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.
TypeScript ai-artartificial-intelligencegenerative-artimage-generationimg2imginpaintinglatent-diffusionlinuxmacosoutpaintingstable-diffusiontxt2imgwindows
chore(webv2): record mixed gallery performance baselines
joshistoast0b7acabad952
diff --git a/.superpowers/sdd/mixed-media-gallery-parity/task-12-report.md b/.superpowers/sdd/mixed-media-gallery-parity/task-12-report.mdnew file mode 100644index 0000000000..cd350b677f--- /dev/null+++ b/.superpowers/sdd/mixed-media-gallery-parity/task-12-report.md@@ -0,0 +1,218 @@+# Task 12 Report: Final performance baselines and release verification++## Status++Complete. The mixed-media implementation has recorded architecture and browser+performance baselines, all release gates pass, and the baseline diff received+an independent read-only approval with no findings.++The first pre-update measurement correctly stopped on zero-headroom growth.+Systematic tracing isolated the cause to one new standalone first-party chunk.+A targeted editor-only chunk consolidation removed that request and reduced the+guarded entry sizes before either baseline was recorded.++## Pre-update measurement and stop condition++The clean starting head was:++```text+f9fb07fef639a2542a58fd76fbdb8766bdf71383+```++`pnpm test:performance:contracts` passed all 9 tests and+`pnpm exec vite build` built 5,116 modules. The required non-update checker then+failed with:++| Route | Metric | Baseline | Measured | Delta |+| --- | --- | ---: | ---: | ---: |+| launchpad | owned raw bytes | 57,925 | 57,966 | +41 |+| editor | owned raw bytes | 110,133 | 110,272 | +139 |+| editor | requests | 74 | 75 | +1 |+| editor | script requests | 58 | 59 | +1 |++The editor source-owner set added only+`source:src/features/gallery/core/items.ts`. The importer audit still measured+`@platform/ui` at exactly 156.++No baseline update command was run at this point.++## Root cause and consolidation++Rollup emitted `core/items.ts` as the sole owner of a new 1,316-byte+`items-*.js` common chunk. It had runtime consumers across four editor-initial+chunks and five independent lazy chunks. The new chunk path also appeared in+Vite's dependency/preload tables in both route entry files, explaining the+small owned-entry growth separately from the leaf payload.++Nearby pure gallery helpers remain coalesced because their runtime consumers+already converge in `galleryStateView` or `workbenchState`.++After controller approval, `vite.config.mts` received one targeted rule that+places:++- `features/gallery/core/items.ts`+- `features/gallery/ui/galleryStateView.ts`++in an editor-only `gallery-state` chunk. It does not use the launchpad-eager+`shared` chunk and does not couple gallery core to DnD/vendor code.++The single-variable rebuild emitted one 11,026-byte `gallery-state` chunk and+removed the standalone item chunk. The non-update checker then failed only for+the expected unrecorded editor source owner:++| Route | Metric | Baseline | Measured | Delta |+| --- | --- | ---: | ---: | ---: |+| launchpad | owned raw bytes | 57,925 | 57,857 | -68 |+| launchpad | requests / scripts | 31 / 15 | 31 / 15 | 0 / 0 |+| editor | owned raw bytes | 110,133 | 108,775 | -1,358 |+| editor | requests / scripts | 74 / 58 | 72 / 56 | -2 / -2 |++Launchpad source ownership remained unchanged. Editor source ownership added+only `core/items.ts`.++## Exactly-once baseline recording++After the zero-headroom audit passed, the following sequence ran once, in the+specified order:++```sh+pnpm test:performance:contracts+pnpm exec vite build+node scripts/check-architecture-performance.mjs --update-baseline+pnpm test:performance:browser:update-baseline+```++The contracts passed 9/9, both builds transformed 5,116 modules, and both+baseline writers exited successfully. Neither update command was repeated.++The architecture writer's JSON serialization expanded one single-element+structural array, which the repository formatter rejected. With controller+approval, only `performance/architecture-baseline.json` was passed through+`oxfmt`. Canonical JSON hashes before and after were identical:++```text+c66003e91cfee4b6ff2f57484ac71fdea97e78a9c793bbe638eeb70bf39ac13c+```++No baseline value was hand-edited.++## Baseline diff audit++The intended production/baseline files are:++- `invokeai/frontend/webv2/vite.config.mts`+- `invokeai/frontend/webv2/performance/architecture-baseline.json`+- `invokeai/frontend/webv2/performance/browser-baseline.json`++Architecture changes:++- launchpad source owners: no additions or removals;+- editor source owners: added only+ `source:src/features/gallery/core/items.ts`;+- launchpad requests/scripts remained 31/15;+- editor requests/scripts decreased from 74/58 to 72/56;+- launchpad/editor owned bytes decreased to 57,857/108,775;+- editor initial raw bytes increased by 11,893, gzip by 2,670, and Brotli by+ 2,648 under the existing generated 1% policy;+- launchpad initial raw bytes increased by 815 while gzip and Brotli decreased;+- `developmentInvalidation` is semantically unchanged;+- the `@platform/ui` cap and measured importer count remain exactly 156;+- structural policy is semantically unchanged.++Browser changes:++- route identities, schema, sampling, and timing policy remain unchanged;+- launchpad request/script counts remain 19/15;+- editor static request/script counts decrease by two;+- activated request/script counts do not increase;+- static script-owner sets add only `core/items.ts` to the editor minimal and+ canvas sets; launchpad is unchanged and no owner is removed;+- recorded resource growth is payload under the existing generated 1% policy,+ not a zero-headroom request or owned-entry increase.++`performance/architecture-fixtures.json`, profile-count shapes, and+`migrationExceptions.ts` are unchanged. The latter remains `[]`.++## Independent baseline review++The read-only reviewer approved the config and generated baselines with no+Critical, Important, or Minor findings. It independently confirmed:++- only the expected config/baseline files changed before this report;+- architecture values exactly match `build-report.json`;+- browser values and limits exactly derive from `browser-report.json`;+- launchpad ownership is unchanged;+- editor adds only `core/items.ts`;+- owned bytes and request counts do not grow;+- the 156-importer cap, structural policy, fixture schema, and migration+ exceptions are unchanged;+- no suspicious budget weakening or hand edit is present.++## Final frontend verification++All commands ran from `invokeai/frontend/webv2`.++```text+pnpm lint+ format: passed+ OXC: passed+ tsc: passed+ architecture: 3 files, 34 tests passed++pnpm test:all+ unit: 376 files, 5,005 tests passed+ browser: 70 files, 358 tests passed+ fixtures: 10 tests passed++pnpm test:performance:architecture+ contracts: 9 tests passed+ deterministic build/source-owner checks: passed+ all browser route/resource/timing policies: passed++pnpm test:accessibility+ production build: passed+ all 9 representative/keyboard/video journeys: passed++pnpm check:release+ complete aggregate lint, unit, browser, fixture, performance, and+ accessibility sequence: passed+```++No timing-sensitive Tabs failure occurred, so the focused-rerun protocol was+not needed. Browser tests still emit their existing non-failing React `act`,+intentional error-boundary, and missing-test-i18n-instance console diagnostics.+Vite still reports its existing large-chunk and Babel plugin-timing warnings.++## Backend verification++From repository root:++```text+uv run pytest -q \+ tests/app/services/gallery/test_gallery_default.py \+ tests/app/routers/test_gallery.py++23 passed, 4 warnings+```++The warnings are environmental/upstream: the installed PyTorch build does not+target the host RTX 5090 CUDA capability, two protobuf container types use a+Python API deprecated for 3.14, and passlib imports `crypt`, which is deprecated+for Python 3.13. They do not affect the focused test result.++## Invariant scans++- The only production `<video>` element is in `PreviewFrame.tsx`.+- No production `useEffect` line was added since branch start.+- `GeneratedImageContract` is byte-for-byte unchanged.+- No existing production file was renamed.+- `core/items.ts` is the only new production source file.+- `migrationExceptions.ts` remains empty.+- Exactly one production accessibility call disables `video-caption`; the+ other occurrence is the fixture test enforcing that count.+- The representative performance fixture keeps image index 0 as the default+ selection.+- `/gallery/items/names` remains fetched on Shift-click/action demand, not+ initial gallery render.+- Details query components mount only while Details is open.+- `git diff --check` passes.diff --git a/invokeai/frontend/webv2/performance/architecture-baseline.json b/invokeai/frontend/webv2/performance/architecture-baseline.jsonindex 1392a67590..ab630aa461 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": 799074,+ "brotliBytes": 798861,"cssRawBytes": 2159,"fontRawBytes": 219480,- "gzipBytes": 799111,+ "gzipBytes": 798982,"imageRawBytes": 156376,- "initialRawBytes": 1833206,- "largestAssetRawBytes": 737748,+ "initialRawBytes": 1834021,+ "largestAssetRawBytes": 737757,"otherAssetRawBytes": 0,- "ownedRawBytes": 57925,+ "ownedRawBytes": 57857,"requestCount": 31,"scriptRequestCount": 15,"sourceOwners": [@@ -239,15 +239,15 @@]},"limits": {- "brotliBytes": 807065,+ "brotliBytes": 806850,"cssRawBytes": 2181,"fontRawBytes": 221675,- "gzipBytes": 807103,+ "gzipBytes": 806972,"imageRawBytes": 157940,- "initialRawBytes": 1851539,- "largestAssetRawBytes": 745126,+ "initialRawBytes": 1852362,+ "largestAssetRawBytes": 745135,"otherAssetRawBytes": 0,- "ownedRawBytes": 57925,+ "ownedRawBytes": 57857,"requestCount": 31,"scriptRequestCount": 15},@@ -257,17 +257,17 @@},"editor": {"baseline": {- "brotliBytes": 982496,+ "brotliBytes": 985144,"cssRawBytes": 2159,"fontRawBytes": 219480,- "gzipBytes": 981192,+ "gzipBytes": 983862,"imageRawBytes": 156376,- "initialRawBytes": 2392898,- "largestAssetRawBytes": 737748,+ "initialRawBytes": 2404791,+ "largestAssetRawBytes": 737757,"otherAssetRawBytes": 0,- "ownedRawBytes": 110133,- "requestCount": 74,- "scriptRequestCount": 58,+ "ownedRawBytes": 108775,+ "requestCount": 72,+ "scriptRequestCount": 56,"sourceOwners": ["package:@ark-ui/react","package:@chakra-ui/react",@@ -401,6 +401,7 @@"source:src/features/gallery/contracts.ts","source:src/features/gallery/core/image.ts","source:src/features/gallery/core/imagePaths.ts",+ "source:src/features/gallery/core/items.ts","source:src/features/gallery/core/recentImages.ts","source:src/features/gallery/core/selection.ts","source:src/features/gallery/core/settings.ts",@@ -744,17 +745,17 @@]},"limits": {- "brotliBytes": 992321,+ "brotliBytes": 994996,"cssRawBytes": 2181,"fontRawBytes": 221675,- "gzipBytes": 991004,+ "gzipBytes": 993701,"imageRawBytes": 157940,- "initialRawBytes": 2416827,- "largestAssetRawBytes": 745126,+ "initialRawBytes": 2428839,+ "largestAssetRawBytes": 745135,"otherAssetRawBytes": 0,- "ownedRawBytes": 110133,- "requestCount": 74,- "scriptRequestCount": 58+ "ownedRawBytes": 108775,+ "requestCount": 72,+ "scriptRequestCount": 56},"owner": "workbench","remediationTicket": "deepen-widget-registry-loading",diff --git a/invokeai/frontend/webv2/performance/browser-baseline.json b/invokeai/frontend/webv2/performance/browser-baseline.jsonindex eba674d58c..23d502c345 100644--- a/invokeai/frontend/webv2/performance/browser-baseline.json+++ b/invokeai/frontend/webv2/performance/browser-baseline.json@@ -25,11 +25,11 @@"scriptRequestCount": 0,"totalRawBytes": 0},- "domContentLoadedMedianMs": 114,+ "domContentLoadedMedianMs": 109.19999999925494,"id": "launchpad","layoutSwitchMedianMs": 0,- "loadMedianMs": 114,- "longestTaskMaxMs": 69,+ "loadMedianMs": 109.30000000074506,+ "longestTaskMaxMs": 67,"owner": "app","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:launchpad",@@ -38,25 +38,25 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 0,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,"requestCount": 19,- "scriptRawBytes": 1455191,+ "scriptRawBytes": 1456006,"scriptRequestCount": 15,- "totalRawBytes": 1578592+ "totalRawBytes": 1584653},"resourceLimits": {"cssRawBytes": 2181,"fontRawBytes": 23901,"imageRawBytes": 0,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,"requestCount": 19,- "scriptRawBytes": 1469743,+ "scriptRawBytes": 1470567,"scriptRequestCount": 15,- "totalRawBytes": 1594378+ "totalRawBytes": 1600500},- "routeReadyMedianMs": 236.20000000298023,+ "routeReadyMedianMs": 225.69999999925494,"scriptSourceOwnerSet": "launchpad-static","stateProfile": "empty"},@@ -83,11 +83,11 @@"scriptRequestCount": 0,"totalRawBytes": 0},- "domContentLoadedMedianMs": 116.09999999776483,+ "domContentLoadedMedianMs": 110.20000000298023,"id": "launchpad","layoutSwitchMedianMs": 0,- "loadMedianMs": 116.09999999776483,- "longestTaskMaxMs": 72,+ "loadMedianMs": 110.30000000074506,+ "longestTaskMaxMs": 69,"owner": "app","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:launchpad",@@ -96,25 +96,25 @@"cssRawBytes": 2159,"fontRawBytes": 23664,"imageRawBytes": 0,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,"requestCount": 19,- "scriptRawBytes": 1455191,+ "scriptRawBytes": 1456006,"scriptRequestCount": 15,- "totalRawBytes": 1578592+ "totalRawBytes": 1584653},"resourceLimits": {"cssRawBytes": 2181,"fontRawBytes": 23901,"imageRawBytes": 0,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,"requestCount": 19,- "scriptRawBytes": 1469743,+ "scriptRawBytes": 1470567,"scriptRequestCount": 15,- "totalRawBytes": 1594378+ "totalRawBytes": 1600500},- "routeReadyMedianMs": 296,+ "routeReadyMedianMs": 281.80000000074506,"scriptSourceOwnerSet": "launchpad-static","stateProfile": "representative"},@@ -141,38 +141,38 @@"scriptRequestCount": 0,"totalRawBytes": 0},- "domContentLoadedMedianMs": 110.60000000149012,+ "domContentLoadedMedianMs": 105.79999999701977,"id": "editor-minimal","layoutSwitchMedianMs": 0,- "loadMedianMs": 110.60000000149012,- "longestTaskMaxMs": 115,+ "loadMedianMs": 105.89999999850988,+ "longestTaskMaxMs": 113,"owner": "workbench",- "projectSwitchMedianMs": 62.3087400000004,+ "projectSwitchMedianMs": 61.23483999999917,"readyMark": "invokeai:ready:widget:center:preview","remediationTicket": "deepen-widget-registry-loading","resourceBaseline": {"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 96,- "scriptRawBytes": 3048188,- "scriptRequestCount": 90,- "totalRawBytes": 3343378+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 94,+ "scriptRawBytes": 3081128,+ "scriptRequestCount": 88,+ "totalRawBytes": 3381564},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 96,- "scriptRawBytes": 3078670,- "scriptRequestCount": 90,- "totalRawBytes": 3376812+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 94,+ "scriptRawBytes": 3111940,+ "scriptRequestCount": 88,+ "totalRawBytes": 3415380},- "routeReadyMedianMs": 619,+ "routeReadyMedianMs": 600.5999999977648,"scriptSourceOwnerSet": "editor-minimal-static","stateProfile": "empty"},@@ -199,38 +199,38 @@"scriptRequestCount": 0,"totalRawBytes": 0},- "domContentLoadedMedianMs": 111.89999999850988,+ "domContentLoadedMedianMs": 104.40000000223517,"id": "editor-minimal","layoutSwitchMedianMs": 0,- "loadMedianMs": 111.89999999850988,- "longestTaskMaxMs": 134,+ "loadMedianMs": 104.5,+ "longestTaskMaxMs": 118,"owner": "workbench",- "projectSwitchMedianMs": 89.34783099999913,+ "projectSwitchMedianMs": 88.15142399999968,"readyMark": "invokeai:ready:widget:center:preview","remediationTicket": "deepen-widget-registry-loading","resourceBaseline": {"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 96,- "scriptRawBytes": 3048188,- "scriptRequestCount": 90,- "totalRawBytes": 3343378+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 94,+ "scriptRawBytes": 3081128,+ "scriptRequestCount": 88,+ "totalRawBytes": 3381564},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 96,- "scriptRawBytes": 3078670,- "scriptRequestCount": 90,- "totalRawBytes": 3376812+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 94,+ "scriptRawBytes": 3111940,+ "scriptRequestCount": 88,+ "totalRawBytes": 3415380},- "routeReadyMedianMs": 668.8000000007451,+ "routeReadyMedianMs": 642.2000000029802,"scriptSourceOwnerSet": "editor-minimal-static","stateProfile": "representative"},@@ -239,29 +239,29 @@"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 136950,+ "largestAssetRawBytes": 136939,"otherRawBytes": 0,"requestCount": 7,- "scriptRawBytes": 290931,+ "scriptRawBytes": 293074,"scriptRequestCount": 7,- "totalRawBytes": 290931+ "totalRawBytes": 293074},"activatedResourceLimits": {"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 138320,+ "largestAssetRawBytes": 138309,"otherRawBytes": 0,"requestCount": 7,- "scriptRawBytes": 293841,+ "scriptRawBytes": 296005,"scriptRequestCount": 7,- "totalRawBytes": 293841+ "totalRawBytes": 296005},- "domContentLoadedMedianMs": 110.89999999850988,+ "domContentLoadedMedianMs": 105.5,"id": "editor-canvas",- "layoutSwitchMedianMs": 80.19999999925494,- "loadMedianMs": 110.89999999850988,- "longestTaskMaxMs": 129,+ "layoutSwitchMedianMs": 77.89999999850988,+ "loadMedianMs": 105.5,+ "longestTaskMaxMs": 105,"owner": "canvas","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:widget:center:canvas",@@ -270,25 +270,25 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 100,- "scriptRawBytes": 3324885,- "scriptRequestCount": 94,- "totalRawBytes": 3620075+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 98,+ "scriptRawBytes": 3359645,+ "scriptRequestCount": 92,+ "totalRawBytes": 3660081},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 100,- "scriptRawBytes": 3358134,- "scriptRequestCount": 94,- "totalRawBytes": 3656276+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 98,+ "scriptRawBytes": 3393242,+ "scriptRequestCount": 92,+ "totalRawBytes": 3696682},- "routeReadyMedianMs": 798,+ "routeReadyMedianMs": 771.3000000007451,"scriptSourceOwnerSet": "editor-canvas-static","stateProfile": "empty"},@@ -297,29 +297,29 @@"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 136950,+ "largestAssetRawBytes": 136939,"otherRawBytes": 0,"requestCount": 7,- "scriptRawBytes": 290931,+ "scriptRawBytes": 293074,"scriptRequestCount": 7,- "totalRawBytes": 290931+ "totalRawBytes": 293074},"activatedResourceLimits": {"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 138320,+ "largestAssetRawBytes": 138309,"otherRawBytes": 0,"requestCount": 7,- "scriptRawBytes": 293841,+ "scriptRawBytes": 296005,"scriptRequestCount": 7,- "totalRawBytes": 293841+ "totalRawBytes": 296005},- "domContentLoadedMedianMs": 118.59999999776483,+ "domContentLoadedMedianMs": 105.69999999925494,"id": "editor-canvas",- "layoutSwitchMedianMs": 330.9000000022352,- "loadMedianMs": 118.60000000149012,- "longestTaskMaxMs": 405,+ "layoutSwitchMedianMs": 323.80000000074506,+ "loadMedianMs": 105.69999999925494,+ "longestTaskMaxMs": 378,"owner": "canvas","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:widget:center:canvas",@@ -328,25 +328,25 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 100,- "scriptRawBytes": 3324885,- "scriptRequestCount": 94,- "totalRawBytes": 3620075+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 98,+ "scriptRawBytes": 3359645,+ "scriptRequestCount": 92,+ "totalRawBytes": 3660081},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 100,- "scriptRawBytes": 3358134,- "scriptRequestCount": 94,- "totalRawBytes": 3656276+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 98,+ "scriptRawBytes": 3393242,+ "scriptRequestCount": 92,+ "totalRawBytes": 3696682},- "routeReadyMedianMs": 1196.2000000029802,+ "routeReadyMedianMs": 1090,"scriptSourceOwnerSet": "editor-canvas-static","stateProfile": "representative"},@@ -355,29 +355,29 @@"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13252,+ "largestAssetRawBytes": 13254,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14234,+ "scriptRawBytes": 14557,"scriptRequestCount": 3,- "totalRawBytes": 14234+ "totalRawBytes": 14557},"activatedResourceLimits": {"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13385,+ "largestAssetRawBytes": 13387,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14377,+ "scriptRawBytes": 14703,"scriptRequestCount": 3,- "totalRawBytes": 14377+ "totalRawBytes": 14703},- "domContentLoadedMedianMs": 114.89999999850988,+ "domContentLoadedMedianMs": 105.79999999701977,"id": "editor-workflow",- "layoutSwitchMedianMs": 76.30000000074506,- "loadMedianMs": 114.89999999850988,- "longestTaskMaxMs": 122,+ "layoutSwitchMedianMs": 65.70000000298023,+ "loadMedianMs": 105.89999999850988,+ "longestTaskMaxMs": 110,"owner": "workflow","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:widget:center:workflow",@@ -386,25 +386,25 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 96,- "scriptRawBytes": 3048188,- "scriptRequestCount": 90,- "totalRawBytes": 3343378+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 94,+ "scriptRawBytes": 3081128,+ "scriptRequestCount": 88,+ "totalRawBytes": 3381564},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 96,- "scriptRawBytes": 3078670,- "scriptRequestCount": 90,- "totalRawBytes": 3376812+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 94,+ "scriptRawBytes": 3111940,+ "scriptRequestCount": 88,+ "totalRawBytes": 3415380},- "routeReadyMedianMs": 771.0999999977648,+ "routeReadyMedianMs": 725.8999999985099,"scriptSourceOwnerSet": "editor-minimal-static","stateProfile": "empty"},@@ -413,29 +413,29 @@"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13252,+ "largestAssetRawBytes": 13254,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14234,+ "scriptRawBytes": 14557,"scriptRequestCount": 3,- "totalRawBytes": 14234+ "totalRawBytes": 14557},"activatedResourceLimits": {"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13385,+ "largestAssetRawBytes": 13387,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14377,+ "scriptRawBytes": 14703,"scriptRequestCount": 3,- "totalRawBytes": 14377+ "totalRawBytes": 14703},- "domContentLoadedMedianMs": 116,+ "domContentLoadedMedianMs": 105.89999999850988,"id": "editor-workflow",- "layoutSwitchMedianMs": 137.79999999701977,- "loadMedianMs": 116.09999999776483,- "longestTaskMaxMs": 457,+ "layoutSwitchMedianMs": 119,+ "loadMedianMs": 106,+ "longestTaskMaxMs": 358,"owner": "workflow","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:widget:center:workflow",@@ -444,25 +444,25 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 96,- "scriptRawBytes": 3048188,- "scriptRequestCount": 90,- "totalRawBytes": 3343378+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 94,+ "scriptRawBytes": 3081128,+ "scriptRequestCount": 88,+ "totalRawBytes": 3381564},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 96,- "scriptRawBytes": 3078670,- "scriptRequestCount": 90,- "totalRawBytes": 3376812+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 94,+ "scriptRawBytes": 3111940,+ "scriptRequestCount": 88,+ "totalRawBytes": 3415380},- "routeReadyMedianMs": 980.1999999992549,+ "routeReadyMedianMs": 917.3000000007451,"scriptSourceOwnerSet": "editor-minimal-static","stateProfile": "representative"},@@ -471,29 +471,29 @@"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13252,+ "largestAssetRawBytes": 13254,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14234,+ "scriptRawBytes": 14557,"scriptRequestCount": 3,- "totalRawBytes": 14234+ "totalRawBytes": 14557},"activatedResourceLimits": {"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13385,+ "largestAssetRawBytes": 13387,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14377,+ "scriptRawBytes": 14703,"scriptRequestCount": 3,- "totalRawBytes": 14377+ "totalRawBytes": 14703},- "domContentLoadedMedianMs": 113.5,+ "domContentLoadedMedianMs": 104.40000000223517,"id": "editor-gallery",- "layoutSwitchMedianMs": 29.900000002235174,- "loadMedianMs": 113.5,- "longestTaskMaxMs": 116,+ "layoutSwitchMedianMs": 25.199999999254942,+ "loadMedianMs": 104.40000000223517,+ "longestTaskMaxMs": 104,"owner": "gallery","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:widget:center:gallery",@@ -502,25 +502,25 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 96,- "scriptRawBytes": 3048188,- "scriptRequestCount": 90,- "totalRawBytes": 3343378+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 94,+ "scriptRawBytes": 3081128,+ "scriptRequestCount": 88,+ "totalRawBytes": 3381564},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 96,- "scriptRawBytes": 3078670,- "scriptRequestCount": 90,- "totalRawBytes": 3376812+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 94,+ "scriptRawBytes": 3111940,+ "scriptRequestCount": 88,+ "totalRawBytes": 3415380},- "routeReadyMedianMs": 730.1000000014901,+ "routeReadyMedianMs": 702.6000000014901,"scriptSourceOwnerSet": "editor-minimal-static","stateProfile": "empty"},@@ -529,29 +529,29 @@"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13252,+ "largestAssetRawBytes": 13254,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14234,+ "scriptRawBytes": 14557,"scriptRequestCount": 3,- "totalRawBytes": 14234+ "totalRawBytes": 14557},"activatedResourceLimits": {"cssRawBytes": 0,"fontRawBytes": 0,"imageRawBytes": 0,- "largestAssetRawBytes": 13385,+ "largestAssetRawBytes": 13387,"otherRawBytes": 0,"requestCount": 3,- "scriptRawBytes": 14377,+ "scriptRawBytes": 14703,"scriptRequestCount": 3,- "totalRawBytes": 14377+ "totalRawBytes": 14703},- "domContentLoadedMedianMs": 115.19999999925494,+ "domContentLoadedMedianMs": 105.39999999850988,"id": "editor-gallery",- "layoutSwitchMedianMs": 39,- "loadMedianMs": 115.30000000074506,- "longestTaskMaxMs": 128,+ "layoutSwitchMedianMs": 36.900000002235174,+ "loadMedianMs": 105.39999999850988,+ "longestTaskMaxMs": 111,"owner": "gallery","projectSwitchMedianMs": 0,"readyMark": "invokeai:ready:widget:center:gallery",@@ -560,25 +560,25 @@"cssRawBytes": 17572,"fontRawBytes": 23664,"imageRawBytes": 156376,- "largestAssetRawBytes": 737748,- "otherRawBytes": 97578,- "requestCount": 96,- "scriptRawBytes": 3048188,- "scriptRequestCount": 90,- "totalRawBytes": 3343378+ "largestAssetRawBytes": 737757,+ "otherRawBytes": 102824,+ "requestCount": 94,+ "scriptRawBytes": 3081128,+ "scriptRequestCount": 88,+ "totalRawBytes": 3381564},"resourceLimits": {"cssRawBytes": 17748,"fontRawBytes": 23901,"imageRawBytes": 157940,- "largestAssetRawBytes": 745126,- "otherRawBytes": 98554,- "requestCount": 96,- "scriptRawBytes": 3078670,- "scriptRequestCount": 90,- "totalRawBytes": 3376812+ "largestAssetRawBytes": 745135,+ "otherRawBytes": 103853,+ "requestCount": 94,+ "scriptRawBytes": 3111940,+ "scriptRequestCount": 88,+ "totalRawBytes": 3415380},- "routeReadyMedianMs": 884.3999999985099,+ "routeReadyMedianMs": 815.1999999992549,"scriptSourceOwnerSet": "editor-minimal-static","stateProfile": "representative"}@@ -959,6 +959,7 @@"source:src/features/gallery/contracts.ts","source:src/features/gallery/core/image.ts","source:src/features/gallery/core/imagePaths.ts",+ "source:src/features/gallery/core/items.ts","source:src/features/gallery/core/recentImages.ts","source:src/features/gallery/core/selection.ts","source:src/features/gallery/core/settings.ts",@@ -1780,6 +1781,7 @@"source:src/features/gallery/contracts.ts","source:src/features/gallery/core/image.ts","source:src/features/gallery/core/imagePaths.ts",+ "source:src/features/gallery/core/items.ts","source:src/features/gallery/core/recentImages.ts","source:src/features/gallery/core/selection.ts","source:src/features/gallery/core/settings.ts",diff --git a/invokeai/frontend/webv2/vite.config.mts b/invokeai/frontend/webv2/vite.config.mtsindex 9b0632fd5e..d679d0db9c 100644--- a/invokeai/frontend/webv2/vite.config.mts+++ b/invokeai/frontend/webv2/vite.config.mts@@ -30,6 +30,16 @@ export default defineConfig({return 'shared';}+ // Mixed-gallery item helpers cross the eager editor shell and its+ // lazy Gallery/Preview chunks. Keep them with the already-eager+ // gallery state projection instead of emitting one extra request.+ if (+ id.endsWith('/features/gallery/core/items.ts') ||+ id.endsWith('/features/gallery/ui/galleryStateView.ts')+ ) {+ return 'gallery-state';+ }+if (!id.includes('/node_modules/')) {return undefined;}