@nanahoshi/mona-ui 0.1.0 → 0.2.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/auto-complete/package.json +4 -0
- package/avatar/package.json +4 -0
- package/breadcrumb/package.json +4 -0
- package/button/package.json +4 -0
- package/button-group/package.json +4 -0
- package/calendar/package.json +4 -0
- package/check-box/package.json +4 -0
- package/chip/package.json +4 -0
- package/circular-progress-bar/package.json +4 -0
- package/color-gradient/package.json +4 -0
- package/color-palette/package.json +4 -0
- package/color-picker/package.json +4 -0
- package/combo-box/package.json +4 -0
- package/common/package.json +4 -0
- package/contextmenu/package.json +4 -0
- package/date-input/package.json +4 -0
- package/date-picker/package.json +4 -0
- package/datetime-picker/package.json +4 -0
- package/dialog/package.json +4 -0
- package/dropdown-button/package.json +4 -0
- package/dropdown-list/package.json +4 -0
- package/dropdowns/package.json +4 -0
- package/editor/package.json +4 -0
- package/expansion-panel/package.json +4 -0
- package/fesm2022/nanahoshi-mona-ui-auto-complete.mjs +40 -55
- package/fesm2022/nanahoshi-mona-ui-breadcrumb.mjs +24 -58
- package/fesm2022/nanahoshi-mona-ui-button-group.mjs +37 -48
- package/fesm2022/nanahoshi-mona-ui-button.mjs +130 -129
- package/fesm2022/nanahoshi-mona-ui-calendar.mjs +69 -165
- package/fesm2022/nanahoshi-mona-ui-check-box.mjs +81 -128
- package/fesm2022/nanahoshi-mona-ui-chip.mjs +102 -112
- package/fesm2022/nanahoshi-mona-ui-circular-progress-bar.mjs +11 -25
- package/fesm2022/nanahoshi-mona-ui-color-gradient.mjs +41 -92
- package/fesm2022/nanahoshi-mona-ui-color-palette.mjs +27 -49
- package/fesm2022/nanahoshi-mona-ui-color-picker.mjs +64 -65
- package/fesm2022/nanahoshi-mona-ui-combo-box.mjs +39 -61
- package/fesm2022/nanahoshi-mona-ui-date-input.mjs +12 -15
- package/fesm2022/nanahoshi-mona-ui-date-picker.mjs +44 -33
- package/fesm2022/nanahoshi-mona-ui-datetime-picker.mjs +58 -60
- package/fesm2022/nanahoshi-mona-ui-dialog.mjs +52 -165
- package/fesm2022/nanahoshi-mona-ui-dropdown-list.mjs +36 -59
- package/fesm2022/nanahoshi-mona-ui-dropdowns.mjs +56 -61
- package/fesm2022/nanahoshi-mona-ui-editor.mjs +302 -81
- package/fesm2022/nanahoshi-mona-ui-expansion-panel.mjs +33 -84
- package/fesm2022/nanahoshi-mona-ui-fieldset.mjs +12 -45
- package/fesm2022/nanahoshi-mona-ui-filter.mjs +18 -48
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-cell.component-B9SQH5N-.mjs → nanahoshi-mona-ui-grid-grid-footer-cell.component-B6FBLtrr.mjs} +14 -14
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-DlLwcCFT.mjs → nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-OJe4UYuw.mjs} +4 -8
- package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-DCd8K6ng.mjs +121 -0
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-toggle.component-DIUutx9s.mjs → nanahoshi-mona-ui-grid-grid-toggle.component-Dl8Hlkhj.mjs} +26 -55
- package/fesm2022/nanahoshi-mona-ui-grid-grid-virtual-list.component-C5FRZlvv.mjs +231 -0
- package/fesm2022/{nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-C3eZIaJK.mjs → nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-BRZUd8cE.mjs} +167 -451
- package/fesm2022/nanahoshi-mona-ui-grid.mjs +1 -1
- package/fesm2022/nanahoshi-mona-ui-internal-indicator-icon.mjs +10 -28
- package/fesm2022/nanahoshi-mona-ui-internal-list.mjs +57 -87
- package/fesm2022/nanahoshi-mona-ui-internal-tree.mjs +48 -139
- package/fesm2022/nanahoshi-mona-ui-internal.mjs +29 -1
- package/fesm2022/nanahoshi-mona-ui-list-box.mjs +10 -32
- package/fesm2022/nanahoshi-mona-ui-list-view.mjs +8 -21
- package/fesm2022/nanahoshi-mona-ui-menubar.mjs +50 -156
- package/fesm2022/nanahoshi-mona-ui-multi-select.mjs +40 -69
- package/fesm2022/nanahoshi-mona-ui-notification.mjs +32 -116
- package/fesm2022/nanahoshi-mona-ui-numeric-text-box.mjs +81 -107
- package/fesm2022/nanahoshi-mona-ui-pager.mjs +33 -85
- package/fesm2022/nanahoshi-mona-ui-placeholder.mjs +12 -34
- package/fesm2022/nanahoshi-mona-ui-popover.mjs +31 -52
- package/fesm2022/nanahoshi-mona-ui-popup-menu.mjs +38 -110
- package/fesm2022/nanahoshi-mona-ui-popup.mjs +4 -4
- package/fesm2022/nanahoshi-mona-ui-progress-bar.mjs +21 -62
- package/fesm2022/nanahoshi-mona-ui-radio-button.mjs +66 -111
- package/fesm2022/nanahoshi-mona-ui-scroll-view.mjs +60 -151
- package/fesm2022/nanahoshi-mona-ui-slider.mjs +117 -173
- package/fesm2022/nanahoshi-mona-ui-split-button.mjs +32 -45
- package/fesm2022/nanahoshi-mona-ui-splitter.mjs +29 -64
- package/fesm2022/nanahoshi-mona-ui-stepper.mjs +38 -101
- package/fesm2022/nanahoshi-mona-ui-switch.mjs +58 -79
- package/fesm2022/nanahoshi-mona-ui-tabs.mjs +42 -118
- package/fesm2022/nanahoshi-mona-ui-text-area.mjs +29 -37
- package/fesm2022/nanahoshi-mona-ui-text-box.mjs +60 -81
- package/fesm2022/nanahoshi-mona-ui-theme.mjs +1111 -269
- package/fesm2022/nanahoshi-mona-ui-time-picker.mjs +45 -39
- package/fesm2022/nanahoshi-mona-ui-time-selector.mjs +45 -109
- package/fesm2022/nanahoshi-mona-ui-tooltip.mjs +54 -82
- package/fesm2022/nanahoshi-mona-ui-tree-view.mjs +2 -2
- package/fesm2022/nanahoshi-mona-ui-window.mjs +35 -115
- package/fieldset/package.json +4 -0
- package/filter/package.json +4 -0
- package/grid/package.json +4 -0
- package/internal/filter-input/package.json +4 -0
- package/internal/indicator-icon/package.json +4 -0
- package/internal/list/package.json +4 -0
- package/internal/package.json +4 -0
- package/internal/tree/package.json +4 -0
- package/list/package.json +4 -0
- package/list-box/package.json +4 -0
- package/list-view/package.json +4 -0
- package/menubar/package.json +4 -0
- package/multi-select/package.json +4 -0
- package/notification/package.json +4 -0
- package/numeric-text-box/package.json +4 -0
- package/package.json +31 -5
- package/pager/package.json +4 -0
- package/placeholder/package.json +4 -0
- package/popover/package.json +4 -0
- package/popup/package.json +4 -0
- package/popup-menu/package.json +4 -0
- package/progress-bar/package.json +4 -0
- package/query/package.json +4 -0
- package/radio-button/package.json +4 -0
- package/scroll-view/package.json +4 -0
- package/slider/package.json +4 -0
- package/split-button/package.json +4 -0
- package/splitter/package.json +4 -0
- package/stepper/package.json +4 -0
- package/switch/package.json +4 -0
- package/tabs/package.json +4 -0
- package/text-area/package.json +4 -0
- package/text-box/package.json +4 -0
- package/theme/package.json +4 -0
- package/time-picker/package.json +4 -0
- package/time-selector/package.json +4 -0
- package/tooltip/package.json +4 -0
- package/tree-view/package.json +4 -0
- package/types/nanahoshi-mona-ui-auto-complete.d.ts +6 -7
- package/types/nanahoshi-mona-ui-breadcrumb.d.ts +4 -6
- package/types/nanahoshi-mona-ui-button-group.d.ts +2 -3
- package/types/nanahoshi-mona-ui-button.d.ts +6 -6
- package/types/nanahoshi-mona-ui-calendar.d.ts +21 -22
- package/types/nanahoshi-mona-ui-check-box.d.ts +6 -9
- package/types/nanahoshi-mona-ui-chip.d.ts +2 -3
- package/types/nanahoshi-mona-ui-circular-progress-bar.d.ts +2 -4
- package/types/nanahoshi-mona-ui-color-gradient.d.ts +10 -11
- package/types/nanahoshi-mona-ui-color-palette.d.ts +4 -5
- package/types/nanahoshi-mona-ui-color-picker.d.ts +6 -8
- package/types/nanahoshi-mona-ui-combo-box.d.ts +6 -7
- package/types/nanahoshi-mona-ui-date-input.d.ts +2 -3
- package/types/nanahoshi-mona-ui-date-picker.d.ts +2 -3
- package/types/nanahoshi-mona-ui-dialog.d.ts +7 -8
- package/types/nanahoshi-mona-ui-dropdown-list.d.ts +6 -7
- package/types/nanahoshi-mona-ui-dropdowns.d.ts +2 -3
- package/types/nanahoshi-mona-ui-editor.d.ts +17 -17
- package/types/nanahoshi-mona-ui-expansion-panel.d.ts +8 -10
- package/types/nanahoshi-mona-ui-fieldset.d.ts +6 -8
- package/types/nanahoshi-mona-ui-filter.d.ts +3 -4
- package/types/nanahoshi-mona-ui-grid.d.ts +16 -17
- package/types/nanahoshi-mona-ui-internal-indicator-icon.d.ts +0 -1
- package/types/nanahoshi-mona-ui-internal-tree.d.ts +16 -16
- package/types/nanahoshi-mona-ui-internal.d.ts +8 -1
- package/types/nanahoshi-mona-ui-list-box.d.ts +4 -5
- package/types/nanahoshi-mona-ui-list-view.d.ts +2 -3
- package/types/nanahoshi-mona-ui-menubar.d.ts +7 -8
- package/types/nanahoshi-mona-ui-multi-select.d.ts +8 -9
- package/types/nanahoshi-mona-ui-numeric-text-box.d.ts +2 -3
- package/types/nanahoshi-mona-ui-pager.d.ts +6 -7
- package/types/nanahoshi-mona-ui-placeholder.d.ts +4 -6
- package/types/nanahoshi-mona-ui-popover.d.ts +8 -9
- package/types/nanahoshi-mona-ui-popup-menu.d.ts +12 -13
- package/types/nanahoshi-mona-ui-progress-bar.d.ts +8 -9
- package/types/nanahoshi-mona-ui-radio-button.d.ts +8 -11
- package/types/nanahoshi-mona-ui-scroll-view.d.ts +18 -20
- package/types/nanahoshi-mona-ui-slider.d.ts +18 -18
- package/types/nanahoshi-mona-ui-split-button.d.ts +2 -3
- package/types/nanahoshi-mona-ui-splitter.d.ts +6 -8
- package/types/nanahoshi-mona-ui-stepper.d.ts +13 -14
- package/types/nanahoshi-mona-ui-switch.d.ts +6 -7
- package/types/nanahoshi-mona-ui-tabs.d.ts +15 -17
- package/types/nanahoshi-mona-ui-text-area.d.ts +2 -4
- package/types/nanahoshi-mona-ui-text-box.d.ts +4 -6
- package/types/nanahoshi-mona-ui-theme.d.ts +111 -12
- package/types/nanahoshi-mona-ui-time-picker.d.ts +2 -3
- package/types/nanahoshi-mona-ui-time-selector.d.ts +10 -11
- package/types/nanahoshi-mona-ui-tooltip.d.ts +4 -5
- package/types/nanahoshi-mona-ui-window.d.ts +16 -17
- package/window/package.json +4 -0
- package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-Dgea-O0X.mjs +0 -130
- package/fesm2022/nanahoshi-mona-ui-grid-grid-virtual-list.component-DRHycGIh.mjs +0 -240
|
@@ -2,14 +2,13 @@ import * as i0 from '@angular/core';
|
|
|
2
2
|
import { Directive, inject, DestroyRef, DOCUMENT, ElementRef, NgZone, input, afterNextRender, Pipe, ApplicationRef, Injector, signal, ViewContainerRef, computed, viewChild, TemplateRef, createComponent, Component, forwardRef, Injectable, contentChild, output, model, effect, untracked } from '@angular/core';
|
|
3
3
|
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
4
4
|
import { fromEvent, Subject, asapScheduler, map, take } from 'rxjs';
|
|
5
|
-
import { createElementControlId, focusElement, setWindowStyles } from '@nanahoshi/mona-ui/internal';
|
|
5
|
+
import { themeOverlaySurfaceClasses, createElementControlId, focusElement, setWindowStyles } from '@nanahoshi/mona-ui/internal';
|
|
6
6
|
import { PopupDataInjectionToken, PopupCloseEvent, PopupCloseSource, PopupService } from '@nanahoshi/mona-ui/popup';
|
|
7
7
|
import * as i1 from '@angular/cdk/a11y';
|
|
8
8
|
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 { ThemeService } from '@nanahoshi/mona-ui/theme';
|
|
13
12
|
import { cva } from 'class-variance-authority';
|
|
14
13
|
|
|
15
14
|
class WindowActionTemplateDirective {
|
|
@@ -432,10 +431,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
432
431
|
}]
|
|
433
432
|
}], 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 }] }] } });
|
|
434
433
|
|
|
435
|
-
const
|
|
436
|
-
flex flex-col
|
|
437
|
-
|
|
438
|
-
w-full h-full
|
|
434
|
+
const windowBaseThemeVariants = cva(`
|
|
435
|
+
flex h-full w-full flex-col
|
|
436
|
+
${themeOverlaySurfaceClasses} text-foreground
|
|
439
437
|
`, {
|
|
440
438
|
variants: {
|
|
441
439
|
rounded: {
|
|
@@ -449,11 +447,10 @@ const windowBaseVariants = cva(`
|
|
|
449
447
|
rounded: "medium"
|
|
450
448
|
}
|
|
451
449
|
});
|
|
452
|
-
const
|
|
453
|
-
flex flex-col
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
shadow-sm
|
|
450
|
+
const windowContentContainerThemeVariants = cva(`
|
|
451
|
+
relative flex h-full w-full flex-col
|
|
452
|
+
border border-border
|
|
453
|
+
shadow-(--shadow-overlay)
|
|
457
454
|
`, {
|
|
458
455
|
variants: {
|
|
459
456
|
rounded: {
|
|
@@ -464,11 +461,12 @@ const windowContentContainerVariants = cva(`
|
|
|
464
461
|
}
|
|
465
462
|
}
|
|
466
463
|
});
|
|
467
|
-
const
|
|
468
|
-
flex-1 overflow-auto
|
|
464
|
+
const windowContentThemeVariants = cva(`
|
|
465
|
+
flex-1 overflow-auto
|
|
466
|
+
[scrollbar-color:var(--color-scrollbar-thumb)_var(--color-scrollbar-track)] [scrollbar-width:thin]
|
|
469
467
|
`);
|
|
470
|
-
const
|
|
471
|
-
absolute flex
|
|
468
|
+
const windowResizerThemeVariants = cva(`
|
|
469
|
+
absolute flex
|
|
472
470
|
`, {
|
|
473
471
|
variants: {
|
|
474
472
|
position: {
|
|
@@ -483,17 +481,17 @@ const windowResizerVariants = cva(`
|
|
|
483
481
|
}
|
|
484
482
|
}
|
|
485
483
|
});
|
|
486
|
-
const
|
|
487
|
-
flex items-center
|
|
484
|
+
const windowTitleBarActionThemeVariants = cva(`
|
|
485
|
+
flex items-center justify-evenly
|
|
488
486
|
`);
|
|
489
|
-
const
|
|
490
|
-
flex items-center justify-start
|
|
491
|
-
px-2 py-1 text-sm
|
|
492
|
-
border-b border-border
|
|
487
|
+
const windowTitleBarThemeVariants = cva(`
|
|
488
|
+
flex items-center justify-start
|
|
489
|
+
overflow-hidden px-2 py-1 text-sm
|
|
490
|
+
border-b border-border-subtle
|
|
493
491
|
`, {
|
|
494
492
|
variants: {
|
|
495
493
|
look: {
|
|
496
|
-
default: "bg-
|
|
494
|
+
default: "bg-surface-muted text-foreground",
|
|
497
495
|
primary: "bg-primary text-primary-foreground"
|
|
498
496
|
},
|
|
499
497
|
rounded: {
|
|
@@ -504,14 +502,12 @@ const windowTitleBarVariants = cva(`
|
|
|
504
502
|
}
|
|
505
503
|
}
|
|
506
504
|
});
|
|
507
|
-
const
|
|
508
|
-
flex items-center
|
|
509
|
-
|
|
510
|
-
overflow-hidden text-ellipsis
|
|
505
|
+
const windowTitleContainerThemeVariants = cva(`
|
|
506
|
+
flex h-full flex-1 items-center overflow-hidden
|
|
507
|
+
cursor-default select-none text-ellipsis
|
|
511
508
|
`);
|
|
512
|
-
const
|
|
513
|
-
font-semibold
|
|
514
|
-
overflow-hidden text-ellipsis whitespace-nowrap
|
|
509
|
+
const windowTitleThemeVariants = cva(`
|
|
510
|
+
overflow-hidden text-ellipsis whitespace-nowrap font-semibold
|
|
515
511
|
`, {
|
|
516
512
|
variants: {
|
|
517
513
|
look: {
|
|
@@ -521,79 +517,12 @@ const windowTitleVariants = cva(`
|
|
|
521
517
|
}
|
|
522
518
|
});
|
|
523
519
|
|
|
524
|
-
const windowBaseThemeVariants = (theme) => {
|
|
525
|
-
switch (theme) {
|
|
526
|
-
case "mona":
|
|
527
|
-
return windowBaseVariants;
|
|
528
|
-
default:
|
|
529
|
-
return windowBaseVariants;
|
|
530
|
-
}
|
|
531
|
-
};
|
|
532
|
-
const windowContentContainerThemeVariants = (theme) => {
|
|
533
|
-
switch (theme) {
|
|
534
|
-
case "mona":
|
|
535
|
-
return windowContentContainerVariants;
|
|
536
|
-
default:
|
|
537
|
-
return windowContentContainerVariants;
|
|
538
|
-
}
|
|
539
|
-
};
|
|
540
|
-
const windowContentThemeVariants = (theme) => {
|
|
541
|
-
switch (theme) {
|
|
542
|
-
case "mona":
|
|
543
|
-
return windowContentVariants;
|
|
544
|
-
default:
|
|
545
|
-
return windowContentVariants;
|
|
546
|
-
}
|
|
547
|
-
};
|
|
548
|
-
const windowResizerThemeVariants = (theme) => {
|
|
549
|
-
switch (theme) {
|
|
550
|
-
case "mona":
|
|
551
|
-
return windowResizerVariants;
|
|
552
|
-
default:
|
|
553
|
-
return windowResizerVariants;
|
|
554
|
-
}
|
|
555
|
-
};
|
|
556
|
-
const windowTitleBarActionThemeVariants = (theme) => {
|
|
557
|
-
switch (theme) {
|
|
558
|
-
case "mona":
|
|
559
|
-
return windowTitleBarActionVariants;
|
|
560
|
-
default:
|
|
561
|
-
return windowTitleBarActionVariants;
|
|
562
|
-
}
|
|
563
|
-
};
|
|
564
|
-
const windowTitleBarThemeVariants = (theme) => {
|
|
565
|
-
switch (theme) {
|
|
566
|
-
case "mona":
|
|
567
|
-
return windowTitleBarVariants;
|
|
568
|
-
default:
|
|
569
|
-
return windowTitleBarVariants;
|
|
570
|
-
}
|
|
571
|
-
};
|
|
572
|
-
const windowTitleContainerThemeVariants = (theme) => {
|
|
573
|
-
switch (theme) {
|
|
574
|
-
case "mona":
|
|
575
|
-
return windowTitleContainerVariants;
|
|
576
|
-
default:
|
|
577
|
-
return windowTitleContainerVariants;
|
|
578
|
-
}
|
|
579
|
-
};
|
|
580
|
-
const windowTitleThemeVariants = (theme) => {
|
|
581
|
-
switch (theme) {
|
|
582
|
-
case "mona":
|
|
583
|
-
return windowTitleVariants;
|
|
584
|
-
default:
|
|
585
|
-
return windowTitleVariants;
|
|
586
|
-
}
|
|
587
|
-
};
|
|
588
|
-
|
|
589
520
|
class ResizePositionPipe {
|
|
590
|
-
#themeService = inject(ThemeService);
|
|
591
521
|
transform(position) {
|
|
592
522
|
if (!position) {
|
|
593
523
|
return null;
|
|
594
524
|
}
|
|
595
|
-
|
|
596
|
-
return windowResizerThemeVariants(theme)({ position });
|
|
525
|
+
return windowResizerThemeVariants({ position });
|
|
597
526
|
}
|
|
598
527
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: ResizePositionPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
599
528
|
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "22.0.6", ngImport: i0, type: ResizePositionPipe, isStandalone: true, name: "monaResizePosition" }); }
|
|
@@ -612,7 +541,6 @@ class WindowContentComponent {
|
|
|
612
541
|
#injector;
|
|
613
542
|
#sizeBeforeMaximize;
|
|
614
543
|
#sizeBeforeMinimize;
|
|
615
|
-
#themeService;
|
|
616
544
|
#trapFocus;
|
|
617
545
|
#viewContainerRef;
|
|
618
546
|
constructor() {
|
|
@@ -624,25 +552,21 @@ class WindowContentComponent {
|
|
|
624
552
|
...(ngDevMode ? [{ debugName: "#sizeBeforeMaximize" }] : /* istanbul ignore next */ []));
|
|
625
553
|
this.#sizeBeforeMinimize = signal(0, /* @ts-ignore */
|
|
626
554
|
...(ngDevMode ? [{ debugName: "#sizeBeforeMinimize" }] : /* istanbul ignore next */ []));
|
|
627
|
-
this.#themeService = inject(ThemeService);
|
|
628
555
|
this.#trapFocus = inject(CdkTrapFocus);
|
|
629
556
|
this.#viewContainerRef = inject(ViewContainerRef);
|
|
630
557
|
this.baseClass = computed(() => {
|
|
631
|
-
const theme = this.#themeService.theme();
|
|
632
558
|
const rounded = this.windowData.rounded;
|
|
633
|
-
return windowBaseThemeVariants(
|
|
559
|
+
return windowBaseThemeVariants({ rounded });
|
|
634
560
|
}, /* @ts-ignore */
|
|
635
561
|
...(ngDevMode ? [{ debugName: "baseClass" }] : /* istanbul ignore next */ []));
|
|
636
562
|
this.componentAnchor = viewChild.required("componentAnchor", { ...(ngDevMode ? { debugName: "componentAnchor" } : /* istanbul ignore next */ {}), read: ViewContainerRef });
|
|
637
563
|
this.contentClass = computed(() => {
|
|
638
|
-
|
|
639
|
-
return windowContentThemeVariants(theme)();
|
|
564
|
+
return windowContentThemeVariants();
|
|
640
565
|
}, /* @ts-ignore */
|
|
641
566
|
...(ngDevMode ? [{ debugName: "contentClass" }] : /* istanbul ignore next */ []));
|
|
642
567
|
this.contentContainerClass = computed(() => {
|
|
643
|
-
const theme = this.#themeService.theme();
|
|
644
568
|
const rounded = this.windowData.rounded;
|
|
645
|
-
return windowContentContainerThemeVariants(
|
|
569
|
+
return windowContentContainerThemeVariants({ rounded });
|
|
646
570
|
}, /* @ts-ignore */
|
|
647
571
|
...(ngDevMode ? [{ debugName: "contentContainerClass" }] : /* istanbul ignore next */ []));
|
|
648
572
|
this.contentTemplate = computed(() => {
|
|
@@ -662,26 +586,22 @@ class WindowContentComponent {
|
|
|
662
586
|
this.minimized = signal(false, /* @ts-ignore */
|
|
663
587
|
...(ngDevMode ? [{ debugName: "minimized" }] : /* istanbul ignore next */ []));
|
|
664
588
|
this.titleBarActionClass = computed(() => {
|
|
665
|
-
|
|
666
|
-
return windowTitleBarActionThemeVariants(theme)();
|
|
589
|
+
return windowTitleBarActionThemeVariants();
|
|
667
590
|
}, /* @ts-ignore */
|
|
668
591
|
...(ngDevMode ? [{ debugName: "titleBarActionClass" }] : /* istanbul ignore next */ []));
|
|
669
592
|
this.titleBarClass = computed(() => {
|
|
670
|
-
const theme = this.#themeService.theme();
|
|
671
593
|
const look = this.windowData.look;
|
|
672
594
|
const rounded = this.windowData.rounded;
|
|
673
|
-
return windowTitleBarThemeVariants(
|
|
595
|
+
return windowTitleBarThemeVariants({ look, rounded });
|
|
674
596
|
}, /* @ts-ignore */
|
|
675
597
|
...(ngDevMode ? [{ debugName: "titleBarClass" }] : /* istanbul ignore next */ []));
|
|
676
598
|
this.titleClass = computed(() => {
|
|
677
|
-
const theme = this.#themeService.theme();
|
|
678
599
|
const look = this.windowData.look;
|
|
679
|
-
return windowTitleThemeVariants(
|
|
600
|
+
return windowTitleThemeVariants({ look });
|
|
680
601
|
}, /* @ts-ignore */
|
|
681
602
|
...(ngDevMode ? [{ debugName: "titleClass" }] : /* istanbul ignore next */ []));
|
|
682
603
|
this.titleContainerClass = computed(() => {
|
|
683
|
-
|
|
684
|
-
return windowTitleContainerThemeVariants(theme)();
|
|
604
|
+
return windowTitleContainerThemeVariants();
|
|
685
605
|
}, /* @ts-ignore */
|
|
686
606
|
...(ngDevMode ? [{ debugName: "titleContainerClass" }] : /* istanbul ignore next */ []));
|
|
687
607
|
this.windowData = inject(PopupDataInjectionToken);
|
|
@@ -789,7 +709,7 @@ class WindowContentComponent {
|
|
|
789
709
|
}
|
|
790
710
|
}
|
|
791
711
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: WindowContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
792
|
-
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()\">\r\n <div\r\n [class]=\"titleBarClass()\"\r\n monaWindowDragHandler\r\n (dblclick)=\"onMaximizeClick()\"\r\n [draggable]=\"windowData.draggable\"\r\n [windowRef]=\"windowData.windowReference\"\r\n [attr.tabindex]=\"windowData.draggable ? 0 : null\"\r\n [attr.aria-label]=\"windowData.draggable ? 'Move window. Use arrow keys to move.' : null\">\r\n <div [id]=\"headerId\" [class]=\"titleContainerClass()\">\r\n @if (windowData.titleTemplate) {\r\n <ng-container [ngTemplateOutlet]=\"windowData.titleTemplate\"></ng-container>\r\n } @else {\r\n <span [class]=\"titleClass()\">{{ windowData.title ?? \"\" }}</span>\r\n }\r\n </div>\r\n <div [class]=\"titleBarActionClass()\">\r\n @if (windowData.actionTemplate) {\r\n <ng-container\r\n [ngTemplateOutlet]=\"windowData.actionTemplate\"\r\n [ngTemplateOutletContext]=\"{ $implicit: windowData.windowReference.windowRef }\">\r\n </ng-container>\r\n }\r\n @let maximizeTitle = maximized() || minimized() ? \"Restore\" : \"Maximize\";\r\n @if (windowData.minimizable && !minimized()) {\r\n <button\r\n monaButton\r\n look=\"ghost\"\r\n size=\"small\"\r\n type=\"button\"\r\n [iconOnly]=\"true\"\r\n [rounded]=\"windowData.rounded\"\r\n [title]=\"'Minimize'\"\r\n aria-label=\"Minimize\"\r\n (dblclick)=\"$event.stopPropagation()\"\r\n (click)=\"onMinimizeClick()\">\r\n <svg lucideMinus [size]=\"16\" aria-hidden=\"true\"></svg>\r\n </button>\r\n }\r\n @if (windowData.maximizable) {\r\n <button\r\n monaButton\r\n look=\"ghost\"\r\n size=\"small\"\r\n type=\"button\"\r\n [iconOnly]=\"true\"\r\n [rounded]=\"windowData.rounded\"\r\n [title]=\"maximizeTitle\"\r\n [attr.aria-label]=\"maximizeTitle\"\r\n (dblclick)=\"$event.stopPropagation()\"\r\n (click)=\"onMaximizeClick()\">\r\n <svg [lucideIcon]=\"maximizeIcon()\" [size]=\"16\" aria-hidden=\"true\"></svg>\r\n </button>\r\n }\r\n @if (windowData.closable) {\r\n <button\r\n monaButton\r\n look=\"ghost\"\r\n size=\"small\"\r\n type=\"button\"\r\n [iconOnly]=\"true\"\r\n [rounded]=\"windowData.rounded\"\r\n title=\"Close\"\r\n aria-label=\"Close window\"\r\n (dblclick)=\"$event.stopPropagation()\"\r\n (click)=\"onCloseClick($event)\">\r\n <svg lucideX [size]=\"16\" aria-hidden=\"true\"></svg>\r\n </button>\r\n }\r\n </div>\r\n </div>\r\n @if (!minimized()) {\r\n <div [class]=\"contentClass()\">\r\n @switch (contentType()) {\r\n @case (\"template\") {\r\n <ng-container [ngTemplateOutlet]=\"contentTemplate()!\"></ng-container>\r\n }\r\n @case (\"component\") {\r\n <ng-container #componentAnchor></ng-container>\r\n }\r\n }\r\n </div>\r\n @if (windowData.footerTemplate) {\r\n <div>\r\n <ng-container [ngTemplateOutlet]=\"windowData.footerTemplate\"></ng-container>\r\n </div>\r\n }\r\n }\r\n @if (windowData.resizable && !maximized()) {\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"north\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the top. Use arrow keys to resize.\"\r\n [class]=\"'north' | monaResizePosition\"></div>\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"south\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the bottom. Use arrow keys to resize.\"\r\n [class]=\"'south' | monaResizePosition\"></div>\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"east\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the right. Use arrow keys to resize.\"\r\n [class]=\"'east' | monaResizePosition\"></div>\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"west\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the left. Use arrow keys to resize.\"\r\n [class]=\"'west' | monaResizePosition\"></div>\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"northeast\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the top-right corner. Use arrow keys to resize.\"\r\n [class]=\"'northeast' | monaResizePosition\"></div>\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"northwest\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the top-left corner. Use arrow keys to resize.\"\r\n [class]=\"'northwest' | monaResizePosition\"></div>\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"southeast\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the bottom-right corner. Use arrow keys to resize.\"\r\n [class]=\"'southeast' | monaResizePosition\"></div>\r\n <div\r\n monaWindowResizeHandler\r\n [minWidth]=\"windowData.minWidth\"\r\n [minHeight]=\"windowData.minHeight\"\r\n [maxWidth]=\"windowData.maxWidth\"\r\n [maxHeight]=\"windowData.maxHeight\"\r\n [windowRef]=\"windowData.windowReference\"\r\n direction=\"southwest\"\r\n tabindex=\"0\"\r\n aria-label=\"Resize window from the bottom-left corner. Use arrow keys to resize.\"\r\n [class]=\"'southwest' | monaResizePosition\"></div>\r\n }\r\n</div>\r\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", "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" }] }); }
|
|
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 ? 'Move window. Use arrow keys to move.' : 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() ? \"Restore\" : \"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]=\"'Minimize'\"\n aria-label=\"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=\"Close\"\n aria-label=\"Close window\"\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 aria-label=\"Resize window from the top. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the bottom. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the right. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the left. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the top-right corner. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the top-left corner. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the bottom-right corner. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the bottom-left corner. Use arrow keys to resize.\"\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", "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" }] }); }
|
|
793
713
|
}
|
|
794
714
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: WindowContentComponent, decorators: [{
|
|
795
715
|
type: Component,
|
|
@@ -807,7 +727,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
807
727
|
"[attr.aria-labelledby]": "headerId",
|
|
808
728
|
"[attr.aria-modal]": "windowData.modal ?? false",
|
|
809
729
|
role: "dialog"
|
|
810
|
-
}, hostDirectives: [CdkTrapFocus], template: "<div [class]=\"contentContainerClass()\">\
|
|
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 ? 'Move window. Use arrow keys to move.' : 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() ? \"Restore\" : \"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]=\"'Minimize'\"\n aria-label=\"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=\"Close\"\n aria-label=\"Close window\"\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 aria-label=\"Resize window from the top. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the bottom. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the right. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the left. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the top-right corner. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the top-left corner. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the bottom-right corner. Use arrow keys to resize.\"\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 aria-label=\"Resize window from the bottom-left corner. Use arrow keys to resize.\"\n [class]=\"'southwest' | monaResizePosition\"></div>\n }\n</div>\n" }]
|
|
811
731
|
}], ctorParameters: () => [], propDecorators: { componentAnchor: [{ type: i0.ViewChild, args: ["componentAnchor", { ...{
|
|
812
732
|
read: ViewContainerRef
|
|
813
733
|
}, isSignal: true }] }] } });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nanahoshi/mona-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "A very light Angular UI framework",
|
|
5
5
|
"author": "Nanahoshi",
|
|
6
6
|
"repository": {
|
|
@@ -19,7 +19,6 @@
|
|
|
19
19
|
"@angular/platform-browser": ">=22.0.0 <24.0.0",
|
|
20
20
|
"@angular/platform-browser-dynamic": ">=22.0.0 <24.0.0",
|
|
21
21
|
"@angular/router": ">=22.0.0 <24.0.0",
|
|
22
|
-
"@fortawesome/angular-fontawesome": "^5.0.0",
|
|
23
22
|
"@tiptap/core": "^3.26.1",
|
|
24
23
|
"@tiptap/extension-color": "^3.26.1",
|
|
25
24
|
"@tiptap/extension-font-family": "^3.26.1",
|
|
@@ -42,11 +41,10 @@
|
|
|
42
41
|
"rxjs": "^7.8.2"
|
|
43
42
|
},
|
|
44
43
|
"dependencies": {
|
|
45
|
-
"@fortawesome/fontawesome-svg-core": "^7.2.0",
|
|
46
|
-
"@fortawesome/free-solid-svg-icons": "^7.2.0",
|
|
47
44
|
"@lucide/angular": "^1.21.0",
|
|
48
45
|
"@mirei/ts-collections": "^17.5.6",
|
|
49
46
|
"class-variance-authority": "^0.7.1",
|
|
47
|
+
"culori": "^4.0.2",
|
|
50
48
|
"luxon": "^3.7.2",
|
|
51
49
|
"remixicon": "^4.9.1",
|
|
52
50
|
"tailwind-merge": "^3.6.0",
|
|
@@ -123,6 +121,10 @@
|
|
|
123
121
|
"types": "./types/nanahoshi-mona-ui-contextmenu.d.ts",
|
|
124
122
|
"default": "./fesm2022/nanahoshi-mona-ui-contextmenu.mjs"
|
|
125
123
|
},
|
|
124
|
+
"./date-input": {
|
|
125
|
+
"types": "./types/nanahoshi-mona-ui-date-input.d.ts",
|
|
126
|
+
"default": "./fesm2022/nanahoshi-mona-ui-date-input.mjs"
|
|
127
|
+
},
|
|
126
128
|
"./date-picker": {
|
|
127
129
|
"types": "./types/nanahoshi-mona-ui-date-picker.d.ts",
|
|
128
130
|
"default": "./fesm2022/nanahoshi-mona-ui-date-picker.mjs"
|
|
@@ -167,6 +169,26 @@
|
|
|
167
169
|
"types": "./types/nanahoshi-mona-ui-grid.d.ts",
|
|
168
170
|
"default": "./fesm2022/nanahoshi-mona-ui-grid.mjs"
|
|
169
171
|
},
|
|
172
|
+
"./internal": {
|
|
173
|
+
"types": "./types/nanahoshi-mona-ui-internal.d.ts",
|
|
174
|
+
"default": "./fesm2022/nanahoshi-mona-ui-internal.mjs"
|
|
175
|
+
},
|
|
176
|
+
"./internal/filter-input": {
|
|
177
|
+
"types": "./types/nanahoshi-mona-ui-internal-filter-input.d.ts",
|
|
178
|
+
"default": "./fesm2022/nanahoshi-mona-ui-internal-filter-input.mjs"
|
|
179
|
+
},
|
|
180
|
+
"./internal/indicator-icon": {
|
|
181
|
+
"types": "./types/nanahoshi-mona-ui-internal-indicator-icon.d.ts",
|
|
182
|
+
"default": "./fesm2022/nanahoshi-mona-ui-internal-indicator-icon.mjs"
|
|
183
|
+
},
|
|
184
|
+
"./internal/list": {
|
|
185
|
+
"types": "./types/nanahoshi-mona-ui-internal-list.d.ts",
|
|
186
|
+
"default": "./fesm2022/nanahoshi-mona-ui-internal-list.mjs"
|
|
187
|
+
},
|
|
188
|
+
"./internal/tree": {
|
|
189
|
+
"types": "./types/nanahoshi-mona-ui-internal-tree.d.ts",
|
|
190
|
+
"default": "./fesm2022/nanahoshi-mona-ui-internal-tree.mjs"
|
|
191
|
+
},
|
|
170
192
|
"./list": {
|
|
171
193
|
"types": "./types/nanahoshi-mona-ui-list.d.ts",
|
|
172
194
|
"default": "./fesm2022/nanahoshi-mona-ui-list.mjs"
|
|
@@ -219,6 +241,10 @@
|
|
|
219
241
|
"types": "./types/nanahoshi-mona-ui-progress-bar.d.ts",
|
|
220
242
|
"default": "./fesm2022/nanahoshi-mona-ui-progress-bar.mjs"
|
|
221
243
|
},
|
|
244
|
+
"./query": {
|
|
245
|
+
"types": "./types/nanahoshi-mona-ui-query.d.ts",
|
|
246
|
+
"default": "./fesm2022/nanahoshi-mona-ui-query.mjs"
|
|
247
|
+
},
|
|
222
248
|
"./radio-button": {
|
|
223
249
|
"types": "./types/nanahoshi-mona-ui-radio-button.d.ts",
|
|
224
250
|
"default": "./fesm2022/nanahoshi-mona-ui-radio-button.mjs"
|
|
@@ -286,4 +312,4 @@
|
|
|
286
312
|
},
|
|
287
313
|
"sideEffects": false,
|
|
288
314
|
"type": "module"
|
|
289
|
-
}
|
|
315
|
+
}
|