@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
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { n as CONTENT_EDITOR_DEFAULT_HTML_CONVERTERS } from "./default-converters-9oSKDsXP.mjs";
|
|
2
|
+
import { createNgsHeadlessEditorId, createNgsHeadlessEditorText } from "@ngstarter-ui/components/headless-editor";
|
|
3
|
+
const CONTENT_EDITOR_EXTRA_BLOCK_DEFS = [
|
|
4
|
+
{
|
|
5
|
+
type: "callout",
|
|
6
|
+
component: () => import("./callout-block-Bl4GZYz8.mjs").then((m) => m.ContentEditorCalloutBlock),
|
|
7
|
+
empty: () => ({
|
|
8
|
+
content: [createNgsHeadlessEditorText()],
|
|
9
|
+
settings: { variant: "note" }
|
|
10
|
+
}),
|
|
11
|
+
options: {}
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
type: "toggle",
|
|
15
|
+
component: () => import("./toggle-block-C5Jo2YDf.mjs").then((m) => m.ContentEditorToggleBlock),
|
|
16
|
+
empty: () => ({
|
|
17
|
+
content: {
|
|
18
|
+
title: [],
|
|
19
|
+
blocks: [emptyParagraph()]
|
|
20
|
+
},
|
|
21
|
+
settings: { expanded: true }
|
|
22
|
+
}),
|
|
23
|
+
options: {}
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
type: "attachment",
|
|
27
|
+
component: () => import("./attachment-block-BK9QxVjq.mjs").then((m) => m.ContentEditorAttachmentBlock),
|
|
28
|
+
empty: () => ({
|
|
29
|
+
content: {
|
|
30
|
+
url: "",
|
|
31
|
+
name: "",
|
|
32
|
+
size: 0,
|
|
33
|
+
mimeType: ""
|
|
34
|
+
},
|
|
35
|
+
settings: {}
|
|
36
|
+
}),
|
|
37
|
+
options: { uploadFn: (_file, dataUrl) => Promise.resolve(dataUrl) }
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
type: "gallery",
|
|
41
|
+
component: () => import("./gallery-block-DT3uIURY.mjs").then((m) => m.ContentEditorGalleryBlock),
|
|
42
|
+
empty: () => ({
|
|
43
|
+
content: { images: [] },
|
|
44
|
+
settings: {}
|
|
45
|
+
}),
|
|
46
|
+
options: { uploadFn: (_file, dataUrl) => Promise.resolve(dataUrl) }
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
type: "grid",
|
|
50
|
+
component: () => import("./grid-block-ZVDT3m8-.mjs").then((m) => m.ContentEditorGridBlock),
|
|
51
|
+
empty: () => ({
|
|
52
|
+
content: { cells: Array.from({ length: 4 }, emptyGridCell) },
|
|
53
|
+
settings: {
|
|
54
|
+
columns: 2,
|
|
55
|
+
gap: "medium",
|
|
56
|
+
stackOnMobile: true
|
|
57
|
+
}
|
|
58
|
+
}),
|
|
59
|
+
options: {}
|
|
60
|
+
}
|
|
61
|
+
].map((def) => ({
|
|
62
|
+
...def,
|
|
63
|
+
toHtml: CONTENT_EDITOR_DEFAULT_HTML_CONVERTERS[def.type]
|
|
64
|
+
}));
|
|
65
|
+
function emptyParagraph() {
|
|
66
|
+
return {
|
|
67
|
+
id: createNgsHeadlessEditorId("paragraph"),
|
|
68
|
+
type: "paragraph",
|
|
69
|
+
content: [createNgsHeadlessEditorText()]
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
function emptyGridCell() {
|
|
73
|
+
return {
|
|
74
|
+
id: createNgsHeadlessEditorId("cell"),
|
|
75
|
+
blocks: [emptyParagraph()]
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
const CONTENT_EDITOR_EXTRA_SUGGESTIONS = [{
|
|
79
|
+
type: "heading",
|
|
80
|
+
title: "Content & layout"
|
|
81
|
+
}, ...[
|
|
82
|
+
[
|
|
83
|
+
"callout",
|
|
84
|
+
"Callout",
|
|
85
|
+
"Notes, tips and warnings",
|
|
86
|
+
"fluent:info-24-regular"
|
|
87
|
+
],
|
|
88
|
+
[
|
|
89
|
+
"toggle",
|
|
90
|
+
"Toggle",
|
|
91
|
+
"Collapsible content with nested blocks",
|
|
92
|
+
"fluent:chevron-down-24-regular"
|
|
93
|
+
],
|
|
94
|
+
[
|
|
95
|
+
"attachment",
|
|
96
|
+
"Attachment",
|
|
97
|
+
"Upload a file for download",
|
|
98
|
+
"fluent:attach-24-regular"
|
|
99
|
+
],
|
|
100
|
+
[
|
|
101
|
+
"gallery",
|
|
102
|
+
"Gallery",
|
|
103
|
+
"Image carousel with captions",
|
|
104
|
+
"fluent:image-multiple-24-regular"
|
|
105
|
+
],
|
|
106
|
+
[
|
|
107
|
+
"grid",
|
|
108
|
+
"Grid",
|
|
109
|
+
"Responsive grid with nested blocks",
|
|
110
|
+
"fluent:grid-24-regular"
|
|
111
|
+
]
|
|
112
|
+
].map(([blockType, title, description, iconName]) => ({
|
|
113
|
+
type: "item",
|
|
114
|
+
blockType,
|
|
115
|
+
title,
|
|
116
|
+
description,
|
|
117
|
+
iconName,
|
|
118
|
+
blockSettings: {}
|
|
119
|
+
}))];
|
|
120
|
+
export { CONTENT_EDITOR_EXTRA_SUGGESTIONS as n, emptyGridCell as r, CONTENT_EDITOR_EXTRA_BLOCK_DEFS as t };
|
|
121
|
+
|
|
122
|
+
//# sourceMappingURL=extra-block-defs-Cn_hfM3c.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extra-block-defs-Cn_hfM3c.mjs","names":[],"sources":["../../../projects/components/content-editor/src/extra-block-defs.ts"],"sourcesContent":["import { createNgsHeadlessEditorId, createNgsHeadlessEditorText } from '@ngstarter-ui/components/headless-editor';\nimport { ContentEditorBlockDef } from './types';\nimport { CONTENT_EDITOR_DEFAULT_HTML_CONVERTERS } from './html/default-converters';\n\nexport const CONTENT_EDITOR_EXTRA_BLOCK_DEFS: ContentEditorBlockDef[] = [\n {\n type: 'callout', component: () => import('./_builder/callout-block/callout-block').then(m => m.ContentEditorCalloutBlock),\n empty: () => ({ content: [createNgsHeadlessEditorText()], settings: { variant: 'note' } }), options: {}\n },\n {\n type: 'toggle', component: () => import('./_builder/toggle-block/toggle-block').then(m => m.ContentEditorToggleBlock),\n empty: () => ({ content: { title: [], blocks: [emptyParagraph()] }, settings: { expanded: true } }), options: {}\n },\n {\n type: 'attachment', component: () => import('./_builder/attachment-block/attachment-block').then(m => m.ContentEditorAttachmentBlock),\n empty: () => ({ content: { url: '', name: '', size: 0, mimeType: '' }, settings: {} }),\n options: { uploadFn: (_file: File, dataUrl: string) => Promise.resolve(dataUrl) }\n },\n {\n type: 'gallery', component: () => import('./_builder/gallery-block/gallery-block').then(m => m.ContentEditorGalleryBlock),\n empty: () => ({ content: { images: [] }, settings: {} }),\n options: { uploadFn: (_file: File, dataUrl: string) => Promise.resolve(dataUrl) }\n },\n {\n type: 'grid', component: () => import('./_builder/grid-block/grid-block').then(m => m.ContentEditorGridBlock),\n empty: () => ({ content: { cells: Array.from({ length: 4 }, emptyGridCell) }, settings: { columns: 2, gap: 'medium', stackOnMobile: true } }), options: {}\n }\n].map(def => ({ ...def, toHtml: CONTENT_EDITOR_DEFAULT_HTML_CONVERTERS[def.type] }));\n\nexport function emptyParagraph() {\n return { id: createNgsHeadlessEditorId('paragraph'), type: 'paragraph', content: [createNgsHeadlessEditorText()] };\n}\nexport function emptyGridCell() { return { id: createNgsHeadlessEditorId('cell'), blocks: [emptyParagraph()] }; }\n\nexport const CONTENT_EDITOR_EXTRA_SUGGESTIONS = [\n { type: 'heading', title: 'Content & layout' },\n ...[\n ['callout', 'Callout', 'Notes, tips and warnings', 'fluent:info-24-regular'],\n ['toggle', 'Toggle', 'Collapsible content with nested blocks', 'fluent:chevron-down-24-regular'],\n ['attachment', 'Attachment', 'Upload a file for download', 'fluent:attach-24-regular'],\n ['gallery', 'Gallery', 'Image carousel with captions', 'fluent:image-multiple-24-regular'],\n ['grid', 'Grid', 'Responsive grid with nested blocks', 'fluent:grid-24-regular']\n ].map(([blockType, title, description, iconName]) => ({ type: 'item', blockType, title, description, iconName, blockSettings: {} }))\n];\n"],"mappings":";;AAIA,MAAa,kCAA2D;CACtE;EACE,MAAM;EAAW,iBAAiB,OAAO,+BAAyC,CAAC,MAAK,MAAK,EAAE,yBAAyB;EACxH,cAAc;GAAE,SAAS,CAAC,4BAA2B,CAAE;GAAG,UAAU,EAAE,SAAS,OAAM;EAAE;EAAK,SAAS,CAAA;CACtG;CACD;EACE,MAAM;EAAU,iBAAiB,OAAO,8BAAuC,CAAC,MAAK,MAAK,EAAE,wBAAwB;EACpH,cAAc;GAAE,SAAS;IAAE,OAAO,CAAA;IAAI,QAAQ,CAAC,eAAc,CAAE;GAAC;GAAI,UAAU,EAAE,UAAU,KAAI;EAAE;EAAK,SAAS,CAAA;CAC/G;CACD;EACE,MAAM;EAAc,iBAAiB,OAAO,kCAA+C,CAAC,MAAK,MAAK,EAAE,4BAA4B;EACpI,cAAc;GAAE,SAAS;IAAE,KAAK;IAAI,MAAM;IAAI,MAAM;IAAG,UAAU;GAAE;GAAI,UAAU,CAAA;EAAE;EACnF,SAAS,EAAE,WAAW,OAAa,YAAoB,QAAQ,QAAQ,OAAO,EAAC;CAChF;CACD;EACE,MAAM;EAAW,iBAAiB,OAAO,+BAAyC,CAAC,MAAK,MAAK,EAAE,yBAAyB;EACxH,cAAc;GAAE,SAAS,EAAE,QAAQ,CAAA,EAAE;GAAI,UAAU,CAAA;EAAE;EACrD,SAAS,EAAE,WAAW,OAAa,YAAoB,QAAQ,QAAQ,OAAO,EAAC;CAChF;CACD;EACE,MAAM;EAAQ,iBAAiB,OAAO,4BAAmC,CAAC,MAAK,MAAK,EAAE,sBAAsB;EAC5G,cAAc;GAAE,SAAS,EAAE,OAAO,MAAM,KAAK,EAAE,QAAQ,EAAC,GAAI,aAAa,EAAC;GAAI,UAAU;IAAE,SAAS;IAAG,KAAK;IAAU,eAAe;GAAI;EAAE;EAAK,SAAS,CAAA;CACzJ;AACF,CAAA,CAAC,KAAI,SAAQ;CAAE,GAAG;CAAK,QAAQ,uCAAuC,IAAI;AAAK,EAAG;AAEnF,SAAgB,iBAAc;CAC5B,OAAO;EAAE,IAAI,0BAA0B,WAAW;EAAG,MAAM;EAAa,SAAS,CAAC,4BAA2B,CAAE;CAAC;AAClH;AACA,SAAgB,gBAAa;CAAK,OAAO;EAAE,IAAI,0BAA0B,MAAM;EAAG,QAAQ,CAAC,eAAc,CAAE;CAAC;AAAI;AAEhH,MAAa,mCAAmC,CAC9C;CAAE,MAAM;CAAW,OAAO;AAAkB,GAC5C,GAAG;CACD;EAAC;EAAW;EAAW;EAA4B;CAAwB;CAC3E;EAAC;EAAU;EAAU;EAA0C;CAAgC;CAC/F;EAAC;EAAc;EAAc;EAA8B;CAA0B;CACrF;EAAC;EAAW;EAAW;EAAgC;CAAkC;CACzF;EAAC;EAAQ;EAAQ;EAAsC;CAAwB;AAChF,CAAA,CAAC,KAAK,CAAC,WAAW,OAAO,aAAa,eAAe;CAAE,MAAM;CAAQ;CAAW;CAAO;CAAa;CAAU,eAAe,CAAA;AAAE,EAAG,CACpI"}
|
|
@@ -0,0 +1,365 @@
|
|
|
1
|
+
import { ContentEditorUploadBlockBase } from "./ngstarter-ui-components-content-editor.mjs";
|
|
2
|
+
import { f as contentEditorText } from "./content-builder.store-D622mHxt.mjs";
|
|
3
|
+
import { t as ContentEditorUploadStatus } from "./upload-status-tZ0x0BUB.mjs";
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
import { ChangeDetectionStrategy, Component, computed, linkedSignal, signal } from "@angular/core";
|
|
6
|
+
import { Icon } from "@ngstarter-ui/components/icon";
|
|
7
|
+
import { Button } from "@ngstarter-ui/components/button";
|
|
8
|
+
import { FormField, Hint, Label } from "@ngstarter-ui/components/form-field";
|
|
9
|
+
import { Input as Input$1 } from "@ngstarter-ui/components/input";
|
|
10
|
+
import { createNgsHeadlessEditorId, createNgsHeadlessEditorText } from "@ngstarter-ui/components/headless-editor";
|
|
11
|
+
import { UploadArea, UploadTriggerDirective } from "@ngstarter-ui/components/upload";
|
|
12
|
+
import { Menu, MenuDivider, MenuItem, MenuTrigger } from "@ngstarter-ui/components/menu";
|
|
13
|
+
import { CdkDrag, CdkDragHandle, CdkDropList, moveItemInArray } from "@angular/cdk/drag-drop";
|
|
14
|
+
import { ImageViewerDirective, ImageViewerPictureDirective } from "@ngstarter-ui/components/image-viewer";
|
|
15
|
+
var ContentEditorGalleryBlock = class ContentEditorGalleryBlock extends ContentEditorUploadBlockBase {
|
|
16
|
+
images = computed(() => this.content().images, ...ngDevMode ? [{ debugName: "images" }] : /* istanbul ignore next */ []);
|
|
17
|
+
selectedId = linkedSignal({
|
|
18
|
+
...ngDevMode ? { debugName: "selectedId" } : /* istanbul ignore next */ {},
|
|
19
|
+
source: this.images,
|
|
20
|
+
computation: (images, previous) => {
|
|
21
|
+
if (images.some((image) => image.id === previous?.value)) return previous.value;
|
|
22
|
+
const previousIndex = previous?.source.findIndex((image) => image.id === previous.value) ?? 0;
|
|
23
|
+
return images[Math.min(Math.max(previousIndex, 0), images.length - 1)]?.id ?? null;
|
|
24
|
+
}
|
|
25
|
+
});
|
|
26
|
+
selectedIndex = computed(() => this.images().findIndex((image) => image.id === this.selectedId()), ...ngDevMode ? [{ debugName: "selectedIndex" }] : /* istanbul ignore next */ []);
|
|
27
|
+
selectedImage = computed(() => this.images()[this.selectedIndex()] ?? null, ...ngDevMode ? [{ debugName: "selectedImage" }] : /* istanbul ignore next */ []);
|
|
28
|
+
replacementId = signal(null, ...ngDevMode ? [{ debugName: "replacementId" }] : /* istanbul ignore next */ []);
|
|
29
|
+
captionText = contentEditorText;
|
|
30
|
+
selectImage(id) {
|
|
31
|
+
this.selectedId.set(id);
|
|
32
|
+
}
|
|
33
|
+
previousImage() {
|
|
34
|
+
const image = this.images()[this.selectedIndex() - 1];
|
|
35
|
+
if (image) this.selectImage(image.id);
|
|
36
|
+
}
|
|
37
|
+
nextImage() {
|
|
38
|
+
const image = this.images()[this.selectedIndex() + 1];
|
|
39
|
+
if (image) this.selectImage(image.id);
|
|
40
|
+
}
|
|
41
|
+
changeAlt(id, event) {
|
|
42
|
+
this.changeImage(id, { alt: event.target.value });
|
|
43
|
+
}
|
|
44
|
+
changeCaption(id, caption) {
|
|
45
|
+
this.changeImage(id, { caption: [createNgsHeadlessEditorText(caption)] });
|
|
46
|
+
}
|
|
47
|
+
changeImage(id, data) {
|
|
48
|
+
this.save({ images: this.latestContent().images.map((image) => image.id === id ? {
|
|
49
|
+
...image,
|
|
50
|
+
...data
|
|
51
|
+
} : image) });
|
|
52
|
+
}
|
|
53
|
+
removeImage(id) {
|
|
54
|
+
this.save({ images: this.latestContent().images.filter((image) => image.id !== id) });
|
|
55
|
+
}
|
|
56
|
+
moveImage(index, direction) {
|
|
57
|
+
this.reorderImage(index, index + direction);
|
|
58
|
+
}
|
|
59
|
+
dropImage(event) {
|
|
60
|
+
this.reorderImage(event.previousIndex, event.currentIndex);
|
|
61
|
+
}
|
|
62
|
+
reorderImage(from, to) {
|
|
63
|
+
const images = [...this.latestContent().images];
|
|
64
|
+
if (from < 0 || to < 0 || from >= images.length || to >= images.length || from === to) return;
|
|
65
|
+
moveItemInArray(images, from, to);
|
|
66
|
+
this.save({ images });
|
|
67
|
+
}
|
|
68
|
+
requestReplacement(id, trigger) {
|
|
69
|
+
this.replacementId.set(id);
|
|
70
|
+
trigger._handleClick();
|
|
71
|
+
}
|
|
72
|
+
async upload(event, replaceId = null) {
|
|
73
|
+
const files = replaceId ? event.files.slice(0, 1) : event.files;
|
|
74
|
+
await this.uploadFiles("gallery", {
|
|
75
|
+
files,
|
|
76
|
+
accept: (file) => file.type.startsWith("image/"),
|
|
77
|
+
apply: (results) => {
|
|
78
|
+
const images = results.map(({ url, file }) => ({
|
|
79
|
+
id: createNgsHeadlessEditorId("image"),
|
|
80
|
+
src: url,
|
|
81
|
+
alt: file.name,
|
|
82
|
+
caption: []
|
|
83
|
+
}));
|
|
84
|
+
if (replaceId) this.changeImage(replaceId, { src: images[0].src });
|
|
85
|
+
else {
|
|
86
|
+
this.save({ images: [...this.latestContent().images, ...images] });
|
|
87
|
+
this.selectImage(images[0].id);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
93
|
+
minVersion: "12.0.0",
|
|
94
|
+
version: "22.3.0",
|
|
95
|
+
ngImport: i0,
|
|
96
|
+
type: ContentEditorGalleryBlock,
|
|
97
|
+
deps: null,
|
|
98
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
99
|
+
});
|
|
100
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
101
|
+
minVersion: "17.0.0",
|
|
102
|
+
version: "22.3.0",
|
|
103
|
+
type: ContentEditorGalleryBlock,
|
|
104
|
+
isStandalone: true,
|
|
105
|
+
selector: "ngs-content-editor-gallery-block",
|
|
106
|
+
usesInheritance: true,
|
|
107
|
+
ngImport: i0,
|
|
108
|
+
template: "<div class=\"flex min-w-0 flex-col gap-4 p-3 sm:p-4\">\n <div class=\"flex flex-wrap items-center gap-3\">\n <span class=\"text-base font-semibold\">Carousel</span>\n <span class=\"text-sm text-on-surface-variant\">{{ images().length }} {{ images().length === 1 ? 'image' : 'images' }}</span>\n </div>\n @if (selectedImage(); as image) {\n <div class=\"gallery-preview relative overflow-hidden rounded-lg\" ngsImageViewer>\n <button ngsButton class=\"gallery-picture block w-full\" [fullWidth]=\"true\" ngsImageViewerPicture [sourceUrl]=\"image.src\" [caption]=\"captionText(image.caption)\" [attr.aria-label]=\"image.alt || 'View image'\">\n <img class=\"block aspect-video w-full object-cover\" [src]=\"image.src\" [alt]=\"image.alt\" draggable=\"false\">\n </button>\n <button ngsIconButton class=\"preview-action image-actions absolute right-3 top-3\" aria-label=\"Image actions\" [ngsMenuTriggerFor]=\"imageMenu\"><ngs-icon name=\"fluent:more-horizontal-24-regular\"/></button>\n @if (images().length > 1) {\n <button ngsIconButton class=\"preview-action absolute left-3 top-1/2 -translate-y-1/2\" aria-label=\"Previous image\" [disabled]=\"selectedIndex() === 0\" (click)=\"previousImage()\"><ngs-icon name=\"fluent:chevron-left-24-regular\"/></button>\n <button ngsIconButton class=\"preview-action absolute right-3 top-1/2 -translate-y-1/2\" aria-label=\"Next image\" [disabled]=\"selectedIndex() === images().length - 1\" (click)=\"nextImage()\"><ngs-icon name=\"fluent:chevron-right-24-regular\"/></button>\n }\n <span class=\"image-counter absolute bottom-3 left-1/2 -translate-x-1/2 rounded-full px-3 py-1 text-sm\" aria-live=\"polite\">{{ selectedIndex() + 1 }} / {{ images().length }}</span>\n </div>\n <div class=\"flex min-w-0 flex-col gap-2\">\n <span class=\"flex items-center gap-2 text-xs text-on-surface-variant\"><ngs-icon name=\"fluent:re-order-24-regular\" class=\"size-4\"/>Drag to reorder</span>\n <div class=\"thumbnail-strip flex min-w-0 gap-3 overflow-x-auto pb-2\">\n <div cdkDropList cdkDropListOrientation=\"horizontal\" [cdkDropListData]=\"images()\" (cdkDropListDropped)=\"dropImage($event)\" class=\"flex shrink-0 gap-3\">\n @for (thumbnail of images(); track thumbnail.id) {\n <div cdkDrag [cdkDragData]=\"thumbnail.id\" class=\"gallery-thumbnail flex shrink-0 items-center gap-1 rounded-lg p-1\" [attr.data-image-id]=\"thumbnail.id\">\n <div cdkDragHandle class=\"thumbnail-handle flex w-5 shrink-0 self-stretch items-center justify-center select-none touch-none\" [attr.title]=\"'Drag to reorder image ' + ($index + 1)\"><ngs-icon name=\"fluent:re-order-dots-vertical-24-regular\"/></div>\n <button ngsButton class=\"thumbnail-picture\" [class.is-selected]=\"selectedId() === thumbnail.id\" [attr.aria-label]=\"'Select image ' + ($index + 1)\" [attr.aria-pressed]=\"selectedId() === thumbnail.id\" (click)=\"selectImage(thumbnail.id)\">\n <img class=\"block h-18 w-32 rounded-md object-cover\" [src]=\"thumbnail.src\" [alt]=\"thumbnail.alt\" draggable=\"false\" loading=\"lazy\">\n </button>\n </div>\n }\n </div>\n <button ngsButton class=\"add-image-tile flex shrink-0 flex-col justify-center gap-1 rounded-lg\" ngsUploadTrigger accept=\"image/*\" [multiple]=\"true\" [disabled]=\"uploading()\" (fileSelected)=\"upload($event)\"><ngs-icon name=\"fluent:add-24-regular\"/>Add images</button>\n </div>\n </div>\n <div class=\"flex flex-col gap-3\">\n <ngs-form-field labelMode=\"external\" subscriptHiddenIfEmpty class=\"gallery-field\">\n <ngs-label>Caption</ngs-label>\n <input ngsInput [value]=\"captionText(image.caption)\" placeholder=\"Add a caption\" (input)=\"changeCaption(image.id, $any($event.target).value)\">\n </ngs-form-field>\n <ngs-form-field labelMode=\"external\" class=\"gallery-field\">\n <ngs-label>Alt text</ngs-label>\n <input ngsInput [value]=\"image.alt\" placeholder=\"Describe this image\" (input)=\"changeAlt(image.id, $event)\">\n <ngs-hint>Describe the image for screen readers</ngs-hint>\n </ngs-form-field>\n </div>\n <ngs-menu #imageMenu>\n <button ngs-menu-item [disabled]=\"uploading()\" (click)=\"requestReplacement(image.id, replaceUpload)\">Replace image</button>\n <button ngs-menu-item [disabled]=\"selectedIndex() === 0\" (click)=\"moveImage(selectedIndex(), -1)\">Move image earlier</button>\n <button ngs-menu-item [disabled]=\"selectedIndex() === images().length - 1\" (click)=\"moveImage(selectedIndex(), 1)\">Move image later</button>\n <ngs-menu-divider/>\n <button ngs-menu-item (click)=\"removeImage(image.id)\">Remove image</button>\n </ngs-menu>\n } @else {\n <ngs-upload-area ngsUploadTrigger accept=\"image/*\" [multiple]=\"true\" (fileSelected)=\"!uploading() && upload($event)\">\n <div class=\"flex flex-col items-center gap-2 py-8\"><ngs-icon name=\"fluent:image-multiple-24-regular\" class=\"size-8\"/><span>Add images to your carousel</span><span class=\"text-xs text-on-surface-variant\">Click or drop images here</span></div>\n </ngs-upload-area>\n }\n <button ngsButton hidden ngsUploadTrigger accept=\"image/*\" #replaceUpload=\"ngsUploadTrigger\" (fileSelected)=\"upload($event, replacementId())\" aria-label=\"Replace selected image\"></button>\n <ngs-content-editor-upload-status [task]=\"uploadTask\"/>\n</div>\n",
|
|
109
|
+
styles: [":host{display:block;min-width:0;background:var(--ngs-content-editor-surface, var(--ngs-color-surface));border:1px solid var(--ngs-content-editor-border, var(--ngs-color-outline-variant));border-radius:var(--ngs-control-radius)}:host button[hidden]{display:none}:host .gallery-picture,:host .thumbnail-picture{--ngs-button-height: auto;--ngs-button-padding: 0;--ngs-button-content-gap: 0}:host .gallery-picture ::ng-deep .content,:host .thumbnail-picture ::ng-deep .content{display:block;width:100%}:host .preview-action{position:absolute;--ngs-button-height: calc(var(--spacing, .25rem) * 8);background:var(--ngs-content-editor-surface, var(--ngs-color-surface));color:var(--ngs-color-on-surface);box-shadow:var(--ngs-shadow-sm);border-radius:var(--ngs-radius-full)}:host .preview-action.image-actions{border-radius:var(--ngs-control-radius)}:host .image-counter{background:var(--ngs-color-black);color:var(--ngs-color-white)}:host .gallery-thumbnail{background:var(--ngs-color-surface-container-low)}:host .thumbnail-handle{cursor:grab}:host .thumbnail-handle:active{cursor:grabbing}:host .thumbnail-picture{border-radius:var(--ngs-radius-md)}:host .thumbnail-picture.is-selected{outline:2px solid var(--ngs-color-primary);outline-offset:1px}:host .add-image-tile{--ngs-button-height: auto;--ngs-button-padding: calc(var(--spacing, .25rem) * 3);--ngs-button-content-gap: var(--spacing, .25rem);width:calc(var(--spacing, .25rem) * 36);border:1px dashed var(--ngs-content-editor-border, var(--ngs-color-outline-variant))}:host .add-image-tile ::ng-deep .icon{left:auto;right:auto}:host .add-image-tile ::ng-deep .content{line-height:normal}:host ngs-form-field{--ngs-form-field-border-width: 1px;--ngs-form-field-border-color: var(--ngs-content-editor-field-border, var(--ngs-color-outline));--ngs-form-field-container-min-height: calc(var(--spacing, .25rem) * 9);--ngs-form-field-input-height: calc(var(--spacing, .25rem) * 9)}:host .cdk-drag-placeholder{opacity:.25}:host .cdk-drag-animating{transition:transform .18s ease}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"],
|
|
110
|
+
dependencies: [
|
|
111
|
+
{
|
|
112
|
+
kind: "component",
|
|
113
|
+
type: ContentEditorUploadStatus,
|
|
114
|
+
selector: "ngs-content-editor-upload-status",
|
|
115
|
+
inputs: ["task"]
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
kind: "component",
|
|
119
|
+
type: UploadArea,
|
|
120
|
+
selector: "ngs-upload-area",
|
|
121
|
+
inputs: [
|
|
122
|
+
"accept",
|
|
123
|
+
"allowHover",
|
|
124
|
+
"multiple"
|
|
125
|
+
],
|
|
126
|
+
outputs: ["fileSelected"],
|
|
127
|
+
exportAs: ["ngsUploadArea"]
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
kind: "directive",
|
|
131
|
+
type: UploadTriggerDirective,
|
|
132
|
+
selector: "[ngsUploadTrigger]",
|
|
133
|
+
inputs: ["accept", "multiple"],
|
|
134
|
+
outputs: ["fileSelected"],
|
|
135
|
+
exportAs: ["ngsUploadTrigger"]
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
kind: "component",
|
|
139
|
+
type: Button,
|
|
140
|
+
selector: "\n button[ngsButton], button[ngsIconButton],\n a[ngsButton], a[ngsIconButton]\n ",
|
|
141
|
+
inputs: [
|
|
142
|
+
"ngsButton",
|
|
143
|
+
"ngsIconButton",
|
|
144
|
+
"loading",
|
|
145
|
+
"disabled",
|
|
146
|
+
"disabledInteractive",
|
|
147
|
+
"disableRipple",
|
|
148
|
+
"reverse",
|
|
149
|
+
"fullWidth",
|
|
150
|
+
"hideTextOnMobile"
|
|
151
|
+
],
|
|
152
|
+
exportAs: ["ngsButton"]
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
kind: "component",
|
|
156
|
+
type: Icon,
|
|
157
|
+
selector: "ngs-icon",
|
|
158
|
+
inputs: ["name"],
|
|
159
|
+
exportAs: ["ngsIcon"]
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
kind: "component",
|
|
163
|
+
type: FormField,
|
|
164
|
+
selector: "ngs-form-field",
|
|
165
|
+
inputs: [
|
|
166
|
+
"labelMode",
|
|
167
|
+
"subscriptHiddenIfEmpty",
|
|
168
|
+
"sameHeightAsButton"
|
|
169
|
+
],
|
|
170
|
+
exportAs: ["ngsFormField"]
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
kind: "component",
|
|
174
|
+
type: Hint,
|
|
175
|
+
selector: "ngs-hint",
|
|
176
|
+
inputs: ["align"],
|
|
177
|
+
exportAs: ["ngsHint"]
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
kind: "component",
|
|
181
|
+
type: Label,
|
|
182
|
+
selector: "ngs-label"
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
kind: "directive",
|
|
186
|
+
type: Input$1,
|
|
187
|
+
selector: "input[ngsInput], textarea[ngsInput]",
|
|
188
|
+
inputs: [
|
|
189
|
+
"id",
|
|
190
|
+
"placeholder",
|
|
191
|
+
"required",
|
|
192
|
+
"disabled",
|
|
193
|
+
"readonly",
|
|
194
|
+
"errorStateMatcher"
|
|
195
|
+
],
|
|
196
|
+
exportAs: ["ngsInput"]
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
kind: "directive",
|
|
200
|
+
type: CdkDrag,
|
|
201
|
+
selector: "[cdkDrag]",
|
|
202
|
+
inputs: [
|
|
203
|
+
"cdkDragData",
|
|
204
|
+
"cdkDragLockAxis",
|
|
205
|
+
"cdkDragRootElement",
|
|
206
|
+
"cdkDragBoundary",
|
|
207
|
+
"cdkDragStartDelay",
|
|
208
|
+
"cdkDragFreeDragPosition",
|
|
209
|
+
"cdkDragDisabled",
|
|
210
|
+
"cdkDragConstrainPosition",
|
|
211
|
+
"cdkDragPreviewClass",
|
|
212
|
+
"cdkDragPreviewContainer",
|
|
213
|
+
"cdkDragScale"
|
|
214
|
+
],
|
|
215
|
+
outputs: [
|
|
216
|
+
"cdkDragStarted",
|
|
217
|
+
"cdkDragReleased",
|
|
218
|
+
"cdkDragEnded",
|
|
219
|
+
"cdkDragEntered",
|
|
220
|
+
"cdkDragExited",
|
|
221
|
+
"cdkDragDropped",
|
|
222
|
+
"cdkDragMoved"
|
|
223
|
+
],
|
|
224
|
+
exportAs: ["cdkDrag"]
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
kind: "directive",
|
|
228
|
+
type: CdkDragHandle,
|
|
229
|
+
selector: "[cdkDragHandle]",
|
|
230
|
+
inputs: ["cdkDragHandleDisabled"]
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
kind: "directive",
|
|
234
|
+
type: CdkDropList,
|
|
235
|
+
selector: "[cdkDropList], cdk-drop-list",
|
|
236
|
+
inputs: [
|
|
237
|
+
"cdkDropListConnectedTo",
|
|
238
|
+
"cdkDropListData",
|
|
239
|
+
"cdkDropListOrientation",
|
|
240
|
+
"id",
|
|
241
|
+
"cdkDropListLockAxis",
|
|
242
|
+
"cdkDropListDisabled",
|
|
243
|
+
"cdkDropListSortingDisabled",
|
|
244
|
+
"cdkDropListEnterPredicate",
|
|
245
|
+
"cdkDropListSortPredicate",
|
|
246
|
+
"cdkDropListAutoScrollDisabled",
|
|
247
|
+
"cdkDropListAutoScrollStep",
|
|
248
|
+
"cdkDropListElementContainer",
|
|
249
|
+
"cdkDropListHasAnchor"
|
|
250
|
+
],
|
|
251
|
+
outputs: [
|
|
252
|
+
"cdkDropListDropped",
|
|
253
|
+
"cdkDropListEntered",
|
|
254
|
+
"cdkDropListExited",
|
|
255
|
+
"cdkDropListSorted"
|
|
256
|
+
],
|
|
257
|
+
exportAs: ["cdkDropList"]
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
kind: "component",
|
|
261
|
+
type: Menu,
|
|
262
|
+
selector: "ngs-menu",
|
|
263
|
+
inputs: [
|
|
264
|
+
"themeSource",
|
|
265
|
+
"role",
|
|
266
|
+
"classList",
|
|
267
|
+
"xPosition",
|
|
268
|
+
"yPosition",
|
|
269
|
+
"pushIntoViewport"
|
|
270
|
+
],
|
|
271
|
+
outputs: ["closed"],
|
|
272
|
+
exportAs: ["ngsMenu"]
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
kind: "component",
|
|
276
|
+
type: MenuDivider,
|
|
277
|
+
selector: "ngs-menu-divider"
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
kind: "component",
|
|
281
|
+
type: MenuItem,
|
|
282
|
+
selector: "ngs-menu-item, [ngs-menu-item]",
|
|
283
|
+
inputs: [
|
|
284
|
+
"disabled",
|
|
285
|
+
"role",
|
|
286
|
+
"selected"
|
|
287
|
+
],
|
|
288
|
+
outputs: ["_triggered"],
|
|
289
|
+
exportAs: ["ngsMenuItem"]
|
|
290
|
+
},
|
|
291
|
+
{
|
|
292
|
+
kind: "directive",
|
|
293
|
+
type: MenuTrigger,
|
|
294
|
+
selector: "[ngsMenuTriggerFor]",
|
|
295
|
+
inputs: [
|
|
296
|
+
"ngsMenuTriggerFor",
|
|
297
|
+
"ngsMenuTriggerData",
|
|
298
|
+
"ngsMenuDisabled",
|
|
299
|
+
"xPosition",
|
|
300
|
+
"yPosition",
|
|
301
|
+
"ngsMenuTriggerRestoreFocus"
|
|
302
|
+
],
|
|
303
|
+
outputs: ["menuOpened", "menuClosed"],
|
|
304
|
+
exportAs: ["ngsMenuTrigger"]
|
|
305
|
+
},
|
|
306
|
+
{
|
|
307
|
+
kind: "directive",
|
|
308
|
+
type: ImageViewerDirective,
|
|
309
|
+
selector: "[ngsImageViewer]",
|
|
310
|
+
exportAs: ["ngsImageViewer"]
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
kind: "directive",
|
|
314
|
+
type: ImageViewerPictureDirective,
|
|
315
|
+
selector: "[ngsImageViewerPicture]",
|
|
316
|
+
inputs: [
|
|
317
|
+
"sourceUrl",
|
|
318
|
+
"caption",
|
|
319
|
+
"title",
|
|
320
|
+
"description"
|
|
321
|
+
],
|
|
322
|
+
exportAs: ["ngsImageViewerPicture"]
|
|
323
|
+
}
|
|
324
|
+
],
|
|
325
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
326
|
+
});
|
|
327
|
+
};
|
|
328
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
329
|
+
minVersion: "12.0.0",
|
|
330
|
+
version: "22.3.0",
|
|
331
|
+
ngImport: i0,
|
|
332
|
+
type: ContentEditorGalleryBlock,
|
|
333
|
+
decorators: [{
|
|
334
|
+
type: Component,
|
|
335
|
+
args: [{
|
|
336
|
+
selector: "ngs-content-editor-gallery-block",
|
|
337
|
+
imports: [
|
|
338
|
+
ContentEditorUploadStatus,
|
|
339
|
+
UploadArea,
|
|
340
|
+
UploadTriggerDirective,
|
|
341
|
+
Button,
|
|
342
|
+
Icon,
|
|
343
|
+
FormField,
|
|
344
|
+
Hint,
|
|
345
|
+
Label,
|
|
346
|
+
Input$1,
|
|
347
|
+
CdkDrag,
|
|
348
|
+
CdkDragHandle,
|
|
349
|
+
CdkDropList,
|
|
350
|
+
Menu,
|
|
351
|
+
MenuDivider,
|
|
352
|
+
MenuItem,
|
|
353
|
+
MenuTrigger,
|
|
354
|
+
ImageViewerDirective,
|
|
355
|
+
ImageViewerPictureDirective
|
|
356
|
+
],
|
|
357
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
358
|
+
template: "<div class=\"flex min-w-0 flex-col gap-4 p-3 sm:p-4\">\n <div class=\"flex flex-wrap items-center gap-3\">\n <span class=\"text-base font-semibold\">Carousel</span>\n <span class=\"text-sm text-on-surface-variant\">{{ images().length }} {{ images().length === 1 ? 'image' : 'images' }}</span>\n </div>\n @if (selectedImage(); as image) {\n <div class=\"gallery-preview relative overflow-hidden rounded-lg\" ngsImageViewer>\n <button ngsButton class=\"gallery-picture block w-full\" [fullWidth]=\"true\" ngsImageViewerPicture [sourceUrl]=\"image.src\" [caption]=\"captionText(image.caption)\" [attr.aria-label]=\"image.alt || 'View image'\">\n <img class=\"block aspect-video w-full object-cover\" [src]=\"image.src\" [alt]=\"image.alt\" draggable=\"false\">\n </button>\n <button ngsIconButton class=\"preview-action image-actions absolute right-3 top-3\" aria-label=\"Image actions\" [ngsMenuTriggerFor]=\"imageMenu\"><ngs-icon name=\"fluent:more-horizontal-24-regular\"/></button>\n @if (images().length > 1) {\n <button ngsIconButton class=\"preview-action absolute left-3 top-1/2 -translate-y-1/2\" aria-label=\"Previous image\" [disabled]=\"selectedIndex() === 0\" (click)=\"previousImage()\"><ngs-icon name=\"fluent:chevron-left-24-regular\"/></button>\n <button ngsIconButton class=\"preview-action absolute right-3 top-1/2 -translate-y-1/2\" aria-label=\"Next image\" [disabled]=\"selectedIndex() === images().length - 1\" (click)=\"nextImage()\"><ngs-icon name=\"fluent:chevron-right-24-regular\"/></button>\n }\n <span class=\"image-counter absolute bottom-3 left-1/2 -translate-x-1/2 rounded-full px-3 py-1 text-sm\" aria-live=\"polite\">{{ selectedIndex() + 1 }} / {{ images().length }}</span>\n </div>\n <div class=\"flex min-w-0 flex-col gap-2\">\n <span class=\"flex items-center gap-2 text-xs text-on-surface-variant\"><ngs-icon name=\"fluent:re-order-24-regular\" class=\"size-4\"/>Drag to reorder</span>\n <div class=\"thumbnail-strip flex min-w-0 gap-3 overflow-x-auto pb-2\">\n <div cdkDropList cdkDropListOrientation=\"horizontal\" [cdkDropListData]=\"images()\" (cdkDropListDropped)=\"dropImage($event)\" class=\"flex shrink-0 gap-3\">\n @for (thumbnail of images(); track thumbnail.id) {\n <div cdkDrag [cdkDragData]=\"thumbnail.id\" class=\"gallery-thumbnail flex shrink-0 items-center gap-1 rounded-lg p-1\" [attr.data-image-id]=\"thumbnail.id\">\n <div cdkDragHandle class=\"thumbnail-handle flex w-5 shrink-0 self-stretch items-center justify-center select-none touch-none\" [attr.title]=\"'Drag to reorder image ' + ($index + 1)\"><ngs-icon name=\"fluent:re-order-dots-vertical-24-regular\"/></div>\n <button ngsButton class=\"thumbnail-picture\" [class.is-selected]=\"selectedId() === thumbnail.id\" [attr.aria-label]=\"'Select image ' + ($index + 1)\" [attr.aria-pressed]=\"selectedId() === thumbnail.id\" (click)=\"selectImage(thumbnail.id)\">\n <img class=\"block h-18 w-32 rounded-md object-cover\" [src]=\"thumbnail.src\" [alt]=\"thumbnail.alt\" draggable=\"false\" loading=\"lazy\">\n </button>\n </div>\n }\n </div>\n <button ngsButton class=\"add-image-tile flex shrink-0 flex-col justify-center gap-1 rounded-lg\" ngsUploadTrigger accept=\"image/*\" [multiple]=\"true\" [disabled]=\"uploading()\" (fileSelected)=\"upload($event)\"><ngs-icon name=\"fluent:add-24-regular\"/>Add images</button>\n </div>\n </div>\n <div class=\"flex flex-col gap-3\">\n <ngs-form-field labelMode=\"external\" subscriptHiddenIfEmpty class=\"gallery-field\">\n <ngs-label>Caption</ngs-label>\n <input ngsInput [value]=\"captionText(image.caption)\" placeholder=\"Add a caption\" (input)=\"changeCaption(image.id, $any($event.target).value)\">\n </ngs-form-field>\n <ngs-form-field labelMode=\"external\" class=\"gallery-field\">\n <ngs-label>Alt text</ngs-label>\n <input ngsInput [value]=\"image.alt\" placeholder=\"Describe this image\" (input)=\"changeAlt(image.id, $event)\">\n <ngs-hint>Describe the image for screen readers</ngs-hint>\n </ngs-form-field>\n </div>\n <ngs-menu #imageMenu>\n <button ngs-menu-item [disabled]=\"uploading()\" (click)=\"requestReplacement(image.id, replaceUpload)\">Replace image</button>\n <button ngs-menu-item [disabled]=\"selectedIndex() === 0\" (click)=\"moveImage(selectedIndex(), -1)\">Move image earlier</button>\n <button ngs-menu-item [disabled]=\"selectedIndex() === images().length - 1\" (click)=\"moveImage(selectedIndex(), 1)\">Move image later</button>\n <ngs-menu-divider/>\n <button ngs-menu-item (click)=\"removeImage(image.id)\">Remove image</button>\n </ngs-menu>\n } @else {\n <ngs-upload-area ngsUploadTrigger accept=\"image/*\" [multiple]=\"true\" (fileSelected)=\"!uploading() && upload($event)\">\n <div class=\"flex flex-col items-center gap-2 py-8\"><ngs-icon name=\"fluent:image-multiple-24-regular\" class=\"size-8\"/><span>Add images to your carousel</span><span class=\"text-xs text-on-surface-variant\">Click or drop images here</span></div>\n </ngs-upload-area>\n }\n <button ngsButton hidden ngsUploadTrigger accept=\"image/*\" #replaceUpload=\"ngsUploadTrigger\" (fileSelected)=\"upload($event, replacementId())\" aria-label=\"Replace selected image\"></button>\n <ngs-content-editor-upload-status [task]=\"uploadTask\"/>\n</div>\n",
|
|
359
|
+
styles: [":host{display:block;min-width:0;background:var(--ngs-content-editor-surface, var(--ngs-color-surface));border:1px solid var(--ngs-content-editor-border, var(--ngs-color-outline-variant));border-radius:var(--ngs-control-radius)}:host button[hidden]{display:none}:host .gallery-picture,:host .thumbnail-picture{--ngs-button-height: auto;--ngs-button-padding: 0;--ngs-button-content-gap: 0}:host .gallery-picture ::ng-deep .content,:host .thumbnail-picture ::ng-deep .content{display:block;width:100%}:host .preview-action{position:absolute;--ngs-button-height: calc(var(--spacing, .25rem) * 8);background:var(--ngs-content-editor-surface, var(--ngs-color-surface));color:var(--ngs-color-on-surface);box-shadow:var(--ngs-shadow-sm);border-radius:var(--ngs-radius-full)}:host .preview-action.image-actions{border-radius:var(--ngs-control-radius)}:host .image-counter{background:var(--ngs-color-black);color:var(--ngs-color-white)}:host .gallery-thumbnail{background:var(--ngs-color-surface-container-low)}:host .thumbnail-handle{cursor:grab}:host .thumbnail-handle:active{cursor:grabbing}:host .thumbnail-picture{border-radius:var(--ngs-radius-md)}:host .thumbnail-picture.is-selected{outline:2px solid var(--ngs-color-primary);outline-offset:1px}:host .add-image-tile{--ngs-button-height: auto;--ngs-button-padding: calc(var(--spacing, .25rem) * 3);--ngs-button-content-gap: var(--spacing, .25rem);width:calc(var(--spacing, .25rem) * 36);border:1px dashed var(--ngs-content-editor-border, var(--ngs-color-outline-variant))}:host .add-image-tile ::ng-deep .icon{left:auto;right:auto}:host .add-image-tile ::ng-deep .content{line-height:normal}:host ngs-form-field{--ngs-form-field-border-width: 1px;--ngs-form-field-border-color: var(--ngs-content-editor-field-border, var(--ngs-color-outline));--ngs-form-field-container-min-height: calc(var(--spacing, .25rem) * 9);--ngs-form-field-input-height: calc(var(--spacing, .25rem) * 9)}:host .cdk-drag-placeholder{opacity:.25}:host .cdk-drag-animating{transition:transform .18s ease}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"]
|
|
360
|
+
}]
|
|
361
|
+
}]
|
|
362
|
+
});
|
|
363
|
+
export { ContentEditorGalleryBlock };
|
|
364
|
+
|
|
365
|
+
//# sourceMappingURL=gallery-block-DT3uIURY.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gallery-block-DT3uIURY.mjs","names":["Input"],"sources":["../../../projects/components/content-editor/src/_builder/gallery-block/gallery-block.ts","../../../projects/components/content-editor/src/_builder/gallery-block/gallery-block.html"],"sourcesContent":["import { ChangeDetectionStrategy, Component, computed, linkedSignal, signal } from '@angular/core';\nimport { CdkDrag, CdkDragDrop, CdkDragHandle, CdkDropList, moveItemInArray } from '@angular/cdk/drag-drop';\nimport { createNgsHeadlessEditorId, createNgsHeadlessEditorText } from '@ngstarter-ui/components/headless-editor';\nimport { UploadArea, UploadTriggerDirective, UploadFileSelectedEvent } from '@ngstarter-ui/components/upload';\nimport { Button } from '@ngstarter-ui/components/button';\nimport { Icon } from '@ngstarter-ui/components/icon';\nimport { FormField, Hint, Label } from '@ngstarter-ui/components/form-field';\nimport { Input } from '@ngstarter-ui/components/input';\nimport { Menu, MenuDivider, MenuItem, MenuTrigger } from '@ngstarter-ui/components/menu';\nimport { ImageViewerDirective, ImageViewerPictureDirective } from '@ngstarter-ui/components/image-viewer';\nimport { ContentEditorUploadBlockBase } from '../upload-block-base';\nimport { ContentEditorGalleryContent, ContentEditorGalleryImage } from '../../types';\nimport { contentEditorText } from '../../document';\nimport { ContentEditorUploadStatus } from '../upload-status/upload-status';\n\n@Component({\n selector: 'ngs-content-editor-gallery-block',\n imports: [ContentEditorUploadStatus, UploadArea, UploadTriggerDirective, Button, Icon, FormField, Hint, Label, Input,\n CdkDrag, CdkDragHandle, CdkDropList, Menu, MenuDivider, MenuItem, MenuTrigger, ImageViewerDirective, ImageViewerPictureDirective],\n templateUrl: './gallery-block.html', styleUrl: './gallery-block.scss', changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class ContentEditorGalleryBlock extends ContentEditorUploadBlockBase<ContentEditorGalleryContent> {\n readonly images = computed(() => this.content().images);\n readonly selectedId = linkedSignal<readonly ContentEditorGalleryImage[], string | null>({\n source: this.images,\n computation: (images, previous) => {\n if (images.some(image => image.id === previous?.value)) return previous!.value;\n const previousIndex = previous?.source.findIndex(image => image.id === previous.value) ?? 0;\n return images[Math.min(Math.max(previousIndex, 0), images.length - 1)]?.id ?? null;\n }\n });\n readonly selectedIndex = computed(() => this.images().findIndex(image => image.id === this.selectedId()));\n readonly selectedImage = computed(() => this.images()[this.selectedIndex()] ?? null);\n readonly replacementId = signal<string | null>(null);\n readonly captionText = contentEditorText;\n\n selectImage(id: string): void { this.selectedId.set(id); }\n previousImage(): void { const image = this.images()[this.selectedIndex() - 1]; if (image) this.selectImage(image.id); }\n nextImage(): void { const image = this.images()[this.selectedIndex() + 1]; if (image) this.selectImage(image.id); }\n changeAlt(id: string, event: Event): void { this.changeImage(id, { alt: (event.target as HTMLInputElement).value }); }\n changeCaption(id: string, caption: string): void { this.changeImage(id, { caption: [createNgsHeadlessEditorText(caption)] }); }\n private changeImage(id: string, data: Partial<ContentEditorGalleryImage>): void {\n this.save({ images: this.latestContent().images.map(image => image.id === id ? { ...image, ...data } : image) });\n }\n removeImage(id: string): void { this.save({ images: this.latestContent().images.filter(image => image.id !== id) }); }\n moveImage(index: number, direction: number): void { this.reorderImage(index, index + direction); }\n dropImage(event: CdkDragDrop<readonly ContentEditorGalleryImage[]>): void {\n this.reorderImage(event.previousIndex, event.currentIndex);\n }\n private reorderImage(from: number, to: number): void {\n const images = [...this.latestContent().images];\n if (from < 0 || to < 0 || from >= images.length || to >= images.length || from === to) return;\n moveItemInArray(images, from, to);\n this.save({ images });\n }\n requestReplacement(id: string, trigger: UploadTriggerDirective): void {\n this.replacementId.set(id);\n trigger._handleClick();\n }\n async upload(event: UploadFileSelectedEvent, replaceId: string | null = null): Promise<void> {\n const files = replaceId ? event.files.slice(0, 1) : event.files;\n await this.uploadFiles('gallery', { files, accept: file => file.type.startsWith('image/'), apply: results => {\n const images = results.map(({ url, file }) => ({ id: createNgsHeadlessEditorId('image'), src: url, alt: file.name, caption: [] } satisfies ContentEditorGalleryImage));\n if (replaceId) this.changeImage(replaceId, { src: images[0].src });\n else { this.save({ images: [...this.latestContent().images, ...images] }); this.selectImage(images[0].id); }\n } });\n }\n}\n","<div class=\"flex min-w-0 flex-col gap-4 p-3 sm:p-4\">\n <div class=\"flex flex-wrap items-center gap-3\">\n <span class=\"text-base font-semibold\">Carousel</span>\n <span class=\"text-sm text-on-surface-variant\">{{ images().length }} {{ images().length === 1 ? 'image' : 'images' }}</span>\n </div>\n @if (selectedImage(); as image) {\n <div class=\"gallery-preview relative overflow-hidden rounded-lg\" ngsImageViewer>\n <button ngsButton class=\"gallery-picture block w-full\" [fullWidth]=\"true\" ngsImageViewerPicture [sourceUrl]=\"image.src\" [caption]=\"captionText(image.caption)\" [attr.aria-label]=\"image.alt || 'View image'\">\n <img class=\"block aspect-video w-full object-cover\" [src]=\"image.src\" [alt]=\"image.alt\" draggable=\"false\">\n </button>\n <button ngsIconButton class=\"preview-action image-actions absolute right-3 top-3\" aria-label=\"Image actions\" [ngsMenuTriggerFor]=\"imageMenu\"><ngs-icon name=\"fluent:more-horizontal-24-regular\"/></button>\n @if (images().length > 1) {\n <button ngsIconButton class=\"preview-action absolute left-3 top-1/2 -translate-y-1/2\" aria-label=\"Previous image\" [disabled]=\"selectedIndex() === 0\" (click)=\"previousImage()\"><ngs-icon name=\"fluent:chevron-left-24-regular\"/></button>\n <button ngsIconButton class=\"preview-action absolute right-3 top-1/2 -translate-y-1/2\" aria-label=\"Next image\" [disabled]=\"selectedIndex() === images().length - 1\" (click)=\"nextImage()\"><ngs-icon name=\"fluent:chevron-right-24-regular\"/></button>\n }\n <span class=\"image-counter absolute bottom-3 left-1/2 -translate-x-1/2 rounded-full px-3 py-1 text-sm\" aria-live=\"polite\">{{ selectedIndex() + 1 }} / {{ images().length }}</span>\n </div>\n <div class=\"flex min-w-0 flex-col gap-2\">\n <span class=\"flex items-center gap-2 text-xs text-on-surface-variant\"><ngs-icon name=\"fluent:re-order-24-regular\" class=\"size-4\"/>Drag to reorder</span>\n <div class=\"thumbnail-strip flex min-w-0 gap-3 overflow-x-auto pb-2\">\n <div cdkDropList cdkDropListOrientation=\"horizontal\" [cdkDropListData]=\"images()\" (cdkDropListDropped)=\"dropImage($event)\" class=\"flex shrink-0 gap-3\">\n @for (thumbnail of images(); track thumbnail.id) {\n <div cdkDrag [cdkDragData]=\"thumbnail.id\" class=\"gallery-thumbnail flex shrink-0 items-center gap-1 rounded-lg p-1\" [attr.data-image-id]=\"thumbnail.id\">\n <div cdkDragHandle class=\"thumbnail-handle flex w-5 shrink-0 self-stretch items-center justify-center select-none touch-none\" [attr.title]=\"'Drag to reorder image ' + ($index + 1)\"><ngs-icon name=\"fluent:re-order-dots-vertical-24-regular\"/></div>\n <button ngsButton class=\"thumbnail-picture\" [class.is-selected]=\"selectedId() === thumbnail.id\" [attr.aria-label]=\"'Select image ' + ($index + 1)\" [attr.aria-pressed]=\"selectedId() === thumbnail.id\" (click)=\"selectImage(thumbnail.id)\">\n <img class=\"block h-18 w-32 rounded-md object-cover\" [src]=\"thumbnail.src\" [alt]=\"thumbnail.alt\" draggable=\"false\" loading=\"lazy\">\n </button>\n </div>\n }\n </div>\n <button ngsButton class=\"add-image-tile flex shrink-0 flex-col justify-center gap-1 rounded-lg\" ngsUploadTrigger accept=\"image/*\" [multiple]=\"true\" [disabled]=\"uploading()\" (fileSelected)=\"upload($event)\"><ngs-icon name=\"fluent:add-24-regular\"/>Add images</button>\n </div>\n </div>\n <div class=\"flex flex-col gap-3\">\n <ngs-form-field labelMode=\"external\" subscriptHiddenIfEmpty class=\"gallery-field\">\n <ngs-label>Caption</ngs-label>\n <input ngsInput [value]=\"captionText(image.caption)\" placeholder=\"Add a caption\" (input)=\"changeCaption(image.id, $any($event.target).value)\">\n </ngs-form-field>\n <ngs-form-field labelMode=\"external\" class=\"gallery-field\">\n <ngs-label>Alt text</ngs-label>\n <input ngsInput [value]=\"image.alt\" placeholder=\"Describe this image\" (input)=\"changeAlt(image.id, $event)\">\n <ngs-hint>Describe the image for screen readers</ngs-hint>\n </ngs-form-field>\n </div>\n <ngs-menu #imageMenu>\n <button ngs-menu-item [disabled]=\"uploading()\" (click)=\"requestReplacement(image.id, replaceUpload)\">Replace image</button>\n <button ngs-menu-item [disabled]=\"selectedIndex() === 0\" (click)=\"moveImage(selectedIndex(), -1)\">Move image earlier</button>\n <button ngs-menu-item [disabled]=\"selectedIndex() === images().length - 1\" (click)=\"moveImage(selectedIndex(), 1)\">Move image later</button>\n <ngs-menu-divider/>\n <button ngs-menu-item (click)=\"removeImage(image.id)\">Remove image</button>\n </ngs-menu>\n } @else {\n <ngs-upload-area ngsUploadTrigger accept=\"image/*\" [multiple]=\"true\" (fileSelected)=\"!uploading() && upload($event)\">\n <div class=\"flex flex-col items-center gap-2 py-8\"><ngs-icon name=\"fluent:image-multiple-24-regular\" class=\"size-8\"/><span>Add images to your carousel</span><span class=\"text-xs text-on-surface-variant\">Click or drop images here</span></div>\n </ngs-upload-area>\n }\n <button ngsButton hidden ngsUploadTrigger accept=\"image/*\" #replaceUpload=\"ngsUploadTrigger\" (fileSelected)=\"upload($event, replacementId())\" aria-label=\"Replace selected image\"></button>\n <ngs-content-editor-upload-status [task]=\"uploadTask\"/>\n</div>\n"],"mappings":"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"}
|