@harpercollins/harpercollins-design-system 1.22.1 → 1.22.2

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/esm/index.js CHANGED
@@ -819,7 +819,7 @@ function Fx(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof
819
819
  flex-direction: column;
820
820
  height: 100vh;
821
821
  width: 100%;
822
- `;function G_({children:n,header:o,theme:a="light_internal",showSidebar:i,sidebarContent:l,sidebarWidth:s=240,collapsedSidebarWidth:c=60,sidebarHeaderContent:d,footerReleaseName:u}){const[p,f]=r.useState(!0);return e(F_,{theme:a,children:t(q_,{children:[o,t(Rm,{sx:{display:"flex",flex:1},children:[i?e(Y_,{sidebarOpen:p,onSidebarToggle:()=>{f(!p)},sidebarContent:l,sidebarWidth:s,collapsedSidebarWidth:c,headerContent:d}):null,t(Bv,{component:"main",id:"main",sx:{transition:"margin-left 0.3s ease",display:"flex",flexDirection:"column",flex:"1 1 auto",width:{xs:"100%",md:`calc(100% - ${p?s:c}px)`,xl:`calc(100% - ${p?1.25*s:c}px)`}},children:[n,e(W_,{releaseName:u})]})]})]})})}function K_({id:r,options:a,onChange:i,name:l,...s}){const[c,d]=o.useState(s.defaultValue),[u,p]=o.useState(s.defaultValue?.value);return t(n,{children:[e(um,{...s,sx:{"--Input-minHeight":"2.6rem"},id:r,options:a,onChange:(e,t,n)=>{d(t),p(t?t?.value:""),i&&i(e,t,n)},getOptionLabel:e=>e.label,isOptionEqualToValue:(e,t)=>e.value===t.value,value:c,renderOption:s.renderOption,name:""}),e(Cf,{name:l,value:u,type:"hidden",sx:{display:"none"}})]})}const J_=Mx.button`
822
+ `;function G_({children:n,header:r,theme:o="light_internal",showSidebar:a,sidebarContent:i,sidebarWidth:l=240,collapsedSidebarWidth:s=60,sidebarHeaderContent:c,footerReleaseName:d}){const[u,p]=OT("sidebarOpen",!0);return e(F_,{theme:o,children:t(q_,{children:[r,t(Rm,{sx:{display:"flex",flex:1},children:[a?e(Y_,{sidebarOpen:u,onSidebarToggle:()=>{p(!u)},sidebarContent:i,sidebarWidth:l,collapsedSidebarWidth:s,headerContent:c}):null,t(Bv,{component:"main",id:"main",sx:{transition:"margin-left 0.3s ease",display:"flex",flexDirection:"column",flex:"1 1 auto",width:{xs:"100%",md:`calc(100% - ${u?l:s}px)`,xl:`calc(100% - ${u?1.25*l:s}px)`}},children:[n,e(W_,{releaseName:d})]})]})]})})}function K_({id:r,options:a,onChange:i,name:l,...s}){const[c,d]=o.useState(s.defaultValue),[u,p]=o.useState(s.defaultValue?.value);return t(n,{children:[e(um,{...s,sx:{"--Input-minHeight":"2.6rem"},id:r,options:a,onChange:(e,t,n)=>{d(t),p(t?t?.value:""),i&&i(e,t,n)},getOptionLabel:e=>e.label,isOptionEqualToValue:(e,t)=>e.value===t.value,value:c,renderOption:s.renderOption,name:""}),e(Cf,{name:l,value:u,type:"hidden",sx:{display:"none"}})]})}const J_=Mx.button`
823
823
  float: right;
824
824
  border: none;
825
825
  background: none;