@ojiepermana/angular 21.2.2 → 21.3.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 +119 -23
- package/fesm2022/ojiepermana-angular-layout-theme.mjs +581 -0
- package/fesm2022/ojiepermana-angular-layout-theme.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-layout.mjs +2 -1
- package/fesm2022/ojiepermana-angular-layout.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-navigation-icon.mjs +59 -0
- package/fesm2022/ojiepermana-angular-navigation-icon.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-navigation.mjs +6 -58
- package/fesm2022/ojiepermana-angular-navigation.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-theme.mjs +1 -1
- package/fesm2022/ojiepermana-angular-theme.mjs.map +1 -1
- package/fesm2022/ojiepermana-angular-ui-component-accordion.mjs +174 -0
- package/fesm2022/ojiepermana-angular-ui-component-accordion.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-alert-dialog.mjs +242 -0
- package/fesm2022/ojiepermana-angular-ui-component-alert-dialog.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-alert.mjs +90 -0
- package/fesm2022/ojiepermana-angular-ui-component-alert.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-aspect-ratio.mjs +33 -0
- package/fesm2022/ojiepermana-angular-ui-component-aspect-ratio.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-avatar.mjs +123 -0
- package/fesm2022/ojiepermana-angular-ui-component-avatar.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-badge.mjs +47 -0
- package/fesm2022/ojiepermana-angular-ui-component-badge.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-breadcrumb.mjs +186 -0
- package/fesm2022/ojiepermana-angular-ui-component-breadcrumb.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-button-group.mjs +95 -0
- package/fesm2022/ojiepermana-angular-ui-component-button-group.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-button.mjs +64 -0
- package/fesm2022/ojiepermana-angular-ui-component-button.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-calendar.mjs +78 -0
- package/fesm2022/ojiepermana-angular-ui-component-calendar.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-card.mjs +137 -0
- package/fesm2022/ojiepermana-angular-ui-component-card.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-carousel.mjs +310 -0
- package/fesm2022/ojiepermana-angular-ui-component-carousel.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-area.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-area.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-bar.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-bar.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-line.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-line.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-pie.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-pie.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-radar.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-radar.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-radial.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-radial.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-scatter.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-chart-scatter.mjs.map +1 -0
- package/fesm2022/{ojiepermana-angular-chart.mjs → ojiepermana-angular-ui-component-chart.mjs} +2 -2
- package/fesm2022/ojiepermana-angular-ui-component-chart.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-checkbox.mjs +104 -0
- package/fesm2022/ojiepermana-angular-ui-component-checkbox.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-collapsible.mjs +116 -0
- package/fesm2022/ojiepermana-angular-ui-component-collapsible.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-combobox.mjs +263 -0
- package/fesm2022/ojiepermana-angular-ui-component-combobox.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-command.mjs +268 -0
- package/fesm2022/ojiepermana-angular-ui-component-command.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-context-menu.mjs +100 -0
- package/fesm2022/ojiepermana-angular-ui-component-context-menu.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-date-picker.mjs +155 -0
- package/fesm2022/ojiepermana-angular-ui-component-date-picker.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-dialog.mjs +262 -0
- package/fesm2022/ojiepermana-angular-ui-component-dialog.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-drawer.mjs +6 -0
- package/fesm2022/ojiepermana-angular-ui-component-drawer.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-dropdown-menu.mjs +458 -0
- package/fesm2022/ojiepermana-angular-ui-component-dropdown-menu.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-form.mjs +208 -0
- package/fesm2022/ojiepermana-angular-ui-component-form.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-input-group.mjs +164 -0
- package/fesm2022/ojiepermana-angular-ui-component-input-group.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-input.mjs +43 -0
- package/fesm2022/ojiepermana-angular-ui-component-input.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-item.mjs +241 -0
- package/fesm2022/ojiepermana-angular-ui-component-item.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-label.mjs +30 -0
- package/fesm2022/ojiepermana-angular-ui-component-label.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-pagination.mjs +192 -0
- package/fesm2022/ojiepermana-angular-ui-component-pagination.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-popover.mjs +163 -0
- package/fesm2022/ojiepermana-angular-ui-component-popover.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-progress.mjs +53 -0
- package/fesm2022/ojiepermana-angular-ui-component-progress.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-radio.mjs +92 -0
- package/fesm2022/ojiepermana-angular-ui-component-radio.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-scroll-area.mjs +48 -0
- package/fesm2022/ojiepermana-angular-ui-component-scroll-area.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-select.mjs +131 -0
- package/fesm2022/ojiepermana-angular-ui-component-select.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-separator.mjs +33 -0
- package/fesm2022/ojiepermana-angular-ui-component-separator.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-sheet.mjs +235 -0
- package/fesm2022/ojiepermana-angular-ui-component-sheet.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-skeleton.mjs +29 -0
- package/fesm2022/ojiepermana-angular-ui-component-skeleton.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-slider.mjs +29 -0
- package/fesm2022/ojiepermana-angular-ui-component-slider.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-switch.mjs +84 -0
- package/fesm2022/ojiepermana-angular-ui-component-switch.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-table.mjs +139 -0
- package/fesm2022/ojiepermana-angular-ui-component-table.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-tabs.mjs +252 -0
- package/fesm2022/ojiepermana-angular-ui-component-tabs.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-textarea.mjs +37 -0
- package/fesm2022/ojiepermana-angular-ui-component-textarea.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-toast.mjs +47 -0
- package/fesm2022/ojiepermana-angular-ui-component-toast.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-tooltip.mjs +56 -0
- package/fesm2022/ojiepermana-angular-ui-component-tooltip.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular-ui-component-utils.mjs +13 -0
- package/fesm2022/ojiepermana-angular-ui-component-utils.mjs.map +1 -0
- package/fesm2022/ojiepermana-angular.mjs +5 -3
- package/fesm2022/ojiepermana-angular.mjs.map +1 -1
- package/layout/theme/package.json +4 -0
- package/navigation-icon/package.json +4 -0
- package/package.json +212 -12
- package/types/ojiepermana-angular-layout-theme.d.ts +205 -0
- package/types/ojiepermana-angular-layout.d.ts +1 -1
- package/types/ojiepermana-angular-navigation-icon.d.ts +17 -0
- package/types/ojiepermana-angular-navigation.d.ts +2 -20
- package/types/ojiepermana-angular-ui-component-accordion.d.ts +51 -0
- package/types/ojiepermana-angular-ui-component-alert-dialog.d.ts +93 -0
- package/types/ojiepermana-angular-ui-component-alert.d.ts +37 -0
- package/types/ojiepermana-angular-ui-component-aspect-ratio.d.ts +12 -0
- package/types/ojiepermana-angular-ui-component-avatar.d.ts +51 -0
- package/types/ojiepermana-angular-ui-component-badge.d.ts +19 -0
- package/types/ojiepermana-angular-ui-component-breadcrumb.d.ts +46 -0
- package/types/ojiepermana-angular-ui-component-button-group.d.ts +26 -0
- package/types/ojiepermana-angular-ui-component-button.d.ts +22 -0
- package/types/ojiepermana-angular-ui-component-calendar.d.ts +33 -0
- package/types/ojiepermana-angular-ui-component-card.d.ts +60 -0
- package/types/ojiepermana-angular-ui-component-carousel.d.ts +86 -0
- package/types/ojiepermana-angular-ui-component-chart-area.d.ts +1 -0
- package/types/ojiepermana-angular-ui-component-chart-bar.d.ts +1 -0
- package/types/ojiepermana-angular-ui-component-chart-line.d.ts +1 -0
- package/types/ojiepermana-angular-ui-component-chart-pie.d.ts +1 -0
- package/types/ojiepermana-angular-ui-component-chart-radar.d.ts +1 -0
- package/types/ojiepermana-angular-ui-component-chart-radial.d.ts +1 -0
- package/types/ojiepermana-angular-ui-component-chart-scatter.d.ts +1 -0
- package/types/{ojiepermana-angular-chart.d.ts → ojiepermana-angular-ui-component-chart.d.ts} +15 -15
- package/types/ojiepermana-angular-ui-component-checkbox.d.ts +35 -0
- package/types/ojiepermana-angular-ui-component-collapsible.d.ts +42 -0
- package/types/ojiepermana-angular-ui-component-combobox.d.ts +51 -0
- package/types/ojiepermana-angular-ui-component-command.d.ts +99 -0
- package/types/ojiepermana-angular-ui-component-context-menu.d.ts +35 -0
- package/types/ojiepermana-angular-ui-component-date-picker.d.ts +41 -0
- package/types/ojiepermana-angular-ui-component-dialog.d.ts +87 -0
- package/types/ojiepermana-angular-ui-component-drawer.d.ts +1 -0
- package/types/ojiepermana-angular-ui-component-dropdown-menu.d.ts +135 -0
- package/types/ojiepermana-angular-ui-component-form.d.ts +92 -0
- package/types/ojiepermana-angular-ui-component-input-group.d.ts +51 -0
- package/types/ojiepermana-angular-ui-component-input.d.ts +16 -0
- package/types/ojiepermana-angular-ui-component-item.d.ts +88 -0
- package/types/ojiepermana-angular-ui-component-label.d.ts +11 -0
- package/types/ojiepermana-angular-ui-component-pagination.d.ts +27 -0
- package/types/ojiepermana-angular-ui-component-popover.d.ts +43 -0
- package/types/ojiepermana-angular-ui-component-progress.d.ts +17 -0
- package/types/ojiepermana-angular-ui-component-radio.d.ts +34 -0
- package/types/ojiepermana-angular-ui-component-scroll-area.d.ts +19 -0
- package/types/ojiepermana-angular-ui-component-select.d.ts +45 -0
- package/types/ojiepermana-angular-ui-component-separator.d.ts +14 -0
- package/types/ojiepermana-angular-ui-component-sheet.d.ts +74 -0
- package/types/ojiepermana-angular-ui-component-skeleton.d.ts +10 -0
- package/types/ojiepermana-angular-ui-component-slider.d.ts +16 -0
- package/types/ojiepermana-angular-ui-component-switch.d.ts +30 -0
- package/types/ojiepermana-angular-ui-component-table.d.ts +52 -0
- package/types/ojiepermana-angular-ui-component-tabs.d.ts +92 -0
- package/types/ojiepermana-angular-ui-component-textarea.d.ts +12 -0
- package/types/ojiepermana-angular-ui-component-toast.d.ts +29 -0
- package/types/ojiepermana-angular-ui-component-tooltip.d.ts +22 -0
- package/types/ojiepermana-angular-ui-component-utils.d.ts +5 -0
- package/ui/component/accordion/package.json +4 -0
- package/ui/component/alert/package.json +4 -0
- package/ui/component/alert-dialog/package.json +4 -0
- package/ui/component/aspect-ratio/package.json +4 -0
- package/ui/component/avatar/package.json +4 -0
- package/ui/component/badge/package.json +4 -0
- package/ui/component/breadcrumb/package.json +4 -0
- package/ui/component/button/package.json +4 -0
- package/ui/component/button-group/package.json +4 -0
- package/ui/component/calendar/package.json +4 -0
- package/ui/component/card/package.json +4 -0
- package/ui/component/carousel/package.json +4 -0
- package/ui/component/chart/README.md +249 -0
- package/ui/component/chart/area/package.json +4 -0
- package/ui/component/chart/bar/package.json +4 -0
- package/ui/component/chart/line/package.json +4 -0
- package/ui/component/chart/package.json +4 -0
- package/ui/component/chart/pie/package.json +4 -0
- package/ui/component/chart/radar/package.json +4 -0
- package/ui/component/chart/radial/package.json +4 -0
- package/ui/component/chart/scatter/package.json +4 -0
- package/ui/component/checkbox/package.json +4 -0
- package/ui/component/collapsible/package.json +4 -0
- package/ui/component/combobox/package.json +4 -0
- package/ui/component/command/package.json +4 -0
- package/ui/component/context-menu/package.json +4 -0
- package/ui/component/date-picker/package.json +4 -0
- package/ui/component/dialog/package.json +4 -0
- package/ui/component/drawer/package.json +4 -0
- package/ui/component/dropdown-menu/package.json +4 -0
- package/ui/component/form/package.json +4 -0
- package/ui/component/input/package.json +4 -0
- package/ui/component/input-group/package.json +4 -0
- package/ui/component/item/package.json +4 -0
- package/ui/component/label/package.json +4 -0
- package/ui/component/pagination/package.json +4 -0
- package/ui/component/popover/package.json +4 -0
- package/ui/component/progress/package.json +4 -0
- package/ui/component/radio/package.json +4 -0
- package/ui/component/scroll-area/package.json +4 -0
- package/ui/component/select/package.json +4 -0
- package/ui/component/separator/package.json +4 -0
- package/ui/component/sheet/package.json +4 -0
- package/ui/component/skeleton/package.json +4 -0
- package/ui/component/slider/package.json +4 -0
- package/ui/component/switch/package.json +4 -0
- package/ui/component/table/package.json +4 -0
- package/ui/component/tabs/package.json +4 -0
- package/ui/component/textarea/package.json +4 -0
- package/ui/component/toast/package.json +4 -0
- package/ui/component/tooltip/package.json +4 -0
- package/ui/component/utils/package.json +4 -0
- package/chart/README.md +0 -0
- package/chart/package.json +0 -4
- package/component/package.json +0 -4
- package/fesm2022/ojiepermana-angular-chart.mjs.map +0 -1
- package/fesm2022/ojiepermana-angular-component.mjs +0 -5774
- package/fesm2022/ojiepermana-angular-component.mjs.map +0 -1
- package/types/ojiepermana-angular-component.d.ts +0 -1927
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ojiepermana-angular-ui-component-date-picker.mjs","sources":["../../../projects/angular/ui/component/date-picker/src/lib/date-picker.component.ts","../../../projects/angular/ui/component/date-picker/ojiepermana-angular-ui-component-date-picker.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n DestroyRef,\n computed,\n effect,\n forwardRef,\n inject,\n input,\n model,\n untracked,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { MatDatepicker, MatDatepickerInput, type MatCalendarView } from '@angular/material/datepicker';\nimport { MatFormField, MatSuffix } from '@angular/material/form-field';\nimport { MatInput } from '@angular/material/input';\nimport { ControlValueAccessor, FormControl, NG_VALUE_ACCESSOR, ReactiveFormsModule } from '@angular/forms';\nimport { cn } from '@ojiepermana/angular/component/utils';\n\nlet nextDatePickerId = 0;\n\n/**\n * Popup date picker. Requires a date adapter provider in the consumer app\n * (e.g. `provideNativeDateAdapter()` from `@angular/material/core`).\n */\n@Component({\n selector: 'ui-date-picker',\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [ReactiveFormsModule, MatFormField, MatSuffix, MatInput, MatDatepicker, MatDatepickerInput],\n host: { '[class]': 'classes()' },\n providers: [{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => DatePickerComponent), multi: true }],\n styleUrl: './date-picker.component.css',\n template: `\n <mat-form-field class=\"ui-date-picker w-full\" appearance=\"outline\" subscriptSizing=\"dynamic\">\n <input\n matInput\n [id]=\"resolvedId()\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby()\"\n [matDatepicker]=\"picker\"\n [matDatepickerFilter]=\"dateFilter()\"\n [placeholder]=\"placeholder()\"\n [required]=\"required()\"\n [min]=\"min()\"\n [max]=\"max()\"\n [formControl]=\"control\"\n (blur)=\"handleTouched()\" />\n <button\n matIconSuffix\n type=\"button\"\n class=\"ui-date-picker-toggle\"\n aria-label=\"Open calendar\"\n [disabled]=\"control.disabled\"\n (click)=\"picker.open()\">\n <svg aria-hidden=\"true\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\">\n <path d=\"M8 2v4\" />\n <path d=\"M16 2v4\" />\n <rect width=\"18\" height=\"18\" x=\"3\" y=\"4\" rx=\"2\" />\n <path d=\"M3 10h18\" />\n </svg>\n </button>\n <mat-datepicker\n #picker\n [panelClass]=\"panelClass()\"\n [startAt]=\"startAt()\"\n [startView]=\"startView()\"\n [touchUi]=\"touchUi()\"></mat-datepicker>\n </mat-form-field>\n `,\n})\nexport class DatePickerComponent implements ControlValueAccessor {\n readonly value = model<Date | null>(null);\n readonly id = input<string | null>(null);\n readonly placeholder = input<string>('Pick a date');\n readonly required = input<boolean>(false);\n readonly min = input<Date | null>(null);\n readonly max = input<Date | null>(null);\n readonly startAt = input<Date | null>(null);\n readonly startView = input<MatCalendarView>('month');\n readonly touchUi = input<boolean>(false);\n readonly dateFilter = input<((date: Date | null) => boolean) | null>(null);\n readonly panelClass = input<string | string[]>('ui-datepicker-panel');\n readonly ariaLabel = input<string | null>(null, { alias: 'aria-label' });\n readonly ariaLabelledby = input<string | null>(null, { alias: 'aria-labelledby' });\n readonly disabled = model<boolean>(false);\n readonly class = input<string>('');\n\n private readonly fallbackId = `ui-date-picker-${nextDatePickerId++}`;\n\n protected readonly classes = computed(() => cn('inline-block', this.class()));\n protected readonly resolvedId = computed(() => this.id() ?? this.fallbackId);\n\n protected readonly control = new FormControl<Date | null>(null);\n\n private onChangeFn: (v: Date | null) => void = () => {};\n private onTouchedFn: () => void = () => {};\n\n constructor() {\n effect(() => {\n const next = this.value();\n if (this.control.value !== next) {\n this.control.setValue(next, { emitEvent: false });\n }\n });\n\n effect(() => {\n const d = this.disabled();\n d ? this.control.disable({ emitEvent: false }) : this.control.enable({ emitEvent: false });\n });\n\n this.control.valueChanges.pipe(takeUntilDestroyed(inject(DestroyRef))).subscribe((next) => {\n untracked(() => this.value.set(next));\n this.onChangeFn(next);\n this.onTouchedFn();\n });\n }\n\n protected handleTouched(): void {\n this.onTouchedFn();\n }\n\n writeValue(v: Date | null): void {\n this.value.set(v);\n }\n\n registerOnChange(fn: (v: Date | null) => void): void {\n this.onChangeFn = fn;\n }\n\n registerOnTouched(fn: () => void): void {\n this.onTouchedFn = fn;\n }\n\n setDisabledState(state: boolean): void {\n this.disabled.set(state);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;AAmBA,IAAI,gBAAgB,GAAG,CAAC;AAExB;;;AAGG;MA8CU,mBAAmB,CAAA;AACrB,IAAA,KAAK,GAAG,KAAK,CAAc,IAAI,4EAAC;AAChC,IAAA,EAAE,GAAG,KAAK,CAAgB,IAAI,yEAAC;AAC/B,IAAA,WAAW,GAAG,KAAK,CAAS,aAAa,kFAAC;AAC1C,IAAA,QAAQ,GAAG,KAAK,CAAU,KAAK,+EAAC;AAChC,IAAA,GAAG,GAAG,KAAK,CAAc,IAAI,0EAAC;AAC9B,IAAA,GAAG,GAAG,KAAK,CAAc,IAAI,0EAAC;A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EAAA,kBAAA,EAAA,OAAA,EAAA,UAAA,EAAA,qBAAA,CAAA,EAAA,QAAA,EAAA,CAAA,UAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAE,aAAa,EAAA,QAAA,EAAA,gBAAA,EAAA,QAAA,EAAA,CAAA,eAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAE,kBAAkB,EAAA,QAAA,EAAA,sBAAA,EAAA,MAAA,EAAA,CAAA,eAAA,EAAA,KAAA,EAAA,KAAA,EAAA,qBAAA,CAAA,EAAA,QAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FA0CxF,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBA7C/B,SAAS;+BACE,gBAAgB,EAAA,eAAA,EACT,uBAAuB,CAAC,MAAM,WACtC,CAAC,mBAAmB,EAAE,YAAY,EAAE,SAAS,EAAE,QAAQ,EAAE,aAAa,EAAE,kBAAkB,CAAC,EAAA,IAAA,EAC9F,EAAE,SAAS,EAAE,WAAW,EAAE,EAAA,SAAA,EACrB,CAAC,EAAE,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,UAAU,CAAC,yBAAyB,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,EAAA,QAAA,EAElG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoCT,EAAA,CAAA,EAAA,MAAA,EAAA,CAAA,kxFAAA,CAAA,EAAA;;;ACpEH;;AAEG;;;;"}
|
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
import { Overlay } from '@angular/cdk/overlay';
|
|
2
|
+
import { TemplatePortal } from '@angular/cdk/portal';
|
|
3
|
+
import { FocusTrapFactory } from '@angular/cdk/a11y';
|
|
4
|
+
import * as i0 from '@angular/core';
|
|
5
|
+
import { inject, ViewContainerRef, DestroyRef, model, input, output, viewChild, computed, effect, ChangeDetectionStrategy, Component, Directive } from '@angular/core';
|
|
6
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
7
|
+
import { DOCUMENT } from '@angular/common';
|
|
8
|
+
import { filter } from 'rxjs/operators';
|
|
9
|
+
import { ButtonComponent } from '@ojiepermana/angular/component/button';
|
|
10
|
+
import { cn } from '@ojiepermana/angular/component/utils';
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Declarative modal dialog. Renders into the body via CDK overlay when
|
|
14
|
+
* `open` becomes `true`. Focus is trapped inside; restored to trigger on close.
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* <button ui-button (click)="open.set(true)">Open</button>
|
|
18
|
+
* <ui-dialog [(open)]="open">
|
|
19
|
+
* <ui-dialog-header>
|
|
20
|
+
* <ui-dialog-title>Are you sure?</ui-dialog-title>
|
|
21
|
+
* <ui-dialog-description>This action cannot be undone.</ui-dialog-description>
|
|
22
|
+
* </ui-dialog-header>
|
|
23
|
+
* <ui-dialog-footer>
|
|
24
|
+
* <button ui-button variant="outline" (click)="open.set(false)">Cancel</button>
|
|
25
|
+
* <button ui-button variant="destructive" (click)="confirm()">Delete</button>
|
|
26
|
+
* </ui-dialog-footer>
|
|
27
|
+
* </ui-dialog>
|
|
28
|
+
*/
|
|
29
|
+
class DialogComponent {
|
|
30
|
+
overlay = inject(Overlay);
|
|
31
|
+
vcr = inject(ViewContainerRef);
|
|
32
|
+
trapFactory = inject(FocusTrapFactory);
|
|
33
|
+
doc = inject(DOCUMENT);
|
|
34
|
+
destroyRef = inject(DestroyRef);
|
|
35
|
+
open = model(false, ...(ngDevMode ? [{ debugName: "open" }] : /* istanbul ignore next */ []));
|
|
36
|
+
closeOnEscape = input(true, ...(ngDevMode ? [{ debugName: "closeOnEscape" }] : /* istanbul ignore next */ []));
|
|
37
|
+
closeOnBackdropClick = input(true, ...(ngDevMode ? [{ debugName: "closeOnBackdropClick" }] : /* istanbul ignore next */ []));
|
|
38
|
+
showCloseButton = input(true, ...(ngDevMode ? [{ debugName: "showCloseButton" }] : /* istanbul ignore next */ []));
|
|
39
|
+
closeButtonLabel = input('Close', ...(ngDevMode ? [{ debugName: "closeButtonLabel" }] : /* istanbul ignore next */ []));
|
|
40
|
+
labelledBy = input(null, { ...(ngDevMode ? { debugName: "labelledBy" } : /* istanbul ignore next */ {}), alias: 'aria-labelledby' });
|
|
41
|
+
describedBy = input(null, { ...(ngDevMode ? { debugName: "describedBy" } : /* istanbul ignore next */ {}), alias: 'aria-describedby' });
|
|
42
|
+
class = input('', ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
43
|
+
openedChange = output();
|
|
44
|
+
tpl = viewChild.required('tpl');
|
|
45
|
+
overlayRef = null;
|
|
46
|
+
focusTrap = null;
|
|
47
|
+
previousFocus = null;
|
|
48
|
+
surfaceClasses = computed(() => cn('relative grid w-full max-w-lg gap-4 rounded-lg border bg-background p-6 shadow-lg duration-200', this.class()), ...(ngDevMode ? [{ debugName: "surfaceClasses" }] : /* istanbul ignore next */ []));
|
|
49
|
+
constructor() {
|
|
50
|
+
effect(() => {
|
|
51
|
+
this.open() ? this.attach() : this.detach();
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
attach() {
|
|
55
|
+
if (this.overlayRef)
|
|
56
|
+
return;
|
|
57
|
+
this.previousFocus = this.doc.activeElement;
|
|
58
|
+
this.overlayRef = this.overlay.create({
|
|
59
|
+
hasBackdrop: true,
|
|
60
|
+
backdropClass: 'ui-dialog-backdrop',
|
|
61
|
+
panelClass: 'ui-dialog-panel',
|
|
62
|
+
scrollStrategy: this.overlay.scrollStrategies.block(),
|
|
63
|
+
positionStrategy: this.overlay.position().global().centerHorizontally().centerVertically(),
|
|
64
|
+
});
|
|
65
|
+
const portal = new TemplatePortal(this.tpl(), this.vcr);
|
|
66
|
+
this.overlayRef.attach(portal);
|
|
67
|
+
this.focusTrap = this.trapFactory.create(this.overlayRef.hostElement);
|
|
68
|
+
this.focusTrap.focusInitialElementWhenReady();
|
|
69
|
+
if (this.closeOnBackdropClick()) {
|
|
70
|
+
this.overlayRef
|
|
71
|
+
.backdropClick()
|
|
72
|
+
.pipe(takeUntilDestroyed(this.destroyRef))
|
|
73
|
+
.subscribe(() => this.requestClose());
|
|
74
|
+
}
|
|
75
|
+
this.overlayRef
|
|
76
|
+
.keydownEvents()
|
|
77
|
+
.pipe(takeUntilDestroyed(this.destroyRef), filter((e) => e.key === 'Escape' && this.closeOnEscape()))
|
|
78
|
+
.subscribe((e) => {
|
|
79
|
+
e.preventDefault();
|
|
80
|
+
this.requestClose();
|
|
81
|
+
});
|
|
82
|
+
this.openedChange.emit(true);
|
|
83
|
+
}
|
|
84
|
+
detach() {
|
|
85
|
+
if (!this.overlayRef)
|
|
86
|
+
return;
|
|
87
|
+
this.focusTrap?.destroy();
|
|
88
|
+
this.focusTrap = null;
|
|
89
|
+
this.overlayRef.dispose();
|
|
90
|
+
this.overlayRef = null;
|
|
91
|
+
this.previousFocus?.focus?.();
|
|
92
|
+
this.openedChange.emit(false);
|
|
93
|
+
}
|
|
94
|
+
requestClose() {
|
|
95
|
+
this.open.set(false);
|
|
96
|
+
}
|
|
97
|
+
close() {
|
|
98
|
+
this.requestClose();
|
|
99
|
+
}
|
|
100
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
101
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.14", type: DialogComponent, isStandalone: true, selector: "ui-dialog", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null }, closeOnEscape: { classPropertyName: "closeOnEscape", publicName: "closeOnEscape", isSignal: true, isRequired: false, transformFunction: null }, closeOnBackdropClick: { classPropertyName: "closeOnBackdropClick", publicName: "closeOnBackdropClick", isSignal: true, isRequired: false, transformFunction: null }, showCloseButton: { classPropertyName: "showCloseButton", publicName: "showCloseButton", isSignal: true, isRequired: false, transformFunction: null }, closeButtonLabel: { classPropertyName: "closeButtonLabel", publicName: "closeButtonLabel", isSignal: true, isRequired: false, transformFunction: null }, labelledBy: { classPropertyName: "labelledBy", publicName: "aria-labelledby", isSignal: true, isRequired: false, transformFunction: null }, describedBy: { classPropertyName: "describedBy", publicName: "aria-describedby", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { open: "openChange", openedChange: "openedChange" }, viewQueries: [{ propertyName: "tpl", first: true, predicate: ["tpl"], descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
102
|
+
<ng-template #tpl>
|
|
103
|
+
<div
|
|
104
|
+
class="ui-dialog-surface"
|
|
105
|
+
role="dialog"
|
|
106
|
+
aria-modal="true"
|
|
107
|
+
[attr.aria-labelledby]="labelledBy()"
|
|
108
|
+
[attr.aria-describedby]="describedBy()"
|
|
109
|
+
[class]="surfaceClasses()">
|
|
110
|
+
@if (showCloseButton()) {
|
|
111
|
+
<button
|
|
112
|
+
type="button"
|
|
113
|
+
ui-button
|
|
114
|
+
variant="ghost"
|
|
115
|
+
size="icon-sm"
|
|
116
|
+
class="ui-dialog-close-button absolute right-4 top-4 h-8 w-8 rounded-md p-0 text-muted-foreground opacity-70 transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring"
|
|
117
|
+
[attr.aria-label]="closeButtonLabel()"
|
|
118
|
+
(click)="close()">
|
|
119
|
+
<span aria-hidden="true">X</span>
|
|
120
|
+
<span class="sr-only">{{ closeButtonLabel() }}</span>
|
|
121
|
+
</button>
|
|
122
|
+
}
|
|
123
|
+
<ng-content />
|
|
124
|
+
</div>
|
|
125
|
+
</ng-template>
|
|
126
|
+
`, isInline: true, dependencies: [{ kind: "component", type: ButtonComponent, selector: "button[ui-button], a[ui-button]", inputs: ["variant", "size", "class"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
127
|
+
}
|
|
128
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogComponent, decorators: [{
|
|
129
|
+
type: Component,
|
|
130
|
+
args: [{
|
|
131
|
+
selector: 'ui-dialog',
|
|
132
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
133
|
+
imports: [ButtonComponent],
|
|
134
|
+
template: `
|
|
135
|
+
<ng-template #tpl>
|
|
136
|
+
<div
|
|
137
|
+
class="ui-dialog-surface"
|
|
138
|
+
role="dialog"
|
|
139
|
+
aria-modal="true"
|
|
140
|
+
[attr.aria-labelledby]="labelledBy()"
|
|
141
|
+
[attr.aria-describedby]="describedBy()"
|
|
142
|
+
[class]="surfaceClasses()">
|
|
143
|
+
@if (showCloseButton()) {
|
|
144
|
+
<button
|
|
145
|
+
type="button"
|
|
146
|
+
ui-button
|
|
147
|
+
variant="ghost"
|
|
148
|
+
size="icon-sm"
|
|
149
|
+
class="ui-dialog-close-button absolute right-4 top-4 h-8 w-8 rounded-md p-0 text-muted-foreground opacity-70 transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring"
|
|
150
|
+
[attr.aria-label]="closeButtonLabel()"
|
|
151
|
+
(click)="close()">
|
|
152
|
+
<span aria-hidden="true">X</span>
|
|
153
|
+
<span class="sr-only">{{ closeButtonLabel() }}</span>
|
|
154
|
+
</button>
|
|
155
|
+
}
|
|
156
|
+
<ng-content />
|
|
157
|
+
</div>
|
|
158
|
+
</ng-template>
|
|
159
|
+
`,
|
|
160
|
+
}]
|
|
161
|
+
}], ctorParameters: () => [], propDecorators: { open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }, { type: i0.Output, args: ["openChange"] }], closeOnEscape: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnEscape", required: false }] }], closeOnBackdropClick: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnBackdropClick", required: false }] }], showCloseButton: [{ type: i0.Input, args: [{ isSignal: true, alias: "showCloseButton", required: false }] }], closeButtonLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeButtonLabel", required: false }] }], labelledBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-labelledby", required: false }] }], describedBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-describedby", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], openedChange: [{ type: i0.Output, args: ["openedChange"] }], tpl: [{ type: i0.ViewChild, args: ['tpl', { isSignal: true }] }] } });
|
|
162
|
+
|
|
163
|
+
class DialogCloseDirective {
|
|
164
|
+
dialog = inject(DialogComponent);
|
|
165
|
+
closeDialog() {
|
|
166
|
+
this.dialog.close();
|
|
167
|
+
}
|
|
168
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogCloseDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
169
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.14", type: DialogCloseDirective, isStandalone: true, selector: "button[ui-dialog-close], a[ui-dialog-close]", host: { listeners: { "click": "closeDialog()" } }, ngImport: i0 });
|
|
170
|
+
}
|
|
171
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogCloseDirective, decorators: [{
|
|
172
|
+
type: Directive,
|
|
173
|
+
args: [{
|
|
174
|
+
selector: 'button[ui-dialog-close], a[ui-dialog-close]',
|
|
175
|
+
host: {
|
|
176
|
+
'(click)': 'closeDialog()',
|
|
177
|
+
},
|
|
178
|
+
}]
|
|
179
|
+
}] });
|
|
180
|
+
|
|
181
|
+
class DialogHeaderComponent {
|
|
182
|
+
class = input('', ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
183
|
+
classes = computed(() => cn('flex flex-col gap-1.5 text-center sm:text-left', this.class()), ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
184
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
185
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.14", type: DialogHeaderComponent, isStandalone: true, selector: "ui-dialog-header", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
186
|
+
}
|
|
187
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogHeaderComponent, decorators: [{
|
|
188
|
+
type: Component,
|
|
189
|
+
args: [{
|
|
190
|
+
selector: 'ui-dialog-header',
|
|
191
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
192
|
+
host: { '[class]': 'classes()' },
|
|
193
|
+
template: `<ng-content />`,
|
|
194
|
+
}]
|
|
195
|
+
}], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
196
|
+
class DialogTitleComponent {
|
|
197
|
+
class = input('', ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
198
|
+
classes = computed(() => cn('text-lg font-semibold leading-none tracking-tight', this.class()), ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
199
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
200
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.14", type: DialogTitleComponent, isStandalone: true, selector: "ui-dialog-title, h2[ui-dialog-title]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
201
|
+
}
|
|
202
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogTitleComponent, decorators: [{
|
|
203
|
+
type: Component,
|
|
204
|
+
args: [{
|
|
205
|
+
selector: 'ui-dialog-title, h2[ui-dialog-title]',
|
|
206
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
207
|
+
host: { '[class]': 'classes()' },
|
|
208
|
+
template: `<ng-content />`,
|
|
209
|
+
}]
|
|
210
|
+
}], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
211
|
+
class DialogDescriptionComponent {
|
|
212
|
+
class = input('', ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
213
|
+
classes = computed(() => cn('text-sm text-muted-foreground', this.class()), ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
214
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogDescriptionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
215
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.14", type: DialogDescriptionComponent, isStandalone: true, selector: "ui-dialog-description, p[ui-dialog-description]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
216
|
+
}
|
|
217
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogDescriptionComponent, decorators: [{
|
|
218
|
+
type: Component,
|
|
219
|
+
args: [{
|
|
220
|
+
selector: 'ui-dialog-description, p[ui-dialog-description]',
|
|
221
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
222
|
+
host: { '[class]': 'classes()' },
|
|
223
|
+
template: `<ng-content />`,
|
|
224
|
+
}]
|
|
225
|
+
}], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
226
|
+
class DialogContentComponent {
|
|
227
|
+
class = input('', ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
228
|
+
classes = computed(() => cn('grid gap-4', this.class()), ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
229
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
230
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.14", type: DialogContentComponent, isStandalone: true, selector: "ui-dialog-content", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
231
|
+
}
|
|
232
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogContentComponent, decorators: [{
|
|
233
|
+
type: Component,
|
|
234
|
+
args: [{
|
|
235
|
+
selector: 'ui-dialog-content',
|
|
236
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
237
|
+
host: { '[class]': 'classes()' },
|
|
238
|
+
template: `<ng-content />`,
|
|
239
|
+
}]
|
|
240
|
+
}], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
241
|
+
class DialogFooterComponent {
|
|
242
|
+
class = input('', ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
|
|
243
|
+
classes = computed(() => cn('flex flex-col-reverse gap-2 sm:flex-row sm:justify-end sm:gap-2', this.class()), ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
|
|
244
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogFooterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
245
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.14", type: DialogFooterComponent, isStandalone: true, selector: "ui-dialog-footer", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
246
|
+
}
|
|
247
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: DialogFooterComponent, decorators: [{
|
|
248
|
+
type: Component,
|
|
249
|
+
args: [{
|
|
250
|
+
selector: 'ui-dialog-footer',
|
|
251
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
252
|
+
host: { '[class]': 'classes()' },
|
|
253
|
+
template: `<ng-content />`,
|
|
254
|
+
}]
|
|
255
|
+
}], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
|
|
256
|
+
|
|
257
|
+
/**
|
|
258
|
+
* Generated bundle index. Do not edit.
|
|
259
|
+
*/
|
|
260
|
+
|
|
261
|
+
export { DialogCloseDirective, DialogComponent, DialogContentComponent, DialogDescriptionComponent, DialogFooterComponent, DialogHeaderComponent, DialogTitleComponent };
|
|
262
|
+
//# sourceMappingURL=ojiepermana-angular-ui-component-dialog.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ojiepermana-angular-ui-component-dialog.mjs","sources":["../../../projects/angular/ui/component/dialog/src/lib/dialog.component.ts","../../../projects/angular/ui/component/dialog/src/lib/dialog-close.directive.ts","../../../projects/angular/ui/component/dialog/src/lib/dialog-parts.component.ts","../../../projects/angular/ui/component/dialog/ojiepermana-angular-ui-component-dialog.ts"],"sourcesContent":["import { Overlay, OverlayRef } from '@angular/cdk/overlay';\nimport { TemplatePortal } from '@angular/cdk/portal';\nimport { FocusTrap, FocusTrapFactory } from '@angular/cdk/a11y';\nimport {\n ChangeDetectionStrategy,\n Component,\n DestroyRef,\n ElementRef,\n TemplateRef,\n ViewContainerRef,\n computed,\n effect,\n inject,\n input,\n model,\n output,\n viewChild,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { DOCUMENT } from '@angular/common';\nimport { filter } from 'rxjs/operators';\nimport { ButtonComponent } from '@ojiepermana/angular/component/button';\nimport { cn } from '@ojiepermana/angular/component/utils';\n\n/**\n * Declarative modal dialog. Renders into the body via CDK overlay when\n * `open` becomes `true`. Focus is trapped inside; restored to trigger on close.\n *\n * @example\n * <button ui-button (click)=\"open.set(true)\">Open</button>\n * <ui-dialog [(open)]=\"open\">\n * <ui-dialog-header>\n * <ui-dialog-title>Are you sure?</ui-dialog-title>\n * <ui-dialog-description>This action cannot be undone.</ui-dialog-description>\n * </ui-dialog-header>\n * <ui-dialog-footer>\n * <button ui-button variant=\"outline\" (click)=\"open.set(false)\">Cancel</button>\n * <button ui-button variant=\"destructive\" (click)=\"confirm()\">Delete</button>\n * </ui-dialog-footer>\n * </ui-dialog>\n */\n@Component({\n selector: 'ui-dialog',\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [ButtonComponent],\n template: `\n <ng-template #tpl>\n <div\n class=\"ui-dialog-surface\"\n role=\"dialog\"\n aria-modal=\"true\"\n [attr.aria-labelledby]=\"labelledBy()\"\n [attr.aria-describedby]=\"describedBy()\"\n [class]=\"surfaceClasses()\">\n @if (showCloseButton()) {\n <button\n type=\"button\"\n ui-button\n variant=\"ghost\"\n size=\"icon-sm\"\n class=\"ui-dialog-close-button absolute right-4 top-4 h-8 w-8 rounded-md p-0 text-muted-foreground opacity-70 transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring\"\n [attr.aria-label]=\"closeButtonLabel()\"\n (click)=\"close()\">\n <span aria-hidden=\"true\">X</span>\n <span class=\"sr-only\">{{ closeButtonLabel() }}</span>\n </button>\n }\n <ng-content />\n </div>\n </ng-template>\n `,\n})\nexport class DialogComponent {\n private readonly overlay = inject(Overlay);\n private readonly vcr = inject(ViewContainerRef);\n private readonly trapFactory = inject(FocusTrapFactory);\n private readonly doc = inject(DOCUMENT);\n private readonly destroyRef = inject(DestroyRef);\n\n readonly open = model<boolean>(false);\n readonly closeOnEscape = input<boolean>(true);\n readonly closeOnBackdropClick = input<boolean>(true);\n readonly showCloseButton = input<boolean>(true);\n readonly closeButtonLabel = input<string>('Close');\n readonly labelledBy = input<string | null>(null, { alias: 'aria-labelledby' });\n readonly describedBy = input<string | null>(null, { alias: 'aria-describedby' });\n readonly class = input<string>('');\n\n readonly openedChange = output<boolean>();\n\n private readonly tpl = viewChild.required<TemplateRef<unknown>>('tpl');\n private overlayRef: OverlayRef | null = null;\n private focusTrap: FocusTrap | null = null;\n private previousFocus: HTMLElement | null = null;\n\n protected readonly surfaceClasses = computed(() =>\n cn('relative grid w-full max-w-lg gap-4 rounded-lg border bg-background p-6 shadow-lg duration-200', this.class()),\n );\n\n constructor() {\n effect(() => {\n this.open() ? this.attach() : this.detach();\n });\n }\n\n private attach(): void {\n if (this.overlayRef) return;\n this.previousFocus = this.doc.activeElement as HTMLElement | null;\n\n this.overlayRef = this.overlay.create({\n hasBackdrop: true,\n backdropClass: 'ui-dialog-backdrop',\n panelClass: 'ui-dialog-panel',\n scrollStrategy: this.overlay.scrollStrategies.block(),\n positionStrategy: this.overlay.position().global().centerHorizontally().centerVertically(),\n });\n\n const portal = new TemplatePortal(this.tpl(), this.vcr);\n this.overlayRef.attach(portal);\n\n this.focusTrap = this.trapFactory.create(this.overlayRef.hostElement);\n this.focusTrap.focusInitialElementWhenReady();\n\n if (this.closeOnBackdropClick()) {\n this.overlayRef\n .backdropClick()\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(() => this.requestClose());\n }\n\n this.overlayRef\n .keydownEvents()\n .pipe(\n takeUntilDestroyed(this.destroyRef),\n filter((e) => e.key === 'Escape' && this.closeOnEscape()),\n )\n .subscribe((e) => {\n e.preventDefault();\n this.requestClose();\n });\n\n this.openedChange.emit(true);\n }\n\n private detach(): void {\n if (!this.overlayRef) return;\n this.focusTrap?.destroy();\n this.focusTrap = null;\n this.overlayRef.dispose();\n this.overlayRef = null;\n this.previousFocus?.focus?.();\n this.openedChange.emit(false);\n }\n\n private requestClose(): void {\n this.open.set(false);\n }\n\n close(): void {\n this.requestClose();\n }\n}\n","import { Directive, inject } from '@angular/core';\n\nimport { DialogComponent } from './dialog.component';\n\n@Directive({\n selector: 'button[ui-dialog-close], a[ui-dialog-close]',\n host: {\n '(click)': 'closeDialog()',\n },\n})\nexport class DialogCloseDirective {\n private readonly dialog = inject(DialogComponent);\n\n closeDialog(): void {\n this.dialog.close();\n }\n}\n","import { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { cn } from '@ojiepermana/angular/component/utils';\n\n@Component({\n selector: 'ui-dialog-header',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { '[class]': 'classes()' },\n template: `<ng-content />`,\n})\nexport class DialogHeaderComponent {\n readonly class = input<string>('');\n protected readonly classes = computed(() => cn('flex flex-col gap-1.5 text-center sm:text-left', this.class()));\n}\n\n@Component({\n selector: 'ui-dialog-title, h2[ui-dialog-title]',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { '[class]': 'classes()' },\n template: `<ng-content />`,\n})\nexport class DialogTitleComponent {\n readonly class = input<string>('');\n protected readonly classes = computed(() => cn('text-lg font-semibold leading-none tracking-tight', this.class()));\n}\n\n@Component({\n selector: 'ui-dialog-description, p[ui-dialog-description]',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { '[class]': 'classes()' },\n template: `<ng-content />`,\n})\nexport class DialogDescriptionComponent {\n readonly class = input<string>('');\n protected readonly classes = computed(() => cn('text-sm text-muted-foreground', this.class()));\n}\n\n@Component({\n selector: 'ui-dialog-content',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { '[class]': 'classes()' },\n template: `<ng-content />`,\n})\nexport class DialogContentComponent {\n readonly class = input<string>('');\n protected readonly classes = computed(() => cn('grid gap-4', this.class()));\n}\n\n@Component({\n selector: 'ui-dialog-footer',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { '[class]': 'classes()' },\n template: `<ng-content />`,\n})\nexport class DialogFooterComponent {\n readonly class = input<string>('');\n protected readonly classes = computed(() =>\n cn('flex flex-col-reverse gap-2 sm:flex-row sm:justify-end sm:gap-2', this.class()),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;AAwBA;;;;;;;;;;;;;;;;AAgBG;MAgCU,eAAe,CAAA;AACT,IAAA,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC;AACzB,IAAA,GAAG,GAAG,MAAM,CAAC,gBAAgB,CAAC;AAC9B,IAAA,WAAW,GAAG,MAAM,CAAC,gBAAgB,CAAC;AACtC,IAAA,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC;AACtB,IAAA,UAAU,GAAG,MAAM,CAAC,UAAU,CAAC;AAEvC,IAAA,IAAI,GAAG,KAAK,CAAU,KAAK,2EAAC;AAC5B,IAAA,aAAa,GAAG,KAAK,CAAU,IAAI,oFAAC;AACpC,IAAA,oBAAoB,GAAG,KAAK,CAAU,IAAI,2FAAC;AAC3C,IAAA,eAAe,GAAG,KAAK,CAAU,IAAI,sFAAC;AACtC,IAAA,gBAAgB,GAAG,KAAK,CAAS,OAAO,uFAAC;IACzC,UAAU,GAAG,KAAK,CAAgB,IAAI,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mBAAmB;oBAC7B,eAAe,EAAE,uBAAuB,CAAC,MAAM;AAC/C,oBAAA,IAAI,EAAE,EAAE,SAAS,EAAE,WAAW,EAAE;AAChC,oBAAA,QAAQ,EAAE,CAAA,cAAA,CAAgB;AAC3B,iBAAA;;MAYY,qBAAqB,CAAA;AACvB,IAAA,KAAK,GAAG,KAAK,CAAS,EAAE,4EAAC;AACf,IAAA,OAAO,GAAG,QAAQ,CAAC,MACpC,EAAE,CAAC,iEAAiE,EAAE,IAAI,CAAC,KAAK,EAAE,CAAC,8EACpF;wGAJU,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAArB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,qBAAqB,gQAFtB,CAAA,cAAA,CAAgB,EAAA,QAAA,EAAA,IAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FAEf,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBANjC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,kBAAkB;oBAC5B,eAAe,EAAE,uBAAuB,CAAC,MAAM;AAC/C,oBAAA,IAAI,EAAE,EAAE,SAAS,EAAE,WAAW,EAAE;AAChC,oBAAA,QAAQ,EAAE,CAAA,cAAA,CAAgB;AAC3B,iBAAA;;;ACpDD;;AAEG;;;;"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { SheetCloseDirective as DrawerCloseDirective, SheetComponent as DrawerComponent, SheetContentComponent as DrawerContentComponent, SheetDescriptionComponent as DrawerDescriptionComponent, SheetFooterComponent as DrawerFooterComponent, SheetHeaderComponent as DrawerHeaderComponent, SheetTitleComponent as DrawerTitleComponent } from '@ojiepermana/angular/component/sheet';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Generated bundle index. Do not edit.
|
|
5
|
+
*/
|
|
6
|
+
//# sourceMappingURL=ojiepermana-angular-ui-component-drawer.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ojiepermana-angular-ui-component-drawer.mjs","sources":["../../../projects/angular/ui/component/drawer/ojiepermana-angular-ui-component-drawer.ts"],"sourcesContent":["/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;AAAA;;AAEG"}
|