"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var core=require("@gem-sdk/core"),system=require("@gem-sdk/system"),styles=require("../common/styles.js"),classes=require("../common/classes.js");const CSSCode=({setting:e,style:s,advanced:r,builderAttrs:t,builderProps:a})=>{let{background:l,preloadBgImage:o}=e??{},i=r?.editorData,c=i?.html?.trim(),d=system.createStyle(styles.getCodeStyle(s,e,!0)),m=system.createClass(classes.getCodeClasses(a?.uid,!i?.html&&!l,r?.cssClass));return core.template`
  ${core.RenderIf(!!o,`${core.RenderIf(!!l?.desktop?.image?.src,`<link rel="preload" href="${l?.desktop?.image?.src}" as="image" />`)}${core.RenderIf(!!l?.tablet?.image?.src,`<link rel="preload" href="${l?.tablet?.image?.src}" as="image" />`)}${core.RenderIf(!!l?.mobile?.image?.src,`<link rel="preload" href="${l?.mobile?.image?.src}" as="image" />`)}`)}
    <div
      ${{...t}}
      style="${d}"
      data-keep-class="true"
      class="${m}">
      <div>
    ${c}
    </div>
    </div>
  `};exports.default=CSSCode;
