@nanahoshi/mona-ui 0.27.1 → 0.27.2
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.
- package/docs/api/auto-complete.md +67 -0
- package/docs/api/avatar.md +31 -0
- package/docs/api/breadcrumb.md +74 -0
- package/docs/api/button-group.md +71 -0
- package/docs/api/button.md +84 -0
- package/docs/api/calendar.md +123 -0
- package/docs/api/card.md +97 -0
- package/docs/api/chart.md +4380 -0
- package/docs/api/check-box.md +70 -0
- package/docs/api/chip.md +55 -0
- package/docs/api/circular-progress-bar.md +71 -0
- package/docs/api/collapsible.md +71 -0
- package/docs/api/color-gradient.md +54 -0
- package/docs/api/color-palette.md +52 -0
- package/docs/api/color-picker.md +89 -0
- package/docs/api/combo-box.md +69 -0
- package/docs/api/command.md +282 -0
- package/docs/api/common.md +599 -0
- package/docs/api/contextmenu.md +239 -0
- package/docs/api/date-input.md +119 -0
- package/docs/api/date-picker.md +67 -0
- package/docs/api/datetime-picker.md +72 -0
- package/docs/api/dialog.md +291 -0
- package/docs/api/dropdown-button.md +248 -0
- package/docs/api/dropdown-list.md +72 -0
- package/docs/api/dropdowns.md +172 -0
- package/docs/api/editor.md +117 -0
- package/docs/api/expansion-panel.md +85 -0
- package/docs/api/fieldset.md +33 -0
- package/docs/api/filter.md +116 -0
- package/docs/api/grid.md +1445 -0
- package/docs/api/i18n.md +1699 -0
- package/docs/api/label.md +58 -0
- package/docs/api/list-box.md +301 -0
- package/docs/api/list-view.md +294 -0
- package/docs/api/list.md +119 -0
- package/docs/api/locales.md +134 -0
- package/docs/api/menubar.md +275 -0
- package/docs/api/multi-select.md +92 -0
- package/docs/api/notification.md +164 -0
- package/docs/api/numeric-text-box.md +130 -0
- package/docs/api/otp-input.md +100 -0
- package/docs/api/pager.md +371 -0
- package/docs/api/placeholder.md +18 -0
- package/docs/api/popover.md +170 -0
- package/docs/api/popup-menu.md +328 -0
- package/docs/api/popup.md +299 -0
- package/docs/api/progress-bar.md +79 -0
- package/docs/api/query.md +367 -0
- package/docs/api/radio-button.md +113 -0
- package/docs/api/rating.md +187 -0
- package/docs/api/scroll-view.md +93 -0
- package/docs/api/segmented.md +114 -0
- package/docs/api/sheet.md +65 -0
- package/docs/api/sidebar.md +583 -0
- package/docs/api/skeleton.md +26 -0
- package/docs/api/slider.md +173 -0
- package/docs/api/spinner.md +132 -0
- package/docs/api/split-button.md +261 -0
- package/docs/api/splitter.md +57 -0
- package/docs/api/stepper.md +148 -0
- package/docs/api/switch.md +78 -0
- package/docs/api/tabs.md +139 -0
- package/docs/api/text-area.md +20 -0
- package/docs/api/text-box.md +106 -0
- package/docs/api/theme.md +627 -0
- package/docs/api/time-picker.md +69 -0
- package/docs/api/time-selector.md +54 -0
- package/docs/api/tooltip.md +112 -0
- package/docs/api/tree-view.md +631 -0
- package/docs/api/window.md +245 -0
- package/docs/auto-complete.md +28 -329
- package/docs/avatar.md +4 -24
- package/docs/breadcrumb.md +10 -65
- package/docs/button-group.md +7 -60
- package/docs/button.md +8 -67
- package/docs/calendar.md +16 -121
- package/docs/card.md +16 -79
- package/docs/chart-bar.md +16 -234
- package/docs/chart-financial.md +10 -121
- package/docs/chart-funnel.md +13 -176
- package/docs/chart-heatmap.md +15 -131
- package/docs/chart-line-area.md +12 -137
- package/docs/chart-pie.md +17 -221
- package/docs/chart-radar.md +13 -129
- package/docs/chart-radial.md +13 -211
- package/docs/chart-scatter.md +6 -74
- package/docs/chart-treemap.md +14 -196
- package/docs/chart.md +154 -1892
- package/docs/checkbox.md +5 -61
- package/docs/chip.md +7 -42
- package/docs/circular-progress-bar.md +9 -61
- package/docs/collapsible.md +5 -87
- package/docs/color-gradient.md +8 -81
- package/docs/color-palette.md +7 -69
- package/docs/color-picker.md +9 -105
- package/docs/combo-box.md +28 -331
- package/docs/command.md +25 -236
- package/docs/contextmenu.md +15 -140
- package/docs/date-picker.md +7 -110
- package/docs/datetime-picker.md +7 -129
- package/docs/decimal-textbox.md +6 -69
- package/docs/dialog.md +23 -263
- package/docs/dropdown-button.md +15 -146
- package/docs/dropdown-list.md +29 -332
- package/docs/editor.md +8 -164
- package/docs/expansion-panel.md +7 -69
- package/docs/fieldset.md +5 -24
- package/docs/grid-columns.md +12 -92
- package/docs/grid-editing.md +29 -291
- package/docs/grid-grouping.md +11 -50
- package/docs/grid-rows.md +10 -74
- package/docs/grid-selection.md +7 -36
- package/docs/grid-server.md +8 -293
- package/docs/grid-sorting-filtering.md +10 -333
- package/docs/grid-state-export.md +17 -228
- package/docs/grid.md +23 -216
- package/docs/input.md +7 -19
- package/docs/label.md +8 -39
- package/docs/list-box.md +21 -253
- package/docs/list-view.md +25 -232
- package/docs/menubar.md +21 -167
- package/docs/multi-select.md +31 -350
- package/docs/notification.md +17 -116
- package/docs/numeric-textbox.md +9 -78
- package/docs/otp-input.md +9 -95
- package/docs/pager.md +19 -239
- package/docs/placeholder.md +5 -18
- package/docs/popover.md +13 -123
- package/docs/popup-menu.md +22 -243
- package/docs/popup.md +24 -248
- package/docs/progress-bar.md +10 -75
- package/docs/radio-button.md +8 -96
- package/docs/range-slider.md +9 -82
- package/docs/rating.md +15 -163
- package/docs/scroll-view.md +9 -86
- package/docs/segmented.md +8 -90
- package/docs/sheet.md +10 -74
- package/docs/sidebar-menus.md +20 -155
- package/docs/sidebar-state.md +16 -134
- package/docs/sidebar.md +18 -218
- package/docs/skeleton.md +5 -26
- package/docs/slider.md +9 -97
- package/docs/spinner.md +15 -95
- package/docs/split-button.md +21 -166
- package/docs/splitter.md +9 -56
- package/docs/stepper.md +13 -127
- package/docs/switch.md +8 -58
- package/docs/tabs.md +13 -111
- package/docs/textarea.md +4 -13
- package/docs/textbox.md +10 -77
- package/docs/time-picker.md +7 -112
- package/docs/tooltip-directive.md +12 -96
- package/docs/tooltip.md +12 -96
- package/docs/tree-view.md +42 -495
- package/docs/window.md +19 -230
- package/fesm2022/nanahoshi-mona-ui-collapsible.mjs +1 -0
- package/fesm2022/nanahoshi-mona-ui-common.mjs +3 -0
- package/fesm2022/nanahoshi-mona-ui-date-input.mjs +13 -1
- package/fesm2022/nanahoshi-mona-ui-dropdowns.mjs +5 -0
- package/fesm2022/nanahoshi-mona-ui-i18n.mjs +9 -0
- package/llms.txt +74 -0
- package/package.json +1 -1
- package/types/nanahoshi-mona-ui-collapsible.d.ts +2 -0
- package/types/nanahoshi-mona-ui-common.d.ts +6 -0
- package/types/nanahoshi-mona-ui-date-input.d.ts +18 -1
- package/types/nanahoshi-mona-ui-dropdowns.d.ts +6 -0
- package/types/nanahoshi-mona-ui-i18n.d.ts +12 -0
package/docs/breadcrumb.md
CHANGED
|
@@ -247,74 +247,19 @@ When multiple breadcrumbs appear on the same page, each should have a distinct `
|
|
|
247
247
|
|
|
248
248
|
## API
|
|
249
249
|
|
|
250
|
-
Everything below is imported from `@nanahoshi/mona-ui/breadcrumb`.
|
|
250
|
+
Everything below is imported from `@nanahoshi/mona-ui/breadcrumb`. Each name links to its reference page, with every input, output, property and method.
|
|
251
251
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
**Selector:** `mona-breadcrumb`
|
|
255
|
-
|
|
256
|
-
#### Inputs
|
|
257
|
-
|
|
258
|
-
| Name | Type | Default | Description |
|
|
259
|
-
| --- | --- | --- | --- |
|
|
260
|
-
| `aria-label` | `string` | `""` | Accessible name for the breadcrumb navigation landmark. Override when multiple breadcrumb components appear on the same page. |
|
|
261
|
-
| `class` | `string` | `""` | Additional CSS classes merged onto the breadcrumb list via `tailwind-merge`. |
|
|
262
|
-
| `disabled` | `boolean` | `false` | Renders the entire breadcrumb with reduced visual emphasis and removes pointer interaction from all items. |
|
|
263
|
-
| `lastItemCurrent` | `boolean` | `true` | Treats the last item as the current page: not a button, and marked `aria-current="page"`. Turn it off for a trail that ends before the page you're on. |
|
|
264
|
-
| `maxItems` | `number \| null` | `null` | The most items to show before the middle of the trail collapses behind a button that shows it again. The first and last items always stay, so anything below 2 counts as 2. `null` never collapses. |
|
|
265
|
-
|
|
266
|
-
### `BreadcrumbItemComponent`
|
|
267
|
-
|
|
268
|
-
Use as a direct child of `<mona-breadcrumb>`. Project any Angular content — text, icons, or elements — into the
|
|
269
|
-
default slot.
|
|
270
|
-
|
|
271
|
-
**Selector:** `mona-breadcrumb-item`
|
|
272
|
-
|
|
273
|
-
#### Inputs
|
|
274
|
-
|
|
275
|
-
| Name | Type | Default | Description |
|
|
276
|
-
| --- | --- | --- | --- |
|
|
277
|
-
| `disabled` | `boolean` | `false` | Renders this item with reduced visual emphasis and removes pointer interaction. Has no visual effect when the parent breadcrumb is also disabled. |
|
|
278
|
-
|
|
279
|
-
#### Outputs
|
|
280
|
-
|
|
281
|
-
| Name | Type | Description |
|
|
252
|
+
| Name | Kind | Description |
|
|
282
253
|
| --- | --- | --- |
|
|
283
|
-
| `
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
Makes a projected anchor the item's link, so the browser and the router treat it as one: ctrl-click, copy link, `href`,
|
|
288
|
-
`routerLink`, `target`. The item then renders no button around it.
|
|
289
|
-
|
|
290
|
-
**Selector:** `a[monaBreadcrumbLink]`
|
|
291
|
-
|
|
292
|
-
#### Inputs
|
|
293
|
-
|
|
294
|
-
| Name | Type | Default | Description |
|
|
295
|
-
| --- | --- | --- | --- |
|
|
296
|
-
| `class` | `string` | `""` | Additional CSS classes merged onto the link via `tailwind-merge`. |
|
|
297
|
-
|
|
298
|
-
### `BreadcrumbSeparatorTemplateDirective`
|
|
299
|
-
|
|
300
|
-
Apply to an `<ng-template>` directly inside `<mona-breadcrumb>` to replace the default `ChevronRight` separator. One
|
|
301
|
-
directive per breadcrumb — the first match is used.
|
|
302
|
-
|
|
303
|
-
**Selector:** `ng-template[monaBreadcrumbSeparatorTemplate]`
|
|
254
|
+
| [`BreadcrumbComponent`](api/breadcrumb.md#breadcrumbcomponent) | Component | |
|
|
255
|
+
| [`BreadcrumbItemComponent`](api/breadcrumb.md#breadcrumbitemcomponent) | Component | Use as a direct child of `<mona-breadcrumb>`. |
|
|
256
|
+
| [`BreadcrumbLinkDirective`](api/breadcrumb.md#breadcrumblinkdirective) | Directive | Makes a projected anchor the item's link, so the browser and the router treat it as one: ctrl-click, copy link, `href`, `routerLink`, `target`. |
|
|
257
|
+
| [`BreadcrumbSeparatorTemplateDirective`](api/breadcrumb.md#breadcrumbseparatortemplatedirective) | Directive | Apply to an `<ng-template>` directly inside `<mona-breadcrumb>` to replace the default `ChevronRight` separator. |
|
|
304
258
|
|
|
305
259
|
### Types
|
|
306
260
|
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
```typescript
|
|
310
|
-
const BREADCRUMB_DEFAULT_MESSAGES: MonaBreadcrumbMessages;
|
|
311
|
-
```
|
|
312
|
-
|
|
313
|
-
#### `MonaBreadcrumbMessages`
|
|
314
|
-
|
|
315
|
-
From `@nanahoshi/mona-ui/i18n`.
|
|
316
|
-
|
|
317
|
-
| Name | Type |
|
|
261
|
+
| Type | Kind |
|
|
318
262
|
| --- | --- |
|
|
319
|
-
| `
|
|
320
|
-
|
|
263
|
+
| [`BREADCRUMB_DEFAULT_MESSAGES`](api/breadcrumb.md#breadcrumb-default-messages) | Constant |
|
|
264
|
+
|
|
265
|
+
**Related types:** [`MonaBreadcrumbMessages`](api/i18n.md#monabreadcrumbmessages)
|
package/docs/button-group.md
CHANGED
|
@@ -323,70 +323,17 @@ Each child button's `aria-pressed` attribute is managed by `ButtonDirective` and
|
|
|
323
323
|
|
|
324
324
|
## API
|
|
325
325
|
|
|
326
|
-
Everything below is imported from `@nanahoshi/mona-ui/button-group`.
|
|
327
|
-
|
|
328
|
-
### `ButtonGroupComponent`
|
|
329
|
-
|
|
330
|
-
**Selector:** `mona-button-group`
|
|
331
|
-
**Type parameters:** `T = unknown`
|
|
332
|
-
**Implements:** `FormValueControl<T \| readonly T[] \| null \| undefined>`
|
|
333
|
-
|
|
334
|
-
#### Inputs
|
|
335
|
-
|
|
336
|
-
| Name | Type | Default | Description |
|
|
337
|
-
| --- | --- | --- | --- |
|
|
338
|
-
| `allowEmpty` | `boolean` | `true` | When `false` and `selection` is `"single"`, a selected button stays selected until another one takes over: the active button can't be deselected, and clearing every `selected` brings it back. It doesn't choose a first button, and a `value` of `null` still clears the group, so a form can reset it. Has no effect in `"multiple"` mode. |
|
|
339
|
-
| `aria-label` | `string \| undefined` | `undefined` | Accessible name for the host element. Override when multiple button groups appear on the same page so screen reader users can distinguish them. |
|
|
340
|
-
| `aria-labelledby` | `string` | `""` | Id of the element that names the group. |
|
|
341
|
-
| `class` | `string` | `""` | Additional CSS classes merged onto the host element via `tailwind-merge`. |
|
|
342
|
-
| `disabled` | `boolean` | `false` | Renders all child buttons with reduced visual emphasis and removes pointer interaction. When bound to a signal form field via `[formField]`, this is written by the `FormField` directive. |
|
|
343
|
-
| `invalid` | `boolean` | `false` | Marks the group as invalid. Error styling requires both `invalid` and `touched` to be `true`. When bound to a signal form field via `[formField]`, this is written by the `FormField` directive. |
|
|
344
|
-
| `look` | `"default" \| "error" \| "ghost" \| "info" \| "outline" \| "primary" \| "secondary" \| "success" \| "warning"` | `"outline"` | Visual style variant propagated to all child buttons. Also controls container-level divider and border behavior. |
|
|
345
|
-
| `readonly` | `boolean` | `false` | Prevents selection changes while the buttons stay focusable. Buttons that aren't toggleable keep working. When bound to a signal form field via `[formField]`, this is written by the `FormField` directive. |
|
|
346
|
-
| `rounded` | `"full" \| "large" \| "medium" \| "none" \| "small"` | `"medium"` | Border-radius preset applied to the container and the outer corners of the first and last child button. |
|
|
347
|
-
| `selection` | `SelectionMode` | `"multiple"` | Whether one button can be selected at a time (`"single"`) or each toggles on its own (`"multiple"`). The buttons stay toggle buttons with `aria-pressed` in both. For a choice that must always hold one value, use `mona-segmented`, which is a radio group. |
|
|
348
|
-
| `size` | `"large" \| "medium" \| "small"` | `"medium"` | Size preset propagated to all child buttons, overriding their individual `size` inputs. |
|
|
349
|
-
| `touched` | `boolean` | `false` | Marks the group as touched. When bound to a signal form field via `[formField]`, this is written by the `FormField` directive. |
|
|
350
|
-
| `value` (two-way) | `T \| readonly T[] \| null \| undefined` | `undefined` | The value of the selected button in `"single"` mode, or `null`, and an array of the selected buttons' values in `"multiple"` mode. Buttons take part by having a `value`. While `undefined`, it leaves each button's `selected` alone. A value with no button yet stays, so one that loads before its button isn't lost. Use either this or `[(selected)]` on the buttons, not both. |
|
|
351
|
-
|
|
352
|
-
#### Outputs
|
|
353
|
-
|
|
354
|
-
| Name | Type | Description |
|
|
355
|
-
| --- | --- | --- |
|
|
356
|
-
| `buttonClick` | `ButtonGroupClickEvent<T>` | Emitted when a button placed directly in the group is clicked, toggleable or not, after the group has applied its selection. Not emitted for a dropdown or split button's own buttons, for a disabled button, or for a toggle button while the group is read-only, since nothing was selected. |
|
|
357
|
-
| `touch` | `void` | Emitted when a user changes the selection or focus leaves the group. The `FormField` directive listens to this to mark the field as touched. |
|
|
358
|
-
| `valueChange` | `T \| readonly T[] \| null \| undefined` | Emitted when `value` changes. |
|
|
359
|
-
|
|
360
|
-
#### Methods
|
|
326
|
+
Everything below is imported from `@nanahoshi/mona-ui/button-group`. Each name links to its reference page, with every input, output, property and method.
|
|
361
327
|
|
|
362
|
-
|
|
|
328
|
+
| Name | Kind |
|
|
363
329
|
| --- | --- |
|
|
364
|
-
| `
|
|
330
|
+
| [`ButtonGroupComponent`](api/button-group.md#buttongroupcomponent) | Component |
|
|
365
331
|
|
|
366
332
|
### Types
|
|
367
333
|
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
```typescript
|
|
371
|
-
const BUTTON_GROUP_DEFAULT_MESSAGES: { buttonGroup: string; };
|
|
372
|
-
```
|
|
373
|
-
|
|
374
|
-
#### `ButtonGroupClickEvent`
|
|
375
|
-
|
|
376
|
-
What `mona-button-group` reports about a clicked button.
|
|
377
|
-
|
|
378
|
-
**Type parameters:** `T = unknown`
|
|
379
|
-
|
|
380
|
-
| Name | Type | Description |
|
|
334
|
+
| Type | Kind | Description |
|
|
381
335
|
| --- | --- | --- |
|
|
382
|
-
| `
|
|
383
|
-
| `
|
|
384
|
-
| `value` (read-only) | `T \| undefined` | The button's `value`, if it has one. |
|
|
385
|
-
|
|
386
|
-
#### `SelectionMode`
|
|
336
|
+
| [`BUTTON_GROUP_DEFAULT_MESSAGES`](api/button-group.md#button-group-default-messages) | Constant | |
|
|
337
|
+
| [`ButtonGroupClickEvent`](api/button-group.md#buttongroupclickevent) | Interface | What `mona-button-group` reports about a clicked button. |
|
|
387
338
|
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
```typescript
|
|
391
|
-
type SelectionMode = "single" | "multiple";
|
|
392
|
-
```
|
|
339
|
+
**Related types:** [`SelectionMode`](api/common.md#selectionmode)
|
package/docs/button.md
CHANGED
|
@@ -182,75 +182,16 @@ The following attributes are managed automatically:
|
|
|
182
182
|
|
|
183
183
|
## API
|
|
184
184
|
|
|
185
|
-
Everything below is imported from `@nanahoshi/mona-ui/button`.
|
|
185
|
+
Everything below is imported from `@nanahoshi/mona-ui/button`. Each name links to its reference page, with every input, output, property and method.
|
|
186
186
|
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
#### Inputs
|
|
192
|
-
|
|
193
|
-
| Name | Type | Default | Description |
|
|
194
|
-
| --- | --- | --- | --- |
|
|
195
|
-
| `aria-haspopup` | `ButtonAriaHasPopup` | `"false"` | Value forwarded to the `aria-haspopup` attribute. Set when this button triggers a popup, menu, listbox, tree, grid, or dialog. Omit or leave as `"false"` for plain action buttons. |
|
|
196
|
-
| `class` | `string` | `""` | Additional CSS classes merged onto the host element via `tailwind-merge`. |
|
|
197
|
-
| `disabled` | `boolean` | `false` | Renders the component with reduced visual emphasis and removes pointer interaction. Accepts the bare attribute form (`<button monaButton disabled>`). When inside a `ButtonGroup`, the button is disabled when either it or the group is disabled. |
|
|
198
|
-
| `iconOnly` | `boolean` | `false` | Removes horizontal padding and fixes a square aspect ratio sized to match `size`. Provide `aria-label` on the host when using icon-only buttons; in dev mode, an icon-only button without an accessible name logs a warning. |
|
|
199
|
-
| `loading` | `boolean` | `false` | Displays a loading indicator and prevents interaction while an operation is in progress. Sets `aria-busy="true"` and `aria-disabled="true"` on the host. The button stays focusable, so keyboard focus isn't lost when loading starts, and clicks (including form submission) are blocked until it ends. |
|
|
200
|
-
| `look` (two-way) | `"clear" \| "default" \| "error" \| "ghost" \| "info" \| "link" \| "outline" \| "primary" \| "secondary" \| "success" \| "warning"` | `"default"` | Visual style variant of the button. When inside a `ButtonGroup`, the group's look takes precedence. `"outline"` looks the same as `"default"`. `"clear"` shows no selected state, so use another look for toggle buttons. |
|
|
201
|
-
| `rounded` | `"full" \| "large" \| "medium" \| "none" \| "small"` | `"medium"` | Border-radius preset applied to the component. When inside a `ButtonGroup`, the group's value takes precedence. |
|
|
202
|
-
| `selected` (two-way) | `boolean` | `false` | Whether the button is in the selected/pressed state. Drives `aria-pressed` when the button is toggleable. Managed by `toggleable` click handling or by `ButtonGroup` selection policy. |
|
|
203
|
-
| `size` | `"large" \| "medium" \| "small"` | `"medium"` | Size preset controlling the button's height and horizontal padding. When inside a `ButtonGroup`, the group's value takes precedence. |
|
|
204
|
-
| `tabindex` | `string \| number` | `0` | Tab index of the host element. Automatically overridden to `-1` when the button is disabled. Accepts a numeric string and converts it to a number; a value that is not a number falls back to `0`. |
|
|
205
|
-
| `toggleable` | `boolean \| undefined` | `undefined` | Enables toggle behavior — each click flips the `selected` state and `aria-pressed` is managed. Accepts the bare attribute form. Buttons in a `ButtonGroup` are toggleable unless this is set to `false`. |
|
|
206
|
-
| `type` | `"button" \| "reset" \| "submit"` | `"button"` | Native `type` attribute of the button. Defaults to `"button"` to prevent accidental form submission; set to `"submit"` or `"reset"` explicitly when that behavior is intended. |
|
|
207
|
-
| `value` | `unknown` | `undefined` | What a `ButtonGroup`'s `value` holds while this button is selected. A button without one takes no part in the group's `value`. |
|
|
208
|
-
|
|
209
|
-
#### Outputs
|
|
210
|
-
|
|
211
|
-
| Name | Type | Description |
|
|
212
|
-
| --- | --- | --- |
|
|
213
|
-
| `lookChange` | `"clear" \| "default" \| "error" \| "ghost" \| "info" \| "link" \| "outline" \| "primary" \| "secondary" \| "success" \| "warning"` | Emitted when `look` changes. |
|
|
214
|
-
| `selectedChange` | `boolean` | Emitted when `selected` changes. |
|
|
215
|
-
|
|
216
|
-
#### Properties
|
|
217
|
-
|
|
218
|
-
| Name | Type | Description |
|
|
219
|
-
| --- | --- | --- |
|
|
220
|
-
| `effectiveDisabled` (read-only) | `Signal<boolean>` | Whether the button is disabled, by its own input or its group's. A dropdown or split button reads this to close its menu. |
|
|
221
|
-
| `effectiveToggleable` (read-only) | `Signal<boolean>` | Whether a click toggles the button: buttons in a group do unless `toggleable` is `false`. The group reads this to know which buttons take part in its selection. |
|
|
187
|
+
| Name | Kind |
|
|
188
|
+
| --- | --- |
|
|
189
|
+
| [`ButtonDirective`](api/button.md#buttondirective) | Directive |
|
|
222
190
|
|
|
223
191
|
### Types
|
|
224
192
|
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
Provided by a component that implements `ButtonGroupMember`, so a `mona-button-group` can find it among its
|
|
228
|
-
content children.
|
|
229
|
-
|
|
230
|
-
```typescript
|
|
231
|
-
const BUTTON_GROUP_MEMBER: InjectionToken<ButtonGroupMember>;
|
|
232
|
-
```
|
|
233
|
-
|
|
234
|
-
#### `ButtonGroupMember`
|
|
235
|
-
|
|
236
|
-
A component whose own buttons join the `mona-button-group` it is placed in, such as a dropdown or split button.
|
|
237
|
-
Those buttons follow the group's look, size, rounding and disabled state, but they aren't toggleable and take no
|
|
238
|
-
part in the group's selection.
|
|
239
|
-
|
|
240
|
-
| Name | Type | Description |
|
|
193
|
+
| Type | Kind | Description |
|
|
241
194
|
| --- | --- | --- |
|
|
242
|
-
| `
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
Values accepted by the `aria-haspopup` input of `ButtonDirective`. `"false"` (the default) omits the attribute.
|
|
247
|
-
|
|
248
|
-
```typescript
|
|
249
|
-
type ButtonAriaHasPopup = "dialog" | "false" | "grid" | "listbox" | "menu" | "tree" | "true";
|
|
250
|
-
```
|
|
251
|
-
|
|
252
|
-
#### `ButtonVariantsInput`
|
|
253
|
-
|
|
254
|
-
```typescript
|
|
255
|
-
type ButtonVariantsInput = VariantInputs<ButtonVariantProps>;
|
|
256
|
-
```
|
|
195
|
+
| [`BUTTON_GROUP_MEMBER`](api/button.md#button-group-member) | Constant | Provided by a component that implements `ButtonGroupMember`, so a `mona-button-group` can find it among its content children. |
|
|
196
|
+
| [`ButtonGroupMember`](api/button.md#buttongroupmember) | Interface | A component whose own buttons join the `mona-button-group` it is placed in, such as a dropdown or split button. |
|
|
197
|
+
| [`ButtonAriaHasPopup`](api/button.md#buttonariahaspopup) | Type alias | Values accepted by the `aria-haspopup` input of `ButtonDirective`. |
|
package/docs/calendar.md
CHANGED
|
@@ -387,129 +387,24 @@ All keyboard actions apply to the focused cell of the grid. The grid is one Tab
|
|
|
387
387
|
|
|
388
388
|
## API
|
|
389
389
|
|
|
390
|
-
Everything below is imported from `@nanahoshi/mona-ui/calendar`.
|
|
391
|
-
|
|
392
|
-
### `CalendarComponent`
|
|
393
|
-
|
|
394
|
-
**Selector:** `mona-calendar`
|
|
395
|
-
**Implements:** `FormValueControl<Date \| Date[] \| null>`
|
|
396
|
-
|
|
397
|
-
#### Inputs
|
|
398
|
-
|
|
399
|
-
| Name | Type | Default | Description |
|
|
400
|
-
| --- | --- | --- | --- |
|
|
401
|
-
| `class` | `string` | `""` | Adds custom CSS classes to the calendar host element. |
|
|
402
|
-
| `disabled` | `boolean` | `false` | Sets the disabled state of the calendar. |
|
|
403
|
-
| `disabledDates` | `DateDisabledType` | — | Sets the disabled dates of the calendar. Accepts either an iterable of Date objects or a predicate function. |
|
|
404
|
-
| `firstDay` | `FirstDayOfWeek \| null` | `null` | Sets the first day of the week. If not specified, derives from the active locale. |
|
|
405
|
-
| `focusOnMount` | `boolean` | `false` | Moves focus to the active day when the calendar first renders. An inline calendar on a page should leave focus where it is; a calendar that opens in a popup sets this so focus moves into it. |
|
|
406
|
-
| `invalid` | `boolean` | `false` | Marks the calendar as invalid. When bound to a signal form field via `[formField]`, this is written by the `FormField` directive. |
|
|
407
|
-
| `maxDate` | `Date \| null` | — | Sets the maximum date that can be selected. |
|
|
408
|
-
| `minDate` | `Date \| null` | — | Sets the minimum date that can be selected. |
|
|
409
|
-
| `readonly` | `boolean` | `false` | Sets the readonly state of the calendar. |
|
|
410
|
-
| `required` | `boolean` | `false` | Sets whether the calendar is required. When bound to a signal form field via `[formField]`, this is written by the `FormField` directive. |
|
|
411
|
-
| `rounded` | `"full" \| "large" \| "medium" \| "none" \| "small"` | `"medium"` | Sets the border radius of the calendar. |
|
|
412
|
-
| `selection` | `CalendarSelection` | `"single"` | Sets the selection mode of the calendar. |
|
|
413
|
-
| `touched` | `boolean` | `false` | Sets the touched state of the calendar. When bound to a signal form field via `[formField]`, this is written by the `FormField` directive. |
|
|
414
|
-
| `value` (two-way) | `Date \| Date[] \| null` | `null` | The current value of the calendar: a `Date` in single selection, the selected dates in multiple selection, and `[start, end]` in range selection. A range is written once both ends are picked. |
|
|
415
|
-
| `weekNumber` | `boolean` | `false` | Enables the display of week numbers in the calendar. |
|
|
416
|
-
|
|
417
|
-
#### Outputs
|
|
418
|
-
|
|
419
|
-
| Name | Type | Description |
|
|
420
|
-
| --- | --- | --- |
|
|
421
|
-
| `touch` | `void` | Emitted when focus leaves the calendar, as a native input is touched on blur. Moving between its buttons and days doesn't count. The `FormField` directive listens to this to mark the field as touched. |
|
|
422
|
-
| `valueChange` | `Date \| Date[] \| null` | Emitted when `value` changes. |
|
|
423
|
-
|
|
424
|
-
### `CalendarDecadeCellTemplateDirective`
|
|
425
|
-
|
|
426
|
-
Provides a custom template for each year cell in the decade view.
|
|
427
|
-
|
|
428
|
-
**Selector:** `ng-template[monaCalendarDecadeCellTemplate]`
|
|
429
|
-
|
|
430
|
-
### `CalendarMonthCellTemplateDirective`
|
|
431
|
-
|
|
432
|
-
Provides a custom template for each day cell in the month view.
|
|
433
|
-
|
|
434
|
-
**Selector:** `ng-template[monaCalendarMonthCellTemplate]`
|
|
435
|
-
|
|
436
|
-
### `CalendarYearCellTemplateDirective`
|
|
437
|
-
|
|
438
|
-
Provides a custom template for each month cell in the year (month-selection) view.
|
|
439
|
-
|
|
440
|
-
**Selector:** `ng-template[monaCalendarYearCellTemplate]`
|
|
441
|
-
|
|
442
|
-
### Types
|
|
443
|
-
|
|
444
|
-
#### `CALENDAR_DEFAULT_MESSAGES`
|
|
445
|
-
|
|
446
|
-
```typescript
|
|
447
|
-
const CALENDAR_DEFAULT_MESSAGES: MonaCalendarMessages;
|
|
448
|
-
```
|
|
449
|
-
|
|
450
|
-
#### `DecadeCellTemplateContext`
|
|
451
|
-
|
|
452
|
-
| Name | Type | Description |
|
|
453
|
-
| --- | --- | --- |
|
|
454
|
-
| `$implicit` | `number` | The year interval of per decade. |
|
|
390
|
+
Everything below is imported from `@nanahoshi/mona-ui/calendar`. Each name links to its reference page, with every input, output, property and method.
|
|
455
391
|
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
| Name | Type | Description |
|
|
392
|
+
| Name | Kind | Description |
|
|
459
393
|
| --- | --- | --- |
|
|
460
|
-
|
|
|
461
|
-
| `
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
| Name | Type | Description |
|
|
466
|
-
| --- | --- | --- |
|
|
467
|
-
| `$implicit` | `number` | The month number (1–12) represented by this cell. |
|
|
468
|
-
| `text` | `string` | The text representation of the month. |
|
|
469
|
-
|
|
470
|
-
#### `CalendarSelection`
|
|
394
|
+
| [`CalendarComponent`](api/calendar.md#calendarcomponent) | Component | |
|
|
395
|
+
| [`CalendarDecadeCellTemplateDirective`](api/calendar.md#calendardecadecelltemplatedirective) | Directive | Provides a custom template for each year cell in the decade view. |
|
|
396
|
+
| [`CalendarMonthCellTemplateDirective`](api/calendar.md#calendarmonthcelltemplatedirective) | Directive | Provides a custom template for each day cell in the month view. |
|
|
397
|
+
| [`CalendarYearCellTemplateDirective`](api/calendar.md#calendaryearcelltemplatedirective) | Directive | Provides a custom template for each month cell in the year (month-selection) view. |
|
|
471
398
|
|
|
472
|
-
|
|
473
|
-
type CalendarSelection = "multiple" | "range" | "single";
|
|
474
|
-
```
|
|
475
|
-
|
|
476
|
-
#### `FirstDayOfWeek`
|
|
477
|
-
|
|
478
|
-
```typescript
|
|
479
|
-
type FirstDayOfWeek = | "monday" | "tuesday" | "wednesday" | "thursday" | "friday" | "saturday" | "sunday";
|
|
480
|
-
```
|
|
481
|
-
|
|
482
|
-
#### `DateDisabledType`
|
|
483
|
-
|
|
484
|
-
From `@nanahoshi/mona-ui/date-input`.
|
|
485
|
-
|
|
486
|
-
```typescript
|
|
487
|
-
type DateDisabledType = Iterable<Date> | Predicate<Date> | null | undefined;
|
|
488
|
-
```
|
|
489
|
-
|
|
490
|
-
#### `MonaCalendarMessages`
|
|
491
|
-
|
|
492
|
-
From `@nanahoshi/mona-ui/i18n`.
|
|
399
|
+
### Types
|
|
493
400
|
|
|
494
|
-
|
|
|
401
|
+
| Type | Kind |
|
|
495
402
|
| --- | --- |
|
|
496
|
-
| `
|
|
497
|
-
| `
|
|
498
|
-
| `
|
|
499
|
-
| `
|
|
500
|
-
| `
|
|
501
|
-
| `
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
**Methods**
|
|
505
|
-
|
|
506
|
-
| Signature |
|
|
507
|
-
| --- |
|
|
508
|
-
| `calendarLabel(formattedMonthAndYear: string): string` |
|
|
509
|
-
| `decadeRange(start: number, end: number): string` |
|
|
510
|
-
| `decadeViewLabel(start: number, end: number): string` |
|
|
511
|
-
| `goToToday(formattedDate: string): string` |
|
|
512
|
-
| `switchToDecadeView(currentYear: string): string` |
|
|
513
|
-
| `switchToYearView(currentMonthAndYear: string): string` |
|
|
514
|
-
| `yearCellLabel(year: number): string` |
|
|
515
|
-
| `yearViewLabel(year: string): string` |
|
|
403
|
+
| [`CALENDAR_DEFAULT_MESSAGES`](api/calendar.md#calendar-default-messages) | Constant |
|
|
404
|
+
| [`DecadeCellTemplateContext`](api/calendar.md#decadecelltemplatecontext) | Interface |
|
|
405
|
+
| [`MonthCellTemplateContext`](api/calendar.md#monthcelltemplatecontext) | Interface |
|
|
406
|
+
| [`YearCellTemplateContext`](api/calendar.md#yearcelltemplatecontext) | Interface |
|
|
407
|
+
| [`CalendarSelection`](api/calendar.md#calendarselection) | Type alias |
|
|
408
|
+
| [`FirstDayOfWeek`](api/calendar.md#firstdayofweek) | Type alias |
|
|
409
|
+
|
|
410
|
+
**Related types:** [`DateDisabledType`](api/date-input.md#datedisabledtype), [`MonaCalendarMessages`](api/i18n.md#monacalendarmessages)
|
package/docs/card.md
CHANGED
|
@@ -207,86 +207,23 @@ A card's colors come from `--color-card` and `--color-card-foreground`, and its
|
|
|
207
207
|
|
|
208
208
|
## API
|
|
209
209
|
|
|
210
|
-
Everything below is imported from `@nanahoshi/mona-ui/card`.
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
|
219
|
-
|
|
|
220
|
-
| `
|
|
221
|
-
| `role` | `"article" \| "group" \| "region"` | `"group"` | The role the card takes when it has a title, which then names it. Use `article` for self-contained content or `region` for a landmark. |
|
|
222
|
-
| `rounded` | `"large" \| "medium" \| "none" \| "small" \| "xlarge" \| "xxlarge"` | `"medium"` | Controls the border radius applied to the card and its header/footer regions. |
|
|
223
|
-
|
|
224
|
-
### `CardFooterComponent`
|
|
225
|
-
|
|
226
|
-
**Selector:** `mona-card-footer`
|
|
227
|
-
|
|
228
|
-
#### Inputs
|
|
229
|
-
|
|
230
|
-
| Name | Type | Default | Description |
|
|
231
|
-
| --- | --- | --- | --- |
|
|
232
|
-
| `class` | `ClassInputType` | `""` | Additional CSS classes merged onto the rendered footer element via `tailwind-merge`. |
|
|
233
|
-
|
|
234
|
-
### `CardHeaderComponent`
|
|
235
|
-
|
|
236
|
-
**Selector:** `mona-card-header`
|
|
237
|
-
|
|
238
|
-
#### Inputs
|
|
239
|
-
|
|
240
|
-
| Name | Type | Default | Description |
|
|
241
|
-
| --- | --- | --- | --- |
|
|
242
|
-
| `class` | `ClassInputType` | `""` | Additional CSS classes merged onto the rendered header element via `tailwind-merge`. |
|
|
243
|
-
|
|
244
|
-
### `CardActionDirective`
|
|
245
|
-
|
|
246
|
-
**Selector:** `ng-template[monaCardAction]`
|
|
247
|
-
|
|
248
|
-
### `CardContentDirective`
|
|
249
|
-
|
|
250
|
-
**Selector:** `ng-template[monaCardContent]`
|
|
251
|
-
|
|
252
|
-
### `CardDescriptionDirective`
|
|
253
|
-
|
|
254
|
-
**Selector:** `ng-template[monaCardDescription]`
|
|
255
|
-
|
|
256
|
-
#### Template context
|
|
257
|
-
|
|
258
|
-
| Name | Type | Description |
|
|
259
|
-
| --- | --- | --- |
|
|
260
|
-
| `$implicit` | `string` | An id for the element in the template, if something needs to refer to it. The card doesn't need it for its name. |
|
|
261
|
-
|
|
262
|
-
### `CardTitleDirective`
|
|
263
|
-
|
|
264
|
-
**Selector:** `ng-template[monaCardTitle]`
|
|
265
|
-
|
|
266
|
-
#### Template context
|
|
267
|
-
|
|
268
|
-
| Name | Type | Description |
|
|
269
|
-
| --- | --- | --- |
|
|
270
|
-
| `$implicit` | `string` | An id for the element in the template, if something needs to refer to it. The card doesn't need it for its name. |
|
|
210
|
+
Everything below is imported from `@nanahoshi/mona-ui/card`. Each name links to its reference page, with every input, output, property and method.
|
|
211
|
+
|
|
212
|
+
| Name | Kind |
|
|
213
|
+
| --- | --- |
|
|
214
|
+
| [`CardComponent`](api/card.md#cardcomponent) | Component |
|
|
215
|
+
| [`CardFooterComponent`](api/card.md#cardfootercomponent) | Component |
|
|
216
|
+
| [`CardHeaderComponent`](api/card.md#cardheadercomponent) | Component |
|
|
217
|
+
| [`CardActionDirective`](api/card.md#cardactiondirective) | Directive |
|
|
218
|
+
| [`CardContentDirective`](api/card.md#cardcontentdirective) | Directive |
|
|
219
|
+
| [`CardDescriptionDirective`](api/card.md#carddescriptiondirective) | Directive |
|
|
220
|
+
| [`CardTitleDirective`](api/card.md#cardtitledirective) | Directive |
|
|
271
221
|
|
|
272
222
|
### Types
|
|
273
223
|
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
```
|
|
279
|
-
|
|
280
|
-
#### `CardTemplateContext`
|
|
281
|
-
|
|
282
|
-
| Name | Type | Description |
|
|
283
|
-
| --- | --- | --- |
|
|
284
|
-
| `$implicit` (read-only) | `string` | An id for the element in the template, if something needs to refer to it. The card doesn't need it for its name. |
|
|
224
|
+
| Type | Kind |
|
|
225
|
+
| --- | --- |
|
|
226
|
+
| [`CARD_DEFAULT_MESSAGES`](api/card.md#card-default-messages) | Constant |
|
|
227
|
+
| [`CardTemplateContext`](api/card.md#cardtemplatecontext) | Interface |
|
|
285
228
|
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
From `@nanahoshi/mona-ui/common`.
|
|
289
|
-
|
|
290
|
-
```typescript
|
|
291
|
-
type ClassInputType = string | string[] | Record<string, unknown> | null | undefined;
|
|
292
|
-
```
|
|
229
|
+
**Related types:** [`ClassInputType`](api/common.md#classinputtype)
|