@radix-ng/primitives 0.8.2 → 0.9.1

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 (175) hide show
  1. package/accordion/index.d.ts +3 -3
  2. package/accordion/src/accordion-content.directive.d.ts +1 -1
  3. package/accordion/src/accordion-header.directive.d.ts +1 -1
  4. package/accordion/src/accordion-item.directive.d.ts +1 -1
  5. package/accordion/src/accordion-root.directive.d.ts +1 -1
  6. package/accordion/src/accordion-trigger.directive.d.ts +1 -1
  7. package/alert-dialog/index.d.ts +2 -2
  8. package/avatar/index.d.ts +2 -2
  9. package/avatar/src/avatar-fallback.directive.d.ts +3 -3
  10. package/avatar/src/avatar-image.directive.d.ts +6 -6
  11. package/avatar/src/avatar-root.directive.d.ts +4 -4
  12. package/checkbox/index.d.ts +1 -1
  13. package/collapsible/index.d.ts +1 -1
  14. package/collapsible/src/collapsible-content.directive.d.ts +1 -1
  15. package/collapsible/src/collapsible-root.directive.d.ts +1 -1
  16. package/collapsible/src/collapsible-trigger.directive.d.ts +1 -1
  17. package/dropdown-menu/index.d.ts +8 -3
  18. package/dropdown-menu/src/dropdown-menu-content.directive.d.ts +12 -2
  19. package/dropdown-menu/src/dropdown-menu-item-checkbox.directive.d.ts +9 -0
  20. package/dropdown-menu/src/dropdown-menu-item-indicator.directive.d.ts +7 -0
  21. package/dropdown-menu/src/dropdown-menu-item-radio-group.directive.d.ts +12 -0
  22. package/dropdown-menu/src/dropdown-menu-item-radio.directive.d.ts +19 -0
  23. package/dropdown-menu/src/dropdown-menu-item-selectable.d.ts +12 -0
  24. package/dropdown-menu/src/dropdown-menu-item.directive.d.ts +14 -5
  25. package/dropdown-menu/src/dropdown-menu-label.directive.d.ts +1 -1
  26. package/dropdown-menu/src/dropdown-menu-separator.directive.d.ts +2 -2
  27. package/dropdown-menu/src/dropdown-menu-trigger.directive.d.ts +31 -1
  28. package/esm2022/accordion/index.mjs +4 -4
  29. package/esm2022/accordion/src/accordion-content.directive.mjs +7 -9
  30. package/esm2022/accordion/src/accordion-header.directive.mjs +5 -5
  31. package/esm2022/accordion/src/accordion-item.directive.mjs +17 -9
  32. package/esm2022/accordion/src/accordion-root.directive.mjs +5 -5
  33. package/esm2022/accordion/src/accordion-trigger.directive.mjs +5 -5
  34. package/esm2022/alert-dialog/index.mjs +3 -3
  35. package/esm2022/alert-dialog/src/alert-dialog-cancel.directive.mjs +4 -4
  36. package/esm2022/alert-dialog/src/alert-dialog-content.directive.mjs +3 -3
  37. package/esm2022/alert-dialog/src/alert-dialog-root.directive.mjs +5 -4
  38. package/esm2022/alert-dialog/src/alert-dialog-title.directive.mjs +3 -3
  39. package/esm2022/alert-dialog/src/alert-dialog-trigger.directive.mjs +4 -4
  40. package/esm2022/alert-dialog/src/alert-dialog.service.mjs +6 -9
  41. package/esm2022/avatar/index.mjs +1 -1
  42. package/esm2022/avatar/src/avatar-fallback.directive.mjs +6 -6
  43. package/esm2022/avatar/src/avatar-image.directive.mjs +6 -6
  44. package/esm2022/avatar/src/avatar-root.directive.mjs +6 -6
  45. package/esm2022/checkbox/index.mjs +2 -2
  46. package/esm2022/checkbox/src/checkbox-button.directive.mjs +5 -5
  47. package/esm2022/checkbox/src/checkbox-indicator.directive.mjs +4 -4
  48. package/esm2022/checkbox/src/checkbox-input.directive.mjs +5 -5
  49. package/esm2022/checkbox/src/checkbox.directive.mjs +4 -4
  50. package/esm2022/checkbox/src/checkbox.token.mjs +1 -1
  51. package/esm2022/collapsible/index.mjs +2 -2
  52. package/esm2022/collapsible/src/collapsible-content.directive.mjs +13 -7
  53. package/esm2022/collapsible/src/collapsible-root.directive.mjs +5 -5
  54. package/esm2022/collapsible/src/collapsible-trigger.directive.mjs +5 -5
  55. package/esm2022/dropdown-menu/index.mjs +9 -4
  56. package/esm2022/dropdown-menu/src/dropdown-menu-content.directive.mjs +35 -10
  57. package/esm2022/dropdown-menu/src/dropdown-menu-item-checkbox.directive.mjs +36 -0
  58. package/esm2022/dropdown-menu/src/dropdown-menu-item-indicator.directive.mjs +22 -0
  59. package/esm2022/dropdown-menu/src/dropdown-menu-item-radio-group.directive.mjs +37 -0
  60. package/esm2022/dropdown-menu/src/dropdown-menu-item-radio.directive.mjs +64 -0
  61. package/esm2022/dropdown-menu/src/dropdown-menu-item-selectable.mjs +31 -0
  62. package/esm2022/dropdown-menu/src/dropdown-menu-item.directive.mjs +58 -17
  63. package/esm2022/dropdown-menu/src/dropdown-menu-label.directive.mjs +5 -5
  64. package/esm2022/dropdown-menu/src/dropdown-menu-separator.directive.mjs +8 -8
  65. package/esm2022/dropdown-menu/src/dropdown-menu-trigger.directive.mjs +128 -12
  66. package/esm2022/label/index.mjs +2 -2
  67. package/esm2022/label/src/label.directive.mjs +54 -0
  68. package/esm2022/menu/index.mjs +7 -7
  69. package/esm2022/menu/src/menu-content.directive.mjs +3 -3
  70. package/esm2022/menu/src/menu-directive.mjs +3 -3
  71. package/esm2022/menu/src/menu-group.directive.mjs +3 -3
  72. package/esm2022/menu/src/menu-item.directive.mjs +8 -4
  73. package/esm2022/menu/src/menu-label.directive.mjs +3 -3
  74. package/esm2022/menu/src/menu-separator.directive.mjs +4 -4
  75. package/esm2022/menubar/index.mjs +7 -7
  76. package/esm2022/menubar/src/menubar-content.directive.mjs +3 -3
  77. package/esm2022/menubar/src/menubar-item-checkbox.directive.mjs +4 -4
  78. package/esm2022/menubar/src/menubar-item-indicator.directive.mjs +3 -3
  79. package/esm2022/menubar/src/menubar-item-radio.directive.mjs +4 -4
  80. package/esm2022/menubar/src/menubar-item.directive.mjs +4 -4
  81. package/esm2022/menubar/src/menubar-radio-group.directive.mjs +3 -3
  82. package/esm2022/menubar/src/menubar-root.directive.mjs +3 -3
  83. package/esm2022/menubar/src/menubar-separator.directive.mjs +4 -4
  84. package/esm2022/menubar/src/menubar-trigger.directive.mjs +4 -4
  85. package/esm2022/progress/src/progress-indicator.directive.mjs +19 -9
  86. package/esm2022/progress/src/progress-root.directive.mjs +63 -7
  87. package/esm2022/radio/src/radio-indicator.directive.mjs +4 -4
  88. package/esm2022/radio/src/radio-item.directive.mjs +4 -8
  89. package/esm2022/radio/src/radio-root.directive.mjs +5 -9
  90. package/esm2022/separator/src/separator.directive.mjs +3 -3
  91. package/esm2022/switch/index.mjs +29 -4
  92. package/esm2022/switch/src/switch-input.directive.mjs +6 -6
  93. package/esm2022/switch/src/switch-root.directive.mjs +7 -7
  94. package/esm2022/switch/src/switch-thumb.directive.mjs +6 -6
  95. package/esm2022/tabs/index.mjs +7 -7
  96. package/esm2022/tabs/src/tabs-content.directive.mjs +5 -5
  97. package/esm2022/tabs/src/tabs-context.service.mjs +3 -3
  98. package/esm2022/tabs/src/tabs-list.directive.mjs +5 -5
  99. package/esm2022/tabs/src/tabs-root.directive.mjs +5 -5
  100. package/esm2022/tabs/src/tabs-trigger.directive.mjs +5 -5
  101. package/esm2022/toggle/index.mjs +2 -2
  102. package/esm2022/toggle/src/toggle.directive.mjs +39 -0
  103. package/esm2022/toggle-group/src/toggle-group-button.directive.mjs +6 -14
  104. package/esm2022/toggle-group/src/toggle-group-button.token.mjs +1 -1
  105. package/esm2022/toggle-group/src/toggle-group-multi.directive.mjs +6 -32
  106. package/esm2022/toggle-group/src/toggle-group.directive.mjs +5 -25
  107. package/esm2022/toggle-group/src/toggle-group.token.mjs +1 -1
  108. package/fesm2022/radix-ng-primitives-accordion.mjs +73 -67
  109. package/fesm2022/radix-ng-primitives-accordion.mjs.map +1 -1
  110. package/fesm2022/radix-ng-primitives-alert-dialog.mjs +49 -51
  111. package/fesm2022/radix-ng-primitives-alert-dialog.mjs.map +1 -1
  112. package/fesm2022/radix-ng-primitives-avatar.mjs +15 -15
  113. package/fesm2022/radix-ng-primitives-avatar.mjs.map +1 -1
  114. package/fesm2022/radix-ng-primitives-checkbox.mjs +43 -43
  115. package/fesm2022/radix-ng-primitives-checkbox.mjs.map +1 -1
  116. package/fesm2022/radix-ng-primitives-collapsible.mjs +20 -14
  117. package/fesm2022/radix-ng-primitives-collapsible.mjs.map +1 -1
  118. package/fesm2022/radix-ng-primitives-dropdown-menu.mjs +397 -47
  119. package/fesm2022/radix-ng-primitives-dropdown-menu.mjs.map +1 -1
  120. package/fesm2022/radix-ng-primitives-label.mjs +17 -10
  121. package/fesm2022/radix-ng-primitives-label.mjs.map +1 -1
  122. package/fesm2022/radix-ng-primitives-menu.mjs +26 -22
  123. package/fesm2022/radix-ng-primitives-menu.mjs.map +1 -1
  124. package/fesm2022/radix-ng-primitives-menubar.mjs +31 -31
  125. package/fesm2022/radix-ng-primitives-menubar.mjs.map +1 -1
  126. package/fesm2022/radix-ng-primitives-progress.mjs +80 -14
  127. package/fesm2022/radix-ng-primitives-progress.mjs.map +1 -1
  128. package/fesm2022/radix-ng-primitives-radio.mjs +10 -14
  129. package/fesm2022/radix-ng-primitives-radio.mjs.map +1 -1
  130. package/fesm2022/radix-ng-primitives-separator.mjs +3 -3
  131. package/fesm2022/radix-ng-primitives-switch.mjs +53 -31
  132. package/fesm2022/radix-ng-primitives-switch.mjs.map +1 -1
  133. package/fesm2022/radix-ng-primitives-tabs.mjs +23 -23
  134. package/fesm2022/radix-ng-primitives-tabs.mjs.map +1 -1
  135. package/fesm2022/radix-ng-primitives-toggle-group.mjs +14 -64
  136. package/fesm2022/radix-ng-primitives-toggle-group.mjs.map +1 -1
  137. package/fesm2022/radix-ng-primitives-toggle.mjs +18 -28
  138. package/fesm2022/radix-ng-primitives-toggle.mjs.map +1 -1
  139. package/label/index.d.ts +1 -1
  140. package/label/src/label.directive.d.ts +23 -0
  141. package/menu/index.d.ts +2 -2
  142. package/menubar/index.d.ts +2 -2
  143. package/package.json +1 -7
  144. package/progress/src/progress-indicator.directive.d.ts +12 -2
  145. package/progress/src/progress-root.directive.d.ts +38 -4
  146. package/radio/src/radio-item.directive.d.ts +1 -2
  147. package/radio/src/radio-root.directive.d.ts +1 -2
  148. package/switch/index.d.ts +11 -3
  149. package/switch/src/switch-input.directive.d.ts +1 -1
  150. package/switch/src/switch-root.directive.d.ts +1 -1
  151. package/switch/src/switch-thumb.directive.d.ts +1 -1
  152. package/tabs/index.d.ts +2 -2
  153. package/tabs/src/tabs-content.directive.d.ts +1 -1
  154. package/tabs/src/tabs-list.directive.d.ts +1 -1
  155. package/tabs/src/tabs-root.directive.d.ts +1 -1
  156. package/tabs/src/tabs-trigger.directive.d.ts +1 -1
  157. package/toggle/index.d.ts +2 -2
  158. package/toggle/src/toggle.directive.d.ts +30 -0
  159. package/toggle-group/src/toggle-group-button.directive.d.ts +1 -7
  160. package/toggle-group/src/toggle-group-multi.directive.d.ts +3 -13
  161. package/toggle-group/src/toggle-group.directive.d.ts +3 -9
  162. package/esm2022/label/src/label-root.directive.mjs +0 -47
  163. package/esm2022/roving-focus/index.mjs +0 -3
  164. package/esm2022/roving-focus/radix-ng-primitives-roving-focus.mjs +0 -5
  165. package/esm2022/roving-focus/src/roving-focus-group.directive.mjs +0 -109
  166. package/esm2022/roving-focus/src/roving-focus-item.directive.mjs +0 -86
  167. package/esm2022/toggle/src/toggle-root.directive.mjs +0 -49
  168. package/fesm2022/radix-ng-primitives-roving-focus.mjs +0 -198
  169. package/fesm2022/radix-ng-primitives-roving-focus.mjs.map +0 -1
  170. package/label/src/label-root.directive.d.ts +0 -14
  171. package/roving-focus/README.md +0 -1
  172. package/roving-focus/index.d.ts +0 -2
  173. package/roving-focus/src/roving-focus-group.directive.d.ts +0 -53
  174. package/roving-focus/src/roving-focus-item.directive.d.ts +0 -50
  175. package/toggle/src/toggle-root.directive.d.ts +0 -32
@@ -1,22 +1,127 @@
1
1
  import * as i1 from '@angular/cdk/menu';
2
- import { CdkMenuTrigger } from '@angular/cdk/menu';
2
+ import { CdkMenuTrigger, CdkMenu, CdkTargetMenuAim, CdkMenuItem } from '@angular/cdk/menu';
3
3
  import * as i0 from '@angular/core';
4
- import { inject, input, booleanAttribute, Directive } from '@angular/core';
5
- import { outputFromObservable } from '@angular/core/rxjs-interop';
6
- import * as i1$1 from '@radix-ng/primitives/menu';
7
- import { RdxMenuItemDirective, RdxMenuSeparatorDirective, RdxMenuContentDirective } from '@radix-ng/primitives/menu';
4
+ import { inject, input, booleanAttribute, numberAttribute, Directive, Input, ElementRef, EventEmitter, Output } from '@angular/core';
5
+ import { Subject, startWith, pairwise } from 'rxjs';
6
+ import { outputFromObservable, takeUntilDestroyed } from '@angular/core/rxjs-interop';
7
+ import { UniqueSelectionDispatcher } from '@angular/cdk/collections';
8
+ import * as i1$1 from '@radix-ng/primitives/separator';
9
+ import { RdxSeparatorRootDirective } from '@radix-ng/primitives/separator';
8
10
 
11
+ var DropdownSide;
12
+ (function (DropdownSide) {
13
+ DropdownSide["Top"] = "top";
14
+ DropdownSide["Right"] = "right";
15
+ DropdownSide["Bottom"] = "bottom";
16
+ DropdownSide["Left"] = "left";
17
+ })(DropdownSide || (DropdownSide = {}));
18
+ var DropdownAlign;
19
+ (function (DropdownAlign) {
20
+ DropdownAlign["Start"] = "start";
21
+ DropdownAlign["Center"] = "center";
22
+ DropdownAlign["End"] = "end";
23
+ })(DropdownAlign || (DropdownAlign = {}));
24
+ const mapRdxAlignToCdkPosition = {
25
+ start: 'top',
26
+ center: 'center',
27
+ end: 'bottom'
28
+ };
29
+ const dropdownPositions = {
30
+ top: {
31
+ originX: 'start',
32
+ originY: 'top',
33
+ overlayX: 'start',
34
+ overlayY: 'bottom',
35
+ offsetX: 0,
36
+ offsetY: 0
37
+ },
38
+ right: {
39
+ originX: 'end',
40
+ originY: 'top',
41
+ overlayX: 'start',
42
+ overlayY: 'top',
43
+ offsetX: 0,
44
+ offsetY: 0
45
+ },
46
+ bottom: {
47
+ originX: 'start',
48
+ originY: 'bottom',
49
+ overlayX: 'start',
50
+ overlayY: 'top',
51
+ offsetX: 0,
52
+ offsetY: 0
53
+ },
54
+ left: {
55
+ originX: 'start',
56
+ originY: 'top',
57
+ overlayX: 'end',
58
+ overlayY: 'top',
59
+ offsetX: 0,
60
+ offsetY: 0
61
+ }
62
+ };
9
63
  class RdxDropdownMenuTriggerDirective {
64
+ set side(value) {
65
+ if (!Object.values(DropdownSide).includes(value)) {
66
+ throw new Error(`Unknown side: ${value}`);
67
+ }
68
+ this._side = value;
69
+ this.cdkMenuTrigger.menuPosition[0] = dropdownPositions[value];
70
+ }
71
+ get side() {
72
+ return this._side;
73
+ }
74
+ set align(value) {
75
+ if (!Object.values(DropdownAlign).includes(value)) {
76
+ throw new Error(`Unknown align: ${value}`);
77
+ }
78
+ this._align = value;
79
+ if (this.isVertical) {
80
+ this.defaultPosition.overlayX = this.defaultPosition.originX = value;
81
+ }
82
+ else {
83
+ this.defaultPosition.overlayY = this.defaultPosition.originY = mapRdxAlignToCdkPosition[value];
84
+ }
85
+ }
86
+ get align() {
87
+ return this._align;
88
+ }
89
+ set sideOffset(value) {
90
+ // todo need invert value for top and left
91
+ if (this.isVertical) {
92
+ this.defaultPosition.offsetY = value;
93
+ }
94
+ else {
95
+ this.defaultPosition.offsetX = value;
96
+ }
97
+ }
98
+ set alignOffset(value) {
99
+ // todo need invert value for top and left
100
+ if (this.isVertical) {
101
+ this.defaultPosition.offsetX = value;
102
+ }
103
+ else {
104
+ this.defaultPosition.offsetY = value;
105
+ }
106
+ }
107
+ get isVertical() {
108
+ return this._side === DropdownSide.Top || this._side === DropdownSide.Bottom;
109
+ }
110
+ get defaultPosition() {
111
+ return this.cdkMenuTrigger.menuPosition[0];
112
+ }
10
113
  constructor() {
11
114
  this.cdkMenuTrigger = inject(CdkMenuTrigger, { host: true });
12
115
  this.disabled = input(false, {
13
116
  transform: booleanAttribute
14
117
  });
15
- /*
16
- * Event handler called when the open state of the dropdown menu changes.
17
- * // TODO: mv to RootMenuDropdown
18
- */
118
+ this._side = DropdownSide.Bottom;
119
+ this._align = DropdownAlign.Start;
19
120
  this.onOpenChange = outputFromObservable(this.cdkMenuTrigger?.opened);
121
+ // todo priority
122
+ this.cdkMenuTrigger.menuPosition = [
123
+ { ...dropdownPositions[DropdownSide.Bottom] }
124
+ ];
20
125
  }
21
126
  onPointerDown($event) {
22
127
  // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)
@@ -30,16 +135,19 @@ class RdxDropdownMenuTriggerDirective {
30
135
  }
31
136
  }
32
137
  }
33
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
34
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "18.0.4", type: RdxDropdownMenuTriggerDirective, isStandalone: true, selector: "[DropdownMenuTrigger]", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onOpenChange: "onOpenChange" }, host: { attributes: { "type": "button" }, listeners: { "pointerdown": "onPointerDown($event)" }, properties: { "attr.aria-haspopup": "'menu'", "attr.aria-expanded": "cdkMenuTrigger.isOpen()", "attr.data-state": "cdkMenuTrigger.isOpen() ? 'open': 'closed'", "attr.data-disabled": "disabled() ? '' : undefined", "disabled": "disabled()" } }, hostDirectives: [{ directive: i1.CdkMenuTrigger, inputs: ["cdkMenuTriggerFor", "DropdownMenuTrigger"] }], ngImport: i0 }); }
138
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
139
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "18.1.2", type: RdxDropdownMenuTriggerDirective, isStandalone: true, selector: "[rdxDropdownMenuTrigger]", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, side: { classPropertyName: "side", publicName: "side", isSignal: false, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: false, isRequired: false, transformFunction: null }, sideOffset: { classPropertyName: "sideOffset", publicName: "sideOffset", isSignal: false, isRequired: false, transformFunction: numberAttribute }, alignOffset: { classPropertyName: "alignOffset", publicName: "alignOffset", isSignal: false, isRequired: false, transformFunction: numberAttribute } }, outputs: { onOpenChange: "onOpenChange" }, host: { attributes: { "type": "button" }, listeners: { "pointerdown": "onPointerDown($event)" }, properties: { "attr.aria-haspopup": "'menu'", "attr.aria-expanded": "cdkMenuTrigger.isOpen()", "attr.data-state": "cdkMenuTrigger.isOpen() ? 'open': 'closed'", "attr.data-disabled": "disabled() ? '' : undefined", "disabled": "disabled()" } }, hostDirectives: [{ directive: i1.CdkMenuTrigger, inputs: ["cdkMenuTriggerFor", "rdxDropdownMenuTrigger"] }], ngImport: i0 }); }
35
140
  }
36
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuTriggerDirective, decorators: [{
141
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuTriggerDirective, decorators: [{
37
142
  type: Directive,
38
143
  args: [{
39
- selector: '[DropdownMenuTrigger]',
144
+ selector: '[rdxDropdownMenuTrigger]',
40
145
  standalone: true,
41
146
  hostDirectives: [
42
- { directive: CdkMenuTrigger, inputs: ['cdkMenuTriggerFor: DropdownMenuTrigger'] }
147
+ {
148
+ directive: CdkMenuTrigger,
149
+ inputs: ['cdkMenuTriggerFor: rdxDropdownMenuTrigger']
150
+ }
43
151
  ],
44
152
  host: {
45
153
  type: 'button',
@@ -51,75 +159,317 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImpor
51
159
  '(pointerdown)': 'onPointerDown($event)'
52
160
  }
53
161
  }]
54
- }] });
162
+ }], ctorParameters: () => [], propDecorators: { side: [{
163
+ type: Input
164
+ }], align: [{
165
+ type: Input
166
+ }], sideOffset: [{
167
+ type: Input,
168
+ args: [{ transform: numberAttribute }]
169
+ }], alignOffset: [{
170
+ type: Input,
171
+ args: [{ transform: numberAttribute }]
172
+ }] } });
55
173
 
56
- class RdxDropdownMenuItemDirective {
174
+ class RdxDropdownMenuContentDirective {
57
175
  constructor() {
58
- /*
59
- * When true, prevents the user from interacting with the item.
60
- */
61
- this.disabled = input(false, {
62
- transform: booleanAttribute,
63
- alias: 'rdxDisabled'
176
+ this.highlighted = new Subject();
177
+ this.cdkMenu = inject(CdkMenu);
178
+ this.cdkMenuTrigger = inject(CdkMenuTrigger, { host: true });
179
+ this.menuTrigger = inject(RdxDropdownMenuTriggerDirective, { optional: true });
180
+ this.highlighted.pipe(startWith(null), pairwise()).subscribe(([prev, item]) => {
181
+ if (prev) {
182
+ prev.highlighted = false;
183
+ }
184
+ if (item) {
185
+ item.highlighted = true;
186
+ }
187
+ });
188
+ }
189
+ updateActiveItem(item) {
190
+ this.cdkMenu['keyManager'].updateActiveItem(item);
191
+ }
192
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuContentDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
193
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.1.2", type: RdxDropdownMenuContentDirective, isStandalone: true, selector: "[rdxDropdownMenuContent]", host: { properties: { "attr.data-state": "cdkMenuTrigger.isOpen() ? 'open': 'closed'", "attr.data-align": "menuTrigger!.align", "attr.data-side": "menuTrigger!.side", "attr.data-orientation": "cdkMenu.orientation" } }, hostDirectives: [{ directive: i1.CdkMenu }, { directive: i1.CdkTargetMenuAim }], ngImport: i0 }); }
194
+ }
195
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuContentDirective, decorators: [{
196
+ type: Directive,
197
+ args: [{
198
+ selector: '[rdxDropdownMenuContent]',
199
+ standalone: true,
200
+ hostDirectives: [CdkMenu, CdkTargetMenuAim],
201
+ host: {
202
+ '[attr.data-state]': "cdkMenuTrigger.isOpen() ? 'open': 'closed'",
203
+ '[attr.data-align]': 'menuTrigger!.align',
204
+ '[attr.data-side]': 'menuTrigger!.side',
205
+ '[attr.data-orientation]': 'cdkMenu.orientation'
206
+ }
207
+ }]
208
+ }], ctorParameters: () => [] });
209
+
210
+ class RdxDropdownMenuItemDirective extends CdkMenuItem {
211
+ constructor() {
212
+ super();
213
+ this.menu = inject(RdxDropdownMenuContentDirective);
214
+ this.nativeElement = inject(ElementRef).nativeElement;
215
+ this.highlighted = false;
216
+ this.disabled = false;
217
+ this.onSelect = new EventEmitter();
218
+ this.menu.highlighted.pipe(takeUntilDestroyed()).subscribe((value) => {
219
+ if (value !== this) {
220
+ this.highlighted = false;
221
+ }
64
222
  });
223
+ this.triggered.subscribe(this.onSelect);
224
+ }
225
+ onPointerMove() {
226
+ this.nativeElement.focus({ preventScroll: true });
227
+ this.menu.updateActiveItem(this);
228
+ }
229
+ onKeydown(event) {
230
+ if (this.nativeElement.tagName !== 'BUTTON' && ['Enter', ' '].includes(event.key)) {
231
+ event.preventDefault();
232
+ }
65
233
  }
66
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuItemDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
67
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "18.0.4", type: RdxDropdownMenuItemDirective, isStandalone: true, selector: "[DropdownMenuItem]", inputs: { disabled: { classPropertyName: "disabled", publicName: "rdxDisabled", isSignal: true, isRequired: false, transformFunction: null } }, hostDirectives: [{ directive: i1$1.RdxMenuItemDirective, inputs: ["rdxDisabled", "disabled"] }], ngImport: i0 }); }
234
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
235
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "18.1.2", type: RdxDropdownMenuItemDirective, isStandalone: true, selector: "[rdxDropdownMenuItem]", inputs: { disabled: ["disabled", "disabled", booleanAttribute] }, outputs: { onSelect: "onSelect" }, host: { attributes: { "type": "button" }, listeners: { "pointermove": "onPointerMove()", "focus": "menu.highlighted.next(this)", "keydown": "onKeydown($event)" }, properties: { "attr.data-orientation": "\"vertical\"", "attr.data-highlighted": "highlighted ? \"\" : null", "attr.data-disabled": "disabled ? \"\" : null", "attr.disabled": "disabled ? \"\" : null" } }, providers: [
236
+ {
237
+ provide: CdkMenuItem,
238
+ useExisting: RdxDropdownMenuItemDirective
239
+ }
240
+ ], usesInheritance: true, ngImport: i0 }); }
68
241
  }
69
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuItemDirective, decorators: [{
242
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemDirective, decorators: [{
70
243
  type: Directive,
71
244
  args: [{
72
- selector: '[DropdownMenuItem]',
245
+ selector: '[rdxDropdownMenuItem]',
73
246
  standalone: true,
74
- hostDirectives: [{ directive: RdxMenuItemDirective, inputs: ['rdxDisabled: disabled '] }]
247
+ host: {
248
+ type: 'button',
249
+ // todo horizontal ?
250
+ '[attr.data-orientation]': '"vertical"',
251
+ '[attr.data-highlighted]': 'highlighted ? "" : null',
252
+ '[attr.data-disabled]': 'disabled ? "" : null',
253
+ '[attr.disabled]': 'disabled ? "" : null',
254
+ '(pointermove)': 'onPointerMove()',
255
+ '(focus)': 'menu.highlighted.next(this)',
256
+ '(keydown)': 'onKeydown($event)'
257
+ },
258
+ providers: [
259
+ {
260
+ provide: CdkMenuItem,
261
+ useExisting: RdxDropdownMenuItemDirective
262
+ }
263
+ ]
75
264
  }]
76
- }] });
265
+ }], ctorParameters: () => [], propDecorators: { disabled: [{
266
+ type: Input,
267
+ args: [{ transform: booleanAttribute }]
268
+ }], onSelect: [{
269
+ type: Output
270
+ }] } });
77
271
 
78
- class RdxDropdownMenuSeparatorDirective {
79
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuSeparatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
80
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.0.4", type: RdxDropdownMenuSeparatorDirective, isStandalone: true, selector: "[DropdownMenuSeparator]", host: { attributes: { "role": "separator" }, properties: { "attr.aria-orientation": "'horizontal'" } }, hostDirectives: [{ directive: i1$1.RdxMenuSeparatorDirective }], ngImport: i0 }); }
272
+ /** Base class providing checked state for selectable DropdownMenuItems. */
273
+ class RdxDropdownMenuSelectable extends RdxDropdownMenuItemDirective {
274
+ constructor() {
275
+ super(...arguments);
276
+ /** Whether the element is checked */
277
+ this.checked = false;
278
+ this.checkedChange = new EventEmitter();
279
+ }
280
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuSelectable, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
281
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "18.1.2", type: RdxDropdownMenuSelectable, isStandalone: true, inputs: { checked: ["checked", "checked", booleanAttribute] }, outputs: { checkedChange: "checkedChange" }, host: { properties: { "attr.aria-checked": "!!checked", "attr.aria-disabled": "disabled || null", "attr.data-state": "checked ? \"checked\" : \"unchecked\"" } }, usesInheritance: true, ngImport: i0 }); }
81
282
  }
82
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuSeparatorDirective, decorators: [{
283
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuSelectable, decorators: [{
83
284
  type: Directive,
84
285
  args: [{
85
- selector: '[DropdownMenuSeparator]',
86
286
  standalone: true,
87
- hostDirectives: [RdxMenuSeparatorDirective],
88
287
  host: {
89
- role: 'separator',
90
- '[attr.aria-orientation]': "'horizontal'"
288
+ '[attr.aria-checked]': '!!checked',
289
+ '[attr.aria-disabled]': 'disabled || null',
290
+ '[attr.data-state]': 'checked ? "checked" : "unchecked"'
91
291
  }
92
292
  }]
293
+ }], propDecorators: { checked: [{
294
+ type: Input,
295
+ args: [{ transform: booleanAttribute }]
296
+ }], checkedChange: [{
297
+ type: Output
298
+ }] } });
299
+
300
+ class RdxDropdownMenuItemCheckboxDirective extends RdxDropdownMenuSelectable {
301
+ trigger(options) {
302
+ if (!this.disabled) {
303
+ this.checked = !this.checked;
304
+ this.checkedChange.emit(this.checked);
305
+ }
306
+ super.trigger(options);
307
+ }
308
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemCheckboxDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
309
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.1.2", type: RdxDropdownMenuItemCheckboxDirective, isStandalone: true, selector: "[rdxDropdownMenuItemCheckbox]", host: { attributes: { "role": "menuitemcheckbox" } }, providers: [
310
+ { provide: RdxDropdownMenuSelectable, useExisting: RdxDropdownMenuItemCheckboxDirective },
311
+ { provide: RdxDropdownMenuItemDirective, useExisting: RdxDropdownMenuSelectable },
312
+ { provide: CdkMenuItem, useExisting: RdxDropdownMenuItemDirective }
313
+ ], usesInheritance: true, ngImport: i0 }); }
314
+ }
315
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemCheckboxDirective, decorators: [{
316
+ type: Directive,
317
+ args: [{
318
+ selector: '[rdxDropdownMenuItemCheckbox]',
319
+ standalone: true,
320
+ host: {
321
+ role: 'menuitemcheckbox'
322
+ },
323
+ providers: [
324
+ { provide: RdxDropdownMenuSelectable, useExisting: RdxDropdownMenuItemCheckboxDirective },
325
+ { provide: RdxDropdownMenuItemDirective, useExisting: RdxDropdownMenuSelectable },
326
+ { provide: CdkMenuItem, useExisting: RdxDropdownMenuItemDirective }
327
+ ]
328
+ }]
93
329
  }] });
94
330
 
95
- class RdxDropdownMenuContentDirective {
96
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuContentDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
97
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.0.4", type: RdxDropdownMenuContentDirective, isStandalone: true, selector: "[DropdownMenuContent]", hostDirectives: [{ directive: i1$1.RdxMenuContentDirective }], ngImport: i0 }); }
331
+ class RdxDropdownMenuItemIndicatorDirective {
332
+ constructor() {
333
+ this.item = inject(RdxDropdownMenuSelectable);
334
+ }
335
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemIndicatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
336
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.1.2", type: RdxDropdownMenuItemIndicatorDirective, isStandalone: true, selector: "[rdxDropdownMenuItemIndicator]", host: { properties: { "style.display": "item.checked ? 'block' : 'none'", "attr.data-state": "item.checked ? 'checked' : 'unchecked'" } }, ngImport: i0 }); }
98
337
  }
99
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuContentDirective, decorators: [{
338
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemIndicatorDirective, decorators: [{
100
339
  type: Directive,
101
340
  args: [{
102
- selector: '[DropdownMenuContent]',
341
+ selector: '[rdxDropdownMenuItemIndicator]',
103
342
  standalone: true,
104
- hostDirectives: [RdxMenuContentDirective]
343
+ host: {
344
+ '[style.display]': "item.checked ? 'block' : 'none'",
345
+ '[attr.data-state]': "item.checked ? 'checked' : 'unchecked'"
346
+ }
105
347
  }]
106
348
  }] });
107
349
 
350
+ class RdxDropdownMenuItemRadioGroupDirective {
351
+ constructor() {
352
+ this.selectionDispatcher = inject(UniqueSelectionDispatcher);
353
+ this._value = null;
354
+ this.valueChange = new EventEmitter();
355
+ }
356
+ set value(id) {
357
+ this._value = id;
358
+ }
359
+ get value() {
360
+ return this._value;
361
+ }
362
+ ngAfterContentInit() {
363
+ this.selectionDispatcher.notify(this.value, '');
364
+ }
365
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemRadioGroupDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
366
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.1.2", type: RdxDropdownMenuItemRadioGroupDirective, isStandalone: true, selector: "[rdxDropdownMenuItemRadioGroup]", inputs: { value: "value" }, outputs: { valueChange: "valueChange" }, host: { attributes: { "role": "group" } }, providers: [{ provide: UniqueSelectionDispatcher, useClass: UniqueSelectionDispatcher }], ngImport: i0 }); }
367
+ }
368
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemRadioGroupDirective, decorators: [{
369
+ type: Directive,
370
+ args: [{
371
+ selector: '[rdxDropdownMenuItemRadioGroup]',
372
+ standalone: true,
373
+ host: {
374
+ role: 'group'
375
+ },
376
+ providers: [{ provide: UniqueSelectionDispatcher, useClass: UniqueSelectionDispatcher }]
377
+ }]
378
+ }], propDecorators: { value: [{
379
+ type: Input
380
+ }], valueChange: [{
381
+ type: Output
382
+ }] } });
383
+
384
+ /** Counter used to set a unique id and name for a selectable item */
385
+ let nextId = 0;
386
+ class RdxDropdownMenuItemRadioDirective extends RdxDropdownMenuSelectable {
387
+ get value() {
388
+ return this._value || this.id;
389
+ }
390
+ set value(value) {
391
+ this._value = value;
392
+ }
393
+ constructor() {
394
+ super();
395
+ /** The unique selection dispatcher for this radio's `RdxDropdownMenuItemRadioGroupDirective`. */
396
+ this.selectionDispatcher = inject(UniqueSelectionDispatcher);
397
+ this.group = inject(RdxDropdownMenuItemRadioGroupDirective);
398
+ /** An ID to identify this radio item to the `UniqueSelectionDispatcher`. */
399
+ this.id = `${nextId++}`;
400
+ this.triggered.subscribe(() => {
401
+ if (!this.disabled) {
402
+ this.selectionDispatcher.notify(this.value, '');
403
+ this.group.valueChange.emit(this.value);
404
+ }
405
+ });
406
+ }
407
+ ngAfterContentInit() {
408
+ this.removeDispatcherListener = this.selectionDispatcher.listen((id) => {
409
+ this.checked = this.value === id;
410
+ });
411
+ }
412
+ ngOnDestroy() {
413
+ super.ngOnDestroy();
414
+ this.removeDispatcherListener();
415
+ }
416
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemRadioDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
417
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.1.2", type: RdxDropdownMenuItemRadioDirective, isStandalone: true, selector: "[rdxDropdownMenuItemRadio]", inputs: { value: "value" }, host: { attributes: { "role": "menuitemradio" } }, providers: [
418
+ { provide: RdxDropdownMenuSelectable, useExisting: RdxDropdownMenuItemRadioDirective },
419
+ { provide: RdxDropdownMenuItemDirective, useExisting: RdxDropdownMenuSelectable },
420
+ { provide: CdkMenuItem, useExisting: RdxDropdownMenuItemDirective }
421
+ ], usesInheritance: true, ngImport: i0 }); }
422
+ }
423
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuItemRadioDirective, decorators: [{
424
+ type: Directive,
425
+ args: [{
426
+ selector: '[rdxDropdownMenuItemRadio]',
427
+ standalone: true,
428
+ host: {
429
+ role: 'menuitemradio'
430
+ },
431
+ providers: [
432
+ { provide: RdxDropdownMenuSelectable, useExisting: RdxDropdownMenuItemRadioDirective },
433
+ { provide: RdxDropdownMenuItemDirective, useExisting: RdxDropdownMenuSelectable },
434
+ { provide: CdkMenuItem, useExisting: RdxDropdownMenuItemDirective }
435
+ ]
436
+ }]
437
+ }], ctorParameters: () => [], propDecorators: { value: [{
438
+ type: Input
439
+ }] } });
440
+
108
441
  class RdxDropdownMenuLabelDirective {
109
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuLabelDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
110
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.0.4", type: RdxDropdownMenuLabelDirective, isStandalone: true, selector: "div[DropdownMenuLabel]", ngImport: i0 }); }
442
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuLabelDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
443
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.1.2", type: RdxDropdownMenuLabelDirective, isStandalone: true, selector: "[rdxDropdownMenuLabel]", ngImport: i0 }); }
111
444
  }
112
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxDropdownMenuLabelDirective, decorators: [{
445
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuLabelDirective, decorators: [{
113
446
  type: Directive,
114
447
  args: [{
115
- selector: 'div[DropdownMenuLabel]',
448
+ selector: '[rdxDropdownMenuLabel]',
116
449
  standalone: true
117
450
  }]
118
451
  }] });
119
452
 
453
+ class RdxDropdownMenuSeparatorDirective {
454
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuSeparatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
455
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.1.2", type: RdxDropdownMenuSeparatorDirective, isStandalone: true, selector: "[rdxDropdownMenuSeparator]", host: { attributes: { "role": "separator" }, properties: { "attr.aria-orientation": "'horizontal'" } }, hostDirectives: [{ directive: i1$1.RdxSeparatorRootDirective }], ngImport: i0 }); }
456
+ }
457
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: RdxDropdownMenuSeparatorDirective, decorators: [{
458
+ type: Directive,
459
+ args: [{
460
+ selector: '[rdxDropdownMenuSeparator]',
461
+ standalone: true,
462
+ hostDirectives: [RdxSeparatorRootDirective],
463
+ host: {
464
+ role: 'separator',
465
+ '[attr.aria-orientation]': "'horizontal'"
466
+ }
467
+ }]
468
+ }] });
469
+
120
470
  /**
121
471
  * Generated bundle index. Do not edit.
122
472
  */
123
473
 
124
- export { RdxDropdownMenuContentDirective, RdxDropdownMenuItemDirective, RdxDropdownMenuLabelDirective, RdxDropdownMenuSeparatorDirective, RdxDropdownMenuTriggerDirective };
474
+ export { DropdownAlign, DropdownSide, RdxDropdownMenuContentDirective, RdxDropdownMenuItemCheckboxDirective, RdxDropdownMenuItemDirective, RdxDropdownMenuItemIndicatorDirective, RdxDropdownMenuItemRadioDirective, RdxDropdownMenuItemRadioGroupDirective, RdxDropdownMenuLabelDirective, RdxDropdownMenuSelectable, RdxDropdownMenuSeparatorDirective, RdxDropdownMenuTriggerDirective, mapRdxAlignToCdkPosition };
125
475
  //# sourceMappingURL=radix-ng-primitives-dropdown-menu.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"radix-ng-primitives-dropdown-menu.mjs","sources":["../../../packages/primitives/dropdown-menu/src/dropdown-menu-trigger.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-item.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-separator.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-content.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-label.directive.ts","../../../packages/primitives/dropdown-menu/radix-ng-primitives-dropdown-menu.ts"],"sourcesContent":["import { BooleanInput } from '@angular/cdk/coercion';\nimport { CdkMenuTrigger } from '@angular/cdk/menu';\nimport { booleanAttribute, Directive, inject, input } from '@angular/core';\nimport { outputFromObservable } from '@angular/core/rxjs-interop';\n\n@Directive({\n selector: '[DropdownMenuTrigger]',\n standalone: true,\n hostDirectives: [\n { directive: CdkMenuTrigger, inputs: ['cdkMenuTriggerFor: DropdownMenuTrigger'] }\n ],\n host: {\n type: 'button',\n '[attr.aria-haspopup]': \"'menu'\",\n '[attr.aria-expanded]': 'cdkMenuTrigger.isOpen()',\n '[attr.data-state]': \"cdkMenuTrigger.isOpen() ? 'open': 'closed'\",\n '[attr.data-disabled]': \"disabled() ? '' : undefined\",\n '[disabled]': 'disabled()',\n\n '(pointerdown)': 'onPointerDown($event)'\n }\n})\nexport class RdxDropdownMenuTriggerDirective {\n protected readonly cdkMenuTrigger = inject(CdkMenuTrigger, { host: true });\n\n readonly disabled = input<boolean, BooleanInput>(false, {\n transform: booleanAttribute\n });\n\n /*\n * Event handler called when the open state of the dropdown menu changes.\n * // TODO: mv to RootMenuDropdown\n */\n onOpenChange = outputFromObservable(this.cdkMenuTrigger?.opened);\n\n onPointerDown($event: MouseEvent) {\n // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)\n // but not when the control key is pressed (avoiding MacOS right click)\n if (!this.disabled() && $event.button === 0 && !$event.ctrlKey) {\n /* empty */\n if (!this.cdkMenuTrigger.isOpen()) {\n // prevent trigger focusing when opening\n // this allows the content to be given focus without competition\n $event.preventDefault();\n }\n }\n }\n}\n","import { BooleanInput } from '@angular/cdk/coercion';\nimport { booleanAttribute, Directive, input } from '@angular/core';\n\nimport { RdxMenuItemDirective } from '@radix-ng/primitives/menu';\n\n@Directive({\n selector: '[DropdownMenuItem]',\n standalone: true,\n hostDirectives: [{ directive: RdxMenuItemDirective, inputs: ['rdxDisabled: disabled '] }]\n})\nexport class RdxDropdownMenuItemDirective {\n /*\n * When true, prevents the user from interacting with the item.\n */\n readonly disabled = input<boolean, BooleanInput>(false, {\n transform: booleanAttribute,\n alias: 'rdxDisabled'\n });\n}\n","import { Directive } from '@angular/core';\n\nimport { RdxMenuSeparatorDirective } from '@radix-ng/primitives/menu';\n\n@Directive({\n selector: '[DropdownMenuSeparator]',\n standalone: true,\n hostDirectives: [RdxMenuSeparatorDirective],\n host: {\n role: 'separator',\n '[attr.aria-orientation]': \"'horizontal'\"\n }\n})\nexport class RdxDropdownMenuSeparatorDirective {}\n","import { Directive } from '@angular/core';\n\nimport { RdxMenuContentDirective } from '@radix-ng/primitives/menu';\n\n@Directive({\n selector: '[DropdownMenuContent]',\n standalone: true,\n hostDirectives: [RdxMenuContentDirective]\n})\nexport class RdxDropdownMenuContentDirective {}\n","import { Directive } from '@angular/core';\n\n@Directive({\n selector: 'div[DropdownMenuLabel]',\n standalone: true\n})\nexport class RdxDropdownMenuLabelDirective {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;MAsBa,+BAA+B,CAAA;AAjB5C,IAAA,WAAA,GAAA;QAkBuB,IAAc,CAAA,cAAA,GAAG,MAAM,CAAC,cAAc,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;AAElE,QAAA,IAAA,CAAA,QAAQ,GAAG,KAAK,CAAwB,KAAK,EAAE;AACpD,YAAA,SAAS,EAAE,gBAAgB;AAC9B,SAAA,CAAC,CAAC;AAEH;;;AAGG;QACH,IAAY,CAAA,YAAA,GAAG,oBAAoB,CAAC,IAAI,CAAC,cAAc,EAAE,MAAM,CAAC,CAAC;AAcpE,KAAA;AA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A,EAAA,SAAA,EAAAA,IAAA,CAAA,uBAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA;;2FAA/B,+BAA+B,EAAA,UAAA,EAAA,CAAA;kBAL3C,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,uBAAuB;AACjC,oBAAA,UAAU,EAAE,IAAI;oBAChB,cAAc,EAAE,CAAC,uBAAuB,CAAC;AAC5C,iBAAA,CAAA;;;MCFY,6BAA6B,CAAA;8GAA7B,6BAA6B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;kGAA7B,6BAA6B,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,wBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA;;2FAA7B,6BAA6B,EAAA,UAAA,EAAA,CAAA;kBAJzC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,wBAAwB;AAClC,oBAAA,UAAU,EAAE,IAAI;AACnB,iBAAA,CAAA;;;ACLD;;AAEG;;;;"}
1
+ {"version":3,"file":"radix-ng-primitives-dropdown-menu.mjs","sources":["../../../packages/primitives/dropdown-menu/src/dropdown-menu-trigger.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-content.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-item.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-item-selectable.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-item-checkbox.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-item-indicator.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-item-radio-group.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-item-radio.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-label.directive.ts","../../../packages/primitives/dropdown-menu/src/dropdown-menu-separator.directive.ts","../../../packages/primitives/dropdown-menu/radix-ng-primitives-dropdown-menu.ts"],"sourcesContent":["import { BooleanInput } from '@angular/cdk/coercion';\nimport { CdkMenuTrigger } from '@angular/cdk/menu';\nimport { ConnectedPosition, VerticalConnectionPos } from '@angular/cdk/overlay';\nimport { booleanAttribute, Directive, inject, Input, input, numberAttribute } from '@angular/core';\nimport { outputFromObservable } from '@angular/core/rxjs-interop';\n\nexport enum DropdownSide {\n Top = 'top',\n Right = 'right',\n Bottom = 'bottom',\n Left = 'left'\n}\n\nexport enum DropdownAlign {\n Start = 'start',\n Center = 'center',\n End = 'end'\n}\n\nexport const mapRdxAlignToCdkPosition = {\n start: 'top',\n center: 'center',\n end: 'bottom'\n};\n\nconst dropdownPositions: Record<DropdownSide, ConnectedPosition> = {\n top: {\n originX: 'start',\n originY: 'top',\n overlayX: 'start',\n overlayY: 'bottom',\n offsetX: 0,\n offsetY: 0\n },\n right: {\n originX: 'end',\n originY: 'top',\n overlayX: 'start',\n overlayY: 'top',\n offsetX: 0,\n offsetY: 0\n },\n bottom: {\n originX: 'start',\n originY: 'bottom',\n overlayX: 'start',\n overlayY: 'top',\n offsetX: 0,\n offsetY: 0\n },\n left: {\n originX: 'start',\n originY: 'top',\n overlayX: 'end',\n overlayY: 'top',\n offsetX: 0,\n offsetY: 0\n }\n};\n\n@Directive({\n selector: '[rdxDropdownMenuTrigger]',\n standalone: true,\n hostDirectives: [\n {\n directive: CdkMenuTrigger,\n inputs: ['cdkMenuTriggerFor: rdxDropdownMenuTrigger']\n }\n ],\n host: {\n type: 'button',\n '[attr.aria-haspopup]': \"'menu'\",\n '[attr.aria-expanded]': 'cdkMenuTrigger.isOpen()',\n '[attr.data-state]': \"cdkMenuTrigger.isOpen() ? 'open': 'closed'\",\n '[attr.data-disabled]': \"disabled() ? '' : undefined\",\n '[disabled]': 'disabled()',\n\n '(pointerdown)': 'onPointerDown($event)'\n }\n})\nexport class RdxDropdownMenuTriggerDirective {\n protected readonly cdkMenuTrigger = inject(CdkMenuTrigger, { host: true });\n\n readonly disabled = input<boolean, BooleanInput>(false, {\n transform: booleanAttribute\n });\n\n @Input()\n set side(value: DropdownSide) {\n if (!Object.values(DropdownSide).includes(value)) {\n throw new Error(`Unknown side: ${value}`);\n }\n\n this._side = value;\n\n this.cdkMenuTrigger.menuPosition[0] = dropdownPositions[value];\n }\n\n get side() {\n return this._side;\n }\n\n private _side: DropdownSide = DropdownSide.Bottom;\n\n @Input()\n set align(value: DropdownAlign) {\n if (!Object.values(DropdownAlign).includes(value)) {\n throw new Error(`Unknown align: ${value}`);\n }\n\n this._align = value;\n\n if (this.isVertical) {\n this.defaultPosition.overlayX = this.defaultPosition.originX = value;\n } else {\n this.defaultPosition.overlayY = this.defaultPosition.originY = mapRdxAlignToCdkPosition[\n value\n ] as VerticalConnectionPos;\n }\n }\n\n get align() {\n return this._align;\n }\n\n private _align: DropdownAlign = DropdownAlign.Start;\n\n @Input({ transform: numberAttribute })\n set sideOffset(value: number) {\n // todo need invert value for top and left\n if (this.isVertical) {\n this.defaultPosition.offsetY = value;\n } else {\n this.defaultPosition.offsetX = value;\n }\n }\n\n @Input({ transform: numberAttribute })\n set alignOffset(value: number) {\n // todo need invert value for top and left\n if (this.isVertical) {\n this.defaultPosition.offsetX = value;\n } else {\n this.defaultPosition.offsetY = value;\n }\n }\n\n get isVertical(): boolean {\n return this._side === DropdownSide.Top || this._side === DropdownSide.Bottom;\n }\n\n get defaultPosition(): ConnectedPosition {\n return this.cdkMenuTrigger.menuPosition[0];\n }\n\n onOpenChange = outputFromObservable(this.cdkMenuTrigger?.opened);\n\n constructor() {\n // todo priority\n this.cdkMenuTrigger.menuPosition = [\n { ...dropdownPositions[DropdownSide.Bottom] }];\n }\n\n onPointerDown($event: MouseEvent) {\n // only call handler if it's the left button (mousedown gets triggered by all mouse buttons)\n // but not when the control key is pressed (avoiding MacOS right click)\n if (!this.disabled() && $event.button === 0 && !$event.ctrlKey) {\n /* empty */\n if (!this.cdkMenuTrigger.isOpen()) {\n // prevent trigger focusing when opening\n // this allows the content to be given focus without competition\n $event.preventDefault();\n }\n }\n }\n}\n","import { CdkMenu, CdkMenuItem, CdkMenuTrigger, CdkTargetMenuAim } from '@angular/cdk/menu';\nimport { Directive, inject } from '@angular/core';\nimport { pairwise, startWith, Subject } from 'rxjs';\nimport { RdxDropdownMenuItemDirective } from './dropdown-menu-item.directive';\nimport { RdxDropdownMenuTriggerDirective } from './dropdown-menu-trigger.directive';\n\n@Directive({\n selector: '[rdxDropdownMenuContent]',\n standalone: true,\n hostDirectives: [CdkMenu, CdkTargetMenuAim],\n host: {\n '[attr.data-state]': \"cdkMenuTrigger.isOpen() ? 'open': 'closed'\",\n '[attr.data-align]': 'menuTrigger!.align',\n '[attr.data-side]': 'menuTrigger!.side',\n '[attr.data-orientation]': 'cdkMenu.orientation'\n }\n})\nexport class RdxDropdownMenuContentDirective {\n readonly highlighted = new Subject<RdxDropdownMenuItemDirective>();\n readonly cdkMenu = inject(CdkMenu);\n protected readonly cdkMenuTrigger = inject(CdkMenuTrigger, { host: true });\n protected readonly menuTrigger = inject(RdxDropdownMenuTriggerDirective, { optional: true });\n\n constructor() {\n this.highlighted.pipe(startWith(null), pairwise()).subscribe(([prev, item]) => {\n if (prev) {\n prev.highlighted = false;\n }\n\n if (item) {\n item.highlighted = true;\n }\n });\n }\n\n updateActiveItem(item: CdkMenuItem) {\n this.cdkMenu['keyManager'].updateActiveItem(item);\n }\n}\n","import { CdkMenuItem } from '@angular/cdk/menu';\nimport { booleanAttribute, Directive, ElementRef, EventEmitter, inject, Input, Output } from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\n\nimport { RdxDropdownMenuContentDirective } from './dropdown-menu-content.directive';\n\n@Directive({\n selector: '[rdxDropdownMenuItem]',\n standalone: true,\n host: {\n type: 'button',\n // todo horizontal ?\n '[attr.data-orientation]': '\"vertical\"',\n '[attr.data-highlighted]': 'highlighted ? \"\" : null',\n '[attr.data-disabled]': 'disabled ? \"\" : null',\n '[attr.disabled]': 'disabled ? \"\" : null',\n '(pointermove)': 'onPointerMove()',\n '(focus)': 'menu.highlighted.next(this)',\n '(keydown)': 'onKeydown($event)'\n },\n providers: [\n {\n provide: CdkMenuItem,\n useExisting: RdxDropdownMenuItemDirective\n }\n ]\n})\nexport class RdxDropdownMenuItemDirective extends CdkMenuItem {\n protected readonly menu = inject(RdxDropdownMenuContentDirective);\n protected readonly nativeElement = inject(ElementRef).nativeElement;\n\n highlighted = false;\n\n @Input({ transform: booleanAttribute }) override disabled: boolean = false;\n\n @Output() readonly onSelect = new EventEmitter<void>();\n\n constructor() {\n super();\n\n this.menu.highlighted.pipe(takeUntilDestroyed()).subscribe((value) => {\n if (value !== this) {\n this.highlighted = false;\n }\n });\n\n this.triggered.subscribe(this.onSelect);\n }\n\n protected onPointerMove() {\n this.nativeElement.focus({ preventScroll: true });\n this.menu.updateActiveItem(this);\n }\n\n protected onKeydown(event: KeyboardEvent) {\n if (this.nativeElement.tagName !== 'BUTTON' && ['Enter', ' '].includes(event.key)) {\n event.preventDefault();\n }\n }\n}\n","import { booleanAttribute, Directive, EventEmitter, Input, Output } from '@angular/core';\nimport { RdxDropdownMenuItemDirective } from './dropdown-menu-item.directive';\n\n/** Base class providing checked state for selectable DropdownMenuItems. */\n@Directive({\n standalone: true,\n host: {\n '[attr.aria-checked]': '!!checked',\n '[attr.aria-disabled]': 'disabled || null',\n '[attr.data-state]': 'checked ? \"checked\" : \"unchecked\"'\n }\n})\nexport class RdxDropdownMenuSelectable extends RdxDropdownMenuItemDirective {\n /** Whether the element is checked */\n @Input({ transform: booleanAttribute }) checked: boolean = false;\n\n @Output() readonly checkedChange = new EventEmitter<boolean>();\n}\n","import { CdkMenuItem } from '@angular/cdk/menu';\nimport { Directive } from '@angular/core';\nimport { RdxDropdownMenuSelectable } from './dropdown-menu-item-selectable';\nimport { RdxDropdownMenuItemDirective } from './dropdown-menu-item.directive';\n\n@Directive({\n selector: '[rdxDropdownMenuItemCheckbox]',\n standalone: true,\n host: {\n role: 'menuitemcheckbox'\n },\n providers: [\n { provide: RdxDropdownMenuSelectable, useExisting: RdxDropdownMenuItemCheckboxDirective },\n { provide: RdxDropdownMenuItemDirective, useExisting: RdxDropdownMenuSelectable },\n { provide: CdkMenuItem, useExisting: RdxDropdownMenuItemDirective }\n ]\n})\nexport class RdxDropdownMenuItemCheckboxDirective extends RdxDropdownMenuSelectable {\n override trigger(options?: { keepOpen: boolean }) {\n if (!this.disabled) {\n this.checked = !this.checked;\n\n this.checkedChange.emit(this.checked);\n }\n\n super.trigger(options);\n }\n}\n","import { Directive, inject } from '@angular/core';\nimport { RdxDropdownMenuSelectable } from './dropdown-menu-item-selectable';\n\n@Directive({\n selector: '[rdxDropdownMenuItemIndicator]',\n standalone: true,\n host: {\n '[style.display]': \"item.checked ? 'block' : 'none'\",\n '[attr.data-state]': \"item.checked ? 'checked' : 'unchecked'\"\n }\n})\nexport class RdxDropdownMenuItemIndicatorDirective {\n item = inject(RdxDropdownMenuSelectable);\n}\n","import { UniqueSelectionDispatcher } from '@angular/cdk/collections';\nimport { AfterContentInit, Directive, EventEmitter, inject, Input, Output } from '@angular/core';\n\n@Directive({\n selector: '[rdxDropdownMenuItemRadioGroup]',\n standalone: true,\n host: {\n role: 'group'\n },\n providers: [{ provide: UniqueSelectionDispatcher, useClass: UniqueSelectionDispatcher }]\n})\nexport class RdxDropdownMenuItemRadioGroupDirective<T> implements AfterContentInit {\n private readonly selectionDispatcher = inject(UniqueSelectionDispatcher);\n\n @Input()\n set value(id: T | null) {\n this._value = id;\n }\n\n get value(): T | null {\n return this._value;\n }\n\n private _value: T | null = null;\n\n @Output() readonly valueChange = new EventEmitter();\n\n ngAfterContentInit(): void {\n this.selectionDispatcher.notify(this.value as string, '');\n }\n}\n","import { UniqueSelectionDispatcher } from '@angular/cdk/collections';\nimport { CdkMenuItem } from '@angular/cdk/menu';\nimport { AfterContentInit, Directive, inject, Input, OnDestroy } from '@angular/core';\nimport { RdxDropdownMenuItemRadioGroupDirective } from './dropdown-menu-item-radio-group.directive';\nimport { RdxDropdownMenuSelectable } from './dropdown-menu-item-selectable';\nimport { RdxDropdownMenuItemDirective } from './dropdown-menu-item.directive';\n\n/** Counter used to set a unique id and name for a selectable item */\nlet nextId = 0;\n\n@Directive({\n selector: '[rdxDropdownMenuItemRadio]',\n standalone: true,\n host: {\n role: 'menuitemradio'\n },\n providers: [\n { provide: RdxDropdownMenuSelectable, useExisting: RdxDropdownMenuItemRadioDirective },\n { provide: RdxDropdownMenuItemDirective, useExisting: RdxDropdownMenuSelectable },\n { provide: CdkMenuItem, useExisting: RdxDropdownMenuItemDirective }\n ]\n})\nexport class RdxDropdownMenuItemRadioDirective\n extends RdxDropdownMenuSelectable\n implements AfterContentInit, OnDestroy\n{\n /** The unique selection dispatcher for this radio's `RdxDropdownMenuItemRadioGroupDirective`. */\n private readonly selectionDispatcher = inject(UniqueSelectionDispatcher);\n\n private readonly group = inject(RdxDropdownMenuItemRadioGroupDirective);\n\n @Input()\n get value() {\n return this._value || this.id;\n }\n\n set value(value: string) {\n this._value = value;\n }\n\n private _value: string | undefined;\n\n /** An ID to identify this radio item to the `UniqueSelectionDispatcher`. */\n private id = `${nextId++}`;\n\n private removeDispatcherListener!: () => void;\n\n constructor() {\n super();\n\n this.triggered.subscribe(() => {\n if (!this.disabled) {\n this.selectionDispatcher.notify(this.value, '');\n\n this.group.valueChange.emit(this.value);\n }\n });\n }\n\n ngAfterContentInit() {\n this.removeDispatcherListener = this.selectionDispatcher.listen((id: string) => {\n this.checked = this.value === id;\n });\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n this.removeDispatcherListener();\n }\n}\n","import { Directive } from '@angular/core';\n\n@Directive({\n selector: '[rdxDropdownMenuLabel]',\n standalone: true\n})\nexport class RdxDropdownMenuLabelDirective {}\n","import { Directive } from '@angular/core';\nimport { RdxSeparatorRootDirective } from '@radix-ng/primitives/separator';\n\n@Directive({\n selector: '[rdxDropdownMenuSeparator]',\n standalone: true,\n hostDirectives: [RdxSeparatorRootDirective],\n host: {\n role: 'separator',\n '[attr.aria-orientation]': \"'horizontal'\"\n }\n})\nexport class RdxDropdownMenuSeparatorDirective {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;IAMY,aAKX;AALD,CAAA,UAAY,YAAY,EAAA;AACpB,IAAA,YAAA,CAAA,KAAA,CAAA,GAAA,KAAW,CAAA;AACX,IAAA,YAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,YAAA,CAAA,QAAA,CAAA,GAAA,QAAiB,CAAA;AACjB,IAAA,YAAA,CAAA,MAAA,CAAA,GAAA,MAAa,CAAA;AACjB,CAAC,EALW,YAAY,KAAZ,YAAY,GAKvB,EAAA,CAAA,CAAA,CAAA;IAEW,cAIX;AAJD,CAAA,UAAY,aAAa,EAAA;AACrB,IAAA,aAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,aAAA,CAAA,QAAA,CAAA,GAAA,QAAiB,CAAA;AACjB,IAAA,aAAA,CAAA,KAAA,CAAA,GAAA,KAAW,CAAA;AACf,CAAC,EAJW,aAAa,KAAb,aAAa,GAIxB,EAAA,CAAA,CAAA,CAAA;AAEY,MAAA,wBAAwB,GAAG;AACpC,IAAA,KAAK,EAAE,KAAK;AACZ,IAAA,MAAM,EAAE,QAAQ;AAChB,IAAA,GAAG,EAAE,QAAQ;EACf;AAEF,MAAM,iBAAiB,GAA4C;AAC/D,IAAA,GAAG,EAAE;AACD,QAAA,OAAO,EAAE,OAAO;AAChB,QAAA,OAAO,EAAE,KAAK;AACd,QAAA,QAAQ,EAAE,OAAO;AACjB,QAAA,QAAQ,EAAE,QAAQ;AAClB,QAAA,OAAO,EAAE,CAAC;AACV,QAAA,OAAO,EAAE,CAAC;AACb,KAAA;AACD,IAAA,KAAK,EAAE;AACH,QAAA,OAAO,E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