@esri/solutions-components 0.10.24 → 0.10.25
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/calcite-action-pad_2.cjs.entry.js +2 -2
- package/dist/cjs/calcite-block_5.cjs.entry.js +5 -7
- package/dist/cjs/{calcite-carousel.cjs.entry.js → calcite-carousel_2.cjs.entry.js} +52 -18
- package/dist/cjs/instant-apps-app-guide.cjs.entry.js +106 -0
- package/dist/cjs/instant-apps-ckeditor-wrapper_3.cjs.entry.js +3 -3
- package/dist/cjs/instant-apps-control-panel.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-export-views.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-export.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-header.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-interactive-legend-classic.cjs.entry.js +8 -3
- package/dist/cjs/instant-apps-interactive-legend-count_2.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-interactive-legend-group-legend-element-caption.cjs.entry.js +2 -2
- package/dist/cjs/instant-apps-interactive-legend-group-legend-element_5.cjs.entry.js +7 -7
- package/dist/cjs/instant-apps-keyboard-shortcuts.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-landing-page.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-language-switcher.cjs.entry.js +3 -3
- package/dist/cjs/instant-apps-language-translator.cjs.entry.js +34 -14
- package/dist/cjs/instant-apps-measurement.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-popover.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-scoreboard.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-sign-in.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-splash.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-time-filter.cjs.entry.js +59 -29
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/solutions-components.cjs.js +1 -1
- package/dist/cjs/{utils-9343bd5b.js → utils-62072741.js} +23 -0
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/components/calcite-carousel-item.js +1 -54
- package/dist/components/calcite-carousel.js +1 -517
- package/dist/{esm/calcite-carousel-item.entry.js → components/carousel-item.js} +28 -9
- package/dist/{esm/calcite-carousel.entry.js → components/carousel.js} +76 -19
- package/dist/components/instant-apps-app-guide.js +184 -0
- package/dist/components/instant-apps-ckeditor-wrapper2.js +1 -1
- package/dist/components/instant-apps-control-panel.js +1 -1
- package/dist/components/instant-apps-export-views.js +1 -1
- package/dist/components/instant-apps-export.js +1 -1
- package/dist/components/instant-apps-filter-list2.js +3 -5
- package/dist/components/instant-apps-header2.js +1 -1
- package/dist/components/instant-apps-interactive-legend-classic2.js +8 -3
- package/dist/components/instant-apps-interactive-legend-group-legend-element-caption.js +2 -2
- package/dist/components/instant-apps-interactive-legend-group-legend-element2.js +2 -2
- package/dist/components/instant-apps-interactive-legend-layer-element-caption2.js +1 -1
- package/dist/components/instant-apps-interactive-legend-layer-element2.js +2 -2
- package/dist/components/instant-apps-interactive-legend-legend-element2.js +1 -1
- package/dist/components/instant-apps-interactive-legend-relationship2.js +2 -2
- package/dist/components/instant-apps-keyboard-shortcuts.js +1 -1
- package/dist/components/instant-apps-landing-page.js +1 -1
- package/dist/components/instant-apps-language-switcher.js +3 -3
- package/dist/components/instant-apps-language-translator-item2.js +1 -1
- package/dist/components/instant-apps-language-translator-search2.js +1 -1
- package/dist/components/instant-apps-language-translator2.js +33 -13
- package/dist/components/instant-apps-measurement-tool2.js +2 -2
- package/dist/components/instant-apps-measurement.js +1 -1
- package/dist/components/instant-apps-popover.js +1 -1
- package/dist/components/instant-apps-scoreboard.js +1 -1
- package/dist/components/instant-apps-sign-in2.js +1 -1
- package/dist/components/instant-apps-social-share2.js +2 -2
- package/dist/components/instant-apps-splash.js +1 -1
- package/dist/components/instant-apps-time-filter.js +59 -29
- package/dist/components/utils4.js +22 -1
- package/dist/esm/{ExpandToggle-9289b7ca.js → ExpandToggle-076b4360.js} +1 -1
- package/dist/esm/{ar-8dded5d5.js → ar-3e3c0d14.js} +8 -8
- package/dist/esm/{bg-c1cdf619.js → bg-a872736b.js} +8 -8
- package/dist/esm/{bs-a40506a4.js → bs-fe545c28.js} +8 -8
- package/dist/esm/buffer-tools_3.entry.js +1 -1
- package/dist/esm/{ca-67879a0c.js → ca-8a2abdaa.js} +8 -8
- package/dist/esm/calcite-accordion_2.entry.js +1 -1
- package/dist/esm/calcite-action-bar.entry.js +4 -4
- package/dist/esm/calcite-action-group.entry.js +3 -3
- package/dist/esm/calcite-action-menu_2.entry.js +3 -3
- package/dist/esm/calcite-action-pad_2.entry.js +6 -6
- package/dist/esm/calcite-action_2.entry.js +6 -6
- package/dist/esm/calcite-alert_5.entry.js +4 -4
- package/dist/esm/calcite-avatar.entry.js +1 -1
- package/dist/esm/calcite-block-section.entry.js +3 -3
- package/dist/esm/calcite-block_5.entry.js +14 -16
- package/dist/esm/calcite-button.entry.js +5 -5
- package/dist/esm/calcite-card-group.entry.js +1 -1
- package/dist/esm/calcite-card.entry.js +3 -3
- package/dist/esm/calcite-carousel_2.entry.js +500 -0
- package/dist/esm/calcite-checkbox.entry.js +3 -3
- package/dist/esm/calcite-chip-group.entry.js +1 -1
- package/dist/esm/calcite-chip_2.entry.js +4 -4
- package/dist/esm/calcite-color-picker-hex-input_2.entry.js +1 -1
- package/dist/esm/calcite-color-picker.entry.js +3 -3
- package/dist/esm/calcite-combobox-item-group.entry.js +2 -2
- package/dist/esm/calcite-combobox_3.entry.js +8 -8
- package/dist/esm/calcite-date-picker-day_3.entry.js +3 -3
- package/dist/esm/calcite-dialog.entry.js +5 -5
- package/dist/esm/calcite-dropdown_2.entry.js +3 -3
- package/dist/esm/calcite-fab.entry.js +1 -1
- package/dist/esm/calcite-filter_5.entry.js +3 -3
- package/dist/esm/calcite-graph_2.entry.js +4 -4
- package/dist/esm/calcite-icon_2.entry.js +2 -2
- package/dist/esm/calcite-inline-editable.entry.js +4 -4
- package/dist/esm/calcite-input-number.entry.js +5 -5
- package/dist/esm/calcite-input-text.entry.js +5 -5
- package/dist/esm/{calcite-input-time-picker-37845feb.js → calcite-input-time-picker-2fbabd28.js} +56 -56
- package/dist/esm/calcite-input-time-picker.entry.js +8 -8
- package/dist/esm/calcite-input-time-zone.entry.js +5 -5
- package/dist/esm/calcite-input_2.entry.js +5 -5
- package/dist/esm/calcite-label.entry.js +2 -2
- package/dist/esm/calcite-link.entry.js +1 -1
- package/dist/esm/calcite-menu-item.entry.js +3 -3
- package/dist/esm/calcite-menu.entry.js +3 -3
- package/dist/esm/calcite-meter.entry.js +3 -3
- package/dist/esm/calcite-modal_3.entry.js +5 -5
- package/dist/esm/calcite-navigation.entry.js +1 -1
- package/dist/esm/calcite-notice.entry.js +4 -4
- package/dist/esm/calcite-option_2.entry.js +3 -3
- package/dist/esm/calcite-pagination.entry.js +3 -3
- package/dist/esm/calcite-pick-list-group.entry.js +1 -1
- package/dist/esm/calcite-pick-list-item.entry.js +3 -3
- package/dist/esm/calcite-pick-list.entry.js +2 -2
- package/dist/esm/calcite-radio-button-group.entry.js +1 -1
- package/dist/esm/calcite-radio-button.entry.js +3 -3
- package/dist/esm/calcite-rating.entry.js +5 -5
- package/dist/esm/calcite-scrim.entry.js +3 -3
- package/dist/esm/calcite-segmented-control_2.entry.js +3 -3
- package/dist/esm/calcite-sheet.entry.js +3 -3
- package/dist/esm/calcite-shell-center-row.entry.js +1 -1
- package/dist/esm/calcite-shell-panel_14.entry.js +4 -4
- package/dist/esm/calcite-sortable-list.entry.js +1 -1
- package/dist/esm/calcite-stepper-item.entry.js +3 -3
- package/dist/esm/calcite-stepper.entry.js +3 -3
- package/dist/esm/calcite-switch.entry.js +3 -3
- package/dist/esm/calcite-table-cell_2.entry.js +3 -3
- package/dist/esm/calcite-table-row.entry.js +1 -1
- package/dist/esm/calcite-table.entry.js +3 -3
- package/dist/esm/calcite-text-area.entry.js +5 -5
- package/dist/esm/calcite-tile-group.entry.js +1 -1
- package/dist/esm/calcite-tile.entry.js +1 -1
- package/dist/esm/calcite-time-picker.entry.js +4 -4
- package/dist/esm/calcite-tip-manager.entry.js +3 -3
- package/dist/esm/calcite-tip.entry.js +3 -3
- package/dist/esm/calcite-tooltip.entry.js +3 -3
- package/dist/esm/calcite-tree_2.entry.js +1 -1
- package/dist/esm/{cs-b01aecfc.js → cs-f9bfb6dd.js} +8 -8
- package/dist/esm/{da-87ac64be.js → da-0528de8d.js} +8 -8
- package/dist/esm/{date-7a1345c1.js → date-f0c83d13.js} +1 -1
- package/dist/esm/{de-at-2db1a5d5.js → de-at-c7c45014.js} +8 -8
- package/dist/esm/{de-ch-063c0a6b.js → de-ch-e9338f1b.js} +8 -8
- package/dist/esm/{de-0eb6c065.js → de-d149b983.js} +8 -8
- package/dist/esm/{dom-451ed293.js → dom-42a638f6.js} +1 -1
- package/dist/esm/{el-eb29e645.js → el-d86fff8e.js} +8 -8
- package/dist/esm/{en-au-00f884ad.js → en-au-e722c119.js} +8 -8
- package/dist/esm/{en-ca-1e7456d7.js → en-ca-8f38a3b8.js} +8 -8
- package/dist/esm/{en-gb-60a33692.js → en-gb-24dd064c.js} +8 -8
- package/dist/esm/{es-74f8b164.js → es-39a9e113.js} +8 -8
- package/dist/esm/{es-mx-2bfa704a.js → es-mx-fa0cbd42.js} +8 -8
- package/dist/esm/{et-b1a2d978.js → et-51eabe80.js} +8 -8
- package/dist/esm/{fi-70441d5b.js → fi-64ca8666.js} +8 -8
- package/dist/esm/{floating-ui-4b1f5138.js → floating-ui-a14930d0.js} +1 -1
- package/dist/esm/{focusTrapComponent-b9709e71.js → focusTrapComponent-c1def619.js} +1 -1
- package/dist/esm/{form-fa4c471b.js → form-46367137.js} +1 -1
- package/dist/esm/{fr-ch-8faa2fcf.js → fr-ch-6fe6a6e6.js} +8 -8
- package/dist/esm/{fr-cea05ec9.js → fr-e20306bf.js} +8 -8
- package/dist/esm/{he-058ece46.js → he-32ec6cce.js} +8 -8
- package/dist/esm/{hi-163a268e.js → hi-da2b085c.js} +8 -8
- package/dist/esm/{hr-2b69b2ad.js → hr-5a52222a.js} +8 -8
- package/dist/esm/{hu-e46e0cb6.js → hu-d3bbacef.js} +8 -8
- package/dist/esm/{id-ebccdbbb.js → id-dcdac250.js} +8 -8
- package/dist/esm/instant-apps-app-guide.entry.js +102 -0
- package/dist/esm/instant-apps-ckeditor-wrapper_3.entry.js +3 -3
- package/dist/esm/instant-apps-control-panel.entry.js +1 -1
- package/dist/esm/instant-apps-export-views.entry.js +1 -1
- package/dist/esm/instant-apps-export.entry.js +1 -1
- package/dist/esm/instant-apps-header.entry.js +1 -1
- package/dist/esm/instant-apps-interactive-legend-classic.entry.js +8 -3
- package/dist/esm/instant-apps-interactive-legend-count_2.entry.js +1 -1
- package/dist/esm/instant-apps-interactive-legend-group-legend-element-caption.entry.js +2 -2
- package/dist/esm/instant-apps-interactive-legend-group-legend-element_5.entry.js +7 -7
- package/dist/esm/instant-apps-keyboard-shortcuts.entry.js +1 -1
- package/dist/esm/instant-apps-landing-page.entry.js +1 -1
- package/dist/esm/instant-apps-language-switcher.entry.js +3 -3
- package/dist/esm/instant-apps-language-translator.entry.js +34 -14
- package/dist/esm/instant-apps-measurement.entry.js +1 -1
- package/dist/esm/instant-apps-popover.entry.js +1 -1
- package/dist/esm/instant-apps-scoreboard.entry.js +1 -1
- package/dist/esm/instant-apps-sign-in.entry.js +1 -1
- package/dist/esm/instant-apps-splash.entry.js +1 -1
- package/dist/esm/instant-apps-time-filter.entry.js +59 -29
- package/dist/esm/{it-813be6d0.js → it-360f430f.js} +8 -8
- package/dist/esm/{it-ch-bc95119e.js → it-ch-0ec68776.js} +8 -8
- package/dist/esm/{ja-3488d28c.js → ja-a95cae4c.js} +8 -8
- package/dist/esm/{ko-54faa268.js → ko-f0edd78f.js} +8 -8
- package/dist/esm/{label-414f1003.js → label-f2ec1100.js} +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{locale-337dc231.js → locale-a53a7bc6.js} +1 -1
- package/dist/esm/{lt-8c773940.js → lt-bff432da.js} +8 -8
- package/dist/esm/{lv-4882a326.js → lv-0c7edf32.js} +8 -8
- package/dist/esm/{mk-d045a827.js → mk-876446b8.js} +8 -8
- package/dist/esm/{nb-529fd6f8.js → nb-25537e87.js} +8 -8
- package/dist/esm/{nl-ebd398ac.js → nl-8be84da3.js} +8 -8
- package/dist/esm/{openCloseComponent-80c6ee4b.js → openCloseComponent-9d44719e.js} +1 -1
- package/dist/esm/{pl-4cd334ed.js → pl-8d4fe5a7.js} +8 -8
- package/dist/esm/{pt-br-29226fc3.js → pt-br-3015e62b.js} +8 -8
- package/dist/esm/{pt-be0c86a5.js → pt-dcc887b4.js} +8 -8
- package/dist/esm/{ro-6555f5dd.js → ro-b973c654.js} +8 -8
- package/dist/esm/{ru-67b5c59c.js → ru-59a7f10b.js} +8 -8
- package/dist/esm/{shared-list-render-c8da5fde.js → shared-list-render-097ee366.js} +1 -1
- package/dist/esm/{sk-81f19081.js → sk-a00e5b97.js} +8 -8
- package/dist/esm/{sl-4b892d99.js → sl-55c8a748.js} +8 -8
- package/dist/esm/solutions-components.js +1 -1
- package/dist/esm/{sr-6cb6f797.js → sr-e4fc3293.js} +8 -8
- package/dist/esm/{sv-aacab364.js → sv-f0782d2a.js} +8 -8
- package/dist/esm/{t9n-7d4462c0.js → t9n-b33c486a.js} +1 -1
- package/dist/esm/{th-6b423678.js → th-d2abb499.js} +8 -8
- package/dist/esm/{time-b0bba3f9.js → time-f99aceff.js} +1 -1
- package/dist/esm/{tr-0e2b854e.js → tr-512413e1.js} +8 -8
- package/dist/esm/{uk-af0a30cc.js → uk-79fe44f1.js} +8 -8
- package/dist/esm/{utils-6493bff2.js → utils-6f13e31e.js} +22 -1
- package/dist/esm/{utils-37bc2853.js → utils-d67a6d71.js} +1 -1
- package/dist/esm/{vi-62071c6f.js → vi-53b51e7a.js} +8 -8
- package/dist/esm/{zh-cn-8f53db2f.js → zh-cn-7d19a53a.js} +8 -8
- package/dist/esm/{zh-hk-a8c68b9c.js → zh-hk-4fb6c3eb.js} +8 -8
- package/dist/esm/{zh-tw-3006115d.js → zh-tw-6a5d2c2b.js} +8 -8
- package/dist/node_modules/@esri/instant-apps-components/dist/collection/components/instant-apps-app-guide/instant-apps-app-guide.css +75 -0
- package/dist/node_modules/@esri/instant-apps-components/dist/collection/components/instant-apps-language-translator/instant-apps-language-translator.css +16 -0
- package/dist/solutions-components/{p-bb9492ed.js → p-022d51db.js} +1 -1
- package/dist/solutions-components/{p-beba6703.js → p-03f3cf77.js} +1 -1
- package/dist/solutions-components/{p-3955461a.js → p-03ffbb1b.js} +1 -1
- package/dist/solutions-components/{p-db2c82ad.js → p-0a1a9ff1.js} +1 -1
- package/dist/solutions-components/p-0a64be62.js +6 -0
- package/dist/solutions-components/{p-a0ef9cee.js → p-0ded20f0.js} +1 -1
- package/dist/solutions-components/{p-abc30e04.js → p-12be6545.js} +1 -1
- package/dist/solutions-components/{p-6384a9a5.entry.js → p-1692858b.entry.js} +1 -1
- package/dist/solutions-components/{p-4182a628.js → p-174aa4da.js} +3 -3
- package/dist/solutions-components/{p-981afe9e.entry.js → p-1826154b.entry.js} +1 -1
- package/dist/solutions-components/{p-109cabd8.entry.js → p-18307307.entry.js} +1 -1
- package/dist/solutions-components/{p-593a6f17.js → p-1a047db6.js} +1 -1
- package/dist/solutions-components/{p-d1371897.js → p-1df2d94d.js} +1 -1
- package/dist/solutions-components/{p-8badcaf5.entry.js → p-216ae423.entry.js} +1 -1
- package/dist/solutions-components/{p-7586e1de.entry.js → p-219f0273.entry.js} +1 -1
- package/dist/solutions-components/{p-ae8ed06a.entry.js → p-283e344a.entry.js} +1 -1
- package/dist/solutions-components/{p-7f090468.entry.js → p-2a059548.entry.js} +1 -1
- package/dist/solutions-components/{p-118e1989.entry.js → p-2bb9b365.entry.js} +1 -1
- package/dist/solutions-components/{p-fd730974.js → p-2caf1f94.js} +2 -2
- package/dist/solutions-components/{p-92de7cd3.entry.js → p-2cb47eff.entry.js} +2 -2
- package/dist/solutions-components/{p-e5736093.entry.js → p-2d2b06db.entry.js} +1 -1
- package/dist/solutions-components/{p-4d97016e.js → p-2d2dcf8a.js} +1 -1
- package/dist/solutions-components/{p-472be784.js → p-2d5e428d.js} +1 -1
- package/dist/solutions-components/{p-89ddc916.js → p-2e7d005f.js} +1 -1
- package/dist/solutions-components/{p-ef360459.entry.js → p-3016bf77.entry.js} +1 -1
- package/dist/solutions-components/{p-a2d4c97e.js → p-3244e59a.js} +2 -2
- package/dist/solutions-components/{p-54fa7a94.js → p-365169c2.js} +1 -1
- package/dist/solutions-components/{p-e013e797.js → p-372e4640.js} +1 -1
- package/dist/solutions-components/p-3d6f8c9e.entry.js +29 -0
- package/dist/solutions-components/{p-458a3f01.entry.js → p-3de85f54.entry.js} +1 -1
- package/dist/solutions-components/{p-5fe92f6e.entry.js → p-3e9a487b.entry.js} +1 -1
- package/dist/solutions-components/{p-2756e4ac.entry.js → p-42710186.entry.js} +1 -1
- package/dist/solutions-components/{p-16d721ef.entry.js → p-44270ade.entry.js} +1 -1
- package/dist/solutions-components/{p-d6c50190.entry.js → p-47398e76.entry.js} +1 -1
- package/dist/solutions-components/{p-20393dcf.entry.js → p-4881885b.entry.js} +3 -3
- package/dist/solutions-components/{p-5a76a4c8.entry.js → p-496b7a1f.entry.js} +1 -1
- package/dist/solutions-components/{p-89f14b8a.entry.js → p-4aafcac7.entry.js} +1 -1
- package/dist/solutions-components/{p-5d4efa42.entry.js → p-4cfe3d80.entry.js} +1 -1
- package/dist/solutions-components/{p-19697807.entry.js → p-4feaf7db.entry.js} +1 -1
- package/dist/solutions-components/{p-c8325ead.entry.js → p-50323300.entry.js} +1 -1
- package/dist/solutions-components/{p-f4e30ab2.js → p-50ab7903.js} +1 -1
- package/dist/solutions-components/{p-960a4993.entry.js → p-50c2d3e5.entry.js} +1 -1
- package/dist/solutions-components/{p-33fe9a28.js → p-50e2a33b.js} +1 -1
- package/dist/solutions-components/{p-6e0b76ce.js → p-51abfcb7.js} +1 -1
- package/dist/solutions-components/{p-1a7c4e9a.js → p-524a996f.js} +1 -1
- package/dist/solutions-components/{p-00cfce5b.entry.js → p-54879c84.entry.js} +1 -1
- package/dist/solutions-components/{p-8ae73529.entry.js → p-5550f101.entry.js} +2 -2
- package/dist/solutions-components/{p-040b6e44.entry.js → p-5714f5ca.entry.js} +1 -1
- package/dist/solutions-components/{p-67392838.entry.js → p-57be85fb.entry.js} +1 -1
- package/dist/solutions-components/{p-48c58b28.js → p-58d8ee47.js} +1 -1
- package/dist/solutions-components/{p-71c0a413.js → p-5959580d.js} +1 -1
- package/dist/solutions-components/{p-acf135cc.js → p-59695ccc.js} +1 -1
- package/dist/solutions-components/{p-116927af.entry.js → p-59b3e946.entry.js} +3 -3
- package/dist/solutions-components/{p-9c6f2672.entry.js → p-5a997dc9.entry.js} +1 -1
- package/dist/solutions-components/{p-c58ec2d0.js → p-5ba9df82.js} +3 -3
- package/dist/solutions-components/{p-78c438c0.entry.js → p-5d398871.entry.js} +1 -1
- package/dist/solutions-components/{p-5d8a5e53.entry.js → p-5d58d70c.entry.js} +1 -1
- package/dist/solutions-components/{p-4336e44a.js → p-62dadb51.js} +1 -1
- package/dist/solutions-components/{p-981ab7fc.entry.js → p-62ed6a7a.entry.js} +1 -1
- package/dist/solutions-components/{p-ea119eee.js → p-63f9004a.js} +1 -1
- package/dist/solutions-components/{p-b955a19b.entry.js → p-64906bb5.entry.js} +2 -2
- package/dist/solutions-components/{p-f7680693.js → p-65fe42ef.js} +1 -1
- package/dist/solutions-components/{p-441f1992.js → p-66cee72b.js} +1 -1
- package/dist/solutions-components/{p-da6e25cb.entry.js → p-6b1d1546.entry.js} +1 -1
- package/dist/solutions-components/{p-f14d11f1.js → p-6b21efce.js} +1 -1
- package/dist/solutions-components/{p-a8d4a522.entry.js → p-6cf1225a.entry.js} +1 -1
- package/dist/solutions-components/{p-a9f65057.entry.js → p-6d4db88b.entry.js} +8 -2
- package/dist/solutions-components/{p-c3782a7e.entry.js → p-6d894d47.entry.js} +1 -1
- package/dist/solutions-components/{p-26a3ba5e.entry.js → p-6e0439fa.entry.js} +1 -1
- package/dist/solutions-components/{p-16261018.js → p-6e118057.js} +2 -2
- package/dist/solutions-components/{p-0bd7752a.entry.js → p-6f594492.entry.js} +2 -2
- package/dist/solutions-components/{p-30903105.entry.js → p-70f2898c.entry.js} +1 -1
- package/dist/solutions-components/p-72bce122.entry.js +6 -0
- package/dist/solutions-components/{p-ddc97e93.entry.js → p-72ee63b0.entry.js} +1 -1
- package/dist/solutions-components/{p-24192cfe.js → p-754a5334.js} +1 -1
- package/dist/solutions-components/{p-fbf86656.entry.js → p-76efd680.entry.js} +1 -1
- package/dist/solutions-components/{p-5c0d42e9.entry.js → p-7758a533.entry.js} +1 -1
- package/dist/solutions-components/{p-c1242d4b.js → p-7a820f38.js} +1 -1
- package/dist/solutions-components/{p-a68f4775.entry.js → p-7b122a6e.entry.js} +1 -1
- package/dist/solutions-components/{p-3fb350ea.js → p-7e762fa7.js} +1 -1
- package/dist/solutions-components/{p-004d601f.entry.js → p-7f147e8b.entry.js} +1 -1
- package/dist/solutions-components/{p-41744516.entry.js → p-82185ebf.entry.js} +1 -1
- package/dist/solutions-components/{p-a16449b2.entry.js → p-827037ce.entry.js} +1 -1
- package/dist/solutions-components/{p-8419b5a1.entry.js → p-88c6ece3.entry.js} +1 -1
- package/dist/solutions-components/{p-cba777d2.js → p-8a683cdc.js} +1 -1
- package/dist/solutions-components/{p-42552409.js → p-8d453a3a.js} +1 -1
- package/dist/solutions-components/{p-886fbbe3.entry.js → p-8ef003ec.entry.js} +1 -1
- package/dist/solutions-components/p-8fb651e5.entry.js +6 -0
- package/dist/solutions-components/{p-4a35785b.js → p-92008b90.js} +1 -1
- package/dist/solutions-components/{p-203b4081.js → p-94397114.js} +1 -1
- package/dist/solutions-components/{p-50203a2d.entry.js → p-94805d7f.entry.js} +1 -1
- package/dist/solutions-components/p-94c518ff.entry.js +6 -0
- package/dist/solutions-components/{p-c5520bba.js → p-97aa6766.js} +1 -1
- package/dist/solutions-components/{p-2afb3a2b.js → p-984ce9da.js} +1 -1
- package/dist/solutions-components/{p-96919110.js → p-99e6cb74.js} +1 -1
- package/dist/solutions-components/{p-075a3c9d.entry.js → p-9d12b3f1.entry.js} +1 -1
- package/dist/solutions-components/{p-ff96d7ee.entry.js → p-9ee72dba.entry.js} +3 -3
- package/dist/solutions-components/{p-86ca6cfe.entry.js → p-9f3aebd0.entry.js} +1 -1
- package/dist/solutions-components/p-a1093fee.entry.js +6 -0
- package/dist/solutions-components/{p-bc86c87d.entry.js → p-a2a2c6a2.entry.js} +2 -2
- package/dist/solutions-components/{p-b9eefee6.entry.js → p-a2dbc38b.entry.js} +2 -2
- package/dist/solutions-components/{p-f4d6771a.js → p-a4255b97.js} +1 -1
- package/dist/solutions-components/{p-6518727d.js → p-a4e73041.js} +1 -1
- package/dist/solutions-components/{p-6e3f1d71.js → p-a5fc6ab7.js} +1 -1
- package/dist/solutions-components/{p-25ee25ea.entry.js → p-a60a2c8b.entry.js} +2 -2
- package/dist/solutions-components/{p-254f6e23.entry.js → p-a6a0df5c.entry.js} +1 -1
- package/dist/solutions-components/p-a7395caf.js +6 -0
- package/dist/solutions-components/{p-8eacc640.js → p-a7761371.js} +1 -1
- package/dist/solutions-components/{p-bdc425fc.js → p-a8b70e9a.js} +1 -1
- package/dist/solutions-components/{p-728ec094.entry.js → p-a8d83bc3.entry.js} +1 -1
- package/dist/solutions-components/p-aa36f70e.entry.js +6 -0
- package/dist/solutions-components/{p-57b673e2.js → p-ac92679c.js} +1 -1
- package/dist/solutions-components/{p-dbcfdc6d.entry.js → p-ad441ffa.entry.js} +1 -1
- package/dist/solutions-components/{p-01510268.entry.js → p-add869b6.entry.js} +1 -1
- package/dist/solutions-components/{p-9232245b.entry.js → p-b310402f.entry.js} +1 -1
- package/dist/solutions-components/{p-996daf05.entry.js → p-b4d708cd.entry.js} +1 -1
- package/dist/solutions-components/{p-6f39a13f.js → p-b7e63ac2.js} +1 -1
- package/dist/solutions-components/{p-c26ac7d9.entry.js → p-b9b2f7a9.entry.js} +1 -1
- package/dist/solutions-components/{p-2fafe489.entry.js → p-bb040eab.entry.js} +1 -1
- package/dist/solutions-components/{p-c5d26e3a.js → p-bcc2d4ff.js} +1 -1
- package/dist/solutions-components/{p-8846430d.entry.js → p-bcce9d28.entry.js} +3 -3
- package/dist/solutions-components/{p-b6b4c707.entry.js → p-c60c5991.entry.js} +1 -1
- package/dist/solutions-components/{p-ec59efb8.js → p-c6ef8cca.js} +1 -1
- package/dist/solutions-components/{p-7b63f249.entry.js → p-c718930a.entry.js} +1 -1
- package/dist/solutions-components/{p-d8a54947.js → p-c94b0e1a.js} +1 -1
- package/dist/solutions-components/{p-e5ec69a4.js → p-cba6953c.js} +1 -1
- package/dist/solutions-components/{p-976ad17d.entry.js → p-d00ca970.entry.js} +1 -1
- package/dist/solutions-components/p-d2033cfa.entry.js +6 -0
- package/dist/solutions-components/{p-4993c7b1.js → p-d2ee8b82.js} +1 -1
- package/dist/solutions-components/{p-228c3bf3.entry.js → p-d4ab82e3.entry.js} +1 -1
- package/dist/solutions-components/{p-8f840208.entry.js → p-d7711a84.entry.js} +1 -1
- package/dist/solutions-components/{p-b7a49673.entry.js → p-d7871f0d.entry.js} +1 -1
- package/dist/solutions-components/{p-1794a1aa.entry.js → p-dc264663.entry.js} +1 -1
- package/dist/solutions-components/{p-2ace1fe7.entry.js → p-dcaae1e9.entry.js} +2 -2
- package/dist/solutions-components/{p-7f31be6a.js → p-dcebc541.js} +1 -1
- package/dist/solutions-components/{p-faf7740b.entry.js → p-de3719f2.entry.js} +1 -1
- package/dist/solutions-components/{p-32cf5a71.entry.js → p-e068dfb9.entry.js} +1 -1
- package/dist/solutions-components/{p-1cfc581f.js → p-e0b65115.js} +1 -1
- package/dist/solutions-components/{p-9901e971.js → p-e0fd4006.js} +1 -1
- package/dist/solutions-components/{p-bd3c130b.entry.js → p-e26cf5f5.entry.js} +1 -1
- package/dist/solutions-components/{p-e3bb02cc.js → p-e6798e38.js} +1 -1
- package/dist/solutions-components/{p-546a2802.js → p-ea8d2558.js} +1 -1
- package/dist/solutions-components/{p-d726e895.js → p-ef187f1d.js} +1 -1
- package/dist/solutions-components/{p-b4d92441.entry.js → p-efca5cea.entry.js} +1 -1
- package/dist/solutions-components/{p-ab8f4820.entry.js → p-f4360468.entry.js} +2 -2
- package/dist/solutions-components/{p-35f33a32.js → p-f4d7f757.js} +1 -1
- package/dist/solutions-components/{p-2b212cd0.entry.js → p-f72fa647.entry.js} +1 -1
- package/dist/solutions-components/{p-328fbcb5.js → p-f7e45464.js} +1 -1
- package/dist/solutions-components/{p-4f4f00a9.js → p-f7ffcd95.js} +1 -1
- package/dist/solutions-components/{p-30b555dc.entry.js → p-fa7c50f8.entry.js} +1 -1
- package/dist/solutions-components/{p-fb95ec69.entry.js → p-fd9fb1ba.entry.js} +1 -1
- package/dist/solutions-components/{p-9957c7b8.entry.js → p-fdb201ff.entry.js} +1 -1
- package/dist/solutions-components/{p-b3b042df.js → p-fe0add26.js} +1 -1
- package/dist/solutions-components/{p-3f6d5f14.entry.js → p-ff105078.entry.js} +1 -1
- package/dist/solutions-components/{p-451b483d.entry.js → p-ff639390.entry.js} +1 -1
- package/dist/solutions-components/solutions-components.esm.js +1 -1
- package/dist/types/preact.d.ts +2 -0
- package/package.json +2 -2
- package/dist/cjs/calcite-carousel-item.cjs.entry.js +0 -46
- package/dist/solutions-components/p-27a25ece.entry.js +0 -6
- package/dist/solutions-components/p-2c00221b.js +0 -6
- package/dist/solutions-components/p-41c34a67.js +0 -6
- package/dist/solutions-components/p-72d0eda0.entry.js +0 -29
- package/dist/solutions-components/p-743ad3a7.entry.js +0 -6
- package/dist/solutions-components/p-93d8ef73.entry.js +0 -6
- package/dist/solutions-components/p-a0b62b46.entry.js +0 -6
- package/dist/solutions-components/p-aef41a6d.entry.js +0 -11
- package/dist/solutions-components/p-af8a7aff.entry.js +0 -6
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as t,c as e,h as s,g as i}from"./p-6eb37ed2.js";import{e as a,b as c,t as h}from"./p-
|
6
|
+
import{r as t,c as e,h as s,g as i}from"./p-6eb37ed2.js";import{e as a,b as c,t as h}from"./p-66cee72b.js";import{c as n,d as o,u as r,I as l}from"./p-1ce2608d.js";import{a as d,s as p,c as b}from"./p-3e828614.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-4b9b7778.js";const f=class{constructor(s){t(this,s),this.calciteChipGroupSelect=e(this,"calciteChipGroupSelect",6),this.items=[],this.updateItems=t=>{const e=this.slotRefEl?.assignedElements({flatten:!0}).filter((t=>t?.matches("calcite-chip")));this.items=t?a(t):e,this.items?.length<1||(this.items?.forEach((t=>{t.interactive=!0,t.scale=this.scale,t.selectionMode=this.selectionMode,t.parentChipGroup=this.el})),this.setSelectedItems(!1))},this.updateSelectedItems=()=>{this.selectedItems=this.items?.filter((t=>t.selected))},this.setSelectedItems=(t,e)=>{e&&this.items?.forEach((t=>{const s=e===t;switch(this.selectionMode){case"multiple":s&&(t.selected=!t.selected);break;case"single":t.selected=!!s&&!t.selected;break;case"single-persist":t.selected=!!s}})),this.updateSelectedItems(),t&&this.calciteChipGroupSelect.emit()},this.disabled=!1,this.label=void 0,this.scale="m",this.selectionMode="none",this.selectedItems=[]}onSelectionModeChange(){this.updateItems()}connectedCallback(){n(this)}componentDidRender(){o(this),r(this)}componentDidLoad(){d(this)}async componentWillLoad(){p(this)}calciteInternalChipKeyEventListener(t){if(t.composedPath().includes(this.el)){const e=this.items?.filter((t=>!t.disabled));switch(t.detail.key){case"ArrowRight":c(e,t.detail.target,"next");break;case"ArrowLeft":c(e,t.detail.target,"previous");break;case"Home":c(e,t.detail.target,"first");break;case"End":c(e,t.detail.target,"last")}}t.stopPropagation()}calciteChipCloseListener(t){const e=t.target;this.items?.includes(e)&&(this.items?.indexOf(e)>0?c(this.items,e,"previous"):0===this.items?.indexOf(e)?c(this.items,e,"next"):c(this.items,e,"first")),this.items=this.items?.filter((t=>t!==e)),t.stopPropagation()}calciteChipSelectListener(t){t.composedPath().includes(this.el)&&this.setSelectedItems(!0,t.target),t.stopPropagation()}calciteInternalChipSelectListener(t){t.composedPath().includes(this.el)&&this.setSelectedItems(!1,t.target),t.stopPropagation()}calciteInternalSyncSelectedChips(t){t.composedPath().includes(this.el)&&(this.updateSelectedItems(),"single"===this.selectionMode&&this.selectedItems.length>1&&this.setSelectedItems(!1,t.target)),t.stopPropagation()}async setFocus(){if(await b(this),!this.disabled)return(this.selectedItems[0]||this.items[0])?.setFocus()}render(){const t="none"===this.selectionMode||"multiple"===this.selectionMode?"group":"radiogroup",{disabled:e}=this;return s(l,{key:"341dd9e8f25d4d358ea6e33740d8b851a5fa0e9d",disabled:e},s("div",{key:"66c9eaa00b7ca0c602f94a017f5b6ef6afc3bd93","aria-disabled":h(e),"aria-label":this.label,class:"container",role:t},s("slot",{key:"d62c336c6cdca0bbd5c6673975ae4a25bc8ef9df",onSlotchange:this.updateItems,ref:t=>this.slotRefEl=t})))}get el(){return i(this)}static get watchers(){return{selectionMode:["onSelectionModeChange"]}}};f.style=":host([disabled]){cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:flex}.container{display:flex;inline-size:100%;flex-wrap:wrap;gap:0.5rem}::slotted(calcite-chip){flex:none}:host([scale=s]) .container{gap:0.25rem}:host([scale=l]) .container{gap:0.75rem}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}:host([hidden]){display:none}[hidden]{display:none}";export{f as calcite_chip_group}
|
@@ -3,7 +3,7 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as t,c as i,h as s,H as o,g as e}from"./p-6eb37ed2.js";import{c as a,d as n}from"./p-f8d23498.js";import{e as h,s as l,f as c}from"./p-
|
6
|
+
import{r as t,c as i,h as s,H as o,g as e}from"./p-6eb37ed2.js";import{c as a,d as n}from"./p-f8d23498.js";import{e as h,s as l,f as c}from"./p-66cee72b.js";import{a as r,s as d,c as p}from"./p-3e828614.js";import{c as u,d as g}from"./p-8d453a3a.js";import{c as f}from"./p-1c249530.js";import{u as b,c as m,s as x,d as v}from"./p-a5fc6ab7.js";import{t as y,q as w,g as j,o as z,E as H,a as C}from"./p-3244e59a.js";import{D}from"./p-8bfa18b7.js";import{d as L}from"./p-c8d3207e.js";import"./p-aaa56cbf.js";import"./p-4b9b7778.js";import"./p-64a34d92.js";import"./p-150394be.js";import"./p-fa56b7c2.js";
|
7
7
|
/*!
|
8
8
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
9
9
|
* See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
@@ -3,7 +3,7 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as t,c as e,h as o,g as i}from"./p-6eb37ed2.js";import{c as n,d as a}from"./p-f8d23498.js";import{z as s,g as c}from"./p-
|
6
|
+
import{r as t,c as e,h as o,g as i}from"./p-6eb37ed2.js";import{c as n,d as a}from"./p-f8d23498.js";import{z as s,g as c}from"./p-66cee72b.js";import{s as l,a as r,c as d}from"./p-3e828614.js";import{c as h,d as p}from"./p-8d453a3a.js";import{c as g,d as m,s as f,u as b}from"./p-a5fc6ab7.js";import{K as k}from"./p-744d9575.js";import{o as u}from"./p-6e118057.js";import{g as v}from"./p-27d462c0.js";import"./p-1c249530.js";import"./p-4b9b7778.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-64a34d92.js";
|
7
7
|
/*!
|
8
8
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
9
9
|
* See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as e,c as t,h as i,F as n,g as a,H as s}from"./p-6eb37ed2.js";import{g as o}from"./p-8bce991a.js";import{t as l,d as c,s as r,e as d,f as h}from"./p-441f1992.js";import{g as p}from"./p-aaa56cbf.js";import{i as f}from"./p-64a34d92.js";import{s as m,a as u,c as g}from"./p-3e828614.js";import{a as b,C as v,I as x,S as y}from"./p-fa56b7c2.js";import{c as k,u as w,d as z,I as C}from"./p-1ce2608d.js";import{c as S}from"./p-1c249530.js";import{H as I}from"./p-1b229454.js";import{c as j,d as A}from"./p-42552409.js";import{c as E,s as H,d as M,u as D}from"./p-6e3f1d71.js";import{S as P,C as F,I as L,a as B}from"./p-2230d4cc.js";import"./p-8bfa18b7.js";import"./p-4b9b7778.js";const T=["ArrowUp","ArrowDown","End","Home"],O=class{constructor(i){e(this,i),this.calciteActionMenuOpen=t(this,"calciteActionMenuOpen",6),this.actionElements=[],this.guid=`calcite-action-menu-${p()}`,this.menuId=`${this.guid}-menu`,this.menuButtonId=`${this.guid}-menu-button`,this.connectMenuButtonEl=()=>{const{menuButtonId:e,menuId:t,open:i,label:n}=this,a=this.slottedMenuButtonEl||this.defaultMenuButtonEl;this.menuButtonEl!==a&&(this.disconnectMenuButtonEl(),this.menuButtonEl=a,this.setTooltipReferenceElement(),a&&(a.active=i,a.setAttribute("aria-controls",t),a.setAttribute("aria-expanded",l(i)),a.setAttribute("aria-haspopup","true"),a.id||(a.id=e),a.label||(a.label=n),a.text||(a.text=n),a.addEventListener("click",this.menuButtonClick),a.addEventListener("keydown",this.menuButtonKeyDown)))},this.disconnectMenuButtonEl=()=>{const{menuButtonEl:e}=this;e&&(e.removeEventListener("click",this.menuButtonClick),e.removeEventListener("keydown",this.menuButtonKeyDown))},this.setMenuButtonEl=e=>{const t=e.target.assignedElements({flatten:!0}).filter((e=>e?.matches("calcite-action")));this.slottedMenuButtonEl=t[0],this.connectMenuButtonEl()},this.setDefaultMenuButtonEl=e=>{this.defaultMenuButtonEl=e,this.connectMenuButtonEl()},this.handleCalciteActionClick=()=>{this.open=!1,this.setFocus()},this.menuButtonClick=()=>{this.toggleOpen()},this.updateTooltip=e=>{const t=e.target.assignedElements({flatten:!0}).filter((e=>e?.matches("calcite-tooltip")));this.tooltipEl=t[0],this.setTooltipReferenceElement()},this.setTooltipReferenceElement=()=>{const{tooltipEl:e,expanded:t,menuButtonEl:i,open:n}=this;e&&(e.referenceElement=t||n?null:i)},this.updateAction=(e,t)=>{const{guid:i,activeMenuItemIndex:n}=this,a=`${i}-action-${t}`;e.tabIndex=-1,e.setAttribute("role","menuitem"),e.id||(e.id=a),e.toggleAttribute(b,t===n)},this.updateActions=e=>{e?.forEach(this.updateAction)},this.handleDefaultSlotChange=e=>{const t=e.target.assignedElements({flatten:!0}).reduce(((e,t)=>t?.matches("calcite-action")?(e.push(t),e):t?.matches("calcite-action-group")?e.concat(Array.from(t.querySelectorAll("calcite-action"))):e),[]);this.actionElements=t.filter((e=>!e.disabled&&!e.hidden))},this.menuButtonKeyDown=e=>{const{key:t}=e,{actionElements:i,activeMenuItemIndex:n,open:a}=this;if(i.length){if(f(t)){if(e.preventDefault(),!a)return void this.toggleOpen();const t=i[n];t?t.click():this.toggleOpen(!1)}if("Tab"!==t)return"Escape"===t?(this.toggleOpen(!1),void e.preventDefault()):void this.handleActionNavigation(e,t,i);this.open=!1}},this.handleActionNavigation=(e,t,i)=>{if(!this.isValidKey(t,T))return;if(e.preventDefault(),!this.open)return this.toggleOpen(),"Home"!==t&&"ArrowDown"!==t||(this.activeMenuItemIndex=0),void("End"!==t&&"ArrowUp"!==t||(this.activeMenuItemIndex=i.length-1));"Home"===t&&(this.activeMenuItemIndex=0),"End"===t&&(this.activeMenuItemIndex=i.length-1);const n=this.activeMenuItemIndex;"ArrowUp"===t&&(this.activeMenuItemIndex=o(Math.max(n-1,-1),i.length)),"ArrowDown"===t&&(this.activeMenuItemIndex=o(n+1,i.length))},this.toggleOpenEnd=()=>{this.setFocus(),this.el.removeEventListener("calcitePopoverOpen",this.toggleOpenEnd)},this.toggleOpen=(e=!this.open)=>{this.el.addEventListener("calcitePopoverOpen",this.toggleOpenEnd),this.open=e},this.handlePopoverOpen=()=>{this.open=!0},this.handlePopoverClose=()=>{this.open=!1},this.appearance="solid",this.expanded=!1,this.flipPlacements=void 0,this.label=void 0,this.open=!1,this.overlayPositioning="absolute",this.placement="auto",this.scale=void 0,this.menuButtonEl=void 0,this.activeMenuItemIndex=-1}connectedCallback(){this.connectMenuButtonEl()}componentWillLoad(){m(this)}componentDidLoad(){u(this)}disconnectedCallback(){this.disconnectMenuButtonEl()}expandedHandler(){this.open=!1,this.setTooltipReferenceElement()}openHandler(e){this.activeMenuItemIndex=this.open?0:-1,this.menuButtonEl&&(this.menuButtonEl.active=e),this.calciteActionMenuOpen.emit(),this.setTooltipReferenceElement()}activeMenuItemIndexHandler(){this.updateActions(this.actionElements)}async setFocus(){return await g(this),c(this.menuButtonEl)}renderMenuButton(){const{appearance:e,label:t,scale:n,expanded:a}=this;return i("slot",{name:y.trigger,onSlotchange:this.setMenuButtonEl},i("calcite-action",{appearance:e,class:v.defaultTrigger,icon:x.menu,ref:this.setDefaultMenuButtonEl,scale:n,text:t,textEnabled:a}))}renderMenuItems(){const{actionElements:e,activeMenuItemIndex:t,open:n,menuId:a,menuButtonEl:s,label:o,placement:l,overlayPositioning:c,flipPlacements:r}=this,d=e[t];return i("calcite-popover",{autoClose:!0,flipPlacements:r,focusTrapDisabled:!0,label:o,offsetDistance:0,onCalcitePopoverClose:this.handlePopoverClose,onCalcitePopoverOpen:this.handlePopoverOpen,open:n,overlayPositioning:c,placement:l,pointerDisabled:!0,referenceElement:s},i("div",{"aria-activedescendant":d?.id||null,"aria-labelledby":s?.id,class:v.menu,id:a,onClick:this.handleCalciteActionClick,role:"menu",tabIndex:-1},i("slot",{onSlotchange:this.handleDefaultSlotChange})))}render(){return i(n,{key:"9feaace5a0750686cc4ad4e7ac83859cc26a7a20"},this.renderMenuButton(),this.renderMenuItems(),i("slot",{key:"ba73adb74c8c729467f300fd4ff33c7af23f2ad7",name:y.tooltip,onSlotchange:this.updateTooltip}))}isValidKey(e,t){return!!t.find((t=>t===e))}get el(){return a(this)}static get watchers(){return{expanded:["expandedHandler"],open:["openHandler"],activeMenuItemIndex:["activeMenuItemIndexHandler"]}}};O.style=":host{box-sizing:border-box;display:flex;flex-direction:column;font-size:var(--calcite-font-size-1)}::slotted(calcite-action-group:not(:last-of-type)){border-block-end-width:var(--calcite-border-width-sm)}.default-trigger{position:relative;block-size:100%;flex:0 1 auto;align-self:stretch}slot[name=trigger]::slotted(calcite-action),calcite-action::slotted([slot=trigger]){position:relative;block-size:100%;flex:0 1 auto;align-self:stretch}.menu{display:flex;max-block-size:45vh;flex-direction:column;flex-wrap:nowrap;overflow-y:auto;overflow-x:hidden;outline:2px solid transparent;outline-offset:2px;gap:var(--calcite-action-menu-items-space, 0)}:host([hidden]){display:none}[hidden]{display:none}";const $=class{constructor(i){e(this,i),this.calcitePanelClose=t(this,"calcitePanelClose",6),this.calcitePanelToggle=t(this,"calcitePanelToggle",6),this.calcitePanelScroll=t(this,"calcitePanelScroll",6),this.resizeObserver=S("resize",(()=>this.resizeHandler())),this.resizeHandler=()=>{const{panelScrollEl:e}=this;e&&"number"==typeof e.scrollHeight&&"number"==typeof e.offsetHeight&&(e.scrollHeight>e.offsetHeight?e.setAttribute("tabindex","0"):e.removeAttribute("tabindex"))},this.setContainerRef=e=>{this.containerEl=e},this.panelKeyDownHandler=e=>{this.closable&&"Escape"===e.key&&!e.defaultPrevented&&(this.handleUserClose(),e.preventDefault())},this.handleUserClose=()=>{this.closed=!0,this.calcitePanelClose.emit()},this.open=()=>{this.isClosed=!1},this.close=async()=>{const e=this.beforeClose??(()=>Promise.resolve());try{await e()}catch(e){return void requestAnimationFrame((()=>{this.closed=!1}))}this.isClosed=!0},this.collapse=()=>{this.collapsed=!this.collapsed,this.calcitePanelToggle.emit()},this.panelScrollHandler=()=>{this.calcitePanelScroll.emit()},this.handleHeaderActionsStartSlotChange=e=>{this.hasStartActions=r(e)},this.handleHeaderActionsEndSlotChange=e=>{this.hasEndActions=r(e)},this.handleHeaderMenuActionsSlotChange=e=>{this.hasMenuItems=r(e)},this.handleActionBarSlotChange=e=>{const t=d(e).filter((e=>e?.matches("calcite-action-bar")));t.forEach((e=>e.layout="horizontal")),this.hasActionBar=!!t.length},this.handleHeaderContentSlotChange=e=>{this.hasHeaderContent=r(e)},this.handleFabSlotChange=e=>{this.hasFab=r(e)},this.handleFooterActionsSlotChange=e=>{this.hasFooterActions=r(e)},this.handleFooterEndSlotChange=e=>{this.hasFooterEndContent=r(e)},this.handleFooterStartSlotChange=e=>{this.hasFooterStartContent=r(e)},this.handleFooterSlotChange=e=>{this.hasFooterContent=r(e)},this.contentBottomSlotChangeHandler=e=>{this.hasContentBottom=r(e)},this.contentTopSlotChangeHandler=e=>{this.hasContentTop=r(e)},this.setPanelScrollEl=e=>{this.panelScrollEl=e,this.resizeObserver?.disconnect(),e&&(this.resizeObserver?.observe(e),this.resizeHandler())},this.handleAlertsSlotChange=e=>{d(e)?.map((e=>{"CALCITE-ALERT"===e.nodeName&&(e.embedded=!0)}))},this.beforeClose=void 0,this.closed=!1,this.disabled=!1,this.closable=!1,this.collapsed=!1,this.collapseDirection="down",this.collapsible=!1,this.headingLevel=void 0,this.loading=!1,this.heading=void 0,this.description=void 0,this.menuOpen=!1,this.messageOverrides=void 0,this.messages=void 0,this.overlayPositioning="absolute",this.scale="m",this.isClosed=!1,this.hasStartActions=!1,this.hasEndActions=!1,this.hasMenuItems=!1,this.hasHeaderContent=!1,this.hasActionBar=!1,this.hasContentBottom=!1,this.hasContentTop=!1,this.hasFab=!1,this.hasFooterActions=!1,this.hasFooterContent=!1,this.hasFooterEndContent=!1,this.hasFooterStartContent=!1,this.defaultMessages=void 0,this.effectiveLocale="",this.showHeaderContent=!1}toggleDialog(e){e?this.close():this.open()}onMessagesChange(){}connectedCallback(){k(this),j(this),E(this)}async componentWillLoad(){m(this),await H(this)}componentDidLoad(){u(this)}componentDidRender(){w(this)}disconnectedCallback(){z(this),A(this),M(this),this.resizeObserver?.disconnect()}effectiveLocaleChange(){D(this,this.effectiveLocale)}async setFocus(){await g(this),h(this.containerEl)}async scrollContentTo(e){this.panelScrollEl?.scrollTo(e)}renderHeaderContent(){const{heading:e,headingLevel:t,description:n,hasHeaderContent:a}=this,s=e?i(I,{class:F.heading,level:t},e):null,o=n?i("span",{class:F.description},n):null;return a||!s&&!o?null:i("div",{class:F.headerContent,key:"header-content"},s,o)}renderActionBar(){return i("div",{class:F.actionBarContainer,hidden:!this.hasActionBar},i("slot",{name:P.actionBar,onSlotchange:this.handleActionBarSlotChange}))}renderHeaderSlottedContent(){return i("div",{class:F.headerContent,hidden:!this.hasHeaderContent,key:"slotted-header-content"},i("slot",{name:P.headerContent,onSlotchange:this.handleHeaderContentSlotChange}))}renderHeaderStartActions(){const{hasStartActions:e}=this;return i("div",{class:{[F.headerActionsStart]:!0,[F.headerActions]:!0},hidden:!e,key:"header-actions-start"},i("slot",{name:P.headerActionsStart,onSlotchange:this.handleHeaderActionsStartSlotChange}))}renderHeaderActionsEnd(){const{hasEndActions:e,messages:t,closable:n,collapsed:a,collapseDirection:s,collapsible:o,hasMenuItems:c}=this,{collapse:r,expand:d,close:h}=t,p=[B.expand,B.collapse];"up"===s&&p.reverse();const f=o?i("calcite-action",{"aria-expanded":l(!a),"aria-label":r,icon:a?p[0]:p[1],id:L.collapse,onClick:this.collapse,scale:this.scale,text:r,title:a?d:r}):null,m=n?i("calcite-action",{"aria-label":h,icon:B.close,id:L.close,onClick:this.handleUserClose,scale:this.scale,text:h,title:h}):null,u=i("slot",{name:P.headerActionsEnd,onSlotchange:this.handleHeaderActionsEndSlotChange}),g=e||f||m||c;return i("div",{class:{[F.headerActionsEnd]:!0,[F.headerActions]:!0},hidden:!g,key:"header-actions-end"},u,this.renderMenu(),f,m)}renderMenu(){const{hasMenuItems:e,messages:t,menuOpen:n}=this;return i("calcite-action-menu",{flipPlacements:["top","bottom"],hidden:!e,key:"menu",label:t.options,open:n,overlayPositioning:this.overlayPositioning,placement:"bottom-end"},i("calcite-action",{icon:B.menu,scale:this.scale,slot:y.trigger,text:t.options}),i("slot",{name:P.headerMenuActions,onSlotchange:this.handleHeaderMenuActionsSlotChange}))}renderHeaderNode(){const{hasHeaderContent:e,hasStartActions:t,hasEndActions:n,closable:a,collapsible:s,hasMenuItems:o,hasActionBar:l}=this,c=this.renderHeaderContent(),r=e||!!c||t||n||s||a||o;return this.showHeaderContent=r,i("header",{class:F.header,hidden:!(r||l)},i("div",{class:{[F.headerContainer]:!0,[F.headerContainerBorderEnd]:l},hidden:!r},this.renderHeaderStartActions(),this.renderHeaderSlottedContent(),c,this.renderHeaderActionsEnd()),this.renderActionBar(),this.renderContentTop())}renderFooterNode(){const{hasFooterEndContent:e,hasFooterStartContent:t,hasFooterContent:n,hasFooterActions:a}=this;return i("footer",{class:F.footer,hidden:!(t||e||n||a)},i("div",{class:F.footerContent,hidden:!n},i("slot",{name:P.footer,onSlotchange:this.handleFooterSlotChange})),i("div",{class:F.footerStart,hidden:n||!t},i("slot",{name:P.footerStart,onSlotchange:this.handleFooterStartSlotChange})),i("div",{class:F.footerEnd,hidden:n||!e},i("slot",{name:P.footerEnd,onSlotchange:this.handleFooterEndSlotChange})),i("div",{class:F.footerActions,hidden:n||!a},i("slot",{key:"footer-actions-slot",name:P.footerActions,onSlotchange:this.handleFooterActionsSlotChange})))}renderContent(){return i("div",{class:F.contentWrapper,hidden:this.collapsible&&this.collapsed,onScroll:this.panelScrollHandler,ref:this.setPanelScrollEl},i("slot",null),this.renderFab())}renderContentBottom(){return i("div",{class:F.contentBottom,hidden:!this.hasContentBottom},i("slot",{name:P.contentBottom,onSlotchange:this.contentBottomSlotChangeHandler}))}renderContentTop(){return i("div",{class:F.contentTop,hidden:!this.hasContentTop},i("slot",{name:P.contentTop,onSlotchange:this.contentTopSlotChangeHandler}))}renderFab(){return i("div",{class:F.fabContainer,hidden:!this.hasFab},i("slot",{name:P.fab,onSlotchange:this.handleFabSlotChange}))}render(){const{disabled:e,loading:t,panelKeyDownHandler:n,isClosed:a}=this,o=i("article",{key:"94df4953da14ffe331994b99f62c18fdaa3b900b","aria-busy":l(t),class:F.container,hidden:a,ref:this.setContainerRef},this.renderHeaderNode(),this.renderContent(),this.renderContentBottom(),this.renderFooterNode(),i("slot",{key:"alerts",name:P.alerts,onSlotchange:this.handleAlertsSlotChange}));return i(s,{key:"01e56f24f7ad90c69f1415f4417b35ed9539e58d",onKeyDown:n},i(C,{key:"6274bdb95260746ce36cd731d363a2d3447cfe80",disabled:e},t?i("calcite-scrim",{loading:t}):null,o))}static get assetsDirs(){return["assets"]}get el(){return a(this)}static get watchers(){return{closed:["toggleDialog"],messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};$.style=":host{box-sizing:border-box;background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-2);font-size:var(--calcite-font-size--1)}:host *{box-sizing:border-box}:host([disabled]){cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{position:relative;display:flex;block-size:100%;inline-size:100%;flex:1 1 auto;overflow:hidden;--calcite-min-header-height:calc(var(--calcite-icon-size) * 3)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}.header{margin:0px;display:flex;align-content:space-between;align-items:center;fill:var(--calcite-color-text-2);color:var(--calcite-color-text-2)}.heading{margin:0px;padding:0px;font-weight:var(--calcite-font-weight-medium)}.header .heading{flex:1 1 auto;padding:0.5rem}:host([scale=s]){--calcite-internal-panel-default-padding:var(--calcite-spacing-sm);--calcite-internal-panel-header-vertical-padding:10px}:host([scale=s]) .header-content .heading{font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=s]) .header-content .description{font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=m]){--calcite-internal-panel-default-padding:var(--calcite-spacing-md);--calcite-internal-panel-header-vertical-padding:var(--calcite-spacing-lg)}:host([scale=m]) .header-content .heading{font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=m]) .header-content .description{font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]){--calcite-internal-panel-default-padding:var(--calcite-spacing-xl);--calcite-internal-panel-header-vertical-padding:var(--calcite-spacing-xxl)}:host([scale=l]) .header-content .heading{font-size:var(--calcite-font-size-1);line-height:1.5rem}:host([scale=l]) .header-content .description{font-size:var(--calcite-font-size-0);line-height:1.25rem}.content-top,.content-bottom{display:flex;align-items:flex-start;align-self:stretch;border-block-start:1px solid var(--calcite-color-border-3);background-color:var(--calcite-color-foreground-1)}.container{position:relative;margin:0px;display:flex;inline-size:100%;flex:1 1 auto;flex-direction:column;align-items:stretch;background-color:var(--calcite-color-background);padding:0px;transition:max-block-size var(--calcite-animation-timing), inline-size var(--calcite-animation-timing)}.container[hidden]{display:none}.header{z-index:var(--calcite-z-index-header);display:flex;flex-direction:column;background-color:var(--calcite-color-foreground-1);border-block-end:var(--calcite-panel-header-border-block-end, 1px solid var(--calcite-color-border-3))}.header-container{display:flex;inline-size:100%;flex-direction:row;align-items:stretch;justify-content:flex-start;flex:0 0 auto}.header-container--border-end{border-block-end:1px solid var(--calcite-color-border-3)}.action-bar-container{inline-size:100%}.action-bar-container ::slotted(calcite-action-bar){inline-size:100%}.header-content{display:flex;flex-direction:column;overflow:hidden;padding-inline:0.75rem;padding-block:0.875rem;margin-inline-end:auto}.header-content .heading,.header-content .description{display:block;overflow-wrap:break-word;padding:0px}.header-content .heading{margin-inline:0px;margin-block:0px 0.25rem;font-weight:var(--calcite-font-weight-medium);color:var(--calcite-color-text-1)}.header-content .heading:only-child{margin-block-end:0px}.header-content .description{color:var(--calcite-color-text-2)}.back-button{border-width:0px;border-style:solid;border-color:var(--calcite-color-border-3);border-inline-end-width:1px}.header-actions{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:stretch}.header-actions--end{margin-inline-start:auto}.content-wrapper{position:relative;display:flex;block-size:100%;flex:1 1 auto;flex-direction:column;flex-wrap:nowrap;align-items:stretch;overflow:auto;background-color:var(--calcite-color-background);outline-color:transparent;padding:var(--calcite-panel-content-space, 0)}.content-wrapper:focus-visible{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-color-brand));outline-offset:calc(\n -2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-offset-invert-focus),\n 1\n )\n )\n )}.content-top,.content-bottom{padding:var(--calcite-internal-panel-default-padding)}.header-content{padding-block:var(--calcite-internal-panel-header-vertical-padding);padding-inline:var(--calcite-internal-panel-default-padding)}.footer{margin-block-start:auto;display:flex;flex-direction:row;align-content:space-between;align-items:center;justify-content:center;background-color:var(--calcite-color-foreground-1);font-size:var(--calcite-font-size--2);line-height:1.375;border-block-start:1px solid var(--calcite-color-border-3);padding:var(--calcite-panel-footer-padding, var(--calcite-internal-panel-default-padding))}.footer-content{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:center}.footer-actions{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:space-evenly;gap:var(--calcite-internal-panel-default-padding)}.footer-start{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:flex-start;margin-inline-end:auto;gap:var(--calcite-internal-panel-default-padding)}.footer-end{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:flex-end;margin-inline-start:auto;gap:var(--calcite-internal-panel-default-padding)}.fab-container{position:sticky;inset-block-end:0px;z-index:var(--calcite-z-index-sticky);margin-block:0px;margin-inline:auto;display:block;padding:0.5rem;inset-inline:0;inline-size:-moz-fit-content;inline-size:fit-content}:host([hidden]){display:none}[hidden]{display:none}";export{O as calcite_action_menu,$ as calcite_panel}
|
6
|
+
import{r as e,c as t,h as i,F as n,g as a,H as s}from"./p-6eb37ed2.js";import{g as o}from"./p-8bce991a.js";import{t as l,d as c,s as r,e as d,f as h}from"./p-66cee72b.js";import{g as p}from"./p-aaa56cbf.js";import{i as f}from"./p-64a34d92.js";import{s as m,a as u,c as g}from"./p-3e828614.js";import{a as b,C as v,I as x,S as y}from"./p-fa56b7c2.js";import{c as k,u as w,d as z,I as C}from"./p-1ce2608d.js";import{c as S}from"./p-1c249530.js";import{H as I}from"./p-1b229454.js";import{c as j,d as A}from"./p-8d453a3a.js";import{c as E,s as H,d as M,u as D}from"./p-a5fc6ab7.js";import{S as P,C as F,I as L,a as B}from"./p-2230d4cc.js";import"./p-8bfa18b7.js";import"./p-4b9b7778.js";const T=["ArrowUp","ArrowDown","End","Home"],O=class{constructor(i){e(this,i),this.calciteActionMenuOpen=t(this,"calciteActionMenuOpen",6),this.actionElements=[],this.guid=`calcite-action-menu-${p()}`,this.menuId=`${this.guid}-menu`,this.menuButtonId=`${this.guid}-menu-button`,this.connectMenuButtonEl=()=>{const{menuButtonId:e,menuId:t,open:i,label:n}=this,a=this.slottedMenuButtonEl||this.defaultMenuButtonEl;this.menuButtonEl!==a&&(this.disconnectMenuButtonEl(),this.menuButtonEl=a,this.setTooltipReferenceElement(),a&&(a.active=i,a.setAttribute("aria-controls",t),a.setAttribute("aria-expanded",l(i)),a.setAttribute("aria-haspopup","true"),a.id||(a.id=e),a.label||(a.label=n),a.text||(a.text=n),a.addEventListener("click",this.menuButtonClick),a.addEventListener("keydown",this.menuButtonKeyDown)))},this.disconnectMenuButtonEl=()=>{const{menuButtonEl:e}=this;e&&(e.removeEventListener("click",this.menuButtonClick),e.removeEventListener("keydown",this.menuButtonKeyDown))},this.setMenuButtonEl=e=>{const t=e.target.assignedElements({flatten:!0}).filter((e=>e?.matches("calcite-action")));this.slottedMenuButtonEl=t[0],this.connectMenuButtonEl()},this.setDefaultMenuButtonEl=e=>{this.defaultMenuButtonEl=e,this.connectMenuButtonEl()},this.handleCalciteActionClick=()=>{this.open=!1,this.setFocus()},this.menuButtonClick=()=>{this.toggleOpen()},this.updateTooltip=e=>{const t=e.target.assignedElements({flatten:!0}).filter((e=>e?.matches("calcite-tooltip")));this.tooltipEl=t[0],this.setTooltipReferenceElement()},this.setTooltipReferenceElement=()=>{const{tooltipEl:e,expanded:t,menuButtonEl:i,open:n}=this;e&&(e.referenceElement=t||n?null:i)},this.updateAction=(e,t)=>{const{guid:i,activeMenuItemIndex:n}=this,a=`${i}-action-${t}`;e.tabIndex=-1,e.setAttribute("role","menuitem"),e.id||(e.id=a),e.toggleAttribute(b,t===n)},this.updateActions=e=>{e?.forEach(this.updateAction)},this.handleDefaultSlotChange=e=>{const t=e.target.assignedElements({flatten:!0}).reduce(((e,t)=>t?.matches("calcite-action")?(e.push(t),e):t?.matches("calcite-action-group")?e.concat(Array.from(t.querySelectorAll("calcite-action"))):e),[]);this.actionElements=t.filter((e=>!e.disabled&&!e.hidden))},this.menuButtonKeyDown=e=>{const{key:t}=e,{actionElements:i,activeMenuItemIndex:n,open:a}=this;if(i.length){if(f(t)){if(e.preventDefault(),!a)return void this.toggleOpen();const t=i[n];t?t.click():this.toggleOpen(!1)}if("Tab"!==t)return"Escape"===t?(this.toggleOpen(!1),void e.preventDefault()):void this.handleActionNavigation(e,t,i);this.open=!1}},this.handleActionNavigation=(e,t,i)=>{if(!this.isValidKey(t,T))return;if(e.preventDefault(),!this.open)return this.toggleOpen(),"Home"!==t&&"ArrowDown"!==t||(this.activeMenuItemIndex=0),void("End"!==t&&"ArrowUp"!==t||(this.activeMenuItemIndex=i.length-1));"Home"===t&&(this.activeMenuItemIndex=0),"End"===t&&(this.activeMenuItemIndex=i.length-1);const n=this.activeMenuItemIndex;"ArrowUp"===t&&(this.activeMenuItemIndex=o(Math.max(n-1,-1),i.length)),"ArrowDown"===t&&(this.activeMenuItemIndex=o(n+1,i.length))},this.toggleOpenEnd=()=>{this.setFocus(),this.el.removeEventListener("calcitePopoverOpen",this.toggleOpenEnd)},this.toggleOpen=(e=!this.open)=>{this.el.addEventListener("calcitePopoverOpen",this.toggleOpenEnd),this.open=e},this.handlePopoverOpen=()=>{this.open=!0},this.handlePopoverClose=()=>{this.open=!1},this.appearance="solid",this.expanded=!1,this.flipPlacements=void 0,this.label=void 0,this.open=!1,this.overlayPositioning="absolute",this.placement="auto",this.scale=void 0,this.menuButtonEl=void 0,this.activeMenuItemIndex=-1}connectedCallback(){this.connectMenuButtonEl()}componentWillLoad(){m(this)}componentDidLoad(){u(this)}disconnectedCallback(){this.disconnectMenuButtonEl()}expandedHandler(){this.open=!1,this.setTooltipReferenceElement()}openHandler(e){this.activeMenuItemIndex=this.open?0:-1,this.menuButtonEl&&(this.menuButtonEl.active=e),this.calciteActionMenuOpen.emit(),this.setTooltipReferenceElement()}activeMenuItemIndexHandler(){this.updateActions(this.actionElements)}async setFocus(){return await g(this),c(this.menuButtonEl)}renderMenuButton(){const{appearance:e,label:t,scale:n,expanded:a}=this;return i("slot",{name:y.trigger,onSlotchange:this.setMenuButtonEl},i("calcite-action",{appearance:e,class:v.defaultTrigger,icon:x.menu,ref:this.setDefaultMenuButtonEl,scale:n,text:t,textEnabled:a}))}renderMenuItems(){const{actionElements:e,activeMenuItemIndex:t,open:n,menuId:a,menuButtonEl:s,label:o,placement:l,overlayPositioning:c,flipPlacements:r}=this,d=e[t];return i("calcite-popover",{autoClose:!0,flipPlacements:r,focusTrapDisabled:!0,label:o,offsetDistance:0,onCalcitePopoverClose:this.handlePopoverClose,onCalcitePopoverOpen:this.handlePopoverOpen,open:n,overlayPositioning:c,placement:l,pointerDisabled:!0,referenceElement:s},i("div",{"aria-activedescendant":d?.id||null,"aria-labelledby":s?.id,class:v.menu,id:a,onClick:this.handleCalciteActionClick,role:"menu",tabIndex:-1},i("slot",{onSlotchange:this.handleDefaultSlotChange})))}render(){return i(n,{key:"9feaace5a0750686cc4ad4e7ac83859cc26a7a20"},this.renderMenuButton(),this.renderMenuItems(),i("slot",{key:"ba73adb74c8c729467f300fd4ff33c7af23f2ad7",name:y.tooltip,onSlotchange:this.updateTooltip}))}isValidKey(e,t){return!!t.find((t=>t===e))}get el(){return a(this)}static get watchers(){return{expanded:["expandedHandler"],open:["openHandler"],activeMenuItemIndex:["activeMenuItemIndexHandler"]}}};O.style=":host{box-sizing:border-box;display:flex;flex-direction:column;font-size:var(--calcite-font-size-1)}::slotted(calcite-action-group:not(:last-of-type)){border-block-end-width:var(--calcite-border-width-sm)}.default-trigger{position:relative;block-size:100%;flex:0 1 auto;align-self:stretch}slot[name=trigger]::slotted(calcite-action),calcite-action::slotted([slot=trigger]){position:relative;block-size:100%;flex:0 1 auto;align-self:stretch}.menu{display:flex;max-block-size:45vh;flex-direction:column;flex-wrap:nowrap;overflow-y:auto;overflow-x:hidden;outline:2px solid transparent;outline-offset:2px;gap:var(--calcite-action-menu-items-space, 0)}:host([hidden]){display:none}[hidden]{display:none}";const $=class{constructor(i){e(this,i),this.calcitePanelClose=t(this,"calcitePanelClose",6),this.calcitePanelToggle=t(this,"calcitePanelToggle",6),this.calcitePanelScroll=t(this,"calcitePanelScroll",6),this.resizeObserver=S("resize",(()=>this.resizeHandler())),this.resizeHandler=()=>{const{panelScrollEl:e}=this;e&&"number"==typeof e.scrollHeight&&"number"==typeof e.offsetHeight&&(e.scrollHeight>e.offsetHeight?e.setAttribute("tabindex","0"):e.removeAttribute("tabindex"))},this.setContainerRef=e=>{this.containerEl=e},this.panelKeyDownHandler=e=>{this.closable&&"Escape"===e.key&&!e.defaultPrevented&&(this.handleUserClose(),e.preventDefault())},this.handleUserClose=()=>{this.closed=!0,this.calcitePanelClose.emit()},this.open=()=>{this.isClosed=!1},this.close=async()=>{const e=this.beforeClose??(()=>Promise.resolve());try{await e()}catch(e){return void requestAnimationFrame((()=>{this.closed=!1}))}this.isClosed=!0},this.collapse=()=>{this.collapsed=!this.collapsed,this.calcitePanelToggle.emit()},this.panelScrollHandler=()=>{this.calcitePanelScroll.emit()},this.handleHeaderActionsStartSlotChange=e=>{this.hasStartActions=r(e)},this.handleHeaderActionsEndSlotChange=e=>{this.hasEndActions=r(e)},this.handleHeaderMenuActionsSlotChange=e=>{this.hasMenuItems=r(e)},this.handleActionBarSlotChange=e=>{const t=d(e).filter((e=>e?.matches("calcite-action-bar")));t.forEach((e=>e.layout="horizontal")),this.hasActionBar=!!t.length},this.handleHeaderContentSlotChange=e=>{this.hasHeaderContent=r(e)},this.handleFabSlotChange=e=>{this.hasFab=r(e)},this.handleFooterActionsSlotChange=e=>{this.hasFooterActions=r(e)},this.handleFooterEndSlotChange=e=>{this.hasFooterEndContent=r(e)},this.handleFooterStartSlotChange=e=>{this.hasFooterStartContent=r(e)},this.handleFooterSlotChange=e=>{this.hasFooterContent=r(e)},this.contentBottomSlotChangeHandler=e=>{this.hasContentBottom=r(e)},this.contentTopSlotChangeHandler=e=>{this.hasContentTop=r(e)},this.setPanelScrollEl=e=>{this.panelScrollEl=e,this.resizeObserver?.disconnect(),e&&(this.resizeObserver?.observe(e),this.resizeHandler())},this.handleAlertsSlotChange=e=>{d(e)?.map((e=>{"CALCITE-ALERT"===e.nodeName&&(e.embedded=!0)}))},this.beforeClose=void 0,this.closed=!1,this.disabled=!1,this.closable=!1,this.collapsed=!1,this.collapseDirection="down",this.collapsible=!1,this.headingLevel=void 0,this.loading=!1,this.heading=void 0,this.description=void 0,this.menuOpen=!1,this.messageOverrides=void 0,this.messages=void 0,this.overlayPositioning="absolute",this.scale="m",this.isClosed=!1,this.hasStartActions=!1,this.hasEndActions=!1,this.hasMenuItems=!1,this.hasHeaderContent=!1,this.hasActionBar=!1,this.hasContentBottom=!1,this.hasContentTop=!1,this.hasFab=!1,this.hasFooterActions=!1,this.hasFooterContent=!1,this.hasFooterEndContent=!1,this.hasFooterStartContent=!1,this.defaultMessages=void 0,this.effectiveLocale="",this.showHeaderContent=!1}toggleDialog(e){e?this.close():this.open()}onMessagesChange(){}connectedCallback(){k(this),j(this),E(this)}async componentWillLoad(){m(this),await H(this)}componentDidLoad(){u(this)}componentDidRender(){w(this)}disconnectedCallback(){z(this),A(this),M(this),this.resizeObserver?.disconnect()}effectiveLocaleChange(){D(this,this.effectiveLocale)}async setFocus(){await g(this),h(this.containerEl)}async scrollContentTo(e){this.panelScrollEl?.scrollTo(e)}renderHeaderContent(){const{heading:e,headingLevel:t,description:n,hasHeaderContent:a}=this,s=e?i(I,{class:F.heading,level:t},e):null,o=n?i("span",{class:F.description},n):null;return a||!s&&!o?null:i("div",{class:F.headerContent,key:"header-content"},s,o)}renderActionBar(){return i("div",{class:F.actionBarContainer,hidden:!this.hasActionBar},i("slot",{name:P.actionBar,onSlotchange:this.handleActionBarSlotChange}))}renderHeaderSlottedContent(){return i("div",{class:F.headerContent,hidden:!this.hasHeaderContent,key:"slotted-header-content"},i("slot",{name:P.headerContent,onSlotchange:this.handleHeaderContentSlotChange}))}renderHeaderStartActions(){const{hasStartActions:e}=this;return i("div",{class:{[F.headerActionsStart]:!0,[F.headerActions]:!0},hidden:!e,key:"header-actions-start"},i("slot",{name:P.headerActionsStart,onSlotchange:this.handleHeaderActionsStartSlotChange}))}renderHeaderActionsEnd(){const{hasEndActions:e,messages:t,closable:n,collapsed:a,collapseDirection:s,collapsible:o,hasMenuItems:c}=this,{collapse:r,expand:d,close:h}=t,p=[B.expand,B.collapse];"up"===s&&p.reverse();const f=o?i("calcite-action",{"aria-expanded":l(!a),"aria-label":r,icon:a?p[0]:p[1],id:L.collapse,onClick:this.collapse,scale:this.scale,text:r,title:a?d:r}):null,m=n?i("calcite-action",{"aria-label":h,icon:B.close,id:L.close,onClick:this.handleUserClose,scale:this.scale,text:h,title:h}):null,u=i("slot",{name:P.headerActionsEnd,onSlotchange:this.handleHeaderActionsEndSlotChange}),g=e||f||m||c;return i("div",{class:{[F.headerActionsEnd]:!0,[F.headerActions]:!0},hidden:!g,key:"header-actions-end"},u,this.renderMenu(),f,m)}renderMenu(){const{hasMenuItems:e,messages:t,menuOpen:n}=this;return i("calcite-action-menu",{flipPlacements:["top","bottom"],hidden:!e,key:"menu",label:t.options,open:n,overlayPositioning:this.overlayPositioning,placement:"bottom-end"},i("calcite-action",{icon:B.menu,scale:this.scale,slot:y.trigger,text:t.options}),i("slot",{name:P.headerMenuActions,onSlotchange:this.handleHeaderMenuActionsSlotChange}))}renderHeaderNode(){const{hasHeaderContent:e,hasStartActions:t,hasEndActions:n,closable:a,collapsible:s,hasMenuItems:o,hasActionBar:l}=this,c=this.renderHeaderContent(),r=e||!!c||t||n||s||a||o;return this.showHeaderContent=r,i("header",{class:F.header,hidden:!(r||l)},i("div",{class:{[F.headerContainer]:!0,[F.headerContainerBorderEnd]:l},hidden:!r},this.renderHeaderStartActions(),this.renderHeaderSlottedContent(),c,this.renderHeaderActionsEnd()),this.renderActionBar(),this.renderContentTop())}renderFooterNode(){const{hasFooterEndContent:e,hasFooterStartContent:t,hasFooterContent:n,hasFooterActions:a}=this;return i("footer",{class:F.footer,hidden:!(t||e||n||a)},i("div",{class:F.footerContent,hidden:!n},i("slot",{name:P.footer,onSlotchange:this.handleFooterSlotChange})),i("div",{class:F.footerStart,hidden:n||!t},i("slot",{name:P.footerStart,onSlotchange:this.handleFooterStartSlotChange})),i("div",{class:F.footerEnd,hidden:n||!e},i("slot",{name:P.footerEnd,onSlotchange:this.handleFooterEndSlotChange})),i("div",{class:F.footerActions,hidden:n||!a},i("slot",{key:"footer-actions-slot",name:P.footerActions,onSlotchange:this.handleFooterActionsSlotChange})))}renderContent(){return i("div",{class:F.contentWrapper,hidden:this.collapsible&&this.collapsed,onScroll:this.panelScrollHandler,ref:this.setPanelScrollEl},i("slot",null),this.renderFab())}renderContentBottom(){return i("div",{class:F.contentBottom,hidden:!this.hasContentBottom},i("slot",{name:P.contentBottom,onSlotchange:this.contentBottomSlotChangeHandler}))}renderContentTop(){return i("div",{class:F.contentTop,hidden:!this.hasContentTop},i("slot",{name:P.contentTop,onSlotchange:this.contentTopSlotChangeHandler}))}renderFab(){return i("div",{class:F.fabContainer,hidden:!this.hasFab},i("slot",{name:P.fab,onSlotchange:this.handleFabSlotChange}))}render(){const{disabled:e,loading:t,panelKeyDownHandler:n,isClosed:a}=this,o=i("article",{key:"94df4953da14ffe331994b99f62c18fdaa3b900b","aria-busy":l(t),class:F.container,hidden:a,ref:this.setContainerRef},this.renderHeaderNode(),this.renderContent(),this.renderContentBottom(),this.renderFooterNode(),i("slot",{key:"alerts",name:P.alerts,onSlotchange:this.handleAlertsSlotChange}));return i(s,{key:"01e56f24f7ad90c69f1415f4417b35ed9539e58d",onKeyDown:n},i(C,{key:"6274bdb95260746ce36cd731d363a2d3447cfe80",disabled:e},t?i("calcite-scrim",{loading:t}):null,o))}static get assetsDirs(){return["assets"]}get el(){return a(this)}static get watchers(){return{closed:["toggleDialog"],messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};$.style=":host{box-sizing:border-box;background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-2);font-size:var(--calcite-font-size--1)}:host *{box-sizing:border-box}:host([disabled]){cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{position:relative;display:flex;block-size:100%;inline-size:100%;flex:1 1 auto;overflow:hidden;--calcite-min-header-height:calc(var(--calcite-icon-size) * 3)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}.header{margin:0px;display:flex;align-content:space-between;align-items:center;fill:var(--calcite-color-text-2);color:var(--calcite-color-text-2)}.heading{margin:0px;padding:0px;font-weight:var(--calcite-font-weight-medium)}.header .heading{flex:1 1 auto;padding:0.5rem}:host([scale=s]){--calcite-internal-panel-default-padding:var(--calcite-spacing-sm);--calcite-internal-panel-header-vertical-padding:10px}:host([scale=s]) .header-content .heading{font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=s]) .header-content .description{font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=m]){--calcite-internal-panel-default-padding:var(--calcite-spacing-md);--calcite-internal-panel-header-vertical-padding:var(--calcite-spacing-lg)}:host([scale=m]) .header-content .heading{font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=m]) .header-content .description{font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]){--calcite-internal-panel-default-padding:var(--calcite-spacing-xl);--calcite-internal-panel-header-vertical-padding:var(--calcite-spacing-xxl)}:host([scale=l]) .header-content .heading{font-size:var(--calcite-font-size-1);line-height:1.5rem}:host([scale=l]) .header-content .description{font-size:var(--calcite-font-size-0);line-height:1.25rem}.content-top,.content-bottom{display:flex;align-items:flex-start;align-self:stretch;border-block-start:1px solid var(--calcite-color-border-3);background-color:var(--calcite-color-foreground-1)}.container{position:relative;margin:0px;display:flex;inline-size:100%;flex:1 1 auto;flex-direction:column;align-items:stretch;background-color:var(--calcite-color-background);padding:0px;transition:max-block-size var(--calcite-animation-timing), inline-size var(--calcite-animation-timing)}.container[hidden]{display:none}.header{z-index:var(--calcite-z-index-header);display:flex;flex-direction:column;background-color:var(--calcite-color-foreground-1);border-block-end:var(--calcite-panel-header-border-block-end, 1px solid var(--calcite-color-border-3))}.header-container{display:flex;inline-size:100%;flex-direction:row;align-items:stretch;justify-content:flex-start;flex:0 0 auto}.header-container--border-end{border-block-end:1px solid var(--calcite-color-border-3)}.action-bar-container{inline-size:100%}.action-bar-container ::slotted(calcite-action-bar){inline-size:100%}.header-content{display:flex;flex-direction:column;overflow:hidden;padding-inline:0.75rem;padding-block:0.875rem;margin-inline-end:auto}.header-content .heading,.header-content .description{display:block;overflow-wrap:break-word;padding:0px}.header-content .heading{margin-inline:0px;margin-block:0px 0.25rem;font-weight:var(--calcite-font-weight-medium);color:var(--calcite-color-text-1)}.header-content .heading:only-child{margin-block-end:0px}.header-content .description{color:var(--calcite-color-text-2)}.back-button{border-width:0px;border-style:solid;border-color:var(--calcite-color-border-3);border-inline-end-width:1px}.header-actions{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:stretch}.header-actions--end{margin-inline-start:auto}.content-wrapper{position:relative;display:flex;block-size:100%;flex:1 1 auto;flex-direction:column;flex-wrap:nowrap;align-items:stretch;overflow:auto;background-color:var(--calcite-color-background);outline-color:transparent;padding:var(--calcite-panel-content-space, 0)}.content-wrapper:focus-visible{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-color-brand));outline-offset:calc(\n -2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-offset-invert-focus),\n 1\n )\n )\n )}.content-top,.content-bottom{padding:var(--calcite-internal-panel-default-padding)}.header-content{padding-block:var(--calcite-internal-panel-header-vertical-padding);padding-inline:var(--calcite-internal-panel-default-padding)}.footer{margin-block-start:auto;display:flex;flex-direction:row;align-content:space-between;align-items:center;justify-content:center;background-color:var(--calcite-color-foreground-1);font-size:var(--calcite-font-size--2);line-height:1.375;border-block-start:1px solid var(--calcite-color-border-3);padding:var(--calcite-panel-footer-padding, var(--calcite-internal-panel-default-padding))}.footer-content{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:center}.footer-actions{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:space-evenly;gap:var(--calcite-internal-panel-default-padding)}.footer-start{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:flex-start;margin-inline-end:auto;gap:var(--calcite-internal-panel-default-padding)}.footer-end{display:flex;flex:1 1 0%;flex-direction:row;align-items:center;justify-content:flex-end;margin-inline-start:auto;gap:var(--calcite-internal-panel-default-padding)}.fab-container{position:sticky;inset-block-end:0px;z-index:var(--calcite-z-index-sticky);margin-block:0px;margin-inline:auto;display:block;padding:0.5rem;inset-inline:0;inline-size:-moz-fit-content;inline-size:fit-content}:host([hidden]){display:none}[hidden]{display:none}";export{O as calcite_action_menu,$ as calcite_panel}
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{d as
|
6
|
+
import{d as a}from"./p-fe0add26.js";import"./p-6eb37ed2.js";import"./p-365169c2.js";import"./p-66cee72b.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-1ce2608d.js";import"./p-4b9b7778.js";import"./p-64a34d92.js";import"./p-2caf1f94.js";import"./p-27d462c0.js";import"./p-3e828614.js";import"./p-8d453a3a.js";import"./p-1c249530.js";import"./p-174aa4da.js";import"./p-0ef9d36b.js";import"./p-12be6545.js";import"./p-d9e930c8.js";import"./p-a5fc6ab7.js";import"./p-ef67c743.js";import"./p-14f027b5.js";var r={name:"en-gb",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekStart:1,yearStart:4,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},ordinal:function(a){var r=["th","st","nd","rd"],e=a%100;return"["+a+(r[(e-20)%10]||r[e]||r[0])+"]"}};a.locale(r,null,!0);export{r as default}
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as t,c as a,h as n,H as s,g as e,F as i}from"./p-6eb37ed2.js";import{d as r,i as o,e as l,s as c,f as p,E as u,l as g,h as d,c as h}from"./p-41c34a67.js";import"./p-3d0e9be4.js";import"./p-4cd4cb85.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-ac122d9e.js";import"./p-720a12c0.js";const m="instant-apps-components__ckeditor-wrapper",v=class{constructor(n){t(this,n),this.isFocused=a(this,"isFocused",7),this.dataChanged=a(this,"dataChanged",7),this.value=void 0,this.editorInstance=void 0,this.config=void 0}updateValue(){this.value&&this.editorInstance.setData(this.value)}async componentDidLoad(){this.init()}componentDidUpdate(){this.editorInstance.setData(this.value)}render(){return n(s,{key:"4a000cee4310d40e940c97d16f24c78415083f1b"},n("div",{key:"55b2e7ddd6b259b58e19f8946d2198df1fd7b579"}))}init(){this.applyStyles(),this.initEditor()}applyStyles(){if(document.getElementById(m))return;const t=document.createElement("style");t.id=m,t.innerHTML="\n .ck.ck-reset.ck-editor.ck-rounded-corners {\n margin-top: 10px !important;\n margin-left: 55px !important;\n }\n .ck-editor__editable {\n height: 70px !important;\n font-size: 0.875rem !important;\n line-height: \t1.375 !important;\n color: var(--calcite-color-text-1) !important;\n }\n\n .ck.ck-editor__editable_inline>:first-child,\n .ck.ck-editor__editable_inline>:last-child {\n --ck-spacing-large: 0.5rem !important;\n }\n\n .ck.ck-balloon-panel.ck-powered-by-balloon {\n --ck-z-modal: 700;\n z-index: 700;\n }\n\n .calcite-mode-dark .ck-editor__editable {\n color: var(--calcite-color-text-inverse) !important;\n }\n",document.head.prepend(t)}async initEditor(){const t=await this.createEditor();t&&(this.editorInstance=t,(this.value||""===this.value)&&t.setData(this.value),t.editing.view.document.on("change:isFocused",this.getEditorFocusedCallback(t)))}async createEditor(){try{let t;return t=this.config?await ClassicEditor.create(this.el,this.config):await ClassicEditor.create(this.el),this.editorInstance=t,Promise.resolve(t)}catch(t){return console.error(t),Promise.reject(null)}}getEditorFocusedCallback(t){return(a,n,s)=>{if(s)this.isFocused.emit();else{const a=t.getData();this.value!==a&&(this.value=a,this.dataChanged.emit(a))}}}get el(){return e(this)}static get watchers(){return{value:["updateValue"]}}};v.style=":host{display:block}";const _="instant-apps-language-translator-item",b={section:`${_}__section`,selected:`${_}__section--selected`,collapsed:`${_}__section--collapsed`,topRow:`${_}__top-row`,labelContainer:`${_}__label-container`,label:`${_}__label`,uiLocationPopoverContent:`${_}__ui-location-popover-content`,uiLocationItems:`${_}__ui-location-items`,uiLocationItem:`${_}__ui-location-item`,infoIcon:`${_}__info-icon`,infoButton:`${_}__info-button`,tip:`${_}__tip`,nestedInput:`${_}__nested-input`},f=class{constructor(n){t(this,n),this.translatorItemDataUpdated=a(this,"translatorItemDataUpdated",7),this.userInputs={},this.translatedInputs={},this.fieldName=void 0,this.translatedLanguageLabels=void 0,this.setting=void 0,this.userLocaleInputOnChangeCallback=void 0,this.translatedLocaleInputOnChangeCallback=void 0}get isTextEditor(){return this.setting.type===r.TextEditor}get calciteMode(){return o()?l.Dark:l.Light}get hasNestedContent(){var t;return!!(null===(t=this.setting)||void 0===t?void 0:t.content)}get tipID(){return`${this.fieldName}goTo`}componentDidLoad(){this.isTextEditor&&c.onChange("uiData",(()=>this.handleEditorCollapse()))}render(){var t;return"content"in this.setting&&(null===(t=this.setting.content)||void 0===t?void 0:t.every((t=>{var a;return 0===(null===(a=null==t?void 0:t.content)||void 0===a?void 0:a.length)})))?n(i,null):n(s,{class:this.calciteMode},this.renderBase(),this.renderPopover())}renderBase(){return n("div",{class:_},this.renderUserLocaleSection(),this.renderTranslatedLanguageSection())}renderPopover(){const t=this.getTip();return n("calcite-popover",{referenceElement:this.tipID,label:"","auto-close":"true",placement:"trailing",closable:!0},n("span",{class:b.uiLocationPopoverContent},n("span",{class:b.uiLocationItems},this.getUILocation()),t?n("span",{class:b.tip},t):null))}renderUserLocaleSection(){const t=this.getUIDataItem(),a=null==t?void 0:t.userLocaleData,s=null==a?void 0:a.value,e=this.setting.id;return n("div",{class:`${b.section}${(null==t?void 0:t.selected)?` ${b.selected}`:""}`},this.renderItemHeader(p.User,null==a?void 0:a.label,e),this.handleInputRender(p.User,s,e))}renderTranslatedLanguageSection(){var t,a;const s=this.getUIDataItem(),e=this.setting.id,i=c.get("currentLanguage"),r=c.get("portalItemResourceT9n"),o=null===(t=this.translatedLanguageLabels)||void 0===t?void 0:t[this.fieldName],l=null===(a=null==r?void 0:r[i])||void 0===a?void 0:a[e];return n("div",{class:`${b.section}${(null==s?void 0:s.selected)?` ${b.selected}`:""}`},this.renderItemHeader(p.Translation,o,e),this.handleInputRender(p.Translation,l,e))}handleInputRender(t,a,n){const s=this.getUIDataItem();return(null==s?void 0:s.expanded)?this.hasNestedContent?this.renderNestedInputs(t):this.renderInput(t,a,n):null}renderNestedInputs(t,a){const n=null!=a?a:this.setting,{content:s}=n;return null==s?void 0:s.map((a=>a.hasOwnProperty("content")?this.renderNestedInputs(t,a):this.renderNestedInput(t,a)))}renderNestedInput(t,a){var s;const e=c.get("currentLanguage"),i=c.get("portalItemResourceT9n"),r=null==a?void 0:a.id,o=null==i?void 0:i[e],l=null==o?void 0:o[r],{label:u,value:g,id:d}=a,h=t===p.Translation?null===(s=this.translatedLanguageLabels)||void 0===s?void 0:s[d]:u,m=t===p.User?g:l;return n("div",{class:b.nestedInput},this.renderItemHeader(t,h,r,a),this.renderInput(t,m,r,a))}renderItemHeader(t,a,s,e){const i=!this.hasNestedContent||!!e;return n("div",{class:b.topRow},this.renderItemHeaderLabel(t,a,e),i?this.renderCopyButton(t,s):null)}renderItemHeaderLabel(t,a,s){const e=t===p.User&&!s;return n("div",{class:b.labelContainer},s?null:this.renderExpandCollapseButton(),n("calcite-icon",{icon:this.getIcon(s),scale:"s"}),n("span",{class:b.label},a),e?this.renderInfoButton():null)}renderExpandCollapseButton(){const t=this.getUIDataItem(),a=(null==t?void 0:t.expanded)?u.Expanded:u.Collapsed;return n("calcite-action",{onClick:this.handleExpand.bind(this,t),icon:a,scale:"s",appearance:"transparent",text:""})}renderInfoButton(){return n("button",{id:this.tipID,class:b.infoButton},n("calcite-icon",{class:b.infoIcon,icon:u.Popover,scale:"s"}))}renderCopyButton(t,a){return n("calcite-action",{class:this.calciteMode,onClick:this.copySelection.bind(this,t,a),slot:"action",icon:u.Copy,appearance:"transparent",text:""})}renderInput(t,a,n,s){const e=null!=s?s:this.setting;return"string"===e.type||"textarea"===e.type?t===p.User?this.renderUserLocaleInput(a,n):this.renderTranslatedLanguageInput(a,n):this.renderTextEditor(a,t,n)}renderUserLocaleInput(t,a){return n("calcite-input",{ref:t=>this.userInputs[a]=t,key:a,id:a,class:l.Light,"data-field-name":this.fieldName,value:t,onFocus:this.handleSelection,onCalciteInputChange:this.handleUserInputChange.bind(this)})}renderTranslatedLanguageInput(t,a){return n("calcite-input",{ref:t=>this.translatedInputs[a]=t,key:a,id:a,class:l.Light,"data-field-name":this.fieldName,value:t,onFocus:this.handleSelection,onCalciteInputChange:this.handleTranslatedInputChange.bind(this)})}renderTextEditor(t,a,s){return n("instant-apps-ckeditor-wrapper",{id:s,ref:this.setEditor.bind(this,a),onDataChanged:this.handleTextEditorDataChange.bind(this,a),onIsFocused:this.handleSelection,value:null!=t?t:"","data-field-name":this.fieldName,config:{toolbar:[]}})}getUIDataItem(){if(g.uiData)return g.uiData.get(this.fieldName)}updateT9nStore(t,a){const n=c.get("currentLanguage"),s=d(n,{[t]:a});c.set("portalItemResourceT9n",s)}handleExpand(){const t=this.getUIDataItem();t.expanded=!t.expanded;const a=new Map(g.uiData);a.set(this.fieldName,t),c.set("uiData",a)}handleEditorCollapse(){var t,a;const n=c.get("uiData"),s=null==n?void 0:n.get(this.fieldName);if(!(null==s?void 0:s.expanded)&&(null===(t=this.userEditorWrapper)||void 0===t?void 0:t.editorInstance)&&(null===(a=this.translatedEditorWrapper)||void 0===a?void 0:a.editorInstance)){const{userEditorWrapper:t,translatedEditorWrapper:a}=this,n=t.editorInstance.getData();t.value=n;const s=a.editorInstance.getData();a.value=s,t.editorInstance.destroy(),a.editorInstance.destroy()}}handleSelection(t){const a=new Map(g.uiData),n=h();n.forEach((t=>{(null==a?void 0:a.get(t)).selected=!1})),n.forEach((n=>{const s=null==t?void 0:t.target;n===(null==s?void 0:s.getAttribute("data-field-name"))&&((null==a?void 0:a.get(n)).selected=!0)})),c.set("uiData",a)}getUILocation(){const t=this.getUIDataItem(),{uiLocation:a,userLocaleData:s}=t,{section:e,subsection:i}=a,r=[e.label,i.label,s.label].filter((t=>!!t));return r.map(((t,a)=>n("span",{class:b.uiLocationItem},n("span",null,t),a!==r.length-1?n("calcite-icon",{icon:"chevron-right",scale:"s"}):null)))}getTip(){const t=this.getUIDataItem(),{tip:a}=t;return a}copySelection(t,a){this.setting.type===r.TextEditor?this.copyTextEditorContent(t):this.copyCalciteInputContent(a,t)}copyTextEditorContent(t){var a,n;const s=t===p.User?null===(a=this.userEditorWrapper)||void 0===a?void 0:a.editorInstance:null===(n=this.translatedEditorWrapper)||void 0===n?void 0:n.editorInstance;setTimeout((()=>{this.selectContent(s),setTimeout((()=>this.selectContent(s)),50)}),50),this.copyContent(s)}selectContent(t){t.editing.view.focus();const{model:a}=t,n=a.createRangeIn(a.document.getRoot());a.change((t=>t.setSelection(n)))}copyContent(t){const a=t.getData(),n=document.createElement("div");n.contentEditable="true",n.innerHTML=a,document.body.appendChild(n);const s=document.createRange();s.selectNodeContents(n);const e=window.getSelection();null==e||e.removeAllRanges(),null==e||e.addRange(s),document.execCommand("copy"),document.body.removeChild(n)}copyCalciteInputContent(t,a){const n=a===p.User?this.userInputs[t]:this.translatedInputs[t];n&&(n.selectText(),navigator.clipboard.writeText(n.value))}setEditor(t,a){t===p.User?this.userEditorWrapper=a:this.translatedEditorWrapper=a}async handleUserInputChange(t){c.set("saving",!0);try{const a=t.target,n=a.id,s=a.value;this.getUIDataItem().userLocaleData.value=s,await this.userLocaleInputOnChangeCallback(n,s),c.set("saving",!1)}catch(t){c.set("saving",!1)}}async handleUserTextEditorChange(t){c.set("saving",!0);try{const a=t.detail,n=t.target.id;this.getUIDataItem().userLocaleData.value=a,await this.userLocaleInputOnChangeCallback(n,a),c.set("saving",!1)}catch(t){c.set("saving",!1)}}async handleTranslatedInputChange(t){c.set("saving",!0);try{const a=t.composedPath()[0],n=a.id;this.updateT9nStore(n,a.value);const{locale:s,resource:e}=this.getTranslatedLocaleCallbackData(),i=t.target.value;await this.translatedLocaleInputOnChangeCallback(n,i,s,e),setTimeout((()=>c.set("saving",!1)),1500),this.translatorItemDataUpdated.emit()}catch(t){console.error("Error writing to portal item resource: ",t),c.set("saving",!1)}}async handleTranslatedTextEditorChange(t){c.set("saving",!0);try{const a=t.target.id;this.updateT9nStore(a,t.detail);const{locale:n,resource:s}=this.getTranslatedLocaleCallbackData(),e=t.detail;await this.translatedLocaleInputOnChangeCallback(a,e,n,s),setTimeout((()=>c.set("saving",!1)),1500),this.translatorItemDataUpdated.emit()}catch(t){console.error("Error writing to portal item resource: ",t),c.set("saving",!1)}}handleTextEditorDataChange(t,a){t===p.User?this.handleUserTextEditorChange(a):this.handleTranslatedTextEditorChange(a)}getTranslatedLocaleCallbackData(){return{locale:c.get("currentLanguage"),resource:c.get("portalItemResource")}}getIcon(t){switch((null!=t?t:this.setting).stringType){case"title":return u.Title;case"subtitle":return u.Subtitle;case"text":return u.Text;case"button":return u.Button;case"string":return u.String;default:return u.SettingIndicator}}};f.style=".sc-instant-apps-language-translator-item-h{display:block}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item.sc-instant-apps-language-translator-item{display:flex}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item{padding:10px;border-bottom:1px solid var(--calcite-color-border-1);background-color:var(--calcite-color-foreground-2);width:49%}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item .instant-apps-language-translator-item__top-row.sc-instant-apps-language-translator-item{display:flex;align-items:center;justify-content:space-between}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item .instant-apps-language-translator-item__label-container.sc-instant-apps-language-translator-item{display:flex;align-items:center}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item .instant-apps-language-translator-item__label.sc-instant-apps-language-translator-item{display:inline-block;margin-left:10px;font-size:14px;font-weight:var(--calcite-font-weight-medium)}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item calcite-input.sc-instant-apps-language-translator-item{margin-top:10px;margin-left:55px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--last-item.sc-instant-apps-language-translator-item{border-bottom:none}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item{background-color:#f1faff}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item:first-child{margin-right:1%}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__ui-location-popover-content.sc-instant-apps-language-translator-item{display:inline-block;padding:10px;max-width:400px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__ui-location-items.sc-instant-apps-language-translator-item{display:flex}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__ui-location-item.sc-instant-apps-language-translator-item{display:flex;align-items:center;font-weight:var(--calcite-font-weight-medium);font-size:14px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__tip.sc-instant-apps-language-translator-item{display:inline-block;font-size:14px;line-height:22px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__info-icon.sc-instant-apps-language-translator-item{color:var(--calcite-color-brand)}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__info-button.sc-instant-apps-language-translator-item{border:0;background-color:transparent;cursor:pointer}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__nested-input.sc-instant-apps-language-translator-item{margin-left:60px;margin-top:8px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__nested-input.sc-instant-apps-language-translator-item calcite-input.sc-instant-apps-language-translator-item{margin-left:30px}.calcite-mode-dark.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item{background-color:#f1faff;background-color:var(--calcite-color-brand);color:var(--calcite-color-text-inverse)}.calcite-mode-dark.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item calcite-action.sc-instant-apps-language-translator-item{--calcite-ui-icon-color:var(--calcite-color-text-inverse)}.calcite-mode-dark.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item calcite-icon.sc-instant-apps-language-translator-item{color:var(--calcite-color-text-inverse)}.instant-apps-language-translator--last-item.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item{border-bottom:none}";const x="instant-apps-language-translator-search",k={base:x,input:`${x}__input`,suggestionList:`${x}__suggestion-list`,suggestionListItem:`${x}__suggestion-list-item`},y=class{constructor(n){t(this,n),this.suggestionSelected=a(this,"suggestionSelected",7),this.t9nPlaceholder=void 0,this.results=[]}render(){return n(s,{key:"71fa373371b7b33faa8f3d91959dc50b1e3b0f34"},this.renderSearchInput(),this.renderSuggestions())}renderSearchInput(){return n("calcite-input",{ref:t=>this.searchInput=t,class:k.input,onCalciteInputInput:this.handleSearch.bind(this),type:"search",placeholder:this.t9nPlaceholder,icon:"search"})}renderSuggestions(){return this.results.length>0?this.renderSuggestionList():null}renderSuggestionList(){return n("ul",{class:k.suggestionList},this.results.map((t=>this.renderSuggestionListItem(t))))}renderSuggestionListItem(t){return n("li",{onClick:this.selectSuggestion.bind(this),class:k.suggestionListItem,"data-field-name":t.fieldName},t.userLocaleData.label)}handleSearch(t){var a,n;const s=null===(n=null===(a=t.target.value)||void 0===a?void 0:a.toLowerCase())||void 0===n?void 0:n.trim(),e=c.get("uiData"),i=h(),r=c.get("portalItemResourceT9n"),o=c.get("currentLanguage"),l=r[o],p=this.getSettingDataItems(i).filter(this.matchedResultsCallback(e,l,s,o));this.results=[...p.map((t=>Object.assign({fieldName:t},e.get(t))))]}matchedResultsCallback(t,a,n,s){return e=>{var i;const r=t.get(e),{label:o}=r.userLocaleData,{value:l}=r.userLocaleData,c=t.get("translatedLanguageLabels"),p=null===(i=null==c?void 0:c[s])||void 0===i?void 0:i[e],u=null==a?void 0:a[e],g=this.testUserInput(o,n),d=this.testUserInput(l,n),h=this.testUserInput(p,n),m=this.testUserInput(u,n);return g||d||h||m}}getSettingDataItems(t){return t.filter((t=>"locales"!==t&&"translatedLanguageLabels"!==t))}testUserInput(t,a){var n;return!!(null==t?void 0:t.trim())&&!!(null==a?void 0:a.trim())&&-1!==(null===(n=null==t?void 0:t.toLowerCase())||void 0===n?void 0:n.search(a))}selectSuggestion(t){const a=t.target.getAttribute("data-field-name");this.suggestionSelected.emit(a),this.resetSearchInput()}resetSearchInput(){this.searchInput.value="",this.results=[]}};y.style=".sc-instant-apps-language-translator-search-h{display:block;position:relative}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__input.sc-instant-apps-language-translator-search{width:235.5px}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list.sc-instant-apps-language-translator-search{position:absolute;margin:0;padding:0;width:100%;max-height:30vh;overflow:auto;border-left:none;background-color:var(--calcite-color-foreground-1);border:1px solid #c0c0c0;z-index:702}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list-item.sc-instant-apps-language-translator-search:first-child{border:none}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list-item.sc-instant-apps-language-translator-search{margin-top:0;padding:0.8em 1em;border-top:solid 1px rgba(110, 110, 110, 0.3);display:flex;flex-direction:column;cursor:pointer;word-break:break-word}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list-item.sc-instant-apps-language-translator-search:hover{background-color:var(--calcite-color-foreground-2)}";export{v as instant_apps_ckeditor_wrapper,f as instant_apps_language_translator_item,y as instant_apps_language_translator_search}
|
6
|
+
import{r as t,c as a,h as n,H as s,g as e,F as i}from"./p-6eb37ed2.js";import{d as r,e as o,f as l,s as c,h as p,E as u,l as g,j as d,c as h}from"./p-0a64be62.js";import"./p-3d0e9be4.js";import"./p-4cd4cb85.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-ac122d9e.js";import"./p-720a12c0.js";const m="instant-apps-components__ckeditor-wrapper",v=class{constructor(n){t(this,n),this.isFocused=a(this,"isFocused",7),this.dataChanged=a(this,"dataChanged",7),this.value=void 0,this.editorInstance=void 0,this.config=void 0}updateValue(){this.value&&this.editorInstance.setData(this.value)}async componentDidLoad(){this.init()}componentDidUpdate(){this.editorInstance.setData(this.value)}render(){return n(s,{key:"26f62d5413e21916b77253476cf48f69682861d5"},n("div",{key:"45a9d7b859a21e49c81afdaa3bdd5074f1428cd5"}))}init(){this.applyStyles(),this.initEditor()}applyStyles(){if(document.getElementById(m))return;const t=document.createElement("style");t.id=m,t.innerHTML="\n .ck.ck-reset.ck-editor.ck-rounded-corners {\n margin-top: 10px !important;\n margin-left: 55px !important;\n }\n .ck-editor__editable {\n height: 70px !important;\n font-size: 0.875rem !important;\n line-height: \t1.375 !important;\n color: var(--calcite-color-text-1) !important;\n }\n\n .ck.ck-editor__editable_inline>:first-child,\n .ck.ck-editor__editable_inline>:last-child {\n --ck-spacing-large: 0.5rem !important;\n }\n\n .ck.ck-balloon-panel.ck-powered-by-balloon {\n --ck-z-modal: 700;\n z-index: 700;\n }\n\n .calcite-mode-dark .ck-editor__editable {\n color: var(--calcite-color-text-inverse) !important;\n }\n",document.head.prepend(t)}async initEditor(){const t=await this.createEditor();t&&(this.editorInstance=t,(this.value||""===this.value)&&t.setData(this.value),t.editing.view.document.on("change:isFocused",this.getEditorFocusedCallback(t)))}async createEditor(){try{let t;return t=this.config?await ClassicEditor.create(this.el,this.config):await ClassicEditor.create(this.el),this.editorInstance=t,Promise.resolve(t)}catch(t){return console.error(t),Promise.reject(null)}}getEditorFocusedCallback(t){return(a,n,s)=>{if(s)this.isFocused.emit();else{const a=t.getData();this.value!==a&&(this.value=a,this.dataChanged.emit(a))}}}get el(){return e(this)}static get watchers(){return{value:["updateValue"]}}};v.style=":host{display:block}";const _="instant-apps-language-translator-item",f={section:`${_}__section`,selected:`${_}__section--selected`,collapsed:`${_}__section--collapsed`,topRow:`${_}__top-row`,labelContainer:`${_}__label-container`,label:`${_}__label`,uiLocationPopoverContent:`${_}__ui-location-popover-content`,uiLocationItems:`${_}__ui-location-items`,uiLocationItem:`${_}__ui-location-item`,infoIcon:`${_}__info-icon`,infoButton:`${_}__info-button`,tip:`${_}__tip`,nestedInput:`${_}__nested-input`},b=class{constructor(n){t(this,n),this.translatorItemDataUpdated=a(this,"translatorItemDataUpdated",7),this.userInputs={},this.translatedInputs={},this.fieldName=void 0,this.translatedLanguageLabels=void 0,this.setting=void 0,this.userLocaleInputOnChangeCallback=void 0,this.translatedLocaleInputOnChangeCallback=void 0}get isTextEditor(){return this.setting.type===r.TextEditor}get calciteMode(){return o()?l.Dark:l.Light}get hasNestedContent(){var t;return!!(null===(t=this.setting)||void 0===t?void 0:t.content)}get tipID(){return`${this.fieldName}goTo`}componentDidLoad(){this.isTextEditor&&c.onChange("uiData",(()=>this.handleEditorCollapse()))}render(){var t;return"content"in this.setting&&(null===(t=this.setting.content)||void 0===t?void 0:t.every((t=>{var a;return 0===(null===(a=null==t?void 0:t.content)||void 0===a?void 0:a.length)})))?n(i,null):n(s,{class:this.calciteMode},this.renderBase(),this.renderPopover())}renderBase(){return n("div",{class:_},this.renderUserLocaleSection(),this.renderTranslatedLanguageSection())}renderPopover(){const t=this.getTip();return n("calcite-popover",{referenceElement:this.tipID,label:"","auto-close":"true",placement:"trailing",closable:!0},n("span",{class:f.uiLocationPopoverContent},n("span",{class:f.uiLocationItems},this.getUILocation()),t?n("span",{class:f.tip},t):null))}renderUserLocaleSection(){const t=this.getUIDataItem(),a=null==t?void 0:t.userLocaleData,s=null==a?void 0:a.value,e=this.setting.id;return n("div",{class:`${f.section}${(null==t?void 0:t.selected)?` ${f.selected}`:""}`},this.renderItemHeader(p.User,null==a?void 0:a.label,e),this.handleInputRender(p.User,s,e))}renderTranslatedLanguageSection(){var t,a;const s=this.getUIDataItem(),e=this.setting.id,i=c.get("currentLanguage"),r=c.get("portalItemResourceT9n"),o=null===(t=this.translatedLanguageLabels)||void 0===t?void 0:t[this.fieldName],l=null===(a=null==r?void 0:r[i])||void 0===a?void 0:a[e];return n("div",{class:`${f.section}${(null==s?void 0:s.selected)?` ${f.selected}`:""}`},this.renderItemHeader(p.Translation,o,e),this.handleInputRender(p.Translation,l,e))}handleInputRender(t,a,n){const s=this.getUIDataItem();return(null==s?void 0:s.expanded)?this.hasNestedContent?this.renderNestedInputs(t):this.renderInput(t,a,n):null}renderNestedInputs(t,a){const n=null!=a?a:this.setting,{content:s}=n;return null==s?void 0:s.map((a=>a.hasOwnProperty("content")?this.renderNestedInputs(t,a):this.renderNestedInput(t,a)))}renderNestedInput(t,a){var s;const e=c.get("currentLanguage"),i=c.get("portalItemResourceT9n"),r=null==a?void 0:a.id,o=null==i?void 0:i[e],l=null==o?void 0:o[r],{label:u,value:g,id:d}=a,h=t===p.Translation?null===(s=this.translatedLanguageLabels)||void 0===s?void 0:s[d]:u,m=t===p.User?g:l;return n("div",{class:f.nestedInput},this.renderItemHeader(t,h,r,a),this.renderInput(t,m,r,a))}renderItemHeader(t,a,s,e){const i=!this.hasNestedContent||!!e;return n("div",{class:f.topRow},this.renderItemHeaderLabel(t,a,e),i?this.renderCopyButton(t,s):null)}renderItemHeaderLabel(t,a,s){const e=t===p.User&&!s;return n("div",{class:f.labelContainer},s?null:this.renderExpandCollapseButton(),n("calcite-icon",{icon:this.getIcon(s),scale:"s"}),n("span",{class:f.label},a),e?this.renderInfoButton():null)}renderExpandCollapseButton(){const t=this.getUIDataItem(),a=(null==t?void 0:t.expanded)?u.Expanded:u.Collapsed;return n("calcite-action",{onClick:this.handleExpand.bind(this,t),icon:a,scale:"s",appearance:"transparent",text:""})}renderInfoButton(){return n("button",{id:this.tipID,class:f.infoButton},n("calcite-icon",{class:f.infoIcon,icon:u.Popover,scale:"s"}))}renderCopyButton(t,a){return n("calcite-action",{class:this.calciteMode,onClick:this.copySelection.bind(this,t,a),slot:"action",icon:u.Copy,appearance:"transparent",text:""})}renderInput(t,a,n,s){const e=null!=s?s:this.setting;return"string"===e.type||"textarea"===e.type?t===p.User?this.renderUserLocaleInput(a,n):this.renderTranslatedLanguageInput(a,n):this.renderTextEditor(a,t,n)}renderUserLocaleInput(t,a){return n("calcite-input",{ref:t=>this.userInputs[a]=t,key:a,id:a,class:l.Light,"data-field-name":this.fieldName,value:t,onFocus:this.handleSelection,onCalciteInputChange:this.handleUserInputChange.bind(this)})}renderTranslatedLanguageInput(t,a){return n("calcite-input",{ref:t=>this.translatedInputs[a]=t,key:a,id:a,class:l.Light,"data-field-name":this.fieldName,value:t,onFocus:this.handleSelection,onCalciteInputChange:this.handleTranslatedInputChange.bind(this)})}renderTextEditor(t,a,s){return n("instant-apps-ckeditor-wrapper",{id:s,ref:this.setEditor.bind(this,a),onDataChanged:this.handleTextEditorDataChange.bind(this,a),onIsFocused:this.handleSelection,value:null!=t?t:"","data-field-name":this.fieldName,config:{toolbar:[]}})}getUIDataItem(){if(g.uiData)return g.uiData.get(this.fieldName)}updateT9nStore(t,a){const n=c.get("currentLanguage"),s=d(n,{[t]:a});c.set("portalItemResourceT9n",s)}handleExpand(){const t=this.getUIDataItem();t.expanded=!t.expanded;const a=new Map(g.uiData);a.set(this.fieldName,t),c.set("uiData",a)}handleEditorCollapse(){var t,a;const n=c.get("uiData"),s=null==n?void 0:n.get(this.fieldName);if(!(null==s?void 0:s.expanded)&&(null===(t=this.userEditorWrapper)||void 0===t?void 0:t.editorInstance)&&(null===(a=this.translatedEditorWrapper)||void 0===a?void 0:a.editorInstance)){const{userEditorWrapper:t,translatedEditorWrapper:a}=this,n=t.editorInstance.getData();t.value=n;const s=a.editorInstance.getData();a.value=s,t.editorInstance.destroy(),a.editorInstance.destroy()}}handleSelection(t){const a=new Map(g.uiData),n=h();n.forEach((t=>{(null==a?void 0:a.get(t)).selected=!1})),n.forEach((n=>{const s=null==t?void 0:t.target;n===(null==s?void 0:s.getAttribute("data-field-name"))&&((null==a?void 0:a.get(n)).selected=!0)})),c.set("uiData",a)}getUILocation(){const t=this.getUIDataItem(),{uiLocation:a,userLocaleData:s}=t,{section:e,subsection:i}=a,r=[e.label,i.label,s.label].filter((t=>!!t));return r.map(((t,a)=>n("span",{class:f.uiLocationItem},n("span",null,t),a!==r.length-1?n("calcite-icon",{icon:"chevron-right",scale:"s"}):null)))}getTip(){const t=this.getUIDataItem(),{tip:a}=t;return a}copySelection(t,a){this.setting.type===r.TextEditor?this.copyTextEditorContent(t):this.copyCalciteInputContent(a,t)}copyTextEditorContent(t){var a,n;const s=t===p.User?null===(a=this.userEditorWrapper)||void 0===a?void 0:a.editorInstance:null===(n=this.translatedEditorWrapper)||void 0===n?void 0:n.editorInstance;setTimeout((()=>{this.selectContent(s),setTimeout((()=>this.selectContent(s)),50)}),50),this.copyContent(s)}selectContent(t){t.editing.view.focus();const{model:a}=t,n=a.createRangeIn(a.document.getRoot());a.change((t=>t.setSelection(n)))}copyContent(t){const a=t.getData(),n=document.createElement("div");n.contentEditable="true",n.innerHTML=a,document.body.appendChild(n);const s=document.createRange();s.selectNodeContents(n);const e=window.getSelection();null==e||e.removeAllRanges(),null==e||e.addRange(s),document.execCommand("copy"),document.body.removeChild(n)}copyCalciteInputContent(t,a){const n=a===p.User?this.userInputs[t]:this.translatedInputs[t];n&&(n.selectText(),navigator.clipboard.writeText(n.value))}setEditor(t,a){t===p.User?this.userEditorWrapper=a:this.translatedEditorWrapper=a}async handleUserInputChange(t){c.set("saving",!0);try{const a=t.target,n=a.id,s=a.value;this.getUIDataItem().userLocaleData.value=s,await this.userLocaleInputOnChangeCallback(n,s),c.set("saving",!1)}catch(t){c.set("saving",!1)}}async handleUserTextEditorChange(t){c.set("saving",!0);try{const a=t.detail,n=t.target.id;this.getUIDataItem().userLocaleData.value=a,await this.userLocaleInputOnChangeCallback(n,a),c.set("saving",!1)}catch(t){c.set("saving",!1)}}async handleTranslatedInputChange(t){c.set("saving",!0);try{const a=t.composedPath()[0],n=a.id;this.updateT9nStore(n,a.value);const{locale:s,resource:e}=this.getTranslatedLocaleCallbackData(),i=t.target.value;await this.translatedLocaleInputOnChangeCallback(n,i,s,e),setTimeout((()=>c.set("saving",!1)),1500),this.translatorItemDataUpdated.emit()}catch(t){console.error("Error writing to portal item resource: ",t),c.set("saving",!1)}}async handleTranslatedTextEditorChange(t){c.set("saving",!0);try{const a=t.target.id;this.updateT9nStore(a,t.detail);const{locale:n,resource:s}=this.getTranslatedLocaleCallbackData(),e=t.detail;await this.translatedLocaleInputOnChangeCallback(a,e,n,s),setTimeout((()=>c.set("saving",!1)),1500),this.translatorItemDataUpdated.emit()}catch(t){console.error("Error writing to portal item resource: ",t),c.set("saving",!1)}}handleTextEditorDataChange(t,a){t===p.User?this.handleUserTextEditorChange(a):this.handleTranslatedTextEditorChange(a)}getTranslatedLocaleCallbackData(){return{locale:c.get("currentLanguage"),resource:c.get("portalItemResource")}}getIcon(t){switch((null!=t?t:this.setting).stringType){case"title":return u.Title;case"subtitle":return u.Subtitle;case"text":return u.Text;case"button":return u.Button;case"string":return u.String;default:return u.SettingIndicator}}};b.style=".sc-instant-apps-language-translator-item-h{display:block}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item.sc-instant-apps-language-translator-item{display:flex}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item{padding:10px;border-bottom:1px solid var(--calcite-color-border-1);background-color:var(--calcite-color-foreground-2);width:49%}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item .instant-apps-language-translator-item__top-row.sc-instant-apps-language-translator-item{display:flex;align-items:center;justify-content:space-between}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item .instant-apps-language-translator-item__label-container.sc-instant-apps-language-translator-item{display:flex;align-items:center}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item .instant-apps-language-translator-item__label.sc-instant-apps-language-translator-item{display:inline-block;margin-left:10px;font-size:14px;font-weight:var(--calcite-font-weight-medium)}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item calcite-input.sc-instant-apps-language-translator-item{margin-top:10px;margin-left:55px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--last-item.sc-instant-apps-language-translator-item{border-bottom:none}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item{background-color:#f1faff}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item:first-child{margin-right:1%}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__ui-location-popover-content.sc-instant-apps-language-translator-item{display:inline-block;padding:10px;max-width:400px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__ui-location-items.sc-instant-apps-language-translator-item{display:flex}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__ui-location-item.sc-instant-apps-language-translator-item{display:flex;align-items:center;font-weight:var(--calcite-font-weight-medium);font-size:14px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__tip.sc-instant-apps-language-translator-item{display:inline-block;font-size:14px;line-height:22px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__info-icon.sc-instant-apps-language-translator-item{color:var(--calcite-color-brand)}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__info-button.sc-instant-apps-language-translator-item{border:0;background-color:transparent;cursor:pointer}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__nested-input.sc-instant-apps-language-translator-item{margin-left:60px;margin-top:8px}.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__nested-input.sc-instant-apps-language-translator-item calcite-input.sc-instant-apps-language-translator-item{margin-left:30px}.calcite-mode-dark.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item{background-color:#f1faff;background-color:var(--calcite-color-brand);color:var(--calcite-color-text-inverse)}.calcite-mode-dark.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item calcite-action.sc-instant-apps-language-translator-item{--calcite-ui-icon-color:var(--calcite-color-text-inverse)}.calcite-mode-dark.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section--selected.sc-instant-apps-language-translator-item calcite-icon.sc-instant-apps-language-translator-item{color:var(--calcite-color-text-inverse)}.instant-apps-language-translator--last-item.sc-instant-apps-language-translator-item-h .instant-apps-language-translator-item__section.sc-instant-apps-language-translator-item{border-bottom:none}";const x="instant-apps-language-translator-search",k={base:x,input:`${x}__input`,suggestionList:`${x}__suggestion-list`,suggestionListItem:`${x}__suggestion-list-item`},y=class{constructor(n){t(this,n),this.suggestionSelected=a(this,"suggestionSelected",7),this.t9nPlaceholder=void 0,this.results=[]}render(){return n(s,{key:"80febf289e2bbfcf09636c84b5a5a83e80f377c0"},this.renderSearchInput(),this.renderSuggestions())}renderSearchInput(){return n("calcite-input",{ref:t=>this.searchInput=t,class:k.input,onCalciteInputInput:this.handleSearch.bind(this),type:"search",placeholder:this.t9nPlaceholder,icon:"search"})}renderSuggestions(){return this.results.length>0?this.renderSuggestionList():null}renderSuggestionList(){return n("ul",{class:k.suggestionList},this.results.map((t=>this.renderSuggestionListItem(t))))}renderSuggestionListItem(t){return n("li",{onClick:this.selectSuggestion.bind(this),class:k.suggestionListItem,"data-field-name":t.fieldName},t.userLocaleData.label)}handleSearch(t){var a,n;const s=null===(n=null===(a=t.target.value)||void 0===a?void 0:a.toLowerCase())||void 0===n?void 0:n.trim(),e=c.get("uiData"),i=h(),r=c.get("portalItemResourceT9n"),o=c.get("currentLanguage"),l=r[o],p=this.getSettingDataItems(i).filter(this.matchedResultsCallback(e,l,s,o));this.results=[...p.map((t=>Object.assign({fieldName:t},e.get(t))))]}matchedResultsCallback(t,a,n,s){return e=>{var i;const r=t.get(e),{label:o}=r.userLocaleData,{value:l}=r.userLocaleData,c=t.get("translatedLanguageLabels"),p=null===(i=null==c?void 0:c[s])||void 0===i?void 0:i[e],u=null==a?void 0:a[e],g=this.testUserInput(o,n),d=this.testUserInput(l,n),h=this.testUserInput(p,n),m=this.testUserInput(u,n);return g||d||h||m}}getSettingDataItems(t){return t.filter((t=>"locales"!==t&&"translatedLanguageLabels"!==t))}testUserInput(t,a){var n;return!!(null==t?void 0:t.trim())&&!!(null==a?void 0:a.trim())&&-1!==(null===(n=null==t?void 0:t.toLowerCase())||void 0===n?void 0:n.search(a))}selectSuggestion(t){const a=t.target.getAttribute("data-field-name");this.suggestionSelected.emit(a),this.resetSearchInput()}resetSearchInput(){this.searchInput.value="",this.results=[]}};y.style=".sc-instant-apps-language-translator-search-h{display:block;position:relative}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__input.sc-instant-apps-language-translator-search{width:235.5px}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list.sc-instant-apps-language-translator-search{position:absolute;margin:0;padding:0;width:100%;max-height:30vh;overflow:auto;border-left:none;background-color:var(--calcite-color-foreground-1);border:1px solid #c0c0c0;z-index:702}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list-item.sc-instant-apps-language-translator-search:first-child{border:none}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list-item.sc-instant-apps-language-translator-search{margin-top:0;padding:0.8em 1em;border-top:solid 1px rgba(110, 110, 110, 0.3);display:flex;flex-direction:column;cursor:pointer;word-break:break-word}.sc-instant-apps-language-translator-search-h .instant-apps-language-translator-search__suggestion-list-item.sc-instant-apps-language-translator-search:hover{background-color:var(--calcite-color-foreground-2)}";export{v as instant_apps_ckeditor_wrapper,b as instant_apps_language_translator_item,y as instant_apps_language_translator_search}
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{d as e}from"./p-
|
6
|
+
import{d as e}from"./p-fe0add26.js";import"./p-6eb37ed2.js";import"./p-365169c2.js";import"./p-66cee72b.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-1ce2608d.js";import"./p-4b9b7778.js";import"./p-64a34d92.js";import"./p-2caf1f94.js";import"./p-27d462c0.js";import"./p-3e828614.js";import"./p-8d453a3a.js";import"./p-1c249530.js";import"./p-174aa4da.js";import"./p-0ef9d36b.js";import"./p-12be6545.js";import"./p-d9e930c8.js";import"./p-a5fc6ab7.js";import"./p-ef67c743.js";import"./p-14f027b5.js";var a={name:"id",weekdays:"Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember".split("_"),weekdaysShort:"Min_Sen_Sel_Rab_Kam_Jum_Sab".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Agt_Sep_Okt_Nov_Des".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sb".split("_"),weekStart:1,formats:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},relativeTime:{future:"dalam %s",past:"%s yang lalu",s:"beberapa detik",m:"semenit",mm:"%d menit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},ordinal:function(e){return e+"."}};e.locale(a,null,!0);export{a as default}
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{d as e}from"./p-
|
6
|
+
import{d as e}from"./p-fe0add26.js";import"./p-6eb37ed2.js";import"./p-365169c2.js";import"./p-66cee72b.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-1ce2608d.js";import"./p-4b9b7778.js";import"./p-64a34d92.js";import"./p-2caf1f94.js";import"./p-27d462c0.js";import"./p-3e828614.js";import"./p-8d453a3a.js";import"./p-1c249530.js";import"./p-174aa4da.js";import"./p-0ef9d36b.js";import"./p-12be6545.js";import"./p-d9e930c8.js";import"./p-a5fc6ab7.js";import"./p-ef67c743.js";import"./p-14f027b5.js";var m={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(e){return e+(1===e?"er":"")}};e.locale(m,null,!0);export{m as default}
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{d as e}from"./p-
|
6
|
+
import{d as e}from"./p-fe0add26.js";import"./p-6eb37ed2.js";import"./p-365169c2.js";import"./p-66cee72b.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-1ce2608d.js";import"./p-4b9b7778.js";import"./p-64a34d92.js";import"./p-2caf1f94.js";import"./p-27d462c0.js";import"./p-3e828614.js";import"./p-8d453a3a.js";import"./p-1c249530.js";import"./p-174aa4da.js";import"./p-0ef9d36b.js";import"./p-12be6545.js";import"./p-d9e930c8.js";import"./p-a5fc6ab7.js";import"./p-ef67c743.js";import"./p-14f027b5.js";function r(e){return e>1&&e<5&&1!=~~(e/10)}function t(e,t,s,n){var m=e+" ";switch(s){case"s":return t||n?"pár sekund":"pár sekundami";case"m":return t?"minuta":n?"minutu":"minutou";case"mm":return t||n?m+(r(e)?"minuty":"minut"):m+"minutami";case"h":return t?"hodina":n?"hodinu":"hodinou";case"hh":return t||n?m+(r(e)?"hodiny":"hodin"):m+"hodinami";case"d":return t||n?"den":"dnem";case"dd":return t||n?m+(r(e)?"dny":"dní"):m+"dny";case"M":return t||n?"měsíc":"měsícem";case"MM":return t||n?m+(r(e)?"měsíce":"měsíců"):m+"měsíci";case"y":return t||n?"rok":"rokem";case"yy":return t||n?m+(r(e)?"roky":"let"):m+"lety"}}var s={name:"cs",weekdays:"neděle_pondělí_úterý_středa_čtvrtek_pátek_sobota".split("_"),weekdaysShort:"ne_po_út_st_čt_pá_so".split("_"),weekdaysMin:"ne_po_út_st_čt_pá_so".split("_"),months:"leden_únor_březen_duben_květen_červen_červenec_srpen_září_říjen_listopad_prosinec".split("_"),monthsShort:"led_úno_bře_dub_kvě_čvn_čvc_srp_zář_říj_lis_pro".split("_"),weekStart:1,yearStart:4,ordinal:function(e){return e+"."},formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd D. MMMM YYYY H:mm",l:"D. M. YYYY"},relativeTime:{future:"za %s",past:"před %s",s:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t}};e.locale(s,null,!0);export{s as default}
|
@@ -3,7 +3,7 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as t,h as a,g as s}from"./p-6eb37ed2.js";import{d as o}from"./p-
|
6
|
+
import{r as t,h as a,g as s}from"./p-6eb37ed2.js";import{d as o}from"./p-66cee72b.js";import{c as e,u as d,d as i,I as l}from"./p-1ce2608d.js";import{s as r,a as c,c as n}from"./p-3e828614.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-4b9b7778.js";
|
7
7
|
/*!
|
8
8
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
9
9
|
* See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
@@ -3,12 +3,12 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as e,c as t,h as i,H as o,g as n}from"./p-6eb37ed2.js";import{t as a,h as l,A as s}from"./p-
|
6
|
+
import{r as e,c as t,h as i,H as o,g as n}from"./p-6eb37ed2.js";import{t as a,h as l,A as s}from"./p-66cee72b.js";import{a as r,c,d,H as h}from"./p-365169c2.js";import{c as m,d as p,u as g,I as b}from"./p-1ce2608d.js";import{c as u,d as f}from"./p-2caf1f94.js";import{s as v,a as k,c as w}from"./p-3e828614.js";import{c as y}from"./p-1c249530.js";import{V as x}from"./p-ef67c743.js";import{i as C}from"./p-4b9b7778.js";import"./p-aaa56cbf.js";import"./p-8bfa18b7.js";import"./p-27d462c0.js";
|
7
7
|
/*!
|
8
8
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
9
9
|
* See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
10
10
|
* v2.12.2
|
11
|
-
*/const z="segmentedControlValidationMessage",j=class{constructor(i){e(this,i),this.calciteSegmentedControlChange=t(this,"calciteSegmentedControlChange",6),this.handleClick=e=>{this.disabled||"calcite-segmented-control-item"===e.target.localName&&this.selectItem(e.target,!0)},this.mutationObserver=y("mutation",(()=>this.setUpItems())),this.appearance="solid",this.disabled=!1,this.form=void 0,this.required=!1,this.name=void 0,this.layout="horizontal",this.scale="m",this.value=null,this.selectedItem=void 0,this.status="idle",this.validationMessage=void 0,this.validationIcon=void 0,this.validity={valid:!1,badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1},this.width="auto"}handlePropsChange(){this.handleItemPropChange()}valueHandler(e){this.getItems().forEach((t=>t.checked=t.value===e))}handleSelectedItemChange(e,t){if(this.value=e?.value,e===t)return;const i=this.getItems(),o=i.filter((t=>t===e)).pop();o?this.selectItem(o):i[0]&&(i[0].tabIndex=0)}componentWillLoad(){v(this),this.setUpItems()}componentDidLoad(){r(this,this.value),k(this)}connectedCallback(){m(this),
|
11
|
+
*/const z="segmentedControlValidationMessage",j=class{constructor(i){e(this,i),this.calciteSegmentedControlChange=t(this,"calciteSegmentedControlChange",6),this.handleClick=e=>{this.disabled||"calcite-segmented-control-item"===e.target.localName&&this.selectItem(e.target,!0)},this.mutationObserver=y("mutation",(()=>this.setUpItems())),this.appearance="solid",this.disabled=!1,this.form=void 0,this.required=!1,this.name=void 0,this.layout="horizontal",this.scale="m",this.value=null,this.selectedItem=void 0,this.status="idle",this.validationMessage=void 0,this.validationIcon=void 0,this.validity={valid:!1,badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1},this.width="auto"}handlePropsChange(){this.handleItemPropChange()}valueHandler(e){this.getItems().forEach((t=>t.checked=t.value===e))}handleSelectedItemChange(e,t){if(this.value=e?.value,e===t)return;const i=this.getItems(),o=i.filter((t=>t===e)).pop();o?this.selectItem(o):i[0]&&(i[0].tabIndex=0)}componentWillLoad(){v(this),this.setUpItems()}componentDidLoad(){r(this,this.value),k(this)}connectedCallback(){m(this),u(this),c(this),this.mutationObserver?.observe(this.el,{childList:!0}),this.handleItemPropChange()}disconnectedCallback(){p(this),f(this),d(this),this.mutationObserver?.unobserve(this.el)}componentDidRender(){g(this)}render(){return i(o,{key:"15d2892515a26a3d97657819a2f7e4ec1bfa132b",onClick:this.handleClick,role:"radiogroup"},i("div",{key:"5cf92b36bed0d722d548bbda4804fe3e2a8c0c6a","aria-errormessage":z,"aria-invalid":a("invalid"===this.status),class:"item-wrapper"},i(b,{key:"3cdc812ffe33a9651dd4308b8fe8db582e3055de",disabled:this.disabled},i("slot",{key:"4e81e1944e237c65f4bf06b8270a5c23f8c49bd3"}),i(h,{key:"b0ccbb1b76b295ab87912c43b0cbbb936c7fea6e",component:this}))),this.validationMessage&&"invalid"===this.status?i(x,{icon:this.validationIcon,id:z,message:this.validationMessage,scale:this.scale,status:this.status}):null)}handleSelected(e){e.preventDefault();const t=e.target;t.checked&&this.selectItem(t),e.stopPropagation()}handleKeyDown(e){const{key:t}=e,{el:i,selectedItem:o}=this;if(-1===["ArrowLeft","ArrowUp","ArrowRight","ArrowDown"," "].indexOf(t))return;let n=t;"rtl"===l(i)&&("ArrowRight"===t&&(n="ArrowLeft"),"ArrowLeft"===t&&(n="ArrowRight"));const a=this.getItems();let s=-1;switch(a.forEach(((e,t)=>{e===o&&(s=t)})),n){case"ArrowLeft":case"ArrowUp":return e.preventDefault(),void this.selectItem(s<1?a[a.length-1]:a[s-1],!0);case"ArrowRight":case"ArrowDown":return e.preventDefault(),void this.selectItem(-1===s?a[1]:a[s+1]||a[0],!0);case" ":return e.preventDefault(),void this.selectItem(e.target,!0);default:return}}async setFocus(){await w(this),(this.selectedItem||this.getItems()[0])?.focus()}handleItemPropChange(){this.getItems().forEach((e=>{e.appearance=this.appearance,e.layout=this.layout,e.scale=this.scale}))}onLabelClick(){this.setFocus()}getItems(){return Array.from(this.el.querySelectorAll("calcite-segmented-control-item"))}selectItem(e,t=!1){if(e===this.selectedItem)return;const i=this.getItems();let o=null;i.forEach((i=>{const n=i===e;(n&&!i.checked||!n&&i.checked)&&(i.checked=n),i.tabIndex=n?0:-1,n&&(o=i,t&&this.calciteSegmentedControlChange.emit())})),this.selectedItem=o,C()&&o&&o.focus()}setUpItems(){const e=this.getItems(),t=e.filter((e=>e.checked)).pop();t?this.selectItem(t):e[0]&&(e[0].tabIndex=0)}get el(){return n(this)}static get watchers(){return{appearance:["handlePropsChange"],layout:["handlePropsChange"],scale:["handlePropsChange"],value:["valueHandler"],selectedItem:["handleSelectedItemChange"]}}};j.style=":host([disabled]){cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:flex;flex-direction:column}.item-wrapper{display:flex;background-color:var(--calcite-color-foreground-1);inline-size:-moz-fit-content;inline-size:fit-content;outline:1px solid var(--calcite-color-border-input);outline-offset:-1px}:host([appearance=outline])>.item-wrapper{background-color:transparent}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}:host([layout=vertical])>.item-wrapper{flex-direction:column;align-items:flex-start;align-self:flex-start}:host([width=full])>.item-wrapper{inline-size:100%;min-inline-size:-moz-fit-content;min-inline-size:fit-content}:host([width=full])>.item-wrapper ::slotted(calcite-segmented-control-item){flex:1 1 auto}:host([width=full][layout=vertical])>.item-wrapper ::slotted(calcite-segmented-control-item){justify-content:flex-start}.validation-container{display:flex;flex-direction:column;align-items:flex-start;align-self:stretch}:host([scale=m]) .validation-container,:host([scale=l]) .validation-container{padding-block-start:0.5rem}:host([scale=s]) .validation-container{padding-block-start:0.25rem}::slotted(input[slot=hidden-form-input]){margin:0 !important;opacity:0 !important;outline:none !important;padding:0 !important;position:absolute !important;inset:0 !important;transform:none !important;-webkit-appearance:none !important;z-index:-1 !important}:host([hidden]){display:none}[hidden]{display:none}";
|
12
12
|
/*!
|
13
13
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
14
14
|
* See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as t,c as s,h as i,g as e}from"./p-6eb37ed2.js";import{S as o}from"./p-7530a02f.js";import{g as n}from"./p-3d0e9be4.js";import"./p-4cd4cb85.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-ac122d9e.js";function l(t){var s;return!!(null===(s=null===window||void 0===window?void 0:window.localStorage)||void 0===s?void 0:s.getItem(t))}const a=class{constructor(i){var e;t(this,i),this.splashClose=s(this,"splashClose",7),this._sanitizer=null==(e=o)||"function"!=typeof e?null:new e({whiteList:{h1:["style"],h2:["style"],h3:["style"],h4:["style"],h5:["style"],h6:["style"],img:["style","src","width","height"],pre:["style"],p:["id","class","style"],div:["id","class","style","role"],span:["id","class","style","role"],figure:["class","style"]}},!0),this.localStorageKey=void 0,this.titleText="",this.content="",this.primaryButtonText="",this.open=!0,this.closeButtonDisabled=!1,this.outsideCloseDisabled=!1,this.secondaryButton=!1,this.secondaryButtonText=void 0,this.secondaryButtonIcon=void 0,this.secondaryButtonCallback=void 0,this.messages=void 0}sanitizeContent(){this.content=this._sanitizer.sanitize(this.content)}componentWillLoad(){let t;const{localStorageKey:s}=this;t=s?this.open&&!l(this.localStorageKey):this.open,this.el.open=t,this.content&&this._sanitizer&&this.sanitizeContent()}componentDidLoad(){n(this)}render(){return i("calcite-modal",{key:"
|
6
|
+
import{r as t,c as s,h as i,g as e}from"./p-6eb37ed2.js";import{S as o}from"./p-7530a02f.js";import{g as n}from"./p-3d0e9be4.js";import"./p-4cd4cb85.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-ac122d9e.js";function l(t){var s;return!!(null===(s=null===window||void 0===window?void 0:window.localStorage)||void 0===s?void 0:s.getItem(t))}const a=class{constructor(i){var e;t(this,i),this.splashClose=s(this,"splashClose",7),this._sanitizer=null==(e=o)||"function"!=typeof e?null:new e({whiteList:{h1:["style"],h2:["style"],h3:["style"],h4:["style"],h5:["style"],h6:["style"],img:["style","src","width","height"],pre:["style"],p:["id","class","style"],div:["id","class","style","role"],span:["id","class","style","role"],figure:["class","style"]}},!0),this.localStorageKey=void 0,this.titleText="",this.content="",this.primaryButtonText="",this.open=!0,this.closeButtonDisabled=!1,this.outsideCloseDisabled=!1,this.secondaryButton=!1,this.secondaryButtonText=void 0,this.secondaryButtonIcon=void 0,this.secondaryButtonCallback=void 0,this.messages=void 0}sanitizeContent(){this.content=this._sanitizer.sanitize(this.content)}componentWillLoad(){let t;const{localStorageKey:s}=this;t=s?this.open&&!l(this.localStorageKey):this.open,this.el.open=t,this.content&&this._sanitizer&&this.sanitizeContent()}componentDidLoad(){n(this)}render(){return i("calcite-modal",{key:"d7ae1e9533ce3ac221547530c509e1682e253ab2",onCalciteModalClose:this.close.bind(this),open:this.open,closeButtonDisabled:this.closeButtonDisabled,outsideCloseDisabled:this.outsideCloseDisabled},this.renderHeader(),this.renderContent(),this.localStorageKey?this.renderDontShowThisAgainCheckbox():null,this.renderPrimaryButton(),this.secondaryButton?this.renderSecondaryButton():null)}renderHeader(){const{titleText:t}=this;return i("header",{slot:"header"},t)}renderContent(){const{content:t}=this;return i("div",{slot:"content",innerHTML:t},i("slot",{name:"custom-action"}))}renderDontShowThisAgainCheckbox(){const{localStorageKey:t,messages:s}=this,e=!!l(t)||null;return i("div",{class:"instant-apps-splash__back-content",slot:"back"},i("calcite-label",{layout:"inline"},i("calcite-checkbox",{onCalciteCheckboxChange:this.handleDontShowThisAgain.bind(this),checked:null!=e?e:void 0}),null==s?void 0:s.dontShowThisAgain))}renderPrimaryButton(){const{primaryButtonText:t}=this;return i("calcite-button",{onClick:this.close.bind(this),slot:"primary"},t||"Enter")}renderSecondaryButton(){var t;return i("calcite-button",{onClick:null===(t=this.secondaryButtonCallback)||void 0===t?void 0:t.bind(this),slot:"secondary","icon-start":this.secondaryButtonIcon,appearance:"outline"},this.secondaryButtonText)}close(){this.open=!1,this.splashClose.emit()}handleDontShowThisAgain(t){const{localStorageKey:s}=this;if(!s)return;const i=t.target,{checked:e}=i;e?null===window||void 0===window||window.localStorage.setItem(s,"false"):function(t){var s;null===(s=null===window||void 0===window?void 0:window.localStorage)||void 0===s||s.removeItem(t)}(s)}get el(){return e(this)}static get watchers(){return{content:["sanitizeContent"]}}};a.style=":host{display:block}:host .image.image_resized img{width:100%}:host .instant-apps-splash__back-content{display:flex;align-items:center}:host .instant-apps-splash__back-content calcite-label{--calcite-label-margin-bottom:0}";export{a as instant_apps_splash}
|