feat: hyperlinked on "Start application" actionto switch to preview in workbench
Browse files
app/components/chat/Artifact.tsx
CHANGED
@@ -178,9 +178,15 @@ const ActionList = memo(({ actions }: ActionListProps) => {
|
|
178 |
<span className="flex-1">Run command</span>
|
179 |
</div>
|
180 |
) : type === 'start' ? (
|
181 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
182 |
<span className="flex-1">Start Application</span>
|
183 |
-
</
|
184 |
) : null}
|
185 |
</div>
|
186 |
{(type === 'shell' || type === 'start') && (
|
|
|
178 |
<span className="flex-1">Run command</span>
|
179 |
</div>
|
180 |
) : type === 'start' ? (
|
181 |
+
<a
|
182 |
+
onClick={(e) => {
|
183 |
+
e.preventDefault();
|
184 |
+
workbenchStore.currentView.set('preview');
|
185 |
+
}}
|
186 |
+
className="flex items-center w-full min-h-[28px]"
|
187 |
+
>
|
188 |
<span className="flex-1">Start Application</span>
|
189 |
+
</a>
|
190 |
) : null}
|
191 |
</div>
|
192 |
{(type === 'shell' || type === 'start') && (
|