diff --git a/assets/Action-BnShWVrx.js b/assets/Action-CwOAv2fk.js similarity index 74% rename from assets/Action-BnShWVrx.js rename to assets/Action-CwOAv2fk.js index ebb9a57b..68916b86 100644 --- a/assets/Action-BnShWVrx.js +++ b/assets/Action-CwOAv2fk.js @@ -1,9 +1,9 @@ -import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{c as h}from"./index-lhGYx47h.js";import{r as i}from"./index-DRjF_FHU.js";import{C as f}from"./index-4or38LtJ.js";import{a as b}from"./Tooltip-DGTzhuPA.js";import{T as g}from"./Text-DZrEBsw6.js";const y="_container_1qov4_17",_="_control_1qov4_22",x="_action_1qov4_33",a={container:y,control:_,action:x},r=i.forwardRef(function({Icon:n,className:o,actionLabel:c,onActionClick:u,...d},p){const l=i.useId(),m=h(a.container,o);return e.jsxs("div",{className:m,id:l,children:[e.jsx(g,{ref:p,...d,className:a.control}),e.jsx(b,{label:c,children:e.jsx("button",{type:"button",className:a.action,onClick:u,"aria-controls":l,children:e.jsx(n,{"aria-hidden":!0})})})]})}),s=i.forwardRef(function(n,o){return e.jsx(f,{asChild:!0,children:e.jsx(r,{ref:o,...n})})});try{r.displayName="ActionInput",r.__docgenInfo={description:`A generic input with an action icon on the right hand side. +import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{c as h}from"./index-lhGYx47h.js";import{r as i}from"./index-DRjF_FHU.js";import{C as f}from"./index-4or38LtJ.js";import{a as b}from"./Tooltip-D2McGlOP.js";import{T as g}from"./Text-DZrEBsw6.js";const y="_container_1qov4_17",_="_control_1qov4_22",x="_action_1qov4_33",a={container:y,control:_,action:x},r=i.forwardRef(function({Icon:n,className:o,actionLabel:c,onActionClick:u,...d},p){const l=i.useId(),m=h(a.container,o);return e.jsxs("div",{className:m,id:l,children:[e.jsx(g,{ref:p,...d,className:a.control}),e.jsx(b,{label:c,children:e.jsx("button",{type:"button",className:a.action,onClick:u,"aria-controls":l,children:e.jsx(n,{"aria-hidden":!0})})})]})}),s=i.forwardRef(function(n,o){return e.jsx(f,{asChild:!0,children:e.jsx(r,{ref:o,...n})})});try{r.displayName="ActionInput",r.__docgenInfo={description:`A generic input with an action icon on the right hand side. You should rarely use it directly, -but it is powering the likes of "copy to clipboard input", "password reveal", ...`,displayName:"ActionInput",props:{Icon:{defaultValue:null,description:"The React component to display on the right hand side of the icon.",name:"Icon",required:!0,type:{name:"FunctionComponent>"}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},enableLigatures:{defaultValue:null,description:`Enable contextual alternate ligatures on input text +but it is powering the likes of "copy to clipboard input", "password reveal", ...`,displayName:"ActionInput",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},Icon:{defaultValue:null,description:"The React component to display on the right hand side of the icon.",name:"Icon",required:!0,type:{name:"FunctionComponent>"}},enableLigatures:{defaultValue:null,description:`Enable contextual alternate ligatures on input text For example on an in-place editing field https://github.com/rsms/inter/issues/222 -https://github.com/rsms/inter/blob/master/src/features/calt.fea`,name:"enableLigatures",required:!1,type:{name:"boolean"}},onActionClick:{defaultValue:null,description:"On click callback for the icon on the right hand side",name:"onActionClick",required:!0,type:{name:"(e: MouseEvent) => void"}},actionLabel:{defaultValue:null,description:'The name of the action to perform (e.g. "Copy to clipboard")',name:"actionLabel",required:!0,type:{name:"string"}}}}}catch{}try{s.displayName="ActionControl",s.__docgenInfo={description:"A styled text input wrapped in a `Control` component, for use in Radix forms.",displayName:"ActionControl",props:{Icon:{defaultValue:null,description:"The React component to display on the right hand side of the icon.",name:"Icon",required:!0,type:{name:"FunctionComponent>"}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},enableLigatures:{defaultValue:null,description:`Enable contextual alternate ligatures on input text +https://github.com/rsms/inter/blob/master/src/features/calt.fea`,name:"enableLigatures",required:!1,type:{name:"boolean"}},onActionClick:{defaultValue:null,description:"On click callback for the icon on the right hand side",name:"onActionClick",required:!0,type:{name:"(e: MouseEvent) => void"}},actionLabel:{defaultValue:null,description:'The name of the action to perform (e.g. "Copy to clipboard")',name:"actionLabel",required:!0,type:{name:"string"}}}}}catch{}try{s.displayName="ActionControl",s.__docgenInfo={description:"A styled text input wrapped in a `Control` component, for use in Radix forms.",displayName:"ActionControl",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},Icon:{defaultValue:null,description:"The React component to display on the right hand side of the icon.",name:"Icon",required:!0,type:{name:"FunctionComponent>"}},enableLigatures:{defaultValue:null,description:`Enable contextual alternate ligatures on input text For example on an in-place editing field https://github.com/rsms/inter/issues/222 https://github.com/rsms/inter/blob/master/src/features/calt.fea`,name:"enableLigatures",required:!1,type:{name:"boolean"}},onActionClick:{defaultValue:null,description:"On click callback for the icon on the right hand side",name:"onActionClick",required:!0,type:{name:"(e: MouseEvent) => void"}},actionLabel:{defaultValue:null,description:'The name of the action to perform (e.g. "Copy to clipboard")',name:"actionLabel",required:!0,type:{name:"string"}}}}}catch{}export{r as A}; diff --git a/assets/Action.stories-DTjW96ks.js b/assets/Action.stories-PfdA3Wpp.js similarity index 95% rename from assets/Action.stories-DTjW96ks.js rename to assets/Action.stories-PfdA3Wpp.js index 0d6dd652..113039c7 100644 --- a/assets/Action.stories-DTjW96ks.js +++ b/assets/Action.stories-PfdA3Wpp.js @@ -1,4 +1,4 @@ -import{j as s}from"./jsx-runtime-DR9Q75dM.js";import{i}from"./index-C87-hJvQ.js";import{T as l}from"./Tooltip-DGTzhuPA.js";import{A as p}from"./Action-BnShWVrx.js";import{C as c}from"./check-BWxs5Tf9.js";import"./index-DRjF_FHU.js";import"./notifications-BEKrtwGv.js";import"./extensions-DRIHxRsb.js";import"./check-circle-solid-DvGH8qX5.js";import"./info-D9sKA_Xt.js";import"./chevron-down-vguALCSX.js";import"./chevron-right-DND12YKW.js";import"./close-CWATPeIo.js";import"./error-DOy7ZFuJ.js";import"./search-DQyZo8im.js";import"./settings-xa_4DC6i.js";import"./spinner--mCkS-8r.js";import"./threads-CbVN7W51.js";import"./user-profile-cqTW1cHH.js";import"./visibility-on-BsZOuBEH.js";import"./warning-DNnCy5FR.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";import"./index-lhGYx47h.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./Text-DZrEBsw6.js";const B={title:"Form/Controls/Action",component:p,tags:["autodocs"],parameters:{controls:{include:["onActionClick","defaultValue","placeholder","disabled","autoFocus","readOnly","invalid","actionLabel","Icon"]}},argTypes:{onActionClick:{action:"clicked"},defaultValue:{type:"string"},placeholder:{type:"string"},disabled:{type:"boolean"},autoFocus:{type:"boolean"},readOnly:{type:"boolean"},invalid:{type:"boolean"},actionLabel:{type:"string"},Icon:{options:Object.keys(i),mapping:i,defaultValue:"check",control:{type:"select"}}},render:({invalid:d,...m})=>s.jsx(l,{children:s.jsx(p,{"data-invalid":d||void 0,...m})}),args:{placeholder:"",autoFocus:!1,disabled:!1,readOnly:!1,invalid:!1,actionLabel:"Action",Icon:c}},e={parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4477"}}},o={args:{defaultValue:"Filled"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4536"}}},a={args:{defaultValue:"Disabled",disabled:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4530"}}},n={args:{defaultValue:"Read only",readOnly:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=2126-21984"}}},r={args:{autoFocus:!0}},t={args:{defaultValue:"Invalid",invalid:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4514"}}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ +import{j as s}from"./jsx-runtime-DR9Q75dM.js";import{i}from"./index-C87-hJvQ.js";import{T as l}from"./Tooltip-D2McGlOP.js";import{A as p}from"./Action-CwOAv2fk.js";import{C as c}from"./check-BWxs5Tf9.js";import"./index-DRjF_FHU.js";import"./notifications-BEKrtwGv.js";import"./extensions-DRIHxRsb.js";import"./check-circle-solid-DvGH8qX5.js";import"./info-D9sKA_Xt.js";import"./chevron-down-vguALCSX.js";import"./chevron-right-DND12YKW.js";import"./close-CWATPeIo.js";import"./error-DOy7ZFuJ.js";import"./search-DQyZo8im.js";import"./settings-xa_4DC6i.js";import"./spinner--mCkS-8r.js";import"./threads-CbVN7W51.js";import"./user-profile-cqTW1cHH.js";import"./visibility-on-BsZOuBEH.js";import"./warning-DNnCy5FR.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";import"./index-lhGYx47h.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./Text-DZrEBsw6.js";const B={title:"Form/Controls/Action",component:p,tags:["autodocs"],parameters:{controls:{include:["onActionClick","defaultValue","placeholder","disabled","autoFocus","readOnly","invalid","actionLabel","Icon"]}},argTypes:{onActionClick:{action:"clicked"},defaultValue:{type:"string"},placeholder:{type:"string"},disabled:{type:"boolean"},autoFocus:{type:"boolean"},readOnly:{type:"boolean"},invalid:{type:"boolean"},actionLabel:{type:"string"},Icon:{options:Object.keys(i),mapping:i,defaultValue:"check",control:{type:"select"}}},render:({invalid:d,...m})=>s.jsx(l,{children:s.jsx(p,{"data-invalid":d||void 0,...m})}),args:{placeholder:"",autoFocus:!1,disabled:!1,readOnly:!1,invalid:!1,actionLabel:"Action",Icon:c}},e={parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4477"}}},o={args:{defaultValue:"Filled"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4536"}}},a={args:{defaultValue:"Disabled",disabled:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4530"}}},n={args:{defaultValue:"Read only",readOnly:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=2126-21984"}}},r={args:{autoFocus:!0}},t={args:{defaultValue:"Invalid",invalid:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4514"}}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ parameters: { design: { type: "figma", diff --git a/assets/ActionButton.stories-Dc7Ppv78.js b/assets/ActionButton.stories-D3eHjSdU.js similarity index 97% rename from assets/ActionButton.stories-Dc7Ppv78.js rename to assets/ActionButton.stories-D3eHjSdU.js index c2b596a1..094f1272 100644 --- a/assets/ActionButton.stories-Dc7Ppv78.js +++ b/assets/ActionButton.stories-D3eHjSdU.js @@ -1,4 +1,4 @@ -import{j as y}from"./jsx-runtime-DR9Q75dM.js";import{f as O}from"./index-JRK_GaCU.js";import{i as b,s as z,l as E,v as T,a as x,m as j,b as M,c as k,e as V,d as A,u as B,f as F}from"./index-C87-hJvQ.js";import{B as L}from"./Button-BORixq-h.js";import{T as _,a as D}from"./Tooltip-DGTzhuPA.js";import{S as P}from"./search-DQyZo8im.js";import{C as f}from"./check-BWxs5Tf9.js";import{C}from"./close-CWATPeIo.js";import"./index-DRjF_FHU.js";import"./notifications-BEKrtwGv.js";import"./extensions-DRIHxRsb.js";import"./check-circle-solid-DvGH8qX5.js";import"./info-D9sKA_Xt.js";import"./chevron-down-vguALCSX.js";import"./chevron-right-DND12YKW.js";import"./error-DOy7ZFuJ.js";import"./settings-xa_4DC6i.js";import"./spinner--mCkS-8r.js";import"./threads-CbVN7W51.js";import"./user-profile-cqTW1cHH.js";import"./visibility-on-BsZOuBEH.js";import"./warning-DNnCy5FR.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";const R=({label:h,...v})=>y.jsx(_,{children:y.jsx(D,{label:h,children:y.jsx(L,{iconOnly:!0,...v})})}),pe={title:"Button/Actions",component:R,tags:["autodocs"],argTypes:{label:{type:"string"},size:{options:["sm","lg"],control:{type:"inline-radio"}},kind:{options:["primary","secondary","tertiary"],control:{type:"inline-radio"}},destructive:{type:"boolean"},disabled:{type:"boolean"},as:{options:["a","button"],control:{type:"inline-radio"}},Icon:{options:Object.keys(b),mapping:b,control:{type:"select"}},onClick:{action:"onClick"}},args:{label:"Action",size:"lg",as:"button",destructive:!1,disabled:!1,onClick:O()},controls:{exclude:["children"]}},e={args:{label:"Settings",kind:"secondary",Icon:z}},r={args:{label:"Copy link",kind:"secondary",Icon:E}},n={args:{label:"Turn video off",kind:"secondary",Icon:T}},o={args:{label:"Turn video on",kind:"primary",Icon:x}},s={args:{label:"Turn mic off",kind:"secondary",Icon:j}},a={args:{label:"Turn mic on",kind:"primary",Icon:M}},c={args:{label:"Share screen",kind:"secondary",Icon:k}},i={args:{label:"Stop sharing screen",kind:"primary",Icon:k}},t={args:{label:"Full screen",kind:"secondary",Icon:V}},l={args:{label:"End call",kind:"primary",destructive:!0,Icon:A}},d={args:{label:"Invite",kind:"primary",size:"sm",Icon:B}},m={args:{label:"Edit",kind:"primary",size:"sm",Icon:F}},p={args:{label:"Search",kind:"secondary",size:"sm",Icon:P}},u={args:{label:"Save",kind:"primary",size:"sm",Icon:f}},S={args:{label:"Save",kind:"primary",size:"sm",Icon:f,disabled:!0}},g={args:{label:"Cancel",kind:"secondary",size:"sm",Icon:C}},I={args:{label:"Close",kind:"secondary",size:"sm",Icon:C}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ +import{j as y}from"./jsx-runtime-DR9Q75dM.js";import{f as O}from"./index-JRK_GaCU.js";import{i as b,s as z,l as E,v as T,a as x,m as j,b as M,c as k,e as V,d as A,u as B,f as F}from"./index-C87-hJvQ.js";import{B as L}from"./Button-BORixq-h.js";import{T as _,a as D}from"./Tooltip-D2McGlOP.js";import{S as P}from"./search-DQyZo8im.js";import{C as f}from"./check-BWxs5Tf9.js";import{C}from"./close-CWATPeIo.js";import"./index-DRjF_FHU.js";import"./notifications-BEKrtwGv.js";import"./extensions-DRIHxRsb.js";import"./check-circle-solid-DvGH8qX5.js";import"./info-D9sKA_Xt.js";import"./chevron-down-vguALCSX.js";import"./chevron-right-DND12YKW.js";import"./error-DOy7ZFuJ.js";import"./settings-xa_4DC6i.js";import"./spinner--mCkS-8r.js";import"./threads-CbVN7W51.js";import"./user-profile-cqTW1cHH.js";import"./visibility-on-BsZOuBEH.js";import"./warning-DNnCy5FR.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";const R=({label:h,...v})=>y.jsx(_,{children:y.jsx(D,{label:h,children:y.jsx(L,{iconOnly:!0,...v})})}),pe={title:"Button/Actions",component:R,tags:["autodocs"],argTypes:{label:{type:"string"},size:{options:["sm","lg"],control:{type:"inline-radio"}},kind:{options:["primary","secondary","tertiary"],control:{type:"inline-radio"}},destructive:{type:"boolean"},disabled:{type:"boolean"},as:{options:["a","button"],control:{type:"inline-radio"}},Icon:{options:Object.keys(b),mapping:b,control:{type:"select"}},onClick:{action:"onClick"}},args:{label:"Action",size:"lg",as:"button",destructive:!1,disabled:!1,onClick:O()},controls:{exclude:["children"]}},e={args:{label:"Settings",kind:"secondary",Icon:z}},r={args:{label:"Copy link",kind:"secondary",Icon:E}},n={args:{label:"Turn video off",kind:"secondary",Icon:T}},o={args:{label:"Turn video on",kind:"primary",Icon:x}},s={args:{label:"Turn mic off",kind:"secondary",Icon:j}},a={args:{label:"Turn mic on",kind:"primary",Icon:M}},c={args:{label:"Share screen",kind:"secondary",Icon:k}},i={args:{label:"Stop sharing screen",kind:"primary",Icon:k}},t={args:{label:"Full screen",kind:"secondary",Icon:V}},l={args:{label:"End call",kind:"primary",destructive:!0,Icon:A}},d={args:{label:"Invite",kind:"primary",size:"sm",Icon:B}},m={args:{label:"Edit",kind:"primary",size:"sm",Icon:F}},p={args:{label:"Search",kind:"secondary",size:"sm",Icon:P}},u={args:{label:"Save",kind:"primary",size:"sm",Icon:f}},S={args:{label:"Save",kind:"primary",size:"sm",Icon:f,disabled:!0}},g={args:{label:"Cancel",kind:"secondary",size:"sm",Icon:C}},I={args:{label:"Close",kind:"secondary",size:"sm",Icon:C}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ args: { label: "Settings", kind: "secondary", diff --git a/assets/Alert.stories-PBNjduBZ.js b/assets/Alert.stories-CZZsTik8.js similarity index 96% rename from assets/Alert.stories-PBNjduBZ.js rename to assets/Alert.stories-CZZsTik8.js index 3e0378c8..b66044b4 100644 --- a/assets/Alert.stories-PBNjduBZ.js +++ b/assets/Alert.stories-CZZsTik8.js @@ -1,4 +1,4 @@ -import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{B as u}from"./Button-BORixq-h.js";import{c as b}from"./index-lhGYx47h.js";import{r as q}from"./index-DRjF_FHU.js";import{C as v,I as C}from"./info-D9sKA_Xt.js";import{E as j}from"./error-DOy7ZFuJ.js";import{C as S}from"./close-CWATPeIo.js";import{T as p}from"./Text-BvzksikX.js";import{I as A}from"./IconButton-CBGH5UyO.js";import"./UnstyledButton-DuxpNl0e.js";import"./Typography-DzhKoIWt.js";import"./IndicatorIcon-CKMK3E77.js";import"./Tooltip-DGTzhuPA.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";const I="_alert_1bz08_19",N="_content_1bz08_46",w="_title_1bz08_57",z="_icon_1bz08_57",B="_actions_1bz08_73",t={alert:I,content:N,"text-content":"_text-content_1bz08_53",title:w,icon:z,actions:B},l=({type:o,title:g,children:h,className:f,actions:m,onClose:d,...x})=>{const y=b(t.alert,f),_=q.useCallback(c=>{switch(o){case"critical":return e.jsx(j,{...c});case"info":return e.jsx(C,{...c});case"success":return e.jsx(v,{...c})}},[o]);return e.jsxs("div",{...x,className:y,"data-type":o,children:[_({width:24,height:24,className:t.icon,"aria-hidden":!0}),e.jsxs("div",{className:t.content,children:[e.jsxs("div",{className:t["text-content"],children:[e.jsx(p,{size:"md",weight:"semibold",children:g}),e.jsx(p,{size:"sm",weight:"regular",children:h})]}),m&&e.jsx("div",{className:t.actions,children:m})]}),d&&e.jsx(A,{onClick:d,"aria-label":"Close",role:"button",className:t.close,children:e.jsx(S,{})})]})};try{l.displayName="Alert",l.__docgenInfo={description:"An alert component component that is dismissable when passing an `onClose`\nproperty.",displayName:"Alert",props:{type:{defaultValue:null,description:"The type of alert",name:"type",required:!0,type:{name:"enum",value:[{value:'"success"'},{value:'"critical"'},{value:'"info"'}]}},title:{defaultValue:null,description:"The headline of the alert.",name:"title",required:!0,type:{name:"string"}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},actions:{defaultValue:null,description:`Actions that will be displayed to the right of the content +import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{B as u}from"./Button-BORixq-h.js";import{c as b}from"./index-lhGYx47h.js";import{r as q}from"./index-DRjF_FHU.js";import{C as v,I as C}from"./info-D9sKA_Xt.js";import{E as j}from"./error-DOy7ZFuJ.js";import{C as S}from"./close-CWATPeIo.js";import{T as p}from"./Text-BvzksikX.js";import{I as A}from"./IconButton-Bf1MsgYV.js";import"./UnstyledButton-DuxpNl0e.js";import"./Typography-DzhKoIWt.js";import"./IndicatorIcon-CKMK3E77.js";import"./Tooltip-D2McGlOP.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";const I="_alert_1bz08_19",N="_content_1bz08_46",w="_title_1bz08_57",z="_icon_1bz08_57",B="_actions_1bz08_73",t={alert:I,content:N,"text-content":"_text-content_1bz08_53",title:w,icon:z,actions:B},l=({type:o,title:g,children:h,className:f,actions:m,onClose:d,...x})=>{const y=b(t.alert,f),_=q.useCallback(c=>{switch(o){case"critical":return e.jsx(j,{...c});case"info":return e.jsx(C,{...c});case"success":return e.jsx(v,{...c})}},[o]);return e.jsxs("div",{...x,className:y,"data-type":o,children:[_({width:24,height:24,className:t.icon,"aria-hidden":!0}),e.jsxs("div",{className:t.content,children:[e.jsxs("div",{className:t["text-content"],children:[e.jsx(p,{size:"md",weight:"semibold",children:g}),e.jsx(p,{size:"sm",weight:"regular",children:h})]}),m&&e.jsx("div",{className:t.actions,children:m})]}),d&&e.jsx(A,{onClick:d,"aria-label":"Close",role:"button",className:t.close,children:e.jsx(S,{})})]})};try{l.displayName="Alert",l.__docgenInfo={description:"An alert component component that is dismissable when passing an `onClose`\nproperty.",displayName:"Alert",props:{type:{defaultValue:null,description:"The type of alert",name:"type",required:!0,type:{name:"enum",value:[{value:'"success"'},{value:'"critical"'},{value:'"info"'}]}},title:{defaultValue:null,description:"The headline of the alert.",name:"title",required:!0,type:{name:"string"}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},actions:{defaultValue:null,description:`Actions that will be displayed to the right of the content Wraps and stacks actions under content when alert's size is <=600px eg \`\`\` diff --git a/assets/Color-F6OSRLHC-CsBEHEVI.js b/assets/Color-F6OSRLHC-D-JbNhmq.js similarity index 99% rename from assets/Color-F6OSRLHC-CsBEHEVI.js rename to assets/Color-F6OSRLHC-D-JbNhmq.js index acbb58ab..0ba704c5 100644 --- a/assets/Color-F6OSRLHC-CsBEHEVI.js +++ b/assets/Color-F6OSRLHC-D-JbNhmq.js @@ -1 +1 @@ -import{ae as ce,af as E,a2 as Y,a0 as he,N as fe,ag as de,ah as ge,ai as be,aj as H}from"./DocsRenderer-CFRXHY34-xrdFE-63.js";import{R as m,r as p}from"./index-DRjF_FHU.js";import"./iframe-80GKSfNA.js";import"../sb-preview/runtime.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-BvEl7W6R.js";import"./index-D-8MO0q_.js";import"./index-CidnEmUr.js";import"./index-DrFu-skq.js";import"./react-18-BZ4hdgop.js";var me=H({"../../node_modules/color-name/index.js"(n,l){l.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}}}),J=H({"../../node_modules/color-convert/conversions.js"(n,l){var c=me(),h={};for(let e of Object.keys(c))h[c[e]]=e;var i={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};l.exports=i;for(let e of Object.keys(i)){if(!("channels"in i[e]))throw new Error("missing channels property: "+e);if(!("labels"in i[e]))throw new Error("missing channel labels property: "+e);if(i[e].labels.length!==i[e].channels)throw new Error("channel and label counts mismatch: "+e);let{channels:t,labels:r}=i[e];delete i[e].channels,delete i[e].labels,Object.defineProperty(i[e],"channels",{value:t}),Object.defineProperty(i[e],"labels",{value:r})}i.rgb.hsl=function(e){let t=e[0]/255,r=e[1]/255,a=e[2]/255,o=Math.min(t,r,a),u=Math.max(t,r,a),s=u-o,f,g;u===o?f=0:t===u?f=(r-a)/s:r===u?f=2+(a-t)/s:a===u&&(f=4+(t-r)/s),f=Math.min(f*60,360),f<0&&(f+=360);let b=(o+u)/2;return u===o?g=0:b<=.5?g=s/(u+o):g=s/(2-u-o),[f,g*100,b*100]},i.rgb.hsv=function(e){let t,r,a,o,u,s=e[0]/255,f=e[1]/255,g=e[2]/255,b=Math.max(s,f,g),y=b-Math.min(s,f,g),v=function(k){return(b-k)/6/y+1/2};return y===0?(o=0,u=0):(u=y/b,t=v(s),r=v(f),a=v(g),s===b?o=a-r:f===b?o=1/3+t-a:g===b&&(o=2/3+r-t),o<0?o+=1:o>1&&(o-=1)),[o*360,u*100,b*100]},i.rgb.hwb=function(e){let t=e[0],r=e[1],a=e[2],o=i.rgb.hsl(e)[0],u=1/255*Math.min(t,Math.min(r,a));return a=1-1/255*Math.max(t,Math.max(r,a)),[o,u*100,a*100]},i.rgb.cmyk=function(e){let t=e[0]/255,r=e[1]/255,a=e[2]/255,o=Math.min(1-t,1-r,1-a),u=(1-t-o)/(1-o)||0,s=(1-r-o)/(1-o)||0,f=(1-a-o)/(1-o)||0;return[u*100,s*100,f*100,o*100]};function d(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}i.rgb.keyword=function(e){let t=h[e];if(t)return t;let r=1/0,a;for(let o of Object.keys(c)){let u=c[o],s=d(e,u);s.04045?((t+.055)/1.055)**2.4:t/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92,a=a>.04045?((a+.055)/1.055)**2.4:a/12.92;let o=t*.4124+r*.3576+a*.1805,u=t*.2126+r*.7152+a*.0722,s=t*.0193+r*.1192+a*.9505;return[o*100,u*100,s*100]},i.rgb.lab=function(e){let t=i.rgb.xyz(e),r=t[0],a=t[1],o=t[2];r/=95.047,a/=100,o/=108.883,r=r>.008856?r**(1/3):7.787*r+16/116,a=a>.008856?a**(1/3):7.787*a+16/116,o=o>.008856?o**(1/3):7.787*o+16/116;let u=116*a-16,s=500*(r-a),f=200*(a-o);return[u,s,f]},i.hsl.rgb=function(e){let t=e[0]/360,r=e[1]/100,a=e[2]/100,o,u,s;if(r===0)return s=a*255,[s,s,s];a<.5?o=a*(1+r):o=a+r-a*r;let f=2*a-o,g=[0,0,0];for(let b=0;b<3;b++)u=t+1/3*-(b-1),u<0&&u++,u>1&&u--,6*u<1?s=f+(o-f)*6*u:2*u<1?s=o:3*u<2?s=f+(o-f)*(2/3-u)*6:s=f,g[b]=s*255;return g},i.hsl.hsv=function(e){let t=e[0],r=e[1]/100,a=e[2]/100,o=r,u=Math.max(a,.01);a*=2,r*=a<=1?a:2-a,o*=u<=1?u:2-u;let s=(a+r)/2,f=a===0?2*o/(u+o):2*r/(a+r);return[t,f*100,s*100]},i.hsv.rgb=function(e){let t=e[0]/60,r=e[1]/100,a=e[2]/100,o=Math.floor(t)%6,u=t-Math.floor(t),s=255*a*(1-r),f=255*a*(1-r*u),g=255*a*(1-r*(1-u));switch(a*=255,o){case 0:return[a,g,s];case 1:return[f,a,s];case 2:return[s,a,g];case 3:return[s,f,a];case 4:return[g,s,a];case 5:return[a,s,f]}},i.hsv.hsl=function(e){let t=e[0],r=e[1]/100,a=e[2]/100,o=Math.max(a,.01),u,s;s=(2-r)*a;let f=(2-r)*o;return u=r*o,u/=f<=1?f:2-f,u=u||0,s/=2,[t,u*100,s*100]},i.hwb.rgb=function(e){let t=e[0]/360,r=e[1]/100,a=e[2]/100,o=r+a,u;o>1&&(r/=o,a/=o);let s=Math.floor(6*t),f=1-a;u=6*t-s,s&1&&(u=1-u);let g=r+u*(f-r),b,y,v;switch(s){default:case 6:case 0:b=f,y=g,v=r;break;case 1:b=g,y=f,v=r;break;case 2:b=r,y=f,v=g;break;case 3:b=r,y=g,v=f;break;case 4:b=g,y=r,v=f;break;case 5:b=f,y=r,v=g;break}return[b*255,y*255,v*255]},i.cmyk.rgb=function(e){let t=e[0]/100,r=e[1]/100,a=e[2]/100,o=e[3]/100,u=1-Math.min(1,t*(1-o)+o),s=1-Math.min(1,r*(1-o)+o),f=1-Math.min(1,a*(1-o)+o);return[u*255,s*255,f*255]},i.xyz.rgb=function(e){let t=e[0]/100,r=e[1]/100,a=e[2]/100,o,u,s;return o=t*3.2406+r*-1.5372+a*-.4986,u=t*-.9689+r*1.8758+a*.0415,s=t*.0557+r*-.204+a*1.057,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,u=u>.0031308?1.055*u**(1/2.4)-.055:u*12.92,s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92,o=Math.min(Math.max(0,o),1),u=Math.min(Math.max(0,u),1),s=Math.min(Math.max(0,s),1),[o*255,u*255,s*255]},i.xyz.lab=function(e){let t=e[0],r=e[1],a=e[2];t/=95.047,r/=100,a/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,a=a>.008856?a**(1/3):7.787*a+16/116;let o=116*r-16,u=500*(t-r),s=200*(r-a);return[o,u,s]},i.lab.xyz=function(e){let t=e[0],r=e[1],a=e[2],o,u,s;u=(t+16)/116,o=r/500+u,s=u-a/200;let f=u**3,g=o**3,b=s**3;return u=f>.008856?f:(u-16/116)/7.787,o=g>.008856?g:(o-16/116)/7.787,s=b>.008856?b:(s-16/116)/7.787,o*=95.047,u*=100,s*=108.883,[o,u,s]},i.lab.lch=function(e){let t=e[0],r=e[1],a=e[2],o;o=Math.atan2(a,r)*360/2/Math.PI,o<0&&(o+=360);let u=Math.sqrt(r*r+a*a);return[t,u,o]},i.lch.lab=function(e){let t=e[0],r=e[1],a=e[2]/360*2*Math.PI,o=r*Math.cos(a),u=r*Math.sin(a);return[t,o,u]},i.rgb.ansi16=function(e,t=null){let[r,a,o]=e,u=t===null?i.rgb.hsv(e)[2]:t;if(u=Math.round(u/50),u===0)return 30;let s=30+(Math.round(o/255)<<2|Math.round(a/255)<<1|Math.round(r/255));return u===2&&(s+=60),s},i.hsv.ansi16=function(e){return i.rgb.ansi16(i.hsv.rgb(e),e[2])},i.rgb.ansi256=function(e){let t=e[0],r=e[1],a=e[2];return t===r&&r===a?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(a/255*5)},i.ansi16.rgb=function(e){let t=e%10;if(t===0||t===7)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];let r=(~~(e>50)+1)*.5,a=(t&1)*r*255,o=(t>>1&1)*r*255,u=(t>>2&1)*r*255;return[a,o,u]},i.ansi256.rgb=function(e){if(e>=232){let u=(e-232)*10+8;return[u,u,u]}e-=16;let t,r=Math.floor(e/36)/5*255,a=Math.floor((t=e%36)/6)/5*255,o=t%6/5*255;return[r,a,o]},i.rgb.hex=function(e){let t=(((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255)).toString(16).toUpperCase();return"000000".substring(t.length)+t},i.hex.rgb=function(e){let t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let r=t[0];t[0].length===3&&(r=r.split("").map(f=>f+f).join(""));let a=parseInt(r,16),o=a>>16&255,u=a>>8&255,s=a&255;return[o,u,s]},i.rgb.hcg=function(e){let t=e[0]/255,r=e[1]/255,a=e[2]/255,o=Math.max(Math.max(t,r),a),u=Math.min(Math.min(t,r),a),s=o-u,f,g;return s<1?f=u/(1-s):f=0,s<=0?g=0:o===t?g=(r-a)/s%6:o===r?g=2+(a-t)/s:g=4+(t-r)/s,g/=6,g%=1,[g*360,s*100,f*100]},i.hsl.hcg=function(e){let t=e[1]/100,r=e[2]/100,a=r<.5?2*t*r:2*t*(1-r),o=0;return a<1&&(o=(r-.5*a)/(1-a)),[e[0],a*100,o*100]},i.hsv.hcg=function(e){let t=e[1]/100,r=e[2]/100,a=t*r,o=0;return a<1&&(o=(r-a)/(1-a)),[e[0],a*100,o*100]},i.hcg.rgb=function(e){let t=e[0]/360,r=e[1]/100,a=e[2]/100;if(r===0)return[a*255,a*255,a*255];let o=[0,0,0],u=t%1*6,s=u%1,f=1-s,g=0;switch(Math.floor(u)){case 0:o[0]=1,o[1]=s,o[2]=0;break;case 1:o[0]=f,o[1]=1,o[2]=0;break;case 2:o[0]=0,o[1]=1,o[2]=s;break;case 3:o[0]=0,o[1]=f,o[2]=1;break;case 4:o[0]=s,o[1]=0,o[2]=1;break;default:o[0]=1,o[1]=0,o[2]=f}return g=(1-r)*a,[(r*o[0]+g)*255,(r*o[1]+g)*255,(r*o[2]+g)*255]},i.hcg.hsv=function(e){let t=e[1]/100,r=e[2]/100,a=t+r*(1-t),o=0;return a>0&&(o=t/a),[e[0],o*100,a*100]},i.hcg.hsl=function(e){let t=e[1]/100,r=e[2]/100*(1-t)+.5*t,a=0;return r>0&&r<.5?a=t/(2*r):r>=.5&&r<1&&(a=t/(2*(1-r))),[e[0],a*100,r*100]},i.hcg.hwb=function(e){let t=e[1]/100,r=e[2]/100,a=t+r*(1-t);return[e[0],(a-t)*100,(1-a)*100]},i.hwb.hcg=function(e){let t=e[1]/100,r=1-e[2]/100,a=r-t,o=0;return a<1&&(o=(r-a)/(1-a)),[e[0],a*100,o*100]},i.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},i.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},i.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},i.gray.hsl=function(e){return[0,0,e[0]]},i.gray.hsv=i.gray.hsl,i.gray.hwb=function(e){return[0,100,e[0]]},i.gray.cmyk=function(e){return[0,0,0,e[0]]},i.gray.lab=function(e){return[e[0],0,0]},i.gray.hex=function(e){let t=Math.round(e[0]/100*255)&255,r=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(r.length)+r},i.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}}}),ve=H({"../../node_modules/color-convert/route.js"(n,l){var c=J();function h(){let t={},r=Object.keys(c);for(let a=r.length,o=0;o1&&(o=u),r(o))};return"conversion"in r&&(a.conversion=r.conversion),a}function t(r){let a=function(...o){let u=o[0];if(u==null)return u;u.length>1&&(o=u);let s=r(o);if(typeof s=="object")for(let f=s.length,g=0;g{i[r]={},Object.defineProperty(i[r],"channels",{value:c[r].channels}),Object.defineProperty(i[r],"labels",{value:c[r].labels});let a=h(r);Object.keys(a).forEach(o=>{let u=a[o];i[r][o]=t(u),i[r][o].raw=e(u)})}),l.exports=i}}),_=ce(pe());function M(){return(M=Object.assign||function(n){for(var l=1;l=0||(i[c]=n[c]);return i}function P(n){var l=p.useRef(n),c=p.useRef(function(h){l.current&&l.current(h)});return l.current=n,c.current}var $=function(n,l,c){return l===void 0&&(l=0),c===void 0&&(c=1),n>c?c:n0:y.buttons>0)&&i.current?d(G(i.current,y,t.current)):b(!1)},g=function(){return b(!1)};function b(y){var v=r.current,k=L(i.current),w=y?k.addEventListener:k.removeEventListener;w(v?"touchmove":"mousemove",f),w(v?"touchend":"mouseup",g)}return[function(y){var v=y.nativeEvent,k=i.current;if(k&&(F(v),!function(q,se){return se&&!N(q)}(v,r.current)&&k)){if(N(v)){r.current=!0;var w=v.changedTouches||[];w.length&&(t.current=w[0].identifier)}k.focus(),d(G(k,v,t.current)),b(!0)}},function(y){var v=y.which||y.keyCode;v<37||v>40||(y.preventDefault(),e({left:v===39?.05:v===37?-.05:0,top:v===40?.05:v===38?-.05:0}))},b]},[e,d]),o=a[0],u=a[1],s=a[2];return p.useEffect(function(){return s},[s]),m.createElement("div",M({},h,{onTouchStart:o,onMouseDown:o,className:"react-colorful__interactive",ref:i,onKeyDown:u,tabIndex:0,role:"slider"}))}),O=function(n){return n.filter(Boolean).join(" ")},V=function(n){var l=n.color,c=n.left,h=n.top,i=h===void 0?.5:h,d=O(["react-colorful__pointer",n.className]);return m.createElement("div",{className:d,style:{top:100*i+"%",left:100*c+"%"}},m.createElement("div",{className:"react-colorful__pointer-fill",style:{backgroundColor:l}}))},x=function(n,l,c){return l===void 0&&(l=0),c===void 0&&(c=Math.pow(10,l)),Math.round(c*n)/c},ye={grad:.9,turn:360,rad:360/(2*Math.PI)},xe=function(n){return ee(B(n))},B=function(n){return n[0]==="#"&&(n=n.substring(1)),n.length<6?{r:parseInt(n[0]+n[0],16),g:parseInt(n[1]+n[1],16),b:parseInt(n[2]+n[2],16),a:n.length===4?x(parseInt(n[3]+n[3],16)/255,2):1}:{r:parseInt(n.substring(0,2),16),g:parseInt(n.substring(2,4),16),b:parseInt(n.substring(4,6),16),a:n.length===8?x(parseInt(n.substring(6,8),16)/255,2):1}},we=function(n,l){return l===void 0&&(l="deg"),Number(n)*(ye[l]||1)},ke=function(n){var l=/hsla?\(?\s*(-?\d*\.?\d+)(deg|rad|grad|turn)?[,\s]+(-?\d*\.?\d+)%?[,\s]+(-?\d*\.?\d+)%?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i.exec(n);return l?_e({h:we(l[1],l[2]),s:Number(l[3]),l:Number(l[4]),a:l[5]===void 0?1:Number(l[5])/(l[6]?100:1)}):{h:0,s:0,v:0,a:1}},_e=function(n){var l=n.s,c=n.l;return{h:n.h,s:(l*=(c<50?c:100-c)/100)>0?2*l/(c+l)*100:0,v:c+l,a:n.a}},Ee=function(n){return Ce(Z(n))},Q=function(n){var l=n.s,c=n.v,h=n.a,i=(200-l)*c/100;return{h:x(n.h),s:x(i>0&&i<200?l*c/100/(i<=100?i:200-i)*100:0),l:x(i/2),a:x(h,2)}},T=function(n){var l=Q(n);return"hsl("+l.h+", "+l.s+"%, "+l.l+"%)"},z=function(n){var l=Q(n);return"hsla("+l.h+", "+l.s+"%, "+l.l+"%, "+l.a+")"},Z=function(n){var l=n.h,c=n.s,h=n.v,i=n.a;l=l/360*6,c/=100,h/=100;var d=Math.floor(l),e=h*(1-c),t=h*(1-(l-d)*c),r=h*(1-(1-l+d)*c),a=d%6;return{r:x(255*[h,t,e,e,r,h][a]),g:x(255*[r,h,h,t,e,e][a]),b:x(255*[e,e,r,h,h,t][a]),a:x(i,2)}},Me=function(n){var l=/rgba?\(?\s*(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i.exec(n);return l?ee({r:Number(l[1])/(l[2]?100/255:1),g:Number(l[3])/(l[4]?100/255:1),b:Number(l[5])/(l[6]?100/255:1),a:l[7]===void 0?1:Number(l[7])/(l[8]?100:1)}):{h:0,s:0,v:0,a:1}},S=function(n){var l=n.toString(16);return l.length<2?"0"+l:l},Ce=function(n){var l=n.r,c=n.g,h=n.b,i=n.a,d=i<1?S(x(255*i)):"";return"#"+S(l)+S(c)+S(h)+d},ee=function(n){var l=n.r,c=n.g,h=n.b,i=n.a,d=Math.max(l,c,h),e=d-Math.min(l,c,h),t=e?d===l?(c-h)/e:d===c?2+(h-l)/e:4+(l-c)/e:0;return{h:x(60*(t<0?t+6:t)),s:x(d?e/d*100:0),v:x(d/255*100),a:i}},re=m.memo(function(n){var l=n.hue,c=n.onChange,h=O(["react-colorful__hue",n.className]);return m.createElement("div",{className:h},m.createElement(D,{onMove:function(i){c({h:360*i.left})},onKey:function(i){c({h:$(l+360*i.left,0,360)})},"aria-label":"Hue","aria-valuenow":x(l),"aria-valuemax":"360","aria-valuemin":"0"},m.createElement(V,{className:"react-colorful__hue-pointer",left:l/360,color:T({h:l,s:100,v:100,a:1})})))}),te=m.memo(function(n){var l=n.hsva,c=n.onChange,h={backgroundColor:T({h:l.h,s:100,v:100,a:1})};return m.createElement("div",{className:"react-colorful__saturation",style:h},m.createElement(D,{onMove:function(i){c({s:100*i.left,v:100-100*i.top})},onKey:function(i){c({s:$(l.s+100*i.left,0,100),v:$(l.v-100*i.top,0,100)})},"aria-label":"Color","aria-valuetext":"Saturation "+x(l.s)+"%, Brightness "+x(l.v)+"%"},m.createElement(V,{className:"react-colorful__saturation-pointer",top:1-l.v/100,left:l.s/100,color:T(l)})))}),ne=function(n,l){if(n===l)return!0;for(var c in n)if(n[c]!==l[c])return!1;return!0},ae=function(n,l){return n.replace(/\s/g,"")===l.replace(/\s/g,"")},$e=function(n,l){return n.toLowerCase()===l.toLowerCase()||ne(B(n),B(l))};function oe(n,l,c){var h=P(c),i=p.useState(function(){return n.toHsva(l)}),d=i[0],e=i[1],t=p.useRef({color:l,hsva:d});p.useEffect(function(){if(!n.equal(l,t.current.color)){var a=n.toHsva(l);t.current={hsva:a,color:l},e(a)}},[l,n]),p.useEffect(function(){var a;ne(d,t.current.hsva)||n.equal(a=n.fromHsva(d),t.current.color)||(t.current={hsva:d,color:a},h(a))},[d,n,h]);var r=p.useCallback(function(a){e(function(o){return Object.assign({},o,a)})},[]);return[d,r]}var Ne=typeof window<"u"?p.useLayoutEffect:p.useEffect,Oe=function(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:void 0},W=new Map,le=function(n){Ne(function(){var l=n.current?n.current.ownerDocument:document;if(l!==void 0&&!W.has(l)){var c=l.createElement("style");c.innerHTML=`.react-colorful{position:relative;display:flex;flex-direction:column;width:200px;height:200px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.react-colorful__saturation{position:relative;flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.react-colorful__alpha-gradient,.react-colorful__pointer-fill{content:"";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;border-radius:inherit}.react-colorful__alpha-gradient,.react-colorful__saturation{box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}.react-colorful__alpha,.react-colorful__hue{position:relative;height:24px}.react-colorful__hue{background:linear-gradient(90deg,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red)}.react-colorful__last-control{border-radius:0 0 8px 8px}.react-colorful__interactive{position:absolute;left:0;top:0;right:0;bottom:0;border-radius:inherit;outline:none;touch-action:none}.react-colorful__pointer{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}.react-colorful__interactive:focus .react-colorful__pointer{transform:translate(-50%,-50%) scale(1.1)}.react-colorful__alpha,.react-colorful__alpha-pointer{background-color:#fff;background-image:url('data:image/svg+xml;charset=utf-8,')}.react-colorful__saturation-pointer{z-index:3}.react-colorful__hue-pointer{z-index:2}`,W.set(l,c);var h=Oe();h&&c.setAttribute("nonce",h),l.head.appendChild(c)}},[])},Se=function(n){var l=n.className,c=n.colorModel,h=n.color,i=h===void 0?c.defaultColor:h,d=n.onChange,e=X(n,["className","colorModel","color","onChange"]),t=p.useRef(null);le(t);var r=oe(c,i,d),a=r[0],o=r[1],u=O(["react-colorful",l]);return m.createElement("div",M({},e,{ref:t,className:u}),m.createElement(te,{hsva:a,onChange:o}),m.createElement(re,{hue:a.h,onChange:o,className:"react-colorful__last-control"}))},je={defaultColor:"000",toHsva:xe,fromHsva:function(n){return Ee({h:n.h,s:n.s,v:n.v,a:1})},equal:$e},Re=function(n){return m.createElement(Se,M({},n,{colorModel:je}))},ze=function(n){var l=n.className,c=n.hsva,h=n.onChange,i={backgroundImage:"linear-gradient(90deg, "+z(Object.assign({},c,{a:0}))+", "+z(Object.assign({},c,{a:1}))+")"},d=O(["react-colorful__alpha",l]),e=x(100*c.a);return m.createElement("div",{className:d},m.createElement("div",{className:"react-colorful__alpha-gradient",style:i}),m.createElement(D,{onMove:function(t){h({a:t.left})},onKey:function(t){h({a:$(c.a+t.left)})},"aria-label":"Alpha","aria-valuetext":e+"%","aria-valuenow":e,"aria-valuemin":"0","aria-valuemax":"100"},m.createElement(V,{className:"react-colorful__alpha-pointer",left:c.a,color:z(c)})))},ue=function(n){var l=n.className,c=n.colorModel,h=n.color,i=h===void 0?c.defaultColor:h,d=n.onChange,e=X(n,["className","colorModel","color","onChange"]),t=p.useRef(null);le(t);var r=oe(c,i,d),a=r[0],o=r[1],u=O(["react-colorful",l]);return m.createElement("div",M({},e,{ref:t,className:u}),m.createElement(te,{hsva:a,onChange:o}),m.createElement(re,{hue:a.h,onChange:o}),m.createElement(ze,{hsva:a,onChange:o,className:"react-colorful__last-control"}))},Ie={defaultColor:"hsla(0, 0%, 0%, 1)",toHsva:ke,fromHsva:z,equal:ae},He=function(n){return m.createElement(ue,M({},n,{colorModel:Ie}))},qe={defaultColor:"rgba(0, 0, 0, 1)",toHsva:Me,fromHsva:function(n){var l=Z(n);return"rgba("+l.r+", "+l.g+", "+l.b+", "+l.a+")"},equal:ae},Pe=function(n){return m.createElement(ue,M({},n,{colorModel:qe}))},Le=E.div({position:"relative",maxWidth:250,'&[aria-readonly="true"]':{opacity:.5}}),Be=E(Y)({position:"absolute",zIndex:1,top:4,left:4,"[aria-readonly=true] &":{cursor:"not-allowed"}}),Te=E.div({width:200,margin:5,".react-colorful__saturation":{borderRadius:"4px 4px 0 0"},".react-colorful__hue":{boxShadow:"inset 0 0 0 1px rgb(0 0 0 / 5%)"},".react-colorful__last-control":{borderRadius:"0 0 4px 4px"}}),Ke=E(he)(({theme:n})=>({fontFamily:n.typography.fonts.base})),Xe=E.div({display:"grid",gridTemplateColumns:"repeat(9, 16px)",gap:6,padding:3,marginTop:5,width:200}),De=E.div(({theme:n,active:l})=>({width:16,height:16,boxShadow:l?`${n.appBorderColor} 0 0 0 1px inset, ${n.textMutedColor}50 0 0 0 4px`:`${n.appBorderColor} 0 0 0 1px inset`,borderRadius:n.appBorderRadius})),Ve=`url('data:image/svg+xml;charset=utf-8,')`,A=({value:n,style:l,...c})=>{let h=`linear-gradient(${n}, ${n}), ${Ve}, linear-gradient(#fff, #fff)`;return m.createElement(De,{...c,style:{...l,backgroundImage:h}})},Ge=E(fe.Input)(({theme:n,readOnly:l})=>({width:"100%",paddingLeft:30,paddingRight:30,boxSizing:"border-box",fontFamily:n.typography.fonts.base})),Fe=E(de)(({theme:n})=>({position:"absolute",zIndex:1,top:6,right:7,width:20,height:20,padding:4,boxSizing:"border-box",cursor:"pointer",color:n.input.color})),ie=(n=>(n.RGB="rgb",n.HSL="hsl",n.HEX="hex",n))(ie||{}),j=Object.values(ie),We=/\(([0-9]+),\s*([0-9]+)%?,\s*([0-9]+)%?,?\s*([0-9.]+)?\)/,Ae=/^\s*rgba?\(([0-9]+),\s*([0-9]+),\s*([0-9]+),?\s*([0-9.]+)?\)\s*$/i,Ue=/^\s*hsla?\(([0-9]+),\s*([0-9]+)%,\s*([0-9]+)%,?\s*([0-9.]+)?\)\s*$/i,K=/^\s*#?([0-9a-f]{3}|[0-9a-f]{6})\s*$/i,Ye=/^\s*#?([0-9a-f]{3})\s*$/i,Je={hex:Re,rgb:Pe,hsl:He},R={hex:"transparent",rgb:"rgba(0, 0, 0, 0)",hsl:"hsla(0, 0%, 0%, 0)"},U=n=>{let l=n?.match(We);if(!l)return[0,0,0,1];let[,c,h,i,d=1]=l;return[c,h,i,d].map(Number)},C=n=>{if(!n)return;let l=!0;if(Ae.test(n)){let[e,t,r,a]=U(n),[o,u,s]=_.default.rgb.hsl([e,t,r])||[0,0,0];return{valid:l,value:n,keyword:_.default.rgb.keyword([e,t,r]),colorSpace:"rgb",rgb:n,hsl:`hsla(${o}, ${u}%, ${s}%, ${a})`,hex:`#${_.default.rgb.hex([e,t,r]).toLowerCase()}`}}if(Ue.test(n)){let[e,t,r,a]=U(n),[o,u,s]=_.default.hsl.rgb([e,t,r])||[0,0,0];return{valid:l,value:n,keyword:_.default.hsl.keyword([e,t,r]),colorSpace:"hsl",rgb:`rgba(${o}, ${u}, ${s}, ${a})`,hsl:n,hex:`#${_.default.hsl.hex([e,t,r]).toLowerCase()}`}}let c=n.replace("#",""),h=_.default.keyword.rgb(c)||_.default.hex.rgb(c),i=_.default.rgb.hsl(h),d=n;if(/[^#a-f0-9]/i.test(n)?d=c:K.test(n)&&(d=`#${c}`),d.startsWith("#"))l=K.test(d);else try{_.default.keyword.hex(d)}catch{l=!1}return{valid:l,value:d,keyword:_.default.rgb.keyword(h),colorSpace:"hex",rgb:`rgba(${h[0]}, ${h[1]}, ${h[2]}, 1)`,hsl:`hsla(${i[0]}, ${i[1]}%, ${i[2]}%, 1)`,hex:d}},Qe=(n,l,c)=>{if(!n||!l?.valid)return R[c];if(c!=="hex")return l?.[c]||R[c];if(!l.hex.startsWith("#"))try{return`#${_.default.keyword.hex(l.hex)}`}catch{return R.hex}let h=l.hex.match(Ye);if(!h)return K.test(l.hex)?l.hex:R.hex;let[i,d,e]=h[1].split("");return`#${i}${i}${d}${d}${e}${e}`},Ze=(n,l)=>{let[c,h]=p.useState(n||""),[i,d]=p.useState(()=>C(c)),[e,t]=p.useState(i?.colorSpace||"hex");p.useEffect(()=>{let u=n||"",s=C(u);h(u),d(s),t(s?.colorSpace||"hex")},[n]);let r=p.useMemo(()=>Qe(c,i,e).toLowerCase(),[c,i,e]),a=p.useCallback(u=>{let s=C(u),f=s?.value||u||"";h(f),f===""&&(d(void 0),l(void 0)),s&&(d(s),t(s.colorSpace),l(s.value))},[l]),o=p.useCallback(()=>{let u=j.indexOf(e)+1;u>=j.length&&(u=0),t(j[u]);let s=i?.[j[u]]||"";h(s),l(s)},[i,e,l]);return{value:c,realValue:r,updateValue:a,color:i,colorSpace:e,cycleColorSpace:o}},I=n=>n.replace(/\s*/,"").toLowerCase(),er=(n,l,c)=>{let[h,i]=p.useState(l?.valid?[l]:[]);p.useEffect(()=>{l===void 0&&i([])},[l]);let d=p.useMemo(()=>(n||[]).map(t=>typeof t=="string"?C(t):t.title?{...C(t.color),keyword:t.title}:C(t.color)).concat(h).filter(Boolean).slice(-27),[n,h]),e=p.useCallback(t=>{t?.valid&&(d.some(r=>I(r[c])===I(t[c]))||i(r=>r.concat(t)))},[c,d]);return{presets:d,addPreset:e}},rr=({name:n,value:l,onChange:c,onFocus:h,onBlur:i,presetColors:d,startOpen:e=!1,argType:t})=>{let r=p.useCallback(ge(c,200),[c]),{value:a,realValue:o,updateValue:u,color:s,colorSpace:f,cycleColorSpace:g}=Ze(l,r),{presets:b,addPreset:y}=er(d,s,f),v=Je[f],k=!!t?.table?.readonly;return m.createElement(Le,{"aria-readonly":k},m.createElement(Be,{startOpen:e,trigger:k?[null]:void 0,closeOnOutsideClick:!0,onVisibleChange:()=>y(s),tooltip:m.createElement(Te,null,m.createElement(v,{color:o==="transparent"?"#000000":o,onChange:u,onFocus:h,onBlur:i}),b.length>0&&m.createElement(Xe,null,b.map((w,q)=>m.createElement(Y,{key:`${w.value}-${q}`,hasChrome:!1,tooltip:m.createElement(Ke,{note:w.keyword||w.value})},m.createElement(A,{value:w[f],active:s&&I(w[f])===I(s[f]),onClick:()=>u(w.value)})))))},m.createElement(A,{value:o,style:{margin:4}})),m.createElement(Ge,{id:be(n),value:a,onChange:w=>u(w.target.value),onFocus:w=>w.target.select(),readOnly:k,placeholder:"Choose color..."}),a?m.createElement(Fe,{onClick:g}):null)},fr=rr;export{rr as ColorControl,fr as default}; +import{ae as ce,af as E,a2 as Y,a0 as he,N as fe,ag as de,ah as ge,ai as be,aj as H}from"./DocsRenderer-CFRXHY34-DG86K5OV.js";import{R as m,r as p}from"./index-DRjF_FHU.js";import"./iframe-DWIAQds9.js";import"../sb-preview/runtime.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-BvEl7W6R.js";import"./index-D-8MO0q_.js";import"./index-CidnEmUr.js";import"./index-DrFu-skq.js";import"./react-18-BZ4hdgop.js";var me=H({"../../node_modules/color-name/index.js"(n,l){l.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}}}),J=H({"../../node_modules/color-convert/conversions.js"(n,l){var c=me(),h={};for(let e of Object.keys(c))h[c[e]]=e;var i={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};l.exports=i;for(let e of Object.keys(i)){if(!("channels"in i[e]))throw new Error("missing channels property: "+e);if(!("labels"in i[e]))throw new Error("missing channel labels property: "+e);if(i[e].labels.length!==i[e].channels)throw new Error("channel and label counts mismatch: "+e);let{channels:t,labels:r}=i[e];delete i[e].channels,delete i[e].labels,Object.defineProperty(i[e],"channels",{value:t}),Object.defineProperty(i[e],"labels",{value:r})}i.rgb.hsl=function(e){let t=e[0]/255,r=e[1]/255,a=e[2]/255,o=Math.min(t,r,a),u=Math.max(t,r,a),s=u-o,f,g;u===o?f=0:t===u?f=(r-a)/s:r===u?f=2+(a-t)/s:a===u&&(f=4+(t-r)/s),f=Math.min(f*60,360),f<0&&(f+=360);let b=(o+u)/2;return u===o?g=0:b<=.5?g=s/(u+o):g=s/(2-u-o),[f,g*100,b*100]},i.rgb.hsv=function(e){let t,r,a,o,u,s=e[0]/255,f=e[1]/255,g=e[2]/255,b=Math.max(s,f,g),y=b-Math.min(s,f,g),v=function(k){return(b-k)/6/y+1/2};return y===0?(o=0,u=0):(u=y/b,t=v(s),r=v(f),a=v(g),s===b?o=a-r:f===b?o=1/3+t-a:g===b&&(o=2/3+r-t),o<0?o+=1:o>1&&(o-=1)),[o*360,u*100,b*100]},i.rgb.hwb=function(e){let t=e[0],r=e[1],a=e[2],o=i.rgb.hsl(e)[0],u=1/255*Math.min(t,Math.min(r,a));return a=1-1/255*Math.max(t,Math.max(r,a)),[o,u*100,a*100]},i.rgb.cmyk=function(e){let t=e[0]/255,r=e[1]/255,a=e[2]/255,o=Math.min(1-t,1-r,1-a),u=(1-t-o)/(1-o)||0,s=(1-r-o)/(1-o)||0,f=(1-a-o)/(1-o)||0;return[u*100,s*100,f*100,o*100]};function d(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}i.rgb.keyword=function(e){let t=h[e];if(t)return t;let r=1/0,a;for(let o of Object.keys(c)){let u=c[o],s=d(e,u);s.04045?((t+.055)/1.055)**2.4:t/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92,a=a>.04045?((a+.055)/1.055)**2.4:a/12.92;let o=t*.4124+r*.3576+a*.1805,u=t*.2126+r*.7152+a*.0722,s=t*.0193+r*.1192+a*.9505;return[o*100,u*100,s*100]},i.rgb.lab=function(e){let t=i.rgb.xyz(e),r=t[0],a=t[1],o=t[2];r/=95.047,a/=100,o/=108.883,r=r>.008856?r**(1/3):7.787*r+16/116,a=a>.008856?a**(1/3):7.787*a+16/116,o=o>.008856?o**(1/3):7.787*o+16/116;let u=116*a-16,s=500*(r-a),f=200*(a-o);return[u,s,f]},i.hsl.rgb=function(e){let t=e[0]/360,r=e[1]/100,a=e[2]/100,o,u,s;if(r===0)return s=a*255,[s,s,s];a<.5?o=a*(1+r):o=a+r-a*r;let f=2*a-o,g=[0,0,0];for(let b=0;b<3;b++)u=t+1/3*-(b-1),u<0&&u++,u>1&&u--,6*u<1?s=f+(o-f)*6*u:2*u<1?s=o:3*u<2?s=f+(o-f)*(2/3-u)*6:s=f,g[b]=s*255;return g},i.hsl.hsv=function(e){let t=e[0],r=e[1]/100,a=e[2]/100,o=r,u=Math.max(a,.01);a*=2,r*=a<=1?a:2-a,o*=u<=1?u:2-u;let s=(a+r)/2,f=a===0?2*o/(u+o):2*r/(a+r);return[t,f*100,s*100]},i.hsv.rgb=function(e){let t=e[0]/60,r=e[1]/100,a=e[2]/100,o=Math.floor(t)%6,u=t-Math.floor(t),s=255*a*(1-r),f=255*a*(1-r*u),g=255*a*(1-r*(1-u));switch(a*=255,o){case 0:return[a,g,s];case 1:return[f,a,s];case 2:return[s,a,g];case 3:return[s,f,a];case 4:return[g,s,a];case 5:return[a,s,f]}},i.hsv.hsl=function(e){let t=e[0],r=e[1]/100,a=e[2]/100,o=Math.max(a,.01),u,s;s=(2-r)*a;let f=(2-r)*o;return u=r*o,u/=f<=1?f:2-f,u=u||0,s/=2,[t,u*100,s*100]},i.hwb.rgb=function(e){let t=e[0]/360,r=e[1]/100,a=e[2]/100,o=r+a,u;o>1&&(r/=o,a/=o);let s=Math.floor(6*t),f=1-a;u=6*t-s,s&1&&(u=1-u);let g=r+u*(f-r),b,y,v;switch(s){default:case 6:case 0:b=f,y=g,v=r;break;case 1:b=g,y=f,v=r;break;case 2:b=r,y=f,v=g;break;case 3:b=r,y=g,v=f;break;case 4:b=g,y=r,v=f;break;case 5:b=f,y=r,v=g;break}return[b*255,y*255,v*255]},i.cmyk.rgb=function(e){let t=e[0]/100,r=e[1]/100,a=e[2]/100,o=e[3]/100,u=1-Math.min(1,t*(1-o)+o),s=1-Math.min(1,r*(1-o)+o),f=1-Math.min(1,a*(1-o)+o);return[u*255,s*255,f*255]},i.xyz.rgb=function(e){let t=e[0]/100,r=e[1]/100,a=e[2]/100,o,u,s;return o=t*3.2406+r*-1.5372+a*-.4986,u=t*-.9689+r*1.8758+a*.0415,s=t*.0557+r*-.204+a*1.057,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,u=u>.0031308?1.055*u**(1/2.4)-.055:u*12.92,s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92,o=Math.min(Math.max(0,o),1),u=Math.min(Math.max(0,u),1),s=Math.min(Math.max(0,s),1),[o*255,u*255,s*255]},i.xyz.lab=function(e){let t=e[0],r=e[1],a=e[2];t/=95.047,r/=100,a/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,a=a>.008856?a**(1/3):7.787*a+16/116;let o=116*r-16,u=500*(t-r),s=200*(r-a);return[o,u,s]},i.lab.xyz=function(e){let t=e[0],r=e[1],a=e[2],o,u,s;u=(t+16)/116,o=r/500+u,s=u-a/200;let f=u**3,g=o**3,b=s**3;return u=f>.008856?f:(u-16/116)/7.787,o=g>.008856?g:(o-16/116)/7.787,s=b>.008856?b:(s-16/116)/7.787,o*=95.047,u*=100,s*=108.883,[o,u,s]},i.lab.lch=function(e){let t=e[0],r=e[1],a=e[2],o;o=Math.atan2(a,r)*360/2/Math.PI,o<0&&(o+=360);let u=Math.sqrt(r*r+a*a);return[t,u,o]},i.lch.lab=function(e){let t=e[0],r=e[1],a=e[2]/360*2*Math.PI,o=r*Math.cos(a),u=r*Math.sin(a);return[t,o,u]},i.rgb.ansi16=function(e,t=null){let[r,a,o]=e,u=t===null?i.rgb.hsv(e)[2]:t;if(u=Math.round(u/50),u===0)return 30;let s=30+(Math.round(o/255)<<2|Math.round(a/255)<<1|Math.round(r/255));return u===2&&(s+=60),s},i.hsv.ansi16=function(e){return i.rgb.ansi16(i.hsv.rgb(e),e[2])},i.rgb.ansi256=function(e){let t=e[0],r=e[1],a=e[2];return t===r&&r===a?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(r/255*5)+Math.round(a/255*5)},i.ansi16.rgb=function(e){let t=e%10;if(t===0||t===7)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];let r=(~~(e>50)+1)*.5,a=(t&1)*r*255,o=(t>>1&1)*r*255,u=(t>>2&1)*r*255;return[a,o,u]},i.ansi256.rgb=function(e){if(e>=232){let u=(e-232)*10+8;return[u,u,u]}e-=16;let t,r=Math.floor(e/36)/5*255,a=Math.floor((t=e%36)/6)/5*255,o=t%6/5*255;return[r,a,o]},i.rgb.hex=function(e){let t=(((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255)).toString(16).toUpperCase();return"000000".substring(t.length)+t},i.hex.rgb=function(e){let t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let r=t[0];t[0].length===3&&(r=r.split("").map(f=>f+f).join(""));let a=parseInt(r,16),o=a>>16&255,u=a>>8&255,s=a&255;return[o,u,s]},i.rgb.hcg=function(e){let t=e[0]/255,r=e[1]/255,a=e[2]/255,o=Math.max(Math.max(t,r),a),u=Math.min(Math.min(t,r),a),s=o-u,f,g;return s<1?f=u/(1-s):f=0,s<=0?g=0:o===t?g=(r-a)/s%6:o===r?g=2+(a-t)/s:g=4+(t-r)/s,g/=6,g%=1,[g*360,s*100,f*100]},i.hsl.hcg=function(e){let t=e[1]/100,r=e[2]/100,a=r<.5?2*t*r:2*t*(1-r),o=0;return a<1&&(o=(r-.5*a)/(1-a)),[e[0],a*100,o*100]},i.hsv.hcg=function(e){let t=e[1]/100,r=e[2]/100,a=t*r,o=0;return a<1&&(o=(r-a)/(1-a)),[e[0],a*100,o*100]},i.hcg.rgb=function(e){let t=e[0]/360,r=e[1]/100,a=e[2]/100;if(r===0)return[a*255,a*255,a*255];let o=[0,0,0],u=t%1*6,s=u%1,f=1-s,g=0;switch(Math.floor(u)){case 0:o[0]=1,o[1]=s,o[2]=0;break;case 1:o[0]=f,o[1]=1,o[2]=0;break;case 2:o[0]=0,o[1]=1,o[2]=s;break;case 3:o[0]=0,o[1]=f,o[2]=1;break;case 4:o[0]=s,o[1]=0,o[2]=1;break;default:o[0]=1,o[1]=0,o[2]=f}return g=(1-r)*a,[(r*o[0]+g)*255,(r*o[1]+g)*255,(r*o[2]+g)*255]},i.hcg.hsv=function(e){let t=e[1]/100,r=e[2]/100,a=t+r*(1-t),o=0;return a>0&&(o=t/a),[e[0],o*100,a*100]},i.hcg.hsl=function(e){let t=e[1]/100,r=e[2]/100*(1-t)+.5*t,a=0;return r>0&&r<.5?a=t/(2*r):r>=.5&&r<1&&(a=t/(2*(1-r))),[e[0],a*100,r*100]},i.hcg.hwb=function(e){let t=e[1]/100,r=e[2]/100,a=t+r*(1-t);return[e[0],(a-t)*100,(1-a)*100]},i.hwb.hcg=function(e){let t=e[1]/100,r=1-e[2]/100,a=r-t,o=0;return a<1&&(o=(r-a)/(1-a)),[e[0],a*100,o*100]},i.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},i.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},i.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},i.gray.hsl=function(e){return[0,0,e[0]]},i.gray.hsv=i.gray.hsl,i.gray.hwb=function(e){return[0,100,e[0]]},i.gray.cmyk=function(e){return[0,0,0,e[0]]},i.gray.lab=function(e){return[e[0],0,0]},i.gray.hex=function(e){let t=Math.round(e[0]/100*255)&255,r=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(r.length)+r},i.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]}}}),ve=H({"../../node_modules/color-convert/route.js"(n,l){var c=J();function h(){let t={},r=Object.keys(c);for(let a=r.length,o=0;o1&&(o=u),r(o))};return"conversion"in r&&(a.conversion=r.conversion),a}function t(r){let a=function(...o){let u=o[0];if(u==null)return u;u.length>1&&(o=u);let s=r(o);if(typeof s=="object")for(let f=s.length,g=0;g{i[r]={},Object.defineProperty(i[r],"channels",{value:c[r].channels}),Object.defineProperty(i[r],"labels",{value:c[r].labels});let a=h(r);Object.keys(a).forEach(o=>{let u=a[o];i[r][o]=t(u),i[r][o].raw=e(u)})}),l.exports=i}}),_=ce(pe());function M(){return(M=Object.assign||function(n){for(var l=1;l=0||(i[c]=n[c]);return i}function P(n){var l=p.useRef(n),c=p.useRef(function(h){l.current&&l.current(h)});return l.current=n,c.current}var $=function(n,l,c){return l===void 0&&(l=0),c===void 0&&(c=1),n>c?c:n0:y.buttons>0)&&i.current?d(G(i.current,y,t.current)):b(!1)},g=function(){return b(!1)};function b(y){var v=r.current,k=L(i.current),w=y?k.addEventListener:k.removeEventListener;w(v?"touchmove":"mousemove",f),w(v?"touchend":"mouseup",g)}return[function(y){var v=y.nativeEvent,k=i.current;if(k&&(F(v),!function(q,se){return se&&!N(q)}(v,r.current)&&k)){if(N(v)){r.current=!0;var w=v.changedTouches||[];w.length&&(t.current=w[0].identifier)}k.focus(),d(G(k,v,t.current)),b(!0)}},function(y){var v=y.which||y.keyCode;v<37||v>40||(y.preventDefault(),e({left:v===39?.05:v===37?-.05:0,top:v===40?.05:v===38?-.05:0}))},b]},[e,d]),o=a[0],u=a[1],s=a[2];return p.useEffect(function(){return s},[s]),m.createElement("div",M({},h,{onTouchStart:o,onMouseDown:o,className:"react-colorful__interactive",ref:i,onKeyDown:u,tabIndex:0,role:"slider"}))}),O=function(n){return n.filter(Boolean).join(" ")},V=function(n){var l=n.color,c=n.left,h=n.top,i=h===void 0?.5:h,d=O(["react-colorful__pointer",n.className]);return m.createElement("div",{className:d,style:{top:100*i+"%",left:100*c+"%"}},m.createElement("div",{className:"react-colorful__pointer-fill",style:{backgroundColor:l}}))},x=function(n,l,c){return l===void 0&&(l=0),c===void 0&&(c=Math.pow(10,l)),Math.round(c*n)/c},ye={grad:.9,turn:360,rad:360/(2*Math.PI)},xe=function(n){return ee(B(n))},B=function(n){return n[0]==="#"&&(n=n.substring(1)),n.length<6?{r:parseInt(n[0]+n[0],16),g:parseInt(n[1]+n[1],16),b:parseInt(n[2]+n[2],16),a:n.length===4?x(parseInt(n[3]+n[3],16)/255,2):1}:{r:parseInt(n.substring(0,2),16),g:parseInt(n.substring(2,4),16),b:parseInt(n.substring(4,6),16),a:n.length===8?x(parseInt(n.substring(6,8),16)/255,2):1}},we=function(n,l){return l===void 0&&(l="deg"),Number(n)*(ye[l]||1)},ke=function(n){var l=/hsla?\(?\s*(-?\d*\.?\d+)(deg|rad|grad|turn)?[,\s]+(-?\d*\.?\d+)%?[,\s]+(-?\d*\.?\d+)%?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i.exec(n);return l?_e({h:we(l[1],l[2]),s:Number(l[3]),l:Number(l[4]),a:l[5]===void 0?1:Number(l[5])/(l[6]?100:1)}):{h:0,s:0,v:0,a:1}},_e=function(n){var l=n.s,c=n.l;return{h:n.h,s:(l*=(c<50?c:100-c)/100)>0?2*l/(c+l)*100:0,v:c+l,a:n.a}},Ee=function(n){return Ce(Z(n))},Q=function(n){var l=n.s,c=n.v,h=n.a,i=(200-l)*c/100;return{h:x(n.h),s:x(i>0&&i<200?l*c/100/(i<=100?i:200-i)*100:0),l:x(i/2),a:x(h,2)}},T=function(n){var l=Q(n);return"hsl("+l.h+", "+l.s+"%, "+l.l+"%)"},z=function(n){var l=Q(n);return"hsla("+l.h+", "+l.s+"%, "+l.l+"%, "+l.a+")"},Z=function(n){var l=n.h,c=n.s,h=n.v,i=n.a;l=l/360*6,c/=100,h/=100;var d=Math.floor(l),e=h*(1-c),t=h*(1-(l-d)*c),r=h*(1-(1-l+d)*c),a=d%6;return{r:x(255*[h,t,e,e,r,h][a]),g:x(255*[r,h,h,t,e,e][a]),b:x(255*[e,e,r,h,h,t][a]),a:x(i,2)}},Me=function(n){var l=/rgba?\(?\s*(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i.exec(n);return l?ee({r:Number(l[1])/(l[2]?100/255:1),g:Number(l[3])/(l[4]?100/255:1),b:Number(l[5])/(l[6]?100/255:1),a:l[7]===void 0?1:Number(l[7])/(l[8]?100:1)}):{h:0,s:0,v:0,a:1}},S=function(n){var l=n.toString(16);return l.length<2?"0"+l:l},Ce=function(n){var l=n.r,c=n.g,h=n.b,i=n.a,d=i<1?S(x(255*i)):"";return"#"+S(l)+S(c)+S(h)+d},ee=function(n){var l=n.r,c=n.g,h=n.b,i=n.a,d=Math.max(l,c,h),e=d-Math.min(l,c,h),t=e?d===l?(c-h)/e:d===c?2+(h-l)/e:4+(l-c)/e:0;return{h:x(60*(t<0?t+6:t)),s:x(d?e/d*100:0),v:x(d/255*100),a:i}},re=m.memo(function(n){var l=n.hue,c=n.onChange,h=O(["react-colorful__hue",n.className]);return m.createElement("div",{className:h},m.createElement(D,{onMove:function(i){c({h:360*i.left})},onKey:function(i){c({h:$(l+360*i.left,0,360)})},"aria-label":"Hue","aria-valuenow":x(l),"aria-valuemax":"360","aria-valuemin":"0"},m.createElement(V,{className:"react-colorful__hue-pointer",left:l/360,color:T({h:l,s:100,v:100,a:1})})))}),te=m.memo(function(n){var l=n.hsva,c=n.onChange,h={backgroundColor:T({h:l.h,s:100,v:100,a:1})};return m.createElement("div",{className:"react-colorful__saturation",style:h},m.createElement(D,{onMove:function(i){c({s:100*i.left,v:100-100*i.top})},onKey:function(i){c({s:$(l.s+100*i.left,0,100),v:$(l.v-100*i.top,0,100)})},"aria-label":"Color","aria-valuetext":"Saturation "+x(l.s)+"%, Brightness "+x(l.v)+"%"},m.createElement(V,{className:"react-colorful__saturation-pointer",top:1-l.v/100,left:l.s/100,color:T(l)})))}),ne=function(n,l){if(n===l)return!0;for(var c in n)if(n[c]!==l[c])return!1;return!0},ae=function(n,l){return n.replace(/\s/g,"")===l.replace(/\s/g,"")},$e=function(n,l){return n.toLowerCase()===l.toLowerCase()||ne(B(n),B(l))};function oe(n,l,c){var h=P(c),i=p.useState(function(){return n.toHsva(l)}),d=i[0],e=i[1],t=p.useRef({color:l,hsva:d});p.useEffect(function(){if(!n.equal(l,t.current.color)){var a=n.toHsva(l);t.current={hsva:a,color:l},e(a)}},[l,n]),p.useEffect(function(){var a;ne(d,t.current.hsva)||n.equal(a=n.fromHsva(d),t.current.color)||(t.current={hsva:d,color:a},h(a))},[d,n,h]);var r=p.useCallback(function(a){e(function(o){return Object.assign({},o,a)})},[]);return[d,r]}var Ne=typeof window<"u"?p.useLayoutEffect:p.useEffect,Oe=function(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:void 0},W=new Map,le=function(n){Ne(function(){var l=n.current?n.current.ownerDocument:document;if(l!==void 0&&!W.has(l)){var c=l.createElement("style");c.innerHTML=`.react-colorful{position:relative;display:flex;flex-direction:column;width:200px;height:200px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.react-colorful__saturation{position:relative;flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.react-colorful__alpha-gradient,.react-colorful__pointer-fill{content:"";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;border-radius:inherit}.react-colorful__alpha-gradient,.react-colorful__saturation{box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}.react-colorful__alpha,.react-colorful__hue{position:relative;height:24px}.react-colorful__hue{background:linear-gradient(90deg,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red)}.react-colorful__last-control{border-radius:0 0 8px 8px}.react-colorful__interactive{position:absolute;left:0;top:0;right:0;bottom:0;border-radius:inherit;outline:none;touch-action:none}.react-colorful__pointer{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}.react-colorful__interactive:focus .react-colorful__pointer{transform:translate(-50%,-50%) scale(1.1)}.react-colorful__alpha,.react-colorful__alpha-pointer{background-color:#fff;background-image:url('data:image/svg+xml;charset=utf-8,')}.react-colorful__saturation-pointer{z-index:3}.react-colorful__hue-pointer{z-index:2}`,W.set(l,c);var h=Oe();h&&c.setAttribute("nonce",h),l.head.appendChild(c)}},[])},Se=function(n){var l=n.className,c=n.colorModel,h=n.color,i=h===void 0?c.defaultColor:h,d=n.onChange,e=X(n,["className","colorModel","color","onChange"]),t=p.useRef(null);le(t);var r=oe(c,i,d),a=r[0],o=r[1],u=O(["react-colorful",l]);return m.createElement("div",M({},e,{ref:t,className:u}),m.createElement(te,{hsva:a,onChange:o}),m.createElement(re,{hue:a.h,onChange:o,className:"react-colorful__last-control"}))},je={defaultColor:"000",toHsva:xe,fromHsva:function(n){return Ee({h:n.h,s:n.s,v:n.v,a:1})},equal:$e},Re=function(n){return m.createElement(Se,M({},n,{colorModel:je}))},ze=function(n){var l=n.className,c=n.hsva,h=n.onChange,i={backgroundImage:"linear-gradient(90deg, "+z(Object.assign({},c,{a:0}))+", "+z(Object.assign({},c,{a:1}))+")"},d=O(["react-colorful__alpha",l]),e=x(100*c.a);return m.createElement("div",{className:d},m.createElement("div",{className:"react-colorful__alpha-gradient",style:i}),m.createElement(D,{onMove:function(t){h({a:t.left})},onKey:function(t){h({a:$(c.a+t.left)})},"aria-label":"Alpha","aria-valuetext":e+"%","aria-valuenow":e,"aria-valuemin":"0","aria-valuemax":"100"},m.createElement(V,{className:"react-colorful__alpha-pointer",left:c.a,color:z(c)})))},ue=function(n){var l=n.className,c=n.colorModel,h=n.color,i=h===void 0?c.defaultColor:h,d=n.onChange,e=X(n,["className","colorModel","color","onChange"]),t=p.useRef(null);le(t);var r=oe(c,i,d),a=r[0],o=r[1],u=O(["react-colorful",l]);return m.createElement("div",M({},e,{ref:t,className:u}),m.createElement(te,{hsva:a,onChange:o}),m.createElement(re,{hue:a.h,onChange:o}),m.createElement(ze,{hsva:a,onChange:o,className:"react-colorful__last-control"}))},Ie={defaultColor:"hsla(0, 0%, 0%, 1)",toHsva:ke,fromHsva:z,equal:ae},He=function(n){return m.createElement(ue,M({},n,{colorModel:Ie}))},qe={defaultColor:"rgba(0, 0, 0, 1)",toHsva:Me,fromHsva:function(n){var l=Z(n);return"rgba("+l.r+", "+l.g+", "+l.b+", "+l.a+")"},equal:ae},Pe=function(n){return m.createElement(ue,M({},n,{colorModel:qe}))},Le=E.div({position:"relative",maxWidth:250,'&[aria-readonly="true"]':{opacity:.5}}),Be=E(Y)({position:"absolute",zIndex:1,top:4,left:4,"[aria-readonly=true] &":{cursor:"not-allowed"}}),Te=E.div({width:200,margin:5,".react-colorful__saturation":{borderRadius:"4px 4px 0 0"},".react-colorful__hue":{boxShadow:"inset 0 0 0 1px rgb(0 0 0 / 5%)"},".react-colorful__last-control":{borderRadius:"0 0 4px 4px"}}),Ke=E(he)(({theme:n})=>({fontFamily:n.typography.fonts.base})),Xe=E.div({display:"grid",gridTemplateColumns:"repeat(9, 16px)",gap:6,padding:3,marginTop:5,width:200}),De=E.div(({theme:n,active:l})=>({width:16,height:16,boxShadow:l?`${n.appBorderColor} 0 0 0 1px inset, ${n.textMutedColor}50 0 0 0 4px`:`${n.appBorderColor} 0 0 0 1px inset`,borderRadius:n.appBorderRadius})),Ve=`url('data:image/svg+xml;charset=utf-8,')`,A=({value:n,style:l,...c})=>{let h=`linear-gradient(${n}, ${n}), ${Ve}, linear-gradient(#fff, #fff)`;return m.createElement(De,{...c,style:{...l,backgroundImage:h}})},Ge=E(fe.Input)(({theme:n,readOnly:l})=>({width:"100%",paddingLeft:30,paddingRight:30,boxSizing:"border-box",fontFamily:n.typography.fonts.base})),Fe=E(de)(({theme:n})=>({position:"absolute",zIndex:1,top:6,right:7,width:20,height:20,padding:4,boxSizing:"border-box",cursor:"pointer",color:n.input.color})),ie=(n=>(n.RGB="rgb",n.HSL="hsl",n.HEX="hex",n))(ie||{}),j=Object.values(ie),We=/\(([0-9]+),\s*([0-9]+)%?,\s*([0-9]+)%?,?\s*([0-9.]+)?\)/,Ae=/^\s*rgba?\(([0-9]+),\s*([0-9]+),\s*([0-9]+),?\s*([0-9.]+)?\)\s*$/i,Ue=/^\s*hsla?\(([0-9]+),\s*([0-9]+)%,\s*([0-9]+)%,?\s*([0-9.]+)?\)\s*$/i,K=/^\s*#?([0-9a-f]{3}|[0-9a-f]{6})\s*$/i,Ye=/^\s*#?([0-9a-f]{3})\s*$/i,Je={hex:Re,rgb:Pe,hsl:He},R={hex:"transparent",rgb:"rgba(0, 0, 0, 0)",hsl:"hsla(0, 0%, 0%, 0)"},U=n=>{let l=n?.match(We);if(!l)return[0,0,0,1];let[,c,h,i,d=1]=l;return[c,h,i,d].map(Number)},C=n=>{if(!n)return;let l=!0;if(Ae.test(n)){let[e,t,r,a]=U(n),[o,u,s]=_.default.rgb.hsl([e,t,r])||[0,0,0];return{valid:l,value:n,keyword:_.default.rgb.keyword([e,t,r]),colorSpace:"rgb",rgb:n,hsl:`hsla(${o}, ${u}%, ${s}%, ${a})`,hex:`#${_.default.rgb.hex([e,t,r]).toLowerCase()}`}}if(Ue.test(n)){let[e,t,r,a]=U(n),[o,u,s]=_.default.hsl.rgb([e,t,r])||[0,0,0];return{valid:l,value:n,keyword:_.default.hsl.keyword([e,t,r]),colorSpace:"hsl",rgb:`rgba(${o}, ${u}, ${s}, ${a})`,hsl:n,hex:`#${_.default.hsl.hex([e,t,r]).toLowerCase()}`}}let c=n.replace("#",""),h=_.default.keyword.rgb(c)||_.default.hex.rgb(c),i=_.default.rgb.hsl(h),d=n;if(/[^#a-f0-9]/i.test(n)?d=c:K.test(n)&&(d=`#${c}`),d.startsWith("#"))l=K.test(d);else try{_.default.keyword.hex(d)}catch{l=!1}return{valid:l,value:d,keyword:_.default.rgb.keyword(h),colorSpace:"hex",rgb:`rgba(${h[0]}, ${h[1]}, ${h[2]}, 1)`,hsl:`hsla(${i[0]}, ${i[1]}%, ${i[2]}%, 1)`,hex:d}},Qe=(n,l,c)=>{if(!n||!l?.valid)return R[c];if(c!=="hex")return l?.[c]||R[c];if(!l.hex.startsWith("#"))try{return`#${_.default.keyword.hex(l.hex)}`}catch{return R.hex}let h=l.hex.match(Ye);if(!h)return K.test(l.hex)?l.hex:R.hex;let[i,d,e]=h[1].split("");return`#${i}${i}${d}${d}${e}${e}`},Ze=(n,l)=>{let[c,h]=p.useState(n||""),[i,d]=p.useState(()=>C(c)),[e,t]=p.useState(i?.colorSpace||"hex");p.useEffect(()=>{let u=n||"",s=C(u);h(u),d(s),t(s?.colorSpace||"hex")},[n]);let r=p.useMemo(()=>Qe(c,i,e).toLowerCase(),[c,i,e]),a=p.useCallback(u=>{let s=C(u),f=s?.value||u||"";h(f),f===""&&(d(void 0),l(void 0)),s&&(d(s),t(s.colorSpace),l(s.value))},[l]),o=p.useCallback(()=>{let u=j.indexOf(e)+1;u>=j.length&&(u=0),t(j[u]);let s=i?.[j[u]]||"";h(s),l(s)},[i,e,l]);return{value:c,realValue:r,updateValue:a,color:i,colorSpace:e,cycleColorSpace:o}},I=n=>n.replace(/\s*/,"").toLowerCase(),er=(n,l,c)=>{let[h,i]=p.useState(l?.valid?[l]:[]);p.useEffect(()=>{l===void 0&&i([])},[l]);let d=p.useMemo(()=>(n||[]).map(t=>typeof t=="string"?C(t):t.title?{...C(t.color),keyword:t.title}:C(t.color)).concat(h).filter(Boolean).slice(-27),[n,h]),e=p.useCallback(t=>{t?.valid&&(d.some(r=>I(r[c])===I(t[c]))||i(r=>r.concat(t)))},[c,d]);return{presets:d,addPreset:e}},rr=({name:n,value:l,onChange:c,onFocus:h,onBlur:i,presetColors:d,startOpen:e=!1,argType:t})=>{let r=p.useCallback(ge(c,200),[c]),{value:a,realValue:o,updateValue:u,color:s,colorSpace:f,cycleColorSpace:g}=Ze(l,r),{presets:b,addPreset:y}=er(d,s,f),v=Je[f],k=!!t?.table?.readonly;return m.createElement(Le,{"aria-readonly":k},m.createElement(Be,{startOpen:e,trigger:k?[null]:void 0,closeOnOutsideClick:!0,onVisibleChange:()=>y(s),tooltip:m.createElement(Te,null,m.createElement(v,{color:o==="transparent"?"#000000":o,onChange:u,onFocus:h,onBlur:i}),b.length>0&&m.createElement(Xe,null,b.map((w,q)=>m.createElement(Y,{key:`${w.value}-${q}`,hasChrome:!1,tooltip:m.createElement(Ke,{note:w.keyword||w.value})},m.createElement(A,{value:w[f],active:s&&I(w[f])===I(s[f]),onClick:()=>u(w.value)})))))},m.createElement(A,{value:o,style:{margin:4}})),m.createElement(Ge,{id:be(n),value:a,onChange:w=>u(w.target.value),onFocus:w=>w.target.select(),readOnly:k,placeholder:"Choose color..."}),a?m.createElement(Fe,{onClick:g}):null)},fr=rr;export{rr as ColorControl,fr as default}; diff --git a/assets/ContextMenu.stories-C6bRKAQB.js b/assets/ContextMenu.stories-CxHKJP9E.js similarity index 97% rename from assets/ContextMenu.stories-C6bRKAQB.js rename to assets/ContextMenu.stories-CxHKJP9E.js index a4bb8c39..bf22873e 100644 --- a/assets/ContextMenu.stories-C6bRKAQB.js +++ b/assets/ContextMenu.stories-CxHKJP9E.js @@ -1,4 +1,4 @@ -import{j as o}from"./jsx-runtime-DR9Q75dM.js";import{U as D}from"./user-profile-cqTW1cHH.js";import{N as U,C as L,L as $}from"./notifications-BEKrtwGv.js";import{r as s}from"./index-DRjF_FHU.js";import{c as g}from"./index-CGa_gRws.js";import{P as F}from"./index-Ksfxd92j.js";import{c as R,A as z,C as B,G as q,L as V,I as W,a as H,R as X,b as K,d as Y,S as J,e as Q,f as Z,g as ee,u as te,h as ne,P as oe,D as v}from"./index-JSxJwvkz.js";import{F as re}from"./FloatingMenu-Dc89G4Nf.js";import{c as ae}from"./index-lhGYx47h.js";import{d as se,D as ie,g as ce}from"./DrawerMenu-BNILBemh.js";import{a as ue,M as b}from"./MenuItem-BFo5ba9w.js";import{S as le}from"./Separator-B6sIYtjz.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./floating-ui.react-CACRriTf.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";function de(e,t=[]){let r=[];function n(l,c){const i=s.createContext(c),p=r.length;r=[...r,c];const f=x=>{const{scope:m,children:C,...h}=x,k=m?.[e]?.[p]||i,G=s.useMemo(()=>h,Object.values(h));return o.jsx(k.Provider,{value:G,children:C})};f.displayName=l+"Provider";function u(x,m){const C=m?.[e]?.[p]||i,h=s.useContext(C);if(h)return h;if(c!==void 0)return c;throw new Error(`\`${x}\` must be used within \`${l}\``)}return[f,u]}const a=()=>{const l=r.map(c=>s.createContext(c));return function(i){const p=i?.[e]||l;return s.useMemo(()=>({[`__scope${e}`]:{...i,[e]:p}}),[i,p])}};return a.scopeName=e,[n,pe(a,...t)]}function pe(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(a=>({useScope:a(),scopeName:a.scopeName}));return function(l){const c=n.reduce((i,{useScope:p,scopeName:f})=>{const x=p(l)[`__scope${f}`];return{...i,...x}},{});return s.useMemo(()=>({[`__scope${t.scopeName}`]:c}),[c])}};return r.scopeName=t.scopeName,r}var I="ContextMenu",[xe,it]=de(I,[R]),d=R(),[me,y]=xe(I),N=e=>{const{__scopeContextMenu:t,children:r,onOpenChange:n,dir:a,modal:l=!0}=e,[c,i]=s.useState(!1),p=d(t),f=te(n),u=s.useCallback(x=>{i(x),f(x)},[f]);return o.jsx(me,{scope:t,open:c,onOpenChange:u,modal:l,children:o.jsx(ne,{...p,dir:a,open:c,onOpenChange:u,modal:l,children:r})})};N.displayName=I;var w="ContextMenuTrigger",j=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,disabled:n=!1,...a}=e,l=y(w,r),c=d(r),i=s.useRef({x:0,y:0}),p=s.useRef({getBoundingClientRect:()=>DOMRect.fromRect({width:0,height:0,...i.current})}),f=s.useRef(0),u=s.useCallback(()=>window.clearTimeout(f.current),[]),x=m=>{i.current={x:m.clientX,y:m.clientY},l.onOpenChange(!0)};return s.useEffect(()=>u,[u]),s.useEffect(()=>void(n&&u()),[n,u]),o.jsxs(o.Fragment,{children:[o.jsx(z,{...c,virtualRef:p}),o.jsx(F.span,{"data-state":l.open?"open":"closed","data-disabled":n?"":void 0,...a,ref:t,style:{WebkitTouchCallout:"none",...e.style},onContextMenu:n?e.onContextMenu:g(e.onContextMenu,m=>{u(),x(m),m.preventDefault()}),onPointerDown:n?e.onPointerDown:g(e.onPointerDown,_(m=>{u(),f.current=window.setTimeout(()=>x(m),700)})),onPointerMove:n?e.onPointerMove:g(e.onPointerMove,_(u)),onPointerCancel:n?e.onPointerCancel:g(e.onPointerCancel,_(u)),onPointerUp:n?e.onPointerUp:g(e.onPointerUp,_(u))})]})});j.displayName=w;var fe="ContextMenuPortal",A=e=>{const{__scopeContextMenu:t,...r}=e,n=d(t);return o.jsx(oe,{...n,...r})};A.displayName=fe;var E="ContextMenuContent",O=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=y(E,r),l=d(r),c=s.useRef(!1);return o.jsx(B,{...l,...n,ref:t,side:"right",sideOffset:2,align:"start",onCloseAutoFocus:i=>{e.onCloseAutoFocus?.(i),!i.defaultPrevented&&c.current&&i.preventDefault(),c.current=!1},onInteractOutside:i=>{e.onInteractOutside?.(i),!i.defaultPrevented&&!a.modal&&(c.current=!0)},style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});O.displayName=E;var Ce="ContextMenuGroup",he=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(q,{...a,...n,ref:t})});he.displayName=Ce;var ge="ContextMenuLabel",Me=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(V,{...a,...n,ref:t})});Me.displayName=ge;var ve="ContextMenuItem",T=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(W,{...a,...n,ref:t})});T.displayName=ve;var be="ContextMenuCheckboxItem",_e=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(H,{...a,...n,ref:t})});_e.displayName=be;var Se="ContextMenuRadioGroup",Ie=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(X,{...a,...n,ref:t})});Ie.displayName=Se;var Pe="ContextMenuRadioItem",Re=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(K,{...a,...n,ref:t})});Re.displayName=Pe;var ye="ContextMenuItemIndicator",Ne=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(Y,{...a,...n,ref:t})});Ne.displayName=ye;var we="ContextMenuSeparator",je=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(J,{...a,...n,ref:t})});je.displayName=we;var Ae="ContextMenuArrow",Ee=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(Q,{...a,...n,ref:t})});Ee.displayName=Ae;var Oe="ContextMenuSubTrigger",Te=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(Z,{...a,...n,ref:t})});Te.displayName=Oe;var ke="ContextMenuSubContent",Ge=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(ee,{...a,...n,ref:t,style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Ge.displayName=ke;function _(e){return t=>t.pointerType!=="mouse"?e(t):void 0}var P=N,De=j,Ue=A,Le=O;const $e=({onSelect:e,children:t})=>o.jsx(T,{onSelect:e??void 0,asChild:!0,children:t}),S=({title:e,onOpenChange:t,trigger:r,hasAccessibleAlternative:n,children:a})=>{const[l,c]=s.useState(!1),i=s.useCallback(C=>{c(C),t?.(C)},[c,t]),p=ce(),f=p==="android"||p==="ios",u=s.useMemo(()=>({MenuItemWrapper:f?null:$e,onOpenChange:i}),[i]),x=o.jsx(ue.Provider,{value:u,children:a}),m=o.jsx(De,{"aria-haspopup":"menu",tabIndex:n?void 0:0,asChild:!0,children:r});return f?o.jsxs(o.Fragment,{children:[o.jsx(P,{onOpenChange:i,children:m}),o.jsx(v.Root,{open:l,onOpenChange:i,children:o.jsxs(v.Portal,{children:[o.jsx(v.Overlay,{className:ae(se.bg)}),o.jsx(v.Content,{asChild:!0,children:o.jsx(ie,{title:e,children:x})})]})})]}):o.jsxs(P,{onOpenChange:i,children:[m,o.jsx(Ue,{children:o.jsx(Le,{asChild:!0,children:o.jsx(re,{title:e,children:x})})})]})};try{S.displayName="ContextMenu",S.__docgenInfo={description:"A menu opened by right-clicking or long-pressing another UI element.",displayName:"ContextMenu",props:{title:{defaultValue:null,description:"The menu title.",name:"title",required:!0,type:{name:"string"}},onOpenChange:{defaultValue:null,description:"Event handler called when the open state of the menu changes.",name:"onOpenChange",required:!1,type:{name:"((open: boolean) => void)"}},trigger:{defaultValue:null,description:`The trigger that can be right-clicked or long-pressed to open the menu. +import{j as o}from"./jsx-runtime-DR9Q75dM.js";import{U as D}from"./user-profile-cqTW1cHH.js";import{N as U,C as L,L as $}from"./notifications-BEKrtwGv.js";import{r as s}from"./index-DRjF_FHU.js";import{c as g}from"./index-CGa_gRws.js";import{P as F}from"./index-Ksfxd92j.js";import{c as R,A as z,C as B,G as q,L as V,I as W,a as H,R as X,b as K,d as Y,S as J,e as Q,f as Z,g as ee,u as te,h as ne,P as oe,D as v}from"./index-Dbt-v4y0.js";import{F as re}from"./FloatingMenu-Dc89G4Nf.js";import{c as ae}from"./index-lhGYx47h.js";import{d as se,D as ie,g as ce}from"./DrawerMenu-BNILBemh.js";import{a as ue,M as b}from"./MenuItem-YyrVQu2n.js";import{S as le}from"./Separator-BbJs_Bbv.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./floating-ui.react-CSvGZjCC.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";function de(e,t=[]){let r=[];function n(l,c){const i=s.createContext(c),p=r.length;r=[...r,c];const f=x=>{const{scope:m,children:C,...h}=x,k=m?.[e]?.[p]||i,G=s.useMemo(()=>h,Object.values(h));return o.jsx(k.Provider,{value:G,children:C})};f.displayName=l+"Provider";function u(x,m){const C=m?.[e]?.[p]||i,h=s.useContext(C);if(h)return h;if(c!==void 0)return c;throw new Error(`\`${x}\` must be used within \`${l}\``)}return[f,u]}const a=()=>{const l=r.map(c=>s.createContext(c));return function(i){const p=i?.[e]||l;return s.useMemo(()=>({[`__scope${e}`]:{...i,[e]:p}}),[i,p])}};return a.scopeName=e,[n,pe(a,...t)]}function pe(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(a=>({useScope:a(),scopeName:a.scopeName}));return function(l){const c=n.reduce((i,{useScope:p,scopeName:f})=>{const x=p(l)[`__scope${f}`];return{...i,...x}},{});return s.useMemo(()=>({[`__scope${t.scopeName}`]:c}),[c])}};return r.scopeName=t.scopeName,r}var I="ContextMenu",[xe,it]=de(I,[R]),d=R(),[me,y]=xe(I),N=e=>{const{__scopeContextMenu:t,children:r,onOpenChange:n,dir:a,modal:l=!0}=e,[c,i]=s.useState(!1),p=d(t),f=te(n),u=s.useCallback(x=>{i(x),f(x)},[f]);return o.jsx(me,{scope:t,open:c,onOpenChange:u,modal:l,children:o.jsx(ne,{...p,dir:a,open:c,onOpenChange:u,modal:l,children:r})})};N.displayName=I;var w="ContextMenuTrigger",j=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,disabled:n=!1,...a}=e,l=y(w,r),c=d(r),i=s.useRef({x:0,y:0}),p=s.useRef({getBoundingClientRect:()=>DOMRect.fromRect({width:0,height:0,...i.current})}),f=s.useRef(0),u=s.useCallback(()=>window.clearTimeout(f.current),[]),x=m=>{i.current={x:m.clientX,y:m.clientY},l.onOpenChange(!0)};return s.useEffect(()=>u,[u]),s.useEffect(()=>void(n&&u()),[n,u]),o.jsxs(o.Fragment,{children:[o.jsx(z,{...c,virtualRef:p}),o.jsx(F.span,{"data-state":l.open?"open":"closed","data-disabled":n?"":void 0,...a,ref:t,style:{WebkitTouchCallout:"none",...e.style},onContextMenu:n?e.onContextMenu:g(e.onContextMenu,m=>{u(),x(m),m.preventDefault()}),onPointerDown:n?e.onPointerDown:g(e.onPointerDown,_(m=>{u(),f.current=window.setTimeout(()=>x(m),700)})),onPointerMove:n?e.onPointerMove:g(e.onPointerMove,_(u)),onPointerCancel:n?e.onPointerCancel:g(e.onPointerCancel,_(u)),onPointerUp:n?e.onPointerUp:g(e.onPointerUp,_(u))})]})});j.displayName=w;var fe="ContextMenuPortal",A=e=>{const{__scopeContextMenu:t,...r}=e,n=d(t);return o.jsx(oe,{...n,...r})};A.displayName=fe;var E="ContextMenuContent",O=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=y(E,r),l=d(r),c=s.useRef(!1);return o.jsx(B,{...l,...n,ref:t,side:"right",sideOffset:2,align:"start",onCloseAutoFocus:i=>{e.onCloseAutoFocus?.(i),!i.defaultPrevented&&c.current&&i.preventDefault(),c.current=!1},onInteractOutside:i=>{e.onInteractOutside?.(i),!i.defaultPrevented&&!a.modal&&(c.current=!0)},style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});O.displayName=E;var Ce="ContextMenuGroup",he=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(q,{...a,...n,ref:t})});he.displayName=Ce;var ge="ContextMenuLabel",Me=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(V,{...a,...n,ref:t})});Me.displayName=ge;var ve="ContextMenuItem",T=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(W,{...a,...n,ref:t})});T.displayName=ve;var be="ContextMenuCheckboxItem",_e=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(H,{...a,...n,ref:t})});_e.displayName=be;var Se="ContextMenuRadioGroup",Ie=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(X,{...a,...n,ref:t})});Ie.displayName=Se;var Pe="ContextMenuRadioItem",Re=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(K,{...a,...n,ref:t})});Re.displayName=Pe;var ye="ContextMenuItemIndicator",Ne=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(Y,{...a,...n,ref:t})});Ne.displayName=ye;var we="ContextMenuSeparator",je=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(J,{...a,...n,ref:t})});je.displayName=we;var Ae="ContextMenuArrow",Ee=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(Q,{...a,...n,ref:t})});Ee.displayName=Ae;var Oe="ContextMenuSubTrigger",Te=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(Z,{...a,...n,ref:t})});Te.displayName=Oe;var ke="ContextMenuSubContent",Ge=s.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,a=d(r);return o.jsx(ee,{...a,...n,ref:t,style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Ge.displayName=ke;function _(e){return t=>t.pointerType!=="mouse"?e(t):void 0}var P=N,De=j,Ue=A,Le=O;const $e=({onSelect:e,children:t})=>o.jsx(T,{onSelect:e??void 0,asChild:!0,children:t}),S=({title:e,onOpenChange:t,trigger:r,hasAccessibleAlternative:n,children:a})=>{const[l,c]=s.useState(!1),i=s.useCallback(C=>{c(C),t?.(C)},[c,t]),p=ce(),f=p==="android"||p==="ios",u=s.useMemo(()=>({MenuItemWrapper:f?null:$e,onOpenChange:i}),[i]),x=o.jsx(ue.Provider,{value:u,children:a}),m=o.jsx(De,{"aria-haspopup":"menu",tabIndex:n?void 0:0,asChild:!0,children:r});return f?o.jsxs(o.Fragment,{children:[o.jsx(P,{onOpenChange:i,children:m}),o.jsx(v.Root,{open:l,onOpenChange:i,children:o.jsxs(v.Portal,{children:[o.jsx(v.Overlay,{className:ae(se.bg)}),o.jsx(v.Content,{asChild:!0,children:o.jsx(ie,{title:e,children:x})})]})})]}):o.jsxs(P,{onOpenChange:i,children:[m,o.jsx(Ue,{children:o.jsx(Le,{asChild:!0,children:o.jsx(re,{title:e,children:x})})})]})};try{S.displayName="ContextMenu",S.__docgenInfo={description:"A menu opened by right-clicking or long-pressing another UI element.",displayName:"ContextMenu",props:{title:{defaultValue:null,description:"The menu title.",name:"title",required:!0,type:{name:"string"}},onOpenChange:{defaultValue:null,description:"Event handler called when the open state of the menu changes.",name:"onOpenChange",required:!1,type:{name:"((open: boolean) => void)"}},trigger:{defaultValue:null,description:`The trigger that can be right-clicked or long-pressed to open the menu. This must be a component that accepts a ref and spreads props. https://www.radix-ui.com/primitives/docs/guides/composition`,name:"trigger",required:!0,type:{name:"ReactNode"}},hasAccessibleAlternative:{defaultValue:null,description:`Whether the functionality of this menu is available through some other keyboard-accessible means. Preferably this should be true, because context diff --git a/assets/DocsRenderer-CFRXHY34-xrdFE-63.js b/assets/DocsRenderer-CFRXHY34-DG86K5OV.js similarity index 99% rename from assets/DocsRenderer-CFRXHY34-xrdFE-63.js rename to assets/DocsRenderer-CFRXHY34-DG86K5OV.js index 6a54b864..3393482c 100644 --- a/assets/DocsRenderer-CFRXHY34-xrdFE-63.js +++ b/assets/DocsRenderer-CFRXHY34-DG86K5OV.js @@ -1,5 +1,5 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-C_34dRtw.js","./iframe-80GKSfNA.js","./index-DRjF_FHU.js","./jsx-runtime-DR9Q75dM.js","./index-BvEl7W6R.js","./index-D-8MO0q_.js","./index-CidnEmUr.js","./index-DrFu-skq.js","./react-18-BZ4hdgop.js","./Color-F6OSRLHC-CsBEHEVI.js","./index-ChEI-nsM.js"])))=>i.map(i=>d[i]); -import{_ as G1}from"./iframe-80GKSfNA.js";import{r as l,R as y}from"./index-DRjF_FHU.js";import{j as J}from"./jsx-runtime-DR9Q75dM.js";import{r as ds,F as W4}from"./index-BvEl7W6R.js";import{O as G4,P as jx}from"./index-D-8MO0q_.js";import{y as fh,g as bu}from"./index-CidnEmUr.js";import{d as Vx}from"./index-DrFu-skq.js";import{renderElement as Ux,unmountElement as qx}from"./react-18-BZ4hdgop.js";var Wx=Object.create,Y4=Object.defineProperty,Gx=Object.getOwnPropertyDescriptor,K4=Object.getOwnPropertyNames,Yx=Object.getPrototypeOf,Kx=Object.prototype.hasOwnProperty,wi=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),mn=(e,t)=>function(){return t||(0,e[K4(e)[0]])((t={exports:{}}).exports,t),t.exports},Zx=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of K4(t))!Kx.call(e,a)&&a!==r&&Y4(e,a,{get:()=>t[a],enumerable:!(n=Gx(t,a))||n.enumerable});return e},Y1=(e,t,r)=>(r=e!=null?Wx(Yx(e)):{},Zx(t||!e||!e.__esModule?Y4(r,"default",{value:e,enumerable:!0}):r,e));function Jx(e,t,{signal:r,edges:n}={}){let a,o=null,i=n!=null&&n.includes("leading"),s=n==null||n.includes("trailing"),c=()=>{o!==null&&(e.apply(a,o),a=void 0,o=null)},d=()=>{s&&c(),f()},p=null,m=()=>{p!=null&&clearTimeout(p),p=setTimeout(()=>{p=null,d()},t)},h=()=>{p!==null&&(clearTimeout(p),p=null)},f=()=>{h(),a=void 0,o=null},v=()=>{h(),c()},g=function(...w){if(r?.aborted)return;a=this,o=w;let x=p==null;m(),i&&x&&c()};return g.schedule=m,g.cancel=f,g.flush=v,r?.addEventListener("abort",f,{once:!0}),g}function fV(e,t=0,r={}){typeof r!="object"&&(r={});let{signal:n,leading:a=!1,trailing:o=!0,maxWait:i}=r,s=Array(2);a&&(s[0]="leading"),o&&(s[1]="trailing");let c,d=null,p=Jx(function(...f){c=e.apply(this,f),d=null},t,{signal:n,edges:s}),m=function(...f){if(i!=null){if(d===null)d=Date.now();else if(Date.now()-d>=i)return c=e.apply(this,f),d=Date.now(),p.cancel(),p.schedule(),c}return p.apply(this,f),c},h=()=>(p.flush(),c);return m.cancel=p.cancel,m.flush=h,m}function Xx(e){return Array.from(new Set(e))}function Qx(e,t){let r={},n=Object.entries(e);for(let a=0;a`control-${e.replace(/\s+/g,"-")}`,ps=e=>`set-${e.replace(/\s+/g,"-")}`,lD=Object.create,K1=Object.defineProperty,sD=Object.getOwnPropertyDescriptor,uD=Object.getOwnPropertyNames,cD=Object.getPrototypeOf,dD=Object.prototype.hasOwnProperty,R=(e,t)=>K1(e,"name",{value:t,configurable:!0}),Ei=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),fs=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),pD=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of uD(t))!dD.call(e,a)&&a!==r&&K1(e,a,{get:()=>t[a],enumerable:!(n=sD(t,a))||n.enumerable});return e},Z1=(e,t,r)=>(r=e!=null?lD(cD(e)):{},pD(t||!e||!e.__esModule?K1(r,"default",{value:e,enumerable:!0}):r,e)),fD=fs(e=>{(function(){var t=typeof Symbol=="function"&&Symbol.for,r=t?Symbol.for("react.element"):60103,n=t?Symbol.for("react.portal"):60106,a=t?Symbol.for("react.fragment"):60107,o=t?Symbol.for("react.strict_mode"):60108,i=t?Symbol.for("react.profiler"):60114,s=t?Symbol.for("react.provider"):60109,c=t?Symbol.for("react.context"):60110,d=t?Symbol.for("react.async_mode"):60111,p=t?Symbol.for("react.concurrent_mode"):60111,m=t?Symbol.for("react.forward_ref"):60112,h=t?Symbol.for("react.suspense"):60113,f=t?Symbol.for("react.suspense_list"):60120,v=t?Symbol.for("react.memo"):60115,g=t?Symbol.for("react.lazy"):60116,w=t?Symbol.for("react.block"):60121,x=t?Symbol.for("react.fundamental"):60117,D=t?Symbol.for("react.responder"):60118,E=t?Symbol.for("react.scope"):60119;function b($){return typeof $=="string"||typeof $=="function"||$===a||$===p||$===i||$===o||$===h||$===f||typeof $=="object"&&$!==null&&($.$$typeof===g||$.$$typeof===v||$.$$typeof===s||$.$$typeof===c||$.$$typeof===m||$.$$typeof===x||$.$$typeof===D||$.$$typeof===E||$.$$typeof===w)}R(b,"isValidElementType");function C($){if(typeof $=="object"&&$!==null){var rt=$.$$typeof;switch(rt){case r:var xt=$.type;switch(xt){case d:case p:case a:case i:case o:case h:return xt;default:var Mr=xt&&xt.$$typeof;switch(Mr){case c:case m:case g:case v:case s:return Mr;default:return rt}}case n:return rt}}}R(C,"typeOf");var S=d,k=p,A=c,_=s,I=r,T=m,z=a,L=g,M=v,O=n,P=i,j=o,U=h,V=!1;function G($){return V||(V=!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.")),Q($)||C($)===d}R(G,"isAsyncMode");function Q($){return C($)===p}R(Q,"isConcurrentMode");function ne($){return C($)===c}R(ne,"isContextConsumer");function Z($){return C($)===s}R(Z,"isContextProvider");function ie($){return typeof $=="object"&&$!==null&&$.$$typeof===r}R(ie,"isElement");function N($){return C($)===m}R(N,"isForwardRef");function K($){return C($)===a}R(K,"isFragment");function re($){return C($)===g}R(re,"isLazy");function fe($){return C($)===v}R(fe,"isMemo");function Ce($){return C($)===n}R(Ce,"isPortal");function Et($){return C($)===i}R(Et,"isProfiler");function He($){return C($)===o}R(He,"isStrictMode");function tt($){return C($)===h}R(tt,"isSuspense"),e.AsyncMode=S,e.ConcurrentMode=k,e.ContextConsumer=A,e.ContextProvider=_,e.Element=I,e.ForwardRef=T,e.Fragment=z,e.Lazy=L,e.Memo=M,e.Portal=O,e.Profiler=P,e.StrictMode=j,e.Suspense=U,e.isAsyncMode=G,e.isConcurrentMode=Q,e.isContextConsumer=ne,e.isContextProvider=Z,e.isElement=ie,e.isForwardRef=N,e.isFragment=K,e.isLazy=re,e.isMemo=fe,e.isPortal=Ce,e.isProfiler=Et,e.isStrictMode=He,e.isSuspense=tt,e.isValidElementType=b,e.typeOf=C})()}),hD=fs((e,t)=>{t.exports=fD()}),Z4=fs((e,t)=>{var r=hD(),n={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},a={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},o={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};s[r.ForwardRef]=o,s[r.Memo]=i;function c(w){return r.isMemo(w)?i:s[w.$$typeof]||n}R(c,"getStatics");var d=Object.defineProperty,p=Object.getOwnPropertyNames,m=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,v=Object.prototype;function g(w,x,D){if(typeof x!="string"){if(v){var E=f(x);E&&E!==v&&g(w,E,D)}var b=p(x);m&&(b=b.concat(m(x)));for(var C=c(w),S=c(x),k=0;k{(function(r){if(typeof e=="object"&&typeof t<"u")t.exports=r();else if(typeof define=="function"&&define.amd)define([],r);else{var n;typeof window<"u"?n=window:typeof global<"u"?n=global:typeof self<"u"?n=self:n=this,n.memoizerific=r()}})(function(){return R(function r(n,a,o){function i(d,p){if(!a[d]){if(!n[d]){var m=typeof Ei=="function"&&Ei;if(!p&&m)return m(d,!0);if(s)return s(d,!0);var h=new Error("Cannot find module '"+d+"'");throw h.code="MODULE_NOT_FOUND",h}var f=a[d]={exports:{}};n[d][0].call(f.exports,function(v){var g=n[d][1][v];return i(g||v)},f,f.exports,r,n,a,o)}return a[d].exports}R(i,"s");for(var s=typeof Ei=="function"&&Ei,c=0;c=0)return this.lastItem=this.list[s],this.list[s].val},o.prototype.set=function(i,s){var c;return this.lastItem&&this.isEqual(this.lastItem.key,i)?(this.lastItem.val=s,this):(c=this.indexOf(i),c>=0?(this.lastItem=this.list[c],this.list[c].val=s,this):(this.lastItem={key:i,val:s},this.list.push(this.lastItem),this.size++,this))},o.prototype.delete=function(i){var s;if(this.lastItem&&this.isEqual(this.lastItem.key,i)&&(this.lastItem=void 0),s=this.indexOf(i),s>=0)return this.size--,this.list.splice(s,1)[0]},o.prototype.has=function(i){var s;return this.lastItem&&this.isEqual(this.lastItem.key,i)?!0:(s=this.indexOf(i),s>=0?(this.lastItem=this.list[s],!0):!1)},o.prototype.forEach=function(i,s){var c;for(c=0;c0&&(D[x]={cacheItem:v,arg:arguments[x]},E?i(m,D):m.push(D),m.length>d&&s(m.shift())),f.wasMemoized=E,f.numArgs=x+1,w},"memoizerific");return f.limit=d,f.wasMemoized=!1,f.cache=p,f.lru=m,f}};function i(d,p){var m=d.length,h=p.length,f,v,g;for(v=0;v=0&&(m=d[f],h=m.cacheItem.get(m.arg),!h||!h.size);f--)m.cacheItem.delete(m.arg)}R(s,"removeCachedResult");function c(d,p){return d===p||d!==d&&p!==p}R(c,"isEqual")},{"map-or-similar":1}]},{},[3])(3)})});function $t(){return $t=Object.assign?Object.assign.bind():function(e){for(var t=1;ti.map(i=>d[i]); +import{_ as G1}from"./iframe-DWIAQds9.js";import{r as l,R as y}from"./index-DRjF_FHU.js";import{j as J}from"./jsx-runtime-DR9Q75dM.js";import{r as ds,F as W4}from"./index-BvEl7W6R.js";import{O as G4,P as jx}from"./index-D-8MO0q_.js";import{y as fh,g as bu}from"./index-CidnEmUr.js";import{d as Vx}from"./index-DrFu-skq.js";import{renderElement as Ux,unmountElement as qx}from"./react-18-BZ4hdgop.js";var Wx=Object.create,Y4=Object.defineProperty,Gx=Object.getOwnPropertyDescriptor,K4=Object.getOwnPropertyNames,Yx=Object.getPrototypeOf,Kx=Object.prototype.hasOwnProperty,wi=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),mn=(e,t)=>function(){return t||(0,e[K4(e)[0]])((t={exports:{}}).exports,t),t.exports},Zx=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of K4(t))!Kx.call(e,a)&&a!==r&&Y4(e,a,{get:()=>t[a],enumerable:!(n=Gx(t,a))||n.enumerable});return e},Y1=(e,t,r)=>(r=e!=null?Wx(Yx(e)):{},Zx(t||!e||!e.__esModule?Y4(r,"default",{value:e,enumerable:!0}):r,e));function Jx(e,t,{signal:r,edges:n}={}){let a,o=null,i=n!=null&&n.includes("leading"),s=n==null||n.includes("trailing"),c=()=>{o!==null&&(e.apply(a,o),a=void 0,o=null)},d=()=>{s&&c(),f()},p=null,m=()=>{p!=null&&clearTimeout(p),p=setTimeout(()=>{p=null,d()},t)},h=()=>{p!==null&&(clearTimeout(p),p=null)},f=()=>{h(),a=void 0,o=null},v=()=>{h(),c()},g=function(...w){if(r?.aborted)return;a=this,o=w;let x=p==null;m(),i&&x&&c()};return g.schedule=m,g.cancel=f,g.flush=v,r?.addEventListener("abort",f,{once:!0}),g}function fV(e,t=0,r={}){typeof r!="object"&&(r={});let{signal:n,leading:a=!1,trailing:o=!0,maxWait:i}=r,s=Array(2);a&&(s[0]="leading"),o&&(s[1]="trailing");let c,d=null,p=Jx(function(...f){c=e.apply(this,f),d=null},t,{signal:n,edges:s}),m=function(...f){if(i!=null){if(d===null)d=Date.now();else if(Date.now()-d>=i)return c=e.apply(this,f),d=Date.now(),p.cancel(),p.schedule(),c}return p.apply(this,f),c},h=()=>(p.flush(),c);return m.cancel=p.cancel,m.flush=h,m}function Xx(e){return Array.from(new Set(e))}function Qx(e,t){let r={},n=Object.entries(e);for(let a=0;a`control-${e.replace(/\s+/g,"-")}`,ps=e=>`set-${e.replace(/\s+/g,"-")}`,lD=Object.create,K1=Object.defineProperty,sD=Object.getOwnPropertyDescriptor,uD=Object.getOwnPropertyNames,cD=Object.getPrototypeOf,dD=Object.prototype.hasOwnProperty,R=(e,t)=>K1(e,"name",{value:t,configurable:!0}),Ei=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),fs=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),pD=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of uD(t))!dD.call(e,a)&&a!==r&&K1(e,a,{get:()=>t[a],enumerable:!(n=sD(t,a))||n.enumerable});return e},Z1=(e,t,r)=>(r=e!=null?lD(cD(e)):{},pD(t||!e||!e.__esModule?K1(r,"default",{value:e,enumerable:!0}):r,e)),fD=fs(e=>{(function(){var t=typeof Symbol=="function"&&Symbol.for,r=t?Symbol.for("react.element"):60103,n=t?Symbol.for("react.portal"):60106,a=t?Symbol.for("react.fragment"):60107,o=t?Symbol.for("react.strict_mode"):60108,i=t?Symbol.for("react.profiler"):60114,s=t?Symbol.for("react.provider"):60109,c=t?Symbol.for("react.context"):60110,d=t?Symbol.for("react.async_mode"):60111,p=t?Symbol.for("react.concurrent_mode"):60111,m=t?Symbol.for("react.forward_ref"):60112,h=t?Symbol.for("react.suspense"):60113,f=t?Symbol.for("react.suspense_list"):60120,v=t?Symbol.for("react.memo"):60115,g=t?Symbol.for("react.lazy"):60116,w=t?Symbol.for("react.block"):60121,x=t?Symbol.for("react.fundamental"):60117,D=t?Symbol.for("react.responder"):60118,E=t?Symbol.for("react.scope"):60119;function b($){return typeof $=="string"||typeof $=="function"||$===a||$===p||$===i||$===o||$===h||$===f||typeof $=="object"&&$!==null&&($.$$typeof===g||$.$$typeof===v||$.$$typeof===s||$.$$typeof===c||$.$$typeof===m||$.$$typeof===x||$.$$typeof===D||$.$$typeof===E||$.$$typeof===w)}R(b,"isValidElementType");function C($){if(typeof $=="object"&&$!==null){var rt=$.$$typeof;switch(rt){case r:var xt=$.type;switch(xt){case d:case p:case a:case i:case o:case h:return xt;default:var Mr=xt&&xt.$$typeof;switch(Mr){case c:case m:case g:case v:case s:return Mr;default:return rt}}case n:return rt}}}R(C,"typeOf");var S=d,k=p,A=c,_=s,I=r,T=m,z=a,L=g,M=v,O=n,P=i,j=o,U=h,V=!1;function G($){return V||(V=!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.")),Q($)||C($)===d}R(G,"isAsyncMode");function Q($){return C($)===p}R(Q,"isConcurrentMode");function ne($){return C($)===c}R(ne,"isContextConsumer");function Z($){return C($)===s}R(Z,"isContextProvider");function ie($){return typeof $=="object"&&$!==null&&$.$$typeof===r}R(ie,"isElement");function N($){return C($)===m}R(N,"isForwardRef");function K($){return C($)===a}R(K,"isFragment");function re($){return C($)===g}R(re,"isLazy");function fe($){return C($)===v}R(fe,"isMemo");function Ce($){return C($)===n}R(Ce,"isPortal");function Et($){return C($)===i}R(Et,"isProfiler");function He($){return C($)===o}R(He,"isStrictMode");function tt($){return C($)===h}R(tt,"isSuspense"),e.AsyncMode=S,e.ConcurrentMode=k,e.ContextConsumer=A,e.ContextProvider=_,e.Element=I,e.ForwardRef=T,e.Fragment=z,e.Lazy=L,e.Memo=M,e.Portal=O,e.Profiler=P,e.StrictMode=j,e.Suspense=U,e.isAsyncMode=G,e.isConcurrentMode=Q,e.isContextConsumer=ne,e.isContextProvider=Z,e.isElement=ie,e.isForwardRef=N,e.isFragment=K,e.isLazy=re,e.isMemo=fe,e.isPortal=Ce,e.isProfiler=Et,e.isStrictMode=He,e.isSuspense=tt,e.isValidElementType=b,e.typeOf=C})()}),hD=fs((e,t)=>{t.exports=fD()}),Z4=fs((e,t)=>{var r=hD(),n={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},a={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},o={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};s[r.ForwardRef]=o,s[r.Memo]=i;function c(w){return r.isMemo(w)?i:s[w.$$typeof]||n}R(c,"getStatics");var d=Object.defineProperty,p=Object.getOwnPropertyNames,m=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,v=Object.prototype;function g(w,x,D){if(typeof x!="string"){if(v){var E=f(x);E&&E!==v&&g(w,E,D)}var b=p(x);m&&(b=b.concat(m(x)));for(var C=c(w),S=c(x),k=0;k{(function(r){if(typeof e=="object"&&typeof t<"u")t.exports=r();else if(typeof define=="function"&&define.amd)define([],r);else{var n;typeof window<"u"?n=window:typeof global<"u"?n=global:typeof self<"u"?n=self:n=this,n.memoizerific=r()}})(function(){return R(function r(n,a,o){function i(d,p){if(!a[d]){if(!n[d]){var m=typeof Ei=="function"&&Ei;if(!p&&m)return m(d,!0);if(s)return s(d,!0);var h=new Error("Cannot find module '"+d+"'");throw h.code="MODULE_NOT_FOUND",h}var f=a[d]={exports:{}};n[d][0].call(f.exports,function(v){var g=n[d][1][v];return i(g||v)},f,f.exports,r,n,a,o)}return a[d].exports}R(i,"s");for(var s=typeof Ei=="function"&&Ei,c=0;c=0)return this.lastItem=this.list[s],this.list[s].val},o.prototype.set=function(i,s){var c;return this.lastItem&&this.isEqual(this.lastItem.key,i)?(this.lastItem.val=s,this):(c=this.indexOf(i),c>=0?(this.lastItem=this.list[c],this.list[c].val=s,this):(this.lastItem={key:i,val:s},this.list.push(this.lastItem),this.size++,this))},o.prototype.delete=function(i){var s;if(this.lastItem&&this.isEqual(this.lastItem.key,i)&&(this.lastItem=void 0),s=this.indexOf(i),s>=0)return this.size--,this.list.splice(s,1)[0]},o.prototype.has=function(i){var s;return this.lastItem&&this.isEqual(this.lastItem.key,i)?!0:(s=this.indexOf(i),s>=0?(this.lastItem=this.list[s],!0):!1)},o.prototype.forEach=function(i,s){var c;for(c=0;c0&&(D[x]={cacheItem:v,arg:arguments[x]},E?i(m,D):m.push(D),m.length>d&&s(m.shift())),f.wasMemoized=E,f.numArgs=x+1,w},"memoizerific");return f.limit=d,f.wasMemoized=!1,f.cache=p,f.lru=m,f}};function i(d,p){var m=d.length,h=p.length,f,v,g;for(v=0;v=0&&(m=d[f],h=m.cacheItem.get(m.arg),!h||!h.size);f--)m.cacheItem.delete(m.arg)}R(s,"removeCachedResult");function c(d,p){return d===p||d!==d&&p!==p}R(c,"isEqual")},{"map-or-similar":1}]},{},[3])(3)})});function $t(){return $t=Object.assign?Object.assign.bind():function(e){for(var t=1;t0?we(Sa,--$e):0,ia--,de===10&&(ia=1,gs--),de}R(o3,"prev");function Oe(){return de=$e2||la(de)>3?"":" "}R(i3,"whitespace");function l3(e,t){for(;--t&&Oe()&&!(de<48||de>102||de>57&&de<65||de>70&&de<97););return ka(e,vo()+(t<6&&dt()==32&&Oe()==32))}R(l3,"escaping");function xl(e){for(;Oe();)switch(de){case e:return $e;case 34:case 39:e!==34&&e!==39&&xl(de);break;case 40:e===41&&xl(e);break;case 92:Oe();break}return $e}R(xl,"delimiter");function s3(e,t){for(;Oe()&&e+de!==57&&!(e+de===84&&dt()===47););return"/*"+ka(t,$e-1)+"*"+hs(e===47?e:Oe())}R(s3,"commenter");function u3(e){for(;!la(dt());)Oe();return ka(e,$e)}R(u3,"identifier");function c3(e){return ap(bo("",null,null,null,[""],e=np(e),0,[0],e))}R(c3,"compile");function bo(e,t,r,n,a,o,i,s,c){for(var d=0,p=0,m=i,h=0,f=0,v=0,g=1,w=1,x=1,D=0,E="",b=a,C=o,S=n,k=E;w;)switch(v=D,D=Oe()){case 40:if(v!=108&&we(k,m-1)==58){El(k+=ee(yo(D),"&","&\f"),"&\f")!=-1&&(x=-1);break}case 34:case 39:case 91:k+=yo(D);break;case 9:case 10:case 13:case 32:k+=i3(v);break;case 92:k+=l3(vo()-1,7);continue;case 47:switch(dt()){case 42:case 47:ao(d3(s3(Oe(),vo()),t,r),c);break;default:k+="/"}break;case 123*g:s[d++]=lt(k)*x;case 125*g:case 59:case 0:switch(D){case 0:case 125:w=0;case 59+p:x==-1&&(k=ee(k,/\f/g,"")),f>0&<(k)-m&&ao(f>32?J0(k+";",n,r,m-1):J0(ee(k," ","")+";",n,r,m-2),c);break;case 59:k+=";";default:if(ao(S=Z0(k,t,r,d,p,a,s,E,b=[],C=[],m),o),D===123)if(p===0)bo(k,t,S,S,b,o,m,s,C);else switch(h===99&&we(k,3)===110?100:h){case 100:case 108:case 109:case 115:bo(e,S,S,n&&ao(Z0(e,S,S,0,0,a,s,E,a,b=[],m),C),a,C,m,s,n?b:C);break;default:bo(k,S,S,S,[""],C,0,s,C)}}d=p=f=0,g=x=1,E=k="",m=i;break;case 58:m=1+lt(k),f=v;default:if(g<1){if(D==123)--g;else if(D==125&&g++==0&&o3()==125)continue}switch(k+=hs(D),D*g){case 38:x=p>0?1:(k+="\f",-1);break;case 44:s[d++]=(lt(k)-1)*x,x=1;break;case 64:dt()===45&&(k+=yo(Oe())),h=dt(),p=m=lt(E=k+=u3(vo())),D++;break;case 45:v===45&<(k)==2&&(g=0)}}return o}R(bo,"parse");function Z0(e,t,r,n,a,o,i,s,c,d,p){for(var m=a-1,h=a===0?o:[""],f=ms(h),v=0,g=0,w=0;v0?h[x]+" "+D:ee(D,/&\f/g,h[x])))&&(c[w++]=E);return Go(e,t,r,a===0?ep:s,c,d,p)}R(Z0,"ruleset");function d3(e,t,r){return Go(e,t,r,Q1,hs(a3()),oa(e,2,-2),0)}R(d3,"comment");function J0(e,t,r,n){return Go(e,t,r,tp,oa(e,0,n),oa(e,n+1,-1),n)}R(J0,"declaration");function an(e,t){for(var r="",n=ms(e),a=0;a-1},"isIgnoringComment"),_D=R(function(e){return function(t,r,n){if(!(t.type!=="rule"||e.compat)){var a=t.value.match(/(:first|:nth|:nth-last)-child/g);if(a){for(var o=!!t.parent,i=o?t.parent.children:n,s=i.length-1;s>=0;s--){var c=i[s];if(c.line=0;r--)if(!h3(t[r]))return!0;return!1},"isPrependedWithRegularRules"),vh=R(function(e){e.type="",e.value="",e.return="",e.children="",e.props=""},"nullifyElement"),ID=R(function(e,t,r){h3(e)&&(e.parent?(console.error("`@import` rules can't be nested inside other rules. Please move it to the top level and put it before regular rules. Keep in mind that they can only be used within global styles."),vh(e)):RD(t,r)&&(console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules."),vh(e)))},"incorrectImportAlarm");function op(e,t){switch(e3(e,t)){case 5103:return te+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return te+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return te+e+wl+e+_e+e+e;case 6828:case 4268:return te+e+_e+e+e;case 6165:return te+e+_e+"flex-"+e+e;case 5187:return te+e+ee(e,/(\w+).+(:[^]+)/,te+"box-$1$2"+_e+"flex-$1$2")+e;case 5443:return te+e+_e+"flex-item-"+ee(e,/flex-|-self/,"")+e;case 4675:return te+e+_e+"flex-line-pack"+ee(e,/align-content|flex-|-self/,"")+e;case 5548:return te+e+_e+ee(e,"shrink","negative")+e;case 5292:return te+e+_e+ee(e,"basis","preferred-size")+e;case 6060:return te+"box-"+ee(e,"-grow","")+te+e+_e+ee(e,"grow","positive")+e;case 4554:return te+ee(e,/([^-])(transform)/g,"$1"+te+"$2")+e;case 6187:return ee(ee(ee(e,/(zoom-|grab)/,te+"$1"),/(image-set)/,te+"$1"),e,"")+e;case 5495:case 3959:return ee(e,/(image-set\([^]*)/,te+"$1$`$1");case 4968:return ee(ee(e,/(.+:)(flex-)?(.*)/,te+"box-pack:$3"+_e+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+te+e+e;case 4095:case 3583:case 4068:case 2532:return ee(e,/(.+)-inline(.+)/,te+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(lt(e)-1-t>6)switch(we(e,t+1)){case 109:if(we(e,t+4)!==45)break;case 102:return ee(e,/(.+:)(.+)-([^]+)/,"$1"+te+"$2-$3$1"+wl+(we(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~El(e,"stretch")?op(ee(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(we(e,t+1)!==115)break;case 6444:switch(we(e,lt(e)-3-(~El(e,"!important")&&10))){case 107:return ee(e,":",":"+te)+e;case 101:return ee(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+te+(we(e,14)===45?"inline-":"")+"box$3$1"+te+"$2$3$1"+_e+"$2box$3")+e}break;case 5936:switch(we(e,t+11)){case 114:return te+e+_e+ee(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return te+e+_e+ee(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return te+e+_e+ee(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return te+e+_e+e+e}return e}R(op,"prefix");var TD=R(function(e,t,r,n){if(e.length>-1&&!e.return)switch(e.type){case tp:e.return=op(e.value,e.length);break;case Q4:return an([Pn(e,{value:ee(e.value,"@","@"+te)})],n);case ep:if(e.length)return r3(e.props,function(a){switch(t3(a,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return an([Pn(e,{props:[ee(a,/:(read-\w+)/,":"+wl+"$1")]})],n);case"::placeholder":return an([Pn(e,{props:[ee(a,/:(plac\w+)/,":"+te+"input-$1")]}),Pn(e,{props:[ee(a,/:(plac\w+)/,":"+wl+"$1")]}),Pn(e,{props:[ee(a,/:(plac\w+)/,_e+"input-$1")]})],n)}return""})}},"prefixer"),BD=[TD],zD=R(function(e){var t=e.key;if(!t)throw new Error(`You have to configure \`key\` for your cache. Please make sure it's unique (and not equal to 'css') as it's used for linking styles to your cache. If multiple caches share the same key they might "fight" for each other's style elements.`);if(t==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(v){var g=v.getAttribute("data-emotion");g.indexOf(" ")!==-1&&(document.head.appendChild(v),v.setAttribute("data-s",""))})}var n=e.stylisPlugins||BD;if(/[^a-z-]/.test(t))throw new Error('Emotion key must only contain lower case alphabetical characters and - but "'+t+'" was passed');var a={},o,i=[];o=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(v){for(var g=v.getAttribute("data-emotion").split(" "),w=1;w=4;++n,a-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(a){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}R(m3,"murmur2");var PD={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},yh=`You have illegal escape sequence in your template literal, most likely inside content's property value. Because you write your CSS inside a JavaScript string you actually have to do double escaping, so for example "content: '\\00d7';" should become "content: '\\\\00d7';". @@ -677,7 +677,7 @@ To pass a single animation please supply them in simple values, e.g. animation(' `,77:`remToPx expects a value in "rem" but you provided it in "%s". `,78:`base must be set in "px" or "%" but you set it in "%s". -`};function qL(){for(var e=arguments.length,t=new Array(e),r=0;r1?a-1:0),i=1;i=0&&a<1?(s=o,c=i):a>=1&&a<2?(s=i,c=o):a>=2&&a<3?(c=o,d=i):a>=3&&a<4?(c=i,d=o):a>=4&&a<5?(s=i,d=o):a>=5&&a<6&&(s=o,d=i);var p=r-o/2,m=s+p,h=c+p,f=d+p;return n(m,h,f)}var b4={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function GL(e){if(typeof e!="string")return e;var t=e.toLowerCase();return b4[t]?"#"+b4[t]:e}var YL=/^#[a-fA-F0-9]{6}$/,KL=/^#[a-fA-F0-9]{8}$/,ZL=/^#[a-fA-F0-9]{3}$/,JL=/^#[a-fA-F0-9]{4}$/,N0=/^rgb\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*\)$/i,XL=/^rgb(?:a)?\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i,QL=/^hsl\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*\)$/i,eO=/^hsl(?:a)?\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i;function uu(e){if(typeof e!="string")throw new Ot(3);var t=GL(e);if(t.match(YL))return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16)};if(t.match(KL)){var r=parseFloat((parseInt(""+t[7]+t[8],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16),alpha:r}}if(t.match(ZL))return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16)};if(t.match(JL)){var n=parseFloat((parseInt(""+t[4]+t[4],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16),alpha:n}}var a=N0.exec(t);if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10)};var o=XL.exec(t.substring(0,50));if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10),alpha:parseFloat(""+o[4])>1?parseFloat(""+o[4])/100:parseFloat(""+o[4])};var i=QL.exec(t);if(i){var s=parseInt(""+i[1],10),c=parseInt(""+i[2],10)/100,d=parseInt(""+i[3],10)/100,p="rgb("+qo(s,c,d)+")",m=N0.exec(p);if(!m)throw new Ot(4,t,p);return{red:parseInt(""+m[1],10),green:parseInt(""+m[2],10),blue:parseInt(""+m[3],10)}}var h=eO.exec(t.substring(0,50));if(h){var f=parseInt(""+h[1],10),v=parseInt(""+h[2],10)/100,g=parseInt(""+h[3],10)/100,w="rgb("+qo(f,v,g)+")",x=N0.exec(w);if(!x)throw new Ot(4,t,w);return{red:parseInt(""+x[1],10),green:parseInt(""+x[2],10),blue:parseInt(""+x[3],10),alpha:parseFloat(""+h[4])>1?parseFloat(""+h[4])/100:parseFloat(""+h[4])}}throw new Ot(5)}function tO(e){var t=e.red/255,r=e.green/255,n=e.blue/255,a=Math.max(t,r,n),o=Math.min(t,r,n),i=(a+o)/2;if(a===o)return e.alpha!==void 0?{hue:0,saturation:0,lightness:i,alpha:e.alpha}:{hue:0,saturation:0,lightness:i};var s,c=a-o,d=i>.5?c/(2-a-o):c/(a+o);switch(a){case t:s=(r-n)/c+(r=1?cs(e,t,r):"rgba("+qo(e,t,r)+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?cs(e.hue,e.saturation,e.lightness):"rgba("+qo(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Ot(2)}function M1(e,t,r){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number")return O1("#"+Yr(e)+Yr(t)+Yr(r));if(typeof e=="object"&&t===void 0&&r===void 0)return O1("#"+Yr(e.red)+Yr(e.green)+Yr(e.blue));throw new Ot(6)}function nr(e,t,r,n){if(typeof e=="string"&&typeof t=="number"){var a=uu(e);return"rgba("+a.red+","+a.green+","+a.blue+","+t+")"}else{if(typeof e=="number"&&typeof t=="number"&&typeof r=="number"&&typeof n=="number")return n>=1?M1(e,t,r):"rgba("+e+","+t+","+r+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?M1(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")"}throw new Ot(7)}var iO=function(e){return typeof e.red=="number"&&typeof e.green=="number"&&typeof e.blue=="number"&&(typeof e.alpha!="number"||typeof e.alpha>"u")},lO=function(e){return typeof e.red=="number"&&typeof e.green=="number"&&typeof e.blue=="number"&&typeof e.alpha=="number"},sO=function(e){return typeof e.hue=="number"&&typeof e.saturation=="number"&&typeof e.lightness=="number"&&(typeof e.alpha!="number"||typeof e.alpha>"u")},uO=function(e){return typeof e.hue=="number"&&typeof e.saturation=="number"&&typeof e.lightness=="number"&&typeof e.alpha=="number"};function L9(e){if(typeof e!="object")throw new Ot(8);if(lO(e))return nr(e);if(iO(e))return M1(e);if(uO(e))return oO(e);if(sO(e))return aO(e);throw new Ot(8)}function O9(e,t,r){return function(){var n=r.concat(Array.prototype.slice.call(arguments));return n.length>=t?e.apply(this,n):O9(e,t,n)}}function cu(e){return O9(e,e.length,[])}function du(e,t,r){return Math.max(e,Math.min(t,r))}function cO(e,t){if(t==="transparent")return t;var r=z9(t);return L9(Da({},r,{lightness:du(0,1,r.lightness-parseFloat(e))}))}var dO=cu(cO),Rt=dO;function pO(e,t){if(t==="transparent")return t;var r=z9(t);return L9(Da({},r,{lightness:du(0,1,r.lightness+parseFloat(e))}))}var fO=cu(pO),Kr=fO;function hO(e,t){if(t==="transparent")return t;var r=uu(t),n=typeof r.alpha=="number"?r.alpha:1,a=Da({},r,{alpha:du(0,1,(n*100+parseFloat(e)*100)/100)});return nr(a)}var mO=cu(hO),Yi=mO;function gO(e,t){if(t==="transparent")return t;var r=uu(t),n=typeof r.alpha=="number"?r.alpha:1,a=Da({},r,{alpha:du(0,1,+(n*100-parseFloat(e)*100).toFixed(2)/100)});return nr(a)}var vO=cu(gO),oe=vO,yO=F.div(se,({theme:e})=>({backgroundColor:e.base==="light"?"rgba(0,0,0,.01)":"rgba(255,255,255,.01)",borderRadius:e.appBorderRadius,border:`1px dashed ${e.appBorderColor}`,display:"flex",alignItems:"center",justifyContent:"center",padding:20,margin:"25px 0 40px",color:oe(.3,e.color.defaultText),fontSize:e.typography.size.s2})),M9=e=>y.createElement(yO,{...e,className:"docblock-emptyblock sb-unstyled"}),bO=F(Hf)(({theme:e})=>({fontSize:`${e.typography.size.s2-1}px`,lineHeight:"19px",margin:"25px 0 40px",borderRadius:e.appBorderRadius,boxShadow:e.base==="light"?"rgba(0, 0, 0, 0.10) 0 1px 3px 0":"rgba(0, 0, 0, 0.20) 0 2px 5px 0","pre.prismjs":{padding:20,background:"inherit"}})),wO=F.div(({theme:e})=>({background:e.background.content,borderRadius:e.appBorderRadius,border:`1px solid ${e.appBorderColor}`,boxShadow:e.base==="light"?"rgba(0, 0, 0, 0.10) 0 1px 3px 0":"rgba(0, 0, 0, 0.20) 0 2px 5px 0",margin:"25px 0 40px",padding:"20px 20px 20px 22px"})),Ki=F.div(({theme:e})=>({animation:`${e.animation.glow} 1.5s ease-in-out infinite`,background:e.appBorderColor,height:17,marginTop:1,width:"60%",[`&:first-child${td}`]:{margin:0}})),EO=()=>y.createElement(wO,null,y.createElement(Ki,null),y.createElement(Ki,{style:{width:"80%"}}),y.createElement(Ki,{style:{width:"30%"}}),y.createElement(Ki,{style:{width:"80%"}})),P9=({isLoading:e,error:t,language:r,code:n,dark:a,format:o=!1,...i})=>{let{typography:s}=E3();if(e)return y.createElement(EO,null);if(t)return y.createElement(M9,null,t);let c=y.createElement(bO,{bordered:!0,copyable:!0,format:o,language:r,className:"docblock-source sb-unstyled",...i},n);if(typeof a>"u")return c;let d=a?Q0.dark:Q0.light;return y.createElement(x3,{theme:ed({...d,fontCode:s.fonts.mono,fontBase:s.fonts.base})},c)},he=e=>`& :where(${e}:not(.sb-anchor, .sb-unstyled, .sb-unstyled ${e}))`,Xf=600,xO=F.h1(se,({theme:e})=>({color:e.color.defaultText,fontSize:e.typography.size.m3,fontWeight:e.typography.weight.bold,lineHeight:"32px",[`@media (min-width: ${Xf}px)`]:{fontSize:e.typography.size.l1,lineHeight:"36px",marginBottom:"16px"}})),DO=F.h2(se,({theme:e})=>({fontWeight:e.typography.weight.regular,fontSize:e.typography.size.s3,lineHeight:"20px",borderBottom:"none",marginBottom:15,[`@media (min-width: ${Xf}px)`]:{fontSize:e.typography.size.m1,lineHeight:"28px",marginBottom:24},color:oe(.25,e.color.defaultText)})),CO=F.div(({theme:e})=>{let t={fontFamily:e.typography.fonts.base,fontSize:e.typography.size.s3,margin:0,WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)",WebkitOverflowScrolling:"touch"},r={margin:"20px 0 8px",padding:0,cursor:"text",position:"relative",color:e.color.defaultText,"&:first-of-type":{marginTop:0,paddingTop:0},"&:hover a.anchor":{textDecoration:"none"},"& code":{fontSize:"inherit"}},n={lineHeight:1,margin:"0 2px",padding:"3px 5px",whiteSpace:"nowrap",borderRadius:3,fontSize:e.typography.size.s2-1,border:e.base==="light"?`1px solid ${e.color.mediumlight}`:`1px solid ${e.color.darker}`,color:e.base==="light"?oe(.1,e.color.defaultText):oe(.3,e.color.defaultText),backgroundColor:e.base==="light"?e.color.lighter:e.color.border};return{maxWidth:1e3,width:"100%",[he("a")]:{...t,fontSize:"inherit",lineHeight:"24px",color:e.color.secondary,textDecoration:"none","&.absent":{color:"#cc0000"},"&.anchor":{display:"block",paddingLeft:30,marginLeft:-30,cursor:"pointer",position:"absolute",top:0,left:0,bottom:0}},[he("blockquote")]:{...t,margin:"16px 0",borderLeft:`4px solid ${e.color.medium}`,padding:"0 15px",color:e.color.dark,"& > :first-of-type":{marginTop:0},"& > :last-child":{marginBottom:0}},[he("div")]:t,[he("dl")]:{...t,margin:"16px 0",padding:0,"& dt":{fontSize:"14px",fontWeight:"bold",fontStyle:"italic",padding:0,margin:"16px 0 4px"},"& dt:first-of-type":{padding:0},"& dt > :first-of-type":{marginTop:0},"& dt > :last-child":{marginBottom:0},"& dd":{margin:"0 0 16px",padding:"0 15px"},"& dd > :first-of-type":{marginTop:0},"& dd > :last-child":{marginBottom:0}},[he("h1")]:{...t,...r,fontSize:`${e.typography.size.l1}px`,fontWeight:e.typography.weight.bold},[he("h2")]:{...t,...r,fontSize:`${e.typography.size.m2}px`,paddingBottom:4,borderBottom:`1px solid ${e.appBorderColor}`},[he("h3")]:{...t,...r,fontSize:`${e.typography.size.m1}px`,fontWeight:e.typography.weight.bold},[he("h4")]:{...t,...r,fontSize:`${e.typography.size.s3}px`},[he("h5")]:{...t,...r,fontSize:`${e.typography.size.s2}px`},[he("h6")]:{...t,...r,fontSize:`${e.typography.size.s2}px`,color:e.color.dark},[he("hr")]:{border:"0 none",borderTop:`1px solid ${e.appBorderColor}`,height:4,padding:0},[he("img")]:{maxWidth:"100%"},[he("li")]:{...t,fontSize:e.typography.size.s2,color:e.color.defaultText,lineHeight:"24px","& + li":{marginTop:".25em"},"& ul, & ol":{marginTop:".25em",marginBottom:0},"& code":n},[he("ol")]:{...t,margin:"16px 0",paddingLeft:30,"& :first-of-type":{marginTop:0},"& :last-child":{marginBottom:0}},[he("p")]:{...t,margin:"16px 0",fontSize:e.typography.size.s2,lineHeight:"24px",color:e.color.defaultText,"& code":n},[he("pre")]:{...t,fontFamily:e.typography.fonts.mono,WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",lineHeight:"18px",padding:"11px 1rem",whiteSpace:"pre-wrap",color:"inherit",borderRadius:3,margin:"1rem 0","&:not(.prismjs)":{background:"transparent",border:"none",borderRadius:0,padding:0,margin:0},"& pre, &.prismjs":{padding:15,margin:0,whiteSpace:"pre-wrap",color:"inherit",fontSize:"13px",lineHeight:"19px",code:{color:"inherit",fontSize:"inherit"}},"& code":{whiteSpace:"pre"},"& code, & tt":{border:"none"}},[he("span")]:{...t,"&.frame":{display:"block",overflow:"hidden","& > span":{border:`1px solid ${e.color.medium}`,display:"block",float:"left",overflow:"hidden",margin:"13px 0 0",padding:7,width:"auto"},"& span img":{display:"block",float:"left"},"& span span":{clear:"both",color:e.color.darkest,display:"block",padding:"5px 0 0"}},"&.align-center":{display:"block",overflow:"hidden",clear:"both","& > span":{display:"block",overflow:"hidden",margin:"13px auto 0",textAlign:"center"},"& span img":{margin:"0 auto",textAlign:"center"}},"&.align-right":{display:"block",overflow:"hidden",clear:"both","& > span":{display:"block",overflow:"hidden",margin:"13px 0 0",textAlign:"right"},"& span img":{margin:0,textAlign:"right"}},"&.float-left":{display:"block",marginRight:13,overflow:"hidden",float:"left","& span":{margin:"13px 0 0"}},"&.float-right":{display:"block",marginLeft:13,overflow:"hidden",float:"right","& > span":{display:"block",overflow:"hidden",margin:"13px auto 0",textAlign:"right"}}},[he("table")]:{...t,margin:"16px 0",fontSize:e.typography.size.s2,lineHeight:"24px",padding:0,borderCollapse:"collapse","& tr":{borderTop:`1px solid ${e.appBorderColor}`,backgroundColor:e.appContentBg,margin:0,padding:0},"& tr:nth-of-type(2n)":{backgroundColor:e.base==="dark"?e.color.darker:e.color.lighter},"& tr th":{fontWeight:"bold",color:e.color.defaultText,border:`1px solid ${e.appBorderColor}`,margin:0,padding:"6px 13px"},"& tr td":{border:`1px solid ${e.appBorderColor}`,color:e.color.defaultText,margin:0,padding:"6px 13px"},"& tr th :first-of-type, & tr td :first-of-type":{marginTop:0},"& tr th :last-child, & tr td :last-child":{marginBottom:0}},[he("ul")]:{...t,margin:"16px 0",paddingLeft:30,"& :first-of-type":{marginTop:0},"& :last-child":{marginBottom:0},listStyle:"disc"}}}),SO=F.div(({theme:e})=>({background:e.background.content,display:"flex",justifyContent:"center",padding:"4rem 20px",minHeight:"100vh",boxSizing:"border-box",gap:"3rem",[`@media (min-width: ${Xf}px)`]:{}})),kO=({children:e,toc:t})=>y.createElement(SO,{className:"sbdocs sbdocs-wrapper"},y.createElement(CO,{className:"sbdocs sbdocs-content"},e),t),pu=e=>({borderRadius:e.appBorderRadius,background:e.background.content,boxShadow:e.base==="light"?"rgba(0, 0, 0, 0.10) 0 1px 3px 0":"rgba(0, 0, 0, 0.20) 0 2px 5px 0",border:`1px solid ${e.appBorderColor}`}),{window:AO}=globalThis,FO=class extends l.Component{constructor(){super(...arguments),this.iframe=null}componentDidMount(){let{id:e}=this.props;this.iframe=AO.document.getElementById(e)}shouldComponentUpdate(e){let{scale:t}=e;return t!==this.props.scale&&this.setIframeBodyStyle({width:`${t*100}%`,height:`${t*100}%`,transform:`scale(${1/t})`,transformOrigin:"top left"}),!1}setIframeBodyStyle(e){return Object.assign(this.iframe.contentDocument.body.style,e)}render(){let{id:e,title:t,src:r,allowFullScreen:n,scale:a,...o}=this.props;return y.createElement("iframe",{id:e,title:t,src:r,...n?{allow:"fullscreen"}:{},loading:"lazy",...o})}},$9=l.createContext({scale:1}),{PREVIEW_URL:_O}=globalThis,RO=_O||"iframe.html",P1=({story:e,primary:t})=>`story--${e.id}${t?"--primary":""}`,IO=e=>{let t=l.useRef(),[r,n]=l.useState(!0),[a,o]=l.useState(),{story:i,height:s,autoplay:c,forceInitialArgs:d,renderStoryToElement:p}=e;return l.useEffect(()=>{if(!(i&&t.current))return()=>{};let m=t.current,h=p(i,m,{showMain:()=>{},showError:({title:f,description:v})=>o(new Error(`${f} - ${v}`)),showException:f=>o(f)},{autoplay:c,forceInitialArgs:d});return n(!1),()=>{Promise.resolve().then(()=>h())}},[c,p,i]),a?y.createElement("pre",null,y.createElement(VB,{error:a})):y.createElement(y.Fragment,null,s?y.createElement("style",null,`#${P1(e)} { min-height: ${s}; transform: translateZ(0); overflow: auto }`):null,r&&y.createElement(N9,null),y.createElement("div",{ref:t,id:`${P1(e)}-inner`,"data-name":i.name}))},TO=({story:e,height:t="500px"})=>y.createElement("div",{style:{width:"100%",height:t}},y.createElement($9.Consumer,null,({scale:r})=>y.createElement(FO,{key:"iframe",id:`iframe--${e.id}`,title:e.name,src:pL(RO,e.id,{viewMode:"story"}),allowFullScreen:!0,scale:r,style:{width:"100%",height:"100%",border:"0 none"}}))),BO=F.strong(({theme:e})=>({color:e.color.orange})),zO=e=>{let{inline:t,story:r}=e;return t&&!e.autoplay&&r.usesMount?y.createElement(BO,null,"This story mounts inside of play. Set"," ",y.createElement("a",{href:"https://storybook.js.org/docs/api/doc-blocks/doc-block-story#autoplay"},"autoplay")," ","to true to view this story."):y.createElement("div",{id:P1(e),className:"sb-story sb-unstyled","data-story-block":"true"},t?y.createElement(IO,{...e}):y.createElement(TO,{...e}))},N9=()=>y.createElement(dL,null),LO=F(Zf)({position:"absolute",left:0,right:0,top:0,transition:"transform .2s linear"}),OO=F.div({display:"flex",alignItems:"center",gap:4}),MO=F.div(({theme:e})=>({width:14,height:14,borderRadius:2,margin:"0 7px",backgroundColor:e.appBorderColor,animation:`${e.animation.glow} 1.5s ease-in-out infinite`})),PO=({isLoading:e,storyId:t,baseUrl:r,zoom:n,resetZoom:a,...o})=>y.createElement(LO,{...o},y.createElement(OO,{key:"left"},e?[1,2,3].map(i=>y.createElement(MO,{key:i})):y.createElement(y.Fragment,null,y.createElement(sn,{key:"zoomin",onClick:i=>{i.preventDefault(),n(.8)},title:"Zoom in"},y.createElement(gL,null)),y.createElement(sn,{key:"zoomout",onClick:i=>{i.preventDefault(),n(1.25)},title:"Zoom out"},y.createElement(vL,null)),y.createElement(sn,{key:"zoomreset",onClick:i=>{i.preventDefault(),a()},title:"Reset zoom"},y.createElement(yL,null))))),$O=F.div(({isColumn:e,columns:t,layout:r})=>({display:e||!t?"block":"flex",position:"relative",flexWrap:"wrap",overflow:"auto",flexDirection:e?"column":"row","& .innerZoomElementWrapper > *":e?{width:r!=="fullscreen"?"calc(100% - 20px)":"100%",display:"block"}:{maxWidth:r!=="fullscreen"?"calc(100% - 20px)":"100%",display:"inline-block"}}),({layout:e="padded"})=>e==="centered"||e==="padded"?{padding:"30px 20px","& .innerZoomElementWrapper > *":{width:"auto",border:"10px solid transparent!important"}}:{},({layout:e="padded"})=>e==="centered"?{display:"flex",justifyContent:"center",justifyItems:"center",alignContent:"center",alignItems:"center"}:{},({columns:e})=>e&&e>1?{".innerZoomElementWrapper > *":{minWidth:`calc(100% / ${e} - 20px)`}}:{}),w4=F(P9)(({theme:e})=>({margin:0,borderTopLeftRadius:0,borderTopRightRadius:0,borderBottomLeftRadius:e.appBorderRadius,borderBottomRightRadius:e.appBorderRadius,border:"none",background:e.base==="light"?"rgba(0, 0, 0, 0.85)":Rt(.05,e.background.content),color:e.color.lightest,button:{background:e.base==="light"?"rgba(0, 0, 0, 0.85)":Rt(.05,e.background.content)}})),NO=F.div(({theme:e,withSource:t,isExpanded:r})=>({position:"relative",overflow:"hidden",margin:"25px 0 40px",...pu(e),borderBottomLeftRadius:t&&r&&0,borderBottomRightRadius:t&&r&&0,borderBottomWidth:r&&0,"h3 + &":{marginTop:"16px"}}),({withToolbar:e})=>e&&{paddingTop:40}),HO=(e,t,r)=>{switch(!0){case!!(e&&e.error):return{source:null,actionItem:{title:"No code available",className:"docblock-code-toggle docblock-code-toggle--disabled",disabled:!0,onClick:()=>r(!1)}};case t:return{source:y.createElement(w4,{...e,dark:!0}),actionItem:{title:"Hide code",className:"docblock-code-toggle docblock-code-toggle--expanded",onClick:()=>r(!1)}};default:return{source:y.createElement(w4,{...e,dark:!0}),actionItem:{title:"Show code",className:"docblock-code-toggle",onClick:()=>r(!0)}}}};function jO(e){if(l.Children.count(e)===1){let t=e;if(t.props)return t.props.id}return null}var VO=F(PO)({position:"absolute",top:0,left:0,right:0,height:40}),UO=F.div({overflow:"hidden",position:"relative"}),H9=({isLoading:e,isColumn:t,columns:r,children:n,withSource:a,withToolbar:o=!1,isExpanded:i=!1,additionalActions:s,className:c,layout:d="padded",...p})=>{let[m,h]=l.useState(i),{source:f,actionItem:v}=HO(a,m,h),[g,w]=l.useState(1),x=[c].concat(["sbdocs","sbdocs-preview","sb-unstyled"]),D=a?[v]:[],[E,b]=l.useState(s?[...s]:[]),C=[...D,...E],{window:S}=globalThis,k=l.useCallback(async _=>{let{createCopyToClipboardFunction:I}=await G1(()=>import("./index-C_34dRtw.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8]),import.meta.url);I()},[]),A=_=>{let I=S.getSelection();I&&I.type==="Range"||(_.preventDefault(),E.filter(T=>T.title==="Copied").length===0&&k(f.props.code).then(()=>{b([...E,{title:"Copied",onClick:()=>{}}]),S.setTimeout(()=>b(E.filter(T=>T.title!=="Copied")),1500)}))};return y.createElement(NO,{withSource:a,withToolbar:o,...p,className:x.join(" ")},o&&y.createElement(VO,{isLoading:e,border:!0,zoom:_=>w(g*_),resetZoom:()=>w(1),storyId:jO(n),baseUrl:"./iframe.html"}),y.createElement($9.Provider,{value:{scale:g}},y.createElement(UO,{className:"docs-story",onCopyCapture:a&&A},y.createElement($O,{isColumn:t||!Array.isArray(n),columns:r,layout:d},y.createElement(LB.Element,{scale:g},Array.isArray(n)?n.map((_,I)=>y.createElement("div",{key:I},_)):y.createElement("div",null,n))),y.createElement(Dp,{actionItems:C}))),a&&m&&f)};F(H9)(()=>({".docs-story":{paddingTop:32,paddingBottom:40}}));function Jr(){return Jr=Object.assign?Object.assign.bind():function(e){for(var t=1;t(e[t.toLowerCase()]=t,e),{for:"htmlFor"}),C4={amp:"&",apos:"'",gt:">",lt:"<",nbsp:" ",quot:"“"},WO=["style","script"],GO=/([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi,YO=/mailto:/i,KO=/\n{2,}$/,j9=/^(\s*>[\s\S]*?)(?=\n{2,})/,ZO=/^ *> ?/gm,JO=/^ {2,}\n/,XO=/^(?:( *[-*_])){3,} *(?:\n *)+\n/,V9=/^\s*(`{3,}|~{3,}) *(\S+)?([^\n]*?)?\n([\s\S]+?)\s*\1 *(?:\n *)*\n?/,U9=/^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/,QO=/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,eM=/^(?:\n *)*\n/,tM=/\r\n?/g,rM=/^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/,nM=/^\[\^([^\]]+)]/,aM=/\f/g,oM=/^---[ \t]*\n(.|\n)*\n---[ \t]*\n/,iM=/^\s*?\[(x|\s)\]/,q9=/^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,W9=/^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,G9=/^([^\n]+)\n *(=|-){3,} *(?:\n *)+\n/,$1=/^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?([^>]*)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i,lM=/&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi,Y9=/^)/,sM=/^(data|aria|x)-[a-z_][a-z\d_.-]*$/,N1=/^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i,uM=/^\{.*\}$/,cM=/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,dM=/^<([^ >]+@[^ >]+)>/,pM=/^<([^ >]+:\/[^ >]+)>/,fM=/-([a-z])?/gi,K9=/^(.*\|?.*)\n *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*)\n?/,hM=/^\[([^\]]*)\]:\s+]+)>?\s*("([^"]*)")?/,mM=/^!\[([^\]]*)\] ?\[([^\]]*)\]/,gM=/^\[([^\]]*)\] ?\[([^\]]*)\]/,vM=/(\[|\])/g,yM=/(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/,bM=/\t/g,wM=/^ *\| */,EM=/(^ *\||\| *$)/g,xM=/ *$/,DM=/^ *:-+: *$/,CM=/^ *:-+ *$/,SM=/^ *-+: *$/,fu="((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|~~.*?~~|==.*?==|.|\\n)*?)",kM=new RegExp(`^([*_])\\1${fu}\\1\\1(?!\\1)`),AM=new RegExp(`^([*_])${fu}\\1(?!\\1|\\w)`),FM=new RegExp(`^==${fu}==`),_M=new RegExp(`^~~${fu}~~`),RM=/^\\([^0-9A-Za-z\s])/,IM=/^[\s\S]+?(?=[^0-9A-Z\s\u00c0-\uffff&#;.()'"]|\d+\.|\n\n| {2,}\n|\w+:\S|$)/i,TM=/^\n+/,BM=/^([ \t]*)/,zM=/\\([^\\])/g,S4=/ *\n+$/,LM=/(?:^|\n)( *)$/,Qf="(?:\\d+\\.)",eh="(?:[*+-])";function Z9(e){return"( *)("+(e===1?Qf:eh)+") +"}var J9=Z9(1),X9=Z9(2);function Q9(e){return new RegExp("^"+(e===1?J9:X9))}var OM=Q9(1),MM=Q9(2);function ex(e){return new RegExp("^"+(e===1?J9:X9)+"[^\\n]*(?:\\n(?!\\1"+(e===1?Qf:eh)+" )[^\\n]*)*(\\n|$)","gm")}var tx=ex(1),rx=ex(2);function nx(e){let t=e===1?Qf:eh;return new RegExp("^( *)("+t+") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1"+t+" (?!"+t+" ))\\n*|\\s*\\n*$)")}var ax=nx(1),ox=nx(2);function k4(e,t){let r=t===1,n=r?ax:ox,a=r?tx:rx,o=r?OM:MM;return{match(i,s,c){let d=LM.exec(c);return d&&(s.list||!s.inline&&!s.simple)?n.exec(i=d[1]+i):null},order:1,parse(i,s,c){let d=r?+i[2]:void 0,p=i[0].replace(KO,` +`};function qL(){for(var e=arguments.length,t=new Array(e),r=0;r1?a-1:0),i=1;i=0&&a<1?(s=o,c=i):a>=1&&a<2?(s=i,c=o):a>=2&&a<3?(c=o,d=i):a>=3&&a<4?(c=i,d=o):a>=4&&a<5?(s=i,d=o):a>=5&&a<6&&(s=o,d=i);var p=r-o/2,m=s+p,h=c+p,f=d+p;return n(m,h,f)}var b4={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function GL(e){if(typeof e!="string")return e;var t=e.toLowerCase();return b4[t]?"#"+b4[t]:e}var YL=/^#[a-fA-F0-9]{6}$/,KL=/^#[a-fA-F0-9]{8}$/,ZL=/^#[a-fA-F0-9]{3}$/,JL=/^#[a-fA-F0-9]{4}$/,N0=/^rgb\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*\)$/i,XL=/^rgb(?:a)?\(\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,)?\s*(\d{1,3})\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i,QL=/^hsl\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*\)$/i,eO=/^hsl(?:a)?\(\s*(\d{0,3}[.]?[0-9]+(?:deg)?)\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,)?\s*(\d{1,3}[.]?[0-9]?)%\s*(?:,|\/)\s*([-+]?\d*[.]?\d+[%]?)\s*\)$/i;function uu(e){if(typeof e!="string")throw new Ot(3);var t=GL(e);if(t.match(YL))return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16)};if(t.match(KL)){var r=parseFloat((parseInt(""+t[7]+t[8],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[2],16),green:parseInt(""+t[3]+t[4],16),blue:parseInt(""+t[5]+t[6],16),alpha:r}}if(t.match(ZL))return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16)};if(t.match(JL)){var n=parseFloat((parseInt(""+t[4]+t[4],16)/255).toFixed(2));return{red:parseInt(""+t[1]+t[1],16),green:parseInt(""+t[2]+t[2],16),blue:parseInt(""+t[3]+t[3],16),alpha:n}}var a=N0.exec(t);if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10)};var o=XL.exec(t.substring(0,50));if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10),alpha:parseFloat(""+o[4])>1?parseFloat(""+o[4])/100:parseFloat(""+o[4])};var i=QL.exec(t);if(i){var s=parseInt(""+i[1],10),c=parseInt(""+i[2],10)/100,d=parseInt(""+i[3],10)/100,p="rgb("+qo(s,c,d)+")",m=N0.exec(p);if(!m)throw new Ot(4,t,p);return{red:parseInt(""+m[1],10),green:parseInt(""+m[2],10),blue:parseInt(""+m[3],10)}}var h=eO.exec(t.substring(0,50));if(h){var f=parseInt(""+h[1],10),v=parseInt(""+h[2],10)/100,g=parseInt(""+h[3],10)/100,w="rgb("+qo(f,v,g)+")",x=N0.exec(w);if(!x)throw new Ot(4,t,w);return{red:parseInt(""+x[1],10),green:parseInt(""+x[2],10),blue:parseInt(""+x[3],10),alpha:parseFloat(""+h[4])>1?parseFloat(""+h[4])/100:parseFloat(""+h[4])}}throw new Ot(5)}function tO(e){var t=e.red/255,r=e.green/255,n=e.blue/255,a=Math.max(t,r,n),o=Math.min(t,r,n),i=(a+o)/2;if(a===o)return e.alpha!==void 0?{hue:0,saturation:0,lightness:i,alpha:e.alpha}:{hue:0,saturation:0,lightness:i};var s,c=a-o,d=i>.5?c/(2-a-o):c/(a+o);switch(a){case t:s=(r-n)/c+(r=1?cs(e,t,r):"rgba("+qo(e,t,r)+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?cs(e.hue,e.saturation,e.lightness):"rgba("+qo(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Ot(2)}function M1(e,t,r){if(typeof e=="number"&&typeof t=="number"&&typeof r=="number")return O1("#"+Yr(e)+Yr(t)+Yr(r));if(typeof e=="object"&&t===void 0&&r===void 0)return O1("#"+Yr(e.red)+Yr(e.green)+Yr(e.blue));throw new Ot(6)}function nr(e,t,r,n){if(typeof e=="string"&&typeof t=="number"){var a=uu(e);return"rgba("+a.red+","+a.green+","+a.blue+","+t+")"}else{if(typeof e=="number"&&typeof t=="number"&&typeof r=="number"&&typeof n=="number")return n>=1?M1(e,t,r):"rgba("+e+","+t+","+r+","+n+")";if(typeof e=="object"&&t===void 0&&r===void 0&&n===void 0)return e.alpha>=1?M1(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")"}throw new Ot(7)}var iO=function(e){return typeof e.red=="number"&&typeof e.green=="number"&&typeof e.blue=="number"&&(typeof e.alpha!="number"||typeof e.alpha>"u")},lO=function(e){return typeof e.red=="number"&&typeof e.green=="number"&&typeof e.blue=="number"&&typeof e.alpha=="number"},sO=function(e){return typeof e.hue=="number"&&typeof e.saturation=="number"&&typeof e.lightness=="number"&&(typeof e.alpha!="number"||typeof e.alpha>"u")},uO=function(e){return typeof e.hue=="number"&&typeof e.saturation=="number"&&typeof e.lightness=="number"&&typeof e.alpha=="number"};function L9(e){if(typeof e!="object")throw new Ot(8);if(lO(e))return nr(e);if(iO(e))return M1(e);if(uO(e))return oO(e);if(sO(e))return aO(e);throw new Ot(8)}function O9(e,t,r){return function(){var n=r.concat(Array.prototype.slice.call(arguments));return n.length>=t?e.apply(this,n):O9(e,t,n)}}function cu(e){return O9(e,e.length,[])}function du(e,t,r){return Math.max(e,Math.min(t,r))}function cO(e,t){if(t==="transparent")return t;var r=z9(t);return L9(Da({},r,{lightness:du(0,1,r.lightness-parseFloat(e))}))}var dO=cu(cO),Rt=dO;function pO(e,t){if(t==="transparent")return t;var r=z9(t);return L9(Da({},r,{lightness:du(0,1,r.lightness+parseFloat(e))}))}var fO=cu(pO),Kr=fO;function hO(e,t){if(t==="transparent")return t;var r=uu(t),n=typeof r.alpha=="number"?r.alpha:1,a=Da({},r,{alpha:du(0,1,(n*100+parseFloat(e)*100)/100)});return nr(a)}var mO=cu(hO),Yi=mO;function gO(e,t){if(t==="transparent")return t;var r=uu(t),n=typeof r.alpha=="number"?r.alpha:1,a=Da({},r,{alpha:du(0,1,+(n*100-parseFloat(e)*100).toFixed(2)/100)});return nr(a)}var vO=cu(gO),oe=vO,yO=F.div(se,({theme:e})=>({backgroundColor:e.base==="light"?"rgba(0,0,0,.01)":"rgba(255,255,255,.01)",borderRadius:e.appBorderRadius,border:`1px dashed ${e.appBorderColor}`,display:"flex",alignItems:"center",justifyContent:"center",padding:20,margin:"25px 0 40px",color:oe(.3,e.color.defaultText),fontSize:e.typography.size.s2})),M9=e=>y.createElement(yO,{...e,className:"docblock-emptyblock sb-unstyled"}),bO=F(Hf)(({theme:e})=>({fontSize:`${e.typography.size.s2-1}px`,lineHeight:"19px",margin:"25px 0 40px",borderRadius:e.appBorderRadius,boxShadow:e.base==="light"?"rgba(0, 0, 0, 0.10) 0 1px 3px 0":"rgba(0, 0, 0, 0.20) 0 2px 5px 0","pre.prismjs":{padding:20,background:"inherit"}})),wO=F.div(({theme:e})=>({background:e.background.content,borderRadius:e.appBorderRadius,border:`1px solid ${e.appBorderColor}`,boxShadow:e.base==="light"?"rgba(0, 0, 0, 0.10) 0 1px 3px 0":"rgba(0, 0, 0, 0.20) 0 2px 5px 0",margin:"25px 0 40px",padding:"20px 20px 20px 22px"})),Ki=F.div(({theme:e})=>({animation:`${e.animation.glow} 1.5s ease-in-out infinite`,background:e.appBorderColor,height:17,marginTop:1,width:"60%",[`&:first-child${td}`]:{margin:0}})),EO=()=>y.createElement(wO,null,y.createElement(Ki,null),y.createElement(Ki,{style:{width:"80%"}}),y.createElement(Ki,{style:{width:"30%"}}),y.createElement(Ki,{style:{width:"80%"}})),P9=({isLoading:e,error:t,language:r,code:n,dark:a,format:o=!1,...i})=>{let{typography:s}=E3();if(e)return y.createElement(EO,null);if(t)return y.createElement(M9,null,t);let c=y.createElement(bO,{bordered:!0,copyable:!0,format:o,language:r,className:"docblock-source sb-unstyled",...i},n);if(typeof a>"u")return c;let d=a?Q0.dark:Q0.light;return y.createElement(x3,{theme:ed({...d,fontCode:s.fonts.mono,fontBase:s.fonts.base})},c)},he=e=>`& :where(${e}:not(.sb-anchor, .sb-unstyled, .sb-unstyled ${e}))`,Xf=600,xO=F.h1(se,({theme:e})=>({color:e.color.defaultText,fontSize:e.typography.size.m3,fontWeight:e.typography.weight.bold,lineHeight:"32px",[`@media (min-width: ${Xf}px)`]:{fontSize:e.typography.size.l1,lineHeight:"36px",marginBottom:"16px"}})),DO=F.h2(se,({theme:e})=>({fontWeight:e.typography.weight.regular,fontSize:e.typography.size.s3,lineHeight:"20px",borderBottom:"none",marginBottom:15,[`@media (min-width: ${Xf}px)`]:{fontSize:e.typography.size.m1,lineHeight:"28px",marginBottom:24},color:oe(.25,e.color.defaultText)})),CO=F.div(({theme:e})=>{let t={fontFamily:e.typography.fonts.base,fontSize:e.typography.size.s3,margin:0,WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)",WebkitOverflowScrolling:"touch"},r={margin:"20px 0 8px",padding:0,cursor:"text",position:"relative",color:e.color.defaultText,"&:first-of-type":{marginTop:0,paddingTop:0},"&:hover a.anchor":{textDecoration:"none"},"& code":{fontSize:"inherit"}},n={lineHeight:1,margin:"0 2px",padding:"3px 5px",whiteSpace:"nowrap",borderRadius:3,fontSize:e.typography.size.s2-1,border:e.base==="light"?`1px solid ${e.color.mediumlight}`:`1px solid ${e.color.darker}`,color:e.base==="light"?oe(.1,e.color.defaultText):oe(.3,e.color.defaultText),backgroundColor:e.base==="light"?e.color.lighter:e.color.border};return{maxWidth:1e3,width:"100%",[he("a")]:{...t,fontSize:"inherit",lineHeight:"24px",color:e.color.secondary,textDecoration:"none","&.absent":{color:"#cc0000"},"&.anchor":{display:"block",paddingLeft:30,marginLeft:-30,cursor:"pointer",position:"absolute",top:0,left:0,bottom:0}},[he("blockquote")]:{...t,margin:"16px 0",borderLeft:`4px solid ${e.color.medium}`,padding:"0 15px",color:e.color.dark,"& > :first-of-type":{marginTop:0},"& > :last-child":{marginBottom:0}},[he("div")]:t,[he("dl")]:{...t,margin:"16px 0",padding:0,"& dt":{fontSize:"14px",fontWeight:"bold",fontStyle:"italic",padding:0,margin:"16px 0 4px"},"& dt:first-of-type":{padding:0},"& dt > :first-of-type":{marginTop:0},"& dt > :last-child":{marginBottom:0},"& dd":{margin:"0 0 16px",padding:"0 15px"},"& dd > :first-of-type":{marginTop:0},"& dd > :last-child":{marginBottom:0}},[he("h1")]:{...t,...r,fontSize:`${e.typography.size.l1}px`,fontWeight:e.typography.weight.bold},[he("h2")]:{...t,...r,fontSize:`${e.typography.size.m2}px`,paddingBottom:4,borderBottom:`1px solid ${e.appBorderColor}`},[he("h3")]:{...t,...r,fontSize:`${e.typography.size.m1}px`,fontWeight:e.typography.weight.bold},[he("h4")]:{...t,...r,fontSize:`${e.typography.size.s3}px`},[he("h5")]:{...t,...r,fontSize:`${e.typography.size.s2}px`},[he("h6")]:{...t,...r,fontSize:`${e.typography.size.s2}px`,color:e.color.dark},[he("hr")]:{border:"0 none",borderTop:`1px solid ${e.appBorderColor}`,height:4,padding:0},[he("img")]:{maxWidth:"100%"},[he("li")]:{...t,fontSize:e.typography.size.s2,color:e.color.defaultText,lineHeight:"24px","& + li":{marginTop:".25em"},"& ul, & ol":{marginTop:".25em",marginBottom:0},"& code":n},[he("ol")]:{...t,margin:"16px 0",paddingLeft:30,"& :first-of-type":{marginTop:0},"& :last-child":{marginBottom:0}},[he("p")]:{...t,margin:"16px 0",fontSize:e.typography.size.s2,lineHeight:"24px",color:e.color.defaultText,"& code":n},[he("pre")]:{...t,fontFamily:e.typography.fonts.mono,WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",lineHeight:"18px",padding:"11px 1rem",whiteSpace:"pre-wrap",color:"inherit",borderRadius:3,margin:"1rem 0","&:not(.prismjs)":{background:"transparent",border:"none",borderRadius:0,padding:0,margin:0},"& pre, &.prismjs":{padding:15,margin:0,whiteSpace:"pre-wrap",color:"inherit",fontSize:"13px",lineHeight:"19px",code:{color:"inherit",fontSize:"inherit"}},"& code":{whiteSpace:"pre"},"& code, & tt":{border:"none"}},[he("span")]:{...t,"&.frame":{display:"block",overflow:"hidden","& > span":{border:`1px solid ${e.color.medium}`,display:"block",float:"left",overflow:"hidden",margin:"13px 0 0",padding:7,width:"auto"},"& span img":{display:"block",float:"left"},"& span span":{clear:"both",color:e.color.darkest,display:"block",padding:"5px 0 0"}},"&.align-center":{display:"block",overflow:"hidden",clear:"both","& > span":{display:"block",overflow:"hidden",margin:"13px auto 0",textAlign:"center"},"& span img":{margin:"0 auto",textAlign:"center"}},"&.align-right":{display:"block",overflow:"hidden",clear:"both","& > span":{display:"block",overflow:"hidden",margin:"13px 0 0",textAlign:"right"},"& span img":{margin:0,textAlign:"right"}},"&.float-left":{display:"block",marginRight:13,overflow:"hidden",float:"left","& span":{margin:"13px 0 0"}},"&.float-right":{display:"block",marginLeft:13,overflow:"hidden",float:"right","& > span":{display:"block",overflow:"hidden",margin:"13px auto 0",textAlign:"right"}}},[he("table")]:{...t,margin:"16px 0",fontSize:e.typography.size.s2,lineHeight:"24px",padding:0,borderCollapse:"collapse","& tr":{borderTop:`1px solid ${e.appBorderColor}`,backgroundColor:e.appContentBg,margin:0,padding:0},"& tr:nth-of-type(2n)":{backgroundColor:e.base==="dark"?e.color.darker:e.color.lighter},"& tr th":{fontWeight:"bold",color:e.color.defaultText,border:`1px solid ${e.appBorderColor}`,margin:0,padding:"6px 13px"},"& tr td":{border:`1px solid ${e.appBorderColor}`,color:e.color.defaultText,margin:0,padding:"6px 13px"},"& tr th :first-of-type, & tr td :first-of-type":{marginTop:0},"& tr th :last-child, & tr td :last-child":{marginBottom:0}},[he("ul")]:{...t,margin:"16px 0",paddingLeft:30,"& :first-of-type":{marginTop:0},"& :last-child":{marginBottom:0},listStyle:"disc"}}}),SO=F.div(({theme:e})=>({background:e.background.content,display:"flex",justifyContent:"center",padding:"4rem 20px",minHeight:"100vh",boxSizing:"border-box",gap:"3rem",[`@media (min-width: ${Xf}px)`]:{}})),kO=({children:e,toc:t})=>y.createElement(SO,{className:"sbdocs sbdocs-wrapper"},y.createElement(CO,{className:"sbdocs sbdocs-content"},e),t),pu=e=>({borderRadius:e.appBorderRadius,background:e.background.content,boxShadow:e.base==="light"?"rgba(0, 0, 0, 0.10) 0 1px 3px 0":"rgba(0, 0, 0, 0.20) 0 2px 5px 0",border:`1px solid ${e.appBorderColor}`}),{window:AO}=globalThis,FO=class extends l.Component{constructor(){super(...arguments),this.iframe=null}componentDidMount(){let{id:e}=this.props;this.iframe=AO.document.getElementById(e)}shouldComponentUpdate(e){let{scale:t}=e;return t!==this.props.scale&&this.setIframeBodyStyle({width:`${t*100}%`,height:`${t*100}%`,transform:`scale(${1/t})`,transformOrigin:"top left"}),!1}setIframeBodyStyle(e){return Object.assign(this.iframe.contentDocument.body.style,e)}render(){let{id:e,title:t,src:r,allowFullScreen:n,scale:a,...o}=this.props;return y.createElement("iframe",{id:e,title:t,src:r,...n?{allow:"fullscreen"}:{},loading:"lazy",...o})}},$9=l.createContext({scale:1}),{PREVIEW_URL:_O}=globalThis,RO=_O||"iframe.html",P1=({story:e,primary:t})=>`story--${e.id}${t?"--primary":""}`,IO=e=>{let t=l.useRef(),[r,n]=l.useState(!0),[a,o]=l.useState(),{story:i,height:s,autoplay:c,forceInitialArgs:d,renderStoryToElement:p}=e;return l.useEffect(()=>{if(!(i&&t.current))return()=>{};let m=t.current,h=p(i,m,{showMain:()=>{},showError:({title:f,description:v})=>o(new Error(`${f} - ${v}`)),showException:f=>o(f)},{autoplay:c,forceInitialArgs:d});return n(!1),()=>{Promise.resolve().then(()=>h())}},[c,p,i]),a?y.createElement("pre",null,y.createElement(VB,{error:a})):y.createElement(y.Fragment,null,s?y.createElement("style",null,`#${P1(e)} { min-height: ${s}; transform: translateZ(0); overflow: auto }`):null,r&&y.createElement(N9,null),y.createElement("div",{ref:t,id:`${P1(e)}-inner`,"data-name":i.name}))},TO=({story:e,height:t="500px"})=>y.createElement("div",{style:{width:"100%",height:t}},y.createElement($9.Consumer,null,({scale:r})=>y.createElement(FO,{key:"iframe",id:`iframe--${e.id}`,title:e.name,src:pL(RO,e.id,{viewMode:"story"}),allowFullScreen:!0,scale:r,style:{width:"100%",height:"100%",border:"0 none"}}))),BO=F.strong(({theme:e})=>({color:e.color.orange})),zO=e=>{let{inline:t,story:r}=e;return t&&!e.autoplay&&r.usesMount?y.createElement(BO,null,"This story mounts inside of play. Set"," ",y.createElement("a",{href:"https://storybook.js.org/docs/api/doc-blocks/doc-block-story#autoplay"},"autoplay")," ","to true to view this story."):y.createElement("div",{id:P1(e),className:"sb-story sb-unstyled","data-story-block":"true"},t?y.createElement(IO,{...e}):y.createElement(TO,{...e}))},N9=()=>y.createElement(dL,null),LO=F(Zf)({position:"absolute",left:0,right:0,top:0,transition:"transform .2s linear"}),OO=F.div({display:"flex",alignItems:"center",gap:4}),MO=F.div(({theme:e})=>({width:14,height:14,borderRadius:2,margin:"0 7px",backgroundColor:e.appBorderColor,animation:`${e.animation.glow} 1.5s ease-in-out infinite`})),PO=({isLoading:e,storyId:t,baseUrl:r,zoom:n,resetZoom:a,...o})=>y.createElement(LO,{...o},y.createElement(OO,{key:"left"},e?[1,2,3].map(i=>y.createElement(MO,{key:i})):y.createElement(y.Fragment,null,y.createElement(sn,{key:"zoomin",onClick:i=>{i.preventDefault(),n(.8)},title:"Zoom in"},y.createElement(gL,null)),y.createElement(sn,{key:"zoomout",onClick:i=>{i.preventDefault(),n(1.25)},title:"Zoom out"},y.createElement(vL,null)),y.createElement(sn,{key:"zoomreset",onClick:i=>{i.preventDefault(),a()},title:"Reset zoom"},y.createElement(yL,null))))),$O=F.div(({isColumn:e,columns:t,layout:r})=>({display:e||!t?"block":"flex",position:"relative",flexWrap:"wrap",overflow:"auto",flexDirection:e?"column":"row","& .innerZoomElementWrapper > *":e?{width:r!=="fullscreen"?"calc(100% - 20px)":"100%",display:"block"}:{maxWidth:r!=="fullscreen"?"calc(100% - 20px)":"100%",display:"inline-block"}}),({layout:e="padded"})=>e==="centered"||e==="padded"?{padding:"30px 20px","& .innerZoomElementWrapper > *":{width:"auto",border:"10px solid transparent!important"}}:{},({layout:e="padded"})=>e==="centered"?{display:"flex",justifyContent:"center",justifyItems:"center",alignContent:"center",alignItems:"center"}:{},({columns:e})=>e&&e>1?{".innerZoomElementWrapper > *":{minWidth:`calc(100% / ${e} - 20px)`}}:{}),w4=F(P9)(({theme:e})=>({margin:0,borderTopLeftRadius:0,borderTopRightRadius:0,borderBottomLeftRadius:e.appBorderRadius,borderBottomRightRadius:e.appBorderRadius,border:"none",background:e.base==="light"?"rgba(0, 0, 0, 0.85)":Rt(.05,e.background.content),color:e.color.lightest,button:{background:e.base==="light"?"rgba(0, 0, 0, 0.85)":Rt(.05,e.background.content)}})),NO=F.div(({theme:e,withSource:t,isExpanded:r})=>({position:"relative",overflow:"hidden",margin:"25px 0 40px",...pu(e),borderBottomLeftRadius:t&&r&&0,borderBottomRightRadius:t&&r&&0,borderBottomWidth:r&&0,"h3 + &":{marginTop:"16px"}}),({withToolbar:e})=>e&&{paddingTop:40}),HO=(e,t,r)=>{switch(!0){case!!(e&&e.error):return{source:null,actionItem:{title:"No code available",className:"docblock-code-toggle docblock-code-toggle--disabled",disabled:!0,onClick:()=>r(!1)}};case t:return{source:y.createElement(w4,{...e,dark:!0}),actionItem:{title:"Hide code",className:"docblock-code-toggle docblock-code-toggle--expanded",onClick:()=>r(!1)}};default:return{source:y.createElement(w4,{...e,dark:!0}),actionItem:{title:"Show code",className:"docblock-code-toggle",onClick:()=>r(!0)}}}};function jO(e){if(l.Children.count(e)===1){let t=e;if(t.props)return t.props.id}return null}var VO=F(PO)({position:"absolute",top:0,left:0,right:0,height:40}),UO=F.div({overflow:"hidden",position:"relative"}),H9=({isLoading:e,isColumn:t,columns:r,children:n,withSource:a,withToolbar:o=!1,isExpanded:i=!1,additionalActions:s,className:c,layout:d="padded",...p})=>{let[m,h]=l.useState(i),{source:f,actionItem:v}=HO(a,m,h),[g,w]=l.useState(1),x=[c].concat(["sbdocs","sbdocs-preview","sb-unstyled"]),D=a?[v]:[],[E,b]=l.useState(s?[...s]:[]),C=[...D,...E],{window:S}=globalThis,k=l.useCallback(async _=>{let{createCopyToClipboardFunction:I}=await G1(()=>import("./index-zGZrE8kf.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8]),import.meta.url);I()},[]),A=_=>{let I=S.getSelection();I&&I.type==="Range"||(_.preventDefault(),E.filter(T=>T.title==="Copied").length===0&&k(f.props.code).then(()=>{b([...E,{title:"Copied",onClick:()=>{}}]),S.setTimeout(()=>b(E.filter(T=>T.title!=="Copied")),1500)}))};return y.createElement(NO,{withSource:a,withToolbar:o,...p,className:x.join(" ")},o&&y.createElement(VO,{isLoading:e,border:!0,zoom:_=>w(g*_),resetZoom:()=>w(1),storyId:jO(n),baseUrl:"./iframe.html"}),y.createElement($9.Provider,{value:{scale:g}},y.createElement(UO,{className:"docs-story",onCopyCapture:a&&A},y.createElement($O,{isColumn:t||!Array.isArray(n),columns:r,layout:d},y.createElement(LB.Element,{scale:g},Array.isArray(n)?n.map((_,I)=>y.createElement("div",{key:I},_)):y.createElement("div",null,n))),y.createElement(Dp,{actionItems:C}))),a&&m&&f)};F(H9)(()=>({".docs-story":{paddingTop:32,paddingBottom:40}}));function Jr(){return Jr=Object.assign?Object.assign.bind():function(e){for(var t=1;t(e[t.toLowerCase()]=t,e),{for:"htmlFor"}),C4={amp:"&",apos:"'",gt:">",lt:"<",nbsp:" ",quot:"“"},WO=["style","script"],GO=/([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi,YO=/mailto:/i,KO=/\n{2,}$/,j9=/^(\s*>[\s\S]*?)(?=\n{2,})/,ZO=/^ *> ?/gm,JO=/^ {2,}\n/,XO=/^(?:( *[-*_])){3,} *(?:\n *)+\n/,V9=/^\s*(`{3,}|~{3,}) *(\S+)?([^\n]*?)?\n([\s\S]+?)\s*\1 *(?:\n *)*\n?/,U9=/^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/,QO=/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,eM=/^(?:\n *)*\n/,tM=/\r\n?/g,rM=/^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/,nM=/^\[\^([^\]]+)]/,aM=/\f/g,oM=/^---[ \t]*\n(.|\n)*\n---[ \t]*\n/,iM=/^\s*?\[(x|\s)\]/,q9=/^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,W9=/^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,G9=/^([^\n]+)\n *(=|-){3,} *(?:\n *)+\n/,$1=/^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?([^>]*)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i,lM=/&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi,Y9=/^)/,sM=/^(data|aria|x)-[a-z_][a-z\d_.-]*$/,N1=/^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i,uM=/^\{.*\}$/,cM=/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,dM=/^<([^ >]+@[^ >]+)>/,pM=/^<([^ >]+:\/[^ >]+)>/,fM=/-([a-z])?/gi,K9=/^(.*\|?.*)\n *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*)\n?/,hM=/^\[([^\]]*)\]:\s+]+)>?\s*("([^"]*)")?/,mM=/^!\[([^\]]*)\] ?\[([^\]]*)\]/,gM=/^\[([^\]]*)\] ?\[([^\]]*)\]/,vM=/(\[|\])/g,yM=/(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/,bM=/\t/g,wM=/^ *\| */,EM=/(^ *\||\| *$)/g,xM=/ *$/,DM=/^ *:-+: *$/,CM=/^ *:-+ *$/,SM=/^ *-+: *$/,fu="((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|~~.*?~~|==.*?==|.|\\n)*?)",kM=new RegExp(`^([*_])\\1${fu}\\1\\1(?!\\1)`),AM=new RegExp(`^([*_])${fu}\\1(?!\\1|\\w)`),FM=new RegExp(`^==${fu}==`),_M=new RegExp(`^~~${fu}~~`),RM=/^\\([^0-9A-Za-z\s])/,IM=/^[\s\S]+?(?=[^0-9A-Z\s\u00c0-\uffff&#;.()'"]|\d+\.|\n\n| {2,}\n|\w+:\S|$)/i,TM=/^\n+/,BM=/^([ \t]*)/,zM=/\\([^\\])/g,S4=/ *\n+$/,LM=/(?:^|\n)( *)$/,Qf="(?:\\d+\\.)",eh="(?:[*+-])";function Z9(e){return"( *)("+(e===1?Qf:eh)+") +"}var J9=Z9(1),X9=Z9(2);function Q9(e){return new RegExp("^"+(e===1?J9:X9))}var OM=Q9(1),MM=Q9(2);function ex(e){return new RegExp("^"+(e===1?J9:X9)+"[^\\n]*(?:\\n(?!\\1"+(e===1?Qf:eh)+" )[^\\n]*)*(\\n|$)","gm")}var tx=ex(1),rx=ex(2);function nx(e){let t=e===1?Qf:eh;return new RegExp("^( *)("+t+") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1"+t+" (?!"+t+" ))\\n*|\\s*\\n*$)")}var ax=nx(1),ox=nx(2);function k4(e,t){let r=t===1,n=r?ax:ox,a=r?tx:rx,o=r?OM:MM;return{match(i,s,c){let d=LM.exec(c);return d&&(s.list||!s.inline&&!s.simple)?n.exec(i=d[1]+i):null},order:1,parse(i,s,c){let d=r?+i[2]:void 0,p=i[0].replace(KO,` `).match(a),m=!1;return{items:p.map(function(h,f){let v=o.exec(h)[0].length,g=new RegExp("^ {1,"+v+"}","gm"),w=h.replace(g,"").replace(o,""),x=f===p.length-1,D=w.indexOf(` `)!==-1||x&&m;m=D;let E=c.inline,b=c.list,C;c.list=!0,D?(c.inline=!1,C=w.replace(S4,` @@ -708,7 +708,7 @@ To pass a single animation please supply them in simple values, e.g. animation(' ${Rt(.02,e.input.background)} 100%)`:`linear-gradient(to right, ${e.color.green} 0%, ${e.color.green} ${(n-t)/(r-t)*100}%, ${Kr(.02,e.input.background)} ${(n-t)/(r-t)*100}%, - ${Kr(.02,e.input.background)} 100%)`,boxShadow:`${e.appBorderColor} 0 0 0 1px inset`,color:"transparent",width:"100%",height:"6px",cursor:"pointer"},"&::-ms-fill-lower":{borderRadius:6},"&::-ms-fill-upper":{borderRadius:6},"&::-ms-thumb":{width:16,height:16,background:`${e.input.background}`,border:`1px solid ${nr(e.appBorderColor,.2)}`,borderRadius:50,cursor:"grab",marginTop:0},"@supports (-ms-ime-align:auto)":{"input[type=range]":{margin:"0"}}})),bx=F.span({paddingLeft:5,paddingRight:5,fontSize:12,whiteSpace:"nowrap",fontFeatureSettings:"tnum",fontVariantNumeric:"tabular-nums","[aria-readonly=true] &":{opacity:.5}}),WP=F(bx)(({numberOFDecimalsPlaces:e,max:t})=>({width:`${e+t.toString().length*2+3}ch`,textAlign:"right",flexShrink:0})),GP=F.div({display:"flex",alignItems:"center",width:"100%"});function YP(e){let t=e.toString().match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return t?Math.max(0,(t[1]?t[1].length:0)-(t[2]?+t[2]:0)):0}var KP=({name:e,value:t,onChange:r,min:n=0,max:a=100,step:o=1,onBlur:i,onFocus:s,argType:c})=>{let d=f=>{r(oP(f.target.value))},p=t!==void 0,m=l.useMemo(()=>YP(o),[o]),h=!!c?.table?.readonly;return y.createElement(GP,{"aria-readonly":h},y.createElement(bx,null,n),y.createElement(qP,{id:vt(e),type:"range",disabled:h,onChange:d,name:e,value:t,min:n,max:a,step:o,onFocus:s,onBlur:i}),y.createElement(WP,{numberOFDecimalsPlaces:m,max:a},p?t.toFixed(m):"--"," / ",a))},ZP=F.label({display:"flex"}),JP=F.div(({isMaxed:e})=>({marginLeft:"0.75rem",paddingTop:"0.35rem",color:e?"red":void 0})),XP=({name:e,value:t,onChange:r,onFocus:n,onBlur:a,maxLength:o,argType:i})=>{let s=f=>{r(f.target.value)},c=!!i?.table?.readonly,[d,p]=l.useState(!1),m=l.useCallback(()=>{r(""),p(!0)},[p]);if(t===void 0)return y.createElement(Sn,{variant:"outline",size:"medium",disabled:c,id:ps(e),onClick:m},"Set string");let h=typeof t=="string";return y.createElement(ZP,null,y.createElement(mi.Textarea,{id:vt(e),maxLength:o,onChange:s,disabled:c,size:"flex",placeholder:"Edit string...",autoFocus:d,valid:h?null:"error",name:e,value:h?t:"",onFocus:n,onBlur:a}),o&&y.createElement(JP,{isMaxed:t?.length===o},t?.length??0," / ",o))},QP=F(mi.Input)({padding:10});function e$(e){e.forEach(t=>{t.startsWith("blob:")&&URL.revokeObjectURL(t)})}var t$=({onChange:e,name:t,accept:r="image/*",value:n,argType:a})=>{let o=l.useRef(null),i=a?.control?.readOnly;function s(c){if(!c.target.files)return;let d=Array.from(c.target.files).map(p=>URL.createObjectURL(p));e(d),e$(n)}return l.useEffect(()=>{n==null&&o.current&&(o.current.value=null)},[n,t]),y.createElement(QP,{ref:o,id:vt(t),type:"file",name:t,multiple:!0,disabled:i,onChange:s,accept:r,size:"flex"})},r$=l.lazy(()=>G1(()=>import("./Color-F6OSRLHC-CsBEHEVI.js"),__vite__mapDeps([9,2,1,3,4,5,6,7,8]),import.meta.url)),n$=e=>y.createElement(l.Suspense,{fallback:y.createElement("div",null)},y.createElement(r$,{...e})),a$={array:O4,object:O4,boolean:JM,color:n$,date:nP,number:lP,check:Mn,"inline-check":Mn,radio:Mn,"inline-radio":Mn,select:Mn,"multi-select":Mn,range:KP,text:XP,file:t$},M4=()=>y.createElement(y.Fragment,null,"-"),o$=({row:e,arg:t,updateArgs:r,isHovered:n})=>{let{key:a,control:o}=e,[i,s]=l.useState(!1),[c,d]=l.useState({value:t});l.useEffect(()=>{i||d({value:t})},[i,t]);let p=l.useCallback(g=>(d({value:g}),r({[a]:g}),g),[r,a]),m=l.useCallback(()=>s(!1),[]),h=l.useCallback(()=>s(!0),[]);if(!o||o.disable){let g=o?.disable!==!0&&e?.type?.name!=="function";return n&&g?y.createElement(aa,{href:"https://storybook.js.org/docs/essentials/controls",target:"_blank",withArrow:!0},"Setup controls"):y.createElement(M4,null)}let f={name:a,argType:e,value:c.value,onChange:p,onBlur:m,onFocus:h},v=a$[o.type]||M4;return y.createElement(v,{...f,...o,controlType:o.type})},i$=F.table(({theme:e})=>({"&&":{borderCollapse:"collapse",borderSpacing:0,border:"none",tr:{border:"none !important",background:"none"},"td, th":{padding:0,border:"none",width:"auto!important"},marginTop:0,marginBottom:0,"th:first-of-type, td:first-of-type":{paddingLeft:0},"th:last-of-type, td:last-of-type":{paddingRight:0},td:{paddingTop:0,paddingBottom:4,"&:not(:first-of-type)":{paddingLeft:10,paddingRight:0}},tbody:{boxShadow:"none",border:"none"},code:Lr({theme:e}),div:{span:{fontWeight:"bold"}},"& code":{margin:0,display:"inline-block",fontSize:e.typography.size.s1}}})),l$=({tags:e})=>{let t=(e.params||[]).filter(o=>o.description),r=t.length!==0,n=e.deprecated!=null,a=e.returns!=null&&e.returns.description!=null;return!r&&!a&&!n?null:y.createElement(y.Fragment,null,y.createElement(i$,null,y.createElement("tbody",null,n&&y.createElement("tr",{key:"deprecated"},y.createElement("td",{colSpan:2},y.createElement("strong",null,"Deprecated"),": ",e.deprecated.toString())),r&&t.map(o=>y.createElement("tr",{key:o.name},y.createElement("td",null,y.createElement("code",null,o.name)),y.createElement("td",null,o.description))),a&&y.createElement("tr",{key:"returns"},y.createElement("td",null,y.createElement("code",null,"Returns")),y.createElement("td",null,e.returns.description)))))},s$=Y1(T9()),V1=8,P4=F.div(({isExpanded:e})=>({display:"flex",flexDirection:e?"column":"row",flexWrap:"wrap",alignItems:"flex-start",marginBottom:"-4px",minWidth:100})),u$=F.span(Lr,({theme:e,simple:t=!1})=>({flex:"0 0 auto",fontFamily:e.typography.fonts.mono,fontSize:e.typography.size.s1,wordBreak:"break-word",whiteSpace:"normal",maxWidth:"100%",margin:0,marginRight:"4px",marginBottom:"4px",paddingTop:"2px",paddingBottom:"2px",lineHeight:"13px",...t&&{background:"transparent",border:"0 none",paddingLeft:0}})),c$=F.button(({theme:e})=>({fontFamily:e.typography.fonts.mono,color:e.color.secondary,marginBottom:"4px",background:"none",border:"none"})),d$=F.div(Lr,({theme:e})=>({fontFamily:e.typography.fonts.mono,color:e.color.secondary,fontSize:e.typography.size.s1,margin:0,whiteSpace:"nowrap",display:"flex",alignItems:"center"})),p$=F.div(({theme:e,width:t})=>({width:t,minWidth:200,maxWidth:800,padding:15,fontFamily:e.typography.fonts.mono,fontSize:e.typography.size.s1,boxSizing:"content-box","& code":{padding:"0 !important"}})),f$=F(AL)({marginLeft:4}),h$=F(I9)({marginLeft:4}),m$=()=>y.createElement("span",null,"-"),wx=({text:e,simple:t})=>y.createElement(u$,{simple:t},e),g$=(0,s$.default)(1e3)(e=>{let t=e.split(/\r?\n/);return`${Math.max(...t.map(r=>r.length))}ch`}),v$=e=>{if(!e)return[e];let t=e.split("|").map(r=>r.trim());return Xx(t)},$4=(e,t=!0)=>{let r=e;return t||(r=e.slice(0,V1)),r.map(n=>y.createElement(wx,{key:n,text:n===""?'""':n}))},y$=({value:e,initialExpandedArgs:t})=>{let{summary:r,detail:n}=e,[a,o]=l.useState(!1),[i,s]=l.useState(t||!1);if(r==null)return null;let c=typeof r.toString=="function"?r.toString():r;if(n==null){if(/[(){}[\]<>]/.test(c))return y.createElement(wx,{text:c});let d=v$(c),p=d.length;return p>V1?y.createElement(P4,{isExpanded:i},$4(d,i),y.createElement(c$,{onClick:()=>s(!i)},i?"Show less...":`Show ${p-V1} more...`)):y.createElement(P4,null,$4(d))}return y.createElement(mz,{closeOnOutsideClick:!0,placement:"bottom",visible:a,onVisibleChange:d=>{o(d)},tooltip:y.createElement(p$,{width:g$(n)},y.createElement(Hf,{language:"jsx",format:!1},n))},y.createElement(d$,{className:"sbdocs-expandable"},y.createElement("span",null,c),a?y.createElement(f$,null):y.createElement(h$,null)))},G0=({value:e,initialExpandedArgs:t})=>e==null?y.createElement(m$,null):y.createElement(y$,{value:e,initialExpandedArgs:t}),b$=F.span({fontWeight:"bold"}),w$=F.span(({theme:e})=>({color:e.color.negative,fontFamily:e.typography.fonts.mono,cursor:"help"})),E$=F.div(({theme:e})=>({"&&":{p:{margin:"0 0 10px 0"},a:{color:e.color.secondary}},code:{...Lr({theme:e}),fontSize:12,fontFamily:e.typography.fonts.mono},"& code":{margin:0,display:"inline-block"},"& pre > code":{whiteSpace:"pre-wrap"}})),x$=F.div(({theme:e,hasDescription:t})=>({color:e.base==="light"?oe(.1,e.color.defaultText):oe(.2,e.color.defaultText),marginTop:t?4:0})),D$=F.div(({theme:e,hasDescription:t})=>({color:e.base==="light"?oe(.1,e.color.defaultText):oe(.2,e.color.defaultText),marginTop:t?12:0,marginBottom:12})),C$=F.td(({theme:e,expandable:t})=>({paddingLeft:t?"40px !important":"20px !important"})),S$=e=>e&&{summary:typeof e=="string"?e:e.name},Zi=e=>{let[t,r]=l.useState(!1),{row:n,updateArgs:a,compact:o,expandable:i,initialExpandedArgs:s}=e,{name:c,description:d}=n,p=n.table||{},m=p.type||S$(n.type),h=p.defaultValue||n.defaultValue,f=n.type?.required,v=d!=null&&d!=="";return y.createElement("tr",{onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1)},y.createElement(C$,{expandable:i},y.createElement(b$,null,c),f?y.createElement(w$,{title:"Required"},"*"):null),o?null:y.createElement("td",null,v&&y.createElement(E$,null,y.createElement(lx,null,d)),p.jsDocTags!=null?y.createElement(y.Fragment,null,y.createElement(D$,{hasDescription:v},y.createElement(G0,{value:m,initialExpandedArgs:s})),y.createElement(l$,{tags:p.jsDocTags})):y.createElement(x$,{hasDescription:v},y.createElement(G0,{value:m,initialExpandedArgs:s}))),o?null:y.createElement("td",null,y.createElement(G0,{value:h,initialExpandedArgs:s})),a?y.createElement("td",null,y.createElement(o$,{...e,isHovered:t})):null)},k$=F.div(({inAddonPanel:e,theme:t})=>({height:e?"100%":"auto",display:"flex",border:e?"none":`1px solid ${t.appBorderColor}`,borderRadius:e?0:t.appBorderRadius,padding:e?0:40,alignItems:"center",justifyContent:"center",flexDirection:"column",gap:15,background:t.background.content,boxShadow:"rgba(0, 0, 0, 0.10) 0 1px 3px 0"})),A$=F.div(({theme:e})=>({display:"flex",fontSize:e.typography.size.s2-1,gap:25})),F$=F.div(({theme:e})=>({width:1,height:16,backgroundColor:e.appBorderColor})),_$=({inAddonPanel:e})=>{let[t,r]=l.useState(!0);return l.useEffect(()=>{let n=setTimeout(()=>{r(!1)},100);return()=>clearTimeout(n)},[]),t?null:y.createElement(k$,{inAddonPanel:e},y.createElement(C9,{title:e?"Interactive story playground":"Args table with interactive controls couldn't be auto-generated",description:y.createElement(y.Fragment,null,"Controls give you an easy to use interface to test your components. Set your story args and you'll see controls appearing here automatically."),footer:y.createElement(A$,null,e&&y.createElement(y.Fragment,null,y.createElement(aa,{href:"https://youtu.be/0gOfS6K0x0E",target:"_blank",withArrow:!0},y.createElement(EL,null)," Watch 5m video"),y.createElement(F$,null),y.createElement(aa,{href:"https://storybook.js.org/docs/essentials/controls",target:"_blank",withArrow:!0},y.createElement(B1,null)," Read docs")),!e&&y.createElement(aa,{href:"https://storybook.js.org/docs/essentials/controls",target:"_blank",withArrow:!0},y.createElement(B1,null)," Learn how to set that up"))}))},R$=F(SL)(({theme:e})=>({marginRight:8,marginLeft:-10,marginTop:-2,height:12,width:12,color:e.base==="light"?oe(.25,e.color.defaultText):oe(.3,e.color.defaultText),border:"none",display:"inline-block"})),I$=F(kL)(({theme:e})=>({marginRight:8,marginLeft:-10,marginTop:-2,height:12,width:12,color:e.base==="light"?oe(.25,e.color.defaultText):oe(.3,e.color.defaultText),border:"none",display:"inline-block"})),T$=F.span(({theme:e})=>({display:"flex",lineHeight:"20px",alignItems:"center"})),B$=F.td(({theme:e})=>({position:"relative",letterSpacing:"0.35em",textTransform:"uppercase",fontWeight:e.typography.weight.bold,fontSize:e.typography.size.s1-1,color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText),background:`${e.background.app} !important`,"& ~ td":{background:`${e.background.app} !important`}})),z$=F.td(({theme:e})=>({position:"relative",fontWeight:e.typography.weight.bold,fontSize:e.typography.size.s2-1,background:e.background.app})),L$=F.td(()=>({position:"relative"})),O$=F.tr(({theme:e})=>({"&:hover > td":{backgroundColor:`${Kr(.005,e.background.app)} !important`,boxShadow:`${e.color.mediumlight} 0 - 1px 0 0 inset`,cursor:"row-resize"}})),N4=F.button(()=>({background:"none",border:"none",padding:"0",font:"inherit",position:"absolute",top:0,bottom:0,left:0,right:0,height:"100%",width:"100%",color:"transparent",cursor:"row-resize !important"})),Y0=({level:e="section",label:t,children:r,initialExpanded:n=!0,colSpan:a=3})=>{let[o,i]=l.useState(n),s=e==="subsection"?z$:B$,c=r?.length||0,d=e==="subsection"?`${c} item${c!==1?"s":""}`:"",p=`${o?"Hide":"Show"} ${e==="subsection"?c:t} item${c!==1?"s":""}`;return y.createElement(y.Fragment,null,y.createElement(O$,{title:p},y.createElement(s,{colSpan:1},y.createElement(N4,{onClick:m=>i(!o),tabIndex:0},p),y.createElement(T$,null,o?y.createElement(R$,null):y.createElement(I$,null),t)),y.createElement(L$,{colSpan:a-1},y.createElement(N4,{onClick:m=>i(!o),tabIndex:-1,style:{outline:"none"}},p),o?null:d)),o?r:null)},Ji=F.div(({theme:e})=>({display:"flex",gap:16,borderBottom:`1px solid ${e.appBorderColor}`,"&:last-child":{borderBottom:0}})),Ae=F.div(({numColumn:e})=>({display:"flex",flexDirection:"column",flex:e||1,gap:5,padding:"12px 20px"})),me=F.div(({theme:e,width:t,height:r})=>({animation:`${e.animation.glow} 1.5s ease-in-out infinite`,background:e.appBorderColor,width:t||"100%",height:r||16,borderRadius:3})),Fe=[2,4,2,2],M$=()=>y.createElement(y.Fragment,null,y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"}))),y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"80%"}),y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"}))),y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"80%"}),y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"}))),y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"80%"}),y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"})))),P$=F.table(({theme:e,compact:t,inAddonPanel:r})=>({"&&":{borderSpacing:0,color:e.color.defaultText,"td, th":{padding:0,border:"none",verticalAlign:"top",textOverflow:"ellipsis"},fontSize:e.typography.size.s2-1,lineHeight:"20px",textAlign:"left",width:"100%",marginTop:r?0:25,marginBottom:r?0:40,"thead th:first-of-type, td:first-of-type":{width:"25%"},"th:first-of-type, td:first-of-type":{paddingLeft:20},"th:nth-of-type(2), td:nth-of-type(2)":{...t?null:{width:"35%"}},"td:nth-of-type(3)":{...t?null:{width:"15%"}},"th:last-of-type, td:last-of-type":{paddingRight:20,...t?null:{width:"25%"}},th:{color:e.base==="light"?oe(.25,e.color.defaultText):oe(.45,e.color.defaultText),paddingTop:10,paddingBottom:10,paddingLeft:15,paddingRight:15},td:{paddingTop:"10px",paddingBottom:"10px","&:not(:first-of-type)":{paddingLeft:15,paddingRight:15},"&:last-of-type":{paddingRight:20}},marginLeft:r?0:1,marginRight:r?0:1,tbody:{...r?null:{filter:e.base==="light"?"drop-shadow(0px 1px 3px rgba(0, 0, 0, 0.10))":"drop-shadow(0px 1px 3px rgba(0, 0, 0, 0.20))"},"> tr > *":{background:e.background.content,borderTop:`1px solid ${e.appBorderColor}`},...r?null:{"> tr:first-of-type > *":{borderBlockStart:`1px solid ${e.appBorderColor}`},"> tr:last-of-type > *":{borderBlockEnd:`1px solid ${e.appBorderColor}`},"> tr > *:first-of-type":{borderInlineStart:`1px solid ${e.appBorderColor}`},"> tr > *:last-of-type":{borderInlineEnd:`1px solid ${e.appBorderColor}`},"> tr:first-of-type > td:first-of-type":{borderTopLeftRadius:e.appBorderRadius},"> tr:first-of-type > td:last-of-type":{borderTopRightRadius:e.appBorderRadius},"> tr:last-of-type > td:first-of-type":{borderBottomLeftRadius:e.appBorderRadius},"> tr:last-of-type > td:last-of-type":{borderBottomRightRadius:e.appBorderRadius}}}}})),$$=F(sn)(({theme:e})=>({margin:"-4px -12px -4px 0"})),N$=F.span({display:"flex",justifyContent:"space-between"}),H$={alpha:(e,t)=>e.name.localeCompare(t.name),requiredFirst:(e,t)=>+!!t.type?.required-+!!e.type?.required||e.name.localeCompare(t.name),none:void 0},j$=(e,t)=>{let r={ungrouped:[],ungroupedSubsections:{},sections:{}};if(!e)return r;Object.entries(e).forEach(([o,i])=>{let{category:s,subcategory:c}=i?.table||{};if(s){let d=r.sections[s]||{ungrouped:[],subsections:{}};if(!c)d.ungrouped.push({key:o,...i});else{let p=d.subsections[c]||[];p.push({key:o,...i}),d.subsections[c]=p}r.sections[s]=d}else if(c){let d=r.ungroupedSubsections[c]||[];d.push({key:o,...i}),r.ungroupedSubsections[c]=d}else r.ungrouped.push({key:o,...i})});let n=H$[t],a=o=>n?Object.keys(o).reduce((i,s)=>({...i,[s]:o[s].sort(n)}),{}):o;return{ungrouped:r.ungrouped.sort(n),ungroupedSubsections:a(r.ungroupedSubsections),sections:Object.keys(r.sections).reduce((o,i)=>({...o,[i]:{ungrouped:r.sections[i].ungrouped.sort(n),subsections:a(r.sections[i].subsections)}}),{})}},V$=(e,t,r)=>{try{return jx(e,t,r)}catch(n){return RL.warn(n.message),!1}},U1=e=>{let{updateArgs:t,resetArgs:r,compact:n,inAddonPanel:a,initialExpandedArgs:o,sort:i="none",isLoading:s}=e;if("error"in e){let{error:D}=e;return y.createElement(M9,null,D," ",y.createElement(aa,{href:"http://storybook.js.org/docs/",target:"_blank",withArrow:!0},y.createElement(B1,null)," Read the docs"))}if(s)return y.createElement(M$,null);let{rows:c,args:d,globals:p}="rows"in e&&e,m=j$(Qx(c||{},D=>!D?.table?.disable&&V$(D,d||{},p||{})),i),h=m.ungrouped.length===0,f=Object.entries(m.sections).length===0,v=Object.entries(m.ungroupedSubsections).length===0;if(h&&f&&v)return y.createElement(_$,{inAddonPanel:a});let g=1;t&&(g+=1),n||(g+=2);let w=Object.keys(m.sections).length>0,x={updateArgs:t,compact:n,inAddonPanel:a,initialExpandedArgs:o};return y.createElement(N8,null,y.createElement(P$,{compact:n,inAddonPanel:a,className:"docblock-argstable sb-unstyled"},y.createElement("thead",{className:"docblock-argstable-head"},y.createElement("tr",null,y.createElement("th",null,y.createElement("span",null,"Name")),n?null:y.createElement("th",null,y.createElement("span",null,"Description")),n?null:y.createElement("th",null,y.createElement("span",null,"Default")),t?y.createElement("th",null,y.createElement(N$,null,"Control"," ",!s&&r&&y.createElement($$,{onClick:()=>r(),title:"Reset controls"},y.createElement(FL,{"aria-hidden":!0})))):null)),y.createElement("tbody",{className:"docblock-argstable-body"},m.ungrouped.map(D=>y.createElement(Zi,{key:D.key,row:D,arg:d&&d[D.key],...x})),Object.entries(m.ungroupedSubsections).map(([D,E])=>y.createElement(Y0,{key:D,label:D,level:"subsection",colSpan:g},E.map(b=>y.createElement(Zi,{key:b.key,row:b,arg:d&&d[b.key],expandable:w,...x})))),Object.entries(m.sections).map(([D,E])=>y.createElement(Y0,{key:D,label:D,level:"section",colSpan:g},E.ungrouped.map(b=>y.createElement(Zi,{key:b.key,row:b,arg:d&&d[b.key],...x})),Object.entries(E.subsections).map(([b,C])=>y.createElement(Y0,{key:b,label:b,level:"subsection",colSpan:g},C.map(S=>y.createElement(Zi,{key:S.key,row:S,arg:d&&d[S.key],expandable:w,...x})))))))))},U$=({tabs:e,...t})=>{let r=Object.entries(e);return r.length===1?y.createElement(U1,{...r[0][1],...t}):y.createElement(Jz,null,r.map((n,a)=>{let[o,i]=n,s=`prop_table_div_${o}`,c="div",d=a===0?t:{sort:t.sort};return y.createElement(c,{key:s,id:s,title:o},({active:p})=>p?y.createElement(U1,{key:`prop_table_${o}`,...i,...d}):null)}))};F.div(({theme:e})=>({marginRight:30,fontSize:`${e.typography.size.s1}px`,color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText)}));F.div({overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"});F.div({display:"flex",flexDirection:"row",alignItems:"baseline","&:not(:last-child)":{marginBottom:"1rem"}});F.div(se,({theme:e})=>({...pu(e),margin:"25px 0 40px",padding:"30px 20px"}));F.div(({theme:e})=>({fontWeight:e.typography.weight.bold,color:e.color.defaultText}));F.div(({theme:e})=>({color:e.base==="light"?oe(.2,e.color.defaultText):oe(.6,e.color.defaultText)}));F.div({flex:"0 0 30%",lineHeight:"20px",marginTop:5});F.div(({theme:e})=>({flex:1,textAlign:"center",fontFamily:e.typography.fonts.mono,fontSize:e.typography.size.s1,lineHeight:1,overflow:"hidden",color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText),"> div":{display:"inline-block",overflow:"hidden",maxWidth:"100%",textOverflow:"ellipsis"},span:{display:"block",marginTop:2}}));F.div({display:"flex",flexDirection:"row"});F.div(({background:e})=>({position:"relative",flex:1,"&::before":{position:"absolute",top:0,left:0,width:"100%",height:"100%",background:e,content:'""'}}));F.div(({theme:e})=>({...pu(e),display:"flex",flexDirection:"row",height:50,marginBottom:5,overflow:"hidden",backgroundColor:"white",backgroundImage:"repeating-linear-gradient(-45deg, #ccc, #ccc 1px, #fff 1px, #fff 16px)",backgroundClip:"padding-box"}));F.div({display:"flex",flexDirection:"column",flex:1,position:"relative",marginBottom:30});F.div({flex:1,display:"flex",flexDirection:"row"});F.div({display:"flex",alignItems:"flex-start"});F.div({flex:"0 0 30%"});F.div({flex:1});F.div(({theme:e})=>({display:"flex",flexDirection:"row",alignItems:"center",paddingBottom:20,fontWeight:e.typography.weight.bold,color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText)}));F.div(({theme:e})=>({fontSize:e.typography.size.s2,lineHeight:"20px",display:"flex",flexDirection:"column"}));F.div(({theme:e})=>({fontFamily:e.typography.fonts.base,fontSize:e.typography.size.s2,color:e.color.defaultText,marginLeft:10,lineHeight:1.2}));F.div(({theme:e})=>({...pu(e),overflow:"hidden",height:40,width:40,display:"flex",alignItems:"center",justifyContent:"center",flex:"none","> img, > svg":{width:20,height:20}}));F.div({display:"inline-flex",flexDirection:"row",alignItems:"center",flex:"0 1 calc(20% - 10px)",minWidth:120,margin:"0px 10px 30px 0"});F.div({display:"flex",flexFlow:"row wrap"});var q$=e=>`anchor--${e}`,W$=({storyId:e,children:t})=>y.createElement("div",{id:q$(e),className:"sb-anchor"},t);globalThis&&globalThis.__DOCS_CONTEXT__===void 0&&(globalThis.__DOCS_CONTEXT__=l.createContext(null),globalThis.__DOCS_CONTEXT__.displayName="DocsContext");var Yt=globalThis?globalThis.__DOCS_CONTEXT__:l.createContext(null),kn=(e,t)=>l.useContext(Yt).resolveOf(e,t),G$=e=>e.split("-").map(t=>t.charAt(0).toUpperCase()+t.slice(1)).join(""),Y$=e=>{if(e)return typeof e=="string"?e.includes("-")?G$(e):e:e.__docgenInfo&&e.__docgenInfo.displayName?e.__docgenInfo.displayName:e.name};function K$(e,t="start"){e.scrollIntoView({behavior:"smooth",block:t,inline:"nearest"})}var Z$=Object.create,Ex=Object.defineProperty,J$=Object.getOwnPropertyDescriptor,xx=Object.getOwnPropertyNames,X$=Object.getPrototypeOf,Q$=Object.prototype.hasOwnProperty,et=(e,t)=>function(){return t||(0,e[xx(e)[0]])((t={exports:{}}).exports,t),t.exports},eN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of xx(t))!Q$.call(e,a)&&a!==r&&Ex(e,a,{get:()=>t[a],enumerable:!(n=J$(t,a))||n.enumerable});return e},nh=(e,t,r)=>(r=e!=null?Z$(X$(e)):{},eN(!e||!e.__esModule?Ex(r,"default",{value:e,enumerable:!0}):r,e)),tN=["bubbles","cancelBubble","cancelable","composed","currentTarget","defaultPrevented","eventPhase","isTrusted","returnValue","srcElement","target","timeStamp","type"],rN=["detail"];function nN(e){let t=tN.filter(r=>e[r]!==void 0).reduce((r,n)=>({...r,[n]:e[n]}),{});return e instanceof CustomEvent&&rN.filter(r=>e[r]!==void 0).forEach(r=>{t[r]=e[r]}),t}var aN=Y1(T9(),1),Dx=et({"node_modules/has-symbols/shams.js"(e,t){t.exports=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var r={},n=Symbol("test"),a=Object(n);if(typeof n=="string"||Object.prototype.toString.call(n)!=="[object Symbol]"||Object.prototype.toString.call(a)!=="[object Symbol]")return!1;var o=42;r[n]=o;for(n in r)return!1;if(typeof Object.keys=="function"&&Object.keys(r).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(r).length!==0)return!1;var i=Object.getOwnPropertySymbols(r);if(i.length!==1||i[0]!==n||!Object.prototype.propertyIsEnumerable.call(r,n))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var s=Object.getOwnPropertyDescriptor(r,n);if(s.value!==o||s.enumerable!==!0)return!1}return!0}}}),Cx=et({"node_modules/has-symbols/index.js"(e,t){var r=typeof Symbol<"u"&&Symbol,n=Dx();t.exports=function(){return typeof r!="function"||typeof Symbol!="function"||typeof r("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:n()}}}),oN=et({"node_modules/function-bind/implementation.js"(e,t){var r="Function.prototype.bind called on incompatible ",n=Array.prototype.slice,a=Object.prototype.toString,o="[object Function]";t.exports=function(i){var s=this;if(typeof s!="function"||a.call(s)!==o)throw new TypeError(r+s);for(var c=n.call(arguments,1),d,p=function(){if(this instanceof d){var g=s.apply(this,c.concat(n.call(arguments)));return Object(g)===g?g:this}else return s.apply(i,c.concat(n.call(arguments)))},m=Math.max(0,s.length-c.length),h=[],f=0;f"u"?r:m(Uint8Array),v={"%AggregateError%":typeof AggregateError>"u"?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?r:ArrayBuffer,"%ArrayIteratorPrototype%":p?m([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":h,"%AsyncGenerator%":h,"%AsyncGeneratorFunction%":h,"%AsyncIteratorPrototype%":h,"%Atomics%":typeof Atomics>"u"?r:Atomics,"%BigInt%":typeof BigInt>"u"?r:BigInt,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?r:Float32Array,"%Float64Array%":typeof Float64Array>"u"?r:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?r:FinalizationRegistry,"%Function%":a,"%GeneratorFunction%":h,"%Int8Array%":typeof Int8Array>"u"?r:Int8Array,"%Int16Array%":typeof Int16Array>"u"?r:Int16Array,"%Int32Array%":typeof Int32Array>"u"?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":p?m(m([][Symbol.iterator]())):r,"%JSON%":typeof JSON=="object"?JSON:r,"%Map%":typeof Map>"u"?r:Map,"%MapIteratorPrototype%":typeof Map>"u"||!p?r:m(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?r:Promise,"%Proxy%":typeof Proxy>"u"?r:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?r:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?r:Set,"%SetIteratorPrototype%":typeof Set>"u"||!p?r:m(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":p?m(""[Symbol.iterator]()):r,"%Symbol%":p?Symbol:r,"%SyntaxError%":n,"%ThrowTypeError%":d,"%TypedArray%":f,"%TypeError%":o,"%Uint8Array%":typeof Uint8Array>"u"?r:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?r:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?r:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?r:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?r:WeakMap,"%WeakRef%":typeof WeakRef>"u"?r:WeakRef,"%WeakSet%":typeof WeakSet>"u"?r:WeakSet},g=function z(L){var M;if(L==="%AsyncFunction%")M=i("async function () {}");else if(L==="%GeneratorFunction%")M=i("function* () {}");else if(L==="%AsyncGeneratorFunction%")M=i("async function* () {}");else if(L==="%AsyncGenerator%"){var O=z("%AsyncGeneratorFunction%");O&&(M=O.prototype)}else if(L==="%AsyncIteratorPrototype%"){var P=z("%AsyncGenerator%");P&&(M=m(P.prototype))}return v[L]=M,M},w={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},x=ah(),D=iN(),E=x.call(Function.call,Array.prototype.concat),b=x.call(Function.apply,Array.prototype.splice),C=x.call(Function.call,String.prototype.replace),S=x.call(Function.call,String.prototype.slice),k=x.call(Function.call,RegExp.prototype.exec),A=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,_=/\\(\\)?/g,I=function(z){var L=S(z,0,1),M=S(z,-1);if(L==="%"&&M!=="%")throw new n("invalid intrinsic syntax, expected closing `%`");if(M==="%"&&L!=="%")throw new n("invalid intrinsic syntax, expected opening `%`");var O=[];return C(z,A,function(P,j,U,V){O[O.length]=U?C(V,_,"$1"):j||P}),O},T=function(z,L){var M=z,O;if(D(w,M)&&(O=w[M],M="%"+O[0]+"%"),D(v,M)){var P=v[M];if(P===h&&(P=g(M)),typeof P>"u"&&!L)throw new o("intrinsic "+z+" exists, but is not available. Please file an issue!");return{alias:O,name:M,value:P}}throw new n("intrinsic "+z+" does not exist!")};t.exports=function(z,L){if(typeof z!="string"||z.length===0)throw new o("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof L!="boolean")throw new o('"allowMissing" argument must be a boolean');if(k(/^%?[^%]*%?$/,z)===null)throw new n("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var M=I(z),O=M.length>0?M[0]:"",P=T("%"+O+"%",L),j=P.name,U=P.value,V=!1,G=P.alias;G&&(O=G[0],b(M,E([0,1],G)));for(var Q=1,ne=!0;Q=M.length){var K=s(U,Z);ne=!!K,ne&&"get"in K&&!("originalValue"in K.get)?U=K.get:U=U[Z]}else ne=D(U,Z),U=U[Z];ne&&!V&&(v[j]=U)}}return U}}}),lN=et({"node_modules/call-bind/index.js"(e,t){var r=ah(),n=Sx(),a=n("%Function.prototype.apply%"),o=n("%Function.prototype.call%"),i=n("%Reflect.apply%",!0)||r.call(o,a),s=n("%Object.getOwnPropertyDescriptor%",!0),c=n("%Object.defineProperty%",!0),d=n("%Math.max%");if(c)try{c({},"a",{value:1})}catch{c=null}t.exports=function(m){var h=i(r,o,arguments);if(s&&c){var f=s(h,"length");f.configurable&&c(h,"length",{value:1+d(0,m.length-(arguments.length-1))})}return h};var p=function(){return i(r,a,arguments)};c?c(t.exports,"apply",{value:p}):t.exports.apply=p}}),sN=et({"node_modules/call-bind/callBound.js"(e,t){var r=Sx(),n=lN(),a=n(r("String.prototype.indexOf"));t.exports=function(o,i){var s=r(o,!!i);return typeof s=="function"&&a(o,".prototype.")>-1?n(s):s}}}),uN=et({"node_modules/has-tostringtag/shams.js"(e,t){var r=Dx();t.exports=function(){return r()&&!!Symbol.toStringTag}}}),cN=et({"node_modules/is-regex/index.js"(e,t){var r=sN(),n=uN()(),a,o,i,s;n&&(a=r("Object.prototype.hasOwnProperty"),o=r("RegExp.prototype.exec"),i={},c=function(){throw i},s={toString:c,valueOf:c},typeof Symbol.toPrimitive=="symbol"&&(s[Symbol.toPrimitive]=c));var c,d=r("Object.prototype.toString"),p=Object.getOwnPropertyDescriptor,m="[object RegExp]";t.exports=n?function(h){if(!h||typeof h!="object")return!1;var f=p(h,"lastIndex"),v=f&&a(f,"value");if(!v)return!1;try{o(h,s)}catch(g){return g===i}}:function(h){return!h||typeof h!="object"&&typeof h!="function"?!1:d(h)===m}}}),dN=et({"node_modules/is-function/index.js"(e,t){t.exports=n;var r=Object.prototype.toString;function n(a){if(!a)return!1;var o=r.call(a);return o==="[object Function]"||typeof a=="function"&&o!=="[object RegExp]"||typeof window<"u"&&(a===window.setTimeout||a===window.alert||a===window.confirm||a===window.prompt)}}}),pN=et({"node_modules/is-symbol/index.js"(e,t){var r=Object.prototype.toString,n=Cx()();n?(a=Symbol.prototype.toString,o=/^Symbol\(.*\)$/,i=function(s){return typeof s.valueOf()!="symbol"?!1:o.test(a.call(s))},t.exports=function(s){if(typeof s=="symbol")return!0;if(r.call(s)!=="[object Symbol]")return!1;try{return i(s)}catch{return!1}}):t.exports=function(s){return!1};var a,o,i}}),fN=nh(cN()),hN=nh(dN()),mN=nh(pN());function gN(e){return e!=null&&typeof e=="object"&&Array.isArray(e)===!1}var vN=typeof global=="object"&&global&&global.Object===Object&&global,yN=vN,bN=typeof self=="object"&&self&&self.Object===Object&&self,wN=yN||bN||Function("return this")(),oh=wN,EN=oh.Symbol,Ca=EN,kx=Object.prototype,xN=kx.hasOwnProperty,DN=kx.toString,no=Ca?Ca.toStringTag:void 0;function CN(e){var t=xN.call(e,no),r=e[no];try{e[no]=void 0;var n=!0}catch{}var a=DN.call(e);return n&&(t?e[no]=r:delete e[no]),a}var SN=CN,kN=Object.prototype,AN=kN.toString;function FN(e){return AN.call(e)}var _N=FN,RN="[object Null]",IN="[object Undefined]",H4=Ca?Ca.toStringTag:void 0;function TN(e){return e==null?e===void 0?IN:RN:H4&&H4 in Object(e)?SN(e):_N(e)}var BN=TN,j4=Ca?Ca.prototype:void 0;j4&&j4.toString;function zN(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Ax=zN,LN="[object AsyncFunction]",ON="[object Function]",MN="[object GeneratorFunction]",PN="[object Proxy]";function $N(e){if(!Ax(e))return!1;var t=BN(e);return t==ON||t==MN||t==LN||t==PN}var NN=$N,HN=oh["__core-js_shared__"],K0=HN,V4=function(){var e=/[^.]+$/.exec(K0&&K0.keys&&K0.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function jN(e){return!!V4&&V4 in e}var VN=jN,UN=Function.prototype,qN=UN.toString;function WN(e){if(e!=null){try{return qN.call(e)}catch{}try{return e+""}catch{}}return""}var GN=WN,YN=/[\\^$.*+?()[\]{}|]/g,KN=/^\[object .+?Constructor\]$/,ZN=Function.prototype,JN=Object.prototype,XN=ZN.toString,QN=JN.hasOwnProperty,eH=RegExp("^"+XN.call(QN).replace(YN,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function tH(e){if(!Ax(e)||VN(e))return!1;var t=NN(e)?eH:KN;return t.test(GN(e))}var rH=tH;function nH(e,t){return e?.[t]}var aH=nH;function oH(e,t){var r=aH(e,t);return rH(r)?r:void 0}var Fx=oH;function iH(e,t){return e===t||e!==e&&t!==t}var lH=iH,sH=Fx(Object,"create"),Wo=sH;function uH(){this.__data__=Wo?Wo(null):{},this.size=0}var cH=uH;function dH(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var pH=dH,fH="__lodash_hash_undefined__",hH=Object.prototype,mH=hH.hasOwnProperty;function gH(e){var t=this.__data__;if(Wo){var r=t[e];return r===fH?void 0:r}return mH.call(t,e)?t[e]:void 0}var vH=gH,yH=Object.prototype,bH=yH.hasOwnProperty;function wH(e){var t=this.__data__;return Wo?t[e]!==void 0:bH.call(t,e)}var EH=wH,xH="__lodash_hash_undefined__";function DH(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Wo&&t===void 0?xH:t,this}var CH=DH;function za(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t-1}var LH=zH;function OH(e,t){var r=this.__data__,n=mu(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var MH=OH;function La(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t{let t=null,r=!1,n=!1,a=!1,o="";if(e.indexOf("//")>=0||e.indexOf("/*")>=0)for(let i=0;i({width:`${e+t.toString().length*2+3}ch`,textAlign:"right",flexShrink:0})),GP=F.div({display:"flex",alignItems:"center",width:"100%"});function YP(e){let t=e.toString().match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return t?Math.max(0,(t[1]?t[1].length:0)-(t[2]?+t[2]:0)):0}var KP=({name:e,value:t,onChange:r,min:n=0,max:a=100,step:o=1,onBlur:i,onFocus:s,argType:c})=>{let d=f=>{r(oP(f.target.value))},p=t!==void 0,m=l.useMemo(()=>YP(o),[o]),h=!!c?.table?.readonly;return y.createElement(GP,{"aria-readonly":h},y.createElement(bx,null,n),y.createElement(qP,{id:vt(e),type:"range",disabled:h,onChange:d,name:e,value:t,min:n,max:a,step:o,onFocus:s,onBlur:i}),y.createElement(WP,{numberOFDecimalsPlaces:m,max:a},p?t.toFixed(m):"--"," / ",a))},ZP=F.label({display:"flex"}),JP=F.div(({isMaxed:e})=>({marginLeft:"0.75rem",paddingTop:"0.35rem",color:e?"red":void 0})),XP=({name:e,value:t,onChange:r,onFocus:n,onBlur:a,maxLength:o,argType:i})=>{let s=f=>{r(f.target.value)},c=!!i?.table?.readonly,[d,p]=l.useState(!1),m=l.useCallback(()=>{r(""),p(!0)},[p]);if(t===void 0)return y.createElement(Sn,{variant:"outline",size:"medium",disabled:c,id:ps(e),onClick:m},"Set string");let h=typeof t=="string";return y.createElement(ZP,null,y.createElement(mi.Textarea,{id:vt(e),maxLength:o,onChange:s,disabled:c,size:"flex",placeholder:"Edit string...",autoFocus:d,valid:h?null:"error",name:e,value:h?t:"",onFocus:n,onBlur:a}),o&&y.createElement(JP,{isMaxed:t?.length===o},t?.length??0," / ",o))},QP=F(mi.Input)({padding:10});function e$(e){e.forEach(t=>{t.startsWith("blob:")&&URL.revokeObjectURL(t)})}var t$=({onChange:e,name:t,accept:r="image/*",value:n,argType:a})=>{let o=l.useRef(null),i=a?.control?.readOnly;function s(c){if(!c.target.files)return;let d=Array.from(c.target.files).map(p=>URL.createObjectURL(p));e(d),e$(n)}return l.useEffect(()=>{n==null&&o.current&&(o.current.value=null)},[n,t]),y.createElement(QP,{ref:o,id:vt(t),type:"file",name:t,multiple:!0,disabled:i,onChange:s,accept:r,size:"flex"})},r$=l.lazy(()=>G1(()=>import("./Color-F6OSRLHC-D-JbNhmq.js"),__vite__mapDeps([9,2,1,3,4,5,6,7,8]),import.meta.url)),n$=e=>y.createElement(l.Suspense,{fallback:y.createElement("div",null)},y.createElement(r$,{...e})),a$={array:O4,object:O4,boolean:JM,color:n$,date:nP,number:lP,check:Mn,"inline-check":Mn,radio:Mn,"inline-radio":Mn,select:Mn,"multi-select":Mn,range:KP,text:XP,file:t$},M4=()=>y.createElement(y.Fragment,null,"-"),o$=({row:e,arg:t,updateArgs:r,isHovered:n})=>{let{key:a,control:o}=e,[i,s]=l.useState(!1),[c,d]=l.useState({value:t});l.useEffect(()=>{i||d({value:t})},[i,t]);let p=l.useCallback(g=>(d({value:g}),r({[a]:g}),g),[r,a]),m=l.useCallback(()=>s(!1),[]),h=l.useCallback(()=>s(!0),[]);if(!o||o.disable){let g=o?.disable!==!0&&e?.type?.name!=="function";return n&&g?y.createElement(aa,{href:"https://storybook.js.org/docs/essentials/controls",target:"_blank",withArrow:!0},"Setup controls"):y.createElement(M4,null)}let f={name:a,argType:e,value:c.value,onChange:p,onBlur:m,onFocus:h},v=a$[o.type]||M4;return y.createElement(v,{...f,...o,controlType:o.type})},i$=F.table(({theme:e})=>({"&&":{borderCollapse:"collapse",borderSpacing:0,border:"none",tr:{border:"none !important",background:"none"},"td, th":{padding:0,border:"none",width:"auto!important"},marginTop:0,marginBottom:0,"th:first-of-type, td:first-of-type":{paddingLeft:0},"th:last-of-type, td:last-of-type":{paddingRight:0},td:{paddingTop:0,paddingBottom:4,"&:not(:first-of-type)":{paddingLeft:10,paddingRight:0}},tbody:{boxShadow:"none",border:"none"},code:Lr({theme:e}),div:{span:{fontWeight:"bold"}},"& code":{margin:0,display:"inline-block",fontSize:e.typography.size.s1}}})),l$=({tags:e})=>{let t=(e.params||[]).filter(o=>o.description),r=t.length!==0,n=e.deprecated!=null,a=e.returns!=null&&e.returns.description!=null;return!r&&!a&&!n?null:y.createElement(y.Fragment,null,y.createElement(i$,null,y.createElement("tbody",null,n&&y.createElement("tr",{key:"deprecated"},y.createElement("td",{colSpan:2},y.createElement("strong",null,"Deprecated"),": ",e.deprecated.toString())),r&&t.map(o=>y.createElement("tr",{key:o.name},y.createElement("td",null,y.createElement("code",null,o.name)),y.createElement("td",null,o.description))),a&&y.createElement("tr",{key:"returns"},y.createElement("td",null,y.createElement("code",null,"Returns")),y.createElement("td",null,e.returns.description)))))},s$=Y1(T9()),V1=8,P4=F.div(({isExpanded:e})=>({display:"flex",flexDirection:e?"column":"row",flexWrap:"wrap",alignItems:"flex-start",marginBottom:"-4px",minWidth:100})),u$=F.span(Lr,({theme:e,simple:t=!1})=>({flex:"0 0 auto",fontFamily:e.typography.fonts.mono,fontSize:e.typography.size.s1,wordBreak:"break-word",whiteSpace:"normal",maxWidth:"100%",margin:0,marginRight:"4px",marginBottom:"4px",paddingTop:"2px",paddingBottom:"2px",lineHeight:"13px",...t&&{background:"transparent",border:"0 none",paddingLeft:0}})),c$=F.button(({theme:e})=>({fontFamily:e.typography.fonts.mono,color:e.color.secondary,marginBottom:"4px",background:"none",border:"none"})),d$=F.div(Lr,({theme:e})=>({fontFamily:e.typography.fonts.mono,color:e.color.secondary,fontSize:e.typography.size.s1,margin:0,whiteSpace:"nowrap",display:"flex",alignItems:"center"})),p$=F.div(({theme:e,width:t})=>({width:t,minWidth:200,maxWidth:800,padding:15,fontFamily:e.typography.fonts.mono,fontSize:e.typography.size.s1,boxSizing:"content-box","& code":{padding:"0 !important"}})),f$=F(AL)({marginLeft:4}),h$=F(I9)({marginLeft:4}),m$=()=>y.createElement("span",null,"-"),wx=({text:e,simple:t})=>y.createElement(u$,{simple:t},e),g$=(0,s$.default)(1e3)(e=>{let t=e.split(/\r?\n/);return`${Math.max(...t.map(r=>r.length))}ch`}),v$=e=>{if(!e)return[e];let t=e.split("|").map(r=>r.trim());return Xx(t)},$4=(e,t=!0)=>{let r=e;return t||(r=e.slice(0,V1)),r.map(n=>y.createElement(wx,{key:n,text:n===""?'""':n}))},y$=({value:e,initialExpandedArgs:t})=>{let{summary:r,detail:n}=e,[a,o]=l.useState(!1),[i,s]=l.useState(t||!1);if(r==null)return null;let c=typeof r.toString=="function"?r.toString():r;if(n==null){if(/[(){}[\]<>]/.test(c))return y.createElement(wx,{text:c});let d=v$(c),p=d.length;return p>V1?y.createElement(P4,{isExpanded:i},$4(d,i),y.createElement(c$,{onClick:()=>s(!i)},i?"Show less...":`Show ${p-V1} more...`)):y.createElement(P4,null,$4(d))}return y.createElement(mz,{closeOnOutsideClick:!0,placement:"bottom",visible:a,onVisibleChange:d=>{o(d)},tooltip:y.createElement(p$,{width:g$(n)},y.createElement(Hf,{language:"jsx",format:!1},n))},y.createElement(d$,{className:"sbdocs-expandable"},y.createElement("span",null,c),a?y.createElement(f$,null):y.createElement(h$,null)))},G0=({value:e,initialExpandedArgs:t})=>e==null?y.createElement(m$,null):y.createElement(y$,{value:e,initialExpandedArgs:t}),b$=F.span({fontWeight:"bold"}),w$=F.span(({theme:e})=>({color:e.color.negative,fontFamily:e.typography.fonts.mono,cursor:"help"})),E$=F.div(({theme:e})=>({"&&":{p:{margin:"0 0 10px 0"},a:{color:e.color.secondary}},code:{...Lr({theme:e}),fontSize:12,fontFamily:e.typography.fonts.mono},"& code":{margin:0,display:"inline-block"},"& pre > code":{whiteSpace:"pre-wrap"}})),x$=F.div(({theme:e,hasDescription:t})=>({color:e.base==="light"?oe(.1,e.color.defaultText):oe(.2,e.color.defaultText),marginTop:t?4:0})),D$=F.div(({theme:e,hasDescription:t})=>({color:e.base==="light"?oe(.1,e.color.defaultText):oe(.2,e.color.defaultText),marginTop:t?12:0,marginBottom:12})),C$=F.td(({theme:e,expandable:t})=>({paddingLeft:t?"40px !important":"20px !important"})),S$=e=>e&&{summary:typeof e=="string"?e:e.name},Zi=e=>{let[t,r]=l.useState(!1),{row:n,updateArgs:a,compact:o,expandable:i,initialExpandedArgs:s}=e,{name:c,description:d}=n,p=n.table||{},m=p.type||S$(n.type),h=p.defaultValue||n.defaultValue,f=n.type?.required,v=d!=null&&d!=="";return y.createElement("tr",{onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1)},y.createElement(C$,{expandable:i},y.createElement(b$,null,c),f?y.createElement(w$,{title:"Required"},"*"):null),o?null:y.createElement("td",null,v&&y.createElement(E$,null,y.createElement(lx,null,d)),p.jsDocTags!=null?y.createElement(y.Fragment,null,y.createElement(D$,{hasDescription:v},y.createElement(G0,{value:m,initialExpandedArgs:s})),y.createElement(l$,{tags:p.jsDocTags})):y.createElement(x$,{hasDescription:v},y.createElement(G0,{value:m,initialExpandedArgs:s}))),o?null:y.createElement("td",null,y.createElement(G0,{value:h,initialExpandedArgs:s})),a?y.createElement("td",null,y.createElement(o$,{...e,isHovered:t})):null)},k$=F.div(({inAddonPanel:e,theme:t})=>({height:e?"100%":"auto",display:"flex",border:e?"none":`1px solid ${t.appBorderColor}`,borderRadius:e?0:t.appBorderRadius,padding:e?0:40,alignItems:"center",justifyContent:"center",flexDirection:"column",gap:15,background:t.background.content,boxShadow:"rgba(0, 0, 0, 0.10) 0 1px 3px 0"})),A$=F.div(({theme:e})=>({display:"flex",fontSize:e.typography.size.s2-1,gap:25})),F$=F.div(({theme:e})=>({width:1,height:16,backgroundColor:e.appBorderColor})),_$=({inAddonPanel:e})=>{let[t,r]=l.useState(!0);return l.useEffect(()=>{let n=setTimeout(()=>{r(!1)},100);return()=>clearTimeout(n)},[]),t?null:y.createElement(k$,{inAddonPanel:e},y.createElement(C9,{title:e?"Interactive story playground":"Args table with interactive controls couldn't be auto-generated",description:y.createElement(y.Fragment,null,"Controls give you an easy to use interface to test your components. Set your story args and you'll see controls appearing here automatically."),footer:y.createElement(A$,null,e&&y.createElement(y.Fragment,null,y.createElement(aa,{href:"https://youtu.be/0gOfS6K0x0E",target:"_blank",withArrow:!0},y.createElement(EL,null)," Watch 5m video"),y.createElement(F$,null),y.createElement(aa,{href:"https://storybook.js.org/docs/essentials/controls",target:"_blank",withArrow:!0},y.createElement(B1,null)," Read docs")),!e&&y.createElement(aa,{href:"https://storybook.js.org/docs/essentials/controls",target:"_blank",withArrow:!0},y.createElement(B1,null)," Learn how to set that up"))}))},R$=F(SL)(({theme:e})=>({marginRight:8,marginLeft:-10,marginTop:-2,height:12,width:12,color:e.base==="light"?oe(.25,e.color.defaultText):oe(.3,e.color.defaultText),border:"none",display:"inline-block"})),I$=F(kL)(({theme:e})=>({marginRight:8,marginLeft:-10,marginTop:-2,height:12,width:12,color:e.base==="light"?oe(.25,e.color.defaultText):oe(.3,e.color.defaultText),border:"none",display:"inline-block"})),T$=F.span(({theme:e})=>({display:"flex",lineHeight:"20px",alignItems:"center"})),B$=F.td(({theme:e})=>({position:"relative",letterSpacing:"0.35em",textTransform:"uppercase",fontWeight:e.typography.weight.bold,fontSize:e.typography.size.s1-1,color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText),background:`${e.background.app} !important`,"& ~ td":{background:`${e.background.app} !important`}})),z$=F.td(({theme:e})=>({position:"relative",fontWeight:e.typography.weight.bold,fontSize:e.typography.size.s2-1,background:e.background.app})),L$=F.td(()=>({position:"relative"})),O$=F.tr(({theme:e})=>({"&:hover > td":{backgroundColor:`${Kr(.005,e.background.app)} !important`,boxShadow:`${e.color.mediumlight} 0 - 1px 0 0 inset`,cursor:"row-resize"}})),N4=F.button(()=>({background:"none",border:"none",padding:"0",font:"inherit",position:"absolute",top:0,bottom:0,left:0,right:0,height:"100%",width:"100%",color:"transparent",cursor:"row-resize !important"})),Y0=({level:e="section",label:t,children:r,initialExpanded:n=!0,colSpan:a=3})=>{let[o,i]=l.useState(n),s=e==="subsection"?z$:B$,c=r?.length||0,d=e==="subsection"?`${c} item${c!==1?"s":""}`:"",p=`${o?"Hide":"Show"} ${e==="subsection"?c:t} item${c!==1?"s":""}`;return y.createElement(y.Fragment,null,y.createElement(O$,{title:p},y.createElement(s,{colSpan:1},y.createElement(N4,{onClick:m=>i(!o),tabIndex:0},p),y.createElement(T$,null,o?y.createElement(R$,null):y.createElement(I$,null),t)),y.createElement(L$,{colSpan:a-1},y.createElement(N4,{onClick:m=>i(!o),tabIndex:-1,style:{outline:"none"}},p),o?null:d)),o?r:null)},Ji=F.div(({theme:e})=>({display:"flex",gap:16,borderBottom:`1px solid ${e.appBorderColor}`,"&:last-child":{borderBottom:0}})),Ae=F.div(({numColumn:e})=>({display:"flex",flexDirection:"column",flex:e||1,gap:5,padding:"12px 20px"})),me=F.div(({theme:e,width:t,height:r})=>({animation:`${e.animation.glow} 1.5s ease-in-out infinite`,background:e.appBorderColor,width:t||"100%",height:r||16,borderRadius:3})),Fe=[2,4,2,2],M$=()=>y.createElement(y.Fragment,null,y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"}))),y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"80%"}),y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"}))),y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"80%"}),y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"}))),y.createElement(Ji,null,y.createElement(Ae,{numColumn:Fe[0]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[1]},y.createElement(me,{width:"80%"}),y.createElement(me,{width:"30%"})),y.createElement(Ae,{numColumn:Fe[2]},y.createElement(me,{width:"60%"})),y.createElement(Ae,{numColumn:Fe[3]},y.createElement(me,{width:"60%"})))),P$=F.table(({theme:e,compact:t,inAddonPanel:r})=>({"&&":{borderSpacing:0,color:e.color.defaultText,"td, th":{padding:0,border:"none",verticalAlign:"top",textOverflow:"ellipsis"},fontSize:e.typography.size.s2-1,lineHeight:"20px",textAlign:"left",width:"100%",marginTop:r?0:25,marginBottom:r?0:40,"thead th:first-of-type, td:first-of-type":{width:"25%"},"th:first-of-type, td:first-of-type":{paddingLeft:20},"th:nth-of-type(2), td:nth-of-type(2)":{...t?null:{width:"35%"}},"td:nth-of-type(3)":{...t?null:{width:"15%"}},"th:last-of-type, td:last-of-type":{paddingRight:20,...t?null:{width:"25%"}},th:{color:e.base==="light"?oe(.25,e.color.defaultText):oe(.45,e.color.defaultText),paddingTop:10,paddingBottom:10,paddingLeft:15,paddingRight:15},td:{paddingTop:"10px",paddingBottom:"10px","&:not(:first-of-type)":{paddingLeft:15,paddingRight:15},"&:last-of-type":{paddingRight:20}},marginLeft:r?0:1,marginRight:r?0:1,tbody:{...r?null:{filter:e.base==="light"?"drop-shadow(0px 1px 3px rgba(0, 0, 0, 0.10))":"drop-shadow(0px 1px 3px rgba(0, 0, 0, 0.20))"},"> tr > *":{background:e.background.content,borderTop:`1px solid ${e.appBorderColor}`},...r?null:{"> tr:first-of-type > *":{borderBlockStart:`1px solid ${e.appBorderColor}`},"> tr:last-of-type > *":{borderBlockEnd:`1px solid ${e.appBorderColor}`},"> tr > *:first-of-type":{borderInlineStart:`1px solid ${e.appBorderColor}`},"> tr > *:last-of-type":{borderInlineEnd:`1px solid ${e.appBorderColor}`},"> tr:first-of-type > td:first-of-type":{borderTopLeftRadius:e.appBorderRadius},"> tr:first-of-type > td:last-of-type":{borderTopRightRadius:e.appBorderRadius},"> tr:last-of-type > td:first-of-type":{borderBottomLeftRadius:e.appBorderRadius},"> tr:last-of-type > td:last-of-type":{borderBottomRightRadius:e.appBorderRadius}}}}})),$$=F(sn)(({theme:e})=>({margin:"-4px -12px -4px 0"})),N$=F.span({display:"flex",justifyContent:"space-between"}),H$={alpha:(e,t)=>e.name.localeCompare(t.name),requiredFirst:(e,t)=>+!!t.type?.required-+!!e.type?.required||e.name.localeCompare(t.name),none:void 0},j$=(e,t)=>{let r={ungrouped:[],ungroupedSubsections:{},sections:{}};if(!e)return r;Object.entries(e).forEach(([o,i])=>{let{category:s,subcategory:c}=i?.table||{};if(s){let d=r.sections[s]||{ungrouped:[],subsections:{}};if(!c)d.ungrouped.push({key:o,...i});else{let p=d.subsections[c]||[];p.push({key:o,...i}),d.subsections[c]=p}r.sections[s]=d}else if(c){let d=r.ungroupedSubsections[c]||[];d.push({key:o,...i}),r.ungroupedSubsections[c]=d}else r.ungrouped.push({key:o,...i})});let n=H$[t],a=o=>n?Object.keys(o).reduce((i,s)=>({...i,[s]:o[s].sort(n)}),{}):o;return{ungrouped:r.ungrouped.sort(n),ungroupedSubsections:a(r.ungroupedSubsections),sections:Object.keys(r.sections).reduce((o,i)=>({...o,[i]:{ungrouped:r.sections[i].ungrouped.sort(n),subsections:a(r.sections[i].subsections)}}),{})}},V$=(e,t,r)=>{try{return jx(e,t,r)}catch(n){return RL.warn(n.message),!1}},U1=e=>{let{updateArgs:t,resetArgs:r,compact:n,inAddonPanel:a,initialExpandedArgs:o,sort:i="none",isLoading:s}=e;if("error"in e){let{error:D}=e;return y.createElement(M9,null,D," ",y.createElement(aa,{href:"http://storybook.js.org/docs/",target:"_blank",withArrow:!0},y.createElement(B1,null)," Read the docs"))}if(s)return y.createElement(M$,null);let{rows:c,args:d,globals:p}="rows"in e&&e,m=j$(Qx(c||{},D=>!D?.table?.disable&&V$(D,d||{},p||{})),i),h=m.ungrouped.length===0,f=Object.entries(m.sections).length===0,v=Object.entries(m.ungroupedSubsections).length===0;if(h&&f&&v)return y.createElement(_$,{inAddonPanel:a});let g=1;t&&(g+=1),n||(g+=2);let w=Object.keys(m.sections).length>0,x={updateArgs:t,compact:n,inAddonPanel:a,initialExpandedArgs:o};return y.createElement(N8,null,y.createElement(P$,{compact:n,inAddonPanel:a,className:"docblock-argstable sb-unstyled"},y.createElement("thead",{className:"docblock-argstable-head"},y.createElement("tr",null,y.createElement("th",null,y.createElement("span",null,"Name")),n?null:y.createElement("th",null,y.createElement("span",null,"Description")),n?null:y.createElement("th",null,y.createElement("span",null,"Default")),t?y.createElement("th",null,y.createElement(N$,null,"Control"," ",!s&&r&&y.createElement($$,{onClick:()=>r(),title:"Reset controls"},y.createElement(FL,{"aria-hidden":!0})))):null)),y.createElement("tbody",{className:"docblock-argstable-body"},m.ungrouped.map(D=>y.createElement(Zi,{key:D.key,row:D,arg:d&&d[D.key],...x})),Object.entries(m.ungroupedSubsections).map(([D,E])=>y.createElement(Y0,{key:D,label:D,level:"subsection",colSpan:g},E.map(b=>y.createElement(Zi,{key:b.key,row:b,arg:d&&d[b.key],expandable:w,...x})))),Object.entries(m.sections).map(([D,E])=>y.createElement(Y0,{key:D,label:D,level:"section",colSpan:g},E.ungrouped.map(b=>y.createElement(Zi,{key:b.key,row:b,arg:d&&d[b.key],...x})),Object.entries(E.subsections).map(([b,C])=>y.createElement(Y0,{key:b,label:b,level:"subsection",colSpan:g},C.map(S=>y.createElement(Zi,{key:S.key,row:S,arg:d&&d[S.key],expandable:w,...x})))))))))},U$=({tabs:e,...t})=>{let r=Object.entries(e);return r.length===1?y.createElement(U1,{...r[0][1],...t}):y.createElement(Jz,null,r.map((n,a)=>{let[o,i]=n,s=`prop_table_div_${o}`,c="div",d=a===0?t:{sort:t.sort};return y.createElement(c,{key:s,id:s,title:o},({active:p})=>p?y.createElement(U1,{key:`prop_table_${o}`,...i,...d}):null)}))};F.div(({theme:e})=>({marginRight:30,fontSize:`${e.typography.size.s1}px`,color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText)}));F.div({overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"});F.div({display:"flex",flexDirection:"row",alignItems:"baseline","&:not(:last-child)":{marginBottom:"1rem"}});F.div(se,({theme:e})=>({...pu(e),margin:"25px 0 40px",padding:"30px 20px"}));F.div(({theme:e})=>({fontWeight:e.typography.weight.bold,color:e.color.defaultText}));F.div(({theme:e})=>({color:e.base==="light"?oe(.2,e.color.defaultText):oe(.6,e.color.defaultText)}));F.div({flex:"0 0 30%",lineHeight:"20px",marginTop:5});F.div(({theme:e})=>({flex:1,textAlign:"center",fontFamily:e.typography.fonts.mono,fontSize:e.typography.size.s1,lineHeight:1,overflow:"hidden",color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText),"> div":{display:"inline-block",overflow:"hidden",maxWidth:"100%",textOverflow:"ellipsis"},span:{display:"block",marginTop:2}}));F.div({display:"flex",flexDirection:"row"});F.div(({background:e})=>({position:"relative",flex:1,"&::before":{position:"absolute",top:0,left:0,width:"100%",height:"100%",background:e,content:'""'}}));F.div(({theme:e})=>({...pu(e),display:"flex",flexDirection:"row",height:50,marginBottom:5,overflow:"hidden",backgroundColor:"white",backgroundImage:"repeating-linear-gradient(-45deg, #ccc, #ccc 1px, #fff 1px, #fff 16px)",backgroundClip:"padding-box"}));F.div({display:"flex",flexDirection:"column",flex:1,position:"relative",marginBottom:30});F.div({flex:1,display:"flex",flexDirection:"row"});F.div({display:"flex",alignItems:"flex-start"});F.div({flex:"0 0 30%"});F.div({flex:1});F.div(({theme:e})=>({display:"flex",flexDirection:"row",alignItems:"center",paddingBottom:20,fontWeight:e.typography.weight.bold,color:e.base==="light"?oe(.4,e.color.defaultText):oe(.6,e.color.defaultText)}));F.div(({theme:e})=>({fontSize:e.typography.size.s2,lineHeight:"20px",display:"flex",flexDirection:"column"}));F.div(({theme:e})=>({fontFamily:e.typography.fonts.base,fontSize:e.typography.size.s2,color:e.color.defaultText,marginLeft:10,lineHeight:1.2}));F.div(({theme:e})=>({...pu(e),overflow:"hidden",height:40,width:40,display:"flex",alignItems:"center",justifyContent:"center",flex:"none","> img, > svg":{width:20,height:20}}));F.div({display:"inline-flex",flexDirection:"row",alignItems:"center",flex:"0 1 calc(20% - 10px)",minWidth:120,margin:"0px 10px 30px 0"});F.div({display:"flex",flexFlow:"row wrap"});var q$=e=>`anchor--${e}`,W$=({storyId:e,children:t})=>y.createElement("div",{id:q$(e),className:"sb-anchor"},t);globalThis&&globalThis.__DOCS_CONTEXT__===void 0&&(globalThis.__DOCS_CONTEXT__=l.createContext(null),globalThis.__DOCS_CONTEXT__.displayName="DocsContext");var Yt=globalThis?globalThis.__DOCS_CONTEXT__:l.createContext(null),kn=(e,t)=>l.useContext(Yt).resolveOf(e,t),G$=e=>e.split("-").map(t=>t.charAt(0).toUpperCase()+t.slice(1)).join(""),Y$=e=>{if(e)return typeof e=="string"?e.includes("-")?G$(e):e:e.__docgenInfo&&e.__docgenInfo.displayName?e.__docgenInfo.displayName:e.name};function K$(e,t="start"){e.scrollIntoView({behavior:"smooth",block:t,inline:"nearest"})}var Z$=Object.create,Ex=Object.defineProperty,J$=Object.getOwnPropertyDescriptor,xx=Object.getOwnPropertyNames,X$=Object.getPrototypeOf,Q$=Object.prototype.hasOwnProperty,et=(e,t)=>function(){return t||(0,e[xx(e)[0]])((t={exports:{}}).exports,t),t.exports},eN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of xx(t))!Q$.call(e,a)&&a!==r&&Ex(e,a,{get:()=>t[a],enumerable:!(n=J$(t,a))||n.enumerable});return e},nh=(e,t,r)=>(r=e!=null?Z$(X$(e)):{},eN(!e||!e.__esModule?Ex(r,"default",{value:e,enumerable:!0}):r,e)),tN=["bubbles","cancelBubble","cancelable","composed","currentTarget","defaultPrevented","eventPhase","isTrusted","returnValue","srcElement","target","timeStamp","type"],rN=["detail"];function nN(e){let t=tN.filter(r=>e[r]!==void 0).reduce((r,n)=>({...r,[n]:e[n]}),{});return e instanceof CustomEvent&&rN.filter(r=>e[r]!==void 0).forEach(r=>{t[r]=e[r]}),t}var aN=Y1(T9(),1),Dx=et({"node_modules/has-symbols/shams.js"(e,t){t.exports=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var r={},n=Symbol("test"),a=Object(n);if(typeof n=="string"||Object.prototype.toString.call(n)!=="[object Symbol]"||Object.prototype.toString.call(a)!=="[object Symbol]")return!1;var o=42;r[n]=o;for(n in r)return!1;if(typeof Object.keys=="function"&&Object.keys(r).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(r).length!==0)return!1;var i=Object.getOwnPropertySymbols(r);if(i.length!==1||i[0]!==n||!Object.prototype.propertyIsEnumerable.call(r,n))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var s=Object.getOwnPropertyDescriptor(r,n);if(s.value!==o||s.enumerable!==!0)return!1}return!0}}}),Cx=et({"node_modules/has-symbols/index.js"(e,t){var r=typeof Symbol<"u"&&Symbol,n=Dx();t.exports=function(){return typeof r!="function"||typeof Symbol!="function"||typeof r("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:n()}}}),oN=et({"node_modules/function-bind/implementation.js"(e,t){var r="Function.prototype.bind called on incompatible ",n=Array.prototype.slice,a=Object.prototype.toString,o="[object Function]";t.exports=function(i){var s=this;if(typeof s!="function"||a.call(s)!==o)throw new TypeError(r+s);for(var c=n.call(arguments,1),d,p=function(){if(this instanceof d){var g=s.apply(this,c.concat(n.call(arguments)));return Object(g)===g?g:this}else return s.apply(i,c.concat(n.call(arguments)))},m=Math.max(0,s.length-c.length),h=[],f=0;f"u"?r:m(Uint8Array),v={"%AggregateError%":typeof AggregateError>"u"?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?r:ArrayBuffer,"%ArrayIteratorPrototype%":p?m([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":h,"%AsyncGenerator%":h,"%AsyncGeneratorFunction%":h,"%AsyncIteratorPrototype%":h,"%Atomics%":typeof Atomics>"u"?r:Atomics,"%BigInt%":typeof BigInt>"u"?r:BigInt,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?r:Float32Array,"%Float64Array%":typeof Float64Array>"u"?r:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?r:FinalizationRegistry,"%Function%":a,"%GeneratorFunction%":h,"%Int8Array%":typeof Int8Array>"u"?r:Int8Array,"%Int16Array%":typeof Int16Array>"u"?r:Int16Array,"%Int32Array%":typeof Int32Array>"u"?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":p?m(m([][Symbol.iterator]())):r,"%JSON%":typeof JSON=="object"?JSON:r,"%Map%":typeof Map>"u"?r:Map,"%MapIteratorPrototype%":typeof Map>"u"||!p?r:m(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?r:Promise,"%Proxy%":typeof Proxy>"u"?r:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?r:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?r:Set,"%SetIteratorPrototype%":typeof Set>"u"||!p?r:m(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":p?m(""[Symbol.iterator]()):r,"%Symbol%":p?Symbol:r,"%SyntaxError%":n,"%ThrowTypeError%":d,"%TypedArray%":f,"%TypeError%":o,"%Uint8Array%":typeof Uint8Array>"u"?r:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?r:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?r:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?r:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?r:WeakMap,"%WeakRef%":typeof WeakRef>"u"?r:WeakRef,"%WeakSet%":typeof WeakSet>"u"?r:WeakSet},g=function z(L){var M;if(L==="%AsyncFunction%")M=i("async function () {}");else if(L==="%GeneratorFunction%")M=i("function* () {}");else if(L==="%AsyncGeneratorFunction%")M=i("async function* () {}");else if(L==="%AsyncGenerator%"){var O=z("%AsyncGeneratorFunction%");O&&(M=O.prototype)}else if(L==="%AsyncIteratorPrototype%"){var P=z("%AsyncGenerator%");P&&(M=m(P.prototype))}return v[L]=M,M},w={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},x=ah(),D=iN(),E=x.call(Function.call,Array.prototype.concat),b=x.call(Function.apply,Array.prototype.splice),C=x.call(Function.call,String.prototype.replace),S=x.call(Function.call,String.prototype.slice),k=x.call(Function.call,RegExp.prototype.exec),A=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,_=/\\(\\)?/g,I=function(z){var L=S(z,0,1),M=S(z,-1);if(L==="%"&&M!=="%")throw new n("invalid intrinsic syntax, expected closing `%`");if(M==="%"&&L!=="%")throw new n("invalid intrinsic syntax, expected opening `%`");var O=[];return C(z,A,function(P,j,U,V){O[O.length]=U?C(V,_,"$1"):j||P}),O},T=function(z,L){var M=z,O;if(D(w,M)&&(O=w[M],M="%"+O[0]+"%"),D(v,M)){var P=v[M];if(P===h&&(P=g(M)),typeof P>"u"&&!L)throw new o("intrinsic "+z+" exists, but is not available. Please file an issue!");return{alias:O,name:M,value:P}}throw new n("intrinsic "+z+" does not exist!")};t.exports=function(z,L){if(typeof z!="string"||z.length===0)throw new o("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof L!="boolean")throw new o('"allowMissing" argument must be a boolean');if(k(/^%?[^%]*%?$/,z)===null)throw new n("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var M=I(z),O=M.length>0?M[0]:"",P=T("%"+O+"%",L),j=P.name,U=P.value,V=!1,G=P.alias;G&&(O=G[0],b(M,E([0,1],G)));for(var Q=1,ne=!0;Q=M.length){var K=s(U,Z);ne=!!K,ne&&"get"in K&&!("originalValue"in K.get)?U=K.get:U=U[Z]}else ne=D(U,Z),U=U[Z];ne&&!V&&(v[j]=U)}}return U}}}),lN=et({"node_modules/call-bind/index.js"(e,t){var r=ah(),n=Sx(),a=n("%Function.prototype.apply%"),o=n("%Function.prototype.call%"),i=n("%Reflect.apply%",!0)||r.call(o,a),s=n("%Object.getOwnPropertyDescriptor%",!0),c=n("%Object.defineProperty%",!0),d=n("%Math.max%");if(c)try{c({},"a",{value:1})}catch{c=null}t.exports=function(m){var h=i(r,o,arguments);if(s&&c){var f=s(h,"length");f.configurable&&c(h,"length",{value:1+d(0,m.length-(arguments.length-1))})}return h};var p=function(){return i(r,a,arguments)};c?c(t.exports,"apply",{value:p}):t.exports.apply=p}}),sN=et({"node_modules/call-bind/callBound.js"(e,t){var r=Sx(),n=lN(),a=n(r("String.prototype.indexOf"));t.exports=function(o,i){var s=r(o,!!i);return typeof s=="function"&&a(o,".prototype.")>-1?n(s):s}}}),uN=et({"node_modules/has-tostringtag/shams.js"(e,t){var r=Dx();t.exports=function(){return r()&&!!Symbol.toStringTag}}}),cN=et({"node_modules/is-regex/index.js"(e,t){var r=sN(),n=uN()(),a,o,i,s;n&&(a=r("Object.prototype.hasOwnProperty"),o=r("RegExp.prototype.exec"),i={},c=function(){throw i},s={toString:c,valueOf:c},typeof Symbol.toPrimitive=="symbol"&&(s[Symbol.toPrimitive]=c));var c,d=r("Object.prototype.toString"),p=Object.getOwnPropertyDescriptor,m="[object RegExp]";t.exports=n?function(h){if(!h||typeof h!="object")return!1;var f=p(h,"lastIndex"),v=f&&a(f,"value");if(!v)return!1;try{o(h,s)}catch(g){return g===i}}:function(h){return!h||typeof h!="object"&&typeof h!="function"?!1:d(h)===m}}}),dN=et({"node_modules/is-function/index.js"(e,t){t.exports=n;var r=Object.prototype.toString;function n(a){if(!a)return!1;var o=r.call(a);return o==="[object Function]"||typeof a=="function"&&o!=="[object RegExp]"||typeof window<"u"&&(a===window.setTimeout||a===window.alert||a===window.confirm||a===window.prompt)}}}),pN=et({"node_modules/is-symbol/index.js"(e,t){var r=Object.prototype.toString,n=Cx()();n?(a=Symbol.prototype.toString,o=/^Symbol\(.*\)$/,i=function(s){return typeof s.valueOf()!="symbol"?!1:o.test(a.call(s))},t.exports=function(s){if(typeof s=="symbol")return!0;if(r.call(s)!=="[object Symbol]")return!1;try{return i(s)}catch{return!1}}):t.exports=function(s){return!1};var a,o,i}}),fN=nh(cN()),hN=nh(dN()),mN=nh(pN());function gN(e){return e!=null&&typeof e=="object"&&Array.isArray(e)===!1}var vN=typeof global=="object"&&global&&global.Object===Object&&global,yN=vN,bN=typeof self=="object"&&self&&self.Object===Object&&self,wN=yN||bN||Function("return this")(),oh=wN,EN=oh.Symbol,Ca=EN,kx=Object.prototype,xN=kx.hasOwnProperty,DN=kx.toString,no=Ca?Ca.toStringTag:void 0;function CN(e){var t=xN.call(e,no),r=e[no];try{e[no]=void 0;var n=!0}catch{}var a=DN.call(e);return n&&(t?e[no]=r:delete e[no]),a}var SN=CN,kN=Object.prototype,AN=kN.toString;function FN(e){return AN.call(e)}var _N=FN,RN="[object Null]",IN="[object Undefined]",H4=Ca?Ca.toStringTag:void 0;function TN(e){return e==null?e===void 0?IN:RN:H4&&H4 in Object(e)?SN(e):_N(e)}var BN=TN,j4=Ca?Ca.prototype:void 0;j4&&j4.toString;function zN(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Ax=zN,LN="[object AsyncFunction]",ON="[object Function]",MN="[object GeneratorFunction]",PN="[object Proxy]";function $N(e){if(!Ax(e))return!1;var t=BN(e);return t==ON||t==MN||t==LN||t==PN}var NN=$N,HN=oh["__core-js_shared__"],K0=HN,V4=function(){var e=/[^.]+$/.exec(K0&&K0.keys&&K0.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function jN(e){return!!V4&&V4 in e}var VN=jN,UN=Function.prototype,qN=UN.toString;function WN(e){if(e!=null){try{return qN.call(e)}catch{}try{return e+""}catch{}}return""}var GN=WN,YN=/[\\^$.*+?()[\]{}|]/g,KN=/^\[object .+?Constructor\]$/,ZN=Function.prototype,JN=Object.prototype,XN=ZN.toString,QN=JN.hasOwnProperty,eH=RegExp("^"+XN.call(QN).replace(YN,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function tH(e){if(!Ax(e)||VN(e))return!1;var t=NN(e)?eH:KN;return t.test(GN(e))}var rH=tH;function nH(e,t){return e?.[t]}var aH=nH;function oH(e,t){var r=aH(e,t);return rH(r)?r:void 0}var Fx=oH;function iH(e,t){return e===t||e!==e&&t!==t}var lH=iH,sH=Fx(Object,"create"),Wo=sH;function uH(){this.__data__=Wo?Wo(null):{},this.size=0}var cH=uH;function dH(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var pH=dH,fH="__lodash_hash_undefined__",hH=Object.prototype,mH=hH.hasOwnProperty;function gH(e){var t=this.__data__;if(Wo){var r=t[e];return r===fH?void 0:r}return mH.call(t,e)?t[e]:void 0}var vH=gH,yH=Object.prototype,bH=yH.hasOwnProperty;function wH(e){var t=this.__data__;return Wo?t[e]!==void 0:bH.call(t,e)}var EH=wH,xH="__lodash_hash_undefined__";function DH(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Wo&&t===void 0?xH:t,this}var CH=DH;function za(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t-1}var LH=zH;function OH(e,t){var r=this.__data__,n=mu(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var MH=OH;function La(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t{let t=null,r=!1,n=!1,a=!1,o="";if(e.indexOf("//")>=0||e.indexOf("/*")>=0)for(let i=0;isj(e).replace(/\n\s*/g,"").trim()),cj=function(e,t){let r=t.slice(0,t.indexOf("{")),n=t.slice(t.indexOf("{"));if(r.includes("=>")||r.includes("function"))return t;let a=r;return a=a.replace(e,"function"),a+n},dj=/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d{3})?Z$/;function Rx(e){if(!lj(e))return e;let t=e,r=!1;return typeof Event<"u"&&e instanceof Event&&(t=nN(t),r=!0),t=Object.keys(t).reduce((n,a)=>{try{t[a]&&t[a].toJSON,n[a]=t[a]}catch{r=!0}return n},{}),r?t:e}var pj=function(e){let t,r,n,a;return function(o,i){try{if(o==="")return a=[],t=new Map([[i,"[]"]]),r=new Map,n=[],i;let s=r.get(this)||this;for(;n.length&&s!==n[0];)n.shift(),a.pop();if(typeof i=="boolean")return i;if(i===void 0)return e.allowUndefined?"_undefined_":void 0;if(i===null)return null;if(typeof i=="number")return i===-1/0?"_-Infinity_":i===1/0?"_Infinity_":Number.isNaN(i)?"_NaN_":i;if(typeof i=="bigint")return`_bigint_${i.toString()}`;if(typeof i=="string")return dj.test(i)?e.allowDate?`_date_${i}`:void 0:i;if((0,fN.default)(i))return e.allowRegExp?`_regexp_${i.flags}|${i.source}`:void 0;if((0,hN.default)(i)){if(!e.allowFunction)return;let{name:d}=i,p=i.toString();return p.match(/(\[native code\]|WEBPACK_IMPORTED_MODULE|__webpack_exports__|__webpack_require__)/)?`_function_${d}|${(()=>{}).toString()}`:`_function_${d}|${uj(cj(o,p))}`}if((0,mN.default)(i)){if(!e.allowSymbol)return;let d=Symbol.keyFor(i);return d!==void 0?`_gsymbol_${d}`:`_symbol_${i.toString().slice(7,-1)}`}if(n.length>=e.maxDepth)return Array.isArray(i)?`[Array(${i.length})]`:"[Object]";if(i===this)return`_duplicate_${JSON.stringify(a)}`;if(i instanceof Error&&e.allowError)return{__isConvertedError__:!0,errorProperties:{...i.cause?{cause:i.cause}:{},...i,name:i.name,message:i.message,stack:i.stack,"_constructor-name_":i.constructor.name}};if(i.constructor&&i.constructor.name&&i.constructor.name!=="Object"&&!Array.isArray(i)&&!e.allowClass)return;let c=t.get(i);if(!c){let d=Array.isArray(i)?i:Rx(i);if(i.constructor&&i.constructor.name&&i.constructor.name!=="Object"&&!Array.isArray(i)&&e.allowClass)try{Object.assign(d,{"_constructor-name_":i.constructor.name})}catch{}return a.push(o),n.unshift(d),t.set(i,JSON.stringify(a)),i!==d&&r.set(i,d),d}return`_duplicate_${c}`}catch{return}}},fj={maxDepth:10,space:void 0,allowFunction:!0,allowRegExp:!0,allowDate:!0,allowClass:!0,allowError:!0,allowUndefined:!0,allowSymbol:!0,lazyEval:!0},hj=(e,t={})=>{let r={...fj,...t};return JSON.stringify(Rx(e),pj(r),t.space)};function Ix(e){return hj(e,{allowFunction:!1})}var Tx=l.createContext({sources:{}}),Bx="--unknown--",mj=({children:e,channel:t})=>{let[r,n]=l.useState({});return l.useEffect(()=>{let a=(o,i=null,s=!1)=>{let{id:c,args:d=void 0,source:p,format:m}=typeof o=="string"?{id:o,source:i,format:s}:o,h=d?Ix(d):Bx;n(f=>({...f,[c]:{...f[c],[h]:{code:p,format:m}}}))};return t.on(fh,a),()=>t.off(fh,a)},[]),y.createElement(Tx.Provider,{value:{sources:r}},e)},gj=(e,t,r)=>{let{sources:n}=r,a=n?.[e];return a?.[Ix(t)]||a?.[Bx]||{code:""}},vj=({snippet:e,storyContext:t,typeFromProps:r,transformFromProps:n})=>{let{__isArgsStory:a}=t.parameters,o=t.parameters.docs?.source||{},i=r||o.type||bu.AUTO;if(o.code!==void 0)return o.code;let s=i===bu.DYNAMIC||i===bu.AUTO&&e&&a?e:o.originalSource||"";return(n??o.transform)?.(s,t)||s},yj=(e,t,r)=>{let n,{of:a}=e;if("of"in e&&a===void 0)throw new Error("Unexpected `of={undefined}`, did you mistype a CSF file reference?");if(a)n=t.resolveOf(a,["story"]).story;else try{n=t.storyById()}catch{}let o=n?.parameters?.docs?.source||{},{code:i}=e,s=e.format??o.format,c=e.language??o.language??"jsx",d=e.dark??o.dark??!1;if(!i&&!n)return{error:"Oh no! The source is not available."};if(i)return{code:i,format:s,language:c,dark:d};let p=t.getStoryContext(n),m=e.__forceInitialArgs?p.initialArgs:p.unmappedArgs,h=gj(n.id,m,r);return s=h.format??n.parameters.docs?.source?.format??!1,{code:vj({snippet:h.code,storyContext:{...p,args:m},typeFromProps:e.type,transformFromProps:e.transform}),format:s,language:c,dark:d}};function bj(e,t){let r=wj([e],t);return r&&r[0]}function wj(e,t){let[r,n]=l.useState({});return l.useEffect(()=>{Promise.all(e.map(async a=>{let o=await t.loadStory(a);n(i=>i[a]===o?i:{...i,[a]:o})}))}),e.map(a=>{if(r[a])return r[a];try{return t.storyById(a)}catch{return null}})}var Ej=(e,t)=>{let{of:r,meta:n}=e;if("of"in e&&r===void 0)throw new Error("Unexpected `of={undefined}`, did you mistype a CSF file reference?");return n&&t.referenceMeta(n,!1),t.resolveOf(r||"story",["story"]).story.id},xj=(e,t,r)=>{let{parameters:n={}}=t||{},{docs:a={}}=n,o=a.story||{};if(a.disable)return null;if(e.inline??o.inline??!1){let s=e.height??o.height,c=e.autoplay??o.autoplay??!1;return{story:t,inline:!0,height:s,autoplay:c,forceInitialArgs:!!e.__forceInitialArgs,primary:!!e.__primary,renderStoryToElement:r.renderStoryToElement}}let i=e.height??o.height??o.iframeHeight??"100px";return{story:t,inline:!1,height:i,primary:!!e.__primary}},Dj=(e={__forceInitialArgs:!1,__primary:!1})=>{let t=l.useContext(Yt),r=Ej(e,t),n=bj(r,t);if(!n)return y.createElement(N9,null);let a=xj(e,n,t);return a?y.createElement(zO,{...a}):null},Cj=e=>{let t=l.useContext(Yt),r=l.useContext(Tx),{of:n,source:a}=e;if("of"in e&&n===void 0)throw new Error("Unexpected `of={undefined}`, did you mistype a CSF file reference?");let{story:o}=kn(n||"story",["story"]),i=yj({...a,...n&&{of:n}},t,r),s=e.layout??o.parameters.layout??o.parameters.docs?.canvas?.layout??"padded",c=e.withToolbar??o.parameters.docs?.canvas?.withToolbar??!1,d=e.additionalActions??o.parameters.docs?.canvas?.additionalActions,p=e.sourceState??o.parameters.docs?.canvas?.sourceState??"hidden",m=e.className??o.parameters.docs?.canvas?.className;return y.createElement(H9,{withSource:p==="none"?void 0:i,isExpanded:p==="shown",withToolbar:c,additionalActions:d,className:m,layout:s},y.createElement(Dj,{of:n||o.moduleExport,meta:e.meta,...e.story}))},Sj=(e,t)=>{let r=kj(e,t);if(!r)throw new Error("No result when story was defined");return r},kj=(e,t)=>{let r=e?t.getStoryContext(e):{args:{}},{id:n}=e||{id:"none"},[a,o]=l.useState(r.args);l.useEffect(()=>{let c=d=>{d.storyId===n&&o(d.args)};return t.channel.on(v4,c),()=>t.channel.off(v4,c)},[n,t.channel]);let i=l.useCallback(c=>t.channel.emit(IL,{storyId:n,updatedArgs:c}),[n,t.channel]),s=l.useCallback(c=>t.channel.emit(TL,{storyId:n,argNames:c}),[n,t.channel]);return e&&[a,i,s]},Aj=(e,t)=>{let r=t.getStoryContext(e),[n,a]=l.useState(r.globals);return l.useEffect(()=>{let o=i=>{a(i.globals)};return t.channel.on(y4,o),()=>t.channel.off(y4,o)},[t.channel]),[n]};function Fj(e,t){let{extractArgTypes:r}=t.docs||{};if(!r)throw new Error("Args unsupported. See Args documentation for your framework.");return r(e)}var _j=e=>{let{of:t}=e;if("of"in e&&t===void 0)throw new Error("Unexpected `of={undefined}`, did you mistype a CSF file reference?");let r=l.useContext(Yt),{story:n}=r.resolveOf(t||"story",["story"]),{parameters:a,argTypes:o,component:i,subcomponents:s}=n,c=a.docs?.controls||{},d=e.include??c.include,p=e.exclude??c.exclude,m=e.sort??c.sort,[h,f,v]=Sj(n,r),[g]=Aj(n,r),w=g4(o,d,p);if(!(s&&Object.keys(s).length>0))return Object.keys(w).length>0||Object.keys(h).length>0?y.createElement(U1,{rows:w,sort:m,args:h,globals:g,updateArgs:f,resetArgs:v}):null;let x=Y$(i),D=Object.fromEntries(Object.entries(s).map(([b,C])=>[b,{rows:g4(Fj(C,a),d,p),sort:m}])),E={[x]:{rows:w,sort:m},...D};return y.createElement(U$,{tabs:E,sort:m,args:h,globals:g,updateArgs:f,resetArgs:v})},{document:zx}=globalThis,Lx=({className:e,children:t,...r})=>{if(typeof e!="string"&&(typeof t!="string"||!t.match(/[\n\r]/g)))return y.createElement(H8,null,t);let n=e&&e.split("-");return y.createElement(P9,{language:n&&n[1]||"text",format:!1,code:t,...r})};function lh(e,t){e.channel.emit(BL,t)}var q1=hL.a,Rj=({hash:e,children:t})=>{let r=l.useContext(Yt);return y.createElement(q1,{href:e,target:"_self",onClick:n=>{let a=e.substring(1);zx.getElementById(a)&&lh(r,e)}},t)},Ox=e=>{let{href:t,target:r,children:n,...a}=e,o=l.useContext(Yt);return!t||r==="_blank"||/^https?:\/\//.test(t)?y.createElement(q1,{...e}):t.startsWith("#")?y.createElement(Rj,{hash:t},n):y.createElement(q1,{href:t,onClick:i=>{i.button===0&&!i.altKey&&!i.ctrlKey&&!i.metaKey&&!i.shiftKey&&(i.preventDefault(),lh(o,i.currentTarget.getAttribute("href")))},target:r,...a},n)},Mx=["h1","h2","h3","h4","h5","h6"],Ij=Mx.reduce((e,t)=>({...e,[t]:F(t)({"& svg":{position:"relative",top:"-0.1em",visibility:"hidden"},"&:hover svg":{visibility:"visible"}})}),{}),Tj=F.a(()=>({float:"left",lineHeight:"inherit",paddingRight:"10px",marginLeft:"-24px",color:"inherit"})),Bj=({as:e,id:t,children:r,...n})=>{let a=l.useContext(Yt),o=Ij[e],i=`#${t}`;return y.createElement(o,{id:t,...n},y.createElement(Tj,{"aria-hidden":"true",href:i,tabIndex:-1,target:"_self",onClick:s=>{zx.getElementById(t)&&lh(a,i)}},y.createElement(CL,null)),r)},sh=e=>{let{as:t,id:r,children:n,...a}=e;if(r)return y.createElement(Bj,{as:t,id:r,...a},n);let o=t,{as:i,...s}=e;return y.createElement(o,{...le(s,t)})},Px=Mx.reduce((e,t)=>({...e,[t]:r=>y.createElement(sh,{as:t,...r})}),{}),zj=e=>{if(!e.children)return null;if(typeof e.children!="string")throw new Error(Vx`The Markdown block only accepts children as a single string, but children were of type: '${typeof e.children}' diff --git a/assets/DrawerMenu.stories-Bfqecup3.js b/assets/DrawerMenu.stories-CuBmyegk.js similarity index 88% rename from assets/DrawerMenu.stories-Bfqecup3.js rename to assets/DrawerMenu.stories-CuBmyegk.js index b4b1858f..dcfcb2c4 100644 --- a/assets/DrawerMenu.stories-Bfqecup3.js +++ b/assets/DrawerMenu.stories-CuBmyegk.js @@ -1,4 +1,4 @@ -import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{U as a}from"./user-profile-cqTW1cHH.js";import{N as s,C as i,L as c}from"./notifications-BEKrtwGv.js";import{D as t,d as l}from"./DrawerMenu-BNILBemh.js";import{M as r}from"./MenuItem-BFo5ba9w.js";import{S as m}from"./Separator-B6sIYtjz.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./floating-ui.react-CACRriTf.js";const h={title:"Menu/DrawerMenu",component:t,argTypes:{},args:{}},p=n=>e.jsxs(e.Fragment,{children:[e.jsx("div",{className:l.bg}),e.jsxs(t,{...n,title:"Settings",children:[e.jsx(r,{Icon:a,label:"Profile",onSelect:()=>{}}),e.jsx(r,{Icon:s,label:"Notifications",onSelect:()=>{}}),e.jsx(r,{Icon:i,label:"Feedback",onSelect:()=>{}}),e.jsx(m,{}),e.jsx(r,{kind:"critical",Icon:c,label:"Sign out",onSelect:()=>{}})]})]}),o=p.bind({});o.args={};o.parameters={...o.parameters,docs:{...o.parameters?.docs,source:{originalSource:`args => <> +import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{U as a}from"./user-profile-cqTW1cHH.js";import{N as s,C as i,L as c}from"./notifications-BEKrtwGv.js";import{D as t,d as l}from"./DrawerMenu-BNILBemh.js";import{M as r}from"./MenuItem-YyrVQu2n.js";import{S as m}from"./Separator-BbJs_Bbv.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./floating-ui.react-CSvGZjCC.js";const h={title:"Menu/DrawerMenu",component:t,argTypes:{},args:{}},p=n=>e.jsxs(e.Fragment,{children:[e.jsx("div",{className:l.bg}),e.jsxs(t,{...n,title:"Settings",children:[e.jsx(r,{Icon:a,label:"Profile",onSelect:()=>{}}),e.jsx(r,{Icon:s,label:"Notifications",onSelect:()=>{}}),e.jsx(r,{Icon:i,label:"Feedback",onSelect:()=>{}}),e.jsx(m,{}),e.jsx(r,{kind:"critical",Icon:c,label:"Sign out",onSelect:()=>{}})]})]}),o=p.bind({});o.args={};o.parameters={...o.parameters,docs:{...o.parameters?.docs,source:{originalSource:`args => <>
{}} /> diff --git a/assets/Dropdown.stories-D_TlQ6US.js b/assets/Dropdown.stories-DSpAra56.js similarity index 99% rename from assets/Dropdown.stories-D_TlQ6US.js rename to assets/Dropdown.stories-DSpAra56.js index 6e0f896b..a63974dd 100644 --- a/assets/Dropdown.stories-D_TlQ6US.js +++ b/assets/Dropdown.stories-DSpAra56.js @@ -1,4 +1,4 @@ -import{j as r}from"./jsx-runtime-DR9Q75dM.js";import{C as K}from"./chevron-down-vguALCSX.js";import{C as O}from"./check-BWxs5Tf9.js";import{E as Q}from"./error-DOy7ZFuJ.js";import{r as a}from"./index-DRjF_FHU.js";import{c as h}from"./index-lhGYx47h.js";import{u as S}from"./floating-ui.react-CACRriTf.js";import{f as A}from"./index-JRK_GaCU.js";import"./index-BvEl7W6R.js";const H="_container_1b6mf_17",P="_placeholder_1b6mf_56",F="_border_1b6mf_60",B="_content_1b6mf_69",G="_open_1b6mf_117",J="_help_1b6mf_121",M="_error_1b6mf_126",u={container:H,placeholder:P,border:F,content:B,open:G,help:J,error:M},_=a.forwardRef(function({className:n,label:o,placeholder:e,helpLabel:s,onValueChange:p,error:i,defaultValue:g,values:m,...x},d){const[t,v]=Z(m,e,g),[f,C,N]=Y(),{listRef:q,onComboboxKeyDown:z,onOptionKeyDown:L}=$(f,C,v),k=a.useRef(null);a.useEffect(()=>{t.value!==void 0&&k.current?.focus()},[t]);const j=t.text===e,V=h({[u.placeholder]:j}),W=h(u.border,{[u.open]:f}),R=h(u.content,{[u.open]:f}),I=S(),D=S();return r.jsxs("div",{ref:N,className:h(n,u.container),"aria-invalid":!!i,children:[r.jsx("label",{id:I,children:o}),r.jsxs("button",{className:V,role:"combobox","aria-haspopup":"listbox","aria-labelledby":I,"aria-controls":D,"aria-expanded":f,ref:l=>{k.current=l,typeof d=="function"?d(l):d&&(d.current=l)},onClick:()=>C(l=>!l),onKeyDown:z,...x,children:[t.text,r.jsx(K,{width:"24",height:"24"})]}),r.jsx("div",{className:W}),r.jsx("div",{className:R,children:r.jsx("ul",{ref:q,id:D,role:"listbox",className:u.content,children:m.map(([l,T])=>r.jsx(X,{isDisplayed:f,isSelected:t.value===l,onClick:()=>{C(!1),v({value:l,text:T}),p?.(l)},onKeyDown:U=>L(U,l,T),children:T},l))})}),!i&&s&&r.jsx("span",{className:u.help,children:s}),i&&r.jsxs("span",{className:u.error,children:[r.jsx(Q,{width:"20",height:"20"}),i]})]})}),X=a.memo(function({children:n,isSelected:o,isDisplayed:e,...s}){const p=a.useRef(null);return a.useEffect(()=>{o&&e&&p.current?.focus()},[o,e]),r.jsxs("li",{tabIndex:0,role:"option",ref:p,"aria-selected":o,...s,children:[n," ",o&&r.jsx(O,{width:"20",height:"20"})]})});function Y(){const[c,n]=a.useState(!1),o=a.useRef(null);return a.useEffect(()=>{const e=s=>{o.current&&!o.current.contains(s.target)&&n(!1)};return document.addEventListener("click",e),()=>document.removeEventListener("click",e)},[n]),[c,n,o]}function Z(c,n,o){return a.useState(()=>{const e={value:void 0,text:n};if(!o)return e;const s=c.find(([p])=>p===o);return s?{value:s[0],text:s[1]}:e})}function $(c,n,o){const e=a.useRef(null),s=a.useCallback(({key:i})=>{switch(i){case"Escape":n(!1);break;case"ArrowDown":n(!0),c&&e.current?.firstElementChild?.focus();break;case"ArrowUp":n(!0);break;case"Home":{n(!0),Promise.resolve().then(()=>{e.current?.firstElementChild?.focus()});break}case"End":{n(!0),Promise.resolve().then(()=>{e.current?.lastElementChild?.focus()});break}}},[e,c,n]),p=a.useCallback((i,g,m)=>{const{key:x,altKey:d}=i;switch(i.stopPropagation(),i.preventDefault(),x){case"Enter":case" ":{o({text:m,value:g}),n(!1);break}case"Tab":case"Escape":n(!1);break;case"ArrowDown":{const t=document.activeElement;e.current?.contains(t)&&t&&t.nextElementSibling?.focus();break}case"ArrowUp":{if(d)o({text:m,value:g}),n(!1);else{const t=document.activeElement;e.current?.contains(t)&&t&&t.previousElementSibling?.focus()}break}case"Home":{e.current?.firstElementChild?.focus();break}case"End":{e.current?.lastElementChild?.focus();break}}},[e,o,n]);return{listRef:e,onComboboxKeyDown:s,onOptionKeyDown:p}}try{_.displayName="Dropdown",_.__docgenInfo={description:"The dropdown content.",displayName:"Dropdown",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},defaultValue:{defaultValue:null,description:"The default value of the dropdown.",name:"defaultValue",required:!1,type:{name:"string"}},values:{defaultValue:null,description:`The values of the dropdown. +import{j as r}from"./jsx-runtime-DR9Q75dM.js";import{C as K}from"./chevron-down-vguALCSX.js";import{C as O}from"./check-BWxs5Tf9.js";import{E as Q}from"./error-DOy7ZFuJ.js";import{r as a}from"./index-DRjF_FHU.js";import{c as h}from"./index-lhGYx47h.js";import{u as S}from"./floating-ui.react-CSvGZjCC.js";import{f as A}from"./index-JRK_GaCU.js";import"./index-BvEl7W6R.js";const H="_container_1b6mf_17",P="_placeholder_1b6mf_56",F="_border_1b6mf_60",B="_content_1b6mf_69",G="_open_1b6mf_117",J="_help_1b6mf_121",M="_error_1b6mf_126",u={container:H,placeholder:P,border:F,content:B,open:G,help:J,error:M},_=a.forwardRef(function({className:n,label:o,placeholder:e,helpLabel:s,onValueChange:p,error:i,defaultValue:g,values:m,...x},d){const[t,v]=Z(m,e,g),[f,C,N]=Y(),{listRef:q,onComboboxKeyDown:z,onOptionKeyDown:L}=$(f,C,v),k=a.useRef(null);a.useEffect(()=>{t.value!==void 0&&k.current?.focus()},[t]);const j=t.text===e,V=h({[u.placeholder]:j}),W=h(u.border,{[u.open]:f}),R=h(u.content,{[u.open]:f}),I=S(),D=S();return r.jsxs("div",{ref:N,className:h(n,u.container),"aria-invalid":!!i,children:[r.jsx("label",{id:I,children:o}),r.jsxs("button",{className:V,role:"combobox","aria-haspopup":"listbox","aria-labelledby":I,"aria-controls":D,"aria-expanded":f,ref:l=>{k.current=l,typeof d=="function"?d(l):d&&(d.current=l)},onClick:()=>C(l=>!l),onKeyDown:z,...x,children:[t.text,r.jsx(K,{width:"24",height:"24"})]}),r.jsx("div",{className:W}),r.jsx("div",{className:R,children:r.jsx("ul",{ref:q,id:D,role:"listbox",className:u.content,children:m.map(([l,T])=>r.jsx(X,{isDisplayed:f,isSelected:t.value===l,onClick:()=>{C(!1),v({value:l,text:T}),p?.(l)},onKeyDown:U=>L(U,l,T),children:T},l))})}),!i&&s&&r.jsx("span",{className:u.help,children:s}),i&&r.jsxs("span",{className:u.error,children:[r.jsx(Q,{width:"20",height:"20"}),i]})]})}),X=a.memo(function({children:n,isSelected:o,isDisplayed:e,...s}){const p=a.useRef(null);return a.useEffect(()=>{o&&e&&p.current?.focus()},[o,e]),r.jsxs("li",{tabIndex:0,role:"option",ref:p,"aria-selected":o,...s,children:[n," ",o&&r.jsx(O,{width:"20",height:"20"})]})});function Y(){const[c,n]=a.useState(!1),o=a.useRef(null);return a.useEffect(()=>{const e=s=>{o.current&&!o.current.contains(s.target)&&n(!1)};return document.addEventListener("click",e),()=>document.removeEventListener("click",e)},[n]),[c,n,o]}function Z(c,n,o){return a.useState(()=>{const e={value:void 0,text:n};if(!o)return e;const s=c.find(([p])=>p===o);return s?{value:s[0],text:s[1]}:e})}function $(c,n,o){const e=a.useRef(null),s=a.useCallback(({key:i})=>{switch(i){case"Escape":n(!1);break;case"ArrowDown":n(!0),c&&e.current?.firstElementChild?.focus();break;case"ArrowUp":n(!0);break;case"Home":{n(!0),Promise.resolve().then(()=>{e.current?.firstElementChild?.focus()});break}case"End":{n(!0),Promise.resolve().then(()=>{e.current?.lastElementChild?.focus()});break}}},[e,c,n]),p=a.useCallback((i,g,m)=>{const{key:x,altKey:d}=i;switch(i.stopPropagation(),i.preventDefault(),x){case"Enter":case" ":{o({text:m,value:g}),n(!1);break}case"Tab":case"Escape":n(!1);break;case"ArrowDown":{const t=document.activeElement;e.current?.contains(t)&&t&&t.nextElementSibling?.focus();break}case"ArrowUp":{if(d)o({text:m,value:g}),n(!1);else{const t=document.activeElement;e.current?.contains(t)&&t&&t.previousElementSibling?.focus()}break}case"Home":{e.current?.firstElementChild?.focus();break}case"End":{e.current?.lastElementChild?.focus();break}}},[e,o,n]);return{listRef:e,onComboboxKeyDown:s,onOptionKeyDown:p}}try{_.displayName="Dropdown",_.__docgenInfo={description:"The dropdown content.",displayName:"Dropdown",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},defaultValue:{defaultValue:null,description:"The default value of the dropdown.",name:"defaultValue",required:!1,type:{name:"string"}},values:{defaultValue:null,description:`The values of the dropdown. [value, text]`,name:"values",required:!0,type:{name:"[string, string][]"}},placeholder:{defaultValue:null,description:"The placeholder text.",name:"placeholder",required:!0,type:{name:"string"}},label:{defaultValue:null,description:"The label to display at the top of the dropdown",name:"label",required:!0,type:{name:"string"}},helpLabel:{defaultValue:null,description:"The help label to display at the bottom of the dropdown",name:"helpLabel",required:!1,type:{name:"string"}},onValueChange:{defaultValue:null,description:`Callback for when the value changes. @param value`,name:"onValueChange",required:!1,type:{name:"((value: string) => void)"}},error:{defaultValue:null,description:"The error message to display.",name:"error",required:!1,type:{name:"string"}}}}}catch{}const ce={title:"Dropdown",component:_,tags:["autodocs"],parameters:{controls:{include:["defaultValue","placeholder","error"]}},argTypes:{label:{type:"string"},error:{type:"string"},placeholder:{type:"string"},values:{type:"string"}},args:{label:"Label",placeholder:"Select an option",onValueChange:A(),values:[["Option1","Option 1"],["Option2","Option 2"],["Option3","Option 3"]]}},b={parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?node-id=799-5732&t=g2Ex9sbzgku1nTIN-4"}}},w={args:{helpLabel:"Optional help text."},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?node-id=799-345&t=g2Ex9sbzgku1nTIN-4"}}},E={args:{error:"Select an option"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?node-id=799-370&t=g2Ex9sbzgku1nTIN-4"}}},y={args:{defaultValue:"Option2"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?node-id=799-381&t=g2Ex9sbzgku1nTIN-4"}}};b.parameters={...b.parameters,docs:{...b.parameters?.docs,source:{originalSource:`{ parameters: { diff --git a/assets/EditInPlace.stories-tK8qCiZC.js b/assets/EditInPlace.stories-ZKzHSOvw.js similarity index 93% rename from assets/EditInPlace.stories-tK8qCiZC.js rename to assets/EditInPlace.stories-ZKzHSOvw.js index 1b04ccaa..23fb6949 100644 --- a/assets/EditInPlace.stories-tK8qCiZC.js +++ b/assets/EditInPlace.stories-ZKzHSOvw.js @@ -1,6 +1,6 @@ -import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{w as V,u as c,e as Q}from"./index-JRK_GaCU.js";import{R as Y,L as $,S as G,H as J,E as K}from"./Message-t35Ysetp.js";import{a as B,T as X}from"./Tooltip-DGTzhuPA.js";import{r as a}from"./index-DRjF_FHU.js";import{S as Z,V as ee}from"./index-4or38LtJ.js";import{C as te}from"./check-BWxs5Tf9.js";import{C as ae}from"./close-CWATPeIo.js";import{F as ne,L as re}from"./Label-BsNBFg9B.js";import{a as se}from"./Text-DZrEBsw6.js";import{B as R}from"./Button-BORixq-h.js";import"./index-lhGYx47h.js";import"./check-circle-solid-DvGH8qX5.js";import"./error-DOy7ZFuJ.js";import"./InlineSpinner-DDpdhuC2.js";import"./spinner--mCkS-8r.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./UnstyledButton-DuxpNl0e.js";const oe="_controls_1h4nb_17",E={controls:oe,"button-group":"_button-group_1h4nb_27"};function le(e,s){switch(s){case 0:return e===0||e===3?1:e;case 1:return 2;case 4:return 0;case 2:return e===2?3:e;case 3:return e===2?0:e;case 5:return e===3?0:e}ie(s)}function ie(e){throw new Error(`Unreachable value: ${e}`)}const g=a.forwardRef(function({className:s,label:o,onSave:u,onCancel:S,onInput:w,onClearServerErrors:j,serverInvalid:L,saveButtonLabel:H,cancelButtonLabel:_,savedLabel:C,savingLabel:q,helpLabel:T,disabled:F,children:k,...W},P){const[n,l]=a.useReducer(le,0),d=a.useRef(!1),[y,p]=a.useState(!1),M=n===1||n===2||y,i=a.useRef();a.useEffect(()=>(n===3&&(i.current=setTimeout(()=>{l(5),i.current=void 0},2e3)),()=>{i.current&&clearTimeout(i.current),i.current=void 0}),[n]);const N=a.useRef(null),I=a.useRef(null),x=a.useRef(null),O=a.useCallback(()=>{d.current||(d.current=!0,p(!0))},[y,p]),D=a.useCallback(r=>{d.current&&(r.currentTarget.contains(r.relatedTarget)||(d.current=!1,p(!1)))},[y,p]),z=a.useCallback(r=>{l(0),w?.(r)},[l,w]),U=a.useCallback(async r=>{if(r.preventDefault(),n!==0)try{l(1),I.current?.blur(),await u?.(r),l(2)}catch{l(3)}},[u,n,i]),A=a.useCallback(r=>{x.current?.blur(),S?.(r),l(4)},[x,S]);return t.jsx(Y,{className:s,onSubmit:U,onReset:A,onFocus:O,onBlur:D,onClearServerErrors:j,ref:N,children:t.jsxs(ne,{name:"input",serverInvalid:L,children:[t.jsx(re,{children:o}),t.jsxs("div",{className:E.controls,children:[t.jsx(se,{ref:P,...W,onInput:z,disabled:F||n===2}),M&&t.jsxs("div",{className:E["button-group"],children:[t.jsx(B,{label:H,children:t.jsx(Z,{asChild:!0,children:t.jsx(R,{type:"submit",kind:"primary",size:"sm",ref:I,disabled:n!==1,iconOnly:!0,Icon:te})})}),t.jsx(B,{label:_,children:t.jsx(R,{type:"reset",kind:"secondary",size:"sm",ref:x,className:E.button,disabled:n===2,iconOnly:!0,Icon:ae})})]})]}),n===2?t.jsx($,{children:q}):k,C&&n===3&&t.jsx(G,{children:C}),T&&(n===0||n===1)&&t.jsx(ee,{children:r=>(r===void 0||r.valid)&&!L&&t.jsx(J,{children:T})})]})})});try{g.displayName="EditInPlace",g.__docgenInfo={description:`A text box with save/cancel buttons that appear when the field is active. +import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{w as V,u as c,e as Q}from"./index-JRK_GaCU.js";import{R as Y,L as $,S as G,H as J,E as K}from"./Message-t35Ysetp.js";import{a as B,T as X}from"./Tooltip-D2McGlOP.js";import{r as a}from"./index-DRjF_FHU.js";import{S as Z,V as ee}from"./index-4or38LtJ.js";import{C as te}from"./check-BWxs5Tf9.js";import{C as ae}from"./close-CWATPeIo.js";import{F as ne,L as re}from"./Label-BsNBFg9B.js";import{a as se}from"./Text-DZrEBsw6.js";import{B as R}from"./Button-BORixq-h.js";import"./index-lhGYx47h.js";import"./check-circle-solid-DvGH8qX5.js";import"./error-DOy7ZFuJ.js";import"./InlineSpinner-DDpdhuC2.js";import"./spinner--mCkS-8r.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./UnstyledButton-DuxpNl0e.js";const oe="_controls_1h4nb_17",E={controls:oe,"button-group":"_button-group_1h4nb_27"};function le(e,s){switch(s){case 0:return e===0||e===3?1:e;case 1:return 2;case 4:return 0;case 2:return e===2?3:e;case 3:return e===2?0:e;case 5:return e===3?0:e}ie(s)}function ie(e){throw new Error(`Unreachable value: ${e}`)}const g=a.forwardRef(function({className:s,label:o,onSave:u,onCancel:S,onInput:w,onClearServerErrors:j,serverInvalid:L,saveButtonLabel:H,cancelButtonLabel:_,savedLabel:C,savingLabel:q,helpLabel:T,disabled:F,children:k,...W},P){const[n,l]=a.useReducer(le,0),d=a.useRef(!1),[y,p]=a.useState(!1),M=n===1||n===2||y,i=a.useRef();a.useEffect(()=>(n===3&&(i.current=setTimeout(()=>{l(5),i.current=void 0},2e3)),()=>{i.current&&clearTimeout(i.current),i.current=void 0}),[n]);const N=a.useRef(null),I=a.useRef(null),x=a.useRef(null),O=a.useCallback(()=>{d.current||(d.current=!0,p(!0))},[y,p]),D=a.useCallback(r=>{d.current&&(r.currentTarget.contains(r.relatedTarget)||(d.current=!1,p(!1)))},[y,p]),z=a.useCallback(r=>{l(0),w?.(r)},[l,w]),U=a.useCallback(async r=>{if(r.preventDefault(),n!==0)try{l(1),I.current?.blur(),await u?.(r),l(2)}catch{l(3)}},[u,n,i]),A=a.useCallback(r=>{x.current?.blur(),S?.(r),l(4)},[x,S]);return t.jsx(Y,{className:s,onSubmit:U,onReset:A,onFocus:O,onBlur:D,onClearServerErrors:j,ref:N,children:t.jsxs(ne,{name:"input",serverInvalid:L,children:[t.jsx(re,{children:o}),t.jsxs("div",{className:E.controls,children:[t.jsx(se,{ref:P,...W,onInput:z,disabled:F||n===2}),M&&t.jsxs("div",{className:E["button-group"],children:[t.jsx(B,{label:H,children:t.jsx(Z,{asChild:!0,children:t.jsx(R,{type:"submit",kind:"primary",size:"sm",ref:I,disabled:n!==1,iconOnly:!0,Icon:te})})}),t.jsx(B,{label:_,children:t.jsx(R,{type:"reset",kind:"secondary",size:"sm",ref:x,className:E.button,disabled:n===2,iconOnly:!0,Icon:ae})})]})]}),n===2?t.jsx($,{children:q}):k,C&&n===3&&t.jsx(G,{children:C}),T&&(n===0||n===1)&&t.jsx(ee,{children:r=>(r===void 0||r.valid)&&!L&&t.jsx(J,{children:T})})]})})});try{g.displayName="EditInPlace",g.__docgenInfo={description:`A text box with save/cancel buttons that appear when the field is active. Since thios control has its own 'save' button, it should *not* appear as part -of a larger form: it exists as its own form that submits separately.`,displayName:"EditInPlace",props:{disabled:{defaultValue:null,description:"If true, disabled the entire component to disallow editing.",name:"disabled",required:!1,type:{name:"boolean"}},label:{defaultValue:null,description:"The label for the control",name:"label",required:!0,type:{name:"string"}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},onInput:{defaultValue:null,description:"onInput event handler on the text control",name:"onInput",required:!1,type:{name:"(((e: ChangeEvent) => void) & FormEventHandler)"}},helpLabel:{defaultValue:null,description:"Label to be displayed under the input as a help text",name:"helpLabel",required:!1,type:{name:"string"}},serverInvalid:{defaultValue:null,description:`Whether the field is in an error state according to the server validation. +of a larger form: it exists as its own form that submits separately.`,displayName:"EditInPlace",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},disabled:{defaultValue:null,description:"If true, disabled the entire component to disallow editing.",name:"disabled",required:!1,type:{name:"boolean"}},label:{defaultValue:null,description:"The label for the control",name:"label",required:!0,type:{name:"string"}},onInput:{defaultValue:null,description:"onInput event handler on the text control",name:"onInput",required:!1,type:{name:"(((e: ChangeEvent) => void) & FormEventHandler)"}},helpLabel:{defaultValue:null,description:"Label to be displayed under the input as a help text",name:"helpLabel",required:!1,type:{name:"string"}},serverInvalid:{defaultValue:null,description:`Whether the field is in an error state according to the server validation. For validation messages, use native validations properties directly, or add custom error messages as children.`,name:"serverInvalid",required:!1,type:{name:"boolean"}},onClearServerErrors:{defaultValue:null,description:"Callback for when the server validation errors should be cleared.",name:"onClearServerErrors",required:!1,type:{name:"(() => void)"}},enableLigatures:{defaultValue:null,description:`Enable contextual alternate ligatures on input text For example on an in-place editing field diff --git a/assets/FloatingMenu.stories-bTTpHRmg.js b/assets/FloatingMenu.stories-CVZ8ATHp.js similarity index 88% rename from assets/FloatingMenu.stories-bTTpHRmg.js rename to assets/FloatingMenu.stories-CVZ8ATHp.js index 539e4fd4..cb96fdef 100644 --- a/assets/FloatingMenu.stories-bTTpHRmg.js +++ b/assets/FloatingMenu.stories-CVZ8ATHp.js @@ -1,4 +1,4 @@ -import{j as o}from"./jsx-runtime-DR9Q75dM.js";import{U as a}from"./user-profile-cqTW1cHH.js";import{N as r,C as s,L as c}from"./notifications-BEKrtwGv.js";import{F as n}from"./FloatingMenu-Dc89G4Nf.js";import{M as t}from"./MenuItem-BFo5ba9w.js";import{S as l}from"./Separator-B6sIYtjz.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./floating-ui.react-CACRriTf.js";const P={title:"Menu/FloatingMenu",component:n,argTypes:{},args:{}},m=i=>o.jsxs(n,{...i,title:"Settings",children:[o.jsx(t,{Icon:a,label:"Profile",onSelect:()=>{}}),o.jsx(t,{Icon:r,label:"Notificationsnotificationsnotifications",onSelect:()=>{}}),o.jsx(t,{Icon:s,label:"Feedback",onSelect:()=>{}}),o.jsx(l,{}),o.jsx(t,{kind:"critical",Icon:c,label:"Sign out",onSelect:()=>{}})]}),e=m.bind({});e.args={};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`args => +import{j as o}from"./jsx-runtime-DR9Q75dM.js";import{U as a}from"./user-profile-cqTW1cHH.js";import{N as r,C as s,L as c}from"./notifications-BEKrtwGv.js";import{F as n}from"./FloatingMenu-Dc89G4Nf.js";import{M as t}from"./MenuItem-YyrVQu2n.js";import{S as l}from"./Separator-BbJs_Bbv.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./floating-ui.react-CSvGZjCC.js";const P={title:"Menu/FloatingMenu",component:n,argTypes:{},args:{}},m=i=>o.jsxs(n,{...i,title:"Settings",children:[o.jsx(t,{Icon:a,label:"Profile",onSelect:()=>{}}),o.jsx(t,{Icon:r,label:"Notificationsnotificationsnotifications",onSelect:()=>{}}),o.jsx(t,{Icon:s,label:"Feedback",onSelect:()=>{}}),o.jsx(l,{}),o.jsx(t,{kind:"critical",Icon:c,label:"Sign out",onSelect:()=>{}})]}),e=m.bind({});e.args={};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`args => {}} /> {/* Extra long label to demonstrate word breaking */} {}} /> diff --git a/assets/Form.stories--cHTjAzR.js b/assets/Form.stories-Bn4-T6XU.js similarity index 94% rename from assets/Form.stories--cHTjAzR.js rename to assets/Form.stories-Bn4-T6XU.js index 751391c4..8fe13c07 100644 --- a/assets/Form.stories--cHTjAzR.js +++ b/assets/Form.stories-Bn4-T6XU.js @@ -1,4 +1,4 @@ -import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{T as v}from"./Tooltip-DGTzhuPA.js";import{R as S,E as a,H as o}from"./Message-t35Ysetp.js";import{s as u,F as p,L as n}from"./Label-BsNBFg9B.js";import{a as _}from"./Text-DZrEBsw6.js";import{a as C}from"./Password-BPLQ51Y-.js";import{a as I}from"./MFA-BqVpayht.js";import{r as x}from"./index-DRjF_FHU.js";import{F as E,S as V}from"./index-4or38LtJ.js";import{c as k}from"./index-lhGYx47h.js";import{a as N}from"./Checkbox-CiKmyzre.js";import{a as f}from"./Radio-2VunTFL7.js";import{a as F}from"./Toggle-BRCP4wr-.js";import{B as T}from"./Button-BORixq-h.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";import"./check-circle-solid-DvGH8qX5.js";import"./error-DOy7ZFuJ.js";import"./InlineSpinner-DDpdhuC2.js";import"./spinner--mCkS-8r.js";import"./visibility-on-BsZOuBEH.js";import"./Action-BnShWVrx.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./check-BWxs5Tf9.js";import"./UnstyledButton-DuxpNl0e.js";const i=x.forwardRef(function({className:r,control:t,children:b,...j},g){const y=k(u["inline-field"],r);return e.jsxs(E,{ref:g,...j,className:y,children:[e.jsx("div",{className:u["inline-field-control"],children:t}),e.jsx("div",{className:u["inline-field-body"],children:b})]})});try{i.displayName="InlineField",i.__docgenInfo={description:"",displayName:"InlineField",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},asChild:{defaultValue:null,description:"",name:"asChild",required:!1,type:{name:"boolean"}},control:{defaultValue:null,description:"The checkbox/radio control to render alongside the rest of the field.",name:"control",required:!0,type:{name:"ReactElement>"}}}}}catch{}const h=x.forwardRef(function(r,t){return e.jsx(V,{asChild:!0,children:e.jsx(T,{type:"submit",ref:t,...r})})});try{h.displayName="Submit",h.__docgenInfo={description:"A stylised submit button for forms.",displayName:"Submit",props:{disabled:{defaultValue:null,description:"Note that disabled attribute is not added to buttons, so that disabled buttons are discoverable by keyboard.\n`aria-disabled` attribute is used to indicate button is disabled.\nEvent handlers are not passed to disabled buttons (onClick, onSubmit, etc.)",name:"disabled",required:!1,type:{name:"boolean"}},kind:{defaultValue:null,description:`The type of button. +import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{T as v}from"./Tooltip-D2McGlOP.js";import{R as S,E as a,H as o}from"./Message-t35Ysetp.js";import{s as u,F as p,L as n}from"./Label-BsNBFg9B.js";import{a as _}from"./Text-DZrEBsw6.js";import{a as C}from"./Password-Dm026fYh.js";import{a as I}from"./MFA-ECyXoHb1.js";import{r as x}from"./index-DRjF_FHU.js";import{F as E,S as V}from"./index-4or38LtJ.js";import{c as k}from"./index-lhGYx47h.js";import{a as N}from"./Checkbox-CiKmyzre.js";import{a as f}from"./Radio-2VunTFL7.js";import{a as F}from"./Toggle-BRCP4wr-.js";import{B as T}from"./Button-BORixq-h.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";import"./check-circle-solid-DvGH8qX5.js";import"./error-DOy7ZFuJ.js";import"./InlineSpinner-DDpdhuC2.js";import"./spinner--mCkS-8r.js";import"./visibility-on-BsZOuBEH.js";import"./Action-CwOAv2fk.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./check-BWxs5Tf9.js";import"./UnstyledButton-DuxpNl0e.js";const i=x.forwardRef(function({className:r,control:t,children:b,...j},g){const y=k(u["inline-field"],r);return e.jsxs(E,{ref:g,...j,className:y,children:[e.jsx("div",{className:u["inline-field-control"],children:t}),e.jsx("div",{className:u["inline-field-body"],children:b})]})});try{i.displayName="InlineField",i.__docgenInfo={description:"",displayName:"InlineField",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},asChild:{defaultValue:null,description:"",name:"asChild",required:!1,type:{name:"boolean"}},control:{defaultValue:null,description:"The checkbox/radio control to render alongside the rest of the field.",name:"control",required:!0,type:{name:"ReactElement>"}}}}}catch{}const h=x.forwardRef(function(r,t){return e.jsx(V,{asChild:!0,children:e.jsx(T,{type:"submit",ref:t,...r})})});try{h.displayName="Submit",h.__docgenInfo={description:"A stylised submit button for forms.",displayName:"Submit",props:{disabled:{defaultValue:null,description:"Note that disabled attribute is not added to buttons, so that disabled buttons are discoverable by keyboard.\n`aria-disabled` attribute is used to indicate button is disabled.\nEvent handlers are not passed to disabled buttons (onClick, onSubmit, etc.)",name:"disabled",required:!1,type:{name:"boolean"}},kind:{defaultValue:null,description:`The type of button. Note: "destructive" is deprecated, please use the destructive prop in conjunction with another button kind.`,name:"kind",required:!1,type:{name:"enum",value:[{value:'"primary"'},{value:'"secondary"'},{value:'"tertiary"'},{value:'"destructive"'}]}},destructive:{defaultValue:{value:"false"},description:"Whether this button triggers a destructive action.",name:"destructive",required:!1,type:{name:"boolean"}},size:{defaultValue:null,description:"The t-shirt size of the button.",name:"size",required:!1,type:{name:"enum",value:[{value:'"sm"'},{value:'"lg"'}]}},iconOnly:{defaultValue:null,description:"Whether the button is an icon only button.",name:"iconOnly",required:!1,type:{name:"boolean"}},Icon:{defaultValue:null,description:"An icon to display within the button.",name:"Icon",required:!1,type:{name:"ComponentType>"}}}}}catch{}const H=({disabled:s,invalid:r,readOnly:t})=>e.jsx(v,{children:e.jsxs(S,{children:[e.jsxs(p,{serverInvalid:r,name:"mxid",children:[e.jsx(n,{children:"Username"}),e.jsx(_,{disabled:s,readOnly:t,defaultValue:"Hello world!"}),r?e.jsx(a,{children:"Error message."}):e.jsx(o,{children:"Help message."})]}),e.jsxs(p,{serverInvalid:r,name:"password",children:[e.jsx(n,{children:"Password"}),e.jsx(C,{disabled:s,readOnly:t,defaultValue:"sup3rS3cur3p4ssw0rd!"}),r?e.jsx(a,{children:"Error message."}):e.jsx(o,{children:"Help message."})]}),e.jsxs(p,{serverInvalid:r,name:"mfa",children:[e.jsx(n,{children:"MFA"}),e.jsx(I,{disabled:s,readOnly:t,defaultValue:"123"}),r?e.jsx(a,{children:"Error message."}):e.jsx(o,{children:"Help message."})]}),e.jsxs(i,{serverInvalid:r,name:"remember",control:e.jsx(N,{disabled:s,readOnly:t,defaultChecked:!0}),children:[e.jsx(n,{children:"Remember me"}),r?e.jsx(a,{children:"Error message."}):e.jsx(o,{children:"Help message."})]}),e.jsxs(i,{serverInvalid:r,name:"radio",control:e.jsx(f,{disabled:s,readOnly:t,defaultChecked:!0}),children:[e.jsx(n,{children:"Option 1"}),r?e.jsx(a,{children:"Error message."}):e.jsx(o,{children:"Help message."})]}),e.jsxs(i,{serverInvalid:r,name:"radio",control:e.jsx(f,{disabled:s,readOnly:t,defaultChecked:!0}),children:[e.jsx(n,{children:"Option 2"}),r?e.jsx(a,{children:"Error message."}):e.jsx(o,{children:"Help message."})]}),e.jsxs(i,{serverInvalid:r,name:"toggle",control:e.jsx(F,{disabled:s,readOnly:t,defaultChecked:!0}),children:[e.jsx(n,{children:"Toggle"}),r?e.jsx(a,{children:"Error message."}):e.jsx(o,{children:"Help message."})]}),e.jsx(h,{disabled:s,children:"Submit"})]})}),ie={title:"Form/Kitchen Sink",component:H,argTypes:{disabled:{type:"boolean"},readOnly:{type:"boolean"},invalid:{type:"boolean"}},args:{disabled:!1,readOnly:!1,invalid:!1}},l={},d={args:{disabled:!0}},c={args:{readOnly:!0}},m={args:{invalid:!0}};l.parameters={...l.parameters,docs:{...l.parameters?.docs,source:{originalSource:"{}",...l.parameters?.docs?.source}}};d.parameters={...d.parameters,docs:{...d.parameters?.docs,source:{originalSource:`{ args: { diff --git a/assets/IconButton-CBGH5UyO.js b/assets/IconButton-Bf1MsgYV.js similarity index 94% rename from assets/IconButton-CBGH5UyO.js rename to assets/IconButton-Bf1MsgYV.js index 95b58c06..413cc48c 100644 --- a/assets/IconButton-CBGH5UyO.js +++ b/assets/IconButton-Bf1MsgYV.js @@ -1,4 +1,4 @@ -import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{r as y,R as v}from"./index-DRjF_FHU.js";import{c as _}from"./index-lhGYx47h.js";import{U as g}from"./UnstyledButton-DuxpNl0e.js";import{I}from"./IndicatorIcon-CKMK3E77.js";import{a as x}from"./Tooltip-DGTzhuPA.js";const q="_destructive_bh2qc_83",e={"icon-button":"_icon-button_bh2qc_17","subtle-bg":"_subtle-bg_bh2qc_38",destructive:q},s=y.forwardRef(function({children:l,className:d,indicator:o,size:u="32px",style:c,disabled:n,destructive:b,tooltip:a,subtleBackground:p,...m},h){const f=_(e["icon-button"],d,{[e.destructive]:b,[e["subtle-bg"]]:p}),i=t.jsx(g,{as:"button",ref:h,className:f,style:{"--cpd-icon-button-size":u,...c},disabled:n,...m,"data-indicator":o,children:t.jsx(I,{indicator:o,colour:n?"var(--cpd-color-icon-disabled)":void 0,children:v.Children.only(l)})});return a?t.jsx(x,{label:a,children:i}):i});try{s.displayName="IconButton",s.__docgenInfo={description:"Display an icon as a button. Can render an indicator",displayName:"IconButton",props:{disabled:{defaultValue:null,description:`Note that disabled attribute is not added to buttons, so that disabled buttons are discoverable by keyboard. +import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{r as y,R as v}from"./index-DRjF_FHU.js";import{c as _}from"./index-lhGYx47h.js";import{U as g}from"./UnstyledButton-DuxpNl0e.js";import{I}from"./IndicatorIcon-CKMK3E77.js";import{a as x}from"./Tooltip-D2McGlOP.js";const q="_destructive_bh2qc_83",e={"icon-button":"_icon-button_bh2qc_17","subtle-bg":"_subtle-bg_bh2qc_38",destructive:q},s=y.forwardRef(function({children:l,className:d,indicator:o,size:u="32px",style:c,disabled:n,destructive:b,tooltip:a,subtleBackground:p,...m},h){const f=_(e["icon-button"],d,{[e.destructive]:b,[e["subtle-bg"]]:p}),i=t.jsx(g,{as:"button",ref:h,className:f,style:{"--cpd-icon-button-size":u,...c},disabled:n,...m,"data-indicator":o,children:t.jsx(I,{indicator:o,colour:n?"var(--cpd-color-icon-disabled)":void 0,children:v.Children.only(l)})});return a?t.jsx(x,{label:a,children:i}):i});try{s.displayName="IconButton",s.__docgenInfo={description:"Display an icon as a button. Can render an indicator",displayName:"IconButton",props:{disabled:{defaultValue:null,description:`Note that disabled attribute is not added to buttons, so that disabled buttons are discoverable by keyboard. \`aria-disabled\` attribute is used to indicate button is disabled. Event handlers are not passed to disabled buttons (onClick, onSubmit, etc.) Whether the button is interactable`,name:"disabled",required:!1,type:{name:"boolean"}},destructive:{defaultValue:{value:"false"},description:"Whether this button triggers a destructive action.",name:"destructive",required:!1,type:{name:"boolean"}},size:{defaultValue:{value:"32px"},description:'The size of the button in CSS units, e.g. `"24px"`.\nNote that this is the size of the *button* itself: the icon will be 0.75 * this size',name:"size",required:!1,type:{name:"string"}},tooltip:{defaultValue:null,description:"Optional tooltip for the button",name:"tooltip",required:!1,type:{name:"string"}},indicator:{defaultValue:null,description:`The icon button indicator dot displayed on the top right diff --git a/assets/IconButton.stories-Kt8Z7I-O.js b/assets/IconButton.stories-DXn3ooYc.js similarity index 96% rename from assets/IconButton.stories-Kt8Z7I-O.js rename to assets/IconButton.stories-DXn3ooYc.js index ee22e7c4..d0c76ded 100644 --- a/assets/IconButton.stories-Kt8Z7I-O.js +++ b/assets/IconButton.stories-DXn3ooYc.js @@ -1,4 +1,4 @@ -import{j as r}from"./jsx-runtime-DR9Q75dM.js";import{f as g}from"./index-JRK_GaCU.js";import{I as p}from"./IconButton-CBGH5UyO.js";import{U as m}from"./user-profile-cqTW1cHH.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";import"./IndicatorIcon-CKMK3E77.js";import"./Tooltip-DGTzhuPA.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";const z={title:"Button/IconButton",component:p,tags:["autodocs"],argTypes:{control:{type:"boolean"},onClick:{action:"onClick"}},args:{size:"32px",disabled:!1,children:r.jsx(m,{}),onClick:g()}},I=l=>r.jsxs(r.Fragment,{children:[r.jsx(p,{...l,size:"32px",children:r.jsx(m,{})}),r.jsx(p,{...l,size:"48px",children:r.jsx(m,{})}),r.jsx(p,{...l,size:"64px",children:r.jsx(m,{})})]}),e=I.bind({}),s={args:{}},a={args:{disabled:!0}},o={args:{indicator:"default"}},t={args:{indicator:"default",disabled:!0}},n={args:{indicator:"success"}},c={args:{indicator:"critical"}},i={args:{subtleBackground:!0}},d={args:{label:"label"}},u={args:{destructive:"true"}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`args => <> +import{j as r}from"./jsx-runtime-DR9Q75dM.js";import{f as g}from"./index-JRK_GaCU.js";import{I as p}from"./IconButton-Bf1MsgYV.js";import{U as m}from"./user-profile-cqTW1cHH.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";import"./IndicatorIcon-CKMK3E77.js";import"./Tooltip-D2McGlOP.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";const z={title:"Button/IconButton",component:p,tags:["autodocs"],argTypes:{control:{type:"boolean"},onClick:{action:"onClick"}},args:{size:"32px",disabled:!1,children:r.jsx(m,{}),onClick:g()}},I=l=>r.jsxs(r.Fragment,{children:[r.jsx(p,{...l,size:"32px",children:r.jsx(m,{})}),r.jsx(p,{...l,size:"48px",children:r.jsx(m,{})}),r.jsx(p,{...l,size:"64px",children:r.jsx(m,{})})]}),e=I.bind({}),s={args:{}},a={args:{disabled:!0}},o={args:{indicator:"default"}},t={args:{indicator:"default",disabled:!0}},n={args:{indicator:"success"}},c={args:{indicator:"critical"}},i={args:{subtleBackground:!0}},d={args:{label:"label"}},u={args:{destructive:"true"}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`args => <> diff --git a/assets/Link.stories-BZPSqP68.js b/assets/Link.stories-DKUKuDDV.js similarity index 65% rename from assets/Link.stories-BZPSqP68.js rename to assets/Link.stories-DKUKuDDV.js index 16f25c52..f96c83de 100644 --- a/assets/Link.stories-BZPSqP68.js +++ b/assets/Link.stories-DKUKuDDV.js @@ -1 +1 @@ -import{j as n}from"./jsx-runtime-DR9Q75dM.js";import{r as l}from"./index-DRjF_FHU.js";import{c as p}from"./index-lhGYx47h.js";const m="_link_1mzip_17",d={link:m},r=l.forwardRef(function({children:s,className:o,kind:t="primary",...i},c){return n.jsx("a",{ref:c,...i,rel:"noreferrer noopener",className:p(d.link,o),"data-kind":t,children:s})});try{r.displayName="Link",r.__docgenInfo={description:"A link component.",displayName:"Link",props:{kind:{defaultValue:{value:"primary"},description:"The type of link.",name:"kind",required:!1,type:{name:"enum",value:[{value:'"primary"'},{value:'"critical"'}]}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}}}}}catch{}const y={title:"Link",component:r,tags:["autodocs"],argTypes:{},args:{}},u=a=>n.jsx(r,{...a,children:"Text link"}),e=u.bind({});e.args={};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:"args => Text link",...e.parameters?.docs?.source}}};const g=["Round"];export{e as Round,g as __namedExportsOrder,y as default}; +import{j as n}from"./jsx-runtime-DR9Q75dM.js";import{r as l}from"./index-DRjF_FHU.js";import{c as p}from"./index-lhGYx47h.js";const m="_link_1mzip_17",d={link:m},r=l.forwardRef(function({children:s,className:o,kind:t="primary",...i},c){return n.jsx("a",{ref:c,...i,rel:"noreferrer noopener",className:p(d.link,o),"data-kind":t,children:s})});try{r.displayName="Link",r.__docgenInfo={description:"A link component.",displayName:"Link",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},kind:{defaultValue:{value:"primary"},description:"The type of link.",name:"kind",required:!1,type:{name:"enum",value:[{value:'"critical"'},{value:'"primary"'}]}}}}}catch{}const y={title:"Link",component:r,tags:["autodocs"],argTypes:{},args:{}},u=a=>n.jsx(r,{...a,children:"Text link"}),e=u.bind({});e.args={};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:"args => Text link",...e.parameters?.docs?.source}}};const g=["Round"];export{e as Round,g as __namedExportsOrder,y as default}; diff --git a/assets/MFA-BqVpayht.js b/assets/MFA-ECyXoHb1.js similarity index 73% rename from assets/MFA-BqVpayht.js rename to assets/MFA-ECyXoHb1.js index bb9def69..e299eb51 100644 --- a/assets/MFA-BqVpayht.js +++ b/assets/MFA-ECyXoHb1.js @@ -1 +1 @@ -import{j as a}from"./jsx-runtime-DR9Q75dM.js";import{r as m,R as u}from"./index-DRjF_FHU.js";import{c as M}from"./index-lhGYx47h.js";import{C as N}from"./index-4or38LtJ.js";const A="_container_9zyti_18",C="_control_9zyti_33",v="_digit_9zyti_57",i={container:A,control:C,digit:v},x=({filled:o,selected:s})=>a.jsx("div",{className:i.digit,"aria-hidden":"true","data-filled":o?"":void 0,"data-selected":s?"":void 0}),c=m.forwardRef(function({className:s,length:r=6,...f},_){const y=M(i.container,s),[g,h]=u.useState(0),[l,d]=u.useState(null),e=t=>{const n=t.currentTarget;h(n.value?.length),document.activeElement!==n||n.selectionStart===null||n.selectionEnd===null?d(null):d([n.selectionStart,n.selectionEnd])};return a.jsxs("div",{className:y,children:[a.jsx("input",{...f,inputMode:"numeric",type:"text",minLength:0,maxLength:r,className:i.control,pattern:`\\d{${r}}`,autoComplete:"one-time-code",onSelect:e,onFocus:e,onBlur:e,onMouseDown:e,onMouseMove:e,onMouseUp:e,onChange:e,ref:_}),Array.from(Array(r).keys()).map(t=>a.jsx(x,{filled:t=l[0]&&ta.jsx("div",{className:i.digit,"aria-hidden":"true","data-filled":o?"":void 0,"data-selected":s?"":void 0}),c=m.forwardRef(function({className:s,length:r=6,...f},_){const y=M(i.container,s),[g,h]=u.useState(0),[l,d]=u.useState(null),e=t=>{const n=t.currentTarget;h(n.value?.length),document.activeElement!==n||n.selectionStart===null||n.selectionEnd===null?d(null):d([n.selectionStart,n.selectionEnd])};return a.jsxs("div",{className:y,children:[a.jsx("input",{...f,inputMode:"numeric",type:"text",minLength:0,maxLength:r,className:i.control,pattern:`\\d{${r}}`,autoComplete:"one-time-code",onSelect:e,onFocus:e,onBlur:e,onMouseDown:e,onMouseMove:e,onMouseUp:e,onChange:e,ref:_}),Array.from(Array(r).keys()).map(t=>a.jsx(x,{filled:t=l[0]&&tp.jsx(t,{...i,"data-invalid":d||void 0}),tags:["autodocs"],parameters:{controls:{include:["defaultValue","disabled","readOnly","invalid"]}},argTypes:{defaultValue:{type:"string"},autoFocus:{type:"boolean"},disabled:{type:"boolean"},readOnly:{type:"boolean"}},args:{defaultValue:"",autoFocus:!1,disabled:!1,readOnly:!1,invalid:!1}},e={parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4786"}}},a={args:{defaultValue:"012345"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4827"}}},n={args:{defaultValue:"012345",disabled:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4821"}}},o={args:{defaultValue:"012345",readOnly:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=2126-21991"}}},r={args:{defaultValue:"012",autoFocus:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4805"}}},s={args:{invalid:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4814"}}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ +import{j as p}from"./jsx-runtime-DR9Q75dM.js";import{M as t}from"./MFA-ECyXoHb1.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";const b={title:"Form/Controls/MFA",component:t,render:({invalid:d,...i})=>p.jsx(t,{...i,"data-invalid":d||void 0}),tags:["autodocs"],parameters:{controls:{include:["defaultValue","disabled","readOnly","invalid"]}},argTypes:{defaultValue:{type:"string"},autoFocus:{type:"boolean"},disabled:{type:"boolean"},readOnly:{type:"boolean"}},args:{defaultValue:"",autoFocus:!1,disabled:!1,readOnly:!1,invalid:!1}},e={parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4786"}}},a={args:{defaultValue:"012345"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4827"}}},n={args:{defaultValue:"012345",disabled:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4821"}}},o={args:{defaultValue:"012345",readOnly:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=2126-21991"}}},r={args:{defaultValue:"012",autoFocus:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4805"}}},s={args:{invalid:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4814"}}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ parameters: { design: { type: "figma", diff --git a/assets/Menu.stories-BT7voQpJ.js b/assets/Menu.stories-h49MhKU-.js similarity index 97% rename from assets/Menu.stories-BT7voQpJ.js rename to assets/Menu.stories-h49MhKU-.js index f2f3e184..674679f9 100644 --- a/assets/Menu.stories-BT7voQpJ.js +++ b/assets/Menu.stories-h49MhKU-.js @@ -1,4 +1,4 @@ -import{j as a}from"./jsx-runtime-DR9Q75dM.js";import{r as i}from"./index-DRjF_FHU.js";import{U as L}from"./user-profile-cqTW1cHH.js";import{N as B,C as U,L as q}from"./notifications-BEKrtwGv.js";import{c as b,u as S}from"./index-CGa_gRws.js";import{c as F}from"./index-C8xBnYIG.js";import{c as C,A as V,C as $,G as W,L as K,I as H,a as X,R as z,b as J,d as Q,S as Y,e as Z,f as ee,g as oe,i as ne,h as re,P as te,D as w}from"./index-JSxJwvkz.js";import{P as ae}from"./index-Ksfxd92j.js";import{F as se}from"./FloatingMenu-Dc89G4Nf.js";import{c as ie}from"./index-lhGYx47h.js";import{d as ce,D as ue,g as pe}from"./DrawerMenu-BNILBemh.js";import{a as de,M as x}from"./MenuItem-BFo5ba9w.js";import{S as le}from"./Separator-B6sIYtjz.js";import{B as me}from"./Button-BORixq-h.js";import"./index-BXwbELbV.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./UnstyledButton-DuxpNl0e.js";function fe(e,n=[]){let o=[];function r(c,u){const s=i.createContext(u),p=o.length;o=[...o,u];const m=l=>{const{scope:h,children:D,...g}=l,k=h?.[e]?.[p]||s,G=i.useMemo(()=>g,Object.values(g));return a.jsx(k.Provider,{value:G,children:D})};m.displayName=c+"Provider";function f(l,h){const D=h?.[e]?.[p]||s,g=i.useContext(D);if(g)return g;if(u!==void 0)return u;throw new Error(`\`${l}\` must be used within \`${c}\``)}return[m,f]}const t=()=>{const c=o.map(u=>i.createContext(u));return function(s){const p=s?.[e]||c;return i.useMemo(()=>({[`__scope${e}`]:{...s,[e]:p}}),[s,p])}};return t.scopeName=e,[r,he(t,...n)]}function he(...e){const n=e[0];if(e.length===1)return n;const o=()=>{const r=e.map(t=>({useScope:t(),scopeName:t.scopeName}));return function(c){const u=r.reduce((s,{useScope:p,scopeName:m})=>{const l=p(c)[`__scope${m}`];return{...s,...l}},{});return i.useMemo(()=>({[`__scope${n.scopeName}`]:u}),[u])}};return o.scopeName=n.scopeName,o}var _="DropdownMenu",[ge,mo]=fe(_,[C]),d=C(),[we,y]=ge(_),N=e=>{const{__scopeDropdownMenu:n,children:o,dir:r,open:t,defaultOpen:c,onOpenChange:u,modal:s=!0}=e,p=d(n),m=i.useRef(null),[f=!1,l]=ne({prop:t,defaultProp:c,onChange:u});return a.jsx(we,{scope:n,triggerId:S(),triggerRef:m,contentId:S(),open:f,onOpenChange:l,onOpenToggle:i.useCallback(()=>l(h=>!h),[l]),modal:s,children:a.jsx(re,{...p,open:f,onOpenChange:l,dir:r,modal:s,children:o})})};N.displayName=_;var R="DropdownMenuTrigger",P=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,disabled:r=!1,...t}=e,c=y(R,o),u=d(o);return a.jsx(V,{asChild:!0,...u,children:a.jsx(ae.button,{type:"button",id:c.triggerId,"aria-haspopup":"menu","aria-expanded":c.open,"aria-controls":c.open?c.contentId:void 0,"data-state":c.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...t,ref:F(n,c.triggerRef),onPointerDown:b(e.onPointerDown,s=>{!r&&s.button===0&&s.ctrlKey===!1&&(c.onOpenToggle(),c.open||s.preventDefault())}),onKeyDown:b(e.onKeyDown,s=>{r||(["Enter"," "].includes(s.key)&&c.onOpenToggle(),s.key==="ArrowDown"&&c.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});P.displayName=R;var Me="DropdownMenuPortal",j=e=>{const{__scopeDropdownMenu:n,...o}=e,r=d(n);return a.jsx(te,{...r,...o})};j.displayName=Me;var T="DropdownMenuContent",O=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=y(T,o),c=d(o),u=i.useRef(!1);return a.jsx($,{id:t.contentId,"aria-labelledby":t.triggerId,...c,...r,ref:n,onCloseAutoFocus:b(e.onCloseAutoFocus,s=>{u.current||t.triggerRef.current?.focus(),u.current=!1,s.preventDefault()}),onInteractOutside:b(e.onInteractOutside,s=>{const p=s.detail.originalEvent,m=p.button===0&&p.ctrlKey===!0,f=p.button===2||m;(!t.modal||f)&&(u.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});O.displayName=T;var ve="DropdownMenuGroup",xe=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(W,{...t,...r,ref:n})});xe.displayName=ve;var be="DropdownMenuLabel",Ie=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(K,{...t,...r,ref:n})});Ie.displayName=be;var De="DropdownMenuItem",E=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(H,{...t,...r,ref:n})});E.displayName=De;var _e="DropdownMenuCheckboxItem",Se=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(X,{...t,...r,ref:n})});Se.displayName=_e;var Ce="DropdownMenuRadioGroup",ye=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(z,{...t,...r,ref:n})});ye.displayName=Ce;var Ne="DropdownMenuRadioItem",Re=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(J,{...t,...r,ref:n})});Re.displayName=Ne;var Pe="DropdownMenuItemIndicator",je=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(Q,{...t,...r,ref:n})});je.displayName=Pe;var Te="DropdownMenuSeparator",Oe=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(Y,{...t,...r,ref:n})});Oe.displayName=Te;var Ee="DropdownMenuArrow",Ae=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(Z,{...t,...r,ref:n})});Ae.displayName=Ee;var ke="DropdownMenuSubTrigger",Ge=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(ee,{...t,...r,ref:n})});Ge.displayName=ke;var Le="DropdownMenuSubContent",Be=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(oe,{...t,...r,ref:n,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Be.displayName=Le;var Ue=N,qe=P,Fe=j,Ve=O;const $e=({onSelect:e,children:n})=>a.jsx(E,{onSelect:e??void 0,asChild:!0,children:n}),I=({title:e,showTitle:n=!0,open:o,onOpenChange:r,trigger:t,children:c,side:u="bottom",align:s="center"})=>{const p=pe(),m=p==="android"||p==="ios",f=i.useMemo(()=>({MenuItemWrapper:m?null:$e,onOpenChange:r}),[r]),l=a.jsx(de.Provider,{value:f,children:c});return m?a.jsxs(w.Root,{open:o,onOpenChange:r,children:[a.jsx(w.Trigger,{asChild:!0,children:t}),a.jsxs(w.Portal,{children:[a.jsx(w.Overlay,{className:ie(ce.bg)}),a.jsx(w.Content,{asChild:!0,children:a.jsx(ue,{title:e,children:l})})]})]}):a.jsxs(Ue,{open:o,onOpenChange:r,children:[a.jsx(qe,{asChild:!0,children:t}),a.jsx(Fe,{children:a.jsx(Ve,{asChild:!0,side:u,align:s,sideOffset:8,onCloseAutoFocus:h=>{h.preventDefault()},children:a.jsx(se,{title:e,showTitle:n,children:l})})})]})};try{I.displayName="Menu",I.__docgenInfo={description:"A menu opened by pressing a button.",displayName:"Menu",props:{title:{defaultValue:null,description:"The menu title. This can be hidden with `showTitle={false}` in which case it will only\nbe a label for screen readers.",name:"title",required:!0,type:{name:"string"}},showTitle:{defaultValue:{value:"true"},description:"Controls whether the title is displayed (see `title` prop). Titles are only displayed on\nweb: on mobile, this parameter is ignored.",name:"showTitle",required:!1,type:{name:"boolean"}},open:{defaultValue:null,description:"Whether the menu is open.",name:"open",required:!0,type:{name:"boolean"}},onOpenChange:{defaultValue:null,description:`Event handler called when the open state of the menu changes. This includes +import{j as a}from"./jsx-runtime-DR9Q75dM.js";import{r as i}from"./index-DRjF_FHU.js";import{U as L}from"./user-profile-cqTW1cHH.js";import{N as B,C as U,L as q}from"./notifications-BEKrtwGv.js";import{c as b,u as S}from"./index-CGa_gRws.js";import{c as F}from"./index-C8xBnYIG.js";import{c as C,A as V,C as $,G as W,L as K,I as H,a as X,R as z,b as J,d as Q,S as Y,e as Z,f as ee,g as oe,i as ne,h as re,P as te,D as w}from"./index-Dbt-v4y0.js";import{P as ae}from"./index-Ksfxd92j.js";import{F as se}from"./FloatingMenu-Dc89G4Nf.js";import{c as ie}from"./index-lhGYx47h.js";import{d as ce,D as ue,g as pe}from"./DrawerMenu-BNILBemh.js";import{a as de,M as x}from"./MenuItem-YyrVQu2n.js";import{S as le}from"./Separator-BbJs_Bbv.js";import{B as me}from"./Button-BORixq-h.js";import"./index-BXwbELbV.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./UnstyledButton-DuxpNl0e.js";function fe(e,n=[]){let o=[];function r(c,u){const s=i.createContext(u),p=o.length;o=[...o,u];const m=l=>{const{scope:h,children:D,...g}=l,k=h?.[e]?.[p]||s,G=i.useMemo(()=>g,Object.values(g));return a.jsx(k.Provider,{value:G,children:D})};m.displayName=c+"Provider";function f(l,h){const D=h?.[e]?.[p]||s,g=i.useContext(D);if(g)return g;if(u!==void 0)return u;throw new Error(`\`${l}\` must be used within \`${c}\``)}return[m,f]}const t=()=>{const c=o.map(u=>i.createContext(u));return function(s){const p=s?.[e]||c;return i.useMemo(()=>({[`__scope${e}`]:{...s,[e]:p}}),[s,p])}};return t.scopeName=e,[r,he(t,...n)]}function he(...e){const n=e[0];if(e.length===1)return n;const o=()=>{const r=e.map(t=>({useScope:t(),scopeName:t.scopeName}));return function(c){const u=r.reduce((s,{useScope:p,scopeName:m})=>{const l=p(c)[`__scope${m}`];return{...s,...l}},{});return i.useMemo(()=>({[`__scope${n.scopeName}`]:u}),[u])}};return o.scopeName=n.scopeName,o}var _="DropdownMenu",[ge,mo]=fe(_,[C]),d=C(),[we,y]=ge(_),N=e=>{const{__scopeDropdownMenu:n,children:o,dir:r,open:t,defaultOpen:c,onOpenChange:u,modal:s=!0}=e,p=d(n),m=i.useRef(null),[f=!1,l]=ne({prop:t,defaultProp:c,onChange:u});return a.jsx(we,{scope:n,triggerId:S(),triggerRef:m,contentId:S(),open:f,onOpenChange:l,onOpenToggle:i.useCallback(()=>l(h=>!h),[l]),modal:s,children:a.jsx(re,{...p,open:f,onOpenChange:l,dir:r,modal:s,children:o})})};N.displayName=_;var R="DropdownMenuTrigger",P=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,disabled:r=!1,...t}=e,c=y(R,o),u=d(o);return a.jsx(V,{asChild:!0,...u,children:a.jsx(ae.button,{type:"button",id:c.triggerId,"aria-haspopup":"menu","aria-expanded":c.open,"aria-controls":c.open?c.contentId:void 0,"data-state":c.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...t,ref:F(n,c.triggerRef),onPointerDown:b(e.onPointerDown,s=>{!r&&s.button===0&&s.ctrlKey===!1&&(c.onOpenToggle(),c.open||s.preventDefault())}),onKeyDown:b(e.onKeyDown,s=>{r||(["Enter"," "].includes(s.key)&&c.onOpenToggle(),s.key==="ArrowDown"&&c.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});P.displayName=R;var Me="DropdownMenuPortal",j=e=>{const{__scopeDropdownMenu:n,...o}=e,r=d(n);return a.jsx(te,{...r,...o})};j.displayName=Me;var T="DropdownMenuContent",O=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=y(T,o),c=d(o),u=i.useRef(!1);return a.jsx($,{id:t.contentId,"aria-labelledby":t.triggerId,...c,...r,ref:n,onCloseAutoFocus:b(e.onCloseAutoFocus,s=>{u.current||t.triggerRef.current?.focus(),u.current=!1,s.preventDefault()}),onInteractOutside:b(e.onInteractOutside,s=>{const p=s.detail.originalEvent,m=p.button===0&&p.ctrlKey===!0,f=p.button===2||m;(!t.modal||f)&&(u.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});O.displayName=T;var ve="DropdownMenuGroup",xe=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(W,{...t,...r,ref:n})});xe.displayName=ve;var be="DropdownMenuLabel",Ie=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(K,{...t,...r,ref:n})});Ie.displayName=be;var De="DropdownMenuItem",E=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(H,{...t,...r,ref:n})});E.displayName=De;var _e="DropdownMenuCheckboxItem",Se=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(X,{...t,...r,ref:n})});Se.displayName=_e;var Ce="DropdownMenuRadioGroup",ye=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(z,{...t,...r,ref:n})});ye.displayName=Ce;var Ne="DropdownMenuRadioItem",Re=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(J,{...t,...r,ref:n})});Re.displayName=Ne;var Pe="DropdownMenuItemIndicator",je=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(Q,{...t,...r,ref:n})});je.displayName=Pe;var Te="DropdownMenuSeparator",Oe=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(Y,{...t,...r,ref:n})});Oe.displayName=Te;var Ee="DropdownMenuArrow",Ae=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(Z,{...t,...r,ref:n})});Ae.displayName=Ee;var ke="DropdownMenuSubTrigger",Ge=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(ee,{...t,...r,ref:n})});Ge.displayName=ke;var Le="DropdownMenuSubContent",Be=i.forwardRef((e,n)=>{const{__scopeDropdownMenu:o,...r}=e,t=d(o);return a.jsx(oe,{...t,...r,ref:n,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Be.displayName=Le;var Ue=N,qe=P,Fe=j,Ve=O;const $e=({onSelect:e,children:n})=>a.jsx(E,{onSelect:e??void 0,asChild:!0,children:n}),I=({title:e,showTitle:n=!0,open:o,onOpenChange:r,trigger:t,children:c,side:u="bottom",align:s="center"})=>{const p=pe(),m=p==="android"||p==="ios",f=i.useMemo(()=>({MenuItemWrapper:m?null:$e,onOpenChange:r}),[r]),l=a.jsx(de.Provider,{value:f,children:c});return m?a.jsxs(w.Root,{open:o,onOpenChange:r,children:[a.jsx(w.Trigger,{asChild:!0,children:t}),a.jsxs(w.Portal,{children:[a.jsx(w.Overlay,{className:ie(ce.bg)}),a.jsx(w.Content,{asChild:!0,children:a.jsx(ue,{title:e,children:l})})]})]}):a.jsxs(Ue,{open:o,onOpenChange:r,children:[a.jsx(qe,{asChild:!0,children:t}),a.jsx(Fe,{children:a.jsx(Ve,{asChild:!0,side:u,align:s,sideOffset:8,onCloseAutoFocus:h=>{h.preventDefault()},children:a.jsx(se,{title:e,showTitle:n,children:l})})})]})};try{I.displayName="Menu",I.__docgenInfo={description:"A menu opened by pressing a button.",displayName:"Menu",props:{title:{defaultValue:null,description:"The menu title. This can be hidden with `showTitle={false}` in which case it will only\nbe a label for screen readers.",name:"title",required:!0,type:{name:"string"}},showTitle:{defaultValue:{value:"true"},description:"Controls whether the title is displayed (see `title` prop). Titles are only displayed on\nweb: on mobile, this parameter is ignored.",name:"showTitle",required:!1,type:{name:"boolean"}},open:{defaultValue:null,description:"Whether the menu is open.",name:"open",required:!0,type:{name:"boolean"}},onOpenChange:{defaultValue:null,description:`Event handler called when the open state of the menu changes. This includes anything like clicking the trigger, selecting a menu item, or dismissing the menu with the mouse or keyboard.`,name:"onOpenChange",required:!0,type:{name:"(open: boolean) => void"}},trigger:{defaultValue:null,description:`The button that opens the menu. This must be a component that accepts a ref and spreads props. diff --git a/assets/MenuItem-BFo5ba9w.js b/assets/MenuItem-YyrVQu2n.js similarity index 96% rename from assets/MenuItem-BFo5ba9w.js rename to assets/MenuItem-YyrVQu2n.js index 9940cb2b..c02616c5 100644 --- a/assets/MenuItem-BFo5ba9w.js +++ b/assets/MenuItem-YyrVQu2n.js @@ -1,4 +1,4 @@ import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{c as N}from"./index-lhGYx47h.js";import{r as l}from"./index-DRjF_FHU.js";import{T as w}from"./Text-BvzksikX.js";import{C as M}from"./chevron-right-DND12YKW.js";import{S as E}from"./index-C8xBnYIG.js";const m=l.createContext(null);try{m.displayName="MenuContext",m.__docgenInfo={description:`A React context providing information about the menu in which a given component resides.`,displayName:"MenuContext",props:{}}}catch{}const V="_item_8j2l6_17",T="_interactive_8j2l6_35",k="_icon_8j2l6_43",q="_label_8j2l6_52",R="_disabled_8j2l6_118",e={item:V,interactive:T,"no-label":"_no-label_8j2l6_39",icon:k,label:q,"nav-hint":"_nav-hint_8j2l6_59",disabled:R},p=({as:o,className:h,Icon:s,label:r,labelProps:b,onSelect:n,kind:f="primary",children:v,onClick:_,disabled:u,...y})=>{const a=o??"button",i=l.useContext(m),g=l.useCallback(I=>{if(_?.(I),n!==null&&i?.MenuItemWrapper==null){const c=new CustomEvent("menu.itemSelect",{bubbles:!0,cancelable:!0});n(c),c.defaultPrevented||i?.onOpenChange(!1)}},[i,n]),x=l.isValidElement(s),C=s,j=s,d=t.jsxs(a,{role:"menuitem",...y,className:N(h,e.item,{[e.interactive]:n!==null,[e["no-label"]]:r===null,[e.disabled]:u}),"data-kind":f,onClick:g,disabled:a==="button"?u:void 0,"aria-disabled":a==="button"?void 0:u,children:[x?t.jsx(E,{className:e.icon,children:C}):t.jsx(j,{width:24,height:24,className:e.icon,"aria-hidden":!0}),r!==null&&t.jsx(w,{className:e.label,size:"md",weight:"medium",as:"span",...b,children:r}),(a==="button"||a==="a")&&t.jsx(M,{width:8,height:24,className:e["nav-hint"],"aria-hidden":!0,viewBox:"8 0 8 24"}),v]});return i?.MenuItemWrapper==null||n===null?d:t.jsx(i.MenuItemWrapper,{onSelect:n,children:d})};try{p.displayName="MenuItem",p.__docgenInfo={description:"An item within a menu, acting either as a navigation button, or simply a\ncontainer for other interactive elements.\nMust be used within a compound Menu or other `menu` or `menubar` aria role subtree.",displayName:"MenuItem",props:{as:{defaultValue:{value:"button"},description:"The element type of this menu item.",name:"as",required:!1,type:{name:"enum",value:[{value:'"a"'},{value:'"button"'},{value:'"div"'}]}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},Icon:{defaultValue:null,description:"The icon to show on this menu item.\nWhen `Icon` is a ReactNode, it should spread the props",name:"Icon",required:!0,type:{name:"ReactNode | ComponentType>"}},label:{defaultValue:null,description:"The label to show on this menu item.",name:"label",required:!0,type:{name:"string | null"}},labelProps:{defaultValue:null,description:"Additional properties to pass to the Text label component.",name:"labelProps",required:!1,type:{name:'Omit; type?: "body" | "heading"; weight?: "medium" | "bold" | "regular" | "semibold" | undefined; size?: "sm" | ... 4 more ... | undefined; className?: string | undefined; } & Omit<...> & { ...; }, "type"> & { ...; }, "ref"> | undefined'}},onSelect:{defaultValue:null,description:`Event callback for when the item is selected via mouse, touch, or keyboard. Calling event.preventDefault in this handler will prevent the menu from -being dismissed.`,name:"onSelect",required:!0,type:{name:"((e: Event) => void) | null"}},kind:{defaultValue:{value:"primary"},description:"The color variant of the menu item.",name:"kind",required:!1,type:{name:"enum",value:[{value:'"primary"'},{value:'"critical"'}]}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}}}}}catch{}export{p as M,m as a}; +being dismissed.`,name:"onSelect",required:!0,type:{name:"((e: Event) => void) | null"}},kind:{defaultValue:{value:"primary"},description:"The color variant of the menu item.",name:"kind",required:!1,type:{name:"enum",value:[{value:'"critical"'},{value:'"primary"'}]}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}}}}}catch{}export{p as M,m as a}; diff --git a/assets/MenuItem.stories-DJ1vpGR1.js b/assets/MenuItem.stories-DyAT8czh.js similarity index 98% rename from assets/MenuItem.stories-DJ1vpGR1.js rename to assets/MenuItem.stories-DyAT8czh.js index 2f7c8721..4bf99219 100644 --- a/assets/MenuItem.stories-DJ1vpGR1.js +++ b/assets/MenuItem.stories-DyAT8czh.js @@ -1,4 +1,4 @@ -import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{C as p,E as g}from"./extensions-DRIHxRsb.js";import{S as b}from"./settings-xa_4DC6i.js";import{M as l}from"./MenuItem-BFo5ba9w.js";import{T as d}from"./Text-BvzksikX.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./Typography-DzhKoIWt.js";const P={title:"Menu/MenuItem",component:l,tags:["autodocs"],argTypes:{onClick:{action:"clicked!"}},args:{label:"Menu item",children:e.jsx(d,{as:"span",size:"sm",children:"99"}),Icon:p},decorators:[u=>e.jsx("div",{style:{width:300},children:e.jsx(u,{})})]},s={render:()=>e.jsxs("div",{style:{width:300},children:[e.jsx(l,{Icon:p,label:"First item",onSelect:()=>{},children:e.jsx(d,{as:"span",size:"sm",children:"99"})}),e.jsx(l,{Icon:g,label:"Second item with a name that's quite long",onSelect:()=>{}}),e.jsx(l,{Icon:b,label:null,onSelect:()=>{},children:e.jsx(d,{as:"span",size:"sm",children:"Third item without a label"})})]})},r={args:{kind:"primary"}},a={args:{kind:"critical"}},o={args:{...r.args,disabled:!0}},t={args:{...a.args,disabled:!0}};function h(u){return e.jsx("div",{style:{height:24,width:48,backgroundColor:"teal"},...u})}const n={args:{...r.args,Icon:e.jsx(h,{})}},i={args:{...r.args,label:void 0}},c={args:{...r.args,label:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat."}},m={args:{...r.args,label:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, empor incididunt ut labore et dolore magna aliqua.",children:e.jsx(d,{as:"span",size:"sm",children:"Longer children too"})}};s.parameters={...s.parameters,docs:{...s.parameters?.docs,source:{originalSource:`{ +import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{C as p,E as g}from"./extensions-DRIHxRsb.js";import{S as b}from"./settings-xa_4DC6i.js";import{M as l}from"./MenuItem-YyrVQu2n.js";import{T as d}from"./Text-BvzksikX.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./Typography-DzhKoIWt.js";const P={title:"Menu/MenuItem",component:l,tags:["autodocs"],argTypes:{onClick:{action:"clicked!"}},args:{label:"Menu item",children:e.jsx(d,{as:"span",size:"sm",children:"99"}),Icon:p},decorators:[u=>e.jsx("div",{style:{width:300},children:e.jsx(u,{})})]},s={render:()=>e.jsxs("div",{style:{width:300},children:[e.jsx(l,{Icon:p,label:"First item",onSelect:()=>{},children:e.jsx(d,{as:"span",size:"sm",children:"99"})}),e.jsx(l,{Icon:g,label:"Second item with a name that's quite long",onSelect:()=>{}}),e.jsx(l,{Icon:b,label:null,onSelect:()=>{},children:e.jsx(d,{as:"span",size:"sm",children:"Third item without a label"})})]})},r={args:{kind:"primary"}},a={args:{kind:"critical"}},o={args:{...r.args,disabled:!0}},t={args:{...a.args,disabled:!0}};function h(u){return e.jsx("div",{style:{height:24,width:48,backgroundColor:"teal"},...u})}const n={args:{...r.args,Icon:e.jsx(h,{})}},i={args:{...r.args,label:void 0}},c={args:{...r.args,label:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat."}},m={args:{...r.args,label:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, empor incididunt ut labore et dolore magna aliqua.",children:e.jsx(d,{as:"span",size:"sm",children:"Longer children too"})}};s.parameters={...s.parameters,docs:{...s.parameters?.docs,source:{originalSource:`{ render: () =>
diff --git a/assets/Password-BPLQ51Y-.js b/assets/Password-Dm026fYh.js similarity index 96% rename from assets/Password-BPLQ51Y-.js rename to assets/Password-Dm026fYh.js index 81a12a80..61946df9 100644 --- a/assets/Password-BPLQ51Y-.js +++ b/assets/Password-Dm026fYh.js @@ -1,4 +1,4 @@ -import{j as a}from"./jsx-runtime-DR9Q75dM.js";import{r as o}from"./index-DRjF_FHU.js";import{C as m}from"./index-4or38LtJ.js";import{a as f,V as b}from"./visibility-on-BsZOuBEH.js";import{A as h}from"./Action-BnShWVrx.js";const r={isHidden:!0,icon:f,label:"Show",type:"password"},g={isHidden:!1,icon:b,label:"Hide",type:"text"},n=o.forwardRef(function(t,s){const[{icon:l,label:d,type:p},c]=o.useReducer(u=>u.isHidden?g:r,r);return a.jsx(h,{ref:s,...t,Icon:l,actionLabel:d,onActionClick:()=>c(),type:p})}),i=o.forwardRef(function(t,s){return a.jsx(m,{asChild:!0,children:a.jsx(n,{ref:s,...t})})});try{n.displayName="PasswordInput",n.__docgenInfo={description:`A password input with a toggle to show/hide the password. +import{j as a}from"./jsx-runtime-DR9Q75dM.js";import{r as o}from"./index-DRjF_FHU.js";import{C as m}from"./index-4or38LtJ.js";import{a as f,V as b}from"./visibility-on-BsZOuBEH.js";import{A as h}from"./Action-CwOAv2fk.js";const r={isHidden:!0,icon:f,label:"Show",type:"password"},g={isHidden:!1,icon:b,label:"Hide",type:"text"},n=o.forwardRef(function(t,s){const[{icon:l,label:d,type:p},c]=o.useReducer(u=>u.isHidden?g:r,r);return a.jsx(h,{ref:s,...t,Icon:l,actionLabel:d,onActionClick:()=>c(),type:p})}),i=o.forwardRef(function(t,s){return a.jsx(m,{asChild:!0,children:a.jsx(n,{ref:s,...t})})});try{n.displayName="PasswordInput",n.__docgenInfo={description:`A password input with a toggle to show/hide the password. Standalone input to be used outside of Radix forms.`,displayName:"PasswordInput",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},enableLigatures:{defaultValue:null,description:`Enable contextual alternate ligatures on input text For example on an in-place editing field diff --git a/assets/Password.stories-xpc97ble.js b/assets/Password.stories-Cvffqo9q.js similarity index 94% rename from assets/Password.stories-xpc97ble.js rename to assets/Password.stories-Cvffqo9q.js index 96ffaa86..2718abff 100644 --- a/assets/Password.stories-xpc97ble.js +++ b/assets/Password.stories-Cvffqo9q.js @@ -1,4 +1,4 @@ -import{j as p}from"./jsx-runtime-DR9Q75dM.js";import{T as l}from"./Tooltip-DGTzhuPA.js";import{u,s as g}from"./index-JRK_GaCU.js";import{P as m}from"./Password-BPLQ51Y-.js";import"./index-DRjF_FHU.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";import"./index-lhGYx47h.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./visibility-on-BsZOuBEH.js";import"./Action-BnShWVrx.js";import"./Text-DZrEBsw6.js";const L={title:"Form/Controls/Password",component:m,tags:["autodocs"],parameters:{controls:{include:["defaultValue","placeholder","disabled","autoFocus","readOnly","invalid"]}},argTypes:{defaultValue:{type:"string"},placeholder:{type:"string"},disabled:{type:"boolean"},autoFocus:{type:"boolean"},readOnly:{type:"boolean"},invalid:{type:"boolean"}},render:({invalid:i,...d})=>p.jsx(l,{children:p.jsx(m,{"data-invalid":i||void 0,...d})}),args:{placeholder:"",autoFocus:!1,disabled:!1,readOnly:!1,invalid:!1}},e={parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4477"}}},a={args:{defaultValue:"Filled"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4536"}}},n={args:{defaultValue:"Disabled",disabled:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4530"}}},o={args:{defaultValue:"Read only",readOnly:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=2126-21984"}}},r={args:{autoFocus:!0}},s={args:{defaultValue:"Invalid",invalid:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4514"}}},t={args:{defaultValue:"hunter2"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4536"}},play:async()=>{const i=u.setup(),d=g.getByRole("button",{name:"Show"});await i.click(d)}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ +import{j as p}from"./jsx-runtime-DR9Q75dM.js";import{T as l}from"./Tooltip-D2McGlOP.js";import{u,s as g}from"./index-JRK_GaCU.js";import{P as m}from"./Password-Dm026fYh.js";import"./index-DRjF_FHU.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";import"./index-lhGYx47h.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./index-C8xBnYIG.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./visibility-on-BsZOuBEH.js";import"./Action-CwOAv2fk.js";import"./Text-DZrEBsw6.js";const L={title:"Form/Controls/Password",component:m,tags:["autodocs"],parameters:{controls:{include:["defaultValue","placeholder","disabled","autoFocus","readOnly","invalid"]}},argTypes:{defaultValue:{type:"string"},placeholder:{type:"string"},disabled:{type:"boolean"},autoFocus:{type:"boolean"},readOnly:{type:"boolean"},invalid:{type:"boolean"}},render:({invalid:i,...d})=>p.jsx(l,{children:p.jsx(m,{"data-invalid":i||void 0,...d})}),args:{placeholder:"",autoFocus:!1,disabled:!1,readOnly:!1,invalid:!1}},e={parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4477"}}},a={args:{defaultValue:"Filled"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4536"}}},n={args:{defaultValue:"Disabled",disabled:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4530"}}},o={args:{defaultValue:"Read only",readOnly:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=2126-21984"}}},r={args:{autoFocus:!0}},s={args:{defaultValue:"Invalid",invalid:!0},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4514"}}},t={args:{defaultValue:"hunter2"},parameters:{design:{type:"figma",url:"https://www.figma.com/file/rTaQE2nIUSLav4Tg3nozq7/Compound-Web-Components?type=design&node-id=793-4536"}},play:async()=>{const i=u.setup(),d=g.getByRole("button",{name:"Show"});await i.click(d)}};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`{ parameters: { design: { type: "figma", diff --git a/assets/PasswordForm.stories-njJrHlv5.js b/assets/PasswordForm.stories-Dnc5DYrq.js similarity index 89% rename from assets/PasswordForm.stories-njJrHlv5.js rename to assets/PasswordForm.stories-Dnc5DYrq.js index 87edb275..39d8fe01 100644 --- a/assets/PasswordForm.stories-njJrHlv5.js +++ b/assets/PasswordForm.stories-Dnc5DYrq.js @@ -1,4 +1,4 @@ -import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{W as p}from"./warning-DNnCy5FR.js";import{P as s}from"./Progress-wZmvUnkq.js";import{T as x}from"./Tooltip-DGTzhuPA.js";import{R as r,H as g,S as w}from"./Message-t35Ysetp.js";import{a}from"./Password-BPLQ51Y-.js";import{L as o,F as t}from"./Label-BsNBFg9B.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";import"./floating-ui.react-CACRriTf.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./check-circle-solid-DvGH8qX5.js";import"./error-DOy7ZFuJ.js";import"./InlineSpinner-DDpdhuC2.js";import"./spinner--mCkS-8r.js";import"./visibility-on-BsZOuBEH.js";import"./Action-BnShWVrx.js";import"./Text-DZrEBsw6.js";const O={title:"Form/Password form",component:r,tags:["autodocs"],subcomponents:{Progress:s,PasswordControl:a,Label:o,Field:t},decorators:[c=>e.jsx(x,{children:e.jsx("div",{style:{maxWidth:"378px"},children:e.jsx(c,{})})})]},n=c=>{switch(c){case 1:return"Very weak password";case 2:return"Weak password";case 3:return"Strong password";case 4:return"Very strong password";default:return"Password strength"}},d=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{}),e.jsx(s,{getValueLabel:n,size:"sm",value:0,max:4})]})}),i=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"password"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"red",value:1,max:4}),e.jsxs(g,{children:[e.jsx(p,{}),"Guess time: a few seconds. Try adding a few more words."]})]})}),l=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"hunter2"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"orange",value:2,max:4}),e.jsxs(g,{children:[e.jsx(p,{}),"Guess time: a few days. Try adding a few more words."]})]})}),m=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"this is a strong password"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"lime",value:3,max:4}),e.jsx(w,{children:"Guess time: years"})]})}),u=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"this is a very strong password"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"green",value:4,max:4}),e.jsx(w,{children:"Guess time: centruries"})]})});d.parameters={...d.parameters,docs:{...d.parameters?.docs,source:{originalSource:`() => { +import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{W as p}from"./warning-DNnCy5FR.js";import{P as s}from"./Progress-DaTknHqR.js";import{T as x}from"./Tooltip-D2McGlOP.js";import{R as r,H as g,S as w}from"./Message-t35Ysetp.js";import{a}from"./Password-Dm026fYh.js";import{L as o,F as t}from"./Label-BsNBFg9B.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./check-circle-solid-DvGH8qX5.js";import"./error-DOy7ZFuJ.js";import"./InlineSpinner-DDpdhuC2.js";import"./spinner--mCkS-8r.js";import"./visibility-on-BsZOuBEH.js";import"./Action-CwOAv2fk.js";import"./Text-DZrEBsw6.js";const O={title:"Form/Password form",component:r,tags:["autodocs"],subcomponents:{Progress:s,PasswordControl:a,Label:o,Field:t},decorators:[c=>e.jsx(x,{children:e.jsx("div",{style:{maxWidth:"378px"},children:e.jsx(c,{})})})]},n=c=>{switch(c){case 1:return"Very weak password";case 2:return"Weak password";case 3:return"Strong password";case 4:return"Very strong password";default:return"Password strength"}},d=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{}),e.jsx(s,{getValueLabel:n,size:"sm",value:0,max:4})]})}),i=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"password"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"red",value:1,max:4}),e.jsxs(g,{children:[e.jsx(p,{}),"Guess time: a few seconds. Try adding a few more words."]})]})}),l=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"hunter2"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"orange",value:2,max:4}),e.jsxs(g,{children:[e.jsx(p,{}),"Guess time: a few days. Try adding a few more words."]})]})}),m=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"this is a strong password"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"lime",value:3,max:4}),e.jsx(w,{children:"Guess time: years"})]})}),u=()=>e.jsx(r,{children:e.jsxs(t,{name:"password",children:[e.jsx(o,{children:"Password"}),e.jsx(a,{defaultValue:"this is a very strong password"}),e.jsx(s,{getValueLabel:n,size:"sm",tint:"green",value:4,max:4}),e.jsx(w,{children:"Guess time: centruries"})]})});d.parameters={...d.parameters,docs:{...d.parameters?.docs,source:{originalSource:`() => { return diff --git a/assets/Progress-wZmvUnkq.js b/assets/Progress-DaTknHqR.js similarity index 78% rename from assets/Progress-wZmvUnkq.js rename to assets/Progress-DaTknHqR.js index fe493e18..183c3a75 100644 --- a/assets/Progress-wZmvUnkq.js +++ b/assets/Progress-DaTknHqR.js @@ -3,6 +3,6 @@ import{j as n}from"./jsx-runtime-DR9Q75dM.js";import{r as p}from"./index-DRjF_FH - less than the value passed to \`max\` (or ${b} if no \`max\` prop is set) - \`null\` or \`undefined\` if the progress is indeterminate. -Defaulting to \`null\`.`}var A=N,M=I;const P=p.forwardRef(function({size:r,tint:i,className:s,value:a,max:c,getValueLabel:u,...t},o){const l=c??1,f=a??l,h=p.useId(),g=u?u(f,l):null;return n.jsxs("div",{className:$(d["progress-bar-container"],s),"data-tint":i,...t,children:[g&&n.jsx("div",{id:h,className:d["progress-bar-label"],children:g}),n.jsx(A,{className:d["progress-bar"],"data-size":r,max:l,value:f,ref:o,"aria-labelledby":g?h:void 0,getValueLabel:u,children:n.jsx(M,{className:d["progress-bar-indicator"],style:{transform:`translateX(-${100-f/l*100}%)`}})})]})});try{P.displayName="Progress",P.__docgenInfo={description:"Displays an indicator showing the completion progress of a task, optionally with a label",displayName:"Progress",props:{size:{defaultValue:null,description:"The size variant of the progress bar",name:"size",required:!0,type:{name:"enum",value:[{value:'"sm"'},{value:'"lg"'}]}},className:{defaultValue:null,description:"The CSS class name forwarded to the root element",name:"className",required:!1,type:{name:"string"}},value:{defaultValue:null,description:"The value of the progress bar. Defaults to max if not provided",name:"value",required:!1,type:{name:"number | null"}},tint:{defaultValue:null,description:`The colour variant to use for the progress bar indicator -If not set, the progress bar will be rendered with a gray tone, which should only be used when the progress bar is empty`,name:"tint",required:!1,type:{name:"enum",value:[{value:'"green"'},{value:'"lime"'},{value:'"orange"'},{value:'"red"'}]}},max:{defaultValue:null,description:"The maximum value of the progress bar. Defaults to 1 if not provided",name:"max",required:!1,type:{name:"number"}},getValueLabel:{defaultValue:null,description:`A function to get the text label to display in the progress bar. +Defaulting to \`null\`.`}var A=N,M=I;const P=p.forwardRef(function({size:r,tint:i,className:s,value:a,max:c,getValueLabel:u,...t},o){const l=c??1,f=a??l,h=p.useId(),g=u?u(f,l):null;return n.jsxs("div",{className:$(d["progress-bar-container"],s),"data-tint":i,...t,children:[g&&n.jsx("div",{id:h,className:d["progress-bar-label"],children:g}),n.jsx(A,{className:d["progress-bar"],"data-size":r,max:l,value:f,ref:o,"aria-labelledby":g?h:void 0,getValueLabel:u,children:n.jsx(M,{className:d["progress-bar-indicator"],style:{transform:`translateX(-${100-f/l*100}%)`}})})]})});try{P.displayName="Progress",P.__docgenInfo={description:"Displays an indicator showing the completion progress of a task, optionally with a label",displayName:"Progress",props:{className:{defaultValue:null,description:"The CSS class name forwarded to the root element",name:"className",required:!1,type:{name:"string"}},size:{defaultValue:null,description:"The size variant of the progress bar",name:"size",required:!0,type:{name:"enum",value:[{value:'"sm"'},{value:'"lg"'}]}},value:{defaultValue:null,description:"The value of the progress bar. Defaults to max if not provided",name:"value",required:!1,type:{name:"number | null"}},max:{defaultValue:null,description:"The maximum value of the progress bar. Defaults to 1 if not provided",name:"max",required:!1,type:{name:"number"}},tint:{defaultValue:null,description:`The colour variant to use for the progress bar indicator +If not set, the progress bar will be rendered with a gray tone, which should only be used when the progress bar is empty`,name:"tint",required:!1,type:{name:"enum",value:[{value:'"green"'},{value:'"lime"'},{value:'"orange"'},{value:'"red"'}]}},getValueLabel:{defaultValue:null,description:`A function to get the text label to display in the progress bar. If set, it will display a label on top of the progress bar`,name:"getValueLabel",required:!1,type:{name:"((value: number, max: number) => string)"}}}}}catch{}export{P}; diff --git a/assets/Progress.stories-BjCxvhnZ.js b/assets/Progress.stories-DQdxsRQA.js similarity index 97% rename from assets/Progress.stories-BjCxvhnZ.js rename to assets/Progress.stories-DQdxsRQA.js index f4223881..a0aa634d 100644 --- a/assets/Progress.stories-BjCxvhnZ.js +++ b/assets/Progress.stories-DQdxsRQA.js @@ -1,4 +1,4 @@ -import{P as u}from"./Progress-wZmvUnkq.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";function i(e){return e===0?"Empty progress bar":e<=25?"Quarter-full progress bar":e<=50?"Half-full progress bar":e<=75?"Three-quarters full progress bar":"Full progress bar"}const L={title:"Progress",component:u,tags:["autodocs"],argTypes:{max:{type:"number"},value:{type:"number"}},args:{getValueLabel:i,size:"sm",max:100,value:50}},r={args:{tint:"green",size:"lg",value:50}},s={args:{tint:"green",size:"sm",value:50}},a={args:{tint:"green",size:"lg",value:100}},n={args:{tint:"green",size:"sm",value:100}},t={args:{value:0}},o={args:{value:25,tint:"red"}},l={args:{value:50,tint:"orange"}},c={args:{value:75,tint:"lime"}},m={args:{value:100,tint:"green"}};r.parameters={...r.parameters,docs:{...r.parameters?.docs,source:{originalSource:`{ +import{P as u}from"./Progress-DaTknHqR.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";function i(e){return e===0?"Empty progress bar":e<=25?"Quarter-full progress bar":e<=50?"Half-full progress bar":e<=75?"Three-quarters full progress bar":"Full progress bar"}const L={title:"Progress",component:u,tags:["autodocs"],argTypes:{max:{type:"number"},value:{type:"number"}},args:{getValueLabel:i,size:"sm",max:100,value:50}},r={args:{tint:"green",size:"lg",value:50}},s={args:{tint:"green",size:"sm",value:50}},a={args:{tint:"green",size:"lg",value:100}},n={args:{tint:"green",size:"sm",value:100}},t={args:{value:0}},o={args:{value:25,tint:"red"}},l={args:{value:50,tint:"orange"}},c={args:{value:75,tint:"lime"}},m={args:{value:100,tint:"green"}};r.parameters={...r.parameters,docs:{...r.parameters?.docs,source:{originalSource:`{ args: { tint: "green", size: "lg", diff --git a/assets/ReleaseAnnouncement.stories-DA7uhYWC.js b/assets/ReleaseAnnouncement.stories-BcQDEAeD.js similarity index 99% rename from assets/ReleaseAnnouncement.stories-DA7uhYWC.js rename to assets/ReleaseAnnouncement.stories-BcQDEAeD.js index 7e0acdd0..e10b818a 100644 --- a/assets/ReleaseAnnouncement.stories-DA7uhYWC.js +++ b/assets/ReleaseAnnouncement.stories-BcQDEAeD.js @@ -1,4 +1,4 @@ -import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{r as s}from"./index-DRjF_FHU.js";import{u as w,b as T,j,k as V,c as q,o as B,s as E,n as N,d as S,a as F,l as I,p as M,m as L}from"./floating-ui.react-CACRriTf.js";import{T as C}from"./Text-BvzksikX.js";import{B as k}from"./Button-BORixq-h.js";import"./index-BvEl7W6R.js";import"./Typography-DzhKoIWt.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";const P="_content_1oa1y_17",H="_header_1oa1y_46",W="_description_1oa1y_52",z="_button_1oa1y_57",D="_arrow_1oa1y_62",p={content:P,header:H,description:W,button:z,arrow:D},O=s.createContext(null);function v(){const e=s.useContext(O);if(e==null)throw new Error("ReleaseAnnouncement components must be wrapped in ");return e}function y({open:e,header:n,description:o,closeLabel:a,placement:r,onClick:m,displayArrow:f}){const _=w(),A=w(),g=s.useRef(null),b=T({placement:r,open:e,whileElementsMounted:q,middleware:[B(16),E({limiter:N({offset:50})}),f&&S({element:g})]}),R=j(b.context),x=V([R]);return s.useMemo(()=>({open:e,...b,...x,labelId:_,descriptionId:A,header:n,description:o,closeLabel:a,onClick:m,displayArrow:f,arrowRef:g}),[e,R,x,b,_,A,n,o,a,m,f,g])}try{y.displayName="useReleaseAnnouncement",y.__docgenInfo={description:"This hook provides the necessary props to create a release announcement.",displayName:"useReleaseAnnouncement",props:{open:{defaultValue:null,description:"Whether the release announcement is open.",name:"open",required:!0,type:{name:"boolean"}},header:{defaultValue:null,description:"The header of the release announcement.",name:"header",required:!0,type:{name:"string"}},description:{defaultValue:null,description:"The description of the release announcement.",name:"description",required:!0,type:{name:"string"}},closeLabel:{defaultValue:null,description:"The label of the close button.",name:"closeLabel",required:!0,type:{name:"string"}},placement:{defaultValue:null,description:"The placement of the release announcement.",name:"placement",required:!0,type:{name:"enum",value:[{value:'"left"'},{value:'"right"'},{value:'"bottom"'},{value:'"top"'},{value:'"left-end"'},{value:'"left-start"'},{value:'"right-end"'},{value:'"right-start"'},{value:'"bottom-end"'},{value:'"bottom-start"'},{value:'"top-end"'},{value:'"top-start"'}]}},onClick:{defaultValue:null,description:"The event handler for the close button.",name:"onClick",required:!0,type:{name:"MouseEventHandler"}},displayArrow:{defaultValue:null,description:"Whether to display an arrow.",name:"displayArrow",required:!1,type:{name:"boolean"}}}}}catch{}function d({children:e,placement:n="right",displayArrow:o=!0,...a}){const r=y({placement:n,displayArrow:o,...a});return t.jsxs(O.Provider,{value:r,children:[t.jsx(K,{children:e}),t.jsx(U,{children:t.jsx($,{})})]})}function K({children:e}){const n=v(),o=e?.ref,a=F([n.refs.setReference,o]);if(!s.isValidElement(e))throw new Error("ReleaseAnnouncement anchor must be a single valid React element");return s.cloneElement(e,n.getReferenceProps({ref:a,...e.props,...n.open&&{"aria-describedby":n.getFloatingProps().id}}))}function U({children:e}){const{context:n,arrowRef:o,displayArrow:a,...r}=v();return n.open?t.jsx(I,{children:t.jsx(M,{context:n,modal:!1,children:t.jsxs("div",{ref:r.refs.setFloating,style:r.floatingStyles,"aria-labelledby":r.labelId,"aria-describedby":r.descriptionId,...r.getFloatingProps(),className:p.content,children:[a&&t.jsx(L,{ref:o,context:n,width:20,height:12,className:p.arrow}),e]})})}):null}function $(){const{labelId:e,descriptionId:n,header:o,description:a,closeLabel:r,onClick:m}=v();return t.jsxs(t.Fragment,{children:[t.jsx(C,{as:"h3",id:e,className:p.header,size:"lg",weight:"semibold",children:o}),t.jsx(C,{as:"span",id:n,className:p.description,size:"sm",weight:"regular",children:a}),t.jsx(k,{size:"sm",kind:"secondary",className:p.button,onClick:m,children:r})]})}try{d.displayName="ReleaseAnnouncement",d.__docgenInfo={description:`The ReleaseAnnouncement component purpose is to inform the user of a new available feature. +import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{r as s}from"./index-DRjF_FHU.js";import{u as w,b as T,j,k as V,c as q,o as B,s as E,n as N,d as S,a as F,l as I,p as M,m as L}from"./floating-ui.react-CSvGZjCC.js";import{T as C}from"./Text-BvzksikX.js";import{B as k}from"./Button-BORixq-h.js";import"./index-BvEl7W6R.js";import"./Typography-DzhKoIWt.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";const P="_content_1oa1y_17",H="_header_1oa1y_46",W="_description_1oa1y_52",z="_button_1oa1y_57",D="_arrow_1oa1y_62",p={content:P,header:H,description:W,button:z,arrow:D},O=s.createContext(null);function v(){const e=s.useContext(O);if(e==null)throw new Error("ReleaseAnnouncement components must be wrapped in ");return e}function y({open:e,header:n,description:o,closeLabel:a,placement:r,onClick:m,displayArrow:f}){const _=w(),A=w(),g=s.useRef(null),b=T({placement:r,open:e,whileElementsMounted:q,middleware:[B(16),E({limiter:N({offset:50})}),f&&S({element:g})]}),R=j(b.context),x=V([R]);return s.useMemo(()=>({open:e,...b,...x,labelId:_,descriptionId:A,header:n,description:o,closeLabel:a,onClick:m,displayArrow:f,arrowRef:g}),[e,R,x,b,_,A,n,o,a,m,f,g])}try{y.displayName="useReleaseAnnouncement",y.__docgenInfo={description:"This hook provides the necessary props to create a release announcement.",displayName:"useReleaseAnnouncement",props:{open:{defaultValue:null,description:"Whether the release announcement is open.",name:"open",required:!0,type:{name:"boolean"}},header:{defaultValue:null,description:"The header of the release announcement.",name:"header",required:!0,type:{name:"string"}},description:{defaultValue:null,description:"The description of the release announcement.",name:"description",required:!0,type:{name:"string"}},closeLabel:{defaultValue:null,description:"The label of the close button.",name:"closeLabel",required:!0,type:{name:"string"}},placement:{defaultValue:null,description:"The placement of the release announcement.",name:"placement",required:!0,type:{name:"enum",value:[{value:'"left"'},{value:'"right"'},{value:'"bottom"'},{value:'"top"'},{value:'"left-end"'},{value:'"left-start"'},{value:'"right-end"'},{value:'"right-start"'},{value:'"bottom-end"'},{value:'"bottom-start"'},{value:'"top-end"'},{value:'"top-start"'}]}},onClick:{defaultValue:null,description:"The event handler for the close button.",name:"onClick",required:!0,type:{name:"MouseEventHandler"}},displayArrow:{defaultValue:null,description:"Whether to display an arrow.",name:"displayArrow",required:!1,type:{name:"boolean"}}}}}catch{}function d({children:e,placement:n="right",displayArrow:o=!0,...a}){const r=y({placement:n,displayArrow:o,...a});return t.jsxs(O.Provider,{value:r,children:[t.jsx(K,{children:e}),t.jsx(U,{children:t.jsx($,{})})]})}function K({children:e}){const n=v(),o=e?.ref,a=F([n.refs.setReference,o]);if(!s.isValidElement(e))throw new Error("ReleaseAnnouncement anchor must be a single valid React element");return s.cloneElement(e,n.getReferenceProps({ref:a,...e.props,...n.open&&{"aria-describedby":n.getFloatingProps().id}}))}function U({children:e}){const{context:n,arrowRef:o,displayArrow:a,...r}=v();return n.open?t.jsx(I,{children:t.jsx(M,{context:n,modal:!1,children:t.jsxs("div",{ref:r.refs.setFloating,style:r.floatingStyles,"aria-labelledby":r.labelId,"aria-describedby":r.descriptionId,...r.getFloatingProps(),className:p.content,children:[a&&t.jsx(L,{ref:o,context:n,width:20,height:12,className:p.arrow}),e]})})}):null}function $(){const{labelId:e,descriptionId:n,header:o,description:a,closeLabel:r,onClick:m}=v();return t.jsxs(t.Fragment,{children:[t.jsx(C,{as:"h3",id:e,className:p.header,size:"lg",weight:"semibold",children:o}),t.jsx(C,{as:"span",id:n,className:p.description,size:"sm",weight:"regular",children:a}),t.jsx(k,{size:"sm",kind:"secondary",className:p.button,onClick:m,children:r})]})}try{d.displayName="ReleaseAnnouncement",d.__docgenInfo={description:`The ReleaseAnnouncement component purpose is to inform the user of a new available feature. This component is a floating component that will appear next to an anchor.`,displayName:"ReleaseAnnouncement",props:{placement:{defaultValue:{value:"right"},description:"The placement of the component",name:"placement",required:!1,type:{name:"enum",value:[{value:'"left"'},{value:'"right"'},{value:'"bottom"'},{value:'"top"'},{value:'"left-end"'},{value:'"left-start"'},{value:'"right-end"'},{value:'"right-start"'},{value:'"bottom-end"'},{value:'"bottom-start"'},{value:'"top-end"'},{value:'"top-start"'}]}},displayArrow:{defaultValue:{value:"true"},description:"Whether to display an arrow.",name:"displayArrow",required:!1,type:{name:"boolean"}},header:{defaultValue:null,description:"The header of the release announcement.",name:"header",required:!0,type:{name:"string"}},onClick:{defaultValue:null,description:"The event handler for the close button.",name:"onClick",required:!0,type:{name:"MouseEventHandler"}},open:{defaultValue:null,description:"Whether the release announcement is open.",name:"open",required:!0,type:{name:"boolean"}},description:{defaultValue:null,description:"The description of the release announcement.",name:"description",required:!0,type:{name:"string"}},closeLabel:{defaultValue:null,description:"The label of the close button.",name:"closeLabel",required:!0,type:{name:"string"}}}}}catch{}const oe={title:"Release Announcement",component:d,tags:["autodocs"],argTypes:{},args:{header:"Notifications have moved",description:"From now on, click the icon here to view your notifications.",placement:"right",closeLabel:"Ok"}},h=e=>{const[n,o]=s.useState(!0);return t.jsx(d,{...e,open:n,onClick:()=>o(!1),children:t.jsx(k,{onClick:()=>o(a=>!a),children:"Open menu"})})},l=h.bind({});l.args={};const i=h.bind({});i.args={header:"A multi line header which is taking multiple lines",description:"A multi line description which is taking multiple lines. The OK button should be vertically centred."};const u=h.bind({});u.args={placement:"bottom"};const c=h.bind({});c.args={displayArrow:!1};l.parameters={...l.parameters,docs:{...l.parameters?.docs,source:{originalSource:`args => { const [open, setOpen] = useState(true); return setOpen(false)}> diff --git a/assets/Separator-B6sIYtjz.js b/assets/Separator-BbJs_Bbv.js similarity index 76% rename from assets/Separator-B6sIYtjz.js rename to assets/Separator-BbJs_Bbv.js index 8da89be9..11fcbc9f 100644 --- a/assets/Separator-B6sIYtjz.js +++ b/assets/Separator-BbJs_Bbv.js @@ -1 +1 @@ -import{j as u}from"./jsx-runtime-DR9Q75dM.js";import{c as y}from"./index-lhGYx47h.js";import{r as o}from"./index-DRjF_FHU.js";import{P as v}from"./index-Ksfxd92j.js";import{a as _}from"./floating-ui.react-CACRriTf.js";var N="Separator",d="horizontal",S=["horizontal","vertical"],f=o.forwardRef((e,a)=>{const{decorative:s,orientation:t=d,...n}=e,r=h(t)?t:d,p=s?{role:"none"}:{"aria-orientation":r==="vertical"?r:void 0,role:"separator"};return u.jsx(v.div,{"data-orientation":r,...p,...n,ref:a})});f.displayName=N;function h(e){return S.includes(e)}var P=f;const R="_separator_144s5_17",O={separator:R},m="--cpd-separator-spacing",l=o.forwardRef(({className:e,spacing:a,kind:s="primary",...t},n)=>{const r=y(O.separator,e),i=o.useRef(null),p=_([i,n]);return o.useEffect(()=>{const c=i.current?.style;a?c?.setProperty(m,a):c?.removeProperty(m)},[a]),u.jsx(P,{...t,className:r,ref:p,"data-kind":s})});l.displayName="Separator";try{l.displayName="Separator",l.__docgenInfo={description:"A separator component.",displayName:"Separator",props:{kind:{defaultValue:{value:"primary"},description:"The style of separator.",name:"kind",required:!1,type:{name:"enum",value:[{value:'"section"'},{value:'"primary"'},{value:'"secondary"'}]}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},asChild:{defaultValue:null,description:"",name:"asChild",required:!1,type:{name:"boolean"}},spacing:{defaultValue:{value:"var(--cpd-space-2x)"},description:"The spacing on either side of the separator.",name:"spacing",required:!1,type:{name:"string"}}}}}catch{}export{l as S}; +import{j as u}from"./jsx-runtime-DR9Q75dM.js";import{c as y}from"./index-lhGYx47h.js";import{r as o}from"./index-DRjF_FHU.js";import{P as v}from"./index-Ksfxd92j.js";import{a as _}from"./floating-ui.react-CSvGZjCC.js";var N="Separator",d="horizontal",S=["horizontal","vertical"],f=o.forwardRef((e,a)=>{const{decorative:s,orientation:t=d,...n}=e,r=h(t)?t:d,p=s?{role:"none"}:{"aria-orientation":r==="vertical"?r:void 0,role:"separator"};return u.jsx(v.div,{"data-orientation":r,...p,...n,ref:a})});f.displayName=N;function h(e){return S.includes(e)}var P=f;const R="_separator_144s5_17",O={separator:R},m="--cpd-separator-spacing",l=o.forwardRef(({className:e,spacing:a,kind:s="primary",...t},n)=>{const r=y(O.separator,e),i=o.useRef(null),p=_([i,n]);return o.useEffect(()=>{const c=i.current?.style;a?c?.setProperty(m,a):c?.removeProperty(m)},[a]),u.jsx(P,{...t,className:r,ref:p,"data-kind":s})});l.displayName="Separator";try{l.displayName="Separator",l.__docgenInfo={description:"A separator component.",displayName:"Separator",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},kind:{defaultValue:{value:"primary"},description:"The style of separator.",name:"kind",required:!1,type:{name:"enum",value:[{value:'"section"'},{value:'"primary"'},{value:'"secondary"'}]}},asChild:{defaultValue:null,description:"",name:"asChild",required:!1,type:{name:"boolean"}},spacing:{defaultValue:{value:"var(--cpd-space-2x)"},description:"The spacing on either side of the separator.",name:"spacing",required:!1,type:{name:"string"}}}}}catch{}export{l as S}; diff --git a/assets/Separator.stories-iz8p05W5.js b/assets/Separator.stories-CRxuvXnz.js similarity index 87% rename from assets/Separator.stories-iz8p05W5.js rename to assets/Separator.stories-CRxuvXnz.js index 4e2d2b6a..9d365ecc 100644 --- a/assets/Separator.stories-iz8p05W5.js +++ b/assets/Separator.stories-CRxuvXnz.js @@ -1,4 +1,4 @@ -import{S as e}from"./Separator-B6sIYtjz.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";import"./floating-ui.react-CACRriTf.js";const g={title:"Separator",component:e,tags:["autodocs"],argTypes:{},args:{}},r={args:{kind:"primary"}},a={args:{kind:"secondary"}},o={args:{kind:"section"}};r.parameters={...r.parameters,docs:{...r.parameters?.docs,source:{originalSource:`{ +import{S as e}from"./Separator-BbJs_Bbv.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-DRjF_FHU.js";import"./index-lhGYx47h.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";import"./index-C8xBnYIG.js";import"./floating-ui.react-CSvGZjCC.js";const g={title:"Separator",component:e,tags:["autodocs"],argTypes:{},args:{}},r={args:{kind:"primary"}},a={args:{kind:"secondary"}},o={args:{kind:"section"}};r.parameters={...r.parameters,docs:{...r.parameters?.docs,source:{originalSource:`{ args: { kind: "primary" } diff --git a/assets/ToggleMenuItem.stories-DDnlXtgb.js b/assets/ToggleMenuItem.stories-BVbICedI.js similarity index 77% rename from assets/ToggleMenuItem.stories-DDnlXtgb.js rename to assets/ToggleMenuItem.stories-BVbICedI.js index 7fc65342..ef97bf93 100644 --- a/assets/ToggleMenuItem.stories-DDnlXtgb.js +++ b/assets/ToggleMenuItem.stories-BVbICedI.js @@ -1,4 +1,4 @@ -import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{r}from"./index-DRjF_FHU.js";import{C as h,E as g}from"./extensions-DRIHxRsb.js";import{M as f}from"./MenuItem-BFo5ba9w.js";import{T as I}from"./Toggle-BRCP4wr-.js";import"./index-lhGYx47h.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";const n=r.forwardRef(function({className:a,Icon:s,label:i,onSelect:l,checked:c,disabled:m},d){const u=r.useId(),p=r.useCallback(()=>{},[]);return t.jsx(f,{as:"div",role:"menuitemcheckbox","aria-checked":c,className:a,Icon:s,label:i,onSelect:l,disabled:m,children:t.jsx(I,{id:u,ref:d,"aria-hidden":!0,checked:c,disabled:m,onChange:p})})});try{n.displayName="ToggleMenuItem",n.__docgenInfo={description:"A menu item with a toggle control.\nMust be used within a compound Menu or other `menu` or `menubar` aria role subtree.",displayName:"ToggleMenuItem",props:{disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}},label:{defaultValue:null,description:"The label to show on this menu item.",name:"label",required:!0,type:{name:"string | null"}},Icon:{defaultValue:null,description:"The icon to show on this menu item.\nWhen `Icon` is a ReactNode, it should spread the props",name:"Icon",required:!0,type:{name:"ReactNode | ComponentType>"}},className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},onSelect:{defaultValue:null,description:`Event callback for when the item is selected via mouse, touch, or keyboard. +import{j as t}from"./jsx-runtime-DR9Q75dM.js";import{r}from"./index-DRjF_FHU.js";import{C as h,E as g}from"./extensions-DRIHxRsb.js";import{M as f}from"./MenuItem-YyrVQu2n.js";import{T as I}from"./Toggle-BRCP4wr-.js";import"./index-lhGYx47h.js";import"./Text-BvzksikX.js";import"./Typography-DzhKoIWt.js";import"./chevron-right-DND12YKW.js";import"./index-C8xBnYIG.js";import"./index-4or38LtJ.js";import"./index-CGa_gRws.js";import"./index-BXwbELbV.js";import"./index-Ksfxd92j.js";import"./index-BvEl7W6R.js";const n=r.forwardRef(function({className:a,Icon:s,label:i,onSelect:l,checked:c,disabled:m},d){const u=r.useId(),p=r.useCallback(()=>{},[]);return t.jsx(f,{as:"div",role:"menuitemcheckbox","aria-checked":c,className:a,Icon:s,label:i,onSelect:l,disabled:m,children:t.jsx(I,{id:u,ref:d,"aria-hidden":!0,checked:c,disabled:m,onChange:p})})});try{n.displayName="ToggleMenuItem",n.__docgenInfo={description:"A menu item with a toggle control.\nMust be used within a compound Menu or other `menu` or `menubar` aria role subtree.",displayName:"ToggleMenuItem",props:{className:{defaultValue:null,description:"The CSS class name.",name:"className",required:!1,type:{name:"string"}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}},label:{defaultValue:null,description:"The label to show on this menu item.",name:"label",required:!0,type:{name:"string | null"}},Icon:{defaultValue:null,description:"The icon to show on this menu item.\nWhen `Icon` is a ReactNode, it should spread the props",name:"Icon",required:!0,type:{name:"ReactNode | ComponentType>"}},onSelect:{defaultValue:null,description:`Event callback for when the item is selected via mouse, touch, or keyboard. Calling event.preventDefault in this handler will prevent the menu from being dismissed.`,name:"onSelect",required:!0,type:{name:"((e: Event) => void) | null"}},checked:{defaultValue:null,description:"Whether the toggle is checked.",name:"checked",required:!0,type:{name:"boolean"}}}}}catch{}const F={title:"Menu/ToggleMenuItem",component:n,tags:["autodocs"],argTypes:{},args:{}},b=o=>{const[a,s]=r.useState(!1);return t.jsxs("div",{style:{width:300},children:[t.jsx(n,{...o,Icon:h,label:"First item",checked:a,onSelect:i=>{i.preventDefault(),s(l=>!l)}}),t.jsx(n,{...o,Icon:g,label:"Second item with a name that's quite long",checked:!0,disabled:!0})]})},e=b.bind({});e.args={};e.parameters={...e.parameters,docs:{...e.parameters?.docs,source:{originalSource:`args => { const [firstChecked, setFirstChecked] = useState(false); diff --git a/assets/Tooltip-DGTzhuPA.js b/assets/Tooltip-D2McGlOP.js similarity index 99% rename from assets/Tooltip-DGTzhuPA.js rename to assets/Tooltip-D2McGlOP.js index f27242cb..e50abfde 100644 --- a/assets/Tooltip-DGTzhuPA.js +++ b/assets/Tooltip-D2McGlOP.js @@ -1,4 +1,4 @@ -import{j as n}from"./jsx-runtime-DR9Q75dM.js";import{r as l}from"./index-DRjF_FHU.js";import{F as O,u as j,b as G,c as U,o as Y,f as B,s as H,d as J,e as K,g as X,h as $,i as z,j as L,k as Q,l as Z,m as ee,a as te}from"./floating-ui.react-CACRriTf.js";import{c as E}from"./index-lhGYx47h.js";const P=l.createContext(null);function x(){const e=l.useContext(P);if(e==null)throw new Error("Tooltip components must be wrapped in ");return e}const oe="_tooltip_1pslb_17",ne="_invisible_1pslb_30",ae="_caption_1pslb_37",ie="_arrow_1pslb_42",m={tooltip:oe,invisible:ne,caption:ae,arrow:ie},q={open:300,close:0},w=({children:e})=>n.jsx(O,{delay:q,timeoutMs:300,children:e});w.displayName="TooltipProvider";try{w.displayName="TooltipProvider",w.__docgenInfo={description:`Enables tooltips to share a global "warm-up" period for their hover delay. +import{j as n}from"./jsx-runtime-DR9Q75dM.js";import{r as l}from"./index-DRjF_FHU.js";import{F as O,u as j,b as G,c as U,o as Y,f as B,s as H,d as J,e as K,g as X,h as $,i as z,j as L,k as Q,l as Z,m as ee,a as te}from"./floating-ui.react-CSvGZjCC.js";import{c as E}from"./index-lhGYx47h.js";const P=l.createContext(null);function x(){const e=l.useContext(P);if(e==null)throw new Error("Tooltip components must be wrapped in ");return e}const oe="_tooltip_1pslb_17",ne="_invisible_1pslb_30",ae="_caption_1pslb_37",ie="_arrow_1pslb_42",m={tooltip:oe,invisible:ne,caption:ae,arrow:ie},q={open:300,close:0},w=({children:e})=>n.jsx(O,{delay:q,timeoutMs:300,children:e});w.displayName="TooltipProvider";try{w.displayName="TooltipProvider",w.__docgenInfo={description:`Enables tooltips to share a global "warm-up" period for their hover delay. You must wrap your application in this component for tooltips to function.`,displayName:"TooltipProvider",props:{}}}catch{}function le({open:e,disabled:a=!1,onOpenChange:i,placement:t="bottom",isTriggerInteractive:r,caption:o,"aria-atomic":u,"aria-live":d,...b}){const s=j(),p=j(),h=l.useRef(null),[R,V]=l.useState(!1),v=a?!1:e??R,g=(I,M,S)=>{i?.(I,M,S),e===void 0&&V(I)},y=G({placement:t,open:v,onOpenChange:g,whileElementsMounted:U,middleware:[Y(6),B({crossAxis:t.includes("-"),fallbackAxisSideDirection:"start",padding:5}),H({padding:5}),J({element:h})]}),c=y.context,{delay:A,initialDelay:F}=K(c);if(F!==q)throw new Error("Tooltips must be wrapped in a global ");const N=X(c,{move:!1,enabled:e===void 0,delay:r?A:{}}),W=$(c,{enabled:e===void 0,visibleOnly:!1}),k=z(c),f="label"in b?"label":"description",T=L(c,{enabled:f==="description",role:"tooltip"}),D=l.useMemo(()=>f==="label"?{reference:{"aria-labelledby":s,"aria-describedby":o?p:void 0}}:{},[f,s,p]),_=Q([N,W,k,T,D]);return l.useMemo(()=>({labelId:s,captionId:o?p:void 0,caption:o,purpose:f,open:v,setOpen:g,tooltipProps:{"aria-atomic":u,"aria-live":d},..._,...y,arrowRef:h}),[s,p,o,T,v,g,_,y,h])}function C({children:e,isTriggerInteractive:a=!0,nonInteractiveTriggerTabIndex:i=0,...t}){const r=le({isTriggerInteractive:a,...t});return n.jsxs(P.Provider,{value:r,children:[n.jsx(pe,{isTriggerInteractive:a,nonInteractiveTriggerTabIndex:i,children:e}),n.jsxs(se,{children:[n.jsx("span",{id:r.labelId,children:"label"in t?t.label:t.description}),n.jsx(re,{})]})]})}function re(){const{caption:e,captionId:a}=x();if(!e)return null;const t=typeof e=="string"?"span":"div";return n.jsx(t,{id:a,className:E(m.caption,"cpd-theme-dark"),children:e})}function se({children:e}){const{context:a,open:i,arrowRef:t,purpose:r,...o}=x();return!i&&r!=="label"?null:n.jsx(Z,{children:n.jsxs("div",{ref:o.refs.setFloating,style:o.floatingStyles,...o.tooltipProps,...o.getFloatingProps(),className:E(m.tooltip,{[m.invisible]:r==="label"&&!i}),children:[n.jsx(ee,{ref:t,context:a,width:10,height:6,className:m.arrow}),e]})})}const pe=({children:e,isTriggerInteractive:a,nonInteractiveTriggerTabIndex:i})=>{const t=x(),r=e?.ref,o=te([t.refs.setReference,r]),u=l.useMemo(()=>{if(l.isValidElement(e))if(a){const d=t.getReferenceProps({ref:o,...e.props});return l.cloneElement(e,d)}else{const d=t.getReferenceProps({ref:o,tabIndex:i}),{"aria-labelledby":b,"aria-describedby":s,...p}=d;return n.jsx("span",{tabIndex:i,...p,children:l.cloneElement(e,{"aria-labelledby":b,"aria-describedby":s})})}},[t,o,e]);if(!u)throw new Error("Tooltip anchor must be a single valid React element");return u};try{C.displayName="Tooltip",C.__docgenInfo={description:"A tooltip component",displayName:"Tooltip",props:{disabled:{defaultValue:null,description:"Whether the tooltip should be forced to be in a closed state.",name:"disabled",required:!1,type:{name:"boolean"}},caption:{defaultValue:null,description:`The caption of the tooltip. JSX.Element can be used to provide accessibility content like kbd element. Keep in mind, the caption should not be used for interactive content.`,name:"caption",required:!1,type:{name:"string | Element"}},"aria-atomic":{defaultValue:null,description:`Additional aria-* attributes to pass through to the floating tooltip for diff --git a/assets/Tooltip.stories-DfHa5l-o.js b/assets/Tooltip.stories-D6PgfVTA.js similarity index 96% rename from assets/Tooltip.stories-DfHa5l-o.js rename to assets/Tooltip.stories-D6PgfVTA.js index 1aa0078f..e889650e 100644 --- a/assets/Tooltip.stories-DfHa5l-o.js +++ b/assets/Tooltip.stories-D6PgfVTA.js @@ -1,4 +1,4 @@ -import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{a as m,T as h}from"./Tooltip-DGTzhuPA.js";import{U as g}from"./user-profile-cqTW1cHH.js";import{I as u}from"./IconButton-CBGH5UyO.js";import"./index-DRjF_FHU.js";import"./floating-ui.react-CACRriTf.js";import"./index-BvEl7W6R.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";import"./IndicatorIcon-CKMK3E77.js";const k={title:"Tooltip",component:m,tags:["autodocs"],controls:{include:["placement","open","label","caption","isTriggerInteractive"]},argTypes:{placement:{control:"inline-radio",options:["top","right","left","bottom"]},open:{control:"boolean"},isTriggerInteractive:{control:"boolean"},label:{control:"text"},description:{control:"text"},caption:{control:"text"}},args:{onOpenChange:void 0,children:e.jsx(u,{children:e.jsx(g,{})})},decorators:[r=>e.jsx("div",{style:{padding:100},children:e.jsx(h,{children:e.jsx(r,{})})})]},b=({children:r})=>e.jsx("div",{style:{display:"flex",gap:"50px",flexDirection:"column",alignItems:"center"},children:r}),x=()=>e.jsx(b,{children:["top","top-start","right","right-end","bottom","bottom-end","left","left-start"].map(r=>e.jsx(m,{open:!0,placement:r,label:"@bob:example.org",children:e.jsx(u,{children:e.jsx(g,{})})},r))}),o=x.bind({});o.args={};const t={args:{label:"@bob:example.org"}},a={args:{label:"I can have a caption",caption:"My beautiful caption"}},s={args:{label:"Copy",caption:e.jsxs(e.Fragment,{children:[e.jsx("kbd",{children:"Ctrl"})," + ",e.jsx("kbd",{children:"C"})]})}},n={args:{open:!0,label:"I'm always open"}},i={args:{open:!1,description:"You can't see me",children:e.jsx("span",{children:"No tooltip to see here"})}},c={args:{disabled:!0,description:"You can't see me",children:e.jsx("span",{children:"No tooltip to see here"})}},p={args:{isTriggerInteractive:!0,description:"Shown with delay",children:e.jsx("a",{href:"https://example.org",children:"Link"})}},l={args:{isTriggerInteractive:!1,description:"Shown without delay",children:e.jsx("span",{children:"Just some text"})}},d={args:{open:!0,description:"Employer Identification Number",children:e.jsx("span",{children:"EIN"})}};o.parameters={...o.parameters,docs:{...o.parameters?.docs,source:{originalSource:`() => +import{j as e}from"./jsx-runtime-DR9Q75dM.js";import{a as m,T as h}from"./Tooltip-D2McGlOP.js";import{U as g}from"./user-profile-cqTW1cHH.js";import{I as u}from"./IconButton-Bf1MsgYV.js";import"./index-DRjF_FHU.js";import"./floating-ui.react-CSvGZjCC.js";import"./index-BvEl7W6R.js";import"./index-lhGYx47h.js";import"./UnstyledButton-DuxpNl0e.js";import"./IndicatorIcon-CKMK3E77.js";const k={title:"Tooltip",component:m,tags:["autodocs"],controls:{include:["placement","open","label","caption","isTriggerInteractive"]},argTypes:{placement:{control:"inline-radio",options:["top","right","left","bottom"]},open:{control:"boolean"},isTriggerInteractive:{control:"boolean"},label:{control:"text"},description:{control:"text"},caption:{control:"text"}},args:{onOpenChange:void 0,children:e.jsx(u,{children:e.jsx(g,{})})},decorators:[r=>e.jsx("div",{style:{padding:100},children:e.jsx(h,{children:e.jsx(r,{})})})]},b=({children:r})=>e.jsx("div",{style:{display:"flex",gap:"50px",flexDirection:"column",alignItems:"center"},children:r}),x=()=>e.jsx(b,{children:["top","top-start","right","right-end","bottom","bottom-end","left","left-start"].map(r=>e.jsx(m,{open:!0,placement:r,label:"@bob:example.org",children:e.jsx(u,{children:e.jsx(g,{})})},r))}),o=x.bind({});o.args={};const t={args:{label:"@bob:example.org"}},a={args:{label:"I can have a caption",caption:"My beautiful caption"}},s={args:{label:"Copy",caption:e.jsxs(e.Fragment,{children:[e.jsx("kbd",{children:"Ctrl"})," + ",e.jsx("kbd",{children:"C"})]})}},n={args:{open:!0,label:"I'm always open"}},i={args:{open:!1,description:"You can't see me",children:e.jsx("span",{children:"No tooltip to see here"})}},c={args:{disabled:!0,description:"You can't see me",children:e.jsx("span",{children:"No tooltip to see here"})}},p={args:{isTriggerInteractive:!0,description:"Shown with delay",children:e.jsx("a",{href:"https://example.org",children:"Link"})}},l={args:{isTriggerInteractive:!1,description:"Shown without delay",children:e.jsx("span",{children:"Just some text"})}},d={args:{open:!0,description:"Employer Identification Number",children:e.jsx("span",{children:"EIN"})}};o.parameters={...o.parameters,docs:{...o.parameters?.docs,source:{originalSource:`() => {(["top", "top-start", "right", "right-end", "bottom", "bottom-end", "left", "left-start"] as Array).map(placement => diff --git a/assets/entry-preview-CI_Ec58I.js b/assets/entry-preview-CmGtEz1u.js similarity index 99% rename from assets/entry-preview-CI_Ec58I.js rename to assets/entry-preview-CmGtEz1u.js index f8b3ed65..1903f2c8 100644 --- a/assets/entry-preview-CI_Ec58I.js +++ b/assets/entry-preview-CmGtEz1u.js @@ -1,5 +1,5 @@ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./react-18-BZ4hdgop.js","./index-DRjF_FHU.js","./index-BvEl7W6R.js"])))=>i.map(i=>d[i]); -import{_ as rr}from"./iframe-80GKSfNA.js";import{_ as tr,a as sr,b as L}from"./chunk-XP5HYGXS-BGCqD1aY.js";import{r as Y,R as re}from"./index-DRjF_FHU.js";import{r as nr}from"./index-BvEl7W6R.js";import"../sb-preview/runtime.js";var b={};/** +import{_ as rr}from"./iframe-DWIAQds9.js";import{_ as tr,a as sr,b as L}from"./chunk-XP5HYGXS-BGCqD1aY.js";import{r as Y,R as re}from"./index-DRjF_FHU.js";import{r as nr}from"./index-BvEl7W6R.js";import"../sb-preview/runtime.js";var b={};/** * @license React * react-dom-test-utils.production.min.js * diff --git a/assets/floating-ui.react-CACRriTf.js b/assets/floating-ui.react-CSvGZjCC.js similarity index 71% rename from assets/floating-ui.react-CACRriTf.js rename to assets/floating-ui.react-CSvGZjCC.js index 500f3532..6ced3633 100644 --- a/assets/floating-ui.react-CACRriTf.js +++ b/assets/floating-ui.react-CSvGZjCC.js @@ -1,4 +1,4 @@ import{r as f,a as Rn}from"./index-DRjF_FHU.js";import{r as Ut}from"./index-BvEl7W6R.js";function Ue(){return typeof window<"u"}function pe(e){return Xt(e)?(e.nodeName||"").toLowerCase():"#document"}function J(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function oe(e){var t;return(t=(Xt(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Xt(e){return Ue()?e instanceof Node||e instanceof J(e).Node:!1}function j(e){return Ue()?e instanceof Element||e instanceof J(e).Element:!1}function z(e){return Ue()?e instanceof HTMLElement||e instanceof J(e).HTMLElement:!1}function at(e){return!Ue()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof J(e).ShadowRoot}function Le(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function En(e){return["table","td","th"].includes(pe(e))}function Xe(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function yt(e){const t=Ge(),n=j(e)?ee(e):e;return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function Cn(e){let t=se(e);for(;z(t)&&!de(t);){if(yt(t))return t;if(Xe(t))return null;t=se(t)}return null}function Ge(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function de(e){return["html","body","#document"].includes(pe(e))}function ee(e){return J(e).getComputedStyle(e)}function Ze(e){return j(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function se(e){if(pe(e)==="html")return e;const t=e.assignedSlot||e.parentNode||at(e)&&e.host||oe(e);return at(t)?t.host:t}function Gt(e){const t=se(e);return de(t)?e.ownerDocument?e.ownerDocument.body:e.body:z(t)&&Le(t)?t:Gt(t)}function fe(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Gt(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),i=J(o);if(s){const c=ft(i);return t.concat(i,i.visualViewport||[],Le(o)?o:[],c&&n?fe(c):[])}return t.concat(o,fe(o,[],n))}function ft(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ie(e){let t=e.activeElement;for(;((n=t)==null||(n=n.shadowRoot)==null?void 0:n.activeElement)!=null;){var n;t=t.shadowRoot.activeElement}return t}function G(e,t){if(!e||!t)return!1;const n=t.getRootNode==null?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&at(n)){let r=t;for(;r;){if(e===r)return!0;r=r.parentNode||r.host}}return!1}function Zt(){const e=navigator.userAgentData;return e!=null&&e.platform?e.platform:navigator.platform}function Jt(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:n,version:r}=t;return n+"/"+r}).join(" "):navigator.userAgent}function Tn(e){return e.mozInputSource===0&&e.isTrusted?!0:dt()&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function Qt(e){return Sn()?!1:!dt()&&e.width===0&&e.height===0||dt()&&e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0&&e.pointerType==="touch"}function en(){return/apple/i.test(navigator.vendor)}function dt(){const e=/android/i;return e.test(Zt())||e.test(Jt())}function An(){return Zt().toLowerCase().startsWith("mac")&&!navigator.maxTouchPoints}function Sn(){return Jt().includes("jsdom/")}function mt(e,t){const n=["mouse","pen"];return n.push("",void 0),n.includes(e)}function On(e){return"nativeEvent"in e}function Pn(e){return e.matches("html,body")}function Z(e){return e?.ownerDocument||document}function rt(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);const n=e;return n.target!=null&&t.contains(n.target)}function ae(e){return"composedPath"in e?e.composedPath()[0]:e.target}const In="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function tn(e){return z(e)&&e.matches(In)}function ot(e){e.preventDefault(),e.stopPropagation()}function Mn(e){return e?e.getAttribute("role")==="combobox"&&tn(e):!1}const Ln=["top","right","bottom","left"],me=Math.min,Q=Math.max,_e=Math.round,ke=Math.floor,re=e=>({x:e,y:e}),Dn={left:"right",right:"left",bottom:"top",top:"bottom"},Fn={start:"end",end:"start"};function gt(e,t,n){return Q(e,me(t,n))}function ce(e,t){return typeof e=="function"?e(t):e}function le(e){return e.split("-")[0]}function Ae(e){return e.split("-")[1]}function wt(e){return e==="x"?"y":"x"}function xt(e){return e==="y"?"height":"width"}function ge(e){return["top","bottom"].includes(le(e))?"y":"x"}function Rt(e){return wt(ge(e))}function kn(e,t,n){n===void 0&&(n=!1);const r=Ae(e),o=Rt(e),s=xt(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Ve(i)),[i,Ve(i)]}function Nn(e){const t=Ve(e);return[pt(e),t,pt(t)]}function pt(e){return e.replace(/start|end/g,t=>Fn[t])}function $n(e,t,n){const r=["left","right"],o=["right","left"],s=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?s:i;default:return[]}}function Wn(e,t,n,r){const o=Ae(e);let s=$n(le(e),n==="start",r);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(pt)))),s}function Ve(e){return e.replace(/left|right|bottom|top/g,t=>Dn[t])}function Bn(e){return{top:0,right:0,bottom:0,left:0,...e}}function nn(e){return typeof e!="number"?Bn(e):{top:e,right:e,bottom:e,left:e}}function He(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}/*! * tabbable 6.2.0 * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE -*/var _n=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],Ke=_n.join(","),rn=typeof Element>"u",Te=rn?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,je=!rn&&Element.prototype.getRootNode?function(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}:function(e){return e?.ownerDocument},qe=function e(t,n){var r;n===void 0&&(n=!0);var o=t==null||(r=t.getAttribute)===null||r===void 0?void 0:r.call(t,"inert"),s=o===""||o==="true",i=s||n&&t&&e(t.parentNode);return i},Vn=function(t){var n,r=t==null||(n=t.getAttribute)===null||n===void 0?void 0:n.call(t,"contenteditable");return r===""||r==="true"},Hn=function(t,n,r){if(qe(t))return[];var o=Array.prototype.slice.apply(t.querySelectorAll(Ke));return n&&Te.call(t,Ke)&&o.unshift(t),o=o.filter(r),o},Kn=function e(t,n,r){for(var o=[],s=Array.from(t);s.length;){var i=s.shift();if(!qe(i,!1))if(i.tagName==="SLOT"){var c=i.assignedElements(),a=c.length?c:i.children,l=e(a,!0,r);r.flatten?o.push.apply(o,l):o.push({scopeParent:i,candidates:l})}else{var d=Te.call(i,Ke);d&&r.filter(i)&&(n||!t.includes(i))&&o.push(i);var m=i.shadowRoot||typeof r.getShadowRoot=="function"&&r.getShadowRoot(i),h=!qe(m,!1)&&(!r.shadowRootFilter||r.shadowRootFilter(i));if(m&&h){var u=e(m===!0?i.children:m.children,!0,r);r.flatten?o.push.apply(o,u):o.push({scopeParent:i,candidates:u})}else s.unshift.apply(s,i.children)}}return o},on=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},sn=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||Vn(t))&&!on(t)?0:t.tabIndex},jn=function(t,n){var r=sn(t);return r<0&&n&&!on(t)?0:r},qn=function(t,n){return t.tabIndex===n.tabIndex?t.documentOrder-n.documentOrder:t.tabIndex-n.tabIndex},cn=function(t){return t.tagName==="INPUT"},Yn=function(t){return cn(t)&&t.type==="hidden"},zn=function(t){var n=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(r){return r.tagName==="SUMMARY"});return n},Un=function(t,n){for(var r=0;rsummary:first-of-type"),i=s?t.parentElement:t;if(Te.call(i,"details:not([open]) *"))return!0;if(!r||r==="full"||r==="legacy-full"){if(typeof o=="function"){for(var c=t;t;){var a=t.parentElement,l=je(t);if(a&&!a.shadowRoot&&o(a)===!0)return St(t);t.assignedSlot?t=t.assignedSlot:!a&&l!==t.ownerDocument?t=l.host:t=a}t=c}if(Jn(t))return!t.getClientRects().length;if(r!=="legacy-full")return!0}else if(r==="non-zero-area")return St(t);return!1},er=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var n=t.parentElement;n;){if(n.tagName==="FIELDSET"&&n.disabled){for(var r=0;r=0)},rr=function e(t){var n=[],r=[];return t.forEach(function(o,s){var i=!!o.scopeParent,c=i?o.scopeParent:o,a=jn(c,i),l=i?e(o.candidates):c;a===0?i?n.push.apply(n,l):n.push(c):r.push({documentOrder:s,tabIndex:a,item:o,isScope:i,content:l})}),r.sort(qn).reduce(function(o,s){return s.isScope?o.push.apply(o,s.content):o.push(s.content),o},[]).concat(n)},Je=function(t,n){n=n||{};var r;return n.getShadowRoot?r=Kn([t],n.includeContainer,{filter:ht.bind(null,n),flatten:!1,getShadowRoot:n.getShadowRoot,shadowRootFilter:nr}):r=Hn(t,n.includeContainer,ht.bind(null,n)),rr(r)},or=function(t,n){if(n=n||{},!t)throw new Error("No node provided");return Te.call(t,Ke)===!1?!1:ht(n,t)};function Ot(e,t,n){let{reference:r,floating:o}=e;const s=ge(t),i=Rt(t),c=xt(i),a=le(t),l=s==="y",d=r.x+r.width/2-o.width/2,m=r.y+r.height/2-o.height/2,h=r[c]/2-o[c]/2;let u;switch(a){case"top":u={x:d,y:r.y-o.height};break;case"bottom":u={x:d,y:r.y+r.height};break;case"right":u={x:r.x+r.width,y:m};break;case"left":u={x:r.x-o.width,y:m};break;default:u={x:r.x,y:r.y}}switch(Ae(t)){case"start":u[i]-=h*(n&&l?-1:1);break;case"end":u[i]+=h*(n&&l?-1:1);break}return u}const ir=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,c=s.filter(Boolean),a=await(i.isRTL==null?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:m}=Ot(l,r,a),h=r,u={},g=0;for(let p=0;p({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:c,middlewareData:a}=t,{element:l,padding:d=0}=ce(e,t)||{};if(l==null)return{};const m=nn(d),h={x:n,y:r},u=Rt(o),g=xt(u),p=await i.getDimensions(l),w=u==="y",y=w?"top":"left",R=w?"bottom":"right",b=w?"clientHeight":"clientWidth",x=s.reference[g]+s.reference[u]-h[u]-s.floating[g],S=h[u]-s.reference[u],I=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let L=I?I[b]:0;(!L||!await(i.isElement==null?void 0:i.isElement(I)))&&(L=c.floating[b]||s.floating[g]);const D=x/2-S/2,B=L/2-p[g]/2-1,_=me(m[y],B),$=me(m[R],B),A=_,H=L-p[g]-$,V=L/2-p[g]/2+D,O=gt(A,V,H),E=!a.arrow&&Ae(o)!=null&&V!==O&&s.reference[g]/2-(VV<=0)){var $,A;const V=((($=s.flip)==null?void 0:$.index)||0)+1,O=L[V];if(O)return{data:{index:V,overflows:_},reset:{placement:O}};let E=(A=_.filter(C=>C.overflows[0]<=0).sort((C,T)=>C.overflows[1]-T.overflows[1])[0])==null?void 0:A.placement;if(!E)switch(u){case"bestFit":{var H;const C=(H=_.filter(T=>{if(I){const v=ge(T.placement);return v===R||v==="y"}return!0}).map(T=>[T.placement,T.overflows.filter(v=>v>0).reduce((v,F)=>v+F,0)]).sort((T,v)=>T[1]-v[1])[0])==null?void 0:H[0];C&&(E=C);break}case"initialPlacement":E=c;break}if(o!==E)return{reset:{placement:E}}}return{}}}};function Pt(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function It(e){return Ln.some(t=>e[t]>=0)}const lr=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=ce(e,t);switch(r){case"referenceHidden":{const s=await Pe(t,{...o,elementContext:"reference"}),i=Pt(s,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:It(i)}}}case"escaped":{const s=await Pe(t,{...o,altBoundary:!0}),i=Pt(s,n.floating);return{data:{escapedOffsets:i,escaped:It(i)}}}default:return{}}}}};async function ur(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=le(n),c=Ae(n),a=ge(n)==="y",l=["left","top"].includes(i)?-1:1,d=s&&a?-1:1,m=ce(t,e);let{mainAxis:h,crossAxis:u,alignmentAxis:g}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return c&&typeof g=="number"&&(u=c==="end"?g*-1:g),a?{x:u*d,y:h*l}:{x:h*l,y:u*d}}const ar=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:i,middlewareData:c}=t,a=await ur(t,e);return i===((n=c.offset)==null?void 0:n.placement)&&(r=c.arrow)!=null&&r.alignmentOffset?{}:{x:o+a.x,y:s+a.y,data:{...a,placement:i}}}}},fr=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:c={fn:w=>{let{x:y,y:R}=w;return{x:y,y:R}}},...a}=ce(e,t),l={x:n,y:r},d=await Pe(t,a),m=ge(le(o)),h=wt(m);let u=l[h],g=l[m];if(s){const w=h==="y"?"top":"left",y=h==="y"?"bottom":"right",R=u+d[w],b=u-d[y];u=gt(R,u,b)}if(i){const w=m==="y"?"top":"left",y=m==="y"?"bottom":"right",R=g+d[w],b=g-d[y];g=gt(R,g,b)}const p=c.fn({...t,[h]:u,[m]:g});return{...p,data:{x:p.x-n,y:p.y-r,enabled:{[h]:s,[m]:i}}}}}},dr=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:i}=t,{offset:c=0,mainAxis:a=!0,crossAxis:l=!0}=ce(e,t),d={x:n,y:r},m=ge(o),h=wt(m);let u=d[h],g=d[m];const p=ce(c,t),w=typeof p=="number"?{mainAxis:p,crossAxis:0}:{mainAxis:0,crossAxis:0,...p};if(a){const b=h==="y"?"height":"width",x=s.reference[h]-s.floating[b]+w.mainAxis,S=s.reference[h]+s.reference[b]-w.mainAxis;uS&&(u=S)}if(l){var y,R;const b=h==="y"?"width":"height",x=["top","left"].includes(le(o)),S=s.reference[m]-s.floating[b]+(x&&((y=i.offset)==null?void 0:y[m])||0)+(x?0:w.crossAxis),I=s.reference[m]+s.reference[b]+(x?0:((R=i.offset)==null?void 0:R[m])||0)-(x?w.crossAxis:0);gI&&(g=I)}return{[h]:u,[m]:g}}}},mr=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:i,elements:c}=t,{apply:a=()=>{},...l}=ce(e,t),d=await Pe(t,l),m=le(o),h=Ae(o),u=ge(o)==="y",{width:g,height:p}=s.floating;let w,y;m==="top"||m==="bottom"?(w=m,y=h===(await(i.isRTL==null?void 0:i.isRTL(c.floating))?"start":"end")?"left":"right"):(y=m,w=h==="end"?"top":"bottom");const R=p-d.top-d.bottom,b=g-d.left-d.right,x=me(p-d[w],R),S=me(g-d[y],b),I=!t.middlewareData.shift;let L=x,D=S;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=b),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(L=R),I&&!h){const _=Q(d.left,0),$=Q(d.right,0),A=Q(d.top,0),H=Q(d.bottom,0);u?D=g-2*(_!==0||$!==0?_+$:Q(d.left,d.right)):L=p-2*(A!==0||H!==0?A+H:Q(d.top,d.bottom))}await a({...t,availableWidth:D,availableHeight:L});const B=await i.getDimensions(c.floating);return g!==B.width||p!==B.height?{reset:{rects:!0}}:{}}}};function ln(e){const t=ee(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=z(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,c=_e(n)!==s||_e(r)!==i;return c&&(n=s,r=i),{width:n,height:r,$:c}}function Et(e){return j(e)?e:e.contextElement}function Ee(e){const t=Et(e);if(!z(t))return re(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=ln(t);let i=(s?_e(n.width):n.width)/r,c=(s?_e(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!c||!Number.isFinite(c))&&(c=1),{x:i,y:c}}const gr=re(0);function un(e){const t=J(e);return!Ge()||!t.visualViewport?gr:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function pr(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==J(e)?!1:t}function ve(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=Et(e);let i=re(1);t&&(r?j(r)&&(i=Ee(r)):i=Ee(e));const c=pr(s,n,r)?un(s):re(0);let a=(o.left+c.x)/i.x,l=(o.top+c.y)/i.y,d=o.width/i.x,m=o.height/i.y;if(s){const h=J(s),u=r&&j(r)?J(r):r;let g=h,p=ft(g);for(;p&&r&&u!==g;){const w=Ee(p),y=p.getBoundingClientRect(),R=ee(p),b=y.left+(p.clientLeft+parseFloat(R.paddingLeft))*w.x,x=y.top+(p.clientTop+parseFloat(R.paddingTop))*w.y;a*=w.x,l*=w.y,d*=w.x,m*=w.y,a+=b,l+=x,g=J(p),p=ft(g)}}return He({width:d,height:m,x:a,y:l})}function Ct(e,t){const n=Ze(e).scrollLeft;return t?t.left+n:ve(oe(e)).left+n}function an(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:Ct(e,r)),s=r.top+t.scrollTop;return{x:o,y:s}}function hr(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=oe(r),c=t?Xe(t.floating):!1;if(r===i||c&&s)return n;let a={scrollLeft:0,scrollTop:0},l=re(1);const d=re(0),m=z(r);if((m||!m&&!s)&&((pe(r)!=="body"||Le(i))&&(a=Ze(r)),z(r))){const u=ve(r);l=Ee(r),d.x=u.x+r.clientLeft,d.y=u.y+r.clientTop}const h=i&&!m&&!s?an(i,a,!0):re(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-a.scrollLeft*l.x+d.x+h.x,y:n.y*l.y-a.scrollTop*l.y+d.y+h.y}}function vr(e){return Array.from(e.getClientRects())}function br(e){const t=oe(e),n=Ze(e),r=e.ownerDocument.body,o=Q(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=Q(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+Ct(e);const c=-n.scrollTop;return ee(r).direction==="rtl"&&(i+=Q(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:c}}function yr(e,t){const n=J(e),r=oe(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,c=0,a=0;if(o){s=o.width,i=o.height;const l=Ge();(!l||l&&t==="fixed")&&(c=o.offsetLeft,a=o.offsetTop)}return{width:s,height:i,x:c,y:a}}function wr(e,t){const n=ve(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=z(e)?Ee(e):re(1),i=e.clientWidth*s.x,c=e.clientHeight*s.y,a=o*s.x,l=r*s.y;return{width:i,height:c,x:a,y:l}}function Mt(e,t,n){let r;if(t==="viewport")r=yr(e,n);else if(t==="document")r=br(oe(e));else if(j(t))r=wr(t,n);else{const o=un(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return He(r)}function fn(e,t){const n=se(e);return n===t||!j(n)||de(n)?!1:ee(n).position==="fixed"||fn(n,t)}function xr(e,t){const n=t.get(e);if(n)return n;let r=fe(e,[],!1).filter(c=>j(c)&&pe(c)!=="body"),o=null;const s=ee(e).position==="fixed";let i=s?se(e):e;for(;j(i)&&!de(i);){const c=ee(i),a=yt(i);!a&&c.position==="fixed"&&(o=null),(s?!a&&!o:!a&&c.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Le(i)&&!a&&fn(e,i))?r=r.filter(d=>d!==i):o=c,i=se(i)}return t.set(e,r),r}function Rr(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?Xe(t)?[]:xr(t,this._c):[].concat(n),r],c=i[0],a=i.reduce((l,d)=>{const m=Mt(t,d,o);return l.top=Q(m.top,l.top),l.right=me(m.right,l.right),l.bottom=me(m.bottom,l.bottom),l.left=Q(m.left,l.left),l},Mt(t,c,o));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function Er(e){const{width:t,height:n}=ln(e);return{width:t,height:n}}function Cr(e,t,n){const r=z(t),o=oe(t),s=n==="fixed",i=ve(e,!0,s,t);let c={scrollLeft:0,scrollTop:0};const a=re(0);if(r||!r&&!s)if((pe(t)!=="body"||Le(o))&&(c=Ze(t)),r){const h=ve(t,!0,s,t);a.x=h.x+t.clientLeft,a.y=h.y+t.clientTop}else o&&(a.x=Ct(o));const l=o&&!r&&!s?an(o,c):re(0),d=i.left+c.scrollLeft-a.x-l.x,m=i.top+c.scrollTop-a.y-l.y;return{x:d,y:m,width:i.width,height:i.height}}function it(e){return ee(e).position==="static"}function Lt(e,t){if(!z(e)||ee(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return oe(e)===n&&(n=n.ownerDocument.body),n}function dn(e,t){const n=J(e);if(Xe(e))return n;if(!z(e)){let o=se(e);for(;o&&!de(o);){if(j(o)&&!it(o))return o;o=se(o)}return n}let r=Lt(e,t);for(;r&&En(r)&&it(r);)r=Lt(r,t);return r&&de(r)&&it(r)&&!yt(r)?n:r||Cn(e)||n}const Tr=async function(e){const t=this.getOffsetParent||dn,n=this.getDimensions,r=await n(e.floating);return{reference:Cr(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Ar(e){return ee(e).direction==="rtl"}const Sr={convertOffsetParentRelativeRectToViewportRelativeRect:hr,getDocumentElement:oe,getClippingRect:Rr,getOffsetParent:dn,getElementRects:Tr,getClientRects:vr,getDimensions:Er,getScale:Ee,isElement:j,isRTL:Ar};function Or(e,t){let n=null,r;const o=oe(e);function s(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function i(c,a){c===void 0&&(c=!1),a===void 0&&(a=1),s();const{left:l,top:d,width:m,height:h}=e.getBoundingClientRect();if(c||t(),!m||!h)return;const u=ke(d),g=ke(o.clientWidth-(l+m)),p=ke(o.clientHeight-(d+h)),w=ke(l),R={rootMargin:-u+"px "+-g+"px "+-p+"px "+-w+"px",threshold:Q(0,me(1,a))||1};let b=!0;function x(S){const I=S[0].intersectionRatio;if(I!==a){if(!b)return i();I?i(!1,I):r=setTimeout(()=>{i(!1,1e-7)},1e3)}b=!1}try{n=new IntersectionObserver(x,{...R,root:o.ownerDocument})}catch{n=new IntersectionObserver(x,R)}n.observe(e)}return i(!0),s}function lo(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:a=!1}=r,l=Et(e),d=o||s?[...l?fe(l):[],...fe(t)]:[];d.forEach(y=>{o&&y.addEventListener("scroll",n,{passive:!0}),s&&y.addEventListener("resize",n)});const m=l&&c?Or(l,n):null;let h=-1,u=null;i&&(u=new ResizeObserver(y=>{let[R]=y;R&&R.target===l&&u&&(u.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var b;(b=u)==null||b.observe(t)})),n()}),l&&!a&&u.observe(l),u.observe(t));let g,p=a?ve(e):null;a&&w();function w(){const y=ve(e);p&&(y.x!==p.x||y.y!==p.y||y.width!==p.width||y.height!==p.height)&&n(),p=y,g=requestAnimationFrame(w)}return n(),()=>{var y;d.forEach(R=>{o&&R.removeEventListener("scroll",n),s&&R.removeEventListener("resize",n)}),m?.(),(y=u)==null||y.disconnect(),u=null,a&&cancelAnimationFrame(g)}}const Pr=ar,Ir=fr,Mr=cr,Lr=mr,Dr=lr,Dt=sr,Fr=dr,kr=(e,t,n)=>{const r=new Map,o={platform:Sr,...n},s={...o.platform,_c:r};return ir(e,t,{...o,platform:s})};var We=typeof document<"u"?f.useLayoutEffect:f.useEffect;function Ye(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Ye(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!Ye(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function mn(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ft(e,t){const n=mn(e);return Math.round(t*n)/n}function st(e){const t=f.useRef(e);return We(()=>{t.current=e}),t}function Nr(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:i}={},transform:c=!0,whileElementsMounted:a,open:l}=e,[d,m]=f.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,u]=f.useState(r);Ye(h,r)||u(r);const[g,p]=f.useState(null),[w,y]=f.useState(null),R=f.useCallback(T=>{T!==I.current&&(I.current=T,p(T))},[]),b=f.useCallback(T=>{T!==L.current&&(L.current=T,y(T))},[]),x=s||g,S=i||w,I=f.useRef(null),L=f.useRef(null),D=f.useRef(d),B=a!=null,_=st(a),$=st(o),A=st(l),H=f.useCallback(()=>{if(!I.current||!L.current)return;const T={placement:t,strategy:n,middleware:h};$.current&&(T.platform=$.current),kr(I.current,L.current,T).then(v=>{const F={...v,isPositioned:A.current!==!1};V.current&&!Ye(D.current,F)&&(D.current=F,Ut.flushSync(()=>{m(F)}))})},[h,t,n,$,A]);We(()=>{l===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,m(T=>({...T,isPositioned:!1})))},[l]);const V=f.useRef(!1);We(()=>(V.current=!0,()=>{V.current=!1}),[]),We(()=>{if(x&&(I.current=x),S&&(L.current=S),x&&S){if(_.current)return _.current(x,S,H);H()}},[x,S,H,_,B]);const O=f.useMemo(()=>({reference:I,floating:L,setReference:R,setFloating:b}),[R,b]),E=f.useMemo(()=>({reference:x,floating:S}),[x,S]),C=f.useMemo(()=>{const T={position:n,left:0,top:0};if(!E.floating)return T;const v=Ft(E.floating,d.x),F=Ft(E.floating,d.y);return c?{...T,transform:"translate("+v+"px, "+F+"px)",...mn(E.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:v,top:F}},[n,c,E.floating,d.x,d.y]);return f.useMemo(()=>({...d,update:H,refs:O,elements:E,floatingStyles:C}),[d,H,O,E,C])}const $r=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Dt({element:r.current,padding:o}).fn(n):{}:r?Dt({element:r,padding:o}).fn(n):{}}}},uo=(e,t)=>({...Pr(e),options:[e,t]}),ao=(e,t)=>({...Ir(e),options:[e,t]}),fo=(e,t)=>({...Fr(e),options:[e,t]}),mo=(e,t)=>({...Mr(e),options:[e,t]}),go=(e,t)=>({...Lr(e),options:[e,t]}),po=(e,t)=>({...Dr(e),options:[e,t]}),ho=(e,t)=>({...$r(e),options:[e,t]});function vo(e){return f.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})},e)}const gn={...Rn},Wr=gn.useInsertionEffect,Br=Wr||(e=>e());function ne(e){const t=f.useRef(()=>{});return Br(()=>{t.current=e}),f.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;oe?.focus({preventScroll:n});o?s():kt=requestAnimationFrame(s)}var Y=typeof document<"u"?f.useLayoutEffect:f.useEffect;function Ie(){return Ie=Object.assign?Object.assign.bind():function(e){for(var t=1;t"floating-ui-"+Math.random().toString(36).slice(2,6)+_r++;function Vr(){const[e,t]=f.useState(()=>Nt?$t():void 0);return Y(()=>{e==null&&t($t())},[]),f.useEffect(()=>{Nt=!0},[]),e}const Hr=gn.useId,Qe=Hr||Vr,bo=f.forwardRef(function(t,n){const{context:{placement:r,elements:{floating:o},middlewareData:{arrow:s,shift:i}},width:c=14,height:a=7,tipRadius:l=0,strokeWidth:d=0,staticOffset:m,stroke:h,d:u,style:{transform:g,...p}={},...w}=t,y=Qe(),[R,b]=f.useState(!1);if(Y(()=>{if(!o)return;ee(o).direction==="rtl"&&b(!0)},[o]),!o)return null;const[x,S]=r.split("-"),I=x==="top"||x==="bottom";let L=m;(I&&i!=null&&i.x||!I&&i!=null&&i.y)&&(L=null);const D=d*2,B=D/2,_=c/2*(l/-8+1),$=a/2*l/4,A=!!u,H=L&&S==="end"?"bottom":"top";let V=L&&S==="end"?"right":"left";L&&R&&(V=S==="end"?"left":"right");const O=s?.x!=null?L||s.x:"",E=s?.y!=null?L||s.y:"",C=u||"M0,0"+(" H"+c)+(" L"+(c-_)+","+(a-$))+(" Q"+c/2+","+a+" "+_+","+(a-$))+" Z",T={top:A?"rotate(180deg)":"",left:A?"rotate(90deg)":"rotate(-90deg)",bottom:A?"":"rotate(180deg)",right:A?"rotate(-90deg)":"rotate(90deg)"}[x];return f.createElement("svg",Ie({},w,{"aria-hidden":!0,ref:n,width:A?c:c+D,height:c,viewBox:"0 0 "+c+" "+(a>c?a:c),style:{position:"absolute",pointerEvents:"none",[V]:O,[H]:E,[x]:I||A?"100%":"calc(100% - "+D/2+"px)",transform:[T,g].filter(v=>!!v).join(" "),...p}}),D>0&&f.createElement("path",{clipPath:"url(#"+y+")",fill:"none",stroke:h,strokeWidth:D+(u?0:1),d:C}),f.createElement("path",{stroke:D&&!u?w.fill:"none",d:C}),f.createElement("clipPath",{id:y},f.createElement("rect",{x:-B,y:B*(A?-1:1),width:c+D,height:c})))});function Kr(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(o=>o(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,((r=e.get(t))==null?void 0:r.filter(o=>o!==n))||[])}}}const jr=f.createContext(null),qr=f.createContext(null),Tt=()=>{var e;return((e=f.useContext(jr))==null?void 0:e.id)||null},et=()=>f.useContext(qr);function be(e){return"data-floating-ui-"+e}function Ce(e){const t=f.useRef(e);return Y(()=>{t.current=e}),t}const Wt=be("safe-polygon");function Be(e,t,n){return n&&!mt(n)?0:typeof e=="number"?e:e?.[t]}function yo(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,dataRef:o,events:s,elements:i}=e,{enabled:c=!0,delay:a=0,handleClose:l=null,mouseOnly:d=!1,restMs:m=0,move:h=!0}=t,u=et(),g=Tt(),p=Ce(l),w=Ce(a),y=Ce(n),R=f.useRef(),b=f.useRef(-1),x=f.useRef(),S=f.useRef(-1),I=f.useRef(!0),L=f.useRef(!1),D=f.useRef(()=>{}),B=f.useRef(!1),_=f.useCallback(()=>{var E;const C=(E=o.current.openEvent)==null?void 0:E.type;return C?.includes("mouse")&&C!=="mousedown"},[o]);f.useEffect(()=>{if(!c)return;function E(C){let{open:T}=C;T||(clearTimeout(b.current),clearTimeout(S.current),I.current=!0,B.current=!1)}return s.on("openchange",E),()=>{s.off("openchange",E)}},[c,s]),f.useEffect(()=>{if(!c||!p.current||!n)return;function E(T){_()&&r(!1,T,"hover")}const C=Z(i.floating).documentElement;return C.addEventListener("mouseleave",E),()=>{C.removeEventListener("mouseleave",E)}},[i.floating,n,r,c,p,_]);const $=f.useCallback(function(E,C,T){C===void 0&&(C=!0),T===void 0&&(T="hover");const v=Be(w.current,"close",R.current);v&&!x.current?(clearTimeout(b.current),b.current=window.setTimeout(()=>r(!1,E,T),v)):C&&(clearTimeout(b.current),r(!1,E,T))},[w,r]),A=ne(()=>{D.current(),x.current=void 0}),H=ne(()=>{if(L.current){const E=Z(i.floating).body;E.style.pointerEvents="",E.removeAttribute(Wt),L.current=!1}});f.useEffect(()=>{if(!c)return;function E(){return o.current.openEvent?["click","mousedown"].includes(o.current.openEvent.type):!1}function C(M){if(clearTimeout(b.current),I.current=!1,d&&!mt(R.current)||m>0&&!Be(w.current,"open"))return;const q=Be(w.current,"open",R.current);q?b.current=window.setTimeout(()=>{y.current||r(!0,M,"hover")},q):r(!0,M,"hover")}function T(M){if(E())return;D.current();const q=Z(i.floating);if(clearTimeout(S.current),B.current=!1,p.current&&o.current.floatingContext){n||clearTimeout(b.current),x.current=p.current({...o.current.floatingContext,tree:u,x:M.clientX,y:M.clientY,onClose(){H(),A(),$(M,!0,"safe-polygon")}});const k=x.current;q.addEventListener("mousemove",k),D.current=()=>{q.removeEventListener("mousemove",k)};return}(R.current==="touch"?!G(i.floating,M.relatedTarget):!0)&&$(M)}function v(M){E()||o.current.floatingContext&&(p.current==null||p.current({...o.current.floatingContext,tree:u,x:M.clientX,y:M.clientY,onClose(){H(),A(),$(M)}})(M))}if(j(i.domReference)){var F;const M=i.domReference;return n&&M.addEventListener("mouseleave",v),(F=i.floating)==null||F.addEventListener("mouseleave",v),h&&M.addEventListener("mousemove",C,{once:!0}),M.addEventListener("mouseenter",C),M.addEventListener("mouseleave",T),()=>{var q;n&&M.removeEventListener("mouseleave",v),(q=i.floating)==null||q.removeEventListener("mouseleave",v),h&&M.removeEventListener("mousemove",C),M.removeEventListener("mouseenter",C),M.removeEventListener("mouseleave",T)}}},[i,c,e,d,m,h,$,A,H,r,n,y,u,w,p,o]),Y(()=>{var E;if(c&&n&&(E=p.current)!=null&&E.__options.blockPointerEvents&&_()){L.current=!0;const T=i.floating;if(j(i.domReference)&&T){var C;const v=Z(i.floating).body;v.setAttribute(Wt,"");const F=i.domReference,M=u==null||(C=u.nodesRef.current.find(q=>q.id===g))==null||(C=C.context)==null?void 0:C.elements.floating;return M&&(M.style.pointerEvents=""),v.style.pointerEvents="none",F.style.pointerEvents="auto",T.style.pointerEvents="auto",()=>{v.style.pointerEvents="",F.style.pointerEvents="",T.style.pointerEvents=""}}}},[c,n,g,i,u,p,_]),Y(()=>{n||(R.current=void 0,B.current=!1,A(),H())},[n,A,H]),f.useEffect(()=>()=>{A(),clearTimeout(b.current),clearTimeout(S.current),H()},[c,i.domReference,A,H]);const V=f.useMemo(()=>{function E(C){R.current=C.pointerType}return{onPointerDown:E,onPointerEnter:E,onMouseMove(C){const{nativeEvent:T}=C;function v(){!I.current&&!y.current&&r(!0,T,"hover")}d&&!mt(R.current)||n||m===0||B.current&&C.movementX**2+C.movementY**2<2||(clearTimeout(S.current),R.current==="touch"?v():(B.current=!0,S.current=window.setTimeout(v,m)))}}},[d,r,n,y,m]),O=f.useMemo(()=>({onMouseEnter(){clearTimeout(b.current)},onMouseLeave(E){$(E.nativeEvent,!1)}}),[$]);return f.useMemo(()=>c?{reference:V,floating:O}:{},[c,V,O])}const vt=()=>{},pn=f.createContext({delay:0,initialDelay:0,timeoutMs:0,currentId:null,setCurrentId:vt,setState:vt,isInstantPhase:!1}),Yr=()=>f.useContext(pn);function wo(e){const{children:t,delay:n,timeoutMs:r=0}=e,[o,s]=f.useReducer((a,l)=>({...a,...l}),{delay:n,timeoutMs:r,initialDelay:n,currentId:null,isInstantPhase:!1}),i=f.useRef(null),c=f.useCallback(a=>{s({currentId:a})},[]);return Y(()=>{o.currentId?i.current===null?i.current=o.currentId:o.isInstantPhase||s({isInstantPhase:!0}):(o.isInstantPhase&&s({isInstantPhase:!1}),i.current=null)},[o.currentId,o.isInstantPhase]),f.createElement(pn.Provider,{value:f.useMemo(()=>({...o,setState:s,setCurrentId:c}),[o,c])},t)}function xo(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,floatingId:o}=e,{id:s,enabled:i=!0}=t,c=s??o,a=Yr(),{currentId:l,setCurrentId:d,initialDelay:m,setState:h,timeoutMs:u}=a;return Y(()=>{i&&l&&(h({delay:{open:1,close:Be(m,"close")}}),l!==c&&r(!1))},[i,c,r,h,l,m]),Y(()=>{function g(){r(!1),h({delay:m,currentId:null})}if(i&&l&&!n&&l===c){if(u){const p=window.setTimeout(g,u);return()=>{clearTimeout(p)}}g()}},[i,n,h,l,c,r,m,u]),Y(()=>{i&&(d===vt||!n||d(c))},[i,n,d,c]),a}function zr(e,t){var n;let r=[],o=(n=e.find(s=>s.id===t))==null?void 0:n.parentId;for(;o;){const s=e.find(i=>i.id===o);o=s?.parentId,s&&(r=r.concat(s))}return r}function Se(e,t){let n=e.filter(o=>{var s;return o.parentId===t&&((s=o.context)==null?void 0:s.open)}),r=n;for(;r.length;)r=e.filter(o=>{var s;return(s=r)==null?void 0:s.some(i=>{var c;return o.parentId===i.id&&((c=o.context)==null?void 0:c.open)})}),n=n.concat(r);return n}let Re=new WeakMap,Ne=new WeakSet,$e={},ct=0;const Ur=()=>typeof HTMLElement<"u"&&"inert"in HTMLElement.prototype,hn=e=>e&&(e.host||hn(e.parentNode)),Xr=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=hn(n);return e.contains(r)?r:null}).filter(n=>n!=null);function Gr(e,t,n,r){const o="data-floating-ui-inert",s=r?"inert":n?"aria-hidden":null,i=Xr(t,e),c=new Set,a=new Set(i),l=[];$e[o]||($e[o]=new WeakMap);const d=$e[o];i.forEach(m),h(t),c.clear();function m(u){!u||c.has(u)||(c.add(u),u.parentNode&&m(u.parentNode))}function h(u){!u||a.has(u)||[].forEach.call(u.children,g=>{if(pe(g)!=="script")if(c.has(g))h(g);else{const p=s?g.getAttribute(s):null,w=p!==null&&p!=="false",y=(Re.get(g)||0)+1,R=(d.get(g)||0)+1;Re.set(g,y),d.set(g,R),l.push(g),y===1&&w&&Ne.add(g),R===1&&g.setAttribute(o,""),!w&&s&&g.setAttribute(s,"true")}})}return ct++,()=>{l.forEach(u=>{const g=(Re.get(u)||0)-1,p=(d.get(u)||0)-1;Re.set(u,g),d.set(u,p),g||(!Ne.has(u)&&s&&u.removeAttribute(s),Ne.delete(u)),p||u.removeAttribute(o)}),ct--,ct||(Re=new WeakMap,Re=new WeakMap,Ne=new WeakSet,$e={})}}function Bt(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);const r=Z(e[0]).body;return Gr(e.concat(Array.from(r.querySelectorAll("[aria-live]"))),r,t,n)}const Me=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function vn(e,t){const n=Je(e,Me());t==="prev"&&n.reverse();const r=n.indexOf(ie(Z(e)));return n.slice(r+1)[0]}function bn(){return vn(document.body,"next")}function yn(){return vn(document.body,"prev")}function Oe(e,t){const n=t||e.currentTarget,r=e.relatedTarget;return!r||!G(n,r)}function Zr(e){Je(e,Me()).forEach(n=>{n.dataset.tabindex=n.getAttribute("tabindex")||"",n.setAttribute("tabindex","-1")})}function _t(e){e.querySelectorAll("[data-tabindex]").forEach(n=>{const r=n.dataset.tabindex;delete n.dataset.tabindex,r?n.setAttribute("tabindex",r):n.removeAttribute("tabindex")})}const tt={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0};let Jr;function Vt(e){e.key==="Tab"&&(e.target,clearTimeout(Jr))}const ze=f.forwardRef(function(t,n){const[r,o]=f.useState();Y(()=>(en()&&o("button"),document.addEventListener("keydown",Vt),()=>{document.removeEventListener("keydown",Vt)}),[]);const s={ref:n,tabIndex:0,role:r,"aria-hidden":r?void 0:!0,[be("focus-guard")]:"",style:tt};return f.createElement("span",Ie({},t,s))}),wn=f.createContext(null),Ht=be("portal");function Qr(e){e===void 0&&(e={});const{id:t,root:n}=e,r=Qe(),o=xn(),[s,i]=f.useState(null),c=f.useRef(null);return Y(()=>()=>{s?.remove(),queueMicrotask(()=>{c.current=null})},[s]),Y(()=>{if(!r||c.current)return;const a=t?document.getElementById(t):null;if(!a)return;const l=document.createElement("div");l.id=r,l.setAttribute(Ht,""),a.appendChild(l),c.current=l,i(l)},[t,r]),Y(()=>{if(!r||c.current)return;let a=n||o?.portalNode;a&&!j(a)&&(a=a.current),a=a||document.body;let l=null;t&&(l=document.createElement("div"),l.id=t,a.appendChild(l));const d=document.createElement("div");d.id=r,d.setAttribute(Ht,""),a=l||a,a.appendChild(d),c.current=d,i(d)},[t,n,r,o]),s}function Ro(e){const{children:t,id:n,root:r=null,preserveTabOrder:o=!0}=e,s=Qr({id:n,root:r}),[i,c]=f.useState(null),a=f.useRef(null),l=f.useRef(null),d=f.useRef(null),m=f.useRef(null),h=i?.modal,u=i?.open,g=!!i&&!i.modal&&i.open&&o&&!!(r||s);return f.useEffect(()=>{if(!s||!o||h)return;function p(w){s&&Oe(w)&&(w.type==="focusin"?_t:Zr)(s)}return s.addEventListener("focusin",p,!0),s.addEventListener("focusout",p,!0),()=>{s.removeEventListener("focusin",p,!0),s.removeEventListener("focusout",p,!0)}},[s,o,h]),f.useEffect(()=>{s&&(u||_t(s))},[u,s]),f.createElement(wn.Provider,{value:f.useMemo(()=>({preserveTabOrder:o,beforeOutsideRef:a,afterOutsideRef:l,beforeInsideRef:d,afterInsideRef:m,portalNode:s,setFocusManagerState:c}),[o,s])},g&&s&&f.createElement(ze,{"data-type":"outside",ref:a,onFocus:p=>{if(Oe(p,s)){var w;(w=d.current)==null||w.focus()}else{const y=yn()||i?.refs.domReference.current;y?.focus()}}}),g&&s&&f.createElement("span",{"aria-owns":s.id,style:tt}),s&&Ut.createPortal(t,s),g&&s&&f.createElement(ze,{"data-type":"outside",ref:l,onFocus:p=>{if(Oe(p,s)){var w;(w=m.current)==null||w.focus()}else{const y=bn()||i?.refs.domReference.current;y?.focus(),i?.closeOnFocusOut&&i?.onOpenChange(!1,p.nativeEvent,"focus-out")}}}))}const xn=()=>f.useContext(wn),bt="data-floating-ui-focusable";function eo(e){return e?e.hasAttribute(bt)?e:e.querySelector("["+bt+"]")||e:null}const Kt=20;let he=[];function lt(e){he=he.filter(n=>n.isConnected);let t=e;if(!(!t||pe(t)==="body")){if(!or(t,Me())){const n=Je(t,Me())[0];n&&(t=n)}he.push(t),he.length>Kt&&(he=he.slice(-Kt))}}function jt(){return he.slice().reverse().find(e=>e.isConnected)}const to=f.forwardRef(function(t,n){return f.createElement("button",Ie({},t,{type:"button",ref:n,tabIndex:-1,style:tt}))});function Eo(e){const{context:t,children:n,disabled:r=!1,order:o=["content"],guards:s=!0,initialFocus:i=0,returnFocus:c=!0,restoreFocus:a=!1,modal:l=!0,visuallyHiddenDismiss:d=!1,closeOnFocusOut:m=!0}=e,{open:h,refs:u,nodeId:g,onOpenChange:p,events:w,dataRef:y,floatingId:R,elements:{domReference:b,floating:x}}=t,S=typeof i=="number"&&i<0,I=Mn(b)&&S,L=Ur()?s:!0,D=Ce(o),B=Ce(i),_=Ce(c),$=et(),A=xn(),H=f.useRef(null),V=f.useRef(null),O=f.useRef(!1),E=f.useRef(!1),C=f.useRef(-1),T=A!=null,v=eo(x),F=ne(function(k){return k===void 0&&(k=v),k?Je(k,Me()):[]}),M=ne(k=>{const W=F(k);return D.current.map(P=>b&&P==="reference"?b:v&&P==="floating"?v:W).filter(Boolean).flat()});f.useEffect(()=>{O.current=!1},[r]),f.useEffect(()=>{if(r||!l)return;function k(P){if(P.key==="Tab"){G(v,ie(Z(v)))&&F().length===0&&!I&&ot(P);const N=M(),K=ae(P);D.current[0]==="reference"&&K===b&&(ot(P),P.shiftKey?xe(N[N.length-1]):xe(N[1])),D.current[1]==="floating"&&K===v&&P.shiftKey&&(ot(P),xe(N[0]))}}const W=Z(v);return W.addEventListener("keydown",k),()=>{W.removeEventListener("keydown",k)}},[r,b,v,l,D,I,F,M]),f.useEffect(()=>{if(r||!x)return;function k(W){const P=ae(W),K=F().indexOf(P);K!==-1&&(C.current=K)}return x.addEventListener("focusin",k),()=>{x.removeEventListener("focusin",k)}},[r,x,F]),f.useEffect(()=>{if(r||!m)return;function k(){E.current=!0,setTimeout(()=>{E.current=!1})}function W(P){const N=P.relatedTarget;queueMicrotask(()=>{const K=!(G(b,N)||G(x,N)||G(N,x)||G(A?.portalNode,N)||N!=null&&N.hasAttribute(be("focus-guard"))||$&&(Se($.nodesRef.current,g).find(X=>{var U,te;return G((U=X.context)==null?void 0:U.elements.floating,N)||G((te=X.context)==null?void 0:te.elements.domReference,N)})||zr($.nodesRef.current,g).find(X=>{var U,te;return((U=X.context)==null?void 0:U.elements.floating)===N||((te=X.context)==null?void 0:te.elements.domReference)===N})));if(a&&K&&ie(Z(v))===Z(v).body){z(v)&&v.focus();const X=C.current,U=F(),te=U[X]||U[U.length-1]||v;z(te)&&te.focus()}(I||!l)&&N&&K&&!E.current&&N!==jt()&&(O.current=!0,p(!1,P,"focus-out"))})}if(x&&z(b))return b.addEventListener("focusout",W),b.addEventListener("pointerdown",k),x.addEventListener("focusout",W),()=>{b.removeEventListener("focusout",W),b.removeEventListener("pointerdown",k),x.removeEventListener("focusout",W)}},[r,b,x,v,l,g,$,A,p,m,a,F,I]),f.useEffect(()=>{var k;if(r)return;const W=Array.from((A==null||(k=A.portalNode)==null?void 0:k.querySelectorAll("["+be("portal")+"]"))||[]);if(x){const P=[x,...W,H.current,V.current,D.current.includes("reference")||I?b:null].filter(K=>K!=null),N=l||I?Bt(P,L,!L):Bt(P);return()=>{N()}}},[r,b,x,l,D,A,I,L]),Y(()=>{if(r||!z(v))return;const k=Z(v),W=ie(k);queueMicrotask(()=>{const P=M(v),N=B.current,K=(typeof N=="number"?P[N]:N.current)||v,X=G(v,W);!S&&!X&&h&&xe(K,{preventScroll:K===v})})},[r,h,v,S,M,B]),Y(()=>{if(r||!v)return;let k=!1;const W=Z(v),P=ie(W);let K=y.current.openEvent;lt(P);function X(we){let{open:De,reason:Fe,event:ue,nested:nt}=we;De&&(K=ue),Fe==="escape-key"&&u.domReference.current&<(u.domReference.current),Fe==="hover"&&ue.type==="mouseleave"&&(O.current=!0),Fe==="outside-press"&&(nt?(O.current=!1,k=!0):O.current=!(Tn(ue)||Qt(ue)))}w.on("openchange",X);const U=W.createElement("span");U.setAttribute("tabindex","-1"),U.setAttribute("aria-hidden","true"),Object.assign(U.style,tt),T&&b&&b.insertAdjacentElement("afterend",U);function te(){return typeof _.current=="boolean"?jt()||U:_.current.current||U}return()=>{w.off("openchange",X);const we=ie(W),De=G(x,we)||$&&Se($.nodesRef.current,g).some(nt=>{var At;return G((At=nt.context)==null?void 0:At.elements.floating,we)});(De||K&&["click","mousedown"].includes(K.type))&&u.domReference.current&<(u.domReference.current);const ue=te();queueMicrotask(()=>{_.current&&!O.current&&z(ue)&&(!(ue!==we&&we!==W.body)||De)&&ue.focus({preventScroll:k}),U.remove()})}},[r,x,v,_,y,u,w,$,g,T,b]),Y(()=>{if(!r&&A)return A.setFocusManagerState({modal:l,closeOnFocusOut:m,open:h,onOpenChange:p,refs:u}),()=>{A.setFocusManagerState(null)}},[r,A,l,h,p,u,m]),Y(()=>{if(r||!v||typeof MutationObserver!="function"||S)return;const k=()=>{const P=v.getAttribute("tabindex"),N=F(),K=ie(Z(x)),X=N.indexOf(K);X!==-1&&(C.current=X),D.current.includes("floating")||K!==u.domReference.current&&N.length===0?P!=="0"&&v.setAttribute("tabindex","0"):P!=="-1"&&v.setAttribute("tabindex","-1")};k();const W=new MutationObserver(k);return W.observe(v,{childList:!0,subtree:!0,attributes:!0}),()=>{W.disconnect()}},[r,x,v,u,D,F,S]);function q(k){return r||!d||!l?null:f.createElement(to,{ref:k==="start"?H:V,onClick:W=>p(!1,W.nativeEvent)},typeof d=="string"?d:"Dismiss")}const ye=!r&&L&&(l?!I:!0)&&(T||l);return f.createElement(f.Fragment,null,ye&&f.createElement(ze,{"data-type":"inside",ref:A?.beforeInsideRef,onFocus:k=>{if(l){const P=M();xe(o[0]==="reference"?P[0]:P[P.length-1])}else if(A!=null&&A.preserveTabOrder&&A.portalNode)if(O.current=!1,Oe(k,A.portalNode)){const P=bn()||b;P?.focus()}else{var W;(W=A.beforeOutsideRef.current)==null||W.focus()}}}),!I&&q("start"),n,q("end"),ye&&f.createElement(ze,{"data-type":"inside",ref:A?.afterInsideRef,onFocus:k=>{if(l)xe(M()[0]);else if(A!=null&&A.preserveTabOrder&&A.portalNode)if(m&&(O.current=!0),Oe(k,A.portalNode)){const P=yn()||b;P?.focus()}else{var W;(W=A.afterOutsideRef.current)==null||W.focus()}}}))}const no={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},ro={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},qt=e=>{var t,n;return{escapeKey:typeof e=="boolean"?e:(t=e?.escapeKey)!=null?t:!1,outsidePress:typeof e=="boolean"?e:(n=e?.outsidePress)!=null?n:!0}};function Co(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,elements:o,dataRef:s}=e,{enabled:i=!0,escapeKey:c=!0,outsidePress:a=!0,outsidePressEvent:l="pointerdown",referencePress:d=!1,referencePressEvent:m="pointerdown",ancestorScroll:h=!1,bubbles:u,capture:g}=t,p=et(),w=ne(typeof a=="function"?a:()=>!1),y=typeof a=="function"?w:a,R=f.useRef(!1),b=f.useRef(!1),{escapeKey:x,outsidePress:S}=qt(u),{escapeKey:I,outsidePress:L}=qt(g),D=f.useRef(!1),B=ne(O=>{var E;if(!n||!i||!c||O.key!=="Escape"||D.current)return;const C=(E=s.current.floatingContext)==null?void 0:E.nodeId,T=p?Se(p.nodesRef.current,C):[];if(!x&&(O.stopPropagation(),T.length>0)){let v=!0;if(T.forEach(F=>{var M;if((M=F.context)!=null&&M.open&&!F.context.dataRef.current.__escapeKeyBubbles){v=!1;return}}),!v)return}r(!1,On(O)?O.nativeEvent:O,"escape-key")}),_=ne(O=>{var E;const C=()=>{var T;B(O),(T=ae(O))==null||T.removeEventListener("keydown",C)};(E=ae(O))==null||E.addEventListener("keydown",C)}),$=ne(O=>{var E;const C=R.current;R.current=!1;const T=b.current;if(b.current=!1,l==="click"&&T||C||typeof y=="function"&&!y(O))return;const v=ae(O),F="["+be("inert")+"]",M=Z(o.floating).querySelectorAll(F);let q=j(v)?v:null;for(;q&&!de(q);){const P=se(q);if(de(P)||!j(P))break;q=P}if(M.length&&j(v)&&!Pn(v)&&!G(v,o.floating)&&Array.from(M).every(P=>!G(q,P)))return;if(z(v)&&V){const P=v.clientWidth>0&&v.scrollWidth>v.clientWidth,N=v.clientHeight>0&&v.scrollHeight>v.clientHeight;let K=N&&O.offsetX>v.clientWidth;if(N&&ee(v).direction==="rtl"&&(K=O.offsetX<=v.offsetWidth-v.clientWidth),K||P&&O.offsetY>v.clientHeight)return}const ye=(E=s.current.floatingContext)==null?void 0:E.nodeId,k=p&&Se(p.nodesRef.current,ye).some(P=>{var N;return rt(O,(N=P.context)==null?void 0:N.elements.floating)});if(rt(O,o.floating)||rt(O,o.domReference)||k)return;const W=p?Se(p.nodesRef.current,ye):[];if(W.length>0){let P=!0;if(W.forEach(N=>{var K;if((K=N.context)!=null&&K.open&&!N.context.dataRef.current.__outsidePressBubbles){P=!1;return}}),!P)return}r(!1,O,"outside-press")}),A=ne(O=>{var E;const C=()=>{var T;$(O),(T=ae(O))==null||T.removeEventListener(l,C)};(E=ae(O))==null||E.addEventListener(l,C)});f.useEffect(()=>{if(!n||!i)return;s.current.__escapeKeyBubbles=x,s.current.__outsidePressBubbles=S;let O=-1;function E(M){r(!1,M,"ancestor-scroll")}function C(){window.clearTimeout(O),D.current=!0}function T(){O=window.setTimeout(()=>{D.current=!1},Ge()?5:0)}const v=Z(o.floating);c&&(v.addEventListener("keydown",I?_:B,I),v.addEventListener("compositionstart",C),v.addEventListener("compositionend",T)),y&&v.addEventListener(l,L?A:$,L);let F=[];return h&&(j(o.domReference)&&(F=fe(o.domReference)),j(o.floating)&&(F=F.concat(fe(o.floating))),!j(o.reference)&&o.reference&&o.reference.contextElement&&(F=F.concat(fe(o.reference.contextElement)))),F=F.filter(M=>{var q;return M!==((q=v.defaultView)==null?void 0:q.visualViewport)}),F.forEach(M=>{M.addEventListener("scroll",E,{passive:!0})}),()=>{c&&(v.removeEventListener("keydown",I?_:B,I),v.removeEventListener("compositionstart",C),v.removeEventListener("compositionend",T)),y&&v.removeEventListener(l,L?A:$,L),F.forEach(M=>{M.removeEventListener("scroll",E)}),window.clearTimeout(O)}},[s,o,c,y,l,n,r,h,i,x,S,B,I,_,$,L,A]),f.useEffect(()=>{R.current=!1},[y,l]);const H=f.useMemo(()=>({onKeyDown:B,[no[m]]:O=>{d&&r(!1,O.nativeEvent,"reference-press")}}),[B,r,d,m]),V=f.useMemo(()=>({onKeyDown:B,onMouseDown(){b.current=!0},onMouseUp(){b.current=!0},[ro[l]]:()=>{R.current=!0}}),[B,l]);return f.useMemo(()=>i?{reference:H,floating:V}:{},[i,H,V])}function oo(e){const{open:t=!1,onOpenChange:n,elements:r}=e,o=Qe(),s=f.useRef({}),[i]=f.useState(()=>Kr()),c=Tt()!=null,[a,l]=f.useState(r.reference),d=ne((u,g,p)=>{s.current.openEvent=u?g:void 0,i.emit("openchange",{open:u,event:g,reason:p,nested:c}),n?.(u,g,p)}),m=f.useMemo(()=>({setPositionReference:l}),[]),h=f.useMemo(()=>({reference:a||r.reference||null,floating:r.floating||null,domReference:r.reference}),[a,r.reference,r.floating]);return f.useMemo(()=>({dataRef:s,open:t,onOpenChange:d,elements:h,events:i,floatingId:o,refs:m}),[t,d,h,i,o,m])}function To(e){e===void 0&&(e={});const{nodeId:t}=e,n=oo({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,o=r.elements,[s,i]=f.useState(null),[c,a]=f.useState(null),d=o?.domReference||s,m=f.useRef(null),h=et();Y(()=>{d&&(m.current=d)},[d]);const u=Nr({...e,elements:{...o,...c&&{reference:c}}}),g=f.useCallback(b=>{const x=j(b)?{getBoundingClientRect:()=>b.getBoundingClientRect(),contextElement:b}:b;a(x),u.refs.setReference(x)},[u.refs]),p=f.useCallback(b=>{(j(b)||b===null)&&(m.current=b,i(b)),(j(u.refs.reference.current)||u.refs.reference.current===null||b!==null&&!j(b))&&u.refs.setReference(b)},[u.refs]),w=f.useMemo(()=>({...u.refs,setReference:p,setPositionReference:g,domReference:m}),[u.refs,p,g]),y=f.useMemo(()=>({...u.elements,domReference:d}),[u.elements,d]),R=f.useMemo(()=>({...u,...r,refs:w,elements:y,nodeId:t}),[u,w,y,t,r]);return Y(()=>{r.dataRef.current.floatingContext=R;const b=h?.nodesRef.current.find(x=>x.id===t);b&&(b.context=R)}),f.useMemo(()=>({...u,context:R,refs:w,elements:y}),[u,w,y,R])}function Ao(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,events:o,dataRef:s,elements:i}=e,{enabled:c=!0,visibleOnly:a=!0}=t,l=f.useRef(!1),d=f.useRef(),m=f.useRef(!0);f.useEffect(()=>{if(!c)return;const u=J(i.domReference);function g(){!n&&z(i.domReference)&&i.domReference===ie(Z(i.domReference))&&(l.current=!0)}function p(){m.current=!0}return u.addEventListener("blur",g),u.addEventListener("keydown",p,!0),()=>{u.removeEventListener("blur",g),u.removeEventListener("keydown",p,!0)}},[i.domReference,n,c]),f.useEffect(()=>{if(!c)return;function u(g){let{reason:p}=g;(p==="reference-press"||p==="escape-key")&&(l.current=!0)}return o.on("openchange",u),()=>{o.off("openchange",u)}},[o,c]),f.useEffect(()=>()=>{clearTimeout(d.current)},[]);const h=f.useMemo(()=>({onPointerDown(u){Qt(u.nativeEvent)||(m.current=!1)},onMouseLeave(){l.current=!1},onFocus(u){if(l.current)return;const g=ae(u.nativeEvent);if(a&&j(g))try{if(en()&&An())throw Error();if(!g.matches(":focus-visible"))return}catch{if(!m.current&&!tn(g))return}r(!0,u.nativeEvent,"focus")},onBlur(u){l.current=!1;const g=u.relatedTarget,p=u.nativeEvent,w=j(g)&&g.hasAttribute(be("focus-guard"))&&g.getAttribute("data-type")==="outside";d.current=window.setTimeout(()=>{var y;const R=ie(i.domReference?i.domReference.ownerDocument:document);!g&&R===i.domReference||G((y=s.current.floatingContext)==null?void 0:y.refs.floating.current,R)||G(i.domReference,R)||w||r(!1,p,"focus")})}}),[s,i.domReference,r,a]);return f.useMemo(()=>c?{reference:h}:{},[c,h])}const Yt="active",zt="selected";function ut(e,t,n){const r=new Map,o=n==="item";let s=e;if(o&&e){const{[Yt]:i,[zt]:c,...a}=e;s=a}return{...n==="floating"&&{tabIndex:-1,[bt]:""},...s,...t.map(i=>{const c=i?i[n]:null;return typeof c=="function"?e?c(e):null:c}).concat(e).reduce((i,c)=>(c&&Object.entries(c).forEach(a=>{let[l,d]=a;if(!(o&&[Yt,zt].includes(l)))if(l.indexOf("on")===0){if(r.has(l)||r.set(l,[]),typeof d=="function"){var m;(m=r.get(l))==null||m.push(d),i[l]=function(){for(var h,u=arguments.length,g=new Array(u),p=0;pw(...g)).find(w=>w!==void 0)}}}else i[l]=d}),i),{})}}function So(e){e===void 0&&(e=[]);const t=e.map(c=>c?.reference),n=e.map(c=>c?.floating),r=e.map(c=>c?.item),o=f.useCallback(c=>ut(c,e,"reference"),t),s=f.useCallback(c=>ut(c,e,"floating"),n),i=f.useCallback(c=>ut(c,e,"item"),r);return f.useMemo(()=>({getReferenceProps:o,getFloatingProps:s,getItemProps:i}),[o,s,i])}const io=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function Oo(e,t){var n;t===void 0&&(t={});const{open:r,floatingId:o}=e,{enabled:s=!0,role:i="dialog"}=t,c=(n=io.get(i))!=null?n:i,a=Qe(),d=Tt()!=null,m=f.useMemo(()=>c==="tooltip"||i==="label"?{["aria-"+(i==="label"?"labelledby":"describedby")]:r?o:void 0}:{"aria-expanded":r?"true":"false","aria-haspopup":c==="alertdialog"?"dialog":c,"aria-controls":r?o:void 0,...c==="listbox"&&{role:"combobox"},...c==="menu"&&{id:a},...c==="menu"&&d&&{role:"menuitem"},...i==="select"&&{"aria-autocomplete":"none"},...i==="combobox"&&{"aria-autocomplete":"list"}},[c,o,d,r,a,i]),h=f.useMemo(()=>{const g={id:o,...c&&{role:c}};return c==="tooltip"||i==="label"?g:{...g,...c==="menu"&&{"aria-labelledby":a}}},[c,o,a,i]),u=f.useCallback(g=>{let{active:p,selected:w}=g;const y={role:"option",...p&&{id:o+"-option"}};switch(i){case"select":return{...y,"aria-selected":p&&w};case"combobox":return{...y,...p&&{"aria-selected":!0}}}return{}},[o,i]);return f.useMemo(()=>s?{reference:m,floating:h,item:u}:{},[s,m,h,u])}export{wo as F,vo as a,To as b,lo as c,ho as d,xo as e,mo as f,yo as g,Ao as h,Co as i,Oo as j,So as k,Ro as l,bo as m,fo as n,uo as o,Eo as p,Nr as q,go as r,ao as s,po as t,Qe as u}; +*/var _n=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],Ke=_n.join(","),rn=typeof Element>"u",Te=rn?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,je=!rn&&Element.prototype.getRootNode?function(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}:function(e){return e?.ownerDocument},qe=function e(t,n){var r;n===void 0&&(n=!0);var o=t==null||(r=t.getAttribute)===null||r===void 0?void 0:r.call(t,"inert"),s=o===""||o==="true",i=s||n&&t&&e(t.parentNode);return i},Vn=function(t){var n,r=t==null||(n=t.getAttribute)===null||n===void 0?void 0:n.call(t,"contenteditable");return r===""||r==="true"},Hn=function(t,n,r){if(qe(t))return[];var o=Array.prototype.slice.apply(t.querySelectorAll(Ke));return n&&Te.call(t,Ke)&&o.unshift(t),o=o.filter(r),o},Kn=function e(t,n,r){for(var o=[],s=Array.from(t);s.length;){var i=s.shift();if(!qe(i,!1))if(i.tagName==="SLOT"){var c=i.assignedElements(),a=c.length?c:i.children,l=e(a,!0,r);r.flatten?o.push.apply(o,l):o.push({scopeParent:i,candidates:l})}else{var d=Te.call(i,Ke);d&&r.filter(i)&&(n||!t.includes(i))&&o.push(i);var m=i.shadowRoot||typeof r.getShadowRoot=="function"&&r.getShadowRoot(i),h=!qe(m,!1)&&(!r.shadowRootFilter||r.shadowRootFilter(i));if(m&&h){var u=e(m===!0?i.children:m.children,!0,r);r.flatten?o.push.apply(o,u):o.push({scopeParent:i,candidates:u})}else s.unshift.apply(s,i.children)}}return o},on=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},sn=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||Vn(t))&&!on(t)?0:t.tabIndex},jn=function(t,n){var r=sn(t);return r<0&&n&&!on(t)?0:r},qn=function(t,n){return t.tabIndex===n.tabIndex?t.documentOrder-n.documentOrder:t.tabIndex-n.tabIndex},cn=function(t){return t.tagName==="INPUT"},Yn=function(t){return cn(t)&&t.type==="hidden"},zn=function(t){var n=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(r){return r.tagName==="SUMMARY"});return n},Un=function(t,n){for(var r=0;rsummary:first-of-type"),i=s?t.parentElement:t;if(Te.call(i,"details:not([open]) *"))return!0;if(!r||r==="full"||r==="legacy-full"){if(typeof o=="function"){for(var c=t;t;){var a=t.parentElement,l=je(t);if(a&&!a.shadowRoot&&o(a)===!0)return St(t);t.assignedSlot?t=t.assignedSlot:!a&&l!==t.ownerDocument?t=l.host:t=a}t=c}if(Jn(t))return!t.getClientRects().length;if(r!=="legacy-full")return!0}else if(r==="non-zero-area")return St(t);return!1},er=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var n=t.parentElement;n;){if(n.tagName==="FIELDSET"&&n.disabled){for(var r=0;r=0)},rr=function e(t){var n=[],r=[];return t.forEach(function(o,s){var i=!!o.scopeParent,c=i?o.scopeParent:o,a=jn(c,i),l=i?e(o.candidates):c;a===0?i?n.push.apply(n,l):n.push(c):r.push({documentOrder:s,tabIndex:a,item:o,isScope:i,content:l})}),r.sort(qn).reduce(function(o,s){return s.isScope?o.push.apply(o,s.content):o.push(s.content),o},[]).concat(n)},Je=function(t,n){n=n||{};var r;return n.getShadowRoot?r=Kn([t],n.includeContainer,{filter:ht.bind(null,n),flatten:!1,getShadowRoot:n.getShadowRoot,shadowRootFilter:nr}):r=Hn(t,n.includeContainer,ht.bind(null,n)),rr(r)},or=function(t,n){if(n=n||{},!t)throw new Error("No node provided");return Te.call(t,Ke)===!1?!1:ht(n,t)};function Ot(e,t,n){let{reference:r,floating:o}=e;const s=ge(t),i=Rt(t),c=xt(i),a=le(t),l=s==="y",d=r.x+r.width/2-o.width/2,m=r.y+r.height/2-o.height/2,h=r[c]/2-o[c]/2;let u;switch(a){case"top":u={x:d,y:r.y-o.height};break;case"bottom":u={x:d,y:r.y+r.height};break;case"right":u={x:r.x+r.width,y:m};break;case"left":u={x:r.x-o.width,y:m};break;default:u={x:r.x,y:r.y}}switch(Ae(t)){case"start":u[i]-=h*(n&&l?-1:1);break;case"end":u[i]+=h*(n&&l?-1:1);break}return u}const ir=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,c=s.filter(Boolean),a=await(i.isRTL==null?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:m}=Ot(l,r,a),h=r,u={},g=0;for(let p=0;p({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:c,middlewareData:a}=t,{element:l,padding:d=0}=ce(e,t)||{};if(l==null)return{};const m=nn(d),h={x:n,y:r},u=Rt(o),g=xt(u),p=await i.getDimensions(l),w=u==="y",y=w?"top":"left",R=w?"bottom":"right",b=w?"clientHeight":"clientWidth",x=s.reference[g]+s.reference[u]-h[u]-s.floating[g],S=h[u]-s.reference[u],I=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let L=I?I[b]:0;(!L||!await(i.isElement==null?void 0:i.isElement(I)))&&(L=c.floating[b]||s.floating[g]);const D=x/2-S/2,B=L/2-p[g]/2-1,_=me(m[y],B),$=me(m[R],B),A=_,H=L-p[g]-$,V=L/2-p[g]/2+D,O=gt(A,V,H),E=!a.arrow&&Ae(o)!=null&&V!==O&&s.reference[g]/2-(VV<=0)){var $,A;const V=((($=s.flip)==null?void 0:$.index)||0)+1,O=L[V];if(O)return{data:{index:V,overflows:_},reset:{placement:O}};let E=(A=_.filter(C=>C.overflows[0]<=0).sort((C,T)=>C.overflows[1]-T.overflows[1])[0])==null?void 0:A.placement;if(!E)switch(u){case"bestFit":{var H;const C=(H=_.filter(T=>{if(I){const v=ge(T.placement);return v===R||v==="y"}return!0}).map(T=>[T.placement,T.overflows.filter(v=>v>0).reduce((v,F)=>v+F,0)]).sort((T,v)=>T[1]-v[1])[0])==null?void 0:H[0];C&&(E=C);break}case"initialPlacement":E=c;break}if(o!==E)return{reset:{placement:E}}}return{}}}};function Pt(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function It(e){return Ln.some(t=>e[t]>=0)}const lr=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=ce(e,t);switch(r){case"referenceHidden":{const s=await Pe(t,{...o,elementContext:"reference"}),i=Pt(s,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:It(i)}}}case"escaped":{const s=await Pe(t,{...o,altBoundary:!0}),i=Pt(s,n.floating);return{data:{escapedOffsets:i,escaped:It(i)}}}default:return{}}}}};async function ur(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=le(n),c=Ae(n),a=ge(n)==="y",l=["left","top"].includes(i)?-1:1,d=s&&a?-1:1,m=ce(t,e);let{mainAxis:h,crossAxis:u,alignmentAxis:g}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return c&&typeof g=="number"&&(u=c==="end"?g*-1:g),a?{x:u*d,y:h*l}:{x:h*l,y:u*d}}const ar=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:i,middlewareData:c}=t,a=await ur(t,e);return i===((n=c.offset)==null?void 0:n.placement)&&(r=c.arrow)!=null&&r.alignmentOffset?{}:{x:o+a.x,y:s+a.y,data:{...a,placement:i}}}}},fr=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:c={fn:w=>{let{x:y,y:R}=w;return{x:y,y:R}}},...a}=ce(e,t),l={x:n,y:r},d=await Pe(t,a),m=ge(le(o)),h=wt(m);let u=l[h],g=l[m];if(s){const w=h==="y"?"top":"left",y=h==="y"?"bottom":"right",R=u+d[w],b=u-d[y];u=gt(R,u,b)}if(i){const w=m==="y"?"top":"left",y=m==="y"?"bottom":"right",R=g+d[w],b=g-d[y];g=gt(R,g,b)}const p=c.fn({...t,[h]:u,[m]:g});return{...p,data:{x:p.x-n,y:p.y-r,enabled:{[h]:s,[m]:i}}}}}},dr=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:i}=t,{offset:c=0,mainAxis:a=!0,crossAxis:l=!0}=ce(e,t),d={x:n,y:r},m=ge(o),h=wt(m);let u=d[h],g=d[m];const p=ce(c,t),w=typeof p=="number"?{mainAxis:p,crossAxis:0}:{mainAxis:0,crossAxis:0,...p};if(a){const b=h==="y"?"height":"width",x=s.reference[h]-s.floating[b]+w.mainAxis,S=s.reference[h]+s.reference[b]-w.mainAxis;uS&&(u=S)}if(l){var y,R;const b=h==="y"?"width":"height",x=["top","left"].includes(le(o)),S=s.reference[m]-s.floating[b]+(x&&((y=i.offset)==null?void 0:y[m])||0)+(x?0:w.crossAxis),I=s.reference[m]+s.reference[b]+(x?0:((R=i.offset)==null?void 0:R[m])||0)-(x?w.crossAxis:0);gI&&(g=I)}return{[h]:u,[m]:g}}}},mr=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:i,elements:c}=t,{apply:a=()=>{},...l}=ce(e,t),d=await Pe(t,l),m=le(o),h=Ae(o),u=ge(o)==="y",{width:g,height:p}=s.floating;let w,y;m==="top"||m==="bottom"?(w=m,y=h===(await(i.isRTL==null?void 0:i.isRTL(c.floating))?"start":"end")?"left":"right"):(y=m,w=h==="end"?"top":"bottom");const R=p-d.top-d.bottom,b=g-d.left-d.right,x=me(p-d[w],R),S=me(g-d[y],b),I=!t.middlewareData.shift;let L=x,D=S;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=b),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(L=R),I&&!h){const _=Q(d.left,0),$=Q(d.right,0),A=Q(d.top,0),H=Q(d.bottom,0);u?D=g-2*(_!==0||$!==0?_+$:Q(d.left,d.right)):L=p-2*(A!==0||H!==0?A+H:Q(d.top,d.bottom))}await a({...t,availableWidth:D,availableHeight:L});const B=await i.getDimensions(c.floating);return g!==B.width||p!==B.height?{reset:{rects:!0}}:{}}}};function ln(e){const t=ee(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=z(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,c=_e(n)!==s||_e(r)!==i;return c&&(n=s,r=i),{width:n,height:r,$:c}}function Et(e){return j(e)?e:e.contextElement}function Ee(e){const t=Et(e);if(!z(t))return re(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=ln(t);let i=(s?_e(n.width):n.width)/r,c=(s?_e(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!c||!Number.isFinite(c))&&(c=1),{x:i,y:c}}const gr=re(0);function un(e){const t=J(e);return!Ge()||!t.visualViewport?gr:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function pr(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==J(e)?!1:t}function ve(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=Et(e);let i=re(1);t&&(r?j(r)&&(i=Ee(r)):i=Ee(e));const c=pr(s,n,r)?un(s):re(0);let a=(o.left+c.x)/i.x,l=(o.top+c.y)/i.y,d=o.width/i.x,m=o.height/i.y;if(s){const h=J(s),u=r&&j(r)?J(r):r;let g=h,p=ft(g);for(;p&&r&&u!==g;){const w=Ee(p),y=p.getBoundingClientRect(),R=ee(p),b=y.left+(p.clientLeft+parseFloat(R.paddingLeft))*w.x,x=y.top+(p.clientTop+parseFloat(R.paddingTop))*w.y;a*=w.x,l*=w.y,d*=w.x,m*=w.y,a+=b,l+=x,g=J(p),p=ft(g)}}return He({width:d,height:m,x:a,y:l})}function Ct(e,t){const n=Ze(e).scrollLeft;return t?t.left+n:ve(oe(e)).left+n}function an(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:Ct(e,r)),s=r.top+t.scrollTop;return{x:o,y:s}}function hr(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=oe(r),c=t?Xe(t.floating):!1;if(r===i||c&&s)return n;let a={scrollLeft:0,scrollTop:0},l=re(1);const d=re(0),m=z(r);if((m||!m&&!s)&&((pe(r)!=="body"||Le(i))&&(a=Ze(r)),z(r))){const u=ve(r);l=Ee(r),d.x=u.x+r.clientLeft,d.y=u.y+r.clientTop}const h=i&&!m&&!s?an(i,a,!0):re(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-a.scrollLeft*l.x+d.x+h.x,y:n.y*l.y-a.scrollTop*l.y+d.y+h.y}}function vr(e){return Array.from(e.getClientRects())}function br(e){const t=oe(e),n=Ze(e),r=e.ownerDocument.body,o=Q(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=Q(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+Ct(e);const c=-n.scrollTop;return ee(r).direction==="rtl"&&(i+=Q(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:c}}function yr(e,t){const n=J(e),r=oe(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,c=0,a=0;if(o){s=o.width,i=o.height;const l=Ge();(!l||l&&t==="fixed")&&(c=o.offsetLeft,a=o.offsetTop)}return{width:s,height:i,x:c,y:a}}function wr(e,t){const n=ve(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=z(e)?Ee(e):re(1),i=e.clientWidth*s.x,c=e.clientHeight*s.y,a=o*s.x,l=r*s.y;return{width:i,height:c,x:a,y:l}}function Mt(e,t,n){let r;if(t==="viewport")r=yr(e,n);else if(t==="document")r=br(oe(e));else if(j(t))r=wr(t,n);else{const o=un(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return He(r)}function fn(e,t){const n=se(e);return n===t||!j(n)||de(n)?!1:ee(n).position==="fixed"||fn(n,t)}function xr(e,t){const n=t.get(e);if(n)return n;let r=fe(e,[],!1).filter(c=>j(c)&&pe(c)!=="body"),o=null;const s=ee(e).position==="fixed";let i=s?se(e):e;for(;j(i)&&!de(i);){const c=ee(i),a=yt(i);!a&&c.position==="fixed"&&(o=null),(s?!a&&!o:!a&&c.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Le(i)&&!a&&fn(e,i))?r=r.filter(d=>d!==i):o=c,i=se(i)}return t.set(e,r),r}function Rr(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?Xe(t)?[]:xr(t,this._c):[].concat(n),r],c=i[0],a=i.reduce((l,d)=>{const m=Mt(t,d,o);return l.top=Q(m.top,l.top),l.right=me(m.right,l.right),l.bottom=me(m.bottom,l.bottom),l.left=Q(m.left,l.left),l},Mt(t,c,o));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function Er(e){const{width:t,height:n}=ln(e);return{width:t,height:n}}function Cr(e,t,n){const r=z(t),o=oe(t),s=n==="fixed",i=ve(e,!0,s,t);let c={scrollLeft:0,scrollTop:0};const a=re(0);if(r||!r&&!s)if((pe(t)!=="body"||Le(o))&&(c=Ze(t)),r){const h=ve(t,!0,s,t);a.x=h.x+t.clientLeft,a.y=h.y+t.clientTop}else o&&(a.x=Ct(o));const l=o&&!r&&!s?an(o,c):re(0),d=i.left+c.scrollLeft-a.x-l.x,m=i.top+c.scrollTop-a.y-l.y;return{x:d,y:m,width:i.width,height:i.height}}function it(e){return ee(e).position==="static"}function Lt(e,t){if(!z(e)||ee(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return oe(e)===n&&(n=n.ownerDocument.body),n}function dn(e,t){const n=J(e);if(Xe(e))return n;if(!z(e)){let o=se(e);for(;o&&!de(o);){if(j(o)&&!it(o))return o;o=se(o)}return n}let r=Lt(e,t);for(;r&&En(r)&&it(r);)r=Lt(r,t);return r&&de(r)&&it(r)&&!yt(r)?n:r||Cn(e)||n}const Tr=async function(e){const t=this.getOffsetParent||dn,n=this.getDimensions,r=await n(e.floating);return{reference:Cr(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Ar(e){return ee(e).direction==="rtl"}const Sr={convertOffsetParentRelativeRectToViewportRelativeRect:hr,getDocumentElement:oe,getClippingRect:Rr,getOffsetParent:dn,getElementRects:Tr,getClientRects:vr,getDimensions:Er,getScale:Ee,isElement:j,isRTL:Ar};function Or(e,t){let n=null,r;const o=oe(e);function s(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function i(c,a){c===void 0&&(c=!1),a===void 0&&(a=1),s();const{left:l,top:d,width:m,height:h}=e.getBoundingClientRect();if(c||t(),!m||!h)return;const u=ke(d),g=ke(o.clientWidth-(l+m)),p=ke(o.clientHeight-(d+h)),w=ke(l),R={rootMargin:-u+"px "+-g+"px "+-p+"px "+-w+"px",threshold:Q(0,me(1,a))||1};let b=!0;function x(S){const I=S[0].intersectionRatio;if(I!==a){if(!b)return i();I?i(!1,I):r=setTimeout(()=>{i(!1,1e-7)},1e3)}b=!1}try{n=new IntersectionObserver(x,{...R,root:o.ownerDocument})}catch{n=new IntersectionObserver(x,R)}n.observe(e)}return i(!0),s}function lo(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:a=!1}=r,l=Et(e),d=o||s?[...l?fe(l):[],...fe(t)]:[];d.forEach(y=>{o&&y.addEventListener("scroll",n,{passive:!0}),s&&y.addEventListener("resize",n)});const m=l&&c?Or(l,n):null;let h=-1,u=null;i&&(u=new ResizeObserver(y=>{let[R]=y;R&&R.target===l&&u&&(u.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var b;(b=u)==null||b.observe(t)})),n()}),l&&!a&&u.observe(l),u.observe(t));let g,p=a?ve(e):null;a&&w();function w(){const y=ve(e);p&&(y.x!==p.x||y.y!==p.y||y.width!==p.width||y.height!==p.height)&&n(),p=y,g=requestAnimationFrame(w)}return n(),()=>{var y;d.forEach(R=>{o&&R.removeEventListener("scroll",n),s&&R.removeEventListener("resize",n)}),m?.(),(y=u)==null||y.disconnect(),u=null,a&&cancelAnimationFrame(g)}}const Pr=ar,Ir=fr,Mr=cr,Lr=mr,Dr=lr,Dt=sr,Fr=dr,kr=(e,t,n)=>{const r=new Map,o={platform:Sr,...n},s={...o.platform,_c:r};return ir(e,t,{...o,platform:s})};var We=typeof document<"u"?f.useLayoutEffect:f.useEffect;function Ye(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Ye(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!Ye(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function mn(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ft(e,t){const n=mn(e);return Math.round(t*n)/n}function st(e){const t=f.useRef(e);return We(()=>{t.current=e}),t}function Nr(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:i}={},transform:c=!0,whileElementsMounted:a,open:l}=e,[d,m]=f.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,u]=f.useState(r);Ye(h,r)||u(r);const[g,p]=f.useState(null),[w,y]=f.useState(null),R=f.useCallback(T=>{T!==I.current&&(I.current=T,p(T))},[]),b=f.useCallback(T=>{T!==L.current&&(L.current=T,y(T))},[]),x=s||g,S=i||w,I=f.useRef(null),L=f.useRef(null),D=f.useRef(d),B=a!=null,_=st(a),$=st(o),A=st(l),H=f.useCallback(()=>{if(!I.current||!L.current)return;const T={placement:t,strategy:n,middleware:h};$.current&&(T.platform=$.current),kr(I.current,L.current,T).then(v=>{const F={...v,isPositioned:A.current!==!1};V.current&&!Ye(D.current,F)&&(D.current=F,Ut.flushSync(()=>{m(F)}))})},[h,t,n,$,A]);We(()=>{l===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,m(T=>({...T,isPositioned:!1})))},[l]);const V=f.useRef(!1);We(()=>(V.current=!0,()=>{V.current=!1}),[]),We(()=>{if(x&&(I.current=x),S&&(L.current=S),x&&S){if(_.current)return _.current(x,S,H);H()}},[x,S,H,_,B]);const O=f.useMemo(()=>({reference:I,floating:L,setReference:R,setFloating:b}),[R,b]),E=f.useMemo(()=>({reference:x,floating:S}),[x,S]),C=f.useMemo(()=>{const T={position:n,left:0,top:0};if(!E.floating)return T;const v=Ft(E.floating,d.x),F=Ft(E.floating,d.y);return c?{...T,transform:"translate("+v+"px, "+F+"px)",...mn(E.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:v,top:F}},[n,c,E.floating,d.x,d.y]);return f.useMemo(()=>({...d,update:H,refs:O,elements:E,floatingStyles:C}),[d,H,O,E,C])}const $r=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Dt({element:r.current,padding:o}).fn(n):{}:r?Dt({element:r,padding:o}).fn(n):{}}}},uo=(e,t)=>({...Pr(e),options:[e,t]}),ao=(e,t)=>({...Ir(e),options:[e,t]}),fo=(e,t)=>({...Fr(e),options:[e,t]}),mo=(e,t)=>({...Mr(e),options:[e,t]}),go=(e,t)=>({...Lr(e),options:[e,t]}),po=(e,t)=>({...Dr(e),options:[e,t]}),ho=(e,t)=>({...$r(e),options:[e,t]});function vo(e){return f.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})},e)}const gn={...Rn},Wr=gn.useInsertionEffect,Br=Wr||(e=>e());function ne(e){const t=f.useRef(()=>{});return Br(()=>{t.current=e}),f.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;oe?.focus({preventScroll:n});o?s():kt=requestAnimationFrame(s)}var Y=typeof document<"u"?f.useLayoutEffect:f.useEffect;function Ie(){return Ie=Object.assign?Object.assign.bind():function(e){for(var t=1;t"floating-ui-"+Math.random().toString(36).slice(2,6)+_r++;function Vr(){const[e,t]=f.useState(()=>Nt?$t():void 0);return Y(()=>{e==null&&t($t())},[]),f.useEffect(()=>{Nt=!0},[]),e}const Hr=gn.useId,Qe=Hr||Vr,bo=f.forwardRef(function(t,n){const{context:{placement:r,elements:{floating:o},middlewareData:{arrow:s,shift:i}},width:c=14,height:a=7,tipRadius:l=0,strokeWidth:d=0,staticOffset:m,stroke:h,d:u,style:{transform:g,...p}={},...w}=t,y=Qe(),[R,b]=f.useState(!1);if(Y(()=>{if(!o)return;ee(o).direction==="rtl"&&b(!0)},[o]),!o)return null;const[x,S]=r.split("-"),I=x==="top"||x==="bottom";let L=m;(I&&i!=null&&i.x||!I&&i!=null&&i.y)&&(L=null);const D=d*2,B=D/2,_=c/2*(l/-8+1),$=a/2*l/4,A=!!u,H=L&&S==="end"?"bottom":"top";let V=L&&S==="end"?"right":"left";L&&R&&(V=S==="end"?"left":"right");const O=s?.x!=null?L||s.x:"",E=s?.y!=null?L||s.y:"",C=u||"M0,0"+(" H"+c)+(" L"+(c-_)+","+(a-$))+(" Q"+c/2+","+a+" "+_+","+(a-$))+" Z",T={top:A?"rotate(180deg)":"",left:A?"rotate(90deg)":"rotate(-90deg)",bottom:A?"":"rotate(180deg)",right:A?"rotate(-90deg)":"rotate(90deg)"}[x];return f.createElement("svg",Ie({},w,{"aria-hidden":!0,ref:n,width:A?c:c+D,height:c,viewBox:"0 0 "+c+" "+(a>c?a:c),style:{position:"absolute",pointerEvents:"none",[V]:O,[H]:E,[x]:I||A?"100%":"calc(100% - "+D/2+"px)",transform:[T,g].filter(v=>!!v).join(" "),...p}}),D>0&&f.createElement("path",{clipPath:"url(#"+y+")",fill:"none",stroke:h,strokeWidth:D+(u?0:1),d:C}),f.createElement("path",{stroke:D&&!u?w.fill:"none",d:C}),f.createElement("clipPath",{id:y},f.createElement("rect",{x:-B,y:B*(A?-1:1),width:c+D,height:c})))});function Kr(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(o=>o(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,((r=e.get(t))==null?void 0:r.filter(o=>o!==n))||[])}}}const jr=f.createContext(null),qr=f.createContext(null),Tt=()=>{var e;return((e=f.useContext(jr))==null?void 0:e.id)||null},et=()=>f.useContext(qr);function be(e){return"data-floating-ui-"+e}function Ce(e){const t=f.useRef(e);return Y(()=>{t.current=e}),t}const Wt=be("safe-polygon");function Be(e,t,n){return n&&!mt(n)?0:typeof e=="number"?e:e?.[t]}function yo(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,dataRef:o,events:s,elements:i}=e,{enabled:c=!0,delay:a=0,handleClose:l=null,mouseOnly:d=!1,restMs:m=0,move:h=!0}=t,u=et(),g=Tt(),p=Ce(l),w=Ce(a),y=Ce(n),R=f.useRef(),b=f.useRef(-1),x=f.useRef(),S=f.useRef(-1),I=f.useRef(!0),L=f.useRef(!1),D=f.useRef(()=>{}),B=f.useRef(!1),_=f.useCallback(()=>{var E;const C=(E=o.current.openEvent)==null?void 0:E.type;return C?.includes("mouse")&&C!=="mousedown"},[o]);f.useEffect(()=>{if(!c)return;function E(C){let{open:T}=C;T||(clearTimeout(b.current),clearTimeout(S.current),I.current=!0,B.current=!1)}return s.on("openchange",E),()=>{s.off("openchange",E)}},[c,s]),f.useEffect(()=>{if(!c||!p.current||!n)return;function E(T){_()&&r(!1,T,"hover")}const C=Z(i.floating).documentElement;return C.addEventListener("mouseleave",E),()=>{C.removeEventListener("mouseleave",E)}},[i.floating,n,r,c,p,_]);const $=f.useCallback(function(E,C,T){C===void 0&&(C=!0),T===void 0&&(T="hover");const v=Be(w.current,"close",R.current);v&&!x.current?(clearTimeout(b.current),b.current=window.setTimeout(()=>r(!1,E,T),v)):C&&(clearTimeout(b.current),r(!1,E,T))},[w,r]),A=ne(()=>{D.current(),x.current=void 0}),H=ne(()=>{if(L.current){const E=Z(i.floating).body;E.style.pointerEvents="",E.removeAttribute(Wt),L.current=!1}});f.useEffect(()=>{if(!c)return;function E(){return o.current.openEvent?["click","mousedown"].includes(o.current.openEvent.type):!1}function C(M){if(clearTimeout(b.current),I.current=!1,d&&!mt(R.current)||m>0&&!Be(w.current,"open"))return;const q=Be(w.current,"open",R.current);q?b.current=window.setTimeout(()=>{y.current||r(!0,M,"hover")},q):r(!0,M,"hover")}function T(M){if(E())return;D.current();const q=Z(i.floating);if(clearTimeout(S.current),B.current=!1,p.current&&o.current.floatingContext){n||clearTimeout(b.current),x.current=p.current({...o.current.floatingContext,tree:u,x:M.clientX,y:M.clientY,onClose(){H(),A(),$(M,!0,"safe-polygon")}});const k=x.current;q.addEventListener("mousemove",k),D.current=()=>{q.removeEventListener("mousemove",k)};return}(R.current==="touch"?!G(i.floating,M.relatedTarget):!0)&&$(M)}function v(M){E()||o.current.floatingContext&&(p.current==null||p.current({...o.current.floatingContext,tree:u,x:M.clientX,y:M.clientY,onClose(){H(),A(),$(M)}})(M))}if(j(i.domReference)){var F;const M=i.domReference;return n&&M.addEventListener("mouseleave",v),(F=i.floating)==null||F.addEventListener("mouseleave",v),h&&M.addEventListener("mousemove",C,{once:!0}),M.addEventListener("mouseenter",C),M.addEventListener("mouseleave",T),()=>{var q;n&&M.removeEventListener("mouseleave",v),(q=i.floating)==null||q.removeEventListener("mouseleave",v),h&&M.removeEventListener("mousemove",C),M.removeEventListener("mouseenter",C),M.removeEventListener("mouseleave",T)}}},[i,c,e,d,m,h,$,A,H,r,n,y,u,w,p,o]),Y(()=>{var E;if(c&&n&&(E=p.current)!=null&&E.__options.blockPointerEvents&&_()){L.current=!0;const T=i.floating;if(j(i.domReference)&&T){var C;const v=Z(i.floating).body;v.setAttribute(Wt,"");const F=i.domReference,M=u==null||(C=u.nodesRef.current.find(q=>q.id===g))==null||(C=C.context)==null?void 0:C.elements.floating;return M&&(M.style.pointerEvents=""),v.style.pointerEvents="none",F.style.pointerEvents="auto",T.style.pointerEvents="auto",()=>{v.style.pointerEvents="",F.style.pointerEvents="",T.style.pointerEvents=""}}}},[c,n,g,i,u,p,_]),Y(()=>{n||(R.current=void 0,B.current=!1,A(),H())},[n,A,H]),f.useEffect(()=>()=>{A(),clearTimeout(b.current),clearTimeout(S.current),H()},[c,i.domReference,A,H]);const V=f.useMemo(()=>{function E(C){R.current=C.pointerType}return{onPointerDown:E,onPointerEnter:E,onMouseMove(C){const{nativeEvent:T}=C;function v(){!I.current&&!y.current&&r(!0,T,"hover")}d&&!mt(R.current)||n||m===0||B.current&&C.movementX**2+C.movementY**2<2||(clearTimeout(S.current),R.current==="touch"?v():(B.current=!0,S.current=window.setTimeout(v,m)))}}},[d,r,n,y,m]),O=f.useMemo(()=>({onMouseEnter(){clearTimeout(b.current)},onMouseLeave(E){$(E.nativeEvent,!1)}}),[$]);return f.useMemo(()=>c?{reference:V,floating:O}:{},[c,V,O])}const vt=()=>{},pn=f.createContext({delay:0,initialDelay:0,timeoutMs:0,currentId:null,setCurrentId:vt,setState:vt,isInstantPhase:!1}),Yr=()=>f.useContext(pn);function wo(e){const{children:t,delay:n,timeoutMs:r=0}=e,[o,s]=f.useReducer((a,l)=>({...a,...l}),{delay:n,timeoutMs:r,initialDelay:n,currentId:null,isInstantPhase:!1}),i=f.useRef(null),c=f.useCallback(a=>{s({currentId:a})},[]);return Y(()=>{o.currentId?i.current===null?i.current=o.currentId:o.isInstantPhase||s({isInstantPhase:!0}):(o.isInstantPhase&&s({isInstantPhase:!1}),i.current=null)},[o.currentId,o.isInstantPhase]),f.createElement(pn.Provider,{value:f.useMemo(()=>({...o,setState:s,setCurrentId:c}),[o,c])},t)}function xo(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,floatingId:o}=e,{id:s,enabled:i=!0}=t,c=s??o,a=Yr(),{currentId:l,setCurrentId:d,initialDelay:m,setState:h,timeoutMs:u}=a;return Y(()=>{i&&l&&(h({delay:{open:1,close:Be(m,"close")}}),l!==c&&r(!1))},[i,c,r,h,l,m]),Y(()=>{function g(){r(!1),h({delay:m,currentId:null})}if(i&&l&&!n&&l===c){if(u){const p=window.setTimeout(g,u);return()=>{clearTimeout(p)}}g()}},[i,n,h,l,c,r,m,u]),Y(()=>{i&&(d===vt||!n||d(c))},[i,n,d,c]),a}function zr(e,t){var n;let r=[],o=(n=e.find(s=>s.id===t))==null?void 0:n.parentId;for(;o;){const s=e.find(i=>i.id===o);o=s?.parentId,s&&(r=r.concat(s))}return r}function Se(e,t){let n=e.filter(o=>{var s;return o.parentId===t&&((s=o.context)==null?void 0:s.open)}),r=n;for(;r.length;)r=e.filter(o=>{var s;return(s=r)==null?void 0:s.some(i=>{var c;return o.parentId===i.id&&((c=o.context)==null?void 0:c.open)})}),n=n.concat(r);return n}let Re=new WeakMap,Ne=new WeakSet,$e={},ct=0;const Ur=()=>typeof HTMLElement<"u"&&"inert"in HTMLElement.prototype,hn=e=>e&&(e.host||hn(e.parentNode)),Xr=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=hn(n);return e.contains(r)?r:null}).filter(n=>n!=null);function Gr(e,t,n,r){const o="data-floating-ui-inert",s=r?"inert":n?"aria-hidden":null,i=Xr(t,e),c=new Set,a=new Set(i),l=[];$e[o]||($e[o]=new WeakMap);const d=$e[o];i.forEach(m),h(t),c.clear();function m(u){!u||c.has(u)||(c.add(u),u.parentNode&&m(u.parentNode))}function h(u){!u||a.has(u)||[].forEach.call(u.children,g=>{if(pe(g)!=="script")if(c.has(g))h(g);else{const p=s?g.getAttribute(s):null,w=p!==null&&p!=="false",y=(Re.get(g)||0)+1,R=(d.get(g)||0)+1;Re.set(g,y),d.set(g,R),l.push(g),y===1&&w&&Ne.add(g),R===1&&g.setAttribute(o,""),!w&&s&&g.setAttribute(s,"true")}})}return ct++,()=>{l.forEach(u=>{const g=(Re.get(u)||0)-1,p=(d.get(u)||0)-1;Re.set(u,g),d.set(u,p),g||(!Ne.has(u)&&s&&u.removeAttribute(s),Ne.delete(u)),p||u.removeAttribute(o)}),ct--,ct||(Re=new WeakMap,Re=new WeakMap,Ne=new WeakSet,$e={})}}function Bt(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);const r=Z(e[0]).body;return Gr(e.concat(Array.from(r.querySelectorAll("[aria-live]"))),r,t,n)}const Me=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function vn(e,t){const n=Je(e,Me());t==="prev"&&n.reverse();const r=n.indexOf(ie(Z(e)));return n.slice(r+1)[0]}function bn(){return vn(document.body,"next")}function yn(){return vn(document.body,"prev")}function Oe(e,t){const n=t||e.currentTarget,r=e.relatedTarget;return!r||!G(n,r)}function Zr(e){Je(e,Me()).forEach(n=>{n.dataset.tabindex=n.getAttribute("tabindex")||"",n.setAttribute("tabindex","-1")})}function _t(e){e.querySelectorAll("[data-tabindex]").forEach(n=>{const r=n.dataset.tabindex;delete n.dataset.tabindex,r?n.setAttribute("tabindex",r):n.removeAttribute("tabindex")})}const tt={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0};let Jr;function Vt(e){e.key==="Tab"&&(e.target,clearTimeout(Jr))}const ze=f.forwardRef(function(t,n){const[r,o]=f.useState();Y(()=>(en()&&o("button"),document.addEventListener("keydown",Vt),()=>{document.removeEventListener("keydown",Vt)}),[]);const s={ref:n,tabIndex:0,role:r,"aria-hidden":r?void 0:!0,[be("focus-guard")]:"",style:tt};return f.createElement("span",Ie({},t,s))}),wn=f.createContext(null),Ht=be("portal");function Qr(e){e===void 0&&(e={});const{id:t,root:n}=e,r=Qe(),o=xn(),[s,i]=f.useState(null),c=f.useRef(null);return Y(()=>()=>{s?.remove(),queueMicrotask(()=>{c.current=null})},[s]),Y(()=>{if(!r||c.current)return;const a=t?document.getElementById(t):null;if(!a)return;const l=document.createElement("div");l.id=r,l.setAttribute(Ht,""),a.appendChild(l),c.current=l,i(l)},[t,r]),Y(()=>{if(n===null||!r||c.current)return;let a=n||o?.portalNode;a&&!j(a)&&(a=a.current),a=a||document.body;let l=null;t&&(l=document.createElement("div"),l.id=t,a.appendChild(l));const d=document.createElement("div");d.id=r,d.setAttribute(Ht,""),a=l||a,a.appendChild(d),c.current=d,i(d)},[t,n,r,o]),s}function Ro(e){const{children:t,id:n,root:r,preserveTabOrder:o=!0}=e,s=Qr({id:n,root:r}),[i,c]=f.useState(null),a=f.useRef(null),l=f.useRef(null),d=f.useRef(null),m=f.useRef(null),h=i?.modal,u=i?.open,g=!!i&&!i.modal&&i.open&&o&&!!(r||s);return f.useEffect(()=>{if(!s||!o||h)return;function p(w){s&&Oe(w)&&(w.type==="focusin"?_t:Zr)(s)}return s.addEventListener("focusin",p,!0),s.addEventListener("focusout",p,!0),()=>{s.removeEventListener("focusin",p,!0),s.removeEventListener("focusout",p,!0)}},[s,o,h]),f.useEffect(()=>{s&&(u||_t(s))},[u,s]),f.createElement(wn.Provider,{value:f.useMemo(()=>({preserveTabOrder:o,beforeOutsideRef:a,afterOutsideRef:l,beforeInsideRef:d,afterInsideRef:m,portalNode:s,setFocusManagerState:c}),[o,s])},g&&s&&f.createElement(ze,{"data-type":"outside",ref:a,onFocus:p=>{if(Oe(p,s)){var w;(w=d.current)==null||w.focus()}else{const y=yn()||i?.refs.domReference.current;y?.focus()}}}),g&&s&&f.createElement("span",{"aria-owns":s.id,style:tt}),s&&Ut.createPortal(t,s),g&&s&&f.createElement(ze,{"data-type":"outside",ref:l,onFocus:p=>{if(Oe(p,s)){var w;(w=m.current)==null||w.focus()}else{const y=bn()||i?.refs.domReference.current;y?.focus(),i?.closeOnFocusOut&&i?.onOpenChange(!1,p.nativeEvent,"focus-out")}}}))}const xn=()=>f.useContext(wn),bt="data-floating-ui-focusable";function eo(e){return e?e.hasAttribute(bt)?e:e.querySelector("["+bt+"]")||e:null}const Kt=20;let he=[];function lt(e){he=he.filter(n=>n.isConnected);let t=e;if(!(!t||pe(t)==="body")){if(!or(t,Me())){const n=Je(t,Me())[0];n&&(t=n)}he.push(t),he.length>Kt&&(he=he.slice(-Kt))}}function jt(){return he.slice().reverse().find(e=>e.isConnected)}const to=f.forwardRef(function(t,n){return f.createElement("button",Ie({},t,{type:"button",ref:n,tabIndex:-1,style:tt}))});function Eo(e){const{context:t,children:n,disabled:r=!1,order:o=["content"],guards:s=!0,initialFocus:i=0,returnFocus:c=!0,restoreFocus:a=!1,modal:l=!0,visuallyHiddenDismiss:d=!1,closeOnFocusOut:m=!0}=e,{open:h,refs:u,nodeId:g,onOpenChange:p,events:w,dataRef:y,floatingId:R,elements:{domReference:b,floating:x}}=t,S=typeof i=="number"&&i<0,I=Mn(b)&&S,L=Ur()?s:!0,D=Ce(o),B=Ce(i),_=Ce(c),$=et(),A=xn(),H=f.useRef(null),V=f.useRef(null),O=f.useRef(!1),E=f.useRef(!1),C=f.useRef(-1),T=A!=null,v=eo(x),F=ne(function(k){return k===void 0&&(k=v),k?Je(k,Me()):[]}),M=ne(k=>{const W=F(k);return D.current.map(P=>b&&P==="reference"?b:v&&P==="floating"?v:W).filter(Boolean).flat()});f.useEffect(()=>{O.current=!1},[r]),f.useEffect(()=>{if(r||!l)return;function k(P){if(P.key==="Tab"){G(v,ie(Z(v)))&&F().length===0&&!I&&ot(P);const N=M(),K=ae(P);D.current[0]==="reference"&&K===b&&(ot(P),P.shiftKey?xe(N[N.length-1]):xe(N[1])),D.current[1]==="floating"&&K===v&&P.shiftKey&&(ot(P),xe(N[0]))}}const W=Z(v);return W.addEventListener("keydown",k),()=>{W.removeEventListener("keydown",k)}},[r,b,v,l,D,I,F,M]),f.useEffect(()=>{if(r||!x)return;function k(W){const P=ae(W),K=F().indexOf(P);K!==-1&&(C.current=K)}return x.addEventListener("focusin",k),()=>{x.removeEventListener("focusin",k)}},[r,x,F]),f.useEffect(()=>{if(r||!m)return;function k(){E.current=!0,setTimeout(()=>{E.current=!1})}function W(P){const N=P.relatedTarget;queueMicrotask(()=>{const K=!(G(b,N)||G(x,N)||G(N,x)||G(A?.portalNode,N)||N!=null&&N.hasAttribute(be("focus-guard"))||$&&(Se($.nodesRef.current,g).find(X=>{var U,te;return G((U=X.context)==null?void 0:U.elements.floating,N)||G((te=X.context)==null?void 0:te.elements.domReference,N)})||zr($.nodesRef.current,g).find(X=>{var U,te;return((U=X.context)==null?void 0:U.elements.floating)===N||((te=X.context)==null?void 0:te.elements.domReference)===N})));if(a&&K&&ie(Z(v))===Z(v).body){z(v)&&v.focus();const X=C.current,U=F(),te=U[X]||U[U.length-1]||v;z(te)&&te.focus()}(I||!l)&&N&&K&&!E.current&&N!==jt()&&(O.current=!0,p(!1,P,"focus-out"))})}if(x&&z(b))return b.addEventListener("focusout",W),b.addEventListener("pointerdown",k),x.addEventListener("focusout",W),()=>{b.removeEventListener("focusout",W),b.removeEventListener("pointerdown",k),x.removeEventListener("focusout",W)}},[r,b,x,v,l,g,$,A,p,m,a,F,I]),f.useEffect(()=>{var k;if(r)return;const W=Array.from((A==null||(k=A.portalNode)==null?void 0:k.querySelectorAll("["+be("portal")+"]"))||[]);if(x){const P=[x,...W,H.current,V.current,D.current.includes("reference")||I?b:null].filter(K=>K!=null),N=l||I?Bt(P,L,!L):Bt(P);return()=>{N()}}},[r,b,x,l,D,A,I,L]),Y(()=>{if(r||!z(v))return;const k=Z(v),W=ie(k);queueMicrotask(()=>{const P=M(v),N=B.current,K=(typeof N=="number"?P[N]:N.current)||v,X=G(v,W);!S&&!X&&h&&xe(K,{preventScroll:K===v})})},[r,h,v,S,M,B]),Y(()=>{if(r||!v)return;let k=!1;const W=Z(v),P=ie(W);let K=y.current.openEvent;lt(P);function X(we){let{open:De,reason:Fe,event:ue,nested:nt}=we;De&&(K=ue),Fe==="escape-key"&&u.domReference.current&<(u.domReference.current),Fe==="hover"&&ue.type==="mouseleave"&&(O.current=!0),Fe==="outside-press"&&(nt?(O.current=!1,k=!0):O.current=!(Tn(ue)||Qt(ue)))}w.on("openchange",X);const U=W.createElement("span");U.setAttribute("tabindex","-1"),U.setAttribute("aria-hidden","true"),Object.assign(U.style,tt),T&&b&&b.insertAdjacentElement("afterend",U);function te(){return typeof _.current=="boolean"?jt()||U:_.current.current||U}return()=>{w.off("openchange",X);const we=ie(W),De=G(x,we)||$&&Se($.nodesRef.current,g).some(nt=>{var At;return G((At=nt.context)==null?void 0:At.elements.floating,we)});(De||K&&["click","mousedown"].includes(K.type))&&u.domReference.current&<(u.domReference.current);const ue=te();queueMicrotask(()=>{_.current&&!O.current&&z(ue)&&(!(ue!==we&&we!==W.body)||De)&&ue.focus({preventScroll:k}),U.remove()})}},[r,x,v,_,y,u,w,$,g,T,b]),Y(()=>{if(!r&&A)return A.setFocusManagerState({modal:l,closeOnFocusOut:m,open:h,onOpenChange:p,refs:u}),()=>{A.setFocusManagerState(null)}},[r,A,l,h,p,u,m]),Y(()=>{if(r||!v||typeof MutationObserver!="function"||S)return;const k=()=>{const P=v.getAttribute("tabindex"),N=F(),K=ie(Z(x)),X=N.indexOf(K);X!==-1&&(C.current=X),D.current.includes("floating")||K!==u.domReference.current&&N.length===0?P!=="0"&&v.setAttribute("tabindex","0"):P!=="-1"&&v.setAttribute("tabindex","-1")};k();const W=new MutationObserver(k);return W.observe(v,{childList:!0,subtree:!0,attributes:!0}),()=>{W.disconnect()}},[r,x,v,u,D,F,S]);function q(k){return r||!d||!l?null:f.createElement(to,{ref:k==="start"?H:V,onClick:W=>p(!1,W.nativeEvent)},typeof d=="string"?d:"Dismiss")}const ye=!r&&L&&(l?!I:!0)&&(T||l);return f.createElement(f.Fragment,null,ye&&f.createElement(ze,{"data-type":"inside",ref:A?.beforeInsideRef,onFocus:k=>{if(l){const P=M();xe(o[0]==="reference"?P[0]:P[P.length-1])}else if(A!=null&&A.preserveTabOrder&&A.portalNode)if(O.current=!1,Oe(k,A.portalNode)){const P=bn()||b;P?.focus()}else{var W;(W=A.beforeOutsideRef.current)==null||W.focus()}}}),!I&&q("start"),n,q("end"),ye&&f.createElement(ze,{"data-type":"inside",ref:A?.afterInsideRef,onFocus:k=>{if(l)xe(M()[0]);else if(A!=null&&A.preserveTabOrder&&A.portalNode)if(m&&(O.current=!0),Oe(k,A.portalNode)){const P=yn()||b;P?.focus()}else{var W;(W=A.afterOutsideRef.current)==null||W.focus()}}}))}const no={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},ro={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},qt=e=>{var t,n;return{escapeKey:typeof e=="boolean"?e:(t=e?.escapeKey)!=null?t:!1,outsidePress:typeof e=="boolean"?e:(n=e?.outsidePress)!=null?n:!0}};function Co(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,elements:o,dataRef:s}=e,{enabled:i=!0,escapeKey:c=!0,outsidePress:a=!0,outsidePressEvent:l="pointerdown",referencePress:d=!1,referencePressEvent:m="pointerdown",ancestorScroll:h=!1,bubbles:u,capture:g}=t,p=et(),w=ne(typeof a=="function"?a:()=>!1),y=typeof a=="function"?w:a,R=f.useRef(!1),b=f.useRef(!1),{escapeKey:x,outsidePress:S}=qt(u),{escapeKey:I,outsidePress:L}=qt(g),D=f.useRef(!1),B=ne(O=>{var E;if(!n||!i||!c||O.key!=="Escape"||D.current)return;const C=(E=s.current.floatingContext)==null?void 0:E.nodeId,T=p?Se(p.nodesRef.current,C):[];if(!x&&(O.stopPropagation(),T.length>0)){let v=!0;if(T.forEach(F=>{var M;if((M=F.context)!=null&&M.open&&!F.context.dataRef.current.__escapeKeyBubbles){v=!1;return}}),!v)return}r(!1,On(O)?O.nativeEvent:O,"escape-key")}),_=ne(O=>{var E;const C=()=>{var T;B(O),(T=ae(O))==null||T.removeEventListener("keydown",C)};(E=ae(O))==null||E.addEventListener("keydown",C)}),$=ne(O=>{var E;const C=R.current;R.current=!1;const T=b.current;if(b.current=!1,l==="click"&&T||C||typeof y=="function"&&!y(O))return;const v=ae(O),F="["+be("inert")+"]",M=Z(o.floating).querySelectorAll(F);let q=j(v)?v:null;for(;q&&!de(q);){const P=se(q);if(de(P)||!j(P))break;q=P}if(M.length&&j(v)&&!Pn(v)&&!G(v,o.floating)&&Array.from(M).every(P=>!G(q,P)))return;if(z(v)&&V){const P=v.clientWidth>0&&v.scrollWidth>v.clientWidth,N=v.clientHeight>0&&v.scrollHeight>v.clientHeight;let K=N&&O.offsetX>v.clientWidth;if(N&&ee(v).direction==="rtl"&&(K=O.offsetX<=v.offsetWidth-v.clientWidth),K||P&&O.offsetY>v.clientHeight)return}const ye=(E=s.current.floatingContext)==null?void 0:E.nodeId,k=p&&Se(p.nodesRef.current,ye).some(P=>{var N;return rt(O,(N=P.context)==null?void 0:N.elements.floating)});if(rt(O,o.floating)||rt(O,o.domReference)||k)return;const W=p?Se(p.nodesRef.current,ye):[];if(W.length>0){let P=!0;if(W.forEach(N=>{var K;if((K=N.context)!=null&&K.open&&!N.context.dataRef.current.__outsidePressBubbles){P=!1;return}}),!P)return}r(!1,O,"outside-press")}),A=ne(O=>{var E;const C=()=>{var T;$(O),(T=ae(O))==null||T.removeEventListener(l,C)};(E=ae(O))==null||E.addEventListener(l,C)});f.useEffect(()=>{if(!n||!i)return;s.current.__escapeKeyBubbles=x,s.current.__outsidePressBubbles=S;let O=-1;function E(M){r(!1,M,"ancestor-scroll")}function C(){window.clearTimeout(O),D.current=!0}function T(){O=window.setTimeout(()=>{D.current=!1},Ge()?5:0)}const v=Z(o.floating);c&&(v.addEventListener("keydown",I?_:B,I),v.addEventListener("compositionstart",C),v.addEventListener("compositionend",T)),y&&v.addEventListener(l,L?A:$,L);let F=[];return h&&(j(o.domReference)&&(F=fe(o.domReference)),j(o.floating)&&(F=F.concat(fe(o.floating))),!j(o.reference)&&o.reference&&o.reference.contextElement&&(F=F.concat(fe(o.reference.contextElement)))),F=F.filter(M=>{var q;return M!==((q=v.defaultView)==null?void 0:q.visualViewport)}),F.forEach(M=>{M.addEventListener("scroll",E,{passive:!0})}),()=>{c&&(v.removeEventListener("keydown",I?_:B,I),v.removeEventListener("compositionstart",C),v.removeEventListener("compositionend",T)),y&&v.removeEventListener(l,L?A:$,L),F.forEach(M=>{M.removeEventListener("scroll",E)}),window.clearTimeout(O)}},[s,o,c,y,l,n,r,h,i,x,S,B,I,_,$,L,A]),f.useEffect(()=>{R.current=!1},[y,l]);const H=f.useMemo(()=>({onKeyDown:B,[no[m]]:O=>{d&&r(!1,O.nativeEvent,"reference-press")}}),[B,r,d,m]),V=f.useMemo(()=>({onKeyDown:B,onMouseDown(){b.current=!0},onMouseUp(){b.current=!0},[ro[l]]:()=>{R.current=!0}}),[B,l]);return f.useMemo(()=>i?{reference:H,floating:V}:{},[i,H,V])}function oo(e){const{open:t=!1,onOpenChange:n,elements:r}=e,o=Qe(),s=f.useRef({}),[i]=f.useState(()=>Kr()),c=Tt()!=null,[a,l]=f.useState(r.reference),d=ne((u,g,p)=>{s.current.openEvent=u?g:void 0,i.emit("openchange",{open:u,event:g,reason:p,nested:c}),n?.(u,g,p)}),m=f.useMemo(()=>({setPositionReference:l}),[]),h=f.useMemo(()=>({reference:a||r.reference||null,floating:r.floating||null,domReference:r.reference}),[a,r.reference,r.floating]);return f.useMemo(()=>({dataRef:s,open:t,onOpenChange:d,elements:h,events:i,floatingId:o,refs:m}),[t,d,h,i,o,m])}function To(e){e===void 0&&(e={});const{nodeId:t}=e,n=oo({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,o=r.elements,[s,i]=f.useState(null),[c,a]=f.useState(null),d=o?.domReference||s,m=f.useRef(null),h=et();Y(()=>{d&&(m.current=d)},[d]);const u=Nr({...e,elements:{...o,...c&&{reference:c}}}),g=f.useCallback(b=>{const x=j(b)?{getBoundingClientRect:()=>b.getBoundingClientRect(),contextElement:b}:b;a(x),u.refs.setReference(x)},[u.refs]),p=f.useCallback(b=>{(j(b)||b===null)&&(m.current=b,i(b)),(j(u.refs.reference.current)||u.refs.reference.current===null||b!==null&&!j(b))&&u.refs.setReference(b)},[u.refs]),w=f.useMemo(()=>({...u.refs,setReference:p,setPositionReference:g,domReference:m}),[u.refs,p,g]),y=f.useMemo(()=>({...u.elements,domReference:d}),[u.elements,d]),R=f.useMemo(()=>({...u,...r,refs:w,elements:y,nodeId:t}),[u,w,y,t,r]);return Y(()=>{r.dataRef.current.floatingContext=R;const b=h?.nodesRef.current.find(x=>x.id===t);b&&(b.context=R)}),f.useMemo(()=>({...u,context:R,refs:w,elements:y}),[u,w,y,R])}function Ao(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,events:o,dataRef:s,elements:i}=e,{enabled:c=!0,visibleOnly:a=!0}=t,l=f.useRef(!1),d=f.useRef(),m=f.useRef(!0);f.useEffect(()=>{if(!c)return;const u=J(i.domReference);function g(){!n&&z(i.domReference)&&i.domReference===ie(Z(i.domReference))&&(l.current=!0)}function p(){m.current=!0}return u.addEventListener("blur",g),u.addEventListener("keydown",p,!0),()=>{u.removeEventListener("blur",g),u.removeEventListener("keydown",p,!0)}},[i.domReference,n,c]),f.useEffect(()=>{if(!c)return;function u(g){let{reason:p}=g;(p==="reference-press"||p==="escape-key")&&(l.current=!0)}return o.on("openchange",u),()=>{o.off("openchange",u)}},[o,c]),f.useEffect(()=>()=>{clearTimeout(d.current)},[]);const h=f.useMemo(()=>({onPointerDown(u){Qt(u.nativeEvent)||(m.current=!1)},onMouseLeave(){l.current=!1},onFocus(u){if(l.current)return;const g=ae(u.nativeEvent);if(a&&j(g))try{if(en()&&An())throw Error();if(!g.matches(":focus-visible"))return}catch{if(!m.current&&!tn(g))return}r(!0,u.nativeEvent,"focus")},onBlur(u){l.current=!1;const g=u.relatedTarget,p=u.nativeEvent,w=j(g)&&g.hasAttribute(be("focus-guard"))&&g.getAttribute("data-type")==="outside";d.current=window.setTimeout(()=>{var y;const R=ie(i.domReference?i.domReference.ownerDocument:document);!g&&R===i.domReference||G((y=s.current.floatingContext)==null?void 0:y.refs.floating.current,R)||G(i.domReference,R)||w||r(!1,p,"focus")})}}),[s,i.domReference,r,a]);return f.useMemo(()=>c?{reference:h}:{},[c,h])}const Yt="active",zt="selected";function ut(e,t,n){const r=new Map,o=n==="item";let s=e;if(o&&e){const{[Yt]:i,[zt]:c,...a}=e;s=a}return{...n==="floating"&&{tabIndex:-1,[bt]:""},...s,...t.map(i=>{const c=i?i[n]:null;return typeof c=="function"?e?c(e):null:c}).concat(e).reduce((i,c)=>(c&&Object.entries(c).forEach(a=>{let[l,d]=a;if(!(o&&[Yt,zt].includes(l)))if(l.indexOf("on")===0){if(r.has(l)||r.set(l,[]),typeof d=="function"){var m;(m=r.get(l))==null||m.push(d),i[l]=function(){for(var h,u=arguments.length,g=new Array(u),p=0;pw(...g)).find(w=>w!==void 0)}}}else i[l]=d}),i),{})}}function So(e){e===void 0&&(e=[]);const t=e.map(c=>c?.reference),n=e.map(c=>c?.floating),r=e.map(c=>c?.item),o=f.useCallback(c=>ut(c,e,"reference"),t),s=f.useCallback(c=>ut(c,e,"floating"),n),i=f.useCallback(c=>ut(c,e,"item"),r);return f.useMemo(()=>({getReferenceProps:o,getFloatingProps:s,getItemProps:i}),[o,s,i])}const io=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function Oo(e,t){var n;t===void 0&&(t={});const{open:r,floatingId:o}=e,{enabled:s=!0,role:i="dialog"}=t,c=(n=io.get(i))!=null?n:i,a=Qe(),d=Tt()!=null,m=f.useMemo(()=>c==="tooltip"||i==="label"?{["aria-"+(i==="label"?"labelledby":"describedby")]:r?o:void 0}:{"aria-expanded":r?"true":"false","aria-haspopup":c==="alertdialog"?"dialog":c,"aria-controls":r?o:void 0,...c==="listbox"&&{role:"combobox"},...c==="menu"&&{id:a},...c==="menu"&&d&&{role:"menuitem"},...i==="select"&&{"aria-autocomplete":"none"},...i==="combobox"&&{"aria-autocomplete":"list"}},[c,o,d,r,a,i]),h=f.useMemo(()=>{const g={id:o,...c&&{role:c}};return c==="tooltip"||i==="label"?g:{...g,...c==="menu"&&{"aria-labelledby":a}}},[c,o,a,i]),u=f.useCallback(g=>{let{active:p,selected:w}=g;const y={role:"option",...p&&{id:o+"-option"}};switch(i){case"select":return{...y,"aria-selected":p&&w};case"combobox":return{...y,...p&&{"aria-selected":!0}}}return{}},[o,i]);return f.useMemo(()=>s?{reference:m,floating:h,item:u}:{},[s,m,h,u])}export{wo as F,vo as a,To as b,lo as c,ho as d,xo as e,mo as f,yo as g,Ao as h,Co as i,Oo as j,So as k,Ro as l,bo as m,fo as n,uo as o,Eo as p,Nr as q,go as r,ao as s,po as t,Qe as u}; diff --git a/assets/iframe-80GKSfNA.js b/assets/iframe-DWIAQds9.js similarity index 77% rename from assets/iframe-80GKSfNA.js rename to assets/iframe-DWIAQds9.js index b5e754c8..eb8c45f5 100644 --- a/assets/iframe-80GKSfNA.js +++ b/assets/iframe-DWIAQds9.js @@ -1,2 +1,2 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./Alert.stories-PBNjduBZ.js","./jsx-runtime-DR9Q75dM.js","./index-DRjF_FHU.js","./Button-BORixq-h.js","./index-lhGYx47h.js","./UnstyledButton-DuxpNl0e.js","./Button-W0jf5teY.css","./info-D9sKA_Xt.js","./error-DOy7ZFuJ.js","./close-CWATPeIo.js","./Text-BvzksikX.js","./Typography-DzhKoIWt.js","./Typography-CFo2KqHV.css","./IconButton-CBGH5UyO.js","./IndicatorIcon-CKMK3E77.js","./IndicatorIcon-Df2gvoto.css","./Tooltip-DGTzhuPA.js","./floating-ui.react-CACRriTf.js","./index-BvEl7W6R.js","./Tooltip-Bx3q_cph.css","./IconButton-X8Xpz74a.css","./Alert-RAKRA8iu.css","./Avatar.stories-Dqdk1TyC.js","./Avatar-BPJ7Tfaa.js","./Avatar-CE8ocXGL.css","./AvatarStack.stories-DFbc-d2p.js","./Badge.stories-BHGShZoQ.js","./Badge-DHQHyvgX.css","./ActionButton.stories-Dc7Ppv78.js","./index-JRK_GaCU.js","./index-C87-hJvQ.js","./notifications-BEKrtwGv.js","./extensions-DRIHxRsb.js","./check-circle-solid-DvGH8qX5.js","./check-BWxs5Tf9.js","./chevron-down-vguALCSX.js","./chevron-right-DND12YKW.js","./search-DQyZo8im.js","./settings-xa_4DC6i.js","./spinner--mCkS-8r.js","./threads-CbVN7W51.js","./user-profile-cqTW1cHH.js","./visibility-on-BsZOuBEH.js","./warning-DNnCy5FR.js","./Button.stories-C34AcO6K.js","./IconButton.stories-Kt8Z7I-O.js","./Dropdown.stories-D_TlQ6US.js","./Dropdown-DTtACc2Q.css","./Action.stories-DTjW96ks.js","./Action-BnShWVrx.js","./index-4or38LtJ.js","./index-CGa_gRws.js","./index-C8xBnYIG.js","./index-BXwbELbV.js","./index-Ksfxd92j.js","./Text-DZrEBsw6.js","./Text-CJ1qRzt7.css","./Action-BdUqm_WT.css","./Checkbox.stories-bVpTzKvF.js","./Checkbox-CiKmyzre.js","./Checkbox-BH8Av3st.css","./EditInPlace.stories-tK8qCiZC.js","./Message-t35Ysetp.js","./Label-BsNBFg9B.js","./Label-B1mKVwiw.css","./InlineSpinner-DDpdhuC2.js","./InlineSpinner-D_6da_B5.css","./EditInPlace-BZjvBnvF.css","./MFA.stories-CdxvnV8S.js","./MFA-BqVpayht.js","./MFA-olUceP-x.css","./Password.stories-xpc97ble.js","./Password-BPLQ51Y-.js","./Radio.stories-DaNVXt2N.js","./Radio-2VunTFL7.js","./Radio-DlPAN7Bx.css","./Text.stories-BPCgZ96x.js","./Toggle.stories--3jyE05F.js","./Toggle-BRCP4wr-.js","./Toggle-CNr3UW_e.css","./Form.stories--cHTjAzR.js","./PasswordForm.stories-njJrHlv5.js","./Progress-wZmvUnkq.js","./Progress-MMKb-Gqu.css","./Glass.stories-D0SeEDtf.js","./Glass-wf6Qw4nq.css","./Icon.stories--8crEGuF.js","./IndicatorIcon.stories-B7G9_a2o.js","./InlineSpinner.stories-CltYLVR9.js","./Link.stories-BZPSqP68.js","./Link-BgRMLc0G.css","./ContextMenu.stories-C6bRKAQB.js","./index-JSxJwvkz.js","./FloatingMenu-Dc89G4Nf.js","./FloatingMenu-BDo-TlpM.css","./DrawerMenu-BNILBemh.js","./DrawerMenu-CGcQbDnp.css","./MenuItem-BFo5ba9w.js","./MenuItem-Bu829Vy7.css","./Separator-B6sIYtjz.js","./Separator-BT_CUzhe.css","./DrawerMenu.stories-Bfqecup3.js","./FloatingMenu.stories-bTTpHRmg.js","./Menu.stories-BT7voQpJ.js","./MenuItem.stories-DJ1vpGR1.js","./ToggleMenuItem.stories-DDnlXtgb.js","./NavBar.stories-CZtOku47.js","./NavItem-CZaXsd0a.js","./NavItem-D86QAt32.css","./NavItem.stories-C3HoG-Mb.js","./Progress.stories-BjCxvhnZ.js","./ReleaseAnnouncement.stories-DA7uhYWC.js","./ReleaseAnnouncement-DDl8J4p8.css","./Search.stories-DoNIoJie.js","./Search-BDRF8W7B.css","./Separator.stories-iz8p05W5.js","./Toast.stories-C23ZRf6c.js","./Toast-YaIeoY4p.css","./Tooltip.stories-DfHa5l-o.js","./Heading.stories-BvVZRN6H.js","./Text.stories-SkRabSCE.js","./entry-preview-CI_Ec58I.js","./chunk-XP5HYGXS-BGCqD1aY.js","./entry-preview-docs-CfC3f9x0.js","./index-CidnEmUr.js","./preview-BhhEZcNS.js","./index-D-8MO0q_.js","./preview-ncvtW_hb.js","./index-DrFu-skq.js","./preview-BWzBA1C2.js","./preview-CA0YOuCz.js","./preview-BbY9cs0x.js","./preview-BpCs1Hus.css"])))=>i.map(i=>d[i]); -import"../sb-preview/runtime.js";(function(){const _=document.createElement("link").relList;if(_&&_.supports&&_.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))a(o);new MutationObserver(o=>{for(const e of o)if(e.type==="childList")for(const s of e.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&a(s)}).observe(document,{childList:!0,subtree:!0});function m(o){const e={};return o.integrity&&(e.integrity=o.integrity),o.referrerPolicy&&(e.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?e.credentials="include":o.crossOrigin==="anonymous"?e.credentials="omit":e.credentials="same-origin",e}function a(o){if(o.ep)return;o.ep=!0;const e=m(o);fetch(o.href,e)}})();const T="modulepreload",I=function(r,_){return new URL(r,_).href},O={},t=function(_,m,a){let o=Promise.resolve();if(m&&m.length>0){const s=document.getElementsByTagName("link"),i=document.querySelector("meta[property=csp-nonce]"),d=i?.nonce||i?.getAttribute("nonce");o=Promise.allSettled(m.map(n=>{if(n=I(n,a),n in O)return;O[n]=!0;const p=n.endsWith(".css"),R=p?'[rel="stylesheet"]':"";if(!!a)for(let u=s.length-1;u>=0;u--){const E=s[u];if(E.href===n&&(!p||E.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${n}"]${R}`))return;const c=document.createElement("link");if(c.rel=p?"stylesheet":T,p||(c.as="script"),c.crossOrigin="",c.href=n,d&&c.setAttribute("nonce",d),document.head.appendChild(c),p)return new Promise((u,E)=>{c.addEventListener("load",u),c.addEventListener("error",()=>E(new Error(`Unable to preload CSS for ${n}`)))})}))}function e(s){const i=new Event("vite:preloadError",{cancelable:!0});if(i.payload=s,window.dispatchEvent(i),!i.defaultPrevented)throw s}return o.then(s=>{for(const i of s||[])i.status==="rejected"&&e(i.reason);return _().catch(e)})},{createBrowserChannel:L}=__STORYBOOK_MODULE_CHANNELS__,{addons:P}=__STORYBOOK_MODULE_PREVIEW_API__,l=L({page:"preview"});P.setChannel(l);window.__STORYBOOK_ADDONS_CHANNEL__=l;window.CONFIG_TYPE==="DEVELOPMENT"&&(window.__STORYBOOK_SERVER_CHANNEL__=l);const y={"./src/components/Alert/Alert.stories.tsx":async()=>t(()=>import("./Alert.stories-PBNjduBZ.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21]),import.meta.url),"./src/components/Avatar/Avatar.stories.tsx":async()=>t(()=>import("./Avatar.stories-Dqdk1TyC.js"),__vite__mapDeps([22,1,2,23,4,24]),import.meta.url),"./src/components/Avatar/AvatarStack.stories.tsx":async()=>t(()=>import("./AvatarStack.stories-DFbc-d2p.js"),__vite__mapDeps([25,1,2,4,23,24]),import.meta.url),"./src/components/Badge/Badge.stories.tsx":async()=>t(()=>import("./Badge.stories-BHGShZoQ.js"),__vite__mapDeps([26,1,2,4,11,12,27]),import.meta.url),"./src/components/Button/ActionButton.stories.tsx":async()=>t(()=>import("./ActionButton.stories-Dc7Ppv78.js"),__vite__mapDeps([28,1,2,29,30,31,32,33,7,34,35,36,9,8,37,38,39,40,41,42,43,3,4,5,6,16,17,18,19]),import.meta.url),"./src/components/Button/Button.stories.tsx":async()=>t(()=>import("./Button.stories-C34AcO6K.js"),__vite__mapDeps([44,29,3,1,2,4,5,6,30,31,32,33,7,34,35,36,9,8,37,38,39,40,41,42,43]),import.meta.url),"./src/components/Button/IconButton/IconButton.stories.tsx":async()=>t(()=>import("./IconButton.stories-Kt8Z7I-O.js"),__vite__mapDeps([45,1,2,29,13,4,5,14,15,16,17,18,19,20,41]),import.meta.url),"./src/components/Dropdown/Dropdown.stories.tsx":async()=>t(()=>import("./Dropdown.stories-D_TlQ6US.js"),__vite__mapDeps([46,1,2,35,34,8,4,17,18,29,47]),import.meta.url),"./src/components/Form/Controls/Action/Action.stories.tsx":async()=>t(()=>import("./Action.stories-DTjW96ks.js"),__vite__mapDeps([48,1,2,30,31,32,33,7,34,35,36,9,8,37,38,39,40,41,42,43,16,17,18,4,19,49,50,51,52,53,54,55,56,57]),import.meta.url),"./src/components/Form/Controls/Checkbox/Checkbox.stories.tsx":async()=>t(()=>import("./Checkbox.stories-bVpTzKvF.js"),__vite__mapDeps([58,1,2,59,4,34,50,51,52,53,54,18,60]),import.meta.url),"./src/components/Form/Controls/EditInPlace/EditInPlace.stories.tsx":async()=>t(()=>import("./EditInPlace.stories-tK8qCiZC.js"),__vite__mapDeps([61,1,2,29,62,50,51,52,53,54,18,63,4,64,33,8,65,39,66,16,17,19,34,9,55,56,3,5,6,67]),import.meta.url),"./src/components/Form/Controls/MFA/MFA.stories.tsx":async()=>t(()=>import("./MFA.stories-CdxvnV8S.js"),__vite__mapDeps([68,1,2,69,4,50,51,52,53,54,18,70]),import.meta.url),"./src/components/Form/Controls/Password/Password.stories.tsx":async()=>t(()=>import("./Password.stories-xpc97ble.js"),__vite__mapDeps([71,1,2,16,17,18,4,19,29,72,50,51,52,53,54,42,49,55,56,57]),import.meta.url),"./src/components/Form/Controls/Radio/Radio.stories.tsx":async()=>t(()=>import("./Radio.stories-DaNVXt2N.js"),__vite__mapDeps([73,1,2,74,4,50,51,52,53,54,18,75]),import.meta.url),"./src/components/Form/Controls/Text/Text.stories.tsx":async()=>t(()=>import("./Text.stories-BPCgZ96x.js"),__vite__mapDeps([76,1,2,55,50,51,52,53,54,18,4,56]),import.meta.url),"./src/components/Form/Controls/Toggle/Toggle.stories.tsx":async()=>t(()=>import("./Toggle.stories--3jyE05F.js"),__vite__mapDeps([77,78,1,2,4,50,51,52,53,54,18,79]),import.meta.url),"./src/components/Form/Form.stories.tsx":async()=>t(()=>import("./Form.stories--cHTjAzR.js"),__vite__mapDeps([80,1,2,16,17,18,4,19,62,50,51,52,53,54,63,64,33,8,65,39,66,55,56,72,42,49,57,69,70,59,34,60,74,75,78,79,3,5,6]),import.meta.url),"./src/components/Form/PasswordForm.stories.tsx":async()=>t(()=>import("./PasswordForm.stories-njJrHlv5.js"),__vite__mapDeps([81,1,2,43,82,4,53,54,18,52,83,16,17,19,62,50,51,63,64,33,8,65,39,66,72,42,49,55,56,57]),import.meta.url),"./src/components/Glass/Glass.stories.tsx":async()=>t(()=>import("./Glass.stories-D0SeEDtf.js"),__vite__mapDeps([84,1,2,4,10,11,12,85]),import.meta.url),"./src/components/Icon/Icon.stories.tsx":async()=>t(()=>import("./Icon.stories--8crEGuF.js"),__vite__mapDeps([86,1,2,40]),import.meta.url),"./src/components/Icon/IndicatorIcon/IndicatorIcon.stories.tsx":async()=>t(()=>import("./IndicatorIcon.stories-B7G9_a2o.js"),__vite__mapDeps([87,1,2,29,14,4,15,40]),import.meta.url),"./src/components/InlineSpinner/InlineSpinner.stories.tsx":async()=>t(()=>import("./InlineSpinner.stories-CltYLVR9.js"),__vite__mapDeps([88,65,1,2,39,66]),import.meta.url),"./src/components/Link/Link.stories.tsx":async()=>t(()=>import("./Link.stories-BZPSqP68.js"),__vite__mapDeps([89,1,2,4,90]),import.meta.url),"./src/components/Menu/ContextMenu.stories.tsx":async()=>t(()=>import("./ContextMenu.stories-C6bRKAQB.js"),__vite__mapDeps([91,1,2,41,31,51,54,18,52,92,53,17,93,4,10,11,12,94,95,96,97,36,98,99,100]),import.meta.url),"./src/components/Menu/DrawerMenu.stories.tsx":async()=>t(()=>import("./DrawerMenu.stories-Bfqecup3.js"),__vite__mapDeps([101,1,2,41,31,95,4,96,97,10,11,12,36,52,98,99,54,18,17,100]),import.meta.url),"./src/components/Menu/FloatingMenu.stories.tsx":async()=>t(()=>import("./FloatingMenu.stories-bTTpHRmg.js"),__vite__mapDeps([102,1,2,41,31,93,4,10,11,12,94,97,36,52,98,99,54,18,17,100]),import.meta.url),"./src/components/Menu/Menu.stories.tsx":async()=>t(()=>import("./Menu.stories-BT7voQpJ.js"),__vite__mapDeps([103,1,2,41,31,51,52,92,53,54,18,17,93,4,10,11,12,94,95,96,97,36,98,99,100,3,5,6]),import.meta.url),"./src/components/Menu/MenuItem.stories.tsx":async()=>t(()=>import("./MenuItem.stories-DJ1vpGR1.js"),__vite__mapDeps([104,1,2,32,38,97,4,10,11,12,36,52,98]),import.meta.url),"./src/components/Menu/ToggleMenuItem.stories.tsx":async()=>t(()=>import("./ToggleMenuItem.stories-DDnlXtgb.js"),__vite__mapDeps([105,1,2,32,97,4,10,11,12,36,52,98,78,50,51,53,54,18,79]),import.meta.url),"./src/components/Nav/NavBar.stories.tsx":async()=>t(()=>import("./NavBar.stories-CZtOku47.js"),__vite__mapDeps([106,1,2,107,4,108]),import.meta.url),"./src/components/Nav/NavItem.stories.tsx":async()=>t(()=>import("./NavItem.stories-C3HoG-Mb.js"),__vite__mapDeps([109,1,2,107,4,108]),import.meta.url),"./src/components/Progress/Progress.stories.tsx":async()=>t(()=>import("./Progress.stories-BjCxvhnZ.js"),__vite__mapDeps([110,82,1,2,4,53,54,18,52,83]),import.meta.url),"./src/components/ReleaseAnnouncement/ReleaseAnnouncement.stories.tsx":async()=>t(()=>import("./ReleaseAnnouncement.stories-DA7uhYWC.js"),__vite__mapDeps([111,1,2,17,18,10,11,4,12,3,5,6,112]),import.meta.url),"./src/components/Search/Search.stories.tsx":async()=>t(()=>import("./Search.stories-DoNIoJie.js"),__vite__mapDeps([113,1,2,4,37,63,50,51,52,53,54,18,64,114]),import.meta.url),"./src/components/Separator/Separator.stories.tsx":async()=>t(()=>import("./Separator.stories-iz8p05W5.js"),__vite__mapDeps([115,99,1,2,4,54,18,52,17,100]),import.meta.url),"./src/components/Toast/Toast.stories.tsx":async()=>t(()=>import("./Toast.stories-C23ZRf6c.js"),__vite__mapDeps([116,1,2,4,117]),import.meta.url),"./src/components/Tooltip/Tooltip.stories.tsx":async()=>t(()=>import("./Tooltip.stories-DfHa5l-o.js"),__vite__mapDeps([118,1,2,16,17,18,4,19,41,13,5,14,15,20]),import.meta.url),"./src/components/Typography/Heading.stories.tsx":async()=>t(()=>import("./Heading.stories-BvVZRN6H.js"),__vite__mapDeps([119,1,2,11,4,12,10]),import.meta.url),"./src/components/Typography/Text.stories.tsx":async()=>t(()=>import("./Text.stories-SkRabSCE.js"),__vite__mapDeps([120,10,1,2,11,4,12]),import.meta.url)};async function A(r){return y[r]()}const{composeConfigs:v,PreviewWeb:D,ClientApi:g}=__STORYBOOK_MODULE_PREVIEW_API__,V=async(r=[])=>{const _=await Promise.all([r[0]??t(()=>import("./entry-preview-CI_Ec58I.js"),__vite__mapDeps([121,122,2,18]),import.meta.url),r[1]??t(()=>import("./entry-preview-docs-CfC3f9x0.js"),__vite__mapDeps([123,122,124,2]),import.meta.url),r[2]??t(()=>import("./preview-BhhEZcNS.js"),__vite__mapDeps([125,126]),import.meta.url),r[3]??t(()=>import("./preview-uky1k3DE.js"),[],import.meta.url),r[4]??t(()=>import("./preview-DHPc-V4N.js"),[],import.meta.url),r[5]??t(()=>import("./preview-ncvtW_hb.js"),__vite__mapDeps([127,128]),import.meta.url),r[6]??t(()=>import("./preview-DYzi3Z2p.js"),[],import.meta.url),r[7]??t(()=>import("./preview-CuLlOZat.js"),[],import.meta.url),r[8]??t(()=>import("./preview-BWzBA1C2.js"),__vite__mapDeps([129,128]),import.meta.url),r[9]??t(()=>import("./preview-caVMbCIR.js"),[],import.meta.url),r[10]??t(()=>import("./preview-CA0YOuCz.js"),__vite__mapDeps([130,29]),import.meta.url),r[11]??t(()=>import("./preview-CVgpLj3b.js"),[],import.meta.url),r[12]??t(()=>import("./preview-BbY9cs0x.js"),__vite__mapDeps([131,2,132]),import.meta.url)]);return v(_)};window.__STORYBOOK_PREVIEW__=window.__STORYBOOK_PREVIEW__||new D(A,V);window.__STORYBOOK_STORY_STORE__=window.__STORYBOOK_STORY_STORE__||window.__STORYBOOK_PREVIEW__.storyStore;export{t as _}; +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./Alert.stories-CZZsTik8.js","./jsx-runtime-DR9Q75dM.js","./index-DRjF_FHU.js","./Button-BORixq-h.js","./index-lhGYx47h.js","./UnstyledButton-DuxpNl0e.js","./Button-W0jf5teY.css","./info-D9sKA_Xt.js","./error-DOy7ZFuJ.js","./close-CWATPeIo.js","./Text-BvzksikX.js","./Typography-DzhKoIWt.js","./Typography-CFo2KqHV.css","./IconButton-Bf1MsgYV.js","./IndicatorIcon-CKMK3E77.js","./IndicatorIcon-Df2gvoto.css","./Tooltip-D2McGlOP.js","./floating-ui.react-CSvGZjCC.js","./index-BvEl7W6R.js","./Tooltip-Bx3q_cph.css","./IconButton-X8Xpz74a.css","./Alert-RAKRA8iu.css","./Avatar.stories-Dqdk1TyC.js","./Avatar-BPJ7Tfaa.js","./Avatar-CE8ocXGL.css","./AvatarStack.stories-DFbc-d2p.js","./Badge.stories-BHGShZoQ.js","./Badge-DHQHyvgX.css","./ActionButton.stories-D3eHjSdU.js","./index-JRK_GaCU.js","./index-C87-hJvQ.js","./notifications-BEKrtwGv.js","./extensions-DRIHxRsb.js","./check-circle-solid-DvGH8qX5.js","./check-BWxs5Tf9.js","./chevron-down-vguALCSX.js","./chevron-right-DND12YKW.js","./search-DQyZo8im.js","./settings-xa_4DC6i.js","./spinner--mCkS-8r.js","./threads-CbVN7W51.js","./user-profile-cqTW1cHH.js","./visibility-on-BsZOuBEH.js","./warning-DNnCy5FR.js","./Button.stories-C34AcO6K.js","./IconButton.stories-DXn3ooYc.js","./Dropdown.stories-DSpAra56.js","./Dropdown-DTtACc2Q.css","./Action.stories-PfdA3Wpp.js","./Action-CwOAv2fk.js","./index-4or38LtJ.js","./index-CGa_gRws.js","./index-C8xBnYIG.js","./index-BXwbELbV.js","./index-Ksfxd92j.js","./Text-DZrEBsw6.js","./Text-CJ1qRzt7.css","./Action-BdUqm_WT.css","./Checkbox.stories-bVpTzKvF.js","./Checkbox-CiKmyzre.js","./Checkbox-BH8Av3st.css","./EditInPlace.stories-ZKzHSOvw.js","./Message-t35Ysetp.js","./Label-BsNBFg9B.js","./Label-B1mKVwiw.css","./InlineSpinner-DDpdhuC2.js","./InlineSpinner-D_6da_B5.css","./EditInPlace-BZjvBnvF.css","./MFA.stories-BgCa2twE.js","./MFA-ECyXoHb1.js","./MFA-olUceP-x.css","./Password.stories-Cvffqo9q.js","./Password-Dm026fYh.js","./Radio.stories-DaNVXt2N.js","./Radio-2VunTFL7.js","./Radio-DlPAN7Bx.css","./Text.stories-BPCgZ96x.js","./Toggle.stories--3jyE05F.js","./Toggle-BRCP4wr-.js","./Toggle-CNr3UW_e.css","./Form.stories-Bn4-T6XU.js","./PasswordForm.stories-Dnc5DYrq.js","./Progress-DaTknHqR.js","./Progress-MMKb-Gqu.css","./Glass.stories-D0SeEDtf.js","./Glass-wf6Qw4nq.css","./Icon.stories--8crEGuF.js","./IndicatorIcon.stories-B7G9_a2o.js","./InlineSpinner.stories-CltYLVR9.js","./Link.stories-DKUKuDDV.js","./Link-BgRMLc0G.css","./ContextMenu.stories-CxHKJP9E.js","./index-Dbt-v4y0.js","./FloatingMenu-Dc89G4Nf.js","./FloatingMenu-BDo-TlpM.css","./DrawerMenu-BNILBemh.js","./DrawerMenu-CGcQbDnp.css","./MenuItem-YyrVQu2n.js","./MenuItem-Bu829Vy7.css","./Separator-BbJs_Bbv.js","./Separator-BT_CUzhe.css","./DrawerMenu.stories-CuBmyegk.js","./FloatingMenu.stories-CVZ8ATHp.js","./Menu.stories-h49MhKU-.js","./MenuItem.stories-DyAT8czh.js","./ToggleMenuItem.stories-BVbICedI.js","./NavBar.stories-CZtOku47.js","./NavItem-CZaXsd0a.js","./NavItem-D86QAt32.css","./NavItem.stories-C3HoG-Mb.js","./Progress.stories-DQdxsRQA.js","./ReleaseAnnouncement.stories-BcQDEAeD.js","./ReleaseAnnouncement-DDl8J4p8.css","./Search.stories-DoNIoJie.js","./Search-BDRF8W7B.css","./Separator.stories-CRxuvXnz.js","./Toast.stories-C23ZRf6c.js","./Toast-YaIeoY4p.css","./Tooltip.stories-D6PgfVTA.js","./Heading.stories-BvVZRN6H.js","./Text.stories-SkRabSCE.js","./entry-preview-CmGtEz1u.js","./chunk-XP5HYGXS-BGCqD1aY.js","./entry-preview-docs-CfC3f9x0.js","./index-CidnEmUr.js","./preview-BhhEZcNS.js","./index-D-8MO0q_.js","./preview-ncvtW_hb.js","./index-DrFu-skq.js","./preview-BWzBA1C2.js","./preview-CA0YOuCz.js","./preview-BbY9cs0x.js","./preview-BpCs1Hus.css"])))=>i.map(i=>d[i]); +import"../sb-preview/runtime.js";(function(){const _=document.createElement("link").relList;if(_&&_.supports&&_.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))a(o);new MutationObserver(o=>{for(const e of o)if(e.type==="childList")for(const s of e.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&a(s)}).observe(document,{childList:!0,subtree:!0});function m(o){const e={};return o.integrity&&(e.integrity=o.integrity),o.referrerPolicy&&(e.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?e.credentials="include":o.crossOrigin==="anonymous"?e.credentials="omit":e.credentials="same-origin",e}function a(o){if(o.ep)return;o.ep=!0;const e=m(o);fetch(o.href,e)}})();const T="modulepreload",I=function(r,_){return new URL(r,_).href},O={},t=function(_,m,a){let o=Promise.resolve();if(m&&m.length>0){const s=document.getElementsByTagName("link"),i=document.querySelector("meta[property=csp-nonce]"),d=i?.nonce||i?.getAttribute("nonce");o=Promise.allSettled(m.map(n=>{if(n=I(n,a),n in O)return;O[n]=!0;const p=n.endsWith(".css"),R=p?'[rel="stylesheet"]':"";if(!!a)for(let u=s.length-1;u>=0;u--){const E=s[u];if(E.href===n&&(!p||E.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${n}"]${R}`))return;const c=document.createElement("link");if(c.rel=p?"stylesheet":T,p||(c.as="script"),c.crossOrigin="",c.href=n,d&&c.setAttribute("nonce",d),document.head.appendChild(c),p)return new Promise((u,E)=>{c.addEventListener("load",u),c.addEventListener("error",()=>E(new Error(`Unable to preload CSS for ${n}`)))})}))}function e(s){const i=new Event("vite:preloadError",{cancelable:!0});if(i.payload=s,window.dispatchEvent(i),!i.defaultPrevented)throw s}return o.then(s=>{for(const i of s||[])i.status==="rejected"&&e(i.reason);return _().catch(e)})},{createBrowserChannel:L}=__STORYBOOK_MODULE_CHANNELS__,{addons:P}=__STORYBOOK_MODULE_PREVIEW_API__,l=L({page:"preview"});P.setChannel(l);window.__STORYBOOK_ADDONS_CHANNEL__=l;window.CONFIG_TYPE==="DEVELOPMENT"&&(window.__STORYBOOK_SERVER_CHANNEL__=l);const y={"./src/components/Alert/Alert.stories.tsx":async()=>t(()=>import("./Alert.stories-CZZsTik8.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21]),import.meta.url),"./src/components/Avatar/Avatar.stories.tsx":async()=>t(()=>import("./Avatar.stories-Dqdk1TyC.js"),__vite__mapDeps([22,1,2,23,4,24]),import.meta.url),"./src/components/Avatar/AvatarStack.stories.tsx":async()=>t(()=>import("./AvatarStack.stories-DFbc-d2p.js"),__vite__mapDeps([25,1,2,4,23,24]),import.meta.url),"./src/components/Badge/Badge.stories.tsx":async()=>t(()=>import("./Badge.stories-BHGShZoQ.js"),__vite__mapDeps([26,1,2,4,11,12,27]),import.meta.url),"./src/components/Button/ActionButton.stories.tsx":async()=>t(()=>import("./ActionButton.stories-D3eHjSdU.js"),__vite__mapDeps([28,1,2,29,30,31,32,33,7,34,35,36,9,8,37,38,39,40,41,42,43,3,4,5,6,16,17,18,19]),import.meta.url),"./src/components/Button/Button.stories.tsx":async()=>t(()=>import("./Button.stories-C34AcO6K.js"),__vite__mapDeps([44,29,3,1,2,4,5,6,30,31,32,33,7,34,35,36,9,8,37,38,39,40,41,42,43]),import.meta.url),"./src/components/Button/IconButton/IconButton.stories.tsx":async()=>t(()=>import("./IconButton.stories-DXn3ooYc.js"),__vite__mapDeps([45,1,2,29,13,4,5,14,15,16,17,18,19,20,41]),import.meta.url),"./src/components/Dropdown/Dropdown.stories.tsx":async()=>t(()=>import("./Dropdown.stories-DSpAra56.js"),__vite__mapDeps([46,1,2,35,34,8,4,17,18,29,47]),import.meta.url),"./src/components/Form/Controls/Action/Action.stories.tsx":async()=>t(()=>import("./Action.stories-PfdA3Wpp.js"),__vite__mapDeps([48,1,2,30,31,32,33,7,34,35,36,9,8,37,38,39,40,41,42,43,16,17,18,4,19,49,50,51,52,53,54,55,56,57]),import.meta.url),"./src/components/Form/Controls/Checkbox/Checkbox.stories.tsx":async()=>t(()=>import("./Checkbox.stories-bVpTzKvF.js"),__vite__mapDeps([58,1,2,59,4,34,50,51,52,53,54,18,60]),import.meta.url),"./src/components/Form/Controls/EditInPlace/EditInPlace.stories.tsx":async()=>t(()=>import("./EditInPlace.stories-ZKzHSOvw.js"),__vite__mapDeps([61,1,2,29,62,50,51,52,53,54,18,63,4,64,33,8,65,39,66,16,17,19,34,9,55,56,3,5,6,67]),import.meta.url),"./src/components/Form/Controls/MFA/MFA.stories.tsx":async()=>t(()=>import("./MFA.stories-BgCa2twE.js"),__vite__mapDeps([68,1,2,69,4,50,51,52,53,54,18,70]),import.meta.url),"./src/components/Form/Controls/Password/Password.stories.tsx":async()=>t(()=>import("./Password.stories-Cvffqo9q.js"),__vite__mapDeps([71,1,2,16,17,18,4,19,29,72,50,51,52,53,54,42,49,55,56,57]),import.meta.url),"./src/components/Form/Controls/Radio/Radio.stories.tsx":async()=>t(()=>import("./Radio.stories-DaNVXt2N.js"),__vite__mapDeps([73,1,2,74,4,50,51,52,53,54,18,75]),import.meta.url),"./src/components/Form/Controls/Text/Text.stories.tsx":async()=>t(()=>import("./Text.stories-BPCgZ96x.js"),__vite__mapDeps([76,1,2,55,50,51,52,53,54,18,4,56]),import.meta.url),"./src/components/Form/Controls/Toggle/Toggle.stories.tsx":async()=>t(()=>import("./Toggle.stories--3jyE05F.js"),__vite__mapDeps([77,78,1,2,4,50,51,52,53,54,18,79]),import.meta.url),"./src/components/Form/Form.stories.tsx":async()=>t(()=>import("./Form.stories-Bn4-T6XU.js"),__vite__mapDeps([80,1,2,16,17,18,4,19,62,50,51,52,53,54,63,64,33,8,65,39,66,55,56,72,42,49,57,69,70,59,34,60,74,75,78,79,3,5,6]),import.meta.url),"./src/components/Form/PasswordForm.stories.tsx":async()=>t(()=>import("./PasswordForm.stories-Dnc5DYrq.js"),__vite__mapDeps([81,1,2,43,82,4,53,54,18,52,83,16,17,19,62,50,51,63,64,33,8,65,39,66,72,42,49,55,56,57]),import.meta.url),"./src/components/Glass/Glass.stories.tsx":async()=>t(()=>import("./Glass.stories-D0SeEDtf.js"),__vite__mapDeps([84,1,2,4,10,11,12,85]),import.meta.url),"./src/components/Icon/Icon.stories.tsx":async()=>t(()=>import("./Icon.stories--8crEGuF.js"),__vite__mapDeps([86,1,2,40]),import.meta.url),"./src/components/Icon/IndicatorIcon/IndicatorIcon.stories.tsx":async()=>t(()=>import("./IndicatorIcon.stories-B7G9_a2o.js"),__vite__mapDeps([87,1,2,29,14,4,15,40]),import.meta.url),"./src/components/InlineSpinner/InlineSpinner.stories.tsx":async()=>t(()=>import("./InlineSpinner.stories-CltYLVR9.js"),__vite__mapDeps([88,65,1,2,39,66]),import.meta.url),"./src/components/Link/Link.stories.tsx":async()=>t(()=>import("./Link.stories-DKUKuDDV.js"),__vite__mapDeps([89,1,2,4,90]),import.meta.url),"./src/components/Menu/ContextMenu.stories.tsx":async()=>t(()=>import("./ContextMenu.stories-CxHKJP9E.js"),__vite__mapDeps([91,1,2,41,31,51,54,18,52,92,53,17,93,4,10,11,12,94,95,96,97,36,98,99,100]),import.meta.url),"./src/components/Menu/DrawerMenu.stories.tsx":async()=>t(()=>import("./DrawerMenu.stories-CuBmyegk.js"),__vite__mapDeps([101,1,2,41,31,95,4,96,97,10,11,12,36,52,98,99,54,18,17,100]),import.meta.url),"./src/components/Menu/FloatingMenu.stories.tsx":async()=>t(()=>import("./FloatingMenu.stories-CVZ8ATHp.js"),__vite__mapDeps([102,1,2,41,31,93,4,10,11,12,94,97,36,52,98,99,54,18,17,100]),import.meta.url),"./src/components/Menu/Menu.stories.tsx":async()=>t(()=>import("./Menu.stories-h49MhKU-.js"),__vite__mapDeps([103,1,2,41,31,51,52,92,53,54,18,17,93,4,10,11,12,94,95,96,97,36,98,99,100,3,5,6]),import.meta.url),"./src/components/Menu/MenuItem.stories.tsx":async()=>t(()=>import("./MenuItem.stories-DyAT8czh.js"),__vite__mapDeps([104,1,2,32,38,97,4,10,11,12,36,52,98]),import.meta.url),"./src/components/Menu/ToggleMenuItem.stories.tsx":async()=>t(()=>import("./ToggleMenuItem.stories-BVbICedI.js"),__vite__mapDeps([105,1,2,32,97,4,10,11,12,36,52,98,78,50,51,53,54,18,79]),import.meta.url),"./src/components/Nav/NavBar.stories.tsx":async()=>t(()=>import("./NavBar.stories-CZtOku47.js"),__vite__mapDeps([106,1,2,107,4,108]),import.meta.url),"./src/components/Nav/NavItem.stories.tsx":async()=>t(()=>import("./NavItem.stories-C3HoG-Mb.js"),__vite__mapDeps([109,1,2,107,4,108]),import.meta.url),"./src/components/Progress/Progress.stories.tsx":async()=>t(()=>import("./Progress.stories-DQdxsRQA.js"),__vite__mapDeps([110,82,1,2,4,53,54,18,52,83]),import.meta.url),"./src/components/ReleaseAnnouncement/ReleaseAnnouncement.stories.tsx":async()=>t(()=>import("./ReleaseAnnouncement.stories-BcQDEAeD.js"),__vite__mapDeps([111,1,2,17,18,10,11,4,12,3,5,6,112]),import.meta.url),"./src/components/Search/Search.stories.tsx":async()=>t(()=>import("./Search.stories-DoNIoJie.js"),__vite__mapDeps([113,1,2,4,37,63,50,51,52,53,54,18,64,114]),import.meta.url),"./src/components/Separator/Separator.stories.tsx":async()=>t(()=>import("./Separator.stories-CRxuvXnz.js"),__vite__mapDeps([115,99,1,2,4,54,18,52,17,100]),import.meta.url),"./src/components/Toast/Toast.stories.tsx":async()=>t(()=>import("./Toast.stories-C23ZRf6c.js"),__vite__mapDeps([116,1,2,4,117]),import.meta.url),"./src/components/Tooltip/Tooltip.stories.tsx":async()=>t(()=>import("./Tooltip.stories-D6PgfVTA.js"),__vite__mapDeps([118,1,2,16,17,18,4,19,41,13,5,14,15,20]),import.meta.url),"./src/components/Typography/Heading.stories.tsx":async()=>t(()=>import("./Heading.stories-BvVZRN6H.js"),__vite__mapDeps([119,1,2,11,4,12,10]),import.meta.url),"./src/components/Typography/Text.stories.tsx":async()=>t(()=>import("./Text.stories-SkRabSCE.js"),__vite__mapDeps([120,10,1,2,11,4,12]),import.meta.url)};async function A(r){return y[r]()}const{composeConfigs:v,PreviewWeb:D,ClientApi:g}=__STORYBOOK_MODULE_PREVIEW_API__,V=async(r=[])=>{const _=await Promise.all([r[0]??t(()=>import("./entry-preview-CmGtEz1u.js"),__vite__mapDeps([121,122,2,18]),import.meta.url),r[1]??t(()=>import("./entry-preview-docs-CfC3f9x0.js"),__vite__mapDeps([123,122,124,2]),import.meta.url),r[2]??t(()=>import("./preview-BhhEZcNS.js"),__vite__mapDeps([125,126]),import.meta.url),r[3]??t(()=>import("./preview-fOt-hspA.js"),[],import.meta.url),r[4]??t(()=>import("./preview-DHPc-V4N.js"),[],import.meta.url),r[5]??t(()=>import("./preview-ncvtW_hb.js"),__vite__mapDeps([127,128]),import.meta.url),r[6]??t(()=>import("./preview-DYzi3Z2p.js"),[],import.meta.url),r[7]??t(()=>import("./preview-CuLlOZat.js"),[],import.meta.url),r[8]??t(()=>import("./preview-BWzBA1C2.js"),__vite__mapDeps([129,128]),import.meta.url),r[9]??t(()=>import("./preview-caVMbCIR.js"),[],import.meta.url),r[10]??t(()=>import("./preview-CA0YOuCz.js"),__vite__mapDeps([130,29]),import.meta.url),r[11]??t(()=>import("./preview-CVgpLj3b.js"),[],import.meta.url),r[12]??t(()=>import("./preview-BbY9cs0x.js"),__vite__mapDeps([131,2,132]),import.meta.url)]);return v(_)};window.__STORYBOOK_PREVIEW__=window.__STORYBOOK_PREVIEW__||new D(A,V);window.__STORYBOOK_STORY_STORE__=window.__STORYBOOK_STORY_STORE__||window.__STORYBOOK_PREVIEW__.storyStore;export{t as _}; diff --git a/assets/index-JSxJwvkz.js b/assets/index-Dbt-v4y0.js similarity index 99% rename from assets/index-JSxJwvkz.js rename to assets/index-Dbt-v4y0.js index 573191d3..cb2b62a7 100644 --- a/assets/index-JSxJwvkz.js +++ b/assets/index-Dbt-v4y0.js @@ -1,4 +1,4 @@ -import{R as S,r as i}from"./index-DRjF_FHU.js";import{c as I,a as me,u as at}from"./index-CGa_gRws.js";import{c as lt,a as Wo}from"./index-BXwbELbV.js";import{u as X,S as it,c as Uo}from"./index-C8xBnYIG.js";import{j as E}from"./jsx-runtime-DR9Q75dM.js";import{P as H,d as Bt}from"./index-Ksfxd92j.js";import{q as Ho,c as Ko,o as Yo,s as Go,n as zo,f as Vo,r as Xo,d as qo,t as Zo}from"./floating-ui.react-CACRriTf.js";import{F as Ln,r as Qo}from"./index-BvEl7W6R.js";function Fn(e){const t=e+"CollectionProvider",[n,r]=lt(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),c=y=>{const{scope:h,children:l}=y,g=S.useRef(null),p=S.useRef(new Map).current;return E.jsx(o,{scope:h,itemMap:p,collectionRef:g,children:l})};c.displayName=t;const s=e+"CollectionSlot",v=S.forwardRef((y,h)=>{const{scope:l,children:g}=y,p=a(s,l),C=X(h,p.collectionRef);return E.jsx(it,{ref:C,children:g})});v.displayName=s;const u=e+"CollectionItemSlot",f="data-radix-collection-item",d=S.forwardRef((y,h)=>{const{scope:l,children:g,...p}=y,C=S.useRef(null),R=X(h,C),b=a(u,l);return S.useEffect(()=>(b.itemMap.set(C,{ref:C,...p}),()=>void b.itemMap.delete(C))),E.jsx(it,{[f]:"",ref:R,children:g})});d.displayName=u;function m(y){const h=a(e+"CollectionConsumer",y);return S.useCallback(()=>{const g=h.collectionRef.current;if(!g)return[];const p=Array.from(g.querySelectorAll(`[${f}]`));return Array.from(h.itemMap.values()).sort((b,x)=>p.indexOf(b.ref.current)-p.indexOf(x.ref.current))},[h.collectionRef,h.itemMap])}return[{Provider:c,Slot:v,ItemSlot:d},m,r]}function Jo(e,t=[]){let n=[];function r(a,c){const s=i.createContext(c),v=n.length;n=[...n,c];const u=d=>{const{scope:m,children:y,...h}=d,l=m?.[e]?.[v]||s,g=i.useMemo(()=>h,Object.values(h));return E.jsx(l.Provider,{value:g,children:y})};u.displayName=a+"Provider";function f(d,m){const y=m?.[e]?.[v]||s,h=i.useContext(y);if(h)return h;if(c!==void 0)return c;throw new Error(`\`${d}\` must be used within \`${a}\``)}return[u,f]}const o=()=>{const a=n.map(c=>i.createContext(c));return function(s){const v=s?.[e]||a;return i.useMemo(()=>({[`__scope${e}`]:{...s,[e]:v}}),[s,v])}};return o.scopeName=e,[r,ea(o,...t)]}function ea(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){const c=r.reduce((s,{useScope:v,scopeName:u})=>{const d=v(a)[`__scope${u}`];return{...s,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:c}),[c])}};return n.scopeName=t.scopeName,n}var ta=i.createContext(void 0);function kn(e){const t=i.useContext(ta);return e||t||"ltr"}function te(e){const t=i.useRef(e);return i.useEffect(()=>{t.current=e}),i.useMemo(()=>(...n)=>t.current?.(...n),[])}function $n(e,t=globalThis?.document){const n=te(e);i.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var na="DismissableLayer",It="dismissableLayer.update",ra="dismissableLayer.pointerDownOutside",oa="dismissableLayer.focusOutside",fn,jn=i.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Bn=i.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:c,onDismiss:s,...v}=e,u=i.useContext(jn),[f,d]=i.useState(null),m=f?.ownerDocument??globalThis?.document,[,y]=i.useState({}),h=X(t,w=>d(w)),l=Array.from(u.layers),[g]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),p=l.indexOf(g),C=f?l.indexOf(f):-1,R=u.layersWithOutsidePointerEventsDisabled.size>0,b=C>=p,x=sa(w=>{const P=w.target,D=[...u.branches].some(_=>_.contains(P));!b||D||(o?.(w),c?.(w),w.defaultPrevented||s?.())},m),N=ca(w=>{const P=w.target;[...u.branches].some(_=>_.contains(P))||(a?.(w),c?.(w),w.defaultPrevented||s?.())},m);return $n(w=>{C===u.layers.size-1&&(r?.(w),!w.defaultPrevented&&s&&(w.preventDefault(),s()))},m),i.useEffect(()=>{if(f)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(fn=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(f)),u.layers.add(f),vn(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=fn)}},[f,m,n,u]),i.useEffect(()=>()=>{f&&(u.layers.delete(f),u.layersWithOutsidePointerEventsDisabled.delete(f),vn())},[f,u]),i.useEffect(()=>{const w=()=>y({});return document.addEventListener(It,w),()=>document.removeEventListener(It,w)},[]),E.jsx(H.div,{...v,ref:h,style:{pointerEvents:R?b?"auto":"none":void 0,...e.style},onFocusCapture:I(e.onFocusCapture,N.onFocusCapture),onBlurCapture:I(e.onBlurCapture,N.onBlurCapture),onPointerDownCapture:I(e.onPointerDownCapture,x.onPointerDownCapture)})});Bn.displayName=na;var aa="DismissableLayerBranch",ia=i.forwardRef((e,t)=>{const n=i.useContext(jn),r=i.useRef(null),o=X(t,r);return i.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),E.jsx(H.div,{...e,ref:o})});ia.displayName=aa;function sa(e,t=globalThis?.document){const n=te(e),r=i.useRef(!1),o=i.useRef(()=>{});return i.useEffect(()=>{const a=s=>{if(s.target&&!r.current){let v=function(){Wn(ra,n,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=v,t.addEventListener("click",o.current,{once:!0})):v()}else t.removeEventListener("click",o.current);r.current=!1},c=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(c),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function ca(e,t=globalThis?.document){const n=te(e),r=i.useRef(!1);return i.useEffect(()=>{const o=a=>{a.target&&!r.current&&Wn(oa,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function vn(){const e=new CustomEvent(It);document.dispatchEvent(e)}function Wn(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Bt(o,a):o.dispatchEvent(a)}var wt=0;function ua(){i.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??mn()),document.body.insertAdjacentElement("beforeend",e[1]??mn()),wt++,()=>{wt===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),wt--}},[])}function mn(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var yt="focusScope.autoFocusOnMount",Et="focusScope.autoFocusOnUnmount",pn={bubbles:!1,cancelable:!0},la="FocusScope",Wt=i.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...c}=e,[s,v]=i.useState(null),u=te(o),f=te(a),d=i.useRef(null),m=X(t,l=>v(l)),y=i.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;i.useEffect(()=>{if(r){let l=function(R){if(y.paused||!s)return;const b=R.target;s.contains(b)?d.current=b:we(d.current,{select:!0})},g=function(R){if(y.paused||!s)return;const b=R.relatedTarget;b!==null&&(s.contains(b)||we(d.current,{select:!0}))},p=function(R){if(document.activeElement===document.body)for(const x of R)x.removedNodes.length>0&&we(s)};document.addEventListener("focusin",l),document.addEventListener("focusout",g);const C=new MutationObserver(p);return s&&C.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",l),document.removeEventListener("focusout",g),C.disconnect()}}},[r,s,y.paused]),i.useEffect(()=>{if(s){gn.add(y);const l=document.activeElement;if(!s.contains(l)){const p=new CustomEvent(yt,pn);s.addEventListener(yt,u),s.dispatchEvent(p),p.defaultPrevented||(da(ha(Un(s)),{select:!0}),document.activeElement===l&&we(s))}return()=>{s.removeEventListener(yt,u),setTimeout(()=>{const p=new CustomEvent(Et,pn);s.addEventListener(Et,f),s.dispatchEvent(p),p.defaultPrevented||we(l??document.body,{select:!0}),s.removeEventListener(Et,f),gn.remove(y)},0)}}},[s,u,f,y]);const h=i.useCallback(l=>{if(!n&&!r||y.paused)return;const g=l.key==="Tab"&&!l.altKey&&!l.ctrlKey&&!l.metaKey,p=document.activeElement;if(g&&p){const C=l.currentTarget,[R,b]=fa(C);R&&b?!l.shiftKey&&p===b?(l.preventDefault(),n&&we(R,{select:!0})):l.shiftKey&&p===R&&(l.preventDefault(),n&&we(b,{select:!0})):p===C&&l.preventDefault()}},[n,r,y.paused]);return E.jsx(H.div,{tabIndex:-1,...c,ref:m,onKeyDown:h})});Wt.displayName=la;function da(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(we(r,{select:t}),document.activeElement!==n)return}function fa(e){const t=Un(e),n=hn(t,e),r=hn(t.reverse(),e);return[n,r]}function Un(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function hn(e,t){for(const n of e)if(!va(n,{upTo:t}))return n}function va(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function ma(e){return e instanceof HTMLInputElement&&"select"in e}function we(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&ma(e)&&t&&e.select()}}var gn=pa();function pa(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=wn(e,t),e.unshift(t)},remove(t){e=wn(e,t),e[0]?.resume()}}}function wn(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function ha(e){return e.filter(t=>t.tagName!=="A")}var ga="Arrow",Hn=i.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...a}=e;return E.jsx(H.svg,{...a,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:E.jsx("polygon",{points:"0,0 30,0 15,10"})})});Hn.displayName=ga;var wa=Hn;function ya(e){const[t,n]=i.useState(void 0);return me(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const a=o[0];let c,s;if("borderBoxSize"in a){const v=a.borderBoxSize,u=Array.isArray(v)?v[0]:v;c=u.inlineSize,s=u.blockSize}else c=e.offsetWidth,s=e.offsetHeight;n({width:c,height:s})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Ut="Popper",[Kn,Yn]=lt(Ut),[Ea,Gn]=Kn(Ut),zn=e=>{const{__scopePopper:t,children:n}=e,[r,o]=i.useState(null);return E.jsx(Ea,{scope:t,anchor:r,onAnchorChange:o,children:n})};zn.displayName=Ut;var Vn="PopperAnchor",Xn=i.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=Gn(Vn,n),c=i.useRef(null),s=X(t,c);return i.useEffect(()=>{a.onAnchorChange(r?.current||c.current)}),r?null:E.jsx(H.div,{...o,ref:s})});Xn.displayName=Vn;var Ht="PopperContent",[ba,Ca]=Kn(Ht),qn=i.forwardRef((e,t)=>{const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:a="center",alignOffset:c=0,arrowPadding:s=0,avoidCollisions:v=!0,collisionBoundary:u=[],collisionPadding:f=0,sticky:d="partial",hideWhenDetached:m=!1,updatePositionStrategy:y="optimized",onPlaced:h,...l}=e,g=Gn(Ht,n),[p,C]=i.useState(null),R=X(t,B=>C(B)),[b,x]=i.useState(null),N=ya(b),w=N?.width??0,P=N?.height??0,D=r+(a!=="center"?"-"+a:""),_=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},T=Array.isArray(u)?u:[u],j=T.length>0,k={padding:_,boundary:T.filter(Ra),altBoundary:j},{refs:K,floatingStyles:Y,placement:V,isPositioned:G,middlewareData:z}=Ho({strategy:"fixed",placement:D,whileElementsMounted:(...B)=>Ko(...B,{animationFrame:y==="always"}),elements:{reference:g.anchor},middleware:[Yo({mainAxis:o+P,alignmentAxis:c}),v&&Go({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?zo():void 0,...k}),v&&Vo({...k}),Xo({...k,apply:({elements:B,rects:ce,availableWidth:Ae,availableHeight:Ie})=>{const{width:he,height:Ge}=ce.reference,A=B.floating.style;A.setProperty("--radix-popper-available-width",`${Ae}px`),A.setProperty("--radix-popper-available-height",`${Ie}px`),A.setProperty("--radix-popper-anchor-width",`${he}px`),A.setProperty("--radix-popper-anchor-height",`${Ge}px`)}}),b&&qo({element:b,padding:s}),xa({arrowWidth:w,arrowHeight:P}),m&&Zo({strategy:"referenceHidden",...k})]}),[M,ne]=Jn(V),re=te(h);me(()=>{G&&re?.()},[G,re]);const de=z.arrow?.x,oe=z.arrow?.y,fe=z.arrow?.centerOffset!==0,[pe,se]=i.useState();return me(()=>{p&&se(window.getComputedStyle(p).zIndex)},[p]),E.jsx("div",{ref:K.setFloating,"data-radix-popper-content-wrapper":"",style:{...Y,transform:G?Y.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:pe,"--radix-popper-transform-origin":[z.transformOrigin?.x,z.transformOrigin?.y].join(" "),...z.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:E.jsx(ba,{scope:n,placedSide:M,onArrowChange:x,arrowX:de,arrowY:oe,shouldHideArrow:fe,children:E.jsx(H.div,{"data-side":M,"data-align":ne,...l,ref:R,style:{...l.style,animation:G?void 0:"none"}})})})});qn.displayName=Ht;var Zn="PopperArrow",Sa={top:"bottom",right:"left",bottom:"top",left:"right"},Qn=i.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,a=Ca(Zn,r),c=Sa[a.placedSide];return E.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[c]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:E.jsx(wa,{...o,ref:n,style:{...o.style,display:"block"}})})});Qn.displayName=Zn;function Ra(e){return e!==null}var xa=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:r,middlewareData:o}=t,c=o.arrow?.centerOffset!==0,s=c?0:e.arrowWidth,v=c?0:e.arrowHeight,[u,f]=Jn(n),d={start:"0%",center:"50%",end:"100%"}[f],m=(o.arrow?.x??0)+s/2,y=(o.arrow?.y??0)+v/2;let h="",l="";return u==="bottom"?(h=c?d:`${m}px`,l=`${-v}px`):u==="top"?(h=c?d:`${m}px`,l=`${r.floating.height+v}px`):u==="right"?(h=`${-v}px`,l=c?d:`${y}px`):u==="left"&&(h=`${r.floating.width+v}px`,l=c?d:`${y}px`),{data:{x:h,y:l}}}});function Jn(e){const[t,n="center"]=e.split("-");return[t,n]}var Pa=zn,Ta=Xn,Da=qn,Ma=Qn,Oa="Portal",er=i.forwardRef((e,t)=>{const{container:n,...r}=e,[o,a]=i.useState(!1);me(()=>a(!0),[]);const c=n||o&&globalThis?.document?.body;return c?Ln.createPortal(E.jsx(H.div,{...r,ref:t}),c):null});er.displayName=Oa;function Aa(e,t){return i.useReducer((n,r)=>t[n][r]??n,e)}var He=e=>{const{present:t,children:n}=e,r=Ia(t),o=typeof n=="function"?n({present:r.isPresent}):i.Children.only(n),a=X(r.ref,Na(o));return typeof n=="function"||r.isPresent?i.cloneElement(o,{ref:a}):null};He.displayName="Presence";function Ia(e){const[t,n]=i.useState(),r=i.useRef({}),o=i.useRef(e),a=i.useRef("none"),c=e?"mounted":"unmounted",[s,v]=Aa(c,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return i.useEffect(()=>{const u=Xe(r.current);a.current=s==="mounted"?u:"none"},[s]),me(()=>{const u=r.current,f=o.current;if(f!==e){const m=a.current,y=Xe(u);e?v("MOUNT"):y==="none"||u?.display==="none"?v("UNMOUNT"):v(f&&m!==y?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,v]),me(()=>{if(t){let u;const f=t.ownerDocument.defaultView??window,d=y=>{const l=Xe(r.current).includes(y.animationName);if(y.target===t&&l&&(v("ANIMATION_END"),!o.current)){const g=t.style.animationFillMode;t.style.animationFillMode="forwards",u=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=g)})}},m=y=>{y.target===t&&(a.current=Xe(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{f.clearTimeout(u),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else v("ANIMATION_END")},[t,v]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:i.useCallback(u=>{u&&(r.current=getComputedStyle(u)),n(u)},[])}}function Xe(e){return e?.animationName||"none"}function Na(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function tr({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=_a({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:r,s=te(n),v=i.useCallback(u=>{if(a){const d=typeof u=="function"?u(e):u;d!==e&&s(d)}else o(u)},[a,e,o,s]);return[c,v]}function _a({defaultProp:e,onChange:t}){const n=i.useState(e),[r]=n,o=i.useRef(r),a=te(t);return i.useEffect(()=>{o.current!==r&&(a(r),o.current=r)},[r,o,a]),n}var bt="rovingFocusGroup.onEntryFocus",La={bubbles:!1,cancelable:!0},dt="RovingFocusGroup",[Nt,nr,Fa]=Fn(dt),[ka,rr]=lt(dt,[Fa]),[$a,ja]=ka(dt),or=i.forwardRef((e,t)=>E.jsx(Nt.Provider,{scope:e.__scopeRovingFocusGroup,children:E.jsx(Nt.Slot,{scope:e.__scopeRovingFocusGroup,children:E.jsx(Ba,{...e,ref:t})})}));or.displayName=dt;var Ba=i.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:c,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:v,onEntryFocus:u,preventScrollOnEntryFocus:f=!1,...d}=e,m=i.useRef(null),y=X(t,m),h=kn(a),[l=null,g]=tr({prop:c,defaultProp:s,onChange:v}),[p,C]=i.useState(!1),R=te(u),b=nr(n),x=i.useRef(!1),[N,w]=i.useState(0);return i.useEffect(()=>{const P=m.current;if(P)return P.addEventListener(bt,R),()=>P.removeEventListener(bt,R)},[R]),E.jsx($a,{scope:n,orientation:r,dir:h,loop:o,currentTabStopId:l,onItemFocus:i.useCallback(P=>g(P),[g]),onItemShiftTab:i.useCallback(()=>C(!0),[]),onFocusableItemAdd:i.useCallback(()=>w(P=>P+1),[]),onFocusableItemRemove:i.useCallback(()=>w(P=>P-1),[]),children:E.jsx(H.div,{tabIndex:p||N===0?-1:0,"data-orientation":r,...d,ref:y,style:{outline:"none",...e.style},onMouseDown:I(e.onMouseDown,()=>{x.current=!0}),onFocus:I(e.onFocus,P=>{const D=!x.current;if(P.target===P.currentTarget&&D&&!p){const _=new CustomEvent(bt,La);if(P.currentTarget.dispatchEvent(_),!_.defaultPrevented){const T=b().filter(V=>V.focusable),j=T.find(V=>V.active),k=T.find(V=>V.id===l),Y=[j,k,...T].filter(Boolean).map(V=>V.ref.current);sr(Y,f)}}x.current=!1}),onBlur:I(e.onBlur,()=>C(!1))})})}),ar="RovingFocusGroupItem",ir=i.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,...c}=e,s=at(),v=a||s,u=ja(ar,n),f=u.currentTabStopId===v,d=nr(n),{onFocusableItemAdd:m,onFocusableItemRemove:y}=u;return i.useEffect(()=>{if(r)return m(),()=>y()},[r,m,y]),E.jsx(Nt.ItemSlot,{scope:n,id:v,focusable:r,active:o,children:E.jsx(H.span,{tabIndex:f?0:-1,"data-orientation":u.orientation,...c,ref:t,onMouseDown:I(e.onMouseDown,h=>{r?u.onItemFocus(v):h.preventDefault()}),onFocus:I(e.onFocus,()=>u.onItemFocus(v)),onKeyDown:I(e.onKeyDown,h=>{if(h.key==="Tab"&&h.shiftKey){u.onItemShiftTab();return}if(h.target!==h.currentTarget)return;const l=Ha(h,u.orientation,u.dir);if(l!==void 0){if(h.metaKey||h.ctrlKey||h.altKey||h.shiftKey)return;h.preventDefault();let p=d().filter(C=>C.focusable).map(C=>C.ref.current);if(l==="last")p.reverse();else if(l==="prev"||l==="next"){l==="prev"&&p.reverse();const C=p.indexOf(h.currentTarget);p=u.loop?Ka(p,C+1):p.slice(C+1)}setTimeout(()=>sr(p))}})})})});ir.displayName=ar;var Wa={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Ua(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Ha(e,t,n){const r=Ua(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return Wa[r]}function sr(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function Ka(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Ya=or,Ga=ir,za=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Re=new WeakMap,qe=new WeakMap,Ze={},Ct=0,cr=function(e){return e&&(e.host||cr(e.parentNode))},Va=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=cr(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Xa=function(e,t,n,r){var o=Va(t,Array.isArray(e)?e:[e]);Ze[n]||(Ze[n]=new WeakMap);var a=Ze[n],c=[],s=new Set,v=new Set(o),u=function(d){!d||s.has(d)||(s.add(d),u(d.parentNode))};o.forEach(u);var f=function(d){!d||v.has(d)||Array.prototype.forEach.call(d.children,function(m){if(s.has(m))f(m);else try{var y=m.getAttribute(r),h=y!==null&&y!=="false",l=(Re.get(m)||0)+1,g=(a.get(m)||0)+1;Re.set(m,l),a.set(m,g),c.push(m),l===1&&h&&qe.set(m,!0),g===1&&m.setAttribute(n,"true"),h||m.setAttribute(r,"true")}catch(p){console.error("aria-hidden: cannot operate on ",m,p)}})};return f(t),s.clear(),Ct++,function(){c.forEach(function(d){var m=Re.get(d)-1,y=a.get(d)-1;Re.set(d,m),a.set(d,y),m||(qe.has(d)||d.removeAttribute(r),qe.delete(d)),y||d.removeAttribute(n)}),Ct--,Ct||(Re=new WeakMap,Re=new WeakMap,qe=new WeakMap,Ze={})}},ur=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=za(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),Xa(r,o,n,"aria-hidden")):function(){return null}},Q=function(){return Q=Object.assign||function(t){for(var n,r=1,o=arguments.length;r"u")return ci;var t=ui(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},di=Yt(),Me="data-scroll-locked",fi=function(e,t,n,r){var o=e.left,a=e.top,c=e.right,s=e.gap;return n===void 0&&(n="margin"),` +import{R as S,r as i}from"./index-DRjF_FHU.js";import{c as I,a as me,u as at}from"./index-CGa_gRws.js";import{c as lt,a as Wo}from"./index-BXwbELbV.js";import{u as X,S as it,c as Uo}from"./index-C8xBnYIG.js";import{j as E}from"./jsx-runtime-DR9Q75dM.js";import{P as H,d as Bt}from"./index-Ksfxd92j.js";import{q as Ho,c as Ko,o as Yo,s as Go,n as zo,f as Vo,r as Xo,d as qo,t as Zo}from"./floating-ui.react-CSvGZjCC.js";import{F as Ln,r as Qo}from"./index-BvEl7W6R.js";function Fn(e){const t=e+"CollectionProvider",[n,r]=lt(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),c=y=>{const{scope:h,children:l}=y,g=S.useRef(null),p=S.useRef(new Map).current;return E.jsx(o,{scope:h,itemMap:p,collectionRef:g,children:l})};c.displayName=t;const s=e+"CollectionSlot",v=S.forwardRef((y,h)=>{const{scope:l,children:g}=y,p=a(s,l),C=X(h,p.collectionRef);return E.jsx(it,{ref:C,children:g})});v.displayName=s;const u=e+"CollectionItemSlot",f="data-radix-collection-item",d=S.forwardRef((y,h)=>{const{scope:l,children:g,...p}=y,C=S.useRef(null),R=X(h,C),b=a(u,l);return S.useEffect(()=>(b.itemMap.set(C,{ref:C,...p}),()=>void b.itemMap.delete(C))),E.jsx(it,{[f]:"",ref:R,children:g})});d.displayName=u;function m(y){const h=a(e+"CollectionConsumer",y);return S.useCallback(()=>{const g=h.collectionRef.current;if(!g)return[];const p=Array.from(g.querySelectorAll(`[${f}]`));return Array.from(h.itemMap.values()).sort((b,x)=>p.indexOf(b.ref.current)-p.indexOf(x.ref.current))},[h.collectionRef,h.itemMap])}return[{Provider:c,Slot:v,ItemSlot:d},m,r]}function Jo(e,t=[]){let n=[];function r(a,c){const s=i.createContext(c),v=n.length;n=[...n,c];const u=d=>{const{scope:m,children:y,...h}=d,l=m?.[e]?.[v]||s,g=i.useMemo(()=>h,Object.values(h));return E.jsx(l.Provider,{value:g,children:y})};u.displayName=a+"Provider";function f(d,m){const y=m?.[e]?.[v]||s,h=i.useContext(y);if(h)return h;if(c!==void 0)return c;throw new Error(`\`${d}\` must be used within \`${a}\``)}return[u,f]}const o=()=>{const a=n.map(c=>i.createContext(c));return function(s){const v=s?.[e]||a;return i.useMemo(()=>({[`__scope${e}`]:{...s,[e]:v}}),[s,v])}};return o.scopeName=e,[r,ea(o,...t)]}function ea(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){const c=r.reduce((s,{useScope:v,scopeName:u})=>{const d=v(a)[`__scope${u}`];return{...s,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:c}),[c])}};return n.scopeName=t.scopeName,n}var ta=i.createContext(void 0);function kn(e){const t=i.useContext(ta);return e||t||"ltr"}function te(e){const t=i.useRef(e);return i.useEffect(()=>{t.current=e}),i.useMemo(()=>(...n)=>t.current?.(...n),[])}function $n(e,t=globalThis?.document){const n=te(e);i.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var na="DismissableLayer",It="dismissableLayer.update",ra="dismissableLayer.pointerDownOutside",oa="dismissableLayer.focusOutside",fn,jn=i.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Bn=i.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:c,onDismiss:s,...v}=e,u=i.useContext(jn),[f,d]=i.useState(null),m=f?.ownerDocument??globalThis?.document,[,y]=i.useState({}),h=X(t,w=>d(w)),l=Array.from(u.layers),[g]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),p=l.indexOf(g),C=f?l.indexOf(f):-1,R=u.layersWithOutsidePointerEventsDisabled.size>0,b=C>=p,x=sa(w=>{const P=w.target,D=[...u.branches].some(_=>_.contains(P));!b||D||(o?.(w),c?.(w),w.defaultPrevented||s?.())},m),N=ca(w=>{const P=w.target;[...u.branches].some(_=>_.contains(P))||(a?.(w),c?.(w),w.defaultPrevented||s?.())},m);return $n(w=>{C===u.layers.size-1&&(r?.(w),!w.defaultPrevented&&s&&(w.preventDefault(),s()))},m),i.useEffect(()=>{if(f)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(fn=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(f)),u.layers.add(f),vn(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=fn)}},[f,m,n,u]),i.useEffect(()=>()=>{f&&(u.layers.delete(f),u.layersWithOutsidePointerEventsDisabled.delete(f),vn())},[f,u]),i.useEffect(()=>{const w=()=>y({});return document.addEventListener(It,w),()=>document.removeEventListener(It,w)},[]),E.jsx(H.div,{...v,ref:h,style:{pointerEvents:R?b?"auto":"none":void 0,...e.style},onFocusCapture:I(e.onFocusCapture,N.onFocusCapture),onBlurCapture:I(e.onBlurCapture,N.onBlurCapture),onPointerDownCapture:I(e.onPointerDownCapture,x.onPointerDownCapture)})});Bn.displayName=na;var aa="DismissableLayerBranch",ia=i.forwardRef((e,t)=>{const n=i.useContext(jn),r=i.useRef(null),o=X(t,r);return i.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),E.jsx(H.div,{...e,ref:o})});ia.displayName=aa;function sa(e,t=globalThis?.document){const n=te(e),r=i.useRef(!1),o=i.useRef(()=>{});return i.useEffect(()=>{const a=s=>{if(s.target&&!r.current){let v=function(){Wn(ra,n,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=v,t.addEventListener("click",o.current,{once:!0})):v()}else t.removeEventListener("click",o.current);r.current=!1},c=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(c),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function ca(e,t=globalThis?.document){const n=te(e),r=i.useRef(!1);return i.useEffect(()=>{const o=a=>{a.target&&!r.current&&Wn(oa,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function vn(){const e=new CustomEvent(It);document.dispatchEvent(e)}function Wn(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Bt(o,a):o.dispatchEvent(a)}var wt=0;function ua(){i.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??mn()),document.body.insertAdjacentElement("beforeend",e[1]??mn()),wt++,()=>{wt===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),wt--}},[])}function mn(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var yt="focusScope.autoFocusOnMount",Et="focusScope.autoFocusOnUnmount",pn={bubbles:!1,cancelable:!0},la="FocusScope",Wt=i.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...c}=e,[s,v]=i.useState(null),u=te(o),f=te(a),d=i.useRef(null),m=X(t,l=>v(l)),y=i.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;i.useEffect(()=>{if(r){let l=function(R){if(y.paused||!s)return;const b=R.target;s.contains(b)?d.current=b:we(d.current,{select:!0})},g=function(R){if(y.paused||!s)return;const b=R.relatedTarget;b!==null&&(s.contains(b)||we(d.current,{select:!0}))},p=function(R){if(document.activeElement===document.body)for(const x of R)x.removedNodes.length>0&&we(s)};document.addEventListener("focusin",l),document.addEventListener("focusout",g);const C=new MutationObserver(p);return s&&C.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",l),document.removeEventListener("focusout",g),C.disconnect()}}},[r,s,y.paused]),i.useEffect(()=>{if(s){gn.add(y);const l=document.activeElement;if(!s.contains(l)){const p=new CustomEvent(yt,pn);s.addEventListener(yt,u),s.dispatchEvent(p),p.defaultPrevented||(da(ha(Un(s)),{select:!0}),document.activeElement===l&&we(s))}return()=>{s.removeEventListener(yt,u),setTimeout(()=>{const p=new CustomEvent(Et,pn);s.addEventListener(Et,f),s.dispatchEvent(p),p.defaultPrevented||we(l??document.body,{select:!0}),s.removeEventListener(Et,f),gn.remove(y)},0)}}},[s,u,f,y]);const h=i.useCallback(l=>{if(!n&&!r||y.paused)return;const g=l.key==="Tab"&&!l.altKey&&!l.ctrlKey&&!l.metaKey,p=document.activeElement;if(g&&p){const C=l.currentTarget,[R,b]=fa(C);R&&b?!l.shiftKey&&p===b?(l.preventDefault(),n&&we(R,{select:!0})):l.shiftKey&&p===R&&(l.preventDefault(),n&&we(b,{select:!0})):p===C&&l.preventDefault()}},[n,r,y.paused]);return E.jsx(H.div,{tabIndex:-1,...c,ref:m,onKeyDown:h})});Wt.displayName=la;function da(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(we(r,{select:t}),document.activeElement!==n)return}function fa(e){const t=Un(e),n=hn(t,e),r=hn(t.reverse(),e);return[n,r]}function Un(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function hn(e,t){for(const n of e)if(!va(n,{upTo:t}))return n}function va(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function ma(e){return e instanceof HTMLInputElement&&"select"in e}function we(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&ma(e)&&t&&e.select()}}var gn=pa();function pa(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=wn(e,t),e.unshift(t)},remove(t){e=wn(e,t),e[0]?.resume()}}}function wn(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function ha(e){return e.filter(t=>t.tagName!=="A")}var ga="Arrow",Hn=i.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...a}=e;return E.jsx(H.svg,{...a,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:E.jsx("polygon",{points:"0,0 30,0 15,10"})})});Hn.displayName=ga;var wa=Hn;function ya(e){const[t,n]=i.useState(void 0);return me(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const a=o[0];let c,s;if("borderBoxSize"in a){const v=a.borderBoxSize,u=Array.isArray(v)?v[0]:v;c=u.inlineSize,s=u.blockSize}else c=e.offsetWidth,s=e.offsetHeight;n({width:c,height:s})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Ut="Popper",[Kn,Yn]=lt(Ut),[Ea,Gn]=Kn(Ut),zn=e=>{const{__scopePopper:t,children:n}=e,[r,o]=i.useState(null);return E.jsx(Ea,{scope:t,anchor:r,onAnchorChange:o,children:n})};zn.displayName=Ut;var Vn="PopperAnchor",Xn=i.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=Gn(Vn,n),c=i.useRef(null),s=X(t,c);return i.useEffect(()=>{a.onAnchorChange(r?.current||c.current)}),r?null:E.jsx(H.div,{...o,ref:s})});Xn.displayName=Vn;var Ht="PopperContent",[ba,Ca]=Kn(Ht),qn=i.forwardRef((e,t)=>{const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:a="center",alignOffset:c=0,arrowPadding:s=0,avoidCollisions:v=!0,collisionBoundary:u=[],collisionPadding:f=0,sticky:d="partial",hideWhenDetached:m=!1,updatePositionStrategy:y="optimized",onPlaced:h,...l}=e,g=Gn(Ht,n),[p,C]=i.useState(null),R=X(t,B=>C(B)),[b,x]=i.useState(null),N=ya(b),w=N?.width??0,P=N?.height??0,D=r+(a!=="center"?"-"+a:""),_=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},T=Array.isArray(u)?u:[u],j=T.length>0,k={padding:_,boundary:T.filter(Ra),altBoundary:j},{refs:K,floatingStyles:Y,placement:V,isPositioned:G,middlewareData:z}=Ho({strategy:"fixed",placement:D,whileElementsMounted:(...B)=>Ko(...B,{animationFrame:y==="always"}),elements:{reference:g.anchor},middleware:[Yo({mainAxis:o+P,alignmentAxis:c}),v&&Go({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?zo():void 0,...k}),v&&Vo({...k}),Xo({...k,apply:({elements:B,rects:ce,availableWidth:Ae,availableHeight:Ie})=>{const{width:he,height:Ge}=ce.reference,A=B.floating.style;A.setProperty("--radix-popper-available-width",`${Ae}px`),A.setProperty("--radix-popper-available-height",`${Ie}px`),A.setProperty("--radix-popper-anchor-width",`${he}px`),A.setProperty("--radix-popper-anchor-height",`${Ge}px`)}}),b&&qo({element:b,padding:s}),xa({arrowWidth:w,arrowHeight:P}),m&&Zo({strategy:"referenceHidden",...k})]}),[M,ne]=Jn(V),re=te(h);me(()=>{G&&re?.()},[G,re]);const de=z.arrow?.x,oe=z.arrow?.y,fe=z.arrow?.centerOffset!==0,[pe,se]=i.useState();return me(()=>{p&&se(window.getComputedStyle(p).zIndex)},[p]),E.jsx("div",{ref:K.setFloating,"data-radix-popper-content-wrapper":"",style:{...Y,transform:G?Y.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:pe,"--radix-popper-transform-origin":[z.transformOrigin?.x,z.transformOrigin?.y].join(" "),...z.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:E.jsx(ba,{scope:n,placedSide:M,onArrowChange:x,arrowX:de,arrowY:oe,shouldHideArrow:fe,children:E.jsx(H.div,{"data-side":M,"data-align":ne,...l,ref:R,style:{...l.style,animation:G?void 0:"none"}})})})});qn.displayName=Ht;var Zn="PopperArrow",Sa={top:"bottom",right:"left",bottom:"top",left:"right"},Qn=i.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,a=Ca(Zn,r),c=Sa[a.placedSide];return E.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[c]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:E.jsx(wa,{...o,ref:n,style:{...o.style,display:"block"}})})});Qn.displayName=Zn;function Ra(e){return e!==null}var xa=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:r,middlewareData:o}=t,c=o.arrow?.centerOffset!==0,s=c?0:e.arrowWidth,v=c?0:e.arrowHeight,[u,f]=Jn(n),d={start:"0%",center:"50%",end:"100%"}[f],m=(o.arrow?.x??0)+s/2,y=(o.arrow?.y??0)+v/2;let h="",l="";return u==="bottom"?(h=c?d:`${m}px`,l=`${-v}px`):u==="top"?(h=c?d:`${m}px`,l=`${r.floating.height+v}px`):u==="right"?(h=`${-v}px`,l=c?d:`${y}px`):u==="left"&&(h=`${r.floating.width+v}px`,l=c?d:`${y}px`),{data:{x:h,y:l}}}});function Jn(e){const[t,n="center"]=e.split("-");return[t,n]}var Pa=zn,Ta=Xn,Da=qn,Ma=Qn,Oa="Portal",er=i.forwardRef((e,t)=>{const{container:n,...r}=e,[o,a]=i.useState(!1);me(()=>a(!0),[]);const c=n||o&&globalThis?.document?.body;return c?Ln.createPortal(E.jsx(H.div,{...r,ref:t}),c):null});er.displayName=Oa;function Aa(e,t){return i.useReducer((n,r)=>t[n][r]??n,e)}var He=e=>{const{present:t,children:n}=e,r=Ia(t),o=typeof n=="function"?n({present:r.isPresent}):i.Children.only(n),a=X(r.ref,Na(o));return typeof n=="function"||r.isPresent?i.cloneElement(o,{ref:a}):null};He.displayName="Presence";function Ia(e){const[t,n]=i.useState(),r=i.useRef({}),o=i.useRef(e),a=i.useRef("none"),c=e?"mounted":"unmounted",[s,v]=Aa(c,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return i.useEffect(()=>{const u=Xe(r.current);a.current=s==="mounted"?u:"none"},[s]),me(()=>{const u=r.current,f=o.current;if(f!==e){const m=a.current,y=Xe(u);e?v("MOUNT"):y==="none"||u?.display==="none"?v("UNMOUNT"):v(f&&m!==y?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,v]),me(()=>{if(t){let u;const f=t.ownerDocument.defaultView??window,d=y=>{const l=Xe(r.current).includes(y.animationName);if(y.target===t&&l&&(v("ANIMATION_END"),!o.current)){const g=t.style.animationFillMode;t.style.animationFillMode="forwards",u=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=g)})}},m=y=>{y.target===t&&(a.current=Xe(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{f.clearTimeout(u),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else v("ANIMATION_END")},[t,v]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:i.useCallback(u=>{u&&(r.current=getComputedStyle(u)),n(u)},[])}}function Xe(e){return e?.animationName||"none"}function Na(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function tr({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=_a({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:r,s=te(n),v=i.useCallback(u=>{if(a){const d=typeof u=="function"?u(e):u;d!==e&&s(d)}else o(u)},[a,e,o,s]);return[c,v]}function _a({defaultProp:e,onChange:t}){const n=i.useState(e),[r]=n,o=i.useRef(r),a=te(t);return i.useEffect(()=>{o.current!==r&&(a(r),o.current=r)},[r,o,a]),n}var bt="rovingFocusGroup.onEntryFocus",La={bubbles:!1,cancelable:!0},dt="RovingFocusGroup",[Nt,nr,Fa]=Fn(dt),[ka,rr]=lt(dt,[Fa]),[$a,ja]=ka(dt),or=i.forwardRef((e,t)=>E.jsx(Nt.Provider,{scope:e.__scopeRovingFocusGroup,children:E.jsx(Nt.Slot,{scope:e.__scopeRovingFocusGroup,children:E.jsx(Ba,{...e,ref:t})})}));or.displayName=dt;var Ba=i.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:c,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:v,onEntryFocus:u,preventScrollOnEntryFocus:f=!1,...d}=e,m=i.useRef(null),y=X(t,m),h=kn(a),[l=null,g]=tr({prop:c,defaultProp:s,onChange:v}),[p,C]=i.useState(!1),R=te(u),b=nr(n),x=i.useRef(!1),[N,w]=i.useState(0);return i.useEffect(()=>{const P=m.current;if(P)return P.addEventListener(bt,R),()=>P.removeEventListener(bt,R)},[R]),E.jsx($a,{scope:n,orientation:r,dir:h,loop:o,currentTabStopId:l,onItemFocus:i.useCallback(P=>g(P),[g]),onItemShiftTab:i.useCallback(()=>C(!0),[]),onFocusableItemAdd:i.useCallback(()=>w(P=>P+1),[]),onFocusableItemRemove:i.useCallback(()=>w(P=>P-1),[]),children:E.jsx(H.div,{tabIndex:p||N===0?-1:0,"data-orientation":r,...d,ref:y,style:{outline:"none",...e.style},onMouseDown:I(e.onMouseDown,()=>{x.current=!0}),onFocus:I(e.onFocus,P=>{const D=!x.current;if(P.target===P.currentTarget&&D&&!p){const _=new CustomEvent(bt,La);if(P.currentTarget.dispatchEvent(_),!_.defaultPrevented){const T=b().filter(V=>V.focusable),j=T.find(V=>V.active),k=T.find(V=>V.id===l),Y=[j,k,...T].filter(Boolean).map(V=>V.ref.current);sr(Y,f)}}x.current=!1}),onBlur:I(e.onBlur,()=>C(!1))})})}),ar="RovingFocusGroupItem",ir=i.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,...c}=e,s=at(),v=a||s,u=ja(ar,n),f=u.currentTabStopId===v,d=nr(n),{onFocusableItemAdd:m,onFocusableItemRemove:y}=u;return i.useEffect(()=>{if(r)return m(),()=>y()},[r,m,y]),E.jsx(Nt.ItemSlot,{scope:n,id:v,focusable:r,active:o,children:E.jsx(H.span,{tabIndex:f?0:-1,"data-orientation":u.orientation,...c,ref:t,onMouseDown:I(e.onMouseDown,h=>{r?u.onItemFocus(v):h.preventDefault()}),onFocus:I(e.onFocus,()=>u.onItemFocus(v)),onKeyDown:I(e.onKeyDown,h=>{if(h.key==="Tab"&&h.shiftKey){u.onItemShiftTab();return}if(h.target!==h.currentTarget)return;const l=Ha(h,u.orientation,u.dir);if(l!==void 0){if(h.metaKey||h.ctrlKey||h.altKey||h.shiftKey)return;h.preventDefault();let p=d().filter(C=>C.focusable).map(C=>C.ref.current);if(l==="last")p.reverse();else if(l==="prev"||l==="next"){l==="prev"&&p.reverse();const C=p.indexOf(h.currentTarget);p=u.loop?Ka(p,C+1):p.slice(C+1)}setTimeout(()=>sr(p))}})})})});ir.displayName=ar;var Wa={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Ua(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Ha(e,t,n){const r=Ua(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return Wa[r]}function sr(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function Ka(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Ya=or,Ga=ir,za=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Re=new WeakMap,qe=new WeakMap,Ze={},Ct=0,cr=function(e){return e&&(e.host||cr(e.parentNode))},Va=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=cr(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Xa=function(e,t,n,r){var o=Va(t,Array.isArray(e)?e:[e]);Ze[n]||(Ze[n]=new WeakMap);var a=Ze[n],c=[],s=new Set,v=new Set(o),u=function(d){!d||s.has(d)||(s.add(d),u(d.parentNode))};o.forEach(u);var f=function(d){!d||v.has(d)||Array.prototype.forEach.call(d.children,function(m){if(s.has(m))f(m);else try{var y=m.getAttribute(r),h=y!==null&&y!=="false",l=(Re.get(m)||0)+1,g=(a.get(m)||0)+1;Re.set(m,l),a.set(m,g),c.push(m),l===1&&h&&qe.set(m,!0),g===1&&m.setAttribute(n,"true"),h||m.setAttribute(r,"true")}catch(p){console.error("aria-hidden: cannot operate on ",m,p)}})};return f(t),s.clear(),Ct++,function(){c.forEach(function(d){var m=Re.get(d)-1,y=a.get(d)-1;Re.set(d,m),a.set(d,y),m||(qe.has(d)||d.removeAttribute(r),qe.delete(d)),y||d.removeAttribute(n)}),Ct--,Ct||(Re=new WeakMap,Re=new WeakMap,qe=new WeakMap,Ze={})}},ur=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=za(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),Xa(r,o,n,"aria-hidden")):function(){return null}},Q=function(){return Q=Object.assign||function(t){for(var n,r=1,o=arguments.length;r"u")return ci;var t=ui(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},di=Yt(),Me="data-scroll-locked",fi=function(e,t,n,r){var o=e.left,a=e.top,c=e.right,s=e.gap;return n===void 0&&(n="margin"),` .`.concat(qa,` { overflow: hidden `).concat(r,`; padding-right: `).concat(s,"px ").concat(r,`; diff --git a/assets/index-C_34dRtw.js b/assets/index-zGZrE8kf.js similarity index 92% rename from assets/index-C_34dRtw.js rename to assets/index-zGZrE8kf.js index 13bb9dcd..38ead521 100644 --- a/assets/index-C_34dRtw.js +++ b/assets/index-zGZrE8kf.js @@ -1 +1 @@ -import{m as c,a as T,G as b,K as d,P as S,g as B,L,b as C,v as H,w as u,c as g,E as y,$ as I,y as h,d as k,N as P,e as W,D as A,x as F,C as x,f as D,S as R,R as f,I as v,h as E,i as M,A as N,F as q,j as w,k as O,l as U,W as Z,n as j,T as z,t as G,o as J,p as K,q as Q,r as V,s as X,u as Y,z as _,B as $,H as aa,J as sa,M as oa,V as ta,O as ea,Q as ra,U as pa,X as ia,Y as na,Z as ma,_ as la,a0 as ca,a1 as Ta,a2 as ba,a3 as da,a4 as Sa,a5 as Ba,a6 as La,a7 as Ca,a8 as Ha,a9 as ua,aa as ga,ab as ya,ac as Ia,ad as ha}from"./DocsRenderer-CFRXHY34-xrdFE-63.js";import"./iframe-80GKSfNA.js";import"../sb-preview/runtime.js";import"./index-DRjF_FHU.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-BvEl7W6R.js";import"./index-D-8MO0q_.js";import"./index-CidnEmUr.js";import"./index-DrFu-skq.js";import"./react-18-BZ4hdgop.js";export{c as A,T as ActionBar,b as AddonPanel,d as Badge,S as Bar,B as Blockquote,L as Button,C as ClipboardCode,H as Code,u as DL,g as Div,y as DocumentWrapper,I as EmptyTabContent,h as ErrorFormatter,k as FlexBar,P as Form,W as H1,A as H2,F as H3,x as H4,D as H5,R as H6,f as HR,v as IconButton,E as IconButtonSkeleton,M as Icons,N as Img,q as LI,w as Link,O as ListItem,U as Loader,Z as Modal,j as OL,z as P,G as Placeholder,J as Pre,K as ResetWrapper,Q as ScrollArea,V as Separator,X as Spaced,Y as Span,_ as StorybookIcon,$ as StorybookLogo,aa as Symbols,sa as SyntaxHighlighter,oa as TT,ta as TabBar,ea as TabButton,ra as TabWrapper,pa as Table,ia as Tabs,na as TabsState,ma as TooltipLinkList,la as TooltipMessage,ca as TooltipNote,Ta as UL,ba as WithTooltip,da as WithTooltipPure,Sa as Zoom,Ba as codeCommon,La as components,Ca as createCopyToClipboardFunction,Ha as getStoryHref,ua as icons,ga as interleaveSeparators,ya as nameSpaceClassNames,Ia as resetComponents,ha as withReset}; +import{m as c,a as T,G as b,K as d,P as S,g as B,L,b as C,v as H,w as u,c as g,E as y,$ as I,y as h,d as k,N as P,e as W,D as A,x as F,C as x,f as D,S as R,R as f,I as v,h as E,i as M,A as N,F as q,j as w,k as O,l as U,W as Z,n as j,T as z,t as G,o as J,p as K,q as Q,r as V,s as X,u as Y,z as _,B as $,H as aa,J as sa,M as oa,V as ta,O as ea,Q as ra,U as pa,X as ia,Y as na,Z as ma,_ as la,a0 as ca,a1 as Ta,a2 as ba,a3 as da,a4 as Sa,a5 as Ba,a6 as La,a7 as Ca,a8 as Ha,a9 as ua,aa as ga,ab as ya,ac as Ia,ad as ha}from"./DocsRenderer-CFRXHY34-DG86K5OV.js";import"./iframe-DWIAQds9.js";import"../sb-preview/runtime.js";import"./index-DRjF_FHU.js";import"./jsx-runtime-DR9Q75dM.js";import"./index-BvEl7W6R.js";import"./index-D-8MO0q_.js";import"./index-CidnEmUr.js";import"./index-DrFu-skq.js";import"./react-18-BZ4hdgop.js";export{c as A,T as ActionBar,b as AddonPanel,d as Badge,S as Bar,B as Blockquote,L as Button,C as ClipboardCode,H as Code,u as DL,g as Div,y as DocumentWrapper,I as EmptyTabContent,h as ErrorFormatter,k as FlexBar,P as Form,W as H1,A as H2,F as H3,x as H4,D as H5,R as H6,f as HR,v as IconButton,E as IconButtonSkeleton,M as Icons,N as Img,q as LI,w as Link,O as ListItem,U as Loader,Z as Modal,j as OL,z as P,G as Placeholder,J as Pre,K as ResetWrapper,Q as ScrollArea,V as Separator,X as Spaced,Y as Span,_ as StorybookIcon,$ as StorybookLogo,aa as Symbols,sa as SyntaxHighlighter,oa as TT,ta as TabBar,ea as TabButton,ra as TabWrapper,pa as Table,ia as Tabs,na as TabsState,ma as TooltipLinkList,la as TooltipMessage,ca as TooltipNote,Ta as UL,ba as WithTooltip,da as WithTooltipPure,Sa as Zoom,Ba as codeCommon,La as components,Ca as createCopyToClipboardFunction,Ha as getStoryHref,ua as icons,ga as interleaveSeparators,ya as nameSpaceClassNames,Ia as resetComponents,ha as withReset}; diff --git a/assets/preview-uky1k3DE.js b/assets/preview-fOt-hspA.js similarity index 76% rename from assets/preview-uky1k3DE.js rename to assets/preview-fOt-hspA.js index 44318466..f3f5f63d 100644 --- a/assets/preview-uky1k3DE.js +++ b/assets/preview-fOt-hspA.js @@ -1,2 +1,2 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./DocsRenderer-CFRXHY34-xrdFE-63.js","./iframe-80GKSfNA.js","./index-DRjF_FHU.js","./jsx-runtime-DR9Q75dM.js","./index-BvEl7W6R.js","./index-D-8MO0q_.js","./index-CidnEmUr.js","./index-DrFu-skq.js","./react-18-BZ4hdgop.js"])))=>i.map(i=>d[i]); -import{_ as a}from"./iframe-80GKSfNA.js";import"../sb-preview/runtime.js";var i=Object.entries(globalThis.TAGS_OPTIONS??{}).reduce((e,r)=>{let[t,o]=r;return o.excludeFromDocsStories&&(e[t]=!0),e},{}),d={docs:{renderer:async()=>{let{DocsRenderer:e}=await a(()=>import("./DocsRenderer-CFRXHY34-xrdFE-63.js").then(r=>r.ak),__vite__mapDeps([0,1,2,3,4,5,6,7,8]),import.meta.url);return new e},stories:{filter:e=>(e.tags||[]).filter(r=>i[r]).length===0&&!e.parameters.docs?.disable}}};export{d as parameters}; +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./DocsRenderer-CFRXHY34-DG86K5OV.js","./iframe-DWIAQds9.js","./index-DRjF_FHU.js","./jsx-runtime-DR9Q75dM.js","./index-BvEl7W6R.js","./index-D-8MO0q_.js","./index-CidnEmUr.js","./index-DrFu-skq.js","./react-18-BZ4hdgop.js"])))=>i.map(i=>d[i]); +import{_ as a}from"./iframe-DWIAQds9.js";import"../sb-preview/runtime.js";var i=Object.entries(globalThis.TAGS_OPTIONS??{}).reduce((e,r)=>{let[t,o]=r;return o.excludeFromDocsStories&&(e[t]=!0),e},{}),d={docs:{renderer:async()=>{let{DocsRenderer:e}=await a(()=>import("./DocsRenderer-CFRXHY34-DG86K5OV.js").then(r=>r.ak),__vite__mapDeps([0,1,2,3,4,5,6,7,8]),import.meta.url);return new e},stories:{filter:e=>(e.tags||[]).filter(r=>i[r]).length===0&&!e.parameters.docs?.disable}}};export{d as parameters}; diff --git a/iframe.html b/iframe.html index 923bbcd4..85d947a1 100644 --- a/iframe.html +++ b/iframe.html @@ -513,7 +513,7 @@ window.global = window; - + diff --git a/project.json b/project.json index c500ae3f..9b00404a 100644 --- a/project.json +++ b/project.json @@ -1 +1 @@ -{"generatedAt":1730713734107,"hasCustomBabel":false,"hasCustomWebpack":false,"hasStaticDirs":false,"hasStorybookEslint":true,"refCount":0,"testPackages":{"@playwright/test":"1.48.2","@testing-library/dom":"10.4.0","@testing-library/jest-dom":"6.6.2","@testing-library/react":"16.0.1","@testing-library/user-event":null,"@vitest/coverage-v8":"2.1.4","vitest":"2.1.4"},"packageManager":{"type":"yarn","version":"1.22.22"},"typescriptOptions":{"reactDocgen":"react-docgen-typescript"},"preview":{"usesGlobals":false},"framework":{"name":"@storybook/react-vite","options":{}},"builder":"@storybook/builder-vite","renderer":"@storybook/react","portableStoriesFileCount":12,"storybookVersion":"8.4.0","storybookVersionSpecifier":"^8.1.1","language":"typescript","storybookPackages":{"@storybook/addon-a11y":{"version":"8.4.0"},"@storybook/manager-api":{"version":"8.4.0"},"@storybook/react":{"version":"8.4.0"},"@storybook/react-vite":{"version":"8.4.0"},"@storybook/test":{"version":"8.4.0"},"eslint-plugin-storybook":{"version":"0.10.1"},"storybook":{"version":"8.4.0"}},"addons":{"@storybook/addon-links":{"version":"8.4.0"},"@storybook/addon-essentials":{"version":"8.4.0"},"@storybook/addon-interactions":{"version":"8.4.0"},"@storybook/addon-designs":{"version":"8.0.3"},"@storybook/addon-themes":{"version":"8.4.0"}}} \ No newline at end of file +{"generatedAt":1730713804474,"hasCustomBabel":false,"hasCustomWebpack":false,"hasStaticDirs":false,"hasStorybookEslint":true,"refCount":0,"testPackages":{"@playwright/test":"1.48.2","@testing-library/dom":"10.4.0","@testing-library/jest-dom":"6.6.3","@testing-library/react":"16.0.1","@testing-library/user-event":null,"@vitest/coverage-v8":"2.1.4","vitest":"2.1.4"},"packageManager":{"type":"yarn","version":"1.22.22"},"typescriptOptions":{"reactDocgen":"react-docgen-typescript"},"preview":{"usesGlobals":false},"framework":{"name":"@storybook/react-vite","options":{}},"builder":"@storybook/builder-vite","renderer":"@storybook/react","portableStoriesFileCount":12,"storybookVersion":"8.4.1","storybookVersionSpecifier":"^8.1.1","language":"typescript","storybookPackages":{"@storybook/addon-a11y":{"version":"8.4.1"},"@storybook/manager-api":{"version":"8.4.1"},"@storybook/react":{"version":"8.4.1"},"@storybook/react-vite":{"version":"8.4.1"},"@storybook/test":{"version":"8.4.1"},"eslint-plugin-storybook":{"version":"0.10.2"},"storybook":{"version":"8.4.1"}},"addons":{"@storybook/addon-links":{"version":"8.4.1"},"@storybook/addon-essentials":{"version":"8.4.1"},"@storybook/addon-interactions":{"version":"8.4.1"},"@storybook/addon-designs":{"version":"8.0.4"},"@storybook/addon-themes":{"version":"8.4.1"}}} \ No newline at end of file diff --git a/sb-manager/globals-runtime.js b/sb-manager/globals-runtime.js index abc70985..fb442713 100644 --- a/sb-manager/globals-runtime.js +++ b/sb-manager/globals-runtime.js @@ -40267,7 +40267,7 @@ We(); var dM = I(Hn(), 1), on = I(cM(), 1); // src/manager-api/version.ts -var pM = "8.4.0"; +var pM = "8.4.1"; // src/manager-api/modules/versions.ts var { VERSIONCHECK: r0e } = H, fM = (0, dM.default)(1)(() => {