/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
import{a as v}from"./JD74LG7K.js";import{d as S}from"./IJQZON2Z.js";import{P as d,R as g,b as m,c as h,d as p}from"./IXZEUVT2.js";var x=Symbol.for(""),y=t=>{if(t?.r===x)return t?._$litStatic$},_=t=>({_$litStatic$:t,r:x});var M=new Map,u=t=>(a,...s)=>{let r=s.length,n,o,i=[],l=[],c,e=0,$=!1;for(;e<r;){for(c=a[e];e<r&&(o=s[e],(n=y(o))!==void 0);)c+=n+a[++e],$=!0;e!==r&&l.push(o),i.push(c),e++}if(e===r&&i.push(a[r]),$){let f=i.join("$$lit$$");(a=M.get(f))===void 0&&(i.raw=i,M.set(f,a=i)),s=l}return t(a,...s)},b=u(m),j=u(h),k=u(p);function A({level:t,class:a,id:s,children:r,excludeGlobalCss:n}){let o=w(t),i=`h${o}`,l=_(i);return b`<${l} .ariaLevel=${String(o)} class=${d(S(n?a:v.heading,a))} id=${s??g} role=heading>${r}</${l}>`}function C(t,a,s){return Math.min(Math.max(t,a),s)}function w(t){return C(Math.ceil(t),1,6)}function B(t,a=1){return w(t+a)}export{A as a,B as b};
