@nanahoshi/mona-ui 0.18.6 → 0.20.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/README.md +71 -13
- package/THIRD_PARTY_NOTICES.md +60 -0
- package/fesm2022/nanahoshi-mona-ui-auto-complete.mjs +11 -3
- package/fesm2022/nanahoshi-mona-ui-breadcrumb.mjs +17 -9
- package/fesm2022/nanahoshi-mona-ui-button-group.mjs +16 -7
- package/fesm2022/nanahoshi-mona-ui-calendar.mjs +196 -101
- package/fesm2022/nanahoshi-mona-ui-card.mjs +22 -14
- package/fesm2022/nanahoshi-mona-ui-chart.mjs +78 -18
- package/fesm2022/nanahoshi-mona-ui-check-box.mjs +1 -1
- package/fesm2022/nanahoshi-mona-ui-chip.mjs +11 -3
- package/fesm2022/nanahoshi-mona-ui-circular-progress-bar.mjs +1 -2
- package/fesm2022/nanahoshi-mona-ui-color-gradient.mjs +23 -5
- package/fesm2022/nanahoshi-mona-ui-color-palette.mjs +49 -28
- package/fesm2022/nanahoshi-mona-ui-color-picker.mjs +42 -26
- package/fesm2022/nanahoshi-mona-ui-combo-box.mjs +11 -3
- package/fesm2022/nanahoshi-mona-ui-date-picker.mjs +39 -21
- package/fesm2022/nanahoshi-mona-ui-datetime-picker.mjs +88 -55
- package/fesm2022/nanahoshi-mona-ui-dialog.mjs +57 -25
- package/fesm2022/nanahoshi-mona-ui-dropdown-list.mjs +13 -5
- package/fesm2022/nanahoshi-mona-ui-dropdowns.mjs +17 -6
- package/fesm2022/nanahoshi-mona-ui-editor.mjs +178 -59
- package/fesm2022/nanahoshi-mona-ui-filter.mjs +137 -54
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-cell.component-WEDbZ5vy.mjs → nanahoshi-mona-ui-grid-grid-footer-cell.component-BuybF7tX.mjs} +2 -2
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-ibH5osCg.mjs → nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-Dj-SaNzk.mjs} +2 -2
- package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-CYAm4l84.mjs +145 -0
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-toggle.component-hc-LeIb0.mjs → nanahoshi-mona-ui-grid-grid-toggle.component-B_Gm--X6.mjs} +46 -31
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-virtual-list.component-DYajpOb9.mjs → nanahoshi-mona-ui-grid-grid-virtual-list.component-X0X487Rm.mjs} +5 -5
- package/fesm2022/{nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-Pm8Fbp6M.mjs → nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-CyzJFQIy.mjs} +99 -42
- package/fesm2022/nanahoshi-mona-ui-grid.mjs +1 -1
- package/fesm2022/nanahoshi-mona-ui-i18n.mjs +4874 -0
- package/fesm2022/nanahoshi-mona-ui-internal-list.mjs +12 -4
- package/fesm2022/nanahoshi-mona-ui-internal-tree.mjs +48 -21
- package/fesm2022/nanahoshi-mona-ui-list-box.mjs +33 -18
- package/fesm2022/nanahoshi-mona-ui-list-view.mjs +10 -10
- package/fesm2022/nanahoshi-mona-ui-list.mjs +2 -0
- package/fesm2022/nanahoshi-mona-ui-locales.mjs +4973 -0
- package/fesm2022/nanahoshi-mona-ui-menubar.mjs +29 -16
- package/fesm2022/nanahoshi-mona-ui-multi-select.mjs +12 -3
- package/fesm2022/nanahoshi-mona-ui-notification.mjs +23 -18
- package/fesm2022/nanahoshi-mona-ui-numeric-text-box.mjs +211 -106
- package/fesm2022/nanahoshi-mona-ui-otp-input.mjs +14 -6
- package/fesm2022/nanahoshi-mona-ui-pager.mjs +66 -29
- package/fesm2022/nanahoshi-mona-ui-popup-menu.mjs +57 -46
- package/fesm2022/nanahoshi-mona-ui-popup.mjs +35 -15
- package/fesm2022/nanahoshi-mona-ui-progress-bar.mjs +38 -17
- package/fesm2022/nanahoshi-mona-ui-rating.mjs +25 -7
- package/fesm2022/nanahoshi-mona-ui-scroll-view.mjs +431 -101
- package/fesm2022/nanahoshi-mona-ui-segmented.mjs +1 -1
- package/fesm2022/nanahoshi-mona-ui-sheet.mjs +26 -8
- package/fesm2022/nanahoshi-mona-ui-sidebar.mjs +222 -28
- package/fesm2022/nanahoshi-mona-ui-slider.mjs +91 -36
- package/fesm2022/nanahoshi-mona-ui-spinner.mjs +34 -15
- package/fesm2022/nanahoshi-mona-ui-split-button.mjs +39 -23
- package/fesm2022/nanahoshi-mona-ui-splitter.mjs +50 -25
- package/fesm2022/nanahoshi-mona-ui-stepper.mjs +41 -14
- package/fesm2022/nanahoshi-mona-ui-switch.mjs +9 -9
- package/fesm2022/nanahoshi-mona-ui-tabs.mjs +74 -56
- package/fesm2022/nanahoshi-mona-ui-text-box.mjs +16 -8
- package/fesm2022/nanahoshi-mona-ui-time-picker.mjs +47 -24
- package/fesm2022/nanahoshi-mona-ui-time-selector.mjs +66 -27
- package/fesm2022/nanahoshi-mona-ui-tree-view.mjs +23 -15
- package/fesm2022/nanahoshi-mona-ui-window.mjs +71 -40
- package/i18n/package.json +4 -0
- package/locales/package.json +4 -0
- package/package.json +9 -1
- package/types/nanahoshi-mona-ui-auto-complete.d.ts +6 -1
- package/types/nanahoshi-mona-ui-breadcrumb.d.ts +9 -3
- package/types/nanahoshi-mona-ui-button-group.d.ts +9 -3
- package/types/nanahoshi-mona-ui-calendar.d.ts +29 -15
- package/types/nanahoshi-mona-ui-card.d.ts +8 -2
- package/types/nanahoshi-mona-ui-chart.d.ts +10 -1
- package/types/nanahoshi-mona-ui-chip.d.ts +7 -1
- package/types/nanahoshi-mona-ui-color-gradient.d.ts +6 -1
- package/types/nanahoshi-mona-ui-color-palette.d.ts +21 -10
- package/types/nanahoshi-mona-ui-color-picker.d.ts +30 -20
- package/types/nanahoshi-mona-ui-combo-box.d.ts +6 -1
- package/types/nanahoshi-mona-ui-date-picker.d.ts +14 -6
- package/types/nanahoshi-mona-ui-datetime-picker.d.ts +40 -12
- package/types/nanahoshi-mona-ui-dialog.d.ts +16 -7
- package/types/nanahoshi-mona-ui-dropdown-list.d.ts +6 -1
- package/types/nanahoshi-mona-ui-dropdowns.d.ts +4 -1
- package/types/nanahoshi-mona-ui-editor.d.ts +6 -1
- package/types/nanahoshi-mona-ui-filter.d.ts +16 -10
- package/types/nanahoshi-mona-ui-grid.d.ts +50 -2
- package/types/nanahoshi-mona-ui-i18n.d.ts +680 -0
- package/types/nanahoshi-mona-ui-internal-list.d.ts +7 -2
- package/types/nanahoshi-mona-ui-internal-tree.d.ts +7 -3
- package/types/nanahoshi-mona-ui-list-box.d.ts +9 -4
- package/types/nanahoshi-mona-ui-list-view.d.ts +6 -6
- package/types/nanahoshi-mona-ui-list.d.ts +1 -1
- package/types/nanahoshi-mona-ui-locales.d.ts +4889 -0
- package/types/nanahoshi-mona-ui-menubar.d.ts +59 -58
- package/types/nanahoshi-mona-ui-multi-select.d.ts +6 -1
- package/types/nanahoshi-mona-ui-notification.d.ts +11 -5
- package/types/nanahoshi-mona-ui-numeric-text-box.d.ts +24 -15
- package/types/nanahoshi-mona-ui-otp-input.d.ts +9 -3
- package/types/nanahoshi-mona-ui-pager.d.ts +20 -6
- package/types/nanahoshi-mona-ui-popup.d.ts +2 -1
- package/types/nanahoshi-mona-ui-progress-bar.d.ts +9 -7
- package/types/nanahoshi-mona-ui-rating.d.ts +19 -12
- package/types/nanahoshi-mona-ui-scroll-view.d.ts +34 -28
- package/types/nanahoshi-mona-ui-sheet.d.ts +8 -2
- package/types/nanahoshi-mona-ui-sidebar.d.ts +3 -0
- package/types/nanahoshi-mona-ui-slider.d.ts +44 -26
- package/types/nanahoshi-mona-ui-spinner.d.ts +13 -4
- package/types/nanahoshi-mona-ui-split-button.d.ts +62 -56
- package/types/nanahoshi-mona-ui-splitter.d.ts +9 -6
- package/types/nanahoshi-mona-ui-stepper.d.ts +10 -3
- package/types/nanahoshi-mona-ui-switch.d.ts +1 -1
- package/types/nanahoshi-mona-ui-tabs.d.ts +96 -35
- package/types/nanahoshi-mona-ui-text-box.d.ts +11 -5
- package/types/nanahoshi-mona-ui-time-picker.d.ts +11 -4
- package/types/nanahoshi-mona-ui-time-selector.d.ts +16 -5
- package/types/nanahoshi-mona-ui-tree-view.d.ts +15 -10
- package/types/nanahoshi-mona-ui-window.d.ts +26 -20
- package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-ZM3CneJ0.mjs +0 -145
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { NgTemplateOutlet } from '@angular/common';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { Directive, inject, DestroyRef, contentChild, TemplateRef,
|
|
3
|
+
import { Directive, inject, DestroyRef, computed, contentChild, TemplateRef, input, output, effect, untracked, afterNextRender, Component } from '@angular/core';
|
|
4
4
|
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
5
5
|
import { FilterInputComponent } from '@nanahoshi/mona-ui/internal/filter-input';
|
|
6
|
-
import { TreeService, TreeComponent, TreeNodeTemplateDirective, NodeDropEvent } from '@nanahoshi/mona-ui/internal/tree';
|
|
6
|
+
import { TREE_DEFAULT_MESSAGES, TreeService, TreeComponent, TreeNodeTemplateDirective, NodeDropEvent } from '@nanahoshi/mona-ui/internal/tree';
|
|
7
7
|
export { NodeCheckEvent, NodeClickEvent, NodeDragEndEvent, NodeDragEvent, NodeDragStartEvent, NodeDropEvent, moveFlatTreeNode, moveTreeNode } from '@nanahoshi/mona-ui/internal/tree';
|
|
8
|
+
import { MonaI18nService } from '@nanahoshi/mona-ui/i18n';
|
|
8
9
|
import { sequenceEqual } from '@mirei/ts-collections';
|
|
9
10
|
import { pairwise } from 'rxjs';
|
|
10
11
|
|
|
@@ -19,17 +20,22 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
19
20
|
}]
|
|
20
21
|
}] });
|
|
21
22
|
|
|
23
|
+
const TREE_VIEW_DEFAULT_MESSAGES = TREE_DEFAULT_MESSAGES;
|
|
24
|
+
|
|
22
25
|
class TreeViewComponent {
|
|
23
26
|
#destroyRef;
|
|
27
|
+
#i18n;
|
|
24
28
|
constructor() {
|
|
25
29
|
this.#destroyRef = inject(DestroyRef);
|
|
26
|
-
this
|
|
27
|
-
this.treeService = inject((TreeService));
|
|
30
|
+
this.#i18n = inject(MonaI18nService);
|
|
28
31
|
this.filterAriaLabel = computed(() => {
|
|
29
32
|
const ariaLabel = this.ariaLabel();
|
|
30
|
-
return ariaLabel ?
|
|
33
|
+
return ariaLabel ? `${this.messages().filter} ${ariaLabel}` : this.messages().filterTree;
|
|
31
34
|
}, /* @ts-ignore */
|
|
32
35
|
...(ngDevMode ? [{ debugName: "filterAriaLabel" }] : /* istanbul ignore next */ []));
|
|
36
|
+
this.messages = this.#i18n.componentMessages("treeView", TREE_VIEW_DEFAULT_MESSAGES);
|
|
37
|
+
this.nodeTemplate = contentChild(TreeViewNodeTemplateDirective, { ...(ngDevMode ? { debugName: "nodeTemplate" } : /* istanbul ignore next */ {}), read: TemplateRef });
|
|
38
|
+
this.treeService = inject((TreeService));
|
|
33
39
|
/**
|
|
34
40
|
* @description Enables CSS transitions when nodes expand or collapse.
|
|
35
41
|
* @default true
|
|
@@ -42,6 +48,11 @@ class TreeViewComponent {
|
|
|
42
48
|
*/
|
|
43
49
|
this.ariaLabel = input("", /* @ts-ignore */
|
|
44
50
|
...(ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
51
|
+
/**
|
|
52
|
+
* @description Emitted when the tree-view loses focus.
|
|
53
|
+
*/
|
|
54
|
+
// eslint-disable-next-line @angular-eslint/no-output-native
|
|
55
|
+
this.blur = output();
|
|
45
56
|
/**
|
|
46
57
|
* @description Property name or accessor used to derive a node's children from a data item. Accepts a property name, a function returning the children, or a function returning an observable of the children.
|
|
47
58
|
* @default ""
|
|
@@ -54,6 +65,11 @@ class TreeViewComponent {
|
|
|
54
65
|
*/
|
|
55
66
|
this.data = input([], /* @ts-ignore */
|
|
56
67
|
...(ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []));
|
|
68
|
+
/**
|
|
69
|
+
* @description Emitted when the tree-view gains focus.
|
|
70
|
+
*/
|
|
71
|
+
// eslint-disable-next-line @angular-eslint/no-output-native
|
|
72
|
+
this.focus = output();
|
|
57
73
|
/**
|
|
58
74
|
* @description Predicate that determines whether a node has children. Required when the children selector returns an observable.
|
|
59
75
|
* @default null
|
|
@@ -72,14 +88,6 @@ class TreeViewComponent {
|
|
|
72
88
|
*/
|
|
73
89
|
this.mode = input("hierarchical", /* @ts-ignore */
|
|
74
90
|
...(ngDevMode ? [{ debugName: "mode" }] : /* istanbul ignore next */ []));
|
|
75
|
-
/**
|
|
76
|
-
* @description Emitted when the tree-view loses focus.
|
|
77
|
-
*/
|
|
78
|
-
this.blur = output();
|
|
79
|
-
/**
|
|
80
|
-
* @description Emitted when the tree-view gains focus.
|
|
81
|
-
*/
|
|
82
|
-
this.focus = output();
|
|
83
91
|
/**
|
|
84
92
|
* @description Emitted when a node is clicked.
|
|
85
93
|
*/
|
|
@@ -193,7 +201,7 @@ class TreeViewComponent {
|
|
|
193
201
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: TreeViewComponent, decorators: [{
|
|
194
202
|
type: Component,
|
|
195
203
|
args: [{ selector: "mona-tree-view", imports: [FilterInputComponent, TreeComponent, TreeNodeTemplateDirective, NgTemplateOutlet], providers: [TreeService], template: "@if (treeService.filterableOptions().enabled) {\n <div role=\"search\" [attr.aria-label]=\"filterAriaLabel()\">\n <mona-filter-input\n [filter]=\"treeService.filterText()\"\n [debounce]=\"treeService.filterableOptions().debounce\"\n [placeholder]=\"treeService.filterPlaceholder()\"\n (filterChange)=\"onFilterChange($event)\"></mona-filter-input>\n </div>\n}\n<div class=\"flex-1 overflow-auto\">\n <mona-tree [ariaLabel]=\"ariaLabel()\">\n @if (nodeTemplate()) {\n <ng-template monaTreeNodeTemplate let-dataItem let-element=\"element\">\n <ng-container\n [ngTemplateOutlet]=\"nodeTemplate() ?? null\"\n [ngTemplateOutletContext]=\"{ $implicit: dataItem, element }\"></ng-container>\n </ng-template>\n }\n </mona-tree>\n</div>\n" }]
|
|
196
|
-
}], ctorParameters: () => [], propDecorators: { nodeTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => TreeViewNodeTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], animate: [{ type: i0.Input, args: [{ isSignal: true, alias: "animate", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], children: [{ type: i0.Input, args: [{ isSignal: true, alias: "children", required: false }] }], data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }],
|
|
204
|
+
}], ctorParameters: () => [], propDecorators: { nodeTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => TreeViewNodeTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], animate: [{ type: i0.Input, args: [{ isSignal: true, alias: "animate", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], blur: [{ type: i0.Output, args: ["blur"] }], children: [{ type: i0.Input, args: [{ isSignal: true, alias: "children", required: false }] }], data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }], focus: [{ type: i0.Output, args: ["focus"] }], hasChildren: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasChildren", required: false }] }], idField: [{ type: i0.Input, args: [{ isSignal: true, alias: "idField", required: false }] }], mode: [{ type: i0.Input, args: [{ isSignal: true, alias: "mode", required: false }] }], nodeClick: [{ type: i0.Output, args: ["nodeClick"] }], parentIdField: [{ type: i0.Input, args: [{ isSignal: true, alias: "parentIdField", required: false }] }], textField: [{ type: i0.Input, args: [{ isSignal: true, alias: "textField", required: false }] }] } });
|
|
197
205
|
|
|
198
206
|
class TreeViewCheckableDirective {
|
|
199
207
|
#defaultOptions;
|
|
@@ -729,5 +737,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
729
737
|
* Generated bundle index. Do not edit.
|
|
730
738
|
*/
|
|
731
739
|
|
|
732
|
-
export { TreeViewCheckableDirective, TreeViewComponent, TreeViewDisableDirective, TreeViewDragAndDropDirective, TreeViewExpandableDirective, TreeViewFilterableDirective, TreeViewNodeTemplateDirective, TreeViewSelectableDirective };
|
|
740
|
+
export { TREE_VIEW_DEFAULT_MESSAGES, TreeViewCheckableDirective, TreeViewComponent, TreeViewDisableDirective, TreeViewDragAndDropDirective, TreeViewExpandableDirective, TreeViewFilterableDirective, TreeViewNodeTemplateDirective, TreeViewSelectableDirective };
|
|
733
741
|
//# sourceMappingURL=nanahoshi-mona-ui-tree-view.mjs.map
|
|
@@ -9,6 +9,7 @@ import { CdkTrapFocus } from '@angular/cdk/a11y';
|
|
|
9
9
|
import { NgTemplateOutlet } from '@angular/common';
|
|
10
10
|
import { LucideMinimize, LucideMaximize, LucideMinus, LucideDynamicIcon, LucideX } from '@lucide/angular';
|
|
11
11
|
import { ButtonDirective } from '@nanahoshi/mona-ui/button';
|
|
12
|
+
import { MonaI18nService, mergeMessages } from '@nanahoshi/mona-ui/i18n';
|
|
12
13
|
import { cva } from 'class-variance-authority';
|
|
13
14
|
|
|
14
15
|
class WindowActionTemplateDirective {
|
|
@@ -55,13 +56,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
55
56
|
}]
|
|
56
57
|
}] });
|
|
57
58
|
|
|
58
|
-
const
|
|
59
|
-
const
|
|
60
|
-
const
|
|
61
|
-
const
|
|
59
|
+
const DEFAULT_MAX_WINDOW_HEIGHT = 800;
|
|
60
|
+
const DEFAULT_MAX_WINDOW_WIDTH = 1200;
|
|
61
|
+
const DEFAULT_MIN_WINDOW_HEIGHT = 50;
|
|
62
|
+
const DEFAULT_MIN_WINDOW_WIDTH = 50;
|
|
62
63
|
|
|
63
|
-
const
|
|
64
|
-
const
|
|
64
|
+
const KEYBOARD_MOVE_STEP = 10;
|
|
65
|
+
const KEYBOARD_MOVE_STEP_FINE = 1;
|
|
65
66
|
class WindowDragHandlerDirective {
|
|
66
67
|
#destroyRef;
|
|
67
68
|
#document;
|
|
@@ -86,10 +87,10 @@ class WindowDragHandlerDirective {
|
|
|
86
87
|
if (!this.draggable()) {
|
|
87
88
|
return;
|
|
88
89
|
}
|
|
89
|
-
const step = event.shiftKey ?
|
|
90
|
+
const step = event.shiftKey ? KEYBOARD_MOVE_STEP_FINE : KEYBOARD_MOVE_STEP;
|
|
90
91
|
const element = this.windowRef().element;
|
|
91
|
-
const innerWidth = this.#document.defaultView?.innerWidth ||
|
|
92
|
-
const innerHeight = this.#document.defaultView?.innerHeight ||
|
|
92
|
+
const innerWidth = this.#document.defaultView?.innerWidth || DEFAULT_MAX_WINDOW_WIDTH;
|
|
93
|
+
const innerHeight = this.#document.defaultView?.innerHeight || DEFAULT_MAX_WINDOW_HEIGHT;
|
|
93
94
|
const initialTop = element.getBoundingClientRect().top;
|
|
94
95
|
const initialLeft = element.getBoundingClientRect().left;
|
|
95
96
|
let top = initialTop;
|
|
@@ -126,8 +127,8 @@ class WindowDragHandlerDirective {
|
|
|
126
127
|
const initialY = event.clientY;
|
|
127
128
|
const initialTop = element.getBoundingClientRect().top;
|
|
128
129
|
const initialLeft = element.getBoundingClientRect().left;
|
|
129
|
-
const innerWidth = this.#document.defaultView?.innerWidth ||
|
|
130
|
-
const innerHeight = this.#document.defaultView?.innerHeight ||
|
|
130
|
+
const innerWidth = this.#document.defaultView?.innerWidth || DEFAULT_MAX_WINDOW_WIDTH;
|
|
131
|
+
const innerHeight = this.#document.defaultView?.innerHeight || DEFAULT_MAX_WINDOW_HEIGHT;
|
|
131
132
|
let dragInitiated = false;
|
|
132
133
|
const onPointerMove = (event) => {
|
|
133
134
|
if (!dragInitiated) {
|
|
@@ -181,8 +182,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
181
182
|
}]
|
|
182
183
|
}], ctorParameters: () => [], propDecorators: { draggable: [{ type: i0.Input, args: [{ isSignal: true, alias: "draggable", required: false }] }], windowRef: [{ type: i0.Input, args: [{ isSignal: true, alias: "windowRef", required: true }] }] } });
|
|
183
184
|
|
|
184
|
-
const
|
|
185
|
-
const
|
|
185
|
+
const KEYBOARD_RESIZE_STEP = 10;
|
|
186
|
+
const KEYBOARD_RESIZE_STEP_FINE = 1;
|
|
186
187
|
class WindowResizeHandlerDirective {
|
|
187
188
|
#destroyRef;
|
|
188
189
|
#document;
|
|
@@ -212,7 +213,7 @@ class WindowResizeHandlerDirective {
|
|
|
212
213
|
this.#destroyRef.onDestroy(() => this.#activeCleanup?.());
|
|
213
214
|
}
|
|
214
215
|
onKeydown(event) {
|
|
215
|
-
const step = event.shiftKey ?
|
|
216
|
+
const step = event.shiftKey ? KEYBOARD_RESIZE_STEP_FINE : KEYBOARD_RESIZE_STEP;
|
|
216
217
|
let deltaX = 0;
|
|
217
218
|
let deltaY = 0;
|
|
218
219
|
switch (event.key) {
|
|
@@ -262,13 +263,13 @@ class WindowResizeHandlerDirective {
|
|
|
262
263
|
});
|
|
263
264
|
}
|
|
264
265
|
#bounds() {
|
|
265
|
-
const innerWidth = this.#document.defaultView?.innerWidth ||
|
|
266
|
-
const innerHeight = this.#document.defaultView?.innerHeight ||
|
|
266
|
+
const innerWidth = this.#document.defaultView?.innerWidth || DEFAULT_MAX_WINDOW_WIDTH;
|
|
267
|
+
const innerHeight = this.#document.defaultView?.innerHeight || DEFAULT_MAX_WINDOW_HEIGHT;
|
|
267
268
|
return {
|
|
268
269
|
innerWidth,
|
|
269
270
|
innerHeight,
|
|
270
|
-
minWidth: this.minWidth() ||
|
|
271
|
-
minHeight: this.minHeight() ||
|
|
271
|
+
minWidth: this.minWidth() || DEFAULT_MIN_WINDOW_WIDTH,
|
|
272
|
+
minHeight: this.minHeight() || DEFAULT_MIN_WINDOW_HEIGHT,
|
|
272
273
|
maxWidth: this.maxWidth() ?? innerWidth,
|
|
273
274
|
maxHeight: this.maxHeight() ?? innerHeight
|
|
274
275
|
};
|
|
@@ -431,6 +432,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
431
432
|
}]
|
|
432
433
|
}], ctorParameters: () => [], propDecorators: { direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: true }] }], maxHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxHeight", required: false }] }], maxWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxWidth", required: false }] }], minHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "minHeight", required: false }] }], minWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "minWidth", required: false }] }], windowRef: [{ type: i0.Input, args: [{ isSignal: true, alias: "windowRef", required: true }] }] } });
|
|
433
434
|
|
|
435
|
+
const WINDOW_DEFAULT_MESSAGES = {
|
|
436
|
+
close: "Close",
|
|
437
|
+
closeWindow: "Close window",
|
|
438
|
+
maximize: "Maximize",
|
|
439
|
+
minimize: "Minimize",
|
|
440
|
+
moveWindow: "Move window. Use arrow keys to move.",
|
|
441
|
+
resizeBottom: "Resize window from the bottom. Use arrow keys to resize.",
|
|
442
|
+
resizeBottomLeft: "Resize window from the bottom-left corner. Use arrow keys to resize.",
|
|
443
|
+
resizeBottomRight: "Resize window from the bottom-right corner. Use arrow keys to resize.",
|
|
444
|
+
resizeLeft: "Resize window from the left. Use arrow keys to resize.",
|
|
445
|
+
resizeRight: "Resize window from the right. Use arrow keys to resize.",
|
|
446
|
+
resizeTop: "Resize window from the top. Use arrow keys to resize.",
|
|
447
|
+
resizeTopLeft: "Resize window from the top-left corner. Use arrow keys to resize.",
|
|
448
|
+
resizeTopRight: "Resize window from the top-right corner. Use arrow keys to resize.",
|
|
449
|
+
restore: "Restore"
|
|
450
|
+
};
|
|
451
|
+
|
|
434
452
|
const windowBaseThemeVariants = cva(`
|
|
435
453
|
flex h-full w-full flex-col
|
|
436
454
|
${themeOverlaySurfaceClasses} text-foreground
|
|
@@ -470,14 +488,14 @@ const windowResizerThemeVariants = cva(`
|
|
|
470
488
|
`, {
|
|
471
489
|
variants: {
|
|
472
490
|
position: {
|
|
473
|
-
east: "
|
|
474
|
-
north: "
|
|
475
|
-
south: "
|
|
476
|
-
west: "
|
|
477
|
-
northeast: "-top-0.5 -
|
|
478
|
-
northwest: "-top-0.5 -
|
|
479
|
-
southeast: "-bottom-0.5 -
|
|
480
|
-
southwest: "-bottom-0.5 -
|
|
491
|
+
east: "inset-y-0 -end-0.5 w-2 cursor-ew-resize rtl:-start-0.5 rtl:end-auto",
|
|
492
|
+
north: "inset-x-0 -top-0.5 h-2 cursor-ns-resize",
|
|
493
|
+
south: "inset-x-0 -bottom-0.5 h-2 cursor-ns-resize",
|
|
494
|
+
west: "inset-y-0 -start-0.5 w-2 cursor-ew-resize rtl:-end-0.5 rtl:start-auto",
|
|
495
|
+
northeast: "-top-0.5 -end-0.5 w-2 h-2 cursor-nesw-resize rtl:-start-0.5 rtl:end-auto",
|
|
496
|
+
northwest: "-top-0.5 -start-0.5 w-2 h-2 cursor-nwse-resize rtl:-end-0.5 rtl:start-auto",
|
|
497
|
+
southeast: "-bottom-0.5 -end-0.5 w-2 h-2 cursor-nwse-resize rtl:-start-0.5 rtl:end-auto",
|
|
498
|
+
southwest: "-bottom-0.5 -start-0.5 w-2 h-2 cursor-nesw-resize rtl:-end-0.5 rtl:start-auto"
|
|
481
499
|
}
|
|
482
500
|
}
|
|
483
501
|
});
|
|
@@ -538,7 +556,9 @@ class WindowContentComponent {
|
|
|
538
556
|
#appRef;
|
|
539
557
|
#document;
|
|
540
558
|
#hostElementRef;
|
|
559
|
+
#i18n;
|
|
541
560
|
#injector;
|
|
561
|
+
#localeMessages;
|
|
542
562
|
#sizeBeforeMaximize;
|
|
543
563
|
#sizeBeforeMinimize;
|
|
544
564
|
#trapFocus;
|
|
@@ -547,7 +567,9 @@ class WindowContentComponent {
|
|
|
547
567
|
this.#appRef = inject(ApplicationRef);
|
|
548
568
|
this.#document = inject(DOCUMENT);
|
|
549
569
|
this.#hostElementRef = inject(ElementRef);
|
|
570
|
+
this.#i18n = inject(MonaI18nService);
|
|
550
571
|
this.#injector = inject(Injector);
|
|
572
|
+
this.#localeMessages = this.#i18n.componentMessages("window", WINDOW_DEFAULT_MESSAGES);
|
|
551
573
|
this.#sizeBeforeMaximize = signal({ width: 0, height: 0, top: 0, left: 0 }, /* @ts-ignore */
|
|
552
574
|
...(ngDevMode ? [{ debugName: "#sizeBeforeMaximize" }] : /* istanbul ignore next */ []));
|
|
553
575
|
this.#sizeBeforeMinimize = signal(0, /* @ts-ignore */
|
|
@@ -583,6 +605,10 @@ class WindowContentComponent {
|
|
|
583
605
|
...(ngDevMode ? [{ debugName: "maximizeIcon" }] : /* istanbul ignore next */ []));
|
|
584
606
|
this.maximized = signal(false, /* @ts-ignore */
|
|
585
607
|
...(ngDevMode ? [{ debugName: "maximized" }] : /* istanbul ignore next */ []));
|
|
608
|
+
this.messages = computed(() => {
|
|
609
|
+
return mergeMessages(this.#localeMessages(), this.windowData.messages);
|
|
610
|
+
}, /* @ts-ignore */
|
|
611
|
+
...(ngDevMode ? [{ debugName: "messages" }] : /* istanbul ignore next */ []));
|
|
586
612
|
this.minimized = signal(false, /* @ts-ignore */
|
|
587
613
|
...(ngDevMode ? [{ debugName: "minimized" }] : /* istanbul ignore next */ []));
|
|
588
614
|
this.titleBarActionClass = computed(() => {
|
|
@@ -709,7 +735,7 @@ class WindowContentComponent {
|
|
|
709
735
|
}
|
|
710
736
|
}
|
|
711
737
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: WindowContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
712
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: WindowContentComponent, isStandalone: true, selector: "mona-window-content", host: { attributes: { "role": "dialog" }, properties: { "class": "baseClass()", "attr.aria-labelledby": "headerId", "attr.aria-modal": "windowData.modal ?? false" } }, viewQueries: [{ propertyName: "componentAnchor", first: true, predicate: ["componentAnchor"], descendants: true, read: ViewContainerRef, isSignal: true }], hostDirectives: [{ directive: i1.CdkTrapFocus }], ngImport: i0, template: "<div [class]=\"contentContainerClass()\">\n <div\n [class]=\"titleBarClass()\"\n monaWindowDragHandler\n (dblclick)=\"onMaximizeClick()\"\n [draggable]=\"windowData.draggable\"\n [windowRef]=\"windowData.windowReference\"\n [attr.tabindex]=\"windowData.draggable ? 0 : null\"\n [attr.aria-label]=\"windowData.draggable ?
|
|
738
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: WindowContentComponent, isStandalone: true, selector: "mona-window-content", host: { attributes: { "role": "dialog" }, properties: { "class": "baseClass()", "attr.aria-labelledby": "headerId", "attr.aria-modal": "windowData.modal ?? false" } }, viewQueries: [{ propertyName: "componentAnchor", first: true, predicate: ["componentAnchor"], descendants: true, read: ViewContainerRef, isSignal: true }], hostDirectives: [{ directive: i1.CdkTrapFocus }], ngImport: i0, template: "<div [class]=\"contentContainerClass()\">\n <div\n [class]=\"titleBarClass()\"\n monaWindowDragHandler\n (dblclick)=\"onMaximizeClick()\"\n [draggable]=\"windowData.draggable\"\n [windowRef]=\"windowData.windowReference\"\n [attr.tabindex]=\"windowData.draggable ? 0 : null\"\n [attr.aria-label]=\"windowData.draggable ? messages().moveWindow : null\">\n <div [id]=\"headerId\" [class]=\"titleContainerClass()\">\n @if (windowData.titleTemplate) {\n <ng-container [ngTemplateOutlet]=\"windowData.titleTemplate\"></ng-container>\n } @else {\n <span [class]=\"titleClass()\">{{ windowData.title ?? \"\" }}</span>\n }\n </div>\n <div [class]=\"titleBarActionClass()\">\n @if (windowData.actionTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"windowData.actionTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: windowData.windowReference.windowRef }\">\n </ng-container>\n }\n @let maximizeTitle = maximized() || minimized() ? messages().restore : messages().maximize;\n @if (windowData.minimizable && !minimized()) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n type=\"button\"\n [iconOnly]=\"true\"\n [rounded]=\"windowData.rounded\"\n [title]=\"messages().minimize\"\n [attr.aria-label]=\"messages().minimize\"\n (dblclick)=\"$event.stopPropagation()\"\n (click)=\"onMinimizeClick()\">\n <svg lucideMinus [size]=\"16\" aria-hidden=\"true\"></svg>\n </button>\n }\n @if (windowData.maximizable) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n type=\"button\"\n [iconOnly]=\"true\"\n [rounded]=\"windowData.rounded\"\n [title]=\"maximizeTitle\"\n [attr.aria-label]=\"maximizeTitle\"\n (dblclick)=\"$event.stopPropagation()\"\n (click)=\"onMaximizeClick()\">\n <svg [lucideIcon]=\"maximizeIcon()\" [size]=\"16\" aria-hidden=\"true\"></svg>\n </button>\n }\n @if (windowData.closable) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n type=\"button\"\n [iconOnly]=\"true\"\n [rounded]=\"windowData.rounded\"\n [title]=\"messages().close\"\n [attr.aria-label]=\"messages().closeWindow\"\n (dblclick)=\"$event.stopPropagation()\"\n (click)=\"onCloseClick($event)\">\n <svg lucideX [size]=\"16\" aria-hidden=\"true\"></svg>\n </button>\n }\n </div>\n </div>\n @if (!minimized()) {\n <div [class]=\"contentClass()\">\n @switch (contentType()) {\n @case (\"template\") {\n <ng-container [ngTemplateOutlet]=\"contentTemplate()!\"></ng-container>\n }\n @case (\"component\") {\n <ng-container #componentAnchor></ng-container>\n }\n }\n </div>\n @if (windowData.footerTemplate) {\n <div>\n <ng-container [ngTemplateOutlet]=\"windowData.footerTemplate\"></ng-container>\n </div>\n }\n }\n @if (windowData.resizable && !maximized()) {\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"north\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeTop\"\n [class]=\"'north' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"south\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeBottom\"\n [class]=\"'south' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"east\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeRight\"\n [class]=\"'east' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"west\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeLeft\"\n [class]=\"'west' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"northeast\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeTopRight\"\n [class]=\"'northeast' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"northwest\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeTopLeft\"\n [class]=\"'northwest' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"southeast\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeBottomRight\"\n [class]=\"'southeast' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"southwest\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeBottomLeft\"\n [class]=\"'southwest' | monaResizePosition\"></div>\n }\n</div>\n", dependencies: [{ kind: "directive", type: WindowDragHandlerDirective, selector: "div[monaWindowDragHandler]", inputs: ["draggable", "windowRef"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: ButtonDirective, selector: "button[monaButton]", inputs: ["aria-haspopup", "disabled", "iconOnly", "loading", "look", "rounded", "selected", "size", "tabindex", "type", "toggleable", "class"], outputs: ["disabledChange", "loadingChange", "lookChange", "selectedChange"] }, { kind: "directive", type: WindowResizeHandlerDirective, selector: "div[monaWindowResizeHandler]", inputs: ["direction", "maxHeight", "maxWidth", "minHeight", "minWidth", "windowRef"] }, { kind: "component", type: LucideMinus, selector: "svg[lucideMinus]" }, { kind: "component", type: LucideDynamicIcon, selector: "svg[lucideIcon]", inputs: ["lucideIcon"] }, { kind: "component", type: LucideX, selector: "svg[lucideX]" }, { kind: "pipe", type: ResizePositionPipe, name: "monaResizePosition" }] }); }
|
|
713
739
|
}
|
|
714
740
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: WindowContentComponent, decorators: [{
|
|
715
741
|
type: Component,
|
|
@@ -727,7 +753,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
727
753
|
"[attr.aria-labelledby]": "headerId",
|
|
728
754
|
"[attr.aria-modal]": "windowData.modal ?? false",
|
|
729
755
|
role: "dialog"
|
|
730
|
-
}, hostDirectives: [CdkTrapFocus], template: "<div [class]=\"contentContainerClass()\">\n <div\n [class]=\"titleBarClass()\"\n monaWindowDragHandler\n (dblclick)=\"onMaximizeClick()\"\n [draggable]=\"windowData.draggable\"\n [windowRef]=\"windowData.windowReference\"\n [attr.tabindex]=\"windowData.draggable ? 0 : null\"\n [attr.aria-label]=\"windowData.draggable ?
|
|
756
|
+
}, hostDirectives: [CdkTrapFocus], template: "<div [class]=\"contentContainerClass()\">\n <div\n [class]=\"titleBarClass()\"\n monaWindowDragHandler\n (dblclick)=\"onMaximizeClick()\"\n [draggable]=\"windowData.draggable\"\n [windowRef]=\"windowData.windowReference\"\n [attr.tabindex]=\"windowData.draggable ? 0 : null\"\n [attr.aria-label]=\"windowData.draggable ? messages().moveWindow : null\">\n <div [id]=\"headerId\" [class]=\"titleContainerClass()\">\n @if (windowData.titleTemplate) {\n <ng-container [ngTemplateOutlet]=\"windowData.titleTemplate\"></ng-container>\n } @else {\n <span [class]=\"titleClass()\">{{ windowData.title ?? \"\" }}</span>\n }\n </div>\n <div [class]=\"titleBarActionClass()\">\n @if (windowData.actionTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"windowData.actionTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: windowData.windowReference.windowRef }\">\n </ng-container>\n }\n @let maximizeTitle = maximized() || minimized() ? messages().restore : messages().maximize;\n @if (windowData.minimizable && !minimized()) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n type=\"button\"\n [iconOnly]=\"true\"\n [rounded]=\"windowData.rounded\"\n [title]=\"messages().minimize\"\n [attr.aria-label]=\"messages().minimize\"\n (dblclick)=\"$event.stopPropagation()\"\n (click)=\"onMinimizeClick()\">\n <svg lucideMinus [size]=\"16\" aria-hidden=\"true\"></svg>\n </button>\n }\n @if (windowData.maximizable) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n type=\"button\"\n [iconOnly]=\"true\"\n [rounded]=\"windowData.rounded\"\n [title]=\"maximizeTitle\"\n [attr.aria-label]=\"maximizeTitle\"\n (dblclick)=\"$event.stopPropagation()\"\n (click)=\"onMaximizeClick()\">\n <svg [lucideIcon]=\"maximizeIcon()\" [size]=\"16\" aria-hidden=\"true\"></svg>\n </button>\n }\n @if (windowData.closable) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n type=\"button\"\n [iconOnly]=\"true\"\n [rounded]=\"windowData.rounded\"\n [title]=\"messages().close\"\n [attr.aria-label]=\"messages().closeWindow\"\n (dblclick)=\"$event.stopPropagation()\"\n (click)=\"onCloseClick($event)\">\n <svg lucideX [size]=\"16\" aria-hidden=\"true\"></svg>\n </button>\n }\n </div>\n </div>\n @if (!minimized()) {\n <div [class]=\"contentClass()\">\n @switch (contentType()) {\n @case (\"template\") {\n <ng-container [ngTemplateOutlet]=\"contentTemplate()!\"></ng-container>\n }\n @case (\"component\") {\n <ng-container #componentAnchor></ng-container>\n }\n }\n </div>\n @if (windowData.footerTemplate) {\n <div>\n <ng-container [ngTemplateOutlet]=\"windowData.footerTemplate\"></ng-container>\n </div>\n }\n }\n @if (windowData.resizable && !maximized()) {\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"north\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeTop\"\n [class]=\"'north' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"south\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeBottom\"\n [class]=\"'south' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"east\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeRight\"\n [class]=\"'east' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"west\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeLeft\"\n [class]=\"'west' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"northeast\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeTopRight\"\n [class]=\"'northeast' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"northwest\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeTopLeft\"\n [class]=\"'northwest' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"southeast\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeBottomRight\"\n [class]=\"'southeast' | monaResizePosition\"></div>\n <div\n monaWindowResizeHandler\n [minWidth]=\"windowData.minWidth\"\n [minHeight]=\"windowData.minHeight\"\n [maxWidth]=\"windowData.maxWidth\"\n [maxHeight]=\"windowData.maxHeight\"\n [windowRef]=\"windowData.windowReference\"\n direction=\"southwest\"\n tabindex=\"0\"\n [attr.aria-label]=\"messages().resizeBottomLeft\"\n [class]=\"'southwest' | monaResizePosition\"></div>\n }\n</div>\n" }]
|
|
731
757
|
}], ctorParameters: () => [], propDecorators: { componentAnchor: [{ type: i0.ViewChild, args: ["componentAnchor", { ...{
|
|
732
758
|
read: ViewContainerRef
|
|
733
759
|
}, isSignal: true }] }] } });
|
|
@@ -805,8 +831,8 @@ class WindowReference {
|
|
|
805
831
|
const element = this.#popupRefOrThrow.overlayRef.overlayElement;
|
|
806
832
|
const width = element.getBoundingClientRect().width;
|
|
807
833
|
const height = element.getBoundingClientRect().height;
|
|
808
|
-
const left = (this.document.defaultView?.innerWidth ||
|
|
809
|
-
const top = (this.document.defaultView?.innerHeight ||
|
|
834
|
+
const left = (this.document.defaultView?.innerWidth || DEFAULT_MAX_WINDOW_WIDTH - width) / 2;
|
|
835
|
+
const top = (this.document.defaultView?.innerHeight || DEFAULT_MAX_WINDOW_HEIGHT - height) / 2;
|
|
810
836
|
element.style.left = `${left}px`;
|
|
811
837
|
element.style.top = `${top}px`;
|
|
812
838
|
}
|
|
@@ -903,6 +929,7 @@ const createWindowInjectorData = (settings) => {
|
|
|
903
929
|
maxHeight: settings.maxHeight,
|
|
904
930
|
maxWidth: settings.maxWidth,
|
|
905
931
|
maximizable: settings.maximizable ?? true,
|
|
932
|
+
messages: settings.messages,
|
|
906
933
|
minHeight: settings.minHeight ?? 50,
|
|
907
934
|
minWidth: settings.minWidth ?? 50,
|
|
908
935
|
minimizable: settings.minimizable ?? true,
|
|
@@ -991,20 +1018,18 @@ class WindowComponent {
|
|
|
991
1018
|
*/
|
|
992
1019
|
this.closable = input(true, /* @ts-ignore */
|
|
993
1020
|
...(ngDevMode ? [{ debugName: "closable" }] : /* istanbul ignore next */ []));
|
|
994
|
-
|
|
995
|
-
* @description Emits when the window is about to be closed.
|
|
996
|
-
*/
|
|
1021
|
+
// eslint-disable-next-line @angular-eslint/no-output-native
|
|
997
1022
|
this.close = output();
|
|
998
|
-
/**
|
|
999
|
-
* @description Emitted after the window has fully closed (post-animation). Preventing this event has no effect.
|
|
1000
|
-
*/
|
|
1001
|
-
this.closed = output();
|
|
1002
1023
|
/**
|
|
1003
1024
|
* @description Sets whether the window should close when the escape key is pressed.
|
|
1004
1025
|
* @default true
|
|
1005
1026
|
*/
|
|
1006
1027
|
this.closeOnEscape = input(true, /* @ts-ignore */
|
|
1007
1028
|
...(ngDevMode ? [{ debugName: "closeOnEscape" }] : /* istanbul ignore next */ []));
|
|
1029
|
+
/**
|
|
1030
|
+
* @description Emitted after the window has fully closed (post-animation). Preventing this event has no effect.
|
|
1031
|
+
*/
|
|
1032
|
+
this.closed = output();
|
|
1008
1033
|
/**
|
|
1009
1034
|
* @description Emits when the window dragging ends.
|
|
1010
1035
|
*/
|
|
@@ -1057,6 +1082,11 @@ class WindowComponent {
|
|
|
1057
1082
|
*/
|
|
1058
1083
|
this.maximizable = input(/* @ts-ignore */
|
|
1059
1084
|
...(ngDevMode ? [undefined, { debugName: "maximizable" }] : /* istanbul ignore next */ []));
|
|
1085
|
+
/**
|
|
1086
|
+
* @description Internationalization message overrides for accessible labels.
|
|
1087
|
+
*/
|
|
1088
|
+
this.messages = input(/* @ts-ignore */
|
|
1089
|
+
...(ngDevMode ? [undefined, { debugName: "messages" }] : /* istanbul ignore next */ []));
|
|
1060
1090
|
/**
|
|
1061
1091
|
* @description Sets the minimum height of the window.
|
|
1062
1092
|
*/
|
|
@@ -1157,6 +1187,7 @@ class WindowComponent {
|
|
|
1157
1187
|
maxHeight: this.maxHeight(),
|
|
1158
1188
|
maxWidth: this.maxWidth(),
|
|
1159
1189
|
maximizable: this.maximizable(),
|
|
1190
|
+
messages: this.messages(),
|
|
1160
1191
|
minHeight: this.minHeight(),
|
|
1161
1192
|
minWidth: this.minWidth(),
|
|
1162
1193
|
minimizable: this.minimizable(),
|
|
@@ -1224,7 +1255,7 @@ class WindowComponent {
|
|
|
1224
1255
|
this.#setResizeSubscription();
|
|
1225
1256
|
}
|
|
1226
1257
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: WindowComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1227
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.0.6", type: WindowComponent, isStandalone: true, selector: "mona-window", inputs: { closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, closeOnEscape: { classPropertyName: "closeOnEscape", publicName: "closeOnEscape", isSignal: true, isRequired: false, transformFunction: null }, draggable: { classPropertyName: "draggable", publicName: "draggable", isSignal: true, isRequired: false, transformFunction: null }, focusedElement: { classPropertyName: "focusedElement", publicName: "focusedElement", isSignal: true, isRequired: false, transformFunction: null }, height: { classPropertyName: "height", publicName: "height", isSignal: true, isRequired: false, transformFunction: null }, left: { classPropertyName: "left", publicName: "left", isSignal: true, isRequired: false, transformFunction: null }, look: { classPropertyName: "look", publicName: "look", isSignal: true, isRequired: false, transformFunction: null }, maxHeight: { classPropertyName: "maxHeight", publicName: "maxHeight", isSignal: true, isRequired: false, transformFunction: null }, maxWidth: { classPropertyName: "maxWidth", publicName: "maxWidth", isSignal: true, isRequired: false, transformFunction: null }, maximizable: { classPropertyName: "maximizable", publicName: "maximizable", isSignal: true, isRequired: false, transformFunction: null }, minHeight: { classPropertyName: "minHeight", publicName: "minHeight", isSignal: true, isRequired: false, transformFunction: null }, minWidth: { classPropertyName: "minWidth", publicName: "minWidth", isSignal: true, isRequired: false, transformFunction: null }, minimizable: { classPropertyName: "minimizable", publicName: "minimizable", isSignal: true, isRequired: false, transformFunction: null }, modal: { classPropertyName: "modal", publicName: "modal", isSignal: true, isRequired: false, transformFunction: null }, resizable: { classPropertyName: "resizable", publicName: "resizable", isSignal: true, isRequired: false, transformFunction: null }, rounded: { classPropertyName: "rounded", publicName: "rounded", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, top: { classPropertyName: "top", publicName: "top", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { close: "close", closed: "closed", dragEnd: "dragEnd", dragStart: "dragStart", height: "heightChange", left: "leftChange", top: "topChange", width: "widthChange" }, host: { classAttribute: "hidden" }, queries: [{ propertyName: "actionTemplate", first: true, predicate: WindowActionTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }, { propertyName: "contentTemplate", first: true, predicate: WindowContentTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }, { propertyName: "footerTemplate", first: true, predicate: WindowFooterTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }, { propertyName: "titleTemplate", first: true, predicate: WindowTitleTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: ``, isInline: true }); }
|
|
1258
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.0.6", type: WindowComponent, isStandalone: true, selector: "mona-window", inputs: { closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, closeOnEscape: { classPropertyName: "closeOnEscape", publicName: "closeOnEscape", isSignal: true, isRequired: false, transformFunction: null }, draggable: { classPropertyName: "draggable", publicName: "draggable", isSignal: true, isRequired: false, transformFunction: null }, focusedElement: { classPropertyName: "focusedElement", publicName: "focusedElement", isSignal: true, isRequired: false, transformFunction: null }, height: { classPropertyName: "height", publicName: "height", isSignal: true, isRequired: false, transformFunction: null }, left: { classPropertyName: "left", publicName: "left", isSignal: true, isRequired: false, transformFunction: null }, look: { classPropertyName: "look", publicName: "look", isSignal: true, isRequired: false, transformFunction: null }, maxHeight: { classPropertyName: "maxHeight", publicName: "maxHeight", isSignal: true, isRequired: false, transformFunction: null }, maxWidth: { classPropertyName: "maxWidth", publicName: "maxWidth", isSignal: true, isRequired: false, transformFunction: null }, maximizable: { classPropertyName: "maximizable", publicName: "maximizable", isSignal: true, isRequired: false, transformFunction: null }, messages: { classPropertyName: "messages", publicName: "messages", isSignal: true, isRequired: false, transformFunction: null }, minHeight: { classPropertyName: "minHeight", publicName: "minHeight", isSignal: true, isRequired: false, transformFunction: null }, minWidth: { classPropertyName: "minWidth", publicName: "minWidth", isSignal: true, isRequired: false, transformFunction: null }, minimizable: { classPropertyName: "minimizable", publicName: "minimizable", isSignal: true, isRequired: false, transformFunction: null }, modal: { classPropertyName: "modal", publicName: "modal", isSignal: true, isRequired: false, transformFunction: null }, resizable: { classPropertyName: "resizable", publicName: "resizable", isSignal: true, isRequired: false, transformFunction: null }, rounded: { classPropertyName: "rounded", publicName: "rounded", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, top: { classPropertyName: "top", publicName: "top", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { close: "close", closed: "closed", dragEnd: "dragEnd", dragStart: "dragStart", height: "heightChange", left: "leftChange", top: "topChange", width: "widthChange" }, host: { classAttribute: "hidden" }, queries: [{ propertyName: "actionTemplate", first: true, predicate: WindowActionTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }, { propertyName: "contentTemplate", first: true, predicate: WindowContentTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }, { propertyName: "footerTemplate", first: true, predicate: WindowFooterTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }, { propertyName: "titleTemplate", first: true, predicate: WindowTitleTemplateDirective, descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: ``, isInline: true }); }
|
|
1228
1259
|
}
|
|
1229
1260
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: WindowComponent, decorators: [{
|
|
1230
1261
|
type: Component,
|
|
@@ -1235,7 +1266,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
1235
1266
|
class: "hidden"
|
|
1236
1267
|
}
|
|
1237
1268
|
}]
|
|
1238
|
-
}], ctorParameters: () => [], propDecorators: { actionTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowActionTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], contentTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowContentTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], footerTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowFooterTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], titleTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowTitleTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], closable: [{ type: i0.Input, args: [{ isSignal: true, alias: "closable", required: false }] }], close: [{ type: i0.Output, args: ["close"] }],
|
|
1269
|
+
}], ctorParameters: () => [], propDecorators: { actionTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowActionTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], contentTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowContentTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], footerTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowFooterTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], titleTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => WindowTitleTemplateDirective), { ...{ read: TemplateRef }, isSignal: true }] }], closable: [{ type: i0.Input, args: [{ isSignal: true, alias: "closable", required: false }] }], close: [{ type: i0.Output, args: ["close"] }], closeOnEscape: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnEscape", required: false }] }], closed: [{ type: i0.Output, args: ["closed"] }], dragEnd: [{ type: i0.Output, args: ["dragEnd"] }], dragStart: [{ type: i0.Output, args: ["dragStart"] }], draggable: [{ type: i0.Input, args: [{ isSignal: true, alias: "draggable", required: false }] }], focusedElement: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusedElement", required: false }] }], height: [{ type: i0.Input, args: [{ isSignal: true, alias: "height", required: false }] }, { type: i0.Output, args: ["heightChange"] }], left: [{ type: i0.Input, args: [{ isSignal: true, alias: "left", required: false }] }, { type: i0.Output, args: ["leftChange"] }], look: [{ type: i0.Input, args: [{ isSignal: true, alias: "look", required: false }] }], maxHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxHeight", required: false }] }], maxWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxWidth", required: false }] }], maximizable: [{ type: i0.Input, args: [{ isSignal: true, alias: "maximizable", required: false }] }], messages: [{ type: i0.Input, args: [{ isSignal: true, alias: "messages", required: false }] }], minHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "minHeight", required: false }] }], minWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "minWidth", required: false }] }], minimizable: [{ type: i0.Input, args: [{ isSignal: true, alias: "minimizable", required: false }] }], modal: [{ type: i0.Input, args: [{ isSignal: true, alias: "modal", required: false }] }], resizable: [{ type: i0.Input, args: [{ isSignal: true, alias: "resizable", required: false }] }], rounded: [{ type: i0.Input, args: [{ isSignal: true, alias: "rounded", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], top: [{ type: i0.Input, args: [{ isSignal: true, alias: "top", required: false }] }, { type: i0.Output, args: ["topChange"] }], width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: false }] }, { type: i0.Output, args: ["widthChange"] }] } });
|
|
1239
1270
|
|
|
1240
1271
|
/*
|
|
1241
1272
|
* Public API Surface of @nanahoshi/mona-ui/window
|
|
@@ -1245,5 +1276,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
1245
1276
|
* Generated bundle index. Do not edit.
|
|
1246
1277
|
*/
|
|
1247
1278
|
|
|
1248
|
-
export { WindowActionTemplateDirective, WindowComponent, WindowContentTemplateDirective, WindowFooterTemplateDirective, WindowRef, WindowService, WindowTitleTemplateDirective };
|
|
1279
|
+
export { WINDOW_DEFAULT_MESSAGES, WindowActionTemplateDirective, WindowComponent, WindowContentTemplateDirective, WindowFooterTemplateDirective, WindowRef, WindowService, WindowTitleTemplateDirective };
|
|
1249
1280
|
//# sourceMappingURL=nanahoshi-mona-ui-window.mjs.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nanahoshi/mona-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.20.0",
|
|
4
4
|
"description": "A very light Angular UI framework",
|
|
5
5
|
"author": "Nanahoshi",
|
|
6
6
|
"repository": {
|
|
@@ -187,6 +187,10 @@
|
|
|
187
187
|
"types": "./types/nanahoshi-mona-ui-grid.d.ts",
|
|
188
188
|
"default": "./fesm2022/nanahoshi-mona-ui-grid.mjs"
|
|
189
189
|
},
|
|
190
|
+
"./i18n": {
|
|
191
|
+
"types": "./types/nanahoshi-mona-ui-i18n.d.ts",
|
|
192
|
+
"default": "./fesm2022/nanahoshi-mona-ui-i18n.mjs"
|
|
193
|
+
},
|
|
190
194
|
"./internal": {
|
|
191
195
|
"types": "./types/nanahoshi-mona-ui-internal.d.ts",
|
|
192
196
|
"default": "./fesm2022/nanahoshi-mona-ui-internal.mjs"
|
|
@@ -223,6 +227,10 @@
|
|
|
223
227
|
"types": "./types/nanahoshi-mona-ui-list-view.d.ts",
|
|
224
228
|
"default": "./fesm2022/nanahoshi-mona-ui-list-view.mjs"
|
|
225
229
|
},
|
|
230
|
+
"./locales": {
|
|
231
|
+
"types": "./types/nanahoshi-mona-ui-locales.d.ts",
|
|
232
|
+
"default": "./fesm2022/nanahoshi-mona-ui-locales.mjs"
|
|
233
|
+
},
|
|
226
234
|
"./menubar": {
|
|
227
235
|
"types": "./types/nanahoshi-mona-ui-menubar.d.ts",
|
|
228
236
|
"default": "./fesm2022/nanahoshi-mona-ui-menubar.mjs"
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import * as _nanahoshi_mona_ui_i18n from '@nanahoshi/mona-ui/i18n';
|
|
2
|
+
import { MonaAutoCompleteMessages } from '@nanahoshi/mona-ui/i18n';
|
|
1
3
|
import * as _angular_core from '@angular/core';
|
|
2
4
|
import { TemplateRef } from '@angular/core';
|
|
3
5
|
import { FormValueControl } from '@angular/forms/signals';
|
|
@@ -50,6 +52,7 @@ declare class AutoCompleteComponent<TData = unknown> implements FormValueControl
|
|
|
50
52
|
protected readonly isEmpty: _angular_core.Signal<boolean>;
|
|
51
53
|
protected readonly listId: string;
|
|
52
54
|
protected readonly listPopupClass: _angular_core.Signal<string>;
|
|
55
|
+
protected readonly messages: _angular_core.Signal<_nanahoshi_mona_ui_i18n.MonaAutoCompleteMessages>;
|
|
53
56
|
protected readonly noDataTemplate: _angular_core.Signal<TemplateRef<any> | undefined>;
|
|
54
57
|
protected readonly popupTemplate: _angular_core.Signal<TemplateRef<any>>;
|
|
55
58
|
protected readonly prefixTemplate: _angular_core.Signal<TemplateRef<any> | undefined>;
|
|
@@ -219,4 +222,6 @@ declare class AutoCompleteComponent<TData = unknown> implements FormValueControl
|
|
|
219
222
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<AutoCompleteComponent<any>, "mona-auto-complete", never, { "ariaDescribedBy": { "alias": "aria-describedby"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "aria-label"; "required": false; "isSignal": true; }; "ariaLabelledBy": { "alias": "aria-labelledby"; "required": false; "isSignal": true; }; "data": { "alias": "data"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "itemDisabled": { "alias": "itemDisabled"; "required": false; "isSignal": true; }; "invalid": { "alias": "invalid"; "required": false; "isSignal": true; }; "highlightFirst": { "alias": "highlightFirst"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "popupClass": { "alias": "popupClass"; "required": false; "isSignal": true; }; "popupHeight": { "alias": "popupHeight"; "required": false; "isSignal": true; }; "popupWidth": { "alias": "popupWidth"; "required": false; "isSignal": true; }; "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "rounded": { "alias": "rounded"; "required": false; "isSignal": true; }; "showClearButton": { "alias": "showClearButton"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "textField": { "alias": "textField"; "required": false; "isSignal": true; }; "touched": { "alias": "touched"; "required": false; "isSignal": true; }; "userClass": { "alias": "class"; "required": false; "isSignal": true; }; "valueField": { "alias": "valueField"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; }, { "close": "close"; "closed": "closed"; "disabled": "disabledChange"; "open": "open"; "opened": "opened"; "touch": "touch"; "value": "valueChange"; }, ["footerTemplate", "groupHeaderTemplate", "headerTemplate", "itemTemplate", "noDataTemplate", "prefixTemplate", "suffixTemplate"], never, true, [{ directive: typeof i1.DropdownDataHandlerDirective; inputs: {}; outputs: {}; }, { directive: typeof i1.DropdownListPopupHandlerDirective; inputs: {}; outputs: {}; }]>;
|
|
220
223
|
}
|
|
221
224
|
|
|
222
|
-
|
|
225
|
+
declare const AUTO_COMPLETE_DEFAULT_MESSAGES: MonaAutoCompleteMessages;
|
|
226
|
+
|
|
227
|
+
export { AUTO_COMPLETE_DEFAULT_MESSAGES, AutoCompleteComponent };
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import * as _nanahoshi_mona_ui_i18n from '@nanahoshi/mona-ui/i18n';
|
|
2
|
+
import { MonaBreadcrumbMessages } from '@nanahoshi/mona-ui/i18n';
|
|
1
3
|
import * as _angular_core from '@angular/core';
|
|
2
4
|
import { TemplateRef } from '@angular/core';
|
|
3
5
|
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
@@ -35,14 +37,16 @@ declare class BreadcrumbItemComponent {
|
|
|
35
37
|
}
|
|
36
38
|
|
|
37
39
|
declare class BreadcrumbComponent implements BreadcrumbVariantInput {
|
|
38
|
-
|
|
40
|
+
#private;
|
|
39
41
|
protected readonly currentItemClass: _angular_core.Signal<string>;
|
|
42
|
+
protected readonly itemComponents: _angular_core.Signal<readonly BreadcrumbItemComponent[]>;
|
|
40
43
|
protected readonly listClass: _angular_core.Signal<string>;
|
|
44
|
+
protected readonly messages: _angular_core.Signal<_nanahoshi_mona_ui_i18n.MonaBreadcrumbMessages>;
|
|
41
45
|
protected readonly separatorTemplate: _angular_core.Signal<TemplateRef<any> | undefined>;
|
|
42
46
|
/**
|
|
43
47
|
* @description Accessible name for the breadcrumb navigation landmark.
|
|
44
48
|
* Override when multiple breadcrumb components appear on the same page.
|
|
45
|
-
* @default "
|
|
49
|
+
* @default ""
|
|
46
50
|
*/
|
|
47
51
|
readonly ariaLabel: _angular_core.InputSignal<string>;
|
|
48
52
|
/**
|
|
@@ -65,4 +69,6 @@ declare class BreadcrumbSeparatorTemplateDirective {
|
|
|
65
69
|
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<BreadcrumbSeparatorTemplateDirective, "ng-template[monaBreadcrumbSeparatorTemplate]", never, {}, {}, never, never, true, never>;
|
|
66
70
|
}
|
|
67
71
|
|
|
68
|
-
|
|
72
|
+
declare const BREADCRUMB_DEFAULT_MESSAGES: MonaBreadcrumbMessages;
|
|
73
|
+
|
|
74
|
+
export { BREADCRUMB_DEFAULT_MESSAGES, BreadcrumbComponent, BreadcrumbItemComponent, BreadcrumbSeparatorTemplateDirective };
|