@@ -54,6 +54,7 @@ import {
54
54
import { type RuntimeEnvironmentType } from "@trigger.dev/database" ;
55
55
import { environmentFullTitle } from "~/components/environments/EnvironmentLabel" ;
56
56
import { Callout } from "~/components/primitives/Callout" ;
57
+ import upgradeForQueuesPath from "~/assets/images/queues-dashboard.png" ;
57
58
58
59
const SearchParamsSchema = z . object ( {
59
60
page : z . coerce . number ( ) . min ( 1 ) . default ( 1 ) ,
@@ -101,8 +102,6 @@ export const loader = async ({ request, params }: LoaderFunctionArgs) => {
101
102
102
103
return typeddefer ( {
103
104
...queues ,
104
- success : false ,
105
- code : "engine-version" ,
106
105
environment : environmentQueuePresenter . call ( environment ) ,
107
106
} ) ;
108
107
} catch ( error ) {
@@ -358,18 +357,7 @@ export default function Page() {
358
357
) : (
359
358
< div className = "grid place-items-center py-6 text-text-dimmed" >
360
359
{ code === "engine-version" ? (
361
- < div className = "flex flex-col gap-2" >
362
- < div className = "flex items-center justify-between gap-2" >
363
- < h4 className = "text-base text-text-bright" > New queues table</ h4 >
364
- < LinkButton
365
- LeadingIcon = { BookOpenIcon }
366
- to = { docsPath ( "v4-upgrade" ) }
367
- variant = { "docs/small" }
368
- >
369
- Upgrade guide
370
- </ LinkButton >
371
- </ div >
372
- </ div >
360
+ < EngineVersionUpgradeCallout />
373
361
) : (
374
362
< Callout variant = "error" > Something went wrong</ Callout >
375
363
) }
@@ -468,6 +456,30 @@ function EnvironmentPauseResumeButton({
468
456
) ;
469
457
}
470
458
459
+ function EngineVersionUpgradeCallout ( ) {
460
+ return (
461
+ < div className = "mt-4 flex max-w-lg flex-col gap-4 rounded-sm border border-grid-bright bg-background-bright px-4" >
462
+ < div className = "flex items-center justify-between gap-2 border-b border-grid-dimmed py-4" >
463
+ < h4 className = "text-base text-text-bright" > New queues table</ h4 >
464
+ < LinkButton LeadingIcon = { BookOpenIcon } to = { docsPath ( "v4-upgrade" ) } variant = { "docs/small" } >
465
+ Upgrade guide
466
+ </ LinkButton >
467
+ </ div >
468
+ < div className = "space-y-4 pb-4" >
469
+ < Paragraph variant = "small" >
470
+ Upgrade to SDK version 4+ to view the new queues table, and be able to pause and resume
471
+ individual queues.
472
+ </ Paragraph >
473
+ < img
474
+ src = { upgradeForQueuesPath }
475
+ alt = "Upgrade for queues"
476
+ className = "rounded-sm border border-grid-dimmed"
477
+ />
478
+ </ div >
479
+ </ div >
480
+ ) ;
481
+ }
482
+
471
483
export function isEnvironmentPauseResumeFormSubmission (
472
484
formMethod : string | undefined ,
473
485
formData : FormData | undefined
0 commit comments