@ngstarter-ui/components 22.3.6 → 22.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +27 -0
- package/ai/component-registry.json +186 -101
- package/fesm2022/attachment-block-BK9QxVjq.mjs +163 -0
- package/fesm2022/attachment-block-BK9QxVjq.mjs.map +1 -0
- package/fesm2022/callout-block-Bl4GZYz8.mjs +196 -0
- package/fesm2022/callout-block-Bl4GZYz8.mjs.map +1 -0
- package/fesm2022/code-block.component-DCRD-9iP.mjs +393 -0
- package/fesm2022/code-block.component-DCRD-9iP.mjs.map +1 -0
- package/fesm2022/content-builder.store-D622mHxt.mjs +328 -0
- package/fesm2022/content-builder.store-D622mHxt.mjs.map +1 -0
- package/fesm2022/content-editor-content-editable.directive-WzD9_71s.mjs +1110 -0
- package/fesm2022/content-editor-content-editable.directive-WzD9_71s.mjs.map +1 -0
- package/fesm2022/cursor-controller-DKfBII1n.mjs +55 -0
- package/fesm2022/cursor-controller-DKfBII1n.mjs.map +1 -0
- package/fesm2022/default-converters-9oSKDsXP.mjs +140 -0
- package/fesm2022/default-converters-9oSKDsXP.mjs.map +1 -0
- package/fesm2022/divider-block.component-Dvgeq_D0.mjs +148 -0
- package/fesm2022/divider-block.component-Dvgeq_D0.mjs.map +1 -0
- package/fesm2022/embed-block-CYkOv4Wt.mjs +565 -0
- package/fesm2022/embed-block-CYkOv4Wt.mjs.map +1 -0
- package/fesm2022/extra-block-defs-Cn_hfM3c.mjs +122 -0
- package/fesm2022/extra-block-defs-Cn_hfM3c.mjs.map +1 -0
- package/fesm2022/gallery-block-DT3uIURY.mjs +365 -0
- package/fesm2022/gallery-block-DT3uIURY.mjs.map +1 -0
- package/fesm2022/grid-block-ZVDT3m8-.mjs +504 -0
- package/fesm2022/grid-block-ZVDT3m8-.mjs.map +1 -0
- package/fesm2022/heading-block.component-iCpJGTMh.mjs +274 -0
- package/fesm2022/heading-block.component-iCpJGTMh.mjs.map +1 -0
- package/fesm2022/html-utils-DywL8gGa.mjs +24 -0
- package/fesm2022/html-utils-DywL8gGa.mjs.map +1 -0
- package/fesm2022/image-block.component-DJ7-HCR8.mjs +285 -0
- package/fesm2022/image-block.component-DJ7-HCR8.mjs.map +1 -0
- package/fesm2022/list-block.component-qFIebEBO.mjs +312 -0
- package/fesm2022/list-block.component-qFIebEBO.mjs.map +1 -0
- package/fesm2022/nested-blocks-CXhgXJ1H.mjs +345 -0
- package/fesm2022/nested-blocks-CXhgXJ1H.mjs.map +1 -0
- package/fesm2022/ngstarter-ui-components-action-required.mjs +150 -45
- package/fesm2022/ngstarter-ui-components-action-required.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-alert.mjs +318 -133
- package/fesm2022/ngstarter-ui-components-alert.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-announcement.mjs +280 -88
- package/fesm2022/ngstarter-ui-components-announcement.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-autocomplete.mjs +647 -386
- package/fesm2022/ngstarter-ui-components-autocomplete.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-avatar.mjs +715 -482
- package/fesm2022/ngstarter-ui-components-avatar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-badge.mjs +308 -97
- package/fesm2022/ngstarter-ui-components-badge.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-block-loader.mjs +164 -47
- package/fesm2022/ngstarter-ui-components-block-loader.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-bottom-sheet.mjs +278 -315
- package/fesm2022/ngstarter-ui-components-bottom-sheet.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-breadcrumbs.mjs +707 -205
- package/fesm2022/ngstarter-ui-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-button-toggle.mjs +518 -175
- package/fesm2022/ngstarter-ui-components-button-toggle.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-button.mjs +294 -68
- package/fesm2022/ngstarter-ui-components-button.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-calendar.mjs +442 -250
- package/fesm2022/ngstarter-ui-components-calendar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-card-overlay.mjs +159 -47
- package/fesm2022/ngstarter-ui-components-card-overlay.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-card.mjs +619 -194
- package/fesm2022/ngstarter-ui-components-card.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-carousel.mjs +1012 -634
- package/fesm2022/ngstarter-ui-components-carousel.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-checkbox.mjs +715 -308
- package/fesm2022/ngstarter-ui-components-checkbox.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-chips.mjs +1397 -667
- package/fesm2022/ngstarter-ui-components-chips.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-code-highlighter.mjs +519 -357
- package/fesm2022/ngstarter-ui-components-code-highlighter.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-color-picker.mjs +1218 -604
- package/fesm2022/ngstarter-ui-components-color-picker.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-color-scheme.mjs +265 -134
- package/fesm2022/ngstarter-ui-components-color-scheme.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-color-switcher.mjs +190 -71
- package/fesm2022/ngstarter-ui-components-color-switcher.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-command-bar.mjs +197 -58
- package/fesm2022/ngstarter-ui-components-command-bar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-comment-editor.mjs +2212 -1128
- package/fesm2022/ngstarter-ui-components-comment-editor.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-comparison-slider.mjs +269 -183
- package/fesm2022/ngstarter-ui-components-comparison-slider.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-confirm.mjs +164 -86
- package/fesm2022/ngstarter-ui-components-confirm.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-content-editor.mjs +6240 -2
- package/fesm2022/ngstarter-ui-components-content-editor.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-cookie-popup.mjs +244 -108
- package/fesm2022/ngstarter-ui-components-cookie-popup.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-core.mjs +2110 -1592
- package/fesm2022/ngstarter-ui-components-core.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-country-select.mjs +1970 -588
- package/fesm2022/ngstarter-ui-components-country-select.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-crop.mjs +249 -191
- package/fesm2022/ngstarter-ui-components-crop.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-currency-select.mjs +1658 -452
- package/fesm2022/ngstarter-ui-components-currency-select.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-data-view.mjs +4538 -2497
- package/fesm2022/ngstarter-ui-components-data-view.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-date-format-select.mjs +357 -157
- package/fesm2022/ngstarter-ui-components-date-format-select.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-datepicker.mjs +2587 -1264
- package/fesm2022/ngstarter-ui-components-datepicker.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-dialog.mjs +681 -385
- package/fesm2022/ngstarter-ui-components-dialog.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-digit-roller.mjs +1000 -750
- package/fesm2022/ngstarter-ui-components-digit-roller.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-divider.mjs +164 -41
- package/fesm2022/ngstarter-ui-components-divider.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-drawer.mjs +218 -143
- package/fesm2022/ngstarter-ui-components-drawer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-emoji-picker.mjs +345 -247
- package/fesm2022/ngstarter-ui-components-emoji-picker.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-empty-state.mjs +244 -74
- package/fesm2022/ngstarter-ui-components-empty-state.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-events.mjs +467 -126
- package/fesm2022/ngstarter-ui-components-events.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-expand.mjs +191 -59
- package/fesm2022/ngstarter-ui-components-expand.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-expansion.mjs +529 -193
- package/fesm2022/ngstarter-ui-components-expansion.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-file-type.mjs +270 -171
- package/fesm2022/ngstarter-ui-components-file-type.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-filter-builder.mjs +741 -352
- package/fesm2022/ngstarter-ui-components-filter-builder.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-form-builder.mjs +9032 -6964
- package/fesm2022/ngstarter-ui-components-form-builder.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-form-field.mjs +741 -276
- package/fesm2022/ngstarter-ui-components-form-field.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-gauge.mjs +155 -43
- package/fesm2022/ngstarter-ui-components-gauge.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-grid.mjs +197 -81
- package/fesm2022/ngstarter-ui-components-grid.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-guided-tour.mjs +881 -740
- package/fesm2022/ngstarter-ui-components-guided-tour.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-headless-editor.mjs +3573 -3656
- package/fesm2022/ngstarter-ui-components-headless-editor.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-headless-stepper.mjs +277 -204
- package/fesm2022/ngstarter-ui-components-headless-stepper.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-icon.mjs +209 -182
- package/fesm2022/ngstarter-ui-components-icon.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-image-designer.mjs +5096 -4066
- package/fesm2022/ngstarter-ui-components-image-designer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-image-placeholder.mjs +45 -19
- package/fesm2022/ngstarter-ui-components-image-placeholder.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-image-resizer.mjs +333 -154
- package/fesm2022/ngstarter-ui-components-image-resizer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-image-viewer.mjs +564 -358
- package/fesm2022/ngstarter-ui-components-image-viewer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-image-zoom-viewer.mjs +246 -167
- package/fesm2022/ngstarter-ui-components-image-zoom-viewer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-incidents.mjs +732 -258
- package/fesm2022/ngstarter-ui-components-incidents.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-inline-text-edit.mjs +244 -182
- package/fesm2022/ngstarter-ui-components-inline-text-edit.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-input-mask.mjs +314 -174
- package/fesm2022/ngstarter-ui-components-input-mask.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-input-validator.mjs +45 -69
- package/fesm2022/ngstarter-ui-components-input-validator.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-input.mjs +303 -161
- package/fesm2022/ngstarter-ui-components-input.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-kanban-board.mjs +504 -159
- package/fesm2022/ngstarter-ui-components-kanban-board.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-kbd.mjs +86 -30
- package/fesm2022/ngstarter-ui-components-kbd.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-layout.mjs +681 -220
- package/fesm2022/ngstarter-ui-components-layout.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-list.mjs +968 -281
- package/fesm2022/ngstarter-ui-components-list.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-logo.mjs +181 -51
- package/fesm2022/ngstarter-ui-components-logo.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-marquee.mjs +226 -147
- package/fesm2022/ngstarter-ui-components-marquee.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-menu.mjs +1686 -1091
- package/fesm2022/ngstarter-ui-components-menu.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-micro-chart.mjs +1541 -943
- package/fesm2022/ngstarter-ui-components-micro-chart.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-navigation.mjs +1035 -455
- package/fesm2022/ngstarter-ui-components-navigation.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-notifications.mjs +678 -230
- package/fesm2022/ngstarter-ui-components-notifications.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-number-input.mjs +616 -316
- package/fesm2022/ngstarter-ui-components-number-input.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-option.mjs +405 -163
- package/fesm2022/ngstarter-ui-components-option.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-overlay.mjs +107 -111
- package/fesm2022/ngstarter-ui-components-overlay.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-page-loading-bar.mjs +131 -76
- package/fesm2022/ngstarter-ui-components-page-loading-bar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-paginator.mjs +543 -295
- package/fesm2022/ngstarter-ui-components-paginator.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-password-strength.mjs +785 -340
- package/fesm2022/ngstarter-ui-components-password-strength.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-pdf-builder.mjs +3705 -2695
- package/fesm2022/ngstarter-ui-components-pdf-builder.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-pdf-signer.mjs +1179 -851
- package/fesm2022/ngstarter-ui-components-pdf-signer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-pdf-viewer.mjs +2973 -2070
- package/fesm2022/ngstarter-ui-components-pdf-viewer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-phone-input.mjs +2081 -770
- package/fesm2022/ngstarter-ui-components-phone-input.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-pin-input.mjs +366 -198
- package/fesm2022/ngstarter-ui-components-pin-input.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-popover.mjs +558 -308
- package/fesm2022/ngstarter-ui-components-popover.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-progress-bar.mjs +178 -73
- package/fesm2022/ngstarter-ui-components-progress-bar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-radio-card.mjs +301 -105
- package/fesm2022/ngstarter-ui-components-radio-card.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-radio.mjs +417 -157
- package/fesm2022/ngstarter-ui-components-radio.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-rail-nav.mjs +208 -88
- package/fesm2022/ngstarter-ui-components-rail-nav.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-resizable-container.mjs +123 -74
- package/fesm2022/ngstarter-ui-components-resizable-container.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-screen-loader.mjs +197 -95
- package/fesm2022/ngstarter-ui-components-screen-loader.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-scroll-spy.mjs +383 -245
- package/fesm2022/ngstarter-ui-components-scroll-spy.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-scrollbar-area.mjs +705 -581
- package/fesm2022/ngstarter-ui-components-scrollbar-area.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-segmented.mjs +422 -220
- package/fesm2022/ngstarter-ui-components-segmented.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-select.mjs +1862 -1159
- package/fesm2022/ngstarter-ui-components-select.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-side-panel.mjs +313 -118
- package/fesm2022/ngstarter-ui-components-side-panel.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-sidebar.mjs +1239 -470
- package/fesm2022/ngstarter-ui-components-sidebar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-sidenav.mjs +664 -354
- package/fesm2022/ngstarter-ui-components-sidenav.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-signature-pad.mjs +1092 -643
- package/fesm2022/ngstarter-ui-components-signature-pad.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-skeleton.mjs +153 -43
- package/fesm2022/ngstarter-ui-components-skeleton.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-slide-toggle.mjs +425 -108
- package/fesm2022/ngstarter-ui-components-slide-toggle.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-slider.mjs +645 -487
- package/fesm2022/ngstarter-ui-components-slider.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-snack-bar.mjs +372 -354
- package/fesm2022/ngstarter-ui-components-snack-bar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-sort.mjs +378 -147
- package/fesm2022/ngstarter-ui-components-sort.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-spinner.mjs +242 -76
- package/fesm2022/ngstarter-ui-components-spinner.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-splash-screen.mjs +142 -91
- package/fesm2022/ngstarter-ui-components-splash-screen.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-split.mjs +1067 -929
- package/fesm2022/ngstarter-ui-components-split.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-step-tracker.mjs +617 -331
- package/fesm2022/ngstarter-ui-components-step-tracker.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-stepper.mjs +357 -126
- package/fesm2022/ngstarter-ui-components-stepper.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-suggestions.mjs +259 -72
- package/fesm2022/ngstarter-ui-components-suggestions.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-tab-panel.mjs +674 -267
- package/fesm2022/ngstarter-ui-components-tab-panel.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-table.mjs +1144 -662
- package/fesm2022/ngstarter-ui-components-table.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-tabs.mjs +1236 -615
- package/fesm2022/ngstarter-ui-components-tabs.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-thumbnail-maker.mjs +414 -216
- package/fesm2022/ngstarter-ui-components-thumbnail-maker.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-tiles.mjs +939 -647
- package/fesm2022/ngstarter-ui-components-tiles.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-timeline.mjs +418 -122
- package/fesm2022/ngstarter-ui-components-timeline.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-timepicker.mjs +870 -508
- package/fesm2022/ngstarter-ui-components-timepicker.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-timezone-select.mjs +651 -371
- package/fesm2022/ngstarter-ui-components-timezone-select.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-toolbar.mjs +727 -320
- package/fesm2022/ngstarter-ui-components-toolbar.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-tooltip.mjs +601 -521
- package/fesm2022/ngstarter-ui-components-tooltip.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-tree-select.mjs +1197 -434
- package/fesm2022/ngstarter-ui-components-tree-select.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-tree.mjs +1821 -1262
- package/fesm2022/ngstarter-ui-components-tree.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-upload.mjs +1059 -345
- package/fesm2022/ngstarter-ui-components-upload.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-video-player.mjs +763 -533
- package/fesm2022/ngstarter-ui-components-video-player.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-video-viewer.mjs +630 -229
- package/fesm2022/ngstarter-ui-components-video-viewer.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-visual-builder.mjs +40 -17
- package/fesm2022/ngstarter-ui-components-visual-builder.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components-whiteboard.mjs +3039 -1803
- package/fesm2022/ngstarter-ui-components-whiteboard.mjs.map +1 -1
- package/fesm2022/ngstarter-ui-components.mjs +3 -5
- package/fesm2022/ngstarter-ui-components.mjs.map +1 -1
- package/fesm2022/paragraph-block.component-Csk8Gu3x.mjs +264 -0
- package/fesm2022/paragraph-block.component-Csk8Gu3x.mjs.map +1 -0
- package/fesm2022/plain-text-settings-BnxCxLhA.mjs +354 -0
- package/fesm2022/plain-text-settings-BnxCxLhA.mjs.map +1 -0
- package/fesm2022/quote-block.component-tRmrU97F.mjs +309 -0
- package/fesm2022/quote-block.component-tRmrU97F.mjs.map +1 -0
- package/fesm2022/table-block.component-BuzRRggv.mjs +1859 -0
- package/fesm2022/table-block.component-BuzRRggv.mjs.map +1 -0
- package/fesm2022/toggle-block-C5Jo2YDf.mjs +150 -0
- package/fesm2022/toggle-block-C5Jo2YDf.mjs.map +1 -0
- package/fesm2022/upload-status-tZ0x0BUB.mjs +107 -0
- package/fesm2022/upload-status-tZ0x0BUB.mjs.map +1 -0
- package/fesm2022/video-block.component-CpAXibm6.mjs +312 -0
- package/fesm2022/video-block.component-CpAXibm6.mjs.map +1 -0
- package/package.json +11 -10
- package/styles/_tokens.scss +1 -0
- package/types/ngstarter-ui-components-action-required.d.ts +34 -14
- package/types/ngstarter-ui-components-alert.d.ts +53 -44
- package/types/ngstarter-ui-components-announcement.d.ts +74 -53
- package/types/ngstarter-ui-components-autocomplete.d.ts +141 -84
- package/types/ngstarter-ui-components-avatar.d.ts +113 -66
- package/types/ngstarter-ui-components-badge.d.ts +73 -37
- package/types/ngstarter-ui-components-block-loader.d.ts +32 -20
- package/types/ngstarter-ui-components-bottom-sheet.d.ts +125 -132
- package/types/ngstarter-ui-components-breadcrumbs.d.ts +93 -88
- package/types/ngstarter-ui-components-button-toggle.d.ts +124 -54
- package/types/ngstarter-ui-components-button.d.ts +69 -27
- package/types/ngstarter-ui-components-calendar.d.ts +123 -71
- package/types/ngstarter-ui-components-card-overlay.d.ts +31 -19
- package/types/ngstarter-ui-components-card.d.ts +75 -71
- package/types/ngstarter-ui-components-carousel.d.ts +115 -69
- package/types/ngstarter-ui-components-checkbox.d.ts +183 -86
- package/types/ngstarter-ui-components-chips.d.ts +288 -195
- package/types/ngstarter-ui-components-code-highlighter.d.ts +71 -28
- package/types/ngstarter-ui-components-color-picker.d.ts +140 -89
- package/types/ngstarter-ui-components-color-scheme.d.ts +43 -52
- package/types/ngstarter-ui-components-color-switcher.d.ts +46 -26
- package/types/ngstarter-ui-components-command-bar.d.ts +40 -26
- package/types/ngstarter-ui-components-comment-editor.d.ts +311 -235
- package/types/ngstarter-ui-components-comparison-slider.d.ts +41 -40
- package/types/ngstarter-ui-components-confirm.d.ts +24 -29
- package/types/ngstarter-ui-components-content-editor.d.ts +1482 -998
- package/types/ngstarter-ui-components-cookie-popup.d.ts +43 -38
- package/types/ngstarter-ui-components-core.d.ts +513 -467
- package/types/ngstarter-ui-components-country-select.d.ts +170 -97
- package/types/ngstarter-ui-components-crop.d.ts +67 -52
- package/types/ngstarter-ui-components-currency-select.d.ts +127 -90
- package/types/ngstarter-ui-components-data-view.d.ts +811 -567
- package/types/ngstarter-ui-components-date-format-select.d.ts +90 -58
- package/types/ngstarter-ui-components-datepicker.d.ts +589 -373
- package/types/ngstarter-ui-components-dialog.d.ts +138 -116
- package/types/ngstarter-ui-components-digit-roller.d.ts +228 -131
- package/types/ngstarter-ui-components-divider.d.ts +29 -17
- package/types/ngstarter-ui-components-drawer.d.ts +39 -30
- package/types/ngstarter-ui-components-emoji-picker.d.ts +69 -47
- package/types/ngstarter-ui-components-empty-state.d.ts +20 -28
- package/types/ngstarter-ui-components-events.d.ts +73 -57
- package/types/ngstarter-ui-components-expand.d.ts +55 -25
- package/types/ngstarter-ui-components-expansion.d.ts +93 -64
- package/types/ngstarter-ui-components-file-type.d.ts +53 -27
- package/types/ngstarter-ui-components-filter-builder.d.ts +131 -100
- package/types/ngstarter-ui-components-form-builder.d.ts +1094 -881
- package/types/ngstarter-ui-components-form-field.d.ts +116 -105
- package/types/ngstarter-ui-components-gauge.d.ts +32 -20
- package/types/ngstarter-ui-components-grid.d.ts +66 -50
- package/types/ngstarter-ui-components-guided-tour.d.ts +250 -222
- package/types/ngstarter-ui-components-headless-editor.d.ts +708 -658
- package/types/ngstarter-ui-components-headless-stepper.d.ts +84 -64
- package/types/ngstarter-ui-components-icon.d.ts +39 -38
- package/types/ngstarter-ui-components-image-designer.d.ts +422 -341
- package/types/ngstarter-ui-components-image-placeholder.d.ts +5 -8
- package/types/ngstarter-ui-components-image-resizer.d.ts +40 -33
- package/types/ngstarter-ui-components-image-viewer.d.ts +67 -54
- package/types/ngstarter-ui-components-image-zoom-viewer.d.ts +29 -33
- package/types/ngstarter-ui-components-incidents.d.ts +97 -104
- package/types/ngstarter-ui-components-inline-text-edit.d.ts +54 -39
- package/types/ngstarter-ui-components-input-mask.d.ts +54 -34
- package/types/ngstarter-ui-components-input-validator.d.ts +7 -11
- package/types/ngstarter-ui-components-input.d.ts +82 -54
- package/types/ngstarter-ui-components-kanban-board.d.ts +76 -63
- package/types/ngstarter-ui-components-kbd.d.ts +8 -12
- package/types/ngstarter-ui-components-layout.d.ts +131 -87
- package/types/ngstarter-ui-components-list.d.ts +123 -88
- package/types/ngstarter-ui-components-logo.d.ts +21 -21
- package/types/ngstarter-ui-components-marquee.d.ts +41 -34
- package/types/ngstarter-ui-components-menu.d.ts +329 -221
- package/types/ngstarter-ui-components-micro-chart.d.ts +385 -186
- package/types/ngstarter-ui-components-navigation.d.ts +186 -125
- package/types/ngstarter-ui-components-notifications.d.ts +104 -89
- package/types/ngstarter-ui-components-number-input.d.ts +138 -96
- package/types/ngstarter-ui-components-option.d.ts +102 -68
- package/types/ngstarter-ui-components-overlay.d.ts +7 -12
- package/types/ngstarter-ui-components-page-loading-bar.d.ts +23 -20
- package/types/ngstarter-ui-components-paginator.d.ts +171 -129
- package/types/ngstarter-ui-components-password-strength.d.ts +217 -102
- package/types/ngstarter-ui-components-pdf-builder.d.ts +717 -649
- package/types/ngstarter-ui-components-pdf-signer.d.ts +202 -142
- package/types/ngstarter-ui-components-pdf-viewer.d.ts +544 -385
- package/types/ngstarter-ui-components-phone-input.d.ts +175 -115
- package/types/ngstarter-ui-components-pin-input.d.ts +83 -45
- package/types/ngstarter-ui-components-popover.d.ts +128 -89
- package/types/ngstarter-ui-components-progress-bar.d.ts +49 -30
- package/types/ngstarter-ui-components-radio-card.d.ts +50 -34
- package/types/ngstarter-ui-components-radio.d.ts +100 -47
- package/types/ngstarter-ui-components-rail-nav.d.ts +36 -29
- package/types/ngstarter-ui-components-resizable-container.d.ts +30 -25
- package/types/ngstarter-ui-components-screen-loader.d.ts +38 -32
- package/types/ngstarter-ui-components-scroll-spy.d.ts +56 -60
- package/types/ngstarter-ui-components-scrollbar-area.d.ts +116 -86
- package/types/ngstarter-ui-components-segmented.d.ts +93 -61
- package/types/ngstarter-ui-components-select.d.ts +366 -266
- package/types/ngstarter-ui-components-side-panel.d.ts +59 -40
- package/types/ngstarter-ui-components-sidebar.d.ts +208 -154
- package/types/ngstarter-ui-components-sidenav.d.ts +136 -78
- package/types/ngstarter-ui-components-signature-pad.d.ts +165 -92
- package/types/ngstarter-ui-components-skeleton.d.ts +18 -17
- package/types/ngstarter-ui-components-slide-toggle.d.ts +113 -44
- package/types/ngstarter-ui-components-slider.d.ts +123 -82
- package/types/ngstarter-ui-components-snack-bar.d.ts +126 -134
- package/types/ngstarter-ui-components-sort.d.ts +99 -63
- package/types/ngstarter-ui-components-spinner.d.ts +49 -27
- package/types/ngstarter-ui-components-splash-screen.d.ts +34 -29
- package/types/ngstarter-ui-components-split.d.ts +276 -195
- package/types/ngstarter-ui-components-step-tracker.d.ts +102 -83
- package/types/ngstarter-ui-components-stepper.d.ts +57 -43
- package/types/ngstarter-ui-components-suggestions.d.ts +41 -28
- package/types/ngstarter-ui-components-tab-panel.d.ts +110 -83
- package/types/ngstarter-ui-components-table.d.ts +256 -228
- package/types/ngstarter-ui-components-tabs.d.ts +231 -138
- package/types/ngstarter-ui-components-thumbnail-maker.d.ts +40 -34
- package/types/ngstarter-ui-components-tiles.d.ts +166 -104
- package/types/ngstarter-ui-components-timeline.d.ts +45 -57
- package/types/ngstarter-ui-components-timepicker.d.ts +166 -111
- package/types/ngstarter-ui-components-timezone-select.d.ts +110 -70
- package/types/ngstarter-ui-components-toolbar.d.ts +89 -72
- package/types/ngstarter-ui-components-tooltip.d.ts +89 -52
- package/types/ngstarter-ui-components-tree-select.d.ts +182 -105
- package/types/ngstarter-ui-components-tree.d.ts +355 -229
- package/types/ngstarter-ui-components-upload.d.ts +216 -131
- package/types/ngstarter-ui-components-video-player.d.ts +130 -67
- package/types/ngstarter-ui-components-video-viewer.d.ts +140 -91
- package/types/ngstarter-ui-components-visual-builder.d.ts +5 -8
- package/types/ngstarter-ui-components-whiteboard.d.ts +412 -339
- package/types/ngstarter-ui-components.d.ts +2 -2
- package/fesm2022/ngstarter-ui-components-content-editor-attachment-block-BgKuFsDy.mjs +0 -35
- package/fesm2022/ngstarter-ui-components-content-editor-attachment-block-BgKuFsDy.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-callout-block-CGTJefVK.mjs +0 -26
- package/fesm2022/ngstarter-ui-components-content-editor-callout-block-CGTJefVK.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-code-block.component-B441NasU.mjs +0 -220
- package/fesm2022/ngstarter-ui-components-content-editor-code-block.component-B441NasU.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-cursor-controller-4Ak8VqGX.mjs +0 -99
- package/fesm2022/ngstarter-ui-components-content-editor-cursor-controller-4Ak8VqGX.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-divider-block.component-D1nXMRXD.mjs +0 -40
- package/fesm2022/ngstarter-ui-components-content-editor-divider-block.component-D1nXMRXD.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-embed-block-Bo3irEeG.mjs +0 -375
- package/fesm2022/ngstarter-ui-components-content-editor-embed-block-Bo3irEeG.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-gallery-block-Cbh0nblW.mjs +0 -80
- package/fesm2022/ngstarter-ui-components-content-editor-gallery-block-Cbh0nblW.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-grid-block-BVQTRzaX.mjs +0 -65
- package/fesm2022/ngstarter-ui-components-content-editor-grid-block-BVQTRzaX.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-heading-block.component-CnbRqEWF.mjs +0 -137
- package/fesm2022/ngstarter-ui-components-content-editor-heading-block.component-CnbRqEWF.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-image-block.component-Cv9-02mR.mjs +0 -113
- package/fesm2022/ngstarter-ui-components-content-editor-image-block.component-Cv9-02mR.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-list-block.component-yvSNKY0B.mjs +0 -188
- package/fesm2022/ngstarter-ui-components-content-editor-list-block.component-yvSNKY0B.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-nested-blocks-Clz9SzCR.mjs +0 -117
- package/fesm2022/ngstarter-ui-components-content-editor-nested-blocks-Clz9SzCR.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-ngstarter-ui-components-content-editor-CZn1p9ek.mjs +0 -4464
- package/fesm2022/ngstarter-ui-components-content-editor-ngstarter-ui-components-content-editor-CZn1p9ek.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-paragraph-block.component-CxDRklAS.mjs +0 -132
- package/fesm2022/ngstarter-ui-components-content-editor-paragraph-block.component-CxDRklAS.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-quote-block.component-BNgtiV7U.mjs +0 -171
- package/fesm2022/ngstarter-ui-components-content-editor-quote-block.component-BNgtiV7U.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-table-block.component-D05mE7nQ.mjs +0 -1653
- package/fesm2022/ngstarter-ui-components-content-editor-table-block.component-D05mE7nQ.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-toggle-block-Ch1kWIaX.mjs +0 -20
- package/fesm2022/ngstarter-ui-components-content-editor-toggle-block-Ch1kWIaX.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-upload-status-QnKI_Rfz.mjs +0 -19
- package/fesm2022/ngstarter-ui-components-content-editor-upload-status-QnKI_Rfz.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-content-editor-video-block.component-laP7DTyq.mjs +0 -134
- package/fesm2022/ngstarter-ui-components-content-editor-video-block.component-laP7DTyq.mjs.map +0 -1
- package/fesm2022/ngstarter-ui-components-form-builder-plain-text-settings-GNXKGonc.mjs +0 -159
- package/fesm2022/ngstarter-ui-components-form-builder-plain-text-settings-GNXKGonc.mjs.map +0 -1
|
@@ -1,946 +1,1544 @@
|
|
|
1
|
-
import * as i0 from
|
|
2
|
-
import {
|
|
3
|
-
import { isPlatformServer } from
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
return this._overlay
|
|
71
|
-
.position()
|
|
72
|
-
.flexibleConnectedTo(this._tooltipOrigin)
|
|
73
|
-
.withFlexibleDimensions()
|
|
74
|
-
.withGrowAfterOpen()
|
|
75
|
-
.withPositions(this._getOverlayPositions());
|
|
76
|
-
}
|
|
77
|
-
_getOverlayPositions() {
|
|
78
|
-
return (new PositionManager()).build(this.getTooltipPosition());
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { ChangeDetectionStrategy, Component, DOCUMENT, DestroyRef, ElementRef, Injector, PLATFORM_ID, Renderer2, ViewContainerRef, booleanAttribute, effect, inject, input, numberAttribute } from "@angular/core";
|
|
3
|
+
import { isPlatformServer } from "@angular/common";
|
|
4
|
+
import { takeUntilDestroyed } from "@angular/core/rxjs-interop";
|
|
5
|
+
import { Overlay, OverlayConfig } from "@angular/cdk/overlay";
|
|
6
|
+
import { TemplatePortal } from "@angular/cdk/portal";
|
|
7
|
+
import { fromEvent } from "rxjs";
|
|
8
|
+
import { PositionManager } from "@ngstarter-ui/components/overlay";
|
|
9
|
+
import { arc, area, curveBumpX, curveCatmullRom, curveLinear, curveStep, interpolate, line, max, min, pie, pointer, scaleBand, scaleLinear, scaleOrdinal, scalePoint, schemeTableau10, select } from "d3";
|
|
10
|
+
var BaseChartTooltip = class {
|
|
11
|
+
_tooltipOrigin;
|
|
12
|
+
_tooltipPortal;
|
|
13
|
+
_overlayRef;
|
|
14
|
+
_renderer = inject(Renderer2);
|
|
15
|
+
_overlay = inject(Overlay);
|
|
16
|
+
_viewContainerRef = inject(ViewContainerRef);
|
|
17
|
+
_injector = inject(Injector);
|
|
18
|
+
_document = inject(DOCUMENT);
|
|
19
|
+
_createTooltipOrigin() {
|
|
20
|
+
let tooltipOrigin = this._document.querySelector(".ngs-mchart-tooltip-origin");
|
|
21
|
+
if (!tooltipOrigin) {
|
|
22
|
+
tooltipOrigin = this._renderer.createElement("div");
|
|
23
|
+
tooltipOrigin.classList.add("ngs-mchart-tooltip-origin");
|
|
24
|
+
this._renderer.appendChild(this._document.body, tooltipOrigin);
|
|
25
|
+
}
|
|
26
|
+
this._tooltipOrigin = tooltipOrigin;
|
|
27
|
+
this._renderer.setStyle(this._tooltipOrigin, "width", "0");
|
|
28
|
+
this._renderer.setStyle(this._tooltipOrigin, "height", "0");
|
|
29
|
+
this._renderer.setStyle(this._tooltipOrigin, "z-index", "-1");
|
|
30
|
+
this._renderer.setStyle(this._tooltipOrigin, "position", "fixed");
|
|
31
|
+
this._renderer.setStyle(this._tooltipOrigin, "opacity", "0");
|
|
32
|
+
}
|
|
33
|
+
_showTooltip(data) {
|
|
34
|
+
this._overlayRef?.detach();
|
|
35
|
+
this._overlayRef = this._overlay.create(this._getOverlayConfig());
|
|
36
|
+
this._overlayRef.attach(this._getContentPortal(data));
|
|
37
|
+
}
|
|
38
|
+
_hideTooltip() {
|
|
39
|
+
this._overlayRef?.detach();
|
|
40
|
+
}
|
|
41
|
+
_setTooltipPositionByEvent(e) {
|
|
42
|
+
this._renderer.setStyle(this._tooltipOrigin, "left", e.clientX - 10 + "px");
|
|
43
|
+
this._renderer.setStyle(this._tooltipOrigin, "top", e.clientY + "px");
|
|
44
|
+
this._renderer.setStyle(this._tooltipOrigin, "width", "20px");
|
|
45
|
+
}
|
|
46
|
+
_setTooltipVisible() {
|
|
47
|
+
this._renderer.addClass(this._tooltipOrigin, "is-visible");
|
|
48
|
+
}
|
|
49
|
+
_setTooltipInVisible() {
|
|
50
|
+
this._renderer.removeClass(this._tooltipOrigin, "is-visible");
|
|
51
|
+
}
|
|
52
|
+
_getContentPortal(data) {
|
|
53
|
+
this._tooltipPortal = new TemplatePortal(this.getTooltipTemplateRef(), this._viewContainerRef, { "$implicit": { ...data } }, this._injector);
|
|
54
|
+
return this._tooltipPortal;
|
|
55
|
+
}
|
|
56
|
+
_getOverlayConfig() {
|
|
57
|
+
return new OverlayConfig({
|
|
58
|
+
panelClass: "ngs-mchart-tooltip-overlay",
|
|
59
|
+
positionStrategy: this._getOverlayPositionStrategy(),
|
|
60
|
+
scrollStrategy: this._overlay.scrollStrategies.reposition()
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
_getOverlayPositionStrategy() {
|
|
64
|
+
return this._overlay.position().flexibleConnectedTo(this._tooltipOrigin).withFlexibleDimensions().withGrowAfterOpen().withPositions(this._getOverlayPositions());
|
|
65
|
+
}
|
|
66
|
+
_getOverlayPositions() {
|
|
67
|
+
return new PositionManager().build(this.getTooltipPosition());
|
|
68
|
+
}
|
|
69
|
+
};
|
|
82
70
|
let nextId$1 = 0;
|
|
83
|
-
class MchartLine extends BaseChartTooltip {
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
71
|
+
var MchartLine = class MchartLine extends BaseChartTooltip {
|
|
72
|
+
_initialized = false;
|
|
73
|
+
_host;
|
|
74
|
+
_svg;
|
|
75
|
+
_dimensions;
|
|
76
|
+
_hostWidth = 0;
|
|
77
|
+
_hostHeight = 0;
|
|
78
|
+
_innerWidth = 0;
|
|
79
|
+
_innerHeight = 0;
|
|
80
|
+
_yScale;
|
|
81
|
+
_xScale;
|
|
82
|
+
_curveMap = {
|
|
83
|
+
"linear": curveLinear,
|
|
84
|
+
"catmullRom": curveCatmullRom,
|
|
85
|
+
"curveBumpX": curveBumpX,
|
|
86
|
+
"curveStep": curveStep
|
|
87
|
+
};
|
|
88
|
+
_resizeObserver;
|
|
89
|
+
_tooltipDot;
|
|
90
|
+
_area;
|
|
91
|
+
_line;
|
|
92
|
+
_platformId = inject(PLATFORM_ID);
|
|
93
|
+
_destroyRef = inject(DestroyRef);
|
|
94
|
+
_elementRef = inject(ElementRef);
|
|
95
|
+
data = input([], ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
|
|
96
|
+
labels = input([], ...ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []);
|
|
97
|
+
strokeWidth = input(2, {
|
|
98
|
+
...ngDevMode ? { debugName: "strokeWidth" } : /* istanbul ignore next */ {},
|
|
99
|
+
transform: numberAttribute
|
|
100
|
+
});
|
|
101
|
+
showArea = input(false, {
|
|
102
|
+
...ngDevMode ? { debugName: "showArea" } : /* istanbul ignore next */ {},
|
|
103
|
+
transform: booleanAttribute
|
|
104
|
+
});
|
|
105
|
+
showMarkers = input(false, {
|
|
106
|
+
...ngDevMode ? { debugName: "showMarkers" } : /* istanbul ignore next */ {},
|
|
107
|
+
transform: booleanAttribute
|
|
108
|
+
});
|
|
109
|
+
responsive = input(false, {
|
|
110
|
+
...ngDevMode ? { debugName: "responsive" } : /* istanbul ignore next */ {},
|
|
111
|
+
transform: booleanAttribute
|
|
112
|
+
});
|
|
113
|
+
fillAreaGradient = input(false, {
|
|
114
|
+
...ngDevMode ? { debugName: "fillAreaGradient" } : /* istanbul ignore next */ {},
|
|
115
|
+
transform: booleanAttribute
|
|
116
|
+
});
|
|
117
|
+
curve = input("linear", ...ngDevMode ? [{ debugName: "curve" }] : /* istanbul ignore next */ []);
|
|
118
|
+
xAccessor = input((d, i) => i, ...ngDevMode ? [{ debugName: "xAccessor" }] : /* istanbul ignore next */ []);
|
|
119
|
+
yAccessor = input((d) => d, ...ngDevMode ? [{ debugName: "yAccessor" }] : /* istanbul ignore next */ []);
|
|
120
|
+
compact = input(false, {
|
|
121
|
+
...ngDevMode ? { debugName: "compact" } : /* istanbul ignore next */ {},
|
|
122
|
+
transform: booleanAttribute
|
|
123
|
+
});
|
|
124
|
+
markerDotSize = input(5, {
|
|
125
|
+
...ngDevMode ? { debugName: "markerDotSize" } : /* istanbul ignore next */ {},
|
|
126
|
+
transform: numberAttribute
|
|
127
|
+
});
|
|
128
|
+
tooltip = input(...ngDevMode ? [void 0, { debugName: "tooltip" }] : /* istanbul ignore next */ []);
|
|
129
|
+
tooltipPosition = input("after-center", ...ngDevMode ? [{ debugName: "tooltipPosition" }] : /* istanbul ignore next */ []);
|
|
130
|
+
_currentTooltipPosition = "after-center";
|
|
131
|
+
get gradientId() {
|
|
132
|
+
return "areaGradient" + this._gradientId;
|
|
133
|
+
}
|
|
134
|
+
_gradientId = nextId$1++;
|
|
135
|
+
constructor() {
|
|
136
|
+
super();
|
|
137
|
+
effect(() => {
|
|
138
|
+
this._currentTooltipPosition = this.tooltipPosition();
|
|
139
|
+
});
|
|
140
|
+
effect(() => {
|
|
141
|
+
if (!this._initialized) return;
|
|
142
|
+
this._render();
|
|
143
|
+
});
|
|
144
|
+
}
|
|
145
|
+
ngAfterViewChecked() {
|
|
146
|
+
if (isPlatformServer(this._platformId)) return;
|
|
147
|
+
if (!this._initialized) {
|
|
148
|
+
const element = this._elementRef.nativeElement;
|
|
149
|
+
this._dimensions = element.getBoundingClientRect();
|
|
150
|
+
if (this._dimensions.width !== 0 && this._dimensions.height !== 0) {
|
|
151
|
+
this._initialized = true;
|
|
152
|
+
this._render();
|
|
153
|
+
this._setupResizeObserver();
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
ngOnDestroy() {
|
|
158
|
+
this._resizeObserver?.disconnect();
|
|
159
|
+
}
|
|
160
|
+
getTooltipPosition() {
|
|
161
|
+
return this._currentTooltipPosition;
|
|
162
|
+
}
|
|
163
|
+
getTooltipTemplateRef() {
|
|
164
|
+
return this.tooltip();
|
|
165
|
+
}
|
|
166
|
+
_render() {
|
|
167
|
+
this._setupContainers();
|
|
168
|
+
this._setupData();
|
|
169
|
+
}
|
|
170
|
+
_setupContainers() {
|
|
171
|
+
this._hostWidth = this._dimensions.width;
|
|
172
|
+
this._hostHeight = this._dimensions.height;
|
|
173
|
+
this._innerWidth = this._dimensions.width;
|
|
174
|
+
this._innerHeight = this._dimensions.height;
|
|
175
|
+
this._host = select(this._elementRef.nativeElement);
|
|
176
|
+
this._svg = this._host.select("svg").attr("viewBox", `0 0 ${this._hostWidth} ${this._hostHeight}`);
|
|
177
|
+
if (this.tooltip()) {
|
|
178
|
+
this._tooltipDot = this._renderer.createElement("div");
|
|
179
|
+
this._renderer.setStyle(this._tooltipDot, "width", "10px");
|
|
180
|
+
this._renderer.setStyle(this._tooltipDot, "height", "10px");
|
|
181
|
+
this._renderer.setStyle(this._tooltipDot, "z-index", "-1");
|
|
182
|
+
this._renderer.setStyle(this._tooltipDot, "position", "fixed");
|
|
183
|
+
this._renderer.setStyle(this._tooltipDot, "opacity", "0");
|
|
184
|
+
this._renderer.appendChild(this._document.body, this._tooltipDot);
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
_setupData(isUpdate = false) {
|
|
188
|
+
let markerDotSize = this.markerDotSize();
|
|
189
|
+
if (!this.showMarkers()) markerDotSize = this.strokeWidth();
|
|
190
|
+
const xAccessor = this.xAccessor();
|
|
191
|
+
const yAccessor = this.yAccessor();
|
|
192
|
+
const xDomain = this.data().map((d, i) => xAccessor(d, i));
|
|
193
|
+
if (!this._xScale) this._xScale = scalePoint().domain(xDomain);
|
|
194
|
+
this._xScale.range([markerDotSize, this._innerWidth - markerDotSize]);
|
|
195
|
+
const yDomain = [this.compact() ? min(this.data().map((d) => yAccessor(d))) : 0, max(this.data().map((d) => yAccessor(d)))];
|
|
196
|
+
if (!this._yScale) this._yScale = scaleLinear().domain(yDomain);
|
|
197
|
+
this._yScale.range([this._innerHeight - markerDotSize, markerDotSize]);
|
|
198
|
+
if (this.showArea()) {
|
|
199
|
+
const areaGenerator = area().x((d, i) => this._xScale(xAccessor(d, i))).y1((d) => this._yScale(yAccessor(d))).y0(this._innerHeight - markerDotSize).curve(this._curveMap[this.curve()]);
|
|
200
|
+
if (!this._area) {
|
|
201
|
+
this._area = this._svg.append("path").datum(this.data()).attr("d", areaGenerator).attr("class", "area");
|
|
202
|
+
if (this.fillAreaGradient()) this._area.attr("fill", `url(#${this.gradientId})`);
|
|
203
|
+
} else this._area.attr("d", areaGenerator);
|
|
204
|
+
}
|
|
205
|
+
const lineGenerator = line().x((d, i) => this._xScale(xAccessor(d, i))).y((d) => this._yScale(yAccessor(d)));
|
|
206
|
+
if (!this._line) this._line = this._svg.append("path").datum(this.data()).attr("d", lineGenerator.curve(this._curveMap[this.curve()])).attr("class", "line").attr("stroke-width", this.strokeWidth());
|
|
207
|
+
else this._line.attr("d", lineGenerator.curve(this._curveMap[this.curve()]));
|
|
208
|
+
if (isUpdate) return;
|
|
209
|
+
if (this.showMarkers() || this.tooltip()) {
|
|
210
|
+
const markerLine = this._svg.append("line").attr("x1", 0).attr("x2", 0).attr("y1", 0).attr("y2", this._innerHeight - markerDotSize).attr("opacity", 0).attr("class", "marker-line");
|
|
211
|
+
const markerDot = this._svg.append("circle").attr("cx", 0).attr("cy", 0).attr("r", markerDotSize).attr("opacity", 0).attr("class", "marker-dot");
|
|
212
|
+
let x = 0;
|
|
213
|
+
let y = 0;
|
|
214
|
+
let label;
|
|
215
|
+
let value;
|
|
216
|
+
if (this.tooltip()) this._createTooltipOrigin();
|
|
217
|
+
fromEvent(this._document, "mousemove").pipe(takeUntilDestroyed(this._destroyRef)).subscribe((e) => {
|
|
218
|
+
const target = e.target;
|
|
219
|
+
const oldXPosition = +markerDot.attr("cx");
|
|
220
|
+
const [posX, posY] = pointer(e, this._svg.node());
|
|
221
|
+
let visible = true;
|
|
222
|
+
if (posX < this.markerDotSize() || posY < this.markerDotSize() || posX > this._hostWidth || posY > this._hostHeight) {
|
|
223
|
+
visible = false;
|
|
224
|
+
this._overlayRef?.detach();
|
|
225
|
+
markerLine.attr("opacity", 0);
|
|
226
|
+
markerDot.attr("opacity", 0);
|
|
227
|
+
} else if (target.closest(".ngs-mchart-line") || target.classList.contains("ngs-mchart-tooltip-overlay") || target.closest(".ngs-mchart-tooltip-overlay")) {
|
|
228
|
+
if (this.showMarkers()) {
|
|
229
|
+
markerLine.attr("opacity", 1);
|
|
230
|
+
markerDot.attr("opacity", 1);
|
|
231
|
+
}
|
|
232
|
+
} else {
|
|
233
|
+
visible = false;
|
|
234
|
+
this._overlayRef?.detach();
|
|
235
|
+
}
|
|
236
|
+
const eachBand = this._xScale.step();
|
|
237
|
+
const index = Math.round(posX / eachBand);
|
|
238
|
+
const dataValue = this.data()[index];
|
|
239
|
+
label = this.labels()[index] ? this.labels()[index] : xAccessor(index, index);
|
|
240
|
+
value = yAccessor(dataValue);
|
|
241
|
+
x = this._xScale(xAccessor(index, index));
|
|
242
|
+
y = this._yScale(yAccessor(dataValue));
|
|
243
|
+
markerLine.attr("x1", x).attr("x2", x);
|
|
244
|
+
markerDot.attr("cx", x).attr("cy", y);
|
|
245
|
+
if (this.tooltip()) {
|
|
246
|
+
if (posX < this._hostWidth / 2) this._currentTooltipPosition = "after-center";
|
|
247
|
+
else this._currentTooltipPosition = "before-center";
|
|
248
|
+
this._setTooltipPositionByEvent(e);
|
|
249
|
+
if (visible) {
|
|
250
|
+
this._setTooltipVisible();
|
|
251
|
+
if (!this._overlayRef?.hasAttached()) this._showTooltip({
|
|
252
|
+
label,
|
|
253
|
+
value
|
|
254
|
+
});
|
|
255
|
+
else if (oldXPosition !== x) this._showTooltip({
|
|
256
|
+
label,
|
|
257
|
+
value
|
|
258
|
+
});
|
|
259
|
+
else {
|
|
260
|
+
this._overlayRef.updatePositionStrategy(this._getOverlayPositionStrategy());
|
|
261
|
+
this._overlayRef.updatePosition();
|
|
262
|
+
}
|
|
263
|
+
} else this._setTooltipInVisible();
|
|
264
|
+
}
|
|
265
|
+
});
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
_setupResizeObserver() {
|
|
269
|
+
if (!this.responsive()) return;
|
|
270
|
+
this._resizeObserver = new ResizeObserver((entries) => {
|
|
271
|
+
if (this._hostWidth !== entries[0].contentRect.width || this._hostHeight !== entries[0].contentRect.height) {
|
|
272
|
+
this._hostWidth = entries[0].contentRect.width;
|
|
273
|
+
this._hostHeight = entries[0].contentRect.height;
|
|
274
|
+
this._innerWidth = entries[0].contentRect.width;
|
|
275
|
+
this._innerHeight = entries[0].contentRect.height;
|
|
276
|
+
this._svg.attr("viewBox", `0 0 ${this._hostWidth} ${this._hostHeight}`);
|
|
277
|
+
this._setupData(true);
|
|
278
|
+
}
|
|
279
|
+
});
|
|
280
|
+
this._resizeObserver.observe(this._elementRef.nativeElement);
|
|
281
|
+
}
|
|
282
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
283
|
+
minVersion: "12.0.0",
|
|
284
|
+
version: "22.3.0",
|
|
285
|
+
ngImport: i0,
|
|
286
|
+
type: MchartLine,
|
|
287
|
+
deps: [],
|
|
288
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
289
|
+
});
|
|
290
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
291
|
+
minVersion: "17.0.0",
|
|
292
|
+
version: "22.3.0",
|
|
293
|
+
type: MchartLine,
|
|
294
|
+
isStandalone: true,
|
|
295
|
+
selector: "ngs-mchart-line",
|
|
296
|
+
inputs: {
|
|
297
|
+
data: {
|
|
298
|
+
classPropertyName: "data",
|
|
299
|
+
publicName: "data",
|
|
300
|
+
isSignal: true,
|
|
301
|
+
isRequired: false,
|
|
302
|
+
transformFunction: null
|
|
303
|
+
},
|
|
304
|
+
labels: {
|
|
305
|
+
classPropertyName: "labels",
|
|
306
|
+
publicName: "labels",
|
|
307
|
+
isSignal: true,
|
|
308
|
+
isRequired: false,
|
|
309
|
+
transformFunction: null
|
|
310
|
+
},
|
|
311
|
+
strokeWidth: {
|
|
312
|
+
classPropertyName: "strokeWidth",
|
|
313
|
+
publicName: "strokeWidth",
|
|
314
|
+
isSignal: true,
|
|
315
|
+
isRequired: false,
|
|
316
|
+
transformFunction: null
|
|
317
|
+
},
|
|
318
|
+
showArea: {
|
|
319
|
+
classPropertyName: "showArea",
|
|
320
|
+
publicName: "showArea",
|
|
321
|
+
isSignal: true,
|
|
322
|
+
isRequired: false,
|
|
323
|
+
transformFunction: null
|
|
324
|
+
},
|
|
325
|
+
showMarkers: {
|
|
326
|
+
classPropertyName: "showMarkers",
|
|
327
|
+
publicName: "showMarkers",
|
|
328
|
+
isSignal: true,
|
|
329
|
+
isRequired: false,
|
|
330
|
+
transformFunction: null
|
|
331
|
+
},
|
|
332
|
+
responsive: {
|
|
333
|
+
classPropertyName: "responsive",
|
|
334
|
+
publicName: "responsive",
|
|
335
|
+
isSignal: true,
|
|
336
|
+
isRequired: false,
|
|
337
|
+
transformFunction: null
|
|
338
|
+
},
|
|
339
|
+
fillAreaGradient: {
|
|
340
|
+
classPropertyName: "fillAreaGradient",
|
|
341
|
+
publicName: "fillAreaGradient",
|
|
342
|
+
isSignal: true,
|
|
343
|
+
isRequired: false,
|
|
344
|
+
transformFunction: null
|
|
345
|
+
},
|
|
346
|
+
curve: {
|
|
347
|
+
classPropertyName: "curve",
|
|
348
|
+
publicName: "curve",
|
|
349
|
+
isSignal: true,
|
|
350
|
+
isRequired: false,
|
|
351
|
+
transformFunction: null
|
|
352
|
+
},
|
|
353
|
+
xAccessor: {
|
|
354
|
+
classPropertyName: "xAccessor",
|
|
355
|
+
publicName: "xAccessor",
|
|
356
|
+
isSignal: true,
|
|
357
|
+
isRequired: false,
|
|
358
|
+
transformFunction: null
|
|
359
|
+
},
|
|
360
|
+
yAccessor: {
|
|
361
|
+
classPropertyName: "yAccessor",
|
|
362
|
+
publicName: "yAccessor",
|
|
363
|
+
isSignal: true,
|
|
364
|
+
isRequired: false,
|
|
365
|
+
transformFunction: null
|
|
366
|
+
},
|
|
367
|
+
compact: {
|
|
368
|
+
classPropertyName: "compact",
|
|
369
|
+
publicName: "compact",
|
|
370
|
+
isSignal: true,
|
|
371
|
+
isRequired: false,
|
|
372
|
+
transformFunction: null
|
|
373
|
+
},
|
|
374
|
+
markerDotSize: {
|
|
375
|
+
classPropertyName: "markerDotSize",
|
|
376
|
+
publicName: "markerDotSize",
|
|
377
|
+
isSignal: true,
|
|
378
|
+
isRequired: false,
|
|
379
|
+
transformFunction: null
|
|
380
|
+
},
|
|
381
|
+
tooltip: {
|
|
382
|
+
classPropertyName: "tooltip",
|
|
383
|
+
publicName: "tooltip",
|
|
384
|
+
isSignal: true,
|
|
385
|
+
isRequired: false,
|
|
386
|
+
transformFunction: null
|
|
387
|
+
},
|
|
388
|
+
tooltipPosition: {
|
|
389
|
+
classPropertyName: "tooltipPosition",
|
|
390
|
+
publicName: "tooltipPosition",
|
|
391
|
+
isSignal: true,
|
|
392
|
+
isRequired: false,
|
|
393
|
+
transformFunction: null
|
|
394
|
+
}
|
|
395
|
+
},
|
|
396
|
+
host: {
|
|
397
|
+
properties: { "class.fill-area-gradient": "fillAreaGradient()" },
|
|
398
|
+
classAttribute: "ngs-mchart-line"
|
|
399
|
+
},
|
|
400
|
+
exportAs: ["ngsMchartLine"],
|
|
401
|
+
usesInheritance: true,
|
|
402
|
+
ngImport: i0,
|
|
403
|
+
template: "<svg>\n @if (fillAreaGradient()) {\n <linearGradient [id]=\"gradientId\" x1=\"0\" x2=\"0\" y1=\"0\" y2=\"1\">\n <stop offset=\"0%\" class=\"lg-start-color\"/>\n <stop offset=\"100%\" class=\"lg-end-color\"/>\n </linearGradient>\n }\n</svg>\n",
|
|
404
|
+
styles: [":host{--ngs-mchart-line-line-bg: var(--ngs-color-primary);--ngs-mchart-line-area-bg: var(--ngs-color-primary-200);--ngs-mchart-line-marker-line-bg: var(--ngs-color-neutral);--ngs-mchart-line-marker-dot-bg: var(--ngs-color-primary);--ngs-mchart-line-area-gradient-start-color: var(--ngs-color-primary);--ngs-mchart-line-area-gradient-end-color: var(--ngs-color-background);display:block;overflow:hidden}:host svg{width:100%;height:100%}:host ::ng-deep .line{stroke:var(--ngs-mchart-line-line-bg);fill:none;stroke-linejoin:round;stroke-linecap:round}:host ::ng-deep .area{stroke-width:0}:host ::ng-deep .marker-line{stroke:var(--ngs-mchart-line-marker-line-bg);stroke-width:1;stroke-dasharray:3}:host ::ng-deep .marker-dot{fill:var(--ngs-mchart-line-marker-dot-bg)}:host:not(.fill-area-gradient) ::ng-deep .area{fill:var(--ngs-mchart-line-area-bg)}:host.fill-area-gradient .lg-start-color{stop-color:var(--ngs-mchart-line-area-gradient-start-color)}:host.fill-area-gradient .lg-end-color{stop-color:var(--ngs-mchart-line-area-gradient-end-color)}:host-context(html.dark){--ngs-mchart-line-area-bg: var(--ngs-color-neutral-700);--ngs-mchart-line-area-gradient-start-color: var(--ngs-color-neutral-700)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"],
|
|
405
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
406
|
+
});
|
|
407
|
+
};
|
|
408
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
409
|
+
minVersion: "12.0.0",
|
|
410
|
+
version: "22.3.0",
|
|
411
|
+
ngImport: i0,
|
|
412
|
+
type: MchartLine,
|
|
413
|
+
decorators: [{
|
|
414
|
+
type: Component,
|
|
415
|
+
args: [{
|
|
416
|
+
selector: "ngs-mchart-line",
|
|
417
|
+
exportAs: "ngsMchartLine",
|
|
418
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
419
|
+
host: {
|
|
420
|
+
"class": "ngs-mchart-line",
|
|
421
|
+
"[class.fill-area-gradient]": "fillAreaGradient()"
|
|
422
|
+
},
|
|
423
|
+
template: "<svg>\n @if (fillAreaGradient()) {\n <linearGradient [id]=\"gradientId\" x1=\"0\" x2=\"0\" y1=\"0\" y2=\"1\">\n <stop offset=\"0%\" class=\"lg-start-color\"/>\n <stop offset=\"100%\" class=\"lg-end-color\"/>\n </linearGradient>\n }\n</svg>\n",
|
|
424
|
+
styles: [":host{--ngs-mchart-line-line-bg: var(--ngs-color-primary);--ngs-mchart-line-area-bg: var(--ngs-color-primary-200);--ngs-mchart-line-marker-line-bg: var(--ngs-color-neutral);--ngs-mchart-line-marker-dot-bg: var(--ngs-color-primary);--ngs-mchart-line-area-gradient-start-color: var(--ngs-color-primary);--ngs-mchart-line-area-gradient-end-color: var(--ngs-color-background);display:block;overflow:hidden}:host svg{width:100%;height:100%}:host ::ng-deep .line{stroke:var(--ngs-mchart-line-line-bg);fill:none;stroke-linejoin:round;stroke-linecap:round}:host ::ng-deep .area{stroke-width:0}:host ::ng-deep .marker-line{stroke:var(--ngs-mchart-line-marker-line-bg);stroke-width:1;stroke-dasharray:3}:host ::ng-deep .marker-dot{fill:var(--ngs-mchart-line-marker-dot-bg)}:host:not(.fill-area-gradient) ::ng-deep .area{fill:var(--ngs-mchart-line-area-bg)}:host.fill-area-gradient .lg-start-color{stop-color:var(--ngs-mchart-line-area-gradient-start-color)}:host.fill-area-gradient .lg-end-color{stop-color:var(--ngs-mchart-line-area-gradient-end-color)}:host-context(html.dark){--ngs-mchart-line-area-bg: var(--ngs-color-neutral-700);--ngs-mchart-line-area-gradient-start-color: var(--ngs-color-neutral-700)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"]
|
|
425
|
+
}]
|
|
426
|
+
}],
|
|
427
|
+
ctorParameters: () => [],
|
|
428
|
+
propDecorators: {
|
|
429
|
+
data: [{
|
|
430
|
+
type: i0.Input,
|
|
431
|
+
args: [{
|
|
432
|
+
isSignal: true,
|
|
433
|
+
alias: "data",
|
|
434
|
+
required: false
|
|
435
|
+
}]
|
|
436
|
+
}],
|
|
437
|
+
labels: [{
|
|
438
|
+
type: i0.Input,
|
|
439
|
+
args: [{
|
|
440
|
+
isSignal: true,
|
|
441
|
+
alias: "labels",
|
|
442
|
+
required: false
|
|
443
|
+
}]
|
|
444
|
+
}],
|
|
445
|
+
strokeWidth: [{
|
|
446
|
+
type: i0.Input,
|
|
447
|
+
args: [{
|
|
448
|
+
isSignal: true,
|
|
449
|
+
alias: "strokeWidth",
|
|
450
|
+
required: false
|
|
451
|
+
}]
|
|
452
|
+
}],
|
|
453
|
+
showArea: [{
|
|
454
|
+
type: i0.Input,
|
|
455
|
+
args: [{
|
|
456
|
+
isSignal: true,
|
|
457
|
+
alias: "showArea",
|
|
458
|
+
required: false
|
|
459
|
+
}]
|
|
460
|
+
}],
|
|
461
|
+
showMarkers: [{
|
|
462
|
+
type: i0.Input,
|
|
463
|
+
args: [{
|
|
464
|
+
isSignal: true,
|
|
465
|
+
alias: "showMarkers",
|
|
466
|
+
required: false
|
|
467
|
+
}]
|
|
468
|
+
}],
|
|
469
|
+
responsive: [{
|
|
470
|
+
type: i0.Input,
|
|
471
|
+
args: [{
|
|
472
|
+
isSignal: true,
|
|
473
|
+
alias: "responsive",
|
|
474
|
+
required: false
|
|
475
|
+
}]
|
|
476
|
+
}],
|
|
477
|
+
fillAreaGradient: [{
|
|
478
|
+
type: i0.Input,
|
|
479
|
+
args: [{
|
|
480
|
+
isSignal: true,
|
|
481
|
+
alias: "fillAreaGradient",
|
|
482
|
+
required: false
|
|
483
|
+
}]
|
|
484
|
+
}],
|
|
485
|
+
curve: [{
|
|
486
|
+
type: i0.Input,
|
|
487
|
+
args: [{
|
|
488
|
+
isSignal: true,
|
|
489
|
+
alias: "curve",
|
|
490
|
+
required: false
|
|
491
|
+
}]
|
|
492
|
+
}],
|
|
493
|
+
xAccessor: [{
|
|
494
|
+
type: i0.Input,
|
|
495
|
+
args: [{
|
|
496
|
+
isSignal: true,
|
|
497
|
+
alias: "xAccessor",
|
|
498
|
+
required: false
|
|
499
|
+
}]
|
|
500
|
+
}],
|
|
501
|
+
yAccessor: [{
|
|
502
|
+
type: i0.Input,
|
|
503
|
+
args: [{
|
|
504
|
+
isSignal: true,
|
|
505
|
+
alias: "yAccessor",
|
|
506
|
+
required: false
|
|
507
|
+
}]
|
|
508
|
+
}],
|
|
509
|
+
compact: [{
|
|
510
|
+
type: i0.Input,
|
|
511
|
+
args: [{
|
|
512
|
+
isSignal: true,
|
|
513
|
+
alias: "compact",
|
|
514
|
+
required: false
|
|
515
|
+
}]
|
|
516
|
+
}],
|
|
517
|
+
markerDotSize: [{
|
|
518
|
+
type: i0.Input,
|
|
519
|
+
args: [{
|
|
520
|
+
isSignal: true,
|
|
521
|
+
alias: "markerDotSize",
|
|
522
|
+
required: false
|
|
523
|
+
}]
|
|
524
|
+
}],
|
|
525
|
+
tooltip: [{
|
|
526
|
+
type: i0.Input,
|
|
527
|
+
args: [{
|
|
528
|
+
isSignal: true,
|
|
529
|
+
alias: "tooltip",
|
|
530
|
+
required: false
|
|
531
|
+
}]
|
|
532
|
+
}],
|
|
533
|
+
tooltipPosition: [{
|
|
534
|
+
type: i0.Input,
|
|
535
|
+
args: [{
|
|
536
|
+
isSignal: true,
|
|
537
|
+
alias: "tooltipPosition",
|
|
538
|
+
required: false
|
|
539
|
+
}]
|
|
540
|
+
}]
|
|
541
|
+
}
|
|
542
|
+
});
|
|
379
543
|
let nextId = 0;
|
|
380
|
-
class MchartBar extends BaseChartTooltip {
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
}
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
544
|
+
var MchartBar = class MchartBar extends BaseChartTooltip {
|
|
545
|
+
_initialized = false;
|
|
546
|
+
_host;
|
|
547
|
+
_svg;
|
|
548
|
+
_hlContainer;
|
|
549
|
+
_dataContainer;
|
|
550
|
+
_dimensions;
|
|
551
|
+
_innerWidth = 0;
|
|
552
|
+
_innerHeight = 0;
|
|
553
|
+
_hostWidth = 0;
|
|
554
|
+
_hostHeight = 0;
|
|
555
|
+
_xScale;
|
|
556
|
+
_yScale;
|
|
557
|
+
_resizeObserver;
|
|
558
|
+
_platformId = inject(PLATFORM_ID);
|
|
559
|
+
_elementRef = inject(ElementRef);
|
|
560
|
+
_destroyRef = inject(DestroyRef);
|
|
561
|
+
data = input([], ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
|
|
562
|
+
labels = input([], ...ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []);
|
|
563
|
+
gap = input(.2, {
|
|
564
|
+
...ngDevMode ? { debugName: "gap" } : /* istanbul ignore next */ {},
|
|
565
|
+
transform: numberAttribute
|
|
566
|
+
});
|
|
567
|
+
radius = input(0, {
|
|
568
|
+
...ngDevMode ? { debugName: "radius" } : /* istanbul ignore next */ {},
|
|
569
|
+
transform: numberAttribute
|
|
570
|
+
});
|
|
571
|
+
highlight = input(false, {
|
|
572
|
+
...ngDevMode ? { debugName: "highlight" } : /* istanbul ignore next */ {},
|
|
573
|
+
transform: booleanAttribute
|
|
574
|
+
});
|
|
575
|
+
responsive = input(false, {
|
|
576
|
+
...ngDevMode ? { debugName: "responsive" } : /* istanbul ignore next */ {},
|
|
577
|
+
transform: booleanAttribute
|
|
578
|
+
});
|
|
579
|
+
fillGradient = input(false, {
|
|
580
|
+
...ngDevMode ? { debugName: "fillGradient" } : /* istanbul ignore next */ {},
|
|
581
|
+
transform: booleanAttribute
|
|
582
|
+
});
|
|
583
|
+
xAccessor = input((d, i) => i, ...ngDevMode ? [{ debugName: "xAccessor" }] : /* istanbul ignore next */ []);
|
|
584
|
+
yAccessor = input((d) => d, ...ngDevMode ? [{ debugName: "yAccessor" }] : /* istanbul ignore next */ []);
|
|
585
|
+
tooltip = input(...ngDevMode ? [void 0, { debugName: "tooltip" }] : /* istanbul ignore next */ []);
|
|
586
|
+
tooltipPosition = input("after-center", ...ngDevMode ? [{ debugName: "tooltipPosition" }] : /* istanbul ignore next */ []);
|
|
587
|
+
_currentTooltipPosition = "after-center";
|
|
588
|
+
get gradientId() {
|
|
589
|
+
return "areaGradient" + this._gradientId;
|
|
590
|
+
}
|
|
591
|
+
_gradientId = nextId++;
|
|
592
|
+
constructor() {
|
|
593
|
+
super();
|
|
594
|
+
effect(() => {
|
|
595
|
+
this._currentTooltipPosition = this.tooltipPosition();
|
|
596
|
+
});
|
|
597
|
+
effect(() => {
|
|
598
|
+
if (!this._initialized) return;
|
|
599
|
+
this._render();
|
|
600
|
+
this._setupResizeObserver();
|
|
601
|
+
});
|
|
602
|
+
}
|
|
603
|
+
ngAfterViewChecked() {
|
|
604
|
+
if (isPlatformServer(this._platformId)) return;
|
|
605
|
+
if (!this._initialized) {
|
|
606
|
+
const element = this._elementRef.nativeElement;
|
|
607
|
+
this._dimensions = element.getBoundingClientRect();
|
|
608
|
+
if (this._dimensions.width !== 0 && this._dimensions.height !== 0) {
|
|
609
|
+
this._initialized = true;
|
|
610
|
+
this._render();
|
|
611
|
+
this._setupResizeObserver();
|
|
612
|
+
}
|
|
613
|
+
}
|
|
614
|
+
}
|
|
615
|
+
ngOnDestroy() {
|
|
616
|
+
this._resizeObserver?.disconnect();
|
|
617
|
+
}
|
|
618
|
+
getTooltipPosition() {
|
|
619
|
+
return this._currentTooltipPosition;
|
|
620
|
+
}
|
|
621
|
+
getTooltipTemplateRef() {
|
|
622
|
+
return this.tooltip();
|
|
623
|
+
}
|
|
624
|
+
_render() {
|
|
625
|
+
this._init();
|
|
626
|
+
this._setupAxisScale();
|
|
627
|
+
this._setupData();
|
|
628
|
+
this._initTooltip();
|
|
629
|
+
}
|
|
630
|
+
_init() {
|
|
631
|
+
this._hostWidth = this._dimensions.width;
|
|
632
|
+
this._hostHeight = this._dimensions.height;
|
|
633
|
+
this._innerWidth = this._dimensions.width;
|
|
634
|
+
this._innerHeight = this._dimensions.height;
|
|
635
|
+
this._host = select(this._elementRef.nativeElement);
|
|
636
|
+
this._svg = this._host.select("svg").attr("viewBox", `0 0 ${this._hostWidth} ${this._hostHeight}`);
|
|
637
|
+
}
|
|
638
|
+
_setupAxisScale() {
|
|
639
|
+
if (!this._xScale) this._xScale = scaleBand().paddingInner(this.gap()).domain(this.data().map((d, i) => i.toString()));
|
|
640
|
+
this._xScale.range([0, this._innerWidth]);
|
|
641
|
+
if (!this._yScale) this._yScale = scaleLinear().domain([0, Math.max(...this.data())]);
|
|
642
|
+
this._yScale.range([this._innerHeight, 0]);
|
|
643
|
+
}
|
|
644
|
+
_setupData() {
|
|
645
|
+
if (this.highlight()) {
|
|
646
|
+
if (!this._hlContainer) {
|
|
647
|
+
this._hlContainer = this._svg.append("g").attr("class", "hl-container").attr("transform", `translate(0,0)`);
|
|
648
|
+
this._hlContainer.selectAll("rect").data(this.data()).enter().append("rect").attr("rx", this.radius()).attr("x", (d, i) => this._xScale(i.toString())).attr("y", 0).attr("width", this._xScale.bandwidth()).attr("height", this._innerHeight).attr("class", "highlight");
|
|
649
|
+
} else this._hlContainer.selectAll("rect").attr("x", (d, i) => this._xScale(i.toString())).attr("y", 0).attr("width", this._xScale.bandwidth()).attr("height", this._innerHeight);
|
|
650
|
+
}
|
|
651
|
+
if (!this._dataContainer) {
|
|
652
|
+
this._dataContainer = this._svg.append("g").attr("class", "data-container").attr("transform", `translate(0,0)`);
|
|
653
|
+
const allBars = this._dataContainer.selectAll("rect").data(this.data()).enter().append("rect").attr("rx", this.radius()).attr("x", (d, i) => this._xScale(i.toString())).attr("y", (d) => this._yScale(d)).attr("width", this._xScale.bandwidth()).attr("height", (d) => this._innerHeight - this._yScale(d)).attr("class", "bar");
|
|
654
|
+
if (this.fillGradient()) allBars.attr("fill", `url(#${this.gradientId})`);
|
|
655
|
+
} else this._dataContainer.selectAll("rect").attr("x", (d, i) => this._xScale(i.toString())).attr("y", (d) => this._yScale(d)).attr("width", this._xScale.bandwidth()).attr("height", (d) => this._innerHeight - this._yScale(d));
|
|
656
|
+
}
|
|
657
|
+
_setupResizeObserver() {
|
|
658
|
+
if (!this.responsive()) return;
|
|
659
|
+
this._resizeObserver?.disconnect();
|
|
660
|
+
this._resizeObserver = new ResizeObserver((entries) => {
|
|
661
|
+
if (this._hostWidth !== entries[0].contentRect.width || this._hostHeight !== entries[0].contentRect.height) {
|
|
662
|
+
this._hostWidth = entries[0].contentRect.width;
|
|
663
|
+
this._hostHeight = entries[0].contentRect.height;
|
|
664
|
+
this._innerWidth = entries[0].contentRect.width;
|
|
665
|
+
this._innerHeight = entries[0].contentRect.height;
|
|
666
|
+
this._svg.attr("viewBox", `0 0 ${this._hostWidth} ${this._hostHeight}`);
|
|
667
|
+
this._setupAxisScale();
|
|
668
|
+
this._setupData();
|
|
669
|
+
}
|
|
670
|
+
});
|
|
671
|
+
this._resizeObserver.observe(this._elementRef.nativeElement);
|
|
672
|
+
}
|
|
673
|
+
_initTooltip() {
|
|
674
|
+
if (!this.tooltip()) return;
|
|
675
|
+
const xAccessor = this.xAccessor();
|
|
676
|
+
const yAccessor = this.yAccessor();
|
|
677
|
+
this._createTooltipOrigin();
|
|
678
|
+
let x = 0;
|
|
679
|
+
let label;
|
|
680
|
+
let value;
|
|
681
|
+
let oldX;
|
|
682
|
+
fromEvent(this._document, "mousemove").pipe(takeUntilDestroyed(this._destroyRef)).subscribe((e) => {
|
|
683
|
+
const target = e.target;
|
|
684
|
+
const [posX, posY] = pointer(e, this._svg.node());
|
|
685
|
+
let visible = true;
|
|
686
|
+
if (posX < 0 || posY < 0 || posX > this._hostWidth || posY > this._hostHeight) {
|
|
687
|
+
visible = false;
|
|
688
|
+
oldX = null;
|
|
689
|
+
this._overlayRef?.detach();
|
|
690
|
+
} else if (!target.closest(".ngs-mchart-line") || !target.classList.contains("ngs-mchart-tooltip-overlay") || !target.closest(".ngs-mchart-tooltip-overlay")) {
|
|
691
|
+
oldX = null;
|
|
692
|
+
this._overlayRef?.detach();
|
|
693
|
+
}
|
|
694
|
+
const eachBand = this._xScale.step();
|
|
695
|
+
const index = Math.floor(posX / eachBand);
|
|
696
|
+
const dataValue = this.data()[index];
|
|
697
|
+
label = this.labels()[index] ? this.labels()[index] : xAccessor(index, index);
|
|
698
|
+
value = yAccessor(dataValue);
|
|
699
|
+
x = this._xScale(xAccessor(index, index));
|
|
700
|
+
this._yScale(yAccessor(dataValue));
|
|
701
|
+
if (posX < this._hostWidth / 2) this._currentTooltipPosition = "after-center";
|
|
702
|
+
else this._currentTooltipPosition = "before-center";
|
|
703
|
+
this._setTooltipPositionByEvent(e);
|
|
704
|
+
if (visible) {
|
|
705
|
+
this._setTooltipVisible();
|
|
706
|
+
if (!this._overlayRef?.hasAttached()) {
|
|
707
|
+
oldX = x;
|
|
708
|
+
this._showTooltip({
|
|
709
|
+
label,
|
|
710
|
+
value
|
|
711
|
+
});
|
|
712
|
+
} else if (oldX !== x) {
|
|
713
|
+
oldX = x;
|
|
714
|
+
this._showTooltip({
|
|
715
|
+
label,
|
|
716
|
+
value
|
|
717
|
+
});
|
|
718
|
+
} else {
|
|
719
|
+
this._overlayRef.updatePositionStrategy(this._getOverlayPositionStrategy());
|
|
720
|
+
this._overlayRef.updatePosition();
|
|
721
|
+
}
|
|
722
|
+
} else {
|
|
723
|
+
oldX = x;
|
|
724
|
+
this._setTooltipInVisible();
|
|
725
|
+
}
|
|
726
|
+
});
|
|
727
|
+
}
|
|
728
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
729
|
+
minVersion: "12.0.0",
|
|
730
|
+
version: "22.3.0",
|
|
731
|
+
ngImport: i0,
|
|
732
|
+
type: MchartBar,
|
|
733
|
+
deps: [],
|
|
734
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
735
|
+
});
|
|
736
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
737
|
+
minVersion: "17.0.0",
|
|
738
|
+
version: "22.3.0",
|
|
739
|
+
type: MchartBar,
|
|
740
|
+
isStandalone: true,
|
|
741
|
+
selector: "ngs-mchart-bar",
|
|
742
|
+
inputs: {
|
|
743
|
+
data: {
|
|
744
|
+
classPropertyName: "data",
|
|
745
|
+
publicName: "data",
|
|
746
|
+
isSignal: true,
|
|
747
|
+
isRequired: false,
|
|
748
|
+
transformFunction: null
|
|
749
|
+
},
|
|
750
|
+
labels: {
|
|
751
|
+
classPropertyName: "labels",
|
|
752
|
+
publicName: "labels",
|
|
753
|
+
isSignal: true,
|
|
754
|
+
isRequired: false,
|
|
755
|
+
transformFunction: null
|
|
756
|
+
},
|
|
757
|
+
gap: {
|
|
758
|
+
classPropertyName: "gap",
|
|
759
|
+
publicName: "gap",
|
|
760
|
+
isSignal: true,
|
|
761
|
+
isRequired: false,
|
|
762
|
+
transformFunction: null
|
|
763
|
+
},
|
|
764
|
+
radius: {
|
|
765
|
+
classPropertyName: "radius",
|
|
766
|
+
publicName: "radius",
|
|
767
|
+
isSignal: true,
|
|
768
|
+
isRequired: false,
|
|
769
|
+
transformFunction: null
|
|
770
|
+
},
|
|
771
|
+
highlight: {
|
|
772
|
+
classPropertyName: "highlight",
|
|
773
|
+
publicName: "highlight",
|
|
774
|
+
isSignal: true,
|
|
775
|
+
isRequired: false,
|
|
776
|
+
transformFunction: null
|
|
777
|
+
},
|
|
778
|
+
responsive: {
|
|
779
|
+
classPropertyName: "responsive",
|
|
780
|
+
publicName: "responsive",
|
|
781
|
+
isSignal: true,
|
|
782
|
+
isRequired: false,
|
|
783
|
+
transformFunction: null
|
|
784
|
+
},
|
|
785
|
+
fillGradient: {
|
|
786
|
+
classPropertyName: "fillGradient",
|
|
787
|
+
publicName: "fillGradient",
|
|
788
|
+
isSignal: true,
|
|
789
|
+
isRequired: false,
|
|
790
|
+
transformFunction: null
|
|
791
|
+
},
|
|
792
|
+
xAccessor: {
|
|
793
|
+
classPropertyName: "xAccessor",
|
|
794
|
+
publicName: "xAccessor",
|
|
795
|
+
isSignal: true,
|
|
796
|
+
isRequired: false,
|
|
797
|
+
transformFunction: null
|
|
798
|
+
},
|
|
799
|
+
yAccessor: {
|
|
800
|
+
classPropertyName: "yAccessor",
|
|
801
|
+
publicName: "yAccessor",
|
|
802
|
+
isSignal: true,
|
|
803
|
+
isRequired: false,
|
|
804
|
+
transformFunction: null
|
|
805
|
+
},
|
|
806
|
+
tooltip: {
|
|
807
|
+
classPropertyName: "tooltip",
|
|
808
|
+
publicName: "tooltip",
|
|
809
|
+
isSignal: true,
|
|
810
|
+
isRequired: false,
|
|
811
|
+
transformFunction: null
|
|
812
|
+
},
|
|
813
|
+
tooltipPosition: {
|
|
814
|
+
classPropertyName: "tooltipPosition",
|
|
815
|
+
publicName: "tooltipPosition",
|
|
816
|
+
isSignal: true,
|
|
817
|
+
isRequired: false,
|
|
818
|
+
transformFunction: null
|
|
819
|
+
}
|
|
820
|
+
},
|
|
821
|
+
host: {
|
|
822
|
+
properties: {
|
|
823
|
+
"class.fill-gradient": "fillGradient()",
|
|
824
|
+
"class.with-tooltip": "!!tooltip()"
|
|
825
|
+
},
|
|
826
|
+
classAttribute: "ngs-mchart-bar"
|
|
827
|
+
},
|
|
828
|
+
exportAs: ["ngsMchartBar"],
|
|
829
|
+
usesInheritance: true,
|
|
830
|
+
ngImport: i0,
|
|
831
|
+
template: "<svg>\n <defs>\n @if (fillGradient()) {\n <linearGradient [id]=\"gradientId\" x1=\"0\" x2=\"0\" y1=\"0\" y2=\"1\">\n <stop offset=\"0%\" class=\"lg-start-color\"/>\n <stop offset=\"100%\" class=\"lg-end-color\"/>\n </linearGradient>\n }\n </defs>\n</svg>\n",
|
|
832
|
+
styles: [":host{--ngs-mchart-bar-bar-bg: var(--ngs-color-primary);--ngs-mchart-bar-bar-gradient-start-color: var(--ngs-color-primary-500);--ngs-mchart-bar-bar-gradient-end-color: var(--ngs-color-primary);--ngs-mchart-bar-highlight-bg: var(--ngs-color-neutral-200);display:block;overflow:hidden}:host svg{width:100%;height:100%}:host ::ng-deep .highlight{fill:var(--ngs-mchart-bar-highlight-bg)}:host:not(.fill-gradient) ::ng-deep .bar{fill:var(--ngs-mchart-bar-bar-bg)}:host.fill-gradient .lg-start-color{stop-color:var(--ngs-mchart-bar-bar-gradient-start-color)}:host.fill-gradient .lg-end-color{stop-color:var(--ngs-mchart-bar-bar-gradient-end-color)}:host.with-tooltip ::ng-deep .bar:hover{opacity:.85}:host-context(html.dark){--ngs-mchart-bar-highlight-bg: var(--ngs-color-neutral-700)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"],
|
|
833
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
834
|
+
});
|
|
835
|
+
};
|
|
836
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
837
|
+
minVersion: "12.0.0",
|
|
838
|
+
version: "22.3.0",
|
|
839
|
+
ngImport: i0,
|
|
840
|
+
type: MchartBar,
|
|
841
|
+
decorators: [{
|
|
842
|
+
type: Component,
|
|
843
|
+
args: [{
|
|
844
|
+
selector: "ngs-mchart-bar",
|
|
845
|
+
exportAs: "ngsMchartBar",
|
|
846
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
847
|
+
host: {
|
|
848
|
+
"class": "ngs-mchart-bar",
|
|
849
|
+
"[class.fill-gradient]": "fillGradient()",
|
|
850
|
+
"[class.with-tooltip]": "!!tooltip()"
|
|
851
|
+
},
|
|
852
|
+
template: "<svg>\n <defs>\n @if (fillGradient()) {\n <linearGradient [id]=\"gradientId\" x1=\"0\" x2=\"0\" y1=\"0\" y2=\"1\">\n <stop offset=\"0%\" class=\"lg-start-color\"/>\n <stop offset=\"100%\" class=\"lg-end-color\"/>\n </linearGradient>\n }\n </defs>\n</svg>\n",
|
|
853
|
+
styles: [":host{--ngs-mchart-bar-bar-bg: var(--ngs-color-primary);--ngs-mchart-bar-bar-gradient-start-color: var(--ngs-color-primary-500);--ngs-mchart-bar-bar-gradient-end-color: var(--ngs-color-primary);--ngs-mchart-bar-highlight-bg: var(--ngs-color-neutral-200);display:block;overflow:hidden}:host svg{width:100%;height:100%}:host ::ng-deep .highlight{fill:var(--ngs-mchart-bar-highlight-bg)}:host:not(.fill-gradient) ::ng-deep .bar{fill:var(--ngs-mchart-bar-bar-bg)}:host.fill-gradient .lg-start-color{stop-color:var(--ngs-mchart-bar-bar-gradient-start-color)}:host.fill-gradient .lg-end-color{stop-color:var(--ngs-mchart-bar-bar-gradient-end-color)}:host.with-tooltip ::ng-deep .bar:hover{opacity:.85}:host-context(html.dark){--ngs-mchart-bar-highlight-bg: var(--ngs-color-neutral-700)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"]
|
|
854
|
+
}]
|
|
855
|
+
}],
|
|
856
|
+
ctorParameters: () => [],
|
|
857
|
+
propDecorators: {
|
|
858
|
+
data: [{
|
|
859
|
+
type: i0.Input,
|
|
860
|
+
args: [{
|
|
861
|
+
isSignal: true,
|
|
862
|
+
alias: "data",
|
|
863
|
+
required: false
|
|
864
|
+
}]
|
|
865
|
+
}],
|
|
866
|
+
labels: [{
|
|
867
|
+
type: i0.Input,
|
|
868
|
+
args: [{
|
|
869
|
+
isSignal: true,
|
|
870
|
+
alias: "labels",
|
|
871
|
+
required: false
|
|
872
|
+
}]
|
|
873
|
+
}],
|
|
874
|
+
gap: [{
|
|
875
|
+
type: i0.Input,
|
|
876
|
+
args: [{
|
|
877
|
+
isSignal: true,
|
|
878
|
+
alias: "gap",
|
|
879
|
+
required: false
|
|
880
|
+
}]
|
|
881
|
+
}],
|
|
882
|
+
radius: [{
|
|
883
|
+
type: i0.Input,
|
|
884
|
+
args: [{
|
|
885
|
+
isSignal: true,
|
|
886
|
+
alias: "radius",
|
|
887
|
+
required: false
|
|
888
|
+
}]
|
|
889
|
+
}],
|
|
890
|
+
highlight: [{
|
|
891
|
+
type: i0.Input,
|
|
892
|
+
args: [{
|
|
893
|
+
isSignal: true,
|
|
894
|
+
alias: "highlight",
|
|
895
|
+
required: false
|
|
896
|
+
}]
|
|
897
|
+
}],
|
|
898
|
+
responsive: [{
|
|
899
|
+
type: i0.Input,
|
|
900
|
+
args: [{
|
|
901
|
+
isSignal: true,
|
|
902
|
+
alias: "responsive",
|
|
903
|
+
required: false
|
|
904
|
+
}]
|
|
905
|
+
}],
|
|
906
|
+
fillGradient: [{
|
|
907
|
+
type: i0.Input,
|
|
908
|
+
args: [{
|
|
909
|
+
isSignal: true,
|
|
910
|
+
alias: "fillGradient",
|
|
911
|
+
required: false
|
|
912
|
+
}]
|
|
913
|
+
}],
|
|
914
|
+
xAccessor: [{
|
|
915
|
+
type: i0.Input,
|
|
916
|
+
args: [{
|
|
917
|
+
isSignal: true,
|
|
918
|
+
alias: "xAccessor",
|
|
919
|
+
required: false
|
|
920
|
+
}]
|
|
921
|
+
}],
|
|
922
|
+
yAccessor: [{
|
|
923
|
+
type: i0.Input,
|
|
924
|
+
args: [{
|
|
925
|
+
isSignal: true,
|
|
926
|
+
alias: "yAccessor",
|
|
927
|
+
required: false
|
|
928
|
+
}]
|
|
929
|
+
}],
|
|
930
|
+
tooltip: [{
|
|
931
|
+
type: i0.Input,
|
|
932
|
+
args: [{
|
|
933
|
+
isSignal: true,
|
|
934
|
+
alias: "tooltip",
|
|
935
|
+
required: false
|
|
936
|
+
}]
|
|
937
|
+
}],
|
|
938
|
+
tooltipPosition: [{
|
|
939
|
+
type: i0.Input,
|
|
940
|
+
args: [{
|
|
941
|
+
isSignal: true,
|
|
942
|
+
alias: "tooltipPosition",
|
|
943
|
+
required: false
|
|
944
|
+
}]
|
|
945
|
+
}]
|
|
946
|
+
}
|
|
947
|
+
});
|
|
948
|
+
var MchartPie = class MchartPie extends BaseChartTooltip {
|
|
949
|
+
_initialized = false;
|
|
950
|
+
_host;
|
|
951
|
+
_svg;
|
|
952
|
+
_dataContainer;
|
|
953
|
+
_legendContainer;
|
|
954
|
+
_dimensions;
|
|
955
|
+
_innerWidth = 0;
|
|
956
|
+
_innerHeight = 0;
|
|
957
|
+
_hostWidth = 0;
|
|
958
|
+
_hostHeight = 0;
|
|
959
|
+
_resizeObserver;
|
|
960
|
+
_platformId = inject(PLATFORM_ID);
|
|
961
|
+
_elementRef = inject(ElementRef);
|
|
962
|
+
_radius = 0;
|
|
963
|
+
_arcGenerator;
|
|
964
|
+
_pieGenerator;
|
|
965
|
+
_colorsGenerator;
|
|
966
|
+
_arcTweenGenerator;
|
|
967
|
+
_pieData;
|
|
968
|
+
data = input([], ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
|
|
969
|
+
labels = input([], ...ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []);
|
|
970
|
+
valueAccessor = input((d) => d, ...ngDevMode ? [{ debugName: "valueAccessor" }] : /* istanbul ignore next */ []);
|
|
971
|
+
dataItemStrokeWidth = input(1, {
|
|
972
|
+
...ngDevMode ? { debugName: "dataItemStrokeWidth" } : /* istanbul ignore next */ {},
|
|
973
|
+
transform: numberAttribute
|
|
974
|
+
});
|
|
975
|
+
legendContainerWidth = input(0, {
|
|
976
|
+
...ngDevMode ? { debugName: "legendContainerWidth" } : /* istanbul ignore next */ {},
|
|
977
|
+
transform: numberAttribute
|
|
978
|
+
});
|
|
979
|
+
showDataAnimation = input(false, {
|
|
980
|
+
...ngDevMode ? { debugName: "showDataAnimation" } : /* istanbul ignore next */ {},
|
|
981
|
+
transform: booleanAttribute
|
|
982
|
+
});
|
|
983
|
+
showValueOnSlices = input(false, {
|
|
984
|
+
...ngDevMode ? { debugName: "showValueOnSlices" } : /* istanbul ignore next */ {},
|
|
985
|
+
transform: booleanAttribute
|
|
986
|
+
});
|
|
987
|
+
showLegend = input(false, {
|
|
988
|
+
...ngDevMode ? { debugName: "showLegend" } : /* istanbul ignore next */ {},
|
|
989
|
+
transform: booleanAttribute
|
|
990
|
+
});
|
|
991
|
+
legendOffset = input(30, {
|
|
992
|
+
...ngDevMode ? { debugName: "legendOffset" } : /* istanbul ignore next */ {},
|
|
993
|
+
transform: numberAttribute
|
|
994
|
+
});
|
|
995
|
+
legendItemHeight = input(30, {
|
|
996
|
+
...ngDevMode ? { debugName: "legendItemHeight" } : /* istanbul ignore next */ {},
|
|
997
|
+
transform: numberAttribute
|
|
998
|
+
});
|
|
999
|
+
legendItemSymbolSize = input(12, {
|
|
1000
|
+
...ngDevMode ? { debugName: "legendItemSymbolSize" } : /* istanbul ignore next */ {},
|
|
1001
|
+
transform: numberAttribute
|
|
1002
|
+
});
|
|
1003
|
+
legendItemFontSize = input(14, {
|
|
1004
|
+
...ngDevMode ? { debugName: "legendItemFontSize" } : /* istanbul ignore next */ {},
|
|
1005
|
+
transform: numberAttribute
|
|
1006
|
+
});
|
|
1007
|
+
legendItemSymbolBorderRadius = input(12, {
|
|
1008
|
+
...ngDevMode ? { debugName: "legendItemSymbolBorderRadius" } : /* istanbul ignore next */ {},
|
|
1009
|
+
transform: numberAttribute
|
|
1010
|
+
});
|
|
1011
|
+
valueFontSize = input(12, {
|
|
1012
|
+
...ngDevMode ? { debugName: "valueFontSize" } : /* istanbul ignore next */ {},
|
|
1013
|
+
transform: numberAttribute
|
|
1014
|
+
});
|
|
1015
|
+
tooltip = input(...ngDevMode ? [void 0, { debugName: "tooltip" }] : /* istanbul ignore next */ []);
|
|
1016
|
+
tooltipPosition = input("after-center", ...ngDevMode ? [{ debugName: "tooltipPosition" }] : /* istanbul ignore next */ []);
|
|
1017
|
+
getTooltipPosition() {
|
|
1018
|
+
return this.tooltipPosition();
|
|
1019
|
+
}
|
|
1020
|
+
getTooltipTemplateRef() {
|
|
1021
|
+
return this.tooltip();
|
|
1022
|
+
}
|
|
1023
|
+
ngAfterViewChecked() {
|
|
1024
|
+
if (isPlatformServer(this._platformId)) return;
|
|
1025
|
+
if (!this._initialized) {
|
|
1026
|
+
const element = this._elementRef.nativeElement;
|
|
1027
|
+
this._dimensions = element.getBoundingClientRect();
|
|
1028
|
+
if (this._dimensions.width !== 0 && this._dimensions.height !== 0) {
|
|
1029
|
+
this._initialized = true;
|
|
1030
|
+
this._render();
|
|
1031
|
+
this._setupResizeObserver();
|
|
1032
|
+
}
|
|
1033
|
+
}
|
|
1034
|
+
}
|
|
1035
|
+
ngOnChanges(changes) {
|
|
1036
|
+
if (!this._initialized) return;
|
|
1037
|
+
if (changes["data"] && !changes["data"].firstChange) this._draw(true);
|
|
1038
|
+
}
|
|
1039
|
+
ngOnDestroy() {
|
|
1040
|
+
this._resizeObserver?.disconnect();
|
|
1041
|
+
}
|
|
1042
|
+
_render() {
|
|
1043
|
+
this._initDimensions();
|
|
1044
|
+
this._initContainers();
|
|
1045
|
+
this._setGenerators();
|
|
1046
|
+
this._setLegend();
|
|
1047
|
+
this._draw();
|
|
1048
|
+
this._initTooltip();
|
|
1049
|
+
}
|
|
1050
|
+
_initDimensions() {
|
|
1051
|
+
const legendContainerWidth = this.showLegend() ? this.legendContainerWidth() : 0;
|
|
1052
|
+
this._hostWidth = this._dimensions.width;
|
|
1053
|
+
this._hostHeight = this._dimensions.height;
|
|
1054
|
+
this._innerWidth = this._dimensions.width - legendContainerWidth - this.dataItemStrokeWidth() * 2;
|
|
1055
|
+
this._innerHeight = this._dimensions.height - this.dataItemStrokeWidth() * 2;
|
|
1056
|
+
this._host = select(this._elementRef.nativeElement);
|
|
1057
|
+
this._svg = this._host.select("svg").attr("viewBox", `0 0 ${this._hostWidth} ${this._hostHeight}`);
|
|
1058
|
+
this._radius = Math.min(this._innerWidth, this._innerHeight) * .5;
|
|
1059
|
+
}
|
|
1060
|
+
_initContainers() {
|
|
1061
|
+
this._dataContainer = this._svg.append("g").attr("class", "data-container").attr("transform", `translate(${this._radius},${this._innerHeight * .5})`);
|
|
1062
|
+
if (this.showLegend()) this._legendContainer = this._svg.append("g").attr("class", "legend-container");
|
|
1063
|
+
}
|
|
1064
|
+
_setGenerators() {
|
|
1065
|
+
const self = this;
|
|
1066
|
+
this._arcGenerator = arc().innerRadius(0).outerRadius(this._radius);
|
|
1067
|
+
this._pieGenerator = pie().value(this.valueAccessor());
|
|
1068
|
+
this._colorsGenerator = scaleOrdinal(schemeTableau10).domain(this.data().map((d, i) => i.toString()));
|
|
1069
|
+
this._arcTweenGenerator = function(d) {
|
|
1070
|
+
const _this = this;
|
|
1071
|
+
const current = d;
|
|
1072
|
+
const interpolateGenerator = interpolate(_this._previous, current);
|
|
1073
|
+
_this._previous = current;
|
|
1074
|
+
return (t) => {
|
|
1075
|
+
return self._arcGenerator(interpolateGenerator(t));
|
|
1076
|
+
};
|
|
1077
|
+
};
|
|
1078
|
+
}
|
|
1079
|
+
_setLegend() {
|
|
1080
|
+
if (!this.showLegend()) return;
|
|
1081
|
+
this._legendContainer.selectAll("g.legend-item").data(this.data()).join("g").attr("class", "legend-item").attr("data-index", (d, i) => i).attr("transform", (d, i) => `translate(0, ${i * this.legendItemHeight()})`).on("mouseenter", (event, d) => {
|
|
1082
|
+
const index = +event.target.getAttribute("data-index");
|
|
1083
|
+
this._dataContainer.select(`path.data-item[data-index="${index}"]`).classed("active", true);
|
|
1084
|
+
}).on("mouseleave", (event, d) => {
|
|
1085
|
+
const index = +event.target.getAttribute("data-index");
|
|
1086
|
+
this._dataContainer.select(`path.data-item[data-index="${index}"]`).classed("active", false);
|
|
1087
|
+
});
|
|
1088
|
+
this._legendContainer.selectAll("g.legend-item").selectAll("text").data((d, i) => [i]).join("text").attr("class", "legend-item-text").attr("x", this.legendItemSymbolSize() * 2).attr("y", this.legendItemHeight() * .5).attr("font-size", this.legendItemFontSize()).text((i) => this.labels()[i]);
|
|
1089
|
+
this._legendContainer.selectAll("g.legend-item").selectAll("rect").data((d, i) => [i]).join("rect").attr("class", "legend-item-symbol").attr("rx", this.legendItemSymbolBorderRadius()).attr("width", this.legendItemSymbolSize()).attr("height", this.legendItemSymbolSize()).attr("fill", (i) => this._colorsGenerator(i)).attr("y", this.legendItemFontSize() * .5 - 2);
|
|
1090
|
+
const dimensions = this._legendContainer.node().getBBox();
|
|
1091
|
+
this._legendContainer.attr("transform", `translate(${this._radius * 2 + this.legendOffset()},${this._innerHeight * .5 - .5 * dimensions.height})`);
|
|
1092
|
+
}
|
|
1093
|
+
_draw(isUpdate = false) {
|
|
1094
|
+
if (isUpdate) this._colorsGenerator.domain(this.data().map((d, i) => i.toString()));
|
|
1095
|
+
this._pieData = this._pieGenerator(this.data());
|
|
1096
|
+
this._dataContainer.selectAll("g.data-item-group").data(this.data()).join("g").attr("class", "data-item-group").attr("data-index", (d, i) => i);
|
|
1097
|
+
this._dataContainer.selectAll("g.data-item-group").selectAll("path").data((d, i) => [this._pieData[i]]).join("path").attr("class", "data-item").attr("stroke-width", this.dataItemStrokeWidth()).attr("d", (d) => this._arcGenerator(d)).style("fill", (d) => this._colorsGenerator(d.index)).attr("data-index", (d) => d.index).transition().duration(this.showDataAnimation() ? 1e3 : 0).attrTween("d", this._arcTweenGenerator);
|
|
1098
|
+
if (this.showValueOnSlices()) this._dataContainer.selectAll("g.data-item-group").selectAll("text").data((d, i) => [this._pieData[i]]).join("text").attr("class", "value").attr("font-size", this.valueFontSize()).attr("transform", (d) => {
|
|
1099
|
+
const coordinates = this._arcGenerator.centroid(d);
|
|
1100
|
+
return `translate(${coordinates[0]},${coordinates[1]})`;
|
|
1101
|
+
}).text((d) => d.data);
|
|
1102
|
+
}
|
|
1103
|
+
_setupResizeObserver() {}
|
|
1104
|
+
_initTooltip() {
|
|
1105
|
+
if (!this.tooltip()) return;
|
|
1106
|
+
let oldValue;
|
|
1107
|
+
this._createTooltipOrigin();
|
|
1108
|
+
this._dataContainer.selectAll("g.data-item-group").data(this._pieData).on("mousemove", (event, d) => {
|
|
1109
|
+
const target = event.target;
|
|
1110
|
+
this._setTooltipPositionByEvent(event);
|
|
1111
|
+
this._setTooltipVisible();
|
|
1112
|
+
const index = +target.getAttribute("data-index");
|
|
1113
|
+
const label = this.labels()[index] ? this.labels()[index] : null;
|
|
1114
|
+
const color = this._colorsGenerator(index);
|
|
1115
|
+
const value = d.data;
|
|
1116
|
+
if (!this._overlayRef?.hasAttached()) {
|
|
1117
|
+
this._showTooltip({
|
|
1118
|
+
label,
|
|
1119
|
+
color,
|
|
1120
|
+
value
|
|
1121
|
+
});
|
|
1122
|
+
oldValue = value;
|
|
1123
|
+
} else if (oldValue !== d.data) {
|
|
1124
|
+
this._showTooltip({
|
|
1125
|
+
label,
|
|
1126
|
+
color,
|
|
1127
|
+
value
|
|
1128
|
+
});
|
|
1129
|
+
oldValue = value;
|
|
1130
|
+
} else this._overlayRef.updatePosition();
|
|
1131
|
+
});
|
|
1132
|
+
this._dataContainer.on("mouseleave", (event) => {
|
|
1133
|
+
this._setTooltipInVisible();
|
|
1134
|
+
this._hideTooltip();
|
|
1135
|
+
});
|
|
1136
|
+
}
|
|
1137
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1138
|
+
minVersion: "12.0.0",
|
|
1139
|
+
version: "22.3.0",
|
|
1140
|
+
ngImport: i0,
|
|
1141
|
+
type: MchartPie,
|
|
1142
|
+
deps: null,
|
|
1143
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
1144
|
+
});
|
|
1145
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
1146
|
+
minVersion: "17.1.0",
|
|
1147
|
+
version: "22.3.0",
|
|
1148
|
+
type: MchartPie,
|
|
1149
|
+
isStandalone: true,
|
|
1150
|
+
selector: "ngs-mchart-pie",
|
|
1151
|
+
inputs: {
|
|
1152
|
+
data: {
|
|
1153
|
+
classPropertyName: "data",
|
|
1154
|
+
publicName: "data",
|
|
1155
|
+
isSignal: true,
|
|
1156
|
+
isRequired: false,
|
|
1157
|
+
transformFunction: null
|
|
1158
|
+
},
|
|
1159
|
+
labels: {
|
|
1160
|
+
classPropertyName: "labels",
|
|
1161
|
+
publicName: "labels",
|
|
1162
|
+
isSignal: true,
|
|
1163
|
+
isRequired: false,
|
|
1164
|
+
transformFunction: null
|
|
1165
|
+
},
|
|
1166
|
+
valueAccessor: {
|
|
1167
|
+
classPropertyName: "valueAccessor",
|
|
1168
|
+
publicName: "valueAccessor",
|
|
1169
|
+
isSignal: true,
|
|
1170
|
+
isRequired: false,
|
|
1171
|
+
transformFunction: null
|
|
1172
|
+
},
|
|
1173
|
+
dataItemStrokeWidth: {
|
|
1174
|
+
classPropertyName: "dataItemStrokeWidth",
|
|
1175
|
+
publicName: "dataItemStrokeWidth",
|
|
1176
|
+
isSignal: true,
|
|
1177
|
+
isRequired: false,
|
|
1178
|
+
transformFunction: null
|
|
1179
|
+
},
|
|
1180
|
+
legendContainerWidth: {
|
|
1181
|
+
classPropertyName: "legendContainerWidth",
|
|
1182
|
+
publicName: "legendContainerWidth",
|
|
1183
|
+
isSignal: true,
|
|
1184
|
+
isRequired: false,
|
|
1185
|
+
transformFunction: null
|
|
1186
|
+
},
|
|
1187
|
+
showDataAnimation: {
|
|
1188
|
+
classPropertyName: "showDataAnimation",
|
|
1189
|
+
publicName: "showDataAnimation",
|
|
1190
|
+
isSignal: true,
|
|
1191
|
+
isRequired: false,
|
|
1192
|
+
transformFunction: null
|
|
1193
|
+
},
|
|
1194
|
+
showValueOnSlices: {
|
|
1195
|
+
classPropertyName: "showValueOnSlices",
|
|
1196
|
+
publicName: "showValueOnSlices",
|
|
1197
|
+
isSignal: true,
|
|
1198
|
+
isRequired: false,
|
|
1199
|
+
transformFunction: null
|
|
1200
|
+
},
|
|
1201
|
+
showLegend: {
|
|
1202
|
+
classPropertyName: "showLegend",
|
|
1203
|
+
publicName: "showLegend",
|
|
1204
|
+
isSignal: true,
|
|
1205
|
+
isRequired: false,
|
|
1206
|
+
transformFunction: null
|
|
1207
|
+
},
|
|
1208
|
+
legendOffset: {
|
|
1209
|
+
classPropertyName: "legendOffset",
|
|
1210
|
+
publicName: "legendOffset",
|
|
1211
|
+
isSignal: true,
|
|
1212
|
+
isRequired: false,
|
|
1213
|
+
transformFunction: null
|
|
1214
|
+
},
|
|
1215
|
+
legendItemHeight: {
|
|
1216
|
+
classPropertyName: "legendItemHeight",
|
|
1217
|
+
publicName: "legendItemHeight",
|
|
1218
|
+
isSignal: true,
|
|
1219
|
+
isRequired: false,
|
|
1220
|
+
transformFunction: null
|
|
1221
|
+
},
|
|
1222
|
+
legendItemSymbolSize: {
|
|
1223
|
+
classPropertyName: "legendItemSymbolSize",
|
|
1224
|
+
publicName: "legendItemSymbolSize",
|
|
1225
|
+
isSignal: true,
|
|
1226
|
+
isRequired: false,
|
|
1227
|
+
transformFunction: null
|
|
1228
|
+
},
|
|
1229
|
+
legendItemFontSize: {
|
|
1230
|
+
classPropertyName: "legendItemFontSize",
|
|
1231
|
+
publicName: "legendItemFontSize",
|
|
1232
|
+
isSignal: true,
|
|
1233
|
+
isRequired: false,
|
|
1234
|
+
transformFunction: null
|
|
1235
|
+
},
|
|
1236
|
+
legendItemSymbolBorderRadius: {
|
|
1237
|
+
classPropertyName: "legendItemSymbolBorderRadius",
|
|
1238
|
+
publicName: "legendItemSymbolBorderRadius",
|
|
1239
|
+
isSignal: true,
|
|
1240
|
+
isRequired: false,
|
|
1241
|
+
transformFunction: null
|
|
1242
|
+
},
|
|
1243
|
+
valueFontSize: {
|
|
1244
|
+
classPropertyName: "valueFontSize",
|
|
1245
|
+
publicName: "valueFontSize",
|
|
1246
|
+
isSignal: true,
|
|
1247
|
+
isRequired: false,
|
|
1248
|
+
transformFunction: null
|
|
1249
|
+
},
|
|
1250
|
+
tooltip: {
|
|
1251
|
+
classPropertyName: "tooltip",
|
|
1252
|
+
publicName: "tooltip",
|
|
1253
|
+
isSignal: true,
|
|
1254
|
+
isRequired: false,
|
|
1255
|
+
transformFunction: null
|
|
1256
|
+
},
|
|
1257
|
+
tooltipPosition: {
|
|
1258
|
+
classPropertyName: "tooltipPosition",
|
|
1259
|
+
publicName: "tooltipPosition",
|
|
1260
|
+
isSignal: true,
|
|
1261
|
+
isRequired: false,
|
|
1262
|
+
transformFunction: null
|
|
1263
|
+
}
|
|
1264
|
+
},
|
|
1265
|
+
host: { classAttribute: "ngs-mchart-pie" },
|
|
1266
|
+
exportAs: ["ngsMchartPie"],
|
|
1267
|
+
usesInheritance: true,
|
|
1268
|
+
usesOnChanges: true,
|
|
1269
|
+
ngImport: i0,
|
|
1270
|
+
template: "<svg></svg>\n",
|
|
1271
|
+
styles: [":host{--ngs-mchart-pie-stroke-color: var(--ngs-color-background);--ngs-mchart-pie-legend-item-color: var(--ngs-color-neutral-900);--ngs-mchart-pie-legend-item-hover-color: var(--ngs-color-primary);--ngs-mchart-pie-value-color: var(--ngs-color-neutral-950);display:block;overflow:hidden}:host svg{width:100%;height:100%}:host:has(.data-item.active) ::ng-deep .data-item:not(.active){opacity:.7;scale:.93;transition:scale .2s}:host ::ng-deep .data-item{stroke:var(--ngs-mchart-pie-stroke-color)}:host ::ng-deep .value{text-anchor:middle;alignment-baseline:middle;fill:var(--ngs-mchart-pie-value-color)}:host ::ng-deep .legend-item{cursor:pointer}:host ::ng-deep .legend-item:hover .legend-item-text{fill:var(--ngs-mchart-pie-legend-item-hover-color)}:host ::ng-deep .legend-item-text{fill:var(--ngs-mchart-pie-legend-item-color)}:host-context(html.dark){--ngs-mchart-pie-legend-item-color: var(--ngs-color-neutral-200)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"],
|
|
1272
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
1273
|
+
});
|
|
1274
|
+
};
|
|
1275
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1276
|
+
minVersion: "12.0.0",
|
|
1277
|
+
version: "22.3.0",
|
|
1278
|
+
ngImport: i0,
|
|
1279
|
+
type: MchartPie,
|
|
1280
|
+
decorators: [{
|
|
1281
|
+
type: Component,
|
|
1282
|
+
args: [{
|
|
1283
|
+
selector: "ngs-mchart-pie",
|
|
1284
|
+
exportAs: "ngsMchartPie",
|
|
1285
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1286
|
+
host: { "class": "ngs-mchart-pie" },
|
|
1287
|
+
template: "<svg></svg>\n",
|
|
1288
|
+
styles: [":host{--ngs-mchart-pie-stroke-color: var(--ngs-color-background);--ngs-mchart-pie-legend-item-color: var(--ngs-color-neutral-900);--ngs-mchart-pie-legend-item-hover-color: var(--ngs-color-primary);--ngs-mchart-pie-value-color: var(--ngs-color-neutral-950);display:block;overflow:hidden}:host svg{width:100%;height:100%}:host:has(.data-item.active) ::ng-deep .data-item:not(.active){opacity:.7;scale:.93;transition:scale .2s}:host ::ng-deep .data-item{stroke:var(--ngs-mchart-pie-stroke-color)}:host ::ng-deep .value{text-anchor:middle;alignment-baseline:middle;fill:var(--ngs-mchart-pie-value-color)}:host ::ng-deep .legend-item{cursor:pointer}:host ::ng-deep .legend-item:hover .legend-item-text{fill:var(--ngs-mchart-pie-legend-item-hover-color)}:host ::ng-deep .legend-item-text{fill:var(--ngs-mchart-pie-legend-item-color)}:host-context(html.dark){--ngs-mchart-pie-legend-item-color: var(--ngs-color-neutral-200)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"]
|
|
1289
|
+
}]
|
|
1290
|
+
}],
|
|
1291
|
+
propDecorators: {
|
|
1292
|
+
data: [{
|
|
1293
|
+
type: i0.Input,
|
|
1294
|
+
args: [{
|
|
1295
|
+
isSignal: true,
|
|
1296
|
+
alias: "data",
|
|
1297
|
+
required: false
|
|
1298
|
+
}]
|
|
1299
|
+
}],
|
|
1300
|
+
labels: [{
|
|
1301
|
+
type: i0.Input,
|
|
1302
|
+
args: [{
|
|
1303
|
+
isSignal: true,
|
|
1304
|
+
alias: "labels",
|
|
1305
|
+
required: false
|
|
1306
|
+
}]
|
|
1307
|
+
}],
|
|
1308
|
+
valueAccessor: [{
|
|
1309
|
+
type: i0.Input,
|
|
1310
|
+
args: [{
|
|
1311
|
+
isSignal: true,
|
|
1312
|
+
alias: "valueAccessor",
|
|
1313
|
+
required: false
|
|
1314
|
+
}]
|
|
1315
|
+
}],
|
|
1316
|
+
dataItemStrokeWidth: [{
|
|
1317
|
+
type: i0.Input,
|
|
1318
|
+
args: [{
|
|
1319
|
+
isSignal: true,
|
|
1320
|
+
alias: "dataItemStrokeWidth",
|
|
1321
|
+
required: false
|
|
1322
|
+
}]
|
|
1323
|
+
}],
|
|
1324
|
+
legendContainerWidth: [{
|
|
1325
|
+
type: i0.Input,
|
|
1326
|
+
args: [{
|
|
1327
|
+
isSignal: true,
|
|
1328
|
+
alias: "legendContainerWidth",
|
|
1329
|
+
required: false
|
|
1330
|
+
}]
|
|
1331
|
+
}],
|
|
1332
|
+
showDataAnimation: [{
|
|
1333
|
+
type: i0.Input,
|
|
1334
|
+
args: [{
|
|
1335
|
+
isSignal: true,
|
|
1336
|
+
alias: "showDataAnimation",
|
|
1337
|
+
required: false
|
|
1338
|
+
}]
|
|
1339
|
+
}],
|
|
1340
|
+
showValueOnSlices: [{
|
|
1341
|
+
type: i0.Input,
|
|
1342
|
+
args: [{
|
|
1343
|
+
isSignal: true,
|
|
1344
|
+
alias: "showValueOnSlices",
|
|
1345
|
+
required: false
|
|
1346
|
+
}]
|
|
1347
|
+
}],
|
|
1348
|
+
showLegend: [{
|
|
1349
|
+
type: i0.Input,
|
|
1350
|
+
args: [{
|
|
1351
|
+
isSignal: true,
|
|
1352
|
+
alias: "showLegend",
|
|
1353
|
+
required: false
|
|
1354
|
+
}]
|
|
1355
|
+
}],
|
|
1356
|
+
legendOffset: [{
|
|
1357
|
+
type: i0.Input,
|
|
1358
|
+
args: [{
|
|
1359
|
+
isSignal: true,
|
|
1360
|
+
alias: "legendOffset",
|
|
1361
|
+
required: false
|
|
1362
|
+
}]
|
|
1363
|
+
}],
|
|
1364
|
+
legendItemHeight: [{
|
|
1365
|
+
type: i0.Input,
|
|
1366
|
+
args: [{
|
|
1367
|
+
isSignal: true,
|
|
1368
|
+
alias: "legendItemHeight",
|
|
1369
|
+
required: false
|
|
1370
|
+
}]
|
|
1371
|
+
}],
|
|
1372
|
+
legendItemSymbolSize: [{
|
|
1373
|
+
type: i0.Input,
|
|
1374
|
+
args: [{
|
|
1375
|
+
isSignal: true,
|
|
1376
|
+
alias: "legendItemSymbolSize",
|
|
1377
|
+
required: false
|
|
1378
|
+
}]
|
|
1379
|
+
}],
|
|
1380
|
+
legendItemFontSize: [{
|
|
1381
|
+
type: i0.Input,
|
|
1382
|
+
args: [{
|
|
1383
|
+
isSignal: true,
|
|
1384
|
+
alias: "legendItemFontSize",
|
|
1385
|
+
required: false
|
|
1386
|
+
}]
|
|
1387
|
+
}],
|
|
1388
|
+
legendItemSymbolBorderRadius: [{
|
|
1389
|
+
type: i0.Input,
|
|
1390
|
+
args: [{
|
|
1391
|
+
isSignal: true,
|
|
1392
|
+
alias: "legendItemSymbolBorderRadius",
|
|
1393
|
+
required: false
|
|
1394
|
+
}]
|
|
1395
|
+
}],
|
|
1396
|
+
valueFontSize: [{
|
|
1397
|
+
type: i0.Input,
|
|
1398
|
+
args: [{
|
|
1399
|
+
isSignal: true,
|
|
1400
|
+
alias: "valueFontSize",
|
|
1401
|
+
required: false
|
|
1402
|
+
}]
|
|
1403
|
+
}],
|
|
1404
|
+
tooltip: [{
|
|
1405
|
+
type: i0.Input,
|
|
1406
|
+
args: [{
|
|
1407
|
+
isSignal: true,
|
|
1408
|
+
alias: "tooltip",
|
|
1409
|
+
required: false
|
|
1410
|
+
}]
|
|
1411
|
+
}],
|
|
1412
|
+
tooltipPosition: [{
|
|
1413
|
+
type: i0.Input,
|
|
1414
|
+
args: [{
|
|
1415
|
+
isSignal: true,
|
|
1416
|
+
alias: "tooltipPosition",
|
|
1417
|
+
required: false
|
|
1418
|
+
}]
|
|
1419
|
+
}]
|
|
1420
|
+
}
|
|
1421
|
+
});
|
|
1422
|
+
var MchartTooltip = class MchartTooltip {
|
|
1423
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1424
|
+
minVersion: "12.0.0",
|
|
1425
|
+
version: "22.3.0",
|
|
1426
|
+
ngImport: i0,
|
|
1427
|
+
type: MchartTooltip,
|
|
1428
|
+
deps: [],
|
|
1429
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
1430
|
+
});
|
|
1431
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
1432
|
+
minVersion: "14.0.0",
|
|
1433
|
+
version: "22.3.0",
|
|
1434
|
+
type: MchartTooltip,
|
|
1435
|
+
isStandalone: true,
|
|
1436
|
+
selector: "ngs-mchart-tooltip",
|
|
1437
|
+
host: { classAttribute: "ngs-mchart-tooltip" },
|
|
1438
|
+
exportAs: ["ngsMchartTooltip"],
|
|
1439
|
+
ngImport: i0,
|
|
1440
|
+
template: "<div class=\"title\">\n <ng-content select=\"ngs-mchart-tooltip-title\" />\n</div>\n<div class=\"body\">\n <ng-content select=\"ngs-mchart-tooltip-body\" />\n</div>\n<ng-content />\n",
|
|
1441
|
+
styles: [":host{display:block;width:max-content;box-shadow:var(--ngs-shadow-sm);border-radius:var(--ngs-radius-lg);background:#fff;font-size:var(--ngs-font-size-xs);overflow:hidden}:host .title:empty{display:none}:host .body:empty{display:none}:host-context(html.dark){background:var(--ngs-color-tertiary-200);color:var(--ngs-color-neutral-800)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"],
|
|
1442
|
+
changeDetection: i0.ChangeDetectionStrategy.Eager
|
|
1443
|
+
});
|
|
1444
|
+
};
|
|
1445
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1446
|
+
minVersion: "12.0.0",
|
|
1447
|
+
version: "22.3.0",
|
|
1448
|
+
ngImport: i0,
|
|
1449
|
+
type: MchartTooltip,
|
|
1450
|
+
decorators: [{
|
|
1451
|
+
type: Component,
|
|
1452
|
+
args: [{
|
|
1453
|
+
selector: "ngs-mchart-tooltip",
|
|
1454
|
+
exportAs: "ngsMchartTooltip",
|
|
1455
|
+
changeDetection: ChangeDetectionStrategy.Eager,
|
|
1456
|
+
host: { "class": "ngs-mchart-tooltip" },
|
|
1457
|
+
template: "<div class=\"title\">\n <ng-content select=\"ngs-mchart-tooltip-title\" />\n</div>\n<div class=\"body\">\n <ng-content select=\"ngs-mchart-tooltip-body\" />\n</div>\n<ng-content />\n",
|
|
1458
|
+
styles: [":host{display:block;width:max-content;box-shadow:var(--ngs-shadow-sm);border-radius:var(--ngs-radius-lg);background:#fff;font-size:var(--ngs-font-size-xs);overflow:hidden}:host .title:empty{display:none}:host .body:empty{display:none}:host-context(html.dark){background:var(--ngs-color-tertiary-200);color:var(--ngs-color-neutral-800)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"]
|
|
1459
|
+
}]
|
|
1460
|
+
}]
|
|
1461
|
+
});
|
|
1462
|
+
var MchartTooltipTitle = class MchartTooltipTitle {
|
|
1463
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1464
|
+
minVersion: "12.0.0",
|
|
1465
|
+
version: "22.3.0",
|
|
1466
|
+
ngImport: i0,
|
|
1467
|
+
type: MchartTooltipTitle,
|
|
1468
|
+
deps: [],
|
|
1469
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
1470
|
+
});
|
|
1471
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
1472
|
+
minVersion: "14.0.0",
|
|
1473
|
+
version: "22.3.0",
|
|
1474
|
+
type: MchartTooltipTitle,
|
|
1475
|
+
isStandalone: true,
|
|
1476
|
+
selector: "ngs-mchart-tooltip-title",
|
|
1477
|
+
host: { classAttribute: "ngs-mchart-tooltip-title" },
|
|
1478
|
+
exportAs: ["ngsMchartTooltipTitle"],
|
|
1479
|
+
ngImport: i0,
|
|
1480
|
+
template: "<ng-content />\n",
|
|
1481
|
+
styles: [":host{display:block;background:var(--ngs-color-neutral-200);padding:calc(var(--spacing, .25rem) * 1.5) calc(var(--spacing, .25rem) * 2);font-weight:500}:host-context(html.dark){background:var(--ngs-color-neutral-300);color:var(--ngs-color-neutral-900)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"],
|
|
1482
|
+
changeDetection: i0.ChangeDetectionStrategy.Eager
|
|
1483
|
+
});
|
|
1484
|
+
};
|
|
1485
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1486
|
+
minVersion: "12.0.0",
|
|
1487
|
+
version: "22.3.0",
|
|
1488
|
+
ngImport: i0,
|
|
1489
|
+
type: MchartTooltipTitle,
|
|
1490
|
+
decorators: [{
|
|
1491
|
+
type: Component,
|
|
1492
|
+
args: [{
|
|
1493
|
+
selector: "ngs-mchart-tooltip-title",
|
|
1494
|
+
exportAs: "ngsMchartTooltipTitle",
|
|
1495
|
+
changeDetection: ChangeDetectionStrategy.Eager,
|
|
1496
|
+
host: { "class": "ngs-mchart-tooltip-title" },
|
|
1497
|
+
template: "<ng-content />\n",
|
|
1498
|
+
styles: [":host{display:block;background:var(--ngs-color-neutral-200);padding:calc(var(--spacing, .25rem) * 1.5) calc(var(--spacing, .25rem) * 2);font-weight:500}:host-context(html.dark){background:var(--ngs-color-neutral-300);color:var(--ngs-color-neutral-900)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"]
|
|
1499
|
+
}]
|
|
1500
|
+
}]
|
|
1501
|
+
});
|
|
1502
|
+
var MchartTooltipBody = class MchartTooltipBody {
|
|
1503
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
1504
|
+
minVersion: "12.0.0",
|
|
1505
|
+
version: "22.3.0",
|
|
1506
|
+
ngImport: i0,
|
|
1507
|
+
type: MchartTooltipBody,
|
|
1508
|
+
deps: [],
|
|
1509
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
1510
|
+
});
|
|
1511
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
1512
|
+
minVersion: "14.0.0",
|
|
1513
|
+
version: "22.3.0",
|
|
1514
|
+
type: MchartTooltipBody,
|
|
1515
|
+
isStandalone: true,
|
|
1516
|
+
selector: "ngs-mchart-tooltip-body",
|
|
1517
|
+
host: { classAttribute: "ngs-mchart-tooltip-body" },
|
|
1518
|
+
exportAs: ["ngsMchartTooltipBody"],
|
|
1519
|
+
ngImport: i0,
|
|
1520
|
+
template: "<ng-content />\n",
|
|
1521
|
+
styles: [":host{display:block;padding:calc(var(--spacing, .25rem) * 1.5) calc(var(--spacing, .25rem) * 2)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"],
|
|
1522
|
+
changeDetection: i0.ChangeDetectionStrategy.Eager
|
|
1523
|
+
});
|
|
1524
|
+
};
|
|
1525
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1526
|
+
minVersion: "12.0.0",
|
|
1527
|
+
version: "22.3.0",
|
|
1528
|
+
ngImport: i0,
|
|
1529
|
+
type: MchartTooltipBody,
|
|
1530
|
+
decorators: [{
|
|
1531
|
+
type: Component,
|
|
1532
|
+
args: [{
|
|
1533
|
+
selector: "ngs-mchart-tooltip-body",
|
|
1534
|
+
exportAs: "ngsMchartTooltipBody",
|
|
1535
|
+
changeDetection: ChangeDetectionStrategy.Eager,
|
|
1536
|
+
host: { "class": "ngs-mchart-tooltip-body" },
|
|
1537
|
+
template: "<ng-content />\n",
|
|
1538
|
+
styles: [":host{display:block;padding:calc(var(--spacing, .25rem) * 1.5) calc(var(--spacing, .25rem) * 2)}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"]
|
|
1539
|
+
}]
|
|
1540
|
+
}]
|
|
1541
|
+
});
|
|
945
1542
|
export { MchartBar, MchartLine, MchartPie, MchartTooltip, MchartTooltipBody, MchartTooltipTitle };
|
|
946
|
-
|
|
1543
|
+
|
|
1544
|
+
//# sourceMappingURL=ngstarter-ui-components-micro-chart.mjs.map
|