@salla.sa/twilight-components 2.9.8 → 2.9.10

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 (81) hide show
  1. package/README.md +15 -15
  2. package/dist/cjs/{index-ed20038c.js → index-2a81e6e4.js} +1 -1
  3. package/dist/cjs/loader.cjs.js +2 -2
  4. package/dist/cjs/salla-button_30.cjs.entry.js +16289 -16249
  5. package/dist/cjs/salla-select.cjs.entry.js +0 -1
  6. package/dist/cjs/twilight.cjs.js +2 -2
  7. package/dist/collection/components/salla-cart-summary/salla-cart-summary.css +0 -3
  8. package/dist/collection/components/salla-cart-summary/salla-cart-summary.js +85 -3
  9. package/dist/collection/components/salla-comment-form/salla-comment-form.js +33 -8
  10. package/dist/collection/components/salla-datetime-picker/salla-datetime-picker.js +1 -232
  11. package/dist/collection/components/salla-file-upload/salla-file-upload.js +1 -3
  12. package/dist/collection/components/salla-gifting/salla-gifting.js +4 -7
  13. package/dist/collection/components/salla-list-tile/salla-list-tile.js +6 -0
  14. package/dist/collection/components/salla-loyalty/salla-loyalty-prize-item.js +2 -2
  15. package/dist/collection/components/salla-loyalty/salla-loyalty.js +4 -0
  16. package/dist/collection/components/salla-modal/salla-modal.js +1 -1
  17. package/dist/collection/components/salla-placeholder/salla-placeholder.js +4 -0
  18. package/dist/collection/components/salla-product-size-guide/salla-product-size-guide.js +4 -1
  19. package/dist/collection/components/salla-scopes/salla-scopes.js +3 -0
  20. package/dist/collection/components/salla-select/salla-select.js +0 -1
  21. package/dist/collection/components/salla-social-share/salla-social-share.js +3 -0
  22. package/dist/collection/components/salla-swiper/salla-swiper.js +3 -0
  23. package/dist/collection/components/salla-tabs/salla-tab-content.js +3 -0
  24. package/dist/collection/components/salla-tabs/salla-tab-header.js +3 -0
  25. package/dist/collection/components/salla-tabs/salla-tabs.js +4 -0
  26. package/dist/collection/components/salla-tel-input/salla-tel-input.js +1 -16
  27. package/dist/collection/components/salla-user-settings/salla-user-settings.js +4 -1
  28. package/dist/components/index.js +1 -1
  29. package/dist/components/salla-cart-summary.js +55 -3
  30. package/dist/components/salla-comment-form.js +8 -3
  31. package/dist/components/salla-datetime-picker2.js +0 -22
  32. package/dist/components/salla-file-upload2.js +0 -2
  33. package/dist/components/salla-gifting.js +2 -4
  34. package/dist/components/salla-product-size-guide.js +0 -1
  35. package/dist/components/salla-select.js +0 -1
  36. package/dist/components/salla-tel-input2.js +0 -1
  37. package/dist/components/salla-user-settings.js +3 -0
  38. package/dist/esm/{index-637c678a.js → index-535ae6f8.js} +1 -1
  39. package/dist/esm/loader.js +2 -2
  40. package/dist/esm/salla-button_30.entry.js +16289 -16249
  41. package/dist/esm/salla-select.entry.js +0 -1
  42. package/dist/esm/twilight.js +2 -2
  43. package/dist/esm-es5/{index-637c678a.js → index-535ae6f8.js} +1 -1
  44. package/dist/esm-es5/loader.js +1 -1
  45. package/dist/esm-es5/salla-button_30.entry.js +2 -2
  46. package/dist/esm-es5/salla-select.entry.js +1 -1
  47. package/dist/esm-es5/twilight.js +1 -1
  48. package/dist/twilight/{p-f610b6bf.system.entry.js → p-0df01b70.system.entry.js} +1 -1
  49. package/dist/twilight/{p-1e3d30a5.js → p-11002b35.js} +1 -1
  50. package/dist/twilight/p-1d724919.entry.js +22 -0
  51. package/dist/twilight/{p-0cca47db.system.js → p-4d9a19dc.system.js} +1 -1
  52. package/dist/twilight/p-5c5a3fc1.system.js +4 -0
  53. package/dist/twilight/p-af4aa9f9.entry.js +4 -0
  54. package/dist/twilight/p-c075bc90.system.entry.js +34 -0
  55. package/dist/twilight/twilight.esm.js +1 -1
  56. package/dist/twilight/twilight.js +1 -1
  57. package/dist/types/components/salla-cart-summary/salla-cart-summary.d.ts +6 -0
  58. package/dist/types/components/salla-comment-form/salla-comment-form.d.ts +6 -2
  59. package/dist/types/components/salla-datetime-picker/salla-datetime-picker.d.ts +4 -46
  60. package/dist/types/components/salla-file-upload/salla-file-upload.d.ts +3 -0
  61. package/dist/types/components/salla-gifting/salla-gifting.d.ts +2 -3
  62. package/dist/types/components/salla-list-tile/salla-list-tile.d.ts +6 -0
  63. package/dist/types/components/salla-loyalty/salla-loyalty-prize-item.d.ts +6 -0
  64. package/dist/types/components/salla-loyalty/salla-loyalty.d.ts +4 -0
  65. package/dist/types/components/salla-modal/salla-modal.d.ts +3 -0
  66. package/dist/types/components/salla-placeholder/salla-placeholder.d.ts +4 -0
  67. package/dist/types/components/salla-product-size-guide/salla-product-size-guide.d.ts +4 -0
  68. package/dist/types/components/salla-scopes/salla-scopes.d.ts +3 -0
  69. package/dist/types/components/salla-social-share/salla-social-share.d.ts +3 -0
  70. package/dist/types/components/salla-swiper/salla-swiper.d.ts +3 -0
  71. package/dist/types/components/salla-tabs/salla-tab-content.d.ts +3 -0
  72. package/dist/types/components/salla-tabs/salla-tab-header.d.ts +3 -0
  73. package/dist/types/components/salla-tabs/salla-tabs.d.ts +4 -0
  74. package/dist/types/components/salla-tel-input/salla-tel-input.d.ts +1 -2
  75. package/dist/types/components/salla-user-settings/salla-user-settings.d.ts +3 -0
  76. package/dist/types/components.d.ts +43 -95
  77. package/package.json +4 -4
  78. package/dist/twilight/p-5ab82b6b.system.js +0 -4
  79. package/dist/twilight/p-83362f18.system.entry.js +0 -34
  80. package/dist/twilight/p-97daba27.entry.js +0 -4
  81. package/dist/twilight/p-99c87dea.entry.js +0 -22
@@ -127,7 +127,6 @@ const SallaSelect = class {
127
127
  }
128
128
  let selectedItem = this.items[!!this.placeholder ? selectedIndex - 1 : selectedIndex];
129
129
  this.value = this.returnObject ? selectedItem : selectedItem[this.itemValue];
130
- console.log("🚀 ~ file: salla-select.tsx ~ line 153 ~ SallaSelect ~ onSelectedItemChange ~ this.value", this.value);
131
130
  }
132
131
  generateHint() {
133
132
  if (!this.persistHint && !this.value) {
@@ -4,7 +4,7 @@
4
4
  'use strict';
5
5
 
6
6
  const index = require('./index-cac2fd59.js');
7
- require('./index-ed20038c.js');
7
+ require('./index-2a81e6e4.js');
8
8
  require('./_commonjsHelpers-691dd63b.js');
9
9
 
10
10
  /*
@@ -77,5 +77,5 @@ const patchDynamicImport = (base, orgScriptElm) => {
77
77
  };
78
78
 
79
79
  patchBrowser().then(options => {
80
- return index.bootstrapLazy(JSON.parse("[[\"salla-button_30.cjs\",[[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-rating-modal\",{\"orderId\":[2,\"order-id\"],\"order\":[32],\"hasError\":[32],\"errorMessage\":[32],\"translationLoaded\":[32],\"open\":[64],\"close\":[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-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-user-settings\",{\"isNotifiable\":[516,\"is-notifiable\"],\"deactivateAccount\":[32],\"promotionalMsgs\":[32],\"deactivateDesc\":[32],\"promotionalMsgsDesc\":[32],\"sorryForLeavingText\":[32],\"warningText\":[32],\"keepAccount\":[32],\"buttonLoading\":[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],\"itemId\":[8,\"item-id\"],\"placeholder\":[32],\"submitText\":[32],\"canComment\":[32]}],[4,\"salla-social-share\",{\"url\":[513],\"urlName\":[513,\"url-name\"],\"platforms\":[16],\"opened\":[32],\"allPlatforms\":[32],\"platformIcons\":[32],\"open\":[64]}],[4,\"salla-cart-summary\",{\"cartSummaryCount\":[32],\"cartSummaryTotal\":[32]}],[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-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\"],\"onChange\":[16],\"onClose\":[16],\"onDayCreate\":[16],\"onDestroy\":[16],\"onKeyDown\":[16],\"onMonthChange\":[16],\"onOpen\":[16],\"onParseConfig\":[16],\"onReady\":[16],\"onValueUpdate\":[16],\"onYearChange\":[16],\"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-swiper\",{\"loop\":[4],\"speed\":[2],\"itemPerView\":[8,\"item-per-view\"],\"spaceBetweenItems\":[2,\"space-between-items\"],\"currentIndex\":[32],\"isLastSlideItem\":[32],\"isFirstSlideItem\":[32]}],[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-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\"]}]]],[\"salla-scopes.cjs\",[[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],\"close\":[64],\"open\":[64],\"handleSubmit\":[64]}]]],[\"salla-add-product-button.cjs\",[[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\"]}]]],[\"salla-conditional-fields.cjs\",[[4,\"salla-conditional-fields\",null,[[0,\"change\",\"changeHandler\"]]]]],[\"salla-installment.cjs\",[[0,\"salla-installment\",{\"price\":[1],\"language\":[1],\"currency\":[1],\"tamaraIsActive\":[32],\"tabbyIsActive\":[32],\"spotiiIsActive\":[32]}]]],[\"salla-loyalty-prize-item.cjs\",[[0,\"salla-loyalty-prize-item\",{\"item\":[16]}]]],[\"salla-select.cjs\",[[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\"]}]]]]"), options);
80
+ return index.bootstrapLazy(JSON.parse("[[\"salla-button_30.cjs\",[[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-rating-modal\",{\"orderId\":[2,\"order-id\"],\"order\":[32],\"hasError\":[32],\"errorMessage\":[32],\"translationLoaded\":[32],\"open\":[64],\"close\":[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-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-user-settings\",{\"isNotifiable\":[516,\"is-notifiable\"],\"deactivateAccount\":[32],\"promotionalMsgs\":[32],\"deactivateDesc\":[32],\"promotionalMsgsDesc\":[32],\"sorryForLeavingText\":[32],\"warningText\":[32],\"keepAccount\":[32],\"buttonLoading\":[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\":[16],\"opened\":[32],\"allPlatforms\":[32],\"platformIcons\":[32],\"open\":[64]}],[4,\"salla-cart-summary\",{\"cartSummaryCount\":[32],\"cartSummaryTotal\":[32],\"animateToCart\":[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-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-swiper\",{\"loop\":[4],\"speed\":[2],\"itemPerView\":[8,\"item-per-view\"],\"spaceBetweenItems\":[2,\"space-between-items\"],\"currentIndex\":[32],\"isLastSlideItem\":[32],\"isFirstSlideItem\":[32]}],[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-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\"]}]]],[\"salla-scopes.cjs\",[[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],\"close\":[64],\"open\":[64],\"handleSubmit\":[64]}]]],[\"salla-add-product-button.cjs\",[[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\"]}]]],[\"salla-conditional-fields.cjs\",[[4,\"salla-conditional-fields\",null,[[0,\"change\",\"changeHandler\"]]]]],[\"salla-installment.cjs\",[[0,\"salla-installment\",{\"price\":[1],\"language\":[1],\"currency\":[1],\"tamaraIsActive\":[32],\"tabbyIsActive\":[32],\"spotiiIsActive\":[32]}]]],[\"salla-loyalty-prize-item.cjs\",[[0,\"salla-loyalty-prize-item\",{\"item\":[16]}]]],[\"salla-select.cjs\",[[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\"]}]]]]"), options);
81
81
  });
@@ -1,3 +0,0 @@
1
- :host {
2
- display: block;
3
- }
@@ -1,8 +1,9 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { Component, Host, h, State } from '@stencil/core';
4
+ import { Component, Host, h, State, Method, Element } from '@stencil/core';
5
5
  import CartIcon from "../../assets/svg/cart.svg";
6
+ import anime from 'animejs';
6
7
  export class SallaCartSummary {
7
8
  constructor() {
8
9
  this.cartSummaryCount = salla.storage.get('cart.summary.count') || 0;
@@ -12,11 +13,61 @@ export class SallaCartSummary {
12
13
  this.cartSummaryTotal = salla.storage.get('cart.summary.total');
13
14
  });
14
15
  }
16
+ /**
17
+ * Animate product Image to cart summary
18
+ * @param image the image element to animate
19
+ */
20
+ async animateToCart(image) {
21
+ document.querySelectorAll('.s-cart-thumb').forEach(el => el.remove());
22
+ if (!(image === null || image === void 0 ? void 0 : image.src)) {
23
+ salla.log('Failed to get the img element');
24
+ return;
25
+ }
26
+ let cartBtn = this.host.querySelector('#s-cart-icon'), btnOffset = cartBtn.getBoundingClientRect(), btnTop = btnOffset.top + window.scrollY, btnLeft = btnOffset.left + window.scrollX;
27
+ // get thumb position ---
28
+ let position = image.getBoundingClientRect(), width = image.offsetWidth + 'px', height = image.offsetHeight + 'px', top = position.top, left = position.left;
29
+ // create thumb img element ---
30
+ let img = document.createElement("img");
31
+ img.src = image.getAttribute('src');
32
+ img.className = "s-cart-thumb";
33
+ img.setAttribute("style", "object-fit:cover; width:" + width + '; height:' + height + '; top:' + top + 'px; left:' + left + 'px;z-index:99999999; ');
34
+ document.body.append(img);
35
+ let cartThumb = document.querySelector('.s-cart-thumb');
36
+ cartBtn.classList.remove('animated', 'rubberBand');
37
+ // start timeline ---
38
+ let cartThumbAnime = new anime.timeline();
39
+ cartThumbAnime.add({
40
+ targets: cartThumb,
41
+ width: [150, 30],
42
+ height: [150, 30],
43
+ top: [top, window.scrollY > 0 ? btnTop - window.scrollY - 40 : btnTop - 40],
44
+ left: [left, btnLeft],
45
+ borderRadius: ['20%', '50%'],
46
+ easing: 'easeOutExpo',
47
+ duration: 1200,
48
+ }, '+=200')
49
+ .add({
50
+ targets: cartThumb,
51
+ width: [30, 0],
52
+ height: [30, 0],
53
+ opacity: [1, 0],
54
+ easing: 'easeOutExpo',
55
+ top: [window.scrollY > 0 ? btnTop - window.scrollY - 40 : btnTop - 40, window.scrollY > 0 ? btnTop - window.scrollY + 10 : btnTop + 10],
56
+ left: [btnLeft, btnLeft + 10],
57
+ }, '-=500')
58
+ .add({
59
+ complete: function () {
60
+ cartBtn.classList.add('animated', 'rubberBand');
61
+ cartThumb.remove();
62
+ },
63
+ }, '-=1700');
64
+ }
15
65
  render() {
16
66
  return (h(Host, null,
17
67
  h("a", { class: "s-cart-summary-wrapper", href: salla.url.get('cart') },
18
- h("slot", { name: "icon" },
19
- h("i", { class: "s-cart-summary-icon", innerHTML: CartIcon })),
68
+ h("div", { id: "s-cart-icon" },
69
+ h("slot", { name: "icon" },
70
+ h("i", { class: "s-cart-summary-icon", innerHTML: CartIcon }))),
20
71
  h("span", { class: "s-cart-summary-count" }, salla.helpers.number(this.cartSummaryCount)),
21
72
  h("b", { class: "s-cart-summary-total" }, salla.money(this.cartSummaryTotal)))));
22
73
  }
@@ -31,4 +82,35 @@ export class SallaCartSummary {
31
82
  "cartSummaryCount": {},
32
83
  "cartSummaryTotal": {}
33
84
  }; }
85
+ static get methods() { return {
86
+ "animateToCart": {
87
+ "complexType": {
88
+ "signature": "(image: any) => Promise<void>",
89
+ "parameters": [{
90
+ "tags": [{
91
+ "name": "param",
92
+ "text": "image the image element to animate"
93
+ }],
94
+ "text": "the image element to animate"
95
+ }],
96
+ "references": {
97
+ "Promise": {
98
+ "location": "global"
99
+ },
100
+ "HTMLImageElement": {
101
+ "location": "global"
102
+ }
103
+ },
104
+ "return": "Promise<void>"
105
+ },
106
+ "docs": {
107
+ "text": "Animate product Image to cart summary",
108
+ "tags": [{
109
+ "name": "param",
110
+ "text": "image the image element to animate"
111
+ }]
112
+ }
113
+ }
114
+ }; }
115
+ static get elementRef() { return "host"; }
34
116
  }
@@ -5,11 +5,15 @@ import { Component, Host, State, h, Prop } from '@stencil/core';
5
5
  export class SallaCommentForm {
6
6
  constructor() {
7
7
  /**
8
- * type prop
8
+ * Type of entity the commment is being submitted for. Defaults to `product`
9
9
  */
10
10
  this.type = salla.url.is_page('page-single') ? 'page' : 'product';
11
11
  /**
12
- * itemId prop
12
+ * To show the avatar or not in the comment form
13
+ */
14
+ this.showAvatar = false;
15
+ /**
16
+ * The ID of the item(as defined in the type), where the comment is for.
13
17
  */
14
18
  this.itemId = salla.config.get('page.id');
15
19
  this.placeholder = salla.lang.get('blocks.comments.placeholder');
@@ -31,10 +35,13 @@ export class SallaCommentForm {
31
35
  }
32
36
  render() {
33
37
  return (h(Host, null, !!this.canComment ? h("form", { ref: frm => this.commentForm = frm },
34
- h("textarea", { required: true, rows: 5, cols: 30, minlength: "4", maxlength: "500", placeholder: this.placeholder, ref: field => this.commentField = field, class: "s-comment-form-input" }),
35
- h("br", null),
36
- h("div", { class: "s-comment-form-action" },
37
- h("salla-button", { ref: btn => this.submitBtn = btn, "loader-position": 'center', onClick: () => this.submit() }, this.submitText))) : ''));
38
+ h("div", { class: "s-comment-form-wrapper" },
39
+ this.showAvatar ? h("img", { class: "s-comment-form-avatar", src: salla.config.get('user.avatar'), alt: "user avatar" }) : '',
40
+ h("div", { class: "s-comment-form-content" },
41
+ h("textarea", { required: true, rows: 5, cols: 30, minlength: "4", maxlength: "500", placeholder: this.placeholder, ref: field => this.commentField = field, class: "s-comment-form-input" }),
42
+ h("br", null),
43
+ h("div", { class: "s-comment-form-action" },
44
+ h("salla-button", { ref: btn => this.submitBtn = btn, "loader-position": 'center', onClick: () => this.submit() }, this.submitText))))) : ''));
38
45
  }
39
46
  static get is() { return "salla-comment-form"; }
40
47
  static get originalStyleUrls() { return {
@@ -56,12 +63,30 @@ export class SallaCommentForm {
56
63
  "optional": false,
57
64
  "docs": {
58
65
  "tags": [],
59
- "text": "type prop"
66
+ "text": "Type of entity the commment is being submitted for. Defaults to `product`"
60
67
  },
61
68
  "attribute": "type",
62
69
  "reflect": false,
63
70
  "defaultValue": "salla.url.is_page('page-single') ? 'page' : 'product'"
64
71
  },
72
+ "showAvatar": {
73
+ "type": "boolean",
74
+ "mutable": false,
75
+ "complexType": {
76
+ "original": "boolean",
77
+ "resolved": "boolean",
78
+ "references": {}
79
+ },
80
+ "required": false,
81
+ "optional": false,
82
+ "docs": {
83
+ "tags": [],
84
+ "text": "To show the avatar or not in the comment form"
85
+ },
86
+ "attribute": "show-avatar",
87
+ "reflect": false,
88
+ "defaultValue": "false"
89
+ },
65
90
  "itemId": {
66
91
  "type": "any",
67
92
  "mutable": false,
@@ -74,7 +99,7 @@ export class SallaCommentForm {
74
99
  "optional": false,
75
100
  "docs": {
76
101
  "tags": [],
77
- "text": "itemId prop"
102
+ "text": "The ID of the item(as defined in the type), where the comment is for."
78
103
  },
79
104
  "attribute": "item-id",
80
105
  "reflect": false,
@@ -217,17 +217,6 @@ export class SallaDatetimePicker {
217
217
  monthSelectorType: this.monthSelectorType,
218
218
  nextArrow: this.nextArrow,
219
219
  noCalendar: this.noCalendar,
220
- onChange: this.onChange,
221
- onClose: this.onClose,
222
- onDayCreate: this.onDayCreate,
223
- onDestroy: this.onDestroy,
224
- onKeyDown: this.onKeyDown,
225
- onMonthChange: this.onMonthChange,
226
- onOpen: this.onOpen,
227
- onParseConfig: this.onParseConfig,
228
- onReady: this.onReady,
229
- onValueUpdate: this.onValueUpdate,
230
- onYearChange: this.onYearChange,
231
220
  parseDate: this.dateParser,
232
221
  position: this.position,
233
222
  positionElement: this.positionElement,
@@ -948,226 +937,6 @@ export class SallaDatetimePicker {
948
937
  "reflect": false,
949
938
  "defaultValue": "false"
950
939
  },
951
- "onChange": {
952
- "type": "unknown",
953
- "mutable": false,
954
- "complexType": {
955
- "original": "Hook | Hook[]",
956
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
957
- "references": {
958
- "Hook": {
959
- "location": "import",
960
- "path": "./interfaces"
961
- }
962
- }
963
- },
964
- "required": false,
965
- "optional": false,
966
- "docs": {
967
- "tags": [],
968
- "text": "Fires when the selected dates have changed - when a date is picked or cleared, by user or programmatically."
969
- }
970
- },
971
- "onClose": {
972
- "type": "unknown",
973
- "mutable": false,
974
- "complexType": {
975
- "original": "Hook | Hook[]",
976
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
977
- "references": {
978
- "Hook": {
979
- "location": "import",
980
- "path": "./interfaces"
981
- }
982
- }
983
- },
984
- "required": false,
985
- "optional": false,
986
- "docs": {
987
- "tags": [],
988
- "text": "Fires when the calendar is closed"
989
- }
990
- },
991
- "onDayCreate": {
992
- "type": "unknown",
993
- "mutable": false,
994
- "complexType": {
995
- "original": "Hook | Hook[]",
996
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
997
- "references": {
998
- "Hook": {
999
- "location": "import",
1000
- "path": "./interfaces"
1001
- }
1002
- }
1003
- },
1004
- "required": false,
1005
- "optional": false,
1006
- "docs": {
1007
- "tags": [],
1008
- "text": "Fires for every day cell in the calendar, where the fourth argument is the html element of the cell. \nSee https://chmln.github.io/flatpickr/events/#ondaycreate"
1009
- }
1010
- },
1011
- "onDestroy": {
1012
- "type": "unknown",
1013
- "mutable": false,
1014
- "complexType": {
1015
- "original": "Hook | Hook[]",
1016
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1017
- "references": {
1018
- "Hook": {
1019
- "location": "import",
1020
- "path": "./interfaces"
1021
- }
1022
- }
1023
- },
1024
- "required": false,
1025
- "optional": false,
1026
- "docs": {
1027
- "tags": [],
1028
- "text": "Fires before the calendar instance is destroyed"
1029
- }
1030
- },
1031
- "onKeyDown": {
1032
- "type": "unknown",
1033
- "mutable": false,
1034
- "complexType": {
1035
- "original": "Hook | Hook[]",
1036
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1037
- "references": {
1038
- "Hook": {
1039
- "location": "import",
1040
- "path": "./interfaces"
1041
- }
1042
- }
1043
- },
1044
- "required": false,
1045
- "optional": false,
1046
- "docs": {
1047
- "tags": [],
1048
- "text": "Fires when valid keyboard input for calendar is detected"
1049
- }
1050
- },
1051
- "onMonthChange": {
1052
- "type": "unknown",
1053
- "mutable": false,
1054
- "complexType": {
1055
- "original": "Hook | Hook[]",
1056
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1057
- "references": {
1058
- "Hook": {
1059
- "location": "import",
1060
- "path": "./interfaces"
1061
- }
1062
- }
1063
- },
1064
- "required": false,
1065
- "optional": false,
1066
- "docs": {
1067
- "tags": [],
1068
- "text": "Fires after the month has changed"
1069
- }
1070
- },
1071
- "onOpen": {
1072
- "type": "unknown",
1073
- "mutable": false,
1074
- "complexType": {
1075
- "original": "Hook | Hook[]",
1076
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1077
- "references": {
1078
- "Hook": {
1079
- "location": "import",
1080
- "path": "./interfaces"
1081
- }
1082
- }
1083
- },
1084
- "required": false,
1085
- "optional": false,
1086
- "docs": {
1087
- "tags": [],
1088
- "text": "Fires after the calendar is opened"
1089
- }
1090
- },
1091
- "onParseConfig": {
1092
- "type": "unknown",
1093
- "mutable": false,
1094
- "complexType": {
1095
- "original": "Hook | Hook[]",
1096
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1097
- "references": {
1098
- "Hook": {
1099
- "location": "import",
1100
- "path": "./interfaces"
1101
- }
1102
- }
1103
- },
1104
- "required": false,
1105
- "optional": false,
1106
- "docs": {
1107
- "tags": [],
1108
- "text": "Fires after the configuration for the calendar is parsed"
1109
- }
1110
- },
1111
- "onReady": {
1112
- "type": "unknown",
1113
- "mutable": false,
1114
- "complexType": {
1115
- "original": "Hook | Hook[]",
1116
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1117
- "references": {
1118
- "Hook": {
1119
- "location": "import",
1120
- "path": "./interfaces"
1121
- }
1122
- }
1123
- },
1124
- "required": false,
1125
- "optional": false,
1126
- "docs": {
1127
- "tags": [],
1128
- "text": "Fires once the calendar instance is ready"
1129
- }
1130
- },
1131
- "onValueUpdate": {
1132
- "type": "unknown",
1133
- "mutable": false,
1134
- "complexType": {
1135
- "original": "Hook | Hook[]",
1136
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1137
- "references": {
1138
- "Hook": {
1139
- "location": "import",
1140
- "path": "./interfaces"
1141
- }
1142
- }
1143
- },
1144
- "required": false,
1145
- "optional": false,
1146
- "docs": {
1147
- "tags": [],
1148
- "text": "Like onChange, but fires immediately after any date changes"
1149
- }
1150
- },
1151
- "onYearChange": {
1152
- "type": "unknown",
1153
- "mutable": false,
1154
- "complexType": {
1155
- "original": "Hook | Hook[]",
1156
- "resolved": "((dates: Date[], currentDateString: string, self: any, data?: any) => void) | Hook[]",
1157
- "references": {
1158
- "Hook": {
1159
- "location": "import",
1160
- "path": "./interfaces"
1161
- }
1162
- }
1163
- },
1164
- "required": false,
1165
- "optional": false,
1166
- "docs": {
1167
- "tags": [],
1168
- "text": "Fires after the year has changed"
1169
- }
1170
- },
1171
940
  "dateParser": {
1172
941
  "type": "unknown",
1173
942
  "mutable": false,
@@ -1363,7 +1132,7 @@ export class SallaDatetimePicker {
1363
1132
  "composed": true,
1364
1133
  "docs": {
1365
1134
  "tags": [],
1366
- "text": ""
1135
+ "text": "Event emitted when the file input gets changed by the user when selecting file(s)."
1367
1136
  },
1368
1137
  "complexType": {
1369
1138
  "original": "any",
@@ -262,8 +262,6 @@ export class SallaFileUpload {
262
262
  async appendFile(file) {
263
263
  return this.pond.files = [file];
264
264
  }
265
- /// Hooks
266
- /// Styles
267
265
  componentDidLoad() {
268
266
  this.pond = this.intiFilePond();
269
267
  }
@@ -1399,7 +1397,7 @@ export class SallaFileUpload {
1399
1397
  "composed": true,
1400
1398
  "docs": {
1401
1399
  "tags": [],
1402
- "text": ""
1400
+ "text": "Event emitted when the file is about to be removed. Returns boolean value."
1403
1401
  },
1404
1402
  "complexType": {
1405
1403
  "original": "any",
@@ -8,7 +8,6 @@ import RightArrow from '../../assets/svg/arrow-right.svg';
8
8
  import LeftArrow from '../../assets/svg/arrow-left.svg';
9
9
  import Cancel from '../../assets/svg/cancel.svg';
10
10
  import GiftSharing from '../../assets/svg/gift-sharing.svg';
11
- //todo:: pass to the placeholder icon sad for no gifting
12
11
  export class SallaGifting {
13
12
  constructor() {
14
13
  this.selectImageForYourGift = salla.lang.get('blocks.buy_as_gift.select_image_or_upload');
@@ -19,7 +18,6 @@ export class SallaGifting {
19
18
  this.parentClass = "is-current-step-1";
20
19
  this.errors = {};
21
20
  this.gift = undefined;
22
- // @State() selectedImage: GiftImage = undefined;
23
21
  this.selectedGiftTextOption = undefined;
24
22
  this.showTextArea = false;
25
23
  /// Gift Form Data
@@ -61,7 +59,7 @@ export class SallaGifting {
61
59
  });
62
60
  }
63
61
  /**
64
- * Show the gifting modal window
62
+ * Show / Open the gifting modal window
65
63
  */
66
64
  async open() {
67
65
  if (salla.config.isGuest()) {
@@ -83,13 +81,12 @@ export class SallaGifting {
83
81
  }
84
82
  /**
85
83
  *
86
- * Hide the gifting modal window
84
+ * Hide / close the gifting modal window
87
85
  */
88
86
  async close() {
89
87
  return this.modal.close();
90
88
  }
91
89
  /**
92
- *
93
90
  * Update the modal height based on the changes on the inner elements height for a specific step OR just a pass a new fixed height
94
91
  */
95
92
  async setWrapperHeight(asStep = 1, delay = 250, additionSpace = 0, newHeight = 0) {
@@ -532,7 +529,7 @@ export class SallaGifting {
532
529
  "return": "Promise<any>"
533
530
  },
534
531
  "docs": {
535
- "text": "Show the gifting modal window",
532
+ "text": "Show / Open the gifting modal window",
536
533
  "tags": []
537
534
  }
538
535
  },
@@ -551,7 +548,7 @@ export class SallaGifting {
551
548
  "return": "Promise<HTMLElement>"
552
549
  },
553
550
  "docs": {
554
- "text": "\nHide the gifting modal window",
551
+ "text": "\nHide / close the gifting modal window",
555
552
  "tags": []
556
553
  }
557
554
  },
@@ -2,6 +2,12 @@
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
4
  import { Component, Host, h, Prop } from '@stencil/core';
5
+ /**
6
+ * @slot icon - An icon to display before the title.
7
+ * @slot title - The primary content of the list tile.
8
+ * @slot subtitle - Additional content displayed below the title.
9
+ * @slot action - An element to display after the title.
10
+ */
5
11
  export class SallaListTile {
6
12
  constructor() {
7
13
  /**
@@ -41,7 +41,7 @@ export class SallaLoyaltyPrizeItem {
41
41
  "optional": false,
42
42
  "docs": {
43
43
  "tags": [],
44
- "text": ""
44
+ "text": "Prize item to be displayed in this component."
45
45
  }
46
46
  }
47
47
  }; }
@@ -53,7 +53,7 @@ export class SallaLoyaltyPrizeItem {
53
53
  "composed": true,
54
54
  "docs": {
55
55
  "tags": [],
56
- "text": ""
56
+ "text": "Event emmited when the user select this item."
57
57
  },
58
58
  "complexType": {
59
59
  "original": "Item",