@wildwinter/app-shell 0.38.0 → 0.39.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.
Files changed (144) hide show
  1. package/LICENSES.md +62 -0
  2. package/README.md +8 -0
  3. package/dist/about.css +13 -34
  4. package/dist/about.css.map +1 -1
  5. package/dist/anchored.css +5 -5
  6. package/dist/anchored.css.map +1 -1
  7. package/dist/app-store.cjs +15 -0
  8. package/dist/app-store.cjs.map +1 -1
  9. package/dist/app-store.d.cts +25 -1
  10. package/dist/app-store.d.ts +25 -1
  11. package/dist/app-store.js +14 -1
  12. package/dist/app-store.js.map +1 -1
  13. package/dist/chunk-2ECJUTSX.js +97 -0
  14. package/dist/chunk-2ECJUTSX.js.map +1 -0
  15. package/dist/chunk-2NMVIM54.js +55 -0
  16. package/dist/chunk-2NMVIM54.js.map +1 -0
  17. package/dist/chunk-C6UVQYKI.js +70 -0
  18. package/dist/chunk-C6UVQYKI.js.map +1 -0
  19. package/dist/chunk-IU7EY6BI.js +26 -0
  20. package/dist/chunk-IU7EY6BI.js.map +1 -0
  21. package/dist/chunk-K2AOLQW4.js +82 -0
  22. package/dist/chunk-K2AOLQW4.js.map +1 -0
  23. package/dist/chunk-KGAMP5LW.js +87 -0
  24. package/dist/chunk-KGAMP5LW.js.map +1 -0
  25. package/dist/chunk-L5HOBEKL.js +534 -0
  26. package/dist/chunk-L5HOBEKL.js.map +1 -0
  27. package/dist/chunk-P4G4ERG6.js +60 -0
  28. package/dist/chunk-P4G4ERG6.js.map +1 -0
  29. package/dist/chunk-P6WLAEKZ.js +71 -0
  30. package/dist/chunk-P6WLAEKZ.js.map +1 -0
  31. package/dist/chunk-S4KWQLYN.js +66 -0
  32. package/dist/chunk-S4KWQLYN.js.map +1 -0
  33. package/dist/chunk-XZYZXY7I.js +554 -0
  34. package/dist/chunk-XZYZXY7I.js.map +1 -0
  35. package/dist/comments.css +5 -3
  36. package/dist/comments.css.map +1 -1
  37. package/dist/confirm.css +1 -54
  38. package/dist/confirm.css.map +1 -1
  39. package/dist/context-menu.cjs +250 -0
  40. package/dist/context-menu.cjs.map +1 -0
  41. package/dist/context-menu.css +64 -0
  42. package/dist/context-menu.css.map +1 -0
  43. package/dist/context-menu.d.cts +25 -0
  44. package/dist/context-menu.d.ts +25 -0
  45. package/dist/context-menu.js +5 -0
  46. package/dist/context-menu.js.map +1 -0
  47. package/dist/controls.css +155 -0
  48. package/dist/controls.css.map +1 -0
  49. package/dist/dialog.cjs +222 -0
  50. package/dist/dialog.cjs.map +1 -0
  51. package/dist/dialog.css +55 -0
  52. package/dist/dialog.css.map +1 -0
  53. package/dist/dialog.d.cts +28 -0
  54. package/dist/dialog.d.ts +28 -0
  55. package/dist/dialog.js +5 -0
  56. package/dist/dialog.js.map +1 -0
  57. package/dist/floating.cjs +83 -0
  58. package/dist/floating.cjs.map +1 -0
  59. package/dist/floating.d.cts +25 -0
  60. package/dist/floating.d.ts +25 -0
  61. package/dist/floating.js +4 -0
  62. package/dist/floating.js.map +1 -0
  63. package/dist/identity.css +15 -50
  64. package/dist/identity.css.map +1 -1
  65. package/dist/index.cjs +1307 -258
  66. package/dist/index.cjs.map +1 -1
  67. package/dist/index.d.cts +349 -149
  68. package/dist/index.d.ts +349 -149
  69. package/dist/index.js +259 -822
  70. package/dist/index.js.map +1 -1
  71. package/dist/job.css +23 -0
  72. package/dist/job.css.map +1 -1
  73. package/dist/link-status.cjs +430 -0
  74. package/dist/link-status.cjs.map +1 -0
  75. package/dist/link-status.css +76 -0
  76. package/dist/link-status.css.map +1 -0
  77. package/dist/link-status.d.cts +53 -0
  78. package/dist/link-status.d.ts +53 -0
  79. package/dist/link-status.js +5 -0
  80. package/dist/link-status.js.map +1 -0
  81. package/dist/menu.cjs +62 -1
  82. package/dist/menu.cjs.map +1 -1
  83. package/dist/menu.d.cts +88 -1
  84. package/dist/menu.d.ts +88 -1
  85. package/dist/menu.js +1 -1
  86. package/dist/notes-editor.css +3 -46
  87. package/dist/notes-editor.css.map +1 -1
  88. package/dist/pane-shell.css +16 -3
  89. package/dist/pane-shell.css.map +1 -1
  90. package/dist/property-list-D3VZCJzi.d.cts +162 -0
  91. package/dist/property-list-D3VZCJzi.d.ts +162 -0
  92. package/dist/property-list.cjs +784 -0
  93. package/dist/property-list.cjs.map +1 -0
  94. package/dist/property-list.d.cts +1 -0
  95. package/dist/property-list.d.ts +1 -0
  96. package/dist/property-list.js +4 -0
  97. package/dist/property-list.js.map +1 -0
  98. package/dist/settings.css +52 -8
  99. package/dist/settings.css.map +1 -1
  100. package/dist/stale.css +3 -0
  101. package/dist/stale.css.map +1 -1
  102. package/dist/stepper.css +35 -0
  103. package/dist/stepper.css.map +1 -1
  104. package/dist/tokens.css +19 -0
  105. package/dist/tokens.css.map +1 -1
  106. package/dist/tool-window.cjs +63 -0
  107. package/dist/tool-window.cjs.map +1 -1
  108. package/dist/tool-window.css +6 -3
  109. package/dist/tool-window.css.map +1 -1
  110. package/dist/tool-window.d.cts +67 -1
  111. package/dist/tool-window.d.ts +67 -1
  112. package/dist/tool-window.js +63 -1
  113. package/dist/tool-window.js.map +1 -1
  114. package/dist/updater-view.cjs +283 -0
  115. package/dist/updater-view.cjs.map +1 -0
  116. package/dist/updater-view.d.cts +23 -0
  117. package/dist/updater-view.d.ts +23 -0
  118. package/dist/updater-view.js +6 -0
  119. package/dist/updater-view.js.map +1 -0
  120. package/dist/updater.cjs +12 -16
  121. package/dist/updater.cjs.map +1 -1
  122. package/dist/updater.css +44 -0
  123. package/dist/updater.css.map +1 -0
  124. package/dist/updater.js +12 -16
  125. package/dist/updater.js.map +1 -1
  126. package/dist/util.cjs +78 -0
  127. package/dist/util.cjs.map +1 -0
  128. package/dist/util.d.cts +37 -0
  129. package/dist/util.d.ts +37 -0
  130. package/dist/util.js +3 -0
  131. package/dist/util.js.map +1 -0
  132. package/dist/vc.css +3 -2
  133. package/dist/vc.css.map +1 -1
  134. package/dist/welcome.cjs +215 -0
  135. package/dist/welcome.cjs.map +1 -0
  136. package/dist/welcome.css +112 -0
  137. package/dist/welcome.css.map +1 -0
  138. package/dist/welcome.d.cts +55 -0
  139. package/dist/welcome.d.ts +55 -0
  140. package/dist/welcome.js +4 -0
  141. package/dist/welcome.js.map +1 -0
  142. package/package.json +58 -2
  143. package/dist/chunk-QDPFU4WX.js +0 -43
  144. package/dist/chunk-QDPFU4WX.js.map +0 -1
package/dist/menu.d.ts CHANGED
@@ -1,3 +1,5 @@
1
+ import { RecentProject } from './app-store.js';
2
+
1
3
  interface MenuLabel {
2
4
  label: string;
3
5
  /** Electron accelerator string, when the item has one. */
@@ -21,6 +23,12 @@ declare const EDIT_MENU: {
21
23
  redo: MenuLabel;
22
24
  duplicate: MenuLabel;
23
25
  find: MenuLabel;
26
+ /** Replace is Find's second tab, on the platform's key for it. */
27
+ replace: {
28
+ label: string;
29
+ acceleratorMac: string;
30
+ acceleratorOther: string;
31
+ };
24
32
  };
25
33
  /**
26
34
  * Back / Forward: navigation HISTORY, the other axis from Up a Level's
@@ -102,5 +110,84 @@ declare function namedMenuItems(naming: MenuNaming): {
102
110
  docs: NamedMenuItem;
103
111
  suiteDocs: NamedMenuItem;
104
112
  };
113
+ /** The File menu items the family shares. */
114
+ declare const FILE_MENU: {
115
+ newProject: MenuLabel;
116
+ openProject: MenuLabel;
117
+ openRecent: MenuLabel;
118
+ /** The empty Open Recent submenu's one disabled item. */
119
+ noRecents: MenuLabel;
120
+ clearRecents: MenuLabel;
121
+ closeProject: MenuLabel;
122
+ save: MenuLabel;
123
+ saveAs: MenuLabel;
124
+ projectSettings: MenuLabel;
125
+ };
126
+ /**
127
+ * The Play menu's shared item. The play SURFACE itself (Patterpad's "Play
128
+ * Scene" on Cmd+P, Storyletter's "The Board" on Cmd+T) is app-named and
129
+ * app-keyed on purpose: the two are not the same act, so the family reserves
130
+ * neither key.
131
+ */
132
+ declare const PLAY_MENU: {
133
+ liveLink: MenuLabel;
134
+ };
135
+ /** The Review menu: examining what you have built rather than building or
136
+ * playing it. Review Feedback's accelerator is spelled ONCE, here. */
137
+ declare const REVIEW_MENU: {
138
+ reviewFeedback: MenuLabel;
139
+ nextFeedback: MenuLabel;
140
+ previousFeedback: MenuLabel;
141
+ coverageTest: MenuLabel;
142
+ findPropertyUsage: MenuLabel;
143
+ showResolvedComments: MenuLabel;
144
+ };
145
+ /** The Publish menu: everything that turns the project into something you
146
+ * hand to others ("Publish", never "Export"). */
147
+ declare const PUBLISH_MENU: {
148
+ playableHtml: MenuLabel;
149
+ bundle: MenuLabel;
150
+ autoRebuild: MenuLabel;
151
+ };
152
+ /** The View menu items beyond the pane toggles (PANE_MENU) and history
153
+ * (GO_MENU). Cmd+[ is family-reserved for Up a Level, which is why Back
154
+ * takes Xcode's pair on the mac. */
155
+ declare const VIEW_MENU: {
156
+ projectOverview: MenuLabel;
157
+ upALevel: MenuLabel;
158
+ colourTheme: MenuLabel;
159
+ };
160
+ /** A path with the home directory as `~`, so a recents entry stays readable
161
+ * at menu width. `home` is `app.getPath("home")`; this file stays
162
+ * electron-free. */
163
+ declare function tildePath(path: string, home: string): string;
164
+ /** As much of Electron's MenuItemConstructorOptions as a recents entry needs;
165
+ * structurally assignable to it. */
166
+ interface RecentsMenuItem {
167
+ label?: string;
168
+ sublabel?: string;
169
+ toolTip?: string;
170
+ enabled?: boolean;
171
+ type?: "separator";
172
+ click?: () => void;
173
+ }
174
+ interface RecentsSubmenuOptions {
175
+ onOpen: (path: string) => void;
176
+ /** Offered after a separator when there is anything to clear. */
177
+ onClear?: () => void;
178
+ /** `app.getPath("home")`, for the `~` abbreviation. */
179
+ home: string;
180
+ /** Defaults to process.platform; a seam for the tests. */
181
+ platform?: string;
182
+ }
183
+ /**
184
+ * The Open Recent submenu: the fifteen lines both apps had.
185
+ *
186
+ * Shows WHERE each recent lives. macOS renders `sublabel` as a dimmed second
187
+ * line and `toolTip` on hover; native menus elsewhere render neither, so
188
+ * there the path is folded into the label itself. Empty, it is the one
189
+ * disabled "No Recent Projects" item.
190
+ */
191
+ declare function recentsSubmenu(recents: RecentProject[], opts: RecentsSubmenuOptions): RecentsMenuItem[];
105
192
 
106
- export { APP_MENU, EDIT_MENU, GO_MENU, HELP_MENU, type MenuLabel, type MenuNaming, type NamedMenuItem, PANE_MENU, namedMenuItems };
193
+ export { APP_MENU, EDIT_MENU, FILE_MENU, GO_MENU, HELP_MENU, type MenuLabel, type MenuNaming, type NamedMenuItem, PANE_MENU, PLAY_MENU, PUBLISH_MENU, REVIEW_MENU, type RecentsMenuItem, type RecentsSubmenuOptions, VIEW_MENU, namedMenuItems, recentsSubmenu, tildePath };
package/dist/menu.js CHANGED
@@ -1,3 +1,3 @@
1
- export { APP_MENU, EDIT_MENU, GO_MENU, HELP_MENU, PANE_MENU, namedMenuItems } from './chunk-QDPFU4WX.js';
1
+ export { APP_MENU, EDIT_MENU, FILE_MENU, GO_MENU, HELP_MENU, PANE_MENU, PLAY_MENU, PUBLISH_MENU, REVIEW_MENU, VIEW_MENU, namedMenuItems, recentsSubmenu, tildePath } from './chunk-2ECJUTSX.js';
2
2
  //# sourceMappingURL=menu.js.map
3
3
  //# sourceMappingURL=menu.js.map
@@ -1,19 +1,6 @@
1
1
  /* src/notes-editor.css */
2
2
  .shell-notes {
3
- width: min(560px, 92vw);
4
- border: 1px solid var(--line);
5
- border-radius: var(--radius-md);
6
- background: var(--surface);
7
- color: var(--ink);
8
- padding: 16px 18px;
9
- box-shadow: var(--shadow-2, var(--shadow-1));
10
- }
11
- .shell-notes::backdrop {
12
- background: rgba(0, 0, 0, 0.28);
13
- }
14
- .shell-notes-title {
15
- font: 600 0.95rem/1.3 var(--font-ui);
16
- margin-bottom: 10px;
3
+ --dialog-width: 560px;
17
4
  }
18
5
  .shell-notes-body {
19
6
  display: flex;
@@ -23,30 +10,19 @@
23
10
  overflow-y: auto;
24
11
  }
25
12
  .shell-notes-caption {
26
- font: 0.72rem/1 var(--font-ui);
13
+ font: 600 0.78rem/1.2 var(--font-ui);
27
14
  color: var(--muted);
28
- text-transform: uppercase;
29
- letter-spacing: 0.04em;
30
15
  }
31
16
  .shell-notes-class {
32
17
  display: flex;
33
18
  flex-direction: column;
34
19
  gap: 4px;
35
20
  }
36
- .shell-notes-text {
21
+ textarea.shell-notes-text {
37
22
  width: 100%;
38
23
  box-sizing: border-box;
39
24
  resize: vertical;
40
- border: 1px solid var(--line-soft);
41
- border-radius: var(--radius-sm);
42
- background: var(--card);
43
- color: var(--ink);
44
25
  font: 0.85rem/1.45 var(--font-read, var(--font-ui));
45
- padding: 6px 8px;
46
- }
47
- .shell-notes-text:focus {
48
- outline: none;
49
- border-color: var(--accent);
50
26
  }
51
27
  .shell-notes-inherited {
52
28
  display: flex;
@@ -85,23 +61,4 @@
85
61
  font: 0.78rem/1 var(--font-ui);
86
62
  align-self: flex-start;
87
63
  }
88
- .shell-notes-actions {
89
- display: flex;
90
- justify-content: flex-end;
91
- margin-top: 12px;
92
- }
93
- .shell-notes-btn {
94
- font: 0.8rem/1 var(--font-ui);
95
- padding: 6px 14px;
96
- border-radius: var(--radius-sm);
97
- border: 1px solid var(--line);
98
- background: var(--card);
99
- color: var(--ink);
100
- cursor: pointer;
101
- }
102
- .shell-notes-btn.primary {
103
- background: var(--accent);
104
- border-color: var(--accent);
105
- color: var(--on-accent, #fff);
106
- }
107
64
  /*# sourceMappingURL=notes-editor.css.map */
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/notes-editor.css"],"sourcesContent":["/* The documentation-notes editor (notes-editor.ts): a modal, because notes are\n prose and the popover Patterpad tried first was too cramped. */\n.shell-notes {\n width: min(560px, 92vw);\n border: 1px solid var(--line); border-radius: var(--radius-md);\n background: var(--surface); color: var(--ink);\n padding: 16px 18px;\n box-shadow: var(--shadow-2, var(--shadow-1));\n}\n.shell-notes::backdrop { background: rgba(0, 0, 0, 0.28); }\n.shell-notes-title { font: 600 0.95rem/1.3 var(--font-ui); margin-bottom: 10px; }\n.shell-notes-body { display: flex; flex-direction: column; gap: 10px; max-height: 60vh; overflow-y: auto; }\n.shell-notes-caption {\n font: 0.72rem/1 var(--font-ui); color: var(--muted);\n text-transform: uppercase; letter-spacing: 0.04em;\n}\n.shell-notes-class { display: flex; flex-direction: column; gap: 4px; }\n.shell-notes-text {\n width: 100%; box-sizing: border-box; resize: vertical;\n border: 1px solid var(--line-soft); border-radius: var(--radius-sm);\n background: var(--card); color: var(--ink);\n font: 0.85rem/1.45 var(--font-read, var(--font-ui)); padding: 6px 8px;\n}\n.shell-notes-text:focus { outline: none; border-color: var(--accent); }\n/* Inherited notes read as CONTEXT rather than as fields: no box, no cursor. */\n.shell-notes-inherited {\n display: flex; flex-direction: column; gap: 6px;\n padding-bottom: 4px; border-bottom: 1px solid var(--line-soft);\n}\n.shell-notes-level { display: flex; flex-direction: column; gap: 2px; }\n.shell-notes-level-label { font: 0.72rem/1 var(--font-ui); color: var(--muted); }\n.shell-notes-line { font: 0.82rem/1.4 var(--font-read, var(--font-ui)); color: var(--muted); }\n.shell-notes-cls {\n font: 0.68rem/1 var(--font-ui); color: var(--muted);\n border: 1px solid var(--line-soft); border-radius: var(--radius-pill);\n padding: 1px 6px; margin-right: 6px;\n}\n.shell-notes-hint { font: 0.72rem/1 var(--font-ui); color: var(--muted); margin: 0; }\n.shell-notes-add { font: 0.78rem/1 var(--font-ui); align-self: flex-start; }\n.shell-notes-actions { display: flex; justify-content: flex-end; margin-top: 12px; }\n.shell-notes-btn {\n font: 0.8rem/1 var(--font-ui); padding: 6px 14px;\n border-radius: var(--radius-sm); border: 1px solid var(--line);\n background: var(--card); color: var(--ink); cursor: pointer;\n}\n.shell-notes-btn.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent, #fff); }\n"],"mappings":";AAEA,CAAC;AACC,SAAO,IAAI,KAAK,EAAE;AAClB,UAAQ,IAAI,MAAM,IAAI;AAAS,iBAAe,IAAI;AAClD,cAAY,IAAI;AAAY,SAAO,IAAI;AACvC,WAAS,KAAK;AACd,cAAY,IAAI,UAAU,EAAE,IAAI;AAClC;A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;AACpF,CAAC;AAAkB,QAAM,OAAO,CAAC,EAAE,IAAI;AAAY,cAAY;AAAY;AAC3E,CAAC;AAAsB,WAAS;AAAM,mBAAiB;AAAU,cAAY;AAAM;AACnF,CAAC;AACC,QAAM,MAAM,CAAC,EAAE,IAAI;AAAY,WAAS,IAAI;AAC5C,iBAAe,IAAI;AAAc,UAAQ,IAAI,MAAM,IAAI;AACvD,cAAY,IAAI;AAAS,SAAO,IAAI;AAAQ,UAAQ;AACtD;AACA,CALC,eAKe,CAAC;AAAU,cAAY,IAAI;AAAW,gBAAc,IAAI;AAAW,SAAO,IAAI,WAAW,EAAE;AAAO;","names":[]}
1
+ {"version":3,"sources":["../src/notes-editor.css"],"sourcesContent":["/* The documentation-notes editor (notes-editor.ts): a modal, because notes are\n prose and the popover Patterpad tried first was too cramped. The panel,\n scrim, title and actions row are the dialog frame's (dialog.css); the text\n areas and the Done button are controls.css's `.field` and `.btn`. */\n.shell-notes { --dialog-width: 560px; }\n.shell-notes-body { display: flex; flex-direction: column; gap: 10px; max-height: 60vh; overflow-y: auto; }\n/* A caption is sentence-case text at label size, weight 600, in the UI face. */\n.shell-notes-caption {\n font: 600 0.78rem/1.2 var(--font-ui); color: var(--muted);\n}\n.shell-notes-class { display: flex; flex-direction: column; gap: 4px; }\n/* Notes are prose, so the area is set in the reading face; the element\n selector out-specifies `.field`, whichever stylesheet loads first. */\ntextarea.shell-notes-text {\n width: 100%; box-sizing: border-box; resize: vertical;\n font: 0.85rem/1.45 var(--font-read, var(--font-ui));\n}\n/* Inherited notes read as CONTEXT rather than as fields: no box, no cursor. */\n.shell-notes-inherited {\n display: flex; flex-direction: column; gap: 6px;\n padding-bottom: 4px; border-bottom: 1px solid var(--line-soft);\n}\n.shell-notes-level { display: flex; flex-direction: column; gap: 2px; }\n.shell-notes-level-label { font: 0.72rem/1 var(--font-ui); color: var(--muted); }\n.shell-notes-line { font: 0.82rem/1.4 var(--font-read, var(--font-ui)); color: var(--muted); }\n.shell-notes-cls {\n font: 0.68rem/1 var(--font-ui); color: var(--muted);\n border: 1px solid var(--line-soft); border-radius: var(--radius-pill);\n padding: 1px 6px; margin-right: 6px;\n}\n.shell-notes-hint { font: 0.72rem/1 var(--font-ui); color: var(--muted); margin: 0; }\n.shell-notes-add { font: 0.78rem/1 var(--font-ui); align-self: flex-start; }\n"],"mappings":";AAIA,CAAC;AAAc,kBAAgB;AAAO;AACtC,CAAC;AAAmB,WAAS;AAAM,kBAAgB;AAAQ,OAAK;AAAM,cAAY;AAAM,cAAY;AAAM;AAE1G,CAAC;AACC,QAAM,IAAI,OAAO,CAAC,IAAI,IAAI;AAAY,SAAO,IAAI;AACnD;AACA,CAAC;AAAoB,WAAS;AAAM,kBAAgB;AAAQ,OAAK;AAAK;AAGtE,QAAQ,CAAC;AACP,SAAO;AAAM,cAAY;AAAY,UAAQ;AAC7C,QAAM,OAAO,CAAC,KAAK,IAAI,WAAW,EAAE,IAAI;AAC1C;AAEA,CAAC;AACC,WAAS;AAAM,kBAAgB;AAAQ,OAAK;AAC5C,kBAAgB;AAAK,iBAAe,IAAI,MAAM,IAAI;AACpD;AACA,CAAC;AAAoB,WAAS;AAAM,kBAAgB;AAAQ,OAAK;AAAK;AACtE,CAAC;AAA0B,QAAM,OAAO,CAAC,EAAE,IAAI;AAAY,SAAO,IAAI;AAAU;AAChF,CAAC;AAAmB,QAAM,OAAO,CAAC,IAAI,IAAI,WAAW,EAAE,IAAI;AAAa,SAAO,IAAI;AAAU;AAC7F,CAAC;AACC,QAAM,OAAO,CAAC,EAAE,IAAI;AAAY,SAAO,IAAI;AAC3C,UAAQ,IAAI,MAAM,IAAI;AAAc,iBAAe,IAAI;AACvD,WAAS,IAAI;AAAK,gBAAc;AAClC;AACA,CAAC;AAAmB,QAAM,OAAO,CAAC,EAAE,IAAI;AAAY,SAAO,IAAI;AAAU,UAAQ;AAAG;AACpF,CAAC;AAAkB,QAAM,OAAO,CAAC,EAAE,IAAI;AAAY,cAAY;AAAY;","names":[]}
@@ -28,13 +28,15 @@
28
28
  gap: 10px;
29
29
  }
30
30
  .pane-toggle {
31
+ display: inline-flex;
32
+ align-items: center;
33
+ justify-content: center;
31
34
  color: var(--muted);
32
35
  font: inherit;
33
- font-size: 0.95rem;
34
36
  background: none;
35
37
  border: 0;
36
38
  border-radius: var(--radius-sm);
37
- padding: 2px 8px;
39
+ padding: 4px 8px;
38
40
  cursor: pointer;
39
41
  }
40
42
  .pane-toggle:hover {
@@ -103,6 +105,18 @@
103
105
  cursor: col-resize;
104
106
  touch-action: none;
105
107
  }
108
+ .pane-resizer::after {
109
+ content: "";
110
+ position: absolute;
111
+ inset: 0 3px;
112
+ background: transparent;
113
+ transition: background var(--dur-quick) var(--ease-standard);
114
+ }
115
+ .pane-resizer:hover::after,
116
+ .pane-resizer.dragging::after,
117
+ body.pane-resizing .pane-resizer::after {
118
+ background: color-mix(in oklab, var(--accent) 45%, transparent);
119
+ }
106
120
  .pane-resizer-nav {
107
121
  left: calc(var(--nav-w) - 3px);
108
122
  }
@@ -136,7 +150,6 @@ body.pane-resizing .panes {
136
150
  border-radius: var(--radius-sm);
137
151
  background: none;
138
152
  color: var(--muted);
139
- font-size: 0.95rem;
140
153
  line-height: 1;
141
154
  cursor: pointer;
142
155
  }
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/pane-shell.css"],"sourcesContent":["/* ============================================================================\n The pane-shell frame: top bar + nav | centre | inspector grid with collapse\n and drag-resize. Reads the shared token grammar (tokens.css) and the app's\n palette vars (--surface / --ink / --muted / --line / --accent, and an\n optional --line-soft). The host fills the pane bodies and the top-bar\n lead/trail slots.\n ============================================================================ */\n\n.pane-shell { flex: 1; display: flex; flex-direction: column; min-height: 0; }\n\n.topbar {\n display: flex; align-items: center; gap: 10px;\n padding: 8px 14px;\n border-bottom: 1px solid var(--line-soft, var(--line));\n background: var(--surface);\n}\n.topbar-lead { display: flex; align-items: center; gap: 8px; min-width: 0; }\n.topbar-spacer { flex: 1; }\n.topbar-trail { display: flex; align-items: center; gap: 10px; }\n.pane-toggle {\n color: var(--muted); font: inherit; font-size: 0.95rem;\n background: none; border: 0; border-radius: var(--radius-sm); padding: 2px 8px; cursor: pointer;\n}\n.pane-toggle:hover { color: var(--accent); }\n\n/* --- the fused title bar (the family ruling, 2026-08-27) --------------------\n On macOS the topbar IS the window's title bar: the app's main window uses\n titleBarStyle \"hiddenInset\" and marks the bar with these classes, so one\n row carries the traffic lights, the identity and the top-level controls\n instead of a native strip whose only cargo is a title. `titlebar` makes the\n bar the drag surface (its controls stay clickable; add `no-drag` to any\n other interactive thing the host mounts); `titlebar-inset` leaves room for\n the traffic lights and is added ONLY on macOS - elsewhere the window keeps\n its native frame and the same bar sits beneath it, identically in every\n app of the family. */\n.topbar.titlebar { -webkit-app-region: drag; }\n.topbar.titlebar :is(button, input, select, a, .no-drag) { -webkit-app-region: no-drag; }\n.topbar.titlebar-inset { padding-left: 84px; }\n\n.panes {\n --nav-open-w: 14rem; --insp-open-w: 22rem;\n --nav-w: var(--nav-open-w); --insp-w: var(--insp-open-w);\n position: relative; flex: 1; min-height: 0;\n display: grid; grid-template-columns: var(--nav-w) minmax(0, 1fr) var(--insp-w);\n transition: grid-template-columns var(--dur-panel) var(--ease-standard);\n}\n.panes.no-nav { --nav-w: 0px; }\n.panes.no-inspector { --insp-w: 0px; }\n\n/* Side panes clip; their inner holds a fixed width so a collapse wipes cleanly\n rather than reflowing while the column animates to 0. */\n.pane { overflow: hidden; min-height: 0; }\n.pane-inner { height: 100%; overflow: auto; }\n.pane-nav .pane-inner { width: var(--nav-open-w); }\n.pane-inspector .pane-inner { width: var(--insp-open-w); }\n.pane-centre { min-width: 0; min-height: 0; overflow: auto; }\n\n.panes > .pane { transition: opacity var(--dur-panel) var(--ease-standard); }\n.panes.no-nav > .pane-nav, .panes.no-inspector > .pane-inspector { opacity: 0; pointer-events: none; }\n\n/* Drag seams over each side pane's inner edge, tracking the grid columns. */\n.pane-resizer { position: absolute; top: 0; bottom: 0; width: 7px; z-index: 6; cursor: col-resize; touch-action: none; }\n.pane-resizer-nav { left: calc(var(--nav-w) - 3px); }\n.pane-resizer-insp { right: calc(var(--insp-w) - 3px); }\n.panes.no-nav .pane-resizer-nav, .panes.no-inspector .pane-resizer-insp { display: none; }\nbody.pane-resizing { cursor: col-resize; user-select: none; }\nbody.pane-resizing .panes { transition: none; } /* 1:1 feel: suspend the grid tween mid-drag */\n\n/* --- the back/forward pair (nav-history.ts) --------------------------------\n VS Code's quietness: two plain chevrons, borderless, greyed where there is\n nowhere to go. They sit to the LEFT of the app's normal navigation (the\n crumb trail here, whatever the host's equivalent is), so they read as part\n of the chrome, not a control demanding attention. */\n.shell-histnav { display: inline-flex; gap: 2px; margin-right: 6px; }\n.shell-histnav-btn { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; padding: 0; border: none; border-radius: var(--radius-sm); background: none; color: var(--muted); font-size: 0.95rem; line-height: 1; cursor: pointer; }\n.shell-histnav-btn:hover:not(:disabled) { color: var(--ink); background: var(--accent-soft); }\n.shell-histnav-btn:disabled { opacity: 0.35; cursor: default; }\n"],"mappings":";AAQA,CAAC;AAAa,QAAM;AAAG,WAAS;AAAM,kBAAgB;AAAQ,cAAY;AAAG;AAE7E,CAAC;AACC,WAAS;AAAM,eAAa;AAAQ,OAAK;AACzC,WAAS,IAAI;AACb,iBAAe,IAAI,MAAM,IAAI,WAAW,EAAE,IAAI;AAC9C,cAAY,IAAI;AAClB;AACA,CAAC;AAAc,WAAS;AAAM,eAAa;AAAQ,OAAK;AAAK,aAAW;AAAG;AAC3E,CAAC;AAAgB,QAAM;AAAG;AAC1B,CAAC;AAAe,WAAS;AAAM,eAAa;AAAQ,OAAK;AAAM;AAC/D,CAAC;AACC,SAAO,IAAI;AAAU,QAAM;AAAS,aAAW;AAC/C,cAAY;AAAM,UAAQ;AAAG,iBAAe,IAAI;AAAc,WAAS,IAAI;AAAK,UAAQ;AAC1F;AACA,CAJC,WAIW;AAAS,SAAO,IAAI;AAAW;AAY3C,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C,CADpD;AACyE,WAAS;AAAM;AACzF,IAAI,CAAC;AAAgB,UAAQ;AAAY,eAAa;AAAM;AAC5D,IAAI,CADC,cACc,CA3BlB;AA2B2B,cAAY;AAAM;AAO9C,CAAC;AAAgB,WAAS;AAAa,OAAK;AAAK,gBAAc;AAAK;AACpE,CAAC;AAAoB,WAAS;AAAa,eAAa;AAAQ,mBAAiB;AAAQ,SAAO;AAAM,UAAQ;AAAM,WAAS;AAAG,UAAQ;AAAM,iBAAe,IAAI;AAAc,cAAY;AAAM,SAAO,IAAI;AAAU,aAAW;AAAS,eAAa;AAAG,UAAQ;AAAS;AAC3Q,CADC,iBACiB,MAAM,KAAK;AAAa,SAAO,IAAI;AAAQ,cAAY,IAAI;AAAgB;AAC7F,CAFC,iBAEiB;AAAY,WAAS;AAAM,UAAQ;AAAS;","names":[]}
1
+ {"version":3,"sources":["../src/pane-shell.css"],"sourcesContent":["/* ============================================================================\n The pane-shell frame: top bar + nav | centre | inspector grid with collapse\n and drag-resize. Reads the shared token grammar (tokens.css) and the app's\n palette vars (--surface / --ink / --muted / --line / --accent, and an\n optional --line-soft). The host fills the pane bodies and the top-bar\n lead/trail slots.\n ============================================================================ */\n\n.pane-shell { flex: 1; display: flex; flex-direction: column; min-height: 0; }\n\n.topbar {\n display: flex; align-items: center; gap: 10px;\n padding: 8px 14px;\n border-bottom: 1px solid var(--line-soft, var(--line));\n background: var(--surface);\n}\n.topbar-lead { display: flex; align-items: center; gap: 8px; min-width: 0; }\n.topbar-spacer { flex: 1; }\n.topbar-trail { display: flex; align-items: center; gap: 10px; }\n.pane-toggle {\n display: inline-flex; align-items: center; justify-content: center;\n color: var(--muted); font: inherit;\n background: none; border: 0; border-radius: var(--radius-sm); padding: 4px 8px; cursor: pointer;\n}\n.pane-toggle:hover { color: var(--accent); }\n\n/* --- the fused title bar (the family ruling, 2026-08-27) --------------------\n On macOS the topbar IS the window's title bar: the app's main window uses\n titleBarStyle \"hiddenInset\" and marks the bar with these classes, so one\n row carries the traffic lights, the identity and the top-level controls\n instead of a native strip whose only cargo is a title. `titlebar` makes the\n bar the drag surface (its controls stay clickable; add `no-drag` to any\n other interactive thing the host mounts); `titlebar-inset` leaves room for\n the traffic lights and is added ONLY on macOS - elsewhere the window keeps\n its native frame and the same bar sits beneath it, identically in every\n app of the family. */\n.topbar.titlebar { -webkit-app-region: drag; }\n.topbar.titlebar :is(button, input, select, a, .no-drag) { -webkit-app-region: no-drag; }\n.topbar.titlebar-inset { padding-left: 84px; }\n\n.panes {\n --nav-open-w: 14rem; --insp-open-w: 22rem;\n --nav-w: var(--nav-open-w); --insp-w: var(--insp-open-w);\n position: relative; flex: 1; min-height: 0;\n display: grid; grid-template-columns: var(--nav-w) minmax(0, 1fr) var(--insp-w);\n transition: grid-template-columns var(--dur-panel) var(--ease-standard);\n}\n.panes.no-nav { --nav-w: 0px; }\n.panes.no-inspector { --insp-w: 0px; }\n\n/* Side panes clip; their inner holds a fixed width so a collapse wipes cleanly\n rather than reflowing while the column animates to 0. */\n.pane { overflow: hidden; min-height: 0; }\n.pane-inner { height: 100%; overflow: auto; }\n.pane-nav .pane-inner { width: var(--nav-open-w); }\n.pane-inspector .pane-inner { width: var(--insp-open-w); }\n.pane-centre { min-width: 0; min-height: 0; overflow: auto; }\n\n.panes > .pane { transition: opacity var(--dur-panel) var(--ease-standard); }\n.panes.no-nav > .pane-nav, .panes.no-inspector > .pane-inspector { opacity: 0; pointer-events: none; }\n\n/* Drag seams over each side pane's inner edge, tracking the grid columns. The\n seam is invisible at rest and lights up under the pointer and while dragging\n (quiet chrome, shown on hover): a colour change only, at --dur-quick. */\n.pane-resizer { position: absolute; top: 0; bottom: 0; width: 7px; z-index: 6; cursor: col-resize; touch-action: none; }\n.pane-resizer::after { content: \"\"; position: absolute; inset: 0 3px; background: transparent; transition: background var(--dur-quick) var(--ease-standard); }\n.pane-resizer:hover::after, .pane-resizer.dragging::after, body.pane-resizing .pane-resizer::after { background: color-mix(in oklab, var(--accent) 45%, transparent); }\n.pane-resizer-nav { left: calc(var(--nav-w) - 3px); }\n.pane-resizer-insp { right: calc(var(--insp-w) - 3px); }\n.panes.no-nav .pane-resizer-nav, .panes.no-inspector .pane-resizer-insp { display: none; }\nbody.pane-resizing { cursor: col-resize; user-select: none; }\nbody.pane-resizing .panes { transition: none; } /* 1:1 feel: suspend the grid tween mid-drag */\n\n/* --- the back/forward pair (nav-history.ts) --------------------------------\n VS Code's quietness: two plain chevrons, borderless, greyed where there is\n nowhere to go. They sit to the LEFT of the app's normal navigation (the\n crumb trail here, whatever the host's equivalent is), so they read as part\n of the chrome, not a control demanding attention. */\n.shell-histnav { display: inline-flex; gap: 2px; margin-right: 6px; }\n.shell-histnav-btn { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; padding: 0; border: none; border-radius: var(--radius-sm); background: none; color: var(--muted); line-height: 1; cursor: pointer; }\n.shell-histnav-btn:hover:not(:disabled) { color: var(--ink); background: var(--accent-soft); }\n.shell-histnav-btn:disabled { opacity: 0.35; cursor: default; }\n"],"mappings":";AAQA,CAAC;AAAa,QAAM;AAAG,WAAS;AAAM,kBAAgB;AAAQ,cAAY;AAAG;AAE7E,CAAC;AACC,WAAS;AAAM,eAAa;AAAQ,OAAK;AACzC,WAAS,IAAI;AACb,iBAAe,IAAI,MAAM,IAAI,WAAW,EAAE,IAAI;AAC9C,cAAY,IAAI;AAClB;AACA,CAAC;AAAc,WAAS;AAAM,eAAa;AAAQ,OAAK;AAAK,aAAW;AAAG;AAC3E,CAAC;AAAgB,QAAM;AAAG;AAC1B,CAAC;AAAe,WAAS;AAAM,eAAa;AAAQ,OAAK;AAAM;AAC/D,CAAC;AACC,WAAS;AAAa,eAAa;AAAQ,mBAAiB;AAC5D,SAAO,IAAI;AAAU,QAAM;AAC3B,cAAY;AAAM,UAAQ;AAAG,iBAAe,IAAI;AAAc,WAAS,IAAI;AAAK,UAAQ;AAC1F;AACA,CALC,WAKW;AAAS,SAAO,IAAI;AAAW;AAY3C,CA1BC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CAF7E,YAE0F;AAAU,cAAY,UAAU,GAAG,KAAK,EAAE,IAAI,UAAU,GAAG,EAAE;AAAc;AACtK,CAAC;AAAmB,QAAM,KAAK,IAAI,SAAS,EAAE;AAAM;AACpD,CAAC;AAAoB,SAAO,KAAK,IAAI,UAAU,EAAE;AAAM;AACvD,CA7BC,KA6BK,CAtBC,OAsBO,CAFb;AAEgC,CA7BhC,KA6BsC,CArBhC,aAqB8C,CADpD;AACyE,WAAS;AAAM;AACzF,IAAI,CAJ4D;AAI3C,UAAQ;AAAY,eAAa;AAAM;AAC5D,IAAI,CAL4D,cAK7C,CA/BlB;AA+B2B,cAAY;AAAM;AAO9C,CAAC;AAAgB,WAAS;AAAa,OAAK;AAAK,gBAAc;AAAK;AACpE,CAAC;AAAoB,WAAS;AAAa,eAAa;AAAQ,mBAAiB;AAAQ,SAAO;AAAM,UAAQ;AAAM,WAAS;AAAG,UAAQ;AAAM,iBAAe,IAAI;AAAc,cAAY;AAAM,SAAO,IAAI;AAAU,eAAa;AAAG,UAAQ;AAAS;AACvP,CADC,iBACiB,MAAM,KAAK;AAAa,SAAO,IAAI;AAAQ,cAAY,IAAI;AAAgB;AAC7F,CAFC,iBAEiB;AAAY,WAAS;AAAM,UAAQ;AAAS;","names":[]}
@@ -0,0 +1,162 @@
1
+ /** A compact list row: a single `.set-rowline` (inline controls) plus, when
2
+ * `details` are given, a disclosure that reveals a `.set-details` panel below,
3
+ * so a list scans like a table with secondary fields tucked away. `name` is
4
+ * what the row declares (a property's name, a field's), stamped on it as
5
+ * `data-name` so `revealRow` can land on it. */
6
+ declare function expandableRow(opts: {
7
+ line: HTMLElement[];
8
+ details?: HTMLElement[];
9
+ name?: string;
10
+ }): HTMLElement;
11
+ /**
12
+ * Land on one row of a list by the `name` it was built with: open its details
13
+ * (an enum's values sit behind the disclosure, and they are usually what the
14
+ * jump was for), bring it to the middle of its scroller, and light it for a
15
+ * moment (`.set-row.landed` in settings.css). "Go to definition" in both apps
16
+ * used to open the page a property is declared on and stop there, with the
17
+ * declaration below the fold and nothing marking it (Storyletter, 2026-09-14).
18
+ *
19
+ * Returns false when no row carries the name, so a host whose page fills in
20
+ * asynchronously can ask again on a later frame; asking again is the host's,
21
+ * since only the host knows what opens on its own time. The row is matched by
22
+ * reading the stamp rather than by an attribute selector, so a name needs no
23
+ * escaping.
24
+ */
25
+ declare function revealRow(within: ParentNode, name: string): boolean;
26
+ /**
27
+ * `revealRow`, retried over the next frames until the row exists or the tries
28
+ * run out: for a page that fills in on its own time after a navigation. Both
29
+ * apps hand-rolled this as `landOn` with the same twelve tries
30
+ * (ui-review-2026-09, finding 29). Resolves true when it landed, false when it
31
+ * gave up, and giving up is quiet: a name no page shows as a row is not a fault.
32
+ */
33
+ declare function revealRowWhenReady(within: ParentNode, name: string, tries?: number): Promise<boolean>;
34
+ /** After a "+ Add" re-renders a list, bring the new (last) row into view and
35
+ * focus its name input (`.set-name`, else the first input). */
36
+ declare function focusNewRow(listEl: HTMLElement | null | undefined): void;
37
+ interface DupGuard {
38
+ /** Forget the previous render's inputs (call at the top of render). */
39
+ reset(): void;
40
+ /** Register a name input; `key` returns the comparison string (default the
41
+ * input's value). Re-checks live on input. `also` = extra inputs that change the key. */
42
+ track(input: HTMLInputElement, key?: () => string, also?: HTMLInputElement[]): void;
43
+ /** Re-paint duplicates; true if any two non-blank keys collide. */
44
+ check(): boolean;
45
+ /** The first input currently flagged (after a fresh check), or null. */
46
+ firstDuplicate(): HTMLInputElement | null;
47
+ }
48
+ /** Case-insensitive duplicate-name detection: paints clashing inputs `.invalid`
49
+ * and lets a Save gate block + jump via `firstDuplicate()`. */
50
+ declare function dupGuard(): DupGuard;
51
+ interface SettingsSectionHandle {
52
+ /** The first invalid control to jump to, blocking Save (e.g. a duplicate
53
+ * name). Return `{ el, message }` to say WHICH fault in the error line;
54
+ * a bare element says it through its own `data-tip` (the dup guard's, a
55
+ * property-name field's), and the line falls back to a generic sentence
56
+ * when it has neither. */
57
+ firstInvalid?(): HTMLElement | {
58
+ el: HTMLElement;
59
+ message?: string;
60
+ } | null;
61
+ }
62
+ interface SettingsSection {
63
+ id: string;
64
+ label: string;
65
+ /** Optional left-rail group heading above this tab. */
66
+ group?: string;
67
+ /** Build the section body into `host`; called fresh on each open so it reads
68
+ * the current data. Return a handle (for the Save gate). */
69
+ mount(host: HTMLElement): SettingsSectionHandle;
70
+ /** Why this tab cannot be used right now, or null when it can. A reason
71
+ * renders the tab dimmed and inert with the reason as its rollover
72
+ * (Patterpad's Audio tab while the project is not voiced). Read on open
73
+ * and on `refreshTabs()`, so a control inside the dialog can flip it. */
74
+ disabled?: () => string | null;
75
+ }
76
+ interface SettingsDialogOptions {
77
+ title: string;
78
+ sections: SettingsSection[];
79
+ /** Fired when Save is clicked and every section validates. The app reads its
80
+ * own section state and persists. May be async; the dialog stays open until
81
+ * it resolves, then closes. */
82
+ onSave: () => void | Promise<void>;
83
+ }
84
+ interface SettingsDialog {
85
+ /** Open (optionally on a given tab id). Sections re-mount from current data. */
86
+ open(tabId?: string): void;
87
+ /** Re-read every section's `disabled()`; a tab that has just become
88
+ * disabled while showing hands over to the first usable one. */
89
+ refreshTabs(): void;
90
+ destroy(): void;
91
+ }
92
+ /** Build a settings dialog. The frame owns the modal, the tab rail, save-on-Save
93
+ * (with a validation gate), and Cancel; the sections own their content + state. */
94
+ declare function mountSettingsDialog(opts: SettingsDialogOptions): SettingsDialog;
95
+
96
+ /** The six types both apps declare. */
97
+ type PropertyListType = "number" | "boolean" | "string" | "enum" | "flags" | "quality";
98
+ /** The shape a row edits. Apps' DTOs carry more (shared, writable, durable);
99
+ * those ride through untouched. */
100
+ interface PropertyDeclLike {
101
+ name: string;
102
+ type: string;
103
+ default?: unknown;
104
+ /** enum / flags */
105
+ values?: string[];
106
+ /** quality: the ladder, in order */
107
+ stages?: string[];
108
+ purpose?: string;
109
+ }
110
+ /** The type list, in the family's order, with the words the select shows. */
111
+ declare const PROPERTY_TYPES: ReadonlyArray<readonly [PropertyListType, string]>;
112
+ interface DefaultControlOptions {
113
+ /**
114
+ * How the default is stored. `false` (default): the string the field shows,
115
+ * "" for none (Storyletter's DTO). `true`: a typed value (boolean, number,
116
+ * string), and none DELETES the key (Patterpad's model).
117
+ */
118
+ typed?: boolean;
119
+ }
120
+ /**
121
+ * The type-appropriate control for a declaration's DEFAULT: a true / false
122
+ * picker for a boolean, the value list for an enum, the stage list for a
123
+ * quality (blank = the first rung), a note for flags (a set starts empty), a
124
+ * number or text field otherwise. The one label for "no default" is "(none)".
125
+ */
126
+ declare function defaultControl(p: PropertyDeclLike, onChange?: () => void, opts?: DefaultControlOptions): HTMLElement;
127
+ interface PropertyListOptions<T extends PropertyDeclLike> extends DefaultControlOptions {
128
+ /** Called after every mutation; a centre editor feeds its autosave here. */
129
+ onChange?: () => void;
130
+ /** The add button's label. Default "+ Add property". */
131
+ addLabel?: string;
132
+ /** The empty sentence. Default "No properties yet." */
133
+ emptyText?: string;
134
+ /** The type select's entries; default `PROPERTY_TYPES`. */
135
+ types?: ReadonlyArray<readonly [string, string]>;
136
+ /** A fresh declaration for the add button. Default: a blank of the first type. */
137
+ newDecl?: () => T;
138
+ /** Controls on the row's line, between the default and the movers
139
+ * (Storyletter's "uses" affordance). */
140
+ extraLine?: (decl: T, index: number) => (HTMLElement | null)[];
141
+ /** Fields behind the disclosure, before Values / Stages / Purpose
142
+ * (Shared, Temporary, Read-only, Durable). */
143
+ extraDetails?: (decl: T, index: number) => (HTMLElement | null)[];
144
+ /** Offer the Purpose field. Default true. */
145
+ purpose?: boolean;
146
+ }
147
+ interface PropertyListHandle extends SettingsSectionHandle {
148
+ /** Both faults, for the Save gate: a duplicate first, then an illegal name. */
149
+ firstInvalid(): HTMLInputElement | null;
150
+ /** The first name that clashes with another, or null. */
151
+ firstDuplicate(): HTMLInputElement | null;
152
+ /** The first name no expression could reach, or null. */
153
+ firstIllegalName(): HTMLInputElement | null;
154
+ /** Redraw from `decls` (after an outside change). */
155
+ render(): void;
156
+ }
157
+ /** Mount the list into `host`. Mutates `decls` in place; the caller reads
158
+ * them back on save (pruning blank names is the caller's, since only it
159
+ * knows its DTO). */
160
+ declare function mountPropertyList<T extends PropertyDeclLike>(host: HTMLElement, decls: T[], opts?: PropertyListOptions<T>): PropertyListHandle;
161
+
162
+ export { type DefaultControlOptions as D, PROPERTY_TYPES as P, type SettingsDialog as S, type DupGuard as a, type PropertyDeclLike as b, type PropertyListHandle as c, type PropertyListOptions as d, type PropertyListType as e, type SettingsDialogOptions as f, type SettingsSection as g, type SettingsSectionHandle as h, defaultControl as i, dupGuard as j, expandableRow as k, focusNewRow as l, mountPropertyList as m, mountSettingsDialog as n, revealRowWhenReady as o, revealRow as r };
@@ -0,0 +1,162 @@
1
+ /** A compact list row: a single `.set-rowline` (inline controls) plus, when
2
+ * `details` are given, a disclosure that reveals a `.set-details` panel below,
3
+ * so a list scans like a table with secondary fields tucked away. `name` is
4
+ * what the row declares (a property's name, a field's), stamped on it as
5
+ * `data-name` so `revealRow` can land on it. */
6
+ declare function expandableRow(opts: {
7
+ line: HTMLElement[];
8
+ details?: HTMLElement[];
9
+ name?: string;
10
+ }): HTMLElement;
11
+ /**
12
+ * Land on one row of a list by the `name` it was built with: open its details
13
+ * (an enum's values sit behind the disclosure, and they are usually what the
14
+ * jump was for), bring it to the middle of its scroller, and light it for a
15
+ * moment (`.set-row.landed` in settings.css). "Go to definition" in both apps
16
+ * used to open the page a property is declared on and stop there, with the
17
+ * declaration below the fold and nothing marking it (Storyletter, 2026-09-14).
18
+ *
19
+ * Returns false when no row carries the name, so a host whose page fills in
20
+ * asynchronously can ask again on a later frame; asking again is the host's,
21
+ * since only the host knows what opens on its own time. The row is matched by
22
+ * reading the stamp rather than by an attribute selector, so a name needs no
23
+ * escaping.
24
+ */
25
+ declare function revealRow(within: ParentNode, name: string): boolean;
26
+ /**
27
+ * `revealRow`, retried over the next frames until the row exists or the tries
28
+ * run out: for a page that fills in on its own time after a navigation. Both
29
+ * apps hand-rolled this as `landOn` with the same twelve tries
30
+ * (ui-review-2026-09, finding 29). Resolves true when it landed, false when it
31
+ * gave up, and giving up is quiet: a name no page shows as a row is not a fault.
32
+ */
33
+ declare function revealRowWhenReady(within: ParentNode, name: string, tries?: number): Promise<boolean>;
34
+ /** After a "+ Add" re-renders a list, bring the new (last) row into view and
35
+ * focus its name input (`.set-name`, else the first input). */
36
+ declare function focusNewRow(listEl: HTMLElement | null | undefined): void;
37
+ interface DupGuard {
38
+ /** Forget the previous render's inputs (call at the top of render). */
39
+ reset(): void;
40
+ /** Register a name input; `key` returns the comparison string (default the
41
+ * input's value). Re-checks live on input. `also` = extra inputs that change the key. */
42
+ track(input: HTMLInputElement, key?: () => string, also?: HTMLInputElement[]): void;
43
+ /** Re-paint duplicates; true if any two non-blank keys collide. */
44
+ check(): boolean;
45
+ /** The first input currently flagged (after a fresh check), or null. */
46
+ firstDuplicate(): HTMLInputElement | null;
47
+ }
48
+ /** Case-insensitive duplicate-name detection: paints clashing inputs `.invalid`
49
+ * and lets a Save gate block + jump via `firstDuplicate()`. */
50
+ declare function dupGuard(): DupGuard;
51
+ interface SettingsSectionHandle {
52
+ /** The first invalid control to jump to, blocking Save (e.g. a duplicate
53
+ * name). Return `{ el, message }` to say WHICH fault in the error line;
54
+ * a bare element says it through its own `data-tip` (the dup guard's, a
55
+ * property-name field's), and the line falls back to a generic sentence
56
+ * when it has neither. */
57
+ firstInvalid?(): HTMLElement | {
58
+ el: HTMLElement;
59
+ message?: string;
60
+ } | null;
61
+ }
62
+ interface SettingsSection {
63
+ id: string;
64
+ label: string;
65
+ /** Optional left-rail group heading above this tab. */
66
+ group?: string;
67
+ /** Build the section body into `host`; called fresh on each open so it reads
68
+ * the current data. Return a handle (for the Save gate). */
69
+ mount(host: HTMLElement): SettingsSectionHandle;
70
+ /** Why this tab cannot be used right now, or null when it can. A reason
71
+ * renders the tab dimmed and inert with the reason as its rollover
72
+ * (Patterpad's Audio tab while the project is not voiced). Read on open
73
+ * and on `refreshTabs()`, so a control inside the dialog can flip it. */
74
+ disabled?: () => string | null;
75
+ }
76
+ interface SettingsDialogOptions {
77
+ title: string;
78
+ sections: SettingsSection[];
79
+ /** Fired when Save is clicked and every section validates. The app reads its
80
+ * own section state and persists. May be async; the dialog stays open until
81
+ * it resolves, then closes. */
82
+ onSave: () => void | Promise<void>;
83
+ }
84
+ interface SettingsDialog {
85
+ /** Open (optionally on a given tab id). Sections re-mount from current data. */
86
+ open(tabId?: string): void;
87
+ /** Re-read every section's `disabled()`; a tab that has just become
88
+ * disabled while showing hands over to the first usable one. */
89
+ refreshTabs(): void;
90
+ destroy(): void;
91
+ }
92
+ /** Build a settings dialog. The frame owns the modal, the tab rail, save-on-Save
93
+ * (with a validation gate), and Cancel; the sections own their content + state. */
94
+ declare function mountSettingsDialog(opts: SettingsDialogOptions): SettingsDialog;
95
+
96
+ /** The six types both apps declare. */
97
+ type PropertyListType = "number" | "boolean" | "string" | "enum" | "flags" | "quality";
98
+ /** The shape a row edits. Apps' DTOs carry more (shared, writable, durable);
99
+ * those ride through untouched. */
100
+ interface PropertyDeclLike {
101
+ name: string;
102
+ type: string;
103
+ default?: unknown;
104
+ /** enum / flags */
105
+ values?: string[];
106
+ /** quality: the ladder, in order */
107
+ stages?: string[];
108
+ purpose?: string;
109
+ }
110
+ /** The type list, in the family's order, with the words the select shows. */
111
+ declare const PROPERTY_TYPES: ReadonlyArray<readonly [PropertyListType, string]>;
112
+ interface DefaultControlOptions {
113
+ /**
114
+ * How the default is stored. `false` (default): the string the field shows,
115
+ * "" for none (Storyletter's DTO). `true`: a typed value (boolean, number,
116
+ * string), and none DELETES the key (Patterpad's model).
117
+ */
118
+ typed?: boolean;
119
+ }
120
+ /**
121
+ * The type-appropriate control for a declaration's DEFAULT: a true / false
122
+ * picker for a boolean, the value list for an enum, the stage list for a
123
+ * quality (blank = the first rung), a note for flags (a set starts empty), a
124
+ * number or text field otherwise. The one label for "no default" is "(none)".
125
+ */
126
+ declare function defaultControl(p: PropertyDeclLike, onChange?: () => void, opts?: DefaultControlOptions): HTMLElement;
127
+ interface PropertyListOptions<T extends PropertyDeclLike> extends DefaultControlOptions {
128
+ /** Called after every mutation; a centre editor feeds its autosave here. */
129
+ onChange?: () => void;
130
+ /** The add button's label. Default "+ Add property". */
131
+ addLabel?: string;
132
+ /** The empty sentence. Default "No properties yet." */
133
+ emptyText?: string;
134
+ /** The type select's entries; default `PROPERTY_TYPES`. */
135
+ types?: ReadonlyArray<readonly [string, string]>;
136
+ /** A fresh declaration for the add button. Default: a blank of the first type. */
137
+ newDecl?: () => T;
138
+ /** Controls on the row's line, between the default and the movers
139
+ * (Storyletter's "uses" affordance). */
140
+ extraLine?: (decl: T, index: number) => (HTMLElement | null)[];
141
+ /** Fields behind the disclosure, before Values / Stages / Purpose
142
+ * (Shared, Temporary, Read-only, Durable). */
143
+ extraDetails?: (decl: T, index: number) => (HTMLElement | null)[];
144
+ /** Offer the Purpose field. Default true. */
145
+ purpose?: boolean;
146
+ }
147
+ interface PropertyListHandle extends SettingsSectionHandle {
148
+ /** Both faults, for the Save gate: a duplicate first, then an illegal name. */
149
+ firstInvalid(): HTMLInputElement | null;
150
+ /** The first name that clashes with another, or null. */
151
+ firstDuplicate(): HTMLInputElement | null;
152
+ /** The first name no expression could reach, or null. */
153
+ firstIllegalName(): HTMLInputElement | null;
154
+ /** Redraw from `decls` (after an outside change). */
155
+ render(): void;
156
+ }
157
+ /** Mount the list into `host`. Mutates `decls` in place; the caller reads
158
+ * them back on save (pruning blank names is the caller's, since only it
159
+ * knows its DTO). */
160
+ declare function mountPropertyList<T extends PropertyDeclLike>(host: HTMLElement, decls: T[], opts?: PropertyListOptions<T>): PropertyListHandle;
161
+
162
+ export { type DefaultControlOptions as D, PROPERTY_TYPES as P, type SettingsDialog as S, type DupGuard as a, type PropertyDeclLike as b, type PropertyListHandle as c, type PropertyListOptions as d, type PropertyListType as e, type SettingsDialogOptions as f, type SettingsSection as g, type SettingsSectionHandle as h, defaultControl as i, dupGuard as j, expandableRow as k, focusNewRow as l, mountPropertyList as m, mountSettingsDialog as n, revealRowWhenReady as o, revealRow as r };