@ojiepermana/angular-component 22.0.44 → 22.0.45
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/fesm2022/ojiepermana-angular-component-accordion.mjs +9 -11
- package/fesm2022/ojiepermana-angular-component-alert-dialog.mjs +93 -32
- package/fesm2022/ojiepermana-angular-component-alert.mjs +5 -9
- package/fesm2022/ojiepermana-angular-component-aspect-ratio.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-avatar.mjs +7 -13
- package/fesm2022/ojiepermana-angular-component-badge.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-breadcrumb.mjs +16 -19
- package/fesm2022/ojiepermana-angular-component-button-group.mjs +4 -7
- package/fesm2022/ojiepermana-angular-component-button.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-calendar.mjs +7 -5
- package/fesm2022/ojiepermana-angular-component-card.mjs +8 -15
- package/fesm2022/ojiepermana-angular-component-carousel.mjs +15 -18
- package/fesm2022/ojiepermana-angular-component-checkbox.mjs +40 -11
- package/fesm2022/ojiepermana-angular-component-collapsible.mjs +8 -6
- package/fesm2022/ojiepermana-angular-component-combobox.mjs +28 -15
- package/fesm2022/ojiepermana-angular-component-command.mjs +9 -17
- package/fesm2022/ojiepermana-angular-component-composer.mjs +15 -18
- package/fesm2022/ojiepermana-angular-component-date-picker.mjs +36 -11
- package/fesm2022/ojiepermana-angular-component-dialog.mjs +85 -30
- package/fesm2022/ojiepermana-angular-component-dropdown-menu.mjs +31 -26
- package/fesm2022/ojiepermana-angular-component-editor.mjs +37 -28
- package/fesm2022/ojiepermana-angular-component-empty.mjs +7 -13
- package/fesm2022/ojiepermana-angular-component-form.mjs +14 -22
- package/fesm2022/ojiepermana-angular-component-hover-card.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-icon.mjs +51 -6
- package/fesm2022/ojiepermana-angular-component-input-group.mjs +17 -15
- package/fesm2022/ojiepermana-angular-component-input-otp.mjs +15 -14
- package/fesm2022/ojiepermana-angular-component-input.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-item.mjs +11 -21
- package/fesm2022/ojiepermana-angular-component-kanban.mjs +27 -26
- package/fesm2022/ojiepermana-angular-component-kbd.mjs +3 -5
- package/fesm2022/ojiepermana-angular-component-label.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-menubar.mjs +6 -6
- package/fesm2022/ojiepermana-angular-component-native-select.mjs +3 -3
- package/fesm2022/ojiepermana-angular-component-navigation-menu.mjs +25 -12
- package/fesm2022/ojiepermana-angular-component-pagination.mjs +22 -13
- package/fesm2022/ojiepermana-angular-component-pillbox.mjs +64 -36
- package/fesm2022/ojiepermana-angular-component-progress.mjs +7 -5
- package/fesm2022/ojiepermana-angular-component-radio.mjs +12 -8
- package/fesm2022/ojiepermana-angular-component-resizable.mjs +22 -11
- package/fesm2022/ojiepermana-angular-component-scroll-area.mjs +8 -6
- package/fesm2022/ojiepermana-angular-component-select.mjs +29 -17
- package/fesm2022/ojiepermana-angular-component-separator.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-sheet.mjs +86 -30
- package/fesm2022/ojiepermana-angular-component-skeleton.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-slider.mjs +25 -13
- package/fesm2022/ojiepermana-angular-component-spinner.mjs +6 -5
- package/fesm2022/ojiepermana-angular-component-switch.mjs +17 -8
- package/fesm2022/ojiepermana-angular-component-table.mjs +9 -17
- package/fesm2022/ojiepermana-angular-component-tabs.mjs +5 -9
- package/fesm2022/ojiepermana-angular-component-textarea.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-timeline.mjs +16 -16
- package/fesm2022/ojiepermana-angular-component-toggle-group.mjs +10 -5
- package/fesm2022/ojiepermana-angular-component-toggle.mjs +2 -3
- package/fesm2022/ojiepermana-angular-component-tooltip.mjs +7 -6
- package/package.json +10 -1
- package/types/ojiepermana-angular-component-alert-dialog.d.ts +42 -3
- package/types/ojiepermana-angular-component-dialog.d.ts +33 -3
- package/types/ojiepermana-angular-component-icon.d.ts +48 -1
- package/types/ojiepermana-angular-component-sheet.d.ts +33 -3
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { signal, computed, effect, Injectable, inject, input, booleanAttribute,
|
|
2
|
+
import { signal, computed, effect, Injectable, inject, input, booleanAttribute, Component, Directive } from '@angular/core';
|
|
3
3
|
import { uniqueId, cn } from '@ojiepermana/angular-component/utils';
|
|
4
4
|
import { NgControl } from '@angular/forms';
|
|
5
5
|
|
|
@@ -83,13 +83,12 @@ class FormFieldComponent {
|
|
|
83
83
|
effect(() => this.ctx.manualInvalid.set(this.invalid()));
|
|
84
84
|
}
|
|
85
85
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormFieldComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
86
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormFieldComponent, isStandalone: true, selector: "FormField", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-orientation": "orientation()", "attr.data-invalid": "ctx.invalid() ? \"\" : null", "attr.role": "\"group\"" } }, providers: [FormFieldContext], ngImport: i0, template: `<ng-content />`, isInline: true
|
|
86
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormFieldComponent, isStandalone: true, selector: "FormField", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-orientation": "orientation()", "attr.data-invalid": "ctx.invalid() ? \"\" : null", "attr.role": "\"group\"" } }, providers: [FormFieldContext], ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
87
87
|
}
|
|
88
88
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormFieldComponent, decorators: [{
|
|
89
89
|
type: Component,
|
|
90
90
|
args: [{
|
|
91
91
|
selector: 'FormField',
|
|
92
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
93
92
|
providers: [FormFieldContext],
|
|
94
93
|
host: {
|
|
95
94
|
'[class]': 'classes()',
|
|
@@ -107,13 +106,12 @@ class FormFieldsetComponent {
|
|
|
107
106
|
classes = computed(() => cn('block min-w-0 border-0 p-0 m-0', 'grid gap-4', this.class()), /* @ts-ignore */
|
|
108
107
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
109
108
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormFieldsetComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
110
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormFieldsetComponent, isStandalone: true, selector: "FormFieldset, fieldset[FormFieldset]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
109
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormFieldsetComponent, isStandalone: true, selector: "FormFieldset, fieldset[FormFieldset]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
111
110
|
}
|
|
112
111
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormFieldsetComponent, decorators: [{
|
|
113
112
|
type: Component,
|
|
114
113
|
args: [{
|
|
115
114
|
selector: 'FormFieldset, fieldset[FormFieldset]',
|
|
116
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
117
115
|
host: {
|
|
118
116
|
'[class]': 'classes()',
|
|
119
117
|
},
|
|
@@ -126,16 +124,17 @@ class FormLegendComponent {
|
|
|
126
124
|
...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
127
125
|
variant = input('legend', /* @ts-ignore */
|
|
128
126
|
...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
129
|
-
classes = computed(() => cn('block min-w-0 text-foreground', this.variant() === 'label'
|
|
127
|
+
classes = computed(() => cn('block min-w-0 text-foreground', this.variant() === 'label'
|
|
128
|
+
? 'text-sm font-medium leading-none'
|
|
129
|
+
: 'text-sm font-semibold leading-none', this.class()), /* @ts-ignore */
|
|
130
130
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
131
131
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormLegendComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
132
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormLegendComponent, isStandalone: true, selector: "FormLegend, legend[FormLegend]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
132
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormLegendComponent, isStandalone: true, selector: "FormLegend, legend[FormLegend]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
133
133
|
}
|
|
134
134
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormLegendComponent, decorators: [{
|
|
135
135
|
type: Component,
|
|
136
136
|
args: [{
|
|
137
137
|
selector: 'FormLegend, legend[FormLegend]',
|
|
138
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
139
138
|
host: {
|
|
140
139
|
'[class]': 'classes()',
|
|
141
140
|
},
|
|
@@ -149,13 +148,12 @@ class FormGroupComponent {
|
|
|
149
148
|
classes = computed(() => cn('block min-w-0', 'grid gap-6', this.class()), /* @ts-ignore */
|
|
150
149
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
151
150
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormGroupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
152
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormGroupComponent, isStandalone: true, selector: "FormGroup", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
151
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormGroupComponent, isStandalone: true, selector: "FormGroup", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
153
152
|
}
|
|
154
153
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormGroupComponent, decorators: [{
|
|
155
154
|
type: Component,
|
|
156
155
|
args: [{
|
|
157
156
|
selector: 'FormGroup',
|
|
158
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
159
157
|
host: {
|
|
160
158
|
'[class]': 'classes()',
|
|
161
159
|
},
|
|
@@ -169,13 +167,12 @@ class FormSeparatorComponent {
|
|
|
169
167
|
classes = computed(() => cn('block min-w-0', 'flex items-center gap-3 text-xs font-medium uppercase tracking-[0.24em] text-muted-foreground', 'before:h-px before:flex-1 before:bg-border after:h-px after:flex-1 after:bg-border', this.class()), /* @ts-ignore */
|
|
170
168
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
171
169
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormSeparatorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
172
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormSeparatorComponent, isStandalone: true, selector: "FormSeparator", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<span class="shrink-0"><ng-content /></span>`, isInline: true
|
|
170
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormSeparatorComponent, isStandalone: true, selector: "FormSeparator", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<span class="shrink-0"><ng-content /></span>`, isInline: true });
|
|
173
171
|
}
|
|
174
172
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormSeparatorComponent, decorators: [{
|
|
175
173
|
type: Component,
|
|
176
174
|
args: [{
|
|
177
175
|
selector: 'FormSeparator',
|
|
178
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
179
176
|
host: {
|
|
180
177
|
'[class]': 'classes()',
|
|
181
178
|
},
|
|
@@ -189,13 +186,12 @@ class FormContentComponent {
|
|
|
189
186
|
classes = computed(() => cn('block min-w-0 flex-1', 'grid gap-1.5', this.class()), /* @ts-ignore */
|
|
190
187
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
191
188
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
192
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormContentComponent, isStandalone: true, selector: "FormContent", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
189
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormContentComponent, isStandalone: true, selector: "FormContent", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
193
190
|
}
|
|
194
191
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormContentComponent, decorators: [{
|
|
195
192
|
type: Component,
|
|
196
193
|
args: [{
|
|
197
194
|
selector: 'FormContent',
|
|
198
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
199
195
|
host: {
|
|
200
196
|
'[class]': 'classes()',
|
|
201
197
|
},
|
|
@@ -209,13 +205,12 @@ class FormTitleComponent {
|
|
|
209
205
|
classes = computed(() => cn('block text-sm font-medium leading-none text-foreground', this.class()), /* @ts-ignore */
|
|
210
206
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
211
207
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
212
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormTitleComponent, isStandalone: true, selector: "FormTitle", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
208
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormTitleComponent, isStandalone: true, selector: "FormTitle", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
213
209
|
}
|
|
214
210
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormTitleComponent, decorators: [{
|
|
215
211
|
type: Component,
|
|
216
212
|
args: [{
|
|
217
213
|
selector: 'FormTitle',
|
|
218
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
219
214
|
host: {
|
|
220
215
|
'[class]': 'classes()',
|
|
221
216
|
},
|
|
@@ -230,13 +225,12 @@ class FormLabelComponent {
|
|
|
230
225
|
classes = computed(() => cn('text-sm font-medium leading-none', this.ctx.invalid() ? 'text-destructive' : 'text-foreground', 'peer-disabled:cursor-not-allowed peer-disabled:opacity-70', this.class()), /* @ts-ignore */
|
|
231
226
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
232
227
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormLabelComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
233
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormLabelComponent, isStandalone: true, selector: "FormLabel, label[FormLabel]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.for": "ctx.controlId" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
228
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormLabelComponent, isStandalone: true, selector: "FormLabel, label[FormLabel]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.for": "ctx.controlId" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
234
229
|
}
|
|
235
230
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormLabelComponent, decorators: [{
|
|
236
231
|
type: Component,
|
|
237
232
|
args: [{
|
|
238
233
|
selector: 'FormLabel, label[FormLabel]',
|
|
239
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
240
234
|
host: {
|
|
241
235
|
'[class]': 'classes()',
|
|
242
236
|
'[attr.for]': 'ctx.controlId',
|
|
@@ -260,13 +254,12 @@ class FormDescriptionComponent {
|
|
|
260
254
|
this.ctx?.hasDescription.set(false);
|
|
261
255
|
}
|
|
262
256
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormDescriptionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
263
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormDescriptionComponent, isStandalone: true, selector: "FormDescription, p[FormDescription]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.id": "descriptionId()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
257
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: FormDescriptionComponent, isStandalone: true, selector: "FormDescription, p[FormDescription]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.id": "descriptionId()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
264
258
|
}
|
|
265
259
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormDescriptionComponent, decorators: [{
|
|
266
260
|
type: Component,
|
|
267
261
|
args: [{
|
|
268
262
|
selector: 'FormDescription, p[FormDescription]',
|
|
269
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
270
263
|
host: {
|
|
271
264
|
'[class]': 'classes()',
|
|
272
265
|
'[attr.id]': 'descriptionId()',
|
|
@@ -298,13 +291,12 @@ class FormMessageComponent {
|
|
|
298
291
|
@if (show()) {
|
|
299
292
|
<ng-content>{{ ctx.firstError() }}</ng-content>
|
|
300
293
|
}
|
|
301
|
-
`, isInline: true
|
|
294
|
+
`, isInline: true });
|
|
302
295
|
}
|
|
303
296
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: FormMessageComponent, decorators: [{
|
|
304
297
|
type: Component,
|
|
305
298
|
args: [{
|
|
306
299
|
selector: 'FormMessage, p[FormMessage]',
|
|
307
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
308
300
|
host: {
|
|
309
301
|
'[class]': 'classes()',
|
|
310
302
|
'[attr.id]': 'ctx.messageId',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { InjectionToken, input, forwardRef,
|
|
2
|
+
import { InjectionToken, input, forwardRef, Component, inject, TemplateRef, Directive, ViewContainerRef, ElementRef, DestroyRef, output, signal } from '@angular/core';
|
|
3
3
|
import { Overlay } from '@angular/cdk/overlay';
|
|
4
4
|
import { TemplatePortal } from '@angular/cdk/portal';
|
|
5
5
|
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
@@ -18,13 +18,12 @@ class HoverCardComponent {
|
|
|
18
18
|
closeDelay = input(100, /* @ts-ignore */
|
|
19
19
|
...(ngDevMode ? [{ debugName: "closeDelay" }] : /* istanbul ignore next */ []));
|
|
20
20
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: HoverCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
21
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: HoverCardComponent, isStandalone: true, selector: "HoverCard", inputs: { side: { classPropertyName: "side", publicName: "side", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, sideOffset: { classPropertyName: "sideOffset", publicName: "sideOffset", isSignal: true, isRequired: false, transformFunction: null }, openDelay: { classPropertyName: "openDelay", publicName: "openDelay", isSignal: true, isRequired: false, transformFunction: null }, closeDelay: { classPropertyName: "closeDelay", publicName: "closeDelay", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "contents" }, providers: [{ provide: HOVER_CARD_DEFAULTS, useExisting: forwardRef(() => HoverCardComponent) }], ngImport: i0, template: '<ng-content />', isInline: true
|
|
21
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: HoverCardComponent, isStandalone: true, selector: "HoverCard", inputs: { side: { classPropertyName: "side", publicName: "side", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, sideOffset: { classPropertyName: "sideOffset", publicName: "sideOffset", isSignal: true, isRequired: false, transformFunction: null }, openDelay: { classPropertyName: "openDelay", publicName: "openDelay", isSignal: true, isRequired: false, transformFunction: null }, closeDelay: { classPropertyName: "closeDelay", publicName: "closeDelay", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "contents" }, providers: [{ provide: HOVER_CARD_DEFAULTS, useExisting: forwardRef(() => HoverCardComponent) }], ngImport: i0, template: '<ng-content />', isInline: true });
|
|
22
22
|
}
|
|
23
23
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: HoverCardComponent, decorators: [{
|
|
24
24
|
type: Component,
|
|
25
25
|
args: [{
|
|
26
26
|
selector: 'HoverCard',
|
|
27
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
28
27
|
providers: [{ provide: HOVER_CARD_DEFAULTS, useExisting: forwardRef(() => HoverCardComponent) }],
|
|
29
28
|
host: {
|
|
30
29
|
class: 'contents',
|
|
@@ -1,14 +1,37 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { inject, PLATFORM_ID, Service, input, computed,
|
|
2
|
+
import { InjectionToken, inject, PLATFORM_ID, Service, input, computed, Component, makeEnvironmentProviders, provideEnvironmentInitializer } from '@angular/core';
|
|
3
3
|
import { DOCUMENT, isPlatformBrowser } from '@angular/common';
|
|
4
4
|
|
|
5
5
|
const MATERIAL_SYMBOLS_FONT_ATTR = 'data-icon-font';
|
|
6
6
|
const MATERIAL_SYMBOLS_FONT_ID = 'material-symbols-outlined';
|
|
7
7
|
const MATERIAL_SYMBOLS_FONT_HREF = 'https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@24,400,0,0';
|
|
8
|
+
/**
|
|
9
|
+
* Presence of this token is what enables {@link IconComponent} to auto-load the
|
|
10
|
+
* font. It is only provided when the app opts in via `provideMaterialSymbols()`;
|
|
11
|
+
* without it, `<Icon>` makes no network request.
|
|
12
|
+
*/
|
|
13
|
+
const MATERIAL_SYMBOLS_CONFIG = new InjectionToken('MATERIAL_SYMBOLS_CONFIG');
|
|
8
14
|
class MaterialSymbolsService {
|
|
9
15
|
documentRef = inject(DOCUMENT, { optional: true });
|
|
10
16
|
platformId = inject(PLATFORM_ID);
|
|
17
|
+
config = inject(MATERIAL_SYMBOLS_CONFIG, { optional: true });
|
|
18
|
+
/**
|
|
19
|
+
* Token-gated load. No-op unless the app opted in via `provideMaterialSymbols()`
|
|
20
|
+
* (which provides {@link MATERIAL_SYMBOLS_CONFIG}). Called by `IconComponent`
|
|
21
|
+
* so rendering an icon never triggers an implicit network request on its own.
|
|
22
|
+
*/
|
|
11
23
|
ensureLoaded() {
|
|
24
|
+
if (!this.config) {
|
|
25
|
+
return;
|
|
26
|
+
}
|
|
27
|
+
this.load(this.config);
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Explicitly inject the font stylesheet, regardless of whether the config
|
|
31
|
+
* token is present. Used by integrations that decide to load the font from
|
|
32
|
+
* their own option surface (e.g. `provideUiTheme({ icons: { materialSymbols: true } })`).
|
|
33
|
+
*/
|
|
34
|
+
load(config) {
|
|
12
35
|
const head = this.documentRef?.head;
|
|
13
36
|
if (!isPlatformBrowser(this.platformId) || !head) {
|
|
14
37
|
return;
|
|
@@ -17,9 +40,9 @@ class MaterialSymbolsService {
|
|
|
17
40
|
if (existing) {
|
|
18
41
|
return;
|
|
19
42
|
}
|
|
20
|
-
const link =
|
|
43
|
+
const link = head.ownerDocument.createElement('link');
|
|
21
44
|
link.rel = 'stylesheet';
|
|
22
|
-
link.href = MATERIAL_SYMBOLS_FONT_HREF;
|
|
45
|
+
link.href = config?.href ?? MATERIAL_SYMBOLS_FONT_HREF;
|
|
23
46
|
link.setAttribute(MATERIAL_SYMBOLS_FONT_ATTR, MATERIAL_SYMBOLS_FONT_ID);
|
|
24
47
|
head.appendChild(link);
|
|
25
48
|
}
|
|
@@ -59,13 +82,12 @@ class IconComponent {
|
|
|
59
82
|
this.materialSymbols.ensureLoaded();
|
|
60
83
|
}
|
|
61
84
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: IconComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
62
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: IconComponent, isStandalone: true, selector: "Icon", inputs: { name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, fill: { classPropertyName: "fill", publicName: "fill", isSignal: true, isRequired: false, transformFunction: null }, weight: { classPropertyName: "weight", publicName: "weight", isSignal: true, isRequired: false, transformFunction: null }, grade: { classPropertyName: "grade", publicName: "grade", isSignal: true, isRequired: false, transformFunction: null }, opticalSize: { classPropertyName: "opticalSize", publicName: "opticalSize", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "aria-hidden": "true", "translate": "no" }, properties: { "class": "classes()", "style.font-size.px": "resolvedSize()", "style.line-height.px": "resolvedSize()", "style.font-variation-settings": "fontVariationSettings()" } }, ngImport: i0, template: `{{ name() }}`, isInline: true
|
|
85
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: IconComponent, isStandalone: true, selector: "Icon", inputs: { name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, fill: { classPropertyName: "fill", publicName: "fill", isSignal: true, isRequired: false, transformFunction: null }, weight: { classPropertyName: "weight", publicName: "weight", isSignal: true, isRequired: false, transformFunction: null }, grade: { classPropertyName: "grade", publicName: "grade", isSignal: true, isRequired: false, transformFunction: null }, opticalSize: { classPropertyName: "opticalSize", publicName: "opticalSize", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "aria-hidden": "true", "translate": "no" }, properties: { "class": "classes()", "style.font-size.px": "resolvedSize()", "style.line-height.px": "resolvedSize()", "style.font-variation-settings": "fontVariationSettings()" } }, ngImport: i0, template: `{{ name() }}`, isInline: true });
|
|
63
86
|
}
|
|
64
87
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: IconComponent, decorators: [{
|
|
65
88
|
type: Component,
|
|
66
89
|
args: [{
|
|
67
90
|
selector: 'Icon',
|
|
68
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
69
91
|
host: {
|
|
70
92
|
'[class]': 'classes()',
|
|
71
93
|
'[style.font-size.px]': 'resolvedSize()',
|
|
@@ -78,8 +100,31 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
78
100
|
}]
|
|
79
101
|
}], ctorParameters: () => [], propDecorators: { name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], fill: [{ type: i0.Input, args: [{ isSignal: true, alias: "fill", required: false }] }], weight: [{ type: i0.Input, args: [{ isSignal: true, alias: "weight", required: false }] }], grade: [{ type: i0.Input, args: [{ isSignal: true, alias: "grade", required: false }] }], opticalSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "opticalSize", required: false }] }] } });
|
|
80
102
|
|
|
103
|
+
/**
|
|
104
|
+
* Opt in to loading the Material Symbols icon font that `<Icon>` renders with.
|
|
105
|
+
*
|
|
106
|
+
* By default `IconComponent` makes **no** network request — better for privacy,
|
|
107
|
+
* offline, and strict CSP. Add this provider to your bootstrap to fetch the font
|
|
108
|
+
* stylesheet once at startup. Pass `{ href }` to load from a self-hosted source
|
|
109
|
+
* instead of Google Fonts.
|
|
110
|
+
*
|
|
111
|
+
* @example
|
|
112
|
+
* // Google Fonts (default source):
|
|
113
|
+
* bootstrapApplication(App, { providers: [provideMaterialSymbols()] });
|
|
114
|
+
*
|
|
115
|
+
* @example
|
|
116
|
+
* // Self-hosted / offline:
|
|
117
|
+
* provideMaterialSymbols({ href: '/assets/material-symbols.css' });
|
|
118
|
+
*/
|
|
119
|
+
function provideMaterialSymbols(config = {}) {
|
|
120
|
+
return makeEnvironmentProviders([
|
|
121
|
+
{ provide: MATERIAL_SYMBOLS_CONFIG, useValue: config },
|
|
122
|
+
provideEnvironmentInitializer(() => inject(MaterialSymbolsService).ensureLoaded()),
|
|
123
|
+
]);
|
|
124
|
+
}
|
|
125
|
+
|
|
81
126
|
/**
|
|
82
127
|
* Generated bundle index. Do not edit.
|
|
83
128
|
*/
|
|
84
129
|
|
|
85
|
-
export { IconComponent, MATERIAL_SYMBOLS_FONT_ATTR, MATERIAL_SYMBOLS_FONT_HREF, MATERIAL_SYMBOLS_FONT_ID, MaterialSymbolsService };
|
|
130
|
+
export { IconComponent, MATERIAL_SYMBOLS_CONFIG, MATERIAL_SYMBOLS_FONT_ATTR, MATERIAL_SYMBOLS_FONT_HREF, MATERIAL_SYMBOLS_FONT_ID, MaterialSymbolsService, provideMaterialSymbols };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { input, computed,
|
|
2
|
+
import { input, computed, Component, inject, ElementRef } from '@angular/core';
|
|
3
3
|
import { cn } from '@ojiepermana/angular-component/utils';
|
|
4
4
|
import { buttonVariants } from '@ojiepermana/angular-component/button';
|
|
5
5
|
|
|
@@ -17,8 +17,16 @@ const GROUP_BASE = [
|
|
|
17
17
|
'[&>[data-slot=input-group-control]]:focus-visible:outline-none',
|
|
18
18
|
].join(' ');
|
|
19
19
|
const addonAlignClasses = {
|
|
20
|
-
'inline-start': [
|
|
21
|
-
|
|
20
|
+
'inline-start': [
|
|
21
|
+
'order-10',
|
|
22
|
+
'[border-inline-end-width:1px]',
|
|
23
|
+
'[border-inline-end-color:hsl(var(--border))]',
|
|
24
|
+
].join(' '),
|
|
25
|
+
'inline-end': [
|
|
26
|
+
'order-30',
|
|
27
|
+
'[border-inline-start-width:1px]',
|
|
28
|
+
'[border-inline-start-color:hsl(var(--border))]',
|
|
29
|
+
].join(' '),
|
|
22
30
|
'block-start': [
|
|
23
31
|
'order-0 basis-full py-2',
|
|
24
32
|
'[border-block-end-width:1px]',
|
|
@@ -47,13 +55,12 @@ class InputGroupComponent {
|
|
|
47
55
|
classes = computed(() => cn(GROUP_BASE, this.class()), /* @ts-ignore */
|
|
48
56
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
49
57
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
50
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupComponent, isStandalone: true, selector: "InputGroup", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
58
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupComponent, isStandalone: true, selector: "InputGroup", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
51
59
|
}
|
|
52
60
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupComponent, decorators: [{
|
|
53
61
|
type: Component,
|
|
54
62
|
args: [{
|
|
55
63
|
selector: 'InputGroup',
|
|
56
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
57
64
|
host: { '[class]': 'classes()' },
|
|
58
65
|
template: `<ng-content />`,
|
|
59
66
|
}]
|
|
@@ -66,13 +73,12 @@ class InputGroupAddonComponent {
|
|
|
66
73
|
classes = computed(() => cn(ADDON_BASE, addonAlignClasses[this.align()], this.class()), /* @ts-ignore */
|
|
67
74
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
68
75
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupAddonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
69
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupAddonComponent, isStandalone: true, selector: "InputGroupAddon", inputs: { align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-align": "align()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
76
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupAddonComponent, isStandalone: true, selector: "InputGroupAddon", inputs: { align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-align": "align()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
70
77
|
}
|
|
71
78
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupAddonComponent, decorators: [{
|
|
72
79
|
type: Component,
|
|
73
80
|
args: [{
|
|
74
81
|
selector: 'InputGroupAddon',
|
|
75
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
76
82
|
host: {
|
|
77
83
|
'[class]': 'classes()',
|
|
78
84
|
'[attr.data-align]': 'align()',
|
|
@@ -86,13 +92,12 @@ class InputGroupTextComponent {
|
|
|
86
92
|
classes = computed(() => cn('inline-flex items-center gap-1.5 whitespace-nowrap text-sm leading-none text-current', this.class()), /* @ts-ignore */
|
|
87
93
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
88
94
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupTextComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
89
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupTextComponent, isStandalone: true, selector: "InputGroupText", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
95
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupTextComponent, isStandalone: true, selector: "InputGroupText", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
90
96
|
}
|
|
91
97
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupTextComponent, decorators: [{
|
|
92
98
|
type: Component,
|
|
93
99
|
args: [{
|
|
94
100
|
selector: 'InputGroupText',
|
|
95
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
96
101
|
host: { '[class]': 'classes()' },
|
|
97
102
|
template: `<ng-content />`,
|
|
98
103
|
}]
|
|
@@ -107,13 +112,12 @@ class InputGroupButtonComponent {
|
|
|
107
112
|
classes = computed(() => cn(buttonVariants({ variant: this.variant(), size: this.size() }), 'shrink-0 shadow-none', this.class()), /* @ts-ignore */
|
|
108
113
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
109
114
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
110
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupButtonComponent, isStandalone: true, selector: "button[InputGroupButton], a[InputGroupButton]", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-size": "size()", "attr.data-variant": "variant()" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
115
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupButtonComponent, isStandalone: true, selector: "button[InputGroupButton], a[InputGroupButton]", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-size": "size()", "attr.data-variant": "variant()" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
111
116
|
}
|
|
112
117
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupButtonComponent, decorators: [{
|
|
113
118
|
type: Component,
|
|
114
119
|
args: [{
|
|
115
120
|
selector: 'button[InputGroupButton], a[InputGroupButton]',
|
|
116
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
117
121
|
host: {
|
|
118
122
|
'[class]': 'classes()',
|
|
119
123
|
'[attr.data-size]': 'size()',
|
|
@@ -132,13 +136,12 @@ class InputGroupInputComponent {
|
|
|
132
136
|
this.el.nativeElement.focus();
|
|
133
137
|
}
|
|
134
138
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
135
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupInputComponent, isStandalone: true, selector: "input[InputGroupInput]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-slot": "input-group-control" }, properties: { "class": "classes()" } }, ngImport: i0, template: '', isInline: true
|
|
139
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupInputComponent, isStandalone: true, selector: "input[InputGroupInput]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-slot": "input-group-control" }, properties: { "class": "classes()" } }, ngImport: i0, template: '', isInline: true });
|
|
136
140
|
}
|
|
137
141
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupInputComponent, decorators: [{
|
|
138
142
|
type: Component,
|
|
139
143
|
args: [{
|
|
140
144
|
selector: 'input[InputGroupInput]',
|
|
141
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
142
145
|
host: {
|
|
143
146
|
'[class]': 'classes()',
|
|
144
147
|
'data-slot': 'input-group-control',
|
|
@@ -156,13 +159,12 @@ class InputGroupTextareaComponent {
|
|
|
156
159
|
this.el.nativeElement.focus();
|
|
157
160
|
}
|
|
158
161
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupTextareaComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
159
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupTextareaComponent, isStandalone: true, selector: "textarea[InputGroupTextarea]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-slot": "input-group-control" }, properties: { "class": "classes()" } }, ngImport: i0, template: '', isInline: true
|
|
162
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputGroupTextareaComponent, isStandalone: true, selector: "textarea[InputGroupTextarea]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-slot": "input-group-control" }, properties: { "class": "classes()" } }, ngImport: i0, template: '', isInline: true });
|
|
160
163
|
}
|
|
161
164
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputGroupTextareaComponent, decorators: [{
|
|
162
165
|
type: Component,
|
|
163
166
|
args: [{
|
|
164
167
|
selector: 'textarea[InputGroupTextarea]',
|
|
165
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
166
168
|
host: {
|
|
167
169
|
'[class]': 'classes()',
|
|
168
170
|
'data-slot': 'input-group-control',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Directive, input, computed,
|
|
2
|
+
import { Directive, input, computed, Component, inject, numberAttribute, booleanAttribute, viewChild, ElementRef, Injector, output, linkedSignal, signal, contentChildren, forwardRef } from '@angular/core';
|
|
3
3
|
import { NgControl, NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
4
4
|
import { FormFieldContext } from '@ojiepermana/angular-component/form';
|
|
5
5
|
import { cn, uniqueId } from '@ojiepermana/angular-component/utils';
|
|
@@ -19,13 +19,12 @@ class InputOtpGroupComponent {
|
|
|
19
19
|
classes = computed(() => cn('flex items-center overflow-hidden rounded-md border border-input bg-background shadow-sm', this.class()), /* @ts-ignore */
|
|
20
20
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
21
21
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputOtpGroupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
22
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputOtpGroupComponent, isStandalone: true, selector: "InputOtpGroup", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"input-otp-group\"" } }, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
22
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputOtpGroupComponent, isStandalone: true, selector: "InputOtpGroup", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"input-otp-group\"" } }, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
23
23
|
}
|
|
24
24
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputOtpGroupComponent, decorators: [{
|
|
25
25
|
type: Component,
|
|
26
26
|
args: [{
|
|
27
27
|
selector: 'InputOtpGroup',
|
|
28
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
29
28
|
host: {
|
|
30
29
|
'[class]': 'classes()',
|
|
31
30
|
'[attr.data-slot]': '"input-otp-group"',
|
|
@@ -46,16 +45,16 @@ class InputOtpSeparatorComponent {
|
|
|
46
45
|
stroke="currentColor"
|
|
47
46
|
stroke-width="2"
|
|
48
47
|
stroke-linecap="round"
|
|
49
|
-
stroke-linejoin="round"
|
|
48
|
+
stroke-linejoin="round"
|
|
49
|
+
>
|
|
50
50
|
<path d="M5 12h14" />
|
|
51
51
|
</svg>
|
|
52
|
-
`, isInline: true
|
|
52
|
+
`, isInline: true });
|
|
53
53
|
}
|
|
54
54
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputOtpSeparatorComponent, decorators: [{
|
|
55
55
|
type: Component,
|
|
56
56
|
args: [{
|
|
57
57
|
selector: 'InputOtpSeparator',
|
|
58
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
59
58
|
host: {
|
|
60
59
|
'[class]': 'classes()',
|
|
61
60
|
'[attr.data-slot]': '"input-otp-separator"',
|
|
@@ -68,7 +67,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
68
67
|
stroke="currentColor"
|
|
69
68
|
stroke-width="2"
|
|
70
69
|
stroke-linecap="round"
|
|
71
|
-
stroke-linejoin="round"
|
|
70
|
+
stroke-linejoin="round"
|
|
71
|
+
>
|
|
72
72
|
<path d="M5 12h14" />
|
|
73
73
|
</svg>
|
|
74
74
|
`,
|
|
@@ -107,7 +107,8 @@ class InputOtpSlotComponent {
|
|
|
107
107
|
...(ngDevMode ? [{ debugName: "ariaDescribedBy" }] : /* istanbul ignore next */ []));
|
|
108
108
|
effectiveInvalid = computed(() => this.invalid() || this.ctx.isInvalid(), /* @ts-ignore */
|
|
109
109
|
...(ngDevMode ? [{ debugName: "effectiveInvalid" }] : /* istanbul ignore next */ []));
|
|
110
|
-
classes = computed(() => cn('relative flex h-10 w-10 items-center justify-center border-r border-border text-sm font-medium transition-[background-color,box-shadow,opacity] last:border-r-0', this.active() && !this.effectiveInvalid() && 'z-10 ring-1 ring-inset ring-ring', this.effectiveInvalid() &&
|
|
110
|
+
classes = computed(() => cn('relative flex h-10 w-10 items-center justify-center border-r border-border text-sm font-medium transition-[background-color,box-shadow,opacity] last:border-r-0', this.active() && !this.effectiveInvalid() && 'z-10 ring-1 ring-inset ring-ring', this.effectiveInvalid() &&
|
|
111
|
+
'bg-destructive/5 text-destructive ring-1 ring-inset ring-destructive/50', this.disabled() && 'opacity-50', this.class()), /* @ts-ignore */
|
|
111
112
|
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
112
113
|
focus(select = true) {
|
|
113
114
|
const input = this.inputRef().nativeElement;
|
|
@@ -152,14 +153,14 @@ class InputOtpSlotComponent {
|
|
|
152
153
|
(focus)="handleFocus()"
|
|
153
154
|
(input)="handleInput($event)"
|
|
154
155
|
(keydown)="handleKeydown($event)"
|
|
155
|
-
(paste)="handlePaste($event)"
|
|
156
|
-
|
|
156
|
+
(paste)="handlePaste($event)"
|
|
157
|
+
/>
|
|
158
|
+
`, isInline: true });
|
|
157
159
|
}
|
|
158
160
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputOtpSlotComponent, decorators: [{
|
|
159
161
|
type: Component,
|
|
160
162
|
args: [{
|
|
161
163
|
selector: 'InputOtpSlot',
|
|
162
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
163
164
|
host: {
|
|
164
165
|
'[class]': 'classes()',
|
|
165
166
|
'[attr.data-slot]': '"input-otp-slot"',
|
|
@@ -189,7 +190,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
189
190
|
(focus)="handleFocus()"
|
|
190
191
|
(input)="handleInput($event)"
|
|
191
192
|
(keydown)="handleKeydown($event)"
|
|
192
|
-
(paste)="handlePaste($event)"
|
|
193
|
+
(paste)="handlePaste($event)"
|
|
194
|
+
/>
|
|
193
195
|
`,
|
|
194
196
|
}]
|
|
195
197
|
}], propDecorators: { index: [{ type: i0.Input, args: [{ isSignal: true, alias: "index", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-invalid", required: false }] }], inputRef: [{ type: i0.ViewChild, args: ['inputRef', { isSignal: true }] }] } });
|
|
@@ -479,13 +481,12 @@ class InputOtpComponent extends InputOtpContextBase {
|
|
|
479
481
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.0.4", type: InputOtpComponent, isStandalone: true, selector: "InputOtp", inputs: { maxLengthInput: { classPropertyName: "maxLengthInput", publicName: "maxLength", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, pattern: { classPropertyName: "pattern", publicName: "pattern", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "aria-label", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledby: { classPropertyName: "ariaLabelledby", publicName: "aria-labelledby", isSignal: true, isRequired: false, transformFunction: null }, ariaDescribedby: { classPropertyName: "ariaDescribedby", publicName: "aria-describedby", isSignal: true, isRequired: false, transformFunction: null }, inputMode: { classPropertyName: "inputMode", publicName: "inputmode", isSignal: true, isRequired: false, transformFunction: null }, autocomplete: { classPropertyName: "autocomplete", publicName: "autocomplete", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalidInput: { classPropertyName: "invalidInput", publicName: "aria-invalid", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange" }, host: { listeners: { "focusout": "handleFocusOut($event)" }, properties: { "class": "classes()", "attr.id": "null", "attr.role": "\"group\"", "attr.data-slot": "\"input-otp\"", "attr.data-disabled": "disabled() ? \"\" : null", "attr.data-invalid": "isInvalid() ? \"\" : null", "attr.aria-label": "ariaLabel()", "attr.aria-labelledby": "ariaLabelledby()", "attr.aria-describedby": "describedBy()", "attr.aria-disabled": "disabled() ? \"true\" : null", "attr.aria-invalid": "isInvalid() ? \"true\" : null" } }, providers: [
|
|
480
482
|
{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => InputOtpComponent), multi: true },
|
|
481
483
|
{ provide: InputOtpContextBase, useExisting: forwardRef(() => InputOtpComponent) },
|
|
482
|
-
], queries: [{ propertyName: "slots", predicate: InputOtpSlotComponent, descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: `<ng-content />`, isInline: true
|
|
484
|
+
], queries: [{ propertyName: "slots", predicate: InputOtpSlotComponent, descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: `<ng-content />`, isInline: true });
|
|
483
485
|
}
|
|
484
486
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputOtpComponent, decorators: [{
|
|
485
487
|
type: Component,
|
|
486
488
|
args: [{
|
|
487
489
|
selector: 'InputOtp',
|
|
488
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
489
490
|
providers: [
|
|
490
491
|
{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => InputOtpComponent), multi: true },
|
|
491
492
|
{ provide: InputOtpContextBase, useExisting: forwardRef(() => InputOtpComponent) },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { inject, ElementRef, input, computed,
|
|
2
|
+
import { inject, ElementRef, input, computed, Component } from '@angular/core';
|
|
3
3
|
import { cn, radiusBaseValue, densityBaseValue } from '@ojiepermana/angular-component/utils';
|
|
4
4
|
|
|
5
5
|
const BASE = [
|
|
@@ -33,13 +33,12 @@ class InputComponent {
|
|
|
33
33
|
this.el.nativeElement.focus();
|
|
34
34
|
}
|
|
35
35
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
36
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputComponent, isStandalone: true, selector: "input[Input]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, radius: { classPropertyName: "radius", publicName: "radius", isSignal: true, isRequired: false, transformFunction: null }, density: { classPropertyName: "density", publicName: "density", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "style.--radius-base": "radiusBase()", "style.--spacing-base": "densityBase()" } }, ngImport: i0, template: '', isInline: true
|
|
36
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.4", type: InputComponent, isStandalone: true, selector: "input[Input]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, radius: { classPropertyName: "radius", publicName: "radius", isSignal: true, isRequired: false, transformFunction: null }, density: { classPropertyName: "density", publicName: "density", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "style.--radius-base": "radiusBase()", "style.--spacing-base": "densityBase()" } }, ngImport: i0, template: '', isInline: true });
|
|
37
37
|
}
|
|
38
38
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImport: i0, type: InputComponent, decorators: [{
|
|
39
39
|
type: Component,
|
|
40
40
|
args: [{
|
|
41
41
|
selector: 'input[Input]',
|
|
42
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
43
42
|
host: {
|
|
44
43
|
'[class]': 'classes()',
|
|
45
44
|
'[style.--radius-base]': 'radiusBase()',
|