@salla.sa/twilight-components 2.14.444 → 2.14.446
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{filepond-plugin-file-poster-CmQuPQcY.js → filepond-plugin-file-poster-DXUkwq91.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-validate-size-sGTAJHie.js → filepond-plugin-file-validate-size-CmWT-l1o.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-validate-type-DhXaHZZZ.js → filepond-plugin-file-validate-type-CI-SRLe5.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-edit-Cj8JCfAN.js → filepond-plugin-image-edit-D0ccVwFm.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-exif-orientation-32JSai7q.js → filepond-plugin-image-exif-orientation-CC7CmDIV.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-preview-BKmavM3U.js → filepond-plugin-image-preview-DOMTJIsr.js} +1 -1
- package/dist/cjs/{filepond-Bbj7PmYR.js → filepond-rDr-05NK.js} +1 -1
- package/dist/cjs/{functions-lGTNolKl.js → functions-BrD7nRK2.js} +1 -1
- package/dist/cjs/{index-BSEEzSJv.js → index-BBFmWakU.js} +1 -1
- package/dist/cjs/{index-BjjfvdmF.js → index-DA8jhZqT.js} +2 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/salla-accordion-body_2.cjs.entry.js +1 -1
- package/dist/cjs/salla-accordion_6.cjs.entry.js +1 -1
- package/dist/cjs/salla-add-product-button_5.cjs.entry.js +2 -2
- package/dist/cjs/salla-advertisement.cjs.entry.js +1 -1
- package/dist/cjs/salla-alert_2.cjs.entry.js +1 -1
- package/dist/cjs/salla-app-install-alert.cjs.entry.js +1 -1
- package/dist/cjs/salla-apps-icons.cjs.entry.js +1 -1
- package/dist/cjs/salla-badge.cjs.entry.js +1 -1
- package/dist/cjs/salla-booking-field_7.cjs.entry.js +10 -10
- package/dist/cjs/salla-bullet-delivery_2.cjs.entry.js +58 -42
- package/dist/cjs/salla-cart-coupons.cjs.entry.js +1 -1
- package/dist/cjs/salla-cart-item-offers_2.cjs.entry.js +1 -1
- package/dist/cjs/salla-cashback-banner.cjs.entry.js +1 -1
- package/dist/cjs/salla-comment-form_8.cjs.entry.js +1 -1
- package/dist/cjs/salla-conditional-offer.cjs.entry.js +1 -1
- package/dist/cjs/salla-contacts.cjs.entry.js +1 -1
- package/dist/cjs/salla-cookies-bar.cjs.entry.js +1 -1
- package/dist/cjs/salla-count-down.cjs.entry.js +1 -1
- package/dist/cjs/salla-custom-fields.cjs.entry.js +1 -1
- package/dist/cjs/salla-delivery-promise.cjs.entry.js +1 -1
- package/dist/cjs/salla-edit-order-button.cjs.entry.js +1 -1
- package/dist/cjs/salla-filters-widget.cjs.entry.js +1 -1
- package/dist/cjs/salla-filters.cjs.entry.js +1 -1
- package/dist/cjs/salla-fulfillment-methods.cjs.entry.js +1 -1
- package/dist/cjs/salla-gifting.cjs.entry.js +144 -38
- package/dist/cjs/salla-hook.cjs.entry.js +1 -1
- package/dist/cjs/salla-infinite-scroll.cjs.entry.js +1 -1
- package/dist/cjs/salla-installment.cjs.entry.js +1 -1
- package/dist/cjs/salla-list-tile.cjs.entry.js +1 -1
- package/dist/cjs/salla-localization-modal.cjs.entry.js +1 -1
- package/dist/cjs/salla-login-modal.cjs.entry.js +1 -1
- package/dist/cjs/salla-loyalty-banner.cjs.entry.js +2 -2
- package/dist/cjs/salla-loyalty-hero_2.cjs.entry.js +2 -2
- package/dist/cjs/salla-loyalty-panel.cjs.entry.js +3 -3
- package/dist/cjs/salla-loyalty-points-banner.cjs.entry.js +1 -1
- package/dist/cjs/salla-loyalty-prize-item.cjs.entry.js +1 -1
- package/dist/cjs/salla-loyalty-program.cjs.entry.js +3 -3
- package/dist/cjs/salla-loyalty-reward.cjs.entry.js +2 -2
- package/dist/cjs/salla-loyalty.cjs.entry.js +1 -1
- package/dist/cjs/salla-maintenance-alert.cjs.entry.js +1 -1
- package/dist/cjs/salla-map.cjs.entry.js +1 -1
- package/dist/cjs/salla-menu.cjs.entry.js +1 -1
- package/dist/cjs/salla-metadata.cjs.entry.js +1 -1
- package/dist/cjs/salla-multiple-bundle-product-cart_2.cjs.entry.js +1 -1
- package/dist/cjs/salla-multiple-bundle-product-options-modal_2.cjs.entry.js +1 -1
- package/dist/cjs/salla-multiple-bundle-product.cjs.entry.js +1 -1
- package/dist/cjs/salla-next-order-coupon.cjs.entry.js +1 -1
- package/dist/cjs/salla-notification-item.cjs.entry.js +1 -1
- package/dist/cjs/salla-notifications.cjs.entry.js +1 -1
- package/dist/cjs/salla-offer-modal.cjs.entry.js +1 -1
- package/dist/cjs/salla-offer.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-details-multiple-bundle-product.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-details-options.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-details.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-edit-item.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-edit-product-card.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-edit.cjs.entry.js +15 -4
- package/dist/cjs/salla-order-summary.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-totals-card.cjs.entry.js +1 -1
- package/dist/cjs/salla-orders.cjs.entry.js +1 -1
- package/dist/cjs/salla-payments.cjs.entry.js +1 -1
- package/dist/cjs/salla-placeholder.cjs.entry.js +1 -1
- package/dist/cjs/salla-price-range.cjs.entry.js +1 -1
- package/dist/cjs/salla-product-card-embed.cjs.entry.js +1 -1
- package/dist/cjs/salla-product-card_2.cjs.entry.js +1 -1
- package/dist/cjs/salla-product-size-guide.cjs.entry.js +1 -1
- package/dist/cjs/salla-products-list.cjs.entry.js +1 -1
- package/dist/cjs/salla-progress-bar.cjs.entry.js +1 -1
- package/dist/cjs/salla-quick-order.cjs.entry.js +1 -1
- package/dist/cjs/salla-rating-modal.cjs.entry.js +1 -1
- package/dist/cjs/salla-reward-action_4.cjs.entry.js +3 -3
- package/dist/cjs/salla-scopes.cjs.entry.js +1 -1
- package/dist/cjs/salla-search.cjs.entry.js +1 -1
- package/dist/cjs/salla-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/salla-slider.cjs.entry.js +1 -1
- package/dist/cjs/salla-social-share.cjs.entry.js +1 -1
- package/dist/cjs/salla-social.cjs.entry.js +1 -1
- package/dist/cjs/salla-tab-content_3.cjs.entry.js +1 -1
- package/dist/cjs/salla-tiered-offer.cjs.entry.js +1 -1
- package/dist/cjs/salla-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/salla-trust-badges.cjs.entry.js +1 -1
- package/dist/cjs/salla-user-menu.cjs.entry.js +1 -1
- package/dist/cjs/salla-user-profile.cjs.entry.js +1 -1
- package/dist/cjs/salla-user-settings.cjs.entry.js +1 -1
- package/dist/cjs/salla-verify.cjs.entry.js +1 -1
- package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
- package/dist/cjs/{tracked-promise-BLOn0DiZ.js → tracked-promise-vD81wqoM.js} +1 -1
- package/dist/cjs/twilight.cjs.js +2 -2
- package/dist/cjs/{vanilla-picker-C5CI4VSj.js → vanilla-picker-Dc4-oPc4.js} +1 -1
- package/dist/collection/components/salla-bought-together/salla-bought-together.js +1 -1
- package/dist/collection/components/salla-gifting/salla-gifting.css +15 -0
- package/dist/collection/components/salla-gifting/salla-gifting.js +149 -36
- package/dist/collection/components/salla-order-edit/salla-order-edit.js +16 -4
- package/dist/collection/components/salla-searchable-dropdown/salla-searchable-dropdown.js +97 -41
- package/dist/components/index.js +2 -2
- package/dist/components/salla-bought-together.js +1 -1
- package/dist/components/salla-gifting.js +170 -51
- package/dist/components/salla-order-edit.js +16 -4
- package/dist/components/salla-searchable-dropdown2.js +59 -41
- package/dist/esm/{filepond-BFX6xxhJ.js → filepond-CpYF7JQY.js} +1 -1
- package/dist/esm/{filepond-plugin-file-poster-DwMxJsyL.js → filepond-plugin-file-poster-ob6i92P3.js} +1 -1
- package/dist/esm/{filepond-plugin-file-validate-size-BFwbB1wr.js → filepond-plugin-file-validate-size-h8AHfyQH.js} +1 -1
- package/dist/esm/{filepond-plugin-file-validate-type-9VetG0aO.js → filepond-plugin-file-validate-type-BPLx-hfr.js} +1 -1
- package/dist/esm/{filepond-plugin-image-edit-DqIgezI-.js → filepond-plugin-image-edit-B7wPe8-3.js} +1 -1
- package/dist/esm/{filepond-plugin-image-exif-orientation-B97i5tWf.js → filepond-plugin-image-exif-orientation-e7W60Y2D.js} +1 -1
- package/dist/esm/{filepond-plugin-image-preview-eGkx8PnH.js → filepond-plugin-image-preview-DOov9hTx.js} +1 -1
- package/dist/esm/{functions-C1QgrjTx.js → functions-BRfvCQ-R.js} +1 -1
- package/dist/esm/{index-CjquqEh1.js → index-DryPCgN9.js} +2 -2
- package/dist/esm/{index-BU_MkqNl.js → index-nKWbBz_d.js} +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/esm/salla-accordion-body_2.entry.js +1 -1
- package/dist/esm/salla-accordion_6.entry.js +1 -1
- package/dist/esm/salla-add-product-button_5.entry.js +2 -2
- package/dist/esm/salla-advertisement.entry.js +1 -1
- package/dist/esm/salla-alert_2.entry.js +1 -1
- package/dist/esm/salla-app-install-alert.entry.js +1 -1
- package/dist/esm/salla-apps-icons.entry.js +1 -1
- package/dist/esm/salla-badge.entry.js +1 -1
- package/dist/esm/salla-booking-field_7.entry.js +10 -10
- package/dist/esm/salla-bullet-delivery_2.entry.js +58 -42
- package/dist/esm/salla-cart-coupons.entry.js +1 -1
- package/dist/esm/salla-cart-item-offers_2.entry.js +1 -1
- package/dist/esm/salla-cashback-banner.entry.js +1 -1
- package/dist/esm/salla-comment-form_8.entry.js +1 -1
- package/dist/esm/salla-conditional-offer.entry.js +1 -1
- package/dist/esm/salla-contacts.entry.js +1 -1
- package/dist/esm/salla-cookies-bar.entry.js +1 -1
- package/dist/esm/salla-count-down.entry.js +1 -1
- package/dist/esm/salla-custom-fields.entry.js +1 -1
- package/dist/esm/salla-delivery-promise.entry.js +1 -1
- package/dist/esm/salla-edit-order-button.entry.js +1 -1
- package/dist/esm/salla-filters-widget.entry.js +1 -1
- package/dist/esm/salla-filters.entry.js +1 -1
- package/dist/esm/salla-fulfillment-methods.entry.js +1 -1
- package/dist/esm/salla-gifting.entry.js +144 -38
- package/dist/esm/salla-hook.entry.js +1 -1
- package/dist/esm/salla-infinite-scroll.entry.js +1 -1
- package/dist/esm/salla-installment.entry.js +1 -1
- package/dist/esm/salla-list-tile.entry.js +1 -1
- package/dist/esm/salla-localization-modal.entry.js +1 -1
- package/dist/esm/salla-login-modal.entry.js +1 -1
- package/dist/esm/salla-loyalty-banner.entry.js +2 -2
- package/dist/esm/salla-loyalty-hero_2.entry.js +2 -2
- package/dist/esm/salla-loyalty-panel.entry.js +3 -3
- package/dist/esm/salla-loyalty-points-banner.entry.js +1 -1
- package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
- package/dist/esm/salla-loyalty-program.entry.js +3 -3
- package/dist/esm/salla-loyalty-reward.entry.js +2 -2
- package/dist/esm/salla-loyalty.entry.js +1 -1
- package/dist/esm/salla-maintenance-alert.entry.js +1 -1
- package/dist/esm/salla-map.entry.js +1 -1
- package/dist/esm/salla-menu.entry.js +1 -1
- package/dist/esm/salla-metadata.entry.js +1 -1
- package/dist/esm/salla-multiple-bundle-product-cart_2.entry.js +1 -1
- package/dist/esm/salla-multiple-bundle-product-options-modal_2.entry.js +1 -1
- package/dist/esm/salla-multiple-bundle-product.entry.js +1 -1
- package/dist/esm/salla-next-order-coupon.entry.js +1 -1
- package/dist/esm/salla-notification-item.entry.js +1 -1
- package/dist/esm/salla-notifications.entry.js +1 -1
- package/dist/esm/salla-offer-modal.entry.js +1 -1
- package/dist/esm/salla-offer.entry.js +1 -1
- package/dist/esm/salla-order-details-multiple-bundle-product.entry.js +1 -1
- package/dist/esm/salla-order-details-options.entry.js +1 -1
- package/dist/esm/salla-order-details.entry.js +1 -1
- package/dist/esm/salla-order-edit-item.entry.js +1 -1
- package/dist/esm/salla-order-edit-product-card.entry.js +1 -1
- package/dist/esm/salla-order-edit.entry.js +15 -4
- package/dist/esm/salla-order-summary.entry.js +1 -1
- package/dist/esm/salla-order-totals-card.entry.js +1 -1
- package/dist/esm/salla-orders.entry.js +1 -1
- package/dist/esm/salla-payments.entry.js +1 -1
- package/dist/esm/salla-placeholder.entry.js +1 -1
- package/dist/esm/salla-price-range.entry.js +1 -1
- package/dist/esm/salla-product-card-embed.entry.js +1 -1
- package/dist/esm/salla-product-card_2.entry.js +1 -1
- package/dist/esm/salla-product-size-guide.entry.js +1 -1
- package/dist/esm/salla-products-list.entry.js +1 -1
- package/dist/esm/salla-progress-bar.entry.js +1 -1
- package/dist/esm/salla-quick-order.entry.js +1 -1
- package/dist/esm/salla-rating-modal.entry.js +1 -1
- package/dist/esm/salla-reward-action_4.entry.js +3 -3
- package/dist/esm/salla-scopes.entry.js +1 -1
- package/dist/esm/salla-search.entry.js +1 -1
- package/dist/esm/salla-skeleton.entry.js +1 -1
- package/dist/esm/salla-slider.entry.js +1 -1
- package/dist/esm/salla-social-share.entry.js +1 -1
- package/dist/esm/salla-social.entry.js +1 -1
- package/dist/esm/salla-tab-content_3.entry.js +1 -1
- package/dist/esm/salla-tiered-offer.entry.js +1 -1
- package/dist/esm/salla-tooltip.entry.js +1 -1
- package/dist/esm/salla-trust-badges.entry.js +1 -1
- package/dist/esm/salla-user-menu.entry.js +1 -1
- package/dist/esm/salla-user-profile.entry.js +1 -1
- package/dist/esm/salla-user-settings.entry.js +1 -1
- package/dist/esm/salla-verify.entry.js +1 -1
- package/dist/esm/salla-wallet.entry.js +1 -1
- package/dist/esm/{tracked-promise-CHodYJuF.js → tracked-promise-x7FFO6oF.js} +1 -1
- package/dist/esm/twilight.js +3 -3
- package/dist/esm/{vanilla-picker-Dz2cnaJm.js → vanilla-picker-WM2eU5Jq.js} +1 -1
- package/dist/twilight/{p-7e5bd688.entry.js → p-02281f9b.entry.js} +1 -1
- package/dist/twilight/{p-4532ccc9.entry.js → p-02be2d0d.entry.js} +1 -1
- package/dist/twilight/{p-4858fee7.entry.js → p-04bf282e.entry.js} +1 -1
- package/dist/twilight/{p-bdb97cd6.entry.js → p-06254080.entry.js} +1 -1
- package/dist/twilight/{p-86cdc4f0.entry.js → p-0fbc1adc.entry.js} +1 -1
- package/dist/twilight/{p-d876814e.entry.js → p-1a8ffb6a.entry.js} +1 -1
- package/dist/twilight/{p-ce3c2d87.entry.js → p-25b0ee17.entry.js} +1 -1
- package/dist/twilight/{p-44bcc6ef.entry.js → p-27954727.entry.js} +1 -1
- package/dist/twilight/{p-113e46ae.entry.js → p-306017cc.entry.js} +1 -1
- package/dist/twilight/{p-2ea272a5.entry.js → p-3158d2a9.entry.js} +1 -1
- package/dist/twilight/{p-da47b179.entry.js → p-362d1920.entry.js} +1 -1
- package/dist/twilight/{p-efca806c.entry.js → p-372ff04c.entry.js} +1 -1
- package/dist/twilight/{p-d65cd0ca.entry.js → p-38334780.entry.js} +1 -1
- package/dist/twilight/{p-1ce6baf8.entry.js → p-385277f9.entry.js} +1 -1
- package/dist/twilight/{p-0bc373c3.entry.js → p-38c40f88.entry.js} +1 -1
- package/dist/twilight/{p-30159ed2.entry.js → p-392bac91.entry.js} +1 -1
- package/dist/twilight/{p-9aa7503c.entry.js → p-39e59627.entry.js} +1 -1
- package/dist/twilight/{p-9dc45831.entry.js → p-3c8531fd.entry.js} +1 -1
- package/dist/twilight/{p-f6741e14.entry.js → p-3ea0a5bb.entry.js} +1 -1
- package/dist/twilight/{p-e88b5134.entry.js → p-4139872a.entry.js} +1 -1
- package/dist/twilight/{p-9c3ff0a1.entry.js → p-41b5d22c.entry.js} +1 -1
- package/dist/twilight/{p-556d563d.entry.js → p-426a869c.entry.js} +1 -1
- package/dist/twilight/{p-bca4bdc7.entry.js → p-43420d4d.entry.js} +1 -1
- package/dist/twilight/{p-c9403f34.entry.js → p-43e5cb00.entry.js} +1 -1
- package/dist/twilight/{p-0cc907b6.entry.js → p-46b2f44a.entry.js} +1 -1
- package/dist/twilight/{p-89f289b8.entry.js → p-47ac0d89.entry.js} +1 -1
- package/dist/twilight/{p-f933dbd9.entry.js → p-4b0747a1.entry.js} +1 -1
- package/dist/twilight/{p-928752cf.entry.js → p-4e8a8906.entry.js} +1 -1
- package/dist/twilight/{p-22ac20fb.entry.js → p-4eb51d3e.entry.js} +1 -1
- package/dist/twilight/{p-dec3e314.entry.js → p-56af742e.entry.js} +1 -1
- package/dist/twilight/{p-b07ea02e.entry.js → p-56f5aac9.entry.js} +1 -1
- package/dist/twilight/{p-89c54193.entry.js → p-57e63e76.entry.js} +1 -1
- package/dist/twilight/{p-386f7262.entry.js → p-5f08f47d.entry.js} +1 -1
- package/dist/twilight/{p-9a029ffb.entry.js → p-63dd5a3c.entry.js} +1 -1
- package/dist/twilight/{p-7a8e7d0f.entry.js → p-65421b04.entry.js} +1 -1
- package/dist/twilight/{p-a85d96e2.entry.js → p-66b9efc0.entry.js} +1 -1
- package/dist/twilight/{p-345fade3.entry.js → p-691abee2.entry.js} +1 -1
- package/dist/twilight/{p-b1555436.entry.js → p-6b2d84be.entry.js} +1 -1
- package/dist/twilight/{p-c02a27a5.entry.js → p-6c25d9f0.entry.js} +1 -1
- package/dist/twilight/{p-658af936.entry.js → p-6e33dad3.entry.js} +1 -1
- package/dist/twilight/{p-c65eb0ee.entry.js → p-70e5fcb0.entry.js} +1 -1
- package/dist/twilight/{p-d5c2fe58.entry.js → p-740ccc8e.entry.js} +1 -1
- package/dist/twilight/{p-9586467e.entry.js → p-7447b19b.entry.js} +1 -1
- package/dist/twilight/p-752c4d55.entry.js +4 -0
- package/dist/twilight/{p-f141b189.entry.js → p-7b91245f.entry.js} +1 -1
- package/dist/twilight/{p-b86e2768.entry.js → p-85911960.entry.js} +1 -1
- package/dist/twilight/{p-87eaf990.entry.js → p-86e3a8fc.entry.js} +1 -1
- package/dist/twilight/{p-4fbe9195.entry.js → p-891d0baa.entry.js} +1 -1
- package/dist/twilight/{p-a3b2c406.entry.js → p-96ce2dbc.entry.js} +1 -1
- package/dist/twilight/{p-lbla8oyU.js → p-B09zahHa.js} +1 -1
- package/dist/twilight/{p-OpqsYFJ7.js → p-CW4u-F7Z.js} +1 -1
- package/dist/twilight/{p-BAeNPoQd.js → p-Cqvb5bEk.js} +1 -1
- package/dist/twilight/{p-CZmvt3JS.js → p-D0NjtBeS.js} +1 -1
- package/dist/twilight/{p-CiZS53-6.js → p-DfQlAXmu.js} +1 -1
- package/dist/twilight/{p-XxMmLD82.js → p-DkfNyQIQ.js} +1 -1
- package/dist/twilight/{p-DizhqBLB.js → p-DnhZebll.js} +1 -1
- package/dist/twilight/{p-CjquqEh1.js → p-DryPCgN9.js} +1 -1
- package/dist/twilight/{p-vtSaduZY.js → p-Dv6JHEwK.js} +1 -1
- package/dist/twilight/{p-CHlhCr-2.js → p-W3jneIaI.js} +1 -1
- package/dist/twilight/{p-4z9238xc.js → p-_2O7LkzU.js} +1 -1
- package/dist/twilight/{p-46aecc23.entry.js → p-a09118de.entry.js} +1 -1
- package/dist/twilight/{p-28503efc.entry.js → p-a35822f5.entry.js} +1 -1
- package/dist/twilight/{p-2aa656f0.entry.js → p-acef8c7b.entry.js} +1 -1
- package/dist/twilight/{p-549792e6.entry.js → p-b51a70cc.entry.js} +1 -1
- package/dist/twilight/{p-4da7a36e.entry.js → p-b607e474.entry.js} +1 -1
- package/dist/twilight/{p-d6b42548.entry.js → p-be360c44.entry.js} +1 -1
- package/dist/twilight/p-c1b9517f.entry.js +4 -0
- package/dist/twilight/{p-dff8a0d3.entry.js → p-c22a3b11.entry.js} +1 -1
- package/dist/twilight/p-c312d0db.entry.js +4 -0
- package/dist/twilight/{p-48f717e0.entry.js → p-c81c589b.entry.js} +1 -1
- package/dist/twilight/{p-cafc416d.entry.js → p-cc65c26b.entry.js} +1 -1
- package/dist/twilight/{p-6e230a2b.entry.js → p-cfa852cf.entry.js} +1 -1
- package/dist/twilight/{p-22c4ec76.entry.js → p-d520bdb9.entry.js} +1 -1
- package/dist/twilight/{p-7b2f6272.entry.js → p-d6ceeb02.entry.js} +1 -1
- package/dist/twilight/{p-96be7ad7.entry.js → p-d72ac224.entry.js} +1 -1
- package/dist/twilight/{p-041739c7.entry.js → p-d9adeaf2.entry.js} +1 -1
- package/dist/twilight/{p-51e355f4.entry.js → p-da8058f3.entry.js} +1 -1
- package/dist/twilight/{p-b8a680fa.entry.js → p-db288463.entry.js} +1 -1
- package/dist/twilight/{p-ea7e46e8.entry.js → p-dc0d3911.entry.js} +1 -1
- package/dist/twilight/{p-3376ea68.entry.js → p-e00cbb9e.entry.js} +1 -1
- package/dist/twilight/{p-2d771a56.entry.js → p-e114505e.entry.js} +1 -1
- package/dist/twilight/{p-d6d1a44f.entry.js → p-e1176fed.entry.js} +1 -1
- package/dist/twilight/{p-61ae022e.entry.js → p-e20e9fcc.entry.js} +1 -1
- package/dist/twilight/{p-656f5c9f.entry.js → p-e290b5c5.entry.js} +1 -1
- package/dist/twilight/{p-736037bf.entry.js → p-e450e794.entry.js} +1 -1
- package/dist/twilight/{p-c191d2fc.entry.js → p-e5cfb673.entry.js} +1 -1
- package/dist/twilight/{p-b8acec24.entry.js → p-e84c62f7.entry.js} +1 -1
- package/dist/twilight/{p-432b5dc2.entry.js → p-eb3ef9e4.entry.js} +1 -1
- package/dist/twilight/{p-d47b2e4a.entry.js → p-ec145c3d.entry.js} +1 -1
- package/dist/twilight/{p-40da7379.entry.js → p-f196f804.entry.js} +1 -1
- package/dist/twilight/p-f2563e2b.entry.js +4 -0
- package/dist/twilight/{p-271228e8.entry.js → p-f2f152fc.entry.js} +1 -1
- package/dist/twilight/{p-98404ee2.entry.js → p-f38b7948.entry.js} +1 -1
- package/dist/twilight/{p-0f268a17.entry.js → p-f6d9edd5.entry.js} +1 -1
- package/dist/twilight/{p-2c270887.entry.js → p-f7b7ea3d.entry.js} +1 -1
- package/dist/twilight/{p-12383fc2.entry.js → p-f974d986.entry.js} +1 -1
- package/dist/twilight/{p-4f7a053b.entry.js → p-ffe84d46.entry.js} +1 -1
- package/dist/twilight/{p-DcGM6DYo.js → p-k4lInm67.js} +1 -1
- package/dist/twilight/twilight.esm.js +1 -1
- package/dist/types/components/salla-gifting/salla-gifting.d.ts +23 -4
- package/dist/types/components/salla-order-edit/salla-order-edit.d.ts +4 -0
- package/dist/types/components/salla-searchable-dropdown/salla-searchable-dropdown.d.ts +8 -0
- package/dist/types/components.d.ts +18 -0
- package/package.json +5 -5
- package/dist/twilight/p-0aa1fc10.entry.js +0 -4
- package/dist/twilight/p-2a75ac14.entry.js +0 -4
- package/dist/twilight/p-644ab356.entry.js +0 -4
- package/dist/twilight/p-f5a99491.entry.js +0 -4
|
@@ -132,7 +132,7 @@ const SallaBoughtTogether$1 = /*@__PURE__*/ proxyCustomElement(class SallaBought
|
|
|
132
132
|
return (h(Host, { class: "s-bought-together-entry" }, h("div", { class: "s-bought-together-header" }, h("h3", { class: "s-bought-together-title" }, this.title), h("p", { class: "s-bought-together-subtitle" }, this.subtitle)), h("div", { class: "s-bought-together-list" }, this.recommendations.map((product) => (h("div", { key: product.id, class: `s-bought-together-item${!this.selectedIds.has(product.id) ? ' s-bought-together-item--unchecked' : ''}` }, h("label", { class: "s-bought-together-checkbox-label" }, h("input", { type: "checkbox", class: "s-bought-together-checkbox", checked: this.selectedIds.has(product.id), onChange: () => this.toggleProduct(product.id) }), h("span", { class: "s-bought-together-checkmark" })), h("a", { class: "s-bought-together-item-link", href: product.url }, h("img", { class: "s-bought-together-item-img", src: product.image?.url || salla.url.cdn('images/s-empty.png'), alt: product.image?.alt || product.name, loading: "lazy", decoding: "async", onError: e => {
|
|
133
133
|
e.currentTarget.onerror = null;
|
|
134
134
|
e.currentTarget.src = salla.url.cdn('images/s-empty.png');
|
|
135
|
-
} }), h("span", { class: "s-bought-together-item-name" }, product.name)), h("span", { class: "s-bought-together-item-price", innerHTML: salla.money(product.price) }))))), h("salla-button", { class: "s-bought-together-btn", disabled: !this.selectedIds.size || this.isAdding, loading: this.isAdding, onClick: () => this.addSelectedToCart() }, h("span", { innerHTML: `${this.buyTogetherFor} ${this.totalPrice}` }))));
|
|
135
|
+
} }), h("span", { class: "s-bought-together-item-name" }, product.name)), h("span", { class: "s-bought-together-item-price", innerHTML: product.price != null ? salla.money(product.price) : '' }))))), h("salla-button", { class: "s-bought-together-btn", disabled: !this.selectedIds.size || this.isAdding, loading: this.isAdding, onClick: () => this.addSelectedToCart() }, h("span", { innerHTML: `${this.buyTogetherFor} ${this.totalPrice}` }))));
|
|
136
136
|
}
|
|
137
137
|
static get style() { return sallaBoughtTogetherCss; }
|
|
138
138
|
}, [0, "salla-bought-together", {
|
|
@@ -6,13 +6,14 @@ import { a as anime } from './anime.es.js';
|
|
|
6
6
|
import { I as IconArrowLeft } from './arrow-left.js';
|
|
7
7
|
import { C as Cancel } from './cancel.js';
|
|
8
8
|
import { S as SIGiftSharing } from './gift-sharing.js';
|
|
9
|
-
import { d as defineCustomElement$
|
|
10
|
-
import { d as defineCustomElement$
|
|
11
|
-
import { d as defineCustomElement$
|
|
12
|
-
import { d as defineCustomElement$
|
|
13
|
-
import { d as defineCustomElement$
|
|
14
|
-
import { d as defineCustomElement$
|
|
15
|
-
import { d as defineCustomElement$
|
|
9
|
+
import { d as defineCustomElement$c } from './salla-button2.js';
|
|
10
|
+
import { d as defineCustomElement$b } from './salla-datetime-picker2.js';
|
|
11
|
+
import { d as defineCustomElement$a } from './salla-file-upload2.js';
|
|
12
|
+
import { d as defineCustomElement$9 } from './salla-list-tile2.js';
|
|
13
|
+
import { d as defineCustomElement$8 } from './salla-loading2.js';
|
|
14
|
+
import { d as defineCustomElement$7 } from './salla-modal2.js';
|
|
15
|
+
import { d as defineCustomElement$6 } from './salla-placeholder2.js';
|
|
16
|
+
import { d as defineCustomElement$5 } from './salla-searchable-dropdown2.js';
|
|
16
17
|
import { d as defineCustomElement$4 } from './salla-skeleton2.js';
|
|
17
18
|
import { d as defineCustomElement$3 } from './salla-slider2.js';
|
|
18
19
|
import { d as defineCustomElement$2 } from './salla-tel-input2.js';
|
|
@@ -30,7 +31,7 @@ var Alert = `<!-- Generated by IcoMoon.io -->
|
|
|
30
31
|
</svg>
|
|
31
32
|
`;
|
|
32
33
|
|
|
33
|
-
const sallaGiftingCss = ".s-gifting-steps-wrapper{transition:0.2s cubic-bezier(0.55, 0, 0.1, 1) 0s}.s-gifting-select{background-image:url(\"data:image/svg+xml;utf8,<svg version='1.1' fill='gray' xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'><title>keyboard_arrow_down</title><path d='M9.875 11.104l6.125 6.125 6.125-6.125 1.875 1.875-8 8-8-8z'></path></svg>\");background-size:24px;background-repeat:no-repeat;background-position:99%;appearance:none}[dir=rtl] .s-gifting-select{background-position:5px}.s-gifting-widget-vertical .s-list-tile-item [slot=title]{display:flex;align-items:center;gap:1.5rem}.s-gifting-widget-vertical .s-list-tile-item-content{width:100%}";
|
|
34
|
+
const sallaGiftingCss = ".s-gifting-steps-wrapper{transition:0.2s cubic-bezier(0.55, 0, 0.1, 1) 0s}.s-gifting-select{background-image:url(\"data:image/svg+xml;utf8,<svg version='1.1' fill='gray' xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'><title>keyboard_arrow_down</title><path d='M9.875 11.104l6.125 6.125 6.125-6.125 1.875 1.875-8 8-8-8z'></path></svg>\");background-size:24px;background-repeat:no-repeat;background-position:99%;appearance:none}[dir=rtl] .s-gifting-select{background-position:5px}.s-gifting-widget-vertical .s-list-tile-item [slot=title]{display:flex;align-items:center;gap:1.5rem}.s-gifting-widget-vertical .s-list-tile-item-content{width:100%}.s-gifting-modal .s-searchable-dropdown-trigger{border-color:#d1d5db}.s-gifting-modal .s-searchable-dropdown-trigger:hover:not(.s-searchable-dropdown-trigger--disabled){border-color:#d1d5db}.s-gifting-modal .s-searchable-dropdown-trigger--open,.s-gifting-modal .s-searchable-dropdown-trigger:focus{border-color:var(--color-primary, #00897b);box-shadow:0 0 0 1px var(--color-primary, #00897b)}.s-gifting-modal .s-searchable-dropdown-trigger-placeholder{color:#000}";
|
|
34
35
|
|
|
35
36
|
const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting extends HTMLElement {
|
|
36
37
|
constructor() {
|
|
@@ -53,7 +54,17 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
53
54
|
this.regions = [];
|
|
54
55
|
this.selectedRegionId = undefined;
|
|
55
56
|
this.isKSA = false;
|
|
57
|
+
this.selectedCountry = null;
|
|
58
|
+
this.selectedRegion = null;
|
|
59
|
+
this.displayedCities = [];
|
|
60
|
+
this.selectedCity = null;
|
|
61
|
+
this.searchingCities = false;
|
|
62
|
+
this.enableCityAjaxSearch = false;
|
|
63
|
+
this.citySearchQuery = '';
|
|
56
64
|
this.step2Animated = false;
|
|
65
|
+
this.citySearchTimer = null;
|
|
66
|
+
this.citySearchCounter = 0;
|
|
67
|
+
this.locationRequestCounter = 0;
|
|
57
68
|
this.showTextArea = false;
|
|
58
69
|
/// Gift Form Data
|
|
59
70
|
this.selectedImage = undefined;
|
|
@@ -67,6 +78,50 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
67
78
|
* The form selector to be used to get the form data
|
|
68
79
|
*/
|
|
69
80
|
this.formSelector = 'form.product-form, form.form--product-options';
|
|
81
|
+
this.handleCitySearch = (query) => {
|
|
82
|
+
this.citySearchQuery = query;
|
|
83
|
+
if (!this.enableCityAjaxSearch)
|
|
84
|
+
return;
|
|
85
|
+
if (this.citySearchTimer)
|
|
86
|
+
clearTimeout(this.citySearchTimer);
|
|
87
|
+
const requestId = ++this.citySearchCounter;
|
|
88
|
+
this.citySearchTimer = setTimeout(async () => {
|
|
89
|
+
this.searchingCities = true;
|
|
90
|
+
try {
|
|
91
|
+
const cities = await this.fetchCities(query);
|
|
92
|
+
if (requestId === this.citySearchCounter) {
|
|
93
|
+
this.displayedCities = cities;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
catch (e) {
|
|
97
|
+
if (requestId === this.citySearchCounter) {
|
|
98
|
+
this.displayedCities = [];
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
finally {
|
|
102
|
+
if (requestId === this.citySearchCounter) {
|
|
103
|
+
this.searchingCities = false;
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}, SallaGifting.CITY_SEARCH_DEBOUNCE_MS);
|
|
107
|
+
};
|
|
108
|
+
this.handleCitySelected = (city) => {
|
|
109
|
+
this.selectedCity = city;
|
|
110
|
+
this.receiverCity = String(city.id);
|
|
111
|
+
this.clearError('receiver.city_id');
|
|
112
|
+
};
|
|
113
|
+
this.handleCityDropdownClosed = () => {
|
|
114
|
+
this.citySearchQuery = '';
|
|
115
|
+
if (this.citySearchTimer) {
|
|
116
|
+
clearTimeout(this.citySearchTimer);
|
|
117
|
+
this.citySearchTimer = null;
|
|
118
|
+
}
|
|
119
|
+
++this.citySearchCounter;
|
|
120
|
+
this.displayedCities = this.gift?.cities ?? [];
|
|
121
|
+
this.searchingCities = false;
|
|
122
|
+
};
|
|
123
|
+
this.handleCountryDropdownClosed = () => { };
|
|
124
|
+
this.handleRegionDropdownClosed = () => { };
|
|
70
125
|
salla.lang.onLoaded(() => {
|
|
71
126
|
this.selectImageOrUpload = salla.lang.get('blocks.buy_as_gift.select_image_or_upload');
|
|
72
127
|
this.selectImageForYourGift = salla.lang.get('blocks.buy_as_gift.select_image_for_your_gift');
|
|
@@ -340,24 +395,58 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
340
395
|
this.receiverName = event.target.value;
|
|
341
396
|
this.clearError('receiver.name');
|
|
342
397
|
}
|
|
343
|
-
|
|
344
|
-
this.
|
|
345
|
-
|
|
398
|
+
resetCityState() {
|
|
399
|
+
if (this.citySearchTimer) {
|
|
400
|
+
clearTimeout(this.citySearchTimer);
|
|
401
|
+
this.citySearchTimer = null;
|
|
402
|
+
}
|
|
403
|
+
++this.citySearchCounter;
|
|
404
|
+
this.gift = { ...this.gift, cities: [] };
|
|
405
|
+
this.displayedCities = [];
|
|
406
|
+
this.receiverCity = undefined;
|
|
407
|
+
this.selectedCity = null;
|
|
408
|
+
this.citySearchQuery = '';
|
|
409
|
+
this.searchingCities = false;
|
|
410
|
+
this.enableCityAjaxSearch = false;
|
|
411
|
+
}
|
|
412
|
+
setInitialCities(cities) {
|
|
413
|
+
this.gift = { ...this.gift, cities };
|
|
414
|
+
this.displayedCities = cities;
|
|
415
|
+
this.enableCityAjaxSearch = cities.length >= SallaGifting.CITY_AJAX_THRESHOLD;
|
|
416
|
+
}
|
|
417
|
+
async fetchCities(query = '') {
|
|
418
|
+
if (!this.selectedCountryId)
|
|
419
|
+
return [];
|
|
420
|
+
if (this.isKSA && !this.selectedRegionId)
|
|
421
|
+
return [];
|
|
422
|
+
const params = [
|
|
423
|
+
'for_branch=0',
|
|
424
|
+
`country_id=${this.selectedCountryId}`,
|
|
425
|
+
];
|
|
426
|
+
if (this.isKSA && this.selectedRegionId) {
|
|
427
|
+
params.push(`region_id=${this.selectedRegionId}`);
|
|
428
|
+
}
|
|
429
|
+
if (query?.trim()) {
|
|
430
|
+
params.push(`query=${encodeURIComponent(query.trim())}`);
|
|
431
|
+
}
|
|
432
|
+
const response = await salla.api.request(`shipping/cities?${params.join('&')}`);
|
|
433
|
+
return response?.data ?? [];
|
|
346
434
|
}
|
|
347
|
-
async
|
|
348
|
-
const countryId =
|
|
435
|
+
async handleCountrySelected(country) {
|
|
436
|
+
const countryId = country?.id;
|
|
437
|
+
this.selectedCountry = country ?? null;
|
|
349
438
|
this.selectedCountryId = countryId;
|
|
439
|
+
this.selectedCountryCode = country?.country_code;
|
|
440
|
+
this.isKSA = country?.country_code === 'SA';
|
|
350
441
|
this.clearError('receiver.country');
|
|
351
|
-
//
|
|
352
|
-
|
|
353
|
-
this.selectedCountryCode = selectedCountry?.country_code;
|
|
354
|
-
this.isKSA = selectedCountry?.country_code === 'SA';
|
|
355
|
-
// Reset region and city
|
|
442
|
+
// Reset region and city; bump request counter so in-flight loads from a
|
|
443
|
+
// previous country/region selection get discarded when they resolve.
|
|
356
444
|
this.regions = [];
|
|
357
445
|
this.selectedRegionId = undefined;
|
|
358
|
-
this.
|
|
359
|
-
this.
|
|
360
|
-
|
|
446
|
+
this.selectedRegion = null;
|
|
447
|
+
this.resetCityState();
|
|
448
|
+
const requestId = ++this.locationRequestCounter;
|
|
449
|
+
if (!countryId) {
|
|
361
450
|
this.selectedCountryCode = undefined;
|
|
362
451
|
this.isKSA = false;
|
|
363
452
|
this.setWrapperHeight(2, 0, 0);
|
|
@@ -369,16 +458,22 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
369
458
|
this.setWrapperHeight(2, 0, 0);
|
|
370
459
|
try {
|
|
371
460
|
const response = await salla.api.request(`shipping/countries/${countryId}/regions`);
|
|
461
|
+
if (requestId !== this.locationRequestCounter)
|
|
462
|
+
return;
|
|
372
463
|
if (response && response.data) {
|
|
373
464
|
this.regions = response.data;
|
|
374
465
|
}
|
|
375
466
|
}
|
|
376
467
|
catch (error) {
|
|
468
|
+
if (requestId !== this.locationRequestCounter)
|
|
469
|
+
return;
|
|
377
470
|
console.error('Error fetching regions:', error);
|
|
378
471
|
}
|
|
379
472
|
finally {
|
|
380
|
-
this.
|
|
381
|
-
|
|
473
|
+
if (requestId === this.locationRequestCounter) {
|
|
474
|
+
this.loadingRegions = false;
|
|
475
|
+
this.setWrapperHeight(2, 0, 0);
|
|
476
|
+
}
|
|
382
477
|
}
|
|
383
478
|
}
|
|
384
479
|
else {
|
|
@@ -386,41 +481,51 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
386
481
|
this.loadingCities = true;
|
|
387
482
|
this.setWrapperHeight(2, 0, 0);
|
|
388
483
|
try {
|
|
389
|
-
const
|
|
390
|
-
if (
|
|
391
|
-
|
|
392
|
-
|
|
484
|
+
const cities = await this.fetchCities();
|
|
485
|
+
if (requestId !== this.locationRequestCounter)
|
|
486
|
+
return;
|
|
487
|
+
this.setInitialCities(cities);
|
|
393
488
|
}
|
|
394
489
|
catch (error) {
|
|
490
|
+
if (requestId !== this.locationRequestCounter)
|
|
491
|
+
return;
|
|
395
492
|
console.error('Error fetching cities:', error);
|
|
396
493
|
}
|
|
397
494
|
finally {
|
|
398
|
-
this.
|
|
495
|
+
if (requestId === this.locationRequestCounter) {
|
|
496
|
+
this.loadingCities = false;
|
|
497
|
+
}
|
|
399
498
|
}
|
|
400
499
|
}
|
|
401
500
|
}
|
|
402
|
-
async
|
|
403
|
-
const regionId =
|
|
501
|
+
async handleRegionSelected(region) {
|
|
502
|
+
const regionId = region?.id;
|
|
503
|
+
this.selectedRegion = region ?? null;
|
|
404
504
|
this.selectedRegionId = regionId;
|
|
405
505
|
this.clearError('receiver.region');
|
|
406
|
-
// Reset city when region changes
|
|
407
|
-
|
|
408
|
-
this.
|
|
506
|
+
// Reset city when region changes; bump request counter so any earlier
|
|
507
|
+
// in-flight city fetch (for a previous region) is discarded on resolve.
|
|
508
|
+
this.resetCityState();
|
|
509
|
+
const requestId = ++this.locationRequestCounter;
|
|
409
510
|
if (!regionId)
|
|
410
511
|
return;
|
|
411
512
|
this.loadingCities = true;
|
|
412
513
|
try {
|
|
413
|
-
const
|
|
414
|
-
if (
|
|
415
|
-
|
|
416
|
-
|
|
514
|
+
const cities = await this.fetchCities();
|
|
515
|
+
if (requestId !== this.locationRequestCounter)
|
|
516
|
+
return;
|
|
517
|
+
this.setInitialCities(cities);
|
|
417
518
|
}
|
|
418
519
|
catch (error) {
|
|
520
|
+
if (requestId !== this.locationRequestCounter)
|
|
521
|
+
return;
|
|
419
522
|
console.error('Error fetching cities:', error);
|
|
420
523
|
}
|
|
421
524
|
finally {
|
|
422
|
-
this.
|
|
423
|
-
|
|
525
|
+
if (requestId === this.locationRequestCounter) {
|
|
526
|
+
this.loadingCities = false;
|
|
527
|
+
this.setWrapperHeight(2, 0, 0);
|
|
528
|
+
}
|
|
424
529
|
}
|
|
425
530
|
}
|
|
426
531
|
handleUploadImage(img) {
|
|
@@ -565,7 +670,7 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
565
670
|
}
|
|
566
671
|
render() {
|
|
567
672
|
return [
|
|
568
|
-
h("div", { key: '
|
|
673
|
+
h("div", { key: 'db700f9ec96a6974f3b815bb017ebe97ae8fe5c0' }, h("salla-list-tile", { key: '1e2fd1c0b375c85fcd4af1ea071c36879e6913c5', class: this.generateClass() }, h("div", { key: 'a9d02c933bc13bf8765e7e91ce08b2c9495954e5', slot: "title" }, this.vertical ? h("span", { innerHTML: SIGiftSharing }) : '', h("h3", { key: '56bd850368806c6ed5770ea5f6b0339749a77dfa' }, !!this.widgetTitle ? this.widgetTitle : this.sectionTitle)), h("div", { key: 'fbb4940fd3e3578f2f5a479d9d44be8dfbda7e43', slot: "subtitle" }, h("div", { key: 'fb7e8532984fbfc6fd61c55a6d44d7cdbb4bc9a2' }, !!this.widgetSubtitle ? this.widgetSubtitle : this.sectionSubtitle)), h("div", { key: '04f27f1ddbfa0b06be111b6c3176fbda5ea6d43a', slot: "action" }, h("salla-button", { key: 'fe71a1a773e5275ede7d1b3ea535c330688028b7', color: "primary", fill: "outline", width: "wide", class: "s-gifting-widget-action", onClick: () => this.handleGiftButtonClick() }, h("slot", { key: 'd62127d30254df2d8add55e0e1dbcfefb686e359', name: "widget-btn-content" }, h("div", { key: '5ddbb695af142baf3bb6986627f97a7a7607eb31', class: "s-gifting-widget-action-content" }, h("span", { key: '7820fb6abd9d7a9c1035c0f80191a3ff2a4c5fe8', innerHTML: SIGiftSharing }), " \u00A0", h("span", { key: '2cfc69862d3d087375efaed3bcec0ff0c1587989' }, this.sectionBtnText)))))), h("salla-modal", { key: '32c19391248ba6186f43fea59493171079e7bf07', id: this.hostId, isLoading: true, class: "s-gifting-modal", width: "sm", ref: modal => this.modal = modal }, h("div", { key: 'e4b5829416314f25793158dae0c530b8057b4085', slot: "loading" }, h("div", { key: '6ee873add5868f105b7ec7291c2a8c8fc033c588', class: "s-gifting-skeleton" }, h("div", { key: '40aae38f8b2d62b434394811a3ef6d8bc00f6f32', class: "s-gifting-modal-header" }, h("salla-skeleton", { key: 'a652cd74a16d0db662ea4a518ebfab366a3c3899', type: 'circle', height: '5rem', width: '5rem' }), h("h2", { key: 'edb4a1477893246e98207aeba7bfb5af686f20b9', class: "s-gifting-modal-title" }, h("div", { key: '83ef942b15450cc59ad32d8c5b3ba43a32bcb29c', class: "s-gifting-modal-badge-wrapper" }, h("salla-skeleton", { key: 'd9041c777a2fa0aa7ffc752958c7441916a02f85', height: '15px', width: '150px' })))), h("div", { key: 'fe3bb9dad01becba87486c4886037fd67b059919', class: "s-gifting-skeleton-content" }, h("salla-skeleton", { key: '08bd8304b66264b70f6df68e64da3560a1f75461', height: '10px', width: '150px' }), h("salla-skeleton", { key: 'bbea0d7ff0c846897af2ef5d3696b252a2f4e662', height: '230px' }), h("salla-skeleton", { key: '8cb1fde02e31a1accabd2e26409983e7ba56eeb1', height: '10px', width: '150px' }), h("salla-skeleton", { key: 'f80a986b953278bac41505506adf8d611566a167', height: '30px' }), h("salla-skeleton", { key: 'f7eccce69b619de385872642e1fb62b2cf6c3082', height: '40px' })))), h("slot", { key: 'd299e46040193b441f8171d05e0048849e3df8d5', name: "header" }), !!this.hasError ?
|
|
569
674
|
h("salla-placeholder", { alignment: "center" }, h("span", { slot: "title" }, this.errorMessage || salla.lang.get('common.errors.empty_results')), h("span", { slot: "description" }, " "))
|
|
570
675
|
:
|
|
571
676
|
[
|
|
@@ -578,14 +683,14 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
578
683
|
h("span", { class: "s-gifting-error" }, this.errors['sender_name']) : ''), h("div", { class: this.step2ItemClass(this.errors?.['receiver.name'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { htmlFor: "receiver_name", class: "s-form-label" }, this.receiverNameFieldLabel), h("input", { type: "text", class: "s-form-control", name: "receiver_name", id: "receiver_name", value: "", onInput: (event) => this.handleReceiverName(event), placeholder: "" }), this.errors && this.errors['receiver.name'] ?
|
|
579
684
|
h("span", { class: "s-gifting-error" }, this.errors['receiver.name']) : ''), h("div", { class: this.step2ItemClass(this.errors?.['receiver.mobile'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { class: "s-form-label" }, this.receiverMobileFieldLabel), h("salla-tel-input", { class: "s-gifting-tel-input", phone: this.receiverMobile, countryCode: this.receiverCountryCode, onPhoneEntered: (e) => this.handlePhoneInputChange(e) }), this.errors && this.errors['receiver.mobile'] ?
|
|
580
685
|
h("span", { class: "s-gifting-error" }, this.errors['receiver.mobile']) : ''), this.isPhysical() &&
|
|
581
|
-
h("div", { class: this.step2ItemClass(this.errors?.['receiver.country'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { class: "s-form-label" }, this.receiverCountryFieldLabel), h("
|
|
686
|
+
h("div", { class: this.step2ItemClass(this.errors?.['receiver.country'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { class: "s-form-label", htmlFor: `${this.hostId}-country` }, this.receiverCountryFieldLabel), h("salla-searchable-dropdown", { placeholder: this.selectCountry, items: this.gift?.countries ?? [], selectedItem: this.selectedCountry, disabled: !this.gift?.countries?.length, required: true, inputId: `${this.hostId}-country`, searchable: false, keepParentScroll: true, onItemSelected: (e) => this.handleCountrySelected(e.detail), onDropdownClosed: () => this.handleCountryDropdownClosed() }), this.errors && this.errors['receiver.country'] ?
|
|
582
687
|
h("span", { class: "s-gifting-error" }, this.errors['receiver.country']) : ''), this.isPhysical() && this.isKSA &&
|
|
583
|
-
h("div", { class: this.step2ItemClass(this.errors?.['receiver.region'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { class: "s-form-label" }, this.receiverRegionFieldLabel), h("
|
|
688
|
+
h("div", { class: this.step2ItemClass(this.errors?.['receiver.region'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { class: "s-form-label", htmlFor: `${this.hostId}-region` }, this.receiverRegionFieldLabel), h("salla-searchable-dropdown", { placeholder: this.selectRegion, items: this.regions ?? [], selectedItem: this.selectedRegion, loading: this.loadingRegions, disabled: this.loadingRegions || !this.regions?.length, required: true, inputId: `${this.hostId}-region`, searchable: false, keepParentScroll: true, onItemSelected: (e) => this.handleRegionSelected(e.detail), onDropdownClosed: () => this.handleRegionDropdownClosed() }), this.errors && this.errors['receiver.region'] ?
|
|
584
689
|
h("span", { class: "s-gifting-error" }, this.errors['receiver.region']) : ''), this.isPhysical() &&
|
|
585
|
-
h("div", { class: this.step2ItemClass(this.errors?.['receiver.city_id'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { class: "s-form-label" }, this.receiverCityFieldLabel), h("
|
|
690
|
+
h("div", { class: this.step2ItemClass(this.errors?.['receiver.city_id'] ? 's-form-group s-form-has-error' : 's-form-group') }, h("label", { class: "s-form-label", htmlFor: `${this.hostId}-city` }, this.receiverCityFieldLabel), h("salla-searchable-dropdown", { placeholder: this.selectCity, items: this.displayedCities, selectedItem: this.selectedCity, loading: this.loadingCities, searching: this.searchingCities, disabled: this.loadingCities || (this.isKSA && !this.selectedRegionId), required: true, inputId: `${this.hostId}-city`, searchQuery: this.citySearchQuery, clientSearch: !this.enableCityAjaxSearch, dropUp: true, keepParentScroll: true, onItemSelected: (e) => this.handleCitySelected(e.detail), onSearchInput: (e) => this.handleCitySearch(e.detail), onDropdownClosed: () => this.handleCityDropdownClosed() }), this.errors && this.errors['receiver.city_id'] ?
|
|
586
691
|
h("span", { class: "s-gifting-error" }, this.errors['receiver.city_id']) : ''), this.isPhysical() &&
|
|
587
692
|
h("div", { class: this.step2ItemClass('s-gifting-info') }, h("span", { innerHTML: Alert }), h("span", null, this.selectCityInfo)), !this.isPhysical() && h("div", { class: this.step2ItemClass() }, h("label", { class: "s-gifting-schedule s-gifting-clickable", htmlFor: `schedule-${this.hostId}` }, h("input", { type: "checkbox", name: 'schedule', id: `schedule-${this.hostId}`, onChange: () => this.toggleCalendar(), class: "s-checkbox" }), h("span", { class: "s-form-label" }, " ", this.sendLater, " "))), h("div", { class: this.getCalendarClasses(), ref: (el) => this.calendarFormGroup = el }, h("label", { class: "s-form-label" }, this.selectSendDateAndTime), h("salla-datetime-picker", { value: this.deliveryDate, placeholder: this.selectSendDateAndTime, "enable-time": true, "date-format": "Y-m-d h:i K", onPicked: (event) => this.handleDateTimePicker(event) }), h("span", { class: "s-gifting-calendar-hint" }, this.canNotEditOrderAfterSelectDate)), h("div", { class: this.step2ItemClass('s-gifting-step-two-footer') }, h("a", { href: "#!", innerHTML: IconArrowLeft, onClick: (e) => this.goToStep1(e) }), h("salla-button", { onClick: () => this.submitForm(), color: "primary", width: 'wide' }, h("span", null, this.sendGift)))))
|
|
588
|
-
], h("slot", { key: '
|
|
693
|
+
], h("slot", { key: 'bd8cd1628ed4282b177f0ddcd5fb93289c47b4d6', name: "footer" })))
|
|
589
694
|
];
|
|
590
695
|
}
|
|
591
696
|
static get style() { return sallaGiftingCss; }
|
|
@@ -641,6 +746,13 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
641
746
|
"regions": [32],
|
|
642
747
|
"selectedRegionId": [32],
|
|
643
748
|
"isKSA": [32],
|
|
749
|
+
"selectedCountry": [32],
|
|
750
|
+
"selectedRegion": [32],
|
|
751
|
+
"displayedCities": [32],
|
|
752
|
+
"selectedCity": [32],
|
|
753
|
+
"searchingCities": [32],
|
|
754
|
+
"enableCityAjaxSearch": [32],
|
|
755
|
+
"citySearchQuery": [32],
|
|
644
756
|
"parsedFormData": [32],
|
|
645
757
|
"showTextArea": [32],
|
|
646
758
|
"selectedImage": [32],
|
|
@@ -662,11 +774,13 @@ const SallaGifting$1 = /*@__PURE__*/ proxyCustomElement(class SallaGifting exten
|
|
|
662
774
|
"close": [64],
|
|
663
775
|
"goToStep2": [64]
|
|
664
776
|
}]);
|
|
777
|
+
SallaGifting$1.CITY_AJAX_THRESHOLD = 400;
|
|
778
|
+
SallaGifting$1.CITY_SEARCH_DEBOUNCE_MS = 100;
|
|
665
779
|
function defineCustomElement$1() {
|
|
666
780
|
if (typeof customElements === "undefined") {
|
|
667
781
|
return;
|
|
668
782
|
}
|
|
669
|
-
const components = ["salla-gifting", "salla-button", "salla-datetime-picker", "salla-file-upload", "salla-list-tile", "salla-loading", "salla-modal", "salla-placeholder", "salla-skeleton", "salla-slider", "salla-tel-input"];
|
|
783
|
+
const components = ["salla-gifting", "salla-button", "salla-datetime-picker", "salla-file-upload", "salla-list-tile", "salla-loading", "salla-modal", "salla-placeholder", "salla-searchable-dropdown", "salla-skeleton", "salla-slider", "salla-tel-input"];
|
|
670
784
|
components.forEach(tagName => { switch (tagName) {
|
|
671
785
|
case "salla-gifting":
|
|
672
786
|
if (!customElements.get(tagName)) {
|
|
@@ -675,35 +789,40 @@ function defineCustomElement$1() {
|
|
|
675
789
|
break;
|
|
676
790
|
case "salla-button":
|
|
677
791
|
if (!customElements.get(tagName)) {
|
|
678
|
-
defineCustomElement$
|
|
792
|
+
defineCustomElement$c();
|
|
679
793
|
}
|
|
680
794
|
break;
|
|
681
795
|
case "salla-datetime-picker":
|
|
682
796
|
if (!customElements.get(tagName)) {
|
|
683
|
-
defineCustomElement$
|
|
797
|
+
defineCustomElement$b();
|
|
684
798
|
}
|
|
685
799
|
break;
|
|
686
800
|
case "salla-file-upload":
|
|
687
801
|
if (!customElements.get(tagName)) {
|
|
688
|
-
defineCustomElement$
|
|
802
|
+
defineCustomElement$a();
|
|
689
803
|
}
|
|
690
804
|
break;
|
|
691
805
|
case "salla-list-tile":
|
|
692
806
|
if (!customElements.get(tagName)) {
|
|
693
|
-
defineCustomElement$
|
|
807
|
+
defineCustomElement$9();
|
|
694
808
|
}
|
|
695
809
|
break;
|
|
696
810
|
case "salla-loading":
|
|
697
811
|
if (!customElements.get(tagName)) {
|
|
698
|
-
defineCustomElement$
|
|
812
|
+
defineCustomElement$8();
|
|
699
813
|
}
|
|
700
814
|
break;
|
|
701
815
|
case "salla-modal":
|
|
702
816
|
if (!customElements.get(tagName)) {
|
|
703
|
-
defineCustomElement$
|
|
817
|
+
defineCustomElement$7();
|
|
704
818
|
}
|
|
705
819
|
break;
|
|
706
820
|
case "salla-placeholder":
|
|
821
|
+
if (!customElements.get(tagName)) {
|
|
822
|
+
defineCustomElement$6();
|
|
823
|
+
}
|
|
824
|
+
break;
|
|
825
|
+
case "salla-searchable-dropdown":
|
|
707
826
|
if (!customElements.get(tagName)) {
|
|
708
827
|
defineCustomElement$5();
|
|
709
828
|
}
|
|
@@ -39,6 +39,7 @@ const SallaOrderEdit$1 = /*@__PURE__*/ proxyCustomElement(class SallaOrderEdit e
|
|
|
39
39
|
this.addProductConfirmLoading = false;
|
|
40
40
|
this.mobileProductsModalMounted = false;
|
|
41
41
|
this.isMobileViewport = false;
|
|
42
|
+
this.isRTL = true;
|
|
42
43
|
// Plain field (not @State): scroll-loading guard never affects rendering, so avoid re-render churn.
|
|
43
44
|
this.mobileProductsListLoading = false;
|
|
44
45
|
this.confirming = false;
|
|
@@ -81,6 +82,9 @@ const SallaOrderEdit$1 = /*@__PURE__*/ proxyCustomElement(class SallaOrderEdit e
|
|
|
81
82
|
};
|
|
82
83
|
this.defaultProductsListSource = 'latest';
|
|
83
84
|
this.debouncedProductSearch = salla.helpers.debounce((query) => this.applyProductSearch(query), 500);
|
|
85
|
+
salla.onReady(() => {
|
|
86
|
+
this.isRTL = salla.config.get('theme.is_rtl', true);
|
|
87
|
+
});
|
|
84
88
|
}
|
|
85
89
|
getParsedExcludedCategories() {
|
|
86
90
|
if (!this.excludedCategories) {
|
|
@@ -434,6 +438,13 @@ const SallaOrderEdit$1 = /*@__PURE__*/ proxyCustomElement(class SallaOrderEdit e
|
|
|
434
438
|
this.navigateToOrder();
|
|
435
439
|
}
|
|
436
440
|
}
|
|
441
|
+
returnToOrderDetails() {
|
|
442
|
+
this.confirming = true;
|
|
443
|
+
this.navigateToOrder();
|
|
444
|
+
}
|
|
445
|
+
getConfirmButtonIconClass() {
|
|
446
|
+
return this.isRTL ? 'sicon-keyboard_arrow_left' : 'sicon-keyboard_arrow_right';
|
|
447
|
+
}
|
|
437
448
|
async cancelEditSession() {
|
|
438
449
|
try {
|
|
439
450
|
await salla.order.api.cancelEditSession(this.orderId);
|
|
@@ -483,7 +494,7 @@ const SallaOrderEdit$1 = /*@__PURE__*/ proxyCustomElement(class SallaOrderEdit e
|
|
|
483
494
|
const hasRemainingAmount = preview?.totals?.remaining_amount?.amount > 0;
|
|
484
495
|
const hasRefundAmount = preview?.totals?.refund_amount?.amount > 0;
|
|
485
496
|
const taxAmount = preview?.totals?.tax?.amount?.amount;
|
|
486
|
-
return (h("salla-modal", { ref: modal => (this.saveModal = modal), width: "md", onModalVisibilityChanged: async (e) => {
|
|
497
|
+
return (h("salla-modal", { ref: modal => (this.saveModal = modal), width: "md", isClosable: false, onModalVisibilityChanged: async (e) => {
|
|
487
498
|
if (!e.detail) {
|
|
488
499
|
this.editPreview = null;
|
|
489
500
|
if (!this.confirming) {
|
|
@@ -491,7 +502,7 @@ const SallaOrderEdit$1 = /*@__PURE__*/ proxyCustomElement(class SallaOrderEdit e
|
|
|
491
502
|
}
|
|
492
503
|
this.confirming = false;
|
|
493
504
|
}
|
|
494
|
-
} }, h("div", { class: "s-order-edit-modal" }, h("h2", { class: "s-order-edit-modal-title" }, salla.lang.getWithDefault('pages.orders.edit_summary_title', 'ملخص الطلب بعد التعديل')), preview?.items?.length > 0 && (h("div", { class: "s-order-edit-modal-items" }, preview.items.map(item => {
|
|
505
|
+
} }, h("div", { class: "s-order-edit-modal" }, h("h2", { class: "s-order-edit-modal-title" }, salla.lang.getWithDefault('pages.orders.edit_summary_title', 'ملخص الطلب بعد التعديل')), h("p", { class: "s-order-edit-modal-subtitle" }, salla.lang.getWithDefault('pages.orders.cart_edits_saved', 'Your cart edits have been saved')), preview?.items?.length > 0 && (h("div", { class: "s-order-edit-modal-items" }, preview.items.map(item => {
|
|
495
506
|
const orderItem = this.order?.items?.find(oi => oi.id == item.id);
|
|
496
507
|
const imageUrl = orderItem?.product?.image?.url;
|
|
497
508
|
const optionsLabel = item.options?.join('/ ');
|
|
@@ -500,7 +511,7 @@ const SallaOrderEdit$1 = /*@__PURE__*/ proxyCustomElement(class SallaOrderEdit e
|
|
|
500
511
|
? salla.lang.getWithDefault('pages.orders.pay_difference', 'دفع فارق المبلغ')
|
|
501
512
|
: hasRefundAmount
|
|
502
513
|
? salla.lang.getWithDefault('pages.orders.confirm_and_receive_difference', 'تأكيد واستلام فارق المبلغ')
|
|
503
|
-
: salla.lang.getWithDefault('pages.orders.confirm_changes', 'تأكيد التعديلات'), h("i", { class:
|
|
514
|
+
: salla.lang.getWithDefault('pages.orders.confirm_changes', 'تأكيد التعديلات'), h("i", { class: `${this.getConfirmButtonIconClass()} s-order-edit-modal-btn-icon` })), h("salla-button", { color: 'gray', fill: "outline", onClick: () => this.returnToOrderDetails() }, salla.lang.getWithDefault('pages.orders.back_to_order_details', 'العودة إلى تفاصيل الطلب'))))));
|
|
504
515
|
}
|
|
505
516
|
render() {
|
|
506
517
|
if (this.loading) {
|
|
@@ -540,7 +551,8 @@ const SallaOrderEdit$1 = /*@__PURE__*/ proxyCustomElement(class SallaOrderEdit e
|
|
|
540
551
|
"addProductLoading": [32],
|
|
541
552
|
"addProductConfirmLoading": [32],
|
|
542
553
|
"mobileProductsModalMounted": [32],
|
|
543
|
-
"isMobileViewport": [32]
|
|
554
|
+
"isMobileViewport": [32],
|
|
555
|
+
"isRTL": [32]
|
|
544
556
|
}, [[0, "orderEditProductSelected", "handleProductSelected"], [0, "orderItemUpdated", "handleItemUpdated"], [0, "orderItemRemoved", "handleItemRemoved"]]]);
|
|
545
557
|
function defineCustomElement$1() {
|
|
546
558
|
if (typeof customElements === "undefined") {
|