@dropi/ui 0.1.37 → 0.1.42
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/assets/icons/symbol/svg/sprite.css.svg +1 -1
- package/dist/cjs/dropi-accordion-item.cjs.entry.js +2 -2
- package/dist/cjs/dropi-accordion.cjs.entry.js +2 -2
- package/dist/cjs/dropi-alert-legacy.cjs.entry.js +1 -1
- package/dist/cjs/dropi-alert-modal.cjs.entry.js +20 -16
- package/dist/cjs/dropi-alert.cjs.entry.js +12 -12
- package/dist/cjs/dropi-avatars.cjs.entry.js +1 -1
- package/dist/cjs/dropi-badge-legacy.cjs.entry.js +2 -2
- package/dist/cjs/dropi-badge.cjs.entry.js +1 -1
- package/dist/cjs/dropi-banner-external.cjs.entry.js +4 -4
- package/dist/cjs/dropi-breadcrumb.cjs.entry.js +4 -4
- package/dist/cjs/dropi-button.cjs.entry.js +7 -7
- package/dist/cjs/dropi-card-checkbox.cjs.entry.js +6 -6
- package/dist/cjs/dropi-card-product.cjs.entry.js +12 -12
- package/dist/cjs/dropi-card-section.cjs.entry.js +9 -9
- package/dist/cjs/dropi-carousel.cjs.entry.js +8 -8
- package/dist/cjs/dropi-checkbox-selection-list.cjs.entry.js +9 -9
- package/dist/cjs/dropi-checkbox.cjs.entry.js +6 -6
- package/dist/cjs/dropi-chips.cjs.entry.js +4 -4
- package/dist/cjs/dropi-city-selector.cjs.entry.js +4 -4
- package/dist/cjs/dropi-color-picker.cjs.entry.js +4 -4
- package/dist/cjs/dropi-country-flags.cjs.entry.js +2 -2
- package/dist/cjs/dropi-country-selector.cjs.entry.js +6 -6
- package/dist/cjs/dropi-date-picker-range.cjs.entry.js +4 -4
- package/dist/cjs/dropi-date-picker.cjs.entry.js +12 -12
- package/dist/cjs/dropi-drawer.cjs.entry.js +4 -4
- package/dist/cjs/dropi-dropdown.cjs.entry.js +2 -2
- package/dist/cjs/dropi-empty-state.cjs.entry.js +3 -3
- package/dist/cjs/dropi-favorite-button.cjs.entry.js +3 -3
- package/dist/cjs/dropi-file-upload-progress-bar.cjs.entry.js +5 -5
- package/dist/cjs/dropi-file-upload.cjs.entry.js +4 -4
- package/dist/cjs/dropi-icon.cjs.entry.js +33 -21
- package/dist/cjs/dropi-ilustration-icon.cjs.entry.js +5 -5
- package/dist/cjs/dropi-image-miniature.cjs.entry.js +3 -3
- package/dist/cjs/dropi-image-overlay.cjs.entry.js +3 -3
- package/dist/cjs/dropi-input_3.cjs.entry.js +56 -26
- package/dist/cjs/dropi-languages-selector.cjs.entry.js +5 -5
- package/dist/cjs/dropi-logo.cjs.entry.js +2 -2
- package/dist/cjs/dropi-lottie-loader.cjs.entry.js +1 -1
- package/dist/cjs/dropi-media-player.cjs.entry.js +5 -5
- package/dist/cjs/dropi-modal.cjs.entry.js +38 -33
- package/dist/cjs/dropi-navbar.cjs.entry.js +7 -7
- package/dist/cjs/dropi-otp-send-code.cjs.entry.js +43 -20
- package/dist/cjs/dropi-phone-input.cjs.entry.js +14 -14
- package/dist/cjs/dropi-progress-bar.cjs.entry.js +43 -0
- package/dist/cjs/dropi-radio-button.cjs.entry.js +5 -5
- package/dist/cjs/dropi-radio-selection-list.cjs.entry.js +9 -9
- package/dist/cjs/dropi-read-more.cjs.entry.js +2 -2
- package/dist/cjs/dropi-search.cjs.entry.js +21 -21
- package/dist/cjs/dropi-select.cjs.entry.js +55 -27
- package/dist/cjs/dropi-sidebar.cjs.entry.js +8 -8
- package/dist/cjs/dropi-simple-stepper.cjs.entry.js +1 -1
- package/dist/cjs/dropi-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/dropi-steps.cjs.entry.js +2 -2
- package/dist/cjs/dropi-switch.cjs.entry.js +5 -5
- package/dist/cjs/dropi-table.cjs.entry.js +41 -33
- package/dist/cjs/dropi-tabs.cjs.entry.js +6 -6
- package/dist/cjs/dropi-tag-type-product.cjs.entry.js +2 -2
- package/dist/cjs/dropi-text-area.cjs.entry.js +7 -7
- package/dist/cjs/dropi-time-line.cjs.entry.js +3 -3
- package/dist/cjs/dropi-toast.cjs.entry.js +2 -2
- package/dist/cjs/dropi-tooltip-v2.cjs.entry.js +3 -3
- package/dist/cjs/dropi-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/dropi-ui.cjs.js +2 -2
- package/dist/cjs/dropi-vertical-steps.cjs.entry.js +4 -4
- package/dist/cjs/dropi-youtube-lazy-video.cjs.entry.js +2 -2
- package/dist/cjs/index-CEWSDq65.js +2773 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/assets/icons/symbol/svg/sprite.css.svg +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/dropi-accordion/dropi-accordion-item.js +1 -1
- package/dist/collection/components/dropi-accordion/dropi-accordion.js +1 -1
- package/dist/collection/components/dropi-alert/dropi-alert.js +16 -16
- package/dist/collection/components/dropi-alert-modal/dropi-alert-modal.js +43 -19
- package/dist/collection/components/dropi-badge-legacy/dropi-badge-legacy.js +1 -1
- package/dist/collection/components/dropi-banner-external/dropi-banner-external.js +1 -1
- package/dist/collection/components/dropi-breadcrumb/dropi-breadcrumb.js +2 -2
- package/dist/collection/components/dropi-button/dropi-button.css +6 -3
- package/dist/collection/components/dropi-button/dropi-button.js +6 -6
- package/dist/collection/components/dropi-card-checkbox/dropi-card-checkbox.js +6 -6
- package/dist/collection/components/dropi-card-product/dropi-card-product.js +11 -11
- package/dist/collection/components/dropi-card-section/dropi-card-section.js +10 -10
- package/dist/collection/components/dropi-carousel/dropi-carousel.js +9 -9
- package/dist/collection/components/dropi-checkbox/dropi-checkbox.js +6 -6
- package/dist/collection/components/dropi-checkbox-selection-list/dropi-checkbox-selection-list.js +10 -10
- package/dist/collection/components/dropi-chips/dropi-chips.js +4 -4
- package/dist/collection/components/dropi-city-selector/dropi-city-selector.js +2 -2
- package/dist/collection/components/dropi-color-picker/dropi-color-picker.js +2 -2
- package/dist/collection/components/dropi-country-flags/dropi-country-flags.js +1 -1
- package/dist/collection/components/dropi-country-selector/dropi-country-selector.js +6 -6
- package/dist/collection/components/dropi-date-picker/dropi-date-picker.js +12 -12
- package/dist/collection/components/dropi-drawer/dropi-drawer.js +2 -2
- package/dist/collection/components/dropi-empty-state/dropi-empty-state.js +1 -1
- package/dist/collection/components/dropi-favorite-button/dropi-favorite-button.js +1 -1
- package/dist/collection/components/dropi-file-upload/dropi-file-upload.js +2 -2
- package/dist/collection/components/dropi-file-upload-progress-bar/dropi-file-upload-progress-bar.js +1 -1
- package/dist/collection/components/dropi-icon/dropi-icon.css +2 -2
- package/dist/collection/components/dropi-icon/dropi-icon.js +59 -27
- package/dist/collection/components/dropi-ilustration-icon/dropi-ilustration-icon.js +4 -4
- package/dist/collection/components/dropi-image-miniature/dropi-image-miniature.js +1 -1
- package/dist/collection/components/dropi-image-overlay/dropi-image-overlay.js +1 -1
- package/dist/collection/components/dropi-input/dropi-input.css +13 -5
- package/dist/collection/components/dropi-input/dropi-input.js +25 -23
- package/dist/collection/components/dropi-languages-selector/dropi-languages-selector.js +5 -5
- package/dist/collection/components/dropi-logo/dropi-logo.js +1 -1
- package/dist/collection/components/dropi-media-player/dropi-media-player.js +2 -2
- package/dist/collection/components/dropi-modal/dropi-modal.css +12 -6
- package/dist/collection/components/dropi-modal/dropi-modal.js +50 -45
- package/dist/collection/components/dropi-navbar/dropi-navbar.js +2 -2
- package/dist/collection/components/dropi-otp-send-code/dropi-otp-send-code.js +77 -19
- package/dist/collection/components/dropi-paginator/dropi-paginator.js +6 -6
- package/dist/collection/components/dropi-phone-input/dropi-phone-input.js +17 -17
- package/dist/collection/components/dropi-progress-bar/dropi-progress-bar.css +35 -0
- package/dist/collection/components/dropi-progress-bar/dropi-progress-bar.js +168 -0
- package/dist/collection/components/dropi-radio-button/dropi-radio-button.js +5 -5
- package/dist/collection/components/dropi-radio-selection-list/dropi-radio-selection-list.js +10 -10
- package/dist/collection/components/dropi-read-more/dropi-read-more.js +1 -1
- package/dist/collection/components/dropi-search/dropi-search.js +26 -26
- package/dist/collection/components/dropi-select/dropi-select.css +4 -0
- package/dist/collection/components/dropi-select/dropi-select.js +90 -30
- package/dist/collection/components/dropi-sidebar/dropi-sidebar.js +8 -8
- package/dist/collection/components/dropi-steps/dropi-steps.js +1 -1
- package/dist/collection/components/dropi-switch/dropi-switch.js +5 -5
- package/dist/collection/components/dropi-table/dropi-table.js +40 -32
- package/dist/collection/components/dropi-tabs/dropi-tabs.js +6 -6
- package/dist/collection/components/dropi-tag/dropi-tag.css +16 -7
- package/dist/collection/components/dropi-tag/dropi-tag.js +55 -1
- package/dist/collection/components/dropi-tag-type-product/dropi-tag-type-product.js +1 -1
- package/dist/collection/components/dropi-text-area/dropi-text-area.js +2 -2
- package/dist/collection/components/dropi-time-line/dropi-time-line.js +2 -2
- package/dist/collection/components/dropi-toast/dropi-toast.js +1 -1
- package/dist/collection/components/dropi-tooltip/dropi-tooltip.js +1 -1
- package/dist/collection/components/dropi-tooltip-v2/dropi-tooltip.js +2 -2
- package/dist/collection/components/dropi-vertical-steps/dropi-vertical-steps.js +2 -2
- package/dist/collection/components/dropi-youtube-lazy-video/dropi-youtube-lazy-video.js +1 -1
- package/dist/components/dropi-accordion-item.js +1 -1
- package/dist/components/dropi-accordion.js +1 -1
- package/dist/components/dropi-alert-modal.js +1 -1
- package/dist/components/dropi-alert.js +1 -1
- package/dist/components/dropi-badge-legacy.js +1 -1
- package/dist/components/dropi-banner-external.js +1 -1
- package/dist/components/dropi-breadcrumb.js +1 -1
- package/dist/components/dropi-button.js +1 -1
- package/dist/components/dropi-card-checkbox.js +1 -1
- package/dist/components/dropi-card-product.js +1 -1
- package/dist/components/dropi-card-section.js +1 -1
- package/dist/components/dropi-carousel.js +1 -1
- package/dist/components/dropi-checkbox-selection-list.js +1 -1
- package/dist/components/dropi-checkbox.js +1 -1
- package/dist/components/dropi-chips.js +1 -1
- package/dist/components/dropi-city-selector.js +1 -1
- package/dist/components/dropi-color-picker.js +1 -1
- package/dist/components/dropi-country-flags.js +1 -1
- package/dist/components/dropi-country-selector.js +1 -1
- package/dist/components/dropi-date-picker-range.js +1 -1
- package/dist/components/dropi-date-picker.js +1 -1
- package/dist/components/dropi-drawer.js +1 -1
- package/dist/components/dropi-dropdown.js +1 -1
- package/dist/components/dropi-empty-state.js +1 -1
- package/dist/components/dropi-favorite-button.js +1 -1
- package/dist/components/dropi-file-upload-progress-bar.js +1 -1
- package/dist/components/dropi-file-upload.js +1 -1
- package/dist/components/dropi-icon.js +1 -1
- package/dist/components/dropi-ilustration-icon.js +1 -1
- package/dist/components/dropi-image-miniature.js +1 -1
- package/dist/components/dropi-image-overlay.js +1 -1
- package/dist/components/dropi-input.js +1 -1
- package/dist/components/dropi-languages-selector.js +1 -1
- package/dist/components/dropi-logo.js +1 -1
- package/dist/components/dropi-media-player.js +1 -1
- package/dist/components/dropi-modal.js +1 -1
- package/dist/components/dropi-navbar.js +1 -1
- package/dist/components/dropi-otp-send-code.js +1 -1
- package/dist/components/dropi-paginator.js +1 -1
- package/dist/components/dropi-phone-input.js +1 -1
- package/dist/components/dropi-progress-bar.d.ts +11 -0
- package/dist/components/dropi-progress-bar.js +1 -0
- package/dist/components/dropi-radio-button.js +1 -1
- package/dist/components/dropi-radio-selection-list.js +1 -1
- package/dist/components/dropi-read-more.js +1 -1
- package/dist/components/dropi-search.js +1 -1
- package/dist/components/dropi-select.js +1 -1
- package/dist/components/dropi-sidebar.js +1 -1
- package/dist/components/dropi-steps.js +1 -1
- package/dist/components/dropi-switch.js +1 -1
- package/dist/components/dropi-table.js +1 -1
- package/dist/components/dropi-tabs.js +1 -1
- package/dist/components/dropi-tag-type-product.js +1 -1
- package/dist/components/dropi-tag.js +1 -1
- package/dist/components/dropi-text-area.js +1 -1
- package/dist/components/dropi-time-line.js +1 -1
- package/dist/components/dropi-toast.js +1 -1
- package/dist/components/dropi-tooltip-v2.js +1 -1
- package/dist/components/dropi-tooltip.js +1 -1
- package/dist/components/dropi-vertical-steps.js +1 -1
- package/dist/components/dropi-youtube-lazy-video.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/p-1YjHPRto.js +1 -0
- package/dist/components/p-2YgFOle2.js +1 -0
- package/dist/components/p-9CkX3ALN.js +1 -0
- package/dist/components/p-B9-h_ikq.js +1 -0
- package/dist/components/p-B9rJd-Rf.js +1 -0
- package/dist/components/p-BDYn1JDe.js +1 -0
- package/dist/components/p-BGb7xtJN.js +1 -0
- package/dist/components/p-BHV6BYSS.js +1 -0
- package/dist/components/p-BKTMBQVw.js +1 -0
- package/dist/components/p-BSB5Ar-y.js +1 -0
- package/dist/components/p-BSHROiHb.js +1 -0
- package/dist/components/p-BT99axEq.js +1 -0
- package/dist/components/p-BVgUVZyu.js +1 -0
- package/dist/components/p-BhRjfHZ3.js +1 -0
- package/dist/components/p-Bimspdte.js +1 -0
- package/dist/components/p-BmuWhHN-.js +1 -0
- package/dist/components/p-BqJ52YOH.js +1 -0
- package/dist/components/p-BrR1YjVi.js +1 -0
- package/dist/components/p-BrnGRyf0.js +1 -0
- package/dist/components/p-BtkDdEAq.js +1 -0
- package/dist/components/p-Btsw7sPN.js +1 -0
- package/dist/components/p-BvIwy9Yl.js +1 -0
- package/dist/components/p-BzCPv3ND.js +1 -0
- package/dist/components/p-C44-ijf2.js +1 -0
- package/dist/components/p-CHb992Wr.js +1 -0
- package/dist/components/p-CJ4s6SQT.js +1 -0
- package/dist/components/p-CKflT57p.js +1 -0
- package/dist/components/p-CWT7wT9m.js +1 -0
- package/dist/components/p-CWWFRdg7.js +1 -0
- package/dist/components/p-CWwDNt3V.js +1 -0
- package/dist/components/p-CXUiN3Rj.js +1 -0
- package/dist/components/p-C_zOkGR5.js +1 -0
- package/dist/components/p-CgRY3n1J.js +1 -0
- package/dist/components/p-Cjq4FTif.js +1 -0
- package/dist/components/p-Cujt3jky.js +1 -0
- package/dist/components/p-D5UeShUa.js +1 -0
- package/dist/components/p-D7GP-lmt.js +1 -0
- package/dist/components/p-DFNI0UID.js +1 -0
- package/dist/components/p-DG5fe-Ke.js +1 -0
- package/dist/components/p-DKWuIsc_.js +1 -0
- package/dist/components/p-DLyzE3Kh.js +1 -0
- package/dist/components/p-DN_IcU8H.js +1 -0
- package/dist/components/p-DON3zW51.js +1 -0
- package/dist/components/p-DQzskhll.js +1 -0
- package/dist/components/p-DYAsdhfM.js +1 -0
- package/dist/components/p-DYYToiO9.js +1 -0
- package/dist/components/p-DehWQyi5.js +1 -0
- package/dist/components/p-DfSe-tBr.js +1 -0
- package/dist/components/p-DfdhNT9F.js +1 -0
- package/dist/components/p-Dgeh9Yg8.js +1 -0
- package/dist/components/p-DlaiuH5K.js +1 -0
- package/dist/components/p-DvLWbKsf.js +1 -0
- package/dist/components/p-DvaFep4Y.js +1 -0
- package/dist/components/p-Dz9uN5Nw.js +1 -0
- package/dist/components/p-ETg0qC-7.js +1 -0
- package/dist/components/p-FAhcOdS-.js +1 -0
- package/dist/components/p-HCtk4_Dq.js +1 -0
- package/dist/components/p-QezfyBk4.js +1 -0
- package/dist/components/p-RD09_3LO.js +1 -0
- package/dist/components/p-RQjw5hdz.js +1 -0
- package/dist/components/p-dbZuh0Uq.js +1 -0
- package/dist/components/p-emzVHCws.js +1 -0
- package/dist/components/p-im7kgtnS.js +1 -0
- package/dist/components/p-kC6NU5nP.js +1 -0
- package/dist/components/p-lX2uCKEi.js +1 -0
- package/dist/components/p-ndQSfLKF.js +1 -0
- package/dist/components/p-plWZwD4h.js +1 -0
- package/dist/components/p-t0lkpFmw.js +1 -0
- package/dist/components/p-ujToMKti.js +1 -0
- package/dist/dropi-ui/dropi-accordion-item.entry.js +58 -0
- package/dist/dropi-ui/dropi-accordion-item.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-accordion.entry.js +20 -0
- package/dist/dropi-ui/dropi-accordion.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-alert-legacy.entry.js +40 -0
- package/dist/dropi-ui/dropi-alert-legacy.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-alert-modal.entry.js +133 -0
- package/dist/dropi-ui/dropi-alert-modal.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-alert.entry.js +65 -0
- package/dist/dropi-ui/dropi-alert.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-avatars.entry.js +32 -0
- package/dist/dropi-ui/dropi-avatars.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-badge-legacy.entry.js +31 -0
- package/dist/dropi-ui/dropi-badge-legacy.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-badge.entry.js +38 -0
- package/dist/dropi-ui/dropi-badge.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-banner-external.entry.js +64 -0
- package/dist/dropi-ui/dropi-banner-external.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-breadcrumb.entry.js +49 -0
- package/dist/dropi-ui/dropi-breadcrumb.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-button.entry.js +88 -0
- package/dist/dropi-ui/dropi-button.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-card-checkbox.entry.js +49 -0
- package/dist/dropi-ui/dropi-card-checkbox.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-card-product.entry.js +79 -0
- package/dist/dropi-ui/dropi-card-product.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-card-section.entry.js +39 -0
- package/dist/dropi-ui/dropi-card-section.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-carousel.entry.js +154 -0
- package/dist/dropi-ui/dropi-carousel.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-checkbox-selection-list.entry.js +74 -0
- package/dist/dropi-ui/dropi-checkbox-selection-list.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-checkbox.entry.js +37 -0
- package/dist/dropi-ui/dropi-checkbox.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-chips.entry.js +31 -0
- package/dist/dropi-ui/dropi-chips.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-city-selector.entry.js +105 -0
- package/dist/dropi-ui/dropi-city-selector.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-color-picker.entry.js +320 -0
- package/dist/dropi-ui/dropi-color-picker.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-country-flags.entry.js +38 -0
- package/dist/dropi-ui/dropi-country-flags.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-country-selector.entry.js +198 -0
- package/dist/dropi-ui/dropi-country-selector.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-date-picker-range.entry.js +116 -0
- package/dist/dropi-ui/dropi-date-picker-range.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-date-picker.entry.js +224 -0
- package/dist/dropi-ui/dropi-date-picker.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-drawer.entry.js +80 -0
- package/dist/dropi-ui/dropi-drawer.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-dropdown.entry.js +66 -0
- package/dist/dropi-ui/dropi-dropdown.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-empty-state.entry.js +37 -0
- package/dist/dropi-ui/dropi-empty-state.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-favorite-button.entry.js +28 -0
- package/dist/dropi-ui/dropi-favorite-button.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-file-upload-progress-bar.entry.js +78 -0
- package/dist/dropi-ui/dropi-file-upload-progress-bar.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-file-upload.entry.js +238 -0
- package/dist/dropi-ui/dropi-file-upload.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-icon.entry.js +80 -0
- package/dist/dropi-ui/dropi-icon.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-ilustration-icon.entry.js +40 -0
- package/dist/dropi-ui/dropi-ilustration-icon.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-image-miniature.entry.js +45 -0
- package/dist/dropi-ui/dropi-image-miniature.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-image-overlay.entry.js +64 -0
- package/dist/dropi-ui/dropi-image-overlay.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-input.entry.js +266 -0
- package/dist/dropi-ui/dropi-input.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-languages-selector.entry.js +62 -0
- package/dist/dropi-ui/dropi-languages-selector.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-logo.entry.js +38 -0
- package/dist/dropi-ui/dropi-logo.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-lottie-loader.entry.js +28 -0
- package/dist/dropi-ui/dropi-lottie-loader.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-media-player.entry.js +193 -0
- package/dist/dropi-ui/dropi-media-player.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-modal.entry.js +148 -0
- package/dist/dropi-ui/dropi-modal.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-navbar.entry.js +55 -0
- package/dist/dropi-ui/dropi-navbar.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-otp-send-code.entry.js +116 -0
- package/dist/dropi-ui/dropi-otp-send-code.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-paginator.entry.js +70 -0
- package/dist/dropi-ui/dropi-paginator.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-phone-input.entry.js +198 -0
- package/dist/dropi-ui/dropi-phone-input.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-progress-bar.entry.js +44 -0
- package/dist/dropi-ui/dropi-progress-bar.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-radio-button.entry.js +48 -0
- package/dist/dropi-ui/dropi-radio-button.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-radio-selection-list.entry.js +61 -0
- package/dist/dropi-ui/dropi-radio-selection-list.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-read-more.entry.js +41 -0
- package/dist/dropi-ui/dropi-read-more.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-search.entry.js +125 -0
- package/dist/dropi-ui/dropi-search.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-select.entry.js +411 -0
- package/dist/dropi-ui/dropi-select.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-sidebar.entry.js +79 -0
- package/dist/dropi-ui/dropi-sidebar.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-simple-stepper.entry.js +54 -0
- package/dist/dropi-ui/dropi-simple-stepper.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-skeleton.entry.js +58 -0
- package/dist/dropi-ui/dropi-skeleton.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-steps.entry.js +53 -0
- package/dist/dropi-ui/dropi-steps.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-switch.entry.js +31 -0
- package/dist/dropi-ui/dropi-switch.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-table.entry.js +308 -0
- package/dist/dropi-ui/dropi-table.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-tabs.entry.js +52 -0
- package/dist/dropi-ui/dropi-tabs.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-tag-type-product.entry.js +20 -0
- package/dist/dropi-ui/dropi-tag-type-product.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-tag.entry.js +97 -0
- package/dist/dropi-ui/dropi-tag.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-text-area.entry.js +135 -0
- package/dist/dropi-ui/dropi-text-area.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-time-line.entry.js +35 -0
- package/dist/dropi-ui/dropi-time-line.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-toast.entry.js +57 -0
- package/dist/dropi-ui/dropi-toast.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-tooltip-v2.entry.js +132 -0
- package/dist/dropi-ui/dropi-tooltip-v2.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-tooltip.entry.js +22 -0
- package/dist/dropi-ui/dropi-tooltip.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-ui.esm.js +1 -1
- package/dist/dropi-ui/dropi-ui.esm.js.map +1 -0
- package/dist/dropi-ui/dropi-vertical-steps.entry.js +56 -0
- package/dist/dropi-ui/dropi-vertical-steps.entry.js.map +1 -0
- package/dist/dropi-ui/dropi-youtube-lazy-video.entry.js +34 -0
- package/dist/dropi-ui/dropi-youtube-lazy-video.entry.js.map +1 -0
- package/dist/dropi-ui/index-Cvp2LQOM.js +4585 -0
- package/dist/dropi-ui/index-Cvp2LQOM.js.map +1 -0
- package/dist/dropi-ui/index.esm.js.map +1 -0
- package/dist/dropi-ui/p-019c2c37.entry.js +1 -0
- package/dist/dropi-ui/p-01c57627.entry.js +1 -0
- package/dist/dropi-ui/{p-db38bf16.entry.js → p-01e4fe42.entry.js} +1 -1
- package/dist/dropi-ui/p-03515548.entry.js +1 -0
- package/dist/dropi-ui/p-0366349e.entry.js +1 -0
- package/dist/dropi-ui/p-06bdd006.entry.js +1 -0
- package/dist/dropi-ui/p-086a6f5f.entry.js +1 -0
- package/dist/dropi-ui/p-088616e6.entry.js +1 -0
- package/dist/dropi-ui/p-08bc8fb2.entry.js +1 -0
- package/dist/dropi-ui/p-0946a1f7.entry.js +1 -0
- package/dist/dropi-ui/p-099f4475.entry.js +1 -0
- package/dist/dropi-ui/p-09aa9a3c.entry.js +1 -0
- package/dist/dropi-ui/p-0a76c15c.entry.js +1 -0
- package/dist/dropi-ui/p-0d188f2c.entry.js +1 -0
- package/dist/dropi-ui/p-0e026afe.entry.js +1 -0
- package/dist/dropi-ui/p-0ef73e45.entry.js +1 -0
- package/dist/dropi-ui/p-0f1b13e5.entry.js +1 -0
- package/dist/dropi-ui/p-1107c210.entry.js +1 -0
- package/dist/dropi-ui/p-13a6dd72.entry.js +1 -0
- package/dist/dropi-ui/p-1558c22f.entry.js +1 -0
- package/dist/dropi-ui/p-16674c7c.entry.js +1 -0
- package/dist/dropi-ui/p-17b16a74.entry.js +1 -0
- package/dist/dropi-ui/p-17c53e19.entry.js +1 -0
- package/dist/dropi-ui/p-1a07b3a6.entry.js +1 -0
- package/dist/dropi-ui/p-1cd4d630.entry.js +1 -0
- package/dist/dropi-ui/p-1ce00757.entry.js +1 -0
- package/dist/dropi-ui/p-1d75dff6.entry.js +1 -0
- package/dist/dropi-ui/p-20a6a2aa.entry.js +1 -0
- package/dist/dropi-ui/p-229dddb0.entry.js +1 -0
- package/dist/dropi-ui/p-256bf069.entry.js +1 -0
- package/dist/dropi-ui/p-25f0c2c9.entry.js +1 -0
- package/dist/dropi-ui/p-278281d2.entry.js +1 -0
- package/dist/dropi-ui/p-28f960a1.entry.js +1 -0
- package/dist/dropi-ui/p-2d356767.entry.js +1 -0
- package/dist/dropi-ui/p-2d9978c1.entry.js +1 -0
- package/dist/dropi-ui/p-2f9072e7.entry.js +1 -0
- package/dist/dropi-ui/p-30377b7e.entry.js +1 -0
- package/dist/dropi-ui/p-342eaf9e.entry.js +1 -0
- package/dist/dropi-ui/p-3496cc01.entry.js +1 -0
- package/dist/dropi-ui/p-35b37d1a.entry.js +1 -0
- package/dist/dropi-ui/p-37bdbadc.entry.js +1 -0
- package/dist/dropi-ui/p-38ea66e4.entry.js +1 -0
- package/dist/dropi-ui/p-393867c2.entry.js +1 -0
- package/dist/dropi-ui/p-3a28b79c.entry.js +1 -0
- package/dist/dropi-ui/p-3aefce2b.entry.js +1 -0
- package/dist/dropi-ui/p-3f76c680.entry.js +1 -0
- package/dist/dropi-ui/p-488a3113.entry.js +1 -0
- package/dist/dropi-ui/p-497e4eff.entry.js +1 -0
- package/dist/dropi-ui/p-4a72e4c8.entry.js +1 -0
- package/dist/dropi-ui/p-4b169817.entry.js +1 -0
- package/dist/dropi-ui/p-4d31eab8.entry.js +1 -0
- package/dist/dropi-ui/p-4e401fbc.entry.js +1 -0
- package/dist/dropi-ui/p-508cfd38.entry.js +1 -0
- package/dist/dropi-ui/p-50e851b7.entry.js +1 -0
- package/dist/dropi-ui/p-53d2905c.entry.js +1 -0
- package/dist/dropi-ui/p-54bfb072.entry.js +1 -0
- package/dist/dropi-ui/p-5730ca4e.entry.js +1 -0
- package/dist/dropi-ui/p-575e1951.entry.js +1 -0
- package/dist/dropi-ui/p-57c3b667.entry.js +1 -0
- package/dist/dropi-ui/p-5915d227.entry.js +1 -0
- package/dist/dropi-ui/p-5c0cd221.entry.js +1 -0
- package/dist/dropi-ui/p-5e0da387.entry.js +1 -0
- package/dist/dropi-ui/p-5eb75ddf.entry.js +1 -0
- package/dist/dropi-ui/p-5f735166.entry.js +1 -0
- package/dist/dropi-ui/p-61f8905c.entry.js +1 -0
- package/dist/dropi-ui/p-648e5340.entry.js +1 -0
- package/dist/dropi-ui/p-650a7679.entry.js +1 -0
- package/dist/dropi-ui/p-66d7d67b.entry.js +1 -0
- package/dist/dropi-ui/p-673a5cfd.entry.js +1 -0
- package/dist/dropi-ui/p-67ba7d35.entry.js +1 -0
- package/dist/dropi-ui/p-692b665a.entry.js +1 -0
- package/dist/dropi-ui/p-69cf66c1.entry.js +1 -0
- package/dist/dropi-ui/p-6a148627.entry.js +1 -0
- package/dist/dropi-ui/p-6b925a36.entry.js +1 -0
- package/dist/dropi-ui/p-6cb6cfe0.entry.js +1 -0
- package/dist/dropi-ui/p-6dbce3d3.entry.js +1 -0
- package/dist/dropi-ui/p-70f75e92.entry.js +1 -0
- package/dist/dropi-ui/p-7140309a.entry.js +1 -0
- package/dist/dropi-ui/p-719a01cb.entry.js +1 -0
- package/dist/dropi-ui/p-72ec96d0.entry.js +1 -0
- package/dist/dropi-ui/p-7369b3b4.entry.js +1 -0
- package/dist/dropi-ui/p-7450d195.entry.js +1 -0
- package/dist/dropi-ui/p-754aed1c.entry.js +1 -0
- package/dist/dropi-ui/p-76fa02a1.entry.js +1 -0
- package/dist/dropi-ui/p-770b0195.entry.js +1 -0
- package/dist/dropi-ui/{p-e3ad21f8.entry.js → p-77cd2fcb.entry.js} +1 -1
- package/dist/dropi-ui/p-7822b081.entry.js +1 -0
- package/dist/dropi-ui/p-78282471.entry.js +1 -0
- package/dist/dropi-ui/p-78aa7fb3.entry.js +1 -0
- package/dist/dropi-ui/p-7a18b7a0.entry.js +1 -0
- package/dist/dropi-ui/p-7a25f595.entry.js +1 -0
- package/dist/dropi-ui/p-7c0f959f.entry.js +1 -0
- package/dist/dropi-ui/p-7c5ea4c5.entry.js +1 -0
- package/dist/dropi-ui/p-7f02ae47.entry.js +1 -0
- package/dist/dropi-ui/p-7f0f828d.entry.js +1 -0
- package/dist/dropi-ui/p-80f0f6e6.entry.js +1 -0
- package/dist/dropi-ui/p-813678a2.entry.js +1 -0
- package/dist/dropi-ui/p-819d810e.entry.js +1 -0
- package/dist/dropi-ui/p-83887880.entry.js +1 -0
- package/dist/dropi-ui/p-83dbc407.entry.js +1 -0
- package/dist/dropi-ui/p-84019422.entry.js +1 -0
- package/dist/dropi-ui/p-85c637bd.entry.js +1 -0
- package/dist/dropi-ui/{p-e6e766ed.entry.js → p-87cc4dcd.entry.js} +1 -1
- package/dist/dropi-ui/p-899089f0.entry.js +1 -0
- package/dist/dropi-ui/p-8b8dc399.entry.js +1 -0
- package/dist/dropi-ui/p-8c107dbe.entry.js +1 -0
- package/dist/dropi-ui/p-8cf27f13.entry.js +1 -0
- package/dist/dropi-ui/p-8d6313c0.entry.js +1 -0
- package/dist/dropi-ui/p-8dbc6bc8.entry.js +1 -0
- package/dist/dropi-ui/p-8fc3dbcb.entry.js +1 -0
- package/dist/dropi-ui/p-90abda79.entry.js +1 -0
- package/dist/dropi-ui/p-928b59e8.entry.js +1 -0
- package/dist/dropi-ui/p-929bc2b6.entry.js +1 -0
- package/dist/dropi-ui/p-92c9e3c5.entry.js +1 -0
- package/dist/dropi-ui/p-94144382.entry.js +1 -0
- package/dist/dropi-ui/p-94a58087.entry.js +1 -0
- package/dist/dropi-ui/p-9645d628.entry.js +1 -0
- package/dist/dropi-ui/p-96f72e50.entry.js +1 -0
- package/dist/dropi-ui/p-9ac8caea.entry.js +1 -0
- package/dist/dropi-ui/p-9b24e8fd.entry.js +1 -0
- package/dist/dropi-ui/p-9b288982.entry.js +1 -0
- package/dist/dropi-ui/p-9b55c8ad.entry.js +1 -0
- package/dist/dropi-ui/p-9bcde3a5.entry.js +1 -0
- package/dist/dropi-ui/p-9c73b4ce.entry.js +1 -0
- package/dist/dropi-ui/p-9e8615de.entry.js +1 -0
- package/dist/dropi-ui/p-a0ade2e7.entry.js +1 -0
- package/dist/dropi-ui/p-a2fb4CHk.js +2 -0
- package/dist/dropi-ui/p-a3b729fe.entry.js +1 -0
- package/dist/dropi-ui/p-a3d602fd.entry.js +1 -0
- package/dist/dropi-ui/p-a470a24a.entry.js +1 -0
- package/dist/dropi-ui/p-a50c8339.entry.js +1 -0
- package/dist/dropi-ui/p-a524ef3d.entry.js +1 -0
- package/dist/dropi-ui/p-a580e8c8.entry.js +1 -0
- package/dist/dropi-ui/p-a62c691f.entry.js +1 -0
- package/dist/dropi-ui/p-a745529a.entry.js +1 -0
- package/dist/dropi-ui/p-a96c54ed.entry.js +1 -0
- package/dist/dropi-ui/p-a9f93e82.entry.js +1 -0
- package/dist/dropi-ui/p-aa0f5964.entry.js +1 -0
- package/dist/dropi-ui/p-aadd5863.entry.js +1 -0
- package/dist/dropi-ui/p-ab3c52a4.entry.js +1 -0
- package/dist/dropi-ui/p-abd327ed.entry.js +1 -0
- package/dist/dropi-ui/p-ac79e805.entry.js +1 -0
- package/dist/dropi-ui/p-ac9d2149.entry.js +1 -0
- package/dist/dropi-ui/p-ad73631e.entry.js +1 -0
- package/dist/dropi-ui/p-b20f7dde.entry.js +1 -0
- package/dist/dropi-ui/p-b25faf92.entry.js +1 -0
- package/dist/dropi-ui/p-b2e7cf4f.entry.js +1 -0
- package/dist/dropi-ui/p-b325f7cf.entry.js +1 -0
- package/dist/dropi-ui/p-b605d3d9.entry.js +1 -0
- package/dist/dropi-ui/p-b63f5d03.entry.js +1 -0
- package/dist/dropi-ui/p-b7748488.entry.js +1 -0
- package/dist/dropi-ui/p-b8050ef5.entry.js +1 -0
- package/dist/dropi-ui/p-b99fee29.entry.js +1 -0
- package/dist/dropi-ui/p-ba3779a2.entry.js +1 -0
- package/dist/dropi-ui/p-bbb5e0ae.entry.js +1 -0
- package/dist/dropi-ui/p-bd0d1a29.entry.js +1 -0
- package/dist/dropi-ui/p-bef43920.entry.js +1 -0
- package/dist/dropi-ui/p-bfd43bdf.entry.js +1 -0
- package/dist/dropi-ui/p-c173db8c.entry.js +1 -0
- package/dist/dropi-ui/p-c218524f.entry.js +1 -0
- package/dist/dropi-ui/p-c4d2881d.entry.js +1 -0
- package/dist/dropi-ui/p-c4fbbb5a.entry.js +1 -0
- package/dist/dropi-ui/p-c51fcf75.entry.js +1 -0
- package/dist/dropi-ui/p-c662bce3.entry.js +1 -0
- package/dist/dropi-ui/p-c6ac1b6d.entry.js +1 -0
- package/dist/dropi-ui/p-ca2e462a.entry.js +1 -0
- package/dist/dropi-ui/p-ca90e108.entry.js +1 -0
- package/dist/dropi-ui/p-cb87d3c7.entry.js +1 -0
- package/dist/dropi-ui/p-cc954850.entry.js +1 -0
- package/dist/dropi-ui/p-cf7cd408.entry.js +1 -0
- package/dist/dropi-ui/p-d02dfc6a.entry.js +1 -0
- package/dist/dropi-ui/p-d11524ca.entry.js +1 -0
- package/dist/dropi-ui/p-d1aeb373.entry.js +1 -0
- package/dist/dropi-ui/p-d46f3328.entry.js +1 -0
- package/dist/dropi-ui/p-d693bbb8.entry.js +1 -0
- package/dist/dropi-ui/p-d724ced4.entry.js +1 -0
- package/dist/dropi-ui/p-d813969b.entry.js +1 -0
- package/dist/dropi-ui/p-d899d4e1.entry.js +1 -0
- package/dist/dropi-ui/p-da038b5d.entry.js +1 -0
- package/dist/dropi-ui/p-db6af92e.entry.js +1 -0
- package/dist/dropi-ui/p-dc53a798.entry.js +1 -0
- package/dist/dropi-ui/p-dc920aff.entry.js +1 -0
- package/dist/dropi-ui/p-e1126498.entry.js +1 -0
- package/dist/dropi-ui/p-e163bf7f.entry.js +1 -0
- package/dist/dropi-ui/p-e1b3c9a3.entry.js +1 -0
- package/dist/dropi-ui/p-e1b40bda.entry.js +1 -0
- package/dist/dropi-ui/p-e22a3b45.entry.js +1 -0
- package/dist/dropi-ui/p-e3c120ba.entry.js +1 -0
- package/dist/dropi-ui/p-e524fed1.entry.js +1 -0
- package/dist/dropi-ui/p-e53b23dd.entry.js +1 -0
- package/dist/dropi-ui/p-e629fdc7.entry.js +1 -0
- package/dist/dropi-ui/p-e97d3704.entry.js +1 -0
- package/dist/dropi-ui/p-e9a64ecc.entry.js +1 -0
- package/dist/dropi-ui/p-ea13bfee.entry.js +1 -0
- package/dist/dropi-ui/p-edcf5623.entry.js +1 -0
- package/dist/dropi-ui/p-edeacd44.entry.js +1 -0
- package/dist/dropi-ui/p-edef4506.entry.js +1 -0
- package/dist/dropi-ui/p-edf796ee.entry.js +1 -0
- package/dist/dropi-ui/p-eec49ea3.entry.js +1 -0
- package/dist/dropi-ui/p-f057bd98.entry.js +1 -0
- package/dist/dropi-ui/p-f0893459.entry.js +1 -0
- package/dist/dropi-ui/p-f0ace417.entry.js +1 -0
- package/dist/dropi-ui/p-f23e1df7.entry.js +1 -0
- package/dist/dropi-ui/p-f2527a45.entry.js +1 -0
- package/dist/dropi-ui/p-f4bd8568.entry.js +1 -0
- package/dist/dropi-ui/p-f6c9057d.entry.js +1 -0
- package/dist/dropi-ui/p-f7a605f8.entry.js +1 -0
- package/dist/dropi-ui/p-f7df0f43.entry.js +1 -0
- package/dist/dropi-ui/p-f7fd7832.entry.js +1 -0
- package/dist/dropi-ui/p-f80fa01d.entry.js +1 -0
- package/dist/dropi-ui/p-f9084a2c.entry.js +1 -0
- package/dist/dropi-ui/p-f9888cea.entry.js +1 -0
- package/dist/dropi-ui/p-f9af2041.entry.js +1 -0
- package/dist/dropi-ui/p-f9d05b69.entry.js +1 -0
- package/dist/dropi-ui/p-faa59cd8.entry.js +1 -0
- package/dist/dropi-ui/p-fb39dfdc.entry.js +1 -0
- package/dist/dropi-ui/p-fcba49ca.entry.js +1 -0
- package/dist/dropi-ui/p-fdbdedd0.entry.js +1 -0
- package/dist/dropi-ui/p-fef3673d.entry.js +1 -0
- package/dist/dropi-ui/p-ffd415a2.entry.js +1 -0
- package/dist/esm/dropi-accordion-item.entry.js +2 -2
- package/dist/esm/dropi-accordion.entry.js +2 -2
- package/dist/esm/dropi-alert-legacy.entry.js +1 -1
- package/dist/esm/dropi-alert-modal.entry.js +20 -16
- package/dist/esm/dropi-alert.entry.js +12 -12
- package/dist/esm/dropi-avatars.entry.js +1 -1
- package/dist/esm/dropi-badge-legacy.entry.js +2 -2
- package/dist/esm/dropi-badge.entry.js +1 -1
- package/dist/esm/dropi-banner-external.entry.js +4 -4
- package/dist/esm/dropi-breadcrumb.entry.js +4 -4
- package/dist/esm/dropi-button.entry.js +7 -7
- package/dist/esm/dropi-card-checkbox.entry.js +6 -6
- package/dist/esm/dropi-card-product.entry.js +12 -12
- package/dist/esm/dropi-card-section.entry.js +9 -9
- package/dist/esm/dropi-carousel.entry.js +8 -8
- package/dist/esm/dropi-checkbox-selection-list.entry.js +9 -9
- package/dist/esm/dropi-checkbox.entry.js +6 -6
- package/dist/esm/dropi-chips.entry.js +4 -4
- package/dist/esm/dropi-city-selector.entry.js +4 -4
- package/dist/esm/dropi-color-picker.entry.js +4 -4
- package/dist/esm/dropi-country-flags.entry.js +2 -2
- package/dist/esm/dropi-country-selector.entry.js +6 -6
- package/dist/esm/dropi-date-picker-range.entry.js +4 -4
- package/dist/esm/dropi-date-picker.entry.js +12 -12
- package/dist/esm/dropi-drawer.entry.js +4 -4
- package/dist/esm/dropi-dropdown.entry.js +2 -2
- package/dist/esm/dropi-empty-state.entry.js +3 -3
- package/dist/esm/dropi-favorite-button.entry.js +3 -3
- package/dist/esm/dropi-file-upload-progress-bar.entry.js +5 -5
- package/dist/esm/dropi-file-upload.entry.js +4 -4
- package/dist/esm/dropi-icon.entry.js +33 -21
- package/dist/esm/dropi-ilustration-icon.entry.js +5 -5
- package/dist/esm/dropi-image-miniature.entry.js +3 -3
- package/dist/esm/dropi-image-overlay.entry.js +3 -3
- package/dist/esm/dropi-input_3.entry.js +56 -26
- package/dist/esm/dropi-languages-selector.entry.js +5 -5
- package/dist/esm/dropi-logo.entry.js +2 -2
- package/dist/esm/dropi-lottie-loader.entry.js +1 -1
- package/dist/esm/dropi-media-player.entry.js +5 -5
- package/dist/esm/dropi-modal.entry.js +38 -33
- package/dist/esm/dropi-navbar.entry.js +7 -7
- package/dist/esm/dropi-otp-send-code.entry.js +43 -20
- package/dist/esm/dropi-phone-input.entry.js +14 -14
- package/dist/esm/dropi-progress-bar.entry.js +41 -0
- package/dist/esm/dropi-radio-button.entry.js +5 -5
- package/dist/esm/dropi-radio-selection-list.entry.js +9 -9
- package/dist/esm/dropi-read-more.entry.js +2 -2
- package/dist/esm/dropi-search.entry.js +21 -21
- package/dist/esm/dropi-select.entry.js +55 -27
- package/dist/esm/dropi-sidebar.entry.js +8 -8
- package/dist/esm/dropi-simple-stepper.entry.js +1 -1
- package/dist/esm/dropi-skeleton.entry.js +1 -1
- package/dist/esm/dropi-steps.entry.js +2 -2
- package/dist/esm/dropi-switch.entry.js +5 -5
- package/dist/esm/dropi-table.entry.js +41 -33
- package/dist/esm/dropi-tabs.entry.js +6 -6
- package/dist/esm/dropi-tag-type-product.entry.js +2 -2
- package/dist/esm/dropi-text-area.entry.js +7 -7
- package/dist/esm/dropi-time-line.entry.js +3 -3
- package/dist/esm/dropi-toast.entry.js +2 -2
- package/dist/esm/dropi-tooltip-v2.entry.js +3 -3
- package/dist/esm/dropi-tooltip.entry.js +2 -2
- package/dist/esm/dropi-ui.js +3 -3
- package/dist/esm/dropi-vertical-steps.entry.js +4 -4
- package/dist/esm/dropi-youtube-lazy-video.entry.js +2 -2
- package/dist/esm/index-a2fb4CHk.js +2763 -0
- package/dist/esm/loader.js +3 -3
- package/dist/types/components/dropi-alert/dropi-alert.d.ts +3 -3
- package/dist/types/components/dropi-alert-modal/dropi-alert-modal.d.ts +8 -4
- package/dist/types/components/dropi-button/dropi-button.d.ts +1 -1
- package/dist/types/components/dropi-card-checkbox/dropi-card-checkbox.d.ts +1 -1
- package/dist/types/components/dropi-card-product/dropi-card-product.d.ts +2 -2
- package/dist/types/components/dropi-card-section/dropi-card-section.d.ts +2 -2
- package/dist/types/components/dropi-carousel/dropi-carousel.d.ts +2 -2
- package/dist/types/components/dropi-checkbox/dropi-checkbox.d.ts +1 -1
- package/dist/types/components/dropi-checkbox-selection-list/dropi-checkbox-selection-list.d.ts +2 -2
- package/dist/types/components/dropi-chips/dropi-chips.d.ts +1 -1
- package/dist/types/components/dropi-country-selector/dropi-country-selector.d.ts +1 -1
- package/dist/types/components/dropi-date-picker/dropi-date-picker.d.ts +2 -2
- package/dist/types/components/dropi-icon/dropi-icon.d.ts +8 -9
- package/dist/types/components/dropi-input/dropi-input.d.ts +5 -5
- package/dist/types/components/dropi-languages-selector/dropi-languages-selector.d.ts +1 -1
- package/dist/types/components/dropi-modal/dropi-modal.d.ts +10 -9
- package/dist/types/components/dropi-otp-send-code/dropi-otp-send-code.d.ts +8 -2
- package/dist/types/components/dropi-paginator/dropi-paginator.d.ts +1 -1
- package/dist/types/components/dropi-phone-input/dropi-phone-input.d.ts +4 -4
- package/dist/types/components/dropi-progress-bar/dropi-progress-bar.d.ts +16 -0
- package/dist/types/components/dropi-radio-button/dropi-radio-button.d.ts +1 -1
- package/dist/types/components/dropi-radio-selection-list/dropi-radio-selection-list.d.ts +2 -2
- package/dist/types/components/dropi-search/dropi-search.d.ts +6 -6
- package/dist/types/components/dropi-select/dropi-select.d.ts +10 -5
- package/dist/types/components/dropi-sidebar/dropi-sidebar.d.ts +1 -1
- package/dist/types/components/dropi-switch/dropi-switch.d.ts +1 -1
- package/dist/types/components/dropi-table/dropi-table.d.ts +7 -7
- package/dist/types/components/dropi-tabs/dropi-tabs.d.ts +1 -1
- package/dist/types/components/dropi-tag/dropi-tag.d.ts +5 -0
- package/dist/types/components.d.ts +336 -199
- package/hydrate/index.js +570 -401
- package/hydrate/index.mjs +570 -401
- package/package.json +1 -1
- package/scripts/setup.js +25 -4
- package/dist/components/p-B_Ace02i.js +0 -1
- package/dist/components/p-BrjO_JXp.js +0 -1
- package/dist/components/p-BwhxWL4p.js +0 -1
- package/dist/components/p-Bz2jXX3R.js +0 -1
- package/dist/components/p-D-vQQQNz.js +0 -1
- package/dist/components/p-D13d88W3.js +0 -1
- package/dist/components/p-I3w7xF7Q.js +0 -1
- package/dist/components/p-o5gyrbbD.js +0 -1
- package/dist/dropi-ui/p-00e5a2de.entry.js +0 -1
- package/dist/dropi-ui/p-0188e07a.entry.js +0 -1
- package/dist/dropi-ui/p-02710049.entry.js +0 -1
- package/dist/dropi-ui/p-18adf694.entry.js +0 -1
- package/dist/dropi-ui/p-1a3619c3.entry.js +0 -1
- package/dist/dropi-ui/p-25640777.entry.js +0 -1
- package/dist/dropi-ui/p-2674d901.entry.js +0 -1
- package/dist/dropi-ui/p-2af538b9.entry.js +0 -1
- package/dist/dropi-ui/p-3013f3b8.entry.js +0 -1
- package/dist/dropi-ui/p-3321ca70.entry.js +0 -1
- package/dist/dropi-ui/p-33d242ec.entry.js +0 -1
- package/dist/dropi-ui/p-39af6478.entry.js +0 -1
- package/dist/dropi-ui/p-446a481d.entry.js +0 -1
- package/dist/dropi-ui/p-50e0d44f.entry.js +0 -1
- package/dist/dropi-ui/p-5c0bd7c2.entry.js +0 -1
- package/dist/dropi-ui/p-5ddf6e93.entry.js +0 -1
- package/dist/dropi-ui/p-5fb33ae4.entry.js +0 -1
- package/dist/dropi-ui/p-665ef7ba.entry.js +0 -1
- package/dist/dropi-ui/p-66b80371.entry.js +0 -1
- package/dist/dropi-ui/p-7bfc1c27.entry.js +0 -1
- package/dist/dropi-ui/p-7c0d2edf.entry.js +0 -1
- package/dist/dropi-ui/p-7eb27836.entry.js +0 -1
- package/dist/dropi-ui/p-8bf5d8ee.entry.js +0 -1
- package/dist/dropi-ui/p-9212f544.entry.js +0 -1
- package/dist/dropi-ui/p-955e52f8.entry.js +0 -1
- package/dist/dropi-ui/p-976a15e3.entry.js +0 -1
- package/dist/dropi-ui/p-a1c93e55.entry.js +0 -1
- package/dist/dropi-ui/p-a232c6a7.entry.js +0 -1
- package/dist/dropi-ui/p-a822a23e.entry.js +0 -1
- package/dist/dropi-ui/p-af8e2157.entry.js +0 -1
- package/dist/dropi-ui/p-c3614c4a.entry.js +0 -1
- package/dist/dropi-ui/p-cc527d91.entry.js +0 -1
- package/dist/dropi-ui/p-cdde481b.entry.js +0 -1
- package/dist/dropi-ui/p-dd5d8b1b.entry.js +0 -1
- package/dist/dropi-ui/p-efc2fc35.entry.js +0 -1
- package/dist/dropi-ui/p-f41cd9b5.entry.js +0 -1
- package/dist/dropi-ui/p-fa3d0267.entry.js +0 -1
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { r as registerInstance, d as createEvent, h } from './index-Cvp2LQOM.js';
|
|
2
|
+
|
|
3
|
+
const dropiCardCheckboxCss = () => `:host{display:block;width:100%}*,*::before,*::after{box-sizing:border-box}.container-card-check{padding:var(--Size-4, 16px);border:1px solid var(--Gray-Gray-200, #c3c9d9);border-radius:var(--Size-2, 8px);width:100%;display:flex;align-items:center;gap:var(--Size-3, 12px);cursor:pointer;height:66px;overflow:hidden;transition:background 0.15s ease, border-color 0.15s ease}.container-card-check.disabled{border-radius:var(--Border-2, 8px);border:1px solid var(--Gray-Gray-100, #e6eaf2);background-color:var(--Gray-Gray-50, #f7f8fa);cursor:default}.container-card-check.disabled .title-check,.container-card-check.disabled .description-text,.container-card-check.disabled .extra-info{color:var(--Gray-Gray-400, #858ea6)}.container-text{width:100%;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;text-align:start;overflow:hidden}.title-check{color:var(--Gray-Gray-700, #32394d);font-size:var(--font-size-m, 14px);font-weight:var(--font-weight-regular, 400);display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis}.description-text{color:var(--Gray-Gray-500, #69738c);font-size:var(--font-size-s, 12px);margin-top:var(--Size-1, 4px);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis}.extra-info{display:flex;justify-content:space-between;align-items:center;flex-direction:column;gap:4px;flex-shrink:0;font-size:var(--font-size-s, 12px);color:var(--Gray-Gray-600, #475066)}.extra-info h4{margin:0;font-weight:var(--font-weight-semibold);color:inherit;line-height:inherit}.default-card{border:none}.is-checked{background:var(--Primary-Primary-50, #fff8f0);border:1px solid var(--Primary-Primary-500, #f49a3d)}`;
|
|
4
|
+
|
|
5
|
+
const DropiCardCheckbox = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.dropiChange = createEvent(this, "dropiChange", 7);
|
|
9
|
+
}
|
|
10
|
+
/** Visual type — matches Angular: 'default' | 'with card' */
|
|
11
|
+
type = 'default';
|
|
12
|
+
/** Whether the checkbox is checked — matches Angular 'state' */
|
|
13
|
+
state = 'checked';
|
|
14
|
+
/** Main title — matches Angular 'title' */
|
|
15
|
+
title = 'Tittle';
|
|
16
|
+
/** Optional description below title */
|
|
17
|
+
description = '';
|
|
18
|
+
/** Optional extra info shown on the right */
|
|
19
|
+
extraInfo = '';
|
|
20
|
+
/** Optional extra info description shown below extraInfo */
|
|
21
|
+
extraInfoDescription = '';
|
|
22
|
+
/** Disables interaction */
|
|
23
|
+
disabled = false;
|
|
24
|
+
/** Emitted with the new checked state when clicked */
|
|
25
|
+
dropiChange;
|
|
26
|
+
get isChecked() {
|
|
27
|
+
return this.state === 'checked';
|
|
28
|
+
}
|
|
29
|
+
handleClick() {
|
|
30
|
+
if (this.disabled)
|
|
31
|
+
return;
|
|
32
|
+
this.state = this.isChecked ? 'default' : 'checked';
|
|
33
|
+
this.dropiChange.emit(this.isChecked);
|
|
34
|
+
}
|
|
35
|
+
render() {
|
|
36
|
+
return (h("div", { key: 'b9004c813a03956904cfed8484cac2d8290be86f', class: {
|
|
37
|
+
'container-card-check': true,
|
|
38
|
+
'default-card': this.type === 'default',
|
|
39
|
+
'is-checked': this.isChecked && this.type === 'with card',
|
|
40
|
+
'disabled': this.disabled,
|
|
41
|
+
}, onClick: () => this.handleClick() }, h("dropi-checkbox", { key: '0c5c50811559c6472173fced2f04eee4626f118f', checked: this.isChecked, disabled: this.disabled }), h("div", { key: '1cb17bf8aea55a498d451922942b4fba6d99492c', class: "container-text" }, h("div", { key: '6e2eab2ae82c13cb4e7a654cc989530cee1122c6', class: "title-check" }, this.title), this.description && h("div", { key: '040e5d8f633975bf3eb806835aae8aa308b1d4f8', class: "description-text" }, this.description)), (this.extraInfo || this.extraInfoDescription) && (h("div", { key: 'a5c794b5f2fa249b309b2fb00a759aea5b9e0d6c', class: "extra-info" }, this.extraInfo && h("div", { key: '1587e1a0801312fa8e759af2a367b36f842e1354' }, this.extraInfo), this.extraInfoDescription && h("h4", { key: '930811071657dfbbeff7c2bdc4cd2c2776d38177' }, this.extraInfoDescription)))));
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
DropiCardCheckbox.style = dropiCardCheckboxCss();
|
|
45
|
+
|
|
46
|
+
export { DropiCardCheckbox as dropi_card_checkbox };
|
|
47
|
+
//# sourceMappingURL=dropi-card-checkbox.entry.esm.js.map
|
|
48
|
+
|
|
49
|
+
//# sourceMappingURL=dropi-card-checkbox.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"dropi-card-checkbox.entry.js","mappings":";;AAAA,MAAM,oBAAoB,GAAG,MAAM,CAAC,ktDAAktD,CAAC;;MCmB1uD,iBAAiB,GAAA,MAAA;;;;;;IAEpB,IAAI,GAA4B,SAAS;;IAExB,KAAK,GAA0B,SAAS;;IAEzD,KAAK,GAAW,QAAQ;;IAExB,WAAW,GAAW,EAAE;;IAExB,SAAS,GAAW,EAAE;;IAEtB,oBAAoB,GAAW,EAAE;;IAEjC,QAAQ,GAAY,KAAK;;AAGxB,IAAA,WAAW;AAEpB,IAAA,IAAY,SAAS,GAAA;AACnB,QAAA,OAAO,IAAI,CAAC,KAAK,KAAK,SAAS;;IAGzB,WAAW,GAAA;QACjB,IAAI,IAAI,CAAC,QAAQ;YA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oB,IAAI,CAAA,CAAA,IAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,EAAK,IAAI,CAAC,oBAAoB,CAAM,CAC9D,CACP,CACG;;;;;;;","names":[],"sources":["src/components/dropi-card-checkbox/dropi-card-checkbox.css?tag=dropi-card-checkbox&encapsulation=shadow","src/components/dropi-card-checkbox/dropi-card-checkbox.tsx"],"sourcesContent":[":host {\n display: block;\n width: 100%;\n}\n\n*, *::before, *::after { box-sizing: border-box; }\n\n.container-card-check {\n padding: var(--Size-4, 16px);\n border: 1px solid var(--Gray-Gray-200, #c3c9d9);\n border-radius: var(--Size-2, 8px);\n width: 100%;\n display: flex;\n align-items: center;\n gap: var(--Size-3, 12px);\n cursor: pointer;\n height: 66px;\n overflow: hidden;\n transition: background 0.15s ease, border-color 0.15s ease;\n}\n\n.container-card-check.disabled {\n border-radius: var(--Border-2, 8px);\n border: 1px solid var(--Gray-Gray-100, #e6eaf2);\n background-color: var(--Gray-Gray-50, #f7f8fa);\n cursor: default;\n}\n\n.container-card-check.disabled .title-check,\n.container-card-check.disabled .description-text,\n.container-card-check.disabled .extra-info {\n color: var(--Gray-Gray-400, #858ea6);\n}\n\n.container-text {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n justify-content: center;\n text-align: start;\n overflow: hidden;\n}\n\n.title-check {\n color: var(--Gray-Gray-700, #32394d);\n font-size: var(--font-size-m, 14px);\n font-weight: var(--font-weight-regular, 400);\n display: -webkit-box;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n.description-text {\n color: var(--Gray-Gray-500, #69738c);\n font-size: var(--font-size-s, 12px);\n margin-top: var(--Size-1, 4px);\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n.extra-info {\n display: flex;\n justify-content: space-between;\n align-items: center;\n flex-direction: column;\n gap: 4px;\n flex-shrink: 0;\n font-size: var(--font-size-s, 12px);\n color: var(--Gray-Gray-600, #475066);\n}\n\n.extra-info h4 {\n margin: 0;\n font-weight: var(--font-weight-semibold);\n color: inherit;\n line-height: inherit;\n}\n\n.default-card {\n border: none;\n}\n\n.is-checked {\n background: var(--Primary-Primary-50, #fff8f0);\n border: 1px solid var(--Primary-Primary-500, #f49a3d);\n}\n","import { Component, Prop, Event, EventEmitter, h } from '@stencil/core';\n\n/**\n * @component dropi-card-checkbox\n * Card-style clickable checkbox with title, description, and optional extra info.\n *\n * @example\n * <dropi-card-checkbox\n * title=\"Opción A\"\n * description=\"Descripción breve\"\n * type=\"with-card\"\n * checked\n * ></dropi-card-checkbox>\n */\n@Component({\n tag: 'dropi-card-checkbox',\n styleUrl: 'dropi-card-checkbox.css',\n shadow: true,\n})\nexport class DropiCardCheckbox {\n /** Visual type — matches Angular: 'default' | 'with card' */\n @Prop() type: 'default' | 'with card' = 'default';\n /** Whether the checkbox is checked — matches Angular 'state' */\n @Prop({ mutable: true }) state: 'checked' | 'default' = 'checked';\n /** Main title — matches Angular 'title' */\n @Prop() title: string = 'Tittle';\n /** Optional description below title */\n @Prop() description: string = '';\n /** Optional extra info shown on the right */\n @Prop() extraInfo: string = '';\n /** Optional extra info description shown below extraInfo */\n @Prop() extraInfoDescription: string = '';\n /** Disables interaction */\n @Prop() disabled: boolean = false;\n\n /** Emitted with the new checked state when clicked */\n @Event() dropiChange: EventEmitter<boolean>;\n\n private get isChecked(): boolean {\n return this.state === 'checked';\n }\n\n private handleClick() {\n if (this.disabled) return;\n this.state = this.isChecked ? 'default' : 'checked';\n this.dropiChange.emit(this.isChecked);\n }\n\n render() {\n return (\n <div\n class={{\n 'container-card-check': true,\n 'default-card': this.type === 'default',\n 'is-checked': this.isChecked && this.type === 'with card',\n 'disabled': this.disabled,\n }}\n onClick={() => this.handleClick()}\n >\n <dropi-checkbox checked={this.isChecked} disabled={this.disabled} />\n <div class=\"container-text\">\n <div class=\"title-check\">{this.title}</div>\n {this.description && <div class=\"description-text\">{this.description}</div>}\n </div>\n {(this.extraInfo || this.extraInfoDescription) && (\n <div class=\"extra-info\">\n {this.extraInfo && <div>{this.extraInfo}</div>}\n {this.extraInfoDescription && <h4>{this.extraInfoDescription}</h4>}\n </div>\n )}\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { r as registerInstance, d as createEvent, h } from './index-Cvp2LQOM.js';
|
|
2
|
+
|
|
3
|
+
const dropiCardProductCss = () => `:host{display:block;font-family:'Inter', sans-serif}*,*::before,*::after{box-sizing:border-box}.dropi-card-product{position:relative;background:#ffffff;border-radius:8px;overflow:hidden;transition:all 0.2s ease-in-out;cursor:pointer;display:flex;flex-direction:column;height:100%;box-sizing:border-box;width:100%;max-width:450px;box-shadow:none}.product-image-container{padding:4px;flex-shrink:0}.product-image{position:relative;width:100%;aspect-ratio:1;border-radius:8px;border:1px solid #c3c9d9;overflow:hidden;display:flex;align-items:center;justify-content:center;background-color:#f8f9fa}.product-image img{width:100%;height:100%;object-fit:cover;border-radius:8px}.product-image img.error-img{object-fit:contain}.favorite-button{position:absolute;bottom:5px;right:6px;border-radius:8px;padding:12px;cursor:pointer;transition:all 0.2s ease-in-out;z-index:2;display:flex;align-items:center;justify-content:center;width:42px;height:40px;background:#ffffff;border:1px solid #858ea6}.favorite-button.favorite-active{background:var(--Primary-Primary-500, #f49a3d);border:1px solid var(--Primary-Primary-500, #f49a3d)}.product-info{position:relative;padding:8px;display:flex;flex-direction:column;gap:4px;flex:1;justify-content:space-between}.supplier-insignia{position:absolute;top:-24px;left:0px}.product-header{display:flex;justify-content:space-between;align-items:center;width:100%;height:26px}.category{color:#69738c;font-family:'Inter', sans-serif;font-size:12px;font-weight:400;line-height:1.5;flex:1}.stock-info{display:flex;align-items:center;gap:2px;font-family:'Inter', sans-serif;font-size:12px;font-weight:400;line-height:1.5}.stock-label{color:#69738c}.stock-value{font-weight:500}.product-name{color:#32394d;font-family:'Inter', sans-serif;font-size:16px;font-weight:500;line-height:1.5;margin:0;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}.supplier-info{font-family:'Inter', sans-serif;font-size:12px;line-height:1.2}.supplier-label{color:#69738c;font-weight:400}.supplier-name{color:#50a5f1;font-weight:400;margin-left:4px;cursor:pointer}.price-container{display:flex;gap:8px;margin-top:4px}.price-item{flex:1;display:flex;flex-direction:column}.price-label{color:#69738c;font-family:'Inter', sans-serif;font-size:12px;font-weight:400;line-height:1.5;height:18px;min-width:max-content}.price-value{color:#32394d;font-family:'Inter', sans-serif;font-size:14px;font-weight:700;line-height:1.1;margin-top:2px}.separator{height:1px;background:#e6eaf2;margin:0;flex-shrink:0}.action-button{background:#ffffff;border:none;border-top:1px solid #e6eaf2;padding:12px;cursor:pointer;transition:all 0.2s ease-in-out;display:flex;align-items:center;justify-content:center;gap:8px;height:40px;flex-shrink:0}.action-button--disabled{opacity:0.3;cursor:not-allowed}.button-text{font-family:'Inter', sans-serif;font-size:14px;font-weight:700;line-height:1.1;color:#f49a3d;text-align:center;white-space:nowrap}`;
|
|
4
|
+
|
|
5
|
+
const DropiCardProduct = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.dropiProductClick = createEvent(this, "dropiProductClick", 7);
|
|
9
|
+
this.dropiFavoriteChange = createEvent(this, "dropiFavoriteChange", 7);
|
|
10
|
+
this.dropiAddProduct = createEvent(this, "dropiAddProduct", 7);
|
|
11
|
+
this.dropiSupplierClick = createEvent(this, "dropiSupplierClick", 7);
|
|
12
|
+
}
|
|
13
|
+
/** Product image URL */
|
|
14
|
+
image = '';
|
|
15
|
+
/** Product name */
|
|
16
|
+
productName = '';
|
|
17
|
+
/** Sale / supplier price (Precio proveedor) */
|
|
18
|
+
salePrice = 0;
|
|
19
|
+
/** Suggested price for the dropshipper (Precio sugerido) */
|
|
20
|
+
suggestedPrice = 0;
|
|
21
|
+
/** Price currency symbol */
|
|
22
|
+
currency = '$';
|
|
23
|
+
/** Supplier / store name */
|
|
24
|
+
supplier = '';
|
|
25
|
+
/** Category label */
|
|
26
|
+
category = '';
|
|
27
|
+
/** Stock quantity (0 = Agotado) */
|
|
28
|
+
stock = 0;
|
|
29
|
+
/** Supplier category for insignia: 'verified' | 'premium' | 'exclusive' | '' */
|
|
30
|
+
supplierCategory = '';
|
|
31
|
+
/** Show favorite button */
|
|
32
|
+
showFavorite = true;
|
|
33
|
+
/** Is marked as favorite */
|
|
34
|
+
isFavorite = false;
|
|
35
|
+
/** Show "Enviar a cliente" button */
|
|
36
|
+
showAddButton = true;
|
|
37
|
+
/** Emitted when card is clicked — matches Angular 'onProductClick' */
|
|
38
|
+
dropiProductClick;
|
|
39
|
+
/** Emitted when favorite toggled — matches Angular 'changeFavorite' */
|
|
40
|
+
dropiFavoriteChange;
|
|
41
|
+
/** Emitted when "Enviar a cliente" button clicked */
|
|
42
|
+
dropiAddProduct;
|
|
43
|
+
/** Emitted when supplier name clicked */
|
|
44
|
+
dropiSupplierClick;
|
|
45
|
+
formatPrice(val) {
|
|
46
|
+
if (val == null)
|
|
47
|
+
return '0';
|
|
48
|
+
return val.toLocaleString('es-CO');
|
|
49
|
+
}
|
|
50
|
+
get inStock() {
|
|
51
|
+
return this.stock > 0;
|
|
52
|
+
}
|
|
53
|
+
getStockColor() {
|
|
54
|
+
if (this.stock === 0)
|
|
55
|
+
return 'var(--Error-Error-500, #f46a6b)';
|
|
56
|
+
if (this.stock <= 10)
|
|
57
|
+
return 'var(--Warning-Warning-500, #f59e0b)';
|
|
58
|
+
return 'var(--Success-Success-500, #0abb87)';
|
|
59
|
+
}
|
|
60
|
+
render() {
|
|
61
|
+
return (h("div", { key: '2fe4ce42e1c331a99fd1171c82e6e48bfb5dbff0', class: "dropi-card-product", onClick: () => this.dropiProductClick.emit() }, h("div", { key: '3f94077ee059e347f3ff4fff808a3a3f3a0ac827', class: "product-image-container" }, h("div", { key: '1d6e8181cc630ab03efc90e316c349dfe9765b46', class: "product-image" }, h("img", { key: 'f6647c21ac24d378482c6e6fe5220d6d18ff694b', src: this.image || '', alt: this.productName, onError: (e) => {
|
|
62
|
+
e.target.src = './assets/utils/no-image.jpg';
|
|
63
|
+
}, class: !this.image ? 'error-img' : '' }), this.showFavorite && (h("button", { key: '37c23af5e1345e2f2b2ac42dd38f88eb17254889', class: { 'favorite-button': true, 'favorite-active': this.isFavorite }, onClick: (e) => {
|
|
64
|
+
e.stopPropagation();
|
|
65
|
+
this.isFavorite = !this.isFavorite;
|
|
66
|
+
this.dropiFavoriteChange.emit(this.isFavorite);
|
|
67
|
+
}, "aria-label": "Favorito" }, h("dropi-icon", { key: 'c6d6c87dcb5ae0f9a0d416667a3d39c7e153b7a6', name: this.isFavorite ? 'Heart-solid' : 'Heart', iconWidth: "18px", iconHeight: "18px", color: this.isFavorite ? '#fff' : '#858ea6' }))))), h("div", { key: '66dbcb028acb35e9a43502e9ff9a00fd2ebf8bf2', class: "product-info" }, this.supplierCategory && (h("dropi-ilustration-icon", { key: 'fd3d94e953a6b91418decc09ed426755a85bac1b', class: "supplier-insignia", type: "insignia", stateInsignia: this.supplierCategory, tagProduct: true })), h("div", { key: '45817e3bb0bfdaa0ec8cb4a23fdac1bb943e93dc', class: "product-header" }, this.category && (h("span", { key: 'c721519a5339a2ac40d20c283bbe8797b78e4b27', class: "category" }, this.category)), h("div", { key: '49f5013738dfffcdb83dfde628f5d1d21164c3d2', class: "stock-info" }, h("span", { key: 'bd49d5069d07b3ae10ac9c85a4b84bbb573f926e', class: "stock-label" }, "Stock:"), h("span", { key: 'd0eefb88240c13c9c56e7470e79cbacc9d86caf4', class: "stock-value", style: { color: this.getStockColor() } }, this.stock === 0 ? 'Agotado' : this.stock))), h("h3", { key: 'a880d0df13af0b75d553daf18e876905b93e6ef1', class: "product-name" }, this.productName), this.supplier && (h("div", { key: 'faa82e269979084e7510b6a17fb1f3caee8ad181', class: "supplier-info" }, h("span", { key: 'b4b223620c58cb30945b1c6be50559614937eb5f', class: "supplier-label" }, "Proveedor:"), h("span", { key: '989580f42383c3b6adb6484a493d1293a2a11904', class: "supplier-name", onClick: (e) => { e.stopPropagation(); this.dropiSupplierClick.emit(); } }, this.supplier))), h("div", { key: '451c1ab830c7ab38c4e414e94f11f63ffcf86162', class: "price-container" }, h("div", { key: '755f3f8aac6f7b1d458d28b74dec2734b42794a6', class: "price-item" }, h("span", { key: 'fff0a718b4f22641adcd28bbcb7e81a0f21755e9', class: "price-label" }, "Precio proveedor"), h("span", { key: '5bb6843a4a293195f0dbda5c3eccfc4f38c719b1', class: "price-value" }, this.currency, " ", this.formatPrice(this.salePrice))), h("div", { key: '468b1d7596ec5d727846a087b5d89461c5fef858', class: "price-item" }, h("span", { key: '91b15e4d58d27997b2dfdb9c73fd417a8f8ba5fb', class: "price-label" }, "Precio sugerido"), h("span", { key: '378483760ffac07491f5b65b37d5e27d41423ec5', class: "price-value" }, this.currency, " ", this.formatPrice(this.suggestedPrice))))), h("div", { key: '71467832049894083ea3454618a12d082cb15844', class: "separator" }), this.showAddButton && (h("div", { key: 'f9f0450e3dfa2b91ae7caa468811cc739d7a280e', class: { 'action-button': true, 'action-button--disabled': !this.inStock }, onClick: (e) => {
|
|
68
|
+
e.stopPropagation();
|
|
69
|
+
if (this.inStock)
|
|
70
|
+
this.dropiAddProduct.emit();
|
|
71
|
+
} }, h("dropi-icon", { key: '50a9fad974460c2728fb1fca74628d093cbb1875', name: "Shopping-cart-arrow-rigth", iconWidth: "20px", iconHeight: "20px", color: "#f49a3d" }), h("span", { key: 'f5ac44dd20e01bc644e863c3cbf51e3493821e70', class: "button-text" }, "Enviar a cliente")))));
|
|
72
|
+
}
|
|
73
|
+
};
|
|
74
|
+
DropiCardProduct.style = dropiCardProductCss();
|
|
75
|
+
|
|
76
|
+
export { DropiCardProduct as dropi_card_product };
|
|
77
|
+
//# sourceMappingURL=dropi-card-product.entry.esm.js.map
|
|
78
|
+
|
|
79
|
+
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AO,EAAE,EAC1E,OAAO,EAAE,CAAC,CAAC,KAAI;gBAAG,CAAC,CAAC,eAAe,EAAE;gBAAE,IAAI,IAAI,CAAC,OAAO;AAAE,oBAAA,IAAI,CAAC,eAAe,CAAC,IAAI,EAAE;aAAG,EAAA,EAEvF,CAAA,CAAA,YAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,IAAI,EAAC,2BAA2B,EAChC,SAAS,EAAC,MAAM,EAChB,UAAU,EAAC,MAAM,EACjB,KAAK,EAAC,SAAS,EAAA,CACf,EACF,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAM,KAAK,EAAC,aAAa,EAAA,EAAA,kBAAA,CAAwB,CAC7C,CACP,CACG;;;;;;;","names":[],"sources":["src/components/dropi-card-product/dropi-card-product.css?tag=dropi-card-product&encapsulation=shadow","src/components/dropi-card-product/dropi-card-product.tsx"],"sourcesContent":[":host {\n display: block;\n font-family: 'Inter', sans-serif;\n}\n*, *::before, *::after { box-sizing: border-box; }\n\n/* ── Card wrapper ── */\n.dropi-card-product {\n position: relative;\n background: #ffffff;\n border-radius: 8px;\n overflow: hidden;\n transition: all 0.2s ease-in-out;\n cursor: pointer;\n display: flex;\n flex-direction: column;\n height: 100%;\n box-sizing: border-box;\n width: 100%;\n max-width: 450px;\n box-shadow: none;\n}\n\n/* ── Image container ── */\n.product-image-container {\n padding: 4px;\n flex-shrink: 0;\n}\n\n.product-image {\n position: relative;\n width: 100%;\n aspect-ratio: 1;\n border-radius: 8px;\n border: 1px solid #c3c9d9;\n overflow: hidden;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: #f8f9fa;\n}\n\n.product-image img {\n width: 100%;\n height: 100%;\n object-fit: cover;\n border-radius: 8px;\n}\n\n.product-image img.error-img {\n object-fit: contain;\n}\n\n/* ── Favorite button ── */\n.favorite-button {\n position: absolute;\n bottom: 5px;\n right: 6px;\n border-radius: 8px;\n padding: 12px;\n cursor: pointer;\n transition: all 0.2s ease-in-out;\n z-index: 2;\n display: flex;\n align-items: center;\n justify-content: center;\n width: 42px;\n height: 40px;\n background: #ffffff;\n border: 1px solid #858ea6;\n}\n\n.favorite-button.favorite-active {\n background: var(--Primary-Primary-500, #f49a3d);\n border: 1px solid var(--Primary-Primary-500, #f49a3d);\n}\n\n/* ── Product info ── */\n.product-info {\n position: relative;\n padding: 8px;\n display: flex;\n flex-direction: column;\n gap: 4px;\n flex: 1;\n justify-content: space-between;\n}\n\n/* ── Supplier insignia — overlaps from top ── */\n.supplier-insignia {\n position: absolute;\n top: -24px;\n left: 0px;\n}\n\n/* ── Header: category + stock ── */\n.product-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n width: 100%;\n height: 26px;\n}\n\n.category {\n color: #69738c;\n font-family: 'Inter', sans-serif;\n font-size: 12px;\n font-weight: 400;\n line-height: 1.5;\n flex: 1;\n}\n\n.stock-info {\n display: flex;\n align-items: center;\n gap: 2px;\n font-family: 'Inter', sans-serif;\n font-size: 12px;\n font-weight: 400;\n line-height: 1.5;\n}\n\n.stock-label {\n color: #69738c;\n}\n\n.stock-value {\n font-weight: 500;\n}\n\n/* ── Product name ── */\n.product-name {\n color: #32394d;\n font-family: 'Inter', sans-serif;\n font-size: 16px;\n font-weight: 500;\n line-height: 1.5;\n margin: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n}\n\n/* ── Supplier ── */\n.supplier-info {\n font-family: 'Inter', sans-serif;\n font-size: 12px;\n line-height: 1.2;\n}\n\n.supplier-label {\n color: #69738c;\n font-weight: 400;\n}\n\n.supplier-name {\n color: #50a5f1;\n font-weight: 400;\n margin-left: 4px;\n cursor: pointer;\n}\n\n/* ── Prices ── */\n.price-container {\n display: flex;\n gap: 8px;\n margin-top: 4px;\n}\n\n.price-item {\n flex: 1;\n display: flex;\n flex-direction: column;\n}\n\n.price-label {\n color: #69738c;\n font-family: 'Inter', sans-serif;\n font-size: 12px;\n font-weight: 400;\n line-height: 1.5;\n height: 18px;\n min-width: max-content;\n}\n\n.price-value {\n color: #32394d;\n font-family: 'Inter', sans-serif;\n font-size: 14px;\n font-weight: 700;\n line-height: 1.1;\n margin-top: 2px;\n}\n\n/* ── Separator ── */\n.separator {\n height: 1px;\n background: #e6eaf2;\n margin: 0;\n flex-shrink: 0;\n}\n\n/* ── Action button ── */\n.action-button {\n background: #ffffff;\n border: none;\n border-top: 1px solid #e6eaf2;\n padding: 12px;\n cursor: pointer;\n transition: all 0.2s ease-in-out;\n display: flex;\n align-items: center;\n justify-content: center;\n gap: 8px;\n height: 40px;\n flex-shrink: 0;\n}\n\n.action-button--disabled {\n opacity: 0.3;\n cursor: not-allowed;\n}\n\n.button-text {\n font-family: 'Inter', sans-serif;\n font-size: 14px;\n font-weight: 700;\n line-height: 1.1;\n color: #f49a3d;\n text-align: center;\n white-space: nowrap;\n}\n","import { Component, Prop, Event, EventEmitter, h } from '@stencil/core';\n\n/**\n * @component dropi-card-product\n * Product card showing image, supplier insignia, name, stock, prices and action button.\n */\n@Component({\n tag: 'dropi-card-product',\n styleUrl: 'dropi-card-product.css',\n shadow: true,\n})\nexport class DropiCardProduct {\n /** Product image URL */\n @Prop() image: string = '';\n /** Product name */\n @Prop() productName: string = '';\n /** Sale / supplier price (Precio proveedor) */\n @Prop() salePrice: number = 0;\n /** Suggested price for the dropshipper (Precio sugerido) */\n @Prop() suggestedPrice: number = 0;\n /** Price currency symbol */\n @Prop() currency: string = '$';\n /** Supplier / store name */\n @Prop() supplier: string = '';\n /** Category label */\n @Prop() category: string = '';\n /** Stock quantity (0 = Agotado) */\n @Prop() stock: number = 0;\n /** Supplier category for insignia: 'verified' | 'premium' | 'exclusive' | '' */\n @Prop() supplierCategory: 'verified' | 'premium' | 'exclusive' | '' = '';\n /** Show favorite button */\n @Prop() showFavorite: boolean = true;\n /** Is marked as favorite */\n @Prop({ mutable: true }) isFavorite: boolean = false;\n /** Show \"Enviar a cliente\" button */\n @Prop() showAddButton: boolean = true;\n\n /** Emitted when card is clicked — matches Angular 'onProductClick' */\n @Event() dropiProductClick: EventEmitter<void>;\n /** Emitted when favorite toggled — matches Angular 'changeFavorite' */\n @Event() dropiFavoriteChange: EventEmitter<boolean>;\n /** Emitted when \"Enviar a cliente\" button clicked */\n @Event() dropiAddProduct: EventEmitter<void>;\n /** Emitted when supplier name clicked */\n @Event() dropiSupplierClick: EventEmitter<void>;\n\n private formatPrice(val: number): string {\n if (val == null) return '0';\n return val.toLocaleString('es-CO');\n }\n\n private get inStock(): boolean {\n return this.stock > 0;\n }\n\n private getStockColor(): string {\n if (this.stock === 0) return 'var(--Error-Error-500, #f46a6b)';\n if (this.stock <= 10) return 'var(--Warning-Warning-500, #f59e0b)';\n return 'var(--Success-Success-500, #0abb87)';\n }\n\n render() {\n return (\n <div class=\"dropi-card-product\" onClick={() => this.dropiProductClick.emit()}>\n\n {/* ── Image container ── */}\n <div class=\"product-image-container\">\n <div class=\"product-image\">\n <img\n src={this.image || ''}\n alt={this.productName}\n onError={(e) => {\n (e.target as HTMLImageElement).src = './assets/utils/no-image.jpg';\n }}\n class={!this.image ? 'error-img' : ''}\n />\n\n {/* Favorite button — bottom right */}\n {this.showFavorite && (\n <button\n class={{ 'favorite-button': true, 'favorite-active': this.isFavorite }}\n onClick={(e) => {\n e.stopPropagation();\n this.isFavorite = !this.isFavorite;\n this.dropiFavoriteChange.emit(this.isFavorite);\n }}\n aria-label=\"Favorito\"\n >\n <dropi-icon\n name={this.isFavorite ? 'Heart-solid' : 'Heart'}\n iconWidth=\"18px\"\n iconHeight=\"18px\"\n color={this.isFavorite ? '#fff' : '#858ea6'}\n />\n </button>\n )}\n </div>\n </div>\n\n {/* ── Product info ── */}\n <div class=\"product-info\">\n\n {/* Insignia — overlapping from top */}\n {this.supplierCategory && (\n <dropi-ilustration-icon\n class=\"supplier-insignia\"\n type=\"insignia\"\n stateInsignia={this.supplierCategory as any}\n tagProduct={true}\n />\n )}\n\n {/* Category + Stock row */}\n <div class=\"product-header\">\n {this.category && (\n <span class=\"category\">{this.category}</span>\n )}\n <div class=\"stock-info\">\n <span class=\"stock-label\">Stock:</span>\n <span class=\"stock-value\" style={{ color: this.getStockColor() }}>\n {this.stock === 0 ? 'Agotado' : this.stock}\n </span>\n </div>\n </div>\n\n {/* Product name */}\n <h3 class=\"product-name\">{this.productName}</h3>\n\n {/* Supplier */}\n {this.supplier && (\n <div class=\"supplier-info\">\n <span class=\"supplier-label\">Proveedor:</span>\n <span\n class=\"supplier-name\"\n onClick={(e) => { e.stopPropagation(); this.dropiSupplierClick.emit(); }}\n >\n {this.supplier}\n </span>\n </div>\n )}\n\n {/* Two price columns */}\n <div class=\"price-container\">\n <div class=\"price-item\">\n <span class=\"price-label\">Precio proveedor</span>\n <span class=\"price-value\">{this.currency} {this.formatPrice(this.salePrice)}</span>\n </div>\n <div class=\"price-item\">\n <span class=\"price-label\">Precio sugerido</span>\n <span class=\"price-value\">{this.currency} {this.formatPrice(this.suggestedPrice)}</span>\n </div>\n </div>\n </div>\n\n {/* ── Separator ── */}\n <div class=\"separator\"></div>\n\n {/* ── Action button ── */}\n {this.showAddButton && (\n <div\n class={{ 'action-button': true, 'action-button--disabled': !this.inStock }}\n onClick={(e) => { e.stopPropagation(); if (this.inStock) this.dropiAddProduct.emit(); }}\n >\n <dropi-icon\n name=\"Shopping-cart-arrow-rigth\"\n iconWidth=\"20px\"\n iconHeight=\"20px\"\n color=\"#f49a3d\"\n />\n <span class=\"button-text\">Enviar a cliente</span>\n </div>\n )}\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { r as registerInstance, d as createEvent, h } from './index-Cvp2LQOM.js';
|
|
2
|
+
|
|
3
|
+
const dropiCardSectionCss = () => `:host{display:block;width:100%}*,*::before,*::after{box-sizing:border-box}.card-section{display:flex;align-items:center;justify-content:space-between;gap:var(--Size-4, 16px);padding:var(--Size-3, 12px) var(--Size-4, 16px);background:var(--Neutral-White, #ffffff);border:1px solid var(--Gray-Gray-100, #e6eaf2);border-radius:var(--Border-2, 8px)}.card-section__text{flex:1}.card-section__title{margin:0 0 4px;font-family:inherit;font-weight:var(--font-weight-bold, 700);color:var(--Gray-Gray-800, #1f2433)}h5.card-section__title{font-size:var(--font-size-m, 14px)}h6.card-section__title{font-size:var(--font-size-s, 12px)}.card-section__desc{margin:0;font-size:var(--font-size-xs, 10px);color:var(--Gray-Gray-500, #69738c)}.card-section__control{flex-shrink:0}.card-section__dropdown-btn{display:flex;align-items:center;background:none;border:none;padding:0;cursor:pointer}`;
|
|
4
|
+
|
|
5
|
+
const DropiCardSection = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.dropiChange = createEvent(this, "dropiChange", 7);
|
|
9
|
+
this.dropiClick = createEvent(this, "dropiClick", 7);
|
|
10
|
+
}
|
|
11
|
+
/** Section title — matches Angular 'title' */
|
|
12
|
+
title = 'title';
|
|
13
|
+
/** Section description */
|
|
14
|
+
description = 'Description';
|
|
15
|
+
/** Control type on the right */
|
|
16
|
+
typeElement = 'dropdown';
|
|
17
|
+
/** Title size variant */
|
|
18
|
+
type = 'important';
|
|
19
|
+
/** Switch checked state */
|
|
20
|
+
isChecked = false;
|
|
21
|
+
/** Emitted when switch changes */
|
|
22
|
+
dropiChange;
|
|
23
|
+
/** Emitted when dropdown icon is clicked */
|
|
24
|
+
dropiClick;
|
|
25
|
+
render() {
|
|
26
|
+
return (h("div", { key: '06fe2a580fb23484419ea4b1c41a265facb722de', class: "card-section" }, h("div", { key: '1020ea256b0311a200a721387b3ecb8d0f3809ab', class: "card-section__text" }, this.type === 'important'
|
|
27
|
+
? h("h5", { class: "card-section__title card-section__title--important" }, this.title)
|
|
28
|
+
: h("h6", { class: "card-section__title" }, this.title), this.description && h("p", { key: '52ea93b6b2736c4c6e3ebb953c2878db90d34b4c', class: "card-section__desc" }, this.description)), h("div", { key: '7ec0ed96e43b45256fd5dec5ee24b0dfd6488403', class: "card-section__control" }, this.typeElement === 'switch' ? (h("dropi-switch", { isChecked: this.isChecked, onDropiChange: (e) => {
|
|
29
|
+
this.isChecked = e.detail;
|
|
30
|
+
this.dropiChange.emit(e.detail);
|
|
31
|
+
} })) : (h("button", { class: "card-section__dropdown-btn", onClick: () => this.dropiClick.emit(), "aria-label": "Expandir" }, h("dropi-icon", { name: "Dropdown-down", iconWidth: "20px", iconHeight: "20px", color: "Gray-Gray-500" }))))));
|
|
32
|
+
}
|
|
33
|
+
};
|
|
34
|
+
DropiCardSection.style = dropiCardSectionCss();
|
|
35
|
+
|
|
36
|
+
export { DropiCardSection as dropi_card_section };
|
|
37
|
+
//# sourceMappingURL=dropi-card-section.entry.esm.js.map
|
|
38
|
+
|
|
39
|
+
//# sourceMappingURL=dropi-card-section.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"dropi-card-section.entry.js","mappings":";;AAAA,MAAM,mBAAmB,GAAG,MAAM,CAAC,w2BAAw2B,CAAC;;MCW/3B,gBAAgB,GAAA,MAAA;;;;;;;IAEnB,KAAK,GAAW,OAAO;;IAEvB,WAAW,GAAW,aAAa;;IAEnC,WAAW,GAA0B,UAAU;;IAE/C,IAAI,GAA2B,WAAW;;IAEzB,SAAS,GAAY,KAAK;;AAG1C,IAAA,WAAW;;AAEX,IAAA,UAAU;IAEnB,MAAM,GAAA;AACJ,QAAA,QACE,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAC,cAAc,EAAA,EACvB,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAC,oBAAoB,EAAA,EAC5B,IAAI,CAAC,IAAI,KAAK;AACb,cAAE,UAAI,KAAK,EAAC,oDAAoD,EAAA,EAAE,IAAI,CAAC,KAAK;AAC5E,cAAE,UAAI,KAAK,EAAC,qBAAqB,EAAA,EAAE,IAAI,CAAC,KAAK,CAAM,EAEpD,IAAI,CAAC,WAAW,IAAI,CAAA,CAAA,GAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAG,KAAK,EAAC,oBAAoB,EAAA,EAAE,IAAI,CAAC,WAAW,CAAK,CACrE,EAEN,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAC,uBAAuB,EAAA,EAC/B,IAAI,CAAC,WAAW,KAAK,QAAQ,IAC5B,CAAA,CAAA,cAAA,EAAA,EACE,SAAS,EAAE,IAAI,CAAC,SAAS,EACzB,aAAa,EAAE,CAAC,CAAuB,KAAI;AACzC,gBAAA,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC,MAAM;gBACzB,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC;AACjC,aAAC,EAAA,CACD,KAEF,CAAA,CAAA,QAAA,EAAA,EAAQ,KAAK,EAAC,4BAA4B,EAAC,OAAO,EAAE,MAAM,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE,EAAA,YAAA,EAAa,UAAU,EAAA,EACrG,CAAA,CAAA,YAAA,EAAA,EAAY,IAAI,EAAC,eAAe,EAAC,SAAS,EAAC,MAAM,EAAC,UAAU,EAAC,MAAM,EAAC,KAAK,EAAC,eAAe,EAAA,CAAG,CACrF,CACV,CACG,CACF;;;;;;;","names":[],"sources":["src/components/dropi-card-section/dropi-card-section.css?tag=dropi-card-section&encapsulation=shadow","src/components/dropi-card-section/dropi-card-section.tsx"],"sourcesContent":[":host { display: block; width: 100%; }\n*, *::before, *::after { box-sizing: border-box; }\n\n.card-section {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: var(--Size-4, 16px);\n padding: var(--Size-3, 12px) var(--Size-4, 16px);\n background: var(--Neutral-White, #ffffff);\n border: 1px solid var(--Gray-Gray-100, #e6eaf2);\n border-radius: var(--Border-2, 8px);\n}\n\n.card-section__text { flex: 1; }\n\n.card-section__title {\n margin: 0 0 4px;\n font-family: inherit;\n font-weight: var(--font-weight-bold, 700);\n color: var(--Gray-Gray-800, #1f2433);\n}\n\nh5.card-section__title { font-size: var(--font-size-m, 14px); }\nh6.card-section__title { font-size: var(--font-size-s, 12px); }\n\n.card-section__desc {\n margin: 0;\n font-size: var(--font-size-xs, 10px);\n color: var(--Gray-Gray-500, #69738c);\n}\n\n.card-section__control { flex-shrink: 0; }\n\n.card-section__dropdown-btn {\n display: flex;\n align-items: center;\n background: none;\n border: none;\n padding: 0;\n cursor: pointer;\n}\n","import { Component, Prop, Event, EventEmitter, h } from '@stencil/core';\n\n/**\n * @component dropi-card-section\n * Section card with title, description and a switch or dropdown control.\n */\n@Component({\n tag: 'dropi-card-section',\n styleUrl: 'dropi-card-section.css',\n shadow: true,\n})\nexport class DropiCardSection {\n /** Section title — matches Angular 'title' */\n @Prop() title: string = 'title';\n /** Section description */\n @Prop() description: string = 'Description';\n /** Control type on the right */\n @Prop() typeElement: 'dropdown' | 'switch' = 'dropdown';\n /** Title size variant */\n @Prop() type: 'medium' | 'important' = 'important';\n /** Switch checked state */\n @Prop({ mutable: true }) isChecked: boolean = false;\n\n /** Emitted when switch changes */\n @Event() dropiChange: EventEmitter<boolean>;\n /** Emitted when dropdown icon is clicked */\n @Event() dropiClick: EventEmitter<void>;\n\n render() {\n return (\n <div class=\"card-section\">\n <div class=\"card-section__text\">\n {this.type === 'important'\n ? <h5 class=\"card-section__title card-section__title--important\">{this.title}</h5>\n : <h6 class=\"card-section__title\">{this.title}</h6>\n }\n {this.description && <p class=\"card-section__desc\">{this.description}</p>}\n </div>\n\n <div class=\"card-section__control\">\n {this.typeElement === 'switch' ? (\n <dropi-switch\n isChecked={this.isChecked}\n onDropiChange={(e: CustomEvent<boolean>) => {\n this.isChecked = e.detail;\n this.dropiChange.emit(e.detail);\n }}\n />\n ) : (\n <button class=\"card-section__dropdown-btn\" onClick={() => this.dropiClick.emit()} aria-label=\"Expandir\">\n <dropi-icon name=\"Dropdown-down\" iconWidth=\"20px\" iconHeight=\"20px\" color=\"Gray-Gray-500\" />\n </button>\n )}\n </div>\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
import { r as registerInstance, d as createEvent, a as getElement, h } from './index-Cvp2LQOM.js';
|
|
2
|
+
|
|
3
|
+
const dropiCarouselCss = () => `:host{display:block;width:100%}*,*::before,*::after{box-sizing:border-box}.dropi-carousel-container{display:flex;flex-direction:column;position:relative;width:100%;max-width:100%;overflow:hidden;padding:0 var(--Size-4)}.dropi-carousel-content{display:flex;align-items:center;position:relative;padding:1rem 0;width:100%}.dropi-carousel-items-content{overflow:hidden;flex:1;padding:0;width:100%;max-width:100%}.dropi-carousel-items-container{display:flex;padding-bottom:var(--Size-3);will-change:transform}.dropi-carousel-item{flex:0 0 auto;padding:0 0.5rem;box-sizing:border-box}.dropi-carousel-item>*{width:100%;box-sizing:border-box;display:block}.dropi-carousel-nav{display:flex;width:40px;height:40px;justify-content:center;align-items:center;cursor:pointer;transition:all 0.2s;flex-shrink:0;z-index:1;border-radius:var(--Border-5);background:var(--Neutral-White, #fff);box-shadow:var(--Shadow-medium);border:none;appearance:none;padding:0}.dropi-carousel-nav:hover{background:var(--Gray-Gray-50)}.dropi-carousel-nav:disabled{opacity:0.4;cursor:not-allowed;box-shadow:none}.dropi-carousel-prev{margin-right:1rem}.dropi-carousel-next{margin-left:1rem}.dropi-carousel-indicators{display:flex;justify-content:center;gap:0.5rem;list-style:none;padding:1rem 0 0 0;margin:0}.dropi-carousel-indicators li{cursor:pointer}.dropi-carousel-indicators li button{width:1rem;height:1rem;border-radius:50%;border:1px solid var(--Gray-Gray-100, #eceef4);background:var(--Neutral-White, #fff);cursor:pointer;transition:all 0.2s;padding:0}.dropi-carousel-indicators li.active button{background:var(--Primary-Primary-500);border-color:var(--Primary-Primary-500)}.dropi-carousel-indicators li:hover button{background:var(--Gray-Gray-200)}.vertical .dropi-carousel-content{flex-direction:column}.vertical .dropi-carousel-items-container{flex-direction:column}.vertical .dropi-carousel-prev{margin:0 0 1rem 0}.vertical .dropi-carousel-next{margin:1rem 0 0 0}@media (max-width: 768px){.dropi-carousel-container{padding:0}.dropi-carousel-item{padding:0 0.25rem}}`;
|
|
4
|
+
|
|
5
|
+
const DropiCarousel = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.dropiPageChange = createEvent(this, "dropiPageChange", 7);
|
|
9
|
+
this.dropiPage = createEvent(this, "dropiPage", 7);
|
|
10
|
+
}
|
|
11
|
+
get el() { return getElement(this); }
|
|
12
|
+
/** Items to display (Array of URLs or objects) */
|
|
13
|
+
value = [];
|
|
14
|
+
/** Active page index */
|
|
15
|
+
page = 0;
|
|
16
|
+
/** Number of items visible per page */
|
|
17
|
+
numVisible = 1;
|
|
18
|
+
/** Number of items to scroll per click */
|
|
19
|
+
numScroll = 1;
|
|
20
|
+
/** Orientation of the carousel */
|
|
21
|
+
orientation = 'horizontal';
|
|
22
|
+
/** Show navigation arrows */
|
|
23
|
+
showNavigators = true;
|
|
24
|
+
/** Show dot indicators */
|
|
25
|
+
showIndicators = true;
|
|
26
|
+
/** Autoplay interval in ms (0 = disabled) */
|
|
27
|
+
autoplayInterval = 0;
|
|
28
|
+
/** Infinite scrolling */
|
|
29
|
+
circular = false;
|
|
30
|
+
parsedValue = [];
|
|
31
|
+
internalPage = 0;
|
|
32
|
+
isAnimating = false;
|
|
33
|
+
totalPages = 0;
|
|
34
|
+
itemsContainer;
|
|
35
|
+
timer;
|
|
36
|
+
dropiPageChange;
|
|
37
|
+
dropiPage;
|
|
38
|
+
handleValue(val) {
|
|
39
|
+
this.parsedValue = typeof val === 'string' ? JSON.parse(val) : (val || []);
|
|
40
|
+
this.updateTotalPages();
|
|
41
|
+
this.updateTransform();
|
|
42
|
+
}
|
|
43
|
+
handlePage(val) {
|
|
44
|
+
this.internalPage = val;
|
|
45
|
+
this.updateTransform();
|
|
46
|
+
}
|
|
47
|
+
componentWillLoad() {
|
|
48
|
+
if (!this.value || (Array.isArray(this.value) && this.value.length === 0)) {
|
|
49
|
+
const attrValue = this.el.getAttribute('value');
|
|
50
|
+
if (attrValue)
|
|
51
|
+
this.value = attrValue;
|
|
52
|
+
}
|
|
53
|
+
this.handleValue(this.value);
|
|
54
|
+
this.internalPage = this.page;
|
|
55
|
+
}
|
|
56
|
+
componentDidLoad() {
|
|
57
|
+
this.updateTransform();
|
|
58
|
+
if (this.autoplayInterval > 0) {
|
|
59
|
+
this.startAutoplay();
|
|
60
|
+
}
|
|
61
|
+
window.addEventListener('resize', this.onResize);
|
|
62
|
+
}
|
|
63
|
+
disconnectedCallback() {
|
|
64
|
+
this.stopAutoplay();
|
|
65
|
+
window.removeEventListener('resize', this.onResize);
|
|
66
|
+
}
|
|
67
|
+
onResize = () => {
|
|
68
|
+
this.updateTotalPages();
|
|
69
|
+
this.updateTransform();
|
|
70
|
+
};
|
|
71
|
+
startAutoplay() {
|
|
72
|
+
this.timer = setInterval(() => this.navForward(), this.autoplayInterval);
|
|
73
|
+
}
|
|
74
|
+
stopAutoplay() {
|
|
75
|
+
if (this.timer)
|
|
76
|
+
clearInterval(this.timer);
|
|
77
|
+
}
|
|
78
|
+
updateTotalPages() {
|
|
79
|
+
if (!this.parsedValue.length || this.parsedValue.length <= this.numVisible) {
|
|
80
|
+
this.totalPages = 1;
|
|
81
|
+
return;
|
|
82
|
+
}
|
|
83
|
+
const totalItems = this.parsedValue.length;
|
|
84
|
+
const remainingItems = totalItems - this.numVisible;
|
|
85
|
+
this.totalPages = Math.ceil(remainingItems / this.numScroll) + 1;
|
|
86
|
+
}
|
|
87
|
+
updateTransform() {
|
|
88
|
+
if (!this.itemsContainer)
|
|
89
|
+
return;
|
|
90
|
+
const prop = this.orientation === 'vertical' ? 'translateY' : 'translateX';
|
|
91
|
+
const firstItem = this.itemsContainer.querySelector('.dropi-carousel-item');
|
|
92
|
+
if (!firstItem)
|
|
93
|
+
return;
|
|
94
|
+
const itemSize = this.orientation === 'vertical' ? firstItem.offsetHeight : firstItem.offsetWidth;
|
|
95
|
+
const itemsScrolled = this.internalPage * this.numScroll;
|
|
96
|
+
const maxScroll = Math.max(0, this.parsedValue.length - this.numVisible);
|
|
97
|
+
const safeScroll = Math.min(itemsScrolled, maxScroll);
|
|
98
|
+
const translateValue = -(safeScroll * itemSize);
|
|
99
|
+
this.itemsContainer.style.transform = `${prop}(${translateValue}px)`;
|
|
100
|
+
}
|
|
101
|
+
navForward = (e) => {
|
|
102
|
+
if (e)
|
|
103
|
+
e.preventDefault();
|
|
104
|
+
if (this.circular || this.internalPage < this.totalPages - 1) {
|
|
105
|
+
this.isAnimating = true;
|
|
106
|
+
this.internalPage = (this.internalPage + 1) % this.totalPages;
|
|
107
|
+
this.page = this.internalPage;
|
|
108
|
+
this.updateTransform();
|
|
109
|
+
this.dropiPageChange.emit(this.internalPage);
|
|
110
|
+
setTimeout(() => (this.isAnimating = false), 500);
|
|
111
|
+
}
|
|
112
|
+
};
|
|
113
|
+
navBackward = (e) => {
|
|
114
|
+
if (e)
|
|
115
|
+
e.preventDefault();
|
|
116
|
+
if (this.circular || this.internalPage > 0) {
|
|
117
|
+
this.isAnimating = true;
|
|
118
|
+
this.internalPage = (this.internalPage - 1 + this.totalPages) % this.totalPages;
|
|
119
|
+
this.page = this.internalPage;
|
|
120
|
+
this.updateTransform();
|
|
121
|
+
this.dropiPageChange.emit(this.internalPage);
|
|
122
|
+
setTimeout(() => (this.isAnimating = false), 500);
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
onDotClick(index) {
|
|
126
|
+
this.isAnimating = true;
|
|
127
|
+
this.internalPage = index;
|
|
128
|
+
this.page = this.internalPage;
|
|
129
|
+
this.updateTransform();
|
|
130
|
+
this.dropiPageChange.emit(this.internalPage);
|
|
131
|
+
setTimeout(() => (this.isAnimating = false), 500);
|
|
132
|
+
}
|
|
133
|
+
render() {
|
|
134
|
+
const items = this.parsedValue;
|
|
135
|
+
if (!items.length)
|
|
136
|
+
return null;
|
|
137
|
+
const itemFlexBasis = `${100 / this.numVisible}%`;
|
|
138
|
+
return (h("div", { class: { 'dropi-carousel-container': true, 'vertical': this.orientation === 'vertical' } }, h("div", { class: "dropi-carousel-content" }, this.showNavigators && items.length > this.numVisible && (h("button", { class: "dropi-carousel-nav dropi-carousel-prev", disabled: !this.circular && this.internalPage === 0, onClick: (e) => this.navBackward(e), "aria-label": "Anterior" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", width: "24", height: "24", viewBox: "0 0 24 24", fill: "none" }, h("path", { d: "M14.659 17.5a.833.833 0 0 1-.589-.244l-4.43-4.431a.833.833 0 0 1 0-1.178l4.43-4.431a.834.834 0 0 1 1.179 1.178L11.42 12.25l3.83 3.829a.833.833 0 0 1-.59 1.421Z", fill: "#475066" })))), h("div", { class: "dropi-carousel-items-content" }, h("div", { class: "dropi-carousel-items-container", ref: (el) => (this.itemsContainer = el), style: { transition: this.isAnimating ? 'transform 0.5s ease' : 'none' } }, items.map((item, i) => (h("div", { class: "dropi-carousel-item", style: { flex: `0 0 ${itemFlexBasis}` } }, typeof item === 'string' ? (h("img", { src: item, alt: `Slide ${i + 1}` })) : (h("slot", { name: `item-${i}` }))))))), this.showNavigators && items.length > this.numVisible && (h("button", { class: "dropi-carousel-nav dropi-carousel-next", disabled: !this.circular && this.internalPage >= this.totalPages - 1, onClick: (e) => this.navForward(e), "aria-label": "Siguiente" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", width: "24", height: "24", viewBox: "0 0 24 24", fill: "none" }, h("path", { d: "M9.341 17.5a.833.833 0 0 0 .589-.244l4.43-4.431a.833.833 0 0 0 0-1.178l-4.43-4.431a.834.834 0 0 0-1.179 1.178l3.83 3.829-3.83 3.829a.833.833 0 0 0 .59 1.421Z", fill: "#475066" }))))), this.showIndicators && this.totalPages > 1 && (h("ul", { class: "dropi-carousel-indicators" }, Array.from({ length: this.totalPages }).map((_, i) => (h("li", { class: { active: i === this.internalPage }, onClick: () => this.onDotClick(i) }, h("button", { type: "button", "aria-label": `Página ${i + 1}` }))))))));
|
|
139
|
+
}
|
|
140
|
+
static get watchers() { return {
|
|
141
|
+
"value": [{
|
|
142
|
+
"handleValue": 0
|
|
143
|
+
}],
|
|
144
|
+
"page": [{
|
|
145
|
+
"handlePage": 0
|
|
146
|
+
}]
|
|
147
|
+
}; }
|
|
148
|
+
};
|
|
149
|
+
DropiCarousel.style = dropiCarouselCss();
|
|
150
|
+
|
|
151
|
+
export { DropiCarousel as dropi_carousel };
|
|
152
|
+
//# sourceMappingURL=dropi-carousel.entry.esm.js.map
|
|
153
|
+
|
|
154
|
+
//# sourceMappingURL=dropi-carousel.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"dropi-carousel.entry.js","mappings":";;AAAA,MAAM,gBAAgB,GAAG,MAAM,CAAC,y/DAAy/D,CAAC;;MCO7gE,aAAa,GAAA,MAAA;;;;;;;;IAIhB,KAAK,GAAmB,EAAE;;IAET,IAAI,GAAW,CAAC;;IAEjC,UAAU,GAAW,CAAC;;IAEtB,SAAS,GAAW,CAAC;;IAErB,WAAW,GAA8B,YAAY;;IAErD,cAAc,GAAQ,IAAI;;IAE1B,cAAc,GAAQ,IAAI;;IAE1B,gBAAgB,GAAW,CAAC;;IAE5B,QAAQ,GAAQ,KAAK;IAEZ,WAAW,GAAU,EAAE;IACvB,YAAY,GAAW,CAAC;IACxB,WAAW,GAAY,KAAK;IAC5B,UAAU,GAAW,CAAC;AAE/B,IAAA,cAAc;AACd,IAAA,KAAK;AAEJ,IAAA,eAAe;AACf,IAAA,SAAS;AAGlB,IAAA,WAAW,CAAC,GAAmB,EAAA;QAC7B,IAAI,CAAC,WAAW,GAAG,OAAO,GAAG,KAAK,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,GAAG,IAAI,EAAE,CAAC;QAC1E,IAAI,CAAC,gBAAgB,EAAE;QACvB,IAAI,CAAC,eAAe,EAAE;;AAIxB,IAAA,UAAU,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AAW,EAAC,IAAI,EAAC,MAAM,EAAA,EAC5F,CAAA,CAAA,MAAA,EAAA,EAAM,CAAC,EAAC,+JAA+J,EAAC,IAAI,EAAC,SAAS,EAAA,CAAG,CACrL,CACC,CACV,CACG,EAEL,IAAI,CAAC,cAAc,IAAI,IAAI,CAAC,UAAU,GAAG,CAAC,KACzC,CAAA,CAAA,IAAA,EAAA,EAAI,KAAK,EAAC,2BAA2B,EAAA,EAClC,KAAK,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,IAAI,CAAC,UAAU,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,MAChD,CAAA,CAAA,IAAA,EAAA,EAAI,KAAK,EAAE,EAAE,MAAM,EAAE,CAAC,KAAK,IAAI,CAAC,YAAY,EAAE,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,EAAA,EAC/E,CAAA,CAAA,QAAA,EAAA,EAAQ,IAAI,EAAC,QAAQ,EAAA,YAAA,EAAa,CAAA,OAAA,EAAU,CAAC,GAAG,CAAC,CAAA,CAAE,EAAA,CAAI,CACpD,CACN,CAAC,CACC,CACN,CACG;;;;;;;;;;;;;;;","names":[],"sources":["src/components/dropi-carousel/dropi-carousel.css?tag=dropi-carousel&encapsulation=shadow","src/components/dropi-carousel/dropi-carousel.tsx"],"sourcesContent":[":host {\n display: block;\n width: 100%;\n}\n\n*, *::before, *::after {\n box-sizing: border-box;\n}\n\n.dropi-carousel-container {\n display: flex;\n flex-direction: column;\n position: relative;\n width: 100%;\n max-width: 100%;\n overflow: hidden;\n padding: 0 var(--Size-4);\n}\n\n.dropi-carousel-content {\n display: flex;\n align-items: center;\n position: relative;\n padding: 1rem 0;\n width: 100%;\n}\n\n.dropi-carousel-items-content {\n overflow: hidden;\n flex: 1;\n padding: 0;\n width: 100%;\n max-width: 100%;\n}\n\n.dropi-carousel-items-container {\n display: flex;\n padding-bottom: var(--Size-3);\n will-change: transform;\n}\n\n.dropi-carousel-item {\n flex: 0 0 auto;\n padding: 0 0.5rem;\n box-sizing: border-box;\n}\n\n.dropi-carousel-item > * {\n width: 100%;\n box-sizing: border-box;\n display: block;\n}\n\n.dropi-carousel-nav {\n display: flex;\n width: 40px;\n height: 40px;\n justify-content: center;\n align-items: center;\n cursor: pointer;\n transition: all 0.2s;\n flex-shrink: 0;\n z-index: 1;\n border-radius: var(--Border-5);\n background: var(--Neutral-White, #fff);\n box-shadow: var(--Shadow-medium);\n border: none;\n appearance: none;\n padding: 0;\n}\n\n.dropi-carousel-nav:hover {\n background: var(--Gray-Gray-50);\n}\n\n.dropi-carousel-nav:disabled {\n opacity: 0.4;\n cursor: not-allowed;\n box-shadow: none;\n}\n\n.dropi-carousel-prev {\n margin-right: 1rem;\n}\n\n.dropi-carousel-next {\n margin-left: 1rem;\n}\n\n.dropi-carousel-indicators {\n display: flex;\n justify-content: center;\n gap: 0.5rem;\n list-style: none;\n padding: 1rem 0 0 0;\n margin: 0;\n}\n\n.dropi-carousel-indicators li {\n cursor: pointer;\n}\n\n.dropi-carousel-indicators li button {\n width: 1rem;\n height: 1rem;\n border-radius: 50%;\n border: 1px solid var(--Gray-Gray-100, #eceef4);\n background: var(--Neutral-White, #fff);\n cursor: pointer;\n transition: all 0.2s;\n padding: 0;\n}\n\n.dropi-carousel-indicators li.active button {\n background: var(--Primary-Primary-500);\n border-color: var(--Primary-Primary-500);\n}\n\n.dropi-carousel-indicators li:hover button {\n background: var(--Gray-Gray-200);\n}\n\n/* Vertical Orientation */\n.vertical .dropi-carousel-content {\n flex-direction: column;\n}\n\n.vertical .dropi-carousel-items-container {\n flex-direction: column;\n}\n\n.vertical .dropi-carousel-prev {\n margin: 0 0 1rem 0;\n}\n\n.vertical .dropi-carousel-next {\n margin: 1rem 0 0 0;\n}\n\n/* Responsive fixes */\n@media (max-width: 768px) {\n .dropi-carousel-container {\n padding: 0;\n }\n .dropi-carousel-item {\n padding: 0 0.25rem;\n }\n}\n","import { Component, Prop, State, Event, EventEmitter, Watch, h, Element } from '@stencil/core';\n\n@Component({\n tag: 'dropi-carousel',\n styleUrl: 'dropi-carousel.css',\n shadow: true,\n})\nexport class DropiCarousel {\n @Element() el: HTMLElement;\n\n /** Items to display (Array of URLs or objects) */\n @Prop() value: any[] | string = [];\n /** Active page index */\n @Prop({ mutable: true }) page: number = 0;\n /** Number of items visible per page */\n @Prop() numVisible: number = 1;\n /** Number of items to scroll per click */\n @Prop() numScroll: number = 1;\n /** Orientation of the carousel */\n @Prop() orientation: 'horizontal' | 'vertical' = 'horizontal';\n /** Show navigation arrows */\n @Prop() showNavigators: any = true;\n /** Show dot indicators */\n @Prop() showIndicators: any = true;\n /** Autoplay interval in ms (0 = disabled) */\n @Prop() autoplayInterval: number = 0;\n /** Infinite scrolling */\n @Prop() circular: any = false;\n\n @State() private parsedValue: any[] = [];\n @State() private internalPage: number = 0;\n @State() private isAnimating: boolean = false;\n @State() private totalPages: number = 0;\n\n private itemsContainer: HTMLElement;\n private timer: any;\n\n @Event() dropiPageChange: EventEmitter<number>;\n @Event() dropiPage: EventEmitter<any>;\n\n @Watch('value')\n handleValue(val: any[] | string) {\n this.parsedValue = typeof val === 'string' ? JSON.parse(val) : (val || []);\n this.updateTotalPages();\n this.updateTransform();\n }\n\n @Watch('page')\n handlePage(val: number) {\n this.internalPage = val;\n this.updateTransform();\n }\n\n componentWillLoad() {\n if (!this.value || (Array.isArray(this.value) && this.value.length === 0)) {\n const attrValue = this.el.getAttribute('value');\n if (attrValue) this.value = attrValue;\n }\n this.handleValue(this.value);\n this.internalPage = this.page;\n }\n\n componentDidLoad() {\n this.updateTransform();\n if (this.autoplayInterval > 0) {\n this.startAutoplay();\n }\n window.addEventListener('resize', this.onResize);\n }\n\n disconnectedCallback() {\n this.stopAutoplay();\n window.removeEventListener('resize', this.onResize);\n }\n\n private onResize = () => {\n this.updateTotalPages();\n this.updateTransform();\n };\n\n private startAutoplay() {\n this.timer = setInterval(() => this.navForward(), this.autoplayInterval);\n }\n\n private stopAutoplay() {\n if (this.timer) clearInterval(this.timer);\n }\n\n private updateTotalPages() {\n if (!this.parsedValue.length || this.parsedValue.length <= this.numVisible) {\n this.totalPages = 1;\n return;\n }\n const totalItems = this.parsedValue.length;\n const remainingItems = totalItems - this.numVisible;\n this.totalPages = Math.ceil(remainingItems / this.numScroll) + 1;\n }\n\n private updateTransform() {\n if (!this.itemsContainer) return;\n \n const prop = this.orientation === 'vertical' ? 'translateY' : 'translateX';\n const firstItem = this.itemsContainer.querySelector('.dropi-carousel-item') as HTMLElement;\n if (!firstItem) return;\n\n const itemSize = this.orientation === 'vertical' ? firstItem.offsetHeight : firstItem.offsetWidth;\n const itemsScrolled = this.internalPage * this.numScroll;\n const maxScroll = Math.max(0, this.parsedValue.length - this.numVisible);\n const safeScroll = Math.min(itemsScrolled, maxScroll);\n \n const translateValue = -(safeScroll * itemSize);\n this.itemsContainer.style.transform = `${prop}(${translateValue}px)`;\n }\n\n private navForward = (e?: Event) => {\n if (e) e.preventDefault();\n if (this.circular || this.internalPage < this.totalPages - 1) {\n this.isAnimating = true;\n this.internalPage = (this.internalPage + 1) % this.totalPages;\n this.page = this.internalPage;\n this.updateTransform();\n this.dropiPageChange.emit(this.internalPage);\n setTimeout(() => (this.isAnimating = false), 500);\n }\n };\n\n private navBackward = (e?: Event) => {\n if (e) e.preventDefault();\n if (this.circular || this.internalPage > 0) {\n this.isAnimating = true;\n this.internalPage = (this.internalPage - 1 + this.totalPages) % this.totalPages;\n this.page = this.internalPage;\n this.updateTransform();\n this.dropiPageChange.emit(this.internalPage);\n setTimeout(() => (this.isAnimating = false), 500);\n }\n };\n\n private onDotClick(index: number) {\n this.isAnimating = true;\n this.internalPage = index;\n this.page = this.internalPage;\n this.updateTransform();\n this.dropiPageChange.emit(this.internalPage);\n setTimeout(() => (this.isAnimating = false), 500);\n }\n\n render() {\n const items = this.parsedValue;\n if (!items.length) return null;\n\n const itemFlexBasis = `${100 / this.numVisible}%`;\n\n return (\n <div class={{ 'dropi-carousel-container': true, 'vertical': this.orientation === 'vertical' }}>\n <div class=\"dropi-carousel-content\">\n {this.showNavigators && items.length > this.numVisible && (\n <button\n class=\"dropi-carousel-nav dropi-carousel-prev\"\n disabled={!this.circular && this.internalPage === 0}\n onClick={(e) => this.navBackward(e)}\n aria-label=\"Anterior\"\n >\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\">\n <path d=\"M14.659 17.5a.833.833 0 0 1-.589-.244l-4.43-4.431a.833.833 0 0 1 0-1.178l4.43-4.431a.834.834 0 0 1 1.179 1.178L11.42 12.25l3.83 3.829a.833.833 0 0 1-.59 1.421Z\" fill=\"#475066\" />\n </svg>\n </button>\n )}\n\n <div class=\"dropi-carousel-items-content\">\n <div\n class=\"dropi-carousel-items-container\"\n ref={(el) => (this.itemsContainer = el)}\n style={{ transition: this.isAnimating ? 'transform 0.5s ease' : 'none' }}\n >\n {items.map((item, i) => (\n <div class=\"dropi-carousel-item\" style={{ flex: `0 0 ${itemFlexBasis}` }}>\n {typeof item === 'string' ? (\n <img src={item} alt={`Slide ${i + 1}`} />\n ) : (\n <slot name={`item-${i}`} />\n )}\n </div>\n ))}\n </div>\n </div>\n\n {this.showNavigators && items.length > this.numVisible && (\n <button\n class=\"dropi-carousel-nav dropi-carousel-next\"\n disabled={!this.circular && this.internalPage >= this.totalPages - 1}\n onClick={(e) => this.navForward(e)}\n aria-label=\"Siguiente\"\n >\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\">\n <path d=\"M9.341 17.5a.833.833 0 0 0 .589-.244l4.43-4.431a.833.833 0 0 0 0-1.178l-4.43-4.431a.834.834 0 0 0-1.179 1.178l3.83 3.829-3.83 3.829a.833.833 0 0 0 .59 1.421Z\" fill=\"#475066\" />\n </svg>\n </button>\n )}\n </div>\n\n {this.showIndicators && this.totalPages > 1 && (\n <ul class=\"dropi-carousel-indicators\">\n {Array.from({ length: this.totalPages }).map((_, i) => (\n <li class={{ active: i === this.internalPage }} onClick={() => this.onDotClick(i)}>\n <button type=\"button\" aria-label={`Página ${i + 1}`} />\n </li>\n ))}\n </ul>\n )}\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { r as registerInstance, d as createEvent, h } from './index-Cvp2LQOM.js';
|
|
2
|
+
|
|
3
|
+
const dropiCheckboxSelectionListCss = () => `:host{display:block;width:100%}*,*::before,*::after{box-sizing:border-box}.csl__search{display:flex;align-items:center;gap:var(--Size-2, 8px);padding:var(--Size-2, 8px) var(--Size-3, 12px);border:1px solid var(--Gray-Gray-200, #c3c9d9);border-radius:var(--Border-2, 8px);margin-bottom:var(--Size-2, 8px)}.csl__search-input{flex:1;border:none;outline:none;font-size:var(--font-size-s, 12px);font-family:inherit;color:var(--Gray-Gray-700, #32394d);background:transparent}.csl__clear{display:flex;background:none;border:none;padding:0;cursor:pointer}.csl__list{display:flex;flex-direction:column}.csl__item{display:flex;align-items:center;gap:var(--Size-2, 8px);padding:var(--Size-2, 8px) var(--Size-3, 12px);cursor:pointer;border-radius:var(--Border-1, 4px);transition:background 0.15s}.csl__item:hover{background:var(--Gray-Gray-50, #f7f8fa)}.csl__icon{width:24px;height:24px;border-radius:50%;object-fit:cover;flex-shrink:0}.csl__label{font-size:var(--font-size-s, 12px);color:var(--Gray-Gray-700, #32394d);flex:1}.csl__empty{padding:var(--Size-4, 16px);text-align:center;font-size:var(--font-size-s, 12px);color:var(--Gray-Gray-400, #858ea6)}`;
|
|
4
|
+
|
|
5
|
+
const DropiCheckboxSelectionList = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.dropiCheckedValues = createEvent(this, "dropiCheckedValues", 7);
|
|
9
|
+
this.dropiSearch = createEvent(this, "dropiSearch", 7);
|
|
10
|
+
}
|
|
11
|
+
/** Options array or JSON string */
|
|
12
|
+
options = [];
|
|
13
|
+
/** Show search filter */
|
|
14
|
+
showFilter = true;
|
|
15
|
+
/** Search placeholder */
|
|
16
|
+
filterPlaceholder = 'Search';
|
|
17
|
+
/** Show "no results" message */
|
|
18
|
+
showNotFound = true;
|
|
19
|
+
/** Empty state message */
|
|
20
|
+
notFoundMessage = 'No related results found';
|
|
21
|
+
/** Allow multiple selection */
|
|
22
|
+
multiSelect = true;
|
|
23
|
+
/** Debounce delay in ms for search input (matches Angular `searchDelay`) */
|
|
24
|
+
searchDelay = 100;
|
|
25
|
+
filterText = '';
|
|
26
|
+
selected = [];
|
|
27
|
+
parsedOptions = [];
|
|
28
|
+
/** Emitted when selection changes — matches Angular 'checkedValues' */
|
|
29
|
+
dropiCheckedValues;
|
|
30
|
+
/** Emitted on search — matches Angular 'onSearch' */
|
|
31
|
+
dropiSearch;
|
|
32
|
+
optionsChanged(val) {
|
|
33
|
+
this.parsedOptions = typeof val === 'string' ? JSON.parse(val) : (val || []);
|
|
34
|
+
}
|
|
35
|
+
componentWillLoad() { this.optionsChanged(this.options); }
|
|
36
|
+
get filtered() {
|
|
37
|
+
if (!this.filterText)
|
|
38
|
+
return this.parsedOptions;
|
|
39
|
+
const q = this.filterText.toLowerCase();
|
|
40
|
+
return this.parsedOptions.filter(o => o.label?.toLowerCase().includes(q));
|
|
41
|
+
}
|
|
42
|
+
toggle(id) {
|
|
43
|
+
if (this.multiSelect) {
|
|
44
|
+
this.selected = this.selected.includes(id)
|
|
45
|
+
? this.selected.filter(s => s !== id)
|
|
46
|
+
: [...this.selected, id];
|
|
47
|
+
}
|
|
48
|
+
else {
|
|
49
|
+
this.selected = this.selected.includes(id) ? [] : [id];
|
|
50
|
+
}
|
|
51
|
+
this.dropiCheckedValues.emit(this.selected);
|
|
52
|
+
}
|
|
53
|
+
render() {
|
|
54
|
+
const items = this.filtered;
|
|
55
|
+
return (h("div", { key: '95774833547807d6001525158bf199883661b649', class: "csl" }, this.showFilter && (h("div", { key: '13f6bfd33150cdf138e90b93fc8121dfcc311050', class: "csl__search" }, h("dropi-icon", { key: '4edf5c21eeac0aa442e58845621b7715d8484c1b', name: "Search", iconWidth: "16px", iconHeight: "16px", color: "Gray-Gray-400" }), h("input", { key: '40071d0c189c7fd1f1bf8090ebe1d64ce9605602', class: "csl__search-input", type: "text", placeholder: this.filterPlaceholder, value: this.filterText, onInput: (e) => {
|
|
56
|
+
this.filterText = e.target.value;
|
|
57
|
+
this.dropiSearch.emit(this.filterText);
|
|
58
|
+
} }), this.filterText && (h("button", { key: 'a560cab7ce53e57e036696194054286aa1dd6fd9', class: "csl__clear", onClick: () => { this.filterText = ''; this.dropiSearch.emit(''); } }, h("dropi-icon", { key: 'f1ae7e38fcb954761edb02bb32af139fb5eea610', name: "Close-small", iconWidth: "14px", iconHeight: "14px", color: "Gray-Gray-400" }))))), h("div", { key: 'e93dfccc8215e96640ebe8c69f33f0bff5f655f2', class: "csl__list" }, items.length === 0 && this.showNotFound ? (h("div", { class: "csl__empty" }, this.notFoundMessage)) : (items.map(opt => {
|
|
59
|
+
const checked = this.selected.includes(opt.id);
|
|
60
|
+
return (h("div", { class: "csl__item", key: opt.id, onClick: () => this.toggle(opt.id) }, h("dropi-checkbox", { checked: checked }), opt.icon && h("img", { class: "csl__icon", src: opt.icon, alt: opt.label }), h("span", { class: "csl__label" }, opt.label)));
|
|
61
|
+
})))));
|
|
62
|
+
}
|
|
63
|
+
static get watchers() { return {
|
|
64
|
+
"options": [{
|
|
65
|
+
"optionsChanged": 0
|
|
66
|
+
}]
|
|
67
|
+
}; }
|
|
68
|
+
};
|
|
69
|
+
DropiCheckboxSelectionList.style = dropiCheckboxSelectionListCss();
|
|
70
|
+
|
|
71
|
+
export { DropiCheckboxSelectionList as dropi_checkbox_selection_list };
|
|
72
|
+
//# sourceMappingURL=dropi-checkbox-selection-list.entry.esm.js.map
|
|
73
|
+
|
|
74
|
+
//# sourceMappingURL=dropi-checkbox-selection-list.entry.js.map
|
|
@@ -0,0 +1 @@
|
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AC,WAAW,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,EAAE,EAAA,EAC5F,CAAA,CAAA,YAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAY,IAAI,EAAC,aAAa,EAAC,SAAS,EAAC,MAAM,EAAC,UAAU,EAAC,MAAM,EAAC,KAAK,EAAC,eAAe,GAAG,CACnF,CACV,CACG,CACP,EAED,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAC,WAAW,EAAA,EACnB,KAAK,CAAC,MAAM,KAAK,CAAC,IAAI,IAAI,CAAC,YAAY,IACtC,CAAA,CAAA,KAAA,EAAA,EAAK,KAAK,EAAC,YAAY,EAAA,EAAE,IAAI,CAAC,eAAe,CAAO,KAEpD,KAAK,CAAC,GAAG,CAAC,GAAG,IAAG;AACd,YAAA,MAAM,OAAO,GAAG,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;AAC9C,YAAA,QACE,CAAA,CAAA,KAAA,EAAA,EAAK,KAAK,EAAC,WAAW,EAAC,GAAG,EAAE,GAAG,CAAC,EAAE,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,EAAA,EACpE,CAAA,CAAA,gBAAA,EAAA,EAAgB,OAAO,EAAE,OAAO,EAAA,CAAI,EACnC,GAAG,CAAC,IAAI,IAAI,WAAK,KAAK,EAAC,WAAW,EAAC,GAAG,EAAE,GAAG,CAAC,IAAI,EAAE,GAAG,EAAE,GAAG,CAAC,KAAK,EAAA,CAAI,EACrE,CAAA,CAAA,MAAA,EAAA,EAAM,KAAK,EAAC,YAAY,EAAA,EAAE,GAAG,CAAC,KAAK,CAAQ,CACvC;AAEV,SAAC,CAAC,CACH,CACG,CACF;;;;;;;;;;;;","names":[],"sources":["src/components/dropi-checkbox-selection-list/dropi-checkbox-selection-list.css?tag=dropi-checkbox-selection-list&encapsulation=shadow","src/components/dropi-checkbox-selection-list/dropi-checkbox-selection-list.tsx"],"sourcesContent":[":host { display: block; width: 100%; }\n*, *::before, *::after { box-sizing: border-box; }\n\n.csl__search {\n display: flex;\n align-items: center;\n gap: var(--Size-2, 8px);\n padding: var(--Size-2, 8px) var(--Size-3, 12px);\n border: 1px solid var(--Gray-Gray-200, #c3c9d9);\n border-radius: var(--Border-2, 8px);\n margin-bottom: var(--Size-2, 8px);\n}\n\n.csl__search-input {\n flex: 1; border: none; outline: none;\n font-size: var(--font-size-s, 12px); font-family: inherit;\n color: var(--Gray-Gray-700, #32394d); background: transparent;\n}\n\n.csl__clear { display: flex; background: none; border: none; padding: 0; cursor: pointer; }\n\n.csl__list { display: flex; flex-direction: column; }\n\n.csl__item {\n display: flex;\n align-items: center;\n gap: var(--Size-2, 8px);\n padding: var(--Size-2, 8px) var(--Size-3, 12px);\n cursor: pointer;\n border-radius: var(--Border-1, 4px);\n transition: background 0.15s;\n}\n.csl__item:hover { background: var(--Gray-Gray-50, #f7f8fa); }\n\n.csl__icon { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }\n\n.csl__label { font-size: var(--font-size-s, 12px); color: var(--Gray-Gray-700, #32394d); flex: 1; }\n\n.csl__empty {\n padding: var(--Size-4, 16px);\n text-align: center;\n font-size: var(--font-size-s, 12px);\n color: var(--Gray-Gray-400, #858ea6);\n}\n","import { Component, Prop, State, Event, EventEmitter, Watch, h } from '@stencil/core';\n\nexport interface CheckboxOption {\n id: string | number;\n label: string;\n icon?: string;\n [key: string]: any;\n}\n\n/**\n * @component dropi-checkbox-selection-list\n * Searchable list of checkbox options with multi-select support.\n */\n@Component({\n tag: 'dropi-checkbox-selection-list',\n styleUrl: 'dropi-checkbox-selection-list.css',\n shadow: true,\n})\nexport class DropiCheckboxSelectionList {\n /** Options array or JSON string */\n @Prop() options: CheckboxOption[] | string = [];\n /** Show search filter */\n @Prop() showFilter: boolean = true;\n /** Search placeholder */\n @Prop() filterPlaceholder: string = 'Search';\n /** Show \"no results\" message */\n @Prop() showNotFound: boolean = true;\n /** Empty state message */\n @Prop() notFoundMessage: string = 'No related results found';\n /** Allow multiple selection */\n @Prop() multiSelect: boolean = true;\n /** Debounce delay in ms for search input (matches Angular `searchDelay`) */\n @Prop() searchDelay: number = 100;\n\n @State() private filterText: string = '';\n @State() private selected: (string | number)[] = [];\n @State() private parsedOptions: CheckboxOption[] = [];\n\n /** Emitted when selection changes — matches Angular 'checkedValues' */\n @Event() dropiCheckedValues: EventEmitter<(string | number)[]>;\n /** Emitted on search — matches Angular 'onSearch' */\n @Event() dropiSearch: EventEmitter<string>;\n\n @Watch('options')\n optionsChanged(val: CheckboxOption[] | string) {\n this.parsedOptions = typeof val === 'string' ? JSON.parse(val) : (val || []);\n }\n\n componentWillLoad() { this.optionsChanged(this.options); }\n\n private get filtered(): CheckboxOption[] {\n if (!this.filterText) return this.parsedOptions;\n const q = this.filterText.toLowerCase();\n return this.parsedOptions.filter(o => o.label?.toLowerCase().includes(q));\n }\n\n private toggle(id: string | number) {\n if (this.multiSelect) {\n this.selected = this.selected.includes(id)\n ? this.selected.filter(s => s !== id)\n : [...this.selected, id];\n } else {\n this.selected = this.selected.includes(id) ? [] : [id];\n }\n this.dropiCheckedValues.emit(this.selected);\n }\n\n render() {\n const items = this.filtered;\n\n return (\n <div class=\"csl\">\n {this.showFilter && (\n <div class=\"csl__search\">\n <dropi-icon name=\"Search\" iconWidth=\"16px\" iconHeight=\"16px\" color=\"Gray-Gray-400\" />\n <input\n class=\"csl__search-input\"\n type=\"text\"\n placeholder={this.filterPlaceholder}\n value={this.filterText}\n onInput={(e) => {\n this.filterText = (e.target as HTMLInputElement).value;\n this.dropiSearch.emit(this.filterText);\n }}\n />\n {this.filterText && (\n <button class=\"csl__clear\" onClick={() => { this.filterText = ''; this.dropiSearch.emit(''); }}>\n <dropi-icon name=\"Close-small\" iconWidth=\"14px\" iconHeight=\"14px\" color=\"Gray-Gray-400\" />\n </button>\n )}\n </div>\n )}\n\n <div class=\"csl__list\">\n {items.length === 0 && this.showNotFound ? (\n <div class=\"csl__empty\">{this.notFoundMessage}</div>\n ) : (\n items.map(opt => {\n const checked = this.selected.includes(opt.id);\n return (\n <div class=\"csl__item\" key={opt.id} onClick={() => this.toggle(opt.id)}>\n <dropi-checkbox checked={checked} />\n {opt.icon && <img class=\"csl__icon\" src={opt.icon} alt={opt.label} />}\n <span class=\"csl__label\">{opt.label}</span>\n </div>\n );\n })\n )}\n </div>\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { r as registerInstance, d as createEvent, h } from './index-Cvp2LQOM.js';
|
|
2
|
+
|
|
3
|
+
const dropiCheckboxCss = () => `:host{display:inline-block}*,*::before,*::after{box-sizing:border-box}.container-dropi-checkbox{display:inline-block}.check{width:20px;height:20px;border-radius:var(--Border-1, 4px);cursor:pointer;transition:background-color 0.3s ease-in-out, border-style 0.3s ease-in-out}.noCheck{border-style:solid;border-width:2px;border-color:var(--Gray-Gray-200, #c3c9d9);display:flex;justify-content:center;align-items:center}.noCheck svg{visibility:hidden}.isCheck{display:flex;background-color:var(--Primary-Primary-500, #f49a3d);justify-content:center;align-items:center}.disabled{background-color:var(--Gray-Gray-50, #f7f8fa);border-color:var(--Gray-Gray-100, #e6eaf2);cursor:not-allowed}`;
|
|
4
|
+
|
|
5
|
+
const DropiCheckbox = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.dropiChange = createEvent(this, "dropiChange", 7);
|
|
9
|
+
}
|
|
10
|
+
/** Whether the checkbox is checked */
|
|
11
|
+
checked = false;
|
|
12
|
+
/** Whether the checkbox is disabled */
|
|
13
|
+
disabled = false;
|
|
14
|
+
/** Emitted when the checked state changes */
|
|
15
|
+
dropiChange;
|
|
16
|
+
changeState() {
|
|
17
|
+
if (this.disabled)
|
|
18
|
+
return;
|
|
19
|
+
this.checked = !this.checked;
|
|
20
|
+
this.dropiChange.emit(this.checked);
|
|
21
|
+
}
|
|
22
|
+
render() {
|
|
23
|
+
return (h("div", { key: '071505574decbf6b138256f73affe101c01080ef', class: "container-dropi-checkbox", onClick: () => this.changeState() }, h("div", { key: '03e7ec24a87e22c4a5fe1d94cc4ca1fe349d6e6f', class: {
|
|
24
|
+
check: true,
|
|
25
|
+
isCheck: this.checked,
|
|
26
|
+
noCheck: !this.checked,
|
|
27
|
+
disabled: this.disabled,
|
|
28
|
+
} }, h("svg", { key: 'c56f01268919995cc7aac0173edf44a01a62e13e', xmlns: "http://www.w3.org/2000/svg", width: "12", height: "12", viewBox: "0 0 24 24", fill: "none" }, h("path", { key: '575f863c9e82e862ea7049bf633b0d86ba374bb2', d: "M20.5991 5.69251L9.08325 17.2075C9.00583 17.2852 8.91382 17.3469 8.8125 17.389C8.71118 17.4311 8.60255 17.4527 8.49283 17.4527C8.38312 17.4527 8.27449 17.4311 8.17317 17.389C8.07185 17.3469 7.97984 17.2852 7.90242 17.2075L3.44908 12.75C3.37166 12.6723 3.27965 12.6106 3.17833 12.5685C3.07701 12.5264 2.96838 12.5048 2.85867 12.5048C2.74896 12.5048 2.64032 12.5264 2.53901 12.5685C2.43769 12.6106 2.34568 12.6723 2.26825 12.75C2.19052 12.8274 2.12884 12.9194 2.08676 13.0208C2.04467 13.1221 2.02301 13.2307 2.02301 13.3404C2.02301 13.4501 2.04467 13.5588 2.08676 13.6601C2.12884 13.7614 2.19052 13.8534 2.26825 13.9308L6.72325 18.385C7.19321 18.8541 7.83008 19.1175 8.49408 19.1175C9.15809 19.1175 9.79496 18.8541 10.2649 18.385L21.7799 6.87251C21.8575 6.7951 21.9191 6.70314 21.9611 6.6019C22.0031 6.50065 22.0247 6.39212 22.0247 6.28251C22.0247 6.17289 22.0031 6.06436 21.9611 5.96312C21.9191 5.86188 21.8575 5.76992 21.7799 5.69251C21.7025 5.61478 21.6105 5.5531 21.5092 5.51101C21.4078 5.46893 21.2992 5.44727 21.1895 5.44727C21.0798 5.44727 20.9712 5.46893 20.8698 5.51101C20.7685 5.5531 20.6765 5.61478 20.5991 5.69251Z", fill: "#FFFFFF" })))));
|
|
29
|
+
}
|
|
30
|
+
static get formAssociated() { return true; }
|
|
31
|
+
};
|
|
32
|
+
DropiCheckbox.style = dropiCheckboxCss();
|
|
33
|
+
|
|
34
|
+
export { DropiCheckbox as dropi_checkbox };
|
|
35
|
+
//# sourceMappingURL=dropi-checkbox.entry.esm.js.map
|
|
36
|
+
|
|
37
|
+
//# sourceMappingURL=dropi-checkbox.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"dropi-checkbox.entry.js","mappings":";;AAAA,MAAM,gBAAgB,GAAG,MAAM,CAAC,8qBAA8qB,CAAC;;MCalsB,aAAa,GAAA,MAAA;;;;;;IAEgB,OAAO,GAAY,KAAK;;IAEvC,QAAQ,GAAY,KAAK;;AAGzC,IAAA,WAAW;IAEZ,WAAW,GAAA;QACjB,IAAI,IAAI,CAAC,QAAQ;YAAE;AACnB,QAAA,IAAI,CAAC,OAAO,GAAG,CAAC,IAAI,CAAC,OAAO;QAC5B,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC;;IAGrC,MAAM,GAAA;AACJ,QAAA,QACE,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAC,0BAA0B,EAAC,OAAO,EAAE,MAAM,IAAI,CAAC,WAAW,EAAE,EAAA,EACrE,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,KAAK,EAAE;AACL,gBAAA,KAAK,EAAE,IAAI;gBACX,OAAO,EAAE,IAAI,CAAC,OAAO;AACrB,gBAAA,OAAO,EAAE,CAAC,IAAI,CAAC,OAAO;gBACtB,QAAQ,EAAE,IAAI,CAAC,QAAQ;aACxB,EAAA,EAED,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAC,4BAA4B,EAAC,KAAK,EAAC,IAAI,EAAC,MAAM,EAAC,IAAI,EAAC,OAAO,EAAC,WAAW,EAAC,IAAI,EAAC,MAAM,EAAA,EAC5F,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,CAAC,EAAC,smCAAsmC,EACxmC,IAAI,EAAC,SAAS,EAAA,CACd,CACE,CACF,CACF;;;;;;;;","names":[],"sources":["src/components/dropi-checkbox/dropi-checkbox.css?tag=dropi-checkbox&encapsulation=shadow","src/components/dropi-checkbox/dropi-checkbox.tsx"],"sourcesContent":[":host {\n display: inline-block;\n}\n\n*, *::before, *::after {\n box-sizing: border-box;\n}\n\n.container-dropi-checkbox {\n display: inline-block;\n}\n\n.check {\n width: 20px;\n height: 20px;\n border-radius: var(--Border-1, 4px);\n cursor: pointer;\n transition:\n background-color 0.3s ease-in-out,\n border-style 0.3s ease-in-out;\n}\n\n.noCheck {\n border-style: solid;\n border-width: 2px;\n border-color: var(--Gray-Gray-200, #c3c9d9);\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.noCheck svg {\n visibility: hidden;\n}\n\n.isCheck {\n display: flex;\n background-color: var(--Primary-Primary-500, #f49a3d);\n justify-content: center;\n align-items: center;\n}\n\n.disabled {\n background-color: var(--Gray-Gray-50, #f7f8fa);\n border-color: var(--Gray-Gray-100, #e6eaf2);\n cursor: not-allowed;\n}\n","import { Component, Prop, Event, EventEmitter, h } from '@stencil/core';\n\n/**\n * @component dropi-checkbox\n * A styled checkbox that emits change events.\n * Supports form association via native `<input type=\"checkbox\">` internals.\n */\n@Component({\n tag: 'dropi-checkbox',\n styleUrl: 'dropi-checkbox.css',\n shadow: true,\n formAssociated: true,\n})\nexport class DropiCheckbox {\n /** Whether the checkbox is checked */\n @Prop({ mutable: true, reflect: true }) checked: boolean = false;\n /** Whether the checkbox is disabled */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /** Emitted when the checked state changes */\n @Event() dropiChange: EventEmitter<boolean>;\n\n private changeState() {\n if (this.disabled) return;\n this.checked = !this.checked;\n this.dropiChange.emit(this.checked);\n }\n\n render() {\n return (\n <div class=\"container-dropi-checkbox\" onClick={() => this.changeState()}>\n <div\n class={{\n check: true,\n isCheck: this.checked,\n noCheck: !this.checked,\n disabled: this.disabled,\n }}\n >\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"12\" viewBox=\"0 0 24 24\" fill=\"none\">\n <path\n d=\"M20.5991 5.69251L9.08325 17.2075C9.00583 17.2852 8.91382 17.3469 8.8125 17.389C8.71118 17.4311 8.60255 17.4527 8.49283 17.4527C8.38312 17.4527 8.27449 17.4311 8.17317 17.389C8.07185 17.3469 7.97984 17.2852 7.90242 17.2075L3.44908 12.75C3.37166 12.6723 3.27965 12.6106 3.17833 12.5685C3.07701 12.5264 2.96838 12.5048 2.85867 12.5048C2.74896 12.5048 2.64032 12.5264 2.53901 12.5685C2.43769 12.6106 2.34568 12.6723 2.26825 12.75C2.19052 12.8274 2.12884 12.9194 2.08676 13.0208C2.04467 13.1221 2.02301 13.2307 2.02301 13.3404C2.02301 13.4501 2.04467 13.5588 2.08676 13.6601C2.12884 13.7614 2.19052 13.8534 2.26825 13.9308L6.72325 18.385C7.19321 18.8541 7.83008 19.1175 8.49408 19.1175C9.15809 19.1175 9.79496 18.8541 10.2649 18.385L21.7799 6.87251C21.8575 6.7951 21.9191 6.70314 21.9611 6.6019C22.0031 6.50065 22.0247 6.39212 22.0247 6.28251C22.0247 6.17289 22.0031 6.06436 21.9611 5.96312C21.9191 5.86188 21.8575 5.76992 21.7799 5.69251C21.7025 5.61478 21.6105 5.5531 21.5092 5.51101C21.4078 5.46893 21.2992 5.44727 21.1895 5.44727C21.0798 5.44727 20.9712 5.46893 20.8698 5.51101C20.7685 5.5531 20.6765 5.61478 20.5991 5.69251Z\"\n fill=\"#FFFFFF\"\n />\n </svg>\n </div>\n </div>\n );\n }\n}\n"],"version":3}
|