reladraw 0.26.1 → 0.27.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,7 +15,7 @@ That matters here specifically. You can't see the SVG you produced. With auto-la
15
15
 
16
16
  ## Check it is installed, and the same version as this skill
17
17
 
18
- This skill teaches reladraw 0.26.1. Once per session, before the first render, run:
18
+ This skill teaches reladraw 0.27.0. Once per session, before the first render, run:
19
19
 
20
20
  ```
21
21
  reladraw --version
@@ -1,4 +1,4 @@
1
- # Syntax reference — 0.26.1
1
+ # Syntax reference — 0.27.0
2
2
 
3
3
  What the language accepts. The changelog at the end lists what changed in each published version; 0.17.0's changes are large, and its entry has a table of every old spelling and what to write instead.
4
4
 
@@ -1288,13 +1288,17 @@ The output is a standalone SVG: every picture is drawn into it as path data, nev
1288
1288
  reladraw render arch.reladraw --page
1289
1289
  ```
1290
1290
 
1291
- `--page` writes `arch.html`: one self-contained file, for opening in a browser, attaching or committing, that needs nothing running and fetches nothing. The page is in the diagram's own colors, so a dark diagram doesn't sit on a white page, and it is headed with `diagram title:`, or the file's name when there is none. Under the title it says which file it was drawn from and when, such as "drawn from arch.reladraw, 2026-11-05 14:32": the page is a snapshot of the file, and is behind it once the file is edited, until it is rendered again. Drag to pan, or press `g` to grab the diagram and pan it with the arrow keys or `h` `j` `k` `l` (Shift for bigger steps, `g` or Escape to let go); scroll, pinch or double-click to zoom; Fit shows the whole diagram and 100% returns it to its own scale. The zoom is always shown, with "Fit" beside it while the whole diagram is in view. There is a full-screen button. The Save menu saves the page itself, as it was written rather than at its current zoom; the `.reladraw` source it was drawn from; or the picture as an SVG or a PNG, as `render` would draw it; or copies the SVG. Each is named after the source file: `arch.html`, `arch.reladraw`, `arch.svg`, `arch.png`. In Chrome and Edge it asks where to save; other browsers put the file with their downloads. The findings are listed beside it in a panel that folds away, and clicking one lights up what its line drew. A box's or a line's name shows under the pointer. The theme picker draws the diagram in another theme, as `--theme` would, keeping the view and the selection; a page or text color the file states holds in every theme, and Save SVG, PNG and Copy SVG take the theme shown. It starts on "Diagram's theme", the one the file names (or dark), which follows the file when it is rendered again. A theme picked by name is the reader's: it holds on every reladraw page in that browser, whatever the file says, until "Diagram's theme" is picked again.
1291
+ `--page` writes `arch.html`: one self-contained file, for opening in a browser, attaching or committing, that needs nothing running and fetches nothing. The page is in the diagram's own colors, so a dark diagram doesn't sit on a white page, and it is headed with `diagram title:`, or the file's name when there is none. Under the title it says which file it was drawn from and when, such as "drawn from arch.reladraw, 2026-11-05 14:32": the page is a snapshot of the file, and is behind it once the file is edited, until it is rendered again. Drag to pan, or press `g` to grab the diagram and pan it with the arrow keys or `h` `j` `k` `l` (Shift for bigger steps, `g` or Escape to let go); scroll, pinch or double-click to zoom; Fit shows the whole diagram and 100% returns it to its own scale. The zoom is always shown, with "Fit" beside it while the whole diagram is in view. There is a full-screen button. The Save menu saves the page itself, as it was written rather than at its current zoom; the `.reladraw` source it was drawn from; or the picture as an SVG or a PNG, as `render` would draw it; or copies the SVG. Each is named after the source file: `arch.html`, `arch.reladraw`, `arch.svg`, `arch.png`. In Chrome and Edge it asks where to save; other browsers put the file with their downloads. The findings are listed beside it, and clicking one lights up what its line drew. A box's or a line's name shows under the pointer.
1292
1292
 
1293
- The side panel can be hidden with the Panel button or `p`, and then stays hidden whatever is selected. With Auto-hide ticked it shows only while something is selected or the findings are open, and the findings start folded. Both choices are remembered by the browser for every page.
1293
+ **The View menu** holds the page's settings, each row a switch that says on or off. **Theme** opens a list of themes, and draws the diagram in the one picked, as `--theme` would, keeping the view and the selection; a page or text color the file states holds in every theme. It starts on "Diagram's theme", the one the file names (or dark), which follows the file when it is rendered again. A theme picked by name is the reader's: it holds on every reladraw page in that browser, whatever the file says, until "Diagram's theme" is picked again. **Side panel** shows or hides the panel beside the drawing, which then stays hidden whatever is selected. **Auto-hide panel** shows it only while something is selected or the findings are open, and the findings start folded. Both are remembered by the browser for every page. **Findings**, with their count, open or fold the findings in the panel. **Guides**, with their count, draws the [guides](#guides) as `--guides` does; it starts as the file or `--guides` says, and a change lasts for that page only. Save SVG, PNG and Copy SVG take the theme and the guides as shown.
1294
1294
 
1295
- **A click on a box or a line selects it**, and never follows a link. The selection is amber; what feeds it is green and what it feeds is red, the lines dashed and moving the way they run; the rest dims. A line runs from the end without an arrowhead when only one end has one, and otherwise from the end written first. The panel beside the drawing names the selection and lists its links, each with its badge, and the boxes it comes from and goes to; a link opens in a new tab, and a box selects it. One line out lights by default, and the panel's button lights everything upstream and downstream. Its description, if it has one, comes last ([Descriptions](#descriptions)). A box with links underlines its text under the pointer. A click on the background or Escape clears the selection.
1295
+ **From the keyboard**, `m` reaches the bar: it is ringed, each control shows its letter, and a strip under it names where the keys are and which keys work there. `v` opens View, `s` opens Save, and `f` goes full screen. In a menu a row's letter does what the row does, and the menu stays open, so several can be changed in turn: in View, `t` theme, `p` side panel, `a` auto-hide, `f` findings and `g` guides; in Save, `p` this page, `r` the source, `s` SVG, `n` PNG and `c` Copy SVG. The arrow keys and Enter work too. In the theme list the arrows draw the diagram in each theme as they reach it, and Enter keeps the one reached. Backspace steps back one level at a time: from the theme list to View, from a menu to the bar, from the bar to the diagram, and then lets go of a grab, a lit finding and the selection in turn. Escape goes straight back to the plain diagram from anywhere: every menu closes, a theme tried and not kept is dropped, and a grab, a lit finding and the selection are all cleared. With the menus closed, `p` shows or hides the side panel and `f` goes full screen; `+` `-` `0` `1` zoom at every level.
1296
1296
 
1297
- Keys: `+` and `-` zoom, `0` fits, `1` is actual size, `f` is full screen, `p` shows or hides the side panel, Escape clears the selection.
1297
+ **A click on a box or a line selects it**, and never follows a link. The selection is amber; what feeds it is green and what it feeds is red, the lines dashed and moving the way they run; the rest dims. A line runs from the end without an arrowhead when only one end has one, and otherwise from the end written first. The panel beside the drawing names the selection and lists its links, each with its badge, and the boxes it comes from and goes to; a link opens in a new tab, and a box selects it. One line out lights by default, and the panel's button lights everything upstream and downstream. Its description, if it has one, comes last ([Descriptions](#descriptions)). A box with links underlines its text under the pointer. A click on the background, Escape or Backspace clears the selection.
1298
+
1299
+ **Selecting from the keyboard**: `s` puts a letter on every box and line, and typing a letter selects that thing. Things in view get the one-letter labels; past 26, the rest take two letters. `/` starts a filter that narrows what gets a letter, live as it is typed: a plain word matches a box's or a line's text, `is:node`, `is:edge` and `is:container` match a kind, and `style:synced` matches what wears that style. Words combine, so `/is:edge rclone` letters only the lines whose text says rclone. Enter ends the filter and the letters pick again, or selects the match at once when there is only one. With something selected, `n` letters what is one line away (from a box, its lines and the boxes at their other ends; from a line, its two ends), `i` letters the boxes inside the selected box and the box it sits in, and `l` letters its links, which a letter opens in a new tab: on the side panel's rows when the panel is shown, and in a small list beside the selection when it is hidden. Backspace steps back a letter, then out of the filter, then out; Escape clears everything. A picked thing out of view is brought into it.
1300
+
1301
+ Keys: `+` and `-` zoom, `0` fits, `1` is actual size, `f` is full screen, `p` shows or hides the side panel, `s` and `/` select, `n` `i` `l` step from the selection, Escape clears the selection.
1298
1302
 
1299
1303
  ### Formatting
1300
1304
 
@@ -1416,6 +1420,11 @@ Designed and absent from the code.
1416
1420
 
1417
1421
  Pre-1.0, so the minor number is where a breaking change goes. Every removal is refused by name with the replacement quoted, rather than dropped in silence: an older file stops with an error saying what to write instead.
1418
1422
 
1423
+ **0.27.0**
1424
+
1425
+ - **The `--page` page selects from the keyboard.** `s` puts a letter on every box and line and a letter selects it; `/` filters what gets a letter by text, `is:node`, `is:edge`, `is:container` or `style:`; with something selected, `n` letters what is one line away, `i` what is inside it and the box it sits in, and `l` its links. See [A page for looking at a diagram](#a-page-for-looking-at-a-diagram).
1426
+ - **The `--page` page has a View menu**, and its bar keeps only the zoom, Full screen, Save and View. The theme, the side panel, auto-hide and the findings moved into View, each a switch that says on or off, and View gained **Guides**, which draws the diagram's guides as `--guides` does. **`m` reaches the menus from the keyboard**: each control shows its letter, a strip names where the keys are, Backspace steps back one level and Escape goes straight back to the plain diagram, clearing the selection too. In the theme list the arrow keys try each theme on the diagram, and Enter keeps one. See [A page for looking at a diagram](#a-page-for-looking-at-a-diagram).
1427
+
1419
1428
  **0.26.1**
1420
1429
 
1421
1430
  - `h` `j` `k` `l` now pan only while the diagram is grabbed with `g`, as the arrow keys do, on the `--page` page and in the playground. In 0.26.0 they panned without a grab.
package/README.md CHANGED
@@ -94,7 +94,7 @@ To install the skill from the main branch instead, which can run ahead of the re
94
94
 
95
95
  ## Status
96
96
 
97
- Version 0.26.1. Early stage, but works. The parser, layout engine, and SVG renderer are written in TypeScript, with zero runtime dependencies. There is a command-line tool that turns a .reladraw text file into an SVG, and an element that does the same inside a web page.
97
+ Version 0.27.0. Early stage, but works. The parser, layout engine, and SVG renderer are written in TypeScript, with zero runtime dependencies. There is a command-line tool that turns a .reladraw text file into an SVG, and an element that does the same inside a web page.
98
98
 
99
99
  ## License
100
100
 
package/SYNTAX.md CHANGED
@@ -1,4 +1,4 @@
1
- # Syntax reference — 0.26.1
1
+ # Syntax reference — 0.27.0
2
2
 
3
3
  What the language accepts. The changelog at the end lists what changed in each published version; 0.17.0's changes are large, and its entry has a table of every old spelling and what to write instead.
4
4
 
@@ -1288,13 +1288,17 @@ The output is a standalone SVG: every picture is drawn into it as path data, nev
1288
1288
  reladraw render arch.reladraw --page
1289
1289
  ```
1290
1290
 
1291
- `--page` writes `arch.html`: one self-contained file, for opening in a browser, attaching or committing, that needs nothing running and fetches nothing. The page is in the diagram's own colors, so a dark diagram doesn't sit on a white page, and it is headed with `diagram title:`, or the file's name when there is none. Under the title it says which file it was drawn from and when, such as "drawn from arch.reladraw, 2026-11-05 14:32": the page is a snapshot of the file, and is behind it once the file is edited, until it is rendered again. Drag to pan, or press `g` to grab the diagram and pan it with the arrow keys or `h` `j` `k` `l` (Shift for bigger steps, `g` or Escape to let go); scroll, pinch or double-click to zoom; Fit shows the whole diagram and 100% returns it to its own scale. The zoom is always shown, with "Fit" beside it while the whole diagram is in view. There is a full-screen button. The Save menu saves the page itself, as it was written rather than at its current zoom; the `.reladraw` source it was drawn from; or the picture as an SVG or a PNG, as `render` would draw it; or copies the SVG. Each is named after the source file: `arch.html`, `arch.reladraw`, `arch.svg`, `arch.png`. In Chrome and Edge it asks where to save; other browsers put the file with their downloads. The findings are listed beside it in a panel that folds away, and clicking one lights up what its line drew. A box's or a line's name shows under the pointer. The theme picker draws the diagram in another theme, as `--theme` would, keeping the view and the selection; a page or text color the file states holds in every theme, and Save SVG, PNG and Copy SVG take the theme shown. It starts on "Diagram's theme", the one the file names (or dark), which follows the file when it is rendered again. A theme picked by name is the reader's: it holds on every reladraw page in that browser, whatever the file says, until "Diagram's theme" is picked again.
1291
+ `--page` writes `arch.html`: one self-contained file, for opening in a browser, attaching or committing, that needs nothing running and fetches nothing. The page is in the diagram's own colors, so a dark diagram doesn't sit on a white page, and it is headed with `diagram title:`, or the file's name when there is none. Under the title it says which file it was drawn from and when, such as "drawn from arch.reladraw, 2026-11-05 14:32": the page is a snapshot of the file, and is behind it once the file is edited, until it is rendered again. Drag to pan, or press `g` to grab the diagram and pan it with the arrow keys or `h` `j` `k` `l` (Shift for bigger steps, `g` or Escape to let go); scroll, pinch or double-click to zoom; Fit shows the whole diagram and 100% returns it to its own scale. The zoom is always shown, with "Fit" beside it while the whole diagram is in view. There is a full-screen button. The Save menu saves the page itself, as it was written rather than at its current zoom; the `.reladraw` source it was drawn from; or the picture as an SVG or a PNG, as `render` would draw it; or copies the SVG. Each is named after the source file: `arch.html`, `arch.reladraw`, `arch.svg`, `arch.png`. In Chrome and Edge it asks where to save; other browsers put the file with their downloads. The findings are listed beside it, and clicking one lights up what its line drew. A box's or a line's name shows under the pointer.
1292
1292
 
1293
- The side panel can be hidden with the Panel button or `p`, and then stays hidden whatever is selected. With Auto-hide ticked it shows only while something is selected or the findings are open, and the findings start folded. Both choices are remembered by the browser for every page.
1293
+ **The View menu** holds the page's settings, each row a switch that says on or off. **Theme** opens a list of themes, and draws the diagram in the one picked, as `--theme` would, keeping the view and the selection; a page or text color the file states holds in every theme. It starts on "Diagram's theme", the one the file names (or dark), which follows the file when it is rendered again. A theme picked by name is the reader's: it holds on every reladraw page in that browser, whatever the file says, until "Diagram's theme" is picked again. **Side panel** shows or hides the panel beside the drawing, which then stays hidden whatever is selected. **Auto-hide panel** shows it only while something is selected or the findings are open, and the findings start folded. Both are remembered by the browser for every page. **Findings**, with their count, open or fold the findings in the panel. **Guides**, with their count, draws the [guides](#guides) as `--guides` does; it starts as the file or `--guides` says, and a change lasts for that page only. Save SVG, PNG and Copy SVG take the theme and the guides as shown.
1294
1294
 
1295
- **A click on a box or a line selects it**, and never follows a link. The selection is amber; what feeds it is green and what it feeds is red, the lines dashed and moving the way they run; the rest dims. A line runs from the end without an arrowhead when only one end has one, and otherwise from the end written first. The panel beside the drawing names the selection and lists its links, each with its badge, and the boxes it comes from and goes to; a link opens in a new tab, and a box selects it. One line out lights by default, and the panel's button lights everything upstream and downstream. Its description, if it has one, comes last ([Descriptions](#descriptions)). A box with links underlines its text under the pointer. A click on the background or Escape clears the selection.
1295
+ **From the keyboard**, `m` reaches the bar: it is ringed, each control shows its letter, and a strip under it names where the keys are and which keys work there. `v` opens View, `s` opens Save, and `f` goes full screen. In a menu a row's letter does what the row does, and the menu stays open, so several can be changed in turn: in View, `t` theme, `p` side panel, `a` auto-hide, `f` findings and `g` guides; in Save, `p` this page, `r` the source, `s` SVG, `n` PNG and `c` Copy SVG. The arrow keys and Enter work too. In the theme list the arrows draw the diagram in each theme as they reach it, and Enter keeps the one reached. Backspace steps back one level at a time: from the theme list to View, from a menu to the bar, from the bar to the diagram, and then lets go of a grab, a lit finding and the selection in turn. Escape goes straight back to the plain diagram from anywhere: every menu closes, a theme tried and not kept is dropped, and a grab, a lit finding and the selection are all cleared. With the menus closed, `p` shows or hides the side panel and `f` goes full screen; `+` `-` `0` `1` zoom at every level.
1296
1296
 
1297
- Keys: `+` and `-` zoom, `0` fits, `1` is actual size, `f` is full screen, `p` shows or hides the side panel, Escape clears the selection.
1297
+ **A click on a box or a line selects it**, and never follows a link. The selection is amber; what feeds it is green and what it feeds is red, the lines dashed and moving the way they run; the rest dims. A line runs from the end without an arrowhead when only one end has one, and otherwise from the end written first. The panel beside the drawing names the selection and lists its links, each with its badge, and the boxes it comes from and goes to; a link opens in a new tab, and a box selects it. One line out lights by default, and the panel's button lights everything upstream and downstream. Its description, if it has one, comes last ([Descriptions](#descriptions)). A box with links underlines its text under the pointer. A click on the background, Escape or Backspace clears the selection.
1298
+
1299
+ **Selecting from the keyboard**: `s` puts a letter on every box and line, and typing a letter selects that thing. Things in view get the one-letter labels; past 26, the rest take two letters. `/` starts a filter that narrows what gets a letter, live as it is typed: a plain word matches a box's or a line's text, `is:node`, `is:edge` and `is:container` match a kind, and `style:synced` matches what wears that style. Words combine, so `/is:edge rclone` letters only the lines whose text says rclone. Enter ends the filter and the letters pick again, or selects the match at once when there is only one. With something selected, `n` letters what is one line away (from a box, its lines and the boxes at their other ends; from a line, its two ends), `i` letters the boxes inside the selected box and the box it sits in, and `l` letters its links, which a letter opens in a new tab: on the side panel's rows when the panel is shown, and in a small list beside the selection when it is hidden. Backspace steps back a letter, then out of the filter, then out; Escape clears everything. A picked thing out of view is brought into it.
1300
+
1301
+ Keys: `+` and `-` zoom, `0` fits, `1` is actual size, `f` is full screen, `p` shows or hides the side panel, `s` and `/` select, `n` `i` `l` step from the selection, Escape clears the selection.
1298
1302
 
1299
1303
  ### Formatting
1300
1304
 
@@ -1416,6 +1420,11 @@ Designed and absent from the code.
1416
1420
 
1417
1421
  Pre-1.0, so the minor number is where a breaking change goes. Every removal is refused by name with the replacement quoted, rather than dropped in silence: an older file stops with an error saying what to write instead.
1418
1422
 
1423
+ **0.27.0**
1424
+
1425
+ - **The `--page` page selects from the keyboard.** `s` puts a letter on every box and line and a letter selects it; `/` filters what gets a letter by text, `is:node`, `is:edge`, `is:container` or `style:`; with something selected, `n` letters what is one line away, `i` what is inside it and the box it sits in, and `l` its links. See [A page for looking at a diagram](#a-page-for-looking-at-a-diagram).
1426
+ - **The `--page` page has a View menu**, and its bar keeps only the zoom, Full screen, Save and View. The theme, the side panel, auto-hide and the findings moved into View, each a switch that says on or off, and View gained **Guides**, which draws the diagram's guides as `--guides` does. **`m` reaches the menus from the keyboard**: each control shows its letter, a strip names where the keys are, Backspace steps back one level and Escape goes straight back to the plain diagram, clearing the selection too. In the theme list the arrow keys try each theme on the diagram, and Enter keeps one. See [A page for looking at a diagram](#a-page-for-looking-at-a-diagram).
1427
+
1419
1428
  **0.26.1**
1420
1429
 
1421
1430
  - `h` `j` `k` `l` now pan only while the diagram is grabbed with `g`, as the arrow keys do, on the `--page` page and in the playground. In 0.26.0 they panned without a grab.