bromcom-ui 2.9.0-rc.8 → 2.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bromcom-ui/bromcom-ui.css +1 -1
- package/dist/bromcom-ui/bromcom-ui.esm.js +1 -1
- package/dist/bromcom-ui/global/global.js +6 -0
- package/dist/bromcom-ui/global/helper/toast.ts +2 -0
- package/dist/bromcom-ui/p-08c75801.js +5 -0
- package/dist/bromcom-ui/p-0dacfdbc.entry.js +5 -0
- package/dist/bromcom-ui/{p-24f0e23a.entry.js → p-13f6e1a7.entry.js} +1 -1
- package/dist/bromcom-ui/{p-5c3e9ac9.entry.js → p-14cafd64.entry.js} +1 -1
- package/dist/bromcom-ui/p-170cf07d.js +6 -0
- package/dist/bromcom-ui/p-19634d99.js +5 -0
- package/dist/bromcom-ui/{p-e4477593.entry.js → p-1c801d0c.entry.js} +1 -1
- package/dist/bromcom-ui/{p-48f85544.entry.js → p-1c9314bd.entry.js} +1 -1
- package/dist/bromcom-ui/{p-6bcaf906.entry.js → p-1cfe5a5d.entry.js} +1 -1
- package/dist/bromcom-ui/p-20ba9769.entry.js +5 -0
- package/dist/bromcom-ui/{p-8ded5483.entry.js → p-228c74e9.entry.js} +1 -1
- package/dist/bromcom-ui/{p-65f01d32.entry.js → p-22eb4e12.entry.js} +1 -1
- package/dist/bromcom-ui/{p-f331e009.entry.js → p-26290ed5.entry.js} +1 -1
- package/dist/bromcom-ui/{p-240151d4.entry.js → p-2aaeb247.entry.js} +1 -1
- package/dist/bromcom-ui/{p-73ca7c0a.entry.js → p-2b822458.entry.js} +1 -1
- package/dist/bromcom-ui/{p-dbc4c30c.js → p-2c5a0863.js} +1 -1
- package/dist/bromcom-ui/p-304bfa08.entry.js +5 -0
- package/dist/bromcom-ui/p-3432a82d.js +19 -0
- package/dist/bromcom-ui/p-399bce44.entry.js +5 -0
- package/dist/bromcom-ui/p-41cea609.entry.js +7 -0
- package/dist/bromcom-ui/{p-6c3e9e10.entry.js → p-430c0a24.entry.js} +1 -1
- package/dist/bromcom-ui/p-434c170e.js +5 -0
- package/dist/bromcom-ui/{p-d0bb9a84.entry.js → p-440bbaaa.entry.js} +1 -1
- package/dist/bromcom-ui/p-47400be4.entry.js +5 -0
- package/dist/bromcom-ui/{p-f5bed571.entry.js → p-4a2de9ce.entry.js} +1 -1
- package/dist/bromcom-ui/p-4f42085a.entry.js +5 -0
- package/dist/bromcom-ui/{p-ff48f5b2.entry.js → p-5232e011.entry.js} +1 -1
- package/dist/bromcom-ui/p-53e91ae6.js +5 -0
- package/dist/bromcom-ui/{p-c75519d5.js → p-54211561.js} +1 -1
- package/dist/bromcom-ui/{p-dc2c4b14.entry.js → p-5699f67d.entry.js} +1 -1
- package/dist/bromcom-ui/p-5871767a.entry.js +5 -0
- package/dist/bromcom-ui/{p-45767d1d.entry.js → p-588165ef.entry.js} +1 -1
- package/dist/bromcom-ui/p-5916e844.entry.js +5 -0
- package/dist/bromcom-ui/{p-499bb928.entry.js → p-5fb0f815.entry.js} +1 -1
- package/dist/bromcom-ui/{p-2fc584c4.js → p-61db1f1f.js} +1 -1
- package/dist/bromcom-ui/{p-89e1d8c5.entry.js → p-626b805d.entry.js} +1 -1
- package/dist/bromcom-ui/{p-d389b202.entry.js → p-647de93f.entry.js} +1 -1
- package/dist/bromcom-ui/p-64fad38b.js +11 -0
- package/dist/bromcom-ui/{p-03134b6f.entry.js → p-67343ad8.entry.js} +1 -1
- package/dist/bromcom-ui/{p-bd51d347.entry.js → p-69260d36.entry.js} +1 -1
- package/dist/bromcom-ui/p-6cf1e8a2.entry.js +5 -0
- package/dist/bromcom-ui/{p-4aa0e6b1.js → p-6edf985f.js} +1 -1
- package/dist/bromcom-ui/p-73ec379d.entry.js +5 -0
- package/dist/bromcom-ui/{p-3cde7f38.js → p-74e6d2b6.js} +1 -1
- package/dist/bromcom-ui/p-75ec5cc6.entry.js +5 -0
- package/dist/bromcom-ui/p-784a7bb0.entry.js +5 -0
- package/dist/bromcom-ui/p-78f0fe00.js +5 -0
- package/dist/bromcom-ui/p-7b05abe8.entry.js +5 -0
- package/dist/bromcom-ui/{p-d995750a.entry.js → p-7c5763cc.entry.js} +1 -1
- package/dist/bromcom-ui/p-7cb30513.js +5 -0
- package/dist/bromcom-ui/{p-81eeccfa.entry.js → p-7d18ce0e.entry.js} +1 -1
- package/dist/bromcom-ui/{p-5ae0a59b.js → p-7e44e6b5.js} +1 -1
- package/dist/bromcom-ui/p-80ee3d97.entry.js +5 -0
- package/dist/bromcom-ui/p-822d590f.entry.js +5 -0
- package/dist/bromcom-ui/p-85eedabc.js +5 -0
- package/dist/bromcom-ui/p-89a28750.entry.js +5 -0
- package/dist/bromcom-ui/{p-3c7a0345.js → p-8c018ae0.js} +1 -1
- package/dist/bromcom-ui/p-8f45ba5f.entry.js +5 -0
- package/dist/bromcom-ui/p-9075a184.entry.js +5 -0
- package/dist/bromcom-ui/{p-f58c1fbe.entry.js → p-913c55ee.entry.js} +1 -1
- package/dist/bromcom-ui/p-9164639f.entry.js +5 -0
- package/dist/bromcom-ui/p-9850cbce.js +5 -0
- package/dist/bromcom-ui/{p-8bcfe3b3.entry.js → p-99824717.entry.js} +1 -1
- package/dist/bromcom-ui/p-9bd5f3b4.entry.js +5 -0
- package/dist/bromcom-ui/{p-6aeaef2a.entry.js → p-a006e404.entry.js} +1 -1
- package/dist/bromcom-ui/{p-e9842c26.js → p-a0ba474b.js} +1 -1
- package/dist/bromcom-ui/{p-b60bcecf.js → p-a1b1750c.js} +1 -1
- package/dist/bromcom-ui/{p-8fcb5846.js → p-a2c364af.js} +1 -1
- package/dist/bromcom-ui/p-a40a5474.entry.js +5 -0
- package/dist/bromcom-ui/{p-7c6e3ae5.entry.js → p-a664cc20.entry.js} +1 -1
- package/dist/bromcom-ui/p-a9eb0321.js +315 -0
- package/dist/bromcom-ui/{p-2acd6bee.entry.js → p-ab0b4d1e.entry.js} +1 -1
- package/dist/bromcom-ui/{p-ea4d8a18.entry.js → p-ae57f046.entry.js} +1 -1
- package/dist/bromcom-ui/{p-2caa75a4.entry.js → p-b4f033b4.entry.js} +1 -1
- package/dist/bromcom-ui/p-b81e8f91.js +5 -0
- package/dist/bromcom-ui/{p-503feae9.entry.js → p-b8a8bd1d.entry.js} +1 -1
- package/dist/bromcom-ui/{p-b4ac5904.js → p-b901e1ce.js} +1 -1
- package/dist/bromcom-ui/p-ba74a838.entry.js +5 -0
- package/dist/bromcom-ui/{p-c42dffea.entry.js → p-ba949d4a.entry.js} +1 -1
- package/dist/bromcom-ui/{p-f4538abb.entry.js → p-ba9eff2a.entry.js} +1 -1
- package/dist/bromcom-ui/{p-fb4b5224.entry.js → p-bd2b6de5.entry.js} +1 -1
- package/dist/bromcom-ui/{p-ebee9f45.entry.js → p-c1a992e7.entry.js} +1 -1
- package/dist/bromcom-ui/{p-908b1b5d.js → p-c8751181.js} +1 -1
- package/dist/bromcom-ui/p-ccf0872d.js +5 -0
- package/dist/bromcom-ui/p-cf659967.entry.js +5 -0
- package/dist/bromcom-ui/{p-8d0ca8c2.js → p-d153c7fc.js} +1 -1
- package/dist/bromcom-ui/p-d3db9e02.entry.js +5 -0
- package/dist/bromcom-ui/{p-7ddaedb7.entry.js → p-d551a51d.entry.js} +1 -1
- package/dist/bromcom-ui/{p-ec36d0c0.entry.js → p-d68c2c0a.entry.js} +1 -1
- package/dist/bromcom-ui/{p-e5a0d8f6.entry.js → p-d724cfa9.entry.js} +1 -1
- package/dist/bromcom-ui/{p-af0a447d.entry.js → p-d7ca94e1.entry.js} +1 -1
- package/dist/bromcom-ui/p-dd49ae28.entry.js +5 -0
- package/dist/bromcom-ui/p-e2294927.entry.js +5 -0
- package/dist/bromcom-ui/{p-1b1f4b44.entry.js → p-e688b044.entry.js} +1 -1
- package/dist/bromcom-ui/p-ec0224fb.entry.js +5 -0
- package/dist/bromcom-ui/{p-6ca980dd.entry.js → p-ece578ef.entry.js} +1 -1
- package/dist/bromcom-ui/{p-1be22601.entry.js → p-ef8c5b55.entry.js} +1 -1
- package/dist/bromcom-ui/p-f711588b.js +5 -0
- package/dist/bromcom-ui/p-fe1f2413.entry.js +5 -0
- package/dist/bromcom-ui/{p-a82f2b2a.entry.js → p-fe83cdd3.entry.js} +1 -1
- package/dist/bromcom-ui/{p-f619f9f9.entry.js → p-fff1a0f9.entry.js} +1 -1
- package/dist/bromcom-ui/static/message-bot.svg +2 -2
- package/dist/cjs/{_commonjsHelpers-bd20f4c0.js → _commonjsHelpers-ed84c3ca.js} +16 -0
- package/dist/cjs/{bcm-ab921827.js → bcm-7f703055.js} +33 -31
- package/dist/cjs/bcm-accordion.cjs.entry.js +5 -5
- package/dist/cjs/bcm-alert.cjs.entry.js +9 -9
- package/dist/cjs/bcm-attendance.cjs.entry.js +5 -5
- package/dist/cjs/bcm-autocomplete.cjs.entry.js +3 -3
- package/dist/cjs/bcm-avatar_2.cjs.entry.js +209 -0
- package/dist/cjs/bcm-box.cjs.entry.js +1 -1
- package/dist/cjs/bcm-breadcrumb.cjs.entry.js +6 -6
- package/dist/cjs/bcm-button-group.cjs.entry.js +11 -11
- package/dist/cjs/bcm-button_15.cjs.entry.js +35172 -0
- package/dist/cjs/bcm-card.cjs.entry.js +10 -10
- package/dist/cjs/bcm-checkbox-group.cjs.entry.js +29 -29
- package/dist/cjs/bcm-checkbox-lite_9.cjs.entry.js +10 -10
- package/dist/cjs/{bcm-checkbox.cjs.entry.js → bcm-checkbox_2.cjs.entry.js} +28 -17
- package/dist/cjs/bcm-chip-group.cjs.entry.js +15 -16
- package/dist/cjs/bcm-chip.cjs.entry.js +7 -7
- package/dist/cjs/bcm-collapse-group.cjs.entry.js +1 -1
- package/dist/cjs/bcm-collapse.cjs.entry.js +6 -6
- package/dist/cjs/bcm-color-input.cjs.entry.js +10 -11
- package/dist/cjs/bcm-colorpicker.cjs.entry.js +3 -3
- package/dist/cjs/bcm-content.cjs.entry.js +1 -1
- package/dist/cjs/bcm-default.cjs.entry.js +5 -5
- package/dist/cjs/bcm-drawer.cjs.entry.js +13 -14
- package/dist/cjs/bcm-dropdown.cjs.entry.js +119 -0
- package/dist/cjs/bcm-error-layout.cjs.entry.js +3 -3
- package/dist/cjs/bcm-expansion-panel.cjs.entry.js +9 -9
- package/dist/cjs/bcm-form-group.cjs.entry.js +1 -1
- package/dist/cjs/bcm-input-custom.cjs.entry.js +6 -6
- package/dist/cjs/bcm-input-dropdown.cjs.entry.js +309 -0
- package/dist/cjs/bcm-item.cjs.entry.js +72 -0
- package/dist/cjs/bcm-items.cjs.entry.js +49 -0
- package/dist/cjs/bcm-link.cjs.entry.js +6 -6
- package/dist/cjs/bcm-list_3.cjs.entry.js +169 -1691
- package/dist/cjs/bcm-menu.cjs.entry.js +150 -0
- package/dist/cjs/bcm-message.cjs.entry.js +3 -3
- package/dist/cjs/bcm-modal-2-footer.cjs.entry.js +11 -12
- package/dist/cjs/bcm-modal-2-header.cjs.entry.js +10 -11
- package/dist/cjs/bcm-modal-2.cjs.entry.js +12 -13
- package/dist/cjs/bcm-modal.cjs.entry.js +11 -11
- package/dist/cjs/bcm-notification.cjs.entry.js +3 -3
- package/dist/cjs/bcm-old-tag_2.cjs.entry.js +3 -3
- package/dist/cjs/bcm-overlay_2.cjs.entry.js +4 -4
- package/dist/cjs/bcm-popconfirm-box.cjs.entry.js +10 -10
- package/dist/cjs/bcm-popconfirm.cjs.entry.js +9 -9
- package/dist/cjs/bcm-popover.cjs.entry.js +229 -0
- package/dist/cjs/bcm-progress.cjs.entry.js +9 -9
- package/dist/cjs/bcm-radio-group.cjs.entry.js +17 -18
- package/dist/cjs/bcm-radio.cjs.entry.js +18 -19
- package/dist/cjs/bcm-range.cjs.entry.js +10 -10
- package/dist/cjs/bcm-result.cjs.entry.js +3 -3
- package/dist/cjs/bcm-select-group.cjs.entry.js +3 -3
- package/dist/cjs/bcm-select-option.cjs.entry.js +3 -3
- package/dist/cjs/bcm-select.cjs.entry.js +5 -5
- package/dist/cjs/bcm-skeleton.cjs.entry.js +5 -5
- package/dist/cjs/bcm-step.cjs.entry.js +8 -8
- package/dist/cjs/bcm-stepper.cjs.entry.js +15 -16
- package/dist/cjs/bcm-switch.cjs.entry.js +15 -15
- package/dist/cjs/bcm-tab-group.cjs.entry.js +209 -0
- package/dist/cjs/bcm-tab-item-header.cjs.entry.js +58 -0
- package/dist/cjs/bcm-tab-item.cjs.entry.js +90 -0
- package/dist/cjs/bcm-tab-pane.cjs.entry.js +3 -3
- package/dist/cjs/bcm-tab.cjs.entry.js +3 -3
- package/dist/cjs/bcm-table.cjs.entry.js +7648 -38
- package/dist/cjs/bcm-tabs-content.cjs.entry.js +3 -3
- package/dist/cjs/bcm-tabs.cjs.entry.js +3 -3
- package/dist/cjs/bcm-tag.cjs.entry.js +19 -19
- package/dist/cjs/bcm-text.cjs.entry.js +49 -0
- package/dist/cjs/bcm-textarea.cjs.entry.js +13 -13
- package/dist/cjs/bcm-timeline-item.cjs.entry.js +3 -3
- package/dist/cjs/bcm-timeline.cjs.entry.js +3 -3
- package/dist/cjs/bcm-toast.cjs.entry.js +38 -19
- package/dist/cjs/bcm-treeview-group.cjs.entry.js +1 -1
- package/dist/cjs/bromcom-ui.cjs.js +5 -4
- package/dist/cjs/{caption-template-8d099fd6.js → caption-template-81dbc490.js} +2 -2
- package/dist/cjs/{color-helper-7ab15732.js → color-helper-c3a819ea.js} +1 -1
- package/dist/cjs/{colors-e1d142ad.js → colors-078851ec.js} +1 -1
- package/dist/cjs/{floating-ui-c9fc2202.js → floating-ui-b441ea7c.js} +2 -2
- package/dist/cjs/{generate-cae9c0fb.js → generate-1dfe001a.js} +2 -2
- package/dist/cjs/{global-3ce50f9f.js → global-4a6abd46.js} +6 -1
- package/dist/cjs/index-5279dea2.js +2571 -0
- package/dist/cjs/{index-906fb4e5.js → index-7eed931f.js} +1631 -25
- package/dist/cjs/{index-fdbf5226.js → index-95ae50d0.js} +1 -1
- package/dist/cjs/{index-ddfd6d8f.js → index-c591ecec.js} +4 -0
- package/dist/cjs/{index-4506fcd7.js → index-d321de96.js} +1 -1
- package/dist/cjs/{input-template-a7f8f2e9.js → input-template-41868c68.js} +8 -8
- package/dist/cjs/{is-load-decorator-137dded1.js → is-load-decorator-15036f37.js} +3 -2
- package/dist/cjs/{json-parse-decarator-34a3d26e.js → json-parse-decarator-f29c368a.js} +2 -2
- package/dist/cjs/{label-template-4d5f99a5.js → label-template-80235581.js} +5 -5
- package/dist/cjs/loader.cjs.js +5 -4
- package/dist/cjs/{number-helper-101d8aa8.js → number-helper-2b9c1f9d.js} +1 -1
- package/dist/cjs/old-bcm-popover-box.cjs.entry.js +11 -11
- package/dist/cjs/old-bcm-popover.cjs.entry.js +9 -9
- package/dist/cjs/{package-ed8b3296.js → package-66b81414.js} +1 -1
- package/dist/cjs/{popover-placement-ccb40073.js → popover-placement-f20020a6.js} +1 -1
- package/dist/cjs/{slot-template-d70ea082.js → slot-template-873b0cd5.js} +2 -2
- package/dist/cjs/{stepper-states-308c8d3e.js → stepper-states-6ccb8ab3.js} +3 -3
- package/dist/cjs/{string-helper-d681e5c7.js → string-helper-fda7cbba.js} +5 -5
- package/dist/cjs/tooltip-helper-0eb3ef13.js +157 -0
- package/dist/cjs/{validators-26badb68.js → validators-97a46a9e.js} +6 -1
- package/dist/cjs/watermark-2c23c8f1.js +47499 -0
- package/dist/collection/assets/csv.svg +9 -0
- package/dist/collection/assets/excel.svg +9 -0
- package/dist/collection/assets/pdf.svg +9 -0
- package/dist/collection/collection-manifest.json +5 -2
- package/dist/collection/components/atoms/avatar/avatar.js +21 -23
- package/dist/collection/components/atoms/avatar/avatar.style.js +24 -21
- package/dist/collection/components/atoms/badge/badge.js +2 -1
- package/dist/collection/components/atoms/badge/badge.style.js +36 -24
- package/dist/collection/components/atoms/button/button.css +55 -0
- package/dist/collection/components/atoms/button/button.js +1 -1
- package/dist/collection/components/atoms/icon/static/message-bot.svg +2 -2
- package/dist/collection/components/molecules/dropdown/dropdown.js +1 -1
- package/dist/collection/components/molecules/input/input.js +0 -2
- package/dist/collection/components/molecules/input-dropdown/input-dropdown.css +291 -0
- package/dist/collection/components/molecules/input-dropdown/input-dropdown.js +751 -0
- package/dist/collection/components/molecules/input-dropdown/input-dropdown.style.js +73 -0
- package/dist/collection/components/molecules/linked/linked.js +5 -29
- package/dist/collection/components/molecules/popconfirm/popconfirm.js +1 -1
- package/dist/collection/components/molecules/popover/popover.js +1 -1
- package/dist/collection/components/molecules/tooltip/tooltip.js +1 -1
- package/dist/collection/components/organism/date-picker/date-picker.css +1 -1
- package/dist/collection/components/organism/date-picker/date-picker.js +20 -1
- package/dist/collection/components/organism/datetime-picker/datetime-picker.css +13 -1
- package/dist/collection/components/organism/datetime-picker/datetime-picker.js +21 -1
- package/dist/collection/components/organism/form/form.js +1 -0
- package/dist/collection/components/organism/form-2/bcm-form-components.js +4 -1
- package/dist/collection/components/organism/list/list.css +1 -1
- package/dist/collection/components/organism/list/list.js +63 -22
- package/dist/collection/components/organism/time-picker/time-picker.css +1 -1
- package/dist/collection/components/organism/time-picker/time-picker.js +20 -1
- package/dist/collection/components/other/toast/toast.js +48 -11
- package/dist/collection/components/other_deprecated/old-popover/old-popover.js +1 -1
- package/dist/collection/components/third-parts/rc-picker/date.js +862 -0
- package/dist/collection/components/third-parts/rc-picker/rc-picker.css +1009 -0
- package/dist/collection/components/third-parts/rc-picker/rc-picker.js +550 -0
- package/dist/collection/components/third-parts/table/table-definations.js +42 -0
- package/dist/collection/components/third-parts/table/table.css +136 -0
- package/dist/collection/components/third-parts/table/table.js +288 -0
- package/dist/collection/decorators/bcm-decorator.js +28 -0
- package/dist/collection/decorators/event-decorator.js +31 -0
- package/dist/collection/decorators/index.js +1 -0
- package/dist/collection/decorators/is-load-decorator.js +2 -1
- package/dist/collection/global/global.js +6 -0
- package/dist/collection/global/helper/toast.js +1 -0
- package/dist/collection/global/helper/toast.ts +2 -0
- package/dist/collection/helper/string-helper.js +2 -2
- package/dist/collection/models/bcm.js +29 -27
- package/dist/collection/templates/index.js +2 -0
- package/dist/collection/templates/toolbar-hamburger-template.js +14 -0
- package/dist/collection/templates/toolbar-template.js +15 -0
- package/dist/components/_commonjsHelpers.js +16 -1
- package/dist/components/avatar.js +46 -44
- package/dist/components/badge.js +39 -70
- package/dist/components/bcm-chip-group.js +14 -8
- package/dist/components/bcm-date-picker.js +4 -2
- package/dist/components/bcm-date.d.ts +11 -0
- package/dist/components/bcm-date.js +232 -0
- package/dist/components/bcm-form-2.js +4 -1
- package/dist/components/bcm-form.js +1 -0
- package/dist/components/bcm-input-dropdown.d.ts +11 -0
- package/dist/components/bcm-input-dropdown.js +395 -0
- package/dist/components/bcm-rc-picker.d.ts +11 -0
- package/dist/components/bcm-rc-picker.js +10 -0
- package/dist/components/bcm-table.js +55128 -41
- package/dist/components/bcm-textarea.js +1 -214
- package/dist/components/bcm-time-picker.js +4 -2
- package/dist/components/bcm-toast.js +30 -10
- package/dist/components/bcm.js +29 -27
- package/dist/components/button.js +1 -1
- package/dist/components/chip.js +12 -6
- package/dist/components/colors2.js +1 -1
- package/dist/components/datetime-picker.js +5 -2
- package/dist/components/generate.js +1 -1
- package/dist/components/index.d.ts +4 -1
- package/dist/components/index.js +9 -1
- package/dist/components/index3.js +5 -1
- package/dist/components/index5.js +2569 -0
- package/dist/components/input.js +0 -2
- package/dist/components/is-load-decorator.js +2 -1
- package/dist/components/linked.js +5 -11
- package/dist/components/list.js +22 -8
- package/dist/components/raf.js +1594 -0
- package/dist/components/rc-overflow.js +32 -1557
- package/dist/components/rc-picker.js +14030 -0
- package/dist/components/string-helper.js +2 -2
- package/dist/components/textarea.js +220 -0
- package/dist/esm/{_commonjsHelpers-3016b722.js → _commonjsHelpers-7002e5de.js} +16 -1
- package/dist/esm/bcm-accordion.entry.js +5 -5
- package/dist/esm/bcm-alert.entry.js +9 -9
- package/dist/esm/bcm-attendance.entry.js +5 -5
- package/dist/esm/bcm-autocomplete.entry.js +3 -3
- package/dist/esm/bcm-avatar_2.entry.js +204 -0
- package/dist/esm/bcm-box.entry.js +1 -1
- package/dist/esm/bcm-breadcrumb.entry.js +6 -6
- package/dist/esm/bcm-button-group.entry.js +8 -8
- package/dist/esm/bcm-button_15.entry.js +35154 -0
- package/dist/esm/bcm-card.entry.js +11 -11
- package/dist/esm/bcm-checkbox-group.entry.js +19 -19
- package/dist/esm/bcm-checkbox-lite_9.entry.js +8 -8
- package/dist/esm/{bcm-checkbox.entry.js → bcm-checkbox_2.entry.js} +24 -14
- package/dist/esm/bcm-chip-group.entry.js +16 -17
- package/dist/esm/bcm-chip.entry.js +8 -8
- package/dist/esm/bcm-collapse-group.entry.js +2 -2
- package/dist/esm/bcm-collapse.entry.js +6 -6
- package/dist/esm/bcm-color-input.entry.js +12 -13
- package/dist/esm/bcm-colorpicker.entry.js +5 -5
- package/dist/esm/bcm-content.entry.js +1 -1
- package/dist/esm/{bcm-9f50af9c.js → bcm-d45dc47d.js} +30 -28
- package/dist/esm/bcm-default.entry.js +5 -5
- package/dist/esm/bcm-drawer.entry.js +13 -14
- package/dist/esm/bcm-dropdown.entry.js +115 -0
- package/dist/esm/bcm-error-layout.entry.js +3 -3
- package/dist/esm/bcm-expansion-panel.entry.js +10 -10
- package/dist/esm/bcm-form-group.entry.js +1 -1
- package/dist/esm/bcm-input-custom.entry.js +6 -6
- package/dist/esm/bcm-input-dropdown.entry.js +305 -0
- package/dist/esm/bcm-item.entry.js +68 -0
- package/dist/esm/bcm-items.entry.js +45 -0
- package/dist/esm/bcm-link.entry.js +4 -4
- package/dist/esm/bcm-list_3.entry.js +93 -1615
- package/dist/esm/bcm-menu.entry.js +146 -0
- package/dist/esm/bcm-message.entry.js +3 -3
- package/dist/esm/bcm-modal-2-footer.entry.js +13 -14
- package/dist/esm/bcm-modal-2-header.entry.js +12 -13
- package/dist/esm/bcm-modal-2.entry.js +13 -14
- package/dist/esm/bcm-modal.entry.js +9 -9
- package/dist/esm/bcm-notification.entry.js +3 -3
- package/dist/esm/bcm-old-tag_2.entry.js +4 -4
- package/dist/esm/bcm-overlay_2.entry.js +4 -4
- package/dist/esm/bcm-popconfirm-box.entry.js +11 -11
- package/dist/esm/bcm-popconfirm.entry.js +7 -7
- package/dist/esm/bcm-popover.entry.js +225 -0
- package/dist/esm/bcm-progress.entry.js +9 -9
- package/dist/esm/bcm-radio-group.entry.js +15 -16
- package/dist/esm/bcm-radio.entry.js +13 -14
- package/dist/esm/bcm-range.entry.js +8 -8
- package/dist/esm/bcm-result.entry.js +3 -3
- package/dist/esm/bcm-select-group.entry.js +3 -3
- package/dist/esm/bcm-select-option.entry.js +3 -3
- package/dist/esm/bcm-select.entry.js +6 -6
- package/dist/esm/bcm-skeleton.entry.js +5 -5
- package/dist/esm/bcm-step.entry.js +8 -8
- package/dist/esm/bcm-stepper.entry.js +15 -16
- package/dist/esm/bcm-switch.entry.js +10 -10
- package/dist/esm/bcm-tab-group.entry.js +205 -0
- package/dist/esm/bcm-tab-item-header.entry.js +54 -0
- package/dist/esm/bcm-tab-item.entry.js +86 -0
- package/dist/esm/bcm-tab-pane.entry.js +3 -3
- package/dist/esm/bcm-tab.entry.js +3 -3
- package/dist/esm/bcm-table.entry.js +7649 -39
- package/dist/esm/bcm-tabs-content.entry.js +4 -4
- package/dist/esm/bcm-tabs.entry.js +4 -4
- package/dist/esm/bcm-tag.entry.js +9 -9
- package/dist/esm/bcm-text.entry.js +45 -0
- package/dist/esm/bcm-textarea.entry.js +11 -11
- package/dist/esm/bcm-timeline-item.entry.js +3 -3
- package/dist/esm/bcm-timeline.entry.js +3 -3
- package/dist/esm/bcm-toast.entry.js +38 -19
- package/dist/esm/bcm-treeview-group.entry.js +1 -1
- package/dist/esm/bromcom-ui.js +6 -5
- package/dist/esm/{caption-template-34a1cb44.js → caption-template-d47f338f.js} +2 -2
- package/dist/esm/{color-helper-116755ed.js → color-helper-845ba523.js} +2 -2
- package/dist/esm/{colors-44c95e7e.js → colors-ebea297f.js} +1 -1
- package/dist/esm/{element-dragger-7ea06c76.js → element-dragger-89bb52fd.js} +1 -1
- package/dist/esm/{floating-ui-e7341329.js → floating-ui-8a0c54d6.js} +1 -1
- package/dist/esm/{generate-e008f24f.js → generate-7a1258c4.js} +2 -2
- package/dist/esm/{global-9c04f017.js → global-032592ad.js} +6 -1
- package/dist/esm/{index-ed9652af.js → index-00c8a8f7.js} +1 -1
- package/dist/esm/{index-348b16ad.js → index-0615c2b8.js} +3 -1
- package/dist/esm/index-3bc8c6e3.js +2569 -0
- package/dist/esm/{index-0052017c.js → index-7e71bbc8.js} +1 -1
- package/dist/esm/{index-6310a048.js → index-e4b6a4ce.js} +1616 -26
- package/dist/esm/{input-template-0bdd4dda.js → input-template-68c29fde.js} +4 -4
- package/dist/esm/{is-load-decorator-07d3502a.js → is-load-decorator-8277e3b8.js} +3 -2
- package/dist/esm/{json-parse-decarator-40fc5701.js → json-parse-decarator-2945634b.js} +2 -2
- package/dist/esm/{label-template-98dafeb3.js → label-template-946d4062.js} +4 -4
- package/dist/esm/loader.js +6 -5
- package/dist/esm/{number-helper-ddce4326.js → number-helper-fe7d1aca.js} +1 -1
- package/dist/esm/old-bcm-popover-box.entry.js +13 -13
- package/dist/esm/old-bcm-popover.entry.js +7 -7
- package/dist/esm/{package-00ece356.js → package-acbf2052.js} +1 -1
- package/dist/esm/{popover-placement-78f86f15.js → popover-placement-be68c848.js} +1 -1
- package/dist/esm/{slot-template-672e941d.js → slot-template-fcc7846e.js} +2 -2
- package/dist/esm/{stepper-states-56644bc7.js → stepper-states-9ab8511e.js} +3 -3
- package/dist/esm/{string-helper-6bd24967.js → string-helper-b0e05041.js} +4 -4
- package/dist/esm/tooltip-helper-e5246812.js +155 -0
- package/dist/esm/{utils-b3338faf.js → utils-57652744.js} +1 -1
- package/dist/esm/{validators-77fbe47e.js → validators-22975416.js} +6 -2
- package/dist/esm/watermark-f2c6a1f9.js +47477 -0
- package/dist/types/components/atoms/avatar/avatar.d.ts +0 -2
- package/dist/types/components/atoms/avatar/avatar.style.d.ts +181 -5
- package/dist/types/components/atoms/badge/badge.style.d.ts +174 -4
- package/dist/types/components/molecules/input-dropdown/input-dropdown.d.ts +51 -0
- package/dist/types/components/molecules/input-dropdown/input-dropdown.style.d.ts +307 -0
- package/dist/types/components/molecules/linked/linked.d.ts +1 -3
- package/dist/types/components/organism/date-picker/date-picker.d.ts +1 -0
- package/dist/types/components/organism/datetime-picker/datetime-picker.d.ts +1 -0
- package/dist/types/components/organism/list/list.d.ts +4 -0
- package/dist/types/components/organism/time-picker/time-picker.d.ts +1 -0
- package/dist/types/components/other/toast/toast.d.ts +2 -0
- package/dist/types/components/third-parts/rc-picker/date.d.ts +175 -0
- package/dist/types/components/third-parts/rc-picker/rc-picker.d.ts +47 -0
- package/dist/types/components/third-parts/table/table-definations.d.ts +28 -0
- package/dist/types/components/third-parts/table/table.d.ts +37 -0
- package/dist/types/components.d.ts +244 -3
- package/dist/types/decorators/bcm-decorator.d.ts +2 -0
- package/dist/types/decorators/event-decorator.d.ts +2 -0
- package/dist/types/decorators/index.d.ts +1 -0
- package/dist/types/global/helper/toast.d.ts +2 -0
- package/dist/types/models/bcm.d.ts +256 -236
- package/dist/types/templates/index.d.ts +2 -0
- package/dist/types/templates/toolbar-hamburger-template.d.ts +12 -0
- package/dist/types/templates/toolbar-template.d.ts +13 -0
- package/helper/toast.d.ts +2 -0
- package/helper/toast.d.ts.map +1 -1
- package/helper/toast.js +1 -0
- package/package.json +9 -3
- package/dist/bromcom-ui/p-019b44bb.entry.js +0 -5
- package/dist/bromcom-ui/p-01a50abe.entry.js +0 -5
- package/dist/bromcom-ui/p-065e0f32.entry.js +0 -5
- package/dist/bromcom-ui/p-0cb5a92d.entry.js +0 -5
- package/dist/bromcom-ui/p-0f52bab9.entry.js +0 -5
- package/dist/bromcom-ui/p-15758356.entry.js +0 -5
- package/dist/bromcom-ui/p-1eabd5dc.js +0 -10
- package/dist/bromcom-ui/p-235023cc.entry.js +0 -5
- package/dist/bromcom-ui/p-2a7bdc8b.entry.js +0 -5
- package/dist/bromcom-ui/p-32028f4f.entry.js +0 -5
- package/dist/bromcom-ui/p-3a68eca1.js +0 -5
- package/dist/bromcom-ui/p-4484ed7d.entry.js +0 -5
- package/dist/bromcom-ui/p-4f8b00bc.entry.js +0 -5
- package/dist/bromcom-ui/p-4fd78dbb.entry.js +0 -5
- package/dist/bromcom-ui/p-54c0916c.js +0 -5
- package/dist/bromcom-ui/p-5d89f348.entry.js +0 -5
- package/dist/bromcom-ui/p-61c4745d.entry.js +0 -5
- package/dist/bromcom-ui/p-626a65e9.js +0 -5
- package/dist/bromcom-ui/p-663766cf.entry.js +0 -5
- package/dist/bromcom-ui/p-6d7fe687.js +0 -6
- package/dist/bromcom-ui/p-6f56f8ca.js +0 -5
- package/dist/bromcom-ui/p-74b2d896.js +0 -5
- package/dist/bromcom-ui/p-7f529bbe.entry.js +0 -5
- package/dist/bromcom-ui/p-9fe802bc.entry.js +0 -5
- package/dist/bromcom-ui/p-a19320bb.entry.js +0 -13
- package/dist/bromcom-ui/p-a429e85b.js +0 -5
- package/dist/bromcom-ui/p-a56e8c98.js +0 -5
- package/dist/bromcom-ui/p-a8033cda.entry.js +0 -5
- package/dist/bromcom-ui/p-a9692ed3.entry.js +0 -5
- package/dist/bromcom-ui/p-b1c83bb8.entry.js +0 -5
- package/dist/bromcom-ui/p-bddbd954.entry.js +0 -5
- package/dist/bromcom-ui/p-c49d038e.js +0 -5
- package/dist/bromcom-ui/p-c799b397.entry.js +0 -5
- package/dist/bromcom-ui/p-cf0ab7f0.entry.js +0 -5
- package/dist/bromcom-ui/p-d65a1e21.js +0 -11
- package/dist/bromcom-ui/p-d7f10f7f.js +0 -5
- package/dist/bromcom-ui/p-dd422dd1.js +0 -5
- package/dist/bromcom-ui/p-e09fa0dc.entry.js +0 -5
- package/dist/bromcom-ui/p-e32d9cfc.js +0 -5
- package/dist/bromcom-ui/p-ec6b45ba.entry.js +0 -5
- package/dist/bromcom-ui/p-f645d9ae.entry.js +0 -5
- package/dist/bromcom-ui/p-fdc3e5b8.entry.js +0 -5
- package/dist/cjs/bcm-avatar.cjs.entry.js +0 -127
- package/dist/cjs/bcm-badge_15.cjs.entry.js +0 -1739
- package/dist/cjs/bcm-colorful.cjs.entry.js +0 -17227
- package/dist/cjs/bcm-date-picker.cjs.entry.js +0 -181
- package/dist/cjs/bcm-datetime-picker.cjs.entry.js +0 -1449
- package/dist/cjs/bcm-form-2.cjs.entry.js +0 -209
- package/dist/cjs/bcm-form.cjs.entry.js +0 -488
- package/dist/cjs/bcm-input.cjs.entry.js +0 -371
- package/dist/cjs/bcm-label.cjs.entry.js +0 -45
- package/dist/cjs/bcm-old-input.cjs.entry.js +0 -397
- package/dist/cjs/bcm-time-picker.cjs.entry.js +0 -149
- package/dist/cjs/datetime-helper-eaf4fadb.js +0 -11
- package/dist/cjs/index-b08b037a.js +0 -52
- package/dist/collection/components/other/data-table/table.css +0 -130
- package/dist/collection/components/other/data-table/table.js +0 -88
- package/dist/esm/bcm-avatar.entry.js +0 -123
- package/dist/esm/bcm-badge_15.entry.js +0 -1721
- package/dist/esm/bcm-colorful.entry.js +0 -17223
- package/dist/esm/bcm-date-picker.entry.js +0 -177
- package/dist/esm/bcm-datetime-picker.entry.js +0 -1445
- package/dist/esm/bcm-form-2.entry.js +0 -205
- package/dist/esm/bcm-form.entry.js +0 -484
- package/dist/esm/bcm-input.entry.js +0 -367
- package/dist/esm/bcm-label.entry.js +0 -41
- package/dist/esm/bcm-old-input.entry.js +0 -393
- package/dist/esm/bcm-time-picker.entry.js +0 -145
- package/dist/esm/datetime-helper-df25808a.js +0 -9
- package/dist/esm/index-962dec74.js +0 -50
- package/dist/types/components/other/data-table/table.d.ts +0 -8
|
@@ -2,32 +2,29 @@
|
|
|
2
2
|
* Built with Stencil
|
|
3
3
|
* Copyright (c) Bromcom.
|
|
4
4
|
*/
|
|
5
|
-
import { h
|
|
6
|
-
import { I as IsLoad } from './is-load-decorator-
|
|
7
|
-
import { J as JsonParse } from './json-parse-decarator-
|
|
8
|
-
import './color-helper-
|
|
9
|
-
import './
|
|
10
|
-
import { s as snq, G as Generate } from './generate-
|
|
11
|
-
import { N as NumberHelper } from './number-helper-
|
|
12
|
-
import { S as StringHelper } from './string-helper-
|
|
13
|
-
import
|
|
14
|
-
import './
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import { c as classnames } from './index-ed9652af.js';
|
|
5
|
+
import { h, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-0615c2b8.js';
|
|
6
|
+
import { I as IsLoad } from './is-load-decorator-8277e3b8.js';
|
|
7
|
+
import { J as JsonParse } from './json-parse-decarator-2945634b.js';
|
|
8
|
+
import './color-helper-845ba523.js';
|
|
9
|
+
import { V as Validators } from './validators-22975416.js';
|
|
10
|
+
import { s as snq, G as Generate } from './generate-7a1258c4.js';
|
|
11
|
+
import { N as NumberHelper } from './number-helper-fe7d1aca.js';
|
|
12
|
+
import { S as StringHelper } from './string-helper-b0e05041.js';
|
|
13
|
+
import './element-dragger-89bb52fd.js';
|
|
14
|
+
import { g as getPlacement, s as setPosition } from './popover-placement-be68c848.js';
|
|
15
|
+
import { p as pluralize, d as delay } from './utils-57652744.js';
|
|
16
|
+
import { B as Bcm, a as Bcm$1 } from './bcm-d45dc47d.js';
|
|
17
|
+
import { C as CaptionTemplate } from './caption-template-d47f338f.js';
|
|
18
|
+
import { c as classnames } from './index-00c8a8f7.js';
|
|
20
19
|
import './types-6f06fa1a.js';
|
|
21
|
-
import { L as LabelTemplate } from './label-template-98dafeb3.js';
|
|
22
20
|
import './types-9493a7ed.js';
|
|
23
|
-
import { c as createStore } from './index-
|
|
24
|
-
import { r as react, a as reactDom } from './index-
|
|
25
|
-
import {
|
|
26
|
-
import { I as InputTemplate } from './input-template-0bdd4dda.js';
|
|
21
|
+
import { c as createStore } from './index-7e71bbc8.js';
|
|
22
|
+
import { r as react, k as RefResizeObserver, d as wrapperRaf, u as useEvent, a as reactDom, e as useLayoutEffect } from './index-e4b6a4ce.js';
|
|
23
|
+
import { I as InputTemplate } from './input-template-68c29fde.js';
|
|
27
24
|
import './colors-1d7854ea.js';
|
|
28
|
-
import './colors-
|
|
29
|
-
import './
|
|
30
|
-
import './
|
|
25
|
+
import './colors-ebea297f.js';
|
|
26
|
+
import './_commonjsHelpers-7002e5de.js';
|
|
27
|
+
import './package-acbf2052.js';
|
|
31
28
|
|
|
32
29
|
const CheckboxTemplate = ({ disabled, checked, readonly, required, indeterminate, hidden, captionType, _id }) => {
|
|
33
30
|
// if ( indeterminate ) {
|
|
@@ -47,18 +44,18 @@ const CheckboxTemplate = ({ disabled, checked, readonly, required, indeterminate
|
|
|
47
44
|
'bcm-checkbox__label-icon-checked': checked,
|
|
48
45
|
});
|
|
49
46
|
const bcmCheckboxLabelClass = classnames('bcm-checkbox__label');
|
|
50
|
-
return (h
|
|
51
|
-
h
|
|
52
|
-
h
|
|
53
|
-
h
|
|
54
|
-
h
|
|
47
|
+
return (h("div", { class: hostClasses },
|
|
48
|
+
h("input", { tabindex: "-1", id: _id, type: "checkbox", checked: checked, disabled: disabled, required: required, readonly: readonly }),
|
|
49
|
+
h("label", { class: bcmCheckboxLabelClass, htmlFor: _id },
|
|
50
|
+
h("span", { class: bcmCheckboxIconClass },
|
|
51
|
+
h("bcm-icon", { icon: "far fa-check" })))));
|
|
55
52
|
};
|
|
56
53
|
|
|
57
54
|
const InfoFooterTemplate = ({ selected, total, found, multiple, variableText }) => {
|
|
58
55
|
total = total || 0;
|
|
59
56
|
variableText = variableText ? pluralize(variableText, total) : 'items';
|
|
60
|
-
return (h
|
|
61
|
-
h
|
|
57
|
+
return (h("footer", { class: "bcm-info-footer" },
|
|
58
|
+
h("bcm-text", { scale: "size-1", color: "grey-8" },
|
|
62
59
|
(multiple && selected > 0) && ` ( ${selected} selected ) `,
|
|
63
60
|
` Total ${total} `,
|
|
64
61
|
found != null && ` / ${found} `,
|
|
@@ -100,20 +97,20 @@ const ListItemTemplate = ({ item, treeview, highlight, checkboxes, size, selecte
|
|
|
100
97
|
item.open = item.isSearching;
|
|
101
98
|
openGroup(item.id);
|
|
102
99
|
};
|
|
103
|
-
return (h
|
|
100
|
+
return (h("div", { id: item.id, hidden: item.hidden, "on-focus": e => !unClickable && !disabled && focusItem(e), class: classnames('bcm-list__item',
|
|
104
101
|
// size === 'large' ? 'size-3' : 'size-2',
|
|
105
102
|
'bcm-list__item-' + size, {
|
|
106
103
|
'bcm-list__item--group': !treeview && item.type == 'group',
|
|
107
104
|
'bcm-list__item--readonly': readonly,
|
|
108
105
|
}) },
|
|
109
|
-
h
|
|
110
|
-
treeview && (h
|
|
111
|
-
h
|
|
112
|
-
checkboxes && (treeview || (!treeview && item.type != 'group')) && (h
|
|
113
|
-
h
|
|
114
|
-
h
|
|
115
|
-
(treeview || !treeview && item.type == "group") && isHaveChildren && (h
|
|
116
|
-
item.items.map((item) => (h
|
|
106
|
+
h("div", { class: classnames('bcm-list__item-content', !checkboxes && item.selected && 'selected', { disabled: disabled }) },
|
|
107
|
+
treeview && (h("div", { class: "bcm-list__item-content-collapse-icon", onClick: () => collapseClick() }, isHaveChildren && h("bcm-icon", { icon: classnames('fas fa-caret-' + (item.isSearching || item.open ? 'down' : 'right')) }))),
|
|
108
|
+
h("div", { class: classnames('bcm-list__item-content-text', { treeview }), onClick: (e) => itemClick(e) },
|
|
109
|
+
checkboxes && (treeview || (!treeview && item.type != 'group')) && (h("div", { class: "bcm-list__item-content-text-checkbox" },
|
|
110
|
+
h(CheckboxTemplate, { indeterminate: item.indeterminate, checked: item.checked, disabled: item.disabled }))),
|
|
111
|
+
h("span", Object.assign({ class: "bcm-list__item-content-text-inner" }, (item.title && { "title": item.title }), { innerHTML: text })))),
|
|
112
|
+
(treeview || !treeview && item.type == "group") && isHaveChildren && (h("div", { class: "bcm-list__item-childs" }, (item.isSearching || item.open || (!treeview && item.type == "group")) &&
|
|
113
|
+
item.items.map((item) => (h(ListItemTemplate, { highlight: highlight, item: item, searchIsOnlyChilds: searchIsOnlyChilds, treeview: treeview, checkboxes: checkboxes, size: size, selectedItem: selectedItem, checkedItem: checkedItem, openGroup: parentId => openGroup(parentId), focusItem: itemId => focusItem(itemId) })))))));
|
|
117
114
|
};
|
|
118
115
|
|
|
119
116
|
const ListTemplate = ({ highlight, selectAllItem, bcmListContainer, treeview, checkboxes, checkAll, infoFooter, value, totalData, searchFound, variableText, _id, data, width, height, size, searchPlaceholder, minSearchLength, selectedItem, openGroup, checkedItem, onScrollEvent, focusItem, items, searchable, searchIsOnlyChilds, emptyText, emptyIcon, }) => {
|
|
@@ -130,21 +127,21 @@ const ListTemplate = ({ highlight, selectAllItem, bcmListContainer, treeview, ch
|
|
|
130
127
|
'flex-direction': 'column',
|
|
131
128
|
};
|
|
132
129
|
};
|
|
133
|
-
return (h
|
|
134
|
-
data && searchable && (h
|
|
135
|
-
h
|
|
136
|
-
h
|
|
137
|
-
h
|
|
138
|
-
checkAll && searchFound != 0 && items && items.length > 0 && checkboxes && showSelectAll && (h
|
|
139
|
-
h
|
|
140
|
-
items.map((item) => (h
|
|
141
|
-
(!items || items.length === 0) && searchFound != 0 && (h
|
|
142
|
-
h
|
|
143
|
-
h
|
|
144
|
-
searchFound == 0 && (h
|
|
145
|
-
h
|
|
146
|
-
h
|
|
147
|
-
infoFooter && data && data.length > 0 && (h
|
|
130
|
+
return (h("div", { id: `bcm-list-${_id}`, class: bcmListContainer, style: { '--height': height, '--width': width } },
|
|
131
|
+
data && searchable && (h("section", { class: "bcm-list__container-search" },
|
|
132
|
+
h("bcm-search", { size: size, id: `bcm-list-${_id}-search`, data: data, clearable: true, placeholder: searchPlaceholder, "min-search-length": minSearchLength, searchIsOnlyChilds: searchIsOnlyChilds }))),
|
|
133
|
+
h("main", { onScroll: e => onScrollEvent(e), class: "scrolling", style: { 'overscroll-behavior': 'none' } },
|
|
134
|
+
h("div", { style: setScrollHeight() },
|
|
135
|
+
checkAll && searchFound != 0 && items && items.length > 0 && checkboxes && showSelectAll && (h("section", { class: "bcm-list__container-select-all" },
|
|
136
|
+
h(ListItemTemplate, { size: size, item: selectAllItem, treeview: false, checkboxes: true, selectedItem: itemId => selectedItem(itemId), checkedItem: itemId => checkedItem(itemId), openGroup: parentId => openGroup(parentId), focusItem: itemId => focusItem(itemId) }))),
|
|
137
|
+
items.map((item) => (h(ListItemTemplate, { highlight: highlight, size: size, item: item, searchIsOnlyChilds: searchIsOnlyChilds, treeview: treeview, checkboxes: checkboxes, selectedItem: itemId => selectedItem(itemId), checkedItem: itemId => checkedItem(itemId), openGroup: parentId => openGroup(parentId), focusItem: itemId => focusItem(itemId) }))),
|
|
138
|
+
(!items || items.length === 0) && searchFound != 0 && (h("section", { class: "bcm-list__container-no-data" },
|
|
139
|
+
h("bcm-empty", { style: { height: 'auto' }, icon: emptyIcon },
|
|
140
|
+
h("span", { innerHTML: emptyText || 'No data' })))),
|
|
141
|
+
searchFound == 0 && (h("section", { class: "bcm-list__container-no-data" },
|
|
142
|
+
h("bcm-empty", { style: { height: 'auto' }, icon: emptyIcon },
|
|
143
|
+
h("span", { innerHTML: emptyText || 'No Data Found' })))))),
|
|
144
|
+
infoFooter && data && data.length > 0 && (h(InfoFooterTemplate, { selected: value === null || value === void 0 ? void 0 : value.length, total: totalData, found: searchFound, multiple: checkboxes, variableText: variableText }))));
|
|
148
145
|
};
|
|
149
146
|
|
|
150
147
|
const { state: state$1 } = createStore({
|
|
@@ -843,7 +840,7 @@ class ListKeyControl extends KeyControl {
|
|
|
843
840
|
keyUp() { }
|
|
844
841
|
}
|
|
845
842
|
|
|
846
|
-
const listCss = "@import url(\"https://fonts.googleapis.com/css?family=Roboto:400,500\");@import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); @import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); @import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); @import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); .size-1{font-size:12px;line-height:20px}.size-2{font-size:14px;line-height:22px}.size-3{font-size:16px;line-height:24px}.size-4{font-size:20px;line-height:28px}.size-5{font-size:24px;line-height:32px}.size-6{font-size:30px;line-height:38px}.size-7{font-size:38px;line-height:46px}.size-8{font-size:46px;line-height:54px}.size-9{font-size:56px;line-height:64px}.weight-regular{font-weight:400}.weight-semibold{font-weight:500}.input-size-large{height:40px}.input-size-medium{height:32px}.input-size-small{height:24px}.resize-none textarea{resize:none}.resize-vertical textarea{resize:vertical}.resize-auto textarea{height:auto;resize:none}.textarea-size-large{padding:4px 0 0 4px;min-height:40px}.textarea-size-large .bcm-input-element{min-height:calc((40px - 8px) + 2px)}.textarea-size-large .input-clear-button{height:calc( 40px - 16px );top:8px;padding:0;margin-right:8px}.textarea-size-medium{padding:4px 0 0 4px;min-height:32px}.textarea-size-medium .bcm-input-element{min-height:calc((32px - 8px) + 2px)}.textarea-size-medium .input-clear-button{height:calc( 32px - 16px );top:8px;padding:0;margin-right:8px}.textarea-size-small{padding:0px 0 0 4px;min-height:24px}.textarea-size-small .bcm-input-element{min-height:calc((24px - 8px) + 2px)}.textarea-size-small .input-clear-button{height:calc( 24px - 16px );top:8px;padding:0;margin-right:8px}*{box-sizing:border-box}.bcm-caption-area{font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;font-size:12px;line-height:calc(12px + 8px);color:var(--bcm-new-ds-color-slate-400);display:flex;flex-direction:row;align-items:flex-start;justify-content:space-between;flex-wrap:nowrap;margin-top:2px}.bcm-caption-area__text{color:var(--bcm-new-ds-color-slate-400)}.bcm-caption-area__text.default{color:var(--bcm-new-ds-color-slate-400)}.bcm-caption-area__text.info{color:var(--bcm-new-ds-color-blue-500)}.bcm-caption-area__text.success{color:var(--bcm-new-ds-color-emerald-500)}.bcm-caption-area__text.warning{color:var(--bcm-new-ds-color-amber-500)}.bcm-caption-area__text.error{color:var(--bcm-new-ds-color-red-500)}.bcm-caption-area__size-small{font-size:10px;line-height:calc(10px + 8px);min-height:calc(10px + 8px)}.bcm-caption-area__size-medium{font-size:12px;line-height:calc(12px + 8px);min-height:calc(12px + 8px)}.bcm-caption-area__size-large{font-size:14px;line-height:calc(14px + 8px);min-height:calc(14px + 8px)}*{box-sizing:border-box}.bcm-label{display:inline-flex;align-items:flex-start;grid-gap:2px}.bcm-label__text{margin-bottom:2px;font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;display:inline-block;color:var(--bcm-new-ds-color-slate-600)}.bcm-label__size-small{font-size:10px;line-height:calc(10px + 8px);min-height:calc(10px + 8px)}.bcm-label__size-medium{font-size:12px;line-height:calc(12px + 8px);min-height:calc(12px + 8px)}.bcm-label__size-large{font-size:14px;line-height:calc(14px + 8px);min-height:calc(14px + 8px)}.bcm-input[no-margin]{margin:0}.bcm-textarea[no-margin]{margin:0}.bcm-switch[no-margin]{margin:0}.bcm-checkbox[no-margin]{margin:0}.bcm-radio-group[no-margin]{margin:0}.bcm-checkbox-group[no-margin]{margin:0}.bcm-range[no-margin]{margin:0}.bcm-form[no-margin]{margin:0}.bcm-form-group[no-margin]{margin:0}.bcm-list[no-margin]{margin:0}.bcm-colorpicker[no-margin]{margin:0}.bcm-date-picker[no-margin]{margin:0}.bcm-time-picker[no-margin]{margin:0}.bcm-datetime-picker[no-margin]{margin:0}.bcm-select[no-margin]{margin:0}.bcm-listbox[no-margin]{margin:0}*{box-sizing:border-box}*{box-sizing:border-box}.bcm-checkbox{outline:none;border:none;--bcm-checkbox-primary-color-default:var(--bcm-new-ds-color-blue-500);--bcm-checkbox-secondary-color-default:var(--bcm-new-ds-color-white);--bcm-checkbox-primary-color-hover:var(--bcm-new-ds-color-blue-600);--bcm-checkbox-secondary-color-hover:var(--bcm-new-ds-color-slate-50);--bcm-checkbox-primary-color-focus-visible:var(--bcm-new-ds-color-blue-800);--bcm-checkbox-secondary-color-focus-visible:var(--bcm-new-ds-color-slate-50);--bcm-checkbox-primary-color-active:var(--bcm-new-ds-color-blue-700);--bcm-checkbox-secondary-color-active:var(--bcm-new-ds-color-slate-50);--bcm-checkbox-primary-color-disabled:var(--bcm-new-ds-color-slate-300);--bcm-checkbox-secondary-color-disabled:var(--bcm-new-ds-color-slate-200);display:inline-flex;width:fit-content;flex-direction:column;margin-bottom:8px}.bcm-checkbox:focus,.bcm-checkbox:hover,.bcm-checkbox:active{outline:none;border:none}.bcm-checkbox *{box-sizing:border-box}.bcm-checkbox input[type=radio],.bcm-checkbox input[type=checkbox]{-webkit-appearance:none;appearance:none;background-color:#fff;margin:0;display:none}.bcm-checkbox__input{display:flex;flex-direction:row;align-items:flex-start;justify-content:flex-start;flex-wrap:nowrap;padding-top:4px}.bcm-checkbox.hidden{display:none}.bcm-checkbox :hover{cursor:pointer}.bcm-checkbox[disabled] :hover,.bcm-checkbox.disabled :hover{cursor:not-allowed}.bcm-checkbox .slot{font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;font-weight:500;color:var(--bcm-new-ds-color-slate-600)}.bcm-checkbox .slot:not(:empty){margin-left:8px;margin-right:8px}.bcm-checkbox-size-small .slot{font-size:12px;line-height:calc(12px + 8px);margin-top:-2.5px}.bcm-checkbox-size-small .bcm-checkbox__input{min-height:calc(24px - 4px)}.bcm-checkbox-size-small .bcm-checkbox__label-icon{width:14px;height:14px;min-width:14px;font-size:calc(10px - 2px)}.bcm-checkbox-size-medium .slot{font-size:calc(12px + 1px);line-height:calc(12px + 8px);margin-top:-1.5px}.bcm-checkbox-size-medium .bcm-checkbox__input{min-height:calc(32px - 4px)}.bcm-checkbox-size-medium .bcm-checkbox__label-icon{width:16px;height:16px;min-width:16px;font-size:10px}.bcm-checkbox-size-large .slot{font-size:16px;line-height:calc(16px + 8px);margin-top:-1.5px}.bcm-checkbox-size-large .bcm-checkbox__input{min-height:calc(32px - 4px)}.bcm-checkbox-size-large .bcm-checkbox__label-icon{width:18px;height:18px;min-width:18px;font-size:12px}.bcm-checkbox__label{display:flex;flex-direction:row;align-items:flex-start;justify-content:flex-start;flex-wrap:nowrap}.bcm-checkbox__label-icon{display:flex;flex-direction:column;align-items:center;justify-content:center;flex-wrap:nowrap;border-width:1px;border-style:solid;border-radius:2px}.bcm-checkbox__label-icon-indeterminate{position:relative}.bcm-checkbox__label-icon-indeterminate:after{content:\"\";display:block;position:absolute;width:70%;height:1.5px;background:var(--bcm-new-ds-color-white)}.bcm-checkbox__label-icon.bcm-radio__icon{width:16px;height:16px;box-sizing:border-box;border-radius:100px}.bcm-checkbox__label-icon.bcm-radio__icon .bcm-radio__icon-inner{width:10px;height:10px;border-radius:100px;background-color:var(--bcm-new-ds-color-white)}.bcm-checkbox .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-default);color:var(--bcm-checkbox-secondary-color-default);border-color:var(--bcm-new-ds-color-slate-300)}.bcm-checkbox .bcm-checkbox__label-icon-checked,.bcm-checkbox .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-default);border-color:var(--bcm-checkbox-primary-color-default)}.bcm-checkbox .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-default);background-color:var(--bcm-checkbox-secondary-color-default)}.bcm-checkbox .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-default)}.bcm-checkbox .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-default)}.bcm-checkbox:hover .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-hover);color:var(--bcm-checkbox-secondary-color-hover);border-color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-checked,.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-hover);border-color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-hover);background-color:var(--bcm-checkbox-secondary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-focus-visible);color:var(--bcm-checkbox-secondary-color-focus-visible);border-color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-checked,.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-focus-visible);border-color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-focus-visible);background-color:var(--bcm-checkbox-secondary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:active .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-active);color:var(--bcm-checkbox-secondary-color-active);border-color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-checked,.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-active);border-color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-active);background-color:var(--bcm-checkbox-secondary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon,.bcm-checkbox.disabled .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-disabled);color:var(--bcm-checkbox-secondary-color-disabled);border-color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-checked,.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate,.bcm-checkbox.disabled .bcm-checkbox__label-icon-checked,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-disabled);border-color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon,.bcm-checkbox.disabled .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-disabled);background-color:var(--bcm-checkbox-secondary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox.disabled .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[no-margin] .bcm-checkbox__input{margin:0;min-height:0;padding:0}.bcm-list{font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;--width:256px;--height:256px;--max-height:inherit;--min-height:inherit;min-width:90px;display:flex;flex-direction:column;margin:0 0 8px 0}.bcm-list__listbox .bcm-list__container{height:var(--height);max-height:var(--max-height);min-height:var(--min-height)}.bcm-list.full-width{width:100%}.bcm-list__size-small .bcm-list__input{height:24px;font-size:12px;line-height:calc(12px + 8px)}.bcm-list__size-small .bcm-list__input .bcm-tag__content.dismissable{font-size:10px;line-height:calc(10px + 8px)}.bcm-list__size-medium .bcm-list__input{height:32px;font-size:14px;line-height:calc(14px + 8px)}.bcm-list__size-medium .bcm-list__input .bcm-tag__content.dismissable{font-size:12px;line-height:calc(12px + 8px)}.bcm-list__size-large .bcm-list__input{height:40px;font-size:16px;line-height:calc(16px + 8px)}.bcm-list__size-large .bcm-list__input .bcm-tag__content.dismissable{font-size:14px;line-height:calc(14px + 8px)}.bcm-list:hover{outline:none}.bcm-list:hover .bcm-list__input{border-color:var(--bcm-new-ds-color-blue-500);background-color:var(--bcm-new-ds-color-slate-50)}.bcm-list:focus-visible{outline:none}.bcm-list:focus-visible .bcm-list__input{border-color:var(--bcm-new-ds-color-blue-600);background-color:var(--bcm-new-ds-color-white)}.bcm-list:active{outline:none}.bcm-list:active .bcm-list__input{border-color:var(--bcm-new-ds-color-blue-600);box-shadow:0 1px 3px 0 rgba(17, 24, 38, 0.1)}.bcm-list__container{--width:256px;--height:256px;width:var(--width);height:var(--height);background-color:var(--bcm-new-ds-color-white);border:1px solid var(--bcm-new-ds-color-slate-300);border-radius:4px;box-sizing:border-box;padding-top:8px;display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;flex-wrap:nowrap;gap:4px}.bcm-list__container main{scroll-behavior:smooth;padding:0 8px;flex:1;overflow:auto;display:flex;flex-direction:column}.bcm-list__container-search{margin:0 8px}.bcm-list__container-search:after{margin:4px 0}.bcm-list__container-no-data{flex:1;display:flex;justify-content:stretch;align-items:stretch;padding-bottom:4px}.bcm-list__container.error{border-color:var(--bcm-color-red-6)}.bcm-list__container.full-width{width:100%}.bcm-list__container.bcm-list__type-linked-component,.bcm-list__container.bcm-list__type-select,.bcm-list__container.bcm-list__type-autocomplete{opacity:0;visibility:hidden;position:absolute;top:0;left:0;height:0;width:0;transform:translateY(10%);z-index:10800;transition:visibility 0s linear 400ms, opacity 100ms, transform 200ms}.bcm-list__container.bcm-list__type-linked-component.bcm-list--top,.bcm-list__container.bcm-list__type-select.bcm-list--top,.bcm-list__container.bcm-list__type-autocomplete.bcm-list--top{transform:translateY(-10%)}.bcm-list__container.bcm-list__type-linked-component.is-open,.bcm-list__container.bcm-list__type-select.is-open,.bcm-list__container.bcm-list__type-autocomplete.is-open{opacity:1;transform:translateY(0);visibility:visible;transition:visibility 0s linear 0s, opacity 100ms, transform 100ms}.bcm-list__container.bcm-list__type-linked-component{margin-top:2px}.bcm-list__label{line-height:1}.bcm-list__input{display:flex;align-items:center;justify-content:space-between;box-sizing:border-box;border:1px solid var(--bcm-new-ds-color-slate-300);border-radius:4px;color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-white);user-select:none;cursor:pointer;padding:0 8px;height:32px;overflow:hidden;position:relative;transition:background-color 100ms, border-color 100ms}.bcm-list__input-spinner{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;background-color:var(--bcm-color-grey-1);opacity:0;visibility:hidden;transition:opacity 0.2s ease-in-out;z-index:-1}.bcm-list__input-spinner.is-open{opacity:1;visibility:visible;z-index:1}.bcm-list__input-container{flex:1;display:block;overflow:hidden}.bcm-list__input-container.value-empty{color:var(--bcm-color-grey-6)}.bcm-list__input-container.type-single,.bcm-list__input-container.value-empty{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.bcm-list__input-placeholder{color:var(--bcm-color-grey-6)}.bcm-list__input-tag-container{height:100%;width:100%;display:flex;align-items:center;justify-content:flex-start;flex-wrap:nowrap;grid-gap:2px;line-height:1}.bcm-list__input-buttons{display:flex;align-items:center;justify-content:flex-end;grid-gap:4px}.bcm-list__input-buttons-button{display:flex;align-items:center;justify-content:center;box-sizing:border-box;padding:4px 4px 0 4px;font-size:16px;color:var(--bcm-new-ds-color-slate-500)}.bcm-list__input-buttons-button.caret-is{transform:rotate(360deg);transition:transform 0.2s ease-in-out}.bcm-list__input-buttons-button.caret-is-open{transform:rotate(180deg)}.bcm-list__input-buttons:not(.disabled) .bcm-list__input-buttons-button:hover{cursor:pointer;color:var(--bcm-new-ds-color-slate-600)}.bcm-list__input-autocomplete{position:relative;padding-right:0}.bcm-list__input-autocomplete .bcm-list-input-selected-text{background-color:#ffffff;display:flex;align-items:center;justify-content:flex-start;width:calc(100% - 24px);height:100%;padding:0 calc(8px + 4px);position:absolute;top:0;left:0}.bcm-list__input-autocomplete .bcm-list__input-container{height:100%;display:flex;flex-direction:row}.bcm-list__input-autocomplete .bcm-list__input-container .bcm-list__input-tag-container{width:auto}.bcm-list__input-autocomplete .bcm-input,.bcm-list__input-autocomplete .bcm-list__autocomplete{height:100%;min-width:70px;width:100%}.bcm-list__input-autocomplete .bcm-input__container,.bcm-list__input-autocomplete .bcm-list__autocomplete__container{height:100%;border:none;padding:0;width:100%}.bcm-list__input-autocomplete .bcm-input__container:not(.disabled).focused,.bcm-list__input-autocomplete .bcm-input__container:not(.disabled):hover,.bcm-list__input-autocomplete .bcm-list__autocomplete__container:not(.disabled).focused,.bcm-list__input-autocomplete .bcm-list__autocomplete__container:not(.disabled):hover{border:none;box-shadow:none}.bcm-list__autocomplete{width:100%;position:relative}.bcm-list.full-width .bcm-list__container,.bcm-list.full-width .bcm-list__input{width:100%}.bcm-list.error .bcm-list__input{border-color:var(--bcm-color-red-6)}.bcm-list.disabled .bcm-list__container,.bcm-list.disabled .bcm-list__input{color:var(--bcm-new-ds-color-slate-300);background-color:var(--bcm-new-ds-color-slate-50);cursor:not-allowed}.bcm-list.disabled .bcm-tag__content.dismissable .close-button{cursor:default}.bcm-list:not(.disabled) .bcm-list__input .bcm-tag__content.checked .close-button bcm-icon{color:var(--bcm-new-ds-color-slate-100)}.bcm-list:not(.disabled) .bcm-list__input .bcm-tag__content.checked .close-button:hover bcm-icon{color:var(--bcm-new-ds-color-slate-200)}.bcm-list:not(.disabled) .bcm-list__input:hover{border-color:var(--bcm-new-ds-color-blue-500)}.bcm-list:not(.disabled) .bcm-list__input:hover .bcm-tag__content.dismissable:not(.checked){background-color:var(--bcm-new-ds-color-slate-200);border-color:var(--bcm-new-ds-color-slate-200)}.bcm-list:not(.disabled) .bcm-list__input:focus-visible{border-color:var(--bcm-new-ds-color-blue-500);box-shadow:0 1px 3px 0 rgba(17, 24, 38, 0.1)}.bcm-list:not(.disabled) .bcm-list__input:active{border-color:var(--bcm-new-ds-color-blue-500)}.bcm-list__item{padding:2px 0}.bcm-list__item.disabled{user-select:none}.bcm-list__item:focus{outline:none}.bcm-list__item:focus-visible>.bcm-list__item-content{background-color:var(--bcm-new-ds-color-slate-300)}.bcm-list__item:focus-visible>.bcm-list__item-content:not(.disabled){color:var(--bcm-new-ds-color-slate-600)}.bcm-list__item-content{display:flex;flex-direction:row;align-items:stretch;justify-content:flex-start;flex-wrap:nowrap;cursor:pointer;border-radius:4px;padding:0;padding-left:4px;color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-slate-50);transition:background-color 0.2s ease}.bcm-list__item-content.disabled{color:var(--bcm-new-ds-color-slate-300);background-color:var(--bcm-new-ds-color-slate-50);user-select:none;cursor:not-allowed}.bcm-list__item-content.selected{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-new-ds-color-blue-500)}.bcm-list__item-content.selected:hover:not(.disabled){color:var(--bcm-new-ds-color-white);background-color:var(--bcm-new-ds-color-blue-600)}.bcm-list__item-content:hover:not(.disabled){color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-slate-100)}.bcm-list__item-content:active:not(.disabled){color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-slate-200)}.bcm-list__item-content-collapse-icon{width:16px;padding:0 8px;display:flex;align-items:center;justify-content:center;font-size:16px}.bcm-list__item-content-collapse-icon.child{cursor:pointer}.bcm-list__item-content-text{user-select:none;padding:8px;width:100%;display:flex;flex-direction:row;align-items:center;justify-content:flex-start}.bcm-list__item-content-text.treeview{padding:8px 0}.bcm-list__item-content-text-checkbox{display:flex;flex-direction:row;align-items:center;justify-content:center;flex-wrap:nowrap;margin-right:8px}.bcm-list__item-content-text-checkbox .bcm-checkbox{margin:0}.bcm-list__item-content-text-inner{width:100%}.bcm-list__item-content-text mark{padding:0;margin:0;font-size:inherit;color:var(--bcm-color-grey-8);background-color:var(--bcm-color-yellow-4)}.bcm-list__item-childs{padding-left:16px}.bcm-list__item-small{padding:2px 0 2px 8px;font-size:10px;line-height:calc(10px + 8px)}.bcm-list__item-small .bcm-list__item-content-text{padding:3px 4px}.bcm-list__item-medium{font-size:12px;line-height:calc(12px + 8px)}.bcm-list__item-medium .bcm-list__item-content-text{padding:6px 4px}.bcm-list__item-large{font-size:14px;line-height:calc(14px + 8px)}.bcm-list__item-large .bcm-list__item-content-text{padding:9px 4px}.bcm-list__item--readonly:focus>.bcm-list__item-content:not(.disabled),.bcm-list__item--readonly.focused>.bcm-list__item-content:not(.disabled){color:var(--bcm-color-grey-7)}.bcm-list__item--readonly>.bcm-list__item-content{color:var(--bcm-color-grey-7)}.bcm-list__item--readonly>.bcm-list__item-content:hover,.bcm-list__item--readonly>.bcm-list__item-content:focus{color:var(--bcm-color-grey-7)}.bcm-list__item--group{border-radius:4px}.bcm-list__item--group:focus>.bcm-list__item-content:not(.disabled){background-color:var(--bcm-new-ds-color-slate-50);color:var(--bcm-new-ds-color-slate-600)}.bcm-list__item--group>.bcm-list__item-content{background-color:var(--bcm-new-ds-color-slate-50);color:var(--bcm-new-ds-color-slate-600);border-radius:4px 4px 0 0;cursor:default;font-size:14px;line-height:calc(14px + 8px);font-weight:500;position:sticky;top:0}.bcm-list__item--group>.bcm-list__item-content>.bcm-list__item-content-text{padding:4px 8px 4px 16px}.bcm-list__item--group>.bcm-list__item-content:hover,.bcm-list__item--group>.bcm-list__item-content:focus{color:var(--bcm-new-ds-color-slate-800);background-color:var(--bcm-new-ds-color-slate-50)}.bcm-list__item--group>.bcm-list__item-content-unclickable:hover{color:var(--bcm-new-ds-color-slate-700);background-color:var(--bcm-new-ds-color-slate-50)}.bcm-list__item--group>.bcm-list__item-childs{background-color:var(--bcm-new-ds-color-slate-50);color:var(--bcm-new-ds-color-slate-600);padding-bottom:8px;border-radius:0 0 4px 4px;padding-left:8px}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content{background-color:var(--bcm-new-ds-color-white);color:var(--bcm-new-ds-color-slate-600)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content:hover{background-color:var(--bcm-new-ds-color-slate-100)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content:active{background-color:var(--bcm-new-ds-color-slate-200)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content:focus-visible{background-color:var(--bcm-new-ds-color-slate-300)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content.selected{background-color:var(--bcm-new-ds-color-blue-500);color:var(--bcm-new-ds-color-white)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content.selected:hover{background-color:var(--bcm-new-ds-color-blue-600)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content.selected:active{background-color:var(--bcm-new-ds-color-blue-700)}.bcm-list__linked{display:none}.bcm-list .bcm-tag--other .value{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.bcm-info-footer{text-align:right;padding:4px 8px;background-color:var(--bcm-new-ds-color-slate-100);color:var(--bcm-new-ds-color-slate-600);border-radius:0 0 4px 4px}";
|
|
843
|
+
const listCss = "@import url(\"https://fonts.googleapis.com/css?family=Roboto:400,500\");@import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); @import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); @import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); @import url(\"https://fonts.googleapis.com/css2?family=Inter:wght@200;400;500;600&display=swap\"); .size-1{font-size:12px;line-height:20px}.size-2{font-size:14px;line-height:22px}.size-3{font-size:16px;line-height:24px}.size-4{font-size:20px;line-height:28px}.size-5{font-size:24px;line-height:32px}.size-6{font-size:30px;line-height:38px}.size-7{font-size:38px;line-height:46px}.size-8{font-size:46px;line-height:54px}.size-9{font-size:56px;line-height:64px}.weight-regular{font-weight:400}.weight-semibold{font-weight:500}.input-size-large{height:40px}.input-size-medium{height:32px}.input-size-small{height:24px}.resize-none textarea{resize:none}.resize-vertical textarea{resize:vertical}.resize-auto textarea{height:auto;resize:none}.textarea-size-large{padding:4px 0 0 4px;min-height:40px}.textarea-size-large .bcm-input-element{min-height:calc((40px - 8px) + 2px)}.textarea-size-large .input-clear-button{height:calc( 40px - 16px );top:8px;padding:0;margin-right:8px}.textarea-size-medium{padding:4px 0 0 4px;min-height:32px}.textarea-size-medium .bcm-input-element{min-height:calc((32px - 8px) + 2px)}.textarea-size-medium .input-clear-button{height:calc( 32px - 16px );top:8px;padding:0;margin-right:8px}.textarea-size-small{padding:0px 0 0 4px;min-height:24px}.textarea-size-small .bcm-input-element{min-height:calc((24px - 8px) + 2px)}.textarea-size-small .input-clear-button{height:calc( 24px - 16px );top:8px;padding:0;margin-right:8px}*{box-sizing:border-box}.bcm-caption-area{font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;font-size:12px;line-height:calc(12px + 8px);color:var(--bcm-new-ds-color-slate-400);display:flex;flex-direction:row;align-items:flex-start;justify-content:space-between;flex-wrap:nowrap;margin-top:2px}.bcm-caption-area__text{color:var(--bcm-new-ds-color-slate-400)}.bcm-caption-area__text.default{color:var(--bcm-new-ds-color-slate-400)}.bcm-caption-area__text.info{color:var(--bcm-new-ds-color-blue-500)}.bcm-caption-area__text.success{color:var(--bcm-new-ds-color-emerald-500)}.bcm-caption-area__text.warning{color:var(--bcm-new-ds-color-amber-500)}.bcm-caption-area__text.error{color:var(--bcm-new-ds-color-red-500)}.bcm-caption-area__size-small{font-size:10px;line-height:calc(10px + 8px);min-height:calc(10px + 8px)}.bcm-caption-area__size-medium{font-size:12px;line-height:calc(12px + 8px);min-height:calc(12px + 8px)}.bcm-caption-area__size-large{font-size:14px;line-height:calc(14px + 8px);min-height:calc(14px + 8px)}*{box-sizing:border-box}.bcm-label{display:inline-flex;align-items:flex-start;grid-gap:2px}.bcm-label__text{margin-bottom:2px;font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;display:inline-block;color:var(--bcm-new-ds-color-slate-600)}.bcm-label__size-small{font-size:10px;line-height:calc(10px + 8px);min-height:calc(10px + 8px)}.bcm-label__size-medium{font-size:12px;line-height:calc(12px + 8px);min-height:calc(12px + 8px)}.bcm-label__size-large{font-size:14px;line-height:calc(14px + 8px);min-height:calc(14px + 8px)}.bcm-input[no-margin]{margin:0}.bcm-textarea[no-margin]{margin:0}.bcm-switch[no-margin]{margin:0}.bcm-checkbox[no-margin]{margin:0}.bcm-radio-group[no-margin]{margin:0}.bcm-checkbox-group[no-margin]{margin:0}.bcm-range[no-margin]{margin:0}.bcm-form[no-margin]{margin:0}.bcm-form-group[no-margin]{margin:0}.bcm-list[no-margin]{margin:0}.bcm-colorpicker[no-margin]{margin:0}.bcm-date-picker[no-margin]{margin:0}.bcm-time-picker[no-margin]{margin:0}.bcm-datetime-picker[no-margin]{margin:0}.bcm-select[no-margin]{margin:0}.bcm-listbox[no-margin]{margin:0}*{box-sizing:border-box}*{box-sizing:border-box}.bcm-checkbox{outline:none;border:none;--bcm-checkbox-primary-color-default:var(--bcm-new-ds-color-blue-500);--bcm-checkbox-secondary-color-default:var(--bcm-new-ds-color-white);--bcm-checkbox-primary-color-hover:var(--bcm-new-ds-color-blue-600);--bcm-checkbox-secondary-color-hover:var(--bcm-new-ds-color-slate-50);--bcm-checkbox-primary-color-focus-visible:var(--bcm-new-ds-color-blue-800);--bcm-checkbox-secondary-color-focus-visible:var(--bcm-new-ds-color-slate-50);--bcm-checkbox-primary-color-active:var(--bcm-new-ds-color-blue-700);--bcm-checkbox-secondary-color-active:var(--bcm-new-ds-color-slate-50);--bcm-checkbox-primary-color-disabled:var(--bcm-new-ds-color-slate-300);--bcm-checkbox-secondary-color-disabled:var(--bcm-new-ds-color-slate-200);display:inline-flex;width:fit-content;flex-direction:column;margin-bottom:8px}.bcm-checkbox:focus,.bcm-checkbox:hover,.bcm-checkbox:active{outline:none;border:none}.bcm-checkbox *{box-sizing:border-box}.bcm-checkbox input[type=radio],.bcm-checkbox input[type=checkbox]{-webkit-appearance:none;appearance:none;background-color:#fff;margin:0;display:none}.bcm-checkbox__input{display:flex;flex-direction:row;align-items:flex-start;justify-content:flex-start;flex-wrap:nowrap;padding-top:4px}.bcm-checkbox.hidden{display:none}.bcm-checkbox :hover{cursor:pointer}.bcm-checkbox[disabled] :hover,.bcm-checkbox.disabled :hover{cursor:not-allowed}.bcm-checkbox .slot{font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;font-weight:500;color:var(--bcm-new-ds-color-slate-600)}.bcm-checkbox .slot:not(:empty){margin-left:8px;margin-right:8px}.bcm-checkbox-size-small .slot{font-size:12px;line-height:calc(12px + 8px);margin-top:-2.5px}.bcm-checkbox-size-small .bcm-checkbox__input{min-height:calc(24px - 4px)}.bcm-checkbox-size-small .bcm-checkbox__label-icon{width:14px;height:14px;min-width:14px;font-size:calc(10px - 2px)}.bcm-checkbox-size-medium .slot{font-size:calc(12px + 1px);line-height:calc(12px + 8px);margin-top:-1.5px}.bcm-checkbox-size-medium .bcm-checkbox__input{min-height:calc(32px - 4px)}.bcm-checkbox-size-medium .bcm-checkbox__label-icon{width:16px;height:16px;min-width:16px;font-size:10px}.bcm-checkbox-size-large .slot{font-size:16px;line-height:calc(16px + 8px);margin-top:-1.5px}.bcm-checkbox-size-large .bcm-checkbox__input{min-height:calc(32px - 4px)}.bcm-checkbox-size-large .bcm-checkbox__label-icon{width:18px;height:18px;min-width:18px;font-size:12px}.bcm-checkbox__label{display:flex;flex-direction:row;align-items:flex-start;justify-content:flex-start;flex-wrap:nowrap}.bcm-checkbox__label-icon{display:flex;flex-direction:column;align-items:center;justify-content:center;flex-wrap:nowrap;border-width:1px;border-style:solid;border-radius:2px}.bcm-checkbox__label-icon-indeterminate{position:relative}.bcm-checkbox__label-icon-indeterminate:after{content:\"\";display:block;position:absolute;width:70%;height:1.5px;background:var(--bcm-new-ds-color-white)}.bcm-checkbox__label-icon.bcm-radio__icon{width:16px;height:16px;box-sizing:border-box;border-radius:100px}.bcm-checkbox__label-icon.bcm-radio__icon .bcm-radio__icon-inner{width:10px;height:10px;border-radius:100px;background-color:var(--bcm-new-ds-color-white)}.bcm-checkbox .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-default);color:var(--bcm-checkbox-secondary-color-default);border-color:var(--bcm-new-ds-color-slate-300)}.bcm-checkbox .bcm-checkbox__label-icon-checked,.bcm-checkbox .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-default);border-color:var(--bcm-checkbox-primary-color-default)}.bcm-checkbox .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-default);background-color:var(--bcm-checkbox-secondary-color-default)}.bcm-checkbox .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-default)}.bcm-checkbox .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-default)}.bcm-checkbox:hover .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-hover);color:var(--bcm-checkbox-secondary-color-hover);border-color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-checked,.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-hover);border-color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-hover);background-color:var(--bcm-checkbox-secondary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:hover .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-hover)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-focus-visible);color:var(--bcm-checkbox-secondary-color-focus-visible);border-color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-checked,.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-focus-visible);border-color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-focus-visible);background-color:var(--bcm-checkbox-secondary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:focus-visible .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-focus-visible)}.bcm-checkbox:active .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-active);color:var(--bcm-checkbox-secondary-color-active);border-color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-checked,.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-active);border-color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-active);background-color:var(--bcm-checkbox-secondary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox:active .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-active)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon,.bcm-checkbox.disabled .bcm-checkbox__label-icon{background:var(--bcm-checkbox-secondary-color-disabled);color:var(--bcm-checkbox-secondary-color-disabled);border-color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-checked,.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate,.bcm-checkbox.disabled .bcm-checkbox__label-icon-checked,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-checkbox-primary-color-disabled);border-color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon,.bcm-checkbox.disabled .bcm-checkbox__label-icon-checked.bcm-radio__icon,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon{border-color:var(--bcm-checkbox-primary-color-disabled);background-color:var(--bcm-checkbox-secondary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox.disabled .bcm-checkbox__label-icon-checked.bcm-radio__icon .bcm-radio__icon-inner,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate.bcm-radio__icon .bcm-radio__icon-inner{background-color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[disabled] .bcm-checkbox__label-icon-indeterminate,.bcm-checkbox.disabled .bcm-checkbox__label-icon-indeterminate{color:var(--bcm-checkbox-primary-color-disabled)}.bcm-checkbox[no-margin] .bcm-checkbox__input{margin:0;min-height:0;padding:0}.bcm-list{font-family:\"Inter\", sans-serif;font-size:14px;line-height:calc(14px + 8px);font-weight:400;--width:256px;--height:256px;--max-height:inherit;--min-height:inherit;min-width:90px;display:flex;flex-direction:column;margin:0 0 8px 0}.bcm-list__listbox .bcm-list__container{height:var(--height);max-height:var(--max-height);min-height:var(--min-height)}.bcm-list.full-width{width:100%}.bcm-list__size-small .bcm-list__input{height:24px;font-size:12px;line-height:calc(12px + 8px)}.bcm-list__size-small .bcm-list__input .bcm-tag__content.dismissable{font-size:10px;line-height:calc(10px + 8px)}.bcm-list__size-medium .bcm-list__input{height:32px;font-size:14px;line-height:calc(14px + 8px)}.bcm-list__size-medium .bcm-list__input .bcm-tag__content.dismissable{font-size:12px;line-height:calc(12px + 8px)}.bcm-list__size-large .bcm-list__input{height:40px;font-size:16px;line-height:calc(16px + 8px)}.bcm-list__size-large .bcm-list__input .bcm-tag__content.dismissable{font-size:14px;line-height:calc(14px + 8px)}.bcm-list:hover{outline:none}.bcm-list:hover .bcm-list__input{border-color:var(--bcm-new-ds-color-blue-500);background-color:var(--bcm-new-ds-color-slate-50)}.bcm-list:focus-visible{outline:none}.bcm-list:focus-visible .bcm-list__input{border-color:var(--bcm-new-ds-color-blue-600);background-color:var(--bcm-new-ds-color-white)}.bcm-list:active{outline:none}.bcm-list:active .bcm-list__input{border-color:var(--bcm-new-ds-color-blue-600);box-shadow:0 1px 3px 0 rgba(17, 24, 38, 0.1)}.bcm-list__container{--width:256px;--height:256px;width:var(--width);height:var(--height);background-color:var(--bcm-new-ds-color-white);border:1px solid var(--bcm-new-ds-color-slate-300);border-radius:4px;box-sizing:border-box;padding-top:8px;display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;flex-wrap:nowrap;gap:4px}.bcm-list__container main{scroll-behavior:smooth;padding:0 8px;flex:1;overflow:auto;display:flex;flex-direction:column}.bcm-list__container-search{margin:0 8px}.bcm-list__container-search:after{margin:4px 0}.bcm-list__container-no-data{flex:1;display:flex;justify-content:stretch;align-items:stretch;padding-bottom:4px}.bcm-list__container.error{border-color:var(--bcm-color-red-6)}.bcm-list__container.full-width{width:100%}.bcm-list__container.bcm-list__type-linked-component,.bcm-list__container.bcm-list__type-select,.bcm-list__container.bcm-list__type-autocomplete{opacity:0;visibility:hidden;position:absolute;top:0;left:0;height:0;width:0;transform:translateY(10%);z-index:10800;transition:visibility 0s linear 400ms, opacity 100ms, transform 200ms}.bcm-list__container.bcm-list__type-linked-component.bcm-list--top,.bcm-list__container.bcm-list__type-select.bcm-list--top,.bcm-list__container.bcm-list__type-autocomplete.bcm-list--top{transform:translateY(-10%)}.bcm-list__container.bcm-list__type-linked-component.is-open,.bcm-list__container.bcm-list__type-select.is-open,.bcm-list__container.bcm-list__type-autocomplete.is-open{opacity:1;transform:translateY(0);visibility:visible;transition:visibility 0s linear 0s, opacity 100ms, transform 100ms}.bcm-list__container.bcm-list__type-linked-component{margin-top:2px}.bcm-list__label{line-height:1}.bcm-list__input{display:flex;align-items:center;justify-content:space-between;box-sizing:border-box;border:1px solid var(--bcm-new-ds-color-slate-300);border-radius:4px;color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-white);user-select:none;cursor:pointer;padding:0 8px;height:32px;overflow:hidden;position:relative;transition:background-color 100ms, border-color 100ms}.bcm-list__input-spinner{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;justify-content:center;align-items:center;background-color:var(--bcm-color-grey-1);opacity:0;visibility:hidden;transition:opacity 0.2s ease-in-out;z-index:-1}.bcm-list__input-spinner.is-open{opacity:1;visibility:visible;z-index:1}.bcm-list__input-container{flex:1;display:block;overflow:hidden}.bcm-list__input-container.value-empty{color:var(--bcm-color-grey-6)}.bcm-list__input-container.type-single,.bcm-list__input-container.value-empty{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.bcm-list__input-placeholder{color:var(--bcm-color-grey-6)}.bcm-list__input-tag-container{height:100%;width:100%;display:flex;align-items:center;justify-content:flex-start;flex-wrap:nowrap;grid-gap:2px;line-height:1}.bcm-list__input-buttons{display:flex;align-items:center;justify-content:flex-end;grid-gap:4px}.bcm-list__input-buttons-button{display:flex;align-items:center;justify-content:center;box-sizing:border-box;padding:0 4px 0 4px;font-size:16px;color:var(--bcm-new-ds-color-slate-500)}.bcm-list__input-buttons-button.caret-is{transform:rotate(360deg);transition:transform 0.2s ease-in-out}.bcm-list__input-buttons-button.caret-is-open{transform:rotate(180deg)}.bcm-list__input-buttons:not(.disabled) .bcm-list__input-buttons-button:hover{cursor:pointer;color:var(--bcm-new-ds-color-slate-600)}.bcm-list__input-autocomplete{position:relative;padding-right:0}.bcm-list__input-autocomplete .bcm-list-input-selected-text{background-color:#ffffff;display:flex;align-items:center;justify-content:flex-start;width:calc(100% - 24px);height:100%;padding:0 calc(8px + 4px);position:absolute;top:0;left:0}.bcm-list__input-autocomplete .bcm-list__input-container{height:100%;display:flex;flex-direction:row}.bcm-list__input-autocomplete .bcm-list__input-container .bcm-list__input-tag-container{width:auto}.bcm-list__input-autocomplete .bcm-input,.bcm-list__input-autocomplete .bcm-list__autocomplete{height:100%;min-width:70px;width:100%}.bcm-list__input-autocomplete .bcm-input__container,.bcm-list__input-autocomplete .bcm-list__autocomplete__container{height:100%;border:none;padding:0;width:100%}.bcm-list__input-autocomplete .bcm-input__container:not(.disabled).focused,.bcm-list__input-autocomplete .bcm-input__container:not(.disabled):hover,.bcm-list__input-autocomplete .bcm-list__autocomplete__container:not(.disabled).focused,.bcm-list__input-autocomplete .bcm-list__autocomplete__container:not(.disabled):hover{border:none;box-shadow:none}.bcm-list__autocomplete{width:100%;position:relative}.bcm-list.full-width .bcm-list__container,.bcm-list.full-width .bcm-list__input{width:100%}.bcm-list.error .bcm-list__input{border-color:var(--bcm-color-red-6)}.bcm-list.disabled .bcm-list__container,.bcm-list.disabled .bcm-list__input{color:var(--bcm-new-ds-color-slate-300);background-color:var(--bcm-new-ds-color-slate-50);cursor:not-allowed}.bcm-list.disabled .bcm-tag__content.dismissable .close-button{cursor:default}.bcm-list:not(.disabled) .bcm-list__input .bcm-tag__content.checked .close-button bcm-icon{color:var(--bcm-new-ds-color-slate-100)}.bcm-list:not(.disabled) .bcm-list__input .bcm-tag__content.checked .close-button:hover bcm-icon{color:var(--bcm-new-ds-color-slate-200)}.bcm-list:not(.disabled) .bcm-list__input:hover{border-color:var(--bcm-new-ds-color-blue-500)}.bcm-list:not(.disabled) .bcm-list__input:hover .bcm-tag__content.dismissable:not(.checked){background-color:var(--bcm-new-ds-color-slate-200);border-color:var(--bcm-new-ds-color-slate-200)}.bcm-list:not(.disabled) .bcm-list__input:focus-visible{border-color:var(--bcm-new-ds-color-blue-500);box-shadow:0 1px 3px 0 rgba(17, 24, 38, 0.1)}.bcm-list:not(.disabled) .bcm-list__input:active{border-color:var(--bcm-new-ds-color-blue-500)}.bcm-list__item{padding:2px 0}.bcm-list__item.disabled{user-select:none}.bcm-list__item:focus{outline:none}.bcm-list__item:focus-visible>.bcm-list__item-content{background-color:var(--bcm-new-ds-color-slate-300)}.bcm-list__item:focus-visible>.bcm-list__item-content:not(.disabled){color:var(--bcm-new-ds-color-slate-600)}.bcm-list__item-content{display:flex;flex-direction:row;align-items:stretch;justify-content:flex-start;flex-wrap:nowrap;cursor:pointer;border-radius:4px;padding:0;padding-left:4px;color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-slate-50);transition:background-color 0.2s ease}.bcm-list__item-content.disabled{color:var(--bcm-new-ds-color-slate-300);background-color:var(--bcm-new-ds-color-slate-50);user-select:none;cursor:not-allowed}.bcm-list__item-content.selected{color:var(--bcm-new-ds-color-white);background-color:var(--bcm-new-ds-color-blue-500)}.bcm-list__item-content.selected:hover:not(.disabled){color:var(--bcm-new-ds-color-white);background-color:var(--bcm-new-ds-color-blue-600)}.bcm-list__item-content:hover:not(.disabled){color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-slate-100)}.bcm-list__item-content:active:not(.disabled){color:var(--bcm-new-ds-color-slate-600);background-color:var(--bcm-new-ds-color-slate-200)}.bcm-list__item-content-collapse-icon{width:16px;padding:0 8px;display:flex;align-items:center;justify-content:center;font-size:16px}.bcm-list__item-content-collapse-icon.child{cursor:pointer}.bcm-list__item-content-text{user-select:none;padding:8px;width:100%;display:flex;flex-direction:row;align-items:center;justify-content:flex-start}.bcm-list__item-content-text.treeview{padding:8px 0}.bcm-list__item-content-text-checkbox{display:flex;flex-direction:row;align-items:center;justify-content:center;flex-wrap:nowrap;margin-right:8px}.bcm-list__item-content-text-checkbox .bcm-checkbox{margin:0}.bcm-list__item-content-text-inner{width:100%}.bcm-list__item-content-text mark{padding:0;margin:0;font-size:inherit;color:var(--bcm-color-grey-8);background-color:var(--bcm-color-yellow-4)}.bcm-list__item-childs{padding-left:16px}.bcm-list__item-small{padding:2px 0 2px 8px;font-size:10px;line-height:calc(10px + 8px)}.bcm-list__item-small .bcm-list__item-content-text{padding:3px 4px}.bcm-list__item-medium{font-size:12px;line-height:calc(12px + 8px)}.bcm-list__item-medium .bcm-list__item-content-text{padding:6px 4px}.bcm-list__item-large{font-size:14px;line-height:calc(14px + 8px)}.bcm-list__item-large .bcm-list__item-content-text{padding:9px 4px}.bcm-list__item--readonly:focus>.bcm-list__item-content:not(.disabled),.bcm-list__item--readonly.focused>.bcm-list__item-content:not(.disabled){color:var(--bcm-color-grey-7)}.bcm-list__item--readonly>.bcm-list__item-content{color:var(--bcm-color-grey-7)}.bcm-list__item--readonly>.bcm-list__item-content:hover,.bcm-list__item--readonly>.bcm-list__item-content:focus{color:var(--bcm-color-grey-7)}.bcm-list__item--group{border-radius:4px}.bcm-list__item--group:focus>.bcm-list__item-content:not(.disabled){background-color:var(--bcm-new-ds-color-slate-50);color:var(--bcm-new-ds-color-slate-600)}.bcm-list__item--group>.bcm-list__item-content{background-color:var(--bcm-new-ds-color-slate-50);color:var(--bcm-new-ds-color-slate-600);border-radius:4px 4px 0 0;cursor:default;font-size:14px;line-height:calc(14px + 8px);font-weight:500;position:sticky;top:0}.bcm-list__item--group>.bcm-list__item-content>.bcm-list__item-content-text{padding:4px 8px 4px 16px}.bcm-list__item--group>.bcm-list__item-content:hover,.bcm-list__item--group>.bcm-list__item-content:focus{color:var(--bcm-new-ds-color-slate-800);background-color:var(--bcm-new-ds-color-slate-50)}.bcm-list__item--group>.bcm-list__item-content-unclickable:hover{color:var(--bcm-new-ds-color-slate-700);background-color:var(--bcm-new-ds-color-slate-50)}.bcm-list__item--group>.bcm-list__item-childs{background-color:var(--bcm-new-ds-color-slate-50);color:var(--bcm-new-ds-color-slate-600);padding-bottom:8px;border-radius:0 0 4px 4px;padding-left:8px}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content{background-color:var(--bcm-new-ds-color-white);color:var(--bcm-new-ds-color-slate-600)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content:hover{background-color:var(--bcm-new-ds-color-slate-100)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content:active{background-color:var(--bcm-new-ds-color-slate-200)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content:focus-visible{background-color:var(--bcm-new-ds-color-slate-300)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content.selected{background-color:var(--bcm-new-ds-color-blue-500);color:var(--bcm-new-ds-color-white)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content.selected:hover{background-color:var(--bcm-new-ds-color-blue-600)}.bcm-list__item--group>.bcm-list__item-childs .bcm-list__item-content.selected:active{background-color:var(--bcm-new-ds-color-blue-700)}.bcm-list__linked{display:none}.bcm-list .bcm-tag--other .value{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.bcm-info-footer{text-align:right;padding:4px 8px;background-color:var(--bcm-new-ds-color-slate-100);color:var(--bcm-new-ds-color-slate-600);border-radius:0 0 4px 4px}";
|
|
847
844
|
|
|
848
845
|
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
849
846
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
@@ -886,6 +883,7 @@ const BcmList = class {
|
|
|
886
883
|
this.maxHeight = "500px";
|
|
887
884
|
this.minHeight = "150px";
|
|
888
885
|
this.width = "256px";
|
|
886
|
+
this.tooltip = undefined;
|
|
889
887
|
this.infoFooter = false;
|
|
890
888
|
this.variableText = "item";
|
|
891
889
|
this.template = undefined;
|
|
@@ -893,6 +891,7 @@ const BcmList = class {
|
|
|
893
891
|
this.keyControl = false;
|
|
894
892
|
this.checkAll = true;
|
|
895
893
|
this.stopDeepClean = false;
|
|
894
|
+
this.openIntersecting = false;
|
|
896
895
|
this.linkedComponent = undefined;
|
|
897
896
|
this.isOpen = false;
|
|
898
897
|
this.calculatedViewport = false;
|
|
@@ -935,7 +934,11 @@ const BcmList = class {
|
|
|
935
934
|
indeterminate: "uncheck",
|
|
936
935
|
};
|
|
937
936
|
this.placement = Bcm$1.Placement["bottom-start"];
|
|
937
|
+
this.disableChangeEvent = false;
|
|
938
938
|
this.data = [];
|
|
939
|
+
window.addEventListener("scroll", this.handleWheel.bind(this), true);
|
|
940
|
+
window.addEventListener("wheel", this.handleWheel.bind(this), true);
|
|
941
|
+
window.addEventListener("resize", this.handleResize.bind(this), true);
|
|
939
942
|
}
|
|
940
943
|
connectedCallback() {
|
|
941
944
|
if (this.height != "256px") {
|
|
@@ -1012,12 +1015,12 @@ const BcmList = class {
|
|
|
1012
1015
|
if (this.checkboxes) {
|
|
1013
1016
|
if (!Validators.compareTwoArrayIsSame(newVal, oldVal)) {
|
|
1014
1017
|
this.bcmChecklist.emit(this.value);
|
|
1015
|
-
this.change.emit(this.value);
|
|
1018
|
+
!this.disableChangeEvent && this.change.emit(this.value);
|
|
1016
1019
|
}
|
|
1017
1020
|
}
|
|
1018
1021
|
else {
|
|
1019
1022
|
if ((newVal === null || newVal === void 0 ? void 0 : newVal.id) != (oldVal === null || oldVal === void 0 ? void 0 : oldVal.id)) {
|
|
1020
|
-
this.change.emit(this.value);
|
|
1023
|
+
!this.disableChangeEvent && this.change.emit(this.value);
|
|
1021
1024
|
}
|
|
1022
1025
|
}
|
|
1023
1026
|
}
|
|
@@ -1577,14 +1580,14 @@ const BcmList = class {
|
|
|
1577
1580
|
});
|
|
1578
1581
|
const bcmListInput = classnames("bcm-list__input");
|
|
1579
1582
|
const openedType = this.type == "select" || this.type == "autocomplete" || this.linkedComponent;
|
|
1580
|
-
return (h
|
|
1583
|
+
return (h(Host, { class: hostClasses, tabindex: "0", style: {
|
|
1581
1584
|
"--width": fullWidth ? "100%" : this.width,
|
|
1582
1585
|
"--height": openedType ? "100%" : this.height,
|
|
1583
1586
|
"--max-height": openedType ? "inherit" : this.maxHeight,
|
|
1584
1587
|
"--min-height": openedType ? "inherit" : this.minHeight,
|
|
1585
|
-
} }, h
|
|
1588
|
+
} }, h("div", { id: `bcm-list-label-${this._id}`, class: "bcm-list__label" }, label && (h("div", null, h("bcm-label", { tooltip: this.tooltip, size: this.size, type: this.captionType, value: label, required: required, htmlFor: this._id })))), this.type == "select" && (h("div", { id: `bcm-list-input-${this._id}`, class: bcmListInput }, h("span", { class: classnames("bcm-list__input-container", { "type-single": !checkboxes, "value-empty": !this.value }) }, this.checkboxes ? (this.value && this.value.length > 0 ? (h("bcm-rc-overflow", { data: this.tagData, maxCount: this.tagCount })) : (h("span", { class: "bcm-list__input-placeholder" }, this.placeholder))) : this.value ? (this.inputText) : (h("span", { class: "bcm-list__input-placeholder" }, this.placeholder))), h("span", { class: classnames("bcm-list__input-buttons", {
|
|
1586
1589
|
disabled: disabled,
|
|
1587
|
-
}) }, this.clearable && this.value && (h
|
|
1590
|
+
}) }, this.clearable && this.value && (h("div", { class: "bcm-list__input-buttons-button" }, h("bcm-icon", { icon: "fal fa-times", onClick: e => !disabled && this.setClear(e) }))), h("div", { class: `bcm-list__input-buttons-button caret-is ${this.isOpen && this.calculatedViewport && "caret-is-open"}` }, h("bcm-icon", { icon: `far fa-angle-down` }))))), this.type === "autocomplete" && (h("div", { id: `bcm-list-input-${this._id}`, class: classnames(bcmListInput, { "bcm-list__input-autocomplete": this.type == "autocomplete" }) }, h("span", { class: "bcm-list__input-container", id: `bcm-list-input-tag-container-${this._id}` }, this.checkboxes && h("span", { class: "bcm-list__input-tag-container", id: `bcm-list-input-tag-container-${this._id}-autocomplete` }), h("bcm-search", { id: `bcm-list-input-tag-container-${this._id}-autocomplete-input`, class: "bcm-list__autocomplete", data: this.data, clearable: true, "full-width": true, "no-caption": true, placeholder: this.placeholder })))), h(ListTemplate, { highlight: this.highlightText, searchable: this.type == "autocomplete" ? false : searchable, bcmListContainer: bcmListContainer, checkboxes: checkboxes, treeview: treeview, infoFooter: this.infoFooter, value: this.value, totalData: this.totalData, searchFound: this.searchFound, variableText: this.variableText, searchPlaceholder: this.searchPlaceholder, minSearchLength: this.minSearchLength, searchIsOnlyChilds: this.searchIsOnlyChilds, _id: this._id, checkAll: this.checkAll, data: this.getItems(), width: this.width, height: this.height, size: this.size, selectAllItem: this.selectAllItem, onScrollEvent: e => this.dataScrollEvent(e), items: this.getLimitedItems(this.searchGetParents), selectedItem: itemId => this.selectedItem(itemId), checkedItem: itemId => this.checkedItem(itemId), openGroup: parentId => this.openGroup(parentId), focusItem: itemId => this.focusItem(itemId), emptyText: this.emptyText, emptyIcon: this.emptyIcon }), h(CaptionTemplate, { noCaption: this.noCaption, captionType: this.captionType, captionError: this.captionError, caption: this.caption })));
|
|
1588
1591
|
}
|
|
1589
1592
|
get el() { return getElement(this); }
|
|
1590
1593
|
static get watchers() { return {
|
|
@@ -1603,8 +1606,8 @@ __decorate([
|
|
|
1603
1606
|
], BcmList.prototype, "dataChanged", null);
|
|
1604
1607
|
BcmList.style = listCss;
|
|
1605
1608
|
|
|
1606
|
-
function _extends
|
|
1607
|
-
_extends
|
|
1609
|
+
function _extends() {
|
|
1610
|
+
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
1608
1611
|
for (var i = 1; i < arguments.length; i++) {
|
|
1609
1612
|
var source = arguments[i];
|
|
1610
1613
|
for (var key in source) {
|
|
@@ -1615,37 +1618,37 @@ function _extends$1() {
|
|
|
1615
1618
|
}
|
|
1616
1619
|
return target;
|
|
1617
1620
|
};
|
|
1618
|
-
return _extends
|
|
1621
|
+
return _extends.apply(this, arguments);
|
|
1619
1622
|
}
|
|
1620
1623
|
|
|
1621
|
-
function _typeof
|
|
1624
|
+
function _typeof(obj) {
|
|
1622
1625
|
"@babel/helpers - typeof";
|
|
1623
1626
|
|
|
1624
|
-
return _typeof
|
|
1627
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
1625
1628
|
return typeof obj;
|
|
1626
1629
|
} : function (obj) {
|
|
1627
1630
|
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
1628
|
-
}, _typeof
|
|
1631
|
+
}, _typeof(obj);
|
|
1629
1632
|
}
|
|
1630
1633
|
|
|
1631
|
-
function _toPrimitive
|
|
1632
|
-
if (_typeof
|
|
1634
|
+
function _toPrimitive(input, hint) {
|
|
1635
|
+
if (_typeof(input) !== "object" || input === null) return input;
|
|
1633
1636
|
var prim = input[Symbol.toPrimitive];
|
|
1634
1637
|
if (prim !== undefined) {
|
|
1635
1638
|
var res = prim.call(input, hint || "default");
|
|
1636
|
-
if (_typeof
|
|
1639
|
+
if (_typeof(res) !== "object") return res;
|
|
1637
1640
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
1638
1641
|
}
|
|
1639
1642
|
return (hint === "string" ? String : Number)(input);
|
|
1640
1643
|
}
|
|
1641
1644
|
|
|
1642
|
-
function _toPropertyKey
|
|
1643
|
-
var key = _toPrimitive
|
|
1644
|
-
return _typeof
|
|
1645
|
+
function _toPropertyKey(arg) {
|
|
1646
|
+
var key = _toPrimitive(arg, "string");
|
|
1647
|
+
return _typeof(key) === "symbol" ? key : String(key);
|
|
1645
1648
|
}
|
|
1646
1649
|
|
|
1647
|
-
function _defineProperty
|
|
1648
|
-
key = _toPropertyKey
|
|
1650
|
+
function _defineProperty(obj, key, value) {
|
|
1651
|
+
key = _toPropertyKey(key);
|
|
1649
1652
|
if (key in obj) {
|
|
1650
1653
|
Object.defineProperty(obj, key, {
|
|
1651
1654
|
value: value,
|
|
@@ -1659,7 +1662,7 @@ function _defineProperty$1(obj, key, value) {
|
|
|
1659
1662
|
return obj;
|
|
1660
1663
|
}
|
|
1661
1664
|
|
|
1662
|
-
function ownKeys
|
|
1665
|
+
function ownKeys(object, enumerableOnly) {
|
|
1663
1666
|
var keys = Object.keys(object);
|
|
1664
1667
|
if (Object.getOwnPropertySymbols) {
|
|
1665
1668
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -1669,12 +1672,12 @@ function ownKeys$1(object, enumerableOnly) {
|
|
|
1669
1672
|
}
|
|
1670
1673
|
return keys;
|
|
1671
1674
|
}
|
|
1672
|
-
function _objectSpread2
|
|
1675
|
+
function _objectSpread2(target) {
|
|
1673
1676
|
for (var i = 1; i < arguments.length; i++) {
|
|
1674
1677
|
var source = null != arguments[i] ? arguments[i] : {};
|
|
1675
|
-
i % 2 ? ownKeys
|
|
1676
|
-
_defineProperty
|
|
1677
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys
|
|
1678
|
+
i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
|
|
1679
|
+
_defineProperty(target, key, source[key]);
|
|
1680
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {
|
|
1678
1681
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
1679
1682
|
});
|
|
1680
1683
|
}
|
|
@@ -1765,1469 +1768,6 @@ function _objectWithoutProperties(source, excluded) {
|
|
|
1765
1768
|
return target;
|
|
1766
1769
|
}
|
|
1767
1770
|
|
|
1768
|
-
function _extends() {
|
|
1769
|
-
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
1770
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
1771
|
-
var source = arguments[i];
|
|
1772
|
-
for (var key in source) {
|
|
1773
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
1774
|
-
target[key] = source[key];
|
|
1775
|
-
}
|
|
1776
|
-
}
|
|
1777
|
-
}
|
|
1778
|
-
return target;
|
|
1779
|
-
};
|
|
1780
|
-
return _extends.apply(this, arguments);
|
|
1781
|
-
}
|
|
1782
|
-
|
|
1783
|
-
/** @license React v16.13.1
|
|
1784
|
-
* react-is.production.min.js
|
|
1785
|
-
*
|
|
1786
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
1787
|
-
*
|
|
1788
|
-
* This source code is licensed under the MIT license found in the
|
|
1789
|
-
* LICENSE file in the root directory of this source tree.
|
|
1790
|
-
*/
|
|
1791
|
-
var b="function"===typeof Symbol&&Symbol.for,c=b?Symbol.for("react.element"):60103,d=b?Symbol.for("react.portal"):60106,e=b?Symbol.for("react.fragment"):60107,f=b?Symbol.for("react.strict_mode"):60108,g=b?Symbol.for("react.profiler"):60114,h=b?Symbol.for("react.provider"):60109,k=b?Symbol.for("react.context"):60110,l=b?Symbol.for("react.async_mode"):60111,m=b?Symbol.for("react.concurrent_mode"):60111,n=b?Symbol.for("react.forward_ref"):60112,p=b?Symbol.for("react.suspense"):60113,q=b?
|
|
1792
|
-
Symbol.for("react.suspense_list"):60120,r=b?Symbol.for("react.memo"):60115,t=b?Symbol.for("react.lazy"):60116,v=b?Symbol.for("react.block"):60121,w=b?Symbol.for("react.fundamental"):60117,x=b?Symbol.for("react.responder"):60118,y=b?Symbol.for("react.scope"):60119;
|
|
1793
|
-
function z(a){if("object"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}var AsyncMode=l;var ConcurrentMode=m;var ContextConsumer=k;var ContextProvider=h;var Element$1=c;var ForwardRef=n;var Fragment=e;var Lazy=t;var Memo=r;var Portal=d;
|
|
1794
|
-
var Profiler=g;var StrictMode=f;var Suspense=p;var isAsyncMode=function(a){return A(a)||z(a)===l};var isConcurrentMode=A;var isContextConsumer=function(a){return z(a)===k};var isContextProvider=function(a){return z(a)===h};var isElement=function(a){return "object"===typeof a&&null!==a&&a.$$typeof===c};var isForwardRef=function(a){return z(a)===n};var isFragment=function(a){return z(a)===e};var isLazy=function(a){return z(a)===t};
|
|
1795
|
-
var isMemo=function(a){return z(a)===r};var isPortal=function(a){return z(a)===d};var isProfiler=function(a){return z(a)===g};var isStrictMode=function(a){return z(a)===f};var isSuspense=function(a){return z(a)===p};
|
|
1796
|
-
var isValidElementType=function(a){return "string"===typeof a||"function"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||"object"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};var typeOf=z;
|
|
1797
|
-
|
|
1798
|
-
var reactIs_production_min = {
|
|
1799
|
-
AsyncMode: AsyncMode,
|
|
1800
|
-
ConcurrentMode: ConcurrentMode,
|
|
1801
|
-
ContextConsumer: ContextConsumer,
|
|
1802
|
-
ContextProvider: ContextProvider,
|
|
1803
|
-
Element: Element$1,
|
|
1804
|
-
ForwardRef: ForwardRef,
|
|
1805
|
-
Fragment: Fragment,
|
|
1806
|
-
Lazy: Lazy,
|
|
1807
|
-
Memo: Memo,
|
|
1808
|
-
Portal: Portal,
|
|
1809
|
-
Profiler: Profiler,
|
|
1810
|
-
StrictMode: StrictMode,
|
|
1811
|
-
Suspense: Suspense,
|
|
1812
|
-
isAsyncMode: isAsyncMode,
|
|
1813
|
-
isConcurrentMode: isConcurrentMode,
|
|
1814
|
-
isContextConsumer: isContextConsumer,
|
|
1815
|
-
isContextProvider: isContextProvider,
|
|
1816
|
-
isElement: isElement,
|
|
1817
|
-
isForwardRef: isForwardRef,
|
|
1818
|
-
isFragment: isFragment,
|
|
1819
|
-
isLazy: isLazy,
|
|
1820
|
-
isMemo: isMemo,
|
|
1821
|
-
isPortal: isPortal,
|
|
1822
|
-
isProfiler: isProfiler,
|
|
1823
|
-
isStrictMode: isStrictMode,
|
|
1824
|
-
isSuspense: isSuspense,
|
|
1825
|
-
isValidElementType: isValidElementType,
|
|
1826
|
-
typeOf: typeOf
|
|
1827
|
-
};
|
|
1828
|
-
|
|
1829
|
-
createCommonjsModule(function (module, exports) {
|
|
1830
|
-
});
|
|
1831
|
-
|
|
1832
|
-
var reactIs = createCommonjsModule(function (module) {
|
|
1833
|
-
|
|
1834
|
-
{
|
|
1835
|
-
module.exports = reactIs_production_min;
|
|
1836
|
-
}
|
|
1837
|
-
});
|
|
1838
|
-
|
|
1839
|
-
function toArray(children) {
|
|
1840
|
-
var option = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
1841
|
-
var ret = [];
|
|
1842
|
-
react.Children.forEach(children, function (child) {
|
|
1843
|
-
if ((child === undefined || child === null) && !option.keepEmpty) {
|
|
1844
|
-
return;
|
|
1845
|
-
}
|
|
1846
|
-
if (Array.isArray(child)) {
|
|
1847
|
-
ret = ret.concat(toArray(child));
|
|
1848
|
-
} else if (reactIs.isFragment(child) && child.props) {
|
|
1849
|
-
ret = ret.concat(toArray(child.props.children, option));
|
|
1850
|
-
} else {
|
|
1851
|
-
ret.push(child);
|
|
1852
|
-
}
|
|
1853
|
-
});
|
|
1854
|
-
return ret;
|
|
1855
|
-
}
|
|
1856
|
-
|
|
1857
|
-
function _typeof$1(obj) {
|
|
1858
|
-
"@babel/helpers - typeof";
|
|
1859
|
-
|
|
1860
|
-
return _typeof$1 = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
1861
|
-
return typeof obj;
|
|
1862
|
-
} : function (obj) {
|
|
1863
|
-
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
1864
|
-
}, _typeof$1(obj);
|
|
1865
|
-
}
|
|
1866
|
-
|
|
1867
|
-
function _toPrimitive(input, hint) {
|
|
1868
|
-
if (_typeof$1(input) !== "object" || input === null) return input;
|
|
1869
|
-
var prim = input[Symbol.toPrimitive];
|
|
1870
|
-
if (prim !== undefined) {
|
|
1871
|
-
var res = prim.call(input, hint || "default");
|
|
1872
|
-
if (_typeof$1(res) !== "object") return res;
|
|
1873
|
-
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
1874
|
-
}
|
|
1875
|
-
return (hint === "string" ? String : Number)(input);
|
|
1876
|
-
}
|
|
1877
|
-
|
|
1878
|
-
function _toPropertyKey(arg) {
|
|
1879
|
-
var key = _toPrimitive(arg, "string");
|
|
1880
|
-
return _typeof$1(key) === "symbol" ? key : String(key);
|
|
1881
|
-
}
|
|
1882
|
-
|
|
1883
|
-
function _defineProperty(obj, key, value) {
|
|
1884
|
-
key = _toPropertyKey(key);
|
|
1885
|
-
if (key in obj) {
|
|
1886
|
-
Object.defineProperty(obj, key, {
|
|
1887
|
-
value: value,
|
|
1888
|
-
enumerable: true,
|
|
1889
|
-
configurable: true,
|
|
1890
|
-
writable: true
|
|
1891
|
-
});
|
|
1892
|
-
} else {
|
|
1893
|
-
obj[key] = value;
|
|
1894
|
-
}
|
|
1895
|
-
return obj;
|
|
1896
|
-
}
|
|
1897
|
-
|
|
1898
|
-
function ownKeys(object, enumerableOnly) {
|
|
1899
|
-
var keys = Object.keys(object);
|
|
1900
|
-
if (Object.getOwnPropertySymbols) {
|
|
1901
|
-
var symbols = Object.getOwnPropertySymbols(object);
|
|
1902
|
-
enumerableOnly && (symbols = symbols.filter(function (sym) {
|
|
1903
|
-
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
1904
|
-
})), keys.push.apply(keys, symbols);
|
|
1905
|
-
}
|
|
1906
|
-
return keys;
|
|
1907
|
-
}
|
|
1908
|
-
function _objectSpread2(target) {
|
|
1909
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
1910
|
-
var source = null != arguments[i] ? arguments[i] : {};
|
|
1911
|
-
i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
|
|
1912
|
-
_defineProperty(target, key, source[key]);
|
|
1913
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {
|
|
1914
|
-
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
1915
|
-
});
|
|
1916
|
-
}
|
|
1917
|
-
return target;
|
|
1918
|
-
}
|
|
1919
|
-
|
|
1920
|
-
function _typeof(obj) {
|
|
1921
|
-
"@babel/helpers - typeof";
|
|
1922
|
-
|
|
1923
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
1924
|
-
return typeof obj;
|
|
1925
|
-
} : function (obj) {
|
|
1926
|
-
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
1927
|
-
}, _typeof(obj);
|
|
1928
|
-
}
|
|
1929
|
-
|
|
1930
|
-
function fillRef(ref, node) {
|
|
1931
|
-
if (typeof ref === 'function') {
|
|
1932
|
-
ref(node);
|
|
1933
|
-
} else if (_typeof(ref) === 'object' && ref && 'current' in ref) {
|
|
1934
|
-
ref.current = node;
|
|
1935
|
-
}
|
|
1936
|
-
}
|
|
1937
|
-
|
|
1938
|
-
/**
|
|
1939
|
-
* Merge refs into one ref function to support ref passing.
|
|
1940
|
-
*/
|
|
1941
|
-
function composeRef() {
|
|
1942
|
-
for (var _len = arguments.length, refs = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
1943
|
-
refs[_key] = arguments[_key];
|
|
1944
|
-
}
|
|
1945
|
-
var refList = refs.filter(function (ref) {
|
|
1946
|
-
return ref;
|
|
1947
|
-
});
|
|
1948
|
-
if (refList.length <= 1) {
|
|
1949
|
-
return refList[0];
|
|
1950
|
-
}
|
|
1951
|
-
return function (node) {
|
|
1952
|
-
refs.forEach(function (ref) {
|
|
1953
|
-
fillRef(ref, node);
|
|
1954
|
-
});
|
|
1955
|
-
};
|
|
1956
|
-
}
|
|
1957
|
-
function supportRef(nodeOrComponent) {
|
|
1958
|
-
var _type$prototype, _nodeOrComponent$prot;
|
|
1959
|
-
var type = reactIs.isMemo(nodeOrComponent) ? nodeOrComponent.type.type : nodeOrComponent.type;
|
|
1960
|
-
|
|
1961
|
-
// Function component node
|
|
1962
|
-
if (typeof type === 'function' && !((_type$prototype = type.prototype) !== null && _type$prototype !== void 0 && _type$prototype.render)) {
|
|
1963
|
-
return false;
|
|
1964
|
-
}
|
|
1965
|
-
|
|
1966
|
-
// Class component
|
|
1967
|
-
if (typeof nodeOrComponent === 'function' && !((_nodeOrComponent$prot = nodeOrComponent.prototype) !== null && _nodeOrComponent$prot !== void 0 && _nodeOrComponent$prot.render)) {
|
|
1968
|
-
return false;
|
|
1969
|
-
}
|
|
1970
|
-
return true;
|
|
1971
|
-
}
|
|
1972
|
-
/* eslint-enable */
|
|
1973
|
-
|
|
1974
|
-
function isDOM(node) {
|
|
1975
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/Element
|
|
1976
|
-
// Since XULElement is also subclass of Element, we only need HTMLElement and SVGElement
|
|
1977
|
-
return node instanceof HTMLElement || node instanceof SVGElement;
|
|
1978
|
-
}
|
|
1979
|
-
|
|
1980
|
-
/**
|
|
1981
|
-
* Return if a node is a DOM node. Else will return by `findDOMNode`
|
|
1982
|
-
*/
|
|
1983
|
-
function findDOMNode(node) {
|
|
1984
|
-
if (isDOM(node)) {
|
|
1985
|
-
return node;
|
|
1986
|
-
}
|
|
1987
|
-
if (node instanceof react.Component) {
|
|
1988
|
-
return reactDom.findDOMNode(node);
|
|
1989
|
-
}
|
|
1990
|
-
return null;
|
|
1991
|
-
}
|
|
1992
|
-
|
|
1993
|
-
/**
|
|
1994
|
-
* A collection of shims that provide minimal functionality of the ES6 collections.
|
|
1995
|
-
*
|
|
1996
|
-
* These implementations are not meant to be used outside of the ResizeObserver
|
|
1997
|
-
* modules as they cover only a limited range of use cases.
|
|
1998
|
-
*/
|
|
1999
|
-
/* eslint-disable require-jsdoc, valid-jsdoc */
|
|
2000
|
-
var MapShim = (function () {
|
|
2001
|
-
if (typeof Map !== 'undefined') {
|
|
2002
|
-
return Map;
|
|
2003
|
-
}
|
|
2004
|
-
/**
|
|
2005
|
-
* Returns index in provided array that matches the specified key.
|
|
2006
|
-
*
|
|
2007
|
-
* @param {Array<Array>} arr
|
|
2008
|
-
* @param {*} key
|
|
2009
|
-
* @returns {number}
|
|
2010
|
-
*/
|
|
2011
|
-
function getIndex(arr, key) {
|
|
2012
|
-
var result = -1;
|
|
2013
|
-
arr.some(function (entry, index) {
|
|
2014
|
-
if (entry[0] === key) {
|
|
2015
|
-
result = index;
|
|
2016
|
-
return true;
|
|
2017
|
-
}
|
|
2018
|
-
return false;
|
|
2019
|
-
});
|
|
2020
|
-
return result;
|
|
2021
|
-
}
|
|
2022
|
-
return /** @class */ (function () {
|
|
2023
|
-
function class_1() {
|
|
2024
|
-
this.__entries__ = [];
|
|
2025
|
-
}
|
|
2026
|
-
Object.defineProperty(class_1.prototype, "size", {
|
|
2027
|
-
/**
|
|
2028
|
-
* @returns {boolean}
|
|
2029
|
-
*/
|
|
2030
|
-
get: function () {
|
|
2031
|
-
return this.__entries__.length;
|
|
2032
|
-
},
|
|
2033
|
-
enumerable: true,
|
|
2034
|
-
configurable: true
|
|
2035
|
-
});
|
|
2036
|
-
/**
|
|
2037
|
-
* @param {*} key
|
|
2038
|
-
* @returns {*}
|
|
2039
|
-
*/
|
|
2040
|
-
class_1.prototype.get = function (key) {
|
|
2041
|
-
var index = getIndex(this.__entries__, key);
|
|
2042
|
-
var entry = this.__entries__[index];
|
|
2043
|
-
return entry && entry[1];
|
|
2044
|
-
};
|
|
2045
|
-
/**
|
|
2046
|
-
* @param {*} key
|
|
2047
|
-
* @param {*} value
|
|
2048
|
-
* @returns {void}
|
|
2049
|
-
*/
|
|
2050
|
-
class_1.prototype.set = function (key, value) {
|
|
2051
|
-
var index = getIndex(this.__entries__, key);
|
|
2052
|
-
if (~index) {
|
|
2053
|
-
this.__entries__[index][1] = value;
|
|
2054
|
-
}
|
|
2055
|
-
else {
|
|
2056
|
-
this.__entries__.push([key, value]);
|
|
2057
|
-
}
|
|
2058
|
-
};
|
|
2059
|
-
/**
|
|
2060
|
-
* @param {*} key
|
|
2061
|
-
* @returns {void}
|
|
2062
|
-
*/
|
|
2063
|
-
class_1.prototype.delete = function (key) {
|
|
2064
|
-
var entries = this.__entries__;
|
|
2065
|
-
var index = getIndex(entries, key);
|
|
2066
|
-
if (~index) {
|
|
2067
|
-
entries.splice(index, 1);
|
|
2068
|
-
}
|
|
2069
|
-
};
|
|
2070
|
-
/**
|
|
2071
|
-
* @param {*} key
|
|
2072
|
-
* @returns {void}
|
|
2073
|
-
*/
|
|
2074
|
-
class_1.prototype.has = function (key) {
|
|
2075
|
-
return !!~getIndex(this.__entries__, key);
|
|
2076
|
-
};
|
|
2077
|
-
/**
|
|
2078
|
-
* @returns {void}
|
|
2079
|
-
*/
|
|
2080
|
-
class_1.prototype.clear = function () {
|
|
2081
|
-
this.__entries__.splice(0);
|
|
2082
|
-
};
|
|
2083
|
-
/**
|
|
2084
|
-
* @param {Function} callback
|
|
2085
|
-
* @param {*} [ctx=null]
|
|
2086
|
-
* @returns {void}
|
|
2087
|
-
*/
|
|
2088
|
-
class_1.prototype.forEach = function (callback, ctx) {
|
|
2089
|
-
if (ctx === void 0) { ctx = null; }
|
|
2090
|
-
for (var _i = 0, _a = this.__entries__; _i < _a.length; _i++) {
|
|
2091
|
-
var entry = _a[_i];
|
|
2092
|
-
callback.call(ctx, entry[1], entry[0]);
|
|
2093
|
-
}
|
|
2094
|
-
};
|
|
2095
|
-
return class_1;
|
|
2096
|
-
}());
|
|
2097
|
-
})();
|
|
2098
|
-
|
|
2099
|
-
/**
|
|
2100
|
-
* Detects whether window and document objects are available in current environment.
|
|
2101
|
-
*/
|
|
2102
|
-
var isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined' && window.document === document;
|
|
2103
|
-
|
|
2104
|
-
// Returns global object of a current environment.
|
|
2105
|
-
var global$1 = (function () {
|
|
2106
|
-
if (typeof global !== 'undefined' && global.Math === Math) {
|
|
2107
|
-
return global;
|
|
2108
|
-
}
|
|
2109
|
-
if (typeof self !== 'undefined' && self.Math === Math) {
|
|
2110
|
-
return self;
|
|
2111
|
-
}
|
|
2112
|
-
if (typeof window !== 'undefined' && window.Math === Math) {
|
|
2113
|
-
return window;
|
|
2114
|
-
}
|
|
2115
|
-
// eslint-disable-next-line no-new-func
|
|
2116
|
-
return Function('return this')();
|
|
2117
|
-
})();
|
|
2118
|
-
|
|
2119
|
-
/**
|
|
2120
|
-
* A shim for the requestAnimationFrame which falls back to the setTimeout if
|
|
2121
|
-
* first one is not supported.
|
|
2122
|
-
*
|
|
2123
|
-
* @returns {number} Requests' identifier.
|
|
2124
|
-
*/
|
|
2125
|
-
var requestAnimationFrame$1 = (function () {
|
|
2126
|
-
if (typeof requestAnimationFrame === 'function') {
|
|
2127
|
-
// It's required to use a bounded function because IE sometimes throws
|
|
2128
|
-
// an "Invalid calling object" error if rAF is invoked without the global
|
|
2129
|
-
// object on the left hand side.
|
|
2130
|
-
return requestAnimationFrame.bind(global$1);
|
|
2131
|
-
}
|
|
2132
|
-
return function (callback) { return setTimeout(function () { return callback(Date.now()); }, 1000 / 60); };
|
|
2133
|
-
})();
|
|
2134
|
-
|
|
2135
|
-
// Defines minimum timeout before adding a trailing call.
|
|
2136
|
-
var trailingTimeout = 2;
|
|
2137
|
-
/**
|
|
2138
|
-
* Creates a wrapper function which ensures that provided callback will be
|
|
2139
|
-
* invoked only once during the specified delay period.
|
|
2140
|
-
*
|
|
2141
|
-
* @param {Function} callback - Function to be invoked after the delay period.
|
|
2142
|
-
* @param {number} delay - Delay after which to invoke callback.
|
|
2143
|
-
* @returns {Function}
|
|
2144
|
-
*/
|
|
2145
|
-
function throttle (callback, delay) {
|
|
2146
|
-
var leadingCall = false, trailingCall = false, lastCallTime = 0;
|
|
2147
|
-
/**
|
|
2148
|
-
* Invokes the original callback function and schedules new invocation if
|
|
2149
|
-
* the "proxy" was called during current request.
|
|
2150
|
-
*
|
|
2151
|
-
* @returns {void}
|
|
2152
|
-
*/
|
|
2153
|
-
function resolvePending() {
|
|
2154
|
-
if (leadingCall) {
|
|
2155
|
-
leadingCall = false;
|
|
2156
|
-
callback();
|
|
2157
|
-
}
|
|
2158
|
-
if (trailingCall) {
|
|
2159
|
-
proxy();
|
|
2160
|
-
}
|
|
2161
|
-
}
|
|
2162
|
-
/**
|
|
2163
|
-
* Callback invoked after the specified delay. It will further postpone
|
|
2164
|
-
* invocation of the original function delegating it to the
|
|
2165
|
-
* requestAnimationFrame.
|
|
2166
|
-
*
|
|
2167
|
-
* @returns {void}
|
|
2168
|
-
*/
|
|
2169
|
-
function timeoutCallback() {
|
|
2170
|
-
requestAnimationFrame$1(resolvePending);
|
|
2171
|
-
}
|
|
2172
|
-
/**
|
|
2173
|
-
* Schedules invocation of the original function.
|
|
2174
|
-
*
|
|
2175
|
-
* @returns {void}
|
|
2176
|
-
*/
|
|
2177
|
-
function proxy() {
|
|
2178
|
-
var timeStamp = Date.now();
|
|
2179
|
-
if (leadingCall) {
|
|
2180
|
-
// Reject immediately following calls.
|
|
2181
|
-
if (timeStamp - lastCallTime < trailingTimeout) {
|
|
2182
|
-
return;
|
|
2183
|
-
}
|
|
2184
|
-
// Schedule new call to be in invoked when the pending one is resolved.
|
|
2185
|
-
// This is important for "transitions" which never actually start
|
|
2186
|
-
// immediately so there is a chance that we might miss one if change
|
|
2187
|
-
// happens amids the pending invocation.
|
|
2188
|
-
trailingCall = true;
|
|
2189
|
-
}
|
|
2190
|
-
else {
|
|
2191
|
-
leadingCall = true;
|
|
2192
|
-
trailingCall = false;
|
|
2193
|
-
setTimeout(timeoutCallback, delay);
|
|
2194
|
-
}
|
|
2195
|
-
lastCallTime = timeStamp;
|
|
2196
|
-
}
|
|
2197
|
-
return proxy;
|
|
2198
|
-
}
|
|
2199
|
-
|
|
2200
|
-
// Minimum delay before invoking the update of observers.
|
|
2201
|
-
var REFRESH_DELAY = 20;
|
|
2202
|
-
// A list of substrings of CSS properties used to find transition events that
|
|
2203
|
-
// might affect dimensions of observed elements.
|
|
2204
|
-
var transitionKeys = ['top', 'right', 'bottom', 'left', 'width', 'height', 'size', 'weight'];
|
|
2205
|
-
// Check if MutationObserver is available.
|
|
2206
|
-
var mutationObserverSupported = typeof MutationObserver !== 'undefined';
|
|
2207
|
-
/**
|
|
2208
|
-
* Singleton controller class which handles updates of ResizeObserver instances.
|
|
2209
|
-
*/
|
|
2210
|
-
var ResizeObserverController = /** @class */ (function () {
|
|
2211
|
-
/**
|
|
2212
|
-
* Creates a new instance of ResizeObserverController.
|
|
2213
|
-
*
|
|
2214
|
-
* @private
|
|
2215
|
-
*/
|
|
2216
|
-
function ResizeObserverController() {
|
|
2217
|
-
/**
|
|
2218
|
-
* Indicates whether DOM listeners have been added.
|
|
2219
|
-
*
|
|
2220
|
-
* @private {boolean}
|
|
2221
|
-
*/
|
|
2222
|
-
this.connected_ = false;
|
|
2223
|
-
/**
|
|
2224
|
-
* Tells that controller has subscribed for Mutation Events.
|
|
2225
|
-
*
|
|
2226
|
-
* @private {boolean}
|
|
2227
|
-
*/
|
|
2228
|
-
this.mutationEventsAdded_ = false;
|
|
2229
|
-
/**
|
|
2230
|
-
* Keeps reference to the instance of MutationObserver.
|
|
2231
|
-
*
|
|
2232
|
-
* @private {MutationObserver}
|
|
2233
|
-
*/
|
|
2234
|
-
this.mutationsObserver_ = null;
|
|
2235
|
-
/**
|
|
2236
|
-
* A list of connected observers.
|
|
2237
|
-
*
|
|
2238
|
-
* @private {Array<ResizeObserverSPI>}
|
|
2239
|
-
*/
|
|
2240
|
-
this.observers_ = [];
|
|
2241
|
-
this.onTransitionEnd_ = this.onTransitionEnd_.bind(this);
|
|
2242
|
-
this.refresh = throttle(this.refresh.bind(this), REFRESH_DELAY);
|
|
2243
|
-
}
|
|
2244
|
-
/**
|
|
2245
|
-
* Adds observer to observers list.
|
|
2246
|
-
*
|
|
2247
|
-
* @param {ResizeObserverSPI} observer - Observer to be added.
|
|
2248
|
-
* @returns {void}
|
|
2249
|
-
*/
|
|
2250
|
-
ResizeObserverController.prototype.addObserver = function (observer) {
|
|
2251
|
-
if (!~this.observers_.indexOf(observer)) {
|
|
2252
|
-
this.observers_.push(observer);
|
|
2253
|
-
}
|
|
2254
|
-
// Add listeners if they haven't been added yet.
|
|
2255
|
-
if (!this.connected_) {
|
|
2256
|
-
this.connect_();
|
|
2257
|
-
}
|
|
2258
|
-
};
|
|
2259
|
-
/**
|
|
2260
|
-
* Removes observer from observers list.
|
|
2261
|
-
*
|
|
2262
|
-
* @param {ResizeObserverSPI} observer - Observer to be removed.
|
|
2263
|
-
* @returns {void}
|
|
2264
|
-
*/
|
|
2265
|
-
ResizeObserverController.prototype.removeObserver = function (observer) {
|
|
2266
|
-
var observers = this.observers_;
|
|
2267
|
-
var index = observers.indexOf(observer);
|
|
2268
|
-
// Remove observer if it's present in registry.
|
|
2269
|
-
if (~index) {
|
|
2270
|
-
observers.splice(index, 1);
|
|
2271
|
-
}
|
|
2272
|
-
// Remove listeners if controller has no connected observers.
|
|
2273
|
-
if (!observers.length && this.connected_) {
|
|
2274
|
-
this.disconnect_();
|
|
2275
|
-
}
|
|
2276
|
-
};
|
|
2277
|
-
/**
|
|
2278
|
-
* Invokes the update of observers. It will continue running updates insofar
|
|
2279
|
-
* it detects changes.
|
|
2280
|
-
*
|
|
2281
|
-
* @returns {void}
|
|
2282
|
-
*/
|
|
2283
|
-
ResizeObserverController.prototype.refresh = function () {
|
|
2284
|
-
var changesDetected = this.updateObservers_();
|
|
2285
|
-
// Continue running updates if changes have been detected as there might
|
|
2286
|
-
// be future ones caused by CSS transitions.
|
|
2287
|
-
if (changesDetected) {
|
|
2288
|
-
this.refresh();
|
|
2289
|
-
}
|
|
2290
|
-
};
|
|
2291
|
-
/**
|
|
2292
|
-
* Updates every observer from observers list and notifies them of queued
|
|
2293
|
-
* entries.
|
|
2294
|
-
*
|
|
2295
|
-
* @private
|
|
2296
|
-
* @returns {boolean} Returns "true" if any observer has detected changes in
|
|
2297
|
-
* dimensions of it's elements.
|
|
2298
|
-
*/
|
|
2299
|
-
ResizeObserverController.prototype.updateObservers_ = function () {
|
|
2300
|
-
// Collect observers that have active observations.
|
|
2301
|
-
var activeObservers = this.observers_.filter(function (observer) {
|
|
2302
|
-
return observer.gatherActive(), observer.hasActive();
|
|
2303
|
-
});
|
|
2304
|
-
// Deliver notifications in a separate cycle in order to avoid any
|
|
2305
|
-
// collisions between observers, e.g. when multiple instances of
|
|
2306
|
-
// ResizeObserver are tracking the same element and the callback of one
|
|
2307
|
-
// of them changes content dimensions of the observed target. Sometimes
|
|
2308
|
-
// this may result in notifications being blocked for the rest of observers.
|
|
2309
|
-
activeObservers.forEach(function (observer) { return observer.broadcastActive(); });
|
|
2310
|
-
return activeObservers.length > 0;
|
|
2311
|
-
};
|
|
2312
|
-
/**
|
|
2313
|
-
* Initializes DOM listeners.
|
|
2314
|
-
*
|
|
2315
|
-
* @private
|
|
2316
|
-
* @returns {void}
|
|
2317
|
-
*/
|
|
2318
|
-
ResizeObserverController.prototype.connect_ = function () {
|
|
2319
|
-
// Do nothing if running in a non-browser environment or if listeners
|
|
2320
|
-
// have been already added.
|
|
2321
|
-
if (!isBrowser || this.connected_) {
|
|
2322
|
-
return;
|
|
2323
|
-
}
|
|
2324
|
-
// Subscription to the "Transitionend" event is used as a workaround for
|
|
2325
|
-
// delayed transitions. This way it's possible to capture at least the
|
|
2326
|
-
// final state of an element.
|
|
2327
|
-
document.addEventListener('transitionend', this.onTransitionEnd_);
|
|
2328
|
-
window.addEventListener('resize', this.refresh);
|
|
2329
|
-
if (mutationObserverSupported) {
|
|
2330
|
-
this.mutationsObserver_ = new MutationObserver(this.refresh);
|
|
2331
|
-
this.mutationsObserver_.observe(document, {
|
|
2332
|
-
attributes: true,
|
|
2333
|
-
childList: true,
|
|
2334
|
-
characterData: true,
|
|
2335
|
-
subtree: true
|
|
2336
|
-
});
|
|
2337
|
-
}
|
|
2338
|
-
else {
|
|
2339
|
-
document.addEventListener('DOMSubtreeModified', this.refresh);
|
|
2340
|
-
this.mutationEventsAdded_ = true;
|
|
2341
|
-
}
|
|
2342
|
-
this.connected_ = true;
|
|
2343
|
-
};
|
|
2344
|
-
/**
|
|
2345
|
-
* Removes DOM listeners.
|
|
2346
|
-
*
|
|
2347
|
-
* @private
|
|
2348
|
-
* @returns {void}
|
|
2349
|
-
*/
|
|
2350
|
-
ResizeObserverController.prototype.disconnect_ = function () {
|
|
2351
|
-
// Do nothing if running in a non-browser environment or if listeners
|
|
2352
|
-
// have been already removed.
|
|
2353
|
-
if (!isBrowser || !this.connected_) {
|
|
2354
|
-
return;
|
|
2355
|
-
}
|
|
2356
|
-
document.removeEventListener('transitionend', this.onTransitionEnd_);
|
|
2357
|
-
window.removeEventListener('resize', this.refresh);
|
|
2358
|
-
if (this.mutationsObserver_) {
|
|
2359
|
-
this.mutationsObserver_.disconnect();
|
|
2360
|
-
}
|
|
2361
|
-
if (this.mutationEventsAdded_) {
|
|
2362
|
-
document.removeEventListener('DOMSubtreeModified', this.refresh);
|
|
2363
|
-
}
|
|
2364
|
-
this.mutationsObserver_ = null;
|
|
2365
|
-
this.mutationEventsAdded_ = false;
|
|
2366
|
-
this.connected_ = false;
|
|
2367
|
-
};
|
|
2368
|
-
/**
|
|
2369
|
-
* "Transitionend" event handler.
|
|
2370
|
-
*
|
|
2371
|
-
* @private
|
|
2372
|
-
* @param {TransitionEvent} event
|
|
2373
|
-
* @returns {void}
|
|
2374
|
-
*/
|
|
2375
|
-
ResizeObserverController.prototype.onTransitionEnd_ = function (_a) {
|
|
2376
|
-
var _b = _a.propertyName, propertyName = _b === void 0 ? '' : _b;
|
|
2377
|
-
// Detect whether transition may affect dimensions of an element.
|
|
2378
|
-
var isReflowProperty = transitionKeys.some(function (key) {
|
|
2379
|
-
return !!~propertyName.indexOf(key);
|
|
2380
|
-
});
|
|
2381
|
-
if (isReflowProperty) {
|
|
2382
|
-
this.refresh();
|
|
2383
|
-
}
|
|
2384
|
-
};
|
|
2385
|
-
/**
|
|
2386
|
-
* Returns instance of the ResizeObserverController.
|
|
2387
|
-
*
|
|
2388
|
-
* @returns {ResizeObserverController}
|
|
2389
|
-
*/
|
|
2390
|
-
ResizeObserverController.getInstance = function () {
|
|
2391
|
-
if (!this.instance_) {
|
|
2392
|
-
this.instance_ = new ResizeObserverController();
|
|
2393
|
-
}
|
|
2394
|
-
return this.instance_;
|
|
2395
|
-
};
|
|
2396
|
-
/**
|
|
2397
|
-
* Holds reference to the controller's instance.
|
|
2398
|
-
*
|
|
2399
|
-
* @private {ResizeObserverController}
|
|
2400
|
-
*/
|
|
2401
|
-
ResizeObserverController.instance_ = null;
|
|
2402
|
-
return ResizeObserverController;
|
|
2403
|
-
}());
|
|
2404
|
-
|
|
2405
|
-
/**
|
|
2406
|
-
* Defines non-writable/enumerable properties of the provided target object.
|
|
2407
|
-
*
|
|
2408
|
-
* @param {Object} target - Object for which to define properties.
|
|
2409
|
-
* @param {Object} props - Properties to be defined.
|
|
2410
|
-
* @returns {Object} Target object.
|
|
2411
|
-
*/
|
|
2412
|
-
var defineConfigurable = (function (target, props) {
|
|
2413
|
-
for (var _i = 0, _a = Object.keys(props); _i < _a.length; _i++) {
|
|
2414
|
-
var key = _a[_i];
|
|
2415
|
-
Object.defineProperty(target, key, {
|
|
2416
|
-
value: props[key],
|
|
2417
|
-
enumerable: false,
|
|
2418
|
-
writable: false,
|
|
2419
|
-
configurable: true
|
|
2420
|
-
});
|
|
2421
|
-
}
|
|
2422
|
-
return target;
|
|
2423
|
-
});
|
|
2424
|
-
|
|
2425
|
-
/**
|
|
2426
|
-
* Returns the global object associated with provided element.
|
|
2427
|
-
*
|
|
2428
|
-
* @param {Object} target
|
|
2429
|
-
* @returns {Object}
|
|
2430
|
-
*/
|
|
2431
|
-
var getWindowOf = (function (target) {
|
|
2432
|
-
// Assume that the element is an instance of Node, which means that it
|
|
2433
|
-
// has the "ownerDocument" property from which we can retrieve a
|
|
2434
|
-
// corresponding global object.
|
|
2435
|
-
var ownerGlobal = target && target.ownerDocument && target.ownerDocument.defaultView;
|
|
2436
|
-
// Return the local global object if it's not possible extract one from
|
|
2437
|
-
// provided element.
|
|
2438
|
-
return ownerGlobal || global$1;
|
|
2439
|
-
});
|
|
2440
|
-
|
|
2441
|
-
// Placeholder of an empty content rectangle.
|
|
2442
|
-
var emptyRect = createRectInit(0, 0, 0, 0);
|
|
2443
|
-
/**
|
|
2444
|
-
* Converts provided string to a number.
|
|
2445
|
-
*
|
|
2446
|
-
* @param {number|string} value
|
|
2447
|
-
* @returns {number}
|
|
2448
|
-
*/
|
|
2449
|
-
function toFloat(value) {
|
|
2450
|
-
return parseFloat(value) || 0;
|
|
2451
|
-
}
|
|
2452
|
-
/**
|
|
2453
|
-
* Extracts borders size from provided styles.
|
|
2454
|
-
*
|
|
2455
|
-
* @param {CSSStyleDeclaration} styles
|
|
2456
|
-
* @param {...string} positions - Borders positions (top, right, ...)
|
|
2457
|
-
* @returns {number}
|
|
2458
|
-
*/
|
|
2459
|
-
function getBordersSize(styles) {
|
|
2460
|
-
var positions = [];
|
|
2461
|
-
for (var _i = 1; _i < arguments.length; _i++) {
|
|
2462
|
-
positions[_i - 1] = arguments[_i];
|
|
2463
|
-
}
|
|
2464
|
-
return positions.reduce(function (size, position) {
|
|
2465
|
-
var value = styles['border-' + position + '-width'];
|
|
2466
|
-
return size + toFloat(value);
|
|
2467
|
-
}, 0);
|
|
2468
|
-
}
|
|
2469
|
-
/**
|
|
2470
|
-
* Extracts paddings sizes from provided styles.
|
|
2471
|
-
*
|
|
2472
|
-
* @param {CSSStyleDeclaration} styles
|
|
2473
|
-
* @returns {Object} Paddings box.
|
|
2474
|
-
*/
|
|
2475
|
-
function getPaddings(styles) {
|
|
2476
|
-
var positions = ['top', 'right', 'bottom', 'left'];
|
|
2477
|
-
var paddings = {};
|
|
2478
|
-
for (var _i = 0, positions_1 = positions; _i < positions_1.length; _i++) {
|
|
2479
|
-
var position = positions_1[_i];
|
|
2480
|
-
var value = styles['padding-' + position];
|
|
2481
|
-
paddings[position] = toFloat(value);
|
|
2482
|
-
}
|
|
2483
|
-
return paddings;
|
|
2484
|
-
}
|
|
2485
|
-
/**
|
|
2486
|
-
* Calculates content rectangle of provided SVG element.
|
|
2487
|
-
*
|
|
2488
|
-
* @param {SVGGraphicsElement} target - Element content rectangle of which needs
|
|
2489
|
-
* to be calculated.
|
|
2490
|
-
* @returns {DOMRectInit}
|
|
2491
|
-
*/
|
|
2492
|
-
function getSVGContentRect(target) {
|
|
2493
|
-
var bbox = target.getBBox();
|
|
2494
|
-
return createRectInit(0, 0, bbox.width, bbox.height);
|
|
2495
|
-
}
|
|
2496
|
-
/**
|
|
2497
|
-
* Calculates content rectangle of provided HTMLElement.
|
|
2498
|
-
*
|
|
2499
|
-
* @param {HTMLElement} target - Element for which to calculate the content rectangle.
|
|
2500
|
-
* @returns {DOMRectInit}
|
|
2501
|
-
*/
|
|
2502
|
-
function getHTMLElementContentRect(target) {
|
|
2503
|
-
// Client width & height properties can't be
|
|
2504
|
-
// used exclusively as they provide rounded values.
|
|
2505
|
-
var clientWidth = target.clientWidth, clientHeight = target.clientHeight;
|
|
2506
|
-
// By this condition we can catch all non-replaced inline, hidden and
|
|
2507
|
-
// detached elements. Though elements with width & height properties less
|
|
2508
|
-
// than 0.5 will be discarded as well.
|
|
2509
|
-
//
|
|
2510
|
-
// Without it we would need to implement separate methods for each of
|
|
2511
|
-
// those cases and it's not possible to perform a precise and performance
|
|
2512
|
-
// effective test for hidden elements. E.g. even jQuery's ':visible' filter
|
|
2513
|
-
// gives wrong results for elements with width & height less than 0.5.
|
|
2514
|
-
if (!clientWidth && !clientHeight) {
|
|
2515
|
-
return emptyRect;
|
|
2516
|
-
}
|
|
2517
|
-
var styles = getWindowOf(target).getComputedStyle(target);
|
|
2518
|
-
var paddings = getPaddings(styles);
|
|
2519
|
-
var horizPad = paddings.left + paddings.right;
|
|
2520
|
-
var vertPad = paddings.top + paddings.bottom;
|
|
2521
|
-
// Computed styles of width & height are being used because they are the
|
|
2522
|
-
// only dimensions available to JS that contain non-rounded values. It could
|
|
2523
|
-
// be possible to utilize the getBoundingClientRect if only it's data wasn't
|
|
2524
|
-
// affected by CSS transformations let alone paddings, borders and scroll bars.
|
|
2525
|
-
var width = toFloat(styles.width), height = toFloat(styles.height);
|
|
2526
|
-
// Width & height include paddings and borders when the 'border-box' box
|
|
2527
|
-
// model is applied (except for IE).
|
|
2528
|
-
if (styles.boxSizing === 'border-box') {
|
|
2529
|
-
// Following conditions are required to handle Internet Explorer which
|
|
2530
|
-
// doesn't include paddings and borders to computed CSS dimensions.
|
|
2531
|
-
//
|
|
2532
|
-
// We can say that if CSS dimensions + paddings are equal to the "client"
|
|
2533
|
-
// properties then it's either IE, and thus we don't need to subtract
|
|
2534
|
-
// anything, or an element merely doesn't have paddings/borders styles.
|
|
2535
|
-
if (Math.round(width + horizPad) !== clientWidth) {
|
|
2536
|
-
width -= getBordersSize(styles, 'left', 'right') + horizPad;
|
|
2537
|
-
}
|
|
2538
|
-
if (Math.round(height + vertPad) !== clientHeight) {
|
|
2539
|
-
height -= getBordersSize(styles, 'top', 'bottom') + vertPad;
|
|
2540
|
-
}
|
|
2541
|
-
}
|
|
2542
|
-
// Following steps can't be applied to the document's root element as its
|
|
2543
|
-
// client[Width/Height] properties represent viewport area of the window.
|
|
2544
|
-
// Besides, it's as well not necessary as the <html> itself neither has
|
|
2545
|
-
// rendered scroll bars nor it can be clipped.
|
|
2546
|
-
if (!isDocumentElement(target)) {
|
|
2547
|
-
// In some browsers (only in Firefox, actually) CSS width & height
|
|
2548
|
-
// include scroll bars size which can be removed at this step as scroll
|
|
2549
|
-
// bars are the only difference between rounded dimensions + paddings
|
|
2550
|
-
// and "client" properties, though that is not always true in Chrome.
|
|
2551
|
-
var vertScrollbar = Math.round(width + horizPad) - clientWidth;
|
|
2552
|
-
var horizScrollbar = Math.round(height + vertPad) - clientHeight;
|
|
2553
|
-
// Chrome has a rather weird rounding of "client" properties.
|
|
2554
|
-
// E.g. for an element with content width of 314.2px it sometimes gives
|
|
2555
|
-
// the client width of 315px and for the width of 314.7px it may give
|
|
2556
|
-
// 314px. And it doesn't happen all the time. So just ignore this delta
|
|
2557
|
-
// as a non-relevant.
|
|
2558
|
-
if (Math.abs(vertScrollbar) !== 1) {
|
|
2559
|
-
width -= vertScrollbar;
|
|
2560
|
-
}
|
|
2561
|
-
if (Math.abs(horizScrollbar) !== 1) {
|
|
2562
|
-
height -= horizScrollbar;
|
|
2563
|
-
}
|
|
2564
|
-
}
|
|
2565
|
-
return createRectInit(paddings.left, paddings.top, width, height);
|
|
2566
|
-
}
|
|
2567
|
-
/**
|
|
2568
|
-
* Checks whether provided element is an instance of the SVGGraphicsElement.
|
|
2569
|
-
*
|
|
2570
|
-
* @param {Element} target - Element to be checked.
|
|
2571
|
-
* @returns {boolean}
|
|
2572
|
-
*/
|
|
2573
|
-
var isSVGGraphicsElement = (function () {
|
|
2574
|
-
// Some browsers, namely IE and Edge, don't have the SVGGraphicsElement
|
|
2575
|
-
// interface.
|
|
2576
|
-
if (typeof SVGGraphicsElement !== 'undefined') {
|
|
2577
|
-
return function (target) { return target instanceof getWindowOf(target).SVGGraphicsElement; };
|
|
2578
|
-
}
|
|
2579
|
-
// If it's so, then check that element is at least an instance of the
|
|
2580
|
-
// SVGElement and that it has the "getBBox" method.
|
|
2581
|
-
// eslint-disable-next-line no-extra-parens
|
|
2582
|
-
return function (target) { return (target instanceof getWindowOf(target).SVGElement &&
|
|
2583
|
-
typeof target.getBBox === 'function'); };
|
|
2584
|
-
})();
|
|
2585
|
-
/**
|
|
2586
|
-
* Checks whether provided element is a document element (<html>).
|
|
2587
|
-
*
|
|
2588
|
-
* @param {Element} target - Element to be checked.
|
|
2589
|
-
* @returns {boolean}
|
|
2590
|
-
*/
|
|
2591
|
-
function isDocumentElement(target) {
|
|
2592
|
-
return target === getWindowOf(target).document.documentElement;
|
|
2593
|
-
}
|
|
2594
|
-
/**
|
|
2595
|
-
* Calculates an appropriate content rectangle for provided html or svg element.
|
|
2596
|
-
*
|
|
2597
|
-
* @param {Element} target - Element content rectangle of which needs to be calculated.
|
|
2598
|
-
* @returns {DOMRectInit}
|
|
2599
|
-
*/
|
|
2600
|
-
function getContentRect(target) {
|
|
2601
|
-
if (!isBrowser) {
|
|
2602
|
-
return emptyRect;
|
|
2603
|
-
}
|
|
2604
|
-
if (isSVGGraphicsElement(target)) {
|
|
2605
|
-
return getSVGContentRect(target);
|
|
2606
|
-
}
|
|
2607
|
-
return getHTMLElementContentRect(target);
|
|
2608
|
-
}
|
|
2609
|
-
/**
|
|
2610
|
-
* Creates rectangle with an interface of the DOMRectReadOnly.
|
|
2611
|
-
* Spec: https://drafts.fxtf.org/geometry/#domrectreadonly
|
|
2612
|
-
*
|
|
2613
|
-
* @param {DOMRectInit} rectInit - Object with rectangle's x/y coordinates and dimensions.
|
|
2614
|
-
* @returns {DOMRectReadOnly}
|
|
2615
|
-
*/
|
|
2616
|
-
function createReadOnlyRect(_a) {
|
|
2617
|
-
var x = _a.x, y = _a.y, width = _a.width, height = _a.height;
|
|
2618
|
-
// If DOMRectReadOnly is available use it as a prototype for the rectangle.
|
|
2619
|
-
var Constr = typeof DOMRectReadOnly !== 'undefined' ? DOMRectReadOnly : Object;
|
|
2620
|
-
var rect = Object.create(Constr.prototype);
|
|
2621
|
-
// Rectangle's properties are not writable and non-enumerable.
|
|
2622
|
-
defineConfigurable(rect, {
|
|
2623
|
-
x: x, y: y, width: width, height: height,
|
|
2624
|
-
top: y,
|
|
2625
|
-
right: x + width,
|
|
2626
|
-
bottom: height + y,
|
|
2627
|
-
left: x
|
|
2628
|
-
});
|
|
2629
|
-
return rect;
|
|
2630
|
-
}
|
|
2631
|
-
/**
|
|
2632
|
-
* Creates DOMRectInit object based on the provided dimensions and the x/y coordinates.
|
|
2633
|
-
* Spec: https://drafts.fxtf.org/geometry/#dictdef-domrectinit
|
|
2634
|
-
*
|
|
2635
|
-
* @param {number} x - X coordinate.
|
|
2636
|
-
* @param {number} y - Y coordinate.
|
|
2637
|
-
* @param {number} width - Rectangle's width.
|
|
2638
|
-
* @param {number} height - Rectangle's height.
|
|
2639
|
-
* @returns {DOMRectInit}
|
|
2640
|
-
*/
|
|
2641
|
-
function createRectInit(x, y, width, height) {
|
|
2642
|
-
return { x: x, y: y, width: width, height: height };
|
|
2643
|
-
}
|
|
2644
|
-
|
|
2645
|
-
/**
|
|
2646
|
-
* Class that is responsible for computations of the content rectangle of
|
|
2647
|
-
* provided DOM element and for keeping track of it's changes.
|
|
2648
|
-
*/
|
|
2649
|
-
var ResizeObservation = /** @class */ (function () {
|
|
2650
|
-
/**
|
|
2651
|
-
* Creates an instance of ResizeObservation.
|
|
2652
|
-
*
|
|
2653
|
-
* @param {Element} target - Element to be observed.
|
|
2654
|
-
*/
|
|
2655
|
-
function ResizeObservation(target) {
|
|
2656
|
-
/**
|
|
2657
|
-
* Broadcasted width of content rectangle.
|
|
2658
|
-
*
|
|
2659
|
-
* @type {number}
|
|
2660
|
-
*/
|
|
2661
|
-
this.broadcastWidth = 0;
|
|
2662
|
-
/**
|
|
2663
|
-
* Broadcasted height of content rectangle.
|
|
2664
|
-
*
|
|
2665
|
-
* @type {number}
|
|
2666
|
-
*/
|
|
2667
|
-
this.broadcastHeight = 0;
|
|
2668
|
-
/**
|
|
2669
|
-
* Reference to the last observed content rectangle.
|
|
2670
|
-
*
|
|
2671
|
-
* @private {DOMRectInit}
|
|
2672
|
-
*/
|
|
2673
|
-
this.contentRect_ = createRectInit(0, 0, 0, 0);
|
|
2674
|
-
this.target = target;
|
|
2675
|
-
}
|
|
2676
|
-
/**
|
|
2677
|
-
* Updates content rectangle and tells whether it's width or height properties
|
|
2678
|
-
* have changed since the last broadcast.
|
|
2679
|
-
*
|
|
2680
|
-
* @returns {boolean}
|
|
2681
|
-
*/
|
|
2682
|
-
ResizeObservation.prototype.isActive = function () {
|
|
2683
|
-
var rect = getContentRect(this.target);
|
|
2684
|
-
this.contentRect_ = rect;
|
|
2685
|
-
return (rect.width !== this.broadcastWidth ||
|
|
2686
|
-
rect.height !== this.broadcastHeight);
|
|
2687
|
-
};
|
|
2688
|
-
/**
|
|
2689
|
-
* Updates 'broadcastWidth' and 'broadcastHeight' properties with a data
|
|
2690
|
-
* from the corresponding properties of the last observed content rectangle.
|
|
2691
|
-
*
|
|
2692
|
-
* @returns {DOMRectInit} Last observed content rectangle.
|
|
2693
|
-
*/
|
|
2694
|
-
ResizeObservation.prototype.broadcastRect = function () {
|
|
2695
|
-
var rect = this.contentRect_;
|
|
2696
|
-
this.broadcastWidth = rect.width;
|
|
2697
|
-
this.broadcastHeight = rect.height;
|
|
2698
|
-
return rect;
|
|
2699
|
-
};
|
|
2700
|
-
return ResizeObservation;
|
|
2701
|
-
}());
|
|
2702
|
-
|
|
2703
|
-
var ResizeObserverEntry = /** @class */ (function () {
|
|
2704
|
-
/**
|
|
2705
|
-
* Creates an instance of ResizeObserverEntry.
|
|
2706
|
-
*
|
|
2707
|
-
* @param {Element} target - Element that is being observed.
|
|
2708
|
-
* @param {DOMRectInit} rectInit - Data of the element's content rectangle.
|
|
2709
|
-
*/
|
|
2710
|
-
function ResizeObserverEntry(target, rectInit) {
|
|
2711
|
-
var contentRect = createReadOnlyRect(rectInit);
|
|
2712
|
-
// According to the specification following properties are not writable
|
|
2713
|
-
// and are also not enumerable in the native implementation.
|
|
2714
|
-
//
|
|
2715
|
-
// Property accessors are not being used as they'd require to define a
|
|
2716
|
-
// private WeakMap storage which may cause memory leaks in browsers that
|
|
2717
|
-
// don't support this type of collections.
|
|
2718
|
-
defineConfigurable(this, { target: target, contentRect: contentRect });
|
|
2719
|
-
}
|
|
2720
|
-
return ResizeObserverEntry;
|
|
2721
|
-
}());
|
|
2722
|
-
|
|
2723
|
-
var ResizeObserverSPI = /** @class */ (function () {
|
|
2724
|
-
/**
|
|
2725
|
-
* Creates a new instance of ResizeObserver.
|
|
2726
|
-
*
|
|
2727
|
-
* @param {ResizeObserverCallback} callback - Callback function that is invoked
|
|
2728
|
-
* when one of the observed elements changes it's content dimensions.
|
|
2729
|
-
* @param {ResizeObserverController} controller - Controller instance which
|
|
2730
|
-
* is responsible for the updates of observer.
|
|
2731
|
-
* @param {ResizeObserver} callbackCtx - Reference to the public
|
|
2732
|
-
* ResizeObserver instance which will be passed to callback function.
|
|
2733
|
-
*/
|
|
2734
|
-
function ResizeObserverSPI(callback, controller, callbackCtx) {
|
|
2735
|
-
/**
|
|
2736
|
-
* Collection of resize observations that have detected changes in dimensions
|
|
2737
|
-
* of elements.
|
|
2738
|
-
*
|
|
2739
|
-
* @private {Array<ResizeObservation>}
|
|
2740
|
-
*/
|
|
2741
|
-
this.activeObservations_ = [];
|
|
2742
|
-
/**
|
|
2743
|
-
* Registry of the ResizeObservation instances.
|
|
2744
|
-
*
|
|
2745
|
-
* @private {Map<Element, ResizeObservation>}
|
|
2746
|
-
*/
|
|
2747
|
-
this.observations_ = new MapShim();
|
|
2748
|
-
if (typeof callback !== 'function') {
|
|
2749
|
-
throw new TypeError('The callback provided as parameter 1 is not a function.');
|
|
2750
|
-
}
|
|
2751
|
-
this.callback_ = callback;
|
|
2752
|
-
this.controller_ = controller;
|
|
2753
|
-
this.callbackCtx_ = callbackCtx;
|
|
2754
|
-
}
|
|
2755
|
-
/**
|
|
2756
|
-
* Starts observing provided element.
|
|
2757
|
-
*
|
|
2758
|
-
* @param {Element} target - Element to be observed.
|
|
2759
|
-
* @returns {void}
|
|
2760
|
-
*/
|
|
2761
|
-
ResizeObserverSPI.prototype.observe = function (target) {
|
|
2762
|
-
if (!arguments.length) {
|
|
2763
|
-
throw new TypeError('1 argument required, but only 0 present.');
|
|
2764
|
-
}
|
|
2765
|
-
// Do nothing if current environment doesn't have the Element interface.
|
|
2766
|
-
if (typeof Element === 'undefined' || !(Element instanceof Object)) {
|
|
2767
|
-
return;
|
|
2768
|
-
}
|
|
2769
|
-
if (!(target instanceof getWindowOf(target).Element)) {
|
|
2770
|
-
throw new TypeError('parameter 1 is not of type "Element".');
|
|
2771
|
-
}
|
|
2772
|
-
var observations = this.observations_;
|
|
2773
|
-
// Do nothing if element is already being observed.
|
|
2774
|
-
if (observations.has(target)) {
|
|
2775
|
-
return;
|
|
2776
|
-
}
|
|
2777
|
-
observations.set(target, new ResizeObservation(target));
|
|
2778
|
-
this.controller_.addObserver(this);
|
|
2779
|
-
// Force the update of observations.
|
|
2780
|
-
this.controller_.refresh();
|
|
2781
|
-
};
|
|
2782
|
-
/**
|
|
2783
|
-
* Stops observing provided element.
|
|
2784
|
-
*
|
|
2785
|
-
* @param {Element} target - Element to stop observing.
|
|
2786
|
-
* @returns {void}
|
|
2787
|
-
*/
|
|
2788
|
-
ResizeObserverSPI.prototype.unobserve = function (target) {
|
|
2789
|
-
if (!arguments.length) {
|
|
2790
|
-
throw new TypeError('1 argument required, but only 0 present.');
|
|
2791
|
-
}
|
|
2792
|
-
// Do nothing if current environment doesn't have the Element interface.
|
|
2793
|
-
if (typeof Element === 'undefined' || !(Element instanceof Object)) {
|
|
2794
|
-
return;
|
|
2795
|
-
}
|
|
2796
|
-
if (!(target instanceof getWindowOf(target).Element)) {
|
|
2797
|
-
throw new TypeError('parameter 1 is not of type "Element".');
|
|
2798
|
-
}
|
|
2799
|
-
var observations = this.observations_;
|
|
2800
|
-
// Do nothing if element is not being observed.
|
|
2801
|
-
if (!observations.has(target)) {
|
|
2802
|
-
return;
|
|
2803
|
-
}
|
|
2804
|
-
observations.delete(target);
|
|
2805
|
-
if (!observations.size) {
|
|
2806
|
-
this.controller_.removeObserver(this);
|
|
2807
|
-
}
|
|
2808
|
-
};
|
|
2809
|
-
/**
|
|
2810
|
-
* Stops observing all elements.
|
|
2811
|
-
*
|
|
2812
|
-
* @returns {void}
|
|
2813
|
-
*/
|
|
2814
|
-
ResizeObserverSPI.prototype.disconnect = function () {
|
|
2815
|
-
this.clearActive();
|
|
2816
|
-
this.observations_.clear();
|
|
2817
|
-
this.controller_.removeObserver(this);
|
|
2818
|
-
};
|
|
2819
|
-
/**
|
|
2820
|
-
* Collects observation instances the associated element of which has changed
|
|
2821
|
-
* it's content rectangle.
|
|
2822
|
-
*
|
|
2823
|
-
* @returns {void}
|
|
2824
|
-
*/
|
|
2825
|
-
ResizeObserverSPI.prototype.gatherActive = function () {
|
|
2826
|
-
var _this = this;
|
|
2827
|
-
this.clearActive();
|
|
2828
|
-
this.observations_.forEach(function (observation) {
|
|
2829
|
-
if (observation.isActive()) {
|
|
2830
|
-
_this.activeObservations_.push(observation);
|
|
2831
|
-
}
|
|
2832
|
-
});
|
|
2833
|
-
};
|
|
2834
|
-
/**
|
|
2835
|
-
* Invokes initial callback function with a list of ResizeObserverEntry
|
|
2836
|
-
* instances collected from active resize observations.
|
|
2837
|
-
*
|
|
2838
|
-
* @returns {void}
|
|
2839
|
-
*/
|
|
2840
|
-
ResizeObserverSPI.prototype.broadcastActive = function () {
|
|
2841
|
-
// Do nothing if observer doesn't have active observations.
|
|
2842
|
-
if (!this.hasActive()) {
|
|
2843
|
-
return;
|
|
2844
|
-
}
|
|
2845
|
-
var ctx = this.callbackCtx_;
|
|
2846
|
-
// Create ResizeObserverEntry instance for every active observation.
|
|
2847
|
-
var entries = this.activeObservations_.map(function (observation) {
|
|
2848
|
-
return new ResizeObserverEntry(observation.target, observation.broadcastRect());
|
|
2849
|
-
});
|
|
2850
|
-
this.callback_.call(ctx, entries, ctx);
|
|
2851
|
-
this.clearActive();
|
|
2852
|
-
};
|
|
2853
|
-
/**
|
|
2854
|
-
* Clears the collection of active observations.
|
|
2855
|
-
*
|
|
2856
|
-
* @returns {void}
|
|
2857
|
-
*/
|
|
2858
|
-
ResizeObserverSPI.prototype.clearActive = function () {
|
|
2859
|
-
this.activeObservations_.splice(0);
|
|
2860
|
-
};
|
|
2861
|
-
/**
|
|
2862
|
-
* Tells whether observer has active observations.
|
|
2863
|
-
*
|
|
2864
|
-
* @returns {boolean}
|
|
2865
|
-
*/
|
|
2866
|
-
ResizeObserverSPI.prototype.hasActive = function () {
|
|
2867
|
-
return this.activeObservations_.length > 0;
|
|
2868
|
-
};
|
|
2869
|
-
return ResizeObserverSPI;
|
|
2870
|
-
}());
|
|
2871
|
-
|
|
2872
|
-
// Registry of internal observers. If WeakMap is not available use current shim
|
|
2873
|
-
// for the Map collection as it has all required methods and because WeakMap
|
|
2874
|
-
// can't be fully polyfilled anyway.
|
|
2875
|
-
var observers = typeof WeakMap !== 'undefined' ? new WeakMap() : new MapShim();
|
|
2876
|
-
/**
|
|
2877
|
-
* ResizeObserver API. Encapsulates the ResizeObserver SPI implementation
|
|
2878
|
-
* exposing only those methods and properties that are defined in the spec.
|
|
2879
|
-
*/
|
|
2880
|
-
var ResizeObserver$1 = /** @class */ (function () {
|
|
2881
|
-
/**
|
|
2882
|
-
* Creates a new instance of ResizeObserver.
|
|
2883
|
-
*
|
|
2884
|
-
* @param {ResizeObserverCallback} callback - Callback that is invoked when
|
|
2885
|
-
* dimensions of the observed elements change.
|
|
2886
|
-
*/
|
|
2887
|
-
function ResizeObserver(callback) {
|
|
2888
|
-
if (!(this instanceof ResizeObserver)) {
|
|
2889
|
-
throw new TypeError('Cannot call a class as a function.');
|
|
2890
|
-
}
|
|
2891
|
-
if (!arguments.length) {
|
|
2892
|
-
throw new TypeError('1 argument required, but only 0 present.');
|
|
2893
|
-
}
|
|
2894
|
-
var controller = ResizeObserverController.getInstance();
|
|
2895
|
-
var observer = new ResizeObserverSPI(callback, controller, this);
|
|
2896
|
-
observers.set(this, observer);
|
|
2897
|
-
}
|
|
2898
|
-
return ResizeObserver;
|
|
2899
|
-
}());
|
|
2900
|
-
// Expose public methods of ResizeObserver.
|
|
2901
|
-
[
|
|
2902
|
-
'observe',
|
|
2903
|
-
'unobserve',
|
|
2904
|
-
'disconnect'
|
|
2905
|
-
].forEach(function (method) {
|
|
2906
|
-
ResizeObserver$1.prototype[method] = function () {
|
|
2907
|
-
var _a;
|
|
2908
|
-
return (_a = observers.get(this))[method].apply(_a, arguments);
|
|
2909
|
-
};
|
|
2910
|
-
});
|
|
2911
|
-
|
|
2912
|
-
var index = (function () {
|
|
2913
|
-
// Export existing implementation if available.
|
|
2914
|
-
if (typeof global$1.ResizeObserver !== 'undefined') {
|
|
2915
|
-
return global$1.ResizeObserver;
|
|
2916
|
-
}
|
|
2917
|
-
return ResizeObserver$1;
|
|
2918
|
-
})();
|
|
2919
|
-
|
|
2920
|
-
// =============================== Const ===============================
|
|
2921
|
-
var elementListeners = new Map();
|
|
2922
|
-
function onResize(entities) {
|
|
2923
|
-
entities.forEach(function (entity) {
|
|
2924
|
-
var _elementListeners$get;
|
|
2925
|
-
var target = entity.target;
|
|
2926
|
-
(_elementListeners$get = elementListeners.get(target)) === null || _elementListeners$get === void 0 ? void 0 : _elementListeners$get.forEach(function (listener) {
|
|
2927
|
-
return listener(target);
|
|
2928
|
-
});
|
|
2929
|
-
});
|
|
2930
|
-
}
|
|
2931
|
-
// Note: ResizeObserver polyfill not support option to measure border-box resize
|
|
2932
|
-
var resizeObserver = new index(onResize);
|
|
2933
|
-
// ============================== Observe ==============================
|
|
2934
|
-
function observe(element, callback) {
|
|
2935
|
-
if (!elementListeners.has(element)) {
|
|
2936
|
-
elementListeners.set(element, new Set());
|
|
2937
|
-
resizeObserver.observe(element);
|
|
2938
|
-
}
|
|
2939
|
-
elementListeners.get(element).add(callback);
|
|
2940
|
-
}
|
|
2941
|
-
function unobserve(element, callback) {
|
|
2942
|
-
if (elementListeners.has(element)) {
|
|
2943
|
-
elementListeners.get(element).delete(callback);
|
|
2944
|
-
if (!elementListeners.get(element).size) {
|
|
2945
|
-
resizeObserver.unobserve(element);
|
|
2946
|
-
elementListeners.delete(element);
|
|
2947
|
-
}
|
|
2948
|
-
}
|
|
2949
|
-
}
|
|
2950
|
-
|
|
2951
|
-
function _classCallCheck(instance, Constructor) {
|
|
2952
|
-
if (!(instance instanceof Constructor)) {
|
|
2953
|
-
throw new TypeError("Cannot call a class as a function");
|
|
2954
|
-
}
|
|
2955
|
-
}
|
|
2956
|
-
|
|
2957
|
-
function _defineProperties(target, props) {
|
|
2958
|
-
for (var i = 0; i < props.length; i++) {
|
|
2959
|
-
var descriptor = props[i];
|
|
2960
|
-
descriptor.enumerable = descriptor.enumerable || false;
|
|
2961
|
-
descriptor.configurable = true;
|
|
2962
|
-
if ("value" in descriptor) descriptor.writable = true;
|
|
2963
|
-
Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);
|
|
2964
|
-
}
|
|
2965
|
-
}
|
|
2966
|
-
function _createClass(Constructor, protoProps, staticProps) {
|
|
2967
|
-
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
2968
|
-
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
2969
|
-
Object.defineProperty(Constructor, "prototype", {
|
|
2970
|
-
writable: false
|
|
2971
|
-
});
|
|
2972
|
-
return Constructor;
|
|
2973
|
-
}
|
|
2974
|
-
|
|
2975
|
-
function _setPrototypeOf(o, p) {
|
|
2976
|
-
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
|
|
2977
|
-
o.__proto__ = p;
|
|
2978
|
-
return o;
|
|
2979
|
-
};
|
|
2980
|
-
return _setPrototypeOf(o, p);
|
|
2981
|
-
}
|
|
2982
|
-
|
|
2983
|
-
function _inherits(subClass, superClass) {
|
|
2984
|
-
if (typeof superClass !== "function" && superClass !== null) {
|
|
2985
|
-
throw new TypeError("Super expression must either be null or a function");
|
|
2986
|
-
}
|
|
2987
|
-
subClass.prototype = Object.create(superClass && superClass.prototype, {
|
|
2988
|
-
constructor: {
|
|
2989
|
-
value: subClass,
|
|
2990
|
-
writable: true,
|
|
2991
|
-
configurable: true
|
|
2992
|
-
}
|
|
2993
|
-
});
|
|
2994
|
-
Object.defineProperty(subClass, "prototype", {
|
|
2995
|
-
writable: false
|
|
2996
|
-
});
|
|
2997
|
-
if (superClass) _setPrototypeOf(subClass, superClass);
|
|
2998
|
-
}
|
|
2999
|
-
|
|
3000
|
-
function _getPrototypeOf(o) {
|
|
3001
|
-
_getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {
|
|
3002
|
-
return o.__proto__ || Object.getPrototypeOf(o);
|
|
3003
|
-
};
|
|
3004
|
-
return _getPrototypeOf(o);
|
|
3005
|
-
}
|
|
3006
|
-
|
|
3007
|
-
function _isNativeReflectConstruct() {
|
|
3008
|
-
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
3009
|
-
if (Reflect.construct.sham) return false;
|
|
3010
|
-
if (typeof Proxy === "function") return true;
|
|
3011
|
-
try {
|
|
3012
|
-
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
3013
|
-
return true;
|
|
3014
|
-
} catch (e) {
|
|
3015
|
-
return false;
|
|
3016
|
-
}
|
|
3017
|
-
}
|
|
3018
|
-
|
|
3019
|
-
function _assertThisInitialized(self) {
|
|
3020
|
-
if (self === void 0) {
|
|
3021
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
3022
|
-
}
|
|
3023
|
-
return self;
|
|
3024
|
-
}
|
|
3025
|
-
|
|
3026
|
-
function _possibleConstructorReturn(self, call) {
|
|
3027
|
-
if (call && (_typeof$1(call) === "object" || typeof call === "function")) {
|
|
3028
|
-
return call;
|
|
3029
|
-
} else if (call !== void 0) {
|
|
3030
|
-
throw new TypeError("Derived constructors may only return object or undefined");
|
|
3031
|
-
}
|
|
3032
|
-
return _assertThisInitialized(self);
|
|
3033
|
-
}
|
|
3034
|
-
|
|
3035
|
-
function _createSuper(Derived) {
|
|
3036
|
-
var hasNativeReflectConstruct = _isNativeReflectConstruct();
|
|
3037
|
-
return function _createSuperInternal() {
|
|
3038
|
-
var Super = _getPrototypeOf(Derived),
|
|
3039
|
-
result;
|
|
3040
|
-
if (hasNativeReflectConstruct) {
|
|
3041
|
-
var NewTarget = _getPrototypeOf(this).constructor;
|
|
3042
|
-
result = Reflect.construct(Super, arguments, NewTarget);
|
|
3043
|
-
} else {
|
|
3044
|
-
result = Super.apply(this, arguments);
|
|
3045
|
-
}
|
|
3046
|
-
return _possibleConstructorReturn(this, result);
|
|
3047
|
-
};
|
|
3048
|
-
}
|
|
3049
|
-
|
|
3050
|
-
/**
|
|
3051
|
-
* Fallback to findDOMNode if origin ref do not provide any dom element
|
|
3052
|
-
*/
|
|
3053
|
-
var DomWrapper = /*#__PURE__*/function (_React$Component) {
|
|
3054
|
-
_inherits(DomWrapper, _React$Component);
|
|
3055
|
-
var _super = _createSuper(DomWrapper);
|
|
3056
|
-
function DomWrapper() {
|
|
3057
|
-
_classCallCheck(this, DomWrapper);
|
|
3058
|
-
return _super.apply(this, arguments);
|
|
3059
|
-
}
|
|
3060
|
-
_createClass(DomWrapper, [{
|
|
3061
|
-
key: "render",
|
|
3062
|
-
value: function render() {
|
|
3063
|
-
return this.props.children;
|
|
3064
|
-
}
|
|
3065
|
-
}]);
|
|
3066
|
-
return DomWrapper;
|
|
3067
|
-
}(react.Component);
|
|
3068
|
-
|
|
3069
|
-
var CollectionContext = /*#__PURE__*/react.createContext(null);
|
|
3070
|
-
/**
|
|
3071
|
-
* Collect all the resize event from children ResizeObserver
|
|
3072
|
-
*/
|
|
3073
|
-
function Collection(_ref) {
|
|
3074
|
-
var children = _ref.children,
|
|
3075
|
-
onBatchResize = _ref.onBatchResize;
|
|
3076
|
-
var resizeIdRef = react.useRef(0);
|
|
3077
|
-
var resizeInfosRef = react.useRef([]);
|
|
3078
|
-
var onCollectionResize = react.useContext(CollectionContext);
|
|
3079
|
-
var onResize = react.useCallback(function (size, element, data) {
|
|
3080
|
-
resizeIdRef.current += 1;
|
|
3081
|
-
var currentId = resizeIdRef.current;
|
|
3082
|
-
resizeInfosRef.current.push({
|
|
3083
|
-
size: size,
|
|
3084
|
-
element: element,
|
|
3085
|
-
data: data
|
|
3086
|
-
});
|
|
3087
|
-
Promise.resolve().then(function () {
|
|
3088
|
-
if (currentId === resizeIdRef.current) {
|
|
3089
|
-
onBatchResize === null || onBatchResize === void 0 ? void 0 : onBatchResize(resizeInfosRef.current);
|
|
3090
|
-
resizeInfosRef.current = [];
|
|
3091
|
-
}
|
|
3092
|
-
});
|
|
3093
|
-
// Continue bubbling if parent exist
|
|
3094
|
-
onCollectionResize === null || onCollectionResize === void 0 ? void 0 : onCollectionResize(size, element, data);
|
|
3095
|
-
}, [onBatchResize, onCollectionResize]);
|
|
3096
|
-
return /*#__PURE__*/react.createElement(CollectionContext.Provider, {
|
|
3097
|
-
value: onResize
|
|
3098
|
-
}, children);
|
|
3099
|
-
}
|
|
3100
|
-
|
|
3101
|
-
function SingleObserver(props, ref) {
|
|
3102
|
-
var children = props.children,
|
|
3103
|
-
disabled = props.disabled;
|
|
3104
|
-
var elementRef = react.useRef(null);
|
|
3105
|
-
var wrapperRef = react.useRef(null);
|
|
3106
|
-
var onCollectionResize = react.useContext(CollectionContext);
|
|
3107
|
-
// =========================== Children ===========================
|
|
3108
|
-
var isRenderProps = typeof children === 'function';
|
|
3109
|
-
var mergedChildren = isRenderProps ? children(elementRef) : children;
|
|
3110
|
-
// ============================= Size =============================
|
|
3111
|
-
var sizeRef = react.useRef({
|
|
3112
|
-
width: -1,
|
|
3113
|
-
height: -1,
|
|
3114
|
-
offsetWidth: -1,
|
|
3115
|
-
offsetHeight: -1
|
|
3116
|
-
});
|
|
3117
|
-
// ============================= Ref ==============================
|
|
3118
|
-
var canRef = !isRenderProps && /*#__PURE__*/react.isValidElement(mergedChildren) && supportRef(mergedChildren);
|
|
3119
|
-
var originRef = canRef ? mergedChildren.ref : null;
|
|
3120
|
-
var mergedRef = react.useMemo(function () {
|
|
3121
|
-
return composeRef(originRef, elementRef);
|
|
3122
|
-
}, [originRef, elementRef]);
|
|
3123
|
-
var getDom = function getDom() {
|
|
3124
|
-
return findDOMNode(elementRef.current) || findDOMNode(wrapperRef.current);
|
|
3125
|
-
};
|
|
3126
|
-
react.useImperativeHandle(ref, function () {
|
|
3127
|
-
return getDom();
|
|
3128
|
-
});
|
|
3129
|
-
// =========================== Observe ============================
|
|
3130
|
-
var propsRef = react.useRef(props);
|
|
3131
|
-
propsRef.current = props;
|
|
3132
|
-
// Handler
|
|
3133
|
-
var onInternalResize = react.useCallback(function (target) {
|
|
3134
|
-
var _propsRef$current = propsRef.current,
|
|
3135
|
-
onResize = _propsRef$current.onResize,
|
|
3136
|
-
data = _propsRef$current.data;
|
|
3137
|
-
var _target$getBoundingCl = target.getBoundingClientRect(),
|
|
3138
|
-
width = _target$getBoundingCl.width,
|
|
3139
|
-
height = _target$getBoundingCl.height;
|
|
3140
|
-
var offsetWidth = target.offsetWidth,
|
|
3141
|
-
offsetHeight = target.offsetHeight;
|
|
3142
|
-
/**
|
|
3143
|
-
* Resize observer trigger when content size changed.
|
|
3144
|
-
* In most case we just care about element size,
|
|
3145
|
-
* let's use `boundary` instead of `contentRect` here to avoid shaking.
|
|
3146
|
-
*/
|
|
3147
|
-
var fixedWidth = Math.floor(width);
|
|
3148
|
-
var fixedHeight = Math.floor(height);
|
|
3149
|
-
if (sizeRef.current.width !== fixedWidth || sizeRef.current.height !== fixedHeight || sizeRef.current.offsetWidth !== offsetWidth || sizeRef.current.offsetHeight !== offsetHeight) {
|
|
3150
|
-
var size = {
|
|
3151
|
-
width: fixedWidth,
|
|
3152
|
-
height: fixedHeight,
|
|
3153
|
-
offsetWidth: offsetWidth,
|
|
3154
|
-
offsetHeight: offsetHeight
|
|
3155
|
-
};
|
|
3156
|
-
sizeRef.current = size;
|
|
3157
|
-
// IE is strange, right?
|
|
3158
|
-
var mergedOffsetWidth = offsetWidth === Math.round(width) ? width : offsetWidth;
|
|
3159
|
-
var mergedOffsetHeight = offsetHeight === Math.round(height) ? height : offsetHeight;
|
|
3160
|
-
var sizeInfo = _objectSpread2(_objectSpread2({}, size), {}, {
|
|
3161
|
-
offsetWidth: mergedOffsetWidth,
|
|
3162
|
-
offsetHeight: mergedOffsetHeight
|
|
3163
|
-
});
|
|
3164
|
-
// Let collection know what happened
|
|
3165
|
-
onCollectionResize === null || onCollectionResize === void 0 ? void 0 : onCollectionResize(sizeInfo, target, data);
|
|
3166
|
-
if (onResize) {
|
|
3167
|
-
// defer the callback but not defer to next frame
|
|
3168
|
-
Promise.resolve().then(function () {
|
|
3169
|
-
onResize(sizeInfo, target);
|
|
3170
|
-
});
|
|
3171
|
-
}
|
|
3172
|
-
}
|
|
3173
|
-
}, []);
|
|
3174
|
-
// Dynamic observe
|
|
3175
|
-
react.useEffect(function () {
|
|
3176
|
-
var currentElement = getDom();
|
|
3177
|
-
if (currentElement && !disabled) {
|
|
3178
|
-
observe(currentElement, onInternalResize);
|
|
3179
|
-
}
|
|
3180
|
-
return function () {
|
|
3181
|
-
return unobserve(currentElement, onInternalResize);
|
|
3182
|
-
};
|
|
3183
|
-
}, [elementRef.current, disabled]);
|
|
3184
|
-
// ============================ Render ============================
|
|
3185
|
-
return /*#__PURE__*/react.createElement(DomWrapper, {
|
|
3186
|
-
ref: wrapperRef
|
|
3187
|
-
}, canRef ? /*#__PURE__*/react.cloneElement(mergedChildren, {
|
|
3188
|
-
ref: mergedRef
|
|
3189
|
-
}) : mergedChildren);
|
|
3190
|
-
}
|
|
3191
|
-
var RefSingleObserver = /*#__PURE__*/react.forwardRef(SingleObserver);
|
|
3192
|
-
|
|
3193
|
-
var INTERNAL_PREFIX_KEY = 'rc-observer-key';
|
|
3194
|
-
function ResizeObserver(props, ref) {
|
|
3195
|
-
var children = props.children;
|
|
3196
|
-
var childNodes = typeof children === 'function' ? [children] : toArray(children);
|
|
3197
|
-
return childNodes.map(function (child, index) {
|
|
3198
|
-
var key = (child === null || child === void 0 ? void 0 : child.key) || "".concat(INTERNAL_PREFIX_KEY, "-").concat(index);
|
|
3199
|
-
return /*#__PURE__*/react.createElement(RefSingleObserver, _extends({}, props, {
|
|
3200
|
-
key: key,
|
|
3201
|
-
ref: index === 0 ? ref : undefined
|
|
3202
|
-
}), child);
|
|
3203
|
-
});
|
|
3204
|
-
}
|
|
3205
|
-
var RefResizeObserver = /*#__PURE__*/react.forwardRef(ResizeObserver);
|
|
3206
|
-
RefResizeObserver.Collection = Collection;
|
|
3207
|
-
|
|
3208
|
-
function canUseDom() {
|
|
3209
|
-
return !!(typeof window !== 'undefined' && window.document && window.document.createElement);
|
|
3210
|
-
}
|
|
3211
|
-
|
|
3212
|
-
/**
|
|
3213
|
-
* Wrap `React.useLayoutEffect` which will not throw warning message in test env
|
|
3214
|
-
*/
|
|
3215
|
-
var useInternalLayoutEffect = canUseDom() ? react.useLayoutEffect : react.useEffect;
|
|
3216
|
-
var useLayoutEffect = function useLayoutEffect(callback, deps) {
|
|
3217
|
-
var firstMountRef = react.useRef(true);
|
|
3218
|
-
useInternalLayoutEffect(function () {
|
|
3219
|
-
return callback(firstMountRef.current);
|
|
3220
|
-
}, deps);
|
|
3221
|
-
|
|
3222
|
-
// We tell react that first mount has passed
|
|
3223
|
-
useInternalLayoutEffect(function () {
|
|
3224
|
-
firstMountRef.current = false;
|
|
3225
|
-
return function () {
|
|
3226
|
-
firstMountRef.current = true;
|
|
3227
|
-
};
|
|
3228
|
-
}, []);
|
|
3229
|
-
};
|
|
3230
|
-
|
|
3231
1771
|
var _excluded$2 = ["prefixCls", "invalidate", "item", "renderItem", "responsive", "responsiveDisabled", "registerSize", "itemKey", "className", "style", "children", "display", "order", "component"];
|
|
3232
1772
|
// Use shared variable to save bundle size
|
|
3233
1773
|
var UNDEFINED = undefined;
|
|
@@ -3275,9 +1815,9 @@ function InternalItem(props, ref) {
|
|
|
3275
1815
|
if (mergedHidden) {
|
|
3276
1816
|
overflowProps['aria-hidden'] = true;
|
|
3277
1817
|
}
|
|
3278
|
-
var itemNode = /*#__PURE__*/react.createElement(Component, _extends
|
|
1818
|
+
var itemNode = /*#__PURE__*/react.createElement(Component, _extends({
|
|
3279
1819
|
className: classnames(!invalidate && prefixCls, className),
|
|
3280
|
-
style: _objectSpread2
|
|
1820
|
+
style: _objectSpread2(_objectSpread2({}, overflowStyle), style)
|
|
3281
1821
|
}, overflowProps, restProps, {
|
|
3282
1822
|
ref: ref
|
|
3283
1823
|
}), childNode);
|
|
@@ -3295,68 +1835,6 @@ function InternalItem(props, ref) {
|
|
|
3295
1835
|
var Item = /*#__PURE__*/react.forwardRef(InternalItem);
|
|
3296
1836
|
Item.displayName = 'Item';
|
|
3297
1837
|
|
|
3298
|
-
function useEvent(callback) {
|
|
3299
|
-
var fnRef = react.useRef();
|
|
3300
|
-
fnRef.current = callback;
|
|
3301
|
-
var memoFn = react.useCallback(function () {
|
|
3302
|
-
var _fnRef$current;
|
|
3303
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
3304
|
-
args[_key] = arguments[_key];
|
|
3305
|
-
}
|
|
3306
|
-
return (_fnRef$current = fnRef.current) === null || _fnRef$current === void 0 ? void 0 : _fnRef$current.call.apply(_fnRef$current, [fnRef].concat(args));
|
|
3307
|
-
}, []);
|
|
3308
|
-
return memoFn;
|
|
3309
|
-
}
|
|
3310
|
-
|
|
3311
|
-
var raf = function raf(callback) {
|
|
3312
|
-
return +setTimeout(callback, 16);
|
|
3313
|
-
};
|
|
3314
|
-
var caf = function caf(num) {
|
|
3315
|
-
return clearTimeout(num);
|
|
3316
|
-
};
|
|
3317
|
-
if (typeof window !== 'undefined' && 'requestAnimationFrame' in window) {
|
|
3318
|
-
raf = function raf(callback) {
|
|
3319
|
-
return window.requestAnimationFrame(callback);
|
|
3320
|
-
};
|
|
3321
|
-
caf = function caf(handle) {
|
|
3322
|
-
return window.cancelAnimationFrame(handle);
|
|
3323
|
-
};
|
|
3324
|
-
}
|
|
3325
|
-
var rafUUID = 0;
|
|
3326
|
-
var rafIds = new Map();
|
|
3327
|
-
function cleanup(id) {
|
|
3328
|
-
rafIds.delete(id);
|
|
3329
|
-
}
|
|
3330
|
-
var wrapperRaf = function wrapperRaf(callback) {
|
|
3331
|
-
var times = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
|
|
3332
|
-
rafUUID += 1;
|
|
3333
|
-
var id = rafUUID;
|
|
3334
|
-
function callRef(leftTimes) {
|
|
3335
|
-
if (leftTimes === 0) {
|
|
3336
|
-
// Clean up
|
|
3337
|
-
cleanup(id);
|
|
3338
|
-
|
|
3339
|
-
// Trigger
|
|
3340
|
-
callback();
|
|
3341
|
-
} else {
|
|
3342
|
-
// Next raf
|
|
3343
|
-
var realId = raf(function () {
|
|
3344
|
-
callRef(leftTimes - 1);
|
|
3345
|
-
});
|
|
3346
|
-
|
|
3347
|
-
// Bind real raf id
|
|
3348
|
-
rafIds.set(id, realId);
|
|
3349
|
-
}
|
|
3350
|
-
}
|
|
3351
|
-
callRef(times);
|
|
3352
|
-
return id;
|
|
3353
|
-
};
|
|
3354
|
-
wrapperRaf.cancel = function (id) {
|
|
3355
|
-
var realId = rafIds.get(id);
|
|
3356
|
-
cleanup(realId);
|
|
3357
|
-
return caf(realId);
|
|
3358
|
-
};
|
|
3359
|
-
|
|
3360
1838
|
function channelUpdate(callback) {
|
|
3361
1839
|
if (typeof MessageChannel === 'undefined') {
|
|
3362
1840
|
wrapperRaf(callback);
|
|
@@ -3422,7 +1900,7 @@ var InternalRawItem = function InternalRawItem(props, ref) {
|
|
|
3422
1900
|
var _props$component = props.component,
|
|
3423
1901
|
Component = _props$component === void 0 ? 'div' : _props$component,
|
|
3424
1902
|
_restProps = _objectWithoutProperties(props, _excluded$1);
|
|
3425
|
-
return /*#__PURE__*/react.createElement(Component, _extends
|
|
1903
|
+
return /*#__PURE__*/react.createElement(Component, _extends({}, _restProps, {
|
|
3426
1904
|
ref: ref
|
|
3427
1905
|
}));
|
|
3428
1906
|
}
|
|
@@ -3433,7 +1911,7 @@ var InternalRawItem = function InternalRawItem(props, ref) {
|
|
|
3433
1911
|
// Do not pass context to sub item to avoid multiple measure
|
|
3434
1912
|
return /*#__PURE__*/react.createElement(OverflowContext.Provider, {
|
|
3435
1913
|
value: null
|
|
3436
|
-
}, /*#__PURE__*/react.createElement(Item, _extends
|
|
1914
|
+
}, /*#__PURE__*/react.createElement(Item, _extends({
|
|
3437
1915
|
ref: ref,
|
|
3438
1916
|
className: classnames(contextClassName, className)
|
|
3439
1917
|
}, restContext, restProps)));
|
|
@@ -3656,7 +2134,7 @@ function Overflow(props, ref) {
|
|
|
3656
2134
|
var key = getKey(item, index);
|
|
3657
2135
|
return /*#__PURE__*/react.createElement(OverflowContext.Provider, {
|
|
3658
2136
|
key: key,
|
|
3659
|
-
value: _objectSpread2
|
|
2137
|
+
value: _objectSpread2(_objectSpread2({}, itemSharedProps), {}, {
|
|
3660
2138
|
order: index,
|
|
3661
2139
|
item: item,
|
|
3662
2140
|
itemKey: key,
|
|
@@ -3666,7 +2144,7 @@ function Overflow(props, ref) {
|
|
|
3666
2144
|
}, renderRawItem(item, index));
|
|
3667
2145
|
} : function (item, index) {
|
|
3668
2146
|
var key = getKey(item, index);
|
|
3669
|
-
return /*#__PURE__*/react.createElement(Item, _extends
|
|
2147
|
+
return /*#__PURE__*/react.createElement(Item, _extends({}, itemSharedProps, {
|
|
3670
2148
|
order: index,
|
|
3671
2149
|
key: key,
|
|
3672
2150
|
item: item,
|
|
@@ -3686,17 +2164,17 @@ function Overflow(props, ref) {
|
|
|
3686
2164
|
};
|
|
3687
2165
|
if (!renderRawRest) {
|
|
3688
2166
|
var mergedRenderRest = renderRest || defaultRenderRest;
|
|
3689
|
-
restNode = /*#__PURE__*/react.createElement(Item, _extends
|
|
2167
|
+
restNode = /*#__PURE__*/react.createElement(Item, _extends({}, itemSharedProps, restContextProps), typeof mergedRenderRest === 'function' ? mergedRenderRest(omittedItems) : mergedRenderRest);
|
|
3690
2168
|
} else if (renderRawRest) {
|
|
3691
2169
|
restNode = /*#__PURE__*/react.createElement(OverflowContext.Provider, {
|
|
3692
|
-
value: _objectSpread2
|
|
2170
|
+
value: _objectSpread2(_objectSpread2({}, itemSharedProps), restContextProps)
|
|
3693
2171
|
}, renderRawRest(omittedItems));
|
|
3694
2172
|
}
|
|
3695
|
-
var overflowNode = /*#__PURE__*/react.createElement(Component, _extends
|
|
2173
|
+
var overflowNode = /*#__PURE__*/react.createElement(Component, _extends({
|
|
3696
2174
|
className: classnames(!invalidate && prefixCls, className),
|
|
3697
2175
|
style: style,
|
|
3698
2176
|
ref: ref
|
|
3699
|
-
}, restProps), mergedData.map(internalRenderItemNode), showRest ? restNode : null, suffix && /*#__PURE__*/react.createElement(Item, _extends
|
|
2177
|
+
}, restProps), mergedData.map(internalRenderItemNode), showRest ? restNode : null, suffix && /*#__PURE__*/react.createElement(Item, _extends({}, itemSharedProps, {
|
|
3700
2178
|
responsive: isResponsive,
|
|
3701
2179
|
responsiveDisabled: !shouldResponsive,
|
|
3702
2180
|
order: mergedDisplayCount,
|
|
@@ -4008,7 +2486,7 @@ const BcmSearch = class {
|
|
|
4008
2486
|
}
|
|
4009
2487
|
render() {
|
|
4010
2488
|
const { _id, placeholder, disabled, readonly } = this;
|
|
4011
|
-
return h
|
|
2489
|
+
return h(Host, { onClick: () => { this.onBcmFocus(); this.onBcmSelect(); } }, h(InputTemplate, { size: this.size, id: _id, type: "search", placeholder: placeholder, disabled: disabled, "full-width": true, readonly: readonly, clearable: this.isActiveClearable, handleFocus: () => this.handleFocus(), handleBlur: () => this.handleBlur(), handleChange: () => this.handleChange(), handleClear: () => this.handleClear(), handleInput: this.debounceHandler, ref: (el) => this.inputElement = el }));
|
|
4012
2490
|
}
|
|
4013
2491
|
get el() { return getElement(this); }
|
|
4014
2492
|
static get watchers() { return {
|