ngx-com 0.0.21 → 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/README.md +137 -33
- package/fesm2022/ngx-com-components-alert.mjs +21 -11
- package/fesm2022/ngx-com-components-alert.mjs.map +1 -1
- package/fesm2022/ngx-com-components-avatar.mjs +9 -7
- package/fesm2022/ngx-com-components-avatar.mjs.map +1 -1
- package/fesm2022/ngx-com-components-button.mjs +1 -1
- package/fesm2022/ngx-com-components-button.mjs.map +1 -1
- package/fesm2022/ngx-com-components-calendar.mjs +27 -3112
- package/fesm2022/ngx-com-components-calendar.mjs.map +1 -1
- package/fesm2022/ngx-com-components-card.mjs +8 -8
- package/fesm2022/ngx-com-components-card.mjs.map +1 -1
- package/fesm2022/ngx-com-components-carousel.mjs +16 -4
- package/fesm2022/ngx-com-components-carousel.mjs.map +1 -1
- package/fesm2022/ngx-com-components-checkbox.mjs +1 -1
- package/fesm2022/ngx-com-components-checkbox.mjs.map +1 -1
- package/fesm2022/ngx-com-components-code-block.mjs +9 -9
- package/fesm2022/ngx-com-components-code-block.mjs.map +1 -1
- package/fesm2022/ngx-com-components-collapsible.mjs +15 -13
- package/fesm2022/ngx-com-components-collapsible.mjs.map +1 -1
- package/fesm2022/ngx-com-components-confirm.mjs +4 -4
- package/fesm2022/ngx-com-components-confirm.mjs.map +1 -1
- package/fesm2022/ngx-com-components-datepicker.mjs +2334 -0
- package/fesm2022/ngx-com-components-datepicker.mjs.map +1 -0
- package/fesm2022/ngx-com-components-dialog.mjs +47 -45
- package/fesm2022/ngx-com-components-dialog.mjs.map +1 -1
- package/fesm2022/ngx-com-components-dropdown.mjs +446 -340
- package/fesm2022/ngx-com-components-dropdown.mjs.map +1 -1
- package/fesm2022/ngx-com-components-empty-state.mjs +5 -3
- package/fesm2022/ngx-com-components-empty-state.mjs.map +1 -1
- package/fesm2022/ngx-com-components-form-field.mjs +11 -6
- package/fesm2022/ngx-com-components-form-field.mjs.map +1 -1
- package/fesm2022/ngx-com-components-icon-lucide.mjs +41 -0
- package/fesm2022/ngx-com-components-icon-lucide.mjs.map +1 -0
- package/fesm2022/ngx-com-components-icon.mjs +89 -61
- package/fesm2022/ngx-com-components-icon.mjs.map +1 -1
- package/fesm2022/ngx-com-components-item.mjs +14 -4
- package/fesm2022/ngx-com-components-item.mjs.map +1 -1
- package/fesm2022/ngx-com-components-menu.mjs +61 -69
- package/fesm2022/ngx-com-components-menu.mjs.map +1 -1
- package/fesm2022/ngx-com-components-native-control.mjs +170 -0
- package/fesm2022/ngx-com-components-native-control.mjs.map +1 -0
- package/fesm2022/ngx-com-components-paginator.mjs +11 -3
- package/fesm2022/ngx-com-components-paginator.mjs.map +1 -1
- package/fesm2022/ngx-com-components-popover.mjs +58 -33
- package/fesm2022/ngx-com-components-popover.mjs.map +1 -1
- package/fesm2022/ngx-com-components-radio.mjs +4 -4
- package/fesm2022/ngx-com-components-radio.mjs.map +1 -1
- package/fesm2022/ngx-com-components-segmented-control.mjs +6 -4
- package/fesm2022/ngx-com-components-segmented-control.mjs.map +1 -1
- package/fesm2022/ngx-com-components-sort.mjs +63 -57
- package/fesm2022/ngx-com-components-sort.mjs.map +1 -1
- package/fesm2022/ngx-com-components-spinner.mjs +6 -6
- package/fesm2022/ngx-com-components-spinner.mjs.map +1 -1
- package/fesm2022/ngx-com-components-switch.mjs +18 -9
- package/fesm2022/ngx-com-components-switch.mjs.map +1 -1
- package/fesm2022/ngx-com-components-table.mjs +23 -9
- package/fesm2022/ngx-com-components-table.mjs.map +1 -1
- package/fesm2022/ngx-com-components-tabs.mjs +81 -58
- package/fesm2022/ngx-com-components-tabs.mjs.map +1 -1
- package/fesm2022/ngx-com-components-timepicker.mjs +1048 -0
- package/fesm2022/ngx-com-components-timepicker.mjs.map +1 -0
- package/fesm2022/ngx-com-components-toast.mjs +18 -14
- package/fesm2022/ngx-com-components-toast.mjs.map +1 -1
- package/fesm2022/ngx-com-components-tooltip.mjs +5 -5
- package/fesm2022/ngx-com-components-tooltip.mjs.map +1 -1
- package/fesm2022/ngx-com-components.mjs +0 -13
- package/fesm2022/ngx-com-components.mjs.map +1 -1
- package/fesm2022/ngx-com-tokens.mjs +0 -8
- package/fesm2022/ngx-com-tokens.mjs.map +1 -1
- package/fesm2022/ngx-com-utils.mjs +13 -1
- package/fesm2022/ngx-com-utils.mjs.map +1 -1
- package/fesm2022/ngx-com.mjs +1 -1
- package/fesm2022/ngx-com.mjs.map +1 -1
- package/package.json +51 -8
- package/styles/animations.css +38 -0
- package/styles/candy.css +121 -0
- package/styles/dark.css +159 -0
- package/styles/forest.css +117 -0
- package/styles/ocean.css +117 -0
- package/styles/themes.css +7 -0
- package/styles/tokens.css +277 -0
- package/styles/utilities.css +16 -0
- package/types/ngx-com-components-alert.d.ts +14 -4
- package/types/ngx-com-components-avatar.d.ts +2 -0
- package/types/ngx-com-components-calendar.d.ts +3 -747
- package/types/ngx-com-components-card.d.ts +2 -2
- package/types/ngx-com-components-carousel.d.ts +11 -1
- package/types/ngx-com-components-code-block.d.ts +4 -4
- package/types/ngx-com-components-collapsible.d.ts +10 -2
- package/types/ngx-com-components-confirm.d.ts +2 -2
- package/types/ngx-com-components-datepicker.d.ts +623 -0
- package/types/ngx-com-components-dialog.d.ts +5 -2
- package/types/ngx-com-components-dropdown.d.ts +22 -4
- package/types/ngx-com-components-empty-state.d.ts +2 -0
- package/types/ngx-com-components-form-field.d.ts +4 -1
- package/types/ngx-com-components-icon-lucide.d.ts +32 -0
- package/types/ngx-com-components-icon.d.ts +49 -35
- package/types/ngx-com-components-item.d.ts +12 -2
- package/types/ngx-com-components-menu.d.ts +38 -38
- package/types/ngx-com-components-native-control.d.ts +99 -0
- package/types/ngx-com-components-paginator.d.ts +2 -0
- package/types/ngx-com-components-popover.d.ts +19 -12
- package/types/ngx-com-components-segmented-control.d.ts +3 -1
- package/types/ngx-com-components-sort.d.ts +13 -10
- package/types/ngx-com-components-switch.d.ts +7 -2
- package/types/ngx-com-components-table.d.ts +16 -2
- package/types/ngx-com-components-tabs.d.ts +46 -34
- package/types/ngx-com-components-timepicker.d.ts +273 -0
- package/types/ngx-com-components-toast.d.ts +4 -2
- package/types/ngx-com-components-tooltip.d.ts +1 -1
- package/types/ngx-com-components.d.ts +6 -7
- package/types/ngx-com-tokens.d.ts +5 -3
- package/types/ngx-com-utils.d.ts +11 -1
- package/types/ngx-com.d.ts +1 -1
|
@@ -42,9 +42,9 @@ const emptyStateVariants = cva('flex', {
|
|
|
42
42
|
const emptyStateIconVariants = cva('flex items-center justify-center shrink-0 bg-muted text-muted-foreground', {
|
|
43
43
|
variants: {
|
|
44
44
|
size: {
|
|
45
|
-
sm: 'size-10 rounded-
|
|
46
|
-
md: 'size-14 rounded-
|
|
47
|
-
lg: 'size-20 rounded-
|
|
45
|
+
sm: 'size-10 rounded-card',
|
|
46
|
+
md: 'size-14 rounded-card',
|
|
47
|
+
lg: 'size-20 rounded-card',
|
|
48
48
|
},
|
|
49
49
|
},
|
|
50
50
|
defaultVariants: {
|
|
@@ -343,6 +343,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
|
|
|
343
343
|
* Apply to a container element. Place buttons inside.
|
|
344
344
|
* Styling automatically adapts to the parent's `size` input.
|
|
345
345
|
*
|
|
346
|
+
* @tokens none
|
|
347
|
+
*
|
|
346
348
|
* @example Single action
|
|
347
349
|
* ```html
|
|
348
350
|
* <div comEmptyStateActions>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-com-components-empty-state.mjs","sources":["../../../projects/com/components/empty-state/empty-state.variants.ts","../../../projects/com/components/empty-state/empty-state.component.ts","../../../projects/com/components/empty-state/empty-state-icon.directive.ts","../../../projects/com/components/empty-state/empty-state-title.directive.ts","../../../projects/com/components/empty-state/empty-state-description.directive.ts","../../../projects/com/components/empty-state/empty-state-actions.directive.ts","../../../projects/com/components/empty-state/ngx-com-components-empty-state.ts"],"sourcesContent":["import { cva } from 'class-variance-authority';\n\nexport type EmptyStateSize = 'sm' | 'md' | 'lg';\nexport type EmptyStateAlign = 'start' | 'center';\nexport type EmptyStateOrientation = 'vertical' | 'horizontal';\n\n/**\n * CVA variants for the empty state container.\n *\n * @tokens `--color-foreground`, `--color-muted`, `--color-muted-foreground`\n */\nexport const emptyStateVariants: (props?: {\n size?: EmptyStateSize;\n align?: EmptyStateAlign;\n orientation?: EmptyStateOrientation;\n}) => string = cva('flex', {\n variants: {\n orientation: {\n vertical: 'flex-col',\n horizontal: 'flex-row',\n },\n align: {\n center: 'items-center text-center',\n start: 'items-start text-left',\n },\n size: {\n sm: 'gap-2 py-4',\n md: 'gap-3 py-6',\n lg: 'gap-4 py-10',\n },\n },\n compoundVariants: [\n { orientation: 'horizontal', align: 'center', class: 'justify-center' },\n { orientation: 'horizontal', align: 'start', class: 'justify-start' },\n ],\n defaultVariants: {\n size: 'md',\n align: 'center',\n orientation: 'vertical',\n },\n});\n\n/**\n * CVA variants for the empty state icon container.\n *\n * @tokens `--color-muted`, `--color-muted-foreground`\n */\nexport const emptyStateIconVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'flex items-center justify-center shrink-0 bg-muted text-muted-foreground',\n {\n variants: {\n size: {\n sm: 'size-10 rounded-lg',\n md: 'size-14 rounded-xl',\n lg: 'size-20 rounded-2xl',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n\n/**\n * CVA variants for the empty state title.\n *\n * @tokens `--color-foreground`\n */\nexport const emptyStateTitleVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'font-heading tracking-tight text-foreground',\n {\n variants: {\n size: {\n sm: 'text-sm font-medium',\n md: 'text-base font-semibold',\n lg: 'text-lg font-semibold',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n\n/**\n * CVA variants for the empty state description.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const emptyStateDescriptionVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'text-muted-foreground',\n {\n variants: {\n size: {\n sm: 'text-xs max-w-[200px]',\n md: 'text-sm max-w-xs',\n lg: 'text-base max-w-sm',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n\n/**\n * CVA variants for the empty state actions container.\n */\nexport const emptyStateActionsVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'flex flex-wrap items-center justify-center',\n {\n variants: {\n size: {\n sm: 'gap-2 pt-1',\n md: 'gap-2.5 pt-2',\n lg: 'gap-3 pt-3',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n","import {\n ChangeDetectionStrategy,\n Component,\n computed,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport type { InputSignal, Signal } from '@angular/core';\nimport { mergeClasses } from 'ngx-com/utils';\nimport { emptyStateVariants } from './empty-state.variants';\nimport type { EmptyStateSize, EmptyStateAlign, EmptyStateOrientation } from './empty-state.variants';\n\n/**\n * Empty state component - a placeholder surface for when there is no data to display.\n *\n * Common use cases include:\n * - Empty lists or tables (\"No results found\")\n * - Initial states before user action (\"Create your first project\")\n * - Search results with no matches (\"No items match your search\")\n * - Error recovery states (\"Something went wrong. Try again.\")\n *\n * The component is a pure layout container that accepts projected content through attribute directives.\n *\n * @tokens `--color-muted`, `--color-muted-foreground`, `--color-foreground`\n *\n * @example Minimal empty state\n * ```html\n * <com-empty-state>\n * <div comEmptyStateIcon>\n * <com-icon name=\"inbox\" size=\"xl\" />\n * </div>\n * <h3 comEmptyStateTitle>No messages</h3>\n * </com-empty-state>\n * ```\n *\n * @example Full empty state with description and action\n * ```html\n * <com-empty-state>\n * <div comEmptyStateIcon>\n * <com-icon name=\"folder-open\" size=\"xl\" />\n * </div>\n * <h3 comEmptyStateTitle>No projects yet</h3>\n * <p comEmptyStateDescription>\n * Create your first project to get started organizing your work.\n * </p>\n * <div comEmptyStateActions>\n * <button comButton>Create Project</button>\n * </div>\n * </com-empty-state>\n * ```\n *\n * @example Search empty state with secondary action\n * ```html\n * <com-empty-state>\n * <div comEmptyStateIcon>\n * <com-icon name=\"search-x\" size=\"xl\" />\n * </div>\n * <h3 comEmptyStateTitle>No results found</h3>\n * <p comEmptyStateDescription>\n * Try adjusting your search terms or filters.\n * </p>\n * <div comEmptyStateActions>\n * <button comButton variant=\"outline\">Clear Filters</button>\n * <button comButton>New Search</button>\n * </div>\n * </com-empty-state>\n * ```\n *\n * @example Small size for inline contexts\n * ```html\n * <com-empty-state size=\"sm\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"list\" size=\"lg\" />\n * </div>\n * <h4 comEmptyStateTitle>No items</h4>\n * </com-empty-state>\n * ```\n *\n * @example Large size for full-page empty states\n * ```html\n * <com-empty-state size=\"lg\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"rocket\" size=\"2xl\" />\n * </div>\n * <h2 comEmptyStateTitle>Welcome to Acme</h2>\n * <p comEmptyStateDescription>\n * Your dashboard is ready. Start by creating your first resource.\n * </p>\n * <div comEmptyStateActions>\n * <button comButton size=\"lg\">Get Started</button>\n * </div>\n * </com-empty-state>\n * ```\n *\n * @example Horizontal orientation\n * ```html\n * <com-empty-state orientation=\"horizontal\" align=\"start\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"alert-circle\" size=\"lg\" />\n * </div>\n * <h4 comEmptyStateTitle>No notifications</h4>\n * <p comEmptyStateDescription>You're all caught up!</p>\n * </com-empty-state>\n * ```\n *\n * @example Left-aligned for sidebar contexts\n * ```html\n * <com-empty-state align=\"start\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"users\" size=\"lg\" />\n * </div>\n * <h4 comEmptyStateTitle>No team members</h4>\n * <p comEmptyStateDescription>Invite people to collaborate.</p>\n * <div comEmptyStateActions>\n * <button comButton size=\"sm\">Invite</button>\n * </div>\n * </com-empty-state>\n * ```\n */\n@Component({\n selector: 'com-empty-state',\n exportAs: 'comEmptyState',\n template: `<ng-content />`,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyState {\n /** Controls overall scale: icon container size, text sizes, spacing. */\n readonly size: InputSignal<EmptyStateSize> = input<EmptyStateSize>('md');\n\n /** Horizontal alignment of content. */\n readonly align: InputSignal<EmptyStateAlign> = input<EmptyStateAlign>('center');\n\n /** Layout direction: vertical stacks content, horizontal places icon beside text. */\n readonly orientation: InputSignal<EmptyStateOrientation> = input<EmptyStateOrientation>('vertical');\n\n /** Consumer CSS classes - merged with variant classes. */\n readonly userClass: InputSignal<string> = input<string>('', { alias: 'class' });\n\n protected readonly computedClass: Signal<string> = computed(() =>\n mergeClasses(\n emptyStateVariants({\n size: this.size(),\n align: this.align(),\n orientation: this.orientation(),\n }),\n this.userClass()\n )\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateIconVariants } from './empty-state.variants';\n\n/**\n * Empty state icon container directive - styled circular background for icon/illustration.\n *\n * Apply to a container element. Place any content inside (typically `com-icon`).\n * Styling automatically adapts to the parent's `size` input.\n *\n * @example\n * ```html\n * <div comEmptyStateIcon>\n * <com-icon name=\"inbox\" size=\"xl\" />\n * </div>\n * ```\n *\n * @example With custom illustration\n * ```html\n * <div comEmptyStateIcon>\n * <img src=\"/assets/empty-mailbox.svg\" alt=\"\" class=\"size-8\" />\n * </div>\n * ```\n *\n * @tokens `--color-muted`, `--color-muted-foreground`\n */\n@Directive({\n selector: '[comEmptyStateIcon]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateIcon {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateIconVariants({ size: this.emptyState.size() })\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateTitleVariants } from './empty-state.variants';\n\n/**\n * Empty state title directive - styled heading text.\n *\n * Apply to any heading element. Consumer picks the semantic level (h2, h3, etc.).\n * Styling automatically adapts to the parent's `size` input.\n *\n * @example\n * ```html\n * <h3 comEmptyStateTitle>No projects yet</h3>\n * ```\n *\n * @tokens `--color-foreground`\n */\n@Directive({\n selector: '[comEmptyStateTitle]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateTitle {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateTitleVariants({ size: this.emptyState.size() })\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateDescriptionVariants } from './empty-state.variants';\n\n/**\n * Empty state description directive - supporting text.\n *\n * Apply to a paragraph or text element.\n * Styling automatically adapts to the parent's `size` input.\n *\n * @example\n * ```html\n * <p comEmptyStateDescription>\n * Create your first project to get started organizing your work.\n * </p>\n * ```\n *\n * @tokens `--color-muted-foreground`\n */\n@Directive({\n selector: '[comEmptyStateDescription]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateDescription {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateDescriptionVariants({ size: this.emptyState.size() })\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateActionsVariants } from './empty-state.variants';\n\n/**\n * Empty state actions directive - container for action buttons.\n *\n * Apply to a container element. Place buttons inside.\n * Styling automatically adapts to the parent's `size` input.\n *\n * @example Single action\n * ```html\n * <div comEmptyStateActions>\n * <button comButton>Create Project</button>\n * </div>\n * ```\n *\n * @example Multiple actions\n * ```html\n * <div comEmptyStateActions>\n * <button comButton variant=\"outline\">Clear Filters</button>\n * <button comButton>New Search</button>\n * </div>\n * ```\n */\n@Directive({\n selector: '[comEmptyStateActions]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateActions {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateActionsVariants({ size: this.emptyState.size() })\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAMA;;;;AAIG;AACI,MAAM,kBAAkB,GAIhB,GAAG,CAAC,MAAM,EAAE;AACzB,IAAA,QAAQ,EAAE;AACR,QAAA,WAAW,EAAE;AACX,YAAA,QAAQ,EAAE,UAAU;AACpB,YAAA,UAAU,EAAE,UAAU;AACvB,SAAA;AACD,QAAA,KAAK,EAAE;AACL,YAAA,MAAM,EAAE,0BAA0B;AAClC,YAAA,KAAK,EAAE,uBAAuB;AAC/B,SAAA;AACD,QAAA,IAAI,EAAE;AACJ,YAAA,EAAE,EAAE,YAAY;AAChB,YAAA,EAAE,EAAE,YAAY;AAChB,YAAA,EAAE,EAAE,aAAa;AAClB,SAAA;AACF,KAAA;AACD,IAAA,gBAAgB,EAAE;QAChB,EAAE,WAAW,EAAE,YAAY,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,gBAAgB,EAAE;QACvE,EAAE,WAAW,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE;AACtE,KAAA;AACD,IAAA,eAAe,EAAE;AACf,QAAA,IAAI,EAAE,IAAI;AACV,QAAA,KAAK,EAAE,QAAQ;AACf,QAAA,WAAW,EAAE,UAAU;AACxB,KAAA;AACF,CAAA;AAED;;;;AAIG;AACI,MAAM,sBAAsB,GAAkD,GAAG,CACtF,0EAA0E,EAC1E;AACE,IAAA,QAAQ,EAAE;AACR,QAAA,IAAI,EAAE;AACJ,YAAA,EAAE,EAAE,oBAAoB;AACxB,YAAA,EAAE,EAAE,oBAAoB;AACxB,YAAA,EAAE,EAAE,qBAAqB;AAC1B,SAAA;AACF,KAAA;AACD,IAAA,eAAe,EAAE;AACf,QAAA,IAAI,EAAE,IAAI;AACX,KAAA;AACF,CAAA;AAGH;;;;AAIG;AACI,MAAM,uBAAuB,GAAkD,GAAG,CACvF,6CAA6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;2FAApB,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBANhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,wBAAwB;AAClC,oBAAA,IAAI,EAAE;AACJ,wBAAA,SAAS,EAAE,iBAAiB;AAC7B,qBAAA;AACF,iBAAA;;;AC9BD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"ngx-com-components-empty-state.mjs","sources":["../../../projects/com/components/empty-state/empty-state.variants.ts","../../../projects/com/components/empty-state/empty-state.component.ts","../../../projects/com/components/empty-state/empty-state-icon.directive.ts","../../../projects/com/components/empty-state/empty-state-title.directive.ts","../../../projects/com/components/empty-state/empty-state-description.directive.ts","../../../projects/com/components/empty-state/empty-state-actions.directive.ts","../../../projects/com/components/empty-state/ngx-com-components-empty-state.ts"],"sourcesContent":["import { cva } from 'class-variance-authority';\n\nexport type EmptyStateSize = 'sm' | 'md' | 'lg';\nexport type EmptyStateAlign = 'start' | 'center';\nexport type EmptyStateOrientation = 'vertical' | 'horizontal';\n\n/**\n * CVA variants for the empty state container.\n *\n * @tokens `--color-foreground`, `--color-muted`, `--color-muted-foreground`\n */\nexport const emptyStateVariants: (props?: {\n size?: EmptyStateSize;\n align?: EmptyStateAlign;\n orientation?: EmptyStateOrientation;\n}) => string = cva('flex', {\n variants: {\n orientation: {\n vertical: 'flex-col',\n horizontal: 'flex-row',\n },\n align: {\n center: 'items-center text-center',\n start: 'items-start text-left',\n },\n size: {\n sm: 'gap-2 py-4',\n md: 'gap-3 py-6',\n lg: 'gap-4 py-10',\n },\n },\n compoundVariants: [\n { orientation: 'horizontal', align: 'center', class: 'justify-center' },\n { orientation: 'horizontal', align: 'start', class: 'justify-start' },\n ],\n defaultVariants: {\n size: 'md',\n align: 'center',\n orientation: 'vertical',\n },\n});\n\n/**\n * CVA variants for the empty state icon container.\n *\n * @tokens `--color-muted`, `--color-muted-foreground`\n */\nexport const emptyStateIconVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'flex items-center justify-center shrink-0 bg-muted text-muted-foreground',\n {\n variants: {\n size: {\n sm: 'size-10 rounded-card',\n md: 'size-14 rounded-card',\n lg: 'size-20 rounded-card',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n\n/**\n * CVA variants for the empty state title.\n *\n * @tokens `--color-foreground`\n */\nexport const emptyStateTitleVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'font-heading tracking-tight text-foreground',\n {\n variants: {\n size: {\n sm: 'text-sm font-medium',\n md: 'text-base font-semibold',\n lg: 'text-lg font-semibold',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n\n/**\n * CVA variants for the empty state description.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const emptyStateDescriptionVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'text-muted-foreground',\n {\n variants: {\n size: {\n sm: 'text-xs max-w-[200px]',\n md: 'text-sm max-w-xs',\n lg: 'text-base max-w-sm',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n\n/**\n * CVA variants for the empty state actions container.\n */\nexport const emptyStateActionsVariants: (props?: { size?: EmptyStateSize }) => string = cva(\n 'flex flex-wrap items-center justify-center',\n {\n variants: {\n size: {\n sm: 'gap-2 pt-1',\n md: 'gap-2.5 pt-2',\n lg: 'gap-3 pt-3',\n },\n },\n defaultVariants: {\n size: 'md',\n },\n }\n);\n","import {\n ChangeDetectionStrategy,\n Component,\n computed,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport type { InputSignal, Signal } from '@angular/core';\nimport { mergeClasses } from 'ngx-com/utils';\nimport { emptyStateVariants } from './empty-state.variants';\nimport type { EmptyStateSize, EmptyStateAlign, EmptyStateOrientation } from './empty-state.variants';\n\n/**\n * Empty state component - a placeholder surface for when there is no data to display.\n *\n * Common use cases include:\n * - Empty lists or tables (\"No results found\")\n * - Initial states before user action (\"Create your first project\")\n * - Search results with no matches (\"No items match your search\")\n * - Error recovery states (\"Something went wrong. Try again.\")\n *\n * The component is a pure layout container that accepts projected content through attribute directives.\n *\n * @tokens `--color-muted`, `--color-muted-foreground`, `--color-foreground`\n *\n * @example Minimal empty state\n * ```html\n * <com-empty-state>\n * <div comEmptyStateIcon>\n * <com-icon name=\"inbox\" size=\"xl\" />\n * </div>\n * <h3 comEmptyStateTitle>No messages</h3>\n * </com-empty-state>\n * ```\n *\n * @example Full empty state with description and action\n * ```html\n * <com-empty-state>\n * <div comEmptyStateIcon>\n * <com-icon name=\"folder-open\" size=\"xl\" />\n * </div>\n * <h3 comEmptyStateTitle>No projects yet</h3>\n * <p comEmptyStateDescription>\n * Create your first project to get started organizing your work.\n * </p>\n * <div comEmptyStateActions>\n * <button comButton>Create Project</button>\n * </div>\n * </com-empty-state>\n * ```\n *\n * @example Search empty state with secondary action\n * ```html\n * <com-empty-state>\n * <div comEmptyStateIcon>\n * <com-icon name=\"search-x\" size=\"xl\" />\n * </div>\n * <h3 comEmptyStateTitle>No results found</h3>\n * <p comEmptyStateDescription>\n * Try adjusting your search terms or filters.\n * </p>\n * <div comEmptyStateActions>\n * <button comButton variant=\"outline\">Clear Filters</button>\n * <button comButton>New Search</button>\n * </div>\n * </com-empty-state>\n * ```\n *\n * @example Small size for inline contexts\n * ```html\n * <com-empty-state size=\"sm\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"list\" size=\"lg\" />\n * </div>\n * <h4 comEmptyStateTitle>No items</h4>\n * </com-empty-state>\n * ```\n *\n * @example Large size for full-page empty states\n * ```html\n * <com-empty-state size=\"lg\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"rocket\" size=\"2xl\" />\n * </div>\n * <h2 comEmptyStateTitle>Welcome to Acme</h2>\n * <p comEmptyStateDescription>\n * Your dashboard is ready. Start by creating your first resource.\n * </p>\n * <div comEmptyStateActions>\n * <button comButton size=\"lg\">Get Started</button>\n * </div>\n * </com-empty-state>\n * ```\n *\n * @example Horizontal orientation\n * ```html\n * <com-empty-state orientation=\"horizontal\" align=\"start\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"alert-circle\" size=\"lg\" />\n * </div>\n * <h4 comEmptyStateTitle>No notifications</h4>\n * <p comEmptyStateDescription>You're all caught up!</p>\n * </com-empty-state>\n * ```\n *\n * @example Left-aligned for sidebar contexts\n * ```html\n * <com-empty-state align=\"start\">\n * <div comEmptyStateIcon>\n * <com-icon name=\"users\" size=\"lg\" />\n * </div>\n * <h4 comEmptyStateTitle>No team members</h4>\n * <p comEmptyStateDescription>Invite people to collaborate.</p>\n * <div comEmptyStateActions>\n * <button comButton size=\"sm\">Invite</button>\n * </div>\n * </com-empty-state>\n * ```\n */\n@Component({\n selector: 'com-empty-state',\n exportAs: 'comEmptyState',\n template: `<ng-content />`,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyState {\n /** Controls overall scale: icon container size, text sizes, spacing. */\n readonly size: InputSignal<EmptyStateSize> = input<EmptyStateSize>('md');\n\n /** Horizontal alignment of content. */\n readonly align: InputSignal<EmptyStateAlign> = input<EmptyStateAlign>('center');\n\n /** Layout direction: vertical stacks content, horizontal places icon beside text. */\n readonly orientation: InputSignal<EmptyStateOrientation> = input<EmptyStateOrientation>('vertical');\n\n /** Consumer CSS classes - merged with variant classes. */\n readonly userClass: InputSignal<string> = input<string>('', { alias: 'class' });\n\n protected readonly computedClass: Signal<string> = computed(() =>\n mergeClasses(\n emptyStateVariants({\n size: this.size(),\n align: this.align(),\n orientation: this.orientation(),\n }),\n this.userClass()\n )\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateIconVariants } from './empty-state.variants';\n\n/**\n * Empty state icon container directive - styled circular background for icon/illustration.\n *\n * Apply to a container element. Place any content inside (typically `com-icon`).\n * Styling automatically adapts to the parent's `size` input.\n *\n * @example\n * ```html\n * <div comEmptyStateIcon>\n * <com-icon name=\"inbox\" size=\"xl\" />\n * </div>\n * ```\n *\n * @example With custom illustration\n * ```html\n * <div comEmptyStateIcon>\n * <img src=\"/assets/empty-mailbox.svg\" alt=\"\" class=\"size-8\" />\n * </div>\n * ```\n *\n * @tokens `--color-muted`, `--color-muted-foreground`\n */\n@Directive({\n selector: '[comEmptyStateIcon]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateIcon {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateIconVariants({ size: this.emptyState.size() })\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateTitleVariants } from './empty-state.variants';\n\n/**\n * Empty state title directive - styled heading text.\n *\n * Apply to any heading element. Consumer picks the semantic level (h2, h3, etc.).\n * Styling automatically adapts to the parent's `size` input.\n *\n * @example\n * ```html\n * <h3 comEmptyStateTitle>No projects yet</h3>\n * ```\n *\n * @tokens `--color-foreground`\n */\n@Directive({\n selector: '[comEmptyStateTitle]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateTitle {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateTitleVariants({ size: this.emptyState.size() })\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateDescriptionVariants } from './empty-state.variants';\n\n/**\n * Empty state description directive - supporting text.\n *\n * Apply to a paragraph or text element.\n * Styling automatically adapts to the parent's `size` input.\n *\n * @example\n * ```html\n * <p comEmptyStateDescription>\n * Create your first project to get started organizing your work.\n * </p>\n * ```\n *\n * @tokens `--color-muted-foreground`\n */\n@Directive({\n selector: '[comEmptyStateDescription]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateDescription {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateDescriptionVariants({ size: this.emptyState.size() })\n );\n}\n","import { computed, Directive, inject, type Signal } from '@angular/core';\nimport { ComEmptyState } from './empty-state.component';\nimport { emptyStateActionsVariants } from './empty-state.variants';\n\n/**\n * Empty state actions directive - container for action buttons.\n *\n * Apply to a container element. Place buttons inside.\n * Styling automatically adapts to the parent's `size` input.\n *\n * @tokens none\n *\n * @example Single action\n * ```html\n * <div comEmptyStateActions>\n * <button comButton>Create Project</button>\n * </div>\n * ```\n *\n * @example Multiple actions\n * ```html\n * <div comEmptyStateActions>\n * <button comButton variant=\"outline\">Clear Filters</button>\n * <button comButton>New Search</button>\n * </div>\n * ```\n */\n@Directive({\n selector: '[comEmptyStateActions]',\n host: {\n '[class]': 'computedClass()',\n },\n})\nexport class ComEmptyStateActions {\n private readonly emptyState = inject(ComEmptyState);\n\n protected readonly computedClass: Signal<string> = computed(() =>\n emptyStateActionsVariants({ size: this.emptyState.size() })\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAMA;;;;AAIG;AACI,MAAM,kBAAkB,GAIhB,GAAG,CAAC,MAAM,EAAE;AACzB,IAAA,QAAQ,EAAE;AACR,QAAA,WAAW,EAAE;AACX,YAAA,QAAQ,EAAE,UAAU;AACpB,YAAA,UAAU,EAAE,UAAU;AACvB,SAAA;AACD,QAAA,KAAK,EAAE;AACL,YAAA,MAAM,EAAE,0BAA0B;AAClC,YAAA,KAAK,EAAE,uBAAuB;AAC/B,SAAA;AACD,QAAA,IAAI,EAAE;AACJ,YAAA,EAAE,EAAE,YAAY;AAChB,YAAA,EAAE,EAAE,YAAY;AAChB,YAAA,EAAE,EAAE,aAAa;AAClB,SAAA;AACF,KAAA;AACD,IAAA,gBAAgB,EAAE;QAChB,EAAE,WAAW,EAAE,YAAY,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE,gBAAgB,EAAE;QACvE,EAAE,WAAW,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,EAAE,KAA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B;AAC7B,qBAAA;AACF,iBAAA;;;ACpBD;;;;;;;;;;;;;;;;;;;;;;AAsBG;MAOU,oBAAoB,CAAA;AACd,IAAA,UAAU,GAAG,MAAM,CAAC,aAAa,CAAC;IAEhC,aAAa,GAAmB,QAAQ,CAAC,MAC1D,yBAAyB,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE,EAAE,CAAC,yDAC5D;uGALU,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAApB,oBAAoB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,wBAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,OAAA,EAAA,iBAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAApB,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBANhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,wBAAwB;AAClC,oBAAA,IAAI,EAAE;AACJ,wBAAA,SAAS,EAAE,iBAAiB;AAC7B,qBAAA;AACF,iBAAA;;;AChCD;;AAEG;;;;"}
|
|
@@ -35,6 +35,8 @@ let nextId$3 = 0;
|
|
|
35
35
|
* The form field automatically associates this label with the inner control
|
|
36
36
|
* and positions it appropriately based on appearance and float state.
|
|
37
37
|
*
|
|
38
|
+
* @tokens none
|
|
39
|
+
*
|
|
38
40
|
* @example
|
|
39
41
|
* ```html
|
|
40
42
|
* <com-form-field>
|
|
@@ -93,7 +95,7 @@ const formFieldContainerVariants = cva([
|
|
|
93
95
|
'com-form-field__container',
|
|
94
96
|
'relative flex items-center',
|
|
95
97
|
'w-full min-h-11',
|
|
96
|
-
'transition-all duration-
|
|
98
|
+
'transition-all duration-normal',
|
|
97
99
|
'rounded-input',
|
|
98
100
|
], {
|
|
99
101
|
variants: {
|
|
@@ -160,7 +162,7 @@ const formFieldLabelVariants = cva([
|
|
|
160
162
|
'pointer-events-none',
|
|
161
163
|
'text-muted-foreground text-sm',
|
|
162
164
|
'origin-top-left',
|
|
163
|
-
'transition-all duration-
|
|
165
|
+
'transition-all duration-slow ease-in-out',
|
|
164
166
|
], {
|
|
165
167
|
variants: {
|
|
166
168
|
appearance: {
|
|
@@ -887,9 +889,12 @@ class ComFormField {
|
|
|
887
889
|
onContainerClick(event) {
|
|
888
890
|
this.control()?.onContainerClick(event);
|
|
889
891
|
}
|
|
892
|
+
onContainerActivate() {
|
|
893
|
+
this.control()?.onContainerClick(new MouseEvent('click'));
|
|
894
|
+
}
|
|
890
895
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: ComFormField, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
891
896
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: ComFormField, isStandalone: true, selector: "com-form-field", inputs: { appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, floatLabel: { classPropertyName: "floatLabel", publicName: "floatLabel", isSignal: true, isRequired: false, transformFunction: null }, hideRequiredMarker: { classPropertyName: "hideRequiredMarker", publicName: "hideRequiredMarker", isSignal: true, isRequired: false, transformFunction: null }, subscriptSizing: { classPropertyName: "subscriptSizing", publicName: "subscriptSizing", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "hostClasses()", "class.com-form-field--focused": "isFocused()", "class.com-form-field--disabled": "isDisabled()", "class.com-form-field--error": "hasError()", "class.com-form-field--floating": "shouldLabelFloat()", "class.com-form-field--has-label": "!!labelChild()" } }, queries: [{ propertyName: "control", first: true, predicate: FormFieldControl, descendants: true, isSignal: true }, { propertyName: "inputDirective", first: true, predicate: ComInput, descendants: true, isSignal: true }, { propertyName: "labelChild", first: true, predicate: ComLabel, descendants: true, isSignal: true }, { propertyName: "hintChildren", predicate: ComHint, isSignal: true }, { propertyName: "errorChildren", predicate: ComError, isSignal: true }, { propertyName: "prefixChild", first: true, predicate: ComPrefix, descendants: true, isSignal: true }, { propertyName: "suffixChild", first: true, predicate: ComSuffix, descendants: true, isSignal: true }], exportAs: ["comFormField"], ngImport: i0, template: `
|
|
892
|
-
<div [class]="containerClasses()" (click)="onContainerClick($event)">
|
|
897
|
+
<div [class]="containerClasses()" role="group" tabindex="-1" (click)="onContainerClick($event)" (keydown.enter)="onContainerActivate()">
|
|
893
898
|
<div class="flex items-center w-full">
|
|
894
899
|
@if (hasPrefix()) {
|
|
895
900
|
<ng-content select="[comPrefix]" />
|
|
@@ -920,12 +925,12 @@ class ComFormField {
|
|
|
920
925
|
<ng-content select="[comHint][align='end']" />
|
|
921
926
|
</div>
|
|
922
927
|
</div>
|
|
923
|
-
`, isInline: true, styles: ["com-form-field.com-form-field--has-label:not(.com-form-field--floating) input::placeholder,com-form-field.com-form-field--has-label:not(.com-form-field--floating) textarea::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-dropdown .text-placeholder{display:none}com-form-field com-dropdown{display:block;width:100%}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
928
|
+
`, isInline: true, styles: ["com-form-field.com-form-field--has-label:not(.com-form-field--floating) input::placeholder,com-form-field.com-form-field--has-label:not(.com-form-field--floating) textarea::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-dropdown .text-placeholder{display:none}com-form-field com-dropdown{display:block;width:100%}com-form-field com-datepicker{display:block;width:100%}com-form-field com-date-range-picker{display:block;width:100%}com-form-field com-time-picker{display:block;width:100%}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-datepicker input::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-date-range-picker input::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-time-picker span[aria-hidden],com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-time-picker button{visibility:hidden}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
924
929
|
}
|
|
925
930
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: ComFormField, decorators: [{
|
|
926
931
|
type: Component,
|
|
927
932
|
args: [{ selector: 'com-form-field', exportAs: 'comFormField', template: `
|
|
928
|
-
<div [class]="containerClasses()" (click)="onContainerClick($event)">
|
|
933
|
+
<div [class]="containerClasses()" role="group" tabindex="-1" (click)="onContainerClick($event)" (keydown.enter)="onContainerActivate()">
|
|
929
934
|
<div class="flex items-center w-full">
|
|
930
935
|
@if (hasPrefix()) {
|
|
931
936
|
<ng-content select="[comPrefix]" />
|
|
@@ -963,7 +968,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
|
|
|
963
968
|
'[class.com-form-field--error]': 'hasError()',
|
|
964
969
|
'[class.com-form-field--floating]': 'shouldLabelFloat()',
|
|
965
970
|
'[class.com-form-field--has-label]': '!!labelChild()',
|
|
966
|
-
}, styles: ["com-form-field.com-form-field--has-label:not(.com-form-field--floating) input::placeholder,com-form-field.com-form-field--has-label:not(.com-form-field--floating) textarea::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-dropdown .text-placeholder{display:none}com-form-field com-dropdown{display:block;width:100%}\n"] }]
|
|
971
|
+
}, styles: ["com-form-field.com-form-field--has-label:not(.com-form-field--floating) input::placeholder,com-form-field.com-form-field--has-label:not(.com-form-field--floating) textarea::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-dropdown .text-placeholder{display:none}com-form-field com-dropdown{display:block;width:100%}com-form-field com-datepicker{display:block;width:100%}com-form-field com-date-range-picker{display:block;width:100%}com-form-field com-time-picker{display:block;width:100%}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-datepicker input::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-date-range-picker input::placeholder{color:transparent}com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-time-picker span[aria-hidden],com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-time-picker button{visibility:hidden}\n"] }]
|
|
967
972
|
}], ctorParameters: () => [], propDecorators: { control: [{ type: i0.ContentChild, args: [i0.forwardRef(() => FormFieldControl), { isSignal: true }] }], inputDirective: [{ type: i0.ContentChild, args: [i0.forwardRef(() => ComInput), { isSignal: true }] }], labelChild: [{ type: i0.ContentChild, args: [i0.forwardRef(() => ComLabel), { isSignal: true }] }], hintChildren: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => ComHint), { isSignal: true }] }], errorChildren: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => ComError), { isSignal: true }] }], prefixChild: [{ type: i0.ContentChild, args: [i0.forwardRef(() => ComPrefix), { isSignal: true }] }], suffixChild: [{ type: i0.ContentChild, args: [i0.forwardRef(() => ComSuffix), { isSignal: true }] }], appearance: [{ type: i0.Input, args: [{ isSignal: true, alias: "appearance", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], floatLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "floatLabel", required: false }] }], hideRequiredMarker: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideRequiredMarker", required: false }] }], subscriptSizing: [{ type: i0.Input, args: [{ isSignal: true, alias: "subscriptSizing", required: false }] }], userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
968
973
|
|
|
969
974
|
// Public API for the form-field component
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-com-components-form-field.mjs","sources":["../../../projects/com/components/form-field/form-field-control.ts","../../../projects/com/components/form-field/label.directive.ts","../../../projects/com/components/form-field/form-field.variants.ts","../../../projects/com/components/form-field/hint.directive.ts","../../../projects/com/components/form-field/error.directive.ts","../../../projects/com/components/form-field/prefix.directive.ts","../../../projects/com/components/form-field/suffix.directive.ts","../../../projects/com/components/form-field/error-state-matcher.ts","../../../projects/com/components/form-field/input.directive.ts","../../../projects/com/components/form-field/form-field-defaults.ts","../../../projects/com/components/form-field/form-field.component.ts","../../../projects/com/components/form-field/index.ts","../../../projects/com/components/form-field/ngx-com-components-form-field.ts"],"sourcesContent":["import type { Signal } from '@angular/core';\nimport type { NgControl } from '@angular/forms';\n\n\n/**\n * Contract that any control inside a form field must implement.\n *\n * This allows the form field to read state from any inner control\n * (input, textarea, custom controls) without knowing implementation details.\n *\n * @example Implementing for a custom phone input\n * ```ts\n * @Directive({\n * selector: 'com-phone-input',\n * providers: [{ provide: FormFieldControl, useExisting: PhoneInputComponent }],\n * })\n * export class PhoneInputComponent extends FormFieldControl<string> {\n * // ... implement all abstract members\n * }\n * ```\n */\nexport abstract class FormFieldControl<T = unknown> {\n /** The NgControl bound to this control (if any). */\n abstract readonly ngControl: NgControl | null;\n\n /** Whether the control is focused. */\n abstract readonly focused: Signal<boolean>;\n\n /** Whether the label should float (focused or non-empty). */\n abstract readonly shouldLabelFloat: Signal<boolean>;\n\n /** Whether the control is required. */\n abstract readonly required: Signal<boolean>;\n\n /** Whether the control is disabled. */\n abstract readonly disabled: Signal<boolean>;\n\n /** Whether the control is in an error state. */\n abstract readonly errorState: Signal<boolean>;\n\n /** Unique ID for the control element. */\n abstract readonly id: Signal<string>;\n\n /** Structured validation errors (Signal Forms path). */\n readonly errors?: Signal<readonly unknown[] | null>;\n\n /** Called when the form field container is clicked. */\n abstract onContainerClick(event: MouseEvent): void;\n}\n","import { Directive, signal } from '@angular/core';\nimport type { Signal } from '@angular/core';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive to mark the label element inside a form field.\n *\n * The form field automatically associates this label with the inner control\n * and positions it appropriately based on appearance and float state.\n *\n * @example\n * ```html\n * <com-form-field>\n * <label comLabel>Email address</label>\n * <input comInput formControlName=\"email\" />\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comLabel]',\n exportAs: 'comLabel',\n host: {\n '[attr.for]': 'forId()',\n '[id]': 'labelId',\n },\n})\nexport class ComLabel {\n readonly labelId: string = `com-label-${nextId++}`;\n\n private readonly _forId = signal<string | null>(null);\n readonly forId: Signal<string | null> = this._forId.asReadonly();\n\n /** Sets the `for` attribute to link to the control. Called by form field. */\n setForId(id: string): void {\n this._forId.set(id);\n }\n}\n","import { cva } from 'class-variance-authority';\nimport type { VariantProps } from 'class-variance-authority';\n\nexport type FormFieldAppearance = 'fill' | 'outline';\nexport type FormFieldColor = 'primary' | 'accent' | 'warn';\nexport type FormFieldFloatLabel = 'auto' | 'always';\nexport type FormFieldSubscriptSizing = 'fixed' | 'dynamic';\n\n/**\n * CVA variants for the form field wrapper.\n *\n * @tokens `--color-foreground`\n */\nexport const formFieldVariants: (props?: {\n disabled?: boolean | null | undefined;\n}) => string = cva(\n ['com-form-field', 'relative block w-full', 'text-foreground'],\n {\n variants: {\n disabled: {\n true: 'pointer-events-none',\n false: '',\n },\n },\n defaultVariants: {\n disabled: false,\n },\n }\n);\n\nexport type FormFieldVariants = VariantProps<typeof formFieldVariants>;\n\n/**\n * CVA variants for the input container (the bordered/filled area).\n *\n * @tokens `--color-input-border`, `--color-input-background`, `--color-primary`,\n * `--color-accent`, `--color-warn`, `--color-ring`, `--color-muted`,\n * `--color-disabled`, `--radius-input`\n */\nexport const formFieldContainerVariants: (props?: {\n appearance?: FormFieldAppearance | null | undefined;\n color?: FormFieldColor | null | undefined;\n focused?: boolean | null | undefined;\n error?: boolean | null | undefined;\n disabled?: boolean | null | undefined;\n}) => string = cva(\n [\n 'com-form-field__container',\n 'relative flex items-center',\n 'w-full min-h-11',\n 'transition-all duration-150',\n 'rounded-input',\n ],\n {\n variants: {\n appearance: {\n outline: [\n 'border border-input-border',\n 'bg-transparent',\n 'mt-2.5', // Reserve space for floating label to prevent height jump\n ],\n fill: [\n 'rounded-b-none',\n 'bg-muted',\n 'border-b-2 border-input-border',\n ],\n },\n color: {\n primary: '',\n accent: '',\n warn: '',\n },\n focused: {\n true: '',\n false: '',\n },\n error: {\n true: '',\n false: '',\n },\n disabled: {\n true: 'bg-disabled border-disabled',\n false: '',\n },\n },\n compoundVariants: [\n // Outline + focused (no error)\n { appearance: 'outline', focused: true, error: false, class: 'border-primary ring-1 ring-primary' },\n { appearance: 'outline', focused: true, error: false, color: 'accent', class: 'border-accent ring-accent' },\n { appearance: 'outline', focused: true, error: false, color: 'warn', class: 'border-warn ring-warn' },\n // Outline + error\n { appearance: 'outline', error: true, class: 'border-warn ring-1 ring-warn' },\n // Fill + focused (no error)\n { appearance: 'fill', focused: true, error: false, class: 'border-b-primary' },\n { appearance: 'fill', focused: true, error: false, color: 'accent', class: 'border-b-accent' },\n { appearance: 'fill', focused: true, error: false, color: 'warn', class: 'border-b-warn' },\n // Fill + error\n { appearance: 'fill', error: true, class: 'border-b-warn' },\n ],\n defaultVariants: {\n appearance: 'outline',\n color: 'primary',\n focused: false,\n error: false,\n disabled: false,\n },\n }\n);\n\nexport type FormFieldContainerVariants = VariantProps<typeof formFieldContainerVariants>;\n\n/**\n * CVA variants for the floating label.\n *\n * @tokens `--color-muted-foreground`, `--color-primary`, `--color-accent`,\n * `--color-warn`, `--color-background`\n */\nexport const formFieldLabelVariants: (props?: {\n appearance?: FormFieldAppearance | null | undefined;\n floating?: boolean | null | undefined;\n color?: FormFieldColor | null | undefined;\n error?: boolean | null | undefined;\n focused?: boolean | null | undefined;\n disabled?: boolean | null | undefined;\n}) => string = cva(\n [\n 'com-form-field__label',\n 'pointer-events-none',\n 'text-muted-foreground text-sm',\n 'origin-top-left',\n 'transition-all duration-200 ease-in-out',\n ],\n {\n variants: {\n appearance: {\n outline: '',\n fill: '',\n },\n floating: {\n // Floating: absolute positioning at container border\n true: 'absolute',\n // Not floating: relative positioning in flex flow (after prefix)\n false: 'relative flex-shrink-0 pl-3',\n },\n color: {\n primary: '',\n accent: '',\n warn: '',\n },\n error: {\n true: 'text-warn',\n false: '',\n },\n focused: {\n true: '',\n false: '',\n },\n disabled: {\n true: 'text-disabled-foreground',\n false: '',\n },\n },\n compoundVariants: [\n // Outline floating (label above border with notch effect)\n {\n appearance: 'outline',\n floating: true,\n class: 'left-2 -top-2.5 scale-75 bg-background px-1',\n },\n // Fill floating\n {\n appearance: 'fill',\n floating: true,\n class: 'left-3 top-1 scale-75 text-xs',\n },\n // Focused + floating colors (no error)\n { floating: true, focused: true, error: false, color: 'primary', class: 'text-primary' },\n { floating: true, focused: true, error: false, color: 'accent', class: 'text-accent' },\n { floating: true, focused: true, error: false, color: 'warn', class: 'text-warn' },\n // Error overrides\n { floating: true, error: true, class: 'text-warn' },\n ],\n defaultVariants: {\n appearance: 'outline',\n floating: false,\n color: 'primary',\n error: false,\n focused: false,\n disabled: false,\n },\n }\n);\n\nexport type FormFieldLabelVariants = VariantProps<typeof formFieldLabelVariants>;\n\n/**\n * CVA variants for the subscript area (hints/errors).\n *\n * @tokens (inherits from children)\n */\nexport const formFieldSubscriptVariants: (props?: {\n sizing?: FormFieldSubscriptSizing | null | undefined;\n}) => string = cva(\n ['com-form-field__subscript', 'text-xs mt-1 px-3'],\n {\n variants: {\n sizing: {\n fixed: 'min-h-5',\n dynamic: 'min-h-0',\n },\n },\n defaultVariants: {\n sizing: 'fixed',\n },\n }\n);\n\nexport type FormFieldSubscriptVariants = VariantProps<typeof formFieldSubscriptVariants>;\n\n/**\n * CVA variants for hint text.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const hintVariants: () => string = cva(['com-form-field__hint', 'text-muted-foreground text-xs']);\n\n/**\n * CVA variants for error messages.\n *\n * @tokens `--color-warn`\n */\nexport const errorVariants: () => string = cva(['com-form-field__error', 'text-warn text-xs']);\n\n/**\n * CVA variants for prefix slot.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const prefixVariants: () => string = cva([\n 'com-form-field__prefix',\n 'flex items-center text-muted-foreground pl-3',\n]);\n\n/**\n * CVA variants for suffix slot.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const suffixVariants: () => string = cva([\n 'com-form-field__suffix',\n 'flex items-center text-muted-foreground pr-3',\n]);\n","import { computed, Directive, input } from '@angular/core';\nimport type { InputSignal, Signal } from '@angular/core';\nimport { hintVariants } from './form-field.variants';\nimport { mergeClasses } from 'ngx-com/utils';\n\n/** Alignment of hint text in the subscript area. */\nexport type HintAlign = 'start' | 'end';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive for hint text displayed below the form field.\n *\n * The hint provides supplementary information to help users fill out the field.\n * It is automatically added to the control's `aria-describedby`.\n *\n * @tokens `--color-muted-foreground`\n *\n * @example Basic hint\n * ```html\n * <com-form-field>\n * <label comLabel>Password</label>\n * <input comInput formControlName=\"password\" />\n * <span comHint>At least 8 characters</span>\n * </com-form-field>\n * ```\n *\n * @example Right-aligned hint (e.g., character count)\n * ```html\n * <com-form-field>\n * <label comLabel>Bio</label>\n * <textarea comInput formControlName=\"bio\"></textarea>\n * <span comHint>Keep it brief</span>\n * <span comHint align=\"end\">{{ bioLength }}/150</span>\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comHint]',\n exportAs: 'comHint',\n host: {\n '[id]': 'id',\n '[class]': 'hostClasses()',\n },\n})\nexport class ComHint {\n readonly id: string = `com-hint-${nextId++}`;\n readonly align: InputSignal<HintAlign> = input<HintAlign>('start');\n\n protected readonly hostClasses: Signal<string> = computed(() =>\n mergeClasses(hintVariants(), this.align() === 'end' && 'ml-auto')\n );\n}\n","import { computed, Directive, input, signal } from '@angular/core';\nimport type { AbstractControl } from '@angular/forms';\nimport type { InputSignal, Signal, WritableSignal } from '@angular/core';\nimport { errorVariants } from './form-field.variants';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive for error messages displayed below the form field.\n *\n * Errors replace hints when the control is in an error state.\n * Uses `role=\"alert\"` and `aria-live=\"polite\"` for screen reader announcement.\n *\n * The optional `match` input allows showing errors only for specific validation errors.\n *\n * @tokens `--color-warn`\n *\n * @example Basic error\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" />\n * <span comError>Please enter a valid email</span>\n * </com-form-field>\n * ```\n *\n * @example Matching specific errors\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" />\n * <span comError match=\"required\">Email is required.</span>\n * <span comError match=\"email\">Must be a valid email address.</span>\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comError]',\n exportAs: 'comError',\n host: {\n '[id]': 'id',\n '[class]': 'errorVariants()',\n '[class.hidden]': '!shouldShow()',\n 'role': 'alert',\n 'aria-live': 'polite',\n },\n})\nexport class ComError {\n readonly id: string = `com-error-${nextId++}`;\n\n /** Reference to the form control (Reactive Forms path). */\n private readonly _control: WritableSignal<AbstractControl | null> = signal(null);\n\n /** Structured errors from Signal Forms. */\n private readonly _signalErrors: WritableSignal<readonly unknown[]> = signal([]);\n\n /**\n * Show this error only when a specific validation error key is present.\n * If empty, the error is always shown when the control is in error state.\n */\n readonly match: InputSignal<string> = input<string>('');\n\n protected readonly errorVariants: () => string = errorVariants;\n\n /**\n * Whether this error should be displayed based on the match condition.\n * Used by the form field to filter which errors to show.\n */\n readonly shouldShow: Signal<boolean> = computed(() => {\n const matchKey = this.match();\n if (!matchKey) return true;\n\n // Signal Forms path: match on error.kind\n const signalErrors = this._signalErrors();\n if (signalErrors.length > 0) {\n return signalErrors.some((e) => (e as { kind?: string })?.kind === matchKey);\n }\n\n // Reactive Forms path: match on AbstractControl.errors keys\n const errors = this._control()?.errors;\n return errors ? matchKey in errors : false;\n });\n\n /**\n * Sets the form control reference (Reactive Forms).\n * Called by the parent form field component.\n */\n setControl(control: AbstractControl | null): void {\n this._control.set(control);\n }\n\n /**\n * Sets structured validation errors (Signal Forms).\n * Called by the parent form field component.\n */\n setSignalErrors(errors: readonly unknown[]): void {\n this._signalErrors.set(errors);\n }\n}\n","import { Directive } from '@angular/core';\nimport { prefixVariants } from './form-field.variants';\n\n/**\n * Directive to mark content as the prefix slot in a form field.\n *\n * Prefix content appears before the input (e.g., currency symbol, icon).\n *\n * @tokens `--color-muted-foreground`\n *\n * @example Currency prefix\n * ```html\n * <com-form-field>\n * <label comLabel>Amount</label>\n * <span comPrefix>$</span>\n * <input comInput type=\"number\" formControlName=\"amount\" />\n * </com-form-field>\n * ```\n *\n * @example Icon prefix\n * ```html\n * <com-form-field>\n * <label comLabel>Search</label>\n * <svg comPrefix class=\"size-4\">...</svg>\n * <input comInput formControlName=\"query\" />\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comPrefix]',\n exportAs: 'comPrefix',\n host: {\n '[class]': 'prefixVariants()',\n },\n})\nexport class ComPrefix {\n protected readonly prefixVariants: () => string = prefixVariants;\n}\n","import { Directive } from '@angular/core';\nimport { suffixVariants } from './form-field.variants';\n\n/**\n * Directive to mark content as the suffix slot in a form field.\n *\n * Suffix content appears after the input (e.g., unit, clear button, visibility toggle).\n *\n * @tokens `--color-muted-foreground`\n *\n * @example Unit suffix\n * ```html\n * <com-form-field>\n * <label comLabel>Weight</label>\n * <input comInput type=\"number\" formControlName=\"weight\" />\n * <span comSuffix>kg</span>\n * </com-form-field>\n * ```\n *\n * @example Clear button suffix\n * ```html\n * <com-form-field>\n * <label comLabel>Search</label>\n * <input comInput formControlName=\"query\" />\n * <button comSuffix type=\"button\" (click)=\"clearSearch()\">\n * <svg class=\"size-4\">...</svg>\n * </button>\n * </com-form-field>\n * ```\n *\n * @example Password visibility toggle\n * ```html\n * <com-form-field>\n * <label comLabel>Password</label>\n * <input comInput [type]=\"showPassword ? 'text' : 'password'\" formControlName=\"password\" />\n * <button comSuffix type=\"button\" (click)=\"showPassword = !showPassword\">\n * <svg class=\"size-4\">...</svg>\n * </button>\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comSuffix]',\n exportAs: 'comSuffix',\n host: {\n '[class]': 'suffixVariants()',\n },\n})\nexport class ComSuffix {\n protected readonly suffixVariants: () => string = suffixVariants;\n}\n","import { Injectable } from '@angular/core';\nimport type { AbstractControl, FormGroupDirective, NgForm } from '@angular/forms';\n\n/**\n * Strategy for determining when to display errors in a form field.\n *\n * The default behavior shows errors when the control is invalid AND\n * either touched OR the parent form has been submitted.\n *\n * @example Override globally with eager error display\n * ```ts\n * @Injectable()\n * export class EagerErrorStateMatcher extends ErrorStateMatcher {\n * override isErrorState(control: AbstractControl | null): boolean {\n * return !!(control?.invalid && control.dirty);\n * }\n * }\n *\n * // In app config\n * providers: [{ provide: ErrorStateMatcher, useClass: EagerErrorStateMatcher }]\n * ```\n *\n * @example Per-field override\n * ```html\n * <com-form-field>\n * <input comInput [errorStateMatcher]=\"eagerMatcher\" />\n * </com-form-field>\n * ```\n */\n@Injectable({ providedIn: 'root' })\nexport class ErrorStateMatcher {\n isErrorState(\n control: AbstractControl | null,\n form: FormGroupDirective | NgForm | null\n ): boolean {\n return !!(control?.invalid && (control.touched || form?.submitted));\n }\n}\n","import {\n booleanAttribute,\n computed,\n DestroyRef,\n Directive,\n ElementRef,\n forwardRef,\n inject,\n input,\n signal,\n} from '@angular/core';\nimport type { DoCheck, InputSignal, InputSignalWithTransform, OnInit, Signal, WritableSignal } from '@angular/core';\n\nimport { FormGroupDirective, NgControl, NgForm } from '@angular/forms';\nimport { AutofillMonitor } from '@angular/cdk/text-field';\nimport { FormFieldControl } from './form-field-control';\nimport { ErrorStateMatcher } from './error-state-matcher';\nimport type { FormFieldAppearance } from './form-field-defaults';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive applied to native `<input>` and `<textarea>` elements to bridge\n * them to the form field wrapper. Implements the `FormFieldControl` contract.\n *\n * This directive does NOT implement `ControlValueAccessor` - it relies on\n * Angular's built-in value accessors (`DefaultValueAccessor`, `NumberValueAccessor`, etc.)\n * that are already applied to native elements with `formControlName` or `ngModel`.\n *\n * Instead, this directive reports state (focused, empty, disabled, error) to the\n * parent form field for proper visual presentation.\n *\n * @tokens (styling is controlled by the parent form field)\n *\n * @example Basic usage\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" placeholder=\"you@example.com\" />\n * </com-form-field>\n * ```\n *\n * @example Textarea\n * ```html\n * <com-form-field>\n * <label comLabel>Description</label>\n * <textarea comInput formControlName=\"description\"></textarea>\n * </com-form-field>\n * ```\n *\n * @example Custom error state matcher\n * ```html\n * <com-form-field>\n * <label comLabel>Code</label>\n * <input comInput formControlName=\"code\" [errorStateMatcher]=\"eagerMatcher\" />\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: 'input[comInput], textarea[comInput]',\n exportAs: 'comInput',\n providers: [{ provide: FormFieldControl, useExisting: forwardRef(() => ComInput) }],\n host: {\n '[id]': 'id()',\n '[disabled]': 'disabled()',\n '[required]': 'required()',\n '[attr.aria-invalid]': 'errorState() || null',\n '[attr.aria-required]': 'required() || null',\n '[attr.aria-describedby]': 'ariaDescribedBy() || null',\n '[class]': 'hostClasses()',\n '(focus)': 'onFocus()',\n '(blur)': 'onBlur()',\n '(input)': 'onInput()',\n },\n})\nexport class ComInput implements FormFieldControl<string>, OnInit, DoCheck {\n private readonly elementRef: ElementRef<HTMLInputElement | HTMLTextAreaElement> = inject(ElementRef);\n private readonly destroyRef = inject(DestroyRef);\n private readonly autofillMonitor = inject(AutofillMonitor);\n private readonly defaultErrorStateMatcher = inject(ErrorStateMatcher);\n private readonly parentForm = inject(NgForm, { optional: true });\n private readonly parentFormGroup = inject(FormGroupDirective, { optional: true });\n\n /** NgControl bound to this input (if using reactive forms). */\n readonly ngControl: NgControl | null = inject(NgControl, { optional: true, self: true });\n\n // Inputs\n readonly inputId: InputSignal<string | undefined> = input<string>(undefined, { alias: 'id' });\n readonly inputDisabled: InputSignalWithTransform<boolean, unknown> = input(false, {\n alias: 'disabled',\n transform: booleanAttribute,\n });\n readonly inputRequired: InputSignalWithTransform<boolean, unknown> = input(false, {\n alias: 'required',\n transform: booleanAttribute,\n });\n readonly userAriaDescribedBy: InputSignal<string> = input<string>('', { alias: 'aria-describedby' });\n readonly errorStateMatcher: InputSignal<ErrorStateMatcher | undefined> = input<ErrorStateMatcher>();\n\n // Signal Forms inputs — set automatically by [formField] via setInputOnDirectives\n readonly sfInvalid: InputSignal<boolean> = input(false, { alias: 'invalid' });\n readonly sfTouched: InputSignalWithTransform<boolean, unknown> = input(false, {\n alias: 'touched',\n transform: booleanAttribute,\n });\n readonly sfErrors: InputSignal<readonly unknown[]> = input<readonly unknown[]>([], {\n alias: 'errors',\n });\n\n /** Whether the form system is Signal Forms (no NgControl present). */\n private readonly isSignalForms: boolean = !this.ngControl;\n\n // Internal state\n private readonly _focused = signal(false);\n private readonly _autofilled = signal(false);\n private readonly _empty = signal(true);\n private readonly _uniqueId: string = `com-input-${nextId++}`;\n private readonly _appearance: WritableSignal<FormFieldAppearance> = signal<FormFieldAppearance>('outline');\n private _previousNativeValue: string = '';\n\n // Public signals implementing FormFieldControl\n readonly focused: Signal<boolean> = this._focused.asReadonly();\n\n readonly id: Signal<string> = computed(() => this.inputId() ?? this._uniqueId);\n\n readonly shouldLabelFloat: Signal<boolean> = computed(() => {\n return this._focused() || !this._empty() || this._autofilled();\n });\n\n readonly disabled: Signal<boolean> = computed(() => {\n if (this.inputDisabled()) return true;\n return this.ngControl?.control?.disabled ?? false;\n });\n\n readonly required: Signal<boolean> = computed(() => {\n if (this.inputRequired()) return true;\n const control = this.ngControl?.control;\n if (control?.validator) {\n const result = control.validator({ value: '' } as never);\n return result?.['required'] !== undefined;\n }\n return false;\n });\n\n readonly errorState: Signal<boolean> = computed(() => {\n if (this.isSignalForms) {\n // Signal Forms: gate on both invalid AND touched — mirrors ErrorStateMatcher default.\n // Signal Forms' invalid is pure validation state (not gated by touched).\n return this.sfInvalid() && this.sfTouched();\n }\n // Reactive Forms: use ErrorStateMatcher (existing logic)\n this._focused();\n this._empty();\n const matcher = this.errorStateMatcher() ?? this.defaultErrorStateMatcher;\n const form = this.parentFormGroup ?? this.parentForm;\n return matcher.isErrorState(this.ngControl?.control ?? null, form);\n });\n\n /** Structured validation errors from Signal Forms, exposed for the parent form field. */\n readonly errors: Signal<readonly unknown[] | null> = computed(() =>\n this.isSignalForms ? this.sfErrors() : null\n );\n\n /** Combined aria-describedby including user-provided and form-field-generated IDs. */\n private readonly _describedByIds = signal('');\n\n readonly ariaDescribedBy: Signal<string> = computed(() => {\n const userIds = this.userAriaDescribedBy();\n const fieldIds = this._describedByIds();\n return [userIds, fieldIds].filter(Boolean).join(' ');\n });\n\n /** Computed host classes including appearance-based padding. */\n protected readonly hostClasses: Signal<string> = computed(() => {\n const base =\n 'peer w-full bg-transparent text-foreground placeholder:text-input-placeholder outline-none border-none disabled:cursor-not-allowed disabled:text-disabled-foreground px-3';\n const padding = this._appearance() === 'fill' ? 'pt-5 pb-1.5' : 'py-2.5';\n return `${base} ${padding}`;\n });\n\n ngOnInit(): void {\n this._previousNativeValue = this.elementRef.nativeElement.value;\n this.updateEmpty();\n\n const autofillSub = this.autofillMonitor.monitor(this.elementRef).subscribe((event) => {\n this._autofilled.set(event.isAutofilled);\n });\n\n this.destroyRef.onDestroy(() => {\n autofillSub.unsubscribe();\n this.autofillMonitor.stopMonitoring(this.elementRef);\n });\n }\n\n ngDoCheck(): void {\n this.dirtyCheckNativeValue();\n }\n\n private dirtyCheckNativeValue(): void {\n const newValue = this.elementRef.nativeElement.value;\n if (this._previousNativeValue !== newValue) {\n this._previousNativeValue = newValue;\n this.updateEmpty();\n }\n }\n\n protected onFocus(): void {\n this._focused.set(true);\n }\n\n protected onBlur(): void {\n this._focused.set(false);\n }\n\n protected onInput(): void {\n this.updateEmpty();\n }\n\n private updateEmpty(): void {\n this._empty.set(!this.elementRef.nativeElement.value);\n }\n\n // FormFieldControl methods\n onContainerClick(event: MouseEvent): void {\n if (!this.disabled() && event.target !== this.elementRef.nativeElement) {\n this.elementRef.nativeElement.focus();\n }\n }\n\n /**\n * Sets the describedBy IDs from the form field.\n * Called by the parent form field component.\n */\n setDescribedByIds(ids: string): void {\n this._describedByIds.set(ids);\n }\n\n /**\n * Sets the appearance for styling.\n * Called by the parent form field component.\n */\n setAppearance(appearance: FormFieldAppearance): void {\n this._appearance.set(appearance);\n }\n\n /** Focus the native element. */\n focus(): void {\n this.elementRef.nativeElement.focus();\n }\n}\n","import { InjectionToken } from '@angular/core';\nimport type {\n FormFieldAppearance,\n FormFieldColor,\n FormFieldFloatLabel,\n FormFieldSubscriptSizing,\n} from './form-field.variants';\n\n// Re-export types for convenience\nexport type { FormFieldAppearance, FormFieldColor, FormFieldFloatLabel, FormFieldSubscriptSizing };\n\n/**\n * Global configuration defaults for form fields.\n *\n * @example Set defaults in app config\n * ```ts\n * providers: [\n * {\n * provide: FORM_FIELD_DEFAULTS,\n * useValue: {\n * appearance: 'fill',\n * floatLabel: 'always',\n * color: 'primary',\n * }\n * }\n * ]\n * ```\n */\nexport interface FormFieldDefaults {\n appearance?: FormFieldAppearance;\n color?: FormFieldColor;\n floatLabel?: FormFieldFloatLabel;\n hideRequiredMarker?: boolean;\n subscriptSizing?: FormFieldSubscriptSizing;\n}\n\nexport const FORM_FIELD_DEFAULTS: InjectionToken<FormFieldDefaults> = new InjectionToken<FormFieldDefaults>(\n 'FORM_FIELD_DEFAULTS',\n {\n providedIn: 'root',\n factory: (): FormFieldDefaults => ({}),\n }\n);\n","import {\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n computed,\n contentChild,\n contentChildren,\n effect,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport type { InputSignal, InputSignalWithTransform, Signal } from '@angular/core';\nimport { FormFieldControl } from './form-field-control';\nimport { ComLabel } from './label.directive';\nimport { ComHint } from './hint.directive';\nimport { ComError } from './error.directive';\nimport { ComPrefix } from './prefix.directive';\nimport { ComSuffix } from './suffix.directive';\nimport { ComInput } from './input.directive';\nimport {\n FORM_FIELD_DEFAULTS,\n type FormFieldAppearance,\n type FormFieldColor,\n type FormFieldFloatLabel,\n type FormFieldSubscriptSizing,\n} from './form-field-defaults';\nimport {\n formFieldVariants,\n formFieldContainerVariants,\n formFieldLabelVariants,\n formFieldSubscriptVariants,\n} from './form-field.variants';\nimport { mergeClasses } from 'ngx-com/utils';\n\n/**\n * Form field wrapper providing visual structure for form inputs.\n *\n * Provides floating labels, borders (outline/fill appearance), hints, errors,\n * and prefix/suffix slots. Automatically wires ARIA attributes for accessibility.\n *\n * The form field reads state from its inner `FormFieldControl` child (typically\n * a `ComInput` directive) and renders UI accordingly.\n *\n * @tokens `--color-foreground`, `--color-input-border`, `--color-input-background`,\n * `--color-primary`, `--color-accent`, `--color-warn`, `--color-ring`,\n * `--color-muted`, `--color-muted-foreground`, `--color-disabled`,\n * `--color-disabled-foreground`, `--color-background`, `--radius-input`\n *\n * @example Basic outline field\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" />\n * <span comHint>We'll never share your email.</span>\n * <span comError match=\"required\">Email is required.</span>\n * </com-form-field>\n * ```\n *\n * @example Fill appearance\n * ```html\n * <com-form-field appearance=\"fill\">\n * <label comLabel>Username</label>\n * <input comInput formControlName=\"username\" />\n * </com-form-field>\n * ```\n *\n * @example With prefix and suffix\n * ```html\n * <com-form-field>\n * <label comLabel>Amount</label>\n * <span comPrefix>$</span>\n * <input comInput type=\"number\" formControlName=\"amount\" />\n * <span comSuffix>.00</span>\n * </com-form-field>\n * ```\n */\n@Component({\n selector: 'com-form-field',\n exportAs: 'comFormField',\n template: `\n <div [class]=\"containerClasses()\" (click)=\"onContainerClick($event)\">\n <div class=\"flex items-center w-full\">\n @if (hasPrefix()) {\n <ng-content select=\"[comPrefix]\" />\n }\n @if (labelChild()) {\n <span [class]=\"labelClasses()\">\n <ng-content select=\"[comLabel]\" />\n @if (showRequiredMarker()) {\n <span class=\"text-warn\" aria-hidden=\"true\"> *</span>\n }\n </span>\n }\n <div class=\"flex-1 min-w-0\">\n <ng-content />\n </div>\n @if (hasSuffix()) {\n <ng-content select=\"[comSuffix]\" />\n }\n </div>\n </div>\n\n <div [class]=\"subscriptClasses()\">\n <div [class.hidden]=\"!showErrors()\">\n <ng-content select=\"[comError]\" />\n </div>\n <div [class.hidden]=\"showErrors()\" class=\"flex justify-between w-full gap-2\">\n <ng-content select=\"[comHint]:not([align='end'])\" />\n <ng-content select=\"[comHint][align='end']\" />\n </div>\n </div>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n styles: `\n /* Hide placeholder when label exists and is not floating (label acts as placeholder) */\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) input::placeholder,\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) textarea::placeholder {\n color: transparent;\n }\n\n /* Hide dropdown placeholder when label exists and is not floating */\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-dropdown .text-placeholder {\n display: none;\n }\n\n /* Make dropdown fill available space inside form-field */\n com-form-field com-dropdown {\n display: block;\n width: 100%;\n }\n `,\n host: {\n '[class]': 'hostClasses()',\n '[class.com-form-field--focused]': 'isFocused()',\n '[class.com-form-field--disabled]': 'isDisabled()',\n '[class.com-form-field--error]': 'hasError()',\n '[class.com-form-field--floating]': 'shouldLabelFloat()',\n '[class.com-form-field--has-label]': '!!labelChild()',\n },\n})\nexport class ComFormField {\n private readonly defaults = inject(FORM_FIELD_DEFAULTS, { optional: true });\n\n // Content children\n readonly control: Signal<FormFieldControl | undefined> = contentChild<FormFieldControl>(FormFieldControl);\n readonly inputDirective: Signal<ComInput | undefined> = contentChild<ComInput>(ComInput);\n readonly labelChild: Signal<ComLabel | undefined> = contentChild<ComLabel>(ComLabel);\n readonly hintChildren: Signal<readonly ComHint[]> = contentChildren<ComHint>(ComHint);\n readonly errorChildren: Signal<readonly ComError[]> = contentChildren<ComError>(ComError);\n readonly prefixChild: Signal<ComPrefix | undefined> = contentChild<ComPrefix>(ComPrefix);\n readonly suffixChild: Signal<ComSuffix | undefined> = contentChild<ComSuffix>(ComSuffix);\n\n // Inputs with defaults fallback\n readonly appearance: InputSignal<FormFieldAppearance> = input<FormFieldAppearance>(\n this.defaults?.appearance ?? 'outline'\n );\n readonly color: InputSignal<FormFieldColor> = input<FormFieldColor>(this.defaults?.color ?? 'primary');\n readonly floatLabel: InputSignal<FormFieldFloatLabel> = input<FormFieldFloatLabel>(\n this.defaults?.floatLabel ?? 'auto'\n );\n readonly hideRequiredMarker: InputSignalWithTransform<boolean, unknown> = input(\n this.defaults?.hideRequiredMarker ?? false,\n { transform: booleanAttribute }\n );\n readonly subscriptSizing: InputSignal<FormFieldSubscriptSizing> = input<FormFieldSubscriptSizing>(\n this.defaults?.subscriptSizing ?? 'fixed'\n );\n readonly userClass: InputSignal<string> = input<string>('', { alias: 'class' });\n\n // Derived state from inner control\n readonly shouldLabelFloat: Signal<boolean> = computed(() => {\n if (this.floatLabel() === 'always') return true;\n return this.control()?.shouldLabelFloat() ?? false;\n });\n\n readonly isFocused: Signal<boolean> = computed(() => this.control()?.focused() ?? false);\n readonly isDisabled: Signal<boolean> = computed(() => this.control()?.disabled() ?? false);\n readonly hasError: Signal<boolean> = computed(() => this.control()?.errorState() ?? false);\n readonly hasPrefix: Signal<boolean> = computed(() => !!this.prefixChild());\n readonly hasSuffix: Signal<boolean> = computed(() => !!this.suffixChild());\n\n readonly showRequiredMarker: Signal<boolean> = computed(() => {\n if (this.hideRequiredMarker()) return false;\n return this.control()?.required() ?? false;\n });\n\n readonly showErrors: Signal<boolean> = computed(() => this.hasError() && this.errorChildren().length > 0);\n\n // Computed classes\n protected readonly hostClasses: Signal<string> = computed(() =>\n mergeClasses(formFieldVariants({ disabled: this.isDisabled() }), this.userClass())\n );\n\n protected readonly containerClasses: Signal<string> = computed(() =>\n formFieldContainerVariants({\n appearance: this.appearance(),\n color: this.color(),\n focused: this.isFocused(),\n error: this.hasError(),\n disabled: this.isDisabled(),\n })\n );\n\n protected readonly labelClasses: Signal<string> = computed(() =>\n formFieldLabelVariants({\n appearance: this.appearance(),\n floating: this.shouldLabelFloat(),\n color: this.color(),\n error: this.hasError(),\n focused: this.isFocused(),\n disabled: this.isDisabled(),\n })\n );\n\n protected readonly subscriptClasses: Signal<string> = computed(() =>\n formFieldSubscriptVariants({ sizing: this.subscriptSizing() })\n );\n\n constructor() {\n // Wire up label to control\n effect(() => {\n const label = this.labelChild();\n const ctrl = this.control();\n if (label && ctrl) {\n label.setForId(ctrl.id());\n }\n });\n\n // Wire up aria-describedby on the control\n effect(() => {\n const ctrl = this.control();\n if (!ctrl || !('setDescribedByIds' in ctrl)) return;\n\n const ids = this.showErrors()\n ? this.errorChildren().filter((e) => e.shouldShow()).map((e) => e.id)\n : this.hintChildren().map((h) => h.id);\n (ctrl as { setDescribedByIds: (ids: string) => void }).setDescribedByIds(ids.join(' '));\n });\n\n // Wire up appearance to control for proper styling\n effect(() => {\n const ctrl = this.control();\n if (ctrl && 'setAppearance' in ctrl) {\n (ctrl as { setAppearance: (appearance: FormFieldAppearance) => void }).setAppearance(this.appearance());\n }\n });\n\n // Wire up control reference to error directives (re-runs on error state change)\n effect(() => {\n // Read hasError to trigger re-evaluation when validation state changes\n this.hasError();\n const ctrl = this.control();\n if (!ctrl) return;\n\n const errors = ctrl.errors?.() ?? null;\n if (errors !== null) {\n // Signal Forms path: pass structured errors to each comError\n this.errorChildren().forEach((error) => error.setSignalErrors(errors as readonly unknown[]));\n } else {\n // Reactive Forms path: pass AbstractControl reference\n const ngControl = ctrl.ngControl?.control ?? null;\n this.errorChildren().forEach((error) => error.setControl(ngControl));\n }\n });\n }\n\n protected onContainerClick(event: MouseEvent): void {\n this.control()?.onContainerClick(event);\n }\n}\n","// Public API for the form-field component\n\n// Main component\nexport { ComFormField } from './form-field.component';\n\n// Directives\nexport { ComInput } from './input.directive';\nexport { ComLabel } from './label.directive';\nexport { ComHint, type HintAlign } from './hint.directive';\nexport { ComError } from './error.directive';\nexport { ComPrefix } from './prefix.directive';\nexport { ComSuffix } from './suffix.directive';\n\n// Abstract class for custom controls\nexport { FormFieldControl } from './form-field-control';\n\n// Error state matching\nexport { ErrorStateMatcher } from './error-state-matcher';\n\n// Configuration\nexport {\n FORM_FIELD_DEFAULTS,\n type FormFieldDefaults,\n type FormFieldAppearance,\n type FormFieldColor,\n type FormFieldFloatLabel,\n type FormFieldSubscriptSizing,\n} from './form-field-defaults';\n\n// Variants (for advanced customization)\nexport {\n formFieldVariants,\n formFieldContainerVariants,\n formFieldLabelVariants,\n formFieldSubscriptVariants,\n hintVariants,\n errorVariants,\n prefixVariants,\n suffixVariants,\n type FormFieldVariants,\n type FormFieldContainerVariants,\n type FormFieldLabelVariants,\n type FormFieldSubscriptVariants,\n} from './form-field.variants';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["nextId"],"mappings":";;;;;;;AAIA;;;;;;;;;;;;;;;;AAgBG;MACmB,gBAAgB,CAAA;;AAuB3B,IAAA,MAAM;AAIhB;;AC7CD;AACA,IAAIA,QAAM,GAAG,CAAC;AAEd;;;;;;;;;;;;;AAaG;MASU,QAAQ,CAAA;AACV,IAAA,OAAO,GAAW,CAAA,UAAA,EAAaA,QAAM,EAAE,EAAE;AAEjC,IAAA,MAAM,GAAG,MAAM,CAAgB,IAAI,kDAAC;AAC5C,IAAA,KAAK,GAA0B,IAAI,CAAC,MAAM,CAAC,UAAU,EAAE;;AAGhE,IAAA,QAAQ,CAAC,EAAU,EAAA;AACjB,QAAA,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC;IACrB;uGATW,QAAQ,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAR,QAAQ,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,YAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,UAAA,EAAA,SAA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EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,OAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,UAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,YAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,kBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,oBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,SAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,OAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;ACxJzF;AAEA;;ACFA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"ngx-com-components-form-field.mjs","sources":["../../../projects/com/components/form-field/form-field-control.ts","../../../projects/com/components/form-field/label.directive.ts","../../../projects/com/components/form-field/form-field.variants.ts","../../../projects/com/components/form-field/hint.directive.ts","../../../projects/com/components/form-field/error.directive.ts","../../../projects/com/components/form-field/prefix.directive.ts","../../../projects/com/components/form-field/suffix.directive.ts","../../../projects/com/components/form-field/error-state-matcher.ts","../../../projects/com/components/form-field/input.directive.ts","../../../projects/com/components/form-field/form-field-defaults.ts","../../../projects/com/components/form-field/form-field.component.ts","../../../projects/com/components/form-field/index.ts","../../../projects/com/components/form-field/ngx-com-components-form-field.ts"],"sourcesContent":["import type { Signal } from '@angular/core';\nimport type { NgControl } from '@angular/forms';\n\n\n/**\n * Contract that any control inside a form field must implement.\n *\n * This allows the form field to read state from any inner control\n * (input, textarea, custom controls) without knowing implementation details.\n *\n * @example Implementing for a custom phone input\n * ```ts\n * @Directive({\n * selector: 'com-phone-input',\n * providers: [{ provide: FormFieldControl, useExisting: PhoneInputComponent }],\n * })\n * export class PhoneInputComponent extends FormFieldControl<string> {\n * // ... implement all abstract members\n * }\n * ```\n */\nexport abstract class FormFieldControl<_T = unknown> {\n /** The NgControl bound to this control (if any). */\n abstract readonly ngControl: NgControl | null;\n\n /** Whether the control is focused. */\n abstract readonly focused: Signal<boolean>;\n\n /** Whether the label should float (focused or non-empty). */\n abstract readonly shouldLabelFloat: Signal<boolean>;\n\n /** Whether the control is required. */\n abstract readonly required: Signal<boolean>;\n\n /** Whether the control is disabled. */\n abstract readonly disabled: Signal<boolean>;\n\n /** Whether the control is in an error state. */\n abstract readonly errorState: Signal<boolean>;\n\n /** Unique ID for the control element. */\n abstract readonly id: Signal<string>;\n\n /** Structured validation errors (Signal Forms path). */\n readonly errors?: Signal<readonly unknown[] | null>;\n\n /** Called when the form field container is clicked. */\n abstract onContainerClick(event: MouseEvent): void;\n}\n","import { Directive, signal } from '@angular/core';\nimport type { Signal } from '@angular/core';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive to mark the label element inside a form field.\n *\n * The form field automatically associates this label with the inner control\n * and positions it appropriately based on appearance and float state.\n *\n * @tokens none\n *\n * @example\n * ```html\n * <com-form-field>\n * <label comLabel>Email address</label>\n * <input comInput formControlName=\"email\" />\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comLabel]',\n exportAs: 'comLabel',\n host: {\n '[attr.for]': 'forId()',\n '[id]': 'labelId',\n },\n})\nexport class ComLabel {\n readonly labelId: string = `com-label-${nextId++}`;\n\n private readonly _forId = signal<string | null>(null);\n readonly forId: Signal<string | null> = this._forId.asReadonly();\n\n /** Sets the `for` attribute to link to the control. Called by form field. */\n setForId(id: string): void {\n this._forId.set(id);\n }\n}\n","import { cva } from 'class-variance-authority';\nimport type { VariantProps } from 'class-variance-authority';\n\nexport type FormFieldAppearance = 'fill' | 'outline';\nexport type FormFieldColor = 'primary' | 'accent' | 'warn';\nexport type FormFieldFloatLabel = 'auto' | 'always';\nexport type FormFieldSubscriptSizing = 'fixed' | 'dynamic';\n\n/**\n * CVA variants for the form field wrapper.\n *\n * @tokens `--color-foreground`\n */\nexport const formFieldVariants: (props?: {\n disabled?: boolean | null | undefined;\n}) => string = cva(\n ['com-form-field', 'relative block w-full', 'text-foreground'],\n {\n variants: {\n disabled: {\n true: 'pointer-events-none',\n false: '',\n },\n },\n defaultVariants: {\n disabled: false,\n },\n }\n);\n\nexport type FormFieldVariants = VariantProps<typeof formFieldVariants>;\n\n/**\n * CVA variants for the input container (the bordered/filled area).\n *\n * @tokens `--color-input-border`, `--color-input-background`, `--color-primary`,\n * `--color-accent`, `--color-warn`, `--color-ring`, `--color-muted`,\n * `--color-disabled`, `--radius-input`\n */\nexport const formFieldContainerVariants: (props?: {\n appearance?: FormFieldAppearance | null | undefined;\n color?: FormFieldColor | null | undefined;\n focused?: boolean | null | undefined;\n error?: boolean | null | undefined;\n disabled?: boolean | null | undefined;\n}) => string = cva(\n [\n 'com-form-field__container',\n 'relative flex items-center',\n 'w-full min-h-11',\n 'transition-all duration-normal',\n 'rounded-input',\n ],\n {\n variants: {\n appearance: {\n outline: [\n 'border border-input-border',\n 'bg-transparent',\n 'mt-2.5', // Reserve space for floating label to prevent height jump\n ],\n fill: [\n 'rounded-b-none',\n 'bg-muted',\n 'border-b-2 border-input-border',\n ],\n },\n color: {\n primary: '',\n accent: '',\n warn: '',\n },\n focused: {\n true: '',\n false: '',\n },\n error: {\n true: '',\n false: '',\n },\n disabled: {\n true: 'bg-disabled border-disabled',\n false: '',\n },\n },\n compoundVariants: [\n // Outline + focused (no error)\n { appearance: 'outline', focused: true, error: false, class: 'border-primary ring-1 ring-primary' },\n { appearance: 'outline', focused: true, error: false, color: 'accent', class: 'border-accent ring-accent' },\n { appearance: 'outline', focused: true, error: false, color: 'warn', class: 'border-warn ring-warn' },\n // Outline + error\n { appearance: 'outline', error: true, class: 'border-warn ring-1 ring-warn' },\n // Fill + focused (no error)\n { appearance: 'fill', focused: true, error: false, class: 'border-b-primary' },\n { appearance: 'fill', focused: true, error: false, color: 'accent', class: 'border-b-accent' },\n { appearance: 'fill', focused: true, error: false, color: 'warn', class: 'border-b-warn' },\n // Fill + error\n { appearance: 'fill', error: true, class: 'border-b-warn' },\n ],\n defaultVariants: {\n appearance: 'outline',\n color: 'primary',\n focused: false,\n error: false,\n disabled: false,\n },\n }\n);\n\nexport type FormFieldContainerVariants = VariantProps<typeof formFieldContainerVariants>;\n\n/**\n * CVA variants for the floating label.\n *\n * @tokens `--color-muted-foreground`, `--color-primary`, `--color-accent`,\n * `--color-warn`, `--color-background`\n */\nexport const formFieldLabelVariants: (props?: {\n appearance?: FormFieldAppearance | null | undefined;\n floating?: boolean | null | undefined;\n color?: FormFieldColor | null | undefined;\n error?: boolean | null | undefined;\n focused?: boolean | null | undefined;\n disabled?: boolean | null | undefined;\n}) => string = cva(\n [\n 'com-form-field__label',\n 'pointer-events-none',\n 'text-muted-foreground text-sm',\n 'origin-top-left',\n 'transition-all duration-slow ease-in-out',\n ],\n {\n variants: {\n appearance: {\n outline: '',\n fill: '',\n },\n floating: {\n // Floating: absolute positioning at container border\n true: 'absolute',\n // Not floating: relative positioning in flex flow (after prefix)\n false: 'relative flex-shrink-0 pl-3',\n },\n color: {\n primary: '',\n accent: '',\n warn: '',\n },\n error: {\n true: 'text-warn',\n false: '',\n },\n focused: {\n true: '',\n false: '',\n },\n disabled: {\n true: 'text-disabled-foreground',\n false: '',\n },\n },\n compoundVariants: [\n // Outline floating (label above border with notch effect)\n {\n appearance: 'outline',\n floating: true,\n class: 'left-2 -top-2.5 scale-75 bg-background px-1',\n },\n // Fill floating\n {\n appearance: 'fill',\n floating: true,\n class: 'left-3 top-1 scale-75 text-xs',\n },\n // Focused + floating colors (no error)\n { floating: true, focused: true, error: false, color: 'primary', class: 'text-primary' },\n { floating: true, focused: true, error: false, color: 'accent', class: 'text-accent' },\n { floating: true, focused: true, error: false, color: 'warn', class: 'text-warn' },\n // Error overrides\n { floating: true, error: true, class: 'text-warn' },\n ],\n defaultVariants: {\n appearance: 'outline',\n floating: false,\n color: 'primary',\n error: false,\n focused: false,\n disabled: false,\n },\n }\n);\n\nexport type FormFieldLabelVariants = VariantProps<typeof formFieldLabelVariants>;\n\n/**\n * CVA variants for the subscript area (hints/errors).\n *\n * @tokens (inherits from children)\n */\nexport const formFieldSubscriptVariants: (props?: {\n sizing?: FormFieldSubscriptSizing | null | undefined;\n}) => string = cva(\n ['com-form-field__subscript', 'text-xs mt-1 px-3'],\n {\n variants: {\n sizing: {\n fixed: 'min-h-5',\n dynamic: 'min-h-0',\n },\n },\n defaultVariants: {\n sizing: 'fixed',\n },\n }\n);\n\nexport type FormFieldSubscriptVariants = VariantProps<typeof formFieldSubscriptVariants>;\n\n/**\n * CVA variants for hint text.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const hintVariants: () => string = cva(['com-form-field__hint', 'text-muted-foreground text-xs']);\n\n/**\n * CVA variants for error messages.\n *\n * @tokens `--color-warn`\n */\nexport const errorVariants: () => string = cva(['com-form-field__error', 'text-warn text-xs']);\n\n/**\n * CVA variants for prefix slot.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const prefixVariants: () => string = cva([\n 'com-form-field__prefix',\n 'flex items-center text-muted-foreground pl-3',\n]);\n\n/**\n * CVA variants for suffix slot.\n *\n * @tokens `--color-muted-foreground`\n */\nexport const suffixVariants: () => string = cva([\n 'com-form-field__suffix',\n 'flex items-center text-muted-foreground pr-3',\n]);\n","import { computed, Directive, input } from '@angular/core';\nimport type { InputSignal, Signal } from '@angular/core';\nimport { hintVariants } from './form-field.variants';\nimport { mergeClasses } from 'ngx-com/utils';\n\n/** Alignment of hint text in the subscript area. */\nexport type HintAlign = 'start' | 'end';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive for hint text displayed below the form field.\n *\n * The hint provides supplementary information to help users fill out the field.\n * It is automatically added to the control's `aria-describedby`.\n *\n * @tokens `--color-muted-foreground`\n *\n * @example Basic hint\n * ```html\n * <com-form-field>\n * <label comLabel>Password</label>\n * <input comInput formControlName=\"password\" />\n * <span comHint>At least 8 characters</span>\n * </com-form-field>\n * ```\n *\n * @example Right-aligned hint (e.g., character count)\n * ```html\n * <com-form-field>\n * <label comLabel>Bio</label>\n * <textarea comInput formControlName=\"bio\"></textarea>\n * <span comHint>Keep it brief</span>\n * <span comHint align=\"end\">{{ bioLength }}/150</span>\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comHint]',\n exportAs: 'comHint',\n host: {\n '[id]': 'id',\n '[class]': 'hostClasses()',\n },\n})\nexport class ComHint {\n readonly id: string = `com-hint-${nextId++}`;\n readonly align: InputSignal<HintAlign> = input<HintAlign>('start');\n\n protected readonly hostClasses: Signal<string> = computed(() =>\n mergeClasses(hintVariants(), this.align() === 'end' && 'ml-auto')\n );\n}\n","import { computed, Directive, input, signal } from '@angular/core';\nimport type { AbstractControl } from '@angular/forms';\nimport type { InputSignal, Signal, WritableSignal } from '@angular/core';\nimport { errorVariants } from './form-field.variants';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive for error messages displayed below the form field.\n *\n * Errors replace hints when the control is in an error state.\n * Uses `role=\"alert\"` and `aria-live=\"polite\"` for screen reader announcement.\n *\n * The optional `match` input allows showing errors only for specific validation errors.\n *\n * @tokens `--color-warn`\n *\n * @example Basic error\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" />\n * <span comError>Please enter a valid email</span>\n * </com-form-field>\n * ```\n *\n * @example Matching specific errors\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" />\n * <span comError match=\"required\">Email is required.</span>\n * <span comError match=\"email\">Must be a valid email address.</span>\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comError]',\n exportAs: 'comError',\n host: {\n '[id]': 'id',\n '[class]': 'errorVariants()',\n '[class.hidden]': '!shouldShow()',\n 'role': 'alert',\n 'aria-live': 'polite',\n },\n})\nexport class ComError {\n readonly id: string = `com-error-${nextId++}`;\n\n /** Reference to the form control (Reactive Forms path). */\n private readonly _control: WritableSignal<AbstractControl | null> = signal(null);\n\n /** Structured errors from Signal Forms. */\n private readonly _signalErrors: WritableSignal<readonly unknown[]> = signal([]);\n\n /**\n * Show this error only when a specific validation error key is present.\n * If empty, the error is always shown when the control is in error state.\n */\n readonly match: InputSignal<string> = input<string>('');\n\n protected readonly errorVariants: () => string = errorVariants;\n\n /**\n * Whether this error should be displayed based on the match condition.\n * Used by the form field to filter which errors to show.\n */\n readonly shouldShow: Signal<boolean> = computed(() => {\n const matchKey = this.match();\n if (!matchKey) return true;\n\n // Signal Forms path: match on error.kind\n const signalErrors = this._signalErrors();\n if (signalErrors.length > 0) {\n return signalErrors.some((e) => (e as { kind?: string })?.kind === matchKey);\n }\n\n // Reactive Forms path: match on AbstractControl.errors keys\n const errors = this._control()?.errors;\n return errors ? matchKey in errors : false;\n });\n\n /**\n * Sets the form control reference (Reactive Forms).\n * Called by the parent form field component.\n */\n setControl(control: AbstractControl | null): void {\n this._control.set(control);\n }\n\n /**\n * Sets structured validation errors (Signal Forms).\n * Called by the parent form field component.\n */\n setSignalErrors(errors: readonly unknown[]): void {\n this._signalErrors.set(errors);\n }\n}\n","import { Directive } from '@angular/core';\nimport { prefixVariants } from './form-field.variants';\n\n/**\n * Directive to mark content as the prefix slot in a form field.\n *\n * Prefix content appears before the input (e.g., currency symbol, icon).\n *\n * @tokens `--color-muted-foreground`\n *\n * @example Currency prefix\n * ```html\n * <com-form-field>\n * <label comLabel>Amount</label>\n * <span comPrefix>$</span>\n * <input comInput type=\"number\" formControlName=\"amount\" />\n * </com-form-field>\n * ```\n *\n * @example Icon prefix\n * ```html\n * <com-form-field>\n * <label comLabel>Search</label>\n * <svg comPrefix class=\"size-4\">...</svg>\n * <input comInput formControlName=\"query\" />\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comPrefix]',\n exportAs: 'comPrefix',\n host: {\n '[class]': 'prefixVariants()',\n },\n})\nexport class ComPrefix {\n protected readonly prefixVariants: () => string = prefixVariants;\n}\n","import { Directive } from '@angular/core';\nimport { suffixVariants } from './form-field.variants';\n\n/**\n * Directive to mark content as the suffix slot in a form field.\n *\n * Suffix content appears after the input (e.g., unit, clear button, visibility toggle).\n *\n * @tokens `--color-muted-foreground`\n *\n * @example Unit suffix\n * ```html\n * <com-form-field>\n * <label comLabel>Weight</label>\n * <input comInput type=\"number\" formControlName=\"weight\" />\n * <span comSuffix>kg</span>\n * </com-form-field>\n * ```\n *\n * @example Clear button suffix\n * ```html\n * <com-form-field>\n * <label comLabel>Search</label>\n * <input comInput formControlName=\"query\" />\n * <button comSuffix type=\"button\" (click)=\"clearSearch()\">\n * <svg class=\"size-4\">...</svg>\n * </button>\n * </com-form-field>\n * ```\n *\n * @example Password visibility toggle\n * ```html\n * <com-form-field>\n * <label comLabel>Password</label>\n * <input comInput [type]=\"showPassword ? 'text' : 'password'\" formControlName=\"password\" />\n * <button comSuffix type=\"button\" (click)=\"showPassword = !showPassword\">\n * <svg class=\"size-4\">...</svg>\n * </button>\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: '[comSuffix]',\n exportAs: 'comSuffix',\n host: {\n '[class]': 'suffixVariants()',\n },\n})\nexport class ComSuffix {\n protected readonly suffixVariants: () => string = suffixVariants;\n}\n","import { Injectable } from '@angular/core';\nimport type { AbstractControl, FormGroupDirective, NgForm } from '@angular/forms';\n\n/**\n * Strategy for determining when to display errors in a form field.\n *\n * The default behavior shows errors when the control is invalid AND\n * either touched OR the parent form has been submitted.\n *\n * @example Override globally with eager error display\n * ```ts\n * @Injectable()\n * export class EagerErrorStateMatcher extends ErrorStateMatcher {\n * override isErrorState(control: AbstractControl | null): boolean {\n * return !!(control?.invalid && control.dirty);\n * }\n * }\n *\n * // In app config\n * providers: [{ provide: ErrorStateMatcher, useClass: EagerErrorStateMatcher }]\n * ```\n *\n * @example Per-field override\n * ```html\n * <com-form-field>\n * <input comInput [errorStateMatcher]=\"eagerMatcher\" />\n * </com-form-field>\n * ```\n */\n@Injectable({ providedIn: 'root' })\nexport class ErrorStateMatcher {\n isErrorState(\n control: AbstractControl | null,\n form: FormGroupDirective | NgForm | null\n ): boolean {\n return !!(control?.invalid && (control.touched || form?.submitted));\n }\n}\n","import {\n booleanAttribute,\n computed,\n DestroyRef,\n Directive,\n ElementRef,\n forwardRef,\n inject,\n input,\n signal,\n} from '@angular/core';\nimport type { DoCheck, InputSignal, InputSignalWithTransform, OnInit, Signal, WritableSignal } from '@angular/core';\n\nimport { FormGroupDirective, NgControl, NgForm } from '@angular/forms';\nimport { AutofillMonitor } from '@angular/cdk/text-field';\nimport { FormFieldControl } from './form-field-control';\nimport { ErrorStateMatcher } from './error-state-matcher';\nimport type { FormFieldAppearance } from './form-field-defaults';\n\n/** Auto-incrementing ID counter. */\nlet nextId = 0;\n\n/**\n * Directive applied to native `<input>` and `<textarea>` elements to bridge\n * them to the form field wrapper. Implements the `FormFieldControl` contract.\n *\n * This directive does NOT implement `ControlValueAccessor` - it relies on\n * Angular's built-in value accessors (`DefaultValueAccessor`, `NumberValueAccessor`, etc.)\n * that are already applied to native elements with `formControlName` or `ngModel`.\n *\n * Instead, this directive reports state (focused, empty, disabled, error) to the\n * parent form field for proper visual presentation.\n *\n * @tokens (styling is controlled by the parent form field)\n *\n * @example Basic usage\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" placeholder=\"you@example.com\" />\n * </com-form-field>\n * ```\n *\n * @example Textarea\n * ```html\n * <com-form-field>\n * <label comLabel>Description</label>\n * <textarea comInput formControlName=\"description\"></textarea>\n * </com-form-field>\n * ```\n *\n * @example Custom error state matcher\n * ```html\n * <com-form-field>\n * <label comLabel>Code</label>\n * <input comInput formControlName=\"code\" [errorStateMatcher]=\"eagerMatcher\" />\n * </com-form-field>\n * ```\n */\n@Directive({\n selector: 'input[comInput], textarea[comInput]',\n exportAs: 'comInput',\n providers: [{ provide: FormFieldControl, useExisting: forwardRef(() => ComInput) }],\n host: {\n '[id]': 'id()',\n '[disabled]': 'disabled()',\n '[required]': 'required()',\n '[attr.aria-invalid]': 'errorState() || null',\n '[attr.aria-required]': 'required() || null',\n '[attr.aria-describedby]': 'ariaDescribedBy() || null',\n '[class]': 'hostClasses()',\n '(focus)': 'onFocus()',\n '(blur)': 'onBlur()',\n '(input)': 'onInput()',\n },\n})\nexport class ComInput implements FormFieldControl<string>, OnInit, DoCheck {\n private readonly elementRef: ElementRef<HTMLInputElement | HTMLTextAreaElement> = inject(ElementRef);\n private readonly destroyRef = inject(DestroyRef);\n private readonly autofillMonitor = inject(AutofillMonitor);\n private readonly defaultErrorStateMatcher = inject(ErrorStateMatcher);\n private readonly parentForm = inject(NgForm, { optional: true });\n private readonly parentFormGroup = inject(FormGroupDirective, { optional: true });\n\n /** NgControl bound to this input (if using reactive forms). */\n readonly ngControl: NgControl | null = inject(NgControl, { optional: true, self: true });\n\n // Inputs\n readonly inputId: InputSignal<string | undefined> = input<string>(undefined, { alias: 'id' });\n readonly inputDisabled: InputSignalWithTransform<boolean, unknown> = input(false, {\n alias: 'disabled',\n transform: booleanAttribute,\n });\n readonly inputRequired: InputSignalWithTransform<boolean, unknown> = input(false, {\n alias: 'required',\n transform: booleanAttribute,\n });\n readonly userAriaDescribedBy: InputSignal<string> = input<string>('', { alias: 'aria-describedby' });\n readonly errorStateMatcher: InputSignal<ErrorStateMatcher | undefined> = input<ErrorStateMatcher>();\n\n // Signal Forms inputs — set automatically by [formField] via setInputOnDirectives\n readonly sfInvalid: InputSignal<boolean> = input(false, { alias: 'invalid' });\n readonly sfTouched: InputSignalWithTransform<boolean, unknown> = input(false, {\n alias: 'touched',\n transform: booleanAttribute,\n });\n readonly sfErrors: InputSignal<readonly unknown[]> = input<readonly unknown[]>([], {\n alias: 'errors',\n });\n\n /** Whether the form system is Signal Forms (no NgControl present). */\n private readonly isSignalForms: boolean = !this.ngControl;\n\n // Internal state\n private readonly _focused = signal(false);\n private readonly _autofilled = signal(false);\n private readonly _empty = signal(true);\n private readonly _uniqueId: string = `com-input-${nextId++}`;\n private readonly _appearance: WritableSignal<FormFieldAppearance> = signal<FormFieldAppearance>('outline');\n private _previousNativeValue: string = '';\n\n // Public signals implementing FormFieldControl\n readonly focused: Signal<boolean> = this._focused.asReadonly();\n\n readonly id: Signal<string> = computed(() => this.inputId() ?? this._uniqueId);\n\n readonly shouldLabelFloat: Signal<boolean> = computed(() => {\n return this._focused() || !this._empty() || this._autofilled();\n });\n\n readonly disabled: Signal<boolean> = computed(() => {\n if (this.inputDisabled()) return true;\n return this.ngControl?.control?.disabled ?? false;\n });\n\n readonly required: Signal<boolean> = computed(() => {\n if (this.inputRequired()) return true;\n const control = this.ngControl?.control;\n if (control?.validator) {\n const result = control.validator({ value: '' } as never);\n return result?.['required'] !== undefined;\n }\n return false;\n });\n\n readonly errorState: Signal<boolean> = computed(() => {\n if (this.isSignalForms) {\n // Signal Forms: gate on both invalid AND touched — mirrors ErrorStateMatcher default.\n // Signal Forms' invalid is pure validation state (not gated by touched).\n return this.sfInvalid() && this.sfTouched();\n }\n // Reactive Forms: use ErrorStateMatcher (existing logic)\n this._focused();\n this._empty();\n const matcher = this.errorStateMatcher() ?? this.defaultErrorStateMatcher;\n const form = this.parentFormGroup ?? this.parentForm;\n return matcher.isErrorState(this.ngControl?.control ?? null, form);\n });\n\n /** Structured validation errors from Signal Forms, exposed for the parent form field. */\n readonly errors: Signal<readonly unknown[] | null> = computed(() =>\n this.isSignalForms ? this.sfErrors() : null\n );\n\n /** Combined aria-describedby including user-provided and form-field-generated IDs. */\n private readonly _describedByIds = signal('');\n\n readonly ariaDescribedBy: Signal<string> = computed(() => {\n const userIds = this.userAriaDescribedBy();\n const fieldIds = this._describedByIds();\n return [userIds, fieldIds].filter(Boolean).join(' ');\n });\n\n /** Computed host classes including appearance-based padding. */\n protected readonly hostClasses: Signal<string> = computed(() => {\n const base =\n 'peer w-full bg-transparent text-foreground placeholder:text-input-placeholder outline-none border-none disabled:cursor-not-allowed disabled:text-disabled-foreground px-3';\n const padding = this._appearance() === 'fill' ? 'pt-5 pb-1.5' : 'py-2.5';\n return `${base} ${padding}`;\n });\n\n ngOnInit(): void {\n this._previousNativeValue = this.elementRef.nativeElement.value;\n this.updateEmpty();\n\n const autofillSub = this.autofillMonitor.monitor(this.elementRef).subscribe((event) => {\n this._autofilled.set(event.isAutofilled);\n });\n\n this.destroyRef.onDestroy(() => {\n autofillSub.unsubscribe();\n this.autofillMonitor.stopMonitoring(this.elementRef);\n });\n }\n\n ngDoCheck(): void {\n this.dirtyCheckNativeValue();\n }\n\n private dirtyCheckNativeValue(): void {\n const newValue = this.elementRef.nativeElement.value;\n if (this._previousNativeValue !== newValue) {\n this._previousNativeValue = newValue;\n this.updateEmpty();\n }\n }\n\n protected onFocus(): void {\n this._focused.set(true);\n }\n\n protected onBlur(): void {\n this._focused.set(false);\n }\n\n protected onInput(): void {\n this.updateEmpty();\n }\n\n private updateEmpty(): void {\n this._empty.set(!this.elementRef.nativeElement.value);\n }\n\n // FormFieldControl methods\n onContainerClick(event: MouseEvent): void {\n if (!this.disabled() && event.target !== this.elementRef.nativeElement) {\n this.elementRef.nativeElement.focus();\n }\n }\n\n /**\n * Sets the describedBy IDs from the form field.\n * Called by the parent form field component.\n */\n setDescribedByIds(ids: string): void {\n this._describedByIds.set(ids);\n }\n\n /**\n * Sets the appearance for styling.\n * Called by the parent form field component.\n */\n setAppearance(appearance: FormFieldAppearance): void {\n this._appearance.set(appearance);\n }\n\n /** Focus the native element. */\n focus(): void {\n this.elementRef.nativeElement.focus();\n }\n}\n","import { InjectionToken } from '@angular/core';\nimport type {\n FormFieldAppearance,\n FormFieldColor,\n FormFieldFloatLabel,\n FormFieldSubscriptSizing,\n} from './form-field.variants';\n\n// Re-export types for convenience\nexport type { FormFieldAppearance, FormFieldColor, FormFieldFloatLabel, FormFieldSubscriptSizing };\n\n/**\n * Global configuration defaults for form fields.\n *\n * @example Set defaults in app config\n * ```ts\n * providers: [\n * {\n * provide: FORM_FIELD_DEFAULTS,\n * useValue: {\n * appearance: 'fill',\n * floatLabel: 'always',\n * color: 'primary',\n * }\n * }\n * ]\n * ```\n */\nexport interface FormFieldDefaults {\n appearance?: FormFieldAppearance;\n color?: FormFieldColor;\n floatLabel?: FormFieldFloatLabel;\n hideRequiredMarker?: boolean;\n subscriptSizing?: FormFieldSubscriptSizing;\n}\n\nexport const FORM_FIELD_DEFAULTS: InjectionToken<FormFieldDefaults> = new InjectionToken<FormFieldDefaults>(\n 'FORM_FIELD_DEFAULTS',\n {\n providedIn: 'root',\n factory: (): FormFieldDefaults => ({}),\n }\n);\n","import {\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n computed,\n contentChild,\n contentChildren,\n effect,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport type { InputSignal, InputSignalWithTransform, Signal } from '@angular/core';\nimport { FormFieldControl } from './form-field-control';\nimport { ComLabel } from './label.directive';\nimport { ComHint } from './hint.directive';\nimport { ComError } from './error.directive';\nimport { ComPrefix } from './prefix.directive';\nimport { ComSuffix } from './suffix.directive';\nimport { ComInput } from './input.directive';\nimport {\n FORM_FIELD_DEFAULTS,\n type FormFieldAppearance,\n type FormFieldColor,\n type FormFieldFloatLabel,\n type FormFieldSubscriptSizing,\n} from './form-field-defaults';\nimport {\n formFieldVariants,\n formFieldContainerVariants,\n formFieldLabelVariants,\n formFieldSubscriptVariants,\n} from './form-field.variants';\nimport { mergeClasses } from 'ngx-com/utils';\n\n/**\n * Form field wrapper providing visual structure for form inputs.\n *\n * Provides floating labels, borders (outline/fill appearance), hints, errors,\n * and prefix/suffix slots. Automatically wires ARIA attributes for accessibility.\n *\n * The form field reads state from its inner `FormFieldControl` child (typically\n * a `ComInput` directive) and renders UI accordingly.\n *\n * @tokens `--color-foreground`, `--color-input-border`, `--color-input-background`,\n * `--color-primary`, `--color-accent`, `--color-warn`, `--color-ring`,\n * `--color-muted`, `--color-muted-foreground`, `--color-disabled`,\n * `--color-disabled-foreground`, `--color-background`, `--radius-input`\n *\n * @example Basic outline field\n * ```html\n * <com-form-field>\n * <label comLabel>Email</label>\n * <input comInput formControlName=\"email\" />\n * <span comHint>We'll never share your email.</span>\n * <span comError match=\"required\">Email is required.</span>\n * </com-form-field>\n * ```\n *\n * @example Fill appearance\n * ```html\n * <com-form-field appearance=\"fill\">\n * <label comLabel>Username</label>\n * <input comInput formControlName=\"username\" />\n * </com-form-field>\n * ```\n *\n * @example With prefix and suffix\n * ```html\n * <com-form-field>\n * <label comLabel>Amount</label>\n * <span comPrefix>$</span>\n * <input comInput type=\"number\" formControlName=\"amount\" />\n * <span comSuffix>.00</span>\n * </com-form-field>\n * ```\n */\n@Component({\n selector: 'com-form-field',\n exportAs: 'comFormField',\n template: `\n <div [class]=\"containerClasses()\" role=\"group\" tabindex=\"-1\" (click)=\"onContainerClick($event)\" (keydown.enter)=\"onContainerActivate()\">\n <div class=\"flex items-center w-full\">\n @if (hasPrefix()) {\n <ng-content select=\"[comPrefix]\" />\n }\n @if (labelChild()) {\n <span [class]=\"labelClasses()\">\n <ng-content select=\"[comLabel]\" />\n @if (showRequiredMarker()) {\n <span class=\"text-warn\" aria-hidden=\"true\"> *</span>\n }\n </span>\n }\n <div class=\"flex-1 min-w-0\">\n <ng-content />\n </div>\n @if (hasSuffix()) {\n <ng-content select=\"[comSuffix]\" />\n }\n </div>\n </div>\n\n <div [class]=\"subscriptClasses()\">\n <div [class.hidden]=\"!showErrors()\">\n <ng-content select=\"[comError]\" />\n </div>\n <div [class.hidden]=\"showErrors()\" class=\"flex justify-between w-full gap-2\">\n <ng-content select=\"[comHint]:not([align='end'])\" />\n <ng-content select=\"[comHint][align='end']\" />\n </div>\n </div>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n styles: `\n /* Hide placeholder when label exists and is not floating (label acts as placeholder) */\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) input::placeholder,\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) textarea::placeholder {\n color: transparent;\n }\n\n /* Hide dropdown placeholder when label exists and is not floating */\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-dropdown .text-placeholder {\n display: none;\n }\n\n /* Make dropdown fill available space inside form-field */\n com-form-field com-dropdown {\n display: block;\n width: 100%;\n }\n\n /* Make datepicker fill available space inside form-field */\n com-form-field com-datepicker {\n display: block;\n width: 100%;\n }\n\n /* Make date-range-picker fill available space inside form-field */\n com-form-field com-date-range-picker {\n display: block;\n width: 100%;\n }\n\n /* Make time-picker fill available space inside form-field */\n com-form-field com-time-picker {\n display: block;\n width: 100%;\n }\n\n /* Hide datepicker placeholder when label exists and is not floating */\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-datepicker input::placeholder {\n color: transparent;\n }\n\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-date-range-picker input::placeholder {\n color: transparent;\n }\n\n /* Hide time picker separators and period button when label is not floating */\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-time-picker span[aria-hidden],\n com-form-field.com-form-field--has-label:not(.com-form-field--floating) com-time-picker button {\n visibility: hidden;\n }\n `,\n host: {\n '[class]': 'hostClasses()',\n '[class.com-form-field--focused]': 'isFocused()',\n '[class.com-form-field--disabled]': 'isDisabled()',\n '[class.com-form-field--error]': 'hasError()',\n '[class.com-form-field--floating]': 'shouldLabelFloat()',\n '[class.com-form-field--has-label]': '!!labelChild()',\n },\n})\nexport class ComFormField {\n private readonly defaults = inject(FORM_FIELD_DEFAULTS, { optional: true });\n\n // Content children\n readonly control: Signal<FormFieldControl | undefined> = contentChild<FormFieldControl>(FormFieldControl);\n readonly inputDirective: Signal<ComInput | undefined> = contentChild<ComInput>(ComInput);\n readonly labelChild: Signal<ComLabel | undefined> = contentChild<ComLabel>(ComLabel);\n readonly hintChildren: Signal<readonly ComHint[]> = contentChildren<ComHint>(ComHint);\n readonly errorChildren: Signal<readonly ComError[]> = contentChildren<ComError>(ComError);\n readonly prefixChild: Signal<ComPrefix | undefined> = contentChild<ComPrefix>(ComPrefix);\n readonly suffixChild: Signal<ComSuffix | undefined> = contentChild<ComSuffix>(ComSuffix);\n\n // Inputs with defaults fallback\n readonly appearance: InputSignal<FormFieldAppearance> = input<FormFieldAppearance>(\n this.defaults?.appearance ?? 'outline'\n );\n readonly color: InputSignal<FormFieldColor> = input<FormFieldColor>(this.defaults?.color ?? 'primary');\n readonly floatLabel: InputSignal<FormFieldFloatLabel> = input<FormFieldFloatLabel>(\n this.defaults?.floatLabel ?? 'auto'\n );\n readonly hideRequiredMarker: InputSignalWithTransform<boolean, unknown> = input(\n this.defaults?.hideRequiredMarker ?? false,\n { transform: booleanAttribute }\n );\n readonly subscriptSizing: InputSignal<FormFieldSubscriptSizing> = input<FormFieldSubscriptSizing>(\n this.defaults?.subscriptSizing ?? 'fixed'\n );\n readonly userClass: InputSignal<string> = input<string>('', { alias: 'class' });\n\n // Derived state from inner control\n readonly shouldLabelFloat: Signal<boolean> = computed(() => {\n if (this.floatLabel() === 'always') return true;\n return this.control()?.shouldLabelFloat() ?? false;\n });\n\n readonly isFocused: Signal<boolean> = computed(() => this.control()?.focused() ?? false);\n readonly isDisabled: Signal<boolean> = computed(() => this.control()?.disabled() ?? false);\n readonly hasError: Signal<boolean> = computed(() => this.control()?.errorState() ?? false);\n readonly hasPrefix: Signal<boolean> = computed(() => !!this.prefixChild());\n readonly hasSuffix: Signal<boolean> = computed(() => !!this.suffixChild());\n\n readonly showRequiredMarker: Signal<boolean> = computed(() => {\n if (this.hideRequiredMarker()) return false;\n return this.control()?.required() ?? false;\n });\n\n readonly showErrors: Signal<boolean> = computed(() => this.hasError() && this.errorChildren().length > 0);\n\n // Computed classes\n protected readonly hostClasses: Signal<string> = computed(() =>\n mergeClasses(formFieldVariants({ disabled: this.isDisabled() }), this.userClass())\n );\n\n protected readonly containerClasses: Signal<string> = computed(() =>\n formFieldContainerVariants({\n appearance: this.appearance(),\n color: this.color(),\n focused: this.isFocused(),\n error: this.hasError(),\n disabled: this.isDisabled(),\n })\n );\n\n protected readonly labelClasses: Signal<string> = computed(() =>\n formFieldLabelVariants({\n appearance: this.appearance(),\n floating: this.shouldLabelFloat(),\n color: this.color(),\n error: this.hasError(),\n focused: this.isFocused(),\n disabled: this.isDisabled(),\n })\n );\n\n protected readonly subscriptClasses: Signal<string> = computed(() =>\n formFieldSubscriptVariants({ sizing: this.subscriptSizing() })\n );\n\n constructor() {\n // Wire up label to control\n effect(() => {\n const label = this.labelChild();\n const ctrl = this.control();\n if (label && ctrl) {\n label.setForId(ctrl.id());\n }\n });\n\n // Wire up aria-describedby on the control\n effect(() => {\n const ctrl = this.control();\n if (!ctrl || !('setDescribedByIds' in ctrl)) return;\n\n const ids = this.showErrors()\n ? this.errorChildren().filter((e) => e.shouldShow()).map((e) => e.id)\n : this.hintChildren().map((h) => h.id);\n (ctrl as { setDescribedByIds: (ids: string) => void }).setDescribedByIds(ids.join(' '));\n });\n\n // Wire up appearance to control for proper styling\n effect(() => {\n const ctrl = this.control();\n if (ctrl && 'setAppearance' in ctrl) {\n (ctrl as { setAppearance: (appearance: FormFieldAppearance) => void }).setAppearance(this.appearance());\n }\n });\n\n // Wire up control reference to error directives (re-runs on error state change)\n effect(() => {\n // Read hasError to trigger re-evaluation when validation state changes\n this.hasError();\n const ctrl = this.control();\n if (!ctrl) return;\n\n const errors = ctrl.errors?.() ?? null;\n if (errors !== null) {\n // Signal Forms path: pass structured errors to each comError\n this.errorChildren().forEach((error) => error.setSignalErrors(errors as readonly unknown[]));\n } else {\n // Reactive Forms path: pass AbstractControl reference\n const ngControl = ctrl.ngControl?.control ?? null;\n this.errorChildren().forEach((error) => error.setControl(ngControl));\n }\n });\n }\n\n protected onContainerClick(event: MouseEvent): void {\n this.control()?.onContainerClick(event);\n }\n\n protected onContainerActivate(): void {\n this.control()?.onContainerClick(new MouseEvent('click'));\n }\n}\n","// Public API for the form-field component\n\n// Main component\nexport { ComFormField } from './form-field.component';\n\n// Directives\nexport { ComInput } from './input.directive';\nexport { ComLabel } from './label.directive';\nexport { ComHint, type HintAlign } from './hint.directive';\nexport { ComError } from './error.directive';\nexport { ComPrefix } from './prefix.directive';\nexport { ComSuffix } from './suffix.directive';\n\n// Abstract class for custom controls\nexport { FormFieldControl } from './form-field-control';\n\n// Error state matching\nexport { ErrorStateMatcher } from './error-state-matcher';\n\n// Configuration\nexport {\n FORM_FIELD_DEFAULTS,\n type FormFieldDefaults,\n type FormFieldAppearance,\n type FormFieldColor,\n type FormFieldFloatLabel,\n type FormFieldSubscriptSizing,\n} from './form-field-defaults';\n\n// Variants (for advanced customization)\nexport {\n formFieldVariants,\n formFieldContainerVariants,\n formFieldLabelVariants,\n formFieldSubscriptVariants,\n hintVariants,\n errorVariants,\n prefixVariants,\n suffixVariants,\n type FormFieldVariants,\n type FormFieldContainerVariants,\n type FormFieldLabelVariants,\n type FormFieldSubscriptVariants,\n} from './form-field.variants';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["nextId"],"mappings":";;;;;;;AAIA;;;;;;;;;;;;;;;;AAgBG;MACmB,gBAAgB,CAAA;;AAuB3B,IAAA,MAAM;AAIhB;;AC7CD;AACA,IAAIA,QAAM,GAAG,CAAC;AAEd;;;;;;;;;;;;;;;AAeG;MASU,QAAQ,CAAA;AACV,IAAA,OAAO,GAAW,CAAA,UAAA,EAAaA,QAAM,EAAE,EAAE;AAEjC,IAAA,MAAM,GAAG,MAAM,CAAgB,I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A,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,OAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;ACzLzF;AAEA;;ACFA;;AAEG;;;;"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { provideComIcons } from 'ngx-com/components/icon';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Converts a single Lucide icon to the generic `ComIconData` format.
|
|
5
|
+
*
|
|
6
|
+
* Lucide's `LucideIconData` is `readonly [string, Record<string, string>][]`
|
|
7
|
+
* which is structurally identical to `ComIconData`. This function exists for
|
|
8
|
+
* type-level conversion and explicit intent.
|
|
9
|
+
*/
|
|
10
|
+
function fromLucideIcon(icon) {
|
|
11
|
+
return icon;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Registers Lucide icons for use with `com-icon`.
|
|
15
|
+
*
|
|
16
|
+
* Drop-in replacement for `provideComIcons` that accepts Lucide icon imports directly.
|
|
17
|
+
*
|
|
18
|
+
* @example Root-level (app.config.ts)
|
|
19
|
+
* ```ts
|
|
20
|
+
* import { provideComLucideIcons } from 'ngx-com/components/icon/lucide';
|
|
21
|
+
* import { ChevronRight, Star, Check } from 'lucide-angular';
|
|
22
|
+
*
|
|
23
|
+
* export const appConfig = {
|
|
24
|
+
* providers: [
|
|
25
|
+
* provideComLucideIcons({ ChevronRight, Star, Check })
|
|
26
|
+
* ]
|
|
27
|
+
* };
|
|
28
|
+
* ```
|
|
29
|
+
*/
|
|
30
|
+
function provideComLucideIcons(icons) {
|
|
31
|
+
// LucideIcons is Record<string, LucideIconData> which is structurally
|
|
32
|
+
// compatible with ComIconMap — cast through unknown for type safety.
|
|
33
|
+
return provideComIcons(icons);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Generated bundle index. Do not edit.
|
|
38
|
+
*/
|
|
39
|
+
|
|
40
|
+
export { fromLucideIcon, provideComLucideIcons };
|
|
41
|
+
//# sourceMappingURL=ngx-com-components-icon-lucide.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ngx-com-components-icon-lucide.mjs","sources":["../../../projects/com/components/icon/lucide/lucide-adapter.ts","../../../projects/com/components/icon/lucide/ngx-com-components-icon-lucide.ts"],"sourcesContent":["import type { Provider } from '@angular/core';\nimport type { LucideIconData, LucideIcons } from 'lucide-angular';\nimport { provideComIcons } from 'ngx-com/components/icon';\nimport type { ComIconData } from 'ngx-com/components/icon';\n\n/**\n * Converts a single Lucide icon to the generic `ComIconData` format.\n *\n * Lucide's `LucideIconData` is `readonly [string, Record<string, string>][]`\n * which is structurally identical to `ComIconData`. This function exists for\n * type-level conversion and explicit intent.\n */\nexport function fromLucideIcon(icon: LucideIconData): ComIconData {\n return icon as unknown as ComIconData;\n}\n\n/**\n * Registers Lucide icons for use with `com-icon`.\n *\n * Drop-in replacement for `provideComIcons` that accepts Lucide icon imports directly.\n *\n * @example Root-level (app.config.ts)\n * ```ts\n * import { provideComLucideIcons } from 'ngx-com/components/icon/lucide';\n * import { ChevronRight, Star, Check } from 'lucide-angular';\n *\n * export const appConfig = {\n * providers: [\n * provideComLucideIcons({ ChevronRight, Star, Check })\n * ]\n * };\n * ```\n */\nexport function provideComLucideIcons(icons: LucideIcons): Provider {\n // LucideIcons is Record<string, LucideIconData> which is structurally\n // compatible with ComIconMap — cast through unknown for type safety.\n return provideComIcons(icons as unknown as Record<string, ComIconData>);\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAKA;;;;;;AAMG;AACG,SAAU,cAAc,CAAC,IAAoB,EAAA;AACjD,IAAA,OAAO,IAA8B;AACvC;AAEA;;;;;;;;;;;;;;;;AAgBG;AACG,SAAU,qBAAqB,CAAC,KAAkB,EAAA;;;AAGtD,IAAA,OAAO,eAAe,CAAC,KAA+C,CAAC;AACzE;;ACrCA;;AAEG;;;;"}
|