Skip to content

Invoke is a leading creative engine that uses image and video generation models to empower professionals, artists, and enthusiasts to generate and create visual media using the latest AI-driven technologies. The solution offers an industry-leading application interface, and serves as the foundation for multiple commercial products.

fix(webv2): put dialog titles and footer buttons on the app scale

joshistoast79fb5e09f659
diff --git a/invokeai/frontend/webv2/src/features/gallery/ui/GalleryBoardMenu.tsx b/invokeai/frontend/webv2/src/features/gallery/ui/GalleryBoardMenu.tsx
index 5bf8d4d346..637919fb15 100644
--- a/invokeai/frontend/webv2/src/features/gallery/ui/GalleryBoardMenu.tsx
+++ b/invokeai/frontend/webv2/src/features/gallery/ui/GalleryBoardMenu.tsx
@@ -169,7 +169,7 @@ export const GalleryBoardMenu = ({
<Dialog.Positioner>
<Dialog.Content>
<Dialog.Header>
- <Dialog.Title fontSize="sm">{t('widgets.gallery.renameBoard')}</Dialog.Title>
+ <Dialog.Title>{t('widgets.gallery.renameBoard')}</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
<Input
@@ -199,7 +199,7 @@ export const GalleryBoardMenu = ({
<Dialog.Positioner>
<Dialog.Content>
<Dialog.Header>
- <Dialog.Title fontSize="sm">
+ <Dialog.Title>
{t('widgets.gallery.deleteBoardQuestion', { name: deleteTarget?.name ?? '' })}
</Dialog.Title>
</Dialog.Header>
diff --git a/invokeai/frontend/webv2/src/features/generation/ui/reference-images/ReferenceImageCropDialog.tsx b/invokeai/frontend/webv2/src/features/generation/ui/reference-images/ReferenceImageCropDialog.tsx
index d6ffe23435..ddd14b8f67 100644
--- a/invokeai/frontend/webv2/src/features/generation/ui/reference-images/ReferenceImageCropDialog.tsx
+++ b/invokeai/frontend/webv2/src/features/generation/ui/reference-images/ReferenceImageCropDialog.tsx
@@ -304,9 +304,7 @@ export const ReferenceImageCropDialog = ({
<Dialog.Positioner>
<Dialog.Content>
<Dialog.Header>
- <Dialog.Title fontSize="sm" fontWeight="700">
- {t('widgets.generate.cropReferenceImage')}
- </Dialog.Title>
+ <Dialog.Title>{t('widgets.generate.cropReferenceImage')}</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
<Stack gap="3">
@@ -392,16 +390,16 @@ export const ReferenceImageCropDialog = ({
<Dialog.Footer>
<Button
disabled={isApplying || isFullReferenceImageCropBox(cropBox)}
- size="sm"
+ size="xs"
variant="outline"
onClick={resetCrop}
>
{t('common.reset')}
</Button>
- <Button disabled={isApplying} size="sm" variant="outline" onClick={close}>
+ <Button disabled={isApplying} size="xs" variant="outline" onClick={close}>
{t('common.cancel')}
</Button>
- <Button loading={isApplying} size="sm" onClick={applyCrop}>
+ <Button loading={isApplying} size="xs" onClick={applyCrop}>
{t('common.apply')}
</Button>
</Dialog.Footer>
diff --git a/invokeai/frontend/webv2/src/features/identity/ui/ProfileDialog.tsx b/invokeai/frontend/webv2/src/features/identity/ui/ProfileDialog.tsx
index fe88f2e34b..367a8a44f2 100644
--- a/invokeai/frontend/webv2/src/features/identity/ui/ProfileDialog.tsx
+++ b/invokeai/frontend/webv2/src/features/identity/ui/ProfileDialog.tsx
@@ -46,9 +46,7 @@ export const ProfileDialog = ({ isOpen, onClose, user }: { isOpen: boolean; onCl
<Dialog.Content>
<Dialog.Header borderBottomWidth="1px" borderColor="border.subtle">
<Stack gap="0.5">
- <Dialog.Title fontSize="md" fontWeight="700">
- {t('auth.account')}
- </Dialog.Title>
+ <Dialog.Title>{t('auth.account')}</Dialog.Title>
<Text color="fg.subtle" fontSize="xs">
{t('auth.signedInAs', { email: user.email })}
</Text>
diff --git a/invokeai/frontend/webv2/src/features/identity/ui/UserFormDialog.tsx b/invokeai/frontend/webv2/src/features/identity/ui/UserFormDialog.tsx
index 235bbcc20c..3034c9a5f3 100644
--- a/invokeai/frontend/webv2/src/features/identity/ui/UserFormDialog.tsx
+++ b/invokeai/frontend/webv2/src/features/identity/ui/UserFormDialog.tsx
@@ -66,9 +66,7 @@ export const UserFormDialog = ({
<>
<Dialog.Header borderBottomWidth="1px" borderColor="border.subtle">
<Stack gap="0.5">
- <Dialog.Title fontSize="md" fontWeight="700">
- {target.mode === 'create' ? t('users.addUser') : t('users.editUser')}
- </Dialog.Title>
+ <Dialog.Title>{target.mode === 'create' ? t('users.addUser') : t('users.editUser')}</Dialog.Title>
{target.mode === 'edit' ? (
<Text color="fg.subtle" fontSize="xs">
{target.user.email}
diff --git a/invokeai/frontend/webv2/src/features/models/ui/detail/UpdatePathDialog.tsx b/invokeai/frontend/webv2/src/features/models/ui/detail/UpdatePathDialog.tsx
index 2aaa30ad4c..35c5412109 100644
--- a/invokeai/frontend/webv2/src/features/models/ui/detail/UpdatePathDialog.tsx
+++ b/invokeai/frontend/webv2/src/features/models/ui/detail/UpdatePathDialog.tsx
@@ -69,9 +69,7 @@ export const UpdatePathDialog = ({
<Dialog.Content>
<Dialog.Header borderBottomWidth="1px" borderColor="border.subtle">
<Stack gap="0.5">
- <Dialog.Title fontSize="sm" fontWeight="700">
- {t('models.updatePath')}
- </Dialog.Title>
+ <Dialog.Title>{t('models.updatePath')}</Dialog.Title>
<Text color="fg.subtle" fontSize="2xs">
{t('models.updatePathDescription')}
</Text>
diff --git a/invokeai/frontend/webv2/src/features/models/ui/library/OrphanedModelsDialog.tsx b/invokeai/frontend/webv2/src/features/models/ui/library/OrphanedModelsDialog.tsx
index e3105aec83..0bd018c2f0 100644
--- a/invokeai/frontend/webv2/src/features/models/ui/library/OrphanedModelsDialog.tsx
+++ b/invokeai/frontend/webv2/src/features/models/ui/library/OrphanedModelsDialog.tsx
@@ -127,9 +127,7 @@ export const OrphanedModelsDialog = ({ onClose }: { onClose: () => void }) => {
<Dialog.Content>
<Dialog.Header borderBottomWidth="1px" borderColor="border.subtle">
<Stack gap="0.5">
- <Dialog.Title fontSize="sm" fontWeight="700">
- {t('models.orphanedTitle')}
- </Dialog.Title>
+ <Dialog.Title>{t('models.orphanedTitle')}</Dialog.Title>
<Text color="fg.subtle" fontSize="2xs">
{t('models.orphanedDescription')}
</Text>
diff --git a/invokeai/frontend/webv2/src/features/workflow/ui/graph-preview/GraphPreviewDialog.tsx b/invokeai/frontend/webv2/src/features/workflow/ui/graph-preview/GraphPreviewDialog.tsx
index ea1aee9581..d285ebfac8 100644
--- a/invokeai/frontend/webv2/src/features/workflow/ui/graph-preview/GraphPreviewDialog.tsx
+++ b/invokeai/frontend/webv2/src/features/workflow/ui/graph-preview/GraphPreviewDialog.tsx
@@ -102,14 +102,14 @@ export const GraphPreviewDialog = ({
aria-disabled={!canInvoke}
cursor={canInvoke ? undefined : 'not-allowed'}
opacity={canInvoke ? undefined : 0.6}
- size="sm"
+ size="xs"
title={dialogRoute.validationMessage}
onClick={invokeRoute}
>
{t('graphPreview.invokeRoute', { route: dialogRoute.label })}
</Button>
) : null}
- <Button size="sm" variant="outline" onClick={closeDialog}>
+ <Button size="xs" variant="outline" onClick={closeDialog}>
{t('common.close')}
</Button>
</Dialog.Footer>
diff --git a/invokeai/frontend/webv2/src/features/workflow/ui/library/WorkflowLibraryDialog.tsx b/invokeai/frontend/webv2/src/features/workflow/ui/library/WorkflowLibraryDialog.tsx
index eb2991c426..f96bdd5a90 100644
--- a/invokeai/frontend/webv2/src/features/workflow/ui/library/WorkflowLibraryDialog.tsx
+++ b/invokeai/frontend/webv2/src/features/workflow/ui/library/WorkflowLibraryDialog.tsx
@@ -345,9 +345,7 @@ export const WorkflowLibraryDialog = ({
</Stack>
) : null}
<Dialog.Header>
- <Dialog.Title fontSize="sm" fontWeight="700">
- Workflow Library
- </Dialog.Title>
+ <Dialog.Title>Workflow Library</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
{preview ? (
diff --git a/invokeai/frontend/webv2/src/platform/ui/ConfirmDialog.tsx b/invokeai/frontend/webv2/src/platform/ui/ConfirmDialog.tsx
index 446aa84570..efa0007cf0 100644
--- a/invokeai/frontend/webv2/src/platform/ui/ConfirmDialog.tsx
+++ b/invokeai/frontend/webv2/src/platform/ui/ConfirmDialog.tsx
@@ -80,9 +80,7 @@ export const ConfirmDialog = ({
<Dialog.Positioner>
<Dialog.Content bg="bg.subtle" borderColor="border.subtle" borderWidth="1px" color="fg">
<Dialog.Header>
- <Dialog.Title fontSize="sm" fontWeight="700">
- {title}
- </Dialog.Title>
+ <Dialog.Title>{title}</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
<Stack gap="2">{typeof body === 'string' ? <Text fontSize="xs">{body}</Text> : body}</Stack>
diff --git a/invokeai/frontend/webv2/src/platform/ui/RenameDialog.tsx b/invokeai/frontend/webv2/src/platform/ui/RenameDialog.tsx
index eaf0fc42ab..bef425faeb 100644
--- a/invokeai/frontend/webv2/src/platform/ui/RenameDialog.tsx
+++ b/invokeai/frontend/webv2/src/platform/ui/RenameDialog.tsx
@@ -81,9 +81,7 @@ export const RenameDialog = ({
<Dialog.Content bg="bg.subtle" borderColor="border.subtle" borderWidth="1px" color="fg">
<chakra.form onSubmit={handleSubmit}>
<Dialog.Header>
- <Dialog.Title fontSize="sm" fontWeight="700">
- {title}
- </Dialog.Title>
+ <Dialog.Title>{title}</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
<Stack gap="2">
diff --git a/invokeai/frontend/webv2/src/platform/ui/theme/recipes.ts b/invokeai/frontend/webv2/src/platform/ui/theme/recipes.ts
index b171a9eb02..289ec646a3 100644
--- a/invokeai/frontend/webv2/src/platform/ui/theme/recipes.ts
+++ b/invokeai/frontend/webv2/src/platform/ui/theme/recipes.ts
@@ -482,6 +482,13 @@ export const dialogSlotRecipe = defineSlotRecipe({
borderColor: 'border.subtle',
borderWidth: '1px',
},
+ // Chakra's stock `lg` title reads as a page heading; dialogs here are
+ // compact tool windows, so titles match the app's `sm`/700 convention.
+ title: {
+ ...chakraSlotRecipes.dialog.base?.title,
+ fontWeight: '700',
+ textStyle: 'sm',
+ },
},
});
diff --git a/invokeai/frontend/webv2/src/workbench/projects/components/OpenProjectDialog.tsx b/invokeai/frontend/webv2/src/workbench/projects/components/OpenProjectDialog.tsx
index a028f22202..6aeee1483a 100644
--- a/invokeai/frontend/webv2/src/workbench/projects/components/OpenProjectDialog.tsx
+++ b/invokeai/frontend/webv2/src/workbench/projects/components/OpenProjectDialog.tsx
@@ -125,9 +125,7 @@ export const OpenProjectDialog = ({ isOpen, onClose }: { isOpen: boolean; onClos
<Dialog.Positioner>
<Dialog.Content>
<Dialog.Header>
- <Dialog.Title fontSize="sm" fontWeight="700">
- {t('projects.openProject')}
- </Dialog.Title>
+ <Dialog.Title>{t('projects.openProject')}</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
<Scrollable maxH="72">
diff --git a/invokeai/frontend/webv2/src/workbench/queue-integration/QueueItemActions.tsx b/invokeai/frontend/webv2/src/workbench/queue-integration/QueueItemActions.tsx
index 9e9bc7e035..8ae6cd0424 100644
--- a/invokeai/frontend/webv2/src/workbench/queue-integration/QueueItemActions.tsx
+++ b/invokeai/frontend/webv2/src/workbench/queue-integration/QueueItemActions.tsx
@@ -101,9 +101,7 @@ export const QueueItemActions = ({ item }: { item: QueueItemReadModel }) => {
<Dialog.Positioner>
<Dialog.Content bg="bg.subtle" borderColor="border.subtle" borderWidth="1px" color="fg">
<Dialog.Header>
- <Dialog.Title fontSize="sm" fontWeight="700">
- {t('widgets.queue.itemTitle', { id: item.id })}
- </Dialog.Title>
+ <Dialog.Title>{t('widgets.queue.itemTitle', { id: item.id })}</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
<JsonPreview label={t('widgets.queue.itemJsonLabel', { id: item.id })} maxH="60vh" value={item} />
diff --git a/invokeai/frontend/webv2/src/workbench/settings/SettingsDialog.tsx b/invokeai/frontend/webv2/src/workbench/settings/SettingsDialog.tsx
index 125cdef867..ae0bf9e447 100644
--- a/invokeai/frontend/webv2/src/workbench/settings/SettingsDialog.tsx
+++ b/invokeai/frontend/webv2/src/workbench/settings/SettingsDialog.tsx
@@ -141,7 +141,7 @@ const SettingsDialogContent = ({ onClose }: { onClose: () => void }) => {
<Flex alignItems="start" gap="2">
<Icon as={SettingsIcon} boxSize="5" />
<Stack gap="1">
- <Dialog.Title fontSize="md" fontWeight="700" mt="0.5" lineHeight={1}>
+ <Dialog.Title lineHeight={1} mt="0.5">
{t('settings.title')}
</Dialog.Title>
<Text color="fg.subtle" fontSize="xs">
diff --git a/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetDialog.tsx b/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetDialog.tsx
index f60214214a..6d309c7852 100644
--- a/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetDialog.tsx
+++ b/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetDialog.tsx
@@ -258,10 +258,10 @@ export const LayoutPresetDialog = ({
</Stack>
</Dialog.Body>
<Dialog.Footer>
- <Button size="sm" type="button" variant="outline" onClick={onClose}>
+ <Button size="xs" type="button" variant="outline" onClick={onClose}>
{t('common.cancel')}
</Button>
- <Button disabled={!canSubmit} size="sm" type="submit">
+ <Button disabled={!canSubmit} size="xs" type="submit">
{submitLabel}
</Button>
</Dialog.Footer>
diff --git a/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetManagerDialogBody.tsx b/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetManagerDialogBody.tsx
index 6aedf9f909..6cb3782c28 100644
--- a/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetManagerDialogBody.tsx
+++ b/invokeai/frontend/webv2/src/workbench/shell/topbar/LayoutPresetManagerDialogBody.tsx
@@ -99,7 +99,7 @@ export const LayoutPresetManagerDialogBody = () => {
</DndContext>
</Dialog.Body>
<Dialog.Footer>
- <Button size="sm" variant="outline" onClick={closeLayoutPresetManager}>
+ <Button size="xs" variant="outline" onClick={closeLayoutPresetManager}>
{t('common.done')}
</Button>
</Dialog.Footer>
diff --git a/invokeai/frontend/webv2/src/workbench/widgets/layers/RunLayerWorkflowDialog.tsx b/invokeai/frontend/webv2/src/workbench/widgets/layers/RunLayerWorkflowDialog.tsx
index ef34c45c84..6c86c67015 100644
--- a/invokeai/frontend/webv2/src/workbench/widgets/layers/RunLayerWorkflowDialog.tsx
+++ b/invokeai/frontend/webv2/src/workbench/widgets/layers/RunLayerWorkflowDialog.tsx
@@ -444,9 +444,7 @@ export const RunLayerWorkflowDialog = ({
<Dialog.Content ref={contentRef} bg="bg.subtle" borderColor="border.subtle" borderWidth="1px" color="fg">
<chakra.form onSubmit={handleSubmit}>
<Dialog.Header>
- <Dialog.Title fontSize="sm" fontWeight="700">
- {t('widgets.layers.runWorkflow.title')}
- </Dialog.Title>
+ <Dialog.Title>{t('widgets.layers.runWorkflow.title')}</Dialog.Title>
</Dialog.Header>
<Dialog.Body>
<Stack gap="4">