"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var core=require("@gem-sdk/core"),helpers$1=require("../../../helpers.js"),Text_liquid=require("../../../text/components/Text.liquid.js"),system=require("@gem-sdk/system"),classes=require("./common/classes.js"),attrs=require("./common/attrs.js"),helpers=require("./common/helpers.js");const ProductPrice=e=>{let{style:r,setting:s,builderProps:t,pageContext:c}=e,o=system.createClass(classes.getWrapperClasses(e)),p=system.createAttr(attrs.getAttrs(e)),a=helpers.getTextProps(e),i=system.createStateOrContext({priceType:s?.priceType,uid:t?.uid,locale:"{{shop.locale}}",currency:"{{shop.currency}}",moneyFormat:`{{ ${c?.showPriceCurrency?"shop.money_with_currency_format":"shop.money_format"} | replace: '"', '\\"' | escape }}`}),l=()=>{let e=core.isLocalEnv?"{{ 'gp-product-price-v7-5.js' | asset_url }}":`${core.baseAssetURL}/assets-v2/gp-product-price-v7-5.js?v={{ shop.metafields.GEMPAGES.ASSETS_VERSION }}`;return`<script ${helpers$1.getSettingPreloadData('class="gps-link" delay',"src")}="${e}" defer="defer"></script>`};return system.Liquid(core.template`
      <gp-product-price
        ${p}
        class="${o}"
        style="${r}"
        gp-data='${core.dataStringify(i)}'
      >
        ${Text_liquid.default(a)}
      </gp-product-price>
      ${l()}
  `)};exports.ProductPrice=ProductPrice,exports.default=ProductPrice;
