@wirabyte/ui 1.0.0-beta.0 → 1.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/CHANGELOG.md +42 -0
- package/README.md +6 -6
- package/avatar/avatar.component.d.ts +4 -2
- package/avatar/avatar.types.d.ts +3 -0
- package/breadcrumb/breadcrumb.component.d.ts +3 -1
- package/button/button.styles.d.ts +1 -1
- package/chat/chat.component.d.ts +118 -0
- package/chat/chat.module.d.ts +8 -0
- package/chat/chat.types.d.ts +64 -0
- package/chat/index.d.ts +5 -0
- package/chat/public-api.d.ts +3 -0
- package/config/options.d.ts +13 -0
- package/config/theme.service.d.ts +5 -0
- package/config/wu-config.service.d.ts +16 -0
- package/core/catalog.d.ts +6 -1
- package/core/overrides.d.ts +7 -0
- package/core/thai/locale.d.ts +47 -0
- package/datepicker/datepicker.component.d.ts +3 -2
- package/descriptions/descriptions.component.d.ts +56 -0
- package/descriptions/descriptions.module.d.ts +8 -0
- package/descriptions/index.d.ts +5 -0
- package/descriptions/public-api.d.ts +2 -0
- package/esm2020/accordion/accordion.component.mjs +4 -4
- package/esm2020/alert/alert-dialog.component.mjs +3 -3
- package/esm2020/asidemenu/asidemenu.component.mjs +3 -3
- package/esm2020/avatar/avatar.component.mjs +10 -5
- package/esm2020/avatar/avatar.types.mjs +2 -2
- package/esm2020/breadcrumb/breadcrumb.component.mjs +5 -3
- package/esm2020/button/button.component.mjs +3 -3
- package/esm2020/button/button.styles.mjs +2 -2
- package/esm2020/card/card.component.mjs +8 -8
- package/esm2020/chat/chat.component.mjs +370 -0
- package/esm2020/chat/chat.module.mjs +17 -0
- package/esm2020/chat/chat.types.mjs +2 -0
- package/esm2020/chat/public-api.mjs +4 -0
- package/esm2020/chat/wirabyte-ui-chat.mjs +5 -0
- package/esm2020/config/options.mjs +1 -1
- package/esm2020/config/theme.service.mjs +35 -3
- package/esm2020/config/wu-config.service.mjs +22 -1
- package/esm2020/core/catalog.mjs +22 -2
- package/esm2020/core/families.mjs +43 -1
- package/esm2020/core/overrides.mjs +26 -1
- package/esm2020/core/thai/locale.mjs +67 -1
- package/esm2020/datepicker/datepicker.component.mjs +5 -4
- package/esm2020/descriptions/descriptions.component.mjs +112 -0
- package/esm2020/descriptions/descriptions.module.mjs +17 -0
- package/esm2020/descriptions/public-api.mjs +3 -0
- package/esm2020/descriptions/wirabyte-ui-descriptions.mjs +5 -0
- package/esm2020/dialog/dialog.component.mjs +3 -3
- package/esm2020/drawer/drawer.component.mjs +3 -3
- package/esm2020/emptystate/emptystate.component.mjs +3 -3
- package/esm2020/errorpage/errorpage.component.mjs +3 -3
- package/esm2020/fieldset/fieldset.component.mjs +4 -4
- package/esm2020/metergroup/metergroup.component.mjs +29 -5
- package/esm2020/metergroup/metergroup.types.mjs +1 -1
- package/esm2020/navbar/navbar.component.mjs +3 -3
- package/esm2020/panel/panel.component.mjs +6 -6
- package/esm2020/popover/popover.base.mjs +3 -3
- package/esm2020/result/result.component.mjs +3 -3
- package/esm2020/scheduler/public-api.mjs +4 -0
- package/esm2020/scheduler/scheduler.component.mjs +484 -0
- package/esm2020/scheduler/scheduler.module.mjs +17 -0
- package/esm2020/scheduler/scheduler.types.mjs +2 -0
- package/esm2020/scheduler/wirabyte-ui-scheduler.mjs +5 -0
- package/esm2020/selectbutton/selectbutton.component.mjs +23 -5
- package/esm2020/signaturepad/public-api.mjs +3 -0
- package/esm2020/signaturepad/signaturepad.component.mjs +289 -0
- package/esm2020/signaturepad/signaturepad.module.mjs +17 -0
- package/esm2020/signaturepad/wirabyte-ui-signaturepad.mjs +5 -0
- package/esm2020/sitefooter/sitefooter.component.mjs +2 -2
- package/esm2020/stat/public-api.mjs +3 -0
- package/esm2020/stat/stat.component.mjs +128 -0
- package/esm2020/stat/stat.module.mjs +17 -0
- package/esm2020/stat/wirabyte-ui-stat.mjs +5 -0
- package/esm2020/table/table.celleditor.mjs +4 -4
- package/esm2020/tabs/tabs.component.mjs +3 -3
- package/esm2020/tag/tag.component.mjs +3 -3
- package/esm2020/textarea/textarea.directive.mjs +33 -1
- package/esm2020/thai/thai.pipes.mjs +3 -3
- package/esm2020/toolbar/toolbar.component.mjs +7 -7
- package/fesm2015/wirabyte-ui-accordion.mjs +3 -3
- package/fesm2015/wirabyte-ui-accordion.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-alert.mjs +2 -2
- package/fesm2015/wirabyte-ui-alert.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-asidemenu.mjs +2 -2
- package/fesm2015/wirabyte-ui-asidemenu.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-avatar.mjs +11 -5
- package/fesm2015/wirabyte-ui-avatar.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-breadcrumb.mjs +4 -2
- package/fesm2015/wirabyte-ui-breadcrumb.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-button.mjs +3 -3
- package/fesm2015/wirabyte-ui-button.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-card.mjs +7 -7
- package/fesm2015/wirabyte-ui-card.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-chat.mjs +399 -0
- package/fesm2015/wirabyte-ui-chat.mjs.map +1 -0
- package/fesm2015/wirabyte-ui-config.mjs +55 -2
- package/fesm2015/wirabyte-ui-config.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-core.mjs +147 -2
- package/fesm2015/wirabyte-ui-core.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-datepicker.mjs +5 -4
- package/fesm2015/wirabyte-ui-datepicker.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-descriptions.mjs +133 -0
- package/fesm2015/wirabyte-ui-descriptions.mjs.map +1 -0
- package/fesm2015/wirabyte-ui-dialog.mjs +2 -2
- package/fesm2015/wirabyte-ui-dialog.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-drawer.mjs +2 -2
- package/fesm2015/wirabyte-ui-drawer.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-emptystate.mjs +2 -2
- package/fesm2015/wirabyte-ui-emptystate.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-errorpage.mjs +2 -2
- package/fesm2015/wirabyte-ui-errorpage.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-fieldset.mjs +3 -3
- package/fesm2015/wirabyte-ui-fieldset.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-metergroup.mjs +29 -4
- package/fesm2015/wirabyte-ui-metergroup.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-navbar.mjs +2 -2
- package/fesm2015/wirabyte-ui-navbar.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-panel.mjs +5 -5
- package/fesm2015/wirabyte-ui-panel.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-popover.mjs +2 -2
- package/fesm2015/wirabyte-ui-popover.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-result.mjs +2 -2
- package/fesm2015/wirabyte-ui-result.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-scheduler.mjs +515 -0
- package/fesm2015/wirabyte-ui-scheduler.mjs.map +1 -0
- package/fesm2015/wirabyte-ui-selectbutton.mjs +22 -4
- package/fesm2015/wirabyte-ui-selectbutton.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-signaturepad.mjs +313 -0
- package/fesm2015/wirabyte-ui-signaturepad.mjs.map +1 -0
- package/fesm2015/wirabyte-ui-sitefooter.mjs +1 -1
- package/fesm2015/wirabyte-ui-sitefooter.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-stat.mjs +151 -0
- package/fesm2015/wirabyte-ui-stat.mjs.map +1 -0
- package/fesm2015/wirabyte-ui-table.mjs +3 -3
- package/fesm2015/wirabyte-ui-table.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-tabs.mjs +2 -2
- package/fesm2015/wirabyte-ui-tabs.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-tag.mjs +2 -2
- package/fesm2015/wirabyte-ui-tag.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-textarea.mjs +32 -0
- package/fesm2015/wirabyte-ui-textarea.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-thai.mjs +2 -2
- package/fesm2015/wirabyte-ui-thai.mjs.map +1 -1
- package/fesm2015/wirabyte-ui-toolbar.mjs +6 -6
- package/fesm2015/wirabyte-ui-toolbar.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-accordion.mjs +3 -3
- package/fesm2020/wirabyte-ui-accordion.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-alert.mjs +2 -2
- package/fesm2020/wirabyte-ui-alert.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-asidemenu.mjs +2 -2
- package/fesm2020/wirabyte-ui-asidemenu.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-avatar.mjs +11 -5
- package/fesm2020/wirabyte-ui-avatar.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-breadcrumb.mjs +4 -2
- package/fesm2020/wirabyte-ui-breadcrumb.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-button.mjs +3 -3
- package/fesm2020/wirabyte-ui-button.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-card.mjs +7 -7
- package/fesm2020/wirabyte-ui-card.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-chat.mjs +391 -0
- package/fesm2020/wirabyte-ui-chat.mjs.map +1 -0
- package/fesm2020/wirabyte-ui-config.mjs +55 -2
- package/fesm2020/wirabyte-ui-config.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-core.mjs +155 -2
- package/fesm2020/wirabyte-ui-core.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-datepicker.mjs +5 -4
- package/fesm2020/wirabyte-ui-datepicker.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-descriptions.mjs +133 -0
- package/fesm2020/wirabyte-ui-descriptions.mjs.map +1 -0
- package/fesm2020/wirabyte-ui-dialog.mjs +2 -2
- package/fesm2020/wirabyte-ui-dialog.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-drawer.mjs +2 -2
- package/fesm2020/wirabyte-ui-drawer.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-emptystate.mjs +2 -2
- package/fesm2020/wirabyte-ui-emptystate.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-errorpage.mjs +2 -2
- package/fesm2020/wirabyte-ui-errorpage.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-fieldset.mjs +3 -3
- package/fesm2020/wirabyte-ui-fieldset.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-metergroup.mjs +28 -4
- package/fesm2020/wirabyte-ui-metergroup.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-navbar.mjs +2 -2
- package/fesm2020/wirabyte-ui-navbar.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-panel.mjs +5 -5
- package/fesm2020/wirabyte-ui-panel.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-popover.mjs +2 -2
- package/fesm2020/wirabyte-ui-popover.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-result.mjs +2 -2
- package/fesm2020/wirabyte-ui-result.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-scheduler.mjs +505 -0
- package/fesm2020/wirabyte-ui-scheduler.mjs.map +1 -0
- package/fesm2020/wirabyte-ui-selectbutton.mjs +22 -4
- package/fesm2020/wirabyte-ui-selectbutton.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-signaturepad.mjs +310 -0
- package/fesm2020/wirabyte-ui-signaturepad.mjs.map +1 -0
- package/fesm2020/wirabyte-ui-sitefooter.mjs +1 -1
- package/fesm2020/wirabyte-ui-sitefooter.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-stat.mjs +149 -0
- package/fesm2020/wirabyte-ui-stat.mjs.map +1 -0
- package/fesm2020/wirabyte-ui-table.mjs +3 -3
- package/fesm2020/wirabyte-ui-table.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-tabs.mjs +2 -2
- package/fesm2020/wirabyte-ui-tabs.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-tag.mjs +2 -2
- package/fesm2020/wirabyte-ui-tag.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-textarea.mjs +32 -0
- package/fesm2020/wirabyte-ui-textarea.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-thai.mjs +2 -2
- package/fesm2020/wirabyte-ui-thai.mjs.map +1 -1
- package/fesm2020/wirabyte-ui-toolbar.mjs +6 -6
- package/fesm2020/wirabyte-ui-toolbar.mjs.map +1 -1
- package/metergroup/metergroup.component.d.ts +16 -3
- package/metergroup/metergroup.types.d.ts +6 -0
- package/package.json +41 -1
- package/scheduler/index.d.ts +5 -0
- package/scheduler/public-api.d.ts +3 -0
- package/scheduler/scheduler.component.d.ts +143 -0
- package/scheduler/scheduler.module.d.ts +8 -0
- package/scheduler/scheduler.types.d.ts +46 -0
- package/schematics/core/catalog.cjs +22 -1
- package/schematics/core/families.cjs +42 -0
- package/schematics/core/overrides.cjs +25 -0
- package/schematics/core/thai/locale.cjs +66 -0
- package/schematics/ng-add/index.cjs +3 -1
- package/selectbutton/selectbutton.component.d.ts +12 -1
- package/signaturepad/index.d.ts +5 -0
- package/signaturepad/public-api.d.ts +2 -0
- package/signaturepad/signaturepad.component.d.ts +98 -0
- package/signaturepad/signaturepad.module.d.ts +8 -0
- package/stat/index.d.ts +5 -0
- package/stat/public-api.d.ts +2 -0
- package/stat/stat.component.d.ts +61 -0
- package/stat/stat.module.d.ts +8 -0
- package/textarea/textarea.directive.d.ts +3 -0
- package/theme/_data.scss +239 -7
- package/theme/_index.scss +29 -0
- package/themes/arun-blue/theme.css +30 -1
- package/themes/arun-green/theme.css +30 -1
- package/themes/arun-orange/theme.css +30 -1
- package/themes/arun-purple/theme.css +30 -1
- package/themes/md-dark-deeppurple/theme.css +30 -1
- package/themes/md-dark-indigo/theme.css +30 -1
- package/themes/md-light-deeppurple/theme.css +30 -1
- package/themes/md-light-indigo/theme.css +30 -1
- package/themes/ratri-blue/theme.css +30 -1
- package/themes/ratri-green/theme.css +30 -1
- package/themes/ratri-orange/theme.css +30 -1
- package/themes/ratri-purple/theme.css +30 -1
- package/themes/sayan-blue/theme.css +30 -1
- package/themes/sayan-green/theme.css +30 -1
- package/themes/sayan-orange/theme.css +30 -1
- package/themes/sayan-purple/theme.css +30 -1
- package/themes/sila-dark-blue/theme.css +30 -1
- package/themes/sila-dark-indigo/theme.css +30 -1
- package/themes/sila-dark-purple/theme.css +30 -1
- package/themes/sila-dark-teal/theme.css +30 -1
- package/themes/sila-light-blue/theme.css +30 -1
- package/themes/sila-light-indigo/theme.css +30 -1
- package/themes/sila-light-purple/theme.css +30 -1
- package/themes/sila-light-teal/theme.css +30 -1
- package/themes/sila-light-wira/theme.css +30 -1
|
@@ -74,22 +74,22 @@ class WuPanel {
|
|
|
74
74
|
}
|
|
75
75
|
}
|
|
76
76
|
WuPanel.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: WuPanel, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
77
|
-
WuPanel.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: WuPanel, isStandalone: true, selector: "wu-panel", inputs: { header: "header", toggleable: "toggleable", collapsed: "collapsed", toggler: "toggler", styleClass: "styleClass", style: "style" }, outputs: { collapsedChange: "collapsedChange", onToggle: "onToggle" }, queries: [{ propertyName: "headerRef", first: true, predicate: ["header"],
|
|
77
|
+
WuPanel.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: WuPanel, isStandalone: true, selector: "wu-panel", inputs: { header: "header", toggleable: "toggleable", collapsed: "collapsed", toggler: "toggler", styleClass: "styleClass", style: "style" }, outputs: { collapsedChange: "collapsedChange", onToggle: "onToggle" }, queries: [{ propertyName: "headerRef", first: true, predicate: ["header"], read: TemplateRef }, { propertyName: "iconsRef", first: true, predicate: ["icons"], read: TemplateRef }, { propertyName: "footerRef", first: true, predicate: ["footer"], read: TemplateRef }, { propertyName: "slotTemplates", predicate: WuTemplate }], ngImport: i0, template: "<div [class]=\"classes\" [style]=\"rootStyle\">\n <div class=\"wu-panel-header p-panel-header\" [style.cursor]=\"toggleable && toggler === 'header' ? 'pointer' : null\" (click)=\"headerClick()\">\n <span *ngIf=\"header\" class=\"wu-panel-title p-panel-title\" [id]=\"titleId\">{{ header }}</span>\n <ng-container *ngIf=\"headerTemplate\"><ng-container *ngTemplateOutlet=\"headerTemplate\"></ng-container></ng-container>\n <ng-content select=\"[wuPanelHeader], wu-header\"></ng-content>\n <div class=\"wu-panel-icons p-panel-icons\">\n <ng-content select=\"[wuPanelIcons]\"></ng-content>\n <ng-container *ngIf=\"iconsTemplate\"><ng-container *ngTemplateOutlet=\"iconsTemplate\"></ng-container></ng-container>\n <button\n *ngIf=\"toggleable\"\n type=\"button\"\n class=\"wu-panel-toggler p-panel-header-icon p-panel-toggler p-link\"\n [attr.aria-expanded]=\"!isCollapsed\"\n [attr.aria-controls]=\"contentId\"\n [attr.aria-label]=\"togglerLabel\"\n (click)=\"toggle($event)\"\n >\n <svg *ngIf=\"isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M8 3v10M3 8h10\"></path></svg>\n <svg *ngIf=\"!isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M3 8h10\"></path></svg>\n </button>\n </div>\n </div>\n <div\n class=\"wu-panel-content-container p-toggleable-content\"\n [id]=\"contentId\"\n role=\"region\"\n [attr.aria-labelledby]=\"header ? titleId : null\"\n [attr.inert]=\"isCollapsed ? '' : null\"\n >\n <div class=\"wu-panel-content-inner\">\n <div class=\"wu-panel-content p-panel-content\"><ng-content></ng-content></div>\n <div class=\"wu-panel-footer p-panel-footer\"><ng-content select=\"[wuPanelFooter], wu-footer\"></ng-content><ng-container *ngIf=\"footerTemplate\"><ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container></ng-container></div>\n </div>\n </div>\n</div>\n", styles: ["@layer wiraui.components{wu-panel{display:block}.wu-panel{border:var(--wu-panel-border-width) solid var(--wu-border);border-radius:var(--wu-panel-radius);background:var(--wu-card-bg);color:var(--wu-text);font-family:var(--wu-font-family);font-size:var(--wu-font-size);line-height:var(--wu-line-height)}.wu-panel-header{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:var(--wu-panel-header-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-radius:var(--wu-panel-radius) var(--wu-panel-radius) 0 0;background:var(--wu-panel-header-bg);color:var(--wu-panel-header-color)}.wu-panel-collapsed .wu-panel-header{border-radius:var(--wu-panel-radius)}.wu-panel-title{font-family:var(--wu-heading-font-family);min-width:0;font-weight:var(--wu-panel-header-weight)}.wu-panel-icons{display:flex;align-items:center;gap:.25rem;margin-left:auto;margin-block:calc((var(--wu-line-height) * 1em - 2rem) / 2)}.wu-panel-icons .wu-btn-icon-only{width:2rem;height:2rem;padding:0}.wu-panel-toggler{flex:none;display:inline-grid;place-items:center;width:2rem;height:2rem;padding:0;border:0;border-radius:50%;background:transparent;color:var(--wu-text-muted);cursor:pointer;transition:background-color var(--wu-transition),color var(--wu-transition)}.wu-panel-toggler:hover{background:var(--wu-hover-bg);color:var(--wu-text)}.wu-panel-toggler:focus-visible{outline:var(--wu-control-focus-outline);outline-offset:var(--wu-control-focus-offset);box-shadow:var(--wu-control-focus-shadow)}.wu-panel-toggler svg{width:.875rem;height:.875rem}.wu-panel-content-container{display:grid;grid-template-rows:1fr;transition:grid-template-rows var(--wu-transition) ease}.wu-panel-collapsed .wu-panel-content-container{grid-template-rows:0fr}.wu-panel-content-inner{min-height:0;overflow:hidden}.wu-panel-content{padding:var(--wu-panel-content-padding-top) var(--wu-panel-content-padding) var(--wu-panel-content-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-top:0;border-radius:0 0 var(--wu-panel-radius) var(--wu-panel-radius)}.wu-panel-content:has(+ .wu-panel-footer:not(:empty)){border-radius:0}.wu-panel-footer{padding:0 var(--wu-panel-content-padding) var(--wu-panel-content-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-top:0;border-radius:0 0 var(--wu-panel-radius) var(--wu-panel-radius)}.wu-panel-footer>[wuPanelFooter]:has(> wu-button,> button,> a,> .wu-btn){display:flex;flex-wrap:wrap;align-items:center;gap:.5rem}.wu-panel-footer:empty{display:none}@media (prefers-reduced-motion: reduce){.wu-panel-content-container{transition:none}}}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
78
78
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: WuPanel, decorators: [{
|
|
79
79
|
type: Component,
|
|
80
|
-
args: [{ selector: 'wu-panel', standalone: true, imports: [NgIf, NgTemplateOutlet], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [class]=\"classes\" [style]=\"rootStyle\">\n <div class=\"wu-panel-header p-panel-header\" [style.cursor]=\"toggleable && toggler === 'header' ? 'pointer' : null\" (click)=\"headerClick()\">\n <span *ngIf=\"header\" class=\"wu-panel-title p-panel-title\" [id]=\"titleId\">{{ header }}</span>\n <ng-container *ngIf=\"headerTemplate\"><ng-container *ngTemplateOutlet=\"headerTemplate\"></ng-container></ng-container>\n <ng-content select=\"[wuPanelHeader], wu-header\"></ng-content>\n <div class=\"wu-panel-icons p-panel-icons\">\n <ng-content select=\"[wuPanelIcons]\"></ng-content>\n <ng-container *ngIf=\"iconsTemplate\"><ng-container *ngTemplateOutlet=\"iconsTemplate\"></ng-container></ng-container>\n <button\n *ngIf=\"toggleable\"\n type=\"button\"\n class=\"wu-panel-toggler p-panel-header-icon p-panel-toggler p-link\"\n [attr.aria-expanded]=\"!isCollapsed\"\n [attr.aria-controls]=\"contentId\"\n [attr.aria-label]=\"togglerLabel\"\n (click)=\"toggle($event)\"\n >\n <svg *ngIf=\"isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M8 3v10M3 8h10\"></path></svg>\n <svg *ngIf=\"!isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M3 8h10\"></path></svg>\n </button>\n </div>\n </div>\n <div\n class=\"wu-panel-content-container p-toggleable-content\"\n [id]=\"contentId\"\n role=\"region\"\n [attr.aria-labelledby]=\"header ? titleId : null\"\n [attr.inert]=\"isCollapsed ? '' : null\"\n >\n <div class=\"wu-panel-content-inner\">\n <div class=\"wu-panel-content p-panel-content\"><ng-content></ng-content></div>\n <div class=\"wu-panel-footer p-panel-footer\"><ng-content select=\"[wuPanelFooter], wu-footer\"></ng-content><ng-container *ngIf=\"footerTemplate\"><ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container></ng-container></div>\n </div>\n </div>\n</div>\n", styles: ["@layer wiraui.components{wu-panel{display:block}.wu-panel{border:var(--wu-panel-border-width) solid var(--wu-border);border-radius:var(--wu-panel-radius);background:var(--wu-card-bg);color:var(--wu-text);font-family:var(--wu-font-family);font-size:var(--wu-font-size);line-height:var(--wu-line-height)}.wu-panel-header{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:var(--wu-panel-header-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-radius:var(--wu-panel-radius) var(--wu-panel-radius) 0 0;background:var(--wu-panel-header-bg);color:var(--wu-panel-header-color)}.wu-panel-collapsed .wu-panel-header{border-radius:var(--wu-panel-radius)}.wu-panel-title{min-width:0;font-weight:var(--wu-panel-header-weight)}.wu-panel-icons{display:flex;align-items:center;gap:.25rem;margin-left:auto;margin-block:calc((var(--wu-line-height) * 1em - 2rem) / 2)}.wu-panel-icons .wu-btn-icon-only{width:2rem;height:2rem;padding:0}.wu-panel-toggler{flex:none;display:inline-grid;place-items:center;width:2rem;height:2rem;padding:0;border:0;border-radius:50%;background:transparent;color:var(--wu-text-muted);cursor:pointer;transition:background-color var(--wu-transition),color var(--wu-transition)}.wu-panel-toggler:hover{background:var(--wu-hover-bg);color:var(--wu-text)}.wu-panel-toggler:focus-visible{outline:var(--wu-control-focus-outline);outline-offset:var(--wu-control-focus-offset);box-shadow:var(--wu-control-focus-shadow)}.wu-panel-toggler svg{width:.875rem;height:.875rem}.wu-panel-content-container{display:grid;grid-template-rows:1fr;transition:grid-template-rows var(--wu-transition) ease}.wu-panel-collapsed .wu-panel-content-container{grid-template-rows:0fr}.wu-panel-content-inner{min-height:0;overflow:hidden}.wu-panel-content{padding:var(--wu-panel-content-padding-top) var(--wu-panel-content-padding) var(--wu-panel-content-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-top:0;border-radius:0 0 var(--wu-panel-radius) var(--wu-panel-radius)}.wu-panel-content:has(+ .wu-panel-footer:not(:empty)){border-radius:0}.wu-panel-footer{padding:0 var(--wu-panel-content-padding) var(--wu-panel-content-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-top:0;border-radius:0 0 var(--wu-panel-radius) var(--wu-panel-radius)}.wu-panel-footer>[wuPanelFooter]:has(> wu-button,> button,> a,> .wu-btn){display:flex;flex-wrap:wrap;align-items:center;gap:.5rem}.wu-panel-footer:empty{display:none}@media (prefers-reduced-motion: reduce){.wu-panel-content-container{transition:none}}}\n"] }]
|
|
80
|
+
args: [{ selector: 'wu-panel', standalone: true, imports: [NgIf, NgTemplateOutlet], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [class]=\"classes\" [style]=\"rootStyle\">\n <div class=\"wu-panel-header p-panel-header\" [style.cursor]=\"toggleable && toggler === 'header' ? 'pointer' : null\" (click)=\"headerClick()\">\n <span *ngIf=\"header\" class=\"wu-panel-title p-panel-title\" [id]=\"titleId\">{{ header }}</span>\n <ng-container *ngIf=\"headerTemplate\"><ng-container *ngTemplateOutlet=\"headerTemplate\"></ng-container></ng-container>\n <ng-content select=\"[wuPanelHeader], wu-header\"></ng-content>\n <div class=\"wu-panel-icons p-panel-icons\">\n <ng-content select=\"[wuPanelIcons]\"></ng-content>\n <ng-container *ngIf=\"iconsTemplate\"><ng-container *ngTemplateOutlet=\"iconsTemplate\"></ng-container></ng-container>\n <button\n *ngIf=\"toggleable\"\n type=\"button\"\n class=\"wu-panel-toggler p-panel-header-icon p-panel-toggler p-link\"\n [attr.aria-expanded]=\"!isCollapsed\"\n [attr.aria-controls]=\"contentId\"\n [attr.aria-label]=\"togglerLabel\"\n (click)=\"toggle($event)\"\n >\n <svg *ngIf=\"isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M8 3v10M3 8h10\"></path></svg>\n <svg *ngIf=\"!isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M3 8h10\"></path></svg>\n </button>\n </div>\n </div>\n <div\n class=\"wu-panel-content-container p-toggleable-content\"\n [id]=\"contentId\"\n role=\"region\"\n [attr.aria-labelledby]=\"header ? titleId : null\"\n [attr.inert]=\"isCollapsed ? '' : null\"\n >\n <div class=\"wu-panel-content-inner\">\n <div class=\"wu-panel-content p-panel-content\"><ng-content></ng-content></div>\n <div class=\"wu-panel-footer p-panel-footer\"><ng-content select=\"[wuPanelFooter], wu-footer\"></ng-content><ng-container *ngIf=\"footerTemplate\"><ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container></ng-container></div>\n </div>\n </div>\n</div>\n", styles: ["@layer wiraui.components{wu-panel{display:block}.wu-panel{border:var(--wu-panel-border-width) solid var(--wu-border);border-radius:var(--wu-panel-radius);background:var(--wu-card-bg);color:var(--wu-text);font-family:var(--wu-font-family);font-size:var(--wu-font-size);line-height:var(--wu-line-height)}.wu-panel-header{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:var(--wu-panel-header-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-radius:var(--wu-panel-radius) var(--wu-panel-radius) 0 0;background:var(--wu-panel-header-bg);color:var(--wu-panel-header-color)}.wu-panel-collapsed .wu-panel-header{border-radius:var(--wu-panel-radius)}.wu-panel-title{font-family:var(--wu-heading-font-family);min-width:0;font-weight:var(--wu-panel-header-weight)}.wu-panel-icons{display:flex;align-items:center;gap:.25rem;margin-left:auto;margin-block:calc((var(--wu-line-height) * 1em - 2rem) / 2)}.wu-panel-icons .wu-btn-icon-only{width:2rem;height:2rem;padding:0}.wu-panel-toggler{flex:none;display:inline-grid;place-items:center;width:2rem;height:2rem;padding:0;border:0;border-radius:50%;background:transparent;color:var(--wu-text-muted);cursor:pointer;transition:background-color var(--wu-transition),color var(--wu-transition)}.wu-panel-toggler:hover{background:var(--wu-hover-bg);color:var(--wu-text)}.wu-panel-toggler:focus-visible{outline:var(--wu-control-focus-outline);outline-offset:var(--wu-control-focus-offset);box-shadow:var(--wu-control-focus-shadow)}.wu-panel-toggler svg{width:.875rem;height:.875rem}.wu-panel-content-container{display:grid;grid-template-rows:1fr;transition:grid-template-rows var(--wu-transition) ease}.wu-panel-collapsed .wu-panel-content-container{grid-template-rows:0fr}.wu-panel-content-inner{min-height:0;overflow:hidden}.wu-panel-content{padding:var(--wu-panel-content-padding-top) var(--wu-panel-content-padding) var(--wu-panel-content-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-top:0;border-radius:0 0 var(--wu-panel-radius) var(--wu-panel-radius)}.wu-panel-content:has(+ .wu-panel-footer:not(:empty)){border-radius:0}.wu-panel-footer{padding:0 var(--wu-panel-content-padding) var(--wu-panel-content-padding);border:var(--wu-panel-section-border-width) solid var(--wu-border);border-top:0;border-radius:0 0 var(--wu-panel-radius) var(--wu-panel-radius)}.wu-panel-footer>[wuPanelFooter]:has(> wu-button,> button,> a,> .wu-btn){display:flex;flex-wrap:wrap;align-items:center;gap:.5rem}.wu-panel-footer:empty{display:none}@media (prefers-reduced-motion: reduce){.wu-panel-content-container{transition:none}}}\n"] }]
|
|
81
81
|
}], ctorParameters: function () { return []; }, propDecorators: { slotTemplates: [{
|
|
82
82
|
type: ContentChildren,
|
|
83
83
|
args: [WuTemplate]
|
|
84
84
|
}], headerRef: [{
|
|
85
85
|
type: ContentChild,
|
|
86
|
-
args: ['header', { read: TemplateRef }]
|
|
86
|
+
args: ['header', { read: TemplateRef, descendants: false }]
|
|
87
87
|
}], iconsRef: [{
|
|
88
88
|
type: ContentChild,
|
|
89
|
-
args: ['icons', { read: TemplateRef }]
|
|
89
|
+
args: ['icons', { read: TemplateRef, descendants: false }]
|
|
90
90
|
}], footerRef: [{
|
|
91
91
|
type: ContentChild,
|
|
92
|
-
args: ['footer', { read: TemplateRef }]
|
|
92
|
+
args: ['footer', { read: TemplateRef, descendants: false }]
|
|
93
93
|
}], header: [{
|
|
94
94
|
type: Input
|
|
95
95
|
}], toggleable: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wirabyte-ui-panel.mjs","sources":["../../lib/panel/panel.component.ts","../../lib/panel/panel.component.html","../../lib/panel/panel.module.ts","../../lib/panel/wirabyte-ui-panel.ts"],"sourcesContent":["import { NgIf, NgTemplateOutlet } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ContentChild,\n ContentChildren,\n EventEmitter,\n inject,\n Input,\n OnDestroy,\n Output,\n QueryList,\n TemplateRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport { ɵassertSupportedAngular, ɵfindTemplate, ɵrefreshOnTranslation, ɵtoBool, ɵuniqueId, ɵWU_SKIP_VERSION_CHECK, WuConfig, WuTemplate } from '@wirabyte/ui/config';\nimport { WuPanelToggler } from './panel.types';\n\n/**\n * Titled box that can collapse: `<wu-panel header=\"รายละเอียด\" toggleable [(collapsed)]=\"closed\">`.\n * Slots: `[wuPanelHeader]` (extra header content), `[wuPanelIcons]` (buttons next to the toggler), `[wuPanelFooter]`.\n */\n@Component({\n selector: 'wu-panel',\n standalone: true,\n imports: [NgIf, NgTemplateOutlet],\n templateUrl: './panel.component.html',\n styleUrls: ['./panel.css'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class WuPanel implements OnDestroy {\n @ContentChildren(WuTemplate) protected slotTemplates?: QueryList<WuTemplate>;\n @ContentChild('header', { read: TemplateRef }) protected headerRef?: TemplateRef<unknown>;\n get headerTemplate(): TemplateRef<unknown> | null {\n return this.headerRef || ɵfindTemplate(this.slotTemplates, 'header');\n }\n @ContentChild('icons', { read: TemplateRef }) protected iconsRef?: TemplateRef<unknown>;\n get iconsTemplate(): TemplateRef<unknown> | null {\n return this.iconsRef || ɵfindTemplate(this.slotTemplates, 'icons');\n }\n @ContentChild('footer', { read: TemplateRef }) protected footerRef?: TemplateRef<unknown>;\n get footerTemplate(): TemplateRef<unknown> | null {\n return this.footerRef || ɵfindTemplate(this.slotTemplates, 'footer');\n }\n @Input() header?: string;\n @Input() set toggleable(v: unknown) { this._toggleable = ɵtoBool(v); }\n get toggleable(): boolean { return this._toggleable; }\n /** Two-way: `[(collapsed)]`. */\n @Input() set collapsed(v: unknown) { this._collapsed = ɵtoBool(v); }\n get collapsed(): boolean { return this._collapsed; }\n @Input() toggler: WuPanelToggler = 'icon';\n\n @Output() readonly collapsedChange = new EventEmitter<boolean>();\n @Output() readonly onToggle = new EventEmitter<{ collapsed: boolean }>();\n\n readonly titleId = ɵuniqueId('wu-panel-title');\n readonly contentId = ɵuniqueId('wu-panel-content');\n private _toggleable = false;\n private _collapsed = false;\n private readonly config = inject(WuConfig);\n private readonly i18n = ɵrefreshOnTranslation();\n\n constructor() {\n ɵassertSupportedAngular(inject(ɵWU_SKIP_VERSION_CHECK, { optional: true }));\n }\n\n ngOnDestroy(): void {\n this.i18n.unsubscribe();\n }\n\n get isCollapsed(): boolean {\n return this._toggleable && this._collapsed;\n }\n\n /** Our classes plus the classic-era `p-*` names. */\n /** Classes for the root element, as before (`styleClass=\"w-full\"`). */\n @Input() styleClass?: string | null;\n /** Inline styles for the root element, as an object: `[style]=\"{ width: '20rem' }\"`. */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Input() style?: Record<string, any> | string | null;\n /** The `style` object for the root (a plain style attribute already styles the host). */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get rootStyle(): Record<string, any> | null {\n return this.style && typeof this.style === 'object' ? this.style : null;\n }\n get classes(): string {\n return [this.baseClasses, this.styleClass].filter(Boolean).join(' ');\n }\n get baseClasses(): string {\n const c = ['wu-panel', 'p-panel', 'p-component'];\n if (this._toggleable) c.push('wu-panel-toggleable', 'p-panel-toggleable');\n if (this.isCollapsed) c.push('wu-panel-collapsed');\n return c.join(' ');\n }\n\n get togglerLabel(): string {\n return this.isCollapsed ? this.config.translation.expand : this.config.translation.collapse;\n }\n\n toggle(event?: Event): void {\n event?.stopPropagation();\n if (!this._toggleable) return;\n this._collapsed = !this.isCollapsed;\n this.collapsedChange.emit(this._collapsed);\n this.onToggle.emit({ collapsed: this._collapsed });\n }\n\n headerClick(): void {\n if (this.toggler === 'header') this.toggle();\n }\n}\n","<div [class]=\"classes\" [style]=\"rootStyle\">\n <div class=\"wu-panel-header p-panel-header\" [style.cursor]=\"toggleable && toggler === 'header' ? 'pointer' : null\" (click)=\"headerClick()\">\n <span *ngIf=\"header\" class=\"wu-panel-title p-panel-title\" [id]=\"titleId\">{{ header }}</span>\n <ng-container *ngIf=\"headerTemplate\"><ng-container *ngTemplateOutlet=\"headerTemplate\"></ng-container></ng-container>\n <ng-content select=\"[wuPanelHeader], wu-header\"></ng-content>\n <div class=\"wu-panel-icons p-panel-icons\">\n <ng-content select=\"[wuPanelIcons]\"></ng-content>\n <ng-container *ngIf=\"iconsTemplate\"><ng-container *ngTemplateOutlet=\"iconsTemplate\"></ng-container></ng-container>\n <button\n *ngIf=\"toggleable\"\n type=\"button\"\n class=\"wu-panel-toggler p-panel-header-icon p-panel-toggler p-link\"\n [attr.aria-expanded]=\"!isCollapsed\"\n [attr.aria-controls]=\"contentId\"\n [attr.aria-label]=\"togglerLabel\"\n (click)=\"toggle($event)\"\n >\n <svg *ngIf=\"isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M8 3v10M3 8h10\"></path></svg>\n <svg *ngIf=\"!isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M3 8h10\"></path></svg>\n </button>\n </div>\n </div>\n <div\n class=\"wu-panel-content-container p-toggleable-content\"\n [id]=\"contentId\"\n role=\"region\"\n [attr.aria-labelledby]=\"header ? titleId : null\"\n [attr.inert]=\"isCollapsed ? '' : null\"\n >\n <div class=\"wu-panel-content-inner\">\n <div class=\"wu-panel-content p-panel-content\"><ng-content></ng-content></div>\n <div class=\"wu-panel-footer p-panel-footer\"><ng-content select=\"[wuPanelFooter], wu-footer\"></ng-content><ng-container *ngIf=\"footerTemplate\"><ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container></ng-container></div>\n </div>\n </div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { WuFooter, WuHeader } from '@wirabyte/ui/card';\nimport { WuTemplate } from '@wirabyte/ui/config';\nimport { WuPanel } from './panel.component';\n\n/** For NgModule apps. Standalone apps can import `WuPanel` directly. `<wu-header>` / `<wu-footer>` slots come with it. */\n@NgModule({\n imports: [WuPanel, WuHeader, WuFooter, WuTemplate],\n exports: [WuPanel, WuHeader, WuFooter, WuTemplate],\n})\nexport class WuPanelModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAkBA;;;AAGG;MAUU,OAAO,CAAA;AAGlB,IAAA,IAAI,cAAc,GAAA;AAChB,QAAA,OAAO,IAAI,CAAC,SAAS,IAAI,aAAa,CAAC,IAAI,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC;KACtE;AAED,IAAA,IAAI,aAAa,GAAA;AACf,QAAA,OAAO,IAAI,CAAC,QAAQ,IAAI,aAAa,CAAC,IAAI,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;KACpE;AAED,IAAA,IAAI,cAAc,GAAA;AAChB,QAAA,OAAO,IAAI,CAAC,SAAS,IAAI,aAAa,CAAC,IAAI,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC;KACtE;AAED,IAAA,IAAa,UAAU,CAAC,CAAU,EAAA,EAAI,IAAI,CAAC,WAAW,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE;IACtE,IAAI,UAAU,KAAc,OAAO,IAAI,CAAC,WAAW,CAAC,EAAE;;AAEtD,IAAA,IAAa,SAAS,CAAC,CAAU,EAAA,EAAI,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE;IACpE,IAAI,SAAS,KAAc,OAAO,IAAI,CAAC,UAAU,CAAC,EAAE;AAapD,IAAA,WAAA,GAAA;AAZS,QAAA,IAAO,CAAA,OAAA,GAAmB,MAAM,CAAC;AAEvB,QAAA,IAAA,CAAA,eAAe,GAAG,IAAI,YAAY,EAAW,CAAC;AAC9C,QAAA,IAAA,CAAA,QAAQ,GAAG,IAAI,YAAY,EAA0B,CAAC;AAEhE,QAAA,IAAA,CAAA,OAAO,GAAG,SAAS,CAAC,gBAAgB,CAAC,CAAC;AACtC,QAAA,IAAA,CAAA,SAAS,GAAG,SAAS,CAA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AAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,YAHd,OAAO,CAAA,EAAA,CAAA,CAAA;4FAGN,aAAa,EAAA,UAAA,EAAA,CAAA;kBAJzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,UAAU,CAAC;oBAClD,OAAO,EAAE,CAAC,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,UAAU,CAAC;iBACnD,CAAA;;;ACTD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"wirabyte-ui-panel.mjs","sources":["../../lib/panel/panel.component.ts","../../lib/panel/panel.component.html","../../lib/panel/panel.module.ts","../../lib/panel/wirabyte-ui-panel.ts"],"sourcesContent":["import { NgIf, NgTemplateOutlet } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ContentChild,\n ContentChildren,\n EventEmitter,\n inject,\n Input,\n OnDestroy,\n Output,\n QueryList,\n TemplateRef,\n ViewEncapsulation,\n} from '@angular/core';\nimport { ɵassertSupportedAngular, ɵfindTemplate, ɵrefreshOnTranslation, ɵtoBool, ɵuniqueId, ɵWU_SKIP_VERSION_CHECK, WuConfig, WuTemplate } from '@wirabyte/ui/config';\nimport { WuPanelToggler } from './panel.types';\n\n/**\n * Titled box that can collapse: `<wu-panel header=\"รายละเอียด\" toggleable [(collapsed)]=\"closed\">`.\n * Slots: `[wuPanelHeader]` (extra header content), `[wuPanelIcons]` (buttons next to the toggler), `[wuPanelFooter]`.\n */\n@Component({\n selector: 'wu-panel',\n standalone: true,\n imports: [NgIf, NgTemplateOutlet],\n templateUrl: './panel.component.html',\n styleUrls: ['./panel.css'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class WuPanel implements OnDestroy {\n @ContentChildren(WuTemplate) protected slotTemplates?: QueryList<WuTemplate>;\n @ContentChild('header', { read: TemplateRef, descendants: false }) protected headerRef?: TemplateRef<unknown>;\n get headerTemplate(): TemplateRef<unknown> | null {\n return this.headerRef || ɵfindTemplate(this.slotTemplates, 'header');\n }\n @ContentChild('icons', { read: TemplateRef, descendants: false }) protected iconsRef?: TemplateRef<unknown>;\n get iconsTemplate(): TemplateRef<unknown> | null {\n return this.iconsRef || ɵfindTemplate(this.slotTemplates, 'icons');\n }\n @ContentChild('footer', { read: TemplateRef, descendants: false }) protected footerRef?: TemplateRef<unknown>;\n get footerTemplate(): TemplateRef<unknown> | null {\n return this.footerRef || ɵfindTemplate(this.slotTemplates, 'footer');\n }\n @Input() header?: string;\n @Input() set toggleable(v: unknown) { this._toggleable = ɵtoBool(v); }\n get toggleable(): boolean { return this._toggleable; }\n /** Two-way: `[(collapsed)]`. */\n @Input() set collapsed(v: unknown) { this._collapsed = ɵtoBool(v); }\n get collapsed(): boolean { return this._collapsed; }\n @Input() toggler: WuPanelToggler = 'icon';\n\n @Output() readonly collapsedChange = new EventEmitter<boolean>();\n @Output() readonly onToggle = new EventEmitter<{ collapsed: boolean }>();\n\n readonly titleId = ɵuniqueId('wu-panel-title');\n readonly contentId = ɵuniqueId('wu-panel-content');\n private _toggleable = false;\n private _collapsed = false;\n private readonly config = inject(WuConfig);\n private readonly i18n = ɵrefreshOnTranslation();\n\n constructor() {\n ɵassertSupportedAngular(inject(ɵWU_SKIP_VERSION_CHECK, { optional: true }));\n }\n\n ngOnDestroy(): void {\n this.i18n.unsubscribe();\n }\n\n get isCollapsed(): boolean {\n return this._toggleable && this._collapsed;\n }\n\n /** Our classes plus the classic-era `p-*` names. */\n /** Classes for the root element, as before (`styleClass=\"w-full\"`). */\n @Input() styleClass?: string | null;\n /** Inline styles for the root element, as an object: `[style]=\"{ width: '20rem' }\"`. */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Input() style?: Record<string, any> | string | null;\n /** The `style` object for the root (a plain style attribute already styles the host). */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get rootStyle(): Record<string, any> | null {\n return this.style && typeof this.style === 'object' ? this.style : null;\n }\n get classes(): string {\n return [this.baseClasses, this.styleClass].filter(Boolean).join(' ');\n }\n get baseClasses(): string {\n const c = ['wu-panel', 'p-panel', 'p-component'];\n if (this._toggleable) c.push('wu-panel-toggleable', 'p-panel-toggleable');\n if (this.isCollapsed) c.push('wu-panel-collapsed');\n return c.join(' ');\n }\n\n get togglerLabel(): string {\n return this.isCollapsed ? this.config.translation.expand : this.config.translation.collapse;\n }\n\n toggle(event?: Event): void {\n event?.stopPropagation();\n if (!this._toggleable) return;\n this._collapsed = !this.isCollapsed;\n this.collapsedChange.emit(this._collapsed);\n this.onToggle.emit({ collapsed: this._collapsed });\n }\n\n headerClick(): void {\n if (this.toggler === 'header') this.toggle();\n }\n}\n","<div [class]=\"classes\" [style]=\"rootStyle\">\n <div class=\"wu-panel-header p-panel-header\" [style.cursor]=\"toggleable && toggler === 'header' ? 'pointer' : null\" (click)=\"headerClick()\">\n <span *ngIf=\"header\" class=\"wu-panel-title p-panel-title\" [id]=\"titleId\">{{ header }}</span>\n <ng-container *ngIf=\"headerTemplate\"><ng-container *ngTemplateOutlet=\"headerTemplate\"></ng-container></ng-container>\n <ng-content select=\"[wuPanelHeader], wu-header\"></ng-content>\n <div class=\"wu-panel-icons p-panel-icons\">\n <ng-content select=\"[wuPanelIcons]\"></ng-content>\n <ng-container *ngIf=\"iconsTemplate\"><ng-container *ngTemplateOutlet=\"iconsTemplate\"></ng-container></ng-container>\n <button\n *ngIf=\"toggleable\"\n type=\"button\"\n class=\"wu-panel-toggler p-panel-header-icon p-panel-toggler p-link\"\n [attr.aria-expanded]=\"!isCollapsed\"\n [attr.aria-controls]=\"contentId\"\n [attr.aria-label]=\"togglerLabel\"\n (click)=\"toggle($event)\"\n >\n <svg *ngIf=\"isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M8 3v10M3 8h10\"></path></svg>\n <svg *ngIf=\"!isCollapsed\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M3 8h10\"></path></svg>\n </button>\n </div>\n </div>\n <div\n class=\"wu-panel-content-container p-toggleable-content\"\n [id]=\"contentId\"\n role=\"region\"\n [attr.aria-labelledby]=\"header ? titleId : null\"\n [attr.inert]=\"isCollapsed ? '' : null\"\n >\n <div class=\"wu-panel-content-inner\">\n <div class=\"wu-panel-content p-panel-content\"><ng-content></ng-content></div>\n <div class=\"wu-panel-footer p-panel-footer\"><ng-content select=\"[wuPanelFooter], wu-footer\"></ng-content><ng-container *ngIf=\"footerTemplate\"><ng-container *ngTemplateOutlet=\"footerTemplate\"></ng-container></ng-container></div>\n </div>\n </div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { WuFooter, WuHeader } from '@wirabyte/ui/card';\nimport { WuTemplate } from '@wirabyte/ui/config';\nimport { WuPanel } from './panel.component';\n\n/** For NgModule apps. Standalone apps can import `WuPanel` directly. `<wu-header>` / `<wu-footer>` slots come with it. */\n@NgModule({\n imports: [WuPanel, WuHeader, WuFooter, WuTemplate],\n exports: [WuPanel, WuHeader, WuFooter, WuTemplate],\n})\nexport class WuPanelModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAkBA;;;AAGG;MAUU,OAAO,CAAA;AAGlB,IAAA,IAAI,cAAc,GAAA;AAChB,QAAA,OAAO,IAAI,CAAC,SAAS,IAAI,aAAa,CAAC,IAAI,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC;KACtE;AAED,IAAA,IAAI,aAAa,GAAA;AACf,QAAA,OAAO,IAAI,CAAC,QAAQ,IAAI,aAAa,CAAC,IAAI,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;KACpE;AAED,IAAA,I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actory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ɵWuPopoverBase, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
138
|
-
ɵWuPopoverBase.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: ɵWuPopoverBase, inputs: { dismissable: "dismissable", showCloseIcon: "showCloseIcon", ariaCloseLabel: "ariaCloseLabel", style: "style", styleClass: "styleClass", focusOnShow: "focusOnShow", appendTo: "appendTo", baseZIndex: "baseZIndex", autoZIndex: "autoZIndex", showTransitionOptions: "showTransitionOptions", hideTransitionOptions: "hideTransitionOptions" }, outputs: { onShow: "onShow", onHide: "onHide" }, queries: [{ propertyName: "contentRef", first: true, predicate: ["content"],
|
|
138
|
+
ɵWuPopoverBase.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: ɵWuPopoverBase, inputs: { dismissable: "dismissable", showCloseIcon: "showCloseIcon", ariaCloseLabel: "ariaCloseLabel", style: "style", styleClass: "styleClass", focusOnShow: "focusOnShow", appendTo: "appendTo", baseZIndex: "baseZIndex", autoZIndex: "autoZIndex", showTransitionOptions: "showTransitionOptions", hideTransitionOptions: "hideTransitionOptions" }, outputs: { onShow: "onShow", onHide: "onHide" }, queries: [{ propertyName: "contentRef", first: true, predicate: ["content"], read: TemplateRef }, { propertyName: "slotTemplates", predicate: WuTemplate }], viewQueries: [{ propertyName: "panelRef", first: true, predicate: ["panel"], descendants: true }], ngImport: i0 });
|
|
139
139
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ɵWuPopoverBase, decorators: [{
|
|
140
140
|
type: Directive
|
|
141
141
|
}], ctorParameters: function () { return []; }, propDecorators: { dismissable: [{
|
|
@@ -169,7 +169,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
169
169
|
args: [WuTemplate]
|
|
170
170
|
}], contentRef: [{
|
|
171
171
|
type: ContentChild,
|
|
172
|
-
args: ['content', { read: TemplateRef }]
|
|
172
|
+
args: ['content', { read: TemplateRef, descendants: false }]
|
|
173
173
|
}], panelRef: [{
|
|
174
174
|
type: ViewChild,
|
|
175
175
|
args: ['panel']
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wirabyte-ui-popover.mjs","sources":["../../lib/popover/popover.base.ts","../../lib/popover/popover.component.ts","../../lib/popover/popover.component.html","../../lib/popover/popover.module.ts","../../lib/popover/wirabyte-ui-popover.ts"],"sourcesContent":["import { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectorRef,\n ContentChild,\n ContentChildren,\n Directive,\n ElementRef,\n EventEmitter,\n inject,\n Input,\n OnDestroy,\n Output,\n QueryList,\n TemplateRef,\n ViewChild,\n} from '@angular/core';\nimport { ɵassertSupportedAngular, ɵfindTemplate, ɵfocusable, ɵrefreshOnTranslation, ɵtoBool, ɵWU_SKIP_VERSION_CHECK, WuConfig, ɵWuPopup, WuTemplate } from '@wirabyte/ui/config';\nimport { WuLocale } from '@wirabyte/ui/core';\n\n/**\n * Shared logic of wu-popover (v1 and v2/v3 templates): a panel with an arrow under (or over) whatever opened it.\n * `#op` + `(click)=\"op.toggle($event)\"`, as existing templates do.\n */\n@Directive()\nexport abstract class ɵWuPopoverBase implements OnDestroy {\n /** A click outside closes it. Default true. */\n @Input() set dismissable(v: unknown) { this._dismissable = v === undefined || ɵtoBool(v); }\n /** An × in the corner. */\n @Input() set showCloseIcon(v: unknown) { this._showCloseIcon = ɵtoBool(v); }\n get showCloseIcon(): boolean { return this._showCloseIcon; }\n @Input() ariaCloseLabel?: string;\n @Input() style?: Record<string, string | number> | null;\n @Input() styleClass?: string;\n /** Move focus into the panel when it opens. Default true. */\n @Input() set focusOnShow(v: unknown) { this._focusOnShow = v === undefined || ɵtoBool(v); }\n /** Accepted for templates moving over; the panel is in the top layer. */\n @Input() appendTo: unknown;\n @Input() baseZIndex: unknown;\n @Input() autoZIndex: unknown;\n @Input() showTransitionOptions: unknown;\n @Input() hideTransitionOptions: unknown;\n\n @Output() readonly onShow = new EventEmitter<void>();\n @Output() readonly onHide = new EventEmitter<void>();\n\n @ContentChildren(WuTemplate) protected slotTemplates?: QueryList<WuTemplate>;\n @ContentChild('content', { read: TemplateRef }) protected contentRef?: TemplateRef<unknown>;\n /** A `content` template (`pTemplate=\"content\"` / `#content`), with `let-closeCallback=\"closeCallback\"`. */\n get contentTemplate(): TemplateRef<unknown> | null {\n return this.contentRef || ɵfindTemplate(this.slotTemplates, 'content');\n }\n readonly contentContext = { closeCallback: () => this.hide() };\n\n @ViewChild('panel') panelRef?: ElementRef<HTMLElement>;\n\n overlayVisible = false;\n flipped = false;\n private _dismissable = true;\n private _showCloseIcon = false;\n private _focusOnShow = true;\n private target: HTMLElement | null = null;\n private popup: ɵWuPopup | null = null;\n protected readonly cdr = inject(ChangeDetectorRef);\n private readonly config = inject(WuConfig);\n private readonly doc = inject(DOCUMENT);\n private readonly i18n = ɵrefreshOnTranslation();\n\n constructor() {\n ɵassertSupportedAngular(inject(ɵWU_SKIP_VERSION_CHECK, { optional: true }));\n }\n\n get t(): WuLocale {\n return this.config.translation;\n }\n\n /** Opens under `target` (default: the element that got the event), or closes when already open for it. */\n toggle(event?: Event | null, target?: HTMLElement | EventTarget | null): void {\n const t = this.resolveTarget(event, target);\n if (this.overlayVisible && (!t || t === this.target)) this.hide();\n else this.show(event, t);\n }\n\n show(event?: Event | null, target?: HTMLElement | EventTarget | null): void {\n const t = this.resolveTarget(event, target);\n if (!t) return;\n if (this.overlayVisible) {\n this.target = t;\n this.popup?.close();\n this.attach();\n return;\n }\n this.target = t;\n this.overlayVisible = true;\n this.cdr.detectChanges();\n this.attach();\n if (this._focusOnShow) {\n const panel = this.panelRef?.nativeElement;\n const first = panel && (panel.querySelector<HTMLElement>('[autofocus]') || ɵfocusable(panel)[0]);\n first?.focus({ preventScroll: true });\n }\n this.onShow.emit();\n }\n\n hide(): void {\n if (!this.overlayVisible) return;\n this.popup?.close();\n this.popup = null;\n this.overlayVisible = false;\n const panel = this.panelRef?.nativeElement;\n if (panel && panel.contains(this.doc.activeElement)) this.target?.focus({ preventScroll: true });\n this.cdr.markForCheck();\n this.onHide.emit();\n }\n\n /** Places the panel again, e.g. after its content changed size. */\n align(): void {\n this.popup?.position();\n }\n\n keydown(event: KeyboardEvent): void {\n if (event.key === 'Escape') {\n event.stopPropagation();\n this.hide();\n }\n }\n\n ngOnDestroy(): void {\n this.popup?.close();\n this.i18n.unsubscribe();\n }\n\n private attach(): void {\n const panel = this.panelRef?.nativeElement;\n if (!panel || !this.target) return;\n this.popup = new ɵWuPopup(this.target, panel, {\n sheet: false,\n gap: 10,\n sheetClass: 'wu-popover-sheet',\n modalClass: 'wu-popover-modal',\n onOutside: () => {\n if (this._dismissable) this.hide();\n },\n onLost: () => this.hide(),\n onEscape: (e) => {\n e.preventDefault();\n this.hide();\n },\n onPosition: (popup, anchor) => {\n const flipped = popup.placement === 'above';\n panel.classList.toggle('wu-popover-flipped', flipped);\n panel.classList.toggle('p-popover-flipped', flipped);\n panel.classList.toggle('p-overlaypanel-flipped', flipped);\n // The arrow points at the middle of the anchor, wherever the panel was pushed to fit.\n const at = anchor.left + anchor.width / 2 - panel.getBoundingClientRect().left;\n panel.style.setProperty('--_arrow', `${Math.round(Math.min(Math.max(at, 16), panel.offsetWidth - 16))}px`);\n },\n });\n this.popup.open();\n }\n\n private resolveTarget(event?: Event | null, target?: HTMLElement | EventTarget | null): HTMLElement | null {\n const t = (target || event?.currentTarget || event?.target || null) as HTMLElement | null;\n return t && t.nodeType === 1 ? t : null;\n }\n}\n","import { NgClass, NgIf, NgStyle, NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, ViewEncapsulation } from '@angular/core';\nimport { ɵWuPopoverBase } from './popover.base';\n\n/**\n * A panel under whatever opened it: `<wu-popover #op>…</wu-popover>` + `(click)=\"op.toggle($event)\"`.\n * In the top layer, so it shows above dialogs and is never clipped; flips above when there is no room below.\n */\n@Component({\n selector: 'wu-popover, wu-overlaypanel, wu-overlayPanel',\n standalone: true,\n exportAs: 'wuPopover',\n imports: [NgClass, NgIf, NgStyle, NgTemplateOutlet],\n templateUrl: './popover.component.html',\n styleUrls: ['./popover.css'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class WuPopover extends ɵWuPopoverBase {}\n","<div\n #panel\n *ngIf=\"overlayVisible\"\n popover=\"manual\"\n role=\"dialog\"\n class=\"wu-popover p-overlaypanel p-component\"\n [ngClass]=\"styleClass || ''\"\n [ngStyle]=\"style || null\"\n (keydown)=\"keydown($event)\"\n>\n <div class=\"wu-popover-content p-overlaypanel-content\">\n <ng-content></ng-content><ng-container *ngIf=\"contentTemplate\"><ng-container *ngTemplateOutlet=\"contentTemplate; context: contentContext\"></ng-container></ng-container>\n </div>\n <button\n *ngIf=\"showCloseIcon\"\n type=\"button\"\n class=\"wu-popover-close p-overlaypanel-close p-link\"\n [attr.aria-label]=\"ariaCloseLabel || t.close\"\n (click)=\"hide()\"\n >\n <svg viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M4 4l8 8M12 4l-8 8\"></path></svg>\n </button>\n</div>\n","import { NgModule } from '@angular/core';\nimport { WuTemplate } from '@wirabyte/ui/config';\nimport { WuPopover } from './popover.component';\n\n/** For NgModule apps. Standalone apps can import `WuPopover` directly. */\n@NgModule({\n imports: [WuPopover, WuTemplate],\n exports: [WuPopover, WuTemplate],\n})\nexport class WuPopoverModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAmBA;;;AAGG;MAEmB,cAAc,CAAA;;AAElC,IAAA,IAAa,WAAW,CAAC,CAAU,IAAI,IAAI,CAAC,YAAY,GAAG,CAAC,KAAK,SAAS,IAAI,OAAO,CAAC,CA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,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YAHhB,SAAS,CAAA,EAAA,CAAA,CAAA;4FAGR,eAAe,EAAA,UAAA,EAAA,CAAA;kBAJ3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,SAAS,EAAE,UAAU,CAAC;AAChC,oBAAA,OAAO,EAAE,CAAC,SAAS,EAAE,UAAU,CAAC;iBACjC,CAAA;;;ACRD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"wirabyte-ui-popover.mjs","sources":["../../lib/popover/popover.base.ts","../../lib/popover/popover.component.ts","../../lib/popover/popover.component.html","../../lib/popover/popover.module.ts","../../lib/popover/wirabyte-ui-popover.ts"],"sourcesContent":["import { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectorRef,\n ContentChild,\n ContentChildren,\n Directive,\n ElementRef,\n EventEmitter,\n inject,\n Input,\n OnDestroy,\n Output,\n QueryList,\n TemplateRef,\n ViewChild,\n} from '@angular/core';\nimport { ɵassertSupportedAngular, ɵfindTemplate, ɵfocusable, ɵrefreshOnTranslation, ɵtoBool, ɵWU_SKIP_VERSION_CHECK, WuConfig, ɵWuPopup, WuTemplate } from '@wirabyte/ui/config';\nimport { WuLocale } from '@wirabyte/ui/core';\n\n/**\n * Shared logic of wu-popover (v1 and v2/v3 templates): a panel with an arrow under (or over) whatever opened it.\n * `#op` + `(click)=\"op.toggle($event)\"`, as existing templates do.\n */\n@Directive()\nexport abstract class ɵWuPopoverBase implements OnDestroy {\n /** A click outside closes it. Default true. */\n @Input() set dismissable(v: unknown) { this._dismissable = v === undefined || ɵtoBool(v); }\n /** An × in the corner. */\n @Input() set showCloseIcon(v: unknown) { this._showCloseIcon = ɵtoBool(v); }\n get showCloseIcon(): boolean { return this._showCloseIcon; }\n @Input() ariaCloseLabel?: string;\n @Input() style?: Record<string, string | number> | null;\n @Input() styleClass?: string;\n /** Move focus into the panel when it opens. Default true. */\n @Input() set focusOnShow(v: unknown) { this._focusOnShow = v === undefined || ɵtoBool(v); }\n /** Accepted for templates moving over; the panel is in the top layer. */\n @Input() appendTo: unknown;\n @Input() baseZIndex: unknown;\n @Input() autoZIndex: unknown;\n @Input() showTransitionOptions: unknown;\n @Input() hideTransitionOptions: unknown;\n\n @Output() readonly onShow = new EventEmitter<void>();\n @Output() readonly onHide = new EventEmitter<void>();\n\n @ContentChildren(WuTemplate) protected slotTemplates?: QueryList<WuTemplate>;\n @ContentChild('content', { read: TemplateRef, descendants: false }) protected contentRef?: TemplateRef<unknown>;\n /** A `content` template (`pTemplate=\"content\"` / `#content`), with `let-closeCallback=\"closeCallback\"`. */\n get contentTemplate(): TemplateRef<unknown> | null {\n return this.contentRef || ɵfindTemplate(this.slotTemplates, 'content');\n }\n readonly contentContext = { closeCallback: () => this.hide() };\n\n @ViewChild('panel') panelRef?: ElementRef<HTMLElement>;\n\n overlayVisible = false;\n flipped = false;\n private _dismissable = true;\n private _showCloseIcon = false;\n private _focusOnShow = true;\n private target: HTMLElement | null = null;\n private popup: ɵWuPopup | null = null;\n protected readonly cdr = inject(ChangeDetectorRef);\n private readonly config = inject(WuConfig);\n private readonly doc = inject(DOCUMENT);\n private readonly i18n = ɵrefreshOnTranslation();\n\n constructor() {\n ɵassertSupportedAngular(inject(ɵWU_SKIP_VERSION_CHECK, { optional: true }));\n }\n\n get t(): WuLocale {\n return this.config.translation;\n }\n\n /** Opens under `target` (default: the element that got the event), or closes when already open for it. */\n toggle(event?: Event | null, target?: HTMLElement | EventTarget | null): void {\n const t = this.resolveTarget(event, target);\n if (this.overlayVisible && (!t || t === this.target)) this.hide();\n else this.show(event, t);\n }\n\n show(event?: Event | null, target?: HTMLElement | EventTarget | null): void {\n const t = this.resolveTarget(event, target);\n if (!t) return;\n if (this.overlayVisible) {\n this.target = t;\n this.popup?.close();\n this.attach();\n return;\n }\n this.target = t;\n this.overlayVisible = true;\n this.cdr.detectChanges();\n this.attach();\n if (this._focusOnShow) {\n const panel = this.panelRef?.nativeElement;\n const first = panel && (panel.querySelector<HTMLElement>('[autofocus]') || ɵfocusable(panel)[0]);\n first?.focus({ preventScroll: true });\n }\n this.onShow.emit();\n }\n\n hide(): void {\n if (!this.overlayVisible) return;\n this.popup?.close();\n this.popup = null;\n this.overlayVisible = false;\n const panel = this.panelRef?.nativeElement;\n if (panel && panel.contains(this.doc.activeElement)) this.target?.focus({ preventScroll: true });\n this.cdr.markForCheck();\n this.onHide.emit();\n }\n\n /** Places the panel again, e.g. after its content changed size. */\n align(): void {\n this.popup?.position();\n }\n\n keydown(event: KeyboardEvent): void {\n if (event.key === 'Escape') {\n event.stopPropagation();\n this.hide();\n }\n }\n\n ngOnDestroy(): void {\n this.popup?.close();\n this.i18n.unsubscribe();\n }\n\n private attach(): void {\n const panel = this.panelRef?.nativeElement;\n if (!panel || !this.target) return;\n this.popup = new ɵWuPopup(this.target, panel, {\n sheet: false,\n gap: 10,\n sheetClass: 'wu-popover-sheet',\n modalClass: 'wu-popover-modal',\n onOutside: () => {\n if (this._dismissable) this.hide();\n },\n onLost: () => this.hide(),\n onEscape: (e) => {\n e.preventDefault();\n this.hide();\n },\n onPosition: (popup, anchor) => {\n const flipped = popup.placement === 'above';\n panel.classList.toggle('wu-popover-flipped', flipped);\n panel.classList.toggle('p-popover-flipped', flipped);\n panel.classList.toggle('p-overlaypanel-flipped', flipped);\n // The arrow points at the middle of the anchor, wherever the panel was pushed to fit.\n const at = anchor.left + anchor.width / 2 - panel.getBoundingClientRect().left;\n panel.style.setProperty('--_arrow', `${Math.round(Math.min(Math.max(at, 16), panel.offsetWidth - 16))}px`);\n },\n });\n this.popup.open();\n }\n\n private resolveTarget(event?: Event | null, target?: HTMLElement | EventTarget | null): HTMLElement | null {\n const t = (target || event?.currentTarget || event?.target || null) as HTMLElement | null;\n return t && t.nodeType === 1 ? t : null;\n }\n}\n","import { NgClass, NgIf, NgStyle, NgTemplateOutlet } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, ViewEncapsulation } from '@angular/core';\nimport { ɵWuPopoverBase } from './popover.base';\n\n/**\n * A panel under whatever opened it: `<wu-popover #op>…</wu-popover>` + `(click)=\"op.toggle($event)\"`.\n * In the top layer, so it shows above dialogs and is never clipped; flips above when there is no room below.\n */\n@Component({\n selector: 'wu-popover, wu-overlaypanel, wu-overlayPanel',\n standalone: true,\n exportAs: 'wuPopover',\n imports: [NgClass, NgIf, NgStyle, NgTemplateOutlet],\n templateUrl: './popover.component.html',\n styleUrls: ['./popover.css'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class WuPopover extends ɵWuPopoverBase {}\n","<div\n #panel\n *ngIf=\"overlayVisible\"\n popover=\"manual\"\n role=\"dialog\"\n class=\"wu-popover p-overlaypanel p-component\"\n [ngClass]=\"styleClass || ''\"\n [ngStyle]=\"style || null\"\n (keydown)=\"keydown($event)\"\n>\n <div class=\"wu-popover-content p-overlaypanel-content\">\n <ng-content></ng-content><ng-container *ngIf=\"contentTemplate\"><ng-container *ngTemplateOutlet=\"contentTemplate; context: contentContext\"></ng-container></ng-container>\n </div>\n <button\n *ngIf=\"showCloseIcon\"\n type=\"button\"\n class=\"wu-popover-close p-overlaypanel-close p-link\"\n [attr.aria-label]=\"ariaCloseLabel || t.close\"\n (click)=\"hide()\"\n >\n <svg viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" stroke-linecap=\"round\" aria-hidden=\"true\"><path d=\"M4 4l8 8M12 4l-8 8\"></path></svg>\n </button>\n</div>\n","import { NgModule } from '@angular/core';\nimport { WuTemplate } from '@wirabyte/ui/config';\nimport { WuPopover } from './popover.component';\n\n/** For NgModule apps. Standalone apps can import `WuPopover` directly. */\n@NgModule({\n imports: [WuPopover, WuTemplate],\n exports: [WuPopover, WuTemplate],\n})\nexport class WuPopoverModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;A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AAA,CAAA,CAAA;AAEpB,eAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YAHhB,SAAS,CAAA,EAAA,CAAA,CAAA;4FAGR,eAAe,EAAA,UAAA,EAAA,CAAA;kBAJ3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,SAAS,EAAE,UAAU,CAAC;AAChC,oBAAA,OAAO,EAAE,CAAC,SAAS,EAAE,UAAU,CAAC;iBACjC,CAAA;;;ACRD;;AAEG;;;;"}
|
|
@@ -53,10 +53,10 @@ class WuResult {
|
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
WuResult.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: WuResult, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
56
|
-
WuResult.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: WuResult, isStandalone: true, selector: "wu-result", inputs: { status: "status", title: "title", subtitle: "subtitle", icon: "icon", showIcon: "showIcon", styleClass: "styleClass", style: "style" }, host: { properties: { "attr.title": "null" }, classAttribute: "wu-result-host" }, ngImport: i0, template: "<div class=\"wu-result\" [class]=\"styleClass || ''\" [style]=\"rootStyle\" [attr.data-status]=\"status\">\n <ng-container *ngIf=\"shown\">\n <span *ngIf=\"!isCode; else code\" class=\"wu-result-mark\" aria-hidden=\"true\">\n <i *ngIf=\"icon; else mark\" [ngClass]=\"icon\"></i>\n <ng-template #mark>\n <svg viewBox=\"0 0 48 48\" focusable=\"false\" [ngSwitch]=\"status\">\n <path *ngSwitchCase=\"'success'\" d=\"m14 24.5 7 7 13-14\"></path>\n <path *ngSwitchCase=\"'error'\" d=\"m16 16 16 16m0-16L16 32\"></path>\n <g *ngSwitchCase=\"'warning'\">\n <path d=\"M24 13v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"34.5\" r=\"2.6\"></circle>\n </g>\n <g *ngSwitchDefault>\n <path d=\"M24 21v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"13.5\" r=\"2.6\"></circle>\n </g>\n </svg>\n </ng-template>\n </span>\n <ng-template #code>\n <svg class=\"wu-result-art\" viewBox=\"0 0 240 110\" aria-hidden=\"true\" focusable=\"false\" [ngSwitch]=\"status\">\n <text class=\"wu-rs-digit\" x=\"52\" y=\"92\" text-anchor=\"middle\">{{ status === '500' ? '5' : '4' }}</text>\n <circle class=\"wu-rs-soft\" cx=\"120\" cy=\"60\" r=\"38\"></circle>\n <g *ngSwitchCase=\"'403'\">\n <path class=\"wu-rs-shackle\" d=\"M108 56v-8a12 12 0 0 1 24 0v8\"></path>\n <rect class=\"wu-rs-accent-fill\" x=\"102\" y=\"55\" width=\"36\" height=\"28\" rx=\"6\"></rect>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"66\" r=\"3.5\"></circle>\n <path class=\"wu-rs-paper-line\" d=\"M120 68v7\"></path>\n </g>\n <g *ngSwitchCase=\"'500'\">\n <path class=\"wu-rs-accent-fill\" d=\"M126 30 106 63h13l-6 27 22-36h-13z\"></path>\n </g>\n <g *ngSwitchDefault>\n <circle class=\"wu-rs-ring\" cx=\"120\" cy=\"60\" r=\"24\"></circle>\n <path class=\"wu-rs-accent-fill\" d=\"m132 48-8 16-16 8 8-16z\"></path>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"60\" r=\"2.5\"></circle>\n </g>\n <text class=\"wu-rs-digit\" x=\"188\" y=\"92\" text-anchor=\"middle\">{{ status === '403' ? '3' : status === '500' ? '0' : '4' }}</text>\n </svg>\n </ng-template>\n </ng-container>\n <p *ngIf=\"titleText\" class=\"wu-result-title\">{{ titleText }}</p>\n <p *ngIf=\"subtitleText\" class=\"wu-result-subtitle\">{{ subtitleText }}</p>\n <div class=\"wu-result-extra\"><ng-content select=\"[wuResultExtra]\"></ng-content></div>\n <div class=\"wu-result-content\"><ng-content></ng-content></div>\n</div>\n", styles: ["@layer wiraui.components{wu-result{display:block}.wu-result{display:flex;flex-direction:column;align-items:center;gap:var(--wu-result-gap);padding:var(--wu-result-padding);text-align:center;font-family:var(--wu-font-family)}.wu-result-mark{display:inline-flex;align-items:center;justify-content:center;width:var(--wu-result-icon-box);height:var(--wu-result-icon-box);margin-bottom:.75rem;border-radius:50%;color:var(--wu-info-color);background:var(--wu-info-bg);font-size:calc(var(--wu-result-icon-box) * .45);line-height:1}.wu-result[data-status=success] .wu-result-mark{color:var(--wu-success-color);background:var(--wu-success-bg)}.wu-result[data-status=error] .wu-result-mark{color:var(--wu-danger-color);background:var(--wu-danger-bg)}.wu-result[data-status=warning] .wu-result-mark{color:var(--wu-warn-color);background:var(--wu-warn-bg)}.wu-result-mark svg{width:60%;height:60%;fill:none;stroke:currentColor;stroke-width:4.5;stroke-linecap:round;stroke-linejoin:round}.wu-result-mark .wu-result-dot{fill:currentColor;stroke:none}.wu-result-art{display:block;width:var(--wu-result-art-width);max-width:100%;height:auto;margin-bottom:.5rem;overflow:visible}.wu-rs-digit{fill:var(--wu-result-code-color);font-family:var(--wu-font-family);font-size:88px;font-weight:700}.wu-rs-soft{fill:var(--wu-result-art-soft)}.wu-rs-ring{fill:var(--wu-result-art-paper);stroke:var(--wu-result-art-accent);stroke-width:4}.wu-rs-shackle{fill:none;stroke:var(--wu-result-art-accent);stroke-width:5;stroke-linecap:round}.wu-rs-accent-fill{fill:var(--wu-result-art-accent);stroke:var(--wu-result-art-accent);stroke-width:2;stroke-linejoin:round}.wu-rs-paper-fill{fill:var(--wu-result-art-paper)}.wu-rs-paper-line{stroke:var(--wu-result-art-paper);stroke-width:3;stroke-linecap:round}.wu-result-title{margin:0;color:var(--wu-result-title-color);font-size:var(--wu-result-title-size);font-weight:var(--wu-result-title-weight);line-height:var(--wu-line-height)}.wu-result-subtitle{margin:0;max-width:36rem;color:var(--wu-result-description-color);line-height:var(--wu-line-height)}.wu-result-extra{display:flex;flex-wrap:wrap;justify-content:center;gap:var(--wu-result-actions-gap);margin-top:1rem}.wu-result-content{box-sizing:border-box;width:100%;max-width:40rem;margin-top:1rem;padding:var(--wu-result-content-padding);border-radius:var(--wu-result-content-radius);background:var(--wu-result-content-bg);text-align:start}.wu-result-extra:empty,.wu-result-content:empty{display:none}}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: NgSwitchDefault, selector: "[ngSwitchDefault]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
56
|
+
WuResult.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: WuResult, isStandalone: true, selector: "wu-result", inputs: { status: "status", title: "title", subtitle: "subtitle", icon: "icon", showIcon: "showIcon", styleClass: "styleClass", style: "style" }, host: { properties: { "attr.title": "null" }, classAttribute: "wu-result-host" }, ngImport: i0, template: "<div class=\"wu-result\" [class]=\"styleClass || ''\" [style]=\"rootStyle\" [attr.data-status]=\"status\">\n <ng-container *ngIf=\"shown\">\n <span *ngIf=\"!isCode; else code\" class=\"wu-result-mark\" aria-hidden=\"true\">\n <i *ngIf=\"icon; else mark\" [ngClass]=\"icon\"></i>\n <ng-template #mark>\n <svg viewBox=\"0 0 48 48\" focusable=\"false\" [ngSwitch]=\"status\">\n <path *ngSwitchCase=\"'success'\" d=\"m14 24.5 7 7 13-14\"></path>\n <path *ngSwitchCase=\"'error'\" d=\"m16 16 16 16m0-16L16 32\"></path>\n <g *ngSwitchCase=\"'warning'\">\n <path d=\"M24 13v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"34.5\" r=\"2.6\"></circle>\n </g>\n <g *ngSwitchDefault>\n <path d=\"M24 21v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"13.5\" r=\"2.6\"></circle>\n </g>\n </svg>\n </ng-template>\n </span>\n <ng-template #code>\n <svg class=\"wu-result-art\" viewBox=\"0 0 240 110\" aria-hidden=\"true\" focusable=\"false\" [ngSwitch]=\"status\">\n <text class=\"wu-rs-digit\" x=\"52\" y=\"92\" text-anchor=\"middle\">{{ status === '500' ? '5' : '4' }}</text>\n <circle class=\"wu-rs-soft\" cx=\"120\" cy=\"60\" r=\"38\"></circle>\n <g *ngSwitchCase=\"'403'\">\n <path class=\"wu-rs-shackle\" d=\"M108 56v-8a12 12 0 0 1 24 0v8\"></path>\n <rect class=\"wu-rs-accent-fill\" x=\"102\" y=\"55\" width=\"36\" height=\"28\" rx=\"6\"></rect>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"66\" r=\"3.5\"></circle>\n <path class=\"wu-rs-paper-line\" d=\"M120 68v7\"></path>\n </g>\n <g *ngSwitchCase=\"'500'\">\n <path class=\"wu-rs-accent-fill\" d=\"M126 30 106 63h13l-6 27 22-36h-13z\"></path>\n </g>\n <g *ngSwitchDefault>\n <circle class=\"wu-rs-ring\" cx=\"120\" cy=\"60\" r=\"24\"></circle>\n <path class=\"wu-rs-accent-fill\" d=\"m132 48-8 16-16 8 8-16z\"></path>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"60\" r=\"2.5\"></circle>\n </g>\n <text class=\"wu-rs-digit\" x=\"188\" y=\"92\" text-anchor=\"middle\">{{ status === '403' ? '3' : status === '500' ? '0' : '4' }}</text>\n </svg>\n </ng-template>\n </ng-container>\n <p *ngIf=\"titleText\" class=\"wu-result-title\">{{ titleText }}</p>\n <p *ngIf=\"subtitleText\" class=\"wu-result-subtitle\">{{ subtitleText }}</p>\n <div class=\"wu-result-extra\"><ng-content select=\"[wuResultExtra]\"></ng-content></div>\n <div class=\"wu-result-content\"><ng-content></ng-content></div>\n</div>\n", styles: ["@layer wiraui.components{wu-result{display:block}.wu-result{display:flex;flex-direction:column;align-items:center;gap:var(--wu-result-gap);padding:var(--wu-result-padding);text-align:center;font-family:var(--wu-font-family)}.wu-result-mark{display:inline-flex;align-items:center;justify-content:center;width:var(--wu-result-icon-box);height:var(--wu-result-icon-box);margin-bottom:.75rem;border-radius:50%;color:var(--wu-info-color);background:var(--wu-info-bg);font-size:calc(var(--wu-result-icon-box) * .45);line-height:1}.wu-result[data-status=success] .wu-result-mark{color:var(--wu-success-color);background:var(--wu-success-bg)}.wu-result[data-status=error] .wu-result-mark{color:var(--wu-danger-color);background:var(--wu-danger-bg)}.wu-result[data-status=warning] .wu-result-mark{color:var(--wu-warn-color);background:var(--wu-warn-bg)}.wu-result-mark svg{width:60%;height:60%;fill:none;stroke:currentColor;stroke-width:4.5;stroke-linecap:round;stroke-linejoin:round}.wu-result-mark .wu-result-dot{fill:currentColor;stroke:none}.wu-result-art{display:block;width:var(--wu-result-art-width);max-width:100%;height:auto;margin-bottom:.5rem;overflow:visible}.wu-rs-digit{fill:var(--wu-result-code-color);font-family:var(--wu-font-family);font-size:88px;font-weight:700}.wu-rs-soft{fill:var(--wu-result-art-soft)}.wu-rs-ring{fill:var(--wu-result-art-paper);stroke:var(--wu-result-art-accent);stroke-width:4}.wu-rs-shackle{fill:none;stroke:var(--wu-result-art-accent);stroke-width:5;stroke-linecap:round}.wu-rs-accent-fill{fill:var(--wu-result-art-accent);stroke:var(--wu-result-art-accent);stroke-width:2;stroke-linejoin:round}.wu-rs-paper-fill{fill:var(--wu-result-art-paper)}.wu-rs-paper-line{stroke:var(--wu-result-art-paper);stroke-width:3;stroke-linecap:round}.wu-result-title{font-family:var(--wu-heading-font-family);margin:0;color:var(--wu-result-title-color);font-size:var(--wu-result-title-size);font-weight:var(--wu-result-title-weight);line-height:var(--wu-line-height)}.wu-result-subtitle{margin:0;max-width:36rem;color:var(--wu-result-description-color);line-height:var(--wu-line-height)}.wu-result-extra{display:flex;flex-wrap:wrap;justify-content:center;gap:var(--wu-result-actions-gap);margin-top:1rem}.wu-result-content{box-sizing:border-box;width:100%;max-width:40rem;margin-top:1rem;padding:var(--wu-result-content-padding);border-radius:var(--wu-result-content-radius);background:var(--wu-result-content-bg);text-align:start}.wu-result-extra:empty,.wu-result-content:empty{display:none}}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: NgSwitchDefault, selector: "[ngSwitchDefault]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
57
57
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: WuResult, decorators: [{
|
|
58
58
|
type: Component,
|
|
59
|
-
args: [{ selector: 'wu-result', standalone: true, imports: [NgClass, NgIf, NgSwitch, NgSwitchCase, NgSwitchDefault], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'wu-result-host', '[attr.title]': 'null' }, template: "<div class=\"wu-result\" [class]=\"styleClass || ''\" [style]=\"rootStyle\" [attr.data-status]=\"status\">\n <ng-container *ngIf=\"shown\">\n <span *ngIf=\"!isCode; else code\" class=\"wu-result-mark\" aria-hidden=\"true\">\n <i *ngIf=\"icon; else mark\" [ngClass]=\"icon\"></i>\n <ng-template #mark>\n <svg viewBox=\"0 0 48 48\" focusable=\"false\" [ngSwitch]=\"status\">\n <path *ngSwitchCase=\"'success'\" d=\"m14 24.5 7 7 13-14\"></path>\n <path *ngSwitchCase=\"'error'\" d=\"m16 16 16 16m0-16L16 32\"></path>\n <g *ngSwitchCase=\"'warning'\">\n <path d=\"M24 13v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"34.5\" r=\"2.6\"></circle>\n </g>\n <g *ngSwitchDefault>\n <path d=\"M24 21v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"13.5\" r=\"2.6\"></circle>\n </g>\n </svg>\n </ng-template>\n </span>\n <ng-template #code>\n <svg class=\"wu-result-art\" viewBox=\"0 0 240 110\" aria-hidden=\"true\" focusable=\"false\" [ngSwitch]=\"status\">\n <text class=\"wu-rs-digit\" x=\"52\" y=\"92\" text-anchor=\"middle\">{{ status === '500' ? '5' : '4' }}</text>\n <circle class=\"wu-rs-soft\" cx=\"120\" cy=\"60\" r=\"38\"></circle>\n <g *ngSwitchCase=\"'403'\">\n <path class=\"wu-rs-shackle\" d=\"M108 56v-8a12 12 0 0 1 24 0v8\"></path>\n <rect class=\"wu-rs-accent-fill\" x=\"102\" y=\"55\" width=\"36\" height=\"28\" rx=\"6\"></rect>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"66\" r=\"3.5\"></circle>\n <path class=\"wu-rs-paper-line\" d=\"M120 68v7\"></path>\n </g>\n <g *ngSwitchCase=\"'500'\">\n <path class=\"wu-rs-accent-fill\" d=\"M126 30 106 63h13l-6 27 22-36h-13z\"></path>\n </g>\n <g *ngSwitchDefault>\n <circle class=\"wu-rs-ring\" cx=\"120\" cy=\"60\" r=\"24\"></circle>\n <path class=\"wu-rs-accent-fill\" d=\"m132 48-8 16-16 8 8-16z\"></path>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"60\" r=\"2.5\"></circle>\n </g>\n <text class=\"wu-rs-digit\" x=\"188\" y=\"92\" text-anchor=\"middle\">{{ status === '403' ? '3' : status === '500' ? '0' : '4' }}</text>\n </svg>\n </ng-template>\n </ng-container>\n <p *ngIf=\"titleText\" class=\"wu-result-title\">{{ titleText }}</p>\n <p *ngIf=\"subtitleText\" class=\"wu-result-subtitle\">{{ subtitleText }}</p>\n <div class=\"wu-result-extra\"><ng-content select=\"[wuResultExtra]\"></ng-content></div>\n <div class=\"wu-result-content\"><ng-content></ng-content></div>\n</div>\n", styles: ["@layer wiraui.components{wu-result{display:block}.wu-result{display:flex;flex-direction:column;align-items:center;gap:var(--wu-result-gap);padding:var(--wu-result-padding);text-align:center;font-family:var(--wu-font-family)}.wu-result-mark{display:inline-flex;align-items:center;justify-content:center;width:var(--wu-result-icon-box);height:var(--wu-result-icon-box);margin-bottom:.75rem;border-radius:50%;color:var(--wu-info-color);background:var(--wu-info-bg);font-size:calc(var(--wu-result-icon-box) * .45);line-height:1}.wu-result[data-status=success] .wu-result-mark{color:var(--wu-success-color);background:var(--wu-success-bg)}.wu-result[data-status=error] .wu-result-mark{color:var(--wu-danger-color);background:var(--wu-danger-bg)}.wu-result[data-status=warning] .wu-result-mark{color:var(--wu-warn-color);background:var(--wu-warn-bg)}.wu-result-mark svg{width:60%;height:60%;fill:none;stroke:currentColor;stroke-width:4.5;stroke-linecap:round;stroke-linejoin:round}.wu-result-mark .wu-result-dot{fill:currentColor;stroke:none}.wu-result-art{display:block;width:var(--wu-result-art-width);max-width:100%;height:auto;margin-bottom:.5rem;overflow:visible}.wu-rs-digit{fill:var(--wu-result-code-color);font-family:var(--wu-font-family);font-size:88px;font-weight:700}.wu-rs-soft{fill:var(--wu-result-art-soft)}.wu-rs-ring{fill:var(--wu-result-art-paper);stroke:var(--wu-result-art-accent);stroke-width:4}.wu-rs-shackle{fill:none;stroke:var(--wu-result-art-accent);stroke-width:5;stroke-linecap:round}.wu-rs-accent-fill{fill:var(--wu-result-art-accent);stroke:var(--wu-result-art-accent);stroke-width:2;stroke-linejoin:round}.wu-rs-paper-fill{fill:var(--wu-result-art-paper)}.wu-rs-paper-line{stroke:var(--wu-result-art-paper);stroke-width:3;stroke-linecap:round}.wu-result-title{margin:0;color:var(--wu-result-title-color);font-size:var(--wu-result-title-size);font-weight:var(--wu-result-title-weight);line-height:var(--wu-line-height)}.wu-result-subtitle{margin:0;max-width:36rem;color:var(--wu-result-description-color);line-height:var(--wu-line-height)}.wu-result-extra{display:flex;flex-wrap:wrap;justify-content:center;gap:var(--wu-result-actions-gap);margin-top:1rem}.wu-result-content{box-sizing:border-box;width:100%;max-width:40rem;margin-top:1rem;padding:var(--wu-result-content-padding);border-radius:var(--wu-result-content-radius);background:var(--wu-result-content-bg);text-align:start}.wu-result-extra:empty,.wu-result-content:empty{display:none}}\n"] }]
|
|
59
|
+
args: [{ selector: 'wu-result', standalone: true, imports: [NgClass, NgIf, NgSwitch, NgSwitchCase, NgSwitchDefault], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'wu-result-host', '[attr.title]': 'null' }, template: "<div class=\"wu-result\" [class]=\"styleClass || ''\" [style]=\"rootStyle\" [attr.data-status]=\"status\">\n <ng-container *ngIf=\"shown\">\n <span *ngIf=\"!isCode; else code\" class=\"wu-result-mark\" aria-hidden=\"true\">\n <i *ngIf=\"icon; else mark\" [ngClass]=\"icon\"></i>\n <ng-template #mark>\n <svg viewBox=\"0 0 48 48\" focusable=\"false\" [ngSwitch]=\"status\">\n <path *ngSwitchCase=\"'success'\" d=\"m14 24.5 7 7 13-14\"></path>\n <path *ngSwitchCase=\"'error'\" d=\"m16 16 16 16m0-16L16 32\"></path>\n <g *ngSwitchCase=\"'warning'\">\n <path d=\"M24 13v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"34.5\" r=\"2.6\"></circle>\n </g>\n <g *ngSwitchDefault>\n <path d=\"M24 21v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"13.5\" r=\"2.6\"></circle>\n </g>\n </svg>\n </ng-template>\n </span>\n <ng-template #code>\n <svg class=\"wu-result-art\" viewBox=\"0 0 240 110\" aria-hidden=\"true\" focusable=\"false\" [ngSwitch]=\"status\">\n <text class=\"wu-rs-digit\" x=\"52\" y=\"92\" text-anchor=\"middle\">{{ status === '500' ? '5' : '4' }}</text>\n <circle class=\"wu-rs-soft\" cx=\"120\" cy=\"60\" r=\"38\"></circle>\n <g *ngSwitchCase=\"'403'\">\n <path class=\"wu-rs-shackle\" d=\"M108 56v-8a12 12 0 0 1 24 0v8\"></path>\n <rect class=\"wu-rs-accent-fill\" x=\"102\" y=\"55\" width=\"36\" height=\"28\" rx=\"6\"></rect>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"66\" r=\"3.5\"></circle>\n <path class=\"wu-rs-paper-line\" d=\"M120 68v7\"></path>\n </g>\n <g *ngSwitchCase=\"'500'\">\n <path class=\"wu-rs-accent-fill\" d=\"M126 30 106 63h13l-6 27 22-36h-13z\"></path>\n </g>\n <g *ngSwitchDefault>\n <circle class=\"wu-rs-ring\" cx=\"120\" cy=\"60\" r=\"24\"></circle>\n <path class=\"wu-rs-accent-fill\" d=\"m132 48-8 16-16 8 8-16z\"></path>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"60\" r=\"2.5\"></circle>\n </g>\n <text class=\"wu-rs-digit\" x=\"188\" y=\"92\" text-anchor=\"middle\">{{ status === '403' ? '3' : status === '500' ? '0' : '4' }}</text>\n </svg>\n </ng-template>\n </ng-container>\n <p *ngIf=\"titleText\" class=\"wu-result-title\">{{ titleText }}</p>\n <p *ngIf=\"subtitleText\" class=\"wu-result-subtitle\">{{ subtitleText }}</p>\n <div class=\"wu-result-extra\"><ng-content select=\"[wuResultExtra]\"></ng-content></div>\n <div class=\"wu-result-content\"><ng-content></ng-content></div>\n</div>\n", styles: ["@layer wiraui.components{wu-result{display:block}.wu-result{display:flex;flex-direction:column;align-items:center;gap:var(--wu-result-gap);padding:var(--wu-result-padding);text-align:center;font-family:var(--wu-font-family)}.wu-result-mark{display:inline-flex;align-items:center;justify-content:center;width:var(--wu-result-icon-box);height:var(--wu-result-icon-box);margin-bottom:.75rem;border-radius:50%;color:var(--wu-info-color);background:var(--wu-info-bg);font-size:calc(var(--wu-result-icon-box) * .45);line-height:1}.wu-result[data-status=success] .wu-result-mark{color:var(--wu-success-color);background:var(--wu-success-bg)}.wu-result[data-status=error] .wu-result-mark{color:var(--wu-danger-color);background:var(--wu-danger-bg)}.wu-result[data-status=warning] .wu-result-mark{color:var(--wu-warn-color);background:var(--wu-warn-bg)}.wu-result-mark svg{width:60%;height:60%;fill:none;stroke:currentColor;stroke-width:4.5;stroke-linecap:round;stroke-linejoin:round}.wu-result-mark .wu-result-dot{fill:currentColor;stroke:none}.wu-result-art{display:block;width:var(--wu-result-art-width);max-width:100%;height:auto;margin-bottom:.5rem;overflow:visible}.wu-rs-digit{fill:var(--wu-result-code-color);font-family:var(--wu-font-family);font-size:88px;font-weight:700}.wu-rs-soft{fill:var(--wu-result-art-soft)}.wu-rs-ring{fill:var(--wu-result-art-paper);stroke:var(--wu-result-art-accent);stroke-width:4}.wu-rs-shackle{fill:none;stroke:var(--wu-result-art-accent);stroke-width:5;stroke-linecap:round}.wu-rs-accent-fill{fill:var(--wu-result-art-accent);stroke:var(--wu-result-art-accent);stroke-width:2;stroke-linejoin:round}.wu-rs-paper-fill{fill:var(--wu-result-art-paper)}.wu-rs-paper-line{stroke:var(--wu-result-art-paper);stroke-width:3;stroke-linecap:round}.wu-result-title{font-family:var(--wu-heading-font-family);margin:0;color:var(--wu-result-title-color);font-size:var(--wu-result-title-size);font-weight:var(--wu-result-title-weight);line-height:var(--wu-line-height)}.wu-result-subtitle{margin:0;max-width:36rem;color:var(--wu-result-description-color);line-height:var(--wu-line-height)}.wu-result-extra{display:flex;flex-wrap:wrap;justify-content:center;gap:var(--wu-result-actions-gap);margin-top:1rem}.wu-result-content{box-sizing:border-box;width:100%;max-width:40rem;margin-top:1rem;padding:var(--wu-result-content-padding);border-radius:var(--wu-result-content-radius);background:var(--wu-result-content-bg);text-align:start}.wu-result-extra:empty,.wu-result-content:empty{display:none}}\n"] }]
|
|
60
60
|
}], ctorParameters: function () { return []; }, propDecorators: { status: [{
|
|
61
61
|
type: Input
|
|
62
62
|
}], title: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wirabyte-ui-result.mjs","sources":["../../lib/result/result.component.ts","../../lib/result/result.component.html","../../lib/result/result.module.ts","../../lib/result/wirabyte-ui-result.ts"],"sourcesContent":["import { NgClass, NgIf, NgSwitch, NgSwitchCase, NgSwitchDefault } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, inject, Input, OnDestroy, ViewEncapsulation } from '@angular/core';\nimport { ɵassertSupportedAngular, ɵrefreshOnTranslation, ɵWU_SKIP_VERSION_CHECK, WuConfig } from '@wirabyte/ui/config';\nimport { WuResultStatus } from '@wirabyte/ui/core';\n\nexport type { WuResultStatus };\n\nconst STATUSES: readonly WuResultStatus[] = ['success', 'error', 'info', 'warning', '403', '404', '500'];\n\n/**\n * The page or panel after a task ends, or instead of a page that cannot be shown:\n * `<wu-result status=\"success\" title=\"ส่งใบสมัครแล้ว\"><wu-button wuResultExtra label=\"กลับหน้าแรก\"></wu-button></wu-result>`.\n * `success`, `error`, `info` and `warning` draw a large status mark in the theme's colours; `403`, `404` and `500` draw\n * the code with a picture in place of its 0. Title and line come from the locale unless given. Elements marked\n * `wuResultExtra` sit in a row of actions; anything else inside the tag goes in a details box under them.\n */\n@Component({\n selector: 'wu-result',\n standalone: true,\n imports: [NgClass, NgIf, NgSwitch, NgSwitchCase, NgSwitchDefault],\n templateUrl: './result.component.html',\n styleUrls: ['./result.css'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n // `title` is an input here: keep it off the host so the whole block gets no browser tooltip.\n host: { class: 'wu-result-host', '[attr.title]': 'null' },\n})\nexport class WuResult implements OnDestroy {\n /** Default `'info'`. Numbers work too: `[status]=\"404\"`. */\n @Input() set status(v: WuResultStatus | number | string | null | undefined) {\n const s = String(v ?? '') as WuResultStatus;\n this._status = STATUSES.includes(s) ? s : 'info';\n }\n get status(): WuResultStatus {\n return this._status;\n }\n /** Default: the locale's title for `status`; `''` shows none. */\n @Input() title?: string | null;\n /** The line under the title. Default: the locale's line for `status`; `''` shows none. */\n @Input() subtitle?: string | null;\n /** An icon class (`'wi wi-rocket'`) in the status circle instead of the drawn mark. */\n @Input() icon?: string | null;\n /** `false` leaves out the mark or picture. */\n @Input() showIcon: boolean | string | null | undefined = true;\n @Input() styleClass?: string | null;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Input() style?: Record<string, any> | string | null;\n\n private _status: WuResultStatus = 'info';\n private readonly config = inject(WuConfig);\n private readonly i18n = ɵrefreshOnTranslation();\n\n constructor() {\n ɵassertSupportedAngular(inject(ɵWU_SKIP_VERSION_CHECK, { optional: true }));\n }\n\n ngOnDestroy(): void {\n this.i18n.unsubscribe();\n }\n\n // ---------- what the template reads ----------\n\n get titleText(): string {\n return this.title ?? this.config.translation.result?.[this._status]?.title ?? '';\n }\n get subtitleText(): string {\n return this.subtitle ?? this.config.translation.result?.[this._status]?.description ?? '';\n }\n /** 403, 404 and 500 draw their code; the others a status mark. */\n get isCode(): boolean {\n return this._status === '403' || this._status === '404' || this._status === '500';\n }\n get shown(): boolean {\n return this.showIcon !== false && this.showIcon !== 'false';\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get rootStyle(): Record<string, any> | null {\n return this.style && typeof this.style === 'object' ? this.style : null;\n }\n}\n","<div class=\"wu-result\" [class]=\"styleClass || ''\" [style]=\"rootStyle\" [attr.data-status]=\"status\">\n <ng-container *ngIf=\"shown\">\n <span *ngIf=\"!isCode; else code\" class=\"wu-result-mark\" aria-hidden=\"true\">\n <i *ngIf=\"icon; else mark\" [ngClass]=\"icon\"></i>\n <ng-template #mark>\n <svg viewBox=\"0 0 48 48\" focusable=\"false\" [ngSwitch]=\"status\">\n <path *ngSwitchCase=\"'success'\" d=\"m14 24.5 7 7 13-14\"></path>\n <path *ngSwitchCase=\"'error'\" d=\"m16 16 16 16m0-16L16 32\"></path>\n <g *ngSwitchCase=\"'warning'\">\n <path d=\"M24 13v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"34.5\" r=\"2.6\"></circle>\n </g>\n <g *ngSwitchDefault>\n <path d=\"M24 21v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"13.5\" r=\"2.6\"></circle>\n </g>\n </svg>\n </ng-template>\n </span>\n <ng-template #code>\n <svg class=\"wu-result-art\" viewBox=\"0 0 240 110\" aria-hidden=\"true\" focusable=\"false\" [ngSwitch]=\"status\">\n <text class=\"wu-rs-digit\" x=\"52\" y=\"92\" text-anchor=\"middle\">{{ status === '500' ? '5' : '4' }}</text>\n <circle class=\"wu-rs-soft\" cx=\"120\" cy=\"60\" r=\"38\"></circle>\n <g *ngSwitchCase=\"'403'\">\n <path class=\"wu-rs-shackle\" d=\"M108 56v-8a12 12 0 0 1 24 0v8\"></path>\n <rect class=\"wu-rs-accent-fill\" x=\"102\" y=\"55\" width=\"36\" height=\"28\" rx=\"6\"></rect>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"66\" r=\"3.5\"></circle>\n <path class=\"wu-rs-paper-line\" d=\"M120 68v7\"></path>\n </g>\n <g *ngSwitchCase=\"'500'\">\n <path class=\"wu-rs-accent-fill\" d=\"M126 30 106 63h13l-6 27 22-36h-13z\"></path>\n </g>\n <g *ngSwitchDefault>\n <circle class=\"wu-rs-ring\" cx=\"120\" cy=\"60\" r=\"24\"></circle>\n <path class=\"wu-rs-accent-fill\" d=\"m132 48-8 16-16 8 8-16z\"></path>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"60\" r=\"2.5\"></circle>\n </g>\n <text class=\"wu-rs-digit\" x=\"188\" y=\"92\" text-anchor=\"middle\">{{ status === '403' ? '3' : status === '500' ? '0' : '4' }}</text>\n </svg>\n </ng-template>\n </ng-container>\n <p *ngIf=\"titleText\" class=\"wu-result-title\">{{ titleText }}</p>\n <p *ngIf=\"subtitleText\" class=\"wu-result-subtitle\">{{ subtitleText }}</p>\n <div class=\"wu-result-extra\"><ng-content select=\"[wuResultExtra]\"></ng-content></div>\n <div class=\"wu-result-content\"><ng-content></ng-content></div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { WuResult } from './result.component';\n\n/** For NgModule apps. Standalone apps can import `WuResult` directly. */\n@NgModule({\n imports: [WuResult],\n exports: [WuResult],\n})\nexport class WuResultModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAOA,MAAM,QAAQ,GAA8B,CAAC,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC;AAEzG;;;;;;AAMG;MAYU,QAAQ,CAAA;;IAEnB,IAAa,MAAM,CAAC,CAAsD,EAAA;AACxE,QAAA,MAAM,CAAC,GAAG,MAAM,CAAC,CAAC,KAAA,IAAA,IAAD,CAAC,KAAA,KAAA,CAAA,GAAD,CAAC,GAAI,EAAE,CAAmB,CAAC;AAC5C,QAAA,IAAI,CAAC,OAAO,GAAG,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,MAAM,CAAC;KAClD;AACD,IAAA,IAAI,MAAM,GAAA;QACR,OAAO,IAAI,CAAC,OAAO,CAAC;KACrB;AAiBD,IAAA,WAAA,GAAA;;AATS,QAAA,IAAQ,CAAA,QAAA,GAAwC,IAAI,CAAC;AAKtD,QAAA,IAAO,CAAA,OAAA,GAAmB,MAAM,CAAC;AACxB,QAAA,IAAA,CAAA,MAAM,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAC;AAC1B,QAAA,IAAI,CAAA,IAAA,GAAG,qBAAqB,EAAE,CAAC;AAG9C,QAAA,uBAAuB,CAAC,MAAM,CAAC,sBAAsB,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;KAC7E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AA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,YAHf,QAAQ,CAAA,EAAA,CAAA,CAAA;4FAGP,cAAc,EAAA,UAAA,EAAA,CAAA;kBAJ1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,QAAQ,CAAC;oBACnB,OAAO,EAAE,CAAC,QAAQ,CAAC;iBACpB,CAAA;;;ACPD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"wirabyte-ui-result.mjs","sources":["../../lib/result/result.component.ts","../../lib/result/result.component.html","../../lib/result/result.module.ts","../../lib/result/wirabyte-ui-result.ts"],"sourcesContent":["import { NgClass, NgIf, NgSwitch, NgSwitchCase, NgSwitchDefault } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, inject, Input, OnDestroy, ViewEncapsulation } from '@angular/core';\nimport { ɵassertSupportedAngular, ɵrefreshOnTranslation, ɵWU_SKIP_VERSION_CHECK, WuConfig } from '@wirabyte/ui/config';\nimport { WuResultStatus } from '@wirabyte/ui/core';\n\nexport type { WuResultStatus };\n\nconst STATUSES: readonly WuResultStatus[] = ['success', 'error', 'info', 'warning', '403', '404', '500'];\n\n/**\n * The page or panel after a task ends, or instead of a page that cannot be shown:\n * `<wu-result status=\"success\" title=\"ส่งใบสมัครแล้ว\"><wu-button wuResultExtra label=\"กลับหน้าแรก\"></wu-button></wu-result>`.\n * `success`, `error`, `info` and `warning` draw a large status mark in the theme's colours; `403`, `404` and `500` draw\n * the code with a picture in place of its 0. Title and line come from the locale unless given. Elements marked\n * `wuResultExtra` sit in a row of actions; anything else inside the tag goes in a details box under them.\n */\n@Component({\n selector: 'wu-result',\n standalone: true,\n imports: [NgClass, NgIf, NgSwitch, NgSwitchCase, NgSwitchDefault],\n templateUrl: './result.component.html',\n styleUrls: ['./result.css'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n // `title` is an input here: keep it off the host so the whole block gets no browser tooltip.\n host: { class: 'wu-result-host', '[attr.title]': 'null' },\n})\nexport class WuResult implements OnDestroy {\n /** Default `'info'`. Numbers work too: `[status]=\"404\"`. */\n @Input() set status(v: WuResultStatus | number | string | null | undefined) {\n const s = String(v ?? '') as WuResultStatus;\n this._status = STATUSES.includes(s) ? s : 'info';\n }\n get status(): WuResultStatus {\n return this._status;\n }\n /** Default: the locale's title for `status`; `''` shows none. */\n @Input() title?: string | null;\n /** The line under the title. Default: the locale's line for `status`; `''` shows none. */\n @Input() subtitle?: string | null;\n /** An icon class (`'wi wi-rocket'`) in the status circle instead of the drawn mark. */\n @Input() icon?: string | null;\n /** `false` leaves out the mark or picture. */\n @Input() showIcon: boolean | string | null | undefined = true;\n @Input() styleClass?: string | null;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Input() style?: Record<string, any> | string | null;\n\n private _status: WuResultStatus = 'info';\n private readonly config = inject(WuConfig);\n private readonly i18n = ɵrefreshOnTranslation();\n\n constructor() {\n ɵassertSupportedAngular(inject(ɵWU_SKIP_VERSION_CHECK, { optional: true }));\n }\n\n ngOnDestroy(): void {\n this.i18n.unsubscribe();\n }\n\n // ---------- what the template reads ----------\n\n get titleText(): string {\n return this.title ?? this.config.translation.result?.[this._status]?.title ?? '';\n }\n get subtitleText(): string {\n return this.subtitle ?? this.config.translation.result?.[this._status]?.description ?? '';\n }\n /** 403, 404 and 500 draw their code; the others a status mark. */\n get isCode(): boolean {\n return this._status === '403' || this._status === '404' || this._status === '500';\n }\n get shown(): boolean {\n return this.showIcon !== false && this.showIcon !== 'false';\n }\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n get rootStyle(): Record<string, any> | null {\n return this.style && typeof this.style === 'object' ? this.style : null;\n }\n}\n","<div class=\"wu-result\" [class]=\"styleClass || ''\" [style]=\"rootStyle\" [attr.data-status]=\"status\">\n <ng-container *ngIf=\"shown\">\n <span *ngIf=\"!isCode; else code\" class=\"wu-result-mark\" aria-hidden=\"true\">\n <i *ngIf=\"icon; else mark\" [ngClass]=\"icon\"></i>\n <ng-template #mark>\n <svg viewBox=\"0 0 48 48\" focusable=\"false\" [ngSwitch]=\"status\">\n <path *ngSwitchCase=\"'success'\" d=\"m14 24.5 7 7 13-14\"></path>\n <path *ngSwitchCase=\"'error'\" d=\"m16 16 16 16m0-16L16 32\"></path>\n <g *ngSwitchCase=\"'warning'\">\n <path d=\"M24 13v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"34.5\" r=\"2.6\"></circle>\n </g>\n <g *ngSwitchDefault>\n <path d=\"M24 21v14\"></path>\n <circle class=\"wu-result-dot\" cx=\"24\" cy=\"13.5\" r=\"2.6\"></circle>\n </g>\n </svg>\n </ng-template>\n </span>\n <ng-template #code>\n <svg class=\"wu-result-art\" viewBox=\"0 0 240 110\" aria-hidden=\"true\" focusable=\"false\" [ngSwitch]=\"status\">\n <text class=\"wu-rs-digit\" x=\"52\" y=\"92\" text-anchor=\"middle\">{{ status === '500' ? '5' : '4' }}</text>\n <circle class=\"wu-rs-soft\" cx=\"120\" cy=\"60\" r=\"38\"></circle>\n <g *ngSwitchCase=\"'403'\">\n <path class=\"wu-rs-shackle\" d=\"M108 56v-8a12 12 0 0 1 24 0v8\"></path>\n <rect class=\"wu-rs-accent-fill\" x=\"102\" y=\"55\" width=\"36\" height=\"28\" rx=\"6\"></rect>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"66\" r=\"3.5\"></circle>\n <path class=\"wu-rs-paper-line\" d=\"M120 68v7\"></path>\n </g>\n <g *ngSwitchCase=\"'500'\">\n <path class=\"wu-rs-accent-fill\" d=\"M126 30 106 63h13l-6 27 22-36h-13z\"></path>\n </g>\n <g *ngSwitchDefault>\n <circle class=\"wu-rs-ring\" cx=\"120\" cy=\"60\" r=\"24\"></circle>\n <path class=\"wu-rs-accent-fill\" d=\"m132 48-8 16-16 8 8-16z\"></path>\n <circle class=\"wu-rs-paper-fill\" cx=\"120\" cy=\"60\" r=\"2.5\"></circle>\n </g>\n <text class=\"wu-rs-digit\" x=\"188\" y=\"92\" text-anchor=\"middle\">{{ status === '403' ? '3' : status === '500' ? '0' : '4' }}</text>\n </svg>\n </ng-template>\n </ng-container>\n <p *ngIf=\"titleText\" class=\"wu-result-title\">{{ titleText }}</p>\n <p *ngIf=\"subtitleText\" class=\"wu-result-subtitle\">{{ subtitleText }}</p>\n <div class=\"wu-result-extra\"><ng-content select=\"[wuResultExtra]\"></ng-content></div>\n <div class=\"wu-result-content\"><ng-content></ng-content></div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { WuResult } from './result.component';\n\n/** For NgModule apps. Standalone apps can import `WuResult` directly. */\n@NgModule({\n imports: [WuResult],\n exports: [WuResult],\n})\nexport class WuResultModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAOA,MAAM,QAAQ,GAA8B,CAAC,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC;AAEzG;;;;;;AAMG;MAYU,QAAQ,CAAA;;IAEnB,IAAa,MAAM,CAAC,CAAsD,EAAA;AACxE,QAAA,MAAM,CAAC,GAAG,MAAM,CAAC,CAAC,KAAA,IAAA,IAAD,CAAC,KAAA,KAAA,CAAA,GAAD,CAAC,GAAI,EAAE,CAAmB,CAAC;AAC5C,QAAA,IAAI,CAAC,OAAO,GAAG,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,MAAM,CAAC;KAClD;AACD,IAAA,IAAI,MAAM,GAAA;QACR,OAAO,IAAI,CAAC,OAAO,CAAC;KACrB;AAiBD,IAAA,WAAA,GAAA;;AATS,QAAA,IAAQ,CAAA,QAAA,GAAwC,IAAI,CAAC;AAKtD,QAAA,IAAO,CAAA,OAAA,GAAmB,MAAM,CAAC;AACxB,Q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