Skip to content

feat(ui): show JSON diffs and truthful save and apply states - #47

Merged
ts-76 merged 24 commits into
mainfrom
fix/json-editor-ui-43
Oct 3, 2026
Merged

ts-76 merged 24 commits into
mainfrom
fix/json-editor-ui-43

Conversation

@ts-76

@ts-76 ts-76 commented Oct 2, 2026 •

Copy link
Copy Markdown
Owner

Visual, Raw and Diff share the current JSON draft. Diff compares against acknowledged saved configuration. Display Save, unsaved edits, Apply progress/partial failures and current/stale Preview separately. Prioritize active Saving over unconfirmed disk status. Add real free-form provider/category inputs with current-draft datalist suggestions; retain the closed agents/claude enum for skill providers.

Closes #43. Keep the small compatibility adapter for the published Visual JSON components and fix DiffView's formatting contract. Tests exercise real numeric/boolean/array/enum editing and DiffView, plus late responses, drafts, pending Save, custom suggestions and partial outcomes. Existing Copilot findings are fixed and resolved.

Based on merged #44/#45/#46 and audited #39. Resolve UI locks by retaining audited dependencies, UI tests and svelte-check; preserve all tested JSON editor changes when aligning with main. Automatic tags/npm publication remain disabled.

Validation at 041d2dab0d58ce09c67f4937ac30eccf842b3c5e: frozen root/UI installs, lint, root/UI TypeScript, svelte-check (0 errors/warnings), 103 CLI/API/release tests + 29 UI tests, full CLI/UI build and real tarball checks pass. Final ancestry merges preserve the tested source tree. Root Bun/UI Bun/root npm audits are all 0. Exact-head CI37119195114 and Security37119195122 (audit + CodeQL) both succeed.

Previous built browser checks verified Raw edits, Diff and Save. Reload confirmation interrupted automation, so subsequent browser Apply is not claimed verified; Apply states and real HTTP/API behavior are covered by automated tests. Fresh Copilot review remains unavailable from its earlier quota exhaustion.

@socket-security

socket-security Bot commented Oct 2, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addedsvelte-check@​4.7.69910010097100

View full report

@ts-76
ts-76 marked this pull request as ready for review October 3, 2026 09:31
Copilot AI balanced review requested due to automatic review settings October 3, 2026 09:32

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Repository-field suggestions are not rendered by the published editor, and an active Save can display the wrong status.

Review effort: Balanced
Findings: 2 Medium severity

Open (2)
What changed in this PR

Adds shared JSON draft diffing, clearer Save/Apply/Preview states, schema-driven choices, and UI validation.

Changes:

  • Adds Diff view and operation-state reporting.
  • Adds dynamic choices and Visual JSON compatibility coverage.
  • Adds Svelte checking to CI and documentation.
File Description
.github/​workflows/​ci.yml Runs Svelte checks.
docs/​editor-ui.md Documents editor behavior.
src/​config/​build-json-schema.ts Adds provider enum metadata.
ui/​bun.lock Locks Svelte-check dependencies.
ui/​package.json Adds the Svelte check command.
ui/​src/​App.svelte Adds Diff and operation states.
ui/​src/​editor-schema.ts Derives draft choices.
ui/​src/​styles.css Styles new UI elements.
ui/​src/​visual-json-internal.ts Updates DiffView compatibility.
ui/​test/​App.test.ts Tests editor state behavior.
ui/​test/​VisualJson.test.ts Tests published components.
ui/​tsconfig.json Configures adapter type resolution.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread ui/src/App.svelte
Comment thread ui/src/editor-schema.ts
@ts-76
ts-76 requested a balanced review from Copilot October 3, 2026 09:39

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@ts-76
ts-76 changed the base branch from fix/editor-draft-retention-41 to main October 3, 2026 11:17
@ts-76
ts-76 merged commit 3b885d3 into main Oct 3, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

visual-jsonを活用してJSON編集UIと状態表示を整理する

2 participants