@salla.sa/twilight-components 3.0.19 → 3.0.20
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/{Helper-DqKJCL8G.js → Helper-C3MBaLHQ.js} +1 -1
- package/dist/cjs/delivery-promise-intent-5WTKLkFZ.js +71 -0
- package/dist/cjs/{filepond-Byu0lc8z.js → filepond-DGt10gCq.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-poster-qwx7lYZ-.js → filepond-plugin-file-poster-NSV7ClY6.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-validate-size-C-n0P4TT.js → filepond-plugin-file-validate-size-C08-fDj7.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-validate-type-C8VOOXdT.js → filepond-plugin-file-validate-type-CbbTh4qd.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-edit-B9KG763Y.js → filepond-plugin-image-edit-CqqtsmjD.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-exif-orientation-Czt4pYzU.js → filepond-plugin-image-exif-orientation-D60HJIiL.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-preview-BFm1Zl0o.js → filepond-plugin-image-preview-B7bWOXFm.js} +1 -1
- package/dist/cjs/{helpers-NV7wgP50.js → helpers-wRMwEkLy.js} +25 -0
- package/dist/cjs/{index-CFW798jX.js → index-U-OadFju.js} +14 -10
- package/dist/cjs/{intlTelInput-CLa2B89b.js → intlTelInput-Cp6WJvPO.js} +1 -1
- 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 +2 -2
- package/dist/cjs/salla-add-product-button_5.cjs.entry.js +120 -6
- 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-applied-filters.cjs.entry.js +2 -2
- package/dist/cjs/salla-apps-icons.cjs.entry.js +1 -1
- package/dist/cjs/salla-attachment-view_9.cjs.entry.js +13 -13
- package/dist/cjs/salla-badge.cjs.entry.js +1 -1
- package/dist/cjs/salla-basket-gap.cjs.entry.js +1 -1
- package/dist/cjs/salla-bullet-delivery_3.cjs.entry.js +12 -17
- 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-cart-summary-card.cjs.entry.js +1 -1
- package/dist/cjs/salla-cashback-banner.cjs.entry.js +1 -1
- package/dist/cjs/salla-comment-factors.cjs.entry.js +1 -1
- package/dist/cjs/salla-comment-form_9.cjs.entry.js +4 -4
- 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 +5 -65
- package/dist/cjs/salla-edit-order-button.cjs.entry.js +1 -1
- package/dist/cjs/salla-filters-widget.cjs.entry.js +2 -2
- package/dist/cjs/salla-filters.cjs.entry.js +2 -2
- package/dist/cjs/salla-free-shipping-banner.cjs.entry.js +1 -1
- package/dist/cjs/salla-free-shipping-tag.cjs.entry.js +1 -1
- package/dist/cjs/salla-fulfillment-methods.cjs.entry.js +1 -1
- package/dist/cjs/salla-gift-card-redeem_2.cjs.entry.js +2 -2
- package/dist/cjs/salla-gifting.cjs.entry.js +1 -1
- package/dist/cjs/salla-hook.cjs.entry.js +1 -1
- package/dist/cjs/salla-infinite-scroll.cjs.entry.js +2 -2
- 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_10.cjs.entry.js +1 -1
- package/dist/cjs/salla-loyalty-exchange-product-card.cjs.entry.js +1 -1
- package/dist/cjs/salla-loyalty-points-banner.cjs.entry.js +1 -1
- package/dist/cjs/salla-loyalty-points-history.cjs.entry.js +1 -1
- package/dist/cjs/salla-loyalty-prize-item.cjs.entry.js +1 -1
- 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_3.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-mobile-update-modal.cjs.entry.js +188 -0
- package/dist/cjs/salla-multiple-bundle-product-cart_2.cjs.entry.js +4 -4
- package/dist/cjs/salla-multiple-bundle-product-options-modal_2.cjs.entry.js +6 -6
- package/dist/cjs/salla-multiple-bundle-product.cjs.entry.js +2 -2
- package/dist/cjs/salla-next-order-coupon.cjs.entry.js +1 -1
- package/dist/cjs/salla-notification-item_2.cjs.entry.js +3 -3
- package/dist/cjs/salla-offer-modal.cjs.entry.js +2 -2
- package/dist/cjs/salla-offer.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-branch.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-cancel.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 +2 -2
- package/dist/cjs/salla-order-edit-item.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-edit-product-card.cjs.entry.js +2 -2
- package/dist/cjs/salla-order-edit.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-items.cjs.entry.js +2 -2
- package/dist/cjs/salla-order-options-modal.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-payment.cjs.entry.js +2 -2
- package/dist/cjs/salla-order-rewards.cjs.entry.js +2 -2
- package/dist/cjs/salla-order-shipments.cjs.entry.js +1 -1
- package/dist/cjs/salla-order-summary.cjs.entry.js +2 -2
- package/dist/cjs/salla-order-totals-card.cjs.entry.js +1 -1
- package/dist/cjs/salla-orders.cjs.entry.js +2 -2
- package/dist/cjs/salla-payments.cjs.entry.js +3 -3
- package/dist/cjs/salla-placeholder.cjs.entry.js +2 -2
- package/dist/cjs/salla-price-range.cjs.entry.js +1 -1
- package/dist/cjs/salla-product-card-embed.cjs.entry.js +2 -2
- package/dist/cjs/salla-product-card.cjs.entry.js +1 -1
- package/dist/cjs/salla-product-size-guide.cjs.entry.js +3 -3
- package/dist/cjs/salla-products-list.cjs.entry.js +2 -2
- package/dist/cjs/salla-products-slider.cjs.entry.js +2 -2
- package/dist/cjs/salla-quick-order.cjs.entry.js +1 -1
- package/dist/cjs/salla-rating-modal-v2.cjs.entry.js +33 -7
- package/dist/cjs/salla-rating-modal.cjs.entry.js +2 -2
- package/dist/cjs/salla-review-factors-tags.cjs.entry.js +2 -2
- package/dist/cjs/salla-review-order-item.cjs.entry.js +1 -1
- package/dist/cjs/salla-scopes.cjs.entry.js +1 -1
- package/dist/cjs/salla-search-product-card.cjs.entry.js +3 -3
- package/dist/cjs/salla-search.cjs.entry.js +2 -2
- package/dist/cjs/salla-skeleton.cjs.entry.js +2 -2
- package/dist/cjs/salla-social-share.cjs.entry.js +2 -2
- package/dist/cjs/salla-social.cjs.entry.js +2 -2
- package/dist/cjs/salla-tab-content_3.cjs.entry.js +4 -4
- package/dist/cjs/salla-thank-you-header.cjs.entry.js +2 -2
- package/dist/cjs/salla-thank-you-page.cjs.entry.js +2 -2
- package/dist/cjs/salla-tiered-offer.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 +2 -2
- package/dist/cjs/salla-verify.cjs.entry.js +3 -3
- package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
- package/dist/cjs/salla-wishlist-actions.cjs.entry.js +2 -2
- package/dist/cjs/salla-wishlist-summary.cjs.entry.js +2 -2
- package/dist/cjs/twilight.cjs.js +2 -2
- package/dist/cjs/{vanilla-picker-Vx_7G7bs.js → vanilla-picker-C-rN_NiT.js} +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/salla-bullet-delivery/helpers.js +23 -0
- package/dist/collection/components/salla-bullet-delivery/salla-bullet-delivery.js +7 -12
- package/dist/collection/components/salla-mobile-update-modal/salla-mobile-update-modal.css +43 -0
- package/dist/collection/components/salla-mobile-update-modal/salla-mobile-update-modal.js +235 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-cart.js +1 -1
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-details.js +2 -2
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-options-modal.js +4 -4
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-slider.js +1 -1
- package/dist/collection/components/salla-multiple-bundle-product/salla-multiple-bundle-product.js +1 -1
- package/dist/collection/components/salla-notifications/salla-notification-item.js +1 -1
- package/dist/collection/components/salla-offer-modal/salla-offer-modal.js +1 -1
- package/dist/collection/components/salla-order-details/salla-order-details.js +1 -1
- package/dist/collection/components/salla-order-edit/salla-order-edit-product-card.js +1 -1
- package/dist/collection/components/salla-order-items/salla-order-items.js +1 -1
- package/dist/collection/components/salla-order-payment/salla-order-payment.js +1 -1
- package/dist/collection/components/salla-order-rewards/salla-order-rewards.js +1 -1
- package/dist/collection/components/salla-order-summary/salla-order-summary.js +1 -1
- package/dist/collection/components/salla-payments/salla-payments.js +2 -2
- package/dist/collection/components/salla-placeholder/salla-placeholder.js +1 -1
- package/dist/collection/components/salla-product-availability/salla-product-availability.js +1 -1
- package/dist/collection/components/salla-product-card-embed/salla-product-card-embed.js +1 -1
- package/dist/collection/components/salla-product-size-guide/salla-product-size-guide.js +2 -2
- package/dist/collection/components/salla-quantity-input/salla-quantity-input.js +1 -1
- package/dist/collection/components/salla-quick-buy/salla-quick-buy.js +47 -1
- package/dist/collection/components/salla-rating-modal/salla-rating-modal-v2.js +31 -5
- package/dist/collection/components/salla-review-card/salla-review-card.js +1 -1
- package/dist/collection/components/salla-review-factors-tags/salla-review-factors-tags.js +1 -1
- package/dist/collection/components/salla-reviews-page/salla-reviews-page.js +1 -1
- package/dist/collection/components/salla-search-product-card/salla-search-product-card.js +2 -2
- package/dist/collection/components/salla-searchable-dropdown/salla-searchable-dropdown.js +4 -4
- package/dist/collection/components/salla-skeleton/salla-skeleton.js +1 -1
- package/dist/collection/components/salla-social/salla-social.js +1 -1
- package/dist/collection/components/salla-social-share/salla-social-share.js +1 -1
- package/dist/collection/components/salla-tabs/salla-tab-content.js +1 -1
- package/dist/collection/components/salla-tabs/salla-tab-header.js +1 -1
- package/dist/collection/components/salla-tabs/salla-tabs.js +1 -1
- package/dist/collection/components/salla-tel-input/salla-tel-input.js +1 -1
- package/dist/collection/components/salla-thank-you-header/salla-thank-you-header.js +1 -1
- package/dist/collection/components/salla-thank-you-page/salla-thank-you-page.js +1 -1
- package/dist/collection/components/salla-tooltip/salla-tooltip.js +1 -1
- package/dist/collection/components/salla-user-settings/salla-user-settings.js +1 -1
- package/dist/collection/components/salla-verify/salla-verify.js +48 -2
- package/dist/collection/components/salla-wishlist-actions/salla-wishlist-actions.js +1 -1
- package/dist/components/delivery-promise-intent.js +67 -0
- package/dist/components/helpers.js +24 -1
- package/dist/components/index.js +2 -2
- package/dist/components/mail.js +2 -2
- package/dist/components/salla-bullet-delivery.js +7 -12
- package/dist/components/salla-contacts.js +2 -2
- package/dist/components/salla-delivery-promise.js +1 -62
- package/dist/components/salla-loyalty-point2.js +2 -2
- package/dist/components/salla-mobile-update-modal.d.ts +11 -0
- package/dist/components/salla-mobile-update-modal.js +241 -0
- package/dist/components/salla-multiple-bundle-product-cart2.js +1 -1
- package/dist/components/salla-multiple-bundle-product-details2.js +2 -2
- package/dist/components/salla-multiple-bundle-product-options-modal2.js +4 -4
- package/dist/components/salla-multiple-bundle-product-slider2.js +1 -1
- package/dist/components/salla-multiple-bundle-product.js +1 -1
- package/dist/components/salla-notification-item2.js +1 -1
- package/dist/components/salla-offer-modal.js +1 -1
- package/dist/components/salla-order-details.js +1 -1
- package/dist/components/salla-order-edit-product-card.js +1 -1
- package/dist/components/salla-order-items2.js +1 -1
- package/dist/components/salla-order-payment.js +1 -1
- package/dist/components/salla-order-rewards.js +1 -1
- package/dist/components/salla-order-summary.js +1 -1
- package/dist/components/salla-payments.js +2 -2
- package/dist/components/salla-placeholder2.js +1 -1
- package/dist/components/salla-product-availability2.js +1 -1
- package/dist/components/salla-product-card-embed.js +1 -1
- package/dist/components/salla-product-size-guide.js +2 -2
- package/dist/components/salla-quantity-input2.js +1 -1
- package/dist/components/salla-quick-buy2.js +117 -3
- package/dist/components/salla-quick-order.js +2 -2
- package/dist/components/salla-rating-modal-v22.js +33 -7
- package/dist/components/salla-rating-modal2.js +2 -2
- package/dist/components/salla-review-card2.js +1 -1
- package/dist/components/salla-review-factors-tags2.js +1 -1
- package/dist/components/salla-reviews-page.js +1 -1
- package/dist/components/salla-search-product-card2.js +2 -2
- package/dist/components/salla-searchable-dropdown2.js +4 -4
- package/dist/components/salla-skeleton2.js +1 -1
- package/dist/components/salla-social-share2.js +4 -4
- package/dist/components/salla-social.js +1 -1
- package/dist/components/salla-tab-content2.js +1 -1
- package/dist/components/salla-tab-header2.js +1 -1
- package/dist/components/salla-tabs2.js +1 -1
- package/dist/components/salla-tel-input2.js +1 -1
- package/dist/components/salla-thank-you-header.js +1 -1
- package/dist/components/salla-thank-you-page.js +1 -1
- package/dist/components/salla-tooltip2.js +1 -1
- package/dist/components/salla-user-settings.js +1 -1
- package/dist/components/salla-verify.js +1 -321
- package/dist/components/salla-verify2.js +328 -0
- package/dist/components/salla-wishlist-actions.js +1 -1
- package/dist/docs.json +158 -2
- package/dist/esm/{Helper-I0CAizv1.js → Helper-BKruFMBN.js} +1 -1
- package/dist/esm/delivery-promise-intent-C6pZjRut.js +67 -0
- package/dist/esm/{filepond-DTUYXV0J.js → filepond-Vl6a--vT.js} +1 -1
- package/dist/esm/{filepond-plugin-file-poster-DydZjneT.js → filepond-plugin-file-poster-CrQqmzd5.js} +1 -1
- package/dist/esm/{filepond-plugin-file-validate-size-nbsCU2t9.js → filepond-plugin-file-validate-size-BrHjddJa.js} +1 -1
- package/dist/esm/{filepond-plugin-file-validate-type-Cl5B_DIy.js → filepond-plugin-file-validate-type-BeMZq9Fl.js} +1 -1
- package/dist/esm/{filepond-plugin-image-edit-bzskFyFR.js → filepond-plugin-image-edit-DW6JzY39.js} +1 -1
- package/dist/esm/{filepond-plugin-image-exif-orientation-MBDuxLaX.js → filepond-plugin-image-exif-orientation-gzIIB75B.js} +1 -1
- package/dist/esm/{filepond-plugin-image-preview-N6wzEryW.js → filepond-plugin-image-preview-BwbtnJIU.js} +1 -1
- package/dist/esm/{helpers-Cnh7Qptl.js → helpers-BVaKfTMx.js} +24 -1
- package/dist/esm/{index-C9zdeQFI.js → index-CrXKQnBu.js} +14 -10
- package/dist/esm/{intlTelInput-B5L9nYtO.js → intlTelInput-BkjSbnO6.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 +2 -2
- package/dist/esm/salla-add-product-button_5.entry.js +120 -6
- 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-applied-filters.entry.js +2 -2
- package/dist/esm/salla-apps-icons.entry.js +1 -1
- package/dist/esm/salla-attachment-view_9.entry.js +13 -13
- package/dist/esm/salla-badge.entry.js +1 -1
- package/dist/esm/salla-basket-gap.entry.js +1 -1
- package/dist/esm/salla-bullet-delivery_3.entry.js +12 -17
- 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-cart-summary-card.entry.js +1 -1
- package/dist/esm/salla-cashback-banner.entry.js +1 -1
- package/dist/esm/salla-comment-factors.entry.js +1 -1
- package/dist/esm/salla-comment-form_9.entry.js +4 -4
- 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 +3 -63
- package/dist/esm/salla-edit-order-button.entry.js +1 -1
- package/dist/esm/salla-filters-widget.entry.js +2 -2
- package/dist/esm/salla-filters.entry.js +2 -2
- package/dist/esm/salla-free-shipping-banner.entry.js +1 -1
- package/dist/esm/salla-free-shipping-tag.entry.js +1 -1
- package/dist/esm/salla-fulfillment-methods.entry.js +1 -1
- package/dist/esm/salla-gift-card-redeem_2.entry.js +2 -2
- package/dist/esm/salla-gifting.entry.js +1 -1
- package/dist/esm/salla-hook.entry.js +1 -1
- package/dist/esm/salla-infinite-scroll.entry.js +2 -2
- 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_10.entry.js +1 -1
- package/dist/esm/salla-loyalty-exchange-product-card.entry.js +1 -1
- package/dist/esm/salla-loyalty-points-banner.entry.js +1 -1
- package/dist/esm/salla-loyalty-points-history.entry.js +1 -1
- package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
- package/dist/esm/salla-loyalty.entry.js +1 -1
- package/dist/esm/salla-maintenance-alert.entry.js +1 -1
- package/dist/esm/salla-map_3.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-mobile-update-modal.entry.js +186 -0
- package/dist/esm/salla-multiple-bundle-product-cart_2.entry.js +4 -4
- package/dist/esm/salla-multiple-bundle-product-options-modal_2.entry.js +6 -6
- package/dist/esm/salla-multiple-bundle-product.entry.js +2 -2
- package/dist/esm/salla-next-order-coupon.entry.js +1 -1
- package/dist/esm/salla-notification-item_2.entry.js +3 -3
- package/dist/esm/salla-offer-modal.entry.js +2 -2
- package/dist/esm/salla-offer.entry.js +1 -1
- package/dist/esm/salla-order-branch.entry.js +1 -1
- package/dist/esm/salla-order-cancel.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 +2 -2
- package/dist/esm/salla-order-edit-item.entry.js +1 -1
- package/dist/esm/salla-order-edit-product-card.entry.js +2 -2
- package/dist/esm/salla-order-edit.entry.js +1 -1
- package/dist/esm/salla-order-items.entry.js +2 -2
- package/dist/esm/salla-order-options-modal.entry.js +1 -1
- package/dist/esm/salla-order-payment.entry.js +2 -2
- package/dist/esm/salla-order-rewards.entry.js +2 -2
- package/dist/esm/salla-order-shipments.entry.js +1 -1
- package/dist/esm/salla-order-summary.entry.js +2 -2
- package/dist/esm/salla-order-totals-card.entry.js +1 -1
- package/dist/esm/salla-orders.entry.js +2 -2
- package/dist/esm/salla-payments.entry.js +3 -3
- package/dist/esm/salla-placeholder.entry.js +2 -2
- package/dist/esm/salla-price-range.entry.js +1 -1
- package/dist/esm/salla-product-card-embed.entry.js +2 -2
- package/dist/esm/salla-product-card.entry.js +1 -1
- package/dist/esm/salla-product-size-guide.entry.js +3 -3
- package/dist/esm/salla-products-list.entry.js +2 -2
- package/dist/esm/salla-products-slider.entry.js +2 -2
- package/dist/esm/salla-quick-order.entry.js +1 -1
- package/dist/esm/salla-rating-modal-v2.entry.js +33 -7
- package/dist/esm/salla-rating-modal.entry.js +2 -2
- package/dist/esm/salla-review-factors-tags.entry.js +2 -2
- package/dist/esm/salla-review-order-item.entry.js +1 -1
- package/dist/esm/salla-scopes.entry.js +1 -1
- package/dist/esm/salla-search-product-card.entry.js +3 -3
- package/dist/esm/salla-search.entry.js +2 -2
- package/dist/esm/salla-skeleton.entry.js +2 -2
- package/dist/esm/salla-social-share.entry.js +2 -2
- package/dist/esm/salla-social.entry.js +2 -2
- package/dist/esm/salla-tab-content_3.entry.js +4 -4
- package/dist/esm/salla-thank-you-header.entry.js +2 -2
- package/dist/esm/salla-thank-you-page.entry.js +2 -2
- package/dist/esm/salla-tiered-offer.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 +2 -2
- package/dist/esm/salla-verify.entry.js +3 -3
- package/dist/esm/salla-wallet.entry.js +1 -1
- package/dist/esm/salla-wishlist-actions.entry.js +2 -2
- package/dist/esm/salla-wishlist-summary.entry.js +2 -2
- package/dist/esm/twilight.js +3 -3
- package/dist/esm/{vanilla-picker-CAeu4f87.js → vanilla-picker-eSagUASw.js} +1 -1
- package/dist/twilight/p-0050dd2a.entry.js +4 -0
- package/dist/twilight/{p-c92cc92f.entry.js → p-012ff05c.entry.js} +1 -1
- package/dist/twilight/{p-8948b58c.entry.js → p-02ce2139.entry.js} +1 -1
- package/dist/twilight/{p-3cc6ca6c.entry.js → p-059aa8a9.entry.js} +1 -1
- package/dist/twilight/{p-995b898f.entry.js → p-09798a10.entry.js} +1 -1
- package/dist/twilight/p-0af7555c.entry.js +4 -0
- package/dist/twilight/{p-bbb09d92.entry.js → p-11075f15.entry.js} +1 -1
- package/dist/twilight/{p-e20d5e75.entry.js → p-12b2b553.entry.js} +1 -1
- package/dist/twilight/{p-619c709c.entry.js → p-14fb124b.entry.js} +1 -1
- package/dist/twilight/{p-e921b2d1.entry.js → p-1ca3525d.entry.js} +1 -1
- package/dist/twilight/{p-30d64bd1.entry.js → p-1f54638c.entry.js} +1 -1
- package/dist/twilight/{p-2b930157.entry.js → p-201c816d.entry.js} +1 -1
- package/dist/twilight/{p-d0f903ac.entry.js → p-203b2723.entry.js} +1 -1
- package/dist/twilight/{p-c4274188.entry.js → p-224c35e6.entry.js} +1 -1
- package/dist/twilight/{p-386b3dcd.entry.js → p-22bd8281.entry.js} +1 -1
- package/dist/twilight/{p-4070f808.entry.js → p-25ac8744.entry.js} +1 -1
- package/dist/twilight/{p-ec356e5a.entry.js → p-25b964c0.entry.js} +1 -1
- package/dist/twilight/{p-7fa4d0b6.entry.js → p-2a469c80.entry.js} +1 -1
- package/dist/twilight/{p-d57b49ff.entry.js → p-2a6f93a8.entry.js} +1 -1
- package/dist/twilight/{p-2e4e15c5.entry.js → p-2b0f98fc.entry.js} +1 -1
- package/dist/twilight/{p-8712f7c7.entry.js → p-2e66576c.entry.js} +1 -1
- package/dist/twilight/{p-45e0a5d0.entry.js → p-2e8e7cf2.entry.js} +1 -1
- package/dist/twilight/{p-faf00404.entry.js → p-2f05393f.entry.js} +1 -1
- package/dist/twilight/{p-a0bfedad.entry.js → p-3054e1c1.entry.js} +1 -1
- package/dist/twilight/{p-90a59027.entry.js → p-3295390b.entry.js} +1 -1
- package/dist/twilight/{p-a3959219.entry.js → p-33678067.entry.js} +1 -1
- package/dist/twilight/{p-4d615f9f.entry.js → p-33c05de2.entry.js} +1 -1
- package/dist/twilight/{p-036fbfc0.entry.js → p-381a9e70.entry.js} +1 -1
- package/dist/twilight/{p-982e9124.entry.js → p-38270121.entry.js} +1 -1
- package/dist/twilight/{p-7db6ccfe.entry.js → p-385bf37d.entry.js} +1 -1
- package/dist/twilight/{p-8c2992e7.entry.js → p-40ee2ca3.entry.js} +1 -1
- package/dist/twilight/{p-e455709f.entry.js → p-43a3401b.entry.js} +1 -1
- package/dist/twilight/{p-32f100f8.entry.js → p-4616033a.entry.js} +1 -1
- package/dist/twilight/p-484af8cc.entry.js +4 -0
- package/dist/twilight/{p-32495dd2.entry.js → p-4b6627f5.entry.js} +1 -1
- package/dist/twilight/p-4ed8ae08.entry.js +4 -0
- package/dist/twilight/{p-8eb3fd92.entry.js → p-4fb442c2.entry.js} +1 -1
- package/dist/twilight/{p-8262e669.entry.js → p-516f9b83.entry.js} +1 -1
- package/dist/twilight/{p-99cb3dba.entry.js → p-56aebb36.entry.js} +1 -1
- package/dist/twilight/{p-1867f7d4.entry.js → p-56fbe5ff.entry.js} +1 -1
- package/dist/twilight/{p-5aee5e44.entry.js → p-58af47e4.entry.js} +1 -1
- package/dist/twilight/{p-575014c4.entry.js → p-616e6781.entry.js} +1 -1
- package/dist/twilight/{p-e223beca.entry.js → p-62077080.entry.js} +1 -1
- package/dist/twilight/p-6427664a.entry.js +4 -0
- package/dist/twilight/{p-0b0d4942.entry.js → p-65253725.entry.js} +1 -1
- package/dist/twilight/{p-d0acd7ff.entry.js → p-6a05f69c.entry.js} +1 -1
- package/dist/twilight/{p-cb54adac.entry.js → p-6afa5aa8.entry.js} +1 -1
- package/dist/twilight/{p-3b766a79.entry.js → p-6ff116eb.entry.js} +1 -1
- package/dist/twilight/{p-9e429047.entry.js → p-710b19d2.entry.js} +1 -1
- package/dist/twilight/{p-e3991836.entry.js → p-71297800.entry.js} +1 -1
- package/dist/twilight/{p-0add41ce.entry.js → p-7234a066.entry.js} +1 -1
- package/dist/twilight/{p-777d28f6.entry.js → p-73af6a02.entry.js} +1 -1
- package/dist/twilight/{p-20f9c62f.entry.js → p-7428deca.entry.js} +1 -1
- package/dist/twilight/{p-703b9253.entry.js → p-75b509cd.entry.js} +1 -1
- package/dist/twilight/{p-9a0218a6.entry.js → p-79e446b2.entry.js} +1 -1
- package/dist/twilight/{p-550ad1a6.entry.js → p-7a8c9411.entry.js} +1 -1
- package/dist/twilight/{p-427c13b6.entry.js → p-86533832.entry.js} +1 -1
- package/dist/twilight/p-8a4af12c.entry.js +4 -0
- package/dist/twilight/{p-3bb0e184.entry.js → p-8ddf6933.entry.js} +1 -1
- package/dist/twilight/{p-fa622715.entry.js → p-93fe31b9.entry.js} +1 -1
- package/dist/twilight/{p-9d1a5007.entry.js → p-9c96a9e7.entry.js} +1 -1
- package/dist/twilight/{p-RflSBQNB.js → p-BNr49RmW.js} +1 -1
- package/dist/twilight/{p-JGEddAgs.js → p-BUzdlb7Q.js} +1 -1
- package/dist/twilight/{p-Cnh7Qptl.js → p-BVaKfTMx.js} +1 -1
- package/dist/twilight/{p-CmYSalnM.js → p-BYWjrTuB.js} +1 -1
- package/dist/twilight/{p-CSGj1pY-.js → p-Bo_J3Do4.js} +1 -1
- package/dist/twilight/{p-Cfz9xit3.js → p-ChxhrML8.js} +1 -1
- package/dist/twilight/{p-C9zdeQFI.js → p-CrXKQnBu.js} +2 -2
- package/dist/twilight/{p-Bgu5gtOF.js → p-D1oKTNWQ.js} +1 -1
- package/dist/twilight/{p-Dav_R_d2.js → p-DUNRPrqt.js} +1 -1
- package/dist/twilight/{p-BcT9tEVW.js → p-DUuRpwsl.js} +1 -1
- package/dist/twilight/{p-Xgbueas7.js → p-DZR3BP63.js} +1 -1
- package/dist/twilight/{p-6f84c662.entry.js → p-a52a3664.entry.js} +1 -1
- package/dist/twilight/p-a7114995.entry.js +4 -0
- package/dist/twilight/{p-e37da59f.entry.js → p-aa7494cd.entry.js} +1 -1
- package/dist/twilight/{p-eeefc285.entry.js → p-ae5d26da.entry.js} +1 -1
- package/dist/twilight/{p-17bcbf9b.entry.js → p-b5434bcc.entry.js} +1 -1
- package/dist/twilight/p-b9fabd92.entry.js +4 -0
- package/dist/twilight/{p-01d5cd61.entry.js → p-bac38ed2.entry.js} +1 -1
- package/dist/twilight/{p-6d572fe0.entry.js → p-bbcfcdb0.entry.js} +1 -1
- package/dist/twilight/{p-a22d9931.entry.js → p-c097cfa1.entry.js} +1 -1
- package/dist/twilight/p-c13e7efb.entry.js +4 -0
- package/dist/twilight/{p-c5e2c781.entry.js → p-d0ea4c3a.entry.js} +1 -1
- package/dist/twilight/{p-74285af9.entry.js → p-d0ec7ca7.entry.js} +1 -1
- package/dist/twilight/{p-4d7fc363.entry.js → p-d31fbdea.entry.js} +1 -1
- package/dist/twilight/{p-9683535f.entry.js → p-d482d43e.entry.js} +1 -1
- package/dist/twilight/{p-0213fde4.entry.js → p-d5368882.entry.js} +1 -1
- package/dist/twilight/{p-b5e0065a.entry.js → p-d5a2a231.entry.js} +1 -1
- package/dist/twilight/{p-a55b5c44.entry.js → p-d6705759.entry.js} +1 -1
- package/dist/twilight/p-d7f2a028.entry.js +4 -0
- package/dist/twilight/{p-7db8d545.entry.js → p-d84dedaf.entry.js} +1 -1
- package/dist/twilight/{p-f6279a13.entry.js → p-d8d9ff09.entry.js} +1 -1
- package/dist/twilight/{p-3b7a45ec.entry.js → p-d902ad13.entry.js} +1 -1
- package/dist/twilight/{p-ade9a68c.entry.js → p-d941dc58.entry.js} +1 -1
- package/dist/twilight/{p-db3efb27.entry.js → p-dd046bbd.entry.js} +1 -1
- package/dist/twilight/{p-a5fc8358.entry.js → p-dd21db09.entry.js} +1 -1
- package/dist/twilight/{p-aabcd09f.entry.js → p-dd83b424.entry.js} +1 -1
- package/dist/twilight/{p-8b8cf457.entry.js → p-e04fb844.entry.js} +1 -1
- package/dist/twilight/{p-290ce0bc.entry.js → p-e60d784c.entry.js} +1 -1
- package/dist/twilight/{p-ad00021e.entry.js → p-e6cc7742.entry.js} +1 -1
- package/dist/twilight/{p-252748d9.entry.js → p-e853ac07.entry.js} +1 -1
- package/dist/twilight/{p-db73d0bf.entry.js → p-e9ecae21.entry.js} +1 -1
- package/dist/twilight/{p-f3b12754.entry.js → p-ebe3d316.entry.js} +1 -1
- package/dist/twilight/{p-ce1e45a3.entry.js → p-ec2a45fb.entry.js} +1 -1
- package/dist/twilight/{p-73dea22d.entry.js → p-ef216c0a.entry.js} +1 -1
- package/dist/twilight/{p-825c5b73.entry.js → p-f3306980.entry.js} +1 -1
- package/dist/twilight/{p-50853b76.entry.js → p-f65205d5.entry.js} +1 -1
- package/dist/twilight/{p-32d9da31.entry.js → p-f6e5cd28.entry.js} +1 -1
- package/dist/twilight/{p-412fb721.entry.js → p-f8cfc9f7.entry.js} +1 -1
- package/dist/twilight/{p-c2df20f8.entry.js → p-faa0b9aa.entry.js} +1 -1
- package/dist/twilight/{p-5009f654.entry.js → p-fb10df18.entry.js} +1 -1
- package/dist/twilight/{p-c64b2b22.entry.js → p-fcb1cff7.entry.js} +1 -1
- package/dist/twilight/{p-f83efc62.entry.js → p-ff3cb99b.entry.js} +1 -1
- package/dist/twilight/{p-194ff38c.entry.js → p-ff4680ea.entry.js} +1 -1
- package/dist/twilight/p-oL7bxwey.js +9 -0
- package/dist/twilight/p-q5NJ0uS-.js +4 -0
- package/dist/twilight/twilight.esm.js +1 -1
- package/dist/types/components/salla-bullet-delivery/helpers.d.ts +7 -0
- package/dist/types/components/salla-bullet-delivery/interfaces.d.ts +4 -0
- package/dist/types/components/salla-bullet-delivery/salla-bullet-delivery.d.ts +0 -2
- package/dist/types/components/salla-mobile-update-modal/salla-mobile-update-modal.d.ts +44 -0
- package/dist/types/components/salla-quick-buy/salla-quick-buy.d.ts +12 -0
- package/dist/types/components/salla-rating-modal/salla-rating-modal-v2.d.ts +4 -0
- package/dist/types/components/salla-verify/salla-verify.d.ts +8 -0
- package/dist/types/components.d.ts +50 -0
- package/package.json +5 -5
- package/dist/twilight/p-2e6537a3.entry.js +0 -4
- package/dist/twilight/p-3a4e86d1.entry.js +0 -4
- package/dist/twilight/p-86d55a6b.entry.js +0 -4
- package/dist/twilight/p-8c548259.entry.js +0 -4
- package/dist/twilight/p-908716fb.entry.js +0 -4
- package/dist/twilight/p-9cf31ff4.entry.js +0 -4
- package/dist/twilight/p-9e542951.entry.js +0 -4
- package/dist/twilight/p-CWWgpQ8Q.js +0 -9
- package/dist/twilight/p-a070cce0.entry.js +0 -4
- package/dist/twilight/p-a3ca61af.entry.js +0 -4
|
@@ -5,7 +5,9 @@ import { Host, h } from "@stencil/core";
|
|
|
5
5
|
import "@salla.sa/applepay/src/index";
|
|
6
6
|
import { resolveApplePayOrderOptions, appendOrderOptionsToPayload, reportProductOptionsValiditySync, } from "../salla-order-options-modal/apple-pay-order-options";
|
|
7
7
|
import { injectFreeProductsIntoPayload } from "../salla-order-options-modal/free-product-payload";
|
|
8
|
-
import { applePayMerchantId, canCompleteApplePay, ensureApplePaySdk, isApplePayHostedRedirect, resolveApplePayNetworks } from "@salla.sa/applepay/src/apple-pay-support";
|
|
8
|
+
import { applePayMerchantId, canCompleteApplePay, ensureApplePaySdk, isApplePayHostedRedirect, normalizeApplePayNetworks, resolveApplePayNetworks } from "@salla.sa/applepay/src/apple-pay-support";
|
|
9
|
+
import { getStoredIntent } from "../salla-delivery-promise/delivery-promise-intent";
|
|
10
|
+
import { isIntentAddressComplete } from "../salla-bullet-delivery/helpers";
|
|
9
11
|
export class SallaQuickBuy {
|
|
10
12
|
constructor() {
|
|
11
13
|
this.hasInitialised = false;
|
|
@@ -224,6 +226,7 @@ export class SallaQuickBuy {
|
|
|
224
226
|
amount: this.applePayAmount > 0 ? this.applePayAmount : this.amount,
|
|
225
227
|
currency: this.currency || salla.config.get('store.settings.buy_now.currency') || 'SAR', // SAR
|
|
226
228
|
requiredShippingContactFields: this.getRequiredShippingContactFields(),
|
|
229
|
+
savedAddress: this.getSavedAddressForApplePay(),
|
|
227
230
|
shippingMethods: this.isRequireShipping ? [] : undefined,
|
|
228
231
|
supportedNetworks: this.resolveSupportedNetworks(),
|
|
229
232
|
supportedCountries: (Array.isArray(this.supportedCountries) && this.supportedCountries.length)
|
|
@@ -377,6 +380,28 @@ export class SallaQuickBuy {
|
|
|
377
380
|
}
|
|
378
381
|
return fields;
|
|
379
382
|
}
|
|
383
|
+
/**
|
|
384
|
+
* The saved address the shopper confirmed in Bullet Delivery, for the checkout to use directly
|
|
385
|
+
* instead of the address Apple Pay would ask for (SHPD-11082). Undefined keeps the default
|
|
386
|
+
* Apple Pay address flow: no Bullet Delivery, no confirmed saved address, or a guest.
|
|
387
|
+
*/
|
|
388
|
+
getSavedAddressForApplePay() {
|
|
389
|
+
// The mini-checkout already has the shopper's address and carrier on the cart, so it keeps
|
|
390
|
+
// Apple Pay's default flow; only the product's own Quick Buy uses the Bullet Delivery address.
|
|
391
|
+
if (!this.isRequireShipping || salla.config.isGuest() || this.resolveCheckoutType() !== 'buy_now')
|
|
392
|
+
return undefined;
|
|
393
|
+
const intent = getStoredIntent();
|
|
394
|
+
if (intent?.type !== 'address' || intent.scope_allocated !== true || !intent.address_id)
|
|
395
|
+
return undefined;
|
|
396
|
+
// A country/city-only address would place the order without a street or district and skip
|
|
397
|
+
// Apple's own address step; keep the default Apple Pay address flow for it.
|
|
398
|
+
if (!isIntentAddressComplete(intent))
|
|
399
|
+
return undefined;
|
|
400
|
+
return {
|
|
401
|
+
address_id: intent.address_id,
|
|
402
|
+
shippingMethods: { url: salla.url.get('checkout/{id}/shipping') },
|
|
403
|
+
};
|
|
404
|
+
}
|
|
380
405
|
/** Set Apple Pay amount + currency from a price payload, always keeping the pair in one currency. */
|
|
381
406
|
applyBaseCurrencyPrice(data) {
|
|
382
407
|
const base = data?.base_currency_price;
|
|
@@ -392,6 +417,27 @@ export class SallaQuickBuy {
|
|
|
392
417
|
this.amount = data.price;
|
|
393
418
|
this.currency = salla.config.get('user.currency_code') || this.currency || 'SAR';
|
|
394
419
|
}
|
|
420
|
+
this.applyApplePayProperties(data?.apple_pay);
|
|
421
|
+
}
|
|
422
|
+
/**
|
|
423
|
+
* Networks/countries travel with price responses so the next sheet matches the new total
|
|
424
|
+
* (the low-amount network rules depend on it; the page config is a cached render snapshot).
|
|
425
|
+
* A payload without the key (product details, older backend) leaves the current source as-is.
|
|
426
|
+
*/
|
|
427
|
+
applyApplePayProperties(applePay) {
|
|
428
|
+
if (!applePay)
|
|
429
|
+
return;
|
|
430
|
+
if (applePay.supported_networks != null) {
|
|
431
|
+
this.supportedNetworks = normalizeApplePayNetworks(applePay.supported_networks);
|
|
432
|
+
}
|
|
433
|
+
if (applePay.supported_countries != null) {
|
|
434
|
+
this.supportedCountries = normalizeApplePayNetworks(applePay.supported_countries);
|
|
435
|
+
}
|
|
436
|
+
// Crossing the high-risk amount threshold can empty the list; never open a sheet with
|
|
437
|
+
// nothing to charge — fall back to the generic buy-now instead.
|
|
438
|
+
if (this.isApplePayActive && !this.resolveSupportedNetworks().length) {
|
|
439
|
+
this.isApplePayActive = false;
|
|
440
|
+
}
|
|
395
441
|
}
|
|
396
442
|
componentWillLoad() {
|
|
397
443
|
console.log('🍏 Pay: Quick Buy Component Loaded');
|
|
@@ -656,6 +656,34 @@ export class SallaRatingModalV2 {
|
|
|
656
656
|
}
|
|
657
657
|
return [];
|
|
658
658
|
}
|
|
659
|
+
getRateStarsMessage(type, container) {
|
|
660
|
+
const itemName = this.getValidationItemName(type, container);
|
|
661
|
+
const message = salla.lang.get(`pages.rating.rate_${type}_stars`, { item: itemName });
|
|
662
|
+
// Drop a leftover ":item" placeholder (and its parentheses) when no name is available.
|
|
663
|
+
return message.replace(/\s*\(:item\)/g, '').replace(/\s*:item/g, '').trim();
|
|
664
|
+
}
|
|
665
|
+
getValidationItemName(type, container) {
|
|
666
|
+
if (type === 'product') {
|
|
667
|
+
const productId = container.querySelector('[name="product_id"]')
|
|
668
|
+
?.value;
|
|
669
|
+
const product = this.getOrderProducts().find(item => String(item.product?.id) === String(productId))?.product;
|
|
670
|
+
return product?.name ?? '';
|
|
671
|
+
}
|
|
672
|
+
return '';
|
|
673
|
+
}
|
|
674
|
+
/** Clear a step's validation message as soon as a star rating is picked. */
|
|
675
|
+
clearValidationOnRating(event) {
|
|
676
|
+
const target = event.target;
|
|
677
|
+
if (!target?.closest('salla-rating-stars')) {
|
|
678
|
+
return;
|
|
679
|
+
}
|
|
680
|
+
const form = target.closest('.rating-outer-form');
|
|
681
|
+
const message = form?.querySelector('.s-rating-modal-validation-msg');
|
|
682
|
+
const mainRow = form?.querySelector('.s-rating-modal-product-rating-row-main');
|
|
683
|
+
if (message && form && this.getRatingHiddenInput(mainRow || form)?.value) {
|
|
684
|
+
message.innerHTML = '';
|
|
685
|
+
}
|
|
686
|
+
}
|
|
659
687
|
validate(rating = null, type = null) {
|
|
660
688
|
if (!rating && this.currentTab?.dataset?.type === 'products') {
|
|
661
689
|
const ratingForms = this.currentTab.querySelectorAll('.rating-outer-form');
|
|
@@ -672,9 +700,7 @@ export class SallaRatingModalV2 {
|
|
|
672
700
|
const validationMessage = resolvedRating.querySelector('.s-rating-modal-validation-msg');
|
|
673
701
|
const resolvedType = type || resolvedRating.getAttribute('data-type');
|
|
674
702
|
if (!stars) {
|
|
675
|
-
validationMessage.innerHTML =
|
|
676
|
-
.get(`pages.rating.rate_${resolvedType}_stars`)
|
|
677
|
-
.replace(' (:item)', '');
|
|
703
|
+
validationMessage.innerHTML = this.getRateStarsMessage(resolvedType, resolvedRating);
|
|
678
704
|
throw new Error(validationMessage.innerHTML);
|
|
679
705
|
}
|
|
680
706
|
if (resolvedType === 'product') {
|
|
@@ -1329,8 +1355,8 @@ export class SallaRatingModalV2 {
|
|
|
1329
1355
|
h("div", { class: "s-rating-modal-wrapper", ref: el => {
|
|
1330
1356
|
if (el)
|
|
1331
1357
|
this.body = el;
|
|
1332
|
-
}
|
|
1333
|
-
this.getRateableProducts().map((item, index) => this.renderProductStep(item, index)), this.isShippingEnabled() && this.order.shipping?.company ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "shipping" }, h("input", { type: "hidden", name: "shipping_company_id", value: this.order.shipping.company.id }), this.order.shipping.company.logo ? (h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: this.order.shipping.company.logo, class: "s-rating-modal-shipping-logo", alt: this.order.shipping.company.name }))) : (h("span", { class: "s-rating-modal-icon", innerHTML: ShippingFast })), h("div", { class: "s-rating-modal-title" }, ' ', `${salla.lang.get('pages.rating.rate_shipping')} ${this.order.shipping.company.name}`), h("p", { class: "s-rating-modal-subtitle" }, salla.lang.get('pages.rating.write_shipping_rate')), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large" })), h("textarea", { name: "comment", class: "s-rating-modal-comment", placeholder: salla.lang.get('pages.rating.write_shipping_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : (''), h("div", { class: "s-rating-modal-thanks s-rating-modal-hidden", ref: el => {
|
|
1358
|
+
}, onClick: (event) => this.clearValidationOnRating(event) }, this.isProductsEnabled() &&
|
|
1359
|
+
this.getRateableProducts().map((item, index) => this.renderProductStep(item, index)), this.isTestimonialsEnabled() ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "store" }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, salla.config.get('store.name')), h("p", { class: "s-rating-modal-subtitle" }, salla.lang.get('pages.rating.rate_the_store')), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large" })), h("textarea", { name: "comment", class: "s-rating-modal-comment", placeholder: salla.lang.get('pages.rating.write_store_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : (''), this.isShippingEnabled() && this.order.shipping?.company ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "shipping" }, h("input", { type: "hidden", name: "shipping_company_id", value: this.order.shipping.company.id }), this.order.shipping.company.logo ? (h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: this.order.shipping.company.logo, class: "s-rating-modal-shipping-logo", alt: this.order.shipping.company.name }))) : (h("span", { class: "s-rating-modal-icon", innerHTML: ShippingFast })), h("div", { class: "s-rating-modal-title" }, ' ', `${salla.lang.get('pages.rating.rate_shipping')} ${this.order.shipping.company.name}`), h("p", { class: "s-rating-modal-subtitle" }, salla.lang.get('pages.rating.write_shipping_rate')), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large" })), h("textarea", { name: "comment", class: "s-rating-modal-comment", placeholder: salla.lang.get('pages.rating.write_shipping_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : (''), h("div", { class: "s-rating-modal-thanks s-rating-modal-hidden", ref: el => {
|
|
1334
1360
|
if (el)
|
|
1335
1361
|
this.thanksTab = el;
|
|
1336
1362
|
} }, h("span", { class: "s-rating-modal-icon", innerHTML: CheckCircle2 }), h("h3", { class: "s-rating-modal-thanks-title" }, salla.lang.get('pages.rating.thanks')), h("div", { class: "s-rating-modal-thanks-msg", innerHTML: this.order.thanks_message }), h("time", { class: "s-rating-modal-thanks-time", ref: el => {
|
|
@@ -162,7 +162,7 @@ export class SallaReviewCard {
|
|
|
162
162
|
return (h("a", { href: this.review?.product?.url, class: "s-review-card-product-container" }, h("img", { alt: product.image?.alt || "Product", src: product.image?.url, class: "s-review-card-product-image", width: 60, height: 60, loading: "lazy", decoding: "async", draggable: false }), h("div", { class: "s-review-card-product-details" }, h("p", { class: "s-review-card-product-details-name" }, product.name), this.showPurchaseCount ? h("p", { class: "s-review-card-product-details-purchase-count" }, h("span", { innerHTML: IconFire2 }), this.purchasedCount) : null)));
|
|
163
163
|
}
|
|
164
164
|
render() {
|
|
165
|
-
return h("div", { key: '
|
|
165
|
+
return h("div", { key: 'a2aeb09661c1764b925ef439162ff403b7e06a3c', class: "s-review-card-container" }, this.renderSlider(), this.renderSingleImage(), renderDivider(), h("div", { key: '7f926752e34f00aee7e113cbf3a5d62c0085dfb7', class: "s-review-card-content" }, this.renderHeader(), h("p", { key: 'e0d9dbe1ba13c32ddfc79d5bbc9b40d4de3882c6', class: "s-review-card-review-content", innerHTML: this.review?.content }), renderDivider(), this.renderProductInfo()));
|
|
166
166
|
}
|
|
167
167
|
static get is() { return "salla-review-card"; }
|
|
168
168
|
static get originalStyleUrls() {
|
|
@@ -47,7 +47,7 @@ export class SallaReviewFactorsTags {
|
|
|
47
47
|
return (h("div", { class: "s-review-factors-tags-factors" }, factors.map(factor => (h("div", { class: "s-review-factors-tags-factor-tag" }, h("span", { class: "s-review-factors-tags-factor-name" }, factor.name), h("span", { class: "s-review-factors-tags-factor-star", innerHTML: Star2 }), h("span", { class: "s-review-factors-tags-factor-rating" }, factor.rating || ''))))));
|
|
48
48
|
}
|
|
49
49
|
render() {
|
|
50
|
-
return (h(Host, { key: '
|
|
50
|
+
return (h(Host, { key: '2fc041ebd27df774250e428f3a68026838221309', class: "s-review-factors-tags-wrapper" }, this.renderFactorTags()));
|
|
51
51
|
}
|
|
52
52
|
static get is() { return "salla-review-factors-tags"; }
|
|
53
53
|
static get originalStyleUrls() {
|
|
@@ -142,7 +142,7 @@ export class SallaReviewsPage {
|
|
|
142
142
|
return options.map(option => (h("option", { key: option.value, value: option.value, selected: option.value === this.sort }, option.label)));
|
|
143
143
|
}
|
|
144
144
|
render() {
|
|
145
|
-
return (h("host", { key: '
|
|
145
|
+
return (h("host", { key: '35cd0a44554000d50366a0fc58e1459aee0b44b8' }, h("div", { key: '84221421edcb64eb6e354ec3db1153a479ad592a', class: "s-reviews-page-header-wrapper" }, h("h2", { key: 'd9d058476d006d09558037e8db5beb2216074f13', class: "s-reviews-page-title" }, this.langTitlesReviews, h("span", { key: '3a26542f8402200d33d8c44edaaa32f368879257', class: "s-reviews-page-count" }, "(", this.langRatingReviews, ")")), h("div", { key: 'c7e62f7e92a8b00ccd7301db6432510b5d7778ef', class: "s-reviews-page-filter-wrapper" }, h("label", { key: '07bcd2bd2e6b218e95296e3e863acf32fa2cca0a', class: "s-reviews-page-filter-label", htmlFor: "testimonials-filter" }, this.langSorting), h("select", { key: 'd6e78c62117a8ed22e76600d83deeccd777fb5d3', onChange: (e) => this.handleSorting(e), disabled: !this.reviews.length, class: "s-reviews-page-filter" }, this.renderSortingOptions()))), this.reviews.length ? h("main", { class: "s-reviews-page-grid", ref: el => {
|
|
146
146
|
this.wrapper = el;
|
|
147
147
|
} }, this.reviews.map(review => (h("salla-review-card", { key: review.id, review: review }))))
|
|
148
148
|
: h("div", { class: "s-products-list-placeholder" }, h("span", { innerHTML: ShoppingBag }), h("p", null, this.placeholderText)), this.pagination?.links?.next && this.reviews.length ? (h("div", { class: "s-reviews-page-load-more-container" }, h("salla-button", { class: "s-reviews-page-load-more-btn", loading: this.isLoading, onClick: () => this.infiniteScroll?.loadNextPage(), onKeyUp: () => this.infiniteScroll?.loadNextPage() }, this.langLoadMore))) : null));
|
|
@@ -109,7 +109,7 @@ export class SallaSearchProductCard {
|
|
|
109
109
|
// 's-search-product-card-out-of-stock': this.productData?.is_out_of_stock,
|
|
110
110
|
};
|
|
111
111
|
const hrefProp = this.productData?.url ? { href: this.productData.url } : {};
|
|
112
|
-
return (h(Host, { key: '
|
|
112
|
+
return (h(Host, { key: '6be103faead19fecfbc380ff4ee53f47f057dae0', id: `search-product-${this.productData?.id}`, class: classes }, this.productData?.url ? (h("a", { class: "s-search-product-card-overlay-link", "aria-label": this.productData?.name, ...hrefProp })) : null, h("div", { key: '1b2200c07aead0031e1b7cf4f4a0d0dbdb165d15', class: "s-search-product-card-image" }, h("img", { key: 'dca2fd85d56f311845397893bb64f50c1202ed2c', class: `s-search-product-card-image-${salla.url.is_placeholder(this.productData?.image?.url) ? 'contain' : 'cover'} lazy`, src: this.placeholder, alt: this.productData?.image?.alt || this.productData?.name, "data-src": this.productData?.image?.url || this.productData?.thumbnail }), this.getProductBadge()), h("div", { key: '6b04b97c6ead3c399acd3597c62fcf197a2a3b0d', class: "s-search-product-card-content" }, h("div", { key: '750a347824045b181736002aed50b586437065ed', class: "s-search-product-card-content-main" }, h("h3", { key: 'b0b85cd7d0314e6e5657d208ede0bdb2ab957d8a', class: "s-search-product-card-content-title" }, this.getDisplayTitle()), this.productData?.subtitle ? (h("p", { class: "s-search-product-card-content-subtitle" }, this.productData?.subtitle)) : null), !!this.showDonationAmount && !!this.productData?.donation
|
|
113
113
|
? [
|
|
114
114
|
h("salla-progress-bar", { donation: this.productData?.donation }),
|
|
115
115
|
h("div", { class: "s-search-product-card-donation-input" }, this.productData?.donation?.can_donate
|
|
@@ -124,7 +124,7 @@ export class SallaSearchProductCard {
|
|
|
124
124
|
]
|
|
125
125
|
: null),
|
|
126
126
|
]
|
|
127
|
-
: null, h("div", { key: '
|
|
127
|
+
: null, h("div", { key: 'f1507e9e9a42d099e46e12b214be70ed41bff404', class: "s-search-product-card-content-sub" }, this.getProductPrice(), this.productData?.is_out_of_stock ? (h("span", { class: "s-search-product-card-out-of-stock-label" }, this.outOfStock)) : null), this.productData?.rating?.stars ? (h("div", { class: "s-search-product-card-rating" }, h("span", { innerHTML: Star }), h("span", null, this.productData.rating.stars))) : null), !this.hideAddBtn ? (h("div", { class: "s-search-product-card-content-footer" }, h("salla-add-product-button", { ref: el => (this.addBtn = el), "product-id": this.productData.id, "product-status": this.productData.status, "product-type": this.productData.type, class: "s-add-product-button-compact" }, this.renderAddToCartLabel()))) : null));
|
|
128
128
|
}
|
|
129
129
|
componentDidLoad() {
|
|
130
130
|
document.lazyLoadInstance?.update(this.host?.querySelectorAll('.lazy'));
|
|
@@ -201,18 +201,18 @@ export class SallaSearchableDropdown {
|
|
|
201
201
|
render() {
|
|
202
202
|
const hasSelection = this.selectedItem != null;
|
|
203
203
|
const listboxId = `${this.inputId}-listbox`;
|
|
204
|
-
return (h(Host, { key: '
|
|
204
|
+
return (h(Host, { key: '02d11f844c06912b4743b820af6cee7c34b77f17', class: "s-searchable-dropdown" }, h("div", { key: 'e2fde5235f96206861dec5c94397a48061a2b59d', class: { 's-searchable-dropdown': true, 's-searchable-dropdown--open': this.isOpen } }, this.label && (h("label", { key: '22d43eb76b9d9b7e28be0a02e799e200499bb2d5', class: "s-searchable-dropdown-label", htmlFor: this.inputId }, this.label, this.required && h("span", { key: 'a139791c05d1b494776f538deafebbf41a2d4eee', class: "s-searchable-dropdown-required" }, " *"))), h("div", { key: '7361971a854f54206f30f61a13bce53c19b4dd54', class: {
|
|
205
205
|
's-searchable-dropdown-trigger': true,
|
|
206
206
|
's-searchable-dropdown-trigger--disabled': this.disabled || this.loading,
|
|
207
207
|
's-searchable-dropdown-trigger--open': this.isOpen,
|
|
208
|
-
}, role: "combobox", "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-controls": listboxId, "aria-disabled": this.disabled || this.loading ? 'true' : 'false', tabIndex: this.disabled || this.loading ? -1 : 0, onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown }, hasSelection ? (h("span", { class: "s-searchable-dropdown-trigger-text" }, this.getDisplayName(this.selectedItem))) : (h("span", { class: "s-searchable-dropdown-trigger-placeholder" }, this.placeholder)), h("i", { key: '
|
|
208
|
+
}, role: "combobox", "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-controls": listboxId, "aria-disabled": this.disabled || this.loading ? 'true' : 'false', tabIndex: this.disabled || this.loading ? -1 : 0, onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown }, hasSelection ? (h("span", { class: "s-searchable-dropdown-trigger-text" }, this.getDisplayName(this.selectedItem))) : (h("span", { class: "s-searchable-dropdown-trigger-placeholder" }, this.placeholder)), h("i", { key: '11a8d6d198eceaff33c83167db1672709da6a334', class: {
|
|
209
209
|
'sicon-keyboard_arrow_down': true,
|
|
210
210
|
's-searchable-dropdown-trigger-icon': true,
|
|
211
211
|
's-searchable-dropdown-trigger-icon--open': this.isOpen,
|
|
212
|
-
}, "aria-hidden": "true" })), this.isOpen && (h("div", { key: '
|
|
212
|
+
}, "aria-hidden": "true" })), this.isOpen && (h("div", { key: 'b1f95c4129297cb880edefdae7dd0ee55d0db89f', class: {
|
|
213
213
|
's-searchable-dropdown-panel': true,
|
|
214
214
|
's-searchable-dropdown-panel--up': this.dropUp,
|
|
215
|
-
}, ref: (el) => (this.panelRef = el) }, this.searchable && (h("div", { key: '
|
|
215
|
+
}, ref: (el) => (this.panelRef = el) }, this.searchable && (h("div", { key: '538366b1f478b758697a6163449f02a844046c24', class: "s-searchable-dropdown-search-wrap" }, h("i", { key: 'd4645a414866d20b37567b0edf7cc063c0783b0e', class: "sicon-search s-searchable-dropdown-search-icon", "aria-hidden": "true" }), h("input", { key: '9a1a0e9146fa1e5a2c391b75c82b8fe795207118', ref: (el) => (this.searchInputRef = el), id: this.inputId, type: "text", class: "s-searchable-dropdown-search-input", placeholder: this.placeholder, value: this.clientSearch ? this.clientSearchQuery : this.searchQuery, onInput: this.handleSearchInputChange, onKeyDown: this.handleSearchKeyDown, autocomplete: "off", "aria-autocomplete": "list", "aria-expanded": this.isOpen ? 'true' : 'false', "aria-controls": listboxId }))), h("div", { key: 'c233695fd26f7c743af2a330c149a02171e108da', id: listboxId, class: "s-searchable-dropdown-list s-scrollbar", role: "listbox" }, this.renderListContent()))))));
|
|
216
216
|
}
|
|
217
217
|
renderListContent() {
|
|
218
218
|
if (this.searching || this.loading) {
|
|
@@ -22,7 +22,7 @@ export class SallaSkeleton {
|
|
|
22
22
|
's-skeleton-item': true,
|
|
23
23
|
's-skeleton-item-circular': this.type == 'circle',
|
|
24
24
|
};
|
|
25
|
-
return (h(Host, { key: '
|
|
25
|
+
return (h(Host, { key: 'c73b16b10bad29384b81ac436a09b5d48712c2c3', class: "s-skeleton-wrapper", style: { width: this.width, height: this.height } }, h("div", { key: '890166817a5e0470d25c3114c87193ff7ad88b10', class: classes }, "\u00A0")));
|
|
26
26
|
}
|
|
27
27
|
static get is() { return "salla-skeleton"; }
|
|
28
28
|
static get originalStyleUrls() {
|
|
@@ -36,7 +36,7 @@ export class SallaSocial {
|
|
|
36
36
|
}
|
|
37
37
|
render() {
|
|
38
38
|
const linksArray = this.getLinksArray();
|
|
39
|
-
return (h(Host, { key: '
|
|
39
|
+
return (h(Host, { key: '29f04bfaf306c249ce6da993bad695b009e2c9e9' }, h("ul", { key: 'ed987f835308d337e3e58accccc159d97d822fe8', class: "s-social-list" }, linksArray.map((link) => (h("li", { class: "s-social-link" }, h("div", { id: "social-slot", innerHTML: this.socialSlot
|
|
40
40
|
.replace(/\{icon\}/g, this.iconsList[link.type])
|
|
41
41
|
.replace(/\{type\}/g, link.type)
|
|
42
42
|
.replace(/\{link\}/g, link.value.toString()) })))))));
|
|
@@ -382,7 +382,7 @@ export class SallaSocialShare {
|
|
|
382
382
|
})));
|
|
383
383
|
}
|
|
384
384
|
render() {
|
|
385
|
-
return (h("div", { key: '
|
|
385
|
+
return (h("div", { key: '6947ccab470304eb0d483fd4b7ca9cc2554bbb71', class: "s-social-share-wrapper" }, h("slot", { key: 'b286eaf408c6b424f2a6b54b8ca7556b8af7af8c', name: "widget" }, h("salla-button", { key: '45e580eb0c93990ece828470a0d3eb8bb76303db', "aria-label": "Share", onClick: () => this.handleShareClick(), class: "s-social-share-btn", shape: "icon", fill: "outline", color: "light" }, h("span", { key: '770d272c4132f0106e70f0ef765417ba4ac0b9f8', innerHTML: this.opened ? Cancel : ShareAlt }))), this.mode === 'modal' ? this.renderModal() : this.renderPopupList()));
|
|
386
386
|
}
|
|
387
387
|
static get is() { return "salla-social-share"; }
|
|
388
388
|
static get originalStyleUrls() {
|
|
@@ -36,7 +36,7 @@ export class SallaTabContent {
|
|
|
36
36
|
's-tabs-content': true,
|
|
37
37
|
's-tabs-content-selected': this.isSelected
|
|
38
38
|
};
|
|
39
|
-
return (h("div", { key: '
|
|
39
|
+
return (h("div", { key: 'e5da5a9d996bbb72e1603f88053d140138d08b38', class: classes }, h("slot", { key: '830ad13557951a06486f3d1155f7d2ec475fc243' })));
|
|
40
40
|
}
|
|
41
41
|
static get is() { return "salla-tab-content"; }
|
|
42
42
|
static get originalStyleUrls() {
|
|
@@ -52,7 +52,7 @@ export class SallaTabHeader {
|
|
|
52
52
|
's-tabs-active': this.isSelected,
|
|
53
53
|
};
|
|
54
54
|
return [
|
|
55
|
-
h("div", { key: '
|
|
55
|
+
h("div", { key: 'dbcd51f0c181991c1ea52ce4d2b8f364c4f77832', class: classes, onClick: this.onClick.bind(this) }, h("slot", { key: '382fc1cb4bece683fcbc67db46f51f5b0900e328' })),
|
|
56
56
|
];
|
|
57
57
|
}
|
|
58
58
|
static get is() { return "salla-tab-header"; }
|
|
@@ -59,7 +59,7 @@ export class SallaTabs {
|
|
|
59
59
|
render() {
|
|
60
60
|
const headerStyle = this.backgroundColor ? { 'background-color': this.backgroundColor } : {};
|
|
61
61
|
return [
|
|
62
|
-
h("div", { key: '
|
|
62
|
+
h("div", { key: 'e9e0030c417a98d19fdcf04ab290e6c77743fa68', class: "s-tabs" }, h("div", { key: 'b79d94a3744ba6d6b5c6e2948a2be057f9d5555c', class: "s-tabs-header", style: headerStyle }, h("slot", { key: '1136f96eeb12125185685a336be660eec5591daa', name: "header" })), h("div", { key: 'ac3ea577952031a2f366172ab27bc08c19f706f4', class: "s-tabs-content-wrapper" }, h("slot", { key: '48486dad9ae07f6a0dacab3c70c9c3df4eb66dcd', name: "content" })))
|
|
63
63
|
];
|
|
64
64
|
}
|
|
65
65
|
static get is() { return "salla-tabs"; }
|
|
@@ -143,7 +143,7 @@ export class SallaTelInput {
|
|
|
143
143
|
}
|
|
144
144
|
}
|
|
145
145
|
render() {
|
|
146
|
-
return (h(Host, { key: '
|
|
146
|
+
return (h(Host, { key: '1ac7260480017f583ad9a85e3184e91aed10c44f', class: "s-tel-input" }, h("input", { key: 'b67e55b6cc4154d4743dee20be5d9fb5b000e698', type: "tel", disabled: this.disabled, name: this.name, value: this.phone, onChange: (event) => this.handleCountryInput(event), ref: el => this.phoneInput = el, enterkeyhint: "next", autocomplete: "tel", class: "s-tel-input-control tel-input s-ltr" }), h("span", { key: '2533925768fe0265fbea2552540734d5cac0b9aa', class: "s-tel-input-error-msg", ref: el => this.errorMsg = el }), h("input", { key: '0bb28963824dbc6e12ececc76f9e756e1a0e150e', type: "hidden", name: "country_code", value: this.countryCode, ref: el => this.countryCodeInput = el, class: "country_code" })));
|
|
147
147
|
}
|
|
148
148
|
componentDidLoad() {
|
|
149
149
|
this.initPromise = this.initTelInput();
|
|
@@ -38,7 +38,7 @@ export class SallaThankYouHeader {
|
|
|
38
38
|
}
|
|
39
39
|
render() {
|
|
40
40
|
const date = this.dateLabel();
|
|
41
|
-
return h("header", { key: '
|
|
41
|
+
return h("header", { key: '059ca864ef1b2688f3919e0d1afe312a6a26304b', class: "s-thank-you-header-wrapper" }, h("div", { key: '7db61c7e59b0c648a863c8f273733a351d7ae7f6', class: "s-thank-you-header-intro" }, h("span", { key: 'fd6898fd919eb23123f0922504cd7fa27fd6d7cf', class: "s-thank-you-header-success" }, h("span", { key: 'f3e543dd2cdb8fd6ec766decf8733053f64a85b4', class: "s-thank-you-header-success-icon", "aria-hidden": "true", innerHTML: SuccessIcon }), h("span", { key: 'fe155c56cfa5b8c96f9ec0ab0212d0ecaa9b78e8', class: "s-thank-you-header-store" }, this.storeLogo ? h("img", { src: this.storeLogo, alt: this.storeName || '' }) : h("span", { "aria-hidden": "true", innerHTML: StoreIcon }))), h("div", { key: '98df6b364ae471bc6d293b2bc2ef550f93ab1ded', class: "s-thank-you-header-copy" }, h("h1", { key: 'e0150e20cf220cb60612745341e0a243f5155f6a', "data-testid": "store-thankyou-header-show-title", class: "s-thank-you-header-title" }, this.heading), h("p", { key: 'd4b592a4517434d7d21c24884bebc7a5d99128ab', class: "s-thank-you-header-subtitle" }, this.subtitle || salla.lang.get('pages.thank_you.order_received')))), h("hr", { key: '98dcc158ecd2af0c6081959299164e4a004255ca', class: "s-thank-you-header-divider" }), h("div", { key: '1b40af524a983485f718aab6f52a13da56c11f69', class: "s-thank-you-header-meta" }, this.referenceId ? h("button", { type: "button", class: "s-thank-you-header-reference", "data-testid": "store-thankyou-header-copy-reference", "aria-label": `${salla.lang.get('common.elements.copy')} ${this.referenceId}`, onClick: () => this.copyReference() }, h("span", { "aria-hidden": "true", innerHTML: OrderIcon }), h("span", { dir: "ltr" }, "#", this.referenceId), h("span", { "aria-hidden": "true", innerHTML: CopyIcon })) : null, date ? h("span", { class: "s-thank-you-header-date" }, h("span", { "aria-hidden": "true", innerHTML: TimeIcon }), h("time", { dateTime: this.createdAt }, date)) : null), h("slot", { key: '1ec96de5ef0c5c44dc80742277ad6b4ee83354da' }));
|
|
42
42
|
}
|
|
43
43
|
static get is() { return "salla-thank-you-header"; }
|
|
44
44
|
static get originalStyleUrls() {
|
|
@@ -9,7 +9,7 @@ import { h, Host } from "@stencil/core";
|
|
|
9
9
|
*/
|
|
10
10
|
export class SallaThankYouPage {
|
|
11
11
|
render() {
|
|
12
|
-
return h(Host, { key: '
|
|
12
|
+
return h(Host, { key: '605e01d9b7299b700f24339f20995bd83e8add0c', class: "s-thank-you-page-wrapper" }, h("slot", { key: 'e1c24571fe73dda85f4f8bd8f2aa206a40bf7aa2', name: "main" }), h("slot", { key: 'd198960d04ce37f98476d9538da54d377edb84ae' }));
|
|
13
13
|
}
|
|
14
14
|
static get is() { return "salla-thank-you-page"; }
|
|
15
15
|
static get originalStyleUrls() {
|
|
@@ -27,7 +27,7 @@ export class SallaTooltip {
|
|
|
27
27
|
}
|
|
28
28
|
render() {
|
|
29
29
|
const validTheme = ['default', 'dark'].includes(this.theme) ? this.theme : 'default';
|
|
30
|
-
return (h("div", { key: '
|
|
30
|
+
return (h("div", { key: 'e78c348a4fdc3eae7b719a8c8f1f115d521a1965', class: "s-tooltip-container" }, h("div", { key: 'dc2137a53c1f5b2075d8a96d13c16ad216ca9b37', class: `s-tooltip-item s-tooltip-item--${validTheme}`, style: { display: this.show ? 'block' : 'none' } }, this.text ? h("span", null, this.text) : h("slot", null))));
|
|
31
31
|
}
|
|
32
32
|
static get is() { return "salla-tooltip"; }
|
|
33
33
|
static get originalStyleUrls() {
|
|
@@ -559,7 +559,7 @@ export class SallaUserSettings {
|
|
|
559
559
|
return (h("salla-button", { fill: "outline", color: "danger", shape: "btn", size: "medium", width: "normal", onClick: () => this.openDeleteModal() }, this.capitalizeText(this.deleteAccount)));
|
|
560
560
|
}
|
|
561
561
|
render() {
|
|
562
|
-
return (h(Host, { key: '
|
|
562
|
+
return (h(Host, { key: 'a5329b99eb9ae0d351d3732a8bd73cb5a0e3bf0e', class: "s-user-settings-wrapper" }, this.canHideName && (h("div", { key: 'fa451ecdfcc4797eb5a844a6b6ba57456887bc65', class: "s-user-settings-section" }, h("salla-list-tile", { key: 'efe0e7fbf16ce4c23f9fefd7d96e77b86c17407d' }, h("div", { key: '6749a02ca8b2fe06bf604aa7e6343c2f6a933db9', slot: "icon", class: "s-user-settings-section-icon" }, h("span", { key: '3fac5e8f843a6d7a82355e742801701daa839b37', innerHTML: UserCancel })), h("div", { key: '9902df824f1c959e5e78448019bb0019139181e3', slot: "title", class: "s-user-settings-section-title" }, this.capitalizeText(this.hideMyName)), h("div", { key: 'a2d6b461b818fb5c88831fc3515c62fbb27a3604', slot: "subtitle", class: "s-user-settings-section-subtitle" }, this.capitalizeText(this.hideMyNameDesc)), h("div", { key: '14dfc10aeb8f3ae132bd6a884f6f0909b3ee0071', slot: "action", class: "s-user-settings-section-action" }, h("label", { key: 'd224bf45f7b946f37460478e49019d38fbe5f4f9', class: "s-toggle" }, h("input", { key: 'f6b97efb600c39f0e66eaac8538a7e076cba851e', class: "s-toggle-input", checked: this.isHiddenName, onChange: e => this.toggleSetting('is_hidden_name', e), type: "checkbox" }), h("div", { key: 'e6c00fa21b86e168a4a6c236cc20035ca3310c7e', class: "s-toggle-switcher" })))))), h("div", { key: '5452089f49aa35bdf5ee2f8cd39dbfc7bf5b83d3', class: "s-user-settings-section" }, h("salla-list-tile", { key: '95a23fe5cbb2e5481137bdad8a424430922110af' }, h("div", { key: 'ae6f7395a3beb1a46339acb225fbf8ae86086f1a', slot: "icon", class: "s-user-settings-section-icon" }, h("span", { key: '4f09f13877d1c9c405163bc7035196ce4e7ab574', innerHTML: Bullhorn })), h("div", { key: '77e038e9ede04ebceb33dc5732552bfb872ff07f', slot: "title", class: "s-user-settings-section-title" }, this.capitalizeText(this.promotionalMsgs)), h("div", { key: 'c1332d656e6c898b09d63b8985ab2b32f92029f1', slot: "subtitle", class: "s-user-settings-section-subtitle" }, this.capitalizeText(this.promotionalMsgsDesc)), h("div", { key: '236c6622e61210bdcad47582e4626fbf7a4f77d3', slot: "action", class: "s-user-settings-section-action" }, h("label", { key: 'be37b0ea5465911064146779025fd5e353a6f556', class: "s-toggle" }, h("input", { key: 'fea0f0478c959bc94f91bc302618eb2e30047927', class: "s-toggle-input", checked: this.isNotifiable, onChange: e => this.toggleSetting('is_notifiable', e), type: "checkbox" }), h("div", { key: '1420206f5679e67ce1fd908ae8e9179eaae1dc77', class: "s-toggle-switcher" }))))), this.isDeleteAccountEnabled ? (h("div", { class: "s-user-settings-section s-user-settings-section-delete-user" }, h("salla-list-tile", null, h("div", { slot: "icon", class: "s-user-settings-section-icon" }, this.renderUserDeleteIcon()), h("div", { slot: "title", class: "s-user-settings-section-title" }, this.capitalizeText(this.deleteAccount)), h("div", { slot: "subtitle", class: "s-user-settings-section-subtitle" }, this.capitalizeText(this.isDeletePending ? this.deleteAccountPending : this.deleteAccountDesc)), h("div", { slot: "action", class: "s-user-settings-section-action" }, this.renderDeleteSectionAction())))) : (h("div", { class: "s-user-settings-section s-user-settings-section-deactivate-user" }, h("salla-list-tile", null, h("div", { slot: "icon", class: "s-user-settings-section-icon" }, h("span", { innerHTML: UserOff })), h("div", { slot: "title", class: "s-user-settings-section-title" }, this.capitalizeText(this.deactivateAccount)), h("div", { slot: "subtitle", class: "s-user-settings-section-subtitle" }, this.capitalizeText(this.deactivateDesc)), h("div", { slot: "action", class: "s-user-settings-section-action" }, h("salla-button", { fill: "outline", color: "danger", shape: "btn", size: "medium", width: "normal", onClick: () => this.openDeactivateModal() }, this.capitalizeText(this.deactivateAccount)))))), this.isDeleteAccountEnabled ? (h("salla-modal", { id: "salla-user-settings-delete-modal", width: "xs", centered: true, showBack: this.currentStep === 'otp', isClosable: this.currentStep !== 'success', iconStyle: this.currentStep === 'success' ? 'success' : undefined, onModalVisibilityChanged: e => this.handleModalVisibilityChanged(e), onModalBack: () => this.goBackFromOtp(), ref: modal => (this.confirmationModal = modal) }, this.currentStep !== 'success' ? (h("span", { slot: "icon", class: "s-user-settings-delete-icon" }, this.renderUserDeleteIcon())) : null, h("div", { key: this.currentStep, class: "s-user-settings-delete-step" }, this.renderDeleteStep()))) : (h("salla-modal", { width: "sm", subTitle: this.capitalizeText(this.sorryForLeavingText), ref: modal => (this.confirmationModal = modal) }, h("span", { slot: "icon", class: "s-user-settings-confirmation-icon", innerHTML: UserOff }), h("div", { class: "s-user-settings-confirmation" }, h("div", { class: "s-user-settings-confirmation-warning" }, this.capitalizeText(this.warningText)), h("div", { class: "s-user-settings-confirmation-actions" }, h("salla-button", { width: "wide", onClick: () => this.confirmationModal.close() }, this.capitalizeText(this.keepAccount)), h("salla-button", { fill: "outline", loading: this.buttonLoading, width: "wide", onClick: () => this.confirmDeactivateAccount() }, this.capitalizeText(this.deactivateAccount))))))));
|
|
563
563
|
}
|
|
564
564
|
static get is() { return "salla-user-settings"; }
|
|
565
565
|
static get originalStyleUrls() {
|
|
@@ -229,7 +229,7 @@ export class SallaVerify {
|
|
|
229
229
|
this.otpInputs.forEach(input => input.value = '');
|
|
230
230
|
this.otpInputs[0].focus();
|
|
231
231
|
})
|
|
232
|
-
.then(() => salla.api.auth.resend(this.data))
|
|
232
|
+
.then(() => this.resendHandler ? this.resendHandler(this.data) : salla.api.auth.resend(this.data))
|
|
233
233
|
.finally(() => this.resendTimer());
|
|
234
234
|
}
|
|
235
235
|
submit() {
|
|
@@ -242,7 +242,7 @@ export class SallaVerify {
|
|
|
242
242
|
let data = { code: this.code.value, ...this.data };
|
|
243
243
|
return this.btn.load()
|
|
244
244
|
.then(() => this.btn.disable())
|
|
245
|
-
.then(() => this.isProfileVerify ? salla.profile.verify(data) : salla.auth.verify(data, this.supportWebAuth))
|
|
245
|
+
.then(() => this.verifyHandler ? this.verifyHandler(data) : this.isProfileVerify ? salla.profile.verify(data) : salla.auth.verify(data, this.supportWebAuth))
|
|
246
246
|
.then(response => this.verified.emit(response))
|
|
247
247
|
.then(() => this.btn.stop() && this.btn.disable())
|
|
248
248
|
.then(() => this.modal.close())
|
|
@@ -358,6 +358,52 @@ export class SallaVerify {
|
|
|
358
358
|
"setter": false,
|
|
359
359
|
"reflect": false,
|
|
360
360
|
"defaultValue": "true"
|
|
361
|
+
},
|
|
362
|
+
"verifyHandler": {
|
|
363
|
+
"type": "unknown",
|
|
364
|
+
"attribute": "verify-handler",
|
|
365
|
+
"mutable": false,
|
|
366
|
+
"complexType": {
|
|
367
|
+
"original": "(data: any) => Promise<any>",
|
|
368
|
+
"resolved": "(data: any) => Promise<any>",
|
|
369
|
+
"references": {
|
|
370
|
+
"Promise": {
|
|
371
|
+
"location": "global",
|
|
372
|
+
"id": "global::Promise"
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
},
|
|
376
|
+
"required": false,
|
|
377
|
+
"optional": true,
|
|
378
|
+
"docs": {
|
|
379
|
+
"tags": [],
|
|
380
|
+
"text": "Replaces the verify request, for flows with their own endpoint. Receives `{code, ...data}`"
|
|
381
|
+
},
|
|
382
|
+
"getter": false,
|
|
383
|
+
"setter": false
|
|
384
|
+
},
|
|
385
|
+
"resendHandler": {
|
|
386
|
+
"type": "unknown",
|
|
387
|
+
"attribute": "resend-handler",
|
|
388
|
+
"mutable": false,
|
|
389
|
+
"complexType": {
|
|
390
|
+
"original": "(data: any) => Promise<any>",
|
|
391
|
+
"resolved": "(data: any) => Promise<any>",
|
|
392
|
+
"references": {
|
|
393
|
+
"Promise": {
|
|
394
|
+
"location": "global",
|
|
395
|
+
"id": "global::Promise"
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
},
|
|
399
|
+
"required": false,
|
|
400
|
+
"optional": true,
|
|
401
|
+
"docs": {
|
|
402
|
+
"tags": [],
|
|
403
|
+
"text": "Replaces the resend request, for flows with their own endpoint. Receives the data passed to `open()`"
|
|
404
|
+
},
|
|
405
|
+
"getter": false,
|
|
406
|
+
"setter": false
|
|
361
407
|
}
|
|
362
408
|
};
|
|
363
409
|
}
|
|
@@ -325,7 +325,7 @@ export class SallaWishlistActions {
|
|
|
325
325
|
}
|
|
326
326
|
}
|
|
327
327
|
render() {
|
|
328
|
-
return (h(Host, { key: '
|
|
328
|
+
return (h(Host, { key: 'ed2bb2b4e6db13b5dc2a8ceb47d0abb4b91da7ea' }, h("div", { key: '9a368503611af6ccce78d35b76ec17bd3ddd296b', class: "s-wishlist-actions" }, h("div", { key: 'a9dc9b280bd46673892d6c72ffc535eb443beb0f', class: "s-wishlist-actions-bar flex items-center justify-end gap-3 mb-3" }, h("div", { key: '90d6ea21a46becdeffca1a9b722a3a20eb3ed341', class: "s-wishlist-actions-dropdown relative" }, h("salla-button", { key: '9edc9eeea5282fc61d48fce5b29ed095793265cf', color: "primary", fill: "outline", type: "button", disabled: !this.hasProducts, "aria-haspopup": "true", "aria-expanded": this.menuOpen ? 'true' : 'false', onClick: () => this.toggleMenu() }, h("div", { key: 'a5a30a3676d304614ec2e8b14172694d00f2e28c', class: "flex flex-row justify-center items-center gap-2" }, h("svg", { key: '6842723fa0aa1f12fba6b91ddc6095a1e8da20af', version: "1.1", xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 32 32", style: { width: '16px', height: '16px' } }, h("path", { key: 'c7aa82770d3ce0a04240ee4ab44b8a4f0cf2d8b3', d: "M26.667 21.333c-1.699 0-3.196 0.812-4.173 2.052l-11.912-5.211c0.044-0.276 0.085-0.553 0.085-0.841 0-0.472-0.081-0.923-0.197-1.359l12.361-6.952c0.971 1.009 2.328 1.644 3.836 1.644 2.941 0 5.333-2.392 5.333-5.333s-2.392-5.333-5.333-5.333-5.333 2.392-5.333 5.333c0 0.472 0.081 0.923 0.197 1.359l-12.361 6.952c-0.971-1.009-2.328-1.644-3.836-1.644-2.941 0-5.333 2.392-5.333 5.333s2.392 5.333 5.333 5.333c1.699 0 3.196-0.812 4.173-2.052l11.912 5.211c-0.044 0.276-0.085 0.553-0.085 0.841 0 2.941 2.392 5.333 5.333 5.333s5.333-2.392 5.333-5.333-2.392-5.333-5.333-5.333zM26.667 2.667c1.471 0 2.667 1.196 2.667 2.667s-1.196 2.667-2.667 2.667-2.667-1.196-2.667-2.667 1.196-2.667 2.667-2.667zM5.333 20c-1.471 0-2.667-1.196-2.667-2.667s1.196-2.667 2.667-2.667 2.667 1.196 2.667 2.667-1.196 2.667-2.667 2.667zM26.667 29.333c-1.471 0-2.667-1.196-2.667-2.667s1.196-2.667 2.667-2.667 2.667 1.196 2.667 2.667-1.196 2.667-2.667 2.667z" })), this.shareLabel, h("svg", { key: '08c44a8306ba2b183aa0549fac2da24c64f3b285', version: "1.1", xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 32 32", style: { width: '16px', height: '16px' } }, h("path", { key: '216163cc1b84ceb0b9035c23ef002b80c69ab9bf', d: "M26.212 10.996c-0.556-0.484-1.396-0.428-1.881 0.127l-8.331 9.519-8.331-9.52c-0.485-0.555-1.327-0.611-1.881-0.125s-0.609 1.328-0.124 1.881l9.333 10.667c0.253 0.291 0.617 0.456 1.003 0.456s0.749-0.165 1.003-0.456l9.333-10.667c0.485-0.553 0.429-1.396-0.124-1.881z" })))), this.menuOpen && (h("ul", { key: '57f73a8af50dc9280efde259d639bf3d41434fed', class: "s-wishlist-actions-menu absolute z-20 mt-1 bg-white rounded-lg shadow overflow-hidden" }, h("li", { key: 'd3b5fc449eef1b2af914dcae0dea0b67af599b84' }, h("button", { key: 'e3689eb4db62ff5ee42122819faa28500c555479', type: "button", class: "s-wishlist-actions-menu-item", onClick: () => this.shareAll() }, this.shareAllLabel)), h("li", { key: 'ad40221d90b2ca52ad9544e8d19324ef8af812c4' }, h("button", { key: '9fde093db8640855d4871972b02e3282e9aed6ad', type: "button", class: "s-wishlist-actions-menu-item", onClick: () => this.shareSpecific() }, this.shareSpecificLabel))))), h("salla-social-share", { key: '91287b112e76c9039170ebe54fcbfe7bfcb2dfb1', class: "s-wishlist-actions-social", ref: el => (this.socialShare = el), url: this.shareUrl, mode: "modal", modalTitle: this.shareModalTitle }, h("span", { key: 'e97a4249a046a17d65f214e5c2ecbca2ff21358c', slot: "widget", class: "s-wishlist-actions-social-anchor", "aria-hidden": "true" }))), this.specificMode && (h("div", { key: '50ba30cc24e590986b6031a373f9334e3d8c97a7', class: "s-wishlist-actions-panel flex items-center justify-between gap-4 flex-wrap p-4 mt-3 mb-3 bg-white rounded-lg" }, h("label", { key: '5dbb40eed9828355189d6242131dd07343d19603', class: "s-wishlist-actions-panel-select-all flex items-center gap-2 cursor-pointer" }, h("input", { key: '5bb2571ed6e9d074739fe130d3b3b3bbe77a2393', type: "checkbox", class: "s-products-list-select-checkbox s-wishlist-actions-select-all", checked: this.isAllSelected, ref: el => (this.selectAllCheckbox = el), "aria-label": this.selectAllLabel, onChange: () => this.toggleSelectAll() }), h("span", { key: '60853767d68f23affc964822e41f19fb93b2f380', class: "s-wishlist-actions-panel-title text-sm font-bold text-gray-700" }, this.shareSpecificLabel, " (", this.selectedCount, ")")), h("div", { key: '5d4cab056b372ff6c2d9de0dfa32e1f1870b536a', class: "s-wishlist-actions-panel-buttons flex items-center gap-2" }, h("salla-button", { key: '2ef6d0388714b348ce2e039662c704d0ea9c3afa', class: "s-wishlist-actions-cancel", color: "light", fill: "outline", type: "button", onClick: () => this.cancelSpecific() }, this.cancelLabel), h("salla-button", { key: '0077c263a4eea12fc0b2b1316d4195916d771417', class: "s-wishlist-actions-share", color: "primary", fill: "outline", type: "button", disabled: !this.selectedCount, loading: this.isSharing, onClick: () => this.shareSelected() }, this.shareLabel)))))));
|
|
329
329
|
}
|
|
330
330
|
static get is() { return "salla-wishlist-actions"; }
|
|
331
331
|
static get originalStyleUrls() {
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Crafted with ❤ by Salla
|
|
3
|
+
*/
|
|
4
|
+
import { q as isMapOriginIntent } from './helpers.js';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Bullet delivery intent helpers.
|
|
8
|
+
* Reads/writes the same storage key as salla-bullet-delivery so both components stay in sync.
|
|
9
|
+
*/
|
|
10
|
+
const INTENT_KEY = 'bullet_delivery_intent';
|
|
11
|
+
function getIntentStorage() {
|
|
12
|
+
const rememberLastSession = Boolean(salla.config.get('store.settings.bullet_delivery.settings.remember_last_session'));
|
|
13
|
+
return rememberLastSession ? salla.storage.store : salla.storage.session;
|
|
14
|
+
}
|
|
15
|
+
function getStoredIntent() {
|
|
16
|
+
const raw = getIntentStorage().get(INTENT_KEY);
|
|
17
|
+
return raw && typeof raw === 'object' ? raw : null;
|
|
18
|
+
}
|
|
19
|
+
/** Resolve the stored intent into a city or branch selection. Returns null when no usable intent. */
|
|
20
|
+
function resolveIntent() {
|
|
21
|
+
const intent = getStoredIntent();
|
|
22
|
+
if (!intent)
|
|
23
|
+
return null;
|
|
24
|
+
if (intent.type === 'address') {
|
|
25
|
+
const city = intent.address_details?.city;
|
|
26
|
+
const cityId = city?.id != null ? Number(city.id) : intent.city_id != null ? Number(intent.city_id) : null;
|
|
27
|
+
const cityName = city?.name?.trim() || '';
|
|
28
|
+
if (cityId != null) {
|
|
29
|
+
return { type: 'address', option: { id: cityId, name: cityName } };
|
|
30
|
+
}
|
|
31
|
+
// Map-origin pick: no city id to query a delivery estimate by, but still show the address.
|
|
32
|
+
if (isMapOriginIntent(intent) && intent.address_details?.formatted_address) {
|
|
33
|
+
return { type: 'address', option: { name: intent.address_details.formatted_address } };
|
|
34
|
+
}
|
|
35
|
+
return null;
|
|
36
|
+
}
|
|
37
|
+
if (intent.type === 'branch') {
|
|
38
|
+
const branchId = intent.branch_id != null
|
|
39
|
+
? Number(intent.branch_id)
|
|
40
|
+
: intent.branch_details?.id != null
|
|
41
|
+
? Number(intent.branch_details.id)
|
|
42
|
+
: null;
|
|
43
|
+
const branchName = intent.branch_details?.name?.trim() || '';
|
|
44
|
+
if (branchId != null) {
|
|
45
|
+
return { type: 'branch', option: { id: branchId, name: branchName } };
|
|
46
|
+
}
|
|
47
|
+
return null;
|
|
48
|
+
}
|
|
49
|
+
return null;
|
|
50
|
+
}
|
|
51
|
+
/** Build the payload for opening the bullet delivery modal with preselection. */
|
|
52
|
+
function buildBulletOpenPayload() {
|
|
53
|
+
const intent = getStoredIntent();
|
|
54
|
+
const payload = {};
|
|
55
|
+
if (intent?.type === 'address' && intent.address_id != null) {
|
|
56
|
+
payload.preselected_address_id = Number(intent.address_id);
|
|
57
|
+
}
|
|
58
|
+
if (intent?.type === 'branch') {
|
|
59
|
+
const branchId = intent.branch_id ?? intent.branch_details?.id;
|
|
60
|
+
if (branchId != null) {
|
|
61
|
+
payload.preselected_branch_id = Number(branchId);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
return payload;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export { buildBulletOpenPayload as b, getStoredIntent as g, resolveIntent as r };
|