Skip to content

Duplicate, delete dialogs and save status in the form document (BITS-282 part d) - #277

Closed
PhilReinking wants to merge 12 commits into
feat/bits-282c-keyboard-movefrom
feat/bits-282d-wire-phase-1
Closed

PhilReinking wants to merge 12 commits into
feat/bits-282c-keyboard-movefrom
feat/bits-282d-wire-phase-1

Conversation

@PhilReinking

@PhilReinking PhilReinking commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Last part of the document editor: Duplicate, the delete dialogs and the save status work in the document, and the docs describe the new editor.

Fixes BITS-282

  • Duplicate is in the question menu, not on groups (the server can't copy them). The copy opens below; a waiting change is saved first.
  • An opened question gets the cursor at the end of its text.
  • Delete… opens the dialog from Ask before deleting a question, naming its answers and the rules that use it #269, naming a question by number and text. Focus goes to the next row, else the one above, else Add question.
  • useDeleteBlock().confirm resolves once the server answered, so focus moves after the delete.
  • Save status sits in the top bar at a fixed width so the bar doesn't shift. Icons with a tooltip under 1280 px; under 1024 px Retry stays in the red bar.
  • Docs: editor, outline (was Storyboard, same address), blocks and logic pages.

Tested: vitest, lint, vue-tsc, build, docs build; by hand at 1440, 1024, 390, 360; the review fixes at 1440, 1024, 390. Save-first and cursor tests fail without the fix.

Not tested: a form with real answers (faked counts in the browser). No CI: stacked PR.

🤖 Generated with Claude Code

PhilReinking and others added 6 commits October 13, 2026 02:54
The copy goes right after the question and opens with the cursor in
its text. A change still waiting to save in the open question is sent
first, so the copy has it. Groups have no Duplicate: the server can't
copy them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The menu's Delete opens the delete dialog that names the answers and
the rules that stop working. After the delete, focus goes to the next
row, else the one above, else Add question; a failed delete keeps it
on the row.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The editor's "Saving…", "Saved" and "Not saved" with Retry now sit in
the top bar, in its light grey as in the board; under 1280 px only the
icons show and Retry is 44 px tall on touch screens.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The editor, outline (was Storyboard, same address), block and logic
pages now describe the document, the open question, its menu, moving
by keyboard and touch, the delete dialog and the save status.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Under 1024 px the top bar showed "Retry" next to the warning icon and
squeezed the form's name to one letter. The red bar above has Retry
and stays while a save failed, so the top bar keeps only the icon.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@PhilReinking PhilReinking left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

OK at 4c262ff. No CI (stacked), local runs: Vitest 364, lint, vue-tsc, build and the docs build pass. The save-first test fails without the fix. On a 4-worker server the copy kept text typed right before Duplicate, also in a group and after reload. Duplicate and delete work by keyboard and touch. After a delete the cursor goes to the next row or Add question; a failed delete keeps it on the row.

PhilReinking and others added 6 commits October 13, 2026 03:34
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A copy from Duplicate opened with the cursor before its text.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A copy from Duplicate has the same text, so the text alone can't tell
the two apart.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
It said "Your change to question N wasn't saved", but Duplicate isn't a
change to that question.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
It said "Your change to question N wasn't saved", but Delete isn't a
change to that question.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@PhilReinking PhilReinking left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

OK at e859a30. No CI (stacked), local runs: Vitest 368, lint, vue-tsc and the build pass. 8 new or changed tests fail on 4c262ff. In the browser at 1440, 1024 and 390 the top bar stays put through saving, saved and idle. A question opens with the cursor at the end, and a click at the start of its text keeps that spot. A copy's delete dialog says "Question 2 (…)", and failed deletes and copies say what failed.

@PhilReinking

Copy link
Copy Markdown
Contributor Author

Landed in main with #282 (the editor rebuild as one PR); this PR's commits are part of it.

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.

1 participant