File "product-average-rating.js"
Full Path: /home/jlklyejr/public_html/wp-content/test/wp-content/plugins/woocommerce/assets/client/blocks/product-average-rating.js
File size: 3.18 KB
MIME-type: text/plain
Charset: utf-8
"use strict";(self.webpackChunkwebpackWcBlocksJsonp=self.webpackChunkwebpackWcBlocksJsonp||[]).push([[3037],{921:(t,o,n)=>{n.r(o),n.d(o,{Block:()=>u,default:()=>d});var e=n(9196),l=n(3849),r=n.n(l),s=n(2864),a=n(947),c=n(5736),i=n(721);const u=t=>{const{textAlign:o}=t,n=(0,a.F)(t),{product:l}=(0,s.useProductDataContext)(),i=r()(n.className,"wc-block-components-product-average-rating",{[`has-text-align-${o}`]:o});return(0,e.createElement)("div",{className:i,style:n.style},Number(l.average_rating)>0?l.average_rating:(0,c.__)("No ratings","woocommerce"))},d=(0,i.withProductDataContext)(u)},947:(t,o,n)=>{n.d(o,{F:()=>i});var e=n(3849),l=n.n(e),r=n(7998),s=n(3243),a=n(3392),c=n(172);const i=t=>{const o=(t=>{const o=(0,r.Kn)(t)?t:{style:{}};let n=o.style;return(0,s.H)(n)&&(n=JSON.parse(n)||{}),(0,r.Kn)(n)||(n={}),{...o,style:n}})(t),n=(0,c.vc)(o),e=(0,c.l8)(o),i=(0,c.su)(o),u=(0,a.f)(o);return{className:l()(u.className,n.className,e.className,i.className),style:{...u.style,...n.style,...e.style,...i.style}}}},3392:(t,o,n)=>{n.d(o,{f:()=>r});var e=n(7998),l=n(3243);const r=t=>{const o=(0,e.Kn)(t.style.typography)?t.style.typography:{},n=(0,l.H)(o.fontFamily)?o.fontFamily:"";return{className:t.fontFamily?`has-${t.fontFamily}-font-family`:n,style:{fontSize:t.fontSize?`var(--wp--preset--font-size--${t.fontSize})`:o.fontSize,fontStyle:o.fontStyle,fontWeight:o.fontWeight,letterSpacing:o.letterSpacing,lineHeight:o.lineHeight,textDecoration:o.textDecoration,textTransform:o.textTransform}}}},172:(t,o,n)=>{n.d(o,{l8:()=>d,su:()=>v,vc:()=>u});var e=n(3849),l=n.n(e),r=n(7427),s=n(2289),a=n(7998);function c(t={}){const o={};return(0,s.getCSSRules)(t,{selector:""}).forEach((t=>{o[t.key]=t.value})),o}function i(t,o){return t&&o?`has-${(0,r.o)(o)}-${t}`:""}function u(t){var o,n,e,r,s,u,d;const{backgroundColor:v,textColor:f,gradient:y,style:g}=t,m=i("background-color",v),p=i("color",f),b=function(t){if(t)return`has-${t}-gradient-background`}(y),h=b||(null==g||null===(o=g.color)||void 0===o?void 0:o.gradient);return{className:l()(p,b,{[m]:!h&&!!m,"has-text-color":f||(null==g||null===(n=g.color)||void 0===n?void 0:n.text),"has-background":v||(null==g||null===(e=g.color)||void 0===e?void 0:e.background)||y||(null==g||null===(r=g.color)||void 0===r?void 0:r.gradient),"has-link-color":(0,a.Kn)(null==g||null===(s=g.elements)||void 0===s?void 0:s.link)?null==g||null===(u=g.elements)||void 0===u||null===(d=u.link)||void 0===d?void 0:d.color:void 0}),style:c({color:(null==g?void 0:g.color)||{}})}}function d(t){var o;const n=(null===(o=t.style)||void 0===o?void 0:o.border)||{};return{className:function(t){var o;const{borderColor:n,style:e}=t,r=n?i("border-color",n):"";return l()({"has-border-color":!!n||!(null==e||null===(o=e.border)||void 0===o||!o.color),[r]:!!r})}(t),style:c({border:n})}}function v(t){var o;return{className:void 0,style:c({spacing:(null===(o=t.style)||void 0===o?void 0:o.spacing)||{}})}}},2893:(t,o,n)=>{n.d(o,{F:()=>e});const e=t=>null===t},7998:(t,o,n)=>{n.d(o,{$n:()=>r,Kn:()=>l,Qr:()=>s});var e=n(2893);const l=t=>!(0,e.F)(t)&&t instanceof Object&&t.constructor===Object;function r(t,o){return l(t)&&o in t}const s=t=>0===Object.keys(t).length},3243:(t,o,n)=>{n.d(o,{H:()=>e});const e=t=>"string"==typeof t}}]);