@3ddv/software-division-components 2.0.14 → 2.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 +2 -0
- package/backoffice/datepicker/datepicker.component.css +262 -0
- package/fesm2022/3ddv-software-division-components-dvm-cart.mjs +18 -6
- package/fesm2022/3ddv-software-division-components-dvm-cart.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-dvm-loader.mjs +18 -4
- package/fesm2022/3ddv-software-division-components-dvm-loader.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-dvm-map-loader.mjs +26 -9
- package/fesm2022/3ddv-software-division-components-dvm-map-loader.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-dvm-neighbors.mjs +41 -42
- package/fesm2022/3ddv-software-division-components-dvm-neighbors.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-dvm-popover.mjs +2 -1
- package/fesm2022/3ddv-software-division-components-dvm-popover.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-generic-button.mjs +3 -2
- package/fesm2022/3ddv-software-division-components-generic-button.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-generic-dialog.mjs +173 -19
- package/fesm2022/3ddv-software-division-components-generic-dialog.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-generic-icon.mjs +45 -19
- package/fesm2022/3ddv-software-division-components-generic-icon.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-generic-select.mjs +67 -23
- package/fesm2022/3ddv-software-division-components-generic-select.mjs.map +1 -1
- package/fesm2022/3ddv-software-division-components-generic-tooltip.mjs +136 -0
- package/fesm2022/3ddv-software-division-components-generic-tooltip.mjs.map +1 -0
- package/fesm2022/3ddv-software-division-components.mjs +14 -8
- package/fesm2022/3ddv-software-division-components.mjs.map +1 -1
- package/generic/braintree/braintree.component.css +7 -0
- package/host-tailwind-layer.css +7 -0
- package/package.json +81 -6
- package/shared/themes/sdc.css +68 -0
- package/styles.css +1 -1
- package/types/3ddv-software-division-components-dvm-cart.d.ts +20 -3
- package/types/3ddv-software-division-components-dvm-loader.d.ts +12 -5
- package/types/3ddv-software-division-components-dvm-map-loader.d.ts +3 -3
- package/types/3ddv-software-division-components-dvm-neighbors.d.ts +12 -6
- package/types/3ddv-software-division-components-generic-button.d.ts +2 -1
- package/types/3ddv-software-division-components-generic-dialog.d.ts +121 -49
- package/types/3ddv-software-division-components-generic-icon.d.ts +8 -2
- package/types/3ddv-software-division-components-generic-select.d.ts +12 -5
- package/types/3ddv-software-division-components-generic-tooltip.d.ts +25 -0
- package/types/3ddv-software-division-components.d.ts +10 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"3ddv-software-division-components-generic-dialog.mjs","sources":["../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-overlay.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-close.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-content.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-description.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-footer.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-header.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-title.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog.service.ts","../../generic/dialog/libs/ui-dialog-helm/src/index.ts","../../generic/dialog/dialog.component.ts","../../generic/dialog/dialog.component.html","../../generic/dialog/public-api.ts","../../generic/dialog/3ddv-software-division-components-generic-dialog.ts"],"sourcesContent":["import { computed, Directive, effect, input, untracked } from '@angular/core';\nimport { hlm, injectCustomClassSettable } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\nexport const hlmDialogOverlayClass =\n 'bg-black/50 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0';\n\n@Directive({\n selector: '[hlmDialogOverlay],brn-dialog-overlay[hlm]',\n})\nexport class HlmDialogOverlay {\n private readonly _classSettable = injectCustomClassSettable({ optional: true, host: true });\n\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected readonly _computedClass = computed(() => hlm(hlmDialogOverlayClass, this.userClass()));\n\n constructor() {\n effect(() => {\n const newClass = this._computedClass();\n untracked(() => this._classSettable?.setClassToCustomElement(newClass));\n });\n }\n}\n","import { ChangeDetectionStrategy, Component, forwardRef, ViewEncapsulation } from '@angular/core';\nimport { BrnDialog, BrnDialogOverlay, provideBrnDialogDefaultOptions } from '@spartan-ng/brain/dialog';\nimport { HlmDialogOverlay } from './hlm-dialog-overlay';\n\n@Component({\n selector: 'hlm-dialog',\n\n imports: [BrnDialogOverlay, HlmDialogOverlay],\n providers: [\n {\n provide: BrnDialog,\n useExisting: forwardRef(() => HlmDialog),\n },\n provideBrnDialogDefaultOptions({\n hasBackdrop: true,\n disableClose: false,\n closeOnBackdropClick: true,\n closeOnOutsidePointerEvents: true,\n scrollStrategy: 'reposition',\n attachPositions: [{ originX: 'center', originY: 'center', overlayX: 'center', overlayY: 'center' }],\n }),\n ],\n template: `\n <brn-dialog-overlay hlm />\n <ng-content />\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n exportAs: 'hlmDialog',\n})\nexport class HlmDialog extends BrnDialog {}\n","import { computed, Directive, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\n@Directive({\n selector: '[hlmDialogClose],[brnDialogClose][hlm]',\n host: {\n '[class]': '_computedClass()',\n },\n})\nexport class HlmDialogClose {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n\n protected readonly _computedClass = computed(() =>\n hlm(\n 'absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground',\n this.userClass()\n )\n );\n}\n","import { HlmIcon } from '@3ddv/software-division-components/generic/icon';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n ComponentRef,\n computed,\n inject,\n input,\n ViewChild,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport { NgIcon, provideIcons } from '@ng-icons/core';\nimport { lucideX } from '@ng-icons/lucide';\nimport { hlm } from '@spartan-ng/brain/core';\nimport { BrnDialogClose, BrnDialogRef, injectBrnDialogContext } from '@spartan-ng/brain/dialog';\nimport type { ClassValue } from 'clsx';\nimport { HlmDialogClose } from './hlm-dialog-close';\n\n@Component({\n selector: 'hlm-dialog-content',\n imports: [BrnDialogClose, HlmDialogClose, NgIcon, HlmIcon],\n providers: [provideIcons({ lucideX })],\n host: {\n '[class]': '_computedClass()',\n '[attr.data-state]': 'state()',\n },\n template: `\n @if (component) {\n <ng-container #outlet />\n } @else {\n <ng-content />\n }\n\n <button brnDialogClose class=\"animated-button\" hlm>\n <span class=\"sr-only\">Close</span>\n <ng-icon hlm name=\"lucideX\" size=\"sm\" />\n </button>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class HlmDialogContent implements AfterViewInit {\n private readonly _dialogRef = inject(BrnDialogRef);\n private readonly _dialogContext = injectBrnDialogContext({ optional: true });\n\n @ViewChild('outlet', { read: ViewContainerRef }) private readonly _outlet!: ViewContainerRef;\n\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n public readonly fitContent = input<boolean>(false);\n public projectedRef: ComponentRef<unknown> | null = null;\n\n public readonly state = computed(() => this._dialogRef?.state() ?? 'closed');\n public readonly componentInputs = computed(() => {\n const { $component, $dynamicComponentClass, $fitContent, close, ...rest } = this._dialogContext;\n return rest;\n });\n protected readonly _computedClass = computed(() =>\n hlm(\n 'border-border grid w-full relative gap-4 border bg-white p-6 shadow-lg [animation-duration:200] data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-top-[2%] data-[state=open]:slide-in-from-top-[2%] rounded-lg md:w-full',\n this.userClass(),\n this.fitContent() || this._fitContent ? '' : 'max-w-lg',\n this._dynamicComponentClass\n )\n );\n\n public readonly component = this._dialogContext?.$component;\n private readonly _dynamicComponentClass = this._dialogContext?.$dynamicComponentClass;\n private readonly _fitContent = this._dialogContext?.$fitContent ?? false;\n\n public ngAfterViewInit(): void {\n if (!this.component || !this._outlet) {\n return;\n }\n this.projectedRef = this._outlet.createComponent(this.component);\n for (const [key, value] of Object.entries(this.componentInputs())) {\n this.projectedRef.setInput(key, value);\n }\n }\n}\n","import { computed, Directive, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport { BrnDialogDescription } from '@spartan-ng/brain/dialog';\nimport type { ClassValue } from 'clsx';\n\n@Directive({\n selector: '[hlmDialogDescription]',\n\n host: {\n '[class]': '_computedClass()',\n },\n hostDirectives: [BrnDialogDescription],\n})\nexport class HlmDialogDescription {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected readonly _computedClass = computed(() => hlm('text-sm text-muted-foreground', this.userClass()));\n}\n","import { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\n@Component({\n selector: 'hlm-dialog-footer',\n\n template: ` <ng-content /> `,\n host: {\n '[class]': '_computedClass()',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class HlmDialogFooter {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected _computedClass = computed(() =>\n hlm('flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2', this.userClass())\n );\n}\n","import { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\n@Component({\n selector: 'hlm-dialog-header',\n\n template: ` <ng-content /> `,\n host: {\n '[class]': '_computedClass()',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class HlmDialogHeader {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected _computedClass = computed(() =>\n hlm('flex flex-col space-y-1.5 text-center sm:text-left', this.userClass())\n );\n}\n","import { computed, Directive, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport { BrnDialogTitle } from '@spartan-ng/brain/dialog';\nimport type { ClassValue } from 'clsx';\n\n@Directive({\n selector: '[hlmDialogTitle]',\n\n host: {\n '[class]': '_computedClass()',\n },\n hostDirectives: [BrnDialogTitle],\n})\nexport class HlmDialogTitle {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected readonly _computedClass = computed(() =>\n hlm('text-lg font-semibold leading-none tracking-tight', this.userClass())\n );\n}\n","import type { ComponentType } from '@angular/cdk/portal';\nimport { inject, Injectable, OutputEmitterRef, signal, TemplateRef } from '@angular/core';\nimport {\n BrnDialog,\n type BrnDialogOptions,\n BrnDialogRef,\n BrnDialogService,\n cssClassesToArray,\n DEFAULT_BRN_DIALOG_OPTIONS,\n} from '@spartan-ng/brain/dialog';\nimport { HlmDialogContent } from './hlm-dialog-content';\nimport { hlmDialogOverlayClass } from './hlm-dialog-overlay';\n\nexport type HlmDialogOptions<DialogContext = unknown> = BrnDialogOptions & {\n contentClass?: string;\n fitContent?: boolean;\n context?: DialogContext;\n};\n\nexport type OutputsOf<T> = {\n [K in keyof T as T[K] extends OutputEmitterRef<any> ? K : never]: T[K];\n};\n\n@Injectable({\n providedIn: 'root',\n})\nexport class HlmDialogService {\n public ref = signal<BrnDialogRef<any> | null>(null);\n public component = signal<BrnDialog | null>(null);\n private readonly _brnDialogService = inject(BrnDialogService);\n\n public open<T = unknown>(\n component: ComponentType<T> | TemplateRef<T>,\n options?: Partial<HlmDialogOptions>\n ): { reference: BrnDialogRef<any>; outputs: OutputsOf<T> | null } {\n if (options) {\n options.panelClass = 'dialog-overlay-margin';\n } else {\n options = { panelClass: 'dialog-overlay-margin' };\n }\n\n const mergedOptions = {\n ...DEFAULT_BRN_DIALOG_OPTIONS,\n ...options,\n backdropClass: cssClassesToArray(`${hlmDialogOverlayClass} ${options?.backdropClass ?? ''} dialog-container`),\n context: {\n ...(typeof options?.context === 'object' && options?.context !== null ? options.context : {}),\n $component: component,\n $dynamicComponentClass: options?.contentClass,\n $fitContent: options?.fitContent,\n },\n };\n const reference = this._brnDialogService.open(HlmDialogContent, undefined, mergedOptions.context, mergedOptions);\n this.ref.set(reference);\n\n const cdkRef = (reference as any)._cdkDialogRef;\n cdkRef?.componentRef?.changeDetectorRef?.detectChanges();\n\n const contentInstance = cdkRef?.componentRef?.instance as HlmDialogContent;\n const instance = contentInstance?.projectedRef?.instance as T | undefined;\n\n // We only expose the component outputs here\n let outputs: OutputsOf<T> | null = null;\n if (instance) {\n const result = {} as Record<string, unknown>;\n for (const key of Object.getOwnPropertyNames(instance)) {\n if ((instance as any)[key] instanceof OutputEmitterRef) {\n result[key] = (instance as any)[key];\n }\n }\n outputs = result as OutputsOf<T>;\n }\n\n return { reference, outputs };\n }\n\n public close(): void {\n if (!this.ref()) {\n return;\n }\n\n this.ref()?.close();\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { HlmDialog } from './lib/hlm-dialog';\nimport { HlmDialogClose } from './lib/hlm-dialog-close';\nimport { HlmDialogContent } from './lib/hlm-dialog-content';\nimport { HlmDialogDescription } from './lib/hlm-dialog-description';\nimport { HlmDialogFooter } from './lib/hlm-dialog-footer';\nimport { HlmDialogHeader } from './lib/hlm-dialog-header';\nimport { HlmDialogOverlay } from './lib/hlm-dialog-overlay';\nimport { HlmDialogTitle } from './lib/hlm-dialog-title';\n\nexport * from './lib/hlm-dialog';\nexport * from './lib/hlm-dialog-close';\nexport * from './lib/hlm-dialog-content';\nexport * from './lib/hlm-dialog-description';\nexport * from './lib/hlm-dialog-footer';\nexport * from './lib/hlm-dialog-header';\nexport * from './lib/hlm-dialog-overlay';\nexport * from './lib/hlm-dialog-title';\nexport * from './lib/hlm-dialog.service';\n\nexport const HlmDialogImports = [\n HlmDialog,\n HlmDialogClose,\n HlmDialogContent,\n HlmDialogDescription,\n HlmDialogFooter,\n HlmDialogHeader,\n HlmDialogOverlay,\n HlmDialogTitle,\n] as const;\n\n@NgModule({\n // imports: [...HlmDialogImports],\n // exports: [...HlmDialogImports],\n})\nexport class HlmDialogModule {}\n","import { ChangeDetectionStrategy, Component, effect, inject, input, viewChild } from '@angular/core';\nimport { BrnDialog } from '@spartan-ng/brain/dialog';\nimport { HlmDialog, HlmDialogContent, HlmDialogService } from './libs/ui-dialog-helm/src';\n\n@Component({\n selector: 'sdc-dialog',\n imports: [HlmDialogContent, HlmDialog],\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './dialog.component.html',\n})\nexport class DialogComponent {\n public dialogService = inject(HlmDialogService);\n public dialogComponent = viewChild(BrnDialog);\n public fitContent = input<boolean>(false);\n\n public constructor() {\n effect(() => {\n this.dialogService.component.set(this.dialogComponent() ?? null);\n });\n }\n}\n","<hlm-dialog #dialogRef>\n <hlm-dialog-content *hlmDialogContent=\"let ctx\" [fitContent]=\"fitContent()\" class=\"dialog-content\" />\n</hlm-dialog>\n","/*\n * Public API Surface of software-division-components\n */\n\nexport * from './dialog.component';\nexport * from './libs/ui-dialog-helm/src';\nexport { HlmDialogService as DialogService } from './libs/ui-dialog-helm/src/lib/hlm-dialog.service';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;AAIO,MAAM,qBAAqB,GAChC;MAKW,gBAAgB,CAAA;AACV,IAAA,cAAc,GAAG,yBAAyB,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;IAE3E,SAAS,GAAG,KAAK,CAAa,EAAE,sDAAI,KAAK,EAAE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,EAAA,EAAA,CAAA;;AEZ9C;;AAEG;;ACFH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"3ddv-software-division-components-generic-dialog.mjs","sources":["../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-overlay.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-close.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-content.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-description.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-footer.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-header.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-title.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog-overlay-pane.ts","../../generic/dialog/libs/ui-dialog-helm/src/lib/hlm-dialog.service.ts","../../generic/dialog/libs/ui-dialog-helm/src/index.ts","../../generic/dialog/dialog.component.ts","../../generic/dialog/dialog.component.html","../../generic/dialog/public-api.ts","../../generic/dialog/3ddv-software-division-components-generic-dialog.ts"],"sourcesContent":["import { computed, Directive, effect, input, untracked } from '@angular/core';\nimport { hlm, injectCustomClassSettable } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\nexport const hlmDialogOverlayClass =\n 'bg-black/50 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0';\n\n@Directive({\n selector: '[hlmDialogOverlay],brn-dialog-overlay[hlm]',\n})\nexport class HlmDialogOverlay {\n private readonly _classSettable = injectCustomClassSettable({ optional: true, host: true });\n\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected readonly _computedClass = computed(() => hlm(hlmDialogOverlayClass, this.userClass()));\n\n constructor() {\n effect(() => {\n const newClass = this._computedClass();\n untracked(() => this._classSettable?.setClassToCustomElement(newClass));\n });\n }\n}\n","import { ChangeDetectionStrategy, Component, forwardRef, ViewEncapsulation } from '@angular/core';\nimport { BrnDialog, BrnDialogOverlay, provideBrnDialogDefaultOptions } from '@spartan-ng/brain/dialog';\nimport { HlmDialogOverlay } from './hlm-dialog-overlay';\n\n@Component({\n selector: 'hlm-dialog',\n\n imports: [BrnDialogOverlay, HlmDialogOverlay],\n providers: [\n {\n provide: BrnDialog,\n useExisting: forwardRef(() => HlmDialog),\n },\n provideBrnDialogDefaultOptions({\n hasBackdrop: true,\n disableClose: false,\n closeOnBackdropClick: true,\n closeOnOutsidePointerEvents: true,\n scrollStrategy: 'reposition',\n attachPositions: [{ originX: 'center', originY: 'center', overlayX: 'center', overlayY: 'center' }],\n }),\n ],\n template: `\n <brn-dialog-overlay hlm />\n <ng-content />\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n exportAs: 'hlmDialog',\n})\nexport class HlmDialog extends BrnDialog {}\n","import { computed, Directive, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\n@Directive({\n selector: '[hlmDialogClose],[brnDialogClose][hlm]',\n host: {\n '[class]': '_computedClass()',\n },\n})\nexport class HlmDialogClose {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n\n protected readonly _computedClass = computed(() =>\n hlm(\n 'absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground',\n this.userClass()\n )\n );\n}\n","import { HlmIcon } from '@3ddv/software-division-components/generic/icon';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n ComponentRef,\n computed,\n inject,\n input,\n ViewChild,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport { NgIcon, provideIcons } from '@ng-icons/core';\nimport { lucideX } from '@ng-icons/lucide';\nimport { hlm } from '@spartan-ng/brain/core';\nimport { BrnDialogClose, BrnDialogRef, injectBrnDialogContext } from '@spartan-ng/brain/dialog';\nimport type { ClassValue } from 'clsx';\nimport { HlmDialogClose } from './hlm-dialog-close';\n\n@Component({\n selector: 'hlm-dialog-content',\n imports: [BrnDialogClose, HlmDialogClose, NgIcon, HlmIcon],\n providers: [provideIcons({ lucideX })],\n host: {\n '[class]': '_computedClass()',\n '[attr.data-state]': 'state()',\n },\n template: `\n @if (component) {\n <ng-container #outlet />\n } @else {\n <ng-content />\n }\n\n @if (effectiveShowCloseButton()) {\n <button brnDialogClose class=\"animated-button\" hlm type=\"button\">\n <span class=\"sr-only\">Close</span>\n <ng-icon hlm name=\"lucideX\" size=\"sm\" />\n </button>\n }\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class HlmDialogContent implements AfterViewInit {\n private readonly _dialogRef = inject(BrnDialogRef);\n private readonly _dialogContext = injectBrnDialogContext({ optional: true });\n\n @ViewChild('outlet', { read: ViewContainerRef }) private readonly _outlet!: ViewContainerRef;\n\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n public readonly fitContent = input<boolean>(false);\n /** When false, the panel close (X) control is not rendered. Default true. Overridden by dialog open context `$showCloseButton` when set. */\n public readonly showCloseButton = input<boolean>(true);\n public projectedRef: ComponentRef<unknown> | null = null;\n\n public readonly state = computed(() => this._dialogRef?.state() ?? 'closed');\n public readonly componentInputs = computed(() => {\n const rawContext = this._dialogContext;\n if (rawContext == null || typeof rawContext !== 'object') {\n return {};\n }\n const { $component, $dynamicComponentClass, $fitContent, $showCloseButton, close, ...rest } = rawContext as Record<\n string,\n unknown\n >;\n return rest;\n });\n protected readonly _computedClass = computed(() =>\n hlm(\n 'grid w-full relative gap-4 border-0 bg-white p-6 shadow-lg outline-none ring-0 [animation-duration:200] data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-top-[2%] data-[state=open]:slide-in-from-top-[2%] rounded-lg md:w-full',\n this.userClass(),\n this.fitContent() || this._fitContent ? '' : 'max-w-lg',\n this._dynamicComponentClass\n )\n );\n\n public readonly component = this._dialogContext?.$component;\n private readonly _dynamicComponentClass = this._dialogContext?.$dynamicComponentClass;\n private readonly _fitContent = this._dialogContext?.$fitContent ?? false;\n\n public readonly effectiveShowCloseButton = computed(() => {\n const ctx = this._dialogContext as { $showCloseButton?: boolean } | null | undefined;\n const fromContext =\n ctx != null && typeof ctx === 'object' && '$showCloseButton' in ctx ? ctx.$showCloseButton : undefined;\n if (typeof fromContext === 'boolean') {\n return fromContext;\n }\n return this.showCloseButton();\n });\n\n public ngAfterViewInit(): void {\n if (!this.component || !this._outlet) {\n return;\n }\n this.projectedRef = this._outlet.createComponent(this.component);\n for (const [key, value] of Object.entries(this.componentInputs())) {\n this.projectedRef.setInput(key, value);\n }\n }\n}\n","import { computed, Directive, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport { BrnDialogDescription } from '@spartan-ng/brain/dialog';\nimport type { ClassValue } from 'clsx';\n\n@Directive({\n selector: '[hlmDialogDescription]',\n\n host: {\n '[class]': '_computedClass()',\n },\n hostDirectives: [BrnDialogDescription],\n})\nexport class HlmDialogDescription {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected readonly _computedClass = computed(() => hlm('text-sm text-muted-foreground', this.userClass()));\n}\n","import { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\n@Component({\n selector: 'hlm-dialog-footer',\n\n template: ` <ng-content /> `,\n host: {\n '[class]': '_computedClass()',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class HlmDialogFooter {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected _computedClass = computed(() =>\n hlm('flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2', this.userClass())\n );\n}\n","import { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport type { ClassValue } from 'clsx';\n\n@Component({\n selector: 'hlm-dialog-header',\n\n template: ` <ng-content /> `,\n host: {\n '[class]': '_computedClass()',\n },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class HlmDialogHeader {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected _computedClass = computed(() =>\n hlm('flex flex-col space-y-1.5 text-center sm:text-left', this.userClass())\n );\n}\n","import { computed, Directive, input } from '@angular/core';\nimport { hlm } from '@spartan-ng/brain/core';\nimport { BrnDialogTitle } from '@spartan-ng/brain/dialog';\nimport type { ClassValue } from 'clsx';\n\n@Directive({\n selector: '[hlmDialogTitle]',\n\n host: {\n '[class]': '_computedClass()',\n },\n hostDirectives: [BrnDialogTitle],\n})\nexport class HlmDialogTitle {\n public readonly userClass = input<ClassValue>('', { alias: 'class' });\n protected readonly _computedClass = computed(() =>\n hlm('text-lg font-semibold leading-none tracking-tight', this.userClass())\n );\n}\n","/**\n * CDK overlay pane sizing (Angular CDK applies this via `OverlayRef.updateSize`).\n * Configure from the host app using `DialogService.open({ ... })`, `sdc-dialog` inputs,\n * or CSS custom properties on `sdc-dialog` (see `readOverlayPaneCssVars`).\n */\nexport type HlmOverlayPaneSize = {\n width?: string;\n maxWidth?: string;\n height?: string;\n maxHeight?: string;\n};\n\n/** CSS custom properties read from `sdc-dialog` (or any host element). */\nexport const SDC_DIALOG_PANE_CSS_VARS = {\n width: '--sdc-dialog-pane-width',\n maxWidth: '--sdc-dialog-pane-max-width',\n height: '--sdc-dialog-pane-height',\n maxHeight: '--sdc-dialog-pane-max-height',\n} as const;\n\nexport function readOverlayPaneCssVars(host: HTMLElement): HlmOverlayPaneSize {\n const computed = getComputedStyle(host);\n const read = (varName: string): string | undefined => {\n const raw = computed.getPropertyValue(varName).trim();\n return raw === '' ? undefined : raw;\n };\n return {\n width: read(SDC_DIALOG_PANE_CSS_VARS.width),\n maxWidth: read(SDC_DIALOG_PANE_CSS_VARS.maxWidth),\n height: read(SDC_DIALOG_PANE_CSS_VARS.height),\n maxHeight: read(SDC_DIALOG_PANE_CSS_VARS.maxHeight),\n };\n}\n\nexport function pickOverlayPaneFromOptions(options?: {\n overlayPaneWidth?: string;\n overlayPaneMaxWidth?: string;\n overlayPaneHeight?: string;\n overlayPaneMaxHeight?: string;\n}): HlmOverlayPaneSize {\n if (!options) {\n return {};\n }\n const size: HlmOverlayPaneSize = {};\n if (options.overlayPaneWidth !== undefined && options.overlayPaneWidth !== '') {\n size.width = options.overlayPaneWidth;\n }\n if (options.overlayPaneMaxWidth !== undefined && options.overlayPaneMaxWidth !== '') {\n size.maxWidth = options.overlayPaneMaxWidth;\n }\n if (options.overlayPaneHeight !== undefined && options.overlayPaneHeight !== '') {\n size.height = options.overlayPaneHeight;\n }\n if (options.overlayPaneMaxHeight !== undefined && options.overlayPaneMaxHeight !== '') {\n size.maxHeight = options.overlayPaneMaxHeight;\n }\n return size;\n}\n\nexport function mergeOverlayPaneSizes(...layers: HlmOverlayPaneSize[]): HlmOverlayPaneSize {\n const merged: HlmOverlayPaneSize = {};\n for (const layer of layers) {\n for (const key of ['width', 'maxWidth', 'height', 'maxHeight'] as const) {\n const v = layer[key];\n if (v !== undefined && v !== '') {\n merged[key] = v;\n }\n }\n }\n return merged;\n}\n\nexport function overlayPaneSizeToUpdateConfig(size: HlmOverlayPaneSize): {\n width?: string;\n maxWidth?: string;\n height?: string;\n maxHeight?: string;\n} {\n const cfg: { width?: string; maxWidth?: string; height?: string; maxHeight?: string } = {};\n if (size.width !== undefined) {\n cfg.width = size.width;\n }\n if (size.maxWidth !== undefined) {\n cfg.maxWidth = size.maxWidth;\n }\n if (size.height !== undefined) {\n cfg.height = size.height;\n }\n if (size.maxHeight !== undefined) {\n cfg.maxHeight = size.maxHeight;\n }\n return cfg;\n}\n","import type { ComponentType } from '@angular/cdk/portal';\nimport { inject, Injectable, OutputEmitterRef, signal, TemplateRef } from '@angular/core';\nimport {\n BrnDialog,\n BrnDialogRef,\n BrnDialogService,\n cssClassesToArray,\n DEFAULT_BRN_DIALOG_OPTIONS,\n type BrnDialogOptions,\n} from '@spartan-ng/brain/dialog';\nimport { HlmDialogContent } from './hlm-dialog-content';\nimport { hlmDialogOverlayClass } from './hlm-dialog-overlay';\nimport {\n mergeOverlayPaneSizes,\n overlayPaneSizeToUpdateConfig,\n pickOverlayPaneFromOptions,\n readOverlayPaneCssVars,\n type HlmOverlayPaneSize,\n} from './hlm-dialog-overlay-pane';\n\nexport type { HlmOverlayPaneSize } from './hlm-dialog-overlay-pane';\n\nexport type HlmDialogOptions<DialogContext = unknown> = BrnDialogOptions & {\n contentClass?: string;\n fitContent?: boolean;\n showCloseButton?: boolean;\n context?: DialogContext;\n /**\n * CDK overlay pane size (see `HlmOverlayPaneSize`). Overrides defaults from `sdc-dialog` inputs / CSS vars.\n * Spartan does not forward these to CDK; applied via `OverlayRef.updateSize`.\n */\n overlayPaneWidth?: string;\n overlayPaneMaxWidth?: string;\n overlayPaneHeight?: string;\n overlayPaneMaxHeight?: string;\n};\n\nexport type OutputsOf<T> = {\n [K in keyof T as T[K] extends OutputEmitterRef<any> ? K : never]: T[K];\n};\n\n@Injectable({\n providedIn: 'root',\n})\nexport class HlmDialogService {\n public ref = signal<BrnDialogRef<any> | null>(null);\n public component = signal<BrnDialog | null>(null);\n /**\n * Host element of `sdc-dialog`; used to read `--sdc-dialog-pane-*` CSS variables on each `open()`.\n * Registered by `DialogComponent`; expect a single dialog host per app.\n */\n public readonly hostElement = signal<HTMLElement | null>(null);\n /**\n * Default overlay pane size from `sdc-dialog` inputs. Overridden per `open()` and by CSS vars\n * when defined on the host (merge order: CSS vars → this signal → `open()` options).\n */\n public readonly defaultOverlayPaneSize = signal<HlmOverlayPaneSize>({});\n\n private readonly _brnDialogService = inject(BrnDialogService);\n\n /**\n * Clears host registration when the active `sdc-dialog` is destroyed (single-host apps).\n */\n public releaseHostIfMatch(host: HTMLElement): void {\n if (this.hostElement() === host) {\n this.hostElement.set(null);\n this.defaultOverlayPaneSize.set({});\n }\n }\n\n public open<T = unknown>(\n component: ComponentType<T> | TemplateRef<T>,\n options?: Partial<HlmDialogOptions>\n ): { reference: BrnDialogRef<any>; outputs: OutputsOf<T> | null } {\n if (options) {\n options.panelClass = 'dialog-overlay-margin';\n } else {\n options = { panelClass: 'dialog-overlay-margin' };\n }\n\n const baseContext = typeof options?.context === 'object' && options?.context !== null ? options.context : {};\n const showCloseFromContext =\n baseContext &&\n typeof baseContext === 'object' &&\n '$showCloseButton' in baseContext &&\n typeof (baseContext as { $showCloseButton: unknown }).$showCloseButton === 'boolean'\n ? (baseContext as { $showCloseButton: boolean }).$showCloseButton\n : undefined;\n const resolvedShowCloseButton =\n options?.showCloseButton !== undefined ? options.showCloseButton : (showCloseFromContext ?? true);\n\n const mergedOptions = {\n ...DEFAULT_BRN_DIALOG_OPTIONS,\n ...options,\n backdropClass: cssClassesToArray(`${hlmDialogOverlayClass} ${options?.backdropClass ?? ''} dialog-container`),\n context: {\n ...baseContext,\n $component: component,\n $dynamicComponentClass: options?.contentClass,\n $fitContent: options?.fitContent,\n $showCloseButton: resolvedShowCloseButton,\n },\n };\n const reference = this._brnDialogService.open(HlmDialogContent, undefined, mergedOptions.context, mergedOptions);\n this.ref.set(reference);\n\n const cdkRef = (reference as any)._cdkDialogRef;\n const host = this.hostElement();\n const fromCss = host ? readOverlayPaneCssVars(host) : {};\n const fromInputs = this.defaultOverlayPaneSize();\n const fromOpen = pickOverlayPaneFromOptions(options);\n const resolvedPane = mergeOverlayPaneSizes(fromCss, fromInputs, fromOpen);\n const updateCfg = overlayPaneSizeToUpdateConfig(resolvedPane);\n if (Object.keys(updateCfg).length > 0) {\n cdkRef?.overlayRef?.updateSize(updateCfg);\n }\n cdkRef?.componentRef?.changeDetectorRef?.detectChanges();\n\n const contentInstance = cdkRef?.componentRef?.instance as HlmDialogContent;\n const instance = contentInstance?.projectedRef?.instance as T | undefined;\n\n let outputs: OutputsOf<T> | null = null;\n if (instance) {\n const result = {} as Record<string, unknown>;\n for (const key of Object.getOwnPropertyNames(instance)) {\n if ((instance as any)[key] instanceof OutputEmitterRef) {\n result[key] = (instance as any)[key];\n }\n }\n outputs = result as OutputsOf<T>;\n }\n\n return { reference, outputs };\n }\n\n public close(): void {\n if (!this.ref()) {\n return;\n }\n\n this.ref()?.close();\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { HlmDialog } from './lib/hlm-dialog';\nimport { HlmDialogClose } from './lib/hlm-dialog-close';\nimport { HlmDialogContent } from './lib/hlm-dialog-content';\nimport { HlmDialogDescription } from './lib/hlm-dialog-description';\nimport { HlmDialogFooter } from './lib/hlm-dialog-footer';\nimport { HlmDialogHeader } from './lib/hlm-dialog-header';\nimport { HlmDialogOverlay } from './lib/hlm-dialog-overlay';\nimport { HlmDialogTitle } from './lib/hlm-dialog-title';\n\nexport * from './lib/hlm-dialog';\nexport * from './lib/hlm-dialog-close';\nexport * from './lib/hlm-dialog-content';\nexport * from './lib/hlm-dialog-description';\nexport * from './lib/hlm-dialog-footer';\nexport * from './lib/hlm-dialog-header';\nexport * from './lib/hlm-dialog-overlay';\nexport * from './lib/hlm-dialog-overlay-pane';\nexport * from './lib/hlm-dialog-title';\nexport * from './lib/hlm-dialog.service';\n\nexport const HlmDialogImports = [\n HlmDialog,\n HlmDialogClose,\n HlmDialogContent,\n HlmDialogDescription,\n HlmDialogFooter,\n HlmDialogHeader,\n HlmDialogOverlay,\n HlmDialogTitle,\n] as const;\n\n@NgModule({\n // imports: [...HlmDialogImports],\n // exports: [...HlmDialogImports],\n})\nexport class HlmDialogModule {}\n","import {\n ChangeDetectionStrategy,\n Component,\n effect,\n ElementRef,\n inject,\n input,\n OnDestroy,\n viewChild,\n} from '@angular/core';\nimport { BrnDialog } from '@spartan-ng/brain/dialog';\nimport type { HlmOverlayPaneSize } from './libs/ui-dialog-helm/src';\nimport { HlmDialog, HlmDialogContent, HlmDialogService } from './libs/ui-dialog-helm/src';\n\n@Component({\n selector: 'sdc-dialog',\n imports: [HlmDialogContent, HlmDialog],\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './dialog.component.html',\n})\nexport class DialogComponent implements OnDestroy {\n public dialogService = inject(HlmDialogService);\n public dialogComponent = viewChild(BrnDialog);\n\n private readonly hostEl = inject<ElementRef<HTMLElement>>(ElementRef);\n\n public fitContent = input<boolean>(false);\n public showCloseButton = input<boolean>(true);\n\n /**\n * Default CDK overlay pane width (e.g. `800px`). Merge order: CSS vars on `sdc-dialog` → these inputs →\n * `DialogService.open({ overlayPaneWidth, ... })` (strongest).\n */\n public overlayPaneWidth = input<string | undefined>(undefined);\n public overlayPaneMaxWidth = input<string | undefined>(undefined);\n public overlayPaneHeight = input<string | undefined>(undefined);\n public overlayPaneMaxHeight = input<string | undefined>(undefined);\n\n public constructor() {\n effect(() => {\n this.dialogService.component.set(this.dialogComponent() ?? null);\n this.dialogService.hostElement.set(this.hostEl.nativeElement);\n\n const size: HlmOverlayPaneSize = {};\n const w = this.overlayPaneWidth();\n const maxW = this.overlayPaneMaxWidth();\n const h = this.overlayPaneHeight();\n const maxH = this.overlayPaneMaxHeight();\n if (w !== undefined && w !== '') {\n size.width = w;\n }\n if (maxW !== undefined && maxW !== '') {\n size.maxWidth = maxW;\n }\n if (h !== undefined && h !== '') {\n size.height = h;\n }\n if (maxH !== undefined && maxH !== '') {\n size.maxHeight = maxH;\n }\n this.dialogService.defaultOverlayPaneSize.set(size);\n });\n }\n\n public ngOnDestroy(): void {\n this.dialogService.releaseHostIfMatch(this.hostEl.nativeElement);\n }\n}\n","<hlm-dialog #dialogRef>\n <hlm-dialog-content\n *hlmDialogContent=\"let ctx\"\n [fitContent]=\"fitContent()\"\n [showCloseButton]=\"showCloseButton()\"\n class=\"dialog-content\" />\n</hlm-dialog>\n","/*\n * Public API Surface of software-division-components\n */\n\nexport * from './dialog.component';\nexport * from './libs/ui-dialog-helm/src';\nexport { HlmDialogService as DialogService } from './libs/ui-dialog-helm/src/lib/hlm-dialog.service';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;AAIO,MAAM,qBAAqB,GAChC;MAKW,gBAAgB,CAAA;AACV,IAAA,cAAc,GAAG,yBAAyB,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;IAE3E,SAAS,GAAG,KAAK,CAAa,EAAE,sDAAI,KAAK,EAAE,OAAO,EAAA,CAAG;AAClD,IAAA,cAAc,GAAG,QAAQ,CAAC,MAAM,GAAG,CAAC,qBAAqB,EAAE,IAAI,CAAC,SAAS,EAAE,CAAC,0DAAC;AAEhG,IAAA,WAAA,GAAA;QACE,MAAM,CAAC,MAAK;AACV,YAAA,MAAM,QAAQ,GAAG,IAAI,CAAC,cAAc,EAAE;AACtC,YAAA,SAAS,CAAC,MAAM,IAAI,CAAC,cAAc,EAAE,uBAAuB,CAAC,QAAQ,CAAC,CAAC;AACzE,QAAA,CAAC,CAAC;IACJ;uGAXW,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAhB,gBAAgB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,4CAAA,EAAA,MAAA,EAAA,EAAA,SAAA,EAAA,EAAA,iBAAA,EAAA,WAAA,EAAA,UAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAhB,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAH5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,4CAA4C;AACvD,iBAAA;;;ACqBK,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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,gBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,kBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,mBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,qBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,iBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,mBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,oBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,sBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AEtB9C;;AAEG;;ACFH;;AAEG;;;;"}
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
-
import { HttpClient } from '@angular/common/http';
|
|
1
|
+
import { HttpClient, HttpBackend } from '@angular/common/http';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { inject, ElementRef, input, signal, effect, ChangeDetectionStrategy, ViewEncapsulation, Component, InjectionToken, computed, Directive, NgModule } from '@angular/core';
|
|
4
4
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
5
5
|
import { map, shareReplay } from 'rxjs';
|
|
6
6
|
|
|
7
|
+
/** Bumped when fetch strategy changes so we do not reuse errored `shareReplay` streams. */
|
|
8
|
+
const ICON_CACHE_SCHEME = 'http-backend-v1';
|
|
7
9
|
const iconCache = new Map();
|
|
8
10
|
class SvgIconComponent {
|
|
9
|
-
// DI
|
|
10
|
-
|
|
11
|
+
// DI — use HttpClient(HttpBackend) so static SVG fetches skip app interceptors
|
|
12
|
+
httpPlain = new HttpClient(inject(HttpBackend));
|
|
11
13
|
cache = iconCache;
|
|
12
14
|
sanitizer = inject(DomSanitizer);
|
|
13
15
|
elementRef = inject(ElementRef);
|
|
@@ -16,17 +18,17 @@ class SvgIconComponent {
|
|
|
16
18
|
iconFolder = input(...(ngDevMode ? [undefined, { debugName: "iconFolder" }] : []));
|
|
17
19
|
className = input('', ...(ngDevMode ? [{ debugName: "className" }] : []));
|
|
18
20
|
color = input('currentColor', ...(ngDevMode ? [{ debugName: "color" }] : []));
|
|
19
|
-
|
|
21
|
+
/** Use `> 0` when the asset relies on stroke */
|
|
22
|
+
strokeWidth = input(0, ...(ngDevMode ? [{ debugName: "strokeWidth" }] : []));
|
|
20
23
|
// STATE
|
|
21
24
|
svgContent = signal(null, ...(ngDevMode ? [{ debugName: "svgContent" }] : []));
|
|
22
25
|
constructor() {
|
|
23
26
|
effect(() => {
|
|
24
|
-
this.
|
|
27
|
+
this.syncHostPaintVars();
|
|
28
|
+
});
|
|
29
|
+
effect(() => {
|
|
30
|
+
this.getIcon().subscribe({
|
|
25
31
|
next: svg => {
|
|
26
|
-
const element = this.elementRef.nativeElement;
|
|
27
|
-
// Apply dynamic properties
|
|
28
|
-
element.style.setProperty('--icon-color', this.resolveColor(this.color()));
|
|
29
|
-
element.style.setProperty('--icon-stroke-width', this.strokeWidth().toString());
|
|
30
32
|
this.svgContent.set(this.sanitizer.bypassSecurityTrustHtml(svg));
|
|
31
33
|
},
|
|
32
34
|
error: (error) => {
|
|
@@ -38,22 +40,46 @@ class SvgIconComponent {
|
|
|
38
40
|
});
|
|
39
41
|
});
|
|
40
42
|
}
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
43
|
+
syncHostPaintVars() {
|
|
44
|
+
const element = this.elementRef.nativeElement;
|
|
45
|
+
element.style.setProperty('--icon-color', this.resolveColor(this.color()));
|
|
46
|
+
const sw = this.strokeWidth();
|
|
47
|
+
if (sw > 0) {
|
|
48
|
+
element.classList.add('sdc-svg-icon--stroke');
|
|
49
|
+
element.style.setProperty('--icon-stroke-width', String(sw));
|
|
50
|
+
}
|
|
51
|
+
else {
|
|
52
|
+
element.classList.remove('sdc-svg-icon--stroke');
|
|
53
|
+
element.style.removeProperty('--icon-stroke-width');
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Cache key must include folder: the same `name` can exist under different paths
|
|
58
|
+
* (e.g. `assets/x.svg` vs `assets/img/x.svg`). Caching by name alone poisoned later loads.
|
|
59
|
+
*/
|
|
60
|
+
getIcon() {
|
|
61
|
+
const folder = this.iconFolder() ?? 'assets';
|
|
62
|
+
const iconName = this.name();
|
|
63
|
+
const cacheKey = `${ICON_CACHE_SCHEME}:${folder}/${iconName}`;
|
|
64
|
+
if (!this.cache.has(cacheKey)) {
|
|
65
|
+
const icon$ = this.httpPlain.get(`/${folder}/${iconName}.svg`, { responseType: 'text' }).pipe(map((svg) => this.sanitizeSvg(svg)), shareReplay({ bufferSize: 1, refCount: true }));
|
|
66
|
+
this.cache.set(cacheKey, icon$);
|
|
46
67
|
}
|
|
47
|
-
return this.cache.get(
|
|
68
|
+
return this.cache.get(cacheKey);
|
|
48
69
|
}
|
|
49
70
|
sanitizeSvg(svg) {
|
|
50
|
-
|
|
71
|
+
let out = svg
|
|
51
72
|
// Remove any existing width/height attributes to make the SVG more flexible
|
|
52
73
|
.replace(/\swidth="[^"]*"/g, '')
|
|
53
74
|
.replace(/\sheight="[^"]*"/g, '')
|
|
54
75
|
// Strip hardcoded fill/stroke so CSS variable takes effect
|
|
55
76
|
.replace(/\sfill="(?!none)[^"]*"/g, '')
|
|
56
|
-
.replace(/\sstroke="(?!none)[^"]*"/g, '')
|
|
77
|
+
.replace(/\sstroke="(?!none)[^"]*"/g, '');
|
|
78
|
+
// Avoid clipping stroke/paint at the root when assets are tight to viewBox
|
|
79
|
+
if (!/\soverflow\s*=/i.test(out)) {
|
|
80
|
+
out = out.replace(/<svg\b/i, '<svg overflow="visible" ');
|
|
81
|
+
}
|
|
82
|
+
return out;
|
|
57
83
|
}
|
|
58
84
|
/**
|
|
59
85
|
* Resolves the color input to a valid CSS value.
|
|
@@ -73,13 +99,13 @@ class SvgIconComponent {
|
|
|
73
99
|
return `var(--color-${color})`;
|
|
74
100
|
}
|
|
75
101
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: SvgIconComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
76
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.4", type: SvgIconComponent, isStandalone: true, selector: "sdc-svg-icon", inputs: { name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: true, transformFunction: null }, iconFolder: { classPropertyName: "iconFolder", publicName: "iconFolder", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, strokeWidth: { classPropertyName: "strokeWidth", publicName: "strokeWidth", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "className()" } }, ngImport: i0, template: "@if (svgContent(); as content) {\n <span class=\"
|
|
102
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.4", type: SvgIconComponent, isStandalone: true, selector: "sdc-svg-icon", inputs: { name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: true, transformFunction: null }, iconFolder: { classPropertyName: "iconFolder", publicName: "iconFolder", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, strokeWidth: { classPropertyName: "strokeWidth", publicName: "strokeWidth", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "className()" } }, ngImport: i0, template: "@if (svgContent(); as content) {\n <span class=\"sdc-svg-icon\" [innerHTML]=\"content\"></span>\n}\n", styles: [":host{display:inline-block;vertical-align:middle;line-height:0;box-sizing:border-box}.sdc-svg-icon{display:flex;align-items:center;justify-content:center;width:100%;height:100%;box-sizing:border-box}.sdc-svg-icon svg{display:block;flex-shrink:0;width:100%;height:100%;max-width:100%;max-height:100%;box-sizing:border-box;overflow:visible;fill:var(--icon-color, currentColor);stroke:none;stroke-width:0}:host(.sdc-svg-icon--stroke) .sdc-svg-icon svg{stroke:var(--icon-color, currentColor);stroke-width:var(--icon-stroke-width, 1)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
77
103
|
}
|
|
78
104
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: SvgIconComponent, decorators: [{
|
|
79
105
|
type: Component,
|
|
80
106
|
args: [{ selector: 'sdc-svg-icon', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
81
107
|
'[class]': 'className()',
|
|
82
|
-
}, template: "@if (svgContent(); as content) {\n <span class=\"
|
|
108
|
+
}, template: "@if (svgContent(); as content) {\n <span class=\"sdc-svg-icon\" [innerHTML]=\"content\"></span>\n}\n", styles: [":host{display:inline-block;vertical-align:middle;line-height:0;box-sizing:border-box}.sdc-svg-icon{display:flex;align-items:center;justify-content:center;width:100%;height:100%;box-sizing:border-box}.sdc-svg-icon svg{display:block;flex-shrink:0;width:100%;height:100%;max-width:100%;max-height:100%;box-sizing:border-box;overflow:visible;fill:var(--icon-color, currentColor);stroke:none;stroke-width:0}:host(.sdc-svg-icon--stroke) .sdc-svg-icon svg{stroke:var(--icon-color, currentColor);stroke-width:var(--icon-stroke-width, 1)}\n"] }]
|
|
83
109
|
}], ctorParameters: () => [], propDecorators: { name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: true }] }], iconFolder: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconFolder", required: false }] }], className: [{ type: i0.Input, args: [{ isSignal: true, alias: "className", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], strokeWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "strokeWidth", required: false }] }] } });
|
|
84
110
|
|
|
85
111
|
const defaultConfig = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"3ddv-software-division-components-generic-icon.mjs","sources":["../../generic/icon/icon.component.ts","../../generic/icon/icon.component.html","../../generic/icon/lib/ui-icon-helm/src/lib/hlm-icon.token.ts","../../generic/icon/lib/ui-icon-helm/src/lib/hlm-icon.ts","../../generic/icon/lib/ui-icon-helm/src/index.ts","../../generic/icon/public-api.ts","../../generic/icon/3ddv-software-division-components-generic-icon.ts"],"sourcesContent":["import { HttpClient } from '@angular/common/http';\nimport {\n ChangeDetectionStrategy,\n Component,\n effect,\n ElementRef,\n inject,\n input,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\nimport { map, Observable, shareReplay } from 'rxjs';\n\nconst iconCache = new Map<string, Observable<string>>();\n\n@Component({\n selector: 'sdc-svg-icon',\n templateUrl: './icon.component.html',\n styleUrl: './icon.component.css',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[class]': 'className()',\n },\n})\nexport class SvgIconComponent {\n // DI\n private readonly http = inject(HttpClient);\n private readonly cache = iconCache;\n private readonly sanitizer = inject(DomSanitizer);\n private readonly elementRef = inject(ElementRef);\n\n // INPUTS / OUTPUTS\n public readonly name = input.required<string>();\n public readonly iconFolder = input<string>();\n public readonly className = input<string>('');\n public readonly color = input<string>('currentColor');\n public readonly strokeWidth = input<number>(1);\n\n // STATE\n public readonly svgContent = signal<SafeHtml | null>(null);\n\n public constructor() {\n effect(() => {\n this.getIcon(this.name()).subscribe({\n next: svg => {\n const element = this.elementRef.nativeElement as HTMLElement;\n\n // Apply dynamic properties\n element.style.setProperty('--icon-color', this.resolveColor(this.color()));\n element.style.setProperty('--icon-stroke-width', this.strokeWidth().toString());\n\n this.svgContent.set(this.sanitizer.bypassSecurityTrustHtml(svg));\n },\n error: (error: unknown) => {\n console.error('Failed to load icon:', error);\n // Optional: set a minimal fallback SVG or clear content\n this.svgContent.set(\n this.sanitizer.bypassSecurityTrustHtml(\n `<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 8v4m0 4h.01\"\n stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" fill=\"none\"/></svg>`\n )\n );\n },\n });\n });\n }\n\n public getIcon(name: string): Observable<string> {\n if (!this.cache.has(name)) {\n const folder = this.iconFolder() ?? 'assets';\n const icon$ = this.http.get(`/${folder}/${name}.svg`, { responseType: 'text' }).pipe(\n map(svg => this.sanitizeSvg(svg)),\n shareReplay({ bufferSize: 1, refCount: true })\n );\n\n this.cache.set(name, icon$);\n }\n\n return this.cache.get(name)!;\n }\n\n private sanitizeSvg(svg: string): string {\n return (\n svg\n // Remove any existing width/height attributes to make the SVG more flexible\n .replace(/\\swidth=\"[^\"]*\"/g, '')\n .replace(/\\sheight=\"[^\"]*\"/g, '')\n // Strip hardcoded fill/stroke so CSS variable takes effect\n .replace(/\\sfill=\"(?!none)[^\"]*\"/g, '')\n .replace(/\\sstroke=\"(?!none)[^\"]*\"/g, '')\n );\n }\n\n /**\n * Resolves the color input to a valid CSS value.\n * - Already-valid CSS values (var(), #hex, rgb(), hsl(), currentColor) pass through unchanged.\n * - A raw CSS variable name starting with \"--\" is wrapped: \"--my-var\" → \"var(--my-var)\".\n * - Any other string is treated as a design-token name and resolved via the\n * \"--color-\" prefix convention: \"accent\" → \"var(--color-accent)\".\n */\n private resolveColor(color: string): string {\n const passThroughPrefixes = ['currentColor', 'var(', '#', 'rgb(', 'rgba(', 'hsl(', 'hsla('];\n\n if (passThroughPrefixes.some(prefix => color.startsWith(prefix))) {\n return color;\n }\n\n if (color.startsWith('--')) {\n return `var(${color})`;\n }\n\n return `var(--color-${color})`;\n }\n}\n","@if (svgContent(); as content) {\n <span class=\"inline-block app-svg-icon\" [innerHTML]=\"content\"></span>\n}\n","import { InjectionToken, ValueProvider, inject } from '@angular/core';\nimport type { IconSize } from './hlm-icon';\n\nexport interface HlmIconConfig {\n size: IconSize;\n}\n\nconst defaultConfig: HlmIconConfig = {\n size: 'base',\n};\n\nconst HlmIconConfigToken = new InjectionToken<HlmIconConfig>('HlmIconConfig');\n\nexport function provideHlmIconConfig(config: Partial<HlmIconConfig>): ValueProvider {\n return { provide: HlmIconConfigToken, useValue: { ...defaultConfig, ...config } };\n}\n\nexport function injectHlmIconConfig(): HlmIconConfig {\n return inject(HlmIconConfigToken, { optional: true }) ?? defaultConfig;\n}\n","import { Directive, computed, input } from '@angular/core';\nimport { injectHlmIconConfig } from './hlm-icon.token';\n\nexport type IconSize = 'xs' | 'sm' | 'base' | 'lg' | 'xl' | 'none' | (Record<never, never> & string);\n\n@Directive({\n selector: 'ng-icon[hlm]',\n standalone: true,\n host: {\n '[style.--ng-icon__size]': '_computedSize()',\n },\n})\nexport class HlmIcon {\n private readonly _config = injectHlmIconConfig();\n public readonly size = input<IconSize>(this._config.size);\n public readonly variant = input<'light' | 'dark'>('light');\n\n protected readonly _computedSize = computed(() => {\n const size = this.size();\n\n switch (size) {\n case 'xs':\n return '12px';\n case 'sm':\n return '16px';\n case 'base':\n return '24px';\n case 'lg':\n return '32px';\n case 'xl':\n return '48px';\n default: {\n return size;\n }\n }\n });\n}\n","import { NgModule } from '@angular/core';\nimport { HlmIcon } from './lib/hlm-icon';\n\nexport * from './lib/hlm-icon';\nexport * from './lib/hlm-icon.token';\n\n@NgModule({\n imports: [HlmIcon],\n exports: [HlmIcon],\n})\nexport class HlmIconModule {}\n","/*\n * Public API Surface of software-division-components\n */\n\nexport * from './icon.component';\nexport { HlmIcon, HlmIconModule } from './lib/ui-icon-helm/src';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAcA,MAAM,SAAS,GAAG,IAAI,GAAG,EAA8B;MAY1C,gBAAgB,CAAA;;AAEV,IAAA,IAAI,GAAG,MAAM,CAAC,UAAU,CAAC;IACzB,KAAK,GAAG,SAAS;AACjB,IAAA,SAAS,GAAG,MAAM,CAAC,YAAY,CAAC;AAChC,IAAA,UAAU,GAAG,MAAM,CAAC,UAAU,CAAC;;AAGhC,IAAA,IAAI,GAAG,KAAK,CAAC,QAAQ,+CAAU;IAC/B,UAAU,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,YAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAU;AAC5B,IAAA,SAAS,GAAG,KAAK,CAAS,EAAE,qDAAC;AAC7B,IAAA,KAAK,GAAG,KAAK,CAAS,cAAc,iDAAC;AACrC,IAAA,WAAW,GAAG,KAAK,CAAS,CAAC,uDAAC;;AAG9B,IAAA,UAAU,GAAG,MAAM,CAAkB,IAAI,sDAAC;AAE1D,IAAA,WAAA,GAAA;QACE,MAAM,CAAC,MAAK;YACV,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,SAAS,CAAC;gBAClC,IAAI,EAAE,GAAG,IAAG;AACV,oBAAA,MAAM,OAAO,GAAG,IAAI,CAAC,UAAU,CAA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AA;oBACR,OAAO,EAAE,CAAC,OAAO,CAAC;oBAClB,OAAO,EAAE,CAAC,OAAO,CAAC;AACnB,iBAAA;;;ACTD;;AAEG;;ACFH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"3ddv-software-division-components-generic-icon.mjs","sources":["../../generic/icon/icon.component.ts","../../generic/icon/icon.component.html","../../generic/icon/lib/ui-icon-helm/src/lib/hlm-icon.token.ts","../../generic/icon/lib/ui-icon-helm/src/lib/hlm-icon.ts","../../generic/icon/lib/ui-icon-helm/src/index.ts","../../generic/icon/public-api.ts","../../generic/icon/3ddv-software-division-components-generic-icon.ts"],"sourcesContent":["import { HttpBackend, HttpClient } from '@angular/common/http';\nimport {\n ChangeDetectionStrategy,\n Component,\n effect,\n ElementRef,\n inject,\n input,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\nimport { map, Observable, shareReplay } from 'rxjs';\n\n/** Bumped when fetch strategy changes so we do not reuse errored `shareReplay` streams. */\nconst ICON_CACHE_SCHEME = 'http-backend-v1';\n\nconst iconCache = new Map<string, Observable<string>>();\n\n@Component({\n selector: 'sdc-svg-icon',\n templateUrl: './icon.component.html',\n styleUrl: './icon.component.css',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[class]': 'className()',\n },\n})\nexport class SvgIconComponent {\n // DI — use HttpClient(HttpBackend) so static SVG fetches skip app interceptors\n private readonly httpPlain = new HttpClient(inject(HttpBackend));\n private readonly cache = iconCache;\n private readonly sanitizer = inject(DomSanitizer);\n private readonly elementRef = inject(ElementRef);\n\n // INPUTS / OUTPUTS\n public readonly name = input.required<string>();\n public readonly iconFolder = input<string>();\n public readonly className = input<string>('');\n public readonly color = input<string>('currentColor');\n /** Use `> 0` when the asset relies on stroke */\n public readonly strokeWidth = input<number>(0);\n\n // STATE\n public readonly svgContent = signal<SafeHtml | null>(null);\n\n public constructor() {\n effect(() => {\n this.syncHostPaintVars();\n });\n\n effect(() => {\n this.getIcon().subscribe({\n next: svg => {\n this.svgContent.set(this.sanitizer.bypassSecurityTrustHtml(svg));\n },\n error: (error: unknown) => {\n console.error('Failed to load icon:', error);\n // Optional: set a minimal fallback SVG or clear content\n this.svgContent.set(\n this.sanitizer.bypassSecurityTrustHtml(\n `<svg viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 8v4m0 4h.01\"\n stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" fill=\"none\"/></svg>`\n )\n );\n },\n });\n });\n }\n\n private syncHostPaintVars(): void {\n const element = this.elementRef.nativeElement as HTMLElement;\n element.style.setProperty('--icon-color', this.resolveColor(this.color()));\n const sw = this.strokeWidth();\n if (sw > 0) {\n element.classList.add('sdc-svg-icon--stroke');\n element.style.setProperty('--icon-stroke-width', String(sw));\n } else {\n element.classList.remove('sdc-svg-icon--stroke');\n element.style.removeProperty('--icon-stroke-width');\n }\n }\n\n /**\n * Cache key must include folder: the same `name` can exist under different paths\n * (e.g. `assets/x.svg` vs `assets/img/x.svg`). Caching by name alone poisoned later loads.\n */\n public getIcon(): Observable<string> {\n const folder: string = this.iconFolder() ?? 'assets';\n const iconName: string = this.name();\n const cacheKey: string = `${ICON_CACHE_SCHEME}:${folder}/${iconName}`;\n\n if (!this.cache.has(cacheKey)) {\n const icon$: Observable<string> = this.httpPlain.get(`/${folder}/${iconName}.svg`, { responseType: 'text' }).pipe(\n map((svg: string) => this.sanitizeSvg(svg)),\n shareReplay({ bufferSize: 1, refCount: true })\n );\n\n this.cache.set(cacheKey, icon$);\n }\n\n return this.cache.get(cacheKey)!;\n }\n\n private sanitizeSvg(svg: string): string {\n let out = svg\n // Remove any existing width/height attributes to make the SVG more flexible\n .replace(/\\swidth=\"[^\"]*\"/g, '')\n .replace(/\\sheight=\"[^\"]*\"/g, '')\n // Strip hardcoded fill/stroke so CSS variable takes effect\n .replace(/\\sfill=\"(?!none)[^\"]*\"/g, '')\n .replace(/\\sstroke=\"(?!none)[^\"]*\"/g, '');\n\n // Avoid clipping stroke/paint at the root when assets are tight to viewBox\n if (!/\\soverflow\\s*=/i.test(out)) {\n out = out.replace(/<svg\\b/i, '<svg overflow=\"visible\" ');\n }\n\n return out;\n }\n\n /**\n * Resolves the color input to a valid CSS value.\n * - Already-valid CSS values (var(), #hex, rgb(), hsl(), currentColor) pass through unchanged.\n * - A raw CSS variable name starting with \"--\" is wrapped: \"--my-var\" → \"var(--my-var)\".\n * - Any other string is treated as a design-token name and resolved via the\n * \"--color-\" prefix convention: \"accent\" → \"var(--color-accent)\".\n */\n private resolveColor(color: string): string {\n const passThroughPrefixes = ['currentColor', 'var(', '#', 'rgb(', 'rgba(', 'hsl(', 'hsla('];\n\n if (passThroughPrefixes.some(prefix => color.startsWith(prefix))) {\n return color;\n }\n\n if (color.startsWith('--')) {\n return `var(${color})`;\n }\n\n return `var(--color-${color})`;\n }\n}\n","@if (svgContent(); as content) {\n <span class=\"sdc-svg-icon\" [innerHTML]=\"content\"></span>\n}\n","import { InjectionToken, ValueProvider, inject } from '@angular/core';\nimport type { IconSize } from './hlm-icon';\n\nexport interface HlmIconConfig {\n size: IconSize;\n}\n\nconst defaultConfig: HlmIconConfig = {\n size: 'base',\n};\n\nconst HlmIconConfigToken = new InjectionToken<HlmIconConfig>('HlmIconConfig');\n\nexport function provideHlmIconConfig(config: Partial<HlmIconConfig>): ValueProvider {\n return { provide: HlmIconConfigToken, useValue: { ...defaultConfig, ...config } };\n}\n\nexport function injectHlmIconConfig(): HlmIconConfig {\n return inject(HlmIconConfigToken, { optional: true }) ?? defaultConfig;\n}\n","import { Directive, computed, input } from '@angular/core';\nimport { injectHlmIconConfig } from './hlm-icon.token';\n\nexport type IconSize = 'xs' | 'sm' | 'base' | 'lg' | 'xl' | 'none' | (Record<never, never> & string);\n\n@Directive({\n selector: 'ng-icon[hlm]',\n standalone: true,\n host: {\n '[style.--ng-icon__size]': '_computedSize()',\n },\n})\nexport class HlmIcon {\n private readonly _config = injectHlmIconConfig();\n public readonly size = input<IconSize>(this._config.size);\n public readonly variant = input<'light' | 'dark'>('light');\n\n protected readonly _computedSize = computed(() => {\n const size = this.size();\n\n switch (size) {\n case 'xs':\n return '12px';\n case 'sm':\n return '16px';\n case 'base':\n return '24px';\n case 'lg':\n return '32px';\n case 'xl':\n return '48px';\n default: {\n return size;\n }\n }\n });\n}\n","import { NgModule } from '@angular/core';\nimport { HlmIcon } from './lib/hlm-icon';\n\nexport * from './lib/hlm-icon';\nexport * from './lib/hlm-icon.token';\n\n@NgModule({\n imports: [HlmIcon],\n exports: [HlmIcon],\n})\nexport class HlmIconModule {}\n","/*\n * Public API Surface of software-division-components\n */\n\nexport * from './icon.component';\nexport { HlmIcon, HlmIconModule } from './lib/ui-icon-helm/src';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAcA;AACA,MAAM,iBAAiB,GAAG,iBAAiB;AAE3C,MAAM,SAAS,GAAG,IAAI,GAAG,EAA8B;MAY1C,gBAAgB,CAAA;;IAEV,SAAS,GAAG,IAAI,UAAU,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;IAC/C,KAAK,GAAG,SAAS;AACjB,IAAA,SAAS,GAAG,MAAM,CAAC,YAAY,CAAC;AAChC,IAAA,UAAU,GAAG,MAAM,CAAC,UAAU,CAAC;;AAGhC,IAAA,IAAI,GAAG,KAAK,CAAC,QAAQ,+CAAU;IAC/B,UAAU,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,YAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAU;AAC5B,IAAA,SAAS,GAAG,KAAK,CAAS,EAAE,qDAAC;AAC7B,IAAA,KAAK,GAAG,KAAK,CAAS,cAAc,iDAAC;;AAErC,IAAA,WAAW,GAAG,KAAK,CAAS,CAAC,uDAAC;;AAG9B,IAA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A,iBAAA,EAAA,MAAA,EAAA,UAAA,EAAA,MAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,OAAA,EAAA,EAAA,iBAAA,EAAA,SAAA,EAAA,UAAA,EAAA,SAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,uBAAA,EAAA,iBAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAP,OAAO,EAAA,UAAA,EAAA,CAAA;kBAPnB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,cAAc;AACxB,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,IAAI,EAAE;AACJ,wBAAA,yBAAyB,EAAE,iBAAiB;AAC7C,qBAAA;AACF,iBAAA;;;MCDY,aAAa,CAAA;uGAAb,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA;wGAAb,aAAa,EAAA,OAAA,EAAA,CAHd,OAAO,CAAA,EAAA,OAAA,EAAA,CACP,OAAO,CAAA,EAAA,CAAA;wGAEN,aAAa,EAAA,CAAA;;2FAAb,aAAa,EAAA,UAAA,EAAA,CAAA;kBAJzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,OAAO,CAAC;oBAClB,OAAO,EAAE,CAAC,OAAO,CAAC;AACnB,iBAAA;;;ACTD;;AAEG;;ACFH;;AAEG;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { input, computed, Directive, booleanAttribute, inject, ChangeDetectionStrategy, Component, contentChild, NgModule, output } from '@angular/core';
|
|
2
|
+
import { input, computed, Directive, booleanAttribute, inject, ElementRef, effect, HostListener, ChangeDetectionStrategy, Component, contentChild, NgModule, output } from '@angular/core';
|
|
3
3
|
import { hlm, injectExposesStateProvider, injectExposedSideProvider } from '@spartan-ng/brain/core';
|
|
4
4
|
import * as i1 from '@spartan-ng/brain/select';
|
|
5
5
|
import { BrnSelectGroup, BrnSelectLabel, BrnSelectOption, BrnSelect, BrnSelectTrigger, BrnSelectImports } from '@spartan-ng/brain/select';
|
|
@@ -29,11 +29,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImpor
|
|
|
29
29
|
class HlmSelectContent {
|
|
30
30
|
userClass = input('', { ...(ngDevMode ? { debugName: "userClass" } : {}), alias: 'class' });
|
|
31
31
|
stickyLabels = input(false, { ...(ngDevMode ? { debugName: "stickyLabels" } : {}), transform: booleanAttribute });
|
|
32
|
+
variant = input('light', ...(ngDevMode ? [{ debugName: "variant" }] : []));
|
|
32
33
|
_stateProvider = injectExposesStateProvider({ optional: true });
|
|
33
34
|
_sideProvider = injectExposedSideProvider({ optional: true });
|
|
34
|
-
_computedClass = computed(() =>
|
|
35
|
+
_computedClass = computed(() => {
|
|
36
|
+
const isGlass = this.variant() === 'glass';
|
|
37
|
+
return hlm('w-full relative z-50 min-w-[8rem] overflow-hidden rounded-md border p-1 data-[side=bottom]:top-[2px] data-[side=top]:bottom-[2px] data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2', isGlass ? '' : 'border-border bg-popover text-popover-foreground shadow-md', this.userClass());
|
|
38
|
+
}, ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
35
39
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: HlmSelectContent, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
36
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.1.4", type: HlmSelectContent, isStandalone: true, selector: "[hlmSelectContent], hlm-select-content", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, stickyLabels: { classPropertyName: "stickyLabels", publicName: "stickyLabels", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()", "attr.data-state": "_stateProvider?.state() ?? \"open\"", "attr.data-side": "_sideProvider?.side() ?? \"bottom\"" } }, ngImport: i0 });
|
|
40
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.1.4", type: HlmSelectContent, isStandalone: true, selector: "[hlmSelectContent], hlm-select-content", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, stickyLabels: { classPropertyName: "stickyLabels", publicName: "stickyLabels", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()", "attr.data-state": "_stateProvider?.state() ?? \"open\"", "attr.data-side": "_sideProvider?.side() ?? \"bottom\"", "style.background": "variant() === \"glass\" ? \"rgba(90, 90, 115, 0.25)\" : null", "style.backdropFilter": "variant() === \"glass\" ? \"blur(20px)\" : null", "style.webkitBackdropFilter": "variant() === \"glass\" ? \"blur(20px)\" : null", "style.borderColor": "variant() === \"glass\" ? \"rgba(255, 255, 255, 0.12)\" : null", "style.color": "variant() === \"glass\" ? \"white\" : null", "style.boxShadow": "variant() === \"glass\" ? \"inset 0 1px 0 rgba(255,255,255,0.55), inset 1px 0 0 rgba(255,255,255,0.18), inset -1px 0 0 rgba(255,255,255,0.04), inset 0 -1px 0 rgba(255,255,255,0.06)\" : null" } }, ngImport: i0 });
|
|
37
41
|
}
|
|
38
42
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: HlmSelectContent, decorators: [{
|
|
39
43
|
type: Directive,
|
|
@@ -43,9 +47,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImpor
|
|
|
43
47
|
'[class]': '_computedClass()',
|
|
44
48
|
'[attr.data-state]': '_stateProvider?.state() ?? "open"',
|
|
45
49
|
'[attr.data-side]': '_sideProvider?.side() ?? "bottom"',
|
|
50
|
+
'[style.background]': 'variant() === "glass" ? "rgba(90, 90, 115, 0.25)" : null',
|
|
51
|
+
'[style.backdropFilter]': 'variant() === "glass" ? "blur(20px)" : null',
|
|
52
|
+
'[style.webkitBackdropFilter]': 'variant() === "glass" ? "blur(20px)" : null',
|
|
53
|
+
'[style.borderColor]': 'variant() === "glass" ? "rgba(255, 255, 255, 0.12)" : null',
|
|
54
|
+
'[style.color]': 'variant() === "glass" ? "white" : null',
|
|
55
|
+
'[style.boxShadow]': 'variant() === "glass" ? "inset 0 1px 0 rgba(255,255,255,0.55), inset 1px 0 0 rgba(255,255,255,0.18), inset -1px 0 0 rgba(255,255,255,0.04), inset 0 -1px 0 rgba(255,255,255,0.06)" : null',
|
|
46
56
|
},
|
|
47
57
|
}]
|
|
48
|
-
}], propDecorators: { userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], stickyLabels: [{ type: i0.Input, args: [{ isSignal: true, alias: "stickyLabels", required: false }] }] } });
|
|
58
|
+
}], propDecorators: { userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], stickyLabels: [{ type: i0.Input, args: [{ isSignal: true, alias: "stickyLabels", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }] } });
|
|
49
59
|
|
|
50
60
|
class HlmSelectGroup {
|
|
51
61
|
userClass = input('', { ...(ngDevMode ? { debugName: "userClass" } : {}), alias: 'class' });
|
|
@@ -85,10 +95,39 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImpor
|
|
|
85
95
|
|
|
86
96
|
class HlmSelectOption {
|
|
87
97
|
_brnSelectOption = inject(BrnSelectOption, { host: true });
|
|
98
|
+
_el = inject(ElementRef);
|
|
88
99
|
userClass = input('', { ...(ngDevMode ? { debugName: "userClass" } : {}), alias: 'class' });
|
|
89
|
-
|
|
100
|
+
variant = input('light', ...(ngDevMode ? [{ debugName: "variant" }] : []));
|
|
101
|
+
constructor() {
|
|
102
|
+
effect(() => {
|
|
103
|
+
if (this.variant() !== 'glass')
|
|
104
|
+
return;
|
|
105
|
+
this._el.nativeElement.style.background = this._brnSelectOption.selected()
|
|
106
|
+
? 'rgba(255, 255, 255, 0.12)'
|
|
107
|
+
: 'transparent';
|
|
108
|
+
});
|
|
109
|
+
}
|
|
110
|
+
onMouseEnter() {
|
|
111
|
+
if (this.variant() !== 'glass')
|
|
112
|
+
return;
|
|
113
|
+
this._el.nativeElement.style.background = 'rgba(255, 255, 255, 0.18)';
|
|
114
|
+
}
|
|
115
|
+
onMouseLeave() {
|
|
116
|
+
if (this.variant() !== 'glass')
|
|
117
|
+
return;
|
|
118
|
+
this._el.nativeElement.style.background = this._brnSelectOption.selected()
|
|
119
|
+
? 'rgba(255, 255, 255, 0.12)'
|
|
120
|
+
: 'transparent';
|
|
121
|
+
}
|
|
122
|
+
_computedClass = computed(() => {
|
|
123
|
+
const isGlass = this.variant() === 'glass';
|
|
124
|
+
const interactionClasses = isGlass
|
|
125
|
+
? 'text-white'
|
|
126
|
+
: 'hover:bg-accent data-[active]:bg-accent data-[active]:text-white';
|
|
127
|
+
return hlm('overflow-hidden text-ellipsis whitespace-nowrap [&>ng-icon]:text-white relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>ng-icon]:pointer-events-none [&>ng-icon]:shrink-0 [&>ng-icon]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2', interactionClasses, this.userClass());
|
|
128
|
+
}, ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
90
129
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: HlmSelectOption, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
91
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.4", type: HlmSelectOption, isStandalone: true, selector: "hlm-option", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "_computedClass()" } }, providers: [provideIcons({ lucideCheck })], hostDirectives: [{ directive: i1.BrnSelectOption, inputs: ["disabled", "disabled", "value", "value"] }], ngImport: i0, template: `
|
|
130
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.4", type: HlmSelectOption, isStandalone: true, selector: "hlm-option", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "mouseenter": "onMouseEnter()", "mouseleave": "onMouseLeave()" }, properties: { "class": "_computedClass()" } }, providers: [provideIcons({ lucideCheck })], hostDirectives: [{ directive: i1.BrnSelectOption, inputs: ["disabled", "disabled", "value", "value"] }], ngImport: i0, template: `
|
|
92
131
|
<span class="absolute right-2 flex size-3.5 items-center justify-center">
|
|
93
132
|
@if (this._brnSelectOption.selected()) {
|
|
94
133
|
<ng-icon aria-hidden="true" hlm name="lucideCheck" size="sm" />
|
|
@@ -119,7 +158,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImpor
|
|
|
119
158
|
`,
|
|
120
159
|
imports: [NgIcon, HlmIcon],
|
|
121
160
|
}]
|
|
122
|
-
}], propDecorators: { userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } }
|
|
161
|
+
}], ctorParameters: () => [], propDecorators: { userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], onMouseEnter: [{
|
|
162
|
+
type: HostListener,
|
|
163
|
+
args: ['mouseenter']
|
|
164
|
+
}], onMouseLeave: [{
|
|
165
|
+
type: HostListener,
|
|
166
|
+
args: ['mouseleave']
|
|
167
|
+
}] } });
|
|
123
168
|
|
|
124
169
|
class HlmSelectScrollDown {
|
|
125
170
|
userClass = input('', { ...(ngDevMode ? { debugName: "userClass" } : {}), alias: 'class' });
|
|
@@ -178,7 +223,7 @@ class HlmSelectTrigger {
|
|
|
178
223
|
userClass = input('', { ...(ngDevMode ? { debugName: "userClass" } : {}), alias: 'class' });
|
|
179
224
|
variant = input('light', ...(ngDevMode ? [{ debugName: "variant" }] : []));
|
|
180
225
|
size = input('default', ...(ngDevMode ? [{ debugName: "size" }] : []));
|
|
181
|
-
_computedClass = computed(() => hlm(selectTriggerVariants({ error: this._brnSelect?.errorState() }), this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
226
|
+
_computedClass = computed(() => hlm(selectTriggerVariants({ error: this._brnSelect?.errorState() }), this.variant() === 'glass' ? 'glass-btn' : '', this.userClass()), ...(ngDevMode ? [{ debugName: "_computedClass" }] : []));
|
|
182
227
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: HlmSelectTrigger, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
183
228
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.4", type: HlmSelectTrigger, isStandalone: true, selector: "hlm-select-trigger", inputs: { userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, providers: [provideIcons({ lucideChevronDown })], queries: [{ propertyName: "_icon", first: true, predicate: HlmIcon, descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
184
229
|
<button #button brnSelectTrigger hlmInput type="button" [attr.data-size]="size()" [class]="_computedClass()">
|
|
@@ -190,19 +235,15 @@ class HlmSelectTrigger {
|
|
|
190
235
|
class="ml-2 flex-none"
|
|
191
236
|
hlm
|
|
192
237
|
name="lucideChevronDown"
|
|
193
|
-
[color]="variant() === 'dark' ? 'white' : 'black'"
|
|
238
|
+
[color]="variant() === 'dark' || variant() === 'glass' ? 'white' : 'black'"
|
|
194
239
|
size="sm" />
|
|
195
240
|
}
|
|
196
241
|
</button>
|
|
197
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: BrnSelectTrigger, selector: "[brnSelectTrigger]" }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "directive", type: HlmIcon, selector: "ng-icon[hlm]", inputs: ["size", "variant"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
242
|
+
`, isInline: true, styles: ["button.glass-btn{background:#ffffff0f!important;border-color:#ffffff0a!important;backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);color:#fff!important;box-shadow:inset 0 1px #ffffff8c,inset 1px 0 #ffffff2e,inset -1px 0 #ffffff0a,inset 0 -1px #ffffff0f!important;transition:background .2s ease,box-shadow .2s ease}button.glass-btn:hover{background:#ffffff1f!important;box-shadow:inset 0 1px #ffffffb3,inset 1px 0 #ffffff40,inset -1px 0 #ffffff0f,inset 0 -1px #ffffff14!important}\n"], dependencies: [{ kind: "directive", type: BrnSelectTrigger, selector: "[brnSelectTrigger]" }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "directive", type: HlmIcon, selector: "ng-icon[hlm]", inputs: ["size", "variant"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
198
243
|
}
|
|
199
244
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: HlmSelectTrigger, decorators: [{
|
|
200
245
|
type: Component,
|
|
201
|
-
args: [{
|
|
202
|
-
selector: 'hlm-select-trigger',
|
|
203
|
-
imports: [BrnSelectTrigger, NgIcon, HlmIcon],
|
|
204
|
-
providers: [provideIcons({ lucideChevronDown })],
|
|
205
|
-
template: `
|
|
246
|
+
args: [{ selector: 'hlm-select-trigger', imports: [BrnSelectTrigger, NgIcon, HlmIcon], providers: [provideIcons({ lucideChevronDown })], template: `
|
|
206
247
|
<button #button brnSelectTrigger hlmInput type="button" [attr.data-size]="size()" [class]="_computedClass()">
|
|
207
248
|
<ng-content />
|
|
208
249
|
@if (_icon()) {
|
|
@@ -212,13 +253,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImpor
|
|
|
212
253
|
class="ml-2 flex-none"
|
|
213
254
|
hlm
|
|
214
255
|
name="lucideChevronDown"
|
|
215
|
-
[color]="variant() === 'dark' ? 'white' : 'black'"
|
|
256
|
+
[color]="variant() === 'dark' || variant() === 'glass' ? 'white' : 'black'"
|
|
216
257
|
size="sm" />
|
|
217
258
|
}
|
|
218
259
|
</button>
|
|
219
|
-
`,
|
|
220
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
221
|
-
}]
|
|
260
|
+
`, changeDetection: ChangeDetectionStrategy.OnPush, styles: ["button.glass-btn{background:#ffffff0f!important;border-color:#ffffff0a!important;backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);color:#fff!important;box-shadow:inset 0 1px #ffffff8c,inset 1px 0 #ffffff2e,inset -1px 0 #ffffff0a,inset 0 -1px #ffffff0f!important;transition:background .2s ease,box-shadow .2s ease}button.glass-btn:hover{background:#ffffff1f!important;box-shadow:inset 0 1px #ffffffb3,inset 1px 0 #ffffff40,inset -1px 0 #ffffff0f,inset 0 -1px #ffffff14!important}\n"] }]
|
|
222
261
|
}], propDecorators: { _icon: [{ type: i0.ContentChild, args: [i0.forwardRef(() => HlmIcon), { isSignal: true }] }], userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }] } });
|
|
223
262
|
|
|
224
263
|
class HlmSelectValue {
|
|
@@ -295,17 +334,22 @@ class SelectComponent {
|
|
|
295
334
|
options = input.required(...(ngDevMode ? [{ debugName: "options" }] : []));
|
|
296
335
|
fullWidth = input(false, ...(ngDevMode ? [{ debugName: "fullWidth" }] : []));
|
|
297
336
|
defaultValue = input(...(ngDevMode ? [undefined, { debugName: "defaultValue" }] : []));
|
|
337
|
+
disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : {}), transform: booleanAttribute });
|
|
298
338
|
valueChange = output();
|
|
299
339
|
get variantClasses() {
|
|
300
|
-
|
|
340
|
+
if (this.variant() === 'dark')
|
|
341
|
+
return 'bg-black text-white';
|
|
342
|
+
if (this.variant() === 'glass')
|
|
343
|
+
return 'select-variant-glass text-white';
|
|
344
|
+
return 'bg-white text-black';
|
|
301
345
|
}
|
|
302
346
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: SelectComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
303
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.4", type: SelectComponent, isStandalone: true, selector: "sdc-select", inputs: { placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null }, defaultValue: { classPropertyName: "defaultValue", publicName: "defaultValue", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<hlm-select\n class=\"select-root\"\n [value]=\"defaultValue()?.value\"\n [placeholder]=\"placeholder()\"\n (valueChange)=\"valueChange.emit($event)\">\n <hlm-select-trigger\n class=\"select-trigger select-trigger--sm\"\n size=\"sm\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-trigger\n class=\"select-trigger select-trigger--lg\"\n size=\"default\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-content [class]=\"fullWidth() ? 'full-width' : ''\" [ngClass]=\"variantClasses\">\n @for (option of options(); track idx + option.label; let idx = $index) {\n <hlm-option [ngClass]=\"variantClasses\" [value]=\"option.value\">{{ option.label }}</hlm-option>\n }\n </hlm-select-content>\n</hlm-select>\n", styles: [".select-root{display:inline-block;width:100%}.select-trigger{display:flex;justify-content:space-between;align-items:center;border-radius:25px!important;outline:none;width:100%;overflow:hidden;color:#fff;font-size:.75rem;text-align:center;white-space:nowrap;text-overflow:ellipsis}.select-trigger:focus,.select-trigger:focus-visible{outline:none;box-shadow:0 0 0 2px var(--accent, var(--ring-accent, #0ea5e9))}.select-trigger--sm{display:flex}.select-trigger--lg{display:none}@media(min-width:1024px){.select-trigger--sm{display:none;font-weight:500;font-size:.875rem}.select-trigger--lg{display:flex;font-weight:500;font-size:.875rem}}.full-width{width:100%}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i1.BrnSelect, selector: "brn-select, hlm-select", inputs: ["id", "multiple", "placeholder", "disabled", "dir", "closeDelay", "open", "value", "compareWith"], outputs: ["openChange", "valueChange"] }, { kind: "component", type: i1.BrnSelectContent, selector: "brn-select-content, hlm-select-content:not(noHlm)" }, { kind: "component", type: i1.BrnSelectValue, selector: "brn-select-value, hlm-select-value", inputs: ["transformFn"] }, { kind: "directive", type: HlmSelectContent, selector: "[hlmSelectContent], hlm-select-content", inputs: ["class", "stickyLabels"] }, { kind: "component", type: HlmSelectTrigger, selector: "hlm-select-trigger", inputs: ["class", "variant", "size"] }, { kind: "component", type: HlmSelectOption, selector: "hlm-option", inputs: ["class"] }, { kind: "directive", type: HlmSelectValue, selector: "hlm-select-value,[hlmSelectValue], brn-select-value[hlm]", inputs: ["class"] }, { kind: "directive", type: HlmSelect, selector: "hlm-select, brn-select [hlm]", inputs: ["class"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
347
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.4", type: SelectComponent, isStandalone: true, selector: "sdc-select", inputs: { placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, fullWidth: { classPropertyName: "fullWidth", publicName: "fullWidth", isSignal: true, isRequired: false, transformFunction: null }, defaultValue: { classPropertyName: "defaultValue", publicName: "defaultValue", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<hlm-select\n class=\"select-root\"\n [disabled]=\"disabled()\"\n [value]=\"defaultValue()?.value\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"disabled()\"\n (valueChange)=\"valueChange.emit($event)\">\n <hlm-select-trigger\n class=\"select-trigger select-trigger--sm\"\n size=\"sm\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-trigger\n class=\"select-trigger select-trigger--lg\"\n size=\"default\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-content [class]=\"fullWidth() ? 'full-width' : ''\" [variant]=\"variant()\" [ngClass]=\"variantClasses\">\n @for (option of options(); track idx + option.label; let idx = $index) {\n <hlm-option [variant]=\"variant()\" [ngClass]=\"variantClasses\" [value]=\"option.value\">{{ option.label }}</hlm-option>\n }\n </hlm-select-content>\n</hlm-select>\n", styles: [".select-root{display:inline-block;width:100%}.select-trigger{display:flex;justify-content:space-between;align-items:center;border-radius:25px!important;outline:none;width:100%;overflow:hidden;color:#fff;font-size:.75rem;text-align:center;white-space:nowrap;text-overflow:ellipsis}.select-trigger:focus,.select-trigger:focus-visible{outline:none;box-shadow:0 0 0 2px var(--accent, var(--ring-accent, #0ea5e9))}.select-trigger--sm{display:flex}.select-trigger--lg{display:none}@media(min-width:1024px){.select-trigger--sm{display:none;font-weight:500;font-size:.875rem}.select-trigger--lg{display:flex;font-weight:500;font-size:.875rem}}.select-trigger.select-variant-glass{background:transparent!important;border-color:#ffffff0a!important;backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);box-shadow:inset 0 1px #ffffff8c,inset 1px 0 #ffffff2e,inset -1px 0 #ffffff0a,inset 0 -1px #ffffff0f;transition:background .2s ease,box-shadow .2s ease}.select-trigger.select-variant-glass:hover{background:transparent!important;box-shadow:inset 0 1px #ffffffb3,inset 1px 0 #ffffff40,inset -1px 0 #ffffff0f,inset 0 -1px #ffffff14}.full-width{width:100%}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i1.BrnSelect, selector: "brn-select, hlm-select", inputs: ["id", "multiple", "placeholder", "disabled", "dir", "closeDelay", "open", "value", "compareWith"], outputs: ["openChange", "valueChange"] }, { kind: "component", type: i1.BrnSelectContent, selector: "brn-select-content, hlm-select-content:not(noHlm)" }, { kind: "component", type: i1.BrnSelectValue, selector: "brn-select-value, hlm-select-value", inputs: ["transformFn"] }, { kind: "directive", type: HlmSelectContent, selector: "[hlmSelectContent], hlm-select-content", inputs: ["class", "stickyLabels", "variant"] }, { kind: "component", type: HlmSelectTrigger, selector: "hlm-select-trigger", inputs: ["class", "variant", "size"] }, { kind: "component", type: HlmSelectOption, selector: "hlm-option", inputs: ["class", "variant"] }, { kind: "directive", type: HlmSelectValue, selector: "hlm-select-value,[hlmSelectValue], brn-select-value[hlm]", inputs: ["class"] }, { kind: "directive", type: HlmSelect, selector: "hlm-select, brn-select [hlm]", inputs: ["class"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
304
348
|
}
|
|
305
349
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.4", ngImport: i0, type: SelectComponent, decorators: [{
|
|
306
350
|
type: Component,
|
|
307
|
-
args: [{ changeDetection: ChangeDetectionStrategy.OnPush, selector: 'sdc-select', imports: [CommonModule, BrnSelectImports, HlmSelectImports], template: "<hlm-select\n class=\"select-root\"\n [value]=\"defaultValue()?.value\"\n [placeholder]=\"placeholder()\"\n (valueChange)=\"valueChange.emit($event)\">\n <hlm-select-trigger\n class=\"select-trigger select-trigger--sm\"\n size=\"sm\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-trigger\n class=\"select-trigger select-trigger--lg\"\n size=\"default\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-content [class]=\"fullWidth() ? 'full-width' : ''\" [ngClass]=\"variantClasses\">\n @for (option of options(); track idx + option.label; let idx = $index) {\n <hlm-option [ngClass]=\"variantClasses\" [value]=\"option.value\">{{ option.label }}</hlm-option>\n }\n </hlm-select-content>\n</hlm-select>\n", styles: [".select-root{display:inline-block;width:100%}.select-trigger{display:flex;justify-content:space-between;align-items:center;border-radius:25px!important;outline:none;width:100%;overflow:hidden;color:#fff;font-size:.75rem;text-align:center;white-space:nowrap;text-overflow:ellipsis}.select-trigger:focus,.select-trigger:focus-visible{outline:none;box-shadow:0 0 0 2px var(--accent, var(--ring-accent, #0ea5e9))}.select-trigger--sm{display:flex}.select-trigger--lg{display:none}@media(min-width:1024px){.select-trigger--sm{display:none;font-weight:500;font-size:.875rem}.select-trigger--lg{display:flex;font-weight:500;font-size:.875rem}}.full-width{width:100%}\n"] }]
|
|
308
|
-
}], propDecorators: { placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: true }] }], fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }], defaultValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "defaultValue", required: false }] }], valueChange: [{ type: i0.Output, args: ["valueChange"] }] } });
|
|
351
|
+
args: [{ changeDetection: ChangeDetectionStrategy.OnPush, selector: 'sdc-select', imports: [CommonModule, BrnSelectImports, HlmSelectImports], template: "<hlm-select\n class=\"select-root\"\n [disabled]=\"disabled()\"\n [value]=\"defaultValue()?.value\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"disabled()\"\n (valueChange)=\"valueChange.emit($event)\">\n <hlm-select-trigger\n class=\"select-trigger select-trigger--sm\"\n size=\"sm\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-trigger\n class=\"select-trigger select-trigger--lg\"\n size=\"default\"\n [variant]=\"variant()\"\n [ngClass]=\"variantClasses\">\n <hlm-select-value [ngClass]=\"variantClasses\" />\n </hlm-select-trigger>\n\n <hlm-select-content [class]=\"fullWidth() ? 'full-width' : ''\" [variant]=\"variant()\" [ngClass]=\"variantClasses\">\n @for (option of options(); track idx + option.label; let idx = $index) {\n <hlm-option [variant]=\"variant()\" [ngClass]=\"variantClasses\" [value]=\"option.value\">{{ option.label }}</hlm-option>\n }\n </hlm-select-content>\n</hlm-select>\n", styles: [".select-root{display:inline-block;width:100%}.select-trigger{display:flex;justify-content:space-between;align-items:center;border-radius:25px!important;outline:none;width:100%;overflow:hidden;color:#fff;font-size:.75rem;text-align:center;white-space:nowrap;text-overflow:ellipsis}.select-trigger:focus,.select-trigger:focus-visible{outline:none;box-shadow:0 0 0 2px var(--accent, var(--ring-accent, #0ea5e9))}.select-trigger--sm{display:flex}.select-trigger--lg{display:none}@media(min-width:1024px){.select-trigger--sm{display:none;font-weight:500;font-size:.875rem}.select-trigger--lg{display:flex;font-weight:500;font-size:.875rem}}.select-trigger.select-variant-glass{background:transparent!important;border-color:#ffffff0a!important;backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);box-shadow:inset 0 1px #ffffff8c,inset 1px 0 #ffffff2e,inset -1px 0 #ffffff0a,inset 0 -1px #ffffff0f;transition:background .2s ease,box-shadow .2s ease}.select-trigger.select-variant-glass:hover{background:transparent!important;box-shadow:inset 0 1px #ffffffb3,inset 1px 0 #ffffff40,inset -1px 0 #ffffff0f,inset 0 -1px #ffffff14}.full-width{width:100%}\n"] }]
|
|
352
|
+
}], propDecorators: { placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: true }] }], fullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullWidth", required: false }] }], defaultValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "defaultValue", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], valueChange: [{ type: i0.Output, args: ["valueChange"] }] } });
|
|
309
353
|
|
|
310
354
|
/**
|
|
311
355
|
* Generated bundle index. Do not edit.
|