import{composeAdvanceStyle as s,template as e,WrapRenderChildren as i,RenderChildren as r}from"@gem-sdk/core";import{getStaticLocale as a}from"../../helpers.js";import{createStyle as o,createClass as t,If as m}from"@gem-sdk/system";import{getContainerStyles as l,getUlStyles as d,getWrapperStyles as c}from"../common/styles.js";import{getUlClasses as n,getWrapperClasses as p}from"../common/classes.js";let IconList=({builderProps:$,style:u,setting:f,rawChildren:g,styles:k,advanced:v})=>{let{preload:y}=f||{},{background:b}=k||{},h=s(v),I=o(l(u,k,{advancedClasses:h,isLiquid:!0})),L=t(n(v?.cssClass)),j=o(d(k)),x=o(c(k)),C=t(p());return e`
    ${m(!!y,`${m(!!b?.desktop?.image?.src,`<link rel="preload" href="${b?.desktop?.image?.src}" as="image" />`)}
      ${m(!!b?.tablet?.image?.src,`<link rel="preload" href="${b?.tablet?.image?.src}" as="image" />`)}
      ${m(!!b?.mobile?.image?.src,`<link rel="preload" href="${b?.mobile?.image?.src}" as="image" />`)}`)}
    <div class="${C}" style="${x}">
    <div
      data-id="${$?.uid}"
       style="${I}">
     ${m(!g,e`<div>${a("IconList","icons_not_found")}</div>`)}
     ${m(!!g,e`<ul
        class="${L}"
        style="${j}"
        >
        ${i({uid:$?.uid??"",customProps:g?.[0].customProps},g?.map((s,e)=>{if(s)return r({...s,dataIndex:e,parentUid:$?.uid,parentStyles:k})}))}
      </ul>`)}
  </div>
  </div>
  `};export{IconList as default};
