Ask Save or Don't save, and show useful status facts

Phase 5-7.

- A changed tab asks Save, Don't save, or Cancel through the native
  dialog, instead of OK and Cancel to discard.
- The conflict banner uses --rs-warn with a warning icon. Keep my
  edits is the primary choice and comes first. Use disk version comes
  last, in the error color. The banner wraps in a narrow pane.
- The status bar shows the save state, the line and column, the word
  count, the line endings, and the view. It shows the watch mode only
  when it polls a network folder.
- The outline and the document facts follow the active tab. A tab
  without a document has no outline and no document facts.
- Tables: only formula cells have a hover hint, so no hint covers the
  next cell. The table adds no gap above its control area. The add
  controls show while a cell has focus.
- The plugin review marks Install and enable as the primary action. The
  other choice is Install, keep disabled.
- Read follows CommonMark soft breaks. Settings, General, Keep line
  breaks shows each source line break. The table preview and cell
  editors of Write keep their line breaks, because their editing
  depends on them.
- Catalog rows in French, Japanese, and Simplified Chinese.
- Docs: UI-053, the user guide, and plugins.md.

Tests: the new layout/plainFixes, the keepLineBreaks cases in the
settings unit tests, and the new install button name.
This commit is contained in:
Knotty Wyvern
2026-10-28 22:06:13 -07:00
parent 0fdc991b2e
commit eeddd880e1
24 changed files with 294 additions and 70 deletions
+15
View File
@@ -980,3 +980,18 @@ Native shell, background image, and desktop acceptance remain open.
- Evidence: `tests/smoke/layout/panesAndSettings.smoke.mjs`.
- Replaces / replaced by: The fixed side panes of narrow windows, and the Save button of the browser settings.
- Limits: At startup, the saved layout applies as it is, also in a narrow window. Panes give way only when the window becomes narrower. Browser checks use desktop service mocks. The SDK release that publishes the new icon names is a separate step.
### UI-053 — Close prompts, conflicts, the status bar, tables, and line breaks
- Type: Rule change
- Date: 2026-10-28
- Status: Implemented for user review
- Decision source: Owner decisions 11 and 14 of 2026-10-27 (interface review issues 10, 16, 17, 18, 23, and 24), stage 5-7.
- Previous rule: A changed tab closed after "Discard unsaved edits? OK/Cancel", with no Save. The conflict banner had no status color or icon, and Use disk version came first in the same style as the other choices. The status bar showed the path, "native watch", and the mode. A tab without a document kept the outline of the last note. Every table cell showed its address in a tooltip over the next cell, tables had about 70 pixels above them, and their add controls showed only on hover. The plugin review had three equal buttons. Read showed each source line break.
- New rule: A changed tab asks Save, Don't save, or Cancel. The conflict banner uses `--rs-warn` with a warning icon. Keep my edits is the primary choice and comes first, and Use disk version comes last in the error color. The status bar shows the save state, the line and column, the word count, the line endings, and the view, and it shows the watch mode only when it polls. The outline and the document facts follow the active tab. Only formula cells have a hover hint, the table adds no gap above its control area, and the add and drag controls show while a cell has focus. Install and enable is the primary plugin action, and the other choice is Install, keep disabled. Read follows CommonMark soft breaks, and **Keep line breaks** in Settings → General shows each source line break.
- Reason: The safe choice must be the easy choice. The status bar must show useful facts. A hint must not hide text.
- Scope: Tab closing, the conflict banner, the status bar, the outline, Write tables, the plugin install review, and Read.
- Shared implementation: `closeTabs` in `Workbench.svelte`, `DocumentArea.svelte`, `StatusBar.svelte`, `tableControls.ts`, `PluginManager.svelte`, `reading.css`, and `fileTitle.ts` (the document settings).
- Evidence: `tests/smoke/layout/plainFixes.smoke.mjs` and `tests/unit/layout/settings.spec.ts`.
- Replaces / replaced by: The OK and Cancel close prompt, and `white-space: pre-line` for every Read paragraph.
- Limits: The word count splits on spaces and counts each Han, Hiragana, and Katakana character as one word. The close prompt uses the native dialog, which browser checks mock. The table control area keeps its 26-pixel padding, because the drag handles need it. The drag handles still show only on hover: showing every row and column handle on focus was too busy. The line break setting applies to Read. The table preview and cell editors of Write keep each line break, because their editing depends on it.
+2 -2
View File
@@ -16,7 +16,7 @@ Get the release ZIP of the plugin, such as `runestone.terminal-<version>.zip`. D
2. Choose **Install plugin ZIP**.
3. Select one or more ZIP files. You can select up to 100 at a time.
4. Review the name, author, version, source, and destination of each plugin.
5. Choose **Install and enable**, or choose **Install** to install the plugin disabled.
5. Choose **Install and enable**, or choose **Install, keep disabled**.
RuneStone copies each plugin into its application data folder and keeps your ZIP unchanged.
The review and installation do not run plugin code.
@@ -65,7 +65,7 @@ RuneStone downloads only the attached ZIP. It does not clone or build the reposi
3. In **Release tag**, enter a tag. Leave it empty to get the latest stable release.
4. For a private repository, enter a Gitea **Access token** with read access to the repository.
5. Choose **Review release**.
6. Review the package. Choose **Install**, **Install and enable**, or, for an installed plugin, **Apply packages**.
6. Review the package. Choose **Install and enable**, **Install, keep disabled**, or, for an installed plugin, **Apply packages**.
To install a prerelease, enter its tag. The release must have exactly one plugin ZIP attached. Source archives and branch links do not work.
Use HTTPS for a remote server. HTTP sends the token and the package without encryption.
+6 -4
View File
@@ -82,7 +82,7 @@ Each document pane has one view control with three choices, and a **Split** butt
Press Ctrl+E to switch between Write and Source. Press Ctrl+Shift+E to switch between Read and the editor. The tab menu has the same choices under **View**.
In a narrow pane, the control shows only icons. Hover over an icon, or focus it with the keyboard, to see its name. The arrow keys move the choice.
The status bar shows the current view. The bar above the document shows the folder of the file, and the tab shows the file name.
The status bar shows the save state, the line and column of the cursor, the word count, the line endings (LF or CRLF), and the current view. For a folder on a network drive, it also shows **Polling for changes**. A tab without a document, such as the theme editor, has no outline and no document facts. The bar above the document shows the folder of the file, and the tab shows the file name.
Write keeps your Markdown source, frontmatter, and Windows line endings. Read shows frontmatter in a collapsed **Properties** section.
Select a checkbox to complete a task. Copy code blocks without their Markdown fences with the **Copy code** button.
In a list item, press Tab to make a nested item. Press Shift+Tab to move it one level up. RuneStone renumbers the list.
@@ -93,6 +93,8 @@ To rename a note, select its title in Write and type a new name. Press Enter or
The file keeps its folder, extension, contents, and edit history.
To hide the title in Write and Read, turn off **Settings → General → File name title**. Then use F2 or **Rename…** in the tab menu.
Read follows CommonMark: a single line break inside a paragraph is a space. To show each line break of the source in Read, turn on **Settings → General → Keep line breaks**.
### Links and backlinks
- Ctrl+click a link in Write or Source. In Read, a normal click follows the link.
@@ -164,7 +166,7 @@ Press Ctrl+S to save the active file immediately.
To change auto-save, open **Settings → General**. Set an interval from 1 to 300 seconds, or turn auto-save off.
**Restore defaults** sets auto-save on with a 5-second interval.
If you close a tab or window with unsaved edits, RuneStone asks before it discards them or ends terminal sessions.
If you close a tab with unsaved edits, RuneStone asks whether to save them: **Save**, **Don't save**, or **Cancel**. If you close a window with unsaved edits or running terminal sessions, RuneStone asks before it closes.
Unsaved text and terminal sessions do not survive a restart or a crash.
## Resolve file conflicts
@@ -178,9 +180,9 @@ Then choose one action:
| Action | Result |
| --- | --- |
| **Use disk version** | Replaces your edits with the file on disk. |
| **Keep my edits** | Keeps your edits. The next save replaces the file on disk. |
| **Save a copy** | Saves your edits to a new file. |
| **Use disk version** | Replaces your edits with the file on disk. The button is last, in the error color. |
If the file is deleted, the tab keeps your text. Use **Save a copy**, or **Retry** after the file is back.
@@ -194,7 +196,7 @@ Settings apply at once to all workspaces on this computer and update all open wi
| Category | Settings |
| --- | --- |
| General | Display language, **File name title**, **Table formulas**, **Show .runestone folder**, and auto-save |
| General | Display language, **File name title**, **Keep line breaks**, **Table formulas**, **Show .runestone folder**, and auto-save |
| Appearance | Color theme, transparency, background image, and custom themes. See [Appearance and custom themes](guides/themes.md). |
| Plug-ins | Install, enable, update, and remove plugins. See [Install and manage plugins](plugins.md). |
| Browser | Homepage, search engine, profiles, ad blocking, and web data |