@salla.sa/twilight-components 2.10.2 → 2.10.4

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.
Files changed (54) hide show
  1. package/dist/cjs/{app-globals-0a1abeac.js → app-globals-6d8fd0d2.js} +1 -1
  2. package/dist/cjs/index-1d2b3370.js +2 -6
  3. package/dist/cjs/loader.cjs.js +2 -2
  4. package/dist/cjs/{salla-button_35.cjs.entry.js → salla-button_37.cjs.entry.js} +364 -10
  5. package/dist/cjs/twilight.cjs.js +2 -2
  6. package/dist/collection/collection-manifest.json +1 -0
  7. package/dist/collection/components/salla-datetime-picker/salla-datetime-picker.js +3 -0
  8. package/dist/collection/components/salla-map/salla-map.js +39 -4
  9. package/dist/collection/components/salla-product-options/interfaces.js +25 -0
  10. package/dist/collection/components/salla-product-options/salla-product-options.css +0 -0
  11. package/dist/collection/components/salla-product-options/salla-product-options.js +422 -0
  12. package/dist/collection/components/salla-quick-order/salla-quick-order.js +2 -2
  13. package/dist/collection/components/salla-slider/salla-slider.js +37 -3
  14. package/dist/collection/components/salla-user-menu/salla-user-menu.js +4 -2
  15. package/dist/components/index.d.ts +1 -0
  16. package/dist/components/index.js +2 -1
  17. package/dist/components/salla-conditional-fields.js +1 -94
  18. package/dist/{esm/salla-conditional-fields.entry.js → components/salla-conditional-fields2.js} +22 -7
  19. package/dist/components/salla-datetime-picker2.js +3 -0
  20. package/dist/components/salla-map.js +38 -3
  21. package/dist/components/salla-product-options.d.ts +11 -0
  22. package/dist/components/salla-product-options.js +270 -0
  23. package/dist/components/salla-quick-order.js +2 -2
  24. package/dist/components/salla-slider2.js +20 -3
  25. package/dist/components/salla-user-menu.js +4 -2
  26. package/dist/esm/{app-globals-d3b05078.js → app-globals-49168536.js} +1 -1
  27. package/dist/esm/index-f1d446ac.js +2 -6
  28. package/dist/esm/loader.js +2 -2
  29. package/dist/esm/{salla-button_35.entry.js → salla-button_37.entry.js} +363 -11
  30. package/dist/esm/twilight.js +2 -2
  31. package/dist/esm-es5/{app-globals-d3b05078.js → app-globals-49168536.js} +2 -2
  32. package/dist/esm-es5/index-f1d446ac.js +2 -2
  33. package/dist/esm-es5/loader.js +1 -1
  34. package/dist/esm-es5/{salla-button_35.entry.js → salla-button_37.entry.js} +4 -4
  35. package/dist/esm-es5/twilight.js +1 -1
  36. package/dist/twilight/p-49a71773.system.js +4 -0
  37. package/dist/twilight/{p-9d458384.entry.js → p-d5f8a6dd.entry.js} +5 -5
  38. package/dist/twilight/{p-95180d48.system.entry.js → p-e7ce5d86.system.entry.js} +7 -7
  39. package/dist/twilight/{p-70235d2a.system.js → p-f03909a5.system.js} +2 -2
  40. package/dist/twilight/{p-1b14dc52.js → p-f6948417.js} +2 -2
  41. package/dist/twilight/twilight.esm.js +1 -1
  42. package/dist/twilight/twilight.js +1 -1
  43. package/dist/types/components/salla-map/salla-map.d.ts +3 -0
  44. package/dist/types/components/salla-product-options/interfaces.d.ts +133 -0
  45. package/dist/types/components/salla-product-options/salla-product-options.d.ts +89 -0
  46. package/dist/types/components/salla-slider/salla-slider.d.ts +8 -0
  47. package/dist/types/components/salla-user-menu/salla-user-menu.d.ts +1 -0
  48. package/dist/types/components.d.ts +85 -0
  49. package/package.json +5 -4
  50. package/dist/cjs/salla-conditional-fields.cjs.entry.js +0 -88
  51. package/dist/esm-es5/salla-conditional-fields.entry.js +0 -4
  52. package/dist/twilight/p-5d3cb89c.system.entry.js +0 -4
  53. package/dist/twilight/p-6a3883ae.entry.js +0 -4
  54. package/dist/twilight/p-97f66179.system.js +0 -4
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import{p as e,w as l,d as a,N as t,a as o,b as i}from"./p-7dc66c07.js";import{g as r}from"./p-1b14dc52.js";import"./p-f84bae34.js";(()=>{e.l=l.__cssshim;const i=Array.from(a.querySelectorAll("script")).find((e=>new RegExp(`/${t}(\\.esm)?\\.js($|\\?|#)`).test(e.src)||e.getAttribute("data-stencil-namespace")===t)),r={};return r.resourcesUrl=new URL(".",new URL(i.getAttribute("data-resources-url")||i.src,l.location.href)).href,((e,o)=>{const i=`__sc_import_${t.replace(/\s|-/g,"_")}`;try{l[i]=new Function("w",`return import(w);//${Math.random()}`)}catch(t){const r=new Map;l[i]=t=>{const s=new URL(t,e).href;let n=r.get(s);if(!n){const e=a.createElement("script");e.type="module",e.crossOrigin=o.crossOrigin,e.src=URL.createObjectURL(new Blob([`import * as m from '${s}'; window.${i}.m = m;`],{type:"application/javascript"})),n=new Promise((a=>{e.onload=()=>{a(l[i].m),e.remove()}})),r.set(s,n),a.head.appendChild(e)}return n}}})(r.resourcesUrl,i),l.customElements?o(r):__sc_import_twilight("./p-5db948f2.js").then((()=>r))})().then((e=>(r(),i(JSON.parse('[["p-9d458384",[[4,"salla-gifting",{"productId":[2,"product-id"],"sectionTitle":[32],"sectionSubtitle":[32],"sectionBtnText":[32],"giftDetails":[32],"selectImageForYourGift":[32],"selectImageOrUpload":[32],"selectGiftMessage":[32],"giftCustomText":[32],"textId":[32],"incorrectGiftText":[32],"nextStep":[32],"senderNameLabel":[32],"receiverNameFieldLabel":[32],"receiverMobileFieldLabel":[32],"receiverEmailFieldLabel":[32],"emailPlaceholder":[32],"sendLater":[32],"selectSendDateAndTime":[32],"canNotEditOrderAfterSelectDate":[32],"sendGift":[32],"donationRequired":[32],"step1Elems":[32],"step2Elems":[32],"stepsWrapper":[32],"textArea":[32],"imageCover":[32],"textSelect":[32],"customTextArea":[32],"calendarFormGroup":[32],"currentStep":[32],"showCalendar":[32],"showGiftText":[32],"currentLang":[32],"parentClass":[32],"errors":[32],"gift":[32],"selectedGiftTextOption":[32],"showTextArea":[32],"selectedImage":[32],"uploadedImage":[32],"selectedText":[32],"senderName":[32],"errorMessage":[32],"hasError":[32],"quantity":[32],"deliveryDate":[32],"timeZone":[32],"receiverName":[32],"receiverMobile":[32],"receiverCountryCode":[32],"receiverEmail":[32],"open":[64],"close":[64],"goToStep2":[64]}],[4,"salla-loyalty",{"prizePoints":[8,"prize-points"],"customerPoints":[2,"customer-points"],"prizeTitle":[1,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"hasError":[32],"errorMessage":[32],"translationLoaded":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"placeholder_title":[32],"placeholder_description":[32],"modal_title":[32],"hasError":[32],"open":[64],"close":[64]}],[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"hasError":[32],"errorMessage":[32],"productID":[32],"translationLoaded":[32],"addToCartLabel":[32],"open":[64],"showOffer":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"hasError":[32],"errorMessage":[32],"translationLoaded":[32],"open":[64],"close":[64]}],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"translationLoaded":[32],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"selected_scope":[32],"isOpenedBefore":[32],"hasError":[32],"loading":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"translationLoaded":[32],"languages":[32],"currencies":[32],"hasError":[32],"errorMessage":[32],"open":[64],"close":[64],"submit":[64]}],[4,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"supportWebAuth":[516,"support-web-auth"],"currentTabName":[32],"regType":[32],"translationLoaded":[32],"title":[32],"emailErrorMsg":[32],"firstNameErrorMsg":[32],"lastNameErrorMsg":[32],"open":[64]},[[8,"verified","onVerified"]]],[0,"salla-quick-order",{"quickOrderTitle":[1025,"quick-order-title"],"subTitle":[1025,"sub-title"],"payButtonTitle":[1025,"pay-button-title"],"confirmPayButtonTitle":[1025,"confirm-pay-button-title"],"agreementText":[1025,"agreement-text"],"isEmailRequired":[1028,"is-email-required"],"productId":[1025,"product-id"],"thanksMessage":[1025,"thanks-message"],"quickOrderStyle":[1025,"quick-order-style"],"user":[32],"isAvailable":[32],"oneClick":[32],"expanded":[32],"isTermsRequired":[32],"countryCode":[32],"submitSucess":[32],"placeHolderEmail":[32],"emailOptional":[32],"agreementShowText":[32],"agreementModalHead":[32],"userNameLabel":[32],"termsChecked":[32]}],[0,"salla-user-settings",{"isNotifiable":[516,"is-notifiable"],"deactivateAccount":[32],"promotionalMsgs":[32],"deactivateDesc":[32],"promotionalMsgsDesc":[32],"sorryForLeavingText":[32],"warningText":[32],"keepAccount":[32],"buttonLoading":[32]}],[4,"salla-map",{"readonly":[4],"searchable":[1028],"lat":[1026],"lng":[1026],"apiKey":[1025,"api-key"],"zoom":[1026],"theme":[1025],"modalActivityTitle":[32],"confirmButtonTitle":[32],"locateButtonTitle":[32],"locateButtonEdit":[32],"searchInputValue":[32],"searchInput":[32],"mapElement":[32],"open":[64]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"translationLoaded":[32],"results":[32],"loading":[32],"typing":[32],"debounce":[32],"search_term":[32]},[[0,"keydown","handleKeyDown"]]],[0,"salla-comment-form",{"type":[1],"showAvatar":[4,"show-avatar"],"itemId":[8,"item-id"],"placeholder":[32],"submitText":[32],"canComment":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[513],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"convertedPlatforms":[32],"open":[64]}],[4,"salla-cart-summary",{"cartSummaryCount":[32],"cartSummaryTotal":[32],"animateToCart":[64]}],[4,"salla-color-picker",{"color":[1],"placement":[8],"format":[1],"showCancelButton":[4,"show-cancel-button"],"showTextField":[4,"show-text-field"],"enableAlpha":[4,"enable-alpha"],"widgetColor":[32],"setPickerOption":[64],"movePopUp":[64],"setColorValue":[64],"openPicker":[64],"closePicker":[64],"destroyPicker":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[4,"salla-quantity-input",{"quantity":[32],"decrease":[64],"increase":[64],"setValue":[64]}],[0,"salla-user-menu",{"inline":[516],"avatarOnly":[516,"avatar-only"],"showHeader":[516,"show-header"],"relativeDropdown":[516,"relative-dropdown"],"accountLoading":[32],"opened":[32],"notifications":[32],"orders":[32],"pending_orders":[32],"wishlist":[32],"profile":[32],"rating":[32],"logout":[32],"hello":[32],"first_name":[32],"last_name":[32],"avatar":[32],"badges":[32],"OrderUpdate":[32]}],[0,"salla-product-availability",{"channels":[1],"productId":[2,"product-id"],"isSubscribed":[1028,"is-subscribed"],"translationLoaded":[32],"title_":[32],"isVisitorSubscribed":[32]}],[4,"salla-verify",{"display":[1],"type":[1025],"autoReload":[4,"auto-reload"],"supportWebAuth":[4,"support-web-auth"],"translationLoaded":[32],"title":[32],"resendAfter":[32],"isProfileVerify":[32],"getCode":[64],"open":[64]}],[0,"salla-datetime-picker",{"value":[1025],"placeholder":[1],"allowInput":[4,"allow-input"],"allowInvalidPreload":[4,"allow-invalid-preload"],"altFormat":[1,"alt-format"],"altInput":[4,"alt-input"],"altInputClass":[1,"alt-input-class"],"appendTo":[16],"ariaDateFormat":[1,"aria-date-format"],"autoFillDefaultTime":[4,"auto-fill-default-time"],"clickOpens":[4,"click-opens"],"closeOnSelect":[4,"close-on-select"],"conjunction":[1],"dateFormat":[1,"date-format"],"defaultDate":[8,"default-date"],"defaultHour":[2,"default-hour"],"defaultMinute":[2,"default-minute"],"defaultSeconds":[2,"default-seconds"],"disable":[16],"disableMobile":[4,"disable-mobile"],"enable":[16],"enableSeconds":[4,"enable-seconds"],"enableTime":[4,"enable-time"],"formatDate":[16],"hourIncrement":[2,"hour-increment"],"inline":[4],"locale":[1],"maxDate":[8,"max-date"],"maxTime":[8,"max-time"],"minDate":[8,"min-date"],"minTime":[8,"min-time"],"minuteIncrement":[2,"minute-increment"],"mode":[1],"monthSelectorType":[1,"month-selector-type"],"nextArrow":[1,"next-arrow"],"noCalendar":[4,"no-calendar"],"dateParser":[16],"position":[1],"positionElement":[16],"prevArrow":[1,"prev-arrow"],"shorthandCurrentMonth":[4,"shorthand-current-month"],"static":[4],"showMonths":[2,"show-months"],"time_24hr":[4,"time_-2-4hr"],"weekNumbers":[4,"week-numbers"],"wrap":[4]}],[0,"salla-file-upload",{"required":[4],"disabled":[4],"allowDrop":[4,"allow-drop"],"allowBrowse":[4,"allow-browse"],"allowPaste":[4,"allow-paste"],"allowMultiple":[4,"allow-multiple"],"allowReplace":[4,"allow-replace"],"allowRevert":[4,"allow-revert"],"allowRemove":[4,"allow-remove"],"allowProcess":[4,"allow-process"],"allowReorder":[4,"allow-reorder"],"storeAsFile":[4,"store-as-file"],"forceRevert":[4,"force-revert"],"maxFilesCount":[2,"max-files-count"],"maxParallelUploads":[2,"max-parallel-uploads"],"checkValidity":[4,"check-validity"],"itemInsertLocation":[1,"item-insert-location"],"itemInsertInterval":[2,"item-insert-interval"],"credits":[4],"dropOnPage":[4,"drop-on-page"],"dropOnElement":[4,"drop-on-element"],"dropValidation":[4,"drop-validation"],"ignoredFiles":[16],"serverConfig":[1,"server-config"],"instantUpload":[4,"instant-upload"],"chunkUploads":[4,"chunk-uploads"],"chunkForce":[4,"chunk-force"],"chunkSize":[2,"chunk-size"],"chunkRetryDelays":[16],"labelDecimalSeparator":[1,"label-decimal-separator"],"labelThousandsSeparator":[1,"label-thousands-separator"],"labelIdle":[1,"label-idle"],"labelInvalidField":[1,"label-invalid-field"],"labelFileWaitingForSize":[1,"label-file-waiting-for-size"],"labelFileSizeNotAvailable":[1,"label-file-size-not-available"],"labelFileLoading":[1,"label-file-loading"],"labelFileLoadError":[1,"label-file-load-error"],"labelFileProcessing":[1,"label-file-processing"],"labelFileProcessingComplete":[1,"label-file-processing-complete"],"labelFileProcessingAborted":[1,"label-file-processing-aborted"],"labelFileProcessingError":[1,"label-file-processing-error"],"labelFileProcessingRevertError":[1,"label-file-processing-revert-error"],"labelFileRemoveError":[1,"label-file-remove-error"],"labelTapToCancel":[1,"label-tap-to-cancel"],"labelTapToRetry":[1,"label-tap-to-retry"],"labelTapToUndo":[1,"label-tap-to-undo"],"labelButtonRemoveItem":[1,"label-button-remove-item"],"labelButtonAbortItemLoad":[1,"label-button-abort-item-load"],"labelButtonRetryItemLoad":[1,"label-button-retry-item-load"],"labelButtonAbortItemProcessing":[1,"label-button-abort-item-processing"],"labelButtonUndoItemProcessing":[1,"label-button-undo-item-processing"],"labelButtonRetryItemProcessing":[1,"label-button-retry-item-processing"],"labelButtonProcessItem":[1,"label-button-process-item"],"iconRemove":[1,"icon-remove"],"iconProcess":[1,"icon-process"],"iconRetry":[1,"icon-retry"],"iconUndo":[1,"icon-undo"],"pond":[32],"files":[32],"appendFile":[64]}],[0,"salla-rating-stars",{"name":[1],"size":[1],"value":[2]}],[4,"salla-tab-content",{"name":[1],"isSelected":[32],"getChild":[64]}],[4,"salla-tab-header",{"name":[1],"activeClass":[1,"active-class"],"height":[8],"centered":[4],"isSelected":[32],"getChild":[64]}],[4,"salla-tabs",{"backgroundColor":[1,"background-color"],"vertical":[4]},[[0,"tabSelected","onSelectedTab"]]],[4,"salla-slider",{"blockTitle":[513,"block-title"],"blockSubtitle":[513,"block-subtitle"],"displayAllUrl":[513,"display-all-url"],"verticalThumbs":[516,"vertical-thumbs"],"showControls":[516,"show-controls"],"controlsOuter":[516,"controls-outer"],"showThumbsControls":[4,"show-thumbs-controls"],"autoPlay":[4,"auto-play"],"slidesPerView":[1,"slides-per-view"],"pagination":[4],"centered":[4],"loop":[4],"type":[1],"sliderConfig":[520,"slider-config"],"thumbsConfig":[520,"thumbs-config"],"currentIndex":[32],"isEnd":[32],"isBeginning":[32],"isRTL":[32],"swiperScript":[32],"displayAllTitle":[32],"slideTo":[64],"slideNext":[64],"slidePrev":[64],"slideToLoop":[64],"slideNextLoop":[64],"slidePrevLoop":[64],"slideReset":[64],"slideToClosest":[64],"update":[64],"updateAutoHeight":[64],"updateSlides":[64],"updateProgress":[64],"updateSlidesClasses":[64],"getSlides":[64]}],[4,"salla-list-tile",{"href":[1],"target":[1]}],[0,"salla-tel-input",{"phone":[1025],"name":[1],"countryCode":[1025,"country-code"],"mobileRequired":[32],"countryCodeLabel":[32],"mobileLabel":[32],"tooShort":[32],"tooLong":[32],"invalidCountryCode":[32],"invalidNumber":[32],"errorMap":[32],"getValues":[64],"isValid":[64]}],[4,"salla-placeholder",{"icon":[1],"alignment":[1],"iconSize":[1,"icon-size"],"translationLoaded":[32]}],[0,"salla-skeleton",{"type":[1],"width":[1],"height":[1]}],[4,"salla-modal",{"isClosable":[1028,"is-closable"],"width":[513],"position":[513],"visible":[516],"hasSkeleton":[516,"has-skeleton"],"isLoading":[1540,"is-loading"],"subTitleFirst":[4,"sub-title-first"],"noPadding":[4,"no-padding"],"subTitle":[1,"sub-title"],"centered":[4],"iconStyle":[1,"icon-style"],"modalTitle":[32],"open":[64],"close":[64],"setTitle":[64],"loading":[64],"stopLoading":[64]},[[0,"keyup","handleKeyUp"]]],[4,"salla-button",{"shape":[513],"color":[513],"fill":[513],"size":[513],"width":[513],"loading":[516],"disabled":[516],"loaderPosition":[1,"loader-position"],"href":[1],"load":[64],"stop":[64],"setText":[64],"disable":[64],"enable":[64]}],[0,"salla-loading",{"size":[8],"width":[8],"color":[1],"bgColor":[1,"bg-color"]}]]],["p-dbb379ce",[[4,"salla-add-product-button",{"channels":[513],"quantity":[514],"donatingAmount":[514,"donating-amount"],"productId":[520,"product-id"],"productStatus":[513,"product-status"],"productType":[513,"product-type"]}]]],["p-6a3883ae",[[4,"salla-conditional-fields",null,[[0,"change","changeHandler"]]]]],["p-82931e46",[[0,"salla-installment",{"price":[1],"language":[1],"currency":[1],"tamaraIsActive":[32],"tabbyIsActive":[32],"spotiiIsActive":[32]}]]],["p-03695034",[[0,"salla-loyalty-prize-item",{"item":[16]}]]],["p-a7bd281c",[[0,"salla-select",{"label":[1],"items":[16],"itemText":[1,"item-text"],"itemValue":[1,"item-value"],"itemDisabled":[1,"item-disabled"],"size":[1],"value":[1032],"autofocus":[4],"clearable":[4],"clearIcon":[1,"clear-icon"],"color":[1],"flat":[4],"disabled":[4],"loading":[4],"loadingColor":[1,"loading-color"],"hint":[1],"persistHint":[4,"persist-hint"],"placeholder":[1],"multiple":[4],"autocomplete":[4],"required":[4],"chips":[4],"shape":[1],"returnObject":[4,"return-object"],"hideDetail":[4,"hide-detail"]}]]]]'),e))));
4
+ import{p as e,w as a,d as l,N as t,a as o,b as i}from"./p-7dc66c07.js";import{g as r}from"./p-f6948417.js";import"./p-f84bae34.js";(()=>{e.l=a.__cssshim;const i=Array.from(l.querySelectorAll("script")).find((e=>new RegExp(`/${t}(\\.esm)?\\.js($|\\?|#)`).test(e.src)||e.getAttribute("data-stencil-namespace")===t)),r={};return r.resourcesUrl=new URL(".",new URL(i.getAttribute("data-resources-url")||i.src,a.location.href)).href,((e,o)=>{const i=`__sc_import_${t.replace(/\s|-/g,"_")}`;try{a[i]=new Function("w",`return import(w);//${Math.random()}`)}catch(t){const r=new Map;a[i]=t=>{const s=new URL(t,e).href;let n=r.get(s);if(!n){const e=l.createElement("script");e.type="module",e.crossOrigin=o.crossOrigin,e.src=URL.createObjectURL(new Blob([`import * as m from '${s}'; window.${i}.m = m;`],{type:"application/javascript"})),n=new Promise((l=>{e.onload=()=>{l(a[i].m),e.remove()}})),r.set(s,n),l.head.appendChild(e)}return n}}})(r.resourcesUrl,i),a.customElements?o(r):__sc_import_twilight("./p-5db948f2.js").then((()=>r))})().then((e=>(r(),i(JSON.parse('[["p-d5f8a6dd",[[4,"salla-gifting",{"productId":[2,"product-id"],"sectionTitle":[32],"sectionSubtitle":[32],"sectionBtnText":[32],"giftDetails":[32],"selectImageForYourGift":[32],"selectImageOrUpload":[32],"selectGiftMessage":[32],"giftCustomText":[32],"textId":[32],"incorrectGiftText":[32],"nextStep":[32],"senderNameLabel":[32],"receiverNameFieldLabel":[32],"receiverMobileFieldLabel":[32],"receiverEmailFieldLabel":[32],"emailPlaceholder":[32],"sendLater":[32],"selectSendDateAndTime":[32],"canNotEditOrderAfterSelectDate":[32],"sendGift":[32],"donationRequired":[32],"step1Elems":[32],"step2Elems":[32],"stepsWrapper":[32],"textArea":[32],"imageCover":[32],"textSelect":[32],"customTextArea":[32],"calendarFormGroup":[32],"currentStep":[32],"showCalendar":[32],"showGiftText":[32],"currentLang":[32],"parentClass":[32],"errors":[32],"gift":[32],"selectedGiftTextOption":[32],"showTextArea":[32],"selectedImage":[32],"uploadedImage":[32],"selectedText":[32],"senderName":[32],"errorMessage":[32],"hasError":[32],"quantity":[32],"deliveryDate":[32],"timeZone":[32],"receiverName":[32],"receiverMobile":[32],"receiverCountryCode":[32],"receiverEmail":[32],"open":[64],"close":[64],"goToStep2":[64]}],[4,"salla-loyalty",{"prizePoints":[8,"prize-points"],"customerPoints":[2,"customer-points"],"prizeTitle":[1,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"hasError":[32],"errorMessage":[32],"translationLoaded":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"placeholder_title":[32],"placeholder_description":[32],"modal_title":[32],"hasError":[32],"open":[64],"close":[64]}],[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"hasError":[32],"errorMessage":[32],"productID":[32],"translationLoaded":[32],"addToCartLabel":[32],"open":[64],"showOffer":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"hasError":[32],"errorMessage":[32],"translationLoaded":[32],"open":[64],"close":[64]}],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"translationLoaded":[32],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"selected_scope":[32],"isOpenedBefore":[32],"hasError":[32],"loading":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"translationLoaded":[32],"languages":[32],"currencies":[32],"hasError":[32],"errorMessage":[32],"open":[64],"close":[64],"submit":[64]}],[4,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"supportWebAuth":[516,"support-web-auth"],"currentTabName":[32],"regType":[32],"translationLoaded":[32],"title":[32],"emailErrorMsg":[32],"firstNameErrorMsg":[32],"lastNameErrorMsg":[32],"open":[64]},[[8,"verified","onVerified"]]],[0,"salla-quick-order",{"quickOrderTitle":[1025,"quick-order-title"],"subTitle":[1025,"sub-title"],"payButtonTitle":[1025,"pay-button-title"],"confirmPayButtonTitle":[1025,"confirm-pay-button-title"],"agreementText":[1025,"agreement-text"],"isEmailRequired":[1028,"is-email-required"],"productId":[1025,"product-id"],"thanksMessage":[1025,"thanks-message"],"quickOrderStyle":[1025,"quick-order-style"],"user":[32],"isAvailable":[32],"oneClick":[32],"expanded":[32],"isTermsRequired":[32],"countryCode":[32],"submitSucess":[32],"placeHolderEmail":[32],"emailOptional":[32],"agreementShowText":[32],"agreementModalHead":[32],"userNameLabel":[32],"termsChecked":[32]}],[0,"salla-user-settings",{"isNotifiable":[516,"is-notifiable"],"deactivateAccount":[32],"promotionalMsgs":[32],"deactivateDesc":[32],"promotionalMsgsDesc":[32],"sorryForLeavingText":[32],"warningText":[32],"keepAccount":[32],"buttonLoading":[32]}],[4,"salla-map",{"readonly":[4],"searchable":[1028],"lat":[1026],"lng":[1026],"apiKey":[1025,"api-key"],"zoom":[1026],"theme":[1025],"modalActivityTitle":[32],"confirmButtonTitle":[32],"locateButtonTitle":[32],"locateButtonEdit":[32],"searchInputValue":[32],"geolocationError":[32],"searchInput":[32],"mapElement":[32],"open":[64]}],[0,"salla-product-options",{"productId":[2,"product-id"],"product":[1],"productDetail":[32],"options":[32],"uploadedImage":[32],"outOfStockText":[32],"donationAmount":[32]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"translationLoaded":[32],"results":[32],"loading":[32],"typing":[32],"debounce":[32],"search_term":[32]},[[0,"keydown","handleKeyDown"]]],[0,"salla-comment-form",{"type":[1],"showAvatar":[4,"show-avatar"],"itemId":[8,"item-id"],"placeholder":[32],"submitText":[32],"canComment":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[513],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"convertedPlatforms":[32],"open":[64]}],[4,"salla-cart-summary",{"cartSummaryCount":[32],"cartSummaryTotal":[32],"animateToCart":[64]}],[4,"salla-color-picker",{"color":[1],"placement":[8],"format":[1],"showCancelButton":[4,"show-cancel-button"],"showTextField":[4,"show-text-field"],"enableAlpha":[4,"enable-alpha"],"widgetColor":[32],"setPickerOption":[64],"movePopUp":[64],"setColorValue":[64],"openPicker":[64],"closePicker":[64],"destroyPicker":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[4,"salla-quantity-input",{"quantity":[32],"decrease":[64],"increase":[64],"setValue":[64]}],[0,"salla-user-menu",{"inline":[516],"avatarOnly":[516,"avatar-only"],"showHeader":[516,"show-header"],"relativeDropdown":[516,"relative-dropdown"],"accountLoading":[32],"opened":[32],"notifications":[32],"orders":[32],"pending_orders":[32],"wishlist":[32],"profile":[32],"rating":[32],"logout":[32],"hello":[32],"first_name":[32],"last_name":[32],"has_red_dot":[32],"avatar":[32],"badges":[32],"OrderUpdate":[32]}],[0,"salla-product-availability",{"channels":[1],"productId":[2,"product-id"],"isSubscribed":[1028,"is-subscribed"],"translationLoaded":[32],"title_":[32],"isVisitorSubscribed":[32]}],[4,"salla-verify",{"display":[1],"type":[1025],"autoReload":[4,"auto-reload"],"supportWebAuth":[4,"support-web-auth"],"translationLoaded":[32],"title":[32],"resendAfter":[32],"isProfileVerify":[32],"getCode":[64],"open":[64]}],[4,"salla-conditional-fields",null,[[0,"change","changeHandler"]]],[0,"salla-rating-stars",{"name":[1],"size":[1],"value":[2]}],[0,"salla-datetime-picker",{"value":[1025],"placeholder":[1],"allowInput":[4,"allow-input"],"allowInvalidPreload":[4,"allow-invalid-preload"],"altFormat":[1,"alt-format"],"altInput":[4,"alt-input"],"altInputClass":[1,"alt-input-class"],"appendTo":[16],"ariaDateFormat":[1,"aria-date-format"],"autoFillDefaultTime":[4,"auto-fill-default-time"],"clickOpens":[4,"click-opens"],"closeOnSelect":[4,"close-on-select"],"conjunction":[1],"dateFormat":[1,"date-format"],"defaultDate":[8,"default-date"],"defaultHour":[2,"default-hour"],"defaultMinute":[2,"default-minute"],"defaultSeconds":[2,"default-seconds"],"disable":[16],"disableMobile":[4,"disable-mobile"],"enable":[16],"enableSeconds":[4,"enable-seconds"],"enableTime":[4,"enable-time"],"formatDate":[16],"hourIncrement":[2,"hour-increment"],"inline":[4],"locale":[1],"maxDate":[8,"max-date"],"maxTime":[8,"max-time"],"minDate":[8,"min-date"],"minTime":[8,"min-time"],"minuteIncrement":[2,"minute-increment"],"mode":[1],"monthSelectorType":[1,"month-selector-type"],"nextArrow":[1,"next-arrow"],"noCalendar":[4,"no-calendar"],"dateParser":[16],"position":[1],"positionElement":[16],"prevArrow":[1,"prev-arrow"],"shorthandCurrentMonth":[4,"shorthand-current-month"],"static":[4],"showMonths":[2,"show-months"],"time_24hr":[4,"time_-2-4hr"],"weekNumbers":[4,"week-numbers"],"wrap":[4]}],[0,"salla-file-upload",{"required":[4],"disabled":[4],"allowDrop":[4,"allow-drop"],"allowBrowse":[4,"allow-browse"],"allowPaste":[4,"allow-paste"],"allowMultiple":[4,"allow-multiple"],"allowReplace":[4,"allow-replace"],"allowRevert":[4,"allow-revert"],"allowRemove":[4,"allow-remove"],"allowProcess":[4,"allow-process"],"allowReorder":[4,"allow-reorder"],"storeAsFile":[4,"store-as-file"],"forceRevert":[4,"force-revert"],"maxFilesCount":[2,"max-files-count"],"maxParallelUploads":[2,"max-parallel-uploads"],"checkValidity":[4,"check-validity"],"itemInsertLocation":[1,"item-insert-location"],"itemInsertInterval":[2,"item-insert-interval"],"credits":[4],"dropOnPage":[4,"drop-on-page"],"dropOnElement":[4,"drop-on-element"],"dropValidation":[4,"drop-validation"],"ignoredFiles":[16],"serverConfig":[1,"server-config"],"instantUpload":[4,"instant-upload"],"chunkUploads":[4,"chunk-uploads"],"chunkForce":[4,"chunk-force"],"chunkSize":[2,"chunk-size"],"chunkRetryDelays":[16],"labelDecimalSeparator":[1,"label-decimal-separator"],"labelThousandsSeparator":[1,"label-thousands-separator"],"labelIdle":[1,"label-idle"],"labelInvalidField":[1,"label-invalid-field"],"labelFileWaitingForSize":[1,"label-file-waiting-for-size"],"labelFileSizeNotAvailable":[1,"label-file-size-not-available"],"labelFileLoading":[1,"label-file-loading"],"labelFileLoadError":[1,"label-file-load-error"],"labelFileProcessing":[1,"label-file-processing"],"labelFileProcessingComplete":[1,"label-file-processing-complete"],"labelFileProcessingAborted":[1,"label-file-processing-aborted"],"labelFileProcessingError":[1,"label-file-processing-error"],"labelFileProcessingRevertError":[1,"label-file-processing-revert-error"],"labelFileRemoveError":[1,"label-file-remove-error"],"labelTapToCancel":[1,"label-tap-to-cancel"],"labelTapToRetry":[1,"label-tap-to-retry"],"labelTapToUndo":[1,"label-tap-to-undo"],"labelButtonRemoveItem":[1,"label-button-remove-item"],"labelButtonAbortItemLoad":[1,"label-button-abort-item-load"],"labelButtonRetryItemLoad":[1,"label-button-retry-item-load"],"labelButtonAbortItemProcessing":[1,"label-button-abort-item-processing"],"labelButtonUndoItemProcessing":[1,"label-button-undo-item-processing"],"labelButtonRetryItemProcessing":[1,"label-button-retry-item-processing"],"labelButtonProcessItem":[1,"label-button-process-item"],"iconRemove":[1,"icon-remove"],"iconProcess":[1,"icon-process"],"iconRetry":[1,"icon-retry"],"iconUndo":[1,"icon-undo"],"pond":[32],"files":[32],"appendFile":[64]}],[4,"salla-tab-content",{"name":[1],"isSelected":[32],"getChild":[64]}],[4,"salla-tab-header",{"name":[1],"activeClass":[1,"active-class"],"height":[8],"centered":[4],"isSelected":[32],"getChild":[64]}],[4,"salla-tabs",{"backgroundColor":[1,"background-color"],"vertical":[4]},[[0,"tabSelected","onSelectedTab"]]],[4,"salla-slider",{"blockTitle":[513,"block-title"],"blockSubtitle":[513,"block-subtitle"],"displayAllUrl":[513,"display-all-url"],"verticalThumbs":[516,"vertical-thumbs"],"autoHeight":[516,"auto-height"],"showControls":[516,"show-controls"],"controlsOuter":[516,"controls-outer"],"showThumbsControls":[4,"show-thumbs-controls"],"autoPlay":[4,"auto-play"],"slidesPerView":[1,"slides-per-view"],"pagination":[4],"centered":[4],"loop":[4],"type":[1],"sliderConfig":[520,"slider-config"],"thumbsConfig":[520,"thumbs-config"],"currentIndex":[32],"isEnd":[32],"isBeginning":[32],"isRTL":[32],"swiperScript":[32],"displayAllTitle":[32],"slideTo":[64],"slideNext":[64],"slidePrev":[64],"slideToLoop":[64],"slideNextLoop":[64],"slidePrevLoop":[64],"slideReset":[64],"slideToClosest":[64],"update":[64],"updateAutoHeight":[64],"updateSlides":[64],"updateProgress":[64],"updateSlidesClasses":[64],"getSlides":[64]}],[4,"salla-list-tile",{"href":[1],"target":[1]}],[0,"salla-tel-input",{"phone":[1025],"name":[1],"countryCode":[1025,"country-code"],"mobileRequired":[32],"countryCodeLabel":[32],"mobileLabel":[32],"tooShort":[32],"tooLong":[32],"invalidCountryCode":[32],"invalidNumber":[32],"errorMap":[32],"getValues":[64],"isValid":[64]}],[4,"salla-placeholder",{"icon":[1],"alignment":[1],"iconSize":[1,"icon-size"],"translationLoaded":[32]}],[0,"salla-skeleton",{"type":[1],"width":[1],"height":[1]}],[4,"salla-modal",{"isClosable":[1028,"is-closable"],"width":[513],"position":[513],"visible":[516],"hasSkeleton":[516,"has-skeleton"],"isLoading":[1540,"is-loading"],"subTitleFirst":[4,"sub-title-first"],"noPadding":[4,"no-padding"],"subTitle":[1,"sub-title"],"centered":[4],"iconStyle":[1,"icon-style"],"modalTitle":[32],"open":[64],"close":[64],"setTitle":[64],"loading":[64],"stopLoading":[64]},[[0,"keyup","handleKeyUp"]]],[4,"salla-button",{"shape":[513],"color":[513],"fill":[513],"size":[513],"width":[513],"loading":[516],"disabled":[516],"loaderPosition":[1,"loader-position"],"href":[1],"load":[64],"stop":[64],"setText":[64],"disable":[64],"enable":[64]}],[0,"salla-loading",{"size":[8],"width":[8],"color":[1],"bgColor":[1,"bg-color"]}]]],["p-dbb379ce",[[4,"salla-add-product-button",{"channels":[513],"quantity":[514],"donatingAmount":[514,"donating-amount"],"productId":[520,"product-id"],"productStatus":[513,"product-status"],"productType":[513,"product-type"]}]]],["p-82931e46",[[0,"salla-installment",{"price":[1],"language":[1],"currency":[1],"tamaraIsActive":[32],"tabbyIsActive":[32],"spotiiIsActive":[32]}]]],["p-03695034",[[0,"salla-loyalty-prize-item",{"item":[16]}]]],["p-a7bd281c",[[0,"salla-select",{"label":[1],"items":[16],"itemText":[1,"item-text"],"itemValue":[1,"item-value"],"itemDisabled":[1,"item-disabled"],"size":[1],"value":[1032],"autofocus":[4],"clearable":[4],"clearIcon":[1,"clear-icon"],"color":[1],"flat":[4],"disabled":[4],"loading":[4],"loadingColor":[1,"loading-color"],"hint":[1],"persistHint":[4,"persist-hint"],"placeholder":[1],"multiple":[4],"autocomplete":[4],"required":[4],"chips":[4],"shape":[1],"returnObject":[4,"return-object"],"hideDetail":[4,"hide-detail"]}]]]]'),e))));
@@ -117,7 +117,7 @@ var __assign=this&&this.__assign||function(){return(__assign=Object.assign||func
117
117
  var resourcesUrl = scriptElm ? scriptElm.getAttribute('data-resources-url') || scriptElm.src : '';
118
118
  var start = function() {
119
119
  // if src is not present then origin is "null", and new URL() throws TypeError: Failed to construct 'URL': Invalid base URL
120
- var url = new URL('./p-97f66179.system.js', new URL(resourcesUrl, window.location.origin !== 'null' ? window.location.origin : undefined));
120
+ var url = new URL('./p-49a71773.system.js', new URL(resourcesUrl, window.location.origin !== 'null' ? window.location.origin : undefined));
121
121
  System.import(url.href);
122
122
  };
123
123
 
@@ -3,11 +3,13 @@ export declare class SallaMap {
3
3
  private map;
4
4
  private locationModal;
5
5
  private marker;
6
+ host: HTMLElement;
6
7
  modalActivityTitle: string;
7
8
  confirmButtonTitle: string;
8
9
  locateButtonTitle: string;
9
10
  locateButtonEdit: string;
10
11
  searchInputValue: string;
12
+ geolocationError: boolean;
11
13
  searchInput: HTMLInputElement;
12
14
  mapElement: HTMLElement;
13
15
  constructor();
@@ -15,6 +17,7 @@ export declare class SallaMap {
15
17
  private getPositionAddress;
16
18
  private initGoogleMaps;
17
19
  private getCurrentLocation;
20
+ private handleLocationError;
18
21
  /**
19
22
  * Open location component
20
23
  */
@@ -0,0 +1,133 @@
1
+ export declare enum DisplayType {
2
+ COLOR = "color",
3
+ DATE = "date",
4
+ DATETIME = "datetime",
5
+ DONATION = "donation",
6
+ IMAGE = "image",
7
+ MULTIPLE_OPTIONS = "multiple-options",
8
+ NUMBER = "number",
9
+ SINGLE_OPTION = "single-option",
10
+ SPLITTER = "splitter",
11
+ TEXT = "text",
12
+ TEXTAREA = "textarea",
13
+ THUMBNAIL = "thumbnail",
14
+ TIME = "time",
15
+ RADIO = "radio",
16
+ CHECKBOX = "checkbox"
17
+ }
18
+ export interface ProductDetail {
19
+ id: string;
20
+ sku: string;
21
+ name: string;
22
+ description: string;
23
+ url: string;
24
+ promotion_title: string;
25
+ subtitle: string;
26
+ type: string;
27
+ status: string;
28
+ price: number;
29
+ sale_price: number;
30
+ regular_price: number;
31
+ starting_price: null;
32
+ quantity: number;
33
+ max_quantity: number;
34
+ discount_ends: number;
35
+ is_taxable: boolean;
36
+ has_read_more: boolean;
37
+ can_add_note: boolean;
38
+ can_show_remained_quantity: boolean;
39
+ can_upload_file: boolean;
40
+ has_custom_form: boolean;
41
+ is_on_sale: boolean;
42
+ is_hidden_quantity: boolean;
43
+ is_available: boolean;
44
+ is_out_of_stock: boolean;
45
+ weight: null;
46
+ calories: null;
47
+ image: SimpleImage;
48
+ brand: Brand;
49
+ donation?: ProductDonation;
50
+ images: Image[];
51
+ tags: Tag[];
52
+ notify_availability: null;
53
+ rating: Rating;
54
+ options: Option[];
55
+ sold_quantity: number;
56
+ category: Category;
57
+ }
58
+ export interface SimpleImage {
59
+ url: string;
60
+ alt: string;
61
+ }
62
+ export interface Category {
63
+ name: string;
64
+ url: string;
65
+ icon: string;
66
+ }
67
+ export interface ProductDonation {
68
+ target_message?: string;
69
+ collected_amount?: number;
70
+ target_amount?: number;
71
+ target_percent?: number;
72
+ target_end_date?: string;
73
+ can_donate: boolean;
74
+ }
75
+ export interface Image {
76
+ id: number;
77
+ url: string;
78
+ main: boolean;
79
+ three_d_image_url: string;
80
+ alt: string;
81
+ video_url: string;
82
+ type: string;
83
+ sort: number;
84
+ }
85
+ export interface Option {
86
+ id: number;
87
+ name: string;
88
+ required: boolean;
89
+ type: string;
90
+ placeholder: string;
91
+ option_type: string;
92
+ not_same_day_order: boolean;
93
+ availability_range: number;
94
+ from_date_time: null;
95
+ to_date_time: null;
96
+ visibility_condition: null;
97
+ details?: Detail[];
98
+ condition_attributes: string;
99
+ }
100
+ export interface Detail {
101
+ id: number;
102
+ name: string;
103
+ additional_price: number;
104
+ option_value: null | string;
105
+ image: null | string;
106
+ color: null | string;
107
+ is_out: boolean;
108
+ }
109
+ export interface Brand {
110
+ id: string;
111
+ url: string;
112
+ name: string;
113
+ logo: string;
114
+ }
115
+ export interface PreTaxPrice {
116
+ amount: number;
117
+ currency: Currency;
118
+ }
119
+ export declare enum Currency {
120
+ Sar = "SAR"
121
+ }
122
+ export interface Promotion {
123
+ title: string;
124
+ sub_title: string;
125
+ }
126
+ export interface Rating {
127
+ count: number;
128
+ stars: number;
129
+ }
130
+ export interface Tag {
131
+ name: string;
132
+ url: string;
133
+ }
@@ -0,0 +1,89 @@
1
+ import { EventEmitter } from '../../stencil-public-runtime';
2
+ import { Option, ProductDetail } from './interfaces';
3
+ export declare class SallaProductOptions {
4
+ constructor();
5
+ private multipleOptionDom;
6
+ private uploader;
7
+ productDetail: ProductDetail;
8
+ options: Option[];
9
+ uploadedImage: string;
10
+ outOfStockText: string;
11
+ donationAmount: string;
12
+ /**
13
+ * The id of the product to which the options are going to be fetched for.
14
+ */
15
+ productId: number;
16
+ /**
17
+ * Product detail information.
18
+ */
19
+ product: string;
20
+ /**
21
+ * Colors Option Event
22
+ */
23
+ colorSelected: EventEmitter;
24
+ /**
25
+ * Thumbnails Option
26
+ */
27
+ thumbnailSelected: EventEmitter;
28
+ /**
29
+ * Single Select Option
30
+ */
31
+ singleSelectOptionSelected: EventEmitter;
32
+ /**
33
+ * Donation Option
34
+ */
35
+ donationMoneyEntered: EventEmitter;
36
+ /**
37
+ * Text Option
38
+ */
39
+ textOptionEntered: EventEmitter;
40
+ /**
41
+ * Textarea Option
42
+ */
43
+ textareaOptionEntered: EventEmitter;
44
+ /**
45
+ * Number Option
46
+ */
47
+ numberOptionEntered: EventEmitter;
48
+ /**
49
+ * Multi-Select Option
50
+ */
51
+ itemsSelected: EventEmitter<string[]>;
52
+ /**
53
+ * DateTime Selection Option
54
+ */
55
+ dateTimeSelected: EventEmitter;
56
+ /**
57
+ * Date Selection Option
58
+ */
59
+ dateSelected: EventEmitter;
60
+ /**
61
+ * Time Selection Option
62
+ */
63
+ timeSelected: EventEmitter;
64
+ private handleMultiSelectFieldInput;
65
+ /**
66
+ * Image Selection
67
+ */
68
+ private setProductDetail;
69
+ private fetchProductOptions;
70
+ private getDisplayForType;
71
+ render(): any;
72
+ private colorOption;
73
+ private dateOption;
74
+ private datetimeOption;
75
+ private donationOption;
76
+ private getFilepondPlaceholder;
77
+ private setUploaderHeight;
78
+ private selectThumbnail;
79
+ private getServerConfig;
80
+ private imageOption;
81
+ private multipleOptions;
82
+ private numberOption;
83
+ private singleOption;
84
+ private splitterOption;
85
+ private textOption;
86
+ private textareaOption;
87
+ private thumbnailOption;
88
+ private timeOption;
89
+ }
@@ -10,6 +10,9 @@ export declare class SallaSwiper {
10
10
  * Show/hide slider block title
11
11
  */
12
12
  blockTitle: string;
13
+ /**
14
+ * Enable call a specific slide
15
+ */
13
16
  /**
14
17
  * Show/hide slider block sub title
15
18
  */
@@ -22,6 +25,10 @@ export declare class SallaSwiper {
22
25
  * Vertical or Horizontal thumbs slider
23
26
  */
24
27
  verticalThumbs: boolean;
28
+ /**
29
+ * Auto Height slider
30
+ */
31
+ autoHeight: boolean;
25
32
  /**
26
33
  * Show/hide arrows
27
34
  */
@@ -198,6 +205,7 @@ export declare class SallaSwiper {
198
205
  autoplay: boolean;
199
206
  centeredSlides: boolean;
200
207
  slidesPerView: string;
208
+ autoHeight: boolean;
201
209
  lazy: boolean;
202
210
  on: {
203
211
  afterInit: (slider: SwiperType) => void[];
@@ -18,6 +18,7 @@ export declare class SallaUserMenu {
18
18
  hello: string;
19
19
  first_name: string;
20
20
  last_name: string;
21
+ has_red_dot: boolean;
21
22
  avatar: string;
22
23
  badges: any;
23
24
  /**
@@ -917,6 +917,16 @@ export namespace Components {
917
917
  */
918
918
  "productId": number;
919
919
  }
920
+ interface SallaProductOptions {
921
+ /**
922
+ * Product detail information.
923
+ */
924
+ "product": string;
925
+ /**
926
+ * The id of the product to which the options are going to be fetched for.
927
+ */
928
+ "productId": number;
929
+ }
920
930
  interface SallaProductSizeGuide {
921
931
  /**
922
932
  * Hide the size-guide modal window
@@ -1163,6 +1173,10 @@ export namespace Components {
1163
1173
  "width": string;
1164
1174
  }
1165
1175
  interface SallaSlider {
1176
+ /**
1177
+ * Auto Height slider
1178
+ */
1179
+ "autoHeight": boolean;
1166
1180
  /**
1167
1181
  * Enable autoplay - working with `type="carousel" only`
1168
1182
  */
@@ -1465,6 +1479,10 @@ export interface SallaModalCustomEvent<T> extends CustomEvent<T> {
1465
1479
  detail: T;
1466
1480
  target: HTMLSallaModalElement;
1467
1481
  }
1482
+ export interface SallaProductOptionsCustomEvent<T> extends CustomEvent<T> {
1483
+ detail: T;
1484
+ target: HTMLSallaProductOptionsElement;
1485
+ }
1468
1486
  export interface SallaQuickOrderCustomEvent<T> extends CustomEvent<T> {
1469
1487
  detail: T;
1470
1488
  target: HTMLSallaQuickOrderElement;
@@ -1618,6 +1636,12 @@ declare global {
1618
1636
  prototype: HTMLSallaProductAvailabilityElement;
1619
1637
  new (): HTMLSallaProductAvailabilityElement;
1620
1638
  };
1639
+ interface HTMLSallaProductOptionsElement extends Components.SallaProductOptions, HTMLStencilElement {
1640
+ }
1641
+ var HTMLSallaProductOptionsElement: {
1642
+ prototype: HTMLSallaProductOptionsElement;
1643
+ new (): HTMLSallaProductOptionsElement;
1644
+ };
1621
1645
  interface HTMLSallaProductSizeGuideElement extends Components.SallaProductSizeGuide, HTMLStencilElement {
1622
1646
  }
1623
1647
  var HTMLSallaProductSizeGuideElement: {
@@ -1749,6 +1773,7 @@ declare global {
1749
1773
  "salla-offer-modal": HTMLSallaOfferModalElement;
1750
1774
  "salla-placeholder": HTMLSallaPlaceholderElement;
1751
1775
  "salla-product-availability": HTMLSallaProductAvailabilityElement;
1776
+ "salla-product-options": HTMLSallaProductOptionsElement;
1752
1777
  "salla-product-size-guide": HTMLSallaProductSizeGuideElement;
1753
1778
  "salla-quantity-input": HTMLSallaQuantityInputElement;
1754
1779
  "salla-quick-order": HTMLSallaQuickOrderElement;
@@ -2589,6 +2614,60 @@ declare namespace LocalJSX {
2589
2614
  */
2590
2615
  "productId"?: number;
2591
2616
  }
2617
+ interface SallaProductOptions {
2618
+ /**
2619
+ * Colors Option Event
2620
+ */
2621
+ "onColorSelected"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2622
+ /**
2623
+ * Date Selection Option
2624
+ */
2625
+ "onDateSelected"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2626
+ /**
2627
+ * DateTime Selection Option
2628
+ */
2629
+ "onDateTimeSelected"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2630
+ /**
2631
+ * Donation Option
2632
+ */
2633
+ "onDonationMoneyEntered"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2634
+ /**
2635
+ * Multi-Select Option
2636
+ */
2637
+ "onItemsSelected"?: (event: SallaProductOptionsCustomEvent<string[]>) => void;
2638
+ /**
2639
+ * Number Option
2640
+ */
2641
+ "onNumberOptionEntered"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2642
+ /**
2643
+ * Single Select Option
2644
+ */
2645
+ "onSingleSelectOptionSelected"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2646
+ /**
2647
+ * Text Option
2648
+ */
2649
+ "onTextOptionEntered"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2650
+ /**
2651
+ * Textarea Option
2652
+ */
2653
+ "onTextareaOptionEntered"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2654
+ /**
2655
+ * Thumbnails Option
2656
+ */
2657
+ "onThumbnailSelected"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2658
+ /**
2659
+ * Time Selection Option
2660
+ */
2661
+ "onTimeSelected"?: (event: SallaProductOptionsCustomEvent<any>) => void;
2662
+ /**
2663
+ * Product detail information.
2664
+ */
2665
+ "product"?: string;
2666
+ /**
2667
+ * The id of the product to which the options are going to be fetched for.
2668
+ */
2669
+ "productId"?: number;
2670
+ }
2592
2671
  interface SallaProductSizeGuide {
2593
2672
  }
2594
2673
  interface SallaQuantityInput {
@@ -2796,6 +2875,10 @@ declare namespace LocalJSX {
2796
2875
  "width"?: string;
2797
2876
  }
2798
2877
  interface SallaSlider {
2878
+ /**
2879
+ * Auto Height slider
2880
+ */
2881
+ "autoHeight"?: boolean;
2799
2882
  /**
2800
2883
  * Enable autoplay - working with `type="carousel" only`
2801
2884
  */
@@ -3013,6 +3096,7 @@ declare namespace LocalJSX {
3013
3096
  "salla-offer-modal": SallaOfferModal;
3014
3097
  "salla-placeholder": SallaPlaceholder;
3015
3098
  "salla-product-availability": SallaProductAvailability;
3099
+ "salla-product-options": SallaProductOptions;
3016
3100
  "salla-product-size-guide": SallaProductSizeGuide;
3017
3101
  "salla-quantity-input": SallaQuantityInput;
3018
3102
  "salla-quick-order": SallaQuickOrder;
@@ -3059,6 +3143,7 @@ declare module "@stencil/core" {
3059
3143
  "salla-offer-modal": LocalJSX.SallaOfferModal & JSXBase.HTMLAttributes<HTMLSallaOfferModalElement>;
3060
3144
  "salla-placeholder": LocalJSX.SallaPlaceholder & JSXBase.HTMLAttributes<HTMLSallaPlaceholderElement>;
3061
3145
  "salla-product-availability": LocalJSX.SallaProductAvailability & JSXBase.HTMLAttributes<HTMLSallaProductAvailabilityElement>;
3146
+ "salla-product-options": LocalJSX.SallaProductOptions & JSXBase.HTMLAttributes<HTMLSallaProductOptionsElement>;
3062
3147
  "salla-product-size-guide": LocalJSX.SallaProductSizeGuide & JSXBase.HTMLAttributes<HTMLSallaProductSizeGuideElement>;
3063
3148
  "salla-quantity-input": LocalJSX.SallaQuantityInput & JSXBase.HTMLAttributes<HTMLSallaQuantityInputElement>;
3064
3149
  "salla-quick-order": LocalJSX.SallaQuickOrder & JSXBase.HTMLAttributes<HTMLSallaQuickOrderElement>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salla.sa/twilight-components",
3
- "version": "2.10.2",
3
+ "version": "2.10.4",
4
4
  "license": "GPL-3.0",
5
5
  "author": "Salla Team <support@salla.dev> (https://salla.dev)",
6
6
  "bugs": {
@@ -58,6 +58,7 @@
58
58
  "@stencil/react-output-target": "^0.3.1",
59
59
  "@stencil/sass": "1.5.2",
60
60
  "@stencil/vue-output-target": "^0.6.1",
61
+ "@tailwindcss/line-clamp": "^0.4.2",
61
62
  "@types/autoprefixer": "^10.2.0",
62
63
  "@types/jest": "^28.1.6",
63
64
  "@types/puppeteer": "3.0.2",
@@ -75,8 +76,8 @@
75
76
  "typescript": "^4.4.3"
76
77
  },
77
78
  "dependencies": {
78
- "@salla.sa/twilight": "^2.10.1",
79
- "@salla.sa/twilight-tailwind-theme": "^2.10.1",
79
+ "@salla.sa/twilight": "^2.10.4",
80
+ "@salla.sa/twilight-tailwind-theme": "^2.10.4",
80
81
  "animejs": "^3.2.1",
81
82
  "filepond": "^4.30.4",
82
83
  "filepond-plugin-file-validate-size": "^2.2.7",
@@ -91,5 +92,5 @@
91
92
  "vanilla-lazyload": "^17.8.3",
92
93
  "vanilla-picker": "^2.12.1"
93
94
  },
94
- "gitHead": "9aee43eff6238e631dfbaa9ac6262d0fe70b5ee7"
95
+ "gitHead": "89b91e1098184edc112bbb3f9a68be0124f1ffee"
95
96
  }
@@ -1,88 +0,0 @@
1
- /*!
2
- * Crafted with ❤ by Salla
3
- */
4
- 'use strict';
5
-
6
- Object.defineProperty(exports, '__esModule', { value: true });
7
-
8
- const index = require('./index-1d2b3370.js');
9
-
10
- const SallaConditionalFields = class {
11
- constructor(hostRef) {
12
- index.registerInstance(this, hostRef);
13
- }
14
- changeHandler(event) {
15
- var _a;
16
- salla.event.emit('salla-onditional-fields::change', event);
17
- salla.log('Received the change event: ', event);
18
- if (!event.target || !['SELECT'].includes(event.target.tagName) && !['checkbox'].includes(event.target.getAttribute('type'))) {
19
- salla.log('Ignore the change because is not support input: ' + (((_a = event === null || event === void 0 ? void 0 : event.target) === null || _a === void 0 ? void 0 : _a.tagName) || 'N/A'));
20
- return;
21
- }
22
- // to extract the option id from the input name, the supported names are name[*] and name[*][]
23
- let optionId = event.target.name.replace('[]', '');
24
- let isMultiple = event.target.getAttribute('type') === 'checkbox';
25
- salla.log('Trying to find all the element with condition:', `[data-show-when^="${optionId}"]`);
26
- this.host.querySelectorAll(`[data-show-when^="${optionId}"]`)
27
- .forEach((field) => {
28
- let isEqual = !(field === null || field === void 0 ? void 0 : field.dataset.showWhen.includes('!='));
29
- let value = field === null || field === void 0 ? void 0 : field.dataset.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$3').trim();
30
- // let isSelected = isMultiple ? event.target?.checked : value === event.target.value;
31
- let isSelected;
32
- if (isMultiple) {
33
- // @ts-ignore
34
- let selectedValues = Array.from(this.host.querySelectorAll(`input[name="${event.target.name}"]:checked`), e => e === null || e === void 0 ? void 0 : e.value);
35
- isSelected = selectedValues.includes(value.toString());
36
- }
37
- else {
38
- isSelected = value === event.target.value;
39
- }
40
- salla.log('The input is ', (isMultiple ? 'Multiple' : 'Single'), ' value:', isSelected);
41
- let showTheInput = (isEqual && isSelected) || (!isEqual && !isSelected);
42
- if (showTheInput) {
43
- field.classList.remove('hidden');
44
- field.querySelectorAll('[name]').forEach((input) => {
45
- input.removeAttribute('disabled');
46
- //To handle focus on hidden input error
47
- if (!['checkbox'].includes(input.getAttribute('type')) && field.getElementsByClassName('required').length) {
48
- input.setAttribute('required', '');
49
- }
50
- });
51
- }
52
- else {
53
- field.classList.add('hidden');
54
- field.querySelectorAll('[name]').forEach((input) => {
55
- input.setAttribute('disabled', '');
56
- input.removeAttribute('required');
57
- if (['checkbox'].includes(input.getAttribute('type')) && input.hasOwnProperty('checked')) {
58
- // @ts-ignore
59
- input.checked = false;
60
- }
61
- //firing this event will show errors, so don't run it when pageLoading.
62
- // if (this.optionsAlreadyInitiated) {
63
- // salla.document.event.fireEvent(input, 'change', {'bubbles': true});
64
- // }
65
- });
66
- }
67
- });
68
- }
69
- componentDidRender() {
70
- this.host.querySelectorAll(`[data-show-when]`).forEach((field) => {
71
- var _a;
72
- // @ts-ignore
73
- let optionName = (_a = field === null || field === void 0 ? void 0 : field.dataset) === null || _a === void 0 ? void 0 : _a.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$1').trim();
74
- if (!optionName) {
75
- return;
76
- }
77
- this.changeHandler({
78
- target: this.host.querySelector('[name^="' + optionName + '"]')
79
- });
80
- });
81
- }
82
- render() {
83
- return (index.h(index.Host, null, index.h("slot", null)));
84
- }
85
- get host() { return index.getElement(this); }
86
- };
87
-
88
- exports.salla_conditional_fields = SallaConditionalFields;