@salla.sa/twilight-components 2.14.350 → 2.14.352

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 (157) hide show
  1. package/dist/cjs/{Helper-B5NunIdR.js → Helper-DHRnzcFm.js} +14 -0
  2. package/dist/cjs/{filepond-qUaAgMcd.js → filepond-XtsZ6xtH.js} +1 -1
  3. package/dist/cjs/{filepond-plugin-file-poster-DUgrMVOZ.js → filepond-plugin-file-poster-Bj84Ypvg.js} +1 -1
  4. package/dist/cjs/{filepond-plugin-file-validate-size-C14LEY_l.js → filepond-plugin-file-validate-size-aYfb4yYH.js} +1 -1
  5. package/dist/cjs/{filepond-plugin-file-validate-type-AbHwQAHY.js → filepond-plugin-file-validate-type-CJsd6rXl.js} +1 -1
  6. package/dist/cjs/{filepond-plugin-image-edit-5ydXOhOa.js → filepond-plugin-image-edit-DRlBSg36.js} +1 -1
  7. package/dist/cjs/{filepond-plugin-image-exif-orientation-D0oIUOy-.js → filepond-plugin-image-exif-orientation-SY8c6DzI.js} +1 -1
  8. package/dist/cjs/{filepond-plugin-image-preview-Bf_VUYwr.js → filepond-plugin-image-preview-iqhJmUmU.js} +1 -1
  9. package/dist/cjs/{index-DKEcPhG9.js → index-C7-280f4.js} +1 -1
  10. package/dist/cjs/{index-BRdJtc1o.js → index-Z-cyrNSM.js} +2 -2
  11. package/dist/cjs/loader.cjs.js +1 -1
  12. package/dist/cjs/salla-accordion_62.cjs.entry.js +25 -36
  13. package/dist/cjs/salla-advertisement.cjs.entry.js +1 -1
  14. package/dist/cjs/salla-app-install-alert.cjs.entry.js +1 -1
  15. package/dist/cjs/salla-apps-icons.cjs.entry.js +1 -1
  16. package/dist/cjs/salla-cart-item-offers.cjs.entry.js +1 -1
  17. package/dist/cjs/salla-conditional-offer.cjs.entry.js +1 -1
  18. package/dist/cjs/salla-contacts.cjs.entry.js +1 -1
  19. package/dist/cjs/salla-custom-fields.cjs.entry.js +1 -1
  20. package/dist/cjs/salla-filters-widget.cjs.entry.js +2 -2
  21. package/dist/cjs/salla-filters.cjs.entry.js +2 -2
  22. package/dist/cjs/salla-hook.cjs.entry.js +1 -1
  23. package/dist/cjs/salla-installment.cjs.entry.js +1 -1
  24. package/dist/cjs/salla-loyalty-prize-item.cjs.entry.js +1 -1
  25. package/dist/cjs/salla-loyalty-program.cjs.entry.js +1 -1
  26. package/dist/cjs/salla-metadata.cjs.entry.js +1 -1
  27. package/dist/cjs/salla-notification-item.cjs.entry.js +1 -1
  28. package/dist/cjs/salla-notifications.cjs.entry.js +2 -2
  29. package/dist/cjs/salla-offer.cjs.entry.js +1 -1
  30. package/dist/cjs/salla-order-details-multiple-bundle-product.cjs.entry.js +1 -1
  31. package/dist/cjs/salla-order-details-options.cjs.entry.js +1 -1
  32. package/dist/cjs/salla-order-details.cjs.entry.js +1 -1
  33. package/dist/cjs/salla-order-summary.cjs.entry.js +1 -1
  34. package/dist/cjs/salla-order-totals-card.cjs.entry.js +1 -1
  35. package/dist/cjs/salla-orders.cjs.entry.js +2 -2
  36. package/dist/cjs/salla-payments.cjs.entry.js +1 -1
  37. package/dist/cjs/salla-price-range.cjs.entry.js +1 -1
  38. package/dist/cjs/salla-review-card.cjs.entry.js +1 -1
  39. package/dist/cjs/salla-reviews-page.cjs.entry.js +2 -2
  40. package/dist/cjs/salla-reviews.cjs.entry.js +2 -2
  41. package/dist/cjs/salla-social.cjs.entry.js +1 -1
  42. package/dist/cjs/salla-tiered-offer.cjs.entry.js +1 -1
  43. package/dist/cjs/salla-tooltip.cjs.entry.js +1 -1
  44. package/dist/cjs/salla-trust-badges.cjs.entry.js +1 -1
  45. package/dist/cjs/salla-verify.cjs.entry.js +1 -1
  46. package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
  47. package/dist/cjs/twilight.cjs.js +1 -1
  48. package/dist/cjs/{vanilla-picker-CYHmsxIw.js → vanilla-picker-Dq7F5bE1.js} +1 -1
  49. package/dist/collection/Helpers/Helper.js +14 -0
  50. package/dist/collection/components/salla-products-list/salla-products-list.js +9 -22
  51. package/dist/collection/components/salla-products-slider/salla-products-slider.js +9 -7
  52. package/dist/components/Helper.js +14 -0
  53. package/dist/components/index.js +2 -2
  54. package/dist/components/salla-products-list2.js +7 -20
  55. package/dist/components/salla-products-slider2.js +7 -5
  56. package/dist/esm/{Helper-Bt5Zv9cl.js → Helper-B5RLi6Xo.js} +14 -0
  57. package/dist/esm/{filepond-DDOVDszb.js → filepond-Dg4ZKM-u.js} +1 -1
  58. package/dist/esm/{filepond-plugin-file-poster-DK5QZAmf.js → filepond-plugin-file-poster-BUIjdsnA.js} +1 -1
  59. package/dist/esm/{filepond-plugin-file-validate-size-BoUr1T-f.js → filepond-plugin-file-validate-size-DgZMMqmi.js} +1 -1
  60. package/dist/esm/{filepond-plugin-file-validate-type-USfq-Egq.js → filepond-plugin-file-validate-type-DA9tDSFr.js} +1 -1
  61. package/dist/esm/{filepond-plugin-image-edit-BzsOppMe.js → filepond-plugin-image-edit-dotdnN4Z.js} +1 -1
  62. package/dist/esm/{filepond-plugin-image-exif-orientation-D2x3fkHF.js → filepond-plugin-image-exif-orientation-oSI8aLU-.js} +1 -1
  63. package/dist/esm/{filepond-plugin-image-preview-CAbtIGaT.js → filepond-plugin-image-preview-DEefQK61.js} +1 -1
  64. package/dist/esm/{index-unlRcuKr.js → index-B7E8Tmgi.js} +1 -1
  65. package/dist/esm/{index-CkAdPgup.js → index-D2-TtAhI.js} +2 -2
  66. package/dist/esm/loader.js +2 -2
  67. package/dist/esm/salla-accordion_62.entry.js +25 -36
  68. package/dist/esm/salla-advertisement.entry.js +1 -1
  69. package/dist/esm/salla-app-install-alert.entry.js +1 -1
  70. package/dist/esm/salla-apps-icons.entry.js +1 -1
  71. package/dist/esm/salla-cart-item-offers.entry.js +1 -1
  72. package/dist/esm/salla-conditional-offer.entry.js +1 -1
  73. package/dist/esm/salla-contacts.entry.js +1 -1
  74. package/dist/esm/salla-custom-fields.entry.js +1 -1
  75. package/dist/esm/salla-filters-widget.entry.js +2 -2
  76. package/dist/esm/salla-filters.entry.js +2 -2
  77. package/dist/esm/salla-hook.entry.js +1 -1
  78. package/dist/esm/salla-installment.entry.js +1 -1
  79. package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
  80. package/dist/esm/salla-loyalty-program.entry.js +1 -1
  81. package/dist/esm/salla-metadata.entry.js +1 -1
  82. package/dist/esm/salla-notification-item.entry.js +1 -1
  83. package/dist/esm/salla-notifications.entry.js +2 -2
  84. package/dist/esm/salla-offer.entry.js +1 -1
  85. package/dist/esm/salla-order-details-multiple-bundle-product.entry.js +1 -1
  86. package/dist/esm/salla-order-details-options.entry.js +1 -1
  87. package/dist/esm/salla-order-details.entry.js +1 -1
  88. package/dist/esm/salla-order-summary.entry.js +1 -1
  89. package/dist/esm/salla-order-totals-card.entry.js +1 -1
  90. package/dist/esm/salla-orders.entry.js +2 -2
  91. package/dist/esm/salla-payments.entry.js +1 -1
  92. package/dist/esm/salla-price-range.entry.js +1 -1
  93. package/dist/esm/salla-review-card.entry.js +1 -1
  94. package/dist/esm/salla-reviews-page.entry.js +2 -2
  95. package/dist/esm/salla-reviews.entry.js +2 -2
  96. package/dist/esm/salla-social.entry.js +1 -1
  97. package/dist/esm/salla-tiered-offer.entry.js +1 -1
  98. package/dist/esm/salla-tooltip.entry.js +1 -1
  99. package/dist/esm/salla-trust-badges.entry.js +1 -1
  100. package/dist/esm/salla-verify.entry.js +1 -1
  101. package/dist/esm/salla-wallet.entry.js +1 -1
  102. package/dist/esm/twilight.js +2 -2
  103. package/dist/esm/{vanilla-picker-7Rdeecyw.js → vanilla-picker-DkUGzUrx.js} +1 -1
  104. package/dist/twilight/{p-aa32cabd.entry.js → p-01bccbf2.entry.js} +1 -1
  105. package/dist/twilight/{p-815175b1.entry.js → p-0effc34b.entry.js} +1 -1
  106. package/dist/twilight/{p-843a8d82.entry.js → p-22d83528.entry.js} +1 -1
  107. package/dist/twilight/{p-9b1184eb.entry.js → p-2aa0a4e2.entry.js} +1 -1
  108. package/dist/twilight/{p-478033b6.entry.js → p-30403778.entry.js} +1 -1
  109. package/dist/twilight/{p-0eb554c0.entry.js → p-3a74b551.entry.js} +1 -1
  110. package/dist/twilight/{p-6c0dd774.entry.js → p-4a594c06.entry.js} +1 -1
  111. package/dist/twilight/p-4e416704.entry.js +4 -0
  112. package/dist/twilight/{p-57bf3aff.entry.js → p-5dbf4cec.entry.js} +1 -1
  113. package/dist/twilight/{p-c4f190b2.entry.js → p-67c327a8.entry.js} +1 -1
  114. package/dist/twilight/{p-b6cddbff.entry.js → p-6b0a03f6.entry.js} +1 -1
  115. package/dist/twilight/{p-a4b3ddc4.entry.js → p-6c2807c8.entry.js} +1 -1
  116. package/dist/twilight/{p-c5ac1d40.entry.js → p-6ce3f119.entry.js} +1 -1
  117. package/dist/twilight/{p-b9648b3c.entry.js → p-6d886b96.entry.js} +1 -1
  118. package/dist/twilight/{p-b8872e5f.entry.js → p-7b3ca138.entry.js} +1 -1
  119. package/dist/twilight/{p-bd0fda0b.entry.js → p-81df7a2e.entry.js} +1 -1
  120. package/dist/twilight/{p-7c33b8f3.entry.js → p-8e7fa4a9.entry.js} +1 -1
  121. package/dist/twilight/{p-0587a19b.entry.js → p-933881d3.entry.js} +1 -1
  122. package/dist/twilight/{p-4bb743c7.entry.js → p-9b8f5399.entry.js} +1 -1
  123. package/dist/twilight/{p-affbe255.entry.js → p-9d35196f.entry.js} +1 -1
  124. package/dist/twilight/{p-1d2131a2.entry.js → p-9fa5ffcf.entry.js} +1 -1
  125. package/dist/twilight/{p-BY-pqCWB.js → p-B0ba6Gec.js} +2 -2
  126. package/dist/twilight/{p-BgVF6sgk.js → p-C2bMx7q5.js} +1 -1
  127. package/dist/twilight/{p-De1xuTRp.js → p-Cmkcwiop.js} +1 -1
  128. package/dist/twilight/{p-BHSXg2s-.js → p-Czq4p9Qp.js} +1 -1
  129. package/dist/twilight/{p-CkAdPgup.js → p-D2-TtAhI.js} +1 -1
  130. package/dist/twilight/{p-DGD3SzSN.js → p-DJ557xys.js} +1 -1
  131. package/dist/twilight/{p-Ciq2A6DK.js → p-DPqkW1aD.js} +2 -2
  132. package/dist/twilight/p-DgNC8L6e.js +4 -0
  133. package/dist/twilight/{p-BXAV6QCo.js → p-DhcC83-2.js} +1 -1
  134. package/dist/twilight/{p-BCXFmuAu.js → p-_JhF_Kvb.js} +1 -1
  135. package/dist/twilight/{p-100f7787.entry.js → p-a42d626d.entry.js} +1 -1
  136. package/dist/twilight/{p-17618bb7.entry.js → p-a858523c.entry.js} +1 -1
  137. package/dist/twilight/{p-d72fc67d.entry.js → p-b1af2aca.entry.js} +1 -1
  138. package/dist/twilight/{p-25e36e28.entry.js → p-b208650b.entry.js} +1 -1
  139. package/dist/twilight/{p-0162ae20.entry.js → p-b9d0212c.entry.js} +1 -1
  140. package/dist/twilight/{p-8565cac6.entry.js → p-cf66ab4d.entry.js} +1 -1
  141. package/dist/twilight/{p-50e1eb99.entry.js → p-d4faa0f6.entry.js} +1 -1
  142. package/dist/twilight/{p-b5b851dc.entry.js → p-db526796.entry.js} +1 -1
  143. package/dist/twilight/{p-b8e7613a.entry.js → p-e26cc25b.entry.js} +1 -1
  144. package/dist/twilight/{p-abcf3b2d.entry.js → p-e5c01983.entry.js} +1 -1
  145. package/dist/twilight/{p-c18da320.entry.js → p-e73c28a8.entry.js} +1 -1
  146. package/dist/twilight/{p-a61b0f9c.entry.js → p-ed60a726.entry.js} +1 -1
  147. package/dist/twilight/{p-50098fb9.entry.js → p-f6ffc708.entry.js} +1 -1
  148. package/dist/twilight/{p-e5dc45dc.entry.js → p-fea62668.entry.js} +1 -1
  149. package/dist/twilight/{p-DhexS4-2.js → p-q-O0srMP.js} +1 -1
  150. package/dist/twilight/twilight.esm.js +1 -1
  151. package/dist/types/Helpers/Helper.d.ts +2 -0
  152. package/dist/types/components/salla-products-list/salla-products-list.d.ts +1 -1
  153. package/dist/types/components/salla-products-slider/salla-products-slider.d.ts +1 -1
  154. package/dist/types/components.d.ts +4 -4
  155. package/package.json +5 -5
  156. package/dist/twilight/p-82f05641.entry.js +0 -4
  157. package/dist/twilight/p-Dljb4XCt.js +0 -4
@@ -1,4 +0,0 @@
1
- /*!
2
- * Crafted with ❤ by Salla
3
- */
4
- import{a as e}from"./p-CgtvEd63.js";salla.event.setMaxListeners(100);var t=new class{setIncludes(e){return this.includes=e,this}toggleElementClassIf(e,t,a,r){t=Array.isArray(t)?t:t.split(" "),a=Array.isArray(a)?a:a.split(" ");let n=r(e);return e?.classList.remove(...n?a:t),e?.classList.add(...n?t:a),this}toggleClassIf(e,t,a,r){return document.querySelectorAll(e).forEach((e=>this.toggleElementClassIf(e,t,a,r))),this}isValidEmail(e){return/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(String(e).toLowerCase())}filterEmojies(e){return e.replace(/(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff]|[\u0023-\u0039]\ufe0f?\u20e3|\u3299|\u3297|\u303d|\u3030|\u24c2|\ud83c[\udd70-\udd71]|\ud83c[\udd7e-\udd7f]|\ud83c\udd8e|\ud83c[\udd91-\udd9a]|\ud83c[\udde6-\uddff]|\ud83c[\ude01-\ude02]|\ud83c\ude1a|\ud83c\ude2f|\ud83c[\ude32-\ude3a]|\ud83c[\ude50-\ude51]|\u203c|\u2049|[\u25aa-\u25ab]|\u25b6|\u25c0|[\u25fb-\u25fe]|\u00a9|\u00ae|\u2122|\u2139|\ud83c\udc04|[\u2600-\u26FF]|\u2b05|\u2b06|\u2b07|\u2b1b|\u2b1c|\u2b50|\u2b55|\u231a|\u231b|\u2328|\u23cf|[\u23e9-\u23f3]|[\u23f8-\u23fa]|\ud83c\udccf|\u2934|\u2935|[\u2190-\u21ff])/g,"")}debounce(e,...t){return this.debounce_||(this.debounce_=salla.helpers.debounce(((e,...t)=>e(...t)),500)),this.debounce_(e,...t)}getProductsSource(e){return{"brands.single":"brands","product.index":"categories","product.index.latest":"latest","product.index.offers":"offers","product.index.search":"search","customer.wishlist":"wishlist","landing-page":"landing-page","product.index.tag":"tags","product.index.sales":"sales","components.most_sales_products":"sales"}[e||salla.config.get("page.slug")]||e||"latest"}getPageTitleForSource(e){return(e={brands:"common.titles.brands",latest:"blocks.home.latest_products",offers:"common.titles.discounts",reorder:"common.titles.products",sales:"common.titles.most_sales"}[e])?salla.lang.get(e):""}getProductsSourceValue(e,t){const a=this.getProductsSource(e);let r=null;if(t)try{r="string"==typeof t?JSON.parse(t):t}catch(e){console.error("Failed to parse JSON string in sourceValue:",e)}if(!["search","json","offers","latest","sales","related"].includes(a)){if(Array.isArray(r)&&r.length)return r;if(Array.isArray(r)&&!r.length)return"";if("number"==typeof r)return[r];if(!t&&["categories","tags","brands"].includes(e))return[salla.config.get("page.id")]}return r||t?r||t:"search"===a?new URLSearchParams(window.location.search).get("q")||"":salla.config.get("page.id")}extractFiltersFromUrl(e){let t={};return e.forEach(((e,a)=>{const r=a.match(/^filters\[(.*?)\](\[(.*?)\])?$/u);if(r){const a=r[1],n=r[3];n?(t[a]=t[a]||{},t[a][n]=e):t[a]=e}else{const r=a.match(/^(.*?)$/u);r&&(t[r[1]]=e)}})),t}async injectExtraFieldsToResponse(e){if(!e||!this.includes)return e;const t=e.data.map((e=>e.id));try{const{data:a}=await this.fetchImagesAndOptions(t);if(this.injectOptionsAndImages(e.data,a),!this.includes.includes("metadata"))return e;const r=await salla.api.metadata.fetchValues("product",t);return e.data.forEach((e=>{e.metadata=r.data.find((t=>parseInt(t.entity_id)===parseInt(e.id)))})),e}catch(e){throw console.error("Error in injectExtraFieldsToResponse:",e),e}}fetchImagesAndOptions(e){return this.productsIncludes().length?salla.api.product.fetchOptions(e,{with:this.productsIncludes()}):Promise.resolve({data:[]})}injectOptionsAndImages(e,t){return t.length?e.map((e=>(this.includes.filter((e=>"metadata"!==e)).forEach((a=>{const r=t.find((t=>parseInt(t.id)===parseInt(e.id)));e[a]=r?r[a]:null})),e))):null}productsIncludes(){return this.includes?.filter((e=>"metadata"!=e))}parseJson(e){if("string"!=typeof e)return e;try{return JSON.parse(e)}catch(e){salla.logger.error("Failed to parse includes as JSON:",e)}return null}getProductSchemaMarkupScript(e){const t=document.createElement("script");return t.type="application/ld+json",t.text=JSON.stringify({"@context":"http://schema.org","@type":"Product",name:e?.name,image:e?.image?.url||e?.thumbnail,description:e?.description,brand:{"@type":"Brand",logo:e?.brand?.logo},offers:{"@type":"Offer",price:e?.price}}),t}createProductSchema(e,t){let a={productID:`${e.id}`,"@type":"Product",name:e.name,url:e.url,image:e.image.url||e.image,description:e.description||e.subtitle||e.name,...e.sku&&e.sku.length>0&&{sku:e.sku},offers:{"@type":"Offer",url:e.url,priceCurrency:e.currency,price:e.price,itemCondition:"NewCondition",availability:e.is_available?"InStock":"OutOfStock",priceValidUntil:e.discount_ends||new Date((new Date).setDate((new Date).getDate()+7)).toISOString().split("T")[0],priceSpecification:{"@type":"PriceSpecification",price:e.regular_price,priceCurrency:e.currency,valueAddedTaxIncluded:e.is_taxable},seller:{"@type":"Organization",name:salla.config.get("store.name")},shippingDetails:{"@type":"OfferShippingDetails",shippingRate:{"@type":"MonetaryAmount",value:"0",currency:e.currency||"SAR"},deliveryTime:{"@type":"ShippingDeliveryTime",businessDays:{"@type":"OpeningHoursSpecification",dayOfWeek:["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"]},cutoffTime:"14:00"}},hasMerchantReturnPolicy:{"@type":"MerchantReturnPolicy",returnPolicyCategory:"https://schema.org/MerchantReturnFiniteReturnWindow",merchantReturnDays:30,returnMethod:"https://schema.org/ReturnByMail",returnFees:"https://schema.org/FreeReturn"}}};return e.rating?.stars&&(a.aggregateRating={"@type":"AggregateRating",ratingValue:e.rating.stars,reviewCount:e.rating.count}),{"@type":"ListItem",position:t,item:a}}generateProductSchema(e){const t="salla-product-schema-script";if(document.getElementById(t))return void salla.logger.warn(`already added schema-script with id (${t})!`);const a=document.createElement("script");a.type="application/ld+json",a.id=t;const r={"@context":"https://schema.org","@type":"ItemList",name:salla.config.get("page.title"),itemListElement:e.map(((e,t)=>this.createProductSchema(e,t+1)))};a.textContent=JSON.stringify(r),document.head.appendChild(a)}formatDateFromString(e,t,a="en"){const r={en:"Invalid Date",ar:"تاريخ غير صالح"};if(!e||"string"!=typeof e||""===e.trim())return r[a];let n;if(/^\d+$/.test(e)){const t=parseInt(e);n=new Date(t>1e12?t:1e3*t)}else n=new Date(e);return isNaN(n.getTime())?r[a]:`${{en:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],ar:["الأحد","الاثنين","الثلاثاء","الأربعاء","الخميس","الجمعة","السبت"]}[a][n.getDay()]} ${t(n.getDate(),"en"===a)} ${{en:["January","February","March","April","May","June","July","August","September","October","November","December"],ar:["يناير","فبراير","مارس","أبريل","مايو","يونيو","يوليو","أغسطس","سبتمبر","أكتوبر","نوفمبر","ديسمبر"]}[a][n.getMonth()]} ${t(n.getFullYear(),"en"===a)}`}copyToClipboard(e){var t=e.target.innerText;navigator.clipboard.writeText(t).then((()=>{console.log("Text copied to clipboard: "+t)})).catch((e=>{console.error("Unable to copy text to clipboard",e)}))}animateItems(t){t&&e({targets:t,opacity:[0,1],duration:1200,translateY:[20,0],delay:function(e,t){return 100*t},easing:"easeOutExpo",complete:function(){t.forEach((e=>{e.classList.add("animated")}))}})}createReviewObject(e){return{"@type":"Review",author:{"@type":"Person",name:e.name},reviewBody:e.content,reviewRating:{"@type":"Rating",bestRating:"5",ratingValue:e.stars,worstRating:"1"}}}generateReviewSchema(e){const t=document.createElement("script");t.type="application/ld+json";const a={"@context":"http://schema.org/","@type":"Store",name:salla.config.get("store.name"),url:salla.config.get("store.url"),address:"الرياض",review:e.map((e=>this.createReviewObject(e))),aggregateRating:{"@type":"AggregateRating",ratingValue:e.reduce(((e,t)=>e+t.stars),0)/e.length,reviewCount:e.length}};t.textContent=JSON.stringify(a),document.head.appendChild(t)}};export{t as H}