@edsis/angular 22.1.6 → 22.2.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +87 -399
- package/SECURITY.md +18 -0
- package/SUPPORT.md +15 -0
- package/chart/README.md +272 -0
- package/component/README.md +89 -0
- package/component/accordion/README.md +195 -0
- package/component/alert/README.md +184 -0
- package/component/alert-dialog/README.md +255 -0
- package/component/aspect-ratio/README.md +116 -0
- package/component/avatar/README.md +182 -0
- package/component/badge/README.md +143 -0
- package/component/breadcrumb/README.md +223 -0
- package/component/button/README.md +141 -0
- package/component/button-group/README.md +214 -0
- package/component/calendar/README.md +125 -0
- package/component/card/README.md +232 -0
- package/component/carousel/README.md +276 -0
- package/component/checkbox/README.md +153 -0
- package/component/collapsible/README.md +216 -0
- package/component/combobox/README.md +202 -0
- package/component/command/README.md +287 -0
- package/component/composer/README.md +241 -0
- package/component/context-menu/README.md +268 -0
- package/component/date-picker/README.md +202 -0
- package/component/dialog/README.md +276 -0
- package/component/drawer/README.md +146 -0
- package/component/dropdown-menu/README.md +336 -0
- package/component/editor/README.md +152 -0
- package/component/empty/README.md +193 -0
- package/component/form/README.md +216 -0
- package/component/hover-card/README.md +150 -0
- package/component/icon/README.md +52 -0
- package/component/input/README.md +160 -0
- package/component/input-group/README.md +245 -0
- package/component/input-otp/README.md +331 -0
- package/component/item/README.md +254 -0
- package/component/kanban/README.md +81 -0
- package/component/kbd/README.md +141 -0
- package/component/label/README.md +137 -0
- package/component/menubar/README.md +270 -0
- package/component/native-select/README.md +176 -0
- package/component/navigation-menu/README.md +165 -0
- package/component/pagination/README.md +151 -0
- package/component/pillbox/README.md +68 -0
- package/component/popover/README.md +54 -0
- package/component/progress/README.md +160 -0
- package/component/radio/README.md +212 -0
- package/component/resizable/README.md +178 -0
- package/component/scroll-area/README.md +150 -0
- package/component/select/README.md +228 -0
- package/component/separator/README.md +175 -0
- package/component/sheet/README.md +190 -0
- package/component/skeleton/README.md +158 -0
- package/component/slider/README.md +207 -0
- package/component/spinner/README.md +160 -0
- package/component/switch/README.md +170 -0
- package/component/table/README.md +292 -0
- package/component/tabs/README.md +220 -0
- package/component/textarea/README.md +169 -0
- package/component/timeline/README.md +94 -0
- package/component/toast/README.md +173 -0
- package/component/toggle/README.md +133 -0
- package/component/toggle-group/README.md +234 -0
- package/component/tooltip/README.md +230 -0
- package/fesm2022/edsis-angular-chart-area.mjs +508 -0
- package/fesm2022/edsis-angular-chart-bar.mjs +946 -0
- package/fesm2022/edsis-angular-chart-core.mjs +1282 -0
- package/fesm2022/edsis-angular-chart-line.mjs +544 -0
- package/fesm2022/edsis-angular-chart-pie.mjs +524 -0
- package/fesm2022/edsis-angular-chart-primitives.mjs +1647 -0
- package/fesm2022/edsis-angular-chart-radar.mjs +693 -0
- package/fesm2022/edsis-angular-chart-radial.mjs +542 -0
- package/fesm2022/edsis-angular-chart-scatter.mjs +486 -0
- package/fesm2022/edsis-angular-chart.mjs +3 -0
- package/fesm2022/edsis-angular-component-accordion.mjs +513 -0
- package/fesm2022/edsis-angular-component-alert-dialog.mjs +1001 -0
- package/fesm2022/edsis-angular-component-alert.mjs +268 -0
- package/fesm2022/edsis-angular-component-aspect-ratio.mjs +80 -0
- package/fesm2022/edsis-angular-component-avatar.mjs +410 -0
- package/fesm2022/edsis-angular-component-badge.mjs +111 -0
- package/fesm2022/edsis-angular-component-breadcrumb.mjs +464 -0
- package/fesm2022/edsis-angular-component-button-group.mjs +252 -0
- package/fesm2022/edsis-angular-component-button.mjs +155 -0
- package/fesm2022/edsis-angular-component-calendar.mjs +835 -0
- package/fesm2022/edsis-angular-component-card.mjs +460 -0
- package/fesm2022/edsis-angular-component-carousel.mjs +700 -0
- package/fesm2022/edsis-angular-component-checkbox.mjs +398 -0
- package/fesm2022/edsis-angular-component-collapsible.mjs +305 -0
- package/fesm2022/edsis-angular-component-combobox.mjs +544 -0
- package/fesm2022/edsis-angular-component-command.mjs +815 -0
- package/fesm2022/edsis-angular-component-composer.mjs +840 -0
- package/fesm2022/edsis-angular-component-context-menu.mjs +197 -0
- package/fesm2022/edsis-angular-component-date-picker.mjs +798 -0
- package/fesm2022/edsis-angular-component-dialog.mjs +798 -0
- package/fesm2022/edsis-angular-component-drawer.mjs +2 -0
- package/fesm2022/edsis-angular-component-dropdown-menu.mjs +1259 -0
- package/fesm2022/edsis-angular-component-editor.mjs +1000 -0
- package/fesm2022/edsis-angular-component-empty.mjs +351 -0
- package/fesm2022/edsis-angular-component-form.mjs +821 -0
- package/fesm2022/edsis-angular-component-hover-card.mjs +486 -0
- package/fesm2022/edsis-angular-component-icon.mjs +253 -0
- package/fesm2022/edsis-angular-component-input-group.mjs +453 -0
- package/fesm2022/edsis-angular-component-input-otp.mjs +957 -0
- package/fesm2022/edsis-angular-component-input.mjs +87 -0
- package/fesm2022/edsis-angular-component-item.mjs +720 -0
- package/fesm2022/edsis-angular-component-kanban.mjs +812 -0
- package/fesm2022/edsis-angular-component-kbd.mjs +124 -0
- package/fesm2022/edsis-angular-component-label.mjs +82 -0
- package/fesm2022/edsis-angular-component-menubar.mjs +481 -0
- package/fesm2022/edsis-angular-component-native-select.mjs +168 -0
- package/fesm2022/edsis-angular-component-navigation-menu.mjs +685 -0
- package/fesm2022/edsis-angular-component-pagination.mjs +425 -0
- package/fesm2022/edsis-angular-component-pillbox.mjs +1679 -0
- package/fesm2022/edsis-angular-component-popover.mjs +292 -0
- package/fesm2022/edsis-angular-component-progress.mjs +184 -0
- package/fesm2022/edsis-angular-component-radio.mjs +491 -0
- package/fesm2022/edsis-angular-component-resizable.mjs +703 -0
- package/fesm2022/edsis-angular-component-scroll-area.mjs +133 -0
- package/fesm2022/edsis-angular-component-segmented-control.mjs +408 -0
- package/fesm2022/edsis-angular-component-select.mjs +743 -0
- package/fesm2022/edsis-angular-component-separator.mjs +102 -0
- package/fesm2022/edsis-angular-component-sheet.mjs +874 -0
- package/fesm2022/edsis-angular-component-skeleton.mjs +62 -0
- package/fesm2022/edsis-angular-component-slider.mjs +676 -0
- package/fesm2022/edsis-angular-component-spinner.mjs +157 -0
- package/fesm2022/edsis-angular-component-switch.mjs +361 -0
- package/fesm2022/edsis-angular-component-table.mjs +446 -0
- package/fesm2022/edsis-angular-component-tabs.mjs +592 -0
- package/fesm2022/edsis-angular-component-textarea.mjs +85 -0
- package/fesm2022/edsis-angular-component-timeline.mjs +619 -0
- package/fesm2022/edsis-angular-component-toast.mjs +231 -0
- package/fesm2022/edsis-angular-component-toggle-group.mjs +579 -0
- package/fesm2022/edsis-angular-component-toggle.mjs +189 -0
- package/fesm2022/edsis-angular-component-tooltip.mjs +804 -0
- package/fesm2022/edsis-angular-component-utils-core.mjs +181 -0
- package/fesm2022/edsis-angular-component-utils-overlay.mjs +54 -0
- package/fesm2022/edsis-angular-component-utils-scale.mjs +76 -0
- package/fesm2022/edsis-angular-component-utils.mjs +2 -0
- package/fesm2022/edsis-angular-component.mjs +0 -0
- package/fesm2022/edsis-angular-navigation-core.mjs +15 -0
- package/fesm2022/edsis-angular-navigation-icon.mjs +35 -0
- package/fesm2022/edsis-angular-navigation-navigation-badge-count.component-BWWWaUgy.mjs +234 -0
- package/fesm2022/edsis-angular-navigation-navigation-dockbar-menu.component-Bx2bxTID.mjs +834 -0
- package/fesm2022/edsis-angular-navigation-navigation-entry-grid.component-Duzt1ffz.mjs +823 -0
- package/fesm2022/edsis-angular-navigation-navigation-flyout-menu.component-cJ8Q1vM6.mjs +670 -0
- package/fesm2022/edsis-angular-navigation-navigation-horizontal.component-CDQ1wt2_.mjs +689 -0
- package/fesm2022/edsis-angular-navigation-navigation-item.component-C1VzerJp.mjs +1522 -0
- package/fesm2022/edsis-angular-navigation-navigation-list.component-BPYLfrID.mjs +346 -0
- package/fesm2022/edsis-angular-navigation-service.mjs +558 -0
- package/fesm2022/edsis-angular-navigation-types.mjs +151 -0
- package/fesm2022/edsis-angular-navigation.mjs +3338 -0
- package/fesm2022/edsis-angular-sdk.mjs +100 -0
- package/fesm2022/edsis-angular-theme-component-settings.mjs +1877 -0
- package/fesm2022/edsis-angular-theme-layout-services.mjs +252 -0
- package/fesm2022/edsis-angular-theme-layout-types.mjs +45 -0
- package/fesm2022/edsis-angular-theme-layout-wrapper.mjs +2568 -0
- package/fesm2022/edsis-angular-theme-layout.mjs +1089 -0
- package/fesm2022/edsis-angular-theme-page-core.mjs +315 -0
- package/fesm2022/edsis-angular-theme-page-filter.mjs +409 -0
- package/fesm2022/edsis-angular-theme-page-overview.mjs +88 -0
- package/fesm2022/edsis-angular-theme-page-root.mjs +693 -0
- package/fesm2022/edsis-angular-theme-page-side.mjs +342 -0
- package/fesm2022/edsis-angular-theme-page-slots.mjs +258 -0
- package/fesm2022/edsis-angular-theme-page.mjs +7 -0
- package/fesm2022/edsis-angular-theme-shell-services.mjs +231 -0
- package/fesm2022/edsis-angular-theme-shell-types.mjs +102 -0
- package/fesm2022/edsis-angular-theme-shell.mjs +1352 -0
- package/fesm2022/edsis-angular-theme-styles.mjs +572 -0
- package/fesm2022/edsis-angular-theme.mjs +0 -0
- package/fesm2022/edsis-angular.mjs +5 -8
- package/navigation/README.md +576 -0
- package/package.json +477 -52
- package/sdk/README.md +212 -0
- package/sdk/schematics/collection.json +20 -0
- package/sdk/schematics/init/index.js +83 -0
- package/sdk/schematics/init/schema.json +19 -0
- package/sdk/schematics/ng-add/index.js +147 -0
- package/sdk/schematics/ng-add/schema.json +14 -0
- package/sdk/schematics/package.json +3 -0
- package/sdk/schematics/sdk/index.js +175 -0
- package/sdk/schematics/sdk/schema.json +19 -0
- package/sdk/sdk.config.example.json +24 -0
- package/sdk/src/config/loader.js +43 -0
- package/sdk/src/config/schema.js +59 -0
- package/sdk/src/emit/client.js +251 -0
- package/sdk/src/emit/metadata.js +310 -0
- package/sdk/src/emit/models.js +104 -0
- package/sdk/src/emit/navigation.js +56 -0
- package/sdk/src/emit/operations.js +118 -0
- package/sdk/src/emit/public-api.js +54 -0
- package/sdk/src/emit/services.js +110 -0
- package/sdk/src/engine.js +67 -0
- package/sdk/src/layout/per-domain.js +360 -0
- package/sdk/src/package.json +3 -0
- package/sdk/src/parser/bundle.js +25 -0
- package/sdk/src/parser/ir.js +429 -0
- package/sdk/src/parser/types.js +7 -0
- package/sdk/src/render/template.js +152 -0
- package/sdk/src/writer/index.js +286 -0
- package/theme/README.md +120 -0
- package/theme/component/settings/README.md +154 -0
- package/theme/layout/README.md +604 -0
- package/theme/page/README.md +505 -0
- package/theme/shell/README.md +344 -0
- package/theme/styles/README.md +202 -0
- package/theme/styles/css/base/components.css +577 -0
- package/theme/styles/css/base/index.css +14 -0
- package/theme/styles/css/base/package.css +9 -0
- package/theme/styles/css/base/prefers-dark.css +86 -0
- package/theme/styles/css/base/print.css +62 -0
- package/theme/styles/css/base/status.css +38 -0
- package/theme/styles/css/base/tailwind.css +208 -0
- package/theme/styles/css/base/theme.css +353 -0
- package/theme/styles/css/base/tokens.css +388 -0
- package/theme/styles/css/color/amber.css +72 -0
- package/theme/styles/css/color/blue.css +72 -0
- package/theme/styles/css/color/brand.css +38 -0
- package/theme/styles/css/color/cyan.css +72 -0
- package/theme/styles/css/color/emerald.css +72 -0
- package/theme/styles/css/color/fuchsia.css +72 -0
- package/theme/styles/css/color/green.css +72 -0
- package/theme/styles/css/color/index.css +19 -0
- package/theme/styles/css/color/indigo.css +72 -0
- package/theme/styles/css/color/lime.css +72 -0
- package/theme/styles/css/color/orange.css +72 -0
- package/theme/styles/css/color/pink.css +72 -0
- package/theme/styles/css/color/purple.css +72 -0
- package/theme/styles/css/color/red.css +72 -0
- package/theme/styles/css/color/rose.css +72 -0
- package/theme/styles/css/color/sky.css +72 -0
- package/theme/styles/css/color/teal.css +72 -0
- package/theme/styles/css/color/violet.css +72 -0
- package/theme/styles/css/color/yellow.css +72 -0
- package/theme/styles/css/fonts.css +85 -0
- package/theme/styles/css/index.css +18 -0
- package/theme/styles/css/neutral/gray.css +63 -0
- package/theme/styles/css/neutral/index.css +11 -0
- package/theme/styles/css/neutral/mauve.css +63 -0
- package/theme/styles/css/neutral/mist.css +63 -0
- package/theme/styles/css/neutral/neutral.css +63 -0
- package/theme/styles/css/neutral/olive.css +63 -0
- package/theme/styles/css/neutral/slate.css +63 -0
- package/theme/styles/css/neutral/stone.css +63 -0
- package/theme/styles/css/neutral/taupe.css +63 -0
- package/theme/styles/css/neutral/zinc.css +63 -0
- package/theme/styles/css/radius/index.css +30 -0
- package/theme/styles/css/space/index.css +20 -0
- package/types/edsis-angular-chart-area.d.ts +139 -0
- package/types/edsis-angular-chart-bar.d.ts +291 -0
- package/types/edsis-angular-chart-core.d.ts +822 -0
- package/types/edsis-angular-chart-line.d.ts +148 -0
- package/types/edsis-angular-chart-pie.d.ts +202 -0
- package/types/edsis-angular-chart-primitives.d.ts +360 -0
- package/types/edsis-angular-chart-radar.d.ts +198 -0
- package/types/edsis-angular-chart-radial.d.ts +187 -0
- package/types/edsis-angular-chart-scatter.d.ts +181 -0
- package/types/edsis-angular-chart.d.ts +3 -0
- package/types/edsis-angular-component-accordion.d.ts +139 -0
- package/types/edsis-angular-component-alert-dialog.d.ts +288 -0
- package/types/edsis-angular-component-alert.d.ts +72 -0
- package/types/edsis-angular-component-aspect-ratio.d.ts +20 -0
- package/types/edsis-angular-component-avatar.d.ts +111 -0
- package/types/edsis-angular-component-badge.d.ts +36 -0
- package/types/edsis-angular-component-breadcrumb.d.ts +85 -0
- package/types/edsis-angular-component-button-group.d.ts +50 -0
- package/types/edsis-angular-component-button.d.ts +44 -0
- package/types/edsis-angular-component-calendar.d.ts +150 -0
- package/types/edsis-angular-component-card.d.ts +123 -0
- package/types/edsis-angular-component-carousel.d.ts +155 -0
- package/types/edsis-angular-component-checkbox.d.ts +100 -0
- package/types/edsis-angular-component-collapsible.d.ts +68 -0
- package/types/edsis-angular-component-combobox.d.ts +105 -0
- package/types/edsis-angular-component-command.d.ts +215 -0
- package/types/edsis-angular-component-composer.d.ts +190 -0
- package/types/edsis-angular-component-context-menu.d.ts +64 -0
- package/types/edsis-angular-component-date-picker.d.ts +199 -0
- package/types/edsis-angular-component-dialog.d.ts +231 -0
- package/types/edsis-angular-component-drawer.d.ts +2 -0
- package/types/edsis-angular-component-dropdown-menu.d.ts +370 -0
- package/types/edsis-angular-component-editor.d.ts +234 -0
- package/types/edsis-angular-component-empty.d.ts +85 -0
- package/types/edsis-angular-component-form.d.ts +223 -0
- package/types/edsis-angular-component-hover-card.d.ts +133 -0
- package/types/edsis-angular-component-icon.d.ts +90 -0
- package/types/edsis-angular-component-input-group.d.ts +98 -0
- package/types/edsis-angular-component-input-otp.d.ts +249 -0
- package/types/edsis-angular-component-input.d.ts +31 -0
- package/types/edsis-angular-component-item.d.ts +169 -0
- package/types/edsis-angular-component-kanban.d.ts +165 -0
- package/types/edsis-angular-component-kbd.d.ts +25 -0
- package/types/edsis-angular-component-label.d.ts +19 -0
- package/types/edsis-angular-component-menubar.d.ts +123 -0
- package/types/edsis-angular-component-native-select.d.ts +39 -0
- package/types/edsis-angular-component-navigation-menu.d.ts +163 -0
- package/types/edsis-angular-component-pagination.d.ts +83 -0
- package/types/edsis-angular-component-pillbox.d.ts +380 -0
- package/types/edsis-angular-component-popover.d.ts +96 -0
- package/types/edsis-angular-component-progress.d.ts +45 -0
- package/types/edsis-angular-component-radio.d.ts +137 -0
- package/types/edsis-angular-component-resizable.d.ts +166 -0
- package/types/edsis-angular-component-scroll-area.d.ts +37 -0
- package/types/edsis-angular-component-segmented-control.d.ts +102 -0
- package/types/edsis-angular-component-select.d.ts +138 -0
- package/types/edsis-angular-component-separator.d.ts +26 -0
- package/types/edsis-angular-component-sheet.d.ts +240 -0
- package/types/edsis-angular-component-skeleton.d.ts +13 -0
- package/types/edsis-angular-component-slider.d.ts +148 -0
- package/types/edsis-angular-component-spinner.d.ts +31 -0
- package/types/edsis-angular-component-switch.d.ts +101 -0
- package/types/edsis-angular-component-table.d.ts +109 -0
- package/types/edsis-angular-component-tabs.d.ts +183 -0
- package/types/edsis-angular-component-textarea.d.ts +27 -0
- package/types/edsis-angular-component-timeline.d.ts +146 -0
- package/types/edsis-angular-component-toast.d.ts +60 -0
- package/types/edsis-angular-component-toggle-group.d.ts +161 -0
- package/types/edsis-angular-component-toggle.d.ts +47 -0
- package/types/edsis-angular-component-tooltip.d.ts +233 -0
- package/types/edsis-angular-component-utils-core.d.ts +175 -0
- package/types/edsis-angular-component-utils-overlay.d.ts +17 -0
- package/types/edsis-angular-component-utils-scale.d.ts +27 -0
- package/types/edsis-angular-component-utils.d.ts +2 -0
- package/types/edsis-angular-component.d.ts +1 -0
- package/types/edsis-angular-navigation-core.d.ts +55 -0
- package/types/edsis-angular-navigation-icon.d.ts +9 -0
- package/types/edsis-angular-navigation-service.d.ts +121 -0
- package/types/edsis-angular-navigation-types.d.ts +185 -0
- package/types/edsis-angular-navigation.d.ts +862 -0
- package/types/edsis-angular-sdk.d.ts +87 -0
- package/types/edsis-angular-theme-component-settings.d.ts +205 -0
- package/types/edsis-angular-theme-layout-services.d.ts +143 -0
- package/types/edsis-angular-theme-layout-types.d.ts +36 -0
- package/types/edsis-angular-theme-layout-wrapper.d.ts +670 -0
- package/types/edsis-angular-theme-layout.d.ts +218 -0
- package/types/edsis-angular-theme-page-core.d.ts +151 -0
- package/types/edsis-angular-theme-page-filter.d.ts +127 -0
- package/types/edsis-angular-theme-page-overview.d.ts +28 -0
- package/types/edsis-angular-theme-page-root.d.ts +172 -0
- package/types/edsis-angular-theme-page-side.d.ts +90 -0
- package/types/edsis-angular-theme-page-slots.d.ts +61 -0
- package/types/edsis-angular-theme-page.d.ts +7 -0
- package/types/edsis-angular-theme-shell-services.d.ts +188 -0
- package/types/edsis-angular-theme-shell-types.d.ts +102 -0
- package/types/edsis-angular-theme-shell.d.ts +178 -0
- package/types/edsis-angular-theme-styles.d.ts +295 -0
- package/types/edsis-angular-theme.d.ts +1 -0
- package/types/edsis-angular.d.ts +5 -2
- package/fesm2022/edsis-angular-block-shell.mjs +0 -1329
- package/fesm2022/edsis-angular-block-shell.mjs.map +0 -1
- package/fesm2022/edsis-angular-block-themes.mjs +0 -1007
- package/fesm2022/edsis-angular-block-themes.mjs.map +0 -1
- package/fesm2022/edsis-angular-module-auth.mjs +0 -2582
- package/fesm2022/edsis-angular-module-auth.mjs.map +0 -1
- package/fesm2022/edsis-angular-platform-mfe.mjs +0 -329
- package/fesm2022/edsis-angular-platform-mfe.mjs.map +0 -1
- package/fesm2022/edsis-angular-services-runtime.mjs +0 -385
- package/fesm2022/edsis-angular-services-runtime.mjs.map +0 -1
- package/fesm2022/edsis-angular.mjs.map +0 -1
- package/types/edsis-angular-block-shell.d.ts +0 -190
- package/types/edsis-angular-block-themes.d.ts +0 -94
- package/types/edsis-angular-module-auth.d.ts +0 -533
- package/types/edsis-angular-platform-mfe.d.ts +0 -126
- package/types/edsis-angular-services-runtime.d.ts +0 -118
|
@@ -0,0 +1,946 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { Component, computed, inject, input, output } from "@angular/core";
|
|
3
|
+
import { CartesianContext, ChartContext, ChartDataTable, ChartMarkFocus, ChartRovingFocus, ChartThemeRadius, ChartThemeSpace, DEFAULT_CARTESIAN_MARGIN_UNITS, readNumber, resolveChartMargin, resolveChartStyle, resolveSeriesColor, seriesColorVar, setupCartesianChart, zeroBaselineDomain } from "@edsis/angular/chart/core";
|
|
4
|
+
import { scaleBand, scaleLinear } from "d3-scale";
|
|
5
|
+
import { max, min } from "d3-array";
|
|
6
|
+
import { stack } from "d3-shape";
|
|
7
|
+
import { ChartPointerTracker } from "@edsis/angular/chart/primitives";
|
|
8
|
+
function resolveBarColor(datum, seriesKey, colorKey) {
|
|
9
|
+
return resolveSeriesColor(colorKey ? datum[colorKey] : void 0, seriesColorVar(seriesKey));
|
|
10
|
+
}
|
|
11
|
+
function isActiveBar(datum, activeKey, activeValue) {
|
|
12
|
+
if (!activeKey || activeValue === void 0) return false;
|
|
13
|
+
const value = datum[activeKey];
|
|
14
|
+
if (typeof value === "number" && typeof activeValue === "number") return value === activeValue;
|
|
15
|
+
return String(value ?? "") === String(activeValue);
|
|
16
|
+
}
|
|
17
|
+
function computeBarLayout(input) {
|
|
18
|
+
const { data, xKey, seriesKeys, variant, orientation, innerWidth, innerHeight, bandPadding, groupPadding, colorKey, activeKey, activeValue } = input;
|
|
19
|
+
const categories = data.map((d) => String(d[xKey] ?? ""));
|
|
20
|
+
const isVertical = orientation === "vertical";
|
|
21
|
+
const categoryScale = scaleBand().domain(categories).range(isVertical ? [0, innerWidth] : [0, innerHeight]).padding(bandPadding);
|
|
22
|
+
const valueScale = scaleLinear();
|
|
23
|
+
if (variant === "stacked" && seriesKeys.length > 0) return stackedLayout({
|
|
24
|
+
data,
|
|
25
|
+
xKey,
|
|
26
|
+
seriesKeys,
|
|
27
|
+
orientation,
|
|
28
|
+
innerWidth,
|
|
29
|
+
innerHeight,
|
|
30
|
+
categoryScale,
|
|
31
|
+
valueScale,
|
|
32
|
+
categories,
|
|
33
|
+
colorKey,
|
|
34
|
+
activeKey,
|
|
35
|
+
activeValue
|
|
36
|
+
});
|
|
37
|
+
return groupedLayout({
|
|
38
|
+
data,
|
|
39
|
+
xKey,
|
|
40
|
+
seriesKeys,
|
|
41
|
+
orientation,
|
|
42
|
+
innerWidth,
|
|
43
|
+
innerHeight,
|
|
44
|
+
categoryScale,
|
|
45
|
+
valueScale,
|
|
46
|
+
groupPadding,
|
|
47
|
+
categories,
|
|
48
|
+
colorKey,
|
|
49
|
+
activeKey,
|
|
50
|
+
activeValue
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
function groupedLayout(input) {
|
|
54
|
+
const { data, seriesKeys, orientation, innerWidth, innerHeight, categoryScale, valueScale, groupPadding, categories, colorKey, activeKey, activeValue } = input;
|
|
55
|
+
const isVertical = orientation === "vertical";
|
|
56
|
+
const minValue = min(data, (d) => min(seriesKeys, (k) => readNumber(d, k)) ?? 0) ?? 0;
|
|
57
|
+
const maxValue = max(data, (d) => max(seriesKeys, (k) => readNumber(d, k)) ?? 0) ?? 0;
|
|
58
|
+
const [domainMin, domainMax] = zeroBaselineDomain(minValue, maxValue);
|
|
59
|
+
valueScale.domain([domainMin, domainMax]).nice().range(isVertical ? [innerHeight, 0] : [0, innerWidth]);
|
|
60
|
+
const baseline = valueScale(0);
|
|
61
|
+
const subScale = scaleBand().domain(seriesKeys).range([0, categoryScale.bandwidth()]).padding(groupPadding);
|
|
62
|
+
const bars = [];
|
|
63
|
+
data.forEach((datum, datumIndex) => {
|
|
64
|
+
const category = categories[datumIndex];
|
|
65
|
+
const bandStart = categoryScale(category) ?? 0;
|
|
66
|
+
seriesKeys.forEach((seriesKey) => {
|
|
67
|
+
const value = readNumber(datum, seriesKey);
|
|
68
|
+
const sub = subScale(seriesKey) ?? 0;
|
|
69
|
+
const scaledValue = valueScale(value);
|
|
70
|
+
const color = resolveBarColor(datum, seriesKey, colorKey);
|
|
71
|
+
const active = isActiveBar(datum, activeKey, activeValue);
|
|
72
|
+
const rect = isVertical ? {
|
|
73
|
+
key: `${datumIndex}-${seriesKey}`,
|
|
74
|
+
seriesKey,
|
|
75
|
+
datumIndex,
|
|
76
|
+
category,
|
|
77
|
+
value,
|
|
78
|
+
x: bandStart + sub,
|
|
79
|
+
y: Math.min(scaledValue, baseline),
|
|
80
|
+
width: subScale.bandwidth(),
|
|
81
|
+
height: Math.abs(baseline - scaledValue),
|
|
82
|
+
color,
|
|
83
|
+
active
|
|
84
|
+
} : {
|
|
85
|
+
key: `${datumIndex}-${seriesKey}`,
|
|
86
|
+
seriesKey,
|
|
87
|
+
datumIndex,
|
|
88
|
+
category,
|
|
89
|
+
value,
|
|
90
|
+
x: Math.min(scaledValue, baseline),
|
|
91
|
+
y: bandStart + sub,
|
|
92
|
+
width: Math.abs(baseline - scaledValue),
|
|
93
|
+
height: subScale.bandwidth(),
|
|
94
|
+
color,
|
|
95
|
+
active
|
|
96
|
+
};
|
|
97
|
+
bars.push(rect);
|
|
98
|
+
});
|
|
99
|
+
});
|
|
100
|
+
return {
|
|
101
|
+
bars,
|
|
102
|
+
categoryScale,
|
|
103
|
+
valueScale,
|
|
104
|
+
categories
|
|
105
|
+
};
|
|
106
|
+
}
|
|
107
|
+
function stackedLayout(input) {
|
|
108
|
+
const { data, seriesKeys, orientation, innerWidth, innerHeight, categoryScale, valueScale, categories, colorKey, activeKey, activeValue } = input;
|
|
109
|
+
const isVertical = orientation === "vertical";
|
|
110
|
+
const normalized = data.map((d) => {
|
|
111
|
+
const out = {};
|
|
112
|
+
for (const k of seriesKeys) out[k] = readNumber(d, k);
|
|
113
|
+
return out;
|
|
114
|
+
});
|
|
115
|
+
const series = stack().keys(seriesKeys)(normalized);
|
|
116
|
+
const minTotal = min(series, (layer) => min(layer, (p) => Math.min(p[0], p[1]))) ?? 0;
|
|
117
|
+
const maxTotal = max(series, (layer) => max(layer, (p) => Math.max(p[0], p[1]))) ?? 0;
|
|
118
|
+
const [domainMin, domainMax] = zeroBaselineDomain(minTotal, maxTotal);
|
|
119
|
+
valueScale.domain([domainMin, domainMax]).nice().range(isVertical ? [innerHeight, 0] : [0, innerWidth]);
|
|
120
|
+
const bars = [];
|
|
121
|
+
series.forEach((layer) => {
|
|
122
|
+
const seriesKey = layer.key;
|
|
123
|
+
layer.forEach((point, datumIndex) => {
|
|
124
|
+
const [lower, upper] = point;
|
|
125
|
+
const value = upper - lower;
|
|
126
|
+
const category = categories[datumIndex];
|
|
127
|
+
const bandStart = categoryScale(category) ?? 0;
|
|
128
|
+
const color = resolveBarColor(data[datumIndex], seriesKey, colorKey);
|
|
129
|
+
const active = isActiveBar(data[datumIndex], activeKey, activeValue);
|
|
130
|
+
const lowerCoord = valueScale(lower);
|
|
131
|
+
const upperCoord = valueScale(upper);
|
|
132
|
+
const span = Math.abs(upperCoord - lowerCoord);
|
|
133
|
+
const rect = isVertical ? {
|
|
134
|
+
key: `${datumIndex}-${seriesKey}`,
|
|
135
|
+
seriesKey,
|
|
136
|
+
datumIndex,
|
|
137
|
+
category,
|
|
138
|
+
value,
|
|
139
|
+
x: bandStart,
|
|
140
|
+
y: Math.min(lowerCoord, upperCoord),
|
|
141
|
+
width: categoryScale.bandwidth(),
|
|
142
|
+
height: span,
|
|
143
|
+
color,
|
|
144
|
+
active
|
|
145
|
+
} : {
|
|
146
|
+
key: `${datumIndex}-${seriesKey}`,
|
|
147
|
+
seriesKey,
|
|
148
|
+
datumIndex,
|
|
149
|
+
category,
|
|
150
|
+
value,
|
|
151
|
+
x: Math.min(lowerCoord, upperCoord),
|
|
152
|
+
y: bandStart,
|
|
153
|
+
width: span,
|
|
154
|
+
height: categoryScale.bandwidth(),
|
|
155
|
+
color,
|
|
156
|
+
active
|
|
157
|
+
};
|
|
158
|
+
bars.push(rect);
|
|
159
|
+
});
|
|
160
|
+
});
|
|
161
|
+
return {
|
|
162
|
+
bars,
|
|
163
|
+
categoryScale,
|
|
164
|
+
valueScale,
|
|
165
|
+
categories
|
|
166
|
+
};
|
|
167
|
+
}
|
|
168
|
+
const MAX_ROWS_PER_COLUMN = 400;
|
|
169
|
+
const EDGE_TOLERANCE = .5;
|
|
170
|
+
function computeBarDotCells(input) {
|
|
171
|
+
const { bars, orientation, innerWidth, innerHeight, baseline, dotSize, dotGap } = input;
|
|
172
|
+
const isVertical = orientation === "vertical";
|
|
173
|
+
const innerLength = isVertical ? innerHeight : innerWidth;
|
|
174
|
+
const track = [];
|
|
175
|
+
const values = [];
|
|
176
|
+
if (innerLength <= 0 || bars.length === 0) return {
|
|
177
|
+
track,
|
|
178
|
+
values
|
|
179
|
+
};
|
|
180
|
+
groupColumns(bars, isVertical).forEach((column, columnIndex) => {
|
|
181
|
+
const cellLength = dotSize ?? column.thickness;
|
|
182
|
+
const step = cellLength + dotGap;
|
|
183
|
+
if (cellLength <= 0 || step <= EDGE_TOLERANCE) return;
|
|
184
|
+
const rowStart = (r) => isVertical ? baseline - r * step - cellLength : baseline + r * step;
|
|
185
|
+
const rowAt = (c) => isVertical ? (baseline - c - cellLength / 2) / step : (c - baseline - cellLength / 2) / step;
|
|
186
|
+
const rMin = Math.ceil(isVertical ? (baseline - innerLength - EDGE_TOLERANCE) / step : (-baseline - EDGE_TOLERANCE) / step);
|
|
187
|
+
let rMax = Math.floor(isVertical ? (baseline - cellLength + EDGE_TOLERANCE) / step : (innerLength - baseline - cellLength + EDGE_TOLERANCE) / step);
|
|
188
|
+
if (rMax - rMin + 1 > MAX_ROWS_PER_COLUMN) rMax = rMin + MAX_ROWS_PER_COLUMN - 1;
|
|
189
|
+
const cellRect = (r) => isVertical ? {
|
|
190
|
+
x: column.pos,
|
|
191
|
+
y: rowStart(r),
|
|
192
|
+
width: column.thickness,
|
|
193
|
+
height: cellLength
|
|
194
|
+
} : {
|
|
195
|
+
x: rowStart(r),
|
|
196
|
+
y: column.pos,
|
|
197
|
+
width: cellLength,
|
|
198
|
+
height: column.thickness
|
|
199
|
+
};
|
|
200
|
+
for (let r = rMin; r <= rMax; r++) track.push({
|
|
201
|
+
key: `${columnIndex}:${r}`,
|
|
202
|
+
...cellRect(r)
|
|
203
|
+
});
|
|
204
|
+
const usedRows = /* @__PURE__ */ new Set();
|
|
205
|
+
for (const bar of column.bars) {
|
|
206
|
+
const barLength = isVertical ? bar.height : bar.width;
|
|
207
|
+
if (barLength <= EDGE_TOLERANCE) continue;
|
|
208
|
+
const barStart = isVertical ? bar.y : bar.x;
|
|
209
|
+
const barEnd = barStart + barLength;
|
|
210
|
+
const rA = rowAt(barStart);
|
|
211
|
+
const rB = rowAt(barEnd);
|
|
212
|
+
const first = Math.max(Math.ceil(Math.min(rA, rB) - EDGE_TOLERANCE / step), rMin);
|
|
213
|
+
const last = Math.min(Math.floor(Math.max(rA, rB) + EDGE_TOLERANCE / step), rMax);
|
|
214
|
+
const rows = [];
|
|
215
|
+
for (let r = first; r <= last; r++) rows.push(r);
|
|
216
|
+
if (rows.length === 0) {
|
|
217
|
+
const r = Math.round(rowAt(barStart + barLength / 2));
|
|
218
|
+
if (r >= rMin && r <= rMax && !usedRows.has(r)) rows.push(r);
|
|
219
|
+
}
|
|
220
|
+
for (const r of rows) {
|
|
221
|
+
if (usedRows.has(r)) continue;
|
|
222
|
+
usedRows.add(r);
|
|
223
|
+
values.push({
|
|
224
|
+
key: `${bar.key}:${r}`,
|
|
225
|
+
...cellRect(r),
|
|
226
|
+
seriesKey: bar.seriesKey,
|
|
227
|
+
datumIndex: bar.datumIndex,
|
|
228
|
+
color: bar.color,
|
|
229
|
+
active: bar.active
|
|
230
|
+
});
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
});
|
|
234
|
+
return {
|
|
235
|
+
track,
|
|
236
|
+
values
|
|
237
|
+
};
|
|
238
|
+
}
|
|
239
|
+
function groupColumns(bars, isVertical) {
|
|
240
|
+
const map = /* @__PURE__ */ new Map();
|
|
241
|
+
for (const bar of bars) {
|
|
242
|
+
const pos = isVertical ? bar.x : bar.y;
|
|
243
|
+
const thickness = isVertical ? bar.width : bar.height;
|
|
244
|
+
if (thickness <= 0) continue;
|
|
245
|
+
const key = `${pos.toFixed(2)}:${thickness.toFixed(2)}`;
|
|
246
|
+
const existing = map.get(key);
|
|
247
|
+
if (existing) existing.bars.push(bar);
|
|
248
|
+
else map.set(key, {
|
|
249
|
+
pos,
|
|
250
|
+
thickness,
|
|
251
|
+
bars: [bar]
|
|
252
|
+
});
|
|
253
|
+
}
|
|
254
|
+
return [...map.values()];
|
|
255
|
+
}
|
|
256
|
+
const defaultBarValueFormatter = (value) => `${value}`;
|
|
257
|
+
var BarChart = class BarChart {
|
|
258
|
+
root = inject(ChartContext);
|
|
259
|
+
cart = inject(CartesianContext);
|
|
260
|
+
themeRadius = inject(ChartThemeRadius);
|
|
261
|
+
data = input.required(...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
|
|
262
|
+
xKey = input.required(...ngDevMode ? [{ debugName: "xKey" }] : /* istanbul ignore next */ []);
|
|
263
|
+
orientation = input("vertical", ...ngDevMode ? [{ debugName: "orientation" }] : /* istanbul ignore next */ []);
|
|
264
|
+
variant = input("grouped", ...ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []);
|
|
265
|
+
styleVariant = input(void 0, ...ngDevMode ? [{ debugName: "styleVariant" }] : /* istanbul ignore next */ []);
|
|
266
|
+
styles = input("base", ...ngDevMode ? [{ debugName: "styles" }] : /* istanbul ignore next */ []);
|
|
267
|
+
chartStyle = resolveChartStyle(this.styleVariant, this.styles);
|
|
268
|
+
themeSpace = inject(ChartThemeSpace);
|
|
269
|
+
margin = input(null, ...ngDevMode ? [{ debugName: "margin" }] : /* istanbul ignore next */ []);
|
|
270
|
+
plotMargin = resolveChartMargin(this.margin, DEFAULT_CARTESIAN_MARGIN_UNITS, this.themeSpace);
|
|
271
|
+
bandPadding = input(.2, ...ngDevMode ? [{ debugName: "bandPadding" }] : /* istanbul ignore next */ []);
|
|
272
|
+
groupPadding = input(.05, ...ngDevMode ? [{ debugName: "groupPadding" }] : /* istanbul ignore next */ []);
|
|
273
|
+
cornerRadius = input(null, ...ngDevMode ? [{ debugName: "cornerRadius" }] : /* istanbul ignore next */ []);
|
|
274
|
+
colorKey = input(void 0, ...ngDevMode ? [{ debugName: "colorKey" }] : /* istanbul ignore next */ []);
|
|
275
|
+
activeKey = input(void 0, ...ngDevMode ? [{ debugName: "activeKey" }] : /* istanbul ignore next */ []);
|
|
276
|
+
activeValue = input(void 0, ...ngDevMode ? [{ debugName: "activeValue" }] : /* istanbul ignore next */ []);
|
|
277
|
+
showValueLabels = input(false, ...ngDevMode ? [{ debugName: "showValueLabels" }] : /* istanbul ignore next */ []);
|
|
278
|
+
valueLabelFormat = input(defaultBarValueFormatter, ...ngDevMode ? [{ debugName: "valueLabelFormat" }] : /* istanbul ignore next */ []);
|
|
279
|
+
dotSize = input(void 0, ...ngDevMode ? [{ debugName: "dotSize" }] : /* istanbul ignore next */ []);
|
|
280
|
+
dotGap = input(2, ...ngDevMode ? [{ debugName: "dotGap" }] : /* istanbul ignore next */ []);
|
|
281
|
+
dotCornerRadius = input(null, ...ngDevMode ? [{ debugName: "dotCornerRadius" }] : /* istanbul ignore next */ []);
|
|
282
|
+
showDotTrack = input(true, ...ngDevMode ? [{ debugName: "showDotTrack" }] : /* istanbul ignore next */ []);
|
|
283
|
+
barClick = output();
|
|
284
|
+
cx = setupCartesianChart({
|
|
285
|
+
data: () => this.data(),
|
|
286
|
+
margin: () => this.plotMargin(),
|
|
287
|
+
cartesian: {
|
|
288
|
+
context: this.cart,
|
|
289
|
+
orientation: () => this.orientation()
|
|
290
|
+
},
|
|
291
|
+
publishLayout: () => {
|
|
292
|
+
const layout = this.layout();
|
|
293
|
+
this.cart.categoryScale.set(layout.categoryScale);
|
|
294
|
+
this.cart.valueScale.set(layout.valueScale);
|
|
295
|
+
this.cart.categories.set(layout.categories);
|
|
296
|
+
},
|
|
297
|
+
click: {
|
|
298
|
+
emit: (event) => this.barClick.emit(event),
|
|
299
|
+
payload: (bar, datumIndex, datum) => ({
|
|
300
|
+
seriesKey: bar.seriesKey,
|
|
301
|
+
datumIndex,
|
|
302
|
+
category: bar.category,
|
|
303
|
+
value: bar.value,
|
|
304
|
+
datum
|
|
305
|
+
})
|
|
306
|
+
},
|
|
307
|
+
ariaLabel: (bar, label) => `${label} in ${bar.category}: ${bar.value}`
|
|
308
|
+
});
|
|
309
|
+
resolvedCornerRadius = computed(() => this.cornerRadius() ?? this.themeRadius.px(), ...ngDevMode ? [{ debugName: "resolvedCornerRadius" }] : /* istanbul ignore next */ []);
|
|
310
|
+
resolvedDotCornerRadius = computed(() => this.dotCornerRadius() ?? Math.min(this.themeRadius.px() * .5, 4), ...ngDevMode ? [{ debugName: "resolvedDotCornerRadius" }] : /* istanbul ignore next */ []);
|
|
311
|
+
layout = computed(() => computeBarLayout({
|
|
312
|
+
data: this.data(),
|
|
313
|
+
xKey: this.xKey(),
|
|
314
|
+
seriesKeys: this.root.visibleSeriesKeys(),
|
|
315
|
+
variant: this.variant(),
|
|
316
|
+
orientation: this.orientation(),
|
|
317
|
+
innerWidth: this.cx.innerWidth(),
|
|
318
|
+
innerHeight: this.cx.innerHeight(),
|
|
319
|
+
bandPadding: this.bandPadding(),
|
|
320
|
+
groupPadding: this.groupPadding(),
|
|
321
|
+
colorKey: this.colorKey(),
|
|
322
|
+
activeKey: this.activeKey(),
|
|
323
|
+
activeValue: this.activeValue()
|
|
324
|
+
}), ...ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []);
|
|
325
|
+
bars = computed(() => this.layout().bars, ...ngDevMode ? [{ debugName: "bars" }] : /* istanbul ignore next */ []);
|
|
326
|
+
dotLayout = computed(() => {
|
|
327
|
+
if (this.chartStyle() !== "dot") return null;
|
|
328
|
+
const layout = this.layout();
|
|
329
|
+
return computeBarDotCells({
|
|
330
|
+
bars: layout.bars,
|
|
331
|
+
orientation: this.orientation(),
|
|
332
|
+
innerWidth: this.cx.innerWidth(),
|
|
333
|
+
innerHeight: this.cx.innerHeight(),
|
|
334
|
+
baseline: layout.valueScale(0),
|
|
335
|
+
dotSize: this.dotSize(),
|
|
336
|
+
dotGap: this.dotGap()
|
|
337
|
+
});
|
|
338
|
+
}, ...ngDevMode ? [{ debugName: "dotLayout" }] : /* istanbul ignore next */ []);
|
|
339
|
+
dotTrackCells = computed(() => this.showDotTrack() ? this.dotLayout()?.track ?? [] : [], ...ngDevMode ? [{ debugName: "dotTrackCells" }] : /* istanbul ignore next */ []);
|
|
340
|
+
dotValueCells = computed(() => this.dotLayout()?.values ?? [], ...ngDevMode ? [{ debugName: "dotValueCells" }] : /* istanbul ignore next */ []);
|
|
341
|
+
ariaSummary = computed(() => {
|
|
342
|
+
const keys = this.root.visibleSeriesKeys();
|
|
343
|
+
return `Bar chart, ${this.data().length} categories, ${keys.length} series: ${keys.join(", ")}.`;
|
|
344
|
+
}, ...ngDevMode ? [{ debugName: "ariaSummary" }] : /* istanbul ignore next */ []);
|
|
345
|
+
visibleSeriesKeys = computed(() => this.root.visibleSeriesKeys(), ...ngDevMode ? [{ debugName: "visibleSeriesKeys" }] : /* istanbul ignore next */ []);
|
|
346
|
+
dataColumns = computed(() => [this.xKey(), ...this.visibleSeriesKeys()], ...ngDevMode ? [{ debugName: "dataColumns" }] : /* istanbul ignore next */ []);
|
|
347
|
+
barOpacity(bar) {
|
|
348
|
+
return this.emphasisOpacity(bar.active);
|
|
349
|
+
}
|
|
350
|
+
dotCellOpacity(cell) {
|
|
351
|
+
return this.emphasisOpacity(cell.active);
|
|
352
|
+
}
|
|
353
|
+
barFill(bar) {
|
|
354
|
+
return this.chartStyle() === "dot" ? "transparent" : bar.color;
|
|
355
|
+
}
|
|
356
|
+
emphasisOpacity(active) {
|
|
357
|
+
return this.activeKey() && this.activeValue() !== void 0 ? active ? 1 : .42 : 1;
|
|
358
|
+
}
|
|
359
|
+
formatValueLabel(bar) {
|
|
360
|
+
return this.valueLabelFormat()(bar.value);
|
|
361
|
+
}
|
|
362
|
+
barLabelX(bar) {
|
|
363
|
+
if (this.orientation() === "vertical") return bar.x + bar.width / 2;
|
|
364
|
+
return bar.value >= 0 ? bar.x + bar.width + 6 : bar.x - 6;
|
|
365
|
+
}
|
|
366
|
+
barLabelY(bar) {
|
|
367
|
+
if (this.orientation() === "vertical") return bar.value >= 0 ? bar.y - 8 : bar.y + bar.height + 10;
|
|
368
|
+
return bar.y + bar.height / 2;
|
|
369
|
+
}
|
|
370
|
+
barLabelAnchor(bar) {
|
|
371
|
+
if (this.orientation() === "vertical") return "middle";
|
|
372
|
+
return bar.value >= 0 ? "start" : "end";
|
|
373
|
+
}
|
|
374
|
+
onKeydown(event, index) {
|
|
375
|
+
const key = event.key;
|
|
376
|
+
let targetIndex = -1;
|
|
377
|
+
if (key === "ArrowRight" || key === "ArrowDown") targetIndex = index + 1;
|
|
378
|
+
else if (key === "ArrowLeft" || key === "ArrowUp") targetIndex = index - 1;
|
|
379
|
+
if (targetIndex >= 0 && targetIndex < this.bars().length) {
|
|
380
|
+
event.preventDefault();
|
|
381
|
+
const parent = event.currentTarget.parentElement;
|
|
382
|
+
if (parent) {
|
|
383
|
+
const targetRect = parent.querySelectorAll(".chart-bar")[targetIndex];
|
|
384
|
+
if (targetRect) targetRect.focus();
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
}
|
|
388
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
389
|
+
minVersion: "12.0.0",
|
|
390
|
+
version: "22.2.3",
|
|
391
|
+
ngImport: i0,
|
|
392
|
+
type: BarChart,
|
|
393
|
+
deps: [],
|
|
394
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
395
|
+
});
|
|
396
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
397
|
+
minVersion: "17.0.0",
|
|
398
|
+
version: "22.2.3",
|
|
399
|
+
type: BarChart,
|
|
400
|
+
isStandalone: true,
|
|
401
|
+
selector: "ChartBar",
|
|
402
|
+
inputs: {
|
|
403
|
+
data: {
|
|
404
|
+
classPropertyName: "data",
|
|
405
|
+
publicName: "data",
|
|
406
|
+
isSignal: true,
|
|
407
|
+
isRequired: true,
|
|
408
|
+
transformFunction: null
|
|
409
|
+
},
|
|
410
|
+
xKey: {
|
|
411
|
+
classPropertyName: "xKey",
|
|
412
|
+
publicName: "xKey",
|
|
413
|
+
isSignal: true,
|
|
414
|
+
isRequired: true,
|
|
415
|
+
transformFunction: null
|
|
416
|
+
},
|
|
417
|
+
orientation: {
|
|
418
|
+
classPropertyName: "orientation",
|
|
419
|
+
publicName: "orientation",
|
|
420
|
+
isSignal: true,
|
|
421
|
+
isRequired: false,
|
|
422
|
+
transformFunction: null
|
|
423
|
+
},
|
|
424
|
+
variant: {
|
|
425
|
+
classPropertyName: "variant",
|
|
426
|
+
publicName: "variant",
|
|
427
|
+
isSignal: true,
|
|
428
|
+
isRequired: false,
|
|
429
|
+
transformFunction: null
|
|
430
|
+
},
|
|
431
|
+
styleVariant: {
|
|
432
|
+
classPropertyName: "styleVariant",
|
|
433
|
+
publicName: "styleVariant",
|
|
434
|
+
isSignal: true,
|
|
435
|
+
isRequired: false,
|
|
436
|
+
transformFunction: null
|
|
437
|
+
},
|
|
438
|
+
styles: {
|
|
439
|
+
classPropertyName: "styles",
|
|
440
|
+
publicName: "styles",
|
|
441
|
+
isSignal: true,
|
|
442
|
+
isRequired: false,
|
|
443
|
+
transformFunction: null
|
|
444
|
+
},
|
|
445
|
+
margin: {
|
|
446
|
+
classPropertyName: "margin",
|
|
447
|
+
publicName: "margin",
|
|
448
|
+
isSignal: true,
|
|
449
|
+
isRequired: false,
|
|
450
|
+
transformFunction: null
|
|
451
|
+
},
|
|
452
|
+
bandPadding: {
|
|
453
|
+
classPropertyName: "bandPadding",
|
|
454
|
+
publicName: "bandPadding",
|
|
455
|
+
isSignal: true,
|
|
456
|
+
isRequired: false,
|
|
457
|
+
transformFunction: null
|
|
458
|
+
},
|
|
459
|
+
groupPadding: {
|
|
460
|
+
classPropertyName: "groupPadding",
|
|
461
|
+
publicName: "groupPadding",
|
|
462
|
+
isSignal: true,
|
|
463
|
+
isRequired: false,
|
|
464
|
+
transformFunction: null
|
|
465
|
+
},
|
|
466
|
+
cornerRadius: {
|
|
467
|
+
classPropertyName: "cornerRadius",
|
|
468
|
+
publicName: "cornerRadius",
|
|
469
|
+
isSignal: true,
|
|
470
|
+
isRequired: false,
|
|
471
|
+
transformFunction: null
|
|
472
|
+
},
|
|
473
|
+
colorKey: {
|
|
474
|
+
classPropertyName: "colorKey",
|
|
475
|
+
publicName: "colorKey",
|
|
476
|
+
isSignal: true,
|
|
477
|
+
isRequired: false,
|
|
478
|
+
transformFunction: null
|
|
479
|
+
},
|
|
480
|
+
activeKey: {
|
|
481
|
+
classPropertyName: "activeKey",
|
|
482
|
+
publicName: "activeKey",
|
|
483
|
+
isSignal: true,
|
|
484
|
+
isRequired: false,
|
|
485
|
+
transformFunction: null
|
|
486
|
+
},
|
|
487
|
+
activeValue: {
|
|
488
|
+
classPropertyName: "activeValue",
|
|
489
|
+
publicName: "activeValue",
|
|
490
|
+
isSignal: true,
|
|
491
|
+
isRequired: false,
|
|
492
|
+
transformFunction: null
|
|
493
|
+
},
|
|
494
|
+
showValueLabels: {
|
|
495
|
+
classPropertyName: "showValueLabels",
|
|
496
|
+
publicName: "showValueLabels",
|
|
497
|
+
isSignal: true,
|
|
498
|
+
isRequired: false,
|
|
499
|
+
transformFunction: null
|
|
500
|
+
},
|
|
501
|
+
valueLabelFormat: {
|
|
502
|
+
classPropertyName: "valueLabelFormat",
|
|
503
|
+
publicName: "valueLabelFormat",
|
|
504
|
+
isSignal: true,
|
|
505
|
+
isRequired: false,
|
|
506
|
+
transformFunction: null
|
|
507
|
+
},
|
|
508
|
+
dotSize: {
|
|
509
|
+
classPropertyName: "dotSize",
|
|
510
|
+
publicName: "dotSize",
|
|
511
|
+
isSignal: true,
|
|
512
|
+
isRequired: false,
|
|
513
|
+
transformFunction: null
|
|
514
|
+
},
|
|
515
|
+
dotGap: {
|
|
516
|
+
classPropertyName: "dotGap",
|
|
517
|
+
publicName: "dotGap",
|
|
518
|
+
isSignal: true,
|
|
519
|
+
isRequired: false,
|
|
520
|
+
transformFunction: null
|
|
521
|
+
},
|
|
522
|
+
dotCornerRadius: {
|
|
523
|
+
classPropertyName: "dotCornerRadius",
|
|
524
|
+
publicName: "dotCornerRadius",
|
|
525
|
+
isSignal: true,
|
|
526
|
+
isRequired: false,
|
|
527
|
+
transformFunction: null
|
|
528
|
+
},
|
|
529
|
+
showDotTrack: {
|
|
530
|
+
classPropertyName: "showDotTrack",
|
|
531
|
+
publicName: "showDotTrack",
|
|
532
|
+
isSignal: true,
|
|
533
|
+
isRequired: false,
|
|
534
|
+
transformFunction: null
|
|
535
|
+
}
|
|
536
|
+
},
|
|
537
|
+
outputs: { barClick: "barClick" },
|
|
538
|
+
host: {
|
|
539
|
+
properties: { "attr.data-style": "chartStyle()" },
|
|
540
|
+
classAttribute: "relative block h-full w-full"
|
|
541
|
+
},
|
|
542
|
+
providers: [CartesianContext],
|
|
543
|
+
ngImport: i0,
|
|
544
|
+
template: `
|
|
545
|
+
<svg:svg
|
|
546
|
+
ChartPointerTracker
|
|
547
|
+
ChartRovingFocus
|
|
548
|
+
class="block h-full w-full overflow-visible"
|
|
549
|
+
[attr.viewBox]="cx.viewBox()"
|
|
550
|
+
preserveAspectRatio="none"
|
|
551
|
+
role="img"
|
|
552
|
+
[attr.aria-label]="ariaSummary()"
|
|
553
|
+
>
|
|
554
|
+
<svg:g [attr.transform]="cx.innerTransform()">
|
|
555
|
+
<ng-content select="svg\\:g[ChartGrid]" />
|
|
556
|
+
<svg:g class="chart-bars">
|
|
557
|
+
@if (chartStyle() === 'dot') {
|
|
558
|
+
<svg:g class="chart-bar-dots" aria-hidden="true">
|
|
559
|
+
@for (cell of dotTrackCells(); track cell.key) {
|
|
560
|
+
<svg:rect
|
|
561
|
+
class="chart-bar-dot-track"
|
|
562
|
+
[attr.x]="cell.x"
|
|
563
|
+
[attr.y]="cell.y"
|
|
564
|
+
[attr.width]="cell.width"
|
|
565
|
+
[attr.height]="cell.height"
|
|
566
|
+
[attr.rx]="resolvedDotCornerRadius()"
|
|
567
|
+
[attr.ry]="resolvedDotCornerRadius()"
|
|
568
|
+
fill="hsl(var(--muted))"
|
|
569
|
+
/>
|
|
570
|
+
}
|
|
571
|
+
@for (cell of dotValueCells(); track cell.key) {
|
|
572
|
+
<svg:rect
|
|
573
|
+
class="chart-bar-dot-value"
|
|
574
|
+
[attr.x]="cell.x"
|
|
575
|
+
[attr.y]="cell.y"
|
|
576
|
+
[attr.width]="cell.width"
|
|
577
|
+
[attr.height]="cell.height"
|
|
578
|
+
[attr.rx]="resolvedDotCornerRadius()"
|
|
579
|
+
[attr.ry]="resolvedDotCornerRadius()"
|
|
580
|
+
[attr.fill]="cell.color"
|
|
581
|
+
[attr.opacity]="dotCellOpacity(cell)"
|
|
582
|
+
/>
|
|
583
|
+
}
|
|
584
|
+
</svg:g>
|
|
585
|
+
}
|
|
586
|
+
@for (bar of bars(); track bar.key; let idx = $index) {
|
|
587
|
+
<svg:rect
|
|
588
|
+
ChartMarkFocus
|
|
589
|
+
class="chart-bar cursor-pointer transition-opacity hover:opacity-80"
|
|
590
|
+
[attr.x]="bar.x"
|
|
591
|
+
[attr.y]="bar.y"
|
|
592
|
+
[attr.width]="bar.width"
|
|
593
|
+
[attr.height]="bar.height"
|
|
594
|
+
[attr.rx]="resolvedCornerRadius()"
|
|
595
|
+
[attr.ry]="resolvedCornerRadius()"
|
|
596
|
+
[attr.fill]="barFill(bar)"
|
|
597
|
+
[attr.opacity]="barOpacity(bar)"
|
|
598
|
+
[attr.stroke]="bar.active ? 'hsl(var(--foreground))' : null"
|
|
599
|
+
[attr.stroke-width]="bar.active ? 1.5 : null"
|
|
600
|
+
[attr.aria-label]="cx.pointAriaLabel(bar)"
|
|
601
|
+
role="img"
|
|
602
|
+
tabindex="0"
|
|
603
|
+
(focus)="cx.setActivePoint($event, bar)"
|
|
604
|
+
(blur)="cx.clearActivePoint()"
|
|
605
|
+
(click)="cx.emitClick(bar)"
|
|
606
|
+
(keydown.enter)="cx.emitClick(bar)"
|
|
607
|
+
(keydown.space)="cx.emitClick(bar); $event.preventDefault()"
|
|
608
|
+
(keydown)="onKeydown($event, idx)"
|
|
609
|
+
/>
|
|
610
|
+
@if (showValueLabels() && bar.height > 0 && bar.width > 0) {
|
|
611
|
+
<svg:text
|
|
612
|
+
class="chart-bar-value pointer-events-none fill-muted-foreground text-2xs-plus"
|
|
613
|
+
[attr.x]="barLabelX(bar)"
|
|
614
|
+
[attr.y]="barLabelY(bar)"
|
|
615
|
+
[attr.text-anchor]="barLabelAnchor(bar)"
|
|
616
|
+
dominant-baseline="middle"
|
|
617
|
+
>
|
|
618
|
+
{{ formatValueLabel(bar) }}
|
|
619
|
+
</svg:text>
|
|
620
|
+
}
|
|
621
|
+
}
|
|
622
|
+
</svg:g>
|
|
623
|
+
<ng-content select="svg\\:g[ChartAxisX]" />
|
|
624
|
+
<ng-content select="svg\\:g[ChartAxisY]" />
|
|
625
|
+
<ng-content select="svg\\:g[ChartCrosshair]" />
|
|
626
|
+
<ng-content />
|
|
627
|
+
</svg:g>
|
|
628
|
+
</svg:svg>
|
|
629
|
+
<ng-content select="ChartTooltip" />
|
|
630
|
+
<ng-content select="ChartLegend" />
|
|
631
|
+
|
|
632
|
+
<ChartDataTable
|
|
633
|
+
[data]="data()"
|
|
634
|
+
[columns]="dataColumns()"
|
|
635
|
+
[rowHeaderKey]="xKey()"
|
|
636
|
+
[label]="ariaSummary()"
|
|
637
|
+
/>
|
|
638
|
+
`,
|
|
639
|
+
isInline: true,
|
|
640
|
+
dependencies: [
|
|
641
|
+
{
|
|
642
|
+
kind: "directive",
|
|
643
|
+
type: ChartPointerTracker,
|
|
644
|
+
selector: "svg:svg[ChartPointerTracker]"
|
|
645
|
+
},
|
|
646
|
+
{
|
|
647
|
+
kind: "directive",
|
|
648
|
+
type: ChartRovingFocus,
|
|
649
|
+
selector: "svg[ChartRovingFocus]"
|
|
650
|
+
},
|
|
651
|
+
{
|
|
652
|
+
kind: "directive",
|
|
653
|
+
type: ChartMarkFocus,
|
|
654
|
+
selector: "[ChartMarkFocus]"
|
|
655
|
+
},
|
|
656
|
+
{
|
|
657
|
+
kind: "component",
|
|
658
|
+
type: ChartDataTable,
|
|
659
|
+
selector: "ChartDataTable",
|
|
660
|
+
inputs: [
|
|
661
|
+
"data",
|
|
662
|
+
"columns",
|
|
663
|
+
"label",
|
|
664
|
+
"rowHeaderKey"
|
|
665
|
+
]
|
|
666
|
+
}
|
|
667
|
+
]
|
|
668
|
+
});
|
|
669
|
+
};
|
|
670
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
671
|
+
minVersion: "12.0.0",
|
|
672
|
+
version: "22.2.3",
|
|
673
|
+
ngImport: i0,
|
|
674
|
+
type: BarChart,
|
|
675
|
+
decorators: [{
|
|
676
|
+
type: Component,
|
|
677
|
+
args: [{
|
|
678
|
+
selector: "ChartBar",
|
|
679
|
+
providers: [CartesianContext],
|
|
680
|
+
imports: [
|
|
681
|
+
ChartPointerTracker,
|
|
682
|
+
ChartRovingFocus,
|
|
683
|
+
ChartMarkFocus,
|
|
684
|
+
ChartDataTable
|
|
685
|
+
],
|
|
686
|
+
host: {
|
|
687
|
+
class: "relative block h-full w-full",
|
|
688
|
+
"[attr.data-style]": "chartStyle()"
|
|
689
|
+
},
|
|
690
|
+
template: `
|
|
691
|
+
<svg:svg
|
|
692
|
+
ChartPointerTracker
|
|
693
|
+
ChartRovingFocus
|
|
694
|
+
class="block h-full w-full overflow-visible"
|
|
695
|
+
[attr.viewBox]="cx.viewBox()"
|
|
696
|
+
preserveAspectRatio="none"
|
|
697
|
+
role="img"
|
|
698
|
+
[attr.aria-label]="ariaSummary()"
|
|
699
|
+
>
|
|
700
|
+
<svg:g [attr.transform]="cx.innerTransform()">
|
|
701
|
+
<ng-content select="svg\\:g[ChartGrid]" />
|
|
702
|
+
<svg:g class="chart-bars">
|
|
703
|
+
@if (chartStyle() === 'dot') {
|
|
704
|
+
<svg:g class="chart-bar-dots" aria-hidden="true">
|
|
705
|
+
@for (cell of dotTrackCells(); track cell.key) {
|
|
706
|
+
<svg:rect
|
|
707
|
+
class="chart-bar-dot-track"
|
|
708
|
+
[attr.x]="cell.x"
|
|
709
|
+
[attr.y]="cell.y"
|
|
710
|
+
[attr.width]="cell.width"
|
|
711
|
+
[attr.height]="cell.height"
|
|
712
|
+
[attr.rx]="resolvedDotCornerRadius()"
|
|
713
|
+
[attr.ry]="resolvedDotCornerRadius()"
|
|
714
|
+
fill="hsl(var(--muted))"
|
|
715
|
+
/>
|
|
716
|
+
}
|
|
717
|
+
@for (cell of dotValueCells(); track cell.key) {
|
|
718
|
+
<svg:rect
|
|
719
|
+
class="chart-bar-dot-value"
|
|
720
|
+
[attr.x]="cell.x"
|
|
721
|
+
[attr.y]="cell.y"
|
|
722
|
+
[attr.width]="cell.width"
|
|
723
|
+
[attr.height]="cell.height"
|
|
724
|
+
[attr.rx]="resolvedDotCornerRadius()"
|
|
725
|
+
[attr.ry]="resolvedDotCornerRadius()"
|
|
726
|
+
[attr.fill]="cell.color"
|
|
727
|
+
[attr.opacity]="dotCellOpacity(cell)"
|
|
728
|
+
/>
|
|
729
|
+
}
|
|
730
|
+
</svg:g>
|
|
731
|
+
}
|
|
732
|
+
@for (bar of bars(); track bar.key; let idx = $index) {
|
|
733
|
+
<svg:rect
|
|
734
|
+
ChartMarkFocus
|
|
735
|
+
class="chart-bar cursor-pointer transition-opacity hover:opacity-80"
|
|
736
|
+
[attr.x]="bar.x"
|
|
737
|
+
[attr.y]="bar.y"
|
|
738
|
+
[attr.width]="bar.width"
|
|
739
|
+
[attr.height]="bar.height"
|
|
740
|
+
[attr.rx]="resolvedCornerRadius()"
|
|
741
|
+
[attr.ry]="resolvedCornerRadius()"
|
|
742
|
+
[attr.fill]="barFill(bar)"
|
|
743
|
+
[attr.opacity]="barOpacity(bar)"
|
|
744
|
+
[attr.stroke]="bar.active ? 'hsl(var(--foreground))' : null"
|
|
745
|
+
[attr.stroke-width]="bar.active ? 1.5 : null"
|
|
746
|
+
[attr.aria-label]="cx.pointAriaLabel(bar)"
|
|
747
|
+
role="img"
|
|
748
|
+
tabindex="0"
|
|
749
|
+
(focus)="cx.setActivePoint($event, bar)"
|
|
750
|
+
(blur)="cx.clearActivePoint()"
|
|
751
|
+
(click)="cx.emitClick(bar)"
|
|
752
|
+
(keydown.enter)="cx.emitClick(bar)"
|
|
753
|
+
(keydown.space)="cx.emitClick(bar); $event.preventDefault()"
|
|
754
|
+
(keydown)="onKeydown($event, idx)"
|
|
755
|
+
/>
|
|
756
|
+
@if (showValueLabels() && bar.height > 0 && bar.width > 0) {
|
|
757
|
+
<svg:text
|
|
758
|
+
class="chart-bar-value pointer-events-none fill-muted-foreground text-2xs-plus"
|
|
759
|
+
[attr.x]="barLabelX(bar)"
|
|
760
|
+
[attr.y]="barLabelY(bar)"
|
|
761
|
+
[attr.text-anchor]="barLabelAnchor(bar)"
|
|
762
|
+
dominant-baseline="middle"
|
|
763
|
+
>
|
|
764
|
+
{{ formatValueLabel(bar) }}
|
|
765
|
+
</svg:text>
|
|
766
|
+
}
|
|
767
|
+
}
|
|
768
|
+
</svg:g>
|
|
769
|
+
<ng-content select="svg\\:g[ChartAxisX]" />
|
|
770
|
+
<ng-content select="svg\\:g[ChartAxisY]" />
|
|
771
|
+
<ng-content select="svg\\:g[ChartCrosshair]" />
|
|
772
|
+
<ng-content />
|
|
773
|
+
</svg:g>
|
|
774
|
+
</svg:svg>
|
|
775
|
+
<ng-content select="ChartTooltip" />
|
|
776
|
+
<ng-content select="ChartLegend" />
|
|
777
|
+
|
|
778
|
+
<ChartDataTable
|
|
779
|
+
[data]="data()"
|
|
780
|
+
[columns]="dataColumns()"
|
|
781
|
+
[rowHeaderKey]="xKey()"
|
|
782
|
+
[label]="ariaSummary()"
|
|
783
|
+
/>
|
|
784
|
+
`
|
|
785
|
+
}]
|
|
786
|
+
}],
|
|
787
|
+
propDecorators: {
|
|
788
|
+
data: [{
|
|
789
|
+
type: i0.Input,
|
|
790
|
+
args: [{
|
|
791
|
+
isSignal: true,
|
|
792
|
+
alias: "data",
|
|
793
|
+
required: true
|
|
794
|
+
}]
|
|
795
|
+
}],
|
|
796
|
+
xKey: [{
|
|
797
|
+
type: i0.Input,
|
|
798
|
+
args: [{
|
|
799
|
+
isSignal: true,
|
|
800
|
+
alias: "xKey",
|
|
801
|
+
required: true
|
|
802
|
+
}]
|
|
803
|
+
}],
|
|
804
|
+
orientation: [{
|
|
805
|
+
type: i0.Input,
|
|
806
|
+
args: [{
|
|
807
|
+
isSignal: true,
|
|
808
|
+
alias: "orientation",
|
|
809
|
+
required: false
|
|
810
|
+
}]
|
|
811
|
+
}],
|
|
812
|
+
variant: [{
|
|
813
|
+
type: i0.Input,
|
|
814
|
+
args: [{
|
|
815
|
+
isSignal: true,
|
|
816
|
+
alias: "variant",
|
|
817
|
+
required: false
|
|
818
|
+
}]
|
|
819
|
+
}],
|
|
820
|
+
styleVariant: [{
|
|
821
|
+
type: i0.Input,
|
|
822
|
+
args: [{
|
|
823
|
+
isSignal: true,
|
|
824
|
+
alias: "styleVariant",
|
|
825
|
+
required: false
|
|
826
|
+
}]
|
|
827
|
+
}],
|
|
828
|
+
styles: [{
|
|
829
|
+
type: i0.Input,
|
|
830
|
+
args: [{
|
|
831
|
+
isSignal: true,
|
|
832
|
+
alias: "styles",
|
|
833
|
+
required: false
|
|
834
|
+
}]
|
|
835
|
+
}],
|
|
836
|
+
margin: [{
|
|
837
|
+
type: i0.Input,
|
|
838
|
+
args: [{
|
|
839
|
+
isSignal: true,
|
|
840
|
+
alias: "margin",
|
|
841
|
+
required: false
|
|
842
|
+
}]
|
|
843
|
+
}],
|
|
844
|
+
bandPadding: [{
|
|
845
|
+
type: i0.Input,
|
|
846
|
+
args: [{
|
|
847
|
+
isSignal: true,
|
|
848
|
+
alias: "bandPadding",
|
|
849
|
+
required: false
|
|
850
|
+
}]
|
|
851
|
+
}],
|
|
852
|
+
groupPadding: [{
|
|
853
|
+
type: i0.Input,
|
|
854
|
+
args: [{
|
|
855
|
+
isSignal: true,
|
|
856
|
+
alias: "groupPadding",
|
|
857
|
+
required: false
|
|
858
|
+
}]
|
|
859
|
+
}],
|
|
860
|
+
cornerRadius: [{
|
|
861
|
+
type: i0.Input,
|
|
862
|
+
args: [{
|
|
863
|
+
isSignal: true,
|
|
864
|
+
alias: "cornerRadius",
|
|
865
|
+
required: false
|
|
866
|
+
}]
|
|
867
|
+
}],
|
|
868
|
+
colorKey: [{
|
|
869
|
+
type: i0.Input,
|
|
870
|
+
args: [{
|
|
871
|
+
isSignal: true,
|
|
872
|
+
alias: "colorKey",
|
|
873
|
+
required: false
|
|
874
|
+
}]
|
|
875
|
+
}],
|
|
876
|
+
activeKey: [{
|
|
877
|
+
type: i0.Input,
|
|
878
|
+
args: [{
|
|
879
|
+
isSignal: true,
|
|
880
|
+
alias: "activeKey",
|
|
881
|
+
required: false
|
|
882
|
+
}]
|
|
883
|
+
}],
|
|
884
|
+
activeValue: [{
|
|
885
|
+
type: i0.Input,
|
|
886
|
+
args: [{
|
|
887
|
+
isSignal: true,
|
|
888
|
+
alias: "activeValue",
|
|
889
|
+
required: false
|
|
890
|
+
}]
|
|
891
|
+
}],
|
|
892
|
+
showValueLabels: [{
|
|
893
|
+
type: i0.Input,
|
|
894
|
+
args: [{
|
|
895
|
+
isSignal: true,
|
|
896
|
+
alias: "showValueLabels",
|
|
897
|
+
required: false
|
|
898
|
+
}]
|
|
899
|
+
}],
|
|
900
|
+
valueLabelFormat: [{
|
|
901
|
+
type: i0.Input,
|
|
902
|
+
args: [{
|
|
903
|
+
isSignal: true,
|
|
904
|
+
alias: "valueLabelFormat",
|
|
905
|
+
required: false
|
|
906
|
+
}]
|
|
907
|
+
}],
|
|
908
|
+
dotSize: [{
|
|
909
|
+
type: i0.Input,
|
|
910
|
+
args: [{
|
|
911
|
+
isSignal: true,
|
|
912
|
+
alias: "dotSize",
|
|
913
|
+
required: false
|
|
914
|
+
}]
|
|
915
|
+
}],
|
|
916
|
+
dotGap: [{
|
|
917
|
+
type: i0.Input,
|
|
918
|
+
args: [{
|
|
919
|
+
isSignal: true,
|
|
920
|
+
alias: "dotGap",
|
|
921
|
+
required: false
|
|
922
|
+
}]
|
|
923
|
+
}],
|
|
924
|
+
dotCornerRadius: [{
|
|
925
|
+
type: i0.Input,
|
|
926
|
+
args: [{
|
|
927
|
+
isSignal: true,
|
|
928
|
+
alias: "dotCornerRadius",
|
|
929
|
+
required: false
|
|
930
|
+
}]
|
|
931
|
+
}],
|
|
932
|
+
showDotTrack: [{
|
|
933
|
+
type: i0.Input,
|
|
934
|
+
args: [{
|
|
935
|
+
isSignal: true,
|
|
936
|
+
alias: "showDotTrack",
|
|
937
|
+
required: false
|
|
938
|
+
}]
|
|
939
|
+
}],
|
|
940
|
+
barClick: [{
|
|
941
|
+
type: i0.Output,
|
|
942
|
+
args: ["barClick"]
|
|
943
|
+
}]
|
|
944
|
+
}
|
|
945
|
+
});
|
|
946
|
+
export { BarChart, computeBarDotCells, computeBarLayout };
|