'use client';
import{jsxs as e,jsx as r,Fragment as o}from"react/jsx-runtime";import t from"../../../text/components/Text.js";import{createClass as i,createAttr as m}from"@gem-sdk/system";import{getWrapperClasses as s}from"./common/classes.js";import{getAttrs as c}from"./common/attrs.js";import{getTextProps as p}from"./common/helpers.js";import{useGpPrice as d}from"./hooks/useGpPrice.js";import{useEditorMode as l,filterToolbarPreview as a}from"@gem-sdk/core";let ProductPrice=n=>{let{style:f,children:h}=n,g=l(),x="edit"===g,{elementRef:u,moneyFormatted:j,currentProductId:P,isNoComparePrice:y,isNoComparePriceILP:k,shouldHiddenComparePrice:N,emitNoDataSignal:v}=d(n),b=i(s(n)),C=m(c(n,{isILP:!x,productId:P,shouldHiddenComparePrice:N})),H=p(n,j),I={visibility:"hidden",opacity:0,maxWidth:0,maxHeight:0},w=k?I:f;return e("div",{ref:u,...C,className:b,style:w,"aria-hidden":"true",onClick:v,children:[y&&x?r(o,{children:r("div",{className:"gp-flex-col gp-flex gp-justify-between gp-p-2",children:r("p",{className:"gp-text-[#212121] gp-text-[12px] gp-leading-3 ",children:"No compare price"})})}):e(o,{children:[r(t,{...H}),h]}),a(h,!0)]})};export{ProductPrice as default};
