@nanahoshi/mona-ui 0.37.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.
- package/docs/api/common.md +1 -1
- package/docs/api/date-picker.md +2 -0
- package/docs/api/date-range-picker.md +2 -0
- package/docs/api/datetime-picker.md +2 -0
- package/docs/api/dropdown-list.md +2 -0
- package/docs/api/dropdown-tree.md +81 -0
- package/docs/api/dropdowns.md +34 -8
- package/docs/api/i18n.md +33 -4
- package/docs/api/list.md +1 -1
- package/docs/api/locales.md +14 -14
- package/docs/api/multi-select-tree.md +75 -0
- package/docs/api/multi-select.md +3 -1
- package/docs/api/popup.md +1 -1
- package/docs/api/time-picker.md +2 -0
- package/docs/api/tree-view.md +2 -2
- package/docs/auto-complete.md +2 -0
- package/docs/combo-box.md +2 -0
- package/docs/date-picker.md +5 -1
- package/docs/date-range-picker.md +5 -1
- package/docs/datetime-picker.md +5 -1
- package/docs/dropdown-list.md +52 -0
- package/docs/dropdown-tree.md +427 -0
- package/docs/multi-select-tree.md +353 -0
- package/docs/multi-select.md +6 -0
- package/docs/time-picker.md +5 -1
- package/dropdown-tree/package.json +4 -0
- package/fesm2022/nanahoshi-mona-ui-calendar.mjs +2 -2
- package/fesm2022/nanahoshi-mona-ui-date-picker.mjs +36 -2
- package/fesm2022/nanahoshi-mona-ui-date-range-picker.mjs +37 -3
- package/fesm2022/nanahoshi-mona-ui-datetime-picker.mjs +52 -5
- package/fesm2022/nanahoshi-mona-ui-dropdown-list.mjs +40 -5
- package/fesm2022/nanahoshi-mona-ui-dropdown-tree.mjs +1061 -0
- package/fesm2022/nanahoshi-mona-ui-dropdowns.mjs +730 -60
- package/fesm2022/nanahoshi-mona-ui-editor.mjs +8 -2
- package/fesm2022/nanahoshi-mona-ui-filter.mjs +4 -0
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-list.component-S2iCn8TV.mjs → nanahoshi-mona-ui-grid-grid-list.component-BoSXXLKQ.mjs} +2 -2
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-row.component-BUJvgihp.mjs → nanahoshi-mona-ui-grid-grid-row.component-Df2gfS0X.mjs} +3 -1
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-virtual-list.component-Wndy-_Bt.mjs → nanahoshi-mona-ui-grid-grid-virtual-list.component-xjrcCXXF.mjs} +2 -2
- package/fesm2022/nanahoshi-mona-ui-grid.mjs +8 -4
- package/fesm2022/nanahoshi-mona-ui-i18n-icu.mjs +13 -0
- package/fesm2022/nanahoshi-mona-ui-internal-tree.mjs +80 -37
- package/fesm2022/nanahoshi-mona-ui-locales-ar-sa.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-de-de.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-es-es.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-fr-fr.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-id-id.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-it-it.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-ja-jp.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-ko-kr.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-pl-pl.mjs +17 -0
- package/fesm2022/nanahoshi-mona-ui-locales-pt-br.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-ru-ru.mjs +17 -0
- package/fesm2022/nanahoshi-mona-ui-locales-tr-tr.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-zh-cn.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-locales-zh-tw.mjs +7 -0
- package/fesm2022/nanahoshi-mona-ui-multi-select-tree.mjs +1179 -0
- package/fesm2022/nanahoshi-mona-ui-multi-select.mjs +42 -7
- package/fesm2022/nanahoshi-mona-ui-pager.mjs +3 -1
- package/fesm2022/nanahoshi-mona-ui-time-picker.mjs +39 -4
- package/fesm2022/nanahoshi-mona-ui-tree-view.mjs +2 -1
- package/i18n/catalogs/en-US.messages.json +9 -0
- package/llms.txt +6 -2
- package/locales/ar-sa/ar-sa.messages.json +9 -0
- package/locales/de-de/de-de.messages.json +9 -0
- package/locales/es-es/es-es.messages.json +9 -0
- package/locales/fr-fr/fr-fr.messages.json +9 -0
- package/locales/id-id/id-id.messages.json +9 -0
- package/locales/it-it/it-it.messages.json +9 -0
- package/locales/ja-jp/ja-jp.messages.json +9 -0
- package/locales/ko-kr/ko-kr.messages.json +9 -0
- package/locales/pl-pl/pl-pl.messages.json +9 -0
- package/locales/pt-br/pt-br.messages.json +9 -0
- package/locales/ru-ru/ru-ru.messages.json +9 -0
- package/locales/tr-tr/tr-tr.messages.json +9 -0
- package/locales/zh-cn/zh-cn.messages.json +9 -0
- package/locales/zh-tw/zh-tw.messages.json +9 -0
- package/multi-select-tree/package.json +4 -0
- package/package.json +9 -1
- package/types/nanahoshi-mona-ui-date-picker.d.ts +25 -1
- package/types/nanahoshi-mona-ui-date-range-picker.d.ts +26 -1
- package/types/nanahoshi-mona-ui-datetime-picker.d.ts +34 -1
- package/types/nanahoshi-mona-ui-dropdown-list.d.ts +33 -5
- package/types/nanahoshi-mona-ui-dropdown-tree.d.ts +414 -0
- package/types/nanahoshi-mona-ui-dropdowns.d.ts +218 -9
- package/types/nanahoshi-mona-ui-i18n.d.ts +12 -0
- package/types/nanahoshi-mona-ui-internal-tree.d.ts +36 -0
- package/types/nanahoshi-mona-ui-locales-ar-sa.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-de-de.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-es-es.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-fr-fr.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-id-id.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-it-it.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-ja-jp.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-ko-kr.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-pl-pl.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-pt-br.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-ru-ru.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-tr-tr.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-zh-cn.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-zh-tw.d.ts +9 -0
- package/types/nanahoshi-mona-ui-multi-select-tree.d.ts +456 -0
- package/types/nanahoshi-mona-ui-multi-select.d.ts +43 -7
- package/types/nanahoshi-mona-ui-time-picker.d.ts +29 -2
package/docs/api/common.md
CHANGED
|
@@ -101,7 +101,7 @@ Class.
|
|
|
101
101
|
| `isDefaultPrevented(): boolean` | Whether `preventDefault()` was called. |
|
|
102
102
|
| `preventDefault(): void` | Cancels what the event announces, such as opening or closing a popup, or closing a dialog. |
|
|
103
103
|
|
|
104
|
-
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`CellEditEvent`](grid.md#celleditevent), [`ColumnReorderEvent`](grid.md#columnreorderevent), [`ColumnSortEvent`](grid.md#columnsortevent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DatePickerComponent`](date-picker.md#datepickercomponent), [`DateRangePickerComponent`](date-range-picker.md#daterangepickercomponent), [`DateTimePickerComponent`](datetime-picker.md#datetimepickercomponent), [`DialogActionEvent`](dialog.md#dialogactionevent), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`FilterChangeEvent`](common.md#filterchangeevent), [`GridAddEvent`](grid.md#gridaddevent), [`GridCancelEvent`](grid.md#gridcancelevent), [`GridEditEvent`](grid.md#grideditevent), [`GridRemoveEvent`](grid.md#gridremoveevent), [`GridSaveEvent`](grid.md#gridsaveevent), [`ListBoxClearEvent`](list-box.md#listboxclearevent), [`ListBoxMoveEvent`](list-box.md#listboxmoveevent), [`ListBoxRemoveEvent`](list-box.md#listboxremoveevent), [`ListBoxTransferEvent`](list-box.md#listboxtransferevent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent), [`NodeCheckEvent`](tree-view.md#nodecheckevent), [`NodeClickEvent`](tree-view.md#nodeclickevent), [`NodeSelectEvent`](tree-view.md#nodeselectevent), [`PageSizeChangeEvent`](pager.md#pagesizechangeevent), [`PopoverHideEvent`](popover.md#popoverhideevent), [`PopoverShowEvent`](popover.md#popovershowevent), [`PopupCloseEvent`](popup.md#popupcloseevent), [`PopupMenuCloseEvent`](popup-menu.md#popupmenucloseevent), [`PopupMenuItemClickEvent`](popup-menu.md#popupmenuitemclickevent), [`RowEditEvent`](grid.md#roweditevent), [`RowReorderEvent`](grid.md#rowreorderevent), [`StepSelectEvent`](stepper.md#stepselectevent), [`TabCloseEvent`](tabs.md#tabcloseevent), [`TabSelectEvent`](tabs.md#tabselectevent), [`TimePickerComponent`](time-picker.md#timepickercomponent), [`ToolbarItemDirective`](toolbar.md#toolbaritemdirective)
|
|
104
|
+
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`CellEditEvent`](grid.md#celleditevent), [`ColumnReorderEvent`](grid.md#columnreorderevent), [`ColumnSortEvent`](grid.md#columnsortevent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DatePickerComponent`](date-picker.md#datepickercomponent), [`DateRangePickerComponent`](date-range-picker.md#daterangepickercomponent), [`DateTimePickerComponent`](datetime-picker.md#datetimepickercomponent), [`DialogActionEvent`](dialog.md#dialogactionevent), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`DropdownTreeComponent`](dropdown-tree.md#dropdowntreecomponent), [`FilterChangeEvent`](common.md#filterchangeevent), [`GridAddEvent`](grid.md#gridaddevent), [`GridCancelEvent`](grid.md#gridcancelevent), [`GridEditEvent`](grid.md#grideditevent), [`GridRemoveEvent`](grid.md#gridremoveevent), [`GridSaveEvent`](grid.md#gridsaveevent), [`ListBoxClearEvent`](list-box.md#listboxclearevent), [`ListBoxMoveEvent`](list-box.md#listboxmoveevent), [`ListBoxRemoveEvent`](list-box.md#listboxremoveevent), [`ListBoxTransferEvent`](list-box.md#listboxtransferevent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent), [`MultiSelectTreeComponent`](multi-select-tree.md#multiselecttreecomponent), [`NodeCheckEvent`](tree-view.md#nodecheckevent), [`NodeClickEvent`](tree-view.md#nodeclickevent), [`NodeSelectEvent`](tree-view.md#nodeselectevent), [`PageSizeChangeEvent`](pager.md#pagesizechangeevent), [`PopoverHideEvent`](popover.md#popoverhideevent), [`PopoverShowEvent`](popover.md#popovershowevent), [`PopupCloseEvent`](popup.md#popupcloseevent), [`PopupMenuCloseEvent`](popup-menu.md#popupmenucloseevent), [`PopupMenuItemClickEvent`](popup-menu.md#popupmenuitemclickevent), [`RowEditEvent`](grid.md#roweditevent), [`RowReorderEvent`](grid.md#rowreorderevent), [`StepSelectEvent`](stepper.md#stepselectevent), [`TabCloseEvent`](tabs.md#tabcloseevent), [`TabSelectEvent`](tabs.md#tabselectevent), [`TimePickerComponent`](time-picker.md#timepickercomponent), [`ToolbarItemDirective`](toolbar.md#toolbaritemdirective)
|
|
105
105
|
|
|
106
106
|
## `FilterChangeEvent`
|
|
107
107
|
|
package/docs/api/date-picker.md
CHANGED
|
@@ -15,6 +15,8 @@ Component.
|
|
|
15
15
|
|
|
16
16
|
| Name | Type | Default | Description |
|
|
17
17
|
| --- | --- | --- | --- |
|
|
18
|
+
| `adaptiveMode` | `AdaptiveMode` | `"none"` | Opens the popup as a sheet along the bottom of the screen on a small screen (narrower than 640 pixels) with `"auto"`, so it's easy to reach with a thumb. With `"none"`, it always opens under the field. |
|
|
19
|
+
| `adaptiveTitle` | `string` | `""` | Title of the bottom sheet the popup opens as with `adaptiveMode="auto"`. When empty, the sheet shows the field's name. |
|
|
18
20
|
| `aria-describedby` | `string` | `""` | Id of an element that describes the input, such as a hint or an error message. |
|
|
19
21
|
| `aria-label` | `string` | `""` | Accessible name of the input. Prefer a visible label, linked through `inputId` or `aria-labelledby`; the placeholder is not a label. |
|
|
20
22
|
| `aria-labelledby` | `string` | `""` | Id of the element that labels the input. |
|
|
@@ -18,6 +18,8 @@ that shows two months at a time.
|
|
|
18
18
|
|
|
19
19
|
| Name | Type | Default | Description |
|
|
20
20
|
| --- | --- | --- | --- |
|
|
21
|
+
| `adaptiveMode` | `AdaptiveMode` | `"none"` | Opens the popup as a sheet along the bottom of the screen on a small screen (narrower than 640 pixels) with `"auto"`, so it's easy to reach with a thumb. With `"none"`, it always opens under the field. |
|
|
22
|
+
| `adaptiveTitle` | `string` | `""` | Title of the bottom sheet the popup opens as with `adaptiveMode="auto"`. When empty, the sheet shows the field's name. |
|
|
21
23
|
| `aria-describedby` | `string` | `""` | Id of an element that describes the range, such as a hint or an error message. It describes both inputs. |
|
|
22
24
|
| `aria-label` | `string` | `""` | Accessible name of the range, on the group that holds its two inputs. Prefer a visible label from a `mona-label` or a `mona-form-field`. Each input is named for its end, as in "Start date". |
|
|
23
25
|
| `aria-labelledby` | `string` | `""` | Id of the element that labels the range, on the group that holds its two inputs. |
|
|
@@ -15,6 +15,8 @@ Component.
|
|
|
15
15
|
|
|
16
16
|
| Name | Type | Default | Description |
|
|
17
17
|
| --- | --- | --- | --- |
|
|
18
|
+
| `adaptiveMode` | `AdaptiveMode` | `"none"` | Opens the popup as a sheet along the bottom of the screen on a small screen (narrower than 640 pixels) with `"auto"`, so it's easy to reach with a thumb. With `"none"`, it always opens under the field. |
|
|
19
|
+
| `adaptiveTitle` | `string` | `""` | Title of the bottom sheet the popup opens as with `adaptiveMode="auto"`. When empty, the sheet shows the field's name. |
|
|
18
20
|
| `aria-describedby` | `string` | `""` | Id of an element that describes the input, such as a hint or an error message. |
|
|
19
21
|
| `aria-label` | `string` | `""` | Accessible name of the input. Prefer a visible label, linked through `inputId` or `aria-labelledby`; the placeholder is not a label. |
|
|
20
22
|
| `aria-labelledby` | `string` | `""` | Id of the element that labels the input. |
|
|
@@ -16,6 +16,8 @@ Component.
|
|
|
16
16
|
|
|
17
17
|
| Name | Type | Default | Description |
|
|
18
18
|
| --- | --- | --- | --- |
|
|
19
|
+
| `adaptiveMode` | `AdaptiveMode` | `"none"` | Opens the popup as a sheet along the bottom of the screen on a small screen (narrower than 640 pixels) with `"auto"`, so it's easy to reach with a thumb. With `"none"`, it always opens under the field. |
|
|
20
|
+
| `adaptiveTitle` | `string` | `""` | Title of the bottom sheet the popup opens as with `adaptiveMode="auto"`. When empty, the sheet shows the field's name. |
|
|
19
21
|
| `aria-describedby` | `string` | `""` | ID of an element that describes the dropdown list, such as help text or an error message. |
|
|
20
22
|
| `aria-label` | `string` | `""` | Accessible name for the host element. Describe what the component represents. When empty, falls back to the placeholder text. |
|
|
21
23
|
| `aria-labelledby` | `string` | `""` | ID of an external element that provides the accessible name for the host element. |
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
# `@nanahoshi/mona-ui/dropdown-tree`
|
|
2
|
+
|
|
3
|
+
Everything `@nanahoshi/mona-ui/dropdown-tree` exports.
|
|
4
|
+
|
|
5
|
+
**Guides:** [Dropdown Tree](../dropdown-tree.md)
|
|
6
|
+
|
|
7
|
+
## `DropdownTreeComponent`
|
|
8
|
+
|
|
9
|
+
Component.
|
|
10
|
+
|
|
11
|
+
**Selector:** `mona-dropdown-tree`
|
|
12
|
+
**Type parameters:** `TData = unknown`, `TValue = TData`
|
|
13
|
+
**Implements:** `FormValueControl<TValue \| null>`
|
|
14
|
+
|
|
15
|
+
### Inputs
|
|
16
|
+
|
|
17
|
+
| Name | Type | Default | Description |
|
|
18
|
+
| --- | --- | --- | --- |
|
|
19
|
+
| `adaptiveMode` | `AdaptiveMode` | `"none"` | Opens the popup as a sheet along the bottom of the screen on a small screen (narrower than 640 pixels) with `"auto"`, so it's easy to reach with a thumb. With `"none"`, it always opens under the field. |
|
|
20
|
+
| `adaptiveTitle` | `string` | `""` | Title of the bottom sheet the popup opens as with `adaptiveMode="auto"`. When empty, the sheet shows the field's name. |
|
|
21
|
+
| `aria-describedby` | `string` | `""` | ID of an element that describes the dropdown tree, such as help text or an error message. |
|
|
22
|
+
| `aria-label` | `string` | `""` | Accessible name of the dropdown tree. Describe what it represents. When empty, falls back to the placeholder text. |
|
|
23
|
+
| `aria-labelledby` | `string` | `""` | ID of an external element that provides the accessible name of the dropdown tree. |
|
|
24
|
+
| `children` | `ChildrenSelector<TData>` | `""` | Property name or accessor that gives a node's children, for `mode="hierarchical"`. An accessor may return an observable, which loads the children when the node is first opened; set `hasChildren` with it. |
|
|
25
|
+
| `class` | `string` | `""` | Additional CSS classes merged onto the host element via `tailwind-merge`. |
|
|
26
|
+
| `data` | `Iterable<TData>` | `[]` | The items of the tree: its root items for `mode="hierarchical"`, or every item for `mode="flat"`. |
|
|
27
|
+
| `disabled` | `boolean` | `false` | Renders the component with reduced visual emphasis and removes pointer interaction. |
|
|
28
|
+
| `hasChildren` | `Predicate<TData> \| null` | `null` | Whether an item has children, before they load. Needed when `children` returns an observable. |
|
|
29
|
+
| `idField` | `string` | `""` | Property name that holds an item's unique id, for `mode="flat"`. |
|
|
30
|
+
| `invalid` | `boolean` | `false` | Marks the field as invalid. Set automatically by the `FormField` directive when bound via `[formField]`. |
|
|
31
|
+
| `itemDisabled` | `DropdownFieldPredicateType<TData>` | `undefined` | Predicate or field name that tells whether an item is disabled. A disabled item can't be selected or opened, and neither can its children. |
|
|
32
|
+
| `loading` | `boolean` | `false` | Shows a loading indicator, in place of the clear button, and marks the field busy. It doesn't block interaction: the field stays usable while data loads. |
|
|
33
|
+
| `mode` | `DataStructure` | `"hierarchical"` | Shape of `data`: `"hierarchical"` for items that hold their children (see `children`), or `"flat"` for one list linked by `idField` and `parentIdField`. |
|
|
34
|
+
| `parentIdField` | `string` | `""` | Property name that holds an item's parent id, for `mode="flat"`. Items without one are roots. |
|
|
35
|
+
| `placeholder` | `string` | `""` | Placeholder text shown when no value is selected. It also names the dropdown tree when neither `aria-label` nor `aria-labelledby` is set. |
|
|
36
|
+
| `popupClass` | `string` | `""` | Additional CSS classes applied to the popup element. |
|
|
37
|
+
| `popupHeight` | `ListSizeInputType` | `null` | Maximum height of the popup, in pixels or as a CSS length. Shorter trees shrink to fit. When unset, the popup is at most 200 pixels tall. |
|
|
38
|
+
| `popupWidth` | `ListSizeInputType` | `null` | Width of the popup element. When unset, the popup is as wide as the field. |
|
|
39
|
+
| `readonly` | `boolean` | `false` | Prevents value changes while preserving the component's visual state. |
|
|
40
|
+
| `required` | `boolean` | `false` | Marks the field as required for form validation. |
|
|
41
|
+
| `rounded` | `"full" \| "large" \| "medium" \| "none" \| "small"` | `"medium"` | Border-radius preset applied to the component. |
|
|
42
|
+
| `showClearButton` | `boolean` | `false` | Shows a clear button that resets the selected value when clicked. |
|
|
43
|
+
| `size` | `"large" \| "medium" \| "small"` | `"medium"` | Size preset controlling the component's dimensions. |
|
|
44
|
+
| `textField` | `DropdownFieldSelectorType<TData, string>` | `undefined` | Property name or accessor that gives an item's text. When unset, the item itself is the text. |
|
|
45
|
+
| `touched` | `boolean` | `false` | Marks the control as touched. Set automatically by the `FormField` directive when bound via `[formField]`. |
|
|
46
|
+
| `value` (two-way) | `TValue \| null` | `null` | The selected item, two-way bindable and compatible with Signal Forms via `[formField]`. It's the data item, or with `valuePrimitive`, the value `valueField` gives for it. `null` means nothing is selected. |
|
|
47
|
+
| `valueField` | `DropdownFieldSelectorType<TData, unknown>` | `undefined` | Property name or accessor that gives an item's value: what identifies the item, matches a value set from code to its node, and is the value with `valuePrimitive`. When unset, the item itself is the value. It should be a stable, unique scalar. |
|
|
48
|
+
| `valuePrimitive` | `boolean` | `false` | Whether the value is what `valueField` gives for the selected item (`true`), or the item itself (`false`). |
|
|
49
|
+
|
|
50
|
+
### Outputs
|
|
51
|
+
|
|
52
|
+
| Name | Type | Description |
|
|
53
|
+
| --- | --- | --- |
|
|
54
|
+
| `close` | `PopupCloseEvent<unknown>` | Emitted when the popup is about to close. This event is preventable. |
|
|
55
|
+
| `closed` | `void` | Emitted after the popup closes. |
|
|
56
|
+
| `open` | `PreventableEvent<Event>` | Emitted when the popup is about to open. This event is preventable. |
|
|
57
|
+
| `opened` | `void` | Emitted after the popup opens. |
|
|
58
|
+
| `touch` | `void` | Emitted when focus leaves the dropdown tree. Moving between it, its clear button and its popup doesn't count. The `FormField` directive listens to this to mark the field as touched. |
|
|
59
|
+
| `valueChange` | `TValue \| null` | Emitted when `value` changes. |
|
|
60
|
+
|
|
61
|
+
### Methods
|
|
62
|
+
|
|
63
|
+
| Signature | Description |
|
|
64
|
+
| --- | --- |
|
|
65
|
+
| `focus(options?: FocusOptions): void` | Moves focus to the dropdown tree. |
|
|
66
|
+
|
|
67
|
+
## `DropdownTreeValueTemplateDirective`
|
|
68
|
+
|
|
69
|
+
Directive.
|
|
70
|
+
|
|
71
|
+
Renders the selected item in the field. Its context's `$implicit` is the item, or `null` with nothing selected.
|
|
72
|
+
|
|
73
|
+
**Selector:** `ng-template[monaDropDownTreeValueTemplate]`
|
|
74
|
+
|
|
75
|
+
## `DROPDOWN_TREE_DEFAULT_MESSAGES`
|
|
76
|
+
|
|
77
|
+
Constant.
|
|
78
|
+
|
|
79
|
+
```typescript
|
|
80
|
+
const DROPDOWN_TREE_DEFAULT_MESSAGES: MonaDropdownTreeMessages;
|
|
81
|
+
```
|
package/docs/api/dropdowns.md
CHANGED
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
Everything `@nanahoshi/mona-ui/dropdowns` exports.
|
|
4
4
|
|
|
5
|
-
**Guides:** [Auto Complete](../auto-complete.md), [Combo Box](../combo-box.md), [Dropdown List](../dropdown-list.md), [Multi Select](../multi-select.md)
|
|
5
|
+
**Guides:** [Auto Complete](../auto-complete.md), [Combo Box](../combo-box.md), [Dropdown List](../dropdown-list.md), [Dropdown Tree](../dropdown-tree.md), [Multi Select](../multi-select.md), [Multi Select Tree](../multi-select-tree.md)
|
|
6
6
|
|
|
7
7
|
## `DropdownFilterableDirective`
|
|
8
8
|
|
|
9
9
|
Directive.
|
|
10
10
|
|
|
11
|
-
**Selector:** `mona-auto-complete[monaDropDownFilterable], mona-dropdown-list[monaDropDownFilterable], mona-combo-box[monaDropDownFilterable], mona-multi-select[monaDropDownFilterable]`
|
|
11
|
+
**Selector:** `mona-auto-complete[monaDropDownFilterable], mona-dropdown-list[monaDropDownFilterable], mona-combo-box[monaDropDownFilterable], mona-dropdown-tree[monaDropDownFilterable], mona-multi-select[monaDropDownFilterable], mona-multi-select-tree[monaDropDownFilterable]`
|
|
12
12
|
|
|
13
13
|
### Inputs
|
|
14
14
|
|
|
@@ -60,7 +60,7 @@ Directive.
|
|
|
60
60
|
|
|
61
61
|
Directive.
|
|
62
62
|
|
|
63
|
-
**Selector:** `ng-template[monaDropDownFooterTemplate], ng-template[monaAutoCompleteFooterTemplate], ng-template[monaDropDownListFooterTemplate], ng-template[monaDropDownTreeFooterTemplate], ng-template[monaComboBoxFooterTemplate], ng-template[monaMultiSelectFooterTemplate]`
|
|
63
|
+
**Selector:** `ng-template[monaDropDownFooterTemplate], ng-template[monaAutoCompleteFooterTemplate], ng-template[monaDropDownListFooterTemplate], ng-template[monaDropDownTreeFooterTemplate], ng-template[monaComboBoxFooterTemplate], ng-template[monaMultiSelectFooterTemplate], ng-template[monaMultiSelectTreeFooterTemplate]`
|
|
64
64
|
|
|
65
65
|
## `DropdownGroupHeaderTemplateDirective`
|
|
66
66
|
|
|
@@ -72,13 +72,13 @@ Directive.
|
|
|
72
72
|
|
|
73
73
|
Directive.
|
|
74
74
|
|
|
75
|
-
**Selector:** `ng-template[monaDropDownHeaderTemplate], ng-template[monaAutoCompleteHeaderTemplate], ng-template[monaDropDownListHeaderTemplate], ng-template[monaDropDownTreeHeaderTemplate], ng-template[monaComboBoxHeaderTemplate], ng-template[monaMultiSelectHeaderTemplate]`
|
|
75
|
+
**Selector:** `ng-template[monaDropDownHeaderTemplate], ng-template[monaAutoCompleteHeaderTemplate], ng-template[monaDropDownListHeaderTemplate], ng-template[monaDropDownTreeHeaderTemplate], ng-template[monaComboBoxHeaderTemplate], ng-template[monaMultiSelectHeaderTemplate], ng-template[monaMultiSelectTreeHeaderTemplate]`
|
|
76
76
|
|
|
77
77
|
## `DropdownItemTemplateDirective`
|
|
78
78
|
|
|
79
79
|
Directive.
|
|
80
80
|
|
|
81
|
-
**Selector:** `ng-template[monaDropDownItemTemplate], ng-template[monaAutoCompleteItemTemplate], ng-template[monaDropDownListItemTemplate], ng-template[monaComboBoxItemTemplate], ng-template[monaMultiSelectItemTemplate]`
|
|
81
|
+
**Selector:** `ng-template[monaDropDownItemTemplate], ng-template[monaAutoCompleteItemTemplate], ng-template[monaDropDownListItemTemplate], ng-template[monaDropDownTreeItemTemplate], ng-template[monaComboBoxItemTemplate], ng-template[monaMultiSelectItemTemplate], ng-template[monaMultiSelectTreeItemTemplate]`
|
|
82
82
|
|
|
83
83
|
## `DropdownListPopupHandlerDirective`
|
|
84
84
|
|
|
@@ -90,7 +90,7 @@ Directive.
|
|
|
90
90
|
|
|
91
91
|
Directive.
|
|
92
92
|
|
|
93
|
-
**Selector:** `ng-template[monaDropDownNoDataTemplate], ng-template[monaAutoCompleteNoDataTemplate], ng-template[monaDropDownListNoDataTemplate], ng-template[monaDropDownTreeNoDataTemplate], ng-template[monaComboBoxNoDataTemplate], ng-template[monaMultiSelectNoDataTemplate]`
|
|
93
|
+
**Selector:** `ng-template[monaDropDownNoDataTemplate], ng-template[monaAutoCompleteNoDataTemplate], ng-template[monaDropDownListNoDataTemplate], ng-template[monaDropDownTreeNoDataTemplate], ng-template[monaComboBoxNoDataTemplate], ng-template[monaMultiSelectNoDataTemplate], ng-template[monaMultiSelectTreeNoDataTemplate]`
|
|
94
94
|
|
|
95
95
|
## `DropdownPrefixTemplateDirective`
|
|
96
96
|
|
|
@@ -151,6 +151,32 @@ Interface.
|
|
|
151
151
|
|
|
152
152
|
**Used by:** [`DropdownDataInputToken`](dropdowns.md#dropdowndatainputtoken)
|
|
153
153
|
|
|
154
|
+
## `DropdownSheetData`
|
|
155
|
+
|
|
156
|
+
Interface.
|
|
157
|
+
|
|
158
|
+
What a dropdown passes to the bottom sheet its popup opens as.
|
|
159
|
+
|
|
160
|
+
### Properties
|
|
161
|
+
|
|
162
|
+
| Name | Type | Description |
|
|
163
|
+
| --- | --- | --- |
|
|
164
|
+
| `content` (read-only) | `TemplateRef<unknown>` | The dropdown's popup template, shown below the sheet's header. |
|
|
165
|
+
| `title` (read-only) | `Signal<string>` | The sheet's title: the dropdown's `adaptiveTitle`, or else its name. |
|
|
166
|
+
|
|
167
|
+
## `AdaptiveMode`
|
|
168
|
+
|
|
169
|
+
Type alias.
|
|
170
|
+
|
|
171
|
+
How a dropdown's popup adapts to a small screen: `"auto"` opens it as a sheet along the bottom of the screen when
|
|
172
|
+
the screen is narrower than 640 pixels, and `"none"` always opens it under the field.
|
|
173
|
+
|
|
174
|
+
```typescript
|
|
175
|
+
type AdaptiveMode = "auto" | "none";
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
**Used by:** [`DatePickerComponent`](date-picker.md#datepickercomponent), [`DateRangePickerComponent`](date-range-picker.md#daterangepickercomponent), [`DateTimePickerComponent`](datetime-picker.md#datetimepickercomponent), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`DropdownTreeComponent`](dropdown-tree.md#dropdowntreecomponent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent), [`MultiSelectTreeComponent`](multi-select-tree.md#multiselecttreecomponent), [`TimePickerComponent`](time-picker.md#timepickercomponent)
|
|
179
|
+
|
|
154
180
|
## `DropdownFieldPredicateType`
|
|
155
181
|
|
|
156
182
|
Type alias.
|
|
@@ -159,7 +185,7 @@ Type alias.
|
|
|
159
185
|
type DropdownFieldPredicateType<TData> = string | Predicate<TData> | null | undefined;
|
|
160
186
|
```
|
|
161
187
|
|
|
162
|
-
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DropdownDataInput`](dropdowns.md#dropdowndatainput), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent)
|
|
188
|
+
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DropdownDataInput`](dropdowns.md#dropdowndatainput), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`DropdownTreeComponent`](dropdown-tree.md#dropdowntreecomponent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent), [`MultiSelectTreeComponent`](multi-select-tree.md#multiselecttreecomponent)
|
|
163
189
|
|
|
164
190
|
## `DropdownFieldSelectorType`
|
|
165
191
|
|
|
@@ -169,4 +195,4 @@ Type alias.
|
|
|
169
195
|
type DropdownFieldSelectorType<TData, TResult = unknown> = string | Selector<TData, TResult> | null | undefined;
|
|
170
196
|
```
|
|
171
197
|
|
|
172
|
-
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DropdownDataInput`](dropdowns.md#dropdowndatainput), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent)
|
|
198
|
+
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DropdownDataInput`](dropdowns.md#dropdowndatainput), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`DropdownTreeComponent`](dropdown-tree.md#dropdowntreecomponent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent), [`MultiSelectTreeComponent`](multi-select-tree.md#multiselecttreecomponent)
|
package/docs/api/i18n.md
CHANGED
|
@@ -1114,13 +1114,26 @@ Interface.
|
|
|
1114
1114
|
|
|
1115
1115
|
### Properties
|
|
1116
1116
|
|
|
1117
|
+
| Name | Type | Description |
|
|
1118
|
+
| --- | --- | --- |
|
|
1119
|
+
| `close` (read-only) | `string` | The button that closes a dropdown's popup when it opens as a bottom sheet on a small screen. |
|
|
1120
|
+
| `itemPosition` (read-only) | `(text: string, position: number, total: number) => string` | |
|
|
1121
|
+
| `noResultsFound` (read-only) | `string` | |
|
|
1122
|
+
| `resultsAvailable` (read-only) | `(count: number) => string` | |
|
|
1123
|
+
|
|
1124
|
+
**Used by:** [`DROPDOWNS_DEFAULT_MESSAGES`](dropdowns.md#dropdowns-default-messages), [`MonaLocaleMessages`](i18n.md#monalocalemessages)
|
|
1125
|
+
|
|
1126
|
+
## `MonaDropdownTreeMessages`
|
|
1127
|
+
|
|
1128
|
+
Interface.
|
|
1129
|
+
|
|
1130
|
+
### Properties
|
|
1131
|
+
|
|
1117
1132
|
| Name | Type |
|
|
1118
1133
|
| --- | --- |
|
|
1119
|
-
| `
|
|
1120
|
-
| `noResultsFound` (read-only) | `string` |
|
|
1121
|
-
| `resultsAvailable` (read-only) | `(count: number) => string` |
|
|
1134
|
+
| `clear` (read-only) | `string` |
|
|
1122
1135
|
|
|
1123
|
-
**Used by:** [`
|
|
1136
|
+
**Used by:** [`DROPDOWN_TREE_DEFAULT_MESSAGES`](dropdown-tree.md#dropdown-tree-default-messages), [`MonaLocaleMessages`](i18n.md#monalocalemessages)
|
|
1124
1137
|
|
|
1125
1138
|
## `MonaEditorMessages`
|
|
1126
1139
|
|
|
@@ -1326,6 +1339,7 @@ Interface.
|
|
|
1326
1339
|
| `dialog` | `MonaDialogMessages` |
|
|
1327
1340
|
| `dropdownList` | `MonaDropdownListMessages` |
|
|
1328
1341
|
| `dropdowns` | `MonaDropdownsMessages` |
|
|
1342
|
+
| `dropdownTree` | `MonaDropdownTreeMessages` |
|
|
1329
1343
|
| `editor` | `MonaEditorMessages` |
|
|
1330
1344
|
| `fileUpload` | `MonaFileUploadMessages` |
|
|
1331
1345
|
| `filter` | `MonaFilterMessages` |
|
|
@@ -1336,6 +1350,7 @@ Interface.
|
|
|
1336
1350
|
| `listBox` | `MonaListBoxMessages` |
|
|
1337
1351
|
| `maskedTextBox` | `MonaMaskedTextBoxMessages` |
|
|
1338
1352
|
| `multiSelect` | `MonaMultiSelectMessages` |
|
|
1353
|
+
| `multiSelectTree` | `MonaMultiSelectTreeMessages` |
|
|
1339
1354
|
| `notification` | `MonaNotificationMessages` |
|
|
1340
1355
|
| `numericTextBox` | `MonaNumericTextBoxMessages` |
|
|
1341
1356
|
| `otpInput` | `MonaOtpInputMessages` |
|
|
@@ -1407,6 +1422,20 @@ Interface.
|
|
|
1407
1422
|
|
|
1408
1423
|
**Used by:** [`MonaLocaleMessages`](i18n.md#monalocalemessages), [`MULTI_SELECT_DEFAULT_MESSAGES`](multi-select.md#multi-select-default-messages)
|
|
1409
1424
|
|
|
1425
|
+
## `MonaMultiSelectTreeMessages`
|
|
1426
|
+
|
|
1427
|
+
Interface.
|
|
1428
|
+
|
|
1429
|
+
### Properties
|
|
1430
|
+
|
|
1431
|
+
| Name | Type |
|
|
1432
|
+
| --- | --- |
|
|
1433
|
+
| `clear` (read-only) | `string` |
|
|
1434
|
+
| `itemsCount` (read-only) | `(count: number) => string` |
|
|
1435
|
+
| `removeMoreItems` (read-only) | `(count: number) => string` |
|
|
1436
|
+
|
|
1437
|
+
**Used by:** [`MonaLocaleMessages`](i18n.md#monalocalemessages), [`MULTI_SELECT_TREE_DEFAULT_MESSAGES`](multi-select-tree.md#multi-select-tree-default-messages)
|
|
1438
|
+
|
|
1410
1439
|
## `MonaNotificationMessages`
|
|
1411
1440
|
|
|
1412
1441
|
Interface.
|
package/docs/api/list.md
CHANGED
|
@@ -70,7 +70,7 @@ Type alias.
|
|
|
70
70
|
type ListSizeInputType = ListSizeType | number;
|
|
71
71
|
```
|
|
72
72
|
|
|
73
|
-
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DatePickerComponent`](date-picker.md#datepickercomponent), [`DateRangePickerComponent`](date-range-picker.md#daterangepickercomponent), [`DateTimePickerComponent`](datetime-picker.md#datetimepickercomponent), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent), [`TimePickerComponent`](time-picker.md#timepickercomponent)
|
|
73
|
+
**Used by:** [`AutoCompleteComponent`](auto-complete.md#autocompletecomponent), [`ComboBoxComponent`](combo-box.md#comboboxcomponent), [`DatePickerComponent`](date-picker.md#datepickercomponent), [`DateRangePickerComponent`](date-range-picker.md#daterangepickercomponent), [`DateTimePickerComponent`](datetime-picker.md#datetimepickercomponent), [`DropdownListComponent`](dropdown-list.md#dropdownlistcomponent), [`DropdownTreeComponent`](dropdown-tree.md#dropdowntreecomponent), [`MultiSelectComponent`](multi-select.md#multiselectcomponent), [`MultiSelectTreeComponent`](multi-select-tree.md#multiselecttreecomponent), [`TimePickerComponent`](time-picker.md#timepickercomponent)
|
|
74
74
|
|
|
75
75
|
## `ListSizeType`
|
|
76
76
|
|