import{a as x,u as f,i as T,ap as V,j as d,f as $,aX as b,cm as R}from"./main-634.js";import{b as A,a as E}from"./bf-400-72.js";import{n as F,o as S}from"./bf-692-111.js";import{e as g}from"./bf-25-81.js";function N({id:r,fk:s}){var n,c;const{css:m}=x(),e=f(A)||{},[i,a]=T(b),u=V(R),z=f(E),p=Object.keys((e==null?void 0:e.fields)||{});let o=!1;s?o=("fields"in i&&((n=i.fields[s])==null?void 0:n.fieldSize))!==("fields"in e&&((c=e==null?void 0:e.fields[s])==null?void 0:c.fieldSize)):o=("fields"in i&&(i==null?void 0:i.fieldsSize))!==("fields"in e&&(e==null?void 0:e.fieldsSize));const h=()=>{a(j=>$(j,l=>{s?(l.fields[s].fieldSize=e==null?void 0:e.fields[s].fieldSize,l.fields[s].classes=e==null?void 0:e.fields[s].classes):(l.fieldsSize=e==null?void 0:e.fieldsSize,p.forEach(t=>{l.fields[t].fieldSize=e==null?void 0:e.fields[t].fieldSize,l.fields[t].classes=e==null?void 0:e.fields[t].classes}))})),s||u(z)};return o?d.jsx(g,{msg:"Reset style",children:d.jsx("button",{onClick:h,className:m(F.resetBtn),type:"button","data-testid":`${r}-reset-style`,children:d.jsx(S,{size:"20"})})}):null}export{N as T};
