@4sh/ui-kit 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/NOTICE +7 -0
- package/README.md +229 -0
- package/fesm2022/4sh-ui-kit-forms.mjs +501 -0
- package/fesm2022/4sh-ui-kit-forms.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-motion.mjs +155 -0
- package/fesm2022/4sh-ui-kit-motion.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-overlay.mjs +61 -0
- package/fesm2022/4sh-ui-kit-overlay.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-theming.mjs +120 -0
- package/fesm2022/4sh-ui-kit-theming.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-types.mjs +12 -0
- package/fesm2022/4sh-ui-kit-types.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-accordion.mjs +244 -0
- package/fesm2022/4sh-ui-kit-ui-accordion.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-alert.mjs +160 -0
- package/fesm2022/4sh-ui-kit-ui-alert.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-autocomplete.mjs +926 -0
- package/fesm2022/4sh-ui-kit-ui-autocomplete.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-avatar-group.mjs +34 -0
- package/fesm2022/4sh-ui-kit-ui-avatar-group.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-avatar.mjs +122 -0
- package/fesm2022/4sh-ui-kit-ui-avatar.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-badge.mjs +95 -0
- package/fesm2022/4sh-ui-kit-ui-badge.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-breadcrumb.mjs +190 -0
- package/fesm2022/4sh-ui-kit-ui-breadcrumb.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-button-split.mjs +151 -0
- package/fesm2022/4sh-ui-kit-ui-button-split.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-button.mjs +222 -0
- package/fesm2022/4sh-ui-kit-ui-button.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-card.mjs +164 -0
- package/fesm2022/4sh-ui-kit-ui-card.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-checkbox.mjs +118 -0
- package/fesm2022/4sh-ui-kit-ui-checkbox.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-chip.mjs +205 -0
- package/fesm2022/4sh-ui-kit-ui-chip.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-context-menu.mjs +219 -0
- package/fesm2022/4sh-ui-kit-ui-context-menu.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-datepicker.mjs +1508 -0
- package/fesm2022/4sh-ui-kit-ui-datepicker.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-drawer.mjs +300 -0
- package/fesm2022/4sh-ui-kit-ui-drawer.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-empty-state.mjs +148 -0
- package/fesm2022/4sh-ui-kit-ui-empty-state.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-field.mjs +102 -0
- package/fesm2022/4sh-ui-kit-ui-field.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-file-upload.mjs +568 -0
- package/fesm2022/4sh-ui-kit-ui-file-upload.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-helper.mjs +85 -0
- package/fesm2022/4sh-ui-kit-ui-helper.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-icon.mjs +98 -0
- package/fesm2022/4sh-ui-kit-ui-icon.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-image.mjs +201 -0
- package/fesm2022/4sh-ui-kit-ui-image.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-input-group.mjs +119 -0
- package/fesm2022/4sh-ui-kit-ui-input-group.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-input-mask.mjs +125 -0
- package/fesm2022/4sh-ui-kit-ui-input-mask.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-input-number.mjs +234 -0
- package/fesm2022/4sh-ui-kit-ui-input-number.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-input-otp.mjs +288 -0
- package/fesm2022/4sh-ui-kit-ui-input-otp.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-input-tags.mjs +679 -0
- package/fesm2022/4sh-ui-kit-ui-input-tags.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-input.mjs +121 -0
- package/fesm2022/4sh-ui-kit-ui-input.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-label.mjs +61 -0
- package/fesm2022/4sh-ui-kit-ui-label.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-link.mjs +147 -0
- package/fesm2022/4sh-ui-kit-ui-link.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-menu.mjs +484 -0
- package/fesm2022/4sh-ui-kit-ui-menu.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-modal.mjs +555 -0
- package/fesm2022/4sh-ui-kit-ui-modal.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-nudger.mjs +168 -0
- package/fesm2022/4sh-ui-kit-ui-nudger.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-paginator.mjs +245 -0
- package/fesm2022/4sh-ui-kit-ui-paginator.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-popover.mjs +296 -0
- package/fesm2022/4sh-ui-kit-ui-popover.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-progress-bar.mjs +124 -0
- package/fesm2022/4sh-ui-kit-ui-progress-bar.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-radio.mjs +92 -0
- package/fesm2022/4sh-ui-kit-ui-radio.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-rating.mjs +185 -0
- package/fesm2022/4sh-ui-kit-ui-rating.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-read-only.mjs +146 -0
- package/fesm2022/4sh-ui-kit-ui-read-only.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-segment-control.mjs +386 -0
- package/fesm2022/4sh-ui-kit-ui-segment-control.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-select.mjs +868 -0
- package/fesm2022/4sh-ui-kit-ui-select.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-separator.mjs +77 -0
- package/fesm2022/4sh-ui-kit-ui-separator.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-sidebar.mjs +577 -0
- package/fesm2022/4sh-ui-kit-ui-sidebar.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-skeleton.mjs +81 -0
- package/fesm2022/4sh-ui-kit-ui-skeleton.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-slider.mjs +340 -0
- package/fesm2022/4sh-ui-kit-ui-slider.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-spinner.mjs +132 -0
- package/fesm2022/4sh-ui-kit-ui-spinner.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-stepper.mjs +389 -0
- package/fesm2022/4sh-ui-kit-ui-stepper.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-table.mjs +1406 -0
- package/fesm2022/4sh-ui-kit-ui-table.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-tabs.mjs +503 -0
- package/fesm2022/4sh-ui-kit-ui-tabs.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-tag.mjs +84 -0
- package/fesm2022/4sh-ui-kit-ui-tag.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-textarea.mjs +119 -0
- package/fesm2022/4sh-ui-kit-ui-textarea.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-toast.mjs +424 -0
- package/fesm2022/4sh-ui-kit-ui-toast.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-toggle.mjs +120 -0
- package/fesm2022/4sh-ui-kit-ui-toggle.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit-ui-tooltip.mjs +445 -0
- package/fesm2022/4sh-ui-kit-ui-tooltip.mjs.map +1 -0
- package/fesm2022/4sh-ui-kit.mjs +16 -0
- package/fesm2022/4sh-ui-kit.mjs.map +1 -0
- package/package.json +287 -0
- package/styles/base/_base.scss +19 -0
- package/styles/base/_motion.scss +144 -0
- package/styles/base/_typography.scss +99 -0
- package/styles/generated/_tokens-breakpoint.scss +8 -0
- package/styles/generated/_tokens-metrics.scss +37 -0
- package/styles/generated/_tokens-primitives.scss +284 -0
- package/styles/generated/_tokens-responsive.scss +99 -0
- package/styles/generated/_tokens-semantics.scss +1274 -0
- package/styles/generated/_tokens-styles.scss +35 -0
- package/styles/generated/_tokens-transitions.scss +11 -0
- package/styles/generated/_tokens-typography.scss +14 -0
- package/styles/generated/_tokens.scss +10 -0
- package/styles/index.scss +25 -0
- package/styles/settings/_ui-config.scss +67 -0
- package/styles/utils/_functions.scss +67 -0
- package/styles/utils/_helpers.scss +129 -0
- package/styles/utils/_mixins.scss +186 -0
- package/styles/utils/_motion.scss +47 -0
- package/styles/utils/_overlay.scss +26 -0
- package/styles/utils.scss +15 -0
- package/styles.css +1 -0
- package/types/4sh-ui-kit-forms.d.ts +259 -0
- package/types/4sh-ui-kit-motion.d.ts +111 -0
- package/types/4sh-ui-kit-overlay.d.ts +31 -0
- package/types/4sh-ui-kit-theming.d.ts +54 -0
- package/types/4sh-ui-kit-types.d.ts +13 -0
- package/types/4sh-ui-kit-ui-accordion.d.ts +140 -0
- package/types/4sh-ui-kit-ui-alert.d.ts +89 -0
- package/types/4sh-ui-kit-ui-autocomplete.d.ts +411 -0
- package/types/4sh-ui-kit-ui-avatar-group.d.ts +17 -0
- package/types/4sh-ui-kit-ui-avatar.d.ts +55 -0
- package/types/4sh-ui-kit-ui-badge.d.ts +38 -0
- package/types/4sh-ui-kit-ui-breadcrumb.d.ts +131 -0
- package/types/4sh-ui-kit-ui-button-split.d.ts +102 -0
- package/types/4sh-ui-kit-ui-button.d.ts +91 -0
- package/types/4sh-ui-kit-ui-card.d.ts +102 -0
- package/types/4sh-ui-kit-ui-checkbox.d.ts +54 -0
- package/types/4sh-ui-kit-ui-chip.d.ts +114 -0
- package/types/4sh-ui-kit-ui-context-menu.d.ts +105 -0
- package/types/4sh-ui-kit-ui-datepicker.d.ts +539 -0
- package/types/4sh-ui-kit-ui-drawer.d.ts +147 -0
- package/types/4sh-ui-kit-ui-empty-state.d.ts +93 -0
- package/types/4sh-ui-kit-ui-field.d.ts +53 -0
- package/types/4sh-ui-kit-ui-file-upload.d.ts +268 -0
- package/types/4sh-ui-kit-ui-helper.d.ts +46 -0
- package/types/4sh-ui-kit-ui-icon.d.ts +69 -0
- package/types/4sh-ui-kit-ui-image.d.ts +88 -0
- package/types/4sh-ui-kit-ui-input-group.d.ts +54 -0
- package/types/4sh-ui-kit-ui-input-mask.d.ts +63 -0
- package/types/4sh-ui-kit-ui-input-number.d.ts +96 -0
- package/types/4sh-ui-kit-ui-input-otp.d.ts +130 -0
- package/types/4sh-ui-kit-ui-input-tags.d.ts +350 -0
- package/types/4sh-ui-kit-ui-input.d.ts +78 -0
- package/types/4sh-ui-kit-ui-label.d.ts +36 -0
- package/types/4sh-ui-kit-ui-link.d.ts +72 -0
- package/types/4sh-ui-kit-ui-menu.d.ts +235 -0
- package/types/4sh-ui-kit-ui-modal.d.ts +241 -0
- package/types/4sh-ui-kit-ui-nudger.d.ts +79 -0
- package/types/4sh-ui-kit-ui-paginator.d.ts +150 -0
- package/types/4sh-ui-kit-ui-popover.d.ts +125 -0
- package/types/4sh-ui-kit-ui-progress-bar.d.ts +82 -0
- package/types/4sh-ui-kit-ui-radio.d.ts +44 -0
- package/types/4sh-ui-kit-ui-rating.d.ts +90 -0
- package/types/4sh-ui-kit-ui-read-only.d.ts +70 -0
- package/types/4sh-ui-kit-ui-segment-control.d.ts +184 -0
- package/types/4sh-ui-kit-ui-select.d.ts +392 -0
- package/types/4sh-ui-kit-ui-separator.d.ts +43 -0
- package/types/4sh-ui-kit-ui-sidebar.d.ts +358 -0
- package/types/4sh-ui-kit-ui-skeleton.d.ts +52 -0
- package/types/4sh-ui-kit-ui-slider.d.ts +127 -0
- package/types/4sh-ui-kit-ui-spinner.d.ts +67 -0
- package/types/4sh-ui-kit-ui-stepper.d.ts +220 -0
- package/types/4sh-ui-kit-ui-table.d.ts +570 -0
- package/types/4sh-ui-kit-ui-tabs.d.ts +225 -0
- package/types/4sh-ui-kit-ui-tag.d.ts +46 -0
- package/types/4sh-ui-kit-ui-textarea.d.ts +61 -0
- package/types/4sh-ui-kit-ui-toast.d.ts +247 -0
- package/types/4sh-ui-kit-ui-toggle.d.ts +67 -0
- package/types/4sh-ui-kit-ui-tooltip.d.ts +167 -0
- package/types/4sh-ui-kit.d.ts +4 -0
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { Directive, input, booleanAttribute, contentChild, viewChild, signal, computed, afterNextRender, Component } from '@angular/core';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Slot markers — apply them (attribute or element form) on the content you project
|
|
6
|
+
* into a `<ui-card>` to route it to the matching region. They carry no behaviour;
|
|
7
|
+
* the card queries their presence to render the surrounding structure.
|
|
8
|
+
*
|
|
9
|
+
* <ui-card>
|
|
10
|
+
* <img uiCardMedia … />
|
|
11
|
+
* <span uiCardTitle>Title</span>
|
|
12
|
+
* <span uiCardSubtitle>Subtitle</span>
|
|
13
|
+
* Body content (default slot)
|
|
14
|
+
* <div uiCardFooter><ui-button … /></div>
|
|
15
|
+
* </ui-card>
|
|
16
|
+
*/
|
|
17
|
+
/** Full-bleed media region, rendered above the body (image, illustration…). */
|
|
18
|
+
class UiCardMedia {
|
|
19
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardMedia, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
20
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.8", type: UiCardMedia, isStandalone: true, selector: "[uiCardMedia], ui-card-media", ngImport: i0 }); }
|
|
21
|
+
}
|
|
22
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardMedia, decorators: [{
|
|
23
|
+
type: Directive,
|
|
24
|
+
args: [{ selector: '[uiCardMedia], ui-card-media' }]
|
|
25
|
+
}] });
|
|
26
|
+
/** Title region (also settable via the `header` string input). */
|
|
27
|
+
class UiCardTitle {
|
|
28
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardTitle, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
29
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.8", type: UiCardTitle, isStandalone: true, selector: "[uiCardTitle], ui-card-title", ngImport: i0 }); }
|
|
30
|
+
}
|
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardTitle, decorators: [{
|
|
32
|
+
type: Directive,
|
|
33
|
+
args: [{ selector: '[uiCardTitle], ui-card-title' }]
|
|
34
|
+
}] });
|
|
35
|
+
/** Subtitle region (also settable via the `subheader` string input). */
|
|
36
|
+
class UiCardSubtitle {
|
|
37
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardSubtitle, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
38
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.8", type: UiCardSubtitle, isStandalone: true, selector: "[uiCardSubtitle], ui-card-subtitle", ngImport: i0 }); }
|
|
39
|
+
}
|
|
40
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardSubtitle, decorators: [{
|
|
41
|
+
type: Directive,
|
|
42
|
+
args: [{ selector: '[uiCardSubtitle], ui-card-subtitle' }]
|
|
43
|
+
}] });
|
|
44
|
+
/** Footer region (actions, tags…), rendered below the body content. */
|
|
45
|
+
class UiCardFooter {
|
|
46
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardFooter, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
47
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.8", type: UiCardFooter, isStandalone: true, selector: "[uiCardFooter], ui-card-footer", ngImport: i0 }); }
|
|
48
|
+
}
|
|
49
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCardFooter, decorators: [{
|
|
50
|
+
type: Directive,
|
|
51
|
+
args: [{ selector: '[uiCardFooter], ui-card-footer' }]
|
|
52
|
+
}] });
|
|
53
|
+
/**
|
|
54
|
+
* ui-card — flexible container that composes optional regions: media, header
|
|
55
|
+
* (title + subtitle), body content and footer.
|
|
56
|
+
*
|
|
57
|
+
* Headless: renders a neutral `surface` box (border + radius, optional elevation) whose
|
|
58
|
+
* regions are driven by content projection. Each region is rendered only when it holds
|
|
59
|
+
* content, so no empty wrapper (and no phantom gap) is emitted. The most common case —
|
|
60
|
+
* dropping content into the card — needs no imports (default `<ng-content>`); title and
|
|
61
|
+
* subtitle also accept the `header`/`subheader` string inputs. Richer slots use the
|
|
62
|
+
* exported marker directives (`UiCardMedia`, `UiCardTitle`, `UiCardSubtitle`, `UiCardFooter`).
|
|
63
|
+
*/
|
|
64
|
+
class UiCard {
|
|
65
|
+
constructor() {
|
|
66
|
+
/** Title text (convenience shorthand for the `uiCardTitle` slot). */
|
|
67
|
+
this.header = input(/* @ts-ignore */
|
|
68
|
+
...(ngDevMode ? [undefined, { debugName: "header" }] : /* istanbul ignore next */ []));
|
|
69
|
+
/** Subtitle text (convenience shorthand for the `uiCardSubtitle` slot). */
|
|
70
|
+
this.subheader = input(/* @ts-ignore */
|
|
71
|
+
...(ngDevMode ? [undefined, { debugName: "subheader" }] : /* istanbul ignore next */ []));
|
|
72
|
+
/** Visual treatment of the surface. */
|
|
73
|
+
this.variant = input('outlined', /* @ts-ignore */
|
|
74
|
+
...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
|
|
75
|
+
/**
|
|
76
|
+
* Removes the horizontal gutter of the default content region so it bleeds to
|
|
77
|
+
* the card edges — lets the consumer own the inner layout (e.g. a full-bleed
|
|
78
|
+
* media/color band + a padded paragraph). Re-apply the gutter on inner blocks
|
|
79
|
+
* with `padding-inline: var(--ui-card-padding)`.
|
|
80
|
+
*/
|
|
81
|
+
this.contentFlush = input(false, { ...(ngDevMode ? { debugName: "contentFlush" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
82
|
+
/** Accessible name for the card region (use when the card conveys a landmark). */
|
|
83
|
+
this.ariaLabel = input(/* @ts-ignore */
|
|
84
|
+
...(ngDevMode ? [undefined, { debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
85
|
+
/** Id of the element labelling the card region. */
|
|
86
|
+
this.ariaLabelledBy = input(/* @ts-ignore */
|
|
87
|
+
...(ngDevMode ? [undefined, { debugName: "ariaLabelledBy" }] : /* istanbul ignore next */ []));
|
|
88
|
+
/** @ignore */
|
|
89
|
+
this.titleSlot = contentChild(UiCardTitle, /* @ts-ignore */
|
|
90
|
+
...(ngDevMode ? [{ debugName: "titleSlot" }] : /* istanbul ignore next */ []));
|
|
91
|
+
/** @ignore */
|
|
92
|
+
this.subtitleSlot = contentChild(UiCardSubtitle, /* @ts-ignore */
|
|
93
|
+
...(ngDevMode ? [{ debugName: "subtitleSlot" }] : /* istanbul ignore next */ []));
|
|
94
|
+
/** @ignore */
|
|
95
|
+
this.mediaSlot = contentChild(UiCardMedia, /* @ts-ignore */
|
|
96
|
+
...(ngDevMode ? [{ debugName: "mediaSlot" }] : /* istanbul ignore next */ []));
|
|
97
|
+
/** @ignore */
|
|
98
|
+
this.footerSlot = contentChild(UiCardFooter, /* @ts-ignore */
|
|
99
|
+
...(ngDevMode ? [{ debugName: "footerSlot" }] : /* istanbul ignore next */ []));
|
|
100
|
+
/** @ignore */
|
|
101
|
+
this.contentWrap = viewChild('contentWrap', /* @ts-ignore */
|
|
102
|
+
...(ngDevMode ? [{ debugName: "contentWrap" }] : /* istanbul ignore next */ []));
|
|
103
|
+
/** @ignore Default content actually projected (detected after rendering). */
|
|
104
|
+
this.hasProjectedContent = signal(false, /* @ts-ignore */
|
|
105
|
+
...(ngDevMode ? [{ debugName: "hasProjectedContent" }] : /* istanbul ignore next */ []));
|
|
106
|
+
/** @ignore A title is provided (string input or projected slot). */
|
|
107
|
+
this.hasTitle = computed(() => !!this.header() || !!this.titleSlot(), /* @ts-ignore */
|
|
108
|
+
...(ngDevMode ? [{ debugName: "hasTitle" }] : /* istanbul ignore next */ []));
|
|
109
|
+
/** @ignore A subtitle is provided (string input or projected slot). */
|
|
110
|
+
this.hasSubtitle = computed(() => !!this.subheader() || !!this.subtitleSlot(), /* @ts-ignore */
|
|
111
|
+
...(ngDevMode ? [{ debugName: "hasSubtitle" }] : /* istanbul ignore next */ []));
|
|
112
|
+
/** @ignore The header region (title and/or subtitle) has content. */
|
|
113
|
+
this.hasHeader = computed(() => this.hasTitle() || this.hasSubtitle(), /* @ts-ignore */
|
|
114
|
+
...(ngDevMode ? [{ debugName: "hasHeader" }] : /* istanbul ignore next */ []));
|
|
115
|
+
/** @ignore A media slot is provided. */
|
|
116
|
+
this.hasMedia = computed(() => !!this.mediaSlot(), /* @ts-ignore */
|
|
117
|
+
...(ngDevMode ? [{ debugName: "hasMedia" }] : /* istanbul ignore next */ []));
|
|
118
|
+
/** @ignore A footer slot is provided. */
|
|
119
|
+
this.hasFooter = computed(() => !!this.footerSlot(), /* @ts-ignore */
|
|
120
|
+
...(ngDevMode ? [{ debugName: "hasFooter" }] : /* istanbul ignore next */ []));
|
|
121
|
+
/** @ignore The body has default content. */
|
|
122
|
+
this.hasContent = computed(() => this.hasProjectedContent(), /* @ts-ignore */
|
|
123
|
+
...(ngDevMode ? [{ debugName: "hasContent" }] : /* istanbul ignore next */ []));
|
|
124
|
+
/** @ignore Render the string title only when no title slot overrides it. */
|
|
125
|
+
this.showHeaderString = computed(() => !!this.header() && !this.titleSlot(), /* @ts-ignore */
|
|
126
|
+
...(ngDevMode ? [{ debugName: "showHeaderString" }] : /* istanbul ignore next */ []));
|
|
127
|
+
/** @ignore Render the string subtitle only when no subtitle slot overrides it. */
|
|
128
|
+
this.showSubheaderString = computed(() => !!this.subheader() && !this.subtitleSlot(), /* @ts-ignore */
|
|
129
|
+
...(ngDevMode ? [{ debugName: "showSubheaderString" }] : /* istanbul ignore next */ []));
|
|
130
|
+
/** @ignore */
|
|
131
|
+
this.classes = computed(() => {
|
|
132
|
+
const c = ['ui-card', `_${this.variant()}`];
|
|
133
|
+
if (this.hasMedia())
|
|
134
|
+
c.push('_has-media');
|
|
135
|
+
return c.join(' ');
|
|
136
|
+
}, /* @ts-ignore */
|
|
137
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
138
|
+
// Detect projected default content (<ng-content>) — SSR-safe (browser only).
|
|
139
|
+
afterNextRender(() => {
|
|
140
|
+
const el = this.contentWrap()?.nativeElement;
|
|
141
|
+
const has = !!el &&
|
|
142
|
+
Array.from(el.childNodes).some((n) => n.nodeType === Node.ELEMENT_NODE ||
|
|
143
|
+
(n.nodeType === Node.TEXT_NODE && !!n.textContent?.trim()));
|
|
144
|
+
this.hasProjectedContent.set(has);
|
|
145
|
+
});
|
|
146
|
+
}
|
|
147
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCard, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
148
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: UiCard, isStandalone: true, selector: "ui-card", inputs: { header: { classPropertyName: "header", publicName: "header", isSignal: true, isRequired: false, transformFunction: null }, subheader: { classPropertyName: "subheader", publicName: "subheader", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, contentFlush: { classPropertyName: "contentFlush", publicName: "contentFlush", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledBy: { classPropertyName: "ariaLabelledBy", publicName: "ariaLabelledBy", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "titleSlot", first: true, predicate: UiCardTitle, descendants: true, isSignal: true }, { propertyName: "subtitleSlot", first: true, predicate: UiCardSubtitle, descendants: true, isSignal: true }, { propertyName: "mediaSlot", first: true, predicate: UiCardMedia, descendants: true, isSignal: true }, { propertyName: "footerSlot", first: true, predicate: UiCardFooter, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "contentWrap", first: true, predicate: ["contentWrap"], descendants: true, isSignal: true }], ngImport: i0, template: "<div\n [class]=\"classes()\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.role]=\"ariaLabel() || ariaLabelledBy() ? 'region' : null\"\n>\n @if (hasMedia()) {\n <div class=\"ui-card-media\">\n <ng-content select=\"[uiCardMedia], ui-card-media\" />\n </div>\n }\n\n <div class=\"ui-card-body\">\n @if (hasHeader()) {\n <div class=\"ui-card-header\">\n @if (hasTitle()) {\n <div class=\"ui-card-title\">\n @if (showHeaderString()) {\n {{ header() }}\n }\n <ng-content select=\"[uiCardTitle], ui-card-title\" />\n </div>\n }\n @if (hasSubtitle()) {\n <div class=\"ui-card-subtitle\">\n @if (showSubheaderString()) {\n {{ subheader() }}\n }\n <ng-content select=\"[uiCardSubtitle], ui-card-subtitle\" />\n </div>\n }\n </div>\n }\n\n <div\n class=\"ui-card-content\"\n #contentWrap\n [class._empty]=\"!hasContent()\"\n [class._flush]=\"contentFlush()\"\n >\n <ng-content />\n </div>\n\n @if (hasFooter()) {\n <div class=\"ui-card-footer\">\n <ng-content select=\"[uiCardFooter], ui-card-footer\" />\n </div>\n }\n </div>\n</div>\n", styles: [":host{display:block}.ui-card{--ui-card-padding: var(--units-lg);display:flex;flex-direction:column;overflow:hidden;background-color:var(--global-background-default);border:var(--stroke-sm) solid transparent;border-radius:var(--radius-md);color:var(--global-text-default);font-family:var(--fontfamily-base)}.ui-card-media{display:flex;overflow:hidden}.ui-card-media ::ng-deep img,.ui-card-media ::ng-deep svg,.ui-card-media ::ng-deep ui-image,.ui-card-media ::ng-deep picture{display:block;width:100%;height:100%;object-fit:cover}.ui-card-body{display:flex;flex-direction:column;gap:var(--units-md);padding-block:var(--units-lg)}.ui-card-header{display:flex;flex-direction:column;gap:var(--units-2xs);padding-inline:var(--units-lg)}.ui-card-title{display:flex;align-items:center;flex-wrap:wrap;gap:var(--units-sm);font-family:var(--fontfamily-title);font-size:var(--size-typography-title-default);font-weight:var(--weight-bold);line-height:1.2;color:var(--global-text-default)}.ui-card-subtitle{font-size:var(--size-typography-text-md);line-height:1.4;color:var(--global-text-muted)}.ui-card-content{padding-inline:var(--units-lg);font-size:var(--size-typography-text-md);line-height:1.5;color:var(--global-text-default)}.ui-card-content._flush{padding-inline:0}.ui-card-content._empty{display:none}.ui-card-footer{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:var(--units-sm);padding-inline:var(--units-lg)}.ui-card._outlined{border-color:var(--global-border-subtle)}.ui-card._elevated{box-shadow:var(--shadow-default-md)}\n"] }); }
|
|
149
|
+
}
|
|
150
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCard, decorators: [{
|
|
151
|
+
type: Component,
|
|
152
|
+
args: [{ selector: 'ui-card', imports: [], template: "<div\n [class]=\"classes()\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.role]=\"ariaLabel() || ariaLabelledBy() ? 'region' : null\"\n>\n @if (hasMedia()) {\n <div class=\"ui-card-media\">\n <ng-content select=\"[uiCardMedia], ui-card-media\" />\n </div>\n }\n\n <div class=\"ui-card-body\">\n @if (hasHeader()) {\n <div class=\"ui-card-header\">\n @if (hasTitle()) {\n <div class=\"ui-card-title\">\n @if (showHeaderString()) {\n {{ header() }}\n }\n <ng-content select=\"[uiCardTitle], ui-card-title\" />\n </div>\n }\n @if (hasSubtitle()) {\n <div class=\"ui-card-subtitle\">\n @if (showSubheaderString()) {\n {{ subheader() }}\n }\n <ng-content select=\"[uiCardSubtitle], ui-card-subtitle\" />\n </div>\n }\n </div>\n }\n\n <div\n class=\"ui-card-content\"\n #contentWrap\n [class._empty]=\"!hasContent()\"\n [class._flush]=\"contentFlush()\"\n >\n <ng-content />\n </div>\n\n @if (hasFooter()) {\n <div class=\"ui-card-footer\">\n <ng-content select=\"[uiCardFooter], ui-card-footer\" />\n </div>\n }\n </div>\n</div>\n", styles: [":host{display:block}.ui-card{--ui-card-padding: var(--units-lg);display:flex;flex-direction:column;overflow:hidden;background-color:var(--global-background-default);border:var(--stroke-sm) solid transparent;border-radius:var(--radius-md);color:var(--global-text-default);font-family:var(--fontfamily-base)}.ui-card-media{display:flex;overflow:hidden}.ui-card-media ::ng-deep img,.ui-card-media ::ng-deep svg,.ui-card-media ::ng-deep ui-image,.ui-card-media ::ng-deep picture{display:block;width:100%;height:100%;object-fit:cover}.ui-card-body{display:flex;flex-direction:column;gap:var(--units-md);padding-block:var(--units-lg)}.ui-card-header{display:flex;flex-direction:column;gap:var(--units-2xs);padding-inline:var(--units-lg)}.ui-card-title{display:flex;align-items:center;flex-wrap:wrap;gap:var(--units-sm);font-family:var(--fontfamily-title);font-size:var(--size-typography-title-default);font-weight:var(--weight-bold);line-height:1.2;color:var(--global-text-default)}.ui-card-subtitle{font-size:var(--size-typography-text-md);line-height:1.4;color:var(--global-text-muted)}.ui-card-content{padding-inline:var(--units-lg);font-size:var(--size-typography-text-md);line-height:1.5;color:var(--global-text-default)}.ui-card-content._flush{padding-inline:0}.ui-card-content._empty{display:none}.ui-card-footer{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:var(--units-sm);padding-inline:var(--units-lg)}.ui-card._outlined{border-color:var(--global-border-subtle)}.ui-card._elevated{box-shadow:var(--shadow-default-md)}\n"] }]
|
|
153
|
+
}], ctorParameters: () => [], propDecorators: { header: [{ type: i0.Input, args: [{ isSignal: true, alias: "header", required: false }] }], subheader: [{ type: i0.Input, args: [{ isSignal: true, alias: "subheader", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], contentFlush: [{ type: i0.Input, args: [{ isSignal: true, alias: "contentFlush", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], ariaLabelledBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelledBy", required: false }] }], titleSlot: [{ type: i0.ContentChild, args: [i0.forwardRef(() => UiCardTitle), { isSignal: true }] }], subtitleSlot: [{ type: i0.ContentChild, args: [i0.forwardRef(() => UiCardSubtitle), { isSignal: true }] }], mediaSlot: [{ type: i0.ContentChild, args: [i0.forwardRef(() => UiCardMedia), { isSignal: true }] }], footerSlot: [{ type: i0.ContentChild, args: [i0.forwardRef(() => UiCardFooter), { isSignal: true }] }], contentWrap: [{ type: i0.ViewChild, args: ['contentWrap', { isSignal: true }] }] } });
|
|
154
|
+
|
|
155
|
+
/*
|
|
156
|
+
* Public API Surface of ui-kit/ui-card
|
|
157
|
+
*/
|
|
158
|
+
|
|
159
|
+
/**
|
|
160
|
+
* Generated bundle index. Do not edit.
|
|
161
|
+
*/
|
|
162
|
+
|
|
163
|
+
export { UiCard, UiCardFooter, UiCardMedia, UiCardSubtitle, UiCardTitle };
|
|
164
|
+
//# sourceMappingURL=4sh-ui-kit-ui-card.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"4sh-ui-kit-ui-card.mjs","sources":["../../../projects/ui-kit/ui-card/src/lib/ui-card.ts","../../../projects/ui-kit/ui-card/src/lib/ui-card.html","../../../projects/ui-kit/ui-card/src/public-api.ts","../../../projects/ui-kit/ui-card/src/4sh-ui-kit-ui-card.ts"],"sourcesContent":["import {\n afterNextRender,\n booleanAttribute,\n Component,\n computed,\n contentChild,\n Directive,\n ElementRef,\n input,\n signal,\n viewChild,\n} from '@angular/core';\n\nexport type CardVariant = 'outlined' | 'elevated' | 'flat';\n\n/**\n * Slot markers — apply them (attribute or element form) on the content you project\n * into a `<ui-card>` to route it to the matching region. They carry no behaviour;\n * the card queries their presence to render the surrounding structure.\n *\n * <ui-card>\n * <img uiCardMedia … />\n * <span uiCardTitle>Title</span>\n * <span uiCardSubtitle>Subtitle</span>\n * Body content (default slot)\n * <div uiCardFooter><ui-button … /></div>\n * </ui-card>\n */\n/** Full-bleed media region, rendered above the body (image, illustration…). */\n@Directive({ selector: '[uiCardMedia], ui-card-media' })\nexport class UiCardMedia {}\n\n/** Title region (also settable via the `header` string input). */\n@Directive({ selector: '[uiCardTitle], ui-card-title' })\nexport class UiCardTitle {}\n\n/** Subtitle region (also settable via the `subheader` string input). */\n@Directive({ selector: '[uiCardSubtitle], ui-card-subtitle' })\nexport class UiCardSubtitle {}\n\n/** Footer region (actions, tags…), rendered below the body content. */\n@Directive({ selector: '[uiCardFooter], ui-card-footer' })\nexport class UiCardFooter {}\n\n/**\n * ui-card — flexible container that composes optional regions: media, header\n * (title + subtitle), body content and footer.\n *\n * Headless: renders a neutral `surface` box (border + radius, optional elevation) whose\n * regions are driven by content projection. Each region is rendered only when it holds\n * content, so no empty wrapper (and no phantom gap) is emitted. The most common case —\n * dropping content into the card — needs no imports (default `<ng-content>`); title and\n * subtitle also accept the `header`/`subheader` string inputs. Richer slots use the\n * exported marker directives (`UiCardMedia`, `UiCardTitle`, `UiCardSubtitle`, `UiCardFooter`).\n */\n@Component({\n selector: 'ui-card',\n imports: [],\n templateUrl: './ui-card.html',\n styleUrl: './ui-card.scss',\n})\nexport class UiCard {\n /** Title text (convenience shorthand for the `uiCardTitle` slot). */\n header = input<string>();\n /** Subtitle text (convenience shorthand for the `uiCardSubtitle` slot). */\n subheader = input<string>();\n /** Visual treatment of the surface. */\n variant = input<CardVariant>('outlined');\n /**\n * Removes the horizontal gutter of the default content region so it bleeds to\n * the card edges — lets the consumer own the inner layout (e.g. a full-bleed\n * media/color band + a padded paragraph). Re-apply the gutter on inner blocks\n * with `padding-inline: var(--ui-card-padding)`.\n */\n contentFlush = input(false, { transform: booleanAttribute });\n /** Accessible name for the card region (use when the card conveys a landmark). */\n ariaLabel = input<string>();\n /** Id of the element labelling the card region. */\n ariaLabelledBy = input<string>();\n\n /** @ignore */\n protected readonly titleSlot = contentChild(UiCardTitle);\n /** @ignore */\n protected readonly subtitleSlot = contentChild(UiCardSubtitle);\n /** @ignore */\n protected readonly mediaSlot = contentChild(UiCardMedia);\n /** @ignore */\n protected readonly footerSlot = contentChild(UiCardFooter);\n\n /** @ignore */\n private readonly contentWrap = viewChild<ElementRef<HTMLElement>>('contentWrap');\n /** @ignore Default content actually projected (detected after rendering). */\n private readonly hasProjectedContent = signal(false);\n\n constructor() {\n // Detect projected default content (<ng-content>) — SSR-safe (browser only).\n afterNextRender(() => {\n const el = this.contentWrap()?.nativeElement;\n const has =\n !!el &&\n Array.from(el.childNodes).some(\n (n) =>\n n.nodeType === Node.ELEMENT_NODE ||\n (n.nodeType === Node.TEXT_NODE && !!n.textContent?.trim()),\n );\n this.hasProjectedContent.set(has);\n });\n }\n\n /** @ignore A title is provided (string input or projected slot). */\n protected readonly hasTitle = computed(() => !!this.header() || !!this.titleSlot());\n /** @ignore A subtitle is provided (string input or projected slot). */\n protected readonly hasSubtitle = computed(() => !!this.subheader() || !!this.subtitleSlot());\n /** @ignore The header region (title and/or subtitle) has content. */\n protected readonly hasHeader = computed(() => this.hasTitle() || this.hasSubtitle());\n /** @ignore A media slot is provided. */\n protected readonly hasMedia = computed(() => !!this.mediaSlot());\n /** @ignore A footer slot is provided. */\n protected readonly hasFooter = computed(() => !!this.footerSlot());\n /** @ignore The body has default content. */\n protected readonly hasContent = computed(() => this.hasProjectedContent());\n\n /** @ignore Render the string title only when no title slot overrides it. */\n protected readonly showHeaderString = computed(() => !!this.header() && !this.titleSlot());\n /** @ignore Render the string subtitle only when no subtitle slot overrides it. */\n protected readonly showSubheaderString = computed(\n () => !!this.subheader() && !this.subtitleSlot(),\n );\n\n /** @ignore */\n protected readonly classes = computed(() => {\n const c = ['ui-card', `_${this.variant()}`];\n if (this.hasMedia()) c.push('_has-media');\n return c.join(' ');\n });\n}\n","<div\n [class]=\"classes()\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.role]=\"ariaLabel() || ariaLabelledBy() ? 'region' : null\"\n>\n @if (hasMedia()) {\n <div class=\"ui-card-media\">\n <ng-content select=\"[uiCardMedia], ui-card-media\" />\n </div>\n }\n\n <div class=\"ui-card-body\">\n @if (hasHeader()) {\n <div class=\"ui-card-header\">\n @if (hasTitle()) {\n <div class=\"ui-card-title\">\n @if (showHeaderString()) {\n {{ header() }}\n }\n <ng-content select=\"[uiCardTitle], ui-card-title\" />\n </div>\n }\n @if (hasSubtitle()) {\n <div class=\"ui-card-subtitle\">\n @if (showSubheaderString()) {\n {{ subheader() }}\n }\n <ng-content select=\"[uiCardSubtitle], ui-card-subtitle\" />\n </div>\n }\n </div>\n }\n\n <div\n class=\"ui-card-content\"\n #contentWrap\n [class._empty]=\"!hasContent()\"\n [class._flush]=\"contentFlush()\"\n >\n <ng-content />\n </div>\n\n @if (hasFooter()) {\n <div class=\"ui-card-footer\">\n <ng-content select=\"[uiCardFooter], ui-card-footer\" />\n </div>\n }\n </div>\n</div>\n","/*\n * Public API Surface of ui-kit/ui-card\n */\n\nexport * from './lib/ui-card';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAeA;;;;;;;;;;;;AAYG;AACH;MAEa,WAAW,CAAA;8GAAX,WAAW,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAAX,WAAW,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,8BAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAAX,WAAW,EAAA,UAAA,EAAA,CAAA;kBADvB,SAAS;mBAAC,EAAE,QAAQ,EAAE,8BAA8B,EAAE;;AAGvD;MAEa,WAAW,CAAA;8GAAX,WAAW,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAAX,WAAW,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,8BAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAAX,WAAW,EAAA,UAAA,EAAA,CAAA;kBADvB,SAAS;mBAAC,EAAE,QAAQ,EAAE,8BAA8B,EAAE;;AAGvD;MAEa,cAAc,CAAA;8GAAd,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAAd,cAAc,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,oCAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAD1B,SAAS;mBAAC,EAAE,QAAQ,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,8FAER,cAAc,CAAA,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,SAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,YAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,UAAA,CAAA,MAEjB,WAAW,CAAA,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,UAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,YAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,UAAA,CAAA,MAEV,YAAY,sEAGS,aAAa,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AE1FjF;;AAEG;;ACFH;;AAEG;;;;"}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, booleanAttribute, output, viewChild, computed, effect, forwardRef, Component } from '@angular/core';
|
|
3
|
+
import { NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
4
|
+
import { BaseFieldControl } from '@4sh/ui-kit/forms';
|
|
5
|
+
import { UiIcon } from '@4sh/ui-kit/ui-icon';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* ui-checkbox — headless checkbox built on a real native <input type="checkbox">.
|
|
9
|
+
*
|
|
10
|
+
* The native input stays in the DOM (visually covering the styled box) so
|
|
11
|
+
* keyboard, screen readers, label click and form semantics come for free.
|
|
12
|
+
* Interactive states (hover/focus/disabled/checked) are pure CSS driven by
|
|
13
|
+
* `form.*` design tokens.
|
|
14
|
+
*
|
|
15
|
+
* Works standalone, with [(ngModel)] or with reactive forms (ControlValueAccessor).
|
|
16
|
+
* By default the model value is boolean; `trueValue`/`falseValue` let the model
|
|
17
|
+
* carry any pair of values (e.g. 'yes'/'no', 1/0).
|
|
18
|
+
*/
|
|
19
|
+
class UiCheckbox extends BaseFieldControl {
|
|
20
|
+
constructor() {
|
|
21
|
+
super();
|
|
22
|
+
/** Label displayed next to the box (clicking it toggles the checkbox). */
|
|
23
|
+
this.label = input(/* @ts-ignore */
|
|
24
|
+
...(ngDevMode ? [undefined, { debugName: "label" }] : /* istanbul ignore next */ []));
|
|
25
|
+
/** Model value emitted when checked. */
|
|
26
|
+
this.trueValue = input(true, /* @ts-ignore */
|
|
27
|
+
...(ngDevMode ? [{ debugName: "trueValue" }] : /* istanbul ignore next */ []));
|
|
28
|
+
/** Model value emitted when unchecked. */
|
|
29
|
+
this.falseValue = input(false, /* @ts-ignore */
|
|
30
|
+
...(ngDevMode ? [{ debugName: "falseValue" }] : /* istanbul ignore next */ []));
|
|
31
|
+
/** Visual indeterminate state ("some but not all selected"). Purely visual: the model keeps its value. */
|
|
32
|
+
this.indeterminate = input(false, { ...(ngDevMode ? { debugName: "indeterminate" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
33
|
+
/** Icon shown when checked. */
|
|
34
|
+
this.checkIcon = input('check', /* @ts-ignore */
|
|
35
|
+
...(ngDevMode ? [{ debugName: "checkIcon" }] : /* istanbul ignore next */ []));
|
|
36
|
+
/** Icon shown when indeterminate. */
|
|
37
|
+
this.indeterminateIcon = input('minus', /* @ts-ignore */
|
|
38
|
+
...(ngDevMode ? [{ debugName: "indeterminateIcon" }] : /* istanbul ignore next */ []));
|
|
39
|
+
/** Emitted on user toggle with the new model value (never when disabled/readonly). */
|
|
40
|
+
this.checkboxChange = output();
|
|
41
|
+
/** Emitted when the native input receives focus. */
|
|
42
|
+
this.checkboxFocus = output();
|
|
43
|
+
/** Emitted when the native input loses focus. */
|
|
44
|
+
this.checkboxBlur = output();
|
|
45
|
+
/** @ignore */
|
|
46
|
+
this.inputEl = viewChild.required('inputEl', /* @ts-ignore */
|
|
47
|
+
...(ngDevMode ? [{ debugName: "inputEl" }] : /* istanbul ignore next */ []));
|
|
48
|
+
/** @ignore */
|
|
49
|
+
this.checked = computed(() => this.modelValue() === this.trueValue(), /* @ts-ignore */
|
|
50
|
+
...(ngDevMode ? [{ debugName: "checked" }] : /* istanbul ignore next */ []));
|
|
51
|
+
/** @ignore */
|
|
52
|
+
this.classes = computed(() => {
|
|
53
|
+
const c = ['ui-checkbox'];
|
|
54
|
+
if (this.checked())
|
|
55
|
+
c.push('_checked');
|
|
56
|
+
if (this.indeterminate())
|
|
57
|
+
c.push('_indeterminate');
|
|
58
|
+
if (this.isDisabled())
|
|
59
|
+
c.push('_disabled');
|
|
60
|
+
if (this.readonly())
|
|
61
|
+
c.push('_readonly');
|
|
62
|
+
if (this.isInvalid())
|
|
63
|
+
c.push('_invalid');
|
|
64
|
+
return c.join(' ');
|
|
65
|
+
}, /* @ts-ignore */
|
|
66
|
+
...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
67
|
+
// The `indeterminate` state only exists as a DOM property.
|
|
68
|
+
effect(() => {
|
|
69
|
+
this.inputEl().nativeElement.indeterminate = this.indeterminate();
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
/** @ignore */
|
|
73
|
+
uidPrefix() {
|
|
74
|
+
return 'ui-checkbox';
|
|
75
|
+
}
|
|
76
|
+
/** Focus the native input programmatically. */
|
|
77
|
+
focus(options) {
|
|
78
|
+
this.inputEl().nativeElement.focus(options);
|
|
79
|
+
}
|
|
80
|
+
/** @ignore Native change: single source of truth for user toggles. */
|
|
81
|
+
onNativeChange() {
|
|
82
|
+
const inputEl = this.inputEl().nativeElement;
|
|
83
|
+
if (this.readonly()) {
|
|
84
|
+
inputEl.checked = this.checked(); // revert the native toggle
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
87
|
+
const value = inputEl.checked ? this.trueValue() : this.falseValue();
|
|
88
|
+
this.modelValue.set(value);
|
|
89
|
+
this.emitChange(value);
|
|
90
|
+
this.checkboxChange.emit(value);
|
|
91
|
+
}
|
|
92
|
+
/** @ignore */
|
|
93
|
+
onBlur(event) {
|
|
94
|
+
this.emitTouch();
|
|
95
|
+
this.checkboxBlur.emit(event);
|
|
96
|
+
}
|
|
97
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCheckbox, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
98
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: UiCheckbox, isStandalone: true, selector: "ui-checkbox", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, trueValue: { classPropertyName: "trueValue", publicName: "trueValue", isSignal: true, isRequired: false, transformFunction: null }, falseValue: { classPropertyName: "falseValue", publicName: "falseValue", isSignal: true, isRequired: false, transformFunction: null }, indeterminate: { classPropertyName: "indeterminate", publicName: "indeterminate", isSignal: true, isRequired: false, transformFunction: null }, checkIcon: { classPropertyName: "checkIcon", publicName: "checkIcon", isSignal: true, isRequired: false, transformFunction: null }, indeterminateIcon: { classPropertyName: "indeterminateIcon", publicName: "indeterminateIcon", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { checkboxChange: "checkboxChange", checkboxFocus: "checkboxFocus", checkboxBlur: "checkboxBlur" }, providers: [
|
|
99
|
+
{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => UiCheckbox), multi: true },
|
|
100
|
+
], viewQueries: [{ propertyName: "inputEl", first: true, predicate: ["inputEl"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<label [class]=\"classes()\">\n <span class=\"ui-checkbox-control\">\n <input\n #inputEl\n type=\"checkbox\"\n class=\"ui-checkbox-input\"\n [id]=\"resolvedId()\"\n [checked]=\"checked()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required()\"\n [attr.name]=\"name() || null\"\n [attr.tabindex]=\"tabindex()\"\n [attr.aria-label]=\"label() ? null : ariaLabel() || null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() || null\"\n [attr.aria-invalid]=\"isInvalid() ? 'true' : null\"\n (change)=\"onNativeChange()\"\n (focus)=\"checkboxFocus.emit($event)\"\n (blur)=\"onBlur($event)\"\n />\n <span class=\"ui-checkbox-box\" aria-hidden=\"true\">\n <ui-icon\n class=\"ui-checkbox-icon\"\n [name]=\"indeterminate() ? indeterminateIcon() : checkIcon()\"\n size=\"md\"\n />\n </span>\n </span>\n\n @if (label()) {\n <span class=\"ui-checkbox-label\">\n <span class=\"ui-checkbox-text\">{{ label() }}</span>\n @if (required()) {\n <span class=\"ui-checkbox-required\" aria-hidden=\"true\">*</span>\n }\n </span>\n }\n</label>\n", styles: [".ui-checkbox{display:inline-flex;align-items:center;gap:var(--units-sm);cursor:pointer;--_surface: var(--form-high-surface-default);--_stroke: var(--form-high-stroke-default);--_content: var(--form-high-content-checked)}.ui-checkbox:hover:not(._disabled):not(._readonly){--_surface: var(--form-high-surface-hover);--_stroke: var(--form-high-stroke-hover);--ui-label-color: var(--form-high-content-hover)}.ui-checkbox._checked:not(._disabled),.ui-checkbox._indeterminate:not(._disabled){--_surface: var(--form-high-surface-checked);--_stroke: var(--form-high-stroke-checked)}.ui-checkbox:has(.ui-checkbox-input:focus-visible){--_stroke: var(--form-high-stroke-focused);--_focus-ring: rgb(from var(--form-high-stroke-focused) r g b / 50%)}.ui-checkbox._disabled{--_surface: var(--form-high-surface-disabled);--_stroke: var(--form-high-stroke-disabled);--_content: var(--form-high-content-disabled)}.ui-checkbox._invalid{--_surface: var(--form-error-surface-default);--_stroke: var(--form-error-stroke-default);--_content: var(--form-error-content-checked)}.ui-checkbox._invalid:hover:not(._disabled):not(._readonly){--_surface: var(--form-error-surface-hover);--_stroke: var(--form-error-stroke-hover);--ui-label-color: var(--form-error-content-hover)}.ui-checkbox._invalid._checked:not(._disabled),.ui-checkbox._invalid._indeterminate:not(._disabled){--_surface: var(--form-error-surface-checked);--_stroke: var(--form-error-stroke-checked)}.ui-checkbox._invalid:has(.ui-checkbox-input:focus-visible){--_stroke: var(--form-error-stroke-focused);--_focus-ring: rgb(from var(--form-error-stroke-focused) r g b / 50%)}.ui-checkbox._invalid._disabled{--_surface: var(--form-error-surface-disabled);--_stroke: var(--form-error-stroke-disabled);--_content: var(--form-error-content-disabled)}.ui-checkbox-control{position:relative;display:inline-flex;width:var(--size-components-2xs);height:var(--size-components-2xs);flex-shrink:0}.ui-checkbox-input{position:absolute;inset:0;z-index:1;width:100%;height:100%;margin:0;opacity:0;cursor:inherit}.ui-checkbox-box{display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:100%;height:100%;background-color:var(--_surface);border:var(--stroke-default) solid var(--_stroke);border-radius:var(--radius-xs);transition:background-color var(--transition-default) var(--transition-easeinout),border-color var(--transition-default) var(--transition-easeinout),box-shadow var(--transition-default) var(--transition-easeinout)}.ui-checkbox:has(.ui-checkbox-input:focus-visible) .ui-checkbox-box{box-shadow:0 0 0 var(--units-2xs) var(--_focus-ring)}.ui-checkbox-icon{color:var(--_content);opacity:0;transform:scale(.6);transition:opacity var(--transition-default) var(--transition-easeinout),transform var(--transition-default) var(--transition-easeinout)}.ui-checkbox._checked .ui-checkbox-icon,.ui-checkbox._indeterminate .ui-checkbox-icon{opacity:1;transform:scale(1)}.ui-checkbox-label{display:inline-flex;align-items:center;gap:var(--units-2xs);font-family:var(--fontfamily-base);font-size:var(--size-typography-text-default);color:var(--ui-label-color, var(--form-high-content-default));cursor:inherit;-webkit-user-select:none;user-select:none;transition:color var(--transition-default) var(--transition-easeinout)}.ui-checkbox-required{color:var(--informative-errorlow-content-default)}.ui-checkbox._disabled{cursor:not-allowed}.ui-checkbox._disabled .ui-checkbox-label{color:var(--form-high-content-disabled)}.ui-checkbox._readonly{cursor:default}\n"], dependencies: [{ kind: "component", type: UiIcon, selector: "ui-icon", inputs: ["name", "size", "type", "family", "decorative", "ariaLabel"] }] }); }
|
|
101
|
+
}
|
|
102
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: UiCheckbox, decorators: [{
|
|
103
|
+
type: Component,
|
|
104
|
+
args: [{ selector: 'ui-checkbox', imports: [UiIcon], providers: [
|
|
105
|
+
{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => UiCheckbox), multi: true },
|
|
106
|
+
], template: "<label [class]=\"classes()\">\n <span class=\"ui-checkbox-control\">\n <input\n #inputEl\n type=\"checkbox\"\n class=\"ui-checkbox-input\"\n [id]=\"resolvedId()\"\n [checked]=\"checked()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required()\"\n [attr.name]=\"name() || null\"\n [attr.tabindex]=\"tabindex()\"\n [attr.aria-label]=\"label() ? null : ariaLabel() || null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() || null\"\n [attr.aria-invalid]=\"isInvalid() ? 'true' : null\"\n (change)=\"onNativeChange()\"\n (focus)=\"checkboxFocus.emit($event)\"\n (blur)=\"onBlur($event)\"\n />\n <span class=\"ui-checkbox-box\" aria-hidden=\"true\">\n <ui-icon\n class=\"ui-checkbox-icon\"\n [name]=\"indeterminate() ? indeterminateIcon() : checkIcon()\"\n size=\"md\"\n />\n </span>\n </span>\n\n @if (label()) {\n <span class=\"ui-checkbox-label\">\n <span class=\"ui-checkbox-text\">{{ label() }}</span>\n @if (required()) {\n <span class=\"ui-checkbox-required\" aria-hidden=\"true\">*</span>\n }\n </span>\n }\n</label>\n", styles: [".ui-checkbox{display:inline-flex;align-items:center;gap:var(--units-sm);cursor:pointer;--_surface: var(--form-high-surface-default);--_stroke: var(--form-high-stroke-default);--_content: var(--form-high-content-checked)}.ui-checkbox:hover:not(._disabled):not(._readonly){--_surface: var(--form-high-surface-hover);--_stroke: var(--form-high-stroke-hover);--ui-label-color: var(--form-high-content-hover)}.ui-checkbox._checked:not(._disabled),.ui-checkbox._indeterminate:not(._disabled){--_surface: var(--form-high-surface-checked);--_stroke: var(--form-high-stroke-checked)}.ui-checkbox:has(.ui-checkbox-input:focus-visible){--_stroke: var(--form-high-stroke-focused);--_focus-ring: rgb(from var(--form-high-stroke-focused) r g b / 50%)}.ui-checkbox._disabled{--_surface: var(--form-high-surface-disabled);--_stroke: var(--form-high-stroke-disabled);--_content: var(--form-high-content-disabled)}.ui-checkbox._invalid{--_surface: var(--form-error-surface-default);--_stroke: var(--form-error-stroke-default);--_content: var(--form-error-content-checked)}.ui-checkbox._invalid:hover:not(._disabled):not(._readonly){--_surface: var(--form-error-surface-hover);--_stroke: var(--form-error-stroke-hover);--ui-label-color: var(--form-error-content-hover)}.ui-checkbox._invalid._checked:not(._disabled),.ui-checkbox._invalid._indeterminate:not(._disabled){--_surface: var(--form-error-surface-checked);--_stroke: var(--form-error-stroke-checked)}.ui-checkbox._invalid:has(.ui-checkbox-input:focus-visible){--_stroke: var(--form-error-stroke-focused);--_focus-ring: rgb(from var(--form-error-stroke-focused) r g b / 50%)}.ui-checkbox._invalid._disabled{--_surface: var(--form-error-surface-disabled);--_stroke: var(--form-error-stroke-disabled);--_content: var(--form-error-content-disabled)}.ui-checkbox-control{position:relative;display:inline-flex;width:var(--size-components-2xs);height:var(--size-components-2xs);flex-shrink:0}.ui-checkbox-input{position:absolute;inset:0;z-index:1;width:100%;height:100%;margin:0;opacity:0;cursor:inherit}.ui-checkbox-box{display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:100%;height:100%;background-color:var(--_surface);border:var(--stroke-default) solid var(--_stroke);border-radius:var(--radius-xs);transition:background-color var(--transition-default) var(--transition-easeinout),border-color var(--transition-default) var(--transition-easeinout),box-shadow var(--transition-default) var(--transition-easeinout)}.ui-checkbox:has(.ui-checkbox-input:focus-visible) .ui-checkbox-box{box-shadow:0 0 0 var(--units-2xs) var(--_focus-ring)}.ui-checkbox-icon{color:var(--_content);opacity:0;transform:scale(.6);transition:opacity var(--transition-default) var(--transition-easeinout),transform var(--transition-default) var(--transition-easeinout)}.ui-checkbox._checked .ui-checkbox-icon,.ui-checkbox._indeterminate .ui-checkbox-icon{opacity:1;transform:scale(1)}.ui-checkbox-label{display:inline-flex;align-items:center;gap:var(--units-2xs);font-family:var(--fontfamily-base);font-size:var(--size-typography-text-default);color:var(--ui-label-color, var(--form-high-content-default));cursor:inherit;-webkit-user-select:none;user-select:none;transition:color var(--transition-default) var(--transition-easeinout)}.ui-checkbox-required{color:var(--informative-errorlow-content-default)}.ui-checkbox._disabled{cursor:not-allowed}.ui-checkbox._disabled .ui-checkbox-label{color:var(--form-high-content-disabled)}.ui-checkbox._readonly{cursor:default}\n"] }]
|
|
107
|
+
}], ctorParameters: () => [], propDecorators: { label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], trueValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "trueValue", required: false }] }], falseValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "falseValue", required: false }] }], indeterminate: [{ type: i0.Input, args: [{ isSignal: true, alias: "indeterminate", required: false }] }], checkIcon: [{ type: i0.Input, args: [{ isSignal: true, alias: "checkIcon", required: false }] }], indeterminateIcon: [{ type: i0.Input, args: [{ isSignal: true, alias: "indeterminateIcon", required: false }] }], checkboxChange: [{ type: i0.Output, args: ["checkboxChange"] }], checkboxFocus: [{ type: i0.Output, args: ["checkboxFocus"] }], checkboxBlur: [{ type: i0.Output, args: ["checkboxBlur"] }], inputEl: [{ type: i0.ViewChild, args: ['inputEl', { isSignal: true }] }] } });
|
|
108
|
+
|
|
109
|
+
/*
|
|
110
|
+
* Public API Surface of ui-kit/ui-checkbox
|
|
111
|
+
*/
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Generated bundle index. Do not edit.
|
|
115
|
+
*/
|
|
116
|
+
|
|
117
|
+
export { UiCheckbox };
|
|
118
|
+
//# sourceMappingURL=4sh-ui-kit-ui-checkbox.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"4sh-ui-kit-ui-checkbox.mjs","sources":["../../../projects/ui-kit/ui-checkbox/src/lib/ui-checkbox.ts","../../../projects/ui-kit/ui-checkbox/src/lib/ui-checkbox.html","../../../projects/ui-kit/ui-checkbox/src/public-api.ts","../../../projects/ui-kit/ui-checkbox/src/4sh-ui-kit-ui-checkbox.ts"],"sourcesContent":["import {\n booleanAttribute,\n Component,\n computed,\n effect,\n ElementRef,\n forwardRef,\n input,\n output,\n viewChild,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { BaseFieldControl } from '@4sh/ui-kit/forms';\nimport { UiIcon } from '@4sh/ui-kit/ui-icon';\n\n/**\n * ui-checkbox — headless checkbox built on a real native <input type=\"checkbox\">.\n *\n * The native input stays in the DOM (visually covering the styled box) so\n * keyboard, screen readers, label click and form semantics come for free.\n * Interactive states (hover/focus/disabled/checked) are pure CSS driven by\n * `form.*` design tokens.\n *\n * Works standalone, with [(ngModel)] or with reactive forms (ControlValueAccessor).\n * By default the model value is boolean; `trueValue`/`falseValue` let the model\n * carry any pair of values (e.g. 'yes'/'no', 1/0).\n */\n@Component({\n selector: 'ui-checkbox',\n imports: [UiIcon],\n templateUrl: './ui-checkbox.html',\n styleUrl: './ui-checkbox.scss',\n providers: [\n { provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => UiCheckbox), multi: true },\n ],\n})\nexport class UiCheckbox<T = boolean> extends BaseFieldControl<T> {\n /** Label displayed next to the box (clicking it toggles the checkbox). */\n label = input<string>();\n /** Model value emitted when checked. */\n trueValue = input<T>(true as T);\n /** Model value emitted when unchecked. */\n falseValue = input<T>(false as T);\n /** Visual indeterminate state (\"some but not all selected\"). Purely visual: the model keeps its value. */\n indeterminate = input(false, { transform: booleanAttribute });\n /** Icon shown when checked. */\n checkIcon = input<string>('check');\n /** Icon shown when indeterminate. */\n indeterminateIcon = input<string>('minus');\n\n /** Emitted on user toggle with the new model value (never when disabled/readonly). */\n checkboxChange = output<T>();\n /** Emitted when the native input receives focus. */\n checkboxFocus = output<FocusEvent>();\n /** Emitted when the native input loses focus. */\n checkboxBlur = output<FocusEvent>();\n\n /** @ignore */\n private readonly inputEl = viewChild.required<ElementRef<HTMLInputElement>>('inputEl');\n\n constructor() {\n super();\n // The `indeterminate` state only exists as a DOM property.\n effect(() => {\n this.inputEl().nativeElement.indeterminate = this.indeterminate();\n });\n }\n\n /** @ignore */\n protected readonly checked = computed(() => this.modelValue() === this.trueValue());\n\n /** @ignore */\n protected readonly classes = computed(() => {\n const c = ['ui-checkbox'];\n if (this.checked()) c.push('_checked');\n if (this.indeterminate()) c.push('_indeterminate');\n if (this.isDisabled()) c.push('_disabled');\n if (this.readonly()) c.push('_readonly');\n if (this.isInvalid()) c.push('_invalid');\n return c.join(' ');\n });\n\n /** @ignore */\n protected override uidPrefix(): string {\n return 'ui-checkbox';\n }\n\n /** Focus the native input programmatically. */\n focus(options?: FocusOptions): void {\n this.inputEl().nativeElement.focus(options);\n }\n\n /** @ignore Native change: single source of truth for user toggles. */\n protected onNativeChange(): void {\n const inputEl = this.inputEl().nativeElement;\n if (this.readonly()) {\n inputEl.checked = this.checked(); // revert the native toggle\n return;\n }\n const value = inputEl.checked ? this.trueValue() : this.falseValue();\n this.modelValue.set(value);\n this.emitChange(value);\n this.checkboxChange.emit(value);\n }\n\n /** @ignore */\n protected onBlur(event: FocusEvent): void {\n this.emitTouch();\n this.checkboxBlur.emit(event);\n }\n}\n","<label [class]=\"classes()\">\n <span class=\"ui-checkbox-control\">\n <input\n #inputEl\n type=\"checkbox\"\n class=\"ui-checkbox-input\"\n [id]=\"resolvedId()\"\n [checked]=\"checked()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required()\"\n [attr.name]=\"name() || null\"\n [attr.tabindex]=\"tabindex()\"\n [attr.aria-label]=\"label() ? null : ariaLabel() || null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() || null\"\n [attr.aria-invalid]=\"isInvalid() ? 'true' : null\"\n (change)=\"onNativeChange()\"\n (focus)=\"checkboxFocus.emit($event)\"\n (blur)=\"onBlur($event)\"\n />\n <span class=\"ui-checkbox-box\" aria-hidden=\"true\">\n <ui-icon\n class=\"ui-checkbox-icon\"\n [name]=\"indeterminate() ? indeterminateIcon() : checkIcon()\"\n size=\"md\"\n />\n </span>\n </span>\n\n @if (label()) {\n <span class=\"ui-checkbox-label\">\n <span class=\"ui-checkbox-text\">{{ label() }}</span>\n @if (required()) {\n <span class=\"ui-checkbox-required\" aria-hidden=\"true\">*</span>\n }\n </span>\n }\n</label>\n","/*\n * Public API Surface of ui-kit/ui-checkbox\n */\n\nexport * from './lib/ui-checkbox';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAeA;;;;;;;;;;;AAWG;AAUG,MAAO,UAAwB,SAAQ,gBAAmB,CAAA;AAwB9D,IAAA,WAAA,GAAA;AACE,QAAA,KAAK,EAAE;;AAvBT,QAAA,IAAA,CAAA,KAAK,GAAG,KAAK;6FAAU;;QAEvB,IAAA,CAAA,SAAS,GAAG,KAAK,CAAI,IAAS;sFAAC;;QAE/B,IAAA,CAAA,UAAU,GAAG,KAAK,CAAI,KAAU;uFAAC;;QAEjC,IAAA,CAAA,aAAa,GAAG,KAAK,CAAC,KAAK,qFAAI,SAAS,EAAE,gBAAgB,EAAA,CAAG;;QAE7D,IAAA,CAAA,SAAS,GAAG,KAAK,CAAS,OAAO;sFAAC;;QAElC,IAAA,CAAA,iBAAiB,GAAG,KAAK,CAAS,OAAO;8FAAC;;QAG1C,IAAA,CAAA,cAAc,GAAG,MAAM,EAAK;;QAE5B,IAAA,CAAA,aAAa,GAAG,MAAM,EAAc;;QAEpC,IAAA,CAAA,YAAY,GAAG,MAAM,EAAc;;AAGlB,QAAA,IAAA,CAAA,OAAO,GAAG,SAAS,CAAC,QAAQ,CAA+B,SAAS;oFAAC;;AAWnE,QAAA,IAAA,CAAA,OAAO,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,UAAU,EAAE,KAAK,IAAI,CAAC,SAAS,EAAE;oFAAC;;AAGhE,QAAA,IAAA,CAAA,OAAO,GAAG,QAAQ,CAAC,MAAK;AACzC,YAAA,MAAM,CAAC,GAAG,CAAC,aAAa,CAAC;YACzB,IAA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