@egose/shadcn-theme-ng 0.0.13 → 0.0.15
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/fesm2022/accordion.mjs +10 -10
- package/alert/fesm2022/alert.mjs +30 -30
- package/autocomplete/fesm2022/autocomplete.mjs +11 -11
- package/badge/fesm2022/badge.mjs +53 -53
- package/basic-alert/fesm2022/basic-alert.mjs +2 -2
- package/button/fesm2022/button.mjs +108 -108
- package/calendar/fesm2022/calendar.mjs +78 -78
- package/checkbox/README.md +64 -0
- package/checkbox/fesm2022/checkbox.mjs +146 -0
- package/checkbox/fesm2022/checkbox.mjs.map +1 -0
- package/checkbox/index.d.ts +55 -0
- package/confirmation-dialog/fesm2022/confirmation-dialog.mjs +10 -10
- package/date-picker/fesm2022/date-picker.mjs +11 -11
- package/dialog/fesm2022/dialog.mjs +9 -9
- package/exports.json +1 -1
- package/form-checkbox/README.md +64 -0
- package/form-checkbox/fesm2022/form-checkbox.mjs +134 -0
- package/form-checkbox/fesm2022/form-checkbox.mjs.map +1 -0
- package/form-checkbox/index.d.ts +26 -0
- package/form-date-picker/fesm2022/form-date-picker.mjs +9 -9
- package/form-field/fesm2022/form-field.mjs +3 -3
- package/form-field-simple/README.md +64 -0
- package/form-field-simple/fesm2022/form-field-simple.mjs +82 -0
- package/form-field-simple/fesm2022/form-field-simple.mjs.map +1 -0
- package/form-field-simple/index.d.ts +22 -0
- package/form-searchable-multiselect/fesm2022/form-searchable-multiselect.mjs +27 -20
- package/form-searchable-multiselect/fesm2022/form-searchable-multiselect.mjs.map +1 -1
- package/form-select/fesm2022/form-select.mjs +9 -9
- package/form-text-input/fesm2022/form-text-input.mjs +9 -9
- package/form-textarea/fesm2022/form-textarea.mjs +9 -9
- package/input/fesm2022/input.mjs +3 -3
- package/label/fesm2022/label.mjs +1 -1
- package/package.json +13 -1
- package/popover/fesm2022/popover.mjs +2 -2
- package/radio-group/fesm2022/radio-group.mjs +5 -5
- package/searchable-multiselect/fesm2022/searchable-multiselect.mjs +20 -20
- package/select/fesm2022/select.mjs +18 -18
- package/separator/fesm2022/separator.mjs +1 -1
- package/sonner/fesm2022/sonner.mjs +4 -4
- package/spinner/fesm2022/spinner.mjs +6 -6
- package/switch/fesm2022/switch.mjs +2 -2
- package/tabs/fesm2022/tabs.mjs +12 -12
- package/tooltip/fesm2022/tooltip.mjs +5 -5
|
@@ -30,13 +30,13 @@ class EgFormSelect {
|
|
|
30
30
|
errorClass = input('', ...(ngDevMode ? [{ debugName: "errorClass" }] : []));
|
|
31
31
|
hintClass = input('', ...(ngDevMode ? [{ debugName: "hintClass" }] : []));
|
|
32
32
|
// Computed classes
|
|
33
|
-
$userClass = computed(() => hlm('
|
|
34
|
-
$labelClass = computed(() => hlm('
|
|
35
|
-
$selectClass = computed(() => hlm('
|
|
36
|
-
$errorClass = computed(() => hlm('
|
|
37
|
-
$hintClass = computed(() => hlm('
|
|
33
|
+
$userClass = computed(() => hlm('flex flex-col', this.userClass()), ...(ngDevMode ? [{ debugName: "$userClass" }] : []));
|
|
34
|
+
$labelClass = computed(() => hlm('mb-1 gap-0', this.labelClass()), ...(ngDevMode ? [{ debugName: "$labelClass" }] : []));
|
|
35
|
+
$selectClass = computed(() => hlm('w-full', this.selectClass()), ...(ngDevMode ? [{ debugName: "$selectClass" }] : []));
|
|
36
|
+
$errorClass = computed(() => hlm('mt-0', this.errorClass()), ...(ngDevMode ? [{ debugName: "$errorClass" }] : []));
|
|
37
|
+
$hintClass = computed(() => hlm('mt-0', this.hintClass()), ...(ngDevMode ? [{ debugName: "$hintClass" }] : []));
|
|
38
38
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: EgFormSelect, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
39
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: EgFormSelect, isStandalone: true, selector: "eg-form-select", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, controlName: { classPropertyName: "controlName", publicName: "controlName", isSignal: true, isRequired: false, transformFunction: null }, error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null }, optionsLabel: { classPropertyName: "optionsLabel", publicName: "optionsLabel", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, labelClass: { classPropertyName: "labelClass", publicName: "labelClass", isSignal: true, isRequired: false, transformFunction: null }, selectClass: { classPropertyName: "selectClass", publicName: "selectClass", isSignal: true, isRequired: false, transformFunction: null }, errorClass: { classPropertyName: "errorClass", publicName: "errorClass", isSignal: true, isRequired: false, transformFunction: null }, hintClass: { classPropertyName: "hintClass", publicName: "hintClass", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "
|
|
39
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: EgFormSelect, isStandalone: true, selector: "eg-form-select", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, controlName: { classPropertyName: "controlName", publicName: "controlName", isSignal: true, isRequired: false, transformFunction: null }, error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null }, optionsLabel: { classPropertyName: "optionsLabel", publicName: "optionsLabel", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, labelClass: { classPropertyName: "labelClass", publicName: "labelClass", isSignal: true, isRequired: false, transformFunction: null }, selectClass: { classPropertyName: "selectClass", publicName: "selectClass", isSignal: true, isRequired: false, transformFunction: null }, errorClass: { classPropertyName: "errorClass", publicName: "errorClass", isSignal: true, isRequired: false, transformFunction: null }, hintClass: { classPropertyName: "hintClass", publicName: "hintClass", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "w-full" }, providers: [{ provide: ControlContainer, useExisting: FormGroupDirective }], ngImport: i0, template: `
|
|
40
40
|
@let lbl = label();
|
|
41
41
|
@let nm = controlName();
|
|
42
42
|
@let err = error();
|
|
@@ -47,7 +47,7 @@ class EgFormSelect {
|
|
|
47
47
|
@if (lbl) {
|
|
48
48
|
<span hlmLabel [class]="$labelClass()">{{ lbl }}
|
|
49
49
|
@if (rqrd) {
|
|
50
|
-
<span class="
|
|
50
|
+
<span class="text-red-500">*</span>
|
|
51
51
|
}
|
|
52
52
|
</span>
|
|
53
53
|
}
|
|
@@ -94,7 +94,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
94
94
|
selector: 'eg-form-select',
|
|
95
95
|
standalone: true,
|
|
96
96
|
host: {
|
|
97
|
-
class: '
|
|
97
|
+
class: 'w-full',
|
|
98
98
|
},
|
|
99
99
|
imports: [ReactiveFormsModule, HlmFormField, HlmError, HlmHint, HlmLabel, BrnSelectImports, HlmSelectImports],
|
|
100
100
|
providers: [{ provide: ControlContainer, useExisting: FormGroupDirective }],
|
|
@@ -110,7 +110,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
110
110
|
@if (lbl) {
|
|
111
111
|
<span hlmLabel [class]="$labelClass()">{{ lbl }}
|
|
112
112
|
@if (rqrd) {
|
|
113
|
-
<span class="
|
|
113
|
+
<span class="text-red-500">*</span>
|
|
114
114
|
}
|
|
115
115
|
</span>
|
|
116
116
|
}
|
|
@@ -66,13 +66,13 @@ class EgFormTextInput {
|
|
|
66
66
|
errorClass = input('', ...(ngDevMode ? [{ debugName: "errorClass" }] : []));
|
|
67
67
|
hintClass = input('', ...(ngDevMode ? [{ debugName: "hintClass" }] : []));
|
|
68
68
|
// Computed class bindings
|
|
69
|
-
$userClass = computed(() => hlm('
|
|
70
|
-
$labelClass = computed(() => hlm('
|
|
71
|
-
$inputClass = computed(() => hlm('
|
|
72
|
-
$errorClass = computed(() => hlm('
|
|
73
|
-
$hintClass = computed(() => hlm('
|
|
69
|
+
$userClass = computed(() => hlm('flex flex-col', this.userClass()), ...(ngDevMode ? [{ debugName: "$userClass" }] : []));
|
|
70
|
+
$labelClass = computed(() => hlm('mb-1 gap-0', this.labelClass()), ...(ngDevMode ? [{ debugName: "$labelClass" }] : []));
|
|
71
|
+
$inputClass = computed(() => hlm('mb-1', this.inputClass()), ...(ngDevMode ? [{ debugName: "$inputClass" }] : []));
|
|
72
|
+
$errorClass = computed(() => hlm('mt-0', this.errorClass()), ...(ngDevMode ? [{ debugName: "$errorClass" }] : []));
|
|
73
|
+
$hintClass = computed(() => hlm('mt-0', this.hintClass()), ...(ngDevMode ? [{ debugName: "$hintClass" }] : []));
|
|
74
74
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: EgFormTextInput, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
75
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: EgFormTextInput, isStandalone: true, selector: "eg-form-text-input", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, controlName: { classPropertyName: "controlName", publicName: "controlName", isSignal: true, isRequired: false, transformFunction: null }, error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, maxlength: { classPropertyName: "maxlength", publicName: "maxlength", isSignal: true, isRequired: false, transformFunction: null }, minlength: { classPropertyName: "minlength", publicName: "minlength", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, pattern: { classPropertyName: "pattern", publicName: "pattern", isSignal: true, isRequired: false, transformFunction: null }, autocomplete: { classPropertyName: "autocomplete", publicName: "autocomplete", isSignal: true, isRequired: false, transformFunction: null }, autofocus: { classPropertyName: "autofocus", publicName: "autofocus", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, labelClass: { classPropertyName: "labelClass", publicName: "labelClass", isSignal: true, isRequired: false, transformFunction: null }, inputClass: { classPropertyName: "inputClass", publicName: "inputClass", isSignal: true, isRequired: false, transformFunction: null }, errorClass: { classPropertyName: "errorClass", publicName: "errorClass", isSignal: true, isRequired: false, transformFunction: null }, hintClass: { classPropertyName: "hintClass", publicName: "hintClass", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "
|
|
75
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: EgFormTextInput, isStandalone: true, selector: "eg-form-text-input", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, controlName: { classPropertyName: "controlName", publicName: "controlName", isSignal: true, isRequired: false, transformFunction: null }, error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, maxlength: { classPropertyName: "maxlength", publicName: "maxlength", isSignal: true, isRequired: false, transformFunction: null }, minlength: { classPropertyName: "minlength", publicName: "minlength", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, pattern: { classPropertyName: "pattern", publicName: "pattern", isSignal: true, isRequired: false, transformFunction: null }, autocomplete: { classPropertyName: "autocomplete", publicName: "autocomplete", isSignal: true, isRequired: false, transformFunction: null }, autofocus: { classPropertyName: "autofocus", publicName: "autofocus", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, labelClass: { classPropertyName: "labelClass", publicName: "labelClass", isSignal: true, isRequired: false, transformFunction: null }, inputClass: { classPropertyName: "inputClass", publicName: "inputClass", isSignal: true, isRequired: false, transformFunction: null }, errorClass: { classPropertyName: "errorClass", publicName: "errorClass", isSignal: true, isRequired: false, transformFunction: null }, hintClass: { classPropertyName: "hintClass", publicName: "hintClass", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "w-full" }, providers: [{ provide: ControlContainer, useExisting: FormGroupDirective }], ngImport: i0, template: `
|
|
76
76
|
@let lbl = label();
|
|
77
77
|
@let nm = controlName();
|
|
78
78
|
@let err = error();
|
|
@@ -83,7 +83,7 @@ class EgFormTextInput {
|
|
|
83
83
|
@if (lbl) {
|
|
84
84
|
<span hlmLabel [class]="$labelClass()">{{ lbl }}
|
|
85
85
|
@if (rqrd) {
|
|
86
|
-
<span class="
|
|
86
|
+
<span class="text-red-500">*</span>
|
|
87
87
|
}
|
|
88
88
|
</span>
|
|
89
89
|
}
|
|
@@ -128,7 +128,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
128
128
|
selector: 'eg-form-text-input',
|
|
129
129
|
standalone: true,
|
|
130
130
|
host: {
|
|
131
|
-
class: '
|
|
131
|
+
class: 'w-full',
|
|
132
132
|
},
|
|
133
133
|
imports: [ReactiveFormsModule, HlmFormField, HlmError, HlmHint, HlmLabel, HlmInput],
|
|
134
134
|
providers: [{ provide: ControlContainer, useExisting: FormGroupDirective }],
|
|
@@ -144,7 +144,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
144
144
|
@if (lbl) {
|
|
145
145
|
<span hlmLabel [class]="$labelClass()">{{ lbl }}
|
|
146
146
|
@if (rqrd) {
|
|
147
|
-
<span class="
|
|
147
|
+
<span class="text-red-500">*</span>
|
|
148
148
|
}
|
|
149
149
|
</span>
|
|
150
150
|
}
|
|
@@ -33,13 +33,13 @@ class EgFormTextarea {
|
|
|
33
33
|
errorClass = input('', ...(ngDevMode ? [{ debugName: "errorClass" }] : []));
|
|
34
34
|
hintClass = input('', ...(ngDevMode ? [{ debugName: "hintClass" }] : []));
|
|
35
35
|
// Computed class bindings
|
|
36
|
-
$userClass = computed(() => hlm('
|
|
37
|
-
$labelClass = computed(() => hlm('
|
|
38
|
-
$textareaClass = computed(() => hlm('
|
|
39
|
-
$errorClass = computed(() => hlm('
|
|
40
|
-
$hintClass = computed(() => hlm('
|
|
36
|
+
$userClass = computed(() => hlm('flex flex-col', this.userClass()), ...(ngDevMode ? [{ debugName: "$userClass" }] : []));
|
|
37
|
+
$labelClass = computed(() => hlm('mb-1 gap-0', this.labelClass()), ...(ngDevMode ? [{ debugName: "$labelClass" }] : []));
|
|
38
|
+
$textareaClass = computed(() => hlm('mb-1', this.textareaClass()), ...(ngDevMode ? [{ debugName: "$textareaClass" }] : []));
|
|
39
|
+
$errorClass = computed(() => hlm('mt-0', this.errorClass()), ...(ngDevMode ? [{ debugName: "$errorClass" }] : []));
|
|
40
|
+
$hintClass = computed(() => hlm('mt-0', this.hintClass()), ...(ngDevMode ? [{ debugName: "$hintClass" }] : []));
|
|
41
41
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: EgFormTextarea, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
42
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: EgFormTextarea, isStandalone: true, selector: "eg-form-textarea", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, controlName: { classPropertyName: "controlName", publicName: "controlName", isSignal: true, isRequired: false, transformFunction: null }, error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, maxlength: { classPropertyName: "maxlength", publicName: "maxlength", isSignal: true, isRequired: false, transformFunction: null }, minlength: { classPropertyName: "minlength", publicName: "minlength", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, cols: { classPropertyName: "cols", publicName: "cols", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, labelClass: { classPropertyName: "labelClass", publicName: "labelClass", isSignal: true, isRequired: false, transformFunction: null }, textareaClass: { classPropertyName: "textareaClass", publicName: "textareaClass", isSignal: true, isRequired: false, transformFunction: null }, errorClass: { classPropertyName: "errorClass", publicName: "errorClass", isSignal: true, isRequired: false, transformFunction: null }, hintClass: { classPropertyName: "hintClass", publicName: "hintClass", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "
|
|
42
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: EgFormTextarea, isStandalone: true, selector: "eg-form-textarea", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, controlName: { classPropertyName: "controlName", publicName: "controlName", isSignal: true, isRequired: false, transformFunction: null }, error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null }, hint: { classPropertyName: "hint", publicName: "hint", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, maxlength: { classPropertyName: "maxlength", publicName: "maxlength", isSignal: true, isRequired: false, transformFunction: null }, minlength: { classPropertyName: "minlength", publicName: "minlength", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, cols: { classPropertyName: "cols", publicName: "cols", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, labelClass: { classPropertyName: "labelClass", publicName: "labelClass", isSignal: true, isRequired: false, transformFunction: null }, textareaClass: { classPropertyName: "textareaClass", publicName: "textareaClass", isSignal: true, isRequired: false, transformFunction: null }, errorClass: { classPropertyName: "errorClass", publicName: "errorClass", isSignal: true, isRequired: false, transformFunction: null }, hintClass: { classPropertyName: "hintClass", publicName: "hintClass", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "w-full" }, providers: [{ provide: ControlContainer, useExisting: FormGroupDirective }], ngImport: i0, template: `
|
|
43
43
|
@let lbl = label();
|
|
44
44
|
@let nm = controlName();
|
|
45
45
|
@let err = error();
|
|
@@ -50,7 +50,7 @@ class EgFormTextarea {
|
|
|
50
50
|
@if (lbl) {
|
|
51
51
|
<span hlmLabel [class]="$labelClass()">{{ lbl }}
|
|
52
52
|
@if (rqrd) {
|
|
53
|
-
<span class="
|
|
53
|
+
<span class="text-red-500">*</span>
|
|
54
54
|
}
|
|
55
55
|
</span>
|
|
56
56
|
}
|
|
@@ -91,7 +91,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
91
91
|
selector: 'eg-form-textarea',
|
|
92
92
|
standalone: true,
|
|
93
93
|
host: {
|
|
94
|
-
class: '
|
|
94
|
+
class: 'w-full',
|
|
95
95
|
},
|
|
96
96
|
imports: [ReactiveFormsModule, HlmFormField, HlmError, HlmHint, HlmLabel, HlmInput],
|
|
97
97
|
providers: [{ provide: ControlContainer, useExisting: FormGroupDirective }],
|
|
@@ -107,7 +107,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
107
107
|
@if (lbl) {
|
|
108
108
|
<span hlmLabel [class]="$labelClass()">{{ lbl }}
|
|
109
109
|
@if (rqrd) {
|
|
110
|
-
<span class="
|
|
110
|
+
<span class="text-red-500">*</span>
|
|
111
111
|
}
|
|
112
112
|
</span>
|
|
113
113
|
}
|
package/input/fesm2022/input.mjs
CHANGED
|
@@ -6,11 +6,11 @@ import { ErrorStateMatcher, ErrorStateTracker } from '@spartan-ng/brain/forms';
|
|
|
6
6
|
import { hlm } from '@egose/shadcn-theme-ng/utils';
|
|
7
7
|
import { cva } from 'class-variance-authority';
|
|
8
8
|
|
|
9
|
-
const inputVariants = cva('
|
|
9
|
+
const inputVariants = cva('file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/10 border-input shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 flex h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base outline-none transition-[color,box-shadow] file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:ring-[3px] disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm', {
|
|
10
10
|
variants: {
|
|
11
11
|
error: {
|
|
12
|
-
auto: '
|
|
13
|
-
true: '
|
|
12
|
+
auto: '[&.ng-invalid.ng-touched]:text-destructive/20 dark:[&.ng-invalid.ng-touched]:text-destructive/40 [&.ng-invalid.ng-touched]:border-destructive [&.ng-invalid.ng-touched]:focus-visible:ring-destructive',
|
|
13
|
+
true: 'text-destructive/90 dark:text-destructive/60 border-destructive focus-visible:ring-destructive',
|
|
14
14
|
},
|
|
15
15
|
},
|
|
16
16
|
defaultVariants: {
|
package/label/fesm2022/label.mjs
CHANGED
|
@@ -6,7 +6,7 @@ import { hlm } from '@egose/shadcn-theme-ng/utils';
|
|
|
6
6
|
|
|
7
7
|
class HlmLabel {
|
|
8
8
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
9
|
-
_computedClass = computed(() => hlm('
|
|
9
|
+
_computedClass = computed(() => hlm('flex select-none items-center gap-2 text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-50 has-[[disabled]]:cursor-not-allowed has-[[disabled]]:opacity-50 group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-data-[disabled]:cursor-not-allowed peer-data-[disabled]:opacity-50', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
10
10
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmLabel, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
11
11
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmLabel, isStandalone: true, selector: "[hlmLabel]", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, hostDirectives: [{ directive: i1.BrnLabel, inputs: ["id", "id"] }], ngImport: i0 });
|
|
12
12
|
}
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.0.
|
|
2
|
+
"version": "0.0.15",
|
|
3
3
|
"description": "Angular shadcn UI theme",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"sideEffects": false,
|
|
@@ -63,6 +63,14 @@
|
|
|
63
63
|
"types": "./form-field/index.d.ts",
|
|
64
64
|
"default": "./form-field/fesm2022/form-field.mjs"
|
|
65
65
|
},
|
|
66
|
+
"./form-field-simple": {
|
|
67
|
+
"types": "./form-field-simple/index.d.ts",
|
|
68
|
+
"default": "./form-field-simple/fesm2022/form-field-simple.mjs"
|
|
69
|
+
},
|
|
70
|
+
"./checkbox": {
|
|
71
|
+
"types": "./checkbox/index.d.ts",
|
|
72
|
+
"default": "./checkbox/fesm2022/checkbox.mjs"
|
|
73
|
+
},
|
|
66
74
|
"./popover": {
|
|
67
75
|
"types": "./popover/index.d.ts",
|
|
68
76
|
"default": "./popover/fesm2022/popover.mjs"
|
|
@@ -134,6 +142,10 @@
|
|
|
134
142
|
"./form-searchable-multiselect": {
|
|
135
143
|
"types": "./form-searchable-multiselect/index.d.ts",
|
|
136
144
|
"default": "./form-searchable-multiselect/fesm2022/form-searchable-multiselect.mjs"
|
|
145
|
+
},
|
|
146
|
+
"./form-checkbox": {
|
|
147
|
+
"types": "./form-checkbox/index.d.ts",
|
|
148
|
+
"default": "./form-checkbox/fesm2022/form-checkbox.mjs"
|
|
137
149
|
}
|
|
138
150
|
}
|
|
139
151
|
}
|
|
@@ -5,7 +5,7 @@ import { injectExposesStateProvider } from '@spartan-ng/brain/core';
|
|
|
5
5
|
|
|
6
6
|
class HlmPopoverClose {
|
|
7
7
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
8
|
-
_computedClass = computed(() => hlm('
|
|
8
|
+
_computedClass = computed(() => hlm('ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute right-4 top-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:pointer-events-none', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
9
9
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmPopoverClose, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
10
10
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmPopoverClose, isStandalone: true, selector: "[hlmPopoverClose],[brnPopoverClose][hlm]", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, ngImport: i0 });
|
|
11
11
|
}
|
|
@@ -30,7 +30,7 @@ class HlmPopoverContent {
|
|
|
30
30
|
});
|
|
31
31
|
}
|
|
32
32
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
33
|
-
_computedClass = computed(() => hlm('
|
|
33
|
+
_computedClass = computed(() => hlm('border-border bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative w-72 rounded-md border p-4 shadow-md outline-none', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
34
34
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmPopoverContent, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
35
35
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmPopoverContent, isStandalone: true, selector: "[hlmPopoverContent],[brnPopoverContent][hlm]", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, ngImport: i0 });
|
|
36
36
|
}
|
|
@@ -11,7 +11,7 @@ class HlmRadio {
|
|
|
11
11
|
_elementRef = inject(ElementRef);
|
|
12
12
|
_isBrowser = isPlatformBrowser(inject(PLATFORM_ID));
|
|
13
13
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
14
|
-
_computedClass = computed(() => hlm('
|
|
14
|
+
_computedClass = computed(() => hlm('group flex items-center gap-x-3', this.userClass(), this._state().disabled() ? 'cursor-not-allowed opacity-50' : ''), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
15
15
|
/** Used to set the id on the underlying brn element. */
|
|
16
16
|
id = input(undefined, ...(ngDevMode ? [{ debugName: "id" }] : []));
|
|
17
17
|
/** Used to set the aria-label attribute on the underlying brn element. */
|
|
@@ -104,7 +104,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
104
104
|
|
|
105
105
|
class HlmRadioGroup {
|
|
106
106
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
107
|
-
_computedClass = computed(() => hlm('
|
|
107
|
+
_computedClass = computed(() => hlm('grid gap-3', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
108
108
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmRadioGroup, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
109
109
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.1", type: HlmRadioGroup, isStandalone: true, selector: "hlm-radio-group", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, hostDirectives: [{ directive: i1.BrnRadioGroup, inputs: ["name", "name", "value", "value", "disabled", "disabled", "required", "required", "direction", "direction"], outputs: ["valueChange", "valueChange"] }], ngImport: i0, template: '<ng-content />', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
110
110
|
}
|
|
@@ -129,9 +129,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
129
129
|
|
|
130
130
|
class HlmRadioIndicator {
|
|
131
131
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
132
|
-
_computedClass = computed(() => hlm('
|
|
132
|
+
_computedClass = computed(() => hlm('border-input text-primary group-has-[:focus-visible]:border-ring group-has-[:focus-visible]:ring-ring/50 dark:bg-input/10 shadow-xs group-data=[disabled=true]:cursor-not-allowed group-data=[disabled=true]:opacity-50 relative flex aspect-square size-4 shrink-0 items-center justify-center rounded-full border outline-none transition-[color,box-shadow] group-has-[:focus-visible]:ring-[3px]', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
133
133
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmRadioIndicator, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
134
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.1", type: HlmRadioIndicator, isStandalone: true, selector: "hlm-radio-indicator", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, ngImport: i0, template: ` <div class="
|
|
134
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.1", type: HlmRadioIndicator, isStandalone: true, selector: "hlm-radio-indicator", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, ngImport: i0, template: ` <div class="group-data-[checked=true]:bg-primary size-2 rounded-full bg-transparent"></div> `, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
135
135
|
}
|
|
136
136
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmRadioIndicator, decorators: [{
|
|
137
137
|
type: Component,
|
|
@@ -140,7 +140,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
140
140
|
host: {
|
|
141
141
|
'[class]': '_computedClass()',
|
|
142
142
|
},
|
|
143
|
-
template: ` <div class="
|
|
143
|
+
template: ` <div class="group-data-[checked=true]:bg-primary size-2 rounded-full bg-transparent"></div> `,
|
|
144
144
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
145
145
|
}]
|
|
146
146
|
}] });
|
|
@@ -100,32 +100,32 @@ class EgSearchableMultiselect {
|
|
|
100
100
|
multi: true,
|
|
101
101
|
},
|
|
102
102
|
], viewQueries: [{ propertyName: "autoComplete", first: true, predicate: HlmAutocomplete, descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
103
|
-
<div class="
|
|
103
|
+
<div class="flex flex-col gap-2 w-full">
|
|
104
104
|
<!-- Selected items -->
|
|
105
105
|
<div
|
|
106
|
-
class="
|
|
107
|
-
|
|
108
|
-
|
|
106
|
+
class="flex gap-2 overflow-x-auto whitespace-nowrap
|
|
107
|
+
[scrollbar-width:none] [-ms-overflow-style:none]
|
|
108
|
+
[&::-webkit-scrollbar]:hidden"
|
|
109
109
|
>
|
|
110
110
|
@if (selectedItems().length === 0) {
|
|
111
111
|
<span
|
|
112
|
-
class="
|
|
113
|
-
|
|
112
|
+
class="bg-gray-100 text-gray-400 rounded-full
|
|
113
|
+
px-2 py-1 inline-flex items-center text-xs"
|
|
114
114
|
>
|
|
115
115
|
{{ placeholder() }}
|
|
116
116
|
</span>
|
|
117
117
|
} @else {
|
|
118
118
|
@for (item of selectedItems(); track item.value) {
|
|
119
119
|
<span
|
|
120
|
-
class="
|
|
121
|
-
|
|
120
|
+
class="bg-gray-200 rounded-full px-2 py-1
|
|
121
|
+
inline-flex items-center gap-2 text-xs"
|
|
122
122
|
>
|
|
123
123
|
{{ item.label }}
|
|
124
124
|
<button
|
|
125
125
|
type="button"
|
|
126
126
|
(click)="removeItem(item.value)"
|
|
127
|
-
class="
|
|
128
|
-
|
|
127
|
+
class="bg-transparent border-0 text-gray-600
|
|
128
|
+
hover:text-red-500 cursor-pointer"
|
|
129
129
|
>
|
|
130
130
|
✕
|
|
131
131
|
</button>
|
|
@@ -161,32 +161,32 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
161
161
|
},
|
|
162
162
|
],
|
|
163
163
|
template: `
|
|
164
|
-
<div class="
|
|
164
|
+
<div class="flex flex-col gap-2 w-full">
|
|
165
165
|
<!-- Selected items -->
|
|
166
166
|
<div
|
|
167
|
-
class="
|
|
168
|
-
|
|
169
|
-
|
|
167
|
+
class="flex gap-2 overflow-x-auto whitespace-nowrap
|
|
168
|
+
[scrollbar-width:none] [-ms-overflow-style:none]
|
|
169
|
+
[&::-webkit-scrollbar]:hidden"
|
|
170
170
|
>
|
|
171
171
|
@if (selectedItems().length === 0) {
|
|
172
172
|
<span
|
|
173
|
-
class="
|
|
174
|
-
|
|
173
|
+
class="bg-gray-100 text-gray-400 rounded-full
|
|
174
|
+
px-2 py-1 inline-flex items-center text-xs"
|
|
175
175
|
>
|
|
176
176
|
{{ placeholder() }}
|
|
177
177
|
</span>
|
|
178
178
|
} @else {
|
|
179
179
|
@for (item of selectedItems(); track item.value) {
|
|
180
180
|
<span
|
|
181
|
-
class="
|
|
182
|
-
|
|
181
|
+
class="bg-gray-200 rounded-full px-2 py-1
|
|
182
|
+
inline-flex items-center gap-2 text-xs"
|
|
183
183
|
>
|
|
184
184
|
{{ item.label }}
|
|
185
185
|
<button
|
|
186
186
|
type="button"
|
|
187
187
|
(click)="removeItem(item.value)"
|
|
188
|
-
class="
|
|
189
|
-
|
|
188
|
+
class="bg-transparent border-0 text-gray-600
|
|
189
|
+
hover:text-red-500 cursor-pointer"
|
|
190
190
|
>
|
|
191
191
|
✕
|
|
192
192
|
</button>
|
|
@@ -11,7 +11,7 @@ import { cva } from 'class-variance-authority';
|
|
|
11
11
|
|
|
12
12
|
class HlmSelect {
|
|
13
13
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
14
|
-
_computedClass = computed(() => hlm('
|
|
14
|
+
_computedClass = computed(() => hlm('space-y-2', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
15
15
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelect, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
16
16
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelect, isStandalone: true, selector: "hlm-select, brn-select [hlm]", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, ngImport: i0 });
|
|
17
17
|
}
|
|
@@ -32,7 +32,7 @@ class HlmSelectContent {
|
|
|
32
32
|
}]));
|
|
33
33
|
_stateProvider = injectExposesStateProvider({ optional: true });
|
|
34
34
|
_sideProvider = injectExposedSideProvider({ optional: true });
|
|
35
|
-
_computedClass = computed(() => hlm('
|
|
35
|
+
_computedClass = computed(() => hlm('border-border bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 w-full min-w-[8rem] overflow-hidden rounded-md border p-1 shadow-md data-[side=bottom]:top-[2px] data-[side=top]:bottom-[2px]', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
36
36
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectContent, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
37
37
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelectContent, isStandalone: true, selector: "[hlmSelectContent], hlm-select-content", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, stickyLabels: { classPropertyName: "stickyLabels", publicName: "stickyLabels", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()", "attr.data-state": "_stateProvider?.state() ?? \"open\"", "attr.data-side": "_sideProvider?.side() ?? \"bottom\"" } }, ngImport: i0 });
|
|
38
38
|
}
|
|
@@ -69,7 +69,7 @@ class HlmSelectLabel {
|
|
|
69
69
|
_selectContent = inject(HlmSelectContent);
|
|
70
70
|
_stickyLabels = computed(() => this._selectContent.stickyLabels(), ...(ngDevMode ? [{ debugName: "_stickyLabels" }] : []));
|
|
71
71
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
72
|
-
_computedClass = computed(() => hlm('
|
|
72
|
+
_computedClass = computed(() => hlm('text-muted-foreground px-2 py-1.5 text-xs', this._stickyLabels() ? 'bg-popover sticky top-0 z-[2] block' : '', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
73
73
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectLabel, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
74
74
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelectLabel, isStandalone: true, selector: "[hlmSelectLabel], hlm-select-label", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, hostDirectives: [{ directive: i1.BrnSelectLabel }], ngImport: i0 });
|
|
75
75
|
}
|
|
@@ -87,10 +87,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
87
87
|
class HlmSelectOption {
|
|
88
88
|
_brnSelectOption = inject(BrnSelectOption, { host: true });
|
|
89
89
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
90
|
-
_computedClass = computed(() => hlm('
|
|
90
|
+
_computedClass = computed(() => hlm('data-[active]:bg-accent data-[active]:text-accent-foreground [&>ng-icon]:text-muted-foreground *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2 relative flex w-full cursor-default select-none items-center gap-2 rounded-sm py-1.5 pl-2 pr-8 text-sm outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>ng-icon]:pointer-events-none [&>ng-icon]:size-4 [&>ng-icon]:shrink-0', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
91
91
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectOption, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
92
92
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.1", type: HlmSelectOption, isStandalone: true, selector: "hlm-option", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, providers: [provideIcons({ lucideCheck })], hostDirectives: [{ directive: i1.BrnSelectOption, inputs: ["disabled", "disabled", "value", "value"] }], ngImport: i0, template: `
|
|
93
|
-
<span class="
|
|
93
|
+
<span class="absolute right-2 flex size-3.5 items-center justify-center">
|
|
94
94
|
@if (this._brnSelectOption.selected()) {
|
|
95
95
|
<ng-icon hlm size="sm" aria-hidden="true" name="lucideCheck" />
|
|
96
96
|
}
|
|
@@ -110,7 +110,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
110
110
|
'[class]': '_computedClass()',
|
|
111
111
|
},
|
|
112
112
|
template: `
|
|
113
|
-
<span class="
|
|
113
|
+
<span class="absolute right-2 flex size-3.5 items-center justify-center">
|
|
114
114
|
@if (this._brnSelectOption.selected()) {
|
|
115
115
|
<ng-icon hlm size="sm" aria-hidden="true" name="lucideCheck" />
|
|
116
116
|
}
|
|
@@ -124,9 +124,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
124
124
|
|
|
125
125
|
class HlmSelectScrollDown {
|
|
126
126
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
127
|
-
_computedClass = computed(() => hlm('
|
|
127
|
+
_computedClass = computed(() => hlm('flex cursor-default items-center justify-center py-1', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
128
128
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectScrollDown, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
129
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelectScrollDown, isStandalone: true, selector: "hlm-select-scroll-down", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, providers: [provideIcons({ lucideChevronDown })], ngImport: i0, template: ` <ng-icon hlm size="sm" class="
|
|
129
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelectScrollDown, isStandalone: true, selector: "hlm-select-scroll-down", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, providers: [provideIcons({ lucideChevronDown })], ngImport: i0, template: ` <ng-icon hlm size="sm" class="ml-2" name="lucideChevronDown" /> `, isInline: true, dependencies: [{ kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "directive", type: HlmIcon, selector: "ng-icon[hlm]", inputs: ["size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
130
130
|
}
|
|
131
131
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectScrollDown, decorators: [{
|
|
132
132
|
type: Component,
|
|
@@ -137,16 +137,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
137
137
|
host: {
|
|
138
138
|
'[class]': '_computedClass()',
|
|
139
139
|
},
|
|
140
|
-
template: ` <ng-icon hlm size="sm" class="
|
|
140
|
+
template: ` <ng-icon hlm size="sm" class="ml-2" name="lucideChevronDown" /> `,
|
|
141
141
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
142
142
|
}]
|
|
143
143
|
}] });
|
|
144
144
|
|
|
145
145
|
class HlmSelectScrollUp {
|
|
146
146
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
147
|
-
_computedClass = computed(() => hlm('
|
|
147
|
+
_computedClass = computed(() => hlm('flex cursor-default items-center justify-center py-1', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
148
148
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectScrollUp, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
149
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelectScrollUp, isStandalone: true, selector: "hlm-select-scroll-up", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, providers: [provideIcons({ lucideChevronUp })], ngImport: i0, template: ` <ng-icon hlm size="sm" class="
|
|
149
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelectScrollUp, isStandalone: true, selector: "hlm-select-scroll-up", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, providers: [provideIcons({ lucideChevronUp })], ngImport: i0, template: ` <ng-icon hlm size="sm" class="ml-2" name="lucideChevronUp" /> `, isInline: true, dependencies: [{ kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "directive", type: HlmIcon, selector: "ng-icon[hlm]", inputs: ["size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
150
150
|
}
|
|
151
151
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectScrollUp, decorators: [{
|
|
152
152
|
type: Component,
|
|
@@ -157,16 +157,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
157
157
|
host: {
|
|
158
158
|
'[class]': '_computedClass()',
|
|
159
159
|
},
|
|
160
|
-
template: ` <ng-icon hlm size="sm" class="
|
|
160
|
+
template: ` <ng-icon hlm size="sm" class="ml-2" name="lucideChevronUp" /> `,
|
|
161
161
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
162
162
|
}]
|
|
163
163
|
}] });
|
|
164
164
|
|
|
165
|
-
const selectTriggerVariants = cva(`
|
|
165
|
+
const selectTriggerVariants = cva(`border-input [&>ng-icon]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 dark:bg-input/10 dark:hover:bg-input/50 shadow-xs flex w-fit items-center justify-between gap-2 whitespace-nowrap rounded-md border bg-transparent px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 [&>ng-icon]:pointer-events-none [&>ng-icon]:size-4 [&>ng-icon]:shrink-0`, {
|
|
166
166
|
variants: {
|
|
167
167
|
error: {
|
|
168
|
-
auto: '
|
|
169
|
-
true: '
|
|
168
|
+
auto: '[&.ng-invalid.ng-touched]:text-destructive [&.ng-invalid.ng-touched]:border-destructive [&.ng-invalid.ng-touched]:focus-visible:ring-destructive/20 dark:[&.ng-invalid.ng-touched]:focus-visible:ring-destructive/40',
|
|
169
|
+
true: 'text-destructive border-destructive focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40',
|
|
170
170
|
},
|
|
171
171
|
},
|
|
172
172
|
defaultVariants: {
|
|
@@ -186,7 +186,7 @@ class HlmSelectTrigger {
|
|
|
186
186
|
@if (_icon()) {
|
|
187
187
|
<ng-content select="ng-icon" />
|
|
188
188
|
} @else {
|
|
189
|
-
<ng-icon hlm size="sm" class="
|
|
189
|
+
<ng-icon hlm size="sm" class="ml-2 flex-none" name="lucideChevronDown" />
|
|
190
190
|
}
|
|
191
191
|
</button>
|
|
192
192
|
`, isInline: true, dependencies: [{ kind: "directive", type: BrnSelectTrigger, selector: "[brnSelectTrigger]" }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "directive", type: HlmIcon, selector: "ng-icon[hlm]", inputs: ["size"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
@@ -203,7 +203,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
203
203
|
@if (_icon()) {
|
|
204
204
|
<ng-content select="ng-icon" />
|
|
205
205
|
} @else {
|
|
206
|
-
<ng-icon hlm size="sm" class="
|
|
206
|
+
<ng-icon hlm size="sm" class="ml-2 flex-none" name="lucideChevronDown" />
|
|
207
207
|
}
|
|
208
208
|
</button>
|
|
209
209
|
`,
|
|
@@ -213,7 +213,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.1", ngImpor
|
|
|
213
213
|
|
|
214
214
|
class HlmSelectValue {
|
|
215
215
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
216
|
-
_computedClass = computed(() => hlm('
|
|
216
|
+
_computedClass = computed(() => hlm('data-[placeholder]:text-muted-foreground line-clamp-1 flex items-center gap-2', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
217
217
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSelectValue, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
218
218
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmSelectValue, isStandalone: true, selector: "hlm-select-value,[hlmSelectValue], brn-select-value[hlm]", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, ngImport: i0 });
|
|
219
219
|
}
|
|
@@ -6,7 +6,7 @@ import { hlm } from '@egose/shadcn-theme-ng/utils';
|
|
|
6
6
|
|
|
7
7
|
class HlmSeparator {
|
|
8
8
|
userClass = input('', ...(ngDevMode ? [{ debugName: "userClass", alias: 'class' }] : [{ alias: 'class' }]));
|
|
9
|
-
_computedClass = computed(() => hlm('
|
|
9
|
+
_computedClass = computed(() => hlm('bg-border inline-flex shrink-0 data-[orientation=horizontal]:h-px data-[orientation=vertical]:h-full data-[orientation=horizontal]:w-full data-[orientation=vertical]:w-px', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
10
10
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.1", ngImport: i0, type: HlmSeparator, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
11
11
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.1", type: HlmSeparator, isStandalone: true, selector: "[hlmSeparator],hlm-separator", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, hostDirectives: [{ directive: i1.BrnSeparator, inputs: ["orientation", "orientation", "decorative", "decorative"] }], ngImport: i0 });
|
|
12
12
|
}
|
|
@@ -27,10 +27,10 @@ class HlmToaster {
|
|
|
27
27
|
}]));
|
|
28
28
|
toastOptions = input({
|
|
29
29
|
classes: {
|
|
30
|
-
toast: '
|
|
31
|
-
description: '
|
|
32
|
-
actionButton: '
|
|
33
|
-
cancelButton: '
|
|
30
|
+
toast: 'group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg',
|
|
31
|
+
description: 'group-[.toast]:text-muted-foreground',
|
|
32
|
+
actionButton: 'group-[.toast]:bg-primary group-[.toast]:text-primary-foreground',
|
|
33
|
+
cancelButton: 'group-[.toast]:bg-muted group-[.toast]:text-muted-foreground',
|
|
34
34
|
},
|
|
35
35
|
}, ...(ngDevMode ? [{ debugName: "toastOptions" }] : []));
|
|
36
36
|
offset = input(null, ...(ngDevMode ? [{ debugName: "offset" }] : []));
|