@cute-widgets/base 20.0.3 → 20.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/CHANGELOG.md +31 -4
  2. package/abstract/index.d.ts +13 -4
  3. package/button/index.d.ts +47 -24
  4. package/button-toggle/index.d.ts +8 -4
  5. package/card/index.d.ts +9 -6
  6. package/collapse/index.d.ts +49 -48
  7. package/core/directives/index.d.ts +1 -31
  8. package/core/index.d.ts +41 -28
  9. package/core/interfaces/index.d.ts +1 -1
  10. package/core/layout/index.d.ts +40 -27
  11. package/core/nav/index.d.ts +1 -2
  12. package/dialog/index.d.ts +81 -57
  13. package/expansion/index.d.ts +5 -18
  14. package/fesm2022/cute-widgets-base-abstract.mjs +13 -8
  15. package/fesm2022/cute-widgets-base-abstract.mjs.map +1 -1
  16. package/fesm2022/cute-widgets-base-button-toggle.mjs +36 -29
  17. package/fesm2022/cute-widgets-base-button-toggle.mjs.map +1 -1
  18. package/fesm2022/cute-widgets-base-button.mjs +169 -104
  19. package/fesm2022/cute-widgets-base-button.mjs.map +1 -1
  20. package/fesm2022/cute-widgets-base-card.mjs +46 -29
  21. package/fesm2022/cute-widgets-base-card.mjs.map +1 -1
  22. package/fesm2022/cute-widgets-base-chips.mjs +6 -18
  23. package/fesm2022/cute-widgets-base-chips.mjs.map +1 -1
  24. package/fesm2022/cute-widgets-base-collapse.mjs +114 -126
  25. package/fesm2022/cute-widgets-base-collapse.mjs.map +1 -1
  26. package/fesm2022/cute-widgets-base-core-directives.mjs +4 -72
  27. package/fesm2022/cute-widgets-base-core-directives.mjs.map +1 -1
  28. package/fesm2022/cute-widgets-base-core-interfaces.mjs.map +1 -1
  29. package/fesm2022/cute-widgets-base-core-layout.mjs +76 -40
  30. package/fesm2022/cute-widgets-base-core-layout.mjs.map +1 -1
  31. package/fesm2022/cute-widgets-base-core-nav.mjs +1 -2
  32. package/fesm2022/cute-widgets-base-core-nav.mjs.map +1 -1
  33. package/fesm2022/cute-widgets-base-core-theming.mjs +1 -1
  34. package/fesm2022/cute-widgets-base-core-theming.mjs.map +1 -1
  35. package/fesm2022/cute-widgets-base-core.mjs +77 -41
  36. package/fesm2022/cute-widgets-base-core.mjs.map +1 -1
  37. package/fesm2022/cute-widgets-base-dialog.mjs +152 -117
  38. package/fesm2022/cute-widgets-base-dialog.mjs.map +1 -1
  39. package/fesm2022/cute-widgets-base-expansion.mjs +19 -13
  40. package/fesm2022/cute-widgets-base-expansion.mjs.map +1 -1
  41. package/fesm2022/cute-widgets-base-list.mjs +2 -2
  42. package/fesm2022/cute-widgets-base-list.mjs.map +1 -1
  43. package/fesm2022/cute-widgets-base-menu.mjs +5 -27
  44. package/fesm2022/cute-widgets-base-menu.mjs.map +1 -1
  45. package/fesm2022/cute-widgets-base-navbar.mjs +88 -42
  46. package/fesm2022/cute-widgets-base-navbar.mjs.map +1 -1
  47. package/fesm2022/cute-widgets-base-paginator.mjs +13 -11
  48. package/fesm2022/cute-widgets-base-paginator.mjs.map +1 -1
  49. package/fesm2022/cute-widgets-base-radio.mjs +1 -2
  50. package/fesm2022/cute-widgets-base-radio.mjs.map +1 -1
  51. package/fesm2022/cute-widgets-base-select.mjs +2 -2
  52. package/fesm2022/cute-widgets-base-select.mjs.map +1 -1
  53. package/fesm2022/cute-widgets-base-sidenav.mjs +31 -30
  54. package/fesm2022/cute-widgets-base-sidenav.mjs.map +1 -1
  55. package/fesm2022/cute-widgets-base-snack-bar.mjs +2 -2
  56. package/fesm2022/cute-widgets-base-snack-bar.mjs.map +1 -1
  57. package/fesm2022/cute-widgets-base-sort.mjs +60 -257
  58. package/fesm2022/cute-widgets-base-sort.mjs.map +1 -1
  59. package/fesm2022/cute-widgets-base-table.mjs +6 -3
  60. package/fesm2022/cute-widgets-base-table.mjs.map +1 -1
  61. package/fesm2022/cute-widgets-base-tabs.mjs +86 -61
  62. package/fesm2022/cute-widgets-base-tabs.mjs.map +1 -1
  63. package/fesm2022/cute-widgets-base.mjs +3 -1
  64. package/fesm2022/cute-widgets-base.mjs.map +1 -1
  65. package/navbar/index.d.ts +30 -9
  66. package/package.json +6 -5
  67. package/paginator/index.d.ts +6 -17
  68. package/radio/index.d.ts +0 -1
  69. package/sidenav/index.d.ts +1 -2
  70. package/sort/index.d.ts +22 -135
  71. package/table/index.d.ts +8 -8
  72. package/tabs/index.d.ts +35 -14
@@ -1,8 +1,9 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Directive, Input, ChangeDetectionStrategy, ViewEncapsulation, Component, EventEmitter, inject, InjectionToken, Injectable, Optional, booleanAttribute, HostListener, ViewChild, NgModule } from '@angular/core';
2
+ import { ChangeDetectionStrategy, ViewEncapsulation, Component, EventEmitter, inject, InjectionToken, Injectable, ElementRef, Input, Directive, booleanAttribute, HostListener, ViewChild, NgModule } from '@angular/core';
3
3
  import { CuteButton } from '@cute-widgets/base/button';
4
- import { CdkDrag } from '@angular/cdk/drag-drop';
5
- import { Subject, merge, defer } from 'rxjs';
4
+ import { CdkDrag, CdkDragHandle } from '@angular/cdk/drag-drop';
5
+ import { _IdGenerator } from '@angular/cdk/a11y';
6
+ import { ReplaySubject, merge, Subject, defer } from 'rxjs';
6
7
  import { filter, take, startWith } from 'rxjs/operators';
7
8
  import { ESCAPE, hasModifierKey } from '@angular/cdk/keycodes';
8
9
  import { OverlayRef, Overlay } from '@angular/cdk/overlay';
@@ -16,68 +17,6 @@ import { BreakpointObserver } from '@angular/cdk/layout';
16
17
  import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
17
18
  import { CommonModule } from '@angular/common';
18
19
 
19
- /**
20
- * @license Apache-2.0
21
- *
22
- * Copyright (c) 2025 CuteWidgets Team. All Rights Reserved.
23
- *
24
- * You may not use this file except in compliance with the License
25
- * that can be found at http://www.apache.org/licenses/LICENSE-2.0
26
- */
27
- class CuteDialogBody {
28
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogBody, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
29
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogBody, isStandalone: true, selector: "cute-dialog-body, [cute-dialog-body], [cuteDialogBody],\n cute-dialog-content, [cute-dialog-content], [cuteDialogContent]\n ", host: { classAttribute: "cute-dialog-body modal-body" }, exportAs: ["cuteDialogBody"], ngImport: i0 }); }
30
- }
31
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogBody, decorators: [{
32
- type: Directive,
33
- args: [{
34
- selector: `cute-dialog-body, [cute-dialog-body], [cuteDialogBody],
35
- cute-dialog-content, [cute-dialog-content], [cuteDialogContent]
36
- `,
37
- exportAs: 'cuteDialogBody',
38
- host: {
39
- 'class': 'cute-dialog-body modal-body'
40
- },
41
- standalone: true,
42
- }]
43
- }] });
44
-
45
- /**
46
- * @license Apache-2.0
47
- *
48
- * Copyright (c) 2025 CuteWidgets Team. All Rights Reserved.
49
- *
50
- * You may not use this file except in compliance with the License
51
- * that can be found at http://www.apache.org/licenses/LICENSE-2.0
52
- *
53
- * This code is a modification of the `@angular/material` original
54
- * code licensed under MIT-style License (https://angular.dev/license).
55
- */
56
- class CuteDialogFooter {
57
- constructor() {
58
- /** Horizontal alignment of the footer's content */
59
- this.align = 'start';
60
- }
61
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogFooter, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
62
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogFooter, isStandalone: true, selector: "cute-dialog-footer, [cute-dialog-footer], [cuteDialogFooter],\n cute-dialog-actions, [cute-dialog-actions], [cuteDialogActions]\n ", inputs: { align: "align" }, host: { properties: { "style.justify-content": "align" }, classAttribute: "cute-dialog-footer cute-dialog-actions modal-footer" }, exportAs: ["cuteDialogFooter", "cuteDialogActions"], ngImport: i0 }); }
63
- }
64
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogFooter, decorators: [{
65
- type: Directive,
66
- args: [{
67
- selector: `cute-dialog-footer, [cute-dialog-footer], [cuteDialogFooter],
68
- cute-dialog-actions, [cute-dialog-actions], [cuteDialogActions]
69
- `,
70
- exportAs: 'cuteDialogFooter, cuteDialogActions',
71
- host: {
72
- 'class': 'cute-dialog-footer cute-dialog-actions modal-footer',
73
- '[style.justify-content]': 'align',
74
- },
75
- standalone: true,
76
- }]
77
- }], propDecorators: { align: [{
78
- type: Input
79
- }] } });
80
-
81
20
  /**
82
21
  * @license Apache-2.0
83
22
  *
@@ -109,9 +48,9 @@ class CuteDialogRef {
109
48
  */
110
49
  this.componentRef = null;
111
50
  /** Subject for notifying the user that the dialog has finished opening. */
112
- this._afterOpened = new Subject();
51
+ this._afterOpened = new ReplaySubject(1);
113
52
  /** Subject for notifying the user that the dialog has started closing. */
114
- this._beforeClosed = new Subject();
53
+ this._beforeClosed = new ReplaySubject(1);
115
54
  /** Current state of the dialog. */
116
55
  this._state = CuteDialogState.OPEN;
117
56
  this.disableClose = _config.disableClose;
@@ -289,10 +228,10 @@ class CuteDialogConfig {
289
228
  this.width = '';
290
229
  /** Height of the dialog. */
291
230
  this.height = '';
292
- /** Max-width of the dialog. If a number is provided, assumes pixel units. Defaults to 80vw. */
293
- this.maxWidth = '80vw';
231
+ /** Max-width of the dialog. If a number is provided, assumes pixel units. */
232
+ this.maxWidth = '560px';
294
233
  /** Max-height of the dialog. If a number is provided, assumes pixel units. */
295
- this.maxHeight = '95vh';
234
+ this.maxHeight = '85vh';
296
235
  /** Whether the dialog can be dragged at runtime and optionally restrict dragging to a specific axis */
297
236
  this.draggable = false;
298
237
  /** Data being injected into the child component. */
@@ -420,7 +359,7 @@ class CuteDialogContainer extends CdkDialogContainer {
420
359
  const bpName = bsBreakpoints.getLabel(dialogConfig.fullscreenStrategy.substring(BREAKPOINT_KEY.length));
421
360
  breakpointObserver
422
361
  .observe([
423
- bsBreakpoints[bpName + 'AndDown'],
362
+ bsBreakpoints.getMediaQuery(bpName + 'AndDown') ?? "",
424
363
  ])
425
364
  .pipe(takeUntilDestroyed())
426
365
  .subscribe(result => {
@@ -686,6 +625,8 @@ class CuteDialog {
686
625
  positionStrategy: this._overlay.position().global().centerHorizontally().centerVertically(),
687
626
  // Disable closing since we need to sync it up to the animation ourselves.
688
627
  disableClose: true,
628
+ // Closing is tied to our animation so the close predicate has to be implemented separately.
629
+ closePredicate: undefined,
689
630
  // Disable closing on destroying, because this service cleans up its open dialogs as well.
690
631
  // We want to do the cleanup here, rather than the CDK service, because the CDK destroys
691
632
  // the dialogs immediately whereas we want it to wait for the animations to finish.
@@ -783,12 +724,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
783
724
  * Button that will close the current dialog.
784
725
  */
785
726
  class CuteDialogClose {
786
- constructor(
787
- // The dialog title directive is always used in combination with a `CuteDialogRef`.
788
- dialogRef, _elementRef, _dialog) {
789
- this.dialogRef = dialogRef;
790
- this._elementRef = _elementRef;
791
- this._dialog = _dialog;
727
+ constructor() {
728
+ this.dialogRef = inject(CuteDialogRef, { optional: true });
729
+ this._elementRef = inject(ElementRef);
730
+ this._dialog = inject(CuteDialog);
792
731
  /** Default to "button" to prevent accidental form submits. */
793
732
  this.type = 'button';
794
733
  /** Dialog close input. */
@@ -818,7 +757,7 @@ class CuteDialogClose {
818
757
  // the FocusMonitor won't detect any origin change, and will always output `program`.
819
758
  _closeDialogVia(this.dialogRef, event.screenX === 0 && event.screenY === 0 ? 'keyboard' : 'mouse', this.dialogResult);
820
759
  }
821
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogClose, deps: [{ token: CuteDialogRef, optional: true }, { token: i0.ElementRef }, { token: CuteDialog }], target: i0.ɵɵFactoryTarget.Directive }); }
760
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogClose, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
822
761
  static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogClose, isStandalone: true, selector: "[cute-dialog-close], [cuteDialogClose]", inputs: { ariaLabel: ["aria-label", "ariaLabel"], type: "type", dialogResult: ["cute-dialog-close", "dialogResult"], _cuteDialogClose: ["cuteDialogClose", "_cuteDialogClose"] }, host: { listeners: { "click": "_onButtonClick($event)" }, properties: { "attr.aria-label": "ariaLabel || null", "attr.type": "type" } }, exportAs: ["cuteDialogClose"], usesOnChanges: true, ngImport: i0 }); }
823
762
  }
824
763
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogClose, decorators: [{
@@ -833,9 +772,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
833
772
  '[attr.type]': 'type',
834
773
  },
835
774
  }]
836
- }], ctorParameters: () => [{ type: CuteDialogRef, decorators: [{
837
- type: Optional
838
- }] }, { type: i0.ElementRef }, { type: CuteDialog }], propDecorators: { ariaLabel: [{
775
+ }], ctorParameters: () => [], propDecorators: { ariaLabel: [{
839
776
  type: Input,
840
777
  args: ['aria-label']
841
778
  }], type: [{
@@ -847,6 +784,127 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
847
784
  type: Input,
848
785
  args: ['cuteDialogClose']
849
786
  }] } });
787
+ class CuteDialogLayoutSection {
788
+ constructor() {
789
+ this._dialogRef = inject(CuteDialogRef, { optional: true });
790
+ this._elementRef = inject(ElementRef);
791
+ this._dialog = inject(CuteDialog);
792
+ }
793
+ ngOnInit() {
794
+ if (!this._dialogRef) {
795
+ this._dialogRef = getClosestDialog(this._elementRef, this._dialog.openDialogs);
796
+ }
797
+ if (this._dialogRef) {
798
+ Promise.resolve().then(() => {
799
+ this._onAdd();
800
+ });
801
+ }
802
+ }
803
+ ngOnDestroy() {
804
+ // Note: we null check because there are some internal
805
+ // tests that are mocking out `MatDialogRef` incorrectly.
806
+ const instance = this._dialogRef?._containerInstance;
807
+ if (instance) {
808
+ Promise.resolve().then(() => {
809
+ this._onRemove();
810
+ });
811
+ }
812
+ }
813
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogLayoutSection, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
814
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogLayoutSection, isStandalone: true, ngImport: i0 }); }
815
+ }
816
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogLayoutSection, decorators: [{
817
+ type: Directive
818
+ }] });
819
+ /**
820
+ * Title of a dialog element. Stays fixed to the top of the dialog when scrolling.
821
+ */
822
+ class CuteDialogTitle extends CuteDialogLayoutSection {
823
+ constructor() {
824
+ super();
825
+ this._header = inject(CuteDialogHeader, { optional: true, host: true });
826
+ this.id = inject(_IdGenerator).getId('cute-dialog-title-');
827
+ }
828
+ _onAdd() {
829
+ // Note: we null check the queue, because there are some internal
830
+ // tests that are mocking out `MatDialogRef` incorrectly.
831
+ this._dialogRef._containerInstance?._addAriaLabelledBy?.(this.id);
832
+ }
833
+ _onRemove() {
834
+ this._dialogRef?._containerInstance?._removeAriaLabelledBy?.(this.id);
835
+ }
836
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogTitle, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
837
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogTitle, isStandalone: true, selector: "[cute-dialog-title], [cuteDialogTitle]", inputs: { id: "id" }, host: { properties: { "id": "id || null", "style": "{\"pointer-events\":\"none\", \"padding\": !_header ? \"var(--bs-modal-header-padding)\" : undefined}" }, classAttribute: "cute-dialog-title modal-title user-select-none" }, exportAs: ["cuteDialogTitle"], usesInheritance: true, ngImport: i0 }); }
838
+ }
839
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogTitle, decorators: [{
840
+ type: Directive,
841
+ args: [{
842
+ selector: '[cute-dialog-title], [cuteDialogTitle]',
843
+ exportAs: 'cuteDialogTitle',
844
+ host: {
845
+ 'class': 'cute-dialog-title modal-title user-select-none',
846
+ '[id]': 'id || null',
847
+ '[style]': '{"pointer-events":"none", "padding": !_header ? "var(--bs-modal-header-padding)" : undefined}',
848
+ },
849
+ }]
850
+ }], ctorParameters: () => [], propDecorators: { id: [{
851
+ type: Input
852
+ }] } });
853
+ /**
854
+ * Scrollable content container of a dialog.
855
+ */
856
+ class CuteDialogBody {
857
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogBody, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
858
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogBody, isStandalone: true, selector: "cute-dialog-body, [cute-dialog-body], [cuteDialogBody],\n cute-dialog-content, [cute-dialog-content], [cuteDialogContent]\n ", host: { classAttribute: "cute-dialog-body modal-body" }, exportAs: ["cuteDialogBody"], ngImport: i0 }); }
859
+ }
860
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogBody, decorators: [{
861
+ type: Directive,
862
+ args: [{
863
+ selector: `cute-dialog-body, [cute-dialog-body], [cuteDialogBody],
864
+ cute-dialog-content, [cute-dialog-content], [cuteDialogContent]
865
+ `,
866
+ exportAs: 'cuteDialogBody',
867
+ host: {
868
+ 'class': 'cute-dialog-body modal-body',
869
+ },
870
+ standalone: true,
871
+ }]
872
+ }] });
873
+ /**
874
+ * Container for the bottom action buttons in a dialog.
875
+ * Stays fixed to the bottom when scrolling.
876
+ */
877
+ class CuteDialogFooter extends CuteDialogLayoutSection {
878
+ constructor() {
879
+ super(...arguments);
880
+ /** Horizontal alignment of the footer's content */
881
+ this.align = 'end';
882
+ }
883
+ _onAdd() {
884
+ this._dialogRef._containerInstance?._updateActionSectionCount?.(1);
885
+ }
886
+ _onRemove() {
887
+ this._dialogRef._containerInstance?._updateActionSectionCount?.(-1);
888
+ }
889
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogFooter, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
890
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogFooter, isStandalone: true, selector: "cute-dialog-footer, [cute-dialog-footer], [cuteDialogFooter],\n cute-dialog-actions, [cute-dialog-actions], [cuteDialogActions]\n ", inputs: { align: "align" }, host: { properties: { "style.justify-content": "align" }, classAttribute: "cute-dialog-footer cute-dialog-actions modal-footer" }, exportAs: ["cuteDialogFooter", "cuteDialogActions"], usesInheritance: true, ngImport: i0 }); }
891
+ }
892
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogFooter, decorators: [{
893
+ type: Directive,
894
+ args: [{
895
+ selector: `cute-dialog-footer, [cute-dialog-footer], [cuteDialogFooter],
896
+ cute-dialog-actions, [cute-dialog-actions], [cuteDialogActions]
897
+ `,
898
+ exportAs: 'cuteDialogFooter, cuteDialogActions',
899
+ host: {
900
+ 'class': 'cute-dialog-footer cute-dialog-actions modal-footer',
901
+ '[style.justify-content]': 'align',
902
+ },
903
+ standalone: true,
904
+ }]
905
+ }], propDecorators: { align: [{
906
+ type: Input
907
+ }] } });
850
908
  /**
851
909
  * Finds the closest CuteDialogRef to an element by looking at the DOM.
852
910
  * @param element Element relative to which to look for a dialog.
@@ -912,16 +970,18 @@ class CuteDialogHeader {
912
970
  class="modal-header"
913
971
  role="heading"
914
972
  cdkDrag
973
+ cdkDragHandle
915
974
  cdkDragRootElement=".cdk-overlay-pane"
916
975
  [cdkDragDisabled]="!draggable || container.isFullScreenDialog()"
917
976
  [style.cursor]="getCursorStyle()"
918
977
  >
919
978
  <ng-content select="[cute-dialog-title], [cuteDialogTitle]"></ng-content>
920
979
  <ng-content></ng-content>
921
- <button cuteButton="close-button" tabindex="-1" color="light" magnitude="smaller" cute-dialog-close></button>
980
+ <button cuteButton="close-button"
981
+ magnitude="small"
982
+ cute-dialog-close></button>
922
983
  </div>
923
- <!-- cdkDragHandle-->
924
- `, isInline: true, dependencies: [{ kind: "component", type: CuteButton, selector: "button[cuteButton], button[cute-button], a[cuteButton], a[cute-button], ", exportAs: ["cuteButton"] }, { kind: "directive", type: CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: CuteDialogClose, selector: "[cute-dialog-close], [cuteDialogClose]", inputs: ["aria-label", "type", "cute-dialog-close", "cuteDialogClose"], exportAs: ["cuteDialogClose"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
984
+ `, isInline: true, dependencies: [{ kind: "component", type: CuteButton, selector: "button[cuteButton], button[cute-button], a[cuteButton], a[cute-button], ", exportAs: ["cuteButton"] }, { kind: "directive", type: CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: CuteDialogClose, selector: "[cute-dialog-close], [cuteDialogClose]", inputs: ["aria-label", "type", "cute-dialog-close", "cuteDialogClose"], exportAs: ["cuteDialogClose"] }, { kind: "directive", type: CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
925
985
  }
926
986
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogHeader, decorators: [{
927
987
  type: Component,
@@ -933,16 +993,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
933
993
  class="modal-header"
934
994
  role="heading"
935
995
  cdkDrag
996
+ cdkDragHandle
936
997
  cdkDragRootElement=".cdk-overlay-pane"
937
998
  [cdkDragDisabled]="!draggable || container.isFullScreenDialog()"
938
999
  [style.cursor]="getCursorStyle()"
939
1000
  >
940
1001
  <ng-content select="[cute-dialog-title], [cuteDialogTitle]"></ng-content>
941
1002
  <ng-content></ng-content>
942
- <button cuteButton="close-button" tabindex="-1" color="light" magnitude="smaller" cute-dialog-close></button>
1003
+ <button cuteButton="close-button"
1004
+ magnitude="small"
1005
+ cute-dialog-close></button>
943
1006
  </div>
944
- <!-- cdkDragHandle-->
945
- `,
1007
+ `,
946
1008
  host: {
947
1009
  'class': 'cute-dialog-header',
948
1010
  },
@@ -951,7 +1013,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
951
1013
  imports: [
952
1014
  CuteButton,
953
1015
  CdkDrag,
954
- CuteDialogClose
1016
+ CuteDialogClose,
1017
+ CdkDragHandle
955
1018
  ]
956
1019
  }]
957
1020
  }], ctorParameters: () => [{ type: CuteDialogContainer }], propDecorators: { cdkDragEl: [{
@@ -968,34 +1031,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
968
1031
  args: ["mouseup", ["$event"]]
969
1032
  }] } });
970
1033
 
971
- /**
972
- * @license Apache-2.0
973
- *
974
- * Copyright (c) 2025 CuteWidgets Team. All Rights Reserved.
975
- *
976
- * You may not use this file except in compliance with the License
977
- * that can be found at http://www.apache.org/licenses/LICENSE-2.0
978
- */
979
- class CuteDialogTitle {
980
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogTitle, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
981
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.15", type: CuteDialogTitle, isStandalone: true, selector: "[cute-dialog-title], [cuteDialogTitle]", inputs: { id: "id" }, host: { properties: { "id": "id || null", "style.pointer-events": "\"none\"" }, classAttribute: "cute-dialog-title modal-title user-select-none" }, exportAs: ["cuteDialogTitle"], ngImport: i0 }); }
982
- }
983
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: CuteDialogTitle, decorators: [{
984
- type: Directive,
985
- args: [{
986
- selector: '[cute-dialog-title], [cuteDialogTitle]',
987
- exportAs: 'cuteDialogTitle',
988
- host: {
989
- 'class': 'cute-dialog-title modal-title user-select-none',
990
- '[id]': 'id || null',
991
- '[style.pointer-events]': '"none"',
992
- },
993
- standalone: true,
994
- }]
995
- }], propDecorators: { id: [{
996
- type: Input
997
- }] } });
998
-
999
1034
  /**
1000
1035
  * @license Apache-2.0
1001
1036
  *
@@ -1042,5 +1077,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
1042
1077
  * Generated bundle index. Do not edit.
1043
1078
  */
1044
1079
 
1045
- export { CUTE_DIALOG_DATA, CUTE_DIALOG_DEFAULT_OPTIONS, CUTE_DIALOG_SCROLL_STRATEGY, CuteDialog, CuteDialogBody, CuteDialogClose, CuteDialogConfig, CuteDialogContainer, CuteDialogFooter, CuteDialogHeader, CuteDialogModule, CuteDialogRef, CuteDialogState, CuteDialogTitle, _closeDialogVia };
1080
+ export { CUTE_DIALOG_DATA, CUTE_DIALOG_DEFAULT_OPTIONS, CUTE_DIALOG_SCROLL_STRATEGY, CuteDialog, CuteDialogBody, CuteDialogClose, CuteDialogConfig, CuteDialogContainer, CuteDialogFooter, CuteDialogHeader, CuteDialogLayoutSection, CuteDialogModule, CuteDialogRef, CuteDialogState, CuteDialogTitle, _closeDialogVia };
1046
1081
  //# sourceMappingURL=cute-widgets-base-dialog.mjs.map