Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

feat(workflows): wrap run page in settings layout

Steven Enamakel3b1aa658f1b0
diff --git a/app/src/pages/WorkflowsRun.tsx b/app/src/pages/WorkflowsRun.tsx
index 580ea31cae..413a3a7e10 100644
--- a/app/src/pages/WorkflowsRun.tsx
+++ b/app/src/pages/WorkflowsRun.tsx
@@ -12,7 +12,9 @@
import { useNavigate } from 'react-router-dom';
import WorkflowRunnerBody from '../components/skills/WorkflowRunnerBody';
+import SettingsTabbedPage from '../components/settings/layout/SettingsTabbedPage';
import Button from '../components/ui/Button';
+import Card from '../components/ui/Card';
import { useT } from '../lib/i18n/I18nContext';
export default function WorkflowsRun() {
@@ -20,37 +22,26 @@ export default function WorkflowsRun() {
const navigate = useNavigate();
return (
- <div className="min-h-full flex flex-col">
- <div className="flex-1 flex items-start justify-center p-4 pt-6">
- <div className="w-full max-w-3xl space-y-4">
- {/* Back goes one layer up to wherever the runner was opened from
- (e.g. the Workflows tab via a workflow's Run/Schedule action),
- not a hard-coded route. Param syncing uses `replace`, so history
- isn't polluted and `-1` lands on the originating page. Falls back
- to the Workflows tab on a cold deep-link with no history. */}
- <div className="flex items-center gap-3">
- <Button
- variant="tertiary"
- size="xs"
- onClick={() =>
- // Use the router history index, not `history.length`: length > 1
- // is true even when the only prior entry is an external referrer,
- // which would bounce the user out of the app. `state.idx > 0`
- // means there's an in-app entry to go back to (matches
- // useSettingsNavigation's guard).
- (window.history.state?.idx ?? 0) > 0 ? navigate(-1) : navigate('/flows')
- }
- aria-label={t('common.back')}>
- <span aria-hidden="true">←</span> {t('common.back')}
- </Button>
- <h1 className="text-base font-semibold text-content">{t('skills.run.title')}</h1>
- </div>
-
- <div className="rounded-2xl border border-line bg-surface p-6 shadow-soft animate-fade-up">
+ <div className="h-full p-4">
+ <SettingsTabbedPage
+ title={t('skills.run.title')}
+ headerAction={
+ <Button
+ variant="tertiary"
+ size="xs"
+ onClick={() =>
+ (window.history.state?.idx ?? 0) > 0 ? navigate(-1) : navigate('/flows')
+ }
+ aria-label={t('common.back')}>
+ <span aria-hidden="true">←</span> {t('common.back')}
+ </Button>
+ }>
+ <Card className="animate-fade-up">
+ <div className="p-4">
<WorkflowRunnerBody />
</div>
- </div>
- </div>
+ </Card>
+ </SettingsTabbedPage>
</div>
);
}