@omni-design/components 0.7.1 → 0.7.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/index.esm.js CHANGED
@@ -1,4 +1,4 @@
1
- import*as e from"react";import t,{useState as r,useRef as o,useCallback as n,useEffect as i,useId as a,useContext as l,createContext as s,useMemo as d,forwardRef as c,Children as u,isValidElement as p}from"react";import{Box as h,Badge as m,GlobalStyles as f,Button as g,Avatar as x,Checkbox as b,FormControlLabel as v,TextField as y,InputAdornment as S,FormHelperText as k,Stack as B,Tooltip as w,IconButton as C,Typography as T,Grid as I,Alert as A,Switch as z,ToggleButton as R,ToggleButtonGroup as E,Radio as P,FormControl as O,FormLabel as L,RadioGroup as M,Slider as W,Chip as D,Container as F,Tabs as N,Tab as H,Paper as V,Dialog as Q,DialogTitle as j,DialogContent as G,DialogContentText as U,DialogActions as X,Zoom as K,Grow as q,Fade as J,Slide as Y,AppBar as $,Toolbar as Z,List as _,ListItem as ee,ListItemButton as te,ListItemIcon as re,ListItemText as oe,Collapse as ne,Divider as ie,Drawer as ae,useTheme as le,useMediaQuery as se}from"@mui/material";import{jsx as de,jsxs as ce,Fragment as ue}from"react/jsx-runtime";import pe from"@mui/icons-material/ContentCopy";import he from"@mui/icons-material/Check";import me from"@mui/icons-material/Person";import fe from"@mui/icons-material/Remove";import ge from"@mui/icons-material/CheckCircleOutline";import xe from"@mui/icons-material/WarningAmber";import be from"@mui/icons-material/ErrorOutline";import ve from"@mui/icons-material/InfoOutlined";import ye from"react-dom";import Se from"@mui/icons-material/ExpandMore";import ke from"@mui/icons-material/Favorite";import Be from"@mui/icons-material/Home";import we from"@mui/icons-material/Delete";import Ce from"@mui/icons-material/Settings";import Te from"@mui/icons-material/Search";import Ie from"@mui/icons-material/Star";import Ae from"@mui/icons-material/Notifications";import ze from"@mui/icons-material/Visibility";import Re from"@mui/icons-material/ShoppingCart";import Ee from"@mui/icons-material/Lock";import Pe from"@mui/icons-material/Info";import Oe from"@mui/icons-material/HomeOutlined";import Le from"@mui/icons-material/FavoriteBorderOutlined";import Me from"@mui/icons-material/DeleteOutlined";import We from"@mui/icons-material/SettingsOutlined";import De from"@mui/icons-material/StarOutline";import Fe from"@mui/icons-material/PersonOutlined";import Ne from"@mui/icons-material/NotificationsOutlined";import He from"@mui/icons-material/VisibilityOutlined";import Ve from"@mui/icons-material/ShoppingCartOutlined";import Qe from"@mui/icons-material/LockOutlined";import je from"@mui/icons-material/HomeRounded";import Ge from"@mui/icons-material/FavoriteRounded";import Ue from"@mui/icons-material/DeleteRounded";import Xe from"@mui/icons-material/SettingsRounded";import Ke from"@mui/icons-material/SearchRounded";import qe from"@mui/icons-material/StarRounded";import Je from"@mui/icons-material/PersonRounded";import Ye from"@mui/icons-material/NotificationsRounded";import $e from"@mui/icons-material/VisibilityRounded";import Ze from"@mui/icons-material/ShoppingCartRounded";import _e from"@mui/icons-material/LockRounded";import et from"@mui/icons-material/InfoRounded";import tt from"@mui/icons-material/HomeTwoTone";import rt from"@mui/icons-material/FavoriteTwoTone";import ot from"@mui/icons-material/DeleteTwoTone";import nt from"@mui/icons-material/SettingsTwoTone";import it from"@mui/icons-material/SearchTwoTone";import at from"@mui/icons-material/StarTwoTone";import lt from"@mui/icons-material/PersonTwoTone";import st from"@mui/icons-material/NotificationsTwoTone";import dt from"@mui/icons-material/VisibilityTwoTone";import ct from"@mui/icons-material/ShoppingCartTwoTone";import ut from"@mui/icons-material/LockTwoTone";import pt from"@mui/icons-material/InfoTwoTone";import ht from"@mui/icons-material/HomeSharp";import mt from"@mui/icons-material/FavoriteSharp";import ft from"@mui/icons-material/DeleteSharp";import gt from"@mui/icons-material/SettingsSharp";import xt from"@mui/icons-material/SearchSharp";import bt from"@mui/icons-material/StarSharp";import vt from"@mui/icons-material/PersonSharp";import yt from"@mui/icons-material/NotificationsSharp";import St from"@mui/icons-material/VisibilitySharp";import kt from"@mui/icons-material/ShoppingCartSharp";import Bt from"@mui/icons-material/LockSharp";import wt from"@mui/icons-material/InfoSharp";import Ct from"@mui/icons-material/Code";import Tt from"@mui/icons-material/GridView";import It from"@mui/icons-material/Computer";import At from"@mui/icons-material/Add";import*as zt from"@mui/icons-material";import{Settings as Rt,Close as Et}from"@mui/icons-material";import Pt from"@mui/icons-material/Menu";import Ot from"@mui/icons-material/Close";import Lt from"@mui/icons-material/FormatBold";import Mt from"@mui/icons-material/FormatItalic";import Wt from"@mui/icons-material/FormatUnderlined";import Dt from"@mui/icons-material/FormatAlignLeft";import Ft from"@mui/icons-material/FormatAlignCenter";import Nt from"@mui/icons-material/KeyboardArrowUp";import Ht from"@mui/icons-material/KeyboardArrowDown";import"@mui/icons-material/FormatAlignRight";import"@mui/icons-material/ViewList";import"@mui/icons-material/ViewModule";import Vt from"@mui/material/CircularProgress";import"@mui/icons-material/StarBorder";import Qt from"@mui/icons-material/StarHalf";import jt from"@mui/icons-material/Cancel";import Gt from"@mui/icons-material/ExpandLess";import Ut from"@mui/icons-material/Image";import Xt from"@mui/icons-material/ChevronLeft";import Kt from"@mui/icons-material/ChevronRight";import qt from"@mui/icons-material/FirstPage";import Jt from"@mui/icons-material/LastPage";import Yt from"@mui/icons-material/Explore";import $t from"@mui/icons-material/Radio";import Zt from"@mui/icons-material/LibraryMusic";import _t from"@mui/icons-material/Bookmark";import er from"@mui/icons-material/Edit";import tr from"@mui/icons-material/Share";import"@mui/icons-material/FavoriteBorder";import"@mui/icons-material/DeleteOutline";import{useThemeProps as rr,styled as or,alpha as nr}from"@mui/material/styles";import ir from"@mui/material/Collapse";import ar from"@mui/material/Checkbox";import{createSvgIcon as lr}from"@mui/material/utils";import sr from"@mui/icons-material/CloudUpload";import dr from"@mui/icons-material/Mail";import"@mui/icons-material/Inbox";import cr from"@mui/icons-material/Folder";import"@mui/icons-material/MoreVert";import"@mui/icons-material/ImageOutlined";import ur from"@mui/icons-material/ArrowBack";import pr from"@mui/icons-material/AccountCircle";import hr from"@mui/icons-material/Twitter";import mr from"@mui/icons-material/GitHub";import fr from"@mui/icons-material/LinkedIn";import gr from"@mui/icons-material/Help";import xr from"@mui/icons-material/FolderOpen";import br from"@mui/icons-material/InsertDriveFile";import vr from"@mui/icons-material/PictureAsPdf";import yr from"@mui/icons-material/VideoLibrary";const Sr=e=>`var(--${e}-Font-Family)`,kr="var(--Font-Family-Display, var(--Font-Family-Header, var(--Header-Font-Family)))",Br="var(--Font-Family-Eyebrow, var(--Decorative-Font-Family))",wr=(e,t)=>`var(--${e}-Font-Family, ${t})`,Cr="var(--Font-Variation-Header, normal)",Tr=(e,t)=>`var(--Eyebrow-${e}-${t}, var(--Overline-${e}-${t}))`,Ir=e=>Tr(e,"Font-Size"),Ar=e=>Tr(e,"Font-Weight"),zr=e=>Tr(e,"Line-Height"),Rr=e=>Tr(e,"Letter-Spacing"),Er=e=>`var(--${e}-Font-Size)`,Pr=e=>`var(--${e}-Font-Weight)`,Or=e=>`calc(var(--${e}-Line-Height) * var(--Cognitive-Multiplier, 1))`,Lr=e=>`var(--${e}-Line-Height)`,Mr=e=>`var(--${e}-Letter-Spacing)`,Wr={"display-large":{component:"h1",fontFamily:wr("Display-Large",kr),fontSize:Er("Display-Large"),fontWeight:Pr("Display-Large"),lineHeight:Or("Display-Large"),letterSpacing:Mr("Display-Large"),defaultColor:"header",defaultWidth:"fill"},"display-medium":{component:"h1",fontFamily:wr("Display-Medium",kr),fontSize:Er("Display-Medium"),fontWeight:Pr("Display-Medium"),lineHeight:Or("Display-Medium"),letterSpacing:Mr("Display-Medium"),defaultColor:"header",defaultWidth:"fill"},"display-small":{component:"h2",fontFamily:wr("Display-Small",kr),fontSize:Er("Display-Small"),fontWeight:Pr("Display-Small"),lineHeight:Or("Display-Small"),letterSpacing:Mr("Display-Small"),defaultColor:"header",defaultWidth:"fill"},h1:{component:"h1",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H1"),fontWeight:Pr("H1"),lineHeight:Or("H1"),letterSpacing:Mr("H1"),defaultColor:"header",defaultWidth:"fill"},h2:{component:"h2",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H2"),fontWeight:Pr("H2"),lineHeight:Or("H2"),letterSpacing:Mr("H2"),defaultColor:"header",defaultWidth:"fill"},h3:{component:"h3",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H3"),fontWeight:Pr("H3"),lineHeight:Or("H3"),letterSpacing:Mr("H3"),defaultColor:"header",defaultWidth:"fill"},h4:{component:"h4",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H4"),fontWeight:Pr("H4"),lineHeight:Or("H4"),letterSpacing:Mr("H4"),defaultColor:"standard",defaultWidth:"fill"},h5:{component:"h5",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H5"),fontWeight:Pr("H5"),lineHeight:Or("H5"),letterSpacing:Mr("H5"),defaultColor:"standard",defaultWidth:"fill"},h6:{component:"h6",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H6"),fontWeight:Pr("H6"),lineHeight:Or("H6"),letterSpacing:Mr("H6"),defaultColor:"standard",defaultWidth:"fill"},"subtitle-large":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Subtitle-Large"),fontWeight:Pr("Subtitle-Large"),lineHeight:Or("Subtitle-Large"),letterSpacing:Mr("Subtitle-Large"),defaultColor:"header",defaultWidth:"fill"},subtitle:{component:"p",fontFamily:Sr("Body"),fontSize:Er("Subtitle-Medium"),fontWeight:Pr("Subtitle-Medium"),lineHeight:Or("Subtitle-Medium"),letterSpacing:Mr("Subtitle-Medium"),defaultColor:"header",defaultWidth:"fill"},"subtitle-small":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Subtitle-Small"),fontWeight:Pr("Subtitle-Small"),lineHeight:Or("Subtitle-Small"),letterSpacing:Mr("Subtitle-Small"),defaultColor:"header",defaultWidth:"fill"},"body-small":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Small"),fontWeight:Pr("Body-Small"),lineHeight:Or("Body-Small"),letterSpacing:Mr("Body-Small"),defaultColor:"standard",defaultWidth:"fill"},"body-small-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Small"),fontWeight:Pr("Body-Small-Semibold"),lineHeight:Or("Body-Small"),letterSpacing:Mr("Body-Small"),defaultColor:"standard",defaultWidth:"fill"},body:{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-medium":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium-Semibold"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-medium-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium-Semibold"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-large":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Large"),fontWeight:Pr("Body-Large"),lineHeight:Or("Body-Large"),letterSpacing:Mr("Body-Large"),defaultColor:"standard",defaultWidth:"fill"},"body-large-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Large"),fontWeight:Pr("Body-Large-Semibold"),lineHeight:Or("Body-Large"),letterSpacing:Mr("Body-Large"),defaultColor:"standard",defaultWidth:"fill"},caption:{component:"span",fontFamily:Sr("Body"),fontSize:Er("Caption"),fontWeight:Pr("Caption"),lineHeight:Or("Caption"),letterSpacing:Mr("Caption"),defaultColor:"quiet",defaultWidth:"hug"},"caption-bold":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Caption"),fontWeight:Pr("Caption-Bold"),lineHeight:Or("Caption"),letterSpacing:Mr("Caption"),defaultColor:"quiet",defaultWidth:"hug"},"label-extra-small":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-ExtraSmall"),fontWeight:Pr("Label-ExtraSmall"),lineHeight:Lr("Label-ExtraSmall"),letterSpacing:Mr("Label-ExtraSmall"),defaultColor:"standard",defaultWidth:"hug"},"label-small":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Small"),fontWeight:Pr("Label-Small"),lineHeight:Lr("Label-Small"),letterSpacing:Mr("Label-Small"),defaultColor:"standard",defaultWidth:"hug"},label:{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Medium"),fontWeight:Pr("Label-Medium"),lineHeight:Lr("Label-Medium"),letterSpacing:Mr("Label-Medium"),defaultColor:"standard",defaultWidth:"hug"},"label-medium":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Medium"),fontWeight:Pr("Label-Medium"),lineHeight:Lr("Label-Medium"),letterSpacing:Mr("Label-Medium"),defaultColor:"standard",defaultWidth:"hug"},"label-large":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Large"),fontWeight:Pr("Label-Large"),lineHeight:Lr("Label-Large"),letterSpacing:Mr("Label-Large"),defaultColor:"standard",defaultWidth:"hug"},legal:{component:"span",fontFamily:Sr("Body"),fontSize:Er("Legal"),fontWeight:Pr("Legal"),lineHeight:Or("Legal"),letterSpacing:Mr("Legal"),defaultColor:"quiet",defaultWidth:"hug"},"legal-semibold":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Legal"),fontWeight:Pr("Legal-Semibold"),lineHeight:Or("Legal"),letterSpacing:Mr("Legal"),defaultColor:"quiet",defaultWidth:"hug"},"eyebrow-small":{component:"span",fontFamily:Br,fontSize:Ir("Small"),fontWeight:Ar("Small"),lineHeight:zr("Small"),letterSpacing:Rr("Small"),textTransform:"uppercase",defaultColor:"eyebrow",defaultWidth:"hug"},eyebrow:{component:"span",fontFamily:Br,fontSize:Ir("Medium"),fontWeight:Ar("Medium"),lineHeight:zr("Medium"),letterSpacing:Rr("Medium"),textTransform:"uppercase",defaultColor:"eyebrow",defaultWidth:"hug"},"eyebrow-large":{component:"span",fontFamily:Br,fontSize:Ir("Large"),fontWeight:Ar("Large"),lineHeight:zr("Large"),letterSpacing:Rr("Large"),textTransform:"uppercase",defaultColor:"eyebrow",defaultWidth:"hug"},"number-small":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Number-Small"),fontWeight:Pr("Number-Small"),lineHeight:Lr("Number-Small"),letterSpacing:Mr("Number-Small"),fontVariantNumeric:"tabular-nums",defaultColor:"standard",defaultWidth:"hug"},"number-medium":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Number-Medium"),fontWeight:Pr("Number-Medium"),lineHeight:Lr("Number-Medium"),letterSpacing:Mr("Number-Medium"),fontVariantNumeric:"tabular-nums",defaultColor:"standard",defaultWidth:"hug"},"number-large":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Number-Large"),fontWeight:Pr("Number-Large"),lineHeight:Lr("Number-Large"),letterSpacing:Mr("Number-Large"),fontVariantNumeric:"tabular-nums",defaultColor:"standard",defaultWidth:"hug"},"button-extra-small":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Button-ExtraSmall"),fontWeight:Pr("Button-ExtraSmall"),lineHeight:Lr("Button-ExtraSmall"),letterSpacing:Mr("Button-ExtraSmall"),defaultColor:"standard",defaultWidth:"hug"},"button-small":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Button-Small"),fontWeight:Pr("Button-Small"),lineHeight:Lr("Button-Small"),letterSpacing:Mr("Button-Small"),defaultColor:"standard",defaultWidth:"hug"},button:{component:"span",fontFamily:Sr("Body"),fontSize:"var(--Button-Standard-Font-Size, var(--Button-Font-Size))",fontWeight:"var(--Button-Standard-Font-Weight, var(--Body-Font-Weight))",lineHeight:Lr("Button-Standard"),letterSpacing:Mr("Button-Standard"),defaultColor:"standard",defaultWidth:"hug"},"button-standard":{component:"span",fontFamily:Sr("Body"),fontSize:"var(--Button-Standard-Font-Size, var(--Button-Font-Size))",fontWeight:"var(--Button-Standard-Font-Weight, var(--Body-Font-Weight))",lineHeight:Lr("Button-Standard"),letterSpacing:Mr("Button-Standard"),defaultColor:"standard",defaultWidth:"hug"}},Dr={"overline-small":"eyebrow-small",overline:"eyebrow","overline-medium":"eyebrow","overline-large":"eyebrow-large","eyebrow-medium":"eyebrow","body-small-bold":"body-small-semibold","body-bold":"body-semibold","body-medium-bold":"body-semibold","body-large-bold":"body-large-semibold","subtitle-medium":"subtitle"},Fr={"eyebrow-small":"overline-small",eyebrow:"overline","eyebrow-large":"overline-large"},Nr={header:"var(--Header)",default:"var(--Header)",primary:"var(--Header-Primary)",secondary:"var(--Header-Secondary)",tertiary:"var(--Header-Tertiary)",neutral:"var(--Header-Neutral)",info:"var(--Header-Info)",success:"var(--Header-Success)",warning:"var(--Header-Warning)",error:"var(--Header-Error)"},Hr={standard:"var(--Text)",default:"var(--Text)",quiet:"var(--Quiet)",eyebrow:"var(--Eyebrow, var(--Quiet))",primary:"var(--Text-Primary)",secondary:"var(--Text-Secondary)",tertiary:"var(--Text-Tertiary)",neutral:"var(--Text-Neutral)",info:"var(--Text-Info)",success:"var(--Text-Success)",warning:"var(--Text-Warning)",error:"var(--Text-Error)"},Vr=new Set(["h1","h2","h3","h4","h5","h6","display-large","display-medium","display-small","subtitle-large","subtitle","subtitle-small"]);function Qr({children:e,textStyle:t="body",color:r,width:o,component:n,noWrap:i=!1,gutterBottom:a=!1,className:l="",sx:s={},...d}){const c=Dr[t]||t,u=Wr[c]||Wr.body,p="string"==typeof u.fontSize?u.fontSize.match(/--([\w-]+)-Font-Size/):null,m=p?p[1]:null,f=m?"var(--"+m+"-Text-Decoration, "+(u.textDecoration||"none")+")":u.textDecoration||"none",g=m?"var(--"+m+"-Text-Transform, "+(u.textTransform||"none")+")":u.textTransform||"none",x=function(e,t,r){const o=Vr.has(e);return(o?Nr:Hr)[t||r]||(o?Nr.header:Hr.standard)}(c,r,u.defaultColor),b=o||u.defaultWidth,v="fill"===b,y=n||u.component,S=r||u.defaultColor;return de(h,{component:y,className:"typography typography-"+c+(Fr[c]?" typography-"+Fr[c]:"")+" typography-color-"+S+" typography-width-"+b+" "+l,sx:{fontFamily:u.fontFamily,fontVariationSettings:u.fontVariationSettings||"normal",fontSize:u.fontSize,fontWeight:u.fontWeight,lineHeight:u.lineHeight,letterSpacing:u.letterSpacing,textDecoration:f,textTransform:g,fontVariantNumeric:u.fontVariantNumeric||"normal",color:x,display:v?"block":"inline",width:v?"100%":"auto",margin:0,marginBottom:a?"0.5em":0,padding:0,...i&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},...s},...d,children:e})}const jr={"@supports (text-box-edge: cap alphabetic)":{textBoxTrim:"trim-both",textBoxEdge:"cap alphabetic",paddingTop:0,paddingBottom:0}},Gr=e=>de(Qr,{textStyle:"display-large",...e}),Ur=e=>de(Qr,{textStyle:"display-medium",...e}),Xr=e=>de(Qr,{textStyle:"display-small",...e}),Kr=e=>de(Qr,{textStyle:"h1",...e}),qr=e=>de(Qr,{textStyle:"h2",...e}),Jr=e=>de(Qr,{textStyle:"h3",...e}),Yr=e=>de(Qr,{textStyle:"h4",...e}),$r=e=>de(Qr,{textStyle:"h5",...e}),Zr=e=>de(Qr,{textStyle:"h6",...e}),_r=Yr,eo=e=>de(Qr,{textStyle:"subtitle-large",...e}),to=e=>de(Qr,{textStyle:"subtitle",...e}),ro=e=>de(Qr,{textStyle:"subtitle-small",...e}),oo=e=>de(Qr,{textStyle:"subtitle",...e}),no=eo,io=to,ao=e=>de(Qr,{textStyle:"body-small",...e}),lo=e=>de(Qr,{textStyle:"body-small-semibold",...e}),so=e=>de(Qr,{textStyle:"body-small-bold",...e}),co=e=>de(Qr,{textStyle:"body",...e}),uo=e=>de(Qr,{textStyle:"body-semibold",...e}),po=e=>de(Qr,{textStyle:"body-bold",...e}),ho=co,mo=ao,fo=e=>de(Qr,{textStyle:"body-large",...e}),go=e=>de(Qr,{textStyle:"body-large-semibold",...e}),xo=e=>de(Qr,{textStyle:"body-large-bold",...e}),bo=e=>de(Qr,{textStyle:"caption",...e}),vo=e=>de(Qr,{textStyle:"caption-bold",...e}),yo=e=>de(Qr,{textStyle:"label-extra-small",...e}),So=e=>de(Qr,{textStyle:"label-small",...e}),ko=e=>de(Qr,{textStyle:"label",...e}),Bo=e=>de(Qr,{textStyle:"label-large",...e}),wo=e=>de(Qr,{textStyle:"legal",...e}),Co=e=>de(Qr,{textStyle:"legal-semibold",...e}),To=e=>de(Qr,{textStyle:"eyebrow-small",...e}),Io=e=>de(Qr,{textStyle:"eyebrow",...e}),Ao=e=>de(Qr,{textStyle:"eyebrow",...e}),zo=e=>de(Qr,{textStyle:"eyebrow-large",...e}),Ro=To,Eo=Io,Po=Ao,Oo=zo,Lo=e=>de(Qr,{textStyle:"number-small",...e}),Mo=e=>de(Qr,{textStyle:"number-medium",...e}),Wo=e=>de(Qr,{textStyle:"number-large",...e}),Do=e=>de(Qr,{textStyle:"button-extra-small",...e}),Fo=e=>de(Qr,{textStyle:"button-small",...e}),No=e=>de(Qr,{textStyle:"button",...e}),Ho={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Vo={xs:"12px",small:"16px",medium:"24px",large:"32px"},Qo=Vo;function jo({children:e,color:t="default",size:r="medium",fontSize:o,disabled:n=!1,twoTone:i=!1,className:a="",sx:l={},"aria-label":s,...d}){const c=Ho[t]||"Default";return de(h,{component:"span",className:"icon icon-"+t+" icon-"+r+(n?" icon-disabled":"")+(i?" icon-twotone":"")+(a?" "+a:""),"aria-hidden":s?void 0:"true","aria-label":s||void 0,role:s?"img":void 0,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",fontSize:"custom"===r&&o?"number"==typeof o?o+"px":o:Qo[r]||Qo.medium,color:"default"===t?"inherit":"var(--Icons-"+c+")",opacity:n?.38:1,cursor:n?"not-allowed":"inherit",lineHeight:1,flexShrink:0,...i&&{"--twotone-variant":"var(--Icons-Variant-"+c+")"},"& .MuiSvgIcon-root":{fontSize:"inherit",color:"inherit"},...l},...d,children:e})}const Go="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAkACQAAD/4QCSRXhpZgAATU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUAAAABAAAARgEoAAMAAAABAAIAAIdpAAQAAAABAAAATgAAAAAAAACQAAAAAQAAAJAAAAABAAOShgAHAAAAEgAAAHigAgAEAAAAAQAAAKCgAwAEAAAAAQAAAKAAAAAAQVNDSUkAAABTY3JlZW5zaG90/+0AOFBob3Rvc2hvcCAzLjAAOEJJTQQEAAAAAAAAOEJJTQQlAAAAAAAQ1B2M2Y8AsgTpgAmY7PhCfv/iAihJQ0NfUFJPRklMRQABAQAAAhhhcHBsBAAAAG1udHJSR0IgWFlaIAfmAAEAAQAAAAAAAGFjc3BBUFBMAAAAAEFQUEwAAAAAAAAAAAAAAAAAAAAAAAD21gABAAAAANMtYXBwbAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACmRlc2MAAAD8AAAAMGNwcnQAAAEsAAAAUHd0cHQAAAF8AAAAFHJYWVoAAAGQAAAAFGdYWVoAAAGkAAAAFGJYWVoAAAG4AAAAFHJUUkMAAAHMAAAAIGNoYWQAAAHsAAAALGJUUkMAAAHMAAAAIGdUUkMAAAHMAAAAIG1sdWMAAAAAAAAAAQAAAAxlblVTAAAAFAAAABwARABpAHMAcABsAGEAeQAgAFAAM21sdWMAAAAAAAAAAQAAAAxlblVTAAAANAAAABwAQwBvAHAAeQByAGkAZwBoAHQAIABBAHAAcABsAGUAIABJAG4AYwAuACwAIAAyADAAMgAyWFlaIAAAAAAAAPbVAAEAAAAA0yxYWVogAAAAAAAAg98AAD2/////u1hZWiAAAAAAAABKvwAAsTcAAAq5WFlaIAAAAAAAACg4AAARCwAAyLlwYXJhAAAAAAADAAAAAmZmAADypwAADVkAABPQAAAKW3NmMzIAAAAAAAEMQgAABd7///MmAAAHkwAA/ZD///ui///9owAAA9wAAMBu/8AAEQgAoACgAwEiAAIRAQMRAf/EAB8AAAEFAQEBAQEBAAAAAAAAAAABAgMEBQYHCAkKC//EALUQAAIBAwMCBAMFBQQEAAABfQECAwAEEQUSITFBBhNRYQcicRQygZGhCCNCscEVUtHwJDNicoIJChYXGBkaJSYnKCkqNDU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6g4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2drh4uPk5ebn6Onq8fLz9PX29/j5+v/EAB8BAAMBAQEBAQEBAQEAAAAAAAABAgMEBQYHCAkKC//EALURAAIBAgQEAwQHBQQEAAECdwABAgMRBAUhMQYSQVEHYXETIjKBCBRCkaGxwQkjM1LwFWJy0QoWJDThJfEXGBkaJicoKSo1Njc4OTpDREVGR0hJSlNUVVZXWFlaY2RlZmdoaWpzdHV2d3h5eoKDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uLj5OXm5+jp6vLz9PX29/j5+v/bAEMAAgICAgICAwICAwQDAwMEBQQEBAQFBgUFBQUFBggGBgYGBgYICAgICAgICAkJCQkJCQsLCwsLDAwMDAwMDAwMDP/bAEMBAgICAwMDBQMDBQwIBwgMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDP/dAAQACv/aAAwDAQACEQMRAD8A8zt1v/D0/m2bbo85K9q664XRPGNl5N0iicc7W9R3FeO2vjF5FAmPB9eldRYvFfqJrWYJIOeDivntTvnRvqeleHfEupeA3EciBoYz8rgcjHr/AI/nXpdt+0p4sd1s7RozEw+V88/lXjlldedEbLVsOCMb+9XPCmk6f4S1yPWvs631uj+Z5bcjI54zU3a1izmlTVmpI+kbLxp8SdcjWVkuzHJ0ZIXCn6MRiultfD3i/UcPdgx57zSgfoMmufb9oZ9WgGl6dAqsw27OWZMf7IFT2XiDxJfKWbcPYkLn6dTXZSrJ/E2zza9Fp+6kj1bRPhjZXKeZr2sLCv8AcgAz/wB9Of6VrX/hL4M6NC39pOb9scieZnBx/sx7R+lebaXYatqlwEupRbx/xMSXP4ZIFehR+C/BUKBtRup7p2/g8zaCT22xgH9a7ou6uor5nJ5XPzw+LkHgGy+INld+AbH7MfPUXMSBlikywwVDd+xxX1HDe3Z8Norx2yIEzsz85z36Yr1SP4cfC6fVTqV1o0U7w4wsrLshDHZmUMeCfU89MDvU+peGPCWsWlxb+H4bG3iRWZhBOu2LaM7pmOQFC5/iABJr57MI1ZS5qTW/Q+lwFCPskqi6dT8o5LC78RfEqG32kRR3h83A6KG5Az7V+pfhHwl8MptKhgvIGhlVAN6yOjdO+Dj9K8W8KfDHTbXUrnWrh4BDCXnnkYjy1UOFwjcjAzksT9AOa9vtbLSJYhJHIsaFFZZEYeWQRwQR8pHoe9d2Fq3Wxw46hK99TtU+Evgu7XOm6tcRE9AWSQfqAf1rOufghqGC+maxBJ6eZGyH81J/lWF9ju4Rvs5xKuNwPXP5Uh1vX9PHyPIO3yOcV1upC2sTg9mZWqfDv4oaKrSWcomVeht7n/2V8Vwdj41+IXhzW44fEMV+0LkRwxNHnfIT03DjHvXp6+OvEtveRRyxzyLJwocDaD6sewFT+NfEVjDp/wBvuJ0a4WPk8dT2UfpXn1nztqDOyjTUFcf4h8TTHS/tWpzLG+zJTPyx8dPc+9fGHjTxve6o8lnp8jLbkkE92/wFWPFnja/1tjBJJ5cA/hHf3NeVahrVhZRNucZqU7LlR1KnzS5mMimitW3yH5qyNb8XW9vHtMn4Dk1w2qeKbaRyfOWJM9erH6CtXw5oN34iuo5Rp8ws2/5bSDG4+oBo6HZGkf/QwfiB+y3N4f8AEotfDV5P/Z8oJ8qRt+wjnhuuK8A1zS9b8AagYLhZvJzgSlG2ZHbdiv0u1v4m6Xd66BfW0tqckbZlIPT3roptF8MeLdKMN1bwvFOhIDBf0zXz9RLmbiz2I6o/MDT/ABdJcSJHc7lJ6HoDXsGhXk6qG3iSNux6V698RfgRZ3enqnhqNIZwBtYLnmvDh8OPiV4YuI4TD9pcuFAUAJ1xli3AHqTwO9Q3Zakzpp6I9M0ZLaC5+2aZARck44GdxPavYvDGqanqF2LGKDFwcfIFbHPfgGuG8AeDr7UZvMvNV0/yIZsTeTMZFjOSrI7KByCOzZz2HWvZF1/TtE8XQeFtE0+BnhgWSTU72VkTEoYL5UUfLuSrAAsT3GetEZq6S3OV4KUrtrQ9H0iPRZXuNPl1GKa7sYhPexwuZBARx5biLJDMx4GCeD71Q8MePvhh4i1K+tPDF6up3mmukUscKldsj7s4MhwdmDuP8ODmvz5+Ofjl/BvhrWdQ8KreafDreurCL1hMvmi2iLsVWQEBEclgqFgN3JB68d+zxJ8RNM8EeLvjHoTxARLKWminiVrydMzXBMZJEQXhdyozN0A446FJyjdM3hhIRkotH1j8fPF9kllq3g7whdBNUa3F5LOitJMktuXMUaPFl8bo2BJCjkEZya+dvhD8d7Pw14WiPjOS5thcM9qr2saTC4s5A8hZo2ILKkxkTgNgHuOvwp45+K/izxlq11rJ1W4im1SFxcMj7HXLncCqYxu2gEdx164Ot4s+IWh6p4I0e006eddSit4Ld5HVVmR7bAXBA5AYZUZzySevESwknbm6s3+tU4+7Doj7yv8A44aP4Ztv7XmS81WHTIv7LgW7uWSJDcPHIjFY2wzrGd0e8FMYBAJOOf8AEX7SenLYqLIRyWlhukkmIKzF5CGffGrbMYxhVJ6N2Ffnd4l8U3upaZJfapYPOLpk2XbthlKJ8v3RtAOe/PHUViXOvW1xp9o81x/pLoBNHsAiZFwFwoYkt0y20Z549dYYO0VF9zKpilJvTofo5pP7Sniy3TzNA2/2fIrNG/zMmBncNjA4Kngj8q9Z8B/tXQ3Rlg8Y+XmLHliFfLZnOQMh+AAQMkkAA5r8tfDfj3xB4dtTYaPIt7aEeY8arux3JAwD7EH0zmvR9a16x8XaLBFusE1WdoRO4QQzIgBzGuGAfsWcjIOBiieGlF6PQwUqc1qtT9d5fihpniLRRf6Msm6ZcASrg7lyCVI4Zc9COCOa8W1vVNQuyZdSdio6KTwK8K8EeKINAuNGsdNuXu7JbZ7a6gZyNlyER1YK3IO3J+XII7nFe66T4d1LxrK0sgMVucgHPII6+2PT2riUteXqU8PZ3Wx4zruvNJO1raQMcdTXKaVoOseKpLj7NalYoDh3kJJJPYV7zf8AgCPwnqMk05MkbDJZ+e3vXQ+Ar/Slgu7S3iJllkO3auR0PU1UV71mdEYKKufPPhz4bWk3iyyS+TcqkkoeQDmvvPUtA03SPD0DWsCJsTOAAD2r540T4d/EHW/HTGxT7PEWLJJt3fKT1xx/OvsvTPg/r0NvFca7eyXRC4KsQF/BRx+ta0acnfqTVrw0sf/R/Q3XfAeh61q8t1cWqM4zhiorirj4YvcPs02RoCgIRlzxXQzfEq1GoPGtvJyxHT+dddp3i7SoY1kkY72GTx09q82UISmzqi/d0PLn8J6/oNuqiRrx+24Z5/SvGfHeg+NZZXutZkkXS4Ip5VihkKyzufLJWQZXKqA+1RuP8q+yZfEVjdRl4sbirbN4IBIHH4V+dPxC+PE3/CRnwL8SC0D6deGOa7jgQQRGdd9uQN6yOAPuvsKk8MRXFjIx5LRuztwnNz7nKeLrzwjb2unQ6dqUumhJDqT6XZ3geSRIPmbzkuH2gyou3mPIHJU8g+M6P+0/4U0vxLcy6/oLMiGZkmQlbn7QS+RNvUhdhIjXyyAMkqQDXjVtHZa54k13xD4bsbmSSyYA3V1dC4uGmuDlmSzUIArqGUBWzlslj2+U9aW91XX7l55tl0JHEyMNpVBgAfgAAR1GMHnNTRwcG3FvU3qYycEpJHXeJ/iNqHijxTd3N8815pMt27w2k1w5jXzeApDPkjKjPPRRwM10ui/ErVNH8LyaPYzR2q299PcC1jbaGSVVyRnO3HIG3AINeD30yTXEv2oKs8TLtZMDKYIzxxnoSeppYLy08pVXAnAIQlSGZ2IyWY54AHAFet7OPLyW0PL9rPn529SzqkhglW6kO6Vi5bnlQcbVPJxgHIqCJ7htKMyyDBmO1CcnJ7gHgdvrVS6a4mm8hgGZgMkYJLeue+K7mfwwdO0uy1OaRJobmMMsUfytvZcnPGDt785HFVKrGKSfUzhRnNtxWxzlzr+oDTY9HS9lNqHVli3YCyAfewee5x+NczNEVl8xxtU9McfMOuB+NdTqWmtbi4tROsqQlcMY9hLNzt3dcj361z8jGaw3kFmQg5649eauEotXXUiaknyy6Fq01CS3xHbM2+UOH2k5KsMEfjXX6Fd3NhItxbgrcJkiUrvYLjJ2qxIyM4rzeKeaNy8R2kgKSOOK6jT2t5I+J/Ll+VlUA8PkYG4jGT+X0onEIaM+i/D3j6/XTLg5+ZrmO5WSUok0bx42vgEDAwM4zxnpzj78+D+s+N/HWmWl14VIsNNtIJklZCZpJriTJ+ZSCBswOBk7elfl3Zx2flpOsuJQC8kbIfmXBGM5/pivsn9nL4v3Xw+s5rW7kZ7e9bzPJ2hRvjG3b84G3C5JYHBXpzXlYmlFe8ejSqSasj9ErjwPqVzOq65+9Vo0DMeAWwM/L2r0DwJ8NdD0uOa6SBNzv1I7e1cL4b+JD+LdCW+UwTbxmOa1LNEY/wCEksASfU9Dxjiu+8N6l4imjkgEJCITlj0Yn0q6MYXuctST2Z6d4YXS7DVtoCq2MD869a1q+tU0/cGXha+SrHw9451HxGWs5Fjjbnc2fl59O9exXHg7xULZft995mRjaBgV1UpPlasZyldn/9L9DbTRdPkeSR4lDFj2rf0Dw/p5kZ3jBGT1ryOTxNrc8/8AoMGFzyT2Feg6LrOs3VssUMezAIY45zjk157cednRFpxR0t/o1iLrjai898fLjoPevy9/a3+IujW+vTWNvpdtNd6NLHGPNs4Z5PKZM5888xttKsi7WwRz6V9k+OvGGoaMIb6YyzJE2x54ULrEHwhfAHQElQTxuPoCR+JXx18earca441LdI96Z7p7iRm8y6EhCRNMdzbmRI1U5OQR6dfOlL21TkjpY9KnFUo88jz++8YavFJqFzpTrY2FzgSxWsmzeY+InfnJYMMjgHNeIXl/LLeS3gXMjPl5GYkvnk5/HrWjot6bnV3M5zHsfCnkHPt9RmsfVpBBeSxRgbW7V6tOmo6HDVqOauU5ZvtNz5qIF3YyoHHFem+DvAN9411Yi1hZI2YhSQSobHTgdMkYxXmkUS3V/aWsB5kZIzj1Y81+pXwn8EeLItJtx4I03TxHbJ+8vdTYhHl4+WJFILBe5PGeleXnGNnQhGnS+KXV9EetkeAp15yqVvhj0W7OD8B/seXmqXEF94lVBb4CTRRbl3YxhlOAeec8fSvojxf+zNoeu6Na6bZQrbS6euIcLgEYwN2wqeOo/kc16b4e8W/GjQtRisfEOlaHqVgdqvJprtFIgx94BmbcfbA+tfQKyfbbKC/EXkl1JdD1UgZIzXyOIxFeU1OVW7XbZH2mGw2GUHCNKye91qz8yvEv7JM7WNvMwBS0Dm4lLHc67SVAGCWO4ADOMAnrXxv4y+Gl54MWO6XesBn2TAjIVTkAkZHGcfSv1v8AiH4m+KV9ObPwzJpuiaah2yXF6qyyOc9QGyoXHtnPevnPXfhJ4w8SRXWfGel6lPcK6m0MMaDBHJUopw3oTxmurBZjWpSi3WTj1Tv/AJHDj8toVozUaLT6NW/zPy+v7KOK5KQ8q3I9OvOK0rW3jEqzXEyCFCCEQ5Yn/PU103xQ8JzeDNch06RHhLJ8yyfeDA85wSCPQivO5G3Dev314/CvuKNaNaCqQejPz+vQlRqOnPdHcx6qq3wufJbyy7CJRzgtnhfck/SvU/DNxp2oajYW2q3Vwbj7THCq7gCF2lSitwByRnLAHkcV45eRWcmjW0qExyptYgZKyZwMZ9R1H5V654E1CBNYs9K1WGJdO1VVtbmPJkVPMO1ZgGy0bq2GJHbpWdZJxNaUmnqfqZ8ENZ17V/Ar2tutlLBpg+xMsEbJcrJEo8l3y5BRkGBtGPlr68+F1zef2RG+p4ErDO0nkZr8yfCeq3vwr0DzrxdU0rUbK6iglWS1cWN2pnKxRvcqCjeYu9UPUHoOtfpL4Wae8it7iWB7M3caskZbLIxXOxxgbWHcc1y0GlLUVdNarY998O6hZR6kVJXcQK9J1OeFrcEEcjNfN2jeFNXu9Y8+K5ZFxz9favRtV03XbC2yLozbR90jFd8JPl2MG9T/0/0LtNNWwh/fqvua6XSoorGwa8kKkHLBCcZFed3Wq6prw8mAeVGeDtH9a6fw/p1zJD5V3LnZ8oyewrgk7z0OiL0Pj34meJm0/wAVa1o99dCWbULYtZWnmGJAturTKDjHLpuADHnaSvSvyG+LemWtzb3t8bc29zPdNcRvseOKZJixY7JDhWBwAF4wM85Jr9zfH/wD8B614ztfHWtRE3dtt3ESMqP5Cv5fnKpAdEDNnPQZxxxX4rftR6jpHiTx5J/wht3JNpaSfZIhIrogKudzRhudm4nDNztGTXmYfDuFa99z1J11Oi48uyPnPSrTT4ra3YtItxI75P8ACwCHAAwD1Gc59iOa5zVopjqOH4LEAFuBnjua7bxVZNoVxHp9pew3z2DG2ae3O+GR4mwzxt3UnODxkc9CK47WLv7ZiaTaspP3UG0AdOnTrXsxbep5k0krGj4Nt/P8aaRFKOHu0GMDHX8q/Wu98GeNfESaRa6dqA0rQbZN06wny5ZTtx8rlXReefmRs+3Wvyj+HsAl8beH/LdTK95ENmTnJOMnsP51/Rj8PtBs20O386NXXy16+hFfJcQJvGUrdE99Vv2PsuGUvqlXm79NHt3Pz9+HPw5+KWmeKftup6098kNwv+rEpiNsAQ6Odg3OeNuCFUjpzx98adNqd54enjZCskY+Xd97kHA/Suu1G40nTX+yW6orMMYUDJ/xo0W3kurC7kKlUchACMEdQTXkVf3lXdX1vZWPoaMFTpW1tpa7bf4nwz8RPCviDxrb/ZopLmBbVpWY25YSFnTETqykEeWecY+bp615f4a+CHi23sre8k8Q3L6ta3huTc7bgFoyADCY5maMDqSwyxPGcV9sC5Tw5qU41RCsQPlmRgApOeOenI5Fei6fa6Pf27T2aIGZeWGOa4sPiKkaToKS+5HTicLTlVVdxbfq7fdc/E/9rXSLiz1LSL29O6ZjJC8g/i2jIP19a+QQWjYNjgg/Lmv0V/b3tI7ZtFCBQRcycA5GNpx/Svzul3SToQv+sVcKenNfc8PN/UYJ9Lr8WfnXEkUsfO3W35HbaS9rPo8sNw2FOSpZgAhzlRt69e4p1hcxRXSTwyMNx4DA/Lt6+uRXORYitpreRmEn3QM/KwBz0retbQXVlBPAXEtuWzwCu3r6j/8AVmvWaR5EW3Y+8PCnijWPH3wiuNJtlN1baJqVm95cSSsXt48s4LR7TiMYYB84DkE4FfqF8L/EV34i0q11/V7GSzmDOiRs25GRflSZcAZVhyrEZwa/Mn9hjxTeaX44n0drC1kstUj8i8uXbbMmFbywqkgMmR8/Bxkc84r9jPDtjpMFkbWyiihijyqRxKERR6Ko4A+lclOPvtGldvY67wp4isF1Aws65xXa6zeRzshjYbSOea8Ts/C8bag90jlcHscZ5roru21WxgM4cuiDgHriuqMnynM276n/1P05fw3eabpRv5IREoXds4BA+naquneIPD1vpJLMryuCztnkHsPbFc9498W+Pp/DUktroz28Ey4LyMA6of4tg/rWt8MtG0VPAtut8iST3iu8zOAWJLEdfYdK4HK87R7HXGOiPmz4rWfi74jeFb3Q/DOsNod1JIDFdEZRoslXhkGDlJFOGxX5hfFr9mHWfhZLp+p39/Nq+iwqZL0wRkSvIsW9hAzmRUVmzgMM4HTPNfq5r2v6To8lzHd4jihkbaCcZCnivkj9pHSvFXxKOkaL4V1JbffbzSCBLhViYeW0nmGWMOSxUbBGQevOOTXn1ZWXM5WOug/e5Ern443iWl9qBS0LRWylm8uRs4QcYyByegzgc1zWpoUcKRtAyPY46EGvWvih4Zg8DRado6zTnUpYxd6isiBGjknUMkWfvcJjOcZJJxzXlF2oa1hk37mOeCecegGM/nXp0ZqSUlsclZWbT3GaJqsuh61Ya1B9+xuYbhffynDY/HGK/oi8LfEO2h8F2uqWzb4ZbZJoSOjI67lOfoa/nKIPfvX6i/sifFex8U+CT8M9cmUanoan7KHPM9iTxjPUxE7SP7u014PE+GnOlHEU943T9H/k/wAz6ThXFwhWlQqbS1Xqv+B+R90+EtV1DWbh/Ed/CSWIaFDzsQ/Mu4ZwCeCRWZrfxU8SaTdTxXzh1ckxpBHtRAPu8gnJ9c/pXI2fgrS08Q6f4iup7qW2tmMN1YrdTR2lzE3AMkaMBvXPyuMEcZyOK9dTT/gBFEP7Q8Paktx50eUieWcYX5nIYS/dOec4PHFfLYbB89FONS3e/wDwx91LENT5nSlL/Ck/1v8AgePx+ONS1mznh1q9hlhmO9UuvKiZRznLZ5HpnmuO8NfEDW9K12PStNuU1HS597RyRkSeXtO3yy4OGXnIZfTGa9O8eWXw18Q+Hr/wx4X8Mw2lpqaSW8tzdYku5I3LZWL5mMe5W25zkD0xmuE1K18P+CtOW7kENhp+lWhBOAkcUMa849gBXJjMMqdnGXNI3VSSV5x5F2dr/NbL77+h8N/tseIbrWtb8PWUyhJZUmuCnopYRr/I18XSRus0eBsKIjADqSRkfp1ruvit8Qbv4neP7zxNGpjtgRb2ERH+rtos7Mj1bJZvc1wSSKQ2QAy4IY+nXGK/SMsw0sPhadKe+79W7n5Lm+KjiMXUqx26eiVi0sr3Mwyg3RbmZgOcgd+36V7j8MtI8NeKZ7vTvFkxt5JLQm2mgBEjTj/VJhSAQxOCANxPTpXielRpLI8pJyPvLycqRyT7Z4/GvX/DOnWuq3linhmSaXVrYxMlvHG6tJeNKuI0HXbGoJaRsDnr0z0V37rRx0d7n1z+zf8ADr4geGfG0euTQPbQC8NtLDcRiSWKzKmXewJz8+1cMPuk5OeRX6l+G/EkSM9sPm2knNec/DjTrz4hxaLrDWqWEraFHFdGSZGmSaCU/u1jU/KpLEhm6kAZ5ruLb4e+L9DmuLyW0+02Zdm8xOGC+6+1cNKc2+YVVxb16HpWheJIbu/+zq2cHkV6vfywSWYUY5FfCl/4huvDWsm5hyV3ZI/GvY9F+KUOqw+VIcFFGc11wrx+FmfLJavY/9X9afiJq+nWPh27jbaSYWVQfUivheL4xWnhOx+y3c+1hkAZ6Z9KpfFD4u/6PJH55nkYcKDxXxlewah4pvmubtyATwOwrza9RJprc6YSctFsek+M/G8Xi+7kWFyImY8g9a1vBlwbeS3S5mkn+zktalySIHYBHZQeAWXgk9v15rQfB8KbQx4r2jRPD1lCF6ZGK4pU/aO7LVT2atFn5v8Ax7+FOo3/AMYdcnt7Wa7sI7Q6zdT3JEcRSIKLkxS5wyCVgvHzgHgHivlDxjZWMOraja6YIDaxTtJCIHZkjjb59gZxuO37ue+K/bL4veAl1/QpLTRdFW+OpSxrdSSSF3jKMWWSSJE3Tx7ifMQYbBBByAR8RXX7DfxBn1u3ksrm3bSpLgGRLjKzeU0mSPlU4bbjIdsjpu9OmhNr4h1KkWtD885EYwxRtxgEjPX5uRWj4X1jVvDfiTTda0Sd7W+tbhHikQ4I5wVI7qwyCDwQcGvs34v/ALLXi7wZoM/ia+RYYBqMFlBa2yCbebhtvmKV5VBtA+fozKuTya+ufhj+x/8AB/4W+FYPFfxTuFvPF8+mvPDp19PGojuHRiqxWo+ZnXIBJLAEGt5VlyO66MyjpOPI9bqx638O9ZtvFujRNc7Y7low0sR4BBHJUHt/k1T1z4aTPcmWHWJLeNjkRg5x9MnNcb4fsTpsaLbyFTGF27TgjHpV3XLnxC4LQ3bOuM5PUe1fltaskmtmfs2FnOm7xbOs0DwlYaMjXlxePcSjd88zD5dvoOgHevi/9qvxbc674YvdH0xythEu5mU489kcEn/cHb1PNezXF3rV2sltcXDurnDKMgHHX/JrzLx54Vs9X0uW2uukg25B6A8VWAxcYV4SlrZpmOZ0Z1qNTXVpo/L+3cI+WU9OoOKt+V5is8YOwYGeTyegzivpPwh8H/DSeNrnw74lvmt5jFv06S5hH2BpHbEf2qRXDBc8HC45yTivorw7+xh408SeOdOt9W8mHwfFIWu59P8ALgDbf3hECb5TIjMTGkjMTjkYGBX6jHERqRVSOz2fc/H61P2U3TqaNbo+H/Cuh65qMsj6Fbbj5MkU2SMtlGZgEOM/KMjg4xmvo74I/Bjxlr/hu/8AiV4Pkn0z+xbm3S4luIWZXilbEk9tMuQPLIIlVlZVX5icZx7N8KfBQ8e/tNatJp+kweFk8Nx3cjW8lu4WdI5fssDNEWAbd95mBXPUA9a/S/4f+F9K+Hdjf2dhHCBqs5ubtIIhFbvIVCHbDkqoKjBHfvWVSTlpbQlzUUrPU7v4P+F9Y0Twdp6axa2lrcKmAtoWZTAp/dBmcZY4ycjjnj1r6Ut9RtZbD7JgAsuCK8f0iS91S3WC0YQxooVVHACgYAUdgOwrTTw9q0b+Z9qYH0zU0/cXuoi99T51+J/wZ1+61KW+8NzNOJXZzbso+XJz8pHb61x2neF9W0lTHqtlJaS9ywIViPQ19y+H4Xs5M30hkPqx6VV+JSWF9oE8FtEstwyZjC4zuHSh0k1zItVJKPK3of/W4WGzm1NhJcyFifU12eleHUyuys3S7cnHBr0bSYnBXC14drnZJ2WhraZ4f2gZrvNP0kIAB2qtp8cgUZWvX/BfgrU/Ege5V47WzhO155emeuFUcsf85reFNyfLFHLOaW5zlrYEDg12+ieEfEGtOF02zkdSeZGG2MfV2wK9csNM8FeFIBO8QvJY8brm4AZQfZPuqPzrRHxR0l38hZ44lXgFvkXA9Pwr06WWVGrtHDPGUouzkcNrHhTwr4M8NX2v+N1j1YWUJufsoUNBlOmd3Lc+wH1r8ktMuJvGHxa8X+M9emNxe6jcRrZmQ5EFkY12QxDoqBlccd6/Qv8AaR8Yyx+Cb660i50+8S7hNuY42drhVYjcRn5eOOMV+YtpcXFrcw6lpZzeW4IMLjaZIyQWRh+AII6EA+orqx+QTxGW1IYfSe687dPn+Zllmf08LmdOddXgtH5X6/L8rn0lDEsEW2UfIpBXHHI6VV1G4gcPGZChIPBHIwKz7Xxt4av4oluLpIJ3Cjy5MoQxGeM8cdDg4Bpt1bwXypMkiyRsMqyMDkE+1fhePo1adR06kWn2aP33A1qVWmqlOSa7pmOIowpMS7tx+83b8KxtVsoEt5JrogRLlnJ4AAGa6TV9U8O6CIop7je5PMcYLt07hen44rx7xd4nXVJBHGGtrFMbYmOWduu9wucew5A9fT18g4Yx+YVVyQah1k1ovTu/JfhueFxDxXgcupNTmpT6RT1fr2XmzyPxNMJ7t7oJh7hlSJT1WIEgZ9zkn8favdv2ffjTqvwwfWbbVY21fQIrqMvaMxDRK/ytJC3Yg4JHQivDmgl1DUxMykKhG0ew79a6nwxZFTq8GwSJPC52n+LackE/T0r99wmUUaOHjhoL3Yq39efU/nrHZzWr154mcvek7/8AA/Q/QNfH/wAF/DXimHUNPgTSYPGCi9XU0JlgmuHwskdw+A0cgI6MCuDkGvb7nTl2q275XUOjD7rKRkMp7g9iK/LbTLH7VoM+gXh8y0fDwZ6wuOm3PftX1t+z/wDFy8i0VPhr4uZZ5tNJ/s+Wck+ZDknySTyMfwkHjpXJjOG0481DR9jTB8QtS5MQrrufUOjatcaNIFSTKk969KTWPtVv5r3Ww46DFeURW9p4kSSfQsJLHnfbOfmyDzsJJz9K5i4ku4i0LSum0kFTkEEdjXymJw1XDzcKisfU4bFU60Oem7o9M1bxBHakt9sbj3rmbL4i6TaXbfbp9/HAZ64l9BfUx80rt9Oa569+HNhM2Z2m/WuKTad0dJ//187TYpMjBr0PTFlUDFZ9lDaKBgV1tqsGBt614kYnROXQ7Hw1p9xql/DZmTy1c5kc9EReWb8BXdeMvixFpEC6R4dUR2NvCyK2cEleCSPUnqa4eyujp+g6rfxnDLEsQPoHOW/QV4Ncap9qtry3lf5iLjac90VZFH4gGvt+HMDB03Xmr3Pjc/x1RT9hTdjt4Pibrd5dOsVyzgjlSxII7jGe9RX+vXN9cB3k8tgPurwufXj2rwjwXqMlzO8q4LBsEentXrYiOFYKAfavrHSitUj5ZVG9zE8X3L3kMVtK7Og7Z4x9K8tl0SEEugwSeK9N135ihYZOD26VzLqGUENnOefpSS0NE7nK3fh+HUolgnRJDkAMQC/oRnr6Vw2vaNrelTTzz6gWt72SC0srZSf3ZyC7AEcHYrcivZ7GNPtiBuhPHfJzXK/E2EnUfDTpkILqfd9fJO3+uK4q+CoTalOCbv8A8A7KWNr0ouMJtKxjDScxq79cDBBP9c1nXWhJKcu2fXj8K6+MnIwu7jGeuMU+SINwO3YV1W6HFdvU4e08PW0cudpIxnNbMFpFZTM8a4J57elavlBA29SfQ8VWniBjLKCPx6UEPzHNpv7v7TYMSMAsnUjvxUSu6yR3qny7iE7lYcEEVWF3LZSbuSQB064BplzqEE5MqnacYI6VtGSMZQ7H0b4A+I9zZ7JJpWWUSH5snHQcD+de+/8ACbeHvEMSxapGIZ26XUOBID6kdGH1r84xq5tFljQkHBkB64K49PUVt6Z4/u4tqSSMdpHP0HX+VcOLw1GuuWornbhK9ak+anKx+jmjO+jzpMZVu7KQgLPH0Gezr1U/ofWvXo9MsNRgFxGAcjtX58eCvilNZzKrSbo3O1kblWHoe1fWXhjxxa29vHdxvm0kwME52MRnafb0NfEZrkzw37ynrH8j7LK82Vf93UVpfmf/0PQbTS4yOR+ZrorawjXGP51x8GoS4Azx9K3rW/c8Bv0rx00as3PEzC28HXdpEcSXSzYx1zHGCP1NfJcWsm8tkuY2OX+YrxnJQxsPXv2r6D8carLZ6dpMhPyyz3EWTxklAVz+K4r4vn1ZdA8Q3WnSFhBKxurUHPMZb94nHUqeor9LyNKOCh5/5s/O87beMnb+tEexfCaCE+C11fAZ7i7mVjjJ+RsBa9WWTdGA3yrzxjvXzp8ONek0PQdSsZWL20WrEW6j/aUyEj8CteswaxdahH5gVkGM8ivYjO8UmeR7Np6GlrBV281Tnadtc66gDCnoRW7h5ItkhyQAx4HWsiXH3CBgZ9fz9qnyLRn7XE6snU88DJ/AetcJ4ofXUh0ka1LG0k+otJaRohDxxJHIH3Z6nBXJx34zXq9hbrJcHOPlGQMevH9a818WSjUfiRBaf8s9IsAOenm3J3t+O1VrGrC8otN6fj6m0aloSi0tfw9DSgSQoM85A9c0oABOSR7danKgAHdwDjgY9BTWCopcgDuM8dK1Mio7rsx8x64qhLKNjE9yCen4VYMhkYrhhz15we9UZVyCucEn2PH9KlkmNdzoFO5eexPUj/8AVXKXlx1MRGe3OK6W7kRWI547dMnvjiuP1FfMLDA74HANZTdkVCN2YT6rP9o8pmyNrDkdcj8KiW7MROGPJ6isqcPBdKX4XnPqOD9aha5Vmyh24BAB/WvPnNt6npQgktDvdN16a2dVD4H97+or6r+FvjqJm/s29cPb3ACMHPHsR/SvhVZ2RgSc4OcV2uh6hcMcW8vluOR2yaOdTTpzV0w5XBqcWf/Z",Uo={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral"},Xo={"xxx-small":{size:16,iconSize:10},"xx-small":{size:24,iconSize:14},"x-small":{size:32,iconSize:18},small:{size:40,iconSize:22},medium:{size:56,iconSize:28},large:{size:64,iconSize:32},"x-large":{size:80,iconSize:40},"xx-large":{size:160,iconSize:80}};const Ko={"xxx-small":"7px","xx-small":"var(--Legal-Font-Size)","x-small":"var(--Number-Small-Font-Size)",small:"var(--Number-Small-Font-Size)",medium:"var(--Number-Medium-Font-Size)",large:"var(--Number-Medium-Font-Size)","x-large":"var(--Number-Large-Font-Size)","xx-large":"var(--Number-Large-Font-Size)"};function qo({src:e,defaultPhoto:t=!0,alt:o,initials:n,icon:i,color:a="default",size:l="x-small",customSize:s,clickable:d=!1,onClick:c,insideButton:u=!1,className:p="",sx:m={},...f}){const[g,x]=r(!1),b="custom"===l&&s?{size:s}:Xo[l]||Xo.medium,v=Uo[a]||Uo.default,y=e||(!t||n||i?void 0:Go),S=y&&!g,k=!S&&n,B=!S&&!k,w=d||!!c,C=S?"transparent":"var(--Buttons-"+v+"-Button)",T="var(--Buttons-"+v+"-Border)",I="var(--Buttons-"+v+"-Text)";return ce(h,{component:w?"button":"div",type:w?"button":void 0,role:w?"button":"img","aria-label":o||n||"Avatar",tabIndex:w?0:void 0,onClick:w?c:void 0,className:"avatar avatar-"+l+" avatar-"+a+(w?" avatar-clickable":"")+(S?" avatar-image":k?" avatar-initials":" avatar-fallback")+(p?" "+p:""),sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:b.size+"px",height:b.size+"px",borderRadius:"50%",backgroundColor:C,color:I,fontFamily:"inherit",fontWeight:600,overflow:"hidden",flexShrink:0,border:S?"none":"2px solid "+T,...u&&{marginLeft:"2px",marginRight:"2px"},...w&&{cursor:"pointer",outline:"none",padding:0,transition:"background-color 0.15s ease, border-color 0.15s ease","&:hover":{backgroundColor:S?"rgba(0,0,0,0.08)":"var(--Buttons-Default-Hover)"},"&:active":{backgroundColor:S?"rgba(0,0,0,0.15)":"var(--Buttons-Default-Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px"}},...m},...f,children:[S&&de(h,{component:"img",src:y,alt:o||"Avatar",onError:()=>x(!0),sx:{width:"100%",height:"100%",objectFit:"cover",borderRadius:"50%"}}),k&&(()=>{const{Comp:e,token:t}=function(e){switch(e){case"xxx-small":case"xx-small":case"x-small":return{Comp:To,token:"Overline-Small"};case"small":case"medium":case"large":default:return{Comp:Io,token:"Overline-Medium"};case"x-large":case"xx-large":return{Comp:zo,token:"Overline-Large"}}}(l);return de(e,{sx:{color:"inherit",fontSize:Ko[l]||Ko.medium,lineHeight:1,textAlign:"center",marginInlineEnd:`calc(-1 * var(--${t}-Letter-Spacing, 0px))`,...jr},"aria-hidden":"true",children:n.slice(0,2).toUpperCase()})})(),B&&de(jo,{size:l,sx:{color:"inherit"},children:i||de(me,{})})]})}function Jo({children:e,max:r=5,size:o="medium",spacing:n=-8,className:i="",sx:a={},...l}){const s=t.Children.toArray(e),d=s.slice(0,r),c=s.length-r;return ce(h,{role:"group","aria-label":"Avatar group, "+s.length+" avatars",className:"avatar-group "+i,sx:{display:"inline-flex",alignItems:"center","& > *:not(:first-of-type)":{marginLeft:n+"px"},...a},...l,children:[d,c>0&&de(qo,{initials:"+"+c,size:o,color:"neutral",sx:{border:"2px solid var(--Background)",zIndex:0}})]})}const Yo=["primary","secondary","tertiary","neutral","info","success","warning","error"],$o=e=>e.charAt(0).toUpperCase()+e.slice(1);function Zo(){const e={};return Yo.forEach(t=>{e[t]=function(e){const t=$o(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"none"}}(t),e[t+"-outline"]=function(e){return{bg:"var(--Background)",text:"var(--Text)",border:"1px solid var(--Buttons-"+$o(e)+"-Border)"}}(t),e[t+"-light"]=function(e){const t=$o(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"1px solid var(--Buttons-"+t+"-Border)"}}(t)}),e}const _o={small:{minW:16,height:16,fontSize:"10px",padding:"0 4px",dotSize:8},medium:{minW:20,height:20,fontSize:"12px",padding:"0 6px",dotSize:10},large:{minW:24,height:24,fontSize:"14px",padding:"0 8px",dotSize:12}};function en({variant:e="primary",size:t="medium",badgeContent:r,max:o=99,showZero:n=!1,invisible:i=!1,dot:a=!1,overlap:l="rectangular",anchorOrigin:s={vertical:"top",horizontal:"right"},children:d,className:c="",sx:u={},...p}){const h=Zo(),f=h[e]||h.primary,g=_o[t]||_o.medium;let x=r;a?x="":"number"==typeof r&&r>o&&(x=o+"+");const b=i||!a&&!n&&(0===r||null==r),v={"& .MuiBadge-badge":{minWidth:a?g.dotSize:g.minW,height:a?g.dotSize:g.height,padding:a?0:g.padding,fontSize:g.fontSize,fontWeight:600,fontFamily:"var(--Body-Font-Family)",lineHeight:1,borderRadius:a?"50%":g.height/2+"px",backgroundColor:f.bg,color:f.text,border:f.border,boxSizing:"border-box",boxShadow:"0 0 0 1px var(--Background)",transition:"transform 0.2s ease, opacity 0.2s ease"},...u};return de(m,{badgeContent:a?"":x,max:o,showZero:n,invisible:b,overlap:l,anchorOrigin:s,variant:a?"dot":"standard",className:"badge-"+e+" "+c,sx:v,...p,children:d})}const tn={1:[[.5,1,1]],2:[[1,2,2],[2,4,4]],3:[[1,2,2],[2,4,4],[3,6,6]],4:[[1,2,2],[2,4,4],[4,8,8],[8,16,16]],5:[[1,2,2],[2,4,4],[4,8,8],[8,16,16],[16,32,32]]},rn=[.2,.17,.15,.13,.11];function on(e){return tn[e].map(([e,t,r],o)=>`${e}px ${t}px ${r}px ${`var(--Dropshadow-Color-${o+1}, rgba(var(--Dropshadow-Color, 20, 20, 20), ${rn[o]}))`}`).join(", ")}const nn=on(1),an=on(2),ln=on(3),sn=on(4),dn=on(5),cn={0:"none",1:nn,2:an,3:ln,4:sn,5:dn},un={"black-white":"BlackWhite"},pn=e=>{return un[e]||(t=e).charAt(0).toUpperCase()+t.slice(1);var t},hn={small:"Sm-",medium:"",large:"Lg-"};function mn(e,t){const r=pn(e),o=(e,t)=>`color-mix(in srgb, rgb(var(${e}, ${t})) calc(var(--Button-Bevel-Opacity, 0.5) * 100%), transparent)`,n="var(--_bevel)",i="calc(-1 * var(--_bevel))",a=hn[t],l=void 0===a?(e,t)=>t:(e,t)=>`var(--${a}Button-${e}, ${t})`;return[`inset ${l("Lowlight-Offset-x",i)} ${l("Lowlight-Offset-y",i)} ${l("Lowlight-Blur-Radius",n)} ${l("Lowlight-Spread",i)} `+o(`--Buttons-${r}-Lowlight`,"0 0 0"),`inset ${l("Highlight-Offset-x",n)} ${l("Highlight-Offset-y",n)} ${l("Highlight-Blur-Radius",n)} ${l("Highlight-Spread",i)} `+o(`--Buttons-${r}-Highlight`,"255 255 255")].join(", ")}const fn={small:"4px 2px",medium:"4px 2px",large:"4px"},gn={small:{avatar:"xxx-small",icon:"small"},medium:{avatar:"xx-small",icon:"medium"},large:{avatar:"small",icon:"large"}};function xn(e,r){if(!t.isValidElement(e))return e;const o=gn[r]||gn.medium;return e.type===qo?t.cloneElement(e,{size:o.avatar,insideButton:!0}):e.type===jo?t.cloneElement(e,{size:o.icon}):e}const bn=["default","primary","secondary","tertiary","neutral","info","success","warning","error"],vn=pn;function yn(e,t=!1,r=!1,o="medium"){const n=vn(e),i=mn(e,o),a=t?nn:"none";return{backgroundColor:`var(--Buttons-${n}-Button)`,color:`var(--Buttons-${n}-Text)`,border:`var(--Button-Border-Width) solid var(--Buttons-${n}-Border)`,boxShadow:"none"===a?i:`${i}, ${a}`,position:"relative",zIndex:1,"& .MuiTouchRipple-rippleVisible":{color:`var(--Buttons-${n}-Hover)`,zIndex:-1},"&:hover":{backgroundColor:`var(--Buttons-${n}-Hover)`,boxShadow:`${i}, ${t?an:nn}`,...!r&&{transform:"translateY(-1px)"}},"&:active":{backgroundColor:`var(--Buttons-${n}-Pressed)`,boxShadow:i,...!r&&{transform:"translateY(0)"}},"&.Mui-focusVisible":{backgroundColor:`var(--Buttons-${n}-Button)`,outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"& .MuiTouchRipple-root":{zIndex:-1},"& .MuiTypography-root":{zIndex:1},"& .MuiButton-icon":{zIndex:1}}}function Sn(e,t=!1){return{backgroundColor:"transparent",color:"var(--Text)",border:`var(--Button-Border-Width) solid var(--Buttons-${vn(e)}-Border)`,boxShadow:"none","& .MuiTouchRipple-rippleVisible":{color:"var(--Hover)"},"&:hover":{backgroundColor:"var(--Hover)",boxShadow:"none",...!t&&{transform:"translateY(-1px)"}},"&:active":{backgroundColor:"var(--Pressed)",...!t&&{transform:"translateY(0)"}},"&.Mui-focusVisible":{backgroundColor:"transparent",outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}}}function kn(e,t=!1){return{backgroundColor:"transparent",color:e?"var(--Hotlink)":"var(--Quiet)",border:"var(--Button-Border-Width) solid transparent",boxShadow:"none",textDecoration:"none",...e&&{"& .btn-text-content":{textDecoration:"underline"}},"& .MuiTouchRipple-rippleVisible":{color:"var(--Hover)"},"&:hover":{backgroundColor:"var(--Hover)",boxShadow:"none",...!t&&{transform:"translateY(-1px)"},...e?{"& .btn-text-content":{textDecoration:"none"}}:{color:"var(--Text)"}},"&:active":{backgroundColor:"var(--Pressed)",...!t&&{transform:"translateY(0)"},...e?{"& .btn-text-content":{textDecoration:"none"}}:{color:"var(--Text)"}},"&.Mui-focusVisible":{backgroundColor:"transparent",outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px",...e&&{"& .btn-text-content":{textDecoration:"none"}}}}}function Bn(e,t=!1,r=!1,o="medium"){const n={};return bn.forEach(e=>{n[e]=yn(e,t,r,o),n[`${e}-outline`]=Sn(e,r),n[`${e}-light`]=function(e,t=!1,r=!1){const o=(n=e).charAt(0).toUpperCase()+n.slice(1);var n;return{backgroundColor:`var(--${o}-Color-11)`,color:`var(--Text-${o}-Color-11)`,border:`var(--Button-Border-Width) solid var(--Buttons-${o}-Border)`,boxShadow:t?nn:"none","& .MuiTouchRipple-rippleVisible":{color:`var(--Hover-${o}-Color-11)`},"&:hover":{backgroundColor:`var(--Hover-${o}-Color-11)`,boxShadow:t?an:nn,...!r&&{transform:"translateY(-1px)"}},"&:active":{backgroundColor:`var(--Pressed-${o}-Color-11)`,boxShadow:"none",...!r&&{transform:"translateY(0)"}},"&.Mui-focusVisible":{backgroundColor:`var(--${o}-Color-11)`,outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}}}(e,t,r)}),n["black-white"]=yn("black-white",t,r,o),n["black-white-outline"]=Sn("black-white",r),n.danger=yn("error",t,r,o),n.outline=Sn("default",r),n.ghost=kn(e,r),n.text=kn(e,r),n}const wn={small:"var(--Small-Button-Height)",medium:"var(--Button-Height)",large:"var(--Large-Button-Height)"},Cn={small:{minHeight:"var(--Small-Button-Height)",minWidth:"var(--Button-Min-Width)",fontSize:"13px","--_height":"var(--Small-Button-Height)"},large:{minHeight:"var(--Large-Button-Height)",minWidth:"var(--Lg-Button-Min-Width, var(--Button-Min-Width))",fontSize:"17px","--_height":"var(--Large-Button-Height)"},medium:{minHeight:"var(--Button-Height)",minWidth:"var(--Button-Min-Width)",fontSize:"15px","--_height":"var(--Button-Height)"}};function Tn({variant:e="default",size:r="medium",elevated:o=!1,selected:n=!1,fullWidth:i=!1,disabled:a=!1,iconOnly:l=!1,letterNumber:s=!1,avatar:d=!1,swatch:c=!1,swatchColor:u,startIcon:p,endIcon:m,startDecorator:b,endDecorator:v,badge:y=!1,badgeContent:S,badgeVariant:k="error",badgeSize:B,badgeDot:w=!1,badgeMax:C=99,badgeAnchorOrigin:T={vertical:"top",horizontal:"right"},children:I,className:A="",sx:z={},...R}){const E=l||d||c;if("production"!==process.env.NODE_ENV){const e=R["aria-label"]||R["aria-labelledby"]||R.title;E&&!e&&console.error('[OmniDesign] An icon-only <Button> has no accessible name. A screen reader announces it as just "button". Add aria-label="…" describing the ACTION ("Delete item"), not the icon ("trash").'),e&&t.Children.forEach(I,t=>{const r=t?.props?.["aria-label"]||t?.props?.titleAccess;r&&console.error('[OmniDesign] <Button> is labelled "'+e+'" but also contains an icon labelled "'+r+"\". A screen reader reads both. Remove the icon's label — the button owns the name.")})}const P=i&&!E&&!s,O=!d&&!c||"ghost"!==e&&"text"!==e?e:"primary",L=Bn(!E,o,n,r),M=L[O]||L.default,W=function({size:e,iconOnly:t,letterNumber:r,avatar:o}){const n=Cn[e]||Cn.medium,i=wn[e]||wn.medium;if(t)return{height:i,width:i,minWidth:"unset",minHeight:"unset",fontSize:o?"small"===e?"var(--Button-ExtraSmall-Font-Size)":"large"===e?"18px":"14px":"small"===e?"0.875rem":n.fontSize,padding:"0","--_height":i};return r?{...n,minHeight:i,minWidth:i,padding:"0"}:{...n,padding:"large"===e?"0 var(--Lg-Button-Padding)":"0 var(--Button-Padding)"}}({size:r,iconOnly:E,letterNumber:s,avatar:d}),D="small"===r?Fo:No,F=void 0!==b?xn(b,r):void 0,N=void 0!==v?xn(v,r):void 0,H=B||("small"===r?"small":"large"===r?"large":"medium"),V=ce(ue,{children:[de(f,{styles:{'[class*="btn-"] .MuiButton-startIcon, [class*="btn-"] .MuiButton-icon':{marginLeft:"0px !important",marginRight:"2px !important"},'[class*="btn-"] .MuiButton-endIcon':{marginLeft:"2px !important",marginRight:"0px !important"},'[class*="btn-"] .MuiButton-iconSizeSmall .MuiSvgIcon-root, [class*="btn-"] .MuiButton-iconSizeSmall > *':{fontSize:Vo.small+" !important"},'[class*="btn-"] .MuiButton-iconSizeMedium .MuiSvgIcon-root, [class*="btn-"] .MuiButton-iconSizeMedium > *':{fontSize:Vo.medium+" !important"},'[class*="btn-"] .MuiButton-iconSizeLarge .MuiSvgIcon-root, [class*="btn-"] .MuiButton-iconSizeLarge > *':{fontSize:Vo.large+" !important"}}}),de(g,{size:r,...P&&{fullWidth:!0},disabled:a,startIcon:void 0!==F?F:d?(()=>{if(d&&I){const e=wn[r]||wn.medium;return de(x,{sx:{width:e,height:e,backgroundColor:"inherit",color:"inherit",fontSize:"small"===r?"var(--Button-ExtraSmall-Font-Size)":"large"===r?"18px":"14px"},children:I})}return p})():p,endIcon:void 0!==N?N:m,className:`btn-${e} ${A}`,role:"button",sx:{borderRadius:d?"var(--Large-Button-Height)":l||c?"small"===r?"var(--Sm-Button-Icon-Radius, var(--Button-Icon-Radius))":"large"===r?"var(--Lg-Button-Icon-Radius, var(--Button-Icon-Radius))":"var(--Button-Icon-Radius)":"small"===r?"var(--Sm-Button-Radius, var(--Button-Radius))":"large"===r?"var(--Lg-Button-Radius, var(--Button-Radius))":"var(--Button-Radius)",textTransform:"none",fontWeight:"inherit",lineHeight:1,whiteSpace:"nowrap",flexShrink:0,transition:"background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out, transform 0.15s ease-in-out","--_bevel":"min(calc(var(--Button-Bevel) * var(--_height) / 100), calc(var(--_height) / 5))",..."small"===r&&{position:"relative","&::before":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"100%",height:"100%",minWidth:"var(--Target, 0px)",minHeight:"var(--Target, 0px)"}},...W,...M,"&.MuiButton-root":{padding:W.padding??"0 var(--Sizing-1)"},"& .MuiButton-startIcon":{display:"inherit",color:"inherit",marginLeft:"0px !important",marginRight:d?"0px !important":"2px !important"},...d&&{"& .MuiAvatar-root":{fontSize:"small"===r?"var(--Button-ExtraSmall-Font-Size)":"large"===r?"18px":"14px"}},"& .MuiButton-endIcon":{display:"inherit",color:"inherit",marginLeft:"2px !important",marginRight:"0px !important"},"& .MuiSvgIcon-root":{color:"inherit"},"&:focus-visible, &.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none",backgroundColor:M.backgroundColor,color:M.color,border:M.border,boxShadow:"none"},...c&&{border:"var(--Button-Border-Width) solid var(--Border)",padding:"1px",width:wn[r]||wn.medium,height:wn[r]||wn.medium,minWidth:"unset",minHeight:"unset",boxShadow:"none","--_bevel":"0",backgroundColor:"transparent !important","&:hover":{backgroundColor:"transparent !important",boxShadow:"none"},"&:active":{boxShadow:"none"},"&:hover .btn-swatch-inner":{filter:"brightness(0.9)"}},...P&&{width:"100%"},...z},...R,...c?{style:{backgroundColor:"transparent"}}:{},children:d?null:c?de(h,{className:"btn-swatch-inner",style:{width:"100%",height:"100%",borderRadius:"small"===r?"var(--Sm-Button-Icon-Inner-Radius, calc(var(--Button-Icon-Radius) - 2px))":"large"===r?"var(--Lg-Button-Icon-Inner-Radius, calc(var(--Button-Icon-Radius) - 2px))":"var(--Button-Icon-Inner-Radius, calc(var(--Button-Icon-Radius) - 2px))",...u?{backgroundColor:u}:{}}}):(()=>{if(E)return I;if(s){return de("small"===r?Do:D,{component:"span",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",padding:"4px",color:"inherit",lineHeight:1,...jr},children:I})}return"string"==typeof I||"number"==typeof I?de(h,{component:"span",className:"btn-text-content",sx:{display:"inline-flex",alignItems:"center",padding:fn[r]||fn.medium},children:de(D,{component:"span",sx:{color:"inherit",...jr},children:I})}):I})()})]});return y?de(en,{variant:k,size:H,badgeContent:S,dot:w,max:C,anchorOrigin:T,showZero:0===S,children:V}):V}const In=["default","primary","secondary","tertiary","neutral","info","success","warning","error"],An=e=>e.charAt(0).toUpperCase()+e.slice(1);function zn(e){const t=An(e);return{type:"outline",color:t,borderToken:"var(--Buttons-"+t+"-Border)",icon:"var(--Buttons-"+t+"-Border)"}}function Rn(e){const t=An(e);return{type:"light",color:t,borderToken:"var(--Buttons-"+t+"-Border)",icon:"var(--Buttons-"+t+"-Border)",dataTheme:t,dataSurface:"Surface-Brightest"}}function En(){const e={};return In.forEach(t=>{e[t+"-outline"]=zn(t),e[t+"-light"]=Rn(t)}),e.primary=zn("primary"),e.default=zn("default"),e.outline=zn("primary"),e.light=Rn("primary"),e}const Pn={small:{box:16,icon:12,labelSize:"13px",gap:6,touchTarget:24},medium:{box:20,icon:14,labelSize:"15px",gap:8,touchTarget:24},large:{box:24,icon:18,labelSize:"17px",gap:10,touchTarget:24}};function On({size:e,variant:t,checked:r,indeterminate:o}){const n=En(),i=n[t]||n.primary,a=Pn[e]||Pn.medium,l=r||o,s="light"===i.type,d=i.borderToken,c="small"===e?"var(--Sm-Checkbox-Radius, 3.2px)":"large"===e?"var(--Lg-Checkbox-Radius, 4.8px)":"var(--Checkbox-Radius, 4px)",u=s?{"data-theme":i.dataTheme,"data-surface":i.dataSurface||"Surface-Brightest"}:{};return de(h,{className:"chk-box-icon",sx:{width:a.box,height:a.box,boxSizing:"border-box",borderRadius:c,border:"2px solid "+d,overflow:"hidden",flexShrink:0,transition:"border-color 0.15s ease-in-out"},children:de(h,{...u,sx:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"var(--Background)",color:"var(--Text)",transition:"background-color 0.15s ease-in-out"},children:l&&de(o?fe:he,{sx:{fontSize:a.icon,color:i.icon}})})})}function Ln({size:e,variant:t}){return de(On,{size:e,variant:t,checked:!1,indeterminate:!1})}function Mn({size:e,variant:t}){return de(On,{size:e,variant:t,checked:!0,indeterminate:!1})}function Wn({size:e,variant:t}){return de(On,{size:e,variant:t,checked:!1,indeterminate:!0})}function Dn({variant:e="primary",size:t="medium",label:r,checked:o,defaultChecked:n,indeterminate:i=!1,disabled:a=!1,onChange:l,name:s,value:d,className:c="",sx:u={},"aria-label":p,"aria-labelledby":h,"aria-describedby":m,inputProps:f={},...g}){En();const x=Pn[t]||Pn.medium,y="small"===t?ao:co,S={...f,...p&&{"aria-label":p},...h&&{"aria-labelledby":h},...m&&{"aria-describedby":m}},k=de(b,{checked:o,defaultChecked:n,indeterminate:i,disabled:a,onChange:l,name:s,value:d,icon:de(Ln,{size:t,variant:e}),checkedIcon:de(Mn,{size:t,variant:e}),indeterminateIcon:de(Wn,{size:t,variant:e}),className:"chk-"+e+" "+c,inputProps:S,disableRipple:!0,sx:{padding:(x.touchTarget-x.box)/2+"px",minWidth:24,minHeight:24,borderRadius:"var(--Checkbox-Radius, 4px)",color:"inherit",transition:"background-color 0.15s ease-in-out","&.Mui-checked, &.MuiCheckbox-indeterminate":{color:"inherit"},"&:hover":{backgroundColor:"transparent"},"&.Mui-focusVisible .chk-box-icon":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none"},...u},...g});return r?de(v,{control:k,label:de(y,{component:"span",sx:{color:a?"var(--Text-Quiet)":"var(--Text)",fontSize:x.labelSize,lineHeight:1.4,userSelect:"none"},children:r}),disabled:a,sx:{marginLeft:0,marginRight:0,gap:x.gap+"px",alignItems:"center","&.Mui-disabled .MuiTypography-root":{color:"var(--Text-Quiet)",opacity:.6}}}):k}const Fn=["primary","secondary","tertiary","neutral","info","success","warning","error"],Nn=e=>e.charAt(0).toUpperCase()+e.slice(1);function Hn(e){return{bg:"var(--Hover)",border:"var(--Buttons-"+Nn(e)+"-Border)",text:"var(--Text)",focusBg:"var(--Hover)"}}function Vn(e){const t=Nn(e);return{bg:"var(--Buttons-"+t+"-Light-Button, var(--Hover))",border:"var(--Buttons-"+t+"-Border)",text:"var(--Text)",focusBg:"var(--Buttons-"+t+"-Light-Button, var(--Hover))"}}const Qn={small:{height:"var(--Small-Button-Height)",fontSize:"13px",labelSize:"13px",padding:"4px var(--Input-Padding, 8px)",iconSize:16},medium:{height:"var(--Button-Height)",fontSize:"15px",labelSize:"15px",padding:"4px var(--Input-Padding, 12px)",iconSize:18},large:{height:"var(--Large-Button-Height)",fontSize:"17px",labelSize:"17px",padding:"4px var(--Input-Padding, 16px)",iconSize:20}},jn={small:{height:"48px",fontSize:"13px",labelSize:"11px",padding:"20px var(--Input-Padding, 12px) 4px",leftPad:12,iconSize:16},medium:{height:"56px",fontSize:"15px",labelSize:"12px",padding:"22px var(--Input-Padding, 14px) 6px",leftPad:14,iconSize:18},large:{height:"64px",fontSize:"17px",labelSize:"14px",padding:"24px var(--Input-Padding, 16px) 6px",leftPad:16,iconSize:20}},Gn={info:ve,success:ge,warning:xe,error:be},Un={info:{border:"var(--Buttons-Info-Border)",icon:"var(--Icons-Info)",text:"var(--Hotlink)"},success:{border:"var(--Buttons-Success-Border)",icon:"var(--Icons-Success)",text:"var(--Text-Success)"},warning:{border:"var(--Buttons-Warning-Border)",icon:"var(--Icons-Warning)",text:"var(--Text-Warning)"},error:{border:"var(--Buttons-Error-Border)",icon:"var(--Icons-Error)",text:"var(--Text-Error)"}};function Xn({variant:e="primary-outline",size:t="medium",label:r,labelPosition:o="standard",placeholder:n,helperText:i,validation:a,validationMessage:l,disabled:s=!1,value:d,defaultValue:c,onChange:u,name:p,type:m="text",multiline:f=!1,rows:g,maxRows:x,startAdornment:b,endAdornment:v,fullWidth:B=!1,className:w="",sx:C={},"aria-label":T,"aria-labelledby":I,"aria-describedby":A,"aria-required":z,"aria-invalid":R,inputProps:E={},...P}){const O=function(){const e={};return Fn.forEach(t=>{e[t+"-outline"]=Hn(t),e[t+"-light"]=Vn(t)}),e.outline=Hn("primary"),e.light=Vn("primary"),e}(),L=O[e]||O["primary-outline"],M="floating"===o;e.endsWith("-light");const W=M?jn[t]||jn.medium:Qn[t]||Qn.medium,D=e.replace(/-outline$/,"").replace(/-light$/,"");Nn(D);const F="var(--Text)",N=a?Un[a]:null,H=a?Gn[a]:null,V=N?N.border:L.border,Q={...E,...T&&{"aria-label":T},...I&&{"aria-labelledby":I},...A&&{"aria-describedby":A},...z&&{"aria-required":z},...R&&{"aria-invalid":R}};return ce(h,{className:"inp-"+e+" "+w,sx:{width:B?"100%":"auto",...C},children:[(()=>{if(!r||M)return null;return de("small"===t?ao:co,{component:"label",sx:{display:"block",marginBottom:"6px",color:s?"var(--Quiet)":"var(--Text)",fontSize:W.labelSize,fontWeight:500,opacity:s?.6:1},children:r})})(),de(h,{sx:{border:"1px solid "+V,borderRadius:"small"===t?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===t?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease-in-out",boxShadow:"none","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{children:de(y,{value:d,defaultValue:c,onChange:u,name:p,type:m,disabled:s,placeholder:n,multiline:f,rows:g,maxRows:x,fullWidth:!0,label:M?r:void 0,variant:"outlined",size:"small"===t?"small":"medium",inputProps:Q,InputProps:{startAdornment:b?de(S,{position:"start",children:b}):void 0,endAdornment:(()=>{if(v)return de(S,{position:"end",children:v})})()},sx:{"& .MuiOutlinedInput-root":{backgroundColor:"var(--Hover)",color:"var(--Quiet)",fontSize:W.fontSize,minHeight:f?"auto":W.height,padding:0,borderRadius:0,transition:"color 0.15s ease-in-out",...M&&{alignItems:"flex-end"},"& fieldset":{border:"none"},"&.Mui-focused":{color:F},"&:not(.Mui-focused) .MuiOutlinedInput-input:not(:placeholder-shown)":{color:F},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed"},"& input":{padding:W.padding,color:"inherit","&::placeholder":{color:"var(--Quiet)",opacity:1}},"& textarea":{padding:W.padding,color:"inherit","&::placeholder":{color:"var(--Quiet)",opacity:1}},"& .MuiInputAdornment-root":{color:"var(--Quiet)"},...M&&{"& .MuiInputAdornment-positionStart":{marginLeft:(W.leftPad||14)+"px",marginRight:"4px",marginBottom:"8px"},"& .MuiInputAdornment-positionEnd":{marginRight:"8px",marginBottom:"8px"},...b&&{"& input":{paddingLeft:"4px"},"& textarea":{paddingLeft:"4px"}}}},"& .MuiInputLabel-root":{color:"var(--Quiet)",fontSize:W.fontSize,transformOrigin:"top left",transform:"translate("+((W.leftPad||14)+(b?32:0))+"px, 16px) scale(1)","&.MuiInputLabel-shrink":{transform:"translate("+((W.leftPad||14)+(b?32:0))+"px, 6px) scale(0.75)",color:"var(--Quiet)"},"&.Mui-focused":{color:F},"&.Mui-disabled":{color:"var(--Quiet)",opacity:.6}},"& .MuiOutlinedInput-notchedOutline legend":{display:"none"},"& .MuiOutlinedInput-notchedOutline":{top:0},"& .MuiOutlinedInput-root.Mui-focused":{outline:"none"},"& .MuiOutlinedInput-root:focus-within":{outline:"none"}},...P})})}),a&&l?ce(h,{sx:{display:"flex",alignItems:"center",gap:"6px",marginTop:"4px",marginLeft:"2px"},children:[H&&de(H,{sx:{fontSize:W.iconSize,color:N.icon,flexShrink:0}}),de(k,{sx:{color:N.text,fontSize:"small"===t?"11px":"12px",margin:0},children:l})]}):i?de(k,{sx:{color:"var(--Quiet)",fontSize:"small"===t?"11px":"12px",marginTop:"4px",marginLeft:"2px"},children:i}):null]})}const Kn=e=>e.charAt(0).toUpperCase()+e.slice(1),qn={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 8px",iconSize:16},medium:{height:"var(--Button-Height)",fontSize:"14px",padding:"6px 12px",iconSize:18},large:{height:"var(--Large-Button-Height)",fontSize:"16px",padding:"8px 16px",iconSize:20}},Jn={small:{height:48,fontSize:"13px",padding:"20px 12px 4px",labelSize:"11px",leftPad:12},medium:{height:56,fontSize:"14px",padding:"22px 14px 6px",labelSize:"12px",leftPad:14},large:{height:64,fontSize:"16px",padding:"24px 16px 6px",labelSize:"14px",leftPad:16}};function Yn({options:e=[],value:a,defaultValue:l="",onChange:s,label:d,labelPosition:c="top",size:u="medium",variant:p="outline",color:m="primary",selectionStyle:f="default",mode:g="standard",placeholder:x="Select…",showDividers:b=!1,showColorLabels:v=!0,startDecoration:y,disabled:S=!1,fullWidth:k=!1,className:B="",sx:w={},...C}){const T="default"===m?"primary":m,I=Kn(T),A="var(--Buttons-"+I+"-Border)",z="default"===m?"var(--Text)":"var(--Text-"+I+")",[R,E]=r(l),[P,O]=r(!1),[L,M]=r(!1),[W,D]=r({top:0,left:0,width:0,direction:"down"}),F=o(null),N=o(null),[H,V]=r(null),[Q,j]=r(null),G=void 0!==a,U=G?a:R,X=e.flatMap(e=>e&&Array.isArray(e.options)?e.options:[e]).find(e=>("string"==typeof e?e:e.value)===U),K=X?"string"==typeof X?X:X.label:"",q=""!==U&&null!=U,J="floating"===c,Y="top"===c,$="color"===g,Z=J?Jn[u]||Jn.medium:qn[u]||qn.medium,_=n(e=>{G||E(e),s?.(e),O(!1),N.current?.focus()},[G,s]),ee=n(()=>{if(!N.current)return{top:0,left:0,width:0};const e=N.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top,o=t>=240||t>=r?"down":"up";return{top:"down"===o?e.bottom+4:void 0,bottom:"up"===o?window.innerHeight-e.top+4:void 0,left:e.left,width:e.width,direction:o}},[]),te=n(()=>{S||O(e=>(e||D(ee()),!e))},[S,ee]);i(()=>{if(!P)return;const e=e=>{!F.current||F.current.contains(e.target)||e.target.closest("[data-select-dropdown]")||O(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[P]),i(()=>{if(!P||!N.current)return;const e=N.current.closest("[data-theme]"),t=N.current.closest("[data-surface]");V(e?.getAttribute("data-theme")||null),j(t?.getAttribute("data-surface")||null);const r=()=>D(ee());return window.addEventListener("scroll",r,!0),window.addEventListener("resize",r),()=>{window.removeEventListener("scroll",r,!0),window.removeEventListener("resize",r)}},[P,ee]);const re=o(null),oe=n(e=>{const t=re.current;if(!t)return;const r=t.querySelectorAll('[role="option"]');if(!r.length)return;const o=t.querySelector('[role="option"]:focus');let n=Array.prototype.indexOf.call(r,o);n="down"===e?n<r.length-1?n+1:0:n>0?n-1:r.length-1,r[n].focus()},[]);i(()=>{P&&requestAnimationFrame(()=>{const e=re.current;if(!e)return;const t=e.querySelector('[aria-selected="true"]'),r=e.querySelector('[role="option"]');(t||r)?.focus()})},[P]);const ne=P?ye.createPortal(de(h,{ref:re,"data-select-dropdown":!0,"data-theme":H||void 0,role:"listbox","aria-label":d||"Options",sx:{position:"fixed",top:W.top??"unset",bottom:W.bottom??"unset",left:W.left,width:W.width+"px",backgroundColor:"var(--Hover)",border:"1px solid var(--Buttons-Default-Border)",borderRadius:"var(--Dropdown-Frame-Radius, var(--Input-Radius, var(--Style-Border-Radius, 4px)))",boxShadow:"none",zIndex:99999,maxHeight:"240px",overflowY:"auto",py:.5},children:(()=>{const r=(e,r,o)=>{const n="string"==typeof e?e:e.value,i="string"==typeof e?e:e.label,a="object"==typeof e?e.color:null,l=n===U,s=function(e,t,r){const o=Kn(r||"default");return t?"solid"===e?{backgroundColor:"var(--Buttons-"+o+"-Button)",color:"var(--Buttons-"+o+"-Text)",border:"1px solid var(--Buttons-"+o+"-Border)",fontWeight:600}:"light"===e?{backgroundColor:"var(--Buttons-"+o+"-Light-Button)",color:"var(--Buttons-"+o+"-Light-Text)",border:"1px solid var(--Buttons-"+o+"-Light-Border)",fontWeight:600}:{backgroundColor:"var(--Buttons-"+o+"-Button)",color:"var(--Buttons-"+o+"-Text)",border:"1px solid var(--Buttons-"+o+"-Border)",fontWeight:600}:{color:"var(--Text)",backgroundColor:"transparent",border:"1px solid transparent"}}(f,l,T),d=r===o-1;return ce(t.Fragment,{children:[ce(h,{role:"option",tabIndex:-1,"aria-selected":l,"aria-label":$&&!v?i:void 0,onClick:()=>_(n),onKeyDown:e=>((e,t)=>{if("Enter"===e.key||" "===e.key)return e.preventDefault(),void _(t);"ArrowDown"===e.key&&(e.preventDefault(),oe("down")),"ArrowUp"===e.key&&(e.preventDefault(),oe("up")),"Escape"===e.key&&(O(!1),N.current?.focus())})(e,n),sx:{display:"flex",alignItems:"center",gap:1,px:1.5,py:0,mx:.5,my:"1px",minHeight:Z.height,cursor:"pointer",fontSize:Z.fontSize,fontFamily:"inherit",borderRadius:"4px",outline:"none",...s,transition:"background-color 0.1s ease","&:hover":l?{}:{backgroundColor:"var(--Buttons-"+I+"-Hover)",color:"var(--Buttons-"+I+"-Text)"},"&:active":l?{}:{backgroundColor:"var(--Buttons-"+I+"-Pressed)",color:"var(--Buttons-"+I+"-Text)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:[$&&a&&de(h,{sx:{height:"calc("+Z.height+" - 8px)",width:"calc("+Z.height+" - 8px)",borderRadius:"var(--Input-Swatch-Radius, var(--Button-Radius))",backgroundColor:a,border:"1px solid "+(l?"var(--Buttons-"+I+"-Border)":"var(--Border)"),flexShrink:0}}),(!$||v)&&de(ao,{style:{flex:1,color:"inherit",fontWeight:"inherit"},children:i}),l&&de(jo,{size:"small",sx:{opacity:.6,flexShrink:0},children:de(he,{})})]}),b&&!d&&de(h,{"aria-hidden":"true",sx:{height:"1px",backgroundColor:"var(--Border)",mx:1,my:.25}})]},n)};return e.map((o,n)=>{if(o&&Array.isArray(o.options)){const e=o.options;return ce(t.Fragment,{children:[de(h,{role:"presentation",sx:{px:1.5,pt:0===n?.75:1.25,pb:.5,fontSize:"11px",fontFamily:"inherit",fontWeight:700,letterSpacing:"0.06em",textTransform:"uppercase",color:"var(--Text-Quiet)"},children:o.label}),e.map((t,o)=>r(t,o,e.length))]},"group-"+(o.label||n))}return r(o,n,e.length)})})()}),document.body):null;return ce(h,{ref:F,className:"select-wrapper select-"+u+" select-label-"+c+" select-style-"+f+" select-variant-"+p+(P?" select-open":"")+(S?" select-disabled":"")+(B?" "+B:""),sx:{position:"relative",width:k?"100%":"auto",display:"inline-block",fontFamily:"inherit",...w},...C,children:[Y&&d&&de("small"===u?ao:co,{component:"label",style:{display:"block",marginBottom:"6px",color:S?"var(--Quiet)":"var(--Text)",fontWeight:500,opacity:S?.6:1},children:d}),de(h,{sx:{border:"1px solid "+A,borderRadius:"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease",boxShadow:"none","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{children:ce(h,{ref:N,component:"button",type:"button",role:"combobox","aria-expanded":P,"aria-haspopup":"listbox","aria-label":d||x,tabIndex:S?-1:0,onClick:te,onKeyDown:e=>"Escape"===e.key?(O(!1),void N.current?.focus()):"Enter"===e.key||" "===e.key?(e.preventDefault(),void te()):P||"ArrowDown"!==e.key&&"ArrowUp"!==e.key?(P&&"ArrowDown"===e.key&&(e.preventDefault(),oe("down")),void(P&&"ArrowUp"===e.key&&(e.preventDefault(),oe("up")))):(e.preventDefault(),void O(!0)),onFocus:()=>M(!0),onBlur:()=>M(!1),sx:{display:"flex",alignItems:"center",gap:1,width:"100%",minWidth:140,height:Z.height,padding:Z.padding,backgroundColor:"var(--Hover)",border:"none",borderRadius:0,color:q||P?z:"var(--Quiet)",fontSize:Z.fontSize,fontFamily:"inherit",cursor:S?"not-allowed":"pointer",opacity:S?.5:1,outline:"none",textAlign:"left",position:"relative",transition:"color 0.15s ease"},children:[y&&de(h,{sx:{display:"flex",alignItems:"center",flexShrink:0,color:"var(--Text-Quiet)"},children:y}),J&&d&&de(h,{sx:{position:"absolute",top:q||P?"6px":"50%",left:(Z.leftPad||14)+(y?32:0)+"px",transform:q||P?"scale(0.75)":"translateY(-50%)",transformOrigin:"top left",color:P?z:"var(--Quiet)",fontSize:Z.fontSize,fontWeight:400,pointerEvents:"none",transition:"top 0.15s ease, transform 0.15s ease, color 0.15s ease"},children:d}),de(h,{sx:{flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",...J&&{mt:q||P?"8px":0}},children:$&&q?ce(h,{sx:{display:"flex",alignItems:"center",gap:1},children:[de(h,{sx:{height:"calc("+Z.height+" - 8px)",width:"calc("+Z.height+" - 8px)",borderRadius:"var(--Input-Swatch-Radius, var(--Button-Radius))",backgroundColor:X&&"string"!=typeof X&&X.color||"transparent",border:"1px solid var(--Border)",flexShrink:0}}),v&&de(ao,{style:{color:"inherit",padding:0},children:K})]}):de(ao,{style:{color:"inherit",padding:0},children:q?K:J&&d?"":x})}),de(Se,{sx:{fontSize:(Z.iconSize||18)+"px",color:"var(--Text-Quiet)",transform:P?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease",flexShrink:0}})]})})}),ne]})}const $n={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Zn={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},_n={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ei={small:{px:"10px",py:"6px",fontSize:"13px",iconSize:"16px",gap:"4px",indicatorThickness:"3px",minHeight:"32px"},medium:{px:"14px",py:"8px",fontSize:"14px",iconSize:"18px",gap:"6px",indicatorThickness:"3px",minHeight:"40px"},large:{px:"18px",py:"10px",fontSize:"16px",iconSize:"20px",gap:"8px",indicatorThickness:"3px",minHeight:"48px"}},ti=s({value:0,setValue:()=>{},variant:"standard",color:"primary",size:"medium",orientation:"horizontal",scrollable:!1,tabsId:""}),ri=()=>l(ti);function oi({children:e,defaultValue:t=0,value:o,onChange:i,variant:l="standard",color:s="primary",size:d="medium",orientation:c="horizontal",scrollable:u=!1,className:p="",sx:m={},...f}){const[g,x]=r(t),b=void 0!==o,v=b?o:g,y=a(),S=n(e=>{b||x(e),i?.(e)},[b,i]);return de(ti.Provider,{value:{value:v,setValue:S,variant:l,color:s,size:d,orientation:c,scrollable:u,tabsId:y},children:de(h,{className:"tabs tabs-"+c+" tabs-"+d+" tabs-"+l+("standard"!==l?" tabs-"+s:"")+(u?" tabs-scrollable":"")+" "+p,sx:{display:"flex",flexDirection:"horizontal"===c?"column":"row",width:"100%",overflow:"hidden",...m},...f,children:e})})}function ni({children:e,rounded:a=!1,className:l="",sx:s={},...d}){const{variant:c,color:u,size:p,orientation:m,scrollable:f,tabsId:g}=ri(),x=o(null),b=o(null),[v,y]=r(!1),[S,k]=r(!1),B="horizontal"===m,w="standard"===c,C="light"===c,T="dark"===c,I=w?void 0:"solid"===c?$n[u]:C?Zn[u]:T?_n[u]:void 0,A=w?void 0:T?"Surface-Dimmest":C?"Surface-Brightest":"Surface",z=n(()=>{const e=b.current;e&&f&&B&&(y(e.scrollLeft>1),k(e.scrollLeft<e.scrollWidth-e.clientWidth-1))},[f,B]);i(()=>{z();const e=b.current;if(!e||!f)return;e.addEventListener("scroll",z,{passive:!0});const t=new ResizeObserver(z);return t.observe(e),()=>{e.removeEventListener("scroll",z),t.disconnect()}},[f,z]);const R=e=>{const t=b.current;if(!t)return;const r=.6*t.clientWidth;t.scrollBy({left:e*r,behavior:"smooth"})},E={display:"inline-flex",alignItems:"center",justifyContent:"center",width:"28px",minWidth:"28px",border:"none",backgroundColor:"transparent",color:"var(--Text-Quiet)",cursor:"pointer",fontSize:"16px",fontFamily:"inherit",lineHeight:1,flexShrink:0,transition:"color 0.15s ease, background-color 0.15s ease","&:hover":{color:"var(--Text)",backgroundColor:"var(--Hover)"},"&:active":{backgroundColor:"var(--Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},"&:disabled":{opacity:.3,cursor:"default","&:hover":{backgroundColor:"transparent",color:"var(--Text-Quiet)"}}},P=t.Children.toArray(e).filter(t.isValidElement).map((e,r)=>t.cloneElement(e,{_index:r,key:e.key||r}));return ce(h,{ref:x,"data-theme":I||void 0,"data-surface":A||void 0,className:"tab-list tab-list-"+c+" tab-list-"+p+" tab-list-"+m+(f?" tab-list-scrollable":"")+" "+l,onKeyDown:e=>{const t=f?b.current:x.current,r=t?.querySelectorAll('[role="tab"]:not([aria-disabled="true"])');if(!r?.length)return;const o=Array.from(r).indexOf(document.activeElement);if(o<0)return;const n=B?"ArrowRight":"ArrowDown",i=B?"ArrowLeft":"ArrowUp";if(e.key===n){e.preventDefault();const t=r[(o+1)%r.length];t.focus(),f&&t.scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"})}else if(e.key===i){e.preventDefault();const t=r[(o-1+r.length)%r.length];t.focus(),f&&t.scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"})}else"Home"===e.key?(e.preventDefault(),r[0].focus(),f&&r[0].scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"})):"End"===e.key&&(e.preventDefault(),r[r.length-1].focus(),f&&r[r.length-1].scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"}))},sx:{display:"flex",flexDirection:B?"row":"column",gap:0,position:"relative",backgroundColor:"var(--Background)",padding:"4px",overflow:"hidden",borderRadius:a?"var(--Style-Border-Radius)":0,...s},...d,children:[f&&B&&de(h,{component:"button","aria-label":"Scroll tabs left",onClick:()=>R(-1),disabled:!v,className:"tab-list-scroll-btn tab-list-scroll-btn-left",sx:E,children:"‹"}),de(h,f&&B?{ref:b,role:"tablist","aria-orientation":m,className:"tab-list-scroll-container",sx:{display:"flex",flexDirection:"row",overflowX:"auto",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"},flex:1,minWidth:0},children:P}:{ref:b,role:"tablist","aria-orientation":m,sx:{display:"flex",flexDirection:B?"row":"column",flex:1},children:P}),f&&B&&de(h,{component:"button","aria-label":"Scroll tabs right",onClick:()=>R(1),disabled:!S,className:"tab-list-scroll-btn tab-list-scroll-btn-right",sx:E,children:"›"})]})}function ii({children:e,value:t,_index:r=0,disabled:o=!1,startDecorator:n,endDecorator:i,iconOnly:a=!1,className:l="",sx:s={},...d}){const{value:c,setValue:u,variant:p,color:m,size:f,orientation:g,tabsId:x}=ri(),b=ei[f]||ei.medium,v="horizontal"===g,y="standard"===p,S="light"===p,k="dark"===p,B=void 0!==t?t:r,w=c===B,C=y?"var(--Buttons-"+({default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"}[m]||"Default")+"-Border)":"var(--Text)";return ce(h,{component:"button",role:"tab",id:"tab-"+x+"-"+B,"data-theme":(y?void 0:"solid"===p?$n[m]:S?Zn[m]:k?_n[m]:void 0)||void 0,"data-surface":(y?void 0:k?"Surface-Dimmest":S?"Surface-Brightest":"Surface")||void 0,"aria-selected":w,"aria-controls":"tabpanel-"+x+"-"+B,"aria-disabled":o||void 0,tabIndex:w?0:-1,onClick:()=>{o||u(B)},className:"tab tab-"+f+(w?" tab-selected":"")+(o?" tab-disabled":"")+(a?" tab-icon-only":"")+" "+l,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",gap:b.gap,padding:a?"calc("+b.py+" + 4px) "+b.py+" "+b.py:"calc("+b.py+" + 4px) "+b.px+" "+b.py+" "+b.px,minHeight:b.minHeight,fontSize:b.fontSize,fontFamily:"inherit",fontWeight:500,lineHeight:1.3,color:w?"var(--Text)":"var(--Quiet)",backgroundColor:"transparent",border:"none",borderBottom:v?w?b.indicatorThickness+" solid "+C:b.indicatorThickness+" solid transparent":"none",borderRight:v?"none":w?b.indicatorThickness+" solid "+C:b.indicatorThickness+" solid transparent",cursor:o?"not-allowed":"pointer",opacity:o?.5:1,position:"relative",outline:"none",transition:"color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease",flexShrink:0,whiteSpace:"nowrap",...!o&&{"&:hover":{backgroundColor:"var(--Hover)"},"&:active":{backgroundColor:"var(--Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},...s},...d,children:[n&&de(h,{className:"tab-start-decorator",sx:{display:"inline-flex",fontSize:b.iconSize,lineHeight:1,flexShrink:0},children:n}),!a&&e&&de("small"===f?bo:ao,{style:{color:"inherit",fontWeight:"inherit"},children:e}),i&&de(h,{className:"tab-end-decorator",sx:{display:"inline-flex",fontSize:b.iconSize,lineHeight:1,flexShrink:0},children:i})]})}function ai({children:e,value:t,className:r="",sx:o={},...n}){const{value:i,size:a,tabsId:l}=ri();return i===t?de(h,{role:"tabpanel",id:"tabpanel-"+l+"-"+t,"aria-labelledby":"tab-"+l+"-"+t,className:"tab-panel tab-panel-"+a+" "+r,sx:{paddingTop:"16px",fontSize:(ei[a]||ei.medium).fontSize,fontFamily:"inherit",color:"var(--Text)",...o},...n,children:e}):null}const li=t.forwardRef(function({theme:e=null,surface:t="Surface",children:r,minHeight:o=160,sx:n={}},i){return de(h,{ref:i,"data-theme":e||void 0,"data-surface":t,sx:{p:4,display:"flex",alignItems:"center",justifyContent:"center",minHeight:o,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)",...n},children:r})}),si="__null__",di=[{label:"Default",value:si},{label:"Primary",value:"Primary"},{label:"Secondary",value:"Secondary"},{label:"Tertiary",value:"Tertiary"},{label:"Neutral",value:"Neutral"},{label:"Info",value:"Info"},{label:"Success",value:"Success"},{label:"Warning",value:"Warning"},{label:"Error",value:"Error"}],ci=["Surface-Dimmest","Surface-Dim","Surface","Surface-Bright","Surface-Brightest","Container","Container-Highest","Container-High","Container-Low","Container-Lowest"];function ui({theme:e=null,onThemeChange:t,surface:r="Surface",onSurfaceChange:o,surfaces:n=ci,size:i="small"}){const a=n.map(e=>({value:e,label:e}));return ce(B,{direction:"row",spacing:1,sx:{alignItems:"center"},children:[de(h,{sx:{width:160},children:de(Yn,{options:di,value:e??si,onChange:e=>t?.(e===si?null:e),labelPosition:"none",size:i,variant:"outline",color:"default","aria-label":"Background theme",fullWidth:!0})}),de(h,{sx:{width:180},children:de(Yn,{options:a,value:r,onChange:e=>o?.(e),labelPosition:"none",size:i,variant:"outline",color:"default","aria-label":"Surface",fullWidth:!0})})]})}function pi(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var hi,mi={exports:{}},fi={exports:{}},gi={};var xi,bi,vi,yi,Si,ki,Bi,wi,Ci,Ti,Ii,Ai,zi,Ri,Ei={};
1
+ import*as e from"react";import t,{useState as r,useRef as o,useCallback as n,useEffect as i,useId as a,useContext as l,createContext as s,useMemo as d,forwardRef as c,Children as u,isValidElement as p}from"react";import{Box as h,Badge as m,GlobalStyles as f,Button as g,Avatar as x,Checkbox as b,FormControlLabel as v,TextField as y,InputAdornment as S,FormHelperText as k,Stack as B,Tooltip as w,IconButton as C,Typography as T,Grid as I,Alert as A,Switch as z,ToggleButton as R,ToggleButtonGroup as E,Radio as P,FormControl as O,FormLabel as L,RadioGroup as M,Slider as W,Chip as D,Container as F,Tabs as N,Tab as H,Paper as V,Dialog as Q,DialogTitle as j,DialogContent as G,DialogContentText as U,DialogActions as X,Zoom as K,Grow as q,Fade as J,Slide as Y,AppBar as Z,Toolbar as $,List as _,ListItem as ee,ListItemButton as te,ListItemIcon as re,ListItemText as oe,Collapse as ne,Divider as ie,Drawer as ae,useTheme as le,useMediaQuery as se}from"@mui/material";import{jsx as de,jsxs as ce,Fragment as ue}from"react/jsx-runtime";import pe from"@mui/icons-material/ContentCopy";import he from"@mui/icons-material/Check";import me from"@mui/icons-material/Person";import fe from"@mui/icons-material/Remove";import ge from"@mui/icons-material/CheckCircleOutline";import xe from"@mui/icons-material/WarningAmber";import be from"@mui/icons-material/ErrorOutline";import ve from"@mui/icons-material/InfoOutlined";import ye from"react-dom";import Se from"@mui/icons-material/ExpandMore";import ke from"@mui/icons-material/Favorite";import Be from"@mui/icons-material/Home";import we from"@mui/icons-material/Delete";import Ce from"@mui/icons-material/Settings";import Te from"@mui/icons-material/Search";import Ie from"@mui/icons-material/Star";import Ae from"@mui/icons-material/Notifications";import ze from"@mui/icons-material/Visibility";import Re from"@mui/icons-material/ShoppingCart";import Ee from"@mui/icons-material/Lock";import Pe from"@mui/icons-material/Info";import Oe from"@mui/icons-material/HomeOutlined";import Le from"@mui/icons-material/FavoriteBorderOutlined";import Me from"@mui/icons-material/DeleteOutlined";import We from"@mui/icons-material/SettingsOutlined";import De from"@mui/icons-material/StarOutline";import Fe from"@mui/icons-material/PersonOutlined";import Ne from"@mui/icons-material/NotificationsOutlined";import He from"@mui/icons-material/VisibilityOutlined";import Ve from"@mui/icons-material/ShoppingCartOutlined";import Qe from"@mui/icons-material/LockOutlined";import je from"@mui/icons-material/HomeRounded";import Ge from"@mui/icons-material/FavoriteRounded";import Ue from"@mui/icons-material/DeleteRounded";import Xe from"@mui/icons-material/SettingsRounded";import Ke from"@mui/icons-material/SearchRounded";import qe from"@mui/icons-material/StarRounded";import Je from"@mui/icons-material/PersonRounded";import Ye from"@mui/icons-material/NotificationsRounded";import Ze from"@mui/icons-material/VisibilityRounded";import $e from"@mui/icons-material/ShoppingCartRounded";import _e from"@mui/icons-material/LockRounded";import et from"@mui/icons-material/InfoRounded";import tt from"@mui/icons-material/HomeTwoTone";import rt from"@mui/icons-material/FavoriteTwoTone";import ot from"@mui/icons-material/DeleteTwoTone";import nt from"@mui/icons-material/SettingsTwoTone";import it from"@mui/icons-material/SearchTwoTone";import at from"@mui/icons-material/StarTwoTone";import lt from"@mui/icons-material/PersonTwoTone";import st from"@mui/icons-material/NotificationsTwoTone";import dt from"@mui/icons-material/VisibilityTwoTone";import ct from"@mui/icons-material/ShoppingCartTwoTone";import ut from"@mui/icons-material/LockTwoTone";import pt from"@mui/icons-material/InfoTwoTone";import ht from"@mui/icons-material/HomeSharp";import mt from"@mui/icons-material/FavoriteSharp";import ft from"@mui/icons-material/DeleteSharp";import gt from"@mui/icons-material/SettingsSharp";import xt from"@mui/icons-material/SearchSharp";import bt from"@mui/icons-material/StarSharp";import vt from"@mui/icons-material/PersonSharp";import yt from"@mui/icons-material/NotificationsSharp";import St from"@mui/icons-material/VisibilitySharp";import kt from"@mui/icons-material/ShoppingCartSharp";import Bt from"@mui/icons-material/LockSharp";import wt from"@mui/icons-material/InfoSharp";import Ct from"@mui/icons-material/Code";import Tt from"@mui/icons-material/GridView";import It from"@mui/icons-material/Computer";import At from"@mui/icons-material/Add";import*as zt from"@mui/icons-material";import{Settings as Rt,Close as Et}from"@mui/icons-material";import Pt from"@mui/icons-material/Menu";import Ot from"@mui/icons-material/Close";import Lt from"@mui/icons-material/FormatBold";import Mt from"@mui/icons-material/FormatItalic";import Wt from"@mui/icons-material/FormatUnderlined";import Dt from"@mui/icons-material/FormatAlignLeft";import Ft from"@mui/icons-material/FormatAlignCenter";import Nt from"@mui/icons-material/KeyboardArrowUp";import Ht from"@mui/icons-material/KeyboardArrowDown";import"@mui/icons-material/FormatAlignRight";import"@mui/icons-material/ViewList";import"@mui/icons-material/ViewModule";import Vt from"@mui/material/CircularProgress";import"@mui/icons-material/StarBorder";import Qt from"@mui/icons-material/StarHalf";import jt from"@mui/icons-material/Cancel";import Gt from"@mui/icons-material/ExpandLess";import Ut from"@mui/icons-material/Image";import Xt from"@mui/icons-material/ChevronLeft";import Kt from"@mui/icons-material/ChevronRight";import qt from"@mui/icons-material/FirstPage";import Jt from"@mui/icons-material/LastPage";import Yt from"@mui/icons-material/Explore";import Zt from"@mui/icons-material/Radio";import $t from"@mui/icons-material/LibraryMusic";import _t from"@mui/icons-material/Bookmark";import er from"@mui/icons-material/Edit";import tr from"@mui/icons-material/Share";import"@mui/icons-material/FavoriteBorder";import"@mui/icons-material/DeleteOutline";import{useThemeProps as rr,styled as or,alpha as nr}from"@mui/material/styles";import ir from"@mui/material/Collapse";import ar from"@mui/material/Checkbox";import{createSvgIcon as lr}from"@mui/material/utils";import sr from"@mui/icons-material/CloudUpload";import dr from"@mui/icons-material/Mail";import"@mui/icons-material/Inbox";import cr from"@mui/icons-material/Folder";import"@mui/icons-material/MoreVert";import"@mui/icons-material/ImageOutlined";import ur from"@mui/icons-material/ArrowBack";import pr from"@mui/icons-material/AccountCircle";import hr from"@mui/icons-material/Twitter";import mr from"@mui/icons-material/GitHub";import fr from"@mui/icons-material/LinkedIn";import gr from"@mui/icons-material/Help";import xr from"@mui/icons-material/FolderOpen";import br from"@mui/icons-material/InsertDriveFile";import vr from"@mui/icons-material/PictureAsPdf";import yr from"@mui/icons-material/VideoLibrary";const Sr=e=>`var(--${e}-Font-Family)`,kr="var(--Font-Family-Display, var(--Font-Family-Header, var(--Header-Font-Family)))",Br="var(--Font-Family-Eyebrow, var(--Decorative-Font-Family))",wr=(e,t)=>`var(--${e}-Font-Family, ${t})`,Cr="var(--Font-Variation-Header, normal)",Tr=(e,t)=>`var(--Eyebrow-${e}-${t}, var(--Overline-${e}-${t}))`,Ir=e=>Tr(e,"Font-Size"),Ar=e=>Tr(e,"Font-Weight"),zr=e=>Tr(e,"Line-Height"),Rr=e=>Tr(e,"Letter-Spacing"),Er=e=>`var(--${e}-Font-Size)`,Pr=e=>`var(--${e}-Font-Weight)`,Or=e=>`calc(var(--${e}-Line-Height) * var(--Cognitive-Multiplier, 1))`,Lr=e=>`var(--${e}-Line-Height)`,Mr=e=>`var(--${e}-Letter-Spacing)`,Wr={"display-large":{component:"h1",fontFamily:wr("Display-Large",kr),fontSize:Er("Display-Large"),fontWeight:Pr("Display-Large"),lineHeight:Or("Display-Large"),letterSpacing:Mr("Display-Large"),defaultColor:"header",defaultWidth:"fill"},"display-medium":{component:"h1",fontFamily:wr("Display-Medium",kr),fontSize:Er("Display-Medium"),fontWeight:Pr("Display-Medium"),lineHeight:Or("Display-Medium"),letterSpacing:Mr("Display-Medium"),defaultColor:"header",defaultWidth:"fill"},"display-small":{component:"h2",fontFamily:wr("Display-Small",kr),fontSize:Er("Display-Small"),fontWeight:Pr("Display-Small"),lineHeight:Or("Display-Small"),letterSpacing:Mr("Display-Small"),defaultColor:"header",defaultWidth:"fill"},h1:{component:"h1",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H1"),fontWeight:Pr("H1"),lineHeight:Or("H1"),letterSpacing:Mr("H1"),defaultColor:"header",defaultWidth:"fill"},h2:{component:"h2",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H2"),fontWeight:Pr("H2"),lineHeight:Or("H2"),letterSpacing:Mr("H2"),defaultColor:"header",defaultWidth:"fill"},h3:{component:"h3",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H3"),fontWeight:Pr("H3"),lineHeight:Or("H3"),letterSpacing:Mr("H3"),defaultColor:"header",defaultWidth:"fill"},h4:{component:"h4",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H4"),fontWeight:Pr("H4"),lineHeight:Or("H4"),letterSpacing:Mr("H4"),defaultColor:"standard",defaultWidth:"fill"},h5:{component:"h5",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H5"),fontWeight:Pr("H5"),lineHeight:Or("H5"),letterSpacing:Mr("H5"),defaultColor:"standard",defaultWidth:"fill"},h6:{component:"h6",fontFamily:Sr("Header"),fontVariationSettings:Cr,fontSize:Er("H6"),fontWeight:Pr("H6"),lineHeight:Or("H6"),letterSpacing:Mr("H6"),defaultColor:"standard",defaultWidth:"fill"},"subtitle-large":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Subtitle-Large"),fontWeight:Pr("Subtitle-Large"),lineHeight:Or("Subtitle-Large"),letterSpacing:Mr("Subtitle-Large"),defaultColor:"header",defaultWidth:"fill"},subtitle:{component:"p",fontFamily:Sr("Body"),fontSize:Er("Subtitle-Medium"),fontWeight:Pr("Subtitle-Medium"),lineHeight:Or("Subtitle-Medium"),letterSpacing:Mr("Subtitle-Medium"),defaultColor:"header",defaultWidth:"fill"},"subtitle-small":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Subtitle-Small"),fontWeight:Pr("Subtitle-Small"),lineHeight:Or("Subtitle-Small"),letterSpacing:Mr("Subtitle-Small"),defaultColor:"header",defaultWidth:"fill"},"body-small":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Small"),fontWeight:Pr("Body-Small"),lineHeight:Or("Body-Small"),letterSpacing:Mr("Body-Small"),defaultColor:"standard",defaultWidth:"fill"},"body-small-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Small"),fontWeight:Pr("Body-Small-Semibold"),lineHeight:Or("Body-Small"),letterSpacing:Mr("Body-Small"),defaultColor:"standard",defaultWidth:"fill"},body:{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-medium":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium-Semibold"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-medium-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Medium"),fontWeight:Pr("Body-Medium-Semibold"),lineHeight:Or("Body-Medium"),letterSpacing:Mr("Body-Medium"),defaultColor:"standard",defaultWidth:"fill"},"body-large":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Large"),fontWeight:Pr("Body-Large"),lineHeight:Or("Body-Large"),letterSpacing:Mr("Body-Large"),defaultColor:"standard",defaultWidth:"fill"},"body-large-semibold":{component:"p",fontFamily:Sr("Body"),fontSize:Er("Body-Large"),fontWeight:Pr("Body-Large-Semibold"),lineHeight:Or("Body-Large"),letterSpacing:Mr("Body-Large"),defaultColor:"standard",defaultWidth:"fill"},caption:{component:"span",fontFamily:Sr("Body"),fontSize:Er("Caption"),fontWeight:Pr("Caption"),lineHeight:Or("Caption"),letterSpacing:Mr("Caption"),defaultColor:"quiet",defaultWidth:"hug"},"caption-bold":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Caption"),fontWeight:Pr("Caption-Bold"),lineHeight:Or("Caption"),letterSpacing:Mr("Caption"),defaultColor:"quiet",defaultWidth:"hug"},"label-extra-small":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-ExtraSmall"),fontWeight:Pr("Label-ExtraSmall"),lineHeight:Lr("Label-ExtraSmall"),letterSpacing:Mr("Label-ExtraSmall"),defaultColor:"standard",defaultWidth:"hug"},"label-small":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Small"),fontWeight:Pr("Label-Small"),lineHeight:Lr("Label-Small"),letterSpacing:Mr("Label-Small"),defaultColor:"standard",defaultWidth:"hug"},label:{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Medium"),fontWeight:Pr("Label-Medium"),lineHeight:Lr("Label-Medium"),letterSpacing:Mr("Label-Medium"),defaultColor:"standard",defaultWidth:"hug"},"label-medium":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Medium"),fontWeight:Pr("Label-Medium"),lineHeight:Lr("Label-Medium"),letterSpacing:Mr("Label-Medium"),defaultColor:"standard",defaultWidth:"hug"},"label-large":{component:"label",fontFamily:Sr("Body"),fontSize:Er("Label-Large"),fontWeight:Pr("Label-Large"),lineHeight:Lr("Label-Large"),letterSpacing:Mr("Label-Large"),defaultColor:"standard",defaultWidth:"hug"},legal:{component:"span",fontFamily:Sr("Body"),fontSize:Er("Legal"),fontWeight:Pr("Legal"),lineHeight:Or("Legal"),letterSpacing:Mr("Legal"),defaultColor:"quiet",defaultWidth:"hug"},"legal-semibold":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Legal"),fontWeight:Pr("Legal-Semibold"),lineHeight:Or("Legal"),letterSpacing:Mr("Legal"),defaultColor:"quiet",defaultWidth:"hug"},"eyebrow-small":{component:"span",fontFamily:Br,fontSize:Ir("Small"),fontWeight:Ar("Small"),lineHeight:zr("Small"),letterSpacing:Rr("Small"),textTransform:"uppercase",defaultColor:"eyebrow",defaultWidth:"hug"},eyebrow:{component:"span",fontFamily:Br,fontSize:Ir("Medium"),fontWeight:Ar("Medium"),lineHeight:zr("Medium"),letterSpacing:Rr("Medium"),textTransform:"uppercase",defaultColor:"eyebrow",defaultWidth:"hug"},"eyebrow-large":{component:"span",fontFamily:Br,fontSize:Ir("Large"),fontWeight:Ar("Large"),lineHeight:zr("Large"),letterSpacing:Rr("Large"),textTransform:"uppercase",defaultColor:"eyebrow",defaultWidth:"hug"},"number-small":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Number-Small"),fontWeight:Pr("Number-Small"),lineHeight:Lr("Number-Small"),letterSpacing:Mr("Number-Small"),fontVariantNumeric:"tabular-nums",defaultColor:"standard",defaultWidth:"hug"},"number-medium":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Number-Medium"),fontWeight:Pr("Number-Medium"),lineHeight:Lr("Number-Medium"),letterSpacing:Mr("Number-Medium"),fontVariantNumeric:"tabular-nums",defaultColor:"standard",defaultWidth:"hug"},"number-large":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Number-Large"),fontWeight:Pr("Number-Large"),lineHeight:Lr("Number-Large"),letterSpacing:Mr("Number-Large"),fontVariantNumeric:"tabular-nums",defaultColor:"standard",defaultWidth:"hug"},"button-extra-small":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Button-ExtraSmall"),fontWeight:Pr("Button-ExtraSmall"),lineHeight:Lr("Button-ExtraSmall"),letterSpacing:Mr("Button-ExtraSmall"),defaultColor:"standard",defaultWidth:"hug"},"button-small":{component:"span",fontFamily:Sr("Body"),fontSize:Er("Button-Small"),fontWeight:Pr("Button-Small"),lineHeight:Lr("Button-Small"),letterSpacing:Mr("Button-Small"),defaultColor:"standard",defaultWidth:"hug"},button:{component:"span",fontFamily:Sr("Body"),fontSize:"var(--Button-Standard-Font-Size, var(--Button-Font-Size))",fontWeight:"var(--Button-Standard-Font-Weight, var(--Body-Font-Weight))",lineHeight:Lr("Button-Standard"),letterSpacing:Mr("Button-Standard"),defaultColor:"standard",defaultWidth:"hug"},"button-standard":{component:"span",fontFamily:Sr("Body"),fontSize:"var(--Button-Standard-Font-Size, var(--Button-Font-Size))",fontWeight:"var(--Button-Standard-Font-Weight, var(--Body-Font-Weight))",lineHeight:Lr("Button-Standard"),letterSpacing:Mr("Button-Standard"),defaultColor:"standard",defaultWidth:"hug"}},Dr={"overline-small":"eyebrow-small",overline:"eyebrow","overline-medium":"eyebrow","overline-large":"eyebrow-large","eyebrow-medium":"eyebrow","body-small-bold":"body-small-semibold","body-bold":"body-semibold","body-medium-bold":"body-semibold","body-large-bold":"body-large-semibold","subtitle-medium":"subtitle"},Fr={"eyebrow-small":"overline-small",eyebrow:"overline","eyebrow-large":"overline-large"},Nr={header:"var(--Header)",default:"var(--Header)",primary:"var(--Header-Primary)",secondary:"var(--Header-Secondary)",tertiary:"var(--Header-Tertiary)",neutral:"var(--Header-Neutral)",info:"var(--Header-Info)",success:"var(--Header-Success)",warning:"var(--Header-Warning)",error:"var(--Header-Error)"},Hr={standard:"var(--Text)",default:"var(--Text)",quiet:"var(--Quiet)",eyebrow:"var(--Eyebrow, var(--Quiet))",primary:"var(--Text-Primary)",secondary:"var(--Text-Secondary)",tertiary:"var(--Text-Tertiary)",neutral:"var(--Text-Neutral)",info:"var(--Text-Info)",success:"var(--Text-Success)",warning:"var(--Text-Warning)",error:"var(--Text-Error)"},Vr=new Set(["h1","h2","h3","h4","h5","h6","display-large","display-medium","display-small","subtitle-large","subtitle","subtitle-small"]);function Qr({children:e,textStyle:t="body",color:r,width:o,component:n,noWrap:i=!1,gutterBottom:a=!1,className:l="",sx:s={},...d}){const c=Dr[t]||t,u=Wr[c]||Wr.body,p="string"==typeof u.fontSize?u.fontSize.match(/--([\w-]+)-Font-Size/):null,m=p?p[1]:null,f=m?"var(--"+m+"-Text-Decoration, "+(u.textDecoration||"none")+")":u.textDecoration||"none",g=m?"var(--"+m+"-Text-Transform, "+(u.textTransform||"none")+")":u.textTransform||"none",x=function(e,t,r){const o=Vr.has(e);return(o?Nr:Hr)[t||r]||(o?Nr.header:Hr.standard)}(c,r,u.defaultColor),b=o||u.defaultWidth,v="fill"===b,y=n||u.component,S=r||u.defaultColor;return de(h,{component:y,className:"typography typography-"+c+(Fr[c]?" typography-"+Fr[c]:"")+" typography-color-"+S+" typography-width-"+b+" "+l,sx:{fontFamily:u.fontFamily,fontVariationSettings:u.fontVariationSettings||"normal",fontSize:u.fontSize,fontWeight:u.fontWeight,lineHeight:u.lineHeight,letterSpacing:u.letterSpacing,textDecoration:f,textTransform:g,fontVariantNumeric:u.fontVariantNumeric||"normal",color:x,display:v?"block":"inline",width:v?"100%":"auto",margin:0,marginBottom:a?"0.5em":0,padding:0,...i&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},...s},...d,children:e})}const jr={"@supports (text-box-edge: cap alphabetic)":{textBoxTrim:"trim-both",textBoxEdge:"cap alphabetic",paddingTop:0,paddingBottom:0}},Gr=e=>de(Qr,{textStyle:"display-large",...e}),Ur=e=>de(Qr,{textStyle:"display-medium",...e}),Xr=e=>de(Qr,{textStyle:"display-small",...e}),Kr=e=>de(Qr,{textStyle:"h1",...e}),qr=e=>de(Qr,{textStyle:"h2",...e}),Jr=e=>de(Qr,{textStyle:"h3",...e}),Yr=e=>de(Qr,{textStyle:"h4",...e}),Zr=e=>de(Qr,{textStyle:"h5",...e}),$r=e=>de(Qr,{textStyle:"h6",...e}),_r=Yr,eo=e=>de(Qr,{textStyle:"subtitle-large",...e}),to=e=>de(Qr,{textStyle:"subtitle",...e}),ro=e=>de(Qr,{textStyle:"subtitle-small",...e}),oo=e=>de(Qr,{textStyle:"subtitle",...e}),no=eo,io=to,ao=e=>de(Qr,{textStyle:"body-small",...e}),lo=e=>de(Qr,{textStyle:"body-small-semibold",...e}),so=e=>de(Qr,{textStyle:"body-small-bold",...e}),co=e=>de(Qr,{textStyle:"body",...e}),uo=e=>de(Qr,{textStyle:"body-semibold",...e}),po=e=>de(Qr,{textStyle:"body-bold",...e}),ho=co,mo=ao,fo=e=>de(Qr,{textStyle:"body-large",...e}),go=e=>de(Qr,{textStyle:"body-large-semibold",...e}),xo=e=>de(Qr,{textStyle:"body-large-bold",...e}),bo=e=>de(Qr,{textStyle:"caption",...e}),vo=e=>de(Qr,{textStyle:"caption-bold",...e}),yo=e=>de(Qr,{textStyle:"label-extra-small",...e}),So=e=>de(Qr,{textStyle:"label-small",...e}),ko=e=>de(Qr,{textStyle:"label",...e}),Bo=e=>de(Qr,{textStyle:"label-large",...e}),wo=e=>de(Qr,{textStyle:"legal",...e}),Co=e=>de(Qr,{textStyle:"legal-semibold",...e}),To=e=>de(Qr,{textStyle:"eyebrow-small",...e}),Io=e=>de(Qr,{textStyle:"eyebrow",...e}),Ao=e=>de(Qr,{textStyle:"eyebrow",...e}),zo=e=>de(Qr,{textStyle:"eyebrow-large",...e}),Ro=To,Eo=Io,Po=Ao,Oo=zo,Lo=e=>de(Qr,{textStyle:"number-small",...e}),Mo=e=>de(Qr,{textStyle:"number-medium",...e}),Wo=e=>de(Qr,{textStyle:"number-large",...e}),Do=e=>de(Qr,{textStyle:"button-extra-small",...e}),Fo=e=>de(Qr,{textStyle:"button-small",...e}),No=e=>de(Qr,{textStyle:"button",...e}),Ho={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Vo={xs:"12px",small:"16px",medium:"24px",large:"32px"},Qo=Vo;function jo({children:e,color:t="default",size:r="medium",fontSize:o,disabled:n=!1,twoTone:i=!1,className:a="",sx:l={},"aria-label":s,...d}){const c=Ho[t]||"Default";return de(h,{component:"span",className:"icon icon-"+t+" icon-"+r+(n?" icon-disabled":"")+(i?" icon-twotone":"")+(a?" "+a:""),"aria-hidden":s?void 0:"true","aria-label":s||void 0,role:s?"img":void 0,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",fontSize:"custom"===r&&o?"number"==typeof o?o+"px":o:Qo[r]||Qo.medium,color:"default"===t?"inherit":"var(--Icons-"+c+")",opacity:n?.38:1,cursor:n?"not-allowed":"inherit",lineHeight:1,flexShrink:0,...i&&{"--twotone-variant":"var(--Icons-Variant-"+c+")"},"& .MuiSvgIcon-root":{fontSize:"inherit",color:"inherit"},...l},...d,children:e})}const Go="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAkACQAAD/4QCSRXhpZgAATU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUAAAABAAAARgEoAAMAAAABAAIAAIdpAAQAAAABAAAATgAAAAAAAACQAAAAAQAAAJAAAAABAAOShgAHAAAAEgAAAHigAgAEAAAAAQAAAKCgAwAEAAAAAQAAAKAAAAAAQVNDSUkAAABTY3JlZW5zaG90/+0AOFBob3Rvc2hvcCAzLjAAOEJJTQQEAAAAAAAAOEJJTQQlAAAAAAAQ1B2M2Y8AsgTpgAmY7PhCfv/iAihJQ0NfUFJPRklMRQABAQAAAhhhcHBsBAAAAG1udHJSR0IgWFlaIAfmAAEAAQAAAAAAAGFjc3BBUFBMAAAAAEFQUEwAAAAAAAAAAAAAAAAAAAAAAAD21gABAAAAANMtYXBwbAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACmRlc2MAAAD8AAAAMGNwcnQAAAEsAAAAUHd0cHQAAAF8AAAAFHJYWVoAAAGQAAAAFGdYWVoAAAGkAAAAFGJYWVoAAAG4AAAAFHJUUkMAAAHMAAAAIGNoYWQAAAHsAAAALGJUUkMAAAHMAAAAIGdUUkMAAAHMAAAAIG1sdWMAAAAAAAAAAQAAAAxlblVTAAAAFAAAABwARABpAHMAcABsAGEAeQAgAFAAM21sdWMAAAAAAAAAAQAAAAxlblVTAAAANAAAABwAQwBvAHAAeQByAGkAZwBoAHQAIABBAHAAcABsAGUAIABJAG4AYwAuACwAIAAyADAAMgAyWFlaIAAAAAAAAPbVAAEAAAAA0yxYWVogAAAAAAAAg98AAD2/////u1hZWiAAAAAAAABKvwAAsTcAAAq5WFlaIAAAAAAAACg4AAARCwAAyLlwYXJhAAAAAAADAAAAAmZmAADypwAADVkAABPQAAAKW3NmMzIAAAAAAAEMQgAABd7///MmAAAHkwAA/ZD///ui///9owAAA9wAAMBu/8AAEQgAoACgAwEiAAIRAQMRAf/EAB8AAAEFAQEBAQEBAAAAAAAAAAABAgMEBQYHCAkKC//EALUQAAIBAwMCBAMFBQQEAAABfQECAwAEEQUSITFBBhNRYQcicRQygZGhCCNCscEVUtHwJDNicoIJChYXGBkaJSYnKCkqNDU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6g4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2drh4uPk5ebn6Onq8fLz9PX29/j5+v/EAB8BAAMBAQEBAQEBAQEAAAAAAAABAgMEBQYHCAkKC//EALURAAIBAgQEAwQHBQQEAAECdwABAgMRBAUhMQYSQVEHYXETIjKBCBRCkaGxwQkjM1LwFWJy0QoWJDThJfEXGBkaJicoKSo1Njc4OTpDREVGR0hJSlNUVVZXWFlaY2RlZmdoaWpzdHV2d3h5eoKDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uLj5OXm5+jp6vLz9PX29/j5+v/bAEMAAgICAgICAwICAwQDAwMEBQQEBAQFBgUFBQUFBggGBgYGBgYICAgICAgICAkJCQkJCQsLCwsLDAwMDAwMDAwMDP/bAEMBAgICAwMDBQMDBQwIBwgMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDP/dAAQACv/aAAwDAQACEQMRAD8A8zt1v/D0/m2bbo85K9q664XRPGNl5N0iicc7W9R3FeO2vjF5FAmPB9eldRYvFfqJrWYJIOeDivntTvnRvqeleHfEupeA3EciBoYz8rgcjHr/AI/nXpdt+0p4sd1s7RozEw+V88/lXjlldedEbLVsOCMb+9XPCmk6f4S1yPWvs631uj+Z5bcjI54zU3a1izmlTVmpI+kbLxp8SdcjWVkuzHJ0ZIXCn6MRiultfD3i/UcPdgx57zSgfoMmufb9oZ9WgGl6dAqsw27OWZMf7IFT2XiDxJfKWbcPYkLn6dTXZSrJ/E2zza9Fp+6kj1bRPhjZXKeZr2sLCv8AcgAz/wB9Of6VrX/hL4M6NC39pOb9scieZnBx/sx7R+lebaXYatqlwEupRbx/xMSXP4ZIFehR+C/BUKBtRup7p2/g8zaCT22xgH9a7ou6uor5nJ5XPzw+LkHgGy+INld+AbH7MfPUXMSBlikywwVDd+xxX1HDe3Z8Norx2yIEzsz85z36Yr1SP4cfC6fVTqV1o0U7w4wsrLshDHZmUMeCfU89MDvU+peGPCWsWlxb+H4bG3iRWZhBOu2LaM7pmOQFC5/iABJr57MI1ZS5qTW/Q+lwFCPskqi6dT8o5LC78RfEqG32kRR3h83A6KG5Az7V+pfhHwl8MptKhgvIGhlVAN6yOjdO+Dj9K8W8KfDHTbXUrnWrh4BDCXnnkYjy1UOFwjcjAzksT9AOa9vtbLSJYhJHIsaFFZZEYeWQRwQR8pHoe9d2Fq3Wxw46hK99TtU+Evgu7XOm6tcRE9AWSQfqAf1rOufghqGC+maxBJ6eZGyH81J/lWF9ju4Rvs5xKuNwPXP5Uh1vX9PHyPIO3yOcV1upC2sTg9mZWqfDv4oaKrSWcomVeht7n/2V8Vwdj41+IXhzW44fEMV+0LkRwxNHnfIT03DjHvXp6+OvEtveRRyxzyLJwocDaD6sewFT+NfEVjDp/wBvuJ0a4WPk8dT2UfpXn1nztqDOyjTUFcf4h8TTHS/tWpzLG+zJTPyx8dPc+9fGHjTxve6o8lnp8jLbkkE92/wFWPFnja/1tjBJJ5cA/hHf3NeVahrVhZRNucZqU7LlR1KnzS5mMimitW3yH5qyNb8XW9vHtMn4Dk1w2qeKbaRyfOWJM9erH6CtXw5oN34iuo5Rp8ws2/5bSDG4+oBo6HZGkf/QwfiB+y3N4f8AEotfDV5P/Z8oJ8qRt+wjnhuuK8A1zS9b8AagYLhZvJzgSlG2ZHbdiv0u1v4m6Xd66BfW0tqckbZlIPT3roptF8MeLdKMN1bwvFOhIDBf0zXz9RLmbiz2I6o/MDT/ABdJcSJHc7lJ6HoDXsGhXk6qG3iSNux6V698RfgRZ3enqnhqNIZwBtYLnmvDh8OPiV4YuI4TD9pcuFAUAJ1xli3AHqTwO9Q3Zakzpp6I9M0ZLaC5+2aZARck44GdxPavYvDGqanqF2LGKDFwcfIFbHPfgGuG8AeDr7UZvMvNV0/yIZsTeTMZFjOSrI7KByCOzZz2HWvZF1/TtE8XQeFtE0+BnhgWSTU72VkTEoYL5UUfLuSrAAsT3GetEZq6S3OV4KUrtrQ9H0iPRZXuNPl1GKa7sYhPexwuZBARx5biLJDMx4GCeD71Q8MePvhh4i1K+tPDF6up3mmukUscKldsj7s4MhwdmDuP8ODmvz5+Ofjl/BvhrWdQ8KreafDreurCL1hMvmi2iLsVWQEBEclgqFgN3JB68d+zxJ8RNM8EeLvjHoTxARLKWminiVrydMzXBMZJEQXhdyozN0A446FJyjdM3hhIRkotH1j8fPF9kllq3g7whdBNUa3F5LOitJMktuXMUaPFl8bo2BJCjkEZya+dvhD8d7Pw14WiPjOS5thcM9qr2saTC4s5A8hZo2ILKkxkTgNgHuOvwp45+K/izxlq11rJ1W4im1SFxcMj7HXLncCqYxu2gEdx164Ot4s+IWh6p4I0e006eddSit4Ld5HVVmR7bAXBA5AYZUZzySevESwknbm6s3+tU4+7Doj7yv8A44aP4Ztv7XmS81WHTIv7LgW7uWSJDcPHIjFY2wzrGd0e8FMYBAJOOf8AEX7SenLYqLIRyWlhukkmIKzF5CGffGrbMYxhVJ6N2Ffnd4l8U3upaZJfapYPOLpk2XbthlKJ8v3RtAOe/PHUViXOvW1xp9o81x/pLoBNHsAiZFwFwoYkt0y20Z549dYYO0VF9zKpilJvTofo5pP7Sniy3TzNA2/2fIrNG/zMmBncNjA4Kngj8q9Z8B/tXQ3Rlg8Y+XmLHliFfLZnOQMh+AAQMkkAA5r8tfDfj3xB4dtTYaPIt7aEeY8arux3JAwD7EH0zmvR9a16x8XaLBFusE1WdoRO4QQzIgBzGuGAfsWcjIOBiieGlF6PQwUqc1qtT9d5fihpniLRRf6Msm6ZcASrg7lyCVI4Zc9COCOa8W1vVNQuyZdSdio6KTwK8K8EeKINAuNGsdNuXu7JbZ7a6gZyNlyER1YK3IO3J+XII7nFe66T4d1LxrK0sgMVucgHPII6+2PT2riUteXqU8PZ3Wx4zruvNJO1raQMcdTXKaVoOseKpLj7NalYoDh3kJJJPYV7zf8AgCPwnqMk05MkbDJZ+e3vXQ+Ar/Slgu7S3iJllkO3auR0PU1UV71mdEYKKufPPhz4bWk3iyyS+TcqkkoeQDmvvPUtA03SPD0DWsCJsTOAAD2r540T4d/EHW/HTGxT7PEWLJJt3fKT1xx/OvsvTPg/r0NvFca7eyXRC4KsQF/BRx+ta0acnfqTVrw0sf/R/Q3XfAeh61q8t1cWqM4zhiorirj4YvcPs02RoCgIRlzxXQzfEq1GoPGtvJyxHT+dddp3i7SoY1kkY72GTx09q82UISmzqi/d0PLn8J6/oNuqiRrx+24Z5/SvGfHeg+NZZXutZkkXS4Ip5VihkKyzufLJWQZXKqA+1RuP8q+yZfEVjdRl4sbirbN4IBIHH4V+dPxC+PE3/CRnwL8SC0D6deGOa7jgQQRGdd9uQN6yOAPuvsKk8MRXFjIx5LRuztwnNz7nKeLrzwjb2unQ6dqUumhJDqT6XZ3geSRIPmbzkuH2gyou3mPIHJU8g+M6P+0/4U0vxLcy6/oLMiGZkmQlbn7QS+RNvUhdhIjXyyAMkqQDXjVtHZa54k13xD4bsbmSSyYA3V1dC4uGmuDlmSzUIArqGUBWzlslj2+U9aW91XX7l55tl0JHEyMNpVBgAfgAAR1GMHnNTRwcG3FvU3qYycEpJHXeJ/iNqHijxTd3N8815pMt27w2k1w5jXzeApDPkjKjPPRRwM10ui/ErVNH8LyaPYzR2q299PcC1jbaGSVVyRnO3HIG3AINeD30yTXEv2oKs8TLtZMDKYIzxxnoSeppYLy08pVXAnAIQlSGZ2IyWY54AHAFet7OPLyW0PL9rPn529SzqkhglW6kO6Vi5bnlQcbVPJxgHIqCJ7htKMyyDBmO1CcnJ7gHgdvrVS6a4mm8hgGZgMkYJLeue+K7mfwwdO0uy1OaRJobmMMsUfytvZcnPGDt785HFVKrGKSfUzhRnNtxWxzlzr+oDTY9HS9lNqHVli3YCyAfewee5x+NczNEVl8xxtU9McfMOuB+NdTqWmtbi4tROsqQlcMY9hLNzt3dcj361z8jGaw3kFmQg5649eauEotXXUiaknyy6Fq01CS3xHbM2+UOH2k5KsMEfjXX6Fd3NhItxbgrcJkiUrvYLjJ2qxIyM4rzeKeaNy8R2kgKSOOK6jT2t5I+J/Ll+VlUA8PkYG4jGT+X0onEIaM+i/D3j6/XTLg5+ZrmO5WSUok0bx42vgEDAwM4zxnpzj78+D+s+N/HWmWl14VIsNNtIJklZCZpJriTJ+ZSCBswOBk7elfl3Zx2flpOsuJQC8kbIfmXBGM5/pivsn9nL4v3Xw+s5rW7kZ7e9bzPJ2hRvjG3b84G3C5JYHBXpzXlYmlFe8ejSqSasj9ErjwPqVzOq65+9Vo0DMeAWwM/L2r0DwJ8NdD0uOa6SBNzv1I7e1cL4b+JD+LdCW+UwTbxmOa1LNEY/wCEksASfU9Dxjiu+8N6l4imjkgEJCITlj0Yn0q6MYXuctST2Z6d4YXS7DVtoCq2MD869a1q+tU0/cGXha+SrHw9451HxGWs5Fjjbnc2fl59O9exXHg7xULZft995mRjaBgV1UpPlasZyldn/9L9DbTRdPkeSR4lDFj2rf0Dw/p5kZ3jBGT1ryOTxNrc8/8AoMGFzyT2Feg6LrOs3VssUMezAIY45zjk157cednRFpxR0t/o1iLrjai898fLjoPevy9/a3+IujW+vTWNvpdtNd6NLHGPNs4Z5PKZM5888xttKsi7WwRz6V9k+OvGGoaMIb6YyzJE2x54ULrEHwhfAHQElQTxuPoCR+JXx18earca441LdI96Z7p7iRm8y6EhCRNMdzbmRI1U5OQR6dfOlL21TkjpY9KnFUo88jz++8YavFJqFzpTrY2FzgSxWsmzeY+InfnJYMMjgHNeIXl/LLeS3gXMjPl5GYkvnk5/HrWjot6bnV3M5zHsfCnkHPt9RmsfVpBBeSxRgbW7V6tOmo6HDVqOauU5ZvtNz5qIF3YyoHHFem+DvAN9411Yi1hZI2YhSQSobHTgdMkYxXmkUS3V/aWsB5kZIzj1Y81+pXwn8EeLItJtx4I03TxHbJ+8vdTYhHl4+WJFILBe5PGeleXnGNnQhGnS+KXV9EetkeAp15yqVvhj0W7OD8B/seXmqXEF94lVBb4CTRRbl3YxhlOAeec8fSvojxf+zNoeu6Na6bZQrbS6euIcLgEYwN2wqeOo/kc16b4e8W/GjQtRisfEOlaHqVgdqvJprtFIgx94BmbcfbA+tfQKyfbbKC/EXkl1JdD1UgZIzXyOIxFeU1OVW7XbZH2mGw2GUHCNKye91qz8yvEv7JM7WNvMwBS0Dm4lLHc67SVAGCWO4ADOMAnrXxv4y+Gl54MWO6XesBn2TAjIVTkAkZHGcfSv1v8AiH4m+KV9ObPwzJpuiaah2yXF6qyyOc9QGyoXHtnPevnPXfhJ4w8SRXWfGel6lPcK6m0MMaDBHJUopw3oTxmurBZjWpSi3WTj1Tv/AJHDj8toVozUaLT6NW/zPy+v7KOK5KQ8q3I9OvOK0rW3jEqzXEyCFCCEQ5Yn/PU103xQ8JzeDNch06RHhLJ8yyfeDA85wSCPQivO5G3Dev314/CvuKNaNaCqQejPz+vQlRqOnPdHcx6qq3wufJbyy7CJRzgtnhfck/SvU/DNxp2oajYW2q3Vwbj7THCq7gCF2lSitwByRnLAHkcV45eRWcmjW0qExyptYgZKyZwMZ9R1H5V654E1CBNYs9K1WGJdO1VVtbmPJkVPMO1ZgGy0bq2GJHbpWdZJxNaUmnqfqZ8ENZ17V/Ar2tutlLBpg+xMsEbJcrJEo8l3y5BRkGBtGPlr68+F1zef2RG+p4ErDO0nkZr8yfCeq3vwr0DzrxdU0rUbK6iglWS1cWN2pnKxRvcqCjeYu9UPUHoOtfpL4Wae8it7iWB7M3caskZbLIxXOxxgbWHcc1y0GlLUVdNarY998O6hZR6kVJXcQK9J1OeFrcEEcjNfN2jeFNXu9Y8+K5ZFxz9favRtV03XbC2yLozbR90jFd8JPl2MG9T/0/0LtNNWwh/fqvua6XSoorGwa8kKkHLBCcZFed3Wq6prw8mAeVGeDtH9a6fw/p1zJD5V3LnZ8oyewrgk7z0OiL0Pj34meJm0/wAVa1o99dCWbULYtZWnmGJAturTKDjHLpuADHnaSvSvyG+LemWtzb3t8bc29zPdNcRvseOKZJixY7JDhWBwAF4wM85Jr9zfH/wD8B614ztfHWtRE3dtt3ESMqP5Cv5fnKpAdEDNnPQZxxxX4rftR6jpHiTx5J/wht3JNpaSfZIhIrogKudzRhudm4nDNztGTXmYfDuFa99z1J11Oi48uyPnPSrTT4ra3YtItxI75P8ACwCHAAwD1Gc59iOa5zVopjqOH4LEAFuBnjua7bxVZNoVxHp9pew3z2DG2ae3O+GR4mwzxt3UnODxkc9CK47WLv7ZiaTaspP3UG0AdOnTrXsxbep5k0krGj4Nt/P8aaRFKOHu0GMDHX8q/Wu98GeNfESaRa6dqA0rQbZN06wny5ZTtx8rlXReefmRs+3Wvyj+HsAl8beH/LdTK95ENmTnJOMnsP51/Rj8PtBs20O386NXXy16+hFfJcQJvGUrdE99Vv2PsuGUvqlXm79NHt3Pz9+HPw5+KWmeKftup6098kNwv+rEpiNsAQ6Odg3OeNuCFUjpzx98adNqd54enjZCskY+Xd97kHA/Suu1G40nTX+yW6orMMYUDJ/xo0W3kurC7kKlUchACMEdQTXkVf3lXdX1vZWPoaMFTpW1tpa7bf4nwz8RPCviDxrb/ZopLmBbVpWY25YSFnTETqykEeWecY+bp615f4a+CHi23sre8k8Q3L6ta3huTc7bgFoyADCY5maMDqSwyxPGcV9sC5Tw5qU41RCsQPlmRgApOeOenI5Fei6fa6Pf27T2aIGZeWGOa4sPiKkaToKS+5HTicLTlVVdxbfq7fdc/E/9rXSLiz1LSL29O6ZjJC8g/i2jIP19a+QQWjYNjgg/Lmv0V/b3tI7ZtFCBQRcycA5GNpx/Svzul3SToQv+sVcKenNfc8PN/UYJ9Lr8WfnXEkUsfO3W35HbaS9rPo8sNw2FOSpZgAhzlRt69e4p1hcxRXSTwyMNx4DA/Lt6+uRXORYitpreRmEn3QM/KwBz0retbQXVlBPAXEtuWzwCu3r6j/8AVmvWaR5EW3Y+8PCnijWPH3wiuNJtlN1baJqVm95cSSsXt48s4LR7TiMYYB84DkE4FfqF8L/EV34i0q11/V7GSzmDOiRs25GRflSZcAZVhyrEZwa/Mn9hjxTeaX44n0drC1kstUj8i8uXbbMmFbywqkgMmR8/Bxkc84r9jPDtjpMFkbWyiihijyqRxKERR6Ko4A+lclOPvtGldvY67wp4isF1Aws65xXa6zeRzshjYbSOea8Ts/C8bag90jlcHscZ5roru21WxgM4cuiDgHriuqMnynM276n/1P05fw3eabpRv5IREoXds4BA+naquneIPD1vpJLMryuCztnkHsPbFc9498W+Pp/DUktroz28Ey4LyMA6of4tg/rWt8MtG0VPAtut8iST3iu8zOAWJLEdfYdK4HK87R7HXGOiPmz4rWfi74jeFb3Q/DOsNod1JIDFdEZRoslXhkGDlJFOGxX5hfFr9mHWfhZLp+p39/Nq+iwqZL0wRkSvIsW9hAzmRUVmzgMM4HTPNfq5r2v6To8lzHd4jihkbaCcZCnivkj9pHSvFXxKOkaL4V1JbffbzSCBLhViYeW0nmGWMOSxUbBGQevOOTXn1ZWXM5WOug/e5Ern443iWl9qBS0LRWylm8uRs4QcYyByegzgc1zWpoUcKRtAyPY46EGvWvih4Zg8DRado6zTnUpYxd6isiBGjknUMkWfvcJjOcZJJxzXlF2oa1hk37mOeCecegGM/nXp0ZqSUlsclZWbT3GaJqsuh61Ya1B9+xuYbhffynDY/HGK/oi8LfEO2h8F2uqWzb4ZbZJoSOjI67lOfoa/nKIPfvX6i/sifFex8U+CT8M9cmUanoan7KHPM9iTxjPUxE7SP7u014PE+GnOlHEU943T9H/k/wAz6ThXFwhWlQqbS1Xqv+B+R90+EtV1DWbh/Ed/CSWIaFDzsQ/Mu4ZwCeCRWZrfxU8SaTdTxXzh1ckxpBHtRAPu8gnJ9c/pXI2fgrS08Q6f4iup7qW2tmMN1YrdTR2lzE3AMkaMBvXPyuMEcZyOK9dTT/gBFEP7Q8Paktx50eUieWcYX5nIYS/dOec4PHFfLYbB89FONS3e/wDwx91LENT5nSlL/Ck/1v8AgePx+ONS1mznh1q9hlhmO9UuvKiZRznLZ5HpnmuO8NfEDW9K12PStNuU1HS597RyRkSeXtO3yy4OGXnIZfTGa9O8eWXw18Q+Hr/wx4X8Mw2lpqaSW8tzdYku5I3LZWL5mMe5W25zkD0xmuE1K18P+CtOW7kENhp+lWhBOAkcUMa849gBXJjMMqdnGXNI3VSSV5x5F2dr/NbL77+h8N/tseIbrWtb8PWUyhJZUmuCnopYRr/I18XSRus0eBsKIjADqSRkfp1ruvit8Qbv4neP7zxNGpjtgRb2ERH+rtos7Mj1bJZvc1wSSKQ2QAy4IY+nXGK/SMsw0sPhadKe+79W7n5Lm+KjiMXUqx26eiVi0sr3Mwyg3RbmZgOcgd+36V7j8MtI8NeKZ7vTvFkxt5JLQm2mgBEjTj/VJhSAQxOCANxPTpXielRpLI8pJyPvLycqRyT7Z4/GvX/DOnWuq3linhmSaXVrYxMlvHG6tJeNKuI0HXbGoJaRsDnr0z0V37rRx0d7n1z+zf8ADr4geGfG0euTQPbQC8NtLDcRiSWKzKmXewJz8+1cMPuk5OeRX6l+G/EkSM9sPm2knNec/DjTrz4hxaLrDWqWEraFHFdGSZGmSaCU/u1jU/KpLEhm6kAZ5ruLb4e+L9DmuLyW0+02Zdm8xOGC+6+1cNKc2+YVVxb16HpWheJIbu/+zq2cHkV6vfywSWYUY5FfCl/4huvDWsm5hyV3ZI/GvY9F+KUOqw+VIcFFGc11wrx+FmfLJavY/9X9afiJq+nWPh27jbaSYWVQfUivheL4xWnhOx+y3c+1hkAZ6Z9KpfFD4u/6PJH55nkYcKDxXxlewah4pvmubtyATwOwrza9RJprc6YSctFsek+M/G8Xi+7kWFyImY8g9a1vBlwbeS3S5mkn+zktalySIHYBHZQeAWXgk9v15rQfB8KbQx4r2jRPD1lCF6ZGK4pU/aO7LVT2atFn5v8Ax7+FOo3/AMYdcnt7Wa7sI7Q6zdT3JEcRSIKLkxS5wyCVgvHzgHgHivlDxjZWMOraja6YIDaxTtJCIHZkjjb59gZxuO37ue+K/bL4veAl1/QpLTRdFW+OpSxrdSSSF3jKMWWSSJE3Tx7ifMQYbBBByAR8RXX7DfxBn1u3ksrm3bSpLgGRLjKzeU0mSPlU4bbjIdsjpu9OmhNr4h1KkWtD885EYwxRtxgEjPX5uRWj4X1jVvDfiTTda0Sd7W+tbhHikQ4I5wVI7qwyCDwQcGvs34v/ALLXi7wZoM/ia+RYYBqMFlBa2yCbebhtvmKV5VBtA+fozKuTya+ufhj+x/8AB/4W+FYPFfxTuFvPF8+mvPDp19PGojuHRiqxWo+ZnXIBJLAEGt5VlyO66MyjpOPI9bqx638O9ZtvFujRNc7Y7low0sR4BBHJUHt/k1T1z4aTPcmWHWJLeNjkRg5x9MnNcb4fsTpsaLbyFTGF27TgjHpV3XLnxC4LQ3bOuM5PUe1fltaskmtmfs2FnOm7xbOs0DwlYaMjXlxePcSjd88zD5dvoOgHevi/9qvxbc674YvdH0xythEu5mU489kcEn/cHb1PNezXF3rV2sltcXDurnDKMgHHX/JrzLx54Vs9X0uW2uukg25B6A8VWAxcYV4SlrZpmOZ0Z1qNTXVpo/L+3cI+WU9OoOKt+V5is8YOwYGeTyegzivpPwh8H/DSeNrnw74lvmt5jFv06S5hH2BpHbEf2qRXDBc8HC45yTivorw7+xh408SeOdOt9W8mHwfFIWu59P8ALgDbf3hECb5TIjMTGkjMTjkYGBX6jHERqRVSOz2fc/H61P2U3TqaNbo+H/Cuh65qMsj6Fbbj5MkU2SMtlGZgEOM/KMjg4xmvo74I/Bjxlr/hu/8AiV4Pkn0z+xbm3S4luIWZXilbEk9tMuQPLIIlVlZVX5icZx7N8KfBQ8e/tNatJp+kweFk8Nx3cjW8lu4WdI5fssDNEWAbd95mBXPUA9a/S/4f+F9K+Hdjf2dhHCBqs5ubtIIhFbvIVCHbDkqoKjBHfvWVSTlpbQlzUUrPU7v4P+F9Y0Twdp6axa2lrcKmAtoWZTAp/dBmcZY4ycjjnj1r6Ut9RtZbD7JgAsuCK8f0iS91S3WC0YQxooVVHACgYAUdgOwrTTw9q0b+Z9qYH0zU0/cXuoi99T51+J/wZ1+61KW+8NzNOJXZzbso+XJz8pHb61x2neF9W0lTHqtlJaS9ywIViPQ19y+H4Xs5M30hkPqx6VV+JSWF9oE8FtEstwyZjC4zuHSh0k1zItVJKPK3of/W4WGzm1NhJcyFifU12eleHUyuys3S7cnHBr0bSYnBXC14drnZJ2WhraZ4f2gZrvNP0kIAB2qtp8cgUZWvX/BfgrU/Ege5V47WzhO155emeuFUcsf85reFNyfLFHLOaW5zlrYEDg12+ieEfEGtOF02zkdSeZGG2MfV2wK9csNM8FeFIBO8QvJY8brm4AZQfZPuqPzrRHxR0l38hZ44lXgFvkXA9Pwr06WWVGrtHDPGUouzkcNrHhTwr4M8NX2v+N1j1YWUJufsoUNBlOmd3Lc+wH1r8ktMuJvGHxa8X+M9emNxe6jcRrZmQ5EFkY12QxDoqBlccd6/Qv8AaR8Yyx+Cb660i50+8S7hNuY42drhVYjcRn5eOOMV+YtpcXFrcw6lpZzeW4IMLjaZIyQWRh+AII6EA+orqx+QTxGW1IYfSe687dPn+Zllmf08LmdOddXgtH5X6/L8rn0lDEsEW2UfIpBXHHI6VV1G4gcPGZChIPBHIwKz7Xxt4av4oluLpIJ3Cjy5MoQxGeM8cdDg4Bpt1bwXypMkiyRsMqyMDkE+1fhePo1adR06kWn2aP33A1qVWmqlOSa7pmOIowpMS7tx+83b8KxtVsoEt5JrogRLlnJ4AAGa6TV9U8O6CIop7je5PMcYLt07hen44rx7xd4nXVJBHGGtrFMbYmOWduu9wucew5A9fT18g4Yx+YVVyQah1k1ovTu/JfhueFxDxXgcupNTmpT6RT1fr2XmzyPxNMJ7t7oJh7hlSJT1WIEgZ9zkn8favdv2ffjTqvwwfWbbVY21fQIrqMvaMxDRK/ytJC3Yg4JHQivDmgl1DUxMykKhG0ew79a6nwxZFTq8GwSJPC52n+LackE/T0r99wmUUaOHjhoL3Yq39efU/nrHZzWr154mcvek7/8AA/Q/QNfH/wAF/DXimHUNPgTSYPGCi9XU0JlgmuHwskdw+A0cgI6MCuDkGvb7nTl2q275XUOjD7rKRkMp7g9iK/LbTLH7VoM+gXh8y0fDwZ6wuOm3PftX1t+z/wDFy8i0VPhr4uZZ5tNJ/s+Wck+ZDknySTyMfwkHjpXJjOG0481DR9jTB8QtS5MQrrufUOjatcaNIFSTKk969KTWPtVv5r3Ww46DFeURW9p4kSSfQsJLHnfbOfmyDzsJJz9K5i4ku4i0LSum0kFTkEEdjXymJw1XDzcKisfU4bFU60Oem7o9M1bxBHakt9sbj3rmbL4i6TaXbfbp9/HAZ64l9BfUx80rt9Oa569+HNhM2Z2m/WuKTad0dJ//187TYpMjBr0PTFlUDFZ9lDaKBgV1tqsGBt614kYnROXQ7Hw1p9xql/DZmTy1c5kc9EReWb8BXdeMvixFpEC6R4dUR2NvCyK2cEleCSPUnqa4eyujp+g6rfxnDLEsQPoHOW/QV4Ncap9qtry3lf5iLjac90VZFH4gGvt+HMDB03Xmr3Pjc/x1RT9hTdjt4Pibrd5dOsVyzgjlSxII7jGe9RX+vXN9cB3k8tgPurwufXj2rwjwXqMlzO8q4LBsEentXrYiOFYKAfavrHSitUj5ZVG9zE8X3L3kMVtK7Og7Z4x9K8tl0SEEugwSeK9N135ihYZOD26VzLqGUENnOefpSS0NE7nK3fh+HUolgnRJDkAMQC/oRnr6Vw2vaNrelTTzz6gWt72SC0srZSf3ZyC7AEcHYrcivZ7GNPtiBuhPHfJzXK/E2EnUfDTpkILqfd9fJO3+uK4q+CoTalOCbv8A8A7KWNr0ouMJtKxjDScxq79cDBBP9c1nXWhJKcu2fXj8K6+MnIwu7jGeuMU+SINwO3YV1W6HFdvU4e08PW0cudpIxnNbMFpFZTM8a4J57elavlBA29SfQ8VWniBjLKCPx6UEPzHNpv7v7TYMSMAsnUjvxUSu6yR3qny7iE7lYcEEVWF3LZSbuSQB064BplzqEE5MqnacYI6VtGSMZQ7H0b4A+I9zZ7JJpWWUSH5snHQcD+de+/8ACbeHvEMSxapGIZ26XUOBID6kdGH1r84xq5tFljQkHBkB64K49PUVt6Z4/u4tqSSMdpHP0HX+VcOLw1GuuWornbhK9ak+anKx+jmjO+jzpMZVu7KQgLPH0Gezr1U/ofWvXo9MsNRgFxGAcjtX58eCvilNZzKrSbo3O1kblWHoe1fWXhjxxa29vHdxvm0kwME52MRnafb0NfEZrkzw37ynrH8j7LK82Vf93UVpfmf/0PQbTS4yOR+ZrorawjXGP51x8GoS4Azx9K3rW/c8Bv0rx00as3PEzC28HXdpEcSXSzYx1zHGCP1NfJcWsm8tkuY2OX+YrxnJQxsPXv2r6D8carLZ6dpMhPyyz3EWTxklAVz+K4r4vn1ZdA8Q3WnSFhBKxurUHPMZb94nHUqeor9LyNKOCh5/5s/O87beMnb+tEexfCaCE+C11fAZ7i7mVjjJ+RsBa9WWTdGA3yrzxjvXzp8ONek0PQdSsZWL20WrEW6j/aUyEj8CteswaxdahH5gVkGM8ivYjO8UmeR7Np6GlrBV281Tnadtc66gDCnoRW7h5ItkhyQAx4HWsiXH3CBgZ9fz9qnyLRn7XE6snU88DJ/AetcJ4ofXUh0ka1LG0k+otJaRohDxxJHIH3Z6nBXJx34zXq9hbrJcHOPlGQMevH9a818WSjUfiRBaf8s9IsAOenm3J3t+O1VrGrC8otN6fj6m0aloSi0tfw9DSgSQoM85A9c0oABOSR7danKgAHdwDjgY9BTWCopcgDuM8dK1Mio7rsx8x64qhLKNjE9yCen4VYMhkYrhhz15we9UZVyCucEn2PH9KlkmNdzoFO5eexPUj/8AVXKXlx1MRGe3OK6W7kRWI547dMnvjiuP1FfMLDA74HANZTdkVCN2YT6rP9o8pmyNrDkdcj8KiW7MROGPJ6isqcPBdKX4XnPqOD9aha5Vmyh24BAB/WvPnNt6npQgktDvdN16a2dVD4H97+or6r+FvjqJm/s29cPb3ACMHPHsR/SvhVZ2RgSc4OcV2uh6hcMcW8vluOR2yaOdTTpzV0w5XBqcWf/Z",Uo={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral"},Xo={"xxx-small":{size:16,iconSize:10},"xx-small":{size:24,iconSize:14},"x-small":{size:32,iconSize:18},small:{size:40,iconSize:22},medium:{size:56,iconSize:28},large:{size:64,iconSize:32},"x-large":{size:80,iconSize:40},"xx-large":{size:160,iconSize:80}};const Ko={"xxx-small":"7px","xx-small":"var(--Legal-Font-Size)","x-small":"var(--Number-Small-Font-Size)",small:"var(--Number-Small-Font-Size)",medium:"var(--Number-Medium-Font-Size)",large:"var(--Number-Medium-Font-Size)","x-large":"var(--Number-Large-Font-Size)","xx-large":"var(--Number-Large-Font-Size)"};function qo({src:e,defaultPhoto:t=!0,alt:o,initials:n,icon:i,color:a="default",size:l="x-small",customSize:s,clickable:d=!1,onClick:c,insideButton:u=!1,className:p="",sx:m={},...f}){const[g,x]=r(!1),b="custom"===l&&s?{size:s}:Xo[l]||Xo.medium,v=Uo[a]||Uo.default,y=e||(!t||n||i?void 0:Go),S=y&&!g,k=!S&&n,B=!S&&!k,w=d||!!c,C=S?"transparent":"var(--Buttons-"+v+"-Button)",T="var(--Buttons-"+v+"-Border)",I="var(--Buttons-"+v+"-Text)";return ce(h,{component:w?"button":"div",type:w?"button":void 0,role:w?"button":"img","aria-label":o||n||"Avatar",tabIndex:w?0:void 0,onClick:w?c:void 0,className:"avatar avatar-"+l+" avatar-"+a+(w?" avatar-clickable":"")+(S?" avatar-image":k?" avatar-initials":" avatar-fallback")+(p?" "+p:""),sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:b.size+"px",height:b.size+"px",borderRadius:"50%",backgroundColor:C,color:I,fontFamily:"inherit",fontWeight:600,overflow:"hidden",flexShrink:0,border:S?"none":"2px solid "+T,...u&&{marginLeft:"2px",marginRight:"2px"},...w&&{cursor:"pointer",outline:"none",padding:0,transition:"background-color 0.15s ease, border-color 0.15s ease","&:hover":{backgroundColor:S?"rgba(0,0,0,0.08)":"var(--Buttons-Default-Hover)"},"&:active":{backgroundColor:S?"rgba(0,0,0,0.15)":"var(--Buttons-Default-Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px"}},...m},...f,children:[S&&de(h,{component:"img",src:y,alt:o||"Avatar",onError:()=>x(!0),sx:{width:"100%",height:"100%",objectFit:"cover",borderRadius:"50%"}}),k&&(()=>{const{Comp:e,token:t}=function(e){switch(e){case"xxx-small":case"xx-small":case"x-small":return{Comp:To,token:"Overline-Small"};case"small":case"medium":case"large":default:return{Comp:Io,token:"Overline-Medium"};case"x-large":case"xx-large":return{Comp:zo,token:"Overline-Large"}}}(l);return de(e,{sx:{color:"inherit",fontSize:Ko[l]||Ko.medium,lineHeight:1,textAlign:"center",marginInlineEnd:`calc(-1 * var(--${t}-Letter-Spacing, 0px))`,...jr},"aria-hidden":"true",children:n.slice(0,2).toUpperCase()})})(),B&&de(jo,{size:l,sx:{color:"inherit"},children:i||de(me,{})})]})}function Jo({children:e,max:r=5,size:o="medium",spacing:n=-8,className:i="",sx:a={},...l}){const s=t.Children.toArray(e),d=s.slice(0,r),c=s.length-r;return ce(h,{role:"group","aria-label":"Avatar group, "+s.length+" avatars",className:"avatar-group "+i,sx:{display:"inline-flex",alignItems:"center","& > *:not(:first-of-type)":{marginLeft:n+"px"},...a},...l,children:[d,c>0&&de(qo,{initials:"+"+c,size:o,color:"neutral",sx:{border:"2px solid var(--Background)",zIndex:0}})]})}const Yo=["primary","secondary","tertiary","neutral","info","success","warning","error"],Zo=e=>e.charAt(0).toUpperCase()+e.slice(1);function $o(){const e={};return Yo.forEach(t=>{e[t]=function(e){const t=Zo(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"none"}}(t),e[t+"-outline"]=function(e){return{bg:"var(--Background)",text:"var(--Text)",border:"1px solid var(--Buttons-"+Zo(e)+"-Border)"}}(t),e[t+"-light"]=function(e){const t=Zo(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"1px solid var(--Buttons-"+t+"-Border)"}}(t)}),e}const _o={small:{minW:16,height:16,fontSize:"10px",padding:"0 4px",dotSize:8},medium:{minW:20,height:20,fontSize:"12px",padding:"0 6px",dotSize:10},large:{minW:24,height:24,fontSize:"14px",padding:"0 8px",dotSize:12}};function en({variant:e="primary",size:t="medium",badgeContent:r,max:o=99,showZero:n=!1,invisible:i=!1,dot:a=!1,overlap:l="rectangular",anchorOrigin:s={vertical:"top",horizontal:"right"},children:d,className:c="",sx:u={},...p}){const h=$o(),f=h[e]||h.primary,g=_o[t]||_o.medium;let x=r;a?x="":"number"==typeof r&&r>o&&(x=o+"+");const b=i||!a&&!n&&(0===r||null==r),v={"& .MuiBadge-badge":{minWidth:a?g.dotSize:g.minW,height:a?g.dotSize:g.height,padding:a?0:g.padding,fontSize:g.fontSize,fontWeight:600,fontFamily:"var(--Body-Font-Family)",lineHeight:1,borderRadius:a?"50%":g.height/2+"px",backgroundColor:f.bg,color:f.text,border:f.border,boxSizing:"border-box",boxShadow:"0 0 0 1px var(--Background)",transition:"transform 0.2s ease, opacity 0.2s ease"},...u};return de(m,{badgeContent:a?"":x,max:o,showZero:n,invisible:b,overlap:l,anchorOrigin:s,variant:a?"dot":"standard",className:"badge-"+e+" "+c,sx:v,...p,children:d})}const tn={1:[[.5,1,1]],2:[[1,2,2],[2,4,4]],3:[[1,2,2],[2,4,4],[3,6,6]],4:[[1,2,2],[2,4,4],[4,8,8],[8,16,16]],5:[[1,2,2],[2,4,4],[4,8,8],[8,16,16],[16,32,32]]},rn=[.2,.17,.15,.13,.11];function on(e){return tn[e].map(([e,t,r],o)=>`${e}px ${t}px ${r}px ${`var(--Dropshadow-Color-${o+1}, rgba(var(--Dropshadow-Color, 20, 20, 20), ${rn[o]}))`}`).join(", ")}const nn=on(1),an=on(2),ln=on(3),sn=on(4),dn=on(5),cn={0:"none",1:nn,2:an,3:ln,4:sn,5:dn},un={"black-white":"BlackWhite"},pn=e=>{return un[e]||(t=e).charAt(0).toUpperCase()+t.slice(1);var t},hn={small:"Sm-",medium:"",large:"Lg-"};function mn(e,t){const r=pn(e),o=(e,t)=>`color-mix(in srgb, rgb(var(${e}, ${t})) calc(var(--Button-Bevel-Opacity, 0.5) * 100%), transparent)`,n="var(--_bevel)",i="calc(-1 * var(--_bevel))",a=hn[t],l=void 0===a?(e,t)=>t:(e,t)=>`var(--${a}Button-${e}, ${t})`;return[`inset ${l("Lowlight-Offset-x",i)} ${l("Lowlight-Offset-y",i)} ${l("Lowlight-Blur-Radius",n)} ${l("Lowlight-Spread",i)} `+o(`--Buttons-${r}-Lowlight`,"0 0 0"),`inset ${l("Highlight-Offset-x",n)} ${l("Highlight-Offset-y",n)} ${l("Highlight-Blur-Radius",n)} ${l("Highlight-Spread",i)} `+o(`--Buttons-${r}-Highlight`,"255 255 255")].join(", ")}const fn={small:"4px 2px",medium:"4px 2px",large:"4px"},gn={small:{avatar:"xxx-small",icon:"small"},medium:{avatar:"xx-small",icon:"medium"},large:{avatar:"small",icon:"large"}};function xn(e,r){if(!t.isValidElement(e))return e;const o=gn[r]||gn.medium;return e.type===qo?t.cloneElement(e,{size:o.avatar,insideButton:!0}):e.type===jo?t.cloneElement(e,{size:o.icon}):e}const bn=["default","primary","secondary","tertiary","neutral","info","success","warning","error"],vn=pn;function yn(e,t=!1,r=!1,o="medium"){const n=vn(e),i=mn(e,o),a=t?nn:"none";return{backgroundColor:`var(--Buttons-${n}-Button)`,color:`var(--Buttons-${n}-Text)`,border:`var(--Button-Border-Width) solid var(--Buttons-${n}-Border)`,boxShadow:"none"===a?i:`${i}, ${a}`,position:"relative",zIndex:1,"& .MuiTouchRipple-rippleVisible":{color:`var(--Buttons-${n}-Hover)`,zIndex:-1},"&:hover":{backgroundColor:`var(--Buttons-${n}-Hover)`,boxShadow:`${i}, ${t?an:nn}`,...!r&&{transform:"translateY(-1px)"}},"&:active":{backgroundColor:`var(--Buttons-${n}-Pressed)`,boxShadow:i,...!r&&{transform:"translateY(0)"}},"&.Mui-focusVisible":{backgroundColor:`var(--Buttons-${n}-Button)`,outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"& .MuiTouchRipple-root":{zIndex:-1},"& .MuiTypography-root":{zIndex:1},"& .MuiButton-icon":{zIndex:1}}}function Sn(e,t=!1){return{backgroundColor:"transparent",color:"var(--Text)",border:`var(--Button-Border-Width) solid var(--Buttons-${vn(e)}-Border)`,boxShadow:"none","& .MuiTouchRipple-rippleVisible":{color:"var(--Hover)"},"&:hover":{backgroundColor:"var(--Hover)",boxShadow:"none",...!t&&{transform:"translateY(-1px)"}},"&:active":{backgroundColor:"var(--Pressed)",...!t&&{transform:"translateY(0)"}},"&.Mui-focusVisible":{backgroundColor:"transparent",outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}}}function kn(e,t=!1){return{backgroundColor:"transparent",color:e?"var(--Hotlink)":"var(--Quiet)",border:"var(--Button-Border-Width) solid transparent",boxShadow:"none",textDecoration:"none",...e&&{"& .btn-text-content":{textDecoration:"underline"}},"& .MuiTouchRipple-rippleVisible":{color:"var(--Hover)"},"&:hover":{backgroundColor:"var(--Hover)",boxShadow:"none",...!t&&{transform:"translateY(-1px)"},...e?{"& .btn-text-content":{textDecoration:"none"}}:{color:"var(--Text)"}},"&:active":{backgroundColor:"var(--Pressed)",...!t&&{transform:"translateY(0)"},...e?{"& .btn-text-content":{textDecoration:"none"}}:{color:"var(--Text)"}},"&.Mui-focusVisible":{backgroundColor:"transparent",outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px",...e&&{"& .btn-text-content":{textDecoration:"none"}}}}}const Bn=/-light$/,wn=new Set;const Cn={small:"var(--Small-Button-Height)",medium:"var(--Button-Height)",large:"var(--Large-Button-Height)"},Tn={small:{minHeight:"var(--Small-Button-Height)",minWidth:"var(--Button-Min-Width)",fontSize:"13px","--_height":"var(--Small-Button-Height)"},large:{minHeight:"var(--Large-Button-Height)",minWidth:"var(--Lg-Button-Min-Width, var(--Button-Min-Width))",fontSize:"17px","--_height":"var(--Large-Button-Height)"},medium:{minHeight:"var(--Button-Height)",minWidth:"var(--Button-Min-Width)",fontSize:"15px","--_height":"var(--Button-Height)"}};function In({variant:e="default",size:r="medium",elevated:o=!1,selected:n=!1,fullWidth:i=!1,disabled:a=!1,iconOnly:l=!1,letterNumber:s=!1,avatar:d=!1,swatch:c=!1,swatchColor:u,startIcon:p,endIcon:m,startDecorator:b,endDecorator:v,badge:y=!1,badgeContent:S,badgeVariant:k="error",badgeSize:B,badgeDot:w=!1,badgeMax:C=99,badgeAnchorOrigin:T={vertical:"top",horizontal:"right"},children:I,className:A="",sx:z={},...R}){const E=l||d||c;if("production"!==process.env.NODE_ENV){const e=R["aria-label"]||R["aria-labelledby"]||R.title;E&&!e&&console.error('[OmniDesign] An icon-only <Button> has no accessible name. A screen reader announces it as just "button". Add aria-label="…" describing the ACTION ("Delete item"), not the icon ("trash").'),e&&t.Children.forEach(I,t=>{const r=t?.props?.["aria-label"]||t?.props?.titleAccess;r&&console.error('[OmniDesign] <Button> is labelled "'+e+'" but also contains an icon labelled "'+r+"\". A screen reader reads both. Remove the icon's label — the button owns the name.")})}const P=!E,O=i&&!E&&!s,L=function(e){const t=String(e||"default");if(!Bn.test(t))return t;const r=t.replace(Bn,"");return"production"===process.env.NODE_ENV||wn.has(t)||(wn.add(t),console.warn('[Button] variant="'+t+'" — the -light shape was removed. Rendering variant="'+r+'" (solid). Use a Buttons mode for colour and solid / -outline / ghost / text for shape.')),r}(!d&&!c||"ghost"!==e&&"text"!==e?e:"primary"),M=function(e,t=!1,r=!1,o="medium"){const n={};return bn.forEach(e=>{n[e]=yn(e,t,r,o),n[`${e}-outline`]=Sn(e,r)}),n["black-white"]=yn("black-white",t,r,o),n["black-white-outline"]=Sn("black-white",r),n.danger=yn("error",t,r,o),n.outline=Sn("default",r),n.ghost=kn(e,r),n.text=kn(e,r),n}(P,o,n,r),W=M[L]||M.default,D=function({size:e,iconOnly:t,letterNumber:r,avatar:o}){const n=Tn[e]||Tn.medium,i=Cn[e]||Cn.medium;if(t)return{height:i,width:i,minWidth:"unset",minHeight:"unset",fontSize:o?"small"===e?"var(--Button-ExtraSmall-Font-Size)":"large"===e?"18px":"14px":"small"===e?"0.875rem":n.fontSize,padding:"0","--_height":i};return r?{...n,minHeight:i,minWidth:i,padding:"0"}:{...n,padding:"large"===e?"0 var(--Lg-Button-Padding)":"0 var(--Button-Padding)"}}({size:r,iconOnly:E,letterNumber:s,avatar:d}),F="small"===r?Fo:No,N=void 0!==b?xn(b,r):void 0,H=void 0!==v?xn(v,r):void 0,V=B||("small"===r?"small":"large"===r?"large":"medium"),Q=ce(ue,{children:[de(f,{styles:{'[class*="btn-"] .MuiButton-startIcon, [class*="btn-"] .MuiButton-icon':{marginLeft:"0px !important",marginRight:"2px !important"},'[class*="btn-"] .MuiButton-endIcon':{marginLeft:"2px !important",marginRight:"0px !important"},'[class*="btn-"] .MuiButton-iconSizeSmall .MuiSvgIcon-root, [class*="btn-"] .MuiButton-iconSizeSmall > *':{fontSize:Vo.small+" !important"},'[class*="btn-"] .MuiButton-iconSizeMedium .MuiSvgIcon-root, [class*="btn-"] .MuiButton-iconSizeMedium > *':{fontSize:Vo.medium+" !important"},'[class*="btn-"] .MuiButton-iconSizeLarge .MuiSvgIcon-root, [class*="btn-"] .MuiButton-iconSizeLarge > *':{fontSize:Vo.large+" !important"}}}),de(g,{size:r,...O&&{fullWidth:!0},disabled:a,startIcon:void 0!==N?N:d?(()=>{if(d&&I){const e=Cn[r]||Cn.medium;return de(x,{sx:{width:e,height:e,backgroundColor:"inherit",color:"inherit",fontSize:"small"===r?"var(--Button-ExtraSmall-Font-Size)":"large"===r?"18px":"14px"},children:I})}return p})():p,endIcon:void 0!==H?H:m,className:`btn-${e} ${A}`,role:"button",sx:{borderRadius:d?"var(--Large-Button-Height)":l||c?"small"===r?"var(--Sm-Button-Icon-Radius, var(--Button-Icon-Radius))":"large"===r?"var(--Lg-Button-Icon-Radius, var(--Button-Icon-Radius))":"var(--Button-Icon-Radius)":"small"===r?"var(--Sm-Button-Radius, var(--Button-Radius))":"large"===r?"var(--Lg-Button-Radius, var(--Button-Radius))":"var(--Button-Radius)",textTransform:"none",fontWeight:"inherit",lineHeight:1,whiteSpace:"nowrap",flexShrink:0,transition:"background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out, transform 0.15s ease-in-out","--_bevel":"min(calc(var(--Button-Bevel) * var(--_height) / 100), calc(var(--_height) / 5))",..."small"===r&&{position:"relative","&::before":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"100%",height:"100%",minWidth:"var(--Target, 0px)",minHeight:"var(--Target, 0px)"}},...D,...W,"&.MuiButton-root":{padding:D.padding??"0 var(--Sizing-1)"},"& .MuiButton-startIcon":{display:"inherit",color:"inherit",marginLeft:"0px !important",marginRight:d?"0px !important":"2px !important"},...d&&{"& .MuiAvatar-root":{fontSize:"small"===r?"var(--Button-ExtraSmall-Font-Size)":"large"===r?"18px":"14px"}},"& .MuiButton-endIcon":{display:"inherit",color:"inherit",marginLeft:"2px !important",marginRight:"0px !important"},"& .MuiSvgIcon-root":{color:"inherit"},"&:focus-visible, &.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none",backgroundColor:W.backgroundColor,color:W.color,border:W.border,boxShadow:"none"},...c&&{border:"var(--Button-Border-Width) solid var(--Border)",padding:"1px",width:Cn[r]||Cn.medium,height:Cn[r]||Cn.medium,minWidth:"unset",minHeight:"unset",boxShadow:"none","--_bevel":"0",backgroundColor:"transparent !important","&:hover":{backgroundColor:"transparent !important",boxShadow:"none"},"&:active":{boxShadow:"none"},"&:hover .btn-swatch-inner":{filter:"brightness(0.9)"}},...O&&{width:"100%"},...z},...R,...c?{style:{backgroundColor:"transparent"}}:{},children:d?null:c?de(h,{className:"btn-swatch-inner",style:{width:"100%",height:"100%",borderRadius:"small"===r?"var(--Sm-Button-Icon-Inner-Radius, calc(var(--Button-Icon-Radius) - 2px))":"large"===r?"var(--Lg-Button-Icon-Inner-Radius, calc(var(--Button-Icon-Radius) - 2px))":"var(--Button-Icon-Inner-Radius, calc(var(--Button-Icon-Radius) - 2px))",...u?{backgroundColor:u}:{}}}):(()=>{if(E)return I;if(s){return de("small"===r?Do:F,{component:"span",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",padding:"4px",color:"inherit",lineHeight:1,...jr},children:I})}return"string"==typeof I||"number"==typeof I?de(h,{component:"span",className:"btn-text-content",sx:{display:"inline-flex",alignItems:"center",padding:fn[r]||fn.medium},children:de(F,{component:"span",sx:{color:"inherit",...jr},children:I})}):I})()})]});return y?de(en,{variant:k,size:V,badgeContent:S,dot:w,max:C,anchorOrigin:T,showZero:0===S,children:Q}):Q}const An=["default","primary","secondary","tertiary","neutral","info","success","warning","error","black-white"],zn=e=>"Default"===e?"var(--Quiet)":"var(--Buttons-"+e+"-Border)";function Rn(){const e={};return An.forEach(t=>{e[t]=function(e){const t=pn(e);return{color:t,borderToken:zn(t),icon:"var(--Buttons-"+t+"-Border)"}}(t)}),e}const En=/-(outline|light|solid)$/,Pn=new Set;function On(e){const t=Rn();return t[function(e){const t=String(e||"default");if(!En.test(t))return t;const r=t.replace(En,"");return"production"===process.env.NODE_ENV||Pn.has(t)||(Pn.add(t),console.warn('[Checkbox] variant="'+t+'" — the -outline/-light/-solid shapes were removed; a Checkbox has one look and `variant` selects colour only. Rendering variant="'+r+'". Update the call site.')),r}(e)]||t.default}const Ln={small:{box:16,icon:12,labelSize:"13px",gap:6,touchTarget:24},medium:{box:20,icon:14,labelSize:"15px",gap:8,touchTarget:24},large:{box:24,icon:18,labelSize:"17px",gap:10,touchTarget:24}};function Mn({size:e,variant:t,checked:r,indeterminate:o}){const n=On(t),i=Ln[e]||Ln.medium,a=r||o,l=n.borderToken,s="small"===e?"var(--Sm-Checkbox-Radius, 3.2px)":"large"===e?"var(--Lg-Checkbox-Radius, 4.8px)":"var(--Checkbox-Radius, 4px)";return de(h,{className:"chk-box-icon",sx:{width:i.box,height:i.box,boxSizing:"border-box",borderRadius:s,border:"2px solid "+l,overflow:"hidden",flexShrink:0,transition:"border-color 0.15s ease-in-out"},children:de(h,{sx:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"var(--Background)",color:"var(--Text)",transition:"background-color 0.15s ease-in-out"},children:a&&de(o?fe:he,{sx:{fontSize:i.icon,color:n.icon}})})})}function Wn({size:e,variant:t}){return de(Mn,{size:e,variant:t,checked:!1,indeterminate:!1})}function Dn({size:e,variant:t}){return de(Mn,{size:e,variant:t,checked:!0,indeterminate:!1})}function Fn({size:e,variant:t}){return de(Mn,{size:e,variant:t,checked:!1,indeterminate:!0})}function Nn({variant:e="primary",size:t="medium",label:r,checked:o,defaultChecked:n,indeterminate:i=!1,disabled:a=!1,onChange:l,name:s,value:d,className:c="",sx:u={},"aria-label":p,"aria-labelledby":h,"aria-describedby":m,inputProps:f={},...g}){On(e);const x=Ln[t]||Ln.medium,y="small"===t?ao:co,S={...f,...p&&{"aria-label":p},...h&&{"aria-labelledby":h},...m&&{"aria-describedby":m}},k=de(b,{checked:o,defaultChecked:n,indeterminate:i,disabled:a,onChange:l,name:s,value:d,icon:de(Wn,{size:t,variant:e}),checkedIcon:de(Dn,{size:t,variant:e}),indeterminateIcon:de(Fn,{size:t,variant:e}),className:"chk-"+e+" "+c,inputProps:S,disableRipple:!0,sx:{padding:(x.touchTarget-x.box)/2+"px",minWidth:24,minHeight:24,borderRadius:"var(--Checkbox-Radius, 4px)",color:"inherit",transition:"background-color 0.15s ease-in-out","&.Mui-checked, &.MuiCheckbox-indeterminate":{color:"inherit"},"&:hover":{backgroundColor:"transparent"},"&.Mui-focusVisible .chk-box-icon":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none"},...u},...g});return r?de(v,{control:k,label:de(y,{component:"span",sx:{color:a?"var(--Text-Quiet)":"var(--Text)",fontSize:x.labelSize,lineHeight:1.4,userSelect:"none"},children:r}),disabled:a,sx:{marginLeft:0,marginRight:0,gap:x.gap+"px",alignItems:"center","&.Mui-disabled .MuiTypography-root":{color:"var(--Text-Quiet)",opacity:.6}}}):k}const Hn=["primary","secondary","tertiary","neutral","info","success","warning","error"],Vn=e=>e.charAt(0).toUpperCase()+e.slice(1);function Qn(e){return{bg:"var(--Hover)",border:"var(--Buttons-"+Vn(e)+"-Border)",text:"var(--Text)",focusBg:"var(--Hover)"}}function jn(e){const t=Vn(e);return{bg:"var(--Buttons-"+t+"-Light-Button, var(--Hover))",border:"var(--Buttons-"+t+"-Border)",text:"var(--Text)",focusBg:"var(--Buttons-"+t+"-Light-Button, var(--Hover))"}}const Gn={small:{height:"var(--Small-Button-Height)",fontSize:"13px",labelSize:"13px",padding:"4px var(--Input-Padding, 8px)",iconSize:16},medium:{height:"var(--Button-Height)",fontSize:"15px",labelSize:"15px",padding:"4px var(--Input-Padding, 12px)",iconSize:18},large:{height:"var(--Large-Button-Height)",fontSize:"17px",labelSize:"17px",padding:"4px var(--Input-Padding, 16px)",iconSize:20}},Un={small:{height:"48px",fontSize:"13px",labelSize:"11px",padding:"20px var(--Input-Padding, 12px) 4px",leftPad:12,iconSize:16},medium:{height:"56px",fontSize:"15px",labelSize:"12px",padding:"22px var(--Input-Padding, 14px) 6px",leftPad:14,iconSize:18},large:{height:"64px",fontSize:"17px",labelSize:"14px",padding:"24px var(--Input-Padding, 16px) 6px",leftPad:16,iconSize:20}},Xn={info:ve,success:ge,warning:xe,error:be},Kn={info:{border:"var(--Buttons-Info-Border)",icon:"var(--Icons-Info)",text:"var(--Hotlink)"},success:{border:"var(--Buttons-Success-Border)",icon:"var(--Icons-Success)",text:"var(--Text-Success)"},warning:{border:"var(--Buttons-Warning-Border)",icon:"var(--Icons-Warning)",text:"var(--Text-Warning)"},error:{border:"var(--Buttons-Error-Border)",icon:"var(--Icons-Error)",text:"var(--Text-Error)"}};function qn({variant:e="primary-outline",size:t="medium",label:r,labelPosition:o="standard",placeholder:n,helperText:i,validation:a,validationMessage:l,disabled:s=!1,value:d,defaultValue:c,onChange:u,name:p,type:m="text",multiline:f=!1,rows:g,maxRows:x,startAdornment:b,endAdornment:v,fullWidth:B=!1,className:w="",sx:C={},"aria-label":T,"aria-labelledby":I,"aria-describedby":A,"aria-required":z,"aria-invalid":R,inputProps:E={},...P}){const O=function(){const e={};return Hn.forEach(t=>{e[t+"-outline"]=Qn(t),e[t+"-light"]=jn(t)}),e.outline=Qn("primary"),e.light=jn("primary"),e}(),L=O[e]||O["primary-outline"],M="floating"===o;e.endsWith("-light");const W=M?Un[t]||Un.medium:Gn[t]||Gn.medium,D=e.replace(/-outline$/,"").replace(/-light$/,"");Vn(D);const F="var(--Text)",N=a?Kn[a]:null,H=a?Xn[a]:null,V=N?N.border:L.border,Q={...E,...T&&{"aria-label":T},...I&&{"aria-labelledby":I},...A&&{"aria-describedby":A},...z&&{"aria-required":z},...R&&{"aria-invalid":R}};return ce(h,{className:"inp-"+e+" "+w,sx:{width:B?"100%":"auto",...C},children:[(()=>{if(!r||M)return null;return de("small"===t?ao:co,{component:"label",sx:{display:"block",marginBottom:"6px",color:s?"var(--Quiet)":"var(--Text)",fontSize:W.labelSize,fontWeight:500,opacity:s?.6:1},children:r})})(),de(h,{sx:{border:"1px solid "+V,borderRadius:"small"===t?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===t?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease-in-out",boxShadow:"none","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{children:de(y,{value:d,defaultValue:c,onChange:u,name:p,type:m,disabled:s,placeholder:n,multiline:f,rows:g,maxRows:x,fullWidth:!0,label:M?r:void 0,variant:"outlined",size:"small"===t?"small":"medium",inputProps:Q,InputProps:{startAdornment:b?de(S,{position:"start",children:b}):void 0,endAdornment:(()=>{if(v)return de(S,{position:"end",children:v})})()},sx:{"& .MuiOutlinedInput-root":{backgroundColor:"var(--Hover)",color:"var(--Quiet)",fontSize:W.fontSize,minHeight:f?"auto":W.height,padding:0,borderRadius:0,transition:"color 0.15s ease-in-out",...M&&{alignItems:"flex-end"},"& fieldset":{border:"none"},"&.Mui-focused":{color:F},"&:not(.Mui-focused) .MuiOutlinedInput-input:not(:placeholder-shown)":{color:F},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed"},"& input":{padding:W.padding,color:"inherit","&::placeholder":{color:"var(--Quiet)",opacity:1}},"& textarea":{padding:W.padding,color:"inherit","&::placeholder":{color:"var(--Quiet)",opacity:1}},"& .MuiInputAdornment-root":{color:"var(--Quiet)"},...M&&{"& .MuiInputAdornment-positionStart":{marginLeft:(W.leftPad||14)+"px",marginRight:"4px",marginBottom:"8px"},"& .MuiInputAdornment-positionEnd":{marginRight:"8px",marginBottom:"8px"},...b&&{"& input":{paddingLeft:"4px"},"& textarea":{paddingLeft:"4px"}}}},"& .MuiInputLabel-root":{color:"var(--Quiet)",fontSize:W.fontSize,transformOrigin:"top left",transform:"translate("+((W.leftPad||14)+(b?32:0))+"px, 16px) scale(1)","&.MuiInputLabel-shrink":{transform:"translate("+((W.leftPad||14)+(b?32:0))+"px, 6px) scale(0.75)",color:"var(--Quiet)"},"&.Mui-focused":{color:F},"&.Mui-disabled":{color:"var(--Quiet)",opacity:.6}},"& .MuiOutlinedInput-notchedOutline legend":{display:"none"},"& .MuiOutlinedInput-notchedOutline":{top:0},"& .MuiOutlinedInput-root.Mui-focused":{outline:"none"},"& .MuiOutlinedInput-root:focus-within":{outline:"none"}},...P})})}),a&&l?ce(h,{sx:{display:"flex",alignItems:"center",gap:"6px",marginTop:"4px",marginLeft:"2px"},children:[H&&de(H,{sx:{fontSize:W.iconSize,color:N.icon,flexShrink:0}}),de(k,{sx:{color:N.text,fontSize:"small"===t?"11px":"12px",margin:0},children:l})]}):i?de(k,{sx:{color:"var(--Quiet)",fontSize:"small"===t?"11px":"12px",marginTop:"4px",marginLeft:"2px"},children:i}):null]})}const Jn=e=>e.charAt(0).toUpperCase()+e.slice(1),Yn={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 8px",iconSize:16},medium:{height:"var(--Button-Height)",fontSize:"14px",padding:"6px 12px",iconSize:18},large:{height:"var(--Large-Button-Height)",fontSize:"16px",padding:"8px 16px",iconSize:20}},Zn={small:{height:48,fontSize:"13px",padding:"20px 12px 4px",labelSize:"11px",leftPad:12},medium:{height:56,fontSize:"14px",padding:"22px 14px 6px",labelSize:"12px",leftPad:14},large:{height:64,fontSize:"16px",padding:"24px 16px 6px",labelSize:"14px",leftPad:16}};function $n({options:e=[],value:a,defaultValue:l="",onChange:s,label:d,labelPosition:c="top",size:u="medium",variant:p="outline",color:m="primary",selectionStyle:f="default",mode:g="standard",placeholder:x="Select…",showDividers:b=!1,showColorLabels:v=!0,startDecoration:y,disabled:S=!1,fullWidth:k=!1,className:B="",sx:w={},...C}){const T="default"===m?"primary":m,I=Jn(T),A="var(--Buttons-"+I+"-Border)",z="default"===m?"var(--Text)":"var(--Text-"+I+")",[R,E]=r(l),[P,O]=r(!1),[L,M]=r(!1),[W,D]=r({top:0,left:0,width:0,direction:"down"}),F=o(null),N=o(null),[H,V]=r(null),[Q,j]=r(null),G=void 0!==a,U=G?a:R,X=e.flatMap(e=>e&&Array.isArray(e.options)?e.options:[e]).find(e=>("string"==typeof e?e:e.value)===U),K=X?"string"==typeof X?X:X.label:"",q=""!==U&&null!=U,J="floating"===c,Y="top"===c,Z="color"===g,$=J?Zn[u]||Zn.medium:Yn[u]||Yn.medium,_=n(e=>{G||E(e),s?.(e),O(!1),N.current?.focus()},[G,s]),ee=n(()=>{if(!N.current)return{top:0,left:0,width:0};const e=N.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top,o=t>=240||t>=r?"down":"up";return{top:"down"===o?e.bottom+4:void 0,bottom:"up"===o?window.innerHeight-e.top+4:void 0,left:e.left,width:e.width,direction:o}},[]),te=n(()=>{S||O(e=>(e||D(ee()),!e))},[S,ee]);i(()=>{if(!P)return;const e=e=>{!F.current||F.current.contains(e.target)||e.target.closest("[data-select-dropdown]")||O(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[P]),i(()=>{if(!P||!N.current)return;const e=N.current.closest("[data-theme]"),t=N.current.closest("[data-surface]");V(e?.getAttribute("data-theme")||null),j(t?.getAttribute("data-surface")||null);const r=()=>D(ee());return window.addEventListener("scroll",r,!0),window.addEventListener("resize",r),()=>{window.removeEventListener("scroll",r,!0),window.removeEventListener("resize",r)}},[P,ee]);const re=o(null),oe=n(e=>{const t=re.current;if(!t)return;const r=t.querySelectorAll('[role="option"]');if(!r.length)return;const o=t.querySelector('[role="option"]:focus');let n=Array.prototype.indexOf.call(r,o);n="down"===e?n<r.length-1?n+1:0:n>0?n-1:r.length-1,r[n].focus()},[]);i(()=>{P&&requestAnimationFrame(()=>{const e=re.current;if(!e)return;const t=e.querySelector('[aria-selected="true"]'),r=e.querySelector('[role="option"]');(t||r)?.focus()})},[P]);const ne=P?ye.createPortal(de(h,{ref:re,"data-select-dropdown":!0,"data-theme":H||void 0,role:"listbox","aria-label":d||"Options",sx:{position:"fixed",top:W.top??"unset",bottom:W.bottom??"unset",left:W.left,width:W.width+"px",backgroundColor:"var(--Hover)",border:"1px solid var(--Buttons-Default-Border)",borderRadius:"var(--Dropdown-Frame-Radius, var(--Input-Radius, var(--Style-Border-Radius, 4px)))",boxShadow:"none",zIndex:99999,maxHeight:"240px",overflowY:"auto",py:.5},children:(()=>{const r=(e,r,o)=>{const n="string"==typeof e?e:e.value,i="string"==typeof e?e:e.label,a="object"==typeof e?e.color:null,l=n===U,s=function(e,t,r){const o=Jn(r||"default");return t?"solid"===e?{backgroundColor:"var(--Buttons-"+o+"-Button)",color:"var(--Buttons-"+o+"-Text)",border:"1px solid var(--Buttons-"+o+"-Border)",fontWeight:600}:"light"===e?{backgroundColor:"var(--Buttons-"+o+"-Light-Button)",color:"var(--Buttons-"+o+"-Light-Text)",border:"1px solid var(--Buttons-"+o+"-Light-Border)",fontWeight:600}:{backgroundColor:"var(--Buttons-"+o+"-Button)",color:"var(--Buttons-"+o+"-Text)",border:"1px solid var(--Buttons-"+o+"-Border)",fontWeight:600}:{color:"var(--Text)",backgroundColor:"transparent",border:"1px solid transparent"}}(f,l,T),d=r===o-1;return ce(t.Fragment,{children:[ce(h,{role:"option",tabIndex:-1,"aria-selected":l,"aria-label":Z&&!v?i:void 0,onClick:()=>_(n),onKeyDown:e=>((e,t)=>{if("Enter"===e.key||" "===e.key)return e.preventDefault(),void _(t);"ArrowDown"===e.key&&(e.preventDefault(),oe("down")),"ArrowUp"===e.key&&(e.preventDefault(),oe("up")),"Escape"===e.key&&(O(!1),N.current?.focus())})(e,n),sx:{display:"flex",alignItems:"center",gap:1,px:1.5,py:0,mx:.5,my:"1px",minHeight:$.height,cursor:"pointer",fontSize:$.fontSize,fontFamily:"inherit",borderRadius:"4px",outline:"none",...s,transition:"background-color 0.1s ease","&:hover":l?{}:{backgroundColor:"var(--Buttons-"+I+"-Hover)",color:"var(--Buttons-"+I+"-Text)"},"&:active":l?{}:{backgroundColor:"var(--Buttons-"+I+"-Pressed)",color:"var(--Buttons-"+I+"-Text)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:[Z&&a&&de(h,{sx:{height:"calc("+$.height+" - 8px)",width:"calc("+$.height+" - 8px)",borderRadius:"var(--Input-Swatch-Radius, var(--Button-Radius))",backgroundColor:a,border:"1px solid "+(l?"var(--Buttons-"+I+"-Border)":"var(--Border)"),flexShrink:0}}),(!Z||v)&&de(ao,{style:{flex:1,color:"inherit",fontWeight:"inherit"},children:i}),l&&de(jo,{size:"small",sx:{opacity:.6,flexShrink:0},children:de(he,{})})]}),b&&!d&&de(h,{"aria-hidden":"true",sx:{height:"1px",backgroundColor:"var(--Border)",mx:1,my:.25}})]},n)};return e.map((o,n)=>{if(o&&Array.isArray(o.options)){const e=o.options;return ce(t.Fragment,{children:[de(h,{role:"presentation",sx:{px:1.5,pt:0===n?.75:1.25,pb:.5,fontSize:"11px",fontFamily:"inherit",fontWeight:700,letterSpacing:"0.06em",textTransform:"uppercase",color:"var(--Text-Quiet)"},children:o.label}),e.map((t,o)=>r(t,o,e.length))]},"group-"+(o.label||n))}return r(o,n,e.length)})})()}),document.body):null;return ce(h,{ref:F,className:"select-wrapper select-"+u+" select-label-"+c+" select-style-"+f+" select-variant-"+p+(P?" select-open":"")+(S?" select-disabled":"")+(B?" "+B:""),sx:{position:"relative",width:k?"100%":"auto",display:"inline-block",fontFamily:"inherit",...w},...C,children:[Y&&d&&de("small"===u?ao:co,{component:"label",style:{display:"block",marginBottom:"6px",color:S?"var(--Quiet)":"var(--Text)",fontWeight:500,opacity:S?.6:1},children:d}),de(h,{sx:{border:"1px solid "+A,borderRadius:"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease",boxShadow:"none","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{children:ce(h,{ref:N,component:"button",type:"button",role:"combobox","aria-expanded":P,"aria-haspopup":"listbox","aria-label":d||x,tabIndex:S?-1:0,onClick:te,onKeyDown:e=>"Escape"===e.key?(O(!1),void N.current?.focus()):"Enter"===e.key||" "===e.key?(e.preventDefault(),void te()):P||"ArrowDown"!==e.key&&"ArrowUp"!==e.key?(P&&"ArrowDown"===e.key&&(e.preventDefault(),oe("down")),void(P&&"ArrowUp"===e.key&&(e.preventDefault(),oe("up")))):(e.preventDefault(),void O(!0)),onFocus:()=>M(!0),onBlur:()=>M(!1),sx:{display:"flex",alignItems:"center",gap:1,width:"100%",minWidth:140,height:$.height,padding:$.padding,backgroundColor:"var(--Hover)",border:"none",borderRadius:0,color:q||P?z:"var(--Quiet)",fontSize:$.fontSize,fontFamily:"inherit",cursor:S?"not-allowed":"pointer",opacity:S?.5:1,outline:"none",textAlign:"left",position:"relative",transition:"color 0.15s ease"},children:[y&&de(h,{sx:{display:"flex",alignItems:"center",flexShrink:0,color:"var(--Text-Quiet)"},children:y}),J&&d&&de(h,{sx:{position:"absolute",top:q||P?"6px":"50%",left:($.leftPad||14)+(y?32:0)+"px",transform:q||P?"scale(0.75)":"translateY(-50%)",transformOrigin:"top left",color:P?z:"var(--Quiet)",fontSize:$.fontSize,fontWeight:400,pointerEvents:"none",transition:"top 0.15s ease, transform 0.15s ease, color 0.15s ease"},children:d}),de(h,{sx:{flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",...J&&{mt:q||P?"8px":0}},children:Z&&q?ce(h,{sx:{display:"flex",alignItems:"center",gap:1},children:[de(h,{sx:{height:"calc("+$.height+" - 8px)",width:"calc("+$.height+" - 8px)",borderRadius:"var(--Input-Swatch-Radius, var(--Button-Radius))",backgroundColor:X&&"string"!=typeof X&&X.color||"transparent",border:"1px solid var(--Border)",flexShrink:0}}),v&&de(ao,{style:{color:"inherit",padding:0},children:K})]}):de(ao,{style:{color:"inherit",padding:0},children:q?K:J&&d?"":x})}),de(Se,{sx:{fontSize:($.iconSize||18)+"px",color:"var(--Text-Quiet)",transform:P?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease",flexShrink:0}})]})})}),ne]})}const _n={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ei={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ti={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ri={small:{px:"10px",py:"6px",fontSize:"13px",iconSize:"16px",gap:"4px",indicatorThickness:"3px",minHeight:"32px"},medium:{px:"14px",py:"8px",fontSize:"14px",iconSize:"18px",gap:"6px",indicatorThickness:"3px",minHeight:"40px"},large:{px:"18px",py:"10px",fontSize:"16px",iconSize:"20px",gap:"8px",indicatorThickness:"3px",minHeight:"48px"}},oi=s({value:0,setValue:()=>{},variant:"standard",color:"primary",size:"medium",orientation:"horizontal",scrollable:!1,tabsId:""}),ni=()=>l(oi);function ii({children:e,defaultValue:t=0,value:o,onChange:i,variant:l="standard",color:s="primary",size:d="medium",orientation:c="horizontal",scrollable:u=!1,className:p="",sx:m={},...f}){const[g,x]=r(t),b=void 0!==o,v=b?o:g,y=a(),S=n(e=>{b||x(e),i?.(e)},[b,i]);return de(oi.Provider,{value:{value:v,setValue:S,variant:l,color:s,size:d,orientation:c,scrollable:u,tabsId:y},children:de(h,{className:"tabs tabs-"+c+" tabs-"+d+" tabs-"+l+("standard"!==l?" tabs-"+s:"")+(u?" tabs-scrollable":"")+" "+p,sx:{display:"flex",flexDirection:"horizontal"===c?"column":"row",width:"100%",overflow:"hidden",...m},...f,children:e})})}function ai({children:e,rounded:a=!1,className:l="",sx:s={},...d}){const{variant:c,color:u,size:p,orientation:m,scrollable:f,tabsId:g}=ni(),x=o(null),b=o(null),[v,y]=r(!1),[S,k]=r(!1),B="horizontal"===m,w="standard"===c,C="light"===c,T="dark"===c,I=w?void 0:"solid"===c?_n[u]:C?ei[u]:T?ti[u]:void 0,A=w?void 0:T?"Surface-Dimmest":C?"Surface-Brightest":"Surface",z=n(()=>{const e=b.current;e&&f&&B&&(y(e.scrollLeft>1),k(e.scrollLeft<e.scrollWidth-e.clientWidth-1))},[f,B]);i(()=>{z();const e=b.current;if(!e||!f)return;e.addEventListener("scroll",z,{passive:!0});const t=new ResizeObserver(z);return t.observe(e),()=>{e.removeEventListener("scroll",z),t.disconnect()}},[f,z]);const R=e=>{const t=b.current;if(!t)return;const r=.6*t.clientWidth;t.scrollBy({left:e*r,behavior:"smooth"})},E={display:"inline-flex",alignItems:"center",justifyContent:"center",width:"28px",minWidth:"28px",border:"none",backgroundColor:"transparent",color:"var(--Text-Quiet)",cursor:"pointer",fontSize:"16px",fontFamily:"inherit",lineHeight:1,flexShrink:0,transition:"color 0.15s ease, background-color 0.15s ease","&:hover":{color:"var(--Text)",backgroundColor:"var(--Hover)"},"&:active":{backgroundColor:"var(--Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},"&:disabled":{opacity:.3,cursor:"default","&:hover":{backgroundColor:"transparent",color:"var(--Text-Quiet)"}}},P=t.Children.toArray(e).filter(t.isValidElement).map((e,r)=>t.cloneElement(e,{_index:r,key:e.key||r}));return ce(h,{ref:x,"data-theme":I||void 0,"data-surface":A||void 0,className:"tab-list tab-list-"+c+" tab-list-"+p+" tab-list-"+m+(f?" tab-list-scrollable":"")+" "+l,onKeyDown:e=>{const t=f?b.current:x.current,r=t?.querySelectorAll('[role="tab"]:not([aria-disabled="true"])');if(!r?.length)return;const o=Array.from(r).indexOf(document.activeElement);if(o<0)return;const n=B?"ArrowRight":"ArrowDown",i=B?"ArrowLeft":"ArrowUp";if(e.key===n){e.preventDefault();const t=r[(o+1)%r.length];t.focus(),f&&t.scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"})}else if(e.key===i){e.preventDefault();const t=r[(o-1+r.length)%r.length];t.focus(),f&&t.scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"})}else"Home"===e.key?(e.preventDefault(),r[0].focus(),f&&r[0].scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"})):"End"===e.key&&(e.preventDefault(),r[r.length-1].focus(),f&&r[r.length-1].scrollIntoView({block:"nearest",inline:"nearest",behavior:"smooth"}))},sx:{display:"flex",flexDirection:B?"row":"column",gap:0,position:"relative",backgroundColor:"var(--Background)",padding:"4px",overflow:"hidden",borderRadius:a?"var(--Style-Border-Radius)":0,...s},...d,children:[f&&B&&de(h,{component:"button","aria-label":"Scroll tabs left",onClick:()=>R(-1),disabled:!v,className:"tab-list-scroll-btn tab-list-scroll-btn-left",sx:E,children:"‹"}),de(h,f&&B?{ref:b,role:"tablist","aria-orientation":m,className:"tab-list-scroll-container",sx:{display:"flex",flexDirection:"row",overflowX:"auto",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"},flex:1,minWidth:0},children:P}:{ref:b,role:"tablist","aria-orientation":m,sx:{display:"flex",flexDirection:B?"row":"column",flex:1},children:P}),f&&B&&de(h,{component:"button","aria-label":"Scroll tabs right",onClick:()=>R(1),disabled:!S,className:"tab-list-scroll-btn tab-list-scroll-btn-right",sx:E,children:"›"})]})}function li({children:e,value:t,_index:r=0,disabled:o=!1,startDecorator:n,endDecorator:i,iconOnly:a=!1,className:l="",sx:s={},...d}){const{value:c,setValue:u,variant:p,color:m,size:f,orientation:g,tabsId:x}=ni(),b=ri[f]||ri.medium,v="horizontal"===g,y="standard"===p,S="light"===p,k="dark"===p,B=void 0!==t?t:r,w=c===B,C=y?"var(--Buttons-"+({default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"}[m]||"Default")+"-Border)":"var(--Text)";return ce(h,{component:"button",role:"tab",id:"tab-"+x+"-"+B,"data-theme":(y?void 0:"solid"===p?_n[m]:S?ei[m]:k?ti[m]:void 0)||void 0,"data-surface":(y?void 0:k?"Surface-Dimmest":S?"Surface-Brightest":"Surface")||void 0,"aria-selected":w,"aria-controls":"tabpanel-"+x+"-"+B,"aria-disabled":o||void 0,tabIndex:w?0:-1,onClick:()=>{o||u(B)},className:"tab tab-"+f+(w?" tab-selected":"")+(o?" tab-disabled":"")+(a?" tab-icon-only":"")+" "+l,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",gap:b.gap,padding:a?"calc("+b.py+" + 4px) "+b.py+" "+b.py:"calc("+b.py+" + 4px) "+b.px+" "+b.py+" "+b.px,minHeight:b.minHeight,fontSize:b.fontSize,fontFamily:"inherit",fontWeight:500,lineHeight:1.3,color:w?"var(--Text)":"var(--Quiet)",backgroundColor:"transparent",border:"none",borderBottom:v?w?b.indicatorThickness+" solid "+C:b.indicatorThickness+" solid transparent":"none",borderRight:v?"none":w?b.indicatorThickness+" solid "+C:b.indicatorThickness+" solid transparent",cursor:o?"not-allowed":"pointer",opacity:o?.5:1,position:"relative",outline:"none",transition:"color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease",flexShrink:0,whiteSpace:"nowrap",...!o&&{"&:hover":{backgroundColor:"var(--Hover)"},"&:active":{backgroundColor:"var(--Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},...s},...d,children:[n&&de(h,{className:"tab-start-decorator",sx:{display:"inline-flex",fontSize:b.iconSize,lineHeight:1,flexShrink:0},children:n}),!a&&e&&de("small"===f?bo:ao,{style:{color:"inherit",fontWeight:"inherit"},children:e}),i&&de(h,{className:"tab-end-decorator",sx:{display:"inline-flex",fontSize:b.iconSize,lineHeight:1,flexShrink:0},children:i})]})}function si({children:e,value:t,className:r="",sx:o={},...n}){const{value:i,size:a,tabsId:l}=ni();return i===t?de(h,{role:"tabpanel",id:"tabpanel-"+l+"-"+t,"aria-labelledby":"tab-"+l+"-"+t,className:"tab-panel tab-panel-"+a+" "+r,sx:{paddingTop:"16px",fontSize:(ri[a]||ri.medium).fontSize,fontFamily:"inherit",color:"var(--Text)",...o},...n,children:e}):null}const di=t.forwardRef(function({theme:e=null,surface:t="Surface",children:r,minHeight:o=160,sx:n={}},i){return de(h,{ref:i,"data-theme":e||void 0,"data-surface":t,sx:{p:4,display:"flex",alignItems:"center",justifyContent:"center",minHeight:o,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)",...n},children:r})}),ci="__null__",ui=[{label:"Default",value:ci},{label:"Primary",value:"Primary"},{label:"Secondary",value:"Secondary"},{label:"Tertiary",value:"Tertiary"},{label:"Neutral",value:"Neutral"},{label:"Info",value:"Info"},{label:"Success",value:"Success"},{label:"Warning",value:"Warning"},{label:"Error",value:"Error"}],pi=["Surface-Dimmest","Surface-Dim","Surface","Surface-Bright","Surface-Brightest","Container","Container-Highest","Container-High","Container-Low","Container-Lowest"];function hi({theme:e=null,onThemeChange:t,surface:r="Surface",onSurfaceChange:o,surfaces:n=pi,size:i="small"}){const a=n.map(e=>({value:e,label:e}));return ce(B,{direction:"row",spacing:1,sx:{alignItems:"center"},children:[de(h,{sx:{width:160},children:de($n,{options:ui,value:e??ci,onChange:e=>t?.(e===ci?null:e),labelPosition:"none",size:i,variant:"outline",color:"default","aria-label":"Background theme",fullWidth:!0})}),de(h,{sx:{width:180},children:de($n,{options:a,value:r,onChange:e=>o?.(e),labelPosition:"none",size:i,variant:"outline",color:"default","aria-label":"Surface",fullWidth:!0})})]})}function mi(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var fi,gi={exports:{}},xi={exports:{}},bi={};var vi,yi,Si,ki,Bi,wi,Ci,Ti,Ii,Ai,zi,Ri,Ei,Pi,Oi={};
2
2
  /** @license React v16.13.1
3
3
  * react-is.development.js
4
4
  *
@@ -6,12 +6,12 @@ import*as e from"react";import t,{useState as r,useRef as o,useCallback as n,use
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */function Pi(){return bi||(bi=1,"production"===process.env.NODE_ENV?fi.exports=function(){if(hi)return gi;hi=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,o=e?Symbol.for("react.fragment"):60107,n=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,s=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,c=e?Symbol.for("react.forward_ref"):60112,u=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:switch(e=e.type){case s:case d:case o:case i:case n:case u:return e;default:switch(e=e&&e.$$typeof){case l:case c:case m:case h:case a:return e;default:return p}}case r:return p}}}function y(e){return v(e)===d}return gi.AsyncMode=s,gi.ConcurrentMode=d,gi.ContextConsumer=l,gi.ContextProvider=a,gi.Element=t,gi.ForwardRef=c,gi.Fragment=o,gi.Lazy=m,gi.Memo=h,gi.Portal=r,gi.Profiler=i,gi.StrictMode=n,gi.Suspense=u,gi.isAsyncMode=function(e){return y(e)||v(e)===s},gi.isConcurrentMode=y,gi.isContextConsumer=function(e){return v(e)===l},gi.isContextProvider=function(e){return v(e)===a},gi.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},gi.isForwardRef=function(e){return v(e)===c},gi.isFragment=function(e){return v(e)===o},gi.isLazy=function(e){return v(e)===m},gi.isMemo=function(e){return v(e)===h},gi.isPortal=function(e){return v(e)===r},gi.isProfiler=function(e){return v(e)===i},gi.isStrictMode=function(e){return v(e)===n},gi.isSuspense=function(e){return v(e)===u},gi.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===d||e===i||e===n||e===u||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===h||e.$$typeof===a||e.$$typeof===l||e.$$typeof===c||e.$$typeof===g||e.$$typeof===x||e.$$typeof===b||e.$$typeof===f)},gi.typeOf=v,gi}():fi.exports=(xi||(xi=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,o=e?Symbol.for("react.fragment"):60107,n=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,s=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,c=e?Symbol.for("react.forward_ref"):60112,u=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:var f=e.type;switch(f){case s:case d:case o:case i:case n:case u:return f;default:var g=f&&f.$$typeof;switch(g){case l:case c:case m:case h:case a:return g;default:return p}}case r:return p}}}var y=s,S=d,k=l,B=a,w=t,C=c,T=o,I=m,A=h,z=r,R=i,E=n,P=u,O=!1;function L(e){return v(e)===d}Ei.AsyncMode=y,Ei.ConcurrentMode=S,Ei.ContextConsumer=k,Ei.ContextProvider=B,Ei.Element=w,Ei.ForwardRef=C,Ei.Fragment=T,Ei.Lazy=I,Ei.Memo=A,Ei.Portal=z,Ei.Profiler=R,Ei.StrictMode=E,Ei.Suspense=P,Ei.isAsyncMode=function(e){return O||(O=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),L(e)||v(e)===s},Ei.isConcurrentMode=L,Ei.isContextConsumer=function(e){return v(e)===l},Ei.isContextProvider=function(e){return v(e)===a},Ei.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Ei.isForwardRef=function(e){return v(e)===c},Ei.isFragment=function(e){return v(e)===o},Ei.isLazy=function(e){return v(e)===m},Ei.isMemo=function(e){return v(e)===h},Ei.isPortal=function(e){return v(e)===r},Ei.isProfiler=function(e){return v(e)===i},Ei.isStrictMode=function(e){return v(e)===n},Ei.isSuspense=function(e){return v(e)===u},Ei.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===d||e===i||e===n||e===u||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===h||e.$$typeof===a||e.$$typeof===l||e.$$typeof===c||e.$$typeof===g||e.$$typeof===x||e.$$typeof===b||e.$$typeof===f)},Ei.typeOf=v}()),Ei)),fi.exports}
9
+ */function Li(){return yi||(yi=1,"production"===process.env.NODE_ENV?xi.exports=function(){if(fi)return bi;fi=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,o=e?Symbol.for("react.fragment"):60107,n=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,s=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,c=e?Symbol.for("react.forward_ref"):60112,u=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:switch(e=e.type){case s:case d:case o:case i:case n:case u:return e;default:switch(e=e&&e.$$typeof){case l:case c:case m:case h:case a:return e;default:return p}}case r:return p}}}function y(e){return v(e)===d}return bi.AsyncMode=s,bi.ConcurrentMode=d,bi.ContextConsumer=l,bi.ContextProvider=a,bi.Element=t,bi.ForwardRef=c,bi.Fragment=o,bi.Lazy=m,bi.Memo=h,bi.Portal=r,bi.Profiler=i,bi.StrictMode=n,bi.Suspense=u,bi.isAsyncMode=function(e){return y(e)||v(e)===s},bi.isConcurrentMode=y,bi.isContextConsumer=function(e){return v(e)===l},bi.isContextProvider=function(e){return v(e)===a},bi.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},bi.isForwardRef=function(e){return v(e)===c},bi.isFragment=function(e){return v(e)===o},bi.isLazy=function(e){return v(e)===m},bi.isMemo=function(e){return v(e)===h},bi.isPortal=function(e){return v(e)===r},bi.isProfiler=function(e){return v(e)===i},bi.isStrictMode=function(e){return v(e)===n},bi.isSuspense=function(e){return v(e)===u},bi.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===d||e===i||e===n||e===u||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===h||e.$$typeof===a||e.$$typeof===l||e.$$typeof===c||e.$$typeof===g||e.$$typeof===x||e.$$typeof===b||e.$$typeof===f)},bi.typeOf=v,bi}():xi.exports=(vi||(vi=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,o=e?Symbol.for("react.fragment"):60107,n=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,s=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,c=e?Symbol.for("react.forward_ref"):60112,u=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,h=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,f=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:var f=e.type;switch(f){case s:case d:case o:case i:case n:case u:return f;default:var g=f&&f.$$typeof;switch(g){case l:case c:case m:case h:case a:return g;default:return p}}case r:return p}}}var y=s,S=d,k=l,B=a,w=t,C=c,T=o,I=m,A=h,z=r,R=i,E=n,P=u,O=!1;function L(e){return v(e)===d}Oi.AsyncMode=y,Oi.ConcurrentMode=S,Oi.ContextConsumer=k,Oi.ContextProvider=B,Oi.Element=w,Oi.ForwardRef=C,Oi.Fragment=T,Oi.Lazy=I,Oi.Memo=A,Oi.Portal=z,Oi.Profiler=R,Oi.StrictMode=E,Oi.Suspense=P,Oi.isAsyncMode=function(e){return O||(O=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),L(e)||v(e)===s},Oi.isConcurrentMode=L,Oi.isContextConsumer=function(e){return v(e)===l},Oi.isContextProvider=function(e){return v(e)===a},Oi.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Oi.isForwardRef=function(e){return v(e)===c},Oi.isFragment=function(e){return v(e)===o},Oi.isLazy=function(e){return v(e)===m},Oi.isMemo=function(e){return v(e)===h},Oi.isPortal=function(e){return v(e)===r},Oi.isProfiler=function(e){return v(e)===i},Oi.isStrictMode=function(e){return v(e)===n},Oi.isSuspense=function(e){return v(e)===u},Oi.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===d||e===i||e===n||e===u||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===h||e.$$typeof===a||e.$$typeof===l||e.$$typeof===c||e.$$typeof===g||e.$$typeof===x||e.$$typeof===b||e.$$typeof===f)},Oi.typeOf=v}()),Oi)),xi.exports}
10
10
  /*
11
11
  object-assign
12
12
  (c) Sindre Sorhus
13
13
  @license MIT
14
- */function Oi(){if(yi)return vi;yi=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;return vi=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(e){o[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}()?Object.assign:function(o,n){for(var i,a,l=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(o),s=1;s<arguments.length;s++){for(var d in i=Object(arguments[s]))t.call(i,d)&&(l[d]=i[d]);if(e){a=e(i);for(var c=0;c<a.length;c++)r.call(i,a[c])&&(l[a[c]]=i[a[c]])}}return l},vi}function Li(){if(ki)return Si;ki=1;return Si="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function Mi(){return wi?Bi:(wi=1,Bi=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var Wi=Pi();mi.exports=function(){if(Ai)return Ii;Ai=1;var e=Pi(),t=Oi(),r=Li(),o=Mi(),n=function(){if(Ti)return Ci;Ti=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=Li(),r={},o=Mi();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function n(n,i,a,l,s){if("production"!==process.env.NODE_ENV)for(var d in n)if(o(n,d)){var c;try{if("function"!=typeof n[d]){var u=Error((l||"React class")+": "+a+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof n[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw u.name="Invariant Violation",u}c=n[d](i,d,l,a,null,t)}catch(e){c=e}if(!c||c instanceof Error||e((l||"React class")+": type specification of "+a+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof c+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),c instanceof Error&&!(c.message in r)){r[c.message]=!0;var p=s?s():"";e("Failed "+a+" type: "+c.message+(null!=p?p:""))}}}return n.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(r={})},Ci=n}(),i=function(){};function a(){return null}return"production"!==process.env.NODE_ENV&&(i=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),Ii=function(l,s){var d="function"==typeof Symbol&&Symbol.iterator,c="<<anonymous>>",u={array:f("array"),bigint:f("bigint"),bool:f("boolean"),func:f("function"),number:f("number"),object:f("object"),string:f("string"),symbol:f("symbol"),any:m(a),arrayOf:function(e){return m(function(t,o,n,i,a){if("function"!=typeof e)return new h("Property `"+a+"` of component `"+n+"` has invalid PropType notation inside arrayOf.");var l=t[o];if(!Array.isArray(l))return new h("Invalid "+i+" `"+a+"` of type `"+b(l)+"` supplied to `"+n+"`, expected an array.");for(var s=0;s<l.length;s++){var d=e(l,s,n,i,a+"["+s+"]",r);if(d instanceof Error)return d}return null})},element:m(function(e,t,r,o,n){var i=e[t];return l(i)?null:new h("Invalid "+o+" `"+n+"` of type `"+b(i)+"` supplied to `"+r+"`, expected a single ReactElement.")}),elementType:m(function(t,r,o,n,i){var a=t[r];return e.isValidElementType(a)?null:new h("Invalid "+n+" `"+i+"` of type `"+b(a)+"` supplied to `"+o+"`, expected a single ReactElement type.")}),instanceOf:function(e){return m(function(t,r,o,n,i){if(!(t[r]instanceof e)){var a=e.name||c;return new h("Invalid "+n+" `"+i+"` of type `"+((l=t[r]).constructor&&l.constructor.name?l.constructor.name:c)+"` supplied to `"+o+"`, expected instance of `"+a+"`.")}var l;return null})},node:m(function(e,t,r,o,n){return x(e[t])?null:new h("Invalid "+o+" `"+n+"` supplied to `"+r+"`, expected a ReactNode.")}),objectOf:function(e){return m(function(t,n,i,a,l){if("function"!=typeof e)return new h("Property `"+l+"` of component `"+i+"` has invalid PropType notation inside objectOf.");var s=t[n],d=b(s);if("object"!==d)return new h("Invalid "+a+" `"+l+"` of type `"+d+"` supplied to `"+i+"`, expected an object.");for(var c in s)if(o(s,c)){var u=e(s,c,i,a,l+"."+c,r);if(u instanceof Error)return u}return null})},oneOf:function(e){return Array.isArray(e)?m(function(t,r,o,n,i){for(var a=t[r],l=0;l<e.length;l++)if(p(a,e[l]))return null;var s=JSON.stringify(e,function(e,t){return"symbol"===v(t)?String(t):t});return new h("Invalid "+n+" `"+i+"` of value `"+String(a)+"` supplied to `"+o+"`, expected one of "+s+".")}):("production"!==process.env.NODE_ENV&&i(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),a)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&i("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var t=0;t<e.length;t++){var n=e[t];if("function"!=typeof n)return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+y(n)+" at index "+t+"."),a}return m(function(t,n,i,a,l){for(var s=[],d=0;d<e.length;d++){var c=(0,e[d])(t,n,i,a,l,r);if(null==c)return null;c.data&&o(c.data,"expectedType")&&s.push(c.data.expectedType)}return new h("Invalid "+a+" `"+l+"` supplied to `"+i+"`"+(s.length>0?", expected one of type ["+s.join(", ")+"]":"")+".")})},shape:function(e){return m(function(t,o,n,i,a){var l=t[o],s=b(l);if("object"!==s)return new h("Invalid "+i+" `"+a+"` of type `"+s+"` supplied to `"+n+"`, expected `object`.");for(var d in e){var c=e[d];if("function"!=typeof c)return g(n,i,a,d,v(c));var u=c(l,d,n,i,a+"."+d,r);if(u)return u}return null})},exact:function(e){return m(function(n,i,a,l,s){var d=n[i],c=b(d);if("object"!==c)return new h("Invalid "+l+" `"+s+"` of type `"+c+"` supplied to `"+a+"`, expected `object`.");var u=t({},n[i],e);for(var p in u){var m=e[p];if(o(e,p)&&"function"!=typeof m)return g(a,l,s,p,v(m));if(!m)return new h("Invalid "+l+" `"+s+"` key `"+p+"` supplied to `"+a+"`.\nBad object: "+JSON.stringify(n[i],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var f=m(d,p,a,l,s+"."+p,r);if(f)return f}return null})}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function h(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function m(e){if("production"!==process.env.NODE_ENV)var t={},o=0;function n(n,a,l,d,u,p,m){if(d=d||c,p=p||l,m!==r){if(s){var f=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw f.name="Invariant Violation",f}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var g=d+":"+l;!t[g]&&o<3&&(i("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+d+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),t[g]=!0,o++)}}return null==a[l]?n?null===a[l]?new h("The "+u+" `"+p+"` is marked as required in `"+d+"`, but its value is `null`."):new h("The "+u+" `"+p+"` is marked as required in `"+d+"`, but its value is `undefined`."):null:e(a,l,d,u,p)}var a=n.bind(null,!1);return a.isRequired=n.bind(null,!0),a}function f(e){return m(function(t,r,o,n,i,a){var l=t[r];return b(l)!==e?new h("Invalid "+n+" `"+i+"` of type `"+v(l)+"` supplied to `"+o+"`, expected `"+e+"`.",{expectedType:e}):null})}function g(e,t,r,o,n){return new h((e||"React class")+": "+t+" type `"+r+"."+o+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+n+"`.")}function x(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(x);if(null===e||l(e))return!0;var t=function(e){var t=e&&(d&&e[d]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var r,o=t.call(e);if(t!==e.entries){for(;!(r=o.next()).done;)if(!x(r.value))return!1}else for(;!(r=o.next()).done;){var n=r.value;if(n&&!x(n[1]))return!1}return!0;default:return!1}}function b(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function v(e){if(null==e)return""+e;var t=b(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function y(e){var t=v(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return h.prototype=Error.prototype,u.checkPropTypes=n,u.resetWarningCache=n.resetWarningCache,u.PropTypes=u,u},Ii}()(Wi.isElement,!0)}else mi.exports=function(){if(Ri)return zi;Ri=1;var e=Li();function t(){}function r(){}return r.resetWarningCache=t,zi=function(){function o(t,r,o,n,i,a){if(a!==e){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function n(){return o}o.isRequired=o;var i={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:n,element:o,elementType:o,instanceOf:n,node:o,objectOf:n,oneOf:n,oneOfType:n,shape:n,exact:n,checkPropTypes:r,resetWarningCache:t};return i.PropTypes=i,i},zi}()();var Di=pi(mi.exports);function Fi({code:e,label:t="Copy code"}){const[o,n]=r(!1);return de(w,{title:o?"Copied!":t,children:de(C,{size:"small",onClick:async()=>{try{await navigator.clipboard.writeText(e),n(!0),setTimeout(()=>n(!1),2e3)}catch(e){console.error("Copy failed:",e)}},"aria-label":o?"Copied":t,sx:{color:o?"var(--Icons-Success, var(--Text))":"var(--Quiet)","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(o?he:pe,{fontSize:"small"})})})}Fi.propTypes={code:Di.string.isRequired,label:Di.string};function Ni({code:e="",language:t="JSX",showCopy:r=!0,showHeader:o=!0,maxHeight:n,wrap:i=!1,sx:a={},...l}){return ce(h,{"data-theme":"Neutral","data-surface":"Surface-Dimmest",sx:{backgroundColor:"var(--Background)",borderRadius:"min(var(--Card-Radius, var(--Style-Border-Radius)), 12px)",overflow:"hidden",...a},...l,children:[o&&(t||r)&&ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:1,px:2,py:1,borderBottom:"1px solid var(--Border)",minHeight:40},children:[de(bo,{color:"quiet",children:t}),r&&e?de(Fi,{code:e}):null]}),de(h,{sx:{p:2,overflow:"auto",maxHeight:n},children:de(h,{component:"pre",sx:{margin:0,fontFamily:"inherit"},children:de(h,{component:"code",sx:{fontFamily:"ui-monospace, SFMono-Regular, Menlo, Consolas, monospace",fontSize:"13px",lineHeight:1.6,color:"var(--Text)",whiteSpace:i?"pre-wrap":"pre",wordBreak:i?"break-word":"normal",display:"block"},children:e})})})]})}function Hi(e){if(!e)return null;const t=e.trim();if(/^#[0-9a-f]{3}$/i.test(t))return{r:parseInt(t[1]+t[1],16),g:parseInt(t[2]+t[2],16),b:parseInt(t[3]+t[3],16),a:1};if(/^#[0-9a-f]{6}$/i.test(t))return{r:parseInt(t.substring(1,3),16),g:parseInt(t.substring(3,5),16),b:parseInt(t.substring(5,7),16),a:1};if(/^#[0-9a-f]{8}$/i.test(t))return{r:parseInt(t.substring(1,3),16),g:parseInt(t.substring(3,5),16),b:parseInt(t.substring(5,7),16),a:parseInt(t.substring(7,9),16)/255};const r=t.match(/rgba?\(\s*([\d.]+)[,\s]+([\d.]+)[,\s]+([\d.]+)(?:[,\s/]+([\d.]+%?))?\s*\)/);if(r){let e=1;return void 0!==r[4]&&(e=r[4].endsWith("%")?parseFloat(r[4])/100:parseFloat(r[4])),{r:Math.round(parseFloat(r[1])),g:Math.round(parseFloat(r[2])),b:Math.round(parseFloat(r[3])),a:e}}return null}function Vi(e,t){if(!e||!t)return e||t;if(e.a>=1)return e;const r=e.a;return{r:Math.round(e.r*r+t.r*(1-r)),g:Math.round(e.g*r+t.g*(1-r)),b:Math.round(e.b*r+t.b*(1-r)),a:1}}function Qi(e){const t=e=>e<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4);return.2126*t(e.r/255)+.7152*t(e.g/255)+.0722*t(e.b/255)}function ji(e,t,r){const o=Hi(e),n=Hi(t),i=Hi(r);if(!o||!n)return null;const a=i?Vi(n,i):n.a<1?null:n;if(!a)return null;const l=Vi(o,a);if(!l)return null;const s=Qi(l),d=Qi(a);return((Math.max(s,d)+.05)/(Math.min(s,d)+.05)).toFixed(2)}function Gi(e){return"undefined"==typeof window?null:getComputedStyle(document.documentElement).getPropertyValue(e).trim()}Ni.propTypes={code:Di.string,language:Di.string,showCopy:Di.bool,showHeader:Di.bool,maxHeight:Di.oneOfType([Di.number,Di.string]),wrap:Di.bool,sx:Di.object};const Ui={"display-large":"Display Large","display-medium":"Display Medium","display-small":"Display Small",h1:"H1",h2:"H2",h3:"H3",h4:"H4",h5:"H5",h6:"H6","subtitle-small":"Subtitle Small",subtitle:"Subtitle Medium","subtitle-large":"Subtitle Large","body-small":"Body Small","body-small-semibold":"Body Small Semibold",body:"Body Medium","body-semibold":"Body Medium Semibold","body-large":"Body Large","body-large-semibold":"Body Large Semibold",label:"Label","label-small":"Label Small","label-large":"Label Large",caption:"Caption","caption-bold":"Caption Bold",legal:"Legal","legal-semibold":"Legal Semibold",eyebrow:"Eyebrow Medium","eyebrow-small":"Eyebrow Small","eyebrow-large":"Eyebrow Large",button:"Button Standard","button-small":"Button Small","button-extra-small":"Button Extra Small","number-large":"Number Large","number-medium":"Number Medium","number-small":"Number Small"};function Xi(){const e=({color:e})=>ce(h,{sx:{textAlign:"center"},children:[de(h,{sx:{width:"80px",height:"80px",backgroundColor:`var(${e.var})`,borderRadius:"8px",border:"1px solid var(--Border)",mb:1,mx:"auto"}}),de(T,{variant:"body2",sx:{fontWeight:600,fontSize:"12px",color:"var(--Text)",mb:.5,wordBreak:"break-word"},children:e.name}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block",fontSize:"10px",fontFamily:"monospace",wordBreak:"break-all"},children:e.var})]});return ce(B,{spacing:6,children:[ce(h,{children:[de(T,{variant:"h5",sx:{mb:3,fontWeight:700},children:"Brand Colors (Static)"}),de(B,{direction:"row",spacing:3,sx:{justifyContent:"center",flexWrap:"wrap",gap:3},children:[{name:"Primary",var:"--Primary-Color-11"},{name:"Secondary",var:"--Secondary-Color-11"},{name:"Tertiary",var:"--Tertiary-Color-11"}].map(t=>de(e,{color:t},t.var))})]}),ce(h,{children:[de(T,{variant:"h5",sx:{mb:3,fontWeight:700},children:"Background Colors (Dynamic)"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Update based on selected Background variant and Mode"}),de(I,{container:!0,spacing:2,sx:{justifyContent:"center"},children:[{name:"Default Background",cssVar:"var(--Theme-Default-Surfaces-Surface)"},{name:"Primary Background",cssVar:"var(--Theme-Primary-Surfaces-Surface)"},{name:"Secondary Background",cssVar:"var(--Theme-Secondary-Surfaces-Surface)"},{name:"Tertiary Background",cssVar:"var(--Theme-Tertiary-Surfaces-Surface)"},{name:"Neutral Background",cssVar:"var(--Theme-Neutral-Surfaces-Surface)"},{name:"Neutral-Variant Background",cssVar:"var(--Theme-Neutral-Variant-Surfaces-Surface)"}].map(e=>de(I,{item:!0,sx:{display:"flex",justifyContent:"center"},children:ce(h,{sx:{textAlign:"center"},children:[de(h,{sx:{minWidth:"max(var(--Button-Height), var(--Min-Button-Width))",minHeight:"var(--Button-Height)",backgroundColor:e.cssVar,borderRadius:"var(--Style-Border-Radius)",border:"2px solid var(--Border)",mb:1}}),de(T,{variant:"body2",sx:{fontWeight:600,fontSize:"12px",color:"var(--Text)",wordBreak:"break-word"},children:e.name})]})},e.name))})]}),ce(h,{children:[de(T,{variant:"h5",sx:{mb:3,fontWeight:700},children:"Dynamic Colors (Update with Mode, Background & Surface)"}),de(A,{severity:"info",sx:{backgroundColor:"var(--Container-Low)",mb:3,border:"1px solid var(--Border)"},children:ce(T,{variant:"body2",children:["Most colors update automatically based on the current"," ",de("strong",{children:"Mode"})," (Light/Dark), ",de("strong",{children:"Background"})," ","variant, and ",de("strong",{children:"Surface"})," theme. Only Primary, Secondary, and Tertiary colors are fixed brand colors."]})}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"These colors automatically adapt based on:"}),ce(B,{spacing:1,sx:{mb:4},children:[ce(h,{sx:{display:"flex",gap:2},children:[de(T,{variant:"body2",sx:{fontWeight:600,minWidth:80},children:"Mode:"}),de(T,{variant:"body2",children:"Light or Dark theme"})]}),ce(h,{sx:{display:"flex",gap:2},children:[de(T,{variant:"body2",sx:{fontWeight:600,minWidth:80},children:"Background:"}),de(T,{variant:"body2",children:"Default, Primary, Secondary, Tertiary, Neutral, or Neutral-Variant"})]}),ce(h,{sx:{display:"flex",gap:2},children:[de(T,{variant:"body2",sx:{fontWeight:600,minWidth:80},children:"Surface:"}),de(T,{variant:"body2",children:"Theme surface layer selection"})]})]}),de(B,{spacing:4,children:[{name:"Layout & Surfaces",colors:[{name:"Background",var:"--Background"},{name:"Border",var:"--Border"},{name:"Border-Variant",var:"--Border-Variant"}]},{name:"Text & Links",colors:[{name:"Header",var:"--Header"},{name:"Text",var:"--Text"},{name:"Text-Quiet",var:"--Text-Quiet"},{name:"Hotlink",var:"--Hotlink"},{name:"Hotlink-Visited",var:"--Hotlink-Visited"}]},{name:"Buttons - Primary",colors:[{name:"Button BG",var:"--Button-Primary-Button"},{name:"Button Text",var:"--Button-Primary-Text"},{name:"Button Hover",var:"--Button-Primary-Hover"},{name:"Button Active",var:"--Button-Primary-Pressed"},{name:"Focus-Visible",var:"--Focus-Visible"}]},{name:"Buttons - Secondary",colors:[{name:"Button BG",var:"--Button-Secondary-Button"},{name:"Button Text",var:"--Button-Secondary-Text"},{name:"Button Hover",var:"--Button-Secondary-Hover"},{name:"Button Active",var:"--Button-Secondary-Pressed"},{name:"Focus-Visible",var:"--Focus-Visible"}]},{name:"Buttons - State",colors:[{name:"Info Button",var:"--Button-Info-Button"},{name:"Success Button",var:"--Button-Success-Button"},{name:"Warning Button",var:"--Button-Warning-Button"},{name:"Error Button",var:"--Button-Error-Button"}]},{name:"Icons",colors:[{name:"Default",var:"--Icons-Default"},{name:"Primary",var:"--Icons-Primary"},{name:"Secondary",var:"--Icons-Secondary"},{name:"Tertiary",var:"--Icons-Tertiary"},{name:"Neutral",var:"--Icons-Neutral"},{name:"Info",var:"--Icons-Info"},{name:"Success",var:"--Icons-Success"},{name:"Warning",var:"--Icons-Warning"},{name:"Error",var:"--Icons-Error"}]},{name:"Chips & Badges",colors:[{name:"Primary BG",var:"--Tags-Primary-BG"},{name:"Primary Text",var:"--Tags-Primary-Text"},{name:"Secondary BG",var:"--Tags-Secondary-BG"},{name:"Secondary Text",var:"--Tags-Secondary-Text"},{name:"Tertiary BG",var:"--Tags-Tertiary-BG"},{name:"Tertiary Text",var:"--Tags-Tertiary-Text"},{name:"Neutral BG",var:"--Tags-Neutral-BG"},{name:"Neutral Text",var:"--Tags-Neutral-Text"},{name:"Info BG",var:"--Tags-Info-BG"},{name:"Info Text",var:"--Tags-Info-Text"},{name:"Success BG",var:"--Tags-Success-BG"},{name:"Success Text",var:"--Tags-Success-Text"},{name:"Warning BG",var:"--Tags-Warning-BG"},{name:"Warning Text",var:"--Tags-Warning-Text"},{name:"Error BG",var:"--Tags-Error-BG"},{name:"Error Text",var:"--Tags-Error-Text"}]}].map(t=>ce(h,{children:[de(T,{variant:"h6",sx:{mb:2,fontWeight:600},children:t.name}),de(I,{container:!0,spacing:2,sx:{justifyContent:"center"},children:t.colors.map(t=>de(I,{item:!0,sx:{display:"flex",justifyContent:"center"},children:de(e,{color:t})},t.var))})]},t.name))})]}),ce(h,{sx:{pt:4,borderTop:"1px solid var(--Border)"},children:[de(T,{variant:"h5",sx:{mb:2,fontWeight:700},children:"How to Use"}),ce(B,{spacing:2,children:[ce(h,{children:[de(T,{variant:"h6",sx:{fontWeight:600,mb:1},children:"Static Colors"}),ce(T,{variant:"body2",sx:{color:"var(--Text-Secondary)"},children:["Use brand colors (",de("code",{style:{backgroundColor:"var(--Container)",padding:"2px 4px",borderRadius:"4px"},children:"--Primary-Color-11"}),","," ",de("code",{style:{backgroundColor:"var(--Container)",padding:"2px 4px",borderRadius:"4px"},children:"--Secondary-Color-11"}),","," ",de("code",{style:{backgroundColor:"var(--Container)",padding:"2px 4px",borderRadius:"4px"},children:"--Tertiary-Color-11"}),") for brand elements that should never change."]})]}),ce(h,{children:[de(T,{variant:"h6",sx:{fontWeight:600,mb:1},children:"Dynamic Colors"}),de(T,{variant:"body2",sx:{color:"var(--Text-Secondary)"},children:"Use dynamic color variables for all UI elements. They will automatically update when users change Mode, Background, or Surface settings."})]}),ce(h,{children:[de(T,{variant:"h6",sx:{fontWeight:600,mb:1},children:"Example Usage"}),de(h,{component:"pre",sx:{backgroundColor:"var(--Container)",p:2,borderRadius:"8px",overflow:"auto",fontSize:"12px",border:"1px solid var(--Border)",color:"var(--Text)"},children:"/* Dynamic - updates with theme changes */\ncolor: var(--Text);\nbackgroundColor: var(--Background);\nborderColor: var(--Border);\n\n/* Static - brand colors stay the same */\naccentColor: var(--Primary-Color-11);"})]})]})]})]})}function Ki(){const e=({name:e,varName:t,baseValue:r})=>de(h,{sx:{mb:2},children:ce(h,{sx:{display:"flex",alignItems:"center",gap:2,mb:1},children:[de(h,{"aria-hidden":"true",sx:{width:`var(${t})`,minWidth:20,height:24,backgroundColor:"var(--Buttons-Primary-Button)",borderRadius:.5,border:"1px solid var(--Border)"}}),ce(B,{spacing:.5,children:[de(T,{variant:"subtitle2",sx:{fontWeight:600},children:e}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:t}),ce(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:["Base: ",r," (with cognitive multiplier)"]})]})]})}),t=({name:e,varName:t,value:r})=>ce(h,{sx:{mb:2},children:[de(h,{"aria-hidden":"true",sx:{width:100,height:r,backgroundColor:"var(--Buttons-Primary-Button)",borderRadius:1,border:"1px solid var(--Border)",mb:1}}),de(T,{variant:"subtitle2",sx:{fontWeight:600},children:e}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block"},children:t}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:r})]});return ce(B,{spacing:3,sx:{p:2},children:[ce("section",{children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Spacing Scale"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Spacing values are multiplied by the cognitive multiplier for accessibility. Each spacing value includes a visual reference and text label for clarity."}),de(B,{spacing:1,children:[{name:"Quarter",var:"--Spacing-Quarter",baseValue:"2px"},{name:"Half",var:"--Spacing-Half",baseValue:"4px"},{name:"1-and-Half",var:"--Spacing-1-and-Half",baseValue:"12px"},{name:"1",var:"--Spacing-1",baseValue:"8px"},{name:"2",var:"--Spacing-2",baseValue:"16px"},{name:"3",var:"--Spacing-3",baseValue:"24px"},{name:"4",var:"--Spacing-4",baseValue:"32px"},{name:"5",var:"--Spacing-5",baseValue:"40px"},{name:"6",var:"--Spacing-6",baseValue:"48px"},{name:"7",var:"--Spacing-7",baseValue:"56px"},{name:"8",var:"--Spacing-8",baseValue:"64px"},{name:"9",var:"--Spacing-9",baseValue:"72px"},{name:"10",var:"--Spacing-10",baseValue:"80px"}].map(t=>de(e,{name:t.name,varName:t.var,baseValue:t.baseValue},t.var))})]}),ce("section",{children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Sizing Scale"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Fixed sizing values for components and layouts. Each size is labeled with its CSS variable and pixel value."}),de(I,{container:!0,spacing:3,children:[{name:"Quarter",var:"--Sizing-Quarter",value:"2px"},{name:"Half",var:"--Sizing-Half",value:"4px"},{name:"1-and-Half",var:"--Sizing-1-and-Half",value:"12px"},{name:"1",var:"--Sizing-1",value:"8px"},{name:"2",var:"--Sizing-2",value:"16px"},{name:"3",var:"--Sizing-3",value:"24px"},{name:"4",var:"--Sizing-4",value:"32px"},{name:"5",var:"--Sizing-5",value:"40px"},{name:"6",var:"--Sizing-6",value:"48px"},{name:"7",var:"--Sizing-7",value:"56px"},{name:"8",var:"--Sizing-8",value:"64px"},{name:"9",var:"--Sizing-9",value:"72px"},{name:"10",var:"--Sizing-10",value:"80px"},{name:"11",var:"--Sizing-11",value:"88px"},{name:"12",var:"--Sizing-12",value:"96px"},{name:"13",var:"--Sizing-13",value:"104px"},{name:"14",var:"--Sizing-14",value:"112px"},{name:"15",var:"--Sizing-15",value:"160px"},{name:"16",var:"--Sizing-16",value:"240px"},{name:"17",var:"--Sizing-17",value:"320px"},{name:"18",var:"--Sizing-18",value:"480px"}].map(e=>de(I,{item:!0,xs:12,sm:6,md:4,lg:3,children:de(t,{name:e.name,varName:e.var,value:e.value})},e.var))})]}),ce("section",{children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Negative Sizing"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Negative values for margins and offsets. Use these to reduce or remove default spacing when needed."}),de(I,{container:!0,spacing:3,children:[{name:"Negative-Quarter",var:"--Sizing-Negative-Quarter",value:"-2px"},{name:"Negative-Half",var:"--Sizing-Negative-Half",value:"-4px"},{name:"Negative-1-and-Half",var:"--Sizing-Negative-1-and-Half",value:"-12px"},{name:"Negative-1",var:"--Sizing-Negative-1",value:"-8px"}].map(e=>de(I,{item:!0,xs:12,sm:6,md:4,lg:3,children:ce(h,{children:[de(T,{variant:"subtitle2",sx:{fontWeight:600},children:e.name}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block"},children:e.var}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:e.value})]})},e.var))})]}),ce("section",{style:{paddingTop:24,borderTop:"1px solid var(--Border)"},children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Container Padding"}),ce(h,{sx:{p:"var(--Spacing-3)",backgroundColor:"var(--Container-Low)",border:"2px dashed var(--Buttons-Primary-Button)",borderRadius:1},children:[ce(T,{variant:"body2",children:["Default container padding: ",de("strong",{children:"var(--Spacing-3)"})," = 24px"]}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block",mt:1},children:"Use this variable for consistent padding around main content areas."})]})]}),ce("section",{style:{paddingTop:24,borderTop:"1px solid var(--Border)"},children:[de(T,{variant:"h5",component:"h2",sx:{mb:3,fontWeight:700},children:"Practical Examples"}),ce("article",{children:[de(T,{variant:"h6",component:"h3",sx:{mb:2,fontWeight:600},children:"Padding Examples"}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",mb:2,display:"block"},children:"Different padding values create different visual breathing room."}),de(I,{container:!0,spacing:2,sx:{mb:4},children:["var(--Spacing-1)","var(--Spacing-2)","var(--Spacing-3)","var(--Spacing-4)"].map(e=>de(I,{item:!0,xs:12,sm:6,children:ce(h,{sx:{p:e,backgroundColor:"var(--Container)",border:"1px solid var(--Border)",borderRadius:1},children:[ce(T,{variant:"subtitle2",children:["Padding: ",e]}),de(T,{variant:"caption",sx:{display:"block",mt:1,color:"var(--Text-Secondary)"},children:"Content with spacing applied"})]})},e))})]}),ce("article",{children:[de(T,{variant:"h6",component:"h3",sx:{mb:2,fontWeight:600},children:"Gap Examples"}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",mb:2,display:"block"},children:"Gap controls spacing between flex/grid children without adding extra elements."}),de(B,{spacing:3,children:["var(--Spacing-1)","var(--Spacing-2)","var(--Spacing-3)"].map(e=>ce(h,{children:[de(B,{direction:"row",spacing:e,sx:{mb:1},children:[1,2,3].map(e=>de(h,{"aria-hidden":"true",sx:{width:60,height:60,backgroundColor:"var(--Buttons-Primary-Button)",borderRadius:1,flexShrink:0}},e))}),ce(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:["Gap: ",e]})]},e))})]})]}),ce(h,{role:"note",sx:{p:2,backgroundColor:"var(--Container-Low)",borderRadius:1,borderLeft:"4px solid var(--Buttons-Primary-Button)",mt:3},children:[de(T,{variant:"subtitle2",sx:{fontWeight:600,mb:1},children:"✓ Accessibility Best Practices Used"}),ce("ul",{style:{margin:"0.5rem 0",paddingLeft:"1.5rem"},children:[de("li",{children:ce(T,{variant:"caption",children:[de("strong",{children:'aria-hidden="true"'})," on purely decorative visual elements"]})}),de("li",{children:de(T,{variant:"caption",children:"All spacing information conveyed through text labels and values"})}),de("li",{children:ce(T,{variant:"caption",children:["No empty decorative ",de("code",{children:"<div>"})," elements in DOM"]})}),de("li",{children:ce(T,{variant:"caption",children:["Semantic HTML: ",de("code",{children:"<section>"})," and ",de("code",{children:"<article>"})," for structure"]})}),de("li",{children:de(T,{variant:"caption",children:"CSS-based spacing (padding/margin) for actual layout, not decorative divs"})}),de("li",{children:de(T,{variant:"caption",children:"Full keyboard navigation and screen reader support"})})]})]})]})}Object.entries({Display:["display-large","display-medium","display-small"],Headings:["h1","h2","h3","h4","h5","h6"],Subtitle:["subtitle-small","subtitle","subtitle-large"],Body:["body-small","body-small-semibold","body","body-semibold","body-large","body-large-semibold"],Label:["label","label-small","label-large"],Caption:["caption","caption-bold"],Legal:["legal","legal-semibold"],Eyebrow:["eyebrow-small","eyebrow","eyebrow-large"],Button:["button-extra-small","button-small","button"],Number:["number-large","number-medium","number-small"]}).map(([e,t])=>({label:e,options:t.map(e=>({value:e,label:Ui[e]}))}));const qi=["default","primary","secondary","tertiary","neutral","info","success","warning","error"],Ji=e=>e.charAt(0).toUpperCase()+e.slice(1);function Yi(e){const t=Ji(e);return{type:"outline",color:t,trackOff:"var(--Background)",trackOffBorder:"var(--Border-Variant)",trackOn:"var(--Buttons-"+t+"-Button)",trackOnBorder:"var(--Buttons-"+t+"-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-"+t+"-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-"+t+"-Button)"}}function $i(e){const t=Ji(e);return{type:"light",color:t,trackOff:"var(--Border-Variant)",trackOffBorder:"transparent",trackOn:"var(--"+t+"-Color-11)",trackOnBorder:"var(--Buttons-"+t+"-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-"+t+"-Border)",iconOff:"var(--Border-Variant)",iconOn:"var(--"+t+"-Color-11)",dataTheme:t,dataSurface:"Surface-Brightest"}}const Zi={small:{trackW:28,trackH:16,dotRadius:"var(--Sizing-2, 16px)",icon:8},medium:{trackW:40,trackH:24,dotRadius:"var(--Sizing-2-and-Half, 20px)",icon:16},large:{trackW:56,trackH:32,dotRadius:"var(--Sizing-2-and-Half, 20px)",icon:16}};function _i({variant:e="default",size:t="medium",checked:r,defaultChecked:o,onChange:n,disabled:i=!1,label:a,labelPlacement:l="end",name:s,value:d,icon:c,iconOn:u,iconOff:p,className:h="",sx:m={},"aria-label":f,"aria-labelledby":g,...x}){const b=function(){const e={};return qi.forEach(t=>{e[t+"-outline"]=Yi(t),e[t+"-light"]=$i(t)}),e.default={type:"themed",trackOff:"var(--Background)",trackOffBorder:"var(--Quiet)",trackOn:"var(--Buttons-Default-Button)",trackOnBorder:"var(--Buttons-Default-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-Default-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-Default-Button)"},e["default-outline"]={type:"themed",trackOff:"var(--Background)",trackOffBorder:"var(--Quiet)",trackOn:"var(--Buttons-Default-Button)",trackOnBorder:"var(--Buttons-Default-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-Default-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-Default-Button)"},e.outline={type:"themed",trackOff:"var(--Background)",trackOffBorder:"var(--Quiet)",trackOn:"var(--Buttons-Default-Button)",trackOnBorder:"var(--Buttons-Default-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-Default-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-Default-Button)"},e.primary=Yi("primary"),e.light=$i("primary"),e}(),y=b[e]||b.default,S=Zi[t]||Zi.medium,k="small"===t?ao:co,B=S.trackH-4,w=Math.max(24,S.trackW),C=Math.max(24,S.trackH),T=(C-S.trackH)/2,I={width:B,height:B,borderRadius:S.dotRadius,boxShadow:"none",border:"none",display:"flex",alignItems:"center",justifyContent:"center",transition:"background-color 0.15s ease","& > *":{width:S.icon,height:S.icon,display:"block"}},A={width:S.trackW,minWidth:24,height:C,minHeight:24,padding:0,overflow:"visible",opacity:i?"var(--Disabled, 0.38)":1,"& .MuiSwitch-switchBase":{position:"absolute",top:0,left:0,width:"100%",height:"100%",display:"flex",justifyContent:"flex-start",alignItems:"center",paddingTop:0,paddingBottom:0,paddingLeft:"2px",paddingRight:w-S.trackW+2+"px",color:"transparent",transition:"justify-content 0.15s ease",transform:"none","& .MuiSwitch-input":{left:0,top:0,width:"100%",height:"100%",margin:0},"& .MuiSwitch-thumb":{...I,backgroundColor:y.dotOff,color:y.iconOff},"&.Mui-checked":{justifyContent:"flex-end",transform:"none","& .MuiSwitch-thumb":{...I,backgroundColor:y.dotOn,color:y.iconOn},"& + .MuiSwitch-track":{backgroundColor:y.trackOn,borderColor:y.trackOnBorder,opacity:1}},"&:hover, &.Mui-checked:hover":{backgroundColor:"transparent"},"&:hover + .MuiSwitch-track":{boxShadow:an},"&:active + .MuiSwitch-track":{boxShadow:nn},"&.Mui-focusVisible + .MuiSwitch-track":{outline:"1px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled + .MuiSwitch-track":{opacity:1}},"& .MuiSwitch-track":{width:S.trackW,height:S.trackH,borderRadius:"var(--Sizing-3, 24px)",backgroundColor:y.trackOff,border:"1px solid "+y.trackOffBorder,boxSizing:"border-box",opacity:1,position:"absolute",top:T,left:0,transition:"background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease"},...m},R=e.includes("-light")||"light"===e,E=void 0!==p?p:c,P=void 0!==u?u:c,O=e=>de("span",{className:"MuiSwitch-thumb",children:e}),L=de(z,{...void 0!==E||void 0!==P?{icon:O(E),checkedIcon:O(P)}:{},checked:r,defaultChecked:o,onChange:n,disabled:i,name:s,value:d,slotProps:{input:{...f?{"aria-label":f}:{},...g?{"aria-labelledby":g}:{}}},className:"switch-"+e+" "+h,sx:A,disableRipple:!0,...R&&y.dataTheme?{"data-theme":y.dataTheme,"data-surface":y.dataSurface||"Surface-Dim"}:{},...x});return a?de(v,{control:L,label:de(k,{component:"span",sx:{color:i?"var(--Text-Quiet)":"var(--Text)",fontSize:"small"===t?"13px":"15px",fontWeight:500,opacity:i?.6:1},children:a}),labelPlacement:l,sx:{gap:"8px",marginLeft:0,marginRight:0}}):L}const ea=_i,ta=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ra={default:"Default",quiet:"Quiet",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},oa=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],na=["filled","outlined","rounded","twotone","sharp"],ia={filled:"Filled",outlined:"Outlined",rounded:"Rounded",twotone:"Two Tone",sharp:"Sharp"},aa={Home:{filled:Be,outlined:Oe,rounded:je,twotone:tt,sharp:ht},Favorite:{filled:ke,outlined:Le,rounded:Ge,twotone:rt,sharp:mt},Delete:{filled:we,outlined:Me,rounded:Ue,twotone:ot,sharp:ft},Settings:{filled:Ce,outlined:We,rounded:Xe,twotone:nt,sharp:gt},Search:{filled:Te,outlined:Te,rounded:Ke,twotone:it,sharp:xt},Star:{filled:Ie,outlined:De,rounded:qe,twotone:at,sharp:bt},Person:{filled:me,outlined:Fe,rounded:Je,twotone:lt,sharp:vt},Notifications:{filled:Ae,outlined:Ne,rounded:Ye,twotone:st,sharp:yt},Visibility:{filled:ze,outlined:He,rounded:$e,twotone:dt,sharp:St},ShoppingCart:{filled:Re,outlined:Ve,rounded:Ze,twotone:ct,sharp:kt},Lock:{filled:Ee,outlined:Qe,rounded:_e,twotone:ut,sharp:Bt},Info:{filled:Pe,outlined:ve,rounded:et,twotone:pt,sharp:wt}};function la({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function sa({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(la,{ratio:t,threshold:r})]})}function da({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"primary":"primary-outline",size:"small",onClick:r,children:e})}function ca(){const[e,t]=r("filled"),[o,n]=r("default"),[a,l]=r("medium"),[s,d]=r("40"),[c,u]=r(!1),[p,m]=r("Home"),[f,g]=r(""),[x,b]=r({}),v=ra[o]||"Default",y="twotone"===e,S="custom"===a?(parseInt(s,10)||40)+"px":{xs:"12px",small:"16px",medium:"24px",large:"36px"}[a]||"24px",k=function(e,t){return aa[e]?.[t]||aa[e]?.filled||Be}(p,e),w=function(e){return{outlined:"Outlined",rounded:"Rounded",twotone:"TwoTone",sharp:"Sharp"}[e]||""}(e),C=p+w+"Icon",T=f.trim().length>0,A="<Icon>\n <"+C+' />\n</Icon>\n{/* aria-hidden="true" by default */}',z='<Icon aria-label="'+(T?f.trim():p+" icon")+'">\n <'+C+' />\n</Icon>\n{/* role="img" added automatically */}';return i(()=>{b({background:Gi("--Background"),iconColor:Gi("--Icons-"+v),iconVariant:Gi("--Icons-Variant-"+v)})},[o,v]),ce(h,{sx:{pb:8},children:[de(Jr,{children:"Icon"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(h,{sx:{p:4,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",minHeight:200,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)",gap:2},children:de(jo,{color:o,size:a,fontSize:"custom"===a?parseInt(s,10)||40:void 0,disabled:c,twoTone:y,"aria-label":T?f.trim():void 0,children:de(k,{})})}),de(Ni,{code:(()=>{const e=[];"default"!==o&&e.push('color="'+o+'"'),"custom"===a?(e.push('size="custom"'),e.push("fontSize={"+(parseInt(s,10)||40)+"}")):"medium"!==a&&e.push('size="'+a+'"'),y&&e.push("twoTone"),c&&e.push("disabled"),T&&e.push('aria-label="'+f.trim()+'"');const t=e.length?" "+e.join(" "):"";return"import "+C+" from '@mui/icons-material/"+p+(w||"")+"';\n\n<Icon"+t+">\n <"+C+" />\n</Icon>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ICON"}),de(h,{component:"input",type:"text",value:p,onChange:e=>m(e.target.value),placeholder:"e.g. Home, Favorite, Delete",sx:{width:"100%",padding:"6px 10px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",boxSizing:"border-box","&:focus":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px",borderColor:"var(--Focus-Visible)"}}}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Enter a MUI icon name."," ",de(h,{component:"a",href:"https://mui.com/material-ui/material-icons/",target:"_blank",rel:"noopener noreferrer",sx:{color:"var(--Text-Primary)",textDecoration:"underline","&:hover":{color:"var(--Header-Primary)"}},children:"Browse MUI Icons ↗"})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:na.map(r=>de(da,{label:ia[r],selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:oa.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>{const t=ra[e],r=o===e;return de(h,{component:"button",onClick:()=>n(e),"aria-label":"Select "+ta(e),"aria-pressed":r,title:ta(e),sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Icons-"+t+")",border:r?"2px solid var(--Text)":"1px solid var(--Border)",outline:r?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:r&&de(he,{sx:{fontSize:16,color:"var(--Background)",pointerEvents:"none"}})},e)})})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["xs","small","medium","large","custom"].map(e=>de(da,{label:"xs"===e?"XS":ta(e),selected:a===e,onClick:()=>l(e)},e))}),"custom"===a&&ce(h,{sx:{display:"flex",alignItems:"center",gap:1,mt:1.5},children:[de(h,{component:"input",type:"number",value:s,onChange:e=>d(e.target.value),"aria-label":"Custom font size in pixels",sx:{width:72,padding:"4px 8px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none","&:focus":{borderColor:"var(--Focus-Visible)"}}}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"px"})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ARIA LABEL"}),de(h,{component:"input",type:"text",value:f,onChange:e=>g(e.target.value),placeholder:"Leave empty for decorative (aria-hidden)",sx:{width:"100%",padding:"6px 10px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",boxSizing:"border-box","&:focus":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px",borderColor:"var(--Focus-Visible)"}}}),de(bo,{style:{color:T?"var(--Tags-Success-Text)":"var(--Text-Quiet)",display:"block",marginTop:6},children:T?'✓ Meaningful — role="img" aria-label="'+f.trim()+'"':'Decorative — aria-hidden="true" (invisible to screen readers)'})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Reduces opacity to 0.38"})]}),de(_i,{checked:c,onChange:e=>u(e.target.checked),size:"small","aria-label":"Toggle disabled"})]})]})}),de(ai,{value:1,children:ce(h,{sx:{p:3},children:[ce(ao,{color:"quiet",style:{marginBottom:24},children:[ia[e]," / ",ta(o)," / ","custom"===a?s+"px":a,T?" / meaningful":" / decorative"]}),ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Icon Contrast (WCAG 1.4.11 — 3:1)"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Non-text elements must contrast 3:1 against the page background."}),de(sa,{label:"var(--Icons-"+v+") vs. var(--Background)",ratio:ji(x.iconColor,x.background),threshold:3,note:C+" at "+S+" in "+ta(o)+" color"}),y&&de(sa,{label:"var(--Icons-Variant-"+v+") vs. var(--Background)",ratio:ji(x.iconVariant,x.background),threshold:3,note:"Two-tone secondary fill — must also meet 3:1"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)",backgroundColor:T?"var(--Tags-Success-BG, rgba(0,200,0,0.05))":"transparent",px:1,borderRadius:"4px"},children:[ce(ao,{style:{fontWeight:600},children:["Current icon — ",T?"meaningful ✓":"decorative"]}),de(h,{component:"pre",sx:{fontFamily:"monospace",fontSize:"11px",color:"var(--Text-Quiet)",mt:.5,whiteSpace:"pre-wrap",wordBreak:"break-word",margin:0},children:T?z:A})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Decorative (no aria-label):"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'aria-hidden="true" is applied automatically. The icon is invisible to screen readers. Use this when the icon is purely visual — e.g. a decorative bullet or inline illustration.'}),de(h,{component:"pre",sx:{fontFamily:"monospace",fontSize:"11px",color:"var(--Text-Quiet)",mt:.5,whiteSpace:"pre-wrap",wordBreak:"break-word",margin:0},children:A})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Meaningful (with aria-label):"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'role="img" is added automatically. The label is announced by screen readers. Use this when the icon conveys information that is not present in surrounding text.'}),de(h,{component:"pre",sx:{fontFamily:"monospace",fontSize:"11px",color:"var(--Text-Quiet)",mt:.5,whiteSpace:"pre-wrap",wordBreak:"break-word",margin:0},children:z})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:["Disabled state",c?" ← current":"",":"]}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Opacity 0.38 — visual cue only. To disable an action, disable the wrapping interactive element (button, link), not the icon itself."})]}),y&&ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:["Two-tone",y?" ← current":"",":"]}),ce(bo,{style:{color:"var(--Text-Quiet)"},children:["Secondary fill uses var(--Icons-Variant-",v,"). Both the primary and secondary fills must meet 3:1 contrast independently."]})]}),ce(h,{sx:{py:1.5},children:[ce(ao,{children:["Touch target — ",S," icon","small"===a?" ⚠":" ✓",":"]}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"small"===a?"Small icons (20px) need a 24px minimum target area around them (WCAG 2.5.5). Wrap in a button with padding.":"Icon is "+S+" — meets 24px minimum. Ensure the wrapping interactive element also meets 24×24px."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Size Reference"}),de(B,{spacing:0,children:[{label:"Small",s:"small",px:"20px",note:"Inline text, compact UI"},{label:"Medium",s:"medium",px:"24px",note:"Standard UI — default"},{label:"Large",s:"large",px:"36px",note:"Emphasis, empty states, hero areas"},{label:"Custom",s:"custom",px:"any",note:"Ensure 24×24px minimum touch target (WCAG 2.5.5)"}].map(({label:e,s:t,px:r,note:o},n,i)=>ce(h,{sx:{py:1.5,borderBottom:n<i.length-1?"1px solid var(--Border)":"none",display:"flex",justifyContent:"space-between",alignItems:"flex-start"},children:[ce(h,{children:[ce(ao,{children:[e," — ",r]}),de(bo,{style:{color:"var(--Text-Quiet)"},children:o})]}),a===t&&de(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:"var(--Tags-Success-BG)",color:"var(--Tags-Success-Text)"},children:"current"})]},e))})]})]})]})})]})})})]})]})}const ua={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error",white:"White",black:"Black"},pa={small:{size:32,iconSize:"16px",borderRadius:"8px"},medium:{size:40,iconSize:"20px",borderRadius:"10px"},large:{size:48,iconSize:"24px",borderRadius:"12px"}};function ha({children:e,color:t="primary",variant:r="solid",size:o="medium",className:n="",sx:i={},...a}){const l=pa[o]||pa.medium,s=ua[t]||ua.primary;let d,c;switch(r){case"light":d=s,c="Surface-Brightest";break;case"dark":d=s,c="Surface-Dimmest";break;default:d=s,c="Surface"}return de(h,{"data-theme":d,"data-surface":c,className:"icon-badge icon-badge-"+r+" icon-badge-"+o+" icon-badge-"+t+" "+n,sx:{width:l.size,height:l.size,borderRadius:l.borderRadius,backgroundColor:"var(--Background)",color:"var(--Text)",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,"& svg":{width:l.iconSize,height:l.iconSize,fontSize:l.iconSize,color:"inherit",stroke:"currentColor"},...i},...a,children:e})}const ma={default:"Default-Light",primary:"Primary-Light",secondary:"Secondary-Light",tertiary:"Tertiary-Light",neutral:"Neutral-Light",info:"Info-Light",success:"Success-Light",warning:"Warning-Light",error:"Error-Light"};function fa({variant:e="outlined",color:o="default",size:n="medium",disabled:i=!1,orientation:a="horizontal",spacing:l=0,fit:s,fullWidth:d=!1,equalWidth:c=!1,value:u,defaultValue:p,onChange:m,children:f,className:g="",sx:x={},"aria-label":b,...v}){const[y,S]=r(p??null),k=void 0!==u,B=k?u:y,w="horizontal"===a,C=0===l,T="light"===e,I="ghost"===e,A=s??(d?"fill":c?"equal":"hug"),z="fill"===A,R="equal"===A&&w,E=(P=o).charAt(0).toUpperCase()+P.slice(1);var P;const O="var(--Buttons-"+E+"-Border)",L="var(--Buttons-"+E+"-Button)",M="var(--Buttons-"+E+"-Text)",W=ma[o]||"Default-Light",D=t.Children.toArray(f).filter(Boolean),F=D.length,N=(e,t)=>r=>{k||S(e),m?.(e,r),t?.(r)},H=D.map((e,r)=>{if(!t.isValidElement(e))return e;const a=0===r,l=r===F-1,s=e.props.value??r,d=B===s;let c;if(C&&F>1){const e="var(--Style-Border-Radius)";c=w?a&&l?e:a?e+" 0 0 "+e:l?"0 "+e+" "+e+" 0":"0":a&&l?e:a?e+" "+e+" 0 0":l?"0 0 "+e+" "+e:"0"}const u={...C&&F>1?{borderRadius:c,...!a&&(w?{marginLeft:"calc(-1 * var(--Button-Border-Width))"}:{marginTop:"calc(-1 * var(--Button-Border-Width))"}),position:"relative","&:hover, &:focus-visible":{zIndex:1}}:{},...d?{backgroundColor:L+" !important",color:M+" !important",borderColor:O+" !important","&:hover, &:active, &.Mui-focusVisible, &:focus-visible":{backgroundColor:L+" !important",color:M+" !important",borderColor:O+" !important"}}:{},...d?{}:{color:"var(--Quiet)",backgroundColor:"transparent","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)",zIndex:1},"&:active":{backgroundColor:"var(--Pressed)",color:"var(--Buttons-Default-Text)"}},...I?{border:"none !important","&:hover":{border:"none !important"}}:{},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px",zIndex:2},...e.props.sx},p=t.cloneElement(e,{variant:e.props.variant??(I?"ghost":d?o:o+"-outline"),size:e.props.size??n,disabled:e.props.disabled??i,onClick:N(s,e.props.onClick),"aria-pressed":d,sx:u});return T&&!d?de(h,{"data-theme":W,"data-surface":"Surface",sx:{display:"contents"},children:p},r):t.cloneElement(p,{key:r})});return de(h,{role:"group","aria-label":b,className:"btn-group btn-group-"+e+" btn-group-"+o+" "+g,sx:{...R?{display:z?"grid":"inline-grid",gridAutoFlow:"column",gridAutoColumns:"1fr",justifyItems:"stretch",alignItems:"stretch",width:z?"100%":"fit-content"}:{display:z?"flex":"inline-flex",flexDirection:w?"row":"column",alignItems:"stretch",width:z?"100%":"auto"},gap:C?0:l,border:"none",borderRadius:"var(--Style-Border-Radius)",...x},...v,children:H})}const ga=["Link","Chip","Badge","Caption","Label","Tag","BodySmall","LegalSemibold","Legal","LabelSmall","LabelExtraSmall","EyebrowSmall","ButtonSmall"];function xa(e){let r=!1;return t.Children.forEach(e,e=>{(function(e){if(!t.isValidElement(e))return!1;const r=e.props||{};if("small"===r.size)return!0;if("small"===r["data-size"])return!0;if(24===r.height||24===r.minHeight)return!0;if("24px"===r.height||"24px"===r.minHeight)return!0;if(r.sx){const e=r.sx.minHeight||r.sx.height;if(24===e||"24px"===e)return!0}const o=e.type;if(o){const e=o.displayName||o.name||"";if(ga.some(t=>e.includes(t)))return!0}return!1})(e)&&(r=!0)}),r}function ba({children:e,gap:t,spacing:r,direction:o="column",enforceMinGap:n=!0,minGapToken:i="--min-stack-gap",divider:a,flexWrap:l,useFlexGap:s=!0,alignItems:c,justifyContent:u,sx:p={},className:h="",...m}){const f=void 0!==t?t:r,g=n&&xa(e),x=d(()=>{if(!g)return f;const e=function(e,t=8){return null==e?0:"number"==typeof e?e*t:"string"==typeof e?e.endsWith("px")?parseFloat(e):e.endsWith("rem")?parseFloat(e)*parseFloat(getComputedStyle(document.documentElement).fontSize||"16"):parseFloat(e)*t||0:0}(f),t=function(e,t=8){if("undefined"==typeof window)return t;const r=getComputedStyle(document.documentElement).getPropertyValue(e).trim();return r?r.endsWith("rem")?parseFloat(r)*parseFloat(getComputedStyle(document.documentElement).fontSize):parseFloat(r)||t:t}(i,8);return e>=t?f:"var("+i+", "+t+"px)"},[g,f,i]);return de(B,{direction:o,spacing:s?void 0:x,gap:s?x:void 0,divider:a,flexWrap:l,useFlexGap:s,alignItems:c,justifyContent:u,className:"omni-stack"+(g?" omni-stack-min-gap-enforced":"")+(h?" "+h:""),sx:{background:"var(--Background)",boxSizing:"border-box",...g?{"&::before":{display:"none"}}:{},...p},"data-min-gap-enforced":g?"true":void 0,...m,children:e})}const va=e=>de(ba,{direction:"row",alignItems:"center",...e}),ya=e=>de(ba,{direction:"column",...e}),Sa=e=>de(ba,{direction:"column",alignItems:"center",justifyContent:"center",...e}),ka=e=>de(ba,{direction:"row",alignItems:"center",justifyContent:"space-between",...e}),Ba=e=>de(ba,{direction:"row",flexWrap:"wrap",...e}),wa=({breakpoint:e="sm",...t})=>de(ba,{direction:{xs:"column",[e]:"row"},...t}),Ca=ba,Ta=Ba,Ia=e=>de(h,{sx:{borderBottom:"1px solid var(--Border)",width:"100%"},...e}),Aa=({sx:e,...t})=>de(ba,{sx:{px:2,...e},...t}),za=({sx:e,...t})=>de(ba,{sx:{overflowY:"auto",...e},...t}),Ra={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Ea={small:{gap:"8px",fontSize:"13px",padding:"var(--Card-Padding)"},medium:{gap:"12px",fontSize:"14px",padding:"var(--Card-Padding)"},large:{gap:"16px",fontSize:"16px",padding:"var(--Card-Padding)"}},Pa=s({variant:"default",color:"primary",size:"medium",orientation:"vertical"});function Oa({children:e,variant:t="solid",color:r="default",surface:o,size:n="medium",orientation:i="vertical",clickable:a=!1,selected:l=!1,elevated:s=!1,draggable:d=!1,onClick:c,href:u,className:p="",sx:m={},...f}){const g="default"===r,x=g?"":Ra[r],b=o||(g?"Container":"dark"===t?"Surface-Dimmest":"light"===t?"Surface-Brightest":"Surface"),v=Ea[n]||Ea.medium,y="horizontal"===i,S=!!d,k=a||!!c||!!u||l||S,B=u?"a":"div",w=l?`var(--Buttons-${(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===r?"Default":r)}-Border)`:"var(--Buttons-Default-Border)",C=k?l?`2px solid ${w}`:"1px solid var(--Buttons-Default-Border)":"1px solid var(--Border-Variant)",T=s?ln:an,I=s?sn:ln,A=s?an:nn;return de(Pa.Provider,{value:{variant:t,color:r,size:n,orientation:i},children:de(h,{component:B,href:u||void 0,onClick:k?c:void 0,role:k?"button":void 0,tabIndex:k?0:void 0,"aria-pressed":!!l||void 0,draggable:S||void 0,className:"card card-"+t+" card-"+n+" card-"+i+(k?" card-clickable":"")+(l?" card-selected":"")+(s?" card-elevated":"")+(S?" card-draggable":"")+" "+p,sx:{display:"flex",border:C,borderRadius:"var(--Card-Radius)",boxShadow:T,overflow:"hidden",textDecoration:"none",transition:"box-shadow 0.2s ease, border-color 0.2s ease, transform 0.1s ease",...k&&!S&&{cursor:"pointer","&:hover":{borderColor:"var(--Buttons-Default-Border)",boxShadow:I,transform:"translateY(-1px)"},"&:active":{transform:"translateY(0) scale(0.995)",boxShadow:A},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"3px",borderRadius:"calc(var(--Card-Radius) + 3px)"}},...S&&{cursor:"grab","&:hover":{borderColor:"var(--Buttons-Default-Border)",boxShadow:I},"&:active":{cursor:"grabbing",zIndex:10,boxShadow:sn,transform:"scale(1.02)",borderWidth:"2px",borderColor:"var(--Buttons-Primary-Border)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"3px"}},...m},onKeyDown:k?e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),c?.())}:void 0,...f,children:de(h,{"data-theme":x||void 0,"data-surface":b,sx:{display:"flex",flexDirection:y?"row":"column",gap:v.gap,padding:v.padding,backgroundColor:"var(--Background)",color:"var(--Text)",fontSize:v.fontSize,fontFamily:"inherit",borderRadius:"inherit",position:"relative",flex:1,minWidth:0,overflow:"hidden"},children:e})})})}function La({children:e,className:t="",sx:r={},...o}){const{size:n}=l(Pa);return de(h,{className:"card-content "+t,sx:{display:"flex",flexDirection:"column",gap:(Ea[n]||Ea.medium).gap,flex:1,minWidth:0,...r},...o,children:e})}const Ma=e=>de(Oa,{clickable:!0,selected:e.selected,...e}),Wa=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Da=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary"]},{label:"Core",colors:["white","black"]},{label:"State",colors:["info","success","warning","error"]}],Fa=[Be,Ct,ge,Ie,Tt,It];function Na(){const[e,t]=r("primary"),[o,n]=r("solid"),[i,a]=r("medium"),l=Fa[0];return ce(ya,{spacing:4,style:{paddingBottom:64},children:[de(Jr,{children:"Icon Badge"}),ce("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:24},children:[de(Oa,{padding:"medium",children:ce(ya,{spacing:4,alignItems:"center",children:[de("div",{style:{padding:40},children:de(ha,{color:e,variant:o,size:i,children:de(l,{})})}),de(va,{spacing:4,alignItems:"flex-end",children:["small","medium","large"].map(t=>ce(ya,{spacing:1,alignItems:"center",children:[de(ha,{color:e,variant:o,size:t,children:de(l,{})}),de(ao,{style:{color:"var(--Quiet)"},children:Wa(t)})]},t))}),ce(ya,{spacing:1,alignItems:"center",children:[de(ao,{style:{color:"var(--Quiet)",fontWeight:600,fontSize:"0.7rem"},children:"Variants"}),de(va,{spacing:3,children:["solid","light","dark"].map(t=>ce(ya,{spacing:1,alignItems:"center",children:[de(ha,{color:e,variant:t,size:"medium",children:de(l,{})}),de(ao,{style:{color:"var(--Quiet)",fontSize:"0.65rem"},children:Wa(t)})]},t))})]}),ce(ya,{spacing:1,alignItems:"center",children:[de(ao,{style:{color:"var(--Quiet)",fontWeight:600,fontSize:"0.7rem"},children:"All Colors"}),de(va,{spacing:2,style:{flexWrap:"wrap",justifyContent:"center"},children:Da.flatMap(e=>e.colors).map(e=>ce(ya,{spacing:0,alignItems:"center",children:[de(ha,{color:e,variant:o,size:"small",children:de(l,{})}),de(ao,{style:{color:"var(--Quiet)",fontSize:"0.55rem"},children:Wa(e)})]},e))})]})]})}),de(Oa,{padding:"medium",children:ce(ya,{spacing:4,children:[de(Jr,{style:{fontSize:"1rem"},children:"Playground"}),ce(ya,{spacing:2,children:[de(ko,{children:"Color"}),Da.map(r=>ce(ya,{spacing:1,children:[de(ao,{style:{color:"var(--Quiet)",fontWeight:600,fontSize:"0.7rem"},children:r.label}),de(va,{spacing:1,children:r.colors.map(r=>de(Tn,{variant:e===r?"default":"outline",size:"small",onClick:()=>t(r),children:Wa(r)},r))})]},r.label))]}),ce(ya,{spacing:1,children:[de(ko,{children:"Variant"}),de(fa,{size:"small",children:["solid","light","dark"].map(e=>de(Tn,{variant:o===e?"default":"outline",size:"small",onClick:()=>n(e),children:Wa(e)},e))})]}),ce(ya,{spacing:1,children:[de(ko,{children:"Size"}),de(fa,{size:"small",children:["small","medium","large"].map(e=>de(Tn,{variant:i===e?"default":"outline",size:"small",onClick:()=>a(e),children:Wa(e)},e))})]}),ce(ya,{spacing:0,children:[ce(ao,{style:{color:"var(--Quiet)"},children:["data-theme: ",Wa(e),"light"===o?"-Light":""]}),ce(ao,{style:{color:"var(--Quiet)"},children:["data-surface: ","dark"===o?"Surface-Dimmest":"Surface"]}),de(ao,{style:{color:"var(--Quiet)"},children:"bg: var(--Background)"}),de(ao,{style:{color:"var(--Quiet)"},children:"icon: var(--Text)"})]})]})})]})]})}const Ha={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Va={small:{size:32,iconSize:16,fontSize:"13px",px:12,gap:6},medium:{size:48,iconSize:24,fontSize:"14px",px:16,gap:8},large:{size:56,iconSize:36,fontSize:"15px",px:20,gap:10}};function Qa({children:e,icon:t,label:r,variant:o="solid",color:n="primary",size:i="medium",extended:a=!1,animate:l=!1,disabled:s=!1,onClick:d,ariaLabel:c,className:u="",sx:p={},...m}){const f=function(e,t){const r=Ha[t]||"Primary";return"light"===e?{bg:"var(--Buttons-"+r+"-Light-Button)",text:"var(--Buttons-"+r+"-Light-Text)",border:"var(--Buttons-"+r+"-Light-Border)",hover:"var(--Buttons-"+r+"-Light-Hover)",active:"var(--Buttons-"+r+"-Light-Pressed)"}:{bg:"var(--Buttons-"+r+"-Button)",text:"var(--Buttons-"+r+"-Text)",border:"var(--Buttons-"+r+"-Border)",hover:"var(--Buttons-"+r+"-Hover)",active:"var(--Buttons-"+r+"-Pressed)"}}(o,n),g=Va[i]||Va.medium,x=t||e||de(At,{sx:{fontSize:g.iconSize}}),b=c||r||"Action";return ce(ue,{children:[l&&de("style",{children:"\n@keyframes fab-pulse {\n 0% { box-shadow: 0 0 0 0 rgba(var(--pulse-rgb, 0,0,0), 0.4); }\n 70% { box-shadow: 0 0 0 12px rgba(var(--pulse-rgb, 0,0,0), 0); }\n 100% { box-shadow: 0 0 0 0 rgba(var(--pulse-rgb, 0,0,0), 0); }\n}\n"}),ce(h,{component:"button",type:"button",role:"button","aria-label":b,onClick:d,disabled:s,className:"fab fab-"+o+" fab-"+n+" fab-"+i+(a?" fab-extended":"")+(l?" fab-animate":"")+(s?" fab-disabled":"")+(u?" "+u:""),sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",gap:a?g.gap+"px":0,...a?{height:g.size+"px",borderRadius:g.size/2+"px",px:g.px+"px"}:{width:g.size+"px",height:g.size+"px",borderRadius:"50%"},backgroundColor:f.bg,color:f.text,border:"var(--Button-Border-Width) solid "+f.border,"--_height":g.size+"px","--_bevel":"min(calc(var(--Button-Bevel) * var(--_height) / 100), calc(var(--_height) / 5))",boxShadow:`${mn(n)}, ${ln}`,fontSize:g.fontSize,fontFamily:"inherit",fontWeight:600,cursor:s?"not-allowed":"pointer",opacity:s?.5:1,outline:"none",flexShrink:0,transition:"background-color 0.15s ease, box-shadow 0.2s ease, transform 0.1s ease","&:hover":s?{}:{backgroundColor:f.hover,boxShadow:`${mn(n)}, ${sn}`},"&:active":s?{}:{backgroundColor:f.active,transform:"scale(0.96)",boxShadow:mn(n)},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px"},...l&&!s&&{animation:"fab-pulse 2s infinite"},...p},...m,children:[de(h,{sx:{display:"flex",alignItems:"center",justifyContent:"center",fontSize:g.iconSize+"px",color:"inherit","& .MuiSvgIcon-root":{fontSize:"inherit",color:"inherit"}},children:x}),a&&r&&de(h,{component:"span",sx:{whiteSpace:"nowrap",lineHeight:1},children:r})]})]})}const ja=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Ga=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Ua={default:"Tertiary",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"};function Xa({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Ka({color:e,selected:t,onClick:r}){const o=Ua[e]||"Primary";return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+ja(e),"aria-pressed":t,title:ja(e),sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function qa({value:e,onChange:t,placeholder:r,label:o}){return ce(h,{children:[o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4},children:o}),de(h,{component:"input",type:"text",value:e,onChange:e=>t(e.target.value),placeholder:r,sx:{width:"100%",padding:"6px 10px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none","&:focus":{borderColor:"var(--Focus-Visible)"}}})]})}function Ja(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r("Add"),[l,s]=r(!1),[d,c]=r("Create"),[u,p]=r(!1),[m,f]=r(!1),[g,x]=r(null),[b,v]=r("Surface"),y="default"===e?"tertiary":e;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Floating Action Button"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:g,children:de(Qa,{color:y,size:o,icon:(()=>{const e=zt[i]||zt.Add;return de(jo,{size:"medium",children:de(e,{})})})(),extended:l,label:d,animate:u,disabled:m,ariaLabel:l?d:i})}),de(Ni,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),t.push("icon={<"+i+"Icon />}"),l&&(t.push("extended"),t.push('label="'+d+'"')),u&&t.push("animate"),m&&t.push("disabled"),t.push('ariaLabel="'+(l?d:i)+'"'),"<Fab\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:g,onThemeChange:x,surface:b,onSurfaceChange:v})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Ga.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(Ka,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Xa,{label:ja(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(qa,{label:"Icon Name",value:i,onChange:a,placeholder:"Add"}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:[de("a",{href:"https://mui.com/material-ui/material-icons/",target:"_blank",rel:"noopener noreferrer",style:{color:"var(--Hotlink)"},children:"Material icon"})," name (e.g. Add, Edit, Favorite, Share)"]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Extended"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Pill shape with icon + text label"})]}),de(_i,{checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Extended"})]}),l&&de(h,{sx:{mt:1.5},children:de(qa,{label:"Label Text",value:d,onChange:c,placeholder:"Create"})}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Animation"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Pulse ring effect to draw attention"})]}),de(_i,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Animation"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(_i,{checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Role:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<button role="button" aria-label="...">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Label:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:l?"Extended: visible label provides accessible name.":"Icon-only: aria-label is required."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Focus:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"3px solid var(--Focus-Visible) with 2px offset."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Disabled:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"HTML disabled attribute. 50% opacity, removed from tab order."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Best Practices"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"One per screen:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"FABs represent the primary action. Use at most one per view."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Extended for clarity:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Use extended variant when the icon alone may be ambiguous."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Animation:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Use sparingly. Respect prefers-reduced-motion."})]})]})]})]})})})]})})})]})]})}function Ya({items:e=[],sections:t,value:o,defaultValue:i=0,onChange:a,expandable:l=!1,expandedWidth:s="partial",defaultExpanded:d=!1,fabAction:c,className:u="",sx:p={},...m}){const[f,g]=r(i),[x,b]=r(d),v=void 0!==o,y=v?o:f,S=n(e=>{v||g(e),a?.(e)},[v,a]),k=l&&x;return ce(h,{component:"nav",role:"navigation","aria-label":"Navigation rail","data-theme":"Default","data-surface":"Surface-Dim",className:"rail"+(k?" rail-expanded":" rail-collapsed")+" "+u,sx:{display:"flex",flexDirection:"column",width:(k?"full"===s?320:240:72)+"px",minHeight:"100%",backgroundColor:"var(--Background)",borderRight:"1px solid var(--Border)",fontFamily:"inherit",transition:"width 0.25s ease",overflow:"hidden",flexShrink:0,...p},...m,children:[l&&de(h,{sx:{display:"flex",justifyContent:k?"flex-start":"center",px:k?1.5:0,height:56,alignItems:"center"},children:de(Tn,{iconOnly:!0,variant:"ghost",size:"small",onClick:()=>b(e=>!e),"aria-label":k?"Collapse menu":"Expand menu",children:de(jo,{size:"small",sx:{color:"inherit"},children:de(k?Ot:Pt,{})})})}),c&&de(h,{sx:{px:k?2:1,py:1,flexShrink:0},children:de(Tn,{variant:"primary-light",size:"medium",onClick:c.onClick,"aria-label":c.label||"Action",startIcon:c.icon?de(jo,{size:"small",sx:{color:"inherit"},children:c.icon}):void 0,sx:{width:k?"100%":56,borderRadius:k?"28px":"var(--Style-Border-Radius)",justifyContent:k?"flex-start":"center",transition:"all 0.2s ease"},children:k?c.label:null})}),de(h,{role:"tablist","aria-orientation":"vertical",sx:{flex:1,overflowY:"auto",overflowX:"hidden",py:.5},children:(()=>{if(t&&t.length>0){const e=[];let r=0;return t.forEach((t,o)=>{o>0&&e.push(de(h,{"aria-hidden":"true",sx:{height:"1px",backgroundColor:"var(--Border)",mx:k?2:1.5,my:.5}},"divider-"+o)),t.items.forEach(t=>{const o=r;e.push(de($a,{icon:t.icon,label:t.label,badge:t.badge,selected:y===o,expanded:k,onClick:()=>S(o)},"item-"+o)),r++})}),e}return e.map((e,t)=>de($a,{icon:e.icon,label:e.label,badge:e.badge,selected:y===t,expanded:k,onClick:()=>S(t)},t))})()})]})}function $a({icon:e,label:t,badge:r,selected:o,expanded:n,onClick:i}){const a="var(--Buttons-Default-Button)",l="var(--Buttons-Default-Text)";return ce(h,{component:"button",type:"button",role:"tab","aria-selected":o,"aria-label":t,onClick:i,sx:{display:"flex",flexDirection:n?"row":"column",alignItems:"center",justifyContent:n?"flex-start":"center",gap:n?1.5:.25,width:"100%",height:56,px:n?2.5:.5,border:"none",borderRadius:0,backgroundColor:n&&o?a:"transparent",color:o?l:"var(--Quiet)",cursor:"pointer",fontFamily:"inherit",textAlign:n?"left":"center",transition:"background-color 0.15s ease, color 0.15s ease",outline:"none","&:hover":o?{}:{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},children:[ce(h,{sx:{position:"relative",display:"flex",alignItems:"center",justifyContent:"center",...!n&&{width:o?56:24,height:32,borderRadius:"16px",backgroundColor:o?a:"transparent",transition:"background-color 0.2s ease, width 0.2s ease"},...n&&{flexShrink:0}},children:[de(jo,{size:"small",sx:{color:"inherit"},children:e}),r&&de(Za,{value:r})]}),t&&de(bo,{style:{color:"inherit",fontWeight:500,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",...n?{flex:1}:{maxWidth:"100%",fontSize:"11px"}},children:t})]})}function Za({value:e}){return de(h,{sx:{position:"absolute",top:-4,right:-6,minWidth:16,height:16,borderRadius:"8px",backgroundColor:"var(--Tags-Error-BG)",color:"var(--Tags-Error-Text)",fontSize:"10px",fontWeight:700,px:.5,display:"flex",alignItems:"center",justifyContent:"center",lineHeight:1},children:e})}const _a=[{icon:de(Be,{}),label:"Home"},{icon:de(Te,{}),label:"Search"},{icon:de(ke,{}),label:"Favorites",badge:3},{icon:de(me,{}),label:"Profile"},{icon:de(Ce,{}),label:"Settings"}];function el({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function tl(){const[e,t]=r(!0),[o,n]=r("partial"),[i,a]=r(!1),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Rail"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[ce(li,{theme:l,surface:d,sx:{minHeight:400,alignItems:"stretch",p:0},children:[de(Ya,{items:_a,expandable:e,expandedWidth:o,fabAction:i?{icon:de(At,{}),label:"Create",onClick:()=>{}}:void 0}),de(h,{sx:{flex:1,p:3},children:de(ao,{style:{color:"var(--Quiet)"},children:"Main content area"})})]}),de(Ni,{code:(()=>{const t=["items={items}"];return e&&(t.push("expandable"),"partial"!==o&&t.push('expandedWidth="full"')),i&&t.push('fabAction={{ icon: <AddIcon />, label: "Create", onClick: handleCreate }}'),t.push("value={activeIndex}"),t.push("onChange={setActiveIndex}"),"<Rail\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"EXPANDED WIDTH"}),de(B,{direction:"row",spacing:1,children:["partial","full"].map(e=>{return de(el,{label:(t=e,t?t.charAt(0).toUpperCase()+t.slice(1):""),selected:o===e,onClick:()=>n(e)},e);var t})})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Expandable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Toggle between collapsed and expanded"})]}),de(_i,{variant:"default-outline",checked:e,onChange:e=>t(e.target.checked),size:"small","aria-label":"Expandable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"FAB Action"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show create button at top"})]}),de(_i,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"FAB action"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Nav",value:'<nav role="navigation" aria-label="Navigation rail">'},{label:"Items",value:'role="tab" aria-selected on each item'},{label:"TabList",value:'role="tablist" aria-orientation="vertical"'},{label:"Toggle",value:'aria-label="Expand/Collapse menu"'},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: -3px"},{label:"Badge",value:"Visual only — announced via aria-label on parent item"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const rl={default:{theme:"Default"},primary:{theme:"Primary"},"primary-light":{theme:"Primary",surface:"Surface-Brightest"},white:{theme:"Neutral",surface:"Surface-Brightest"},black:{theme:"Neutral",surface:"Surface-Dimmest"}};function ol({items:e=[],value:t,defaultValue:o,onChange:i,type:a="floating",orientation:l="horizontal",color:s="default",fab:d,className:c="",sx:u={},...p}){const[m,f]=r(o??null),g=void 0!==t,x=g?t:m,b=n(e=>{const t=x===e?null:e;g||f(t),i?.(t)},[g,x,i]),v=rl[s]||rl.default,y=v.theme,S=v.surface,k="vertical"===l,B="floating"===a,w=de(h,{role:"toolbar","aria-orientation":l,"aria-label":"Toolbar","data-theme":y,"data-surface":S||"Surface",className:"toolbar toolbar-"+a+" toolbar-"+l+" toolbar-"+s+" "+c,sx:{display:"inline-flex",flexDirection:k?"column":"row",alignItems:"center",gap:"4px",backgroundColor:"var(--Background)",border:"1px solid var(--Border-Variant)",borderRadius:B?"56px":"var(--Style-Border-Radius)",padding:B?"8px 16px":"8px",fontFamily:"inherit",flexShrink:0,...B&&{boxShadow:an},...u},...p,children:e.map((e,t)=>{const r=x===t;return de(Tn,{iconOnly:!0,variant:r?"default":"ghost",size:"small",onClick:()=>b(t),"aria-label":e.label,"aria-checked":r,role:"radio",children:de(jo,{size:"small",sx:{color:"inherit"},children:e.icon})},e.key||t)})});return d&&B?ce(h,{sx:{display:"inline-flex",flexDirection:k?"column":"row",alignItems:"center",gap:1},children:[w,de(Tn,{iconOnly:!0,variant:"default",size:"large",onClick:d.onClick,"aria-label":d.label||"Action",sx:{borderRadius:"50%",width:56,height:56,minWidth:"unset",minHeight:"unset"},children:de(jo,{size:"medium",sx:{color:"inherit"},children:d.icon})})]}):w}const nl=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",il=[{icon:de(Lt,{}),label:"Bold"},{icon:de(Mt,{}),label:"Italic"},{icon:de(Wt,{}),label:"Underline"},{icon:de(Dt,{}),label:"Align left"},{icon:de(Ft,{}),label:"Align center"}];function al({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function ll(){const[e,t]=r("floating"),[o,n]=r("default"),[i,a]=r("horizontal"),[l,s]=r(!1),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Toolbar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:d,surface:u,sx:{minHeight:200},children:de(ol,{items:il,type:e,color:o,orientation:i,fab:l&&"floating"===e?{icon:de(At,{}),label:"Create",onClick:()=>{}}:void 0})}),de(Ni,{code:(()=>{const t=["items={items}"];return"floating"!==e&&t.push('type="contextual"'),"default"!==o&&t.push('color="'+o+'"'),"horizontal"!==i&&t.push('orientation="vertical"'),l&&t.push('fab={{ icon: <AddIcon />, label: "Create", onClick: handleCreate }}'),t.push("value={selected}"),t.push("onChange={setSelected}"),"<Toolbar\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TYPE"}),de(B,{direction:"row",spacing:1,children:["floating","contextual"].map(r=>de(al,{label:nl(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["default","primary","primary-light","white","black"].map(e=>de(al,{label:nl(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ORIENTATION"}),de(B,{direction:"row",spacing:1,children:["horizontal","vertical"].map(e=>de(al,{label:nl(e),selected:i===e,onClick:()=>a(e)},e))})]}),"floating"===e&&ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"FAB Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Add FAB to the right of toolbar"})]}),de(_i,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"FAB button"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="toolbar" aria-orientation aria-label'},{label:"Items",value:'role="radio" aria-checked on each icon button'},{label:"Selection",value:"Toggle — click selected again to deselect"},{label:"Focus",value:"Uses Button component focus styles"},{label:"Floating",value:"borderRadius 56px, padding 16px, Effect-Level-2 shadow"},{label:"Contextual",value:"Standard border-radius, padding 8px, no shadow"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const sl={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 8px",iconSize:16,btnSize:28},medium:{height:"var(--Button-Height)",fontSize:"14px",padding:"6px 12px",iconSize:18,btnSize:36},large:{height:"var(--Large-Button-Height)",fontSize:"16px",padding:"8px 16px",iconSize:20,btnSize:44}};function dl({value:e,defaultValue:t=0,onChange:a,min:l,max:s,step:d=1,variant:c="outlined",style:u="outline",color:p="default",size:m="medium",label:f,labelPosition:g="top",placeholder:x,helperText:b,disabled:v=!1,fullWidth:y=!1,className:S="",sx:k={},...B}){const[w,C]=r(t),[T,I]=r(!1),A=o(null),z=void 0!==e,R=z?e:w,E=""!==R&&null!=R,P=(O="default"===p?"primary":p).charAt(0).toUpperCase()+O.slice(1);var O;const L="var(--Buttons-"+P+"-Border)",M="default"===p?"var(--Text)":"var(--Text-"+P+")",W="outlined"===c,D="floating"===g,F="top"===g,N=sl[m]||sl.medium,H="small"===m?ao:co,V=n(e=>{let t="number"==typeof e?e:parseFloat(e);isNaN(t)&&(t=0),void 0!==l&&t<l&&(t=l),void 0!==s&&t>s&&(t=s),z||C(t),a?.(t)},[z,a,l,s]),Q=o(R);Q.current=R;const j=n(e=>{if(v)return;const t="number"==typeof Q.current?Q.current:parseFloat(Q.current)||0;void 0!==l&&e<0&&t<=l||void 0!==s&&e>0&&t>=s||V(t+e*d)},[v,d,l,s,V]),G=void 0!==l&&R<=l,U=void 0!==s&&R>=s,X=o(null),K=o(null),q=n(()=>{X.current&&(clearTimeout(X.current),X.current=null),K.current&&(clearInterval(K.current),K.current=null)},[]),J=n(e=>{v||(q(),j(e),X.current=setTimeout(()=>{let t=120,r=0;const o=()=>{j(e),r+=1,10===r&&t>60?(clearInterval(K.current),t=60,K.current=setInterval(o,t)):30===r&&t>30&&(clearInterval(K.current),t=30,K.current=setInterval(o,t))};K.current=setInterval(o,t)},400))},[v,j,q]);i(()=>q,[q]);const Y=e=>({onPointerDown:t=>{if(void 0===t.button||0===t.button){t.preventDefault();try{t.currentTarget.setPointerCapture?.(t.pointerId)}catch(e){}J(e)}},onPointerUp:e=>{try{e.currentTarget.releasePointerCapture?.(e.pointerId)}catch(e){}q()},onPointerCancel:q,onPointerLeave:q,onKeyDown:t=>{"Enter"!==t.key&&" "!==t.key||t.repeat||(t.preventDefault(),J(e))},onKeyUp:e=>{"Enter"!==e.key&&" "!==e.key||q()},onBlur:q}),$=e=>{const t=e.target.value;if(""===t||"-"===t)return void(z||C(t));const r=parseFloat(t);isNaN(r)||V(r)},Z=e=>{"ArrowUp"===e.key&&(e.preventDefault(),j(1)),"ArrowDown"===e.key&&(e.preventDefault(),j(-1))},_={display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"var(--Buttons-"+P+"-Light-Button, transparent)",color:"var(--Buttons-"+P+"-Light-Text, var(--Text))",cursor:"pointer",outline:"none",flexShrink:0,border:"none",transition:"background-color 0.15s ease","&:hover":{backgroundColor:"var(--Buttons-"+P+"-Hover)"},"&:active":{backgroundColor:"var(--Buttons-"+P+"-Pressed)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px"},"&:disabled":{opacity:.4,cursor:"not-allowed"}},ee={},te=()=>F&&f?de(H,{component:"label",style:{display:"block",marginBottom:"6px",color:v?"var(--Quiet)":"var(--Text)",fontWeight:500,opacity:v?.6:1},children:f}):null;return ce(h,W?{className:"numberfield numberfield-outlined"+(v?" numberfield-disabled":"")+(S?" "+S:""),sx:{width:y?"100%":"auto",fontFamily:"inherit",...k},...B,children:[te(),de(h,{sx:{border:"1px solid "+L,borderRadius:"small"===m?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease",boxShadow:"none",opacity:v?.5:1,"&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{...ee,children:ce(h,{sx:{position:"relative",display:"flex",alignItems:"stretch",minHeight:N.height,backgroundColor:"var(--Hover)"},children:[D&&f&&de(h,{sx:{position:"absolute",top:E||T?"6px":"50%",left:"14px",transform:E||T?"scale(0.75)":"translateY(-50%)",transformOrigin:"top left",color:T?M:"var(--Quiet)",fontSize:N.fontSize,fontWeight:400,pointerEvents:"none",transition:"top 0.15s ease, transform 0.15s ease, color 0.15s ease",zIndex:1},children:f}),de(h,{component:"input",ref:A,type:"text",inputMode:"numeric",role:"spinbutton","aria-valuenow":"number"==typeof R?R:void 0,"aria-valuemin":l,"aria-valuemax":s,"aria-label":f||"Number",value:R,onChange:$,onKeyDown:Z,onFocus:()=>I(!0),onBlur:()=>I(!1),disabled:v,placeholder:D?void 0:x||"",sx:{flex:1,border:"none",outline:"none",backgroundColor:"transparent",color:E||T?M:"var(--Quiet)",fontSize:N.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)",padding:D?"22px 14px 6px":N.padding,minWidth:0,"&::placeholder":{color:"var(--Quiet)",opacity:1},"&:disabled":{cursor:"not-allowed"}}}),ce(h,{sx:{display:"flex",flexDirection:"column",borderLeft:"1px solid "+L},children:[de(h,{component:"button",type:"button","aria-label":"Increase",...Y(1),disabled:v||U,sx:{..._,flex:1,width:32,borderBottom:"1px solid "+L},children:de(jo,{size:"small",children:de(Nt,{})})}),de(h,{component:"button",type:"button","aria-label":"Decrease",...Y(-1),disabled:v||G,sx:{..._,flex:1,width:32},children:de(jo,{size:"small",children:de(Ht,{})})})]})]})})}),b&&de(ao,{style:{color:"var(--Quiet)",marginTop:"4px",marginLeft:"2px"},children:b})]}:{className:"numberfield numberfield-spinner"+(v?" numberfield-disabled":"")+(S?" "+S:""),sx:{fontFamily:"inherit",...k},...B,children:[te(),ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:"small"===m?.5:1,opacity:v?.5:1},children:[de(h,{component:"button",type:"button","aria-label":"Decrease",...Y(-1),disabled:v||G,sx:{..._,width:N.btnSize,height:N.btnSize,borderRadius:"small"===m?"var(--Sm-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"var(--Button-Icon-Radius, var(--Style-Border-Radius))",border:"1px solid "+L},children:de(jo,{size:"small",children:de(fe,{})})}),de(h,{sx:{border:"1px solid "+L,borderRadius:"small"===m?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{...ee,children:de(h,{component:"input",ref:A,type:"text",inputMode:"numeric",role:"spinbutton","aria-valuenow":"number"==typeof R?R:void 0,"aria-valuemin":l,"aria-valuemax":s,"aria-label":f||"Number",value:R,onChange:$,onKeyDown:Z,onFocus:()=>I(!0),onBlur:()=>I(!1),disabled:v,sx:{width:"small"===m?40:56,minHeight:N.height,textAlign:"center",border:"none",outline:"none",backgroundColor:"var(--Hover)",color:"var(--Text)",fontSize:N.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:600,"&:disabled":{cursor:"not-allowed"}}})})}),de(h,{component:"button",type:"button","aria-label":"Increase",...Y(1),disabled:v||U,sx:{..._,width:N.btnSize,height:N.btnSize,borderRadius:"small"===m?"var(--Sm-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"var(--Button-Icon-Radius, var(--Style-Border-Radius))",border:"1px solid "+L},children:de(jo,{size:"small",children:de(At,{})})})]}),b&&de(ao,{style:{color:"var(--Quiet)",marginTop:"4px",marginLeft:"2px"},children:b})]})}const cl=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ul=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function pl({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function hl({color:e,selected:t,onClick:r}){const o=cl(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function ml(){const[e,t]=r("outlined"),[o,n]=r("outline"),[i,a]=r("default"),[l,s]=r("medium"),[d,c]=r("top"),[u,p]=r(!0),[m,f]=r(!1),[g,x]=r(!1),[b,v]=r(null),[y,S]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Number Field"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:b,surface:y,children:de(h,{sx:{width:"100%",maxWidth:"outlined"===e?300:"auto"},children:de(dl,{variant:e,style:o,color:i,size:l,label:u?"Quantity":void 0,labelPosition:d,min:0,max:100,disabled:m,fullWidth:g&&"outlined"===e})})}),de(Ni,{code:(()=>{const t=['variant="'+e+'"'];return"outline"!==o&&t.push('style="'+o+'"'),"default"!==i&&t.push('color="'+i+'"'),"medium"!==l&&t.push('size="'+l+'"'),u&&t.push('label="Quantity"'),"top"!==d&&t.push('labelPosition="'+d+'"'),t.push("min={0}"),t.push("max={100}"),m&&t.push("disabled"),g&&"outlined"===e&&t.push("fullWidth"),t.push("value={value}"),t.push("onChange={setValue}"),"<NumberField\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:b,onThemeChange:v,surface:y,onSurfaceChange:S})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"VARIANT"}),de(B,{direction:"row",spacing:1,children:["outlined","spinner"].map(r=>de(pl,{label:cl(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","light"].map(e=>de(pl,{label:cl(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:ul.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(hl,{color:e,selected:i===e,onClick:a},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(pl,{label:cl(e),selected:l===e,onClick:()=>s(e)},e))})]}),"outlined"===e&&ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL"}),de(B,{direction:"row",spacing:1,children:["top","floating","none"].map(e=>de(pl,{label:"none"===e?"None":cl(e),selected:d===e,onClick:()=>c(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Label"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Text label above field"})]}),de(_i,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Show label"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(_i,{variant:"default-outline",checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]}),"outlined"===e&&ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Full Width"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Stretch to container"})]}),de(_i,{variant:"default-outline",checked:g,onChange:e=>x(e.target.checked),size:"small","aria-label":"Full width"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="spinbutton" with aria-valuenow, aria-valuemin, aria-valuemax'},{label:"Label",value:"aria-label from label prop. Always provide a label."},{label:"Keyboard",value:"ArrowUp/Down increment/decrement. Direct text entry supported."},{label:"Steppers",value:'aria-label="Increase" / "Decrease" on stepper buttons'},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px"},{label:"Disabled",value:"HTML disabled. Steppers also disabled at min/max bounds."}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}function fl({children:e,selected:t=!1,onChange:r,value:o,sx:n={},...i}){return de(R,{value:o,selected:t,onChange:r,sx:{border:"1px solid var(--Border)",color:"var(--Text)",backgroundColor:t?"var(--Buttons-Primary-Button)":"transparent","&:hover":{backgroundColor:t?"var(--Buttons-Primary-Button)":"var(--Container-High)"},"&.Mui-selected":{backgroundColor:"var(--Buttons-Primary-Button)",color:"#fff","&:hover":{backgroundColor:"var(--Buttons-Primary-Button)"}},textTransform:"none",fontWeight:500,...n},...i,children:e})}const gl=["default","primary","secondary","tertiary","neutral","black-white","info","success","warning","error"],xl=["fill","outline","ghost"];function bl(){const e={};return gl.forEach(t=>{xl.forEach(r=>{e["fill"===r?t:t+"-"+r]=function(e,t){const r=pn(e),o={color:e,style:t,bg:"transparent",text:"var(--Quiet)",hover:"var(--Buttons-"+r+"-Hover)",hoverText:"var(--Buttons-"+r+"-Text)"};return"ghost"===t?{...o,border:"transparent",selectedBg:"transparent",selectedText:"var(--Buttons-"+r+"-Border)",selectedRing:"inset 0 0 0 2px var(--Buttons-"+r+"-Border)",bevel:!1}:"outline"===t?{...o,border:"var(--Buttons-"+r+"-Border)",selectedBg:"transparent",selectedText:"var(--Buttons-"+r+"-Border)",selectedRing:"inset 0 0 0 2px var(--Buttons-"+r+"-Border)",bevel:!1}:{...o,border:"var(--Buttons-"+r+"-Border)",selectedBg:"var(--Buttons-"+r+"-Button)",selectedText:"var(--Buttons-"+r+"-Text)",selectedRing:null,bevel:!0}}(t,r)})}),e}const vl={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 10px",iconSize:16,gap:4,swatchRadius:"var(--Sm-Input-Swatch-Radius, 18px)"},medium:{height:"var(--Button-Height)",fontSize:"15px",padding:"6px 14px",iconSize:18,gap:6,swatchRadius:"var(--Input-Swatch-Radius, 26px)"},large:{height:"var(--Large-Button-Height)",fontSize:"17px",padding:"8px 18px",iconSize:20,gap:8,swatchRadius:"var(--Lg-Input-Swatch-Radius, 50px)"}};function yl({variant:e="primary",size:t="medium",value:r,defaultValue:o,onChange:n,exclusive:i=!0,orientation:a="horizontal",disabled:l=!1,fullWidth:s=!1,children:d,className:c="",sx:u={},"aria-label":p,...h}){const m=bl(),f=m[e]||m.default,g=vl[t]||vl.medium,x="vertical"===a,b={gap:0,border:"ghost"===f.style?"none":"1px solid "+f.border,borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",...s&&{width:"100%"},display:"grid",gridAutoFlow:x?"row":"column",...x?{gridAutoRows:"1fr"}:{gridAutoColumns:"1fr"},"& .MuiToggleButtonGroup-grouped":{margin:0,borderLeft:0,borderTop:0,"&.Mui-selected + &.Mui-selected":{marginLeft:0,marginTop:0,borderLeft:0,borderTop:0}},"& .MuiToggleButton-root":{height:g.height,fontSize:g.fontSize,padding:g.padding,fontFamily:"inherit",fontWeight:500,textTransform:"none",letterSpacing:"0",lineHeight:1.4,backgroundColor:f.bg,color:f.text,border:"none",borderRadius:0,transition:"background-color 0.15s ease, color 0.15s ease","& .tbtn-start, & .tbtn-end":{display:"inline-flex",alignItems:"center",flexShrink:0,"& > *":{width:g.iconSize,height:g.iconSize,display:"block"}},"& .tbtn-start":{marginRight:"2px"},"& .tbtn-end":{marginLeft:"2px"},"& .tbtn-swatch":{display:"block",flexShrink:0,width:g.iconSize,height:g.iconSize,borderRadius:g.swatchRadius,border:"1px solid var(--Border-Variant)"},"& .tbtn-swatch:not(:only-child)":{marginRight:"2px"},"--_height":g.height,"--_bevel":"var(--Button-Bevel-Px, min(calc(var(--Button-Bevel, 0) * var(--_height) / 100), calc(var(--_height) / 5)))",...s&&{flex:1},..."ghost"===f.style?{}:x?{"&:not(:last-of-type)":{borderBottom:"1px solid "+f.border}}:{"&:not(:last-of-type)":{borderRight:"1px solid "+f.border}},"&:hover":{backgroundColor:f.hover,color:f.hoverText},"&.Mui-selected":{backgroundColor:f.selectedBg,color:f.selectedText,...f.bevel?{boxShadow:mn(f.color)}:{},...f.selectedRing?{boxShadow:f.selectedRing}:{}},"&.Mui-selected:hover":{backgroundColor:f.selectedBg,color:f.selectedText,...f.bevel?{boxShadow:mn(f.color)}:{},...f.selectedRing?{boxShadow:f.selectedRing}:{}},"&.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"-2px",zIndex:1},"&.Mui-disabled":{opacity:.6,color:f.text,backgroundColor:f.bg},"&.Mui-disabled.Mui-selected":{opacity:.6,backgroundColor:f.selectedBg,color:f.selectedText},"& .MuiSvgIcon-root":{fontSize:g.iconSize},"& > *:not(:only-child)":{marginRight:g.gap/2,marginLeft:g.gap/2}},...u};return de(E,{value:r,defaultValue:o,onChange:n,exclusive:i,orientation:a,disabled:l,className:"toggle-group-"+e+" "+c,sx:b,"aria-label":p,...h,children:d})}const Sl=e=>de(yl,{variant:"default",...e}),kl=e=>de(yl,{variant:"primary",...e}),Bl=e=>de(yl,{variant:"secondary",...e}),wl=e=>de(yl,{variant:"tertiary",...e}),Cl=e=>de(yl,{variant:"neutral",...e}),Tl=e=>de(yl,{variant:"black-white",...e}),Il=e=>de(yl,{variant:"info",...e}),Al=e=>de(yl,{variant:"success",...e}),zl=e=>de(yl,{variant:"warning",...e}),Rl=e=>de(yl,{variant:"error",...e});function El({label:e,value:t="",onChange:o,placeholder:n,error:i=!1,errorMessage:a="",disabled:l=!1,helperText:s="",variant:d="outlined",size:c="medium",type:u="text",required:p=!1,fullWidth:m=!0,startAdornment:f,endAdornment:g,sx:x={},"aria-label":b,"aria-labelledby":v,...B}){const[w,C]=r(!1),T=i?"var(--Buttons-Error-Border)":w?"var(--Buttons-Primary-Border)":"var(--Border)",I=i||w?"var(--Text)":"var(--Text-Quiet)",A="var(--Text)";return ce(h,{sx:{width:m?"100%":"auto"},children:[de(y,{label:e,value:t,onChange:o,placeholder:n,disabled:l,variant:d,size:c,type:u,required:p,onFocus:()=>C(!0),onBlur:()=>C(!1),error:i,fullWidth:m,slotProps:{htmlInput:{...b?{"aria-label":b}:{},...v?{"aria-labelledby":v}:{}},input:{"data-surface":l?"Container-Low":"Container",style:{color:A},startAdornment:f?de(S,{position:"start",children:f}):void 0,endAdornment:g?de(S,{position:"end",children:g}):void 0}},sx:{width:m?"100%":"auto","& .MuiOutlinedInput-root":{backgroundColor:"var(--Background)",transition:"all 0.2s ease-in-out",color:A,"& fieldset":{borderColor:T,transition:"border-color 0.2s ease-in-out"},"&:hover fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)"},"&.Mui-focused fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)",borderWidth:"2px"},"&.Mui-disabled":{backgroundColor:"var(--Background)",opacity:.6}},"& .MuiInputLabel-root":{color:I,transition:"all 0.2s ease-in-out",fontSize:"14px",fontWeight:500,"&.Mui-focused":{color:"var(--Text)",fontWeight:600},"&.Mui-error":{color:"var(--Text)"},"&.Mui-disabled":{color:"var(--Text-Secondary)",opacity:.6}},"& .MuiFormHelperText-root":{color:i?"var(--Buttons-Error-Border)":"var(--Text-Secondary)",marginTop:"4px",fontSize:"12px"},...x},...B}),i&&a&&de(k,{error:!0,sx:{color:"var(--Buttons-Error-Border)",marginTop:"4px",fontSize:"12px",fontWeight:500},children:a})]})}function Pl({label:e="Email",...t}){return de(El,{label:e,type:"email",placeholder:"user@example.com",...t})}function Ol({label:e="Password",...t}){return de(El,{label:e,type:"password",...t})}function Ll({label:e="Search",placeholder:t="Type to search...",...r}){return de(El,{label:e,type:"search",placeholder:t,...r})}function Ml({label:e="Number",...t}){return de(El,{label:e,type:"number",...t})}function Wl({label:e="Phone",placeholder:t="(555) 123-4567",...r}){return de(El,{label:e,type:"tel",placeholder:t,...r})}function Dl({label:e="Website",placeholder:t="https://example.com",...r}){return de(El,{label:e,type:"url",placeholder:t,...r})}function Fl({label:e,value:t="",onChange:o,placeholder:n,error:i=!1,errorMessage:a="",disabled:l=!1,helperText:s="",rows:d=4,required:c=!1,fullWidth:u=!0,sx:p={},...m}){const[f,g]=r(!1);return ce(h,{sx:{width:u?"100%":"auto"},children:[de(y,{label:e,value:t,onChange:o,placeholder:n,disabled:l,variant:"outlined",multiline:!0,rows:d,required:c,fullWidth:u,onFocus:()=>g(!0),onBlur:()=>g(!1),error:i,slotProps:{input:{"data-surface":l?"Container-Low":"Container",style:{color:"var(--Text)"}}},sx:{width:u?"100%":"auto","& .MuiOutlinedInput-root":{backgroundColor:"var(--Background)",transition:"all 0.2s ease-in-out",color:"var(--Text)","& fieldset":{borderColor:i?"var(--Buttons-Error-Border)":f?"var(--Buttons-Primary-Border)":"var(--Border)",transition:"border-color 0.2s ease-in-out"},"&:hover fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)"},"&.Mui-focused fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)",borderWidth:"2px"},"&.Mui-disabled":{backgroundColor:"var(--Background)",opacity:.6}},"& .MuiInputLabel-root":{color:i||f?"var(--Text)":"var(--Text-Quiet)",transition:"all 0.2s ease-in-out",fontSize:"14px",fontWeight:500,"&.Mui-focused":{color:"var(--Text)",fontWeight:600},"&.Mui-error":{color:"var(--Text)"},"&.Mui-disabled":{color:"var(--Text-Secondary)",opacity:.6}},...p},...m}),i&&a&&de(k,{error:!0,sx:{color:"var(--Buttons-Error-Border)",marginTop:"4px",fontSize:"12px",fontWeight:500},children:a})]})}function Nl({fields:e=[],spacing:t=2,sx:r={},...o}){return de(h,{sx:{display:"flex",flexDirection:"column",gap:`var(--Spacing-${t})`,width:"100%",...r},...o,children:e.map(e=>de(El,{...e},e.id))})}const Hl=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Vl=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Ql=[{value:"apple",label:"Apple"},{value:"banana",label:"Banana"},{value:"cherry",label:"Cherry"},{value:"date",label:"Date"},{value:"elderberry",label:"Elderberry"}],jl=[{value:"primary",label:"Primary",color:"var(--Buttons-Primary-Button)"},{value:"secondary",label:"Secondary",color:"var(--Buttons-Secondary-Button)"},{value:"tertiary",label:"Tertiary",color:"var(--Buttons-Tertiary-Button)"},{value:"neutral",label:"Neutral",color:"var(--Buttons-Neutral-Button)"},{value:"info",label:"Info",color:"var(--Buttons-Info-Button)"},{value:"success",label:"Success",color:"var(--Buttons-Success-Button)"},{value:"warning",label:"Warning",color:"var(--Buttons-Warning-Button)"},{value:"error",label:"Error",color:"var(--Buttons-Error-Button)"}];function Gl({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Ul({color:e,selected:t,onClick:r}){const o=Hl(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Xl(){const[e,t]=r("outline"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r("top"),[d,c]=r("Fruit"),[u,p]=r(!1),[m,f]=r(!1),[g,x]=r(!0),[b,v]=r(!1),[y,S]=r("Search"),[k,w]=r(""),[C,T]=r(null),[A,z]=r("Surface"),[R,E]=r(!1),[P,O]=r(!0);return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Select"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:C,surface:A,children:de(h,{sx:{width:"100%",maxWidth:360},children:de(Yn,{variant:e,color:o,size:i,label:d,labelPosition:l,mode:R?"color":void 0,showColorLabels:R?P:void 0,options:R?jl:Ql,value:k,onChange:w,showDividers:u,disabled:m,fullWidth:g,startDecoration:b?(()=>{const e=zt[y]||zt.Search;return de(jo,{size:"small",children:de(e,{})})})():void 0})})}),de(Ni,{code:(()=>{const t=[];return"outline"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),d&&t.push('label="'+d+'"'),"top"!==l&&t.push('labelPosition="'+l+'"'),R&&t.push('mode="color"'),R&&!P&&t.push("showColorLabels={false}"),u&&t.push("showDividers"),m&&t.push("disabled"),g&&t.push("fullWidth"),b&&t.push("startDecoration={<Icon><"+y+"Icon /></Icon>}"),t.push("options={options}"),t.push("value={value}"),t.push("onChange={setValue}"),"<Select\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:C,onThemeChange:T,surface:A,onSurfaceChange:z})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","light"].map(r=>de(Gl,{label:Hl(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Vl.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Ul,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Gl,{label:Hl(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL"}),de(B,{direction:"row",spacing:1,children:["top","floating","none"].map(e=>de(Gl,{label:"none"===e?"None":Hl(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Start Icon"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Icon rendered before the value"})]}),de(_i,{checked:b,onChange:e=>v(e.target.checked),size:"small","aria-label":"Start icon"})]}),b&&ce(h,{sx:{mt:2},children:[de(Xn,{label:"Icon Name",value:y,onChange:e=>S(e.target.value),placeholder:"Search",variant:"primary-outline",size:"small",fullWidth:!0}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:[de("a",{href:"https://mui.com/material-ui/material-icons/",target:"_blank",rel:"noopener noreferrer",style:{color:"var(--Hotlink)"},children:"Material icon"})," name (e.g. Search, Add, Edit, Filter, Sort, Star)"]})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Dividers"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Lines between options"})]}),de(_i,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Show dividers"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(_i,{checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Color Mode"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Render swatches alongside each option. Swatch size scales to Select height, radius follows the brand's button radius."})]}),de(_i,{checked:R,onChange:e=>E(e.target.checked),size:"small","aria-label":"Color mode"})]}),R&&ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Color Labels"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Hide to render a swatch-only trigger (no text). Useful for compact color pickers."})]}),de(_i,{checked:P,onChange:e=>O(e.target.checked),size:"small","aria-label":"Show color labels"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Full Width"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Stretch to container width"})]}),de(_i,{checked:g,onChange:e=>x(e.target.checked),size:"small","aria-label":"Full width"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Trigger",value:'role="combobox" aria-expanded="true|false" aria-haspopup="listbox"'},{label:"Dropdown",value:'role="listbox" aria-label="..."'},{label:"Options",value:'role="option" aria-selected="true|false"'},{label:"Label",value:"aria-label from label prop. Always provide a label."},{label:"Keyboard",value:"Enter/Space opens. Escape closes. Arrow keys when open."},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px (on outer shell)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Kl={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 8px",iconSize:16},medium:{height:"var(--Button-Height)",fontSize:"14px",padding:"6px 12px",iconSize:18},large:{height:"var(--Large-Button-Height)",fontSize:"16px",padding:"8px 16px",iconSize:20}},ql={small:{height:"48px",fontSize:"13px",padding:"20px 12px 4px",leftPad:12},medium:{height:"56px",fontSize:"14px",padding:"22px 14px 6px",leftPad:14},large:{height:"64px",fontSize:"16px",padding:"24px 16px 6px",leftPad:16}};function Jl({options:e=[],value:t,defaultValue:a=null,onChange:l,inputValue:s,onInputChange:d,label:c,labelPosition:u="top",placeholder:p="Type to search",helperText:m,size:f="medium",variant:g="outline",color:x="primary",loading:b=!1,loadingText:v="Loading…",noOptionsText:y="No options",freeSolo:S=!1,clearable:k=!0,disabled:B=!1,fullWidth:w=!1,className:C="",sx:T={},...I}){const A=(z="default"===x?"primary":x).charAt(0).toUpperCase()+z.slice(1);var z;const R="var(--Buttons-"+A+"-Border)",E="default"===x?"var(--Text)":"var(--Text-"+A+")",[P,O]=r(a),[L,M]=r(a?"string"==typeof a?a:a.label||"":""),[W,D]=r(!1),[F,N]=r(!1),[H,V]=r(-1),Q=o(null),j=o(null),G=void 0!==t,U=void 0!==s,X=G?t:P,K=U?s:L,q="floating"===u,J="top"===u,Y=""!==K,$=q?ql[f]||ql.medium:Kl[f]||Kl.medium,Z=K?e.filter(e=>("string"==typeof e?e:e.label).toLowerCase().includes(K.toLowerCase())):e,_=n(e=>{U||M(e),d?.(e)},[U,d]),ee=n(e=>{const t="string"==typeof e?e:e.label;G||O(e),_(t),l?.(e),D(!1),V(-1),j.current?.focus()},[G,l,_]);i(()=>{if(!W)return;const e=e=>{Q.current&&!Q.current.contains(e.target)&&D(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[W]);return ce(h,{ref:Q,className:"autocomplete autocomplete-"+f+" autocomplete-variant-"+g+(W?" autocomplete-open":"")+(B?" autocomplete-disabled":"")+(C?" "+C:""),sx:{position:"relative",width:w?"100%":"auto",display:"inline-block",fontFamily:"inherit",...T},...I,children:[J&&c&&de("small"===f?ao:co,{component:"label",style:{display:"block",marginBottom:"6px",color:B?"var(--Quiet)":"var(--Text)",fontWeight:500,opacity:B?.6:1},children:c}),de(h,{sx:{border:"1px solid "+R,borderRadius:"small"===f?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===f?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease",boxShadow:"none",opacity:B?.5:1,"&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{children:ce(h,{sx:{position:"relative",display:"flex",alignItems:"center",minHeight:$.height,backgroundColor:"var(--Hover)"},children:[q&&c&&de(h,{sx:{position:"absolute",top:Y||F?"6px":"50%",left:($.leftPad||14)+"px",transform:Y||F?"scale(0.75)":"translateY(-50%)",transformOrigin:"top left",color:F?E:"var(--Quiet)",fontSize:$.fontSize,fontWeight:400,pointerEvents:"none",zIndex:1,transition:"top 0.15s ease, transform 0.15s ease, color 0.15s ease"},children:c}),de(h,{component:"input",ref:j,type:"text",role:"combobox","aria-expanded":W,"aria-haspopup":"listbox","aria-autocomplete":"list","aria-label":c||p,autoComplete:"off",value:K,onChange:e=>{_(e.target.value),W||D(!0),V(-1)},onKeyDown:e=>{if("Escape"!==e.key){if("ArrowDown"===e.key){if(e.preventDefault(),!W)return void D(!0);V(e=>Math.min(e+1,Z.length-1))}"ArrowUp"===e.key&&(e.preventDefault(),V(e=>Math.max(e-1,0))),"Enter"===e.key&&W&&H>=0&&Z[H]&&(e.preventDefault(),ee(Z[H]))}else D(!1)},onFocus:()=>{N(!0),D(!0)},onBlur:()=>N(!1),disabled:B,placeholder:q?void 0:p,sx:{flex:1,border:"none",outline:"none",backgroundColor:"transparent",color:Y||F?E:"var(--Quiet)",fontSize:$.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)",padding:$.padding,minWidth:0,"&::placeholder":{color:"var(--Quiet)",opacity:1,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)"},"&:disabled":{cursor:"not-allowed"}}}),b&&W&&de(Vt,{size:16,sx:{mr:1,color:"var(--Quiet)"}}),k&&K&&!B&&de(h,{component:"button",type:"button","aria-label":"Clear",onClick:()=>{G||O(null),_(""),l?.(null),j.current?.focus()},sx:{display:"flex",alignItems:"center",justifyContent:"center",width:20,height:20,borderRadius:"50%",mr:.5,border:"none",backgroundColor:"transparent",color:"var(--Quiet)",cursor:"pointer","&:hover":{color:"var(--Text)",backgroundColor:"var(--Hover)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)"}},children:de(Ot,{sx:{fontSize:14}})}),de(h,{component:"button",type:"button","aria-label":W?"Close":"Open",tabIndex:-1,onClick:()=>{B||D(!W)},sx:{display:"flex",alignItems:"center",justifyContent:"center",width:28,height:"100%",border:"none",backgroundColor:"transparent",color:"var(--Quiet)",cursor:B?"not-allowed":"pointer"},children:de(Se,{sx:{fontSize:($.iconSize||18)+"px",transform:W?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"}})})]})})}),m&&de(h,{sx:{fontSize:"12px",color:"var(--Quiet)",mt:"4px",ml:"2px"},children:m}),W&&de(h,{role:"listbox","aria-label":c||"Options",sx:{position:"absolute",top:"100%",left:0,right:0,mt:.5,backgroundColor:"var(--Hover)",border:"1px solid var(--Buttons-Default-Border)",borderRadius:"var(--Style-Border-Radius)",boxShadow:"none",zIndex:9999,maxHeight:240,overflowY:"auto",py:.5},children:b?de(h,{sx:{px:1.5,py:2,textAlign:"center",fontSize:$.fontSize,color:"var(--Quiet)"},children:v}):0===Z.length?de(h,{sx:{px:1.5,py:2,textAlign:"center",fontSize:$.fontSize,color:"var(--Quiet)"},children:y}):Z.map((e,t)=>{const r="string"==typeof e?e:e.label,o="string"==typeof e?e:e.value,n=r===(X?"string"==typeof X?X:X.label:null),i=function(e,t){return t?{backgroundColor:"transparent",color:"var(--Text)",fontWeight:600}:e?{backgroundColor:"var(--Hover)",color:"var(--Text)"}:{backgroundColor:"transparent",color:"var(--Text-Quiet)"}}(t===H,n);return ce(h,{role:"option","aria-selected":n,onClick:()=>ee(e),onMouseEnter:()=>V(t),sx:{display:"flex",alignItems:"center",gap:1,px:1.5,py:0,mx:.5,minHeight:$.height,borderRadius:"4px",cursor:"pointer",fontSize:$.fontSize,fontFamily:"inherit",...i,transition:"background-color 0.1s ease","&:active":{backgroundColor:"var(--Pressed)"}},children:[de(ao,{style:{flex:1,color:"inherit",fontWeight:"inherit"},children:r}),n&&de(jo,{size:"small",sx:{opacity:.6,flexShrink:0},children:de(he,{})})]},o||r)})})]})}const Yl=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",$l=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Zl=[{value:"apple",label:"Apple"},{value:"banana",label:"Banana"},{value:"cherry",label:"Cherry"},{value:"date",label:"Date"},{value:"elderberry",label:"Elderberry"},{value:"fig",label:"Fig"},{value:"grape",label:"Grape"}];function _l({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function es({color:e,selected:t,onClick:r}){const o=Yl(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function ts(){const[e,t]=r("outline"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r("top"),[d,c]=r("Fruit"),[u,p]=r(!0),[m,f]=r(!1),[g,x]=r(!0),[b,v]=r(null),[y,S]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Autocomplete"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:b,surface:y,children:de(h,{sx:{width:"100%",maxWidth:360},children:de(Jl,{variant:e,color:o,size:i,label:d,labelPosition:l,options:Zl,clearable:u,disabled:m,fullWidth:g})})}),de(Ni,{code:(()=>{const t=[];return"outline"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),d&&t.push('label="'+d+'"'),"top"!==l&&t.push('labelPosition="'+l+'"'),u||t.push("clearable={false}"),m&&t.push("disabled"),g&&t.push("fullWidth"),t.push("options={options}"),t.push("onChange={handleChange}"),"<Autocomplete\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:b,onThemeChange:v,surface:y,onSurfaceChange:S})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","light"].map(r=>de(_l,{label:Yl(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:$l.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(es,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(_l,{label:Yl(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL"}),de(B,{direction:"row",spacing:1,children:["top","floating","none"].map(e=>de(_l,{label:"none"===e?"None":Yl(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clearable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show clear button when has value"})]}),de(_i,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Clearable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(_i,{checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Full Width"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Stretch to container width"})]}),de(_i,{checked:g,onChange:e=>x(e.target.checked),size:"small","aria-label":"Full width"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Input",value:'role="combobox" aria-expanded aria-haspopup="listbox" aria-autocomplete="list"'},{label:"Dropdown",value:'role="listbox" aria-label="..."'},{label:"Options",value:'role="option" aria-selected="true|false"'},{label:"Label",value:"aria-label from label prop. Always provide a label."},{label:"Keyboard",value:"Arrow keys navigate, Enter selects, Escape closes."},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px (on outer shell)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const rs=["default","primary","secondary","tertiary","neutral","info","success","warning","error"],os={small:{touchTarget:24,box:16,dot:8,gap:4,LabelComp:ao},medium:{touchTarget:24,box:20,dot:9.5,gap:8,LabelComp:co},large:{touchTarget:24,box:24,dot:9.5,gap:12,LabelComp:fo}};function ns({size:e,color:t,checked:r}){const o=(n=t).charAt(0).toUpperCase()+n.slice(1);var n;const i="var(--Buttons-"+o+"-Border)",a="var(--Buttons-"+o+"-Border)",l=os[e]||os.medium;return de(h,{className:"radio-circle-icon",sx:{width:l.box,height:l.box,boxSizing:"border-box",borderRadius:"50%",border:"2px solid "+i,overflow:"hidden",flexShrink:0,backgroundColor:"var(--Background)",display:"flex",alignItems:"center",justifyContent:"center",transition:"border-color 0.15s ease-in-out"},children:r&&de(h,{sx:{width:l.dot,height:l.dot,borderRadius:"50%",backgroundColor:a,transition:"transform 0.15s ease-in-out"}})})}function is({color:e="primary",size:t="medium",label:r,labelPlacement:o="end",checked:n,disabled:i=!1,onChange:a,name:l,value:s,className:d="",sx:c={},"aria-label":u,"aria-labelledby":p,"aria-describedby":h,inputProps:m={},...f}){const g=rs.includes(e)?e:"primary",x=os[t]||os.medium,b=x.LabelComp,y=(x.touchTarget-x.box)/2,S={...m,...u&&{"aria-label":u},...p&&{"aria-labelledby":p},...h&&{"aria-describedby":h}},k=de(P,{checked:n,disabled:i,onChange:a,name:l,value:s,icon:de(ns,{size:t,color:g,checked:!1}),checkedIcon:de(ns,{size:t,color:g,checked:!0}),className:"radio-"+g+" "+d,inputProps:S,disableRipple:!0,sx:{padding:y+"px",width:x.touchTarget,height:x.touchTarget,minWidth:x.touchTarget,minHeight:x.touchTarget,boxSizing:"border-box",borderRadius:"50%",color:"inherit",transition:"background-color 0.15s ease-in-out","&.Mui-checked":{color:"inherit"},"&:hover":{backgroundColor:"transparent"},"&.Mui-focusVisible .radio-circle-icon":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none"},...c},...f});return r?de(v,{control:k,label:de(b,{component:"span",sx:{color:i?"var(--Text-Quiet)":"var(--Text)",lineHeight:1.4,userSelect:"none"},children:r}),labelPlacement:o,disabled:i,sx:{marginLeft:0,marginRight:0,gap:x.gap+"px",alignItems:"center","&.Mui-disabled .MuiTypography-root":{color:"var(--Text-Quiet)",opacity:.6}}}):k}function as({color:e="primary",size:t="medium",label:r,options:o=[],value:n,onChange:i,orientation:a="vertical",labelPlacement:l="end",disabled:s=!1,spacing:d=1,name:c,className:u="",sx:p={},"aria-label":h,"aria-labelledby":m,...f}){return ce(O,{component:"fieldset",disabled:s,className:"radio-group-"+e+" "+u,sx:p,children:[r&&de(L,{component:"legend",sx:{color:s?"var(--Text-Quiet)":"var(--Text)",fontSize:"small"===t?"13px":"15px",fontWeight:500,mb:1,"&.Mui-focused":{color:"var(--Text)"},"&.Mui-disabled":{color:"var(--Text-Quiet)",opacity:.6}},children:r}),de(M,{value:n,onChange:i,name:c,"aria-label":h,"aria-labelledby":m,row:"horizontal"===a,sx:{display:"flex",flexDirection:"horizontal"===a?"row":"column",flexWrap:"horizontal"===a?"wrap":"nowrap",alignItems:"horizontal"===a?"center":"flex-start",gap:d},...f,children:o.map(r=>de(is,{color:e,size:t,label:r.label,labelPlacement:l,value:r.value,disabled:r.disabled||s},r.value))})]})}const ls=is,ss=["default","primary","secondary","tertiary","neutral","info","success","warning","error"];const ds={small:{visual:12,track:2,labelSize:11},medium:{visual:16,track:4,labelSize:12},large:{visual:20,track:6,labelSize:13}};function cs({variant:e="primary",size:t="medium",value:r,defaultValue:o,onChange:n,onChangeCommitted:i,min:a=0,max:l=100,step:s=1,marks:d=!1,valueLabelDisplay:c="off",orientation:u="horizontal",track:p="normal",disabled:m=!1,label:f,name:g,className:x="",sx:b={},"aria-label":v,"aria-labelledby":y,...S}){const k=function(){const e={};return ss.forEach(t=>{e[t]=function(e){const t=(r=e).charAt(0).toUpperCase()+r.slice(1);var r;return{thumb:"var(--Buttons-"+t+"-Button)",thumbBorder:"1px solid var(--Buttons-"+t+"-Border)",track:"var(--Buttons-"+t+"-Button)",trackBorder:"1px solid var(--Buttons-"+t+"-Border)",rail:"var(--Border-Variant)",valueLabel:"var(--Buttons-"+t+"-Text)",valueLabelText:"var(--Buttons-"+t+"-Button)"}}(t)}),e}(),B=k[e]||k.primary,w=ds[t]||ds.medium,C="vertical"===u,T=Array.isArray(r)||Array.isArray(o),I="inverted"===p,A="small"===t?ao:co,z=w.track+2,R=I?B.track:B.rail,E=I?B.trackBorder:null,P=I?B.rail:B.track,O=I?null:B.trackBorder,L={color:"transparent"===B.track?B.thumb:B.track,height:C?void 0:z,width:C?z:void 0,"& .MuiSlider-rail":{backgroundColor:R,border:E||"none",boxSizing:E?"content-box":"border-box",opacity:1,height:C?void 0:E?w.track:z,width:C?E?w.track:z:void 0,borderRadius:z/2},"& .MuiSlider-track":{boxSizing:O?"content-box":"border-box",backgroundColor:P,border:O||"none",height:C?void 0:O?w.track:z,width:C?O?w.track:z:void 0,borderRadius:z/2},"& .MuiSlider-thumb":{width:24,height:24,backgroundColor:"transparent",border:"none",boxShadow:"none",transition:"none","--_height":w.visual+"px","--_bevel":"min(calc(var(--Button-Bevel) * var(--_height) / 100), calc(var(--_height) / 5))","&::after":{display:"none"},"&::before":{content:'""',position:"absolute",width:w.visual,height:w.visual,borderRadius:"50%",backgroundColor:B.thumb,border:B.thumbBorder||"none",boxShadow:`${mn(e)}, ${nn}`,transition:"box-shadow 0.15s ease-in-out",top:"50%",left:"50%",transform:"translate(-50%, -50%)"},"&:hover::before":{boxShadow:`${mn(e)}, ${an}`},"&.Mui-active::before":{boxShadow:mn(e)},"&.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px",borderRadius:"50%"},"&.Mui-focusVisible::before":{boxShadow:`${mn(e)}, ${an}`}},...T?C?{'& .MuiSlider-thumb[data-index="0"]::before':{top:0,left:"50%",transform:"translateX(-50%)"},'& .MuiSlider-thumb[data-index="1"]::before':{top:"auto",bottom:0,left:"50%",transform:"translateX(-50%)"}}:{'& .MuiSlider-thumb[data-index="0"]::before':{left:"auto",right:0,top:"50%",transform:"translateY(-50%)"},'& .MuiSlider-thumb[data-index="1"]::before':{left:0,right:"auto",top:"50%",transform:"translateY(-50%)"}}:{},"& .MuiSlider-valueLabel":{backgroundColor:B.valueLabel,color:B.valueLabelText,fontSize:w.labelSize,fontWeight:600,borderRadius:"6px",padding:"2px 8px","&::before":{backgroundColor:B.valueLabel}},"& .MuiSlider-mark":{backgroundColor:B.rail,width:C?z:2,height:C?2:z,borderRadius:1},"& .MuiSlider-markActive":{backgroundColor:B.thumb,opacity:.6},"& .MuiSlider-markLabel":{color:"var(--Text-Quiet)",fontSize:w.labelSize},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none","& .MuiSlider-thumb::before":{boxShadow:"none"}},...b},M=de(W,{value:r,defaultValue:o,onChange:n,onChangeCommitted:i,min:a,max:l,step:s,marks:d,valueLabelDisplay:c,orientation:u,track:"inverted"===p?"inverted":!1!==p&&"normal",disabled:m,name:g,"aria-label":v,"aria-labelledby":y,className:"slider-"+e+" "+x,sx:L,...S});return f?ce(h,{sx:{width:C?"auto":"100%",height:C?"100%":"auto",display:"flex",flexDirection:"column",gap:"4px"},children:[de(A,{component:"label",sx:{color:m?"var(--Text-Quiet)":"var(--Text)",fontSize:"small"===t?"13px":"15px",fontWeight:500,opacity:m?.6:1},children:f}),M]}):M}const us=cs,ps=cs,hs={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ms={small:{iconSize:16,minHit:24,gap:0,focusInset:-3,focusWidth:3},medium:{iconSize:24,minHit:24,gap:0,focusInset:-3,focusWidth:3},large:{iconSize:36,minHit:void 0,gap:2,focusInset:2,focusWidth:2}};function fs({value:e,defaultValue:t,onChange:o,max:n=5,precision:i=1,color:a="default",size:l="medium",readOnly:s=!1,disabled:d=!1,emptyLabel:c="No rating",className:u="",sx:p={},...m}){const[f,g]=r(t??null),[x,b]=r(null),v=void 0!==e,y=v?e:f,S=null!==x?x:y,k=.5===i,B=!s&&!d,w=hs[a]||hs.default,C=ms[l]||ms.medium,T="var(--Buttons-"+w+"-Button)",I="var(--Buttons-"+w+"-Border)",A=e=>{if(!B)return;const t=e===y?null:e;v||g(t),o?.(t)},z=(e,t)=>{if(!B||!k)return;b(t?e+.5:e+1)},R=B?{"&:hover":{filter:"drop-shadow(0 2px 4px rgba(var(--Dropshadow-Color), 0.22)) drop-shadow(0 1px 2px rgba(var(--Dropshadow-Color), 0.28))","& .MuiSvgIcon-root":{stroke:"var(--Buttons-"+w+"-Border)",strokeWidth:1}}}:{},E=e=>{const t=e+1,r=e+.5,o=null!==S&&t<=S,a=null!==S&&!o&&k&&r<=S,l=a?Qt:Ie,s=((e,t)=>e||t?{color:T,filter:"drop-shadow(0 1px 2px rgba(var(--Dropshadow-Color), 0.28))",transition:"filter 0.15s ease","& .MuiSvgIcon-root":{stroke:I,strokeWidth:.5}}:{color:"transparent","& .MuiSvgIcon-root":{stroke:"var(--Quiet)",strokeWidth:1}})(o,a);return k&&B?ce(h,{sx:{position:"relative",display:"inline-flex",cursor:"pointer",...s,...R},onMouseLeave:()=>b(null),children:[de(h,{sx:{position:"absolute",left:0,top:0,width:"50%",height:"100%",zIndex:1,cursor:"pointer"},onMouseEnter:()=>z(e,!0),onClick:()=>A(r)}),de(h,{sx:{position:"absolute",right:0,top:0,width:"50%",height:"100%",zIndex:1,cursor:"pointer"},onMouseEnter:()=>z(e,!1),onClick:()=>A(t)}),de(l,{sx:{fontSize:C.iconSize,transition:"color 0.1s ease, filter 0.1s ease"}})]},e):de(h,{component:B?"button":"span",type:B?"button":void 0,role:B?"radio":void 0,"aria-checked":o,"aria-label":t+" star"+(1!==t?"s":""),tabIndex:B?0:-1,onClick:()=>A(t),onMouseEnter:()=>B&&b(t),onMouseLeave:()=>B&&b(null),onKeyDown:e=>{if(B&&("ArrowRight"!==e.key&&"ArrowUp"!==e.key||(e.preventDefault(),A(Math.min((y||0)+i,n))),"ArrowLeft"===e.key||"ArrowDown"===e.key)){e.preventDefault();const t=Math.max((y||0)-i,0);A(t||null)}},sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",border:"none",backgroundColor:"transparent",padding:0,...C.minHit&&{minWidth:C.minHit+"px",minHeight:C.minHit+"px"},cursor:d?"not-allowed":B?"pointer":"default",outline:"none",transition:"transform 0.1s ease",...s,...R,"&:active":B?{transform:"scale(0.95)"}:{},"&:focus-visible":B?{outline:C.focusWidth+"px solid var(--Focus-Visible)",outlineOffset:C.focusInset+"px",borderRadius:"2px"}:{},"&:disabled":{cursor:"not-allowed",opacity:.5}},children:de(l,{sx:{fontSize:C.iconSize,transition:"color 0.1s ease, filter 0.1s ease"}})},e)};return ce(h,{role:B?"radiogroup":"img","aria-label":"Rating"+(null!==y?": "+y+" of "+n+" stars":": "+c),className:"rating rating-"+a+" rating-"+l+(s?" rating-readonly":"")+(d?" rating-disabled":"")+(null===y?" rating-empty":"")+(u?" "+u:""),sx:{display:"inline-flex",alignItems:"center",gap:C.gap+"px",opacity:d?.5:1,fontFamily:"inherit",...p},...m,children:[Array.from({length:n},(e,t)=>E(t)),null===y&&!x&&de(bo,{style:{color:"var(--Quiet)",marginLeft:4},children:c})]})}const gs={small:{height:"var(--Small-Button-Height)",fontSize:"13px",iconSize:18,px:12},medium:{height:"var(--Button-Height)",fontSize:"14px",iconSize:20,px:16},large:{height:"var(--Large-Button-Height)",fontSize:"15px",iconSize:22,px:16}};function xs({value:e,defaultValue:t="",onChange:n,onFocus:i,onBlur:a,onClear:l,onSubmit:s,placeholder:d="Search…",size:c="medium",color:u="default",showClearButton:p=!0,disabled:m=!1,ariaLabel:f="Search",className:g="",sx:x={},...b}){const[v,y]=r(t),[S,k]=r(!1),B=o(null),w=void 0!==e,C=w?e:v,T=C.length>0,I=S||T,A=(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===u?"primary":u),z="default"===u?"var(--Text)":"var(--Text-"+A+")",R=gs[c]||gs.medium,E=()=>{w||y(""),n?.(""),l?.(),B.current?.focus()};return de(h,{className:"search-field search-field-"+c+(S?" search-field-focused":"")+(T?" search-field-filled":"")+(m?" search-field-disabled":"")+(g?" "+g:""),sx:{display:"flex",boxSizing:"border-box",...x},...b,children:de(h,{sx:{border:"1px solid "+("var(--Buttons-"+A+"-Border)"),borderRadius:"small"===c?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===c?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",opacity:m?.5:1,transition:"border-color 0.15s ease, box-shadow 0.15s ease",boxShadow:"none",width:"100%","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:ce(h,{sx:{display:"flex",alignItems:"center",gap:1,width:"100%",boxSizing:"border-box",minHeight:R.height,px:R.px+"px",backgroundColor:"var(--Hover)"},children:[de(jo,{size:"small",sx:{color:I?z:"var(--Quiet)",flexShrink:0,transition:"color 0.15s ease"},children:de(Te,{})}),de(h,{component:"input",ref:B,type:"text",role:"searchbox","aria-label":f,value:C,onChange:e=>{const t=e.target.value;w||y(t),n?.(t,e)},onFocus:e=>{k(!0),i?.(e)},onBlur:e=>{k(!1),a?.(e)},onKeyDown:e=>{"Enter"===e.key&&s?.(C,e),"Escape"===e.key&&T&&E()},placeholder:d,disabled:m,sx:{flex:1,border:"none",outline:"none",backgroundColor:"transparent",color:I?z:"var(--Quiet)",fontSize:R.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)",minWidth:0,"&::placeholder":{color:"var(--Quiet)",opacity:1,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)"},"&:disabled":{cursor:"not-allowed"}}}),p&&T&&!m&&de(h,{component:"button",type:"button","aria-label":"Clear search",onClick:E,sx:{display:"flex",alignItems:"center",justifyContent:"center",width:R.iconSize+4,height:R.iconSize+4,borderRadius:"50%",border:"none",backgroundColor:"transparent",color:"var(--Quiet)",cursor:"pointer",flexShrink:0,padding:0,transition:"color 0.15s ease, background-color 0.15s ease","&:hover":{backgroundColor:"var(--Hover)",color:z},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px"}},children:de(jo,{size:"small",children:de(Ot,{})})})]})})})}const bs=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",vs=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function ys({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Ss({color:e,selected:t,onClick:r}){const o=bs(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function ks(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(!1),[l,s]=r(!0),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Search Field"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:400},children:de(xs,{color:e,size:o,disabled:i,showClearButton:l,placeholder:"Search..."})})}),de(Ni,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),l||t.push("showClearButton={false}"),i&&t.push("disabled"),t.push('placeholder="Search..."'),t.push("onChange={handleSearch}"),"<SearchField\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:vs.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(Ss,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(ys,{label:bs(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clear Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show clear when has value"})]}),de(_i,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Clear button"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(_i,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Disabled"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="searchbox" on the input element'},{label:"Label",value:'aria-label="Search" (configurable via ariaLabel prop)'},{label:"Clear",value:'aria-label="Clear search" on clear button'},{label:"Keyboard",value:"Enter submits, Escape clears"},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Bs=["primary","secondary","tertiary","neutral","info","success","warning","error"],ws=e=>e.charAt(0).toUpperCase()+e.slice(1);function Cs(){const e={};return Bs.forEach(t=>{e[t]=function(e){const t=ws(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"none",hoverBg:"var(--Buttons-"+t+"-Hover)",activeBg:"var(--Buttons-"+t+"-Pressed)"}}(t),e[t+"-outline"]=function(e){return{bg:"var(--Background)",text:"var(--Text)",border:"1px solid var(--Buttons-"+ws(e)+"-Border)",hoverBg:"var(--Hover)",activeBg:"var(--Hover)"}}(t),e[t+"-light"]=function(e){const t=ws(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"1px solid var(--Buttons-"+t+"-Border)",hoverBg:"var(--Buttons-"+t+"-Hover)",activeBg:"var(--Buttons-"+t+"-Pressed)"}}(t)}),e}const Ts={small:{height:24,fontSize:"12px",iconSize:16,padding:"0 8px",deleteSize:16,gap:4},medium:{height:32,fontSize:"13px",iconSize:18,padding:"0 12px",deleteSize:18,gap:6},large:{height:40,fontSize:"14px",iconSize:20,padding:"0 16px",deleteSize:24,gap:8}},Is=c(function({size:e,onClick:t,...r},o){const n="large"===e?24:"medium"===e?18:16;return de(h,{ref:o,component:"button",onClick:e=>{e.stopPropagation(),t&&t(e)},onKeyDown:e=>{"Enter"!==e.key&&"Backspace"!==e.key&&"Delete"!==e.key||(e.stopPropagation(),t&&t(e))},"aria-label":"Remove",role:"button",tabIndex:0,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",minWidth:24,minHeight:24,width:n,height:n,padding:0,margin:0,marginLeft:"2px",marginRight:"-4px",border:"none",borderRadius:"50%",backgroundColor:"transparent",color:"inherit",opacity:.7,cursor:"pointer",position:"relative",flexShrink:0,transition:"opacity 0.15s ease, background-color 0.15s ease","&:hover":{opacity:1,backgroundColor:"rgba(0,0,0,0.08)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px"},...n<24&&{"&::after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",minWidth:24,minHeight:24}}},...r,children:de(jt,{sx:{fontSize:n,pointerEvents:"none"}})})});function As({variant:e="primary",size:t="medium",label:r,clickable:o=!1,disabled:n=!1,selected:i=!1,selectionMode:a,onDelete:l,onClick:s,startDecorator:d,endDecorator:c,children:u,className:p="",sx:m={},...f}){const g=Cs(),x=g[e]||g.primary,b=l?"large":t,v=Ts[b]||Ts.medium,y=o||!!s||!!a,S={};"radio"===a?(S.role="radio",S["aria-checked"]=i):"checkbox"===a&&(S.role="checkbox",S["aria-checked"]=i);const k=i?{outline:"2px solid var(--Buttons-Primary-Button)",outlineOffset:"1px"}:{},B=r||u,w={height:v.height,fontSize:v.fontSize,fontWeight:500,fontFamily:"inherit",borderRadius:v.height/2+"px",padding:v.padding,boxSizing:"border-box",position:"relative",backgroundColor:x.bg,color:x.text,border:x.border,...k,..."small"===b&&{"&::after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",minWidth:24,minHeight:24,width:"100%",height:"100%"}},...y&&!n?{cursor:"pointer",transition:"background-color 0.15s ease, outline 0.15s ease","&:hover":{backgroundColor:x.hoverBg},"&:active":{backgroundColor:x.activeBg}}:{},"&:focus-visible, &.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},...n?{opacity:.5,cursor:"not-allowed",pointerEvents:"none"}:{},boxShadow:"none","& .MuiChip-label":{padding:0,fontSize:"inherit",fontWeight:"inherit",fontFamily:"inherit",lineHeight:1.2,display:"flex",alignItems:"center",gap:v.gap+"px"},"& .MuiChip-icon":{margin:0,marginLeft:"-2px",color:"inherit",fontSize:v.iconSize},"& .MuiChip-deleteIcon":{display:"none"},...m},C=ce(h,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:v.gap+"px",lineHeight:1},children:[d&&de(h,{component:"span",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,"& .MuiSvgIcon-root":{fontSize:v.iconSize},"& .MuiAvatar-root":{width:v.iconSize+4,height:v.iconSize+4,fontSize:Math.round(.65*v.iconSize)+"px"}},children:d}),B,c&&de(h,{component:"span",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,"& .MuiSvgIcon-root":{fontSize:v.iconSize},"& .MuiAvatar-root":{width:v.iconSize+4,height:v.iconSize+4,fontSize:Math.round(.65*v.iconSize)+"px"}},children:c}),l&&de(Is,{size:b,onClick:l})]});return de(D,{label:C,clickable:y&&!n,disabled:n,onClick:y?s:void 0,className:"chip-"+e+" "+p,sx:w,...S,...f})}const zs={body:{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Letter-Spacing)"},"body-small":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Small-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Small-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Small-Letter-Spacing)"},"body-large":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Large-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Large-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Large-Letter-Spacing)"},"body-semibold":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Font-Size)",fontWeight:"var(--Body-Semibold-Font-Weight)",letterSpacing:"var(--Body-Letter-Spacing)"},"body-bold":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Font-Size)",fontWeight:"var(--Body-Bold-Font-Weight)",letterSpacing:"var(--Body-Letter-Spacing)"},button:{fontFamily:"var(--Body-Font-Family)",lineHeight:"var(--Button-Line-Height)",fontSize:"var(--Button-Font-Size)",fontWeight:"var(--Button-Font-Weight)",letterSpacing:"var(--Button-Letter-Spacing)"},label:{fontFamily:"var(--Body-Font-Family)",lineHeight:"var(--Label-Line-Height)",fontSize:"var(--Label-Font-Size)",fontWeight:"var(--Label-Font-Weight)",letterSpacing:"var(--Label-Letter-Spacing)"},caption:{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Small-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Small-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Small-Letter-Spacing)"}},Rs="var(--Link-Visited, var(--Hotlink-Visited))",Es={primary:{base:"var(--Link, var(--Hotlink))",visited:Rs},standard:{base:"var(--Text)",visited:Rs},quiet:{base:"var(--Text-Quiet)",visited:Rs}};function Ps({children:e,href:t,target:r,rel:o,textStyle:n="body",color:i="primary",disabled:a=!1,onClick:l,className:s="",sx:d={},...c}){const u=zs[n]||zs.body,p=Es[i]||Es.primary;return de(h,{component:"a",href:a?void 0:t,target:r,rel:"_blank"===r?o||"noopener noreferrer":o,onClick:a?e=>e.preventDefault():l,"aria-disabled":a||void 0,tabIndex:a?-1:void 0,className:"link link-"+n+" link-color-"+i+(a?" link-disabled":"")+" "+s,sx:{fontFamily:u.fontFamily,lineHeight:u.lineHeight,fontSize:u.fontSize,fontWeight:u.fontWeight,letterSpacing:u.letterSpacing,textDecoration:"underline",textUnderlineOffset:"3px",textDecorationThickness:"1px",color:p.base,cursor:a?"not-allowed":"pointer",opacity:a?.5:1,pointerEvents:a?"none":"auto",display:"inline-flex",alignItems:"center",minHeight:"24px",minWidth:"24px",transition:"color 0.15s ease, text-decoration-color 0.15s ease",...!a&&{"&:hover":{textDecorationThickness:"2px"},"&:visited":{color:p.visited},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px",borderRadius:"2px"},"&:active":{textDecorationThickness:"2px"}},...d},...c,children:e})}function Os({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"primary":"primary-outline",size:"small",onClick:r,children:e})}function Ls({code:e}){return de(Ni,{code:e,language:"JSX",wrap:!0,sx:{mt:1}})}function Ms({passes:e}){return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5,px:1.5,py:.5,borderRadius:"20px",backgroundColor:e?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:e?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)",fontSize:"12px",fontWeight:600},children:[de(e?ge:xe,{sx:{fontSize:14}}),e?"WCAG Pass":"WCAG Fail"]})}function Ws({leftLabel:e,rightLabel:t,leftContent:r,rightContent:o,leftCode:n,rightCode:i,leftPasses:a,rightPasses:l}){return ce(I,{container:!0,spacing:3,children:[de(I,{item:!0,xs:12,md:6,children:ce(h,{sx:{p:2,border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:"var(--Background)",height:"100%"},children:[ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[de(ao,{style:{fontWeight:600},children:e}),de(Ms,{passes:a})]}),de(h,{sx:{p:2,backgroundColor:"var(--Surface-Dim, var(--Surface))",borderRadius:"var(--Style-Border-Radius)",minHeight:80},children:r}),de(Ls,{code:n})]})}),de(I,{item:!0,xs:12,md:6,children:ce(h,{sx:{p:2,border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:"var(--Background)",height:"100%"},children:[ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[de(ao,{style:{fontWeight:600},children:t}),de(Ms,{passes:l})]}),de(h,{sx:{p:2,backgroundColor:"var(--Surface-Dim, var(--Surface))",borderRadius:"var(--Style-Border-Radius)",minHeight:80},children:o}),de(Ls,{code:i})]})})]})}function Ds(){const[e,t]=r("column"),[o,n]=r(.5),[i,a]=r("small"),[l,s]=r(!0),[d,c]=r(!1),[u,p]=r(null),[m,f]=r("Surface"),g={small:{label:"Small links ⚡",content:ce(ue,{children:[de(Ps,{href:"#",size:"small",children:"Terms of Service"}),de(Ps,{href:"#",size:"small",children:"Privacy Policy"}),de(Ps,{href:"#",size:"small",children:"Cookie Settings"})]})},chips:{label:"Chips ⚡",content:ce(ue,{children:[de(As,{label:"React",size:"small"}),de(As,{label:"TypeScript",size:"small"}),de(As,{label:"Design System",size:"small"})]})},normal:{label:"Normal buttons",content:ce(ue,{children:[de(Tn,{variant:"primary",size:"medium",children:"Primary"}),de(Tn,{variant:"secondary",size:"medium",children:"Secondary"})]})},mixed:{label:"Mixed ⚡",content:ce(ue,{children:[de(Tn,{variant:"primary",size:"medium",children:"Save changes"}),de(Ps,{href:"#",size:"small",children:"Or discard"})]})}},x=["small","chips","mixed"].includes(i),b=l&&x;return ce(I,{container:!0,spacing:3,sx:{mt:1},children:[ce(I,{item:!0,xs:12,md:7,children:[de(li,{theme:u,children:ce(h,{sx:{width:"100%"},children:[b&&ce(h,{sx:{mb:2,px:2,py:1,borderRadius:"var(--Style-Border-Radius)",backgroundColor:"var(--Tags-Warning-BG)",color:"var(--Tags-Warning-Text)",fontSize:"12px",fontWeight:600,display:"flex",alignItems:"center",gap:1},children:[de(xe,{sx:{fontSize:16}}),"Small child detected — gap raised to var(--min-stack-gap)"]}),de(ba,{direction:e,gap:o,enforceMinGap:l,flexWrap:d?"wrap":void 0,children:g[i].content})]})}),de(Ls,{code:(()=>{const t=["<OmniStack"];return"column"!==e&&t.push(' direction="'+e+'"'),t.push(" gap={"+o+"}"),l||t.push(" enforceMinGap={false}"),d&&t.push(' flexWrap="wrap"'),t.push(">"),t.push(" {children}"),t.push("</OmniStack>"),t.join("\n")})()})]}),de(I,{item:!0,xs:12,md:5,children:ce(h,{sx:{display:"flex",flexDirection:"column",gap:3},children:[de(ui,{theme:u,onThemeChange:p,surface:m,onSurfaceChange:f}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"CHILDREN"}),de(h,{sx:{display:"flex",flexWrap:"wrap",gap:1},children:Object.entries(g).map(([e,{label:t}])=>de(Os,{label:t,selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"DIRECTION"}),de(h,{sx:{display:"flex",gap:1},children:["row","column"].map(r=>{return de(Os,{label:(o=r,o?o.charAt(0).toUpperCase()+o.slice(1):""),selected:e===r,onClick:()=>t(r)},r);var o})})]}),ce(h,{children:[ce(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:["GAP — ",o," unit",b?" → raised to var(--min-stack-gap)":""]}),ce(h,{sx:{display:"flex",alignItems:"center",gap:2},children:[de(h,{component:"input",type:"range",min:0,max:6,step:.5,value:o,onChange:e=>n(Number(e.target.value)),sx:{flex:1,accentColor:"var(--Primary-Color-10)"}}),de(bo,{style:{color:"var(--Text)",minWidth:24,textAlign:"right"},children:o})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(h,{sx:{display:"flex",flexDirection:"column",gap:1.5},children:[ce(h,{sx:{display:"flex",alignItems:"flex-start",justifyContent:"space-between"},children:[ce(h,{children:[de(ao,{children:"Enforce min gap"}),de(bo,{style:{color:b?"var(--Tags-Warning-Text)":"var(--Text-Quiet)",display:"block"},children:b?"⚡ Active — small child detected":x?"Off — WCAG 2.5.8 risk":"No small children detected"})]}),de(_i,{checked:l,onChange:e=>s(e.target.checked),size:"small"})]}),ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[de(ao,{children:"Flex wrap"}),de(_i,{checked:d,onChange:e=>c(e.target.checked),size:"small"})]})]})]})]})})]})}function Fs(){return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Stack"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:32,maxWidth:640},children:"OmniStack is a layout primitive built on MUI Stack with one intelligent addition: it automatically enforces a minimum gap between children when it detects small (24px) interactive components — protecting WCAG 2.5.8 compliance without any extra developer effort."}),ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Why it matters"}),de(ii,{children:"Playground"}),de(ii,{children:"API"})]}),de(ai,{value:0,children:ce(h,{sx:{pt:3,display:"flex",flexDirection:"column",gap:4},children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"The problem"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"WCAG 2.5.8 requires that small interactive targets (24px) have enough surrounding space that they don’t overlap adjacent targets. Every layout library leaves this entirely to the developer — meaning it’s silently violated constantly."}),de(Ws,{leftLabel:"Plain MUI Stack — gap too small",rightLabel:"OmniStack — gap auto-enforced",leftPasses:!1,rightPasses:!0,leftContent:ce(h,{sx:{display:"flex",flexDirection:"column",gap:"4px"},children:[de(Ps,{href:"#",size:"small",children:"Terms of Service"}),de(Ps,{href:"#",size:"small",children:"Privacy Policy"}),de(Ps,{href:"#",size:"small",children:"Cookie Settings"})]}),rightContent:ce(ba,{gap:.5,children:[de(Ps,{href:"#",size:"small",children:"Terms of Service"}),de(Ps,{href:"#",size:"small",children:"Privacy Policy"}),de(Ps,{href:"#",size:"small",children:"Cookie Settings"})]}),leftCode:'<Stack gap={0.5}>\n <Link size="small">Terms of Service</Link>\n <Link size="small">Privacy Policy</Link>\n <Link size="small">Cookie Settings</Link>\n</Stack>\n// ⚠ gap=4px — targets overlap',rightCode:'<OmniStack gap={0.5}>\n <Link size="small">Terms of Service</Link>\n <Link size="small">Privacy Policy</Link>\n <Link size="small">Cookie Settings</Link>\n</OmniStack>\n// ✓ small child detected → gap enforced'})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"Mixed component sizes"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"One small child is enough to trigger enforcement for the whole stack — the most common case is a normal button paired with a small cancel link."}),de(Ws,{leftLabel:"Without enforcement",rightLabel:"With enforcement",leftPasses:!1,rightPasses:!0,leftContent:ce(h,{sx:{display:"flex",flexDirection:"column",gap:"2px"},children:[de(Tn,{variant:"primary",size:"medium",children:"Save changes"}),de(Ps,{href:"#",size:"small",children:"Or discard"})]}),rightContent:ce(ba,{gap:.25,children:[de(Tn,{variant:"primary",size:"medium",children:"Save changes"}),de(Ps,{href:"#",size:"small",children:"Or discard"})]}),leftCode:'<Stack gap={0.25}>\n <Button size="medium">Save changes</Button>\n <Link size="small">Or discard</Link>\n</Stack>\n// ⚠ Link is 24px — gap too tight',rightCode:'<OmniStack gap={0.25}>\n <Button size="medium">Save changes</Button>\n <Link size="small">Or discard</Link>\n</OmniStack>\n// ✓ Link detected → gap enforced'})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"How detection works"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"OmniStack inspects children at render time using a priority-ordered signal chain. Any one signal is enough to trigger enforcement."}),de(h,{sx:{display:"flex",flexDirection:"column"},children:[{signal:'size="small" prop',example:'<Link size="small" />'},{signal:'data-size="small"',example:'<div data-size="small" />'},{signal:"height={24}",example:"<Box height={24} />"},{signal:"minHeight={24}",example:"<Box minHeight={24} />"},{signal:"sx.minHeight: 24",example:"<Box sx={{ minHeight: 24 }} />"},{signal:"Known component name",example:"Link, Chip, Badge, Caption…"}].map(({signal:e,example:t},r,o)=>ce(h,{sx:{display:"flex",alignItems:"center",gap:2,py:1.5,borderBottom:r<o.length-1?"1px solid var(--Border)":"none"},children:[de(h,{sx:{width:8,height:8,borderRadius:"50%",backgroundColor:"var(--Primary-Color-10)",flexShrink:0}}),de(ao,{style:{flex:"0 0 200px"},children:e}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"Token-driven minimum"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"The minimum gap is a CSS custom property, not a hardcoded value — so it respects your brand spacing scale and responds to theme changes without re-rendering."}),de(Ls,{code:":root {\n --min-stack-gap: 8px; /* Set in your theme.css */\n}\n\n/* OmniStack substitutes the variable, not the value: */\ngap: var(--min-stack-gap, 8px);\n\n/* Dark mode, brand overrides, and media queries\n all work automatically — no re-render needed. */"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"Auditable opt-out"}),ce(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:["Use ",de("code",{children:"enforceMinGap={false}"})," to opt out. This creates a searchable pattern accessibility audits can grep for — a conscious waiver, not a silent violation."]}),de(Ls,{code:'<OmniStack gap={0.5} enforceMinGap={false}>\n {/* Explicitly waived — auditors can grep:\n enforceMinGap={false}\n to find all waivers in the codebase. */}\n <Link size="small">Terms</Link>\n <Link size="small">Privacy</Link>\n</OmniStack>'})]})]})}),de(ai,{value:1,children:de(Ds,{})}),de(ai,{value:2,children:ce(h,{sx:{pt:3},children:[de(Jr,{children:"OmniStack props"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:4,marginBottom:16},children:"All standard MUI Stack props are supported. These are OmniStack additions:"}),de(h,{sx:{border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",mb:4},children:[{prop:"enforceMinGap",type:"boolean",default:"true",desc:"Enable/disable smart gap enforcement."},{prop:"minGapToken",type:"string",default:'"--min-stack-gap"',desc:"CSS variable name for the minimum gap value."},{prop:"gap",type:"number|string",default:"undefined",desc:"Desired gap. Enforced against minGapToken when small children detected."},{prop:"direction",type:"string|object",default:'"column"',desc:"Stack direction. Supports responsive breakpoint objects."},{prop:"flexWrap",type:"string",default:"undefined",desc:'"wrap" | "nowrap" | "wrap-reverse"'},{prop:"divider",type:"ReactNode",default:"undefined",desc:"Element rendered between each child."}].map(({prop:e,type:t,default:r,desc:o},n,i)=>ce(h,{sx:{display:"grid",gridTemplateColumns:"160px 160px 1fr",gap:2,px:2,py:1.5,alignItems:"start",borderBottom:n<i.length-1?"1px solid var(--Border)":"none",backgroundColor:n%2==0?"transparent":"var(--Surface-Dim, var(--Surface))"},children:[de(bo,{style:{fontFamily:"monospace",color:"var(--Primary-Color-10)",fontWeight:600},children:e}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t}),ce(h,{children:[de(bo,{style:{color:"var(--Text)"},children:o}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:2},children:["Default: ",r]})]})]},e))}),de(Jr,{children:"Convenience exports"}),de(h,{sx:{border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",mb:4},children:[{name:"Stack",desc:"Alias for OmniStack — drop-in MUI Stack replacement"},{name:"HStack",desc:'direction="row" alignItems="center"'},{name:"VStack",desc:'direction="column"'},{name:"CenteredStack",desc:'direction="column" alignItems="center" justifyContent="center"'},{name:"SpaceBetweenStack",desc:'direction="row" justifyContent="space-between"'},{name:"WrapStack",desc:'direction="row" flexWrap="wrap"'},{name:"ResponsiveStack",desc:"column on xs, row on sm+ (breakpoint configurable)"},{name:"GridStack",desc:"Alias for WrapStack"},{name:"InsetStack",desc:"OmniStack with px: 2 horizontal padding"},{name:"ScrollStack",desc:"OmniStack with overflowY: auto"}].map(({name:e,desc:t},r,o)=>ce(h,{sx:{display:"grid",gridTemplateColumns:"200px 1fr",gap:2,px:2,py:1.5,borderBottom:r<o.length-1?"1px solid var(--Border)":"none",backgroundColor:r%2==0?"transparent":"var(--Surface-Dim, var(--Surface))"},children:[de(bo,{style:{fontFamily:"monospace",color:"var(--Primary-Color-10)",fontWeight:600},children:e}),de(bo,{style:{color:"var(--Text-Quiet)"},children:t})]},e))}),de(Jr,{children:"Debug attributes"}),de(Ls,{code:'/* When enforcement is active, OmniStack adds: */\nclassName="omni-stack omni-stack-min-gap-enforced"\ndata-min-gap-enforced="true"\n\n/* Target in CSS: */\n.omni-stack-min-gap-enforced { outline: 2px dashed orange; }\n\n/* Query in tests: */\ncontainer.querySelector(\'[data-min-gap-enforced="true"]\')'})]})})]})]})}function Ns({children:e,theme:t,surface:r,elevation:o=0,component:n="div",className:i="",sx:a={},style:l,...s}){const d=Math.max(0,Math.min(5,0|o));if(!d)return de(h,{component:n,"data-theme":t||void 0,"data-surface":r||void 0,className:"omni-box"+(i?" "+i:""),sx:{background:"var(--Background)",boxSizing:"border-box",...a},style:l,...s,children:e});const c=l||{},{width:u,height:p,minWidth:m,minHeight:f,maxWidth:g,maxHeight:x,borderRadius:b,margin:v,marginTop:y,marginRight:S,marginBottom:k,marginLeft:B,...w}=c,C={width:u,height:p,minWidth:m,minHeight:f,maxWidth:g,maxHeight:x,borderRadius:b,margin:v,marginTop:y,marginRight:S,marginBottom:k,marginLeft:B},{width:T,height:I,borderRadius:A,...z}=a;return de(h,{component:n,className:"omni-box-elevation"+(i?" "+i:""),sx:{boxShadow:cn[d],boxSizing:"border-box",width:T,height:I,borderRadius:A},style:C,...s,children:de(h,{"data-theme":t||void 0,"data-surface":r||void 0,className:"omni-box",sx:{width:"100%",height:"100%",background:"var(--Background)",borderRadius:"inherit",boxSizing:"border-box",...z},style:w,children:e})})}const Hs=["Surface","Surface-Dim","Surface-Bright","Container","Container-Low","Container-Lowest","Container-High"],Vs=["Default","Primary","Primary-Light","Secondary","Secondary-Light","Tertiary","Tertiary-Light","Neutral","Neutral-Light","Info-Light","Success-Light","Warning-Light","Error-Light"];function Qs({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function js(){const[e,t]=r(""),[o,n]=r(""),[i,a]=r(null),[l,s]=r("Surface");return ce(Ns,{sx:{pb:8},children:[de(Jr,{children:"Box"}),ce(co,{color:"quiet",style:{marginTop:8,marginBottom:24,maxWidth:720},children:["Bare layout primitive — a slot that participates in the design-system cascade (",de("code",{children:"data-theme"})," / ",de("code",{children:"data-surface"}),") without carrying any chrome. Reach for ",de("code",{children:"<Ratio>"})," or",de("code",{children:" <Card>"})," when you need padding, borders, or shadow."]}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:i,surface:l,children:de(Ns,{sx:{width:"100%",maxWidth:400},children:de(Ns,{theme:e||void 0,surface:o||void 0,children:ce(Ns,{sx:{padding:3,backgroundColor:"var(--Background)",color:"var(--Text)",borderRadius:"var(--Style-Border-Radius)",border:"1px dashed var(--Border-Variant)"},children:[de($r,{children:"Box content"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:6},children:"Anything dropped inside resolves tokens against the Box's theme / surface, if you set them."})]})})})}),de(Ni,{code:(()=>{const t=[];e&&t.push('theme="'+e+'"'),o&&t.push('surface="'+o+'"');return"<Box"+(t.length?" "+t.join(" "):"")+">\n {/* anything */}\n</Box>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(Ns,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"When to use"})]}),de(ai,{value:0,children:ce(Ns,{sx:{p:3},children:[de(Ns,{sx:{mb:3},children:de(ui,{theme:i,onThemeChange:a,surface:l,onSurfaceChange:s})}),ce(Ns,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"THEME (optional)"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[de(Qs,{label:"None",selected:!e,onClick:()=>t("")}),Vs.map(r=>de(Qs,{label:r,selected:e===r,onClick:()=>t(r)},r))]})]}),ce(Ns,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SURFACE (optional)"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[de(Qs,{label:"None",selected:!o,onClick:()=>n("")}),Hs.map(e=>de(Qs,{label:e,selected:o===e,onClick:()=>n(e)},e))]}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Both props are pass-throughs to ",de("code",{children:"data-theme"})," ","and ",de("code",{children:"data-surface"}),". Leave empty to inherit from the parent zone."]})]})]})}),de(ai,{value:1,children:de(Ns,{sx:{p:3},children:ce(B,{spacing:2,children:[ce(Ns,{children:[de(ao,{style:{fontWeight:700},children:"Reach for Box when…"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:"you need a wrapper to scope a theme / surface zone, or you want a typed JSX root without painting any visual styling."})]}),ce(Ns,{children:[de(ao,{style:{fontWeight:700},children:"Use Ratio when…"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:"the container needs a fixed proportion (image, video, embed, hero tile) — it carries the same theme / color shell Box used to."})]}),ce(Ns,{children:[de(ao,{style:{fontWeight:700},children:"Use Card when…"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:"the container has a title, body, and actions — Card handles the standard 2-layer chrome plus header / footer slots."})]})]})})})]})})})]})]})}function Gs({children:e,maxWidth:t="lg",disableGutters:r=!1,sx:o={},...n}){return de(F,{maxWidth:t,disableGutters:r,"data-surface":"Surface",sx:{backgroundColor:"var(--Background)",color:"var(--Text)",transition:"all 0.2s ease-in-out",...o},...n,children:e})}function Us({children:e,container:t=!1,item:r=!1,spacing:o=2,sx:n={},...i}){return de(I,{container:t,item:r,spacing:o,sx:{transition:"all 0.2s ease-in-out",...n},...i,children:e})}function Xs({theme:e,surface:t="Surface",as:r="section",padding:o,className:n,style:i,children:a,...l}){return de(r,{...e?{"data-theme":e}:{},"data-surface":t,className:n,style:{background:"var(--Background)",color:"var(--Text)",...void 0!==o?{padding:o}:{},...i},...l,children:a})}function Ks(){return ce("div",{children:[de(Jr,{style:{marginBottom:12},children:"Section"}),ce(co,{color:"quiet",style:{marginBottom:32,maxWidth:720},children:[de("code",{children:"<Section>"})," bundles ",de("code",{children:"data-theme"})," +"," ",de("code",{children:"data-surface"})," + background paint into one component. Use anywhere you'd otherwise reach for"," ",de("code",{children:"<section data-theme data-surface style={{ background: var(--Background) }}>"}),". For wrapping without painting (e.g. AppBar's themed zone), use"," ",de("code",{children:"<ThemedZone>"}),"."]}),de(Jr,{style:{marginTop:24,marginBottom:12},children:"Theme + surface"}),de(ao,{color:"quiet",style:{marginBottom:16,display:"block"},children:'Sets data-theme="Primary-Light" + data-surface="Surface", paints --Background.'}),ce(Xs,{theme:"Primary-Light",surface:"Surface",padding:"32px",style:{borderRadius:8},children:[de(Jr,{children:"Primary-Light surface"}),de(co,{children:"Body text picks up --Text automatically."}),de(ao,{color:"quiet",children:"Quiet text picks up --Text-Quiet."}),de("div",{style:{marginTop:12},children:de(Tn,{variant:"primary",children:"Primary button"})})]}),de(Jr,{style:{marginTop:32,marginBottom:12},children:"Container surface"}),ce(Xs,{surface:"Container",padding:"32px",style:{borderRadius:8},children:[de(Jr,{children:"Container surface (inherits theme)"}),de(co,{children:"Useful for card-like regions."})]}),de(Jr,{style:{marginTop:32,marginBottom:12},children:"Different element"}),ce(ao,{color:"quiet",style:{marginBottom:16,display:"block"},children:["Pass ",de("code",{children:'as="article"'}),", ",de("code",{children:'as="footer"'}),", etc."]}),ce(Xs,{as:"article",theme:"Neutral-Dark",surface:"Surface",padding:"32px",style:{borderRadius:8},children:[de(Jr,{children:"Neutral-Dark article"}),de(co,{children:"Renders as an <article> element."})]})]})}const qs=["1:1","3:4","4:3","16:9","9:16","2:3","3:2","1:2","2:1","9:21","21:9","5:7","7:5","4:5","5:4","5:3","3:5","16:10","10:16","Golden-Horizontal","Golden-Vertical"],Js="1.618034",Ys={"1:1":"1 / 1","3:4":"3 / 4","4:3":"4 / 3","16:9":"16 / 9","9:16":"9 / 16","2:3":"2 / 3","3:2":"3 / 2","1:2":"1 / 2","2:1":"2 / 1","9:21":"9 / 21","21:9":"21 / 9","5:7":"5 / 7","7:5":"7 / 5","4:5":"4 / 5","5:4":"5 / 4","5:3":"5 / 3","3:5":"3 / 5","16:10":"16 / 10","10:16":"10 / 16","Golden-Horizontal":Js+" / 1","Golden-Vertical":"1 / "+Js},$s={none:0,xs:1,sm:2,md:3,lg:4,xl:6};function Zs({ratio:e="1:1",children:r,variant:o="default",color:n="default",padding:i="none",fit:a="width",placeholder:l=!0,elevated:s=!1,clickable:d=!1,onClick:c,maxWidth:u,maxHeight:p,component:m="div",className:f="",sx:g={},...x}){const b=Ys[e]||Ys["1:1"],v=(y="default"===n?"Default":n).charAt(0).toUpperCase()+y.slice(1);var y;const S=l&&0===t.Children.count(r),k="default"===n?"Default":v,B="dark"===o?"Surface-Dimmest":"light"===o?"Surface-Brightest":"Surface",w=void 0!==$s[i]?$s[i]:$s.none,C=d||!!c,T="default"===o,I=s?ln:an,A=s?sn:ln;return de(h,{component:m,onClick:C?c:void 0,role:C?"button":void 0,tabIndex:C?0:void 0,className:"ratio ratio-"+e.toLowerCase()+" ratio-"+o+(C?" ratio-clickable":"")+(s?" ratio-elevated":"")+(f?" "+f:""),sx:{aspectRatio:b,flex:"0 0 auto",..."height"===a?{height:"100%",width:"auto",minHeight:24}:{width:"100%",height:"auto",minWidth:24},...void 0!==u&&{maxWidth:u},...void 0!==p&&{maxHeight:p},border:T?"none":"1px solid var(--Border-Variant)",borderRadius:T?0:"var(--Style-Border-Radius)",boxShadow:T?"none":I,overflow:"hidden",transition:"box-shadow 0.2s ease, border-color 0.2s ease",...C&&{cursor:"pointer","&:hover":{borderColor:"var(--Buttons-Default-Border)",boxShadow:A},"&:active":{transform:"scale(0.995)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"3px"}},...!C&&!T&&{"&:hover":{boxShadow:A}},...g},...x,children:de(h,{"data-theme":k||void 0,"data-surface":B,sx:{width:"100%",height:"100%",padding:w,backgroundColor:S?"var(--Border)":"var(--Background)",color:"var(--Text)",fontFamily:"inherit",borderRadius:T?0:"calc(var(--Style-Border-Radius) - 1px)",...S?{display:"flex",alignItems:"center",justifyContent:"center"}:{"& > *":{width:"100%",height:"100%"}}},children:S?de(jo,{size:"large",sx:{color:"var(--Background)"},children:de(Ut,{})}):r})})}const _s=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ed=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],td=["default","solid","light","dark"],rd=["none","xs","sm","md","lg","xl"];function od({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function nd({color:e,selected:t,onClick:r,variant:o}){const n=_s(e);return de(Ns,{component:"button","data-theme":{solid:n,light:n+"-Light",dark:n,default:void 0}[o],"data-surface":{solid:"Surface",light:"Surface",dark:"Surface-Dimmest",default:"Surface"}[o],onClick:()=>r(e),"aria-label":"Select "+n,"aria-pressed":t,title:n,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Background)",border:t?"2px solid var(--Text)":"2px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Text)",pointerEvents:"none"}})})}function id(){const[e,t]=r("1:1"),[o,n]=r("solid"),[i,a]=r("primary"),[l,s]=r("none"),[d,c]=r(!1),[u,p]=r(!1),[h,m]=r(null),[f,g]=r("Surface");return ce(Ns,{sx:{pb:8},children:[de(Jr,{children:"Ratio"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:h,surface:f,children:de(Ns,{sx:{width:"100%",maxWidth:480},children:de(Zs,{ratio:e,variant:o,color:i,padding:l,elevated:d,clickable:u})})}),de(Ni,{code:(()=>{const t=['ratio="'+e+'"'];return"default"!==o&&t.push('variant="'+o+'"'),"default"!==i&&t.push('color="'+i+'"'),"none"!==l&&t.push('padding="'+l+'"'),d&&t.push("elevated"),u&&t.push("clickable onClick={handleClick}"),"<Ratio "+t.join(" ")+">\n {/* your content */}\n</Ratio>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(Ns,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Reference"})]}),de(ai,{value:0,children:ce(Ns,{sx:{p:3},children:[de(Ns,{sx:{mb:3},children:de(ui,{theme:h,onThemeChange:m,surface:f,onSurfaceChange:g})}),ce(Ns,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"VARIANT"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:td.map(e=>de(od,{label:_s(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(Ns,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:ed.map(e=>ce(Ns,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(nd,{color:e,selected:i===e,onClick:a,variant:"default"===o?"solid":o},e))})]},e.label))})]}),ce(Ns,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PADDING"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:rd.map(e=>de(od,{label:"none"===e?"None":e.toUpperCase(),selected:l===e,onClick:()=>s(e)},e))})]}),ce(Ns,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"RATIO"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:qs.map(r=>de(od,{label:r,selected:e===r,onClick:()=>t(r)},r))})]}),ce(Ns,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(Ns,{children:[de(ko,{children:"Elevated"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Bumps the shadow up one level"})]}),de(_i,{checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Elevated"})]}),ce(Ns,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(Ns,{children:[de(ko,{children:"Clickable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Adds hover, press, and focus-visible"})]}),de(_i,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Clickable"})]})]})}),de(ai,{value:1,children:de(Ns,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(Ns,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Common use cases"}),de(B,{spacing:0,children:[{label:"1:1",value:"Square thumbnails, avatars, product tiles"},{label:"16:9",value:"Video, hero images, modern displays"},{label:"4:3",value:"Classic photo, presentation slides"},{label:"3:2",value:"DSLR photography, print frames"},{label:"21:9",value:"Cinematic ultrawide"},{label:"9:16 / 4:5 / 5:7",value:"Portrait social media (Stories, Reels, prints)"},{label:"16:10",value:"Laptop / monitor displays"},{label:"Golden-Horizontal",value:"φ : 1 — design framing for cards, hero blocks"},{label:"Golden-Vertical",value:"1 : φ — vertical posters, sidebars"}].map(({label:e,value:t})=>ce(Ns,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:e}),de(bo,{style:{color:"var(--Text-Quiet)"},children:t})]},e))})]}),ce(co,{color:"quiet",children:["Built on native CSS ",de("code",{children:"aspect-ratio"}),". The themed shell mirrors Box — pick a variant + color to paint the frame, or keep ",de("code",{children:'variant="default"'}),"for a borderless ratio container."]})]})})})]})})})]})]})}const ad=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ld=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],sd=[{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function dd({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function cd({color:e,selected:t,onClick:r}){const o=ad(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function ud(){const[e,t]=r("standard"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r("horizontal"),[d,c]=r(null),[u,p]=r("Surface"),[m,f]=r(!1),g="standard"===e?ld:sd;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Tabs"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:"vertical"===l?500:"100%",display:"flex",flexDirection:"vertical"===l?"row":"column"},children:ce(oi,{defaultValue:0,variant:e,color:o,size:i,orientation:l,children:[ce(ni,{rounded:m,children:[de(ii,{children:"Overview"}),de(ii,{children:"Features"}),de(ii,{children:"Pricing"})]}),de(ai,{value:0,children:de(h,{sx:{p:2},children:de(co,{style:{color:"var(--Quiet)"},children:"Overview content goes here."})})}),de(ai,{value:1,children:de(h,{sx:{p:2},children:de(co,{style:{color:"var(--Quiet)"},children:"Features content goes here."})})}),de(ai,{value:2,children:de(h,{sx:{p:2},children:de(co,{style:{color:"var(--Quiet)"},children:"Pricing content goes here."})})})]})})}),de(Ni,{code:(()=>{const t=[];return"standard"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),"horizontal"!==l&&t.push('orientation="vertical"'),"<Tabs defaultValue={0}"+(t.length?" "+t.join(" "):"")+">\n <TabList"+(m?" rounded":"")+">\n <Tab>Overview</Tab>\n <Tab>Features</Tab>\n <Tab>Pricing</Tab>\n </TabList>\n <TabPanel value={0}>Overview content</TabPanel>\n <TabPanel value={1}>Features content</TabPanel>\n <TabPanel value={2}>Pricing content</TabPanel>\n</Tabs>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["standard","solid","light","dark"].map(r=>de(dd,{label:ad("standard"===r?"default":r),selected:e===r,onClick:()=>(e=>{t(e),"standard"!==e&&"default"===o&&n("primary")})(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:g.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(cd,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(dd,{label:ad(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ORIENTATION"}),de(B,{direction:"row",spacing:1,children:["horizontal","vertical"].map(e=>de(dd,{label:ad(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SHAPE"}),de(_i,{label:"Rounded corners",checked:m,onChange:e=>f(e.target.checked)}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Off by default. When on, the TabList applies"," ",de("code",{children:"var(--Style-Border-Radius)"})," and clips the active tab's background to fit the rounded shell (",de("code",{children:"overflow: hidden"})," is always on)."]})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"TabList",value:'role="tablist" aria-orientation'},{label:"Tab",value:'role="tab" aria-selected aria-controls={panelId}'},{label:"TabPanel",value:'role="tabpanel" aria-labelledby={tabId}'},{label:"Keyboard",value:"Arrow keys navigate tabs. Home/End jump to first/last."},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: -3px"},{label:"Indicator",value:"Standard: var(--Buttons-{C}-Border). Themed: var(--Text)."}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const pd={small:{fontSize:"var(--Body-Small-Font-Size)",gap:"6px",py:"4px"},medium:{fontSize:"var(--Body-Font-Size)",gap:"8px",py:"6px"},large:{fontSize:"var(--Body-Large-Font-Size)",gap:"10px",py:"8px"}};function hd({children:e,separator:r="/",size:o="medium",condense:n=!1,maxItems:i=4,itemsBeforeCollapse:a=1,itemsAfterCollapse:l=1,backOnlyMobile:s=!1,onExpand:d,className:c="",sx:m={},...f}){const g=pd[o]||pd.medium,x=u.toArray(e).filter(p),b=x.length,v=n&&b>i;let y=x;const[S,k]=t.useState(!1);if(v&&!S){const e=x.slice(0,a),t=x.slice(b-l);y=[...e,de(h,{component:"button",onClick:()=>{k(!0),d?.()},"aria-label":"Show full breadcrumb trail",className:"breadcrumb-ellipsis",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",background:"none",border:"none",padding:"2px 4px",cursor:"pointer",fontFamily:"inherit",fontSize:"inherit",color:"var(--Quiet)",borderRadius:"4px","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"1px"}},children:"…"},"__breadcrumb-ellipsis"),...t]}const B=[];y.forEach((e,t)=>{const o=v&&!S?t===y.length-1:t===b-1;B.push(de(h,{component:"li",className:"breadcrumb-item"+(o?" breadcrumb-current":""),sx:{display:"inline-flex",alignItems:"center",...o&&{color:"var(--Text)",fontWeight:600},...!o&&{color:"var(--Quiet)"},maxWidth:"200px","& > *":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},...o?{"aria-current":"page"}:{},children:e},"crumb-"+t)),t<y.length-1&&B.push(de(h,{component:"li",role:"presentation","aria-hidden":"true",className:"breadcrumb-separator",sx:{display:"inline-flex",alignItems:"center",color:"var(--Quiet)",userSelect:"none",fontSize:"inherit",lineHeight:1,flexShrink:0},children:r},"sep-"+t))});const w=b>=2?x[b-2]:null;return ce(h,{component:"nav","aria-label":"Breadcrumb",className:"breadcrumbs breadcrumbs-"+o+" "+c,sx:{fontSize:g.fontSize,fontFamily:"var(--Body-Font-Family)",lineHeight:1.5,...m},...f,children:[de(h,{component:"ol",className:"breadcrumbs-list",sx:{display:"flex",flexWrap:"wrap",alignItems:"center",gap:g.gap,listStyle:"none",margin:0,padding:0,...s&&{"@media (max-width: 600px)":{display:"none"}}},children:B}),s&&w&&ce(h,{className:"breadcrumbs-back-mobile",sx:{display:"none","@media (max-width: 600px)":{display:"flex",alignItems:"center",gap:"4px",fontSize:g.fontSize,color:"var(--Link)"}},children:[de(h,{component:"span","aria-hidden":"true",sx:{fontSize:"1.1em",lineHeight:1},children:"←"}),t.cloneElement(w,{style:{...w.props?.style||{},textDecoration:"underline",textUnderlineOffset:"3px"}})]})]})}function md({children:e,href:t,className:r="",sx:o={},...n}){const i=!!t;return de(h,{component:i?"a":"span",href:t||void 0,className:"breadcrumb-link "+r,sx:{color:"inherit",textDecoration:i?"underline":"none",textUnderlineOffset:"3px",textDecorationThickness:"1px",cursor:i?"pointer":"default",transition:"color 0.15s ease",...i&&{"&:hover":{color:"var(--Link-Hover)",textDecorationThickness:"2px"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px",borderRadius:"2px"}},...o},...n,children:e})}const fd=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"";function gd({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function xd(){const[e,t]=r("medium"),[o,n]=r("/"),[i,a]=r(!1),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Breadcrumbs"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:l,surface:d,children:ce(hd,{size:e,separator:o,condense:i,maxItems:3,children:[de(md,{href:"#",children:"Home"}),de(md,{href:"#",children:"Products"}),de(md,{href:"#",children:"Shoes"}),de(md,{children:"Running Shoes"})]})}),de(Ni,{code:(()=>{const t=[];return"medium"!==e&&t.push('size="'+e+'"'),"/"!==o&&t.push('separator="'+o+'"'),i&&t.push("condense maxItems={3}"),"<Breadcrumbs"+(t.length?" "+t.join(" "):"")+'>\n <BreadcrumbItem href="/">Home</BreadcrumbItem>\n <BreadcrumbItem href="/products">Products</BreadcrumbItem>\n <BreadcrumbItem href="/products/shoes">Shoes</BreadcrumbItem>\n <BreadcrumbItem>Running Shoes</BreadcrumbItem>\n</Breadcrumbs>'})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(r=>de(gd,{label:fd(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SEPARATOR"}),de(B,{direction:"row",spacing:1,children:["/","›","→","·","|"].map(e=>de(gd,{label:e,selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Condense"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Collapse middle items into ellipsis"})]}),de(_i,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Condense"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Nav",value:'<nav aria-label="Breadcrumb">'},{label:"List",value:"<ol> with <li> for each crumb"},{label:"Current",value:'aria-current="page" on the last item'},{label:"Links",value:"BreadcrumbItem renders <a> when href is provided"},{label:"Ellipsis",value:'Expandable button with aria-label="Show full breadcrumb trail"'},{label:"Separator",value:'aria-hidden="true" — decorative only'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const bd={small:{btnSize:"small",fontSize:"13px",gap:"2px"},medium:{btnSize:"medium",fontSize:"14px",gap:"4px"},large:{btnSize:"large",fontSize:"16px",gap:"4px"}};function vd({count:e=10,page:t,defaultPage:o=1,onChange:i,color:a="default",size:l="medium",siblingCount:s=1,boundaryCount:d=1,disabled:c=!1,showFirstButton:u=!1,showLastButton:p=!1,className:m="",sx:f={},...g}){const[x,b]=r(o),v=void 0!==t,y=v?t:x;(e=>{e.charAt(0).toUpperCase(),e.slice(1)})("default"===a?"Default":a);const S=bd[l]||bd.medium,k=n(t=>{const r=Math.max(1,Math.min(e,t));v||b(r),i?.(r)},[e,v,i]),B=function({count:e,page:t,siblingCount:r=1,boundaryCount:o=1}){const n=(e,t)=>Array.from({length:t-e+1},(t,r)=>e+r);if(2*r+3+2*o>=e)return n(1,e);const i=Math.max(t-r,o+1),a=Math.min(t+r,e-o),l=i>o+2,s=a<e-o-1;if(!l&&s)return[...n(1,Math.min(3+2*r+o,e)),"ellipsis-right",...n(e-o+1,e)];if(l&&!s){const t=n(Math.max(e-(3+2*r+o)+1,1),e);return[...n(1,o),"ellipsis-left",...t]}return l&&s?[...n(1,o),"ellipsis-left",...n(i,a),"ellipsis-right",...n(e-o+1,e)]:n(1,e)}({count:e,page:y,siblingCount:s,boundaryCount:d}),w="default"===a?"default":a;return de(h,{component:"nav","aria-label":"Pagination",className:"pagination pagination-"+a+" pagination-"+l+" "+m,sx:{display:"inline-flex",...f},...g,children:ce(h,{component:"ul",sx:{display:"flex",alignItems:"center",gap:S.gap,listStyle:"none",m:0,p:0,flexWrap:"wrap"},children:[u&&de(h,{component:"li",children:de(Tn,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||1===y,onClick:()=>k(1),"aria-label":"Go to first page",children:de(jo,{size:"small",children:de(qt,{})})})}),de(h,{component:"li",children:de(Tn,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||1===y,onClick:()=>k(y-1),"aria-label":"Go to previous page",children:de(jo,{size:"small",children:de(Xt,{})})})}),B.map((e,t)=>{if("string"==typeof e)return de(h,{component:"li",children:de(bo,{style:{color:"var(--Quiet)",padding:"0 4px"},"aria-hidden":"true",children:"…"})},e+"-"+t);const r=e===y;return de(h,{component:"li",children:de(Tn,{variant:r?w:w+"-outline",size:S.btnSize,disabled:c,onClick:()=>k(e),"aria-label":"Page "+e,"aria-current":r?"page":void 0,letterNumber:!0,children:e})},e)}),de(h,{component:"li",children:de(Tn,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||y===e,onClick:()=>k(y+1),"aria-label":"Go to next page",children:de(jo,{size:"small",children:de(Kt,{})})})}),p&&de(h,{component:"li",children:de(Tn,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||y===e,onClick:()=>k(e),"aria-label":"Go to last page",children:de(jo,{size:"small",children:de(Jt,{})})})})]})})}const yd=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Sd=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function kd({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Bd({color:e,selected:t,onClick:r}){const o=yd(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function wd(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(10),[l,s]=r(!1),[d,c]=r(!1),[u,p]=r(!1),[m,f]=r(null),[g,x]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Pagination"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:m,surface:g,children:de(vd,{color:e,size:o,count:i,showFirstButton:l,showLastButton:d,disabled:u})}),de(Ni,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),10!==i&&t.push("count={"+i+"}"),l&&t.push("showFirstButton"),d&&t.push("showLastButton"),u&&t.push("disabled"),t.push("onChange={handlePageChange}"),1===t.length?"<Pagination onChange={handlePageChange} />":"<Pagination\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:m,onThemeChange:f,surface:g,onSurfaceChange:x})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Sd.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(Bd,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(kd,{label:yd(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PAGES"}),de(B,{direction:"row",spacing:1,children:[5,10,20,50].map(e=>de(kd,{label:String(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"First/Last Buttons"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show jump to first/last page"})]}),de(_i,{variant:"default-outline",checked:l,onChange:e=>{s(e.target.checked),c(e.target.checked)},size:"small","aria-label":"First/last buttons"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(_i,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Disabled"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Nav",value:'<nav aria-label="Pagination">'},{label:"List",value:"<ol> with <li> for each button"},{label:"Current",value:'aria-current="page" on selected page'},{label:"Labels",value:'aria-label="Page N", "Go to previous/next/first/last page"'},{label:"Keyboard",value:"Tab navigates between buttons"},{label:"Focus",value:"Uses Button component focus styles"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Cd=e=>e.charAt(0).toUpperCase()+e.slice(1),Td={small:{py:"4px",itemPx:"8px",itemPy:"4px",fontSize:"13px",minWidth:"140px"},medium:{py:"6px",itemPx:"12px",itemPy:"6px",fontSize:"14px",minWidth:"160px"},large:{py:"8px",itemPx:"16px",itemPy:"8px",fontSize:"16px",minWidth:"180px"}},Id=s({open:!1,setOpen:()=>{},anchorRef:{current:null},menuId:"",buttonId:"",variant:"outline",color:"default",size:"medium"}),Ad=()=>l(Id);function zd({children:e,variant:t="outline",color:i="default",size:l="medium",open:s,onOpenChange:d,...c}){const[u,p]=r(!1),m=void 0!==s,f=m?s:u,g=o(null),x=a(),b="menu-"+x,v="menubtn-"+x,y=n(e=>{const t="function"==typeof e?e(f):e;m?d?.(t):p(t)},[m,f,d]);return de(Id.Provider,{value:{open:f,setOpen:y,anchorRef:g,menuId:b,buttonId:v,variant:t,color:i,size:l},children:de(h,{sx:{display:"inline-flex",position:"relative"},...c,children:e})})}function Rd({children:e,className:t="",sx:r={},...o}){const{open:n,setOpen:i,anchorRef:a,menuId:l,buttonId:s,size:d,color:c}=Ad(),u=Td[d]||Td.medium,p=Cd("default"===c?"Default":c);return ce(h,{component:"button",ref:a,id:s,"aria-haspopup":"true","aria-expanded":n,"aria-controls":n?l:void 0,onClick:()=>i(e=>!e),className:"menu-button "+t,sx:{display:"inline-flex",alignItems:"center",gap:"6px",padding:u.itemPy+" "+u.itemPx,fontSize:u.fontSize,fontFamily:"inherit",fontWeight:600,color:"var(--Text)",backgroundColor:"var(--Background)",border:"1px solid var(--Buttons-"+p+"-Border)",borderRadius:"var(--Style-Border-Radius)",cursor:"pointer",boxShadow:"none",transition:"box-shadow 0.15s ease","&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},...r},onKeyDown:e=>{"ArrowDown"!==e.key&&"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),i(!0))},...o,children:["string"==typeof e?de("small"===d?ao:co,{style:{color:"inherit",fontWeight:600},children:e}):e,de(jo,{size:"small",sx:{color:"var(--Quiet)",transition:"transform 0.2s ease",transform:n?"rotate(180deg)":"rotate(0deg)"},children:de(Se,{})})]})}function Ed({children:e,className:t="",placement:r="bottom-start",sx:n={},...a}){const{open:l,setOpen:s,anchorRef:d,menuId:c,buttonId:u,variant:p,color:m,size:f}=Ad(),g=o(null),x=Td[f]||Td.medium,b=Cd("default"===m?"Default":m),v="var(--Buttons-"+b+"-Border)",y="light"===p?"default"===m?"Default":b:"solid"===p?b:void 0,S="light"===p?"Surface-Brightest":"solid"===p?"Surface":void 0;return i(()=>{if(l&&g.current){const e=g.current.querySelector('[role="menuitem"]:not([aria-disabled="true"])');e&&e.focus()}},[l]),i(()=>{if(!l)return;const e=e=>{g.current&&!g.current.contains(e.target)&&d.current&&!d.current.contains(e.target)&&s(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[l,s,d]),i(()=>{if(!l)return;const e=e=>{"Escape"===e.key&&(s(!1),d.current?.focus())};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[l,s,d]),l?de(h,{className:"menu menu-"+p+" "+t,sx:{position:"absolute",top:"100%",left:"bottom-end"===r?"auto":0,right:"bottom-end"===r?0:"auto",zIndex:99999,marginTop:"4px",border:"1px solid "+v,borderRadius:"var(--Dropdown-Frame-Radius, var(--Input-Radius, var(--Style-Border-Radius, 4px)))",boxShadow:"none",overflow:"hidden",...n},children:de(h,{ref:g,id:c,role:"menu","aria-labelledby":u,"data-theme":y,"data-surface":S,sx:{minWidth:x.minWidth,backgroundColor:"var(--Background)",color:"var(--Text)",fontSize:x.fontSize,fontFamily:"inherit",padding:x.py+" 0",outline:"none",borderRadius:"calc(var(--Dropdown-Frame-Radius, var(--Input-Radius, var(--Style-Border-Radius, 4px))) - 1px)"},onKeyDown:e=>{const t=g.current?.querySelectorAll('[role="menuitem"]:not([aria-disabled="true"])');if(!t?.length)return;const r=Array.from(t).indexOf(document.activeElement);"ArrowDown"===e.key?(e.preventDefault(),t[(r+1)%t.length].focus()):"ArrowUp"===e.key?(e.preventDefault(),t[(r-1+t.length)%t.length].focus()):"Home"===e.key?(e.preventDefault(),t[0].focus()):"End"===e.key?(e.preventDefault(),t[t.length-1].focus()):"Tab"===e.key&&s(!1)},...a,children:e})}):null}function Pd({children:e,onClick:t,selected:r=!1,disabled:o=!1,className:n="",sx:i={},...a}){const{setOpen:l,size:s}=Ad(),d=Td[s]||Td.medium,c="small"===s?ao:co,u=()=>{o||(t?.(),l(!1))};return de(h,{role:"menuitem",tabIndex:o?-1:0,"aria-disabled":o||void 0,"aria-selected":r||void 0,onClick:u,onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),u())},className:"menu-item"+(r?" menu-item-selected":"")+" "+n,sx:{display:"flex",alignItems:"center",gap:"8px",padding:d.itemPy+" "+d.itemPx,color:o?"var(--Quiet)":r?"var(--Text)":"var(--Quiet)",backgroundColor:r?"var(--Hover)":"transparent",cursor:o?"not-allowed":"pointer",opacity:o?.5:1,outline:"none",transition:"background-color 0.1s ease, color 0.1s ease",userSelect:"none",...!o&&{"&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{backgroundColor:"var(--Hover)",color:"var(--Text)",outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},...i},...a,children:de(c,{style:{color:"inherit",fontWeight:r?600:"inherit"},children:e})})}function Od({className:e="",sx:t={},...r}){return de(h,{component:"hr",role:"separator",className:"menu-divider "+e,sx:{border:"none",borderTop:"1px solid var(--Border)",margin:"4px 0",...t},...r})}const Ld=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Md=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function Wd({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Dd({color:e,selected:t,onClick:r}){const o=Ld(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Fd(){const[e,t]=r("outline"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Menu"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:l,surface:d,sx:{minHeight:250,alignItems:"flex-start",pt:6},children:ce(zd,{variant:e,color:o,size:i,children:[de(Rd,{children:"Actions"}),ce(Ed,{children:[de(Pd,{children:"Edit"}),de(Pd,{children:"Duplicate"}),de(Pd,{selected:!0,children:"Archive"}),de(Od,{}),de(Pd,{disabled:!0,children:"Delete"})]})]})}),de(Ni,{code:(()=>{const t=[];return"outline"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),"<Dropdown "+t.join(" ")+">\n <MenuButton>Actions</MenuButton>\n <Menu>\n <MenuItem>Edit</MenuItem>\n <MenuItem>Duplicate</MenuItem>\n <MenuDivider />\n <MenuItem>Delete</MenuItem>\n </Menu>\n</Dropdown>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","solid","light"].map(r=>de(Wd,{label:Ld(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Md.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Dd,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Wd,{label:Ld(e),selected:i===e,onClick:()=>a(e)},e))})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Button",value:'aria-haspopup="true" aria-expanded aria-controls'},{label:"Menu",value:'role="menu" aria-labelledby={buttonId}'},{label:"Items",value:'role="menuitem" with tabIndex'},{label:"Selected",value:'aria-selected="true" on active item'},{label:"Disabled",value:'aria-disabled="true", not focusable'},{label:"Keyboard",value:"Arrow keys navigate. Enter/Space selects. Escape closes."},{label:"Focus",value:"First item focused on open. Focus returns to button on close."}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Nd={default:"Nav-Bar",primary:"Primary","primary-light":"Primary-Light","primary-medium":"Primary-Medium","primary-dark":"Primary-Dark",white:"White",black:"Black"};function Hd({items:e=[],value:t,defaultValue:o=0,onChange:i,showLabels:a=!0,labelOrientation:l="vertical",backfill:s=!0,barColor:d="default",fixed:c=!0,className:u="",sx:p={},...m}){const[f,g]=r(o),x=void 0!==t,b=x?t:f,v=n(e=>{x||g(e),i?.(e)},[x,i]),y="horizontal"===(e.length>4?"vertical":l);return de(h,{component:"nav",role:"navigation","aria-label":"Bottom navigation","data-theme":Nd[d]||Nd.default,"data-surface":"Surface-Dim",className:"bottom-nav bottom-nav-"+d+(a?" bottom-nav-labels":"")+(y&&a?" bottom-nav-horizontal":"")+(s?" bottom-nav-backfill":"")+(c?" bottom-nav-fixed":"")+(u?" "+u:""),sx:{display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"var(--Background)",borderTop:"1px solid var(--Border)",fontFamily:"inherit",width:"100%",...c&&{position:"fixed",bottom:0,left:0,right:0,zIndex:1100},...p},...m,children:de(h,{role:"tablist",sx:{display:"flex",alignItems:"center",justifyContent:"space-around",width:"100%",maxWidth:600,height:a&&!y?72:64,px:1},children:e.map((e,t)=>{const r=t===b;return de(Vd,{icon:e.icon,label:e.label,selected:r,showLabel:a,horizontal:y,backfill:s,onClick:()=>v(t),ariaLabel:e.label||"Tab "+(t+1)},e.key||t)})})})}function Vd({icon:e,label:t,selected:r,showLabel:o,horizontal:n,backfill:i,onClick:a,ariaLabel:l}){const s="var(--Text-Quiet)",d="var(--Text)",c="var(--Buttons-Primary-Text)",u=r?i&&n?c:d:s,p=!n,m=ce(h,{sx:{display:"flex",flexDirection:n?"row":"column",alignItems:"center",justifyContent:"center",gap:n?.75:0,...r&&i&&{backgroundColor:"var(--Buttons-Primary-Button)",border:"1px solid var(--Buttons-Primary-Border)",borderRadius:"16px",px:n?2:2.5,py:.5},...r&&i?{}:{px:n?1:0,border:"1px solid transparent"},transition:"background-color 0.2s ease, border-color 0.2s ease"},children:[de(h,{sx:{display:"flex",alignItems:"center",justifyContent:"center",fontSize:"24px",color:r?i?c:d:s,transition:"color 0.15s ease","& .MuiSvgIcon-root":{fontSize:"inherit",color:"inherit"}},children:e}),o&&n&&t&&de(h,{sx:{fontSize:"13px",fontWeight:r?600:500,color:r&&i?c:r?d:s,whiteSpace:"nowrap",lineHeight:1,transition:"color 0.15s ease"},children:t})]});return ce(h,{component:"button",type:"button",role:"tab","aria-selected":r,"aria-label":l,onClick:a,sx:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",flex:1,gap:p&&o?.25:0,border:"none",backgroundColor:"transparent",cursor:"pointer",outline:"none",fontFamily:"inherit",py:1,minWidth:0,transition:"transform 0.1s ease","&:hover":{transform:"scale(1.04)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-2px",borderRadius:"8px"}},children:[m,o&&p&&t&&de(h,{sx:{fontSize:"11px",fontWeight:r?600:400,color:u,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%",lineHeight:1.2,mt:.25,transition:"color 0.15s ease"},children:t})]})}const Qd={Home:de(Be,{sx:{fontSize:"inherit"}}),Explore:de(Yt,{sx:{fontSize:"inherit"}}),Radio:de($t,{sx:{fontSize:"inherit"}}),Library:de(Zt,{sx:{fontSize:"inherit"}}),Favorite:de(ke,{sx:{fontSize:"inherit"}}),Person:de(me,{sx:{fontSize:"inherit"}}),Search:de(Te,{sx:{fontSize:"inherit"}}),Settings:de(Ce,{sx:{fontSize:"inherit"}}),Notifications:de(Ae,{sx:{fontSize:"inherit"}}),Cart:de(Re,{sx:{fontSize:"inherit"}}),Star:de(Ie,{sx:{fontSize:"inherit"}}),Bookmark:de(_t,{sx:{fontSize:"inherit"}})},jd=Object.keys(Qd),Gd=[{icon:"Home",label:"Home"},{icon:"Explore",label:"Browse"},{icon:"Radio",label:"Radio"},{icon:"Library",label:"Library"}],Ud=[{value:"default",label:"Default",desc:'data-theme="Nav-Bar"'},{value:"primary",label:"Primary",desc:'data-theme="Primary"'},{value:"primary-light",label:"Primary Light",desc:'data-theme="Primary-Light"'},{value:"primary-medium",label:"Primary Medium",desc:'data-theme="Primary-Medium"'},{value:"primary-dark",label:"Primary Dark",desc:'data-theme="Primary-Dark"'},{value:"white",label:"White",desc:'data-theme="White"'},{value:"black",label:"Black",desc:'data-theme="Black"'}];function Xd({label:e,selected:t,onClick:r,disabled:o}){return de(h,{component:"button",onClick:r,disabled:o,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",cursor:o?"not-allowed":"pointer",border:"2px solid var(--Buttons-Primary-Button)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:t?"var(--Buttons-Primary-Button)":"transparent",color:t?"var(--Buttons-Primary-Text)":"var(--Text)",padding:"4px 12px",fontSize:"14px",fontFamily:"inherit",fontWeight:500,whiteSpace:"nowrap",flexShrink:0,opacity:o?.4:1,transition:"background-color 0.15s ease, color 0.15s ease","&:hover":{backgroundColor:o?"transparent":t?"var(--Buttons-Primary-Hover)":"var(--Surface-Dim)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:e})}function Kd({value:e,onChange:t,placeholder:r,sx:o}){return de(h,{component:"input",type:"text",value:e,onChange:e=>t(e.target.value),placeholder:r,sx:{flex:1,padding:"4px 8px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none",minWidth:0,"&:focus":{borderColor:"var(--Focus-Visible)"},...o}})}function qd({value:e,onChange:t,options:r,label:o}){return de(h,{component:"select",value:e,onChange:e=>t(e.target.value),"aria-label":o,sx:{padding:"4px 6px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none",cursor:"pointer","&:focus":{borderColor:"var(--Focus-Visible)"}},children:r.map(e=>de("option",{value:"string"==typeof e?e:e.value,children:"string"==typeof e?e:e.label},"string"==typeof e?e:e.value))})}function Jd({value:e,onChange:t,min:r,max:o,label:n}){return ce(h,{sx:{display:"flex",alignItems:"center",gap:1},children:[de(bo,{style:{color:"var(--Text-Quiet)",flexShrink:0,width:90},children:n}),de("button",{type:"button",onClick:()=>{e>r&&t(e-1)},disabled:e<=r,style:{width:28,height:28,display:"flex",alignItems:"center",justifyContent:"center",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",cursor:e<=r?"not-allowed":"pointer",fontSize:"14px",opacity:e<=r?.4:1,fontFamily:"inherit"},children:"−"}),de(h,{sx:{fontWeight:700,fontSize:"14px",minWidth:24,textAlign:"center"},children:e}),de("button",{type:"button",onClick:()=>{e<o&&t(e+1)},disabled:e>=o,style:{width:28,height:28,display:"flex",alignItems:"center",justifyContent:"center",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",cursor:e>=o?"not-allowed":"pointer",fontSize:"14px",opacity:e>=o?.4:1,fontFamily:"inherit"},children:"+"})]})}function Yd({label:e,checked:t,onChange:r,caption:o,disabled:n}){return ce(h,{sx:{py:.5,opacity:n?.4:1},children:[de(v,{control:de(b,{checked:t,onChange:e=>r(e.target.checked),size:"small",disabled:n,sx:{color:"var(--Text-Quiet)","&.Mui-checked":{color:"var(--Buttons-Primary-Button)"}}}),label:de(ko,{children:e}),sx:{m:0}}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginLeft:32},children:o})]})}function $d(){const[e,t]=r(0),[o,n]=r(0),[a,l]=r(!0),[s,d]=r(!0),[c,u]=r("vertical"),[p,m]=r(!0),[f,g]=r("default"),[x,b]=r(4),[v,y]=r(Gd.map(e=>({icon:e.icon,label:e.label}))),S=x<=4;i(()=>{x>4&&"horizontal"===c&&u("vertical")},[x,c]),i(()=>{y(e=>{const t=[],r=[{icon:"Favorite",label:"Favorites"},{icon:"Person",label:"Profile"}];for(let o=0;o<x;o++)if(e[o])t.push(e[o]);else{const e=r[o-Gd.length]||{icon:jd[o%jd.length],label:jd[o%jd.length]};t.push(e)}return t}),n(e=>Math.min(e,x-1))},[x]);const k=(e,t,r)=>{y(o=>{const n=[...o];return n[e]={...n[e],[t]:r},n})},w=v.slice(0,x).map(e=>({icon:Qd[e.icon]||Qd.Home,label:e.label}));return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Bottom Navigation"}),ce(N,{value:e,onChange:(e,r)=>t(r),sx:{mt:3,mb:0,borderBottom:"1px solid var(--Border)","& .MuiTabs-indicator":{backgroundColor:"var(--Buttons-Primary-Button)",height:3},"& .MuiTab-root":{color:"var(--Text-Quiet)",textTransform:"none",fontWeight:500,"&.Mui-selected":{color:"var(--Text)"}}},children:[de(H,{label:"Playground"}),de(H,{label:"Accessibility"})]}),0===e&&ce(I,{container:!0,sx:{minHeight:400},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"calc((100vw - 432px) / 2)"},flexShrink:0},children:[ce(h,{sx:{p:4,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",minHeight:300,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)",gap:4},children:[de(h,{sx:{width:"100%",maxWidth:500,overflow:"hidden",boxShadow:"0 2px 12px rgba(0,0,0,0.08)"},children:de(Hd,{items:w,value:o,onChange:n,showLabels:s,labelOrientation:c,backfill:p,barColor:f,fixed:!1},"bn-"+x+"-"+c+"-"+p+"-"+s+"-"+f)}),ce(bo,{style:{color:"var(--Text-Quiet)",textAlign:"center"},children:[x," items · ",s?"horizontal"===c&&S?"Horizontal labels":"Vertical labels":"Icons only",p?" · Backfill":""," · ",(Ud.find(e=>e.value===f)||Ud[0]).label]})]}),de(Ni,{code:(()=>{const e=[];e.push("const items = ["),w.forEach((t,r)=>{const o=v[r];e.push(" { icon: <"+o.icon+"Icon />, label: '"+o.label+"' },")}),e.push("];"),e.push("");const t=[];return t.push("items={items}"),"default"!==f&&t.push('barColor="'+f+'"'),s||t.push("showLabels={false}"),s&&"horizontal"===c&&S&&t.push('labelOrientation="horizontal"'),p||t.push("backfill={false}"),a||t.push("fixed={false}"),e.push("<BottomNavigation"),t.forEach(t=>e.push(" "+t)),e.push("/>"),e.join("\n")})(),language:"JSX",sx:{borderRadius:0,borderBottom:"1px solid var(--Border)"}})]}),ce(I,{item:!0,sx:{width:{xs:"calc(100vw - 432px)",md:"calc((100vw - 432px) / 2)"},flexShrink:0,p:3,backgroundColor:"var(--Container)",overflowY:"auto"},children:[de(Yr,{children:"Playground"}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BAR COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:Ud.map(e=>de(Xd,{label:e.label,selected:f===e.value,onClick:()=>g(e.value)},e.value))}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:[(Ud.find(e=>e.value===f)||Ud[0]).desc,' · data-surface="Surface-Dim" · bg: var(--Background)']})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(B,{spacing:0,children:[de(Yd,{label:"Fixed",checked:a,onChange:l,caption:"Position fixed to bottom of viewport."}),de(Yd,{label:"Labels",checked:s,onChange:d,caption:"Show text labels with icons."}),de(Yd,{label:"Selected Backfill",checked:p,onChange:m,caption:"Pill on selected: bg var(--Buttons-Primary-Button), border var(--Buttons-Primary-Border), icon var(--Buttons-Primary-Text)."})]})]}),s&&ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL ORIENTATION"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[de(Xd,{label:"Vertical",selected:"vertical"===c,onClick:()=>u("vertical")}),de(Xd,{label:"Horizontal",selected:"horizontal"===c&&S,onClick:()=>{S&&u("horizontal")},disabled:!S})]}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:S?"vertical"===c?"Icon above label (default). Label below pill.":"Icon beside label. Label inside pill when backfill is on.":"Horizontal is only available with 4 or fewer items. Reduce item count to enable."})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"NAVIGATION ITEMS"}),de(Jd,{label:"Count",value:x,onChange:b,min:3,max:6}),de(B,{spacing:1.5,sx:{mt:2},children:v.slice(0,x).map((e,t)=>ce(h,{sx:{display:"flex",alignItems:"center",gap:1,flexWrap:"nowrap"},children:[de(bo,{style:{color:"var(--Text-Quiet)",flexShrink:0,width:16,textAlign:"right"},children:t+1}),de(qd,{value:e.icon,onChange:e=>k(t,"icon",e),options:jd,label:"Item "+(t+1)+" icon"}),s&&de(Kd,{value:e.label,onChange:e=>k(t,"label",e),placeholder:"Label"})]},t))})]})]})]}),1===e&&ce(h,{sx:{p:4},children:[de(Yr,{children:"Accessibility Requirements"}),ce(ao,{color:"quiet",style:{marginBottom:32},children:[x," items · ",s?"Labels "+c:"Icons only",p?" · Backfill":""," · ",(Ud.find(e=>e.value===f)||Ud[0]).label]}),ce(B,{spacing:4,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Landmark:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<nav role="navigation" aria-label="Bottom navigation">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Tab list:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'role="tablist"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Tab items:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'role="tab", aria-selected, aria-label'})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Focus:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"3px solid var(--Focus-Visible) on :focus-visible."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Token Reference"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Bar:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'Always: data-surface="Surface-Dim" · bg: var(--Background). Theme set by data-theme (Nav-Bar, Primary, Primary-Light, etc.).'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Unselected icon/label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Text-Quiet)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Selected (no backfill):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Text)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Selected backfill pill:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"bg: var(--Buttons-Primary-Button) · border: 1px solid var(--Buttons-Primary-Border) · icon/text: var(--Buttons-Primary-Text)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Backfill + horizontal label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"Label inside pill: var(--Buttons-Primary-Text)"})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Backfill + vertical label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"Label below pill: var(--Text)"})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Best Practices"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Item count:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"3–5 recommended. 6 maximum."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Horizontal layout:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Only available with 4 or fewer items."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Labels:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Always recommended for clarity."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Fixed:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Add bottom padding to main content to avoid overlap."})]})]})]})]})]})]})}const Zd={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},_d={small:{indicator:24,fontSize:"11px",labelFontSize:"13px",connectorThickness:2,gap:0},medium:{indicator:32,fontSize:"13px",labelFontSize:"14px",connectorThickness:2,gap:0},large:{indicator:40,fontSize:"16px",labelFontSize:"16px",connectorThickness:2,gap:0}},ec=s({orientation:"horizontal",size:"medium",color:"primary",activeStep:0,clickable:!1,onStepClick:null,dashedIncomplete:!1,totalSteps:0}),tc=()=>l(ec);function rc({children:e,orientation:r="horizontal",size:o="medium",color:n="primary",activeStep:i=0,clickable:a=!1,onStepClick:l,dashedIncomplete:s=!1,className:d="",sx:c={},...u}){const p=t.Children.toArray(e).filter(t.isValidElement),m=p.length,f="horizontal"===r;return de(ec.Provider,{value:{orientation:r,size:o,color:n,activeStep:i,clickable:a,onStepClick:l,dashedIncomplete:s,totalSteps:m},children:de(h,{component:"ol",role:"list","aria-label":"Progress",className:"stepper stepper-"+r+" stepper-"+o+" stepper-"+n+" "+d,sx:{display:"flex",flexDirection:f?"row":"column",alignItems:f?"flex-start":"stretch",listStyle:"none",margin:0,padding:0,width:"100%",gap:0,...c},...u,children:p.map((e,r)=>t.cloneElement(e,{_index:r,key:e.key||r}))})})}function oc({children:e,icon:t,label:r,_index:o=0,className:n="",sx:i={},...a}){const{orientation:l,size:s,color:d,activeStep:c,clickable:u,onStepClick:p,dashedIncomplete:m,totalSteps:f}=tc(),g=_d[s]||_d.medium,x=Zd[d]||"Primary",b="horizontal"===l,v=o===c,y=o<c,S=o>c,k=o===f-1,B=t||o+1,w=r||e,C="var(--Buttons-"+x+"-Border)",T=v||y?"var(--Buttons-"+x+"-Button)":"transparent",I=v||y?"var(--Buttons-"+x+"-Text)":"var(--Text)",A=v||y?"var(--Buttons-"+x+"-Hover)":"var(--Hover)",z=v||y?"var(--Buttons-"+x+"-Pressed)":"var(--Pressed)",R=de(h,{component:u?"button":"div",onClick:u?()=>p?.(o):void 0,onKeyDown:u?e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),p?.(o))}:void 0,tabIndex:u?0:void 0,role:u?"button":void 0,"aria-label":u?"Go to step "+(o+1):void 0,"aria-current":v?"step":void 0,className:"step-indicator step-indicator-"+s+(v?" step-indicator-active":"")+(y?" step-indicator-completed":"")+(S?" step-indicator-incomplete":"")+(u?" step-indicator-clickable":""),sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:g.indicator+"px",height:g.indicator+"px",minWidth:g.indicator+"px",minHeight:g.indicator+"px",borderRadius:"50%",border:(v?"2px":"1px")+" solid "+C,backgroundColor:T,color:I,fontSize:g.fontSize,fontFamily:"inherit",fontWeight:700,lineHeight:1,flexShrink:0,position:"relative",transition:"background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease",cursor:u?"pointer":"default",outline:"none",padding:0,..."small"===s&&{"&::after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"24px",height:"24px",borderRadius:"50%"}},...u&&{"&:hover":{backgroundColor:A},"&:active":{backgroundColor:z},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px"}}},children:B}),E=k?null:de(h,{className:"step-connector"+(y?" step-connector-completed":"")+(S?" step-connector-incomplete":"")+(m&&S?" step-connector-dashed":""),"aria-hidden":"true",sx:{flex:1,...b?{height:g.connectorThickness+"px",minWidth:"20px",alignSelf:"flex-start",marginTop:g.indicator/2-g.connectorThickness/2+"px",marginLeft:"8px",marginRight:"8px"}:{width:g.connectorThickness+"px",minHeight:"24px",marginLeft:g.indicator/2-g.connectorThickness/2+"px",marginTop:"4px",marginBottom:"4px"},backgroundColor:y?"var(--Buttons-"+x+"-Button)":"var(--Border)",...m&&S&&{backgroundColor:"transparent",backgroundImage:b?"repeating-linear-gradient(90deg, var(--Border) 0px, var(--Border) 6px, transparent 6px, transparent 12px)":"repeating-linear-gradient(180deg, var(--Border) 0px, var(--Border) 6px, transparent 6px, transparent 12px)",backgroundSize:b?"12px 100%":"100% 12px"},transition:"background-color 0.15s ease"}}),P=w?de("small"===s?bo:ao,{style:{fontWeight:v?600:400,color:v||y?"var(--Text)":"var(--Quiet)",textAlign:b?"center":"left",whiteSpace:"nowrap",lineHeight:1.3},children:w}):null;return ce(h,b?{component:"li",className:"step step-"+s+" step-horizontal"+(v?" step-active":"")+(y?" step-completed":"")+(S?" step-incomplete":"")+" "+n,sx:{display:"flex",alignItems:"center",flex:k?"none":1,...i},...a,children:[ce(h,{sx:{display:"flex",flexDirection:"column",alignItems:"center",flexShrink:0},children:[R,P&&de(h,{sx:{mt:"4px"},children:P})]}),E]}:{component:"li",className:"step step-"+s+" step-vertical"+(v?" step-active":"")+(y?" step-completed":"")+(S?" step-incomplete":"")+" "+n,sx:{display:"flex",flexDirection:"column",alignItems:"flex-start",...i},...a,children:[ce(h,{sx:{display:"flex",alignItems:"center",gap:"8px"},children:[R,P]}),E]})}const nc=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ic=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],ac=["Account","Details","Review","Confirm","Complete","Done"];function lc({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function sc({color:e,selected:t,onClick:r}){const o=nc(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function dc(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r("horizontal"),[l,s]=r(4),[d,c]=r(1),[u,p]=r(!1),[m,f]=r(!1),[g,x]=r(null),[b,v]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Stepper"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:g,surface:b,children:de(h,{sx:{width:"100%",maxWidth:"vertical"===i?300:"100%"},children:de(rc,{color:e,size:o,orientation:i,activeStep:d,clickable:u,onStepClick:u?c:void 0,dashedIncomplete:m,children:ac.slice(0,l).map(e=>de(oc,{label:e},e))})})}),de(Ni,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),"horizontal"!==i&&t.push('orientation="vertical"'),t.push("activeStep={"+d+"}"),u&&t.push("clickable onStepClick={setActiveStep}"),m&&t.push("dashedIncomplete"),"<Stepper "+t.join(" ")+">\n"+ac.slice(0,l).map(e=>' <Step label="'+e+'" />').join("\n")+"\n</Stepper>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:g,onThemeChange:x,surface:b,onSurfaceChange:v})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STEPS"}),de(B,{direction:"row",spacing:1,children:[2,3,4,5,6].map(e=>de(lc,{label:String(e),selected:l===e,onClick:()=>{s(e),d>=e&&c(e-1)}},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ACTIVE STEP"}),de(B,{direction:"row",spacing:1,children:ac.slice(0,l).map((e,t)=>de(lc,{label:String(t+1),selected:d===t,onClick:()=>c(t)},t))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:ic.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(sc,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(lc,{label:nc(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ORIENTATION"}),de(B,{direction:"row",spacing:1,children:["horizontal","vertical"].map(e=>de(lc,{label:nc(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clickable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Steps are interactive buttons"})]}),de(_i,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Clickable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Dashed Incomplete"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Dashed connector for future steps"})]}),de(_i,{variant:"default-outline",checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Dashed incomplete"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Container",value:'<ol role="list" aria-label="Progress">'},{label:"Steps",value:"<li> elements with step state classes"},{label:"Active",value:'aria-current="step" on the active indicator'},{label:"Clickable",value:'role="button" aria-label="Go to step N" with tabIndex'},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: 2px"},{label:"Connectors",value:'aria-hidden="true" — decorative only'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}function cc({actions:e=[],variant:t="solid",color:a="default",direction:l="up",speed:s=50,showTooltips:d=!0,open:c,onOpen:u,onClose:p,icon:m,ariaLabel:f="Speed Dial",className:g="",sx:x={},...b}){const[v,y]=r(!1),S=void 0!==c,k=S?c:v,B=o(null),C=t,T=n(()=>{k?(S||y(!1),p?.()):(S||y(!0),u?.())},[k,S,u,p]),I=n((e,t)=>{e.onClick?.(t),S||y(!1),p?.()},[S,p]);i(()=>{if(!k)return;const e=e=>{B.current&&!B.current.contains(e.target)&&(S||y(!1),p?.())};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[k,S,p]),i(()=>{if(!k)return;const e=e=>{"Escape"===e.key&&(S||y(!1),p?.())};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[k,S,p]);const A="up"===l||"down"===l,z="up"===l||"down"===l?"left":"top";return ce(h,{ref:B,className:"speed-dial speed-dial-"+t+" speed-dial-"+a+" speed-dial-"+l+" "+g,sx:{position:"relative",display:"inline-flex",overflow:"visible",width:A?"56px":"auto",height:A?"auto":"56px",...x},...b,children:[de(Qa,{size:"large",variant:C,color:a,onClick:T,"aria-label":f,"aria-expanded":k,"aria-haspopup":"menu",sx:{position:"relative",zIndex:2},children:de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",transition:"transform 0.3s ease",transform:k?"rotate(45deg)":"rotate(0deg)"},children:m||de(At,{})})}),de(h,{role:"menu",sx:{position:"absolute",inset:0,pointerEvents:"none",overflow:"visible"},children:e.map((e,t)=>{const r=(e=>{const t=56+44*e;switch(l){case"up":default:return{bottom:t+"px",left:"12px"};case"down":return{top:t+"px",left:"12px"};case"left":return{right:t+"px",top:"12px"};case"right":return{left:t+"px",top:"12px"}}})(t),o=t*s,n=de(Qa,{size:"small",variant:C,color:a,role:"menuitem","aria-label":e.name||"Action "+(t+1),onClick:()=>I(e,t),sx:{position:"absolute",...r,opacity:k?1:0,transform:k?"scale(1)":"scale(0.3)",transition:"opacity 0.2s ease, transform 0.2s ease",transitionDelay:k?o+"ms":"0ms",pointerEvents:k?"auto":"none"},children:e.icon||de(At,{})},e.key||t);return d&&e.name?de(w,{title:e.name,placement:z,arrow:!0,open:!!k&&void 0,slotProps:{tooltip:{sx:{backgroundColor:"var(--Container)",color:"var(--Text)",fontSize:"12px",fontWeight:500,border:"1px solid var(--Border)",boxShadow:"0 2px 8px rgba(0,0,0,0.12)"}},arrow:{sx:{color:"var(--Container)"}}},children:n},e.key||t):n})})]})}const uc=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",pc=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],hc=[{name:"Edit",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(er,{})})},{name:"Share",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(tr,{})})},{name:"Delete",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(we,{})})},{name:"Favorite",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(ke,{})})}];function mc({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function fc({color:e,selected:t,onClick:r}){const o=uc(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function gc(){const[e,t]=r("solid"),[o,n]=r("default"),[i,a]=r("up"),[l,s]=r(!0),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Speed Dial"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:d,surface:u,sx:{minHeight:300,alignItems:"flex-end",justifyContent:"center"},children:de(cc,{variant:e,color:o,direction:i,showTooltips:l,actions:hc,ariaLabel:"Quick actions"})}),de(Ni,{code:(()=>{const t=[];return"solid"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"up"!==i&&t.push('direction="'+i+'"'),l||t.push("showTooltips={false}"),t.push("actions={actions}"),t.push('ariaLabel="Quick actions"'),"<SpeedDial\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["solid","outline"].map(r=>de(mc,{label:uc(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:pc.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(fc,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"DIRECTION"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["up","down","left","right"].map(e=>de(mc,{label:uc(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Tooltips"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show labels beside actions"})]}),de(_i,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Show tooltips"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"FAB",value:'aria-expanded, aria-haspopup="menu", aria-label'},{label:"Actions",value:'role="menu" container, role="menuitem" on each action'},{label:"Labels",value:"aria-label on each action from name prop"},{label:"Keyboard",value:"Escape closes. Click outside closes."},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: 2px"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const xc={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",black:"BW",white:"BW"};function bc(e,t){return"var(--"+(xc[e]||"Primary")+"-Color-"+t+")"}const vc={primary:{linear:[{family:"primary",tone:8,position:0},{family:"primary",tone:11,position:100}],radial:[{family:"primary",tone:8,position:0},{family:"primary",tone:11,position:100}],mesh:[{family:"primary",tone:8,x:20,y:20,spread:60},{family:"primary",tone:9,x:80,y:30,spread:50},{family:"primary",tone:10,x:50,y:80,spread:55}],meshCard:[{family:"primary",tone:3,x:10,y:10,spread:60},{family:"primary",tone:6,x:80,y:20,spread:50},{family:"primary",tone:9,x:40,y:80,spread:55}]},secondary:{linear:[{family:"secondary",tone:7,position:0},{family:"secondary",tone:10,position:100}],radial:[{family:"secondary",tone:7,position:0},{family:"secondary",tone:10,position:100}],mesh:[{family:"secondary",tone:7,x:15,y:25,spread:55},{family:"secondary",tone:9,x:75,y:35,spread:50},{family:"secondary",tone:11,x:45,y:75,spread:60}],meshCard:[{family:"secondary",tone:2,x:15,y:15,spread:55},{family:"secondary",tone:5,x:85,y:25,spread:50},{family:"secondary",tone:8,x:50,y:75,spread:60}]},tertiary:{linear:[{family:"tertiary",tone:8,position:0},{family:"tertiary",tone:11,position:100}],radial:[{family:"tertiary",tone:8,position:0},{family:"tertiary",tone:11,position:100}],mesh:[{family:"tertiary",tone:8,x:25,y:15,spread:55},{family:"tertiary",tone:10,x:70,y:40,spread:50},{family:"tertiary",tone:11,x:40,y:85,spread:55}],meshCard:[{family:"tertiary",tone:3,x:20,y:10,spread:60},{family:"tertiary",tone:7,x:75,y:30,spread:50},{family:"tertiary",tone:10,x:45,y:80,spread:55}]},black:{linear:[{family:"black",tone:10,position:0},{family:"neutral",tone:3,position:100}],radial:[{family:"black",tone:10,position:0},{family:"neutral",tone:3,position:100}],mesh:[{family:"black",tone:10,x:0,y:0,spread:100},{family:"primary",tone:3,x:25,y:25,spread:50},{family:"secondary",tone:4,x:75,y:35,spread:45},{family:"tertiary",tone:3,x:50,y:80,spread:50}],meshCard:[{family:"black",tone:11,x:0,y:0,spread:100},{family:"primary",tone:5,x:20,y:20,spread:55},{family:"secondary",tone:8,x:80,y:30,spread:45},{family:"tertiary",tone:10,x:45,y:80,spread:50}]},white:{linear:[{family:"white",tone:2,position:0},{family:"neutral",tone:9,position:100}],radial:[{family:"white",tone:2,position:0},{family:"neutral",tone:9,position:100}],mesh:[{family:"white",tone:2,x:0,y:0,spread:100},{family:"primary",tone:9,x:25,y:25,spread:50},{family:"secondary",tone:8,x:75,y:35,spread:45},{family:"tertiary",tone:9,x:50,y:80,spread:50}],meshCard:[{family:"white",tone:1,x:0,y:0,spread:100},{family:"primary",tone:4,x:20,y:20,spread:55},{family:"secondary",tone:7,x:80,y:30,spread:45},{family:"tertiary",tone:10,x:45,y:80,spread:50}]}};function yc(e,t){const r=vc[e]||vc.primary;return(r[t]||r.linear).map(e=>({...e}))}function Sc({variant:e="linear",color:t="primary",angle:r=135,stops:o=null,position:n=null,blobs:i=null,cardProps:a={},minHeight:l=300,children:s,className:d="",sx:c={},...u}){const p="meshCard"===e,m="mesh"===e||p,f="radial"===e,g="linear"===e||f,x=o||yc(t,f?"radial":"linear"),b=i||yc(t,p?"meshCard":"mesh"),v=m?function(e){if(!e||0===e.length)return"none";const t=e.map(e=>{const t=bc(e.family,e.tone),r=e.spread||40;return"radial-gradient(circle at "+e.x+"% "+e.y+"%, "+t+" 0%, transparent "+r+"%)"}),r=bc(e[0].family,e[0].tone);return t.push(r),t.join(", ")}(b):f?function(e,t){if(!e||0===e.length)return"none";const r=[...e].sort((e,t)=>e.position-t.position).map(e=>bc(e.family,e.tone)+" "+e.position+"%"),o=t||{x:50,y:50};return"radial-gradient(circle at "+o.x+"% "+o.y+"%, "+r.join(", ")+")"}(x,n||{x:50,y:50}):function(e,t){return e&&0!==e.length?"linear-gradient("+t+"deg, "+[...e].sort((e,t)=>e.position-t.position).map(e=>bc(e.family,e.tone)+" "+e.position+"%").join(", ")+")":"none"}(x,r),y=g?x[0]:b[0];var S,k;const B=function(e){return"dark"===e?"var(--BW-Color-1)":"var(--BW-Color-6)"}((S=y?.tone||8,"black"===(k=y?.family||"primary")||"white"===k?S<=5?"light":"dark":S<=5?"dark":"light"));return de(h,p?{className:"gradient gradient-mesh-card "+d,sx:{background:v,minHeight:l,borderRadius:"var(--Card-Radius)",display:"flex",alignItems:"center",justifyContent:"center",padding:"var(--Card-Padding)",position:"relative",overflow:"hidden",...c},...u,children:de(Oa,{variant:"solid",...a,children:de(La,{children:s})})}:{className:"gradient gradient-"+e+" "+d,sx:{background:v,minHeight:l,borderRadius:"var(--Card-Radius)",color:B,display:"flex",alignItems:"center",justifyContent:"center",position:"relative",overflow:"hidden",...c},...u,children:s})}const kc=e=>de(Sc,{variant:"linear",...e}),Bc=e=>de(Sc,{variant:"radial",...e}),wc=e=>de(Sc,{variant:"mesh",...e}),Cc=e=>de(Sc,{variant:"meshCard",...e});function Tc({children:e,surface:t="Container",outlined:r=!1,variant:o=(r?"outlined":"elevation"),sx:n={},...i}){const{dataSurface:a,elevation:l}=function(e="Container"){const t={"Container-Lowest":{elevation:0,zIndex:0},"Container-Low":{elevation:1,zIndex:100},Container:{elevation:4,zIndex:200},"Container-High":{elevation:8,zIndex:300},"Container-Highest":{elevation:12,zIndex:400}},r=t[e]||t.Container;return{dataSurface:e,elevation:r.elevation,zIndex:r.zIndex}}(t);return de(V,{variant:o,elevation:r?0:l,"data-surface":a,sx:{padding:2,borderRadius:"8px",transition:"all 0.2s ease-in-out",...n},...i,children:e})}function Ic({open:e=!1,onClose:t,anchorRef:n,placement:a="bottom-end",theme:l="Default",surface:s="Surface-Bright",width:d=320,maxHeight:c=400,children:u,sx:p={}}){const m=o(null),[f,g]=r({top:0,left:0,right:"auto"});return i(()=>{if(!e||!n?.current)return;const t=n.current.getBoundingClientRect();g("bottom-end"===a?{top:t.bottom+6,right:window.innerWidth-t.right,left:"auto"}:{top:t.bottom+6,left:t.left,right:"auto"})},[e,n,a]),i(()=>{if(!e)return;const r=e=>{m.current?.contains(e.target)||n?.current?.contains(e.target)||t?.()};return document.addEventListener("pointerdown",r),()=>document.removeEventListener("pointerdown",r)},[e,t,n]),i(()=>{if(!e)return;const r=e=>{"Escape"===e.key&&t?.()};return document.addEventListener("keydown",r),()=>document.removeEventListener("keydown",r)},[e,t]),e?ye.createPortal(de(h,{ref:m,"data-theme":l,"data-surface":s,sx:{position:"fixed",top:f.top,left:f.left,right:f.right,zIndex:2e9,width:d,maxHeight:c,overflowY:"auto",backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",boxShadow:sn,...p},children:u}),document.body):null}["default","primary","secondary","tertiary","neutral"].map(e=>{return{value:e,label:(t=e,t?t.charAt(0).toUpperCase()+t.slice(1):"")};var t});const Ac=s(null),zc=["Default","Primary-Light","Primary","Secondary-Light","Secondary","Tertiary-Light","Tertiary","Neutral-Light","Neutral","Error-Light","Success-Light","Warning-Light","Info-Light","Primary-Dark","Secondary-Dark","Tertiary-Dark","Neutral-Dark","Error-Dark","Success-Dark","Warning-Dark","Info-Dark","App-Bar","Nav-Bar","Status"],Rc=["Professional","Modern","Bold","Playful"],Ec=["Surface-Dimmest","Surface-Dim","Surface","Surface-Bright","Surface-Brightest","Container","Container-Low","Container-Lowest","Container-High","Container-Highest"],Pc={"light-tonal":{theme:"Primary",rootSurface:"Surface-Brightest"},"grey-professional":{theme:"Neutral",rootSurface:"Surface"},"dark-professional":{theme:"Neutral-Dark",rootSurface:"Surface"}},Oc="omni-foundation",Lc="omni-core",Mc="omni-typography",Wc="omni-mode",Dc="omni-base",Fc="omni-styles";function Nc(e){document.getElementById(e)?.remove()}function Hc(e,t,r){return t?function(e){return!(!e||"string"!=typeof e)&&(e.startsWith("http")||e.startsWith("/")||e.endsWith(".css"))}(t)?function(e,t,r){const o=document.getElementById(e);return o?"LINK"===o.tagName&&o.getAttribute("href")!==t?new Promise((e,r)=>{o.onload=()=>e(o),o.onerror=()=>r(new Error(`OmniDesignProvider: failed to load ${t}`)),o.setAttribute("href",t)}):Promise.resolve(o):new Promise((o,n)=>{const i=document.createElement("link");i.id=e,i.rel="stylesheet",i.setAttribute("data-omni","true"),i.onload=()=>o(i),i.onerror=()=>n(new Error(`OmniDesignProvider: failed to load ${t}`)),i.href=t;const a=r?document.getElementById(r):null;a?document.head.insertBefore(i,a):document.head.appendChild(i)})}(e,t,r):function(e,t,r){if(!t)return Promise.resolve(null);const o=document.getElementById(e);if(o)return o.textContent=t,Promise.resolve(o);const n=document.createElement("style");n.id=e,n.setAttribute("data-omni","true"),n.textContent=t;const i=r?document.getElementById(r):null;return i?document.head.insertBefore(n,i):document.head.appendChild(n),Promise.resolve(n)}(e,t,r):Promise.resolve(null)}function Vc({themeURL:e,foundationCSS:t,coreCSS:a,typographyCSS:l,lightModeCSS:s,darkModeCSS:c,baseCSS:u,stylesCSS:p,defaultTheme:h="Default",defaultStyle:m="Modern",defaultSurface:f="Surface",surfaceStyle:g,defaultDarkMode:x=!1,darkTheme:b="Neutral-Dark",darkMode:v,onDarkModeChange:y,className:S,style:k,fullHeight:B=!0,children:w}){const[C,T]=r(x),I=void 0!==v,A=I?v:C,[z,R]=r({foundation:t??null,core:a??null,typography:l??null,lightMode:s??null,darkMode:c??null,base:u??null,styles:p??null}),[E,P]=r({}),O=o(!0);i(()=>(O.current=!0,()=>{O.current=!1}),[]),i(()=>{e&&(X("loading"),async function(e){const t=/\.json(\?|$)/.test(e)?e:`${e.replace(/\/$/,"")}/theme.json`,r=e.replace(/\/$/,"").replace(/\/theme\.json(\?.*)?$/,""),o=await fetch(t);if(!o.ok)throw new Error(`OmniDesignProvider: could not load theme manifest from ${t} (${o.status})`);const n=await o.json(),i=e=>e?/^https?:\/\//i.test(e)?e:`${r}/${e}`:null;return{foundationURL:i(n.foundation),coreURL:i(n.core),typographyURL:i(n.typography),lightModeURL:i(n.lightMode),darkModeURL:i(n.darkMode),baseURL:i(n.base),stylesURL:i(n.styles),defaultTheme:n.defaultTheme??null,defaultStyle:n.defaultStyle??null,defaultSurface:n.defaultSurface??null,darkTheme:n.darkTheme??null,name:n.name??null}}(e).then(e=>{O.current&&(R({foundation:t??e.foundationURL,core:a??e.coreURL,typography:l??e.typographyURL,lightMode:s??e.lightModeURL,darkMode:c??e.darkModeURL,base:u??e.baseURL,styles:p??e.stylesURL}),P({defaultTheme:e.defaultTheme,defaultStyle:e.defaultStyle,defaultSurface:e.defaultSurface,darkTheme:e.darkTheme,name:e.name}))}).catch(e=>{O.current&&(console.error("OmniDesignProvider: manifest error:",e),q(e.message),X("error"))}))},[e]);const L=g?Pc[g]?.theme??h:"Default"!==h?h:E.defaultTheme??h,M=g?Pc[g]?.rootSurface??f:E.defaultSurface??f,W=E.defaultStyle??m,D="Neutral-Dark"!==b?b:E.darkTheme??b,[F,N]=r(L),[H,V]=r(W),[Q,j]=r(M),G=!!(e||t||a||l||s||c||u||p),[U,X]=r(G?"loading":"ready"),[K,q]=r(null);i(()=>{const{foundation:e,core:t,typography:r,base:o,styles:n}=z;if(e||t||r||o||n)return X("loading"),q(null),Promise.all([Hc(Oc,e),Hc(Lc,t),Hc(Mc,r).catch(e=>{console.warn("OmniDesignProvider: typography CSS did not load —",e.message)}),Hc(Dc,o),Hc(Fc,n)]).then(()=>{O.current&&X("ready")}).catch(e=>{O.current&&(console.error("OmniDesignProvider CSS error:",e),q(e.message),X("error"))}),()=>{Nc(Oc),Nc(Lc),Nc(Mc),Nc(Dc),Nc(Fc)};X("ready")},[z.foundation,z.core,z.typography,z.base,z.styles]),i(()=>{const e=A?z.darkMode:z.lightMode;e&&Hc(Wc,e,Dc).catch(e=>console.error("OmniDesignProvider mode CSS error:",e))},[A,z.lightMode,z.darkMode]),i(()=>()=>Nc(Wc),[]);const J=A?D:F,Y=n(()=>{I?y?.(!A):T(e=>!e)},[I,A,y]),$=n(e=>{zc.includes(e)||console.warn(`OmniDesignProvider: unknown theme "${e}"`),N(e)},[]),Z=n(e=>{Rc.includes(e)||console.warn(`OmniDesignProvider: unknown style "${e}"`),V(e)},[]),_=n(e=>{Ec.includes(e)||console.warn(`OmniDesignProvider: unknown surface "${e}"`),j(e)},[]),ee=d(()=>({theme:J,style:H,surface:Q,isDark:A,cssStatus:U,cssError:K,setTheme:$,setStyle:Z,setSurface:_,toggleDarkMode:Y,themes:zc,styles:Rc,surfaces:Ec,name:E.name??null}),[J,H,Q,A,U,K,$,Z,_,Y,E.name]);return ce(Ac.Provider,{value:ee,children:[de("style",{"data-omni":"hide-during-load",children:'[data-omni-css="loading"]{visibility:hidden}'}),de("div",{"data-theme":J,"data-style":H,"data-surface":Q,"data-omni-css":U,className:S,style:{...B?{minHeight:"100vh"}:{},...k},children:w})]})}function Qc(){const e=l(Ac);if(!e)throw new Error("useOmniDesign must be used inside a <OmniDesignProvider>");return e}function jc({theme:e,surface:t,as:r="div",children:o,className:n,style:i,...a}){return de(r,{"data-theme":e,"data-surface":t,className:n,style:i,...a,children:o})}function Gc({surface:e,as:t="div",children:r,className:o,style:n,...i}){return de(t,{"data-surface":e,className:o,style:n,...i,children:r})}const Uc=e=>c(function(t,r){return de(Y,{direction:e,ref:r,...t})}),Xc={fade:c(function(e,t){return de(J,{ref:t,...e})}),grow:c(function(e,t){return de(q,{ref:t,...e})}),zoom:c(function(e,t){return de(K,{ref:t,...e})}),"slide-up":Uc("up"),"slide-down":Uc("down"),"slide-left":Uc("left"),"slide-right":Uc("right")},Kc={backgroundColor:"var(--Background)",color:"var(--Text)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",boxShadow:"0 8px 32px rgba(0,0,0,0.18)"},qc={color:"var(--Text)",fontWeight:600,fontSize:"18px",fontFamily:"inherit",borderBottom:"1px solid var(--Border)",display:"flex",justifyContent:"space-between",alignItems:"center",py:1.5,px:3},Jc={color:"var(--Text)",fontFamily:"inherit",fontSize:"14px",lineHeight:1.6,py:3,px:3},Yc={borderTop:"1px solid var(--Border)",px:3,py:1.5,gap:1},$c={fontFamily:"inherit",fontWeight:500,fontSize:"14px",borderRadius:"var(--Style-Border-Radius)",padding:"6px 16px",cursor:"pointer",border:"none",transition:"background-color 0.15s, color 0.15s","&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"1px"}},Zc={primary:{...$c,backgroundColor:"var(--Buttons-Primary-Button)",color:"var(--Buttons-Primary-Text)",border:"1px solid var(--Buttons-Primary-Border)","&:hover":{backgroundColor:"var(--Buttons-Primary-Hover)"}},outline:{...$c,backgroundColor:"transparent",color:"var(--Text)",border:"1px solid var(--Border)","&:hover":{backgroundColor:"var(--Hover)"}}};function _c({open:e=!1,onClose:t,title:r,children:o,actions:n,maxWidth:i="sm",fullScreen:a=!1,scroll:l="body",alert:s=!1,nonModal:d=!1,transition:c,transitionDuration:u=300,titleId:p="dialog-title",contentId:m="dialog-description",className:f="",sx:g={},PaperProps:x={},...b}){const v=c?Xc[c]:void 0;let y;try{y=Qc()}catch{y=null}const S=y?.theme||"Default",k=y?.style||"Modern",B=y?.surface||"Surface";return ce(Q,{open:e,onClose:(e,r)=>{s&&"backdropClick"===r||s&&"escapeKeyDown"===r||t?.(e,r)},maxWidth:!a&&i,fullScreen:a,fullWidth:!a,scroll:l,hideBackdrop:d,disableEnforceFocus:d,disableEscapeKeyDown:s,TransitionComponent:v,transitionDuration:u,"aria-labelledby":p,"aria-describedby":m,className:"dialog dialog-"+i+(a?" dialog-fullscreen":"")+(s?" dialog-alert":"")+(f?" "+f:""),style:{zIndex:1e7},slotProps:{backdrop:{sx:{backgroundColor:d?"transparent":"rgba(0,0,0,0.5)"}}},PaperProps:{...x,"data-theme":S,"data-style":k,"data-surface":B,sx:{...Kc,...a&&{borderRadius:0,border:"none"},...x.sx},role:s?"alertdialog":"dialog"},...b,children:[r&&ce(j,{id:p,sx:qc,children:[r,!s&&t&&de(C,{"aria-label":"Close dialog",onClick:e=>t(e,"closeButton"),size:"small",sx:{color:"var(--Text-Quiet)","&:hover":{backgroundColor:"var(--Hover)"}},children:de(Ot,{fontSize:"small"})})]}),de(G,{dividers:"paper"===l,sx:{...Jc,..."paper"===l&&{maxHeight:a?"none":"400px",overflowY:"auto",borderColor:"var(--Border)"}},children:s?de(U,{id:m,sx:{color:"var(--Text)",fontFamily:"inherit",fontSize:"14px",lineHeight:1.6},children:o}):de(h,{id:m,children:o})}),n&&de(X,{sx:Yc,children:n})]})}function eu({open:e,onClose:t,title:r,children:o,confirmText:n="Confirm",cancelText:i="Cancel",onConfirm:a,onCancel:l,...s}){return de(_c,{open:e,onClose:t,title:r,alert:!0,...s,actions:ce(ue,{children:[de(h,{component:"button",type:"button",onClick:l||t,sx:Zc.outline,children:i}),de(h,{component:"button",type:"button",onClick:a||t,sx:Zc.primary,children:n})]}),children:o})}function tu({open:e,onClose:t,title:r,children:o,submitText:n="Submit",cancelText:i="Cancel",onSubmit:a,...l}){return de(_c,{open:e,onClose:t,title:r,...l,actions:ce(ue,{children:[de(h,{component:"button",type:"button",onClick:t,sx:Zc.outline,children:i}),de(h,{component:"button",type:"button",onClick:a,sx:Zc.primary,children:n})]}),children:o})}function ru({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function ou(){const[e,t]=r(!1),[o,n]=r("sm"),[i,a]=r(!1),[l,s]=r("none"),[d,c]=r(!1),[u,p]=r(!1),[m,f]=r(null),[g,x]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Dialog"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:m,surface:g,children:de(Tn,{variant:"default",onClick:()=>t(!0),children:"Open Dialog"})}),de(Ni,{code:(()=>{const e=["open={open}","onClose={handleClose}"];return"sm"!==o&&e.push('maxWidth="'+o+'"'),i&&e.push("fullScreen"),d&&e.push("alert"),u&&e.push("nonModal"),"none"!==l&&e.push('transition="'+l+'"'),e.push('title="Dialog Title"'),e.push('actions={<><Button variant="default-outline" onClick={handleClose}>Cancel</Button><Button variant="default" onClick={handleClose}>Confirm</Button></>}'),"<Dialog\n "+e.join("\n ")+"\n>\n Dialog content goes here.\n</Dialog>"})(),language:"JSX",wrap:!0,sx:{mt:2}}),de(_c,{open:e,onClose:(e,r)=>{d&&"backdropClick"===r||t(!1)},maxWidth:o,fullScreen:i,alert:d,nonModal:u,transition:"none"!==l?l:void 0,title:"Dialog Title",actions:ce(ue,{children:[de(Tn,{variant:"default-outline",size:"small",onClick:()=>t(!1),children:"Cancel"}),de(Tn,{variant:"default",size:"small",onClick:()=>t(!1),children:"Confirm"})]}),children:de(co,{children:"This is the dialog content. You can put any information here that requires user attention or action."})})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:m,onThemeChange:f,surface:g,onSurfaceChange:x})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[["xs","sm","md","lg","xl"].map(e=>de(ru,{label:e.toUpperCase(),selected:o===e,onClick:()=>{n(e),a(!1)}},e)),de(ru,{label:"Full Screen",selected:i,onClick:()=>a(!i)})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TRANSITION"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["none","slide-up","slide-down","grow","fade","zoom"].map(e=>{return de(ru,{label:(t=e,t?t.charAt(0).toUpperCase()+t.slice(1):""),selected:l===e,onClick:()=>s(e)},e);var t})})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Alert"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"No backdrop dismiss, no Escape"})]}),de(_i,{variant:"default-outline",checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Alert mode"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Non-Modal"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"No backdrop, interact with content behind"})]}),de(_i,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Non-modal"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="dialog" (standard) or role="alertdialog" (alert mode)'},{label:"Label",value:"aria-labelledby links to title, aria-describedby links to content"},{label:"Focus",value:"Focus trapped inside dialog. Returns to trigger on close."},{label:"Keyboard",value:"Escape closes (unless alert). Tab cycles through focusable elements."},{label:"Backdrop",value:"Click closes (unless alert or non-modal)"},{label:"Close",value:'Close button with aria-label="Close dialog"'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const nu={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info-Medium",success:"Success-Medium",warning:"Warning-Medium",error:"Error-Medium"},iu={primary:"Primary-Light",secondary:"Secondary-Light",tertiary:"Tertiary-Light",neutral:"Neutral-Light",info:"Info-Light",success:"Success-Light",warning:"Warning-Light",error:"Error-Light"},au={small:{maxWidth:400,padding:"24px"},medium:{maxWidth:560,padding:"32px"},large:{maxWidth:720,padding:"40px"}},lu={fade:{enter:{from:{opacity:0},to:{opacity:1}},name:"modal-fade"},"slide-up":{enter:{from:{opacity:0,transform:"translateY(40px)"},to:{opacity:1,transform:"translateY(0)"}},name:"modal-slide-up"},"slide-down":{enter:{from:{opacity:0,transform:"translateY(-40px)"},to:{opacity:1,transform:"translateY(0)"}},name:"modal-slide-down"},zoom:{enter:{from:{opacity:0,transform:"scale(0.85)"},to:{opacity:1,transform:"scale(1)"}},name:"modal-zoom"}};function su(e){const t=lu[e];if(!t)return"";const{from:r,to:o}=t.enter,n=Object.entries(r).map(([e,t])=>e+":"+t).join(";"),i=Object.entries(o).map(([e,t])=>e+":"+t).join(";");return"@keyframes "+t.name+" { from {"+n+"} to {"+i+"} }@keyframes "+t.name+"-backdrop { from { opacity: 0 } to { opacity: 1 } }"}function du({open:e,onClose:t,children:n,title:a,variant:l="default",color:s="primary",size:d="medium",layout:c="center",transition:u="fade",transitionSpeed:p=250,closeOnBackdrop:m=!0,showCloseButton:f=!0,className:g="",sx:x={},...b}){const v=o(null),y=o(null),[S,k]=r(!1);let B;try{B=Qc()}catch{B=null}const w=B?.theme||"Default",C=B?.style||"Modern",T="soft"===l,I="solid"===l,A="fullscreen"===c,z=I?nu[s]:T?iu[s]:null,R=au[d]||au.medium,E=lu[u],P=E?E.name:void 0,O=p+"ms";return i(()=>(e?(y.current=document.activeElement,k(!0),requestAnimationFrame(()=>{v.current?.focus()}),document.body.style.overflow="hidden"):(k(!1),document.body.style.overflow="",y.current?.focus()),()=>{document.body.style.overflow=""}),[e]),i(()=>{if(!e)return;const r=e=>{"Escape"===e.key&&t?.()};return document.addEventListener("keydown",r),()=>document.removeEventListener("keydown",r)},[e,t]),e||S?ce(ue,{children:["none"!==u&&de("style",{children:su(u)}),de(h,{"aria-hidden":"true",onClick:m?t:void 0,sx:{position:"fixed",inset:0,zIndex:1e7,backgroundColor:"rgba(0,0,0,0.5)",...P&&{animation:P+"-backdrop "+O+" ease-out forwards"}}}),ce(h,{role:"dialog","aria-modal":"true","aria-label":a||"Modal",ref:v,tabIndex:-1,"data-surface":"Container-High","data-theme":z||w,"data-style":C,className:"modal modal-"+l+" modal-"+d+" modal-"+c+(T||I?" modal-"+s:"")+(g?" "+g:""),sx:{position:"fixed",zIndex:10000001,outline:"none",fontFamily:"inherit",...A?{inset:0,borderRadius:0}:{top:"50%",left:"50%",transform:"translate(-50%, -50%)",maxWidth:R.maxWidth+"px",width:"calc(100% - 32px)",maxHeight:"calc(100vh - 64px)",borderRadius:"var(--Modal-Radius, var(--Style-Border-Radius))"},backgroundColor:"var(--Background)",color:"var(--Text)",boxShadow:"0 8px 32px rgba(0,0,0,0.24)",display:"flex",flexDirection:"column",overflow:"hidden",...P&&{animation:P+" "+O+" ease-out forwards"},...x},...b,children:[(a||f)&&ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",px:A?4:R.padding,pt:A?3:R.padding,pb:0,flexShrink:0},children:[a&&de(h,{sx:{fontSize:"small"===d?"18px":"large"===d?"24px":"20px",fontWeight:700,color:"var(--Text)",flex:1},children:a}),f&&de(h,{component:"button",type:"button","aria-label":"Close modal",onClick:t,sx:{display:"flex",alignItems:"center",justifyContent:"center",width:32,height:32,borderRadius:"50%",border:"none",backgroundColor:"transparent",color:"var(--Text-Quiet)",cursor:"pointer",flexShrink:0,ml:1,transition:"background-color 0.15s ease, color 0.15s ease","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(Ot,{sx:{fontSize:20}})})]}),de(h,{sx:{flex:1,overflowY:"auto",px:A?4:R.padding,pt:A?3:"16px",pb:A?3:R.padding,color:"var(--Text)",fontSize:"small"===d?"13px":"14px",lineHeight:1.6},children:n})]})]}):null}const cu={small:{width:"240px",height:"200px"},medium:{width:"320px",height:"280px"},large:{width:"420px",height:"380px"}},uu={left:{borderRight:"1px solid var(--Border)"},right:{borderLeft:"1px solid var(--Border)"},top:{borderBottom:"1px solid var(--Border)"},bottom:{borderTop:"1px solid var(--Border)"}},pu={left:{top:0,left:0,bottom:0},right:{top:0,right:0,bottom:0},top:{top:0,left:0,right:0},bottom:{bottom:0,left:0,right:0}},hu={left:"translateX(-100%)",right:"translateX(100%)",top:"translateY(-100%)",bottom:"translateY(100%)"};function mu({children:e,open:t=!1,onClose:r,size:a="medium",anchor:l="left",hideBackdrop:s=!1,className:d="",sx:c={},...u}){const p=o(null),m=o(null),f="left"===l||"right"===l;let g;try{g=Qc()}catch{g=null}const x=g?.theme||"Default",b=g?.style||"Modern",v=cu[a]||cu.medium;i(()=>{if(!t)return;const e=e=>{"Escape"===e.key&&r?.()};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[t,r]),i(()=>{t?(m.current=document.activeElement,requestAnimationFrame(()=>{const e=p.current?.querySelector('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');e?e.focus():p.current?.focus()})):m.current&&(m.current.focus(),m.current=null)},[t]),i(()=>{if(t){const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}}},[t]);const y=n(e=>{if("Tab"!==e.key||!p.current)return;const t=p.current.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');if(!t.length)return;const r=t[0],o=t[t.length-1];e.shiftKey?document.activeElement===r&&(e.preventDefault(),o.focus()):document.activeElement===o&&(e.preventDefault(),r.focus())},[]);return t?ce(ue,{children:[!s&&de(h,{onClick:()=>r?.(),"aria-hidden":"true",sx:{position:"fixed",inset:0,zIndex:1e7,backgroundColor:"rgba(0, 0, 0, 0.5)",transition:"opacity 0.3s ease"}}),de(h,{ref:p,role:"dialog","aria-modal":"true",tabIndex:-1,"data-theme":x,"data-style":b,"data-surface":"Surface-Dim",onKeyDown:y,className:"drawer drawer-"+a+" drawer-"+l+" "+d,sx:{position:"fixed",zIndex:10000001,...pu[l],...f?{width:v.width,height:"100%"}:{height:v.height,width:"100%"},backgroundColor:"var(--Background)",color:"var(--Text)",...uu[l],boxShadow:ln,display:"flex",flexDirection:"column",outline:"none",overflow:"hidden",animation:"drawer-slide-in 0.3s ease forwards","@keyframes drawer-slide-in":{from:{transform:hu[l]},to:{transform:"translate(0, 0)"}},...c},...u,children:e})]}):null}function fu({onClick:e,className:t="",sx:r={},...o}){return de(h,{sx:{position:"absolute",top:"12px",right:"12px",zIndex:1,...r},className:t,...o,children:de(Tn,{iconOnly:!0,variant:"ghost",size:"small",onClick:e,"aria-label":"Close drawer",children:de(jo,{size:"small",children:de(Ot,{})})})})}function gu({children:e,className:t="",sx:r={},...o}){return de(h,{className:"drawer-header "+t,sx:{display:"flex",alignItems:"center",justifyContent:"space-between",padding:"16px",borderBottom:"1px solid var(--Border)",flexShrink:0,...r},...o,children:e})}function xu({children:e,className:t="",sx:r={},...o}){return de(h,{className:"drawer-content "+t,sx:{flex:1,overflowY:"auto",padding:"16px",...r},...o,children:e})}function bu(){return bu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)({}).hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},bu.apply(null,arguments)}const vu={};function yu(t,r){const o=e.useRef(vu);return o.current===vu&&(o.current=t(r)),o}function Su(e,t,r,o){const n=yu(ku).current;return function(e,t,r,o,n){return e.refs[0]!==t||e.refs[1]!==r||e.refs[2]!==o||e.refs[3]!==n}(n,e,t,r,o)&&function(e,t){if(e.refs=t,t.every(e=>null==e))return void(e.callback=null);e.callback=r=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),null!=r){const o=Array(t.length).fill(null);for(let e=0;e<t.length;e+=1){const n=t[e];if(null!=n)switch(typeof n){case"function":{const t=n(r);"function"==typeof t&&(o[e]=t);break}case"object":n.current=r}}e.cleanup=()=>{for(let e=0;e<t.length;e+=1){const r=t[e];if(null!=r)switch(typeof r){case"function":{const t=o[e];"function"==typeof t?t():r(null);break}case"object":r.current=null}}}}}}(n,[e,t,r,o]),n.callback}function ku(){return{callback:null,cleanup:null,refs:[]}}function Bu(e,t,r=void 0){const o={};for(const n in e){const i=e[n];let a="",l=!0;for(let e=0;e<i.length;e+=1){const o=i[e];o&&(a+=(!0===l?"":" ")+t(o),l=!1,r&&r[o]&&(a+=" "+r[o]))}o[n]=a}return o}function wu(e){var t,r,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var n=e.length;for(t=0;t<n;t++)e[t]&&(r=wu(e[t]))&&(o&&(o+=" "),o+=r)}else for(r in e)e[r]&&(o&&(o+=" "),o+=r);return o}function Cu(){for(var e,t,r=0,o="",n=arguments.length;r<n;r++)(e=arguments[r])&&(t=wu(e))&&(o&&(o+=" "),o+=t);return o}function Tu(e,t=[]){if(void 0===e)return{};const r={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&"function"==typeof e[r]&&!t.includes(r)).forEach(t=>{r[t]=e[t]}),r}function Iu(e){if(void 0===e)return{};const t={};return Object.keys(e).filter(t=>!(t.match(/^on[A-Z]/)&&"function"==typeof e[t])).forEach(r=>{t[r]=e[r]}),t}function Au(e,t,r){return"function"==typeof e?e(t,r):e}function zu(t){const{elementType:r,externalSlotProps:o,ownerState:n,skipResolvingSlotProps:i=!1,...a}=t,l=i?{}:Au(o,n),{props:s,internalRef:d}=function(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:o,externalForwardedProps:n,className:i}=e;if(!t){const e=Cu(r?.className,i,n?.className,o?.className),t={...r?.style,...n?.style,...o?.style},a={...r,...n,...o};return e.length>0&&(a.className=e),Object.keys(t).length>0&&(a.style=t),{props:a,internalRef:void 0}}const a=Tu({...n,...o}),l=Iu(o),s=Iu(n),d=t(a),c=Cu(d?.className,r?.className,i,n?.className,o?.className),u={...d?.style,...r?.style,...n?.style,...o?.style},p={...d,...r,...s,...l};return c.length>0&&(p.className=c),Object.keys(u).length>0&&(p.style=u),{props:p,internalRef:d.ref}}({...a,externalSlotProps:l}),c=function(e,t,r){return void 0===e||"string"==typeof e?t:{...t,ownerState:{...t.ownerState,...r}}}(r,{...s,ref:function(...t){const r=e.useRef(void 0),o=e.useCallback(e=>{const r=t.map(t=>{if(null==t)return null;if("function"==typeof t){const r=t,o=r(e);return"function"==typeof o?o:()=>{r(null)}}return t.current=e,()=>{t.current=null}});return()=>{r.forEach(e=>e?.())}},t);return e.useMemo(()=>t.every(e=>null==e)?null:e=>{r.current&&(r.current(),r.current=void 0),null!=e&&(r.current=o(e))},t)}(d,l?.ref,t.additionalProps?.ref)},n);return c}const Ru=new Set;function Eu(e,t="warning"){if("production"===process.env.NODE_ENV)return;const r=Array.isArray(e)?e.join("\n"):e;Ru.has(r)||(Ru.add(r),"error"===t?console.error(r):console.warn(r))}function Pu(e){return rr}const Ou=e=>e,Lu=(()=>{let e=Ou;return{configure(t){e=t},generate:t=>e(t),reset(){e=Ou}}})(),Mu={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function Wu(e,t,r="Mui"){const o=Mu[t];return o?`${r}-${o}`:`${Lu.generate(e)}-${t}`}function Du(e,t,r="Mui"){const o={};return t.forEach(t=>{o[t]=Wu(e,t,r)}),o}function Fu(e){return Wu("MuiSimpleTreeView",e)}Du("MuiSimpleTreeView",["root","item","itemContent","itemGroupTransition","itemIconContainer","itemLabel","itemCheckbox"]);const Nu=Object.freeze([]),Hu=Object.freeze({}),Vu=e.createContext(null);"production"!==process.env.NODE_ENV&&(Vu.displayName="TreeViewContext");const Qu=()=>{const t=e.useContext(Vu);if(null==t)throw new Error(["MUI X: Could not find the Tree View context.","It looks like you rendered your component outside of a SimpleTreeView or RichTreeView parent component.","This can also happen if you are bundling multiple versions of the Tree View."].join("\n"));return t},ju=e.createContext({classes:{},slots:{},slotProps:{}});"production"!==process.env.NODE_ENV&&(ju.displayName="TreeViewStyleContext");const Gu=()=>e.useContext(ju);function Uu(t){const{store:r,apiRef:o,rootRef:n,classes:i=Hu,slots:a=Hu,slotProps:l=Hu,children:s}=t,d=(t=>{const{store:r,apiRef:o,rootRef:n}=t,i=yu(()=>r.buildPublicAPI()).current;!function(e,t){null!=t&&null==t.current&&(t.current=e)}(i,o);const a=e.useCallback(e=>{let t=null,o=null;const n=[],i={};r.itemPluginManager.listPlugins().forEach(r=>{const a=r({props:e,rootRef:t,contentRef:o});a?.rootRef&&(t=a.rootRef),a?.contentRef&&(o=a.contentRef),a?.propsEnhancers&&(n.push(a.propsEnhancers),Object.keys(a.propsEnhancers).forEach(e=>{i[e]=!0}))});const a=Object.fromEntries(Object.keys(i).map(e=>{return[e,(t=e,e=>{const r={};return n.forEach(o=>{const n=o[t];null!=n&&Object.assign(r,n(e))}),r})];var t}));return{contentRef:o,rootRef:t,propsEnhancers:a}},[r]),l=e.useCallback(({itemId:e,children:t,idAttribute:o})=>{let n=t;const i=r.itemPluginManager.listWrappers();for(let t=i.length-1;t>=0;t-=1)n=(0,i[t])({store:r,itemId:e,children:n,idAttribute:o});return n},[r]);return e.useMemo(()=>({runItemPlugins:a,wrapItem:l,publicAPI:i,store:r,rootRef:n}),[a,l,i,r,n])})({store:r,apiRef:o,rootRef:n}),c=e.useMemo(()=>({classes:i,slots:{collapseIcon:a.collapseIcon,expandIcon:a.expandIcon,endIcon:a.endIcon},slotProps:{collapseIcon:l.collapseIcon,expandIcon:l.expandIcon,endIcon:l.endIcon}}),[i,a.collapseIcon,a.expandIcon,a.endIcon,l.collapseIcon,l.expandIcon,l.endIcon]);return de(Vu.Provider,{value:d,children:de(ju.Provider,{value:c,children:s})})}function Xu(e,t){if(null==e)return{};var r={};for(var o in e)if({}.hasOwnProperty.call(e,o)){if(-1!==t.indexOf(o))continue;r[o]=e[o]}return r}const Ku=["apiRef","slots","slotProps","disabledItemsFocusable","onItemClick","itemChildrenIndentation","id","expandedItems","defaultExpandedItems","onExpandedItemsChange","onItemExpansionToggle","expansionTrigger","disableSelection","selectedItems","defaultSelectedItems","multiSelect","checkboxSelection","selectionPropagation","onSelectedItemsChange","onItemSelectionToggle","onItemFocus"];var qu=(e,t,r)=>{if(1===t.length&&t[0]===r){let t=!1;try{const r={};e(r)===r&&(t=!0)}catch{}if(t){let e;try{throw new Error}catch(t){({stack:e}=t)}console.warn("The result function returned its own inputs without modification. e.g\n`createSelector([state => state.todos], todos => todos)`\nThis could lead to inefficient memoization and unnecessary re-renders.\nEnsure transformation logic is in the result function, and extraction logic is in the input selectors.",{stack:e})}}},Ju=(e,t,r)=>{const{memoize:o,memoizeOptions:n}=t,{inputSelectorResults:i,inputSelectorResultsCopy:a}=e,l=o(()=>({}),...n);if(!(l.apply(null,i)===l.apply(null,a))){let e;try{throw new Error}catch(t){({stack:e}=t)}console.warn("An input selector returned a different result when passed same arguments.\nThis means your output selector will likely run more frequently than intended.\nAvoid returning a new reference inside your input selector, e.g.\n`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)`",{arguments:r,firstInputs:i,secondInputs:a,stack:e})}},Yu={inputStabilityCheck:"once",identityFunctionCheck:"once"},$u=Symbol("NOT_FOUND");var Zu=e=>Array.isArray(e)?e:[e];function _u(e){const t=Array.isArray(e[0])?e[0]:e;return function(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(e=>"function"==typeof e)){const r=e.map(e=>"function"==typeof e?`function ${e.name||"unnamed"}()`:typeof e).join(", ");throw new TypeError(`${t}[${r}]`)}}(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function ep(e,t){const r=[],{length:o}=e;for(let n=0;n<o;n++)r.push(e[n].apply(null,t));return r}var tp=(e,t)=>e===t;var rp="undefined"!=typeof WeakRef?WeakRef:class{constructor(e){this.value=e}deref(){return this.value}};function op(){return{s:0,v:void 0,o:null,p:null}}function np(e,t={}){let r={s:0,v:void 0,o:null,p:null};const{resultEqualityCheck:o}=t;let n,i=0;function a(){let t=r;const{length:a}=arguments;for(let e=0,r=a;e<r;e++){const r=arguments[e];if("function"==typeof r||"object"==typeof r&&null!==r){let e=t.o;null===e&&(t.o=e=new WeakMap);const o=e.get(r);void 0===o?(t=op(),e.set(r,t)):t=o}else{let e=t.p;null===e&&(t.p=e=new Map);const o=e.get(r);void 0===o?(t=op(),e.set(r,t)):t=o}}const l=t;let s;if(1===t.s)s=t.v;else if(s=e.apply(null,arguments),i++,o){const e=n?.deref?.()??n;null!=e&&o(e,s)&&(s=e,0!==i&&i--);n="object"==typeof s&&null!==s||"function"==typeof s?new rp(s):s}return l.s=1,l.v=s,s}return a.clearCache=()=>{r={s:0,v:void 0,o:null,p:null},a.resetResultsCount()},a.resultsCount=()=>i,a.resetResultsCount=()=>{i=0},a}function ip(e,...t){const r="function"==typeof e?{memoize:e,memoizeOptions:t}:e,o=(...e)=>{let t,o=0,n=0,i={},a=e.pop();"object"==typeof a&&(i=a,a=e.pop()),function(e,t="expected a function, instead received "+typeof e){if("function"!=typeof e)throw new TypeError(t)}(a,`createSelector expects an output function after the inputs, but received: [${typeof a}]`);const l={...r,...i},{memoize:s,memoizeOptions:d=[],argsMemoize:c=np,argsMemoizeOptions:u=[],devModeChecks:p={}}=l,h=Zu(d),m=Zu(u),f=_u(e),g=s(function(){return o++,a.apply(null,arguments)},...h);let x=!0;const b=c(function(){n++;const e=ep(f,arguments);if(t=g.apply(null,e),"production"!==process.env.NODE_ENV){const{identityFunctionCheck:r,inputStabilityCheck:o}=((e,t)=>{const{identityFunctionCheck:r,inputStabilityCheck:o}={...Yu,...t};return{identityFunctionCheck:{shouldRun:"always"===r||"once"===r&&e,run:qu},inputStabilityCheck:{shouldRun:"always"===o||"once"===o&&e,run:Ju}}})(x,p);if(r.shouldRun&&r.run(a,e,t),o.shouldRun){const t=ep(f,arguments);o.run({inputSelectorResults:e,inputSelectorResultsCopy:t},{memoize:s,memoizeOptions:h},arguments)}x&&(x=!1)}return t},...m);return Object.assign(b,{resultFunc:a,memoizedResultFunc:g,dependencies:f,dependencyRecomputations:()=>n,resetDependencyRecomputations:()=>{n=0},lastResult:()=>t,recomputations:()=>o,resetRecomputations:()=>{o=0},memoize:s,argsMemoize:c})};return Object.assign(o,{withTypes:()=>o}),o}var ap=ip(np),lp=Object.assign((e,t=ap)=>{!function(e,t="expected an object, instead received "+typeof e){if("object"!=typeof e)throw new TypeError(t)}(e,"createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);const r=Object.keys(e),o=t(r.map(t=>e[t]),(...e)=>e.reduce((e,t,o)=>(e[r[o]]=t,e),{}));return o},{withTypes:()=>lp});const sp=ip({memoize:function(e,t){const r="object"==typeof t?t:{equalityCheck:t},{equalityCheck:o=tp,maxSize:n=1,resultEqualityCheck:i}=r,a=function(e){return function(t,r){if(null===t||null===r||t.length!==r.length)return!1;const{length:o}=t;for(let n=0;n<o;n++)if(!e(t[n],r[n]))return!1;return!0}}(o);let l=0;const s=n<=1?function(e){let t;return{get:r=>t&&e(t.key,r)?t.value:$u,put(e,r){t={key:e,value:r}},getEntries:()=>t?[t]:[],clear(){t=void 0}}}(a):function(e,t){let r=[];function o(e){const o=r.findIndex(r=>t(e,r.key));if(o>-1){const e=r[o];return o>0&&(r.splice(o,1),r.unshift(e)),e.value}return $u}return{get:o,put:function(t,n){o(t)===$u&&(r.unshift({key:t,value:n}),r.length>e&&r.pop())},getEntries:function(){return r},clear:function(){r=[]}}}(n,a);function d(){let t=s.get(arguments);if(t===$u){if(t=e.apply(null,arguments),l++,i){const e=s.getEntries().find(e=>i(e.value,t));e&&(t=e.value,0!==l&&l--)}s.put(arguments,t)}return t}return d.clearCache=()=>{s.clear(),d.resetResultsCount()},d.resultsCount=()=>l,d.resetResultsCount=()=>{l=0},d},memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),dp=(e,t,r,o,n,i,a,l,...s)=>{if(s.length>0)throw new Error("Unsupported number of selectors");let d;if(e&&t&&r&&o&&n&&i&&a&&l)d=(s,d,c,u)=>{const p=e(s,d,c,u),h=t(s,d,c,u),m=r(s,d,c,u),f=o(s,d,c,u),g=n(s,d,c,u),x=i(s,d,c,u),b=a(s,d,c,u);return l(p,h,m,f,g,x,b,d,c,u)};else if(e&&t&&r&&o&&n&&i&&a)d=(l,s,d,c)=>{const u=e(l,s,d,c),p=t(l,s,d,c),h=r(l,s,d,c),m=o(l,s,d,c),f=n(l,s,d,c),g=i(l,s,d,c);return a(u,p,h,m,f,g,s,d,c)};else if(e&&t&&r&&o&&n&&i)d=(a,l,s,d)=>{const c=e(a,l,s,d),u=t(a,l,s,d),p=r(a,l,s,d),h=o(a,l,s,d),m=n(a,l,s,d);return i(c,u,p,h,m,l,s,d)};else if(e&&t&&r&&o&&n)d=(i,a,l,s)=>{const d=e(i,a,l,s),c=t(i,a,l,s),u=r(i,a,l,s),p=o(i,a,l,s);return n(d,c,u,p,a,l,s)};else if(e&&t&&r&&o)d=(n,i,a,l)=>{const s=e(n,i,a,l),d=t(n,i,a,l),c=r(n,i,a,l);return o(s,d,c,i,a,l)};else if(e&&t&&r)d=(o,n,i,a)=>{const l=e(o,n,i,a),s=t(o,n,i,a);return r(l,s,n,i,a)};else if(e&&t)d=(r,o,n,i)=>{const a=e(r,o,n,i);return t(a,o,n,i)};else{if(!e)throw new Error("Missing arguments");d=e}return d},cp=(...e)=>{const t=new WeakMap;let r=1;const o=e[e.length-1],n=e.length-1||1,i=Math.max(o.length-n,0);if(i>3)throw new Error("Unsupported number of arguments");return(n,a,l,s)=>{let d=n.__cacheKey__;d||(d={id:r},n.__cacheKey__=d,r+=1);let c=t.get(d);if(!c){const r=1===e.length?[e=>e,o]:e;let n=e;const a=[void 0,void 0,void 0];switch(i){case 0:break;case 1:n=[...r.slice(0,-1),()=>a[0],o];break;case 2:n=[...r.slice(0,-1),()=>a[0],()=>a[1],o];break;case 3:n=[...r.slice(0,-1),()=>a[0],()=>a[1],()=>a[2],o];break;default:throw new Error("Unsupported number of arguments")}c=sp(...n),c.selectorArgs=a,t.set(d,c)}switch(i){case 3:c.selectorArgs[2]=s;case 2:c.selectorArgs[1]=l;case 1:c.selectorArgs[0]=a}switch(i){case 0:return c(n);case 1:return c(n,a);case 2:return c(n,a,l);case 3:return c(n,a,l,s);default:throw new Error("unreachable")}}};var up,pp={exports:{}},hp={};var mp,fp={};
14
+ */function Mi(){if(ki)return Si;ki=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;return Si=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(e){o[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}()?Object.assign:function(o,n){for(var i,a,l=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(o),s=1;s<arguments.length;s++){for(var d in i=Object(arguments[s]))t.call(i,d)&&(l[d]=i[d]);if(e){a=e(i);for(var c=0;c<a.length;c++)r.call(i,a[c])&&(l[a[c]]=i[a[c]])}}return l},Si}function Wi(){if(wi)return Bi;wi=1;return Bi="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function Di(){return Ti?Ci:(Ti=1,Ci=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var Fi=Li();gi.exports=function(){if(Ri)return zi;Ri=1;var e=Li(),t=Mi(),r=Wi(),o=Di(),n=function(){if(Ai)return Ii;Ai=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=Wi(),r={},o=Di();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function n(n,i,a,l,s){if("production"!==process.env.NODE_ENV)for(var d in n)if(o(n,d)){var c;try{if("function"!=typeof n[d]){var u=Error((l||"React class")+": "+a+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof n[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw u.name="Invariant Violation",u}c=n[d](i,d,l,a,null,t)}catch(e){c=e}if(!c||c instanceof Error||e((l||"React class")+": type specification of "+a+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof c+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),c instanceof Error&&!(c.message in r)){r[c.message]=!0;var p=s?s():"";e("Failed "+a+" type: "+c.message+(null!=p?p:""))}}}return n.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(r={})},Ii=n}(),i=function(){};function a(){return null}return"production"!==process.env.NODE_ENV&&(i=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),zi=function(l,s){var d="function"==typeof Symbol&&Symbol.iterator,c="<<anonymous>>",u={array:f("array"),bigint:f("bigint"),bool:f("boolean"),func:f("function"),number:f("number"),object:f("object"),string:f("string"),symbol:f("symbol"),any:m(a),arrayOf:function(e){return m(function(t,o,n,i,a){if("function"!=typeof e)return new h("Property `"+a+"` of component `"+n+"` has invalid PropType notation inside arrayOf.");var l=t[o];if(!Array.isArray(l))return new h("Invalid "+i+" `"+a+"` of type `"+b(l)+"` supplied to `"+n+"`, expected an array.");for(var s=0;s<l.length;s++){var d=e(l,s,n,i,a+"["+s+"]",r);if(d instanceof Error)return d}return null})},element:m(function(e,t,r,o,n){var i=e[t];return l(i)?null:new h("Invalid "+o+" `"+n+"` of type `"+b(i)+"` supplied to `"+r+"`, expected a single ReactElement.")}),elementType:m(function(t,r,o,n,i){var a=t[r];return e.isValidElementType(a)?null:new h("Invalid "+n+" `"+i+"` of type `"+b(a)+"` supplied to `"+o+"`, expected a single ReactElement type.")}),instanceOf:function(e){return m(function(t,r,o,n,i){if(!(t[r]instanceof e)){var a=e.name||c;return new h("Invalid "+n+" `"+i+"` of type `"+((l=t[r]).constructor&&l.constructor.name?l.constructor.name:c)+"` supplied to `"+o+"`, expected instance of `"+a+"`.")}var l;return null})},node:m(function(e,t,r,o,n){return x(e[t])?null:new h("Invalid "+o+" `"+n+"` supplied to `"+r+"`, expected a ReactNode.")}),objectOf:function(e){return m(function(t,n,i,a,l){if("function"!=typeof e)return new h("Property `"+l+"` of component `"+i+"` has invalid PropType notation inside objectOf.");var s=t[n],d=b(s);if("object"!==d)return new h("Invalid "+a+" `"+l+"` of type `"+d+"` supplied to `"+i+"`, expected an object.");for(var c in s)if(o(s,c)){var u=e(s,c,i,a,l+"."+c,r);if(u instanceof Error)return u}return null})},oneOf:function(e){return Array.isArray(e)?m(function(t,r,o,n,i){for(var a=t[r],l=0;l<e.length;l++)if(p(a,e[l]))return null;var s=JSON.stringify(e,function(e,t){return"symbol"===v(t)?String(t):t});return new h("Invalid "+n+" `"+i+"` of value `"+String(a)+"` supplied to `"+o+"`, expected one of "+s+".")}):("production"!==process.env.NODE_ENV&&i(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),a)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&i("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var t=0;t<e.length;t++){var n=e[t];if("function"!=typeof n)return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+y(n)+" at index "+t+"."),a}return m(function(t,n,i,a,l){for(var s=[],d=0;d<e.length;d++){var c=(0,e[d])(t,n,i,a,l,r);if(null==c)return null;c.data&&o(c.data,"expectedType")&&s.push(c.data.expectedType)}return new h("Invalid "+a+" `"+l+"` supplied to `"+i+"`"+(s.length>0?", expected one of type ["+s.join(", ")+"]":"")+".")})},shape:function(e){return m(function(t,o,n,i,a){var l=t[o],s=b(l);if("object"!==s)return new h("Invalid "+i+" `"+a+"` of type `"+s+"` supplied to `"+n+"`, expected `object`.");for(var d in e){var c=e[d];if("function"!=typeof c)return g(n,i,a,d,v(c));var u=c(l,d,n,i,a+"."+d,r);if(u)return u}return null})},exact:function(e){return m(function(n,i,a,l,s){var d=n[i],c=b(d);if("object"!==c)return new h("Invalid "+l+" `"+s+"` of type `"+c+"` supplied to `"+a+"`, expected `object`.");var u=t({},n[i],e);for(var p in u){var m=e[p];if(o(e,p)&&"function"!=typeof m)return g(a,l,s,p,v(m));if(!m)return new h("Invalid "+l+" `"+s+"` key `"+p+"` supplied to `"+a+"`.\nBad object: "+JSON.stringify(n[i],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var f=m(d,p,a,l,s+"."+p,r);if(f)return f}return null})}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function h(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function m(e){if("production"!==process.env.NODE_ENV)var t={},o=0;function n(n,a,l,d,u,p,m){if(d=d||c,p=p||l,m!==r){if(s){var f=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw f.name="Invariant Violation",f}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var g=d+":"+l;!t[g]&&o<3&&(i("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+d+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),t[g]=!0,o++)}}return null==a[l]?n?null===a[l]?new h("The "+u+" `"+p+"` is marked as required in `"+d+"`, but its value is `null`."):new h("The "+u+" `"+p+"` is marked as required in `"+d+"`, but its value is `undefined`."):null:e(a,l,d,u,p)}var a=n.bind(null,!1);return a.isRequired=n.bind(null,!0),a}function f(e){return m(function(t,r,o,n,i,a){var l=t[r];return b(l)!==e?new h("Invalid "+n+" `"+i+"` of type `"+v(l)+"` supplied to `"+o+"`, expected `"+e+"`.",{expectedType:e}):null})}function g(e,t,r,o,n){return new h((e||"React class")+": "+t+" type `"+r+"."+o+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+n+"`.")}function x(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(x);if(null===e||l(e))return!0;var t=function(e){var t=e&&(d&&e[d]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var r,o=t.call(e);if(t!==e.entries){for(;!(r=o.next()).done;)if(!x(r.value))return!1}else for(;!(r=o.next()).done;){var n=r.value;if(n&&!x(n[1]))return!1}return!0;default:return!1}}function b(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function v(e){if(null==e)return""+e;var t=b(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function y(e){var t=v(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return h.prototype=Error.prototype,u.checkPropTypes=n,u.resetWarningCache=n.resetWarningCache,u.PropTypes=u,u},zi}()(Fi.isElement,!0)}else gi.exports=function(){if(Pi)return Ei;Pi=1;var e=Wi();function t(){}function r(){}return r.resetWarningCache=t,Ei=function(){function o(t,r,o,n,i,a){if(a!==e){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function n(){return o}o.isRequired=o;var i={array:o,bigint:o,bool:o,func:o,number:o,object:o,string:o,symbol:o,any:o,arrayOf:n,element:o,elementType:o,instanceOf:n,node:o,objectOf:n,oneOf:n,oneOfType:n,shape:n,exact:n,checkPropTypes:r,resetWarningCache:t};return i.PropTypes=i,i},Ei}()();var Ni=mi(gi.exports);function Hi({code:e,label:t="Copy code"}){const[o,n]=r(!1);return de(w,{title:o?"Copied!":t,children:de(C,{size:"small",onClick:async()=>{try{await navigator.clipboard.writeText(e),n(!0),setTimeout(()=>n(!1),2e3)}catch(e){console.error("Copy failed:",e)}},"aria-label":o?"Copied":t,sx:{color:o?"var(--Icons-Success, var(--Text))":"var(--Quiet)","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(o?he:pe,{fontSize:"small"})})})}Hi.propTypes={code:Ni.string.isRequired,label:Ni.string};function Vi({code:e="",language:t="JSX",showCopy:r=!0,showHeader:o=!0,maxHeight:n,wrap:i=!1,sx:a={},...l}){return ce(h,{"data-theme":"Neutral","data-surface":"Surface-Dimmest",sx:{backgroundColor:"var(--Background)",borderRadius:"min(var(--Card-Radius, var(--Style-Border-Radius)), 12px)",overflow:"hidden",...a},...l,children:[o&&(t||r)&&ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:1,px:2,py:1,borderBottom:"1px solid var(--Border)",minHeight:40},children:[de(bo,{color:"quiet",children:t}),r&&e?de(Hi,{code:e}):null]}),de(h,{sx:{p:2,overflow:"auto",maxHeight:n},children:de(h,{component:"pre",sx:{margin:0,fontFamily:"inherit"},children:de(h,{component:"code",sx:{fontFamily:"ui-monospace, SFMono-Regular, Menlo, Consolas, monospace",fontSize:"13px",lineHeight:1.6,color:"var(--Text)",whiteSpace:i?"pre-wrap":"pre",wordBreak:i?"break-word":"normal",display:"block"},children:e})})})]})}function Qi(e){if(!e)return null;const t=e.trim();if(/^#[0-9a-f]{3}$/i.test(t))return{r:parseInt(t[1]+t[1],16),g:parseInt(t[2]+t[2],16),b:parseInt(t[3]+t[3],16),a:1};if(/^#[0-9a-f]{6}$/i.test(t))return{r:parseInt(t.substring(1,3),16),g:parseInt(t.substring(3,5),16),b:parseInt(t.substring(5,7),16),a:1};if(/^#[0-9a-f]{8}$/i.test(t))return{r:parseInt(t.substring(1,3),16),g:parseInt(t.substring(3,5),16),b:parseInt(t.substring(5,7),16),a:parseInt(t.substring(7,9),16)/255};const r=t.match(/rgba?\(\s*([\d.]+)[,\s]+([\d.]+)[,\s]+([\d.]+)(?:[,\s/]+([\d.]+%?))?\s*\)/);if(r){let e=1;return void 0!==r[4]&&(e=r[4].endsWith("%")?parseFloat(r[4])/100:parseFloat(r[4])),{r:Math.round(parseFloat(r[1])),g:Math.round(parseFloat(r[2])),b:Math.round(parseFloat(r[3])),a:e}}return null}function ji(e,t){if(!e||!t)return e||t;if(e.a>=1)return e;const r=e.a;return{r:Math.round(e.r*r+t.r*(1-r)),g:Math.round(e.g*r+t.g*(1-r)),b:Math.round(e.b*r+t.b*(1-r)),a:1}}function Gi(e){const t=e=>e<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4);return.2126*t(e.r/255)+.7152*t(e.g/255)+.0722*t(e.b/255)}function Ui(e,t,r){const o=Qi(e),n=Qi(t),i=Qi(r);if(!o||!n)return null;const a=i?ji(n,i):n.a<1?null:n;if(!a)return null;const l=ji(o,a);if(!l)return null;const s=Gi(l),d=Gi(a);return((Math.max(s,d)+.05)/(Math.min(s,d)+.05)).toFixed(2)}function Xi(e){return"undefined"==typeof window?null:getComputedStyle(document.documentElement).getPropertyValue(e).trim()}Vi.propTypes={code:Ni.string,language:Ni.string,showCopy:Ni.bool,showHeader:Ni.bool,maxHeight:Ni.oneOfType([Ni.number,Ni.string]),wrap:Ni.bool,sx:Ni.object};const Ki={"display-large":"Display Large","display-medium":"Display Medium","display-small":"Display Small",h1:"H1",h2:"H2",h3:"H3",h4:"H4",h5:"H5",h6:"H6","subtitle-small":"Subtitle Small",subtitle:"Subtitle Medium","subtitle-large":"Subtitle Large","body-small":"Body Small","body-small-semibold":"Body Small Semibold",body:"Body Medium","body-semibold":"Body Medium Semibold","body-large":"Body Large","body-large-semibold":"Body Large Semibold",label:"Label","label-small":"Label Small","label-large":"Label Large",caption:"Caption","caption-bold":"Caption Bold",legal:"Legal","legal-semibold":"Legal Semibold",eyebrow:"Eyebrow Medium","eyebrow-small":"Eyebrow Small","eyebrow-large":"Eyebrow Large",button:"Button Standard","button-small":"Button Small","button-extra-small":"Button Extra Small","number-large":"Number Large","number-medium":"Number Medium","number-small":"Number Small"};function qi(){const e=({color:e})=>ce(h,{sx:{textAlign:"center"},children:[de(h,{sx:{width:"80px",height:"80px",backgroundColor:`var(${e.var})`,borderRadius:"8px",border:"1px solid var(--Border)",mb:1,mx:"auto"}}),de(T,{variant:"body2",sx:{fontWeight:600,fontSize:"12px",color:"var(--Text)",mb:.5,wordBreak:"break-word"},children:e.name}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block",fontSize:"10px",fontFamily:"monospace",wordBreak:"break-all"},children:e.var})]});return ce(B,{spacing:6,children:[ce(h,{children:[de(T,{variant:"h5",sx:{mb:3,fontWeight:700},children:"Brand Colors (Static)"}),de(B,{direction:"row",spacing:3,sx:{justifyContent:"center",flexWrap:"wrap",gap:3},children:[{name:"Primary",var:"--Primary-Color-11"},{name:"Secondary",var:"--Secondary-Color-11"},{name:"Tertiary",var:"--Tertiary-Color-11"}].map(t=>de(e,{color:t},t.var))})]}),ce(h,{children:[de(T,{variant:"h5",sx:{mb:3,fontWeight:700},children:"Background Colors (Dynamic)"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Update based on selected Background variant and Mode"}),de(I,{container:!0,spacing:2,sx:{justifyContent:"center"},children:[{name:"Default Background",cssVar:"var(--Theme-Default-Surfaces-Surface)"},{name:"Primary Background",cssVar:"var(--Theme-Primary-Surfaces-Surface)"},{name:"Secondary Background",cssVar:"var(--Theme-Secondary-Surfaces-Surface)"},{name:"Tertiary Background",cssVar:"var(--Theme-Tertiary-Surfaces-Surface)"},{name:"Neutral Background",cssVar:"var(--Theme-Neutral-Surfaces-Surface)"},{name:"Neutral-Variant Background",cssVar:"var(--Theme-Neutral-Variant-Surfaces-Surface)"}].map(e=>de(I,{item:!0,sx:{display:"flex",justifyContent:"center"},children:ce(h,{sx:{textAlign:"center"},children:[de(h,{sx:{minWidth:"max(var(--Button-Height), var(--Min-Button-Width))",minHeight:"var(--Button-Height)",backgroundColor:e.cssVar,borderRadius:"var(--Style-Border-Radius)",border:"2px solid var(--Border)",mb:1}}),de(T,{variant:"body2",sx:{fontWeight:600,fontSize:"12px",color:"var(--Text)",wordBreak:"break-word"},children:e.name})]})},e.name))})]}),ce(h,{children:[de(T,{variant:"h5",sx:{mb:3,fontWeight:700},children:"Dynamic Colors (Update with Mode, Background & Surface)"}),de(A,{severity:"info",sx:{backgroundColor:"var(--Container-Low)",mb:3,border:"1px solid var(--Border)"},children:ce(T,{variant:"body2",children:["Most colors update automatically based on the current"," ",de("strong",{children:"Mode"})," (Light/Dark), ",de("strong",{children:"Background"})," ","variant, and ",de("strong",{children:"Surface"})," theme. Only Primary, Secondary, and Tertiary colors are fixed brand colors."]})}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"These colors automatically adapt based on:"}),ce(B,{spacing:1,sx:{mb:4},children:[ce(h,{sx:{display:"flex",gap:2},children:[de(T,{variant:"body2",sx:{fontWeight:600,minWidth:80},children:"Mode:"}),de(T,{variant:"body2",children:"Light or Dark theme"})]}),ce(h,{sx:{display:"flex",gap:2},children:[de(T,{variant:"body2",sx:{fontWeight:600,minWidth:80},children:"Background:"}),de(T,{variant:"body2",children:"Default, Primary, Secondary, Tertiary, Neutral, or Neutral-Variant"})]}),ce(h,{sx:{display:"flex",gap:2},children:[de(T,{variant:"body2",sx:{fontWeight:600,minWidth:80},children:"Surface:"}),de(T,{variant:"body2",children:"Theme surface layer selection"})]})]}),de(B,{spacing:4,children:[{name:"Layout & Surfaces",colors:[{name:"Background",var:"--Background"},{name:"Border",var:"--Border"},{name:"Border-Variant",var:"--Border-Variant"}]},{name:"Text & Links",colors:[{name:"Header",var:"--Header"},{name:"Text",var:"--Text"},{name:"Text-Quiet",var:"--Text-Quiet"},{name:"Hotlink",var:"--Hotlink"},{name:"Hotlink-Visited",var:"--Hotlink-Visited"}]},{name:"Buttons - Primary",colors:[{name:"Button BG",var:"--Button-Primary-Button"},{name:"Button Text",var:"--Button-Primary-Text"},{name:"Button Hover",var:"--Button-Primary-Hover"},{name:"Button Active",var:"--Button-Primary-Pressed"},{name:"Focus-Visible",var:"--Focus-Visible"}]},{name:"Buttons - Secondary",colors:[{name:"Button BG",var:"--Button-Secondary-Button"},{name:"Button Text",var:"--Button-Secondary-Text"},{name:"Button Hover",var:"--Button-Secondary-Hover"},{name:"Button Active",var:"--Button-Secondary-Pressed"},{name:"Focus-Visible",var:"--Focus-Visible"}]},{name:"Buttons - State",colors:[{name:"Info Button",var:"--Button-Info-Button"},{name:"Success Button",var:"--Button-Success-Button"},{name:"Warning Button",var:"--Button-Warning-Button"},{name:"Error Button",var:"--Button-Error-Button"}]},{name:"Icons",colors:[{name:"Default",var:"--Icons-Default"},{name:"Primary",var:"--Icons-Primary"},{name:"Secondary",var:"--Icons-Secondary"},{name:"Tertiary",var:"--Icons-Tertiary"},{name:"Neutral",var:"--Icons-Neutral"},{name:"Info",var:"--Icons-Info"},{name:"Success",var:"--Icons-Success"},{name:"Warning",var:"--Icons-Warning"},{name:"Error",var:"--Icons-Error"}]},{name:"Chips & Badges",colors:[{name:"Primary BG",var:"--Tags-Primary-BG"},{name:"Primary Text",var:"--Tags-Primary-Text"},{name:"Secondary BG",var:"--Tags-Secondary-BG"},{name:"Secondary Text",var:"--Tags-Secondary-Text"},{name:"Tertiary BG",var:"--Tags-Tertiary-BG"},{name:"Tertiary Text",var:"--Tags-Tertiary-Text"},{name:"Neutral BG",var:"--Tags-Neutral-BG"},{name:"Neutral Text",var:"--Tags-Neutral-Text"},{name:"Info BG",var:"--Tags-Info-BG"},{name:"Info Text",var:"--Tags-Info-Text"},{name:"Success BG",var:"--Tags-Success-BG"},{name:"Success Text",var:"--Tags-Success-Text"},{name:"Warning BG",var:"--Tags-Warning-BG"},{name:"Warning Text",var:"--Tags-Warning-Text"},{name:"Error BG",var:"--Tags-Error-BG"},{name:"Error Text",var:"--Tags-Error-Text"}]}].map(t=>ce(h,{children:[de(T,{variant:"h6",sx:{mb:2,fontWeight:600},children:t.name}),de(I,{container:!0,spacing:2,sx:{justifyContent:"center"},children:t.colors.map(t=>de(I,{item:!0,sx:{display:"flex",justifyContent:"center"},children:de(e,{color:t})},t.var))})]},t.name))})]}),ce(h,{sx:{pt:4,borderTop:"1px solid var(--Border)"},children:[de(T,{variant:"h5",sx:{mb:2,fontWeight:700},children:"How to Use"}),ce(B,{spacing:2,children:[ce(h,{children:[de(T,{variant:"h6",sx:{fontWeight:600,mb:1},children:"Static Colors"}),ce(T,{variant:"body2",sx:{color:"var(--Text-Secondary)"},children:["Use brand colors (",de("code",{style:{backgroundColor:"var(--Container)",padding:"2px 4px",borderRadius:"4px"},children:"--Primary-Color-11"}),","," ",de("code",{style:{backgroundColor:"var(--Container)",padding:"2px 4px",borderRadius:"4px"},children:"--Secondary-Color-11"}),","," ",de("code",{style:{backgroundColor:"var(--Container)",padding:"2px 4px",borderRadius:"4px"},children:"--Tertiary-Color-11"}),") for brand elements that should never change."]})]}),ce(h,{children:[de(T,{variant:"h6",sx:{fontWeight:600,mb:1},children:"Dynamic Colors"}),de(T,{variant:"body2",sx:{color:"var(--Text-Secondary)"},children:"Use dynamic color variables for all UI elements. They will automatically update when users change Mode, Background, or Surface settings."})]}),ce(h,{children:[de(T,{variant:"h6",sx:{fontWeight:600,mb:1},children:"Example Usage"}),de(h,{component:"pre",sx:{backgroundColor:"var(--Container)",p:2,borderRadius:"8px",overflow:"auto",fontSize:"12px",border:"1px solid var(--Border)",color:"var(--Text)"},children:"/* Dynamic - updates with theme changes */\ncolor: var(--Text);\nbackgroundColor: var(--Background);\nborderColor: var(--Border);\n\n/* Static - brand colors stay the same */\naccentColor: var(--Primary-Color-11);"})]})]})]})]})}function Ji(){const e=({name:e,varName:t,baseValue:r})=>de(h,{sx:{mb:2},children:ce(h,{sx:{display:"flex",alignItems:"center",gap:2,mb:1},children:[de(h,{"aria-hidden":"true",sx:{width:`var(${t})`,minWidth:20,height:24,backgroundColor:"var(--Buttons-Primary-Button)",borderRadius:.5,border:"1px solid var(--Border)"}}),ce(B,{spacing:.5,children:[de(T,{variant:"subtitle2",sx:{fontWeight:600},children:e}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:t}),ce(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:["Base: ",r," (with cognitive multiplier)"]})]})]})}),t=({name:e,varName:t,value:r})=>ce(h,{sx:{mb:2},children:[de(h,{"aria-hidden":"true",sx:{width:100,height:r,backgroundColor:"var(--Buttons-Primary-Button)",borderRadius:1,border:"1px solid var(--Border)",mb:1}}),de(T,{variant:"subtitle2",sx:{fontWeight:600},children:e}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block"},children:t}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:r})]});return ce(B,{spacing:3,sx:{p:2},children:[ce("section",{children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Spacing Scale"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Spacing values are multiplied by the cognitive multiplier for accessibility. Each spacing value includes a visual reference and text label for clarity."}),de(B,{spacing:1,children:[{name:"Quarter",var:"--Spacing-Quarter",baseValue:"2px"},{name:"Half",var:"--Spacing-Half",baseValue:"4px"},{name:"1-and-Half",var:"--Spacing-1-and-Half",baseValue:"12px"},{name:"1",var:"--Spacing-1",baseValue:"8px"},{name:"2",var:"--Spacing-2",baseValue:"16px"},{name:"3",var:"--Spacing-3",baseValue:"24px"},{name:"4",var:"--Spacing-4",baseValue:"32px"},{name:"5",var:"--Spacing-5",baseValue:"40px"},{name:"6",var:"--Spacing-6",baseValue:"48px"},{name:"7",var:"--Spacing-7",baseValue:"56px"},{name:"8",var:"--Spacing-8",baseValue:"64px"},{name:"9",var:"--Spacing-9",baseValue:"72px"},{name:"10",var:"--Spacing-10",baseValue:"80px"}].map(t=>de(e,{name:t.name,varName:t.var,baseValue:t.baseValue},t.var))})]}),ce("section",{children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Sizing Scale"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Fixed sizing values for components and layouts. Each size is labeled with its CSS variable and pixel value."}),de(I,{container:!0,spacing:3,children:[{name:"Quarter",var:"--Sizing-Quarter",value:"2px"},{name:"Half",var:"--Sizing-Half",value:"4px"},{name:"1-and-Half",var:"--Sizing-1-and-Half",value:"12px"},{name:"1",var:"--Sizing-1",value:"8px"},{name:"2",var:"--Sizing-2",value:"16px"},{name:"3",var:"--Sizing-3",value:"24px"},{name:"4",var:"--Sizing-4",value:"32px"},{name:"5",var:"--Sizing-5",value:"40px"},{name:"6",var:"--Sizing-6",value:"48px"},{name:"7",var:"--Sizing-7",value:"56px"},{name:"8",var:"--Sizing-8",value:"64px"},{name:"9",var:"--Sizing-9",value:"72px"},{name:"10",var:"--Sizing-10",value:"80px"},{name:"11",var:"--Sizing-11",value:"88px"},{name:"12",var:"--Sizing-12",value:"96px"},{name:"13",var:"--Sizing-13",value:"104px"},{name:"14",var:"--Sizing-14",value:"112px"},{name:"15",var:"--Sizing-15",value:"160px"},{name:"16",var:"--Sizing-16",value:"240px"},{name:"17",var:"--Sizing-17",value:"320px"},{name:"18",var:"--Sizing-18",value:"480px"}].map(e=>de(I,{item:!0,xs:12,sm:6,md:4,lg:3,children:de(t,{name:e.name,varName:e.var,value:e.value})},e.var))})]}),ce("section",{children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Negative Sizing"}),de(T,{variant:"body2",sx:{mb:3,color:"var(--Text-Secondary)"},children:"Negative values for margins and offsets. Use these to reduce or remove default spacing when needed."}),de(I,{container:!0,spacing:3,children:[{name:"Negative-Quarter",var:"--Sizing-Negative-Quarter",value:"-2px"},{name:"Negative-Half",var:"--Sizing-Negative-Half",value:"-4px"},{name:"Negative-1-and-Half",var:"--Sizing-Negative-1-and-Half",value:"-12px"},{name:"Negative-1",var:"--Sizing-Negative-1",value:"-8px"}].map(e=>de(I,{item:!0,xs:12,sm:6,md:4,lg:3,children:ce(h,{children:[de(T,{variant:"subtitle2",sx:{fontWeight:600},children:e.name}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block"},children:e.var}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:e.value})]})},e.var))})]}),ce("section",{style:{paddingTop:24,borderTop:"1px solid var(--Border)"},children:[de(T,{variant:"h5",component:"h2",sx:{mb:2,fontWeight:700},children:"Container Padding"}),ce(h,{sx:{p:"var(--Spacing-3)",backgroundColor:"var(--Container-Low)",border:"2px dashed var(--Buttons-Primary-Button)",borderRadius:1},children:[ce(T,{variant:"body2",children:["Default container padding: ",de("strong",{children:"var(--Spacing-3)"})," = 24px"]}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",display:"block",mt:1},children:"Use this variable for consistent padding around main content areas."})]})]}),ce("section",{style:{paddingTop:24,borderTop:"1px solid var(--Border)"},children:[de(T,{variant:"h5",component:"h2",sx:{mb:3,fontWeight:700},children:"Practical Examples"}),ce("article",{children:[de(T,{variant:"h6",component:"h3",sx:{mb:2,fontWeight:600},children:"Padding Examples"}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",mb:2,display:"block"},children:"Different padding values create different visual breathing room."}),de(I,{container:!0,spacing:2,sx:{mb:4},children:["var(--Spacing-1)","var(--Spacing-2)","var(--Spacing-3)","var(--Spacing-4)"].map(e=>de(I,{item:!0,xs:12,sm:6,children:ce(h,{sx:{p:e,backgroundColor:"var(--Container)",border:"1px solid var(--Border)",borderRadius:1},children:[ce(T,{variant:"subtitle2",children:["Padding: ",e]}),de(T,{variant:"caption",sx:{display:"block",mt:1,color:"var(--Text-Secondary)"},children:"Content with spacing applied"})]})},e))})]}),ce("article",{children:[de(T,{variant:"h6",component:"h3",sx:{mb:2,fontWeight:600},children:"Gap Examples"}),de(T,{variant:"caption",sx:{color:"var(--Text-Secondary)",mb:2,display:"block"},children:"Gap controls spacing between flex/grid children without adding extra elements."}),de(B,{spacing:3,children:["var(--Spacing-1)","var(--Spacing-2)","var(--Spacing-3)"].map(e=>ce(h,{children:[de(B,{direction:"row",spacing:e,sx:{mb:1},children:[1,2,3].map(e=>de(h,{"aria-hidden":"true",sx:{width:60,height:60,backgroundColor:"var(--Buttons-Primary-Button)",borderRadius:1,flexShrink:0}},e))}),ce(T,{variant:"caption",sx:{color:"var(--Text-Secondary)"},children:["Gap: ",e]})]},e))})]})]}),ce(h,{role:"note",sx:{p:2,backgroundColor:"var(--Container-Low)",borderRadius:1,borderLeft:"4px solid var(--Buttons-Primary-Button)",mt:3},children:[de(T,{variant:"subtitle2",sx:{fontWeight:600,mb:1},children:"✓ Accessibility Best Practices Used"}),ce("ul",{style:{margin:"0.5rem 0",paddingLeft:"1.5rem"},children:[de("li",{children:ce(T,{variant:"caption",children:[de("strong",{children:'aria-hidden="true"'})," on purely decorative visual elements"]})}),de("li",{children:de(T,{variant:"caption",children:"All spacing information conveyed through text labels and values"})}),de("li",{children:ce(T,{variant:"caption",children:["No empty decorative ",de("code",{children:"<div>"})," elements in DOM"]})}),de("li",{children:ce(T,{variant:"caption",children:["Semantic HTML: ",de("code",{children:"<section>"})," and ",de("code",{children:"<article>"})," for structure"]})}),de("li",{children:de(T,{variant:"caption",children:"CSS-based spacing (padding/margin) for actual layout, not decorative divs"})}),de("li",{children:de(T,{variant:"caption",children:"Full keyboard navigation and screen reader support"})})]})]})]})}Object.entries({Display:["display-large","display-medium","display-small"],Headings:["h1","h2","h3","h4","h5","h6"],Subtitle:["subtitle-small","subtitle","subtitle-large"],Body:["body-small","body-small-semibold","body","body-semibold","body-large","body-large-semibold"],Label:["label","label-small","label-large"],Caption:["caption","caption-bold"],Legal:["legal","legal-semibold"],Eyebrow:["eyebrow-small","eyebrow","eyebrow-large"],Button:["button-extra-small","button-small","button"],Number:["number-large","number-medium","number-small"]}).map(([e,t])=>({label:e,options:t.map(e=>({value:e,label:Ki[e]}))}));const Yi=["default","primary","secondary","tertiary","neutral","info","success","warning","error"],Zi=e=>e.charAt(0).toUpperCase()+e.slice(1);function $i(e){const t=Zi(e);return{type:"outline",color:t,trackOff:"var(--Background)",trackOffBorder:"var(--Border-Variant)",trackOn:"var(--Buttons-"+t+"-Button)",trackOnBorder:"var(--Buttons-"+t+"-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-"+t+"-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-"+t+"-Button)"}}function _i(e){const t=Zi(e);return{type:"light",color:t,trackOff:"var(--Border-Variant)",trackOffBorder:"transparent",trackOn:"var(--"+t+"-Color-11)",trackOnBorder:"var(--Buttons-"+t+"-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-"+t+"-Border)",iconOff:"var(--Border-Variant)",iconOn:"var(--"+t+"-Color-11)",dataTheme:t,dataSurface:"Surface-Brightest"}}const ea={small:{trackW:28,trackH:16,dotRadius:"var(--Sizing-2, 16px)",icon:8},medium:{trackW:40,trackH:24,dotRadius:"var(--Sizing-2-and-Half, 20px)",icon:16},large:{trackW:56,trackH:32,dotRadius:"var(--Sizing-2-and-Half, 20px)",icon:16}};function ta({variant:e="default",size:t="medium",checked:r,defaultChecked:o,onChange:n,disabled:i=!1,label:a,labelPlacement:l="end",name:s,value:d,icon:c,iconOn:u,iconOff:p,className:h="",sx:m={},"aria-label":f,"aria-labelledby":g,...x}){const b=function(){const e={};return Yi.forEach(t=>{e[t+"-outline"]=$i(t),e[t+"-light"]=_i(t)}),e.default={type:"themed",trackOff:"var(--Background)",trackOffBorder:"var(--Quiet)",trackOn:"var(--Buttons-Default-Button)",trackOnBorder:"var(--Buttons-Default-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-Default-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-Default-Button)"},e["default-outline"]={type:"themed",trackOff:"var(--Background)",trackOffBorder:"var(--Quiet)",trackOn:"var(--Buttons-Default-Button)",trackOnBorder:"var(--Buttons-Default-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-Default-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-Default-Button)"},e.outline={type:"themed",trackOff:"var(--Background)",trackOffBorder:"var(--Quiet)",trackOn:"var(--Buttons-Default-Button)",trackOnBorder:"var(--Buttons-Default-Border)",dotOff:"var(--Quiet)",dotOn:"var(--Buttons-Default-Text)",iconOff:"var(--Background)",iconOn:"var(--Buttons-Default-Button)"},e.primary=$i("primary"),e.light=_i("primary"),e}(),y=b[e]||b.default,S=ea[t]||ea.medium,k="small"===t?ao:co,B=S.trackH-4,w=Math.max(24,S.trackW),C=Math.max(24,S.trackH),T=(C-S.trackH)/2,I={width:B,height:B,borderRadius:S.dotRadius,boxShadow:"none",border:"none",display:"flex",alignItems:"center",justifyContent:"center",transition:"background-color 0.15s ease","& > *":{width:S.icon,height:S.icon,display:"block"}},A={width:S.trackW,minWidth:24,height:C,minHeight:24,padding:0,overflow:"visible",opacity:i?"var(--Disabled, 0.38)":1,"& .MuiSwitch-switchBase":{position:"absolute",top:0,left:0,width:"100%",height:"100%",display:"flex",justifyContent:"flex-start",alignItems:"center",paddingTop:0,paddingBottom:0,paddingLeft:"2px",paddingRight:w-S.trackW+2+"px",color:"transparent",transition:"justify-content 0.15s ease",transform:"none","& .MuiSwitch-input":{left:0,top:0,width:"100%",height:"100%",margin:0},"& .MuiSwitch-thumb":{...I,backgroundColor:y.dotOff,color:y.iconOff},"&.Mui-checked":{justifyContent:"flex-end",transform:"none","& .MuiSwitch-thumb":{...I,backgroundColor:y.dotOn,color:y.iconOn},"& + .MuiSwitch-track":{backgroundColor:y.trackOn,borderColor:y.trackOnBorder,opacity:1}},"&:hover, &.Mui-checked:hover":{backgroundColor:"transparent"},"&:hover + .MuiSwitch-track":{boxShadow:an},"&:active + .MuiSwitch-track":{boxShadow:nn},"&.Mui-focusVisible + .MuiSwitch-track":{outline:"1px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled + .MuiSwitch-track":{opacity:1}},"& .MuiSwitch-track":{width:S.trackW,height:S.trackH,borderRadius:"var(--Sizing-3, 24px)",backgroundColor:y.trackOff,border:"1px solid "+y.trackOffBorder,boxSizing:"border-box",opacity:1,position:"absolute",top:T,left:0,transition:"background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease"},...m},R=e.includes("-light")||"light"===e,E=void 0!==p?p:c,P=void 0!==u?u:c,O=e=>de("span",{className:"MuiSwitch-thumb",children:e}),L=de(z,{...void 0!==E||void 0!==P?{icon:O(E),checkedIcon:O(P)}:{},checked:r,defaultChecked:o,onChange:n,disabled:i,name:s,value:d,slotProps:{input:{...f?{"aria-label":f}:{},...g?{"aria-labelledby":g}:{}}},className:"switch-"+e+" "+h,sx:A,disableRipple:!0,...R&&y.dataTheme?{"data-theme":y.dataTheme,"data-surface":y.dataSurface||"Surface-Dim"}:{},...x});return a?de(v,{control:L,label:de(k,{component:"span",sx:{color:i?"var(--Text-Quiet)":"var(--Text)",fontSize:"small"===t?"13px":"15px",fontWeight:500,opacity:i?.6:1},children:a}),labelPlacement:l,sx:{gap:"8px",marginLeft:0,marginRight:0}}):L}const ra=ta,oa=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",na={default:"Default",quiet:"Quiet",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ia=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],aa=["filled","outlined","rounded","twotone","sharp"],la={filled:"Filled",outlined:"Outlined",rounded:"Rounded",twotone:"Two Tone",sharp:"Sharp"},sa={Home:{filled:Be,outlined:Oe,rounded:je,twotone:tt,sharp:ht},Favorite:{filled:ke,outlined:Le,rounded:Ge,twotone:rt,sharp:mt},Delete:{filled:we,outlined:Me,rounded:Ue,twotone:ot,sharp:ft},Settings:{filled:Ce,outlined:We,rounded:Xe,twotone:nt,sharp:gt},Search:{filled:Te,outlined:Te,rounded:Ke,twotone:it,sharp:xt},Star:{filled:Ie,outlined:De,rounded:qe,twotone:at,sharp:bt},Person:{filled:me,outlined:Fe,rounded:Je,twotone:lt,sharp:vt},Notifications:{filled:Ae,outlined:Ne,rounded:Ye,twotone:st,sharp:yt},Visibility:{filled:ze,outlined:He,rounded:Ze,twotone:dt,sharp:St},ShoppingCart:{filled:Re,outlined:Ve,rounded:$e,twotone:ct,sharp:kt},Lock:{filled:Ee,outlined:Qe,rounded:_e,twotone:ut,sharp:Bt},Info:{filled:Pe,outlined:ve,rounded:et,twotone:pt,sharp:wt}};function da({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function ca({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(da,{ratio:t,threshold:r})]})}function ua({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"primary":"primary-outline",size:"small",onClick:r,children:e})}function pa(){const[e,t]=r("filled"),[o,n]=r("default"),[a,l]=r("medium"),[s,d]=r("40"),[c,u]=r(!1),[p,m]=r("Home"),[f,g]=r(""),[x,b]=r({}),v=na[o]||"Default",y="twotone"===e,S="custom"===a?(parseInt(s,10)||40)+"px":{xs:"12px",small:"16px",medium:"24px",large:"36px"}[a]||"24px",k=function(e,t){return sa[e]?.[t]||sa[e]?.filled||Be}(p,e),w=function(e){return{outlined:"Outlined",rounded:"Rounded",twotone:"TwoTone",sharp:"Sharp"}[e]||""}(e),C=p+w+"Icon",T=f.trim().length>0,A="<Icon>\n <"+C+' />\n</Icon>\n{/* aria-hidden="true" by default */}',z='<Icon aria-label="'+(T?f.trim():p+" icon")+'">\n <'+C+' />\n</Icon>\n{/* role="img" added automatically */}';return i(()=>{b({background:Xi("--Background"),iconColor:Xi("--Icons-"+v),iconVariant:Xi("--Icons-Variant-"+v)})},[o,v]),ce(h,{sx:{pb:8},children:[de(Jr,{children:"Icon"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(h,{sx:{p:4,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",minHeight:200,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)",gap:2},children:de(jo,{color:o,size:a,fontSize:"custom"===a?parseInt(s,10)||40:void 0,disabled:c,twoTone:y,"aria-label":T?f.trim():void 0,children:de(k,{})})}),de(Vi,{code:(()=>{const e=[];"default"!==o&&e.push('color="'+o+'"'),"custom"===a?(e.push('size="custom"'),e.push("fontSize={"+(parseInt(s,10)||40)+"}")):"medium"!==a&&e.push('size="'+a+'"'),y&&e.push("twoTone"),c&&e.push("disabled"),T&&e.push('aria-label="'+f.trim()+'"');const t=e.length?" "+e.join(" "):"";return"import "+C+" from '@mui/icons-material/"+p+(w||"")+"';\n\n<Icon"+t+">\n <"+C+" />\n</Icon>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ICON"}),de(h,{component:"input",type:"text",value:p,onChange:e=>m(e.target.value),placeholder:"e.g. Home, Favorite, Delete",sx:{width:"100%",padding:"6px 10px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",boxSizing:"border-box","&:focus":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px",borderColor:"var(--Focus-Visible)"}}}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Enter a MUI icon name."," ",de(h,{component:"a",href:"https://mui.com/material-ui/material-icons/",target:"_blank",rel:"noopener noreferrer",sx:{color:"var(--Text-Primary)",textDecoration:"underline","&:hover":{color:"var(--Header-Primary)"}},children:"Browse MUI Icons ↗"})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:aa.map(r=>de(ua,{label:la[r],selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:ia.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>{const t=na[e],r=o===e;return de(h,{component:"button",onClick:()=>n(e),"aria-label":"Select "+oa(e),"aria-pressed":r,title:oa(e),sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Icons-"+t+")",border:r?"2px solid var(--Text)":"1px solid var(--Border)",outline:r?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:r&&de(he,{sx:{fontSize:16,color:"var(--Background)",pointerEvents:"none"}})},e)})})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["xs","small","medium","large","custom"].map(e=>de(ua,{label:"xs"===e?"XS":oa(e),selected:a===e,onClick:()=>l(e)},e))}),"custom"===a&&ce(h,{sx:{display:"flex",alignItems:"center",gap:1,mt:1.5},children:[de(h,{component:"input",type:"number",value:s,onChange:e=>d(e.target.value),"aria-label":"Custom font size in pixels",sx:{width:72,padding:"4px 8px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none","&:focus":{borderColor:"var(--Focus-Visible)"}}}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"px"})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ARIA LABEL"}),de(h,{component:"input",type:"text",value:f,onChange:e=>g(e.target.value),placeholder:"Leave empty for decorative (aria-hidden)",sx:{width:"100%",padding:"6px 10px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",boxSizing:"border-box","&:focus":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px",borderColor:"var(--Focus-Visible)"}}}),de(bo,{style:{color:T?"var(--Tags-Success-Text)":"var(--Text-Quiet)",display:"block",marginTop:6},children:T?'✓ Meaningful — role="img" aria-label="'+f.trim()+'"':'Decorative — aria-hidden="true" (invisible to screen readers)'})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Reduces opacity to 0.38"})]}),de(ta,{checked:c,onChange:e=>u(e.target.checked),size:"small","aria-label":"Toggle disabled"})]})]})}),de(si,{value:1,children:ce(h,{sx:{p:3},children:[ce(ao,{color:"quiet",style:{marginBottom:24},children:[la[e]," / ",oa(o)," / ","custom"===a?s+"px":a,T?" / meaningful":" / decorative"]}),ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Icon Contrast (WCAG 1.4.11 — 3:1)"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Non-text elements must contrast 3:1 against the page background."}),de(ca,{label:"var(--Icons-"+v+") vs. var(--Background)",ratio:Ui(x.iconColor,x.background),threshold:3,note:C+" at "+S+" in "+oa(o)+" color"}),y&&de(ca,{label:"var(--Icons-Variant-"+v+") vs. var(--Background)",ratio:Ui(x.iconVariant,x.background),threshold:3,note:"Two-tone secondary fill — must also meet 3:1"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)",backgroundColor:T?"var(--Tags-Success-BG, rgba(0,200,0,0.05))":"transparent",px:1,borderRadius:"4px"},children:[ce(ao,{style:{fontWeight:600},children:["Current icon — ",T?"meaningful ✓":"decorative"]}),de(h,{component:"pre",sx:{fontFamily:"monospace",fontSize:"11px",color:"var(--Text-Quiet)",mt:.5,whiteSpace:"pre-wrap",wordBreak:"break-word",margin:0},children:T?z:A})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Decorative (no aria-label):"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'aria-hidden="true" is applied automatically. The icon is invisible to screen readers. Use this when the icon is purely visual — e.g. a decorative bullet or inline illustration.'}),de(h,{component:"pre",sx:{fontFamily:"monospace",fontSize:"11px",color:"var(--Text-Quiet)",mt:.5,whiteSpace:"pre-wrap",wordBreak:"break-word",margin:0},children:A})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Meaningful (with aria-label):"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'role="img" is added automatically. The label is announced by screen readers. Use this when the icon conveys information that is not present in surrounding text.'}),de(h,{component:"pre",sx:{fontFamily:"monospace",fontSize:"11px",color:"var(--Text-Quiet)",mt:.5,whiteSpace:"pre-wrap",wordBreak:"break-word",margin:0},children:z})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:["Disabled state",c?" ← current":"",":"]}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Opacity 0.38 — visual cue only. To disable an action, disable the wrapping interactive element (button, link), not the icon itself."})]}),y&&ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:["Two-tone",y?" ← current":"",":"]}),ce(bo,{style:{color:"var(--Text-Quiet)"},children:["Secondary fill uses var(--Icons-Variant-",v,"). Both the primary and secondary fills must meet 3:1 contrast independently."]})]}),ce(h,{sx:{py:1.5},children:[ce(ao,{children:["Touch target — ",S," icon","small"===a?" ⚠":" ✓",":"]}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"small"===a?"Small icons (20px) need a 24px minimum target area around them (WCAG 2.5.5). Wrap in a button with padding.":"Icon is "+S+" — meets 24px minimum. Ensure the wrapping interactive element also meets 24×24px."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Size Reference"}),de(B,{spacing:0,children:[{label:"Small",s:"small",px:"20px",note:"Inline text, compact UI"},{label:"Medium",s:"medium",px:"24px",note:"Standard UI — default"},{label:"Large",s:"large",px:"36px",note:"Emphasis, empty states, hero areas"},{label:"Custom",s:"custom",px:"any",note:"Ensure 24×24px minimum touch target (WCAG 2.5.5)"}].map(({label:e,s:t,px:r,note:o},n,i)=>ce(h,{sx:{py:1.5,borderBottom:n<i.length-1?"1px solid var(--Border)":"none",display:"flex",justifyContent:"space-between",alignItems:"flex-start"},children:[ce(h,{children:[ce(ao,{children:[e," — ",r]}),de(bo,{style:{color:"var(--Text-Quiet)"},children:o})]}),a===t&&de(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:"var(--Tags-Success-BG)",color:"var(--Tags-Success-Text)"},children:"current"})]},e))})]})]})]})})]})})})]})]})}const ha={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error",white:"White",black:"Black"},ma={small:{size:32,iconSize:"16px",borderRadius:"8px"},medium:{size:40,iconSize:"20px",borderRadius:"10px"},large:{size:48,iconSize:"24px",borderRadius:"12px"}};function fa({children:e,color:t="primary",variant:r="solid",size:o="medium",className:n="",sx:i={},...a}){const l=ma[o]||ma.medium,s=ha[t]||ha.primary;let d,c;switch(r){case"light":d=s,c="Surface-Brightest";break;case"dark":d=s,c="Surface-Dimmest";break;default:d=s,c="Surface"}return de(h,{"data-theme":d,"data-surface":c,className:"icon-badge icon-badge-"+r+" icon-badge-"+o+" icon-badge-"+t+" "+n,sx:{width:l.size,height:l.size,borderRadius:l.borderRadius,backgroundColor:"var(--Background)",color:"var(--Text)",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,"& svg":{width:l.iconSize,height:l.iconSize,fontSize:l.iconSize,color:"inherit",stroke:"currentColor"},...i},...a,children:e})}const ga={default:"Default-Light",primary:"Primary-Light",secondary:"Secondary-Light",tertiary:"Tertiary-Light",neutral:"Neutral-Light",info:"Info-Light",success:"Success-Light",warning:"Warning-Light",error:"Error-Light"};function xa({variant:e="outlined",color:o="default",size:n="medium",disabled:i=!1,orientation:a="horizontal",spacing:l=0,fit:s,fullWidth:d=!1,equalWidth:c=!1,value:u,defaultValue:p,onChange:m,children:f,className:g="",sx:x={},"aria-label":b,...v}){const[y,S]=r(p??null),k=void 0!==u,B=k?u:y,w="horizontal"===a,C=0===l,T="light"===e,I="ghost"===e,A=s??(d?"fill":c?"equal":"hug"),z="fill"===A,R="equal"===A&&w,E=(P=o).charAt(0).toUpperCase()+P.slice(1);var P;const O="var(--Buttons-"+E+"-Border)",L="var(--Buttons-"+E+"-Button)",M="var(--Buttons-"+E+"-Text)",W=ga[o]||"Default-Light",D=t.Children.toArray(f).filter(Boolean),F=D.length,N=(e,t)=>r=>{k||S(e),m?.(e,r),t?.(r)},H=D.map((e,r)=>{if(!t.isValidElement(e))return e;const a=0===r,l=r===F-1,s=e.props.value??r,d=B===s;let c;if(C&&F>1){const e="var(--Style-Border-Radius)";c=w?a&&l?e:a?e+" 0 0 "+e:l?"0 "+e+" "+e+" 0":"0":a&&l?e:a?e+" "+e+" 0 0":l?"0 0 "+e+" "+e:"0"}const u={...C&&F>1?{borderRadius:c,...!a&&(w?{marginLeft:"calc(-1 * var(--Button-Border-Width))"}:{marginTop:"calc(-1 * var(--Button-Border-Width))"}),position:"relative","&:hover, &:focus-visible":{zIndex:1}}:{},...d?{backgroundColor:L+" !important",color:M+" !important",borderColor:O+" !important","&:hover, &:active, &.Mui-focusVisible, &:focus-visible":{backgroundColor:L+" !important",color:M+" !important",borderColor:O+" !important"}}:{},...d?{}:{color:"var(--Quiet)",backgroundColor:"transparent","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)",zIndex:1},"&:active":{backgroundColor:"var(--Pressed)",color:"var(--Buttons-Default-Text)"}},...I?{border:"none !important","&:hover":{border:"none !important"}}:{},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px",zIndex:2},...e.props.sx},p=t.cloneElement(e,{variant:e.props.variant??(I?"ghost":d?o:o+"-outline"),size:e.props.size??n,disabled:e.props.disabled??i,onClick:N(s,e.props.onClick),"aria-pressed":d,sx:u});return T&&!d?de(h,{"data-theme":W,"data-surface":"Surface",sx:{display:"contents"},children:p},r):t.cloneElement(p,{key:r})});return de(h,{role:"group","aria-label":b,className:"btn-group btn-group-"+e+" btn-group-"+o+" "+g,sx:{...R?{display:z?"grid":"inline-grid",gridAutoFlow:"column",gridAutoColumns:"1fr",justifyItems:"stretch",alignItems:"stretch",width:z?"100%":"fit-content"}:{display:z?"flex":"inline-flex",flexDirection:w?"row":"column",alignItems:"stretch",width:z?"100%":"auto"},gap:C?0:l,border:"none",borderRadius:"var(--Style-Border-Radius)",...x},...v,children:H})}const ba=["Link","Chip","Badge","Caption","Label","Tag","BodySmall","LegalSemibold","Legal","LabelSmall","LabelExtraSmall","EyebrowSmall","ButtonSmall"];function va(e){let r=!1;return t.Children.forEach(e,e=>{(function(e){if(!t.isValidElement(e))return!1;const r=e.props||{};if("small"===r.size)return!0;if("small"===r["data-size"])return!0;if(24===r.height||24===r.minHeight)return!0;if("24px"===r.height||"24px"===r.minHeight)return!0;if(r.sx){const e=r.sx.minHeight||r.sx.height;if(24===e||"24px"===e)return!0}const o=e.type;if(o){const e=o.displayName||o.name||"";if(ba.some(t=>e.includes(t)))return!0}return!1})(e)&&(r=!0)}),r}function ya({children:e,gap:t,spacing:r,direction:o="column",enforceMinGap:n=!0,minGapToken:i="--min-stack-gap",divider:a,flexWrap:l,useFlexGap:s=!0,alignItems:c,justifyContent:u,sx:p={},className:h="",...m}){const f=void 0!==t?t:r,g=n&&va(e),x=d(()=>{if(!g)return f;const e=function(e,t=8){return null==e?0:"number"==typeof e?e*t:"string"==typeof e?e.endsWith("px")?parseFloat(e):e.endsWith("rem")?parseFloat(e)*parseFloat(getComputedStyle(document.documentElement).fontSize||"16"):parseFloat(e)*t||0:0}(f),t=function(e,t=8){if("undefined"==typeof window)return t;const r=getComputedStyle(document.documentElement).getPropertyValue(e).trim();return r?r.endsWith("rem")?parseFloat(r)*parseFloat(getComputedStyle(document.documentElement).fontSize):parseFloat(r)||t:t}(i,8);return e>=t?f:"var("+i+", "+t+"px)"},[g,f,i]);return de(B,{direction:o,spacing:s?void 0:x,gap:s?x:void 0,divider:a,flexWrap:l,useFlexGap:s,alignItems:c,justifyContent:u,className:"omni-stack"+(g?" omni-stack-min-gap-enforced":"")+(h?" "+h:""),sx:{background:"var(--Background)",boxSizing:"border-box",...g?{"&::before":{display:"none"}}:{},...p},"data-min-gap-enforced":g?"true":void 0,...m,children:e})}const Sa=e=>de(ya,{direction:"row",alignItems:"center",...e}),ka=e=>de(ya,{direction:"column",...e}),Ba=e=>de(ya,{direction:"column",alignItems:"center",justifyContent:"center",...e}),wa=e=>de(ya,{direction:"row",alignItems:"center",justifyContent:"space-between",...e}),Ca=e=>de(ya,{direction:"row",flexWrap:"wrap",...e}),Ta=({breakpoint:e="sm",...t})=>de(ya,{direction:{xs:"column",[e]:"row"},...t}),Ia=ya,Aa=Ca,za=e=>de(h,{sx:{borderBottom:"1px solid var(--Border)",width:"100%"},...e}),Ra=({sx:e,...t})=>de(ya,{sx:{px:2,...e},...t}),Ea=({sx:e,...t})=>de(ya,{sx:{overflowY:"auto",...e},...t}),Pa={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Oa={small:{gap:"8px",fontSize:"13px",padding:"var(--Card-Padding)"},medium:{gap:"12px",fontSize:"14px",padding:"var(--Card-Padding)"},large:{gap:"16px",fontSize:"16px",padding:"var(--Card-Padding)"}},La=s({variant:"default",color:"primary",size:"medium",orientation:"vertical"});function Ma({children:e,variant:t="solid",color:r="default",surface:o,size:n="medium",orientation:i="vertical",clickable:a=!1,selected:l=!1,elevated:s=!1,draggable:d=!1,onClick:c,href:u,className:p="",sx:m={},...f}){const g="default"===r,x=g?"":Pa[r],b=o||(g?"Container":"dark"===t?"Surface-Dimmest":"light"===t?"Surface-Brightest":"Surface"),v=Oa[n]||Oa.medium,y="horizontal"===i,S=!!d,k=a||!!c||!!u||l||S,B=u?"a":"div",w=l?`var(--Buttons-${(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===r?"Default":r)}-Border)`:"var(--Buttons-Default-Border)",C=k?l?`2px solid ${w}`:"1px solid var(--Buttons-Default-Border)":"1px solid var(--Border-Variant)",T=s?ln:an,I=s?sn:ln,A=s?an:nn;return de(La.Provider,{value:{variant:t,color:r,size:n,orientation:i},children:de(h,{component:B,href:u||void 0,onClick:k?c:void 0,role:k?"button":void 0,tabIndex:k?0:void 0,"aria-pressed":!!l||void 0,draggable:S||void 0,className:"card card-"+t+" card-"+n+" card-"+i+(k?" card-clickable":"")+(l?" card-selected":"")+(s?" card-elevated":"")+(S?" card-draggable":"")+" "+p,sx:{display:"flex",border:C,borderRadius:"var(--Card-Radius)",boxShadow:T,overflow:"hidden",textDecoration:"none",transition:"box-shadow 0.2s ease, border-color 0.2s ease, transform 0.1s ease",...k&&!S&&{cursor:"pointer","&:hover":{borderColor:"var(--Buttons-Default-Border)",boxShadow:I,transform:"translateY(-1px)"},"&:active":{transform:"translateY(0) scale(0.995)",boxShadow:A},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"3px",borderRadius:"calc(var(--Card-Radius) + 3px)"}},...S&&{cursor:"grab","&:hover":{borderColor:"var(--Buttons-Default-Border)",boxShadow:I},"&:active":{cursor:"grabbing",zIndex:10,boxShadow:sn,transform:"scale(1.02)",borderWidth:"2px",borderColor:"var(--Buttons-Primary-Border)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"3px"}},...m},onKeyDown:k?e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),c?.())}:void 0,...f,children:de(h,{"data-theme":x||void 0,"data-surface":b,sx:{display:"flex",flexDirection:y?"row":"column",gap:v.gap,padding:v.padding,backgroundColor:"var(--Background)",color:"var(--Text)",fontSize:v.fontSize,fontFamily:"inherit",borderRadius:"inherit",position:"relative",flex:1,minWidth:0,overflow:"hidden"},children:e})})})}function Wa({children:e,className:t="",sx:r={},...o}){const{size:n}=l(La);return de(h,{className:"card-content "+t,sx:{display:"flex",flexDirection:"column",gap:(Oa[n]||Oa.medium).gap,flex:1,minWidth:0,...r},...o,children:e})}const Da=e=>de(Ma,{clickable:!0,selected:e.selected,...e}),Fa=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Na=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary"]},{label:"Core",colors:["white","black"]},{label:"State",colors:["info","success","warning","error"]}],Ha=[Be,Ct,ge,Ie,Tt,It];function Va(){const[e,t]=r("primary"),[o,n]=r("solid"),[i,a]=r("medium"),l=Ha[0];return ce(ka,{spacing:4,style:{paddingBottom:64},children:[de(Jr,{children:"Icon Badge"}),ce("div",{style:{display:"grid",gridTemplateColumns:"1fr 1fr",gap:24},children:[de(Ma,{padding:"medium",children:ce(ka,{spacing:4,alignItems:"center",children:[de("div",{style:{padding:40},children:de(fa,{color:e,variant:o,size:i,children:de(l,{})})}),de(Sa,{spacing:4,alignItems:"flex-end",children:["small","medium","large"].map(t=>ce(ka,{spacing:1,alignItems:"center",children:[de(fa,{color:e,variant:o,size:t,children:de(l,{})}),de(ao,{style:{color:"var(--Quiet)"},children:Fa(t)})]},t))}),ce(ka,{spacing:1,alignItems:"center",children:[de(ao,{style:{color:"var(--Quiet)",fontWeight:600,fontSize:"0.7rem"},children:"Variants"}),de(Sa,{spacing:3,children:["solid","light","dark"].map(t=>ce(ka,{spacing:1,alignItems:"center",children:[de(fa,{color:e,variant:t,size:"medium",children:de(l,{})}),de(ao,{style:{color:"var(--Quiet)",fontSize:"0.65rem"},children:Fa(t)})]},t))})]}),ce(ka,{spacing:1,alignItems:"center",children:[de(ao,{style:{color:"var(--Quiet)",fontWeight:600,fontSize:"0.7rem"},children:"All Colors"}),de(Sa,{spacing:2,style:{flexWrap:"wrap",justifyContent:"center"},children:Na.flatMap(e=>e.colors).map(e=>ce(ka,{spacing:0,alignItems:"center",children:[de(fa,{color:e,variant:o,size:"small",children:de(l,{})}),de(ao,{style:{color:"var(--Quiet)",fontSize:"0.55rem"},children:Fa(e)})]},e))})]})]})}),de(Ma,{padding:"medium",children:ce(ka,{spacing:4,children:[de(Jr,{style:{fontSize:"1rem"},children:"Playground"}),ce(ka,{spacing:2,children:[de(ko,{children:"Color"}),Na.map(r=>ce(ka,{spacing:1,children:[de(ao,{style:{color:"var(--Quiet)",fontWeight:600,fontSize:"0.7rem"},children:r.label}),de(Sa,{spacing:1,children:r.colors.map(r=>de(In,{variant:e===r?"default":"outline",size:"small",onClick:()=>t(r),children:Fa(r)},r))})]},r.label))]}),ce(ka,{spacing:1,children:[de(ko,{children:"Variant"}),de(xa,{size:"small",children:["solid","light","dark"].map(e=>de(In,{variant:o===e?"default":"outline",size:"small",onClick:()=>n(e),children:Fa(e)},e))})]}),ce(ka,{spacing:1,children:[de(ko,{children:"Size"}),de(xa,{size:"small",children:["small","medium","large"].map(e=>de(In,{variant:i===e?"default":"outline",size:"small",onClick:()=>a(e),children:Fa(e)},e))})]}),ce(ka,{spacing:0,children:[ce(ao,{style:{color:"var(--Quiet)"},children:["data-theme: ",Fa(e),"light"===o?"-Light":""]}),ce(ao,{style:{color:"var(--Quiet)"},children:["data-surface: ","dark"===o?"Surface-Dimmest":"Surface"]}),de(ao,{style:{color:"var(--Quiet)"},children:"bg: var(--Background)"}),de(ao,{style:{color:"var(--Quiet)"},children:"icon: var(--Text)"})]})]})})]})]})}const Qa={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ja={small:{size:32,iconSize:16,fontSize:"13px",px:12,gap:6},medium:{size:48,iconSize:24,fontSize:"14px",px:16,gap:8},large:{size:56,iconSize:36,fontSize:"15px",px:20,gap:10}};function Ga({children:e,icon:t,label:r,variant:o="solid",color:n="primary",size:i="medium",extended:a=!1,animate:l=!1,disabled:s=!1,onClick:d,ariaLabel:c,className:u="",sx:p={},...m}){const f=function(e,t){const r=Qa[t]||"Primary";return"light"===e?{bg:"var(--Buttons-"+r+"-Light-Button)",text:"var(--Buttons-"+r+"-Light-Text)",border:"var(--Buttons-"+r+"-Light-Border)",hover:"var(--Buttons-"+r+"-Light-Hover)",active:"var(--Buttons-"+r+"-Light-Pressed)"}:{bg:"var(--Buttons-"+r+"-Button)",text:"var(--Buttons-"+r+"-Text)",border:"var(--Buttons-"+r+"-Border)",hover:"var(--Buttons-"+r+"-Hover)",active:"var(--Buttons-"+r+"-Pressed)"}}(o,n),g=ja[i]||ja.medium,x=t||e||de(At,{sx:{fontSize:g.iconSize}}),b=c||r||"Action";return ce(ue,{children:[l&&de("style",{children:"\n@keyframes fab-pulse {\n 0% { box-shadow: 0 0 0 0 rgba(var(--pulse-rgb, 0,0,0), 0.4); }\n 70% { box-shadow: 0 0 0 12px rgba(var(--pulse-rgb, 0,0,0), 0); }\n 100% { box-shadow: 0 0 0 0 rgba(var(--pulse-rgb, 0,0,0), 0); }\n}\n"}),ce(h,{component:"button",type:"button",role:"button","aria-label":b,onClick:d,disabled:s,className:"fab fab-"+o+" fab-"+n+" fab-"+i+(a?" fab-extended":"")+(l?" fab-animate":"")+(s?" fab-disabled":"")+(u?" "+u:""),sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",gap:a?g.gap+"px":0,...a?{height:g.size+"px",borderRadius:g.size/2+"px",px:g.px+"px"}:{width:g.size+"px",height:g.size+"px",borderRadius:"50%"},backgroundColor:f.bg,color:f.text,border:"var(--Button-Border-Width) solid "+f.border,"--_height":g.size+"px","--_bevel":"min(calc(var(--Button-Bevel) * var(--_height) / 100), calc(var(--_height) / 5))",boxShadow:`${mn(n)}, ${ln}`,fontSize:g.fontSize,fontFamily:"inherit",fontWeight:600,cursor:s?"not-allowed":"pointer",opacity:s?.5:1,outline:"none",flexShrink:0,transition:"background-color 0.15s ease, box-shadow 0.2s ease, transform 0.1s ease","&:hover":s?{}:{backgroundColor:f.hover,boxShadow:`${mn(n)}, ${sn}`},"&:active":s?{}:{backgroundColor:f.active,transform:"scale(0.96)",boxShadow:mn(n)},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px"},...l&&!s&&{animation:"fab-pulse 2s infinite"},...p},...m,children:[de(h,{sx:{display:"flex",alignItems:"center",justifyContent:"center",fontSize:g.iconSize+"px",color:"inherit","& .MuiSvgIcon-root":{fontSize:"inherit",color:"inherit"}},children:x}),a&&r&&de(h,{component:"span",sx:{whiteSpace:"nowrap",lineHeight:1},children:r})]})]})}const Ua=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Xa=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Ka={default:"Tertiary",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"};function qa({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Ja({color:e,selected:t,onClick:r}){const o=Ka[e]||"Primary";return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+Ua(e),"aria-pressed":t,title:Ua(e),sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Ya({value:e,onChange:t,placeholder:r,label:o}){return ce(h,{children:[o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4},children:o}),de(h,{component:"input",type:"text",value:e,onChange:e=>t(e.target.value),placeholder:r,sx:{width:"100%",padding:"6px 10px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none","&:focus":{borderColor:"var(--Focus-Visible)"}}})]})}function Za(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r("Add"),[l,s]=r(!1),[d,c]=r("Create"),[u,p]=r(!1),[m,f]=r(!1),[g,x]=r(null),[b,v]=r("Surface"),y="default"===e?"tertiary":e;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Floating Action Button"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:g,children:de(Ga,{color:y,size:o,icon:(()=>{const e=zt[i]||zt.Add;return de(jo,{size:"medium",children:de(e,{})})})(),extended:l,label:d,animate:u,disabled:m,ariaLabel:l?d:i})}),de(Vi,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),t.push("icon={<"+i+"Icon />}"),l&&(t.push("extended"),t.push('label="'+d+'"')),u&&t.push("animate"),m&&t.push("disabled"),t.push('ariaLabel="'+(l?d:i)+'"'),"<Fab\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:g,onThemeChange:x,surface:b,onSurfaceChange:v})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Xa.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(Ja,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(qa,{label:Ua(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(Ya,{label:"Icon Name",value:i,onChange:a,placeholder:"Add"}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:[de("a",{href:"https://mui.com/material-ui/material-icons/",target:"_blank",rel:"noopener noreferrer",style:{color:"var(--Hotlink)"},children:"Material icon"})," name (e.g. Add, Edit, Favorite, Share)"]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Extended"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Pill shape with icon + text label"})]}),de(ta,{checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Extended"})]}),l&&de(h,{sx:{mt:1.5},children:de(Ya,{label:"Label Text",value:d,onChange:c,placeholder:"Create"})}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Animation"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Pulse ring effect to draw attention"})]}),de(ta,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Animation"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(ta,{checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Role:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<button role="button" aria-label="...">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Label:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:l?"Extended: visible label provides accessible name.":"Icon-only: aria-label is required."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Focus:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"3px solid var(--Focus-Visible) with 2px offset."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Disabled:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"HTML disabled attribute. 50% opacity, removed from tab order."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Best Practices"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"One per screen:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"FABs represent the primary action. Use at most one per view."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Extended for clarity:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Use extended variant when the icon alone may be ambiguous."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Animation:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Use sparingly. Respect prefers-reduced-motion."})]})]})]})]})})})]})})})]})]})}function $a({items:e=[],sections:t,value:o,defaultValue:i=0,onChange:a,expandable:l=!1,expandedWidth:s="partial",defaultExpanded:d=!1,fabAction:c,className:u="",sx:p={},...m}){const[f,g]=r(i),[x,b]=r(d),v=void 0!==o,y=v?o:f,S=n(e=>{v||g(e),a?.(e)},[v,a]),k=l&&x;return ce(h,{component:"nav",role:"navigation","aria-label":"Navigation rail","data-theme":"Default","data-surface":"Surface-Dim",className:"rail"+(k?" rail-expanded":" rail-collapsed")+" "+u,sx:{display:"flex",flexDirection:"column",width:(k?"full"===s?320:240:72)+"px",minHeight:"100%",backgroundColor:"var(--Background)",borderRight:"1px solid var(--Border)",fontFamily:"inherit",transition:"width 0.25s ease",overflow:"hidden",flexShrink:0,...p},...m,children:[l&&de(h,{sx:{display:"flex",justifyContent:k?"flex-start":"center",px:k?1.5:0,height:56,alignItems:"center"},children:de(In,{iconOnly:!0,variant:"ghost",size:"small",onClick:()=>b(e=>!e),"aria-label":k?"Collapse menu":"Expand menu",children:de(jo,{size:"small",sx:{color:"inherit"},children:de(k?Ot:Pt,{})})})}),c&&de(h,{sx:{px:k?2:1,py:1,flexShrink:0},children:de(In,{variant:"primary-light",size:"medium",onClick:c.onClick,"aria-label":c.label||"Action",startIcon:c.icon?de(jo,{size:"small",sx:{color:"inherit"},children:c.icon}):void 0,sx:{width:k?"100%":56,borderRadius:k?"28px":"var(--Style-Border-Radius)",justifyContent:k?"flex-start":"center",transition:"all 0.2s ease"},children:k?c.label:null})}),de(h,{role:"tablist","aria-orientation":"vertical",sx:{flex:1,overflowY:"auto",overflowX:"hidden",py:.5},children:(()=>{if(t&&t.length>0){const e=[];let r=0;return t.forEach((t,o)=>{o>0&&e.push(de(h,{"aria-hidden":"true",sx:{height:"1px",backgroundColor:"var(--Border)",mx:k?2:1.5,my:.5}},"divider-"+o)),t.items.forEach(t=>{const o=r;e.push(de(_a,{icon:t.icon,label:t.label,badge:t.badge,selected:y===o,expanded:k,onClick:()=>S(o)},"item-"+o)),r++})}),e}return e.map((e,t)=>de(_a,{icon:e.icon,label:e.label,badge:e.badge,selected:y===t,expanded:k,onClick:()=>S(t)},t))})()})]})}function _a({icon:e,label:t,badge:r,selected:o,expanded:n,onClick:i}){const a="var(--Buttons-Default-Button)",l="var(--Buttons-Default-Text)";return ce(h,{component:"button",type:"button",role:"tab","aria-selected":o,"aria-label":t,onClick:i,sx:{display:"flex",flexDirection:n?"row":"column",alignItems:"center",justifyContent:n?"flex-start":"center",gap:n?1.5:.25,width:"100%",height:56,px:n?2.5:.5,border:"none",borderRadius:0,backgroundColor:n&&o?a:"transparent",color:o?l:"var(--Quiet)",cursor:"pointer",fontFamily:"inherit",textAlign:n?"left":"center",transition:"background-color 0.15s ease, color 0.15s ease",outline:"none","&:hover":o?{}:{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},children:[ce(h,{sx:{position:"relative",display:"flex",alignItems:"center",justifyContent:"center",...!n&&{width:o?56:24,height:32,borderRadius:"16px",backgroundColor:o?a:"transparent",transition:"background-color 0.2s ease, width 0.2s ease"},...n&&{flexShrink:0}},children:[de(jo,{size:"small",sx:{color:"inherit"},children:e}),r&&de(el,{value:r})]}),t&&de(bo,{style:{color:"inherit",fontWeight:500,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",...n?{flex:1}:{maxWidth:"100%",fontSize:"11px"}},children:t})]})}function el({value:e}){return de(h,{sx:{position:"absolute",top:-4,right:-6,minWidth:16,height:16,borderRadius:"8px",backgroundColor:"var(--Tags-Error-BG)",color:"var(--Tags-Error-Text)",fontSize:"10px",fontWeight:700,px:.5,display:"flex",alignItems:"center",justifyContent:"center",lineHeight:1},children:e})}const tl=[{icon:de(Be,{}),label:"Home"},{icon:de(Te,{}),label:"Search"},{icon:de(ke,{}),label:"Favorites",badge:3},{icon:de(me,{}),label:"Profile"},{icon:de(Ce,{}),label:"Settings"}];function rl({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function ol(){const[e,t]=r(!0),[o,n]=r("partial"),[i,a]=r(!1),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Rail"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[ce(di,{theme:l,surface:d,sx:{minHeight:400,alignItems:"stretch",p:0},children:[de($a,{items:tl,expandable:e,expandedWidth:o,fabAction:i?{icon:de(At,{}),label:"Create",onClick:()=>{}}:void 0}),de(h,{sx:{flex:1,p:3},children:de(ao,{style:{color:"var(--Quiet)"},children:"Main content area"})})]}),de(Vi,{code:(()=>{const t=["items={items}"];return e&&(t.push("expandable"),"partial"!==o&&t.push('expandedWidth="full"')),i&&t.push('fabAction={{ icon: <AddIcon />, label: "Create", onClick: handleCreate }}'),t.push("value={activeIndex}"),t.push("onChange={setActiveIndex}"),"<Rail\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"EXPANDED WIDTH"}),de(B,{direction:"row",spacing:1,children:["partial","full"].map(e=>{return de(rl,{label:(t=e,t?t.charAt(0).toUpperCase()+t.slice(1):""),selected:o===e,onClick:()=>n(e)},e);var t})})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Expandable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Toggle between collapsed and expanded"})]}),de(ta,{variant:"default-outline",checked:e,onChange:e=>t(e.target.checked),size:"small","aria-label":"Expandable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"FAB Action"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show create button at top"})]}),de(ta,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"FAB action"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Nav",value:'<nav role="navigation" aria-label="Navigation rail">'},{label:"Items",value:'role="tab" aria-selected on each item'},{label:"TabList",value:'role="tablist" aria-orientation="vertical"'},{label:"Toggle",value:'aria-label="Expand/Collapse menu"'},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: -3px"},{label:"Badge",value:"Visual only — announced via aria-label on parent item"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const nl={default:{theme:"Default"},primary:{theme:"Primary"},"primary-light":{theme:"Primary",surface:"Surface-Brightest"},white:{theme:"Neutral",surface:"Surface-Brightest"},black:{theme:"Neutral",surface:"Surface-Dimmest"}};function il({items:e=[],value:t,defaultValue:o,onChange:i,type:a="floating",orientation:l="horizontal",color:s="default",fab:d,className:c="",sx:u={},...p}){const[m,f]=r(o??null),g=void 0!==t,x=g?t:m,b=n(e=>{const t=x===e?null:e;g||f(t),i?.(t)},[g,x,i]),v=nl[s]||nl.default,y=v.theme,S=v.surface,k="vertical"===l,B="floating"===a,w=de(h,{role:"toolbar","aria-orientation":l,"aria-label":"Toolbar","data-theme":y,"data-surface":S||"Surface",className:"toolbar toolbar-"+a+" toolbar-"+l+" toolbar-"+s+" "+c,sx:{display:"inline-flex",flexDirection:k?"column":"row",alignItems:"center",gap:"4px",backgroundColor:"var(--Background)",border:"1px solid var(--Border-Variant)",borderRadius:B?"56px":"var(--Style-Border-Radius)",padding:B?"8px 16px":"8px",fontFamily:"inherit",flexShrink:0,...B&&{boxShadow:an},...u},...p,children:e.map((e,t)=>{const r=x===t;return de(In,{iconOnly:!0,variant:r?"default":"ghost",size:"small",onClick:()=>b(t),"aria-label":e.label,"aria-checked":r,role:"radio",children:de(jo,{size:"small",sx:{color:"inherit"},children:e.icon})},e.key||t)})});return d&&B?ce(h,{sx:{display:"inline-flex",flexDirection:k?"column":"row",alignItems:"center",gap:1},children:[w,de(In,{iconOnly:!0,variant:"default",size:"large",onClick:d.onClick,"aria-label":d.label||"Action",sx:{borderRadius:"50%",width:56,height:56,minWidth:"unset",minHeight:"unset"},children:de(jo,{size:"medium",sx:{color:"inherit"},children:d.icon})})]}):w}const al=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ll=[{icon:de(Lt,{}),label:"Bold"},{icon:de(Mt,{}),label:"Italic"},{icon:de(Wt,{}),label:"Underline"},{icon:de(Dt,{}),label:"Align left"},{icon:de(Ft,{}),label:"Align center"}];function sl({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function dl(){const[e,t]=r("floating"),[o,n]=r("default"),[i,a]=r("horizontal"),[l,s]=r(!1),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Toolbar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:d,surface:u,sx:{minHeight:200},children:de(il,{items:ll,type:e,color:o,orientation:i,fab:l&&"floating"===e?{icon:de(At,{}),label:"Create",onClick:()=>{}}:void 0})}),de(Vi,{code:(()=>{const t=["items={items}"];return"floating"!==e&&t.push('type="contextual"'),"default"!==o&&t.push('color="'+o+'"'),"horizontal"!==i&&t.push('orientation="vertical"'),l&&t.push('fab={{ icon: <AddIcon />, label: "Create", onClick: handleCreate }}'),t.push("value={selected}"),t.push("onChange={setSelected}"),"<Toolbar\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TYPE"}),de(B,{direction:"row",spacing:1,children:["floating","contextual"].map(r=>de(sl,{label:al(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["default","primary","primary-light","white","black"].map(e=>de(sl,{label:al(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ORIENTATION"}),de(B,{direction:"row",spacing:1,children:["horizontal","vertical"].map(e=>de(sl,{label:al(e),selected:i===e,onClick:()=>a(e)},e))})]}),"floating"===e&&ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"FAB Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Add FAB to the right of toolbar"})]}),de(ta,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"FAB button"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="toolbar" aria-orientation aria-label'},{label:"Items",value:'role="radio" aria-checked on each icon button'},{label:"Selection",value:"Toggle — click selected again to deselect"},{label:"Focus",value:"Uses Button component focus styles"},{label:"Floating",value:"borderRadius 56px, padding 16px, Effect-Level-2 shadow"},{label:"Contextual",value:"Standard border-radius, padding 8px, no shadow"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const cl={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 8px",iconSize:16,btnSize:28},medium:{height:"var(--Button-Height)",fontSize:"14px",padding:"6px 12px",iconSize:18,btnSize:36},large:{height:"var(--Large-Button-Height)",fontSize:"16px",padding:"8px 16px",iconSize:20,btnSize:44}};function ul({value:e,defaultValue:t=0,onChange:a,min:l,max:s,step:d=1,variant:c="outlined",style:u="outline",color:p="default",size:m="medium",label:f,labelPosition:g="top",placeholder:x,helperText:b,disabled:v=!1,fullWidth:y=!1,className:S="",sx:k={},...B}){const[w,C]=r(t),[T,I]=r(!1),A=o(null),z=void 0!==e,R=z?e:w,E=""!==R&&null!=R,P=(O="default"===p?"primary":p).charAt(0).toUpperCase()+O.slice(1);var O;const L="var(--Buttons-"+P+"-Border)",M="default"===p?"var(--Text)":"var(--Text-"+P+")",W="outlined"===c,D="floating"===g,F="top"===g,N=cl[m]||cl.medium,H="small"===m?ao:co,V=n(e=>{let t="number"==typeof e?e:parseFloat(e);isNaN(t)&&(t=0),void 0!==l&&t<l&&(t=l),void 0!==s&&t>s&&(t=s),z||C(t),a?.(t)},[z,a,l,s]),Q=o(R);Q.current=R;const j=n(e=>{if(v)return;const t="number"==typeof Q.current?Q.current:parseFloat(Q.current)||0;void 0!==l&&e<0&&t<=l||void 0!==s&&e>0&&t>=s||V(t+e*d)},[v,d,l,s,V]),G=void 0!==l&&R<=l,U=void 0!==s&&R>=s,X=o(null),K=o(null),q=n(()=>{X.current&&(clearTimeout(X.current),X.current=null),K.current&&(clearInterval(K.current),K.current=null)},[]),J=n(e=>{v||(q(),j(e),X.current=setTimeout(()=>{let t=120,r=0;const o=()=>{j(e),r+=1,10===r&&t>60?(clearInterval(K.current),t=60,K.current=setInterval(o,t)):30===r&&t>30&&(clearInterval(K.current),t=30,K.current=setInterval(o,t))};K.current=setInterval(o,t)},400))},[v,j,q]);i(()=>q,[q]);const Y=e=>({onPointerDown:t=>{if(void 0===t.button||0===t.button){t.preventDefault();try{t.currentTarget.setPointerCapture?.(t.pointerId)}catch(e){}J(e)}},onPointerUp:e=>{try{e.currentTarget.releasePointerCapture?.(e.pointerId)}catch(e){}q()},onPointerCancel:q,onPointerLeave:q,onKeyDown:t=>{"Enter"!==t.key&&" "!==t.key||t.repeat||(t.preventDefault(),J(e))},onKeyUp:e=>{"Enter"!==e.key&&" "!==e.key||q()},onBlur:q}),Z=e=>{const t=e.target.value;if(""===t||"-"===t)return void(z||C(t));const r=parseFloat(t);isNaN(r)||V(r)},$=e=>{"ArrowUp"===e.key&&(e.preventDefault(),j(1)),"ArrowDown"===e.key&&(e.preventDefault(),j(-1))},_={display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"var(--Buttons-"+P+"-Light-Button, transparent)",color:"var(--Buttons-"+P+"-Light-Text, var(--Text))",cursor:"pointer",outline:"none",flexShrink:0,border:"none",transition:"background-color 0.15s ease","&:hover":{backgroundColor:"var(--Buttons-"+P+"-Hover)"},"&:active":{backgroundColor:"var(--Buttons-"+P+"-Pressed)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px"},"&:disabled":{opacity:.4,cursor:"not-allowed"}},ee={},te=()=>F&&f?de(H,{component:"label",style:{display:"block",marginBottom:"6px",color:v?"var(--Quiet)":"var(--Text)",fontWeight:500,opacity:v?.6:1},children:f}):null;return ce(h,W?{className:"numberfield numberfield-outlined"+(v?" numberfield-disabled":"")+(S?" "+S:""),sx:{width:y?"100%":"auto",fontFamily:"inherit",...k},...B,children:[te(),de(h,{sx:{border:"1px solid "+L,borderRadius:"small"===m?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease",boxShadow:"none",opacity:v?.5:1,"&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{...ee,children:ce(h,{sx:{position:"relative",display:"flex",alignItems:"stretch",minHeight:N.height,backgroundColor:"var(--Hover)"},children:[D&&f&&de(h,{sx:{position:"absolute",top:E||T?"6px":"50%",left:"14px",transform:E||T?"scale(0.75)":"translateY(-50%)",transformOrigin:"top left",color:T?M:"var(--Quiet)",fontSize:N.fontSize,fontWeight:400,pointerEvents:"none",transition:"top 0.15s ease, transform 0.15s ease, color 0.15s ease",zIndex:1},children:f}),de(h,{component:"input",ref:A,type:"text",inputMode:"numeric",role:"spinbutton","aria-valuenow":"number"==typeof R?R:void 0,"aria-valuemin":l,"aria-valuemax":s,"aria-label":f||"Number",value:R,onChange:Z,onKeyDown:$,onFocus:()=>I(!0),onBlur:()=>I(!1),disabled:v,placeholder:D?void 0:x||"",sx:{flex:1,border:"none",outline:"none",backgroundColor:"transparent",color:E||T?M:"var(--Quiet)",fontSize:N.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)",padding:D?"22px 14px 6px":N.padding,minWidth:0,"&::placeholder":{color:"var(--Quiet)",opacity:1},"&:disabled":{cursor:"not-allowed"}}}),ce(h,{sx:{display:"flex",flexDirection:"column",borderLeft:"1px solid "+L},children:[de(h,{component:"button",type:"button","aria-label":"Increase",...Y(1),disabled:v||U,sx:{..._,flex:1,width:32,borderBottom:"1px solid "+L},children:de(jo,{size:"small",children:de(Nt,{})})}),de(h,{component:"button",type:"button","aria-label":"Decrease",...Y(-1),disabled:v||G,sx:{..._,flex:1,width:32},children:de(jo,{size:"small",children:de(Ht,{})})})]})]})})}),b&&de(ao,{style:{color:"var(--Quiet)",marginTop:"4px",marginLeft:"2px"},children:b})]}:{className:"numberfield numberfield-spinner"+(v?" numberfield-disabled":"")+(S?" "+S:""),sx:{fontFamily:"inherit",...k},...B,children:[te(),ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:"small"===m?.5:1,opacity:v?.5:1},children:[de(h,{component:"button",type:"button","aria-label":"Decrease",...Y(-1),disabled:v||G,sx:{..._,width:N.btnSize,height:N.btnSize,borderRadius:"small"===m?"var(--Sm-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"var(--Button-Icon-Radius, var(--Style-Border-Radius))",border:"1px solid "+L},children:de(jo,{size:"small",children:de(fe,{})})}),de(h,{sx:{border:"1px solid "+L,borderRadius:"small"===m?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{...ee,children:de(h,{component:"input",ref:A,type:"text",inputMode:"numeric",role:"spinbutton","aria-valuenow":"number"==typeof R?R:void 0,"aria-valuemin":l,"aria-valuemax":s,"aria-label":f||"Number",value:R,onChange:Z,onKeyDown:$,onFocus:()=>I(!0),onBlur:()=>I(!1),disabled:v,sx:{width:"small"===m?40:56,minHeight:N.height,textAlign:"center",border:"none",outline:"none",backgroundColor:"var(--Hover)",color:"var(--Text)",fontSize:N.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:600,"&:disabled":{cursor:"not-allowed"}}})})}),de(h,{component:"button",type:"button","aria-label":"Increase",...Y(1),disabled:v||U,sx:{..._,width:N.btnSize,height:N.btnSize,borderRadius:"small"===m?"var(--Sm-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"large"===m?"var(--Lg-Button-Icon-Radius, var(--Button-Icon-Radius, var(--Style-Border-Radius)))":"var(--Button-Icon-Radius, var(--Style-Border-Radius))",border:"1px solid "+L},children:de(jo,{size:"small",children:de(At,{})})})]}),b&&de(ao,{style:{color:"var(--Quiet)",marginTop:"4px",marginLeft:"2px"},children:b})]})}const pl=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",hl=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function ml({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function fl({color:e,selected:t,onClick:r}){const o=pl(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function gl(){const[e,t]=r("outlined"),[o,n]=r("outline"),[i,a]=r("default"),[l,s]=r("medium"),[d,c]=r("top"),[u,p]=r(!0),[m,f]=r(!1),[g,x]=r(!1),[b,v]=r(null),[y,S]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Number Field"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:b,surface:y,children:de(h,{sx:{width:"100%",maxWidth:"outlined"===e?300:"auto"},children:de(ul,{variant:e,style:o,color:i,size:l,label:u?"Quantity":void 0,labelPosition:d,min:0,max:100,disabled:m,fullWidth:g&&"outlined"===e})})}),de(Vi,{code:(()=>{const t=['variant="'+e+'"'];return"outline"!==o&&t.push('style="'+o+'"'),"default"!==i&&t.push('color="'+i+'"'),"medium"!==l&&t.push('size="'+l+'"'),u&&t.push('label="Quantity"'),"top"!==d&&t.push('labelPosition="'+d+'"'),t.push("min={0}"),t.push("max={100}"),m&&t.push("disabled"),g&&"outlined"===e&&t.push("fullWidth"),t.push("value={value}"),t.push("onChange={setValue}"),"<NumberField\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:b,onThemeChange:v,surface:y,onSurfaceChange:S})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"VARIANT"}),de(B,{direction:"row",spacing:1,children:["outlined","spinner"].map(r=>de(ml,{label:pl(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","light"].map(e=>de(ml,{label:pl(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:hl.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(fl,{color:e,selected:i===e,onClick:a},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(ml,{label:pl(e),selected:l===e,onClick:()=>s(e)},e))})]}),"outlined"===e&&ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL"}),de(B,{direction:"row",spacing:1,children:["top","floating","none"].map(e=>de(ml,{label:"none"===e?"None":pl(e),selected:d===e,onClick:()=>c(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Label"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Text label above field"})]}),de(ta,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Show label"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(ta,{variant:"default-outline",checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]}),"outlined"===e&&ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Full Width"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Stretch to container"})]}),de(ta,{variant:"default-outline",checked:g,onChange:e=>x(e.target.checked),size:"small","aria-label":"Full width"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="spinbutton" with aria-valuenow, aria-valuemin, aria-valuemax'},{label:"Label",value:"aria-label from label prop. Always provide a label."},{label:"Keyboard",value:"ArrowUp/Down increment/decrement. Direct text entry supported."},{label:"Steppers",value:'aria-label="Increase" / "Decrease" on stepper buttons'},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px"},{label:"Disabled",value:"HTML disabled. Steppers also disabled at min/max bounds."}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}function xl({children:e,selected:t=!1,onChange:r,value:o,sx:n={},...i}){return de(R,{value:o,selected:t,onChange:r,sx:{border:"1px solid var(--Border)",color:"var(--Text)",backgroundColor:t?"var(--Buttons-Primary-Button)":"transparent","&:hover":{backgroundColor:t?"var(--Buttons-Primary-Button)":"var(--Container-High)"},"&.Mui-selected":{backgroundColor:"var(--Buttons-Primary-Button)",color:"#fff","&:hover":{backgroundColor:"var(--Buttons-Primary-Button)"}},textTransform:"none",fontWeight:500,...n},...i,children:e})}const bl=["default","primary","secondary","tertiary","neutral","black-white","info","success","warning","error"],vl=["fill","outline","ghost"];function yl(){const e={};return bl.forEach(t=>{vl.forEach(r=>{e["fill"===r?t:t+"-"+r]=function(e,t){const r=pn(e),o={color:e,style:t,bg:"transparent",text:"var(--Quiet)",hover:"var(--Buttons-"+r+"-Hover)",hoverText:"var(--Buttons-"+r+"-Text)"};return"ghost"===t?{...o,border:"transparent",selectedBg:"transparent",selectedText:"var(--Buttons-"+r+"-Border)",selectedRing:"inset 0 0 0 2px var(--Buttons-"+r+"-Border)",bevel:!1}:"outline"===t?{...o,border:"var(--Buttons-"+r+"-Border)",selectedBg:"transparent",selectedText:"var(--Buttons-"+r+"-Border)",selectedRing:"inset 0 0 0 2px var(--Buttons-"+r+"-Border)",bevel:!1}:{...o,border:"var(--Buttons-"+r+"-Border)",selectedBg:"var(--Buttons-"+r+"-Button)",selectedText:"var(--Buttons-"+r+"-Text)",selectedRing:null,bevel:!0}}(t,r)})}),e}const Sl={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 10px",iconSize:16,gap:4,swatchRadius:"var(--Sm-Input-Swatch-Radius, 18px)"},medium:{height:"var(--Button-Height)",fontSize:"15px",padding:"6px 14px",iconSize:18,gap:6,swatchRadius:"var(--Input-Swatch-Radius, 26px)"},large:{height:"var(--Large-Button-Height)",fontSize:"17px",padding:"8px 18px",iconSize:20,gap:8,swatchRadius:"var(--Lg-Input-Swatch-Radius, 50px)"}};function kl({variant:e="primary",size:t="medium",value:r,defaultValue:o,onChange:n,exclusive:i=!0,orientation:a="horizontal",disabled:l=!1,fullWidth:s=!1,children:d,className:c="",sx:u={},"aria-label":p,...h}){const m=yl(),f=m[e]||m.default,g=Sl[t]||Sl.medium,x="vertical"===a,b={gap:0,border:"ghost"===f.style?"none":"1px solid "+f.border,borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",...s&&{width:"100%"},display:"grid",gridAutoFlow:x?"row":"column",...x?{gridAutoRows:"1fr"}:{gridAutoColumns:"1fr"},"& .MuiToggleButtonGroup-grouped":{margin:0,borderLeft:0,borderTop:0,"&.Mui-selected + &.Mui-selected":{marginLeft:0,marginTop:0,borderLeft:0,borderTop:0}},"& .MuiToggleButton-root":{height:g.height,fontSize:g.fontSize,padding:g.padding,fontFamily:"inherit",fontWeight:500,textTransform:"none",letterSpacing:"0",lineHeight:1.4,backgroundColor:f.bg,color:f.text,border:"none",borderRadius:0,transition:"background-color 0.15s ease, color 0.15s ease","& .tbtn-start, & .tbtn-end":{display:"inline-flex",alignItems:"center",flexShrink:0,"& > *":{width:g.iconSize,height:g.iconSize,display:"block"}},"& .tbtn-start":{marginRight:"2px"},"& .tbtn-end":{marginLeft:"2px"},"& .tbtn-swatch":{display:"block",flexShrink:0,width:g.iconSize,height:g.iconSize,borderRadius:g.swatchRadius,border:"1px solid var(--Border-Variant)"},"& .tbtn-swatch:not(:only-child)":{marginRight:"2px"},"--_height":g.height,"--_bevel":"var(--Button-Bevel-Px, min(calc(var(--Button-Bevel, 0) * var(--_height) / 100), calc(var(--_height) / 5)))",...s&&{flex:1},..."ghost"===f.style?{}:x?{"&:not(:last-of-type)":{borderBottom:"1px solid "+f.border}}:{"&:not(:last-of-type)":{borderRight:"1px solid "+f.border}},"&:hover":{backgroundColor:f.hover,color:f.hoverText},"&.Mui-selected":{backgroundColor:f.selectedBg,color:f.selectedText,...f.bevel?{boxShadow:mn(f.color)}:{},...f.selectedRing?{boxShadow:f.selectedRing}:{}},"&.Mui-selected:hover":{backgroundColor:f.selectedBg,color:f.selectedText,...f.bevel?{boxShadow:mn(f.color)}:{},...f.selectedRing?{boxShadow:f.selectedRing}:{}},"&.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"-2px",zIndex:1},"&.Mui-disabled":{opacity:.6,color:f.text,backgroundColor:f.bg},"&.Mui-disabled.Mui-selected":{opacity:.6,backgroundColor:f.selectedBg,color:f.selectedText},"& .MuiSvgIcon-root":{fontSize:g.iconSize},"& > *:not(:only-child)":{marginRight:g.gap/2,marginLeft:g.gap/2}},...u};return de(E,{value:r,defaultValue:o,onChange:n,exclusive:i,orientation:a,disabled:l,className:"toggle-group-"+e+" "+c,sx:b,"aria-label":p,...h,children:d})}const Bl=e=>de(kl,{variant:"default",...e}),wl=e=>de(kl,{variant:"primary",...e}),Cl=e=>de(kl,{variant:"secondary",...e}),Tl=e=>de(kl,{variant:"tertiary",...e}),Il=e=>de(kl,{variant:"neutral",...e}),Al=e=>de(kl,{variant:"black-white",...e}),zl=e=>de(kl,{variant:"info",...e}),Rl=e=>de(kl,{variant:"success",...e}),El=e=>de(kl,{variant:"warning",...e}),Pl=e=>de(kl,{variant:"error",...e});function Ol({label:e,value:t="",onChange:o,placeholder:n,error:i=!1,errorMessage:a="",disabled:l=!1,helperText:s="",variant:d="outlined",size:c="medium",type:u="text",required:p=!1,fullWidth:m=!0,startAdornment:f,endAdornment:g,sx:x={},"aria-label":b,"aria-labelledby":v,...B}){const[w,C]=r(!1),T=i?"var(--Buttons-Error-Border)":w?"var(--Buttons-Primary-Border)":"var(--Border)",I=i||w?"var(--Text)":"var(--Text-Quiet)",A="var(--Text)";return ce(h,{sx:{width:m?"100%":"auto"},children:[de(y,{label:e,value:t,onChange:o,placeholder:n,disabled:l,variant:d,size:c,type:u,required:p,onFocus:()=>C(!0),onBlur:()=>C(!1),error:i,fullWidth:m,slotProps:{htmlInput:{...b?{"aria-label":b}:{},...v?{"aria-labelledby":v}:{}},input:{"data-surface":l?"Container-Low":"Container",style:{color:A},startAdornment:f?de(S,{position:"start",children:f}):void 0,endAdornment:g?de(S,{position:"end",children:g}):void 0}},sx:{width:m?"100%":"auto","& .MuiOutlinedInput-root":{backgroundColor:"var(--Background)",transition:"all 0.2s ease-in-out",color:A,"& fieldset":{borderColor:T,transition:"border-color 0.2s ease-in-out"},"&:hover fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)"},"&.Mui-focused fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)",borderWidth:"2px"},"&.Mui-disabled":{backgroundColor:"var(--Background)",opacity:.6}},"& .MuiInputLabel-root":{color:I,transition:"all 0.2s ease-in-out",fontSize:"14px",fontWeight:500,"&.Mui-focused":{color:"var(--Text)",fontWeight:600},"&.Mui-error":{color:"var(--Text)"},"&.Mui-disabled":{color:"var(--Text-Secondary)",opacity:.6}},"& .MuiFormHelperText-root":{color:i?"var(--Buttons-Error-Border)":"var(--Text-Secondary)",marginTop:"4px",fontSize:"12px"},...x},...B}),i&&a&&de(k,{error:!0,sx:{color:"var(--Buttons-Error-Border)",marginTop:"4px",fontSize:"12px",fontWeight:500},children:a})]})}function Ll({label:e="Email",...t}){return de(Ol,{label:e,type:"email",placeholder:"user@example.com",...t})}function Ml({label:e="Password",...t}){return de(Ol,{label:e,type:"password",...t})}function Wl({label:e="Search",placeholder:t="Type to search...",...r}){return de(Ol,{label:e,type:"search",placeholder:t,...r})}function Dl({label:e="Number",...t}){return de(Ol,{label:e,type:"number",...t})}function Fl({label:e="Phone",placeholder:t="(555) 123-4567",...r}){return de(Ol,{label:e,type:"tel",placeholder:t,...r})}function Nl({label:e="Website",placeholder:t="https://example.com",...r}){return de(Ol,{label:e,type:"url",placeholder:t,...r})}function Hl({label:e,value:t="",onChange:o,placeholder:n,error:i=!1,errorMessage:a="",disabled:l=!1,helperText:s="",rows:d=4,required:c=!1,fullWidth:u=!0,sx:p={},...m}){const[f,g]=r(!1);return ce(h,{sx:{width:u?"100%":"auto"},children:[de(y,{label:e,value:t,onChange:o,placeholder:n,disabled:l,variant:"outlined",multiline:!0,rows:d,required:c,fullWidth:u,onFocus:()=>g(!0),onBlur:()=>g(!1),error:i,slotProps:{input:{"data-surface":l?"Container-Low":"Container",style:{color:"var(--Text)"}}},sx:{width:u?"100%":"auto","& .MuiOutlinedInput-root":{backgroundColor:"var(--Background)",transition:"all 0.2s ease-in-out",color:"var(--Text)","& fieldset":{borderColor:i?"var(--Buttons-Error-Border)":f?"var(--Buttons-Primary-Border)":"var(--Border)",transition:"border-color 0.2s ease-in-out"},"&:hover fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)"},"&.Mui-focused fieldset":{borderColor:i?"var(--Buttons-Error-Border)":"var(--Buttons-Primary-Border)",borderWidth:"2px"},"&.Mui-disabled":{backgroundColor:"var(--Background)",opacity:.6}},"& .MuiInputLabel-root":{color:i||f?"var(--Text)":"var(--Text-Quiet)",transition:"all 0.2s ease-in-out",fontSize:"14px",fontWeight:500,"&.Mui-focused":{color:"var(--Text)",fontWeight:600},"&.Mui-error":{color:"var(--Text)"},"&.Mui-disabled":{color:"var(--Text-Secondary)",opacity:.6}},...p},...m}),i&&a&&de(k,{error:!0,sx:{color:"var(--Buttons-Error-Border)",marginTop:"4px",fontSize:"12px",fontWeight:500},children:a})]})}function Vl({fields:e=[],spacing:t=2,sx:r={},...o}){return de(h,{sx:{display:"flex",flexDirection:"column",gap:`var(--Spacing-${t})`,width:"100%",...r},...o,children:e.map(e=>de(Ol,{...e},e.id))})}const Ql=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",jl=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Gl=[{value:"apple",label:"Apple"},{value:"banana",label:"Banana"},{value:"cherry",label:"Cherry"},{value:"date",label:"Date"},{value:"elderberry",label:"Elderberry"}],Ul=[{value:"primary",label:"Primary",color:"var(--Buttons-Primary-Button)"},{value:"secondary",label:"Secondary",color:"var(--Buttons-Secondary-Button)"},{value:"tertiary",label:"Tertiary",color:"var(--Buttons-Tertiary-Button)"},{value:"neutral",label:"Neutral",color:"var(--Buttons-Neutral-Button)"},{value:"info",label:"Info",color:"var(--Buttons-Info-Button)"},{value:"success",label:"Success",color:"var(--Buttons-Success-Button)"},{value:"warning",label:"Warning",color:"var(--Buttons-Warning-Button)"},{value:"error",label:"Error",color:"var(--Buttons-Error-Button)"}];function Xl({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Kl({color:e,selected:t,onClick:r}){const o=Ql(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function ql(){const[e,t]=r("outline"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r("top"),[d,c]=r("Fruit"),[u,p]=r(!1),[m,f]=r(!1),[g,x]=r(!0),[b,v]=r(!1),[y,S]=r("Search"),[k,w]=r(""),[C,T]=r(null),[A,z]=r("Surface"),[R,E]=r(!1),[P,O]=r(!0);return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Select"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:C,surface:A,children:de(h,{sx:{width:"100%",maxWidth:360},children:de($n,{variant:e,color:o,size:i,label:d,labelPosition:l,mode:R?"color":void 0,showColorLabels:R?P:void 0,options:R?Ul:Gl,value:k,onChange:w,showDividers:u,disabled:m,fullWidth:g,startDecoration:b?(()=>{const e=zt[y]||zt.Search;return de(jo,{size:"small",children:de(e,{})})})():void 0})})}),de(Vi,{code:(()=>{const t=[];return"outline"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),d&&t.push('label="'+d+'"'),"top"!==l&&t.push('labelPosition="'+l+'"'),R&&t.push('mode="color"'),R&&!P&&t.push("showColorLabels={false}"),u&&t.push("showDividers"),m&&t.push("disabled"),g&&t.push("fullWidth"),b&&t.push("startDecoration={<Icon><"+y+"Icon /></Icon>}"),t.push("options={options}"),t.push("value={value}"),t.push("onChange={setValue}"),"<Select\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:C,onThemeChange:T,surface:A,onSurfaceChange:z})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","light"].map(r=>de(Xl,{label:Ql(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:jl.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Kl,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Xl,{label:Ql(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL"}),de(B,{direction:"row",spacing:1,children:["top","floating","none"].map(e=>de(Xl,{label:"none"===e?"None":Ql(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Start Icon"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Icon rendered before the value"})]}),de(ta,{checked:b,onChange:e=>v(e.target.checked),size:"small","aria-label":"Start icon"})]}),b&&ce(h,{sx:{mt:2},children:[de(qn,{label:"Icon Name",value:y,onChange:e=>S(e.target.value),placeholder:"Search",variant:"primary-outline",size:"small",fullWidth:!0}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:[de("a",{href:"https://mui.com/material-ui/material-icons/",target:"_blank",rel:"noopener noreferrer",style:{color:"var(--Hotlink)"},children:"Material icon"})," name (e.g. Search, Add, Edit, Filter, Sort, Star)"]})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Dividers"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Lines between options"})]}),de(ta,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Show dividers"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(ta,{checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Color Mode"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Render swatches alongside each option. Swatch size scales to Select height, radius follows the brand's button radius."})]}),de(ta,{checked:R,onChange:e=>E(e.target.checked),size:"small","aria-label":"Color mode"})]}),R&&ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Color Labels"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Hide to render a swatch-only trigger (no text). Useful for compact color pickers."})]}),de(ta,{checked:P,onChange:e=>O(e.target.checked),size:"small","aria-label":"Show color labels"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Full Width"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Stretch to container width"})]}),de(ta,{checked:g,onChange:e=>x(e.target.checked),size:"small","aria-label":"Full width"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Trigger",value:'role="combobox" aria-expanded="true|false" aria-haspopup="listbox"'},{label:"Dropdown",value:'role="listbox" aria-label="..."'},{label:"Options",value:'role="option" aria-selected="true|false"'},{label:"Label",value:"aria-label from label prop. Always provide a label."},{label:"Keyboard",value:"Enter/Space opens. Escape closes. Arrow keys when open."},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px (on outer shell)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Jl={small:{height:"var(--Small-Button-Height)",fontSize:"13px",padding:"4px 8px",iconSize:16},medium:{height:"var(--Button-Height)",fontSize:"14px",padding:"6px 12px",iconSize:18},large:{height:"var(--Large-Button-Height)",fontSize:"16px",padding:"8px 16px",iconSize:20}},Yl={small:{height:"48px",fontSize:"13px",padding:"20px 12px 4px",leftPad:12},medium:{height:"56px",fontSize:"14px",padding:"22px 14px 6px",leftPad:14},large:{height:"64px",fontSize:"16px",padding:"24px 16px 6px",leftPad:16}};function Zl({options:e=[],value:t,defaultValue:a=null,onChange:l,inputValue:s,onInputChange:d,label:c,labelPosition:u="top",placeholder:p="Type to search",helperText:m,size:f="medium",variant:g="outline",color:x="primary",loading:b=!1,loadingText:v="Loading…",noOptionsText:y="No options",freeSolo:S=!1,clearable:k=!0,disabled:B=!1,fullWidth:w=!1,className:C="",sx:T={},...I}){const A=(z="default"===x?"primary":x).charAt(0).toUpperCase()+z.slice(1);var z;const R="var(--Buttons-"+A+"-Border)",E="default"===x?"var(--Text)":"var(--Text-"+A+")",[P,O]=r(a),[L,M]=r(a?"string"==typeof a?a:a.label||"":""),[W,D]=r(!1),[F,N]=r(!1),[H,V]=r(-1),Q=o(null),j=o(null),G=void 0!==t,U=void 0!==s,X=G?t:P,K=U?s:L,q="floating"===u,J="top"===u,Y=""!==K,Z=q?Yl[f]||Yl.medium:Jl[f]||Jl.medium,$=K?e.filter(e=>("string"==typeof e?e:e.label).toLowerCase().includes(K.toLowerCase())):e,_=n(e=>{U||M(e),d?.(e)},[U,d]),ee=n(e=>{const t="string"==typeof e?e:e.label;G||O(e),_(t),l?.(e),D(!1),V(-1),j.current?.focus()},[G,l,_]);i(()=>{if(!W)return;const e=e=>{Q.current&&!Q.current.contains(e.target)&&D(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[W]);return ce(h,{ref:Q,className:"autocomplete autocomplete-"+f+" autocomplete-variant-"+g+(W?" autocomplete-open":"")+(B?" autocomplete-disabled":"")+(C?" "+C:""),sx:{position:"relative",width:w?"100%":"auto",display:"inline-block",fontFamily:"inherit",...T},...I,children:[J&&c&&de("small"===f?ao:co,{component:"label",style:{display:"block",marginBottom:"6px",color:B?"var(--Quiet)":"var(--Text)",fontWeight:500,opacity:B?.6:1},children:c}),de(h,{sx:{border:"1px solid "+R,borderRadius:"small"===f?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===f?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",transition:"border-color 0.15s ease",boxShadow:"none",opacity:B?.5:1,"&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(h,{children:ce(h,{sx:{position:"relative",display:"flex",alignItems:"center",minHeight:Z.height,backgroundColor:"var(--Hover)"},children:[q&&c&&de(h,{sx:{position:"absolute",top:Y||F?"6px":"50%",left:(Z.leftPad||14)+"px",transform:Y||F?"scale(0.75)":"translateY(-50%)",transformOrigin:"top left",color:F?E:"var(--Quiet)",fontSize:Z.fontSize,fontWeight:400,pointerEvents:"none",zIndex:1,transition:"top 0.15s ease, transform 0.15s ease, color 0.15s ease"},children:c}),de(h,{component:"input",ref:j,type:"text",role:"combobox","aria-expanded":W,"aria-haspopup":"listbox","aria-autocomplete":"list","aria-label":c||p,autoComplete:"off",value:K,onChange:e=>{_(e.target.value),W||D(!0),V(-1)},onKeyDown:e=>{if("Escape"!==e.key){if("ArrowDown"===e.key){if(e.preventDefault(),!W)return void D(!0);V(e=>Math.min(e+1,$.length-1))}"ArrowUp"===e.key&&(e.preventDefault(),V(e=>Math.max(e-1,0))),"Enter"===e.key&&W&&H>=0&&$[H]&&(e.preventDefault(),ee($[H]))}else D(!1)},onFocus:()=>{N(!0),D(!0)},onBlur:()=>N(!1),disabled:B,placeholder:q?void 0:p,sx:{flex:1,border:"none",outline:"none",backgroundColor:"transparent",color:Y||F?E:"var(--Quiet)",fontSize:Z.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)",padding:Z.padding,minWidth:0,"&::placeholder":{color:"var(--Quiet)",opacity:1,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)"},"&:disabled":{cursor:"not-allowed"}}}),b&&W&&de(Vt,{size:16,sx:{mr:1,color:"var(--Quiet)"}}),k&&K&&!B&&de(h,{component:"button",type:"button","aria-label":"Clear",onClick:()=>{G||O(null),_(""),l?.(null),j.current?.focus()},sx:{display:"flex",alignItems:"center",justifyContent:"center",width:20,height:20,borderRadius:"50%",mr:.5,border:"none",backgroundColor:"transparent",color:"var(--Quiet)",cursor:"pointer","&:hover":{color:"var(--Text)",backgroundColor:"var(--Hover)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)"}},children:de(Ot,{sx:{fontSize:14}})}),de(h,{component:"button",type:"button","aria-label":W?"Close":"Open",tabIndex:-1,onClick:()=>{B||D(!W)},sx:{display:"flex",alignItems:"center",justifyContent:"center",width:28,height:"100%",border:"none",backgroundColor:"transparent",color:"var(--Quiet)",cursor:B?"not-allowed":"pointer"},children:de(Se,{sx:{fontSize:(Z.iconSize||18)+"px",transform:W?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"}})})]})})}),m&&de(h,{sx:{fontSize:"12px",color:"var(--Quiet)",mt:"4px",ml:"2px"},children:m}),W&&de(h,{role:"listbox","aria-label":c||"Options",sx:{position:"absolute",top:"100%",left:0,right:0,mt:.5,backgroundColor:"var(--Hover)",border:"1px solid var(--Buttons-Default-Border)",borderRadius:"var(--Style-Border-Radius)",boxShadow:"none",zIndex:9999,maxHeight:240,overflowY:"auto",py:.5},children:b?de(h,{sx:{px:1.5,py:2,textAlign:"center",fontSize:Z.fontSize,color:"var(--Quiet)"},children:v}):0===$.length?de(h,{sx:{px:1.5,py:2,textAlign:"center",fontSize:Z.fontSize,color:"var(--Quiet)"},children:y}):$.map((e,t)=>{const r="string"==typeof e?e:e.label,o="string"==typeof e?e:e.value,n=r===(X?"string"==typeof X?X:X.label:null),i=function(e,t){return t?{backgroundColor:"transparent",color:"var(--Text)",fontWeight:600}:e?{backgroundColor:"var(--Hover)",color:"var(--Text)"}:{backgroundColor:"transparent",color:"var(--Text-Quiet)"}}(t===H,n);return ce(h,{role:"option","aria-selected":n,onClick:()=>ee(e),onMouseEnter:()=>V(t),sx:{display:"flex",alignItems:"center",gap:1,px:1.5,py:0,mx:.5,minHeight:Z.height,borderRadius:"4px",cursor:"pointer",fontSize:Z.fontSize,fontFamily:"inherit",...i,transition:"background-color 0.1s ease","&:active":{backgroundColor:"var(--Pressed)"}},children:[de(ao,{style:{flex:1,color:"inherit",fontWeight:"inherit"},children:r}),n&&de(jo,{size:"small",sx:{opacity:.6,flexShrink:0},children:de(he,{})})]},o||r)})})]})}const $l=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",_l=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],es=[{value:"apple",label:"Apple"},{value:"banana",label:"Banana"},{value:"cherry",label:"Cherry"},{value:"date",label:"Date"},{value:"elderberry",label:"Elderberry"},{value:"fig",label:"Fig"},{value:"grape",label:"Grape"}];function ts({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function rs({color:e,selected:t,onClick:r}){const o=$l(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function os(){const[e,t]=r("outline"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r("top"),[d,c]=r("Fruit"),[u,p]=r(!0),[m,f]=r(!1),[g,x]=r(!0),[b,v]=r(null),[y,S]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Autocomplete"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:b,surface:y,children:de(h,{sx:{width:"100%",maxWidth:360},children:de(Zl,{variant:e,color:o,size:i,label:d,labelPosition:l,options:es,clearable:u,disabled:m,fullWidth:g})})}),de(Vi,{code:(()=>{const t=[];return"outline"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),d&&t.push('label="'+d+'"'),"top"!==l&&t.push('labelPosition="'+l+'"'),u||t.push("clearable={false}"),m&&t.push("disabled"),g&&t.push("fullWidth"),t.push("options={options}"),t.push("onChange={handleChange}"),"<Autocomplete\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:b,onThemeChange:v,surface:y,onSurfaceChange:S})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","light"].map(r=>de(ts,{label:$l(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:_l.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(rs,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(ts,{label:$l(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL"}),de(B,{direction:"row",spacing:1,children:["top","floating","none"].map(e=>de(ts,{label:"none"===e?"None":$l(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clearable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show clear button when has value"})]}),de(ta,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Clearable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(ta,{checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Disabled"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Full Width"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Stretch to container width"})]}),de(ta,{checked:g,onChange:e=>x(e.target.checked),size:"small","aria-label":"Full width"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Input",value:'role="combobox" aria-expanded aria-haspopup="listbox" aria-autocomplete="list"'},{label:"Dropdown",value:'role="listbox" aria-label="..."'},{label:"Options",value:'role="option" aria-selected="true|false"'},{label:"Label",value:"aria-label from label prop. Always provide a label."},{label:"Keyboard",value:"Arrow keys navigate, Enter selects, Escape closes."},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px (on outer shell)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const ns=["default","primary","secondary","tertiary","neutral","info","success","warning","error","black-white"],is=pn,as={small:{touchTarget:24,box:16,dot:8,gap:4,LabelComp:ao},medium:{touchTarget:24,box:20,dot:9.5,gap:8,LabelComp:co},large:{touchTarget:24,box:24,dot:9.5,gap:12,LabelComp:fo}};function ls({size:e,color:t,checked:r}){const o=is(t),n="Default"===o?"var(--Quiet)":"var(--Buttons-"+o+"-Border)",i="var(--Buttons-"+o+"-Border)",a=as[e]||as.medium;return de(h,{className:"radio-circle-icon",sx:{width:a.box,height:a.box,boxSizing:"border-box",borderRadius:"50%",border:"2px solid "+n,overflow:"hidden",flexShrink:0,backgroundColor:"var(--Background)",display:"flex",alignItems:"center",justifyContent:"center",transition:"border-color 0.15s ease-in-out"},children:r&&de(h,{sx:{width:a.dot,height:a.dot,borderRadius:"50%",backgroundColor:i,transition:"transform 0.15s ease-in-out"}})})}function ss({color:e="primary",size:t="medium",label:r,labelPlacement:o="end",checked:n,disabled:i=!1,onChange:a,name:l,value:s,className:d="",sx:c={},"aria-label":u,"aria-labelledby":p,"aria-describedby":h,inputProps:m={},...f}){const g=ns.includes(e)?e:"primary",x=as[t]||as.medium,b=x.LabelComp,y=(x.touchTarget-x.box)/2,S={...m,...u&&{"aria-label":u},...p&&{"aria-labelledby":p},...h&&{"aria-describedby":h}},k=de(P,{checked:n,disabled:i,onChange:a,name:l,value:s,icon:de(ls,{size:t,color:g,checked:!1}),checkedIcon:de(ls,{size:t,color:g,checked:!0}),className:"radio-"+g+" "+d,inputProps:S,disableRipple:!0,sx:{padding:y+"px",width:x.touchTarget,height:x.touchTarget,minWidth:x.touchTarget,minHeight:x.touchTarget,boxSizing:"border-box",borderRadius:"50%",color:"inherit",transition:"background-color 0.15s ease-in-out","&.Mui-checked":{color:"inherit"},"&:hover":{backgroundColor:"transparent"},"&.Mui-focusVisible .radio-circle-icon":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none"},...c},...f});return r?de(v,{control:k,label:de(b,{component:"span",sx:{color:i?"var(--Text-Quiet)":"var(--Text)",lineHeight:1.4,userSelect:"none"},children:r}),labelPlacement:o,disabled:i,sx:{marginLeft:0,marginRight:0,gap:x.gap+"px",alignItems:"center","&.Mui-disabled .MuiTypography-root":{color:"var(--Text-Quiet)",opacity:.6}}}):k}function ds({color:e="primary",size:t="medium",label:r,options:o=[],value:n,onChange:i,orientation:a="vertical",labelPlacement:l="end",disabled:s=!1,spacing:d=1,name:c,className:u="",sx:p={},"aria-label":h,"aria-labelledby":m,...f}){return ce(O,{component:"fieldset",disabled:s,className:"radio-group-"+e+" "+u,sx:p,children:[r&&de(L,{component:"legend",sx:{color:s?"var(--Text-Quiet)":"var(--Text)",fontSize:"small"===t?"13px":"15px",fontWeight:500,mb:1,"&.Mui-focused":{color:"var(--Text)"},"&.Mui-disabled":{color:"var(--Text-Quiet)",opacity:.6}},children:r}),de(M,{value:n,onChange:i,name:c,"aria-label":h,"aria-labelledby":m,row:"horizontal"===a,sx:{display:"flex",flexDirection:"horizontal"===a?"row":"column",flexWrap:"horizontal"===a?"wrap":"nowrap",alignItems:"horizontal"===a?"center":"flex-start",gap:d},...f,children:o.map(r=>de(ss,{color:e,size:t,label:r.label,labelPlacement:l,value:r.value,disabled:r.disabled||s},r.value))})]})}const cs=ss,us=["default","primary","secondary","tertiary","neutral","info","success","warning","error"];const ps={small:{visual:12,track:2,labelSize:11},medium:{visual:16,track:4,labelSize:12},large:{visual:20,track:6,labelSize:13}};function hs({variant:e="primary",size:t="medium",value:r,defaultValue:o,onChange:n,onChangeCommitted:i,min:a=0,max:l=100,step:s=1,marks:d=!1,valueLabelDisplay:c="off",orientation:u="horizontal",track:p="normal",disabled:m=!1,label:f,name:g,className:x="",sx:b={},"aria-label":v,"aria-labelledby":y,...S}){const k=function(){const e={};return us.forEach(t=>{e[t]=function(e){const t=(r=e).charAt(0).toUpperCase()+r.slice(1);var r;return{thumb:"var(--Buttons-"+t+"-Button)",thumbBorder:"1px solid var(--Buttons-"+t+"-Border)",track:"var(--Buttons-"+t+"-Button)",trackBorder:"1px solid var(--Buttons-"+t+"-Border)",rail:"var(--Border-Variant)",valueLabel:"var(--Buttons-"+t+"-Text)",valueLabelText:"var(--Buttons-"+t+"-Button)"}}(t)}),e}(),B=k[e]||k.primary,w=ps[t]||ps.medium,C="vertical"===u,T=Array.isArray(r)||Array.isArray(o),I="inverted"===p,A="small"===t?ao:co,z=w.track+2,R=I?B.track:B.rail,E=I?B.trackBorder:null,P=I?B.rail:B.track,O=I?null:B.trackBorder,L={color:"transparent"===B.track?B.thumb:B.track,height:C?void 0:z,width:C?z:void 0,"& .MuiSlider-rail":{backgroundColor:R,border:E||"none",boxSizing:E?"content-box":"border-box",opacity:1,height:C?void 0:E?w.track:z,width:C?E?w.track:z:void 0,borderRadius:z/2},"& .MuiSlider-track":{boxSizing:O?"content-box":"border-box",backgroundColor:P,border:O||"none",height:C?void 0:O?w.track:z,width:C?O?w.track:z:void 0,borderRadius:z/2},"& .MuiSlider-thumb":{width:24,height:24,backgroundColor:"transparent",border:"none",boxShadow:"none",transition:"none","--_height":w.visual+"px","--_bevel":"min(calc(var(--Button-Bevel) * var(--_height) / 100), calc(var(--_height) / 5))","&::after":{display:"none"},"&::before":{content:'""',position:"absolute",width:w.visual,height:w.visual,borderRadius:"50%",backgroundColor:B.thumb,border:B.thumbBorder||"none",boxShadow:`${mn(e)}, ${nn}`,transition:"box-shadow 0.15s ease-in-out",top:"50%",left:"50%",transform:"translate(-50%, -50%)"},"&:hover::before":{boxShadow:`${mn(e)}, ${an}`},"&.Mui-active::before":{boxShadow:mn(e)},"&.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px",borderRadius:"50%"},"&.Mui-focusVisible::before":{boxShadow:`${mn(e)}, ${an}`}},...T?C?{'& .MuiSlider-thumb[data-index="0"]::before':{top:0,left:"50%",transform:"translateX(-50%)"},'& .MuiSlider-thumb[data-index="1"]::before':{top:"auto",bottom:0,left:"50%",transform:"translateX(-50%)"}}:{'& .MuiSlider-thumb[data-index="0"]::before':{left:"auto",right:0,top:"50%",transform:"translateY(-50%)"},'& .MuiSlider-thumb[data-index="1"]::before':{left:0,right:"auto",top:"50%",transform:"translateY(-50%)"}}:{},"& .MuiSlider-valueLabel":{backgroundColor:B.valueLabel,color:B.valueLabelText,fontSize:w.labelSize,fontWeight:600,borderRadius:"6px",padding:"2px 8px","&::before":{backgroundColor:B.valueLabel}},"& .MuiSlider-mark":{backgroundColor:B.rail,width:C?z:2,height:C?2:z,borderRadius:1},"& .MuiSlider-markActive":{backgroundColor:B.thumb,opacity:.6},"& .MuiSlider-markLabel":{color:"var(--Text-Quiet)",fontSize:w.labelSize},"&.Mui-disabled":{opacity:.6,cursor:"not-allowed",pointerEvents:"none","& .MuiSlider-thumb::before":{boxShadow:"none"}},...b},M=de(W,{value:r,defaultValue:o,onChange:n,onChangeCommitted:i,min:a,max:l,step:s,marks:d,valueLabelDisplay:c,orientation:u,track:"inverted"===p?"inverted":!1!==p&&"normal",disabled:m,name:g,"aria-label":v,"aria-labelledby":y,className:"slider-"+e+" "+x,sx:L,...S});return f?ce(h,{sx:{width:C?"auto":"100%",height:C?"100%":"auto",display:"flex",flexDirection:"column",gap:"4px"},children:[de(A,{component:"label",sx:{color:m?"var(--Text-Quiet)":"var(--Text)",fontSize:"small"===t?"13px":"15px",fontWeight:500,opacity:m?.6:1},children:f}),M]}):M}const ms=hs,fs=hs,gs={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},xs={small:{iconSize:16,minHit:24,gap:0,focusInset:-3,focusWidth:3},medium:{iconSize:24,minHit:24,gap:0,focusInset:-3,focusWidth:3},large:{iconSize:36,minHit:void 0,gap:2,focusInset:2,focusWidth:2}};function bs({value:e,defaultValue:t,onChange:o,max:n=5,precision:i=1,color:a="default",size:l="medium",readOnly:s=!1,disabled:d=!1,emptyLabel:c="No rating",className:u="",sx:p={},...m}){const[f,g]=r(t??null),[x,b]=r(null),v=void 0!==e,y=v?e:f,S=null!==x?x:y,k=.5===i,B=!s&&!d,w=gs[a]||gs.default,C=xs[l]||xs.medium,T="var(--Buttons-"+w+"-Button)",I="var(--Buttons-"+w+"-Border)",A=e=>{if(!B)return;const t=e===y?null:e;v||g(t),o?.(t)},z=(e,t)=>{if(!B||!k)return;b(t?e+.5:e+1)},R=B?{"&:hover":{filter:"drop-shadow(0 2px 4px rgba(var(--Dropshadow-Color), 0.22)) drop-shadow(0 1px 2px rgba(var(--Dropshadow-Color), 0.28))","& .MuiSvgIcon-root":{stroke:"var(--Buttons-"+w+"-Border)",strokeWidth:1}}}:{},E=e=>{const t=e+1,r=e+.5,o=null!==S&&t<=S,a=null!==S&&!o&&k&&r<=S,l=a?Qt:Ie,s=((e,t)=>e||t?{color:T,filter:"drop-shadow(0 1px 2px rgba(var(--Dropshadow-Color), 0.28))",transition:"filter 0.15s ease","& .MuiSvgIcon-root":{stroke:I,strokeWidth:.5}}:{color:"transparent","& .MuiSvgIcon-root":{stroke:"var(--Quiet)",strokeWidth:1}})(o,a);return k&&B?ce(h,{sx:{position:"relative",display:"inline-flex",cursor:"pointer",...s,...R},onMouseLeave:()=>b(null),children:[de(h,{sx:{position:"absolute",left:0,top:0,width:"50%",height:"100%",zIndex:1,cursor:"pointer"},onMouseEnter:()=>z(e,!0),onClick:()=>A(r)}),de(h,{sx:{position:"absolute",right:0,top:0,width:"50%",height:"100%",zIndex:1,cursor:"pointer"},onMouseEnter:()=>z(e,!1),onClick:()=>A(t)}),de(l,{sx:{fontSize:C.iconSize,transition:"color 0.1s ease, filter 0.1s ease"}})]},e):de(h,{component:B?"button":"span",type:B?"button":void 0,role:B?"radio":void 0,"aria-checked":o,"aria-label":t+" star"+(1!==t?"s":""),tabIndex:B?0:-1,onClick:()=>A(t),onMouseEnter:()=>B&&b(t),onMouseLeave:()=>B&&b(null),onKeyDown:e=>{if(B&&("ArrowRight"!==e.key&&"ArrowUp"!==e.key||(e.preventDefault(),A(Math.min((y||0)+i,n))),"ArrowLeft"===e.key||"ArrowDown"===e.key)){e.preventDefault();const t=Math.max((y||0)-i,0);A(t||null)}},sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",border:"none",backgroundColor:"transparent",padding:0,...C.minHit&&{minWidth:C.minHit+"px",minHeight:C.minHit+"px"},cursor:d?"not-allowed":B?"pointer":"default",outline:"none",transition:"transform 0.1s ease",...s,...R,"&:active":B?{transform:"scale(0.95)"}:{},"&:focus-visible":B?{outline:C.focusWidth+"px solid var(--Focus-Visible)",outlineOffset:C.focusInset+"px",borderRadius:"2px"}:{},"&:disabled":{cursor:"not-allowed",opacity:.5}},children:de(l,{sx:{fontSize:C.iconSize,transition:"color 0.1s ease, filter 0.1s ease"}})},e)};return ce(h,{role:B?"radiogroup":"img","aria-label":"Rating"+(null!==y?": "+y+" of "+n+" stars":": "+c),className:"rating rating-"+a+" rating-"+l+(s?" rating-readonly":"")+(d?" rating-disabled":"")+(null===y?" rating-empty":"")+(u?" "+u:""),sx:{display:"inline-flex",alignItems:"center",gap:C.gap+"px",opacity:d?.5:1,fontFamily:"inherit",...p},...m,children:[Array.from({length:n},(e,t)=>E(t)),null===y&&!x&&de(bo,{style:{color:"var(--Quiet)",marginLeft:4},children:c})]})}const vs={small:{height:"var(--Small-Button-Height)",fontSize:"13px",iconSize:18,px:12},medium:{height:"var(--Button-Height)",fontSize:"14px",iconSize:20,px:16},large:{height:"var(--Large-Button-Height)",fontSize:"15px",iconSize:22,px:16}};function ys({value:e,defaultValue:t="",onChange:n,onFocus:i,onBlur:a,onClear:l,onSubmit:s,placeholder:d="Search…",size:c="medium",color:u="default",showClearButton:p=!0,disabled:m=!1,ariaLabel:f="Search",className:g="",sx:x={},...b}){const[v,y]=r(t),[S,k]=r(!1),B=o(null),w=void 0!==e,C=w?e:v,T=C.length>0,I=S||T,A=(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===u?"primary":u),z="default"===u?"var(--Text)":"var(--Text-"+A+")",R=vs[c]||vs.medium,E=()=>{w||y(""),n?.(""),l?.(),B.current?.focus()};return de(h,{className:"search-field search-field-"+c+(S?" search-field-focused":"")+(T?" search-field-filled":"")+(m?" search-field-disabled":"")+(g?" "+g:""),sx:{display:"flex",boxSizing:"border-box",...x},...b,children:de(h,{sx:{border:"1px solid "+("var(--Buttons-"+A+"-Border)"),borderRadius:"small"===c?"var(--Sm-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"large"===c?"var(--Lg-Input-Radius, var(--Input-Radius, var(--Style-Border-Radius)))":"var(--Input-Radius, var(--Style-Border-Radius))",overflow:"hidden",opacity:m?.5:1,transition:"border-color 0.15s ease, box-shadow 0.15s ease",boxShadow:"none",width:"100%","&:focus-within":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:ce(h,{sx:{display:"flex",alignItems:"center",gap:1,width:"100%",boxSizing:"border-box",minHeight:R.height,px:R.px+"px",backgroundColor:"var(--Hover)"},children:[de(jo,{size:"small",sx:{color:I?z:"var(--Quiet)",flexShrink:0,transition:"color 0.15s ease"},children:de(Te,{})}),de(h,{component:"input",ref:B,type:"text",role:"searchbox","aria-label":f,value:C,onChange:e=>{const t=e.target.value;w||y(t),n?.(t,e)},onFocus:e=>{k(!0),i?.(e)},onBlur:e=>{k(!1),a?.(e)},onKeyDown:e=>{"Enter"===e.key&&s?.(C,e),"Escape"===e.key&&T&&E()},placeholder:d,disabled:m,sx:{flex:1,border:"none",outline:"none",backgroundColor:"transparent",color:I?z:"var(--Quiet)",fontSize:R.fontSize,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)",minWidth:0,"&::placeholder":{color:"var(--Quiet)",opacity:1,fontFamily:"var(--Body-Font-Family)",fontWeight:"var(--Body-Font-Weight)"},"&:disabled":{cursor:"not-allowed"}}}),p&&T&&!m&&de(h,{component:"button",type:"button","aria-label":"Clear search",onClick:E,sx:{display:"flex",alignItems:"center",justifyContent:"center",width:R.iconSize+4,height:R.iconSize+4,borderRadius:"50%",border:"none",backgroundColor:"transparent",color:"var(--Quiet)",cursor:"pointer",flexShrink:0,padding:0,transition:"color 0.15s ease, background-color 0.15s ease","&:hover":{backgroundColor:"var(--Hover)",color:z},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px"}},children:de(jo,{size:"small",children:de(Ot,{})})})]})})})}const Ss=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ks=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function Bs({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function ws({color:e,selected:t,onClick:r}){const o=Ss(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Cs(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(!1),[l,s]=r(!0),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Search Field"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:400},children:de(ys,{color:e,size:o,disabled:i,showClearButton:l,placeholder:"Search..."})})}),de(Vi,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),l||t.push("showClearButton={false}"),i&&t.push("disabled"),t.push('placeholder="Search..."'),t.push("onChange={handleSearch}"),"<SearchField\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:ks.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(ws,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Bs,{label:Ss(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clear Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show clear when has value"})]}),de(ta,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Clear button"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(ta,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Disabled"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="searchbox" on the input element'},{label:"Label",value:'aria-label="Search" (configurable via ariaLabel prop)'},{label:"Clear",value:'aria-label="Clear search" on clear button'},{label:"Keyboard",value:"Enter submits, Escape clears"},{label:"Focus",value:"outline: 2px solid var(--Focus-Visible); outline-offset: 2px"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Ts=["primary","secondary","tertiary","neutral","info","success","warning","error"],Is=e=>e.charAt(0).toUpperCase()+e.slice(1);function As(){const e={};return Ts.forEach(t=>{e[t]=function(e){const t=Is(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"none",hoverBg:"var(--Buttons-"+t+"-Hover)",activeBg:"var(--Buttons-"+t+"-Pressed)"}}(t),e[t+"-outline"]=function(e){return{bg:"var(--Background)",text:"var(--Text)",border:"1px solid var(--Buttons-"+Is(e)+"-Border)",hoverBg:"var(--Hover)",activeBg:"var(--Hover)"}}(t),e[t+"-light"]=function(e){const t=Is(e);return{bg:"var(--Buttons-"+t+"-Button)",text:"var(--Buttons-"+t+"-Text)",border:"1px solid var(--Buttons-"+t+"-Border)",hoverBg:"var(--Buttons-"+t+"-Hover)",activeBg:"var(--Buttons-"+t+"-Pressed)"}}(t)}),e}const zs={small:{height:24,fontSize:"12px",iconSize:16,padding:"0 8px",deleteSize:16,gap:4},medium:{height:32,fontSize:"13px",iconSize:18,padding:"0 12px",deleteSize:18,gap:6},large:{height:40,fontSize:"14px",iconSize:20,padding:"0 16px",deleteSize:24,gap:8}},Rs=c(function({size:e,onClick:t,...r},o){const n="large"===e?24:"medium"===e?18:16;return de(h,{ref:o,component:"button",onClick:e=>{e.stopPropagation(),t&&t(e)},onKeyDown:e=>{"Enter"!==e.key&&"Backspace"!==e.key&&"Delete"!==e.key||(e.stopPropagation(),t&&t(e))},"aria-label":"Remove",role:"button",tabIndex:0,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",minWidth:24,minHeight:24,width:n,height:n,padding:0,margin:0,marginLeft:"2px",marginRight:"-4px",border:"none",borderRadius:"50%",backgroundColor:"transparent",color:"inherit",opacity:.7,cursor:"pointer",position:"relative",flexShrink:0,transition:"opacity 0.15s ease, background-color 0.15s ease","&:hover":{opacity:1,backgroundColor:"rgba(0,0,0,0.08)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"1px"},...n<24&&{"&::after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",minWidth:24,minHeight:24}}},...r,children:de(jt,{sx:{fontSize:n,pointerEvents:"none"}})})});function Es({variant:e="primary",size:t="medium",label:r,clickable:o=!1,disabled:n=!1,selected:i=!1,selectionMode:a,onDelete:l,onClick:s,startDecorator:d,endDecorator:c,children:u,className:p="",sx:m={},...f}){const g=As(),x=g[e]||g.primary,b=l?"large":t,v=zs[b]||zs.medium,y=o||!!s||!!a,S={};"radio"===a?(S.role="radio",S["aria-checked"]=i):"checkbox"===a&&(S.role="checkbox",S["aria-checked"]=i);const k=i?{outline:"2px solid var(--Buttons-Primary-Button)",outlineOffset:"1px"}:{},B=r||u,w={height:v.height,fontSize:v.fontSize,fontWeight:500,fontFamily:"inherit",borderRadius:v.height/2+"px",padding:v.padding,boxSizing:"border-box",position:"relative",backgroundColor:x.bg,color:x.text,border:x.border,...k,..."small"===b&&{"&::after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",minWidth:24,minHeight:24,width:"100%",height:"100%"}},...y&&!n?{cursor:"pointer",transition:"background-color 0.15s ease, outline 0.15s ease","&:hover":{backgroundColor:x.hoverBg},"&:active":{backgroundColor:x.activeBg}}:{},"&:focus-visible, &.Mui-focusVisible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},...n?{opacity:.5,cursor:"not-allowed",pointerEvents:"none"}:{},boxShadow:"none","& .MuiChip-label":{padding:0,fontSize:"inherit",fontWeight:"inherit",fontFamily:"inherit",lineHeight:1.2,display:"flex",alignItems:"center",gap:v.gap+"px"},"& .MuiChip-icon":{margin:0,marginLeft:"-2px",color:"inherit",fontSize:v.iconSize},"& .MuiChip-deleteIcon":{display:"none"},...m},C=ce(h,{component:"span",sx:{display:"inline-flex",alignItems:"center",gap:v.gap+"px",lineHeight:1},children:[d&&de(h,{component:"span",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,"& .MuiSvgIcon-root":{fontSize:v.iconSize},"& .MuiAvatar-root":{width:v.iconSize+4,height:v.iconSize+4,fontSize:Math.round(.65*v.iconSize)+"px"}},children:d}),B,c&&de(h,{component:"span",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,"& .MuiSvgIcon-root":{fontSize:v.iconSize},"& .MuiAvatar-root":{width:v.iconSize+4,height:v.iconSize+4,fontSize:Math.round(.65*v.iconSize)+"px"}},children:c}),l&&de(Rs,{size:b,onClick:l})]});return de(D,{label:C,clickable:y&&!n,disabled:n,onClick:y?s:void 0,className:"chip-"+e+" "+p,sx:w,...S,...f})}const Ps={body:{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Letter-Spacing)"},"body-small":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Small-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Small-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Small-Letter-Spacing)"},"body-large":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Large-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Large-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Large-Letter-Spacing)"},"body-semibold":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Font-Size)",fontWeight:"var(--Body-Semibold-Font-Weight)",letterSpacing:"var(--Body-Letter-Spacing)"},"body-bold":{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Font-Size)",fontWeight:"var(--Body-Bold-Font-Weight)",letterSpacing:"var(--Body-Letter-Spacing)"},button:{fontFamily:"var(--Body-Font-Family)",lineHeight:"var(--Button-Line-Height)",fontSize:"var(--Button-Font-Size)",fontWeight:"var(--Button-Font-Weight)",letterSpacing:"var(--Button-Letter-Spacing)"},label:{fontFamily:"var(--Body-Font-Family)",lineHeight:"var(--Label-Line-Height)",fontSize:"var(--Label-Font-Size)",fontWeight:"var(--Label-Font-Weight)",letterSpacing:"var(--Label-Letter-Spacing)"},caption:{fontFamily:"var(--Body-Font-Family)",lineHeight:"calc(var(--Body-Small-Line-Height) * var(--Cognitive-Multiplier, 1))",fontSize:"var(--Body-Small-Font-Size)",fontWeight:"var(--Body-Font-Weight)",letterSpacing:"var(--Body-Small-Letter-Spacing)"}},Os="var(--Link-Visited, var(--Hotlink-Visited))",Ls={primary:{base:"var(--Link, var(--Hotlink))",visited:Os},standard:{base:"var(--Text)",visited:Os},quiet:{base:"var(--Text-Quiet)",visited:Os}};function Ms({children:e,href:t,target:r,rel:o,textStyle:n="body",color:i="primary",disabled:a=!1,onClick:l,className:s="",sx:d={},...c}){const u=Ps[n]||Ps.body,p=Ls[i]||Ls.primary;return de(h,{component:"a",href:a?void 0:t,target:r,rel:"_blank"===r?o||"noopener noreferrer":o,onClick:a?e=>e.preventDefault():l,"aria-disabled":a||void 0,tabIndex:a?-1:void 0,className:"link link-"+n+" link-color-"+i+(a?" link-disabled":"")+" "+s,sx:{fontFamily:u.fontFamily,lineHeight:u.lineHeight,fontSize:u.fontSize,fontWeight:u.fontWeight,letterSpacing:u.letterSpacing,textDecoration:"underline",textUnderlineOffset:"3px",textDecorationThickness:"1px",color:p.base,cursor:a?"not-allowed":"pointer",opacity:a?.5:1,pointerEvents:a?"none":"auto",display:"inline-flex",alignItems:"center",minHeight:"24px",minWidth:"24px",transition:"color 0.15s ease, text-decoration-color 0.15s ease",...!a&&{"&:hover":{textDecorationThickness:"2px"},"&:visited":{color:p.visited},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px",borderRadius:"2px"},"&:active":{textDecorationThickness:"2px"}},...d},...c,children:e})}function Ws({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"primary":"primary-outline",size:"small",onClick:r,children:e})}function Ds({code:e}){return de(Vi,{code:e,language:"JSX",wrap:!0,sx:{mt:1}})}function Fs({passes:e}){return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5,px:1.5,py:.5,borderRadius:"20px",backgroundColor:e?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:e?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)",fontSize:"12px",fontWeight:600},children:[de(e?ge:xe,{sx:{fontSize:14}}),e?"WCAG Pass":"WCAG Fail"]})}function Ns({leftLabel:e,rightLabel:t,leftContent:r,rightContent:o,leftCode:n,rightCode:i,leftPasses:a,rightPasses:l}){return ce(I,{container:!0,spacing:3,children:[de(I,{item:!0,xs:12,md:6,children:ce(h,{sx:{p:2,border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:"var(--Background)",height:"100%"},children:[ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[de(ao,{style:{fontWeight:600},children:e}),de(Fs,{passes:a})]}),de(h,{sx:{p:2,backgroundColor:"var(--Surface-Dim, var(--Surface))",borderRadius:"var(--Style-Border-Radius)",minHeight:80},children:r}),de(Ds,{code:n})]})}),de(I,{item:!0,xs:12,md:6,children:ce(h,{sx:{p:2,border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:"var(--Background)",height:"100%"},children:[ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mb:2},children:[de(ao,{style:{fontWeight:600},children:t}),de(Fs,{passes:l})]}),de(h,{sx:{p:2,backgroundColor:"var(--Surface-Dim, var(--Surface))",borderRadius:"var(--Style-Border-Radius)",minHeight:80},children:o}),de(Ds,{code:i})]})})]})}function Hs(){const[e,t]=r("column"),[o,n]=r(.5),[i,a]=r("small"),[l,s]=r(!0),[d,c]=r(!1),[u,p]=r(null),[m,f]=r("Surface"),g={small:{label:"Small links ⚡",content:ce(ue,{children:[de(Ms,{href:"#",size:"small",children:"Terms of Service"}),de(Ms,{href:"#",size:"small",children:"Privacy Policy"}),de(Ms,{href:"#",size:"small",children:"Cookie Settings"})]})},chips:{label:"Chips ⚡",content:ce(ue,{children:[de(Es,{label:"React",size:"small"}),de(Es,{label:"TypeScript",size:"small"}),de(Es,{label:"Design System",size:"small"})]})},normal:{label:"Normal buttons",content:ce(ue,{children:[de(In,{variant:"primary",size:"medium",children:"Primary"}),de(In,{variant:"secondary",size:"medium",children:"Secondary"})]})},mixed:{label:"Mixed ⚡",content:ce(ue,{children:[de(In,{variant:"primary",size:"medium",children:"Save changes"}),de(Ms,{href:"#",size:"small",children:"Or discard"})]})}},x=["small","chips","mixed"].includes(i),b=l&&x;return ce(I,{container:!0,spacing:3,sx:{mt:1},children:[ce(I,{item:!0,xs:12,md:7,children:[de(di,{theme:u,children:ce(h,{sx:{width:"100%"},children:[b&&ce(h,{sx:{mb:2,px:2,py:1,borderRadius:"var(--Style-Border-Radius)",backgroundColor:"var(--Tags-Warning-BG)",color:"var(--Tags-Warning-Text)",fontSize:"12px",fontWeight:600,display:"flex",alignItems:"center",gap:1},children:[de(xe,{sx:{fontSize:16}}),"Small child detected — gap raised to var(--min-stack-gap)"]}),de(ya,{direction:e,gap:o,enforceMinGap:l,flexWrap:d?"wrap":void 0,children:g[i].content})]})}),de(Ds,{code:(()=>{const t=["<OmniStack"];return"column"!==e&&t.push(' direction="'+e+'"'),t.push(" gap={"+o+"}"),l||t.push(" enforceMinGap={false}"),d&&t.push(' flexWrap="wrap"'),t.push(">"),t.push(" {children}"),t.push("</OmniStack>"),t.join("\n")})()})]}),de(I,{item:!0,xs:12,md:5,children:ce(h,{sx:{display:"flex",flexDirection:"column",gap:3},children:[de(hi,{theme:u,onThemeChange:p,surface:m,onSurfaceChange:f}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"CHILDREN"}),de(h,{sx:{display:"flex",flexWrap:"wrap",gap:1},children:Object.entries(g).map(([e,{label:t}])=>de(Ws,{label:t,selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"DIRECTION"}),de(h,{sx:{display:"flex",gap:1},children:["row","column"].map(r=>{return de(Ws,{label:(o=r,o?o.charAt(0).toUpperCase()+o.slice(1):""),selected:e===r,onClick:()=>t(r)},r);var o})})]}),ce(h,{children:[ce(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:["GAP — ",o," unit",b?" → raised to var(--min-stack-gap)":""]}),ce(h,{sx:{display:"flex",alignItems:"center",gap:2},children:[de(h,{component:"input",type:"range",min:0,max:6,step:.5,value:o,onChange:e=>n(Number(e.target.value)),sx:{flex:1,accentColor:"var(--Primary-Color-10)"}}),de(bo,{style:{color:"var(--Text)",minWidth:24,textAlign:"right"},children:o})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(h,{sx:{display:"flex",flexDirection:"column",gap:1.5},children:[ce(h,{sx:{display:"flex",alignItems:"flex-start",justifyContent:"space-between"},children:[ce(h,{children:[de(ao,{children:"Enforce min gap"}),de(bo,{style:{color:b?"var(--Tags-Warning-Text)":"var(--Text-Quiet)",display:"block"},children:b?"⚡ Active — small child detected":x?"Off — WCAG 2.5.8 risk":"No small children detected"})]}),de(ta,{checked:l,onChange:e=>s(e.target.checked),size:"small"})]}),ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[de(ao,{children:"Flex wrap"}),de(ta,{checked:d,onChange:e=>c(e.target.checked),size:"small"})]})]})]})]})})]})}function Vs(){return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Stack"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:32,maxWidth:640},children:"OmniStack is a layout primitive built on MUI Stack with one intelligent addition: it automatically enforces a minimum gap between children when it detects small (24px) interactive components — protecting WCAG 2.5.8 compliance without any extra developer effort."}),ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Why it matters"}),de(li,{children:"Playground"}),de(li,{children:"API"})]}),de(si,{value:0,children:ce(h,{sx:{pt:3,display:"flex",flexDirection:"column",gap:4},children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"The problem"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"WCAG 2.5.8 requires that small interactive targets (24px) have enough surrounding space that they don’t overlap adjacent targets. Every layout library leaves this entirely to the developer — meaning it’s silently violated constantly."}),de(Ns,{leftLabel:"Plain MUI Stack — gap too small",rightLabel:"OmniStack — gap auto-enforced",leftPasses:!1,rightPasses:!0,leftContent:ce(h,{sx:{display:"flex",flexDirection:"column",gap:"4px"},children:[de(Ms,{href:"#",size:"small",children:"Terms of Service"}),de(Ms,{href:"#",size:"small",children:"Privacy Policy"}),de(Ms,{href:"#",size:"small",children:"Cookie Settings"})]}),rightContent:ce(ya,{gap:.5,children:[de(Ms,{href:"#",size:"small",children:"Terms of Service"}),de(Ms,{href:"#",size:"small",children:"Privacy Policy"}),de(Ms,{href:"#",size:"small",children:"Cookie Settings"})]}),leftCode:'<Stack gap={0.5}>\n <Link size="small">Terms of Service</Link>\n <Link size="small">Privacy Policy</Link>\n <Link size="small">Cookie Settings</Link>\n</Stack>\n// ⚠ gap=4px — targets overlap',rightCode:'<OmniStack gap={0.5}>\n <Link size="small">Terms of Service</Link>\n <Link size="small">Privacy Policy</Link>\n <Link size="small">Cookie Settings</Link>\n</OmniStack>\n// ✓ small child detected → gap enforced'})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"Mixed component sizes"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"One small child is enough to trigger enforcement for the whole stack — the most common case is a normal button paired with a small cancel link."}),de(Ns,{leftLabel:"Without enforcement",rightLabel:"With enforcement",leftPasses:!1,rightPasses:!0,leftContent:ce(h,{sx:{display:"flex",flexDirection:"column",gap:"2px"},children:[de(In,{variant:"primary",size:"medium",children:"Save changes"}),de(Ms,{href:"#",size:"small",children:"Or discard"})]}),rightContent:ce(ya,{gap:.25,children:[de(In,{variant:"primary",size:"medium",children:"Save changes"}),de(Ms,{href:"#",size:"small",children:"Or discard"})]}),leftCode:'<Stack gap={0.25}>\n <Button size="medium">Save changes</Button>\n <Link size="small">Or discard</Link>\n</Stack>\n// ⚠ Link is 24px — gap too tight',rightCode:'<OmniStack gap={0.25}>\n <Button size="medium">Save changes</Button>\n <Link size="small">Or discard</Link>\n</OmniStack>\n// ✓ Link detected → gap enforced'})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"How detection works"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"OmniStack inspects children at render time using a priority-ordered signal chain. Any one signal is enough to trigger enforcement."}),de(h,{sx:{display:"flex",flexDirection:"column"},children:[{signal:'size="small" prop',example:'<Link size="small" />'},{signal:'data-size="small"',example:'<div data-size="small" />'},{signal:"height={24}",example:"<Box height={24} />"},{signal:"minHeight={24}",example:"<Box minHeight={24} />"},{signal:"sx.minHeight: 24",example:"<Box sx={{ minHeight: 24 }} />"},{signal:"Known component name",example:"Link, Chip, Badge, Caption…"}].map(({signal:e,example:t},r,o)=>ce(h,{sx:{display:"flex",alignItems:"center",gap:2,py:1.5,borderBottom:r<o.length-1?"1px solid var(--Border)":"none"},children:[de(h,{sx:{width:8,height:8,borderRadius:"50%",backgroundColor:"var(--Primary-Color-10)",flexShrink:0}}),de(ao,{style:{flex:"0 0 200px"},children:e}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"Token-driven minimum"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:"The minimum gap is a CSS custom property, not a hardcoded value — so it respects your brand spacing scale and responds to theme changes without re-rendering."}),de(Ds,{code:":root {\n --min-stack-gap: 8px; /* Set in your theme.css */\n}\n\n/* OmniStack substitutes the variable, not the value: */\ngap: var(--min-stack-gap, 8px);\n\n/* Dark mode, brand overrides, and media queries\n all work automatically — no re-render needed. */"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)"},children:[de(Jr,{children:"Auditable opt-out"}),ce(co,{style:{color:"var(--Text-Quiet)",marginTop:8,marginBottom:16},children:["Use ",de("code",{children:"enforceMinGap={false}"})," to opt out. This creates a searchable pattern accessibility audits can grep for — a conscious waiver, not a silent violation."]}),de(Ds,{code:'<OmniStack gap={0.5} enforceMinGap={false}>\n {/* Explicitly waived — auditors can grep:\n enforceMinGap={false}\n to find all waivers in the codebase. */}\n <Link size="small">Terms</Link>\n <Link size="small">Privacy</Link>\n</OmniStack>'})]})]})}),de(si,{value:1,children:de(Hs,{})}),de(si,{value:2,children:ce(h,{sx:{pt:3},children:[de(Jr,{children:"OmniStack props"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:4,marginBottom:16},children:"All standard MUI Stack props are supported. These are OmniStack additions:"}),de(h,{sx:{border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",mb:4},children:[{prop:"enforceMinGap",type:"boolean",default:"true",desc:"Enable/disable smart gap enforcement."},{prop:"minGapToken",type:"string",default:'"--min-stack-gap"',desc:"CSS variable name for the minimum gap value."},{prop:"gap",type:"number|string",default:"undefined",desc:"Desired gap. Enforced against minGapToken when small children detected."},{prop:"direction",type:"string|object",default:'"column"',desc:"Stack direction. Supports responsive breakpoint objects."},{prop:"flexWrap",type:"string",default:"undefined",desc:'"wrap" | "nowrap" | "wrap-reverse"'},{prop:"divider",type:"ReactNode",default:"undefined",desc:"Element rendered between each child."}].map(({prop:e,type:t,default:r,desc:o},n,i)=>ce(h,{sx:{display:"grid",gridTemplateColumns:"160px 160px 1fr",gap:2,px:2,py:1.5,alignItems:"start",borderBottom:n<i.length-1?"1px solid var(--Border)":"none",backgroundColor:n%2==0?"transparent":"var(--Surface-Dim, var(--Surface))"},children:[de(bo,{style:{fontFamily:"monospace",color:"var(--Primary-Color-10)",fontWeight:600},children:e}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t}),ce(h,{children:[de(bo,{style:{color:"var(--Text)"},children:o}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:2},children:["Default: ",r]})]})]},e))}),de(Jr,{children:"Convenience exports"}),de(h,{sx:{border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",mb:4},children:[{name:"Stack",desc:"Alias for OmniStack — drop-in MUI Stack replacement"},{name:"HStack",desc:'direction="row" alignItems="center"'},{name:"VStack",desc:'direction="column"'},{name:"CenteredStack",desc:'direction="column" alignItems="center" justifyContent="center"'},{name:"SpaceBetweenStack",desc:'direction="row" justifyContent="space-between"'},{name:"WrapStack",desc:'direction="row" flexWrap="wrap"'},{name:"ResponsiveStack",desc:"column on xs, row on sm+ (breakpoint configurable)"},{name:"GridStack",desc:"Alias for WrapStack"},{name:"InsetStack",desc:"OmniStack with px: 2 horizontal padding"},{name:"ScrollStack",desc:"OmniStack with overflowY: auto"}].map(({name:e,desc:t},r,o)=>ce(h,{sx:{display:"grid",gridTemplateColumns:"200px 1fr",gap:2,px:2,py:1.5,borderBottom:r<o.length-1?"1px solid var(--Border)":"none",backgroundColor:r%2==0?"transparent":"var(--Surface-Dim, var(--Surface))"},children:[de(bo,{style:{fontFamily:"monospace",color:"var(--Primary-Color-10)",fontWeight:600},children:e}),de(bo,{style:{color:"var(--Text-Quiet)"},children:t})]},e))}),de(Jr,{children:"Debug attributes"}),de(Ds,{code:'/* When enforcement is active, OmniStack adds: */\nclassName="omni-stack omni-stack-min-gap-enforced"\ndata-min-gap-enforced="true"\n\n/* Target in CSS: */\n.omni-stack-min-gap-enforced { outline: 2px dashed orange; }\n\n/* Query in tests: */\ncontainer.querySelector(\'[data-min-gap-enforced="true"]\')'})]})})]})]})}function Qs({children:e,theme:t,surface:r,elevation:o=0,component:n="div",className:i="",sx:a={},style:l,...s}){const d=Math.max(0,Math.min(5,0|o));if(!d)return de(h,{component:n,"data-theme":t||void 0,"data-surface":r||void 0,className:"omni-box"+(i?" "+i:""),sx:{background:"var(--Background)",boxSizing:"border-box",...a},style:l,...s,children:e});const c=l||{},{width:u,height:p,minWidth:m,minHeight:f,maxWidth:g,maxHeight:x,borderRadius:b,margin:v,marginTop:y,marginRight:S,marginBottom:k,marginLeft:B,...w}=c,C={width:u,height:p,minWidth:m,minHeight:f,maxWidth:g,maxHeight:x,borderRadius:b,margin:v,marginTop:y,marginRight:S,marginBottom:k,marginLeft:B},{width:T,height:I,borderRadius:A,...z}=a;return de(h,{component:n,className:"omni-box-elevation"+(i?" "+i:""),sx:{boxShadow:cn[d],boxSizing:"border-box",width:T,height:I,borderRadius:A},style:C,...s,children:de(h,{"data-theme":t||void 0,"data-surface":r||void 0,className:"omni-box",sx:{width:"100%",height:"100%",background:"var(--Background)",borderRadius:"inherit",boxSizing:"border-box",...z},style:w,children:e})})}const js=["Surface","Surface-Dim","Surface-Bright","Container","Container-Low","Container-Lowest","Container-High"],Gs=["Default","Primary","Primary-Light","Secondary","Secondary-Light","Tertiary","Tertiary-Light","Neutral","Neutral-Light","Info-Light","Success-Light","Warning-Light","Error-Light"];function Us({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Xs(){const[e,t]=r(""),[o,n]=r(""),[i,a]=r(null),[l,s]=r("Surface");return ce(Qs,{sx:{pb:8},children:[de(Jr,{children:"Box"}),ce(co,{color:"quiet",style:{marginTop:8,marginBottom:24,maxWidth:720},children:["Bare layout primitive — a slot that participates in the design-system cascade (",de("code",{children:"data-theme"})," / ",de("code",{children:"data-surface"}),") without carrying any chrome. Reach for ",de("code",{children:"<Ratio>"})," or",de("code",{children:" <Card>"})," when you need padding, borders, or shadow."]}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:i,surface:l,children:de(Qs,{sx:{width:"100%",maxWidth:400},children:de(Qs,{theme:e||void 0,surface:o||void 0,children:ce(Qs,{sx:{padding:3,backgroundColor:"var(--Background)",color:"var(--Text)",borderRadius:"var(--Style-Border-Radius)",border:"1px dashed var(--Border-Variant)"},children:[de(Zr,{children:"Box content"}),de(co,{style:{color:"var(--Text-Quiet)",marginTop:6},children:"Anything dropped inside resolves tokens against the Box's theme / surface, if you set them."})]})})})}),de(Vi,{code:(()=>{const t=[];e&&t.push('theme="'+e+'"'),o&&t.push('surface="'+o+'"');return"<Box"+(t.length?" "+t.join(" "):"")+">\n {/* anything */}\n</Box>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(Qs,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"When to use"})]}),de(si,{value:0,children:ce(Qs,{sx:{p:3},children:[de(Qs,{sx:{mb:3},children:de(hi,{theme:i,onThemeChange:a,surface:l,onSurfaceChange:s})}),ce(Qs,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"THEME (optional)"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[de(Us,{label:"None",selected:!e,onClick:()=>t("")}),Gs.map(r=>de(Us,{label:r,selected:e===r,onClick:()=>t(r)},r))]})]}),ce(Qs,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SURFACE (optional)"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[de(Us,{label:"None",selected:!o,onClick:()=>n("")}),js.map(e=>de(Us,{label:e,selected:o===e,onClick:()=>n(e)},e))]}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Both props are pass-throughs to ",de("code",{children:"data-theme"})," ","and ",de("code",{children:"data-surface"}),". Leave empty to inherit from the parent zone."]})]})]})}),de(si,{value:1,children:de(Qs,{sx:{p:3},children:ce(B,{spacing:2,children:[ce(Qs,{children:[de(ao,{style:{fontWeight:700},children:"Reach for Box when…"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:"you need a wrapper to scope a theme / surface zone, or you want a typed JSX root without painting any visual styling."})]}),ce(Qs,{children:[de(ao,{style:{fontWeight:700},children:"Use Ratio when…"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:"the container needs a fixed proportion (image, video, embed, hero tile) — it carries the same theme / color shell Box used to."})]}),ce(Qs,{children:[de(ao,{style:{fontWeight:700},children:"Use Card when…"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:4},children:"the container has a title, body, and actions — Card handles the standard 2-layer chrome plus header / footer slots."})]})]})})})]})})})]})]})}function Ks({children:e,maxWidth:t="lg",disableGutters:r=!1,sx:o={},...n}){return de(F,{maxWidth:t,disableGutters:r,"data-surface":"Surface",sx:{backgroundColor:"var(--Background)",color:"var(--Text)",transition:"all 0.2s ease-in-out",...o},...n,children:e})}function qs({children:e,container:t=!1,item:r=!1,spacing:o=2,sx:n={},...i}){return de(I,{container:t,item:r,spacing:o,sx:{transition:"all 0.2s ease-in-out",...n},...i,children:e})}function Js({theme:e,surface:t="Surface",as:r="section",padding:o,className:n,style:i,children:a,...l}){return de(r,{...e?{"data-theme":e}:{},"data-surface":t,className:n,style:{background:"var(--Background)",color:"var(--Text)",...void 0!==o?{padding:o}:{},...i},...l,children:a})}function Ys(){return ce("div",{children:[de(Jr,{style:{marginBottom:12},children:"Section"}),ce(co,{color:"quiet",style:{marginBottom:32,maxWidth:720},children:[de("code",{children:"<Section>"})," bundles ",de("code",{children:"data-theme"})," +"," ",de("code",{children:"data-surface"})," + background paint into one component. Use anywhere you'd otherwise reach for"," ",de("code",{children:"<section data-theme data-surface style={{ background: var(--Background) }}>"}),". For wrapping without painting (e.g. AppBar's themed zone), use"," ",de("code",{children:"<ThemedZone>"}),"."]}),de(Jr,{style:{marginTop:24,marginBottom:12},children:"Theme + surface"}),de(ao,{color:"quiet",style:{marginBottom:16,display:"block"},children:'Sets data-theme="Primary-Light" + data-surface="Surface", paints --Background.'}),ce(Js,{theme:"Primary-Light",surface:"Surface",padding:"32px",style:{borderRadius:8},children:[de(Jr,{children:"Primary-Light surface"}),de(co,{children:"Body text picks up --Text automatically."}),de(ao,{color:"quiet",children:"Quiet text picks up --Text-Quiet."}),de("div",{style:{marginTop:12},children:de(In,{variant:"primary",children:"Primary button"})})]}),de(Jr,{style:{marginTop:32,marginBottom:12},children:"Container surface"}),ce(Js,{surface:"Container",padding:"32px",style:{borderRadius:8},children:[de(Jr,{children:"Container surface (inherits theme)"}),de(co,{children:"Useful for card-like regions."})]}),de(Jr,{style:{marginTop:32,marginBottom:12},children:"Different element"}),ce(ao,{color:"quiet",style:{marginBottom:16,display:"block"},children:["Pass ",de("code",{children:'as="article"'}),", ",de("code",{children:'as="footer"'}),", etc."]}),ce(Js,{as:"article",theme:"Neutral-Dark",surface:"Surface",padding:"32px",style:{borderRadius:8},children:[de(Jr,{children:"Neutral-Dark article"}),de(co,{children:"Renders as an <article> element."})]})]})}const Zs=["1:1","3:4","4:3","16:9","9:16","2:3","3:2","1:2","2:1","9:21","21:9","5:7","7:5","4:5","5:4","5:3","3:5","16:10","10:16","Golden-Horizontal","Golden-Vertical"],$s="1.618034",_s={"1:1":"1 / 1","3:4":"3 / 4","4:3":"4 / 3","16:9":"16 / 9","9:16":"9 / 16","2:3":"2 / 3","3:2":"3 / 2","1:2":"1 / 2","2:1":"2 / 1","9:21":"9 / 21","21:9":"21 / 9","5:7":"5 / 7","7:5":"7 / 5","4:5":"4 / 5","5:4":"5 / 4","5:3":"5 / 3","3:5":"3 / 5","16:10":"16 / 10","10:16":"10 / 16","Golden-Horizontal":$s+" / 1","Golden-Vertical":"1 / "+$s},ed={none:0,xs:1,sm:2,md:3,lg:4,xl:6};function td({ratio:e="1:1",children:r,variant:o="default",color:n="default",padding:i="none",fit:a="width",placeholder:l=!0,elevated:s=!1,clickable:d=!1,onClick:c,maxWidth:u,maxHeight:p,component:m="div",className:f="",sx:g={},...x}){const b=_s[e]||_s["1:1"],v=(y="default"===n?"Default":n).charAt(0).toUpperCase()+y.slice(1);var y;const S=l&&0===t.Children.count(r),k="default"===n?void 0:v,B="dark"===o?"Surface-Dimmest":"light"===o?"Surface-Brightest":void 0,w=void 0!==ed[i]?ed[i]:ed.none,C=d||!!c,T="default"===o,I=s?ln:an,A=s?sn:ln;return de(h,{component:m,onClick:C?c:void 0,role:C?"button":void 0,tabIndex:C?0:void 0,className:"ratio ratio-"+e.toLowerCase()+" ratio-"+o+(C?" ratio-clickable":"")+(s?" ratio-elevated":"")+(f?" "+f:""),sx:{aspectRatio:b,flex:"0 0 auto",..."height"===a?{height:"100%",width:"auto",minHeight:24}:{width:"100%",height:"auto",minWidth:24},...void 0!==u&&{maxWidth:u},...void 0!==p&&{maxHeight:p},border:T?"none":"1px solid var(--Border-Variant)",borderRadius:T?0:"var(--Style-Border-Radius)",boxShadow:T?"none":I,overflow:"hidden",transition:"box-shadow 0.2s ease, border-color 0.2s ease",...C&&{cursor:"pointer","&:hover":{borderColor:"var(--Buttons-Default-Border)",boxShadow:A},"&:active":{transform:"scale(0.995)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"3px"}},...!C&&!T&&{"&:hover":{boxShadow:A}},...g},...x,children:de(h,{"data-theme":k||void 0,"data-surface":B,sx:{width:"100%",height:"100%",padding:w,backgroundColor:S?"var(--Border)":"var(--Background)",color:"var(--Text)",fontFamily:"inherit",borderRadius:T?0:"calc(var(--Style-Border-Radius) - 1px)",...S?{display:"flex",alignItems:"center",justifyContent:"center"}:{"& > *":{width:"100%",height:"100%"}}},children:S?de(jo,{size:"large",sx:{color:"var(--Background)"},children:de(Ut,{})}):r})})}const rd=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",od=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],nd=["default","solid","light","dark"],id=["none","xs","sm","md","lg","xl"];function ad({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function ld({color:e,selected:t,onClick:r,variant:o}){const n=rd(e);return de(Qs,{component:"button","data-theme":{solid:n,light:n+"-Light",dark:n,default:void 0}[o],"data-surface":{solid:"Surface",light:"Surface",dark:"Surface-Dimmest",default:"Surface"}[o],onClick:()=>r(e),"aria-label":"Select "+n,"aria-pressed":t,title:n,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Background)",border:t?"2px solid var(--Text)":"2px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Text)",pointerEvents:"none"}})})}function sd(){const[e,t]=r("1:1"),[o,n]=r("solid"),[i,a]=r("primary"),[l,s]=r("none"),[d,c]=r(!1),[u,p]=r(!1),[h,m]=r(null),[f,g]=r("Surface");return ce(Qs,{sx:{pb:8},children:[de(Jr,{children:"Ratio"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:h,surface:f,children:de(Qs,{sx:{width:"100%",maxWidth:480},children:de(td,{ratio:e,variant:o,color:i,padding:l,elevated:d,clickable:u})})}),de(Vi,{code:(()=>{const t=['ratio="'+e+'"'];return"default"!==o&&t.push('variant="'+o+'"'),"default"!==i&&t.push('color="'+i+'"'),"none"!==l&&t.push('padding="'+l+'"'),d&&t.push("elevated"),u&&t.push("clickable onClick={handleClick}"),"<Ratio "+t.join(" ")+">\n {/* your content */}\n</Ratio>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(Qs,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Reference"})]}),de(si,{value:0,children:ce(Qs,{sx:{p:3},children:[de(Qs,{sx:{mb:3},children:de(hi,{theme:h,onThemeChange:m,surface:f,onSurfaceChange:g})}),ce(Qs,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"VARIANT"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:nd.map(e=>de(ad,{label:rd(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(Qs,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:od.map(e=>ce(Qs,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(ld,{color:e,selected:i===e,onClick:a,variant:"default"===o?"solid":o},e))})]},e.label))})]}),ce(Qs,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PADDING"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:id.map(e=>de(ad,{label:"none"===e?"None":e.toUpperCase(),selected:l===e,onClick:()=>s(e)},e))})]}),ce(Qs,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"RATIO"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:Zs.map(r=>de(ad,{label:r,selected:e===r,onClick:()=>t(r)},r))})]}),ce(Qs,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(Qs,{children:[de(ko,{children:"Elevated"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Bumps the shadow up one level"})]}),de(ta,{checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Elevated"})]}),ce(Qs,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(Qs,{children:[de(ko,{children:"Clickable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Adds hover, press, and focus-visible"})]}),de(ta,{checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Clickable"})]})]})}),de(si,{value:1,children:de(Qs,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(Qs,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Common use cases"}),de(B,{spacing:0,children:[{label:"1:1",value:"Square thumbnails, avatars, product tiles"},{label:"16:9",value:"Video, hero images, modern displays"},{label:"4:3",value:"Classic photo, presentation slides"},{label:"3:2",value:"DSLR photography, print frames"},{label:"21:9",value:"Cinematic ultrawide"},{label:"9:16 / 4:5 / 5:7",value:"Portrait social media (Stories, Reels, prints)"},{label:"16:10",value:"Laptop / monitor displays"},{label:"Golden-Horizontal",value:"φ : 1 — design framing for cards, hero blocks"},{label:"Golden-Vertical",value:"1 : φ — vertical posters, sidebars"}].map(({label:e,value:t})=>ce(Qs,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:e}),de(bo,{style:{color:"var(--Text-Quiet)"},children:t})]},e))})]}),ce(co,{color:"quiet",children:["Built on native CSS ",de("code",{children:"aspect-ratio"}),". The themed shell mirrors Box — pick a variant + color to paint the frame, or keep ",de("code",{children:'variant="default"'}),"for a borderless ratio container."]})]})})})]})})})]})]})}const dd=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",cd=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],ud=[{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function pd({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function hd({color:e,selected:t,onClick:r}){const o=dd(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function md(){const[e,t]=r("standard"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r("horizontal"),[d,c]=r(null),[u,p]=r("Surface"),[m,f]=r(!1),g="standard"===e?cd:ud;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Tabs"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:"vertical"===l?500:"100%",display:"flex",flexDirection:"vertical"===l?"row":"column"},children:ce(ii,{defaultValue:0,variant:e,color:o,size:i,orientation:l,children:[ce(ai,{rounded:m,children:[de(li,{children:"Overview"}),de(li,{children:"Features"}),de(li,{children:"Pricing"})]}),de(si,{value:0,children:de(h,{sx:{p:2},children:de(co,{style:{color:"var(--Quiet)"},children:"Overview content goes here."})})}),de(si,{value:1,children:de(h,{sx:{p:2},children:de(co,{style:{color:"var(--Quiet)"},children:"Features content goes here."})})}),de(si,{value:2,children:de(h,{sx:{p:2},children:de(co,{style:{color:"var(--Quiet)"},children:"Pricing content goes here."})})})]})})}),de(Vi,{code:(()=>{const t=[];return"standard"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),"horizontal"!==l&&t.push('orientation="vertical"'),"<Tabs defaultValue={0}"+(t.length?" "+t.join(" "):"")+">\n <TabList"+(m?" rounded":"")+">\n <Tab>Overview</Tab>\n <Tab>Features</Tab>\n <Tab>Pricing</Tab>\n </TabList>\n <TabPanel value={0}>Overview content</TabPanel>\n <TabPanel value={1}>Features content</TabPanel>\n <TabPanel value={2}>Pricing content</TabPanel>\n</Tabs>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["standard","solid","light","dark"].map(r=>de(pd,{label:dd("standard"===r?"default":r),selected:e===r,onClick:()=>(e=>{t(e),"standard"!==e&&"default"===o&&n("primary")})(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:g.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(hd,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(pd,{label:dd(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ORIENTATION"}),de(B,{direction:"row",spacing:1,children:["horizontal","vertical"].map(e=>de(pd,{label:dd(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SHAPE"}),de(ta,{label:"Rounded corners",checked:m,onChange:e=>f(e.target.checked)}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Off by default. When on, the TabList applies"," ",de("code",{children:"var(--Style-Border-Radius)"})," and clips the active tab's background to fit the rounded shell (",de("code",{children:"overflow: hidden"})," is always on)."]})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"TabList",value:'role="tablist" aria-orientation'},{label:"Tab",value:'role="tab" aria-selected aria-controls={panelId}'},{label:"TabPanel",value:'role="tabpanel" aria-labelledby={tabId}'},{label:"Keyboard",value:"Arrow keys navigate tabs. Home/End jump to first/last."},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: -3px"},{label:"Indicator",value:"Standard: var(--Buttons-{C}-Border). Themed: var(--Text)."}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const fd={small:{fontSize:"var(--Body-Small-Font-Size)",gap:"6px",py:"4px"},medium:{fontSize:"var(--Body-Font-Size)",gap:"8px",py:"6px"},large:{fontSize:"var(--Body-Large-Font-Size)",gap:"10px",py:"8px"}};function gd({children:e,separator:r="/",size:o="medium",condense:n=!1,maxItems:i=4,itemsBeforeCollapse:a=1,itemsAfterCollapse:l=1,backOnlyMobile:s=!1,onExpand:d,className:c="",sx:m={},...f}){const g=fd[o]||fd.medium,x=u.toArray(e).filter(p),b=x.length,v=n&&b>i;let y=x;const[S,k]=t.useState(!1);if(v&&!S){const e=x.slice(0,a),t=x.slice(b-l);y=[...e,de(h,{component:"button",onClick:()=>{k(!0),d?.()},"aria-label":"Show full breadcrumb trail",className:"breadcrumb-ellipsis",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",background:"none",border:"none",padding:"2px 4px",cursor:"pointer",fontFamily:"inherit",fontSize:"inherit",color:"var(--Quiet)",borderRadius:"4px","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"1px"}},children:"…"},"__breadcrumb-ellipsis"),...t]}const B=[];y.forEach((e,t)=>{const o=v&&!S?t===y.length-1:t===b-1;B.push(de(h,{component:"li",className:"breadcrumb-item"+(o?" breadcrumb-current":""),sx:{display:"inline-flex",alignItems:"center",...o&&{color:"var(--Text)",fontWeight:600},...!o&&{color:"var(--Quiet)"},maxWidth:"200px","& > *":{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},...o?{"aria-current":"page"}:{},children:e},"crumb-"+t)),t<y.length-1&&B.push(de(h,{component:"li",role:"presentation","aria-hidden":"true",className:"breadcrumb-separator",sx:{display:"inline-flex",alignItems:"center",color:"var(--Quiet)",userSelect:"none",fontSize:"inherit",lineHeight:1,flexShrink:0},children:r},"sep-"+t))});const w=b>=2?x[b-2]:null;return ce(h,{component:"nav","aria-label":"Breadcrumb",className:"breadcrumbs breadcrumbs-"+o+" "+c,sx:{fontSize:g.fontSize,fontFamily:"var(--Body-Font-Family)",lineHeight:1.5,...m},...f,children:[de(h,{component:"ol",className:"breadcrumbs-list",sx:{display:"flex",flexWrap:"wrap",alignItems:"center",gap:g.gap,listStyle:"none",margin:0,padding:0,...s&&{"@media (max-width: 600px)":{display:"none"}}},children:B}),s&&w&&ce(h,{className:"breadcrumbs-back-mobile",sx:{display:"none","@media (max-width: 600px)":{display:"flex",alignItems:"center",gap:"4px",fontSize:g.fontSize,color:"var(--Link)"}},children:[de(h,{component:"span","aria-hidden":"true",sx:{fontSize:"1.1em",lineHeight:1},children:"←"}),t.cloneElement(w,{style:{...w.props?.style||{},textDecoration:"underline",textUnderlineOffset:"3px"}})]})]})}function xd({children:e,href:t,className:r="",sx:o={},...n}){const i=!!t;return de(h,{component:i?"a":"span",href:t||void 0,className:"breadcrumb-link "+r,sx:{color:"inherit",textDecoration:i?"underline":"none",textUnderlineOffset:"3px",textDecorationThickness:"1px",cursor:i?"pointer":"default",transition:"color 0.15s ease",...i&&{"&:hover":{color:"var(--Link-Hover)",textDecorationThickness:"2px"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px",borderRadius:"2px"}},...o},...n,children:e})}const bd=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"";function vd({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function yd(){const[e,t]=r("medium"),[o,n]=r("/"),[i,a]=r(!1),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Breadcrumbs"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:l,surface:d,children:ce(gd,{size:e,separator:o,condense:i,maxItems:3,children:[de(xd,{href:"#",children:"Home"}),de(xd,{href:"#",children:"Products"}),de(xd,{href:"#",children:"Shoes"}),de(xd,{children:"Running Shoes"})]})}),de(Vi,{code:(()=>{const t=[];return"medium"!==e&&t.push('size="'+e+'"'),"/"!==o&&t.push('separator="'+o+'"'),i&&t.push("condense maxItems={3}"),"<Breadcrumbs"+(t.length?" "+t.join(" "):"")+'>\n <BreadcrumbItem href="/">Home</BreadcrumbItem>\n <BreadcrumbItem href="/products">Products</BreadcrumbItem>\n <BreadcrumbItem href="/products/shoes">Shoes</BreadcrumbItem>\n <BreadcrumbItem>Running Shoes</BreadcrumbItem>\n</Breadcrumbs>'})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(r=>de(vd,{label:bd(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SEPARATOR"}),de(B,{direction:"row",spacing:1,children:["/","›","→","·","|"].map(e=>de(vd,{label:e,selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Condense"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Collapse middle items into ellipsis"})]}),de(ta,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Condense"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Nav",value:'<nav aria-label="Breadcrumb">'},{label:"List",value:"<ol> with <li> for each crumb"},{label:"Current",value:'aria-current="page" on the last item'},{label:"Links",value:"BreadcrumbItem renders <a> when href is provided"},{label:"Ellipsis",value:'Expandable button with aria-label="Show full breadcrumb trail"'},{label:"Separator",value:'aria-hidden="true" — decorative only'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Sd={small:{btnSize:"small",fontSize:"13px",gap:"2px"},medium:{btnSize:"medium",fontSize:"14px",gap:"4px"},large:{btnSize:"large",fontSize:"16px",gap:"4px"}};function kd({count:e=10,page:t,defaultPage:o=1,onChange:i,color:a="default",size:l="medium",siblingCount:s=1,boundaryCount:d=1,disabled:c=!1,showFirstButton:u=!1,showLastButton:p=!1,className:m="",sx:f={},...g}){const[x,b]=r(o),v=void 0!==t,y=v?t:x;(e=>{e.charAt(0).toUpperCase(),e.slice(1)})("default"===a?"Default":a);const S=Sd[l]||Sd.medium,k=n(t=>{const r=Math.max(1,Math.min(e,t));v||b(r),i?.(r)},[e,v,i]),B=function({count:e,page:t,siblingCount:r=1,boundaryCount:o=1}){const n=(e,t)=>Array.from({length:t-e+1},(t,r)=>e+r);if(2*r+3+2*o>=e)return n(1,e);const i=Math.max(t-r,o+1),a=Math.min(t+r,e-o),l=i>o+2,s=a<e-o-1;if(!l&&s)return[...n(1,Math.min(3+2*r+o,e)),"ellipsis-right",...n(e-o+1,e)];if(l&&!s){const t=n(Math.max(e-(3+2*r+o)+1,1),e);return[...n(1,o),"ellipsis-left",...t]}return l&&s?[...n(1,o),"ellipsis-left",...n(i,a),"ellipsis-right",...n(e-o+1,e)]:n(1,e)}({count:e,page:y,siblingCount:s,boundaryCount:d}),w="default"===a?"default":a;return de(h,{component:"nav","aria-label":"Pagination",className:"pagination pagination-"+a+" pagination-"+l+" "+m,sx:{display:"inline-flex",...f},...g,children:ce(h,{component:"ul",sx:{display:"flex",alignItems:"center",gap:S.gap,listStyle:"none",m:0,p:0,flexWrap:"wrap"},children:[u&&de(h,{component:"li",children:de(In,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||1===y,onClick:()=>k(1),"aria-label":"Go to first page",children:de(jo,{size:"small",children:de(qt,{})})})}),de(h,{component:"li",children:de(In,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||1===y,onClick:()=>k(y-1),"aria-label":"Go to previous page",children:de(jo,{size:"small",children:de(Xt,{})})})}),B.map((e,t)=>{if("string"==typeof e)return de(h,{component:"li",children:de(bo,{style:{color:"var(--Quiet)",padding:"0 4px"},"aria-hidden":"true",children:"…"})},e+"-"+t);const r=e===y;return de(h,{component:"li",children:de(In,{variant:r?w:w+"-outline",size:S.btnSize,disabled:c,onClick:()=>k(e),"aria-label":"Page "+e,"aria-current":r?"page":void 0,letterNumber:!0,children:e})},e)}),de(h,{component:"li",children:de(In,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||y===e,onClick:()=>k(y+1),"aria-label":"Go to next page",children:de(jo,{size:"small",children:de(Kt,{})})})}),p&&de(h,{component:"li",children:de(In,{iconOnly:!0,variant:w+"-outline",size:S.btnSize,disabled:c||y===e,onClick:()=>k(e),"aria-label":"Go to last page",children:de(jo,{size:"small",children:de(Jt,{})})})})]})})}const Bd=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",wd=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function Cd({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Td({color:e,selected:t,onClick:r}){const o=Bd(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Id(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(10),[l,s]=r(!1),[d,c]=r(!1),[u,p]=r(!1),[m,f]=r(null),[g,x]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Pagination"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:m,surface:g,children:de(kd,{color:e,size:o,count:i,showFirstButton:l,showLastButton:d,disabled:u})}),de(Vi,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),10!==i&&t.push("count={"+i+"}"),l&&t.push("showFirstButton"),d&&t.push("showLastButton"),u&&t.push("disabled"),t.push("onChange={handlePageChange}"),1===t.length?"<Pagination onChange={handlePageChange} />":"<Pagination\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:m,onThemeChange:f,surface:g,onSurfaceChange:x})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:wd.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(Td,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Cd,{label:Bd(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PAGES"}),de(B,{direction:"row",spacing:1,children:[5,10,20,50].map(e=>de(Cd,{label:String(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"First/Last Buttons"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show jump to first/last page"})]}),de(ta,{variant:"default-outline",checked:l,onChange:e=>{s(e.target.checked),c(e.target.checked)},size:"small","aria-label":"First/last buttons"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disabled"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Non-interactive state"})]}),de(ta,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Disabled"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Nav",value:'<nav aria-label="Pagination">'},{label:"List",value:"<ol> with <li> for each button"},{label:"Current",value:'aria-current="page" on selected page'},{label:"Labels",value:'aria-label="Page N", "Go to previous/next/first/last page"'},{label:"Keyboard",value:"Tab navigates between buttons"},{label:"Focus",value:"Uses Button component focus styles"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Ad=e=>e.charAt(0).toUpperCase()+e.slice(1),zd={small:{py:"4px",itemPx:"8px",itemPy:"4px",fontSize:"13px",minWidth:"140px"},medium:{py:"6px",itemPx:"12px",itemPy:"6px",fontSize:"14px",minWidth:"160px"},large:{py:"8px",itemPx:"16px",itemPy:"8px",fontSize:"16px",minWidth:"180px"}},Rd=s({open:!1,setOpen:()=>{},anchorRef:{current:null},menuId:"",buttonId:"",variant:"outline",color:"default",size:"medium"}),Ed=()=>l(Rd);function Pd({children:e,variant:t="outline",color:i="default",size:l="medium",open:s,onOpenChange:d,...c}){const[u,p]=r(!1),m=void 0!==s,f=m?s:u,g=o(null),x=a(),b="menu-"+x,v="menubtn-"+x,y=n(e=>{const t="function"==typeof e?e(f):e;m?d?.(t):p(t)},[m,f,d]);return de(Rd.Provider,{value:{open:f,setOpen:y,anchorRef:g,menuId:b,buttonId:v,variant:t,color:i,size:l},children:de(h,{sx:{display:"inline-flex",position:"relative"},...c,children:e})})}function Od({children:e,className:t="",sx:r={},...o}){const{open:n,setOpen:i,anchorRef:a,menuId:l,buttonId:s,size:d,color:c}=Ed(),u=zd[d]||zd.medium,p=Ad("default"===c?"Default":c);return ce(h,{component:"button",ref:a,id:s,"aria-haspopup":"true","aria-expanded":n,"aria-controls":n?l:void 0,onClick:()=>i(e=>!e),className:"menu-button "+t,sx:{display:"inline-flex",alignItems:"center",gap:"6px",padding:u.itemPy+" "+u.itemPx,fontSize:u.fontSize,fontFamily:"inherit",fontWeight:600,color:"var(--Text)",backgroundColor:"var(--Background)",border:"1px solid var(--Buttons-"+p+"-Border)",borderRadius:"var(--Style-Border-Radius)",cursor:"pointer",boxShadow:"none",transition:"box-shadow 0.15s ease","&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"},...r},onKeyDown:e=>{"ArrowDown"!==e.key&&"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),i(!0))},...o,children:["string"==typeof e?de("small"===d?ao:co,{style:{color:"inherit",fontWeight:600},children:e}):e,de(jo,{size:"small",sx:{color:"var(--Quiet)",transition:"transform 0.2s ease",transform:n?"rotate(180deg)":"rotate(0deg)"},children:de(Se,{})})]})}function Ld({children:e,className:t="",placement:r="bottom-start",sx:n={},...a}){const{open:l,setOpen:s,anchorRef:d,menuId:c,buttonId:u,variant:p,color:m,size:f}=Ed(),g=o(null),x=zd[f]||zd.medium,b=Ad("default"===m?"Default":m),v="var(--Buttons-"+b+"-Border)",y="light"===p?"default"===m?"Default":b:"solid"===p?b:void 0,S="light"===p?"Surface-Brightest":"solid"===p?"Surface":void 0;return i(()=>{if(l&&g.current){const e=g.current.querySelector('[role="menuitem"]:not([aria-disabled="true"])');e&&e.focus()}},[l]),i(()=>{if(!l)return;const e=e=>{g.current&&!g.current.contains(e.target)&&d.current&&!d.current.contains(e.target)&&s(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[l,s,d]),i(()=>{if(!l)return;const e=e=>{"Escape"===e.key&&(s(!1),d.current?.focus())};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[l,s,d]),l?de(h,{className:"menu menu-"+p+" "+t,sx:{position:"absolute",top:"100%",left:"bottom-end"===r?"auto":0,right:"bottom-end"===r?0:"auto",zIndex:99999,marginTop:"4px",border:"1px solid "+v,borderRadius:"var(--Dropdown-Frame-Radius, var(--Input-Radius, var(--Style-Border-Radius, 4px)))",boxShadow:"none",overflow:"hidden",...n},children:de(h,{ref:g,id:c,role:"menu","aria-labelledby":u,"data-theme":y,"data-surface":S,sx:{minWidth:x.minWidth,backgroundColor:"var(--Background)",color:"var(--Text)",fontSize:x.fontSize,fontFamily:"inherit",padding:x.py+" 0",outline:"none",borderRadius:"calc(var(--Dropdown-Frame-Radius, var(--Input-Radius, var(--Style-Border-Radius, 4px))) - 1px)"},onKeyDown:e=>{const t=g.current?.querySelectorAll('[role="menuitem"]:not([aria-disabled="true"])');if(!t?.length)return;const r=Array.from(t).indexOf(document.activeElement);"ArrowDown"===e.key?(e.preventDefault(),t[(r+1)%t.length].focus()):"ArrowUp"===e.key?(e.preventDefault(),t[(r-1+t.length)%t.length].focus()):"Home"===e.key?(e.preventDefault(),t[0].focus()):"End"===e.key?(e.preventDefault(),t[t.length-1].focus()):"Tab"===e.key&&s(!1)},...a,children:e})}):null}function Md({children:e,onClick:t,selected:r=!1,disabled:o=!1,className:n="",sx:i={},...a}){const{setOpen:l,size:s}=Ed(),d=zd[s]||zd.medium,c="small"===s?ao:co,u=()=>{o||(t?.(),l(!1))};return de(h,{role:"menuitem",tabIndex:o?-1:0,"aria-disabled":o||void 0,"aria-selected":r||void 0,onClick:u,onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),u())},className:"menu-item"+(r?" menu-item-selected":"")+" "+n,sx:{display:"flex",alignItems:"center",gap:"8px",padding:d.itemPy+" "+d.itemPx,color:o?"var(--Quiet)":r?"var(--Text)":"var(--Quiet)",backgroundColor:r?"var(--Hover)":"transparent",cursor:o?"not-allowed":"pointer",opacity:o?.5:1,outline:"none",transition:"background-color 0.1s ease, color 0.1s ease",userSelect:"none",...!o&&{"&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{backgroundColor:"var(--Hover)",color:"var(--Text)",outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},...i},...a,children:de(c,{style:{color:"inherit",fontWeight:r?600:"inherit"},children:e})})}function Wd({className:e="",sx:t={},...r}){return de(h,{component:"hr",role:"separator",className:"menu-divider "+e,sx:{border:"none",borderTop:"1px solid var(--Border)",margin:"4px 0",...t},...r})}const Dd=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Fd=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function Nd({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Hd({color:e,selected:t,onClick:r}){const o=Dd(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Vd(){const[e,t]=r("outline"),[o,n]=r("default"),[i,a]=r("medium"),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Menu"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:l,surface:d,sx:{minHeight:250,alignItems:"flex-start",pt:6},children:ce(Pd,{variant:e,color:o,size:i,children:[de(Od,{children:"Actions"}),ce(Ld,{children:[de(Md,{children:"Edit"}),de(Md,{children:"Duplicate"}),de(Md,{selected:!0,children:"Archive"}),de(Wd,{}),de(Md,{disabled:!0,children:"Delete"})]})]})}),de(Vi,{code:(()=>{const t=[];return"outline"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),"<Dropdown "+t.join(" ")+">\n <MenuButton>Actions</MenuButton>\n <Menu>\n <MenuItem>Edit</MenuItem>\n <MenuItem>Duplicate</MenuItem>\n <MenuDivider />\n <MenuItem>Delete</MenuItem>\n </Menu>\n</Dropdown>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["outline","solid","light"].map(r=>de(Nd,{label:Dd(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Fd.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Hd,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Nd,{label:Dd(e),selected:i===e,onClick:()=>a(e)},e))})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Button",value:'aria-haspopup="true" aria-expanded aria-controls'},{label:"Menu",value:'role="menu" aria-labelledby={buttonId}'},{label:"Items",value:'role="menuitem" with tabIndex'},{label:"Selected",value:'aria-selected="true" on active item'},{label:"Disabled",value:'aria-disabled="true", not focusable'},{label:"Keyboard",value:"Arrow keys navigate. Enter/Space selects. Escape closes."},{label:"Focus",value:"First item focused on open. Focus returns to button on close."}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Qd={default:"Nav-Bar",primary:"Primary","primary-light":"Primary-Light","primary-medium":"Primary-Medium","primary-dark":"Primary-Dark",white:"White",black:"Black"};function jd({items:e=[],value:t,defaultValue:o=0,onChange:i,showLabels:a=!0,labelOrientation:l="vertical",backfill:s=!0,barColor:d="default",fixed:c=!0,className:u="",sx:p={},...m}){const[f,g]=r(o),x=void 0!==t,b=x?t:f,v=n(e=>{x||g(e),i?.(e)},[x,i]),y="horizontal"===(e.length>4?"vertical":l);return de(h,{component:"nav",role:"navigation","aria-label":"Bottom navigation","data-theme":Qd[d]||Qd.default,"data-surface":"Surface-Dim",className:"bottom-nav bottom-nav-"+d+(a?" bottom-nav-labels":"")+(y&&a?" bottom-nav-horizontal":"")+(s?" bottom-nav-backfill":"")+(c?" bottom-nav-fixed":"")+(u?" "+u:""),sx:{display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"var(--Background)",borderTop:"1px solid var(--Border)",fontFamily:"inherit",width:"100%",...c&&{position:"fixed",bottom:0,left:0,right:0,zIndex:1100},...p},...m,children:de(h,{role:"tablist",sx:{display:"flex",alignItems:"center",justifyContent:"space-around",width:"100%",maxWidth:600,height:a&&!y?72:64,px:1},children:e.map((e,t)=>{const r=t===b;return de(Gd,{icon:e.icon,label:e.label,selected:r,showLabel:a,horizontal:y,backfill:s,onClick:()=>v(t),ariaLabel:e.label||"Tab "+(t+1)},e.key||t)})})})}function Gd({icon:e,label:t,selected:r,showLabel:o,horizontal:n,backfill:i,onClick:a,ariaLabel:l}){const s="var(--Text-Quiet)",d="var(--Text)",c="var(--Buttons-Primary-Text)",u=r?i&&n?c:d:s,p=!n,m=ce(h,{sx:{display:"flex",flexDirection:n?"row":"column",alignItems:"center",justifyContent:"center",gap:n?.75:0,...r&&i&&{backgroundColor:"var(--Buttons-Primary-Button)",border:"1px solid var(--Buttons-Primary-Border)",borderRadius:"16px",px:n?2:2.5,py:.5},...r&&i?{}:{px:n?1:0,border:"1px solid transparent"},transition:"background-color 0.2s ease, border-color 0.2s ease"},children:[de(h,{sx:{display:"flex",alignItems:"center",justifyContent:"center",fontSize:"24px",color:r?i?c:d:s,transition:"color 0.15s ease","& .MuiSvgIcon-root":{fontSize:"inherit",color:"inherit"}},children:e}),o&&n&&t&&de(h,{sx:{fontSize:"13px",fontWeight:r?600:500,color:r&&i?c:r?d:s,whiteSpace:"nowrap",lineHeight:1,transition:"color 0.15s ease"},children:t})]});return ce(h,{component:"button",type:"button",role:"tab","aria-selected":r,"aria-label":l,onClick:a,sx:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",flex:1,gap:p&&o?.25:0,border:"none",backgroundColor:"transparent",cursor:"pointer",outline:"none",fontFamily:"inherit",py:1,minWidth:0,transition:"transform 0.1s ease","&:hover":{transform:"scale(1.04)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-2px",borderRadius:"8px"}},children:[m,o&&p&&t&&de(h,{sx:{fontSize:"11px",fontWeight:r?600:400,color:u,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%",lineHeight:1.2,mt:.25,transition:"color 0.15s ease"},children:t})]})}const Ud={Home:de(Be,{sx:{fontSize:"inherit"}}),Explore:de(Yt,{sx:{fontSize:"inherit"}}),Radio:de(Zt,{sx:{fontSize:"inherit"}}),Library:de($t,{sx:{fontSize:"inherit"}}),Favorite:de(ke,{sx:{fontSize:"inherit"}}),Person:de(me,{sx:{fontSize:"inherit"}}),Search:de(Te,{sx:{fontSize:"inherit"}}),Settings:de(Ce,{sx:{fontSize:"inherit"}}),Notifications:de(Ae,{sx:{fontSize:"inherit"}}),Cart:de(Re,{sx:{fontSize:"inherit"}}),Star:de(Ie,{sx:{fontSize:"inherit"}}),Bookmark:de(_t,{sx:{fontSize:"inherit"}})},Xd=Object.keys(Ud),Kd=[{icon:"Home",label:"Home"},{icon:"Explore",label:"Browse"},{icon:"Radio",label:"Radio"},{icon:"Library",label:"Library"}],qd=[{value:"default",label:"Default",desc:'data-theme="Nav-Bar"'},{value:"primary",label:"Primary",desc:'data-theme="Primary"'},{value:"primary-light",label:"Primary Light",desc:'data-theme="Primary-Light"'},{value:"primary-medium",label:"Primary Medium",desc:'data-theme="Primary-Medium"'},{value:"primary-dark",label:"Primary Dark",desc:'data-theme="Primary-Dark"'},{value:"white",label:"White",desc:'data-theme="White"'},{value:"black",label:"Black",desc:'data-theme="Black"'}];function Jd({label:e,selected:t,onClick:r,disabled:o}){return de(h,{component:"button",onClick:r,disabled:o,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",cursor:o?"not-allowed":"pointer",border:"2px solid var(--Buttons-Primary-Button)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:t?"var(--Buttons-Primary-Button)":"transparent",color:t?"var(--Buttons-Primary-Text)":"var(--Text)",padding:"4px 12px",fontSize:"14px",fontFamily:"inherit",fontWeight:500,whiteSpace:"nowrap",flexShrink:0,opacity:o?.4:1,transition:"background-color 0.15s ease, color 0.15s ease","&:hover":{backgroundColor:o?"transparent":t?"var(--Buttons-Primary-Hover)":"var(--Surface-Dim)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:e})}function Yd({value:e,onChange:t,placeholder:r,sx:o}){return de(h,{component:"input",type:"text",value:e,onChange:e=>t(e.target.value),placeholder:r,sx:{flex:1,padding:"4px 8px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none",minWidth:0,"&:focus":{borderColor:"var(--Focus-Visible)"},...o}})}function Zd({value:e,onChange:t,options:r,label:o}){return de(h,{component:"select",value:e,onChange:e=>t(e.target.value),"aria-label":o,sx:{padding:"4px 6px",fontSize:"13px",fontFamily:"inherit",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",outline:"none",cursor:"pointer","&:focus":{borderColor:"var(--Focus-Visible)"}},children:r.map(e=>de("option",{value:"string"==typeof e?e:e.value,children:"string"==typeof e?e:e.label},"string"==typeof e?e:e.value))})}function $d({value:e,onChange:t,min:r,max:o,label:n}){return ce(h,{sx:{display:"flex",alignItems:"center",gap:1},children:[de(bo,{style:{color:"var(--Text-Quiet)",flexShrink:0,width:90},children:n}),de("button",{type:"button",onClick:()=>{e>r&&t(e-1)},disabled:e<=r,style:{width:28,height:28,display:"flex",alignItems:"center",justifyContent:"center",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",cursor:e<=r?"not-allowed":"pointer",fontSize:"14px",opacity:e<=r?.4:1,fontFamily:"inherit"},children:"−"}),de(h,{sx:{fontWeight:700,fontSize:"14px",minWidth:24,textAlign:"center"},children:e}),de("button",{type:"button",onClick:()=>{e<o&&t(e+1)},disabled:e>=o,style:{width:28,height:28,display:"flex",alignItems:"center",justifyContent:"center",border:"1px solid var(--Border)",borderRadius:"4px",backgroundColor:"var(--Background)",color:"var(--Text)",cursor:e>=o?"not-allowed":"pointer",fontSize:"14px",opacity:e>=o?.4:1,fontFamily:"inherit"},children:"+"})]})}function _d({label:e,checked:t,onChange:r,caption:o,disabled:n}){return ce(h,{sx:{py:.5,opacity:n?.4:1},children:[de(v,{control:de(b,{checked:t,onChange:e=>r(e.target.checked),size:"small",disabled:n,sx:{color:"var(--Text-Quiet)","&.Mui-checked":{color:"var(--Buttons-Primary-Button)"}}}),label:de(ko,{children:e}),sx:{m:0}}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginLeft:32},children:o})]})}function ec(){const[e,t]=r(0),[o,n]=r(0),[a,l]=r(!0),[s,d]=r(!0),[c,u]=r("vertical"),[p,m]=r(!0),[f,g]=r("default"),[x,b]=r(4),[v,y]=r(Kd.map(e=>({icon:e.icon,label:e.label}))),S=x<=4;i(()=>{x>4&&"horizontal"===c&&u("vertical")},[x,c]),i(()=>{y(e=>{const t=[],r=[{icon:"Favorite",label:"Favorites"},{icon:"Person",label:"Profile"}];for(let o=0;o<x;o++)if(e[o])t.push(e[o]);else{const e=r[o-Kd.length]||{icon:Xd[o%Xd.length],label:Xd[o%Xd.length]};t.push(e)}return t}),n(e=>Math.min(e,x-1))},[x]);const k=(e,t,r)=>{y(o=>{const n=[...o];return n[e]={...n[e],[t]:r},n})},w=v.slice(0,x).map(e=>({icon:Ud[e.icon]||Ud.Home,label:e.label}));return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Bottom Navigation"}),ce(N,{value:e,onChange:(e,r)=>t(r),sx:{mt:3,mb:0,borderBottom:"1px solid var(--Border)","& .MuiTabs-indicator":{backgroundColor:"var(--Buttons-Primary-Button)",height:3},"& .MuiTab-root":{color:"var(--Text-Quiet)",textTransform:"none",fontWeight:500,"&.Mui-selected":{color:"var(--Text)"}}},children:[de(H,{label:"Playground"}),de(H,{label:"Accessibility"})]}),0===e&&ce(I,{container:!0,sx:{minHeight:400},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"calc((100vw - 432px) / 2)"},flexShrink:0},children:[ce(h,{sx:{p:4,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",minHeight:300,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)",gap:4},children:[de(h,{sx:{width:"100%",maxWidth:500,overflow:"hidden",boxShadow:"0 2px 12px rgba(0,0,0,0.08)"},children:de(jd,{items:w,value:o,onChange:n,showLabels:s,labelOrientation:c,backfill:p,barColor:f,fixed:!1},"bn-"+x+"-"+c+"-"+p+"-"+s+"-"+f)}),ce(bo,{style:{color:"var(--Text-Quiet)",textAlign:"center"},children:[x," items · ",s?"horizontal"===c&&S?"Horizontal labels":"Vertical labels":"Icons only",p?" · Backfill":""," · ",(qd.find(e=>e.value===f)||qd[0]).label]})]}),de(Vi,{code:(()=>{const e=[];e.push("const items = ["),w.forEach((t,r)=>{const o=v[r];e.push(" { icon: <"+o.icon+"Icon />, label: '"+o.label+"' },")}),e.push("];"),e.push("");const t=[];return t.push("items={items}"),"default"!==f&&t.push('barColor="'+f+'"'),s||t.push("showLabels={false}"),s&&"horizontal"===c&&S&&t.push('labelOrientation="horizontal"'),p||t.push("backfill={false}"),a||t.push("fixed={false}"),e.push("<BottomNavigation"),t.forEach(t=>e.push(" "+t)),e.push("/>"),e.join("\n")})(),language:"JSX",sx:{borderRadius:0,borderBottom:"1px solid var(--Border)"}})]}),ce(I,{item:!0,sx:{width:{xs:"calc(100vw - 432px)",md:"calc((100vw - 432px) / 2)"},flexShrink:0,p:3,backgroundColor:"var(--Container)",overflowY:"auto"},children:[de(Yr,{children:"Playground"}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BAR COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:qd.map(e=>de(Jd,{label:e.label,selected:f===e.value,onClick:()=>g(e.value)},e.value))}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:[(qd.find(e=>e.value===f)||qd[0]).desc,' · data-surface="Surface-Dim" · bg: var(--Background)']})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(B,{spacing:0,children:[de(_d,{label:"Fixed",checked:a,onChange:l,caption:"Position fixed to bottom of viewport."}),de(_d,{label:"Labels",checked:s,onChange:d,caption:"Show text labels with icons."}),de(_d,{label:"Selected Backfill",checked:p,onChange:m,caption:"Pill on selected: bg var(--Buttons-Primary-Button), border var(--Buttons-Primary-Border), icon var(--Buttons-Primary-Text)."})]})]}),s&&ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LABEL ORIENTATION"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[de(Jd,{label:"Vertical",selected:"vertical"===c,onClick:()=>u("vertical")}),de(Jd,{label:"Horizontal",selected:"horizontal"===c&&S,onClick:()=>{S&&u("horizontal")},disabled:!S})]}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:S?"vertical"===c?"Icon above label (default). Label below pill.":"Icon beside label. Label inside pill when backfill is on.":"Horizontal is only available with 4 or fewer items. Reduce item count to enable."})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"NAVIGATION ITEMS"}),de($d,{label:"Count",value:x,onChange:b,min:3,max:6}),de(B,{spacing:1.5,sx:{mt:2},children:v.slice(0,x).map((e,t)=>ce(h,{sx:{display:"flex",alignItems:"center",gap:1,flexWrap:"nowrap"},children:[de(bo,{style:{color:"var(--Text-Quiet)",flexShrink:0,width:16,textAlign:"right"},children:t+1}),de(Zd,{value:e.icon,onChange:e=>k(t,"icon",e),options:Xd,label:"Item "+(t+1)+" icon"}),s&&de(Yd,{value:e.label,onChange:e=>k(t,"label",e),placeholder:"Label"})]},t))})]})]})]}),1===e&&ce(h,{sx:{p:4},children:[de(Yr,{children:"Accessibility Requirements"}),ce(ao,{color:"quiet",style:{marginBottom:32},children:[x," items · ",s?"Labels "+c:"Icons only",p?" · Backfill":""," · ",(qd.find(e=>e.value===f)||qd[0]).label]}),ce(B,{spacing:4,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Landmark:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<nav role="navigation" aria-label="Bottom navigation">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Tab list:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'role="tablist"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Tab items:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'role="tab", aria-selected, aria-label'})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Focus:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"3px solid var(--Focus-Visible) on :focus-visible."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Token Reference"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Bar:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'Always: data-surface="Surface-Dim" · bg: var(--Background). Theme set by data-theme (Nav-Bar, Primary, Primary-Light, etc.).'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Unselected icon/label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Text-Quiet)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Selected (no backfill):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Text)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Selected backfill pill:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"bg: var(--Buttons-Primary-Button) · border: 1px solid var(--Buttons-Primary-Border) · icon/text: var(--Buttons-Primary-Text)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Backfill + horizontal label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"Label inside pill: var(--Buttons-Primary-Text)"})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Backfill + vertical label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"Label below pill: var(--Text)"})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Best Practices"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Item count:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"3–5 recommended. 6 maximum."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Horizontal layout:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Only available with 4 or fewer items."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Labels:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Always recommended for clarity."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Fixed:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Add bottom padding to main content to avoid overlap."})]})]})]})]})]})]})}const tc={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},rc={small:{indicator:24,fontSize:"11px",labelFontSize:"13px",connectorThickness:2,gap:0},medium:{indicator:32,fontSize:"13px",labelFontSize:"14px",connectorThickness:2,gap:0},large:{indicator:40,fontSize:"16px",labelFontSize:"16px",connectorThickness:2,gap:0}},oc=s({orientation:"horizontal",size:"medium",color:"primary",activeStep:0,clickable:!1,onStepClick:null,dashedIncomplete:!1,totalSteps:0}),nc=()=>l(oc);function ic({children:e,orientation:r="horizontal",size:o="medium",color:n="primary",activeStep:i=0,clickable:a=!1,onStepClick:l,dashedIncomplete:s=!1,className:d="",sx:c={},...u}){const p=t.Children.toArray(e).filter(t.isValidElement),m=p.length,f="horizontal"===r;return de(oc.Provider,{value:{orientation:r,size:o,color:n,activeStep:i,clickable:a,onStepClick:l,dashedIncomplete:s,totalSteps:m},children:de(h,{component:"ol",role:"list","aria-label":"Progress",className:"stepper stepper-"+r+" stepper-"+o+" stepper-"+n+" "+d,sx:{display:"flex",flexDirection:f?"row":"column",alignItems:f?"flex-start":"stretch",listStyle:"none",margin:0,padding:0,width:"100%",gap:0,...c},...u,children:p.map((e,r)=>t.cloneElement(e,{_index:r,key:e.key||r}))})})}function ac({children:e,icon:t,label:r,_index:o=0,className:n="",sx:i={},...a}){const{orientation:l,size:s,color:d,activeStep:c,clickable:u,onStepClick:p,dashedIncomplete:m,totalSteps:f}=nc(),g=rc[s]||rc.medium,x=tc[d]||"Primary",b="horizontal"===l,v=o===c,y=o<c,S=o>c,k=o===f-1,B=t||o+1,w=r||e,C="var(--Buttons-"+x+"-Border)",T=v||y?"var(--Buttons-"+x+"-Button)":"transparent",I=v||y?"var(--Buttons-"+x+"-Text)":"var(--Text)",A=v||y?"var(--Buttons-"+x+"-Hover)":"var(--Hover)",z=v||y?"var(--Buttons-"+x+"-Pressed)":"var(--Pressed)",R=de(h,{component:u?"button":"div",onClick:u?()=>p?.(o):void 0,onKeyDown:u?e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),p?.(o))}:void 0,tabIndex:u?0:void 0,role:u?"button":void 0,"aria-label":u?"Go to step "+(o+1):void 0,"aria-current":v?"step":void 0,className:"step-indicator step-indicator-"+s+(v?" step-indicator-active":"")+(y?" step-indicator-completed":"")+(S?" step-indicator-incomplete":"")+(u?" step-indicator-clickable":""),sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:g.indicator+"px",height:g.indicator+"px",minWidth:g.indicator+"px",minHeight:g.indicator+"px",borderRadius:"50%",border:(v?"2px":"1px")+" solid "+C,backgroundColor:T,color:I,fontSize:g.fontSize,fontFamily:"inherit",fontWeight:700,lineHeight:1,flexShrink:0,position:"relative",transition:"background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease",cursor:u?"pointer":"default",outline:"none",padding:0,..."small"===s&&{"&::after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"24px",height:"24px",borderRadius:"50%"}},...u&&{"&:hover":{backgroundColor:A},"&:active":{backgroundColor:z},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px"}}},children:B}),E=k?null:de(h,{className:"step-connector"+(y?" step-connector-completed":"")+(S?" step-connector-incomplete":"")+(m&&S?" step-connector-dashed":""),"aria-hidden":"true",sx:{flex:1,...b?{height:g.connectorThickness+"px",minWidth:"20px",alignSelf:"flex-start",marginTop:g.indicator/2-g.connectorThickness/2+"px",marginLeft:"8px",marginRight:"8px"}:{width:g.connectorThickness+"px",minHeight:"24px",marginLeft:g.indicator/2-g.connectorThickness/2+"px",marginTop:"4px",marginBottom:"4px"},backgroundColor:y?"var(--Buttons-"+x+"-Button)":"var(--Border)",...m&&S&&{backgroundColor:"transparent",backgroundImage:b?"repeating-linear-gradient(90deg, var(--Border) 0px, var(--Border) 6px, transparent 6px, transparent 12px)":"repeating-linear-gradient(180deg, var(--Border) 0px, var(--Border) 6px, transparent 6px, transparent 12px)",backgroundSize:b?"12px 100%":"100% 12px"},transition:"background-color 0.15s ease"}}),P=w?de("small"===s?bo:ao,{style:{fontWeight:v?600:400,color:v||y?"var(--Text)":"var(--Quiet)",textAlign:b?"center":"left",whiteSpace:"nowrap",lineHeight:1.3},children:w}):null;return ce(h,b?{component:"li",className:"step step-"+s+" step-horizontal"+(v?" step-active":"")+(y?" step-completed":"")+(S?" step-incomplete":"")+" "+n,sx:{display:"flex",alignItems:"center",flex:k?"none":1,...i},...a,children:[ce(h,{sx:{display:"flex",flexDirection:"column",alignItems:"center",flexShrink:0},children:[R,P&&de(h,{sx:{mt:"4px"},children:P})]}),E]}:{component:"li",className:"step step-"+s+" step-vertical"+(v?" step-active":"")+(y?" step-completed":"")+(S?" step-incomplete":"")+" "+n,sx:{display:"flex",flexDirection:"column",alignItems:"flex-start",...i},...a,children:[ce(h,{sx:{display:"flex",alignItems:"center",gap:"8px"},children:[R,P]}),E]})}const lc=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",sc=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],dc=["Account","Details","Review","Confirm","Complete","Done"];function cc({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function uc({color:e,selected:t,onClick:r}){const o=lc(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function pc(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r("horizontal"),[l,s]=r(4),[d,c]=r(1),[u,p]=r(!1),[m,f]=r(!1),[g,x]=r(null),[b,v]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Stepper"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:g,surface:b,children:de(h,{sx:{width:"100%",maxWidth:"vertical"===i?300:"100%"},children:de(ic,{color:e,size:o,orientation:i,activeStep:d,clickable:u,onStepClick:u?c:void 0,dashedIncomplete:m,children:dc.slice(0,l).map(e=>de(ac,{label:e},e))})})}),de(Vi,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),"horizontal"!==i&&t.push('orientation="vertical"'),t.push("activeStep={"+d+"}"),u&&t.push("clickable onStepClick={setActiveStep}"),m&&t.push("dashedIncomplete"),"<Stepper "+t.join(" ")+">\n"+dc.slice(0,l).map(e=>' <Step label="'+e+'" />').join("\n")+"\n</Stepper>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:g,onThemeChange:x,surface:b,onSurfaceChange:v})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STEPS"}),de(B,{direction:"row",spacing:1,children:[2,3,4,5,6].map(e=>de(cc,{label:String(e),selected:l===e,onClick:()=>{s(e),d>=e&&c(e-1)}},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ACTIVE STEP"}),de(B,{direction:"row",spacing:1,children:dc.slice(0,l).map((e,t)=>de(cc,{label:String(t+1),selected:d===t,onClick:()=>c(t)},t))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:sc.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(uc,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(cc,{label:lc(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ORIENTATION"}),de(B,{direction:"row",spacing:1,children:["horizontal","vertical"].map(e=>de(cc,{label:lc(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clickable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Steps are interactive buttons"})]}),de(ta,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Clickable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Dashed Incomplete"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Dashed connector for future steps"})]}),de(ta,{variant:"default-outline",checked:m,onChange:e=>f(e.target.checked),size:"small","aria-label":"Dashed incomplete"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Container",value:'<ol role="list" aria-label="Progress">'},{label:"Steps",value:"<li> elements with step state classes"},{label:"Active",value:'aria-current="step" on the active indicator'},{label:"Clickable",value:'role="button" aria-label="Go to step N" with tabIndex'},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: 2px"},{label:"Connectors",value:'aria-hidden="true" — decorative only'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}function hc({actions:e=[],variant:t="solid",color:a="default",direction:l="up",speed:s=50,showTooltips:d=!0,open:c,onOpen:u,onClose:p,icon:m,ariaLabel:f="Speed Dial",className:g="",sx:x={},...b}){const[v,y]=r(!1),S=void 0!==c,k=S?c:v,B=o(null),C=t,T=n(()=>{k?(S||y(!1),p?.()):(S||y(!0),u?.())},[k,S,u,p]),I=n((e,t)=>{e.onClick?.(t),S||y(!1),p?.()},[S,p]);i(()=>{if(!k)return;const e=e=>{B.current&&!B.current.contains(e.target)&&(S||y(!1),p?.())};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[k,S,p]),i(()=>{if(!k)return;const e=e=>{"Escape"===e.key&&(S||y(!1),p?.())};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[k,S,p]);const A="up"===l||"down"===l,z="up"===l||"down"===l?"left":"top";return ce(h,{ref:B,className:"speed-dial speed-dial-"+t+" speed-dial-"+a+" speed-dial-"+l+" "+g,sx:{position:"relative",display:"inline-flex",overflow:"visible",width:A?"56px":"auto",height:A?"auto":"56px",...x},...b,children:[de(Ga,{size:"large",variant:C,color:a,onClick:T,"aria-label":f,"aria-expanded":k,"aria-haspopup":"menu",sx:{position:"relative",zIndex:2},children:de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",transition:"transform 0.3s ease",transform:k?"rotate(45deg)":"rotate(0deg)"},children:m||de(At,{})})}),de(h,{role:"menu",sx:{position:"absolute",inset:0,pointerEvents:"none",overflow:"visible"},children:e.map((e,t)=>{const r=(e=>{const t=56+44*e;switch(l){case"up":default:return{bottom:t+"px",left:"12px"};case"down":return{top:t+"px",left:"12px"};case"left":return{right:t+"px",top:"12px"};case"right":return{left:t+"px",top:"12px"}}})(t),o=t*s,n=de(Ga,{size:"small",variant:C,color:a,role:"menuitem","aria-label":e.name||"Action "+(t+1),onClick:()=>I(e,t),sx:{position:"absolute",...r,opacity:k?1:0,transform:k?"scale(1)":"scale(0.3)",transition:"opacity 0.2s ease, transform 0.2s ease",transitionDelay:k?o+"ms":"0ms",pointerEvents:k?"auto":"none"},children:e.icon||de(At,{})},e.key||t);return d&&e.name?de(w,{title:e.name,placement:z,arrow:!0,open:!!k&&void 0,slotProps:{tooltip:{sx:{backgroundColor:"var(--Container)",color:"var(--Text)",fontSize:"12px",fontWeight:500,border:"1px solid var(--Border)",boxShadow:"0 2px 8px rgba(0,0,0,0.12)"}},arrow:{sx:{color:"var(--Container)"}}},children:n},e.key||t):n})})]})}const mc=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",fc=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],gc=[{name:"Edit",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(er,{})})},{name:"Share",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(tr,{})})},{name:"Delete",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(we,{})})},{name:"Favorite",icon:de(jo,{size:"small",sx:{color:"inherit"},children:de(ke,{})})}];function xc({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function bc({color:e,selected:t,onClick:r}){const o=mc(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function vc(){const[e,t]=r("solid"),[o,n]=r("default"),[i,a]=r("up"),[l,s]=r(!0),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Speed Dial"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:d,surface:u,sx:{minHeight:300,alignItems:"flex-end",justifyContent:"center"},children:de(hc,{variant:e,color:o,direction:i,showTooltips:l,actions:gc,ariaLabel:"Quick actions"})}),de(Vi,{code:(()=>{const t=[];return"solid"!==e&&t.push('variant="'+e+'"'),"default"!==o&&t.push('color="'+o+'"'),"up"!==i&&t.push('direction="'+i+'"'),l||t.push("showTooltips={false}"),t.push("actions={actions}"),t.push('ariaLabel="Quick actions"'),"<SpeedDial\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["solid","outline"].map(r=>de(xc,{label:mc(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:fc.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(bc,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"DIRECTION"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["up","down","left","right"].map(e=>de(xc,{label:mc(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Tooltips"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show labels beside actions"})]}),de(ta,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Show tooltips"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"FAB",value:'aria-expanded, aria-haspopup="menu", aria-label'},{label:"Actions",value:'role="menu" container, role="menuitem" on each action'},{label:"Labels",value:"aria-label on each action from name prop"},{label:"Keyboard",value:"Escape closes. Click outside closes."},{label:"Focus",value:"outline: 3px solid var(--Focus-Visible); outline-offset: 2px"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const yc={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",black:"BW",white:"BW"};function Sc(e,t){return"var(--"+(yc[e]||"Primary")+"-Color-"+t+")"}const kc={primary:{linear:[{family:"primary",tone:8,position:0},{family:"primary",tone:11,position:100}],radial:[{family:"primary",tone:8,position:0},{family:"primary",tone:11,position:100}],mesh:[{family:"primary",tone:8,x:20,y:20,spread:60},{family:"primary",tone:9,x:80,y:30,spread:50},{family:"primary",tone:10,x:50,y:80,spread:55}],meshCard:[{family:"primary",tone:3,x:10,y:10,spread:60},{family:"primary",tone:6,x:80,y:20,spread:50},{family:"primary",tone:9,x:40,y:80,spread:55}]},secondary:{linear:[{family:"secondary",tone:7,position:0},{family:"secondary",tone:10,position:100}],radial:[{family:"secondary",tone:7,position:0},{family:"secondary",tone:10,position:100}],mesh:[{family:"secondary",tone:7,x:15,y:25,spread:55},{family:"secondary",tone:9,x:75,y:35,spread:50},{family:"secondary",tone:11,x:45,y:75,spread:60}],meshCard:[{family:"secondary",tone:2,x:15,y:15,spread:55},{family:"secondary",tone:5,x:85,y:25,spread:50},{family:"secondary",tone:8,x:50,y:75,spread:60}]},tertiary:{linear:[{family:"tertiary",tone:8,position:0},{family:"tertiary",tone:11,position:100}],radial:[{family:"tertiary",tone:8,position:0},{family:"tertiary",tone:11,position:100}],mesh:[{family:"tertiary",tone:8,x:25,y:15,spread:55},{family:"tertiary",tone:10,x:70,y:40,spread:50},{family:"tertiary",tone:11,x:40,y:85,spread:55}],meshCard:[{family:"tertiary",tone:3,x:20,y:10,spread:60},{family:"tertiary",tone:7,x:75,y:30,spread:50},{family:"tertiary",tone:10,x:45,y:80,spread:55}]},black:{linear:[{family:"black",tone:10,position:0},{family:"neutral",tone:3,position:100}],radial:[{family:"black",tone:10,position:0},{family:"neutral",tone:3,position:100}],mesh:[{family:"black",tone:10,x:0,y:0,spread:100},{family:"primary",tone:3,x:25,y:25,spread:50},{family:"secondary",tone:4,x:75,y:35,spread:45},{family:"tertiary",tone:3,x:50,y:80,spread:50}],meshCard:[{family:"black",tone:11,x:0,y:0,spread:100},{family:"primary",tone:5,x:20,y:20,spread:55},{family:"secondary",tone:8,x:80,y:30,spread:45},{family:"tertiary",tone:10,x:45,y:80,spread:50}]},white:{linear:[{family:"white",tone:2,position:0},{family:"neutral",tone:9,position:100}],radial:[{family:"white",tone:2,position:0},{family:"neutral",tone:9,position:100}],mesh:[{family:"white",tone:2,x:0,y:0,spread:100},{family:"primary",tone:9,x:25,y:25,spread:50},{family:"secondary",tone:8,x:75,y:35,spread:45},{family:"tertiary",tone:9,x:50,y:80,spread:50}],meshCard:[{family:"white",tone:1,x:0,y:0,spread:100},{family:"primary",tone:4,x:20,y:20,spread:55},{family:"secondary",tone:7,x:80,y:30,spread:45},{family:"tertiary",tone:10,x:45,y:80,spread:50}]}};function Bc(e,t){const r=kc[e]||kc.primary;return(r[t]||r.linear).map(e=>({...e}))}function wc({variant:e="linear",color:t="primary",angle:r=135,stops:o=null,position:n=null,blobs:i=null,cardProps:a={},minHeight:l=300,children:s,className:d="",sx:c={},...u}){const p="meshCard"===e,m="mesh"===e||p,f="radial"===e,g="linear"===e||f,x=o||Bc(t,f?"radial":"linear"),b=i||Bc(t,p?"meshCard":"mesh"),v=m?function(e){if(!e||0===e.length)return"none";const t=e.map(e=>{const t=Sc(e.family,e.tone),r=e.spread||40;return"radial-gradient(circle at "+e.x+"% "+e.y+"%, "+t+" 0%, transparent "+r+"%)"}),r=Sc(e[0].family,e[0].tone);return t.push(r),t.join(", ")}(b):f?function(e,t){if(!e||0===e.length)return"none";const r=[...e].sort((e,t)=>e.position-t.position).map(e=>Sc(e.family,e.tone)+" "+e.position+"%"),o=t||{x:50,y:50};return"radial-gradient(circle at "+o.x+"% "+o.y+"%, "+r.join(", ")+")"}(x,n||{x:50,y:50}):function(e,t){return e&&0!==e.length?"linear-gradient("+t+"deg, "+[...e].sort((e,t)=>e.position-t.position).map(e=>Sc(e.family,e.tone)+" "+e.position+"%").join(", ")+")":"none"}(x,r),y=g?x[0]:b[0];var S,k;const B=function(e){return"dark"===e?"var(--BW-Color-1)":"var(--BW-Color-6)"}((S=y?.tone||8,"black"===(k=y?.family||"primary")||"white"===k?S<=5?"light":"dark":S<=5?"dark":"light"));return de(h,p?{className:"gradient gradient-mesh-card "+d,sx:{background:v,minHeight:l,borderRadius:"var(--Card-Radius)",display:"flex",alignItems:"center",justifyContent:"center",padding:"var(--Card-Padding)",position:"relative",overflow:"hidden",...c},...u,children:de(Ma,{variant:"solid",...a,children:de(Wa,{children:s})})}:{className:"gradient gradient-"+e+" "+d,sx:{background:v,minHeight:l,borderRadius:"var(--Card-Radius)",color:B,display:"flex",alignItems:"center",justifyContent:"center",position:"relative",overflow:"hidden",...c},...u,children:s})}const Cc=e=>de(wc,{variant:"linear",...e}),Tc=e=>de(wc,{variant:"radial",...e}),Ic=e=>de(wc,{variant:"mesh",...e}),Ac=e=>de(wc,{variant:"meshCard",...e});function zc({children:e,surface:t="Container",outlined:r=!1,variant:o=(r?"outlined":"elevation"),sx:n={},...i}){const{dataSurface:a,elevation:l}=function(e="Container"){const t={"Container-Lowest":{elevation:0,zIndex:0},"Container-Low":{elevation:1,zIndex:100},Container:{elevation:4,zIndex:200},"Container-High":{elevation:8,zIndex:300},"Container-Highest":{elevation:12,zIndex:400}},r=t[e]||t.Container;return{dataSurface:e,elevation:r.elevation,zIndex:r.zIndex}}(t);return de(V,{variant:o,elevation:r?0:l,"data-surface":a,sx:{padding:2,borderRadius:"8px",transition:"all 0.2s ease-in-out",...n},...i,children:e})}function Rc({open:e=!1,onClose:t,anchorRef:n,placement:a="bottom-end",theme:l="Default",surface:s="Surface-Bright",width:d=320,maxHeight:c=400,children:u,sx:p={}}){const m=o(null),[f,g]=r({top:0,left:0,right:"auto"});return i(()=>{if(!e||!n?.current)return;const t=n.current.getBoundingClientRect();g("bottom-end"===a?{top:t.bottom+6,right:window.innerWidth-t.right,left:"auto"}:{top:t.bottom+6,left:t.left,right:"auto"})},[e,n,a]),i(()=>{if(!e)return;const r=e=>{m.current?.contains(e.target)||n?.current?.contains(e.target)||t?.()};return document.addEventListener("pointerdown",r),()=>document.removeEventListener("pointerdown",r)},[e,t,n]),i(()=>{if(!e)return;const r=e=>{"Escape"===e.key&&t?.()};return document.addEventListener("keydown",r),()=>document.removeEventListener("keydown",r)},[e,t]),e?ye.createPortal(de(h,{ref:m,"data-theme":l,"data-surface":s,sx:{position:"fixed",top:f.top,left:f.left,right:f.right,zIndex:2e9,width:d,maxHeight:c,overflowY:"auto",backgroundColor:"var(--Background)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",boxShadow:sn,...p},children:u}),document.body):null}["default","primary","secondary","tertiary","neutral"].map(e=>{return{value:e,label:(t=e,t?t.charAt(0).toUpperCase()+t.slice(1):"")};var t});const Ec=s(null),Pc=["Default","Primary-Light","Primary","Secondary-Light","Secondary","Tertiary-Light","Tertiary","Neutral-Light","Neutral","Error-Light","Success-Light","Warning-Light","Info-Light","Primary-Dark","Secondary-Dark","Tertiary-Dark","Neutral-Dark","Error-Dark","Success-Dark","Warning-Dark","Info-Dark","App-Bar","Nav-Bar","Status"],Oc=["Professional","Modern","Bold","Playful"],Lc=["Surface-Dimmest","Surface-Dim","Surface","Surface-Bright","Surface-Brightest","Container","Container-Low","Container-Lowest","Container-High","Container-Highest"],Mc={"light-tonal":{theme:"Primary",rootSurface:"Surface-Brightest"},"grey-professional":{theme:"Neutral",rootSurface:"Surface"},"dark-professional":{theme:"Neutral-Dark",rootSurface:"Surface"}},Wc="omni-foundation",Dc="omni-core",Fc="omni-typography",Nc="omni-mode",Hc="omni-base",Vc="omni-styles";function Qc(e){document.getElementById(e)?.remove()}function jc(e,t,r){return t?function(e){return!(!e||"string"!=typeof e)&&(e.startsWith("http")||e.startsWith("/")||e.endsWith(".css"))}(t)?function(e,t,r){const o=document.getElementById(e);return o?"LINK"===o.tagName&&o.getAttribute("href")!==t?new Promise((e,r)=>{o.onload=()=>e(o),o.onerror=()=>r(new Error(`OmniDesignProvider: failed to load ${t}`)),o.setAttribute("href",t)}):Promise.resolve(o):new Promise((o,n)=>{const i=document.createElement("link");i.id=e,i.rel="stylesheet",i.setAttribute("data-omni","true"),i.onload=()=>o(i),i.onerror=()=>n(new Error(`OmniDesignProvider: failed to load ${t}`)),i.href=t;const a=r?document.getElementById(r):null;a?document.head.insertBefore(i,a):document.head.appendChild(i)})}(e,t,r):function(e,t,r){if(!t)return Promise.resolve(null);const o=document.getElementById(e);if(o)return o.textContent=t,Promise.resolve(o);const n=document.createElement("style");n.id=e,n.setAttribute("data-omni","true"),n.textContent=t;const i=r?document.getElementById(r):null;return i?document.head.insertBefore(n,i):document.head.appendChild(n),Promise.resolve(n)}(e,t,r):Promise.resolve(null)}function Gc({themeURL:e,foundationCSS:t,coreCSS:a,typographyCSS:l,lightModeCSS:s,darkModeCSS:c,baseCSS:u,stylesCSS:p,defaultTheme:h="Default",defaultStyle:m="Modern",defaultSurface:f="Surface",surfaceStyle:g,defaultDarkMode:x=!1,darkTheme:b="Neutral-Dark",darkMode:v,onDarkModeChange:y,className:S,style:k,fullHeight:B=!0,children:w}){const[C,T]=r(x),I=void 0!==v,A=I?v:C,[z,R]=r({foundation:t??null,core:a??null,typography:l??null,lightMode:s??null,darkMode:c??null,base:u??null,styles:p??null}),[E,P]=r({}),O=o(!0);i(()=>(O.current=!0,()=>{O.current=!1}),[]),i(()=>{e&&(X("loading"),async function(e){const t=/\.json(\?|$)/.test(e)?e:`${e.replace(/\/$/,"")}/theme.json`,r=e.replace(/\/$/,"").replace(/\/theme\.json(\?.*)?$/,""),o=await fetch(t);if(!o.ok)throw new Error(`OmniDesignProvider: could not load theme manifest from ${t} (${o.status})`);const n=await o.json(),i=e=>e?/^https?:\/\//i.test(e)?e:`${r}/${e}`:null;return{foundationURL:i(n.foundation),coreURL:i(n.core),typographyURL:i(n.typography),lightModeURL:i(n.lightMode),darkModeURL:i(n.darkMode),baseURL:i(n.base),stylesURL:i(n.styles),defaultTheme:n.defaultTheme??null,defaultStyle:n.defaultStyle??null,defaultSurface:n.defaultSurface??null,darkTheme:n.darkTheme??null,name:n.name??null}}(e).then(e=>{O.current&&(R({foundation:t??e.foundationURL,core:a??e.coreURL,typography:l??e.typographyURL,lightMode:s??e.lightModeURL,darkMode:c??e.darkModeURL,base:u??e.baseURL,styles:p??e.stylesURL}),P({defaultTheme:e.defaultTheme,defaultStyle:e.defaultStyle,defaultSurface:e.defaultSurface,darkTheme:e.darkTheme,name:e.name}))}).catch(e=>{O.current&&(console.error("OmniDesignProvider: manifest error:",e),q(e.message),X("error"))}))},[e]);const L=g?Mc[g]?.theme??h:"Default"!==h?h:E.defaultTheme??h,M=g?Mc[g]?.rootSurface??f:E.defaultSurface??f,W=E.defaultStyle??m,D="Neutral-Dark"!==b?b:E.darkTheme??b,[F,N]=r(L),[H,V]=r(W),[Q,j]=r(M),G=!!(e||t||a||l||s||c||u||p),[U,X]=r(G?"loading":"ready"),[K,q]=r(null);i(()=>{const{foundation:e,core:t,typography:r,base:o,styles:n}=z;if(e||t||r||o||n)return X("loading"),q(null),Promise.all([jc(Wc,e),jc(Dc,t),jc(Fc,r).catch(e=>{console.warn("OmniDesignProvider: typography CSS did not load —",e.message)}),jc(Hc,o),jc(Vc,n)]).then(()=>{O.current&&X("ready")}).catch(e=>{O.current&&(console.error("OmniDesignProvider CSS error:",e),q(e.message),X("error"))}),()=>{Qc(Wc),Qc(Dc),Qc(Fc),Qc(Hc),Qc(Vc)};X("ready")},[z.foundation,z.core,z.typography,z.base,z.styles]),i(()=>{const e=A?z.darkMode:z.lightMode;e&&jc(Nc,e,Hc).catch(e=>console.error("OmniDesignProvider mode CSS error:",e))},[A,z.lightMode,z.darkMode]),i(()=>()=>Qc(Nc),[]);const J=A?D:F,Y=n(()=>{I?y?.(!A):T(e=>!e)},[I,A,y]),Z=n(e=>{Pc.includes(e)||console.warn(`OmniDesignProvider: unknown theme "${e}"`),N(e)},[]),$=n(e=>{Oc.includes(e)||console.warn(`OmniDesignProvider: unknown style "${e}"`),V(e)},[]),_=n(e=>{Lc.includes(e)||console.warn(`OmniDesignProvider: unknown surface "${e}"`),j(e)},[]),ee=d(()=>({theme:J,style:H,surface:Q,isDark:A,cssStatus:U,cssError:K,setTheme:Z,setStyle:$,setSurface:_,toggleDarkMode:Y,themes:Pc,styles:Oc,surfaces:Lc,name:E.name??null}),[J,H,Q,A,U,K,Z,$,_,Y,E.name]);return ce(Ec.Provider,{value:ee,children:[de("style",{"data-omni":"hide-during-load",children:'[data-omni-css="loading"]{visibility:hidden}'}),de("div",{"data-theme":J,"data-style":H,"data-surface":Q,"data-omni-css":U,className:S,style:{...B?{minHeight:"100vh"}:{},...k},children:w})]})}function Uc(){const e=l(Ec);if(!e)throw new Error("useOmniDesign must be used inside a <OmniDesignProvider>");return e}function Xc({theme:e,surface:t,as:r="div",children:o,className:n,style:i,...a}){return de(r,{"data-theme":e,"data-surface":t,className:n,style:i,...a,children:o})}function Kc({surface:e,as:t="div",children:r,className:o,style:n,...i}){return de(t,{"data-surface":e,className:o,style:n,...i,children:r})}const qc=e=>c(function(t,r){return de(Y,{direction:e,ref:r,...t})}),Jc={fade:c(function(e,t){return de(J,{ref:t,...e})}),grow:c(function(e,t){return de(q,{ref:t,...e})}),zoom:c(function(e,t){return de(K,{ref:t,...e})}),"slide-up":qc("up"),"slide-down":qc("down"),"slide-left":qc("left"),"slide-right":qc("right")},Yc={backgroundColor:"var(--Background)",color:"var(--Text)",border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",boxShadow:"0 8px 32px rgba(0,0,0,0.18)"},Zc={color:"var(--Text)",fontWeight:600,fontSize:"18px",fontFamily:"inherit",borderBottom:"1px solid var(--Border)",display:"flex",justifyContent:"space-between",alignItems:"center",py:1.5,px:3},$c={color:"var(--Text)",fontFamily:"inherit",fontSize:"14px",lineHeight:1.6,py:3,px:3},_c={borderTop:"1px solid var(--Border)",px:3,py:1.5,gap:1},eu={fontFamily:"inherit",fontWeight:500,fontSize:"14px",borderRadius:"var(--Style-Border-Radius)",padding:"6px 16px",cursor:"pointer",border:"none",transition:"background-color 0.15s, color 0.15s","&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"1px"}},tu={primary:{...eu,backgroundColor:"var(--Buttons-Primary-Button)",color:"var(--Buttons-Primary-Text)",border:"1px solid var(--Buttons-Primary-Border)","&:hover":{backgroundColor:"var(--Buttons-Primary-Hover)"}},outline:{...eu,backgroundColor:"transparent",color:"var(--Text)",border:"1px solid var(--Border)","&:hover":{backgroundColor:"var(--Hover)"}}};function ru({open:e=!1,onClose:t,title:r,children:o,actions:n,maxWidth:i="sm",fullScreen:a=!1,scroll:l="body",alert:s=!1,nonModal:d=!1,transition:c,transitionDuration:u=300,titleId:p="dialog-title",contentId:m="dialog-description",className:f="",sx:g={},PaperProps:x={},...b}){const v=c?Jc[c]:void 0;let y;try{y=Uc()}catch{y=null}const S=y?.theme||"Default",k=y?.style||"Modern",B=y?.surface||"Surface";return ce(Q,{open:e,onClose:(e,r)=>{s&&"backdropClick"===r||s&&"escapeKeyDown"===r||t?.(e,r)},maxWidth:!a&&i,fullScreen:a,fullWidth:!a,scroll:l,hideBackdrop:d,disableEnforceFocus:d,disableEscapeKeyDown:s,TransitionComponent:v,transitionDuration:u,"aria-labelledby":p,"aria-describedby":m,className:"dialog dialog-"+i+(a?" dialog-fullscreen":"")+(s?" dialog-alert":"")+(f?" "+f:""),style:{zIndex:1e7},slotProps:{backdrop:{sx:{backgroundColor:d?"transparent":"rgba(0,0,0,0.5)"}}},PaperProps:{...x,"data-theme":S,"data-style":k,"data-surface":B,sx:{...Yc,...a&&{borderRadius:0,border:"none"},...x.sx},role:s?"alertdialog":"dialog"},...b,children:[r&&ce(j,{id:p,sx:Zc,children:[r,!s&&t&&de(C,{"aria-label":"Close dialog",onClick:e=>t(e,"closeButton"),size:"small",sx:{color:"var(--Text-Quiet)","&:hover":{backgroundColor:"var(--Hover)"}},children:de(Ot,{fontSize:"small"})})]}),de(G,{dividers:"paper"===l,sx:{...$c,..."paper"===l&&{maxHeight:a?"none":"400px",overflowY:"auto",borderColor:"var(--Border)"}},children:s?de(U,{id:m,sx:{color:"var(--Text)",fontFamily:"inherit",fontSize:"14px",lineHeight:1.6},children:o}):de(h,{id:m,children:o})}),n&&de(X,{sx:_c,children:n})]})}function ou({open:e,onClose:t,title:r,children:o,confirmText:n="Confirm",cancelText:i="Cancel",onConfirm:a,onCancel:l,...s}){return de(ru,{open:e,onClose:t,title:r,alert:!0,...s,actions:ce(ue,{children:[de(h,{component:"button",type:"button",onClick:l||t,sx:tu.outline,children:i}),de(h,{component:"button",type:"button",onClick:a||t,sx:tu.primary,children:n})]}),children:o})}function nu({open:e,onClose:t,title:r,children:o,submitText:n="Submit",cancelText:i="Cancel",onSubmit:a,...l}){return de(ru,{open:e,onClose:t,title:r,...l,actions:ce(ue,{children:[de(h,{component:"button",type:"button",onClick:t,sx:tu.outline,children:i}),de(h,{component:"button",type:"button",onClick:a,sx:tu.primary,children:n})]}),children:o})}function iu({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function au(){const[e,t]=r(!1),[o,n]=r("sm"),[i,a]=r(!1),[l,s]=r("none"),[d,c]=r(!1),[u,p]=r(!1),[m,f]=r(null),[g,x]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Dialog"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:m,surface:g,children:de(In,{variant:"default",onClick:()=>t(!0),children:"Open Dialog"})}),de(Vi,{code:(()=>{const e=["open={open}","onClose={handleClose}"];return"sm"!==o&&e.push('maxWidth="'+o+'"'),i&&e.push("fullScreen"),d&&e.push("alert"),u&&e.push("nonModal"),"none"!==l&&e.push('transition="'+l+'"'),e.push('title="Dialog Title"'),e.push('actions={<><Button variant="default-outline" onClick={handleClose}>Cancel</Button><Button variant="default" onClick={handleClose}>Confirm</Button></>}'),"<Dialog\n "+e.join("\n ")+"\n>\n Dialog content goes here.\n</Dialog>"})(),language:"JSX",wrap:!0,sx:{mt:2}}),de(ru,{open:e,onClose:(e,r)=>{d&&"backdropClick"===r||t(!1)},maxWidth:o,fullScreen:i,alert:d,nonModal:u,transition:"none"!==l?l:void 0,title:"Dialog Title",actions:ce(ue,{children:[de(In,{variant:"default-outline",size:"small",onClick:()=>t(!1),children:"Cancel"}),de(In,{variant:"default",size:"small",onClick:()=>t(!1),children:"Confirm"})]}),children:de(co,{children:"This is the dialog content. You can put any information here that requires user attention or action."})})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:m,onThemeChange:f,surface:g,onSurfaceChange:x})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),ce(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:[["xs","sm","md","lg","xl"].map(e=>de(iu,{label:e.toUpperCase(),selected:o===e,onClick:()=>{n(e),a(!1)}},e)),de(iu,{label:"Full Screen",selected:i,onClick:()=>a(!i)})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TRANSITION"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["none","slide-up","slide-down","grow","fade","zoom"].map(e=>{return de(iu,{label:(t=e,t?t.charAt(0).toUpperCase()+t.slice(1):""),selected:l===e,onClick:()=>s(e)},e);var t})})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Alert"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"No backdrop dismiss, no Escape"})]}),de(ta,{variant:"default-outline",checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Alert mode"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Non-Modal"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"No backdrop, interact with content behind"})]}),de(ta,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Non-modal"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="dialog" (standard) or role="alertdialog" (alert mode)'},{label:"Label",value:"aria-labelledby links to title, aria-describedby links to content"},{label:"Focus",value:"Focus trapped inside dialog. Returns to trigger on close."},{label:"Keyboard",value:"Escape closes (unless alert). Tab cycles through focusable elements."},{label:"Backdrop",value:"Click closes (unless alert or non-modal)"},{label:"Close",value:'Close button with aria-label="Close dialog"'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const lu={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info-Medium",success:"Success-Medium",warning:"Warning-Medium",error:"Error-Medium"},su={primary:"Primary-Light",secondary:"Secondary-Light",tertiary:"Tertiary-Light",neutral:"Neutral-Light",info:"Info-Light",success:"Success-Light",warning:"Warning-Light",error:"Error-Light"},du={small:{maxWidth:400,padding:"24px"},medium:{maxWidth:560,padding:"32px"},large:{maxWidth:720,padding:"40px"}},cu={fade:{enter:{from:{opacity:0},to:{opacity:1}},name:"modal-fade"},"slide-up":{enter:{from:{opacity:0,transform:"translateY(40px)"},to:{opacity:1,transform:"translateY(0)"}},name:"modal-slide-up"},"slide-down":{enter:{from:{opacity:0,transform:"translateY(-40px)"},to:{opacity:1,transform:"translateY(0)"}},name:"modal-slide-down"},zoom:{enter:{from:{opacity:0,transform:"scale(0.85)"},to:{opacity:1,transform:"scale(1)"}},name:"modal-zoom"}};function uu(e){const t=cu[e];if(!t)return"";const{from:r,to:o}=t.enter,n=Object.entries(r).map(([e,t])=>e+":"+t).join(";"),i=Object.entries(o).map(([e,t])=>e+":"+t).join(";");return"@keyframes "+t.name+" { from {"+n+"} to {"+i+"} }@keyframes "+t.name+"-backdrop { from { opacity: 0 } to { opacity: 1 } }"}function pu({open:e,onClose:t,children:n,title:a,variant:l="default",color:s="primary",size:d="medium",layout:c="center",transition:u="fade",transitionSpeed:p=250,closeOnBackdrop:m=!0,showCloseButton:f=!0,className:g="",sx:x={},...b}){const v=o(null),y=o(null),[S,k]=r(!1);let B;try{B=Uc()}catch{B=null}const w=B?.theme||"Default",C=B?.style||"Modern",T="soft"===l,I="solid"===l,A="fullscreen"===c,z=I?lu[s]:T?su[s]:null,R=du[d]||du.medium,E=cu[u],P=E?E.name:void 0,O=p+"ms";return i(()=>(e?(y.current=document.activeElement,k(!0),requestAnimationFrame(()=>{v.current?.focus()}),document.body.style.overflow="hidden"):(k(!1),document.body.style.overflow="",y.current?.focus()),()=>{document.body.style.overflow=""}),[e]),i(()=>{if(!e)return;const r=e=>{"Escape"===e.key&&t?.()};return document.addEventListener("keydown",r),()=>document.removeEventListener("keydown",r)},[e,t]),e||S?ce(ue,{children:["none"!==u&&de("style",{children:uu(u)}),de(h,{"aria-hidden":"true",onClick:m?t:void 0,sx:{position:"fixed",inset:0,zIndex:1e7,backgroundColor:"rgba(0,0,0,0.5)",...P&&{animation:P+"-backdrop "+O+" ease-out forwards"}}}),ce(h,{role:"dialog","aria-modal":"true","aria-label":a||"Modal",ref:v,tabIndex:-1,"data-surface":"Container-High","data-theme":z||w,"data-style":C,className:"modal modal-"+l+" modal-"+d+" modal-"+c+(T||I?" modal-"+s:"")+(g?" "+g:""),sx:{position:"fixed",zIndex:10000001,outline:"none",fontFamily:"inherit",...A?{inset:0,borderRadius:0}:{top:"50%",left:"50%",transform:"translate(-50%, -50%)",maxWidth:R.maxWidth+"px",width:"calc(100% - 32px)",maxHeight:"calc(100vh - 64px)",borderRadius:"var(--Modal-Radius, var(--Style-Border-Radius))"},backgroundColor:"var(--Background)",color:"var(--Text)",boxShadow:"0 8px 32px rgba(0,0,0,0.24)",display:"flex",flexDirection:"column",overflow:"hidden",...P&&{animation:P+" "+O+" ease-out forwards"},...x},...b,children:[(a||f)&&ce(h,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",px:A?4:R.padding,pt:A?3:R.padding,pb:0,flexShrink:0},children:[a&&de(h,{sx:{fontSize:"small"===d?"18px":"large"===d?"24px":"20px",fontWeight:700,color:"var(--Text)",flex:1},children:a}),f&&de(h,{component:"button",type:"button","aria-label":"Close modal",onClick:t,sx:{display:"flex",alignItems:"center",justifyContent:"center",width:32,height:32,borderRadius:"50%",border:"none",backgroundColor:"transparent",color:"var(--Text-Quiet)",cursor:"pointer",flexShrink:0,ml:1,transition:"background-color 0.15s ease, color 0.15s ease","&:hover":{backgroundColor:"var(--Hover)",color:"var(--Text)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:de(Ot,{sx:{fontSize:20}})})]}),de(h,{sx:{flex:1,overflowY:"auto",px:A?4:R.padding,pt:A?3:"16px",pb:A?3:R.padding,color:"var(--Text)",fontSize:"small"===d?"13px":"14px",lineHeight:1.6},children:n})]})]}):null}const hu={small:{width:"240px",height:"200px"},medium:{width:"320px",height:"280px"},large:{width:"420px",height:"380px"}},mu={left:{borderRight:"1px solid var(--Border)"},right:{borderLeft:"1px solid var(--Border)"},top:{borderBottom:"1px solid var(--Border)"},bottom:{borderTop:"1px solid var(--Border)"}},fu={left:{top:0,left:0,bottom:0},right:{top:0,right:0,bottom:0},top:{top:0,left:0,right:0},bottom:{bottom:0,left:0,right:0}},gu={left:"translateX(-100%)",right:"translateX(100%)",top:"translateY(-100%)",bottom:"translateY(100%)"};function xu({children:e,open:t=!1,onClose:r,size:a="medium",anchor:l="left",hideBackdrop:s=!1,className:d="",sx:c={},...u}){const p=o(null),m=o(null),f="left"===l||"right"===l;let g;try{g=Uc()}catch{g=null}const x=g?.theme||"Default",b=g?.style||"Modern",v=hu[a]||hu.medium;i(()=>{if(!t)return;const e=e=>{"Escape"===e.key&&r?.()};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[t,r]),i(()=>{t?(m.current=document.activeElement,requestAnimationFrame(()=>{const e=p.current?.querySelector('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');e?e.focus():p.current?.focus()})):m.current&&(m.current.focus(),m.current=null)},[t]),i(()=>{if(t){const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}}},[t]);const y=n(e=>{if("Tab"!==e.key||!p.current)return;const t=p.current.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');if(!t.length)return;const r=t[0],o=t[t.length-1];e.shiftKey?document.activeElement===r&&(e.preventDefault(),o.focus()):document.activeElement===o&&(e.preventDefault(),r.focus())},[]);return t?ce(ue,{children:[!s&&de(h,{onClick:()=>r?.(),"aria-hidden":"true",sx:{position:"fixed",inset:0,zIndex:1e7,backgroundColor:"rgba(0, 0, 0, 0.5)",transition:"opacity 0.3s ease"}}),de(h,{ref:p,role:"dialog","aria-modal":"true",tabIndex:-1,"data-theme":x,"data-style":b,"data-surface":"Surface-Dim",onKeyDown:y,className:"drawer drawer-"+a+" drawer-"+l+" "+d,sx:{position:"fixed",zIndex:10000001,...fu[l],...f?{width:v.width,height:"100%"}:{height:v.height,width:"100%"},backgroundColor:"var(--Background)",color:"var(--Text)",...mu[l],boxShadow:ln,display:"flex",flexDirection:"column",outline:"none",overflow:"hidden",animation:"drawer-slide-in 0.3s ease forwards","@keyframes drawer-slide-in":{from:{transform:gu[l]},to:{transform:"translate(0, 0)"}},...c},...u,children:e})]}):null}function bu({onClick:e,className:t="",sx:r={},...o}){return de(h,{sx:{position:"absolute",top:"12px",right:"12px",zIndex:1,...r},className:t,...o,children:de(In,{iconOnly:!0,variant:"ghost",size:"small",onClick:e,"aria-label":"Close drawer",children:de(jo,{size:"small",children:de(Ot,{})})})})}function vu({children:e,className:t="",sx:r={},...o}){return de(h,{className:"drawer-header "+t,sx:{display:"flex",alignItems:"center",justifyContent:"space-between",padding:"16px",borderBottom:"1px solid var(--Border)",flexShrink:0,...r},...o,children:e})}function yu({children:e,className:t="",sx:r={},...o}){return de(h,{className:"drawer-content "+t,sx:{flex:1,overflowY:"auto",padding:"16px",...r},...o,children:e})}function Su(){return Su=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)({}).hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},Su.apply(null,arguments)}const ku={};function Bu(t,r){const o=e.useRef(ku);return o.current===ku&&(o.current=t(r)),o}function wu(e,t,r,o){const n=Bu(Cu).current;return function(e,t,r,o,n){return e.refs[0]!==t||e.refs[1]!==r||e.refs[2]!==o||e.refs[3]!==n}(n,e,t,r,o)&&function(e,t){if(e.refs=t,t.every(e=>null==e))return void(e.callback=null);e.callback=r=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),null!=r){const o=Array(t.length).fill(null);for(let e=0;e<t.length;e+=1){const n=t[e];if(null!=n)switch(typeof n){case"function":{const t=n(r);"function"==typeof t&&(o[e]=t);break}case"object":n.current=r}}e.cleanup=()=>{for(let e=0;e<t.length;e+=1){const r=t[e];if(null!=r)switch(typeof r){case"function":{const t=o[e];"function"==typeof t?t():r(null);break}case"object":r.current=null}}}}}}(n,[e,t,r,o]),n.callback}function Cu(){return{callback:null,cleanup:null,refs:[]}}function Tu(e,t,r=void 0){const o={};for(const n in e){const i=e[n];let a="",l=!0;for(let e=0;e<i.length;e+=1){const o=i[e];o&&(a+=(!0===l?"":" ")+t(o),l=!1,r&&r[o]&&(a+=" "+r[o]))}o[n]=a}return o}function Iu(e){var t,r,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var n=e.length;for(t=0;t<n;t++)e[t]&&(r=Iu(e[t]))&&(o&&(o+=" "),o+=r)}else for(r in e)e[r]&&(o&&(o+=" "),o+=r);return o}function Au(){for(var e,t,r=0,o="",n=arguments.length;r<n;r++)(e=arguments[r])&&(t=Iu(e))&&(o&&(o+=" "),o+=t);return o}function zu(e,t=[]){if(void 0===e)return{};const r={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&"function"==typeof e[r]&&!t.includes(r)).forEach(t=>{r[t]=e[t]}),r}function Ru(e){if(void 0===e)return{};const t={};return Object.keys(e).filter(t=>!(t.match(/^on[A-Z]/)&&"function"==typeof e[t])).forEach(r=>{t[r]=e[r]}),t}function Eu(e,t,r){return"function"==typeof e?e(t,r):e}function Pu(t){const{elementType:r,externalSlotProps:o,ownerState:n,skipResolvingSlotProps:i=!1,...a}=t,l=i?{}:Eu(o,n),{props:s,internalRef:d}=function(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:o,externalForwardedProps:n,className:i}=e;if(!t){const e=Au(r?.className,i,n?.className,o?.className),t={...r?.style,...n?.style,...o?.style},a={...r,...n,...o};return e.length>0&&(a.className=e),Object.keys(t).length>0&&(a.style=t),{props:a,internalRef:void 0}}const a=zu({...n,...o}),l=Ru(o),s=Ru(n),d=t(a),c=Au(d?.className,r?.className,i,n?.className,o?.className),u={...d?.style,...r?.style,...n?.style,...o?.style},p={...d,...r,...s,...l};return c.length>0&&(p.className=c),Object.keys(u).length>0&&(p.style=u),{props:p,internalRef:d.ref}}({...a,externalSlotProps:l}),c=function(e,t,r){return void 0===e||"string"==typeof e?t:{...t,ownerState:{...t.ownerState,...r}}}(r,{...s,ref:function(...t){const r=e.useRef(void 0),o=e.useCallback(e=>{const r=t.map(t=>{if(null==t)return null;if("function"==typeof t){const r=t,o=r(e);return"function"==typeof o?o:()=>{r(null)}}return t.current=e,()=>{t.current=null}});return()=>{r.forEach(e=>e?.())}},t);return e.useMemo(()=>t.every(e=>null==e)?null:e=>{r.current&&(r.current(),r.current=void 0),null!=e&&(r.current=o(e))},t)}(d,l?.ref,t.additionalProps?.ref)},n);return c}const Ou=new Set;function Lu(e,t="warning"){if("production"===process.env.NODE_ENV)return;const r=Array.isArray(e)?e.join("\n"):e;Ou.has(r)||(Ou.add(r),"error"===t?console.error(r):console.warn(r))}function Mu(e){return rr}const Wu=e=>e,Du=(()=>{let e=Wu;return{configure(t){e=t},generate:t=>e(t),reset(){e=Wu}}})(),Fu={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function Nu(e,t,r="Mui"){const o=Fu[t];return o?`${r}-${o}`:`${Du.generate(e)}-${t}`}function Hu(e,t,r="Mui"){const o={};return t.forEach(t=>{o[t]=Nu(e,t,r)}),o}function Vu(e){return Nu("MuiSimpleTreeView",e)}Hu("MuiSimpleTreeView",["root","item","itemContent","itemGroupTransition","itemIconContainer","itemLabel","itemCheckbox"]);const Qu=Object.freeze([]),ju=Object.freeze({}),Gu=e.createContext(null);"production"!==process.env.NODE_ENV&&(Gu.displayName="TreeViewContext");const Uu=()=>{const t=e.useContext(Gu);if(null==t)throw new Error(["MUI X: Could not find the Tree View context.","It looks like you rendered your component outside of a SimpleTreeView or RichTreeView parent component.","This can also happen if you are bundling multiple versions of the Tree View."].join("\n"));return t},Xu=e.createContext({classes:{},slots:{},slotProps:{}});"production"!==process.env.NODE_ENV&&(Xu.displayName="TreeViewStyleContext");const Ku=()=>e.useContext(Xu);function qu(t){const{store:r,apiRef:o,rootRef:n,classes:i=ju,slots:a=ju,slotProps:l=ju,children:s}=t,d=(t=>{const{store:r,apiRef:o,rootRef:n}=t,i=Bu(()=>r.buildPublicAPI()).current;!function(e,t){null!=t&&null==t.current&&(t.current=e)}(i,o);const a=e.useCallback(e=>{let t=null,o=null;const n=[],i={};r.itemPluginManager.listPlugins().forEach(r=>{const a=r({props:e,rootRef:t,contentRef:o});a?.rootRef&&(t=a.rootRef),a?.contentRef&&(o=a.contentRef),a?.propsEnhancers&&(n.push(a.propsEnhancers),Object.keys(a.propsEnhancers).forEach(e=>{i[e]=!0}))});const a=Object.fromEntries(Object.keys(i).map(e=>{return[e,(t=e,e=>{const r={};return n.forEach(o=>{const n=o[t];null!=n&&Object.assign(r,n(e))}),r})];var t}));return{contentRef:o,rootRef:t,propsEnhancers:a}},[r]),l=e.useCallback(({itemId:e,children:t,idAttribute:o})=>{let n=t;const i=r.itemPluginManager.listWrappers();for(let t=i.length-1;t>=0;t-=1)n=(0,i[t])({store:r,itemId:e,children:n,idAttribute:o});return n},[r]);return e.useMemo(()=>({runItemPlugins:a,wrapItem:l,publicAPI:i,store:r,rootRef:n}),[a,l,i,r,n])})({store:r,apiRef:o,rootRef:n}),c=e.useMemo(()=>({classes:i,slots:{collapseIcon:a.collapseIcon,expandIcon:a.expandIcon,endIcon:a.endIcon},slotProps:{collapseIcon:l.collapseIcon,expandIcon:l.expandIcon,endIcon:l.endIcon}}),[i,a.collapseIcon,a.expandIcon,a.endIcon,l.collapseIcon,l.expandIcon,l.endIcon]);return de(Gu.Provider,{value:d,children:de(Xu.Provider,{value:c,children:s})})}function Ju(e,t){if(null==e)return{};var r={};for(var o in e)if({}.hasOwnProperty.call(e,o)){if(-1!==t.indexOf(o))continue;r[o]=e[o]}return r}const Yu=["apiRef","slots","slotProps","disabledItemsFocusable","onItemClick","itemChildrenIndentation","id","expandedItems","defaultExpandedItems","onExpandedItemsChange","onItemExpansionToggle","expansionTrigger","disableSelection","selectedItems","defaultSelectedItems","multiSelect","checkboxSelection","selectionPropagation","onSelectedItemsChange","onItemSelectionToggle","onItemFocus"];var Zu=(e,t,r)=>{if(1===t.length&&t[0]===r){let t=!1;try{const r={};e(r)===r&&(t=!0)}catch{}if(t){let e;try{throw new Error}catch(t){({stack:e}=t)}console.warn("The result function returned its own inputs without modification. e.g\n`createSelector([state => state.todos], todos => todos)`\nThis could lead to inefficient memoization and unnecessary re-renders.\nEnsure transformation logic is in the result function, and extraction logic is in the input selectors.",{stack:e})}}},$u=(e,t,r)=>{const{memoize:o,memoizeOptions:n}=t,{inputSelectorResults:i,inputSelectorResultsCopy:a}=e,l=o(()=>({}),...n);if(!(l.apply(null,i)===l.apply(null,a))){let e;try{throw new Error}catch(t){({stack:e}=t)}console.warn("An input selector returned a different result when passed same arguments.\nThis means your output selector will likely run more frequently than intended.\nAvoid returning a new reference inside your input selector, e.g.\n`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)`",{arguments:r,firstInputs:i,secondInputs:a,stack:e})}},_u={inputStabilityCheck:"once",identityFunctionCheck:"once"},ep=Symbol("NOT_FOUND");var tp=e=>Array.isArray(e)?e:[e];function rp(e){const t=Array.isArray(e[0])?e[0]:e;return function(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(e=>"function"==typeof e)){const r=e.map(e=>"function"==typeof e?`function ${e.name||"unnamed"}()`:typeof e).join(", ");throw new TypeError(`${t}[${r}]`)}}(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function op(e,t){const r=[],{length:o}=e;for(let n=0;n<o;n++)r.push(e[n].apply(null,t));return r}var np=(e,t)=>e===t;var ip="undefined"!=typeof WeakRef?WeakRef:class{constructor(e){this.value=e}deref(){return this.value}};function ap(){return{s:0,v:void 0,o:null,p:null}}function lp(e,t={}){let r={s:0,v:void 0,o:null,p:null};const{resultEqualityCheck:o}=t;let n,i=0;function a(){let t=r;const{length:a}=arguments;for(let e=0,r=a;e<r;e++){const r=arguments[e];if("function"==typeof r||"object"==typeof r&&null!==r){let e=t.o;null===e&&(t.o=e=new WeakMap);const o=e.get(r);void 0===o?(t=ap(),e.set(r,t)):t=o}else{let e=t.p;null===e&&(t.p=e=new Map);const o=e.get(r);void 0===o?(t=ap(),e.set(r,t)):t=o}}const l=t;let s;if(1===t.s)s=t.v;else if(s=e.apply(null,arguments),i++,o){const e=n?.deref?.()??n;null!=e&&o(e,s)&&(s=e,0!==i&&i--);n="object"==typeof s&&null!==s||"function"==typeof s?new ip(s):s}return l.s=1,l.v=s,s}return a.clearCache=()=>{r={s:0,v:void 0,o:null,p:null},a.resetResultsCount()},a.resultsCount=()=>i,a.resetResultsCount=()=>{i=0},a}function sp(e,...t){const r="function"==typeof e?{memoize:e,memoizeOptions:t}:e,o=(...e)=>{let t,o=0,n=0,i={},a=e.pop();"object"==typeof a&&(i=a,a=e.pop()),function(e,t="expected a function, instead received "+typeof e){if("function"!=typeof e)throw new TypeError(t)}(a,`createSelector expects an output function after the inputs, but received: [${typeof a}]`);const l={...r,...i},{memoize:s,memoizeOptions:d=[],argsMemoize:c=lp,argsMemoizeOptions:u=[],devModeChecks:p={}}=l,h=tp(d),m=tp(u),f=rp(e),g=s(function(){return o++,a.apply(null,arguments)},...h);let x=!0;const b=c(function(){n++;const e=op(f,arguments);if(t=g.apply(null,e),"production"!==process.env.NODE_ENV){const{identityFunctionCheck:r,inputStabilityCheck:o}=((e,t)=>{const{identityFunctionCheck:r,inputStabilityCheck:o}={..._u,...t};return{identityFunctionCheck:{shouldRun:"always"===r||"once"===r&&e,run:Zu},inputStabilityCheck:{shouldRun:"always"===o||"once"===o&&e,run:$u}}})(x,p);if(r.shouldRun&&r.run(a,e,t),o.shouldRun){const t=op(f,arguments);o.run({inputSelectorResults:e,inputSelectorResultsCopy:t},{memoize:s,memoizeOptions:h},arguments)}x&&(x=!1)}return t},...m);return Object.assign(b,{resultFunc:a,memoizedResultFunc:g,dependencies:f,dependencyRecomputations:()=>n,resetDependencyRecomputations:()=>{n=0},lastResult:()=>t,recomputations:()=>o,resetRecomputations:()=>{o=0},memoize:s,argsMemoize:c})};return Object.assign(o,{withTypes:()=>o}),o}var dp=sp(lp),cp=Object.assign((e,t=dp)=>{!function(e,t="expected an object, instead received "+typeof e){if("object"!=typeof e)throw new TypeError(t)}(e,"createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);const r=Object.keys(e),o=t(r.map(t=>e[t]),(...e)=>e.reduce((e,t,o)=>(e[r[o]]=t,e),{}));return o},{withTypes:()=>cp});const up=sp({memoize:function(e,t){const r="object"==typeof t?t:{equalityCheck:t},{equalityCheck:o=np,maxSize:n=1,resultEqualityCheck:i}=r,a=function(e){return function(t,r){if(null===t||null===r||t.length!==r.length)return!1;const{length:o}=t;for(let n=0;n<o;n++)if(!e(t[n],r[n]))return!1;return!0}}(o);let l=0;const s=n<=1?function(e){let t;return{get:r=>t&&e(t.key,r)?t.value:ep,put(e,r){t={key:e,value:r}},getEntries:()=>t?[t]:[],clear(){t=void 0}}}(a):function(e,t){let r=[];function o(e){const o=r.findIndex(r=>t(e,r.key));if(o>-1){const e=r[o];return o>0&&(r.splice(o,1),r.unshift(e)),e.value}return ep}return{get:o,put:function(t,n){o(t)===ep&&(r.unshift({key:t,value:n}),r.length>e&&r.pop())},getEntries:function(){return r},clear:function(){r=[]}}}(n,a);function d(){let t=s.get(arguments);if(t===ep){if(t=e.apply(null,arguments),l++,i){const e=s.getEntries().find(e=>i(e.value,t));e&&(t=e.value,0!==l&&l--)}s.put(arguments,t)}return t}return d.clearCache=()=>{s.clear(),d.resetResultsCount()},d.resultsCount=()=>l,d.resetResultsCount=()=>{l=0},d},memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),pp=(e,t,r,o,n,i,a,l,...s)=>{if(s.length>0)throw new Error("Unsupported number of selectors");let d;if(e&&t&&r&&o&&n&&i&&a&&l)d=(s,d,c,u)=>{const p=e(s,d,c,u),h=t(s,d,c,u),m=r(s,d,c,u),f=o(s,d,c,u),g=n(s,d,c,u),x=i(s,d,c,u),b=a(s,d,c,u);return l(p,h,m,f,g,x,b,d,c,u)};else if(e&&t&&r&&o&&n&&i&&a)d=(l,s,d,c)=>{const u=e(l,s,d,c),p=t(l,s,d,c),h=r(l,s,d,c),m=o(l,s,d,c),f=n(l,s,d,c),g=i(l,s,d,c);return a(u,p,h,m,f,g,s,d,c)};else if(e&&t&&r&&o&&n&&i)d=(a,l,s,d)=>{const c=e(a,l,s,d),u=t(a,l,s,d),p=r(a,l,s,d),h=o(a,l,s,d),m=n(a,l,s,d);return i(c,u,p,h,m,l,s,d)};else if(e&&t&&r&&o&&n)d=(i,a,l,s)=>{const d=e(i,a,l,s),c=t(i,a,l,s),u=r(i,a,l,s),p=o(i,a,l,s);return n(d,c,u,p,a,l,s)};else if(e&&t&&r&&o)d=(n,i,a,l)=>{const s=e(n,i,a,l),d=t(n,i,a,l),c=r(n,i,a,l);return o(s,d,c,i,a,l)};else if(e&&t&&r)d=(o,n,i,a)=>{const l=e(o,n,i,a),s=t(o,n,i,a);return r(l,s,n,i,a)};else if(e&&t)d=(r,o,n,i)=>{const a=e(r,o,n,i);return t(a,o,n,i)};else{if(!e)throw new Error("Missing arguments");d=e}return d},hp=(...e)=>{const t=new WeakMap;let r=1;const o=e[e.length-1],n=e.length-1||1,i=Math.max(o.length-n,0);if(i>3)throw new Error("Unsupported number of arguments");return(n,a,l,s)=>{let d=n.__cacheKey__;d||(d={id:r},n.__cacheKey__=d,r+=1);let c=t.get(d);if(!c){const r=1===e.length?[e=>e,o]:e;let n=e;const a=[void 0,void 0,void 0];switch(i){case 0:break;case 1:n=[...r.slice(0,-1),()=>a[0],o];break;case 2:n=[...r.slice(0,-1),()=>a[0],()=>a[1],o];break;case 3:n=[...r.slice(0,-1),()=>a[0],()=>a[1],()=>a[2],o];break;default:throw new Error("Unsupported number of arguments")}c=up(...n),c.selectorArgs=a,t.set(d,c)}switch(i){case 3:c.selectorArgs[2]=s;case 2:c.selectorArgs[1]=l;case 1:c.selectorArgs[0]=a}switch(i){case 0:return c(n);case 1:return c(n,a);case 2:return c(n,a,l);case 3:return c(n,a,l,s);default:throw new Error("unreachable")}}};var mp,fp={exports:{}},gp={};var xp,bp={};
15
15
  /**
16
16
  * @license React
17
17
  * use-sync-external-store-shim.development.js
@@ -20,7 +20,7 @@ object-assign
20
20
  *
21
21
  * This source code is licensed under the MIT license found in the
22
22
  * LICENSE file in the root directory of this source tree.
23
- */"production"===process.env.NODE_ENV?pp.exports=function(){if(up)return hp;up=1;var e=t,r="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},o=e.useState,n=e.useEffect,i=e.useLayoutEffect,a=e.useDebugValue;function l(e){var t=e.getSnapshot;e=e.value;try{var o=t();return!r(e,o)}catch(e){return!0}}var s="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var r=t(),s=o({inst:{value:r,getSnapshot:t}}),d=s[0].inst,c=s[1];return i(function(){d.value=r,d.getSnapshot=t,l(d)&&c({inst:d})},[e,r,t]),n(function(){return l(d)&&c({inst:d}),e(function(){l(d)&&c({inst:d})})},[e]),a(r),r};return hp.useSyncExternalStore=void 0!==e.useSyncExternalStore?e.useSyncExternalStore:s,hp}():pp.exports=(mp||(mp=1,"production"!==process.env.NODE_ENV&&function(){function e(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!o(e,r)}catch(e){return!0}}"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var r=t,o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=r.useState,i=r.useEffect,a=r.useLayoutEffect,l=r.useDebugValue,s=!1,d=!1,c="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(t,c){s||void 0===r.startTransition||(s=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var u=c();if(!d){var p=c();o(u,p)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),d=!0)}var h=(p=n({inst:{value:u,getSnapshot:c}}))[0].inst,m=p[1];return a(function(){h.value=u,h.getSnapshot=c,e(h)&&m({inst:h})},[t,u,c]),i(function(){return e(h)&&m({inst:h}),t(function(){e(h)&&m({inst:h})})},[t]),l(u),u};fp.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:c,"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),fp);var gp,xp=pp.exports,bp={exports:{}},vp={};var yp,Sp={};
23
+ */"production"===process.env.NODE_ENV?fp.exports=function(){if(mp)return gp;mp=1;var e=t,r="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},o=e.useState,n=e.useEffect,i=e.useLayoutEffect,a=e.useDebugValue;function l(e){var t=e.getSnapshot;e=e.value;try{var o=t();return!r(e,o)}catch(e){return!0}}var s="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var r=t(),s=o({inst:{value:r,getSnapshot:t}}),d=s[0].inst,c=s[1];return i(function(){d.value=r,d.getSnapshot=t,l(d)&&c({inst:d})},[e,r,t]),n(function(){return l(d)&&c({inst:d}),e(function(){l(d)&&c({inst:d})})},[e]),a(r),r};return gp.useSyncExternalStore=void 0!==e.useSyncExternalStore?e.useSyncExternalStore:s,gp}():fp.exports=(xp||(xp=1,"production"!==process.env.NODE_ENV&&function(){function e(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!o(e,r)}catch(e){return!0}}"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var r=t,o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=r.useState,i=r.useEffect,a=r.useLayoutEffect,l=r.useDebugValue,s=!1,d=!1,c="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(t,c){s||void 0===r.startTransition||(s=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var u=c();if(!d){var p=c();o(u,p)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),d=!0)}var h=(p=n({inst:{value:u,getSnapshot:c}}))[0].inst,m=p[1];return a(function(){h.value=u,h.getSnapshot=c,e(h)&&m({inst:h})},[t,u,c]),i(function(){return e(h)&&m({inst:h}),t(function(){e(h)&&m({inst:h})})},[t]),l(u),u};bp.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:c,"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),bp);var vp,yp=fp.exports,Sp={exports:{}},kp={};var Bp,wp={};
24
24
  /**
25
25
  * @license React
26
26
  * use-sync-external-store-shim/with-selector.development.js
@@ -29,7 +29,7 @@ object-assign
29
29
  *
30
30
  * This source code is licensed under the MIT license found in the
31
31
  * LICENSE file in the root directory of this source tree.
32
- */"production"===process.env.NODE_ENV?bp.exports=function(){if(gp)return vp;gp=1;var e=t,r=xp,o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=r.useSyncExternalStore,i=e.useRef,a=e.useEffect,l=e.useMemo,s=e.useDebugValue;return vp.useSyncExternalStoreWithSelector=function(e,t,r,d,c){var u=i(null);if(null===u.current){var p={hasValue:!1,value:null};u.current=p}else p=u.current;u=l(function(){function e(e){if(!a){if(a=!0,n=e,e=d(e),void 0!==c&&p.hasValue){var t=p.value;if(c(t,e))return i=t}return i=e}if(t=i,o(n,e))return t;var r=d(e);return void 0!==c&&c(t,r)?(n=e,t):(n=e,i=r)}var n,i,a=!1,l=void 0===r?null:r;return[function(){return e(t())},null===l?void 0:function(){return e(l())}]},[t,r,d,c]);var h=n(e,u[0],u[1]);return a(function(){p.hasValue=!0,p.value=h},[h]),s(h),h},vp}():bp.exports=(yp||(yp=1,"production"!==process.env.NODE_ENV&&function(){"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var e=t,r=xp,o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=r.useSyncExternalStore,i=e.useRef,a=e.useEffect,l=e.useMemo,s=e.useDebugValue;Sp.useSyncExternalStoreWithSelector=function(e,t,r,d,c){var u=i(null);if(null===u.current){var p={hasValue:!1,value:null};u.current=p}else p=u.current;u=l(function(){function e(e){if(!a){if(a=!0,n=e,e=d(e),void 0!==c&&p.hasValue){var t=p.value;if(c(t,e))return i=t}return i=e}if(t=i,o(n,e))return t;var r=d(e);return void 0!==c&&c(t,r)?(n=e,t):(n=e,i=r)}var n,i,a=!1,l=void 0===r?null:r;return[function(){return e(t())},null===l?void 0:function(){return e(l())}]},[t,r,d,c]);var h=n(e,u[0],u[1]);return a(function(){p.hasValue=!0,p.value=h},[h]),s(h),h},"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),Sp);var kp=bp.exports;const Bp=parseInt(e.version,10)>=19?function(t,r,o,n,i){const a=e.useCallback(()=>r(t.getSnapshot(),o,n,i),[t,r,o,n,i]);return xp.useSyncExternalStore(t.subscribe,a,a)}:function(e,t,r,o,n){return kp.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,r,o,n))};function wp(e,t,r,o,n){return Bp(e,t,r,o,n)}class Cp{static create(e){return new Cp(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){this.state=e,this.updateTick+=1;const t=this.updateTick,r=this.listeners.values();let o;for(;o=r.next(),!o.done;){if(t!==this.updateTick)return;(0,o.value)(e)}}update(e){for(const t in e)if(!Object.is(this.state[t],e[t]))return void this.setState(bu({},this.state,e))}set(e,t){Object.is(this.state[e],t)||this.setState(bu({},this.state,{[e]:t}))}use=(()=>(e,t,r,o)=>wp(this,e,t,r,o))()}const Tp=dp(e=>e.providedTreeId??e.treeId),Ip={treeId:Tp,treeItemIdAttribute:dp(Tp,(e,t,r)=>null!=r?r:`${e??""}-${t}`)},Ap="__TREE_VIEW_ROOT_PARENT_ID__",zp=e=>{const t={};return e.forEach((e,r)=>{t[e]=r}),t},Rp=(e,t)=>{if(null==t)return!1;let r=e[t];if(!r)return!1;if(r.disabled)return!0;for(;null!=r.parentId;){if(r=e[r.parentId],!r)return!1;if(r.disabled)return!0}return!1};function Ep(e){const{storeParameters:t,items:r,parentId:o,depth:n,isItemExpandable:i,otherItemsMetaLookup:a}=e,l={},s={},d=[],c=[],u=e=>{const r=t.getItemId?t.getItemId(e):e.id;!function({id:e,parentId:t,item:r,itemMetaLookup:o,siblingsMetaLookup:n}){if(null==e)throw new Error(["MUI X: The Tree View component requires all items to have a unique `id` property.","Alternatively, you can use the `getItemId` prop to specify a custom id for each item.","An item was provided without id in the `items` prop:",JSON.stringify(r)].join("\n"));if(null!=n[e]||null!=o[e]&&o[e].parentId!==t)throw new Error(["MUI X: The Tree View component requires all items to have a unique `id` property.","Alternatively, you can use the `getItemId` prop to specify a custom id for each item.",`Two items were provided with the same id in the \`items\` prop: "${e}"`].join("\n"))}({id:r,parentId:o,item:e,itemMetaLookup:a,siblingsMetaLookup:l});const u=t.getItemLabel?t.getItemLabel(e):e.label;if(null==u)throw new Error(["MUI X: The Tree View component requires all items to have a `label` property.","Alternatively, you can use the `getItemLabel` prop to specify a custom label for each item.","An item was provided without label in the `items` prop:",JSON.stringify(e)].join("\n"));const p=(t.getItemChildren?t.getItemChildren(e):e.children)||[];c.push({id:r,children:p}),s[r]=e,l[r]={id:r,label:u,parentId:o,idAttribute:void 0,expandable:i(e,p),disabled:!!t.isItemDisabled&&t.isItemDisabled(e),selectable:!t.isItemSelectionDisabled||!t.isItemSelectionDisabled(e),depth:n},d.push(r)};for(const e of r)u(e);return{metaLookup:l,modelLookup:s,orderedChildrenIds:d,childrenIndexes:zp(d),itemsChildren:c}}const Pp=[],Op={domStructure:dp(e=>e.domStructure),disabledItemFocusable:dp(e=>e.disabledItemsFocusable),itemMetaLookup:dp(e=>e.itemMetaLookup),itemOrderedChildrenIdsLookup:dp(e=>e.itemOrderedChildrenIdsLookup),itemMeta:dp((e,t)=>e.itemMetaLookup[t??Ap]??null),itemOrderedChildrenIds:dp((e,t)=>e.itemOrderedChildrenIdsLookup[t??Ap]??Pp),itemModel:dp((e,t)=>e.itemModelLookup[t]),isItemDisabled:dp((e,t)=>Rp(e.itemMetaLookup,t)),itemIndex:dp((e,t)=>{const r=e.itemMetaLookup[t];if(null==r)return-1;return e.itemChildrenIndexesLookup[r.parentId??Ap][r.id]}),itemParentId:dp((e,t)=>e.itemMetaLookup[t]?.parentId??null),itemDepth:dp((e,t)=>e.itemMetaLookup[t]?.depth??0),canItemBeFocused:dp((e,t)=>e.disabledItemsFocusable||null!=e.itemModelLookup[t]&&!Rp(e.itemMetaLookup,t)),itemChildrenIndentation:dp(e=>e.itemChildrenIndentation)};class Lp{constructor(e){this.store=e}static shouldRebuildItemsState=(e,t)=>["items","isItemDisabled","isItemSelectionDisabled","getItemId","getItemLabel","getItemChildren"].some(r=>{const o=r;return e[o]!==t[o]});static buildItemsStateIfNeeded=e=>{const t={},r={},o={},n={};return function i(a,l,s){const d=l??Ap,{metaLookup:c,modelLookup:u,orderedChildrenIds:p,childrenIndexes:h,itemsChildren:m}=Ep({storeParameters:e,items:a,parentId:l,depth:s,isItemExpandable:(e,t)=>!!t&&t.length>0,otherItemsMetaLookup:t});Object.assign(t,c),Object.assign(r,u),o[d]=p,n[d]=h;for(const e of m)i(e.children||[],e.id,s+1)}(e.items,null,0),{itemMetaLookup:t,itemModelLookup:r,itemOrderedChildrenIdsLookup:o,itemChildrenIndexesLookup:n}};getItem=e=>Op.itemModel(this.store.state,e);getItemTree=()=>{const e=t=>{const r=bu({},Op.itemModel(this.store.state,t)),o=Op.itemOrderedChildrenIds(this.store.state,t);return o.length>0?r.children=o.map(e):delete r.children,r};return Op.itemOrderedChildrenIds(this.store.state,null).map(e)};getItemOrderedChildrenIds=e=>Op.itemOrderedChildrenIds(this.store.state,e);getParentId=e=>{const t=Op.itemMeta(this.store.state,e);return t?.parentId||null};setIsItemDisabled=({itemId:e,shouldBeDisabled:t})=>{if(!this.store.state.itemMetaLookup[e])return;const r=bu({},this.store.state.itemMetaLookup);r[e]=bu({},r[e],{disabled:t??!r[e].disabled}),this.store.set("itemMetaLookup",r)};buildPublicAPI=()=>({getItem:this.getItem,getItemDOMElement:this.getItemDOMElement,getItemOrderedChildrenIds:this.getItemOrderedChildrenIds,getItemTree:this.getItemTree,getParentId:this.getParentId,setIsItemDisabled:this.setIsItemDisabled});getItemDOMElement=e=>{const t=Op.itemMeta(this.store.state,e);if(null==t)return null;const r=Ip.treeItemIdAttribute(this.store.state,e,t.idAttribute);return document.getElementById(r)};setItemChildren=({items:e,parentId:t,getChildrenCount:r})=>{const o=t??Ap,n=null==t?-1:Op.itemDepth(this.store.state,t),{metaLookup:i,modelLookup:a,orderedChildrenIds:l,childrenIndexes:s}=Ep({storeParameters:this.store.parameters,items:e,parentId:t,depth:n+1,isItemExpandable:r?e=>0!==r(e):()=>!1,otherItemsMetaLookup:Op.itemMetaLookup(this.store.state)});this.store.update({itemModelLookup:bu({},this.store.state.itemModelLookup,a),itemMetaLookup:bu({},this.store.state.itemMetaLookup,i),itemOrderedChildrenIdsLookup:bu({},this.store.state.itemOrderedChildrenIdsLookup,{[o]:l}),itemChildrenIndexesLookup:bu({},this.store.state.itemChildrenIndexesLookup,{[o]:s})})};removeChildren=e=>{const t=this.store.state.itemMetaLookup,r=Object.keys(t).reduce((r,o)=>{const n=t[o];return n.parentId===e?r:bu({},r,{[n.id]:n})},{}),o=bu({},this.store.state.itemOrderedChildrenIdsLookup),n=bu({},this.store.state.itemChildrenIndexesLookup),i=e??Ap;delete n[i],delete o[i],this.store.update({itemMetaLookup:r,itemOrderedChildrenIdsLookup:o,itemChildrenIndexesLookup:n})};handleItemClick=(e,t)=>{this.store.parameters.onItemClick?.(e,t)}}const Mp=cp(e=>e.selectedItems,e=>Array.isArray(e)?e:null!=e?[e]:[]),Wp=cp(Mp,e=>{const t=new Map;return e.forEach(e=>{t.set(e,!0)}),t}),Dp=dp((e,t)=>e.itemMetaLookup[t]?.selectable??!0),Fp={selectedItemsRaw:dp(e=>e.selectedItems),selectedItems:Mp,selectedItemsMap:Wp,enabled:dp(e=>!e.disableSelection),isMultiSelectEnabled:dp(e=>e.multiSelect),isCheckboxSelectionEnabled:dp(e=>e.checkboxSelection),propagationRules:dp(e=>e.selectionPropagation),isItemSelected:dp(Wp,(e,t)=>e.has(t)),isFeatureEnabledForItem:dp(Dp,e=>!e.disableSelection,(e,t,r)=>t&&e),canItemBeSelected:dp(Op.isItemDisabled,Dp,e=>!e.disableSelection,(e,t,r,o)=>r&&!e&&t),isItemSelectable:Dp},Np=dp((e,t)=>{if(Fp.isItemSelected(e,t))return"checked";let r=!1,o=!1;const n=i=>{i!==t&&(Fp.isItemSelected(e,i)?r=!0:o=!0),Op.itemOrderedChildrenIds(e,i).forEach(n)};n(t);return Fp.propagationRules(e).parents?r&&o?"indeterminate":r&&!o?"checked":"empty":r?"indeterminate":"empty"}),Hp=({props:e})=>{const{itemId:t}=e,{store:r}=Qu(),o=wp(r,Fp.isCheckboxSelectionEnabled),n=wp(r,Fp.isFeatureEnabledForItem,t),i=wp(r,Fp.canItemBeSelected,t),a=wp(r,Np,t);return{propsEnhancers:{root:()=>{let e;return e="checked"===a||("indeterminate"===a?"mixed":!i&&void 0),{"aria-checked":e}},checkbox:({externalEventHandlers:e,interactions:l})=>({tabIndex:-1,onChange:o=>{e.onChange?.(o),o.defaultMuiPrevented||Fp.canItemBeSelected(r.state,t)&&l.handleCheckboxSelection(o)},visible:o&&n,disabled:!i,checked:"checked"===a,indeterminate:"indeterminate"===a})}}},Vp=cp(e=>e.expandedItems,e=>{const t=new Map;return e.forEach(e=>{t.set(e,!0)}),t}),Qp={expandedItemsRaw:dp(e=>e.expandedItems),expandedItemsMap:Vp,flatList:cp(Op.itemOrderedChildrenIdsLookup,Vp,(e,t)=>(e[Ap]??[]).flatMap(function r(o){if(!t.has(o))return[o];const n=[o],i=e[o]||[];for(const e of i)n.push(...r(e));return n})),triggerSlot:dp(e=>e.expansionTrigger),isItemExpanded:dp(Vp,(e,t)=>e.has(t)),isItemExpandable:dp(Op.itemMeta,(e,t)=>e?.expandable??!1)},jp=(e,t)=>{let r=t.length-1;for(;r>=0&&!Op.canItemBeFocused(e,t[r]);)r-=1;if(-1!==r)return t[r]},Gp=(e,t)=>{const r=Op.itemMeta(e,t);if(!r)return null;const o=Op.itemOrderedChildrenIds(e,r.parentId),n=Op.itemIndex(e,t);if(0===n)return r.parentId;let i=n-1;for(;!Op.canItemBeFocused(e,o[i])&&i>=0;)i-=1;if(-1===i)return null==r.parentId?null:Gp(e,r.parentId);let a=o[i],l=jp(e,Op.itemOrderedChildrenIds(e,a));for(;Qp.isItemExpanded(e,a)&&null!=l;)a=l,l=jp(e,Op.itemOrderedChildrenIds(e,a));return a},Up=(e,t)=>{if(Qp.isItemExpanded(e,t)){const r=Op.itemOrderedChildrenIds(e,t).find(t=>Op.canItemBeFocused(e,t));if(null!=r)return r}let r=Op.itemMeta(e,t);for(;null!=r;){const t=Op.itemOrderedChildrenIds(e,r.parentId),o=Op.itemIndex(e,r.id);if(o<t.length-1){let r=o+1;for(;!Op.canItemBeFocused(e,t[r])&&r<t.length-1;)r+=1;if(Op.canItemBeFocused(e,t[r]))return t[r]}r=Op.itemMeta(e,r.parentId)}return null},Xp=e=>{let t=null;for(;null==t||Qp.isItemExpanded(e,t);){const r=Op.itemOrderedChildrenIds(e,t),o=jp(e,r);if(null==o)return t;t=o}return t},Kp=e=>Op.itemOrderedChildrenIds(e,null).find(t=>Op.canItemBeFocused(e,t)),qp=(e,t,r)=>{if(t===r)return[t,r];const o=Op.itemMeta(e,t),n=Op.itemMeta(e,r);if(!o||!n)return[t,r];if(o.parentId===n.id||n.parentId===o.id)return n.parentId===o.id?[o.id,n.id]:[n.id,o.id];const i=[o.id],a=[n.id];let l=o.parentId,s=n.parentId,d=-1!==a.indexOf(l),c=-1!==i.indexOf(s),u=!0,p=!0;for(;!c&&!d;)u&&(i.push(l),d=-1!==a.indexOf(l),u=null!==l,!d&&u&&(l=Op.itemParentId(e,l))),p&&!d&&(a.push(s),c=-1!==i.indexOf(s),p=null!==s,!c&&p&&(s=Op.itemParentId(e,s)));const h=d?l:s,m=Op.itemOrderedChildrenIds(e,h),f=i[i.indexOf(h)-1],g=a[a.indexOf(h)-1];return m.indexOf(f)<m.indexOf(g)?[t,r]:[r,t]},Jp=(e,t)=>t!==e.closest('*[role="treeitem"]');class Yp{lastSelectedItem=null;lastSelectedRange={};constructor(e){this.store=e,e.itemPluginManager.register(Hp,null)}setSelectedItems=(e,t,r)=>{const{selectionPropagation:o=Hu,selectedItems:n,onItemSelectionToggle:i,onSelectedItemsChange:a}=this.store.parameters,l=Fp.selectedItemsRaw(this.store.state);let s;const d=Fp.isMultiSelectEnabled(this.store.state);if(s=d&&(o.descendants||o.parents)?function({store:e,selectionPropagation:t,newModel:r,oldModel:o,additionalItemsToPropagate:n}){if(!t.descendants&&!t.parents)return r;let i=!1;const a=Zp(r),l=$p({store:e,newModel:r,oldModel:o});return n?.forEach(e=>{a[e]?l.added.includes(e)||l.added.push(e):l.removed.includes(e)||l.removed.push(e)}),l.added.forEach(r=>{if(t.descendants){const t=o=>{o!==r&&(i=!0,a[o]=!0),Op.itemOrderedChildrenIds(e.state,o).forEach(t)};t(r)}if(t.parents){const t=r=>{if(!a[r])return!1;return Op.itemOrderedChildrenIds(e.state,r).every(t)},o=r=>{const n=Op.itemParentId(e.state,r);if(null==n)return;Op.itemOrderedChildrenIds(e.state,n).every(t)&&(i=!0,a[n]=!0,o(n))};o(r)}}),l.removed.forEach(r=>{if(t.parents){let t=Op.itemParentId(e.state,r);for(;null!=t;)a[t]&&(i=!0,delete a[t]),t=Op.itemParentId(e.state,t)}if(t.descendants){const t=o=>{o!==r&&(i=!0,delete a[o]),Op.itemOrderedChildrenIds(e.state,o).forEach(t)};t(r)}}),i?Object.keys(a):r}({store:this.store,selectionPropagation:o,newModel:t,oldModel:l,additionalItemsToPropagate:r}):t,i)if(d){const t=$p({store:this.store,newModel:s,oldModel:l});i&&(t.added.forEach(t=>{i(e,t,!0)}),t.removed.forEach(t=>{i(e,t,!1)}))}else s!==l&&(null!=l&&i(e,l,!1),null!=s&&i(e,s,!0));void 0===n&&this.store.set("selectedItems",s),a?.(e,s)};selectRange=(e,[t,r])=>{if(!Fp.isMultiSelectEnabled(this.store.state))return;let o=Fp.selectedItems(this.store.state).slice();Object.keys(this.lastSelectedRange).length>0&&(o=o.filter(e=>!this.lastSelectedRange[e]));const n=Zp(o),i=((e,t,r)=>{const o=t=>{if(Qp.isItemExpandable(e,t)&&Qp.isItemExpanded(e,t))return Op.itemOrderedChildrenIds(e,t)[0];let r=Op.itemMeta(e,t);for(;null!=r;){const t=Op.itemOrderedChildrenIds(e,r.parentId),o=Op.itemIndex(e,r.id);if(o<t.length-1)return t[o+1];r=r.parentId?Op.itemMeta(e,r.parentId):null}throw new Error("Invalid range")},[n,i]=qp(e,t,r),a=[n];let l=n;for(;l!==i;)l=o(l),Op.isItemDisabled(e,l)||a.push(l);return a})(this.store.state,t,r).filter(e=>Fp.isItemSelectable(this.store.state,e)),a=i.filter(e=>!n[e]);o=o.concat(a),this.setSelectedItems(e,o),this.lastSelectedRange=Zp(i)};buildPublicAPI=()=>({setItemSelection:this.setItemSelection});setItemSelection=({itemId:e,event:t=null,keepExistingSelection:r=!1,shouldBeSelected:o})=>{if(!Fp.enabled(this.store.state))return;let n;const i=Fp.isMultiSelectEnabled(this.store.state);if(r){const t=Fp.selectedItems(this.store.state),r=Fp.isItemSelected(this.store.state,e);n=!r||!1!==o&&null!=o?r||!0!==o&&null!=o?t:[e].concat(t):t.filter(t=>t!==e)}else n=!1===o||null==o&&Fp.isItemSelected(this.store.state,e)?i?[]:null:i?[e]:e;this.setSelectedItems(t,n,[e]),this.lastSelectedItem=e,this.lastSelectedRange={}};selectAllNavigableItems=e=>{if(!Fp.isMultiSelectEnabled(this.store.state))return;const t=(e=>{let t=Kp(e);const r=[];for(;null!=t;)r.push(t),t=Up(e,t);return r})(this.store.state);this.setSelectedItems(e,t),this.lastSelectedRange=Zp(t)};expandSelectionRange=(e,t)=>{if(null!=this.lastSelectedItem){const[r,o]=qp(this.store.state,t,this.lastSelectedItem);this.selectRange(e,[r,o])}};selectRangeFromStartToItem=(e,t)=>{this.selectRange(e,[Kp(this.store.state),t])};selectRangeFromItemToEnd=(e,t)=>{this.selectRange(e,[t,Xp(this.store.state)])};selectItemFromArrowNavigation=(e,t,r)=>{if(!Fp.isMultiSelectEnabled(this.store.state))return;let o=Fp.selectedItems(this.store.state).slice();0===Object.keys(this.lastSelectedRange).length?(o.push(r),this.lastSelectedRange={[t]:!0,[r]:!0}):(this.lastSelectedRange[t]||(this.lastSelectedRange={}),this.lastSelectedRange[r]?(o=o.filter(e=>e!==t),delete this.lastSelectedRange[t]):(o.push(r),this.lastSelectedRange[r]=!0)),this.setSelectedItems(e,o)}}function $p({store:e,oldModel:t,newModel:r}){const o=new Map;return r.forEach(e=>{o.set(e,!0)}),{added:r.filter(t=>!Fp.isItemSelected(e.state,t)),removed:t.filter(e=>!o.has(e))}}function Zp(e){const t={};return e.forEach(e=>{t[e]=!0}),t}const _p=e.createContext(null);function eh(t){const{children:r,itemId:o=null,idAttribute:n}=t,{store:i,rootRef:a}=Qu(),l=e.useRef(new Map);e.useEffect(()=>{if(!a.current)return;const e=Op.itemOrderedChildrenIds(i.state,o??null)??[],t=(n??a.current.id).replace(/["\\]/g,"\\$&");if(null!=o){const e=a.current.querySelector(`*[id="${t}"][role="treeitem"]`);if(e&&"false"===e.getAttribute("aria-expanded"))return}const r=a.current.querySelectorAll(`${null==o?"":`*[id="${t}"] `}[role="treeitem"]:not(*[id="${t}"] [role="treeitem"] [role="treeitem"])`),s=Array.from(r).map(e=>l.current.get(e.id)),d=s.length!==e.length||s.some((t,r)=>t!==e[r]);d&&i.jsxItems.setJSXItemsOrderedChildrenIds(o??null,s)});const s=e.useMemo(()=>({registerChild:(e,t)=>l.current.set(e,t),unregisterChild:e=>l.current.delete(e),parentId:o}),[o]);return de(_p.Provider,{value:s,children:r})}"production"!==process.env.NODE_ENV&&(_p.displayName="TreeViewChildrenItemContext"),"production"!==process.env.NODE_ENV&&(eh.propTypes={children:Di.node,id:Di.string});const th=e.createContext(()=>-1);"production"!==process.env.NODE_ENV&&(th.displayName="TreeViewItemDepthContext");const rh="undefined"!=typeof document?e.useLayoutEffect:()=>{},oh=[];const nh=e.createContext();"production"!==process.env.NODE_ENV&&(Di.node,Di.bool);function ih(t,r){const o=e.useContext(nh)??!1,n=yu(()=>new t(bu({},r,{isRtl:o}))).current;var i;return rh(()=>n.updateStateFromParameters(bu({},r,{isRtl:o})),[n,o,r]),i=n.disposeEffect,e.useEffect(i,oh),n}class ah{maxListeners=20;warnOnce=!1;events={};on(e,t,r={}){let o=this.events[e];if(o||(o={highPriority:new Map,regular:new Map},this.events[e]=o),r.isFirst?o.highPriority.set(t,!0):o.regular.set(t,!0),"production"!==process.env.NODE_ENV){const t=o.highPriority.size+o.regular.size;t>this.maxListeners&&!this.warnOnce&&(this.warnOnce=!0,console.warn([`Possible EventEmitter memory leak detected. ${t} ${e} listeners added.`].join("\n")))}}removeListener(e,t){this.events[e]&&(this.events[e].regular.delete(t),this.events[e].highPriority.delete(t))}removeAllListeners(){this.events={}}emit(e,...t){const r=this.events[e];if(!r)return;const o=Array.from(r.highPriority.keys()),n=Array.from(r.regular.keys());for(let e=o.length-1;e>=0;e-=1){const n=o[e];r.highPriority.has(n)&&n.apply(this,t)}for(let e=0;e<n.length;e+=1){const o=n[e];r.regular.has(o)&&o.apply(this,t)}}once(e,t){const r=this;this.on(e,function o(...n){r.removeListener(e,o),t.apply(r,n)})}}const lh=({isItemEditable:e,expansionTrigger:t})=>t||(e?"iconContainer":"content");function sh(e){return{disabledItemsFocusable:e.disabledItemsFocusable??!1,domStructure:"nested",itemChildrenIndentation:e.itemChildrenIndentation??"12px",providedTreeId:e.id,expansionTrigger:lh({isItemEditable:e.isItemEditable,expansionTrigger:e.expansionTrigger}),disableSelection:e.disableSelection??!1,multiSelect:e.multiSelect??!1,checkboxSelection:e.checkboxSelection??!1,selectionPropagation:e.selectionPropagation??Hu}}function dh(e,t,r){return void 0!==e?e:void 0!==t?t:r}let ch=0;class uh{timeoutIds=(()=>new Map)();intervalIds=(()=>new Map)();startTimeout=(e,t,r)=>{this.clearTimeout(e);const o=setTimeout(()=>{this.timeoutIds.delete(e),r()},t);this.timeoutIds.set(e,o)};startInterval=(e,t,r)=>{this.clearTimeout(e);const o=setInterval(r,t);this.intervalIds.set(e,o)};clearTimeout=e=>{const t=this.timeoutIds.get(e);null!=t&&(clearTimeout(t),this.timeoutIds.delete(e))};clearInterval=e=>{const t=this.intervalIds.get(e);null!=t&&(clearInterval(t),this.intervalIds.delete(e))};clearAll=()=>{this.timeoutIds.forEach(clearTimeout),this.timeoutIds.clear(),this.intervalIds.forEach(clearInterval),this.intervalIds.clear()}}class ph{constructor(e){this.store=e}setExpandedItems=(e,t)=>{void 0===this.store.parameters.expandedItems&&this.store.set("expandedItems",t),this.store.parameters.onExpandedItemsChange?.(e,t)};isItemExpanded=e=>Qp.isItemExpanded(this.store.state,e);buildPublicAPI=()=>({isItemExpanded:this.isItemExpanded,setItemExpansion:this.setItemExpansion});setItemExpansion=({itemId:e,event:t=null,shouldBeExpanded:r})=>{const o=Qp.isItemExpanded(this.store.state,e),n=r??!o;if(o===n)return;const i={isExpansionPrevented:!1,shouldBeExpanded:n,itemId:e};this.store.publishEvent("beforeItemToggleExpansion",i,t),i.isExpansionPrevented||this.applyItemExpansion({itemId:e,event:t,shouldBeExpanded:n})};applyItemExpansion=({itemId:e,event:t,shouldBeExpanded:r})=>{const o=Qp.expandedItemsRaw(this.store.state);let n;n=r?[e].concat(o):o.filter(t=>t!==e),this.store.parameters.onItemExpansionToggle?.(t,e,r),this.setExpandedItems(t,n)};expandAllSiblings=(e,t)=>{const r=Op.itemMeta(this.store.state,t);if(null==r)return;const o=Op.itemOrderedChildrenIds(this.store.state,r.parentId).filter(e=>Qp.isItemExpandable(this.store.state,e)&&!Qp.isItemExpanded(this.store.state,e)),n=Qp.expandedItemsRaw(this.store.state).concat(o);o.length>0&&(this.store.parameters.onItemExpansionToggle&&o.forEach(t=>{this.store.parameters.onItemExpansionToggle(e,t,!0)}),this.setExpandedItems(e,n))};addExpandableItems=e=>{const t=bu({},this.store.state.itemMetaLookup);for(const r of e)t[r]=bu({},t[r],{expandable:!0});this.store.set("itemMetaLookup",t)}}const hh={isItemEditable:dp(e=>e.isItemEditable,Op.itemModel,(e,t,r)=>!(!t||null==e)&&("boolean"==typeof e?e:e(t))),isItemBeingEdited:dp((e,t)=>null!=t&&e.editedItemId===t),isAnyItemBeingEdited:dp(e=>!!e.editedItemId)};class mh{typeaheadQuery="";constructor(e){this.store=e,this.labelMap=fh(Op.itemMetaLookup(this.store.state)),this.store.registerStoreEffect(Op.itemMetaLookup,(e,t)=>{this.store.shouldIgnoreItemsStateUpdate()||(this.labelMap=fh(t))})}canToggleItemSelection=e=>Fp.canItemBeSelected(this.store.state,e);canToggleItemExpansion=e=>!Op.isItemDisabled(this.store.state,e)&&Qp.isItemExpandable(this.store.state,e);getFirstItemMatchingTypeaheadQuery=(e,t)=>{const r=e=>{const t=Up(this.store.state,e);return null===t?Kp(this.store.state):t},o=t=>{let o=null;const n={};let i=t.length>1?e:r(e);for(;null==o&&!n[i];){const e=this.labelMap[i];e?.startsWith(t)?o=i:(n[i]=!0,i=r(i))}return o},n=t.toLowerCase(),i=`${this.typeaheadQuery}${n}`,a=o(i);if(null!=a)return this.typeaheadQuery=i,a;const l=o(n);return null!=l?(this.typeaheadQuery=n,l):(this.typeaheadQuery="",null)};updateLabelMap=e=>{this.labelMap=e(this.labelMap)};handleItemKeyDown=async(e,t)=>{if(e.defaultMuiPrevented)return;if(e.altKey||Jp(e.target,e.currentTarget))return;const r=e.ctrlKey||e.metaKey,o=e.key,n=Fp.isMultiSelectEnabled(this.store.state);switch(!0){case" "===o&&this.canToggleItemSelection(t):e.preventDefault(),n&&e.shiftKey?this.store.selection.expandSelectionRange(e,t):this.store.selection.setItemSelection({event:e,itemId:t,keepExistingSelection:n,shouldBeSelected:void 0});break;case"Enter"===o:this.store.labelEditing?.setEditedItem&&hh.isItemEditable(this.store.state,t)&&!hh.isItemBeingEdited(this.store.state,t)?this.store.labelEditing.setEditedItem(t):this.canToggleItemExpansion(t)?(this.store.expansion.setItemExpansion({event:e,itemId:t}),e.preventDefault()):this.canToggleItemSelection(t)&&(n?(e.preventDefault(),this.store.selection.setItemSelection({event:e,itemId:t,keepExistingSelection:!0})):Fp.isItemSelected(this.store.state,t)||(this.store.selection.setItemSelection({event:e,itemId:t}),e.preventDefault()));break;case"ArrowDown"===o:{const r=Up(this.store.state,t);r&&(e.preventDefault(),this.store.focus.focusItem(e,r),n&&e.shiftKey&&this.canToggleItemSelection(r)&&this.store.selection.selectItemFromArrowNavigation(e,t,r));break}case"ArrowUp"===o:{const r=Gp(this.store.state,t);r&&(e.preventDefault(),this.store.focus.focusItem(e,r),n&&e.shiftKey&&this.canToggleItemSelection(r)&&this.store.selection.selectItemFromArrowNavigation(e,t,r));break}case"ArrowRight"===o&&!this.store.parameters.isRtl||"ArrowLeft"===o&&this.store.parameters.isRtl:if(r)return;if(Qp.isItemExpanded(this.store.state,t)){const r=Up(this.store.state,t);r&&(this.store.focus.focusItem(e,r),e.preventDefault())}else this.canToggleItemExpansion(t)&&(this.store.expansion.setItemExpansion({event:e,itemId:t}),e.preventDefault());break;case"ArrowLeft"===o&&!this.store.parameters.isRtl||"ArrowRight"===o&&this.store.parameters.isRtl:if(r)return;if(this.canToggleItemExpansion(t)&&Qp.isItemExpanded(this.store.state,t))this.store.expansion.setItemExpansion({event:e,itemId:t}),e.preventDefault();else{const r=Op.itemParentId(this.store.state,t);r&&(this.store.focus.focusItem(e,r),e.preventDefault())}break;case"Home"===o:this.canToggleItemSelection(t)&&n&&r&&e.shiftKey?this.store.selection.selectRangeFromStartToItem(e,t):this.store.focus.focusItem(e,Kp(this.store.state)),e.preventDefault();break;case"End"===o:this.canToggleItemSelection(t)&&n&&r&&e.shiftKey?this.store.selection.selectRangeFromItemToEnd(e,t):this.store.focus.focusItem(e,Xp(this.store.state)),e.preventDefault();break;case"*"===o:this.store.expansion.expandAllSiblings(e,t),e.preventDefault();break;case"A"===String.fromCharCode(e.keyCode)&&r&&n&&Fp.enabled(this.store.state):this.store.selection.selectAllNavigableItems(e),e.preventDefault();break;case!(r||e.shiftKey||(i=o,!i||1!==i.length||!i.match(/\S/))):{this.store.timeoutManager.clearTimeout("typeahead");const r=this.getFirstItemMatchingTypeaheadQuery(t,o);null!=r?(this.store.focus.focusItem(e,r),e.preventDefault()):this.typeaheadQuery="",this.store.timeoutManager.startTimeout("typeahead",500,()=>{this.typeaheadQuery=""});break}}var i}}function fh(e){const t={};return Object.values(e).forEach(e=>{t[e.id]=e.label.toLowerCase()}),t}const gh=cp(Fp.selectedItems,Qp.expandedItemsMap,Op.itemMetaLookup,Op.disabledItemFocusable,e=>Op.itemOrderedChildrenIds(e,null),(e,t,r,o,n)=>{const i=e.find(e=>{if(!o&&Rp(r,e))return!1;const n=r[e];return n&&(null==n.parentId||t.has(n.parentId))});if(null!=i)return i;const a=n.find(e=>o||!Rp(r,e));return null!=a?a:null}),xh={defaultFocusableItemId:gh,isItemTheDefaultFocusableItem:dp(gh,(e,t)=>e===t),focusedItemId:dp(e=>e.focusedItemId),isItemFocused:dp((e,t)=>e.focusedItemId===t)};class bh{constructor(e){this.store=e;let t=e.state;this.store.subscribe(e=>{if(e.itemMetaLookup===t.itemMetaLookup)return void(t=e);const r=xh.focusedItemId(e);if(null==r||Op.itemMeta(e,r))return void(t=e);const o=t=>null!=t&&Op.itemMeta(e,t)?t:null,n=o(Up(t,r))??o(Gp(t,r))??Kp(e);null==n?this.setFocusedItemId(null):this.applyItemFocus(null,n),t=e})}setFocusedItemId=e=>{xh.focusedItemId(this.store.state)!==e&&this.store.set("focusedItemId",e)};applyItemFocus=(e,t)=>{this.store.items.getItemDOMElement(t)?.focus(),this.setFocusedItemId(t),this.store.parameters.onItemFocus?.(e,t)};buildPublicAPI=()=>({focusItem:this.focusItem});focusItem=(e,t)=>{const r=Op.itemMeta(this.store.state,t);r&&(null==r.parentId||Qp.isItemExpanded(this.store.state,r.parentId))&&this.applyItemFocus(e,t)};removeFocusedItem=()=>{const e=xh.focusedItemId(this.store.state);if(null==e)return;if(Op.itemMeta(this.store.state,e)){const t=this.store.items.getItemDOMElement(e);t&&t.blur()}this.setFocusedItemId(null)};handleRootFocus=e=>{if(e.defaultMuiPrevented)return;const t=xh.defaultFocusableItemId(this.store.state);e.target===e.currentTarget&&null!=t&&this.applyItemFocus(e,t)};handleRootBlur=e=>{e.defaultMuiPrevented||this.setFocusedItemId(null)}}class vh{itemPlugins=[];itemWrappers=[];register=(e,t)=>{this.itemPlugins.push(e),t&&this.itemWrappers.push(t)};listPlugins=()=>this.itemPlugins;listWrappers=()=>this.itemWrappers}class yh extends Cp{initialParameters=null;eventManager=(()=>new ah)();timeoutManager=(()=>new uh)();itemPluginManager=(()=>new vh)();constructor(e,t,r){const o=function(e){return bu({treeId:void 0,focusedItemId:null},sh(e),Lp.buildItemsStateIfNeeded(e),{expandedItems:dh(e.expandedItems,e.defaultExpandedItems,[]),selectedItems:dh(e.selectedItems,e.defaultSelectedItems,e.multiSelect?Nu:null)})}(e);super(r.getInitialState(o,e)),this.parameters=e,this.instanceName=t,this.mapper=r,this.items=new Lp(this),this.focus=new bh(this),this.expansion=new ph(this),this.selection=new Yp(this),this.keyboardNavigation=new mh(this),"production"!==process.env.NODE_ENV&&(this.initialParameters=e)}buildPublicAPI(){return bu({},this.items.buildPublicAPI(),this.focus.buildPublicAPI(),this.expansion.buildPublicAPI(),this.selection.buildPublicAPI())}updateStateFromParameters(e){const t=(t,r,o)=>{if(void 0!==e[r]&&(t[r]=e[r]),"production"!==process.env.NODE_ENV){const t=e[o],n=void 0!==e[r],i=this.initialParameters?.[o],a=void 0!==this.initialParameters?.[r];a!==n?Eu([`MUI X Tree View: A component is changing the ${a?"":"un"}controlled ${r} state of ${this.instanceName} to be ${a?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${r} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"],"error"):JSON.stringify(i)!==JSON.stringify(t)&&Eu([`MUI X Tree View: A component is changing the default ${r} state of an uncontrolled ${this.instanceName} after being initialized. `,`To suppress this warning opt to use a controlled ${this.instanceName}.`],"error")}},r=sh(e);t(r,"expandedItems","defaultExpandedItems"),t(r,"selectedItems","defaultSelectedItems"),this.state.providedTreeId===e.id&&void 0!==this.state.treeId||(r.treeId=(ch+=1,`mui-tree-view-${ch}`)),!this.mapper.shouldIgnoreItemsStateUpdate(e)&&Lp.shouldRebuildItemsState(e,this.parameters)&&Object.assign(r,Lp.buildItemsStateIfNeeded(e));const o=this.mapper.updateStateFromParameters(r,e,t);this.update(o),this.parameters=e}disposeEffect=()=>this.timeoutManager.clearAll;shouldIgnoreItemsStateUpdate=()=>this.mapper.shouldIgnoreItemsStateUpdate(this.parameters);registerStoreEffect=(e,t)=>{let r=e(this.state);this.subscribe(o=>{const n=e(o);n!==r&&(t(r,n),r=n)})};publishEvent=(e,t,r)=>{(function(e){return void 0!==e?.isPropagationStopped})(r)&&r.isPropagationStopped()||this.eventManager.emit(e,t,r)};subscribeEvent=(e,t)=>{this.eventManager.on(e,t)}}const Sh={isEmpty:dp(e=>null==e.lazyLoadedItems||0===Object.keys(e.lazyLoadedItems.loading).length&&0===Object.keys(e.lazyLoadedItems.errors).length),isItemLoading:dp((e,t)=>e.lazyLoadedItems?.loading[t??Ap]??!1),itemHasError:dp((e,t)=>!!e.lazyLoadedItems?.errors[t??Ap]),itemError:dp((e,t)=>e.lazyLoadedItems?.errors[t??Ap])},kh=e=>Array.isArray(e)?e.length>0&&e.some(kh):Boolean(e),Bh=({props:t,rootRef:r,contentRef:o})=>{const{store:n}=Qu(),{children:i,disabled:a=!1,disableSelection:l=!1,label:s,itemId:d,id:c}=t,u=e.useContext(_p);if(null==u)throw new Error(["MUI X: Could not find the Tree View Children Item context.","It looks like you rendered your component outside of a SimpleTreeView parent component.","This can also happen if you are bundling multiple versions of the Tree View."].join("\n"));const{registerChild:p,unregisterChild:h,parentId:m}=u,f=kh(i),g=e.useRef(null),x=Su(g,o),b=wp(n,Ip.treeItemIdAttribute,d,c),v=e.useRef(!0),y=yu(Symbol);return rh(()=>(p(b,d),()=>{h(b),h(b)}),[n,p,h,b,d]),rh(()=>(v.current=!0,()=>{v.current=!1}),[]),rh(()=>{const e=n.jsxItems.upsertJSXItem({id:d,idAttribute:c,parentId:m,expandable:f,disabled:a,selectable:!l},y.current);return()=>{v.current||e()}},[n,m,d,f,a,l,c,y]),e.useEffect(()=>{if(s)return n.jsxItems.mapLabelFromJSX(d,(g.current?.textContent??"").toLowerCase())},[n,d,s]),{contentRef:x,rootRef:r}},wh=({children:t,itemId:r,idAttribute:o})=>{const n=e.useContext(th);return de(eh,{itemId:r,idAttribute:o,children:de(th.Provider,{value:n+1,children:t})})};"production"!==process.env.NODE_ENV&&(wh.displayName="jsxItemsitemWrapper");class Ch{itemOwners=(()=>new Map)();constructor(e){this.store=e,e.itemPluginManager.register(Bh,wh)}upsertJSXItem=(e,t)=>{const r=this.itemOwners.get(e.id);if(null!=r&&r!==t)throw new Error(["MUI X: The Tree View component requires all items to have a unique `id` property.","Alternatively, you can use the `getItemId` prop to specify a custom id for each item.",`Two items were provided with the same id in the \`items\` prop: "${e.id}"`].join("\n"));this.itemOwners.set(e.id,t);const o=Op.itemMeta(this.store.state,e.id);if(null!=o){let t=!1;for(const r of Object.keys(e))if(o[r]!==e[r]){t=!0;break}t&&this.store.update({itemMetaLookup:bu({},this.store.state.itemMetaLookup,{[e.id]:bu({},o,e)})})}else this.store.update({itemMetaLookup:bu({},this.store.state.itemMetaLookup,{[e.id]:e}),itemModelLookup:bu({},this.store.state.itemModelLookup,{[e.id]:{id:e.id,label:e.label??""}})});return()=>{this.itemOwners.delete(e.id);const t=bu({},this.store.state.itemMetaLookup),r=bu({},this.store.state.itemModelLookup);delete t[e.id],delete r[e.id],this.store.update({itemMetaLookup:t,itemModelLookup:r})}};mapLabelFromJSX=(e,t)=>(this.store.keyboardNavigation.updateLabelMap(r=>(r[e]=t,r)),()=>{this.store.keyboardNavigation.updateLabelMap(t=>{const r=bu({},t);return delete r[e],r})});setJSXItemsOrderedChildrenIds=(e,t)=>{const r=e??Ap;this.store.update({itemOrderedChildrenIdsLookup:bu({},this.store.state.itemOrderedChildrenIdsLookup,{[r]:t}),itemChildrenIndexesLookup:bu({},this.store.state.itemChildrenIndexesLookup,{[r]:zp(t)})})}}const Th={getInitialState:e=>e,updateStateFromParameters:e=>e,shouldIgnoreItemsStateUpdate:()=>!0};class Ih extends yh{jsxItems=(()=>new Ch(this))();constructor(e){super(bu({},e,{items:Nu}),"SimpleTreeView",Th)}updateStateFromParameters(e){super.updateStateFromParameters(bu({},e,{items:Nu}))}}const Ah=Pu(),zh=or("ul",{name:"MuiSimpleTreeView",slot:"Root"})({padding:0,margin:0,listStyle:"none",outline:0,position:"relative"}),Rh=e.forwardRef(function(t,r){const o=Ah({props:t,name:"MuiSimpleTreeView"});"production"!==process.env.NODE_ENV&&null!=o.items&&Eu(["MUI X: The Simple Tree View component does not support the `items` prop.","If you want to add items, you need to pass them as JSX children.","Check the documentation for more details: https://mui.com/x/react-tree-view/simple-tree-view/items/."]);const{slots:n,slotProps:i,apiRef:a,parameters:l,forwardedProps:s}=function(t){const{apiRef:r,slots:o,slotProps:n,disabledItemsFocusable:i,onItemClick:a,itemChildrenIndentation:l,id:s,expandedItems:d,defaultExpandedItems:c,onExpandedItemsChange:u,onItemExpansionToggle:p,expansionTrigger:h,disableSelection:m,selectedItems:f,defaultSelectedItems:g,multiSelect:x,checkboxSelection:b,selectionPropagation:v,onSelectedItemsChange:y,onItemSelectionToggle:S,onItemFocus:k}=t,B=Xu(t,Ku);return{apiRef:r,slots:o,slotProps:n,parameters:e.useMemo(()=>({disabledItemsFocusable:i,onItemClick:a,itemChildrenIndentation:l,id:s,expandedItems:d,defaultExpandedItems:c,onExpandedItemsChange:u,onItemExpansionToggle:p,expansionTrigger:h,disableSelection:m,selectedItems:f,defaultSelectedItems:g,multiSelect:x,checkboxSelection:b,selectionPropagation:v,onSelectedItemsChange:y,onItemSelectionToggle:S,onItemFocus:k}),[i,a,l,s,d,c,u,p,h,m,f,g,x,b,v,y,S,k]),forwardedProps:B}}(o),d=ih(Ih,l),c=e.useRef(null),u=function(e,t,r){const o=wp(e,Ip.treeId),n=wp(e,Op.itemChildrenIndentation),i=wp(e,Fp.isMultiSelectEnabled);return a=>bu({ref:r,role:"tree",id:o,"aria-multiselectable":i},t,a,{style:bu({},t.style,{"--TreeView-itemChildrenIndentation":"number"==typeof n?`${n}px`:n}),onFocus:t=>{a.onFocus?.(t),e.focus.handleRootFocus(t)},onBlur:t=>{a.onBlur?.(t),e.focus.handleRootBlur(t)}})}(d,s,Su(r,c)),p=(t=>{const{classes:r}=t;return e.useMemo(()=>Bu({root:["root"],item:["item"],itemContent:["itemContent"],itemGroupTransition:["itemGroupTransition"],itemIconContainer:["itemIconContainer"],itemLabel:["itemLabel"],itemCheckbox:["itemCheckbox"]},Fu,r),[r])})(o),h=n?.root??zh,m=zu({elementType:h,externalSlotProps:i?.root,className:p.root,getSlotProps:u,ownerState:o});return de(Uu,{store:d,classes:p,slots:n,slotProps:i,apiRef:a,rootRef:c,children:de(eh,{itemId:null,idAttribute:null,children:de(th.Provider,{value:0,children:de(h,bu({},m))})})})});"production"!==process.env.NODE_ENV&&(Rh.displayName="SimpleTreeView"),"production"!==process.env.NODE_ENV&&(Rh.propTypes={apiRef:Di.shape({current:Di.shape({focusItem:Di.func,getItem:Di.func,getItemDOMElement:Di.func,getItemOrderedChildrenIds:Di.func,getItemTree:Di.func,getParentId:Di.func,isItemExpanded:Di.func,setIsItemDisabled:Di.func,setItemExpansion:Di.func,setItemSelection:Di.func})}),checkboxSelection:Di.bool,children:Di.node,classes:Di.object,className:Di.string,defaultExpandedItems:Di.arrayOf(Di.string),defaultSelectedItems:Di.any,disabledItemsFocusable:Di.bool,disableSelection:Di.bool,expandedItems:Di.arrayOf(Di.string),expansionTrigger:Di.oneOf(["content","iconContainer"]),id:Di.string,itemChildrenIndentation:Di.oneOfType([Di.number,Di.string]),multiSelect:Di.bool,onExpandedItemsChange:Di.func,onItemClick:Di.func,onItemExpansionToggle:Di.func,onItemFocus:Di.func,onItemSelectionToggle:Di.func,onSelectedItemsChange:Di.func,selectedItems:Di.any,selectionPropagation:Di.shape({descendants:Di.bool,parents:Di.bool}),slotProps:Di.object,slots:Di.object,sx:Di.oneOfType([Di.arrayOf(Di.oneOfType([Di.func,Di.object,Di.bool])),Di.func,Di.object])});var Eh,Ph={exports:{}},Oh={};var Lh,Mh={};
32
+ */"production"===process.env.NODE_ENV?Sp.exports=function(){if(vp)return kp;vp=1;var e=t,r=yp,o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=r.useSyncExternalStore,i=e.useRef,a=e.useEffect,l=e.useMemo,s=e.useDebugValue;return kp.useSyncExternalStoreWithSelector=function(e,t,r,d,c){var u=i(null);if(null===u.current){var p={hasValue:!1,value:null};u.current=p}else p=u.current;u=l(function(){function e(e){if(!a){if(a=!0,n=e,e=d(e),void 0!==c&&p.hasValue){var t=p.value;if(c(t,e))return i=t}return i=e}if(t=i,o(n,e))return t;var r=d(e);return void 0!==c&&c(t,r)?(n=e,t):(n=e,i=r)}var n,i,a=!1,l=void 0===r?null:r;return[function(){return e(t())},null===l?void 0:function(){return e(l())}]},[t,r,d,c]);var h=n(e,u[0],u[1]);return a(function(){p.hasValue=!0,p.value=h},[h]),s(h),h},kp}():Sp.exports=(Bp||(Bp=1,"production"!==process.env.NODE_ENV&&function(){"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var e=t,r=yp,o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=r.useSyncExternalStore,i=e.useRef,a=e.useEffect,l=e.useMemo,s=e.useDebugValue;wp.useSyncExternalStoreWithSelector=function(e,t,r,d,c){var u=i(null);if(null===u.current){var p={hasValue:!1,value:null};u.current=p}else p=u.current;u=l(function(){function e(e){if(!a){if(a=!0,n=e,e=d(e),void 0!==c&&p.hasValue){var t=p.value;if(c(t,e))return i=t}return i=e}if(t=i,o(n,e))return t;var r=d(e);return void 0!==c&&c(t,r)?(n=e,t):(n=e,i=r)}var n,i,a=!1,l=void 0===r?null:r;return[function(){return e(t())},null===l?void 0:function(){return e(l())}]},[t,r,d,c]);var h=n(e,u[0],u[1]);return a(function(){p.hasValue=!0,p.value=h},[h]),s(h),h},"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),wp);var Cp=Sp.exports;const Tp=parseInt(e.version,10)>=19?function(t,r,o,n,i){const a=e.useCallback(()=>r(t.getSnapshot(),o,n,i),[t,r,o,n,i]);return yp.useSyncExternalStore(t.subscribe,a,a)}:function(e,t,r,o,n){return Cp.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,r,o,n))};function Ip(e,t,r,o,n){return Tp(e,t,r,o,n)}class Ap{static create(e){return new Ap(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){this.state=e,this.updateTick+=1;const t=this.updateTick,r=this.listeners.values();let o;for(;o=r.next(),!o.done;){if(t!==this.updateTick)return;(0,o.value)(e)}}update(e){for(const t in e)if(!Object.is(this.state[t],e[t]))return void this.setState(Su({},this.state,e))}set(e,t){Object.is(this.state[e],t)||this.setState(Su({},this.state,{[e]:t}))}use=(()=>(e,t,r,o)=>Ip(this,e,t,r,o))()}const zp=pp(e=>e.providedTreeId??e.treeId),Rp={treeId:zp,treeItemIdAttribute:pp(zp,(e,t,r)=>null!=r?r:`${e??""}-${t}`)},Ep="__TREE_VIEW_ROOT_PARENT_ID__",Pp=e=>{const t={};return e.forEach((e,r)=>{t[e]=r}),t},Op=(e,t)=>{if(null==t)return!1;let r=e[t];if(!r)return!1;if(r.disabled)return!0;for(;null!=r.parentId;){if(r=e[r.parentId],!r)return!1;if(r.disabled)return!0}return!1};function Lp(e){const{storeParameters:t,items:r,parentId:o,depth:n,isItemExpandable:i,otherItemsMetaLookup:a}=e,l={},s={},d=[],c=[],u=e=>{const r=t.getItemId?t.getItemId(e):e.id;!function({id:e,parentId:t,item:r,itemMetaLookup:o,siblingsMetaLookup:n}){if(null==e)throw new Error(["MUI X: The Tree View component requires all items to have a unique `id` property.","Alternatively, you can use the `getItemId` prop to specify a custom id for each item.","An item was provided without id in the `items` prop:",JSON.stringify(r)].join("\n"));if(null!=n[e]||null!=o[e]&&o[e].parentId!==t)throw new Error(["MUI X: The Tree View component requires all items to have a unique `id` property.","Alternatively, you can use the `getItemId` prop to specify a custom id for each item.",`Two items were provided with the same id in the \`items\` prop: "${e}"`].join("\n"))}({id:r,parentId:o,item:e,itemMetaLookup:a,siblingsMetaLookup:l});const u=t.getItemLabel?t.getItemLabel(e):e.label;if(null==u)throw new Error(["MUI X: The Tree View component requires all items to have a `label` property.","Alternatively, you can use the `getItemLabel` prop to specify a custom label for each item.","An item was provided without label in the `items` prop:",JSON.stringify(e)].join("\n"));const p=(t.getItemChildren?t.getItemChildren(e):e.children)||[];c.push({id:r,children:p}),s[r]=e,l[r]={id:r,label:u,parentId:o,idAttribute:void 0,expandable:i(e,p),disabled:!!t.isItemDisabled&&t.isItemDisabled(e),selectable:!t.isItemSelectionDisabled||!t.isItemSelectionDisabled(e),depth:n},d.push(r)};for(const e of r)u(e);return{metaLookup:l,modelLookup:s,orderedChildrenIds:d,childrenIndexes:Pp(d),itemsChildren:c}}const Mp=[],Wp={domStructure:pp(e=>e.domStructure),disabledItemFocusable:pp(e=>e.disabledItemsFocusable),itemMetaLookup:pp(e=>e.itemMetaLookup),itemOrderedChildrenIdsLookup:pp(e=>e.itemOrderedChildrenIdsLookup),itemMeta:pp((e,t)=>e.itemMetaLookup[t??Ep]??null),itemOrderedChildrenIds:pp((e,t)=>e.itemOrderedChildrenIdsLookup[t??Ep]??Mp),itemModel:pp((e,t)=>e.itemModelLookup[t]),isItemDisabled:pp((e,t)=>Op(e.itemMetaLookup,t)),itemIndex:pp((e,t)=>{const r=e.itemMetaLookup[t];if(null==r)return-1;return e.itemChildrenIndexesLookup[r.parentId??Ep][r.id]}),itemParentId:pp((e,t)=>e.itemMetaLookup[t]?.parentId??null),itemDepth:pp((e,t)=>e.itemMetaLookup[t]?.depth??0),canItemBeFocused:pp((e,t)=>e.disabledItemsFocusable||null!=e.itemModelLookup[t]&&!Op(e.itemMetaLookup,t)),itemChildrenIndentation:pp(e=>e.itemChildrenIndentation)};class Dp{constructor(e){this.store=e}static shouldRebuildItemsState=(e,t)=>["items","isItemDisabled","isItemSelectionDisabled","getItemId","getItemLabel","getItemChildren"].some(r=>{const o=r;return e[o]!==t[o]});static buildItemsStateIfNeeded=e=>{const t={},r={},o={},n={};return function i(a,l,s){const d=l??Ep,{metaLookup:c,modelLookup:u,orderedChildrenIds:p,childrenIndexes:h,itemsChildren:m}=Lp({storeParameters:e,items:a,parentId:l,depth:s,isItemExpandable:(e,t)=>!!t&&t.length>0,otherItemsMetaLookup:t});Object.assign(t,c),Object.assign(r,u),o[d]=p,n[d]=h;for(const e of m)i(e.children||[],e.id,s+1)}(e.items,null,0),{itemMetaLookup:t,itemModelLookup:r,itemOrderedChildrenIdsLookup:o,itemChildrenIndexesLookup:n}};getItem=e=>Wp.itemModel(this.store.state,e);getItemTree=()=>{const e=t=>{const r=Su({},Wp.itemModel(this.store.state,t)),o=Wp.itemOrderedChildrenIds(this.store.state,t);return o.length>0?r.children=o.map(e):delete r.children,r};return Wp.itemOrderedChildrenIds(this.store.state,null).map(e)};getItemOrderedChildrenIds=e=>Wp.itemOrderedChildrenIds(this.store.state,e);getParentId=e=>{const t=Wp.itemMeta(this.store.state,e);return t?.parentId||null};setIsItemDisabled=({itemId:e,shouldBeDisabled:t})=>{if(!this.store.state.itemMetaLookup[e])return;const r=Su({},this.store.state.itemMetaLookup);r[e]=Su({},r[e],{disabled:t??!r[e].disabled}),this.store.set("itemMetaLookup",r)};buildPublicAPI=()=>({getItem:this.getItem,getItemDOMElement:this.getItemDOMElement,getItemOrderedChildrenIds:this.getItemOrderedChildrenIds,getItemTree:this.getItemTree,getParentId:this.getParentId,setIsItemDisabled:this.setIsItemDisabled});getItemDOMElement=e=>{const t=Wp.itemMeta(this.store.state,e);if(null==t)return null;const r=Rp.treeItemIdAttribute(this.store.state,e,t.idAttribute);return document.getElementById(r)};setItemChildren=({items:e,parentId:t,getChildrenCount:r})=>{const o=t??Ep,n=null==t?-1:Wp.itemDepth(this.store.state,t),{metaLookup:i,modelLookup:a,orderedChildrenIds:l,childrenIndexes:s}=Lp({storeParameters:this.store.parameters,items:e,parentId:t,depth:n+1,isItemExpandable:r?e=>0!==r(e):()=>!1,otherItemsMetaLookup:Wp.itemMetaLookup(this.store.state)});this.store.update({itemModelLookup:Su({},this.store.state.itemModelLookup,a),itemMetaLookup:Su({},this.store.state.itemMetaLookup,i),itemOrderedChildrenIdsLookup:Su({},this.store.state.itemOrderedChildrenIdsLookup,{[o]:l}),itemChildrenIndexesLookup:Su({},this.store.state.itemChildrenIndexesLookup,{[o]:s})})};removeChildren=e=>{const t=this.store.state.itemMetaLookup,r=Object.keys(t).reduce((r,o)=>{const n=t[o];return n.parentId===e?r:Su({},r,{[n.id]:n})},{}),o=Su({},this.store.state.itemOrderedChildrenIdsLookup),n=Su({},this.store.state.itemChildrenIndexesLookup),i=e??Ep;delete n[i],delete o[i],this.store.update({itemMetaLookup:r,itemOrderedChildrenIdsLookup:o,itemChildrenIndexesLookup:n})};handleItemClick=(e,t)=>{this.store.parameters.onItemClick?.(e,t)}}const Fp=hp(e=>e.selectedItems,e=>Array.isArray(e)?e:null!=e?[e]:[]),Np=hp(Fp,e=>{const t=new Map;return e.forEach(e=>{t.set(e,!0)}),t}),Hp=pp((e,t)=>e.itemMetaLookup[t]?.selectable??!0),Vp={selectedItemsRaw:pp(e=>e.selectedItems),selectedItems:Fp,selectedItemsMap:Np,enabled:pp(e=>!e.disableSelection),isMultiSelectEnabled:pp(e=>e.multiSelect),isCheckboxSelectionEnabled:pp(e=>e.checkboxSelection),propagationRules:pp(e=>e.selectionPropagation),isItemSelected:pp(Np,(e,t)=>e.has(t)),isFeatureEnabledForItem:pp(Hp,e=>!e.disableSelection,(e,t,r)=>t&&e),canItemBeSelected:pp(Wp.isItemDisabled,Hp,e=>!e.disableSelection,(e,t,r,o)=>r&&!e&&t),isItemSelectable:Hp},Qp=pp((e,t)=>{if(Vp.isItemSelected(e,t))return"checked";let r=!1,o=!1;const n=i=>{i!==t&&(Vp.isItemSelected(e,i)?r=!0:o=!0),Wp.itemOrderedChildrenIds(e,i).forEach(n)};n(t);return Vp.propagationRules(e).parents?r&&o?"indeterminate":r&&!o?"checked":"empty":r?"indeterminate":"empty"}),jp=({props:e})=>{const{itemId:t}=e,{store:r}=Uu(),o=Ip(r,Vp.isCheckboxSelectionEnabled),n=Ip(r,Vp.isFeatureEnabledForItem,t),i=Ip(r,Vp.canItemBeSelected,t),a=Ip(r,Qp,t);return{propsEnhancers:{root:()=>{let e;return e="checked"===a||("indeterminate"===a?"mixed":!i&&void 0),{"aria-checked":e}},checkbox:({externalEventHandlers:e,interactions:l})=>({tabIndex:-1,onChange:o=>{e.onChange?.(o),o.defaultMuiPrevented||Vp.canItemBeSelected(r.state,t)&&l.handleCheckboxSelection(o)},visible:o&&n,disabled:!i,checked:"checked"===a,indeterminate:"indeterminate"===a})}}},Gp=hp(e=>e.expandedItems,e=>{const t=new Map;return e.forEach(e=>{t.set(e,!0)}),t}),Up={expandedItemsRaw:pp(e=>e.expandedItems),expandedItemsMap:Gp,flatList:hp(Wp.itemOrderedChildrenIdsLookup,Gp,(e,t)=>(e[Ep]??[]).flatMap(function r(o){if(!t.has(o))return[o];const n=[o],i=e[o]||[];for(const e of i)n.push(...r(e));return n})),triggerSlot:pp(e=>e.expansionTrigger),isItemExpanded:pp(Gp,(e,t)=>e.has(t)),isItemExpandable:pp(Wp.itemMeta,(e,t)=>e?.expandable??!1)},Xp=(e,t)=>{let r=t.length-1;for(;r>=0&&!Wp.canItemBeFocused(e,t[r]);)r-=1;if(-1!==r)return t[r]},Kp=(e,t)=>{const r=Wp.itemMeta(e,t);if(!r)return null;const o=Wp.itemOrderedChildrenIds(e,r.parentId),n=Wp.itemIndex(e,t);if(0===n)return r.parentId;let i=n-1;for(;!Wp.canItemBeFocused(e,o[i])&&i>=0;)i-=1;if(-1===i)return null==r.parentId?null:Kp(e,r.parentId);let a=o[i],l=Xp(e,Wp.itemOrderedChildrenIds(e,a));for(;Up.isItemExpanded(e,a)&&null!=l;)a=l,l=Xp(e,Wp.itemOrderedChildrenIds(e,a));return a},qp=(e,t)=>{if(Up.isItemExpanded(e,t)){const r=Wp.itemOrderedChildrenIds(e,t).find(t=>Wp.canItemBeFocused(e,t));if(null!=r)return r}let r=Wp.itemMeta(e,t);for(;null!=r;){const t=Wp.itemOrderedChildrenIds(e,r.parentId),o=Wp.itemIndex(e,r.id);if(o<t.length-1){let r=o+1;for(;!Wp.canItemBeFocused(e,t[r])&&r<t.length-1;)r+=1;if(Wp.canItemBeFocused(e,t[r]))return t[r]}r=Wp.itemMeta(e,r.parentId)}return null},Jp=e=>{let t=null;for(;null==t||Up.isItemExpanded(e,t);){const r=Wp.itemOrderedChildrenIds(e,t),o=Xp(e,r);if(null==o)return t;t=o}return t},Yp=e=>Wp.itemOrderedChildrenIds(e,null).find(t=>Wp.canItemBeFocused(e,t)),Zp=(e,t,r)=>{if(t===r)return[t,r];const o=Wp.itemMeta(e,t),n=Wp.itemMeta(e,r);if(!o||!n)return[t,r];if(o.parentId===n.id||n.parentId===o.id)return n.parentId===o.id?[o.id,n.id]:[n.id,o.id];const i=[o.id],a=[n.id];let l=o.parentId,s=n.parentId,d=-1!==a.indexOf(l),c=-1!==i.indexOf(s),u=!0,p=!0;for(;!c&&!d;)u&&(i.push(l),d=-1!==a.indexOf(l),u=null!==l,!d&&u&&(l=Wp.itemParentId(e,l))),p&&!d&&(a.push(s),c=-1!==i.indexOf(s),p=null!==s,!c&&p&&(s=Wp.itemParentId(e,s)));const h=d?l:s,m=Wp.itemOrderedChildrenIds(e,h),f=i[i.indexOf(h)-1],g=a[a.indexOf(h)-1];return m.indexOf(f)<m.indexOf(g)?[t,r]:[r,t]},$p=(e,t)=>t!==e.closest('*[role="treeitem"]');class _p{lastSelectedItem=null;lastSelectedRange={};constructor(e){this.store=e,e.itemPluginManager.register(jp,null)}setSelectedItems=(e,t,r)=>{const{selectionPropagation:o=ju,selectedItems:n,onItemSelectionToggle:i,onSelectedItemsChange:a}=this.store.parameters,l=Vp.selectedItemsRaw(this.store.state);let s;const d=Vp.isMultiSelectEnabled(this.store.state);if(s=d&&(o.descendants||o.parents)?function({store:e,selectionPropagation:t,newModel:r,oldModel:o,additionalItemsToPropagate:n}){if(!t.descendants&&!t.parents)return r;let i=!1;const a=th(r),l=eh({store:e,newModel:r,oldModel:o});return n?.forEach(e=>{a[e]?l.added.includes(e)||l.added.push(e):l.removed.includes(e)||l.removed.push(e)}),l.added.forEach(r=>{if(t.descendants){const t=o=>{o!==r&&(i=!0,a[o]=!0),Wp.itemOrderedChildrenIds(e.state,o).forEach(t)};t(r)}if(t.parents){const t=r=>{if(!a[r])return!1;return Wp.itemOrderedChildrenIds(e.state,r).every(t)},o=r=>{const n=Wp.itemParentId(e.state,r);if(null==n)return;Wp.itemOrderedChildrenIds(e.state,n).every(t)&&(i=!0,a[n]=!0,o(n))};o(r)}}),l.removed.forEach(r=>{if(t.parents){let t=Wp.itemParentId(e.state,r);for(;null!=t;)a[t]&&(i=!0,delete a[t]),t=Wp.itemParentId(e.state,t)}if(t.descendants){const t=o=>{o!==r&&(i=!0,delete a[o]),Wp.itemOrderedChildrenIds(e.state,o).forEach(t)};t(r)}}),i?Object.keys(a):r}({store:this.store,selectionPropagation:o,newModel:t,oldModel:l,additionalItemsToPropagate:r}):t,i)if(d){const t=eh({store:this.store,newModel:s,oldModel:l});i&&(t.added.forEach(t=>{i(e,t,!0)}),t.removed.forEach(t=>{i(e,t,!1)}))}else s!==l&&(null!=l&&i(e,l,!1),null!=s&&i(e,s,!0));void 0===n&&this.store.set("selectedItems",s),a?.(e,s)};selectRange=(e,[t,r])=>{if(!Vp.isMultiSelectEnabled(this.store.state))return;let o=Vp.selectedItems(this.store.state).slice();Object.keys(this.lastSelectedRange).length>0&&(o=o.filter(e=>!this.lastSelectedRange[e]));const n=th(o),i=((e,t,r)=>{const o=t=>{if(Up.isItemExpandable(e,t)&&Up.isItemExpanded(e,t))return Wp.itemOrderedChildrenIds(e,t)[0];let r=Wp.itemMeta(e,t);for(;null!=r;){const t=Wp.itemOrderedChildrenIds(e,r.parentId),o=Wp.itemIndex(e,r.id);if(o<t.length-1)return t[o+1];r=r.parentId?Wp.itemMeta(e,r.parentId):null}throw new Error("Invalid range")},[n,i]=Zp(e,t,r),a=[n];let l=n;for(;l!==i;)l=o(l),Wp.isItemDisabled(e,l)||a.push(l);return a})(this.store.state,t,r).filter(e=>Vp.isItemSelectable(this.store.state,e)),a=i.filter(e=>!n[e]);o=o.concat(a),this.setSelectedItems(e,o),this.lastSelectedRange=th(i)};buildPublicAPI=()=>({setItemSelection:this.setItemSelection});setItemSelection=({itemId:e,event:t=null,keepExistingSelection:r=!1,shouldBeSelected:o})=>{if(!Vp.enabled(this.store.state))return;let n;const i=Vp.isMultiSelectEnabled(this.store.state);if(r){const t=Vp.selectedItems(this.store.state),r=Vp.isItemSelected(this.store.state,e);n=!r||!1!==o&&null!=o?r||!0!==o&&null!=o?t:[e].concat(t):t.filter(t=>t!==e)}else n=!1===o||null==o&&Vp.isItemSelected(this.store.state,e)?i?[]:null:i?[e]:e;this.setSelectedItems(t,n,[e]),this.lastSelectedItem=e,this.lastSelectedRange={}};selectAllNavigableItems=e=>{if(!Vp.isMultiSelectEnabled(this.store.state))return;const t=(e=>{let t=Yp(e);const r=[];for(;null!=t;)r.push(t),t=qp(e,t);return r})(this.store.state);this.setSelectedItems(e,t),this.lastSelectedRange=th(t)};expandSelectionRange=(e,t)=>{if(null!=this.lastSelectedItem){const[r,o]=Zp(this.store.state,t,this.lastSelectedItem);this.selectRange(e,[r,o])}};selectRangeFromStartToItem=(e,t)=>{this.selectRange(e,[Yp(this.store.state),t])};selectRangeFromItemToEnd=(e,t)=>{this.selectRange(e,[t,Jp(this.store.state)])};selectItemFromArrowNavigation=(e,t,r)=>{if(!Vp.isMultiSelectEnabled(this.store.state))return;let o=Vp.selectedItems(this.store.state).slice();0===Object.keys(this.lastSelectedRange).length?(o.push(r),this.lastSelectedRange={[t]:!0,[r]:!0}):(this.lastSelectedRange[t]||(this.lastSelectedRange={}),this.lastSelectedRange[r]?(o=o.filter(e=>e!==t),delete this.lastSelectedRange[t]):(o.push(r),this.lastSelectedRange[r]=!0)),this.setSelectedItems(e,o)}}function eh({store:e,oldModel:t,newModel:r}){const o=new Map;return r.forEach(e=>{o.set(e,!0)}),{added:r.filter(t=>!Vp.isItemSelected(e.state,t)),removed:t.filter(e=>!o.has(e))}}function th(e){const t={};return e.forEach(e=>{t[e]=!0}),t}const rh=e.createContext(null);function oh(t){const{children:r,itemId:o=null,idAttribute:n}=t,{store:i,rootRef:a}=Uu(),l=e.useRef(new Map);e.useEffect(()=>{if(!a.current)return;const e=Wp.itemOrderedChildrenIds(i.state,o??null)??[],t=(n??a.current.id).replace(/["\\]/g,"\\$&");if(null!=o){const e=a.current.querySelector(`*[id="${t}"][role="treeitem"]`);if(e&&"false"===e.getAttribute("aria-expanded"))return}const r=a.current.querySelectorAll(`${null==o?"":`*[id="${t}"] `}[role="treeitem"]:not(*[id="${t}"] [role="treeitem"] [role="treeitem"])`),s=Array.from(r).map(e=>l.current.get(e.id)),d=s.length!==e.length||s.some((t,r)=>t!==e[r]);d&&i.jsxItems.setJSXItemsOrderedChildrenIds(o??null,s)});const s=e.useMemo(()=>({registerChild:(e,t)=>l.current.set(e,t),unregisterChild:e=>l.current.delete(e),parentId:o}),[o]);return de(rh.Provider,{value:s,children:r})}"production"!==process.env.NODE_ENV&&(rh.displayName="TreeViewChildrenItemContext"),"production"!==process.env.NODE_ENV&&(oh.propTypes={children:Ni.node,id:Ni.string});const nh=e.createContext(()=>-1);"production"!==process.env.NODE_ENV&&(nh.displayName="TreeViewItemDepthContext");const ih="undefined"!=typeof document?e.useLayoutEffect:()=>{},ah=[];const lh=e.createContext();"production"!==process.env.NODE_ENV&&(Ni.node,Ni.bool);function sh(t,r){const o=e.useContext(lh)??!1,n=Bu(()=>new t(Su({},r,{isRtl:o}))).current;var i;return ih(()=>n.updateStateFromParameters(Su({},r,{isRtl:o})),[n,o,r]),i=n.disposeEffect,e.useEffect(i,ah),n}class dh{maxListeners=20;warnOnce=!1;events={};on(e,t,r={}){let o=this.events[e];if(o||(o={highPriority:new Map,regular:new Map},this.events[e]=o),r.isFirst?o.highPriority.set(t,!0):o.regular.set(t,!0),"production"!==process.env.NODE_ENV){const t=o.highPriority.size+o.regular.size;t>this.maxListeners&&!this.warnOnce&&(this.warnOnce=!0,console.warn([`Possible EventEmitter memory leak detected. ${t} ${e} listeners added.`].join("\n")))}}removeListener(e,t){this.events[e]&&(this.events[e].regular.delete(t),this.events[e].highPriority.delete(t))}removeAllListeners(){this.events={}}emit(e,...t){const r=this.events[e];if(!r)return;const o=Array.from(r.highPriority.keys()),n=Array.from(r.regular.keys());for(let e=o.length-1;e>=0;e-=1){const n=o[e];r.highPriority.has(n)&&n.apply(this,t)}for(let e=0;e<n.length;e+=1){const o=n[e];r.regular.has(o)&&o.apply(this,t)}}once(e,t){const r=this;this.on(e,function o(...n){r.removeListener(e,o),t.apply(r,n)})}}const ch=({isItemEditable:e,expansionTrigger:t})=>t||(e?"iconContainer":"content");function uh(e){return{disabledItemsFocusable:e.disabledItemsFocusable??!1,domStructure:"nested",itemChildrenIndentation:e.itemChildrenIndentation??"12px",providedTreeId:e.id,expansionTrigger:ch({isItemEditable:e.isItemEditable,expansionTrigger:e.expansionTrigger}),disableSelection:e.disableSelection??!1,multiSelect:e.multiSelect??!1,checkboxSelection:e.checkboxSelection??!1,selectionPropagation:e.selectionPropagation??ju}}function ph(e,t,r){return void 0!==e?e:void 0!==t?t:r}let hh=0;class mh{timeoutIds=(()=>new Map)();intervalIds=(()=>new Map)();startTimeout=(e,t,r)=>{this.clearTimeout(e);const o=setTimeout(()=>{this.timeoutIds.delete(e),r()},t);this.timeoutIds.set(e,o)};startInterval=(e,t,r)=>{this.clearTimeout(e);const o=setInterval(r,t);this.intervalIds.set(e,o)};clearTimeout=e=>{const t=this.timeoutIds.get(e);null!=t&&(clearTimeout(t),this.timeoutIds.delete(e))};clearInterval=e=>{const t=this.intervalIds.get(e);null!=t&&(clearInterval(t),this.intervalIds.delete(e))};clearAll=()=>{this.timeoutIds.forEach(clearTimeout),this.timeoutIds.clear(),this.intervalIds.forEach(clearInterval),this.intervalIds.clear()}}class fh{constructor(e){this.store=e}setExpandedItems=(e,t)=>{void 0===this.store.parameters.expandedItems&&this.store.set("expandedItems",t),this.store.parameters.onExpandedItemsChange?.(e,t)};isItemExpanded=e=>Up.isItemExpanded(this.store.state,e);buildPublicAPI=()=>({isItemExpanded:this.isItemExpanded,setItemExpansion:this.setItemExpansion});setItemExpansion=({itemId:e,event:t=null,shouldBeExpanded:r})=>{const o=Up.isItemExpanded(this.store.state,e),n=r??!o;if(o===n)return;const i={isExpansionPrevented:!1,shouldBeExpanded:n,itemId:e};this.store.publishEvent("beforeItemToggleExpansion",i,t),i.isExpansionPrevented||this.applyItemExpansion({itemId:e,event:t,shouldBeExpanded:n})};applyItemExpansion=({itemId:e,event:t,shouldBeExpanded:r})=>{const o=Up.expandedItemsRaw(this.store.state);let n;n=r?[e].concat(o):o.filter(t=>t!==e),this.store.parameters.onItemExpansionToggle?.(t,e,r),this.setExpandedItems(t,n)};expandAllSiblings=(e,t)=>{const r=Wp.itemMeta(this.store.state,t);if(null==r)return;const o=Wp.itemOrderedChildrenIds(this.store.state,r.parentId).filter(e=>Up.isItemExpandable(this.store.state,e)&&!Up.isItemExpanded(this.store.state,e)),n=Up.expandedItemsRaw(this.store.state).concat(o);o.length>0&&(this.store.parameters.onItemExpansionToggle&&o.forEach(t=>{this.store.parameters.onItemExpansionToggle(e,t,!0)}),this.setExpandedItems(e,n))};addExpandableItems=e=>{const t=Su({},this.store.state.itemMetaLookup);for(const r of e)t[r]=Su({},t[r],{expandable:!0});this.store.set("itemMetaLookup",t)}}const gh={isItemEditable:pp(e=>e.isItemEditable,Wp.itemModel,(e,t,r)=>!(!t||null==e)&&("boolean"==typeof e?e:e(t))),isItemBeingEdited:pp((e,t)=>null!=t&&e.editedItemId===t),isAnyItemBeingEdited:pp(e=>!!e.editedItemId)};class xh{typeaheadQuery="";constructor(e){this.store=e,this.labelMap=bh(Wp.itemMetaLookup(this.store.state)),this.store.registerStoreEffect(Wp.itemMetaLookup,(e,t)=>{this.store.shouldIgnoreItemsStateUpdate()||(this.labelMap=bh(t))})}canToggleItemSelection=e=>Vp.canItemBeSelected(this.store.state,e);canToggleItemExpansion=e=>!Wp.isItemDisabled(this.store.state,e)&&Up.isItemExpandable(this.store.state,e);getFirstItemMatchingTypeaheadQuery=(e,t)=>{const r=e=>{const t=qp(this.store.state,e);return null===t?Yp(this.store.state):t},o=t=>{let o=null;const n={};let i=t.length>1?e:r(e);for(;null==o&&!n[i];){const e=this.labelMap[i];e?.startsWith(t)?o=i:(n[i]=!0,i=r(i))}return o},n=t.toLowerCase(),i=`${this.typeaheadQuery}${n}`,a=o(i);if(null!=a)return this.typeaheadQuery=i,a;const l=o(n);return null!=l?(this.typeaheadQuery=n,l):(this.typeaheadQuery="",null)};updateLabelMap=e=>{this.labelMap=e(this.labelMap)};handleItemKeyDown=async(e,t)=>{if(e.defaultMuiPrevented)return;if(e.altKey||$p(e.target,e.currentTarget))return;const r=e.ctrlKey||e.metaKey,o=e.key,n=Vp.isMultiSelectEnabled(this.store.state);switch(!0){case" "===o&&this.canToggleItemSelection(t):e.preventDefault(),n&&e.shiftKey?this.store.selection.expandSelectionRange(e,t):this.store.selection.setItemSelection({event:e,itemId:t,keepExistingSelection:n,shouldBeSelected:void 0});break;case"Enter"===o:this.store.labelEditing?.setEditedItem&&gh.isItemEditable(this.store.state,t)&&!gh.isItemBeingEdited(this.store.state,t)?this.store.labelEditing.setEditedItem(t):this.canToggleItemExpansion(t)?(this.store.expansion.setItemExpansion({event:e,itemId:t}),e.preventDefault()):this.canToggleItemSelection(t)&&(n?(e.preventDefault(),this.store.selection.setItemSelection({event:e,itemId:t,keepExistingSelection:!0})):Vp.isItemSelected(this.store.state,t)||(this.store.selection.setItemSelection({event:e,itemId:t}),e.preventDefault()));break;case"ArrowDown"===o:{const r=qp(this.store.state,t);r&&(e.preventDefault(),this.store.focus.focusItem(e,r),n&&e.shiftKey&&this.canToggleItemSelection(r)&&this.store.selection.selectItemFromArrowNavigation(e,t,r));break}case"ArrowUp"===o:{const r=Kp(this.store.state,t);r&&(e.preventDefault(),this.store.focus.focusItem(e,r),n&&e.shiftKey&&this.canToggleItemSelection(r)&&this.store.selection.selectItemFromArrowNavigation(e,t,r));break}case"ArrowRight"===o&&!this.store.parameters.isRtl||"ArrowLeft"===o&&this.store.parameters.isRtl:if(r)return;if(Up.isItemExpanded(this.store.state,t)){const r=qp(this.store.state,t);r&&(this.store.focus.focusItem(e,r),e.preventDefault())}else this.canToggleItemExpansion(t)&&(this.store.expansion.setItemExpansion({event:e,itemId:t}),e.preventDefault());break;case"ArrowLeft"===o&&!this.store.parameters.isRtl||"ArrowRight"===o&&this.store.parameters.isRtl:if(r)return;if(this.canToggleItemExpansion(t)&&Up.isItemExpanded(this.store.state,t))this.store.expansion.setItemExpansion({event:e,itemId:t}),e.preventDefault();else{const r=Wp.itemParentId(this.store.state,t);r&&(this.store.focus.focusItem(e,r),e.preventDefault())}break;case"Home"===o:this.canToggleItemSelection(t)&&n&&r&&e.shiftKey?this.store.selection.selectRangeFromStartToItem(e,t):this.store.focus.focusItem(e,Yp(this.store.state)),e.preventDefault();break;case"End"===o:this.canToggleItemSelection(t)&&n&&r&&e.shiftKey?this.store.selection.selectRangeFromItemToEnd(e,t):this.store.focus.focusItem(e,Jp(this.store.state)),e.preventDefault();break;case"*"===o:this.store.expansion.expandAllSiblings(e,t),e.preventDefault();break;case"A"===String.fromCharCode(e.keyCode)&&r&&n&&Vp.enabled(this.store.state):this.store.selection.selectAllNavigableItems(e),e.preventDefault();break;case!(r||e.shiftKey||(i=o,!i||1!==i.length||!i.match(/\S/))):{this.store.timeoutManager.clearTimeout("typeahead");const r=this.getFirstItemMatchingTypeaheadQuery(t,o);null!=r?(this.store.focus.focusItem(e,r),e.preventDefault()):this.typeaheadQuery="",this.store.timeoutManager.startTimeout("typeahead",500,()=>{this.typeaheadQuery=""});break}}var i}}function bh(e){const t={};return Object.values(e).forEach(e=>{t[e.id]=e.label.toLowerCase()}),t}const vh=hp(Vp.selectedItems,Up.expandedItemsMap,Wp.itemMetaLookup,Wp.disabledItemFocusable,e=>Wp.itemOrderedChildrenIds(e,null),(e,t,r,o,n)=>{const i=e.find(e=>{if(!o&&Op(r,e))return!1;const n=r[e];return n&&(null==n.parentId||t.has(n.parentId))});if(null!=i)return i;const a=n.find(e=>o||!Op(r,e));return null!=a?a:null}),yh={defaultFocusableItemId:vh,isItemTheDefaultFocusableItem:pp(vh,(e,t)=>e===t),focusedItemId:pp(e=>e.focusedItemId),isItemFocused:pp((e,t)=>e.focusedItemId===t)};class Sh{constructor(e){this.store=e;let t=e.state;this.store.subscribe(e=>{if(e.itemMetaLookup===t.itemMetaLookup)return void(t=e);const r=yh.focusedItemId(e);if(null==r||Wp.itemMeta(e,r))return void(t=e);const o=t=>null!=t&&Wp.itemMeta(e,t)?t:null,n=o(qp(t,r))??o(Kp(t,r))??Yp(e);null==n?this.setFocusedItemId(null):this.applyItemFocus(null,n),t=e})}setFocusedItemId=e=>{yh.focusedItemId(this.store.state)!==e&&this.store.set("focusedItemId",e)};applyItemFocus=(e,t)=>{this.store.items.getItemDOMElement(t)?.focus(),this.setFocusedItemId(t),this.store.parameters.onItemFocus?.(e,t)};buildPublicAPI=()=>({focusItem:this.focusItem});focusItem=(e,t)=>{const r=Wp.itemMeta(this.store.state,t);r&&(null==r.parentId||Up.isItemExpanded(this.store.state,r.parentId))&&this.applyItemFocus(e,t)};removeFocusedItem=()=>{const e=yh.focusedItemId(this.store.state);if(null==e)return;if(Wp.itemMeta(this.store.state,e)){const t=this.store.items.getItemDOMElement(e);t&&t.blur()}this.setFocusedItemId(null)};handleRootFocus=e=>{if(e.defaultMuiPrevented)return;const t=yh.defaultFocusableItemId(this.store.state);e.target===e.currentTarget&&null!=t&&this.applyItemFocus(e,t)};handleRootBlur=e=>{e.defaultMuiPrevented||this.setFocusedItemId(null)}}class kh{itemPlugins=[];itemWrappers=[];register=(e,t)=>{this.itemPlugins.push(e),t&&this.itemWrappers.push(t)};listPlugins=()=>this.itemPlugins;listWrappers=()=>this.itemWrappers}class Bh extends Ap{initialParameters=null;eventManager=(()=>new dh)();timeoutManager=(()=>new mh)();itemPluginManager=(()=>new kh)();constructor(e,t,r){const o=function(e){return Su({treeId:void 0,focusedItemId:null},uh(e),Dp.buildItemsStateIfNeeded(e),{expandedItems:ph(e.expandedItems,e.defaultExpandedItems,[]),selectedItems:ph(e.selectedItems,e.defaultSelectedItems,e.multiSelect?Qu:null)})}(e);super(r.getInitialState(o,e)),this.parameters=e,this.instanceName=t,this.mapper=r,this.items=new Dp(this),this.focus=new Sh(this),this.expansion=new fh(this),this.selection=new _p(this),this.keyboardNavigation=new xh(this),"production"!==process.env.NODE_ENV&&(this.initialParameters=e)}buildPublicAPI(){return Su({},this.items.buildPublicAPI(),this.focus.buildPublicAPI(),this.expansion.buildPublicAPI(),this.selection.buildPublicAPI())}updateStateFromParameters(e){const t=(t,r,o)=>{if(void 0!==e[r]&&(t[r]=e[r]),"production"!==process.env.NODE_ENV){const t=e[o],n=void 0!==e[r],i=this.initialParameters?.[o],a=void 0!==this.initialParameters?.[r];a!==n?Lu([`MUI X Tree View: A component is changing the ${a?"":"un"}controlled ${r} state of ${this.instanceName} to be ${a?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${r} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"],"error"):JSON.stringify(i)!==JSON.stringify(t)&&Lu([`MUI X Tree View: A component is changing the default ${r} state of an uncontrolled ${this.instanceName} after being initialized. `,`To suppress this warning opt to use a controlled ${this.instanceName}.`],"error")}},r=uh(e);t(r,"expandedItems","defaultExpandedItems"),t(r,"selectedItems","defaultSelectedItems"),this.state.providedTreeId===e.id&&void 0!==this.state.treeId||(r.treeId=(hh+=1,`mui-tree-view-${hh}`)),!this.mapper.shouldIgnoreItemsStateUpdate(e)&&Dp.shouldRebuildItemsState(e,this.parameters)&&Object.assign(r,Dp.buildItemsStateIfNeeded(e));const o=this.mapper.updateStateFromParameters(r,e,t);this.update(o),this.parameters=e}disposeEffect=()=>this.timeoutManager.clearAll;shouldIgnoreItemsStateUpdate=()=>this.mapper.shouldIgnoreItemsStateUpdate(this.parameters);registerStoreEffect=(e,t)=>{let r=e(this.state);this.subscribe(o=>{const n=e(o);n!==r&&(t(r,n),r=n)})};publishEvent=(e,t,r)=>{(function(e){return void 0!==e?.isPropagationStopped})(r)&&r.isPropagationStopped()||this.eventManager.emit(e,t,r)};subscribeEvent=(e,t)=>{this.eventManager.on(e,t)}}const wh={isEmpty:pp(e=>null==e.lazyLoadedItems||0===Object.keys(e.lazyLoadedItems.loading).length&&0===Object.keys(e.lazyLoadedItems.errors).length),isItemLoading:pp((e,t)=>e.lazyLoadedItems?.loading[t??Ep]??!1),itemHasError:pp((e,t)=>!!e.lazyLoadedItems?.errors[t??Ep]),itemError:pp((e,t)=>e.lazyLoadedItems?.errors[t??Ep])},Ch=e=>Array.isArray(e)?e.length>0&&e.some(Ch):Boolean(e),Th=({props:t,rootRef:r,contentRef:o})=>{const{store:n}=Uu(),{children:i,disabled:a=!1,disableSelection:l=!1,label:s,itemId:d,id:c}=t,u=e.useContext(rh);if(null==u)throw new Error(["MUI X: Could not find the Tree View Children Item context.","It looks like you rendered your component outside of a SimpleTreeView parent component.","This can also happen if you are bundling multiple versions of the Tree View."].join("\n"));const{registerChild:p,unregisterChild:h,parentId:m}=u,f=Ch(i),g=e.useRef(null),x=wu(g,o),b=Ip(n,Rp.treeItemIdAttribute,d,c),v=e.useRef(!0),y=Bu(Symbol);return ih(()=>(p(b,d),()=>{h(b),h(b)}),[n,p,h,b,d]),ih(()=>(v.current=!0,()=>{v.current=!1}),[]),ih(()=>{const e=n.jsxItems.upsertJSXItem({id:d,idAttribute:c,parentId:m,expandable:f,disabled:a,selectable:!l},y.current);return()=>{v.current||e()}},[n,m,d,f,a,l,c,y]),e.useEffect(()=>{if(s)return n.jsxItems.mapLabelFromJSX(d,(g.current?.textContent??"").toLowerCase())},[n,d,s]),{contentRef:x,rootRef:r}},Ih=({children:t,itemId:r,idAttribute:o})=>{const n=e.useContext(nh);return de(oh,{itemId:r,idAttribute:o,children:de(nh.Provider,{value:n+1,children:t})})};"production"!==process.env.NODE_ENV&&(Ih.displayName="jsxItemsitemWrapper");class Ah{itemOwners=(()=>new Map)();constructor(e){this.store=e,e.itemPluginManager.register(Th,Ih)}upsertJSXItem=(e,t)=>{const r=this.itemOwners.get(e.id);if(null!=r&&r!==t)throw new Error(["MUI X: The Tree View component requires all items to have a unique `id` property.","Alternatively, you can use the `getItemId` prop to specify a custom id for each item.",`Two items were provided with the same id in the \`items\` prop: "${e.id}"`].join("\n"));this.itemOwners.set(e.id,t);const o=Wp.itemMeta(this.store.state,e.id);if(null!=o){let t=!1;for(const r of Object.keys(e))if(o[r]!==e[r]){t=!0;break}t&&this.store.update({itemMetaLookup:Su({},this.store.state.itemMetaLookup,{[e.id]:Su({},o,e)})})}else this.store.update({itemMetaLookup:Su({},this.store.state.itemMetaLookup,{[e.id]:e}),itemModelLookup:Su({},this.store.state.itemModelLookup,{[e.id]:{id:e.id,label:e.label??""}})});return()=>{this.itemOwners.delete(e.id);const t=Su({},this.store.state.itemMetaLookup),r=Su({},this.store.state.itemModelLookup);delete t[e.id],delete r[e.id],this.store.update({itemMetaLookup:t,itemModelLookup:r})}};mapLabelFromJSX=(e,t)=>(this.store.keyboardNavigation.updateLabelMap(r=>(r[e]=t,r)),()=>{this.store.keyboardNavigation.updateLabelMap(t=>{const r=Su({},t);return delete r[e],r})});setJSXItemsOrderedChildrenIds=(e,t)=>{const r=e??Ep;this.store.update({itemOrderedChildrenIdsLookup:Su({},this.store.state.itemOrderedChildrenIdsLookup,{[r]:t}),itemChildrenIndexesLookup:Su({},this.store.state.itemChildrenIndexesLookup,{[r]:Pp(t)})})}}const zh={getInitialState:e=>e,updateStateFromParameters:e=>e,shouldIgnoreItemsStateUpdate:()=>!0};class Rh extends Bh{jsxItems=(()=>new Ah(this))();constructor(e){super(Su({},e,{items:Qu}),"SimpleTreeView",zh)}updateStateFromParameters(e){super.updateStateFromParameters(Su({},e,{items:Qu}))}}const Eh=Mu(),Ph=or("ul",{name:"MuiSimpleTreeView",slot:"Root"})({padding:0,margin:0,listStyle:"none",outline:0,position:"relative"}),Oh=e.forwardRef(function(t,r){const o=Eh({props:t,name:"MuiSimpleTreeView"});"production"!==process.env.NODE_ENV&&null!=o.items&&Lu(["MUI X: The Simple Tree View component does not support the `items` prop.","If you want to add items, you need to pass them as JSX children.","Check the documentation for more details: https://mui.com/x/react-tree-view/simple-tree-view/items/."]);const{slots:n,slotProps:i,apiRef:a,parameters:l,forwardedProps:s}=function(t){const{apiRef:r,slots:o,slotProps:n,disabledItemsFocusable:i,onItemClick:a,itemChildrenIndentation:l,id:s,expandedItems:d,defaultExpandedItems:c,onExpandedItemsChange:u,onItemExpansionToggle:p,expansionTrigger:h,disableSelection:m,selectedItems:f,defaultSelectedItems:g,multiSelect:x,checkboxSelection:b,selectionPropagation:v,onSelectedItemsChange:y,onItemSelectionToggle:S,onItemFocus:k}=t,B=Ju(t,Yu);return{apiRef:r,slots:o,slotProps:n,parameters:e.useMemo(()=>({disabledItemsFocusable:i,onItemClick:a,itemChildrenIndentation:l,id:s,expandedItems:d,defaultExpandedItems:c,onExpandedItemsChange:u,onItemExpansionToggle:p,expansionTrigger:h,disableSelection:m,selectedItems:f,defaultSelectedItems:g,multiSelect:x,checkboxSelection:b,selectionPropagation:v,onSelectedItemsChange:y,onItemSelectionToggle:S,onItemFocus:k}),[i,a,l,s,d,c,u,p,h,m,f,g,x,b,v,y,S,k]),forwardedProps:B}}(o),d=sh(Rh,l),c=e.useRef(null),u=function(e,t,r){const o=Ip(e,Rp.treeId),n=Ip(e,Wp.itemChildrenIndentation),i=Ip(e,Vp.isMultiSelectEnabled);return a=>Su({ref:r,role:"tree",id:o,"aria-multiselectable":i},t,a,{style:Su({},t.style,{"--TreeView-itemChildrenIndentation":"number"==typeof n?`${n}px`:n}),onFocus:t=>{a.onFocus?.(t),e.focus.handleRootFocus(t)},onBlur:t=>{a.onBlur?.(t),e.focus.handleRootBlur(t)}})}(d,s,wu(r,c)),p=(t=>{const{classes:r}=t;return e.useMemo(()=>Tu({root:["root"],item:["item"],itemContent:["itemContent"],itemGroupTransition:["itemGroupTransition"],itemIconContainer:["itemIconContainer"],itemLabel:["itemLabel"],itemCheckbox:["itemCheckbox"]},Vu,r),[r])})(o),h=n?.root??Ph,m=Pu({elementType:h,externalSlotProps:i?.root,className:p.root,getSlotProps:u,ownerState:o});return de(qu,{store:d,classes:p,slots:n,slotProps:i,apiRef:a,rootRef:c,children:de(oh,{itemId:null,idAttribute:null,children:de(nh.Provider,{value:0,children:de(h,Su({},m))})})})});"production"!==process.env.NODE_ENV&&(Oh.displayName="SimpleTreeView"),"production"!==process.env.NODE_ENV&&(Oh.propTypes={apiRef:Ni.shape({current:Ni.shape({focusItem:Ni.func,getItem:Ni.func,getItemDOMElement:Ni.func,getItemOrderedChildrenIds:Ni.func,getItemTree:Ni.func,getParentId:Ni.func,isItemExpanded:Ni.func,setIsItemDisabled:Ni.func,setItemExpansion:Ni.func,setItemSelection:Ni.func})}),checkboxSelection:Ni.bool,children:Ni.node,classes:Ni.object,className:Ni.string,defaultExpandedItems:Ni.arrayOf(Ni.string),defaultSelectedItems:Ni.any,disabledItemsFocusable:Ni.bool,disableSelection:Ni.bool,expandedItems:Ni.arrayOf(Ni.string),expansionTrigger:Ni.oneOf(["content","iconContainer"]),id:Ni.string,itemChildrenIndentation:Ni.oneOfType([Ni.number,Ni.string]),multiSelect:Ni.bool,onExpandedItemsChange:Ni.func,onItemClick:Ni.func,onItemExpansionToggle:Ni.func,onItemFocus:Ni.func,onItemSelectionToggle:Ni.func,onSelectedItemsChange:Ni.func,selectedItems:Ni.any,selectionPropagation:Ni.shape({descendants:Ni.bool,parents:Ni.bool}),slotProps:Ni.object,slots:Ni.object,sx:Ni.oneOfType([Ni.arrayOf(Ni.oneOfType([Ni.func,Ni.object,Ni.bool])),Ni.func,Ni.object])});var Lh,Mh={exports:{}},Wh={};var Dh,Fh={};
33
33
  /**
34
34
  * @license React
35
35
  * react-is.development.js
@@ -38,5 +38,5 @@ object-assign
38
38
  *
39
39
  * This source code is licensed under the MIT license found in the
40
40
  * LICENSE file in the root directory of this source tree.
41
- */"production"===process.env.NODE_ENV?Ph.exports=function(){if(Eh)return Oh;Eh=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),n=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),c=Symbol.for("react.memo"),u=Symbol.for("react.lazy"),p=Symbol.for("react.view_transition"),h=Symbol.for("react.client.reference");function m(h){if("object"==typeof h&&null!==h){var m=h.$$typeof;switch(m){case e:switch(h=h.type){case r:case n:case o:case s:case d:case p:return h;default:switch(h=h&&h.$$typeof){case a:case l:case u:case c:case i:return h;default:return m}}case t:return m}}}return Oh.ContextConsumer=i,Oh.ContextProvider=a,Oh.Element=e,Oh.ForwardRef=l,Oh.Fragment=r,Oh.Lazy=u,Oh.Memo=c,Oh.Portal=t,Oh.Profiler=n,Oh.StrictMode=o,Oh.Suspense=s,Oh.SuspenseList=d,Oh.isContextConsumer=function(e){return m(e)===i},Oh.isContextProvider=function(e){return m(e)===a},Oh.isElement=function(t){return"object"==typeof t&&null!==t&&t.$$typeof===e},Oh.isForwardRef=function(e){return m(e)===l},Oh.isFragment=function(e){return m(e)===r},Oh.isLazy=function(e){return m(e)===u},Oh.isMemo=function(e){return m(e)===c},Oh.isPortal=function(e){return m(e)===t},Oh.isProfiler=function(e){return m(e)===n},Oh.isStrictMode=function(e){return m(e)===o},Oh.isSuspense=function(e){return m(e)===s},Oh.isSuspenseList=function(e){return m(e)===d},Oh.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===n||e===o||e===s||e===d||"object"==typeof e&&null!==e&&(e.$$typeof===u||e.$$typeof===c||e.$$typeof===a||e.$$typeof===i||e.$$typeof===l||e.$$typeof===h||void 0!==e.getModuleId)},Oh.typeOf=m,Oh}():Ph.exports=(Lh||(Lh=1,"production"!==process.env.NODE_ENV&&function(){function e(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:switch(e=e.type){case o:case i:case n:case d:case c:case h:return e;default:switch(e=e&&e.$$typeof){case l:case s:case p:case u:case a:return e;default:return m}}case r:return m}}}var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),a=Symbol.for("react.consumer"),l=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),h=Symbol.for("react.view_transition"),m=Symbol.for("react.client.reference");Mh.ContextConsumer=a,Mh.ContextProvider=l,Mh.Element=t,Mh.ForwardRef=s,Mh.Fragment=o,Mh.Lazy=p,Mh.Memo=u,Mh.Portal=r,Mh.Profiler=i,Mh.StrictMode=n,Mh.Suspense=d,Mh.SuspenseList=c,Mh.isContextConsumer=function(t){return e(t)===a},Mh.isContextProvider=function(t){return e(t)===l},Mh.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Mh.isForwardRef=function(t){return e(t)===s},Mh.isFragment=function(t){return e(t)===o},Mh.isLazy=function(t){return e(t)===p},Mh.isMemo=function(t){return e(t)===u},Mh.isPortal=function(t){return e(t)===r},Mh.isProfiler=function(t){return e(t)===i},Mh.isStrictMode=function(t){return e(t)===n},Mh.isSuspense=function(t){return e(t)===d},Mh.isSuspenseList=function(t){return e(t)===c},Mh.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===i||e===n||e===d||e===c||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===u||e.$$typeof===l||e.$$typeof===a||e.$$typeof===s||e.$$typeof===m||void 0!==e.getModuleId)},Mh.typeOf=e}()),Mh);var Wh=Ph.exports;function Dh(e){if("object"!=typeof e||null===e)return!1;const t=Object.getPrototypeOf(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)}function Fh(t){if(e.isValidElement(t)||Wh.isValidElementType(t)||!Dh(t))return t;const r={};return Object.keys(t).forEach(e=>{r[e]=Fh(t[e])}),r}function Nh(t,r,o={clone:!0}){const n=o.clone?{...t}:t;return Dh(t)&&Dh(r)&&Object.keys(r).forEach(i=>{e.isValidElement(r[i])||Wh.isValidElementType(r[i])?n[i]=r[i]:Dh(r[i])&&Object.prototype.hasOwnProperty.call(t,i)&&Dh(t[i])?n[i]=Nh(t[i],r[i],o):o.clone?n[i]=Dh(r[i])?Fh(r[i]):r[i]:n[i]=r[i]}),n}function Hh(e){if("string"!=typeof e)throw new Error("production"!==process.env.NODE_ENV?"MUI: `capitalize(string)` expects a string argument.":function(e,...t){const r=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(e=>r.searchParams.append("args[]",e)),`Minified MUI error #${e}; visit ${r} for the full message.`}(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Vh(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:o=5,...n}=e,i=(e=>{const t=Object.keys(e).map(t=>({key:t,val:e[t]}))||[];return t.sort((e,t)=>e.val-t.val),t.reduce((e,t)=>({...e,[t.key]:t.val}),{})})(t),a=Object.keys(i);function l(e){return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r})`}function s(e){return`@media (max-width:${("number"==typeof t[e]?t[e]:e)-o/100}${r})`}function d(e,n){const i=a.indexOf(n);return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r}) and (max-width:${(-1!==i&&"number"==typeof t[a[i]]?t[a[i]]:n)-o/100}${r})`}return{keys:a,values:i,up:l,down:s,between:d,only:function(e){return a.indexOf(e)+1<a.length?d(e,a[a.indexOf(e)+1]):l(e)},not:function(e){const t=a.indexOf(e);return 0===t?l(a[1]):t===a.length-1?s(a[t]):d(e,a[a.indexOf(e)+1]).replace("@media","@media not all and")},unit:r,...n}}function Qh(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(e=>e.startsWith("@container")).sort((e,t)=>{const r=/min-width:\s*([0-9.]+)/;return+(e.match(r)?.[1]||0)-+(t.match(r)?.[1]||0)});return r.length?r.reduce((e,r)=>{const o=t[r];return delete e[r],e[r]=o,e},{...t}):t}const jh={borderRadius:4},Gh="production"!==process.env.NODE_ENV?Di.oneOfType([Di.number,Di.string,Di.object,Di.array]):{};function Uh(e,t){return t?Nh(e,t,{clone:!1}):e}const Xh={xs:0,sm:600,md:900,lg:1200,xl:1536},Kh={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${Xh[e]}px)`},qh={containerQueries:e=>({up:t=>{let r="number"==typeof t?t:Xh[t]||t;return"number"==typeof r&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function Jh(e,t,r){const o=e.theme||{};if(Array.isArray(t)){const e=o.breakpoints||Kh;return t.reduce((o,n,i)=>(o[e.up(e.keys[i])]=r(t[i]),o),{})}if("object"==typeof t){const e=o.breakpoints||Kh;return Object.keys(t).reduce((n,i)=>{if(a=e.keys,"@"===(l=i)||l.startsWith("@")&&(a.some(e=>l.startsWith(`@${e}`))||l.match(/^@\d/))){const e=function(e,t){const r=t.match(/^@([^/]+)?\/?(.+)?$/);if(!r){if("production"!==process.env.NODE_ENV)throw new Error(`MUI: The provided shorthand (${t}) is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.\nFor example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`);return null}const[,o,n]=r,i=Number.isNaN(+o)?o||0:+o;return e.containerQueries(n).up(i)}(o.containerQueries?o:qh,i);e&&(n[e]=r(t[i],i))}else if(Object.keys(e.values||Xh).includes(i)){n[e.up(i)]=r(t[i],i)}else{const e=i;n[e]=t[e]}var a,l;return n},{})}return r(t)}function Yh(e,t){return e.reduce((e,t)=>{const r=e[t];return(!r||0===Object.keys(r).length)&&delete e[t],e},t)}function $h(e,t,r=!0){if(!t||"string"!=typeof t)return null;if(e&&e.vars&&r){const r=`vars.${t}`.split(".").reduce((e,t)=>e&&e[t]?e[t]:null,e);if(null!=r)return r}return t.split(".").reduce((e,t)=>e&&null!=e[t]?e[t]:null,e)}function Zh(e,t,r,o=r){let n;return n="function"==typeof e?e(r):Array.isArray(e)?e[r]||o:$h(e,r)||o,t&&(n=t(n,o,e)),n}function _h(e){const{prop:t,cssProperty:r=e.prop,themeKey:o,transform:n}=e,i=e=>{if(null==e[t])return null;const i=e[t],a=$h(e.theme,o)||{};return Jh(e,i,e=>{let o=Zh(a,n,e);return e===o&&"string"==typeof e&&(o=Zh(a,n,`${t}${"default"===e?"":Hh(e)}`,e)),!1===r?o:{[r]:o}})};return i.propTypes="production"!==process.env.NODE_ENV?{[t]:Gh}:{},i.filterProps=[t],i}const em={m:"margin",p:"padding"},tm={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},rm={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},om=function(e){const t={};return r=>(void 0===t[r]&&(t[r]=e(r)),t[r])}(e=>{if(e.length>2){if(!rm[e])return[e];e=rm[e]}const[t,r]=e.split(""),o=em[t],n=tm[r]||"";return Array.isArray(n)?n.map(e=>o+e):[o+n]}),nm=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],im=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],am=[...nm,...im];function lm(e,t,r,o){const n=$h(e,t,!0)??r;return"number"==typeof n||"string"==typeof n?e=>"string"==typeof e?e:("production"!==process.env.NODE_ENV&&"number"!=typeof e&&console.error(`MUI: Expected ${o} argument to be a number or a string, got ${e}.`),"string"==typeof n?n.startsWith("var(")&&0===e?0:n.startsWith("var(")&&1===e?n:`calc(${e} * ${n})`:n*e):Array.isArray(n)?e=>{if("string"==typeof e)return e;const r=Math.abs(e);"production"!==process.env.NODE_ENV&&(Number.isInteger(r)?r>n.length-1&&console.error([`MUI: The value provided (${r}) overflows.`,`The supported values are: ${JSON.stringify(n)}.`,`${r} > ${n.length-1}, you need to add the missing values.`].join("\n")):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join("\n")));const o=n[r];return e>=0?o:"number"==typeof o?-o:"string"==typeof o&&o.startsWith("var(")?`calc(-1 * ${o})`:`-${o}`}:"function"==typeof n?n:("production"!==process.env.NODE_ENV&&console.error([`MUI: The \`theme.${t}\` value (${n}) is invalid.`,"It should be a number, an array or a function."].join("\n")),()=>{})}function sm(e){return lm(e,"spacing",8,"spacing")}function dm(e,t){return"string"==typeof t||null==t?t:e(t)}function cm(e,t,r,o){if(!t.includes(r))return null;const n=function(e,t){return r=>e.reduce((e,o)=>(e[o]=dm(t,r),e),{})}(om(r),o);return Jh(e,e[r],n)}function um(e,t){const r=sm(e.theme);return Object.keys(e).map(o=>cm(e,t,o,r)).reduce(Uh,{})}function pm(e){return um(e,nm)}function hm(e){return um(e,im)}function mm(...e){const t=e.reduce((e,t)=>(t.filterProps.forEach(r=>{e[r]=t}),e),{}),r=e=>Object.keys(e).reduce((r,o)=>t[o]?Uh(r,t[o](e)):r,{});return r.propTypes="production"!==process.env.NODE_ENV?e.reduce((e,t)=>Object.assign(e,t.propTypes),{}):{},r.filterProps=e.reduce((e,t)=>e.concat(t.filterProps),[]),r}function fm(e){return"number"!=typeof e?e:`${e}px solid`}function gm(e,t){return _h({prop:e,themeKey:"borders",transform:t})}pm.propTypes="production"!==process.env.NODE_ENV?nm.reduce((e,t)=>(e[t]=Gh,e),{}):{},pm.filterProps=nm,hm.propTypes="production"!==process.env.NODE_ENV?im.reduce((e,t)=>(e[t]=Gh,e),{}):{},hm.filterProps=im,"production"===process.env.NODE_ENV||am.reduce((e,t)=>(e[t]=Gh,e),{});const xm=gm("border",fm),bm=gm("borderTop",fm),vm=gm("borderRight",fm),ym=gm("borderBottom",fm),Sm=gm("borderLeft",fm),km=gm("borderColor"),Bm=gm("borderTopColor"),wm=gm("borderRightColor"),Cm=gm("borderBottomColor"),Tm=gm("borderLeftColor"),Im=gm("outline",fm),Am=gm("outlineColor"),zm=e=>{if(void 0!==e.borderRadius&&null!==e.borderRadius){const t=lm(e.theme,"shape.borderRadius",4,"borderRadius"),r=e=>({borderRadius:dm(t,e)});return Jh(e,e.borderRadius,r)}return null};zm.propTypes="production"!==process.env.NODE_ENV?{borderRadius:Gh}:{},zm.filterProps=["borderRadius"],mm(xm,bm,vm,ym,Sm,km,Bm,wm,Cm,Tm,zm,Im,Am);const Rm=e=>{if(void 0!==e.gap&&null!==e.gap){const t=lm(e.theme,"spacing",8,"gap"),r=e=>({gap:dm(t,e)});return Jh(e,e.gap,r)}return null};Rm.propTypes="production"!==process.env.NODE_ENV?{gap:Gh}:{},Rm.filterProps=["gap"];const Em=e=>{if(void 0!==e.columnGap&&null!==e.columnGap){const t=lm(e.theme,"spacing",8,"columnGap"),r=e=>({columnGap:dm(t,e)});return Jh(e,e.columnGap,r)}return null};Em.propTypes="production"!==process.env.NODE_ENV?{columnGap:Gh}:{},Em.filterProps=["columnGap"];const Pm=e=>{if(void 0!==e.rowGap&&null!==e.rowGap){const t=lm(e.theme,"spacing",8,"rowGap"),r=e=>({rowGap:dm(t,e)});return Jh(e,e.rowGap,r)}return null};Pm.propTypes="production"!==process.env.NODE_ENV?{rowGap:Gh}:{},Pm.filterProps=["rowGap"];function Om(e,t){return"grey"===t?t:e}mm(Rm,Em,Pm,_h({prop:"gridColumn"}),_h({prop:"gridRow"}),_h({prop:"gridAutoFlow"}),_h({prop:"gridAutoColumns"}),_h({prop:"gridAutoRows"}),_h({prop:"gridTemplateColumns"}),_h({prop:"gridTemplateRows"}),_h({prop:"gridTemplateAreas"}),_h({prop:"gridArea"}));function Lm(e){return e<=1&&0!==e?100*e+"%":e}mm(_h({prop:"color",themeKey:"palette",transform:Om}),_h({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Om}),_h({prop:"backgroundColor",themeKey:"palette",transform:Om}));const Mm=_h({prop:"width",transform:Lm}),Wm=e=>{if(void 0!==e.maxWidth&&null!==e.maxWidth){const t=t=>{const r=e.theme?.breakpoints?.values?.[t]||Xh[t];return r?"px"!==e.theme?.breakpoints?.unit?{maxWidth:`${r}${e.theme.breakpoints.unit}`}:{maxWidth:r}:{maxWidth:Lm(t)}};return Jh(e,e.maxWidth,t)}return null};Wm.filterProps=["maxWidth"];const Dm=_h({prop:"minWidth",transform:Lm}),Fm=_h({prop:"height",transform:Lm}),Nm=_h({prop:"maxHeight",transform:Lm}),Hm=_h({prop:"minHeight",transform:Lm});_h({prop:"size",cssProperty:"width",transform:Lm}),_h({prop:"size",cssProperty:"height",transform:Lm});mm(Mm,Wm,Dm,Fm,Nm,Hm,_h({prop:"boxSizing"}));const Vm={border:{themeKey:"borders",transform:fm},borderTop:{themeKey:"borders",transform:fm},borderRight:{themeKey:"borders",transform:fm},borderBottom:{themeKey:"borders",transform:fm},borderLeft:{themeKey:"borders",transform:fm},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:fm},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:zm},color:{themeKey:"palette",transform:Om},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Om},backgroundColor:{themeKey:"palette",transform:Om},p:{style:hm},pt:{style:hm},pr:{style:hm},pb:{style:hm},pl:{style:hm},px:{style:hm},py:{style:hm},padding:{style:hm},paddingTop:{style:hm},paddingRight:{style:hm},paddingBottom:{style:hm},paddingLeft:{style:hm},paddingX:{style:hm},paddingY:{style:hm},paddingInline:{style:hm},paddingInlineStart:{style:hm},paddingInlineEnd:{style:hm},paddingBlock:{style:hm},paddingBlockStart:{style:hm},paddingBlockEnd:{style:hm},m:{style:pm},mt:{style:pm},mr:{style:pm},mb:{style:pm},ml:{style:pm},mx:{style:pm},my:{style:pm},margin:{style:pm},marginTop:{style:pm},marginRight:{style:pm},marginBottom:{style:pm},marginLeft:{style:pm},marginX:{style:pm},marginY:{style:pm},marginInline:{style:pm},marginInlineStart:{style:pm},marginInlineEnd:{style:pm},marginBlock:{style:pm},marginBlockStart:{style:pm},marginBlockEnd:{style:pm},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:Rm},rowGap:{style:Pm},columnGap:{style:Em},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Lm},maxWidth:{style:Wm},minWidth:{transform:Lm},height:{transform:Lm},maxHeight:{transform:Lm},minHeight:{transform:Lm},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};const Qm=function(){function e(e,t,r,o){const n={[e]:t,theme:r},i=o[e];if(!i)return{[e]:t};const{cssProperty:a=e,themeKey:l,transform:s,style:d}=i;if(null==t)return null;if("typography"===l&&"inherit"===t)return{[e]:t};const c=$h(r,l)||{};if(d)return d(n);return Jh(n,t,t=>{let r=Zh(c,s,t);return t===r&&"string"==typeof t&&(r=Zh(c,s,`${e}${"default"===t?"":Hh(t)}`,t)),!1===a?r:{[a]:r}})}return function t(r){const{sx:o,theme:n={},nested:i}=r||{};if(!o)return null;const a=n.unstable_sxConfig??Vm;function l(r){let o=r;if("function"==typeof r)o=r(n);else if("object"!=typeof r)return r;if(!o)return null;const l=function(e={}){const t=e.keys?.reduce((t,r)=>(t[e.up(r)]={},t),{});return t||{}}(n.breakpoints),s=Object.keys(l);let d=l;return Object.keys(o).forEach(r=>{const i=(l=o[r],s=n,"function"==typeof l?l(s):l);var l,s;if(null!=i)if("object"==typeof i)if(a[r])d=Uh(d,e(r,i,n,a));else{const e=Jh({theme:n},i,e=>({[r]:e}));!function(...e){const t=e.reduce((e,t)=>e.concat(Object.keys(t)),[]),r=new Set(t);return e.every(e=>r.size===Object.keys(e).length)}(e,i)?d=Uh(d,e):d[r]=t({sx:i,theme:n,nested:!0})}else d=Uh(d,e(r,i,n,a))}),!i&&n.modularCssLayers?{"@layer sx":Qh(n,Yh(s,d))}:Qh(n,Yh(s,d))}return Array.isArray(o)?o.map(l):l(o)}}();function jm(e,t){const r=this;if(r.vars){if(!r.colorSchemes?.[e]||"function"!=typeof r.getColorSchemeSelector)return{};let o=r.getColorSchemeSelector(e);return"&"===o?t:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:t})}return r.palette.mode===e?t:{}}function Gm(e){return"ownerState"!==e&&"theme"!==e&&"sx"!==e&&"as"!==e}Qm.filterProps=["sx"],function(e={},...t){const{breakpoints:r={},palette:o={},spacing:n,shape:i={},...a}=e,l=Vh(r),s=function(e=8,t=sm({spacing:e})){if(e.mui)return e;const r=(...e)=>("production"!==process.env.NODE_ENV&&(e.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${e.length}`)),(0===e.length?[1]:e).map(e=>{const r=t(e);return"number"==typeof r?`${r}px`:r}).join(" "));return r.mui=!0,r}(n);let d=Nh({breakpoints:l,direction:"ltr",components:{},palette:{mode:"light",...o},spacing:s,shape:{...jh,...i}},a);d=function(e){const t=(e,t)=>e.replace("@media",t?`@container ${t}`:"@container");function r(r,o){r.up=(...r)=>t(e.breakpoints.up(...r),o),r.down=(...r)=>t(e.breakpoints.down(...r),o),r.between=(...r)=>t(e.breakpoints.between(...r),o),r.only=(...r)=>t(e.breakpoints.only(...r),o),r.not=(...r)=>{const n=t(e.breakpoints.not(...r),o);return n.includes("not all and")?n.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):n}}const o={},n=e=>(r(o,e),o);return r(n),{...e,containerQueries:n}}(d),d.applyStyles=jm,d=t.reduce((e,t)=>Nh(e,t),d),d.unstable_sxConfig={...Vm,...a?.unstable_sxConfig},d.unstable_sx=function(e){return Qm({sx:e,theme:this})}}();const Um=(e,t,r)=>"function"==typeof r?r(e,t):r,Xm=t=>{const{runItemPlugins:r,publicAPI:o,store:n}=Qu(),i=e.useContext(th),a=wp(n,Um,t.itemId,i),{id:l,itemId:s,label:d,children:c,rootRef:u}=t,{rootRef:p,contentRef:h,propsEnhancers:m}=r(t),{interactions:f,status:g}=(({itemId:e,children:t})=>{const{store:r,publicAPI:o}=Qu(),n=wp(r,Qp.isItemExpandable,e),i=wp(r,Sh.isItemLoading,e),a=wp(r,Sh.itemHasError,e),l=kh(t)||n,s=wp(r,Qp.isItemExpanded,e),d=wp(r,xh.isItemFocused,e),c=wp(r,Fp.isItemSelected,e),u=wp(r,Op.isItemDisabled,e),p=wp(r,hh.isItemBeingEdited,e),h=wp(r,hh.isItemEditable,e),m={expandable:l,expanded:s,focused:d,selected:c,disabled:u,editing:p,editable:h,loading:i,error:a},f=()=>{r.labelEditing&&(p?r.labelEditing.setEditedItem(null):r.labelEditing.setEditedItem(e))};return{interactions:{handleExpansion:t=>{if(m.disabled)return;m.focused||r.focus.focusItem(t,e);const o=Fp.isMultiSelectEnabled(r.state)&&(t.shiftKey||t.ctrlKey||t.metaKey);!m.expandable||o&&Qp.isItemExpanded(r.state,e)||r.expansion.setItemExpansion({event:t,itemId:e})},handleSelection:t=>{Fp.canItemBeSelected(r.state,e)&&(m.focused||m.editing||r.focus.focusItem(t,e),Fp.isMultiSelectEnabled(r.state)&&(t.shiftKey||t.ctrlKey||t.metaKey)?t.shiftKey?r.selection.expandSelectionRange(t,e):r.selection.setItemSelection({event:t,itemId:e,keepExistingSelection:!0}):r.selection.setItemSelection({event:t,itemId:e,shouldBeSelected:!0}))},handleCheckboxSelection:t=>{const o=t.nativeEvent.shiftKey,n=Fp.isMultiSelectEnabled(r.state);n&&o?r.selection.expandSelectionRange(t,e):r.selection.setItemSelection({event:t,itemId:e,keepExistingSelection:n,shouldBeSelected:t.target.checked})},toggleItemEditing:f,handleSaveItemLabel:(t,o)=>{r.labelEditing&&hh.isItemBeingEdited(r.state,e)&&(r.labelEditing.updateItemLabel(e,o),f(),r.focus.focusItem(t,e))},handleCancelItemLabelEditing:t=>{r.labelEditing&&hh.isItemBeingEdited(r.state,e)&&(f(),r.focus.focusItem(t,e))}},status:m,publicAPI:o}})({itemId:s,children:c}),x=e.useRef(null),b=e.useRef(null),v=Su(u,p,x),y=Su(h,b),S=e.useRef(null),k=wp(n,Fp.isCheckboxSelectionEnabled),B=wp(n,Ip.treeItemIdAttribute,s,l),w=wp(n,xh.isItemTheDefaultFocusableItem,s),C={rootRefObject:x,contentRefObject:b,interactions:f},T=e=>t=>{if(e.onBlur?.(t),t.defaultMuiPrevented)return;const r=n.items.getItemDOMElement(s);g.editing||t.relatedTarget&&Jp(t.relatedTarget,r)&&(t.target&&"labelInput"===t.target?.dataset?.element&&Jp(t.target,r)||"labelInput"===t.relatedTarget?.dataset?.element)||n.focus.removeFocusedItem()},I=e=>t=>{e.onKeyDown?.(t),t.defaultMuiPrevented||"labelInput"===t.target?.dataset?.element||n.keyboardNavigation.handleItemKeyDown(t,s)},A=e=>t=>{e.onMouseDown?.(t),t.defaultMuiPrevented||(t.shiftKey||t.ctrlKey||t.metaKey||g.disabled)&&t.preventDefault()};return{getContextProviderProps:()=>({itemId:s,id:l}),getRootProps:(e={})=>{const r=bu({},Tu(t),Tu(e)),o=bu({},r,{ref:v,role:"treeitem",tabIndex:w?0:-1,id:B,"aria-expanded":g.expandable?g.expanded:void 0,"aria-disabled":g.disabled||void 0},e,{style:bu({},e.style??{},{"--TreeView-itemDepth":a}),onFocus:(i=r,e=>{i.onFocus?.(e),e.defaultMuiPrevented||!g.focused&&Op.canItemBeFocused(n.state,s)&&e.currentTarget===e.target&&n.focus.focusItem(e,s)}),onBlur:T(r),onKeyDown:I(r)});var i;const l=m.root?.(bu({},C,{externalEventHandlers:r}))??{};return bu({},o,l)},getContentProps:(e={})=>{const t=Tu(e),r=bu({},t,e,{ref:y,onClick:(o=t,e=>{o.onClick?.(e),n.items.handleItemClick(e,s),e.defaultMuiPrevented||S.current?.contains(e.target)||("content"===Qp.triggerSlot(n.state)&&f.handleExpansion(e),k||f.handleSelection(e))}),onMouseDown:A(t),status:g});var o;["expanded","selected","focused","disabled","editing","editable"].forEach(e=>{g[e]&&(r[`data-${e}`]="")});const i=m.content?.(bu({},C,{externalEventHandlers:t}))??{};return bu({},r,i)},getGroupTransitionProps:(e={})=>bu({},Tu(e),{unmountOnExit:!0,component:"ul",role:"group",in:g.expanded,children:c},e),getIconContainerProps:(e={})=>{const t=Tu(e);return bu({},t,e,{onClick:(r=t,e=>{r.onClick?.(e),e.defaultMuiPrevented||"iconContainer"===Qp.triggerSlot(n.state)&&f.handleExpansion(e)})});var r},getCheckboxProps:(e={})=>{const t=Tu(e),r=bu({},t,{ref:S,"aria-hidden":!0},e),o=m.checkbox?.(bu({},C,{externalEventHandlers:t}))??{};return bu({},r,o)},getLabelProps:(e={})=>{const t=bu({},Tu(e)),r=bu({},t,{children:d},e,{onDoubleClick:(o=t,e=>{o.onDoubleClick?.(e),e.defaultMuiPrevented||f.toggleItemEditing()})});var o;const n=m.label?.(bu({},C,{externalEventHandlers:t}))??{};return bu({},n,r)},getLabelInputProps:(e={})=>{const t=Tu(e),r=m.labelInput?.(bu({},C,{externalEventHandlers:t}))??{};return bu({},e,r)},getDragAndDropOverlayProps:(e={})=>{const t=Tu(e),r=m.dragAndDropOverlay?.(bu({},C,{externalEventHandlers:t}))??{};return bu({},e,r)},getErrorContainerProps:(e={})=>bu({},Tu(e),e),getLoadingContainerProps:(e={})=>bu({size:"12px",thickness:6},Tu(e),e),rootRef:v,status:g,publicAPI:o}};function Km(e){return Wu("MuiTreeItem",e)}Du("MuiTreeItem",["root","content","groupTransition","iconContainer","label","checkbox","labelInput","dragAndDropOverlay","errorIcon","loadingIcon","expanded","selected","focused","disabled","editable","editing"]);const qm=lr(de("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"TreeViewExpandIcon"),Jm=lr(de("path",{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"}),"TreeViewCollapseIcon"),Ym=["ownerState"];function $m(e,t,r){return void 0!==e?e:void 0!==t?t:r}function Zm(e){const{slots:t,slotProps:r,status:o}=e,{slots:n,slotProps:i}=Gu(),a={collapseIcon:$m(t?.collapseIcon,n.collapseIcon,Jm),expandIcon:$m(t?.expandIcon,n.expandIcon,qm),endIcon:$m(t?.endIcon,n.endIcon),icon:t?.icon};let l;l=a?.icon?"icon":o.expandable?o.expanded?"collapseIcon":"expandIcon":"endIcon";const s=a[l],d=Xu(zu({elementType:s,externalSlotProps:e=>bu({},Au(i[l],e),Au(r?.[l],e)),ownerState:{}}),Ym);return s?de(s,bu({},d)):null}"production"!==process.env.NODE_ENV&&(Zm.propTypes={slotProps:Di.object,slots:Di.object,status:Di.shape({disabled:Di.bool.isRequired,editable:Di.bool.isRequired,editing:Di.bool.isRequired,error:Di.bool.isRequired,expandable:Di.bool.isRequired,expanded:Di.bool.isRequired,focused:Di.bool.isRequired,loading:Di.bool.isRequired,selected:Di.bool.isRequired}).isRequired});const _m=or("div",{name:"MuiTreeItemDragAndDropOverlay",slot:"Root",shouldForwardProp:e=>Gm(e)&&"action"!==e})(({theme:e})=>({position:"absolute",left:0,display:"flex",top:0,bottom:0,right:0,pointerEvents:"none",variants:[{props:{action:"make-child"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * var(--TreeView-itemDepth))",borderRadius:e.shape.borderRadius,backgroundColor:e.vars?`rgba(${e.vars.palette.primary.darkChannel} / ${e.vars.palette.action.focusOpacity})`:nr(e.palette.primary.dark,e.palette.action.focusOpacity)}},{props:{action:"reorder-above"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * var(--TreeView-itemDepth))",borderTop:`1px solid ${(e.vars||e).palette.action.active}`}},{props:{action:"reorder-below"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * var(--TreeView-itemDepth))",borderBottom:`1px solid ${(e.vars||e).palette.action.active}`}},{props:{action:"move-to-parent"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * calc(var(--TreeView-itemDepth) - 1))",borderBottom:`1px solid ${(e.vars||e).palette.action.active}`}}]}));function ef(e){return null==e.action?null:de(_m,bu({},e))}function tf(t){const{children:r,itemId:o,id:n}=t,{wrapItem:i,store:a}=Qu(),l=wp(a,Ip.treeItemIdAttribute,o,n);return de(e.Fragment,{children:i({children:r,itemId:o,store:a,idAttribute:l})})}"production"!==process.env.NODE_ENV&&(ef.propTypes={action:Di.oneOf(["make-child","move-to-parent","reorder-above","reorder-below"]),style:Di.object}),"production"!==process.env.NODE_ENV&&(tf.propTypes={children:Di.node,id:Di.string,itemId:Di.string.isRequired});const rf=or("input",{name:"MuiTreeItem",slot:"LabelInput"})(({theme:e})=>bu({},e.typography.body1,{width:"100%",backgroundColor:(e.vars||e).palette.background.paper,borderRadius:e.shape.borderRadius,border:"none",padding:"0 2px",boxSizing:"border-box","&:focus":{outline:`1px solid ${(e.vars||e).palette.primary.main}`}})),of=["visible"],nf=["id","itemId","label","disabled","disableSelection","children","slots","slotProps","classes"],af=Pu(),lf=or("li",{name:"MuiTreeItem",slot:"Root"})({listStyle:"none",margin:0,padding:0,outline:0}),sf=or("div",{name:"MuiTreeItem",slot:"Content",shouldForwardProp:e=>Gm(e)&&"status"!==e})(({theme:e})=>({padding:e.spacing(.5,1),paddingLeft:`calc(${e.spacing(1)} + var(--TreeView-itemChildrenIndentation) * var(--TreeView-itemDepth))`,borderRadius:e.shape.borderRadius,width:"100%",boxSizing:"border-box",position:"relative",display:"flex",alignItems:"center",gap:e.spacing(1),cursor:"pointer",WebkitTapHighlightColor:"transparent","&:hover":{backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},"&[data-disabled]":{opacity:(e.vars||e).palette.action.disabledOpacity,backgroundColor:"transparent",cursor:"auto"},"&[data-focused]":{backgroundColor:(e.vars||e).palette.action.focus},"&[data-selected]":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:nr(e.palette.primary.main,e.palette.action.selectedOpacity),"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:nr(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:nr(e.palette.primary.main,e.palette.action.selectedOpacity)}}},"&[data-selected][data-focused]":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:nr(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}})),df=or("div",{name:"MuiTreeItem",slot:"Label",shouldForwardProp:e=>Gm(e)&&"editable"!==e})(({theme:e})=>bu({width:"100%",boxSizing:"border-box",minWidth:0,position:"relative",overflow:"hidden"},e.typography.body1,{variants:[{props:({editable:e})=>e,style:{paddingLeft:"2px"}}]})),cf=or("div",{name:"MuiTreeItem",slot:"IconContainer"})({width:16,display:"flex",flexShrink:0,justifyContent:"center",position:"relative",cursor:"inherit","& svg":{fontSize:18}}),uf=or(ir,{name:"MuiTreeItem",slot:"GroupTransition",overridesResolver:(e,t)=>t.groupTransition})({margin:0,padding:0}),pf=or("div",{name:"MuiTreeItem",slot:"ErrorIcon"})({position:"absolute",right:-3,width:7,height:7,borderRadius:"50%",backgroundColor:"red"}),hf=or(Vt,{name:"MuiTreeItem",slot:"LoadingIcon"})({color:"text.primary"}),mf=or(e.forwardRef((e,t)=>{const{visible:r}=e,o=Xu(e,of);return r?de(ar,bu({},o,{ref:t})):null}),{name:"MuiTreeItem",slot:"Checkbox"})({padding:0});"production"!==process.env.NODE_ENV&&(mf.displayName="TreeItemCheckbox");const ff=e.forwardRef(function(e,t){const r=af({props:e,name:"MuiTreeItem"}),{id:o,itemId:n,label:i,disabled:a,disableSelection:l,children:s,slots:d={},slotProps:c={},classes:u}=r,p=Xu(r,nf),{getContextProviderProps:h,getRootProps:m,getContentProps:f,getIconContainerProps:g,getCheckboxProps:x,getLabelProps:b,getGroupTransitionProps:v,getLabelInputProps:y,getDragAndDropOverlayProps:S,getErrorContainerProps:k,getLoadingContainerProps:B,status:w}=Xm({id:o,itemId:n,children:s,label:i,disabled:a,disableSelection:l}),C=(e=>{const{classes:t}=Gu();return Bu({root:["root"],content:["content"],iconContainer:["iconContainer"],checkbox:["checkbox"],label:["label"],groupTransition:["groupTransition"],labelInput:["labelInput"],dragAndDropOverlay:["dragAndDropOverlay"],errorIcon:["errorIcon"],loadingIcon:["loadingIcon"],expanded:["expanded"],editing:["editing"],editable:["editable"],selected:["selected"],focused:["focused"],disabled:["disabled"]},Km,bu({},e,{root:Cu(e?.root,t.root),content:Cu(e?.content,t.itemContent),iconContainer:Cu(e?.iconContainer,t.itemIconContainer),checkbox:Cu(e?.checkbox,t.itemCheckbox),label:Cu(e?.label,t.itemLabel),groupTransition:Cu(e?.groupTransition,t.itemGroupTransition),labelInput:Cu(e?.labelInput,t.itemLabelInput),dragAndDropOverlay:Cu(e?.dragAndDropOverlay,t.itemDragAndDropOverlay),errorIcon:Cu(e?.errorIcon,t.itemErrorIcon),loadingIcon:Cu(e?.loadingIcon,t.itemLoadingIcon)}))})(u),T=d.root??lf,I=zu({elementType:T,getSlotProps:m,externalForwardedProps:p,externalSlotProps:c.root,additionalProps:{ref:t},ownerState:{},className:C.root}),A=d.content??sf,z=zu({elementType:A,getSlotProps:f,externalSlotProps:c.content,ownerState:{},className:Cu(C.content,w.expanded&&C.expanded,w.selected&&C.selected,w.focused&&C.focused,w.disabled&&C.disabled,w.editing&&C.editing,w.editable&&C.editable)}),R=d.iconContainer??cf,E=zu({elementType:R,getSlotProps:g,externalSlotProps:c.iconContainer,ownerState:{},className:C.iconContainer}),P=d.label??df,O=zu({elementType:P,getSlotProps:b,externalSlotProps:c.label,ownerState:{},className:C.label}),L=d.checkbox??mf,M=zu({elementType:L,getSlotProps:x,externalSlotProps:c.checkbox,ownerState:{},className:C.checkbox}),W=d.groupTransition??void 0,D=zu({elementType:W,getSlotProps:v,externalSlotProps:c.groupTransition,ownerState:{},className:C.groupTransition}),F=d.labelInput??rf,N=zu({elementType:F,getSlotProps:y,externalSlotProps:c.labelInput,ownerState:{},className:C.labelInput}),H=d.dragAndDropOverlay??ef,V=zu({elementType:H,getSlotProps:S,externalSlotProps:c.dragAndDropOverlay,ownerState:{},className:C.dragAndDropOverlay}),Q=d.errorIcon??pf,j=zu({elementType:Q,getSlotProps:k,externalSlotProps:c.errorIcon,ownerState:{},className:C.errorIcon}),G=d.loadingIcon??hf,U=zu({elementType:G,getSlotProps:B,externalSlotProps:c.loadingIcon,ownerState:{},className:C.loadingIcon});return de(tf,bu({},h(),{children:ce(T,bu({},I,{children:[ce(A,bu({},z,{children:[ce(R,bu({},E,{children:[w.error&&de(Q,bu({},j)),w.loading?de(G,bu({},U)):de(Zm,{status:w,slots:d,slotProps:c})]})),de(L,bu({},M)),w.editing?de(F,bu({},N)):de(P,bu({},O)),de(H,bu({},V))]})),s&&de(uf,bu({as:W},D))]}))}))});"production"!==process.env.NODE_ENV&&(ff.displayName="TreeItem"),"production"!==process.env.NODE_ENV&&(ff.propTypes={children:Di.any,classes:Di.object,className:Di.string,disabled:Di.bool,disableSelection:Di.bool,id:Di.string,itemId:Di.string.isRequired,label:Di.node,onBlur:Di.func,onFocus:function(e,t,r,o,n){if("production"===process.env.NODE_ENV)return null;const i=n||t;return void 0!==e[t]?new Error(`The prop \`${i}\` is not supported. Please remove it.`):null},onKeyDown:Di.func,slotProps:Di.object,slots:Di.object,sx:Di.oneOfType([Di.arrayOf(Di.oneOfType([Di.func,Di.object,Di.bool])),Di.func,Di.object])});const gf=e=>e.charAt(0).toUpperCase()+e.slice(1),xf={compact:{minHeight:"24px",fontSize:"13px",py:"2px",px:"10px",iconSize:16,gap:"6px"},default:{minHeight:"32px",fontSize:"14px",py:"4px",px:"12px",iconSize:18,gap:"8px"}},bf={none:{},slide:{"& .MuiCollapse-root":{transition:"all 0.25s ease"}},spring:{"& .MuiCollapse-root":{transition:"all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1)"}}};function vf(e){return{outline:"none","&.Mui-focused > .MuiTreeItem-content":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},"&:focus-visible > .MuiTreeItem-content":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},"& > .MuiTreeItem-content":{minHeight:e.minHeight,fontSize:e.fontSize,fontFamily:"inherit",color:"var(--Quiet)",padding:"0 8px",borderRadius:"var(--Style-Border-Radius)",border:"1px solid transparent",transition:"color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease",backgroundColor:"transparent",outline:"none","&:hover":{color:"var(--Text)",backgroundColor:"var(--Hover)"},"&:active":{color:"var(--Text)",backgroundColor:"var(--Pressed)"},"&.Mui-selected":{color:"var(--Text)",fontWeight:600,backgroundColor:"var(--Pressed)",padding:"0 8px","&:hover":{backgroundColor:"var(--Hover)"}},"&.Mui-disabled":{opacity:.45}},"& > .MuiTreeItem-content .MuiTreeItem-label":{fontSize:e.fontSize,fontFamily:"inherit",lineHeight:e.minHeight,padding:0,width:"100%"},"& > .MuiTreeItem-content .MuiTreeItem-iconContainer":{width:e.iconSize+"px",color:"inherit",zIndex:1},"& > .MuiTreeItem-group":{marginLeft:"12px",borderLeft:"1px solid var(--Border)",paddingLeft:"8px"}}}function yf({item:e,d:t,isCompact:r}){const o=r?bo:ao;return ce(h,{sx:{display:"flex",alignItems:"center",gap:t.gap,width:"100%"},children:[e.icon&&de(jo,{size:"small",sx:{color:"inherit",flexShrink:0},children:e.icon}),de(o,{style:{flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",color:"inherit",fontWeight:"inherit"},children:e.label}),e.badge&&de(h,{sx:{flexShrink:0},children:e.badge})]})}function Sf(e=[],t="default",r="primary",o="default",n=[]){const i=xf[t]||xf.default,a="compact"===t;return gf(r),e.map(e=>de(ff,{itemId:e.id,disabled:e.disabled,label:de(yf,{item:e,d:i,isCompact:a}),sx:{...vf(i),...e.sx||{}},children:e.children&&e.children.length>0?Sf(e.children,t,r,o,n):null},e.id))}function kf({color:e="default",variant:t="solid",density:o="default",animation:i="slide",selectionStyle:a,items:l=Bf,selectionMode:s="single",checkboxSelection:d=!1,disableSelection:c=!1,disabledItemsFocusable:u=!1,defaultExpandedItems:p,expandedItems:m,onExpandedItemsChange:f,selectedItems:g,onSelectedItemsChange:x,onItemExpansionToggle:b,onItemSelectionToggle:v,slots:y,"aria-label":S="Tree view",className:k="",sx:B={},...w}){const C=a||t,T=gf(e),I="light"===C?"Surface-Brightest":"Surface-Dim",[A,z]=r(g||("multi"===s?[]:null)),R=void 0!==g?g:A,E=Array.isArray(R)?R:R?[R]:[],P=n((e,t)=>{void 0===g&&z(t),x?.(e,t)},[g,x]),O={};return void 0!==m&&(O.expandedItems=m),void 0!==f&&(O.onExpandedItemsChange=f),void 0!==p&&(O.defaultExpandedItems=p),de(h,{"data-theme":T,"data-surface":I,className:"omni-treeview omni-treeview-"+C+" omni-treeview-"+e+" omni-treeview-"+o+(k?" "+k:""),sx:{backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",...bf[i]||{},...B},children:de(Rh,{"aria-label":S,multiSelect:"multi"===s,checkboxSelection:d,disableSelection:c,disabledItemsFocusable:u,selectedItems:R,onSelectedItemsChange:P,onItemExpansionToggle:b,onItemSelectionToggle:v,slots:{expandIcon:()=>de(jo,{size:"small",sx:{color:"inherit"},children:de(Kt,{})}),collapseIcon:()=>de(jo,{size:"small",sx:{color:"inherit"},children:de(Se,{})}),...y},sx:{p:"8px","& .MuiTreeItem-root":{fontFamily:"inherit"},"& .MuiTreeItem-content.Mui-focused":{outline:"none"},"& .MuiTreeItem-content:focus-visible":{outline:"none"}},...O,...w,children:Sf(l,o,e,C,E)})})}const Bf=[{id:"1",label:"Design System",children:[{id:"1-1",label:"Foundations",children:[{id:"1-1-1",label:"Colors"},{id:"1-1-2",label:"Typography"},{id:"1-1-3",label:"Spacing"}]},{id:"1-2",label:"Components",children:[{id:"1-2-1",label:"Buttons"},{id:"1-2-2",label:"Inputs"},{id:"1-2-3",label:"Navigation",disabled:!0}]}]},{id:"2",label:"Tokens",children:[{id:"2-1",label:"Light Mode"},{id:"2-2",label:"Dark Mode"}]},{id:"3",label:"Changelog"}],wf=e=>de(kf,{variant:"solid",...e}),Cf=e=>de(kf,{variant:"light",...e}),Tf=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",If=[{id:"home",label:"Home"},{id:"products",label:"Products",children:[{id:"featured",label:"Featured"},{id:"new",label:"New Arrivals"},{id:"sale",label:"On Sale"}]},{id:"about",label:"About"},{id:"contact",label:"Contact"}];function Af({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function zf(){const[e,t]=r(!1),[o,n]=r("medium"),[i,a]=r("left"),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Drawer"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:l,surface:d,children:de(Tn,{variant:"default",onClick:()=>t(!0),children:"Open Drawer"})}),de(Ni,{code:(()=>{const e=["open={open}","onClose={handleClose}"];return"medium"!==o&&e.push('size="'+o+'"'),"left"!==i&&e.push('anchor="'+i+'"'),"<Drawer "+e.join(" ")+">\n <DrawerHeader>\n <H5>Navigation</H5>\n <DrawerClose onClick={handleClose} />\n </DrawerHeader>\n <DrawerContent>\n <OmniTreeView items={navItems} />\n </DrawerContent>\n</Drawer>"})(),language:"JSX",wrap:!0,sx:{mt:2}}),ce(mu,{open:e,onClose:()=>t(!1),size:o,anchor:i,children:[ce(gu,{children:[de($r,{children:"Navigation"}),de(fu,{onClick:()=>t(!1)})]}),de(xu,{children:de(kf,{items:If,variant:"solid",color:"default",defaultExpandedItems:["products"],sx:{border:"none",borderRadius:0}})})]})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Af,{label:Tf(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ANCHOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["left","right","top","bottom"].map(e=>de(Af,{label:Tf(e),selected:i===e,onClick:()=>a(e)},e))})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="dialog" aria-modal="true"'},{label:"Focus",value:"Focus trapped inside drawer. Returns to trigger on close."},{label:"Keyboard",value:"Escape closes. Tab cycles focusable elements."},{label:"Backdrop",value:"Click closes. Body scroll locked while open."},{label:"Close",value:'Button with aria-label="Close drawer"'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Rf={small:{minHeight:"120px",padding:"16px",iconSize:"20px",gap:1},medium:{minHeight:"200px",padding:"32px 24px",iconSize:"32px",gap:2},large:{minHeight:"300px",padding:"48px 24px",iconSize:"48px",gap:3}};function Ef({onFiles:e,accept:t,multiple:i=!1,size:a="medium",disabled:l=!1,icon:s,label:d,sublabel:c,children:u,className:p="",sx:m={},...f}){const[g,x]=r(!1),b=o(null),v=o(0),y=Rf[a]||Rf.medium,S=n(t=>{!l&&t?.length&&e?.(Array.from(t))},[l,e]),k=n(e=>{e.preventDefault(),e.stopPropagation(),v.current=0,x(!1),l||S(e.dataTransfer.files)},[l,S]),B=n(e=>{e.preventDefault(),e.stopPropagation()},[]),w=n(e=>{e.preventDefault(),e.stopPropagation(),v.current++,l||x(!0)},[l]),C=n(e=>{e.preventDefault(),e.stopPropagation(),v.current--,0===v.current&&x(!1)},[]),T=n(()=>{l||b.current?.click()},[l]),I=n(e=>{l||"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),b.current?.click())},[l]),A=n(e=>{S(e.target.files),e.target.value=""},[S]),z=s||sr,R=i?"Drag and drop files here":"Drag and drop file here";return ce(h,{role:"button",tabIndex:l?-1:0,"aria-label":d||R,"aria-disabled":l||void 0,onClick:T,onKeyDown:I,onDrop:k,onDragOver:B,onDragEnter:w,onDragLeave:C,className:"drop-zone drop-zone-"+a+(g?" drop-zone-dragging":"")+(l?" drop-zone-disabled":"")+" "+p,sx:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:y.gap,minHeight:y.minHeight,padding:y.padding,border:"2px dashed",borderColor:g?"var(--Buttons-Primary-Border)":"var(--Buttons-Default-Border)",borderRadius:"32px",backgroundColor:g?"var(--Hover)":"transparent",color:"var(--Text)",cursor:l?"not-allowed":"pointer",opacity:l?.5:1,outline:"none",transition:"background-color 0.2s ease, border-color 0.2s ease",textAlign:"center",...!l&&{"&:hover":{backgroundColor:"var(--Hover)",borderColor:"var(--Buttons-Primary-Border)"},"&:active":{backgroundColor:"var(--Pressed)",borderColor:"var(--Buttons-Primary-Border)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px",borderColor:"var(--Buttons-Primary-Border)"}},...m},...f,children:[de("input",{ref:b,type:"file",accept:t,multiple:i,onChange:A,style:{display:"none"},"aria-hidden":"true",tabIndex:-1}),u||ce(ue,{children:[de(z,{sx:{fontSize:y.iconSize,color:"var(--Text-Quiet)"}}),de(ao,{style:{color:"var(--Text)"},children:d||R}),de(bo,{style:{color:"var(--Text-Quiet)"},children:c||"or click to browse"})]})]})}const Pf={small:{px:"12px",py:"8px",fontSize:"13px",iconSize:"18px",gap:"8px"},medium:{px:"16px",py:"12px",fontSize:"14px",iconSize:"20px",gap:"10px"},large:{px:"20px",py:"14px",fontSize:"16px",iconSize:"22px",gap:"12px"}};function Of({children:e,variant:t="light",color:r="info",size:o="medium",startDecorator:n,endDecorator:i,className:a="",sx:l={},...s}){const d=(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===r?"Default":r),c=Pf[o]||Pf.medium,u="default"===r?"Default":d,p="light"===t?"Surface-Brightest":"Surface",m="var(--Buttons-"+d+"-Border)",f=ce(ue,{children:[n&&de(h,{className:"alert-start-decorator",sx:{display:"inline-flex",alignItems:"center",fontSize:c.iconSize,lineHeight:1,flexShrink:0,mt:"2px"},children:n}),de(h,{className:"alert-message",sx:{flex:1,minWidth:0},children:"string"==typeof e?de("small"===o?ao:co,{children:e}):e}),i&&de(h,{className:"alert-end-decorator",sx:{display:"inline-flex",alignItems:"flex-start",flexShrink:0,gap:c.gap,paddingTop:"2px"},children:i})]});return de(h,{role:"alert",className:"alert alert-"+t+" alert-"+o+" alert-"+r+" "+a,sx:{border:"1px solid "+m,borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",boxShadow:ln,...l},...s,children:de(h,{"data-theme":u,"data-surface":p,className:"alert-inner",sx:{display:"flex",alignItems:"flex-start",gap:c.gap,padding:c.py+" "+c.px,fontSize:c.fontSize,fontFamily:"inherit",lineHeight:1.5,color:"var(--Text)",backgroundColor:"var(--Background)",borderRadius:"calc(var(--Style-Border-Radius) - 1px)"},children:f})})}const Lf=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Mf=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Wf={info:de(ve,{}),success:de(ge,{}),warning:de(xe,{}),error:de(be,{})};function Df({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Ff({color:e,selected:t,onClick:r}){const o=Lf(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Nf(){const[e,t]=r("light"),[o,n]=r("info"),[i,a]=r("medium"),[l,s]=r(!0),[d,c]=r(null),[u,p]=r("Surface"),m=l&&Wf[o]?de(jo,{size:"small",sx:{color:"inherit"},children:Wf[o]}):void 0;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Alert"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:480},children:de(Of,{variant:e,color:o,size:i,startDecorator:m,children:"This is an alert message. Check the details for more information."})})}),de(Ni,{code:(()=>{const t=['variant="'+e+'"'];return"info"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),l&&Wf[o]&&t.push("startDecorator={<Icon><"+Lf(o)+"Icon /></Icon>}"),"<Alert "+t.join(" ")+">\n This is an alert message.\n</Alert>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["solid","light"].map(r=>de(Df,{label:Lf(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Mf.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Ff,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Df,{label:Lf(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Icon"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Start decorator icon"})]}),de(_i,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Show icon"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="alert" — live region, announced immediately'},{label:"Border",value:"var(--Buttons-{Color}-Border) on outer shell"},{label:"Shadow",value:"var(--Effect-Level-3)"},{label:"Icons",value:"Decorative — aria-hidden by default via Icon component"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Hf={small:{px:"12px",py:"8px",fontSize:"13px",gap:"8px",minWidth:"240px"},medium:{px:"16px",py:"10px",fontSize:"14px",gap:"12px",minWidth:"300px"},large:{px:"20px",py:"14px",fontSize:"16px",gap:"16px",minWidth:"360px"}};function Vf({children:e,open:t=!1,onClose:r,variant:a="light",color:l="info",size:s="medium",anchor:d="bottom",autoHideDuration:c,startDecorator:u,endDecorator:p,action:m,className:f="",sx:g={},...x}){const b=o(null),v=(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===l?"Default":l),y=Hf[s]||Hf.medium,S="small"===s?ao:co,k="default"===l?"Default":v,B="light"===a?"Surface-Brightest":"Surface",w="var(--Buttons-"+v+"-Border)";i(()=>{if(t&&c&&c>0)return b.current=setTimeout(()=>{r?.({},"timeout")},c),()=>clearTimeout(b.current)},[t,c,r]),i(()=>{if(!t)return;const e=e=>{"Escape"===e.key&&r?.(e,"escapeKeyDown")};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[t,r]);const C=n(()=>{b.current&&clearTimeout(b.current)},[]),T=n(()=>{t&&c&&c>0&&(b.current=setTimeout(()=>{r?.({},"timeout")},c))},[t,c,r]),I="top"===d?{from:{transform:"translateX(-50%) translateY(-120%)"},to:{transform:"translateX(-50%) translateY(0)"}}:{from:{transform:"translateX(-50%) translateY(120%)"},to:{transform:"translateX(-50%) translateY(0)"}};return t?de(h,{role:"alert","aria-live":"polite","aria-atomic":"true",onMouseEnter:C,onMouseLeave:T,className:"snackbar snackbar-"+a+" snackbar-"+s+" snackbar-"+d+" snackbar-"+l+" "+f,sx:{position:"fixed",left:"50%",transform:"translateX(-50%)",..."top"===d?{top:"16px"}:{bottom:"16px"},zIndex:1400,minWidth:y.minWidth,maxWidth:"min(560px, calc(100vw - 32px))",border:"1px solid "+w,borderRadius:"var(--Style-Border-Radius)",boxShadow:ln,overflow:"hidden",animation:"snackbar-slide-in 0.3s ease forwards","@keyframes snackbar-slide-in":I,...g},...x,children:ce(h,{"data-theme":k,"data-surface":B,sx:{display:"flex",alignItems:"center",gap:y.gap,padding:y.py+" "+y.px,fontSize:y.fontSize,fontFamily:"inherit",lineHeight:1.4,color:"var(--Text)",backgroundColor:"var(--Background)",borderRadius:"calc(var(--Style-Border-Radius) - 1px)"},children:[u&&de(h,{sx:{display:"inline-flex",flexShrink:0,lineHeight:1},children:u}),de(h,{sx:{flex:1,minWidth:0},children:"string"==typeof e?de(S,{children:e}):e}),m&&de(h,{sx:{display:"inline-flex",flexShrink:0},children:m}),p&&de(h,{sx:{display:"inline-flex",flexShrink:0,lineHeight:1},children:p}),r&&de(Tn,{iconOnly:!0,variant:"ghost",size:"small",onClick:e=>r(e,"closeClick"),"aria-label":"Close notification",sx:{flexShrink:0,ml:"4px"},children:de(jo,{size:"small",children:de(Ot,{})})})]})}):null}const Qf=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",jf=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Gf={info:de(ve,{}),success:de(ge,{}),warning:de(xe,{}),error:de(be,{})};function Uf({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Xf({color:e,selected:t,onClick:r}){const o=Qf(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Kf(){const[e,t]=r("light"),[o,n]=r("info"),[i,a]=r("medium"),[l,s]=r("bottom"),[d,c]=r(!0),[u,p]=r(!0),[m,f]=r(!1),[g,x]=r(null),[b,v]=r("Surface"),y=d&&Gf[o]?de(jo,{size:"small",sx:{color:"inherit"},children:Gf[o]}):void 0;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Snackbar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:g,surface:b,children:de(Tn,{variant:"default",onClick:()=>f(!0),children:"Show Snackbar"})}),de(Ni,{code:(()=>{const t=["open={open}"];return t.push('variant="'+e+'"'),"info"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),"bottom"!==l&&t.push('anchor="top"'),u&&t.push("onClose={handleClose}"),d&&Gf[o]&&t.push("startDecorator={<Icon><"+Qf(o)+"Icon /></Icon>}"),"<Snackbar\n "+t.join("\n ")+"\n>\n Operation completed successfully.\n</Snackbar>"})(),language:"JSX",wrap:!0,sx:{mt:2}}),de(Vf,{open:m,onClose:u?()=>f(!1):void 0,variant:e,color:o,size:i,anchor:l,autoHideDuration:4e3,startDecorator:y,children:"Operation completed successfully."})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:g,onThemeChange:x,surface:b,onSurfaceChange:v})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["solid","light"].map(r=>de(Uf,{label:Qf(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:jf.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Xf,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Uf,{label:Qf(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ANCHOR"}),de(B,{direction:"row",spacing:1,children:["top","bottom"].map(e=>de(Uf,{label:Qf(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Icon"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Start decorator icon"})]}),de(_i,{variant:"default-outline",checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Show icon"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Close Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show dismiss button"})]}),de(_i,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Close button"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="alert" aria-live="polite" aria-atomic="true"'},{label:"Close",value:'Button with aria-label="Close notification"'},{label:"Keyboard",value:"Escape closes. Auto-hides after duration."},{label:"Hover",value:"Pauses auto-hide timer on mouse enter"},{label:"Border",value:"var(--Buttons-{Color}-Border) on outer shell"},{label:"Shadow",value:"var(--Effect-Level-3)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const qf={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",white:"Neutral",black:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Jf={small:{diameter:24,thickness:3,fontSize:"9px",labelSize:"0px"},medium:{diameter:40,thickness:4,fontSize:"12px",labelSize:"12px"},large:{diameter:56,thickness:5,fontSize:"14px",labelSize:"14px"}};function Yf({value:e,color:t="primary",size:r="medium",thickness:o,showValue:n=!1,children:i,className:l="",sx:s={},...d}){const c=qf[t]||"Primary",u=Jf[r]||Jf.medium,p=o||u.thickness,m=null!=e,f=m?Math.min(100,Math.max(0,e)):0,g=(u.diameter-p)/2,x=2*Math.PI*g,b=m?x-f/100*x:.75*x,v="var(--Buttons-"+c+"-Border)",y="cp-grad-"+a().replace(/:/g,"");return ce(h,{role:"progressbar","aria-valuenow":m?Math.round(f):void 0,"aria-valuemin":m?0:void 0,"aria-valuemax":m?100:void 0,"aria-label":m?Math.round(f)+"% progress":"Loading",className:"circular-progress circular-progress-"+r+" circular-progress-"+t+(m?" circular-progress-value":" circular-progress-indeterminate")+" "+l,sx:{position:"relative",display:"inline-flex",alignItems:"center",justifyContent:"center",width:u.diameter+"px",height:u.diameter+"px",flexShrink:0,...!m&&{animation:"circular-progress-spin 1.2s linear infinite","@keyframes circular-progress-spin":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(360deg)"}}},...s},...d,children:[ce("svg",{viewBox:"0 0 "+u.diameter+" "+u.diameter,width:u.diameter,height:u.diameter,style:{position:"absolute",top:0,left:0,transform:"rotate(-90deg)"},children:[de("defs",{children:ce("linearGradient",{id:y,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[de("stop",{offset:"0%",stopColor:v,stopOpacity:"0"}),de("stop",{offset:"100%",stopColor:v,stopOpacity:"1"})]})}),de("circle",{cx:u.diameter/2,cy:u.diameter/2,r:g,fill:"none",stroke:"var(--Border-Variant)",strokeWidth:p,className:"circular-progress-track"}),de("circle",{cx:u.diameter/2,cy:u.diameter/2,r:g,fill:"none",stroke:"url(#"+y+")",strokeWidth:p,strokeDasharray:x,strokeDashoffset:b,strokeLinecap:"round",className:"circular-progress-indicator",style:{transition:m?"stroke-dashoffset 0.4s ease":"none"}})]}),(n||i)&&m&&de(h,{className:"circular-progress-label","aria-hidden":"true",sx:{position:"relative",zIndex:1,fontSize:u.fontSize,fontWeight:700,fontFamily:"inherit",lineHeight:1,color:"var(--Text)",userSelect:"none"},children:i||Math.round(f)+"%"})]})}const $f=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Zf=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function _f({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function eg({color:e,selected:t,onClick:r}){const o=$f(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function tg(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(!1),[l,s]=r(65),[d,c]=r(!1),[u,p]=r(null),[m,f]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Circular Progress"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:u,children:de(Yf,{color:e,size:o,value:i?l:void 0,showValue:i&&d})}),de(Ni,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),i&&(t.push("value={"+l+"}"),d&&t.push("showValue")),0===t.length?"<CircularProgress />":"<CircularProgress\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:u,onThemeChange:p,surface:m,onSurfaceChange:f})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Zf.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(eg,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(_f,{label:$f(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Determinate"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show a static arc at a specific value"})]}),de(_i,{checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Determinate"})]}),i&&ce(ue,{children:[de(h,{sx:{mt:2},children:de(cs,{label:"Value",min:0,max:100,value:l,onChange:(e,t)=>s(t),size:"small",valueLabelDisplay:"auto"})}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Label"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Center percentage text"})]}),de(_i,{checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Show label"})]})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Role:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'role="progressbar"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Determinate:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'aria-valuenow, aria-valuemin="0", aria-valuemax="100"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Indeterminate:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'aria-label="Loading" (no value attributes)'})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Label:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Center percentage label is aria-hidden — screen readers use aria-valuenow."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Token Reference"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Track (back circle):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Border-Variant)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Fill (progress arc):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Buttons-{Color}-Border)"})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Center label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Text)"})]})]})]})]})})})]})})})]})]})}const rg={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},og={small:{height:"4px",borderRadius:"2px"},medium:{height:"6px",borderRadius:"3px"},large:{height:"8px",borderRadius:"4px"}};function ng({value:e,color:t="primary",size:r="medium",className:o="",sx:n={},...i}){const a=rg[t]||"Primary",l=og[r]||og.medium,s=null!=e,d=s?Math.min(100,Math.max(0,e)):0,c="var(--Buttons-"+a+"-Border)";return de(h,{role:"progressbar","aria-valuenow":s?Math.round(d):void 0,"aria-valuemin":s?0:void 0,"aria-valuemax":s?100:void 0,"aria-label":s?Math.round(d)+"% progress":"Loading",className:"linear-progress linear-progress-"+r+" linear-progress-"+t+(s?" linear-progress-determinate":" linear-progress-indeterminate")+" "+o,sx:{position:"relative",width:"100%",height:l.height,borderRadius:l.borderRadius,backgroundColor:"var(--Border-Variant)",overflow:"hidden",flexShrink:0,...n},...i,children:de(h,{className:"linear-progress-bar",sx:{position:"absolute",top:0,left:0,height:"100%",borderRadius:"inherit",backgroundColor:c,...s?{width:d+"%",transition:"width 0.4s ease"}:{width:"40%",animation:"linear-progress-slide 1.5s ease-in-out infinite","@keyframes linear-progress-slide":{"0%":{left:"-40%",width:"40%"},"50%":{left:"30%",width:"50%"},"100%":{left:"100%",width:"40%"}}}}})})}const ig=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",ag=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function lg({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function sg({color:e,selected:t,onClick:r}){const o=ig(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function dg(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(!1),[l,s]=r(65),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Linear Progress"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:400},children:de(ng,{color:e,size:o,value:i?l:void 0})})}),de(Ni,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),i&&t.push("value={"+l+"}"),0===t.length?"<LinearProgress />":"<LinearProgress\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:ag.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(sg,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(lg,{label:ig(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Determinate"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show a static bar at a specific value"})]}),de(_i,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Determinate"})]}),i&&de(h,{sx:{mt:2},children:de(cs,{label:"Value",min:0,max:100,value:l,onChange:(e,t)=>s(t),size:"small",valueLabelDisplay:"auto"})})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="progressbar"'},{label:"Determinate",value:'aria-valuenow, aria-valuemin="0", aria-valuemax="100"'},{label:"Indeterminate",value:'aria-label="Loading" (no value attributes)'},{label:"Track",value:"var(--Border-Variant)"},{label:"Fill",value:"var(--Buttons-{Color}-Border)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const cg=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]}],ug=["photo","icon","initials"],pg={photo:"Photo",icon:"Icon",initials:"Initials"},hg=["xxx-small","xx-small","x-small","small","medium","large","x-large","xx-large"],mg={"xxx-small":"XXXS","xx-small":"XXS","x-small":"XS",small:"Small",medium:"Medium",large:"Large","x-large":"XL","xx-large":"XXL"};function fg({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function gg({color:e,selected:t,onClick:r}){const o=(n=e)?n.charAt(0).toUpperCase()+n.slice(1):"";var n;return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function xg(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r("initials"),[l,s]=r(!1),[d,c]=r(!1),[u,p]=r(!1),[m,f]=r(null),[g,x]=r("Surface"),b="photo"===i,v=()=>{const t={size:o,clickable:l,insideButton:d};return b||(t.color=e),"initials"===i&&(t.initials="LN"),"photo"===i&&(t.src="https://i.pravatar.cc/150?img=3",t.alt="User avatar"),t};return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Avatar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:m,surface:g,children:u?ce(Jo,{max:3,size:o,children:[de(qo,{...v()}),de(qo,{color:e,size:o,initials:"AB"}),de(qo,{color:e,size:o,initials:"CD"}),de(qo,{color:e,size:o,initials:"EF"})]}):de(qo,{...v()})}),de(Ni,{code:(()=>{const t=[];return b||"default"===e||t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),"initials"===i&&t.push('initials="LN"'),"photo"===i&&t.push('src="..." alt="User avatar"'),l&&t.push("clickable onClick={handleClick}"),d&&t.push("insideButton"),u?"<AvatarGroup max={3}>\n <Avatar "+t.join(" ")+' />\n <Avatar initials="AB" />\n <Avatar initials="CD" />\n <Avatar initials="EF" />\n</AvatarGroup>':"<Avatar "+t.join(" ")+" />"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:m,onThemeChange:f,surface:g,onSurfaceChange:x})}),ce(h,{sx:{opacity:b?.4:1,pointerEvents:b?"none":"auto"},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:cg.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(gg,{color:r,selected:e===r,onClick:t},r))})]},r.label))}),b&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:8},children:"Color is ignored when the avatar shows a photo — the image carries the visual."})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:hg.map(e=>de(fg,{label:mg[e],selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"CONTENT"}),de(B,{direction:"row",spacing:1,children:ug.map(e=>de(fg,{label:pg[e],selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clickable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Interactive with hover/focus states"})]}),de(_i,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Clickable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Inside Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Adds 2px horizontal margin so the avatar sits cleanly in a Button"})]}),de(_i,{variant:"default-outline",checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Inside Button"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Group"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show as AvatarGroup with overflow"})]}),de(_i,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Show group"})]})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="img" (static) or role="button" (clickable)'},{label:"Label",value:'aria-label from alt, initials, or "Avatar"'},{label:"Image",value:"alt text on <img>. Falls back to initials or icon on error."},{label:"Clickable",value:"Rendered as <button>. Focus ring: 3px solid var(--Focus-Visible)."},{label:"Group",value:'role="group" aria-label="Avatar group, N avatars"'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const bg=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",vg=["primary","secondary","tertiary","neutral","info","success","warning","error"];function yg({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)",fontSize:"11px",fontWeight:700},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function Sg({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(yg,{ratio:t,threshold:r})]})}function kg({color:e,selected:t,onClick:r}){const o=bg(e);return de(w,{title:o,arrow:!0,children:de(h,{onClick:()=>r(e),role:"button","aria-label":"Select "+o+" color","aria-pressed":t,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:24,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})})}function Bg({label:e,selected:t,onClick:r}){return de(h,{component:"button",onClick:r,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",cursor:"pointer",border:"2px solid var(--Buttons-Primary-Button)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:t?"var(--Buttons-Primary-Button)":"transparent",color:t?"var(--Buttons-Primary-Text)":"var(--Text)",padding:"4px 12px",fontSize:"14px",fontFamily:"inherit",fontWeight:500,whiteSpace:"nowrap",flexShrink:0,transition:"background-color 0.15s ease, color 0.15s ease","&:hover":{backgroundColor:t?"var(--Buttons-Primary-Hover)":"var(--Surface-Dim)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:e})}function wg(){const[e,t]=r(0),[o,n]=r("solid"),[a,l]=r("primary"),[s,d]=r("medium"),[c,u]=r("5"),[p,m]=r(!1),[f,g]=r(!1),[x,S]=r({}),k=()=>"solid"===o?a:a+"-"+o,w=()=>{if(p)return;const e=parseInt(c,10);return isNaN(e)||String(e)!==c.trim()?c||void 0:e};i(()=>{const e=bg(a),t={};"solid"===o?(t.badgeBg=Gi("--Buttons-"+e+"-Button"),t.badgeText=Gi("--Buttons-"+e+"-Text"),t.badgeBorder=null):"outline"===o?(t.badgeBg=Gi("--Background"),t.badgeText=Gi("--Text"),t.badgeBorder=Gi("--Buttons-"+e+"-Border")):"light"===o&&(t.badgeBg=Gi("--Buttons-"+e+"-Button"),t.badgeText=Gi("--Buttons-"+e+"-Text"),t.badgeBorder=Gi("--Buttons-"+e+"-Border")),t.background=Gi("--Background"),t.focusVisible=Gi("--Focus-Visible"),S(t)},[o,a]);const C={small:{badge:"16px",dot:"8px",font:"10px"},medium:{badge:"20px",dot:"10px",font:"12px"},large:{badge:"24px",dot:"12px",font:"14px"}};return ce(h,{sx:{width:"100%"},children:[de(Jr,{style:{marginBottom:8},children:"Badge"}),de(co,{color:"quiet",style:{marginBottom:24},children:"Small label attached to an element showing status or count. Solid, outline, and light variants across all 8 colors."}),ce(N,{value:e,onChange:(e,r)=>t(r),sx:{borderBottom:"1px solid var(--Border)",mb:0},children:[de(H,{label:"Playground"}),de(H,{label:"Accessibility"})]}),0===e&&ce(I,{container:!0,sx:{minHeight:400},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"calc((100vw - 432px) / 2)"},flexShrink:0},children:[de(h,{sx:{p:4,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",minHeight:200,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)"},children:ce(B,{direction:"row",spacing:6,alignItems:"center",children:[de(en,{variant:k(),size:s,badgeContent:w(),dot:p,showZero:f,children:de(dr,{sx:{fontSize:32,color:"var(--Text-Quiet)"}})}),de(en,{variant:k(),size:s,badgeContent:w(),dot:p,showZero:f,children:de(Ae,{sx:{fontSize:32,color:"var(--Text-Quiet)"}})}),de(en,{variant:k(),size:s,badgeContent:w(),dot:p,showZero:f,children:de(Re,{sx:{fontSize:32,color:"var(--Text-Quiet)"}})})]})}),de(Ni,{code:(()=>{const e=['variant="'+k()+'"','size="'+s+'"'];if(p)e.push("dot");else{const t=w();"number"==typeof t?e.push("badgeContent={"+t+"}"):t&&e.push('badgeContent="'+t+'"')}return f&&e.push("showZero"),"<Badge "+e.join(" ")+">\n <MailIcon />\n</Badge>"})(),language:"JSX",sx:{borderRadius:0,borderBottom:"1px solid var(--Border)"}})]}),ce(I,{item:!0,sx:{width:{xs:"calc(100vw - 432px)",md:"calc((100vw - 432px) / 2)"},flexShrink:0,p:3,backgroundColor:"var(--Container)",overflowY:"auto"},children:[de(Yr,{children:"Playground"}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,flexWrap:"wrap",sx:{gap:1},children:["solid","outline","light"].map(e=>de(Bg,{label:bg(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:vg.map(e=>de(kg,{color:e,selected:a===e,onClick:l},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Bg,{label:bg(e),selected:s===e,onClick:()=>d(e)},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Badge ",C[s]?.badge," · Dot ",C[s]?.dot," · Font ",C[s]?.font]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BADGE CONTENT"}),de(y,{size:"small",value:c,onChange:e=>u(e.target.value),placeholder:"Number or text",disabled:p,sx:{width:"160px","& .MuiOutlinedInput-root":{fontFamily:"inherit",fontSize:"14px",backgroundColor:"var(--Background)","& fieldset":{borderColor:"var(--Border)"},"&:hover fieldset":{borderColor:"var(--Border)"},"&.Mui-focused fieldset":{borderColor:"var(--Buttons-Primary-Border)"}},"& .MuiOutlinedInput-input":{color:"var(--Text)",padding:"6px 12px"}}})]}),ce(h,{sx:{mt:3},children:[de(v,{control:de(b,{checked:p,onChange:e=>m(e.target.checked),size:"small"}),label:de(ao,{children:"Dot (no content)"})}),de(v,{control:de(b,{checked:f,onChange:e=>g(e.target.checked),size:"small"}),label:de(ao,{children:"Show zero"})})]})]})]}),1===e&&ce(h,{sx:{p:4},children:[de(Yr,{children:"Accessibility Requirements"}),ce(ao,{color:"quiet",style:{marginBottom:32},children:["Based on current Playground settings: ",o," · ",a," · ",s]}),ce(B,{spacing:4,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Badge Text Contrast"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Badge text must have ≥ 4.5:1 contrast against badge background (WCAG 1.4.3 AA)"}),de(Sg,{label:"Badge Text vs. Badge Background",ratio:ji(x.badgeText,x.badgeBg),threshold:4.5,note:"solid"===o?"var(--Buttons-{C}-Text) vs var(--Buttons-{C}-Button)":"outline"===o?"var(--Text) vs var(--Background)":"var(--Buttons-{C}-Text) vs var(--Buttons-{C}-Button)"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Badge Visibility"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Badge background (or border) must have ≥ 3:1 contrast against page background (WCAG 1.4.11)"}),(()=>{const e=ji(x.badgeBg,x.background),t=x.badgeBorder?ji(x.badgeBorder,x.background):null;return de(Sg,{label:"Badge vs. Page Background",ratio:(r=e,n=t,r||n?r?n?parseFloat(r)>=parseFloat(n)?r:n:r:n:null),threshold:3.1,note:"outline"===o?"Border "+(t||"--")+":1 — outline relies on border contrast":"BG "+(e||"--")+":1"});var r,n})()]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Badge Sizing"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Badge dimensions per size setting"}),de(h,{sx:{display:"flex",justifyContent:"space-between",py:1.5,borderBottom:"1px solid var(--Border)"},children:ce(h,{children:[ce(ao,{children:["Badge height (",s,")"]}),ce(bo,{style:{color:"var(--Text-Quiet)"},children:[C[s]?.badge," height · ",C[s]?.font," font · pill shape"]})]})}),de(h,{sx:{display:"flex",justifyContent:"space-between",py:1.5,borderBottom:"1px solid var(--Border)"},children:ce(h,{children:[ce(ao,{children:["Dot size (",s,")"]}),ce(bo,{style:{color:"var(--Text-Quiet)"},children:[C[s]?.dot," diameter circle"]})]})})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA & Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{style:{display:"block",marginBottom:2},children:"Screenreader support:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'MUI Badge renders badge content in a visually-hidden span for assistive technology. Numeric content is announced (e.g. "5 notifications").'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{style:{display:"block",marginBottom:2},children:"Dot variant:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Dot badges are purely decorative. Ensure the parent element conveys status to assistive tech via aria-label or similar."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{style:{display:"block",marginBottom:2},children:"Max overflow:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'When content exceeds max (default 99), displays "99+" visually but announces the actual number to screenreaders.'})]})]})]})]})]})]})}const Cg=e=>e.charAt(0).toUpperCase()+e.slice(1);function Tg(e){return e&&"default"!==e&&"border-variant"!==e?"border"===e?"var(--Border)":"var(--Icons-"+Cg(e)+")":"var(--Border-Variant)"}function Ig(e,t){const r=e&&!["default","border","border-variant"].includes(e)?Cg(e):"Default",o=Tg(e);return"light"===t?{bg:"var(--Tag-"+r+"-BG)",text:"var(--Tag-"+r+"-Text)",border:"1px solid "+o}:{bg:"var(--Background)",text:"var(--Text)",border:"1px solid "+o}}const Ag={small:1,medium:2,large:4};function zg({color:e="default",orientation:t="horizontal",size:r="small",children:o,indicatorText:n,indicatorStyle:i="outline",textAlign:a="center",className:l="",sx:s={},...d}){const c=Tg(e),u=Ag[r]||Ag.small,p=!(!o&&!n),m=o||n,f="vertical"===t;if(f&&!p)return de(h,{role:"separator","aria-orientation":"vertical",className:"divider-vertical divider-"+e+" "+l,sx:{display:"inline-block",width:u+"px",alignSelf:"stretch",minHeight:24,backgroundColor:c,flexShrink:0,...s},...d});if(f&&p){const t=Ig(e,i),r="top"===a?"0 0 10%":"1 1 auto",o="top"===a?"1 1 auto":"bottom"===a?"0 0 10%":"1 1 auto";return ce(h,{role:"separator","aria-orientation":"vertical",className:"divider-vertical divider-"+e+" divider-indicator "+l,sx:{display:"inline-flex",flexDirection:"column",alignItems:"center",alignSelf:"stretch",minHeight:24,flexShrink:0,...s},...d,children:[de(h,{sx:{flex:r,width:u+"px",backgroundColor:c}}),de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,my:1,px:.75,py:.5,borderRadius:"12px",fontSize:"11px",fontWeight:500,fontFamily:"inherit",lineHeight:1.2,whiteSpace:"nowrap",backgroundColor:t.bg,color:t.text,border:t.border,boxSizing:"border-box"},children:m}),de(h,{sx:{flex:o,width:u+"px",backgroundColor:c}})]})}if(!p)return de(h,{role:"separator","aria-orientation":"horizontal",className:"divider-horizontal divider-"+e+" "+l,sx:{width:"100%",height:u+"px",backgroundColor:c,flexShrink:0,...s},...d});const g=Ig(e,i),x="left"===a?"0 0 10%":"1 1 auto",b="left"===a?"1 1 auto":"right"===a?"0 0 10%":"1 1 auto";return ce(h,{role:"separator","aria-orientation":"horizontal",className:"divider-horizontal divider-"+e+" divider-indicator "+l,sx:{display:"flex",alignItems:"center",width:"100%",...s},...d,children:[de(h,{sx:{flex:x,height:u+"px",backgroundColor:c}}),de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,mx:2,px:1.5,py:.5,borderRadius:"12px",fontSize:"12px",fontWeight:500,fontFamily:"inherit",lineHeight:1.2,whiteSpace:"nowrap",backgroundColor:g.bg,color:g.text,border:g.border,boxSizing:"border-box"},children:m}),de(h,{sx:{flex:b,height:u+"px",backgroundColor:c}})]})}const Rg={eyebrow:To,title:co,secondary:lo},Eg={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info-Medium",success:"Success-Medium",warning:"Warning-Medium",error:"Error-Medium"},Pg={primary:"Primary-Light",secondary:"Secondary-Light",tertiary:"Tertiary-Light",neutral:"Neutral-Light",info:"Info-Light",success:"Success-Light",warning:"Warning-Light",error:"Error-Light"},Og={small:{py:.5,px:1.5,fontSize:"13px",iconSize:16,decoratorSize:28,gap:1,checkSize:"small"},medium:{py:1,px:1,fontSize:"14px",iconSize:20,decoratorSize:36,gap:1.5,checkSize:"small"},large:{py:1.5,px:2.5,fontSize:"16px",iconSize:24,decoratorSize:40,gap:2,checkSize:"medium"}};function Lg({children:e,size:t="medium",isButton:r=!1,onAction:o,ariaLabel:n}){return de(h,r?{component:"button",role:"button",tabIndex:0,"aria-label":n||"Action",onClick:e=>{e.stopPropagation(),o?.(e)},onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),e.stopPropagation(),o?.(e))},className:"list-item-decorator-button",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,padding:0,border:"none",backgroundColor:"transparent",borderRadius:"50%",cursor:"pointer",color:"inherit",transition:"background-color 0.15s ease","&:hover":{backgroundColor:"rgba(128,128,128,0.15)"},"&:active":{backgroundColor:"rgba(128,128,128,0.25)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},children:e}:{className:"list-item-decorator",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0},children:e})}function Mg({children:e,startDecorator:t,endDecorator:r,startDecoratorIsButton:o=!1,endDecoratorIsButton:n=!1,onStartDecoratorAction:i,onEndDecoratorAction:a,startDecoratorAriaLabel:l,endDecoratorAriaLabel:s,size:d="medium",variant:c="default",color:u,eyebrow:p,overline:m,secondary:f,clickable:g=!1,disabled:x=!1,selected:v=!1,selectionMode:y="none",onSelect:S,onClick:k,bottomBorder:B=!1,rightBorder:w=!1,sx:C={},...T}){const I=Og[d]||Og.medium,A=g||!!k,z="checkbox"===y||"radio"===y,R=(A||z)&&!x,E=e=>{x||(z&&S?.(e),k?.(e))};return ce(h,{component:"li",role:z?"option":A?"button":"listitem",tabIndex:R?0:void 0,"aria-disabled":x||void 0,"aria-selected":z?v:v||void 0,"aria-checked":"checkbox"===y?v:void 0,onClick:E,onKeyDown:R?e=>{x||"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),E(e))}:void 0,className:"list-item"+(v?" list-item-selected":"")+(x?" list-item-disabled":"")+(A?" list-item-clickable":"")+(z?" list-item-selectable":""),sx:{display:"flex",flexDirection:"row",alignItems:"flex-start",justifyContent:"flex-start",width:"100%",boxSizing:"border-box",gap:"var(--Sizing-1-and-Half)",py:I.py,px:I.px,minHeight:"32px",fontSize:I.fontSize,fontFamily:"inherit",color:"var(--Text)",listStyle:"none",cursor:R?"pointer":"default",opacity:x?.5:1,position:"relative",transition:"background-color 0.15s ease, box-shadow 0.15s ease",...A?{border:"1px solid var(--Border)",boxShadow:"var(--Effect-Level-1)",padding:"var(--Sizing-1)",borderRadius:"var(--Input-Radius)"}:{},...!A&&B?{borderBottom:"1px solid var(--Border-Variant)"}:{},...!A&&w?{borderRight:"1px solid var(--Border-Variant)"}:{},backgroundColor:v?"var(--Hover)":"transparent","&:hover":R?{backgroundColor:"var(--Hover)",boxShadow:"var(--Effect-Level-2)"}:{},"&:active":R?{backgroundColor:"var(--Pressed)",boxShadow:"var(--Effect-Level-1)"}:{},"&:focus-visible":{outline:"none"},"&:focus-visible::after":{content:'""',position:"absolute",inset:"1px",border:"3px solid var(--Focus-Visible)",borderRadius:"var(--Input-Inner-Focus-Visible)",pointerEvents:"none"},...C},...T,children:["checkbox"===y&&de(b,{checked:v,disabled:x,size:I.checkSize,tabIndex:-1,onClick:e=>e.stopPropagation(),onChange:()=>S?.(),sx:{p:0,mr:0,color:"inherit","&.Mui-checked":{color:"inherit"}},inputProps:{"aria-label":"Select "+("string"==typeof e?e:"item")}}),"radio"===y&&de(P,{checked:v,disabled:x,size:I.checkSize,tabIndex:-1,onClick:e=>e.stopPropagation(),onChange:()=>S?.(),sx:{p:0,mr:0,color:"inherit","&.Mui-checked":{color:"inherit"}},inputProps:{"aria-label":"Select "+("string"==typeof e?e:"item")}}),t&&de(Lg,{size:d,isButton:o,onAction:i,ariaLabel:l,children:t}),(()=>{const t=Rg,r=p??m,o={display:"block",width:"100%",wordBreak:"break-word",overflowWrap:"anywhere"};return ce(h,{sx:{flex:"1 1 auto",width:"100%",minWidth:0,display:"flex",flexDirection:"column",gap:0},children:[r&&de(t.eyebrow,{style:{...o,color:"var(--Quiet)"},children:r}),null!=e&&de(t.title,{style:{...o,color:"var(--Text)"},children:e}),f&&de(t.secondary,{style:{...o,color:"var(--Quiet)"},children:f})]})})(),r&&de(Lg,{size:d,isButton:n,onAction:a,ariaLabel:s,children:r})]})}function Wg({children:e,items:r,variant:o="default",color:n="primary",size:i="medium",orientation:a="vertical",dividers:l=!1,selectionMode:s="none",selectedIndices:d=[],onSelectionChange:c,clickable:u=!1,component:p="ul",className:m="",sx:f={},...g}){const x="horizontal"===a,b="checkbox"===s||"radio"===s,v="light"===o,y="default"===o,S={};"solid"===o&&Eg[n]?S["data-theme"]=Eg[n]:v&&Pg[n]&&(S["data-theme"]=Pg[n]);return de(h,{component:p,role:b?"listbox":"list","aria-multiselectable":"checkbox"===s||void 0,...S,className:"list-container list-"+o+" list-"+n+" "+m,sx:{display:"flex",flexDirection:x?"row":"column",boxSizing:"border-box",alignItems:"stretch",gap:u?"var(--Sizing-1)":0,m:0,p:y?0:1,backgroundColor:y?"transparent":"var(--Background)",color:"var(--Text)",borderRadius:y?0:"var(--Style-Border-Radius)",width:"100%",listStyle:"none",...x?{"& > .list-item":{flex:"1 1 0",width:"auto"}}:{},...f},...g,children:(()=>{if(r&&r.length>0){const e=[];return r.forEach((t,a)=>{e.push(de(Mg,{size:i,variant:o,color:n,startDecorator:t.startDecorator,endDecorator:t.endDecorator,startDecoratorIsButton:t.startDecoratorIsButton,endDecoratorIsButton:t.endDecoratorIsButton,onStartDecoratorAction:t.onStartDecoratorAction,onEndDecoratorAction:t.onEndDecoratorAction,startDecoratorAriaLabel:t.startDecoratorAriaLabel,endDecoratorAriaLabel:t.endDecoratorAriaLabel,eyebrow:t.eyebrow??t.overline,secondary:t.secondary,clickable:u||t.clickable,disabled:t.disabled,bottomBorder:t.bottomBorder,rightBorder:t.rightBorder,selected:b?d.includes(a):t.selected,selectionMode:s,onSelect:()=>(e=>{if(c)if("radio"===s)c([e]);else{const t=d.includes(e)?d.filter(t=>t!==e):[...d,e];c(t)}})(a),onClick:t.onClick,children:t.label||t.children},"item-"+a)),l&&a<r.length-1&&e.push(de(h,{component:"li",role:"separator","aria-hidden":"true",sx:x?{width:"1px",alignSelf:"stretch",backgroundColor:"var(--Border)",flexShrink:0}:{height:"1px",backgroundColor:"var(--Border)"}},"div-"+a))}),e}if(e){const r=t.Children.toArray(e);if(!l)return r;const o=[];return r.forEach((e,t)=>{o.push(e),t<r.length-1&&o.push(de(h,{component:"li",role:"separator","aria-hidden":"true",sx:x?{width:"1px",alignSelf:"stretch",backgroundColor:"var(--Border)",flexShrink:0}:{height:"1px",backgroundColor:"var(--Border)"}},"div-"+t))}),o}return null})()})}const Dg={small:{py:"4px",px:"8px",fontSize:"13px",headerFontSize:"12px"},medium:{py:"8px",px:"12px",fontSize:"14px",headerFontSize:"13px"},large:{py:"12px",px:"16px",fontSize:"16px",headerFontSize:"14px"}};function Fg({children:e,columns:t,rows:r,footerRows:o,variant:n="default",color:i="primary",size:a="medium",stripe:l="none",stickyHeader:s=!1,stickyFooter:d=!1,className:c="",sx:u={},...p}){const m=Dg[a]||Dg.medium,f="solid"===n,g="outlined"===n,x="light"===n,b=(e=>e.charAt(0).toUpperCase()+e.slice(1))(i),v=g?"1px solid var(--Buttons-"+b+"-Border)":"none",y={};f&&(y["data-theme"]=b+"-Medium");const S=()=>{const e={fontWeight:600,fontSize:m.headerFontSize,textAlign:"left",padding:m.py+" "+m.px,borderBottom:"2px solid var(--Border)",color:"var(--Text)",whiteSpace:"nowrap"};return x?(e.backgroundColor="var(--Buttons-"+b+"-Button)",e.color="var(--Buttons-"+b+"-Text)"):e.backgroundColor=f?"var(--Hover)":"var(--Background)",s&&(e.position="sticky",e.top=0,e.zIndex=2),e},k=()=>{const e={fontWeight:600,fontSize:m.headerFontSize,textAlign:"left",padding:m.py+" "+m.px,borderTop:"2px solid var(--Border)",color:"var(--Text)",whiteSpace:"nowrap"};return x?(e.backgroundColor="var(--Buttons-"+b+"-Button)",e.color="var(--Buttons-"+b+"-Text)"):e.backgroundColor=f?"var(--Hover)":"var(--Background)",d&&(e.position="sticky",e.bottom=0,e.zIndex=2),e},B=e=>"none"===l?"Surface":"odd"===l?e%2==0?"Surface":"Surface-Dim":"even"===l&&e%2==0?"Surface-Dim":"Surface",w=()=>({padding:m.py+" "+m.px,fontSize:m.fontSize,color:"var(--Text)",borderBottom:"1px solid var(--Border)",textAlign:"left"});return de(h,{className:"table-wrapper table-"+n+(f||x||g?" table-"+i:"")+" "+c,...y,sx:{width:"100%",overflow:"auto",border:v,borderRadius:g||x?"var(--Style-Border-Radius)":0,...u},children:de(h,{component:"table",sx:{width:"100%",borderCollapse:"collapse",tableLayout:"fixed",fontFamily:"inherit","& thead th":S(),"& tbody td":w(),"& tfoot td, & tfoot th":k(),...s?{"& thead th":{...S(),position:"sticky",top:0,zIndex:2}}:{},...d?{"& tfoot td, & tfoot th":{...k(),position:"sticky",bottom:0,zIndex:2}}:{}},...p,children:t&&r?t&&r?ce(ue,{children:[de(h,{component:"thead",children:de(h,{component:"tr",children:t.map((e,t)=>de(h,{component:"th",sx:{...S(),...e.width?{width:e.width}:{},...e.align?{textAlign:e.align}:{}},children:e.label||e.header||e},"h-"+t))})}),de(h,{component:"tbody",children:r.map((e,r)=>de(h,{component:"tr","data-surface":B(r),sx:{backgroundColor:"var(--"+B(r)+")"},children:(Array.isArray(e)?e:t.map(t=>e[t.field||t.key])).map((e,o)=>de(h,{component:"td",sx:{...w(),...t[o]&&t[o].align?{textAlign:t[o].align}:{}},children:e},"c-"+r+"-"+o))},"r-"+r))}),o&&o.length>0&&de(h,{component:"tfoot",children:o.map((e,r)=>de(h,{component:"tr",children:(Array.isArray(e)?e:t.map(t=>e[t.field||t.key])).map((e,o)=>de(h,{component:"td",sx:{...k(),...t[o]&&t[o].align?{textAlign:t[o].align}:{}},children:e},"fc-"+r+"-"+o))},"f-"+r))})]}):null:e})})}const Ng={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info-Medium",success:"Success-Medium",warning:"Warning-Medium",error:"Error-Medium"},Hg={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Vg={small:{fontSize:"12px",py:"4px",px:"8px",maxWidth:200,arrowSize:6},medium:{fontSize:"13px",py:"6px",px:"12px",maxWidth:280,arrowSize:8},large:{fontSize:"14px",py:"8px",px:"16px",maxWidth:360,arrowSize:10}};function Qg({children:e,title:t,variant:r="solid",color:o="primary",size:n="medium",placement:i="bottom",arrow:a=!1,open:l,enterDelay:s=100,leaveDelay:d=0,describeChild:c=!1,className:u="",sx:p={},...m}){const f=Vg[n]||Vg.medium,g="solid"===r,x="light"===r,b="outline"===r,v=(e=>e.charAt(0).toUpperCase()+e.slice(1))(o),y="var(--Background)",S=void 0===l?{}:{open:l};return de(w,{title:t?de(h,{"data-theme":(g?Ng[o]:x?Hg[o]:null)||void 0,"data-surface":x?"Surface-Brightest":g?"Surface":void 0,className:"tooltip-content tooltip-"+r+" tooltip-"+o+" tooltip-"+n+" "+u,sx:{backgroundColor:"var(--Background)",color:"var(--Text)",border:b?"1px solid var(--Buttons-"+v+"-Border)":"none",borderRadius:"var(--Style-Border-Radius)",fontSize:f.fontSize,lineHeight:1.5,fontFamily:"inherit",padding:f.py+" "+f.px,maxWidth:f.maxWidth+"px",boxShadow:"0 2px 8px rgba(0,0,0,0.15)",...p},children:t}):"",placement:i,arrow:a,enterDelay:s,leaveDelay:d,describeChild:c,...S,componentsProps:{tooltip:{sx:{backgroundColor:"transparent",padding:0,maxWidth:"none",boxShadow:"none"}},arrow:{sx:{color:y,"&::before":{border:b?"1px solid var(--Buttons-"+v+"-Border)":"none",backgroundColor:y,boxSizing:"border-box"},fontSize:f.arrowSize+"px"}}},...m,children:e})}const jg={default:{theme:"App-Bar"},primary:{theme:"Primary"},"primary-light":{theme:"Primary",surface:"Surface-Brightest"},white:{theme:"Neutral",surface:"Surface-Brightest"},black:{theme:"Neutral",surface:"Surface-Dimmest"}};function Gg({children:e,onClick:t,ariaLabel:r}){return de(Tn,{iconOnly:!0,variant:"ghost",size:"medium",onClick:t,"aria-label":r,children:e})}function Ug({barColor:e="default",surface:o="Surface",loginType:n="login",menuType:i="hamburger",brandType:a="name",searchPosition:l="right",companyName:s="Company",navLinks:d=["Home","Products","About"],rightButtons:c=[],showRightButtons:u=!1,onMenuClick:p,user:m,onLogin:f,onSignOut:g,brand:x,onBrandClick:b,centerSlot:v,endSlot:y,searchValue:S,onSearchChange:k,searchPlaceholder:B="Search...",children:w,className:C="",sx:T={}}){const[I,A]=r(!1),z=jg[e]||jg.default,R=z.theme,E=z.surface||o,P="expanded"===i&&d.length>3?"hamburger":i,O=de(xs,{placeholder:B,size:"medium",value:S,onChange:k,sx:{flex:"left"===l?"0 1 400px":"0 1 280px",minWidth:0}});return ce(ue,{children:[de(h,{component:"header",role:"banner","data-theme":R,"data-surface":E,className:"appbar appbar-desktop appbar-"+e+(C?" "+C:""),sx:{display:"flex",alignItems:"center",height:64,px:2,gap:2,backgroundColor:"var(--Background)",color:"var(--Text)",boxShadow:nn,fontFamily:"inherit",...T},children:w||ce(ue,{children:["hamburger"===P&&de(Gg,{ariaLabel:"Open navigation menu",onClick:p||(()=>A(!0)),children:de(Pt,{sx:{fontSize:"inherit"}})}),de(h,void 0!==x?b?{component:"button",type:"button",onClick:b,sx:{background:"transparent",border:"none",padding:0,cursor:"pointer",color:"inherit",font:"inherit",fontWeight:700,fontSize:"18px",whiteSpace:"nowrap",flexShrink:0},children:x}:{sx:{fontWeight:700,fontSize:"18px",whiteSpace:"nowrap",flexShrink:0},children:x}:"logo"===a?{sx:{width:32,height:32,borderRadius:"6px",backgroundColor:"var(--Text)",opacity:.8,flexShrink:0},"aria-label":"Company logo"}:{sx:{fontWeight:700,fontSize:"18px",whiteSpace:"nowrap",flexShrink:0},children:s}),ce(ue,void 0!==v?{children:[de(h,{sx:{flex:1}}),de(h,{sx:{display:"flex",alignItems:"center",flexShrink:0},children:v}),de(h,{sx:{flex:1}})]}:{children:["left"===l&&O,"expanded"===P&&de(oi,{defaultValue:0,variant:"standard",color:"default",sx:{ml:2,minHeight:0},children:de(ni,{"aria-label":"Main navigation",children:d.map(e=>de(ii,{children:e},e))})}),de(h,{sx:{flex:1}}),"right"===l&&O]}),void 0!==y?de(h,{sx:{display:"flex",alignItems:"center",gap:1},children:y}):ce(ue,{children:[u&&c.length>0&&de(h,{sx:{display:"flex",alignItems:"center",gap:.5},children:c.map((e,r)=>e.raw?de(t.Fragment,{children:e.icon},r):de(Gg,{ariaLabel:e.label||"Action "+(r+1),children:e.icon},r))}),m?de(Tn,{variant:"ghost",size:"small",onClick:g,"aria-label":"Sign out",startIcon:m.photoURL?de(h,{component:"img",src:m.photoURL,alt:"",sx:{width:24,height:24,borderRadius:"50%"}}):de(pr,{sx:{fontSize:24}}),children:m.displayName?.split(" ")[0]||"Account"}):f?de(Tn,{variant:"default-outline",size:"small",onClick:f,children:"Login"}):"avatar"===n?de(Tn,{iconOnly:!0,variant:"ghost",size:"medium","aria-label":"Account",children:de(pr,{sx:{fontSize:28}})}):null]})]})}),de(mu,{open:I,onClose:()=>A(!1),anchor:"left",size:"small",children:de(h,{component:"nav","aria-label":"Main navigation",sx:{display:"flex",flexDirection:"column",gap:.5,py:1},children:d.map(e=>de(Tn,{variant:"ghost",size:"medium",onClick:()=>A(!1),sx:{justifyContent:"flex-start",width:"100%"},children:e},e))})})]})}function Xg({mobileVariant:e="search",barColor:t="default",surface:o="Surface",title:n="Page Title",subtitle:i="Subtitle text",actionIcon:a,companyName:l="Company",navLinks:s=["Home","Products","About"],className:d="",sx:c={}}){const[u,p]=r(!1),m=jg[t]||jg.default,f=m.theme,g=m.surface||o,x={backgroundColor:"var(--Background)",color:"var(--Text)",boxShadow:nn,fontFamily:"inherit",width:"100%",maxWidth:420,...c},b={"data-theme":f,"data-surface":g},v=de(mu,{open:u,onClose:()=>p(!1),anchor:"left",size:"small",children:de(h,{component:"nav","aria-label":"Main navigation",sx:{display:"flex",flexDirection:"column",gap:.5,py:1},children:s.map(e=>de(Tn,{variant:"ghost",size:"medium",onClick:()=>p(!1),sx:{justifyContent:"flex-start",width:"100%"},children:e},e))})});return"search"===e?ce(ue,{children:[ce(h,{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-search appbar-"+t+" "+d,...b,sx:{...x,display:"flex",alignItems:"center",height:64,px:1.5,gap:1.5},children:[de(Gg,{ariaLabel:"Open navigation menu",onClick:()=>p(!0),children:de(Pt,{sx:{fontSize:"inherit"}})}),de(xs,{placeholder:"Search "+l,size:"small",sx:{flex:1,minWidth:0}}),de(Tn,{iconOnly:!0,variant:"ghost",size:"medium","aria-label":"Account",children:de(pr,{sx:{fontSize:28}})})]}),v]}):ce(h,"small"===e?{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-small appbar-"+t+" "+d,...b,sx:{...x,display:"flex",alignItems:"center",height:64,px:1.5,gap:1},children:[de(Gg,{ariaLabel:"Back",children:de(ur,{sx:{fontSize:"inherit"}})}),ce(h,{sx:{flex:1,minWidth:0},children:[de(h,{sx:{fontWeight:600,fontSize:"16px",lineHeight:1.3,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:n}),i&&de(h,{sx:{fontSize:"12px",opacity:.7,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:i})]}),a&&de(Gg,{ariaLabel:"Action",children:a})]}:"medium"===e?{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-medium appbar-"+t+" "+d,...b,sx:{...x,px:1.5,pb:2},children:[ce(h,{sx:{display:"flex",alignItems:"center",height:56,gap:1},children:[de(Gg,{ariaLabel:"Back",children:de(ur,{sx:{fontSize:"inherit"}})}),de(h,{sx:{flex:1}}),a&&de(Gg,{ariaLabel:"Action",children:a})]}),ce(h,{sx:{px:1.5},children:[de(h,{sx:{fontWeight:600,fontSize:"24px",lineHeight:1.2},children:n}),i&&de(h,{sx:{fontSize:"14px",opacity:.7,mt:.5},children:i})]})]}:{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-large appbar-"+t+" "+d,...b,sx:{...x,px:1.5,pb:3},children:[ce(h,{sx:{display:"flex",alignItems:"center",height:56,gap:1},children:[de(Gg,{ariaLabel:"Back",children:de(ur,{sx:{fontSize:"inherit"}})}),de(h,{sx:{flex:1}}),a&&de(Gg,{ariaLabel:"Action",children:a})]}),ce(h,{sx:{px:1.5,mt:1},children:[de(h,{sx:{fontWeight:600,fontSize:"36px",lineHeight:1.1},children:n}),i&&de(h,{sx:{fontSize:"14px",opacity:.7,mt:.5},children:i})]})]})}function Kg({mode:e="desktop",...t}){return de("mobile"===e?Xg:Ug,{...t})}const qg=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Jg=["default","primary","primary-light","white","black"],Yg=["Surface","Surface-Bright","Surface-Dim","Surface-Dimmest"],$g={default:{theme:"App-Bar"},primary:{theme:"Primary"},"primary-light":{theme:"Primary",surface:"Surface-Brightest"},white:{theme:"Neutral",surface:"Surface-Brightest"},black:{theme:"Neutral",surface:"Surface-Dimmest"}};function Zg({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function _g({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(Zg,{ratio:t,threshold:r})]})}function ex({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function tx({color:e,selected:t,onClick:r}){const o=$g[e]||$g.default;return de(h,{component:"button","data-theme":o.theme,"data-surface":o.surface||"Surface",onClick:()=>r(e),"aria-label":"Select "+e,"aria-pressed":t,title:e,sx:{width:"var(--Button-Height, 36px)",height:"var(--Button-Height, 36px)",borderRadius:"4px",backgroundColor:"var(--Background)",border:t?"2px solid var(--Text)":"2px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Text)",pointerEvents:"none"}})})}function rx(){const[e,t]=r("desktop"),[o,n]=r("default"),[a,l]=r("Surface"),[s,d]=r("login"),[c,u]=r("hamburger"),[p,m]=r("name"),[f,g]=r("right"),[x,b]=r("search"),[v,y]=r(null),[S,k]=r("Surface"),[w,C]=r({}),T="desktop"===e,A=$g[o]||$g.default,z=A.theme,R=A.surface||a;return i(()=>{const e={};e.text=Gi("--Text"),e.textQuiet=Gi("--Text-Quiet"),e.background=Gi("--Background"),e.border=Gi("--Border"),e.focusVisible=Gi("--Focus-Visible"),e.hover=Gi("--Hover"),e.active=Gi("--Pressed"),C(e)},[o,a,e]),ce(h,{sx:{pb:8},children:[de(Jr,{children:"App Bar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{theme:v,children:de(h,{sx:{width:"100%",maxWidth:T?"100%":420,overflow:"hidden"},children:T?de(Ug,{barColor:o,surface:a,loginType:s,menuType:c,brandType:p,searchPosition:f,companyName:"My App",navLinks:["Home","Products","About"]}):de(Xg,{barColor:o,surface:a,mobileVariant:x,companyName:"My App",title:"Page Title",subtitle:"Subtitle text"})})}),de(Ni,{code:(()=>{if(T){const e=[];"default"!==o&&e.push('barColor="'+o+'"'),"Surface"!==a&&e.push('surface="'+a+'"'),"login"!==s&&e.push('loginType="'+s+'"'),"hamburger"!==c&&e.push('menuType="'+c+'"'),"name"!==p&&e.push('brandType="'+p+'"'),"right"!==f&&e.push('searchPosition="'+f+'"');const t=e.length?"\n "+e.join("\n ")+"\n":"";return'<AppBar mode="desktop"'+(t||" ")+'companyName="My App" />'}{const e=['mode="mobile"','mobileVariant="'+x+'"'];return"default"!==o&&e.push('barColor="'+o+'"'),"Surface"!==a&&e.push('surface="'+a+'"'),"<AppBar\n "+e.join("\n ")+'\n title="Page Title"\n/>'}})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:v,onThemeChange:y,surface:S,onSurfaceChange:k})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"MODE"}),de(B,{direction:"row",spacing:1,children:["desktop","mobile"].map(r=>de(ex,{label:qg(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BAR COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:Jg.map(e=>de(tx,{color:e,selected:o===e,onClick:n},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",marginTop:6,display:"block"},children:['data-theme="',z,'"']})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SURFACE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:Yg.map(e=>de(ex,{label:e.replace("Surface-","").replace("Surface","Default"),selected:a===e,onClick:()=>l(e)},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",marginTop:6,display:"block"},children:['data-surface="',a,'"']})]}),T&&ce(ue,{children:[ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"MENU TYPE"}),de(B,{direction:"row",spacing:1,children:["hamburger","expanded"].map(e=>de(ex,{label:qg(e),selected:c===e,onClick:()=>u(e)},e))}),de(bo,{style:{color:"var(--Text-Quiet)",marginTop:4,display:"block"},children:"Expanded auto-falls back to hamburger when nav > 3 links"})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BRAND"}),de(B,{direction:"row",spacing:1,children:["name","logo"].map(e=>de(ex,{label:qg(e),selected:p===e,onClick:()=>m(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SEARCH POSITION"}),de(B,{direction:"row",spacing:1,children:["left","right"].map(e=>de(ex,{label:qg(e),selected:f===e,onClick:()=>g(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LOGIN TYPE"}),de(B,{direction:"row",spacing:1,children:["login","avatar"].map(e=>de(ex,{label:qg(e),selected:s===e,onClick:()=>d(e)},e))})]})]}),!T&&ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"MOBILE VARIANT"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["search","small","medium","large"].map(e=>de(ex,{label:qg(e),selected:x===e,onClick:()=>b(e)},e))})]})]})}),de(ai,{value:1,children:ce(h,{sx:{p:3},children:[ce(ao,{color:"quiet",style:{marginBottom:24},children:[e," / ",o," / ",a,T?"":" / "+x,' — data-theme="',z,'" data-surface="',R,'"']}),ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Text Contrast (WCAG 1.4.3 — 4.5:1)"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"All text and icons must have 4.5:1 contrast against the AppBar background."}),de(_g,{label:"Resting: var(--Text) vs. var(--Background)",ratio:ji(w.text,w.background),threshold:4.5,note:'data-theme="'+z+'" data-surface="'+R+'"'}),de(_g,{label:"On hover: var(--Text) vs. var(--Hover)",ratio:ji(w.text,w.hover),threshold:4.5,note:"Icon buttons use var(--Hover) on hover"}),de(_g,{label:"On active: var(--Text) vs. var(--Pressed)",ratio:ji(w.text,w.active),threshold:4.5,note:"Icon buttons use var(--Pressed) on press"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Focus Indicator (WCAG 2.4.11 — 3:1)"}),de(_g,{label:"var(--Focus-Visible) vs. var(--Background)",ratio:ji(w.focusVisible,w.background),threshold:3,note:"outline: 3px solid var(--Focus-Visible); outline-offset: 1px"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Touch Target Area (WCAG 2.5.5)"}),[{label:"Icon button",size:40,note:"width: 40px, height: 40px"},{label:"AppBar (desktop)",size:64,note:"height: 64px"},{label:"AppBar (mobile)",size:64,note:"height: 64px"}].map(({label:e,size:t,note:r})=>{const o=t>=24,n=t>=44,i=t>=48;return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[ce(ao,{style:{color:"var(--Text)"},children:[e," — ",t,"px"]}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:r})]}),ce(h,{sx:{display:"flex",gap:.5,flexWrap:"wrap",justifyContent:"flex-end"},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:o?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:o?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:["Desktop ",o?"Y":"N"]}),ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:n?"var(--Tags-Success-BG)":"var(--Tags-Warning-BG)",color:n?"var(--Tags-Success-Text)":"var(--Tags-Warning-Text)"},children:["iOS ",n?"Y":"~"]}),ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:i?"var(--Tags-Success-BG)":"var(--Tags-Warning-BG)",color:i?"var(--Tags-Success-Text)":"var(--Tags-Warning-Text)"},children:["Android ",i?"Y":"~"]})]})]},e)})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Landmark:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<header role="banner">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Navigation (expanded menu):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<nav aria-label="Main navigation">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Theme + Surface:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'data-theme="'+z+'" data-surface="'+R+'"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Shadow:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"box-shadow: var(--Effect-Level-1)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Icon buttons:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"All icon buttons have aria-label. Focus visible on keyboard navigation."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Keyboard:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Tab navigates all interactive elements. Enter/Space activates buttons."})]})]})]})]})]})})]})})})]})]})}function ox({title:e="My App",mode:t="light",navItems:r=[{label:"HOME",href:"#"},{label:"ABOUT",href:"#"},{label:"SERVICES",href:"#"},{label:"CONTACT",href:"#"}],rightContent:o,sx:n={},...i}){return de($,{position:"fixed",sx:{background:"var(--Background)",color:"var(--Text)",boxShadow:"0 1px 3px rgba(0,0,0,0.1)",borderBottom:"1px solid var(--Border-Variant)",transition:"all 0.2s ease-in-out",zIndex:1201,...n},...i,children:de(F,{maxWidth:"lg",children:ce(Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",px:0},children:[de(T,{variant:"h6",sx:{fontWeight:700,color:"var(--Text)",mr:"auto",transition:"color 0.2s ease-in-out"},children:e}),de(h,{sx:{display:{xs:"none",md:"flex"},gap:3,flex:1,justifyContent:"center"},children:r.map((e,t)=>de(T,{component:"a",href:e.href,variant:"body2",sx:{textDecoration:"none",color:"var(--Text)",transition:"color 0.2s ease-in-out","&:hover":{color:"var(--Primary-Color-11)"}},children:e.label},t))}),de(B,{direction:"row",spacing:1,alignItems:"center",children:o})]})})})}const nx={default:{bg:"var(--Primary-Color-1)",fg:"var(--Primary-Color-12)"},primary:{theme:"Primary",surface:"Surface-Dim"},"primary-dark":{bg:"var(--Primary-Color-1)",fg:"var(--Primary-Color-12)"},white:{bg:"var(--Neutral-Color-11)",fg:"var(--Neutral-Color-3)"},black:{bg:"var(--Neutral-Color-1)",fg:"var(--Neutral-Color-12)"}};function ix({color:e="default",companyName:t="",year:r=(new Date).getFullYear(),rights:o="All rights reserved",children:n,className:i,style:a,...l}){const s=n??`© ${r}${t?" "+t:""}.${o?" "+o+".":""}`,d=nx[e]||nx.default,c=d.theme?{"data-theme":d.theme,"data-surface":d.surface||"Surface-Dim"}:{},u=d.theme?{background:"var(--Background)",color:"var(--Text)"}:{background:d.bg,color:d.fg};return de("div",{...c,className:["dino-copyright",i].filter(Boolean).join(" "),style:{padding:"14px 24px",textAlign:"center",...u,...a},...l,children:de(ao,{style:{color:"inherit",opacity:.85},children:s})})}const ax={default:{bg:"var(--Primary-Color-2)",fg:"var(--Primary-Color-12)"},primary:{theme:"Primary",surface:"Surface"},"primary-dark":{theme:"Primary",surface:"Surface-Dimmest"},white:{bg:"var(--Neutral-Color-12)",fg:"var(--Neutral-Color-2)"},black:{bg:"var(--Neutral-Color-1)",fg:"var(--Neutral-Color-12)"}};function lx({color:e="default",brand:t,address:r,columns:o=[],socialLinks:n=[],subscribe:i,copyrightName:a,copyrightYear:l,className:s,style:d,...c}){const u=o.slice(0,3),p=ax[e]||ax.default,h=p.theme?{"data-theme":p.theme,"data-surface":p.surface||"Surface"}:{},m=p.theme?{background:"var(--Background)",color:"var(--Text)"}:{background:p.bg,color:p.fg};return ce("footer",{...h,className:["dino-footer",s].filter(Boolean).join(" "),style:{...m,...d},...c,children:[ce("div",{style:{maxWidth:1200,margin:"0 auto",padding:"40px 24px 56px"},children:[t&&de("div",{style:{marginBottom:36},children:t}),ce("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(280px, 1fr))",gap:40},children:[de(sx,{address:r}),u.map((e,t)=>de(dx,{...e},t))]}),(n.length>0||i)&&ce("div",{style:{marginTop:48,paddingTop:32,borderTop:"1px solid rgba(255, 255, 255, 0.10)",display:"flex",flexWrap:"wrap",gap:32,alignItems:"flex-start",justifyContent:"space-between"},children:[n.length>0&&de(cx,{links:n}),i&&de(ux,{...i})]})]}),de(ix,{color:e,companyName:a,year:l})]})}function sx({address:e}){if(!e)return de("div",{});const{company:t,lines:r=[],email:o,phone:n}=e,i=[...t?[t]:[],...r,...n?[n]:[]];return ce("div",{children:[i.map((e,t)=>de(ao,{style:{color:"inherit",opacity:.85,display:"block"},children:e},t)),o&&de("div",{style:{marginTop:12},children:de(ao,{style:{color:"inherit",opacity:.85,display:"block"},children:de(Ps,{href:"mailto:"+o,color:"standard",style:{color:"inherit"},children:o})})})]})}function dx({title:e,links:t=[]}){return ce("div",{children:[e&&de(Yr,{style:{color:"inherit",marginBottom:12},children:e}),de("ul",{style:{listStyle:"none",margin:0,padding:0},children:t.map((e,t)=>de("li",{style:{marginBottom:8},children:de(Ps,{href:e.href,onClick:e.onClick,color:"standard",style:{color:"inherit",opacity:.85},children:e.label})},t))})]})}function cx({links:e}){return de("div",{style:{display:"flex",gap:16,alignItems:"center"},children:e.map((e,t)=>de("a",{href:e.url,target:"_blank",rel:"noopener noreferrer","aria-label":e.label||"Social link",style:{color:"inherit",opacity:.85,display:"inline-flex",alignItems:"center",justifyContent:"center",width:36,height:36,borderRadius:"50%",border:"1px solid rgba(255, 255, 255, 0.18)",textDecoration:"none",transition:"opacity 150ms ease, border-color 150ms ease"},onMouseEnter:e=>{e.currentTarget.style.opacity="1"},onMouseLeave:e=>{e.currentTarget.style.opacity="0.85"},children:e.icon},t))})}function ux({title:e="Stay in the loop",description:t,placeholder:o="your@email.com",buttonLabel:n="Subscribe",onSubscribe:i}){const[a,l]=r(""),[s,d]=r(!1);return ce("form",{onSubmit:async e=>{if(e&&e.preventDefault(),a&&!s){d(!0);try{await(i?.(a)),l("")}finally{d(!1)}}},style:{minWidth:260,maxWidth:360,flex:"1 1 260px"},children:[de(Yr,{style:{color:"inherit",marginBottom:6},children:e}),t&&de(ao,{style:{color:"inherit",opacity:.85,marginBottom:12,display:"block"},children:t}),ce("div",{style:{display:"flex",gap:8},children:[de(El,{type:"email",value:a,onChange:e=>l(e.target.value),placeholder:o,size:"small",fullWidth:!0,"aria-label":"Email address"}),de(Tn,{type:"submit",variant:"primary",size:"small",disabled:s||!a,children:n})]})]})}function px(e){const t=e.match(/rgba?\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)/);return t?[Number(t[1]),Number(t[2]),Number(t[3])]:null}function hx(e){return e?"#"+e.map(e=>e.toString(16).padStart(2,"0")).join(""):"—"}function mx([e,t,r]){const o=[e,t,r].map(e=>(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4));return.2126*o[0]+.7152*o[1]+.0722*o[2]}function fx({targetRef:e,label:t,deps:o=[]}){const[n,a]=r(null),[l,s]=r(null);i(()=>{if(!e.current)return;const t=requestAnimationFrame(()=>{if(!e.current)return;const t=getComputedStyle(e.current);a(px(t.backgroundColor)),s(px(t.color))});return()=>cancelAnimationFrame(t)},o);const d=function(e,t){if(!e||!t)return null;const r=mx(e),o=mx(t);return(Math.max(r,o)+.05)/(Math.min(r,o)+.05)}(n,l),c=null!==d&&d>=4.5,u=null===d?"—":null!==d&&d>=7?"AAA":c?"AA":"Fail",p=null===d?"var(--Text-Quiet)":c?"var(--Text-Success)":"var(--Text-Error)";return ce("div",{style:{display:"flex",alignItems:"center",gap:16,padding:"12px 16px",borderRadius:8,background:"var(--Container)",border:"1px solid var(--Border)"},children:[ce("div",{style:{flex:1,minWidth:0},children:[de(ao,{style:{fontWeight:600},children:t}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Background ",hx(n)," · Text ",hx(l)]})]}),ce("div",{style:{display:"flex",alignItems:"center",gap:6,borderRadius:999,padding:"4px 10px",background:"var(--Background)",border:"1px solid var(--Border)"},children:[de("span",{style:{fontWeight:700,fontSize:12,color:p},children:u}),de(bo,{style:{color:"var(--Text-Quiet)"},children:null!==d?d.toFixed(2)+":1":"—"})]})]})}const gx={company:"DinoDesign",lines:["123 Market Street","San Francisco, CA 94103"],email:"hello@dinodesign.dev",phone:"+1 (555) 010-0000"},xx=[{title:"Product",links:[{label:"Features",href:"#"},{label:"Pricing",href:"#"},{label:"Add-ons",href:"#"}]},{title:"Company",links:[{label:"About",href:"#"},{label:"Careers",href:"#"},{label:"Contact",href:"#"}]},{title:"Resources",links:[{label:"Docs",href:"#"},{label:"Changelog",href:"#"},{label:"Status",href:"#"}]}],bx=[{icon:de(hr,{fontSize:"small"}),url:"https://twitter.com",label:"Twitter"},{icon:de(mr,{fontSize:"small"}),url:"https://github.com",label:"GitHub"},{icon:de(fr,{fontSize:"small"}),url:"https://linkedin.com",label:"LinkedIn"}],vx=[{value:"default",label:"Default"},{value:"primary",label:"Primary"},{value:"primary-dark",label:"Primary Dark"},{value:"white",label:"White"},{value:"black",label:"Black"}];function yx({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Sx(){const[e,t]=r(4),[n,a]=r(!0),[l,s]=r(!0),[d,c]=r("default"),u=o(null),[p,m]=r(null),[f,g]=r(null);i(()=>{u.current&&(m({current:u.current.querySelector(".dino-footer")}),g({current:u.current.querySelector(".dino-copyright")}))},[d,e,n,l]);const x=xx.slice(0,Math.max(0,e-1)),b=n?bx:[],v=l?{title:"Stay in the loop",description:"Monthly updates on new components and tips.",onSubscribe:async e=>console.log("subscribed:",e)}:void 0;return ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Footer"}),ce(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:["Configurable 1–4 column footer. The first column is always the company address / contact. Optional ",de("code",{children:"socialLinks"})," and"," ",de("code",{children:"subscribe"})," sit above the auto-generated copyright strip."]}),de(h,{ref:u,sx:{borderRadius:1,overflow:"hidden",mb:4},children:de(lx,{color:d,address:gx,columns:x,socialLinks:b,subscribe:v,copyrightName:"DinoDesign"})}),ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:560},children:[ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLUMNS"}),de(B,{direction:"row",spacing:1,children:[1,2,3,4].map(r=>de(yx,{label:String(r),selected:e===r,onClick:()=>t(r)},r))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"First column is always the address / contact. Up to 3 more link columns."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:vx.map(e=>de(yx,{label:e.label,selected:d===e.value,onClick:()=>c(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:'"Default" hardcodes Primary tone 2 (auto-derived in a future iteration).'})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SOCIAL LINKS"}),de(ea,{label:"Show social media row",checked:n,onChange:e=>a(e.target.checked)}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["When on, the Footer renders the ",de("code",{children:"socialLinks"})," row (icons linking out). In your app, supply the icon + url pairs from your data store."]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SUBSCRIBE"}),de(ea,{label:"Show email subscribe form",checked:l,onChange:e=>s(e.target.checked)}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["When on, the Footer renders an email subscribe form. Hook it up via"," ",de("code",{children:"subscribe.onSubscribe(email)"}),"."]})]})]})}),de(ai,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[de(bo,{style:{color:"var(--Text-Quiet)"},children:"Live WCAG 2.1 contrast against the painted background. AA needs 4.5:1 for normal text; AAA needs 7:1."}),p&&de(fx,{targetRef:p,label:"Footer body",deps:[d,e,n,l]}),f&&de(fx,{targetRef:f,label:"Copyright strip",deps:[d,e,n,l]})]})})]})]})}const kx=[{value:"default",label:"Default"},{value:"primary",label:"Primary"},{value:"primary-dark",label:"Primary Dark"},{value:"white",label:"White"},{value:"black",label:"Black"}];function Bx({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function wx(){const[e,t]=r("DinoDesign"),[n,a]=r((new Date).getFullYear()),[l,s]=r("All rights reserved"),[d,c]=r(""),[u,p]=r(!1),[m,f]=r("default"),g=o(null),[x,b]=r(null);return i(()=>{g.current&&b({current:g.current.querySelector(".dino-copyright")})},[m,u,e,n,l,d]),ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Copyright"}),ce(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:["Standalone copyright strip used at the bottom of pages. Defaults to"," ",ce("code",{children:["© ","{year}"," ","{companyName}",". ","{rights}","."]})," Pass"," ",de("code",{children:"children"})," to override the entire text."]}),de(h,{ref:g,sx:{borderRadius:1,overflow:"hidden",mb:4},children:de(ix,u?{color:m,children:d||"Type a custom message →"}:{color:m,companyName:e,year:Number(n)||(new Date).getFullYear(),rights:l})}),ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:560},children:[ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TEXT MODE"}),ce(B,{direction:"row",spacing:1,children:[de(Bx,{label:"Auto-generated",selected:!u,onClick:()=>p(!1)}),de(Bx,{label:"Custom",selected:u,onClick:()=>p(!0)})]})]}),!u&&ce(ue,{children:[de(Xn,{label:"Company name",value:e,onChange:e=>t(e.target.value),placeholder:"DinoDesign",size:"medium"}),de(dl,{label:"Year",value:Number(n),onChange:e=>a(e),min:1900,max:2100}),de(Xn,{label:"Rights text",value:l,onChange:e=>s(e.target.value),placeholder:"All rights reserved",size:"medium"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'Leave Rights blank to omit "All rights reserved." entirely.'})]}),u&&ce(ue,{children:[de(Xn,{label:"Custom text",value:d,onChange:e=>c(e.target.value),placeholder:"© 2026 DinoDesign · MIT License · Built with love",size:"medium",multiline:!0}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Pass any string (or React node) as children to fully override the auto text."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:kx.map(e=>de(Bx,{label:e.label,selected:m===e.value,onClick:()=>f(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Matches the Footer color presets so the two stack cleanly."})]})]})}),de(ai,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[de(bo,{style:{color:"var(--Text-Quiet)"},children:"Live WCAG 2.1 contrast against the painted background. AA needs 4.5:1 for normal text; AAA needs 7:1."}),x&&de(fx,{targetRef:x,label:"Copyright strip",deps:[m,u,e,n,l,d]})]})})]})]})}const Cx=["Default","Primary","Secondary","Tertiary","Neutral"],Tx={Classic:{name:"Classic",description:"Raised + soft shadow",angle:135,bevel:!0,depth:5,softness:1,shadow:!0,shadowDistance:6,shadowBlur:8,shadowOpacity:.6},Carved:{name:"Carved",description:"Deep inset, no shadow",angle:135,bevel:!0,depth:10,softness:2,shadow:!1,shadowDistance:4,shadowBlur:4,shadowOpacity:.4},Embossed:{name:"Embossed",description:"Inset + heavy shadow",angle:135,bevel:!0,depth:7,softness:1.5,shadow:!0,shadowDistance:10,shadowBlur:14,shadowOpacity:.7},Stamp:{name:"Stamp",description:"Reversed light + shadow",angle:315,bevel:!0,depth:6,softness:1,shadow:!0,shadowDistance:5,shadowBlur:6,shadowOpacity:.8},"Night Cut":{name:"Night Cut",description:"Inset on dark background",angle:135,bevel:!0,depth:8,softness:2,shadow:!1,shadowDistance:6,shadowBlur:8,shadowOpacity:.6},"Shadow Only":{name:"Shadow Only",description:"Flat fill + drop shadow",angle:135,bevel:!1,depth:4,softness:1,shadow:!0,shadowDistance:8,shadowBlur:12,shadowOpacity:.5}},Ix=Object.keys(Tx);function Ax(e,t){if("custom"===e)return{...Tx.Classic,name:"Custom",description:"Custom",...t||{}};const r=Tx[e];return r?{...r}:{...Tx.Classic}}function zx(e,t){const r=e||"Primary";return"base"===t?"var(--Buttons-"+r+"-Button)":"highlight"===t?"rgb(var(--Buttons-"+r+"-Highlight))":"lowlight"===t?"rgb(var(--Buttons-"+r+"-Lowlight))":void 0}function Rx(e){const t=e||"Primary";return"Default"===t?"var(--Text)":"var(--Text-"+t+")"}function Ex(e,t){const r=(e-90)*Math.PI/180;return{dx:Math.cos(r)*t,dy:Math.sin(r)*t}}const Px={"display-large":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Large-Font-Size)",fontWeight:"var(--Display-Large-Font-Weight)",letterSpacing:"var(--Display-Large-Letter-Spacing)",pxHint:64},"display-small":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Small-Font-Size)",fontWeight:"var(--Display-Small-Font-Weight)",letterSpacing:"var(--Display-Small-Letter-Spacing)",pxHint:48}};function Ox({text:e="Your Brand. Perfected.",curves:r,arc:o=160,radius:n=300,direction:i="up",rotation:a=0,autoCrop:l=!0,textStyle:s="display-large",fontSize:d,fontFamily:c,fontWeight:u,letterSpacing:p,color:h="var(--Text, #1a1a1a)",bevel:m=!1,bevelTheme:f="Primary",bevelPreset:g,bevelCustom:x,className:b,style:v,...y}){const S=g?Ax(g,x):null,k=S?!!S.bevel:!!m,B=Px[s]||Px["display-large"],w=c??B.fontFamily,C=d??B.fontSize,T=u??B.fontWeight,I=p??B.letterSpacing,A="number"==typeof d?d:B.pxHint,z=r&&r.length>0?r:[{arc:o,radius:n,direction:i}],{d:R,width:E,upMax:P,downMax:O,pathId:L}=function(e){return t.useMemo(()=>{const t="dino-curved-text-"+Math.random().toString(36).slice(2,9);let r=0;const o=0;let n="M "+r+" "+o,i=0,a=0;for(const{arc:t,radius:l,direction:s}of e){const e=Lx(t,1,359),d=Math.max(10,l),c=e*Math.PI/180,u=2*d*Math.sin(c/2),p=d*(1-Math.cos(c/2));r+=u,n+=" A "+d+" "+d+" 0 "+(e>180?1:0)+" "+("up"===s?1:0)+" "+r+" "+o,"up"===s?i=Math.max(i,p):a=Math.max(a,p)}return{d:n,width:r,upMax:i,downMax:a,pathId:t}},[JSON.stringify(e)])}(z),M=Math.ceil(P+A),W=Math.ceil(O+A),D=Math.ceil(A),F=Math.ceil(E+2*D),N=M+W,H=D,V=M,Q=a?"rotate("+a+" "+F/2+" "+N/2+")":void 0,j=t.useRef(null),[G,U]=t.useState(null),[X,K]=t.useState(A);t.useEffect(()=>{if(!j.current||"undefined"==typeof ResizeObserver)return;const e=j.current,t=()=>{const t=e.getBoundingClientRect(),r=G?G.width:F;if(!r||!t.width)return;const o=t.width/r;K(A*o)};t();const r=new ResizeObserver(t);return r.observe(e),()=>r.disconnect()},[F,A,G]);const q=k&&X>=19;t.useLayoutEffect(()=>{if(!l)return void U(null);const e=j.current;if(!e)return;const t=e.querySelector("text");if(!t)return;let r;try{r=t.getBBox()}catch(e){return}if(!r||!r.width||!r.height)return;const o=F/2,n=N/2,i=a*Math.PI/180,s=Math.cos(i),d=Math.sin(i),c=(e,t)=>{const r=e-o,i=t-n;return{x:o+r*s-i*d,y:n+r*d+i*s}},u=[c(r.x,r.y),c(r.x+r.width,r.y),c(r.x,r.y+r.height),c(r.x+r.width,r.y+r.height)],p=Math.min(...u.map(e=>e.x)),h=Math.max(...u.map(e=>e.x)),m=Math.min(...u.map(e=>e.y)),f=Math.max(...u.map(e=>e.y)),g=.12*A,x={x:p-g,y:m-g,width:h-p+2*g,height:f-m+2*g};U(e=>e&&Math.abs(e.x-x.x)<.5&&Math.abs(e.y-x.y)<.5&&Math.abs(e.width-x.width)<.5&&Math.abs(e.height-x.height)<.5?e:x)},[l,e,JSON.stringify(z),a,A,I,w,T,k,f,g,JSON.stringify(x)]);const J=G?G.x+" "+G.y+" "+G.width+" "+G.height:"0 0 "+F+" "+N,Y=G?G.width:F,$=G?G.height:N;return ce("svg",{ref:j,viewBox:J,width:Y,height:$,preserveAspectRatio:"xMidYMid meet",xmlns:"http://www.w3.org/2000/svg",style:{display:"block",maxWidth:"100%",height:"auto",overflow:"visible",...v},"aria-label":e,role:"img",className:["dino-curved-text",b].filter(Boolean).join(" "),...y,children:[de("defs",{children:de("path",{id:L,d:R,transform:"translate("+H+" "+V+")"})}),ce("g",{transform:Q,children:[q&&(()=>{const t=S?S.depth/96:.045,r=Math.max(2,Math.round(A*t)),o=Math.max(1,Math.round(A*t*.67)),n={fontFamily:w,fontSize:"number"==typeof C?C+"px":C,fontWeight:T,letterSpacing:"number"==typeof I?I+"px":I};return ce(ue,{children:[de("text",{className:"dino-bevel-layer dino-bevel-layer--lowlight",fill:"rgb(var(--Buttons-"+f+"-Lowlight))",transform:"translate(0 "+r+")",style:n,children:de("textPath",{href:"#"+L,startOffset:"50%",textAnchor:"middle",children:e})}),de("text",{className:"dino-bevel-layer dino-bevel-layer--highlight",fill:"rgb(var(--Buttons-"+f+"-Highlight))",transform:"translate(0 -"+o+")",style:n,children:de("textPath",{href:"#"+L,startOffset:"50%",textAnchor:"middle",children:e})})]})})(),de("text",{className:"dino-curved-text__base",fill:q?"var(--Buttons-"+f+"-Button)":k?Rx(f):h,style:{fontFamily:w,fontSize:"number"==typeof C?C+"px":C,fontWeight:T,letterSpacing:"number"==typeof I?I+"px":I},children:de("textPath",{href:"#"+L,startOffset:"50%",textAnchor:"middle",children:e})})]})]})}function Lx(e,t,r){return Math.max(t,Math.min(r,e))}const Mx=[{value:"display-large",label:"Display Large"},{value:"display-small",label:"Display Small"}],Wx=[{value:"text",label:"Text",css:"var(--Text)"},{value:"primary",label:"Primary",css:"var(--Text-Primary)"},{value:"secondary",label:"Secondary",css:"var(--Text-Secondary)"},{value:"tertiary",label:"Tertiary",css:"var(--Text-Tertiary)"}],Dx=Cx.map(e=>({value:e,label:e}));function Fx({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Nx(){const[e,t]=r("Your Brand. Perfected."),[n,a]=r("display-large"),[l,s]=r("primary"),[d,c]=r([(u="up",{arc:140,radius:340,direction:u})]);var u;const[p,m]=r(0),[f,g]=r(8),[x,b]=r(700),[v,y]=r(!1),[S,k]=r("Primary"),[w,C]=r("Classic"),T=o(null),[I,A]=r(null);i(()=>{T.current&&A({current:T.current.querySelector("text")})},[l,n,d,p,f,x,v,S,w]);const z=Wx.find(e=>e.value===l)?.css||Wx[0].css;function R(e,t){c(r=>r.map((r,o)=>o===e?{...r,...t}:r))}return ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Curved Display Text"}),de(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:"Decorative text laid along an SVG arc. Chain multiple arcs to build a wave — each curve gets its own radius, arc sweep, and direction. Uses your design system's decorative font + text tokens."}),ce(h,{sx:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(360px, 1fr))",gap:3,alignItems:"start"},children:[de(h,{sx:{minWidth:0},children:de(h,{ref:T,"data-surface":"Container",sx:{background:"var(--Background)",borderRadius:2,p:3,display:"flex",alignItems:"center",justifyContent:"center",overflow:"auto",position:"sticky",top:16},children:de(Ox,{text:e,curves:d,textStyle:n,rotation:p,letterSpacing:f,fontWeight:x,bevel:v,bevelTheme:S,bevelPreset:v?w:void 0,color:z})})}),de(h,{sx:{minWidth:0,alignSelf:"flex-start"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:720},children:[de(Xn,{label:"Text",value:e,onChange:e=>t(e.target.value),placeholder:"Your headline…",size:"medium"}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"CURVES"}),de(B,{direction:"row",spacing:1,children:[1,2].map(e=>de(Fx,{label:String(e),selected:d.length===e,onClick:()=>function(e){c(t=>{if(e===t.length)return t;if(e>t.length){const r=[...t];for(;r.length<e;){const e=r[r.length-1];r.push({arc:e.arc,radius:e.radius,direction:"up"===e.direction?"down":"up"})}return r}return t.slice(0,e)})}(e)},e))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"One curve is an arch. Two curves chain end-to-end for a wave."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:12},children:"PER-CURVE SETTINGS"}),de(B,{spacing:2,children:d.map((e,t)=>ce(h,{"data-surface":"Container",style:{background:"var(--Background)",border:"1px solid var(--Border)",borderRadius:8,padding:12},children:[ce(B,{direction:"row",alignItems:"center",spacing:2,sx:{mb:1},children:[ce(bo,{style:{fontWeight:700},children:["Curve ",t+1]}),de("div",{style:{flex:1}}),ce(B,{direction:"row",spacing:1,children:[de(Fx,{label:"⌢ Up",selected:"up"===e.direction,onClick:()=>R(t,{direction:"up"})}),de(Fx,{label:"⌣ Down",selected:"down"===e.direction,onClick:()=>R(t,{direction:"down"})})]})]}),ce(B,{spacing:1,children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Radius",ce("span",{style:{float:"right"},children:[e.radius,"px"]})]}),de(cs,{min:100,max:600,step:10,value:e.radius,onChange:(e,r)=>R(t,{radius:r})})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Arc sweep",ce("span",{style:{float:"right"},children:[e.arc,"°"]})]}),de(cs,{min:40,max:280,step:5,value:e.arc,onChange:(e,r)=>R(t,{arc:r})})]})]})]},t))})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TYPOGRAPHY"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Mx.map(e=>de(Fx,{label:e.label,selected:n===e.value,onClick:()=>a(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Uses the lib's DisplayLarge / DisplaySmall tokens (font-family, size, weight, letter-spacing)."})]}),ce(h,{children:[ce(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:["LETTER SPACING",ce("span",{style:{float:"right"},children:[f,"px"]})]}),de(cs,{min:-4,max:40,step:1,value:f,onChange:(e,t)=>g(t)}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Adjusts the gap between characters along the wave."})]}),ce(h,{children:[ce(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:["FONT WEIGHT",de("span",{style:{float:"right"},children:x})]}),de(cs,{min:100,max:900,step:100,value:x,onChange:(e,t)=>b(t)}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Heavier weights read better at decorative sizes. Available weights depend on the loaded display font."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BEVEL"}),de(ea,{label:"3D bevel effect",checked:v,onChange:e=>y(e.target.checked)}),v&&ce(h,{sx:{mt:1.5},children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:6},children:"Preset"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1,mb:1.5},children:Ix.map(e=>de(Fx,{label:e,selected:w===e,onClick:()=>C(e)},e))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:6},children:"Bevel theme"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Dx.map(e=>de(Fx,{label:e.label,selected:S===e.value,onClick:()=>k(e.value)},e.value))})]}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Bevel layers use ",ce("code",{children:["--Buttons-","{Theme}","-Button"]})," for the fill, with ",de("code",{children:"Highlight"})," + ",de("code",{children:"Lowlight"}),"tokens for the bright/shadow stripes. CurvedText honors a preset's ",de("em",{children:"depth"})," only — angle, softness, and drop-shadow fields are stacked-rendering limitations and are ignored here (the full filter pipeline lives in ",de("code",{children:"<BevelText>"}),"). Shadow-only presets render no effect. Auto-hides below 19px so the 3:1 bevel contrast doesn't compromise small-text legibility."]})]}),ce(h,{children:[ce(B,{direction:"row",alignItems:"center",sx:{mb:1},children:[ce(To,{style:{color:"var(--Text-Quiet)",flex:1},children:["ROTATION",ce("span",{style:{float:"right",marginRight:12},children:[p,"°"]})]}),de(Tn,{variant:"default-outline",size:"small",onClick:function(){const t=T.current?.querySelector("svg");if(!t)return;const r=t.querySelector("path"),o=t.querySelector("text");if(!r||!o)return;const n=r.getTotalLength();if(!n)return;let i=0;try{i=o.getComputedTextLength?.()||0}catch(e){}i||(i=Math.min(n,18*e.length));const a=Math.max(0,(n-i)/2),l=Math.min(n,a+i),s=r.getPointAtLength(a),d=r.getPointAtLength(l),c=180*Math.atan2(d.y-s.y,d.x-s.x)/Math.PI,u=Math.max(-45,Math.min(45,Math.round(-c)));m(u)},children:"Auto-level"})]}),de(cs,{min:-45,max:45,step:1,value:p,onChange:(e,t)=>m(t)}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:'Tilts the whole text block around its center. "Auto-level" rotates so the text\'s start and end sit on the same horizontal line — useful when a multi-curve wave makes the reading line slant.'})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Wx.map(e=>de(Fx,{label:e.label,selected:l===e.value,onClick:()=>s(e.value)},e.value))})]})]})}),de(ai,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[de(bo,{style:{color:"var(--Text-Quiet)"},children:"Live WCAG 2.1 contrast against the painted background. Decorative display text counts as large text — AA needs 3:1, AAA needs 4.5:1 — but DinoDesign defaults to 4.5:1 across the board."}),I&&de(fx,{targetRef:I,label:"Curved text",deps:[l,n,JSON.stringify(d),p,f]}),ce(ao,{color:"quiet",children:["The SVG sets ",de("code",{children:'role="img"'})," and"," ",de("code",{children:"aria-label"})," to the rendered text so screen readers announce it as a labeled image, not a stream of individual glyphs."]})]})})]})})})]})]})}const Hx={"display-large":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Large-Font-Size)",fontWeight:"var(--Display-Large-Font-Weight)",letterSpacing:"var(--Display-Large-Letter-Spacing)",pxHint:96},"display-small":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Small-Font-Size)",fontWeight:"var(--Display-Small-Font-Weight)",letterSpacing:"var(--Display-Small-Letter-Spacing)",pxHint:64}};function Vx({text:e="DinoDesign",theme:r="Primary",preset:o="Classic",custom:n,textStyle:i="display-large",fontSize:a,fontFamily:l,fontWeight:s,letterSpacing:d,className:c,style:u,...p}){const h=Hx[i]||Hx["display-large"],m=l??h.fontFamily,f=a??h.fontSize,g=s??h.fontWeight,x=d??h.letterSpacing,b="number"==typeof a?a:h.pxHint,v=Ax(o,n),y="dino-bevel-"+t.useId().replace(/:/g,""),S=y+"-s",k=t.useRef(null),[B,w]=t.useState(b),C=.6*b,T=Math.max(400,e.length*C+80),I=1.9*b,A=T/2,z=.7*I;t.useEffect(()=>{if(!k.current||"undefined"==typeof ResizeObserver)return;const e=k.current,t=()=>{const t=e.getBoundingClientRect();T&&t.width&&w(b*(t.width/T))};t();const r=new ResizeObserver(t);return r.observe(e),()=>r.disconnect()},[T,b]);const R=B>=19,E=v.bevel?Ex(v.angle+180,v.depth):{dx:0,dy:0},P=v.bevel?Ex(v.angle,v.depth):{dx:0,dy:0},O=v.shadow?Ex(v.angle,v.shadowDistance??6):{dx:0,dy:0},L=R?zx(r,"base"):Rx(r),M=zx(r,"highlight"),W=zx(r,"lowlight"),D={fontFamily:m,fontSize:"number"==typeof f?f+"px":f,fontWeight:g,letterSpacing:"number"==typeof x?x+"px":x},F=v.bevel&&R?"url(#"+y+")":void 0,N=v.shadow&&R?"url(#"+S+")":void 0;return ce("svg",{ref:k,viewBox:"0 0 "+T+" "+I,width:T,height:I,preserveAspectRatio:"xMidYMid meet",xmlns:"http://www.w3.org/2000/svg",style:{display:"block",maxWidth:"100%",height:"auto",overflow:"visible",...u},"aria-label":e,role:"img",className:["dino-bevel-text",c].filter(Boolean).join(" "),...p,children:[ce("defs",{children:[v.shadow&&de("filter",{id:S,x:"-30%",y:"-30%",width:"160%",height:"160%",children:de("feDropShadow",{dx:O.dx.toFixed(2),dy:O.dy.toFixed(2),stdDeviation:v.shadowBlur??8,style:{floodColor:W,floodOpacity:v.shadowOpacity??.6}})}),v.bevel&&ce("filter",{id:y,x:"-5%",y:"-5%",width:"110%",height:"110%",colorInterpolationFilters:"sRGB",children:[de("feGaussianBlur",{in:"SourceAlpha",stdDeviation:(v.softness??1)+.5,result:"blur-alpha"}),de("feOffset",{in:"blur-alpha",dx:P.dx.toFixed(2),dy:P.dy.toFixed(2),result:"shadow-offset"}),de("feFlood",{style:{floodColor:W,floodOpacity:.95},result:"shadow-flood"}),de("feComposite",{in:"shadow-flood",in2:"shadow-offset",operator:"in",result:"shadow-shaped"}),de("feComposite",{in:"shadow-shaped",in2:"SourceAlpha",operator:"in",result:"shadow-clipped"}),de("feOffset",{in:"blur-alpha",dx:E.dx.toFixed(2),dy:E.dy.toFixed(2),result:"hi-offset"}),de("feFlood",{style:{floodColor:M,floodOpacity:.95},result:"hi-flood"}),de("feComposite",{in:"hi-flood",in2:"hi-offset",operator:"in",result:"hi-shaped"}),de("feComposite",{in:"hi-shaped",in2:"SourceAlpha",operator:"in",result:"hi-clipped"}),ce("feMerge",{children:[de("feMergeNode",{in:"SourceGraphic"}),de("feMergeNode",{in:"shadow-clipped"}),de("feMergeNode",{in:"hi-clipped"})]})]})]}),v.shadow&&R&&de("text",{className:"dino-bevel-layer dino-bevel-layer--shadow",x:A,y:z,textAnchor:"middle",fill:L,filter:N,style:D,"aria-hidden":"true",children:e}),de("text",{className:v.bevel?"dino-bevel-text__base dino-bevel-layer":"dino-bevel-text__base",x:A,y:z,textAnchor:"middle",fill:L,filter:F,style:D,children:e})]})}const Qx=[...Ix.map(e=>({value:e,label:e,description:Tx[e].description})),{value:"custom",label:"Custom",description:"Tune every knob"}],jx=[{value:"light",label:"Light",css:"var(--Surface)"},{value:"warm",label:"Warm",css:"var(--Surface-Dim)"},{value:"dark",label:"Dark",css:"var(--Container-High)"}];function Gx({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Ux({option:e,active:t,onClick:r}){return ce(h,{onClick:r,role:"button",tabIndex:0,onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),r())},sx:{flex:"1 1 140px",minWidth:130,cursor:"pointer",border:"1.5px solid",borderColor:t?"var(--Buttons-Primary-Border)":"var(--Border)",background:t?"rgb(var(--Buttons-Primary-Highlight) / 0.18)":"var(--Background)",borderRadius:"var(--Style-Border-Radius)",p:1.5,transition:"border-color 0.15s, background 0.15s",textAlign:"center","&:hover":{borderColor:"var(--Buttons-Primary-Border)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:2}},children:[de(bo,{style:{fontWeight:600,color:"var(--Text)"},children:e.label}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:2},children:e.description})]})}function Xx(){const[e,t]=r("DinoDesign"),[o,n]=r("Primary"),[i,a]=r("Classic"),[l,s]=r("light"),[d,c]=r(135),[u,p]=r(5),[m,f]=r(1),[g,x]=r(!0),[b,v]=r(!0),[y,S]=r(6),[k,w]=r(8),[C,T]=r(60),[I,A]=r(96),[z,R]=r(900),[E,P]=r(0),O="custom"===i,L=O?{angle:d,depth:u,softness:m,bevel:g,shadow:b,shadowDistance:y,shadowBlur:k,shadowOpacity:C/100}:void 0;const M=jx.find(e=>e.value===l)?.css||jx[0].css;return ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Bevel Display Text"}),de(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:"Straight-line display text with an SVG inset-bevel and optional drop shadow. Colors are locked to the active button-palette tokens (Button / Highlight / Lowlight) so the same preset reads correctly under any theme."}),ce(h,{sx:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(360px, 1fr))",gap:3,alignItems:"start"},children:[de(h,{sx:{minWidth:0},children:de(h,{"data-surface":"Container",sx:{background:M,borderRadius:2,p:4,display:"flex",alignItems:"center",justifyContent:"center",minHeight:240,overflow:"auto",position:"sticky",top:16,transition:"background 0.2s"},children:de(Vx,{text:e,theme:o,preset:i,custom:L,fontSize:I,fontWeight:z,letterSpacing:E})})}),de(h,{sx:{minWidth:0,alignSelf:"flex-start"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:720},children:[de(Xn,{label:"Text",value:e,onChange:e=>t(e.target.value),placeholder:"Your headline…",size:"medium"}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"THEME"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Cx.map(e=>de(Gx,{label:e,selected:o===e,onClick:()=>n(e)},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Resolves to ",ce("code",{children:["--Buttons-","{Theme}","-Button"]})," ","(fill), ",de("code",{children:"-Highlight"})," (light edge), and"," ",de("code",{children:"-Lowlight"})," (shadow edge)."]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PRESETS"}),de(h,{sx:{display:"flex",flexWrap:"wrap",gap:1},children:Qx.map(e=>de(Ux,{option:e,active:i===e.value,onClick:()=>function(e){if(a(e),"custom"!==e){const t=Ax(e);c(t.angle),p(t.depth??5),f(t.softness??1),x(t.bevel),v(t.shadow),S(t.shadowDistance??6),w(t.shadowBlur??8),T(Math.round(100*(t.shadowOpacity??.6)))}}(e.value)},e.value))})]}),O&&ce(h,{sx:{border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",p:2},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:12},children:"CUSTOM"}),ce(B,{spacing:2,children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Light angle",ce("span",{style:{float:"right"},children:[d,"°"]})]}),de(cs,{min:0,max:360,step:5,value:d,onChange:(e,t)=>c(t)})]}),ce(h,{sx:{border:"1px solid var(--Border-Variant)",borderRadius:1,p:1.5},children:[de(ea,{label:"Inset bevel",checked:g,onChange:e=>x(e.target.checked)}),g&&ce(B,{spacing:1.5,sx:{mt:1.5},children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Depth",ce("span",{style:{float:"right"},children:[u,"px"]})]}),de(cs,{min:1,max:16,step:1,value:u,onChange:(e,t)=>p(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Softness",ce("span",{style:{float:"right"},children:[m,"px"]})]}),de(cs,{min:0,max:6,step:.5,value:m,onChange:(e,t)=>f(t)})]})]})]}),ce(h,{sx:{border:"1px solid var(--Border-Variant)",borderRadius:1,p:1.5},children:[de(ea,{label:"Drop shadow",checked:b,onChange:e=>v(e.target.checked)}),b&&ce(B,{spacing:1.5,sx:{mt:1.5},children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Distance",ce("span",{style:{float:"right"},children:[y,"px"]})]}),de(cs,{min:1,max:24,step:1,value:y,onChange:(e,t)=>S(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Blur",ce("span",{style:{float:"right"},children:[k,"px"]})]}),de(cs,{min:0,max:24,step:1,value:k,onChange:(e,t)=>w(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Opacity",ce("span",{style:{float:"right"},children:[C,"%"]})]}),de(cs,{min:10,max:100,step:5,value:C,onChange:(e,t)=>T(t)})]})]})]})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TYPOGRAPHY"}),ce(B,{spacing:2,children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Font size",ce("span",{style:{float:"right"},children:[I,"px"]})]}),de(cs,{min:32,max:160,step:4,value:I,onChange:(e,t)=>A(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Font weight",de("span",{style:{float:"right"},children:z})]}),de(cs,{min:400,max:900,step:100,value:z,onChange:(e,t)=>R(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Letter spacing",ce("span",{style:{float:"right"},children:[E,"px"]})]}),de(cs,{min:-2,max:20,step:1,value:E,onChange:(e,t)=>P(t)})]})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PREVIEW BACKGROUND"}),de(B,{direction:"row",spacing:1,children:jx.map(e=>de(Gx,{label:e.label,selected:l===e.value,onClick:()=>s(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Showcase-only — doesn't affect the emitted code."})]})]})}),de(ai,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[ce(bo,{style:{color:"var(--Text-Quiet)"},children:["BevelText uses the same Highlight / Lowlight token pair as button bevels, which target the WCAG 2.1 large-text minimum (3:1). Bevel text is decorative display — the SVG sets"," ",de("code",{children:'role="img"'})," and ",de("code",{children:"aria-label"})," to the rendered string so screen readers announce it as a labeled image, not a stream of glyphs."]}),de(ao,{color:"quiet",children:"Keep the rendered glyph height above ~24px when the bevel is on — at smaller sizes the highlight / lowlight stripes optically reduce the legible stroke width and the 3:1 contrast no longer feels comfortable."})]})})]})})})]})]})}function Kx({open:e,onClose:t,items:o=[],onItemClick:n,width:i=280,variant:a="temporary",header:l,footer:s,sx:d={},...c}){const[u,p]=r(null),[f,g]=r({}),x=(e,r)=>{p(r),n?.(e),"temporary"===a&&t?.()},b="permanent"===a?"permanent":"standard"===a?"standard":"temporary",v=ce(h,{sx:{display:"flex",flexDirection:"column",height:"100%",backgroundColor:"var(--Container)",color:"var(--Text)"},children:[l&&de(h,{sx:{p:2,borderBottom:"1px solid var(--Border-Variant)"},children:"string"==typeof l?de(T,{variant:"h6",sx:{fontWeight:700},children:l}):l}),de(_,{sx:{flex:1,overflow:"auto",py:1},children:o.map((e,t)=>{const r=u===t,o=e.submenu&&e.submenu.length>0,n=f[t];return ce(h,{children:[de(w,{title:e.tooltip||"",placement:"right",children:de(ee,{disablePadding:!0,children:ce(te,{onClick:()=>{o?(e=>{g(t=>({...t,[e]:!t[e]}))})(t):x(e,t)},selected:r&&!o,sx:{backgroundColor:r&&!o?"var(--Buttons-Primary-Button)":"transparent",color:r&&!o?"var(--Buttons-Primary-Text)":"var(--Text)","&:hover":{backgroundColor:r&&!o?"var(--Buttons-Primary-Button)":"var(--Container-High)"},"&.Mui-selected":{backgroundColor:"var(--Buttons-Primary-Button)",color:"var(--Buttons-Primary-Text)","&:hover":{backgroundColor:"var(--Buttons-Primary-Button)"}},transition:"all 0.2s ease-in-out"},children:[e.icon&&de(re,{sx:{color:r&&!o?"var(--Buttons-Primary-Text)":"var(--Icons-Primary)",minWidth:40},children:e.badge?de(m,{badgeContent:e.badge,color:"error",children:e.icon}):e.icon}),de(oe,{primary:e.label,primaryTypographyProps:{variant:"body2",fontWeight:r&&!o?600:500}}),o&&de(h,{sx:{ml:1},children:de(n?Gt:Se,{})})]})})}),o&&de(ne,{in:n,timeout:"auto",unmountOnExit:!0,children:de(_,{component:"div",disablePadding:!0,children:e.submenu.map((e,t)=>de(ee,{disablePadding:!0,children:ce(te,{onClick:()=>x(e,t),sx:{pl:4,backgroundColor:"transparent",color:"var(--Text)","&:hover":{backgroundColor:"var(--Container-High)"},"&.Mui-selected":{backgroundColor:"var(--Buttons-Primary-Button)",color:"var(--Buttons-Primary-Text)"}},children:[e.icon&&de(re,{sx:{color:"var(--Icons-Primary)",minWidth:40},children:e.icon}),de(oe,{primary:e.label})]})},t))})}),e.divider&&de(ie,{sx:{my:1,borderColor:"var(--Border-Variant)"}})]},t)})}),s&&de(h,{sx:{borderTop:"1px solid var(--Border-Variant)",p:2},children:"string"==typeof s?de(T,{variant:"caption",sx:{color:"var(--Text-Quiet)"},children:s}):s})]});return"permanent"===a?de(h,{sx:{width:i,flexShrink:0,...d},children:v}):de(ae,{variant:b,open:e,onClose:t,PaperProps:{sx:{width:i,backgroundColor:"var(--Container)",color:"var(--Text)",...d}},...c,children:v})}function qx({layout:e="side",navItems:t=[{label:"Home",icon:de(Be,{}),path:"/"},{label:"About",icon:de(Pe,{}),path:"/about"},{label:"Settings",icon:de(Ce,{}),path:"/settings"},{label:"Help",icon:de(gr,{}),path:"/help"}],title:o="My App",children:n,onLayoutChange:i,onNavigate:a,sx:l={},...s}){const d=le(),c=se(d.breakpoints.down("md"));se(d.breakpoints.down("lg"));const[u,p]=r(!1),[m,f]=r(!1),g=c?"top":e,x=({compact:e=!1})=>de(_,{sx:{py:1},children:t.map((t,r)=>de(w,{title:e?t.label:"",placement:"right",children:ce(te,{onClick:()=>{a?.(t),p(!1)},sx:{color:"var(--Text)","&:hover":{backgroundColor:"var(--Container-High)"},transition:"all 0.2s ease-in-out",justifyContent:e?"center":"flex-start",px:e?1:2},children:[de(re,{sx:{color:"var(--Icons-Primary)",minWidth:e?"auto":40,mr:e?0:1},children:t.icon}),!e&&de(oe,{primary:t.label})]})},r))});return ce(h,{sx:{minHeight:"100vh",backgroundColor:"var(--Background)",color:"var(--Text)",display:"flex",flexDirection:"column",...l},...s,children:[de($,{position:"static",sx:{backgroundColor:"var(--Header)",color:"var(--Text)",boxShadow:"0 1px 3px rgba(0,0,0,0.12)",borderBottom:"1px solid var(--Border-Variant)"},children:ce(Z,{children:[c&&"rail"!==g&&de(C,{edge:"start",color:"inherit",onClick:()=>p(!u),sx:{mr:2},children:de(u?Ot:Pt,{})}),de(T,{variant:"h6",sx:{flex:1,fontWeight:700},children:o}),!c&&i&&ce(E,{value:e,exclusive:!0,onChange:(e,t)=>{t&&i(t)},size:"small",sx:{"& .MuiToggleButton-root":{color:"var(--Text)",border:"1px solid var(--Border)","&.Mui-selected":{backgroundColor:"var(--Button-Primary-Button)",color:"#fff",borderColor:"var(--Button-Primary-Button)"}}},children:[de(R,{value:"side","aria-label":"side nav",children:"☰ Side"}),de(R,{value:"rail","aria-label":"rail nav",children:"⫷ Rail"}),de(R,{value:"side-rail","aria-label":"side-rail nav",children:"☰⫷ Both"})]})]})}),ce(h,{sx:{display:"flex",flex:1},children:[("rail"===g||"side-rail"===g)&&!c&&de(h,{sx:{width:80,backgroundColor:"var(--Container)",borderRight:"1px solid var(--Border-Variant)",display:"flex",flexDirection:"column",py:2},children:de(x,{compact:!0})}),("side"===g||"side-rail"===g)&&!c&&ce(h,{sx:{width:m?80:280,backgroundColor:"var(--Container)",borderRight:"1px solid var(--Border-Variant)",transition:"width 0.3s ease-in-out",display:"flex",flexDirection:"column"},children:[ce(h,{sx:{p:2,display:"flex",alignItems:"center",justifyContent:"space-between",borderBottom:"1px solid var(--Border-Variant)",minHeight:64},children:[!m&&de(T,{variant:"h6",sx:{fontWeight:700,color:"var(--Text)"},children:"Menu"}),de(C,{size:"small",onClick:()=>f(!m),sx:{color:"var(--Icons-Primary)"},children:m?"›":"‹"})]}),de(x,{compact:m})]}),c&&ce(ae,{anchor:"left",open:u,onClose:()=>p(!1),sx:{"& .MuiDrawer-paper":{backgroundColor:"var(--Container)",width:280}},children:[de(h,{sx:{p:2,borderBottom:"1px solid var(--Border-Variant)"},children:de(T,{variant:"h6",sx:{fontWeight:700},children:"Menu"})}),de(x,{compact:!1})]}),de(h,{sx:{flex:1,overflow:"auto",backgroundColor:"var(--Background)"},children:de(F,{maxWidth:"lg",sx:{py:4},children:n})})]})]})}const Jx={small:{summaryPadding:"8px 12px",detailsPy:"8px",detailsPx:"12px",fontSize:"13px",iconSize:"small"},medium:{summaryPadding:"12px 8px 12px 16px",detailsPy:"12px",detailsPx:"16px",fontSize:"14px",iconSize:"medium"},large:{summaryPadding:"16px 20px",detailsPy:"16px",detailsPx:"20px",fontSize:"16px",iconSize:"large"}},Yx=s({variant:"solid",color:"default",size:"medium",spacing:0}),$x=s({expanded:!1,toggle:()=>{},disabled:!1,accordionId:""});function Zx({children:e,variant:t="solid",color:r="default",size:o="medium",spacing:n=0,className:i="",sx:a={},...l}){const s="default"===r?"Default":(d=r).charAt(0).toUpperCase()+d.slice(1);var d;const c=0===n,u="default"===r?"Default":s,p="dark"===t?"Surface-Dimmest":"light"===t?"Surface-Brightest":"Surface";return de(Yx.Provider,c?{value:{variant:t,color:r,size:o,spacing:n},children:de(h,{role:"presentation",className:"accordion-group accordion-group-"+t+" "+i,sx:{border:"1px solid var(--Border-Variant)",borderRadius:"var(--Button-Radius)",overflow:"hidden",boxShadow:an,...a},...l,children:de(h,{"data-theme":u,"data-surface":p,sx:{backgroundColor:"var(--Background)",borderRadius:"calc(var(--Button-Radius) - 1px)"},children:e})})}:{value:{variant:t,color:r,size:o,spacing:n,dataTheme:u,dataSurface:p},children:de(h,{role:"presentation",className:"accordion-group accordion-group-"+t+" accordion-group-spaced "+i,sx:{display:"flex",flexDirection:"column",gap:.5===n?"var(--Sizing-Half)":1===n?"var(--Sizing-1)":1.5===n?"var(--Sizing-1-and-Half)":2===n?"var(--Sizing-2)":8*n+"px",...a},...l,children:e})})}function _x({children:e,expanded:t,defaultExpanded:o=!1,onChange:n,disabled:i=!1,className:a="",sx:s={},...d}){const[c,u]=r(o),p=void 0!==t,m=p?t:c,{spacing:f,dataTheme:g,dataSurface:x}=l(Yx),b=0===f,[v]=r(()=>"accordion-"+Math.random().toString(36).substring(2,9)),y=de($x.Provider,{value:{expanded:m,toggle:()=>{if(i)return;const e=!m;p||u(e),n?.(e)},disabled:i,accordionId:v},children:de(h,{className:"accordion"+(m?" accordion-expanded":"")+(i?" accordion-disabled":"")+" "+a,sx:{...b&&{borderBottom:"1px solid var(--Border-Variant)","&:last-child":{borderBottom:"none"}},opacity:i?.5:1,...s},...d,children:e})});return b?y:de(h,{sx:{border:"1px solid var(--Border-Variant)",borderRadius:"var(--Button-Radius)",overflow:"hidden",boxShadow:an},children:de(h,{"data-theme":g,"data-surface":x,sx:{backgroundColor:"var(--Background)",borderRadius:"calc(var(--Button-Radius) - 1px)"},children:y})})}const eb={small:ao,medium:co,large:fo};function tb({children:e,startDecorator:t,endDecorator:r,eyebrow:o,overline:n,secondary:i,expandIcon:a,className:s="",sx:d={},...c}){const{expanded:u,toggle:p,disabled:m,accordionId:f}=l($x),{size:g}=l(Yx),x=Jx[g]||Jx.medium,b=eb[g]||eb.medium,v=a||de(jo,{size:x.iconSize,sx:{color:u?"var(--Text)":"var(--Quiet)",transition:"color 0.15s ease"},children:de(Se,{})}),y={overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",display:"block"};return ce(h,{component:"button",role:"button","aria-expanded":u,"aria-controls":f+"-content",id:f+"-header",tabIndex:m?-1:0,onClick:p,onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),p())},className:"accordion-summary"+(u?" accordion-summary-expanded":"")+" "+s,sx:{display:"flex",flexDirection:"row",alignItems:"flex-start",justifyContent:"flex-start",width:"100%",gap:"var(--Sizing-1-and-Half)",padding:x.summaryPadding,border:"none",backgroundColor:"transparent",color:u?"var(--Text)":"var(--Quiet)",fontSize:x.fontSize,fontFamily:"inherit",cursor:m?"not-allowed":"pointer",textAlign:"left",transition:"color 0.2s ease, background-color 0.15s ease",borderRadius:0,"&:hover":m?{}:{color:"var(--Text)","& .omni-icon":{color:"var(--Text)"}},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},...d},...c,children:[t&&de(h,{className:"accordion-summary-start",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0},children:t}),ce(h,{sx:{flex:1,minWidth:0,display:"flex",flexDirection:"column",gap:"var(--Sizing-Half)"},children:[(o??n)&&de(To,{style:{...y,color:"var(--Text-Quiet)"},children:o??n}),null!=e&&de(b,{style:{...y,color:"inherit",fontWeight:600},children:e}),i&&de(ao,{style:{...y,color:"var(--Text-Quiet)"},children:i})]}),r&&de(h,{className:"accordion-summary-end",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0},children:r}),de(h,{sx:{display:"flex",alignItems:"center",justifyContent:"center",transform:u?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.25s ease",flexShrink:0},children:v})]})}function rb({children:e,className:t="",sx:r={},...o}){const{expanded:n,accordionId:i}=l($x),{size:a}=l(Yx),s=Jx[a]||Jx.medium;return n?de(h,{role:"region",id:i+"-content","aria-labelledby":i+"-header",className:"accordion-details "+t,sx:{padding:"0 "+s.detailsPx+" "+s.detailsPy+" "+s.detailsPx,color:"var(--Text)",fontSize:s.fontSize,fontFamily:"inherit",lineHeight:1.6,...r},...o,children:e}):null}const ob={1:{padLeft:0,togglePadLeft:0},2:{padLeft:24,togglePadLeft:4},3:{padLeft:48,togglePadLeft:0},4:{padLeft:72,togglePadLeft:0},5:{padLeft:88,togglePadLeft:4}},nb={0:{padLeft:8},1:{padLeft:48},2:{padLeft:56,slotPadLeft:4},3:{padLeft:64,slotPadLeft:4},4:{padLeft:88,slotPadLeft:4},5:{padLeft:112},6:{padLeft:128}};function ib({label:e,icon:t,level:r=0,toggle:o="none",onToggle:n,disabled:i=!1,size:a="small",className:l="",sx:s={},children:d,...c}){const u=6===r&&"none"!==o?"none":o,p="on"===u,m="none"!==u,f=m?ob[r]||{padLeft:0,togglePadLeft:0}:nb[r]||nb[0],g={paddingTop:"8px",paddingRight:"8px",paddingBottom:"8px",paddingLeft:(f.padLeft??8)+"px"};return ce(h,{className:"tree-branch tree-branch-"+a+" tree-branch-level-"+r+" tree-branch-toggle-"+u+(i?" tree-branch-disabled":"")+(l?" "+l:""),sx:{width:"100%",...s},...c,children:[ce(h,{component:"button",type:"button",role:"treeitem","aria-expanded":m?p:void 0,"aria-disabled":i||void 0,tabIndex:i?-1:0,onClick:e=>{i||m&&(e.stopPropagation(),n?.(p?"off":"on"))},disabled:i,sx:{display:"flex",flexDirection:"row",alignItems:"center",gap:"4px",width:"100%",minHeight:"24px",...g,border:"none",backgroundColor:"transparent",fontFamily:"inherit",color:"inherit",textAlign:"left",cursor:i?"not-allowed":"pointer",opacity:i?.5:1,outline:"none",transition:"background-color 0.15s ease, color 0.15s ease","&:hover":i?{}:{backgroundColor:"var(--Hover)"},"&:active":i?{}:{backgroundColor:"var(--Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-2px"}},children:[m&&de(h,{className:"tree-branch-toggle",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,paddingLeft:(f.togglePadLeft??0)+"px"},children:de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",transition:"transform 0.2s ease",transform:p?"rotate(-90deg)":"rotate(0deg)"},children:de(jo,{size:"small",children:de(Kt,{})})})}),ce(h,{className:"tree-branch-slot",sx:{display:"flex",flexDirection:"row",alignItems:"center",gap:"4px",flex:1,minWidth:0,...void 0!==f.slotPadLeft&&{paddingLeft:f.slotPadLeft+"px"}},children:[t&&de(h,{sx:{display:"inline-flex",alignItems:"center",flexShrink:0},children:de(jo,{size:"small",children:t})}),null!=e&&de(lo,{style:{color:"inherit",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",display:"block",flex:1,minWidth:0},children:e})]})]}),p&&d&&de(h,{role:"group",sx:{display:"flex",flexDirection:"column"},children:d})]})}const ab=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",lb=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],sb=e=>de(h,{sx:{width:8,height:8,borderRadius:"50%",backgroundColor:e,flexShrink:0}}),db=[{id:"1",label:"Documents",icon:de(cr,{}),badge:sb("var(--Warning-Text, orange)"),children:[{id:"1-1",label:"Company",icon:de(xr,{}),badge:sb("var(--Warning-Text, orange)"),children:[{id:"1-1-1",label:"Invoice",icon:de(vr,{})},{id:"1-1-2",label:"Meeting notes",icon:de(br,{})},{id:"1-1-3",label:"Tasks list",icon:de(br,{})},{id:"1-1-4",label:"Equipment",icon:de(vr,{})},{id:"1-1-5",label:"Video conference",icon:de(yr,{})}]},{id:"1-2",label:"Personal",icon:de(cr,{})},{id:"1-3",label:"Group photo",icon:de(Ut,{})}]},{id:"2",label:"Bookmarked",icon:de(_t,{}),children:[{id:"2-1",label:"Favourites",icon:de(br,{})}]},{id:"3",label:"History",icon:de(cr,{})},{id:"4",label:"Trash",icon:de(we,{}),disabled:!0}],cb=JSON.stringify(Bf,null,2);function ub({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function pb({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(ub,{ratio:t,threshold:r})]})}function hb({label:e,selected:t,onClick:r}){return de(Tn,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function mb({color:e,selected:t,onClick:r}){const o=ab(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function fb({value:e,onChange:t}){const[o,n]=r(e),[i,a]=r(null);return ce(h,{children:[ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:1},children:[de(To,{style:{color:"var(--Text-Quiet)"},children:"TREE DATA (JSON)"}),de(Tn,{variant:"ghost",size:"small",onClick:()=>{n(cb),a(null),t(Bf)},children:"Reset"})]}),de(h,{component:"textarea",value:o,onChange:e=>{n(e.target.value);try{const r=JSON.parse(e.target.value);a(null),t(r)}catch(e){a(e.message)}},spellCheck:!1,rows:10,sx:{width:"100%",fontFamily:"monospace",fontSize:"11px",backgroundColor:"#1e1e1e",color:i?"#f87171":"#e5e7eb",border:"1px solid "+(i?"#f87171":"#333"),borderRadius:"6px",padding:"10px",resize:"vertical",outline:"none",boxSizing:"border-box",lineHeight:1.5,"&:focus":{borderColor:"var(--Focus-Visible)"}}}),i&&ce(bo,{style:{color:"#f87171",display:"block",marginTop:4},children:["JSON error: ",i]})]})}function gb(){const[e,t]=r("solid"),[a,l]=r("primary"),[s,d]=r("default"),[c,u]=r("slide"),[p,m]=r("single"),[f,g]=r(!1),[x,b]=r(!1),[v,y]=r(!1),[S,k]=r(Bf),[w,C]=r(null),[T,A]=r("Surface"),[z,R]=r({}),E=o(null),P=ab(a),O=v?db:S,L=n((e,t)=>e&&getComputedStyle(e).getPropertyValue(t).trim()||null,[]);i(()=>{const e=setTimeout(()=>{const e=E.current;R({text:L(e,"--Text"),textQuiet:L(e,"--Text-Quiet"),background:L(e,"--Background"),border:L(e,"--Border"),focusVisible:L(e,"--Focus-Visible"),activeBtn:L(e,"--Buttons-"+P+"-Button"),activeBorder:L(e,"--Buttons-"+P+"-Border")})},50);return()=>clearTimeout(e)},[a,w,L,P]);return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Tree View"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(li,{ref:E,theme:w,children:de(h,{sx:{width:"100%",maxWidth:360},children:de(kf,{color:a,variant:e,density:s,animation:c,selectionMode:p,checkboxSelection:f,disableSelection:x,items:O,defaultExpandedItems:["1","1-1","2"]})})}),de(Ni,{code:(()=>{const t=["<OmniTreeView"];return"default"!==a&&t.push(' color="'+a+'"'),"default"!==e&&t.push(' variant="'+e+'"'),"default"!==s&&t.push(' density="'+s+'"'),"slide"!==c&&t.push(' animation="'+c+'"'),"single"!==p&&t.push(' selectionMode="'+p+'"'),f&&t.push(" checkboxSelection"),x&&t.push(" disableSelection"),t.push(" items={treeData}"),t.push("/>"),t.join("\n")})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(oi,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ni,{children:[de(ii,{children:"Playground"}),de(ii,{children:"Accessibility"})]}),de(ai,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(ui,{theme:w,onThemeChange:C,surface:T,onSurfaceChange:A})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),ce(B,{direction:"row",spacing:1,children:[de(hb,{label:"Solid",selected:"solid"===e,onClick:()=>t("solid")}),de(hb,{label:"Light",selected:"light"===e,onClick:()=>t("light")})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:lb.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(mb,{color:e,selected:a===e,onClick:l},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"DENSITY"}),ce(B,{direction:"row",spacing:1,children:[de(hb,{label:"Compact",selected:"compact"===s,onClick:()=>d("compact")}),de(hb,{label:"Default",selected:"default"===s,onClick:()=>d("default")})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ANIMATION"}),de(B,{direction:"row",spacing:1,children:["none","slide","spring"].map(e=>de(hb,{label:ab(e),selected:c===e,onClick:()=>u(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SELECTION MODE"}),ce(B,{direction:"row",spacing:1,children:[de(hb,{label:"Single",selected:"single"===p,onClick:()=>m("single")}),de(hb,{label:"Multi",selected:"multi"===p,onClick:()=>m("multi")})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Icons"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Load sample data with icons and badges"})]}),de(_i,{checked:v,onChange:e=>y(e.target.checked),size:"small","aria-label":"Show icons"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Checkbox Selection"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show checkboxes for each item"})]}),de(_i,{checked:f,onChange:e=>g(e.target.checked),size:"small","aria-label":"Checkbox selection"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disable Selection"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Items are not selectable"})]}),de(_i,{checked:x,onChange:e=>b(e.target.checked),size:"small","aria-label":"Disable selection"})]})]}),!v&&de(h,{sx:{mt:3},children:de(fb,{value:cb,onChange:k})})]})}),de(ai,{value:1,children:de(h,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Text Contrast (WCAG 1.4.3 — 4.5:1)"}),de(pb,{label:"Resting: var(--Text-Quiet) vs. background",ratio:ji(z.textQuiet,z.background),threshold:4.5,note:"Unselected items use Text-Quiet"}),de(pb,{label:"Hover: var(--Text) vs. background",ratio:ji(z.text,z.background),threshold:4.5,note:"Hovered items use var(--Text)"}),de(pb,{label:"Active (solid): var(--Text) vs. var(--Buttons-"+P+"-Button)",ratio:ji(z.text,z.activeBtn),threshold:4.5,note:"Selected item with solid fill"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"Focus Indicator (WCAG 2.4.11 — 3:1)"}),de(pb,{label:"var(--Focus-Visible) vs. background",ratio:ji(z.focusVisible,z.background),threshold:3,note:"outline: 2px solid var(--Focus-Visible); outline-offset: -2px"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de($r,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="tree" on root, role="treeitem" on each node'},{label:"Expansion",value:'aria-expanded="true/false" on parent items'},{label:"Selection",value:"aria-selected on selected items"},{label:"Disabled",value:'aria-disabled="true" on disabled items'},{label:"Icons",value:"Icon elements are aria-hidden — label carries the accessible name"},{label:"Keyboard",value:"Arrow keys navigate, Enter/Space selects, * expands all siblings"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})]})})})]})})})]})]})}function xb(e,t){if(document.getElementById(t))return;const r=document.createElement("link");r.rel="stylesheet",r.href=e,r.id=t,document.head.appendChild(r)}const bb=[{value:"desktop",label:"Desktop",note:"32px touch targets (WCAG)"},{value:"ios-mobile",label:"iOS Mobile",note:"44px touch targets (HIG)"},{value:"ios-tablet",label:"iOS Tablet",note:"44px touch targets (HIG)"},{value:"android",label:"Android",note:"48px touch targets (M3)"}],vb={desktop:"32px","ios-mobile":"44px","ios-tablet":"44px",android:"48px"};function yb(){const{mode:e,switchMode:t}=function(e="light"){const[t,o]=r(e);return i(()=>{xb("/styles/foundation.css","css-foundation"),xb("/styles/core.css","css-core"),xb("/styles/Light-Mode.css","css-mode"),xb("/styles/base.css","css-base"),xb("/styles/typography-tokens.css","css-typography-tokens")},[]),{mode:t,switchMode:e=>{const t=document.getElementById("css-mode");t&&(t.href="dark"===e?"/styles/Dark-Mode.css":"/styles/Light-Mode.css"),o(e),localStorage.setItem("themeMode",e)}}}("light"),[o,n]=r(!1),[a,l]=r("desktop");i(()=>{const e=localStorage.getItem("dino-platform")||"desktop",r=localStorage.getItem("themeMode")||"light";l(e),document.documentElement.style.setProperty("--Button-Height",vb[e]||"32px"),"dark"===r&&t("dark")},[]);const s=e=>{l(e),localStorage.setItem("dino-platform",e),document.documentElement.style.setProperty("--Button-Height",vb[e]||"32px")};return ce(ue,{children:[de(h,{onClick:()=>n(!0),role:"button","aria-label":"Open settings",sx:{position:"fixed",bottom:24,right:24,width:52,height:52,borderRadius:"50%",backgroundColor:"var(--Buttons-Tertiary-Button)",color:"var(--Buttons-Tertiary-Text)",display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",boxShadow:"0 4px 12px rgba(0,0,0,0.15)",zIndex:999,transition:"transform 0.15s ease, box-shadow 0.15s ease","&:hover":{transform:"scale(1.08)",boxShadow:"0 6px 16px rgba(0,0,0,0.2)"}},children:de(Rt,{sx:{fontSize:24}})}),de(mu,{anchor:"right",open:o,onClose:()=>n(!1),hideBackdrop:!0,size:"small",sx:{width:320,zIndex:99999999},children:ce(h,{sx:{p:3,height:"100%",display:"flex",flexDirection:"column"},children:[ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:2},children:[de($r,{children:"Settings"}),de(Tn,{iconOnly:!0,variant:"ghost",size:"small",onClick:()=>n(!1),"aria-label":"Close settings",children:de(Et,{fontSize:"small"})})]}),de(ie,{sx:{mb:3,borderColor:"var(--Border)"}}),de(h,{sx:{flex:1,overflowY:"auto"},children:ce(B,{spacing:4,children:[ce(h,{children:[de(To,{style:{color:"var(--Text)",opacity:.85,display:"block",marginBottom:12,fontWeight:600},children:"MODE"}),ce(B,{direction:"row",spacing:1,children:[de(Tn,{variant:"light"===e?"primary":"primary-outline",size:"small",onClick:()=>t("light"),sx:{flex:1},children:"Light"}),de(Tn,{variant:"dark"===e?"primary":"primary-outline",size:"small",onClick:()=>t("dark"),sx:{flex:1},children:"Dark"})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text)",opacity:.85,display:"block",marginBottom:12,fontWeight:600},children:"PLATFORM"}),de(B,{spacing:1,children:bb.map(({value:e,label:t,note:r})=>{const o=a===e;return ce(h,{onClick:()=>s(e),sx:{p:1.5,borderRadius:"var(--Style-Border-Radius)",cursor:"pointer",border:o?"2px solid var(--Buttons-Primary-Button)":"1px solid var(--Border)",backgroundColor:o?"var(--Background)":"transparent",display:"flex",justifyContent:"space-between",alignItems:"center",transition:"all 0.15s ease","&:hover":{backgroundColor:"var(--Hover)"}},children:[ce(h,{children:[de(ao,{style:{color:o?"var(--Buttons-Primary-Button)":"var(--Text)",fontWeight:o?600:400},children:t}),de(bo,{style:{color:"var(--Text)",opacity:.7},children:r})]}),o&&de(h,{sx:{width:8,height:8,borderRadius:"50%",backgroundColor:"var(--Buttons-Primary-Button)",flexShrink:0}})]},e)})})]})]})}),de(ie,{sx:{my:3,borderColor:"var(--Border)"}}),de(Tn,{variant:"primary-outline",size:"small",onClick:()=>{s("desktop"),t("light")},sx:{width:"100%"},children:"Reset to Defaults"})]})})]})}var Sb={};export{_x as Accordion,rb as AccordionDetails,Zx as AccordionGroup,tb as AccordionSummary,Of as Alert,eu as AlertDialog,Nf as AlertShowcase,Kg as AppBar,rx as AppBarShowcase,Jl as Autocomplete,ts as AutocompleteShowcase,qo as Avatar,Jo as AvatarGroup,xg as AvatarShowcase,en as Badge,wg as BadgeShowcase,Vx as BevelText,Xx as BevelTextShowcase,Tl as BlackWhiteToggleButtonGroup,co as Body,ho as Body1,mo as Body2,po as BodyBold,fo as BodyLarge,xo as BodyLargeBold,go as BodyLargeSemibold,uo as BodySemibold,ao as BodySmall,so as BodySmallBold,lo as BodySmallSemibold,Hd as BottomNavigation,$d as BottomNavigationShowcase,Ns as Box,js as BoxShowcase,md as BreadcrumbItem,hd as Breadcrumbs,xd as BreadcrumbsShowcase,Tn as Button,fa as ButtonGroup,Fo as ButtonSmall,No as ButtonText,jr as CAP_HEIGHT_TRIM,bo as Caption,vo as CaptionBold,Oa as Card,Sa as CenteredStack,Dn as Checkbox,As as Chip,Yf as CircularProgress,tg as CircularProgressShowcase,Ni as CodeBlock,Xi as Colors,Gs as Container,Fi as CopyButton,ix as Copyright,wx as CopyrightShowcase,Ox as CurvedText,Nx as CurvedTextShowcase,Go as DEFAULT_AVATAR_SRC,Bf as DEFAULT_ITEMS,Sl as DefaultToggleButtonGroup,Ug as DesktopAppBar,_c as Dialog,ou as DialogShowcase,Gr as DisplayLarge,Ur as DisplayMedium,Xr as DisplaySmall,zg as Divider,mu as Drawer,fu as DrawerClose,xu as DrawerContent,gu as DrawerHeader,zf as DrawerShowcase,Ef as DropZone,zd as Dropdown,ba as DynoStack,kf as DynoTreeView,Pl as EmailTextField,Rl as ErrorToggleButtonGroup,Io as Eyebrow,zo as EyebrowLarge,Ao as EyebrowMedium,To as EyebrowSmall,Qa as Fab,Ja as FabShowcase,lx as Footer,Sx as FooterShowcase,tu as FormDialog,Sc as Gradient,Us as Grid,Ta as GridStack,Kr as H1,qr as H2,Jr as H3,Yr as H4,$r as H5,Zr as H6,va as HStack,ox as Header,_r as Heading,jo as Icon,ha as IconBadge,Na as IconBadgeShowcase,ca as IconShowcase,Il as InfoToggleButtonGroup,Aa as InsetStack,ko as Label,yo as LabelExtraSmall,Bo as LabelLarge,So as LabelSmall,wo as Legal,Co as LegalSemibold,Cf as LightTreeView,kc as LinearGradient,ng as LinearProgress,dg as LinearProgressShowcase,Ps as Link,Wg as List,Mg as ListItem,Lg as ListItemDecorator,qx as MainLayout,Ed as Menu,Rd as MenuButton,Od as MenuDivider,Pd as MenuItem,Fd as MenuShowcase,Cc as MeshCardGradient,wc as MeshGradient,Xg as MobileAppBar,du as Modal,Cl as NeutralToggleButtonGroup,dl as NumberField,ml as NumberFieldShowcase,Wo as NumberLarge,Mo as NumberMedium,Lo as NumberSmall,Ml as NumberTextField,Vc as OmniDesignProvider,ba as OmniStack,kf as OmniTreeView,Eo as Overline,Oo as OverlineLarge,Po as OverlineMedium,Ro as OverlineSmall,vd as Pagination,wd as PaginationShowcase,Tc as Paper,Ol as PasswordTextField,Wl as PhoneTextField,Ic as Popover,kl as PrimaryToggleButtonGroup,qs as RATIO_NAMES,Bc as RadialGradient,is as Radio,as as RadioGroup,ls as RadioInput,Ya as Rail,tl as RailShowcase,ps as RangeSlider,fs as Rating,fs as RatingInput,Zs as Ratio,id as RatioShowcase,wa as ResponsiveStack,za as ScrollStack,xs as SearchField,ks as SearchFieldShowcase,Ll as SearchTextField,Bl as SecondaryToggleButtonGroup,Xs as Section,Ks as SectionShowcase,Yn as Select,Xl as SelectShowcase,Ma as SelectableCard,yb as SettingsPanel,Kx as Sidebar,us as Slider,us as SliderInput,Vf as Snackbar,Kf as SnackbarShowcase,wf as SolidTreeView,ka as SpaceBetweenStack,Ki as Spacing,cc as SpeedDial,gc as SpeedDialShowcase,Ca as Stack,Ia as StackDivider,Fs as StackShowcase,oc as Step,rc as Stepper,dc as StepperShowcase,to as Subtitle,no as Subtitle1,io as Subtitle2,eo as SubtitleLarge,oo as SubtitleMedium,ro as SubtitleSmall,Al as SuccessToggleButtonGroup,Gc as Surfaced,ea as Switch,ea as SwitchInput,ii as Tab,ni as TabList,ai as TabPanel,Fg as Table,oi as Tabs,ud as TabsShowcase,wl as TertiaryToggleButtonGroup,Fl as TextArea,El as TextField,Nl as TextFieldGroup,Xn as TextInput,jc as ThemedZone,fl as ToggleButton,yl as ToggleButtonGroup,ol as Toolbar,ll as ToolbarShowcase,Qg as Tooltip,ib as TreeBranch,gb as TreeViewShowcase,Qr as Typography,Dl as URLTextField,ya as VStack,zl as WarningToggleButtonGroup,Ba as WrapStack,Sb as default,Qc as useOmniDesign,tc as useStepperContext,ri as useTabsContext};
41
+ */"production"===process.env.NODE_ENV?Mh.exports=function(){if(Lh)return Wh;Lh=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),n=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),c=Symbol.for("react.memo"),u=Symbol.for("react.lazy"),p=Symbol.for("react.view_transition"),h=Symbol.for("react.client.reference");function m(h){if("object"==typeof h&&null!==h){var m=h.$$typeof;switch(m){case e:switch(h=h.type){case r:case n:case o:case s:case d:case p:return h;default:switch(h=h&&h.$$typeof){case a:case l:case u:case c:case i:return h;default:return m}}case t:return m}}}return Wh.ContextConsumer=i,Wh.ContextProvider=a,Wh.Element=e,Wh.ForwardRef=l,Wh.Fragment=r,Wh.Lazy=u,Wh.Memo=c,Wh.Portal=t,Wh.Profiler=n,Wh.StrictMode=o,Wh.Suspense=s,Wh.SuspenseList=d,Wh.isContextConsumer=function(e){return m(e)===i},Wh.isContextProvider=function(e){return m(e)===a},Wh.isElement=function(t){return"object"==typeof t&&null!==t&&t.$$typeof===e},Wh.isForwardRef=function(e){return m(e)===l},Wh.isFragment=function(e){return m(e)===r},Wh.isLazy=function(e){return m(e)===u},Wh.isMemo=function(e){return m(e)===c},Wh.isPortal=function(e){return m(e)===t},Wh.isProfiler=function(e){return m(e)===n},Wh.isStrictMode=function(e){return m(e)===o},Wh.isSuspense=function(e){return m(e)===s},Wh.isSuspenseList=function(e){return m(e)===d},Wh.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===n||e===o||e===s||e===d||"object"==typeof e&&null!==e&&(e.$$typeof===u||e.$$typeof===c||e.$$typeof===a||e.$$typeof===i||e.$$typeof===l||e.$$typeof===h||void 0!==e.getModuleId)},Wh.typeOf=m,Wh}():Mh.exports=(Dh||(Dh=1,"production"!==process.env.NODE_ENV&&function(){function e(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:switch(e=e.type){case o:case i:case n:case d:case c:case h:return e;default:switch(e=e&&e.$$typeof){case l:case s:case p:case u:case a:return e;default:return m}}case r:return m}}}var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),a=Symbol.for("react.consumer"),l=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),h=Symbol.for("react.view_transition"),m=Symbol.for("react.client.reference");Fh.ContextConsumer=a,Fh.ContextProvider=l,Fh.Element=t,Fh.ForwardRef=s,Fh.Fragment=o,Fh.Lazy=p,Fh.Memo=u,Fh.Portal=r,Fh.Profiler=i,Fh.StrictMode=n,Fh.Suspense=d,Fh.SuspenseList=c,Fh.isContextConsumer=function(t){return e(t)===a},Fh.isContextProvider=function(t){return e(t)===l},Fh.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Fh.isForwardRef=function(t){return e(t)===s},Fh.isFragment=function(t){return e(t)===o},Fh.isLazy=function(t){return e(t)===p},Fh.isMemo=function(t){return e(t)===u},Fh.isPortal=function(t){return e(t)===r},Fh.isProfiler=function(t){return e(t)===i},Fh.isStrictMode=function(t){return e(t)===n},Fh.isSuspense=function(t){return e(t)===d},Fh.isSuspenseList=function(t){return e(t)===c},Fh.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===i||e===n||e===d||e===c||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===u||e.$$typeof===l||e.$$typeof===a||e.$$typeof===s||e.$$typeof===m||void 0!==e.getModuleId)},Fh.typeOf=e}()),Fh);var Nh=Mh.exports;function Hh(e){if("object"!=typeof e||null===e)return!1;const t=Object.getPrototypeOf(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)}function Vh(t){if(e.isValidElement(t)||Nh.isValidElementType(t)||!Hh(t))return t;const r={};return Object.keys(t).forEach(e=>{r[e]=Vh(t[e])}),r}function Qh(t,r,o={clone:!0}){const n=o.clone?{...t}:t;return Hh(t)&&Hh(r)&&Object.keys(r).forEach(i=>{e.isValidElement(r[i])||Nh.isValidElementType(r[i])?n[i]=r[i]:Hh(r[i])&&Object.prototype.hasOwnProperty.call(t,i)&&Hh(t[i])?n[i]=Qh(t[i],r[i],o):o.clone?n[i]=Hh(r[i])?Vh(r[i]):r[i]:n[i]=r[i]}),n}function jh(e){if("string"!=typeof e)throw new Error("production"!==process.env.NODE_ENV?"MUI: `capitalize(string)` expects a string argument.":function(e,...t){const r=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(e=>r.searchParams.append("args[]",e)),`Minified MUI error #${e}; visit ${r} for the full message.`}(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Gh(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:o=5,...n}=e,i=(e=>{const t=Object.keys(e).map(t=>({key:t,val:e[t]}))||[];return t.sort((e,t)=>e.val-t.val),t.reduce((e,t)=>({...e,[t.key]:t.val}),{})})(t),a=Object.keys(i);function l(e){return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r})`}function s(e){return`@media (max-width:${("number"==typeof t[e]?t[e]:e)-o/100}${r})`}function d(e,n){const i=a.indexOf(n);return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r}) and (max-width:${(-1!==i&&"number"==typeof t[a[i]]?t[a[i]]:n)-o/100}${r})`}return{keys:a,values:i,up:l,down:s,between:d,only:function(e){return a.indexOf(e)+1<a.length?d(e,a[a.indexOf(e)+1]):l(e)},not:function(e){const t=a.indexOf(e);return 0===t?l(a[1]):t===a.length-1?s(a[t]):d(e,a[a.indexOf(e)+1]).replace("@media","@media not all and")},unit:r,...n}}function Uh(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(e=>e.startsWith("@container")).sort((e,t)=>{const r=/min-width:\s*([0-9.]+)/;return+(e.match(r)?.[1]||0)-+(t.match(r)?.[1]||0)});return r.length?r.reduce((e,r)=>{const o=t[r];return delete e[r],e[r]=o,e},{...t}):t}const Xh={borderRadius:4},Kh="production"!==process.env.NODE_ENV?Ni.oneOfType([Ni.number,Ni.string,Ni.object,Ni.array]):{};function qh(e,t){return t?Qh(e,t,{clone:!1}):e}const Jh={xs:0,sm:600,md:900,lg:1200,xl:1536},Yh={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${Jh[e]}px)`},Zh={containerQueries:e=>({up:t=>{let r="number"==typeof t?t:Jh[t]||t;return"number"==typeof r&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function $h(e,t,r){const o=e.theme||{};if(Array.isArray(t)){const e=o.breakpoints||Yh;return t.reduce((o,n,i)=>(o[e.up(e.keys[i])]=r(t[i]),o),{})}if("object"==typeof t){const e=o.breakpoints||Yh;return Object.keys(t).reduce((n,i)=>{if(a=e.keys,"@"===(l=i)||l.startsWith("@")&&(a.some(e=>l.startsWith(`@${e}`))||l.match(/^@\d/))){const e=function(e,t){const r=t.match(/^@([^/]+)?\/?(.+)?$/);if(!r){if("production"!==process.env.NODE_ENV)throw new Error(`MUI: The provided shorthand (${t}) is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.\nFor example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`);return null}const[,o,n]=r,i=Number.isNaN(+o)?o||0:+o;return e.containerQueries(n).up(i)}(o.containerQueries?o:Zh,i);e&&(n[e]=r(t[i],i))}else if(Object.keys(e.values||Jh).includes(i)){n[e.up(i)]=r(t[i],i)}else{const e=i;n[e]=t[e]}var a,l;return n},{})}return r(t)}function _h(e,t){return e.reduce((e,t)=>{const r=e[t];return(!r||0===Object.keys(r).length)&&delete e[t],e},t)}function em(e,t,r=!0){if(!t||"string"!=typeof t)return null;if(e&&e.vars&&r){const r=`vars.${t}`.split(".").reduce((e,t)=>e&&e[t]?e[t]:null,e);if(null!=r)return r}return t.split(".").reduce((e,t)=>e&&null!=e[t]?e[t]:null,e)}function tm(e,t,r,o=r){let n;return n="function"==typeof e?e(r):Array.isArray(e)?e[r]||o:em(e,r)||o,t&&(n=t(n,o,e)),n}function rm(e){const{prop:t,cssProperty:r=e.prop,themeKey:o,transform:n}=e,i=e=>{if(null==e[t])return null;const i=e[t],a=em(e.theme,o)||{};return $h(e,i,e=>{let o=tm(a,n,e);return e===o&&"string"==typeof e&&(o=tm(a,n,`${t}${"default"===e?"":jh(e)}`,e)),!1===r?o:{[r]:o}})};return i.propTypes="production"!==process.env.NODE_ENV?{[t]:Kh}:{},i.filterProps=[t],i}const om={m:"margin",p:"padding"},nm={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},im={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},am=function(e){const t={};return r=>(void 0===t[r]&&(t[r]=e(r)),t[r])}(e=>{if(e.length>2){if(!im[e])return[e];e=im[e]}const[t,r]=e.split(""),o=om[t],n=nm[r]||"";return Array.isArray(n)?n.map(e=>o+e):[o+n]}),lm=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],sm=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],dm=[...lm,...sm];function cm(e,t,r,o){const n=em(e,t,!0)??r;return"number"==typeof n||"string"==typeof n?e=>"string"==typeof e?e:("production"!==process.env.NODE_ENV&&"number"!=typeof e&&console.error(`MUI: Expected ${o} argument to be a number or a string, got ${e}.`),"string"==typeof n?n.startsWith("var(")&&0===e?0:n.startsWith("var(")&&1===e?n:`calc(${e} * ${n})`:n*e):Array.isArray(n)?e=>{if("string"==typeof e)return e;const r=Math.abs(e);"production"!==process.env.NODE_ENV&&(Number.isInteger(r)?r>n.length-1&&console.error([`MUI: The value provided (${r}) overflows.`,`The supported values are: ${JSON.stringify(n)}.`,`${r} > ${n.length-1}, you need to add the missing values.`].join("\n")):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join("\n")));const o=n[r];return e>=0?o:"number"==typeof o?-o:"string"==typeof o&&o.startsWith("var(")?`calc(-1 * ${o})`:`-${o}`}:"function"==typeof n?n:("production"!==process.env.NODE_ENV&&console.error([`MUI: The \`theme.${t}\` value (${n}) is invalid.`,"It should be a number, an array or a function."].join("\n")),()=>{})}function um(e){return cm(e,"spacing",8,"spacing")}function pm(e,t){return"string"==typeof t||null==t?t:e(t)}function hm(e,t,r,o){if(!t.includes(r))return null;const n=function(e,t){return r=>e.reduce((e,o)=>(e[o]=pm(t,r),e),{})}(am(r),o);return $h(e,e[r],n)}function mm(e,t){const r=um(e.theme);return Object.keys(e).map(o=>hm(e,t,o,r)).reduce(qh,{})}function fm(e){return mm(e,lm)}function gm(e){return mm(e,sm)}function xm(...e){const t=e.reduce((e,t)=>(t.filterProps.forEach(r=>{e[r]=t}),e),{}),r=e=>Object.keys(e).reduce((r,o)=>t[o]?qh(r,t[o](e)):r,{});return r.propTypes="production"!==process.env.NODE_ENV?e.reduce((e,t)=>Object.assign(e,t.propTypes),{}):{},r.filterProps=e.reduce((e,t)=>e.concat(t.filterProps),[]),r}function bm(e){return"number"!=typeof e?e:`${e}px solid`}function vm(e,t){return rm({prop:e,themeKey:"borders",transform:t})}fm.propTypes="production"!==process.env.NODE_ENV?lm.reduce((e,t)=>(e[t]=Kh,e),{}):{},fm.filterProps=lm,gm.propTypes="production"!==process.env.NODE_ENV?sm.reduce((e,t)=>(e[t]=Kh,e),{}):{},gm.filterProps=sm,"production"===process.env.NODE_ENV||dm.reduce((e,t)=>(e[t]=Kh,e),{});const ym=vm("border",bm),Sm=vm("borderTop",bm),km=vm("borderRight",bm),Bm=vm("borderBottom",bm),wm=vm("borderLeft",bm),Cm=vm("borderColor"),Tm=vm("borderTopColor"),Im=vm("borderRightColor"),Am=vm("borderBottomColor"),zm=vm("borderLeftColor"),Rm=vm("outline",bm),Em=vm("outlineColor"),Pm=e=>{if(void 0!==e.borderRadius&&null!==e.borderRadius){const t=cm(e.theme,"shape.borderRadius",4,"borderRadius"),r=e=>({borderRadius:pm(t,e)});return $h(e,e.borderRadius,r)}return null};Pm.propTypes="production"!==process.env.NODE_ENV?{borderRadius:Kh}:{},Pm.filterProps=["borderRadius"],xm(ym,Sm,km,Bm,wm,Cm,Tm,Im,Am,zm,Pm,Rm,Em);const Om=e=>{if(void 0!==e.gap&&null!==e.gap){const t=cm(e.theme,"spacing",8,"gap"),r=e=>({gap:pm(t,e)});return $h(e,e.gap,r)}return null};Om.propTypes="production"!==process.env.NODE_ENV?{gap:Kh}:{},Om.filterProps=["gap"];const Lm=e=>{if(void 0!==e.columnGap&&null!==e.columnGap){const t=cm(e.theme,"spacing",8,"columnGap"),r=e=>({columnGap:pm(t,e)});return $h(e,e.columnGap,r)}return null};Lm.propTypes="production"!==process.env.NODE_ENV?{columnGap:Kh}:{},Lm.filterProps=["columnGap"];const Mm=e=>{if(void 0!==e.rowGap&&null!==e.rowGap){const t=cm(e.theme,"spacing",8,"rowGap"),r=e=>({rowGap:pm(t,e)});return $h(e,e.rowGap,r)}return null};Mm.propTypes="production"!==process.env.NODE_ENV?{rowGap:Kh}:{},Mm.filterProps=["rowGap"];function Wm(e,t){return"grey"===t?t:e}xm(Om,Lm,Mm,rm({prop:"gridColumn"}),rm({prop:"gridRow"}),rm({prop:"gridAutoFlow"}),rm({prop:"gridAutoColumns"}),rm({prop:"gridAutoRows"}),rm({prop:"gridTemplateColumns"}),rm({prop:"gridTemplateRows"}),rm({prop:"gridTemplateAreas"}),rm({prop:"gridArea"}));function Dm(e){return e<=1&&0!==e?100*e+"%":e}xm(rm({prop:"color",themeKey:"palette",transform:Wm}),rm({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Wm}),rm({prop:"backgroundColor",themeKey:"palette",transform:Wm}));const Fm=rm({prop:"width",transform:Dm}),Nm=e=>{if(void 0!==e.maxWidth&&null!==e.maxWidth){const t=t=>{const r=e.theme?.breakpoints?.values?.[t]||Jh[t];return r?"px"!==e.theme?.breakpoints?.unit?{maxWidth:`${r}${e.theme.breakpoints.unit}`}:{maxWidth:r}:{maxWidth:Dm(t)}};return $h(e,e.maxWidth,t)}return null};Nm.filterProps=["maxWidth"];const Hm=rm({prop:"minWidth",transform:Dm}),Vm=rm({prop:"height",transform:Dm}),Qm=rm({prop:"maxHeight",transform:Dm}),jm=rm({prop:"minHeight",transform:Dm});rm({prop:"size",cssProperty:"width",transform:Dm}),rm({prop:"size",cssProperty:"height",transform:Dm});xm(Fm,Nm,Hm,Vm,Qm,jm,rm({prop:"boxSizing"}));const Gm={border:{themeKey:"borders",transform:bm},borderTop:{themeKey:"borders",transform:bm},borderRight:{themeKey:"borders",transform:bm},borderBottom:{themeKey:"borders",transform:bm},borderLeft:{themeKey:"borders",transform:bm},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:bm},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Pm},color:{themeKey:"palette",transform:Wm},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Wm},backgroundColor:{themeKey:"palette",transform:Wm},p:{style:gm},pt:{style:gm},pr:{style:gm},pb:{style:gm},pl:{style:gm},px:{style:gm},py:{style:gm},padding:{style:gm},paddingTop:{style:gm},paddingRight:{style:gm},paddingBottom:{style:gm},paddingLeft:{style:gm},paddingX:{style:gm},paddingY:{style:gm},paddingInline:{style:gm},paddingInlineStart:{style:gm},paddingInlineEnd:{style:gm},paddingBlock:{style:gm},paddingBlockStart:{style:gm},paddingBlockEnd:{style:gm},m:{style:fm},mt:{style:fm},mr:{style:fm},mb:{style:fm},ml:{style:fm},mx:{style:fm},my:{style:fm},margin:{style:fm},marginTop:{style:fm},marginRight:{style:fm},marginBottom:{style:fm},marginLeft:{style:fm},marginX:{style:fm},marginY:{style:fm},marginInline:{style:fm},marginInlineStart:{style:fm},marginInlineEnd:{style:fm},marginBlock:{style:fm},marginBlockStart:{style:fm},marginBlockEnd:{style:fm},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:Om},rowGap:{style:Mm},columnGap:{style:Lm},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Dm},maxWidth:{style:Nm},minWidth:{transform:Dm},height:{transform:Dm},maxHeight:{transform:Dm},minHeight:{transform:Dm},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};const Um=function(){function e(e,t,r,o){const n={[e]:t,theme:r},i=o[e];if(!i)return{[e]:t};const{cssProperty:a=e,themeKey:l,transform:s,style:d}=i;if(null==t)return null;if("typography"===l&&"inherit"===t)return{[e]:t};const c=em(r,l)||{};if(d)return d(n);return $h(n,t,t=>{let r=tm(c,s,t);return t===r&&"string"==typeof t&&(r=tm(c,s,`${e}${"default"===t?"":jh(t)}`,t)),!1===a?r:{[a]:r}})}return function t(r){const{sx:o,theme:n={},nested:i}=r||{};if(!o)return null;const a=n.unstable_sxConfig??Gm;function l(r){let o=r;if("function"==typeof r)o=r(n);else if("object"!=typeof r)return r;if(!o)return null;const l=function(e={}){const t=e.keys?.reduce((t,r)=>(t[e.up(r)]={},t),{});return t||{}}(n.breakpoints),s=Object.keys(l);let d=l;return Object.keys(o).forEach(r=>{const i=(l=o[r],s=n,"function"==typeof l?l(s):l);var l,s;if(null!=i)if("object"==typeof i)if(a[r])d=qh(d,e(r,i,n,a));else{const e=$h({theme:n},i,e=>({[r]:e}));!function(...e){const t=e.reduce((e,t)=>e.concat(Object.keys(t)),[]),r=new Set(t);return e.every(e=>r.size===Object.keys(e).length)}(e,i)?d=qh(d,e):d[r]=t({sx:i,theme:n,nested:!0})}else d=qh(d,e(r,i,n,a))}),!i&&n.modularCssLayers?{"@layer sx":Uh(n,_h(s,d))}:Uh(n,_h(s,d))}return Array.isArray(o)?o.map(l):l(o)}}();function Xm(e,t){const r=this;if(r.vars){if(!r.colorSchemes?.[e]||"function"!=typeof r.getColorSchemeSelector)return{};let o=r.getColorSchemeSelector(e);return"&"===o?t:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:t})}return r.palette.mode===e?t:{}}function Km(e){return"ownerState"!==e&&"theme"!==e&&"sx"!==e&&"as"!==e}Um.filterProps=["sx"],function(e={},...t){const{breakpoints:r={},palette:o={},spacing:n,shape:i={},...a}=e,l=Gh(r),s=function(e=8,t=um({spacing:e})){if(e.mui)return e;const r=(...e)=>("production"!==process.env.NODE_ENV&&(e.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${e.length}`)),(0===e.length?[1]:e).map(e=>{const r=t(e);return"number"==typeof r?`${r}px`:r}).join(" "));return r.mui=!0,r}(n);let d=Qh({breakpoints:l,direction:"ltr",components:{},palette:{mode:"light",...o},spacing:s,shape:{...Xh,...i}},a);d=function(e){const t=(e,t)=>e.replace("@media",t?`@container ${t}`:"@container");function r(r,o){r.up=(...r)=>t(e.breakpoints.up(...r),o),r.down=(...r)=>t(e.breakpoints.down(...r),o),r.between=(...r)=>t(e.breakpoints.between(...r),o),r.only=(...r)=>t(e.breakpoints.only(...r),o),r.not=(...r)=>{const n=t(e.breakpoints.not(...r),o);return n.includes("not all and")?n.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):n}}const o={},n=e=>(r(o,e),o);return r(n),{...e,containerQueries:n}}(d),d.applyStyles=Xm,d=t.reduce((e,t)=>Qh(e,t),d),d.unstable_sxConfig={...Gm,...a?.unstable_sxConfig},d.unstable_sx=function(e){return Um({sx:e,theme:this})}}();const qm=(e,t,r)=>"function"==typeof r?r(e,t):r,Jm=t=>{const{runItemPlugins:r,publicAPI:o,store:n}=Uu(),i=e.useContext(nh),a=Ip(n,qm,t.itemId,i),{id:l,itemId:s,label:d,children:c,rootRef:u}=t,{rootRef:p,contentRef:h,propsEnhancers:m}=r(t),{interactions:f,status:g}=(({itemId:e,children:t})=>{const{store:r,publicAPI:o}=Uu(),n=Ip(r,Up.isItemExpandable,e),i=Ip(r,wh.isItemLoading,e),a=Ip(r,wh.itemHasError,e),l=Ch(t)||n,s=Ip(r,Up.isItemExpanded,e),d=Ip(r,yh.isItemFocused,e),c=Ip(r,Vp.isItemSelected,e),u=Ip(r,Wp.isItemDisabled,e),p=Ip(r,gh.isItemBeingEdited,e),h=Ip(r,gh.isItemEditable,e),m={expandable:l,expanded:s,focused:d,selected:c,disabled:u,editing:p,editable:h,loading:i,error:a},f=()=>{r.labelEditing&&(p?r.labelEditing.setEditedItem(null):r.labelEditing.setEditedItem(e))};return{interactions:{handleExpansion:t=>{if(m.disabled)return;m.focused||r.focus.focusItem(t,e);const o=Vp.isMultiSelectEnabled(r.state)&&(t.shiftKey||t.ctrlKey||t.metaKey);!m.expandable||o&&Up.isItemExpanded(r.state,e)||r.expansion.setItemExpansion({event:t,itemId:e})},handleSelection:t=>{Vp.canItemBeSelected(r.state,e)&&(m.focused||m.editing||r.focus.focusItem(t,e),Vp.isMultiSelectEnabled(r.state)&&(t.shiftKey||t.ctrlKey||t.metaKey)?t.shiftKey?r.selection.expandSelectionRange(t,e):r.selection.setItemSelection({event:t,itemId:e,keepExistingSelection:!0}):r.selection.setItemSelection({event:t,itemId:e,shouldBeSelected:!0}))},handleCheckboxSelection:t=>{const o=t.nativeEvent.shiftKey,n=Vp.isMultiSelectEnabled(r.state);n&&o?r.selection.expandSelectionRange(t,e):r.selection.setItemSelection({event:t,itemId:e,keepExistingSelection:n,shouldBeSelected:t.target.checked})},toggleItemEditing:f,handleSaveItemLabel:(t,o)=>{r.labelEditing&&gh.isItemBeingEdited(r.state,e)&&(r.labelEditing.updateItemLabel(e,o),f(),r.focus.focusItem(t,e))},handleCancelItemLabelEditing:t=>{r.labelEditing&&gh.isItemBeingEdited(r.state,e)&&(f(),r.focus.focusItem(t,e))}},status:m,publicAPI:o}})({itemId:s,children:c}),x=e.useRef(null),b=e.useRef(null),v=wu(u,p,x),y=wu(h,b),S=e.useRef(null),k=Ip(n,Vp.isCheckboxSelectionEnabled),B=Ip(n,Rp.treeItemIdAttribute,s,l),w=Ip(n,yh.isItemTheDefaultFocusableItem,s),C={rootRefObject:x,contentRefObject:b,interactions:f},T=e=>t=>{if(e.onBlur?.(t),t.defaultMuiPrevented)return;const r=n.items.getItemDOMElement(s);g.editing||t.relatedTarget&&$p(t.relatedTarget,r)&&(t.target&&"labelInput"===t.target?.dataset?.element&&$p(t.target,r)||"labelInput"===t.relatedTarget?.dataset?.element)||n.focus.removeFocusedItem()},I=e=>t=>{e.onKeyDown?.(t),t.defaultMuiPrevented||"labelInput"===t.target?.dataset?.element||n.keyboardNavigation.handleItemKeyDown(t,s)},A=e=>t=>{e.onMouseDown?.(t),t.defaultMuiPrevented||(t.shiftKey||t.ctrlKey||t.metaKey||g.disabled)&&t.preventDefault()};return{getContextProviderProps:()=>({itemId:s,id:l}),getRootProps:(e={})=>{const r=Su({},zu(t),zu(e)),o=Su({},r,{ref:v,role:"treeitem",tabIndex:w?0:-1,id:B,"aria-expanded":g.expandable?g.expanded:void 0,"aria-disabled":g.disabled||void 0},e,{style:Su({},e.style??{},{"--TreeView-itemDepth":a}),onFocus:(i=r,e=>{i.onFocus?.(e),e.defaultMuiPrevented||!g.focused&&Wp.canItemBeFocused(n.state,s)&&e.currentTarget===e.target&&n.focus.focusItem(e,s)}),onBlur:T(r),onKeyDown:I(r)});var i;const l=m.root?.(Su({},C,{externalEventHandlers:r}))??{};return Su({},o,l)},getContentProps:(e={})=>{const t=zu(e),r=Su({},t,e,{ref:y,onClick:(o=t,e=>{o.onClick?.(e),n.items.handleItemClick(e,s),e.defaultMuiPrevented||S.current?.contains(e.target)||("content"===Up.triggerSlot(n.state)&&f.handleExpansion(e),k||f.handleSelection(e))}),onMouseDown:A(t),status:g});var o;["expanded","selected","focused","disabled","editing","editable"].forEach(e=>{g[e]&&(r[`data-${e}`]="")});const i=m.content?.(Su({},C,{externalEventHandlers:t}))??{};return Su({},r,i)},getGroupTransitionProps:(e={})=>Su({},zu(e),{unmountOnExit:!0,component:"ul",role:"group",in:g.expanded,children:c},e),getIconContainerProps:(e={})=>{const t=zu(e);return Su({},t,e,{onClick:(r=t,e=>{r.onClick?.(e),e.defaultMuiPrevented||"iconContainer"===Up.triggerSlot(n.state)&&f.handleExpansion(e)})});var r},getCheckboxProps:(e={})=>{const t=zu(e),r=Su({},t,{ref:S,"aria-hidden":!0},e),o=m.checkbox?.(Su({},C,{externalEventHandlers:t}))??{};return Su({},r,o)},getLabelProps:(e={})=>{const t=Su({},zu(e)),r=Su({},t,{children:d},e,{onDoubleClick:(o=t,e=>{o.onDoubleClick?.(e),e.defaultMuiPrevented||f.toggleItemEditing()})});var o;const n=m.label?.(Su({},C,{externalEventHandlers:t}))??{};return Su({},n,r)},getLabelInputProps:(e={})=>{const t=zu(e),r=m.labelInput?.(Su({},C,{externalEventHandlers:t}))??{};return Su({},e,r)},getDragAndDropOverlayProps:(e={})=>{const t=zu(e),r=m.dragAndDropOverlay?.(Su({},C,{externalEventHandlers:t}))??{};return Su({},e,r)},getErrorContainerProps:(e={})=>Su({},zu(e),e),getLoadingContainerProps:(e={})=>Su({size:"12px",thickness:6},zu(e),e),rootRef:v,status:g,publicAPI:o}};function Ym(e){return Nu("MuiTreeItem",e)}Hu("MuiTreeItem",["root","content","groupTransition","iconContainer","label","checkbox","labelInput","dragAndDropOverlay","errorIcon","loadingIcon","expanded","selected","focused","disabled","editable","editing"]);const Zm=lr(de("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"TreeViewExpandIcon"),$m=lr(de("path",{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"}),"TreeViewCollapseIcon"),_m=["ownerState"];function ef(e,t,r){return void 0!==e?e:void 0!==t?t:r}function tf(e){const{slots:t,slotProps:r,status:o}=e,{slots:n,slotProps:i}=Ku(),a={collapseIcon:ef(t?.collapseIcon,n.collapseIcon,$m),expandIcon:ef(t?.expandIcon,n.expandIcon,Zm),endIcon:ef(t?.endIcon,n.endIcon),icon:t?.icon};let l;l=a?.icon?"icon":o.expandable?o.expanded?"collapseIcon":"expandIcon":"endIcon";const s=a[l],d=Ju(Pu({elementType:s,externalSlotProps:e=>Su({},Eu(i[l],e),Eu(r?.[l],e)),ownerState:{}}),_m);return s?de(s,Su({},d)):null}"production"!==process.env.NODE_ENV&&(tf.propTypes={slotProps:Ni.object,slots:Ni.object,status:Ni.shape({disabled:Ni.bool.isRequired,editable:Ni.bool.isRequired,editing:Ni.bool.isRequired,error:Ni.bool.isRequired,expandable:Ni.bool.isRequired,expanded:Ni.bool.isRequired,focused:Ni.bool.isRequired,loading:Ni.bool.isRequired,selected:Ni.bool.isRequired}).isRequired});const rf=or("div",{name:"MuiTreeItemDragAndDropOverlay",slot:"Root",shouldForwardProp:e=>Km(e)&&"action"!==e})(({theme:e})=>({position:"absolute",left:0,display:"flex",top:0,bottom:0,right:0,pointerEvents:"none",variants:[{props:{action:"make-child"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * var(--TreeView-itemDepth))",borderRadius:e.shape.borderRadius,backgroundColor:e.vars?`rgba(${e.vars.palette.primary.darkChannel} / ${e.vars.palette.action.focusOpacity})`:nr(e.palette.primary.dark,e.palette.action.focusOpacity)}},{props:{action:"reorder-above"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * var(--TreeView-itemDepth))",borderTop:`1px solid ${(e.vars||e).palette.action.active}`}},{props:{action:"reorder-below"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * var(--TreeView-itemDepth))",borderBottom:`1px solid ${(e.vars||e).palette.action.active}`}},{props:{action:"move-to-parent"},style:{marginLeft:"calc(var(--TreeView-indentMultiplier) * calc(var(--TreeView-itemDepth) - 1))",borderBottom:`1px solid ${(e.vars||e).palette.action.active}`}}]}));function of(e){return null==e.action?null:de(rf,Su({},e))}function nf(t){const{children:r,itemId:o,id:n}=t,{wrapItem:i,store:a}=Uu(),l=Ip(a,Rp.treeItemIdAttribute,o,n);return de(e.Fragment,{children:i({children:r,itemId:o,store:a,idAttribute:l})})}"production"!==process.env.NODE_ENV&&(of.propTypes={action:Ni.oneOf(["make-child","move-to-parent","reorder-above","reorder-below"]),style:Ni.object}),"production"!==process.env.NODE_ENV&&(nf.propTypes={children:Ni.node,id:Ni.string,itemId:Ni.string.isRequired});const af=or("input",{name:"MuiTreeItem",slot:"LabelInput"})(({theme:e})=>Su({},e.typography.body1,{width:"100%",backgroundColor:(e.vars||e).palette.background.paper,borderRadius:e.shape.borderRadius,border:"none",padding:"0 2px",boxSizing:"border-box","&:focus":{outline:`1px solid ${(e.vars||e).palette.primary.main}`}})),lf=["visible"],sf=["id","itemId","label","disabled","disableSelection","children","slots","slotProps","classes"],df=Mu(),cf=or("li",{name:"MuiTreeItem",slot:"Root"})({listStyle:"none",margin:0,padding:0,outline:0}),uf=or("div",{name:"MuiTreeItem",slot:"Content",shouldForwardProp:e=>Km(e)&&"status"!==e})(({theme:e})=>({padding:e.spacing(.5,1),paddingLeft:`calc(${e.spacing(1)} + var(--TreeView-itemChildrenIndentation) * var(--TreeView-itemDepth))`,borderRadius:e.shape.borderRadius,width:"100%",boxSizing:"border-box",position:"relative",display:"flex",alignItems:"center",gap:e.spacing(1),cursor:"pointer",WebkitTapHighlightColor:"transparent","&:hover":{backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},"&[data-disabled]":{opacity:(e.vars||e).palette.action.disabledOpacity,backgroundColor:"transparent",cursor:"auto"},"&[data-focused]":{backgroundColor:(e.vars||e).palette.action.focus},"&[data-selected]":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:nr(e.palette.primary.main,e.palette.action.selectedOpacity),"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:nr(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:nr(e.palette.primary.main,e.palette.action.selectedOpacity)}}},"&[data-selected][data-focused]":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:nr(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}})),pf=or("div",{name:"MuiTreeItem",slot:"Label",shouldForwardProp:e=>Km(e)&&"editable"!==e})(({theme:e})=>Su({width:"100%",boxSizing:"border-box",minWidth:0,position:"relative",overflow:"hidden"},e.typography.body1,{variants:[{props:({editable:e})=>e,style:{paddingLeft:"2px"}}]})),hf=or("div",{name:"MuiTreeItem",slot:"IconContainer"})({width:16,display:"flex",flexShrink:0,justifyContent:"center",position:"relative",cursor:"inherit","& svg":{fontSize:18}}),mf=or(ir,{name:"MuiTreeItem",slot:"GroupTransition",overridesResolver:(e,t)=>t.groupTransition})({margin:0,padding:0}),ff=or("div",{name:"MuiTreeItem",slot:"ErrorIcon"})({position:"absolute",right:-3,width:7,height:7,borderRadius:"50%",backgroundColor:"red"}),gf=or(Vt,{name:"MuiTreeItem",slot:"LoadingIcon"})({color:"text.primary"}),xf=or(e.forwardRef((e,t)=>{const{visible:r}=e,o=Ju(e,lf);return r?de(ar,Su({},o,{ref:t})):null}),{name:"MuiTreeItem",slot:"Checkbox"})({padding:0});"production"!==process.env.NODE_ENV&&(xf.displayName="TreeItemCheckbox");const bf=e.forwardRef(function(e,t){const r=df({props:e,name:"MuiTreeItem"}),{id:o,itemId:n,label:i,disabled:a,disableSelection:l,children:s,slots:d={},slotProps:c={},classes:u}=r,p=Ju(r,sf),{getContextProviderProps:h,getRootProps:m,getContentProps:f,getIconContainerProps:g,getCheckboxProps:x,getLabelProps:b,getGroupTransitionProps:v,getLabelInputProps:y,getDragAndDropOverlayProps:S,getErrorContainerProps:k,getLoadingContainerProps:B,status:w}=Jm({id:o,itemId:n,children:s,label:i,disabled:a,disableSelection:l}),C=(e=>{const{classes:t}=Ku();return Tu({root:["root"],content:["content"],iconContainer:["iconContainer"],checkbox:["checkbox"],label:["label"],groupTransition:["groupTransition"],labelInput:["labelInput"],dragAndDropOverlay:["dragAndDropOverlay"],errorIcon:["errorIcon"],loadingIcon:["loadingIcon"],expanded:["expanded"],editing:["editing"],editable:["editable"],selected:["selected"],focused:["focused"],disabled:["disabled"]},Ym,Su({},e,{root:Au(e?.root,t.root),content:Au(e?.content,t.itemContent),iconContainer:Au(e?.iconContainer,t.itemIconContainer),checkbox:Au(e?.checkbox,t.itemCheckbox),label:Au(e?.label,t.itemLabel),groupTransition:Au(e?.groupTransition,t.itemGroupTransition),labelInput:Au(e?.labelInput,t.itemLabelInput),dragAndDropOverlay:Au(e?.dragAndDropOverlay,t.itemDragAndDropOverlay),errorIcon:Au(e?.errorIcon,t.itemErrorIcon),loadingIcon:Au(e?.loadingIcon,t.itemLoadingIcon)}))})(u),T=d.root??cf,I=Pu({elementType:T,getSlotProps:m,externalForwardedProps:p,externalSlotProps:c.root,additionalProps:{ref:t},ownerState:{},className:C.root}),A=d.content??uf,z=Pu({elementType:A,getSlotProps:f,externalSlotProps:c.content,ownerState:{},className:Au(C.content,w.expanded&&C.expanded,w.selected&&C.selected,w.focused&&C.focused,w.disabled&&C.disabled,w.editing&&C.editing,w.editable&&C.editable)}),R=d.iconContainer??hf,E=Pu({elementType:R,getSlotProps:g,externalSlotProps:c.iconContainer,ownerState:{},className:C.iconContainer}),P=d.label??pf,O=Pu({elementType:P,getSlotProps:b,externalSlotProps:c.label,ownerState:{},className:C.label}),L=d.checkbox??xf,M=Pu({elementType:L,getSlotProps:x,externalSlotProps:c.checkbox,ownerState:{},className:C.checkbox}),W=d.groupTransition??void 0,D=Pu({elementType:W,getSlotProps:v,externalSlotProps:c.groupTransition,ownerState:{},className:C.groupTransition}),F=d.labelInput??af,N=Pu({elementType:F,getSlotProps:y,externalSlotProps:c.labelInput,ownerState:{},className:C.labelInput}),H=d.dragAndDropOverlay??of,V=Pu({elementType:H,getSlotProps:S,externalSlotProps:c.dragAndDropOverlay,ownerState:{},className:C.dragAndDropOverlay}),Q=d.errorIcon??ff,j=Pu({elementType:Q,getSlotProps:k,externalSlotProps:c.errorIcon,ownerState:{},className:C.errorIcon}),G=d.loadingIcon??gf,U=Pu({elementType:G,getSlotProps:B,externalSlotProps:c.loadingIcon,ownerState:{},className:C.loadingIcon});return de(nf,Su({},h(),{children:ce(T,Su({},I,{children:[ce(A,Su({},z,{children:[ce(R,Su({},E,{children:[w.error&&de(Q,Su({},j)),w.loading?de(G,Su({},U)):de(tf,{status:w,slots:d,slotProps:c})]})),de(L,Su({},M)),w.editing?de(F,Su({},N)):de(P,Su({},O)),de(H,Su({},V))]})),s&&de(mf,Su({as:W},D))]}))}))});"production"!==process.env.NODE_ENV&&(bf.displayName="TreeItem"),"production"!==process.env.NODE_ENV&&(bf.propTypes={children:Ni.any,classes:Ni.object,className:Ni.string,disabled:Ni.bool,disableSelection:Ni.bool,id:Ni.string,itemId:Ni.string.isRequired,label:Ni.node,onBlur:Ni.func,onFocus:function(e,t,r,o,n){if("production"===process.env.NODE_ENV)return null;const i=n||t;return void 0!==e[t]?new Error(`The prop \`${i}\` is not supported. Please remove it.`):null},onKeyDown:Ni.func,slotProps:Ni.object,slots:Ni.object,sx:Ni.oneOfType([Ni.arrayOf(Ni.oneOfType([Ni.func,Ni.object,Ni.bool])),Ni.func,Ni.object])});const vf=e=>e.charAt(0).toUpperCase()+e.slice(1),yf={compact:{minHeight:"24px",fontSize:"13px",py:"2px",px:"10px",iconSize:16,gap:"6px"},default:{minHeight:"32px",fontSize:"14px",py:"4px",px:"12px",iconSize:18,gap:"8px"}},Sf={none:{},slide:{"& .MuiCollapse-root":{transition:"all 0.25s ease"}},spring:{"& .MuiCollapse-root":{transition:"all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1)"}}};function kf(e){return{outline:"none","&.Mui-focused > .MuiTreeItem-content":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},"&:focus-visible > .MuiTreeItem-content":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},"& > .MuiTreeItem-content":{minHeight:e.minHeight,fontSize:e.fontSize,fontFamily:"inherit",color:"var(--Quiet)",padding:"0 8px",borderRadius:"var(--Style-Border-Radius)",border:"1px solid transparent",transition:"color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease",backgroundColor:"transparent",outline:"none","&:hover":{color:"var(--Text)",backgroundColor:"var(--Hover)"},"&:active":{color:"var(--Text)",backgroundColor:"var(--Pressed)"},"&.Mui-selected":{color:"var(--Text)",fontWeight:600,backgroundColor:"var(--Pressed)",padding:"0 8px","&:hover":{backgroundColor:"var(--Hover)"}},"&.Mui-disabled":{opacity:.45}},"& > .MuiTreeItem-content .MuiTreeItem-label":{fontSize:e.fontSize,fontFamily:"inherit",lineHeight:e.minHeight,padding:0,width:"100%"},"& > .MuiTreeItem-content .MuiTreeItem-iconContainer":{width:e.iconSize+"px",color:"inherit",zIndex:1},"& > .MuiTreeItem-group":{marginLeft:"12px",borderLeft:"1px solid var(--Border)",paddingLeft:"8px"}}}function Bf({item:e,d:t,isCompact:r}){const o=r?bo:ao;return ce(h,{sx:{display:"flex",alignItems:"center",gap:t.gap,width:"100%"},children:[e.icon&&de(jo,{size:"small",sx:{color:"inherit",flexShrink:0},children:e.icon}),de(o,{style:{flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",color:"inherit",fontWeight:"inherit"},children:e.label}),e.badge&&de(h,{sx:{flexShrink:0},children:e.badge})]})}function wf(e=[],t="default",r="primary",o="default",n=[]){const i=yf[t]||yf.default,a="compact"===t;return vf(r),e.map(e=>de(bf,{itemId:e.id,disabled:e.disabled,label:de(Bf,{item:e,d:i,isCompact:a}),sx:{...kf(i),...e.sx||{}},children:e.children&&e.children.length>0?wf(e.children,t,r,o,n):null},e.id))}function Cf({color:e="default",variant:t="solid",density:o="default",animation:i="slide",selectionStyle:a,items:l=Tf,selectionMode:s="single",checkboxSelection:d=!1,disableSelection:c=!1,disabledItemsFocusable:u=!1,defaultExpandedItems:p,expandedItems:m,onExpandedItemsChange:f,selectedItems:g,onSelectedItemsChange:x,onItemExpansionToggle:b,onItemSelectionToggle:v,slots:y,"aria-label":S="Tree view",className:k="",sx:B={},...w}){const C=a||t,T=vf(e),I="light"===C?"Surface-Brightest":"Surface-Dim",[A,z]=r(g||("multi"===s?[]:null)),R=void 0!==g?g:A,E=Array.isArray(R)?R:R?[R]:[],P=n((e,t)=>{void 0===g&&z(t),x?.(e,t)},[g,x]),O={};return void 0!==m&&(O.expandedItems=m),void 0!==f&&(O.onExpandedItemsChange=f),void 0!==p&&(O.defaultExpandedItems=p),de(h,{"data-theme":T,"data-surface":I,className:"omni-treeview omni-treeview-"+C+" omni-treeview-"+e+" omni-treeview-"+o+(k?" "+k:""),sx:{backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",...Sf[i]||{},...B},children:de(Oh,{"aria-label":S,multiSelect:"multi"===s,checkboxSelection:d,disableSelection:c,disabledItemsFocusable:u,selectedItems:R,onSelectedItemsChange:P,onItemExpansionToggle:b,onItemSelectionToggle:v,slots:{expandIcon:()=>de(jo,{size:"small",sx:{color:"inherit"},children:de(Kt,{})}),collapseIcon:()=>de(jo,{size:"small",sx:{color:"inherit"},children:de(Se,{})}),...y},sx:{p:"8px","& .MuiTreeItem-root":{fontFamily:"inherit"},"& .MuiTreeItem-content.Mui-focused":{outline:"none"},"& .MuiTreeItem-content:focus-visible":{outline:"none"}},...O,...w,children:wf(l,o,e,C,E)})})}const Tf=[{id:"1",label:"Design System",children:[{id:"1-1",label:"Foundations",children:[{id:"1-1-1",label:"Colors"},{id:"1-1-2",label:"Typography"},{id:"1-1-3",label:"Spacing"}]},{id:"1-2",label:"Components",children:[{id:"1-2-1",label:"Buttons"},{id:"1-2-2",label:"Inputs"},{id:"1-2-3",label:"Navigation",disabled:!0}]}]},{id:"2",label:"Tokens",children:[{id:"2-1",label:"Light Mode"},{id:"2-2",label:"Dark Mode"}]},{id:"3",label:"Changelog"}],If=e=>de(Cf,{variant:"solid",...e}),Af=e=>de(Cf,{variant:"light",...e}),zf=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Rf=[{id:"home",label:"Home"},{id:"products",label:"Products",children:[{id:"featured",label:"Featured"},{id:"new",label:"New Arrivals"},{id:"sale",label:"On Sale"}]},{id:"about",label:"About"},{id:"contact",label:"Contact"}];function Ef({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Pf(){const[e,t]=r(!1),[o,n]=r("medium"),[i,a]=r("left"),[l,s]=r(null),[d,c]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Drawer"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:l,surface:d,children:de(In,{variant:"default",onClick:()=>t(!0),children:"Open Drawer"})}),de(Vi,{code:(()=>{const e=["open={open}","onClose={handleClose}"];return"medium"!==o&&e.push('size="'+o+'"'),"left"!==i&&e.push('anchor="'+i+'"'),"<Drawer "+e.join(" ")+">\n <DrawerHeader>\n <H5>Navigation</H5>\n <DrawerClose onClick={handleClose} />\n </DrawerHeader>\n <DrawerContent>\n <OmniTreeView items={navItems} />\n </DrawerContent>\n</Drawer>"})(),language:"JSX",wrap:!0,sx:{mt:2}}),ce(xu,{open:e,onClose:()=>t(!1),size:o,anchor:i,children:[ce(vu,{children:[de(Zr,{children:"Navigation"}),de(bu,{onClick:()=>t(!1)})]}),de(yu,{children:de(Cf,{items:Rf,variant:"solid",color:"default",defaultExpandedItems:["products"],sx:{border:"none",borderRadius:0}})})]})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:l,onThemeChange:s,surface:d,onSurfaceChange:c})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Ef,{label:zf(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ANCHOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["left","right","top","bottom"].map(e=>de(Ef,{label:zf(e),selected:i===e,onClick:()=>a(e)},e))})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="dialog" aria-modal="true"'},{label:"Focus",value:"Focus trapped inside drawer. Returns to trigger on close."},{label:"Keyboard",value:"Escape closes. Tab cycles focusable elements."},{label:"Backdrop",value:"Click closes. Body scroll locked while open."},{label:"Close",value:'Button with aria-label="Close drawer"'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Of={small:{minHeight:"120px",padding:"16px",iconSize:"20px",gap:1},medium:{minHeight:"200px",padding:"32px 24px",iconSize:"32px",gap:2},large:{minHeight:"300px",padding:"48px 24px",iconSize:"48px",gap:3}};function Lf({onFiles:e,accept:t,multiple:i=!1,size:a="medium",disabled:l=!1,icon:s,label:d,sublabel:c,children:u,className:p="",sx:m={},...f}){const[g,x]=r(!1),b=o(null),v=o(0),y=Of[a]||Of.medium,S=n(t=>{!l&&t?.length&&e?.(Array.from(t))},[l,e]),k=n(e=>{e.preventDefault(),e.stopPropagation(),v.current=0,x(!1),l||S(e.dataTransfer.files)},[l,S]),B=n(e=>{e.preventDefault(),e.stopPropagation()},[]),w=n(e=>{e.preventDefault(),e.stopPropagation(),v.current++,l||x(!0)},[l]),C=n(e=>{e.preventDefault(),e.stopPropagation(),v.current--,0===v.current&&x(!1)},[]),T=n(()=>{l||b.current?.click()},[l]),I=n(e=>{l||"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),b.current?.click())},[l]),A=n(e=>{S(e.target.files),e.target.value=""},[S]),z=s||sr,R=i?"Drag and drop files here":"Drag and drop file here";return ce(h,{role:"button",tabIndex:l?-1:0,"aria-label":d||R,"aria-disabled":l||void 0,onClick:T,onKeyDown:I,onDrop:k,onDragOver:B,onDragEnter:w,onDragLeave:C,className:"drop-zone drop-zone-"+a+(g?" drop-zone-dragging":"")+(l?" drop-zone-disabled":"")+" "+p,sx:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:y.gap,minHeight:y.minHeight,padding:y.padding,border:"2px dashed",borderColor:g?"var(--Buttons-Primary-Border)":"var(--Buttons-Default-Border)",borderRadius:"32px",backgroundColor:g?"var(--Hover)":"transparent",color:"var(--Text)",cursor:l?"not-allowed":"pointer",opacity:l?.5:1,outline:"none",transition:"background-color 0.2s ease, border-color 0.2s ease",textAlign:"center",...!l&&{"&:hover":{backgroundColor:"var(--Hover)",borderColor:"var(--Buttons-Primary-Border)"},"&:active":{backgroundColor:"var(--Pressed)",borderColor:"var(--Buttons-Primary-Border)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"2px",borderColor:"var(--Buttons-Primary-Border)"}},...m},...f,children:[de("input",{ref:b,type:"file",accept:t,multiple:i,onChange:A,style:{display:"none"},"aria-hidden":"true",tabIndex:-1}),u||ce(ue,{children:[de(z,{sx:{fontSize:y.iconSize,color:"var(--Text-Quiet)"}}),de(ao,{style:{color:"var(--Text)"},children:d||R}),de(bo,{style:{color:"var(--Text-Quiet)"},children:c||"or click to browse"})]})]})}const Mf={small:{px:"12px",py:"8px",fontSize:"13px",iconSize:"18px",gap:"8px"},medium:{px:"16px",py:"12px",fontSize:"14px",iconSize:"20px",gap:"10px"},large:{px:"20px",py:"14px",fontSize:"16px",iconSize:"22px",gap:"12px"}};function Wf({children:e,variant:t="light",color:r="info",size:o="medium",startDecorator:n,endDecorator:i,className:a="",sx:l={},...s}){const d=(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===r?"Default":r),c=Mf[o]||Mf.medium,u="default"===r?"Default":d,p="light"===t?"Surface-Brightest":"Surface",m="var(--Buttons-"+d+"-Border)",f=ce(ue,{children:[n&&de(h,{className:"alert-start-decorator",sx:{display:"inline-flex",alignItems:"center",fontSize:c.iconSize,lineHeight:1,flexShrink:0,mt:"2px"},children:n}),de(h,{className:"alert-message",sx:{flex:1,minWidth:0},children:"string"==typeof e?de("small"===o?ao:co,{children:e}):e}),i&&de(h,{className:"alert-end-decorator",sx:{display:"inline-flex",alignItems:"flex-start",flexShrink:0,gap:c.gap,paddingTop:"2px"},children:i})]});return de(h,{role:"alert",className:"alert alert-"+t+" alert-"+o+" alert-"+r+" "+a,sx:{border:"1px solid "+m,borderRadius:"var(--Style-Border-Radius)",overflow:"hidden",boxShadow:ln,...l},...s,children:de(h,{"data-theme":u,"data-surface":p,className:"alert-inner",sx:{display:"flex",alignItems:"flex-start",gap:c.gap,padding:c.py+" "+c.px,fontSize:c.fontSize,fontFamily:"inherit",lineHeight:1.5,color:"var(--Text)",backgroundColor:"var(--Background)",borderRadius:"calc(var(--Style-Border-Radius) - 1px)"},children:f})})}const Df=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Ff=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Nf={info:de(ve,{}),success:de(ge,{}),warning:de(xe,{}),error:de(be,{})};function Hf({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Vf({color:e,selected:t,onClick:r}){const o=Df(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Qf(){const[e,t]=r("light"),[o,n]=r("info"),[i,a]=r("medium"),[l,s]=r(!0),[d,c]=r(null),[u,p]=r("Surface"),m=l&&Nf[o]?de(jo,{size:"small",sx:{color:"inherit"},children:Nf[o]}):void 0;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Alert"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:480},children:de(Wf,{variant:e,color:o,size:i,startDecorator:m,children:"This is an alert message. Check the details for more information."})})}),de(Vi,{code:(()=>{const t=['variant="'+e+'"'];return"info"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),l&&Nf[o]&&t.push("startDecorator={<Icon><"+Df(o)+"Icon /></Icon>}"),"<Alert "+t.join(" ")+">\n This is an alert message.\n</Alert>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["solid","light"].map(r=>de(Hf,{label:Df(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Ff.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Vf,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Hf,{label:Df(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Icon"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Start decorator icon"})]}),de(ta,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Show icon"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="alert" — live region, announced immediately'},{label:"Border",value:"var(--Buttons-{Color}-Border) on outer shell"},{label:"Shadow",value:"var(--Effect-Level-3)"},{label:"Icons",value:"Decorative — aria-hidden by default via Icon component"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const jf={small:{px:"12px",py:"8px",fontSize:"13px",gap:"8px",minWidth:"240px"},medium:{px:"16px",py:"10px",fontSize:"14px",gap:"12px",minWidth:"300px"},large:{px:"20px",py:"14px",fontSize:"16px",gap:"16px",minWidth:"360px"}};function Gf({children:e,open:t=!1,onClose:r,variant:a="light",color:l="info",size:s="medium",anchor:d="bottom",autoHideDuration:c,startDecorator:u,endDecorator:p,action:m,className:f="",sx:g={},...x}){const b=o(null),v=(e=>e.charAt(0).toUpperCase()+e.slice(1))("default"===l?"Default":l),y=jf[s]||jf.medium,S="small"===s?ao:co,k="default"===l?"Default":v,B="light"===a?"Surface-Brightest":"Surface",w="var(--Buttons-"+v+"-Border)";i(()=>{if(t&&c&&c>0)return b.current=setTimeout(()=>{r?.({},"timeout")},c),()=>clearTimeout(b.current)},[t,c,r]),i(()=>{if(!t)return;const e=e=>{"Escape"===e.key&&r?.(e,"escapeKeyDown")};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[t,r]);const C=n(()=>{b.current&&clearTimeout(b.current)},[]),T=n(()=>{t&&c&&c>0&&(b.current=setTimeout(()=>{r?.({},"timeout")},c))},[t,c,r]),I="top"===d?{from:{transform:"translateX(-50%) translateY(-120%)"},to:{transform:"translateX(-50%) translateY(0)"}}:{from:{transform:"translateX(-50%) translateY(120%)"},to:{transform:"translateX(-50%) translateY(0)"}};return t?de(h,{role:"alert","aria-live":"polite","aria-atomic":"true",onMouseEnter:C,onMouseLeave:T,className:"snackbar snackbar-"+a+" snackbar-"+s+" snackbar-"+d+" snackbar-"+l+" "+f,sx:{position:"fixed",left:"50%",transform:"translateX(-50%)",..."top"===d?{top:"16px"}:{bottom:"16px"},zIndex:1400,minWidth:y.minWidth,maxWidth:"min(560px, calc(100vw - 32px))",border:"1px solid "+w,borderRadius:"var(--Style-Border-Radius)",boxShadow:ln,overflow:"hidden",animation:"snackbar-slide-in 0.3s ease forwards","@keyframes snackbar-slide-in":I,...g},...x,children:ce(h,{"data-theme":k,"data-surface":B,sx:{display:"flex",alignItems:"center",gap:y.gap,padding:y.py+" "+y.px,fontSize:y.fontSize,fontFamily:"inherit",lineHeight:1.4,color:"var(--Text)",backgroundColor:"var(--Background)",borderRadius:"calc(var(--Style-Border-Radius) - 1px)"},children:[u&&de(h,{sx:{display:"inline-flex",flexShrink:0,lineHeight:1},children:u}),de(h,{sx:{flex:1,minWidth:0},children:"string"==typeof e?de(S,{children:e}):e}),m&&de(h,{sx:{display:"inline-flex",flexShrink:0},children:m}),p&&de(h,{sx:{display:"inline-flex",flexShrink:0,lineHeight:1},children:p}),r&&de(In,{iconOnly:!0,variant:"ghost",size:"small",onClick:e=>r(e,"closeClick"),"aria-label":"Close notification",sx:{flexShrink:0,ml:"4px"},children:de(jo,{size:"small",children:de(Ot,{})})})]})}):null}const Uf=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",Xf=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],Kf={info:de(ve,{}),success:de(ge,{}),warning:de(xe,{}),error:de(be,{})};function qf({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Jf({color:e,selected:t,onClick:r}){const o=Uf(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function Yf(){const[e,t]=r("light"),[o,n]=r("info"),[i,a]=r("medium"),[l,s]=r("bottom"),[d,c]=r(!0),[u,p]=r(!0),[m,f]=r(!1),[g,x]=r(null),[b,v]=r("Surface"),y=d&&Kf[o]?de(jo,{size:"small",sx:{color:"inherit"},children:Kf[o]}):void 0;return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Snackbar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:g,surface:b,children:de(In,{variant:"default",onClick:()=>f(!0),children:"Show Snackbar"})}),de(Vi,{code:(()=>{const t=["open={open}"];return t.push('variant="'+e+'"'),"info"!==o&&t.push('color="'+o+'"'),"medium"!==i&&t.push('size="'+i+'"'),"bottom"!==l&&t.push('anchor="top"'),u&&t.push("onClose={handleClose}"),d&&Kf[o]&&t.push("startDecorator={<Icon><"+Uf(o)+"Icon /></Icon>}"),"<Snackbar\n "+t.join("\n ")+"\n>\n Operation completed successfully.\n</Snackbar>"})(),language:"JSX",wrap:!0,sx:{mt:2}}),de(Gf,{open:m,onClose:u?()=>f(!1):void 0,variant:e,color:o,size:i,anchor:l,autoHideDuration:4e3,startDecorator:y,children:"Operation completed successfully."})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:g,onThemeChange:x,surface:b,onSurfaceChange:v})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,children:["solid","light"].map(r=>de(qf,{label:Uf(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:Xf.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(Jf,{color:e,selected:o===e,onClick:n},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(qf,{label:Uf(e),selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ANCHOR"}),de(B,{direction:"row",spacing:1,children:["top","bottom"].map(e=>de(qf,{label:Uf(e),selected:l===e,onClick:()=>s(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Icon"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Start decorator icon"})]}),de(ta,{variant:"default-outline",checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Show icon"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Close Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show dismiss button"})]}),de(ta,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Close button"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="alert" aria-live="polite" aria-atomic="true"'},{label:"Close",value:'Button with aria-label="Close notification"'},{label:"Keyboard",value:"Escape closes. Auto-hides after duration."},{label:"Hover",value:"Pauses auto-hide timer on mouse enter"},{label:"Border",value:"var(--Buttons-{Color}-Border) on outer shell"},{label:"Shadow",value:"var(--Effect-Level-3)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Zf={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",white:"Neutral",black:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},$f={small:{diameter:24,thickness:3,fontSize:"9px",labelSize:"0px"},medium:{diameter:40,thickness:4,fontSize:"12px",labelSize:"12px"},large:{diameter:56,thickness:5,fontSize:"14px",labelSize:"14px"}};function _f({value:e,color:t="primary",size:r="medium",thickness:o,showValue:n=!1,children:i,className:l="",sx:s={},...d}){const c=Zf[t]||"Primary",u=$f[r]||$f.medium,p=o||u.thickness,m=null!=e,f=m?Math.min(100,Math.max(0,e)):0,g=(u.diameter-p)/2,x=2*Math.PI*g,b=m?x-f/100*x:.75*x,v="var(--Buttons-"+c+"-Border)",y="cp-grad-"+a().replace(/:/g,"");return ce(h,{role:"progressbar","aria-valuenow":m?Math.round(f):void 0,"aria-valuemin":m?0:void 0,"aria-valuemax":m?100:void 0,"aria-label":m?Math.round(f)+"% progress":"Loading",className:"circular-progress circular-progress-"+r+" circular-progress-"+t+(m?" circular-progress-value":" circular-progress-indeterminate")+" "+l,sx:{position:"relative",display:"inline-flex",alignItems:"center",justifyContent:"center",width:u.diameter+"px",height:u.diameter+"px",flexShrink:0,...!m&&{animation:"circular-progress-spin 1.2s linear infinite","@keyframes circular-progress-spin":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(360deg)"}}},...s},...d,children:[ce("svg",{viewBox:"0 0 "+u.diameter+" "+u.diameter,width:u.diameter,height:u.diameter,style:{position:"absolute",top:0,left:0,transform:"rotate(-90deg)"},children:[de("defs",{children:ce("linearGradient",{id:y,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[de("stop",{offset:"0%",stopColor:v,stopOpacity:"0"}),de("stop",{offset:"100%",stopColor:v,stopOpacity:"1"})]})}),de("circle",{cx:u.diameter/2,cy:u.diameter/2,r:g,fill:"none",stroke:"var(--Border-Variant)",strokeWidth:p,className:"circular-progress-track"}),de("circle",{cx:u.diameter/2,cy:u.diameter/2,r:g,fill:"none",stroke:"url(#"+y+")",strokeWidth:p,strokeDasharray:x,strokeDashoffset:b,strokeLinecap:"round",className:"circular-progress-indicator",style:{transition:m?"stroke-dashoffset 0.4s ease":"none"}})]}),(n||i)&&m&&de(h,{className:"circular-progress-label","aria-hidden":"true",sx:{position:"relative",zIndex:1,fontSize:u.fontSize,fontWeight:700,fontFamily:"inherit",lineHeight:1,color:"var(--Text)",userSelect:"none"},children:i||Math.round(f)+"%"})]})}const eg=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",tg=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function rg({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function og({color:e,selected:t,onClick:r}){const o=eg(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function ng(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(!1),[l,s]=r(65),[d,c]=r(!1),[u,p]=r(null),[m,f]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Circular Progress"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:u,children:de(_f,{color:e,size:o,value:i?l:void 0,showValue:i&&d})}),de(Vi,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),i&&(t.push("value={"+l+"}"),d&&t.push("showValue")),0===t.length?"<CircularProgress />":"<CircularProgress\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:u,onThemeChange:p,surface:m,onSurfaceChange:f})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:tg.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(og,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(rg,{label:eg(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Determinate"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show a static arc at a specific value"})]}),de(ta,{checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Determinate"})]}),i&&ce(ue,{children:[de(h,{sx:{mt:2},children:de(hs,{label:"Value",min:0,max:100,value:l,onChange:(e,t)=>s(t),size:"small",valueLabelDisplay:"auto"})}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Label"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Center percentage text"})]}),de(ta,{checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Show label"})]})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Role:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'role="progressbar"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Determinate:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'aria-valuenow, aria-valuemin="0", aria-valuemax="100"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Indeterminate:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'aria-label="Loading" (no value attributes)'})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Label:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Center percentage label is aria-hidden — screen readers use aria-valuenow."})]})]})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Token Reference"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Track (back circle):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Border-Variant)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Fill (progress arc):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Buttons-{Color}-Border)"})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Center label:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"var(--Text)"})]})]})]})]})})})]})})})]})]})}const ig={default:"Default",primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},ag={small:{height:"4px",borderRadius:"2px"},medium:{height:"6px",borderRadius:"3px"},large:{height:"8px",borderRadius:"4px"}};function lg({value:e,color:t="primary",size:r="medium",className:o="",sx:n={},...i}){const a=ig[t]||"Primary",l=ag[r]||ag.medium,s=null!=e,d=s?Math.min(100,Math.max(0,e)):0,c="var(--Buttons-"+a+"-Border)";return de(h,{role:"progressbar","aria-valuenow":s?Math.round(d):void 0,"aria-valuemin":s?0:void 0,"aria-valuemax":s?100:void 0,"aria-label":s?Math.round(d)+"% progress":"Loading",className:"linear-progress linear-progress-"+r+" linear-progress-"+t+(s?" linear-progress-determinate":" linear-progress-indeterminate")+" "+o,sx:{position:"relative",width:"100%",height:l.height,borderRadius:l.borderRadius,backgroundColor:"var(--Border-Variant)",overflow:"hidden",flexShrink:0,...n},...i,children:de(h,{className:"linear-progress-bar",sx:{position:"absolute",top:0,left:0,height:"100%",borderRadius:"inherit",backgroundColor:c,...s?{width:d+"%",transition:"width 0.4s ease"}:{width:"40%",animation:"linear-progress-slide 1.5s ease-in-out infinite","@keyframes linear-progress-slide":{"0%":{left:"-40%",width:"40%"},"50%":{left:"30%",width:"50%"},"100%":{left:"100%",width:"40%"}}}}})})}const sg=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",dg=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}];function cg({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function ug({color:e,selected:t,onClick:r}){const o=sg(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function pg(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r(!1),[l,s]=r(65),[d,c]=r(null),[u,p]=r("Surface");return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Linear Progress"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:d,surface:u,children:de(h,{sx:{width:"100%",maxWidth:400},children:de(lg,{color:e,size:o,value:i?l:void 0})})}),de(Vi,{code:(()=>{const t=[];return"default"!==e&&t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),i&&t.push("value={"+l+"}"),0===t.length?"<LinearProgress />":"<LinearProgress\n "+t.join("\n ")+"\n/>"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:d,onThemeChange:c,surface:u,onSurfaceChange:p})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:dg.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(ug,{color:r,selected:e===r,onClick:t},r))})]},r.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(cg,{label:sg(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Determinate"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show a static bar at a specific value"})]}),de(ta,{variant:"default-outline",checked:i,onChange:e=>a(e.target.checked),size:"small","aria-label":"Determinate"})]}),i&&de(h,{sx:{mt:2},children:de(hs,{label:"Value",min:0,max:100,value:l,onChange:(e,t)=>s(t),size:"small",valueLabelDisplay:"auto"})})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="progressbar"'},{label:"Determinate",value:'aria-valuenow, aria-valuemin="0", aria-valuemax="100"'},{label:"Indeterminate",value:'aria-label="Loading" (no value attributes)'},{label:"Track",value:"var(--Border-Variant)"},{label:"Fill",value:"var(--Buttons-{Color}-Border)"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const hg=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]}],mg=["photo","icon","initials"],fg={photo:"Photo",icon:"Icon",initials:"Initials"},gg=["xxx-small","xx-small","x-small","small","medium","large","x-large","xx-large"],xg={"xxx-small":"XXXS","xx-small":"XXS","x-small":"XS",small:"Small",medium:"Medium",large:"Large","x-large":"XL","xx-large":"XXL"};function bg({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function vg({color:e,selected:t,onClick:r}){const o=(n=e)?n.charAt(0).toUpperCase()+n.slice(1):"";var n;return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function yg(){const[e,t]=r("default"),[o,n]=r("medium"),[i,a]=r("initials"),[l,s]=r(!1),[d,c]=r(!1),[u,p]=r(!1),[m,f]=r(null),[g,x]=r("Surface"),b="photo"===i,v=()=>{const t={size:o,clickable:l,insideButton:d};return b||(t.color=e),"initials"===i&&(t.initials="LN"),"photo"===i&&(t.src="https://i.pravatar.cc/150?img=3",t.alt="User avatar"),t};return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Avatar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:m,surface:g,children:u?ce(Jo,{max:3,size:o,children:[de(qo,{...v()}),de(qo,{color:e,size:o,initials:"AB"}),de(qo,{color:e,size:o,initials:"CD"}),de(qo,{color:e,size:o,initials:"EF"})]}):de(qo,{...v()})}),de(Vi,{code:(()=>{const t=[];return b||"default"===e||t.push('color="'+e+'"'),"medium"!==o&&t.push('size="'+o+'"'),"initials"===i&&t.push('initials="LN"'),"photo"===i&&t.push('src="..." alt="User avatar"'),l&&t.push("clickable onClick={handleClick}"),d&&t.push("insideButton"),u?"<AvatarGroup max={3}>\n <Avatar "+t.join(" ")+' />\n <Avatar initials="AB" />\n <Avatar initials="CD" />\n <Avatar initials="EF" />\n</AvatarGroup>':"<Avatar "+t.join(" ")+" />"})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:m,onThemeChange:f,surface:g,onSurfaceChange:x})}),ce(h,{sx:{opacity:b?.4:1,pointerEvents:b?"none":"auto"},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:hg.map(r=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:r.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:r.colors.map(r=>de(vg,{color:r,selected:e===r,onClick:t},r))})]},r.label))}),b&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:8},children:"Color is ignored when the avatar shows a photo — the image carries the visual."})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:gg.map(e=>de(bg,{label:xg[e],selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"CONTENT"}),de(B,{direction:"row",spacing:1,children:mg.map(e=>de(bg,{label:fg[e],selected:i===e,onClick:()=>a(e)},e))})]}),ce(h,{sx:{mt:3,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Clickable"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Interactive with hover/focus states"})]}),de(ta,{variant:"default-outline",checked:l,onChange:e=>s(e.target.checked),size:"small","aria-label":"Clickable"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Inside Button"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Adds 2px horizontal margin so the avatar sits cleanly in a Button"})]}),de(ta,{variant:"default-outline",checked:d,onChange:e=>c(e.target.checked),size:"small","aria-label":"Inside Button"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Group"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show as AvatarGroup with overflow"})]}),de(ta,{variant:"default-outline",checked:u,onChange:e=>p(e.target.checked),size:"small","aria-label":"Show group"})]})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:de(B,{spacing:3,children:ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="img" (static) or role="button" (clickable)'},{label:"Label",value:'aria-label from alt, initials, or "Avatar"'},{label:"Image",value:"alt text on <img>. Falls back to initials or icon on error."},{label:"Clickable",value:"Rendered as <button>. Focus ring: 3px solid var(--Focus-Visible)."},{label:"Group",value:'role="group" aria-label="Avatar group, N avatars"'}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})})})})]})})})]})]})}const Sg=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",kg=["primary","secondary","tertiary","neutral","info","success","warning","error"];function Bg({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)",fontSize:"11px",fontWeight:700},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function wg({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(Bg,{ratio:t,threshold:r})]})}function Cg({color:e,selected:t,onClick:r}){const o=Sg(e);return de(w,{title:o,arrow:!0,children:de(h,{onClick:()=>r(e),role:"button","aria-label":"Select "+o+" color","aria-pressed":t,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:24,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})})}function Tg({label:e,selected:t,onClick:r}){return de(h,{component:"button",onClick:r,sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",cursor:"pointer",border:"2px solid var(--Buttons-Primary-Button)",borderRadius:"var(--Style-Border-Radius)",backgroundColor:t?"var(--Buttons-Primary-Button)":"transparent",color:t?"var(--Buttons-Primary-Text)":"var(--Text)",padding:"4px 12px",fontSize:"14px",fontFamily:"inherit",fontWeight:500,whiteSpace:"nowrap",flexShrink:0,transition:"background-color 0.15s ease, color 0.15s ease","&:hover":{backgroundColor:t?"var(--Buttons-Primary-Hover)":"var(--Surface-Dim)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:"2px"}},children:e})}function Ig(){const[e,t]=r(0),[o,n]=r("solid"),[a,l]=r("primary"),[s,d]=r("medium"),[c,u]=r("5"),[p,m]=r(!1),[f,g]=r(!1),[x,S]=r({}),k=()=>"solid"===o?a:a+"-"+o,w=()=>{if(p)return;const e=parseInt(c,10);return isNaN(e)||String(e)!==c.trim()?c||void 0:e};i(()=>{const e=Sg(a),t={};"solid"===o?(t.badgeBg=Xi("--Buttons-"+e+"-Button"),t.badgeText=Xi("--Buttons-"+e+"-Text"),t.badgeBorder=null):"outline"===o?(t.badgeBg=Xi("--Background"),t.badgeText=Xi("--Text"),t.badgeBorder=Xi("--Buttons-"+e+"-Border")):"light"===o&&(t.badgeBg=Xi("--Buttons-"+e+"-Button"),t.badgeText=Xi("--Buttons-"+e+"-Text"),t.badgeBorder=Xi("--Buttons-"+e+"-Border")),t.background=Xi("--Background"),t.focusVisible=Xi("--Focus-Visible"),S(t)},[o,a]);const C={small:{badge:"16px",dot:"8px",font:"10px"},medium:{badge:"20px",dot:"10px",font:"12px"},large:{badge:"24px",dot:"12px",font:"14px"}};return ce(h,{sx:{width:"100%"},children:[de(Jr,{style:{marginBottom:8},children:"Badge"}),de(co,{color:"quiet",style:{marginBottom:24},children:"Small label attached to an element showing status or count. Solid, outline, and light variants across all 8 colors."}),ce(N,{value:e,onChange:(e,r)=>t(r),sx:{borderBottom:"1px solid var(--Border)",mb:0},children:[de(H,{label:"Playground"}),de(H,{label:"Accessibility"})]}),0===e&&ce(I,{container:!0,sx:{minHeight:400},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"calc((100vw - 432px) / 2)"},flexShrink:0},children:[de(h,{sx:{p:4,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",minHeight:200,backgroundColor:"var(--Background)",borderBottom:"1px solid var(--Border)"},children:ce(B,{direction:"row",spacing:6,alignItems:"center",children:[de(en,{variant:k(),size:s,badgeContent:w(),dot:p,showZero:f,children:de(dr,{sx:{fontSize:32,color:"var(--Text-Quiet)"}})}),de(en,{variant:k(),size:s,badgeContent:w(),dot:p,showZero:f,children:de(Ae,{sx:{fontSize:32,color:"var(--Text-Quiet)"}})}),de(en,{variant:k(),size:s,badgeContent:w(),dot:p,showZero:f,children:de(Re,{sx:{fontSize:32,color:"var(--Text-Quiet)"}})})]})}),de(Vi,{code:(()=>{const e=['variant="'+k()+'"','size="'+s+'"'];if(p)e.push("dot");else{const t=w();"number"==typeof t?e.push("badgeContent={"+t+"}"):t&&e.push('badgeContent="'+t+'"')}return f&&e.push("showZero"),"<Badge "+e.join(" ")+">\n <MailIcon />\n</Badge>"})(),language:"JSX",sx:{borderRadius:0,borderBottom:"1px solid var(--Border)"}})]}),ce(I,{item:!0,sx:{width:{xs:"calc(100vw - 432px)",md:"calc((100vw - 432px) / 2)"},flexShrink:0,p:3,backgroundColor:"var(--Container)",overflowY:"auto"},children:[de(Yr,{children:"Playground"}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),de(B,{direction:"row",spacing:1,flexWrap:"wrap",sx:{gap:1},children:["solid","outline","light"].map(e=>de(Tg,{label:Sg(e),selected:o===e,onClick:()=>n(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:kg.map(e=>de(Cg,{color:e,selected:a===e,onClick:l},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SIZE"}),de(B,{direction:"row",spacing:1,children:["small","medium","large"].map(e=>de(Tg,{label:Sg(e),selected:s===e,onClick:()=>d(e)},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Badge ",C[s]?.badge," · Dot ",C[s]?.dot," · Font ",C[s]?.font]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BADGE CONTENT"}),de(y,{size:"small",value:c,onChange:e=>u(e.target.value),placeholder:"Number or text",disabled:p,sx:{width:"160px","& .MuiOutlinedInput-root":{fontFamily:"inherit",fontSize:"14px",backgroundColor:"var(--Background)","& fieldset":{borderColor:"var(--Border)"},"&:hover fieldset":{borderColor:"var(--Border)"},"&.Mui-focused fieldset":{borderColor:"var(--Buttons-Primary-Border)"}},"& .MuiOutlinedInput-input":{color:"var(--Text)",padding:"6px 12px"}}})]}),ce(h,{sx:{mt:3},children:[de(v,{control:de(b,{checked:p,onChange:e=>m(e.target.checked),size:"small"}),label:de(ao,{children:"Dot (no content)"})}),de(v,{control:de(b,{checked:f,onChange:e=>g(e.target.checked),size:"small"}),label:de(ao,{children:"Show zero"})})]})]})]}),1===e&&ce(h,{sx:{p:4},children:[de(Yr,{children:"Accessibility Requirements"}),ce(ao,{color:"quiet",style:{marginBottom:32},children:["Based on current Playground settings: ",o," · ",a," · ",s]}),ce(B,{spacing:4,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Badge Text Contrast"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Badge text must have ≥ 4.5:1 contrast against badge background (WCAG 1.4.3 AA)"}),de(wg,{label:"Badge Text vs. Badge Background",ratio:Ui(x.badgeText,x.badgeBg),threshold:4.5,note:"solid"===o?"var(--Buttons-{C}-Text) vs var(--Buttons-{C}-Button)":"outline"===o?"var(--Text) vs var(--Background)":"var(--Buttons-{C}-Text) vs var(--Buttons-{C}-Button)"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Badge Visibility"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Badge background (or border) must have ≥ 3:1 contrast against page background (WCAG 1.4.11)"}),(()=>{const e=Ui(x.badgeBg,x.background),t=x.badgeBorder?Ui(x.badgeBorder,x.background):null;return de(wg,{label:"Badge vs. Page Background",ratio:(r=e,n=t,r||n?r?n?parseFloat(r)>=parseFloat(n)?r:n:r:n:null),threshold:3.1,note:"outline"===o?"Border "+(t||"--")+":1 — outline relies on border contrast":"BG "+(e||"--")+":1"});var r,n})()]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Badge Sizing"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"Badge dimensions per size setting"}),de(h,{sx:{display:"flex",justifyContent:"space-between",py:1.5,borderBottom:"1px solid var(--Border)"},children:ce(h,{children:[ce(ao,{children:["Badge height (",s,")"]}),ce(bo,{style:{color:"var(--Text-Quiet)"},children:[C[s]?.badge," height · ",C[s]?.font," font · pill shape"]})]})}),de(h,{sx:{display:"flex",justifyContent:"space-between",py:1.5,borderBottom:"1px solid var(--Border)"},children:ce(h,{children:[ce(ao,{children:["Dot size (",s,")"]}),ce(bo,{style:{color:"var(--Text-Quiet)"},children:[C[s]?.dot," diameter circle"]})]})})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Container)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA & Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{style:{display:"block",marginBottom:2},children:"Screenreader support:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'MUI Badge renders badge content in a visually-hidden span for assistive technology. Numeric content is announced (e.g. "5 notifications").'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{style:{display:"block",marginBottom:2},children:"Dot variant:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Dot badges are purely decorative. Ensure the parent element conveys status to assistive tech via aria-label or similar."})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{style:{display:"block",marginBottom:2},children:"Max overflow:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'When content exceeds max (default 99), displays "99+" visually but announces the actual number to screenreaders.'})]})]})]})]})]})]})}const Ag=e=>e.charAt(0).toUpperCase()+e.slice(1);function zg(e){return e&&"default"!==e&&"border-variant"!==e?"border"===e?"var(--Border)":"var(--Icons-"+Ag(e)+")":"var(--Border-Variant)"}function Rg(e,t){const r=e&&!["default","border","border-variant"].includes(e)?Ag(e):"Default",o=zg(e);return"light"===t?{bg:"var(--Tag-"+r+"-BG)",text:"var(--Tag-"+r+"-Text)",border:"1px solid "+o}:{bg:"var(--Background)",text:"var(--Text)",border:"1px solid "+o}}const Eg={small:1,medium:2,large:4};function Pg({color:e="default",orientation:t="horizontal",size:r="small",children:o,indicatorText:n,indicatorStyle:i="outline",textAlign:a="center",className:l="",sx:s={},...d}){const c=zg(e),u=Eg[r]||Eg.small,p=!(!o&&!n),m=o||n,f="vertical"===t;if(f&&!p)return de(h,{role:"separator","aria-orientation":"vertical",className:"divider-vertical divider-"+e+" "+l,sx:{display:"inline-block",width:u+"px",alignSelf:"stretch",minHeight:24,backgroundColor:c,flexShrink:0,...s},...d});if(f&&p){const t=Rg(e,i),r="top"===a?"0 0 10%":"1 1 auto",o="top"===a?"1 1 auto":"bottom"===a?"0 0 10%":"1 1 auto";return ce(h,{role:"separator","aria-orientation":"vertical",className:"divider-vertical divider-"+e+" divider-indicator "+l,sx:{display:"inline-flex",flexDirection:"column",alignItems:"center",alignSelf:"stretch",minHeight:24,flexShrink:0,...s},...d,children:[de(h,{sx:{flex:r,width:u+"px",backgroundColor:c}}),de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,my:1,px:.75,py:.5,borderRadius:"12px",fontSize:"11px",fontWeight:500,fontFamily:"inherit",lineHeight:1.2,whiteSpace:"nowrap",backgroundColor:t.bg,color:t.text,border:t.border,boxSizing:"border-box"},children:m}),de(h,{sx:{flex:o,width:u+"px",backgroundColor:c}})]})}if(!p)return de(h,{role:"separator","aria-orientation":"horizontal",className:"divider-horizontal divider-"+e+" "+l,sx:{width:"100%",height:u+"px",backgroundColor:c,flexShrink:0,...s},...d});const g=Rg(e,i),x="left"===a?"0 0 10%":"1 1 auto",b="left"===a?"1 1 auto":"right"===a?"0 0 10%":"1 1 auto";return ce(h,{role:"separator","aria-orientation":"horizontal",className:"divider-horizontal divider-"+e+" divider-indicator "+l,sx:{display:"flex",alignItems:"center",width:"100%",...s},...d,children:[de(h,{sx:{flex:x,height:u+"px",backgroundColor:c}}),de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,mx:2,px:1.5,py:.5,borderRadius:"12px",fontSize:"12px",fontWeight:500,fontFamily:"inherit",lineHeight:1.2,whiteSpace:"nowrap",backgroundColor:g.bg,color:g.text,border:g.border,boxSizing:"border-box"},children:m}),de(h,{sx:{flex:b,height:u+"px",backgroundColor:c}})]})}const Og={eyebrow:To,title:co,secondary:lo},Lg={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info-Medium",success:"Success-Medium",warning:"Warning-Medium",error:"Error-Medium"},Mg={primary:"Primary-Light",secondary:"Secondary-Light",tertiary:"Tertiary-Light",neutral:"Neutral-Light",info:"Info-Light",success:"Success-Light",warning:"Warning-Light",error:"Error-Light"},Wg={small:{py:.5,px:1.5,fontSize:"13px",iconSize:16,decoratorSize:28,gap:1,checkSize:"small"},medium:{py:1,px:1,fontSize:"14px",iconSize:20,decoratorSize:36,gap:1.5,checkSize:"small"},large:{py:1.5,px:2.5,fontSize:"16px",iconSize:24,decoratorSize:40,gap:2,checkSize:"medium"}};function Dg({children:e,size:t="medium",isButton:r=!1,onAction:o,ariaLabel:n}){return de(h,r?{component:"button",role:"button",tabIndex:0,"aria-label":n||"Action",onClick:e=>{e.stopPropagation(),o?.(e)},onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),e.stopPropagation(),o?.(e))},className:"list-item-decorator-button",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,padding:0,border:"none",backgroundColor:"transparent",borderRadius:"50%",cursor:"pointer",color:"inherit",transition:"background-color 0.15s ease","&:hover":{backgroundColor:"rgba(128,128,128,0.15)"},"&:active":{backgroundColor:"rgba(128,128,128,0.25)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"}},children:e}:{className:"list-item-decorator",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0},children:e})}function Fg({children:e,startDecorator:t,endDecorator:r,startDecoratorIsButton:o=!1,endDecoratorIsButton:n=!1,onStartDecoratorAction:i,onEndDecoratorAction:a,startDecoratorAriaLabel:l,endDecoratorAriaLabel:s,size:d="medium",variant:c="default",color:u,eyebrow:p,overline:m,secondary:f,clickable:g=!1,disabled:x=!1,selected:v=!1,selectionMode:y="none",onSelect:S,onClick:k,bottomBorder:B=!1,rightBorder:w=!1,sx:C={},...T}){const I=Wg[d]||Wg.medium,A=g||!!k,z="checkbox"===y||"radio"===y,R=(A||z)&&!x,E=e=>{x||(z&&S?.(e),k?.(e))};return ce(h,{component:"li",role:z?"option":A?"button":"listitem",tabIndex:R?0:void 0,"aria-disabled":x||void 0,"aria-selected":z?v:v||void 0,"aria-checked":"checkbox"===y?v:void 0,onClick:E,onKeyDown:R?e=>{x||"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),E(e))}:void 0,className:"list-item"+(v?" list-item-selected":"")+(x?" list-item-disabled":"")+(A?" list-item-clickable":"")+(z?" list-item-selectable":""),sx:{display:"flex",flexDirection:"row",alignItems:"flex-start",justifyContent:"flex-start",width:"100%",boxSizing:"border-box",gap:"var(--Sizing-1-and-Half)",py:I.py,px:I.px,minHeight:"32px",fontSize:I.fontSize,fontFamily:"inherit",color:"var(--Text)",listStyle:"none",cursor:R?"pointer":"default",opacity:x?.5:1,position:"relative",transition:"background-color 0.15s ease, box-shadow 0.15s ease",...A?{border:"1px solid var(--Border)",boxShadow:"var(--Effect-Level-1)",padding:"var(--Sizing-1)",borderRadius:"var(--Input-Radius)"}:{},...!A&&B?{borderBottom:"1px solid var(--Border-Variant)"}:{},...!A&&w?{borderRight:"1px solid var(--Border-Variant)"}:{},backgroundColor:v?"var(--Hover)":"transparent","&:hover":R?{backgroundColor:"var(--Hover)",boxShadow:"var(--Effect-Level-2)"}:{},"&:active":R?{backgroundColor:"var(--Pressed)",boxShadow:"var(--Effect-Level-1)"}:{},"&:focus-visible":{outline:"none"},"&:focus-visible::after":{content:'""',position:"absolute",inset:"1px",border:"3px solid var(--Focus-Visible)",borderRadius:"var(--Input-Inner-Focus-Visible)",pointerEvents:"none"},...C},...T,children:["checkbox"===y&&de(b,{checked:v,disabled:x,size:I.checkSize,tabIndex:-1,onClick:e=>e.stopPropagation(),onChange:()=>S?.(),sx:{p:0,mr:0,color:"inherit","&.Mui-checked":{color:"inherit"}},inputProps:{"aria-label":"Select "+("string"==typeof e?e:"item")}}),"radio"===y&&de(P,{checked:v,disabled:x,size:I.checkSize,tabIndex:-1,onClick:e=>e.stopPropagation(),onChange:()=>S?.(),sx:{p:0,mr:0,color:"inherit","&.Mui-checked":{color:"inherit"}},inputProps:{"aria-label":"Select "+("string"==typeof e?e:"item")}}),t&&de(Dg,{size:d,isButton:o,onAction:i,ariaLabel:l,children:t}),(()=>{const t=Og,r=p??m,o={display:"block",width:"100%",wordBreak:"break-word",overflowWrap:"anywhere"};return ce(h,{sx:{flex:"1 1 auto",width:"100%",minWidth:0,display:"flex",flexDirection:"column",gap:0},children:[r&&de(t.eyebrow,{style:{...o,color:"var(--Quiet)"},children:r}),null!=e&&de(t.title,{style:{...o,color:"var(--Text)"},children:e}),f&&de(t.secondary,{style:{...o,color:"var(--Quiet)"},children:f})]})})(),r&&de(Dg,{size:d,isButton:n,onAction:a,ariaLabel:s,children:r})]})}function Ng({children:e,items:r,variant:o="default",color:n="primary",size:i="medium",orientation:a="vertical",dividers:l=!1,selectionMode:s="none",selectedIndices:d=[],onSelectionChange:c,clickable:u=!1,component:p="ul",className:m="",sx:f={},...g}){const x="horizontal"===a,b="checkbox"===s||"radio"===s,v="light"===o,y="default"===o,S={};"solid"===o&&Lg[n]?S["data-theme"]=Lg[n]:v&&Mg[n]&&(S["data-theme"]=Mg[n]);return de(h,{component:p,role:b?"listbox":"list","aria-multiselectable":"checkbox"===s||void 0,...S,className:"list-container list-"+o+" list-"+n+" "+m,sx:{display:"flex",flexDirection:x?"row":"column",boxSizing:"border-box",alignItems:"stretch",gap:u?"var(--Sizing-1)":0,m:0,p:y?0:1,backgroundColor:y?"transparent":"var(--Background)",color:"var(--Text)",borderRadius:y?0:"var(--Style-Border-Radius)",width:"100%",listStyle:"none",...x?{"& > .list-item":{flex:"1 1 0",width:"auto"}}:{},...f},...g,children:(()=>{if(r&&r.length>0){const e=[];return r.forEach((t,a)=>{e.push(de(Fg,{size:i,variant:o,color:n,startDecorator:t.startDecorator,endDecorator:t.endDecorator,startDecoratorIsButton:t.startDecoratorIsButton,endDecoratorIsButton:t.endDecoratorIsButton,onStartDecoratorAction:t.onStartDecoratorAction,onEndDecoratorAction:t.onEndDecoratorAction,startDecoratorAriaLabel:t.startDecoratorAriaLabel,endDecoratorAriaLabel:t.endDecoratorAriaLabel,eyebrow:t.eyebrow??t.overline,secondary:t.secondary,clickable:u||t.clickable,disabled:t.disabled,bottomBorder:t.bottomBorder,rightBorder:t.rightBorder,selected:b?d.includes(a):t.selected,selectionMode:s,onSelect:()=>(e=>{if(c)if("radio"===s)c([e]);else{const t=d.includes(e)?d.filter(t=>t!==e):[...d,e];c(t)}})(a),onClick:t.onClick,children:t.label||t.children},"item-"+a)),l&&a<r.length-1&&e.push(de(h,{component:"li",role:"separator","aria-hidden":"true",sx:x?{width:"1px",alignSelf:"stretch",backgroundColor:"var(--Border)",flexShrink:0}:{height:"1px",backgroundColor:"var(--Border)"}},"div-"+a))}),e}if(e){const r=t.Children.toArray(e);if(!l)return r;const o=[];return r.forEach((e,t)=>{o.push(e),t<r.length-1&&o.push(de(h,{component:"li",role:"separator","aria-hidden":"true",sx:x?{width:"1px",alignSelf:"stretch",backgroundColor:"var(--Border)",flexShrink:0}:{height:"1px",backgroundColor:"var(--Border)"}},"div-"+t))}),o}return null})()})}const Hg={small:{py:"4px",px:"8px",fontSize:"13px",headerFontSize:"12px"},medium:{py:"8px",px:"12px",fontSize:"14px",headerFontSize:"13px"},large:{py:"12px",px:"16px",fontSize:"16px",headerFontSize:"14px"}};function Vg({children:e,columns:t,rows:r,footerRows:o,variant:n="default",color:i="primary",size:a="medium",stripe:l="none",stickyHeader:s=!1,stickyFooter:d=!1,className:c="",sx:u={},...p}){const m=Hg[a]||Hg.medium,f="solid"===n,g="outlined"===n,x="light"===n,b=(e=>e.charAt(0).toUpperCase()+e.slice(1))(i),v=g?"1px solid var(--Buttons-"+b+"-Border)":"none",y={};f&&(y["data-theme"]=b+"-Medium");const S=()=>{const e={fontWeight:600,fontSize:m.headerFontSize,textAlign:"left",padding:m.py+" "+m.px,borderBottom:"2px solid var(--Border)",color:"var(--Text)",whiteSpace:"nowrap"};return x?(e.backgroundColor="var(--Buttons-"+b+"-Button)",e.color="var(--Buttons-"+b+"-Text)"):e.backgroundColor=f?"var(--Hover)":"var(--Background)",s&&(e.position="sticky",e.top=0,e.zIndex=2),e},k=()=>{const e={fontWeight:600,fontSize:m.headerFontSize,textAlign:"left",padding:m.py+" "+m.px,borderTop:"2px solid var(--Border)",color:"var(--Text)",whiteSpace:"nowrap"};return x?(e.backgroundColor="var(--Buttons-"+b+"-Button)",e.color="var(--Buttons-"+b+"-Text)"):e.backgroundColor=f?"var(--Hover)":"var(--Background)",d&&(e.position="sticky",e.bottom=0,e.zIndex=2),e},B=e=>"none"===l?"Surface":"odd"===l?e%2==0?"Surface":"Surface-Dim":"even"===l&&e%2==0?"Surface-Dim":"Surface",w=()=>({padding:m.py+" "+m.px,fontSize:m.fontSize,color:"var(--Text)",borderBottom:"1px solid var(--Border)",textAlign:"left"});return de(h,{className:"table-wrapper table-"+n+(f||x||g?" table-"+i:"")+" "+c,...y,sx:{width:"100%",overflow:"auto",border:v,borderRadius:g||x?"var(--Style-Border-Radius)":0,...u},children:de(h,{component:"table",sx:{width:"100%",borderCollapse:"collapse",tableLayout:"fixed",fontFamily:"inherit","& thead th":S(),"& tbody td":w(),"& tfoot td, & tfoot th":k(),...s?{"& thead th":{...S(),position:"sticky",top:0,zIndex:2}}:{},...d?{"& tfoot td, & tfoot th":{...k(),position:"sticky",bottom:0,zIndex:2}}:{}},...p,children:t&&r?t&&r?ce(ue,{children:[de(h,{component:"thead",children:de(h,{component:"tr",children:t.map((e,t)=>de(h,{component:"th",sx:{...S(),...e.width?{width:e.width}:{},...e.align?{textAlign:e.align}:{}},children:e.label||e.header||e},"h-"+t))})}),de(h,{component:"tbody",children:r.map((e,r)=>de(h,{component:"tr","data-surface":B(r),sx:{backgroundColor:"var(--"+B(r)+")"},children:(Array.isArray(e)?e:t.map(t=>e[t.field||t.key])).map((e,o)=>de(h,{component:"td",sx:{...w(),...t[o]&&t[o].align?{textAlign:t[o].align}:{}},children:e},"c-"+r+"-"+o))},"r-"+r))}),o&&o.length>0&&de(h,{component:"tfoot",children:o.map((e,r)=>de(h,{component:"tr",children:(Array.isArray(e)?e:t.map(t=>e[t.field||t.key])).map((e,o)=>de(h,{component:"td",sx:{...k(),...t[o]&&t[o].align?{textAlign:t[o].align}:{}},children:e},"fc-"+r+"-"+o))},"f-"+r))})]}):null:e})})}const Qg={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info-Medium",success:"Success-Medium",warning:"Warning-Medium",error:"Error-Medium"},jg={primary:"Primary",secondary:"Secondary",tertiary:"Tertiary",neutral:"Neutral",info:"Info",success:"Success",warning:"Warning",error:"Error"},Gg={small:{fontSize:"12px",py:"4px",px:"8px",maxWidth:200,arrowSize:6},medium:{fontSize:"13px",py:"6px",px:"12px",maxWidth:280,arrowSize:8},large:{fontSize:"14px",py:"8px",px:"16px",maxWidth:360,arrowSize:10}};function Ug({children:e,title:t,variant:r="solid",color:o="primary",size:n="medium",placement:i="bottom",arrow:a=!1,open:l,enterDelay:s=100,leaveDelay:d=0,describeChild:c=!1,className:u="",sx:p={},...m}){const f=Gg[n]||Gg.medium,g="solid"===r,x="light"===r,b="outline"===r,v=(e=>e.charAt(0).toUpperCase()+e.slice(1))(o),y="var(--Background)",S=void 0===l?{}:{open:l};return de(w,{title:t?de(h,{"data-theme":(g?Qg[o]:x?jg[o]:null)||void 0,"data-surface":x?"Surface-Brightest":g?"Surface":void 0,className:"tooltip-content tooltip-"+r+" tooltip-"+o+" tooltip-"+n+" "+u,sx:{backgroundColor:"var(--Background)",color:"var(--Text)",border:b?"1px solid var(--Buttons-"+v+"-Border)":"none",borderRadius:"var(--Style-Border-Radius)",fontSize:f.fontSize,lineHeight:1.5,fontFamily:"inherit",padding:f.py+" "+f.px,maxWidth:f.maxWidth+"px",boxShadow:"0 2px 8px rgba(0,0,0,0.15)",...p},children:t}):"",placement:i,arrow:a,enterDelay:s,leaveDelay:d,describeChild:c,...S,componentsProps:{tooltip:{sx:{backgroundColor:"transparent",padding:0,maxWidth:"none",boxShadow:"none"}},arrow:{sx:{color:y,"&::before":{border:b?"1px solid var(--Buttons-"+v+"-Border)":"none",backgroundColor:y,boxSizing:"border-box"},fontSize:f.arrowSize+"px"}}},...m,children:e})}const Xg={default:{theme:"App-Bar"},primary:{theme:"Primary"},"primary-light":{theme:"Primary",surface:"Surface-Brightest"},white:{theme:"Neutral",surface:"Surface-Brightest"},black:{theme:"Neutral",surface:"Surface-Dimmest"}};function Kg({children:e,onClick:t,ariaLabel:r}){return de(In,{iconOnly:!0,variant:"ghost",size:"medium",onClick:t,"aria-label":r,children:e})}function qg({barColor:e="default",surface:o="Surface",loginType:n="login",menuType:i="hamburger",brandType:a="name",searchPosition:l="right",companyName:s="Company",navLinks:d=["Home","Products","About"],rightButtons:c=[],showRightButtons:u=!1,onMenuClick:p,user:m,onLogin:f,onSignOut:g,brand:x,onBrandClick:b,centerSlot:v,endSlot:y,searchValue:S,onSearchChange:k,searchPlaceholder:B="Search...",children:w,className:C="",sx:T={}}){const[I,A]=r(!1),z=Xg[e]||Xg.default,R=z.theme,E=z.surface||o,P="expanded"===i&&d.length>3?"hamburger":i,O=de(ys,{placeholder:B,size:"medium",value:S,onChange:k,sx:{flex:"left"===l?"0 1 400px":"0 1 280px",minWidth:0}});return ce(ue,{children:[de(h,{component:"header",role:"banner","data-theme":R,"data-surface":E,className:"appbar appbar-desktop appbar-"+e+(C?" "+C:""),sx:{display:"flex",alignItems:"center",height:64,px:2,gap:2,backgroundColor:"var(--Background)",color:"var(--Text)",boxShadow:nn,fontFamily:"inherit",...T},children:w||ce(ue,{children:["hamburger"===P&&de(Kg,{ariaLabel:"Open navigation menu",onClick:p||(()=>A(!0)),children:de(Pt,{sx:{fontSize:"inherit"}})}),de(h,void 0!==x?b?{component:"button",type:"button",onClick:b,sx:{background:"transparent",border:"none",padding:0,cursor:"pointer",color:"inherit",font:"inherit",fontWeight:700,fontSize:"18px",whiteSpace:"nowrap",flexShrink:0},children:x}:{sx:{fontWeight:700,fontSize:"18px",whiteSpace:"nowrap",flexShrink:0},children:x}:"logo"===a?{sx:{width:32,height:32,borderRadius:"6px",backgroundColor:"var(--Text)",opacity:.8,flexShrink:0},"aria-label":"Company logo"}:{sx:{fontWeight:700,fontSize:"18px",whiteSpace:"nowrap",flexShrink:0},children:s}),ce(ue,void 0!==v?{children:[de(h,{sx:{flex:1}}),de(h,{sx:{display:"flex",alignItems:"center",flexShrink:0},children:v}),de(h,{sx:{flex:1}})]}:{children:["left"===l&&O,"expanded"===P&&de(ii,{defaultValue:0,variant:"standard",color:"default",sx:{ml:2,minHeight:0},children:de(ai,{"aria-label":"Main navigation",children:d.map(e=>de(li,{children:e},e))})}),de(h,{sx:{flex:1}}),"right"===l&&O]}),void 0!==y?de(h,{sx:{display:"flex",alignItems:"center",gap:1},children:y}):ce(ue,{children:[u&&c.length>0&&de(h,{sx:{display:"flex",alignItems:"center",gap:.5},children:c.map((e,r)=>e.raw?de(t.Fragment,{children:e.icon},r):de(Kg,{ariaLabel:e.label||"Action "+(r+1),children:e.icon},r))}),m?de(In,{variant:"ghost",size:"small",onClick:g,"aria-label":"Sign out",startIcon:m.photoURL?de(h,{component:"img",src:m.photoURL,alt:"",sx:{width:24,height:24,borderRadius:"50%"}}):de(pr,{sx:{fontSize:24}}),children:m.displayName?.split(" ")[0]||"Account"}):f?de(In,{variant:"default-outline",size:"small",onClick:f,children:"Login"}):"avatar"===n?de(In,{iconOnly:!0,variant:"ghost",size:"medium","aria-label":"Account",children:de(pr,{sx:{fontSize:28}})}):null]})]})}),de(xu,{open:I,onClose:()=>A(!1),anchor:"left",size:"small",children:de(h,{component:"nav","aria-label":"Main navigation",sx:{display:"flex",flexDirection:"column",gap:.5,py:1},children:d.map(e=>de(In,{variant:"ghost",size:"medium",onClick:()=>A(!1),sx:{justifyContent:"flex-start",width:"100%"},children:e},e))})})]})}function Jg({mobileVariant:e="search",barColor:t="default",surface:o="Surface",title:n="Page Title",subtitle:i="Subtitle text",actionIcon:a,companyName:l="Company",navLinks:s=["Home","Products","About"],className:d="",sx:c={}}){const[u,p]=r(!1),m=Xg[t]||Xg.default,f=m.theme,g=m.surface||o,x={backgroundColor:"var(--Background)",color:"var(--Text)",boxShadow:nn,fontFamily:"inherit",width:"100%",maxWidth:420,...c},b={"data-theme":f,"data-surface":g},v=de(xu,{open:u,onClose:()=>p(!1),anchor:"left",size:"small",children:de(h,{component:"nav","aria-label":"Main navigation",sx:{display:"flex",flexDirection:"column",gap:.5,py:1},children:s.map(e=>de(In,{variant:"ghost",size:"medium",onClick:()=>p(!1),sx:{justifyContent:"flex-start",width:"100%"},children:e},e))})});return"search"===e?ce(ue,{children:[ce(h,{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-search appbar-"+t+" "+d,...b,sx:{...x,display:"flex",alignItems:"center",height:64,px:1.5,gap:1.5},children:[de(Kg,{ariaLabel:"Open navigation menu",onClick:()=>p(!0),children:de(Pt,{sx:{fontSize:"inherit"}})}),de(ys,{placeholder:"Search "+l,size:"small",sx:{flex:1,minWidth:0}}),de(In,{iconOnly:!0,variant:"ghost",size:"medium","aria-label":"Account",children:de(pr,{sx:{fontSize:28}})})]}),v]}):ce(h,"small"===e?{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-small appbar-"+t+" "+d,...b,sx:{...x,display:"flex",alignItems:"center",height:64,px:1.5,gap:1},children:[de(Kg,{ariaLabel:"Back",children:de(ur,{sx:{fontSize:"inherit"}})}),ce(h,{sx:{flex:1,minWidth:0},children:[de(h,{sx:{fontWeight:600,fontSize:"16px",lineHeight:1.3,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:n}),i&&de(h,{sx:{fontSize:"12px",opacity:.7,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:i})]}),a&&de(Kg,{ariaLabel:"Action",children:a})]}:"medium"===e?{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-medium appbar-"+t+" "+d,...b,sx:{...x,px:1.5,pb:2},children:[ce(h,{sx:{display:"flex",alignItems:"center",height:56,gap:1},children:[de(Kg,{ariaLabel:"Back",children:de(ur,{sx:{fontSize:"inherit"}})}),de(h,{sx:{flex:1}}),a&&de(Kg,{ariaLabel:"Action",children:a})]}),ce(h,{sx:{px:1.5},children:[de(h,{sx:{fontWeight:600,fontSize:"24px",lineHeight:1.2},children:n}),i&&de(h,{sx:{fontSize:"14px",opacity:.7,mt:.5},children:i})]})]}:{component:"header",role:"banner",className:"appbar appbar-mobile appbar-mobile-large appbar-"+t+" "+d,...b,sx:{...x,px:1.5,pb:3},children:[ce(h,{sx:{display:"flex",alignItems:"center",height:56,gap:1},children:[de(Kg,{ariaLabel:"Back",children:de(ur,{sx:{fontSize:"inherit"}})}),de(h,{sx:{flex:1}}),a&&de(Kg,{ariaLabel:"Action",children:a})]}),ce(h,{sx:{px:1.5,mt:1},children:[de(h,{sx:{fontWeight:600,fontSize:"36px",lineHeight:1.1},children:n}),i&&de(h,{sx:{fontSize:"14px",opacity:.7,mt:.5},children:i})]})]})}function Yg({mode:e="desktop",...t}){return de("mobile"===e?Jg:qg,{...t})}const Zg=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",$g=["default","primary","primary-light","white","black"],_g=["Surface","Surface-Bright","Surface-Dim","Surface-Dimmest"],ex={default:{theme:"App-Bar"},primary:{theme:"Primary"},"primary-light":{theme:"Primary",surface:"Surface-Brightest"},white:{theme:"Neutral",surface:"Surface-Brightest"},black:{theme:"Neutral",surface:"Surface-Dimmest"}};function tx({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function rx({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(tx,{ratio:t,threshold:r})]})}function ox({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function nx({color:e,selected:t,onClick:r}){const o=ex[e]||ex.default;return de(h,{component:"button","data-theme":o.theme,"data-surface":o.surface||"Surface",onClick:()=>r(e),"aria-label":"Select "+e,"aria-pressed":t,title:e,sx:{width:"var(--Button-Height, 36px)",height:"var(--Button-Height, 36px)",borderRadius:"4px",backgroundColor:"var(--Background)",border:t?"2px solid var(--Text)":"2px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Text)",pointerEvents:"none"}})})}function ix(){const[e,t]=r("desktop"),[o,n]=r("default"),[a,l]=r("Surface"),[s,d]=r("login"),[c,u]=r("hamburger"),[p,m]=r("name"),[f,g]=r("right"),[x,b]=r("search"),[v,y]=r(null),[S,k]=r("Surface"),[w,C]=r({}),T="desktop"===e,A=ex[o]||ex.default,z=A.theme,R=A.surface||a;return i(()=>{const e={};e.text=Xi("--Text"),e.textQuiet=Xi("--Text-Quiet"),e.background=Xi("--Background"),e.border=Xi("--Border"),e.focusVisible=Xi("--Focus-Visible"),e.hover=Xi("--Hover"),e.active=Xi("--Pressed"),C(e)},[o,a,e]),ce(h,{sx:{pb:8},children:[de(Jr,{children:"App Bar"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{theme:v,children:de(h,{sx:{width:"100%",maxWidth:T?"100%":420,overflow:"hidden"},children:T?de(qg,{barColor:o,surface:a,loginType:s,menuType:c,brandType:p,searchPosition:f,companyName:"My App",navLinks:["Home","Products","About"]}):de(Jg,{barColor:o,surface:a,mobileVariant:x,companyName:"My App",title:"Page Title",subtitle:"Subtitle text"})})}),de(Vi,{code:(()=>{if(T){const e=[];"default"!==o&&e.push('barColor="'+o+'"'),"Surface"!==a&&e.push('surface="'+a+'"'),"login"!==s&&e.push('loginType="'+s+'"'),"hamburger"!==c&&e.push('menuType="'+c+'"'),"name"!==p&&e.push('brandType="'+p+'"'),"right"!==f&&e.push('searchPosition="'+f+'"');const t=e.length?"\n "+e.join("\n ")+"\n":"";return'<AppBar mode="desktop"'+(t||" ")+'companyName="My App" />'}{const e=['mode="mobile"','mobileVariant="'+x+'"'];return"default"!==o&&e.push('barColor="'+o+'"'),"Surface"!==a&&e.push('surface="'+a+'"'),"<AppBar\n "+e.join("\n ")+'\n title="Page Title"\n/>'}})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:v,onThemeChange:y,surface:S,onSurfaceChange:k})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"MODE"}),de(B,{direction:"row",spacing:1,children:["desktop","mobile"].map(r=>de(ox,{label:Zg(r),selected:e===r,onClick:()=>t(r)},r))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BAR COLOR"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:$g.map(e=>de(nx,{color:e,selected:o===e,onClick:n},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",marginTop:6,display:"block"},children:['data-theme="',z,'"']})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SURFACE"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:_g.map(e=>de(ox,{label:e.replace("Surface-","").replace("Surface","Default"),selected:a===e,onClick:()=>l(e)},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",marginTop:6,display:"block"},children:['data-surface="',a,'"']})]}),T&&ce(ue,{children:[ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"MENU TYPE"}),de(B,{direction:"row",spacing:1,children:["hamburger","expanded"].map(e=>de(ox,{label:Zg(e),selected:c===e,onClick:()=>u(e)},e))}),de(bo,{style:{color:"var(--Text-Quiet)",marginTop:4,display:"block"},children:"Expanded auto-falls back to hamburger when nav > 3 links"})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BRAND"}),de(B,{direction:"row",spacing:1,children:["name","logo"].map(e=>de(ox,{label:Zg(e),selected:p===e,onClick:()=>m(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SEARCH POSITION"}),de(B,{direction:"row",spacing:1,children:["left","right"].map(e=>de(ox,{label:Zg(e),selected:f===e,onClick:()=>g(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"LOGIN TYPE"}),de(B,{direction:"row",spacing:1,children:["login","avatar"].map(e=>de(ox,{label:Zg(e),selected:s===e,onClick:()=>d(e)},e))})]})]}),!T&&ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"MOBILE VARIANT"}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:["search","small","medium","large"].map(e=>de(ox,{label:Zg(e),selected:x===e,onClick:()=>b(e)},e))})]})]})}),de(si,{value:1,children:ce(h,{sx:{p:3},children:[ce(ao,{color:"quiet",style:{marginBottom:24},children:[e," / ",o," / ",a,T?"":" / "+x,' — data-theme="',z,'" data-surface="',R,'"']}),ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Text Contrast (WCAG 1.4.3 — 4.5:1)"}),de(ao,{color:"quiet",style:{marginBottom:16},children:"All text and icons must have 4.5:1 contrast against the AppBar background."}),de(rx,{label:"Resting: var(--Text) vs. var(--Background)",ratio:Ui(w.text,w.background),threshold:4.5,note:'data-theme="'+z+'" data-surface="'+R+'"'}),de(rx,{label:"On hover: var(--Text) vs. var(--Hover)",ratio:Ui(w.text,w.hover),threshold:4.5,note:"Icon buttons use var(--Hover) on hover"}),de(rx,{label:"On active: var(--Text) vs. var(--Pressed)",ratio:Ui(w.text,w.active),threshold:4.5,note:"Icon buttons use var(--Pressed) on press"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Focus Indicator (WCAG 2.4.11 — 3:1)"}),de(rx,{label:"var(--Focus-Visible) vs. var(--Background)",ratio:Ui(w.focusVisible,w.background),threshold:3,note:"outline: 3px solid var(--Focus-Visible); outline-offset: 1px"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Touch Target Area (WCAG 2.5.5)"}),[{label:"Icon button",size:40,note:"width: 40px, height: 40px"},{label:"AppBar (desktop)",size:64,note:"height: 64px"},{label:"AppBar (mobile)",size:64,note:"height: 64px"}].map(({label:e,size:t,note:r})=>{const o=t>=24,n=t>=44,i=t>=48;return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[ce(ao,{style:{color:"var(--Text)"},children:[e," — ",t,"px"]}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:r})]}),ce(h,{sx:{display:"flex",gap:.5,flexWrap:"wrap",justifyContent:"flex-end"},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:o?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:o?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:["Desktop ",o?"Y":"N"]}),ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:n?"var(--Tags-Success-BG)":"var(--Tags-Warning-BG)",color:n?"var(--Tags-Success-Text)":"var(--Tags-Warning-Text)"},children:["iOS ",n?"Y":"~"]}),ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:i?"var(--Tags-Success-BG)":"var(--Tags-Warning-BG)",color:i?"var(--Tags-Success-Text)":"var(--Tags-Warning-Text)"},children:["Android ",i?"Y":"~"]})]})]},e)})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),ce(B,{spacing:0,children:[ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Landmark:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<header role="banner">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Navigation (expanded menu):"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'<nav aria-label="Main navigation">'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Theme + Surface:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:'data-theme="'+z+'" data-surface="'+R+'"'})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Shadow:"}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:"box-shadow: var(--Effect-Level-1)"})]}),ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[de(ao,{children:"Icon buttons:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"All icon buttons have aria-label. Focus visible on keyboard navigation."})]}),ce(h,{sx:{py:1.5},children:[de(ao,{children:"Keyboard:"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Tab navigates all interactive elements. Enter/Space activates buttons."})]})]})]})]})]})})]})})})]})]})}function ax({title:e="My App",mode:t="light",navItems:r=[{label:"HOME",href:"#"},{label:"ABOUT",href:"#"},{label:"SERVICES",href:"#"},{label:"CONTACT",href:"#"}],rightContent:o,sx:n={},...i}){return de(Z,{position:"fixed",sx:{background:"var(--Background)",color:"var(--Text)",boxShadow:"0 1px 3px rgba(0,0,0,0.1)",borderBottom:"1px solid var(--Border-Variant)",transition:"all 0.2s ease-in-out",zIndex:1201,...n},...i,children:de(F,{maxWidth:"lg",children:ce($,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",px:0},children:[de(T,{variant:"h6",sx:{fontWeight:700,color:"var(--Text)",mr:"auto",transition:"color 0.2s ease-in-out"},children:e}),de(h,{sx:{display:{xs:"none",md:"flex"},gap:3,flex:1,justifyContent:"center"},children:r.map((e,t)=>de(T,{component:"a",href:e.href,variant:"body2",sx:{textDecoration:"none",color:"var(--Text)",transition:"color 0.2s ease-in-out","&:hover":{color:"var(--Primary-Color-11)"}},children:e.label},t))}),de(B,{direction:"row",spacing:1,alignItems:"center",children:o})]})})})}const lx={default:{bg:"var(--Primary-Color-1)",fg:"var(--Primary-Color-12)"},primary:{theme:"Primary",surface:"Surface-Dim"},"primary-dark":{bg:"var(--Primary-Color-1)",fg:"var(--Primary-Color-12)"},white:{bg:"var(--Neutral-Color-11)",fg:"var(--Neutral-Color-3)"},black:{bg:"var(--Neutral-Color-1)",fg:"var(--Neutral-Color-12)"}};function sx({color:e="default",companyName:t="",year:r=(new Date).getFullYear(),rights:o="All rights reserved",children:n,className:i,style:a,...l}){const s=n??`© ${r}${t?" "+t:""}.${o?" "+o+".":""}`,d=lx[e]||lx.default,c=d.theme?{"data-theme":d.theme,"data-surface":d.surface||"Surface-Dim"}:{},u=d.theme?{background:"var(--Background)",color:"var(--Text)"}:{background:d.bg,color:d.fg};return de("div",{...c,className:["dino-copyright",i].filter(Boolean).join(" "),style:{padding:"14px 24px",textAlign:"center",...u,...a},...l,children:de(ao,{style:{color:"inherit",opacity:.85},children:s})})}const dx={default:{bg:"var(--Primary-Color-2)",fg:"var(--Primary-Color-12)"},primary:{theme:"Primary",surface:"Surface"},"primary-dark":{theme:"Primary",surface:"Surface-Dimmest"},white:{bg:"var(--Neutral-Color-12)",fg:"var(--Neutral-Color-2)"},black:{bg:"var(--Neutral-Color-1)",fg:"var(--Neutral-Color-12)"}};function cx({color:e="default",brand:t,address:r,columns:o=[],socialLinks:n=[],subscribe:i,copyrightName:a,copyrightYear:l,className:s,style:d,...c}){const u=o.slice(0,3),p=dx[e]||dx.default,h=p.theme?{"data-theme":p.theme,"data-surface":p.surface||"Surface"}:{},m=p.theme?{background:"var(--Background)",color:"var(--Text)"}:{background:p.bg,color:p.fg};return ce("footer",{...h,className:["dino-footer",s].filter(Boolean).join(" "),style:{...m,...d},...c,children:[ce("div",{style:{maxWidth:1200,margin:"0 auto",padding:"40px 24px 56px"},children:[t&&de("div",{style:{marginBottom:36},children:t}),ce("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(280px, 1fr))",gap:40},children:[de(ux,{address:r}),u.map((e,t)=>de(px,{...e},t))]}),(n.length>0||i)&&ce("div",{style:{marginTop:48,paddingTop:32,borderTop:"1px solid rgba(255, 255, 255, 0.10)",display:"flex",flexWrap:"wrap",gap:32,alignItems:"flex-start",justifyContent:"space-between"},children:[n.length>0&&de(hx,{links:n}),i&&de(mx,{...i})]})]}),de(sx,{color:e,companyName:a,year:l})]})}function ux({address:e}){if(!e)return de("div",{});const{company:t,lines:r=[],email:o,phone:n}=e,i=[...t?[t]:[],...r,...n?[n]:[]];return ce("div",{children:[i.map((e,t)=>de(ao,{style:{color:"inherit",opacity:.85,display:"block"},children:e},t)),o&&de("div",{style:{marginTop:12},children:de(ao,{style:{color:"inherit",opacity:.85,display:"block"},children:de(Ms,{href:"mailto:"+o,color:"standard",style:{color:"inherit"},children:o})})})]})}function px({title:e,links:t=[]}){return ce("div",{children:[e&&de(Yr,{style:{color:"inherit",marginBottom:12},children:e}),de("ul",{style:{listStyle:"none",margin:0,padding:0},children:t.map((e,t)=>de("li",{style:{marginBottom:8},children:de(Ms,{href:e.href,onClick:e.onClick,color:"standard",style:{color:"inherit",opacity:.85},children:e.label})},t))})]})}function hx({links:e}){return de("div",{style:{display:"flex",gap:16,alignItems:"center"},children:e.map((e,t)=>de("a",{href:e.url,target:"_blank",rel:"noopener noreferrer","aria-label":e.label||"Social link",style:{color:"inherit",opacity:.85,display:"inline-flex",alignItems:"center",justifyContent:"center",width:36,height:36,borderRadius:"50%",border:"1px solid rgba(255, 255, 255, 0.18)",textDecoration:"none",transition:"opacity 150ms ease, border-color 150ms ease"},onMouseEnter:e=>{e.currentTarget.style.opacity="1"},onMouseLeave:e=>{e.currentTarget.style.opacity="0.85"},children:e.icon},t))})}function mx({title:e="Stay in the loop",description:t,placeholder:o="your@email.com",buttonLabel:n="Subscribe",onSubscribe:i}){const[a,l]=r(""),[s,d]=r(!1);return ce("form",{onSubmit:async e=>{if(e&&e.preventDefault(),a&&!s){d(!0);try{await(i?.(a)),l("")}finally{d(!1)}}},style:{minWidth:260,maxWidth:360,flex:"1 1 260px"},children:[de(Yr,{style:{color:"inherit",marginBottom:6},children:e}),t&&de(ao,{style:{color:"inherit",opacity:.85,marginBottom:12,display:"block"},children:t}),ce("div",{style:{display:"flex",gap:8},children:[de(Ol,{type:"email",value:a,onChange:e=>l(e.target.value),placeholder:o,size:"small",fullWidth:!0,"aria-label":"Email address"}),de(In,{type:"submit",variant:"primary",size:"small",disabled:s||!a,children:n})]})]})}function fx(e){const t=e.match(/rgba?\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)/);return t?[Number(t[1]),Number(t[2]),Number(t[3])]:null}function gx(e){return e?"#"+e.map(e=>e.toString(16).padStart(2,"0")).join(""):"—"}function xx([e,t,r]){const o=[e,t,r].map(e=>(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4));return.2126*o[0]+.7152*o[1]+.0722*o[2]}function bx({targetRef:e,label:t,deps:o=[]}){const[n,a]=r(null),[l,s]=r(null);i(()=>{if(!e.current)return;const t=requestAnimationFrame(()=>{if(!e.current)return;const t=getComputedStyle(e.current);a(fx(t.backgroundColor)),s(fx(t.color))});return()=>cancelAnimationFrame(t)},o);const d=function(e,t){if(!e||!t)return null;const r=xx(e),o=xx(t);return(Math.max(r,o)+.05)/(Math.min(r,o)+.05)}(n,l),c=null!==d&&d>=4.5,u=null===d?"—":null!==d&&d>=7?"AAA":c?"AA":"Fail",p=null===d?"var(--Text-Quiet)":c?"var(--Text-Success)":"var(--Text-Error)";return ce("div",{style:{display:"flex",alignItems:"center",gap:16,padding:"12px 16px",borderRadius:8,background:"var(--Container)",border:"1px solid var(--Border)"},children:[ce("div",{style:{flex:1,minWidth:0},children:[de(ao,{style:{fontWeight:600},children:t}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Background ",gx(n)," · Text ",gx(l)]})]}),ce("div",{style:{display:"flex",alignItems:"center",gap:6,borderRadius:999,padding:"4px 10px",background:"var(--Background)",border:"1px solid var(--Border)"},children:[de("span",{style:{fontWeight:700,fontSize:12,color:p},children:u}),de(bo,{style:{color:"var(--Text-Quiet)"},children:null!==d?d.toFixed(2)+":1":"—"})]})]})}const vx={company:"DinoDesign",lines:["123 Market Street","San Francisco, CA 94103"],email:"hello@dinodesign.dev",phone:"+1 (555) 010-0000"},yx=[{title:"Product",links:[{label:"Features",href:"#"},{label:"Pricing",href:"#"},{label:"Add-ons",href:"#"}]},{title:"Company",links:[{label:"About",href:"#"},{label:"Careers",href:"#"},{label:"Contact",href:"#"}]},{title:"Resources",links:[{label:"Docs",href:"#"},{label:"Changelog",href:"#"},{label:"Status",href:"#"}]}],Sx=[{icon:de(hr,{fontSize:"small"}),url:"https://twitter.com",label:"Twitter"},{icon:de(mr,{fontSize:"small"}),url:"https://github.com",label:"GitHub"},{icon:de(fr,{fontSize:"small"}),url:"https://linkedin.com",label:"LinkedIn"}],kx=[{value:"default",label:"Default"},{value:"primary",label:"Primary"},{value:"primary-dark",label:"Primary Dark"},{value:"white",label:"White"},{value:"black",label:"Black"}];function Bx({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function wx(){const[e,t]=r(4),[n,a]=r(!0),[l,s]=r(!0),[d,c]=r("default"),u=o(null),[p,m]=r(null),[f,g]=r(null);i(()=>{u.current&&(m({current:u.current.querySelector(".dino-footer")}),g({current:u.current.querySelector(".dino-copyright")}))},[d,e,n,l]);const x=yx.slice(0,Math.max(0,e-1)),b=n?Sx:[],v=l?{title:"Stay in the loop",description:"Monthly updates on new components and tips.",onSubscribe:async e=>console.log("subscribed:",e)}:void 0;return ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Footer"}),ce(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:["Configurable 1–4 column footer. The first column is always the company address / contact. Optional ",de("code",{children:"socialLinks"})," and"," ",de("code",{children:"subscribe"})," sit above the auto-generated copyright strip."]}),de(h,{ref:u,sx:{borderRadius:1,overflow:"hidden",mb:4},children:de(cx,{color:d,address:vx,columns:x,socialLinks:b,subscribe:v,copyrightName:"DinoDesign"})}),ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:560},children:[ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLUMNS"}),de(B,{direction:"row",spacing:1,children:[1,2,3,4].map(r=>de(Bx,{label:String(r),selected:e===r,onClick:()=>t(r)},r))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"First column is always the address / contact. Up to 3 more link columns."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:kx.map(e=>de(Bx,{label:e.label,selected:d===e.value,onClick:()=>c(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:'"Default" hardcodes Primary tone 2 (auto-derived in a future iteration).'})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SOCIAL LINKS"}),de(ra,{label:"Show social media row",checked:n,onChange:e=>a(e.target.checked)}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["When on, the Footer renders the ",de("code",{children:"socialLinks"})," row (icons linking out). In your app, supply the icon + url pairs from your data store."]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SUBSCRIBE"}),de(ra,{label:"Show email subscribe form",checked:l,onChange:e=>s(e.target.checked)}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["When on, the Footer renders an email subscribe form. Hook it up via"," ",de("code",{children:"subscribe.onSubscribe(email)"}),"."]})]})]})}),de(si,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[de(bo,{style:{color:"var(--Text-Quiet)"},children:"Live WCAG 2.1 contrast against the painted background. AA needs 4.5:1 for normal text; AAA needs 7:1."}),p&&de(bx,{targetRef:p,label:"Footer body",deps:[d,e,n,l]}),f&&de(bx,{targetRef:f,label:"Copyright strip",deps:[d,e,n,l]})]})})]})]})}const Cx=[{value:"default",label:"Default"},{value:"primary",label:"Primary"},{value:"primary-dark",label:"Primary Dark"},{value:"white",label:"White"},{value:"black",label:"Black"}];function Tx({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Ix(){const[e,t]=r("DinoDesign"),[n,a]=r((new Date).getFullYear()),[l,s]=r("All rights reserved"),[d,c]=r(""),[u,p]=r(!1),[m,f]=r("default"),g=o(null),[x,b]=r(null);return i(()=>{g.current&&b({current:g.current.querySelector(".dino-copyright")})},[m,u,e,n,l,d]),ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Copyright"}),ce(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:["Standalone copyright strip used at the bottom of pages. Defaults to"," ",ce("code",{children:["© ","{year}"," ","{companyName}",". ","{rights}","."]})," Pass"," ",de("code",{children:"children"})," to override the entire text."]}),de(h,{ref:g,sx:{borderRadius:1,overflow:"hidden",mb:4},children:de(sx,u?{color:m,children:d||"Type a custom message →"}:{color:m,companyName:e,year:Number(n)||(new Date).getFullYear(),rights:l})}),ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:560},children:[ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TEXT MODE"}),ce(B,{direction:"row",spacing:1,children:[de(Tx,{label:"Auto-generated",selected:!u,onClick:()=>p(!1)}),de(Tx,{label:"Custom",selected:u,onClick:()=>p(!0)})]})]}),!u&&ce(ue,{children:[de(qn,{label:"Company name",value:e,onChange:e=>t(e.target.value),placeholder:"DinoDesign",size:"medium"}),de(ul,{label:"Year",value:Number(n),onChange:e=>a(e),min:1900,max:2100}),de(qn,{label:"Rights text",value:l,onChange:e=>s(e.target.value),placeholder:"All rights reserved",size:"medium"}),de(bo,{style:{color:"var(--Text-Quiet)"},children:'Leave Rights blank to omit "All rights reserved." entirely.'})]}),u&&ce(ue,{children:[de(qn,{label:"Custom text",value:d,onChange:e=>c(e.target.value),placeholder:"© 2026 DinoDesign · MIT License · Built with love",size:"medium",multiline:!0}),de(bo,{style:{color:"var(--Text-Quiet)"},children:"Pass any string (or React node) as children to fully override the auto text."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Cx.map(e=>de(Tx,{label:e.label,selected:m===e.value,onClick:()=>f(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Matches the Footer color presets so the two stack cleanly."})]})]})}),de(si,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[de(bo,{style:{color:"var(--Text-Quiet)"},children:"Live WCAG 2.1 contrast against the painted background. AA needs 4.5:1 for normal text; AAA needs 7:1."}),x&&de(bx,{targetRef:x,label:"Copyright strip",deps:[m,u,e,n,l,d]})]})})]})]})}const Ax=["Default","Primary","Secondary","Tertiary","Neutral"],zx={Classic:{name:"Classic",description:"Raised + soft shadow",angle:135,bevel:!0,depth:5,softness:1,shadow:!0,shadowDistance:6,shadowBlur:8,shadowOpacity:.6},Carved:{name:"Carved",description:"Deep inset, no shadow",angle:135,bevel:!0,depth:10,softness:2,shadow:!1,shadowDistance:4,shadowBlur:4,shadowOpacity:.4},Embossed:{name:"Embossed",description:"Inset + heavy shadow",angle:135,bevel:!0,depth:7,softness:1.5,shadow:!0,shadowDistance:10,shadowBlur:14,shadowOpacity:.7},Stamp:{name:"Stamp",description:"Reversed light + shadow",angle:315,bevel:!0,depth:6,softness:1,shadow:!0,shadowDistance:5,shadowBlur:6,shadowOpacity:.8},"Night Cut":{name:"Night Cut",description:"Inset on dark background",angle:135,bevel:!0,depth:8,softness:2,shadow:!1,shadowDistance:6,shadowBlur:8,shadowOpacity:.6},"Shadow Only":{name:"Shadow Only",description:"Flat fill + drop shadow",angle:135,bevel:!1,depth:4,softness:1,shadow:!0,shadowDistance:8,shadowBlur:12,shadowOpacity:.5}},Rx=Object.keys(zx);function Ex(e,t){if("custom"===e)return{...zx.Classic,name:"Custom",description:"Custom",...t||{}};const r=zx[e];return r?{...r}:{...zx.Classic}}function Px(e,t){const r=e||"Primary";return"base"===t?"var(--Buttons-"+r+"-Button)":"highlight"===t?"rgb(var(--Buttons-"+r+"-Highlight))":"lowlight"===t?"rgb(var(--Buttons-"+r+"-Lowlight))":void 0}function Ox(e){const t=e||"Primary";return"Default"===t?"var(--Text)":"var(--Text-"+t+")"}function Lx(e,t){const r=(e-90)*Math.PI/180;return{dx:Math.cos(r)*t,dy:Math.sin(r)*t}}const Mx={"display-large":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Large-Font-Size)",fontWeight:"var(--Display-Large-Font-Weight)",letterSpacing:"var(--Display-Large-Letter-Spacing)",pxHint:64},"display-small":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Small-Font-Size)",fontWeight:"var(--Display-Small-Font-Weight)",letterSpacing:"var(--Display-Small-Letter-Spacing)",pxHint:48}};function Wx({text:e="Your Brand. Perfected.",curves:r,arc:o=160,radius:n=300,direction:i="up",rotation:a=0,autoCrop:l=!0,textStyle:s="display-large",fontSize:d,fontFamily:c,fontWeight:u,letterSpacing:p,color:h="var(--Text, #1a1a1a)",bevel:m=!1,bevelTheme:f="Primary",bevelPreset:g,bevelCustom:x,className:b,style:v,...y}){const S=g?Ex(g,x):null,k=S?!!S.bevel:!!m,B=Mx[s]||Mx["display-large"],w=c??B.fontFamily,C=d??B.fontSize,T=u??B.fontWeight,I=p??B.letterSpacing,A="number"==typeof d?d:B.pxHint,z=r&&r.length>0?r:[{arc:o,radius:n,direction:i}],{d:R,width:E,upMax:P,downMax:O,pathId:L}=function(e){return t.useMemo(()=>{const t="dino-curved-text-"+Math.random().toString(36).slice(2,9);let r=0;const o=0;let n="M "+r+" "+o,i=0,a=0;for(const{arc:t,radius:l,direction:s}of e){const e=Dx(t,1,359),d=Math.max(10,l),c=e*Math.PI/180,u=2*d*Math.sin(c/2),p=d*(1-Math.cos(c/2));r+=u,n+=" A "+d+" "+d+" 0 "+(e>180?1:0)+" "+("up"===s?1:0)+" "+r+" "+o,"up"===s?i=Math.max(i,p):a=Math.max(a,p)}return{d:n,width:r,upMax:i,downMax:a,pathId:t}},[JSON.stringify(e)])}(z),M=Math.ceil(P+A),W=Math.ceil(O+A),D=Math.ceil(A),F=Math.ceil(E+2*D),N=M+W,H=D,V=M,Q=a?"rotate("+a+" "+F/2+" "+N/2+")":void 0,j=t.useRef(null),[G,U]=t.useState(null),[X,K]=t.useState(A);t.useEffect(()=>{if(!j.current||"undefined"==typeof ResizeObserver)return;const e=j.current,t=()=>{const t=e.getBoundingClientRect(),r=G?G.width:F;if(!r||!t.width)return;const o=t.width/r;K(A*o)};t();const r=new ResizeObserver(t);return r.observe(e),()=>r.disconnect()},[F,A,G]);const q=k&&X>=19;t.useLayoutEffect(()=>{if(!l)return void U(null);const e=j.current;if(!e)return;const t=e.querySelector("text");if(!t)return;let r;try{r=t.getBBox()}catch(e){return}if(!r||!r.width||!r.height)return;const o=F/2,n=N/2,i=a*Math.PI/180,s=Math.cos(i),d=Math.sin(i),c=(e,t)=>{const r=e-o,i=t-n;return{x:o+r*s-i*d,y:n+r*d+i*s}},u=[c(r.x,r.y),c(r.x+r.width,r.y),c(r.x,r.y+r.height),c(r.x+r.width,r.y+r.height)],p=Math.min(...u.map(e=>e.x)),h=Math.max(...u.map(e=>e.x)),m=Math.min(...u.map(e=>e.y)),f=Math.max(...u.map(e=>e.y)),g=.12*A,x={x:p-g,y:m-g,width:h-p+2*g,height:f-m+2*g};U(e=>e&&Math.abs(e.x-x.x)<.5&&Math.abs(e.y-x.y)<.5&&Math.abs(e.width-x.width)<.5&&Math.abs(e.height-x.height)<.5?e:x)},[l,e,JSON.stringify(z),a,A,I,w,T,k,f,g,JSON.stringify(x)]);const J=G?G.x+" "+G.y+" "+G.width+" "+G.height:"0 0 "+F+" "+N,Y=G?G.width:F,Z=G?G.height:N;return ce("svg",{ref:j,viewBox:J,width:Y,height:Z,preserveAspectRatio:"xMidYMid meet",xmlns:"http://www.w3.org/2000/svg",style:{display:"block",maxWidth:"100%",height:"auto",overflow:"visible",...v},"aria-label":e,role:"img",className:["dino-curved-text",b].filter(Boolean).join(" "),...y,children:[de("defs",{children:de("path",{id:L,d:R,transform:"translate("+H+" "+V+")"})}),ce("g",{transform:Q,children:[q&&(()=>{const t=S?S.depth/96:.045,r=Math.max(2,Math.round(A*t)),o=Math.max(1,Math.round(A*t*.67)),n={fontFamily:w,fontSize:"number"==typeof C?C+"px":C,fontWeight:T,letterSpacing:"number"==typeof I?I+"px":I};return ce(ue,{children:[de("text",{className:"dino-bevel-layer dino-bevel-layer--lowlight",fill:"rgb(var(--Buttons-"+f+"-Lowlight))",transform:"translate(0 "+r+")",style:n,children:de("textPath",{href:"#"+L,startOffset:"50%",textAnchor:"middle",children:e})}),de("text",{className:"dino-bevel-layer dino-bevel-layer--highlight",fill:"rgb(var(--Buttons-"+f+"-Highlight))",transform:"translate(0 -"+o+")",style:n,children:de("textPath",{href:"#"+L,startOffset:"50%",textAnchor:"middle",children:e})})]})})(),de("text",{className:"dino-curved-text__base",fill:q?"var(--Buttons-"+f+"-Button)":k?Ox(f):h,style:{fontFamily:w,fontSize:"number"==typeof C?C+"px":C,fontWeight:T,letterSpacing:"number"==typeof I?I+"px":I},children:de("textPath",{href:"#"+L,startOffset:"50%",textAnchor:"middle",children:e})})]})]})}function Dx(e,t,r){return Math.max(t,Math.min(r,e))}const Fx=[{value:"display-large",label:"Display Large"},{value:"display-small",label:"Display Small"}],Nx=[{value:"text",label:"Text",css:"var(--Text)"},{value:"primary",label:"Primary",css:"var(--Text-Primary)"},{value:"secondary",label:"Secondary",css:"var(--Text-Secondary)"},{value:"tertiary",label:"Tertiary",css:"var(--Text-Tertiary)"}],Hx=Ax.map(e=>({value:e,label:e}));function Vx({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function Qx(){const[e,t]=r("Your Brand. Perfected."),[n,a]=r("display-large"),[l,s]=r("primary"),[d,c]=r([(u="up",{arc:140,radius:340,direction:u})]);var u;const[p,m]=r(0),[f,g]=r(8),[x,b]=r(700),[v,y]=r(!1),[S,k]=r("Primary"),[w,C]=r("Classic"),T=o(null),[I,A]=r(null);i(()=>{T.current&&A({current:T.current.querySelector("text")})},[l,n,d,p,f,x,v,S,w]);const z=Nx.find(e=>e.value===l)?.css||Nx[0].css;function R(e,t){c(r=>r.map((r,o)=>o===e?{...r,...t}:r))}return ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Curved Display Text"}),de(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:"Decorative text laid along an SVG arc. Chain multiple arcs to build a wave — each curve gets its own radius, arc sweep, and direction. Uses your design system's decorative font + text tokens."}),ce(h,{sx:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(360px, 1fr))",gap:3,alignItems:"start"},children:[de(h,{sx:{minWidth:0},children:de(h,{ref:T,"data-surface":"Container",sx:{background:"var(--Background)",borderRadius:2,p:3,display:"flex",alignItems:"center",justifyContent:"center",overflow:"auto",position:"sticky",top:16},children:de(Wx,{text:e,curves:d,textStyle:n,rotation:p,letterSpacing:f,fontWeight:x,bevel:v,bevelTheme:S,bevelPreset:v?w:void 0,color:z})})}),de(h,{sx:{minWidth:0,alignSelf:"flex-start"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:720},children:[de(qn,{label:"Text",value:e,onChange:e=>t(e.target.value),placeholder:"Your headline…",size:"medium"}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"CURVES"}),de(B,{direction:"row",spacing:1,children:[1,2].map(e=>de(Vx,{label:String(e),selected:d.length===e,onClick:()=>function(e){c(t=>{if(e===t.length)return t;if(e>t.length){const r=[...t];for(;r.length<e;){const e=r[r.length-1];r.push({arc:e.arc,radius:e.radius,direction:"up"===e.direction?"down":"up"})}return r}return t.slice(0,e)})}(e)},e))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"One curve is an arch. Two curves chain end-to-end for a wave."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:12},children:"PER-CURVE SETTINGS"}),de(B,{spacing:2,children:d.map((e,t)=>ce(h,{"data-surface":"Container",style:{background:"var(--Background)",border:"1px solid var(--Border)",borderRadius:8,padding:12},children:[ce(B,{direction:"row",alignItems:"center",spacing:2,sx:{mb:1},children:[ce(bo,{style:{fontWeight:700},children:["Curve ",t+1]}),de("div",{style:{flex:1}}),ce(B,{direction:"row",spacing:1,children:[de(Vx,{label:"⌢ Up",selected:"up"===e.direction,onClick:()=>R(t,{direction:"up"})}),de(Vx,{label:"⌣ Down",selected:"down"===e.direction,onClick:()=>R(t,{direction:"down"})})]})]}),ce(B,{spacing:1,children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Radius",ce("span",{style:{float:"right"},children:[e.radius,"px"]})]}),de(hs,{min:100,max:600,step:10,value:e.radius,onChange:(e,r)=>R(t,{radius:r})})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Arc sweep",ce("span",{style:{float:"right"},children:[e.arc,"°"]})]}),de(hs,{min:40,max:280,step:5,value:e.arc,onChange:(e,r)=>R(t,{arc:r})})]})]})]},t))})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TYPOGRAPHY"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Fx.map(e=>de(Vx,{label:e.label,selected:n===e.value,onClick:()=>a(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Uses the lib's DisplayLarge / DisplaySmall tokens (font-family, size, weight, letter-spacing)."})]}),ce(h,{children:[ce(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:["LETTER SPACING",ce("span",{style:{float:"right"},children:[f,"px"]})]}),de(hs,{min:-4,max:40,step:1,value:f,onChange:(e,t)=>g(t)}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Adjusts the gap between characters along the wave."})]}),ce(h,{children:[ce(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:["FONT WEIGHT",de("span",{style:{float:"right"},children:x})]}),de(hs,{min:100,max:900,step:100,value:x,onChange:(e,t)=>b(t)}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Heavier weights read better at decorative sizes. Available weights depend on the loaded display font."})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"BEVEL"}),de(ra,{label:"3D bevel effect",checked:v,onChange:e=>y(e.target.checked)}),v&&ce(h,{sx:{mt:1.5},children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:6},children:"Preset"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1,mb:1.5},children:Rx.map(e=>de(Vx,{label:e,selected:w===e,onClick:()=>C(e)},e))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:6},children:"Bevel theme"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Hx.map(e=>de(Vx,{label:e.label,selected:S===e.value,onClick:()=>k(e.value)},e.value))})]}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Bevel layers use ",ce("code",{children:["--Buttons-","{Theme}","-Button"]})," for the fill, with ",de("code",{children:"Highlight"})," + ",de("code",{children:"Lowlight"}),"tokens for the bright/shadow stripes. CurvedText honors a preset's ",de("em",{children:"depth"})," only — angle, softness, and drop-shadow fields are stacked-rendering limitations and are ignored here (the full filter pipeline lives in ",de("code",{children:"<BevelText>"}),"). Shadow-only presets render no effect. Auto-hides below 19px so the 3:1 bevel contrast doesn't compromise small-text legibility."]})]}),ce(h,{children:[ce(B,{direction:"row",alignItems:"center",sx:{mb:1},children:[ce(To,{style:{color:"var(--Text-Quiet)",flex:1},children:["ROTATION",ce("span",{style:{float:"right",marginRight:12},children:[p,"°"]})]}),de(In,{variant:"default-outline",size:"small",onClick:function(){const t=T.current?.querySelector("svg");if(!t)return;const r=t.querySelector("path"),o=t.querySelector("text");if(!r||!o)return;const n=r.getTotalLength();if(!n)return;let i=0;try{i=o.getComputedTextLength?.()||0}catch(e){}i||(i=Math.min(n,18*e.length));const a=Math.max(0,(n-i)/2),l=Math.min(n,a+i),s=r.getPointAtLength(a),d=r.getPointAtLength(l),c=180*Math.atan2(d.y-s.y,d.x-s.x)/Math.PI,u=Math.max(-45,Math.min(45,Math.round(-c)));m(u)},children:"Auto-level"})]}),de(hs,{min:-45,max:45,step:1,value:p,onChange:(e,t)=>m(t)}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:'Tilts the whole text block around its center. "Auto-level" rotates so the text\'s start and end sit on the same horizontal line — useful when a multi-curve wave makes the reading line slant.'})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Nx.map(e=>de(Vx,{label:e.label,selected:l===e.value,onClick:()=>s(e.value)},e.value))})]})]})}),de(si,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[de(bo,{style:{color:"var(--Text-Quiet)"},children:"Live WCAG 2.1 contrast against the painted background. Decorative display text counts as large text — AA needs 3:1, AAA needs 4.5:1 — but DinoDesign defaults to 4.5:1 across the board."}),I&&de(bx,{targetRef:I,label:"Curved text",deps:[l,n,JSON.stringify(d),p,f]}),ce(ao,{color:"quiet",children:["The SVG sets ",de("code",{children:'role="img"'})," and"," ",de("code",{children:"aria-label"})," to the rendered text so screen readers announce it as a labeled image, not a stream of individual glyphs."]})]})})]})})})]})]})}const jx={"display-large":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Large-Font-Size)",fontWeight:"var(--Display-Large-Font-Weight)",letterSpacing:"var(--Display-Large-Letter-Spacing)",pxHint:96},"display-small":{fontFamily:"var(--Header-Font-Family)",fontSize:"var(--Display-Small-Font-Size)",fontWeight:"var(--Display-Small-Font-Weight)",letterSpacing:"var(--Display-Small-Letter-Spacing)",pxHint:64}};function Gx({text:e="DinoDesign",theme:r="Primary",preset:o="Classic",custom:n,textStyle:i="display-large",fontSize:a,fontFamily:l,fontWeight:s,letterSpacing:d,className:c,style:u,...p}){const h=jx[i]||jx["display-large"],m=l??h.fontFamily,f=a??h.fontSize,g=s??h.fontWeight,x=d??h.letterSpacing,b="number"==typeof a?a:h.pxHint,v=Ex(o,n),y="dino-bevel-"+t.useId().replace(/:/g,""),S=y+"-s",k=t.useRef(null),[B,w]=t.useState(b),C=.6*b,T=Math.max(400,e.length*C+80),I=1.9*b,A=T/2,z=.7*I;t.useEffect(()=>{if(!k.current||"undefined"==typeof ResizeObserver)return;const e=k.current,t=()=>{const t=e.getBoundingClientRect();T&&t.width&&w(b*(t.width/T))};t();const r=new ResizeObserver(t);return r.observe(e),()=>r.disconnect()},[T,b]);const R=B>=19,E=v.bevel?Lx(v.angle+180,v.depth):{dx:0,dy:0},P=v.bevel?Lx(v.angle,v.depth):{dx:0,dy:0},O=v.shadow?Lx(v.angle,v.shadowDistance??6):{dx:0,dy:0},L=R?Px(r,"base"):Ox(r),M=Px(r,"highlight"),W=Px(r,"lowlight"),D={fontFamily:m,fontSize:"number"==typeof f?f+"px":f,fontWeight:g,letterSpacing:"number"==typeof x?x+"px":x},F=v.bevel&&R?"url(#"+y+")":void 0,N=v.shadow&&R?"url(#"+S+")":void 0;return ce("svg",{ref:k,viewBox:"0 0 "+T+" "+I,width:T,height:I,preserveAspectRatio:"xMidYMid meet",xmlns:"http://www.w3.org/2000/svg",style:{display:"block",maxWidth:"100%",height:"auto",overflow:"visible",...u},"aria-label":e,role:"img",className:["dino-bevel-text",c].filter(Boolean).join(" "),...p,children:[ce("defs",{children:[v.shadow&&de("filter",{id:S,x:"-30%",y:"-30%",width:"160%",height:"160%",children:de("feDropShadow",{dx:O.dx.toFixed(2),dy:O.dy.toFixed(2),stdDeviation:v.shadowBlur??8,style:{floodColor:W,floodOpacity:v.shadowOpacity??.6}})}),v.bevel&&ce("filter",{id:y,x:"-5%",y:"-5%",width:"110%",height:"110%",colorInterpolationFilters:"sRGB",children:[de("feGaussianBlur",{in:"SourceAlpha",stdDeviation:(v.softness??1)+.5,result:"blur-alpha"}),de("feOffset",{in:"blur-alpha",dx:P.dx.toFixed(2),dy:P.dy.toFixed(2),result:"shadow-offset"}),de("feFlood",{style:{floodColor:W,floodOpacity:.95},result:"shadow-flood"}),de("feComposite",{in:"shadow-flood",in2:"shadow-offset",operator:"in",result:"shadow-shaped"}),de("feComposite",{in:"shadow-shaped",in2:"SourceAlpha",operator:"in",result:"shadow-clipped"}),de("feOffset",{in:"blur-alpha",dx:E.dx.toFixed(2),dy:E.dy.toFixed(2),result:"hi-offset"}),de("feFlood",{style:{floodColor:M,floodOpacity:.95},result:"hi-flood"}),de("feComposite",{in:"hi-flood",in2:"hi-offset",operator:"in",result:"hi-shaped"}),de("feComposite",{in:"hi-shaped",in2:"SourceAlpha",operator:"in",result:"hi-clipped"}),ce("feMerge",{children:[de("feMergeNode",{in:"SourceGraphic"}),de("feMergeNode",{in:"shadow-clipped"}),de("feMergeNode",{in:"hi-clipped"})]})]})]}),v.shadow&&R&&de("text",{className:"dino-bevel-layer dino-bevel-layer--shadow",x:A,y:z,textAnchor:"middle",fill:L,filter:N,style:D,"aria-hidden":"true",children:e}),de("text",{className:v.bevel?"dino-bevel-text__base dino-bevel-layer":"dino-bevel-text__base",x:A,y:z,textAnchor:"middle",fill:L,filter:F,style:D,children:e})]})}const Ux=[...Rx.map(e=>({value:e,label:e,description:zx[e].description})),{value:"custom",label:"Custom",description:"Tune every knob"}],Xx=[{value:"light",label:"Light",css:"var(--Surface)"},{value:"warm",label:"Warm",css:"var(--Surface-Dim)"},{value:"dark",label:"Dark",css:"var(--Container-High)"}];function Kx({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function qx({option:e,active:t,onClick:r}){return ce(h,{onClick:r,role:"button",tabIndex:0,onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),r())},sx:{flex:"1 1 140px",minWidth:130,cursor:"pointer",border:"1.5px solid",borderColor:t?"var(--Buttons-Primary-Border)":"var(--Border)",background:t?"rgb(var(--Buttons-Primary-Highlight) / 0.18)":"var(--Background)",borderRadius:"var(--Style-Border-Radius)",p:1.5,transition:"border-color 0.15s, background 0.15s",textAlign:"center","&:hover":{borderColor:"var(--Buttons-Primary-Border)"},"&:focus-visible":{outline:"2px solid var(--Focus-Visible)",outlineOffset:2}},children:[de(bo,{style:{fontWeight:600,color:"var(--Text)"},children:e.label}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:2},children:e.description})]})}function Jx(){const[e,t]=r("DinoDesign"),[o,n]=r("Primary"),[i,a]=r("Classic"),[l,s]=r("light"),[d,c]=r(135),[u,p]=r(5),[m,f]=r(1),[g,x]=r(!0),[b,v]=r(!0),[y,S]=r(6),[k,w]=r(8),[C,T]=r(60),[I,A]=r(96),[z,R]=r(900),[E,P]=r(0),O="custom"===i,L=O?{angle:d,depth:u,softness:m,bevel:g,shadow:b,shadowDistance:y,shadowBlur:k,shadowOpacity:C/100}:void 0;const M=Xx.find(e=>e.value===l)?.css||Xx[0].css;return ce(h,{children:[de(Jr,{style:{marginBottom:12},children:"Bevel Display Text"}),de(co,{color:"quiet",style:{marginBottom:24,maxWidth:720},children:"Straight-line display text with an SVG inset-bevel and optional drop shadow. Colors are locked to the active button-palette tokens (Button / Highlight / Lowlight) so the same preset reads correctly under any theme."}),ce(h,{sx:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(360px, 1fr))",gap:3,alignItems:"start"},children:[de(h,{sx:{minWidth:0},children:de(h,{"data-surface":"Container",sx:{background:M,borderRadius:2,p:4,display:"flex",alignItems:"center",justifyContent:"center",minHeight:240,overflow:"auto",position:"sticky",top:16,transition:"background 0.2s"},children:de(Gx,{text:e,theme:o,preset:i,custom:L,fontSize:I,fontWeight:z,letterSpacing:E})})}),de(h,{sx:{minWidth:0,alignSelf:"flex-start"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(B,{spacing:3,sx:{p:3,maxWidth:720},children:[de(qn,{label:"Text",value:e,onChange:e=>t(e.target.value),placeholder:"Your headline…",size:"medium"}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"THEME"}),de(B,{direction:"row",spacing:1,sx:{flexWrap:"wrap",rowGap:1},children:Ax.map(e=>de(Kx,{label:e,selected:o===e,onClick:()=>n(e)},e))}),ce(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:["Resolves to ",ce("code",{children:["--Buttons-","{Theme}","-Button"]})," ","(fill), ",de("code",{children:"-Highlight"})," (light edge), and"," ",de("code",{children:"-Lowlight"})," (shadow edge)."]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PRESETS"}),de(h,{sx:{display:"flex",flexWrap:"wrap",gap:1},children:Ux.map(e=>de(qx,{option:e,active:i===e.value,onClick:()=>function(e){if(a(e),"custom"!==e){const t=Ex(e);c(t.angle),p(t.depth??5),f(t.softness??1),x(t.bevel),v(t.shadow),S(t.shadowDistance??6),w(t.shadowBlur??8),T(Math.round(100*(t.shadowOpacity??.6)))}}(e.value)},e.value))})]}),O&&ce(h,{sx:{border:"1px solid var(--Border)",borderRadius:"var(--Style-Border-Radius)",p:2},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:12},children:"CUSTOM"}),ce(B,{spacing:2,children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Light angle",ce("span",{style:{float:"right"},children:[d,"°"]})]}),de(hs,{min:0,max:360,step:5,value:d,onChange:(e,t)=>c(t)})]}),ce(h,{sx:{border:"1px solid var(--Border-Variant)",borderRadius:1,p:1.5},children:[de(ra,{label:"Inset bevel",checked:g,onChange:e=>x(e.target.checked)}),g&&ce(B,{spacing:1.5,sx:{mt:1.5},children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Depth",ce("span",{style:{float:"right"},children:[u,"px"]})]}),de(hs,{min:1,max:16,step:1,value:u,onChange:(e,t)=>p(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Softness",ce("span",{style:{float:"right"},children:[m,"px"]})]}),de(hs,{min:0,max:6,step:.5,value:m,onChange:(e,t)=>f(t)})]})]})]}),ce(h,{sx:{border:"1px solid var(--Border-Variant)",borderRadius:1,p:1.5},children:[de(ra,{label:"Drop shadow",checked:b,onChange:e=>v(e.target.checked)}),b&&ce(B,{spacing:1.5,sx:{mt:1.5},children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Distance",ce("span",{style:{float:"right"},children:[y,"px"]})]}),de(hs,{min:1,max:24,step:1,value:y,onChange:(e,t)=>S(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Blur",ce("span",{style:{float:"right"},children:[k,"px"]})]}),de(hs,{min:0,max:24,step:1,value:k,onChange:(e,t)=>w(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Opacity",ce("span",{style:{float:"right"},children:[C,"%"]})]}),de(hs,{min:10,max:100,step:5,value:C,onChange:(e,t)=>T(t)})]})]})]})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"TYPOGRAPHY"}),ce(B,{spacing:2,children:[ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Font size",ce("span",{style:{float:"right"},children:[I,"px"]})]}),de(hs,{min:32,max:160,step:4,value:I,onChange:(e,t)=>A(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Font weight",de("span",{style:{float:"right"},children:z})]}),de(hs,{min:400,max:900,step:100,value:z,onChange:(e,t)=>R(t)})]}),ce("div",{children:[ce(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:["Letter spacing",ce("span",{style:{float:"right"},children:[E,"px"]})]}),de(hs,{min:-2,max:20,step:1,value:E,onChange:(e,t)=>P(t)})]})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"PREVIEW BACKGROUND"}),de(B,{direction:"row",spacing:1,children:Xx.map(e=>de(Kx,{label:e.label,selected:l===e.value,onClick:()=>s(e.value)},e.value))}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginTop:6},children:"Showcase-only — doesn't affect the emitted code."})]})]})}),de(si,{value:1,children:ce(B,{spacing:2,sx:{p:3,maxWidth:560},children:[ce(bo,{style:{color:"var(--Text-Quiet)"},children:["BevelText uses the same Highlight / Lowlight token pair as button bevels, which target the WCAG 2.1 large-text minimum (3:1). Bevel text is decorative display — the SVG sets"," ",de("code",{children:'role="img"'})," and ",de("code",{children:"aria-label"})," to the rendered string so screen readers announce it as a labeled image, not a stream of glyphs."]}),de(ao,{color:"quiet",children:"Keep the rendered glyph height above ~24px when the bevel is on — at smaller sizes the highlight / lowlight stripes optically reduce the legible stroke width and the 3:1 contrast no longer feels comfortable."})]})})]})})})]})]})}function Yx({open:e,onClose:t,items:o=[],onItemClick:n,width:i=280,variant:a="temporary",header:l,footer:s,sx:d={},...c}){const[u,p]=r(null),[f,g]=r({}),x=(e,r)=>{p(r),n?.(e),"temporary"===a&&t?.()},b="permanent"===a?"permanent":"standard"===a?"standard":"temporary",v=ce(h,{sx:{display:"flex",flexDirection:"column",height:"100%",backgroundColor:"var(--Container)",color:"var(--Text)"},children:[l&&de(h,{sx:{p:2,borderBottom:"1px solid var(--Border-Variant)"},children:"string"==typeof l?de(T,{variant:"h6",sx:{fontWeight:700},children:l}):l}),de(_,{sx:{flex:1,overflow:"auto",py:1},children:o.map((e,t)=>{const r=u===t,o=e.submenu&&e.submenu.length>0,n=f[t];return ce(h,{children:[de(w,{title:e.tooltip||"",placement:"right",children:de(ee,{disablePadding:!0,children:ce(te,{onClick:()=>{o?(e=>{g(t=>({...t,[e]:!t[e]}))})(t):x(e,t)},selected:r&&!o,sx:{backgroundColor:r&&!o?"var(--Buttons-Primary-Button)":"transparent",color:r&&!o?"var(--Buttons-Primary-Text)":"var(--Text)","&:hover":{backgroundColor:r&&!o?"var(--Buttons-Primary-Button)":"var(--Container-High)"},"&.Mui-selected":{backgroundColor:"var(--Buttons-Primary-Button)",color:"var(--Buttons-Primary-Text)","&:hover":{backgroundColor:"var(--Buttons-Primary-Button)"}},transition:"all 0.2s ease-in-out"},children:[e.icon&&de(re,{sx:{color:r&&!o?"var(--Buttons-Primary-Text)":"var(--Icons-Primary)",minWidth:40},children:e.badge?de(m,{badgeContent:e.badge,color:"error",children:e.icon}):e.icon}),de(oe,{primary:e.label,primaryTypographyProps:{variant:"body2",fontWeight:r&&!o?600:500}}),o&&de(h,{sx:{ml:1},children:de(n?Gt:Se,{})})]})})}),o&&de(ne,{in:n,timeout:"auto",unmountOnExit:!0,children:de(_,{component:"div",disablePadding:!0,children:e.submenu.map((e,t)=>de(ee,{disablePadding:!0,children:ce(te,{onClick:()=>x(e,t),sx:{pl:4,backgroundColor:"transparent",color:"var(--Text)","&:hover":{backgroundColor:"var(--Container-High)"},"&.Mui-selected":{backgroundColor:"var(--Buttons-Primary-Button)",color:"var(--Buttons-Primary-Text)"}},children:[e.icon&&de(re,{sx:{color:"var(--Icons-Primary)",minWidth:40},children:e.icon}),de(oe,{primary:e.label})]})},t))})}),e.divider&&de(ie,{sx:{my:1,borderColor:"var(--Border-Variant)"}})]},t)})}),s&&de(h,{sx:{borderTop:"1px solid var(--Border-Variant)",p:2},children:"string"==typeof s?de(T,{variant:"caption",sx:{color:"var(--Text-Quiet)"},children:s}):s})]});return"permanent"===a?de(h,{sx:{width:i,flexShrink:0,...d},children:v}):de(ae,{variant:b,open:e,onClose:t,PaperProps:{sx:{width:i,backgroundColor:"var(--Container)",color:"var(--Text)",...d}},...c,children:v})}function Zx({layout:e="side",navItems:t=[{label:"Home",icon:de(Be,{}),path:"/"},{label:"About",icon:de(Pe,{}),path:"/about"},{label:"Settings",icon:de(Ce,{}),path:"/settings"},{label:"Help",icon:de(gr,{}),path:"/help"}],title:o="My App",children:n,onLayoutChange:i,onNavigate:a,sx:l={},...s}){const d=le(),c=se(d.breakpoints.down("md"));se(d.breakpoints.down("lg"));const[u,p]=r(!1),[m,f]=r(!1),g=c?"top":e,x=({compact:e=!1})=>de(_,{sx:{py:1},children:t.map((t,r)=>de(w,{title:e?t.label:"",placement:"right",children:ce(te,{onClick:()=>{a?.(t),p(!1)},sx:{color:"var(--Text)","&:hover":{backgroundColor:"var(--Container-High)"},transition:"all 0.2s ease-in-out",justifyContent:e?"center":"flex-start",px:e?1:2},children:[de(re,{sx:{color:"var(--Icons-Primary)",minWidth:e?"auto":40,mr:e?0:1},children:t.icon}),!e&&de(oe,{primary:t.label})]})},r))});return ce(h,{sx:{minHeight:"100vh",backgroundColor:"var(--Background)",color:"var(--Text)",display:"flex",flexDirection:"column",...l},...s,children:[de(Z,{position:"static",sx:{backgroundColor:"var(--Header)",color:"var(--Text)",boxShadow:"0 1px 3px rgba(0,0,0,0.12)",borderBottom:"1px solid var(--Border-Variant)"},children:ce($,{children:[c&&"rail"!==g&&de(C,{edge:"start",color:"inherit",onClick:()=>p(!u),sx:{mr:2},children:de(u?Ot:Pt,{})}),de(T,{variant:"h6",sx:{flex:1,fontWeight:700},children:o}),!c&&i&&ce(E,{value:e,exclusive:!0,onChange:(e,t)=>{t&&i(t)},size:"small",sx:{"& .MuiToggleButton-root":{color:"var(--Text)",border:"1px solid var(--Border)","&.Mui-selected":{backgroundColor:"var(--Button-Primary-Button)",color:"#fff",borderColor:"var(--Button-Primary-Button)"}}},children:[de(R,{value:"side","aria-label":"side nav",children:"☰ Side"}),de(R,{value:"rail","aria-label":"rail nav",children:"⫷ Rail"}),de(R,{value:"side-rail","aria-label":"side-rail nav",children:"☰⫷ Both"})]})]})}),ce(h,{sx:{display:"flex",flex:1},children:[("rail"===g||"side-rail"===g)&&!c&&de(h,{sx:{width:80,backgroundColor:"var(--Container)",borderRight:"1px solid var(--Border-Variant)",display:"flex",flexDirection:"column",py:2},children:de(x,{compact:!0})}),("side"===g||"side-rail"===g)&&!c&&ce(h,{sx:{width:m?80:280,backgroundColor:"var(--Container)",borderRight:"1px solid var(--Border-Variant)",transition:"width 0.3s ease-in-out",display:"flex",flexDirection:"column"},children:[ce(h,{sx:{p:2,display:"flex",alignItems:"center",justifyContent:"space-between",borderBottom:"1px solid var(--Border-Variant)",minHeight:64},children:[!m&&de(T,{variant:"h6",sx:{fontWeight:700,color:"var(--Text)"},children:"Menu"}),de(C,{size:"small",onClick:()=>f(!m),sx:{color:"var(--Icons-Primary)"},children:m?"›":"‹"})]}),de(x,{compact:m})]}),c&&ce(ae,{anchor:"left",open:u,onClose:()=>p(!1),sx:{"& .MuiDrawer-paper":{backgroundColor:"var(--Container)",width:280}},children:[de(h,{sx:{p:2,borderBottom:"1px solid var(--Border-Variant)"},children:de(T,{variant:"h6",sx:{fontWeight:700},children:"Menu"})}),de(x,{compact:!1})]}),de(h,{sx:{flex:1,overflow:"auto",backgroundColor:"var(--Background)"},children:de(F,{maxWidth:"lg",sx:{py:4},children:n})})]})]})}const $x={small:{summaryPadding:"8px 12px",detailsPy:"8px",detailsPx:"12px",fontSize:"13px",iconSize:"small"},medium:{summaryPadding:"12px 8px 12px 16px",detailsPy:"12px",detailsPx:"16px",fontSize:"14px",iconSize:"medium"},large:{summaryPadding:"16px 20px",detailsPy:"16px",detailsPx:"20px",fontSize:"16px",iconSize:"large"}},_x=s({variant:"solid",color:"default",size:"medium",spacing:0}),eb=s({expanded:!1,toggle:()=>{},disabled:!1,accordionId:""});function tb({children:e,variant:t="solid",color:r="default",size:o="medium",spacing:n=0,className:i="",sx:a={},...l}){const s="default"===r?"Default":(d=r).charAt(0).toUpperCase()+d.slice(1);var d;const c=0===n,u="default"===r?"Default":s,p="dark"===t?"Surface-Dimmest":"light"===t?"Surface-Brightest":"Surface";return de(_x.Provider,c?{value:{variant:t,color:r,size:o,spacing:n},children:de(h,{role:"presentation",className:"accordion-group accordion-group-"+t+" "+i,sx:{border:"1px solid var(--Border-Variant)",borderRadius:"var(--Button-Radius)",overflow:"hidden",boxShadow:an,...a},...l,children:de(h,{"data-theme":u,"data-surface":p,sx:{backgroundColor:"var(--Background)",borderRadius:"calc(var(--Button-Radius) - 1px)"},children:e})})}:{value:{variant:t,color:r,size:o,spacing:n,dataTheme:u,dataSurface:p},children:de(h,{role:"presentation",className:"accordion-group accordion-group-"+t+" accordion-group-spaced "+i,sx:{display:"flex",flexDirection:"column",gap:.5===n?"var(--Sizing-Half)":1===n?"var(--Sizing-1)":1.5===n?"var(--Sizing-1-and-Half)":2===n?"var(--Sizing-2)":8*n+"px",...a},...l,children:e})})}function rb({children:e,expanded:t,defaultExpanded:o=!1,onChange:n,disabled:i=!1,className:a="",sx:s={},...d}){const[c,u]=r(o),p=void 0!==t,m=p?t:c,{spacing:f,dataTheme:g,dataSurface:x}=l(_x),b=0===f,[v]=r(()=>"accordion-"+Math.random().toString(36).substring(2,9)),y=de(eb.Provider,{value:{expanded:m,toggle:()=>{if(i)return;const e=!m;p||u(e),n?.(e)},disabled:i,accordionId:v},children:de(h,{className:"accordion"+(m?" accordion-expanded":"")+(i?" accordion-disabled":"")+" "+a,sx:{...b&&{borderBottom:"1px solid var(--Border-Variant)","&:last-child":{borderBottom:"none"}},opacity:i?.5:1,...s},...d,children:e})});return b?y:de(h,{sx:{border:"1px solid var(--Border-Variant)",borderRadius:"var(--Button-Radius)",overflow:"hidden",boxShadow:an},children:de(h,{"data-theme":g,"data-surface":x,sx:{backgroundColor:"var(--Background)",borderRadius:"calc(var(--Button-Radius) - 1px)"},children:y})})}const ob={small:ao,medium:co,large:fo};function nb({children:e,startDecorator:t,endDecorator:r,eyebrow:o,overline:n,secondary:i,expandIcon:a,className:s="",sx:d={},...c}){const{expanded:u,toggle:p,disabled:m,accordionId:f}=l(eb),{size:g}=l(_x),x=$x[g]||$x.medium,b=ob[g]||ob.medium,v=a||de(jo,{size:x.iconSize,sx:{color:u?"var(--Text)":"var(--Quiet)",transition:"color 0.15s ease"},children:de(Se,{})}),y={overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",display:"block"};return ce(h,{component:"button",role:"button","aria-expanded":u,"aria-controls":f+"-content",id:f+"-header",tabIndex:m?-1:0,onClick:p,onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),p())},className:"accordion-summary"+(u?" accordion-summary-expanded":"")+" "+s,sx:{display:"flex",flexDirection:"row",alignItems:"flex-start",justifyContent:"flex-start",width:"100%",gap:"var(--Sizing-1-and-Half)",padding:x.summaryPadding,border:"none",backgroundColor:"transparent",color:u?"var(--Text)":"var(--Quiet)",fontSize:x.fontSize,fontFamily:"inherit",cursor:m?"not-allowed":"pointer",textAlign:"left",transition:"color 0.2s ease, background-color 0.15s ease",borderRadius:0,"&:hover":m?{}:{color:"var(--Text)","& .omni-icon":{color:"var(--Text)"}},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-3px"},...d},...c,children:[t&&de(h,{className:"accordion-summary-start",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0},children:t}),ce(h,{sx:{flex:1,minWidth:0,display:"flex",flexDirection:"column",gap:"var(--Sizing-Half)"},children:[(o??n)&&de(To,{style:{...y,color:"var(--Text-Quiet)"},children:o??n}),null!=e&&de(b,{style:{...y,color:"inherit",fontWeight:600},children:e}),i&&de(ao,{style:{...y,color:"var(--Text-Quiet)"},children:i})]}),r&&de(h,{className:"accordion-summary-end",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0},children:r}),de(h,{sx:{display:"flex",alignItems:"center",justifyContent:"center",transform:u?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.25s ease",flexShrink:0},children:v})]})}function ib({children:e,className:t="",sx:r={},...o}){const{expanded:n,accordionId:i}=l(eb),{size:a}=l(_x),s=$x[a]||$x.medium;return n?de(h,{role:"region",id:i+"-content","aria-labelledby":i+"-header",className:"accordion-details "+t,sx:{padding:"0 "+s.detailsPx+" "+s.detailsPy+" "+s.detailsPx,color:"var(--Text)",fontSize:s.fontSize,fontFamily:"inherit",lineHeight:1.6,...r},...o,children:e}):null}const ab={1:{padLeft:0,togglePadLeft:0},2:{padLeft:24,togglePadLeft:4},3:{padLeft:48,togglePadLeft:0},4:{padLeft:72,togglePadLeft:0},5:{padLeft:88,togglePadLeft:4}},lb={0:{padLeft:8},1:{padLeft:48},2:{padLeft:56,slotPadLeft:4},3:{padLeft:64,slotPadLeft:4},4:{padLeft:88,slotPadLeft:4},5:{padLeft:112},6:{padLeft:128}};function sb({label:e,icon:t,level:r=0,toggle:o="none",onToggle:n,disabled:i=!1,size:a="small",className:l="",sx:s={},children:d,...c}){const u=6===r&&"none"!==o?"none":o,p="on"===u,m="none"!==u,f=m?ab[r]||{padLeft:0,togglePadLeft:0}:lb[r]||lb[0],g={paddingTop:"8px",paddingRight:"8px",paddingBottom:"8px",paddingLeft:(f.padLeft??8)+"px"};return ce(h,{className:"tree-branch tree-branch-"+a+" tree-branch-level-"+r+" tree-branch-toggle-"+u+(i?" tree-branch-disabled":"")+(l?" "+l:""),sx:{width:"100%",...s},...c,children:[ce(h,{component:"button",type:"button",role:"treeitem","aria-expanded":m?p:void 0,"aria-disabled":i||void 0,tabIndex:i?-1:0,onClick:e=>{i||m&&(e.stopPropagation(),n?.(p?"off":"on"))},disabled:i,sx:{display:"flex",flexDirection:"row",alignItems:"center",gap:"4px",width:"100%",minHeight:"24px",...g,border:"none",backgroundColor:"transparent",fontFamily:"inherit",color:"inherit",textAlign:"left",cursor:i?"not-allowed":"pointer",opacity:i?.5:1,outline:"none",transition:"background-color 0.15s ease, color 0.15s ease","&:hover":i?{}:{backgroundColor:"var(--Hover)"},"&:active":i?{}:{backgroundColor:"var(--Pressed)"},"&:focus-visible":{outline:"3px solid var(--Focus-Visible)",outlineOffset:"-2px"}},children:[m&&de(h,{className:"tree-branch-toggle",sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,paddingLeft:(f.togglePadLeft??0)+"px"},children:de(h,{sx:{display:"inline-flex",alignItems:"center",justifyContent:"center",transition:"transform 0.2s ease",transform:p?"rotate(-90deg)":"rotate(0deg)"},children:de(jo,{size:"small",children:de(Kt,{})})})}),ce(h,{className:"tree-branch-slot",sx:{display:"flex",flexDirection:"row",alignItems:"center",gap:"4px",flex:1,minWidth:0,...void 0!==f.slotPadLeft&&{paddingLeft:f.slotPadLeft+"px"}},children:[t&&de(h,{sx:{display:"inline-flex",alignItems:"center",flexShrink:0},children:de(jo,{size:"small",children:t})}),null!=e&&de(lo,{style:{color:"inherit",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",display:"block",flex:1,minWidth:0},children:e})]})]}),p&&d&&de(h,{role:"group",sx:{display:"flex",flexDirection:"column"},children:d})]})}const db=e=>e?e.charAt(0).toUpperCase()+e.slice(1):"",cb=[{label:"Default",colors:["default"]},{label:"Theme",colors:["primary","secondary","tertiary","neutral"]},{label:"State",colors:["info","success","warning","error"]}],ub=e=>de(h,{sx:{width:8,height:8,borderRadius:"50%",backgroundColor:e,flexShrink:0}}),pb=[{id:"1",label:"Documents",icon:de(cr,{}),badge:ub("var(--Warning-Text, orange)"),children:[{id:"1-1",label:"Company",icon:de(xr,{}),badge:ub("var(--Warning-Text, orange)"),children:[{id:"1-1-1",label:"Invoice",icon:de(vr,{})},{id:"1-1-2",label:"Meeting notes",icon:de(br,{})},{id:"1-1-3",label:"Tasks list",icon:de(br,{})},{id:"1-1-4",label:"Equipment",icon:de(vr,{})},{id:"1-1-5",label:"Video conference",icon:de(yr,{})}]},{id:"1-2",label:"Personal",icon:de(cr,{})},{id:"1-3",label:"Group photo",icon:de(Ut,{})}]},{id:"2",label:"Bookmarked",icon:de(_t,{}),children:[{id:"2-1",label:"Favourites",icon:de(br,{})}]},{id:"3",label:"History",icon:de(cr,{})},{id:"4",label:"Trash",icon:de(we,{}),disabled:!0}],hb=JSON.stringify(Tf,null,2);function mb({ratio:e,threshold:t}){if(!e)return de(bo,{style:{color:"var(--Text-Quiet)"},children:"--"});const r=parseFloat(e)>=t;return ce(h,{sx:{display:"inline-flex",alignItems:"center",gap:.5},children:[ce(h,{sx:{px:1,py:.25,borderRadius:"4px",fontSize:"11px",fontWeight:700,backgroundColor:r?"var(--Tags-Success-BG)":"var(--Tags-Error-BG)",color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:[e,":1"]}),de(bo,{style:{color:r?"var(--Tags-Success-Text)":"var(--Tags-Error-Text)"},children:r?"Pass":"Fail"})]})}function fb({label:e,ratio:t,threshold:r,note:o}){return ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"flex-start",py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(h,{sx:{flex:1},children:[de(ao,{style:{color:"var(--Text)"},children:e}),o&&de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:o})]}),de(mb,{ratio:t,threshold:r})]})}function gb({label:e,selected:t,onClick:r}){return de(In,{selected:t,variant:t?"default":"default-outline",size:"small",onClick:r,children:e})}function xb({color:e,selected:t,onClick:r}){const o=db(e);return de(h,{component:"button",onClick:()=>r(e),"aria-label":"Select "+o,"aria-pressed":t,title:o,sx:{width:"var(--Button-Height)",height:"var(--Button-Height)",borderRadius:"4px",backgroundColor:"var(--Buttons-"+o+"-Button)",border:t?"2px solid var(--Text)":"1px solid var(--Border)",outline:t?"2px solid var(--Focus-Visible)":"2px solid transparent",outlineOffset:"1px",cursor:"pointer",flexShrink:0,display:"flex",alignItems:"center",justifyContent:"center",transition:"transform 0.1s ease","&:hover":{transform:"scale(1.1)"}},children:t&&de(he,{sx:{fontSize:16,color:"var(--Buttons-"+o+"-Text)",pointerEvents:"none"}})})}function bb({value:e,onChange:t}){const[o,n]=r(e),[i,a]=r(null);return ce(h,{children:[ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:1},children:[de(To,{style:{color:"var(--Text-Quiet)"},children:"TREE DATA (JSON)"}),de(In,{variant:"ghost",size:"small",onClick:()=>{n(hb),a(null),t(Tf)},children:"Reset"})]}),de(h,{component:"textarea",value:o,onChange:e=>{n(e.target.value);try{const r=JSON.parse(e.target.value);a(null),t(r)}catch(e){a(e.message)}},spellCheck:!1,rows:10,sx:{width:"100%",fontFamily:"monospace",fontSize:"11px",backgroundColor:"#1e1e1e",color:i?"#f87171":"#e5e7eb",border:"1px solid "+(i?"#f87171":"#333"),borderRadius:"6px",padding:"10px",resize:"vertical",outline:"none",boxSizing:"border-box",lineHeight:1.5,"&:focus":{borderColor:"var(--Focus-Visible)"}}}),i&&ce(bo,{style:{color:"#f87171",display:"block",marginTop:4},children:["JSON error: ",i]})]})}function vb(){const[e,t]=r("solid"),[a,l]=r("primary"),[s,d]=r("default"),[c,u]=r("slide"),[p,m]=r("single"),[f,g]=r(!1),[x,b]=r(!1),[v,y]=r(!1),[S,k]=r(Tf),[w,C]=r(null),[T,A]=r("Surface"),[z,R]=r({}),E=o(null),P=db(a),O=v?pb:S,L=n((e,t)=>e&&getComputedStyle(e).getPropertyValue(t).trim()||null,[]);i(()=>{const e=setTimeout(()=>{const e=E.current;R({text:L(e,"--Text"),textQuiet:L(e,"--Text-Quiet"),background:L(e,"--Background"),border:L(e,"--Border"),focusVisible:L(e,"--Focus-Visible"),activeBtn:L(e,"--Buttons-"+P+"-Button"),activeBorder:L(e,"--Buttons-"+P+"-Border")})},50);return()=>clearTimeout(e)},[a,w,L,P]);return ce(h,{sx:{pb:8},children:[de(Jr,{children:"Tree View"}),ce(I,{container:!0,sx:{mt:2,alignItems:"flex-start",flexWrap:"wrap"},children:[ce(I,{item:!0,sx:{width:{xs:"100%",md:"55%"},flexShrink:0,pr:{md:3}},children:[de(di,{ref:E,theme:w,children:de(h,{sx:{width:"100%",maxWidth:360},children:de(Cf,{color:a,variant:e,density:s,animation:c,selectionMode:p,checkboxSelection:f,disableSelection:x,items:O,defaultExpandedItems:["1","1-1","2"]})})}),de(Vi,{code:(()=>{const t=["<OmniTreeView"];return"default"!==a&&t.push(' color="'+a+'"'),"default"!==e&&t.push(' variant="'+e+'"'),"default"!==s&&t.push(' density="'+s+'"'),"slide"!==c&&t.push(' animation="'+c+'"'),"single"!==p&&t.push(' selectionMode="'+p+'"'),f&&t.push(" checkboxSelection"),x&&t.push(" disableSelection"),t.push(" items={treeData}"),t.push("/>"),t.join("\n")})(),language:"JSX",wrap:!0,sx:{mt:2}})]}),de(I,{item:!0,sx:{width:{xs:"100%",md:"45%"},flexShrink:0,alignSelf:"flex-start",minWidth:0,overflow:"hidden"},children:de(h,{sx:{backgroundColor:"var(--Background)",overflow:"hidden"},children:ce(ii,{defaultValue:0,variant:"standard",color:"primary",children:[ce(ai,{children:[de(li,{children:"Playground"}),de(li,{children:"Accessibility"})]}),de(si,{value:0,children:ce(h,{sx:{p:3},children:[de(h,{sx:{mb:3},children:de(hi,{theme:w,onThemeChange:C,surface:T,onSurfaceChange:A})}),ce(h,{children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"STYLE"}),ce(B,{direction:"row",spacing:1,children:[de(gb,{label:"Solid",selected:"solid"===e,onClick:()=>t("solid")}),de(gb,{label:"Light",selected:"light"===e,onClick:()=>t("light")})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"COLOR"}),de(B,{spacing:1.5,children:cb.map(e=>ce(h,{children:[de(bo,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:4,fontWeight:600},children:e.label}),de(B,{direction:"row",flexWrap:"wrap",sx:{gap:1},children:e.colors.map(e=>de(xb,{color:e,selected:a===e,onClick:l},e))})]},e.label))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"DENSITY"}),ce(B,{direction:"row",spacing:1,children:[de(gb,{label:"Compact",selected:"compact"===s,onClick:()=>d("compact")}),de(gb,{label:"Default",selected:"default"===s,onClick:()=>d("default")})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"ANIMATION"}),de(B,{direction:"row",spacing:1,children:["none","slide","spring"].map(e=>de(gb,{label:db(e),selected:c===e,onClick:()=>u(e)},e))})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"SELECTION MODE"}),ce(B,{direction:"row",spacing:1,children:[de(gb,{label:"Single",selected:"single"===p,onClick:()=>m("single")}),de(gb,{label:"Multi",selected:"multi"===p,onClick:()=>m("multi")})]})]}),ce(h,{sx:{mt:3},children:[de(To,{style:{color:"var(--Text-Quiet)",display:"block",marginBottom:8},children:"OPTIONS"}),ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Show Icons"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Load sample data with icons and badges"})]}),de(ta,{checked:v,onChange:e=>y(e.target.checked),size:"small","aria-label":"Show icons"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Checkbox Selection"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Show checkboxes for each item"})]}),de(ta,{checked:f,onChange:e=>g(e.target.checked),size:"small","aria-label":"Checkbox selection"})]}),ce(h,{sx:{mt:2,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ce(h,{children:[de(ko,{children:"Disable Selection"}),de(bo,{style:{color:"var(--Text-Quiet)",display:"block"},children:"Items are not selectable"})]}),de(ta,{checked:x,onChange:e=>b(e.target.checked),size:"small","aria-label":"Disable selection"})]})]}),!v&&de(h,{sx:{mt:3},children:de(bb,{value:hb,onChange:k})})]})}),de(si,{value:1,children:de(h,{sx:{p:3},children:ce(B,{spacing:3,children:[ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Text Contrast (WCAG 1.4.3 — 4.5:1)"}),de(fb,{label:"Resting: var(--Text-Quiet) vs. background",ratio:Ui(z.textQuiet,z.background),threshold:4.5,note:"Unselected items use Text-Quiet"}),de(fb,{label:"Hover: var(--Text) vs. background",ratio:Ui(z.text,z.background),threshold:4.5,note:"Hovered items use var(--Text)"}),de(fb,{label:"Active (solid): var(--Text) vs. var(--Buttons-"+P+"-Button)",ratio:Ui(z.text,z.activeBtn),threshold:4.5,note:"Selected item with solid fill"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"Focus Indicator (WCAG 2.4.11 — 3:1)"}),de(fb,{label:"var(--Focus-Visible) vs. background",ratio:Ui(z.focusVisible,z.background),threshold:3,note:"outline: 2px solid var(--Focus-Visible); outline-offset: -2px"})]}),ce(h,{sx:{p:3,backgroundColor:"var(--Background)",borderRadius:"var(--Style-Border-Radius)",border:"1px solid var(--Border)"},children:[de(Zr,{children:"ARIA and Semantics"}),de(B,{spacing:0,children:[{label:"Role",value:'role="tree" on root, role="treeitem" on each node'},{label:"Expansion",value:'aria-expanded="true/false" on parent items'},{label:"Selection",value:"aria-selected on selected items"},{label:"Disabled",value:'aria-disabled="true" on disabled items'},{label:"Icons",value:"Icon elements are aria-hidden — label carries the accessible name"},{label:"Keyboard",value:"Arrow keys navigate, Enter/Space selects, * expands all siblings"}].map(({label:e,value:t})=>ce(h,{sx:{py:1.5,borderBottom:"1px solid var(--Border)"},children:[ce(ao,{children:[e,":"]}),de(bo,{style:{color:"var(--Text-Quiet)",fontFamily:"monospace"},children:t})]},e))})]})]})})})]})})})]})]})}function yb(e,t){if(document.getElementById(t))return;const r=document.createElement("link");r.rel="stylesheet",r.href=e,r.id=t,document.head.appendChild(r)}const Sb=[{value:"desktop",label:"Desktop",note:"32px touch targets (WCAG)"},{value:"ios-mobile",label:"iOS Mobile",note:"44px touch targets (HIG)"},{value:"ios-tablet",label:"iOS Tablet",note:"44px touch targets (HIG)"},{value:"android",label:"Android",note:"48px touch targets (M3)"}],kb={desktop:"32px","ios-mobile":"44px","ios-tablet":"44px",android:"48px"};function Bb(){const{mode:e,switchMode:t}=function(e="light"){const[t,o]=r(e);return i(()=>{yb("/styles/foundation.css","css-foundation"),yb("/styles/core.css","css-core"),yb("/styles/Light-Mode.css","css-mode"),yb("/styles/base.css","css-base"),yb("/styles/typography-tokens.css","css-typography-tokens")},[]),{mode:t,switchMode:e=>{const t=document.getElementById("css-mode");t&&(t.href="dark"===e?"/styles/Dark-Mode.css":"/styles/Light-Mode.css"),o(e),localStorage.setItem("themeMode",e)}}}("light"),[o,n]=r(!1),[a,l]=r("desktop");i(()=>{const e=localStorage.getItem("dino-platform")||"desktop",r=localStorage.getItem("themeMode")||"light";l(e),document.documentElement.style.setProperty("--Button-Height",kb[e]||"32px"),"dark"===r&&t("dark")},[]);const s=e=>{l(e),localStorage.setItem("dino-platform",e),document.documentElement.style.setProperty("--Button-Height",kb[e]||"32px")};return ce(ue,{children:[de(h,{onClick:()=>n(!0),role:"button","aria-label":"Open settings",sx:{position:"fixed",bottom:24,right:24,width:52,height:52,borderRadius:"50%",backgroundColor:"var(--Buttons-Tertiary-Button)",color:"var(--Buttons-Tertiary-Text)",display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",boxShadow:"0 4px 12px rgba(0,0,0,0.15)",zIndex:999,transition:"transform 0.15s ease, box-shadow 0.15s ease","&:hover":{transform:"scale(1.08)",boxShadow:"0 6px 16px rgba(0,0,0,0.2)"}},children:de(Rt,{sx:{fontSize:24}})}),de(xu,{anchor:"right",open:o,onClose:()=>n(!1),hideBackdrop:!0,size:"small",sx:{width:320,zIndex:99999999},children:ce(h,{sx:{p:3,height:"100%",display:"flex",flexDirection:"column"},children:[ce(h,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:2},children:[de(Zr,{children:"Settings"}),de(In,{iconOnly:!0,variant:"ghost",size:"small",onClick:()=>n(!1),"aria-label":"Close settings",children:de(Et,{fontSize:"small"})})]}),de(ie,{sx:{mb:3,borderColor:"var(--Border)"}}),de(h,{sx:{flex:1,overflowY:"auto"},children:ce(B,{spacing:4,children:[ce(h,{children:[de(To,{style:{color:"var(--Text)",opacity:.85,display:"block",marginBottom:12,fontWeight:600},children:"MODE"}),ce(B,{direction:"row",spacing:1,children:[de(In,{variant:"light"===e?"primary":"primary-outline",size:"small",onClick:()=>t("light"),sx:{flex:1},children:"Light"}),de(In,{variant:"dark"===e?"primary":"primary-outline",size:"small",onClick:()=>t("dark"),sx:{flex:1},children:"Dark"})]})]}),ce(h,{children:[de(To,{style:{color:"var(--Text)",opacity:.85,display:"block",marginBottom:12,fontWeight:600},children:"PLATFORM"}),de(B,{spacing:1,children:Sb.map(({value:e,label:t,note:r})=>{const o=a===e;return ce(h,{onClick:()=>s(e),sx:{p:1.5,borderRadius:"var(--Style-Border-Radius)",cursor:"pointer",border:o?"2px solid var(--Buttons-Primary-Button)":"1px solid var(--Border)",backgroundColor:o?"var(--Background)":"transparent",display:"flex",justifyContent:"space-between",alignItems:"center",transition:"all 0.15s ease","&:hover":{backgroundColor:"var(--Hover)"}},children:[ce(h,{children:[de(ao,{style:{color:o?"var(--Buttons-Primary-Button)":"var(--Text)",fontWeight:o?600:400},children:t}),de(bo,{style:{color:"var(--Text)",opacity:.7},children:r})]}),o&&de(h,{sx:{width:8,height:8,borderRadius:"50%",backgroundColor:"var(--Buttons-Primary-Button)",flexShrink:0}})]},e)})})]})]})}),de(ie,{sx:{my:3,borderColor:"var(--Border)"}}),de(In,{variant:"primary-outline",size:"small",onClick:()=>{s("desktop"),t("light")},sx:{width:"100%"},children:"Reset to Defaults"})]})})]})}var wb={};export{rb as Accordion,ib as AccordionDetails,tb as AccordionGroup,nb as AccordionSummary,Wf as Alert,ou as AlertDialog,Qf as AlertShowcase,Yg as AppBar,ix as AppBarShowcase,Zl as Autocomplete,os as AutocompleteShowcase,qo as Avatar,Jo as AvatarGroup,yg as AvatarShowcase,en as Badge,Ig as BadgeShowcase,Gx as BevelText,Jx as BevelTextShowcase,Al as BlackWhiteToggleButtonGroup,co as Body,ho as Body1,mo as Body2,po as BodyBold,fo as BodyLarge,xo as BodyLargeBold,go as BodyLargeSemibold,uo as BodySemibold,ao as BodySmall,so as BodySmallBold,lo as BodySmallSemibold,jd as BottomNavigation,ec as BottomNavigationShowcase,Qs as Box,Xs as BoxShowcase,xd as BreadcrumbItem,gd as Breadcrumbs,yd as BreadcrumbsShowcase,In as Button,xa as ButtonGroup,Fo as ButtonSmall,No as ButtonText,jr as CAP_HEIGHT_TRIM,bo as Caption,vo as CaptionBold,Ma as Card,Ba as CenteredStack,Nn as Checkbox,Es as Chip,_f as CircularProgress,ng as CircularProgressShowcase,Vi as CodeBlock,qi as Colors,Ks as Container,Hi as CopyButton,sx as Copyright,Ix as CopyrightShowcase,Wx as CurvedText,Qx as CurvedTextShowcase,Go as DEFAULT_AVATAR_SRC,Tf as DEFAULT_ITEMS,Bl as DefaultToggleButtonGroup,qg as DesktopAppBar,ru as Dialog,au as DialogShowcase,Gr as DisplayLarge,Ur as DisplayMedium,Xr as DisplaySmall,Pg as Divider,xu as Drawer,bu as DrawerClose,yu as DrawerContent,vu as DrawerHeader,Pf as DrawerShowcase,Lf as DropZone,Pd as Dropdown,ya as DynoStack,Cf as DynoTreeView,Ll as EmailTextField,Pl as ErrorToggleButtonGroup,Io as Eyebrow,zo as EyebrowLarge,Ao as EyebrowMedium,To as EyebrowSmall,Ga as Fab,Za as FabShowcase,cx as Footer,wx as FooterShowcase,nu as FormDialog,wc as Gradient,qs as Grid,Aa as GridStack,Kr as H1,qr as H2,Jr as H3,Yr as H4,Zr as H5,$r as H6,Sa as HStack,ax as Header,_r as Heading,jo as Icon,fa as IconBadge,Va as IconBadgeShowcase,pa as IconShowcase,zl as InfoToggleButtonGroup,Ra as InsetStack,ko as Label,yo as LabelExtraSmall,Bo as LabelLarge,So as LabelSmall,wo as Legal,Co as LegalSemibold,Af as LightTreeView,Cc as LinearGradient,lg as LinearProgress,pg as LinearProgressShowcase,Ms as Link,Ng as List,Fg as ListItem,Dg as ListItemDecorator,Zx as MainLayout,Ld as Menu,Od as MenuButton,Wd as MenuDivider,Md as MenuItem,Vd as MenuShowcase,Ac as MeshCardGradient,Ic as MeshGradient,Jg as MobileAppBar,pu as Modal,Il as NeutralToggleButtonGroup,ul as NumberField,gl as NumberFieldShowcase,Wo as NumberLarge,Mo as NumberMedium,Lo as NumberSmall,Dl as NumberTextField,Gc as OmniDesignProvider,ya as OmniStack,Cf as OmniTreeView,Eo as Overline,Oo as OverlineLarge,Po as OverlineMedium,Ro as OverlineSmall,kd as Pagination,Id as PaginationShowcase,zc as Paper,Ml as PasswordTextField,Fl as PhoneTextField,Rc as Popover,wl as PrimaryToggleButtonGroup,Zs as RATIO_NAMES,Tc as RadialGradient,ss as Radio,ds as RadioGroup,cs as RadioInput,$a as Rail,ol as RailShowcase,fs as RangeSlider,bs as Rating,bs as RatingInput,td as Ratio,sd as RatioShowcase,Ta as ResponsiveStack,Ea as ScrollStack,ys as SearchField,Cs as SearchFieldShowcase,Wl as SearchTextField,Cl as SecondaryToggleButtonGroup,Js as Section,Ys as SectionShowcase,$n as Select,ql as SelectShowcase,Da as SelectableCard,Bb as SettingsPanel,Yx as Sidebar,ms as Slider,ms as SliderInput,Gf as Snackbar,Yf as SnackbarShowcase,If as SolidTreeView,wa as SpaceBetweenStack,Ji as Spacing,hc as SpeedDial,vc as SpeedDialShowcase,Ia as Stack,za as StackDivider,Vs as StackShowcase,ac as Step,ic as Stepper,pc as StepperShowcase,to as Subtitle,no as Subtitle1,io as Subtitle2,eo as SubtitleLarge,oo as SubtitleMedium,ro as SubtitleSmall,Rl as SuccessToggleButtonGroup,Kc as Surfaced,ra as Switch,ra as SwitchInput,li as Tab,ai as TabList,si as TabPanel,Vg as Table,ii as Tabs,md as TabsShowcase,Tl as TertiaryToggleButtonGroup,Hl as TextArea,Ol as TextField,Vl as TextFieldGroup,qn as TextInput,Xc as ThemedZone,xl as ToggleButton,kl as ToggleButtonGroup,il as Toolbar,dl as ToolbarShowcase,Ug as Tooltip,sb as TreeBranch,vb as TreeViewShowcase,Qr as Typography,Nl as URLTextField,ka as VStack,El as WarningToggleButtonGroup,Ca as WrapStack,wb as default,Uc as useOmniDesign,nc as useStepperContext,ni as useTabsContext};
42
42
  //# sourceMappingURL=index.esm.js.map