@salla.sa/twilight-components 2.14.272 → 2.14.273
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-EG2Mf8a1.js → filepond-B6LUaQ9F.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-poster-DjNsnxTw.js → filepond-plugin-file-poster-DlB67Vv3.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-validate-size-BlM1btNO.js → filepond-plugin-file-validate-size-D7kuqaEC.js} +1 -1
- package/dist/cjs/{filepond-plugin-file-validate-type-DhymSoh9.js → filepond-plugin-file-validate-type-CliXp1Qt.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-edit-BQfvfpQ1.js → filepond-plugin-image-edit-BRIZbIyN.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-exif-orientation-DOi06s13.js → filepond-plugin-image-exif-orientation-bFbWHyQs.js} +1 -1
- package/dist/cjs/{filepond-plugin-image-preview-Rfix7Xbt.js → filepond-plugin-image-preview-24nxaVX6.js} +1 -1
- package/dist/cjs/{index-DS7mXxWq.js → index-BpUrZ_-D.js} +136 -26
- package/dist/cjs/{index-vIV5iX-W.js → index-xI-pRoDr.js} +1 -1
- package/dist/cjs/loader.cjs.js +3 -4
- package/dist/cjs/{salla-add-product-button_51.cjs.entry.js → salla-accordion_62.cjs.entry.js} +2104 -120
- package/dist/cjs/salla-advertisement.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-cart-item-offers.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-filters-widget.cjs.entry.js +1 -1
- package/dist/cjs/salla-filters.cjs.entry.js +1 -1
- package/dist/cjs/salla-installment.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 +1 -1
- package/dist/cjs/salla-metadata.cjs.entry.js +1 -1
- package/dist/cjs/salla-notification-item.cjs.entry.js +2 -2
- package/dist/cjs/salla-notifications.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-accordion_4.cjs.entry.js → salla-order-details-options.cjs.entry.js} +1 -100
- package/dist/cjs/salla-order-details.cjs.entry.js +2 -2
- package/dist/cjs/salla-order-summary.cjs.entry.js +2 -2
- package/dist/cjs/salla-orders.cjs.entry.js +1 -1
- package/dist/cjs/salla-payments.cjs.entry.js +3 -3
- package/dist/cjs/salla-price-range.cjs.entry.js +3 -3
- package/dist/cjs/salla-review-card.cjs.entry.js +2 -2
- package/dist/cjs/salla-reviews-page.cjs.entry.js +2 -2
- package/dist/cjs/salla-reviews.cjs.entry.js +2 -2
- package/dist/cjs/salla-social.cjs.entry.js +2 -2
- package/dist/cjs/salla-tiered-offer.cjs.entry.js +1 -1
- package/dist/cjs/salla-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/salla-verify.cjs.entry.js +1 -1
- package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
- package/dist/cjs/twilight.cjs.js +3 -4
- package/dist/collection/collection-manifest.json +5 -0
- package/dist/collection/components/salla-accordion/salla-accordion-head.js +8 -2
- package/dist/collection/components/salla-comments/salla-comments.js +20 -1
- package/dist/collection/components/salla-conditional-fields/salla-conditional-fields.js +33 -5
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-cart.css +0 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-cart.js +89 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-details.css +0 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-details.js +195 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-options-modal.css +3 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-options-modal.js +595 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-slider.css +0 -0
- package/dist/collection/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-slider.js +174 -0
- package/dist/collection/components/salla-multiple-bundle-product/interfaces.js +1 -0
- package/dist/collection/components/salla-multiple-bundle-product/salla-multiple-bundle-product.css +3 -0
- package/dist/collection/components/salla-multiple-bundle-product/salla-multiple-bundle-product.js +132 -0
- 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-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-price-range/salla-price-range.js +2 -2
- package/dist/collection/components/salla-product-availability/salla-product-availability.js +1 -1
- package/dist/collection/components/salla-product-card/salla-product-card.js +5 -5
- package/dist/collection/components/salla-product-options/salla-product-options.js +105 -22
- 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 +1 -1
- package/dist/collection/components/salla-review-card/salla-review-card.js +1 -1
- package/dist/collection/components/salla-reviews/salla-reviews.js +1 -1
- package/dist/collection/components/salla-reviews-page/salla-reviews-page.js +1 -1
- package/dist/collection/components/salla-scopes/salla-scopes.js +1 -1
- package/dist/collection/components/salla-search/salla-search.js +3 -3
- package/dist/collection/components/salla-skeleton/salla-skeleton.js +1 -1
- package/dist/collection/components/salla-slider/salla-slider.js +2 -2
- 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-tooltip/salla-tooltip.js +1 -1
- package/dist/collection/components/salla-user-settings/salla-user-settings.js +1 -1
- package/dist/components/index.js +2 -2
- package/dist/components/salla-accordion-head2.js +2 -2
- package/dist/components/salla-comments.js +20 -1
- package/dist/components/salla-conditional-fields2.js +28 -6
- package/dist/components/salla-multiple-bundle-product-cart.d.ts +11 -0
- package/dist/components/salla-multiple-bundle-product-cart.js +9 -0
- package/dist/components/salla-multiple-bundle-product-cart2.js +153 -0
- package/dist/components/salla-multiple-bundle-product-details.d.ts +11 -0
- package/dist/components/salla-multiple-bundle-product-details.js +9 -0
- package/dist/components/salla-multiple-bundle-product-details2.js +283 -0
- package/dist/components/salla-multiple-bundle-product-options-modal.d.ts +11 -0
- package/dist/components/salla-multiple-bundle-product-options-modal.js +9 -0
- package/dist/components/salla-multiple-bundle-product-options-modal2.js +585 -0
- package/dist/components/salla-multiple-bundle-product-slider.d.ts +11 -0
- package/dist/components/salla-multiple-bundle-product-slider.js +9 -0
- package/dist/components/salla-multiple-bundle-product-slider2.js +81 -0
- package/dist/components/salla-multiple-bundle-product.d.ts +11 -0
- package/dist/components/salla-multiple-bundle-product.js +210 -0
- 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-summary.js +1 -1
- package/dist/components/salla-payments.js +2 -2
- package/dist/components/salla-placeholder2.js +1 -1
- package/dist/components/salla-price-range2.js +2 -2
- package/dist/components/salla-product-availability2.js +1 -1
- package/dist/components/salla-product-card2.js +5 -5
- package/dist/components/salla-product-options.js +1 -810
- package/dist/{esm/salla-product-options.entry.js → components/salla-product-options2.js} +197 -30
- package/dist/components/salla-product-size-guide.js +2 -2
- package/dist/components/salla-quantity-input.js +1 -1
- package/dist/components/salla-quick-buy2.js +1 -1
- package/dist/components/salla-review-card2.js +1 -1
- package/dist/components/salla-reviews-page.js +1 -1
- package/dist/components/salla-reviews.js +1 -1
- package/dist/components/salla-scopes.js +1 -1
- package/dist/components/salla-search.js +3 -3
- package/dist/components/salla-skeleton2.js +1 -1
- package/dist/components/salla-slider2.js +2 -2
- package/dist/components/salla-social-share.js +1 -1
- 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-tooltip2.js +1 -1
- package/dist/components/salla-user-settings.js +1 -1
- package/dist/esm/{filepond-DbR8YXoW.js → filepond-C8M-qAIs.js} +1 -1
- package/dist/esm/{filepond-plugin-file-poster-DEj3O3wZ.js → filepond-plugin-file-poster-UfHq-uvl.js} +1 -1
- package/dist/esm/{filepond-plugin-file-validate-size-DYnIp5yF.js → filepond-plugin-file-validate-size-DZ15xnJZ.js} +1 -1
- package/dist/esm/{filepond-plugin-file-validate-type-Cx_PD8SU.js → filepond-plugin-file-validate-type-CWR9opI0.js} +1 -1
- package/dist/esm/{filepond-plugin-image-edit-BwmXRkmP.js → filepond-plugin-image-edit-XbR1h-bg.js} +1 -1
- package/dist/esm/{filepond-plugin-image-exif-orientation-BtsMS4U-.js → filepond-plugin-image-exif-orientation-cSRDvvXQ.js} +1 -1
- package/dist/esm/{filepond-plugin-image-preview-DQ0c3hIt.js → filepond-plugin-image-preview-B-SvzNFg.js} +1 -1
- package/dist/esm/{index-xiIpq8fU.js → index-Q_DltBmK.js} +1 -1
- package/dist/esm/{index-D5PGwR59.js → index-gLeBNvS1.js} +136 -26
- package/dist/esm/loader.js +3 -4
- package/dist/esm/{salla-add-product-button_51.entry.js → salla-accordion_62.entry.js} +2084 -111
- package/dist/esm/salla-advertisement.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-cart-item-offers.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-filters-widget.entry.js +1 -1
- package/dist/esm/salla-filters.entry.js +1 -1
- package/dist/esm/salla-installment.entry.js +1 -1
- package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
- package/dist/esm/salla-loyalty-program.entry.js +1 -1
- package/dist/esm/salla-metadata.entry.js +1 -1
- package/dist/esm/salla-notification-item.entry.js +2 -2
- package/dist/esm/salla-notifications.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-accordion_4.entry.js → salla-order-details-options.entry.js} +2 -98
- package/dist/esm/salla-order-details.entry.js +2 -2
- package/dist/esm/salla-order-summary.entry.js +2 -2
- package/dist/esm/salla-orders.entry.js +1 -1
- package/dist/esm/salla-payments.entry.js +3 -3
- package/dist/esm/salla-price-range.entry.js +3 -3
- package/dist/esm/salla-review-card.entry.js +2 -2
- package/dist/esm/salla-reviews-page.entry.js +2 -2
- package/dist/esm/salla-reviews.entry.js +2 -2
- package/dist/esm/salla-social.entry.js +2 -2
- package/dist/esm/salla-tiered-offer.entry.js +1 -1
- package/dist/esm/salla-tooltip.entry.js +2 -2
- package/dist/esm/salla-verify.entry.js +1 -1
- package/dist/esm/salla-wallet.entry.js +1 -1
- package/dist/esm/twilight.js +3 -4
- package/dist/twilight/{p-4611a11b.entry.js → p-00d8544c.entry.js} +1 -1
- package/dist/twilight/{p-b40d5871.entry.js → p-06d126b6.entry.js} +1 -1
- package/dist/twilight/{p-2bf21126.entry.js → p-1cc68ef5.entry.js} +1 -1
- package/dist/twilight/{p-BsHa_73h.js → p-1ekWkYOJ.js} +1 -1
- package/dist/twilight/p-21b37923.entry.js +4 -0
- package/dist/twilight/{p-bcab2639.entry.js → p-263b9b06.entry.js} +1 -1
- package/dist/twilight/{p-8ba8efe1.entry.js → p-2787ff9f.entry.js} +1 -1
- package/dist/twilight/p-3c1484b9.entry.js +11 -0
- package/dist/twilight/{p-c15928d5.entry.js → p-5057b400.entry.js} +1 -1
- package/dist/twilight/{p-280c1f64.entry.js → p-5278b873.entry.js} +1 -1
- package/dist/twilight/{p-e3b0a71f.entry.js → p-56f7a2ba.entry.js} +1 -1
- package/dist/twilight/{p-65b1fcea.entry.js → p-697db5c6.entry.js} +1 -1
- package/dist/twilight/{p-b94ebbd9.entry.js → p-73a8296a.entry.js} +1 -1
- package/dist/twilight/{p-eae51196.entry.js → p-7603a820.entry.js} +1 -1
- package/dist/twilight/{p-56fa3b9c.entry.js → p-7c8d7ca3.entry.js} +1 -1
- package/dist/twilight/{p-e95284d7.entry.js → p-80a07063.entry.js} +1 -1
- package/dist/twilight/{p-eaad31d1.entry.js → p-82c156ab.entry.js} +1 -1
- package/dist/twilight/{p-7df916fc.entry.js → p-8380c411.entry.js} +1 -1
- package/dist/twilight/{p-a61e2b8e.entry.js → p-946e5649.entry.js} +1 -1
- package/dist/twilight/{p-f3c29342.entry.js → p-9bcd9c87.entry.js} +1 -1
- package/dist/twilight/p-9c477fdf.entry.js +4 -0
- package/dist/twilight/{p-DV_VEuIe.js → p-B-nQtFTN.js} +1 -1
- package/dist/twilight/{p-DEUne75O.js → p-BI2zk2yo.js} +1 -1
- package/dist/twilight/{p-C4wd-bXb.js → p-BRD27esZ.js} +1 -1
- package/dist/twilight/{p-Bvez5luh.js → p-CUYEEJ4c.js} +1 -1
- package/dist/twilight/{p-CH8-uKSN.js → p-DUvdNUoC.js} +1 -1
- package/dist/twilight/{p-D0ZZ4jO5.js → p-DhR67rwu.js} +1 -1
- package/dist/twilight/p-a01dd6b7.entry.js +4 -0
- package/dist/twilight/{p-9e3f55be.entry.js → p-a3e000ef.entry.js} +1 -1
- package/dist/twilight/{p-3f412ab2.entry.js → p-a6c14a64.entry.js} +1 -1
- package/dist/twilight/p-b0b79820.entry.js +4 -0
- package/dist/twilight/{p-10856491.entry.js → p-b5581886.entry.js} +1 -1
- package/dist/twilight/p-b81437f4.entry.js +4 -0
- package/dist/twilight/{p-de200512.entry.js → p-bf010154.entry.js} +1 -1
- package/dist/twilight/{p-0ffafdea.entry.js → p-c0388251.entry.js} +1 -1
- package/dist/twilight/{p-2613f6dc.entry.js → p-c9ab361e.entry.js} +1 -1
- package/dist/twilight/{p-92848d53.entry.js → p-ed85bc00.entry.js} +1 -1
- package/dist/twilight/p-f7863a58.entry.js +4 -0
- package/dist/twilight/{p-D5PGwR59.js → p-gLeBNvS1.js} +2 -2
- package/dist/twilight/{p-D5p2t_CX.js → p-j4lbZMJ0.js} +1 -1
- package/dist/twilight/twilight.esm.js +1 -1
- package/dist/types/components/salla-accordion/salla-accordion-head.d.ts +6 -0
- package/dist/types/components/salla-conditional-fields/salla-conditional-fields.d.ts +2 -0
- package/dist/types/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-cart.d.ts +10 -0
- package/dist/types/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-details.d.ts +20 -0
- package/dist/types/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-options-modal.d.ts +46 -0
- package/dist/types/components/salla-multiple-bundle-product/components/salla-multiple-bundle-product-slider.d.ts +22 -0
- package/dist/types/components/salla-multiple-bundle-product/interfaces.d.ts +101 -0
- package/dist/types/components/salla-multiple-bundle-product/salla-multiple-bundle-product.d.ts +42 -0
- package/dist/types/components/salla-product-options/salla-product-options.d.ts +21 -1
- package/dist/types/components.d.ts +298 -2
- package/package.json +5 -5
- package/dist/cjs/app-globals-OVEmNa5W.js +0 -38
- package/dist/cjs/camera-DytepEoK.js +0 -13
- package/dist/cjs/minus-CCryh1qf.js +0 -21
- package/dist/cjs/salla-booking-field_2.cjs.entry.js +0 -280
- package/dist/cjs/salla-product-options.cjs.entry.js +0 -715
- package/dist/esm/app-globals-BKgAyoNJ.js +0 -36
- package/dist/esm/camera-C6jIkM-X.js +0 -11
- package/dist/esm/minus-DfeagqF1.js +0 -18
- package/dist/esm/salla-booking-field_2.entry.js +0 -277
- package/dist/twilight/p-19c38b4a.entry.js +0 -11
- package/dist/twilight/p-8272b58f.entry.js +0 -4
- package/dist/twilight/p-989fcbb4.entry.js +0 -4
- package/dist/twilight/p-9f47b72b.entry.js +0 -4
- package/dist/twilight/p-C6jIkM-X.js +0 -4
- package/dist/twilight/p-DfeagqF1.js +0 -4
- package/dist/twilight/p-KHt1Smzh.js +0 -4
- package/dist/twilight/p-b8d41065.entry.js +0 -4
- package/dist/twilight/p-dd9695d6.entry.js +0 -4
- package/dist/twilight/p-e2ebb686.entry.js +0 -4
- package/dist/twilight/p-e30f7c20.entry.js +0 -4
- package/dist/twilight/p-fcb3e719.entry.js +0 -4
|
@@ -1,9 +1,19 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Crafted with ❤ by Salla
|
|
3
3
|
*/
|
|
4
|
-
import {
|
|
5
|
-
import { I as IconVerified } from './check
|
|
6
|
-
import { C as CameraIcon } from './camera
|
|
4
|
+
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
5
|
+
import { I as IconVerified } from './check.js';
|
|
6
|
+
import { C as CameraIcon } from './camera.js';
|
|
7
|
+
import { d as defineCustomElement$a } from './salla-booking-field2.js';
|
|
8
|
+
import { d as defineCustomElement$9 } from './salla-button2.js';
|
|
9
|
+
import { d as defineCustomElement$8 } from './salla-color-picker2.js';
|
|
10
|
+
import { d as defineCustomElement$7 } from './salla-conditional-fields2.js';
|
|
11
|
+
import { d as defineCustomElement$6 } from './salla-datetime-picker2.js';
|
|
12
|
+
import { d as defineCustomElement$5 } from './salla-file-upload2.js';
|
|
13
|
+
import { d as defineCustomElement$4 } from './salla-loading2.js';
|
|
14
|
+
import { d as defineCustomElement$3 } from './salla-map2.js';
|
|
15
|
+
import { d as defineCustomElement$2 } from './salla-modal2.js';
|
|
16
|
+
import { d as defineCustomElement$1 } from './salla-progress-bar2.js';
|
|
7
17
|
|
|
8
18
|
var DisplayType;
|
|
9
19
|
(function (DisplayType) {
|
|
@@ -43,10 +53,11 @@ var FileIcon = `<!-- Generated by IcoMoon.io -->
|
|
|
43
53
|
|
|
44
54
|
const sallaProductOptionsCss = "";
|
|
45
55
|
|
|
46
|
-
const SallaProductOptions = class {
|
|
47
|
-
constructor(
|
|
48
|
-
|
|
49
|
-
this.
|
|
56
|
+
const SallaProductOptions = /*@__PURE__*/ proxyCustomElement(class SallaProductOptions extends HTMLElement {
|
|
57
|
+
constructor() {
|
|
58
|
+
super();
|
|
59
|
+
this.__registerHost();
|
|
60
|
+
this.changed = createEvent(this, "changed", 7);
|
|
50
61
|
this.fileTypes = {
|
|
51
62
|
pdf: 'application/pdf',
|
|
52
63
|
png: 'image/png',
|
|
@@ -159,9 +170,21 @@ const SallaProductOptions = class {
|
|
|
159
170
|
async getSelectedOptionsData() {
|
|
160
171
|
const selectedOptions = {};
|
|
161
172
|
const formData = this.host.getElementSallaData();
|
|
173
|
+
// Check if bundleContext is defined as a prop on the component before accessing it
|
|
174
|
+
const contextData = (typeof this.bundleContext !== 'undefined') ? this.bundleContext : null;
|
|
162
175
|
formData.forEach((value, key) => {
|
|
163
|
-
if (
|
|
164
|
-
|
|
176
|
+
if (contextData) {
|
|
177
|
+
// Handle bundle naming convention: bundle[sectionId][index][options][optionId]
|
|
178
|
+
if (key.startsWith('bundle[') && key.includes('[options][')) {
|
|
179
|
+
const optionId = key.split('[options][')[1].replace(']', '');
|
|
180
|
+
selectedOptions[optionId] = value;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
else {
|
|
184
|
+
// Handle standard naming convention: options[optionId]
|
|
185
|
+
if (key.startsWith('options[')) {
|
|
186
|
+
selectedOptions[key.replace('options[', '').replace(']', '')] = value;
|
|
187
|
+
}
|
|
165
188
|
}
|
|
166
189
|
});
|
|
167
190
|
return selectedOptions;
|
|
@@ -337,6 +360,10 @@ const SallaProductOptions = class {
|
|
|
337
360
|
if (option.type === DisplayType.SINGLE_OPTION) {
|
|
338
361
|
return this.singleOption(option);
|
|
339
362
|
}
|
|
363
|
+
// Handle radio type as single option for bundle products
|
|
364
|
+
if (option.type === DisplayType.RADIO) {
|
|
365
|
+
return this.radioOption(option);
|
|
366
|
+
}
|
|
340
367
|
if (option.type === DisplayType.DIGITAL_CARD_VALUE) {
|
|
341
368
|
return this.digitalCardValuesOption(option);
|
|
342
369
|
}
|
|
@@ -448,10 +475,47 @@ const SallaProductOptions = class {
|
|
|
448
475
|
}
|
|
449
476
|
return (h(Host, { class: "s-product-options-wrapper" }, h("salla-conditional-fields", null, this.optionsData.map((option) => h("div", { key: option.id, class: `s-product-options-option-container${option.visibility_condition || this.hideDigitalCardsOptions(option) ? ' hidden' : ''}`, "data-option-id": option.id, ...this.getOptionShownWhen(option) }, option.name === 'splitter' ?
|
|
450
477
|
this.splitterOption()
|
|
451
|
-
: h("div", { class: { "s-product-options-option": true, "s-product-options-option-booking": option.type === DisplayType.BOOKING && salla.url.is_page("cart") }, "data-option-type": option.type, "data-option-required": `${option.required}` }, h("label", { htmlFor:
|
|
478
|
+
: h("div", { class: { "s-product-options-option": true, "s-product-options-option-booking": option.type === DisplayType.BOOKING && salla.url.is_page("cart") }, "data-option-type": option.type, "data-option-required": `${option.required}` }, h("label", { htmlFor: this.generateInputName(option.id), class: `s-product-options-option-label ${this.hideLabel(option) ? 's-product-options-option-label-hidden' : ''}` }, h("b", null, option.name, option.required && h("span", null, " * "), " "), h("small", null, option.placeholder)), h("div", { class: `s-product-options-option-content ${this.hideLabel(option) || (option.type === DisplayType.BOOKING && salla.url.is_page("cart")) ? 's-product-options-option-content-full-width' : ''}` }, this.getDisplayForType(option))))))));
|
|
452
479
|
}
|
|
453
480
|
generateUniqueKey(defaultValue) {
|
|
454
|
-
|
|
481
|
+
const contextData = this.bundleContext;
|
|
482
|
+
let baseKey = this.uniqueKey ? `${defaultValue}-${this.uniqueKey}` : defaultValue;
|
|
483
|
+
if (contextData) {
|
|
484
|
+
try {
|
|
485
|
+
// Handle both string and object types
|
|
486
|
+
const context = typeof contextData === 'string'
|
|
487
|
+
? JSON.parse(contextData)
|
|
488
|
+
: contextData;
|
|
489
|
+
const { sectionId, productId } = context;
|
|
490
|
+
baseKey = `${baseKey}-bundle-${sectionId}-${productId}`;
|
|
491
|
+
}
|
|
492
|
+
catch (e) {
|
|
493
|
+
// If parsing fails, just use the base key
|
|
494
|
+
}
|
|
495
|
+
}
|
|
496
|
+
return baseKey;
|
|
497
|
+
}
|
|
498
|
+
/**
|
|
499
|
+
* Generate the correct input name based on bundle context
|
|
500
|
+
* @param optionId - The option ID
|
|
501
|
+
* @returns The formatted input name
|
|
502
|
+
*/
|
|
503
|
+
generateInputName(optionId) {
|
|
504
|
+
const contextData = this.bundleContext;
|
|
505
|
+
if (contextData) {
|
|
506
|
+
try {
|
|
507
|
+
// Handle both string and object types
|
|
508
|
+
const context = typeof contextData === 'string'
|
|
509
|
+
? JSON.parse(contextData)
|
|
510
|
+
: contextData;
|
|
511
|
+
const { sectionId, productId } = context;
|
|
512
|
+
return `bundle[${sectionId}][${productId}][options][${optionId}]`;
|
|
513
|
+
}
|
|
514
|
+
catch (e) {
|
|
515
|
+
return `options[${optionId}]`;
|
|
516
|
+
}
|
|
517
|
+
}
|
|
518
|
+
return `options[${optionId}]`;
|
|
455
519
|
}
|
|
456
520
|
fillSelectedOptions() {
|
|
457
521
|
this.selectedOptions = this.optionsData.reduce((acc, opt) => {
|
|
@@ -511,7 +575,7 @@ const SallaProductOptions = class {
|
|
|
511
575
|
this.getExpireDonationMessage(option));
|
|
512
576
|
}
|
|
513
577
|
fileUploader(option, additions = null) {
|
|
514
|
-
return h("salla-file-upload", { ...(additions || {}), "payload-name": "file", value: option.value, "instant-upload": true, name:
|
|
578
|
+
return h("salla-file-upload", { ...(additions || {}), "payload-name": "file", value: option.value, "instant-upload": true, name: this.generateInputName(option.id), required: !option.visibility_condition && option.required, height: "120px", onAdded: (e) => this.changedHandler(e, option), url: salla.cart.api.getUploadImageEndpoint(), "form-data": { cart_item_id: this.productId, product_id: this.productId }, onInvalidInput: (e) => this.invalidHandler(e, option), class: { "s-product-options-image-input": true, required: option.required } }, h("div", { class: "s-product-options-filepond-placeholder" }, h("span", { class: "s-product-options-filepond-placeholder-icon", innerHTML: additions.accept?.split(',').every(type => type.includes('image'))
|
|
515
579
|
? CameraIcon
|
|
516
580
|
: FileIcon }), h("p", { class: "s-product-options-filepond-placeholder-text" }, salla.lang.get('common.uploader.drag_and_drop')), h("span", { class: "filepond--label-action" }, salla.lang.get('common.uploader.browse'))));
|
|
517
581
|
}
|
|
@@ -529,7 +593,7 @@ const SallaProductOptions = class {
|
|
|
529
593
|
// TODO: (ONLY FOR TESTING!) find a better way to make it testable, e.g. wrap it with a unique class like textOption
|
|
530
594
|
//@ts-ignore
|
|
531
595
|
numberOption(option) {
|
|
532
|
-
return h("input", { type: "text", value: option.value, class: "s-form-control", required: !option.visibility_condition && option.required, name:
|
|
596
|
+
return h("input", { type: "text", value: option.value, class: "s-form-control", required: !option.visibility_condition && option.required, name: this.generateInputName(option.id), placeholder: option.placeholder, onBlur: e => this.changedHandler(e, option), onInvalid: (e) => this.invalidHandler(e, option), onInput: e => salla.helpers.inputDigitsOnly(e.target) });
|
|
533
597
|
}
|
|
534
598
|
//@ts-ignore
|
|
535
599
|
splitterOption() {
|
|
@@ -537,36 +601,36 @@ const SallaProductOptions = class {
|
|
|
537
601
|
}
|
|
538
602
|
//@ts-ignore
|
|
539
603
|
textOption(option) {
|
|
540
|
-
return h("div", { class: "s-product-options-text" }, h("input", { type: "text", value: option.value, maxLength: option?.length, class: 's-form-control', required: !option.visibility_condition && option.required, name:
|
|
604
|
+
return h("div", { class: "s-product-options-text" }, h("input", { type: "text", value: option.value, maxLength: option?.length, class: 's-form-control', required: !option.visibility_condition && option.required, name: this.generateInputName(option.id), placeholder: option.placeholder, onInvalid: (e) => this.invalidHandler(e, option), onChange: e => this.changedHandler(e, option) }));
|
|
541
605
|
}
|
|
542
606
|
//@ts-ignore
|
|
543
607
|
textareaOption(option) {
|
|
544
608
|
//todo::remove mt-1 class, and if it's okay to remove the tag itself will be great
|
|
545
|
-
return h("div", { class: "s-product-options-textarea" }, h("div", { class: "mt-1" }, h("textarea", { rows: 4, value: option.value, maxLength: option?.length, class: "s-form-control", required: !option.visibility_condition && option.required, id:
|
|
609
|
+
return h("div", { class: "s-product-options-textarea" }, h("div", { class: "mt-1" }, h("textarea", { rows: 4, value: option.value, maxLength: option?.length, class: "s-form-control", required: !option.visibility_condition && option.required, id: this.generateUniqueKey(option.id.toString()), name: this.generateInputName(option.id), placeholder: option.placeholder, onInvalid: (e) => this.invalidHandler(e, option), onChange: (e) => this.changedHandler(e, option) })));
|
|
546
610
|
}
|
|
547
611
|
//@ts-ignore
|
|
548
612
|
mapOption(option) {
|
|
549
|
-
return h("salla-map", { zoom: 15, lat: this.getLatLng(option.value, 'lat'), lng: this.getLatLng(option.value, 'lng'), name:
|
|
613
|
+
return h("salla-map", { zoom: 15, lat: this.getLatLng(option.value, 'lat'), lng: this.getLatLng(option.value, 'lng'), name: this.generateInputName(option.id), searchable: true, required: option.required, onInvalidInput: (e) => this.invalidHandler(e, option), onSelected: e => this.changedHandler(e, option) });
|
|
550
614
|
}
|
|
551
615
|
colorPickerOption(option) {
|
|
552
|
-
return h("salla-color-picker", { onSubmitted: e => this.changedHandler(e, option), name:
|
|
616
|
+
return h("salla-color-picker", { onSubmitted: e => this.changedHandler(e, option), name: this.generateInputName(option.id), required: !option.visibility_condition && option.required, onInvalidInput: (e) => this.invalidHandler(e, option), color: option.value });
|
|
553
617
|
}
|
|
554
618
|
/**
|
|
555
619
|
* ============= Date Time options =============
|
|
556
620
|
*/
|
|
557
621
|
//@ts-ignore
|
|
558
622
|
timeOption(option) {
|
|
559
|
-
return h("salla-datetime-picker", { noCalendar: true, enableTime: true, dateFormat: "h:i K", value: option.value, placeholder: option.name, required: !option.visibility_condition && option.required, name:
|
|
623
|
+
return h("salla-datetime-picker", { noCalendar: true, enableTime: true, dateFormat: "h:i K", value: option.value, placeholder: option.name, required: !option.visibility_condition && option.required, name: this.generateInputName(option.id), class: "s-product-options-time-element", onInvalidInput: (e) => this.invalidHandler(e, option), onPicked: e => this.changedHandler(e, option) });
|
|
560
624
|
}
|
|
561
625
|
//@ts-ignore
|
|
562
626
|
dateOption(option) {
|
|
563
627
|
//todo:: consider date-range @see https://github.com/SallaApp/theme-raed/blob/master/src/assets/js/partials/product-options.js#L8-L23
|
|
564
|
-
return h("div", { class: "s-product-options-date-element" }, h("salla-datetime-picker", { value: option.value, placeholder: option.name, required: !option.visibility_condition && option.required, minDate: new Date(), name:
|
|
628
|
+
return h("div", { class: "s-product-options-date-element" }, h("salla-datetime-picker", { value: option.value, placeholder: option.name, required: !option.visibility_condition && option.required, minDate: new Date(), name: this.generateInputName(option.id), onInvalidInput: (e) => this.invalidHandler(e, option), onPicked: e => this.changedHandler(e, option) }));
|
|
565
629
|
}
|
|
566
630
|
//@ts-ignore
|
|
567
631
|
datetimeOption(option) {
|
|
568
632
|
//todo:: consider date-range @see https://github.com/SallaApp/theme-raed/blob/master/src/assets/js/partials/product-options.js#L8-L23
|
|
569
|
-
return h("div", { class: "s-product-options-datetime-element" }, h("salla-datetime-picker", { enableTime: true, value: option.value, dateFormat: "Y-m-d G:i:K", placeholder: option.name, required: !option.visibility_condition && option.required, name:
|
|
633
|
+
return h("div", { class: "s-product-options-datetime-element" }, h("salla-datetime-picker", { enableTime: true, value: option.value, dateFormat: "Y-m-d G:i:K", placeholder: option.name, required: !option.visibility_condition && option.required, name: this.generateInputName(option.id), maxDate: option.to_date_time, minDate: option.from_date_time, onInvalidInput: (e) => this.invalidHandler(e, option), onPicked: e => this.changedHandler(e, option) }));
|
|
570
634
|
}
|
|
571
635
|
/**
|
|
572
636
|
* ============= Advanced options =============
|
|
@@ -628,7 +692,8 @@ const SallaProductOptions = class {
|
|
|
628
692
|
* @returns HTMLElement[] - An array of labeled input elements.
|
|
629
693
|
*/
|
|
630
694
|
renderOptionDetails(type, option, isRequired, buttonStyle = false) {
|
|
631
|
-
const
|
|
695
|
+
const baseName = this.generateInputName(option.id);
|
|
696
|
+
const name = type === 'radio' ? baseName : `${baseName}[]`;
|
|
632
697
|
return option?.details.map((detail) => this.renderInput(type, detail, option, isRequired, name, buttonStyle));
|
|
633
698
|
}
|
|
634
699
|
/**
|
|
@@ -637,7 +702,7 @@ const SallaProductOptions = class {
|
|
|
637
702
|
* @returns HTMLElement - A select dropdown element with all option details.
|
|
638
703
|
*/
|
|
639
704
|
renderSelect(option) {
|
|
640
|
-
return (h("div", null, h("select", { name:
|
|
705
|
+
return (h("div", null, h("select", { name: this.generateInputName(option.id), required: !option.visibility_condition && option.required, class: "s-form-control", onInvalid: (e) => this.invalidHandler(e, option), onChange: (e) => this.changedHandler(e, option) }, h("option", { value: "" }, option.placeholder), option?.details.map((detail) => (h("option", { key: detail.id, value: detail.id, disabled: this.canDisabled && this.isOptionDetailOut(detail), selected: detail.is_selected }, this.getOptionDetailName(detail)))))));
|
|
641
706
|
}
|
|
642
707
|
/**
|
|
643
708
|
* Renders a grid-based layout for option inputs (radio or checkbox).
|
|
@@ -678,14 +743,24 @@ const SallaProductOptions = class {
|
|
|
678
743
|
required: option.required,
|
|
679
744
|
} }, this.renderOptionDetails('checkbox', option, isRequired)));
|
|
680
745
|
}
|
|
746
|
+
/**
|
|
747
|
+
* Renders a radio option selection (used for bundle products).
|
|
748
|
+
* This is essentially the same as single option but with explicit radio handling.
|
|
749
|
+
* @param option - The parent option object.
|
|
750
|
+
* @returns HTMLElement - The rendered radio option element.
|
|
751
|
+
*/
|
|
752
|
+
radioOption(option) {
|
|
753
|
+
// Radio options behave the same as single options
|
|
754
|
+
return this.singleOption(option);
|
|
755
|
+
}
|
|
681
756
|
//@ts-ignore
|
|
682
757
|
colorOption(option) {
|
|
683
|
-
return (h("fieldset", { class: "s-product-options-colors-wrapper" }, option?.details.map((detail) => (h("div", { class: "s-product-options-colors-item", key: detail.id }, h("input", { type: "radio", value: detail.id, required: !option.visibility_condition && option.required, checked: detail.is_selected, name:
|
|
758
|
+
return (h("fieldset", { class: "s-product-options-colors-wrapper" }, option?.details.map((detail) => (h("div", { class: "s-product-options-colors-item", key: detail.id }, h("input", { type: "radio", value: detail.id, required: !option.visibility_condition && option.required, checked: detail.is_selected, name: this.generateInputName(option.id), disabled: this.canDisabled && this.isOptionDetailOut(detail), id: this.generateUniqueKey(`color-${this.productId}-${option.id}-${detail.id}`), onInvalid: (e) => this.invalidHandler(e, option), onChange: (e) => this.changedHandler(e, option) }), h("label", { htmlFor: this.generateUniqueKey(`color-${this.productId}-${option.id}-${detail.id}`) }, h("span", { style: { backgroundColor: detail.color } }), h("div", { innerHTML: this.getOptionDetailName(detail, true, option.type) })))))));
|
|
684
759
|
}
|
|
685
760
|
//@ts-ignore
|
|
686
761
|
thumbnailOption(option) {
|
|
687
762
|
return h("div", { class: "s-product-options-thumbnails-wrapper" }, option.details.map((detail) => {
|
|
688
|
-
return h("div", { key: detail.id }, h("input", { type: "radio", value: detail.id, "data-itemid": detail.id, required: !option.visibility_condition && option.required, checked: detail.is_selected, name:
|
|
763
|
+
return h("div", { key: detail.id }, h("input", { type: "radio", value: detail.id, "data-itemid": detail.id, required: !option.visibility_condition && option.required, checked: detail.is_selected, name: this.generateInputName(option.id), "data-img-id": detail.option_value, disabled: this.canDisabled && this.isOptionDetailOut(detail), id: this.generateUniqueKey(`option_${this.productId}-${option.id}_${detail.id}`), onInvalid: (e) => this.invalidHandler(e, option), onChange: (e) => this.changedHandler(e, option) }), h("label", { htmlFor: this.generateUniqueKey(`option_${this.productId}-${option.id}_${detail.id}`), "data-img-id": detail.option_value, class: "go-to-slide" }, h("img", { "data-src": detail.image, src: detail.image, title: detail.name, alt: detail.name }), h("span", { innerHTML: IconVerified, class: "s-product-options-thumbnails-icon" }), this.isOptionDetailOut(detail) ?
|
|
689
764
|
[
|
|
690
765
|
h("small", { key: detail.id, class: "s-product-options-thumbnails-stock-badge" }, this.outOfStockText),
|
|
691
766
|
this.canDisabled ? h("div", { key: detail.id, class: "s-product-options-thumbnails-badge-overlay" }) : '',
|
|
@@ -697,17 +772,109 @@ const SallaProductOptions = class {
|
|
|
697
772
|
digitalCardValuesOption(option) {
|
|
698
773
|
return h("div", { class: "s-product-options-digital-card-wrapper" }, this.availableDigitalCardValues.length > 0 ? this.availableDigitalCardValues.map((detail) => {
|
|
699
774
|
const id = String(detail.id);
|
|
700
|
-
return h("label", { htmlFor: this.generateUniqueKey(id.toString()), key: id, class: "s-product-options-digital-card-option" }, h("input", { type: "radio", "data-code-value": true, class: "s-form-control s-product-options-digital-card-input", value: detail.id, name:
|
|
775
|
+
return h("label", { htmlFor: this.generateUniqueKey(id.toString()), key: id, class: "s-product-options-digital-card-option" }, h("input", { type: "radio", "data-code-value": true, class: "s-form-control s-product-options-digital-card-input", value: detail.id, name: this.generateInputName(option.id), id: this.generateUniqueKey(id.toString()), required: !option.visibility_condition && option.required, onInvalid: (e) => this.invalidHandler(e, option), ...(!this.ignoreDefaultCardValue ? { defaultChecked: this.getSelectedDigitalCardOptions(option)?.id === detail.id } : {}) }), h("span", null, detail.name, " ", salla.config?.currency()?.symbol));
|
|
701
776
|
})
|
|
702
777
|
: h("div", { class: "s-product-options-digital-card-out-of-stock" }));
|
|
703
778
|
}
|
|
704
779
|
countryOption(option) {
|
|
705
780
|
return h("div", { class: "s-product-options-digital-card-wrapper" }, option.details.map((detail) => {
|
|
706
|
-
return h("label", { htmlFor: this.generateUniqueKey(detail.id.toString()), key: detail.id, class: { "s-product-options-digital-card-option": true, "s-product-options-digital-card-option-stock-out": detail.is_out } }, h("input", { id: this.generateUniqueKey(detail.id.toString()), type: "radio", class: "s-form-control s-product-options-digital-card-input", value: detail.id, name:
|
|
781
|
+
return h("label", { htmlFor: this.generateUniqueKey(detail.id.toString()), key: detail.id, class: { "s-product-options-digital-card-option": true, "s-product-options-digital-card-option-stock-out": detail.is_out } }, h("input", { id: this.generateUniqueKey(detail.id.toString()), type: "radio", class: "s-form-control s-product-options-digital-card-input", value: detail.id, name: this.generateInputName(option.id), disabled: detail.is_out, required: !option.visibility_condition && option.required, onInvalid: (e) => this.invalidHandler(e, option), onChange: e => this.changedHandler(e, option), onClick: () => { this.disableCardValue = false; }, ...(salla.url.is_page("cart") ? { defaultChecked: this.getSelectedDigitalCardOptions(option)?.id === detail.id } : {}) }), h("img", { loading: 'lazy', alt: detail.code, height: 24, width: 24, class: "s-product-options-country-flag", src: `https://cdn.assets.salla.network/prod/admin/cp/assets/flags/1x1/${String(detail.code).toLocaleLowerCase()}.svg` }), h("span", null, detail.name));
|
|
707
782
|
}));
|
|
708
783
|
}
|
|
709
|
-
get host() { return
|
|
710
|
-
}
|
|
711
|
-
|
|
784
|
+
get host() { return this; }
|
|
785
|
+
static get style() { return sallaProductOptionsCss; }
|
|
786
|
+
}, [0, "salla-product-options", {
|
|
787
|
+
"productId": [8, "product-id"],
|
|
788
|
+
"options": [1],
|
|
789
|
+
"hideOutLabel": [1, "hide-out-label"],
|
|
790
|
+
"uniqueKey": [1, "unique-key"],
|
|
791
|
+
"bundleContext": [1, "bundle-context"],
|
|
792
|
+
"config": [1],
|
|
793
|
+
"optionsData": [32],
|
|
794
|
+
"outOfStockText": [32],
|
|
795
|
+
"donationAmount": [32],
|
|
796
|
+
"selectDonationAmount": [32],
|
|
797
|
+
"selectAmount": [32],
|
|
798
|
+
"isCustomDonation": [32],
|
|
799
|
+
"selectedOptions": [32],
|
|
800
|
+
"canDisabled": [32],
|
|
801
|
+
"selectedSkus": [32],
|
|
802
|
+
"selectedOutSkus": [32],
|
|
803
|
+
"disableCardValue": [32],
|
|
804
|
+
"availableDigitalCardValues": [32],
|
|
805
|
+
"userInitiatedValidation": [32],
|
|
806
|
+
"setOptionsData": [64],
|
|
807
|
+
"getSelectedOptionsData": [64],
|
|
808
|
+
"reportValidity": [64],
|
|
809
|
+
"hasOutOfStockOption": [64],
|
|
810
|
+
"getSelectedOptions": [64],
|
|
811
|
+
"getOption": [64],
|
|
812
|
+
"enableUserInitiatedValidation": [64],
|
|
813
|
+
"validateAndScroll": [64]
|
|
814
|
+
}]);
|
|
815
|
+
function defineCustomElement() {
|
|
816
|
+
if (typeof customElements === "undefined") {
|
|
817
|
+
return;
|
|
818
|
+
}
|
|
819
|
+
const components = ["salla-product-options", "salla-booking-field", "salla-button", "salla-color-picker", "salla-conditional-fields", "salla-datetime-picker", "salla-file-upload", "salla-loading", "salla-map", "salla-modal", "salla-progress-bar"];
|
|
820
|
+
components.forEach(tagName => { switch (tagName) {
|
|
821
|
+
case "salla-product-options":
|
|
822
|
+
if (!customElements.get(tagName)) {
|
|
823
|
+
customElements.define(tagName, SallaProductOptions);
|
|
824
|
+
}
|
|
825
|
+
break;
|
|
826
|
+
case "salla-booking-field":
|
|
827
|
+
if (!customElements.get(tagName)) {
|
|
828
|
+
defineCustomElement$a();
|
|
829
|
+
}
|
|
830
|
+
break;
|
|
831
|
+
case "salla-button":
|
|
832
|
+
if (!customElements.get(tagName)) {
|
|
833
|
+
defineCustomElement$9();
|
|
834
|
+
}
|
|
835
|
+
break;
|
|
836
|
+
case "salla-color-picker":
|
|
837
|
+
if (!customElements.get(tagName)) {
|
|
838
|
+
defineCustomElement$8();
|
|
839
|
+
}
|
|
840
|
+
break;
|
|
841
|
+
case "salla-conditional-fields":
|
|
842
|
+
if (!customElements.get(tagName)) {
|
|
843
|
+
defineCustomElement$7();
|
|
844
|
+
}
|
|
845
|
+
break;
|
|
846
|
+
case "salla-datetime-picker":
|
|
847
|
+
if (!customElements.get(tagName)) {
|
|
848
|
+
defineCustomElement$6();
|
|
849
|
+
}
|
|
850
|
+
break;
|
|
851
|
+
case "salla-file-upload":
|
|
852
|
+
if (!customElements.get(tagName)) {
|
|
853
|
+
defineCustomElement$5();
|
|
854
|
+
}
|
|
855
|
+
break;
|
|
856
|
+
case "salla-loading":
|
|
857
|
+
if (!customElements.get(tagName)) {
|
|
858
|
+
defineCustomElement$4();
|
|
859
|
+
}
|
|
860
|
+
break;
|
|
861
|
+
case "salla-map":
|
|
862
|
+
if (!customElements.get(tagName)) {
|
|
863
|
+
defineCustomElement$3();
|
|
864
|
+
}
|
|
865
|
+
break;
|
|
866
|
+
case "salla-modal":
|
|
867
|
+
if (!customElements.get(tagName)) {
|
|
868
|
+
defineCustomElement$2();
|
|
869
|
+
}
|
|
870
|
+
break;
|
|
871
|
+
case "salla-progress-bar":
|
|
872
|
+
if (!customElements.get(tagName)) {
|
|
873
|
+
defineCustomElement$1();
|
|
874
|
+
}
|
|
875
|
+
break;
|
|
876
|
+
} });
|
|
877
|
+
}
|
|
878
|
+
defineCustomElement();
|
|
712
879
|
|
|
713
|
-
export { SallaProductOptions as
|
|
880
|
+
export { SallaProductOptions as S, defineCustomElement as d };
|
|
@@ -59,11 +59,11 @@ const SallaProductSizeGuide$1 = /*@__PURE__*/ proxyCustomElement(class SallaProd
|
|
|
59
59
|
return h("salla-placeholder", { alignment: "center", iconSize: "xl" }, h("div", { slot: "title" }, this.placeholder_title), h("div", { slot: "description" }, this.placeholder_description));
|
|
60
60
|
}
|
|
61
61
|
render() {
|
|
62
|
-
return (h("salla-modal", { key: '
|
|
62
|
+
return (h("salla-modal", { key: 'f80606d8b6e1e950c87209ca4e195c92f70dc341', class: "s-product-size-guide-wrapper", id: 'salla-product-size-guide-modal', isLoading: true, "has-skeleton": true, width: "md", ref: modal => this.modal = modal }, h("span", { key: '245688c24b70279566b0f7c51c7bf924ca5196c0', slot: 'icon', class: "s-product-size-guide-header-icon", innerHTML: PencilRuler }), h("div", { key: '9dc9b4aa8dea0599dbc78f5821e36bc4c600c6aa', slot: "loading" }, h("div", { key: 'fca84d9c2c5fa20ac446270c1c68c4ccda16dd77', class: "s-product-size-guide-skeleton" }, h("salla-skeleton", { key: '0f036371c9b42314beb4e2c1f308a99e2b068ab8', height: '15px', width: '25%' }), h("div", { key: 'a9059b864fddf26b6e15869cab013e793966907e', class: "s-product-size-guide-skeleton-header" }, h("salla-skeleton", { key: '34e188b1ff7e0b5e24df84d1b14df2b2255fc9eb', height: '40px' }), h("salla-skeleton", { key: '38653491fd73cf4d66cb87658b8121f88130e52e', height: '40px' }), h("salla-skeleton", { key: 'a8c3b3cc039fbbb8796c611f4485d889c94e632a', height: '40px' }), h("salla-skeleton", { key: '2de2d63a1a56a58f7f1bef92c46843683528ee1a', height: '40px' })), h("div", { key: 'cf0b08cb85830fcec4dd82140c89b6d009e1bc74', class: "s-product-size-guide-skeleton-content" }, h("salla-skeleton", { key: '402ed4292bb79e839316440ed985b1caed102602', height: '15px', width: '25%' }), h("salla-skeleton", { key: '88f0019d79ea72ef7748a5c04b7a8364c1160b92', height: '10px', width: '75%' }), h("salla-skeleton", { key: '10d7879c306d7185092c9e9aa0d407d2bb57519e', height: '10px', width: '50%' }), h("salla-skeleton", { key: '7b2d00c4c8000083b79d93466ed07828d61b6fbd', height: '10px', width: '75%' }), h("salla-skeleton", { key: '5d33b9848d9bccf34bb5f4a93ad99889fe1ee69f', height: '10px', width: '100%' }), h("salla-skeleton", { key: '6e49c074a8611a819814d17829466b983a419196', height: '10px', width: '25%' }), h("salla-skeleton", { key: '0fb70ed844efeda0d3c2ba348e14d1469a7b279b', height: '10px', width: '60%' }), h("salla-skeleton", { key: '5e55cb90aba76662377efccfef4a84fe0f64c341', height: '10px', width: '45%' }), h("salla-skeleton", { key: '058b96e3db12454ddfced543d6ecbdf0c38ac3dd', height: '10px', width: '30%' })))), h("slot", { key: 'e9eef25bce60cbb1dd48b3d8bc1ebda2305acda0', name: "header" }), !this.hasError && !!this.guides ?
|
|
63
63
|
[
|
|
64
64
|
h("salla-tabs", null, this.guides.map((guide) => h("salla-tab-header", { slot: "header", name: guide.name }, h("span", null, guide.name))), this.guides.map((guide) => h("salla-tab-content", { slot: "content", name: guide.name }, h("div", { innerHTML: guide.description }))))
|
|
65
65
|
]
|
|
66
|
-
: this.showPlaceholder(), h("slot", { key: '
|
|
66
|
+
: this.showPlaceholder(), h("slot", { key: '6b8bebc72d4a7baea765b1e5a6d4a81862206f94', name: "footer" })));
|
|
67
67
|
}
|
|
68
68
|
get host() { return this; }
|
|
69
69
|
static get style() { return sallaProductSizeGuideCss; }
|
|
@@ -84,7 +84,7 @@ const SallaQuantityInput$1 = /*@__PURE__*/ proxyCustomElement(class SallaQuantit
|
|
|
84
84
|
return this.host;
|
|
85
85
|
}
|
|
86
86
|
render() {
|
|
87
|
-
return (h(Host, { key: '
|
|
87
|
+
return (h(Host, { key: '5627ef48310739dc0a112c9c214f78bae9b71bca', class: "s-quantity-input" }, h("div", { key: '50040d9cd5bbf38d06d6a13f17a1b4d756f5285d', class: "s-quantity-input-container" }, h("button", { key: '334c465e2ac46c3b88e3f89ae3b0754dc3741f69', onClick: () => this.increase(), class: "s-quantity-input-increase-button s-quantity-input-button", type: "button" }, !this.hasIncrementSlot ? h("span", { innerHTML: Add }) : '', h("slot", { key: '9f41e975e7c47f4cbc3e97dd3f8591b633d9da29', name: "increment-button" })), h("input", { key: '6f5bfdeb1804cf98a13f12b966e5fa6582e39557', class: "s-quantity-input-input", ...this.getInputAttributes(), ref: (el) => this.textInput = el, onInput: (event) => this.setValue(event.target.value), min: "1", value: this.quantity }), h("button", { key: '583f5edb96bc5a368851eadb5940d79b7afed3be', class: "s-quantity-input-decrease-button s-quantity-input-button", onClick: () => this.decrease(), type: "button" }, !this.hasDecrementSlot ? h("span", { innerHTML: Minus }) : '', h("slot", { key: '8726d4d616dd6f4fd1348312d3a9c24bf9268146', name: "decrement-button" })))));
|
|
88
88
|
}
|
|
89
89
|
get host() { return this; }
|
|
90
90
|
static get watchers() { return {
|
|
@@ -896,7 +896,7 @@ const SallaQuickBuy = /*@__PURE__*/ proxyCustomElement(class SallaQuickBuy exten
|
|
|
896
896
|
});
|
|
897
897
|
}
|
|
898
898
|
render() {
|
|
899
|
-
return h(Host, { key: '
|
|
899
|
+
return h(Host, { key: '46c3a8b699f4390166d027a0eb2d34451a1dd6f1' }, this.quickBuyButton());
|
|
900
900
|
}
|
|
901
901
|
quickBuyButton() {
|
|
902
902
|
return h("apple-pay-button", { locale: salla.config.get('user.language_code'), onClick: () => this.quickBuyHandler(), "data-quick-purchase": "applepay", class: "s-quick-buy-apple-pay", "data-is-applepay": "1", buttonstyle: "black", type: this.type });
|
|
@@ -172,7 +172,7 @@ const SallaReviewCard = /*@__PURE__*/ proxyCustomElement(class SallaReviewCard e
|
|
|
172
172
|
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)));
|
|
173
173
|
}
|
|
174
174
|
render() {
|
|
175
|
-
return h("div", { key: '
|
|
175
|
+
return h("div", { key: 'ff1711d73446e0b98e8e0888d1491687f942ff68', class: "s-review-card-container" }, this.renderSlider(), this.renderSingleImage(), renderDivider(), h("div", { key: '490953d92b6e4437f3d4ffbbabc45babf2289224', class: "s-review-card-content" }, this.renderHeader(), h("p", { key: '8960b58c5eab8a89834d5d73f6d941d03898224a', class: "s-review-card-review-content", innerHTML: this.review?.content }), renderDivider(), this.renderProductInfo()));
|
|
176
176
|
}
|
|
177
177
|
get el() { return this; }
|
|
178
178
|
static get style() { return sallaReviewCardCss; }
|
|
@@ -685,7 +685,7 @@ const SallaReviewsPage$1 = /*@__PURE__*/ proxyCustomElement(class SallaReviewsPa
|
|
|
685
685
|
return options.map(option => (h("option", { key: option.value, value: option.value, selected: option.value === this.sort }, option.label)));
|
|
686
686
|
}
|
|
687
687
|
render() {
|
|
688
|
-
return (h("host", { key: '
|
|
688
|
+
return (h("host", { key: '31750df2834dcfce2f87fe3f18e10e7337aa512d' }, h("div", { key: '5757fa951f0ea25b9bc42f67d06b59f8175a73d8', class: "s-reviews-page-header-wrapper" }, h("h2", { key: 'd8db2aaae4061163e8f719512ae7dd76330dfcf7', class: "s-reviews-page-title" }, this.langTitlesReviews, h("span", { key: '057ffec21309286aca0e5a4bba4e41a9322f775f', class: "s-reviews-page-count" }, "(", this.langRatingReviews, ")")), h("div", { key: 'a85ed89e04fe8004d86927689df954d995e4ad84', class: "s-reviews-page-filter-wrapper" }, h("label", { key: '7eff22ea70a463ea95655c8accf7113cf1a35fad', class: "s-reviews-page-filter-label", htmlFor: "testimonials-filter" }, this.langSorting), h("select", { key: '8895a03ea1c404895386b6d73c21fe35fc4dc811', 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 => {
|
|
689
689
|
this.wrapper = el;
|
|
690
690
|
} }, this.reviews.map(review => (h("salla-review-card", { key: review.id, review: review }))))
|
|
691
691
|
: 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));
|
|
@@ -98,7 +98,7 @@ const SallaReviews$1 = /*@__PURE__*/ proxyCustomElement(class SallaReviews exten
|
|
|
98
98
|
});
|
|
99
99
|
}
|
|
100
100
|
render() {
|
|
101
|
-
return (h("div", { key: '
|
|
101
|
+
return (h("div", { key: '636e5db1fe5a6441a3a779c26e383fec4cba4908', class: "s-reviews-container" }, h("div", { key: '5b2a8c72c8544cf152f811c67c23ed8e07a9af58', class: "s-reviews-header-wrapper" }, h("h1", { key: '786e8cfb33ae5b602de1f889d40307abe3dce582', class: "s-reviews-header" }, this.testimonialText), !!this.displayAllLink ? (h("a", { href: this.displayAllURL, class: "s-reviews-display-all" }, this.displayAllLinkText, h("span", { class: "s-reviews-display-all-icon", innerHTML: IconArrowLeft }))) : null), h("salla-slider", { key: 'f950c968c0b076b365b450a13ffabad4e3e9a4da', centered: true, "slides-per-view": 1, type: "testimonials", class: "s-reviews-testimonials-slider", "controls-outer": true, "auto-play": true, id: `testimonials-${this.source}-slider` }, h("div", { key: 'ca057f133699b406673b2e3dc476c14dc0dd9f79', slot: "items" }, this.reviews.map((item, index) => (h("div", { key: index, class: "s-reviews-swiper-slide" }, h("div", { class: "s-reviews-testimonial" }, h("div", { class: "s-reviews-testimonial__inner" }, h("div", { class: "s-reviews-testimonial__avatar" }, h("img", { src: 'images/s-empty.png', "data-src": item.avatar, alt: item.name ? item.name : 'testimonial-' + index, class: "lazy" })), h("div", { class: "s-reviews-testimonial__text" }, h("p", { innerHTML: item.content }), h("div", { class: "s-reviews-testimonial__name_wrapper" }, h("div", { class: "s-reviews-testimonial__info" }, item.name && h("h2", null, `${item.name}`)), h("div", { class: "s-reviews-testimonial__rating" }, h("salla-rating-stars", { size: "small", value: item.stars })))), h("span", { class: "s-reviews-testimonial__icon", innerHTML: IconQuoteOpen }))))))))));
|
|
102
102
|
}
|
|
103
103
|
static get style() { return sallaReviewsCss; }
|
|
104
104
|
}, [0, "salla-reviews", {
|
|
@@ -165,7 +165,7 @@ const SallaScopees = /*@__PURE__*/ proxyCustomElement(class SallaScopees extends
|
|
|
165
165
|
return salla.onReady();
|
|
166
166
|
}
|
|
167
167
|
render() {
|
|
168
|
-
return (h(Host, { key: '
|
|
168
|
+
return (h(Host, { key: '42ac0a93262d5a6bdd602b97fa636b70c2269635' }, h("salla-modal", { key: '632eca8b8faa74fd990bc5c024befa11d461568f', ref: modal => this.modal = modal, isClosable: !!(this.isOpenedBefore || (this.selection == 'optional')), class: "s-scopes-modal", isLoading: this.loading, "has-skeleton": true }, this.loading ?
|
|
169
169
|
h("div", { slot: "loading" }, h("div", { class: "s-scopes-skeleton" }, h("salla-list-tile", { class: "s-scopes-header" }, h("div", { slot: "icon", class: "s-scopes-header-icon" }, h("salla-skeleton", { type: "circle" })), h("div", { slot: "title", class: "s-scopes-header-title mb-5" }, h("salla-skeleton", { height: '15px', width: '50%' })), h("div", { slot: "subtitle", class: "s-scopes-header-subtitle" }, h("salla-skeleton", { height: '10px' }), h("salla-skeleton", { height: '10px', width: '75%' }))), h("div", { class: "s-scopes-skeleton-search" }, h("salla-skeleton", { height: '10px', width: '50%' }), h("salla-skeleton", { height: '30px', width: '100%' })), h("div", { class: "s-scopes-skeleton-scopes" }, h("salla-skeleton", { height: '10px', width: '30%' }), h("salla-skeleton", { height: '10px', width: '25%' }), h("salla-skeleton", { height: '10px', width: '30%' }), h("salla-skeleton", { height: '10px', width: '25%' }), h("salla-skeleton", { height: '10px', width: '30%' }), h("salla-skeleton", { height: '10px', width: '25%' }), h("salla-skeleton", { height: '10px', width: '30%' }), h("salla-skeleton", { height: '10px', width: '25%' })), h("div", { class: "s-scopes-skeleton-btn" }, h("salla-skeleton", { height: '40px', width: '100%' }))))
|
|
170
170
|
:
|
|
171
171
|
[h("salla-list-tile", { class: this.originalScopesList?.length ? "s-scopes-header block" : "s-hidden" }, h("div", { slot: "icon", class: "s-scopes-header-icon", innerHTML: StoreAlt }), h("div", { slot: "title", class: "s-scopes-header-title" }, salla.lang.get('blocks.scope.you_are_browse_store_from')), h("div", { slot: "subtitle", class: "s-scopes-header-subtitle" }, !!this.selected_scope ? this.selected_scope.name : "")), h("div", { class: "s-scopes-wrap" }, !!this.originalScopesList?.length && h("h4", { class: "s-scopes-title" }, this.getFormTitle()), this.originalScopesList?.length > this.searchDisplayLimit ?
|
|
@@ -126,12 +126,12 @@ const SallaSearch$1 = /*@__PURE__*/ proxyCustomElement(class SallaSearch extends
|
|
|
126
126
|
this.inputValue.length < 3 ? this.container.classList.remove('s-search-no-results') : '';
|
|
127
127
|
}
|
|
128
128
|
render() {
|
|
129
|
-
const searchContent = h("div", { key: '
|
|
130
|
-
h("salla-button", { loading: this.loading, class: { 's-search-action': true, 's-search-action-oval': this.oval }, onClick: () => this.handleActionClick() }, !this.loading && h("span", { innerHTML: Search })) : null), h("div", { key: '
|
|
129
|
+
const searchContent = h("div", { key: 'fe1ad73a7d7cdc9bfacb43e5c8f1b2d2c5983f9e', class: { 's-search-container': true, 's-search-inline': this.inline }, ref: container => this.container = container }, h("div", { key: 'df9c5af32950d9fc1ec30f46054630244fd2e2c1', class: "s-search-input-wrapper" }, h("span", { key: 'f4c1788bcd50992364e52388e425cc19c0906ec5', class: "s-search-icon-wrap" }, h("span", { key: 'a46da8c6f02e4970c903dc73d3d4a4e107a543f4', class: "s-search-icon", innerHTML: this.loading ? '<i class="s-search-spinner-loader"/>' : Search })), h("input", { key: 'af5fff2641e6416f06c51c01e19e007c6ff43e32', type: "search", enterkeyhint: "search", autocomplete: "off", class: "s-search-input", placeholder: salla.lang.get('blocks.header.search_placeholder'), onInput: (e) => this.limitWordsAndSearch(e), onKeyDown: e => this.handleKeyDown(e), ref: input => this.searchInput = input, style: { height: this.height + 'px', borderRadius: this.oval ? this.height / 2 + 'px' : '' } }), this.showAction ?
|
|
130
|
+
h("salla-button", { loading: this.loading, class: { 's-search-action': true, 's-search-action-oval': this.oval }, onClick: () => this.handleActionClick() }, !this.loading && h("span", { innerHTML: Search })) : null), h("div", { key: 'e742cf41fdf23b37a46324df3bac24abc2c9bf03', class: "s-search-results" }, this.results?.data.map((product) => h("a", { href: product.url + '?from=search-bar', class: { "s-search-product": true, 's-search-product-not-available': !product.is_available }, innerHTML: this.productSlot
|
|
131
131
|
.replace(/\{name\}/g, product.name)
|
|
132
132
|
.replace(/\{price\}/g, product.price ? salla.money(product.price) : '')
|
|
133
133
|
.replace(/\{regular_price\}/g, product.is_on_sale && product.regular_price ? salla.money(product.regular_price) : '')
|
|
134
|
-
.replace(/\{image\}/g, product.image.url) })), h("p", { key: '
|
|
134
|
+
.replace(/\{image\}/g, product.image.url) })), h("p", { key: 'bea643f12fa014f6df1dee41a1a8ee8c41022458', ref: el => this.noResults = el, class: "s-search-no-results-placeholder" }, salla.lang.get('common.elements.no_options'))));
|
|
135
135
|
return (this.inline ?
|
|
136
136
|
h("div", { class: "s-search-modal" }, searchContent)
|
|
137
137
|
:
|
|
@@ -27,7 +27,7 @@ const SallaSkeleton = /*@__PURE__*/ proxyCustomElement(class SallaSkeleton exten
|
|
|
27
27
|
's-skeleton-item': true,
|
|
28
28
|
's-skeleton-item-circular': this.type == 'circle',
|
|
29
29
|
};
|
|
30
|
-
return (h(Host, { key: '
|
|
30
|
+
return (h(Host, { key: 'df1344797b9cbe42331625a2a1f432e07d6bd9ef', class: "s-skeleton-wrapper", style: { width: this.width, height: this.height } }, h("div", { key: 'b56611551bb2b2bcb02b46240e30f88e2ea7aea5', class: classes }, "\u00A0")));
|
|
31
31
|
}
|
|
32
32
|
static get style() { return sallaSkeletonCss; }
|
|
33
33
|
}, [0, "salla-skeleton", {
|
|
@@ -523,7 +523,7 @@ const SallaSlider = /*@__PURE__*/ proxyCustomElement(class SallaSlider extends H
|
|
|
523
523
|
classes += this.verticalThumbs ? ' s-slider-vertical ' : ' s-slider-horizontal ';
|
|
524
524
|
classes += this.arrowsCentered ? ' s-slider-v-centered ' : '';
|
|
525
525
|
classes += this.gridThumbs ? ' s-slider-with-grid-thumbs ' : '';
|
|
526
|
-
return (h(Host, { key: '
|
|
526
|
+
return (h(Host, { key: '85e91dde02b7f32655d0ac10e5abb7f9e49d7157', class: 's-slider-wrapper ' + classes }, this.blockTitle || this.showControls ?
|
|
527
527
|
h("div", { class: "s-slider-block__title" }, this.blockTitle ?
|
|
528
528
|
h("div", { class: "s-slider-block__title-right" }, h("h2", null, this.blockTitle), this.blockSubtitle ? h("p", { innerHTML: this.blockSubtitle }) : '')
|
|
529
529
|
: '', h("div", { class: "s-slider-block__title-left" }, this.displayAllUrl ?
|
|
@@ -531,7 +531,7 @@ const SallaSlider = /*@__PURE__*/ proxyCustomElement(class SallaSlider extends H
|
|
|
531
531
|
: '', this.showControls ?
|
|
532
532
|
h("div", { class: "s-slider-block__title-nav", dir: "rtl" }, h("button", { "aria-label": "Previous Slide", class: "s-slider-prev s-slider-nav-arrow" }, h("span", { class: "s-slider-button-icon", innerHTML: this.direction == 'rtl' ? ArrowRightIcon : ArrowLeftIcon })), h("button", { "aria-label": "Next Slide", class: "s-slider-next s-slider-nav-arrow" }, h("span", { class: "s-slider-button-icon", innerHTML: this.direction == 'rtl' ? ArrowLeftIcon : ArrowRightIcon })))
|
|
533
533
|
: ''))
|
|
534
|
-
: '', h("div", { key: '
|
|
534
|
+
: '', h("div", { key: '8842ac56011138fd8456257bff568919c9ce8867', class: "swiper s-slider-container", ref: el => this.sliderContainer = el, dir: this.vertical ? "ltr" : this.direction }, h("slot", { key: '17fb40e69031d4c329df9d00fb75443d0ff9ba0c' }), h("div", { key: 'b8f42b180a271b4a873d99024251705e9d76adde', class: "swiper-wrapper s-slider-swiper-wrapper", ref: el => this.sliderWrapper = el }, h("slot", { key: '82ef4871810000d0b65a24518c6613a6484a2ee9', name: 'items' })), this.pagination ? h("div", { class: "swiper-pagination" }) : ''), this.type == 'thumbs' && this.hasThumbSlot ? h("div", { class: "s-slider-thumbs" }, h("div", { class: "swiper s-slider-thumbs-container", dir: this.getThumbsDirection(), ref: el => this.thumbsSliderContainer = el }, h("div", { class: { "s-slider-swiper-wrapper swiper-wrapper": true, "s-slider-grid-thumbs": this.gridThumbs }, ref: el => this.thumbsSliderWrapper = el }, h("slot", { name: "thumbs" })), this.showThumbsControls ?
|
|
535
535
|
h("div", { class: "s-slider-thumbs-nav", dir: "rtl" }, h("button", { "aria-label": "Previous Slide", class: "s-slider-thumbs-prev s-slider-nav-arrow" }, h("span", { class: "s-slider-button-icon", innerHTML: this.direction == 'rtl' ? ArrowRightIcon : ArrowLeftIcon })), h("button", { "aria-label": "Next Slide", class: "s-slider-thumbs-next s-slider-nav-arrow" }, h("span", { class: "s-slider-button-icon", innerHTML: this.direction == 'rtl' ? ArrowLeftIcon : ArrowRightIcon })))
|
|
536
536
|
: null))
|
|
537
537
|
: null));
|
|
@@ -147,7 +147,7 @@ const SallaSocialShare$1 = /*@__PURE__*/ proxyCustomElement(class SallaSocialSha
|
|
|
147
147
|
window.a2a?.init('page');
|
|
148
148
|
}
|
|
149
149
|
render() {
|
|
150
|
-
return (h("div", { key: '
|
|
150
|
+
return (h("div", { key: 'e104cbf1051f36e7d1055a96b8d42e0f38b70f21', class: "s-social-share-wrapper" }, h("slot", { key: '8519676943448a6b87b1b3df8dd74b78de72aeb9', name: 'widget' }, h("salla-button", { key: '0be8b0bf52f046f6818b530430ce1e636fcd36c2', "aria-label": "Share", onClick: () => this.open(), class: "s-social-share-btn", shape: "icon", fill: "outline", color: "light" }, h("span", { key: 'e637247fec7fd1a0235a410ca3e28fb4e7eff7f3', innerHTML: this.opened ? Cancel : ShareAlt }))), h("ul", { key: '8a378bac1865b26744ad31e6bf7218174b24bdd6', ref: el => this.shareMenu = el, class: "s-social-share-list a2a_kit share", "data-a2a-url": this.url ? this.url : window.location.href, "data-a2a-title": this.urlName ? this.urlName : document.title }, this.platforms.split(',').map(platform => {
|
|
151
151
|
return (h("li", null, h("a", { class: `a2a_button_${platform}`, "aria-label": `Share Via ${platform}` }, this.platformIcons.map((icon) => {
|
|
152
152
|
if (icon.name === platform) {
|
|
153
153
|
return h("span", { class: "s-social-share-icon", innerHTML: icon.icon });
|
|
@@ -56,7 +56,7 @@ const SallaSocial$1 = /*@__PURE__*/ proxyCustomElement(class SallaSocial extends
|
|
|
56
56
|
}
|
|
57
57
|
render() {
|
|
58
58
|
const linksArray = this.getLinksArray();
|
|
59
|
-
return (h(Host, { key: '
|
|
59
|
+
return (h(Host, { key: '385311677990c9c48c682c399a742c5544dcaf43' }, h("ul", { key: '0aa7264032d08d165fa8e701324f4928539596dd', class: "s-social-list" }, linksArray.map((link) => (h("li", { class: "s-social-link" }, h("div", { id: "social-slot", innerHTML: this.socialSlot
|
|
60
60
|
.replace(/\{icon\}/g, this.iconsList[link.type])
|
|
61
61
|
.replace(/\{type\}/g, link.type)
|
|
62
62
|
.replace(/\{link\}/g, link.value.toString()) })))))));
|
|
@@ -32,7 +32,7 @@ const SallaTabContent = /*@__PURE__*/ proxyCustomElement(class SallaTabContent e
|
|
|
32
32
|
's-tabs-content': true,
|
|
33
33
|
's-tabs-content-selected': this.isSelected
|
|
34
34
|
};
|
|
35
|
-
return (h("div", { key: '
|
|
35
|
+
return (h("div", { key: '571a30d15d890516a1382ed25239df46de519a12', class: classes }, h("slot", { key: '4ceb77d0d6fb15f28e1bb51ec842b7a658ccc160' })));
|
|
36
36
|
}
|
|
37
37
|
static get style() { return sallaTabContentCss; }
|
|
38
38
|
}, [4, "salla-tab-content", {
|
|
@@ -58,7 +58,7 @@ const SallaTabHeader = /*@__PURE__*/ proxyCustomElement(class SallaTabHeader ext
|
|
|
58
58
|
's-tabs-active': this.isSelected,
|
|
59
59
|
};
|
|
60
60
|
return [
|
|
61
|
-
h("div", { key: '
|
|
61
|
+
h("div", { key: '01eec3d799fd24f75ee29e65447e166057aed846', class: classes, onClick: this.onClick.bind(this) }, h("slot", { key: '200d5e89d7bf9cf232c997fa14c0384be65001c1' })),
|
|
62
62
|
];
|
|
63
63
|
}
|
|
64
64
|
static get style() { return sallaTabHeaderCss; }
|
|
@@ -51,7 +51,7 @@ const SallaTabs = /*@__PURE__*/ proxyCustomElement(class SallaTabs extends HTMLE
|
|
|
51
51
|
}
|
|
52
52
|
render() {
|
|
53
53
|
return [
|
|
54
|
-
h("div", { key: '
|
|
54
|
+
h("div", { key: '11dca6efd64c797274f2b71aa10426fbdf08d351', class: "s-tabs" }, h("div", { key: '9afd9c6a09728218cddc084c77f417d0249bdfd9', class: "s-tabs-header" }, h("slot", { key: 'eef1f2faed6b440c592e51f6d1205e140584b070', name: "header" })), h("div", { key: 'adb5bd9c1af2ba78c173eb3fbd5c73c0513ccca5', class: "s-tabs-content-wrapper" }, h("slot", { key: 'db9eaa79d095ef71fb1df1ab96ddbb925ec59b40', name: "content" })))
|
|
55
55
|
];
|
|
56
56
|
}
|
|
57
57
|
get host() { return this; }
|