@motifx-community/ui 0.1.0-beta.10 → 0.1.0-beta.11

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 (163) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/dist/components/toolbar/Toolbar.d.ts +2 -2
  3. package/dist/index.js +22 -7
  4. package/dist/index.js.map +1 -1
  5. package/docs/accordion.md +1 -1
  6. package/docs/actionsheet.md +1 -1
  7. package/docs/appbar.md +1 -1
  8. package/docs/appmenu-api.md +1 -1
  9. package/docs/appmenu-programmatic.md +1 -1
  10. package/docs/appmenu-search.md +1 -1
  11. package/docs/appmenu.md +1 -1
  12. package/docs/avatar.md +1 -1
  13. package/docs/badge.md +1 -1
  14. package/docs/bar-gauge-angles.md +1 -1
  15. package/docs/bar-gauge-data.md +1 -1
  16. package/docs/bar-gauge-labels.md +1 -1
  17. package/docs/bar-gauge.md +1 -1
  18. package/docs/barcode.md +1 -1
  19. package/docs/bottomnavigation.md +1 -1
  20. package/docs/bottomsheet.md +1 -1
  21. package/docs/breadcrumb.md +1 -1
  22. package/docs/button.md +2 -2
  23. package/docs/buttongroup.md +1 -1
  24. package/docs/buttons.md +3 -5
  25. package/docs/calendar.md +1 -1
  26. package/docs/card.md +1 -1
  27. package/docs/chart-bars.md +1 -1
  28. package/docs/chart-candles.md +1 -1
  29. package/docs/chart-funnel.md +1 -1
  30. package/docs/chart-heatmap.md +1 -1
  31. package/docs/chart-lines.md +1 -1
  32. package/docs/chart-live.md +1 -1
  33. package/docs/chart-pie.md +1 -1
  34. package/docs/chart-radar.md +1 -1
  35. package/docs/chart-ranges.md +1 -1
  36. package/docs/chart-references.md +1 -1
  37. package/docs/chart-scatter.md +1 -1
  38. package/docs/chart-waterfall.md +1 -1
  39. package/docs/chart-zoom.md +1 -1
  40. package/docs/chart.md +1 -1
  41. package/docs/checkbox.md +1 -1
  42. package/docs/chip.md +1 -1
  43. package/docs/choice.md +1 -1
  44. package/docs/colorbox.md +1 -1
  45. package/docs/combobox.md +1 -1
  46. package/docs/commands.md +126 -0
  47. package/docs/control.md +1 -1
  48. package/docs/data.md +1 -1
  49. package/docs/datagrid-api.md +3 -3
  50. package/docs/datagrid-bands.md +1 -1
  51. package/docs/datagrid-drag-select.md +1 -1
  52. package/docs/datagrid-drag.md +1 -1
  53. package/docs/datagrid-editing.md +107 -1
  54. package/docs/datagrid-filtering.md +11 -3
  55. package/docs/datagrid-forms.md +1 -1
  56. package/docs/datagrid-grouping.md +1 -1
  57. package/docs/datagrid-layout.md +2 -2
  58. package/docs/datagrid-lookups.md +1 -1
  59. package/docs/datagrid-master-detail.md +1 -1
  60. package/docs/datagrid-scrolling.md +1 -1
  61. package/docs/datagrid-selection.md +1 -1
  62. package/docs/datagrid.md +1 -1
  63. package/docs/datebox.md +1 -1
  64. package/docs/daterangebox.md +1 -1
  65. package/docs/display.md +1 -1
  66. package/docs/draggable.md +1 -1
  67. package/docs/drawer.md +1 -1
  68. package/docs/dropdown.md +1 -1
  69. package/docs/editors.md +3 -1
  70. package/docs/feedback.md +1 -1
  71. package/docs/fileuploader.md +1 -1
  72. package/docs/filterbuilder.md +1 -1
  73. package/docs/formlayout.md +1 -1
  74. package/docs/foundations.md +1 -1
  75. package/docs/gallery.md +1 -1
  76. package/docs/gauge-base.md +1 -1
  77. package/docs/gauge-circular.md +1 -1
  78. package/docs/gauge-dashboards.md +1 -1
  79. package/docs/gauge-linear.md +1 -1
  80. package/docs/gauge-markers.md +1 -1
  81. package/docs/gauge-marks.md +1 -1
  82. package/docs/gauge-ranges.md +1 -1
  83. package/docs/gauge-scales.md +1 -1
  84. package/docs/gauge.md +1 -1
  85. package/docs/home.md +2 -2
  86. package/docs/keyboard.md +5 -3
  87. package/docs/language.md +2 -2
  88. package/docs/layout.md +1 -1
  89. package/docs/listbox.md +1 -1
  90. package/docs/loadpanel.md +2 -2
  91. package/docs/lookup.md +1 -1
  92. package/docs/menus-api.md +142 -0
  93. package/docs/menus-context.md +126 -0
  94. package/docs/menus-customization.md +138 -0
  95. package/docs/menus-merging.md +208 -0
  96. package/docs/menus-programmatic.md +74 -0
  97. package/docs/menus.md +22 -179
  98. package/docs/multiview.md +1 -1
  99. package/docs/navigation.md +7 -2
  100. package/docs/numberbox.md +3 -3
  101. package/docs/otpinput.md +1 -1
  102. package/docs/pagination.md +1 -1
  103. package/docs/popover.md +1 -1
  104. package/docs/progress.md +3 -3
  105. package/docs/qrcode.md +1 -1
  106. package/docs/radiogroup.md +1 -1
  107. package/docs/rating.md +1 -1
  108. package/docs/resizable.md +1 -1
  109. package/docs/ribbonmenu-api.md +1 -1
  110. package/docs/ribbonmenu-commands.md +1 -1
  111. package/docs/ribbonmenu-customization.md +1 -1
  112. package/docs/ribbonmenu-display.md +1 -1
  113. package/docs/ribbonmenu-layouts.md +1 -1
  114. package/docs/ribbonmenu-programmatic.md +1 -1
  115. package/docs/ribbonmenu.md +1 -1
  116. package/docs/scheduler-agenda.md +1 -1
  117. package/docs/scheduler-big-data.md +1 -1
  118. package/docs/scheduler-editing.md +1 -1
  119. package/docs/scheduler-form.md +1 -1
  120. package/docs/scheduler-icalendar.md +1 -1
  121. package/docs/scheduler-mobile.md +1 -1
  122. package/docs/scheduler-recurrence.md +1 -1
  123. package/docs/scheduler-resources.md +1 -1
  124. package/docs/scheduler-timeline.md +1 -1
  125. package/docs/scheduler.md +1 -1
  126. package/docs/scrollview.md +1 -1
  127. package/docs/shortcuteditor.md +248 -0
  128. package/docs/showcase-home.md +1 -1
  129. package/docs/showcase.md +1 -1
  130. package/docs/signature.md +1 -1
  131. package/docs/skeleton.md +1 -1
  132. package/docs/slider.md +3 -3
  133. package/docs/sortable.md +1 -1
  134. package/docs/sparkline.md +1 -1
  135. package/docs/speeddial.md +1 -1
  136. package/docs/splitter.md +1 -1
  137. package/docs/stepper.md +1 -1
  138. package/docs/switch.md +1 -1
  139. package/docs/tabdocs-dock.md +1 -1
  140. package/docs/tabdocs-drag.md +1 -1
  141. package/docs/tabdocs-menus.md +1 -1
  142. package/docs/tabdocs-mobile.md +1 -1
  143. package/docs/tabdocs-tabs.md +1 -1
  144. package/docs/tabdocs-windows.md +1 -1
  145. package/docs/tabdocs-workspace.md +1 -1
  146. package/docs/tabdocs.md +1 -1
  147. package/docs/tabs.md +1 -1
  148. package/docs/tagbox.md +1 -1
  149. package/docs/textarea.md +1 -1
  150. package/docs/textbox.md +1 -1
  151. package/docs/tileview.md +1 -1
  152. package/docs/timeline.md +1 -1
  153. package/docs/toast.md +1 -1
  154. package/docs/tokens.md +13 -1
  155. package/docs/toolbar.md +1 -1
  156. package/docs/tooltip.md +1 -1
  157. package/docs/treeview.md +1 -1
  158. package/docs/validationsummary.md +1 -1
  159. package/docs/window.md +1 -1
  160. package/docs/wizard.md +1 -1
  161. package/llms-full.txt +3774 -2692
  162. package/llms.txt +16 -6
  163. package/package.json +1 -1
package/docs/scheduler.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Scheduler
2
2
 
3
- > Scheduler · @motifx-community/ui 0.1.0-beta.8
3
+ > Scheduler · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A full-featured calendar for appointments across days and hours. It provides day, week, work week and month views, all-day and multi-day bars, side-by-side display of overlapping appointments, and a "+N more" link when a day is full. Appointments can come from an array or a data source, and every setting can change at runtime.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # ScrollView
2
2
 
3
- > Navigation · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A scrollable container with configurable scrollbars, pull-to-refresh, and load-on-scroll near the end of the content. You can scroll it programmatically to a position or an element.
6
6
 
@@ -0,0 +1,248 @@
1
+ # ShortcutEditor
2
+
3
+ > Editors · @motifx-community/ui 0.1.0-beta.10
4
+
5
+ A list of the app’s keyboard shortcuts in which the user assigns other keys. It shows the shortcuts of commands, of the app and of the kit’s components, and you can place it anywhere: a settings page, a dialog or a tab.
6
+
7
+ ## Import
8
+
9
+ ```tsx
10
+ import { ShortcutEditor } from '@motifx-community/ui';
11
+ ```
12
+
13
+ ## Changing the keys of shortcuts
14
+
15
+ The editor lists the shortcuts in `shortcuts`, the registry that holds every keyboard shortcut of the app. Select a shortcut, press the new keys in the field, and choose Assign. The field says first whether the keys are free or which shortcut uses them. Remove keys leaves a shortcut without keys, and Reset gives it its own keys again.
16
+
17
+ ```tsx
18
+ import { reactive } from '@motifx/core';
19
+ import { ShortcutEditor, Stack, commands, type Keymap } from '@motifx-community/ui';
20
+
21
+ /**
22
+ * The app's commands, limited to this example, and an editor for their keys. The keys the user gives arrive in
23
+ * `onKeysChanged`, ready to save; giving them back to `shortcuts.keymap` restores them.
24
+ */
25
+ export default function Basic() {
26
+ const s = reactive({ told: 'Nothing yet.', keymap: {} as Keymap });
27
+ const run = (what: string) => () => (s.told = what);
28
+
29
+ return (
30
+ <Stack
31
+ gap="md"
32
+ ref={(host: Stack) => {
33
+ commands.add({ key: 'demo.save', text: '&Save', shortcut: 'Mod+S', category: 'File', scope: host, run: run('Save') });
34
+ commands.add({ key: 'demo.print', text: '&Print', shortcut: 'Mod+P', category: 'File', scope: host, run: run('Print') });
35
+ commands.add({ key: 'demo.find', text: '&Find', shortcut: 'Mod+F', category: 'Edit', scope: host, run: run('Find') });
36
+ commands.add({ key: 'demo.replace', text: '&Replace', category: 'Edit', scope: host, run: run('Replace') });
37
+ }}
38
+ >
39
+ <ShortcutEditor height="22rem" filter={(info) => info.customizable && !!info.name?.startsWith('demo.')} onKeysChanged={(e) => (s.keymap = e.keymap)} />
40
+ <p tabIndex={0} class="se-page">Click here, then press the keys: they work while focus is in this example.</p>
41
+ <output class="se-told">{() => s.told}</output>
42
+ <pre class="se-keymap">{() => JSON.stringify(s.keymap)}</pre>
43
+ </Stack>
44
+ );
45
+ }
46
+ ```
47
+
48
+ ## Saving the user’s keys
49
+
50
+ The keys the user assigns are kept in `shortcuts.keymap`, a plain object keyed by the shortcut’s name. `onKeysChanged`, or `shortcuts.onKeymapChanged`, reports it after each change; assigning a saved object to `shortcuts.keymap` restores the keys. Where the object is stored is up to the app.
51
+
52
+ ```tsx
53
+ shortcuts.keymap = JSON.parse(localStorage.getItem('keys') ?? '{}');
54
+ shortcuts.onKeymapChanged((e) => localStorage.setItem('keys', JSON.stringify(e.keymap)));
55
+ ```
56
+
57
+ A shortcut added later, such as one of a component opened after the keymap was restored, takes the user’s keys for its name when it is added.
58
+
59
+ ## In a dialog
60
+
61
+ The editor fills the height of its parent, so it can be the content of a window or a tab panel. Without a `filter`, it lists every shortcut of the page the user can change: here, the shortcuts of this documentation site.
62
+
63
+ ```tsx
64
+ import { Button, MxForm, ShortcutEditor } from '@motifx-community/ui';
65
+
66
+ /** The editor in a window of its own, as a settings dialog opens it. It lists every shortcut of this site. */
67
+ export default function InWindow() {
68
+ const open = (button: Button) => {
69
+ const form = new MxForm({ title: 'Keyboard shortcuts', width: '40rem', height: '30rem', resizable: true, modal: true });
70
+ form.content = new ShortcutEditor();
71
+ form.footer = <Button text="Close" tone="accent" onclick={() => form.close('ok')} />;
72
+ void form.showDialog(button);
73
+ };
74
+ let button!: Button;
75
+ return <Button text="Keyboard shortcuts…" variant="outline" ref={(b: Button) => (button = b)} onclick={() => open(button)} />;
76
+ }
77
+ ```
78
+
79
+ The customizer of a [MenuBar](menus-customization.md) shows the same editor on its Keyboard page; `customizerKeyboard: false` leaves the page out.
80
+
81
+ ## Which shortcuts are listed
82
+
83
+ A shortcut is listed when it has a name. `addShortcut` takes the name, the text the list shows and the category it is grouped under; `customizable: false` keeps its keys fixed. Several shortcuts with one name, such as the same action in two documents, are one row and take the same keys. `filter` chooses the rows, `grouped`, `searchEnabled` and `resetAllEnabled` turn the parts of the editor on and off.
84
+
85
+ ```tsx
86
+ import { reactive } from '@motifx/core';
87
+ import { ShortcutEditor, Stack, Switch, addShortcut, type ShortcutInfo } from '@motifx-community/ui';
88
+
89
+ /**
90
+ * Shortcuts of the app's own (`addShortcut` with a name), one the user cannot change, and the switches of the editor:
91
+ * the categories, the search field, the reset button, and every shortcut or only the ones the user can change.
92
+ */
93
+ export default function Options() {
94
+ const s = reactive({ grouped: true, search: true, resetAll: true, all: false });
95
+ const ours = (info: ShortcutInfo) => !!info.name?.startsWith('options.');
96
+ const changeable = (info: ShortcutInfo) => info.customizable && ours(info);
97
+
98
+ return (
99
+ <Stack
100
+ gap="md"
101
+ ref={(host: Stack) => {
102
+ const stops = [
103
+ addShortcut(['F5', 'Mod+R'], () => {}, { scope: host, name: 'options.reload', text: 'Reload', category: 'View' }),
104
+ addShortcut('Mod+=', () => {}, { scope: host, name: 'options.zoomIn', text: 'Zoom in', category: 'View' }),
105
+ addShortcut('Mod+-', () => {}, { scope: host, name: 'options.zoomOut', text: 'Zoom out', category: 'View' }),
106
+ addShortcut('F1', () => {}, { scope: host, name: 'options.help', text: 'Help', category: 'Help', customizable: false }),
107
+ ];
108
+ host.motif.setDisposable(() => stops.forEach((stop) => stop()));
109
+ }}
110
+ >
111
+ <Stack orientation="horizontal" gap="lg" wrap>
112
+ <Switch label="Categories" x-model={() => s.grouped} />
113
+ <Switch label="Search" x-model={() => s.search} />
114
+ <Switch label="Reset all keys" x-model={() => s.resetAll} />
115
+ <Switch label="Fixed shortcuts too" x-model={() => s.all} />
116
+ </Stack>
117
+ <ShortcutEditor
118
+ height="20rem"
119
+ grouped={() => s.grouped}
120
+ searchEnabled={() => s.search}
121
+ resetAllEnabled={() => s.resetAll}
122
+ filter={() => (s.all ? ours : changeable)}
123
+ />
124
+ </Stack>
125
+ );
126
+ }
127
+ ```
128
+
129
+ ```tsx
130
+ addShortcut(['F5', 'Mod+R'], () => view.reload(), { name: 'view.reload', text: () => t('Reload'), category: () => t('View') });
131
+ ```
132
+
133
+ ## Shortcuts of the kit’s components
134
+
135
+ The kit’s components register their shortcuts under names of their own, with texts in the kit’s language. The user’s keys apply to them as to any other shortcut.
136
+
137
+ | Component | Names | Shortcuts |
138
+ | --- | --- | --- |
139
+ | `Commands (`commands.add`)` | The key of the command | The text and the category of the command. |
140
+ | `TabDocumentManager` | `tabDocuments.<action>`, such as `tabDocuments.closeTab`; `tabDocuments.focusGroup1` to `9` | Each action of `keys`. The keys of a mode, such as moving a window with the arrow keys, are read inside the mode and are not listed. |
141
+ | `Toaster` | `toaster.focus` | The key that moves focus to the notifications. |
142
+ | `MenuBar` | `menuBar.focus` | F10, with `focusOnF10`. |
143
+
144
+ ## Programmatic use
145
+
146
+ `new ShortcutEditor(props)` creates the editor without JSX. Each prop is also a property; `selected`, `give()` and `resetAll()` do what the toolbar does.
147
+
148
+ ```tsx
149
+ import { Component } from '@motifx/core';
150
+ import { Button, ShortcutEditor, Stack, addShortcut } from '@motifx-community/ui';
151
+
152
+ /** An editor created programmatically: a shortcut is selected and given other keys from code, then reset. */
153
+ export default class Programmatic extends Component<HTMLDivElement> {
154
+ constructor() {
155
+ super('div');
156
+ const stack = new Stack({ gap: 'md' });
157
+ const stop = addShortcut('Mod+K', () => {}, { scope: stack, name: 'code.palette', text: 'Command palette', category: 'Go' });
158
+ stack.motif.setDisposable(stop);
159
+ const editor = new ShortcutEditor({ height: '10rem', filter: (info) => info.name === 'code.palette' });
160
+ const give = new Button({
161
+ text: 'Give it Ctrl+Shift+P',
162
+ variant: 'outline',
163
+ onclick: () => {
164
+ editor.selected = 'code.palette';
165
+ editor.give(['Ctrl+Shift+P']);
166
+ },
167
+ });
168
+ const reset = new Button({ text: 'Reset all keys', variant: 'outline', onclick: () => editor.resetAll() });
169
+ const buttons = new Stack({ orientation: 'horizontal', gap: 'sm' });
170
+ buttons.controls.add(give, reset);
171
+ stack.controls.add(editor, buttons);
172
+ this.controls.add(stack);
173
+ }
174
+ }
175
+ ```
176
+
177
+ ## API reference
178
+
179
+ ### Props
180
+
181
+ | Prop | Type | Default | Description |
182
+ | --- | --- | --- | --- |
183
+ | `filter` | `Bind<((shortcut: ShortcutInfo) => boolean) \| null>` | The shortcuts the user can change | Which shortcuts are listed. A shortcut the user cannot change is listed with its row turned off. |
184
+ | `grouped` | `Bind<boolean>` | `true` | Lists the shortcuts under their categories. A shortcut without one is listed under “Other”. |
185
+ | `searchEnabled` | `Bind<boolean>` | `true` | Shows a search field above the list. |
186
+ | `resetAllEnabled` | `Bind<boolean>` | `true` | Shows the button that gives every shortcut its own keys again. |
187
+ | `height` | `Bind<string \| null>` | The height of the parent | The height, as a CSS length. |
188
+ | `label` | `Bind<string>` | The kit string “Keyboard shortcuts” | The accessible name. |
189
+
190
+ ### Properties and methods
191
+
192
+ | Member | Type | Description |
193
+ | --- | --- | --- |
194
+ | `selected` | `string \| null` | The name of the selected shortcut. Settable. |
195
+ | `give(keys)` | `boolean` | Gives the selected shortcut the keys (an empty list removes its keys), or its own keys again with `null`. Returns `false` when no shortcut the user can change is selected. |
196
+ | `resetAll()` | `void` | Gives every shortcut its own keys again. |
197
+ | `refresh()` | `void` | Reads the shortcuts and their keys again. The editor does this when shortcuts are added or removed, and when the language changes. |
198
+
199
+ ### Events
200
+
201
+ | Event | Type | Description |
202
+ | --- | --- | --- |
203
+ | `onKeysChanged` | `{ name, keys, keymap }` | Occurs after the user changes the keys of a shortcut. `name` is `null` after a reset of all keys; `keymap` holds every key the user has given, to save. |
204
+
205
+ ### Shortcut options for the list
206
+
207
+ | Option of addShortcut | Type | Description |
208
+ | --- | --- | --- |
209
+ | `name` | `string` | Names what the shortcut does. Shortcuts with the same name share the keys the user gives them. Without a name, a shortcut is not listed and cannot be changed. |
210
+ | `text` | `string \| (() => string)` | How the shortcut reads in the list. A function is read again when the language changes. |
211
+ | `category` | `string \| (() => string)` | The heading the list groups the shortcut under. |
212
+ | `customizable` | `boolean` | `false` keeps the shortcut’s own keys. It is still listed when the filter allows it. |
213
+
214
+ ### Keyboard
215
+
216
+ | Where | Keys |
217
+ | --- | --- |
218
+ | `A row` | The arrow keys, Home and End move through the list; typing in the search field filters it. |
219
+ | `The keys field` | Takes the keys pressed instead of running them. Backspace clears it; Tab and Escape keep their usual meaning. |
220
+
221
+ ### Accessibility
222
+
223
+ | Topic | Details |
224
+ | --- | --- |
225
+ | `Name` | The editor is a group named by `label`; the list, the toolbar and the keys field have names of their own. |
226
+ | `Status` | The text that says who uses the keys pressed is a live region, read when it changes. |
227
+ | `Keys` | Keys are written as the platform writes them: Ctrl+Shift+S, and ⇧⌘S on Apple platforms. |
228
+
229
+ ### Styling hooks
230
+
231
+ | Hook | Description |
232
+ | --- | --- |
233
+ | `.mx-shortcut-editor` | The editor. |
234
+ | `.mx-shortcut-editor__tools, .mx-shortcut-editor__keys, .mx-shortcut-editor__capture` | The toolbar, the keys row and its field. |
235
+ | `.mx-shortcut-editor__status` | The text that says who uses the keys pressed. |
236
+ | `.mx-shortcut-editor__list` | The list of shortcuts. |
237
+ | `.mx-shortcut-editor__text, .mx-shortcut-editor__changed, .mx-shortcut-editor__row-keys` | A row: the name of the shortcut, the mark of keys the user changed, and its keys. |
238
+
239
+ ### Design tokens
240
+
241
+ | Token | Description |
242
+ | --- | --- |
243
+ | `shortcut-editor.editor, .keys` | Units: the editor and the keys row, with the `gap` between their parts. |
244
+ | `shortcut-editor.status, .row-keys, .changed` | Units: the status text, the keys at the end of a row (read as in a menu), and the mark of changed keys. |
245
+
246
+ ## Feedback
247
+
248
+ Loading issues…
@@ -1,6 +1,6 @@
1
1
  # Showcase: a smart home
2
2
 
3
- > Get started · @motifx-community/ui 0.1.0-beta.8
3
+ > Get started · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A smart home panel for a tablet, built with the kit as a MotifJS application of its own: a rail of screens, the day and the home's state at the top, and tiles you can touch. The devices report new values every two seconds.
6
6
 
package/docs/showcase.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Showcase: an order screen
2
2
 
3
- > Get started · @motifx-community/ui 0.1.0-beta.8
3
+ > Get started · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  An order entry screen built with the kit, structured the way a MotifJS application is normally built: state and operations live in a model (`OrderModel`), and the page binds to it. The customer list is a data source of 5,000 rows that responds like a server.
6
6
 
package/docs/signature.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Signature
2
2
 
3
- > Editors · @motifx-community/ui 0.1.0-beta.8
3
+ > Editors · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A pad to sign on with a pen, a finger or a mouse. The value is the strokes themselves, so a signature can be stored as data, drawn again at any size and exported as an image.
6
6
 
package/docs/skeleton.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Skeleton
2
2
 
3
- > Display · @motifx-community/ui 0.1.0-beta.8
3
+ > Display · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A placeholder that matches the shape of content that is loading, so the page keeps its layout while data arrives. If you provide content, it replaces the placeholder in the same place when loading ends.
6
6
 
package/docs/slider.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Slider
2
2
 
3
- > Editors · @motifx-community/ui 0.1.0-beta.8
3
+ > Editors · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Selects a value on a track by dragging a thumb or using the keyboard. It supports a single number or a range with two thumbs, steps, labeled tick marks, a value tooltip, a vertical orientation and number formatting, along with the label, help text and validation common to all fields.
6
6
 
@@ -243,7 +243,7 @@ export default function States() {
243
243
 
244
244
  ## Localization
245
245
 
246
- The names of the two thumbs in a range come from `uiLocale.strings` (`minimum`, `maximum`). Numbers use `locale`, which defaults to the kit's language, `uiLocale.locale`.
246
+ The names of the two thumbs in a range come from `uiLocale.strings` (`minimum`, `maximum`). Numbers use `locale`, which defaults to the page `lang`.
247
247
 
248
248
  ```tsx
249
249
  import { reactive } from '@motifx/core';
@@ -326,7 +326,7 @@ export default function Localization() {
326
326
  | `tickLabels` | `Bind<boolean>` | `false` | Shows values under the marks, or at the two ends if there are no marks. |
327
327
  | `showValue` | `Bind<'never' \| 'drag' \| 'always'>` | `'never'` | Shows a value tooltip above the thumb: never, while it moves (with the pointer or keyboard), or always. |
328
328
  | `format` | `Bind<Intl.NumberFormatOptions \| null>` | `null` | The format used by the tooltip, the tick labels and screen readers. |
329
- | `locale` | `Bind<string>` | `uiLocale.locale` | The locale of `format`. |
329
+ | `locale` | `Bind<string>` | The page `lang` | The locale of `format`. |
330
330
  | `valueText` | `(value: number) => string` | — | The text screen readers announce for a value. Because it is a function, it is stored as is and not bound. |
331
331
  | `updateOn` | `Bind<'input' \| 'change'>` | `'input'` | With `change`, the value updates when the thumb is released. The thumb still moves during the drag. |
332
332
  | `name` | `Bind<string>` | `''` | The name submitted with the form. A range submits two values. |
package/docs/sortable.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Sortable
2
2
 
3
- > Navigation · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Lets users reorder items by dragging them with the pointer or a finger, or with the keyboard. Lists in the same group can exchange items. A drop moves the element and reports the indexes, while your data stays under your control.
6
6
 
package/docs/sparkline.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Sparkline
2
2
 
3
- > Charts · @motifx-community/ui 0.1.0-beta.8
3
+ > Charts · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A chart the size of a word, for a trend beside a number, in a sentence or in a row of a table. It draws a line, an area, bars, or wins and losses, and marks the values that matter.
6
6
 
package/docs/speeddial.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # SpeedDial
2
2
 
3
- > Buttons · @motifx-community/ui 0.1.0-beta.8
3
+ > Buttons · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A floating action button that opens a set of related actions. Place it in a corner, on an edge or inline. Actions appear in a line with labels, or on a full, half or quarter circle around the button with tooltips. If there is only one action, the main button performs it directly.
6
6
 
package/docs/splitter.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Splitter
2
2
 
3
- > Navigation · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Divides space into any number of resizable panes, arranged side by side or stacked. A handle between each pair of panes can be dragged or moved with the keyboard, and it resizes the two panes next to it. Panes can be collapsed from their handle and can contain another splitter. For two panes where one has a fixed size, see [SplitContainer](layout.md).
6
6
 
package/docs/stepper.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Stepper
2
2
 
3
- > Navigation · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Shows the steps of a longer task and the user's progress through them. Each step has an indicator and text, with a line between steps, and steps before the current one are marked complete. [Wizard](wizard.md) adds a page and navigation buttons to each step.
6
6
 
package/docs/switch.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Switch
2
2
 
3
- > Choice · @motifx-community/ui 0.1.0-beta.8
3
+ > Choice · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  An on/off switch with a label. It has a track with a sliding thumb, optional on/off text inside or next to the track, and read-only and required states. It is a native check box with the switch role.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager: Dock and floating windows
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Documents and whole groups can float in their own windows within the page, and dock again into document groups or into dock areas around them, which can collapse to the edge of the manager. The mouse, the keyboard and the API all perform the same actions through the same events.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager: Drag and drop
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Drag tabs and whole groups as you would in a code editor: along a strip, to another group, beside a group, along an edge of the layout, or between two managers. The same moves are available from the keyboard, and every drop goes through the methods and events of the action it performs.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager: Menus and keys
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  The commands around tabs: context menus on tabs and on the empty strip, a searchable list of a group's documents, application toolbar buttons, the recently used list, back and forward, reopening closed documents, locked groups, and keyboard shortcuts for all of them.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager: Tablet and phone
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  On tablets and phones, a layout of groups, splits and dock areas does not fit as designed. The manager keeps the layout and changes how it is presented: the documents, groups, areas and saved JSON stay the same, and content is moved rather than recreated. The presentation depends on the manager's own width rather than the device, and on touch screens its tabs and buttons are larger.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager: Tabs
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Tabs that behave as they do in code editors: preview tabs replaced by the next preview, pinned tabs that stay at the start, tabs that shrink, wrap or scroll, counts and colors, and the same document open in two groups.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager: New windows
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A document, a group or a floating window can move into its own browser window and back. Its content moves with it without being recreated, and the new window is part of the same manager, so its tabs, menus, keys and dragging work the same way.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager: A whole workspace
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A complete screen built from kit components: a menu bar, the manager, a DataGrid with every feature enabled, forms, and a tool docked at the bottom. Each part is the same component documented on its own page, and the manager simply hosts them.
6
6
 
package/docs/tabdocs.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # TabDocumentManager
2
2
 
3
- > TabDocumentManager · @motifx-community/ui 0.1.0-beta.8
3
+ > TabDocumentManager · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A document manager that arranges content the way code editors arrange files: documents in tabs, tabs in groups, and groups split side by side or one above the other. A document's content can be any component, such as a form, a grid or plain text, and it is moved rather than recreated when its tab goes to another group. Every user action is also a method, with a cancelable event before it and a notification after it, and the whole layout can be saved to JSON and restored. Preview and pinned tabs, sizes and copies are covered in [Tabs](tabdocs-tabs.md), and context menus, lists and keyboard shortcuts in [Menus and keys](tabdocs-menus.md).
6
6
 
package/docs/tabs.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Tabs
2
2
 
3
- > Navigation · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Tabs display one panel at a time below a tab strip. You can define them in JSX or programmatically, and they support closable tabs, icons and badges, scroll buttons when tabs overflow, four placements, and panels that are created on first display.
6
6
 
package/docs/tagbox.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # TagBox
2
2
 
3
- > Data · @motifx-community/ui 0.1.0-beta.8
3
+ > Data · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Selects multiple items. Selected items appear as tags in the field, followed by a text input that searches the list. Items can come from memory or from a data source, and typed text can become a custom tag.
6
6
 
package/docs/textarea.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # TextArea
2
2
 
3
- > Editors · @motifx-community/ui 0.1.0-beta.8
3
+ > Editors · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A multi-line text input. The box can grow with its content or be resized by the user, and it supports a character counter, a clear button and Ctrl+Enter to submit, along with the label, help text and validation common to all fields.
6
6
 
package/docs/textbox.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # TextBox
2
2
 
3
- > Editors · @motifx-community/ui 0.1.0-beta.8
3
+ > Editors · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A single-line text input with a label, help text and error display. It supports a placeholder, a prefix and suffix, buttons inside the box, a clear button, a password reveal button, a character counter, an input mask and validation, either on its own, in a group, or across all fields in a panel.
6
6
 
package/docs/tileview.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # TileView
2
2
 
3
- > Display · @motifx-community/ui 0.1.0-beta.8
3
+ > Display · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Arranges tiles of different sizes on a grid of base cells, where each tile spans a set number of cells. Tiles fill the height in columns and scroll horizontally, or fill the width in rows. They can be selected and reordered by dragging.
6
6
 
package/docs/timeline.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Timeline
2
2
 
3
- > Display · @motifx-community/ui 0.1.0-beta.8
3
+ > Display · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Displays events in chronological order. In the vertical layout, each event is a card next to a line with a marker. In the horizontal layout, events appear along a line of dates, and selecting a date shows that event's card below the line. Dates are formatted in the kit language. For scheduling by the hour, see [Scheduler](scheduler.md).
6
6
 
package/docs/toast.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Toast
2
2
 
3
- > Feedback · @motifx-community/ui 0.1.0-beta.8
3
+ > Feedback · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Brief notifications at the edge of the window, with four tones, an optional action such as Undo, a custom duration or none, six positions and a limit on how many appear at once. Show them programmatically, or place a custom region in JSX.
6
6
 
package/docs/tokens.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Design tokens
2
2
 
3
- > Get started · @motifx-community/ui 0.1.0-beta.8
3
+ > Get started · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  The token system has five layers. The first four (primitives, design language scales, semantic tokens per theme, and density) come from `@motifx-community/design-system` and are listed here for reference. The fifth layer, component tokens, belongs to this kit: each component has its own tokens, written in `@layer mx.components`, and each one references a design system token. Every design language provides its own value for each component token.
6
6
 
@@ -1097,6 +1097,9 @@ Source: `tokens/schema/*.json` for names and types, and `tokens/languages/<langu
1097
1097
  | `combo-box.arrow-glyph.icon` | `--mx-combo-box-arrow-glyph-icon` | `` | `var(--mx-icon-chevron-down)` |
1098
1098
  | `combo-box.arrow-glyph.open.rotate` | `--mx-combo-box-arrow-glyph-open-rotate` | `` | `0.5turn` |
1099
1099
  | `combo-box.loading.color` | `--mx-combo-box-loading-color` | `color.fg.secondary` | `#5e5c55` |
1100
+ | `customizer.page.gap` | `--mx-customizer-page-gap` | `space.3` | `0.75rem` |
1101
+ | `customizer.buttons.gap` | `--mx-customizer-buttons-gap` | `space.2` | `0.5rem` |
1102
+ | `customizer.footer.gap` | `--mx-customizer-footer-gap` | `space.2` | `0.5rem` |
1100
1103
  | `datagrid.record-height` | `--mx-datagrid-record-height` | `control.height.md` | `2rem` |
1101
1104
  | `datagrid.row-space` | `--mx-datagrid-row-space` | `space.1` | `0.25rem` |
1102
1105
  | `datagrid.cell-inset` | `--mx-datagrid-cell-inset` | `control.padding.sm` | `0.5rem` |
@@ -3423,6 +3426,15 @@ Source: `tokens/schema/*.json` for names and types, and `tokens/languages/<langu
3423
3426
  | `sheet.footer.gap` | `--mx-sheet-footer-gap` | `space.2` | `0.5rem` |
3424
3427
  | `sheet.footer.border-top-width` | `--mx-sheet-footer-border-top-width` | `border.width.1` | `1px` |
3425
3428
  | `sheet.footer.border-top-color` | `--mx-sheet-footer-border-top-color` | `color.stroke.divider` | `rgb(0 0 0 / 0.1)` |
3429
+ | `shortcut-editor.editor.gap` | `--mx-shortcut-editor-editor-gap` | `space.3` | `0.75rem` |
3430
+ | `shortcut-editor.keys.gap` | `--mx-shortcut-editor-keys-gap` | `space.3` | `0.75rem` |
3431
+ | `shortcut-editor.status.color` | `--mx-shortcut-editor-status-color` | `color.fg.secondary` | `#5e5c55` |
3432
+ | `shortcut-editor.row-keys.padding-start` | `--mx-shortcut-editor-row-keys-padding-start` | `space.6` | `1.5rem` |
3433
+ | `shortcut-editor.row-keys.color` | `--mx-shortcut-editor-row-keys-color` | `color.fg.secondary` | `#5e5c55` |
3434
+ | `shortcut-editor.row-keys.font-size` | `--mx-shortcut-editor-row-keys-font-size` | `font.size.caption` | `0.75rem` |
3435
+ | `shortcut-editor.changed.padding-start` | `--mx-shortcut-editor-changed-padding-start` | `space.2` | `0.5rem` |
3436
+ | `shortcut-editor.changed.color` | `--mx-shortcut-editor-changed-color` | `color.fg.secondary` | `#5e5c55` |
3437
+ | `shortcut-editor.changed.font-size` | `--mx-shortcut-editor-changed-font-size` | `font.size.caption` | `0.75rem` |
3426
3438
  | `signature.width` | `--mx-signature-width` | `` | `420px` |
3427
3439
  | `signature.height` | `--mx-signature-height` | `` | `160px` |
3428
3440
  | `signature.guide-inset` | `--mx-signature-guide-inset` | `space.6` | `1.5rem` |
package/docs/toolbar.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Toolbar
2
2
 
3
- > Buttons · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A command bar that holds buttons, toggle buttons, menus and fields, organized in groups with separators. The toolbar is a single Tab stop, and the arrow keys move between its controls. Items that do not fit move into an overflow menu at the end. You can define items as data, as JSX children, or both.
6
6
 
package/docs/tooltip.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Tooltip
2
2
 
3
- > Feedback · @motifx-community/ui 0.1.0-beta.8
3
+ > Feedback · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A short description shown next to an element when the pointer rests on it, when it receives keyboard focus, or programmatically. Users can hover over the tooltip, Escape dismisses it, and only one is open at a time on the page.
6
6
 
package/docs/treeview.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # TreeView
2
2
 
3
- > Data · @motifx-community/ui 0.1.0-beta.8
3
+ > Data · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Displays items in a hierarchy. Rows can be expanded and collapsed, selected individually or in groups, and searched. Check boxes can roll up to parent rows, and children can load on demand when a row is first expanded. Large trees render only the visible rows.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # ValidationSummary
2
2
 
3
- > Editors · @motifx-community/ui 0.1.0-beta.8
3
+ > Editors · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Lists the invalid fields of a `ValidationGroup` under a header, with each field's label and message on its own line. Clicking a line moves focus to the field. The summary updates whenever a field in the group is validated or reset, and it is hidden when there are no errors.
6
6
 
package/docs/window.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Window and dialog
2
2
 
3
- > Navigation · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  A window or dialog built on the native `<dialog>` element. A single form can be shown as modeless or modal, depending on how you open it. It has a title bar, can be moved, resized, minimized and maximized, and Enter and Escape activate its buttons. Forms can open other forms, and `messageBox` and `confirm` cover common prompts.
6
6
 
package/docs/wizard.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Wizard
2
2
 
3
- > Navigation · @motifx-community/ui 0.1.0-beta.8
3
+ > Navigation · @motifx-community/ui 0.1.0-beta.10
4
4
 
5
5
  Guides the user through a multi-step task. It combines a [Stepper](stepper.md) above or next to one page per step with Back and Next buttons below. Next validates the page first, and on the last step it finishes the wizard.
6
6