|
4 | 4 | BellAlertIcon, |
5 | 5 | BookOpenIcon, |
6 | 6 | ChatBubbleLeftRightIcon, |
| 7 | + CheckIcon, |
7 | 8 | PlusIcon, |
8 | 9 | QuestionMarkCircleIcon, |
9 | 10 | Squares2X2Icon, |
@@ -116,10 +117,17 @@ function DeployDocsLinks() { |
116 | 117 | ); |
117 | 118 | } |
118 | 119 |
|
119 | | -export function HasNoTasksDev({ initializedAt }: { initializedAt: Date | string | null }) { |
| 120 | +export function HasNoTasksDev({ |
| 121 | + initializedAt, |
| 122 | + enhanced = false, |
| 123 | +}: { |
| 124 | + initializedAt: Date | string | null; |
| 125 | + enhanced?: boolean; |
| 126 | +}) { |
120 | 127 | const { isConnected } = useDevPresence(); |
121 | 128 | const initialized = !!initializedAt; |
122 | 129 | const devConnected = isConnected === true; |
| 130 | + const complete = <CheckIcon className="size-5 text-success" aria-label="Complete" />; |
123 | 131 |
|
124 | 132 | return ( |
125 | 133 | <PackageManagerProvider> |
@@ -163,49 +171,88 @@ export function HasNoTasksDev({ initializedAt }: { initializedAt: Date | string |
163 | 171 | </div> |
164 | 172 | </> |
165 | 173 | )} |
166 | | - <StepNumber |
167 | | - stepNumber="1" |
168 | | - title={initialized ? "Project initialized" : "Initialize your project"} |
169 | | - complete={initialized} |
170 | | - /> |
171 | | - <StepContentContainer> |
172 | | - {initialized ? ( |
173 | | - <Paragraph> |
174 | | - Your project is initialized. Your tasks live in the{" "} |
175 | | - <InlineCode variant="small">trigger</InlineCode> directory. |
176 | | - </Paragraph> |
177 | | - ) : ( |
178 | | - <> |
179 | | - <InitCommandV3 /> |
180 | | - <Paragraph spacing> |
181 | | - Run this in an existing project. You'll notice a new folder called{" "} |
182 | | - <InlineCode variant="small">trigger</InlineCode> with a few example tasks to help |
183 | | - you get started. |
184 | | - </Paragraph> |
185 | | - </> |
186 | | - )} |
187 | | - </StepContentContainer> |
188 | | - <StepNumber |
189 | | - stepNumber="2" |
190 | | - title={devConnected ? "Dev server connected" : "Start the dev server"} |
191 | | - complete={devConnected} |
192 | | - /> |
193 | | - <StepContentContainer> |
194 | | - {devConnected ? ( |
195 | | - <Paragraph> |
196 | | - Your dev server is connected. Your tasks will appear here automatically as soon as |
197 | | - they register. |
198 | | - </Paragraph> |
199 | | - ) : ( |
200 | | - <> |
201 | | - <TriggerDevStepV3 /> |
202 | | - <Paragraph spacing> |
203 | | - Keep this running while you develop. Once your tasks register, this page updates |
204 | | - automatically. |
205 | | - </Paragraph> |
206 | | - </> |
207 | | - )} |
208 | | - </StepContentContainer> |
| 174 | + {enhanced ? ( |
| 175 | + <div> |
| 176 | + <SettingsRow |
| 177 | + bordered={false} |
| 178 | + title={initialized ? "Project initialized" : "Initialize your project"} |
| 179 | + description={ |
| 180 | + initialized ? ( |
| 181 | + <> |
| 182 | + Your project is initialized. Your tasks live in the{" "} |
| 183 | + <InlineCode variant="extra-small">trigger</InlineCode> directory. |
| 184 | + </> |
| 185 | + ) : ( |
| 186 | + <> |
| 187 | + Run this in an existing project. You'll notice a new folder called{" "} |
| 188 | + <InlineCode variant="extra-small">trigger</InlineCode> with a few example tasks |
| 189 | + to help you get started. |
| 190 | + </> |
| 191 | + ) |
| 192 | + } |
| 193 | + action={initialized ? complete : undefined} |
| 194 | + /> |
| 195 | + {!initialized && <InitCommandV3 />} |
| 196 | + <SettingsRow |
| 197 | + className="border-t border-grid-dimmed" |
| 198 | + bordered={false} |
| 199 | + title={devConnected ? "Dev server connected" : "Start the dev server"} |
| 200 | + description={ |
| 201 | + devConnected |
| 202 | + ? "Your dev server is connected. Your tasks will appear here automatically as soon as they register." |
| 203 | + : "Keep this running while you develop. Once your tasks register, this page updates automatically." |
| 204 | + } |
| 205 | + action={devConnected ? complete : undefined} |
| 206 | + /> |
| 207 | + {!devConnected && <TriggerDevStepV3 />} |
| 208 | + </div> |
| 209 | + ) : ( |
| 210 | + <> |
| 211 | + <StepNumber |
| 212 | + stepNumber="1" |
| 213 | + title={initialized ? "Project initialized" : "Initialize your project"} |
| 214 | + complete={initialized} |
| 215 | + /> |
| 216 | + <StepContentContainer> |
| 217 | + {initialized ? ( |
| 218 | + <Paragraph> |
| 219 | + Your project is initialized. Your tasks live in the{" "} |
| 220 | + <InlineCode variant="small">trigger</InlineCode> directory. |
| 221 | + </Paragraph> |
| 222 | + ) : ( |
| 223 | + <> |
| 224 | + <InitCommandV3 /> |
| 225 | + <Paragraph spacing> |
| 226 | + Run this in an existing project. You'll notice a new folder called{" "} |
| 227 | + <InlineCode variant="small">trigger</InlineCode> with a few example tasks to |
| 228 | + help you get started. |
| 229 | + </Paragraph> |
| 230 | + </> |
| 231 | + )} |
| 232 | + </StepContentContainer> |
| 233 | + <StepNumber |
| 234 | + stepNumber="2" |
| 235 | + title={devConnected ? "Dev server connected" : "Start the dev server"} |
| 236 | + complete={devConnected} |
| 237 | + /> |
| 238 | + <StepContentContainer> |
| 239 | + {devConnected ? ( |
| 240 | + <Paragraph> |
| 241 | + Your dev server is connected. Your tasks will appear here automatically as soon as |
| 242 | + they register. |
| 243 | + </Paragraph> |
| 244 | + ) : ( |
| 245 | + <> |
| 246 | + <TriggerDevStepV3 /> |
| 247 | + <Paragraph spacing> |
| 248 | + Keep this running while you develop. Once your tasks register, this page updates |
| 249 | + automatically. |
| 250 | + </Paragraph> |
| 251 | + </> |
| 252 | + )} |
| 253 | + </StepContentContainer> |
| 254 | + </> |
| 255 | + )} |
209 | 256 | </div> |
210 | 257 | </PackageManagerProvider> |
211 | 258 | ); |
|
0 commit comments