Conflicts resolved in 16 files. Where main's new shell, classic page and
tests depend on a wire format or a signature the cleanup had changed, main
wins; where main only extended code the cleanup had restructured, main's
change is carried over into the new structure:
- MCP HTTP server: the poll response keeps main's separate export fields
(exportFormat, exportXml, exportOptions, exportId with a random id)
instead of the cleanup's pendingExport object; the classic preview page
is main's version
- MCP index: start_session keeps the cleanup's structure and gains main's
BROWSER=none, previewUrl and same-origin note; get_selection is written
in the registerTool style; create_new_diagram keeps the cleanup's
helpers with main's comment
- history: addHistory takes main's source parameter and returns the index
again (main's signature)
- new-diagram: the cleanup's prepareNewModel split plus main's page ids
for diagrams without one
- diagram context: one ExportResult type (main's, with optional fields)
for both the tagged exports and main's requestExport; the cleanup's
single export resolver stays
- versions store and version-text test: main's VersionItem base type and
describeChangeSummary rename, without the legacy history conversion the
cleanup removed
- dictionaries: main's shell section added; openFileHint stays removed
(unused on main too)
- tests: the server wiring test keeps the SDK client and gains main's
session cases; the HTTP server test uses main's export fields; the DOM
polyfill comes from tests/setup.ts
- package.json: main's postcss kept, the cleanup's removals kept; lockfile
regenerated
- tests/e2e/lib: openApp(page, { path, config }), MODEL_CONFIGS_KEY,
savedModelConfigs, settingsDialog, chunkedReplies, sse() and
toolCallEvents() replace about 70 copies of goto + wait for iframe,
three local openApp functions, 14 window.fetch overrides and the
Node-side SSE serialisers; unused fixtures removed
- delete theme, save, history, model-config, upload and copy-paste
specs (the copy-button test moves to chat.spec.ts); trim
iframe-interaction, history-restore, keyboard and smoke to tests that
can fail; file-upload asserts on the preview image
- settings-review-fixes.spec.ts split by topic into settings-bedrock,
settings-tabs-sync and settings-providers
- unit tests use vi.stubEnv with unstubEnvs: true instead of
hand-written process.env save and restore loops
- package-lock.json regenerated for the removed dependencies, dotenv and
the devDependency move of @opennextjs/cloudflare
- lib/admin: SettingType and getSettingsPath are file-internal
- components/chat/chat-engine.tsx: comment no longer mentions click counts
- components/model-selector.tsx uses Dialog, Command and Tooltip
directly; delete components/ai-elements/model-selector.tsx and
components/button-with-tooltip.tsx; one renderGroups for both lists;
no "Server · " prefix round trip
- components/ui: drop CommandDialog, CommandShortcut and six unused
shadcn exports
- model-config-dialog: no type-to-confirm on provider delete;
provider-credentials-fields: drop footer and bedrockApiKey
- hooks/use-model-config.ts and lib/types/model-config.ts: remove the
2025-12 single-provider migration, resetConfig, selectedModel and
fields nothing reads
- components/chat/TemplateFormDialog.tsx replaces the create and edit
dialogs; TemplatePanel drops the setInput fallback, the
templatesChanged listener, dictionary fallbacks and formatLastUsed;
lib/template-storage.ts drops getTemplate, clickCount and indexes
- reasoning.tsx becomes one component; shimmer uses a CSS keyframe
(motion and @radix-ui/react-use-controllable-state removed)
- error-toast.tsx deleted in favour of toast.error; ValidationCard
drops the idle status; dev-xml-simulator uses English literals
- admin: no enum setting type, shared types from lib/admin
(AdminProviderInput stays exported for that), ENABLE_HISTORY_XML_REPLACE
entry removed
- app/globals.css: drop check-pop, --ease-spring, --duration-normal
and the shadow aliases
- dictionaries: 81 unused keys removed from all four languages
lib/system-prompts.ts takes the three Styles paragraphs from
styleRules() in packages/mcp-server/src/xml-examples.ts; the generated
prompt is byte-identical. packages/mcp-server/tests/load-diagram.test.ts
drops its own DOM polyfill setup now that vitest installs it once.
- index.ts: registerTool() does the session check, try/catch and the
write queue for all 15 tools; fail()/ok(), syncFromBrowser(),
commitDocument() and describePages() replace the copied blocks; drop
pickPageSelector, currentSession.version, the input ?? {} defaults;
add_page reuses prepareNewModel() split out of prepareNewDiagram
- xml-validation.ts: drop the hand-written syntax checks that saxes
already reports, MAX_XML_SIZE and the stale header
- http-server.ts: one pendingExport object, no unread response fields,
no CORS/OPTIONS branch for same-origin requests, fewer exports
- diagram-operations parseNewCell(), addHistory returns void,
normalizeToMxfile without host, foldCells without layer, expandStyles
removed, unused preview.css rule removed, no .d.ts output
- xml-examples.ts styleRules() shares the Styles paragraphs with the
web prompt
- tests: setupFiles installs the DOM polyfill once, server-wiring uses
the SDK client, mcp-core.test.ts drops the cases MCP tests already
cover
- stores/versions-store.ts, hooks/use-session-manager.ts,
lib/session-storage.ts: remove the diagramHistory conversion layer,
the localStorage chat migration and the empty templates store
- stores/canvas-store.ts, lib/drawio/editor-bridge.ts: remove the
pages list nothing read
- components/chat/chat-engine.tsx: use the context's chartXMLRef and
latestSvgRef instead of local copies, subscribe to one settings field,
stop prefetching quota limits (lib/use-quota-manager.tsx takes the
values from the 429 body), readDiagramFile delegates to the MCP
loader (which now strips XML prologs and accepts <svg:svg>)
- contexts/diagram-context.tsx: one requestTaggedExport path for
thumbnails, validation, fetch and save; fetchDiagramXml replaces
handleExport plus the exported resolver map
- hooks/use-validate-diagram.ts and app/api/validate-diagram: plain
fetch returning JSON instead of a streamed object nobody consumed
- hooks/use-diagram-tool-handlers.ts: drop the DEBUG blocks; canvas
vars inheritance lives in placeOnPage (lib/diagram-pages.ts)
- lobby-hero, icon-button, drawio-frame: remove unreachable branches
and unused props
- app/[lang]/about/page.tsx renders en, zh and ja (zh-Hant falls back
to zh) from one JSX tree with per-language texts and generateMetadata;
delete the cn/ and ja/ copies and redirect their old URLs
- app/[lang]/layout.tsx: use hasLocale, an OG locale table, and real
zh/ja title and description
- components/icons/github.tsx replaces react-icons and lucide's
deprecated Github icon
- quota-limit-toast: read the dictionary keys directly, shadow-float
- Cloudflare: defineCloudflareConfig({}) without R2, no r2_buckets, no
dev-time OpenNext init, cf-typegen script removed,
@opennextjs/cloudflare moves to devDependencies, docs updated
- lib/system-prompts.ts: delete the extended prompt kept only to reach
the 4096-token cache threshold of two old Claude models; describe the
current canvas-first UI in the App Features section
- app/api/chat/route.ts: remove the server-side example cache (the
browser answers examples itself), the ENABLE_HISTORY_XML_REPLACE
option and its helper, the unread messageMetadata fields; the
DEBUG_LLM_PAYLOAD blocks become one describeMessages summary
- app/api/log-feedback and log-save share scoreLatestTrace in
lib/langfuse.ts
- app/api/admin/test-model and validate-model call a shared
testModelConnection() instead of one route faking a request to the
other and passing trust through the body
- lib/dynamo-quota-manager.ts reads the failing item from the
conditional update instead of a second GetItem
- lib/ai-providers.ts: geminiThinkingOptions helper for the google and
vertexai cases, drop the unused fourth resolveBaseURL parameter
- edge-functions: always stream, shrink messageSchema, drop model
aliases nothing sends
- delete app/api/chat/xml_guide.md, parseOutputTokenLimit, unused type
exports and export keywords on file-internal symbols
- env.example: drop variables nothing reads, document the quota,
validation and analytics variables, mention the apiKeyEnv array form
(also in docs/*/ai-providers.md)
- delete electron/settings, the settings preload and window, the
config-presets IPC channels, the Configuration menu and the preset
watcher in scripts/electron-dev.mjs; config-manager.ts keeps only the
user locale (still read from config-presets.json so the saved
language survives)
- electron/main/env-loader.ts parses .env with dotenv instead of a
hand-written parser; electron:compile bundles dependencies
- drop the unreachable development branches in port-manager.ts and
next-server.ts, the duplicated locale normalisation in menu-i18n.ts,
the unused electronAPI members, resources/entitlements.mac.plist
- scripts/copy-dereferenced.cjs shared by afterPack and
prepare-electron-build
- CI: delete ci.yml, move type check and concurrency into test.yml,
Node 24 everywhere, docker-build only on main
- remove unused dependencies (@xmldom/xmldom, remark-gfm,
@anthropic-ai/tokenizer, @testing-library/user-event, concurrently,
wait-on, eslint, eslint-config-next, @vitest/coverage-v8, shx),
.eslintrc.json and the vitest coverage block
- lib/utils.ts: remove convertToLegalXml and replaceNodes; the streaming
preview now goes through wrapCellsInModel, autoFixXml and
replacePageModel like the final commit path does
- lib/utils.ts: extractDiagramXML reuses extractSvgEmbeddedXml,
pageElement and decompressPageContent instead of hand-written SVG
parsing and pako inflation
- lib/use-file-processor.tsx: messages parameter is required, drop the
English default texts only tests used
- hooks/use-dictionary.ts, lib/i18n/utils.ts: drop duplicate default
exports nobody imported
- tests updated accordingly
2026-10-12 08:05:13 +09:00
2 changed files with 407 additions and 658 deletions
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.