gf-components 0.1.19 → 0.1.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs.js CHANGED
@@ -386,7 +386,7 @@ html body {
386
386
  font: var(--gf-label-md-default);
387
387
  color: var(--gf-color-button-primary);
388
388
  text-decoration-line: underline;
389
- `,xw=({title:e,subtitle:t,listTitle:r,items:n,gap:a,...o})=>{const i=s=>{if(typeof s!="string"){const l=s.current.getBoundingClientRect().top+window.scrollY-(a||0);window.scroll({top:l,behavior:"smooth"})}};return re.jsxs(re.Fragment,{children:[re.jsx(Pr,{}),re.jsx(yw,{cardtype:"default",title:re.jsx(Wv,{title:e,subtitle:t,type:"header"}),...o,children:re.jsxs(ti,{vertical:!0,gap:8,style:{alignItems:"start"},children:[re.jsx(Cw,{children:r||"Table of contents"}),n.map((s,l)=>re.jsx(Sw,{type:"link",href:typeof s.href=="string"?s.href:void 0,onClick:()=>i(s.href),children:s.name},`button-select-item-${l}`))]})})]})},Ew=({tabList:e,tabContent:t,expandContent:r,expandLabel:n,handleDownload:a,...o})=>{var v;const[i,s]=P.useState((v=e==null?void 0:e[0])==null?void 0:v.key),[l,u]=P.useState(!1),d=b=>{s(b)},f=()=>{u(b=>!b)};return re.jsxs(re.Fragment,{children:[re.jsx(Pr,{}),re.jsx(Wa,{className:"gf-full-width gf-override-ant-card-actions",tabList:e,cardtype:"default",activeTabKey:i,onTabChange:d,tabBarExtraContent:re.jsx(zv,{onClick:a}),actions:r!=null&&r[i]?[re.jsxs(ti,{vertical:!0,children:[re.jsx(kv,{open:l,onClick:f,children:n}),l&&(r==null?void 0:r[i])]})]:void 0,...o,children:t==null?void 0:t[i]})]})},{Paragraph:ww,Text:Gv}=_r,$w=tt(Wa)`
389
+ `,xw=({title:e,subtitle:t,listTitle:r,items:n,gap:a,...o})=>{const i=s=>{if(typeof s!="string"){const l=s.current.getBoundingClientRect().top+window.scrollY-(a||0);window.scroll({top:l,behavior:"smooth"})}};return re.jsxs(re.Fragment,{children:[re.jsx(Pr,{}),re.jsx(yw,{cardtype:"default",title:re.jsx(Wv,{title:e,subtitle:t,type:"header"}),...o,children:re.jsxs(ti,{vertical:!0,gap:8,style:{alignItems:"start"},children:[re.jsx(Cw,{children:r||"Table of contents"}),n.map((s,l)=>re.jsx(Sw,{type:"link",href:typeof s.href=="string"?s.href:void 0,onClick:()=>i(s.href),children:s.name},`button-select-item-${l}`))]})})]})},Ew=({tabList:e,tabContent:t,expandContent:r,expandLabel:n,padding:a=24,handleDownload:o,...i})=>{var b;const[s,l]=P.useState((b=e==null?void 0:e[0])==null?void 0:b.key),[u,d]=P.useState(!1),f=h=>{l(h)},v=()=>{d(h=>!h)};return re.jsxs(re.Fragment,{children:[re.jsx(Pr,{}),re.jsx(Wa,{className:"gf-full-width gf-override-ant-card-actions",tabList:e,cardtype:"default",activeTabKey:s,onTabChange:f,tabBarExtraContent:re.jsx(zv,{onClick:o}),actions:r!=null&&r[s]?[re.jsxs(ti,{vertical:!0,children:[re.jsx(kv,{open:u,onClick:v,children:n}),u&&(r==null?void 0:r[s])]})]:void 0,styles:{header:{padding:`0px ${a}`},body:{padding:a}},...i,children:t==null?void 0:t[s]})]})},{Paragraph:ww,Text:Gv}=_r,$w=tt(Wa)`
390
390
  min-width: 226px;
391
391
  `,Ow=tt(Gv)`
392
392
  font: var(--gf-header-h1);