@radix-ng/primitives 0.7.2 → 0.8.2
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/accordion/README.md +1 -0
- package/accordion/index.d.ts +5 -0
- package/accordion/src/accordion-content.directive.d.ts +64 -0
- package/accordion/src/accordion-header.directive.d.ts +23 -0
- package/accordion/src/accordion-item.directive.d.ts +36 -0
- package/accordion/src/accordion-root.directive.d.ts +57 -0
- package/accordion/src/accordion-trigger.directive.d.ts +31 -0
- package/checkbox/index.d.ts +2 -0
- package/checkbox/src/checkbox-button.directive.d.ts +8 -0
- package/checkbox/src/checkbox-indicator.directive.d.ts +1 -1
- package/checkbox/src/checkbox-input.directive.d.ts +9 -0
- package/checkbox/src/checkbox.directive.d.ts +7 -5
- package/dropdown-menu/README.md +1 -0
- package/dropdown-menu/index.d.ts +5 -0
- package/dropdown-menu/src/dropdown-menu-content.directive.d.ts +6 -0
- package/dropdown-menu/src/dropdown-menu-item.directive.d.ts +8 -0
- package/dropdown-menu/src/dropdown-menu-label.directive.d.ts +5 -0
- package/dropdown-menu/src/dropdown-menu-separator.directive.d.ts +6 -0
- package/dropdown-menu/src/dropdown-menu-trigger.directive.d.ts +12 -0
- package/esm2022/accordion/index.mjs +6 -0
- package/esm2022/accordion/radix-ng-primitives-accordion.mjs +5 -0
- package/esm2022/accordion/src/accordion-content.directive.mjs +139 -0
- package/esm2022/accordion/src/accordion-header.directive.mjs +44 -0
- package/esm2022/accordion/src/accordion-item.directive.mjs +75 -0
- package/esm2022/accordion/src/accordion-root.directive.mjs +120 -0
- package/esm2022/accordion/src/accordion-trigger.directive.mjs +61 -0
- package/esm2022/checkbox/index.mjs +3 -1
- package/esm2022/checkbox/src/checkbox-button.directive.mjs +33 -0
- package/esm2022/checkbox/src/checkbox-indicator.directive.mjs +4 -3
- package/esm2022/checkbox/src/checkbox-input.directive.mjs +41 -0
- package/esm2022/checkbox/src/checkbox.directive.mjs +16 -20
- package/esm2022/dropdown-menu/index.mjs +6 -0
- package/esm2022/dropdown-menu/radix-ng-primitives-dropdown-menu.mjs +5 -0
- package/esm2022/dropdown-menu/src/dropdown-menu-content.directive.mjs +17 -0
- package/esm2022/dropdown-menu/src/dropdown-menu-item.directive.mjs +26 -0
- package/esm2022/dropdown-menu/src/dropdown-menu-label.directive.mjs +14 -0
- package/esm2022/dropdown-menu/src/dropdown-menu-separator.directive.mjs +21 -0
- package/esm2022/dropdown-menu/src/dropdown-menu-trigger.directive.mjs +52 -0
- package/esm2022/label/src/label-root.directive.mjs +7 -8
- package/esm2022/menu/src/menu-item.directive.mjs +10 -4
- package/esm2022/menubar/src/menubar-trigger.directive.mjs +3 -3
- package/esm2022/radio/src/radio-item.directive.mjs +1 -2
- package/esm2022/switch/index.mjs +2 -1
- package/esm2022/switch/src/switch-input.directive.mjs +8 -6
- package/esm2022/switch/src/switch-root.directive.mjs +42 -18
- package/esm2022/switch/src/switch-thumb.directive.mjs +3 -3
- package/esm2022/tabs/index.mjs +38 -0
- package/esm2022/tabs/radix-ng-primitives-tabs.mjs +5 -0
- package/esm2022/tabs/src/tabs-content.directive.mjs +29 -0
- package/esm2022/tabs/src/tabs-context.service.mjs +43 -0
- package/esm2022/tabs/src/tabs-list.directive.mjs +23 -0
- package/esm2022/tabs/src/tabs-root.directive.mjs +54 -0
- package/esm2022/tabs/src/tabs-trigger.directive.mjs +52 -0
- package/esm2022/toggle-group/src/toggle-group-button.directive.mjs +10 -1
- package/esm2022/toggle-group/src/toggle-group-multi.directive.mjs +17 -7
- package/fesm2022/radix-ng-primitives-accordion.mjs +431 -0
- package/fesm2022/radix-ng-primitives-accordion.mjs.map +1 -0
- package/fesm2022/radix-ng-primitives-checkbox.mjs +87 -22
- package/fesm2022/radix-ng-primitives-checkbox.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-dropdown-menu.mjs +125 -0
- package/fesm2022/radix-ng-primitives-dropdown-menu.mjs.map +1 -0
- package/fesm2022/radix-ng-primitives-label.mjs +6 -7
- package/fesm2022/radix-ng-primitives-label.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-menu.mjs +9 -3
- package/fesm2022/radix-ng-primitives-menu.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-menubar.mjs +2 -2
- package/fesm2022/radix-ng-primitives-menubar.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-radio.mjs +0 -1
- package/fesm2022/radix-ng-primitives-radio.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-switch.mjs +50 -24
- package/fesm2022/radix-ng-primitives-switch.mjs.map +1 -1
- package/fesm2022/radix-ng-primitives-tabs.mjs +222 -0
- package/fesm2022/radix-ng-primitives-tabs.mjs.map +1 -0
- package/fesm2022/radix-ng-primitives-toggle-group.mjs +25 -6
- package/fesm2022/radix-ng-primitives-toggle-group.mjs.map +1 -1
- package/label/src/label-root.directive.d.ts +3 -2
- package/menu/README.md +1 -0
- package/menu/src/menu-item.directive.d.ts +2 -1
- package/package.json +19 -1
- package/switch/index.d.ts +1 -0
- package/switch/src/switch-root.directive.d.ts +26 -9
- package/tabs/index.d.ts +15 -0
- package/tabs/src/tabs-content.directive.d.ts +8 -0
- package/tabs/src/tabs-context.service.d.ts +22 -0
- package/tabs/src/tabs-list.directive.d.ts +6 -0
- package/tabs/src/tabs-root.directive.d.ts +37 -0
- package/tabs/src/tabs-trigger.directive.d.ts +19 -0
- package/toggle-group/src/toggle-group-button.directive.d.ts +9 -0
- package/toggle-group/src/toggle-group-multi.directive.d.ts +19 -6
@@ -0,0 +1,431 @@
|
|
1
|
+
import * as i0 from '@angular/core';
|
2
|
+
import { InjectionToken, inject, ElementRef, signal, input, effect, Directive, contentChild, Input, contentChildren } from '@angular/core';
|
3
|
+
import * as i1 from '@angular/cdk/accordion';
|
4
|
+
import { CdkAccordionItem, CdkAccordion } from '@angular/cdk/accordion';
|
5
|
+
import { animationFrameScheduler } from 'rxjs';
|
6
|
+
|
7
|
+
const RdxAccordionContentToken = new InjectionToken('RdxAccordionContentToken');
|
8
|
+
class RdxAccordionContentDirective {
|
9
|
+
constructor() {
|
10
|
+
/**
|
11
|
+
* @ignore
|
12
|
+
*/
|
13
|
+
this.elementRef = inject(ElementRef);
|
14
|
+
/**
|
15
|
+
* @ignore
|
16
|
+
*/
|
17
|
+
this.initialized = signal(false);
|
18
|
+
/**
|
19
|
+
* Current item state
|
20
|
+
*/
|
21
|
+
this.state = signal('closed');
|
22
|
+
/**
|
23
|
+
* When true, prevents the user from interacting with the accordion and all its items.
|
24
|
+
*/
|
25
|
+
this.disabled = input(false);
|
26
|
+
/**
|
27
|
+
* @ignore
|
28
|
+
*/
|
29
|
+
this.accordionItem = inject(CdkAccordionItem);
|
30
|
+
/**
|
31
|
+
* @ignore
|
32
|
+
*/
|
33
|
+
this.orientation = 'vertical';
|
34
|
+
effect(() => {
|
35
|
+
if (this.state()) {
|
36
|
+
this.setPresence();
|
37
|
+
}
|
38
|
+
});
|
39
|
+
}
|
40
|
+
/**
|
41
|
+
* @ignore
|
42
|
+
*/
|
43
|
+
ngOnInit() {
|
44
|
+
this.togglePresence();
|
45
|
+
}
|
46
|
+
/**
|
47
|
+
* @ignore
|
48
|
+
*/
|
49
|
+
setOpen(state) {
|
50
|
+
if (this.disabled()) {
|
51
|
+
return;
|
52
|
+
}
|
53
|
+
if (state === undefined) {
|
54
|
+
this.state.update(() => (this.state() === 'open' ? 'closed' : 'open'));
|
55
|
+
}
|
56
|
+
else {
|
57
|
+
this.state.update(() => state);
|
58
|
+
}
|
59
|
+
}
|
60
|
+
/**
|
61
|
+
* @ignore
|
62
|
+
*/
|
63
|
+
initialize() {
|
64
|
+
if (!this.initialized()) {
|
65
|
+
this.togglePresence();
|
66
|
+
animationFrameScheduler.schedule(() => {
|
67
|
+
this.elementRef.nativeElement
|
68
|
+
.getAnimations()
|
69
|
+
.forEach((animation) => animation.cancel());
|
70
|
+
this.initialized.set(true);
|
71
|
+
});
|
72
|
+
}
|
73
|
+
}
|
74
|
+
/**
|
75
|
+
* @ignore
|
76
|
+
*/
|
77
|
+
setPresence() {
|
78
|
+
if (!this.initialized()) {
|
79
|
+
this.initialize();
|
80
|
+
return;
|
81
|
+
}
|
82
|
+
animationFrameScheduler.schedule(() => {
|
83
|
+
const animations = this.elementRef.nativeElement.getAnimations();
|
84
|
+
const hidden = this.elementRef.nativeElement.hasAttribute('hidden');
|
85
|
+
if (hidden) {
|
86
|
+
this.show();
|
87
|
+
const rect = this.elementRef.nativeElement.getBoundingClientRect();
|
88
|
+
const height = `${this.elementRef.nativeElement.scrollHeight /*rect.height*/}px`;
|
89
|
+
const width = `${rect.width}px`;
|
90
|
+
this.elementRef.nativeElement.style.setProperty('--radix-accordion-content-height', height);
|
91
|
+
this.elementRef.nativeElement.style.setProperty('--radix-accordion-content-width', width);
|
92
|
+
this.hide();
|
93
|
+
}
|
94
|
+
Promise.all(animations.map((animation) => animation.finished)).then(() => {
|
95
|
+
this.togglePresence();
|
96
|
+
});
|
97
|
+
});
|
98
|
+
}
|
99
|
+
/**
|
100
|
+
* @ignore
|
101
|
+
*/
|
102
|
+
togglePresence() {
|
103
|
+
if (this.state() === 'open') {
|
104
|
+
this.show();
|
105
|
+
}
|
106
|
+
else {
|
107
|
+
this.hide();
|
108
|
+
}
|
109
|
+
}
|
110
|
+
/**
|
111
|
+
* @ignore
|
112
|
+
*/
|
113
|
+
show() {
|
114
|
+
this.elementRef.nativeElement.removeAttribute('hidden');
|
115
|
+
}
|
116
|
+
/**
|
117
|
+
* @ignore
|
118
|
+
*/
|
119
|
+
hide() {
|
120
|
+
this.elementRef.nativeElement.setAttribute('hidden', '');
|
121
|
+
}
|
122
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionContentDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
123
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "18.0.4", type: RdxAccordionContentDirective, isStandalone: true, selector: "[AccordionContent]", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-state": "state()", "attr.data-disabled": "disabled() ? \"\" : undefined", "attr.data-orientation": "orientation" } }, providers: [{ provide: RdxAccordionContentToken, useExisting: RdxAccordionContentDirective }], exportAs: ["AccordionContent"], hostDirectives: [{ directive: i1.CdkAccordionItem }], ngImport: i0 }); }
|
124
|
+
}
|
125
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionContentDirective, decorators: [{
|
126
|
+
type: Directive,
|
127
|
+
args: [{
|
128
|
+
selector: '[AccordionContent]',
|
129
|
+
standalone: true,
|
130
|
+
exportAs: 'AccordionContent',
|
131
|
+
providers: [{ provide: RdxAccordionContentToken, useExisting: RdxAccordionContentDirective }],
|
132
|
+
host: {
|
133
|
+
'[attr.data-state]': 'state()',
|
134
|
+
'[attr.data-disabled]': 'disabled() ? "" : undefined',
|
135
|
+
'[attr.data-orientation]': 'orientation'
|
136
|
+
},
|
137
|
+
hostDirectives: [CdkAccordionItem]
|
138
|
+
}]
|
139
|
+
}], ctorParameters: () => [] });
|
140
|
+
|
141
|
+
const RdxAccordionItemToken = new InjectionToken('RdxAccordionItemToken');
|
142
|
+
function injectAccordionItem() {
|
143
|
+
return inject(RdxAccordionItemDirective);
|
144
|
+
}
|
145
|
+
class RdxAccordionItemDirective {
|
146
|
+
constructor() {
|
147
|
+
/**
|
148
|
+
* @ignore
|
149
|
+
*/
|
150
|
+
this.accordionContent = contentChild.required(RdxAccordionContentToken);
|
151
|
+
/**
|
152
|
+
* Current item state
|
153
|
+
*/
|
154
|
+
this.state = signal('closed');
|
155
|
+
/**
|
156
|
+
* When true, prevents the user from interacting with the item.
|
157
|
+
*/
|
158
|
+
this.disabled = input(false);
|
159
|
+
/**
|
160
|
+
* @ignore
|
161
|
+
*/
|
162
|
+
this.orientation = 'vertical';
|
163
|
+
}
|
164
|
+
/**
|
165
|
+
* Changes current item state
|
166
|
+
*/
|
167
|
+
setOpen(state) {
|
168
|
+
if (this.disabled()) {
|
169
|
+
return;
|
170
|
+
}
|
171
|
+
if (state === undefined) {
|
172
|
+
this.state.update(() => (this.state() === 'open' ? 'closed' : 'open'));
|
173
|
+
}
|
174
|
+
else {
|
175
|
+
this.state.update(() => state);
|
176
|
+
}
|
177
|
+
this.accordionContent().setOpen(this.state());
|
178
|
+
}
|
179
|
+
/**
|
180
|
+
* @ignore
|
181
|
+
*/
|
182
|
+
setOrientation(orientation) {
|
183
|
+
this.orientation = orientation;
|
184
|
+
this.accordionContent().orientation = orientation;
|
185
|
+
}
|
186
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionItemDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
187
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.2.0", version: "18.0.4", type: RdxAccordionItemDirective, isStandalone: true, selector: "[AccordionItem]", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null } }, host: { properties: { "attr.data-state": "state()", "attr.data-disabled": "disabled() ? \"\" : undefined", "attr.data-orientation": "orientation" } }, providers: [
|
188
|
+
{ provide: RdxAccordionItemToken, useExisting: RdxAccordionItemDirective, multi: true }
|
189
|
+
], queries: [{ propertyName: "accordionContent", first: true, predicate: RdxAccordionContentToken, descendants: true, isSignal: true }], exportAs: ["AccordionItem"], hostDirectives: [{ directive: i1.CdkAccordion }], ngImport: i0 }); }
|
190
|
+
}
|
191
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionItemDirective, decorators: [{
|
192
|
+
type: Directive,
|
193
|
+
args: [{
|
194
|
+
selector: '[AccordionItem]',
|
195
|
+
standalone: true,
|
196
|
+
exportAs: 'AccordionItem',
|
197
|
+
providers: [
|
198
|
+
{ provide: RdxAccordionItemToken, useExisting: RdxAccordionItemDirective, multi: true }
|
199
|
+
],
|
200
|
+
host: {
|
201
|
+
'[attr.data-state]': 'state()',
|
202
|
+
'[attr.data-disabled]': 'disabled() ? "" : undefined',
|
203
|
+
'[attr.data-orientation]': 'orientation'
|
204
|
+
},
|
205
|
+
hostDirectives: [CdkAccordion]
|
206
|
+
}]
|
207
|
+
}], propDecorators: { value: [{
|
208
|
+
type: Input
|
209
|
+
}] } });
|
210
|
+
|
211
|
+
const RdxAccordionRootToken = new InjectionToken('RdxAccordionRootDirective');
|
212
|
+
function injectAccordionRoot() {
|
213
|
+
return inject(RdxAccordionRootDirective);
|
214
|
+
}
|
215
|
+
class RdxAccordionRootDirective {
|
216
|
+
constructor() {
|
217
|
+
/**
|
218
|
+
* @private
|
219
|
+
* @ignore
|
220
|
+
*/
|
221
|
+
this.accordionItems = contentChildren(RdxAccordionItemToken);
|
222
|
+
/**
|
223
|
+
* @private
|
224
|
+
* @ignore
|
225
|
+
*/
|
226
|
+
this._orientation = 'vertical';
|
227
|
+
/**
|
228
|
+
* @private
|
229
|
+
* @ignore
|
230
|
+
*/
|
231
|
+
this._value = [];
|
232
|
+
/**
|
233
|
+
* The value of the item to expand when initially rendered and type is "single". Use when you do not need to control the state of the items.
|
234
|
+
*/
|
235
|
+
this.defaultValue = [];
|
236
|
+
/**
|
237
|
+
* Determines whether one or multiple items can be opened at the same time.
|
238
|
+
*/
|
239
|
+
this.type = 'single';
|
240
|
+
/**
|
241
|
+
* @ignore
|
242
|
+
*/
|
243
|
+
this.collapsible = true;
|
244
|
+
}
|
245
|
+
/**
|
246
|
+
* The controlled value of the item to expand
|
247
|
+
*/
|
248
|
+
set value(value) {
|
249
|
+
if (value !== undefined) {
|
250
|
+
this._value = Array.isArray(value) ? value : [value];
|
251
|
+
}
|
252
|
+
else {
|
253
|
+
this._value = [];
|
254
|
+
}
|
255
|
+
this.onValueChange(this._value);
|
256
|
+
}
|
257
|
+
/**
|
258
|
+
* The orientation of the accordion.
|
259
|
+
*/
|
260
|
+
set orientation(orientation) {
|
261
|
+
this._orientation = orientation ?? 'vertical';
|
262
|
+
this.accordionItems().forEach((accordionItem) => accordionItem.setOrientation(this._orientation));
|
263
|
+
}
|
264
|
+
/**
|
265
|
+
* @ignore
|
266
|
+
*/
|
267
|
+
ngOnInit() {
|
268
|
+
if (this.defaultValue) {
|
269
|
+
this.value = this.defaultValue;
|
270
|
+
}
|
271
|
+
}
|
272
|
+
/**
|
273
|
+
* @ignore
|
274
|
+
*/
|
275
|
+
onValueChange(value) {
|
276
|
+
if (this.type === 'single') {
|
277
|
+
const currentValue = value.length > 0 ? value[0] : undefined;
|
278
|
+
this.accordionItems().forEach((accordionItem) => {
|
279
|
+
if (accordionItem.value === currentValue) {
|
280
|
+
accordionItem.setOpen();
|
281
|
+
}
|
282
|
+
else {
|
283
|
+
accordionItem.setOpen('closed');
|
284
|
+
}
|
285
|
+
});
|
286
|
+
}
|
287
|
+
else {
|
288
|
+
value.forEach((valueItem) => {
|
289
|
+
this.accordionItems().forEach((accordionItem) => {
|
290
|
+
if (accordionItem.value === valueItem) {
|
291
|
+
accordionItem.setOpen();
|
292
|
+
}
|
293
|
+
});
|
294
|
+
});
|
295
|
+
}
|
296
|
+
}
|
297
|
+
/**
|
298
|
+
* @ignore
|
299
|
+
*/
|
300
|
+
getOrientation() {
|
301
|
+
return this._orientation;
|
302
|
+
}
|
303
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionRootDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
304
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.2.0", version: "18.0.4", type: RdxAccordionRootDirective, isStandalone: true, selector: "[AccordionRoot]", inputs: { defaultValue: "defaultValue", type: "type", collapsible: "collapsible", value: "value", orientation: "orientation" }, host: { properties: { "attr.data-orientation": "getOrientation()" } }, providers: [{ provide: RdxAccordionRootToken, useExisting: RdxAccordionRootDirective }], queries: [{ propertyName: "accordionItems", predicate: RdxAccordionItemToken, isSignal: true }], ngImport: i0 }); }
|
305
|
+
}
|
306
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionRootDirective, decorators: [{
|
307
|
+
type: Directive,
|
308
|
+
args: [{
|
309
|
+
selector: '[AccordionRoot]',
|
310
|
+
standalone: true,
|
311
|
+
providers: [{ provide: RdxAccordionRootToken, useExisting: RdxAccordionRootDirective }],
|
312
|
+
host: {
|
313
|
+
'[attr.data-orientation]': 'getOrientation()'
|
314
|
+
}
|
315
|
+
}]
|
316
|
+
}], propDecorators: { defaultValue: [{
|
317
|
+
type: Input
|
318
|
+
}], type: [{
|
319
|
+
type: Input
|
320
|
+
}], collapsible: [{
|
321
|
+
type: Input
|
322
|
+
}], value: [{
|
323
|
+
type: Input
|
324
|
+
}], orientation: [{
|
325
|
+
type: Input
|
326
|
+
}] } });
|
327
|
+
|
328
|
+
class RdxAccordionHeaderDirective {
|
329
|
+
constructor() {
|
330
|
+
/**
|
331
|
+
* @ignore
|
332
|
+
*/
|
333
|
+
this.accordionItem = injectAccordionItem();
|
334
|
+
}
|
335
|
+
/**
|
336
|
+
* @ignore
|
337
|
+
*/
|
338
|
+
getState() {
|
339
|
+
return this.accordionItem.state();
|
340
|
+
}
|
341
|
+
/**
|
342
|
+
* @ignore
|
343
|
+
*/
|
344
|
+
getDisabled() {
|
345
|
+
return this.accordionItem.disabled() ? '' : undefined;
|
346
|
+
}
|
347
|
+
/**
|
348
|
+
* @ignore
|
349
|
+
*/
|
350
|
+
getOrientation() {
|
351
|
+
return this.accordionItem.orientation;
|
352
|
+
}
|
353
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionHeaderDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
354
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.0.4", type: RdxAccordionHeaderDirective, isStandalone: true, selector: "[AccordionHeader]", host: { properties: { "attr.data-state": "getState()", "attr.data-disabled": "getDisabled()", "attr.data-orientation": "getOrientation()" } }, ngImport: i0 }); }
|
355
|
+
}
|
356
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionHeaderDirective, decorators: [{
|
357
|
+
type: Directive,
|
358
|
+
args: [{
|
359
|
+
selector: '[AccordionHeader]',
|
360
|
+
standalone: true,
|
361
|
+
host: {
|
362
|
+
'[attr.data-state]': 'getState()',
|
363
|
+
'[attr.data-disabled]': 'getDisabled()',
|
364
|
+
'[attr.data-orientation]': 'getOrientation()'
|
365
|
+
}
|
366
|
+
}]
|
367
|
+
}] });
|
368
|
+
|
369
|
+
class RdxAccordionTriggerDirective {
|
370
|
+
constructor() {
|
371
|
+
/**
|
372
|
+
* @ignore
|
373
|
+
*/
|
374
|
+
this.accordionRoot = injectAccordionRoot();
|
375
|
+
/**
|
376
|
+
* @ignore
|
377
|
+
*/
|
378
|
+
this.accordionItem = injectAccordionItem();
|
379
|
+
}
|
380
|
+
/**
|
381
|
+
* Fires when trigger clicked
|
382
|
+
*/
|
383
|
+
onClick() {
|
384
|
+
if (!this.accordionRoot.collapsible) {
|
385
|
+
return;
|
386
|
+
}
|
387
|
+
if (this.accordionItem.value) {
|
388
|
+
this.accordionRoot.value = [this.accordionItem.value];
|
389
|
+
}
|
390
|
+
}
|
391
|
+
/**
|
392
|
+
* @ignore
|
393
|
+
*/
|
394
|
+
getState() {
|
395
|
+
return this.accordionItem.state();
|
396
|
+
}
|
397
|
+
/**
|
398
|
+
* @ignore
|
399
|
+
*/
|
400
|
+
getDisabled() {
|
401
|
+
return this.accordionItem.disabled() || undefined;
|
402
|
+
}
|
403
|
+
/**
|
404
|
+
* @ignore
|
405
|
+
*/
|
406
|
+
getOrientation() {
|
407
|
+
return this.accordionRoot.getOrientation();
|
408
|
+
}
|
409
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
410
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.0.4", type: RdxAccordionTriggerDirective, isStandalone: true, selector: "[AccordionTrigger]", host: { listeners: { "click": "onClick()" }, properties: { "attr.data-state": "getState()", "attr.data-disabled": "getDisabled()", "attr.data-orientation": "getOrientation()" } }, ngImport: i0 }); }
|
411
|
+
}
|
412
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.0.4", ngImport: i0, type: RdxAccordionTriggerDirective, decorators: [{
|
413
|
+
type: Directive,
|
414
|
+
args: [{
|
415
|
+
selector: '[AccordionTrigger]',
|
416
|
+
standalone: true,
|
417
|
+
host: {
|
418
|
+
'(click)': 'onClick()',
|
419
|
+
'[attr.data-state]': 'getState()',
|
420
|
+
'[attr.data-disabled]': 'getDisabled()',
|
421
|
+
'[attr.data-orientation]': 'getOrientation()'
|
422
|
+
}
|
423
|
+
}]
|
424
|
+
}] });
|
425
|
+
|
426
|
+
/**
|
427
|
+
* Generated bundle index. Do not edit.
|
428
|
+
*/
|
429
|
+
|
430
|
+
export { RdxAccordionContentDirective, RdxAccordionContentToken, RdxAccordionHeaderDirective, RdxAccordionItemDirective, RdxAccordionItemToken, RdxAccordionRootDirective, RdxAccordionRootToken, RdxAccordionTriggerDirective, injectAccordionItem, injectAccordionRoot };
|
431
|
+
//# sourceMappingURL=radix-ng-primitives-accordion.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"radix-ng-primitives-accordion.mjs","sources":["../../../packages/primitives/accordion/src/accordion-content.directive.ts","../../../packages/primitives/accordion/src/accordion-item.directive.ts","../../../packages/primitives/accordion/src/accordion-root.directive.ts","../../../packages/primitives/accordion/src/accordion-header.directive.ts","../../../packages/primitives/accordion/src/accordion-trigger.directive.ts","../../../packages/primitives/accordion/radix-ng-primitives-accordion.ts"],"sourcesContent":["import { CdkAccordionItem } from '@angular/cdk/accordion';\nimport {\n Directive,\n effect,\n ElementRef,\n inject,\n InjectionToken,\n input,\n OnInit,\n signal\n} from '@angular/core';\nimport { animationFrameScheduler } from 'rxjs';\n\nimport { RdxAccordionItemState } from './accordion-item.directive';\nimport { RdxAccordionOrientation } from './accordion-root.directive';\n\nexport const RdxAccordionContentToken = new InjectionToken<RdxAccordionContentDirective>(\n 'RdxAccordionContentToken'\n);\n\n@Directive({\n selector: '[AccordionContent]',\n standalone: true,\n exportAs: 'AccordionContent',\n providers: [{ provide: RdxAccordionContentToken, useExisting: RdxAccordionContentDirective }],\n host: {\n '[attr.data-state]': 'state()',\n '[attr.data-disabled]': 'disabled() ? \"\" : undefined',\n '[attr.data-orientation]': 'orientation'\n },\n hostDirectives: [CdkAccordionItem]\n})\nexport class RdxAccordionContentDirective implements OnInit {\n /**\n * @ignore\n */\n private readonly elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\n /**\n * @ignore\n */\n private initialized = signal(false);\n /**\n * Current item state\n */\n state = signal<RdxAccordionItemState>('closed');\n /**\n * When true, prevents the user from interacting with the accordion and all its items.\n */\n disabled = input(false);\n /**\n * @ignore\n */\n accordionItem = inject(CdkAccordionItem);\n /**\n * @ignore\n */\n orientation: RdxAccordionOrientation = 'vertical';\n\n constructor() {\n effect(() => {\n if (this.state()) {\n this.setPresence();\n }\n });\n }\n\n /**\n * @ignore\n */\n ngOnInit(): void {\n this.togglePresence();\n }\n\n /**\n * @ignore\n */\n setOpen(state?: RdxAccordionItemState | undefined): void {\n if (this.disabled()) {\n return;\n }\n\n if (state === undefined) {\n this.state.update(() => (this.state() === 'open' ? 'closed' : 'open'));\n } else {\n this.state.update(() => state);\n }\n }\n\n /**\n * @ignore\n */\n private initialize(): void {\n if (!this.initialized()) {\n this.togglePresence();\n\n animationFrameScheduler.schedule(() => {\n this.elementRef.nativeElement\n .getAnimations()\n .forEach((animation) => animation.cancel());\n\n this.initialized.set(true);\n });\n }\n }\n\n /**\n * @ignore\n */\n private setPresence(): void {\n if (!this.initialized()) {\n this.initialize();\n\n return;\n }\n\n animationFrameScheduler.schedule(() => {\n const animations = this.elementRef.nativeElement.getAnimations();\n\n const hidden = this.elementRef.nativeElement.hasAttribute('hidden');\n\n if (hidden) {\n this.show();\n\n const rect = this.elementRef.nativeElement.getBoundingClientRect();\n const height = `${this.elementRef.nativeElement.scrollHeight /*rect.height*/}px`;\n const width = `${rect.width}px`;\n\n this.elementRef.nativeElement.style.setProperty(\n '--radix-accordion-content-height',\n height\n );\n\n this.elementRef.nativeElement.style.setProperty(\n '--radix-accordion-content-width',\n width\n );\n\n this.hide();\n }\n\n Promise.all(animations.map((animation) => animation.finished)).then(() => {\n this.togglePresence();\n });\n });\n }\n\n /**\n * @ignore\n */\n private togglePresence(): void {\n if (this.state() === 'open') {\n this.show();\n } else {\n this.hide();\n }\n }\n\n /**\n * @ignore\n */\n private show(): void {\n this.elementRef.nativeElement.removeAttribute('hidden');\n }\n\n /**\n * @ignore\n */\n private hide(): void {\n this.elementRef.nativeElement.setAttribute('hidden', '');\n }\n}\n","import { CdkAccordion } from '@angular/cdk/accordion';\nimport {\n contentChild,\n Directive,\n inject,\n InjectionToken,\n Input,\n input,\n signal\n} from '@angular/core';\n\nimport { RdxAccordionContentToken } from './accordion-content.directive';\nimport { RdxAccordionOrientation } from './accordion-root.directive';\n\nexport type RdxAccordionItemState = 'open' | 'closed';\n\nexport const RdxAccordionItemToken = new InjectionToken<RdxAccordionItemDirective>(\n 'RdxAccordionItemToken'\n);\n\nexport function injectAccordionItem(): RdxAccordionItemDirective {\n return inject(RdxAccordionItemDirective);\n}\n\n@Directive({\n selector: '[AccordionItem]',\n standalone: true,\n exportAs: 'AccordionItem',\n providers: [\n { provide: RdxAccordionItemToken, useExisting: RdxAccordionItemDirective, multi: true }\n ],\n host: {\n '[attr.data-state]': 'state()',\n '[attr.data-disabled]': 'disabled() ? \"\" : undefined',\n '[attr.data-orientation]': 'orientation'\n },\n hostDirectives: [CdkAccordion]\n})\nexport class RdxAccordionItemDirective {\n /**\n * @ignore\n */\n private accordionContent = contentChild.required(RdxAccordionContentToken);\n /**\n * Current item state\n */\n state = signal<RdxAccordionItemState>('closed');\n /**\n * When true, prevents the user from interacting with the item.\n */\n disabled = input(false);\n /**\n * @ignore\n */\n orientation: RdxAccordionOrientation = 'vertical';\n\n @Input() value?: string;\n\n /**\n * Changes current item state\n */\n setOpen(state?: RdxAccordionItemState) {\n if (this.disabled()) {\n return;\n }\n\n if (state === undefined) {\n this.state.update(() => (this.state() === 'open' ? 'closed' : 'open'));\n } else {\n this.state.update(() => state);\n }\n\n this.accordionContent().setOpen(this.state());\n }\n\n /**\n * @ignore\n */\n setOrientation(orientation: RdxAccordionOrientation) {\n this.orientation = orientation;\n\n this.accordionContent().orientation = orientation;\n }\n}\n","import { contentChildren, Directive, inject, InjectionToken, Input, OnInit } from '@angular/core';\n\nimport { RdxAccordionItemToken } from './accordion-item.directive';\n\nexport type RdxAccordionType = 'single' | 'multiple';\nexport type RdxAccordionOrientation = 'horizontal' | 'vertical';\n\nexport const RdxAccordionRootToken = new InjectionToken<RdxAccordionRootDirective>(\n 'RdxAccordionRootDirective'\n);\n\nexport function injectAccordionRoot(): RdxAccordionRootDirective {\n return inject(RdxAccordionRootDirective);\n}\n\n@Directive({\n selector: '[AccordionRoot]',\n standalone: true,\n providers: [{ provide: RdxAccordionRootToken, useExisting: RdxAccordionRootDirective }],\n host: {\n '[attr.data-orientation]': 'getOrientation()'\n }\n})\nexport class RdxAccordionRootDirective implements OnInit {\n /**\n * @private\n * @ignore\n */\n private readonly accordionItems = contentChildren(RdxAccordionItemToken);\n /**\n * @private\n * @ignore\n */\n private _orientation: RdxAccordionOrientation = 'vertical';\n /**\n * @private\n * @ignore\n */\n private _value: string[] = [];\n /**\n * The value of the item to expand when initially rendered and type is \"single\". Use when you do not need to control the state of the items.\n */\n @Input() defaultValue?: string[] = [];\n /**\n * Determines whether one or multiple items can be opened at the same time.\n */\n @Input() type: RdxAccordionType = 'single';\n /**\n * @ignore\n */\n @Input() collapsible = true;\n /**\n * The controlled value of the item to expand\n */\n @Input() set value(value: string | string[] | undefined) {\n if (value !== undefined) {\n this._value = Array.isArray(value) ? value : [value];\n } else {\n this._value = [];\n }\n\n this.onValueChange(this._value);\n }\n /**\n * The orientation of the accordion.\n */\n @Input() set orientation(orientation: RdxAccordionOrientation | undefined) {\n this._orientation = orientation ?? 'vertical';\n this.accordionItems().forEach((accordionItem) =>\n accordionItem.setOrientation(this._orientation)\n );\n }\n\n /**\n * @ignore\n */\n ngOnInit(): void {\n if (this.defaultValue) {\n this.value = this.defaultValue;\n }\n }\n\n /**\n * @ignore\n */\n onValueChange(value: string[]): void {\n if (this.type === 'single') {\n const currentValue = value.length > 0 ? value[0] : undefined;\n\n this.accordionItems().forEach((accordionItem) => {\n if (accordionItem.value === currentValue) {\n accordionItem.setOpen();\n } else {\n accordionItem.setOpen('closed');\n }\n });\n } else {\n value.forEach((valueItem) => {\n this.accordionItems().forEach((accordionItem) => {\n if (accordionItem.value === valueItem) {\n accordionItem.setOpen();\n }\n });\n });\n }\n }\n\n /**\n * @ignore\n */\n getOrientation(): RdxAccordionOrientation {\n return this._orientation;\n }\n}\n","import { Directive } from '@angular/core';\n\nimport { injectAccordionItem, RdxAccordionItemState } from './accordion-item.directive';\nimport { RdxAccordionOrientation } from './accordion-root.directive';\n\n@Directive({\n selector: '[AccordionHeader]',\n standalone: true,\n host: {\n '[attr.data-state]': 'getState()',\n '[attr.data-disabled]': 'getDisabled()',\n '[attr.data-orientation]': 'getOrientation()'\n }\n})\nexport class RdxAccordionHeaderDirective {\n /**\n * @ignore\n */\n private readonly accordionItem = injectAccordionItem();\n\n /**\n * @ignore\n */\n getState(): RdxAccordionItemState {\n return this.accordionItem.state();\n }\n\n /**\n * @ignore\n */\n getDisabled(): string | undefined {\n return this.accordionItem.disabled() ? '' : undefined;\n }\n\n /**\n * @ignore\n */\n getOrientation(): RdxAccordionOrientation {\n return this.accordionItem.orientation;\n }\n}\n","import { Directive } from '@angular/core';\n\nimport { injectAccordionItem, RdxAccordionItemState } from './accordion-item.directive';\nimport { injectAccordionRoot, RdxAccordionOrientation } from './accordion-root.directive';\n\n@Directive({\n selector: '[AccordionTrigger]',\n standalone: true,\n host: {\n '(click)': 'onClick()',\n '[attr.data-state]': 'getState()',\n '[attr.data-disabled]': 'getDisabled()',\n '[attr.data-orientation]': 'getOrientation()'\n }\n})\nexport class RdxAccordionTriggerDirective {\n /**\n * @ignore\n */\n private readonly accordionRoot = injectAccordionRoot();\n /**\n * @ignore\n */\n private readonly accordionItem = injectAccordionItem();\n\n /**\n * Fires when trigger clicked\n */\n onClick(): void {\n if (!this.accordionRoot.collapsible) {\n return;\n }\n\n if (this.accordionItem.value) {\n this.accordionRoot.value = [this.accordionItem.value];\n }\n }\n\n /**\n * @ignore\n */\n getState(): RdxAccordionItemState {\n return this.accordionItem.state();\n }\n\n /**\n * @ignore\n */\n getDisabled(): boolean | undefined {\n return this.accordionItem.disabled() || undefined;\n }\n\n /**\n * @ignore\n */\n getOrientation(): RdxAccordionOrientation {\n return this.accordionRoot.getOrientation();\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;MAgBa,wBAAwB,GAAG,IAAI,cAAc,CACtD,0BAA0B,EAC5B;MAcW,4BAA4B,CAAA;AA0BrC,IAAA,WAAA,GAAA;AAzBA;;AAEG;AACc,QAAA,IAAA,CAAA,UAAU,GAAG,MAAM,CAA0B,UAAU,CAAC,CAAC;AAC1E;;AAEG;AACK,QAAA,IAAA,CAAA,WAAW,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;AACpC;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