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.

feat(webv2): restore the What's New notes and point docs at the v7 site

Lincoln Stein20da521e0b79
diff --git a/invokeai/frontend/webv2/performance/architecture-baseline.json b/invokeai/frontend/webv2/performance/architecture-baseline.json
index 5dc3c67c05..b429ad3867 100644
--- a/invokeai/frontend/webv2/performance/architecture-baseline.json
+++ b/invokeai/frontend/webv2/performance/architecture-baseline.json
@@ -2,15 +2,15 @@
"build": {
"launchpad": {
"baseline": {
- "brotliBytes": 893586,
+ "brotliBytes": 783834,
"cssRawBytes": 2159,
"fontRawBytes": 219480,
- "gzipBytes": 892942,
- "imageRawBytes": 156376,
- "initialRawBytes": 2118609,
- "largestAssetRawBytes": 749035,
+ "gzipBytes": 783016,
+ "imageRawBytes": 44398,
+ "initialRawBytes": 2012114,
+ "largestAssetRawBytes": 749225,
"otherAssetRawBytes": 0,
- "ownedRawBytes": 93082,
+ "ownedRawBytes": 94155,
"requestCount": 36,
"scriptRequestCount": 20,
"sourceOwners": [
@@ -197,6 +197,7 @@
"source:src/platform/react/useMountEffect.ts",
"source:src/platform/react/usePreservedScrollOffset.ts",
"source:src/platform/react/useZodForm.ts",
+ "source:src/platform/runtime/appMetadata.ts",
"source:src/platform/search/dateTokens.ts",
"source:src/platform/state/accountLifecycle.ts",
"source:src/platform/state/externalStore.ts",
@@ -325,7 +326,9 @@
"source:src/workbench/settings/launchpad.tsx",
"source:src/workbench/settings/settingsDialogStore.ts",
"source:src/workbench/settings/settingsSearchShortcut.ts",
- "source:src/workbench/settings/store.ts"
+ "source:src/workbench/settings/store.ts",
+ "source:src/workbench/shell/useWhatsNew.ts",
+ "source:src/workbench/shell/whatsNewStore.ts"
]
},
"owner": "app",
@@ -334,15 +337,15 @@
},
"editor": {
"baseline": {
- "brotliBytes": 1243382,
+ "brotliBytes": 1139046,
"cssRawBytes": 2159,
"fontRawBytes": 219480,
- "gzipBytes": 1237668,
- "imageRawBytes": 156376,
- "initialRawBytes": 3203516,
- "largestAssetRawBytes": 749035,
+ "gzipBytes": 1132999,
+ "imageRawBytes": 44398,
+ "initialRawBytes": 3111181,
+ "largestAssetRawBytes": 749225,
"otherAssetRawBytes": 0,
- "ownedRawBytes": 144128,
+ "ownedRawBytes": 143824,
"requestCount": 74,
"scriptRequestCount": 58,
"sourceOwners": [
@@ -715,6 +718,7 @@
"source:src/platform/react/useMountEffect.ts",
"source:src/platform/react/usePreservedScrollOffset.ts",
"source:src/platform/react/useZodForm.ts",
+ "source:src/platform/runtime/appMetadata.ts",
"source:src/platform/search/dateTokens.ts",
"source:src/platform/state/accountLifecycle.ts",
"source:src/platform/state/compareAndSwapRollback.ts",
@@ -1000,6 +1004,8 @@
"source:src/workbench/shell/topbar/useLayoutDrift.ts",
"source:src/workbench/shell/topbar/useTopbarShortcut.ts",
"source:src/workbench/shell/useMountedInstanceIds.ts",
+ "source:src/workbench/shell/useWhatsNew.ts",
+ "source:src/workbench/shell/whatsNewStore.ts",
"source:src/workbench/useNotify.ts",
"source:src/workbench/useOpenWorkbenchWidget.ts",
"source:src/workbench/widget-frame/FloatingWidgetLayer.tsx",
@@ -1066,7 +1072,7 @@
"source": "src/app/WorkbenchApp.tsx"
}
},
- "capturedAt": "2026-09-29",
+ "capturedAt": "2026-10-02",
"developmentInvalidation": {
"platformUiBarrel": {
"specifier": "@platform/ui",
diff --git a/invokeai/frontend/webv2/public/locales/en.json b/invokeai/frontend/webv2/public/locales/en.json
index 025608e435..9ef045e5eb 100644
--- a/invokeai/frontend/webv2/public/locales/en.json
+++ b/invokeai/frontend/webv2/public/locales/en.json
@@ -4593,5 +4593,20 @@
"estimate": "{{count, number}} selected · {{images}}, {{videos}}, about {{size}}",
"available": "{{images}}, {{videos}} unused · about {{size}} reclaimable"
}
+ },
+ "whatsNew": {
+ "items": [
+ "Complete frontend facelift with flexible UI widgets.",
+ "Projects that help keep your work organized.",
+ "Powerful new Canvas features.",
+ "Video models: Wan-2.2, MiniMax H3, LTX-2.5.",
+ "Search galleries by content or image similarity.",
+ "An interactive image map that groups your gallery by theme and autotags images.",
+ "Smaller and faster models.",
+ "And much more!"
+ ],
+ "readReleaseNotes": "Read Release Notes",
+ "readTheDocs": "Read the Docs",
+ "whatsNewInInvoke": "What's New in Invoke"
}
}
diff --git a/invokeai/frontend/webv2/scripts/mock-backend.mjs b/invokeai/frontend/webv2/scripts/mock-backend.mjs
index c6e0cb1726..c95441e8ef 100644
--- a/invokeai/frontend/webv2/scripts/mock-backend.mjs
+++ b/invokeai/frontend/webv2/scripts/mock-backend.mjs
@@ -97,6 +97,8 @@ const STARTER_MODEL = {
type: 'main',
};
+const MOCK_APP_VERSION = 'fixture';
+
const STARTER_MODELS_RESPONSE = {
starter_bundles: {
'sd-1': { models: [STARTER_MODEL], name: 'Stable Diffusion 1.5' },
@@ -113,8 +115,13 @@ const createState = (profile) => {
return {
boards: new Map(fixture.boards.map((board) => [board.board_id, clone(board)])),
- // Dismiss the alpha notice so journeys start on the requested page.
- clientState: new Map([['webv2:workbench-settings', JSON.stringify({ alphaNoticeAcknowledged: true })]]),
+ // Dismiss the alpha notice and What's New notes so journeys start on the requested page.
+ clientState: new Map([
+ [
+ 'webv2:workbench-settings',
+ JSON.stringify({ alphaNoticeAcknowledged: true, whatsNewSeenVersion: MOCK_APP_VERSION }),
+ ],
+ ]),
images: new Map(fixture.images.map((image) => [image.image_name, clone(image)])),
models: new Map(fixture.models.map((model) => [model.key, clone(model)])),
mutationClock: 0,
@@ -867,7 +874,7 @@ export const startMockBackend = async (port, { profile = 'empty' } = {}) => {
}
if (method === 'GET' && path === '/api/v1/app/version') {
- return json(200, { version: 'fixture' });
+ return json(200, { version: MOCK_APP_VERSION });
}
if (method === 'GET' && path === '/api/v1/app/generation_device_options') {
diff --git a/invokeai/frontend/webv2/scripts/run-accessibility-journeys.mjs b/invokeai/frontend/webv2/scripts/run-accessibility-journeys.mjs
index 6b6852a452..1a02e31ba2 100644
--- a/invokeai/frontend/webv2/scripts/run-accessibility-journeys.mjs
+++ b/invokeai/frontend/webv2/scripts/run-accessibility-journeys.mjs
@@ -534,16 +534,18 @@ const runTopbarMenuJourney = async (browser) => {
const appMenu = page.getByRole('menu', { exact: true, name: 'Open menu' });
const commandPaletteItem = page.getByRole('menuitem', { name: /^Command palette/ });
const settingsItem = appMenu.getByRole('menuitem', { name: /^Settings(?: \(.+\))?$/ });
+ const whatsNewItem = page.getByRole('menuitem', { exact: true, name: "What's New in Invoke" });
const documentationItem = page.getByRole('menuitem', { exact: true, name: 'Documentation' });
const discordItem = page.getByRole('menuitem', { exact: true, name: 'Discord' });
await commandPaletteItem.waitFor();
await settingsItem.waitFor();
+ await whatsNewItem.waitFor();
await documentationItem.waitFor();
await discordItem.waitFor();
const footerMetrics = await appMenu.evaluate((menu) => {
const menuBounds = menu.getBoundingClientRect();
- const footerItems = [...menu.querySelectorAll('[role="menuitem"]')].slice(-4);
+ const footerItems = [...menu.querySelectorAll('[role="menuitem"]')].slice(-5);
return {
itemsFit: footerItems.every((item) => {
@@ -567,7 +569,7 @@ const runTopbarMenuJourney = async (browser) => {
await appMenu.press('End');
assert.equal(await appMenu.getAttribute('aria-activedescendant'), await discordItem.getAttribute('id'));
- for (const item of [documentationItem, settingsItem, commandPaletteItem]) {
+ for (const item of [documentationItem, whatsNewItem, settingsItem, commandPaletteItem]) {
await appMenu.press('ArrowUp');
assert.equal(await appMenu.getAttribute('aria-activedescendant'), await item.getAttribute('id'));
}
diff --git a/invokeai/frontend/webv2/src/app/App.tsx b/invokeai/frontend/webv2/src/app/App.tsx
index 3d3016dd63..9513e3daef 100644
--- a/invokeai/frontend/webv2/src/app/App.tsx
+++ b/invokeai/frontend/webv2/src/app/App.tsx
@@ -4,6 +4,7 @@ import { AppToaster } from '@platform/ui/toaster';
import { RouterProvider } from '@tanstack/react-router';
import { system } from '@theme/system';
import { useWorkbenchSettingsSelector } from '@workbench/settings/store';
+import { useWhatsNew } from '@workbench/shell/useWhatsNew';
import { lazy, Suspense } from 'react';
import { FeatureHintsAdapterProvider } from './FeatureHintsProvider';
@@ -28,6 +29,21 @@ const AlphaNoticeGate = () => {
) : null;
};
+const WhatsNewDialog = lazy(() =>
+ import('@workbench/shell/WhatsNewDialog').then((module) => ({ default: module.WhatsNewDialog }))
+);
+
+/** Load the What's New notes when a new version has not been seen yet, or when the app menu asks for them. */
+const WhatsNewGate = () => {
+ const { isOpen } = useWhatsNew();
+
+ return isOpen ? (
+ <Suspense fallback={null}>
+ <WhatsNewDialog />
+ </Suspense>
+ ) : null;
+};
+
export const App = () => (
<AppProviders>
<ChakraProvider value={system}>
@@ -35,6 +51,7 @@ export const App = () => (
<I18nController />
<AppToaster />
<AlphaNoticeGate />
+ <WhatsNewGate />
<FeatureHintsAdapterProvider>
<RouterProvider router={router} />
</FeatureHintsAdapterProvider>
diff --git a/invokeai/frontend/webv2/src/app/router.tsx b/invokeai/frontend/webv2/src/app/router.tsx
index e8cd821554..2d2b4acd50 100644
--- a/invokeai/frontend/webv2/src/app/router.tsx
+++ b/invokeai/frontend/webv2/src/app/router.tsx
@@ -30,6 +30,7 @@ import { Launchpad } from '@workbench/launchpad/Launchpad';
import { ProjectFileOptionsProvider } from '@workbench/projects/components/ProjectFileOptionsProvider';
import { peekOpenProjectIds, type WorkbenchSearch } from '@workbench/projects/session';
import { loadWorkbenchSettings } from '@workbench/settings/store';
+import { loadAppVersion } from '@workbench/shell/whatsNewStore';
import { Fragment } from 'react';
import { SocketHubRuntime } from './SocketHubRuntime';
@@ -100,6 +101,8 @@ const authenticatedRoute = createRoute({
}
}
+ // What's New compares this with the account's last-seen version; it never holds up the route.
+ void loadAppVersion();
await loadWorkbenchSettings();
},
component: AuthenticatedLayout,
diff --git a/invokeai/frontend/webv2/src/platform/i18n/translationKeys.test.ts b/invokeai/frontend/webv2/src/platform/i18n/translationKeys.test.ts
index f649b8dc3e..186a015985 100644
--- a/invokeai/frontend/webv2/src/platform/i18n/translationKeys.test.ts
+++ b/invokeai/frontend/webv2/src/platform/i18n/translationKeys.test.ts
@@ -29,6 +29,11 @@ const flattenCatalog = (value: unknown, prefix = '', keys = new Set<string>()):
const path = prefix ? `${prefix}.${segment}` : segment;
if (typeof child === 'object' && child !== null) {
+ // An array is read whole with `t('x', { returnObjects: true })`, so its own path is a key too.
+ if (Array.isArray(child)) {
+ keys.add(path);
+ }
+
flattenCatalog(child, path, keys);
continue;
}
diff --git a/invokeai/frontend/webv2/src/platform/runtime/appMetadata.ts b/invokeai/frontend/webv2/src/platform/runtime/appMetadata.ts
index 717f5cd11e..9b54abb519 100644
--- a/invokeai/frontend/webv2/src/platform/runtime/appMetadata.ts
+++ b/invokeai/frontend/webv2/src/platform/runtime/appMetadata.ts
@@ -1,2 +1,10 @@
/** Build-time application metadata with no domain dependencies. */
export const APP_VERSION = '7.0';
+
+export const DOCS_URL = 'https://invoke-ai.github.io/InvokeAI-7/';
+
+/** Release notes for a server version string (`7.0.0`, `7.0.0-rc1`), or the release list when it is unknown. */
+export const getReleaseNotesUrl = (version: string | null): string =>
+ version
+ ? `https://github.com/invoke-ai/InvokeAI/releases/tag/v${version}`
+ : 'https://github.com/invoke-ai/InvokeAI/releases';
diff --git a/invokeai/frontend/webv2/src/platform/ui/VendoredIcon.tsx b/invokeai/frontend/webv2/src/platform/ui/VendoredIcon.tsx
index bfd7c10303..7f5d5dfb4c 100644
--- a/invokeai/frontend/webv2/src/platform/ui/VendoredIcon.tsx
+++ b/invokeai/frontend/webv2/src/platform/ui/VendoredIcon.tsx
@@ -102,3 +102,13 @@ export const GradientIcon = createVendoredIcon({
title: 'Gradient',
viewBox: '0 0 32 32',
});
+
+export const LightbulbFilamentIcon = createVendoredIcon({
+ origin: 'Phosphor Icons, bold weight (MIT)',
+ paths: [
+ 'M180,232a12,12,0,0,1-12,12H88a12,12,0,0,1,0-24h80A12,12,0,0,1,180,232Zm40-128a92.47,92.47,0,0,1-37,73.73,7.81,7.81,0,0,0-3,6.27,20,20,0,0,1-20,20H96a20,20,0,0,1-20-20v-.23a7.76,7.76,0,0,0-3.25-6.2,91.36,91.36,0,0,1-36.75-73C35.73,54.69,76,13.2,125.79,12A92,92,0,0,1,220,104Zm-24,0a68,68,0,0,0-69.65-68C89.56,36.89,59.8,67.56,60,104.39a67.52,67.52,0,0,0,27.18,54h0A32.14,32.14,0,0,1,99.77,180H116V149L87.51,120.49a12,12,0,0,1,17-17L128,127l23.51-23.51a12,12,0,0,1,17,17L140,149v31h16.25a31.89,31.89,0,0,1,12.41-21.49A67.45,67.45,0,0,0,196,104Z',
+ ],
+ slug: 'lightbulb-filament',
+ title: 'Lightbulb',
+ viewBox: '0 0 256 256',
+});
diff --git a/invokeai/frontend/webv2/src/workbench/launchpad/HelpMenu.tsx b/invokeai/frontend/webv2/src/workbench/launchpad/HelpMenu.tsx
index f488087993..7f01c2b21d 100644
--- a/invokeai/frontend/webv2/src/workbench/launchpad/HelpMenu.tsx
+++ b/invokeai/frontend/webv2/src/workbench/launchpad/HelpMenu.tsx
@@ -1,7 +1,7 @@
import type { ElementType } from 'react';
import { chakra, HStack, Icon, Menu, Portal, Text } from '@chakra-ui/react';
-import { APP_VERSION } from '@platform/runtime/appMetadata';
+import { APP_VERSION, DOCS_URL } from '@platform/runtime/appMetadata';
import { Button } from '@platform/ui/Button';
import { MenuContent } from '@platform/ui/Menu';
import { DiscordIcon, GithubIcon } from '@platform/ui/VendoredIcon';
@@ -22,7 +22,7 @@ interface HelpLink {
const GUIDES: HelpLink[] = [
{
- href: 'https://invoke-ai.github.io/InvokeAI/',
+ href: DOCS_URL,
icon: BookOpenTextIcon,
labelKey: 'launchpad.help.documentation',
value: 'documentation',
diff --git a/invokeai/frontend/webv2/src/workbench/settings/contracts.ts b/invokeai/frontend/webv2/src/workbench/settings/contracts.ts
index 6bb72cb54a..e2b0cafe7b 100644
--- a/invokeai/frontend/webv2/src/workbench/settings/contracts.ts
+++ b/invokeai/frontend/webv2/src/workbench/settings/contracts.ts
@@ -45,6 +45,8 @@ export interface StoredGeneratePreset {
export interface WorkbenchPreferences {
/** The alpha-build notice was dismissed; shown once per account until then. */
alphaNoticeAcknowledged: boolean;
+ /** Server version whose What's New notes were last dismissed; a different version shows them once. */
+ whatsNewSeenVersion: string | null;
themeId: WorkbenchThemeId;
reduceMotion: boolean;
showFocusRegionHighlight: boolean;
diff --git a/invokeai/frontend/webv2/src/workbench/settings/store.ts b/invokeai/frontend/webv2/src/workbench/settings/store.ts
index 6c1fb92e25..eeed16f05c 100644
--- a/invokeai/frontend/webv2/src/workbench/settings/store.ts
+++ b/invokeai/frontend/webv2/src/workbench/settings/store.ts
@@ -67,6 +67,7 @@ export const DEFAULT_PREFERENCES: WorkbenchPreferences = {
showPromptSyntaxHighlighting: true,
showFocusRegionHighlight: true,
themeId: DEFAULT_THEME_ID,
+ whatsNewSeenVersion: null,
workflowEdgeStyle: 'curved',
workflowEdgesBehindNodes: false,
workflowGroupNodesByCategory: true,
@@ -348,6 +349,10 @@ export const normalizeWorkbenchPreferences = (preferences?: WorkbenchPreferences
? preferences.showPromptSyntaxHighlighting
: DEFAULT_PREFERENCES.showPromptSyntaxHighlighting,
themeId: resolveWorkbenchThemeId(preferences?.themeId) ?? DEFAULT_PREFERENCES.themeId,
+ whatsNewSeenVersion:
+ typeof preferences?.whatsNewSeenVersion === 'string'
+ ? preferences.whatsNewSeenVersion
+ : DEFAULT_PREFERENCES.whatsNewSeenVersion,
workflowEdgeStyle:
preferences?.workflowEdgeStyle === 'square' || preferences?.workflowEdgeStyle === 'straight'
? 'square'
diff --git a/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.browser.test.tsx b/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.browser.test.tsx
new file mode 100644
index 0000000000..5bce28a715
--- /dev/null
+++ b/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.browser.test.tsx
@@ -0,0 +1,177 @@
+import { ChakraProvider } from '@chakra-ui/react';
+import { accountLifecycle } from '@platform/state/accountLifecycle';
+import { system } from '@theme/system';
+import { isHotkeyModalLayerActive } from '@workbench/hotkeys/modalLayer';
+import { createInstance } from 'i18next';
+import { act } from 'react';
+import { createRoot, type Root } from 'react-dom/client';
+import { I18nextProvider, initReactI18next } from 'react-i18next';
+import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
+import { page } from 'vitest/browser';
+
+import { WhatsNewDialog } from './WhatsNewDialog';
+import * as store from './whatsNewStore';
+
+type Snapshot = {
+ preferences: { alphaNoticeAcknowledged: boolean; whatsNewSeenVersion: string | null };
+ status: 'idle' | 'ready';
+};
+
+const settings = vi.hoisted(() => ({
+ snapshot: {
+ preferences: { alphaNoticeAcknowledged: true, whatsNewSeenVersion: null },
+ status: 'idle',
+ } as Snapshot,
+ listeners: new Set<() => void>(),
+ patchWorkbenchPreferences: vi.fn(),
+}));
+
+vi.mock('@workbench/settings/store', async () => {
+ const { useSyncExternalStore } = await import('react');
+
+ return {
+ patchWorkbenchPreferences: settings.patchWorkbenchPreferences,
+ useWorkbenchSettingsSelector: (selector: (snapshot: Snapshot) => unknown) =>
+ useSyncExternalStore(
+ (listener) => {
+ settings.listeners.add(listener);
+ return () => settings.listeners.delete(listener);
+ },
+ () => selector(settings.snapshot)
+ ),
+ };
+});
+
+vi.mock('@platform/transport/http', () => ({
+ apiFetchJson: vi.fn((path: string) =>
+ path === '/api/v1/app/version'
+ ? Promise.resolve({ version: '7.0.0-rc1' })
+ : Promise.reject(new Error(`unexpected request ${path}`))
+ ),
+}));
+
+const catalog = (await fetch('/locales/en.json').then((response) => response.json())) as {
+ whatsNew: { items: string[] };
+};
+// An emphasized item exercises the `<StrongComponent>` markup the shipped catalog may use.
+catalog.whatsNew.items = [...catalog.whatsNew.items, 'Try <StrongComponent>the new thing</StrongComponent> today.'];
+
+const i18n = createInstance();
+await i18n.use(initReactI18next).init({
+ lng: 'en',
+ resources: { en: { translation: catalog } },
+ interpolation: { escapeValue: false },
+});
+
+(globalThis as typeof globalThis & { IS_REACT_ACT_ENVIRONMENT: boolean }).IS_REACT_ACT_ENVIRONMENT = true;
+
+const setSnapshot = (next: Snapshot) =>
+ act(() => {
+ settings.snapshot = next;
+ settings.listeners.forEach((listener) => listener());
+ });
+
+const ready = (preferences: Snapshot['preferences']): Snapshot => ({ preferences, status: 'ready' });
+
+const title = () => i18n.t('whatsNew.whatsNewInInvoke');
+
+describe('WhatsNewDialog', () => {
+ let host: HTMLDivElement;
+ let root: Root;
+
+ beforeEach(async () => {
+ settings.patchWorkbenchPreferences.mockReset();
+ settings.snapshot = { preferences: { alphaNoticeAcknowledged: true, whatsNewSeenVersion: null }, status: 'idle' };
+ // An account switch drops the previous test's request and dismissal; the version is not account data.
+ accountLifecycle.invalidate();
+ host = document.createElement('div');
+ document.body.append(host);
+ root = createRoot(host);
+ await act(() =>
+ root.render(
+ <ChakraProvider value={system}>
+ <I18nextProvider i18n={i18n}>
+ <WhatsNewDialog />
+ </I18nextProvider>
+ </ChakraProvider>
+ )
+ );
+ });
+
+ afterEach(async () => {
+ await act(() => root.unmount());
+ host.remove();
+ });
+
+ it('shows once for an unseen version after preferences load, then records the version on dismissal', async () => {
+ await act(() => store.loadAppVersion());
+ // Not before the account's preferences are known: an account that saw these notes must not see them flash.
+ expect(document.querySelector('[role="dialog"]')).toBeNull();
+
+ await setSnapshot(ready({ alphaNoticeAcknowledged: true, whatsNewSeenVersion: '6.14.2' }));
+ await expect.element(page.getByRole('dialog', { name: title() })).toBeVisible();
+ await expect.element(page.getByText('v7.0.0-rc1')).toBeVisible();
+ // An automatic open has no click behind it, so focus on a link would draw its keyboard ring; start on the panel.
+ await expect.element(page.getByRole('dialog', { name: title() })).toHaveFocus();
+ expect(isHotkeyModalLayerActive()).toBe(true);
+
+ const items = i18n.t('whatsNew.items', { returnObjects: true }) as string[];
+ expect(page.getByRole('listitem').elements()).toHaveLength(items.length);
+ // Item text with `:` and `.` renders verbatim.
+ await expect.element(page.getByText('Video models: Wan-2.2, MiniMax H3, LTX-2.5.')).toBeVisible();
+ const emphasis = page.getByText('the new thing', { exact: true }).element();
+ expect(emphasis.tagName).toBe('SPAN');
+ expect(emphasis.parentElement?.textContent).toBe('Try the new thing today.');
+
+ expect(page.getByRole('link', { name: i18n.t('whatsNew.readReleaseNotes') }).element()).toHaveAttribute(
+ 'href',
+ 'https://github.com/invoke-ai/InvokeAI/releases/tag/v7.0.0-rc1'
+ );
+ expect(page.getByRole('link', { name: i18n.t('whatsNew.readTheDocs') }).element()).toHaveAttribute(
+ 'href',
+ 'https://invoke-ai.github.io/InvokeAI-7/'
+ );
+
+ await page.getByRole('button', { name: /close/i }).click();
+ expect(settings.patchWorkbenchPreferences).toHaveBeenCalledExactlyOnceWith({ whatsNewSeenVersion: '7.0.0-rc1' });
+
+ await setSnapshot(ready({ alphaNoticeAcknowledged: true, whatsNewSeenVersion: '7.0.0-rc1' }));
+ await expect.element(page.getByRole('dialog')).not.toBeInTheDocument();
+ expect(isHotkeyModalLayerActive()).toBe(false);
+ });
+
+ it('waits for the alpha notice to be dismissed first', async () => {
+ await act(() => store.loadAppVersion());
+ await setSnapshot(ready({ alphaNoticeAcknowledged: false, whatsNewSeenVersion: null }));
+ await expect.element(page.getByText('v7.0.0-rc1')).not.toBeInTheDocument();
+ expect(document.querySelector('[role="dialog"]')).toBeNull();
+
+ await setSnapshot(ready({ alphaNoticeAcknowledged: true, whatsNewSeenVersion: null }));
+ await expect.element(page.getByRole('dialog', { name: title() })).toBeVisible();
+ });
+
+ it('stays closed for a seen version until the app menu opens it, and reopening writes nothing', async () => {
+ await act(() => store.loadAppVersion());
+ await setSnapshot(ready({ alphaNoticeAcknowledged: true, whatsNewSeenVersion: '7.0.0-rc1' }));
+ expect(document.querySelector('[role="dialog"]')).toBeNull();
+
+ await act(() => store.openWhatsNew());
+ await expect.element(page.getByRole('dialog', { name: title() })).toBeVisible();
+
+ await page.getByRole('button', { name: /close/i }).click();
+ await expect.element(page.getByRole('dialog')).not.toBeInTheDocument();
+ expect(settings.patchWorkbenchPreferences).not.toHaveBeenCalled();
+ });
+
+ it('shows an unseen version again for the next account after one dismissed it', async () => {
+ await act(() => store.loadAppVersion());
+ await setSnapshot(ready({ alphaNoticeAcknowledged: true, whatsNewSeenVersion: null }));
+ await page.getByRole('button', { name: /close/i }).click();
+ await expect.element(page.getByRole('dialog')).not.toBeInTheDocument();
+
+ await act(() => {
+ accountLifecycle.invalidate();
+ });
+ await expect.element(page.getByRole('dialog', { name: title() })).toBeVisible();
+ });
+});
diff --git a/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.lateVersion.browser.test.tsx b/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.lateVersion.browser.test.tsx
new file mode 100644
index 0000000000..2e25837363
--- /dev/null
+++ b/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.lateVersion.browser.test.tsx
@@ -0,0 +1,120 @@
+import { ChakraProvider } from '@chakra-ui/react';
+import { system } from '@theme/system';
+import { createInstance } from 'i18next';
+import { act } from 'react';
+import { createRoot, type Root } from 'react-dom/client';
+import { I18nextProvider, initReactI18next } from 'react-i18next';
+import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
+import { page } from 'vitest/browser';
+
+import { WhatsNewDialog } from './WhatsNewDialog';
+import * as store from './whatsNewStore';
+
+type Snapshot = {
+ preferences: { alphaNoticeAcknowledged: boolean; whatsNewSeenVersion: string | null };
+ status: 'idle' | 'ready';
+};
+
+const settings = vi.hoisted(() => ({
+ snapshot: {
+ preferences: { alphaNoticeAcknowledged: true, whatsNewSeenVersion: null },
+ status: 'idle',
+ } as Snapshot,
+ listeners: new Set<() => void>(),
+ patchWorkbenchPreferences: vi.fn(),
+}));
+
+vi.mock('@workbench/settings/store', async () => {
+ const { useSyncExternalStore } = await import('react');
+
+ return {
+ patchWorkbenchPreferences: settings.patchWorkbenchPreferences,
+ useWorkbenchSettingsSelector: (selector: (snapshot: Snapshot) => unknown) =>
+ useSyncExternalStore(
+ (listener) => {
+ settings.listeners.add(listener);
+ return () => settings.listeners.delete(listener);
+ },
+ () => selector(settings.snapshot)
+ ),
+ };
+});
+
+const http = vi.hoisted(() => ({ resolveVersion: (_value: { version: string }) => {} }));
+
+// The version read stays pending until the test resolves it.
+vi.mock('@platform/transport/http', () => ({
+ apiFetchJson: vi.fn((path: string) =>
+ path === '/api/v1/app/version'
+ ? new Promise((resolve) => {
+ http.resolveVersion = resolve;
+ })
+ : Promise.reject(new Error(`unexpected request ${path}`))
+ ),
+}));
+
+const catalog = (await fetch('/locales/en.json').then((response) => response.json())) as Record<string, unknown>;
+
+const i18n = createInstance();
+await i18n.use(initReactI18next).init({
+ lng: 'en',
+ resources: { en: { translation: catalog } },
+ interpolation: { escapeValue: false },
+});
+
+(globalThis as typeof globalThis & { IS_REACT_ACT_ENVIRONMENT: boolean }).IS_REACT_ACT_ENVIRONMENT = true;
+
+const setSnapshot = (next: Snapshot) =>
+ act(() => {
+ settings.snapshot = next;
+ settings.listeners.forEach((listener) => listener());
+ });
+
+const ready = (preferences: Snapshot['preferences']): Snapshot => ({ preferences, status: 'ready' });
+
+const title = () => i18n.t('whatsNew.whatsNewInInvoke');
+
+/** Its own file: the store keeps the version for the page's lifetime, and this case needs it still unknown. */
+describe('WhatsNewDialog with a slow version read', () => {
+ let host: HTMLDivElement;
+ let root: Root;
+
+ beforeEach(async () => {
+ host = document.createElement('div');
+ document.body.append(host);
+ root = createRoot(host);
+ await act(() =>
+ root.render(
+ <ChakraProvider value={system}>
+ <I18nextProvider i18n={i18n}>
+ <WhatsNewDialog />
+ </I18nextProvider>
+ </ChakraProvider>
+ )
+ );
+ });
+
+ afterEach(async () => {
+ await act(() => root.unmount());
+ host.remove();
+ });
+
+ it('does not reopen notes closed by hand when the version arrives late', async () => {
+ await setSnapshot(ready({ alphaNoticeAcknowledged: true, whatsNewSeenVersion: '6.14.2' }));
+
+ // The boot read is still pending when the menu opens the notes.
+ void store.loadAppVersion();
+ await act(() => store.openWhatsNew());
+ await expect.element(page.getByRole('dialog', { name: title() })).toBeVisible();
+ await page.getByRole('button', { name: /close/i }).click();
+ await expect.element(page.getByRole('dialog')).not.toBeInTheDocument();
+
+ await act(async () => {
+ http.resolveVersion({ version: '7.0.0-rc1' });
+ await store.loadAppVersion();
+ });
+ expect(store.getWhatsNewSnapshot().version).toBe('7.0.0-rc1');
+ await expect.element(page.getByRole('dialog')).not.toBeInTheDocument();
+ expect(settings.patchWorkbenchPreferences).not.toHaveBeenCalled();
+ });
+});
diff --git a/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.tsx b/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.tsx
new file mode 100644
index 0000000000..8f2748e726
--- /dev/null
+++ b/invokeai/frontend/webv2/src/workbench/shell/WhatsNewDialog.tsx
@@ -0,0 +1,129 @@
+import { Dialog, HStack, Link, List, Portal, Stack, Text } from '@chakra-ui/react';
+import { useMountEffect } from '@platform/react/useMountEffect';
+import { DOCS_URL, getReleaseNotesUrl } from '@platform/runtime/appMetadata';
+import { CloseButton } from '@platform/ui';
+import { InvokeMark } from '@platform/ui/InvokeMark';
+import { registerHotkeyModalLayer } from '@workbench/hotkeys/modalLayer';
+import { patchWorkbenchPreferences } from '@workbench/settings/store';
+import { useCallback, useRef } from 'react';
+import { useTranslation } from 'react-i18next';
+
+import { useWhatsNew } from './useWhatsNew';
+import { dismissWhatsNew } from './whatsNewStore';
+
+const EMPHASIS = /<StrongComponent>(.*?)<\/StrongComponent>/;
+
+const readItems = (value: unknown): string[] =>
+ Array.isArray(value) ? value.filter((entry): entry is string => typeof entry === 'string') : [];
+
+/** Items may emphasize a phrase with `<StrongComponent>…</StrongComponent>`; split captures land on odd indexes. */
+const WhatsNewItem = ({ text }: { text: string }) =>
+ text.split(EMPHASIS).map((part, index) =>
+ index % 2 === 1 ? (
+ <Text key={index} as="span" color="fg" fontWeight="600">
+ {part}
+ </Text>
+ ) : (
+ part
+ )
+ );
+
+/** Mounted only while the notes are open: workbench hotkeys stay quiet under them, as under the other dialogs. */
+const WhatsNewModalLayer = () => {
+ useMountEffect(() => registerHotkeyModalLayer('whats-new'));
+
+ return null;
+};
+
+export const WhatsNewDialog = () => {
+ const { t } = useTranslation();
+ const { isOpen, isUnseen, version } = useWhatsNew();
+ const items = readItems(t('whatsNew.items', { returnObjects: true }));
+ const contentRef = useRef<HTMLDivElement | null>(null);
+ // Start on the panel, not the first link: focus that opens without a click (the automatic showing) counts as
+ // keyboard focus and would ring the link. Tab still reaches the links, and Escape still closes.
+ const getInitialFocusEl = useCallback(() => contentRef.current, []);
+
+ const handleOpenChange = useCallback(
+ (event: { open: boolean }) => {
+ if (event.open) {
+ return;
+ }
+
+ dismissWhatsNew();
+
+ // Unseen implies loaded preferences; patching before they load would persist defaults over saved choices.
+ if (isUnseen) {
+ void patchWorkbenchPreferences({ whatsNewSeenVersion: version });
+ }
+ },
+ [isUnseen, version]
+ );
+
+ return (
+ <Dialog.Root
+ initialFocusEl={getInitialFocusEl}
+ open={isOpen}
+ placement="center"
+ size="xs"
+ onOpenChange={handleOpenChange}
+ >
+ {isOpen ? <WhatsNewModalLayer /> : null}
+ <Portal>
+ <Dialog.Backdrop />
+ <Dialog.Positioner>
+ <Dialog.Content ref={contentRef}>
+ <Dialog.Header>
+ <HStack gap="2.5">
+ <InvokeMark size={20} />
+ <Dialog.Title fontSize="sm">{t('whatsNew.whatsNewInInvoke')}</Dialog.Title>
+ {version ? (
+ <Text color="fg.subtle" fontSize="xs">
+ v{version}
+ </Text>
+ ) : null}
+ </HStack>
+ </Dialog.Header>
+ <Dialog.Body>
+ <Stack gap="4">
+ <List.Root fontSize="xs" gap="1" ps="4">
+ {items.map((item, index) => (
+ // The catalog order is fixed for a build, so the index is a stable key.
+ <List.Item key={index}>
+ <WhatsNewItem text={item} />
+ </List.Item>
+ ))}
+ </List.Root>
+ <Stack gap="1">
+ <Link
+ color="accent.fg"
+ fontSize="xs"
+ fontWeight="600"
+ href={getReleaseNotesUrl(version)}
+ rel="noreferrer"
+ target="_blank"
+ >
+ {t('whatsNew.readReleaseNotes')}
+ </Link>
+ <Link
+ color="accent.fg"
+ fontSize="xs"
+ fontWeight="600"
+ href={DOCS_URL}
+ rel="noreferrer"
+ target="_blank"
+ >
+ {t('whatsNew.readTheDocs')}
+ </Link>
+ </Stack>
+ </Stack>
+ </Dialog.Body>
+ <Dialog.CloseTrigger asChild>
+ <CloseButton />
+ </Dialog.CloseTrigger>
+ </Dialog.Content>
+ </Dialog.Positioner>
+ </Portal>
+ </Dialog.Root>
+ );
+};
diff --git a/invokeai/frontend/webv2/src/workbench/shell/topbar/AppMenu.tsx b/invokeai/frontend/webv2/src/workbench/shell/topbar/AppMenu.tsx
index 67f8841bdb..65ece9c981 100644
--- a/invokeai/frontend/webv2/src/workbench/shell/topbar/AppMenu.tsx
+++ b/invokeai/frontend/webv2/src/workbench/shell/topbar/AppMenu.tsx
@@ -1,16 +1,17 @@
import { Badge, Box, chakra, HStack, Icon, Menu, Portal, Text } from '@chakra-ui/react';
import { AccountMenuSection, useCapabilities, useHasAccountSection } from '@features/identity';
import { getQueueSummary } from '@features/queue/contracts';
-import { APP_VERSION } from '@platform/runtime/appMetadata';
+import { APP_VERSION, DOCS_URL } from '@platform/runtime/appMetadata';
import { IconButton } from '@platform/ui/Button';
import { InvokeMark } from '@platform/ui/InvokeMark';
import { MenuContent } from '@platform/ui/Menu';
import { Tooltip } from '@platform/ui/Tooltip';
-import { DiscordIcon } from '@platform/ui/VendoredIcon';
+import { DiscordIcon, LightbulbFilamentIcon } from '@platform/ui/VendoredIcon';
import { useNavigate } from '@tanstack/react-router';
import { OPEN_COMMAND_PALETTE_HOTKEY } from '@workbench/hotkeys/catalog';
import { openCommandPalette } from '@workbench/palette/paletteStore';
import { openWorkbenchSettings } from '@workbench/settings/settingsDialogStore';
+import { openWhatsNew } from '@workbench/shell/whatsNewStore';
import { useOpenWorkbenchWidget } from '@workbench/useOpenWorkbenchWidget';
import { useActiveProjectId, useActiveProjectSelector } from '@workbench/WorkbenchContext';
import {
@@ -23,7 +24,6 @@ import {
SearchIcon,
SettingsIcon,
TypeIcon,
- type LucideIcon,
} from 'lucide-react';
import { useCallback, type ElementType } from 'react';
import { useTranslation } from 'react-i18next';
@@ -31,7 +31,6 @@ import { useTranslation } from 'react-i18next';
import { useTopbarShortcut } from './useTopbarShortcut';
const MENU_POSITIONING = { placement: 'bottom-start' } as const;
-const DOCS_URL = 'https://invoke-ai.github.io/InvokeAI/';
const DISCORD_URL = 'https://discord.gg/ZmtBAhwWhy';
export const AppMenu = () => {
@@ -121,6 +120,12 @@ export const AppMenu = () => {
<HStack gap="0.5" px="0" py="0">
<SearchMenuAction />
<SettingsMenuAction onClick={openSettings} />
+ <AppMenuAction
+ icon={LightbulbFilamentIcon}
+ label={t('whatsNew.whatsNewInInvoke')}
+ value="whats-new"
+ onClick={openWhatsNew}
+ />
<AppMenuLink
href={DOCS_URL}
icon={BookOpenTextIcon}
@@ -188,7 +193,8 @@ const AppMenuAction = ({
onClick,
value,
}: {
- icon: LucideIcon;
+ /** Lucide for generic actions, a vendored glyph where one is kept for continuity. */
+ icon: ElementType;
label: string;
onClick: () => void;
value: string;
diff --git a/invokeai/frontend/webv2/src/workbench/shell/useWhatsNew.ts b/invokeai/frontend/webv2/src/workbench/shell/useWhatsNew.ts
new file mode 100644
index 0000000000..84c71c4b8f
--- /dev/null
+++ b/invokeai/frontend/webv2/src/workbench/shell/useWhatsNew.ts
@@ -0,0 +1,29 @@
+import { useWorkbenchSettingsSelector } from '@workbench/settings/store';
+
+import { useWhatsNewSnapshot } from './whatsNewStore';
+
+export interface WhatsNewState {
+ isOpen: boolean;
+ /** Whether this showing is the automatic one for a version the account has not dismissed yet. */
+ isUnseen: boolean;
+ /** The server version, or null while unknown. */
+ version: string | null;
+}
+
+/**
+ * Show the notes once per server version for each account, after its preferences are known and the alpha
+ * notice is out of the way, and whenever the app menu asks for them.
+ */
+export const useWhatsNew = (): WhatsNewState => {
+ const { isDismissed, isRequested, version } = useWhatsNewSnapshot();
+ const isUnseen = useWorkbenchSettingsSelector(
+ (snapshot) =>
+ !isDismissed &&
+ version !== null &&
+ snapshot.status === 'ready' &&
+ snapshot.preferences.alphaNoticeAcknowledged &&
+ snapshot.preferences.whatsNewSeenVersion !== version
+ );
+
+ return { isOpen: isRequested || isUnseen, isUnseen, version };
+};
diff --git a/invokeai/frontend/webv2/src/workbench/shell/whatsNewStore.ts b/invokeai/frontend/webv2/src/workbench/shell/whatsNewStore.ts
new file mode 100644
index 0000000000..180ecadc89
--- /dev/null
+++ b/invokeai/frontend/webv2/src/workbench/shell/whatsNewStore.ts
@@ -0,0 +1,62 @@
+import { createLogger } from '@platform/logging/logger';
+import { registerAccountOwnedResource } from '@platform/state/accountLifecycle';
+import { createExternalStore } from '@platform/state/externalStore';
+import { apiFetchJson } from '@platform/transport/http';
+
+const logger = createLogger({ area: 'whats-new', namespace: 'app' });
+
+export interface WhatsNewSnapshot {
+ /**
+ * Closed during this page load. A version that arrives after a manual close must not reopen the notes the user
+ * just dismissed; the next load still shows an unseen version.
+ */
+ isDismissed: boolean;
+ /** Opened from the app menu; the automatic first-run showing is derived from preferences instead. */
+ isRequested: boolean;
+ /**
+ * The server version, or null while unknown. Held here rather than in the query cache: the gate lives above
+ * the router, and account transitions clear that cache without remounting it.
+ */
+ version: string | null;
+}
+
+const store = createExternalStore<WhatsNewSnapshot>({ isDismissed: false, isRequested: false, version: null });
+
+let versionLoad: Promise<void> | null = null;
+
+// The server version is not account data; only the request to show the notes follows the account.
+registerAccountOwnedResource({
+ clear: () => store.patchSnapshot({ isDismissed: false, isRequested: false }),
+ name: 'whats-new',
+});
+
+/** The version only changes across a server restart, so one successful read per page load is enough. */
+export const loadAppVersion = (): Promise<void> => {
+ if (store.getSnapshot().version !== null) {
+ return Promise.resolve();
+ }
+
+ versionLoad ??= apiFetchJson<{ version: string }>('/api/v1/app/version')
+ .then((response) => store.patchSnapshot({ version: response.version }))
+ .catch((error: unknown) => {
+ // The notes stay closed until a later load succeeds; nothing else depends on them.
+ logger.warn({ error, message: 'Failed to load the app version', name: 'app.whats-new.version-failed' });
+ })
+ .finally(() => {
+ versionLoad = null;
+ });
+
+ return versionLoad;
+};
+
+export const openWhatsNew = (): void => {
+ store.patchSnapshot({ isRequested: true });
+ // A failed boot read leaves the version out of the header and links; try again while the notes are open.
+ void loadAppVersion();
+};
+
+export const dismissWhatsNew = (): void => store.patchSnapshot({ isDismissed: true, isRequested: false });
+
+export const getWhatsNewSnapshot = (): WhatsNewSnapshot => store.getSnapshot();
+
+export const useWhatsNewSnapshot = (): WhatsNewSnapshot => store.useSnapshot();
diff --git a/invokeai/frontend/webv2/vite.config.mts b/invokeai/frontend/webv2/vite.config.mts
index e92fb1d44f..375c819800 100644
--- a/invokeai/frontend/webv2/vite.config.mts
+++ b/invokeai/frontend/webv2/vite.config.mts
@@ -40,6 +40,10 @@ const ROUTE_SHARED_MODULES = [
'/platform/ui/settings/contracts.ts',
'/platform/core/concurrency.ts',
'/platform/query/client.ts',
+ // The What's New gate mounts at boot; the app menu and the lazy dialog share these with it.
+ '/platform/runtime/appMetadata.ts',
+ '/workbench/shell/useWhatsNew.ts',
+ '/workbench/shell/whatsNewStore.ts',
'/platform/time/serverTimestamp.ts',
'/platform/transport/connectionStore.ts',
'/platform/transport/socketHub.ts',