ng-primitives 0.35.0 → 0.37.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/a11y/visually-hidden/visually-hidden-state.d.ts +1 -1
- package/accordion/accordion/accordion-state.d.ts +1 -1
- package/accordion/accordion-item/accordion-item-state.d.ts +1 -1
- package/accordion/accordion-trigger/accordion-trigger.d.ts +4 -0
- package/avatar/avatar/avatar-state.d.ts +1 -1
- package/button/button/button-state.d.ts +1 -1
- package/checkbox/checkbox/checkbox-state.d.ts +1 -1
- package/date-picker/date-picker/date-picker-state.d.ts +1 -1
- package/dialog/dialog/dialog-state.d.ts +1 -1
- package/dialog/dialog-overlay/dialog-overlay.d.ts +7 -1
- package/dialog/dialog-trigger/dialog-trigger.d.ts +0 -2
- package/example-theme/index.css +2 -0
- package/fesm2022/ng-primitives-a11y.mjs +3 -3
- package/fesm2022/ng-primitives-accordion.mjs +18 -13
- package/fesm2022/ng-primitives-accordion.mjs.map +1 -1
- package/fesm2022/ng-primitives-autofill.mjs +4 -4
- package/fesm2022/ng-primitives-avatar.mjs +9 -9
- package/fesm2022/ng-primitives-button.mjs +3 -3
- package/fesm2022/ng-primitives-checkbox.mjs +4 -4
- package/fesm2022/ng-primitives-common.mjs +3 -3
- package/fesm2022/ng-primitives-date-picker.mjs +27 -27
- package/fesm2022/ng-primitives-dialog.mjs +30 -22
- package/fesm2022/ng-primitives-dialog.mjs.map +1 -1
- package/fesm2022/ng-primitives-file-upload.mjs +18 -12
- package/fesm2022/ng-primitives-file-upload.mjs.map +1 -1
- package/fesm2022/ng-primitives-focus-trap.mjs +31 -8
- package/fesm2022/ng-primitives-focus-trap.mjs.map +1 -1
- package/fesm2022/ng-primitives-form-field.mjs +15 -15
- package/fesm2022/ng-primitives-input.mjs +3 -3
- package/fesm2022/ng-primitives-interactions.mjs +15 -15
- package/fesm2022/ng-primitives-internal.mjs +66 -70
- package/fesm2022/ng-primitives-internal.mjs.map +1 -1
- package/fesm2022/ng-primitives-listbox.mjs +12 -12
- package/fesm2022/ng-primitives-menu.mjs +13 -13
- package/fesm2022/ng-primitives-meter.mjs +164 -0
- package/fesm2022/ng-primitives-meter.mjs.map +1 -0
- package/fesm2022/ng-primitives-pagination.mjs +19 -19
- package/fesm2022/ng-primitives-popover.mjs +114 -68
- package/fesm2022/ng-primitives-popover.mjs.map +1 -1
- package/fesm2022/ng-primitives-progress.mjs +6 -6
- package/fesm2022/ng-primitives-radio.mjs +13 -9
- package/fesm2022/ng-primitives-radio.mjs.map +1 -1
- package/fesm2022/ng-primitives-resize.mjs +3 -3
- package/fesm2022/ng-primitives-roving-focus.mjs +6 -6
- package/fesm2022/ng-primitives-search.mjs +7 -7
- package/fesm2022/ng-primitives-select.mjs +3 -3
- package/fesm2022/ng-primitives-separator.mjs +3 -3
- package/fesm2022/ng-primitives-slider.mjs +12 -12
- package/fesm2022/ng-primitives-state.mjs +10 -3
- package/fesm2022/ng-primitives-state.mjs.map +1 -1
- package/fesm2022/ng-primitives-switch.mjs +6 -6
- package/fesm2022/ng-primitives-tabs.mjs +35 -48
- package/fesm2022/ng-primitives-tabs.mjs.map +1 -1
- package/fesm2022/ng-primitives-textarea.mjs +3 -3
- package/fesm2022/ng-primitives-toast.mjs +3 -3
- package/fesm2022/ng-primitives-toggle-group.mjs +9 -14
- package/fesm2022/ng-primitives-toggle-group.mjs.map +1 -1
- package/fesm2022/ng-primitives-toggle.mjs +4 -4
- package/fesm2022/ng-primitives-toolbar.mjs +38 -14
- package/fesm2022/ng-primitives-toolbar.mjs.map +1 -1
- package/fesm2022/ng-primitives-tooltip.mjs +108 -51
- package/fesm2022/ng-primitives-tooltip.mjs.map +1 -1
- package/fesm2022/ng-primitives-utils.mjs +18 -0
- package/fesm2022/ng-primitives-utils.mjs.map +1 -1
- package/file-upload/file-dropzone/file-dropzone-state.d.ts +2 -2
- package/file-upload/file-dropzone/file-dropzone.d.ts +3 -2
- package/file-upload/file-upload/file-upload-state.d.ts +2 -2
- package/file-upload/file-upload/file-upload.d.ts +3 -2
- package/focus-trap/focus-trap/focus-trap-state.d.ts +41 -0
- package/focus-trap/focus-trap/focus-trap.d.ts +4 -0
- package/focus-trap/index.d.ts +1 -0
- package/form-field/form-control/form-control-state.d.ts +24 -24
- package/form-field/form-field/form-field-state.d.ts +1 -1
- package/input/input/input-state.d.ts +1 -1
- package/internal/exit-animation/exit-animation-manager.d.ts +17 -0
- package/internal/exit-animation/exit-animation.d.ts +4 -17
- package/internal/index.d.ts +2 -1
- package/listbox/listbox/listbox-state.d.ts +4 -4
- package/meter/README.md +3 -0
- package/meter/index.d.ts +6 -0
- package/meter/meter/meter-state.d.ts +25 -0
- package/meter/meter/meter.d.ts +27 -0
- package/meter/meter-indicator/meter-indicator.d.ts +15 -0
- package/meter/meter-label/meter-label.d.ts +18 -0
- package/meter/meter-track/meter-track.d.ts +5 -0
- package/meter/meter-value/meter-value.d.ts +5 -0
- package/package.json +13 -9
- package/pagination/pagination/pagination-state.d.ts +3 -3
- package/pagination/pagination-first/pagination-first.d.ts +2 -2
- package/pagination/pagination-next/pagination-next.d.ts +2 -2
- package/pagination/pagination-previous/pagination-previous.d.ts +2 -2
- package/popover/index.d.ts +1 -0
- package/popover/popover/popover-token.d.ts +10 -0
- package/popover/popover/popover.d.ts +34 -3
- package/popover/popover-trigger/popover-trigger-state.d.ts +5 -3
- package/popover/popover-trigger/popover-trigger.d.ts +26 -18
- package/progress/progress/progress-state.d.ts +3 -3
- package/progress/progress-indicator/progress-indicator.d.ts +2 -2
- package/radio/radio-group/radio-group-state.d.ts +1 -1
- package/radio/radio-item/radio-item-state.d.ts +1 -1
- package/roving-focus/roving-focus-group/roving-focus-group-state.d.ts +7 -7
- package/schematics/ng-generate/schema.d.ts +4 -1
- package/schematics/ng-generate/schema.json +4 -1
- package/schematics/ng-generate/templates/meter/meter.__fileSuffix@dasherize__.ts.template +78 -0
- package/schematics/ng-generate/templates/pagination/pagination.__fileSuffix@dasherize__.ts.template +11 -11
- package/schematics/ng-generate/templates/slider/slider.__fileSuffix@dasherize__.ts.template +8 -3
- package/schematics/ng-generate/templates/toolbar/toolbar-button.__fileSuffix@dasherize__.ts.template +58 -0
- package/schematics/ng-generate/templates/toolbar/toolbar.__fileSuffix@dasherize__.ts.template +37 -0
- package/schematics/ng-generate/templates/tooltip/tooltip-trigger.__fileSuffix@dasherize__.ts.template +35 -0
- package/schematics/ng-generate/templates/tooltip/tooltip.__fileSuffix@dasherize__.ts.template +60 -0
- package/search/search/search-state.d.ts +1 -1
- package/select/select/select-state.d.ts +1 -1
- package/slider/slider/slider-state.d.ts +5 -5
- package/slider/slider-range/slider-range.d.ts +4 -4
- package/slider/slider-thumb/slider-thumb.d.ts +4 -4
- package/slider/slider-track/slider-track.d.ts +4 -4
- package/state/index.d.ts +7 -1
- package/switch/switch/switch-state.d.ts +1 -1
- package/tabs/index.d.ts +1 -2
- package/tabs/tab-button/tab-button.d.ts +9 -10
- package/tabs/tab-list/tab-list.d.ts +6 -7
- package/tabs/tab-panel/tab-panel.d.ts +11 -9
- package/tabs/tabset/tabset-state.d.ts +7 -8
- package/tabs/tabset/tabset.d.ts +3 -4
- package/textarea/textarea/textarea-state.d.ts +1 -1
- package/toggle/toggle/toggle-state.d.ts +1 -1
- package/toggle-group/toggle-group/toggle-group-state.d.ts +7 -7
- package/toggle-group/toggle-group/toggle-group.d.ts +1 -1
- package/toggle-group/toggle-group-item/toggle-group-item-state.d.ts +13 -13
- package/toolbar/index.d.ts +1 -0
- package/toolbar/toolbar/toolbar-state.d.ts +39 -0
- package/toolbar/toolbar/toolbar.d.ts +10 -1
- package/tooltip/index.d.ts +1 -0
- package/tooltip/tooltip/tooltip-token.d.ts +10 -0
- package/tooltip/tooltip/tooltip.d.ts +2 -1
- package/tooltip/tooltip-trigger/tooltip-trigger-state.d.ts +3 -3
- package/tooltip/tooltip-trigger/tooltip-trigger.d.ts +44 -18
- package/tabs/tabset/tabset-token.d.ts +0 -11
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, numberAttribute, signal, computed, Directive } from '@angular/core';
|
|
3
|
+
import { createStateToken, createStateProvider, createStateInjector, createState } from 'ng-primitives/state';
|
|
4
|
+
import { uniqueId } from 'ng-primitives/utils';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* The state token for the Meter primitive.
|
|
8
|
+
*/
|
|
9
|
+
const NgpMeterStateToken = createStateToken('Meter');
|
|
10
|
+
/**
|
|
11
|
+
* Provides the Meter state.
|
|
12
|
+
*/
|
|
13
|
+
const provideMeterState = createStateProvider(NgpMeterStateToken);
|
|
14
|
+
/**
|
|
15
|
+
* Injects the Meter state.
|
|
16
|
+
*/
|
|
17
|
+
const injectMeterState = createStateInjector(NgpMeterStateToken);
|
|
18
|
+
/**
|
|
19
|
+
* The Meter state registration function.
|
|
20
|
+
*/
|
|
21
|
+
const meterState = createState(NgpMeterStateToken);
|
|
22
|
+
|
|
23
|
+
class NgpMeter {
|
|
24
|
+
constructor() {
|
|
25
|
+
/** The value of the meter. */
|
|
26
|
+
this.value = input(0, {
|
|
27
|
+
alias: 'ngpMeterValue',
|
|
28
|
+
transform: numberAttribute,
|
|
29
|
+
});
|
|
30
|
+
/** The minimum value of the meter. */
|
|
31
|
+
this.min = input(0, {
|
|
32
|
+
alias: 'ngpMeterMin',
|
|
33
|
+
transform: numberAttribute,
|
|
34
|
+
});
|
|
35
|
+
/** The maximum value of the meter. */
|
|
36
|
+
this.max = input(100, {
|
|
37
|
+
alias: 'ngpMeterMax',
|
|
38
|
+
transform: numberAttribute,
|
|
39
|
+
});
|
|
40
|
+
/**
|
|
41
|
+
* Define a function that returns the meter value label.
|
|
42
|
+
* @param value The current value
|
|
43
|
+
* @param max The maximum value
|
|
44
|
+
* @returns The value label
|
|
45
|
+
*/
|
|
46
|
+
this.valueLabel = input((value, max) => `${Math.round((value / max) * 100)}%`, {
|
|
47
|
+
alias: 'ngpMeterValueLabel',
|
|
48
|
+
});
|
|
49
|
+
/** @internal Store the label instance */
|
|
50
|
+
this.label = signal(null);
|
|
51
|
+
/** @internal The percentage of the meter. */
|
|
52
|
+
this.percentage = computed(() => {
|
|
53
|
+
const value = this.state.value();
|
|
54
|
+
const min = this.state.min();
|
|
55
|
+
const max = this.state.max();
|
|
56
|
+
if (value == null) {
|
|
57
|
+
return 0;
|
|
58
|
+
}
|
|
59
|
+
if (value < min) {
|
|
60
|
+
return 0;
|
|
61
|
+
}
|
|
62
|
+
if (value > max) {
|
|
63
|
+
return 100;
|
|
64
|
+
}
|
|
65
|
+
return ((value - min) / (max - min)) * 100;
|
|
66
|
+
});
|
|
67
|
+
/** The state of the meter. */
|
|
68
|
+
this.state = meterState(this);
|
|
69
|
+
}
|
|
70
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeter, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
71
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpMeter, isStandalone: true, selector: "[ngpMeter]", inputs: { value: { classPropertyName: "value", publicName: "ngpMeterValue", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "ngpMeterMin", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "ngpMeterMax", isSignal: true, isRequired: false, transformFunction: null }, valueLabel: { classPropertyName: "valueLabel", publicName: "ngpMeterValueLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "meter" }, properties: { "attr.aria-valuenow": "percentage()", "attr.aria-valuemin": "min()", "attr.aria-valuemax": "max()", "attr.aria-valuetext": "valueLabel()(value(), max())", "attr.aria-labelledby": "label()?.id()" } }, providers: [provideMeterState()], exportAs: ["ngpMeter"], ngImport: i0 }); }
|
|
72
|
+
}
|
|
73
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeter, decorators: [{
|
|
74
|
+
type: Directive,
|
|
75
|
+
args: [{
|
|
76
|
+
selector: '[ngpMeter]',
|
|
77
|
+
exportAs: 'ngpMeter',
|
|
78
|
+
providers: [provideMeterState()],
|
|
79
|
+
host: {
|
|
80
|
+
role: 'meter',
|
|
81
|
+
'[attr.aria-valuenow]': 'percentage()',
|
|
82
|
+
'[attr.aria-valuemin]': 'min()',
|
|
83
|
+
'[attr.aria-valuemax]': 'max()',
|
|
84
|
+
'[attr.aria-valuetext]': 'valueLabel()(value(), max())',
|
|
85
|
+
'[attr.aria-labelledby]': 'label()?.id()',
|
|
86
|
+
},
|
|
87
|
+
}]
|
|
88
|
+
}] });
|
|
89
|
+
|
|
90
|
+
class NgpMeterTrack {
|
|
91
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterTrack, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
92
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.8", type: NgpMeterTrack, isStandalone: true, selector: "[ngpMeterTrack]", exportAs: ["ngpMeterTrack"], ngImport: i0 }); }
|
|
93
|
+
}
|
|
94
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterTrack, decorators: [{
|
|
95
|
+
type: Directive,
|
|
96
|
+
args: [{
|
|
97
|
+
selector: '[ngpMeterTrack]',
|
|
98
|
+
exportAs: 'ngpMeterTrack',
|
|
99
|
+
}]
|
|
100
|
+
}] });
|
|
101
|
+
|
|
102
|
+
class NgpMeterIndicator {
|
|
103
|
+
constructor() {
|
|
104
|
+
/** Access the meter */
|
|
105
|
+
this.meter = injectMeterState();
|
|
106
|
+
}
|
|
107
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterIndicator, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
108
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.8", type: NgpMeterIndicator, isStandalone: true, selector: "[ngpMeterIndicator]", host: { properties: { "style.width.%": "meter().percentage()" } }, exportAs: ["ngpMeterIndicator"], ngImport: i0 }); }
|
|
109
|
+
}
|
|
110
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterIndicator, decorators: [{
|
|
111
|
+
type: Directive,
|
|
112
|
+
args: [{
|
|
113
|
+
selector: '[ngpMeterIndicator]',
|
|
114
|
+
exportAs: 'ngpMeterIndicator',
|
|
115
|
+
host: {
|
|
116
|
+
'[style.width.%]': 'meter().percentage()',
|
|
117
|
+
},
|
|
118
|
+
}]
|
|
119
|
+
}] });
|
|
120
|
+
|
|
121
|
+
class NgpMeterValue {
|
|
122
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterValue, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
123
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.8", type: NgpMeterValue, isStandalone: true, selector: "[ngpMeterValue]", host: { attributes: { "aria-hidden": "true" } }, exportAs: ["ngpMeterValue"], ngImport: i0 }); }
|
|
124
|
+
}
|
|
125
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterValue, decorators: [{
|
|
126
|
+
type: Directive,
|
|
127
|
+
args: [{
|
|
128
|
+
selector: '[ngpMeterValue]',
|
|
129
|
+
exportAs: 'ngpMeterValue',
|
|
130
|
+
host: {
|
|
131
|
+
'aria-hidden': 'true',
|
|
132
|
+
},
|
|
133
|
+
}]
|
|
134
|
+
}] });
|
|
135
|
+
|
|
136
|
+
class NgpMeterLabel {
|
|
137
|
+
constructor() {
|
|
138
|
+
/** Access the meter */
|
|
139
|
+
this.meter = injectMeterState();
|
|
140
|
+
/** The id of the meter label */
|
|
141
|
+
this.id = input(uniqueId('ngp-meter-label'));
|
|
142
|
+
// Register the label with the meter
|
|
143
|
+
this.meter().label.set(this);
|
|
144
|
+
}
|
|
145
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterLabel, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
146
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpMeterLabel, isStandalone: true, selector: "[ngpMeterLabel]", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.id": "id()" } }, exportAs: ["ngpMeterLabel"], ngImport: i0 }); }
|
|
147
|
+
}
|
|
148
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpMeterLabel, decorators: [{
|
|
149
|
+
type: Directive,
|
|
150
|
+
args: [{
|
|
151
|
+
selector: '[ngpMeterLabel]',
|
|
152
|
+
exportAs: 'ngpMeterLabel',
|
|
153
|
+
host: {
|
|
154
|
+
'[attr.id]': 'id()',
|
|
155
|
+
},
|
|
156
|
+
}]
|
|
157
|
+
}], ctorParameters: () => [] });
|
|
158
|
+
|
|
159
|
+
/**
|
|
160
|
+
* Generated bundle index. Do not edit.
|
|
161
|
+
*/
|
|
162
|
+
|
|
163
|
+
export { NgpMeter, NgpMeterIndicator, NgpMeterLabel, NgpMeterTrack, NgpMeterValue, injectMeterState, provideMeterState };
|
|
164
|
+
//# sourceMappingURL=ng-primitives-meter.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ng-primitives-meter.mjs","sources":["../../../../packages/ng-primitives/meter/src/meter/meter-state.ts","../../../../packages/ng-primitives/meter/src/meter/meter.ts","../../../../packages/ng-primitives/meter/src/meter-track/meter-track.ts","../../../../packages/ng-primitives/meter/src/meter-indicator/meter-indicator.ts","../../../../packages/ng-primitives/meter/src/meter-value/meter-value.ts","../../../../packages/ng-primitives/meter/src/meter-label/meter-label.ts","../../../../packages/ng-primitives/meter/src/ng-primitives-meter.ts"],"sourcesContent":["import {\n createState,\n createStateInjector,\n createStateProvider,\n createStateToken,\n} from 'ng-primitives/state';\nimport type { NgpMeter } from './meter';\n\n/**\n * The state token for the Meter primitive.\n */\nexport const NgpMeterStateToken = createStateToken<NgpMeter>('Meter');\n\n/**\n * Provides the Meter state.\n */\nexport const provideMeterState = createStateProvider(NgpMeterStateToken);\n\n/**\n * Injects the Meter state.\n */\nexport const injectMeterState = createStateInjector(NgpMeterStateToken);\n\n/**\n * The Meter state registration function.\n */\nexport const meterState = createState(NgpMeterStateToken);\n","import { NumberInput } from '@angular/cdk/coercion';\nimport { computed, Directive, input, numberAttribute, signal } from '@angular/core';\nimport type { NgpMeterLabel } from '../meter-label/meter-label';\nimport { meterState, provideMeterState } from './meter-state';\n\n@Directive({\n selector: '[ngpMeter]',\n exportAs: 'ngpMeter',\n providers: [provideMeterState()],\n host: {\n role: 'meter',\n '[attr.aria-valuenow]': 'percentage()',\n '[attr.aria-valuemin]': 'min()',\n '[attr.aria-valuemax]': 'max()',\n '[attr.aria-valuetext]': 'valueLabel()(value(), max())',\n '[attr.aria-labelledby]': 'label()?.id()',\n },\n})\nexport class NgpMeter {\n /** The value of the meter. */\n readonly value = input<number, NumberInput>(0, {\n alias: 'ngpMeterValue',\n transform: numberAttribute,\n });\n\n /** The minimum value of the meter. */\n readonly min = input<number, NumberInput>(0, {\n alias: 'ngpMeterMin',\n transform: numberAttribute,\n });\n\n /** The maximum value of the meter. */\n readonly max = input<number, NumberInput>(100, {\n alias: 'ngpMeterMax',\n transform: numberAttribute,\n });\n\n /**\n * Define a function that returns the meter value label.\n * @param value The current value\n * @param max The maximum value\n * @returns The value label\n */\n readonly valueLabel = input<NgpMeterValueTextFn>(\n (value, max) => `${Math.round((value / max) * 100)}%`,\n {\n alias: 'ngpMeterValueLabel',\n },\n );\n\n /** @internal Store the label instance */\n readonly label = signal<NgpMeterLabel | null>(null);\n\n /** @internal The percentage of the meter. */\n readonly percentage = computed(() => {\n const value = this.state.value();\n const min = this.state.min();\n const max = this.state.max();\n\n if (value == null) {\n return 0;\n }\n\n if (value < min) {\n return 0;\n }\n\n if (value > max) {\n return 100;\n }\n\n return ((value - min) / (max - min)) * 100;\n });\n\n /** The state of the meter. */\n private readonly state = meterState<NgpMeter>(this);\n}\n\nexport type NgpMeterValueTextFn = (value: number, max: number) => string;\n","import { Directive } from '@angular/core';\n\n@Directive({\n selector: '[ngpMeterTrack]',\n exportAs: 'ngpMeterTrack',\n})\nexport class NgpMeterTrack {}\n","import { Directive } from '@angular/core';\nimport { injectMeterState } from '../meter/meter-state';\n\n@Directive({\n selector: '[ngpMeterIndicator]',\n exportAs: 'ngpMeterIndicator',\n host: {\n '[style.width.%]': 'meter().percentage()',\n },\n})\nexport class NgpMeterIndicator {\n /** Access the meter */\n protected readonly meter = injectMeterState();\n}\n","import { Directive } from '@angular/core';\n\n@Directive({\n selector: '[ngpMeterValue]',\n exportAs: 'ngpMeterValue',\n host: {\n 'aria-hidden': 'true',\n },\n})\nexport class NgpMeterValue {}\n","import { Directive, input } from '@angular/core';\nimport { uniqueId } from 'ng-primitives/utils';\nimport { injectMeterState } from '../meter/meter-state';\n\n@Directive({\n selector: '[ngpMeterLabel]',\n exportAs: 'ngpMeterLabel',\n host: {\n '[attr.id]': 'id()',\n },\n})\nexport class NgpMeterLabel {\n /** Access the meter */\n protected readonly meter = injectMeterState();\n\n /** The id of the meter label */\n readonly id = input(uniqueId('ngp-meter-label'));\n\n constructor() {\n // Register the label with the meter\n this.meter().label.set(this);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAQA;;AAEG;AACI,MAAM,kBAAkB,GAA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;AACJ,wBAAA,aAAa,EAAE,MAAM;AACtB,qBAAA;AACF,iBAAA;;;MCGY,aAAa,CAAA;AAOxB,IAAA,WAAA,GAAA;;QALmB,IAAK,CAAA,KAAA,GAAG,gBAAgB,EAAE;;QAGpC,IAAE,CAAA,EAAA,GAAG,KAAK,CAAC,QAAQ,CAAC,iBAAiB,CAAC,CAAC;;QAI9C,IAAI,CAAC,KAAK,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC;;8GATnB,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAAb,aAAa,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,iBAAA,EAAA,MAAA,EAAA,EAAA,EAAA,EAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,SAAA,EAAA,MAAA,EAAA,EAAA,EAAA,QAAA,EAAA,CAAA,eAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAAb,aAAa,EAAA,UAAA,EAAA,CAAA;kBAPzB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,iBAAiB;AAC3B,oBAAA,QAAQ,EAAE,eAAe;AACzB,oBAAA,IAAI,EAAE;AACJ,wBAAA,WAAW,EAAE,MAAM;AACpB,qBAAA;AACF,iBAAA;;;ACVD;;AAEG;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { input, numberAttribute, booleanAttribute, computed,
|
|
2
|
+
import { input, numberAttribute, booleanAttribute, computed, HostListener, Directive, output } from '@angular/core';
|
|
3
3
|
import * as i1 from 'ng-primitives/button';
|
|
4
4
|
import { syncButton, NgpButton } from 'ng-primitives/button';
|
|
5
5
|
import { createStateToken, createStateProvider, createStateInjector, createState } from 'ng-primitives/state';
|
|
@@ -72,10 +72,10 @@ class NgpPaginationButton {
|
|
|
72
72
|
event.stopPropagation();
|
|
73
73
|
this.goToPage();
|
|
74
74
|
}
|
|
75
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.
|
|
76
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.
|
|
75
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationButton, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
76
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpPaginationButton, isStandalone: true, selector: "[ngpPaginationButton]", inputs: { page: { classPropertyName: "page", publicName: "ngpPaginationButtonPage", isSignal: true, isRequired: true, transformFunction: null }, buttonDisabled: { classPropertyName: "buttonDisabled", publicName: "ngpPaginationButtonDisabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "goToPage()", "keydown.enter": "onEnter($event)", "keydown.space": "onEnter($event)" }, properties: { "tabindex": "disabled() ? -1 : 0", "attr.data-disabled": "disabled() ? \"\" : null", "attr.data-page": "page()", "attr.data-selected": "selected() ? \"\" : null", "attr.aria-current": "selected()" } }, exportAs: ["ngpPaginationButton"], hostDirectives: [{ directive: i1.NgpButton }], ngImport: i0 }); }
|
|
77
77
|
}
|
|
78
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.
|
|
78
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationButton, decorators: [{
|
|
79
79
|
type: Directive,
|
|
80
80
|
args: [{
|
|
81
81
|
selector: '[ngpPaginationButton]',
|
|
@@ -139,10 +139,10 @@ class NgpPaginationFirst {
|
|
|
139
139
|
event.stopPropagation();
|
|
140
140
|
this.goToFirstPage();
|
|
141
141
|
}
|
|
142
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.
|
|
143
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.
|
|
142
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationFirst, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
143
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpPaginationFirst, isStandalone: true, selector: "[ngpPaginationFirst]", inputs: { buttonDisabled: { classPropertyName: "buttonDisabled", publicName: "ngpPaginationFirstDisabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "goToFirstPage()", "keydown.enter": "onEnter($event)", "keydown.space": "onEnter($event)" }, properties: { "tabindex": "disabled() ? -1 : 0", "attr.data-disabled": "disabled() ? \"\" : null", "attr.data-first-page": "paginationState().firstPage() ? \"\" : null" } }, exportAs: ["ngpPaginationFirst"], hostDirectives: [{ directive: i1.NgpButton }], ngImport: i0 }); }
|
|
144
144
|
}
|
|
145
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.
|
|
145
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationFirst, decorators: [{
|
|
146
146
|
type: Directive,
|
|
147
147
|
args: [{
|
|
148
148
|
selector: '[ngpPaginationFirst]',
|
|
@@ -204,10 +204,10 @@ class NgpPaginationLast {
|
|
|
204
204
|
event.stopPropagation();
|
|
205
205
|
this.goToLastPage();
|
|
206
206
|
}
|
|
207
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.
|
|
208
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.
|
|
207
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationLast, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
208
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpPaginationLast, isStandalone: true, selector: "[ngpPaginationLast]", inputs: { buttonDisabled: { classPropertyName: "buttonDisabled", publicName: "ngpPaginationLastDisabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "goToLastPage()", "keydown.enter": "onEnter($event)", "keydown.space": "onEnter($event)" }, properties: { "tabindex": "disabled() ? -1 : 0", "attr.data-disabled": "disabled() ? \"\" : null", "attr.data-last-page": "paginationState().lastPage() ? \"\" : null" } }, exportAs: ["ngpPaginationLast"], hostDirectives: [{ directive: i1.NgpButton }], ngImport: i0 }); }
|
|
209
209
|
}
|
|
210
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.
|
|
210
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationLast, decorators: [{
|
|
211
211
|
type: Directive,
|
|
212
212
|
args: [{
|
|
213
213
|
selector: '[ngpPaginationLast]',
|
|
@@ -272,10 +272,10 @@ class NgpPaginationNext {
|
|
|
272
272
|
event.stopPropagation();
|
|
273
273
|
this.goToNextPage();
|
|
274
274
|
}
|
|
275
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.
|
|
276
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.
|
|
275
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationNext, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
276
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpPaginationNext, isStandalone: true, selector: "[ngpPaginationNext]", inputs: { buttonDisabled: { classPropertyName: "buttonDisabled", publicName: "ngpPaginationNextDisabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "goToNextPage()", "keydown.enter": "onEnter($event)", "keydown.space": "onEnter($event)" }, properties: { "tabindex": "disabled() ? -1 : 0", "attr.data-disabled": "disabled() ? \"\" : null", "attr.data-last-page": "paginationState().lastPage() ? \"\" : null" } }, exportAs: ["ngpPaginationNext"], hostDirectives: [{ directive: i1.NgpButton }], ngImport: i0 }); }
|
|
277
277
|
}
|
|
278
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.
|
|
278
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationNext, decorators: [{
|
|
279
279
|
type: Directive,
|
|
280
280
|
args: [{
|
|
281
281
|
selector: '[ngpPaginationNext]',
|
|
@@ -340,10 +340,10 @@ class NgpPaginationPrevious {
|
|
|
340
340
|
event.stopPropagation();
|
|
341
341
|
this.goToPreviousPage();
|
|
342
342
|
}
|
|
343
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.
|
|
344
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.
|
|
343
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationPrevious, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
344
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpPaginationPrevious, isStandalone: true, selector: "[ngpPaginationPrevious]", inputs: { buttonDisabled: { classPropertyName: "buttonDisabled", publicName: "ngpPaginationPreviousDisabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "goToPreviousPage()", "keydown.enter": "onEnter($event)", "keydown.space": "onEnter($event)" }, properties: { "tabindex": "disabled() ? -1 : 0", "attr.data-disabled": "disabled() ? \"\" : null", "attr.data-first-page": "paginationState().firstPage() ? \"\" : null" } }, exportAs: ["ngpPaginationPrevious"], hostDirectives: [{ directive: i1.NgpButton }], ngImport: i0 }); }
|
|
345
345
|
}
|
|
346
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.
|
|
346
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPaginationPrevious, decorators: [{
|
|
347
347
|
type: Directive,
|
|
348
348
|
args: [{
|
|
349
349
|
selector: '[ngpPaginationPrevious]',
|
|
@@ -426,10 +426,10 @@ class NgpPagination {
|
|
|
426
426
|
this.state.page.set(page);
|
|
427
427
|
this.pageChange.emit(page);
|
|
428
428
|
}
|
|
429
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.
|
|
430
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.
|
|
429
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPagination, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
430
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: NgpPagination, isStandalone: true, selector: "[ngpPagination]", inputs: { page: { classPropertyName: "page", publicName: "ngpPaginationPage", isSignal: true, isRequired: false, transformFunction: null }, pageCount: { classPropertyName: "pageCount", publicName: "ngpPaginationPageCount", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "ngpPaginationDisabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { pageChange: "ngpPaginationPageChange" }, host: { attributes: { "role": "navigation" }, properties: { "attr.data-page": "state.page()", "attr.data-page-count": "state.pageCount()", "attr.data-first-page": "firstPage() ? \"\" : null", "attr.data-last-page": "lastPage() ? \"\" : null", "attr.data-disabled": "state.disabled() ? \"\" : null" } }, providers: [providePaginationState()], exportAs: ["ngpPagination"], ngImport: i0 }); }
|
|
431
431
|
}
|
|
432
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.
|
|
432
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: NgpPagination, decorators: [{
|
|
433
433
|
type: Directive,
|
|
434
434
|
args: [{
|
|
435
435
|
selector: '[ngpPagination]',
|