@baseline-ui/core 0.24.1 → 0.25.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,23 +1,22 @@
1
1
  import { classNames, invariant, filterTruthyValues, getSvgPathFromStroke, getHTMLElement, getTextDimensions, getPlainText, cleanKeyFromGlobImport, getOsSpecificKeyboardShortcutLabel, isUrl } from '@baseline-ui/utils';
2
- import to, { useMemo, useCallback, useContext, useEffect, createContext, useLayoutEffect, useState, useRef, useImperativeHandle, useReducer, Fragment as Fragment$1, createElement } from 'react';
2
+ import to, { useMemo, useImperativeHandle, useCallback, useContext, useEffect, createContext, useLayoutEffect, useState, useRef, useReducer, Fragment as Fragment$1, createElement } from 'react';
3
3
  import { useControlledState, clamp } from '@react-stately/utils';
4
- import { useReducedMotion, animated, useSpring, useTransition, config, easings } from '@react-spring/web';
5
- import { useSeparator, useHover, mergeProps, useOption, useLocale, useListBox, ListKeyboardDelegate, useFocusRing, DragPreview, useNumberField, useNumberFormatter, useSlider, useSliderThumb, VisuallyHidden, useSwitch, useSearchField, Overlay, usePopover, DismissButton, useMenu, useKeyboard, useMenuTrigger, useLink, useDrop, useId, useProgressBar, useTextField, useTooltip, useTooltipTrigger, useOverlayPosition, useCheckbox, useTagGroup, FocusScope, useFocusManager, useButton, usePress, useSelect, HiddenSelect, useTabList, useTab, useDialog, useOverlayTrigger, useLabel, useField, useClipboard, useRadioGroup, useFilter, useInteractOutside, useComboBox, useGridListItem, useGridListSelectionCheckbox, useGridList, useDraggableCollection, useDroppableCollection, ListDropTargetDelegate, useDraggableItem, useListBoxSection, useToggleButton, I18nProvider, useMessageFormatter, useMenuSection, useMenuItem, useDateFormatter, useTag, useTabPanel, useModalOverlay, useRadio, useDropIndicator } from 'react-aria';
4
+ import { useReducedMotion, animated, useSpring, useTransition, easings, config } from '@react-spring/web';
5
+ import { useSeparator, useHover, mergeProps, useOption, useLocale, useListBox, ListKeyboardDelegate, useFocusRing, DragPreview, useNumberField, useNumberFormatter, useSlider, useSliderThumb, VisuallyHidden, useDialog, Overlay, usePopover, DismissButton, useTooltip, useTooltipTrigger, useOverlayPosition, useKeyboard, FocusScope, useSwitch, useSearchField, useMenu, useMenuTrigger, useLink, useDrop, useId, useProgressBar, useTextField, useCheckbox, useTagGroup, useFocusManager, useButton, usePress, useSelect, HiddenSelect, useTabList, useTab, useOverlayTrigger, useLabel, useField, useClipboard, useRadioGroup, useFilter, useInteractOutside, useComboBox, useGridListItem, useGridListSelectionCheckbox, useGridList, useDraggableCollection, useDroppableCollection, ListDropTargetDelegate, useDraggableItem, useListBoxSection, useToggleButton, I18nProvider, useMessageFormatter, useModalOverlay, useMenuSection, useMenuItem, useDateFormatter, useTag, useTabPanel, useRadio, useDropIndicator } from 'react-aria';
6
6
  export { useCollator, useDateFormatter, useNumberFormatter } from 'react-aria';
7
- import { useListState, useNumberFieldState, useSliderState, useToggleState, useSearchFieldState, useTreeState, useMenuTriggerState, useTooltipTriggerState, Item, useSelectState, useTabListState, useOverlayTriggerState, useRadioGroupState, useComboBoxState, useDraggableCollectionState, useDroppableCollectionState, useListData, Section } from 'react-stately';
7
+ import { useListState, useNumberFieldState, useSliderState, useTooltipTriggerState, useToggleState, useSearchFieldState, useTreeState, useMenuTriggerState, useSelectState, useTabListState, Item, useOverlayTriggerState, useRadioGroupState, useComboBoxState, useDraggableCollectionState, useDroppableCollectionState, Section } from 'react-stately';
8
8
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
9
9
  import { CheckmarkIcon, MoreIcon, QuestionmarkCircleIcon, PauseIcon, PlayIcon, AvatarIcon as AvatarIcon$1, TextIcon as TextIcon$1, HighlightTextIcon, SearchIcon as SearchIcon$1, CaretLeftIcon as CaretLeftIcon$3, CaretRightIcon as CaretRightIcon$3 } from '@baseline-ui/icons/24';
10
10
  import { sprinkles, lightTheme, themeVars, queries, darkTheme, layoutSprinkleValues } from '@baseline-ui/tokens';
11
- import { ChevronDownIcon, MinusIcon, PlusIcon, ChevronRightIcon, XIcon } from '@baseline-ui/icons/8';
11
+ import { ChevronDownIcon, MinusIcon, PlusIcon, ChevronRightIcon, XIcon as XIcon$1 } from '@baseline-ui/icons/8';
12
12
  import { ReadOnlyIcon, ErrorFilledIcon, CloseIcon, NoneIcon, UndoIcon, RedoIcon, TrashIcon, ArrowDownCircleFilledIcon, XIcon as XIcon$3, WarningFilledIcon, CheckmarkIcon as CheckmarkIcon$3, CheckFilledIcon, ErrorAltFilledIcon, AvatarIcon, InfoFilledIcon, CaretLeftIcon as CaretLeftIcon$1, CaretRightIcon as CaretRightIcon$1 } from '@baseline-ui/icons/16';
13
- import { CheckmarkIcon as CheckmarkIcon$1, MinusIcon as MinusIcon$1, XIcon as XIcon$2, CaretLeftIcon, CaretRightIcon } from '@baseline-ui/icons/12';
14
- import { XIcon as XIcon$1, TextIcon, BoldIcon, ItalicIcon, UnderlineIcon, AtIcon, CrossCircleFilledIcon, ArrowUpCircleFilledIcon, CheckmarkIcon as CheckmarkIcon$2, CheckFilledIcon as CheckFilledIcon$1, ErrorAltFilledIcon as ErrorAltFilledIcon$1, InfoFilledIcon as InfoFilledIcon$1, WarningFilledIcon as WarningFilledIcon$1, PlusIcon as PlusIcon$1, MinusIcon as MinusIcon$2, LinkIcon, SearchIcon, CaretLeftIcon as CaretLeftIcon$2, CaretRightIcon as CaretRightIcon$2 } from '@baseline-ui/icons/20';
15
- import { assignInlineVars } from '@vanilla-extract/dynamic';
13
+ import { XIcon, TextIcon, BoldIcon, ItalicIcon, UnderlineIcon, AtIcon, CrossCircleFilledIcon, ArrowUpCircleFilledIcon, CheckmarkIcon as CheckmarkIcon$2, CheckFilledIcon as CheckFilledIcon$1, ErrorAltFilledIcon as ErrorAltFilledIcon$1, InfoFilledIcon as InfoFilledIcon$1, WarningFilledIcon as WarningFilledIcon$1, PlusIcon as PlusIcon$1, MinusIcon as MinusIcon$2, LinkIcon, SearchIcon, CaretLeftIcon as CaretLeftIcon$2, CaretRightIcon as CaretRightIcon$2 } from '@baseline-ui/icons/20';
16
14
  import { useGranularEffect, useGranularLayoutEffect } from 'granular-hooks';
17
- import sb from 'lodash/isEmpty';
18
- import vo from 'lodash/isEqual';
19
- import { FocusableProvider } from '@react-aria/focus';
15
+ import J1 from 'lodash/isEmpty';
16
+ import { assignInlineVars } from '@vanilla-extract/dynamic';
20
17
  import { Slot } from '@radix-ui/react-slot';
18
+ import { FocusableProvider } from '@react-aria/focus';
19
+ import { CheckmarkIcon as CheckmarkIcon$1, MinusIcon as MinusIcon$1, XIcon as XIcon$2, CaretLeftIcon, CaretRightIcon } from '@baseline-ui/icons/12';
21
20
  import { parseColor, useColorAreaState, useColorFieldState, useColorSliderState } from '@react-stately/color';
22
21
  import { useColorSwatch, useColorArea, useColorField, useColorSlider } from '@react-aria/color';
23
22
  import { getStroke } from 'perfect-freehand';
@@ -31,12 +30,12 @@ import { createFontColorPlugin, createFontBackgroundColorPlugin, MARK_COLOR, MAR
31
30
  import { createParagraphPlugin, ELEMENT_PARAGRAPH } from '@udecode/plate-paragraph';
32
31
  import { createLinkPlugin, ELEMENT_LINK, upsertLink, unwrapLink } from '@udecode/plate-link';
33
32
  import { withRef, withProps } from '@udecode/cn';
34
- import * as Zm from 'dompurify';
33
+ import * as tu from 'dompurify';
35
34
  import { jsx as jsx$1 } from 'slate-hyperscript';
36
35
  import { useHTMLInputCursorState } from '@udecode/plate-combobox';
37
36
  import { useSelected } from 'slate-react';
38
37
  import { useInteractionModality, PressResponder } from '@react-aria/interactions';
39
- import YP from 'markdown-it';
38
+ import ik from 'markdown-it';
40
39
  import { announce } from '@react-aria/live-announcer';
41
40
  import { useActionGroup, useActionGroupItem } from '@react-aria/actiongroup';
42
41
 
@@ -49,8 +48,8 @@ import { useActionGroup, useActionGroupItem } from '@react-aria/actiongroup';
49
48
  * This notice may not be removed from this file.
50
49
  *
51
50
  */
52
- var we=typeof document<"u"?to.useLayoutEffect:()=>{};function ca(e){let t=useRef(null);return we(()=>{t.current=e;},[e]),useCallback((...o)=>{let r=t.current;return r?.(...o)},[])}function da(e){let[t,o]=useState(e),r=useRef(null),a=ca(()=>{if(!r.current)return;let n=r.current.next();if(n.done){r.current=null;return}t===n.value?a():o(n.value);});we(()=>{r.current&&a();});let i=ca(n=>{r.current=n(t),a();});return [t,i]}var ge=e=>{var t;return (t=e?.ownerDocument)!==null&&t!==void 0?t:document},Q=e=>{if(e&&"window"in e&&e.window===e)return e;let t=Vt(e);return t instanceof ShadowRoot?t.ownerDocument.defaultView||window:t?.defaultView||window},Vt=e=>{if(!e)return document;let t=e.getRootNode?e.getRootNode():document;return e.isConnected?(t):null};function N(...e){return e.length===1?e[0]:t=>{for(let o of e)typeof o=="function"?o(t):o!=null&&(o.current=t);}}var Pf=new Set(["id"]),kf=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),wf=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),Rf=/^(data-.*)$/;function ma(e,t={}){let{labelable:o,isLink:r,propNames:a}=t,i={};for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(Pf.has(n)||o&&kf.has(n)||r&&wf.has(n)||a?.has(n)||Rf.test(n))&&(i[n]=e[n]);return i}function vn(e){var t;return typeof window>"u"||window.navigator==null?!1:((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.brands.some(o=>e.test(o.brand)))||e.test(window.navigator.userAgent)}function ua(e){var t;return typeof window<"u"&&window.navigator!=null?e.test(((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.platform)||window.navigator.platform):!1}function _n(){return ua(/^Mac/i)}function zn(){return ua(/^iPhone/i)}function hn(){return ua(/^iPad/i)||_n()&&navigator.maxTouchPoints>1}function fa(){return zn()||hn()}function ya(){return vn(/Android/i)}function Ko(){return vn(/Firefox/i)}function Re(e){let t=useRef(null);return useMemo(()=>({get current(){return t.current},set current(o){t.current=o,typeof e=="function"?e(o):e&&(e.current=o);}}),[e])}function Sf(){return typeof window.ResizeObserver<"u"}function ba(e){let{ref:t,onResize:o}=e;useEffect(()=>{let r=t?.current;if(r)if(Sf()){let a=new window.ResizeObserver(i=>{i.length&&o();});return a.observe(r),()=>{r&&a.unobserve(r);}}else return window.addEventListener("resize",o,!1),()=>{window.removeEventListener("resize",o,!1);}},[o,t]);}function Bf(e){return "type"in e&&e.type==="section"?jsx(Section,{items:e.children,title:e.title,children:t=>jsx(Item,{children:t.label},t.id)},e.id):(invariant("label"in e,"Item doesn't have a label"),jsx(Item,{textValue:e.label,children:e.label},e.id))}function se(){return useCallback(e=>Bf(e),[])}function Cn(e,t,o){let{direction:r}=useLocale(),a=useDraggableCollectionState({...e,collection:t.collection,selectionManager:t.selectionManager,isDisabled:!e.enableReorder,getItems:e.getItems||(l=>[...l].map(s=>{let p=t.collection.getItem(s);return invariant(p,"Expected item to be defined."),{"text/plain":p.textValue}}))});useDraggableCollection(e,a,o);let i=useDroppableCollectionState({...e,collection:t.collection,selectionManager:t.selectionManager}),{collectionProps:n}=useDroppableCollection({...e,keyboardDelegate:new ListKeyboardDelegate({collection:t.collection,disabledKeys:t.disabledKeys,ref:o,orientation:e.orientation,layout:e.layout,direction:r}),dropTargetDelegate:new ListDropTargetDelegate(t.collection,o)},i,o);return {collectionProps:n,dragState:a,dropState:i}}function Uf(e,t){if(typeof e!="object"||!e)return e;var o=e[Symbol.toPrimitive];if(o!==void 0){var r=o.call(e,t||"default");if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return (t==="string"?String:Number)(e)}function qf(e){var t=Uf(e,"string");return typeof t=="symbol"?t:String(t)}function Kf(e,t,o){return t=qf(t),t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function Pn(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),o.push.apply(o,r);}return o}function kn(e){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?Pn(Object(o),!0).forEach(function(r){Kf(e,r,o[r]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):Pn(Object(o)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(o,r));});}return e}function wn(e,t){var o={};for(var r in e)o[r]=t(e[r],r);return o}var Gf=(e,t,o)=>{for(var r of Object.keys(e)){var a;if(e[r]!==((a=t[r])!==null&&a!==void 0?a:o[r]))return !1}return !0},_=e=>{var t=o=>{var r=e.defaultClassName,a=kn(kn({},e.defaultVariants),o);for(var i in a){var n,l=(n=a[i])!==null&&n!==void 0?n:e.defaultVariants[i];if(l!=null){var s=l;typeof s=="boolean"&&(s=s===!0?"true":"false");var p=e.variantClassNames[i][s];p&&(r+=" "+p);}}for(var[d,u]of e.compoundVariants)Gf(d,a,e.defaultVariants)&&(r+=" "+u);return r};return t.variants=()=>Object.keys(e.variantClassNames),t.classNames={get base(){return e.defaultClassName.split(" ")[0]},get variants(){return wn(e.variantClassNames,o=>wn(o,r=>r.split(" ")[0]))}},t};var Rn=_({defaultClassName:"_6n12k9b _1yep5z6l0 _1yep5z6kz _1yep5z6hk _1yep5z6ki",variantClassNames:{isDropTarget:{true:"_1yep5z612n"},orientation:{vertical:"_1yep5z6166",horizontal:"_1yep5z6167"}},defaultVariants:{},compoundVariants:[]}),In="_6n12k98 _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",Tn=_({defaultClassName:"_6n12k99 _1yep5z6ev _1yep5z6da _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),Nn=_({defaultClassName:"_6n12k91 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6dy _1yep5z6eu _1yep5z6ki _1yep5z6kl _1yep5z6ky _1yep5z6kx _1yep5z6kv _1yep5z6ks",variantClassNames:{isSelected:{},isFocused:{true:"_1yep5z612n _1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612w _1yep5z612x _1yep5z612y"},isHovered:{true:"_1yep5z6114",false:"_1yep5z6113"},isFirstChild:{true:"_6n12k95"},isLastChild:{true:"_6n12k96"},isDisabled:{true:"z9nup83 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Sn="_6n12k90";var Ln=_({defaultClassName:"gukncs0",variantClassNames:{isVertical:{true:"gukncs1"},isSecondary:{true:"gukncs2"}},defaultVariants:{},compoundVariants:[]});var F=to.forwardRef(({className:e,style:t,variant:o="primary",orientation:r="horizontal",UNSAFE_omitRole:a,elementType:i="div",...n},l)=>{let{separatorProps:s}=useSeparator({...n,orientation:r,elementType:i});return jsx(i,{...s,className:classNames(Ln({isVertical:r==="vertical",isSecondary:o==="secondary"}),"BaselineUI-Separator",e),"data-orientation":r,"data-block-id":n["data-block-id"],style:t,role:a?void 0:s.role,ref:l})});F.displayName="Separator";function oy(e){return sprinkles.properties.has(e)}var M=to.forwardRef(({elementType:e="div",children:t,...o},r)=>{let a=e,{sprinkleProps:i,domProps:n}=useMemo(()=>{let l={},s={};for(let p in o)oy(p)?l[p]=o[p]:s[p]=o[p];return {sprinkleProps:l,domProps:s}},[o]);return jsx(a,{...n,className:classNames(sprinkles(i),"BaselineUI-Box",n.className),ref:r,children:t})});M.displayName="Box";var Wo=to.forwardRef(({item:e,isDisabled:t,isFocusVisible:o,isSelected:r,liProps:a,showSelectedIcon:i,description:n,descriptionProps:l,labelProps:s,isFocused:p,isPressed:d,_state:u},c)=>{invariant(e.value&&(e.value.type==="option"||e.value.type===void 0),"Item cannot be a section");let{icon:m,label:f}=e.value,{hoverProps:y,isHovered:g}=useHover({isDisabled:t}),v=filterTruthyValues({"data-selected":r,"data-disabled":t,"data-focused":p,"data-hovered":g,"data-pressed":d,"data-focus-visible":o,"data-selection-mode":u.selectionManager.selectionMode});return jsxs("li",{...mergeProps(a,y,v),className:classNames(Nn({isHovered:g,isFocused:o,isFirstChild:u.collection.getFirstKey()===e.key,isLastChild:u.collection.getLastKey()===e.key,isDisabled:t}),"BaselineUI-ListBox-Option"),ref:c,children:[jsxs(M,{display:"flex",alignItems:"center",gap:"lg",children:[i?jsx("span",{"aria-hidden":!0,style:{height:24,width:24},children:r?jsx(CheckmarkIcon,{size:24}):null}):null,m?jsx(m,{size:24}):null,jsx("span",{...s,children:f})]}),n?jsx("span",{className:Tn({isDisabled:t}),...l,children:n}):null]})});Wo.displayName="DefaultRenderOption";var _a=({dropState:e,orientation:t="vertical",dropIndicatorStyle:o,dropIndicatorClassName:r,renderDropIndicator:a=({isDropTarget:n,isHidden:l,dropIndicatorProps:s,orientation:p},d)=>l?null:jsx("li",{...s,ref:d,"data-drop-target":n,className:classNames(Rn({isDropTarget:n,orientation:p}),"BaselineUI-DropIndicator",r),style:o}),...i})=>{let n=to.useRef(null),{dropIndicatorProps:l,isHidden:s,isDropTarget:p}=useDropIndicator(i,e,n);return a({dropIndicatorProps:{...l,role:"option"},isHidden:s,isDropTarget:p,orientation:t},n)};var Hn=({item:e,children:t,state:o,dragState:r,...a})=>{let{dragProps:i}=useDraggableItem({key:e.key},r);return jsxs(Fragment,{children:[jsx(_a,{target:{type:"item",key:e.key,dropPosition:"before"},...a}),t(i),o.collection.getKeyAfter(e.key)==null&&jsx(_a,{target:{type:"item",key:e.key,dropPosition:"after"},...a})]})};Hn.displayName="DraggableListOption";var Xo=to.forwardRef(({item:e,renderOption:t=(c,m,f)=>jsx(Wo,{item:c,liProps:m.optionProps,...m,ref:f}),showSelectedIcon:o,state:r,dragState:a,dropState:i,orientation:n,dropIndicatorStyle:l,dropIndicatorClassName:s,optionStyle:p,optionClassName:d},u)=>{let c=to.useRef(null),m=useOption({key:e.key},r,c),{value:f}=e;invariant(!!f),invariant(!("children"in e),"ListSection should not be passed to ListOption");let y={style:typeof p=="function"?p(f):p,className:typeof d=="function"?d(f):d};return a&&i?jsx(Hn,{orientation:n,state:r,item:e,dropState:i,dragState:a,dropIndicatorStyle:l,dropIndicatorClassName:s,children:g=>t(e,{...m,showSelectedIcon:o,_state:r,optionProps:mergeProps(m.optionProps,g,y)},N(c,u))}):t(e,{...m,showSelectedIcon:o,_state:r,optionProps:mergeProps(m.optionProps,y)},N(c,u))});Xo.displayName="Option";var za=({section:e,state:t,sectionClassName:o,sectionStyle:r,...a})=>{let{itemProps:i,groupProps:n}=useListBoxSection({heading:e.rendered,"aria-label":e["aria-label"]}),l=t.collection.getChildren?.(e.key);invariant(l,"items with type `section` must have children");let{value:s}=e,p=typeof r=="function"?r(s):r,d=typeof o=="function"?o(s):o;return jsxs(Fragment,{children:[e.key!==t.collection.getFirstKey()&&jsx(F,{UNSAFE_omitRole:!0}),jsx("li",{...i,style:{...i.style,...p},className:classNames(Sn,d,"BaselineUI-ListBox-Section"),children:jsx("ul",{...n,children:[...l].map(u=>jsx(Xo,{item:u,state:t,...a},u.key))})})]})};za.displayName="ListBoxSection";var We=to.createContext(null),ha=to.forwardRef(({className:e,layout:t="stack",orientation:o="vertical",showSelectedIcon:r=!0,style:a,renderOption:i,enableReorder:n=!1,"data-block-id":l,renderDragPreview:s,onReorder:p,state:d,...u},c)=>{let m=to.useRef(null),{direction:f}=useLocale(),y=to.useRef(null),{listBoxProps:g}=useListBox({...u,shouldSelectOnPressUp:n,keyboardDelegate:new ListKeyboardDelegate({collection:d.collection,ref:y,layout:t,orientation:o,direction:f,disabledKeys:d.disabledKeys})},d,y),v=useReducedMotion(),b=useCallback(T=>{let I=ge(y.current);p&&(!v&&"startViewTransition"in I?I.startViewTransition(()=>{p(T);}):p(T));},[p,v]),{collectionProps:h,dragState:z,dropState:x}=Cn({...u,onReorder:b,layout:t,orientation:o,enableReorder:n,preview:m},d,y),{isFocusVisible:R,isFocused:C,focusProps:P}=useFocusRing(),k=filterTruthyValues({"data-block-id":l,"data-layout":t,"data-empty":d.collection.size===0,"data-focused":C,"data-focus-visible":R,"data-orientation":o});return jsxs("ul",{...mergeProps(g,P,k,h),className:classNames(In,"BaselineUI-ListBox",e),style:a,ref:N(c,y),children:[[...d.collection].map(T=>{let I={key:T.key,state:d,dragState:z,dropState:x,renderOption:i,renderDropIndicator:u.renderDropIndicator,showSelectedIcon:r,orientation:o,dropIndicatorStyle:u.dropIndicatorStyle,dropIndicatorClassName:u.dropIndicatorClassName,optionStyle:u.optionStyle,optionClassName:u.optionClassName};return T.type==="section"?jsx(za,{...I,section:T}):jsx(Xo,{...I,item:T})}),s?jsx(DragPreview,{ref:m,children:s}):null]})});ha.displayName="ListBoxCore";var On=to.forwardRef((e,t)=>{let o=se(),r=useListState({...e,children:o});return jsx(ha,{...e,ref:t,state:r})});On.displayName="ListBoxStandalone";var te=to.forwardRef((e,t)=>{let o=useContext(We);return useEffect(()=>{if(!e.items&&!o)throw new Error("ListBox: You must provide a `state` or `items` prop to render the listbox.")},[e.items,o]),o?jsx(ha,{...e,ref:t,state:o}):jsx(On,{...e,ref:t})});te.displayName="ListBox";var $t="uf19bsg _1yep5z6ki",Vn=_({defaultClassName:"uf19bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0 _1yep5z6kx _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ks",variantClassNames:{size:{xxs:"uf19bs1",xs:"uf19bs2",sm:"uf19bs3",md:"uf19bs4",lg:"uf19bs5 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy"},isHovered:{true:"uf19bs6"},isDisabled:{true:"uf19bs7 _1yep5z610d"},isFocusVisible:{true:"uf19bs8"},variant:{primary:"uf19bs9",secondary:"uf19bsa",tertiary:"uf19bsb",ghost:"uf19bsc",toolbar:"_1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg",popover:"uf19bse _1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z6mn _1yep5z6mo _1yep5z6mp _1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nq _1yep5z6nr _1yep5z6ns _1yep5z6uz _1yep5z6v0 _1yep5z6v1"},isPressed:{true:"uf19bsf"}},defaultVariants:{},compoundVariants:[[{variant:"toolbar",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"primary",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"secondary",isHovered:!0,isFocusVisible:!1},"_1yep5z61ln"],[{variant:"tertiary",isHovered:!0,isFocusVisible:!1},"_1yep5z61lm _1yep5z61mg"],[{variant:"ghost",isHovered:!0,isFocusVisible:!1},"_1yep5z61ls"],[{variant:"popover",isHovered:!0,isFocusVisible:!1},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"toolbar",isPressed:!0},"_1yep5z61mg"],[{variant:"primary",isPressed:!0},"_1yep5z61mf"],[{variant:"secondary",isPressed:!0},"_1yep5z61ln"],[{variant:"tertiary",isPressed:!0},"_1yep5z61lq _1yep5z61mg"],[{variant:"ghost",isPressed:!0},"_1yep5z61lt"],[{variant:"popover",isPressed:!0},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"ghost",isDisabled:!1},"_1yep5z61lr"],[{variant:"popover",size:"lg"},"_1yep5z61h4 _1yep5z61h5 _1yep5z61h6 _1yep5z61hs _1yep5z61ht _1yep5z61hu _1yep5z61ig _1yep5z61ih _1yep5z61ii _1yep5z61j4 _1yep5z61j5 _1yep5z61j6"]]});var Yo=to.createContext({state:null,overlayTriggerAria:{triggerProps:{},overlayProps:{}},triggerRef:void 0}),Xe=({children:e,...t})=>{let o=to.useRef(null),r=useOverlayTriggerState(t),a=useOverlayTrigger(t,r),i=useMemo(()=>({state:r,overlayTriggerAria:a,triggerRef:o}),[r,a]);return jsx(Yo.Provider,{value:i,children:typeof e=="function"?e(r):e})};var jn={bottom:"_1gzftth2",top:"_1gzftth3",right:"_1gzftth4",left:"_1gzftth5"},$n="_1gzftth1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",Un="_1gzftth6",qn="_1gzftth8",Kn="_1gzftth7",Gn="var(--_1gzftth0)";function Wn(e){return typeof e=="object"&&typeof e.left=="number"&&typeof e.top=="number"&&(typeof e.width=="number"||e.width===void 0)&&(typeof e.height=="number"||e.height===void 0)}var Ut=to.createContext({isSelected:!1,ref:void 0}),Ye=({children:e,anchorRect:t})=>{let{state:o,overlayTriggerAria:r,triggerRef:a}=useContext(Yo);invariant(o,"PopoverTrigger must be used within a Popover");let{triggerProps:i}=r,n=useMemo(()=>({...i,isSelected:o.isOpen,ref:a}),[i,o.isOpen,a]);return invariant(!t&&e||t&&!e,"Either one of anchorRect or children has to be provided."),invariant(!t||Wn(t),"If provided, the anchorRect prop must be an object with left and top number values, and optionally width and height."),jsx(Ut.Provider,{value:n,children:t?jsx("button",{className:classNames(qn,"BaselineUI-PopoverTrigger-Hidden"),style:t,ref:a,tabIndex:-1},JSON.stringify(t)):e})};var qt=e=>{let t=to.useRef(null),{ref:o,...r}=useContext(Ut)||{},{buttonProps:a,isPressed:i}=useButton({...e,...r},t);return {buttonProps:a,isPressed:i,ref:N(t,o||null)}},Kt=(e,t)=>{let o=to.useRef(null),{ref:r,...a}=useContext(Ut)||{},{buttonProps:i,isPressed:n}=useToggleButton({...e,...a},t,o);return {buttonProps:i,isPressed:n,ref:N(o,r||null)}};var Gt=_({defaultClassName:"oom8bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6dy _1yep5z6ki",variantClassNames:{variant:{primary:"oom8bs1",secondary:"oom8bs2",tertiary:"oom8bs3",ghost:"oom8bs4",popover:"oom8bs5",toolbar:"oom8bs6",success:"oom8bs7",warning:"oom8bs8",error:"oom8bs9"},isDisabled:{true:"oom8bsa"},isFocusVisible:{true:"oom8bsb"},isHovered:{true:"oom8bsc"},size:{sm:"oom8bsd",md:"oom8bse",lg:"oom8bsf"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isHovered:!0},"oom8bsg"],[{variant:"secondary",isHovered:!0},"oom8bsh"],[{variant:"tertiary",isHovered:!0},"oom8bsi"],[{variant:"popover",isHovered:!0},"oom8bsj"],[{variant:"ghost",isHovered:!0},"oom8bsk"],[{variant:"success",isHovered:!0},"oom8bsl"],[{variant:"warning",isHovered:!0},"oom8bsm"],[{variant:"error",isHovered:!0},"oom8bsn"],[{variant:"primary",isFocusVisible:!0},"oom8bso"],[{variant:"tertiary",isFocusVisible:!0},"oom8bsp"],[{variant:"success",isFocusVisible:!0},"oom8bsq"],[{variant:"warning",isFocusVisible:!0},"oom8bsr"],[{variant:"error",isFocusVisible:!0},"oom8bss"]]});var e1={sm:16,md:20,lg:24},O=to.forwardRef(({label:e,style:t,className:o,iconStart:r,iconEnd:a,variant:i="primary",elementType:n="button",isDisabled:l,size:s="sm","data-block-id":p,...d},u)=>{let{buttonProps:c,isPressed:m,ref:f}=qt({...d,elementType:n,isDisabled:l}),y=e1[s],{hoverProps:g,isHovered:v}=useHover({isDisabled:l}),{isFocusVisible:b,isFocused:h,focusProps:z}=useFocusRing(),x=filterTruthyValues({"data-block-id":p,"data-disabled":l,"data-focused":h,"data-focus-visible":b,"data-hovered":v,"data-pressed":m});return jsxs(n,{...mergeProps(c,g,z,x),className:classNames(Gt({isDisabled:!!l,isFocusVisible:b,isHovered:v,variant:i,size:s}),"BaselineUI-ActionButton",o),style:t,ref:N(u,f),children:[!!r&&jsx(r,{size:y}),e,!!a&&jsx(a,{size:y}),i==="popover"&&jsx(ChevronDownIcon,{size:8,className:$t})]})});O.displayName="ActionButton";var Qn=_({defaultClassName:"z9nup84",variantClassNames:{size:{xs:"z9nup85",sm:"z9nup86"}},defaultVariants:{},compoundVariants:[]});var Wt="z9nup80",po="z9nup83";var Jn="z9nup87";var es=to.forwardRef(({className:e,node:t},o)=>{let r=to.useRef(null);return to.useEffect(()=>{let a=r.current;return a?.append(t),()=>{a?.contains(t)&&t.remove();}},[t]),jsx("div",{className:classNames(Wt,e),ref:N(o,r)})});es.displayName="DomNodeRenderer";var os="_14uvjig0 z9nup81",ts="_14uvjig7",rs="_14uvjig3",as=_({defaultClassName:"_14uvjig4",variantClassNames:{isDisabled:{true:"_14uvjig5"},hasNumberInput:{false:"_14uvjig6"}},defaultVariants:{},compoundVariants:[]}),is=_({defaultClassName:"_14uvjige _14uvjig1",variantClassNames:{active:{true:"_14uvjigf _14uvjig2"},isDisabled:{true:"_14uvjigg"},isReadOnly:{true:"_14uvjigh"},isFocusVisible:{true:"_14uvjigi _14uvjig2"},isHovered:{true:"_14uvjigj _14uvjig2"}},defaultVariants:{},compoundVariants:[]}),ns="_14uvjig8",ss=_({defaultClassName:"_14uvjig9 _14uvjig1",variantClassNames:{active:{true:"_14uvjig2"},isFocusVisible:{true:"_14uvjigb _14uvjig2"},isDisabled:{true:"_14uvjigc"},isHovered:{true:"_14uvjig2"}},defaultVariants:{},compoundVariants:[]});var co=_({defaultClassName:"nrh1ehx",variantClassNames:{isDisabled:{true:"nrh1ehy"},hasError:{true:"nrh1ehz"},labelPosition:{start:"nrh1eh10",top:"nrh1eh11"}},defaultVariants:{},compoundVariants:[]}),Xt=_({defaultClassName:"nrh1eho",variantClassNames:{isDisabled:{true:"nrh1ehp"},labelPosition:{top:"nrh1ehq",start:"nrh1ehr"}},defaultVariants:{},compoundVariants:[]}),mo=_({defaultClassName:"nrh1ehs",variantClassNames:{validationState:{valid:"nrh1eht",error:"nrh1ehu",warning:"nrh1ehv"},isReadOnly:{true:"nrh1ehw"}},defaultVariants:{},compoundVariants:[]}),Me="nrh1eh3",De=_({defaultClassName:"nrh1eh4",variantClassNames:{labelPosition:{top:"nrh1eh5",start:"nrh1eh6"},hasMessage:{true:"nrh1eh7"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"nrh1eh8"]]}),Be=_({defaultClassName:"nrh1eh0",variantClassNames:{labelPosition:{top:"z9nup81",start:"nrh1eh2 z9nup82"}},defaultVariants:{},compoundVariants:[]}),uo=_({defaultClassName:"nrh1eh9 z9nup82",variantClassNames:{validationState:{valid:"nrh1eha",error:"nrh1ehb",warning:"nrh1ehc"},isHovered:{true:"nrh1ehd"},isFocused:{true:"nrh1ehe"},isDisabled:{true:"nrh1ehf"},variant:{primary:"nrh1ehg",ghost:"nrh1ehh"},isReadOnly:{true:"nrh1ehi"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"nrh1ehj"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"nrh1ehk"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"nrh1ehl"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"nrh1ehm"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"nrh1ehn"]]});function _e({description:e,errorMessageProps:t,descriptionProps:o,warningMessage:r,errorMessage:a,labelPosition:i,isDisabled:n}){return e?jsx("div",{...o,className:co({isDisabled:n,labelPosition:i}),children:e}):a?jsx("div",{...t,className:co({hasError:!0,labelPosition:i}),children:a}):r?jsx("div",{className:co({isDisabled:n,labelPosition:i}),children:r}):null}var ls=_({defaultClassName:"_1lnwne1 z9nup82",variantClassNames:{isHoveredOrFocused:{true:"_1lnwne2"},isInteractive:{false:"z9nup83"}},defaultVariants:{},compoundVariants:[[{isHoveredOrFocused:!0,isInteractive:!0},"_1lnwne4"]]}),ps="_1lnwne0";var d1={xxs:8,xs:12,sm:16,md:20,lg:24},L=to.forwardRef(({className:e,style:t,icon:o,size:r="md",variant:a="primary",UNSAFE_NON_INTERACTIVE:i,elementType:n=i?"div":"button",...l},s)=>{!l["aria-label"]&&!l["aria-labelledby"]&&console.warn("An `ActionIconButton` requires an aria-label or aria-labelledby prop.");let{buttonProps:p,isPressed:d,ref:u}=qt({...l,elementType:n}),{isFocusVisible:c,isFocused:m,focusProps:f}=useFocusRing(),{hoverProps:y,isHovered:g}=useHover({isDisabled:l.isDisabled}),v=filterTruthyValues({"data-block-id":l["data-block-id"],"data-focused":m,"data-focus-visible":c,"data-disabled":l.isDisabled,"data-hovered":g,"data-pressed":d});return jsxs(n,{...mergeProps(p,y,f,v),className:classNames(Vn({variant:a,size:r,isDisabled:!!l.isDisabled,isFocusVisible:c,isHovered:g,isPressed:d}),"BaselineUI-ActionIconButton",e),ref:N(s,u),style:t,...i&&{tabIndex:void 0,role:void 0,"aria-label":void 0,"aria-labelledby":void 0,"aria-disabled":void 0},children:[jsx(o,{role:"presentation",size:d1[r]}),a==="popover"&&jsx(ChevronDownIcon,{size:8,className:$t})]})});L.displayName="ActionIconButton";var Ie=to.forwardRef(({className:e,style:t,labelPosition:o="top",variant:r="primary",showStepper:a=!0,...i},n)=>{let l=to.useRef(null),{locale:s}=useLocale(),p=useNumberFieldState({...i,locale:s}),{hoverProps:d,isHovered:u}=useHover({isDisabled:i.isDisabled}),{focusProps:c,isFocusVisible:m,isFocused:f}=useFocusRing(),{labelProps:y,decrementButtonProps:g,inputProps:v,incrementButtonProps:b,groupProps:h,descriptionProps:z,errorMessageProps:x}=useNumberField(i,p,l),R=useMemo(()=>i.isReadOnly?ReadOnlyIcon:i.isInvalid?ErrorFilledIcon:null,[i.isInvalid,i.isReadOnly]),C=_e({description:i.description,errorMessageProps:x,descriptionProps:z,errorMessage:i.errorMessage,labelPosition:o,isDisabled:i.isDisabled}),P=filterTruthyValues({"data-disabled":i.isDisabled,"data-readonly":i.isReadOnly,"data-hovered":u,"data-focused":f,"data-focus-visible":m,"data-invalid":i.isInvalid,"data-block-id":i["data-block-id"]});return jsxs("div",{style:t,className:classNames(Be({labelPosition:o}),"BaselineUI-NumberInput",e),...P,ref:n,children:[i.label?jsxs("div",{className:De({labelPosition:o,hasMessage:!!C}),children:[jsx("label",{...y,className:Me,children:i.label}),o==="start"&&C]}):null,jsxs("div",{className:classNames({[po]:i.isDisabled}),children:[jsxs("div",{...mergeProps(h,d),className:classNames(uo({isHovered:u,isDisabled:!!i.isDisabled,isReadOnly:!!i.isReadOnly,validationState:i.isInvalid?"error":"valid",isFocused:f,variant:r}),{[ps]:o==="start"},"BaselineUI-NumberInput-Container"),children:[jsx("input",{...mergeProps(v,c),ref:l,className:classNames("BaselineUI-NumberInput-Input",Xt({isDisabled:i.isDisabled,labelPosition:o}))}),R?jsx(R,{className:mo({validationState:"error",isReadOnly:i.isReadOnly}),size:16}):null,a?jsxs("div",{className:ls({isHoveredOrFocused:u||f,isInteractive:!i.isReadOnly&&!i.isDisabled}),children:[jsx(L,{variant:"secondary",size:"xxs",icon:MinusIcon,...g,className:"BaselineUI-NumberInput-DecrementButton"}),jsx(F,{style:{height:16},orientation:"vertical"}),jsx(L,{variant:"secondary",size:"xxs",icon:PlusIcon,...b,className:"BaselineUI-NumberInput-DecrementButton"})]}):null]}),o==="top"&&C]})]})});Ie.displayName="NumberInput";var Qt=to.forwardRef(({className:e,style:t,onChange:o,onChangeEnd:r,numberFormatOptions:a,isDisabled:i,step:n,minValue:l,maxValue:s,value:p,"aria-label":d,"aria-labelledby":u,"aria-details":c,"aria-describedby":m,"data-block-id":f,defaultValue:y,isReadOnly:g,label:v,id:b,includeNumberInput:h},z)=>{let x=to.useRef(null),R={onChange:o===void 0?void 0:E=>{o(E[0]);},isDisabled:i||g,step:n,minValue:l,maxValue:s,onChangeEnd:r===void 0?void 0:E=>{r(E[0]);},value:p===void 0?void 0:[p],defaultValue:y===void 0?void 0:[y],"aria-label":d,"aria-labelledby":u,"aria-details":c,"aria-describedby":m,id:b,label:v},C=useNumberFormatter(a),P=useSliderState({...R,numberFormatter:C}),{trackProps:k,groupProps:T,labelProps:I}=useSlider(R,P,x),D=jsx(Ie,{variant:"ghost",showStepper:!1,"aria-label":d,"aria-labelledby":I.id,value:P.getThumbValue(0),formatOptions:a,onChange:E=>{P.setThumbValue(0,E);},style:{width:55,textAlign:"right",flexShrink:0}});return jsxs("div",{...T,style:t,"data-block-id":f,className:classNames(os,"BaselineUI-Slider",e),children:[v?jsxs("div",{className:rs,children:[jsx("label",{...I,className:classNames(as({isDisabled:i,hasNumberInput:!!h}),"BaselineUI-Slider-Label"),children:v}),h?D:null]}):null,jsxs("div",{className:ts,children:[jsx("div",{...k,className:classNames(ns,"BaselineUI-Slider-Track"),ref:N(x,z),"data-testid":"track",children:jsx(L1,{state:P,trackRef:x,isDisabled:i,isReadOnly:g})}),h&&!v?D:null]})]})});Qt.displayName="Slider";function L1({state:e,trackRef:t,isDisabled:o,isReadOnly:r}){let a=to.useRef(null),{thumbProps:i,inputProps:n,isDragging:l}=useSliderThumb({trackRef:t,inputRef:a},e),{focusProps:s,isFocused:p,isFocusVisible:d}=useFocusRing(),{hoverProps:u,isHovered:c}=useHover({isDisabled:o}),m=filterTruthyValues({"data-disabled":o,"data-readonly":r,"data-hovered":c,"data-focus-visible":d,"data-dragging":l,"data-focused":p});return jsxs(Fragment,{children:[jsx("div",{className:classNames(ss({isDisabled:o,isFocusVisible:d,active:l,isHovered:c}),"BaselineUI-Slider-TrackHighlight"),style:{width:i.style?.left},"data-testid":"track-highlight"}),jsx("div",{...mergeProps(i,u,m),className:classNames(is({isDisabled:o,isFocusVisible:d,active:l,isReadOnly:r,isHovered:c}),"BaselineUI-Slider-Thumb"),"data-testid":"thumb",children:jsx(VisuallyHidden,{children:jsx("input",{ref:a,...mergeProps(n,s)})})})]})}var fs=_({defaultClassName:"bpklwa7",variantClassNames:{isReadOnly:{true:"bpklwa8"},isDisabled:{true:"bpklwa9"},isSelected:{true:"bpklwaa"},isFocused:{true:"bpklwab"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"bpklwac"]]}),ys=_({defaultClassName:"bpklwae",variantClassNames:{isDisabled:{true:"bpklwaf"},isSelected:{true:"bpklwag"},isReadOnly:{true:"bpklwah"}},defaultVariants:{},compoundVariants:[]}),bs="bpklwad",gs=_({defaultClassName:"bpklwa0",variantClassNames:{labelPosition:{top:"bpklwa1",left:"bpklwa2"}},defaultVariants:{},compoundVariants:[]}),vs="bpklwa6",_s=_({defaultClassName:"bpklwa3",variantClassNames:{labelPosition:{top:"bpklwa4",left:"bpklwa5"}},defaultVariants:{},compoundVariants:[]});var Cs=to.forwardRef(({className:e,label:t,labelPosition:o="top",statusLabel:r,style:a,"data-block-id":i,...n},l)=>{let s=to.useRef(null),p=useToggleState(n),{inputProps:d,isPressed:u}=useSwitch(n,p,s),{isFocusVisible:c,focusProps:m}=useFocusRing(),{hoverProps:f,isHovered:y}=useHover({isDisabled:n.isDisabled}),g=filterTruthyValues({"data-block-id":i,"data-focused":c,"data-disabled":n.isDisabled,"data-focus-visible":c,"data-selected":p.isSelected,"data-readonly":n.isReadOnly,"data-hovered":y,"data-pressed":u}),v=jsx("div",{className:classNames(fs({isSelected:p.isSelected,isDisabled:!!n.isDisabled,isFocused:c,isReadOnly:!!n.isReadOnly}),"BaselineUI-Switch-Track"),children:jsx("div",{className:classNames(ys({isSelected:p.isSelected,isDisabled:n.isDisabled,isReadOnly:n.isReadOnly}),"BaselineUI-Switch-Knob"),"data-testid":"switch-knob"})});return jsxs("label",{...mergeProps(g,f),className:classNames(gs({labelPosition:o}),"BaselineUI-Switch",e),style:a,ref:l,children:[t?jsx("span",{className:classNames(bs,"BaselineUI-Switch-Label"),children:t}):null,jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(d,m),ref:s})}),r?jsxs("div",{className:_s({labelPosition:o}),children:[jsx("span",{className:classNames("BaselineUI-Switch-Status-Label",vs),children:p.isSelected?r.on:r.off}),v]}):v]})});Cs.displayName="Switch";var Ps="_19n40yy9",ks=_({defaultClassName:"_19n40yy0",variantClassNames:{size:{lg:"_19n40yy1",md:"_19n40yy2",sm:"_19n40yy3"},variant:{primary:"_19n40yy4",ghost:"_19n40yy5"},isFocused:{true:"_19n40yy6"},hasText:{true:"_19n40yy7"},isDisabled:{true:"_19n40yy8"}},defaultVariants:{},compoundVariants:[]});var X1={sm:SearchIcon,md:SearchIcon$1,lg:SearchIcon$1},Is=to.forwardRef(({className:e,size:t="md",variant:o="primary",...r},a)=>{let i=to.useRef(null),n=useSearchFieldState(r),{inputProps:l,clearButtonProps:s}=useSearchField({...r,"aria-haspopup":!1,"aria-autocomplete":"none",type:"search"},n,i),{focusProps:p,isFocusVisible:d,isFocused:u}=useFocusRing({within:!0,isTextInput:!0}),c=X1[t],m=t==="sm"?XIcon$2:XIcon$3,f=filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":u,"data-disabled":r.isDisabled,"data-focus-visible":d});return jsxs("div",{...f,className:classNames(ks({size:t,isFocused:u,variant:o,hasText:!!n.value,isDisabled:r.isDisabled}),"BaselineUI-SearchInput",e),ref:a,children:[jsx(c,{size:t==="sm"?20:24}),jsx("input",{...mergeProps(l,p),className:Ps,ref:i}),n.value!==""&&jsx(L,{icon:m,...s,size:t==="sm"?"xs":"sm",variant:"secondary"})]})});Is.displayName="SearchInput";function Ns({ref:e,onIntersect:t,isDisabled:o,threshold:r,rootMargin:a,root:i}){let n=to.useRef(null);useEffect(()=>{if(o){n.current?.disconnect(),n.current=null;return}n.current=new IntersectionObserver(([l])=>{t(l);},{root:i?.current,rootMargin:a,threshold:r});},[t,o,i,a,r]),useEffect(()=>{let{current:l}=n;return e.current&&l?.observe(e.current),()=>l?.disconnect()},[e]);}function Ss({ref:e,onResize:t,isDisabled:o}){let r=to.useRef(null),[a,i]=to.useState();return to.useEffect(()=>{if(o){r.current?.disconnect(),r.current=null;return}r.current=new ResizeObserver(([n])=>{i(n.contentRect),t?.(n);});},[t,o,i]),to.useEffect(()=>{let{current:n}=r;return e.current&&n?.observe(e.current),()=>n?.disconnect()},[e]),{size:a}}function bo({src:e,alt:t}){let[o,r]=useState(!1),[a,i]=useState(!1),[n,l]=useState(!1),s=()=>{r(!0),l(!1);},p=()=>{i(!0),l(!1);};return useEffect(()=>{if(!e)return;l(!0);let d=new Image;return d.src=e,d.addEventListener("load",s),d.addEventListener("error",p),()=>{d.removeEventListener("load",s),d.removeEventListener("error",p);}},[e]),{isLoaded:o,hasError:a,isLoading:n,imgProps:{src:o?e:void 0,alt:t}}}function Fe(){let e=useRef(!0);return useEffect(()=>{e.current=!1;},[]),e.current}var Ls="SET_STATE",er="UNDO",or="REDO",ab=(e,t)=>{let{past:o,present:r,future:a}=e;switch(t.type){case Ls:return {past:[...o,r],present:t.data,future:[]};case er:return {past:o.slice(0,o?.length-1),present:o[o?.length-1],future:[r,...a]};case or:return {past:[...o,r],present:a[0],future:a.slice(1)};default:throw new Error("Invalid action type")}},Ms=(e={},{isDisabled:t,onAction:o})=>{let r=Fe(),[a,i]=useReducer(ab,{past:[],present:e,future:[]}),{past:n,present:l,future:s}=a,p=y=>{i({type:Ls,data:y});},d=useRef(),u=()=>{d.current=er,i({type:er});},c=()=>{d.current=or,i({type:or});},m=!!n?.length,f=!!s?.length;return useGranularEffect(()=>{(d.current===er||d.current===or)&&(o?.(l,d.current),d.current=void 0);},[l],[o,r]),{state:l,push:t?()=>{}:p,undo:t?()=>{}:u,redo:t?()=>{}:c,pastStates:n,futureStates:s,canUndo:m,canRedo:f}};var Ta=to.createContext({messages:{}}),Es=({children:e,messages:t={},...o})=>{let r=to.useMemo(()=>({messages:t}),[t]);return jsx(I18nProvider,{...o,children:jsx(Ta.Provider,{value:r,children:e})})};Es.displayName="I18nProvider";function B(e){let{messages:t}=useContext(Ta);!e&&sb(t)&&console.warn("BUI \u{1F30D}: No messages object provided and no messages found in the `I18nProvider`. Please provide a messages object to the `useI18n` hook.");let o=useMessageFormatter(e?cleanKeyFromGlobImport(e):t),r=useLocale();return {formatMessage:(a,i)=>{if(typeof a=="object")try{return o(a.id,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.id.toString()}\`. The default message, i.e. \`${a.defaultMessage}\`, will be used instead.`),a.defaultMessage||a.id}else try{return o(a,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.toString()}\`. The default message, i.e. \`${a.toString()}\`, will be used instead.`),a}},locale:r}}var j=e=>e;function wN(e,t,o){let r=to.useRef(null);return to.useEffect(()=>{if(e)return r.current=new MutationObserver(o),r.current.observe(e,t),()=>{r.current&&r.current.disconnect();}},[e,t,o]),r.current}function Hs(e,t){let[o,r]=useState(()=>{try{let i=window.localStorage.getItem(e);return i?JSON.parse(i):t}catch(i){return console.log(i),t}});return [o,i=>{try{let n=i instanceof Function?i(o):i;r(n),window.localStorage.setItem(e,JSON.stringify(n));}catch(n){console.log(n);}}]}function MN({ref:e,onSelectionChange:t,onSelectionEnd:o,isDisabled:r}){let a=to.useRef(null);usePress({ref:e,isDisabled:r,onPressEnd(){let n=Q(e.current).getSelection();n&&e.current?.contains(n.anchorNode)&&o?.(n);},onPressStart(){let i=Q(e.current);a.current=i.getSelection(),a.current&&a.current.removeAllRanges();}}),useEffect(()=>{let i=e.current;if(!i||r)return;function n(){let p=Q(i).getSelection();p&&e.current?.contains(p.anchorNode)&&t(p);}let l=ge(i);return l.addEventListener("selectionchange",n),()=>{l.removeEventListener("selectionchange",n);}},[e,t,r]);}function go(e){let t=useCallback(()=>{let a=Q(e??document.body),i=a.matchMedia(queries.tablet);return a.matchMedia(queries.desktop).matches?"desktop":i.matches?"tablet":"mobile"},[e]),[o,r]=to.useState(t);return we(()=>{let a=Q(e),i=()=>{r(t());};return a.addEventListener("resize",i),i(),()=>{a.removeEventListener("resize",i);}},[e,t]),o}var Na=to.createContext(void 0),Vs=({portalContainer:e,children:t})=>jsx(Na.Provider,{value:e,children:t});Vs.displayName="PortalContainerProvider";function de(e){let t=useContext(Na);return e||t}var Pb=["append","prepend","insert","insertBefore","insertAfter","remove","removeSelectedItems","move","moveBefore","moveAfter","update"];function js(e){let{onListChange:t,onSelectionChange:o,...r}=e,a=useListData({...r,initialItems:e.initialItems||[]}),i=useRef(e.initialItems),n=useCallback(()=>{t&&t(a.items);},[t,a.items]),l=useCallback(()=>{o&&o(a.selectedKeys);},[o,a.selectedKeys]),s=useCallback(d=>e.getKey?e.getKey(d):d.id||d.key,[e]);useGranularEffect(n,[a.items,e.initialItems],[n]),useGranularEffect(l,[a.selectedKeys,e.initialItems],[l]),useEffect(()=>{let d=(y,g)=>y.filter(v=>!g.some(b=>vo(v,b))),u=(y,g)=>g.filter(v=>!y.some(b=>vo(v,b))),c=y=>{y.length>0&&a.remove(...y.map(g=>s(g)));},m=(y,g)=>{if(y.length>0){let v=g.findIndex(b=>y.some(h=>vo(b,h)));if(v===0)a.prepend(...y);else if(v>0){let b=g[v-1],h=a.items.findIndex(z=>vo(z,b));a.insertAfter(s(a.items[h]),...y);}else a.append(...y);}},f=y=>{for(let[g,v]of y.entries()){let b=a.items.findIndex(h=>vo(h,v));b!==-1&&b!==g&&a.move(s(a.items[b]),g);}};if(!vo(i.current,e.initialItems)){let y=a.items,g=e.initialItems||[],v=d(y,g);c(v);let b=u(y,g);m(b,g),f(g),i.current=g;}},[e.initialItems,a,s]);let p=useMemo(()=>{let d={};for(let u of Pb)d[u]=(...c)=>{let m=a[u](...c);return n(),(u==="remove"||u==="removeSelectedItems")&&l(),m};return d},[a,n,l]);return {...a,...p}}function La(e=window){let[t,o]=useState("light"),[r,a]=useState(!1),[i,n]=useState(!1),[l,s]=useState(!1);return useEffect(()=>{let p=e.matchMedia("(prefers-color-scheme: dark)"),d=u=>{o(u.matches?"dark":"light");};return p.matches&&o("dark"),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),useEffect(()=>{let p=e.matchMedia("(prefers-contrast: more)"),d=u=>{a(u.matches);};return a(p.matches),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),useEffect(()=>{let p=e.matchMedia("(prefers-reduced-motion: reduce)"),d=u=>{n(u.matches);};return p.matches&&n(!0),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),useEffect(()=>{let p=e.matchMedia("(prefers-reduced-transparency: reduce)"),d=u=>{s(u.matches);};return p.matches&&s(!0),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),{colorScheme:t,highContrast:r,reducedMotion:i,transparency:l}}var _o=createContext({theme:lightTheme,setTheme:()=>{}});var $s="var(--hj25q10)";var ar={LIGHT:{name:"light",theme:lightTheme},DARK:{name:"dark",theme:darkTheme}},zo=to.forwardRef(({theme:e="system",children:t,setTheme:o,className:r,style:a,UNSAFE_domProps:i,"data-block-id":n},l)=>{let{direction:s}=useLocale(),{colorScheme:p,reducedMotion:d,highContrast:u,transparency:c}=La(),{name:m,theme:f}=useMemo(()=>{switch(e){case"system":return p==="light"?ar.LIGHT:ar.DARK;case"light":return ar.LIGHT;case"dark":return ar.DARK;default:return {name:"custom",theme:e}}},[p,e]),y=go(),g={"data-theme":m,"data-block-id":n,"data-reduced-motion":d,"data-high-contrast":u,"data-transparency":c,"data-device":y},v=useMemo(()=>({theme:f,setTheme:o}),[f,o]);return jsx(_o.Provider,{value:v,children:jsx("div",{...mergeProps(i,g),className:classNames(Wt,"BaselineUI-ThemeProvider",r),style:{...assignInlineVars(themeVars,f),...assignInlineVars({[$s]:s==="rtl"?"-1":"1"}),...a},ref:l,children:t})})});zo.displayName="ThemeProvider";var Gs=_({defaultClassName:"_1mdhlqv3",variantClassNames:{isOpen:{true:"_1mdhlqv4"}},defaultVariants:{},compoundVariants:[]}),ir="_1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Ws=_({defaultClassName:"_1mdhlqv0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6eu _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy",variantClassNames:{isFocused:{false:"_1mdhlqv1"},isDisabled:{true:"z9nup83 _1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),Xs="_1mdhlqv7 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs",Ys="_1yep5z66x _1yep5z66y _1yep5z66z",Zs="_1mdhlqv5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k";var ho=to.forwardRef(({className:e,style:t,children:o,...r},a)=>{let{theme:i}=useContext(_o);return jsx(Overlay,{...r,children:jsx(zo,{ref:a,theme:i,style:t,className:classNames("BaselineUI-Portal",e),children:o})})});ho.displayName="Portal";function Js({placement:e}){let t=useReducedMotion();return useTransition(!0,{from:{opacity:0,transform:`translate3d(${e==="bottom"?"0, 4px, 0":"0, -4px, 0"})`},enter:{opacity:1,transform:"translate3d(0, 0, 0)"},immediate:!!t,config:config.stiff})}var{color:Ma}=themeVars,le=to.forwardRef(({className:e,style:t,state:o,overlayProps:r,underlayClassName:a,children:i,includeArrow:n=!1,offset:l=2,portalContainer:s,contentContainerClassName:p,contentContainerStyle:d,...u},c)=>{let m=to.useRef(null),f=de(s),y=n?8:0,{underlayProps:g,popoverProps:v,placement:b,arrowProps:h}=usePopover({...u,offset:l+y,popoverRef:m,containerPadding:u.containerPadding||0},o),z=Js({placement:b}),x=b==="center"?"bottom":b;return z((R,C)=>C&&jsxs(ho,{portalContainer:f,style:t,ref:c,children:[!u.isNonModal&&jsx("div",{...g,className:classNames(Kn,a,"BaselineUI-Popover-Underlay")}),jsxs(animated.div,{...v,style:{...v.style,...R,...assignInlineVars({[Gn]:`${u.triggerRef?.current?.offsetWidth}px`})},ref:N(m,c),className:classNames($n,"BaselineUI-Popover-Content",e),"data-placement":["top","bottom","left","right"].filter(P=>b?.includes(P)),children:[n?jsxs("svg",{className:classNames(jn[x],"BaselineUI-PopoverContent-Arrow"),...h,style:{...h.style,position:"absolute"},width:"15",height:"9",viewBox:"0 0 15 9",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M.019 0h1.228l6.272 7.237L13.791 0h1.228v1h-.772L7.519 8.763.791 1H.019V0Z",fill:Ma.border.medium}),jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:Ma.background.primary.subtle,stroke:Ma.background.primary.subtle})]}):null,jsx(DismissButton,{onDismiss:o.close}),jsx("div",{...r,style:d,className:classNames(Un,p),children:i}),jsx(DismissButton,{onDismiss:o.close})]})]}))});le.displayName="PopoverContentCore";var tl="xyd2ss1 _1yep5z613 _1yep5z614 _1yep5z615 _1yep5z63f _1yep5z63g _1yep5z63h _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b _1yep5z65r _1yep5z65s _1yep5z65t _1yep5z683 _1yep5z684 _1yep5z685 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z66x _1yep5z66y _1yep5z66z _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6l0 _1yep5z6kz _1yep5z6he _1yep5z6l3 _1yep5z6fs",rl="xyd2ss0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b";var Ba=({section:e,showSelectedIcon:t,state:o})=>{let{itemProps:r,groupProps:a,headingProps:i}=useMenuSection({heading:e.value?.title,"aria-label":e["aria-label"]});return jsxs(Fragment,{children:[e.key!==o.collection.getFirstKey()&&jsx(F,{elementType:"li"}),jsxs("li",{...r,children:[e.value?.title?jsx(VisuallyHidden,{children:jsx("span",{...i,children:e.value.title})}):null,jsx("ul",{...a,className:rl,children:[...e.childNodes].map(n=>(invariant(n.type==="item"),jsx(sr,{item:n,state:o,showSelectedIcon:t},n.key)))})]})]})};Ba.displayName="MenuSection";var sr=({item:e,state:t,className:o,showSelectedIcon:r})=>{let a=to.useRef(null),i=useMenuItem({key:e.key},t,a),{isFocusVisible:n,focusProps:l}=useFocusRing();return jsx(Wo,{item:e,liProps:mergeProps(i.menuItemProps,l,{className:o}),...i,isFocusVisible:n,ref:a,description:e.value?.keyboardShortcut,descriptionProps:i.keyboardShortcutProps,_state:t,showSelectedIcon:r})};sr.displayName="MenuItem";var Fa=to.forwardRef(({className:e,itemClassName:t,onContentKeyDown:o,...r},a)=>{let i=useTreeState(r),n=to.useRef(null),{menuProps:l}=useMenu(r,i,n),{keyboardProps:s}=useKeyboard({onKeyDown:o});return jsx("ul",{...mergeProps(l,s),className:classNames(tl,e),ref:N(n,a),children:[...i.collection].map(p=>p.type==="section"?jsx(Ba,{section:p,state:i,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},p.key):jsx(sr,{item:p,state:i,className:t,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},p.key))})});Fa.displayName="MenuContent";var lr=to.forwardRef(({defaultOpen:e,onOpenChange:t,isOpen:o,isDisabled:r,contentClassName:a,placement:i="bottom start",isNonModal:n,shouldFlip:l,shouldUpdatePosition:s,boundaryElement:p,crossOffset:d,offset:u,triggerLabel:c,renderTrigger:m=({buttonProps:v,ref:b})=>jsx(O,{...v,variant:"popover",ref:b}),portalContainer:f,...y},g)=>{let v=to.useRef(null),b=de(f),h=useMenuTriggerState({defaultOpen:e,isOpen:o,onOpenChange:t}),{menuTriggerProps:z,menuProps:x}=useMenuTrigger({isDisabled:r,type:"menu"},h,v),R=se(),C=useMemo(()=>mergeProps(z,{isDisabled:r,isSelected:h.isOpen,className:"BaselineUI-Menu-Trigger",label:c}),[z,r,h.isOpen,c]);return useEffect(()=>{!c&&!m&&console.warn("The `triggerLabel` prop is required when no `renderTrigger` or `children` is provided.");},[m,c]),jsxs(Fragment,{children:[m({buttonProps:C,ref:v}),h.isOpen?jsx(le,{triggerRef:v,state:h,placement:i,isNonModal:n,shouldFlip:l,shouldUpdatePosition:s,boundaryElement:p,crossOffset:d,offset:u||2,className:classNames(ir,"BaselineUI-Menu-Popover"),portalContainer:b,children:jsx(Fa,{className:a,...x,...y,ref:g,autoFocus:h.focusStrategy||"first",children:R})}):null]})});lr.displayName="Menu";var pr=_({defaultClassName:"_13f0naj0",variantClassNames:{variant:{default:"_13f0naj1",inline:"_13f0naj2"},isHovered:{true:"_13f0naj3"},isFocusVisible:{true:"_13f0naj4"},isDisabled:{true:"_13f0naj5"},size:{sm:"_13f0naj6",md:"_13f0naj7",lg:"_13f0naj8"},type:{body:"_13f0naj9",label:"_13f0naja"},isActive:{true:"_13f0najb"}},defaultVariants:{},compoundVariants:[[{isActive:!0,isDisabled:!1},"_13f0najc"],[{type:"body",size:"sm"},"_13f0najd"],[{type:"body",size:"md"},"_13f0naje"],[{type:"body",size:"lg"},"_13f0najf"],[{type:"label",size:"sm"},"_13f0najg"],[{type:"label",size:"md"},"_13f0najh"],[{type:"label",size:"lg"},"_13f0naji"]]});var ll=to.forwardRef(({className:e,style:t,children:o,variant:r="default",size:a="md",elementType:i="a",type:n="body","data-block-id":l,title:s,...p},d)=>{let u=to.useRef(null),{linkProps:c,isPressed:m}=useLink({...p,elementType:p.onPress?"span":i},u),{isFocusVisible:f,isFocused:y,focusProps:g}=useFocusRing(),{hoverProps:v,isHovered:b}=useHover({isDisabled:p.isDisabled}),h=i,z=filterTruthyValues({"data-block-id":l,"data-disabled":p.isDisabled,"data-focused":y,"data-pressed":m,"data-focus-visible":f,"data-hovered":b,title:s});return jsx(h,{...mergeProps(c,g,v,z),className:classNames(pr({variant:r,isFocusVisible:f,isHovered:b,isDisabled:p.isDisabled,size:a,isActive:m,type:n}),"BaselineUI-Link",e),ref:N(u,d),style:t,children:o})});ll.displayName="Link";function pl({isDisabled:e,onValueChange:t,onChange:o,name:r,"aria-describedby":a,"aria-label":i,accept:n,multiple:l}){let s=useId(),p=useId(),d=useId();return {inputProps:{type:"file",id:p,disabled:!!e,"aria-labelledby":i?void 0:s,"aria-describedby":a||d,"aria-label":i,onChange:c=>{let m=[...c.target.files||[]];t?.(m),o?.(c);},name:r,accept:n,multiple:l},labelProps:{htmlFor:p,id:s},descriptionProps:{id:d}}}async function Va({items:e}){let t=e.filter(o=>o.kind==="file").map(async o=>(invariant(o.kind==="file"),o.getFile()));return await Promise.all(t)}var cl=_({defaultClassName:"_180w5ed0",variantClassNames:{variant:{default:"_180w5ed1",inline:"_180w5ed2"},hoveredOrFocusedOrActive:{true:"_180w5ed3"},disabled:{true:"_180w5ed4"}},defaultVariants:{},compoundVariants:[[{variant:"inline",hoveredOrFocusedOrActive:!0},"_180w5ed5"],[{variant:"default",hoveredOrFocusedOrActive:!0},"_180w5ed6"],[{variant:"default",disabled:!0},"_180w5ed7"],[{variant:"inline",disabled:!0},"_180w5ed8"]]}),dl=_({defaultClassName:"_180w5ede",variantClassNames:{disabled:{true:"_180w5edf"}},defaultVariants:{},compoundVariants:[]}),ml=_({defaultClassName:"_180w5ed9",variantClassNames:{disabled:{true:"_180w5eda"}},defaultVariants:{},compoundVariants:[]}),ul=_({defaultClassName:"_180w5edb",variantClassNames:{disabled:{true:"_180w5edc"},hovered:{true:"_180w5edd"}},defaultVariants:{},compoundVariants:[]});var gl=to.forwardRef(({className:e,label:t,description:o,icon:r,variant:a="default",...i},n)=>{let l=to.useRef(null),{inputProps:s,descriptionProps:p,labelProps:d}=pl(i),{dropProps:u}=useDrop({ref:l,onDrop:async({items:g})=>{let v=g.filter(h=>h.kind==="file").map(async h=>(invariant(h.kind==="file"),h.getFile())),b=await Promise.all(v);i.onValueChange?.(b);}}),{focusProps:c,isFocusVisible:m}=useFocusRing(),{hoverProps:f,isHovered:y}=useHover({isDisabled:i.isDisabled});return jsxs("label",{...mergeProps(u,f,d),className:classNames(cl({variant:a,disabled:i.isDisabled,hoveredOrFocusedOrActive:y||m}),e),ref:N(n,l),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(c,s)})}),r?jsx(r,{size:20,className:ml({disabled:i.isDisabled})}):null,jsxs("div",{children:[jsx("div",{className:ul({disabled:i.isDisabled,hovered:y}),children:t}),o?jsx("div",{...p,className:dl({disabled:i.isDisabled}),children:o}):null]})]})});gl.displayName="FileUpload";var vl="_12vfhl40 z9nup81",_l="_12vfhl41 z9nup82",zl=_({defaultClassName:"_12vfhl48",variantClassNames:{variant:{success:"_12vfhl49",error:"_12vfhl4a",active:"_12vfhl4b"}},defaultVariants:{},compoundVariants:[]}),hl="_12vfhl42",xl="_12vfhl47",Cl="_12vfhl46 z9nup82",Pl="_12vfhl45",kl=_({defaultClassName:"_12vfhl43 _12vfhl42",variantClassNames:{hasLabel:{false:"_12vfhl44"}},defaultVariants:{},compoundVariants:[]});var wl=to.forwardRef(({className:e,variant:t="active",showValue:o,description:r,errorMessage:a,...i},n)=>{let l=useId(),{labelProps:s,progressBarProps:p}=useProgressBar({...i,"aria-describedby":r?l:i["aria-describedby"]}),{minValue:d=0,maxValue:u=100,value:c=0,label:m}=i,f=(c-d)/(u-d),y=`${Math.round(f*100)}%`,g=jsx("output",{className:kl({hasLabel:!!m}),children:p["aria-valuetext"]}),v=t==="error"?a:r;return jsxs("div",{...p,className:classNames(vl,e),ref:n,children:[m?jsxs("div",{className:_l,children:[jsx("label",{...s,className:hl,children:m}),o?g:null]}):null,jsxs("div",{className:Pl,children:[jsxs("div",{className:Cl,children:[jsx("div",{className:xl,children:jsx("div",{style:{width:y},className:zl({variant:t})})}),!m&&o?g:null]}),v?jsx("div",{className:co({hasError:t==="error"}),id:l,children:v}):null]})]})});wl.displayName="ProgressBar";function Po({isReadOnly:e,validationState:t}){return e?ReadOnlyIcon:t==="error"?ErrorFilledIcon:t==="warning"?WarningFilledIcon:null}var ko=to.forwardRef(({className:e,validationState:t,variant:o="primary",style:r,labelPosition:a="top",inputStyle:i,inputClassName:n,"data-block-id":l,...s},p)=>{let d=to.useRef(null),{inputProps:u,labelProps:c,descriptionProps:m,errorMessageProps:f,validationErrors:y}=useTextField({...s,validationState:t?t==="error"?"invalid":"valid":void 0},d),g=s.errorMessage||y.join(" "),v=_e({...s,errorMessage:g,descriptionProps:m,errorMessageProps:f,labelPosition:a});g&&(t="error");let{hoverProps:b,isHovered:h}=useHover({isDisabled:s.isDisabled}),{isFocused:z,focusProps:x,isFocusVisible:R}=useFocusRing(),C=Po({isReadOnly:s.isReadOnly,validationState:t}),P=filterTruthyValues({"data-readonly":s.isReadOnly,"data-disabled":s.isDisabled,"data-validation-state":t,"data-focused":z,"data-focus-visible":R});return jsxs("div",{className:classNames(Be({labelPosition:a}),"BaselineUI-TextInput",e),"data-block-id":l,style:r,ref:p,children:[s.label||a==="start"&&v?jsxs("div",{className:De({labelPosition:a,hasMessage:!!v}),children:[jsx("label",{...c,className:Me,children:s.label}),a==="start"&&v]}):null,jsxs("div",{className:classNames({[po]:s.isDisabled}),children:[jsxs("div",{...b,className:uo({validationState:t,isHovered:h,isFocused:z,variant:o,isReadOnly:!!s.isReadOnly,isDisabled:!!s.isDisabled}),children:[jsx("input",{...mergeProps(u,x,P),className:classNames(Xt({isDisabled:s.isDisabled,labelPosition:a}),"BaselineUI-TextInput-Input",n),style:i,ref:d}),C?jsx(C,{className:mo({validationState:t,isReadOnly:s.isReadOnly}),size:16}):null]}),a==="top"&&v]})]})});ko.displayName="TextInput";var wo=({value:e,...t})=>{let o=useNumberFormatter(t);return jsx(Fragment,{children:o.format(e)})};wo.displayName="NumberFormat";var Il="_1yep5z6i3 _1yep5z6i4 _1yep5z6i5",Tl=_({defaultClassName:"_9b1tml0",variantClassNames:{isSelected:{true:"_9b1tml1",false:"_9b1tml2"},isDisabled:{true:"z9nup83"},isHovered:{true:"_9b1tml4"},isFocusVisible:{true:"_9b1tml5"},isReadOnly:{true:"_9b1tml6"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0,isReadOnly:!1},"_9b1tml7"],[{isSelected:!0,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml8"],[{isSelected:!1,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml9"],[{isSelected:!0,isDisabled:!0},"_9b1tmla"],[{isSelected:!0,isReadOnly:!0},"_9b1tmlb"]]}),Nl=_({defaultClassName:"_9b1tmlf",variantClassNames:{isSelected:{true:"_9b1tmlg"},size:{sm:"_9b1tmlh",md:"_9b1tmli"},isDisabled:{true:"_9b1tmlj"},isReadOnly:{true:"_9b1tmlk"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"_9b1tmll"],[{isSelected:!0,isDisabled:!0},"_9b1tmlm"],[{isSelected:!1,isDisabled:!0},"_9b1tmln"]]}),Sl=_({defaultClassName:"_9b1tmlc",variantClassNames:{isDisabled:{true:"_9b1tmld"},isReadOnly:{true:"_9b1tmle"}},defaultVariants:{},compoundVariants:[]});var Dl=to.forwardRef(({className:e,count:t,style:o,size:r="md",icon:a,...i},n)=>{let l={isRequired:!1},s=a||(r==="md"?CheckmarkIcon$2:CheckmarkIcon$3);!i["aria-label"]&&!i["aria-labelledby"]&&console.warn("You must provide either an `aria-label` or `aria-labelledby` prop to the `Reaction` component.");let p=to.useRef(null),d=useToggleState({...i,...l}),{inputProps:u,isPressed:c,isDisabled:m,isReadOnly:f,isSelected:y}=useSwitch({...i,...l},d,p),{focusProps:g,isFocused:v,isFocusVisible:b}=useFocusRing(),{hoverProps:h,isHovered:z}=useHover({});return jsxs("label",{ref:n,style:o,className:classNames(Il,"BaselineUI-Reaction",e),"data-block-id":i["data-block-id"],"data-focused":v,"data-focus-visible":b,"data-disabled":m,"data-hovered":z,"data-pressed":c,"data-selected":y,children:[jsx(VisuallyHidden,{children:jsx("input",{...u,...g,ref:p})}),jsxs("div",{...h,className:Tl({isSelected:y,isFocusVisible:b,isHovered:z,isReadOnly:f,isDisabled:m}),children:[jsx("div",{className:Sl({isDisabled:m,isReadOnly:f}),children:jsx(s,{size:r==="md"?20:16})}),jsx("div",{className:Nl({isSelected:d.isSelected,isDisabled:m,isReadOnly:f,size:r}),children:jsx(wo,{value:t})})]})]})});Dl.displayName="Reaction";var Bl=_({defaultClassName:"_1jwycy80",variantClassNames:{placement:{bottom:"_1jwycy81",left:"_1jwycy82",right:"_1jwycy83",top:"_1jwycy84"},variant:{default:"_1jwycy85",inverse:"_1jwycy86"}},defaultVariants:{},compoundVariants:[]}),El=_({defaultClassName:"_1jwycy87 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn",variantClassNames:{size:{md:"_1yep5z63u _1yep5z63v _1yep5z63w _1yep5z61i _1yep5z61j _1yep5z61k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6e7",sm:"_1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6dv"},variant:{default:"_1yep5z6g0 _1yep5z6ez",inverse:"_1yep5z6d7 _1yep5z6fs _1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var $a=to.forwardRef(({children:e,state:t,overlayProps:o,arrowProps:r,placement:a,variant:i,size:n,tooltipProps:l,includeArrow:s},p)=>{let{tooltipProps:d}=useTooltip({isOpen:t.isOpen},t),u=useMemo(()=>{switch(a){case"top":return {x:0,y:4};case"bottom":return {x:0,y:-4};case"left":return {x:4,y:0};case"right":return {x:-4,y:0};default:return {x:0,y:0}}},[a]),c=useReducedMotion(),[m]=useSpring(()=>({from:{opacity:0,transform:`translate(${u.x}px, ${u.y}px)`},to:{opacity:1,transform:"translate(0, 0)"},immediate:!!c})),f=a==="center"?"bottom":a;return jsxs(animated.span,{...o,style:{...m,...o.style},ref:p,"data-placement":f,children:[s?jsx("div",{className:Bl({placement:f,variant:i}),...r}):null,jsx("div",{...mergeProps(d,l),className:El({variant:i,size:n}),children:e})]})});$a.displayName="TooltipContent";var He=to.forwardRef(({children:e,placement:t="bottom",delay:o=1e3,closeDelay:r=500,variant:a="default",size:i="md",includeArrow:n=!0,portalContainer:l,...s},p)=>{let d=to.useRef(null),u=to.useRef(null),c=!s.text||s.isDisabled,m=useTooltipTriggerState({...s,delay:o,closeDelay:r,isDisabled:c}),{triggerProps:f,tooltipProps:y}=useTooltipTrigger({...s,isDisabled:c,delay:o,closeDelay:r},m,d),g=de(l),{overlayProps:v,arrowProps:b,placement:h,updatePosition:z}=useOverlayPosition({arrowSize:n?13:0,targetRef:d,arrowBoundaryOffset:n?8:0,offset:n?12:2,overlayRef:u,placement:t,isOpen:m.isOpen,...s});return Ns({ref:u,threshold:1,onIntersect:z,isDisabled:!m.isOpen}),Ss({ref:d,onResize:z,isDisabled:!m.isOpen}),jsxs(FocusableProvider,{...f,ref:d,children:[e,m.isOpen?jsx(ho,{disableFocusManagement:!0,portalContainer:g,children:jsx($a,{ref:N(p,u),state:m,arrowProps:b,overlayProps:v,placement:h,tooltipProps:y,variant:a,size:i,includeArrow:n,children:s.text})}):null]})});He.displayName="Tooltip";var Ol="_1azy5686",Vl="_1azy5685",Al="var(--_1azy5680)",jl="_1azy5688",$l="_1azy5689",Ul="_1azy5681 z9nup82",ql="_1azy5682";var Kl="_1azy5687";var bv={sm:16,md:20},gv={sm:[CheckFilledIcon,ErrorAltFilledIcon],md:[CheckFilledIcon$1,ErrorAltFilledIcon$1]},Io=to.forwardRef(({className:e,style:t,size:o="md",variant:r="active",...a},i)=>{let{labelProps:n,progressBarProps:l}=useProgressBar({...a,isIndeterminate:!0}),s=bv[o],p=s/2-2,d=2*p*Math.PI,u=gv[o][r==="success"?0:1];return jsxs("div",{className:classNames(Ul,e),ref:i,style:{...assignInlineVars({[Al]:`${d}px`}),...t},children:[jsxs("div",{...l,className:ql,children:[(r==="active"||r==="inactive")&&jsxs("svg",{height:s,width:s,viewBox:`0 0 ${s} ${s}`,children:[jsx("circle",{role:"presentation",className:Ol,cx:s/2,cy:s/2,r:p}),r==="active"&&jsx("circle",{role:"presentation",className:Vl,cx:s/2,cy:s/2,r:p})]}),r==="success"&&jsx(u,{className:Kl,size:s}),r==="error"&&jsx(u,{className:jl,size:s})]}),a.label?jsx("span",{...n,className:$l,children:a.label}):null]})});Io.displayName="ProgressSpinner";var Gl=_({defaultClassName:"_5uw3kp0 oom8bs0 z9nup82",variantClassNames:{isHovered:{true:"_5uw3kp1"},isFocusVisible:{true:"_5uw3kp2"},isDisabled:{true:"_5uw3kp3"},isSelected:{true:"_5uw3kp4"},size:{sm:"_5uw3kp5",md:"_5uw3kp6",lg:"_5uw3kp7"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0},"_5uw3kp8"],[{isSelected:!0,isDisabled:!0},"_5uw3kp9"]]});var kv={sm:16,md:20,lg:24},mr=to.forwardRef(({className:e,style:t,iconStart:o,size:r="md",elementType:a="button",...i},n)=>{let l=useToggleState(i),{buttonProps:s,isPressed:p,ref:d}=Kt(i,l),{hoverProps:u,isHovered:c}=useHover({isDisabled:i.isDisabled}),{isFocusVisible:m,isFocused:f,focusProps:y}=useFocusRing(),g=filterTruthyValues({"data-block-id":i["data-block-id"],"data-focused":f,"data-focus-visible":m,"data-disabled":i.isDisabled,"data-hovered":c,"data-pressed":p,"data-selected":l.isSelected});return jsxs(a,{...mergeProps(s,u,y,g),className:classNames(Gl({isHovered:c,isFocusVisible:m,isSelected:l.isSelected,size:r,isDisabled:i.isDisabled}),"BaselineUI-ToggleButton",e),style:t,ref:N(d,n),children:[o?jsx(o,{size:kv[r]}):null,i.label]})});mr.displayName="ToggleButton";var ur=_({defaultClassName:"_16vugd0e",variantClassNames:{isDisabled:{true:"_16vugd0f"}},defaultVariants:{},compoundVariants:[]}),Wl=_({defaultClassName:"_16vugd01 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),Xl=_({defaultClassName:"_16vugd05",variantClassNames:{isIndeterminate:{true:"_16vugd04"},isSelected:{true:"_16vugd04"},isFocusVisible:{true:"_16vugd08"},isHovered:{true:"_16vugd09"},isDisabled:{true:"_16vugd0a"},isReadOnly:{true:"_16vugd0b"},hasError:{true:"_16vugd0c"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_16vugd0d"]]});var Ql=to.forwardRef(({className:e,style:t,label:o,labelPosition:r="end","data-block-id":a,...i},n)=>{let l=to.useRef(null),s=useToggleState(i),{isFocusVisible:p,isFocused:d,focusProps:u}=useFocusRing(),{inputProps:c,isPressed:m,isDisabled:f,isSelected:y,isReadOnly:g}=useCheckbox({...i,children:o},s,l),{hoverProps:v,isHovered:b}=useHover({isDisabled:f}),h=filterTruthyValues({"data-disabled":f,"data-readonly":g,"data-hovered":b,"data-selected":y,"data-pressed":m,"data-indeterminate":i.isIndeterminate,"data-invalid":i.isInvalid,"data-focus-visible":p,"data-focused":d,"data-block-id":a});return jsxs("label",{...h,className:classNames(Wl({labelPosition:r}),"BaselineUI-Checkbox",e),style:t,ref:n,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(c,u),ref:l})}),jsxs("div",{...v,className:Xl({isSelected:y&&!i.isIndeterminate,isIndeterminate:i.isIndeterminate,isFocusVisible:p,isDisabled:f,isReadOnly:g,hasError:i.isInvalid,isHovered:b}),children:[y&&!i.isIndeterminate?jsx(CheckmarkIcon$1,{size:12}):null,i.isIndeterminate?jsx(MinusIcon$1,{size:12}):null]}),o?jsx("span",{className:ur({isDisabled:f}),children:o}):null]})});Ql.displayName="Checkbox";var Jl={ar:{goToPage:"\u0627\u0646\u062A\u0642\u0627\u0644 \u0625\u0644\u0649 \u0635\u0641\u062D\u0629",nextPage:"\u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u062A\u0627\u0644\u064A\u0629",pageXofY:"\u0635\u0641\u062D\u0629 {arg0} \u0645\u0646 {arg1}",prevPage:"\u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u0633\u0627\u0628\u0642\u0629"},cs:{goToPage:"P\u0159ej\xEDt na stranu",nextPage:"Dal\u0161\xED str\xE1nka",pageXofY:"Strana {arg0} z {arg1}",prevPage:"P\u0159edchoz\xED strana"},cy:{goToPage:"Mynd i Dudalen",nextPage:"Tudalen Nesaf",pageXofY:"Tudalen {arg0} o {arg1}",prevPage:"Tudalen Blaenorol"},da:{goToPage:"G\xE5 til side",nextPage:"N\xE6ste side",pageXofY:"Side {arg0} af {arg1}",prevPage:"Forrige side"},de:{goToPage:"Zu Seite wechseln",nextPage:"N\xE4chste Seite",pageXofY:"Seite {arg0} von {arg1}",prevPage:"Vorherige Seite"},el:{goToPage:"\u039C\u03B5\u03C4\u03AC\u03B2\u03B1\u03C3\u03B7 \u03C3\u03C4\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1",nextPage:"\u0395\u03C0\u03CC\u03BC\u03B5\u03BD\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1",pageXofY:"\u03A3\u03B5\u03BB\u03AF\u03B4\u03B1 {arg0} \u03B1\u03C0\u03CC {arg1}",prevPage:"\u03A0\u03C1\u03BF\u03B7\u03B3\u03BF\u03CD\u03BC\u03B5\u03BD\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1"},"en-GB":{goToPage:"Go to Page",nextPage:"Next Page",pageXofY:"Page {arg0} of {arg1}",prevPage:"Previous Page"},en:{goToPage:"Go to Page",nextPage:"Next Page",pageXofY:"Page {arg0} of {arg1}",prevPage:"Previous Page"},es:{goToPage:"Ir a la p\xE1gina",nextPage:"P\xE1gina siguiente",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina anterior"},fi:{goToPage:"Mene sivulle",nextPage:"Seuraava sivu",pageXofY:"Sivu {arg0} / {arg1}",prevPage:"Edellinen sivu"},"fr-CA":{goToPage:"Aller \xE0 la page",nextPage:"Page suivante",pageXofY:"Page {arg0} sur {arg1}",prevPage:"Page pr\xE9c\xE9dente"},fr:{goToPage:"Aller \xE0 la page",nextPage:"Page suivante",pageXofY:"Page {arg0} sur {arg1}",prevPage:"Page pr\xE9c\xE9dente"},he:{goToPage:"\u05DE\u05E2\u05D1\u05E8 \u05DC\u05E2\u05DE\u05D5\u05D3",nextPage:"\u05D4\u05E2\u05DE\u05D5\u05D3 \u05D4\u05D1\u05D0",pageXofY:"\u05E2\u05DE\u05D5\u05D3 {arg0} \u05DE\u05EA\u05D5\u05DA {arg1}",prevPage:"\u05D4\u05E2\u05DE\u05D5\u05D3 \u05D4\u05E7\u05D5\u05D3\u05DD"},hr:{goToPage:"Idi na stranicu",nextPage:"Slijede\u0107a stranica",pageXofY:"Stranica {arg0} od {arg1}",prevPage:"Prethodna stranica"},id:{goToPage:"Buka halaman",nextPage:"Halaman Berikutnya",pageXofY:"Halaman {arg0} dari {arg1}",prevPage:"Halaman Sebelumnya"},it:{goToPage:"Vai a pagina",nextPage:"Pagina successiva",pageXofY:"Pagina {arg0} di {arg1}",prevPage:"Pagina precedente"},ja:{goToPage:"\u30DA\u30FC\u30B8\u306B\u79FB\u52D5",nextPage:"\u6B21\u306E\u30DA\u30FC\u30B8",pageXofY:"\u30DA\u30FC\u30B8 {arg0}/{arg1}",prevPage:"\u524D\u306E\u30DA\u30FC\u30B8"},ko:{goToPage:"\uD398\uC774\uC9C0\uB85C \uC774\uB3D9",nextPage:"\uB2E4\uC74C \uD398\uC774\uC9C0",pageXofY:"{arg0}/{arg1} \uD398\uC774\uC9C0",prevPage:"\uC774\uC804 \uD398\uC774\uC9C0"},ms:{goToPage:"Pergi ke Halaman",nextPage:"Halaman Seterusnya",pageXofY:"Halaman {arg0} daripada {arg1}",prevPage:"Halaman Sebelumnya"},"nb-NO":{goToPage:"G\xE5 til side",nextPage:"Neste side",pageXofY:"Side {arg0} av {arg1}",prevPage:"Forrige side"},nl:{goToPage:"Ga naar pagina",nextPage:"Volgende pagina",pageXofY:"Pagina {arg0} van {arg1}",prevPage:"Vorige pagina"},pl:{goToPage:"Przejd\u017A do strony",nextPage:"Nast\u0119pna strona",pageXofY:"Strona {arg0} z {arg1}",prevPage:"Poprzednia strona"},"pt-PT":{goToPage:"Ir para p\xE1gina",nextPage:"P\xE1gina seguinte",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina anterior"},pt:{goToPage:"Ir \xE0 P\xE1gina",nextPage:"P\xE1gina Seguinte",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina Anterior"},ru:{goToPage:"\u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u043A \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0435",nextPage:"\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430",pageXofY:"\u0421\u0442\u0440\u0430\u043D\u0438\u0446\u0430 {arg0} \u0438\u0437 {arg1}",prevPage:"\u041F\u0440\u0435\u0434\u044B\u0434\u0443\u0449\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430"},sk:{goToPage:"\xCDs\u0165 na stranu",nextPage:"Dal\u0161ia strana",pageXofY:"Strana {arg0} z {arg1}",prevPage:"Predch\xE1dzaj\xFAca strana"},sl:{goToPage:"Pojdi na stran",nextPage:"Naslednja stran",pageXofY:"Stran {arg0} od {arg1}",prevPage:"Prej\u0161nja stran"},sv:{goToPage:"G\xE5 till sida",nextPage:"N\xE4sta sida",pageXofY:"Sida {arg0} av {arg1}",prevPage:"F\xF6reg\xE5ende sida"},th:{goToPage:"\u0E44\u0E1B\u0E17\u0E35\u0E48\u0E2B\u0E19\u0E49\u0E32",nextPage:"\u0E2B\u0E19\u0E49\u0E32\u0E16\u0E31\u0E14\u0E44\u0E1B",pageXofY:"\u0E2B\u0E19\u0E49\u0E32 {arg0} \u0E08\u0E32\u0E01 {arg1}",prevPage:"\u0E2B\u0E19\u0E49\u0E32\u0E01\u0E48\u0E2D\u0E19\u0E2B\u0E19\u0E49\u0E32"},tr:{goToPage:"Sayfaya Git",nextPage:"Sonraki Sayfa",pageXofY:"Sayfa {arg0}/{arg1}",prevPage:"\xD6nceki Sayfa"},uk:{goToPage:"\u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u043D\u0430 \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0443",nextPage:"\u041D\u0430\u0441\u0442\u0443\u043F\u043D\u0430 \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0430",pageXofY:"\u0421\u0442\u043E\u0440\u0456\u043D\u043A\u0430 {arg0} \u0437 {arg1}",prevPage:"\u041F\u043E\u043F\u0435\u0440\u0435\u0434\u043D\u044F \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0430"},"zh-Hans":{goToPage:"\u524D\u5F80\u9875\u9762",nextPage:"\u4E0B\u4E00\u9875",pageXofY:"\u7B2C {arg0}/{arg1} \u9875",prevPage:"\u4E0A\u4E00\u9875"},"zh-Hant":{goToPage:"\u5230\u6B64\u9801",nextPage:"\u4E0B\u4E00\u9801",pageXofY:"\u7B2C{arg0}\u9801\uFF0C\u5171{arg1}\u9801",prevPage:"\u4E0A\u4E00\u9801"}};var ep=_({defaultClassName:"_1nsi9h17",variantClassNames:{isFocusVisible:{true:"_1nsi9h18"},variant:{pinned:"_1nsi9h19",floating:"_1nsi9h1a"}},defaultVariants:{},compoundVariants:[]}),op="_1nsi9h1b",tp=_({defaultClassName:"_1nsi9h10",variantClassNames:{size:{xs:"_1nsi9h11",sm:"_1nsi9h12",md:"_1nsi9h13",lg:"_1nsi9h14"},variant:{floating:"_1nsi9h15",pinned:"_1nsi9h16"}},defaultVariants:{},compoundVariants:[]}),rp="_1nsi9h1c";var Jv={style:"decimal"},e_={xs:[CaretLeftIcon,CaretRightIcon],sm:[CaretLeftIcon$1,CaretRightIcon$1],md:[CaretLeftIcon$2,CaretRightIcon$2],lg:[CaretLeftIcon$3,CaretRightIcon$3]},sp=to.forwardRef(({className:e,style:t,minValue:o=1,defaultValue:r=1,incrementAriaLabel:a,decrementAriaLabel:i,"aria-label":n,size:l="md",variant:s="floating",...p},d)=>{let{locale:u}=useLocale(),c=B(Jl),m={...p,formatOptions:Jv,minValue:o,incrementAriaLabel:a||c.formatMessage("nextPage"),decrementAriaLabel:i||c.formatMessage("prevPage"),defaultValue:r,"aria-label":n||c.formatMessage("goToPage")},f=to.useRef(null),y=useNumberFieldState({...m,locale:u}),{inputProps:g,decrementButtonProps:v,incrementButtonProps:b,groupProps:h}=useNumberField({...m,onKeyDown:E=>{E.key==="Enter"&&f.current?.blur(),p.onKeyDown?.(E);}},y,f),{hoverProps:z,isHovered:x}=useHover({}),{focusProps:R,isFocused:C,isFocusVisible:P}=useFocusRing(),k=s==="floating",[T,I]=e_[l],D=filterTruthyValues({"data-focus-visible":P,"data-focused":C,"data-hovered":x,"data-block-id":p["data-block-id"]});return jsxs("div",{...mergeProps(h,z,D),className:classNames(tp({size:l,variant:s}),"BaselineUI-Pagination",e),style:t,ref:d,children:[jsx(L,{icon:T,...v,elementType:"div",size:l,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-DecrementButton"}),s==="floating"&&jsx(F,{orientation:"vertical"}),jsxs("div",{className:ep({isFocusVisible:P,variant:s}),"aria-label":c.formatMessage("pageXofY",{arg0:g.value,arg1:y.maxValue}),children:[jsx("input",{...mergeProps(g,R),ref:f,className:classNames("BaselineUI-Pagination-Input",op),style:{width:`${g.value?.toString().length||1}ch`}}),jsxs("span",{className:rp,children:["/ ",jsx(wo,{value:y.maxValue})]})]}),s==="floating"&&jsx(F,{orientation:"vertical"}),jsx(L,{icon:I,...b,elementType:"div",size:l,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-IncrementButton"})]})});sp.displayName="Pagination";var lp=({date:e,...t})=>{let o=useDateFormatter(t);return jsx(Fragment,{children:o.format(e)})};lp.displayName="DateFormat";var fr=_({defaultClassName:"_1f789qj1",variantClassNames:{isFocusVisible:{true:"_1f789qj2"},variant:{neutral:"_1f789qj3",red:"_1f789qj4",green:"_1f789qj5",blue:"_1f789qj6","high-contrast":"_1f789qj7"},isDisabled:{true:"_1f789qj8"},allowsRemoving:{true:"_1f789qj9"},isSelected:{true:"_1f789qja"},allowsSelection:{true:"_1f789qjb"},isHovered:{true:"_1f789qjc"}},defaultVariants:{},compoundVariants:[[{allowsSelection:!0,isHovered:!0,variant:"neutral"},"_1f789qjd"],[{allowsSelection:!0,isHovered:!0,variant:"red"},"_1f789qje"],[{allowsSelection:!0,isHovered:!0,variant:"blue"},"_1f789qjf"],[{allowsSelection:!0,isHovered:!0,variant:"green"},"_1f789qjg"],[{allowsSelection:!0,isHovered:!0,variant:"high-contrast"},"_1f789qjh"],[{allowsSelection:!0,isSelected:!0,isHovered:!0},"_1f789qji"]]}),pp="_1f789qjj",cp="_1f789qj0",dp=_({defaultClassName:"_1f789qjk",variantClassNames:{variant:{neutral:"_1f789qjl",red:"_1f789qjm",green:"_1f789qjn",blue:"_1f789qjo","high-contrast":"_1f789qjp"},isHovered:{true:"_1f789qjq"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,variant:"neutral"},"_1f789qjr"],[{isHovered:!0,variant:"red"},"_1f789qjs"],[{isHovered:!0,variant:"blue"},"_1f789qjt"],[{isHovered:!0,variant:"green"},"_1f789qju"],[{isHovered:!0,variant:"high-contrast"},"_1f789qjv"]]});var m_=({item:e,state:t,variant:o="neutral"})=>{let r=to.useRef(null),{focusProps:a,isFocusVisible:i}=useFocusRing({within:!0}),{rowProps:n,gridCellProps:l,removeButtonProps:s,allowsRemoving:p,isDisabled:d,isSelected:u,allowsSelection:c}=useTag({item:e},t,r),m=to.useRef(null),{buttonProps:f}=useButton(s,m),{hoverProps:y,isHovered:g}=useHover({isDisabled:d}),{hoverProps:v,isHovered:b}=useHover({isDisabled:d}),h=e.value?.icon,z=e.value?.variant??o;return jsx("div",{...mergeProps(n,a,v),ref:r,className:fr({isFocusVisible:i,variant:z,isDisabled:d,allowsRemoving:p,isSelected:u,allowsSelection:c,isHovered:b}),children:jsxs("div",{...l,className:pp,children:[u?jsx(CheckmarkIcon$3,{size:16}):null,!u&&h?jsx(h,{size:16}):null,e.rendered,p?jsx("button",{...mergeProps(f,y),className:dp({variant:z,isHovered:g}),children:jsx(XIcon$2,{})}):null]})})},Ga=to.forwardRef(({className:e,style:t,...o},r)=>{let a=to.useRef(null),i=useListState(o),{gridProps:n}=useTagGroup(o,i,a);return jsx("div",{...n,className:classNames(cp,e),style:t,ref:N(r,a),children:[...i.collection].map(l=>jsx(m_,{state:i,item:l,variant:o.variant},l.key))})});Ga.displayName="TagGroupBase";var yp=to.forwardRef(({items:e,...t},o)=>jsx(Ga,{...t,items:e,ref:o,children:r=>jsx(Item,{children:r.label})}));yp.displayName="TagGroup";var bp="_1yep5z6kv",gp=_({defaultClassName:"_1kvz17db _1yep5z6ki _1yep5z6kk",variantClassNames:{showActionsOnTriggerOnly:{true:"_1kvz17dc"},isTriggered:{true:"_1kvz17dd"}},defaultVariants:{},compoundVariants:[]}),vp=_({defaultClassName:"_1kvz17d0 _1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z68c _1yep5z68d _1yep5z68e _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6ki _1yep5z6kj",variantClassNames:{isExpanded:{true:"_1kvz17d1"}},defaultVariants:{},compoundVariants:[]}),_p="_1yep5z6ev _1yep5z6dy",zp=_({defaultClassName:"_1kvz17d2 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ki _1yep5z6kl",variantClassNames:{isFocusVisible:{true:"_1kvz17d3"},isHovered:{true:"_1yep5z6ft",false:"_1yep5z6fu"},isDisabled:{true:"z9nup83"}},defaultVariants:{},compoundVariants:[]}),hp="_1kvz17da _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6dz",xp=_({defaultClassName:"_1kvz17d7 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{isDisabled:{true:"_1yep5z6ey",false:"_1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var Xa=to.forwardRef(({children:e,className:t,style:o},r)=>{let{headers:a}=useContext(Oe),{disabledKeys:i}=useContext(Oe),{keyboardProps:n}=useKeyboard({onKeyDown:l=>{let s=Vt(l.target),p=[...a?.keys()||[]].findIndex(f=>a?.get(f)?.current===s?.activeElement),d=a?.get(p||0),u=a?.size||0,c=f=>{let y=a.get(f-1<0?u-1:f-1);i?.has(y?.current?.getAttribute("data-key")||"")?c(f-1):y?.current?.focus();},m=f=>{let y=a.get((f+1)%u);i?.has(y?.current?.getAttribute("data-key")||"")?m(f+1):y?.current?.focus();};if(d)switch(l.key){case"Home":{l.preventDefault(),m(-1);break}case"End":{l.preventDefault(),c(u);break}case"ArrowDown":{l.preventDefault(),m(p);break}case"ArrowUp":{l.preventDefault(),c(p);break}default:l.continuePropagation();}}});return jsx("div",{...n,style:o,className:classNames(bp,t),ref:r,children:to.Children.map(e,(l,s)=>to.cloneElement(l,{index:s}))})});Xa.displayName="AccordionBase";var Oe=to.createContext({expandedKeys:new Set,setExpandedKeys:()=>{},disabledKeys:new Set,headers:new Map,expansionMode:"multiple"}),kp=to.forwardRef(({children:e,disabledKeys:t,defaultExpandedKeys:o=new Set,expandedKeys:r,expansionMode:a="multiple",onChange:i,className:n,style:l},s)=>{let[p,d]=to.useState(o),u=to.useRef(new Map).current,[c,m]=to.useState(a);useEffect(()=>{m(c);},[c]),useEffect(()=>{i?.(p);},[p,i]);let f=useMemo(()=>({expandedKeys:r||p,setExpandedKeys:r?()=>{}:d,disabledKeys:t,headers:u,expansionMode:c}),[r,p,t,u,c]);return jsx(Oe.Provider,{value:f,children:jsx(FocusScope,{children:jsx(Xa,{className:n,style:l,ref:s,children:e})})})});kp.displayName="Accordion";var Za=to.forwardRef(({title:e,actions:t,controlId:o,value:r,id:a,index:i,subLabel:n,showActionsOnTriggerOnly:l},s)=>{let p=to.useRef(null),{expandedKeys:d,setExpandedKeys:u,expansionMode:c,disabledKeys:m,headers:f}=useContext(Oe),y=m?.has(r),g=useFocusManager();invariant(g);let{focusNext:v,focusPrevious:b}=g,{keyboardProps:h}=useKeyboard({onKeyDown:w=>{w.key==="ArrowRight"?v({wrap:!0}):w.key==="ArrowLeft"?b({wrap:!0}):w.continuePropagation();},isDisabled:y});useEffect(()=>{invariant(typeof i=="number","AccordionItem must have an index"),f?.set(i,p);},[i,f]);let z=()=>{u(w=>{let S=new Set(w);return S.has(r)?S.delete(r):(c==="single"&&S.clear(),S.add(r)),S});},{buttonProps:x}=useButton({"aria-expanded":d.has(r),"aria-controls":o,onPress:z,isDisabled:y},p),{pressProps:R}=usePress({onPress:z,isDisabled:y}),{focusProps:C,isFocusVisible:P}=useFocusRing(),{hoverProps:k,isHovered:T}=useHover({isDisabled:y}),{focusProps:I,isFocusVisible:D}=useFocusRing({within:!0}),E=d.has(r);return jsxs("h3",{...mergeProps(h,R,k,I),className:zp({isFocusVisible:P,isHovered:T,isDisabled:y}),ref:s,children:[jsxs("div",{className:xp({isDisabled:!!y}),children:[jsx(ChevronRightIcon,{className:vp({isExpanded:E}),size:8}),jsx("button",{...mergeProps(x,C),id:a,"data-key":r,className:hp,ref:p,children:e})]}),t?.length?jsx("div",{"data-testid":"action-buttons",className:gp({showActionsOnTriggerOnly:l,isTriggered:D||T}),children:t.map((w,S)=>jsx(L,{variant:"secondary",size:"sm",excludeFromTabOrder:!0,isDisabled:y,...w},S))}):null,n?jsx("div",{className:_p,children:n}):null]})});Za.displayName="AccordionHeader";var Mp=to.forwardRef(({title:e,actions:t,children:o,value:r,index:a,subLabel:i,style:n,className:l,showActionsOnTriggerOnly:s},p)=>{let d=useId(),u=useId(),{expandedKeys:c}=useContext(Oe),m=to.useRef(null),f=c.has(r),y=Fe(),g=useReducedMotion(),v=useTransition(f?[r]:[],{from:!y&&!g&&{height:0,opacity:0},enter:()=>async b=>{await b({height:m.current?.scrollHeight,opacity:1});},leave:{height:0,opacity:0},keys:b=>b});return jsxs(Fragment,{children:[jsx(FocusScope,{children:jsx(Za,{value:r,actions:t,id:u,title:e,controlId:d,ref:p,index:a,subLabel:i,showActionsOnTriggerOnly:s})}),v(b=>jsx(animated.div,{role:"region","aria-labelledby":u,id:d,style:{...b,overflow:"hidden"},children:jsx("div",{ref:m,className:l,style:n,children:o})}))]})});Mp.displayName="AccordionItem";var nt=to.forwardRef(({variant:e,isOpen:t,selectedIcon:o,validationState:r="valid",valueProps:a,label:i,...n},l)=>{let s=to.useRef(null),{buttonProps:p,isPressed:d}=useButton({...n,isDisabled:n.isDisabled||n.isReadOnly},s),{hoverProps:u,isHovered:c}=useHover({isDisabled:n.isDisabled}),{focusProps:m,isFocused:f,isFocusVisible:y}=useFocusRing(),g=Po({isReadOnly:n.isReadOnly,validationState:r});n.isReadOnly&&(p.disabled=!1);let v=filterTruthyValues({"data-disabled":n.isDisabled,"data-readonly":n.isReadOnly,"data-focused":f,"data-focus-visible":y,"data-hovered":c,"data-pressed":d,"data-open":t});return jsxs("button",{...mergeProps(p,u,m,v),ref:N(l,s),className:classNames(Ws({isFocused:y,isDisabled:n.isDisabled}),uo({variant:e,isHovered:c,isFocused:y,validationState:r,isDisabled:!!n.isDisabled,isReadOnly:n.isReadOnly}),"BaselineUI-Select-Button"),children:[jsxs("span",{className:Zs,children:[o?jsx(o,{size:24}):null,jsx("span",{...a,children:i})]}),g?jsx("span",{"aria-hidden":!0,className:classNames(mo({validationState:r,isReadOnly:!!n.isReadOnly}),Ys),children:jsx(g,{size:16})}):null,jsx("span",{"aria-hidden":!0,children:jsx(ChevronDownIcon,{size:8,className:Gs({isOpen:t})})})]})});nt.displayName="SelectButton";var ei=to.createContext(null),oi=to.forwardRef(({className:e,style:t,labelPosition:o="top",variant:r="primary","data-block-id":a,optionStyle:i,optionClassName:n,placement:l="bottom start",state:s,renderTrigger:p=({buttonProps:c,selectedValue:m,valueProps:f,isOpen:y,ref:g})=>{let v=m&&"icon"in m&&m.icon;return jsx(nt,{...c,isOpen:y,isReadOnly:d.isReadOnly,ref:g,variant:r,validationState:d.validationState,selectedIcon:v||void 0,label:m?"label"in m&&m?.label:d.placeholder,valueProps:f})},...d},u)=>{let c=to.useRef(null),m=de(d.portalContainer),{labelProps:f,triggerProps:y,valueProps:g,menuProps:v,descriptionProps:b,errorMessageProps:h}=useSelect({...d,validationState:d.validationState==="error"?"invalid":"valid"},s,c),z=_e({...d,descriptionProps:b,errorMessageProps:h,labelPosition:o}),x=s.selectedItem?.value??null;return jsxs(We.Provider,{value:s,children:[jsxs("div",{style:t,className:classNames(Be({labelPosition:o}),"BaselineUI-Select",e),"data-block-id":a,ref:u,children:[d.label||z?jsxs("div",{className:De({labelPosition:o,hasMessage:!!z}),children:[d.label?jsx("div",{...f,className:classNames(Me,"BaselineUI-Select-Label"),children:d.label}):null,o==="start"&&z]}):null,jsx(HiddenSelect,{state:s,triggerRef:c,isDisabled:d.isDisabled,label:d.label,name:d.name}),p({buttonProps:y,selectedValue:x,valueProps:g,isOpen:s.isOpen,ref:c}),o==="top"&&z]}),s.isOpen?jsx(le,{placement:l,portalContainer:m,offset:2,state:s,triggerRef:c,style:t,className:classNames(ir,"BaselineUI-Select-Popover"),...d,children:jsx(te,{...v,label:d.label,items:d.items,showSelectedIcon:d.showSelectedIcon,className:Xs,optionStyle:i,optionClassName:n})}):null]})});oi.displayName="SelectCore";var Fp=to.forwardRef((e,t)=>{let o=se(),r=useSelectState({...e,validationState:e.validationState==="error"?"invalid":"valid",children:o});return jsx(oi,{...e,ref:t,state:r})});Fp.displayName="SelectStandalone";var Ae=to.forwardRef((e,t)=>{let o=useContext(ei);return useEffect(()=>{invariant(o||e.items,"Select: A `state` that can be passed via context or `items` are required.");},[e.items,o]),o?jsx(oi,{state:o,...e,ref:t}):jsx(Fp,{...e,ref:t})});Ae.displayName="Select";var Op=to.forwardRef(({className:e,style:t,variant:o,"data-block-id":r,icon:a,includeTooltip:i,placement:n="bottom start",...l},s)=>{let p=to.useRef(null),d=useCallback(({buttonProps:u,selectedValue:c,valueProps:m,isOpen:f,ref:y})=>{let g=c&&"icon"in c&&c.icon;return jsx(He,{isDisabled:!i||l.isDisabled,variant:"inverse",size:"sm",includeArrow:!1,text:l["aria-label"],placement:n,offset:4,children:jsx(nt,{...u,isOpen:f,isReadOnly:l.isReadOnly,ref:y,variant:o,validationState:l.validationState,selectedIcon:g||void 0,label:c?"label"in c&&c?.label:l.placeholder,valueProps:m})})},[i,n,l,o]);return jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:classNames("BaselineUI-IconSelect",e),"data-block-id":r,style:t,ref:N(s,p),children:[jsx(a,{size:24,className:sprinkles({color:"icon.primary"})}),jsx(Ae,{...l,renderTrigger:d})]})});Op.displayName="IconSelect";var Vp="_1017q4c5",Ap=_({defaultClassName:"_1017q4c0",variantClassNames:{size:{md:"_1017q4c1",sm:"_1017q4c2"},isDisabled:{true:"_1017q4c3"}},defaultVariants:{},compoundVariants:[]}),jp="_1017q4c4";var t6={sm:AvatarIcon,md:AvatarIcon$1},So=to.forwardRef(({className:e,style:t,size:o="md",icon:r=t6[o],name:a,imgSrc:i,showInitials:n,isDisabled:l,hasNotifications:s,imgLoading:p,"data-block-id":d},u)=>{let{imgProps:c}=bo({src:i,alt:a}),m=a?.split(" ").map(f=>f[0]).join("");return jsxs("span",{className:classNames(Ap({size:o,isDisabled:l}),"BaselineUI-Avatar",e),"data-disabled":l,ref:u,style:t,"aria-disabled":l,"data-block-id":d,children:[i?jsx("img",{...c,loading:p,className:jp}):null,!n&&!i&&jsx(r,{size:o==="sm"?16:24}),n&&!i?o==="sm"?m[0]:m:null,s?jsx("div",{"data-testid":"notification",className:Vp}):null]})});So.displayName="Avatar";var $p="_1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",Up=_({defaultClassName:"_1x62fhb6 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6ev _1yep5z69i _1yep5z69j _1yep5z69k",variantClassNames:{isHovered:{true:"_1yep5z6105"},isSelected:{true:"_1x62fhb8"},isFocusVisible:{true:"_1x62fhb9"},isDisabled:{true:"_1x62fhba _1yep5z6109"},variant:{primary:"_1x62fhbb _1yep5z6z6",ghost:"_1yep5z6z9"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:!0,isDisabled:!1},"_1yep5z61lg"],[{variant:"primary",isSelected:!0},"_1yep5z61me"],[{variant:"ghost",isSelected:!0,isFocusVisible:!1},"_1x62fhbd"],[{variant:"ghost",isSelected:!0,isDisabled:!1},"_1yep5z61lr"],[{variant:"ghost",isDisabled:!0,isSelected:!0},"_1x62fhbe _1yep5z6ey"],[{variant:"primary",isHovered:!0},"_1yep5z61mf"]]}),qp=_({defaultClassName:"_1x62fhb3 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1x62fhb4",ghost:"_1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),Kp="_1x62fhbf",Gp="_1yep5z6l2 _1yep5z6kz _1yep5z6hc _1yep5z6l1",Wp=_({defaultClassName:"_1x62fhb0 _1yep5z6kv _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1yep5z6115",ghost:"_1x62fhb2"}},defaultVariants:{},compoundVariants:[]});var Xp=({state:e,...t})=>{let o=to.useRef(null),{tabPanelProps:r}=useTabPanel(t,e,o),{selectedItem:a}=e,{focusProps:i,isFocusVisible:n}=useFocusRing();if(!a?.value)return null;let{className:l,style:s,"data-block-id":p}=a.value;return jsx("div",{...mergeProps(r,i),ref:o,className:classNames({[Gp]:n},"Baseline-Tabs-TabPanel",l),"data-block-id":p,style:s,children:a?.props.children})};var ii=to.forwardRef(({className:e,style:t,tabHeaderStyle:o,tabHeaderClassName:r,variant:a="primary",actions:i,onRemove:n,"data-block-id":l,...s},p)=>{let d=useTabListState({...s,selectedKey:s.selectedValue,defaultSelectedKey:s.defaultSelectedValue,disabledKeys:s.disabledValues}),u=to.useRef(null),{tabListProps:c}=useTabList({...s,selectedKey:s.selectedValue,defaultSelectedKey:s.defaultSelectedValue,disabledKeys:s.disabledValues},d,u);return jsxs("div",{className:classNames("BaselineUI-Tabs",e),style:t,ref:p,"data-block-id":l,children:[jsxs("div",{className:classNames(Wp({variant:a}),r),style:o,children:[jsx("div",{...c,className:qp({variant:a}),ref:u,children:[...d.collection].map(m=>(invariant(m.value,"TabItem requires a value prop"),jsx(Zp,{item:m,state:d,onRemove:n,variant:a},m.key)))}),i?.map((m,f)=>jsx("div",{className:$p,children:jsx(L,{...m,variant:"secondary",size:"sm",className:classNames(Kp,m.className)})},f))]}),jsx(Xp,{state:d},d.selectedItem?.key)]})});ii.displayName="TabsBase";var Zp=({item:e,onRemove:t,state:o,variant:r})=>{let{key:a,value:i}=e,n=to.useRef(null),{tabProps:l,isSelected:s,isDisabled:p}=useTab({key:a},o,n),{hoverProps:d,isHovered:u}=useHover({});invariant(i,"TabButton requires a value prop");let{title:c,icon:m,titleStyle:f,titleClassName:y}=i,{focusProps:g,isFocusVisible:v,isFocused:b}=useFocusRing(),{keyboardProps:h}=useKeyboard({onKeyDown:x=>{x.key==="Backspace"&&t?t(a):x.continuePropagation();}}),z=filterTruthyValues({"data-selected":s,"data-disabled":p,"data-focused":b,"data-hovered":u,"data-focus-visible":v});return jsxs("div",{...mergeProps(h,l,d,g,z),className:classNames(Up({isHovered:u,isSelected:s,isFocusVisible:v,isDisabled:p,variant:r}),"BaselineUI-Tabs-TabButton",y),style:f,ref:n,children:[m?jsx(m,{size:20}):null,c,t?jsx(L,{variant:"secondary",elementType:"div",icon:XIcon,size:"xxs",onPress:()=>{t(a);},excludeFromTabOrder:!0,UNSAFE_NON_INTERACTIVE:!0,style:{display:"inline-flex",color:"inherit",opacity:s||b||u?1:0}}):null]})};Zp.displayName="TabButton";var Jp=to.forwardRef(({children:e,...t},o)=>{let r=useMemo(()=>to.Children.map(e,a=>!a||!to.isValidElement(a)||typeof a.type=="string"?null:{...a.props,id:a.props.value}).filter(Boolean),[e]);return jsx(ii,{...t,ref:o,items:r,children:a=>jsx(Item,{title:a.title,children:a.children},a.key)})});Jp.displayName="Tabs";var ec=({children:e,title:t,value:o})=>(invariant(o,"TabItem requires a value prop"),invariant(t,"TabItem requires a title prop"),invariant(e,"TabItem requires children"),e);ec.displayName="TabItem";var oc={ar:{close:"\u0625\u063A\u0644\u0627\u0642"},cs:{close:"Zav\u0159\xEDt"},cy:{close:"Cau"},da:{close:"Luk"},de:{close:"Schlie\xDFen"},el:{close:"\u039A\u03BB\u03B5\u03AF\u03C3\u03B9\u03BC\u03BF"},"en-GB":{close:"Close"},en:{close:"Close"},es:{close:"Cerrar"},fi:{close:"Sulje"},"fr-CA":{close:"Fermer"},fr:{close:"Fermer"},he:{close:"\u05E1\u05D2\u05D9\u05E8\u05D4"},hr:{close:"Zatvori"},id:{close:"Tutup"},it:{close:"Chiudi"},ja:{close:"\u9589\u3058\u308B"},ko:{close:"\uB2EB\uAE30"},ms:{close:"Tutup"},"nb-NO":{close:"Lukk"},nl:{close:"Sluit"},pl:{close:"Zamknij"},"pt-PT":{close:"Fechar"},pt:{close:"Fechar"},ru:{close:"\u0417\u0430\u043A\u0440\u044B\u0442\u044C"},sk:{close:"Zavrie\u0165"},sl:{close:"Zapri"},sv:{close:"St\xE4ng"},th:{close:"\u0E1B\u0E34\u0E14"},tr:{close:"Kapat"},uk:{close:"\u0417\u0430\u043A\u0440\u0438\u0442\u0438"},"zh-Hans":{close:"\u5173\u95ED"},"zh-Hant":{close:"\u95DC\u9589"}};var tc=_({defaultClassName:"kfun6yw",variantClassNames:{arrangement:{single:"kfun6yx",multi:"kfun6yy",compact:"kfun6yz"}},defaultVariants:{},compoundVariants:[]}),rc=_({defaultClassName:"kfun6y0 z9nup82",variantClassNames:{variant:{info:"kfun6y1",warning:"kfun6y2",error:"kfun6y3",success:"kfun6y4"},arrangement:{single:"kfun6y5",multi:"kfun6y6",compact:"kfun6y7"},hasButton:{true:"kfun6y8"},hasCloseButton:{true:"kfun6y9"}},defaultVariants:{},compoundVariants:[[{hasButton:!1,arrangement:"single"},"kfun6ya"],[{hasButton:!0,arrangement:"compact"},"kfun6yb"],[{hasCloseButton:!0,arrangement:"compact"},"kfun6yc"]]}),ac=_({defaultClassName:"kfun6yt",variantClassNames:{size:{sm:"kfun6yu",md:"kfun6yv"}},defaultVariants:{},compoundVariants:[]}),ic=_({defaultClassName:"kfun6yp",variantClassNames:{arrangement:{single:"kfun6yq",multi:"kfun6yr",compact:"kfun6ys"}},defaultVariants:{},compoundVariants:[]}),nc=_({defaultClassName:"kfun6yk",variantClassNames:{variant:{info:"kfun6yl",warning:"kfun6ym",error:"kfun6yn",success:"kfun6yo"}},defaultVariants:{},compoundVariants:[]}),sc=_({defaultClassName:"kfun6yh",variantClassNames:{size:{sm:"kfun6yi",md:"kfun6yj"}},defaultVariants:{},compoundVariants:[]}),lc=_({defaultClassName:"kfun6yd z9nup82",variantClassNames:{arrangement:{single:"kfun6ye",multi:"kfun6yf",compact:"kfun6yg"}},defaultVariants:{},compoundVariants:[]});var M6={error:{sm:ErrorAltFilledIcon,md:ErrorAltFilledIcon$1},info:{sm:InfoFilledIcon,md:InfoFilledIcon$1},success:{sm:CheckFilledIcon,md:CheckFilledIcon$1},warning:{sm:WarningFilledIcon,md:WarningFilledIcon$1}},pc=to.forwardRef(({className:e,description:t,actionLabel:o,onAction:r,style:a,variant:i="info",title:n,arrangement:l="single",onClose:s,size:p="sm"},d)=>{let u=B(oc),c=o&&jsx(O,{variant:l==="compact"?"tertiary":"ghost",label:o,onPress:r}),m=M6[i][p];return jsxs("div",{className:classNames(rc({variant:i,arrangement:l,hasButton:!!o||!!s,hasCloseButton:!!s}),e),style:a,role:"alert",ref:d,children:[jsxs("div",{className:lc({arrangement:l}),children:[jsx(m,{className:nc({variant:i}),size:16}),jsxs("div",{className:tc({arrangement:l}),children:[jsx("h3",{className:sc({size:p}),children:n}),jsx("section",{className:ac({size:p}),children:t})]}),l==="compact"&&c]}),jsxs("div",{className:ic({arrangement:l}),children:[l!=="compact"&&c,s?jsx(L,{variant:"secondary",icon:CloseIcon,size:"sm",onPress:s,"aria-label":u.formatMessage("close")}):null]})]})});pc.displayName="InlineAlert";var cc=_({defaultClassName:"_1tkzayn0 _1yep5z6dy",variantClassNames:{size:{sm:"_1tkzayn1",md:"_1tkzayn2",lg:"_1tkzayn3"},type:{subtitle:"_1yep5z6105",title:"_1yep5z6105",label:"_1yep5z6106",value:"_1yep5z6106",helper:"_1yep5z6107",body:"_1yep5z6105"}},defaultVariants:{},compoundVariants:[[{type:"title",size:"sm"},"_1yep5z61jz"],[{type:"title",size:"md"},"_1yep5z61k2"],[{type:"title",size:"lg"},"_1yep5z61k5"],[{type:"body",size:"sm"},"_1yep5z61kp"],[{type:"body",size:"md"},"_1yep5z61ks"],[{type:"body",size:"lg"},"_1yep5z61ks"],[{type:"subtitle",size:"sm"},"_1yep5z61kl"],[{type:"subtitle",size:"md"},"_1yep5z61ko"],[{type:"subtitle",size:"lg"},"_1yep5z61ko"],[{type:"label",size:"md"},"_1yep5z61kn"],[{type:"label",size:"lg"},"_1yep5z61kn"],[{type:"value",size:"md"},"_1yep5z61kn"],[{type:"value",size:"lg"},"_1yep5z61kn"],[{type:"helper",size:"sm"},"_1yep5z61kh"]]});var W=to.forwardRef(({elementType:e="span",type:t="title",children:o,size:r="md",...a},i)=>jsx(e,{...a,className:classNames(cc({size:r,type:t}),"BaselineUI-Text",a.className),ref:i,children:o}));W.displayName="Text";var dc=_({defaultClassName:"siobe21 _1yep5z6ao _1yep5z6ap _1yep5z6aq _1yep5z6bc _1yep5z6bd _1yep5z6be _1yep5z6d7 _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie",variantClassNames:{background:{subtle:"_1yep5z6113",medium:"_1yep5z6114"}},defaultVariants:{},compoundVariants:[]}),mc="siobe24",uc="var(--siobe20)";var hr=to.forwardRef(({className:e,style:t,children:o,background:r="medium",title:a,action:i,"data-block-id":n,onCloseRequest:l,...s},p)=>{let{formatMessage:d}=B(),u=to.useRef(null),{dialogProps:c,titleProps:m}=useDialog(s,u);return jsxs("div",{...c,className:classNames(dc({background:r}),"BaselineUI-Drawer",e),"data-block-id":n,style:t,ref:N(p,u),children:[jsxs(M,{paddingLeft:"lg",paddingRight:"sm",backgroundColor:"background.primary.subtle",display:"flex",justifyContent:"space-between",alignItems:"center",gap:"lg",className:mc,children:[jsx(W,{type:"title",size:"sm",...m,className:Jn,children:a}),jsxs(M,{children:[i?jsx(L,{...i,variant:"secondary"}):null,jsx(L,{variant:"secondary",size:"md",icon:XIcon$1,onPress:l,"aria-label":d(V6.close)})]})]}),jsx(F,{variant:r==="subtle"?"primary":"secondary"}),o]})});hr.displayName="Drawer";var V6=j({close:{id:"close",defaultMessage:"Close"}});function bc(e,t,o){let{isDisabled:r}=e,a=useReducedMotion(),[i,n]=to.useState("100vh");useEffect(()=>{if(!fa()&&!ya())return;let m=Q(o.current);function f(){n(`${m?.visualViewport.height}px`);}return f(),m?.visualViewport.addEventListener("resize",f),()=>{m?.visualViewport.removeEventListener("resize",f);}},[o]);let[{y:l},s]=useSpring(()=>({y:0,immediate:a,config:{easing:easings.easeOutCubic}})),p=useRef(0),d=useCallback(()=>{s.start({y:p.current,onRest:()=>{t.close();}});},[s,t]),u=useCallback(m=>{m.target.closest("[data-drawer]")||d();},[d]);useGranularLayoutEffect(()=>{p.current=o.current?.offsetHeight||0,s.set({y:p.current}),s.start({y:0,immediate:!!a});},[],[s,a]);let c=l.to({range:[0,p.current/2,p.current],output:[.5,.2,0],extrapolate:"clamp"}).to(m=>`rgba(0,0,0,${m})`);return {overlayProps:{style:r?void 0:{transform:l.to(m=>`translateY(${m}px)`)}},underlayProps:{style:r?void 0:{backgroundColor:c},onPointerDown:r?void 0:u},close:d,containerHeight:r?void 0:i}}var gc=_({defaultClassName:"aml2vl0 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hr _1yep5z6hs _1yep5z6ht",variantClassNames:{enableDrawer:{false:"_1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",true:"aml2vl2"}},defaultVariants:{},compoundVariants:[]}),vc="_1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6g2 _1yep5z6hr _1yep5z6hs _1yep5z6ht";var je=to.createContext({state:null,triggerProps:{},overlayProps:{}}),ze=({children:e,...t})=>{let o=useOverlayTriggerState(t),{triggerProps:r,overlayProps:a}=useOverlayTrigger({type:"dialog"},o),i=useMemo(()=>({state:o,triggerProps:r,overlayProps:a}),[o,r,a]);return jsx(je.Provider,{value:i,children:e})};ze.displayName="Modal";var pi=to.createContext({isDrawer:!1,closeDrawer:()=>{}}),n5=animated(zo),s5=({children:e,className:t,style:o,isDismissable:r=!0,isKeyboardDismissDisabled:a=!1,portalContainer:i,disableAnimation:n,enableDrawer:l=!1,"data-block-id":s})=>{let{state:p}=to.useContext(je),d=go(i),u=de(i),c=typeof l=="boolean"&&l||l==="auto"&&d==="mobile";invariant(p,"ModalContent must be a child of Modal");let m=to.useRef(null),f=typeof r=="function"?r(c):r,y=typeof a=="function"?a(c):a,{underlayProps:g,overlayProps:v,close:b,containerHeight:h}=bc({isDisabled:!c,isDismissable:f},p,m),{modalProps:z,underlayProps:x}=useModalOverlay({isDismissable:!c,isKeyboardDismissDisabled:y},p,m),{theme:R}=useContext(_o),C=useReducedMotion(),P=useSpring({from:{opacity:0,transform:"scale(0.95)"},to:{opacity:1,transform:"scale(1)"},immediate:!!C||n,config:{easing:easings.easeInBounce}}),k=useMemo(()=>({...z.style,...c?{...v.style,width:"100%"}:P}),[v.style,z.style,c,P]),T=useMemo(()=>({isDrawer:c,closeDrawer:b}),[c,b]);return jsx(Overlay,{portalContainer:u,children:jsx(pi.Provider,{value:T,children:jsxs(n5,{className:classNames(gc({enableDrawer:c}),t),theme:R,"data-block-id":s,style:{...o,height:c?h:"auto",...assignInlineVars({[uc]:h})},children:[jsx(animated.div,{...mergeProps(x,g),onPointerDown:c?g.onPointerDown:x.onPointerDown,"data-testid":"underlay",style:g.style,className:classNames(vc,"BaselineUI-Modal-Underlay")}),jsx(animated.div,{...mergeProps(z,v),style:k,ref:m,"data-drawer":c,className:"BaselineUI-Modal-Content",children:e})]})})})},l5=animated(s5),Te=({children:e,style:t,...o})=>{let{state:r}=to.useContext(je);invariant(r,"ModalContent must be a child of Modal");let a=useReducedMotion();return useTransition(r.isOpen,{from:{opacity:0},enter:{opacity:1},immediate:!!a||o.disableAnimation})((n,l)=>l&&jsx(l5,{...o,style:{...t,...n},children:typeof e=="function"?e({close:r.close}):e}))};var Pc=_({defaultClassName:"cjv3et0 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs _1yep5z6d7",variantClassNames:{size:{sm:"cjv3et1",md:"cjv3et2",lg:"cjv3et3",content:"cjv3et4"},variant:{primary:"_1yep5z6121 _1yep5z616i _1yep5z616k",ghost:"cjv3et6"},isDrawer:{true:"cjv3et7 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg _1yep5z6166"}},defaultVariants:{},compoundVariants:[]});var di=to.createContext({titleProps:{}}),me=to.forwardRef(({children:e,className:t,style:o,inheritDrawer:r,size:a="md",variant:i="primary","data-block-id":n,drawerBackground:l,...s},p)=>{let d=to.useRef(null),u=to.useRef(null),{isDrawer:c,closeDrawer:m}=useContext(pi),[f,y]=to.useState("");useLayoutEffect(()=>{let h=u.current?.getRootNode(),z=s["aria-label"]||"";s["aria-labelledby"]&&(z=h?.querySelector(`#${s["aria-labelledby"].replaceAll(":","\\:")}`)?.textContent||""),y(z);},[s]);let{dialogProps:g,titleProps:v}=useDialog(s,d),b=useMemo(()=>({titleProps:v}),[v]);return c&&r?jsx(hr,{title:f,onCloseRequest:m,className:t,...s,"data-drawer":!0,"data-block-id":n,ref:N(u,p),background:l,children:e}):jsx(di.Provider,{value:b,children:jsx("section",{...g,"data-block-id":n,ref:N(d,p),style:o,className:classNames(Pc({size:c?"content":a,variant:i,isDrawer:c}),"BaselineUI-Dialog",t),children:e})})});me.displayName="Dialog";var wc=to.forwardRef(({children:e,className:t,style:o},r)=>{let{titleProps:a}=useContext(di),i=to.isValidElement(e)?Slot:"h3";return jsx(i,{...a,ref:r,className:t,style:o,children:e})});wc.displayName="DialogTitle";var $e={ar:{add:"\u0625\u0636\u0627\u0641\u0629",addColor:"\u0625\u0636\u0627\u0641\u0629 \u0644\u0648\u0646",cancel:"\u0625\u0644\u063A\u0627\u0621",colorFormat:"\u062A\u0646\u0633\u064A\u0642 \u0627\u0644\u0644\u0648\u0646",colorPresets:"\u0627\u0644\u0623\u0644\u0648\u0627\u0646 \u0627\u0644\u0645\u0633\u0628\u0642\u0629",customColors:"\u0623\u0644\u0648\u0627\u0646 \u0645\u062E\u0635\u0635\u0629",newColor:"\u0644\u0648\u0646 \u0645\u062E\u0635\u0635 \u062C\u062F\u064A\u062F",noColor:"\u0644\u0627 \u064A\u0648\u062C\u062F",removeColor:"\u0625\u0632\u0627\u0644\u0629 \u0627\u0644\u0644\u0648\u0646",transparent:"\u0634\u0641\u0627\u0641"},cs:{add:"P\u0159idat",addColor:"P\u0159idat barvu",cancel:"Zru\u0161it",colorFormat:"Form\xE1t barvy",colorPresets:"P\u0159edvolby barev",customColors:"Vlastn\xED barvy",newColor:"Vlastn\xED barva",noColor:"Nen\xED",removeColor:"Odebrat barvu",transparent:"Pr\u016Fhledn\xE1"},cy:{add:"Ychwanegu",addColor:"Ychwanegu Lliw",cancel:"Canslo",colorFormat:"Fformat Lliw",colorPresets:"Rhagosodiadau Lliw",customColors:"Lliwiau Custom",newColor:"Lliw Personol Newydd",noColor:"Dim",removeColor:"Tynnu Lliw",transparent:"Tryloyw"},da:{add:"Tilf\xF8j",addColor:"Tilf\xF8j Farve",cancel:"Annuller",colorFormat:"Farveformat",colorPresets:"Farvevalg",customColors:"Brugerdefinerede farver",newColor:"Ny tilpasset farve",noColor:"Ingen",removeColor:"Fjern Farve",transparent:"Transparent"},de:{add:"Hinzuf\xFCgen",addColor:"Farbe hinzuf\xFCgen",cancel:"Abbrechen",colorFormat:"Farbformat",colorPresets:"Farbvorlagen",customColors:"Benutzerdefinierte Farben",newColor:"Neue benutzerdefinierte Farbe",noColor:"Kein",removeColor:"Farbe entfernen",transparent:"Transparent"},el:{add:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7",addColor:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",cancel:"\u0391\u03BA\u03CD\u03C1\u03C9\u03C3\u03B7",colorFormat:"\u039C\u03BF\u03C1\u03C6\u03AE \u03C7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",colorPresets:"\u03A0\u03C1\u03BF\u03B5\u03C0\u03B9\u03BB\u03BF\u03B3\u03AD\u03C2 \u03C7\u03C1\u03C9\u03BC\u03AC\u03C4\u03C9\u03BD",customColors:"\u03A0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03B1 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03B1",newColor:"\u039D\u03AD\u03BF \u03C0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03BF \u03C7\u03C1\u03CE\u03BC\u03B1",noColor:"\u039A\u03B1\u03BD\u03AD\u03BD\u03B1\u03C2",removeColor:"\u0391\u03C6\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",transparent:"\u0397\u03BC\u03B9\u03B4\u03B9\u03B1\u03C6\u03B1\u03BD\u03AE\u03C2"},"en-GB":{add:"Add",addColor:"Add Colour",cancel:"Cancel",colorFormat:"Colour Format",colorPresets:"Colour Presets",customColors:"Custom Colours",newColor:"New Custom Colour",noColor:"None",removeColor:"Remove Colour",transparent:"Transparent"},en:{add:"Add",addColor:"Add Color",cancel:"Cancel",colorFormat:"Color Format",colorPresets:"Color Presets",customColors:"Custom Colors",newColor:"New Custom Color",noColor:"None",removeColor:"Remove Color",transparent:"Transparent"},es:{add:"A\xF1adir",addColor:"A\xF1adir color",cancel:"Cancelar",colorFormat:"Formato de color",colorPresets:"Preajustes de color",customColors:"Colores personalizados",newColor:"Nuevo color personalizado",noColor:"Ninguna",removeColor:"Eliminar color",transparent:"Transparente"},fi:{add:"Lis\xE4\xE4",addColor:"Lis\xE4\xE4 v\xE4ri",cancel:"Kumoa",colorFormat:"V\xE4rimuoto",colorPresets:"V\xE4rin esiasetukset",customColors:"Mukautetut v\xE4rit",newColor:"Uusi muokattu v\xE4ri",noColor:"Ei mit\xE4\xE4n",removeColor:"Poista v\xE4ri",transparent:"L\xE4pin\xE4kyv\xE4"},"fr-CA":{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},fr:{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},he:{add:"\u05D4\u05D5\u05E1\u05E4\u05D4",addColor:"\u05D4\u05D5\u05E1\u05E3 \u05E6\u05D1\u05E2",cancel:"\u05D1\u05D9\u05D8\u05D5\u05DC",colorFormat:"\u05E4\u05D5\u05E8\u05DE\u05D8 \u05E6\u05D1\u05E2",colorPresets:"\u05DE\u05E6\u05D1\u05D9 \u05E6\u05D1\u05E2 \u05DE\u05EA\u05D5\u05DB\u05E0\u05EA\u05D9\u05DD",customColors:"\u05E6\u05D1\u05E2\u05D9\u05DD \u05DE\u05D5\u05EA\u05D0\u05DE\u05D9\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA",newColor:"\u05E6\u05D1\u05E2 \u05DE\u05D5\u05EA\u05D0\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA \u05D7\u05D3\u05E9",noColor:"\u05DC\u05DC\u05D0",removeColor:"\u05D4\u05E1\u05E8 \u05E6\u05D1\u05E2",transparent:"\u05E9\u05E7\u05D5\u05E3"},hr:{add:"Dodati",addColor:"Dodaj boju",cancel:"Otka\u017Ei",colorFormat:"Format boje",colorPresets:"Prijedlozi boja",customColors:"Prilago\u0111ene boje",newColor:"Nova prilago\u0111ena boja",noColor:"Prazno",removeColor:"Ukloni boju",transparent:"Prozirna"},id:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batalkan",colorFormat:"Format Warna",colorPresets:"Preset Warna",customColors:"Warna Kustom",newColor:"Warna Khusus Baru",noColor:"Tidak ada",removeColor:"Hapus Warna",transparent:"Transparan"},it:{add:"Aggiungi",addColor:"Aggiungi colore",cancel:"Annulla",colorFormat:"Formato del colore",colorPresets:"Colori predefiniti",customColors:"Colori personalizzati",newColor:"Nuovo colore personalizzato",noColor:"Nessuno",removeColor:"Rimuovi colore",transparent:"Trasparente"},ja:{add:"\u8FFD\u52A0",addColor:"\u8272\u3092\u8FFD\u52A0",cancel:"\u30AD\u30E3\u30F3\u30BB\u30EB",colorFormat:"\u30AB\u30E9\u30FC\u30D5\u30A9\u30FC\u30DE\u30C3\u30C8",colorPresets:"\u30AB\u30E9\u30FC\u30D7\u30EA\u30BB\u30C3\u30C8",customColors:"\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",newColor:"\u65B0\u898F\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",noColor:"\u306A\u3057",removeColor:"\u8272\u3092\u524A\u9664",transparent:"\u900F\u660E"},ko:{add:"\uCD94\uAC00",addColor:"\uC0C9\uC0C1 \uCD94\uAC00",cancel:"\uCDE8\uC18C",colorFormat:"\uC0C9\uC0C1 \uD615\uC2DD",colorPresets:"\uC0C9\uC0C1 \uBBF8\uB9AC\uC124\uC815",customColors:"\uC0AC\uC6A9\uC790 \uC815\uC758 \uC0C9\uC0C1",newColor:"\uC0C8\uB85C\uC6B4 \uC0AC\uC6A9\uC790\uC9C0\uC815 \uC0C9\uC0C1",noColor:"\uC5C6\uC74C",removeColor:"\uC0C9\uC0C1 \uC81C\uAC70",transparent:"\uD22C\uBA85"},ms:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batal",colorFormat:"Format Warna",colorPresets:"Praset Warna",customColors:"Warna Kustom",newColor:"Warna Tersuai Baharu",noColor:"Tiada",removeColor:"Buang Warna",transparent:"Lut Sinar"},"nb-NO":{add:"Legg til",addColor:"Legg til farge",cancel:"Avbryt",colorFormat:"Fargeformat",colorPresets:"Fargeinnstillinger",customColors:"Egendefinerte farger",newColor:"Ny tilpasset farge",noColor:"Ingen",removeColor:"Fjern farge",transparent:"Gjennomsiktig"},nl:{add:"Voeg toe",addColor:"Kleur toevoegen",cancel:"Annuleer",colorFormat:"Kleurformaat",colorPresets:"Kleurvoorinstellingen",customColors:"Aangepaste kleuren",newColor:"Nieuwe aangepaste kleur",noColor:"Geen",removeColor:"Kleur verwijderen",transparent:"Doorzichtig"},pl:{add:"Dodaj",addColor:"Dodaj kolor",cancel:"Anuluj",colorFormat:"Format koloru",colorPresets:"Wst\u0119pnie ustawione kolory",customColors:"Niestandardowe kolory",newColor:"Nowy kolor niestandardowy",noColor:"Brak",removeColor:"Usu\u0144 kolor",transparent:"Prze\u015Bwiecaj\u0105ce"},"pt-PT":{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Predefini\xE7\xF5es de cor",customColors:"Cores personalizadas",newColor:"Nova cor personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},pt:{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Pr\xE9-ajustes de Cores",customColors:"Cores personalizadas",newColor:"Nova Cor Personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},ru:{add:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C",addColor:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0446\u0432\u0435\u0442",cancel:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u0446\u0432\u0435\u0442\u0430",colorPresets:"\u0411\u0438\u0431\u043B\u0438\u043E\u0442\u0435\u043A\u0430 \u0446\u0432\u0435\u0442\u043E\u0432",customColors:"\u041F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u0435\u043B\u044C\u0441\u043A\u0438\u0435 \u0446\u0432\u0435\u0442\u0430",newColor:"\u041D\u043E\u0432\u044B\u0439 \u0441\u043E\u0431\u0441\u0442\u0432\u0435\u043D\u043D\u044B\u0439 \u0446\u0432\u0435\u0442",noColor:"\u041D\u0435\u0442",removeColor:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0446\u0432\u0435\u0442",transparent:"\u041F\u0440\u043E\u0437\u0440\u0430\u0447\u043D\u044B\u0439"},sk:{add:"Prida\u0165",addColor:"Prida\u0165 farbu",cancel:"Zru\u0161i\u0165",colorFormat:"Form\xE1t farby",colorPresets:"Predvo\u013Eby farieb",customColors:"Vlastn\xE9 farby",newColor:"Vlastn\xE1 farba",noColor:"\u017Diadny",removeColor:"Odstr\xE1ni\u0165 farbu",transparent:"Prieh\u013Eadn\xE1"},sl:{add:"Dodaj",addColor:"Dodaj barvo",cancel:"Prekli\u010Di",colorFormat:"Barvni format",colorPresets:"Barvne predloge",customColors:"Prilagojene barve",newColor:"Nova barva po meri",noColor:"Prazna stran",removeColor:"Odstrani barvo",transparent:"Prosojna"},sv:{add:"L\xE4gg till",addColor:"L\xE4gg till f\xE4rg",cancel:"Avbryt",colorFormat:"F\xE4rgformat",colorPresets:"F\xF6rval f\xF6r f\xE4rger",customColors:"Anpassade f\xE4rger",newColor:"Ny anpassad f\xE4rg",noColor:"Ingen",removeColor:"Ta bort f\xE4rg",transparent:"Genomskinligt"},th:{add:"\u0E40\u0E1E\u0E34\u0E48\u0E21",addColor:"\u0E40\u0E1E\u0E34\u0E48\u0E21\u0E2A\u0E35",cancel:"\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01",colorFormat:"\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E2A\u0E35",colorPresets:"\u0E04\u0E48\u0E32\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E15\u0E31\u0E49\u0E07\u0E44\u0E27\u0E49\u0E25\u0E48\u0E27\u0E07\u0E2B\u0E19\u0E49\u0E32",customColors:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07",newColor:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07\u0E43\u0E2B\u0E21\u0E48",noColor:"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E40\u0E25\u0E22",removeColor:"\u0E25\u0E1A\u0E2A\u0E35",transparent:"\u0E42\u0E1B\u0E23\u0E48\u0E07\u0E43\u0E2A"},tr:{add:"Ekle",addColor:"Renk Ekle",cancel:"Vazge\xE7",colorFormat:"Renk Format\u0131",colorPresets:"Renk \xD6nayarlar\u0131",customColors:"\xD6zel Renkler",newColor:"Yeni \xF6zel renk",noColor:"Hi\xE7biri",removeColor:"Rengi Kald\u0131r",transparent:"\u015Eeffaf"},uk:{add:"\u0414\u043E\u0434\u0430\u0442\u0438",addColor:"\u0414\u043E\u0434\u0430\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",cancel:"\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u043A\u043E\u043B\u044C\u043E\u0440\u0443",colorPresets:"\u0411\u0456\u0431\u043B\u0456\u043E\u0442\u0435\u043A\u0430 \u043A\u043E\u043B\u044C\u043E\u0440\u0456\u0432",customColors:"\u041A\u043E\u0440\u0438\u0441\u0442\u0443\u0432\u0430\u0446\u044C\u043A\u0456 \u043A\u043E\u043B\u044C\u043E\u0440\u0438",newColor:"\u041D\u043E\u0432\u0438\u0439 \u0432\u043B\u0430\u0441\u043D\u0438\u0439 \u043A\u043E\u043B\u0456\u0440",noColor:"\u041D\u0435\u043C\u0430\u0454",removeColor:"\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",transparent:"\u041F\u0440\u043E\u0437\u043E\u0440\u0438\u0439"},"zh-Hans":{add:"\u6DFB\u52A0",addColor:"\u6DFB\u52A0\u989C\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u989C\u8272\u683C\u5F0F",colorPresets:"\u989C\u8272\u9884\u8BBE",customColors:"\u81EA\u5B9A\u4E49\u989C\u8272",newColor:"\u65B0\u81EA\u5B9A\u4E49\u989C\u8272",noColor:"\u65E0",removeColor:"\u79FB\u9664\u989C\u8272",transparent:"\u900F\u660E"},"zh-Hant":{add:"\u52A0\u5165",addColor:"\u6DFB\u52A0\u984F\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u984F\u8272\u683C\u5F0F",colorPresets:"\u984F\u8272\u9810\u8A2D\u9805",customColors:"\u81EA\u8A02\u984F\u8272",newColor:"\u65B0\u81EA\u8A02\u984F\u8272",noColor:"\u7121",removeColor:"\u79FB\u9664\u984F\u8272",transparent:"\u900F\u660E"}};var Pr=({children:e})=>{let{triggerProps:t}=to.useContext(je);return jsx(Slot,{...t,children:e})};Pr.displayName="ModalTrigger";var P5=({children:e})=>{let{state:t}=to.useContext(je);return jsx(Slot,{onPress:()=>t?.close(),children:e})};var Ue=to.forwardRef((e,t)=>{let{state:o,overlayTriggerAria:{overlayProps:r},triggerRef:a}=useContext(Yo);return invariant(a),o?.isOpen?jsx(le,{ref:t,...e,triggerRef:e.triggerRef||a,overlayProps:r,state:o}):null});Ue.displayName="PopoverContent";var Rc="_1dbkl53 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6kv",Ic="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt",Tc="_1dbkl5e",Nc=_({defaultClassName:"_1dbkl54 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l6 _1yep5z6ky _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6kx _1yep5z6dy",variantClassNames:{isHovered:{true:"_1dbkl55"},isFocusVisible:{true:"_1dbkl56"},isDisabled:{true:"z9nup83 _1yep5z6109"},labelPosition:{top:"_1dbkl58",start:"_1dbkl59"}},defaultVariants:{},compoundVariants:[]}),Sc=_({defaultClassName:"_1dbkl50 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6dy _1yep5z6ev",variantClassNames:{labelPosition:{top:"_1yep5z6nq _1yep5z6nr _1yep5z6ns",start:"_1dbkl52"}},defaultVariants:{},compoundVariants:[]}),kr="_1dbkl5l _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69f _1yep5z69g _1yep5z69h",Lc="_1dbkl5f z9nup87",wr="_1dbkl5m _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn",Mc="_1dbkl5k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ky",Dc="_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy _1yep5z6ev _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it",Rr=_({defaultClassName:"_1dbkl5h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs",variantClassNames:{includesCustomColorPicker:{true:"_1yep5z6me _1yep5z6mf _1yep5z6mg"}},defaultVariants:{},compoundVariants:[]}),mi="_1dbkl5v _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",Bc=_({defaultClassName:"_1dbkl5q _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6br _1yep5z6bs _1yep5z6bt _1yep5z6d3 _1yep5z6d4 _1yep5z6d5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocused:{true:"_1dbkl5r _1yep5z611y"},isHovered:{true:"_1dbkl5s"},allowAlpha:{false:"_1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6166"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,isFocused:!1},"_1yep5z61nd"]]}),Ec=_({defaultClassName:"_1dbkl5a _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62c _1yep5z62d _1yep5z62e _1yep5z63i _1yep5z63j _1yep5z63k _1yep5z616 _1yep5z617 _1yep5z618 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e _1yep5z6f0 _1yep5z6kx _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kl",variantClassNames:{isHovered:{true:"_1yep5z6115"},isFocusVisible:{true:"_1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612n"},isDisabled:{true:"_1yep5z610d"}},defaultVariants:{},compoundVariants:[]}),dt="_1dbkl5u",Ir="_1dbkl5g _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Tr="_1dbkl5j _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",ui="_1dbkl5x",Fc="_1dbkl5w",fi="_1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69l _1yep5z69m _1yep5z69n",Nr=_({defaultClassName:"_1dbkl5n _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6l2 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6l7 _1yep5z6la",variantClassNames:{isFocusVisible:{true:"_1dbkl5o _1yep5z616a _1yep5z612n _1yep5z616c"}},defaultVariants:{},compoundVariants:[]}),yi="z9nup84 z9nup86 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6ho _1yep5z6hp _1yep5z6hq";var Hc=_({defaultClassName:"_1344e9q0 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ks _1yep5z6hk _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",variantClassNames:{isFocusVisible:{true:"_1344e9q1"},isDisabled:{true:"_1344e9q2"},removeBlendMode:{true:"_1344e9q3"},isSelected:{true:"_1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616f"},isHovered:{true:"_1344e9q5"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isFocusVisible:!0},"_1344e9q6"],[{isSelected:!0,isFocusVisible:!0},"_1344e9q7 _1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq _1yep5z61o5"],[{isHovered:!0,isSelected:!1},"_1yep5z61rq _1yep5z61rn _1yep5z61rl _1yep5z61o2"]]});var he=to.forwardRef(({color:e,isFocusVisible:t,isSelected:o,isInteractive:r,isDisabled:a,style:i,className:n,id:l,"data-block-id":s,...p},d)=>{let u=e&&e!==xe&&(typeof e=="string"?parseColor(e):e),{formatMessage:c}=B(),m=!u,{colorSwatchProps:f}=useColorSwatch({color:m?"#000000":e}),{hoverProps:y,isHovered:g}=useHover({isDisabled:a||!r}),v=filterTruthyValues({"data-focus-visible":t,"data-selected":o,"data-hovered":g,"data-block-id":s,"data-disabled":a,"data-interactive":r});return jsx("div",{...mergeProps(y,v,m?{}:f),style:i,"aria-label":m?c(H5.none):f["aria-label"],role:"img",className:classNames(Hc({removeBlendMode:m,isFocusVisible:t,isDisabled:!!a,isSelected:!!o,isHovered:g}),"BaselineUI-ColorSwatch",n),ref:d,id:l,...p,children:jsx(M,{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"full",height:"full",width:"full",opacity:a?"medium":void 0,style:u?Oc(u,4):void 0,children:m?jsx(NoneIcon,{size:14}):null})})});he.displayName="ColorSwatch";var H5=j({none:{id:"none",defaultMessage:"None"}});var Ac=[{id:"hex",label:"HEX"},{id:"rgb",label:"RGB"}],Lo=parseColor("#000000").toFormat("hsla"),J="hsla",mt="hexa";function Je(e){return typeof e=="string"?parseColor(e).toFormat(J):e?e.toFormat(J):null}function jc(e,t){return e?.getChannelValue("alpha")?t?.toString(mt)===e.toString(mt):!t?.getChannelValue("alpha")}function $c(e,t,o){return t?.label?t.label:e?.getChannelValue("alpha")===0?o:e?.toString("rgba")}var xe="NONE";function Uc(e,t){let o=t?.map(a=>({id:parseColor(a.color).toString(mt),label:a.label}))||[],r={id:xe,label:e};return [...o,r]}var Sr=(e,{optionProps:t,isFocusVisible:o,isSelected:r},a)=>(invariant(e.value&&"label"in e.value,"Item must have label"),jsx("li",{...t,ref:a,className:Mc,children:jsx(he,{color:e.value.id,isFocusVisible:o,isSelected:r,"aria-label":e.value.label,isInteractive:!0})})),Oc=(e,t=4)=>{let o=e.getChannelValue("alpha")===0,r=`repeating-conic-gradient(transparent 0% 25%, ${themeVars.color.background.secondary.medium} 25% 50%)`;return {backgroundImage:o?r:`linear-gradient(${e.toString("hexa")}, ${e.toString("hexa")}), ${r}`,backgroundSize:`${t}px ${t}px`}};var Kc=({value:e,...t})=>{let o=to.useRef(null),r=to.useRef(null),a=to.useRef(null),i=useColorAreaState({...t,value:e}),{colorAreaProps:n,xInputProps:l,yInputProps:s,thumbProps:p}=useColorArea({...t,value:e,inputXRef:o,inputYRef:r,containerRef:a},i);useEffect(()=>{o.current?.focus();},[]);let{focusProps:d,isFocusVisible:u}=useFocusRing();return jsx("div",{ref:a,...n,className:classNames(Rc,"BaselineUI-ColorInput-ColorArea"),children:jsxs("div",{...p,className:classNames(Nr({isFocusVisible:u}),"BaselineUI-ColorInput-ColorAreaThumb"),style:{...p.style,transform:"translate(-50%, -50%)",backgroundColor:Je(e)?.withChannelValue("alpha",1).toString("css")},children:[jsx("input",{ref:o,...l,...d}),jsx("input",{ref:r,...s,...d})]})})};var Xc=({color:e,setColor:t,allowAlpha:o,...r})=>{let a=useColorFieldState({value:e,onChange:u=>{t(Je(u)?.toFormat(J).withChannelValue("alpha",e.getChannelValue("alpha")??1)||Lo);}}),i=to.useRef(null),{inputProps:n}=useColorField({...r,"aria-label":"Hex"},a,i),{focusProps:l,isFocused:s}=useFocusRing({isTextInput:!0}),{hoverProps:p,isHovered:d}=useHover({});return jsxs("div",{className:classNames(mi,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"hexa":"hex",children:[jsx("input",{...mergeProps(n,l,p),ref:i,className:Bc({isFocused:s,isHovered:d,allowAlpha:o})}),o?jsx(Zc,{color:e,setColor:t}):null]})},Yc=({color:e,setColor:t,allowAlpha:o})=>{let r=e.toFormat("rgba"),{locale:a}=useLocale();return jsxs("div",{className:classNames(mi,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"rgba":"rgb",children:[jsx(Ie,{"aria-label":e.getChannelName("red",a),value:r.getChannelValue("red"),showStepper:!1,className:dt,onChange:i=>{t(r.withChannelValue("red",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsx(Ie,{"aria-label":e.getChannelName("green",a),value:r.getChannelValue("green"),showStepper:!1,className:dt,onChange:i=>{t(r.withChannelValue("green",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsx(Ie,{"aria-label":e.getChannelName("blue",a),value:r.getChannelValue("blue"),showStepper:!1,className:dt,onChange:i=>{t(r.withChannelValue("blue",i).toFormat(J));},step:1,minValue:0,maxValue:255}),o?jsx(Zc,{color:e,setColor:t}):null]})},J5={style:"percent",maximumFractionDigits:0},Zc=({color:e,setColor:t})=>{let{locale:o}=useLocale(),r=useCallback(a=>{t(e.withChannelValue("alpha",a));},[e,t]);return jsx(Ie,{"aria-label":e.getChannelName("alpha",o),value:e.getChannelValue("alpha"),formatOptions:J5,className:dt,showStepper:!1,onChange:r,minValue:0,maxValue:1})};var zi=({channel:e,...t})=>{let{locale:o}=useLocale(),r=useColorSliderState({...t,channel:e,locale:o}),a=to.useRef(null),i=to.useRef(null),{trackProps:n,thumbProps:l,inputProps:s}=useColorSlider({...t,channel:e,trackRef:a,inputRef:i,"aria-label":r.value.getChannelName(e,o)},r),{focusProps:p,isFocusVisible:d}=useFocusRing();return jsxs("div",{className:classNames(wr,{[Qn({size:"xs"})]:e==="alpha"},"BaselineUI-ColorInput-ColorSlider"),"data-channel":e,...n,ref:a,children:[e==="alpha"&&jsx("div",{className:yi}),jsx("div",{className:wr,style:n.style}),jsxs("div",{className:classNames(Nr({isFocusVisible:d}),"BaselineUI-ColorInput-ColorSliderThumb"),...l,children:[jsx("div",{className:yi,style:{backgroundColor:"#ffffff"}}),jsx("div",{style:{backgroundColor:r.getDisplayColor().toString("css"),height:8},className:wr}),jsx(VisuallyHidden,{children:jsx("input",{ref:i,...s,...p})})]})]})};var Lr=({color:e,setColor:t,allowAlpha:o})=>{let[r,a]=to.useState("hex"),{formatMessage:i}=B($e);return jsxs(Fragment,{children:[jsx(Kc,{value:e,xChannel:"saturation",yChannel:"lightness",onChange:t}),jsxs("div",{className:fi,children:[jsx(zi,{channel:"hue",value:e,onChange:t}),o?jsx(zi,{channel:"alpha",value:e,onChange:t}):null]}),jsxs("div",{className:classNames(fi,sprinkles.variants({paddingTop:"none",gap:"sm"})),children:[jsx(Ae,{label:i("colorFormat"),labelPosition:"start",variant:"ghost",items:Ac,selectedKey:r,onSelectionChange:n=>{a(n);}}),r==="hex"&&jsx(Xc,{color:e,setColor:t,allowAlpha:o}),r==="rgb"&&jsx(Yc,{color:e,setColor:t,allowAlpha:o})]})]})};var Ci=({color:e,setColor:t,storePickedColorKey:o,addColorButtonLabel:r,removeColorButtonLabel:a,customColorsLabel:i,pickerMode:n,allowAlpha:l})=>{let{locale:s}=useLocale(),{formatMessage:p}=B($e),d=to.useRef(null),u=go(d.current),[c,m]=Hs(o,[]),f=to.useRef(null),[y,g]=to.useState(e),v=to.useMemo(()=>c.map(C=>({id:C,label:parseColor(C).getColorName(s),description:C})),[c,s]),b=useCallback(()=>{let C=n==="active"?e:y;if(c.includes(C.toString(J))){f.current?.querySelector(`[data-key='${C.toString(J)}']`)?.classList.add(ui);return}m([...c,C.toString(J)]);},[c,e,m,y,n]);useEffect(()=>{let C=f.current;function P(k){k.animationName===Fc&&k.target?.classList.remove(ui);}return C?.addEventListener("animationend",P),()=>{C?.removeEventListener("animationend",P);}},[]);let h=useId(),z=jsx(L,{ref:d,variant:"secondary",size:"md","aria-label":r,icon:PlusIcon$1,onPress:n==="active"?b:void 0}),x=useCallback(C=>jsxs(me,{size:"content",className:Rr({includesCustomColorPicker:!0}),style:{paddingBlockEnd:0},"aria-label":p("newColor"),children:[jsx(Lr,{color:y,setColor:g,allowAlpha:l}),jsx(F,{}),jsx(M,{padding:"lg",display:"flex",flexDirection:"row-reverse",children:jsxs(M,{display:"inline-flex",gap:"lg",children:[jsx(O,{label:p("cancel"),size:"sm",variant:"secondary",onPress:C}),jsx(O,{label:p("add"),variant:"primary",onPress:()=>{b(),C();},size:"sm"})]})})]}),[y,b,p,l]),R=useCallback(C=>{invariant(C instanceof Set,"Key must be a set");let P=[...C][0];P&&t(parseColor(P).toFormat(J));},[t]);return jsxs(Fragment,{children:[jsx(F,{}),jsxs("div",{className:classNames(Dc,"BaselineUI-ColorInput-CustomColors"),children:[jsx("span",{id:h,children:i}),jsxs(M,{display:"flex",children:[!!c.length&&c.includes(e.toString(J))&&jsx(L,{variant:"secondary",size:"md",elementType:"div",icon:MinusIcon$2,"aria-label":a,onPress:()=>{m(c.filter(C=>C!==e.toString(J)));}}),n==="active"&&z,n==="lazy"&&(u==="mobile"?jsxs(ze,{children:[jsx(Pr,{children:z}),jsx(Te,{style:{zIndex:1e5},children:({close:C})=>x(C)})]}):jsx(Xe,{type:"dialog",children:({close:C})=>jsxs(Fragment,{children:[jsx(Ye,{children:z}),jsx(Ue,{placement:"right top",className:Ir,offset:6,children:x(C)})]})}))]})]}),!!c.length&&jsx(te,{items:v,layout:"grid","aria-labelledby":h,className:classNames(kr,Tr,sprinkles.variants({paddingTop:"xs"}),"BaselineUI-ColorInput-CustomColorsListBox"),renderOption:Sr,ref:f,autoFocus:!1,selectionMode:"single",selectedKeys:[e.toString(J)],onSelectionChange:R})]})};var Pi=to.forwardRef(({setColor:e,color:t,triggerRef:o,autoFocus:r,presets:a,state:i},n)=>{let{formatMessage:l}=B($e),s=useCallback(p=>{if(p instanceof Set&&p.size){let d=[...p][0],u=a.find(c=>c.id===d);invariant(u,"Preset not found"),e(u.id===xe?null:parseColor(u.id).toFormat(J)),i.close();}},[i,a,e]);return jsx("div",{className:classNames(Tr,"BaselineUI-ColorInput-Presets"),style:{minWidth:o.current?.offsetWidth},ref:n,children:jsx(te,{autoFocus:r,items:a,layout:"grid","aria-label":l("colorPresets"),className:kr,renderOption:Sr,selectionMode:"single",selectedKeys:[t?.toString(mt)||xe],onSelectionChange:s})})});Pi.displayName="ColorPresetList";var ft=to.forwardRef(({color:e,colorLabel:t,colorName:o,...r},a)=>{let i=to.useRef(null),{hoverProps:n,isHovered:l}=useHover({isDisabled:r.isDisabled}),{buttonProps:s,isPressed:p}=useButton(r,i),{isFocusVisible:d,focusProps:u}=useFocusRing(),c=filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":d,"data-focus-visible":d,"data-disabled":r.isDisabled,"data-hovered":l,"data-pressed":p});return jsxs("button",{...mergeProps(s,n,u,c),style:r.style,className:classNames(Nc({isHovered:l,isFocusVisible:d||r.isOpen,isDisabled:r.isDisabled,labelPosition:r.labelPosition}),"BaselineUI-ColorInputButton",r.className),ref:N(a,i),children:[jsx(he,{color:e?.toString("hexa")}),t?jsx("div",{className:Lc,children:o}):jsx(VisuallyHidden,{children:o})]})});ft.displayName="ColorInputButton";var Br=to.forwardRef(({className:e,style:t,icon:o,...r},a)=>{let i=to.useRef(null),{hoverProps:n,isHovered:l}=useHover({isDisabled:r.isDisabled}),{buttonProps:s,isPressed:p}=useButton(r,i),{isFocusVisible:d,focusProps:u}=useFocusRing(),c=filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":d,"data-focus-visible":d,"data-disabled":r.isDisabled,"data-hovered":l,"data-pressed":p});return jsxs("button",{...mergeProps(s,n,u,c),ref:N(a,i),style:t,className:classNames(Ec({isHovered:l||p||r.isOpen,isFocusVisible:d,isDisabled:r.isDisabled}),"BaselineUI-IconColorInputButton",e),children:[jsx(o,{size:16}),jsx("div",{className:Tc,style:{backgroundColor:r.color||void 0}})]})});Br.displayName="IconColorInputButton";function ud({colorLabel:e,color:t,presets:o}){let{formatMessage:r}=B(),{locale:a}=useLocale(),i=useMemo(()=>o.find(s=>s.id===xe?!t:t?jc(t,parseColor(s.id)):!1),[o,t]),n=useMemo(()=>typeof e=="function"?e?.(t):e?$c(t,i,r(Pz.transparent)):!1,[t,e,r,i]),l=useMemo(()=>{if(i?.label)return i.label;t?.getColorName(a);},[t,a,i?.label]);return {colorName:n,humanReadableName:l}}var Pz=j({transparent:{defaultMessage:"Transparent",id:"transparent"}});var Bo=to.forwardRef(({className:e,style:t,allowRemoval:o,allowAlpha:r=!0,presets:a,labelPosition:i="top",colorLabel:n=!0,includePicker:l=!0,onChange:s,defaultValue:p,storePickedColorKey:d="baselinePickedColor",value:u,addColorButtonLabel:c,removeColorButtonLabel:m,customColorsLabel:f,renderTriggerButton:y=({isOpen:R,color:C,ref:P,colorName:k,triggerProps:T,labelId:I})=>jsx(ft,{...mergeProps(T,{...z.label?{"aria-labelledby":I}:{"aria-label":z["aria-label"]}}),ref:P,isOpen:R,isDisabled:z.isDisabled,labelPosition:i,color:C,colorLabel:n,colorName:k}),pickerMode:g="active",offset:v=2,placement:b=i==="start"?"bottom end":"bottom start","data-block-id":h,...z},x)=>{let R=to.useRef(null),C=to.useRef(null),P=useOverlayTriggerState(z),{triggerProps:k,overlayProps:T}=useOverlayTrigger({type:"listbox"},P,R),I=de(z.portalContainer),[D,E]=useControlledState(u===void 0?void 0:Je(u),Je(p),V=>s?.(V?.toFormat("rgba")||null)),{formatMessage:w}=B($e),S=useMemo(()=>Uc(w(Er.noColor),a),[a,w]),$=useId(),{colorName:re}=ud({colorLabel:n,color:D,presets:S}),pe=useMemo(()=>S.filter(V=>o||V.id!==xe),[S,o]),X=c||w(Er.addColor),K=m||w(Er.removeColor),G=f||w(Er.customColors);return jsxs(Fragment,{children:[jsxs("div",{className:classNames({[Ic]:i==="start"},"BaselineUI-ColorInput-Trigger",e),"data-block-id":h,style:t,ref:x,children:[z.label?jsx("label",{id:$,className:Sc({labelPosition:i}),children:z.label}):null,y({isOpen:P.isOpen,color:D,ref:R,colorName:re,triggerProps:k,labelId:$})]}),P.isOpen?jsx(le,{...z,portalContainer:I,placement:b,state:P,offset:v,className:classNames(Ir,"BaselineUI-ColorInput-Popover"),triggerRef:R,overlayProps:T,children:jsxs(me,{size:"content",className:Rr({includesCustomColorPicker:l}),ref:C,"aria-labelledby":$,"aria-label":z["aria-label"],children:[l&&g==="active"?jsxs(Fragment,{children:[jsx(Lr,{color:D||Lo,setColor:E,allowAlpha:r}),jsx(Ci,{color:D||Lo,setColor:E,storePickedColorKey:d,addColorButtonLabel:X,removeColorButtonLabel:K,customColorsLabel:G,pickerMode:g,allowAlpha:r})]}):null,!!pe.length&&jsxs(Fragment,{children:[l&&g==="active"?jsx(F,{}):null,jsx(Pi,{autoFocus:l&&g==="active"?!1:"first",state:P,triggerRef:R,presets:pe,color:D,setColor:E})]}),l&&g==="lazy"?jsx(Ci,{color:D||Lo,setColor:E,storePickedColorKey:d,addColorButtonLabel:X,removeColorButtonLabel:K,customColorsLabel:G,pickerMode:g,allowAlpha:r}):null]})}):null]})});Bo.displayName="ColorInput";var Er=j({addColor:{defaultMessage:"Add color",id:"addColor"},removeColor:{defaultMessage:"Remove color",id:"removeColor"},customColors:{defaultMessage:"Custom colors",id:"customColors"},noColor:{defaultMessage:"No color",id:"noColor"},transparent:{defaultMessage:"Transparent",id:"transparent"}});var gd=to.forwardRef(({className:e,style:t,icon:o,includeTooltip:r,variant:a="standard","data-block-id":i,placement:n="bottom start",...l},s)=>{let p=to.useRef(null),d=useCallback(({isOpen:u,color:c,ref:m,colorName:f,triggerProps:y})=>jsx(He,{isDisabled:!r||l.isDisabled,variant:"inverse",size:"sm",includeArrow:!1,text:l["aria-label"],placement:n,offset:4,children:a==="standard"?jsx(ft,{...y,"aria-label":l["aria-label"],ref:m,isOpen:u,isDisabled:l.isDisabled,color:c,colorLabel:!1,colorName:f}):jsx(Br,{...y,isOpen:u,icon:TextIcon,color:c?.toString("hexa"),ref:m,isDisabled:l.isDisabled,"aria-label":l["aria-label"]})}),[r,n,l,a]);return jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:a==="standard"?"md":"none",alignItems:"center",className:classNames("BaselineUI-IconColorInput",e),"data-block-id":i,style:t,ref:N(s,p),children:[a==="standard"&&jsx(o,{size:24,className:sprinkles({color:"icon.primary"})}),jsx(Bo,{...l,colorLabel:!1,renderTriggerButton:d})]})});gd.displayName="IconColorInput";var vd={ar:{redo:"\u0625\u0639\u0627\u062F\u0629",undo:"\u062A\u0631\u0627\u062C\u0639"},cs:{redo:"Opakovat",undo:"Zru\u0161it"},cy:{redo:"Ail-wneud",undo:"Dad-wneud"},da:{redo:"Gentag",undo:"Fortryd"},de:{redo:"Wiederholen",undo:"R\xFCckg\xE4ngig machen"},el:{redo:"\u0395\u03C0\u03B1\u03BD\u03AC\u03BB\u03B7\u03C8\u03B7",undo:"\u0391\u03BD\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7"},"en-GB":{redo:"Redo",undo:"Undo"},en:{redo:"Redo",undo:"Undo"},es:{redo:"Rehacer",undo:"Deshacer"},fi:{redo:"Tee sittenkin",undo:"Peru"},"fr-CA":{redo:"R\xE9tablir",undo:"Annuler"},fr:{redo:"R\xE9tablir",undo:"Annuler"},he:{redo:"\u05D1\u05D9\u05E6\u05D5\u05E2 \u05DE\u05D7\u05D3\u05E9",undo:"\u05D1\u05D9\u05D8\u05D5\u05DC \u05E4\u05E2\u05D5\u05DC\u05D4"},hr:{redo:"Ponovi",undo:"Vrati"},id:{redo:"Ulangi",undo:"Kembalikan"},it:{redo:"Ripristina",undo:"Annulla"},ja:{redo:"\u3084\u308A\u76F4\u3059",undo:"\u53D6\u308A\u6D88\u3059"},ko:{redo:"\uC2E4\uD589\uBCF5\uADC0",undo:"\uC2E4\uD589\uCDE8\uC18C"},ms:{redo:"Buat Semula",undo:"Buat Asal"},"nb-NO":{redo:"Gj\xF8r om igjen",undo:"Angre"},nl:{redo:"Opnieuw",undo:"Herstel"},pl:{redo:"Pon\xF3w",undo:"Cofnij"},"pt-PT":{redo:"Refazer",undo:"Desfazer"},pt:{redo:"Refazer",undo:"Desfazer"},ru:{redo:"\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u044C",undo:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C"},sk:{redo:"Opakova\u0165",undo:"Zru\u0161i\u0165"},sl:{redo:"Uveljavi",undo:"Razveljavi"},sv:{redo:"G\xF6r om",undo:"\xC5ngra"},th:{redo:"\u0E17\u0E33\u0E0B\u0E49\u0E33",undo:"\u0E16\u0E2D\u0E19\u0E04\u0E33\u0E2A\u0E31\u0E48\u0E07\u0E01\u0E25\u0E31\u0E1A"},tr:{redo:"Yinele",undo:"Geri Al"},uk:{redo:"\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u0438",undo:"\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438"},"zh-Hans":{redo:"\u91CD\u505A",undo:"\u64A4\u9500"},"zh-Hant":{redo:"\u91CD\u4F5C",undo:"\u5FA9\u539F"}};var Fr=_({defaultClassName:"mnnh5s1 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ki _1yep5z6kl _1yep5z6kx _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{true:"mnnh5s2 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy _1yep5z6122 _1yep5z616j _1yep5z616k",false:"_1yep5z6166 _1yep5z6116"},isHovered:{true:"mnnh5s4"},hasLoadedImage:{true:"_1yep5z6115"},includeCheckeredBackground:{true:"mnnh5s6"},showFocusRing:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 _1yep5z6yl"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,hasLoadedImage:!1},"_1yep5z61mo"],[{isHovered:!0,hasLoadedImage:!0},"mnnh5s9"],[{isInline:!0,isDisabled:!0},"_1yep5z61nd"],[{hasLoadedImage:!0,includeCheckeredBackground:!0},"_1yep5z61mg"]]}),_d="_1yep5z6d8",Hr=_({defaultClassName:"mnnh5sa",variantClassNames:{isInline:{true:"mnnh5sb",false:"mnnh5sc"},isDisabled:{true:"mnnh5sd"},hasLoadedImage:{true:"mnnh5s0"}},defaultVariants:{},compoundVariants:[]});var zd=_({defaultClassName:"_1i0ytqa3 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6kw _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1i0ytqa4"},isInline:{true:"_1yep5z611e",false:"_1yep5z611g"},isDisabled:{true:"_1i0ytqa7 _1yep5z6yl",false:"_1i0ytqa8"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isFocusVisible:!0},"_1i0ytqa9 _1yep5z61n9 _1yep5z61rt _1yep5z61rv"],[{isInline:!1,isFocusVisible:!0},"_1i0ytqaa"],[{isInline:!0,isDisabled:!0},"_1yep5z61mp"],[{isInline:!1,isDisabled:!0},"_1yep5z61mr"]]}),hd="_1i0ytqa0",Or=_({defaultClassName:"_1i0ytqab _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z6115"},isDisabled:{true:"_1i0ytqad _1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),xd=_({defaultClassName:"_1i0ytqa1 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b"}},defaultVariants:{},compoundVariants:[]});var Wz={size:1,thinning:0,smoothing:0,streamline:0,easing:e=>e,start:{taper:0,easing:e=>e,cap:!0},end:{taper:0,easing:e=>e,cap:!0},simulatePressure:!1},kd=to.forwardRef(({className:e,style:t,canvasClassName:o,canvasStyle:r,isBound:a=!0,strokeWidth:i=2,strokeColor:n="#3A87FD",onChange:l,defaultValue:s,onChangeEnd:p,enableHistory:d=!1,isInline:u=!0,isDisabled:c,placeholder:m,clearLabel:f,undoLabel:y,redoLabel:g,footerClassName:v,canvasRef:b,value:h,footerStyle:z,"data-block-id":x,"aria-label":R="Drawing canvas",description:C="This is a canvas for drawing using a mouse or touch input.",...P},k)=>{let T=B(vd),I=to.useRef(null),[D,E]=to.useState(h?Ni(h):s?Ni(s):[]),w=to.useMemo(()=>({...Wz,...P}),[P]),[S,$]=to.useState(),re=useId(),{labelProps:pe,fieldProps:X}=useLabel({...P,"aria-label":R,labelElementType:"span"}),{isFocusVisible:K,focusProps:G}=useFocusRing({within:!0}),{hoverProps:V,isHovered:Z}=useHover({isDisabled:c}),{undo:ee,redo:Ce,canRedo:Pe,canUndo:ye,push:ke}=Ms(D,{onAction:A=>{A&&(E(A),p?.(A.map(H=>getStroke(H,w))));},isDisabled:!d}),{keyboardProps:Le}=useKeyboard({onKeyDown:A=>{A.key==="Backspace"?Ot():A.key==="z"&&(A.metaKey||A.ctrlKey)&&(A.shiftKey?Pe&&Ce():ye&&ee());}}),[oe,ce]=useState(!1),sa=useCallback(A=>{let H=A.currentTarget.getBoundingClientRect();$(H),A.target.setPointerCapture(A.pointerId);let ae={x:A.clientX-H.x,y:A.clientY-H.y,pressure:A.pressure};E(U=>[...U,[ae]]),ce(!0);},[]),la=useCallback(A=>{if(A.buttons!==1||!S)return;let ae=Id(A.nativeEvent).map(U=>({x:a?clamp(U.clientX-S.left,0,S.width):U.clientX-S.left,y:a?clamp(U.clientY-S.top,0,S.height):U.clientY-S.top,pressure:U.pressure}));E(U=>{let be=[...U];return be[U.length-1]=[...be[U.length-1],...ae],be});},[S,a]),pa=useCallback(()=>{S&&(p?.(D.map(A=>getStroke(A,w))),ke(D),ce(!1));},[S,p,D,ke,w]),Ht=Fe();useGranularEffect(()=>{Ht||l?.(D.map(A=>getStroke(A,w)));},[D],[l,w,Ht]);let Ot=()=>{E([]),l?.([]),ke([]);};return jsxs("div",{ref:N(I,k),className:classNames(hd,"BaselineUI-FreehandCanvas",e),style:t,"aria-disabled":c,"data-block-id":x,children:[P.label||d?jsxs("div",{className:xd({isInline:u}),children:[P.label?jsx(W,{type:"label",size:"sm",...pe,children:P.label}):jsx("span",{}),d?jsxs("div",{children:[jsx(L,{variant:"secondary",size:"sm",isDisabled:!ye||c,icon:UndoIcon,onPress:ee,"aria-label":y||T.formatMessage("undo")}),jsx(L,{variant:"secondary",size:"sm",isDisabled:!Pe||c,icon:RedoIcon,onPress:Ce,"aria-label":g||T.formatMessage("redo")})]}):null]}):null,jsxs("div",{role:"application",...mergeProps(G,Le,V,X),tabIndex:c?void 0:0,className:classNames(Fr({isInline:u,isHovered:Z}),zd({isFocusVisible:K,isInline:u,isDisabled:!!c}),o),"aria-describedby":P["aria-describedby"]||re,style:r,ref:b,children:[jsx(VisuallyHidden,{children:jsx("div",{id:re,children:C})}),jsx("svg",{width:r?.width||"100%",height:r?.height||"100%",onPointerDown:sa,onPointerMove:la,onPointerUp:pa,children:(h?Ni(h):D).map((A,H,ae)=>H<ae.length-1||!oe?jsx(wd,{points:A,options:w,strokeColor:n,strokeWidth:i},H):jsx(Rd,{points:A,options:w,strokeColor:n,strokeWidth:i},H))})]}),m||f?jsx("div",{style:z,className:classNames(Or({isInline:u,isDisabled:c}),v),children:(D.length||!m)&&f?jsx(O,{size:"sm",variant:"ghost",label:f,isDisabled:c,onPress:Ot}):jsx(O,{size:"sm",variant:"ghost",label:m,isDisabled:!0})}):null]})});kd.displayName="FreehandCanvas";var wd=to.memo(({points:e,options:t,strokeColor:o,strokeWidth:r})=>{let a=useMemo(()=>getSvgPathFromStroke(getStroke(e,t)),[e,t]);return jsx("path",{d:a,stroke:o,strokeWidth:r})});wd.displayName="Stroke";var Rd=to.memo(({points:e,options:t,strokeColor:o,strokeWidth:r})=>{let a=useRef([]),i=useMemo(()=>{let n=[],l=Math.ceil(e.length/Vr);for(let s=0;s<l;s++)if(s===l-1){let p=e.slice(s*Vr-(s>0?1:0),s*Vr+Vr),d=getSvgPathFromStroke(getStroke(p,t));n.push(d),a.current[s]=d;}else n.push(a.current[s]);return n},[e,t]);return jsx(Fragment,{children:i.map((n,l)=>jsx("path",{d:n,stroke:o,strokeWidth:r},l))})});Rd.displayName="SplitStroke";var Ni=e=>e.map(t=>t.map(([o,r])=>({x:o,y:r,pressure:0}))),Vr=60*3;function Id(e){if(typeof e.getCoalescedEvents=="function"){let t=e.getCoalescedEvents();return [e,...t.flatMap(o=>Id(o))]}return [e]}var Td="_1vac7ws0",Nd=_({defaultClassName:"_1vac7ws1",variantClassNames:{isDragging:{true:"_1vac7ws2"}},defaultVariants:{},compoundVariants:[]});function Ld(e,t){let[o,r]=useState([]),a=()=>e?.flatMap(i=>[...t.querySelectorAll(i)]).map(i=>({current:i}));return useGranularEffect(()=>{r(a());},[],[a]),useGranularEffect(()=>{let i=a();r(i);},[e],[a]),o}function Md(e){let{scrollable:t,ownerDocument:o,onScroll:r}=e;useEffect(()=>{let a=getHTMLElement(t,o);if(a)return (a.style.position==="static"||!a.style.position)&&console.warn("Scrollable ancestor passed to `Transform` component should not be statically positioned."),a.addEventListener("scroll",r),()=>{a.removeEventListener("scroll",r);}},[t,r,o]);}var dh=makeMoveable([Draggable,Resizable,Rotatable,Snappable]),Bd=to.forwardRef(({className:e,children:t,isRotatable:o,isResizable:r,isDraggable:a,style:i,onTransform:n,onTransformStart:l,onTransformEnd:s,onDoubleClick:p,onDragStart:d,onDragEnd:u,onDrag:c,onResizeStart:m,onResizeEnd:f,onResize:y,onRotateStart:g,onRotateEnd:v,onRotate:b,onSnap:h,isSnappable:z,elementGuidelines:x,hideAnchorOnDrag:R=!0,title:C,rotationPosition:P,autoUpdate:k,bound:T,snapRotationDegrees:I,snapRotationThreshold:D,scrollableAncestor:E,renderDirections:w,stopPropagation:S,transformOrigin:$,preventDefault:re},pe)=>{let X=useRef(null),K=useRef(null),[G,V]=useState(document),Z=useRef(G.createElement("div")),[ee,Ce]=useState({}),[Pe,ye]=useState(!1),[ke,Le]=useState(!1),[oe,ce]=useState(),sa=Ld(x,G);useLayoutEffect(()=>{let H=Z.current;return Z.current=G.createElement("div"),()=>{H.remove();}},[G]);let{keyboardProps:la}=useKeyboard({onKeyDown:H=>{let ae=H.shiftKey?10:1,U=H.metaKey||H.ctrlKey;U&&H.shiftKey&&(ae=45);function be(qo,vf="x"){U?K.current?.request("rotatable",{deltaRotate:qo*ae},!0):K.current?.request("draggable",vf==="x"?{deltaX:qo*ae}:{deltaY:qo*ae},!0);}switch(H.key){case"ArrowRight":{be(1);break}case"ArrowLeft":{be(-1);break}case"ArrowUp":{be(-1,"y");break}case"ArrowDown":be(1,"y");}requestAnimationFrame(()=>{K.current?.updateRect();});}});useEffect(()=>{let H=ge(X.current);V(H);let ae=Z.current;H.body.append(Z.current);function U(qo){Le(qo.shiftKey);}function be(){Le(!1);}return H.addEventListener("keydown",U),H.addEventListener("keyup",be),()=>{H.removeEventListener("keydown",U),H.removeEventListener("keyup",be),ae.remove();}},[]),Md({scrollable:E,onScroll:()=>{K.current?.updateRect();},ownerDocument:G});let pa=useCallback(H=>{Ce(ae=>({...ae,...H.style})),n?.(H);},[n]),Ht=useCallback(H=>{if(ye(!0),X.current?.focus(),T){let U=getHTMLElement(T,G)?.getBoundingClientRect();ce({position:"client",left:U?.left??0,top:U?.top??0,right:U?.right??0,bottom:U?.bottom??0});}d?.(H);},[T,G,d]),Ot=useCallback(H=>{ye(!1),u?.(H);},[u]),A=t({style:{...ee.width&&{width:ee.width},...ee.height&&{height:ee.height}}});return jsxs(Fragment,{children:[jsx("div",{role:"button",...la,ref:N(X,pe),style:{display:"inline-block",...i,...ee},className:classNames(Td,e),onDoubleClick:p,tabIndex:0,title:C,children:A}),createPortal(jsx(dh,{ref:K,target:X,draggable:a,resizable:r,rotatable:o,keepRatio:ke,throttleDrag:1,snappable:z||!!T,elementGuidelines:sa,snapRenderThreshold:.9,className:Nd({isDragging:Pe&&R}),onRender:pa,onDragStart:Ht,onDragEnd:Ot,useResizeObserver:k,useMutationObserver:k,onRenderEnd:s,onDrag:c,onResizeStart:m,onResizeEnd:f,onResize:y,onRotateStart:g,onRotateEnd:v,onRotate:b,onRenderStart:l,onSnap:h,rotationPosition:P,bounds:oe,snapRotationDegrees:I,snapRotationThreshold:D,renderDirections:w,stopPropagation:S,preventDefault:re,transformOrigin:$}),Z.current)]})});Bd.displayName="Transform";var Ed={ar:{delete:"\u062D\u0630\u0641",selectImage:"\u062A\u062D\u062F\u064A\u062F \u0635\u0648\u0631\u0629"},cs:{delete:"Smazat",selectImage:"Vybrat obr\xE1zek"},cy:{delete:"Dileu",selectImage:"Dewiswch Ddelwedd"},da:{delete:"Slet",selectImage:"V\xE6lg billede"},de:{delete:"L\xF6schen",selectImage:"Bild ausw\xE4hlen"},el:{delete:"\u0394\u03B9\u03B1\u03B3\u03C1\u03B1\u03C6\u03AE",selectImage:"\u0395\u03C0\u03B9\u03BB\u03BF\u03B3\u03AE \u03B5\u03B9\u03BA\u03CC\u03BD\u03B1\u03C2"},"en-GB":{delete:"Delete",selectImage:"Select Image"},en:{delete:"Delete",selectImage:"Select Image"},es:{delete:"Eliminar",selectImage:"Seleccionar imagen"},fi:{delete:"Poista",selectImage:"Valitse kuva"},"fr-CA":{delete:"Supprimer",selectImage:"S\xE9lectionner une image"},fr:{delete:"Supprimer",selectImage:"S\xE9lectionner une image"},he:{delete:"\u05DE\u05D7\u05D9\u05E7\u05D4",selectImage:"\u05D1\u05D7\u05D9\u05E8\u05EA \u05EA\u05DE\u05D5\u05E0\u05D4"},hr:{delete:"Obri\u0161i",selectImage:"Odaberi sliku"},id:{delete:"Hapus",selectImage:"Pilih Gambar"},it:{delete:"Elimina",selectImage:"Seleziona immagine"},ja:{delete:"\u524A\u9664",selectImage:"\u30A4\u30E1\u30FC\u30B8\u3092\u9078\u629E"},ko:{delete:"\uC0AD\uC81C",selectImage:"\uC774\uBBF8\uC9C0 \uC120\uD0DD"},ms:{delete:"Padam",selectImage:"Pilih Imej"},"nb-NO":{delete:"Slett",selectImage:"Velg bilde"},nl:{delete:"Verwijder",selectImage:"Selecteer afbeelding"},pl:{delete:"Usu\u0144",selectImage:"Wybierz obraz"},"pt-PT":{delete:"Apagar",selectImage:"Selecionar imagem"},pt:{delete:"Apagar",selectImage:"Selecionar Imagem"},ru:{delete:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C",selectImage:"\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0438\u0437\u043E\u0431\u0440."},sk:{delete:"Zmaza\u0165",selectImage:"Vybra\u0165 obr\xE1zok"},sl:{delete:"Izbri\u0161i",selectImage:"Izberi sliko"},sv:{delete:"Radera",selectImage:"V\xE4lj bild"},th:{delete:"\u0E25\u0E1A",selectImage:"\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E23\u0E39\u0E1B\u0E20\u0E32\u0E1E"},tr:{delete:"Sil",selectImage:"Resim Se\xE7"},uk:{delete:"\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438",selectImage:"\u041E\u0431\u0440\u0430\u0442\u0438 \u0437\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u043D\u044F"},"zh-Hans":{delete:"\u5220\u9664",selectImage:"\u9009\u62E9\u56FE\u50CF"},"zh-Hant":{delete:"\u522A\u9664",selectImage:"\u9078\u53D6\u5716\u50CF"}};var Od=to.forwardRef(({className:e,style:t,isInline:o=!0,accept:r="image/*",defaultImageSrc:a,imageSrc:i,imageAlt:n,pickerButtonLabel:l,isDisabled:s,onDrop:p,onPaste:d,includeCheckeredBackground:u=!0,"data-block-id":c,pickerButtonStyle:m,pickerButtonClassName:f,footerClassName:y,footerStyle:g,clearLabel:v,placeholder:b,labelStyle:h,labelClassName:z,...x},R)=>{let C=to.useRef(null),P=to.useRef(null),{formatMessage:k}=B(Ed),[T,I]=useControlledState(i,a||null,oe=>{invariant(typeof oe!="string"),x.onValueChange?.(oe?[oe]:[]);}),D=useMemo(()=>kh(T||void 0),[T]),{fieldProps:E,labelProps:w}=useField(x),{dropProps:S,isDropTarget:$}=useDrop({ref:C,onDrop:async oe=>{if(s)return;let ce=await Va({items:oe.items});ce.length&&I(ce[0]),p?.(oe);},...x}),{clipboardProps:re}=useClipboard({onPaste:async oe=>{if(s)return;let ce=await Va({items:oe});ce.length&&I(ce[0]),d?.(oe);},...x}),pe=()=>{I(null),P.current&&(P.current.value="");},X={type:"file",onChange:oe=>{let ce=[...oe.target.files];I(ce[0]),x.onChange?.(oe);},accept:r,disabled:s},{focusProps:K,isFocused:G,isFocusVisible:V}=useFocusRing({within:!0}),{hoverProps:Z,isHovered:ee}=useHover({isDisabled:s}),{imgProps:Ce,isLoading:Pe,isLoaded:ye}=bo({src:D,alt:n||""}),ke={label:l||k("selectImage"),onPress:()=>C.current?.click(),variant:"secondary",isDisabled:s,excludeFromTabOrder:!0,className:classNames(Gt({isFocusVisible:V}),{[_d]:$&&!s},f),style:m},Le=filterTruthyValues({"data-loaded":ye,"data-block-id":c,"data-hovered":ee,"data-focused":G,"data-drop-target":$,"data-disabled":s,"data-focus-visible":V});return jsxs(M,{...Le,className:classNames("BaselineUI-ImageDropZone",e),display:"flex",flexDirection:"column",alignItems:"center",style:t,ref:R,children:[jsxs("label",{...mergeProps(S,Z,K,w),className:classNames(Fr({isInline:o,isHovered:ee,isDisabled:s,hasLoadedImage:!!D&&ye,showFocusRing:$||!!D&&V}),z),style:h,ref:C,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(E,re,X),ref:P})}),!D&&jsx(O,{...ke}),!!D&&(Pe?jsx(Io,{}):jsx("img",{className:Hr({isInline:o,isDisabled:s,hasLoadedImage:!!D&&ye&&u}),...Ce}))]}),b||v?jsx("div",{style:g,className:classNames(Or({isInline:o,isDisabled:s}),y),children:(D||!b)&&v?jsx(O,{size:"sm",variant:"ghost",label:v,isDisabled:s,onPress:pe}):jsx(O,{size:"sm",variant:"ghost",label:b,isDisabled:!0})}):null]})});Od.displayName="ImageDropZone";function kh(e){return e instanceof File?URL.createObjectURL(e):e}var Vd="_1vm2oh49 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6fv",Di="_1vm2oh48 _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6jc _1yep5z6jd _1yep5z6je",Ad=_({defaultClassName:"_1vm2oh40 mnnh5s1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6l1 _1yep5z6kz _1yep5z6hk _1yep5z6l2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kx _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{accent:{theme:"_1vm2oh41",positive:"_1vm2oh42"},isInline:{true:"mnnh5s2 _1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6121 _1yep5z616i _1yep5z616k",false:"_1yep5z611g"},isFocusVisible:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 z9nup83 _1yep5z6yl"},isHovered:{true:"_1vm2oh47"}},defaultVariants:{},compoundVariants:[[{accent:"positive",isInline:!0},"_1yep5z61mp"],[{accent:"theme",isInline:!0},"_1yep5z61me"],[{accent:"positive",isInline:!1},"_1yep5z61mr"],[{accent:"theme",isInline:!1},"_1yep5z61mg"],[{isFocusVisible:!0,isInline:!0},"_1yep5z61ny _1yep5z61rl _1yep5z61rn _1yep5z61ro"],[{isHovered:!0,isInline:!0},"_1yep5z61ro _1yep5z61ny _1yep5z61rl _1yep5z61rn"],[{isHovered:!0,isInline:!1,accent:"positive"},"_1yep5z61mq"],[{isHovered:!0,isInline:!1,accent:"theme"},"_1yep5z61mi"],[{isHovered:!0,isInline:!0,accent:"theme"},"_1yep5z61mf"]]});var Ud=to.forwardRef(({className:e,style:t,isDisabled:o,isInline:r=!0,imageAlt:a,imageSrc:i,svgSrc:n,textValue:l,textStyle:s,onPress:p,onDelete:d,deleteAriaLabel:u,addAriaLabel:c,accent:m="positive","data-block-id":f,...y},g)=>{let{focusProps:v,isFocused:b,isFocusVisible:h}=useFocusRing({within:!0}),{isHovered:z,hoverProps:x}=useHover({isDisabled:o}),{pressProps:R}=usePress({isDisabled:o,onPress:p});invariant(i||n||l,"Preview must have content. You must provide either an `imageSrc`, `svgSrc`, or `textValue` prop.");let C=filterTruthyValues({"data-hovered":z,"data-focus-visible":h,"data-focused":b,"data-disabled":o});return jsxs("div",{...y,className:classNames(Ad({isInline:r,isFocusVisible:h,isDisabled:o,isHovered:z,accent:m}),"BaselineUI-Preview",e),"data-block-id":f,"aria-label":y["aria-label"]||a||l,style:t,ref:g,children:[typeof n=="string"?jsx("button",{disabled:o,...mergeProps(x,v,R,C),className:Di,"aria-label":c,dangerouslySetInnerHTML:{__html:n}}):jsxs("button",{...mergeProps(x,v,R,C),disabled:o,style:s,"aria-label":c,className:Di,children:[i?jsx("img",{src:i,alt:a,className:Hr({isInline:r,isDisabled:o})}):null,!!n&&typeof n=="object"&&n,l]}),d?jsx(L,{isDisabled:o,className:Vd,"aria-label":u,size:"xs",icon:TrashIcon,onPress:d}):null]})});Ud.displayName="Preview";var qd="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e",Kd=_({defaultClassName:"cw3m0n8 _1yep5z6ew _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Gd="cw3m0n7",Wd=_({defaultClassName:"cw3m0n0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),Xd="_1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ks",Yd=_({defaultClassName:"cw3m0n3 _16vugd05",variantClassNames:{isFocusVisible:{true:"_16vugd08"},isSelected:{true:"_16vugd07"},isDisabled:{true:"_16vugd0a"}},defaultVariants:{},compoundVariants:[]});var jh=({label:e,description:t},{isSelected:o,isFocusVisible:r,isDisabled:a,optionLabelPosition:i})=>jsxs("div",{className:Wd({labelPosition:i}),children:[jsx("div",{className:Yd({isSelected:o,isFocusVisible:r,isDisabled:a}),children:o?jsx("div",{className:Gd}):null}),e?jsxs("div",{className:qd,children:[jsx("span",{className:ur({isDisabled:a}),children:e}),t?jsx("span",{className:Kd({isDisabled:a}),children:t}):null]}):null]}),Zd=({state:e,renderOption:t=jh,item:o,optionLabelPosition:r="end",optionStyle:a,optionClassName:i,isReadOnly:n,...l})=>{let s=!!l.isDisabled||!!l.disabledValues?.includes(o.id),p=to.useRef(null),{inputProps:d,isPressed:u,isSelected:c}=useRadio({...l,isDisabled:s,children:o.label,value:o.id},e,p),{focusProps:m,isFocusVisible:f,isFocused:y}=useFocusRing(),{isHovered:g}=useHover({isDisabled:s}),v=filterTruthyValues({"data-selected":c,"data-focused":y,"data-focus-visible":f,"data-hovered":g,"data-disabled":s,"data-pressed":u,"data-read-only":n});return jsxs("label",{...v,style:a,className:classNames("BaselineUI-Radio-Item",i),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(d,m),ref:p})}),t(o,{isFocusVisible:f,isSelected:c,isFocused:y,isHovered:g,isDisabled:s,optionLabelPosition:r,isReadOnly:n})]})};var Ur=to.forwardRef(({className:e,style:t,optionsContainerClassName:o,optionsContainerStyle:r,items:a,labelPosition:i="top",renderOption:n,"aria-label":l,"aria-labelledby":s,"aria-describedby":p,"aria-details":d,"data-block-id":u,...c},m)=>{let f=useRadioGroupState(c),{radioGroupProps:y,labelProps:g,descriptionProps:v,errorMessageProps:b}=useRadioGroup({...c,"aria-label":l,"aria-labelledby":s,"aria-describedby":p,"aria-details":d},f),h=_e({...c,descriptionProps:v,errorMessageProps:b,labelPosition:i}),z=filterTruthyValues({"data-orientation":c.orientation,"data-block-id":u,"data-disabled":c.isDisabled,"data-readonly":c.isReadOnly});return jsxs("div",{...mergeProps(y,z),className:classNames(Be({labelPosition:i}),"BaselineUI-RadioGroup",e),style:t,ref:m,children:[c.label||h?jsxs("div",{className:De({labelPosition:i,hasMessage:!!h}),children:[jsx("span",{...g,className:classNames(Me,"BaselineUI-RadioGroup-Label"),children:c.label}),i==="start"&&h]}):null,jsxs("div",{className:classNames({[po]:c.isDisabled}),children:[jsx("div",{className:classNames(Xd,o),style:r,children:a.map(x=>jsx(Zd,{state:f,renderOption:n,item:x,...c,value:x.id},x.id))}),i==="top"&&h]})]})});Ur.displayName="RadioGroup";var Qd=({id:e,defaultMessage:t,elementType:o=Fragment$1})=>{invariant(e||t,"`id` or `defaultMessage` is required.");let r=B();return jsx(o,{children:r.formatMessage(e)||t})};Qd.displayName="MessageFormat";var Jd=to.forwardRef(({className:e,style:t,children:o,role:r="group",isDisabled:a,...i},n)=>{let{hoverProps:l,isHovered:s}=useHover({isDisabled:a});return jsx("div",{...l,role:r,"data-hovered":s,"data-disabled":a,className:e,style:t,...i,ref:n,children:o})});Jd.displayName="Group";var qr="_46ioju0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e",Kr="_1yep5z61ov _1yep5z61ow _1yep5z61ox _1yep5z61g1 _1yep5z61g2 _1yep5z61g3";var om=to.forwardRef(({items:e,optionsContainerClassName:t,...o},r)=>{let a=useMemo(()=>e.map(i=>({id:i.color,label:i.label})),[e]);return useEffect(()=>{console.warn("`ColorPresetInlineInput` is deprecated. Please use `ColorSwatchPicker` instead.");},[]),jsx(Ur,{items:a,optionsContainerClassName:classNames(Kr,t),orientation:"horizontal",renderOption:({label:i,id:n},{isSelected:l,isFocusVisible:s})=>jsx("div",{className:qr,children:jsx(he,{isFocusVisible:s,color:n,isSelected:l,"aria-label":i,isInteractive:!0})}),...o,className:classNames(o.className,"BaselineUI-ColorPresetInput"),ref:r})});om.displayName="ColorPresetInput";var Vi="UNSUPPORTED_IN_MENU";function am(e){return useMemo(()=>to.Children.toArray(e).map(t=>{let o=t,r=uniqueId("item"),a=zt(o,Xe),i=rm(o),n,l;if(a){let v=zt(a,Ye);invariant(v),n=rm(v),l=zt(a,Ue).props.children;}else i?n=i:n=o;let{onPress:s,label:p,"aria-label":d,iconStart:u,isDisabled:c,icon:m}=n.props,f=p||d||Vi;invariant(typeof f=="string","ActionGroup children must have a string label");let y=`${r}-${f}`;return createElement(Item,{...{key:y,onPress:s,textValue:f,"aria-label":d,icon:u||m,dialogContent:l,isDisabled:c},key:y},o)}),[e])}function zt(e,t){return t?flatMapDeep(to.Children.toArray(e),r=>to.isValidElement(r)&&r.props.children?[r,...to.Children.toArray(r.props.children)]:[r]).find(r=>to.isValidElement(r)&&r.type===t):void 0}function rm(e){return zt(e,O)||zt(e,L)}var im="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6kn",nm={horizontal:"xvr3wn0",vertical:"xvr3wn1"};var ji=to.forwardRef(({className:e,style:t,children:o,collapsibleMenuProps:r,"data-block-id":a,renderSpacer:i,...n},l)=>{let{formatMessage:s}=B(),[p,d]=useState(),u=am(o),c=useListState({...n,children:u}),m=Re(l),f=useRef(null),[{visibleItems:y,isMeasuring:g},v]=da({visibleItems:c.collection.size,isMeasuring:!1}),b=useCallback(()=>{let k=T=>{if(f.current&&m.current){let I=[...f.current.children],D=m.current.getBoundingClientRect().width,E=T<c.collection.size,w=0,S=0;if(E){let $=I.pop();$&&(w+=cm($,!1,!0));}for(let[$,re]of I.entries())if(w+=cm(re,$===0,$===I.length-1),Math.round(w)<=Math.round(D))S++;else break;return S}return T};v(function*(){yield {visibleItems:c.collection.size,isMeasuring:!0};let T=k(c.collection.size),I=T<c.collection.size&&T>0;yield {visibleItems:T,isMeasuring:I},I&&(yield {visibleItems:k(T),isMeasuring:!1});});},[v,m,c.collection.size]),h=useMemo(()=>({get current(){return m.current?.parentElement}}),[m]);ba({ref:h,onResize:b}),we(b,[c.collection,b]);let{toolbarProps:z}=useToolbar(n,m),x=[...c.collection],R=x.slice(0,y),C=x.slice(y).filter(k=>k.textValue!==Vi),P=C.length>0;return useEffect(()=>{d(void 0);},[C.length]),useEffect(()=>{n.orientation==="vertical"&&console.warn("Toolbar: Vertical orientation is not supported when `isCollapsible` is true.");},[n.orientation]),jsxs(FocusScope,{children:[jsx("div",{...z,className:e,"data-block-id":a,"data-collapse":!0,style:{...t,flexBasis:g?"100%":void 0},ref:m,children:jsxs("div",{ref:f,className:im,children:[R.map(k=>k.rendered),P?jsxs(Fragment,{children:[!g&&i?.(),jsx(lr,{placement:"bottom end",renderTrigger:({buttonProps:k,ref:T})=>jsx(L,{...k,size:"md",icon:MoreIcon,"aria-label":s(bx.more),variant:"toolbar",ref:T}),...r,disabledKeys:C.filter(k=>k.props?.isDisabled).map(k=>k.key),items:C.map(k=>{let T=k.textValue||k["aria-label"];return invariant(T,"ActionItem must have a label"),{id:k.key,label:T,icon:k.props.icon}}),onAction:k=>{let T=c.collection.getItem(k);invariant(T,"Item not found");let{onPress:I,dialogContent:D}=T.props;I?.(),d(D);}})]}):null]})}),jsx(ze,{isOpen:!!p,onOpenChange:k=>{k||d(void 0);},children:jsx(Te,{enableDrawer:"auto",style:{zIndex:1e5},children:p?to.cloneElement(p,{inheritDrawer:!0}):null})})]})});ji.displayName="CollapsibleToolbar";function cm(e,t,o){let a=Q(e).getComputedStyle(e);return e.getBoundingClientRect().width+(t?0:dm(a.marginLeft))+(o?0:dm(a.marginRight))}function dm(e){let t=Number.parseInt(e,10);return Number.isNaN(t)?0:t}var bx=j({more:{id:"more",defaultMessage:"More"}});var $i=to.forwardRef(({className:e,style:t,"data-block-id":o,"aria-controls":r,...a},i)=>{let n=to.useRef(null),{toolbarProps:l}=useToolbar(a,n);return jsx("div",{...l,"aria-controls":r,className:classNames(nm[a.orientation||"horizontal"],"BaselineUI-Toolbar",e),style:t,"data-block-id":o,ref:N(i,n),children:a.children})});$i.displayName="WrappedToolbar";var Gr=to.forwardRef((e,t)=>{let o=e.isCollapsible?ji:$i;return jsx(o,{...e,ref:t})});Gr.displayName="Toolbar";var um=_({defaultClassName:"_1j5skr71",variantClassNames:{size:{xxs:"_1j5skr72",xs:"_1j5skr73",sm:"_1j5skr74",md:"_1j5skr75",lg:"_1j5skr76"}},defaultVariants:{},compoundVariants:[]}),fm=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7g"},isFocusVisible:{true:"_1j5skr7h"},isDisabled:{true:"z9nup83 _1yep5z610d"},isSelected:{true:"_1j5skr7j"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61rl _1yep5z61o5 _1yep5z61lo"],[{isSelected:!1,isHovered:!0,isDisabled:!1},"_1yep5z6fu"],[{isSelected:!1,isFocusVisible:!0,isDisabled:!1},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0,isDisabled:!1},"_1j5skr7k _1yep5z61rm _1yep5z61rl _1yep5z61nz _1yep5z61lp"],[{isSelected:!0,isFocusVisible:!1,isDisabled:!1},"_1yep5z61rl _1yep5z61rn _1yep5z61ny _1yep5z61ro"]]}),ym=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7m"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1yep5z610c"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61ln"]]}),bm=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7r"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1j5skr7t"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!0,isDisabled:!1},"_1yep5z61mg _1yep5z61lq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61mg _1yep5z61lo"]]}),gm=_({defaultClassName:"_1j5skr77 _1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr78"},isFocusVisible:{true:"_1j5skr79"},isSelected:{true:"_1j5skr7a"},isDisabled:{true:"_1j5skr7b z9nup83 _1yep5z610e"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1},"_1j5skr7c _1yep5z61lp"],[{isSelected:!1,isDisabled:!0},"_1j5skr7d _1yep5z61lo"],[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!1,isFocusVisible:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0},"_1j5skr7e _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]});var Sx={xxs:8,xs:12,sm:16,md:20,lg:24},ve=to.forwardRef(({className:e,style:t,icon:o,size:r="md",variant:a="primary","data-block-id":i,...n},l)=>{let s=useToggleState(n),{buttonProps:p,isPressed:d,ref:u}=Kt(n,s),{hoverProps:c,isHovered:m}=useHover({isDisabled:n.isDisabled}),{isFocusVisible:f,isFocused:y,focusProps:g}=useFocusRing(),v=useMemo(()=>typeof o=="function"?o:s.isSelected?o.selected:o.unselected,[o,s.isSelected]),b={isSelected:s.isSelected,isHovered:m,isFocusVisible:f,isDisabled:!!n.isDisabled},h=filterTruthyValues({"data-hovered":m,"data-selected":s.isSelected,"data-focus-visible":f,"data-disabled":n.isDisabled,"data-block-id":i,"data-focused":y,"data-pressed":d});return jsx("button",{...mergeProps(p,c,g,h),className:classNames(a==="toolbar"&&gm(b),a==="primary"&&fm(b),a==="secondary"&&ym(b),a==="tertiary"&&bm(b),um({size:r}),"BaselineUI-ToggleIconButton",e),style:t,ref:N(u,l),children:jsx(v,{size:Sx[r]})})});ve.displayName="ToggleIconButton";var _m="f6jv6bm",zm="_1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z6j0 _1yep5z6j1 _1yep5z6j2",Fo="_1yep5z689 _1yep5z68a _1yep5z68b _1yep5z65x _1yep5z65y _1yep5z65z",hm=_({defaultClassName:"f6jv6b0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6fs",variantClassNames:{isInline:{true:"f6jv6b1"},isMinimal:{true:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6uw _1yep5z6ux _1yep5z6uy _1yep5z6142 _1yep5z6143 _1yep5z6144",false:"_1yep5z613n _1yep5z613o _1yep5z613p"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isMinimal:!1},"_1yep5z61h7 _1yep5z61h8 _1yep5z61h9 _1yep5z61hv _1yep5z61hw _1yep5z61hx _1yep5z61ij _1yep5z61ik _1yep5z61il _1yep5z61j7 _1yep5z61j8 _1yep5z61j9 _1yep5z61rv _1yep5z61rt _1yep5z61nc"]]}),Wr=_({defaultClassName:"f6jv6b4 _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6e3 _1yep5z6eu _1yep5z6ky",variantClassNames:{isDisabled:{true:"f6jv6b5 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),xm="f6jv6bj _1yep5z6vz _1yep5z6w0 _1yep5z6w1 _1yep5z6wn _1yep5z6wo _1yep5z6wp _1yep5z6xb _1yep5z6xc _1yep5z6xd _1yep5z6xz _1yep5z6y0 _1yep5z6y1",Cm="f6jv6bk";var Pm="f6jv6bn _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6l6 _1yep5z6l1 _1yep5z6kz _1yep5z6hc _1yep5z6eu",km=_({defaultClassName:"f6jv6bf _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6kx",variantClassNames:{isHovered:{true:"_1yep5z6115"},isDisabled:{true:"_1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),wm="f6jv6bi _1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs _1yep5z6l0 _1yep5z6kz _1yep5z6hf _1yep5z6l3",Rm="_1yep5z6j6 _1yep5z6j7 _1yep5z6j8",Im="f6jv6be f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu _1yep5z6e3 _1yep5z6kv",Tm=_({defaultClassName:"f6jv6bb _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jc _1yep5z6jd _1yep5z6je",variantClassNames:{isInline:{true:"_1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z616k _1yep5z616i _1yep5z6121",false:"_1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg"}},defaultVariants:{},compoundVariants:[]}),Nm="f6jv6bl",Sm="f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu",Xr=_({defaultClassName:"f6jv6b6",variantClassNames:{isInline:{true:"f6jv6b7",false:"f6jv6b8"}},defaultVariants:{},compoundVariants:[]}),Yr="f6jv6b9 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it",xt="f6jv6bo";var Mm=[["Toolbar Focus","Alt+F10"],["Bold","Ctrl+B"],["Italic","Ctrl+I"],["Underline","Ctrl+U"],["Select All","Ctrl+A"],["Cut","Ctrl+X"],["Copy","Ctrl+C"],["Paste","Ctrl+V"],["Undo","Ctrl+Z"],["Redo","Ctrl+Shift+Z"],["Submit","Ctrl+Enter"],["Open Help Dialog","Ctrl+Shift+H"]],{dialog:{row:Ct}}=layoutSprinkleValues,Dm=({isOpen:e,onClose:t})=>{let{formatMessage:o}=B(),r=useId();return jsx(ze,{isOpen:e,onOpenChange:a=>{a||t();},children:jsx(Te,{enableDrawer:"auto",style:{zIndex:999999},children:jsxs(me,{"aria-labelledby":r,className:xm,drawerBackground:"subtle",children:[jsxs(M,{paddingLeft:Ct.padding.horizontal.lg,paddingRight:Ct.padding.horizontal.sm,display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",backgroundColor:"background.primary.subtle",className:Cm,children:[jsx(W,{id:r,elementType:"h3",type:"title",size:"md",children:o(Pt.help)}),jsx(L,{icon:XIcon$1,size:"md",variant:"secondary","aria-label":o(Pt.close),onPress:t})]}),jsx(F,{className:Nm}),jsxs(M,{paddingX:Ct.padding.horizontal.lg,role:"table","aria-labelledby":r,backgroundColor:"background.primary.subtle",children:[jsx("div",{role:"rowgroup",children:jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Ct.padding.vertical.md,color:"text.primary",children:[jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",children:o(Pt.action)}),jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",style:{textTransform:"capitalize"},children:o(Pt.shortcut)})]})}),jsx("div",{role:"rowgroup",children:Mm.map(([a,i],n)=>jsxs(Fragment$1,{children:[jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Ct.padding.vertical.xs,style:{minHeight:40},children:[jsx(W,{type:"subtitle",size:"sm",role:"cell",children:o(Pt[camelCase(a)])}),jsx(W,{elementType:"kbd",type:"subtitle",size:"sm",role:"cell",children:getOsSpecificKeyboardShortcutLabel(i,!0)})]}),n!==Mm.length-1&&jsx(F,{})]},a))})]})]})})})},Pt=j({toolbarFocus:{id:"toolbarFocus",defaultMessage:"Toolbar Focus"},help:{id:"help",defaultMessage:"Help"},close:{id:"close",defaultMessage:"Close"},action:{id:"action",defaultMessage:"Action"},shortcut:{id:"shortcut",defaultMessage:"Shortcut"},bold:{id:"bold",defaultMessage:"Bold"},italic:{id:"italic",defaultMessage:"Italic"},underline:{id:"underline",defaultMessage:"Underline"},selectAll:{id:"selectAll",defaultMessage:"Select All"},cut:{id:"cut",defaultMessage:"Cut"},copy:{id:"copy",defaultMessage:"Copy"},paste:{id:"paste",defaultMessage:"Paste"},undo:{id:"undo",defaultMessage:"Undo"},redo:{id:"redo",defaultMessage:"Redo"},openHelpDialog:{id:"openHelpDialog",defaultMessage:"Open Help Dialog"},submit:{id:"submit",defaultMessage:"Submit"}});var Zr=to.forwardRef(({value:e,defaultValue:t,onChange:o,placeholder:r,spellCheck:a,textBoxRef:i,isInline:n,isMinimal:l,isDisabled:s,editableContentAriaLabel:p,editorHandle:d,autoFocus:u,saveOnEnter:c,onSave:m},f)=>{let y=to.useRef(null),[g,v]=useControlledState(e,t||"",o),b=useCallback(I=>{v(I.currentTarget.value||"");},[v]),h=useCallback(I=>{(c&&I.key==="Enter"&&!I.shiftKey||(I.ctrlKey||I.metaKey)&&I.key==="Enter")&&(I.preventDefault(),m());},[c,m]);useImperativeHandle(f,()=>({clear:()=>{v("");}}));let z=useCallback(I=>{I.currentTarget.style.height="16px",I.currentTarget.style.height=I.currentTarget.scrollHeight+"px";},[]);useGranularLayoutEffect(()=>{let I=y.current;I&&(I.style.height="16px",I.style.height=I.scrollHeight+"px");},[l],[g]),useImperativeHandle(d,()=>({setCaretPosition:I=>{y.current&&(y.current.focus(),y.current.setSelectionRange(I,I));}}));let{focusProps:x,isFocused:R,isFocusVisible:C}=useFocusRing(),{hoverProps:P,isHovered:k}=useHover({}),T=filterTruthyValues({"data-focus-visible":C,"data-hovered":k,"data-focused":R});return jsx("textarea",{...mergeProps(x,P,T),ref:N(y,i),className:classNames(l?Im:[Wr(),Xr({isInline:n}),Sm]),autoFocus:u,onChange:b,disabled:s,onInput:z,value:g,placeholder:r,spellCheck:a,"aria-label":p,onKeyDown:h})});Zr.displayName="PlainEditor";var Rt="mention",Qr="mention_input",Km=to.forwardRef(({onCancel:e,editor:t,element:o,onSelectionChange:r},a)=>{let{containerRef:i,items:n,maxMentionableUsersSuggestions:l}=useContext(ea),s=useSelected(),[p,d]=useState(""),{contains:u}=useFilter({sensitivity:"base"}),{formatMessage:c}=B(),m=useMemo(()=>{let w=n.filter(S=>p===""||u(S.displayName,p)).map(S=>({id:S.id,label:S.displayName,data:S}));return l?take(w,l):w},[n,l,p,u]),f=useCallback(w=>jsx(Item,{children:w.label},w.id),[]),y=useCallback((w=!1)=>{let S=findNodePath(t,o);S&&(removeNodes(t,{at:S}),w&&focusEditor(t));},[t,o]),g=useComboBoxState({items:m,children:f,menuTrigger:"focus",onSelectionChange:w=>{y(!0),r?.(w);}}),v=to.useRef(null),b=to.useRef(null),h=to.useRef(null),z=to.useRef(null),x=useHTMLInputCursorState(b);useInteractOutside({ref:z,onInteractOutside:()=>{g.close();}});let{inputProps:R,listBoxProps:C}=useComboBox({defaultItems:m,inputRef:b,buttonRef:v,listBoxRef:h,popoverRef:z,menuTrigger:"focus","aria-label":c(mC.mention)},g);useEffect(()=>{b.current?.focus();},[]);let P=useCallback((w="manual",S=!1)=>{y(S),e?.(w,g.inputValue);},[e,y,g.inputValue]),k=useRef(s);useEffect(()=>{k.current&&!s&&P("deselect"),k.current=s;},[s,P]);let T=x?.atStart??!1,I=x?.atEnd??!1,D=useCallback(w=>{w.key==="Backspace"&&T?P("backspace",!0):w.key==="Escape"?P("escape",!0):w.key==="ArrowLeft"&&T?P("arrowLeft",!0):w.key==="ArrowRight"&&I&&P("arrowRight",!0);let S=Hotkeys.isUndo(w)&&t.history.undos.length>0,$=Hotkeys.isRedo(w)&&t.history.redos.length>0;(S||$)&&(w.preventDefault(),t[S?"undo":"redo"](),focusEditor(t));},[T,I,P,t]),E=useMemo(()=>{if(!CSS.supports("field-sizing","content")){let w=Q(b.current),S=b.current?w?.getComputedStyle(b.current).font:void 0;return {width:S?getTextDimensions({text:g.inputValue,font:S}).width+10:"4ch"}}},[g.inputValue]);return jsxs(We.Provider,{value:g,children:[jsx("input",{...mergeProps(R,{onKeyDown:D,onBlur:()=>{P("blur",!0);},onChange:w=>{d(w.target.value);}}),style:E,className:Pm,ref:N(a,b)}),g.isOpen?jsx(le,{triggerRef:i,className:wm,isNonModal:!0,ref:z,state:g,children:jsx(te,{...C,items:void 0,autoFocus:"first",ref:h,className:sprinkles({width:"full"}),renderOption:Wm})}):null]})});Km.displayName="MentionInputContentElement";var Wi=withRef(({className:e,...t},o)=>{let{children:r,editor:a,element:i}=t,{items:n}=useContext(ea),l=useRef(null),[s,p]=useState(null);useEffect(()=>{let c=findNodePath(a,i);if(!c)return;let m=getPointBefore(a,c);if(!m)return;let f=createPointRef(a,m);return p(f),()=>{f.unref();}},[a,i]);let d=useCallback(()=>{let c=l.current?.getRootNode()instanceof ShadowRoot;moveSelection(a,{unit:"offset"}),moveSelection(a,{unit:"character",distance:1}),Ko()&&c&&focusEditor(a);},[a]),u=useCallback(c=>{if(!c)return;let m=l.current?.getRootNode()instanceof ShadowRoot,f=n.find(g=>g.id===c);invariant(f,"User not found");let y={type:Rt,value:f.id,displayName:f.displayName,children:[{text:""}]};insertNodes(a,[y,{text:" "}]),m?setTimeout(()=>{d();},0):d();},[a,n,d]);return jsxs(PlateElement,{as:"span","data-slate-value":i.value,contentEditable:!1,className:e,ref:o,...t,children:[jsx(Km,{onCancel:(c,m)=>{c!=="backspace"&&insertText(a,"@"+m,{at:s?.current??void 0}),(c==="arrowLeft"||c==="arrowRight")&&moveSelection(a,{distance:1,reverse:c==="arrowLeft"});},onSelectionChange:u,ref:l,element:i,editor:a}),r]})});Wi.displayName="MentionInputElement";var Xi=withRef(({className:e,onClick:t,children:o,...r},a)=>{let i=useElement();return jsxs(PlateElement,{as:"span",className:e,contentEditable:!1,"data-user-id":i.value,onClick:getHandler(t,i),ref:a,...r,children:["@",i.displayName,o]})});Xi.displayName="MentionElement";var Gm=(e,{options:{trigger:t,triggerPreviousCharPattern:o,triggerQuery:r}})=>{let{insertText:a}=e,i=n=>n===t;return e.insertText=n=>{if(!e.selection||!i(n)||r&&!r(e)){a(n);return}let l=getEditorString(e,getRange(e,e.selection,getPointBefore(e,e.selection)));if(o?.test(l)){Jr(e);return}a(n);},e},mC=j({mention:{defaultMessage:"Mention",id:"mention"}});function Ym({className:e,children:t,...o}){return jsx(PlateElement,{asChild:!0,className:e,...o,children:jsx("p",{children:t})})}function IC(e){return Object.entries(e).map(([t,o])=>`${kebabCase(t)}:${o}`).filter(([,t])=>!!t).join(";")}function TC(e){return "text"in e}function It(e){if(!e)return "";function t(o){if(TC(o)){let a=o.text;return o.bold&&(a=`<b>${a}</b>`),o.italic&&(a=`<i>${a}</i>`),o.underline&&(a=`<u>${a}</u>`),(o.color||o.backgroundColor)&&(a=`<span style="${IC(filterTruthyValues({color:o.color||void 0,backgroundColor:o.backgroundColor||void 0}))}">${a}</span>`),a}let r=o.children?.map(It).join("");switch(o.type){case ELEMENT_PARAGRAPH:return `<p>${r}</p>`;case ELEMENT_LINK:return `<a href="${o.url}">${r}</a>`;case Rt:return `<span data-user-id="${o.value}">${o.displayName}</span>`;default:return r}}return Array.isArray(e)?e.map(o=>t(o)).join(""):t(e)}function NC(e){return e?(e=e.trim(),e.endsWith(";")&&(e=e.slice(0,-1)),Object.fromEntries(e.split(";").map(t=>t.split(":").map(o=>o.trim())).map(([t,o])=>[camelCase(t),o]))):{}}function en(e){e.startsWith("<p>")||(e=`<p>${e}</p>`);let t=new DOMParser().parseFromString(Zm.default.sanitize(e),"text/html"),o=t.querySelectorAll("[style]");for(let a of o)a.style.textDecoration==="underline"&&(a.style.textDecoration="",a.style.cssText||a.removeAttribute("style"),a.hasAttributes()?a.innerHTML=`<u>${a.innerHTML}</u>`:a.outerHTML=`<u>${a.innerHTML}</u>`);let r=t.querySelectorAll("br");for(let a of r)a.outerHTML=a.closest("p")?`
53
- `:"<p>";return Jm(t.body)}function Jm(e,t){if(e.nodeType===Node.TEXT_NODE)return jsx$1("text",t,e.textContent);if(e.nodeType!==Node.ELEMENT_NODE)return null;let o={...t};switch(e.nodeName.toUpperCase()){case"B":{o.bold=!0;break}case"I":{o.italic=!0;break}case"EM":{o.italic=!0;break}case"U":{o.underline=!0;break}case"SPAN":{let a=NC(e.getAttribute("style")||"");a["text-decoration"]==="underline"&&(o.underline=!0),a.color&&(o.color=a.color),a.backgroundColor&&(o.backgroundColor=a.backgroundColor);break}}let r=[...e.childNodes].flatMap(a=>Jm(a,o));switch(r.length===0&&r.push(jsx$1("text",o,"")),e.nodeName.toUpperCase()){case"BR":return jsx$1("text",t,`
54
- `);case"SPAN":{let a=e.dataset.userId;return a?jsx$1("element",{type:Rt,value:a,displayName:e.textContent},{text:""}):r}case"P":return jsx$1("element",{type:ELEMENT_PARAGRAPH},r);case"A":return jsx$1("element",{type:ELEMENT_LINK,url:e.getAttribute("href")},r);default:return r}}function eu(e){let t=findNode(e,{match:{type:getPluginType(e,ELEMENT_LINK)}}),[o]=t||[{url:""}];return o?.url}function Jr(e){let t={children:[{text:" "}],type:Qr};e.insertNode(t);}var SC=createPluginFactory({isElement:!0,isInline:!0,isMarkableVoid:!0,isVoid:!0,key:Rt,options:{trigger:"@",triggerPreviousCharPattern:/^$|^[\s"']$/},plugins:[{isElement:!0,isInline:!0,isVoid:!0,key:Qr}],withOverrides:Gm}),ou=createPlugins([createParagraphPlugin({component:Ym}),createBoldPlugin({component:withProps(PlateLeaf,{as:"b"})}),createItalicPlugin({component:withProps(PlateLeaf,{as:"i"})}),createUnderlinePlugin({component:withProps(PlateLeaf,{as:"u"})}),createFontColorPlugin(),createFontBackgroundColorPlugin(),createLinkPlugin({component:tu}),SC({component:Xi})],{components:{[Qr]:Wi}});var nu=({isDisabled:e})=>{let{formatMessage:t}=B(),o=useEditorRef();return jsx(Xe,{type:"dialog",children:({close:r})=>jsxs(Fragment,{children:[jsx(Ye,{children:jsx(L,{icon:LinkIcon,size:"sm",isDisabled:e,"aria-label":t(ro.addLink),className:Fo,preventFocusOnPress:!0})}),jsx(Ue,{className:sprinkles({boxShadow:"medium"}),placement:"top end",children:jsx(me,{size:"content",style:{minWidth:240},children:jsx(OC,{close:()=>{r(),setTimeout(()=>{focusEditor(o,o.selection);},0);}})})})]})})},OC=({close:e})=>{let t=useEditorRef(),{formatMessage:o}=B(),r=useEditorSelector(p=>eu(p),[]),[a,i]=to.useState(r?"show":"add"),[n,l]=to.useState(r||""),s=jsx(M,{padding:"lg",children:jsx(ko,{label:o(ro.link),value:n,autoFocus:!0,onChange:l,placeholder:"https://yourdomain.com"})});return jsxs(Fragment,{children:[a==="add"&&jsxs(Fragment,{children:[s,jsx(M,{display:"flex",justifyContent:"flex-end",padding:"lg",className:_m,children:jsx(O,{isDisabled:!isUrl(n,!0),label:o(ro.addLink),size:"sm",onPress:()=>{upsertLink(t,{url:n,skipValidation:!0}),e?.();},preventFocusOnPress:!0})})]}),a==="show"&&jsxs(Fragment,{children:[jsx(M,{padding:"lg",children:jsx(W,{type:"subtitle",size:"sm",children:r})}),jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(O,{label:o(ro.editLink),size:"sm",variant:"secondary",onPress:()=>{i("edit");},style:{flex:1,justifyContent:"center"}}),jsx(O,{label:o(ro.removeLink),size:"sm",onPress:()=>{unwrapLink(t),e?.();},preventFocusOnPress:!0,style:{flex:1,justifyContent:"center"}})]})]}),a==="edit"&&jsxs(Fragment,{children:[s,jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(O,{label:o(ro.cancel),size:"sm",variant:"secondary",onPress:()=>{i("show"),e?.();}}),jsx(O,{label:o(ro.save),size:"sm",onPress:()=>{upsertLink(t,{url:n,skipValidation:!0}),e?.();}})]})]})]})};function tu({className:e,children:t,...o}){return jsx(PlateElement,{asChild:!0,className:e,...o,children:jsx("a",{className:pr({size:"sm"}),children:t})})}var ro=j({addLink:{id:"addLink",defaultMessage:"Add Link",description:"Add Link"},editLink:{id:"editLink",defaultMessage:"Edit Link",description:"Edit Link"},removeLink:{id:"removeLink",defaultMessage:"Remove Link",description:"Remove Link"},cancel:{id:"cancel",defaultMessage:"Cancel",description:"Cancel"},save:{id:"save",defaultMessage:"Save",description:"Save"},link:{id:"linkAnnotation",defaultMessage:"Link",description:"Link"}});var AC=parseColor("#ffffff00").toString("hexa"),on=[{label:"Red",color:"#ff0000"},{label:"Green",color:"#00ff00"},{label:"Blue",color:"#0000ff"},{label:"Yellow",color:"#ffff00"},{label:"Cyan",color:"#00ffff"},{label:"Magenta",color:"#ff00ff"},{label:"Black",color:"#000000"},{label:"White",color:"#ffffff"},{label:"Gray",color:"#808080"},{label:"Orange",color:"#ffa500"},{label:"Brown",color:"#a52a2a"},{label:"Purple",color:"#800080"}];[...on,{label:"Transparent",color:AC}];var oa=({nodeType:e,icon:t,ariaLabel:o,isDisabled:r})=>{let a=useEditorSelector(n=>isMarkActive(n,e),[]),i=useEditorRef();return jsx(ve,{variant:"tertiary",isSelected:a,size:"sm",icon:t,"aria-label":o,isDisabled:r,onPress:()=>{toggleMark(i,{key:e});},preventFocusOnPress:!0})},rn=({nodeType:e,"aria-label":t,isDisabled:o})=>{let{updateColor:r,clearColor:a,color:i}=useColorDropdownMenuState({customColors:[],colors:[],nodeType:e}),n=useCallback(({ref:s,triggerProps:p})=>jsx(L,{icon:e==="color"?TextIcon$1:HighlightTextIcon,"aria-label":t,size:"md",variant:"popover",isDisabled:o,className:Fo,preventFocusOnPress:!0,...p,ref:s}),[e,t,o]),l=useCallback(s=>{s?r(s.toString("rgba")):a();},[a,r]);return jsx(Bo,{presets:on,allowRemoval:!0,pickerMode:"lazy",placement:"top end",colorLabel:!1,renderTriggerButton:n,value:i||"#000000",onChange:l,isDisabled:o})};var gP=[{type:ELEMENT_PARAGRAPH,children:[{text:""}]}],ea=to.createContext({items:[],containerRef:{current:null},maxMentionableUsersSuggestions:10}),nn=to.forwardRef(({value:e,defaultValue:t,onChange:o,style:r,spellCheck:a,placeholder:i,isInline:n,isDisabled:l,editableContentAriaLabel:s,containerRef:p,onHelpDialogOpenRequest:d,mentionableUsers:u,editorHandle:c,maxMentionableUsersSuggestions:m,autoFocus:f,editorRef:y,saveOnEnter:g,onSave:v},b)=>{let h=useRef(null),z=useId(),{formatMessage:x}=B(),R=useRef(null),C=R.current,P=useRef(null),k=useMemo(()=>C?.getRootNode()instanceof ShadowRoot,[C]),[T,I]=useControlledState(e?en(e):void 0,en(t||"<p></p>"),w=>{o&&o(It(w));}),{keyboardProps:D}=useKeyboard({onKeyDown:w=>{(g&&w.key==="Enter"&&!w.shiftKey||(w.ctrlKey||w.metaKey)&&w.key==="Enter")&&(w.preventDefault(),v()),w.altKey&&w.key==="F10"?(w.preventDefault(),h.current&&h.current.querySelector("button")?.focus()):w.continuePropagation(),Ko()&&k&&P.current&&focusEditor(P.current);}});useEffect(()=>{l&&P.current&&deselect(P.current);},[l]),useImperativeHandle(b,()=>({startMention:()=>{P.current&&!R.current?.querySelector("input[role='combobox']")&&Jr(P.current);}})),useImperativeHandle(c,()=>({setCaretPosition:w=>{P.current&&(focusEditor(P.current),moveSelection(P.current,{distance:w,unit:"character"}));}}));let E=useMemo(()=>({items:u||[],containerRef:p,maxMentionableUsersSuggestions:m}),[u,p,m]);return jsx(ea.Provider,{value:E,children:jsxs(Plate,{initialValue:T||gP,plugins:ou,editorRef:N(P,y||null),onChange:w=>{I(w);},children:[jsxs(Gr,{className:Yr,"aria-controls":z,ref:h,children:[jsxs(M,{display:"flex",flexDirection:"row",role:"group",gap:"xs",paddingX:"sm",children:[jsx(oa,{nodeType:MARK_BOLD,icon:BoldIcon,ariaLabel:x(Ao.bold),isDisabled:l}),jsx(oa,{nodeType:MARK_ITALIC,icon:ItalicIcon,ariaLabel:x(Ao.italic),isDisabled:l}),jsx(oa,{nodeType:MARK_UNDERLINE,icon:UnderlineIcon,ariaLabel:x(Ao.underline),isDisabled:l})]}),jsx(F,{orientation:"vertical",className:xt}),jsx(rn,{nodeType:MARK_COLOR,"aria-label":x(Ao.fontColor),isDisabled:l}),jsx(F,{orientation:"vertical",className:xt}),jsx(rn,{nodeType:MARK_BG_COLOR,"aria-label":x(Ao.backgroundColor),isDisabled:l}),jsx(F,{orientation:"vertical",className:xt}),jsx(nu,{isDisabled:l}),jsx(F,{orientation:"vertical",className:xt}),jsx(L,{className:Fo,icon:QuestionmarkCircleIcon,size:"sm","aria-label":x(Ao.help),onPress:d})]}),jsx(F,{variant:"secondary"}),jsx("div",{...D,ref:R,children:jsx(PlateContent,{id:z,disabled:l,readOnly:l,style:r,placeholder:i,autoFocus:f,spellCheck:a,"aria-label":s,className:classNames(Wr({isDisabled:l}),Xr({isInline:n})),renderPlaceholder:({attributes:w,children:S})=>jsx("span",{...w,className:sprinkles({paddingY:"lg"}),children:S})})})]})})});nn.displayName="RichEditor";var Wm=({key:e,value:t},{isDisabled:o,optionProps:r,isFocused:a,_state:i},n)=>{let{hoverProps:l}=useHover({isDisabled:o}),{label:s,data:p}=t;return jsxs(Fragment,{children:[jsxs("li",{...mergeProps(r,l),className:km({isDisabled:o,isHovered:a}),"data-active":a,ref:n,children:[jsx(So,{name:s,...p?.avatar}),jsxs(M,{display:"flex",flexDirection:"column",children:[jsx(W,{type:"subtitle",size:"sm",children:s}),jsx(W,{type:"helper",size:"sm",children:p?.description})]})]}),e===i.collection.getLastKey()?null:jsx(F,{})]})},Ao=j({bold:{defaultMessage:"Bold",id:"bold"},italic:{defaultMessage:"Italic",id:"italic"},underline:{defaultMessage:"Underline",id:"underline"},backgroundColor:{defaultMessage:"Background color",id:"backgroundColor"},fontColor:{defaultMessage:"Font color",id:"fontColor"},help:{defaultMessage:"Help",id:"help"}});var uu=to.memo(to.forwardRef(({className:e,style:t,"data-block-id":o,enableRichText:r=!1,onCancel:a,onSave:i,isInline:n=!0,submitButtonIcon:l=ArrowUpCircleFilledIcon,submitButtonAriaLabel:s,cancelButtonAriaLabel:p,"aria-label":d,"aria-describedby":u,"aria-labelledby":c,"aria-details":m,editableContentAriaLabel:f="Editing Area",footerButtons:y,clearOnCancel:g,clearOnSave:v,...b},h)=>{let z=useRef(null),{formatMessage:x}=B(),R=useRef(null),C=useRef(null),P=useRef(null),k=!r&&b.variant==="minimal",T=useRef(null),[I,D]=to.useState(b.value||b.defaultValue),E=b.isDisabled||b.isSaveDisabled||!getPlainText(I||""),{fieldProps:w}=useLabel({"aria-label":d,"aria-labelledby":c,"aria-describedby":u,"aria-details":m,labelElementType:"div"});k&&!b.avatarName&&console.warn("Editor: When using the minimal `variant` and `enableRichText` is `false`, you should provide an `avatarName`.");let S=useCallback(()=>{D(""),r?z.current?.reset():C.current?.clear();},[r]),$=useCallback(()=>{E||(i?.(r?It(z.current?.children):R.current.value),v&&S());},[S,v,r,i,E]),re=jsx(L,{variant:"ghost","aria-label":s||x(ln.save),icon:l,isDisabled:E,size:"md",excludeFromTabOrder:k,className:k?Rm:void 0,onPress:$,preventFocusOnPress:!0}),[pe,X]=to.useState(!1),{keyboardProps:K}=useKeyboard({onKeyDown:V=>{(V.metaKey||V.ctrlKey)&&V.shiftKey&&V.key==="h"&&(V.preventDefault(),X(!0));}}),G=useCallback(V=>{D(V),b.onChange?.(V);},[b]);return jsxs("div",{...mergeProps(w,r?K:{}),role:"application",ref:N(P,h),style:t,"data-block-id":o,className:classNames(hm({isInline:n,isMinimal:k}),"BaselineUI-Editor",e),"aria-disabled":b.isDisabled,children:[k?jsxs(Fragment,{children:[n?jsx(So,{className:zm,name:b.avatarName||""}):null,jsxs("div",{className:Tm({isInline:n}),children:[jsx(Zr,{isMinimal:k,textBoxRef:R,isInline:n,editableContentAriaLabel:f,...b,onChange:G,onSave:$}),re]})]}):jsxs(Fragment,{children:[r?jsx(nn,{containerRef:P,ref:T,editorRef:z,isInline:n,editableContentAriaLabel:f,onHelpDialogOpenRequest:()=>{X(!0);},...b,onChange:G,onSave:$}):jsxs(Fragment,{children:[!n&&jsx(F,{variant:"secondary"}),jsx(Zr,{onCancel:a,textBoxRef:R,ref:C,isInline:n,editableContentAriaLabel:f,...b,onChange:V=>{D(V),b.onChange?.(V);},onSave:$})]}),jsx(F,{variant:"secondary"}),jsxs("div",{className:classNames(Yr,sprinkles({justifyContent:"space-between"})),children:[jsxs(M,{paddingX:"sm",gap:"sm",display:"flex",children:[r&&b.mentionableUsers?jsx(L,{icon:AtIcon,size:"sm","aria-label":x(ln.mention),onPress:()=>T.current?.startMention(),preventFocusOnPress:!0}):null,y?.map(({type:V,props:Z},ee)=>V==="action"?jsx(L,{...Z,size:"sm",isDisabled:b.isDisabled||Z.isDisabled},ee):jsx(ve,{...Z,size:"sm",variant:"tertiary",isDisabled:b.isDisabled||Z.isDisabled},ee))]}),jsxs(M,{children:[!!a&&jsx(L,{variant:"secondary",icon:CrossCircleFilledIcon,isDisabled:b.isDisabled,size:"md",onPress:()=>{a(),g&&S();},"aria-label":p||x(ln.cancel)}),re]})]})]}),jsx(Dm,{isOpen:pe,onClose:()=>{X(!1);}})]})}));uu.displayName="Editor";var ln=j({cancel:{defaultMessage:"Cancel",id:"cancel"},save:{defaultMessage:"Save",id:"save"},mention:{defaultMessage:"Mention",id:"mention"}});var ra=to.forwardRef(({className:e,style:t,"data-block-id":o,isMounted:r,children:a,transitions:i,elementType:n="div",...l},s)=>{let p=useTransition(r,i),d=animated[n];return p((u,c)=>c&&jsx(d,{className:e,"data-block-id":o,style:{...t,...u},...l,ref:s,children:a}))});ra.displayName="Transition";var fu="_8kqf970 _1yep5z6ow _1yep5z6ox _1yep5z6oy _1yep5z613b _1yep5z613c _1yep5z613d _1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6142 _1yep5z6143 _1yep5z6144 _1yep5z6yh _1yep5z6uq _1yep5z6ur _1yep5z6us _1yep5z6168";var bu=2,gu=to.forwardRef(({className:e,style:t,hideForKeyboard:o,scrollRef:r,label:a,delay:i=1500,smoothScroll:n=!0,"data-block-id":l},s)=>{let p=to.useRef(null),d=useInteractionModality(),[u,c]=to.useState(!1),m=useCallback(()=>{let k=r?.current||ge(p.current).body;return Q(k).getComputedStyle(k).flexDirection==="column-reverse"?k.scrollTop+bu>=0:k.scrollTop+k.clientHeight+bu>=k.scrollHeight},[r]),[f,y]=to.useState(m),g=Fe(),{buttonProps:v,isPressed:b}=useButton({onPress:()=>{let k=r?.current||ge(p.current).body;k.scrollTo({top:k.scrollHeight,behavior:n?"smooth":"auto"});}},p),{focusProps:h,isFocused:z,isFocusVisible:x}=useFocusRing(),{hoverProps:R,isHovered:C}=useHover({}),P=filterTruthyValues({"data-block-id":l,"data-pressed":b,"data-focus-visible":x,"data-hovered":C,"data-focused":z});return useEffect(()=>{y(m());},[m]),useEffect(()=>{let k=r?.current||ge(p.current).body,T="onscrollend"in Q(k),I=()=>{setTimeout(()=>{c(!1),y(m());},i);},D=()=>{c(!0),T||I();};return k.addEventListener("scroll",D),k.addEventListener("scrollend",I),()=>{k.removeEventListener("scroll",D),k.removeEventListener("scrollend",I);}},[r,i,m]),jsxs(ra,{isMounted:(o?d!=="keyboard":!0)&&!u&&!f,elementType:"button",transitions:{from:{opacity:0,transform:"translateX(-50%) translateY(10px)"},enter:{opacity:1,transform:"translateX(-50%) translateY(0)"},leave:{opacity:0,transform:"translateX(-50%) translateY(10px)"},immediate:g},...mergeProps(v,h,R,P),className:classNames(fu,fr({isFocusVisible:x,variant:"high-contrast",isHovered:C}),"BaselineUI-ScrollControlButton",e),style:t,ref:N(s,p),children:[jsx(ArrowDownCircleFilledIcon,{size:16}),a]})});gu.displayName="ScrollControlButton";var cn="_1yep5z6jc _1yep5z6jd _1yep5z6je _1yep5z6jl _1yep5z6jm _1yep5z6jn",vu=_({defaultClassName:"_1v0p2z10 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",variantClassNames:{hasTitleAndIcon:{true:"_1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nw _1yep5z6nx _1yep5z6ny"},hasNoCloseBtn:{true:"_1yep5z6lk _1yep5z6ll _1yep5z6lm _1yep5z6nw _1yep5z6nx _1yep5z6ny _1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6mq _1yep5z6mr _1yep5z6ms"}},defaultVariants:{},compoundVariants:[[{hasTitleAndIcon:!0,hasNoCloseBtn:!0},"_1yep5z61g7 _1yep5z61g8 _1yep5z61g9"]]}),_u="_1v0p2z10";var ia=to.forwardRef(({className:e,style:t,"data-block-id":o,message:r,title:a,primaryActionLabel:i,cancelLabel:n,textInputProps:l,icon:s,iconColor:p,showCloseButton:d=!0,onPrimaryAction:u,onCancel:c,autoFocusButton:m,isPrimaryActionDisabled:f},y)=>{let g=useId(),{formatMessage:v}=B(),b=a&&jsx(W,{id:g,type:"title",size:"sm",elementType:"h3",children:a});return jsxs(me,{className:e,style:t,"data-block-id":o,size:"sm",variant:"primary",role:"alertdialog",ref:y,"aria-labelledby":g,children:[jsxs("div",{className:vu({hasTitleAndIcon:!!(s&&a),hasNoCloseBtn:!d}),children:[jsxs(M,{display:"flex",justifyContent:"space-between",alignItems:"center",flexDirection:"row",children:[s?jsx(s,{style:{color:p},size:24}):null,!s&&b,d?jsx(L,{icon:XIcon$1,variant:"secondary",size:"md","aria-label":v(qP.close),onPress:c}):null]}),s?b:null]}),r?jsx(M,{elementType:"section",className:_u,paddingX:"lg",paddingBottom:"lg",typography:"body.sm.regular",color:"text.primary",children:r}):null,l?jsx(M,{paddingX:"lg",paddingBottom:"lg",children:jsx(ko,{...l})}):null,n||i?jsxs(Fragment,{children:[jsx(F,{}),jsxs(M,{padding:"lg",display:"flex",gap:"xl",children:[n?jsx(O,{variant:"secondary",className:cn,label:n,onPress:c,autoFocus:m==="cancel"}):null,i?jsx(O,{className:cn,label:i,onPress:u,autoFocus:m==="primary",isDisabled:f}):null]})]}):null]})});ia.displayName="AlertDialog";var qP=j({close:{id:"close",defaultMessage:"Close",description:"Close button label"}});var zu="_1t55bp71",hu="_1yep5z6e3 _1yep5z6eu _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69i _1yep5z69j _1yep5z69k",xu="_1t55bp70";var ZP=YP(),Cu=to.forwardRef(({className:e,style:t,children:o,"data-block-id":r,showCaret:a},i)=>{let n=useMemo(()=>{let l=o;return (!o||Array.isArray(o)&&o.length===0)&&(l=""),ZP.render(l)},[o]);return jsx("div",{className:classNames(hu,xu,{[zu]:a},"BaselineUI-Markdown",e),"data-block-id":r,style:t,ref:i,dangerouslySetInnerHTML:{__html:n}})});Cu.displayName="Markdown";function Ru(e){let{formatMessage:t,locale:o}=B(),[r,a]=to.useState(!1),[i,n]=to.useState(0),[l,s]=to.useState(0),[p,d]=to.useState(!1);useEffect(()=>{if(!e.current)return;let m=e.current,f=()=>{a(!1),n(0);},y=()=>{p||n(m.currentTime*100/m.duration);},g=()=>{s(m.duration);};return m.addEventListener("ended",f),m.addEventListener("timeupdate",y),m.addEventListener("loadedmetadata",g),()=>{m.removeEventListener("ended",f),m.removeEventListener("timeupdate",y),m.removeEventListener("loadedmetadata",g);}},[p,e]);let u=useCallback(()=>{(async()=>e.current&&(e.current.paused?(await e.current.play(),a(!0),announce(t(ku.playing),"polite")):(e.current.pause(),a(!1),announce(t(ku.paused),"polite"))))();},[t,e]),c=useCallback(m=>{e.current&&(e.current.currentTime=m*e.current.duration/100,announce(e0(e.current.currentTime,o.locale),"assertive"));},[o.locale,e]);return {isPlaying:r,progress:i,duration:l,togglePlay:u,seek:c,setProgress:n,formattedCurrentTime:e.current?.currentTime?wu(e.current?.currentTime):"00:00",formattedDuration:l?wu(l):"00:00",setIsSliderDragging:d}}var ku=j({playing:{id:"playing",defaultMessage:"Playing"},paused:{id:"paused",defaultMessage:"Paused"}});function e0(e,t){let o=Math.floor(e/3600),r=Math.floor(e%3600/60),a=e%60,i={...o&&{hours:o},...r&&{minutes:r},seconds:Math.floor(a)};return new Intl.DurationFormat(t,{style:"long"}).format(i)}function wu(e){let t=Math.floor(e%3600/60),o=Math.floor(e%60);return [t,o].map(r=>r.toString().padStart(2,"0")).join(":")}var Iu="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q",Tu="rta2n91 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6z9 _1yep5z6ut _1yep5z6uu _1yep5z6uv _1yep5z6166 _1yep5z6106",Nu="rta2n90";var Mu=to.forwardRef(({className:e,style:t,size:o="lg",sources:r,"data-block-id":a,...i},n)=>{let l=to.useRef(null),{isPlaying:s,progress:p,duration:d,togglePlay:u,seek:c,formattedDuration:m,formattedCurrentTime:f,setProgress:y,setIsSliderDragging:g}=Ru(l),{formatMessage:v}=B(),b=filterTruthyValues({"data-block-id":a,"data-state":s?"playing":"paused","data-loaded":d>0});return jsxs("div",{...b,...i,className:classNames(Iu,"BaselineUI-AudioPlayer",e),role:"group",style:t,ref:n,children:[jsx(VisuallyHidden,{children:jsx("audio",{ref:l,children:r.map(({url:h,type:z})=>jsx("source",{src:h,type:z},h))})}),jsx(ve,{icon:s?PauseIcon:PlayIcon,variant:"toolbar",isSelected:s,size:o,"aria-label":v(s?mn.pause:mn.play),style:{borderRadius:"50%"},onPress:u}),jsxs("div",{className:Tu,children:[jsx("span",{"aria-hidden":!0,children:f}),jsx(Qt,{"aria-label":v(mn.audioTimeline),value:p,minValue:0,maxValue:100,className:Nu,onChange:h=>{y(h),g(!0);},onChangeEnd:h=>{c(h),g(!1);}}),jsx("span",{"aria-hidden":!0,children:m})]})]})});Mu.displayName="AudioPlayer";var mn=j({play:{id:"play",defaultMessage:"Play"},pause:{id:"pause",defaultMessage:"Pause"},audioTimeline:{id:"audioTimeline",defaultMessage:"Audio timeline"}});var Du="_1w920rnf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6ho _1yep5z6hp _1yep5z6hq",Bu="_1w920rn1 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k",Eu="_1w920rn0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6km",Lt=_({defaultClassName:"_1w920rn2 _1yep5z6d6 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{isFocusVisible:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isLoading:{true:"_1yep5z614w _1yep5z614x _1yep5z614y"},imageWidth:{sm:"_1w920rn6",md:"_1w920rn7"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rn8 _1yep5z6l1 _1yep5z6kz _1yep5z6hc"]]}),Fu="_1w920rnd _1yep5z6kw",Hu=_({defaultClassName:"_1w920rn9 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6fw _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocusVisible:{true:"_1w920rna _1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1w920rnb"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rnc _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]}),Ou="_1w920rne";var Au=({items:e,ulRef:t})=>{let{length:o}=e,r=to.useRef(null);return useLayoutEffect(()=>{if(!r.current)return;let a=r.current.closest(".BaselineUI-ImageGallery")?.querySelector(`[data-image-key='${e?.at(-1)?.key}']`)?.cloneNode(!0);invariant(a,"Node is not defined."),r.current?.prepend(a);},[e,t]),jsx("div",{className:Lt(),ref:r,children:jsx(M,{backgroundColor:"background.secondary.medium",borderRadius:"full",typography:"label.md.medium",color:"text.primary",position:"absolute",paddingX:"md",className:Ou,children:o})})};var $u=({item:{value:e},options:{optionProps:t,isFocusVisible:o,isSelected:r},liRef:a,fit:i="contain",imageWidth:n=102,onDelete:l,aspectRatio:s})=>{let p=useId(),{formatMessage:d}=B();invariant(e&&(e?.type==="option"||e?.type===void 0));let{imgProps:u,isLoading:c,isLoaded:m}=bo({src:e.data?.src,alt:e.data?.alt??""}),f=useTransition(m,{from:{opacity:0},enter:{opacity:1},leave:{opacity:0}}),y=isNumber(n)?void 0:Lt({imageWidth:n}),g=isNumber(n)?{width:n}:void 0;return jsxs("li",{...t,ref:a,className:Bu,"aria-labelledby":p,children:[jsx("div",{className:classNames(Lt({isFocusVisible:o,isSelected:r,isLoading:!0}),y),style:{aspectRatio:s?.toString(),...g},"data-image-key":e.id,children:c?jsx(Io,{"aria-label":d(Mt.loading)}):f((v,b)=>b&&jsx(animated.div,{role:"img","aria-label":u.alt,style:{...v,backgroundImage:`url(${u.src})`,backgroundSize:i},className:Fu,children:l?jsx("div",{className:Du,children:jsx(L,{"aria-label":d(Mt.delete),size:"xs",icon:XIcon$2,onPress:()=>{l(e.id);},UNSAFE_NON_INTERACTIVE:!0})}):null}))}),jsx("span",{id:p,className:Hu({isFocusVisible:o,isSelected:r}),children:e.label})]})};var x0={width:0,display:"block"};var C0=to.createContext(null),fn=to.forwardRef(({className:e,style:t,fit:o="cover",onReorder:r,"data-block-id":a,onDelete:i,imageWidth:n="sm",aspectRatio:l=3/4,list:s,onKeyDown:p,...d},u)=>{let c=to.useRef(null),[m,f]=useState([]),{formatMessage:y}=B(),g=useCallback(z=>{z.target.dropPosition==="before"?s.moveBefore(z.target.key,z.keys):z.target.dropPosition==="after"&&s.moveAfter(z.target.key,z.keys),r?.(z);},[s,r]),v=useCallback(()=>{i&&m.length&&(s.remove(...m),i(new Set(m)),f([]));},[m,s,i]),b=useCallback((z,x,R)=>jsx($u,{item:z,options:x,liRef:R,fit:o,imageWidth:n,aspectRatio:l,onDelete:i?C=>{f([C]);}:void 0}),[l,o,i,n]),{keyboardProps:h}=useKeyboard({onKeyDown(z){if(p?.(z),z.key==="Backspace"||z.key==="Delete"){if(!i)return;if([...s.selectedKeys].length)f([...s.selectedKeys]);else {let R=s.getItem(z.target.dataset.key).id;f([R]);}}}});return jsxs("div",{...h,ref:u,style:t,className:classNames("BaselineUI-ImageGallery",e),"data-block-id":a,children:[jsx(te,{...d,items:s.items,onReorder:g,layout:"grid",orientation:"vertical",className:Eu,ref:c,dropIndicatorStyle:x0,renderOption:b,renderDragPreview:z=>jsx(Au,{items:z,ulRef:c}),onSelectionChange:s.setSelectedKeys,getItems:z=>[...z].map(x=>({src:s.getItem(x).src||"",alt:s.getItem(x).alt||"",key:x}))}),jsx(ze,{isOpen:!![...m].length,onOpenChange:z=>{z||f([]);},children:jsx(Te,{isDismissable:!0,children:jsx(ia,{showCloseButton:!1,title:"Are you sure you want to delete this item?",primaryActionLabel:y(Mt.delete),cancelLabel:y(Mt.cancel),onCancel:()=>{f([]);},onPrimaryAction:v,autoFocusButton:"cancel"})})})]})});fn.displayName="ImageGalleryCore";var Uu=to.forwardRef((e,t)=>{let{items:o=[],onListChange:r,onSelectionChange:a}=e,i=js({initialItems:o.map(n=>({id:n.id,label:n.label,data:{src:n.src,alt:n.alt}})),onListChange:r,onSelectionChange:a});return jsx(fn,{...e,ref:t,list:i})});Uu.displayName="ImageGalleryStandalone";var qu=to.forwardRef((e,t)=>{let o=useContext(C0);return useEffect(()=>{invariant(o||e.items,"ImageGallery: A `state` that can be passed via context or `items` are required.");},[e.items,o]),o?jsx(fn,{...e,ref:t,list:o}):jsx(Uu,{...e,ref:t})});qu.displayName="ImageGallery";var Mt=j({delete:{id:"delete",defaultMessage:"Delete"},cancel:{id:"cancel",defaultMessage:"Cancel"},loading:{id:"loading",defaultMessage:"Loading"}});var Ku="_1sexph00",Gu="_1sexph01 _1yep5z616p _1yep5z616q _1yep5z616r _1yep5z6191 _1yep5z6192 _1yep5z6193 _1yep5z61a7 _1yep5z61a8 _1yep5z61a9 _1yep5z617v _1yep5z617w _1yep5z617x _1yep5z61q4 _1yep5z61q5 _1yep5z61q6";var Xu=to.forwardRef(({className:e,style:t,items:o,"data-block-id":r,hideLabel:a,size:i="md",isDisabled:n,showSelectedIcon:l=!0,excludeFromTabOrder:s,...p},d)=>{let u=se(),c=useSelectState({items:o,...p,children:u,validationState:p.validationState==="error"?"invalid":"valid",onSelectionChange:x=>{x&&f(x),p.onSelectionChange?.(x);}}),[m,f]=useState(c.selectedKey||c.collection.getFirstKey()),y=useMemo(()=>c.collection.getItem(m),[m,c.collection]),{hoverProps:g,isHovered:v}=useHover({isDisabled:n}),b=useMemo(()=>{let x=y.textValue||y["aria-label"],R=y.value.icon,C=m===c.selectedKey,k={size:i,isSelected:C,onPress:()=>{c.setSelectedKey(C?null:m);},isDisabled:n,excludeFromTabOrder:s};return a&&R?jsx(ve,{icon:R,"aria-label":x,variant:"toolbar",...k}):jsx(mr,{iconStart:R,label:x,...k})},[m,y,s,a,n,v,i,c]),h=useCallback(({buttonProps:x,isOpen:R,ref:C})=>{let P=m===c.selectedKey;return jsx(ve,{...x,ref:C,icon:ChevronDownIcon,"aria-expanded":R,variant:"toolbar",size:i,isSelected:P,className:Gu,isDisabled:n,excludeFromTabOrder:s})},[m,s,n,i,c.selectedKey]),z=filterTruthyValues({"data-block-id":r,"data-hovered":v,"data-selected":m===c.selectedKey});return jsx(ei.Provider,{value:c,children:jsxs(M,{...g,role:"group",display:"inline-flex",flexDirection:"row",alignItems:"center",className:classNames(Ku,"BaselineUI-ButtonSelect",e),"aria-label":p["aria-label"],"aria-labelledby":p["aria-labelledby"],"aria-describedby":p["aria-describedby"],"aria-details":p["aria-details"],style:t,ref:d,...z,children:[b,jsx(Ae,{isDisabled:n,showSelectedIcon:l,placement:"bottom end",items:o,...p,variant:"ghost",renderTrigger:h})]})})});Xu.displayName="ButtonSelect";var Yu=_({defaultClassName:"_18v88n10 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6kv",variantClassNames:{labelPosition:{top:"_1yep5z613n _1yep5z613o _1yep5z613p",start:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6152 _1yep5z6153 _1yep5z6154 _1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),Zu=_({defaultClassName:"_18v88n1p _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6eu _1yep5z6kv _1yep5z6l6 _1yep5z6ky _1yep5z6dy",variantClassNames:{isDisabled:{true:"_18v88n1q _1yep5z6109"},labelPosition:{top:"_18v88n1r",start:"_18v88n1s"}},defaultVariants:{},compoundVariants:[]}),Qu=_({defaultClassName:"_18v88n1t _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ks",variantClassNames:{validationState:{valid:"_18v88n1u",error:"_1yep5z6zp",warning:"_1yep5z6zx"},isReadOnly:{true:"_1yep5z610b"}},defaultVariants:{},compoundVariants:[]}),Ju=_({defaultClassName:"_18v88n1d _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{validationState:{valid:"_18v88n1e",error:"_1yep5z611k",warning:"_18v88n1g"},isHovered:{true:"_18v88n1h"},isFocused:{true:"_1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z616k _1yep5z616i _1yep5z611y _1yep5z616b _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"_18v88n1j"},variant:{primary:"_18v88n1k",ghost:"_18v88n1l"},isReadOnly:{true:"_1yep5z612n"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"_1yep5z61rv _1yep5z61rt _1yep5z61nc"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"_18v88n1n"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"_1yep5z61nd"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"_1yep5z61nd"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"_18v88n1o"]]}),ef=_({defaultClassName:"_18v88n13 _1yep5z6dy _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),of=_({defaultClassName:"_18v88n19 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5",variantClassNames:{labelPosition:{top:"_1yep5z6sh _1yep5z6si _1yep5z6sj",start:"_1yep5z6me _1yep5z6mf _1yep5z6mg _1yep5z613n _1yep5z613o _1yep5z613p"},hasMessage:{true:"_18v88n1c"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"_1yep5z61q7 _1yep5z61q8 _1yep5z61q9"]]}),tf="_1yep5z6kv",rf="_1yep5z6d7 _1yep5z6fs",af=_({defaultClassName:"_18v88n15 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isHovered:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isOpen:{true:"_1yep5z612v _1yep5z6169"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isHovered:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isOpen:!0},"_1yep5z61o6 _1yep5z61rk"]]});var lf=to.forwardRef(({className:e,style:t,inputStyle:o,inputClassName:r,"data-block-id":a,label:i,items:n,showSelectedIcon:l=!1,onSelectionChange:s,onInputChange:p,isInvalid:d=!1,labelPosition:u="top",validationState:c="valid",variant:m="primary",toggleLabel:f,renderOption:y,showIcon:g=!0,filter:v,...b},h)=>{let{contains:z}=useFilter({sensitivity:"base"}),x=se(),R=useComboBoxState({...b,defaultFilter:v||z,defaultItems:n,onSelectionChange:s,onInputChange:p,children:x,validationState:d?"invalid":"valid"}),C=to.useRef(null),P=to.useRef(null),k=to.useRef(null),T=to.useRef(null),I=to.useRef(null),{buttonProps:D,inputProps:E,listBoxProps:w,labelProps:S,errorMessageProps:$,descriptionProps:re,validationErrors:pe}=useComboBox({...b,inputRef:P,defaultItems:n,buttonRef:C,listBoxRef:k,popoverRef:T,validationState:c==="error"?"invalid":"valid"},R),X=b.errorMessage||pe.join(" "),K=_e({...b,errorMessage:X,descriptionProps:re,errorMessageProps:$,labelPosition:u});X&&(c="error");let{hoverProps:G,isHovered:V}=useHover({isDisabled:b.isDisabled}),{isFocused:Z,focusProps:ee,isFocusVisible:Ce}=useFocusRing(),Pe=Po({isReadOnly:b.isReadOnly,validationState:c}),ye=filterTruthyValues({"data-read-only":b.isReadOnly,"data-disabled":b.isDisabled,"data-validation-state":c,"data-focused":Z,"data-focus-visible":Ce}),{labelProps:ke,fieldProps:Le}=useLabel({label:i});return jsx(We.Provider,{value:R,children:jsxs("div",{className:classNames(Yu({labelPosition:u}),e,"BaselineUI-ComboBox"),"data-block-id":a,style:t,ref:h,children:[i||u==="start"&&K?jsxs("div",{className:of({labelPosition:u,hasMessage:!!K}),children:[jsx("label",{...mergeProps(S,ke),className:ef({isDisabled:b.isDisabled}),children:i}),u==="start"&&K]}):null,jsxs("div",{...G,className:Ju({validationState:c,isHovered:V,isFocused:Z,variant:m,isReadOnly:!!b.isReadOnly,isDisabled:!!b.isDisabled}),ref:I,children:[jsx("input",{...mergeProps(E,ee,ye,Le),ref:P,className:classNames(Zu({isDisabled:b.isDisabled,labelPosition:u}),"BaselineUI-ComboBox-Input",r),style:o}),Pe&&g?jsx(Pe,{className:Qu({validationState:c,isReadOnly:b.isReadOnly}),size:16}):null,jsx(O,{...D,ref:C,variant:"popover",label:f,className:af({isFocusVisible:!b.isDisabled&&!b.isReadOnly&&Ce,isHovered:!b.isDisabled&&!b.isReadOnly&&V,isOpen:R.isOpen})})]}),R.isOpen?jsx(le,{className:rf,ref:T,triggerRef:I,state:R,children:jsx(te,{...w,items:n,ref:k,renderOption:y,selectionMode:"single",showSelectedIcon:l,className:tf})}):null,u==="top"&&K]})})});lf.displayName="ComboBox";var pf="byycd00";var bn=to.forwardRef(({item:e,renderGridItem:t,state:o},r)=>{let a=Re(r),i=useGridListItem({node:e},o,a),n=o.selectionManager.selectionMode!=="none"&&o.selectionManager.selectionBehavior==="toggle",{checkboxProps:l}=useGridListSelectionCheckbox({key:e.key},o);return t(e,{...i,checkBoxProps:n?l:void 0},a)});bn.displayName="GridListItem";var df=to.forwardRef(({className:e,style:t,"data-block-id":o,...r},a)=>{let i=se(),n=useListState({...r,children:i}),l=Re(a),{gridProps:s}=useGridList(r,n,l);return jsx("ul",{...s,className:classNames(pf,e),"data-block-id":o,style:t,ref:l,children:[...n.collection].map(p=>jsx(bn,{item:p,state:n,renderGridItem:r.renderGridItem},p.key))})});df.displayName="GridList";var mf="_1dc3b8m0";var yf=to.forwardRef(({className:e,selectionMode:t="single",style:o,"data-block-id":r,includeTooltip:a,...i},n)=>{let l=Re(n),s=se(),p=useListState({...i,selectionMode:t,suppressTextValueWarning:!0,children:s}),{actionGroupProps:d}=useActionGroup({...i,selectionMode:t,children:s},p,l);return jsx(M,{...d,display:"flex",flexDirection:"row",gap:"xs",className:classNames("BaselineUI-ActionGroup",e),"data-block-id":r,style:o,ref:l,children:[...p.collection].map(u=>jsx(ek,{item:u,state:p,isDisabled:i.isDisabled,onAction:i.onAction,includeTooltip:a},u.key))})});yf.displayName="ActionGroup";var ek=({item:e,state:t,onAction:o,includeTooltip:r,isDisabled:a})=>{let{buttonProps:i}=useActionGroupItem({key:e.key},t),n=a||t.selectionManager.isDisabled(e.key),l=t.selectionManager.isSelected(e.key);invariant(e.value);let{icon:s}=e.value;return invariant(s),jsx(PressResponder,{...mergeProps(i,{onPress:()=>{o?.(e.key);}}),children:jsx(He,{text:e.textValue,size:"sm",variant:"inverse",isDisabled:!r,includeArrow:!1,offset:4,children:jsx(L,{variant:"tertiary",icon:s,"aria-label":e.textValue,size:"sm",isDisabled:n,className:classNames({[mf]:l},"BaselineUI-ActionGroup-Item")})})})};var gf=to.forwardRef(({className:e,style:t,items:o,optionsContainerClassName:r,"data-block-id":a,label:i,icon:n,value:l,defaultValue:s,onChange:p,isDisabled:d,optionClassName:u,optionStyle:c,labelPosition:m="top",...f},y)=>{let g=useMemo(()=>o.map(b=>({id:b.color,label:b.label})),[o]),v=useId();return useEffect(()=>{!i&&!f["aria-label"]&&!f["aria-labelledby"]&&console.warn("ColorSwatchPicker: Please provide a label or aria-label for accessibility.");},[i,f]),jsxs(M,{...ma(f),className:classNames("BaselineUI-ColorSwatchPicker",e),"data-block-id":a,display:"flex",flexDirection:m==="top"?"column":"row",alignItems:m==="top"?"flex-start":"center",justifyContent:"space-between",gap:"md",style:t,ref:y,children:[n||i?jsxs(M,{display:"flex",alignItems:"center",gap:"md",children:[n?jsx(n,{size:24,className:sprinkles({color:"icon.primary"})}):null,i?jsx(W,{id:v,type:"label",size:"sm",children:i}):null]}):null,jsx(te,{className:classNames(Kr,r),selectionMode:"single",items:g,orientation:"horizontal",defaultSelectedKeys:s?[s]:void 0,disabledKeys:d?g.map(b=>b.id):void 0,isDisabled:d,selectedKeys:l?[l]:void 0,onSelectionChange:b=>{p?.([...b][0]);},optionClassName:u,optionStyle:c,renderOption:({key:b,textValue:h},{isSelected:z,isFocusVisible:x,isDisabled:R,optionProps:C},P)=>jsx("li",{...C,"data-disabled":R,className:classNames(qr,C.className),ref:P,children:jsx(he,{isFocusVisible:x,color:b,isSelected:z,"aria-label":h,isInteractive:!0,isDisabled:R})}),...f,"aria-labelledby":i?v:f["aria-labelledby"]})]})});gf.displayName="ColorSwatchPicker";function rY(e){return e.closest(".BaselineUI-Portal")||e.closest(".BaselineUI-Popover-Content")}
51
+ var Te=typeof document<"u"?to.useLayoutEffect:()=>{};function la(e){let o=useRef(null);return Te(()=>{o.current=e;},[e]),useCallback((...t)=>{let r=o.current;return r?.(...t)},[])}function pa(e){let[o,t]=useState(e),r=useRef(null),a=la(()=>{if(!r.current)return;let s=r.current.next();if(s.done){r.current=null;return}o===s.value?a():t(s.value);});Te(()=>{r.current&&a();});let i=la(s=>{r.current=s(o),a();});return [o,i]}var be=e=>{var o;return (o=e?.ownerDocument)!==null&&o!==void 0?o:document},Q=e=>{if(e&&"window"in e&&e.window===e)return e;let o=At(e);return o instanceof ShadowRoot?o.ownerDocument.defaultView||window:o?.defaultView||window},At=e=>{if(!e)return document;let o=e.getRootNode?e.getRootNode():document;return e.isConnected?(o):null};function T(...e){return e.length===1?e[0]:o=>{for(let t of e)typeof t=="function"?t(o):t!=null&&(t.current=o);}}var Mf=new Set(["id"]),Bf=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),Df=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),Ef=/^(data-.*)$/;function ca(e,o={}){let{labelable:t,isLink:r,propNames:a}=o,i={};for(let s in e)Object.prototype.hasOwnProperty.call(e,s)&&(Mf.has(s)||t&&Bf.has(s)||r&&Df.has(s)||a?.has(s)||Ef.test(s))&&(i[s]=e[s]);return i}function fs(e){var o;return typeof window>"u"||window.navigator==null?!1:((o=window.navigator.userAgentData)===null||o===void 0?void 0:o.brands.some(t=>e.test(t.brand)))||e.test(window.navigator.userAgent)}function da(e){var o;return typeof window<"u"&&window.navigator!=null?e.test(((o=window.navigator.userAgentData)===null||o===void 0?void 0:o.platform)||window.navigator.platform):!1}function ys(){return da(/^Mac/i)}function bs(){return da(/^iPhone/i)}function gs(){return da(/^iPad/i)||ys()&&navigator.maxTouchPoints>1}function ma(){return bs()||gs()}function ua(){return fs(/Android/i)}function Go(){return fs(/Firefox/i)}function ge(e){let o=useRef(null);return useMemo(()=>({get current(){return o.current},set current(t){o.current=t,typeof e=="function"?e(t):e&&(e.current=t);}}),[e])}function Vf(){return typeof window.ResizeObserver<"u"}function fa(e){let{ref:o,onResize:t}=e;useEffect(()=>{let r=o?.current;if(r)if(Vf()){let a=new window.ResizeObserver(i=>{i.length&&t();});return a.observe(r),()=>{r&&a.unobserve(r);}}else return window.addEventListener("resize",t,!1),()=>{window.removeEventListener("resize",t,!1);}},[t,o]);}function Uf(e){return "type"in e&&e.type==="section"?jsx(Section,{items:e.children,title:e.title,children:o=>jsx(Item,{children:o.label},o.id)},e.id):(invariant("label"in e,"Item doesn't have a label"),jsx(Item,{textValue:e.label,children:e.label},e.id))}function te(){return useCallback(e=>Uf(e),[])}function _s(e,o,t){let{direction:r}=useLocale(),a=useDraggableCollectionState({...e,collection:o.collection,selectionManager:o.selectionManager,isDisabled:!e.enableReorder,getItems:e.getItems||(n=>[...n].map(p=>{let l=o.collection.getItem(p);return invariant(l,"Expected item to be defined."),{"text/plain":l.textValue}}))});useDraggableCollection(e,a,t);let i=useDroppableCollectionState({...e,collection:o.collection,selectionManager:o.selectionManager}),{collectionProps:s}=useDroppableCollection({...e,keyboardDelegate:new ListKeyboardDelegate({collection:o.collection,disabledKeys:o.disabledKeys,ref:t,orientation:e.orientation,layout:e.layout,direction:r}),dropTargetDelegate:new ListDropTargetDelegate(o.collection,t)},i,t);return {collectionProps:s,dragState:a,dropState:i}}function Jf(e,o){if(typeof e!="object"||!e)return e;var t=e[Symbol.toPrimitive];if(t!==void 0){var r=t.call(e,o||"default");if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return (o==="string"?String:Number)(e)}function ey(e){var o=Jf(e,"string");return typeof o=="symbol"?o:String(o)}function oy(e,o,t){return o=ey(o),o in e?Object.defineProperty(e,o,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[o]=t,e}function zs(e,o){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);o&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),t.push.apply(t,r);}return t}function hs(e){for(var o=1;o<arguments.length;o++){var t=arguments[o]!=null?arguments[o]:{};o%2?zs(Object(t),!0).forEach(function(r){oy(e,r,t[r]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):zs(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r));});}return e}function xs(e,o){var t={};for(var r in e)t[r]=o(e[r],r);return t}var ty=(e,o,t)=>{for(var r of Object.keys(e)){var a;if(e[r]!==((a=o[r])!==null&&a!==void 0?a:t[r]))return !1}return !0},v=e=>{var o=t=>{var r=e.defaultClassName,a=hs(hs({},e.defaultVariants),t);for(var i in a){var s,n=(s=a[i])!==null&&s!==void 0?s:e.defaultVariants[i];if(n!=null){var p=n;typeof p=="boolean"&&(p=p===!0?"true":"false");var l=e.variantClassNames[i][p];l&&(r+=" "+l);}}for(var[c,m]of e.compoundVariants)ty(c,a,e.defaultVariants)&&(r+=" "+m);return r};return o.variants=()=>Object.keys(e.variantClassNames),o.classNames={get base(){return e.defaultClassName.split(" ")[0]},get variants(){return xs(e.variantClassNames,t=>xs(t,r=>r.split(" ")[0]))}},o};var Cs=v({defaultClassName:"_6n12k9b _1yep5z6l0 _1yep5z6kz _1yep5z6hk _1yep5z6ki",variantClassNames:{isDropTarget:{true:"_1yep5z612n"},orientation:{vertical:"_1yep5z6166",horizontal:"_1yep5z6167"}},defaultVariants:{},compoundVariants:[]}),Ps="_6n12k98 _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",ks=v({defaultClassName:"_6n12k99 _1yep5z6ev _1yep5z6da _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),ws=v({defaultClassName:"_6n12k91 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6dy _1yep5z6eu _1yep5z6ki _1yep5z6kl _1yep5z6ky _1yep5z6kx _1yep5z6kv _1yep5z6ks",variantClassNames:{isSelected:{},isFocused:{true:"_1yep5z612n _1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612w _1yep5z612x _1yep5z612y"},isHovered:{true:"_1yep5z6114",false:"_1yep5z6113"},isFirstChild:{true:"_6n12k95"},isLastChild:{true:"_6n12k96"},isDisabled:{true:"z9nup83 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Rs="_6n12k9f _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",Is="_6n12k90";var Ns=v({defaultClassName:"gukncs0",variantClassNames:{isVertical:{true:"gukncs1"},isSecondary:{true:"gukncs2"}},defaultVariants:{},compoundVariants:[]});var O=to.forwardRef(({className:e,style:o,variant:t="primary",orientation:r="horizontal",UNSAFE_omitRole:a,elementType:i="div","data-block-id":s,"data-block-class":n,...p},l)=>{let{separatorProps:c}=useSeparator({...p,orientation:r,elementType:i});return jsx(i,{...c,className:classNames(Ns({isVertical:r==="vertical",isSecondary:t==="secondary"}),"BaselineUI-Separator",e),"data-orientation":r,"data-block-id":s,"data-block-class":n,style:o,role:a?void 0:c.role,ref:l})});O.displayName="Separator";function cy(e){return sprinkles.properties.has(e)}var M=to.forwardRef(({elementType:e="div",children:o,...t},r)=>{let a=e,{sprinkleProps:i,domProps:s}=useMemo(()=>{let n={},p={};for(let l in t)cy(l)?n[l]=t[l]:p[l]=t[l];return {sprinkleProps:n,domProps:p}},[t]);return jsx(a,{...s,className:classNames(sprinkles(i),"BaselineUI-Box",s.className),ref:r,children:o})});M.displayName="Box";var Xo=to.forwardRef(({item:e,isDisabled:o,isFocusVisible:t,isSelected:r,liProps:a,showSelectedIcon:i,description:s,descriptionProps:n,labelProps:p,isFocused:l,isPressed:c,_state:m},u)=>{invariant(e.value&&(e.value.type==="option"||e.value.type===void 0),"Item cannot be a section");let{icon:d,label:f}=e.value,{hoverProps:y,isHovered:b}=useHover({isDisabled:o}),_=filterTruthyValues({"data-selected":r,"data-disabled":o,"data-focused":l,"data-hovered":b,"data-pressed":c,"data-focus-visible":t,"data-selection-mode":m.selectionManager.selectionMode});return jsxs("li",{...mergeProps(a,y,_),className:classNames(ws({isHovered:b,isFocused:t,isFirstChild:m.collection.getFirstKey()===e.key,isLastChild:m.collection.getLastKey()===e.key,isDisabled:o}),"BaselineUI-ListBox-Option"),ref:u,children:[jsxs(M,{display:"flex",alignItems:"center",gap:"lg",children:[i?jsx("span",{"aria-hidden":!0,style:{height:24,width:24},children:r?jsx(CheckmarkIcon,{size:24}):null}):null,d?jsx(d,{size:24}):null,jsx("span",{...p,children:f})]}),s?jsx("span",{className:ks({isDisabled:o}),...n,children:s}):null]})});Xo.displayName="DefaultRenderOption";var ga=({dropState:e,orientation:o="vertical",dropIndicatorStyle:t,dropIndicatorClassName:r,renderDropIndicator:a=({isDropTarget:s,isHidden:n,dropIndicatorProps:p,orientation:l},c)=>n?null:jsx("li",{...p,ref:c,"data-drop-target":s,className:classNames(Cs({isDropTarget:s,orientation:l}),"BaselineUI-DropIndicator",r),style:t}),...i})=>{let s=to.useRef(null),{dropIndicatorProps:n,isHidden:p,isDropTarget:l}=useDropIndicator(i,e,s);return a({dropIndicatorProps:{...n,role:"option"},isHidden:p,isDropTarget:l,orientation:o},s)};var Ds=({item:e,children:o,state:t,dragState:r,...a})=>{let{dragProps:i}=useDraggableItem({key:e.key},r);return jsxs(Fragment,{children:[jsx(ga,{target:{type:"item",key:e.key,dropPosition:"before"},...a}),o(i),t.collection.getKeyAfter(e.key)==null&&jsx(ga,{target:{type:"item",key:e.key,dropPosition:"after"},...a})]})};Ds.displayName="DraggableListOption";var Yo=to.forwardRef(({item:e,renderOption:o=(u,d,f)=>jsx(Xo,{item:u,liProps:d.optionProps,...d,ref:f}),showSelectedIcon:t,state:r,dragState:a,dropState:i,orientation:s,dropIndicatorStyle:n,dropIndicatorClassName:p,optionStyle:l,optionClassName:c},m)=>{let u=to.useRef(null),d=useOption({key:e.key},r,u),{value:f}=e;invariant(!!f),invariant(!("children"in e),"ListSection should not be passed to ListOption");let y={style:typeof l=="function"?l(f):l,className:typeof c=="function"?c(f):c};return a&&i?jsx(Ds,{orientation:s,state:r,item:e,dropState:i,dragState:a,dropIndicatorStyle:n,dropIndicatorClassName:p,children:b=>o(e,{...d,showSelectedIcon:t,_state:r,optionProps:mergeProps(d.optionProps,b,y)},T(u,m))}):o(e,{...d,showSelectedIcon:t,_state:r,optionProps:mergeProps(d.optionProps,y)},T(u,m))});Yo.displayName="Option";var Hs=({section:e,state:o,sectionClassName:t,sectionStyle:r,showSectionHeader:a,renderSectionHeader:i,withSectionHeaderPadding:s=!1,...n})=>{let p=to.useRef(null),{itemProps:l,groupProps:c,headingProps:m}=useListBoxSection({heading:a?i?.(e,p)||e.rendered:void 0,"aria-label":e["aria-label"]}),u=o.collection.getChildren?.(e.key);invariant(u,"items with type `section` must have children");let{value:d}=e,f=typeof r=="function"?r(d):r,y=typeof t=="function"?t(d):t;return jsxs(Fragment,{children:[e.key!==o.collection.getFirstKey()&&jsx(O,{UNSAFE_omitRole:!0}),jsxs("li",{...l,style:{...l.style,...f},className:classNames(Is,y,"BaselineUI-ListBox-Section"),children:[e.rendered&&a?i?.(e,p)||jsx(M,{...m,className:classNames("BaselineUI-ListBox-SectionHeader",Rs),ref:p,paddingX:"lg",typography:"label.md.medium",color:"text.primary",paddingInlineStart:s?"5xl":"lg",paddingInlineEnd:"lg",children:e.rendered}):null,jsx("ul",{...c,children:[...u].map(b=>jsx(Yo,{item:b,state:o,...n},b.key))})]})]})};var Ze=to.createContext(null),va=to.forwardRef(({className:e,layout:o="stack",orientation:t="vertical",showSelectedIcon:r=!0,style:a,renderOption:i,enableReorder:s=!1,"data-block-id":n,"data-block-class":p,renderDragPreview:l,onReorder:c,state:m,listBoxHandle:u,...d},f)=>{let y=to.useRef(null),{direction:b}=useLocale(),_=to.useRef(null),{listBoxProps:z}=useListBox({...d,shouldSelectOnPressUp:s,keyboardDelegate:new ListKeyboardDelegate({collection:m.collection,ref:_,layout:o,orientation:t,direction:b,disabledKeys:m.disabledKeys})},m,_);useImperativeHandle(u,()=>({scrollIntoView:(B,L)=>{_.current?.querySelector(`[data-key="${B}"][role="option"]`)?.scrollIntoView(L);}}));let g=useReducedMotion(),h=useCallback(B=>{let L=be(_.current);c&&(!g&&"startViewTransition"in L?L.startViewTransition(()=>{c(B);}):c(B));},[c,g]),{collectionProps:C,dragState:w,dropState:P}=_s({...d,onReorder:h,layout:o,orientation:t,enableReorder:s,preview:y},m,_),{isFocusVisible:k,isFocused:N,focusProps:R}=useFocusRing(),I=filterTruthyValues({"data-block-id":n,"data-block-class":p,"data-layout":o,"data-empty":m.collection.size===0,"data-focused":N,"data-focus-visible":k,"data-orientation":t});return jsxs("ul",{...mergeProps(z,R,I,C),className:classNames(Ps,"BaselineUI-ListBox",e),style:a,ref:T(f,_),children:[[...m.collection].map(B=>{let L={key:B.key,state:m,dragState:w,dropState:P,renderOption:i,renderDropIndicator:d.renderDropIndicator,renderSectionHeader:d.renderSectionHeader,showSelectedIcon:r,orientation:t,dropIndicatorStyle:d.dropIndicatorStyle,dropIndicatorClassName:d.dropIndicatorClassName,optionStyle:d.optionStyle,optionClassName:d.optionClassName,showSectionHeader:d.showSectionHeader,withSectionHeaderPadding:d.withSectionHeaderPadding};return B.type==="section"?jsx(Hs,{...L,section:B}):jsx(Yo,{...L,item:B})}),l?jsx(DragPreview,{ref:y,children:l}):null]})});va.displayName="ListBoxCore";var Os=to.forwardRef((e,o)=>{let t=te(),r=useListState({...e,children:t});return jsx(va,{...e,ref:o,state:r})});Os.displayName="ListBoxStandalone";var re=to.forwardRef((e,o)=>{let t=useContext(Ze);return useEffect(()=>{if(!e.items&&!t)throw new Error("ListBox: You must provide a `state` or `items` prop to render the listbox.")},[e.items,t]),t?jsx(va,{...e,ref:o,state:t}):jsx(Os,{...e,ref:o})});re.displayName="ListBox";var Ut="uf19bsg _1yep5z6ki",Vs=v({defaultClassName:"uf19bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0 _1yep5z6kx _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ks",variantClassNames:{size:{xxs:"uf19bs1",xs:"uf19bs2",sm:"uf19bs3",md:"uf19bs4",lg:"uf19bs5 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy"},isHovered:{true:"uf19bs6"},isDisabled:{true:"uf19bs7 _1yep5z610d"},isFocusVisible:{true:"uf19bs8"},variant:{primary:"uf19bs9",secondary:"uf19bsa",tertiary:"uf19bsb",ghost:"uf19bsc",toolbar:"_1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg",popover:"uf19bse _1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z6mn _1yep5z6mo _1yep5z6mp _1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nq _1yep5z6nr _1yep5z6ns _1yep5z6uz _1yep5z6v0 _1yep5z6v1"},isPressed:{true:"uf19bsf"}},defaultVariants:{},compoundVariants:[[{variant:"toolbar",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"primary",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"secondary",isHovered:!0,isFocusVisible:!1},"_1yep5z61ln"],[{variant:"tertiary",isHovered:!0,isFocusVisible:!1},"_1yep5z61lm _1yep5z61mg"],[{variant:"ghost",isHovered:!0,isFocusVisible:!1},"_1yep5z61ls"],[{variant:"popover",isHovered:!0,isFocusVisible:!1},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"toolbar",isPressed:!0},"_1yep5z61mg"],[{variant:"primary",isPressed:!0},"_1yep5z61mf"],[{variant:"secondary",isPressed:!0},"_1yep5z61ln"],[{variant:"tertiary",isPressed:!0},"_1yep5z61lq _1yep5z61mg"],[{variant:"ghost",isPressed:!0},"_1yep5z61lt"],[{variant:"popover",isPressed:!0},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"ghost",isDisabled:!1},"_1yep5z61lr"],[{variant:"popover",size:"lg"},"_1yep5z61h4 _1yep5z61h5 _1yep5z61h6 _1yep5z61hs _1yep5z61ht _1yep5z61hu _1yep5z61ig _1yep5z61ih _1yep5z61ii _1yep5z61j4 _1yep5z61j5 _1yep5z61j6"]]});var Zo=to.createContext({state:null,overlayTriggerAria:{triggerProps:{},overlayProps:{}},triggerRef:void 0}),Se=({children:e,...o})=>{let t=to.useRef(null),r=useOverlayTriggerState(o),a=useOverlayTrigger(o,r),i=useMemo(()=>({state:r,overlayTriggerAria:a,triggerRef:t}),[r,a]);return jsx(Zo.Provider,{value:i,children:typeof e=="function"?e(r):e})};var js={bottom:"_1gzftth2",top:"_1gzftth3",right:"_1gzftth4",left:"_1gzftth5"},$s="_1gzftth1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",Us="_1gzftth6",qs="_1gzftth8",Ks="_1gzftth7",Gs="var(--_1gzftth0)";function FR(e){return e.closest(".BaselineUI-Portal")||e.closest(".BaselineUI-Popover-Content")}function Ws(e){return typeof e=="object"&&typeof e.left=="number"&&typeof e.top=="number"&&(typeof e.width=="number"||e.width===void 0)&&(typeof e.height=="number"||e.height===void 0)}var qt=to.createContext({isSelected:!1,ref:void 0}),Le=({children:e,anchorRect:o})=>{let{state:t,overlayTriggerAria:r,triggerRef:a}=useContext(Zo);invariant(t,"PopoverTrigger must be used within a Popover");let{triggerProps:i}=r,s=useMemo(()=>({...i,isSelected:t.isOpen,ref:a}),[i,t.isOpen,a]);return invariant(!o&&e||o&&!e,"Either one of anchorRect or children has to be provided."),invariant(!o||Ws(o),"If provided, the anchorRect prop must be an object with left and top number values, and optionally width and height."),jsx(qt.Provider,{value:s,children:o?jsx("button",{className:classNames(qs,"BaselineUI-PopoverTrigger-Hidden"),style:o,ref:a,tabIndex:-1},JSON.stringify(o)):e})};var Kt=e=>{let o=to.useRef(null),{ref:t,...r}=useContext(qt)||{},{buttonProps:a,isPressed:i}=useButton({...e,...r},o);return {buttonProps:a,isPressed:i,ref:T(o,t||null)}},Gt=(e,o)=>{let t=to.useRef(null),{ref:r,...a}=useContext(qt)||{},{buttonProps:i,isPressed:s}=useToggleButton({...e,...a},o,t);return {buttonProps:i,isPressed:s,ref:T(t,r||null)}};var Wt=v({defaultClassName:"oom8bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6dy _1yep5z6ki",variantClassNames:{variant:{primary:"oom8bs1",secondary:"oom8bs2",tertiary:"oom8bs3",ghost:"oom8bs4",popover:"oom8bs5",toolbar:"oom8bs6",success:"oom8bs7",warning:"oom8bs8",error:"oom8bs9"},isDisabled:{true:"oom8bsa"},isFocusVisible:{true:"oom8bsb"},isHovered:{true:"oom8bsc"},size:{sm:"oom8bsd",md:"oom8bse",lg:"oom8bsf"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isHovered:!0},"oom8bsg"],[{variant:"secondary",isHovered:!0},"oom8bsh"],[{variant:"tertiary",isHovered:!0},"oom8bsi"],[{variant:"popover",isHovered:!0},"oom8bsj"],[{variant:"ghost",isHovered:!0},"oom8bsk"],[{variant:"success",isHovered:!0},"oom8bsl"],[{variant:"warning",isHovered:!0},"oom8bsm"],[{variant:"error",isHovered:!0},"oom8bsn"],[{variant:"primary",isFocusVisible:!0},"oom8bso"],[{variant:"tertiary",isFocusVisible:!0},"oom8bsp"],[{variant:"success",isFocusVisible:!0},"oom8bsq"],[{variant:"warning",isFocusVisible:!0},"oom8bsr"],[{variant:"error",isFocusVisible:!0},"oom8bss"]]});var p1={sm:16,md:20,lg:24},A=to.forwardRef(({label:e,style:o,className:t,iconStart:r,iconEnd:a,variant:i="primary",elementType:s="button",isDisabled:n,size:p="sm","data-block-id":l,"data-block-class":c,...m},u)=>{let{buttonProps:d,isPressed:f,ref:y}=Kt({...m,elementType:s,isDisabled:n}),b=p1[p],{hoverProps:_,isHovered:z}=useHover({isDisabled:n}),{isFocusVisible:g,isFocused:h,focusProps:C}=useFocusRing(),w=filterTruthyValues({"data-block-id":l,"data-block-class":c,"data-disabled":n,"data-focused":h,"data-focus-visible":g,"data-hovered":z,"data-pressed":f});return jsxs(s,{...mergeProps(d,_,C,w),className:classNames(Wt({isDisabled:!!n,isFocusVisible:g,isHovered:z,variant:i,size:p}),"BaselineUI-ActionButton",t),style:o,ref:T(u,y),children:[!!r&&jsx(r,{size:b}),e,!!a&&jsx(a,{size:b}),i==="popover"&&jsx(ChevronDownIcon,{size:8,className:Ut})]})});A.displayName="ActionButton";var Qs=v({defaultClassName:"z9nup84",variantClassNames:{size:{xs:"z9nup85",sm:"z9nup86"}},defaultVariants:{},compoundVariants:[]});var Xt="z9nup80",po="z9nup83";var Js="z9nup87";var en=to.forwardRef(({className:e,node:o,...t},r)=>{let a=to.useRef(null);return to.useEffect(()=>{let i=a.current;return i?.append(o),()=>{i?.contains(o)&&o.remove();}},[o]),jsx("div",{className:classNames(Xt,e),ref:T(r,a),...t})});en.displayName="DomNodeRenderer";var on="_14uvjig0 z9nup81",tn="_14uvjig7",rn="_14uvjig3",an=v({defaultClassName:"_14uvjig4",variantClassNames:{isDisabled:{true:"_14uvjig5"},hasNumberInput:{false:"_14uvjig6"}},defaultVariants:{},compoundVariants:[]}),sn=v({defaultClassName:"_14uvjige _14uvjig1",variantClassNames:{active:{true:"_14uvjigf _14uvjig2"},isDisabled:{true:"_14uvjigg"},isReadOnly:{true:"_14uvjigh"},isFocusVisible:{true:"_14uvjigi _14uvjig2"},isHovered:{true:"_14uvjigj _14uvjig2"}},defaultVariants:{},compoundVariants:[]}),nn="_14uvjig8",ln=v({defaultClassName:"_14uvjig9 _14uvjig1",variantClassNames:{active:{true:"_14uvjig2"},isFocusVisible:{true:"_14uvjigb _14uvjig2"},isDisabled:{true:"_14uvjigc"},isHovered:{true:"_14uvjig2"}},defaultVariants:{},compoundVariants:[]});var co=v({defaultClassName:"nrh1ehx",variantClassNames:{isDisabled:{true:"nrh1ehy"},hasError:{true:"nrh1ehz"},labelPosition:{start:"nrh1eh10",top:"nrh1eh11"}},defaultVariants:{},compoundVariants:[]}),Yt=v({defaultClassName:"nrh1eho",variantClassNames:{isDisabled:{true:"nrh1ehp"},labelPosition:{top:"nrh1ehq",start:"nrh1ehr"}},defaultVariants:{},compoundVariants:[]}),mo=v({defaultClassName:"nrh1ehs",variantClassNames:{validationState:{valid:"nrh1eht",error:"nrh1ehu",warning:"nrh1ehv"},isReadOnly:{true:"nrh1ehw"}},defaultVariants:{},compoundVariants:[]}),Fe="nrh1eh3",He=v({defaultClassName:"nrh1eh4",variantClassNames:{labelPosition:{top:"nrh1eh5",start:"nrh1eh6"},hasMessage:{true:"nrh1eh7"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"nrh1eh8"]]}),Oe=v({defaultClassName:"nrh1eh0",variantClassNames:{labelPosition:{top:"z9nup81",start:"nrh1eh2 z9nup82"}},defaultVariants:{},compoundVariants:[]}),uo=v({defaultClassName:"nrh1eh9 z9nup82",variantClassNames:{validationState:{valid:"nrh1eha",error:"nrh1ehb",warning:"nrh1ehc"},isHovered:{true:"nrh1ehd"},isFocused:{true:"nrh1ehe"},isDisabled:{true:"nrh1ehf"},variant:{primary:"nrh1ehg",ghost:"nrh1ehh"},isReadOnly:{true:"nrh1ehi"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"nrh1ehj"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"nrh1ehk"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"nrh1ehl"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"nrh1ehm"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"nrh1ehn"]]});function xe({description:e,errorMessageProps:o,descriptionProps:t,warningMessage:r,errorMessage:a,labelPosition:i,isDisabled:s}){return e?jsx("div",{...t,className:co({isDisabled:s,labelPosition:i}),children:e}):a?jsx("div",{...o,className:co({hasError:!0,labelPosition:i}),children:a}):r?jsx("div",{className:co({isDisabled:s,labelPosition:i}),children:r}):null}var pn=v({defaultClassName:"_1lnwne1 z9nup82",variantClassNames:{isHoveredOrFocused:{true:"_1lnwne2"},isInteractive:{false:"z9nup83"}},defaultVariants:{},compoundVariants:[[{isHoveredOrFocused:!0,isInteractive:!0},"_1lnwne4"]]}),cn="_1lnwne0";var z1={xxs:8,xs:12,sm:16,md:20,lg:24},D=to.forwardRef(({className:e,style:o,icon:t,size:r="md",variant:a="primary",UNSAFE_NON_INTERACTIVE:i,elementType:s=i?"div":"button",...n},p)=>{!n["aria-label"]&&!n["aria-labelledby"]&&console.warn("An `ActionIconButton` requires an aria-label or aria-labelledby prop.");let{buttonProps:l,isPressed:c,ref:m}=Kt({...n,elementType:s}),{isFocusVisible:u,isFocused:d,focusProps:f}=useFocusRing(),{hoverProps:y,isHovered:b}=useHover({isDisabled:n.isDisabled}),_=filterTruthyValues({"data-block-id":n["data-block-id"],"data-block-class":n["data-block-class"],"data-focused":d,"data-focus-visible":u,"data-disabled":n.isDisabled,"data-hovered":b,"data-pressed":c});return jsxs(s,{...mergeProps(l,y,f,_),className:classNames(Vs({variant:a,size:r,isDisabled:!!n.isDisabled,isFocusVisible:u,isHovered:b,isPressed:c}),"BaselineUI-ActionIconButton",e),ref:T(p,m),style:o,...i&&{tabIndex:void 0,role:void 0,"aria-label":void 0,"aria-labelledby":void 0,"aria-disabled":void 0},children:[jsx(t,{role:"presentation",size:z1[r]}),a==="popover"&&jsx(ChevronDownIcon,{size:8,className:Ut})]})});D.displayName="ActionIconButton";var Me=to.forwardRef(({className:e,style:o,labelPosition:t="top",variant:r="primary",showStepper:a=!0,...i},s)=>{let n=to.useRef(null),{locale:p}=useLocale(),l=useNumberFieldState({...i,locale:p}),{hoverProps:c,isHovered:m}=useHover({isDisabled:i.isDisabled}),{focusProps:u,isFocusVisible:d,isFocused:f}=useFocusRing(),{labelProps:y,decrementButtonProps:b,inputProps:_,incrementButtonProps:z,groupProps:g,descriptionProps:h,errorMessageProps:C}=useNumberField(i,l,n),w=useMemo(()=>i.isReadOnly?ReadOnlyIcon:i.isInvalid?ErrorFilledIcon:null,[i.isInvalid,i.isReadOnly]),P=xe({description:i.description,errorMessageProps:C,descriptionProps:h,errorMessage:i.errorMessage,labelPosition:t,isDisabled:i.isDisabled}),k=filterTruthyValues({"data-disabled":i.isDisabled,"data-readonly":i.isReadOnly,"data-hovered":m,"data-focused":f,"data-focus-visible":d,"data-invalid":i.isInvalid,"data-block-id":i["data-block-id"],"data-block-class":i["data-block-class"]});return jsxs("div",{style:o,className:classNames(Oe({labelPosition:t}),"BaselineUI-NumberInput",e),...k,ref:s,children:[i.label?jsxs("div",{className:He({labelPosition:t,hasMessage:!!P}),children:[jsx("label",{...y,className:Fe,children:i.label}),t==="start"&&P]}):null,jsxs("div",{className:classNames({[po]:i.isDisabled}),children:[jsxs("div",{...mergeProps(g,c),className:classNames(uo({isHovered:m,isDisabled:!!i.isDisabled,isReadOnly:!!i.isReadOnly,validationState:i.isInvalid?"error":"valid",isFocused:f,variant:r}),{[cn]:t==="start"},"BaselineUI-NumberInput-Container"),children:[jsx("input",{...mergeProps(_,u),ref:n,className:classNames("BaselineUI-NumberInput-Input",Yt({isDisabled:i.isDisabled,labelPosition:t}))}),w?jsx(w,{className:mo({validationState:"error",isReadOnly:i.isReadOnly}),size:16}):null,a?jsxs("div",{className:pn({isHoveredOrFocused:m||f,isInteractive:!i.isReadOnly&&!i.isDisabled}),children:[jsx(D,{variant:"secondary",size:"xxs",icon:MinusIcon,...b,className:"BaselineUI-NumberInput-DecrementButton"}),jsx(O,{style:{height:16},orientation:"vertical"}),jsx(D,{variant:"secondary",size:"xxs",icon:PlusIcon,...z,className:"BaselineUI-NumberInput-DecrementButton"})]}):null]}),t==="top"&&P]})]})});Me.displayName="NumberInput";var yo=to.forwardRef(({className:e,style:o,onChange:t,onChangeEnd:r,numberFormatOptions:a,isDisabled:i,step:s,minValue:n,maxValue:p,value:l,"aria-label":c,"aria-labelledby":m,"aria-details":u,"aria-describedby":d,"data-block-id":f,"data-block-class":y,defaultValue:b,isReadOnly:_,label:z,id:g,includeNumberInput:h},C)=>{let w=to.useRef(null),P={onChange:t===void 0?void 0:x=>{t(x[0]);},isDisabled:i||_,step:s,minValue:n,maxValue:p,onChangeEnd:r===void 0?void 0:x=>{r(x[0]);},value:l===void 0?void 0:[l],defaultValue:b===void 0?void 0:[b],"aria-label":c,"aria-labelledby":m,"aria-details":u,"aria-describedby":d,id:g,label:z},k=useNumberFormatter(a),N=useSliderState({...P,numberFormatter:k}),{trackProps:R,groupProps:I,labelProps:B}=useSlider(P,N,w),L=jsx(Me,{variant:"ghost",showStepper:!1,"aria-label":c,"aria-labelledby":B.id,value:N.getThumbValue(0),formatOptions:a,onChange:x=>{N.setThumbValue(0,x);},style:{width:55,textAlign:"right",flexShrink:0}});return jsxs("div",{...I,style:o,"data-block-id":f,"data-block-class":y,className:classNames(on,"BaselineUI-Slider",e),children:[z?jsxs("div",{className:rn,children:[jsx("label",{...B,className:classNames(an({isDisabled:i,hasNumberInput:!!h}),"BaselineUI-Slider-Label"),children:z}),h?L:null]}):null,jsxs("div",{className:tn,children:[jsx("div",{...R,className:classNames(nn,"BaselineUI-Slider-Track"),ref:T(w,C),"data-testid":"track",children:jsx(A1,{state:N,trackRef:w,isDisabled:i,isReadOnly:_})}),h&&!z?L:null]})]})});yo.displayName="Slider";function A1({state:e,trackRef:o,isDisabled:t,isReadOnly:r}){let a=to.useRef(null),{thumbProps:i,inputProps:s,isDragging:n}=useSliderThumb({trackRef:o,inputRef:a},e),{focusProps:p,isFocused:l,isFocusVisible:c}=useFocusRing(),{hoverProps:m,isHovered:u}=useHover({isDisabled:t}),d=filterTruthyValues({"data-disabled":t,"data-readonly":r,"data-hovered":u,"data-focus-visible":c,"data-dragging":n,"data-focused":l});return jsxs(Fragment,{children:[jsx("div",{className:classNames(ln({isDisabled:t,isFocusVisible:c,active:n,isHovered:u}),"BaselineUI-Slider-TrackHighlight"),style:{width:i.style?.left},"data-testid":"track-highlight"}),jsx("div",{...mergeProps(i,m,d),className:classNames(sn({isDisabled:t,isFocusVisible:c,active:n,isReadOnly:r,isHovered:u}),"BaselineUI-Slider-Thumb"),"data-testid":"thumb",children:jsx(VisuallyHidden,{children:jsx("input",{ref:a,...mergeProps(s,p)})})})]})}function bn({ref:e,onIntersect:o,isDisabled:t,threshold:r,rootMargin:a,root:i}){let s=to.useRef(null);useEffect(()=>{if(t){s.current?.disconnect(),s.current=null;return}s.current=new IntersectionObserver(([n])=>{o(n);},{root:i?.current,rootMargin:a,threshold:r});},[o,t,i,a,r]),useEffect(()=>{let{current:n}=s;return e.current&&n?.observe(e.current),()=>n?.disconnect()},[e]);}function gn({ref:e,onResize:o,isDisabled:t}){let r=to.useRef(null),[a,i]=to.useState();return to.useEffect(()=>{if(t){r.current?.disconnect(),r.current=null;return}r.current=new ResizeObserver(([s])=>{i(s.contentRect),o?.(s);});},[o,t,i]),to.useEffect(()=>{let{current:s}=r;return e.current&&s?.observe(e.current),()=>s?.disconnect()},[e]),{size:a}}function bo({src:e,alt:o}){let[t,r]=useState(!1),[a,i]=useState(!1),[s,n]=useState(!1),p=()=>{r(!0),n(!1);},l=()=>{i(!0),n(!1);};return useEffect(()=>{if(!e)return;n(!0);let c=new Image;return c.src=e,c.addEventListener("load",p),c.addEventListener("error",l),()=>{c.removeEventListener("load",p),c.removeEventListener("error",l);}},[e]),{isLoaded:t,hasError:a,isLoading:s,imgProps:{src:t?e:void 0,alt:o}}}function Ae(){let e=useRef(!0);return useEffect(()=>{e.current=!1;},[]),e.current}var vn="SET_STATE",er="UNDO",or="REDO",Y1=(e,o)=>{let{past:t,present:r,future:a}=e;switch(o.type){case vn:return {past:[...t,r],present:o.data,future:[]};case er:return {past:t.slice(0,t?.length-1),present:t[t?.length-1],future:[r,...a]};case or:return {past:[...t,r],present:a[0],future:a.slice(1)};default:throw new Error("Invalid action type")}},_n=(e={},{isDisabled:o,onAction:t})=>{let r=Ae(),[a,i]=useReducer(Y1,{past:[],present:e,future:[]}),{past:s,present:n,future:p}=a,l=y=>{i({type:vn,data:y});},c=useRef(),m=()=>{c.current=er,i({type:er});},u=()=>{c.current=or,i({type:or});},d=!!s?.length,f=!!p?.length;return useGranularEffect(()=>{(c.current===er||c.current===or)&&(t?.(n,c.current),c.current=void 0);},[n],[t,r]),{state:n,push:o?()=>{}:l,undo:o?()=>{}:m,redo:o?()=>{}:u,pastStates:s,futureStates:p,canUndo:d,canRedo:f}};var ka=to.createContext({messages:{}}),xn=({children:e,messages:o={},...t})=>{let r=to.useMemo(()=>({messages:o}),[o]);return jsx(I18nProvider,{...t,children:jsx(ka.Provider,{value:r,children:e})})};xn.displayName="I18nProvider";function F(e){let{messages:o}=useContext(ka);!e&&J1(o)&&console.warn("BUI \u{1F30D}: No messages object provided and no messages found in the `I18nProvider`. Please provide a messages object to the `useI18n` hook.");let t=useMessageFormatter(e?cleanKeyFromGlobImport(e):o),r=useLocale();return {formatMessage:(a,i)=>{if(typeof a=="object")try{return t(a.id,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.id.toString()}\`. The default message, i.e. \`${a.defaultMessage}\`, will be used instead.`),a.defaultMessage||a.id}else try{return t(a,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.toString()}\`. The default message, i.e. \`${a.toString()}\`, will be used instead.`),a}},locale:r}}var $=e=>e;function rT(e,o,t){let r=to.useRef(null);return to.useEffect(()=>{if(e)return r.current=new MutationObserver(t),r.current.observe(e,o),()=>{r.current&&r.current.disconnect();}},[e,o,t]),r.current}function Pn(e,o){let[t,r]=useState(()=>{try{let i=window.localStorage.getItem(e);return i?JSON.parse(i):o}catch(i){return console.log(i),o}});return [t,i=>{try{let s=i instanceof Function?i(t):i;r(s),window.localStorage.setItem(e,JSON.stringify(s));}catch(s){console.log(s);}}]}function cT({ref:e,onSelectionChange:o,onSelectionEnd:t,isDisabled:r}){let a=to.useRef(null);usePress({ref:e,isDisabled:r,onPressEnd(){let s=Q(e.current).getSelection();s&&e.current?.contains(s.anchorNode)&&t?.(s);},onPressStart(){let i=Q(e.current);a.current=i.getSelection(),a.current&&a.current.removeAllRanges();}}),useEffect(()=>{let i=e.current;if(!i||r)return;function s(){let l=Q(i).getSelection();l&&e.current?.contains(l.anchorNode)&&o(l);}let n=be(i);return n.addEventListener("selectionchange",s),()=>{n.removeEventListener("selectionchange",s);}},[e,o,r]);}function go(e){let o=useCallback(()=>{let a=Q(e??document.body),i=a.matchMedia(queries.tablet);return a.matchMedia(queries.desktop).matches?"desktop":i.matches?"tablet":"mobile"},[e]),[t,r]=to.useState(o);return Te(()=>{let a=Q(e),i=()=>{r(o());};return a.addEventListener("resize",i),i(),()=>{a.removeEventListener("resize",i);}},[e,o]),t}var wa=to.createContext(void 0),wn=({portalContainer:e,children:o})=>jsx(wa.Provider,{value:e,children:o});wn.displayName="PortalContainerProvider";function ue(e){let o=useContext(wa);return e||o}var Rn=v({defaultClassName:"_1tkzayn0 _1yep5z6dy",variantClassNames:{size:{sm:"_1tkzayn1",md:"_1tkzayn2",lg:"_1tkzayn3"},type:{subtitle:"_1yep5z6105",title:"_1yep5z6105",label:"_1yep5z6106",value:"_1yep5z6106",helper:"_1yep5z6107",body:"_1yep5z6105"}},defaultVariants:{},compoundVariants:[[{type:"title",size:"sm"},"_1yep5z61jz"],[{type:"title",size:"md"},"_1yep5z61k2"],[{type:"title",size:"lg"},"_1yep5z61k5"],[{type:"body",size:"sm"},"_1yep5z61kp"],[{type:"body",size:"md"},"_1yep5z61ks"],[{type:"body",size:"lg"},"_1yep5z61ks"],[{type:"subtitle",size:"sm"},"_1yep5z61kl"],[{type:"subtitle",size:"md"},"_1yep5z61ko"],[{type:"subtitle",size:"lg"},"_1yep5z61ko"],[{type:"label",size:"md"},"_1yep5z61kn"],[{type:"label",size:"lg"},"_1yep5z61kn"],[{type:"value",size:"md"},"_1yep5z61kn"],[{type:"value",size:"lg"},"_1yep5z61kn"],[{type:"helper",size:"sm"},"_1yep5z61kh"]]});var X=to.forwardRef(({elementType:e="span",type:o="title",children:t,size:r="md",...a},i)=>jsx(e,{...a,className:classNames(Rn({size:r,type:o}),"BaselineUI-Text",a.className),ref:i,children:t}));X.displayName="Text";var In=v({defaultClassName:"siobe21 _1yep5z6ao _1yep5z6ap _1yep5z6aq _1yep5z6bc _1yep5z6bd _1yep5z6be _1yep5z6d7 _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie",variantClassNames:{background:{subtle:"_1yep5z6113",medium:"_1yep5z6114"}},defaultVariants:{},compoundVariants:[]}),Nn="siobe24",Tn="var(--siobe20)";var rr=to.forwardRef(({className:e,style:o,children:t,background:r="medium",title:a,action:i,"data-block-id":s,"data-block-class":n,onCloseRequest:p,...l},c)=>{let{formatMessage:m}=F(),u=to.useRef(null),{dialogProps:d,titleProps:f}=useDialog(l,u);return jsxs("div",{...d,className:classNames(In({background:r}),"BaselineUI-Drawer",e),"data-block-id":s,"data-block-class":n,style:o,ref:T(c,u),children:[jsxs(M,{paddingLeft:"lg",paddingRight:"sm",backgroundColor:"background.primary.subtle",display:"flex",justifyContent:"space-between",alignItems:"center",gap:"lg",className:Nn,children:[jsx(X,{type:"title",size:"sm",...f,className:Js,children:a}),jsxs(M,{children:[i?jsx(D,{...i,variant:"secondary"}):null,jsx(D,{variant:"secondary",size:"md",icon:XIcon,onPress:p,"aria-label":m(vb.close)})]})]}),jsx(O,{variant:r==="subtle"?"primary":"secondary"}),t]})});rr.displayName="Drawer";var vb=$({close:{id:"close",defaultMessage:"Close"}});function Mn(e,o,t){let{isDisabled:r}=e,a=useReducedMotion(),[i,s]=to.useState("100vh");useEffect(()=>{if(!ma()&&!ua())return;let d=Q(t.current);function f(){s(`${d?.visualViewport.height}px`);}return f(),d?.visualViewport.addEventListener("resize",f),()=>{d?.visualViewport.removeEventListener("resize",f);}},[t]);let[{y:n},p]=useSpring(()=>({y:0,immediate:a,config:{easing:easings.easeOutCubic}})),l=useRef(0),c=useCallback(()=>{p.start({y:l.current,onRest:()=>{o.close();}});},[p,o]),m=useCallback(d=>{d.target.closest("[data-drawer]")||c();},[c]);useGranularLayoutEffect(()=>{l.current=t.current?.offsetHeight||0,p.set({y:l.current}),p.start({y:0,immediate:!!a});},[],[p,a]);let u=n.to({range:[0,l.current/2,l.current],output:[.5,.2,0],extrapolate:"clamp"}).to(d=>`rgba(0,0,0,${d})`);return {overlayProps:{style:r?void 0:{transform:n.to(d=>`translateY(${d}px)`)}},underlayProps:{style:r?void 0:{backgroundColor:u},onPointerDown:r?void 0:m},close:c,containerHeight:r?void 0:i}}var Bn=v({defaultClassName:"aml2vl0 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hr _1yep5z6hs _1yep5z6ht",variantClassNames:{enableDrawer:{false:"_1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",true:"aml2vl2"}},defaultVariants:{},compoundVariants:[]}),Dn="_1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6g2 _1yep5z6hr _1yep5z6hs _1yep5z6ht";function Ia(e=window){let[o,t]=useState("light"),[r,a]=useState(!1),[i,s]=useState(!1),[n,p]=useState(!1);return useEffect(()=>{let l=e.matchMedia("(prefers-color-scheme: dark)"),c=m=>{t(m.matches?"dark":"light");};return l.matches&&t("dark"),l.addEventListener("change",c),()=>{l.addEventListener("change",c);}},[e]),useEffect(()=>{let l=e.matchMedia("(prefers-contrast: more)"),c=m=>{a(m.matches);};return a(l.matches),l.addEventListener("change",c),()=>{l.addEventListener("change",c);}},[e]),useEffect(()=>{let l=e.matchMedia("(prefers-reduced-motion: reduce)"),c=m=>{s(m.matches);};return l.matches&&s(!0),l.addEventListener("change",c),()=>{l.addEventListener("change",c);}},[e]),useEffect(()=>{let l=e.matchMedia("(prefers-reduced-transparency: reduce)"),c=m=>{p(m.matches);};return l.matches&&p(!0),l.addEventListener("change",c),()=>{l.addEventListener("change",c);}},[e]),{colorScheme:o,highContrast:r,reducedMotion:i,transparency:n}}var vo=createContext({theme:lightTheme,setTheme:()=>{}});var En="var(--hj25q10)";var sr={LIGHT:{name:"light",theme:lightTheme},DARK:{name:"dark",theme:darkTheme}},_o=to.forwardRef(({theme:e="system",children:o,setTheme:t,className:r,style:a,UNSAFE_domProps:i,"data-block-id":s,"data-block-class":n},p)=>{let{direction:l}=useLocale(),{colorScheme:c,reducedMotion:m,highContrast:u,transparency:d}=Ia(),{name:f,theme:y}=useMemo(()=>{switch(e){case"system":return c==="light"?sr.LIGHT:sr.DARK;case"light":return sr.LIGHT;case"dark":return sr.DARK;default:return {name:"custom",theme:e}}},[c,e]),b=go(),_={"data-theme":f,"data-block-id":s,"data-block-class":n,"data-reduced-motion":m,"data-high-contrast":u,"data-transparency":d,"data-device":b},z=useMemo(()=>({theme:y,setTheme:t}),[y,t]);return jsx(vo.Provider,{value:z,children:jsx("div",{...mergeProps(i,_),className:classNames(Xt,"BaselineUI-ThemeProvider",r),style:{...assignInlineVars(themeVars,y),...assignInlineVars({[En]:l==="rtl"?"-1":"1"}),...a},ref:p,children:o})})});_o.displayName="ThemeProvider";var je=to.createContext({state:null,triggerProps:{},overlayProps:{}}),Ce=({children:e,...o})=>{let t=useOverlayTriggerState(o),{triggerProps:r,overlayProps:a}=useOverlayTrigger({type:"dialog"},t),i=useMemo(()=>({state:t,triggerProps:r,overlayProps:a}),[t,r,a]);return jsx(je.Provider,{value:i,children:e})};Ce.displayName="Modal";var Na=to.createContext({isDrawer:!1,closeDrawer:()=>{}}),Gb=animated(_o),Wb=({children:e,className:o,style:t,isDismissable:r=!0,isKeyboardDismissDisabled:a=!1,portalContainer:i,disableAnimation:s,enableDrawer:n=!1,"data-block-id":p,"data-block-class":l})=>{let{state:c}=to.useContext(je),m=go(i),u=ue(i),d=typeof n=="boolean"&&n||n==="auto"&&m==="mobile";invariant(c,"ModalContent must be a child of Modal");let f=to.useRef(null),y=typeof r=="function"?r(d):r,b=typeof a=="function"?a(d):a,{underlayProps:_,overlayProps:z,close:g,containerHeight:h}=Mn({isDisabled:!d,isDismissable:y},c,f),{modalProps:C,underlayProps:w}=useModalOverlay({isDismissable:!d,isKeyboardDismissDisabled:b},c,f),{theme:P}=useContext(vo),k=useReducedMotion(),N=useSpring({from:{opacity:0,transform:"scale(0.95)"},to:{opacity:1,transform:"scale(1)"},immediate:!!k||s,config:{easing:easings.easeInBounce}}),R=useMemo(()=>({...C.style,...d?{...z.style,width:"100%"}:N}),[z.style,C.style,d,N]),I=useMemo(()=>({isDrawer:d,closeDrawer:g}),[d,g]);return jsx(Overlay,{portalContainer:u,children:jsx(Na.Provider,{value:I,children:jsxs(Gb,{className:classNames(Bn({enableDrawer:d}),o),theme:P,"data-block-id":p,"data-block-class":l,style:{...t,height:d?h:"auto",...assignInlineVars({[Tn]:h})},children:[jsx(animated.div,{...mergeProps(w,_),onPointerDown:d?_.onPointerDown:w.onPointerDown,"data-testid":"underlay",style:_.style,className:classNames(Dn,"BaselineUI-Modal-Underlay")}),jsx(animated.div,{...mergeProps(C,z),style:R,ref:f,"data-drawer":d,className:"BaselineUI-Modal-Content",children:e})]})})})},Xb=animated(Wb),Be=({children:e,style:o,...t})=>{let{state:r}=to.useContext(je);invariant(r,"ModalContent must be a child of Modal");let a=useReducedMotion();return useTransition(r.isOpen,{from:{opacity:0},enter:{opacity:1},immediate:!!a||t.disableAnimation})((s,n)=>n&&jsx(Xb,{...t,style:{...o,...s},children:typeof e=="function"?e({close:r.close}):e}))};var qn=v({defaultClassName:"cjv3et0 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs _1yep5z6d7",variantClassNames:{size:{sm:"cjv3et1",md:"cjv3et2",lg:"cjv3et3",content:"cjv3et4"},variant:{primary:"_1yep5z6121 _1yep5z616i _1yep5z616k",ghost:"cjv3et6"},isDrawer:{true:"cjv3et7 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg _1yep5z6166"}},defaultVariants:{},compoundVariants:[]});var Sa=to.createContext({titleProps:{}}),le=to.forwardRef(({children:e,className:o,style:t,inheritDrawer:r,size:a="md",variant:i="primary","data-block-id":s,"data-block-class":n,drawerBackground:p,...l},c)=>{let m=to.useRef(null),u=to.useRef(null),{isDrawer:d,closeDrawer:f}=useContext(Na),[y,b]=to.useState("");useLayoutEffect(()=>{let h=u.current?.getRootNode(),C=l["aria-label"]||"";l["aria-labelledby"]&&(C=h?.querySelector(`#${l["aria-labelledby"].replaceAll(":","\\:")}`)?.textContent||""),b(C);},[l]);let{dialogProps:_,titleProps:z}=useDialog(l,m),g=useMemo(()=>({titleProps:z}),[z]);return d&&r?jsx(rr,{title:y,onCloseRequest:f,className:o,...l,"data-drawer":!0,"data-block-id":s,"data-block-class":n,ref:T(u,c),background:p,children:e}):jsx(Sa.Provider,{value:g,children:jsx("section",{..._,"data-block-id":s,"data-block-class":n,ref:T(m,c),style:t,className:classNames(qn({size:d?"content":a,variant:i,isDrawer:d}),"BaselineUI-Dialog",o),children:e})})});le.displayName="Dialog";var Gn=to.forwardRef(({children:e,className:o,style:t},r)=>{let{titleProps:a}=useContext(Sa),i=to.isValidElement(e)?Slot:"h3";return jsx(i,{...a,ref:r,className:o,style:t,children:e})});Gn.displayName="DialogTitle";var zo=to.forwardRef(({className:e,style:o,children:t,"data-block-id":r,"data-block-class":a,...i},s)=>{let{theme:n}=useContext(vo);return jsx(Overlay,{...i,children:jsx(_o,{ref:s,theme:n,style:o,className:classNames("BaselineUI-Portal",e),"data-block-id":r,"data-block-class":a,children:t})})});zo.displayName="Portal";function Xn({placement:e}){let o=useReducedMotion();return useTransition(!0,{from:{opacity:0,transform:`translate3d(${e==="bottom"?"0, 4px, 0":"0, -4px, 0"})`},enter:{opacity:1,transform:"translate3d(0, 0, 0)"},immediate:!!o,config:config.stiff})}var{color:La}=themeVars,ce=to.forwardRef(({className:e,style:o,state:t,overlayProps:r,underlayClassName:a,children:i,includeArrow:s=!1,offset:n=2,portalContainer:p,contentContainerClassName:l,contentContainerStyle:c,"data-block-id":m,"data-block-class":u,...d},f)=>{let y=to.useRef(null),b=ue(p),_=s?8:0,{underlayProps:z,popoverProps:g,placement:h,arrowProps:C}=usePopover({...d,offset:n+_,popoverRef:y,containerPadding:d.containerPadding||0},t);delete g.style?.position;let w=Xn({placement:h}),P=h==="center"?"bottom":h;return w((k,N)=>N&&jsxs(zo,{portalContainer:b,style:o,ref:f,"data-block-id":m,"data-block-class":u,children:[!d.isNonModal&&jsx("div",{...z,className:classNames(Ks,a,"BaselineUI-Popover-Underlay")}),jsxs(animated.div,{...g,style:{...g.style,...k,...assignInlineVars({[Gs]:`${d.triggerRef?.current?.offsetWidth}px`})},ref:T(y,f),className:classNames($s,"BaselineUI-Popover-Content",e),"data-placement":["top","bottom","left","right"].filter(R=>h?.includes(R)),children:[s?jsxs("svg",{className:classNames(js[P],"BaselineUI-PopoverContent-Arrow"),...C,style:{...C.style,position:"absolute"},width:"15",height:"9",viewBox:"0 0 15 9",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M.019 0h1.228l6.272 7.237L13.791 0h1.228v1h-.772L7.519 8.763.791 1H.019V0Z",fill:La.border.medium}),jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:La.background.primary.subtle,stroke:La.background.primary.subtle})]}):null,jsx(DismissButton,{onDismiss:t.close}),jsx("div",{...r,style:c,className:classNames(Us,l),children:i}),jsx(DismissButton,{onDismiss:t.close})]})]}))});ce.displayName="PopoverContentCore";var Pe=to.forwardRef((e,o)=>{let{state:t,overlayTriggerAria:{overlayProps:r},triggerRef:a}=useContext(Zo);return invariant(a),t?.isOpen?jsx(ce,{ref:o,...e,triggerRef:e.triggerRef||a,overlayProps:r,state:t}):null});Pe.displayName="PopoverContent";var Qn=v({defaultClassName:"_1mdhlqv3",variantClassNames:{isOpen:{true:"_1mdhlqv4"}},defaultVariants:{},compoundVariants:[]}),xo="_1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Jn=v({defaultClassName:"_1mdhlqv0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6eu _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy",variantClassNames:{isFocused:{false:"_1mdhlqv1"},isDisabled:{true:"z9nup83 _1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),el="_1mdhlqv7 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs",ol="_1yep5z66x _1yep5z66y _1yep5z66z",tl="_1mdhlqv5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k";var rl=v({defaultClassName:"_1jwycy80",variantClassNames:{placement:{bottom:"_1jwycy81",left:"_1jwycy82",right:"_1jwycy83",top:"_1jwycy84"},variant:{default:"_1jwycy85",inverse:"_1jwycy86"}},defaultVariants:{},compoundVariants:[]}),al=v({defaultClassName:"_1jwycy87 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn",variantClassNames:{size:{md:"_1yep5z63u _1yep5z63v _1yep5z63w _1yep5z61i _1yep5z61j _1yep5z61k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6e7",sm:"_1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6dv"},variant:{default:"_1yep5z6g0 _1yep5z6ez",inverse:"_1yep5z6d7 _1yep5z6fs _1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var Ba=to.forwardRef(({children:e,state:o,overlayProps:t,arrowProps:r,placement:a,variant:i,size:s,tooltipProps:n,includeArrow:p},l)=>{let{tooltipProps:c}=useTooltip({isOpen:o.isOpen},o),m=useMemo(()=>{switch(a){case"top":return {x:0,y:4};case"bottom":return {x:0,y:-4};case"left":return {x:4,y:0};case"right":return {x:-4,y:0};default:return {x:0,y:0}}},[a]),u=useReducedMotion(),[d]=useSpring(()=>({from:{opacity:0,transform:`translate(${m.x}px, ${m.y}px)`},to:{opacity:1,transform:"translate(0, 0)"},immediate:!!u})),f=a==="center"?"bottom":a;return jsxs(animated.span,{...t,style:{...d,...t.style},ref:l,"data-placement":f,children:[p?jsx("div",{className:rl({placement:f,variant:i}),...r}):null,jsx("div",{...mergeProps(c,n),className:al({variant:i,size:s}),children:e})]})});Ba.displayName="TooltipContent";var ke=to.forwardRef(({children:e,placement:o="bottom",delay:t=1e3,closeDelay:r=500,variant:a="default",size:i="md",includeArrow:s=!0,portalContainer:n,className:p,style:l,"data-block-id":c,"data-block-class":m,...u},d)=>{let f=to.useRef(null),y=to.useRef(null),b=!u.text||u.isDisabled,_=useTooltipTriggerState({...u,delay:t,closeDelay:r,isDisabled:b}),{triggerProps:z,tooltipProps:g}=useTooltipTrigger({...u,isDisabled:b,delay:t,closeDelay:r},_,f),h=ue(n),{overlayProps:C,arrowProps:w,placement:P,updatePosition:k}=useOverlayPosition({arrowSize:s?13:0,targetRef:f,arrowBoundaryOffset:s?8:0,offset:s?12:2,overlayRef:y,placement:o,isOpen:_.isOpen,...u});return bn({ref:y,threshold:1,onIntersect:k,isDisabled:!_.isOpen}),gn({ref:f,onResize:k,isDisabled:!_.isOpen}),jsxs(FocusableProvider,{...z,ref:f,children:[e,_.isOpen?jsx(zo,{disableFocusManagement:!0,portalContainer:h,className:p,style:l,"data-block-id":c,"data-block-class":m,children:jsx(Ba,{ref:T(d,y),state:_,arrowProps:w,overlayProps:C,placement:P,tooltipProps:g,variant:a,size:i,includeArrow:s,children:u.text})}):null]})});ke.displayName="Tooltip";var pl=to.forwardRef(({className:e,style:o,onChange:t,"data-block-id":r,icon:a,formatValue:i=l=>l,tooltipProps:s,...n},p)=>{let l=ge(p),[c,m]=useControlledState(n.value,n.defaultValue||0,t),[u,d]=to.useState(!1),{keyboardProps:f}=useKeyboard({onKeyDown:_=>{(_.key==="Enter"||_.key==="Escape")&&d(!1);}}),y=i(c||0),b=s?.isDisabled?`${n["aria-label"]}, ${y}`:y.toString();return jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:classNames("BaselineUI-IconSlider",e),"data-block-id":r,style:o,ref:l,children:[a?jsx(a,{size:24,className:sprinkles({color:"icon.primary"})}):null,jsxs(Se,{type:"dialog",isOpen:u,onOpenChange:d,children:[jsx(Le,{children:jsx(ke,{text:n["aria-label"],size:"sm",variant:"inverse",includeArrow:!1,...s,children:jsx(A,{label:y,variant:"popover","aria-label":b,style:{fontVariantNumeric:"tabular-nums"}})})}),jsx(Pe,{className:xo,placement:"bottom start",children:jsx(le,{size:"content",children:jsx(FocusScope,{autoFocus:!0,children:jsx(M,{paddingY:"sm",paddingX:"lg",style:{width:215},...f,children:jsx(yo,{...n,onChange:_=>{m(_),t?.(_);},value:c})})})})})]})]})});pl.displayName="IconSlider";var cl=v({defaultClassName:"bpklwa7",variantClassNames:{isReadOnly:{true:"bpklwa8"},isDisabled:{true:"bpklwa9"},isSelected:{true:"bpklwaa"},isFocused:{true:"bpklwab"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"bpklwac"]]}),dl=v({defaultClassName:"bpklwae",variantClassNames:{isDisabled:{true:"bpklwaf"},isSelected:{true:"bpklwag"},isReadOnly:{true:"bpklwah"}},defaultVariants:{},compoundVariants:[]}),ml="bpklwad",ul=v({defaultClassName:"bpklwa0",variantClassNames:{labelPosition:{top:"bpklwa1",left:"bpklwa2"}},defaultVariants:{},compoundVariants:[]}),fl="bpklwa6",yl=v({defaultClassName:"bpklwa3",variantClassNames:{labelPosition:{top:"bpklwa4",left:"bpklwa5"}},defaultVariants:{},compoundVariants:[]});var _l=to.forwardRef(({className:e,label:o,labelPosition:t="top",statusLabel:r,style:a,"data-block-id":i,"data-block-class":s,...n},p)=>{let l=to.useRef(null),c=useToggleState(n),{inputProps:m,isPressed:u}=useSwitch(n,c,l),{isFocusVisible:d,focusProps:f}=useFocusRing(),{hoverProps:y,isHovered:b}=useHover({isDisabled:n.isDisabled}),_=filterTruthyValues({"data-block-id":i,"data-block-class":s,"data-focused":d,"data-disabled":n.isDisabled,"data-focus-visible":d,"data-selected":c.isSelected,"data-readonly":n.isReadOnly,"data-hovered":b,"data-pressed":u}),z=jsx("div",{className:classNames(cl({isSelected:c.isSelected,isDisabled:!!n.isDisabled,isFocused:d,isReadOnly:!!n.isReadOnly}),"BaselineUI-Switch-Track"),children:jsx("div",{className:classNames(dl({isSelected:c.isSelected,isDisabled:n.isDisabled,isReadOnly:n.isReadOnly}),"BaselineUI-Switch-Knob"),"data-testid":"switch-knob"})});return jsxs("label",{...mergeProps(_,y),className:classNames(ul({labelPosition:t}),"BaselineUI-Switch",e),style:a,ref:p,children:[o?jsx("span",{className:classNames(ml,"BaselineUI-Switch-Label"),children:o}):null,jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(m,f),ref:l})}),r?jsxs("div",{className:yl({labelPosition:t}),children:[jsx("span",{className:classNames("BaselineUI-Switch-Status-Label",fl),children:c.isSelected?r.on:r.off}),z]}):z]})});_l.displayName="Switch";var zl="_19n40yy9",hl=v({defaultClassName:"_19n40yy0",variantClassNames:{size:{lg:"_19n40yy1",md:"_19n40yy2",sm:"_19n40yy3"},variant:{primary:"_19n40yy4",ghost:"_19n40yy5"},isFocused:{true:"_19n40yy6"},hasText:{true:"_19n40yy7"},isDisabled:{true:"_19n40yy8"}},defaultVariants:{},compoundVariants:[]});var Jg={sm:SearchIcon,md:SearchIcon$1,lg:SearchIcon$1},Pl=to.forwardRef(({className:e,size:o="md",variant:t="primary","data-block-id":r,"data-block-class":a,...i},s)=>{let n=to.useRef(null),p=useSearchFieldState(i),{inputProps:l,clearButtonProps:c}=useSearchField({...i,"aria-haspopup":!1,"aria-autocomplete":"none",type:"search"},p,n),{focusProps:m,isFocusVisible:u,isFocused:d}=useFocusRing({within:!0,isTextInput:!0}),f=Jg[o],y=o==="sm"?XIcon$2:XIcon$3,b=filterTruthyValues({"data-block-id":r,"data-block-class":a,"data-focused":d,"data-disabled":i.isDisabled,"data-focus-visible":u});return jsxs("div",{...b,className:classNames(hl({size:o,isFocused:d,variant:t,hasText:!!p.value,isDisabled:i.isDisabled}),"BaselineUI-SearchInput",e),ref:s,children:[jsx(f,{size:o==="sm"?20:24}),jsx("input",{...mergeProps(l,m),className:zl,ref:n}),p.value!==""&&jsx(D,{icon:y,...c,size:o==="sm"?"xs":"sm",variant:"secondary"})]})});Pl.displayName="SearchInput";var kl="xyd2ss1 _1yep5z613 _1yep5z614 _1yep5z615 _1yep5z63f _1yep5z63g _1yep5z63h _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b _1yep5z65r _1yep5z65s _1yep5z65t _1yep5z683 _1yep5z684 _1yep5z685 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z66x _1yep5z66y _1yep5z66z _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6l0 _1yep5z6kz _1yep5z6he _1yep5z6l3 _1yep5z6fs",wl="xyd2ss0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b";var Fa=({section:e,showSelectedIcon:o,state:t})=>{let{itemProps:r,groupProps:a,headingProps:i}=useMenuSection({heading:e.value?.title,"aria-label":e["aria-label"]});return jsxs(Fragment,{children:[e.key!==t.collection.getFirstKey()&&jsx(O,{elementType:"li"}),jsxs("li",{...r,children:[e.value?.title?jsx(VisuallyHidden,{children:jsx("span",{...i,children:e.value.title})}):null,jsx("ul",{...a,className:wl,children:[...e.childNodes].map(s=>(invariant(s.type==="item"),jsx(cr,{item:s,state:t,showSelectedIcon:o},s.key)))})]})]})};Fa.displayName="MenuSection";var cr=({item:e,state:o,className:t,showSelectedIcon:r})=>{let a=to.useRef(null),i=useMenuItem({key:e.key},o,a),{isFocusVisible:s,focusProps:n}=useFocusRing();return jsx(Xo,{item:e,liProps:mergeProps(i.menuItemProps,n,{className:t}),...i,isFocusVisible:s,ref:a,description:e.value?.keyboardShortcut,descriptionProps:i.keyboardShortcutProps,_state:o,showSelectedIcon:r})};cr.displayName="MenuItem";var Oa=to.forwardRef(({className:e,itemClassName:o,onContentKeyDown:t,...r},a)=>{let i=useTreeState(r),s=to.useRef(null),{menuProps:n}=useMenu(r,i,s),{keyboardProps:p}=useKeyboard({onKeyDown:t});return jsx("ul",{...mergeProps(n,p),className:classNames(kl,e),ref:T(s,a),children:[...i.collection].map(l=>l.type==="section"?jsx(Fa,{section:l,state:i,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},l.key):jsx(cr,{item:l,state:i,className:o,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},l.key))})});Oa.displayName="MenuContent";var dr=to.forwardRef(({defaultOpen:e,onOpenChange:o,isOpen:t,isDisabled:r,contentClassName:a,placement:i="bottom start",isNonModal:s,shouldFlip:n,shouldUpdatePosition:p,boundaryElement:l,crossOffset:c,offset:m,triggerLabel:u,renderTrigger:d=({buttonProps:_,ref:z})=>jsx(A,{..._,variant:"popover",ref:z}),portalContainer:f,...y},b)=>{let _=to.useRef(null),z=ue(f),g=useMenuTriggerState({defaultOpen:e,isOpen:t,onOpenChange:o}),{menuTriggerProps:h,menuProps:C}=useMenuTrigger({isDisabled:r,type:"menu"},g,_),w=te(),P=useMemo(()=>mergeProps(h,{isDisabled:r,isSelected:g.isOpen,className:"BaselineUI-Menu-Trigger",label:u}),[h,r,g.isOpen,u]);return useEffect(()=>{!u&&!d&&console.warn("The `triggerLabel` prop is required when no `renderTrigger` or `children` is provided.");},[d,u]),jsxs(Fragment,{children:[d({buttonProps:P,ref:_}),g.isOpen?jsx(ce,{triggerRef:_,state:g,placement:i,isNonModal:s,shouldFlip:n,shouldUpdatePosition:p,boundaryElement:l,crossOffset:c,offset:m||2,className:classNames(xo,"BaselineUI-Menu-Popover"),portalContainer:z,children:jsx(Oa,{className:a,...C,...y,ref:b,autoFocus:g.focusStrategy||"first",children:w})}):null]})});dr.displayName="Menu";var mr=v({defaultClassName:"_13f0naj0",variantClassNames:{variant:{default:"_13f0naj1",inline:"_13f0naj2"},isHovered:{true:"_13f0naj3"},isFocusVisible:{true:"_13f0naj4"},isDisabled:{true:"_13f0naj5"},size:{sm:"_13f0naj6",md:"_13f0naj7",lg:"_13f0naj8"},type:{body:"_13f0naj9",label:"_13f0naja"},isActive:{true:"_13f0najb"}},defaultVariants:{},compoundVariants:[[{isActive:!0,isDisabled:!1},"_13f0najc"],[{type:"body",size:"sm"},"_13f0najd"],[{type:"body",size:"md"},"_13f0naje"],[{type:"body",size:"lg"},"_13f0najf"],[{type:"label",size:"sm"},"_13f0najg"],[{type:"label",size:"md"},"_13f0najh"],[{type:"label",size:"lg"},"_13f0naji"]]});var Sl=to.forwardRef(({className:e,style:o,children:t,variant:r="default",size:a="md",elementType:i="a",type:s="body","data-block-id":n,"data-block-class":p,title:l,...c},m)=>{let u=to.useRef(null),{linkProps:d,isPressed:f}=useLink({...c,elementType:c.onPress?"span":i},u),{isFocusVisible:y,isFocused:b,focusProps:_}=useFocusRing(),{hoverProps:z,isHovered:g}=useHover({isDisabled:c.isDisabled}),h=i,C=filterTruthyValues({"data-block-id":n,"data-block-class":p,"data-disabled":c.isDisabled,"data-focused":b,"data-pressed":f,"data-focus-visible":y,"data-hovered":g,title:l});return jsx(h,{...mergeProps(d,_,z,C),className:classNames(mr({variant:r,isFocusVisible:y,isHovered:g,isDisabled:c.isDisabled,size:a,isActive:f,type:s}),"BaselineUI-Link",e),ref:T(u,m),style:o,children:t})});Sl.displayName="Link";function Ll({isDisabled:e,onValueChange:o,onChange:t,name:r,"aria-describedby":a,"aria-label":i,accept:s,multiple:n}){let p=useId(),l=useId(),c=useId();return {inputProps:{type:"file",id:l,disabled:!!e,"aria-labelledby":i?void 0:p,"aria-describedby":a||c,"aria-label":i,onChange:u=>{let d=[...u.target.files||[]];o?.(d),t?.(u);},name:r,accept:s,multiple:n},labelProps:{htmlFor:l,id:p},descriptionProps:{id:c}}}async function ja({items:e}){let o=e.filter(t=>t.kind==="file").map(async t=>(invariant(t.kind==="file"),t.getFile()));return await Promise.all(o)}var Ml=v({defaultClassName:"_180w5ed0",variantClassNames:{variant:{default:"_180w5ed1",inline:"_180w5ed2"},hoveredOrFocusedOrActive:{true:"_180w5ed3"},disabled:{true:"_180w5ed4"}},defaultVariants:{},compoundVariants:[[{variant:"inline",hoveredOrFocusedOrActive:!0},"_180w5ed5"],[{variant:"default",hoveredOrFocusedOrActive:!0},"_180w5ed6"],[{variant:"default",disabled:!0},"_180w5ed7"],[{variant:"inline",disabled:!0},"_180w5ed8"]]}),Bl=v({defaultClassName:"_180w5ede",variantClassNames:{disabled:{true:"_180w5edf"}},defaultVariants:{},compoundVariants:[]}),Dl=v({defaultClassName:"_180w5ed9",variantClassNames:{disabled:{true:"_180w5eda"}},defaultVariants:{},compoundVariants:[]}),El=v({defaultClassName:"_180w5edb",variantClassNames:{disabled:{true:"_180w5edc"},hovered:{true:"_180w5edd"}},defaultVariants:{},compoundVariants:[]});var Vl=to.forwardRef(({className:e,label:o,description:t,icon:r,variant:a="default",...i},s)=>{let n=to.useRef(null),{inputProps:p,descriptionProps:l,labelProps:c}=Ll(i),{dropProps:m}=useDrop({ref:n,onDrop:async({items:b})=>{let _=b.filter(g=>g.kind==="file").map(async g=>(invariant(g.kind==="file"),g.getFile())),z=await Promise.all(_);i.onValueChange?.(z);}}),{focusProps:u,isFocusVisible:d}=useFocusRing(),{hoverProps:f,isHovered:y}=useHover({isDisabled:i.isDisabled});return jsxs("label",{...mergeProps(m,f,c),className:classNames(Ml({variant:a,disabled:i.isDisabled,hoveredOrFocusedOrActive:y||d}),e),ref:T(s,n),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(u,p)})}),r?jsx(r,{size:20,className:Dl({disabled:i.isDisabled})}):null,jsxs("div",{children:[jsx("div",{className:El({disabled:i.isDisabled,hovered:y}),children:o}),t?jsx("div",{...l,className:Bl({disabled:i.isDisabled}),children:t}):null]})]})});Vl.displayName="FileUpload";var Al="_12vfhl40 z9nup81",jl="_12vfhl41 z9nup82",$l=v({defaultClassName:"_12vfhl48",variantClassNames:{variant:{success:"_12vfhl49",error:"_12vfhl4a",active:"_12vfhl4b"}},defaultVariants:{},compoundVariants:[]}),Ul="_12vfhl42",ql="_12vfhl47",Kl="_12vfhl46 z9nup82",Gl="_12vfhl45",Wl=v({defaultClassName:"_12vfhl43 _12vfhl42",variantClassNames:{hasLabel:{false:"_12vfhl44"}},defaultVariants:{},compoundVariants:[]});var Xl=to.forwardRef(({className:e,style:o,variant:t="active",showValue:r,description:a,errorMessage:i,"data-block-id":s,"data-block-class":n,...p},l)=>{let c=useId(),{labelProps:m,progressBarProps:u}=useProgressBar({...p,"aria-describedby":a?c:p["aria-describedby"]}),{minValue:d=0,maxValue:f=100,value:y=0,label:b}=p,_=(y-d)/(f-d),z=`${Math.round(_*100)}%`,g=jsx("output",{className:Wl({hasLabel:!!b}),children:u["aria-valuetext"]}),h=t==="error"?i:a;return jsxs("div",{...u,style:o,className:classNames(Al,"BaselineUI-ProgressBar",e),"data-block-id":s,"data-block-class":n,ref:l,children:[b?jsxs("div",{className:jl,children:[jsx("label",{...m,className:Ul,children:b}),r?g:null]}):null,jsxs("div",{className:Gl,children:[jsxs("div",{className:Kl,children:[jsx("div",{className:ql,children:jsx("div",{style:{width:z},className:$l({variant:t})})}),!b&&r?g:null]}),h?jsx("div",{className:co({hasError:t==="error"}),id:c,children:h}):null]})]})});Xl.displayName="ProgressBar";function ko({isReadOnly:e,validationState:o}){return e?ReadOnlyIcon:o==="error"?ErrorFilledIcon:o==="warning"?WarningFilledIcon:null}var wo=to.forwardRef(({className:e,validationState:o,variant:t="primary",style:r,labelPosition:a="top",inputStyle:i,inputClassName:s,"data-block-id":n,"data-block-class":p,...l},c)=>{let m=to.useRef(null),{inputProps:u,labelProps:d,descriptionProps:f,errorMessageProps:y,validationErrors:b}=useTextField({...l,validationState:o?o==="error"?"invalid":"valid":void 0},m),_=l.errorMessage||b.join(" "),z=xe({...l,errorMessage:_,descriptionProps:f,errorMessageProps:y,labelPosition:a});_&&(o="error");let{hoverProps:g,isHovered:h}=useHover({isDisabled:l.isDisabled}),{isFocused:C,focusProps:w,isFocusVisible:P}=useFocusRing(),k=ko({isReadOnly:l.isReadOnly,validationState:o}),N=filterTruthyValues({"data-readonly":l.isReadOnly,"data-disabled":l.isDisabled,"data-validation-state":o,"data-focused":C,"data-focus-visible":P});return jsxs("div",{className:classNames(Oe({labelPosition:a}),"BaselineUI-TextInput",e),"data-block-id":n,"data-block-class":p,style:r,ref:c,children:[l.label||a==="start"&&z?jsxs("div",{className:He({labelPosition:a,hasMessage:!!z}),children:[jsx("label",{...d,className:Fe,children:l.label}),a==="start"&&z]}):null,jsxs("div",{className:classNames({[po]:l.isDisabled}),children:[jsxs("div",{...g,className:uo({validationState:o,isHovered:h,isFocused:C,variant:t,isReadOnly:!!l.isReadOnly,isDisabled:!!l.isDisabled}),children:[jsx("input",{...mergeProps(u,w,N),className:classNames(Yt({isDisabled:l.isDisabled,labelPosition:a}),"BaselineUI-TextInput-Input",s),style:i,ref:m}),k?jsx(k,{className:mo({validationState:o,isReadOnly:l.isReadOnly}),size:16}):null]}),a==="top"&&z]})]})});wo.displayName="TextInput";var Ro=({value:e,...o})=>{let t=useNumberFormatter(o);return jsx(Fragment,{children:t.format(e)})};Ro.displayName="NumberFormat";var Zl="_1yep5z6i3 _1yep5z6i4 _1yep5z6i5",Ql=v({defaultClassName:"_9b1tml0",variantClassNames:{isSelected:{true:"_9b1tml1",false:"_9b1tml2"},isDisabled:{true:"z9nup83"},isHovered:{true:"_9b1tml4"},isFocusVisible:{true:"_9b1tml5"},isReadOnly:{true:"_9b1tml6"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0,isReadOnly:!1},"_9b1tml7"],[{isSelected:!0,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml8"],[{isSelected:!1,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml9"],[{isSelected:!0,isDisabled:!0},"_9b1tmla"],[{isSelected:!0,isReadOnly:!0},"_9b1tmlb"]]}),Jl=v({defaultClassName:"_9b1tmlf",variantClassNames:{isSelected:{true:"_9b1tmlg"},size:{sm:"_9b1tmlh",md:"_9b1tmli"},isDisabled:{true:"_9b1tmlj"},isReadOnly:{true:"_9b1tmlk"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"_9b1tmll"],[{isSelected:!0,isDisabled:!0},"_9b1tmlm"],[{isSelected:!1,isDisabled:!0},"_9b1tmln"]]}),ep=v({defaultClassName:"_9b1tmlc",variantClassNames:{isDisabled:{true:"_9b1tmld"},isReadOnly:{true:"_9b1tmle"}},defaultVariants:{},compoundVariants:[]});var rp=to.forwardRef(({className:e,count:o,style:t,size:r="md",icon:a,"data-block-id":i,"data-block-class":s,...n},p)=>{let l={isRequired:!1},c=a||(r==="md"?CheckmarkIcon$2:CheckmarkIcon$3);!n["aria-label"]&&!n["aria-labelledby"]&&console.warn("You must provide either an `aria-label` or `aria-labelledby` prop to the `Reaction` component.");let m=to.useRef(null),u=useToggleState({...n,...l}),{inputProps:d,isPressed:f,isDisabled:y,isReadOnly:b,isSelected:_}=useSwitch({...n,...l},u,m),{focusProps:z,isFocused:g,isFocusVisible:h}=useFocusRing(),{hoverProps:C,isHovered:w}=useHover({}),P=filterTruthyValues({"data-block-id":i,"data-block-class":s,"data-focused":g,"data-focus-visible":h,"data-disabled":y,"data-hovered":w,"data-pressed":f,"data-selected":_});return jsxs("label",{ref:p,style:t,className:classNames(Zl,"BaselineUI-Reaction",e),...P,children:[jsx(VisuallyHidden,{children:jsx("input",{...d,...z,ref:m})}),jsxs("div",{...C,className:Ql({isSelected:_,isFocusVisible:h,isHovered:w,isReadOnly:b,isDisabled:y}),children:[jsx("div",{className:ep({isDisabled:y,isReadOnly:b}),children:jsx(c,{size:r==="md"?20:16})}),jsx("div",{className:Jl({isSelected:u.isSelected,isDisabled:y,isReadOnly:b,size:r}),children:jsx(Ro,{value:o})})]})]})});rp.displayName="Reaction";var ap="_1azy5686",ip="_1azy5685",sp="var(--_1azy5680)",np="_1azy5688",lp="_1azy5689",pp="_1azy5681 z9nup82",cp="_1azy5682";var dp="_1azy5687";var f_={sm:16,md:20},y_={sm:[CheckFilledIcon,ErrorAltFilledIcon],md:[CheckFilledIcon$1,ErrorAltFilledIcon$1]},No=to.forwardRef(({className:e,style:o,size:t="md",variant:r="active","data-block-id":a,"data-block-class":i,...s},n)=>{let{labelProps:p,progressBarProps:l}=useProgressBar({...s,isIndeterminate:!0}),c=f_[t],m=c/2-2,u=2*m*Math.PI,d=y_[t][r==="success"?0:1];return jsxs("div",{className:classNames(pp,"BaselineUI-ProgressSpinner",e),ref:n,style:{...assignInlineVars({[sp]:`${u}px`}),...o},"data-block-id":a,"data-block-class":i,children:[jsxs("div",{...l,className:cp,children:[(r==="active"||r==="inactive")&&jsxs("svg",{height:c,width:c,viewBox:`0 0 ${c} ${c}`,children:[jsx("circle",{role:"presentation",className:ap,cx:c/2,cy:c/2,r:m}),r==="active"&&jsx("circle",{role:"presentation",className:ip,cx:c/2,cy:c/2,r:m})]}),r==="success"&&jsx(d,{className:dp,size:c}),r==="error"&&jsx(d,{className:np,size:c})]}),s.label?jsx("span",{...p,className:lp,children:s.label}):null]})});No.displayName="ProgressSpinner";var mp=v({defaultClassName:"_5uw3kp0 oom8bs0 z9nup82",variantClassNames:{isHovered:{true:"_5uw3kp1"},isFocusVisible:{true:"_5uw3kp2"},isDisabled:{true:"_5uw3kp3"},isSelected:{true:"_5uw3kp4"},size:{sm:"_5uw3kp5",md:"_5uw3kp6",lg:"_5uw3kp7"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0},"_5uw3kp8"],[{isSelected:!0,isDisabled:!0},"_5uw3kp9"]]});var C_={sm:16,md:20,lg:24},yr=to.forwardRef(({className:e,style:o,iconStart:t,size:r="md",elementType:a="button",...i},s)=>{let n=useToggleState(i),{buttonProps:p,isPressed:l,ref:c}=Gt(i,n),{hoverProps:m,isHovered:u}=useHover({isDisabled:i.isDisabled}),{isFocusVisible:d,isFocused:f,focusProps:y}=useFocusRing(),b=filterTruthyValues({"data-block-id":i["data-block-id"],"data-block-class":i["data-block-class"],"data-focused":f,"data-focus-visible":d,"data-disabled":i.isDisabled,"data-hovered":u,"data-pressed":l,"data-selected":n.isSelected});return jsxs(a,{...mergeProps(p,m,y,b),className:classNames(mp({isHovered:u,isFocusVisible:d,isSelected:n.isSelected,size:r,isDisabled:i.isDisabled}),"BaselineUI-ToggleButton",e),style:o,ref:T(c,s),children:[t?jsx(t,{size:C_[r]}):null,i.label]})});yr.displayName="ToggleButton";var br=v({defaultClassName:"_16vugd0e",variantClassNames:{isDisabled:{true:"_16vugd0f"}},defaultVariants:{},compoundVariants:[]}),up=v({defaultClassName:"_16vugd01 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),fp=v({defaultClassName:"_16vugd05",variantClassNames:{isIndeterminate:{true:"_16vugd04"},isSelected:{true:"_16vugd04"},isFocusVisible:{true:"_16vugd08"},isHovered:{true:"_16vugd09"},isDisabled:{true:"_16vugd0a"},isReadOnly:{true:"_16vugd0b"},hasError:{true:"_16vugd0c"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_16vugd0d"]]});var gp=to.forwardRef(({className:e,style:o,label:t,labelPosition:r="end","data-block-id":a,"data-block-class":i,...s},n)=>{let p=to.useRef(null),l=useToggleState(s),{isFocusVisible:c,isFocused:m,focusProps:u}=useFocusRing(),{inputProps:d,isPressed:f,isDisabled:y,isSelected:b,isReadOnly:_}=useCheckbox({...s,children:t},l,p),{hoverProps:z,isHovered:g}=useHover({isDisabled:y}),h=filterTruthyValues({"data-disabled":y,"data-readonly":_,"data-hovered":g,"data-selected":b,"data-pressed":f,"data-indeterminate":s.isIndeterminate,"data-invalid":s.isInvalid,"data-focus-visible":c,"data-focused":m,"data-block-id":a,"data-block-class":i});return jsxs("label",{...h,className:classNames(up({labelPosition:r}),"BaselineUI-Checkbox",e),style:o,ref:n,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(d,u),ref:p})}),jsxs("div",{...z,className:fp({isSelected:b&&!s.isIndeterminate,isIndeterminate:s.isIndeterminate,isFocusVisible:c,isDisabled:y,isReadOnly:_,hasError:s.isInvalid,isHovered:g}),children:[b&&!s.isIndeterminate?jsx(CheckmarkIcon$1,{size:12}):null,s.isIndeterminate?jsx(MinusIcon$1,{size:12}):null]}),t?jsx("span",{className:br({isDisabled:y}),children:t}):null]})});gp.displayName="Checkbox";var vp={ar:{goToPage:"\u0627\u0646\u062A\u0642\u0627\u0644 \u0625\u0644\u0649 \u0635\u0641\u062D\u0629",nextPage:"\u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u062A\u0627\u0644\u064A\u0629",pageXofY:"\u0635\u0641\u062D\u0629 {arg0} \u0645\u0646 {arg1}",prevPage:"\u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u0633\u0627\u0628\u0642\u0629"},cs:{goToPage:"P\u0159ej\xEDt na stranu",nextPage:"Dal\u0161\xED str\xE1nka",pageXofY:"Strana {arg0} z {arg1}",prevPage:"P\u0159edchoz\xED strana"},cy:{goToPage:"Mynd i Dudalen",nextPage:"Tudalen Nesaf",pageXofY:"Tudalen {arg0} o {arg1}",prevPage:"Tudalen Blaenorol"},da:{goToPage:"G\xE5 til side",nextPage:"N\xE6ste side",pageXofY:"Side {arg0} af {arg1}",prevPage:"Forrige side"},de:{goToPage:"Zu Seite wechseln",nextPage:"N\xE4chste Seite",pageXofY:"Seite {arg0} von {arg1}",prevPage:"Vorherige Seite"},el:{goToPage:"\u039C\u03B5\u03C4\u03AC\u03B2\u03B1\u03C3\u03B7 \u03C3\u03C4\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1",nextPage:"\u0395\u03C0\u03CC\u03BC\u03B5\u03BD\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1",pageXofY:"\u03A3\u03B5\u03BB\u03AF\u03B4\u03B1 {arg0} \u03B1\u03C0\u03CC {arg1}",prevPage:"\u03A0\u03C1\u03BF\u03B7\u03B3\u03BF\u03CD\u03BC\u03B5\u03BD\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1"},"en-GB":{goToPage:"Go to Page",nextPage:"Next Page",pageXofY:"Page {arg0} of {arg1}",prevPage:"Previous Page"},en:{goToPage:"Go to Page",nextPage:"Next Page",pageXofY:"Page {arg0} of {arg1}",prevPage:"Previous Page"},es:{goToPage:"Ir a la p\xE1gina",nextPage:"P\xE1gina siguiente",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina anterior"},fi:{goToPage:"Mene sivulle",nextPage:"Seuraava sivu",pageXofY:"Sivu {arg0} / {arg1}",prevPage:"Edellinen sivu"},"fr-CA":{goToPage:"Aller \xE0 la page",nextPage:"Page suivante",pageXofY:"Page {arg0} sur {arg1}",prevPage:"Page pr\xE9c\xE9dente"},fr:{goToPage:"Aller \xE0 la page",nextPage:"Page suivante",pageXofY:"Page {arg0} sur {arg1}",prevPage:"Page pr\xE9c\xE9dente"},he:{goToPage:"\u05DE\u05E2\u05D1\u05E8 \u05DC\u05E2\u05DE\u05D5\u05D3",nextPage:"\u05D4\u05E2\u05DE\u05D5\u05D3 \u05D4\u05D1\u05D0",pageXofY:"\u05E2\u05DE\u05D5\u05D3 {arg0} \u05DE\u05EA\u05D5\u05DA {arg1}",prevPage:"\u05D4\u05E2\u05DE\u05D5\u05D3 \u05D4\u05E7\u05D5\u05D3\u05DD"},hr:{goToPage:"Idi na stranicu",nextPage:"Slijede\u0107a stranica",pageXofY:"Stranica {arg0} od {arg1}",prevPage:"Prethodna stranica"},id:{goToPage:"Buka halaman",nextPage:"Halaman Berikutnya",pageXofY:"Halaman {arg0} dari {arg1}",prevPage:"Halaman Sebelumnya"},it:{goToPage:"Vai a pagina",nextPage:"Pagina successiva",pageXofY:"Pagina {arg0} di {arg1}",prevPage:"Pagina precedente"},ja:{goToPage:"\u30DA\u30FC\u30B8\u306B\u79FB\u52D5",nextPage:"\u6B21\u306E\u30DA\u30FC\u30B8",pageXofY:"\u30DA\u30FC\u30B8 {arg0}/{arg1}",prevPage:"\u524D\u306E\u30DA\u30FC\u30B8"},ko:{goToPage:"\uD398\uC774\uC9C0\uB85C \uC774\uB3D9",nextPage:"\uB2E4\uC74C \uD398\uC774\uC9C0",pageXofY:"{arg0}/{arg1} \uD398\uC774\uC9C0",prevPage:"\uC774\uC804 \uD398\uC774\uC9C0"},ms:{goToPage:"Pergi ke Halaman",nextPage:"Halaman Seterusnya",pageXofY:"Halaman {arg0} daripada {arg1}",prevPage:"Halaman Sebelumnya"},"nb-NO":{goToPage:"G\xE5 til side",nextPage:"Neste side",pageXofY:"Side {arg0} av {arg1}",prevPage:"Forrige side"},nl:{goToPage:"Ga naar pagina",nextPage:"Volgende pagina",pageXofY:"Pagina {arg0} van {arg1}",prevPage:"Vorige pagina"},pl:{goToPage:"Przejd\u017A do strony",nextPage:"Nast\u0119pna strona",pageXofY:"Strona {arg0} z {arg1}",prevPage:"Poprzednia strona"},"pt-PT":{goToPage:"Ir para p\xE1gina",nextPage:"P\xE1gina seguinte",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina anterior"},pt:{goToPage:"Ir \xE0 P\xE1gina",nextPage:"P\xE1gina Seguinte",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina Anterior"},ru:{goToPage:"\u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u043A \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0435",nextPage:"\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430",pageXofY:"\u0421\u0442\u0440\u0430\u043D\u0438\u0446\u0430 {arg0} \u0438\u0437 {arg1}",prevPage:"\u041F\u0440\u0435\u0434\u044B\u0434\u0443\u0449\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430"},sk:{goToPage:"\xCDs\u0165 na stranu",nextPage:"Dal\u0161ia strana",pageXofY:"Strana {arg0} z {arg1}",prevPage:"Predch\xE1dzaj\xFAca strana"},sl:{goToPage:"Pojdi na stran",nextPage:"Naslednja stran",pageXofY:"Stran {arg0} od {arg1}",prevPage:"Prej\u0161nja stran"},sv:{goToPage:"G\xE5 till sida",nextPage:"N\xE4sta sida",pageXofY:"Sida {arg0} av {arg1}",prevPage:"F\xF6reg\xE5ende sida"},th:{goToPage:"\u0E44\u0E1B\u0E17\u0E35\u0E48\u0E2B\u0E19\u0E49\u0E32",nextPage:"\u0E2B\u0E19\u0E49\u0E32\u0E16\u0E31\u0E14\u0E44\u0E1B",pageXofY:"\u0E2B\u0E19\u0E49\u0E32 {arg0} \u0E08\u0E32\u0E01 {arg1}",prevPage:"\u0E2B\u0E19\u0E49\u0E32\u0E01\u0E48\u0E2D\u0E19\u0E2B\u0E19\u0E49\u0E32"},tr:{goToPage:"Sayfaya Git",nextPage:"Sonraki Sayfa",pageXofY:"Sayfa {arg0}/{arg1}",prevPage:"\xD6nceki Sayfa"},uk:{goToPage:"\u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u043D\u0430 \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0443",nextPage:"\u041D\u0430\u0441\u0442\u0443\u043F\u043D\u0430 \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0430",pageXofY:"\u0421\u0442\u043E\u0440\u0456\u043D\u043A\u0430 {arg0} \u0437 {arg1}",prevPage:"\u041F\u043E\u043F\u0435\u0440\u0435\u0434\u043D\u044F \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0430"},"zh-Hans":{goToPage:"\u524D\u5F80\u9875\u9762",nextPage:"\u4E0B\u4E00\u9875",pageXofY:"\u7B2C {arg0}/{arg1} \u9875",prevPage:"\u4E0A\u4E00\u9875"},"zh-Hant":{goToPage:"\u5230\u6B64\u9801",nextPage:"\u4E0B\u4E00\u9801",pageXofY:"\u7B2C{arg0}\u9801\uFF0C\u5171{arg1}\u9801",prevPage:"\u4E0A\u4E00\u9801"}};var _p=v({defaultClassName:"_1nsi9h17",variantClassNames:{isFocusVisible:{true:"_1nsi9h18"},variant:{pinned:"_1nsi9h19",floating:"_1nsi9h1a"}},defaultVariants:{},compoundVariants:[]}),zp="_1nsi9h1b",hp=v({defaultClassName:"_1nsi9h10",variantClassNames:{size:{xs:"_1nsi9h11",sm:"_1nsi9h12",md:"_1nsi9h13",lg:"_1nsi9h14"},variant:{floating:"_1nsi9h15",pinned:"_1nsi9h16"}},defaultVariants:{},compoundVariants:[]}),xp="_1nsi9h1c";var Z_={style:"decimal"},Q_={xs:[CaretLeftIcon,CaretRightIcon],sm:[CaretLeftIcon$1,CaretRightIcon$1],md:[CaretLeftIcon$2,CaretRightIcon$2],lg:[CaretLeftIcon$3,CaretRightIcon$3]},wp=to.forwardRef(({className:e,style:o,minValue:t=1,defaultValue:r=1,incrementAriaLabel:a,decrementAriaLabel:i,"aria-label":s,size:n="md",variant:p="floating",...l},c)=>{let{locale:m}=useLocale(),u=F(vp),d={...l,formatOptions:Z_,minValue:t,incrementAriaLabel:a||u.formatMessage("nextPage"),decrementAriaLabel:i||u.formatMessage("prevPage"),defaultValue:r,"aria-label":s||u.formatMessage("goToPage")},f=to.useRef(null),y=useNumberFieldState({...d,locale:m}),{inputProps:b,decrementButtonProps:_,incrementButtonProps:z,groupProps:g}=useNumberField({...d,onKeyDown:L=>{L.key==="Enter"&&f.current?.blur(),l.onKeyDown?.(L);}},y,f),{hoverProps:h,isHovered:C}=useHover({}),{focusProps:w,isFocused:P,isFocusVisible:k}=useFocusRing(),N=p==="floating",[R,I]=Q_[n],B=filterTruthyValues({"data-focus-visible":k,"data-focused":P,"data-hovered":C,"data-block-id":l["data-block-id"],"data-block-class":l["data-block-class"]});return jsxs("div",{...mergeProps(g,h,B),className:classNames(hp({size:n,variant:p}),"BaselineUI-Pagination",e),style:o,ref:c,children:[jsx(D,{icon:R,..._,elementType:"div",size:n,style:{height:"100%",...N&&{borderRadius:0}},className:"BaselineUI-Pagination-DecrementButton"}),p==="floating"&&jsx(O,{orientation:"vertical"}),jsxs("div",{className:_p({isFocusVisible:k,variant:p}),"aria-label":u.formatMessage("pageXofY",{arg0:b.value,arg1:y.maxValue}),children:[jsx("input",{...mergeProps(b,w),ref:f,className:classNames("BaselineUI-Pagination-Input",zp),style:{width:`${b.value?.toString().length||1}ch`}}),jsxs("span",{className:xp,children:["/ ",jsx(Ro,{value:y.maxValue})]})]}),p==="floating"&&jsx(O,{orientation:"vertical"}),jsx(D,{icon:I,...z,elementType:"div",size:n,style:{height:"100%",...N&&{borderRadius:0}},className:"BaselineUI-Pagination-IncrementButton"})]})});wp.displayName="Pagination";var Rp=({date:e,...o})=>{let t=useDateFormatter(o);return jsx(Fragment,{children:t.format(e)})};Rp.displayName="DateFormat";var gr=v({defaultClassName:"_1f789qj1",variantClassNames:{isFocusVisible:{true:"_1f789qj2"},variant:{neutral:"_1f789qj3",red:"_1f789qj4",green:"_1f789qj5",blue:"_1f789qj6","high-contrast":"_1f789qj7"},isDisabled:{true:"_1f789qj8"},allowsRemoving:{true:"_1f789qj9"},isSelected:{true:"_1f789qja"},allowsSelection:{true:"_1f789qjb"},isHovered:{true:"_1f789qjc"}},defaultVariants:{},compoundVariants:[[{allowsSelection:!0,isHovered:!0,variant:"neutral"},"_1f789qjd"],[{allowsSelection:!0,isHovered:!0,variant:"red"},"_1f789qje"],[{allowsSelection:!0,isHovered:!0,variant:"blue"},"_1f789qjf"],[{allowsSelection:!0,isHovered:!0,variant:"green"},"_1f789qjg"],[{allowsSelection:!0,isHovered:!0,variant:"high-contrast"},"_1f789qjh"],[{allowsSelection:!0,isSelected:!0,isHovered:!0},"_1f789qji"]]}),Ip="_1f789qjj",Np="_1f789qj0",Tp=v({defaultClassName:"_1f789qjk",variantClassNames:{variant:{neutral:"_1f789qjl",red:"_1f789qjm",green:"_1f789qjn",blue:"_1f789qjo","high-contrast":"_1f789qjp"},isHovered:{true:"_1f789qjq"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,variant:"neutral"},"_1f789qjr"],[{isHovered:!0,variant:"red"},"_1f789qjs"],[{isHovered:!0,variant:"blue"},"_1f789qjt"],[{isHovered:!0,variant:"green"},"_1f789qju"],[{isHovered:!0,variant:"high-contrast"},"_1f789qjv"]]});var Bp=({item:e,state:o,variant:t="neutral"})=>{let r=to.useRef(null),{focusProps:a,isFocusVisible:i}=useFocusRing({within:!0}),{rowProps:s,gridCellProps:n,removeButtonProps:p,allowsRemoving:l,isDisabled:c,isSelected:m,allowsSelection:u}=useTag({item:e},o,r),d=to.useRef(null),{buttonProps:f}=useButton(p,d),{hoverProps:y,isHovered:b}=useHover({isDisabled:c}),{hoverProps:_,isHovered:z}=useHover({isDisabled:c}),g=e.value?.icon,h=e.value?.data?.variant??t;return jsx("div",{...mergeProps(s,a,_),ref:r,className:classNames(gr({isFocusVisible:i,variant:h,isDisabled:c,allowsRemoving:l,isSelected:m,allowsSelection:u,isHovered:z}),"BaselineUI-Tag"),children:jsxs("div",{...n,className:Ip,children:[m?jsx(CheckmarkIcon$3,{size:16}):null,!m&&g?jsx(g,{size:16}):null,e.rendered,l?jsx("button",{...mergeProps(f,y),className:Tp({variant:h,isHovered:b}),children:jsx(XIcon$2,{})}):null]})})};var Fp=to.forwardRef(({className:e,style:o,"data-block-id":t,"data-block-class":r,items:a,...i},s)=>{let n=useMemo(()=>a.map(u=>({...u,data:{variant:u.variant}})),[a]),p=te(),l=to.useRef(null),c=useListState({...i,items:n,children:p}),{gridProps:m}=useTagGroup(i,c,l);return jsx("div",{...m,className:classNames(Np,"BaselineUI-TagGroup",e),style:o,"data-block-id":t,"data-block-class":r,ref:T(s,l),children:[...c.collection].map(u=>jsx(Bp,{state:c,item:u,variant:i.variant},u.key))})});Fp.displayName="TagGroup";var Hp="_1yep5z6kv",Op=v({defaultClassName:"_1kvz17db _1yep5z6ki _1yep5z6kk",variantClassNames:{showActionsOnTriggerOnly:{true:"_1kvz17dc"},isTriggered:{true:"_1kvz17dd"}},defaultVariants:{},compoundVariants:[]}),Vp=v({defaultClassName:"_1kvz17d0 _1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z68c _1yep5z68d _1yep5z68e _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6ki _1yep5z6kj",variantClassNames:{isExpanded:{true:"_1kvz17d1"}},defaultVariants:{},compoundVariants:[]}),Ap="_1yep5z6ev _1yep5z6dy",jp=v({defaultClassName:"_1kvz17d2 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ki _1yep5z6kl",variantClassNames:{isFocusVisible:{true:"_1kvz17d3"},isHovered:{true:"_1yep5z6ft",false:"_1yep5z6fu"},isDisabled:{true:"z9nup83"}},defaultVariants:{},compoundVariants:[]}),$p="_1kvz17da _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6dz",Up=v({defaultClassName:"_1kvz17d7 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{isDisabled:{true:"_1yep5z6ey",false:"_1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var Wa=to.forwardRef(({children:e,className:o,style:t},r)=>{let{headers:a}=useContext($e),{disabledKeys:i}=useContext($e),{keyboardProps:s}=useKeyboard({onKeyDown:n=>{let p=At(n.target),l=[...a?.keys()||[]].findIndex(f=>a?.get(f)?.current===p?.activeElement),c=a?.get(l||0),m=a?.size||0,u=f=>{let y=a.get(f-1<0?m-1:f-1);i?.has(y?.current?.getAttribute("data-key")||"")?u(f-1):y?.current?.focus();},d=f=>{let y=a.get((f+1)%m);i?.has(y?.current?.getAttribute("data-key")||"")?d(f+1):y?.current?.focus();};if(c)switch(n.key){case"Home":{n.preventDefault(),d(-1);break}case"End":{n.preventDefault(),u(m);break}case"ArrowDown":{n.preventDefault(),d(l);break}case"ArrowUp":{n.preventDefault(),u(l);break}default:n.continuePropagation();}}});return jsx("div",{...s,style:t,className:classNames(Hp,o),ref:r,children:to.Children.map(e,(n,p)=>to.cloneElement(n,{index:p}))})});Wa.displayName="AccordionBase";var $e=to.createContext({expandedKeys:new Set,setExpandedKeys:()=>{},disabledKeys:new Set,headers:new Map,expansionMode:"multiple"}),Gp=to.forwardRef(({children:e,disabledKeys:o,defaultExpandedKeys:t=new Set,expandedKeys:r,expansionMode:a="multiple",onChange:i,className:s,style:n},p)=>{let[l,c]=to.useState(t),m=to.useRef(new Map).current,[u,d]=to.useState(a);useEffect(()=>{d(u);},[u]),useEffect(()=>{i?.(l);},[l,i]);let f=useMemo(()=>({expandedKeys:r||l,setExpandedKeys:r?()=>{}:c,disabledKeys:o,headers:m,expansionMode:u}),[r,l,o,m,u]);return jsx($e.Provider,{value:f,children:jsx(FocusScope,{children:jsx(Wa,{className:s,style:n,ref:p,children:e})})})});Gp.displayName="Accordion";var Ya=to.forwardRef(({title:e,actions:o,controlId:t,value:r,id:a,index:i,subLabel:s,showActionsOnTriggerOnly:n},p)=>{let l=to.useRef(null),{expandedKeys:c,setExpandedKeys:m,expansionMode:u,disabledKeys:d,headers:f}=useContext($e),y=d?.has(r),b=useFocusManager();invariant(b);let{focusNext:_,focusPrevious:z}=b,{keyboardProps:g}=useKeyboard({onKeyDown:x=>{x.key==="ArrowRight"?_({wrap:!0}):x.key==="ArrowLeft"?z({wrap:!0}):x.continuePropagation();},isDisabled:y});useEffect(()=>{invariant(typeof i=="number","AccordionItem must have an index"),f?.set(i,l);},[i,f]);let h=()=>{m(x=>{let S=new Set(x);return S.has(r)?S.delete(r):(u==="single"&&S.clear(),S.add(r)),S});},{buttonProps:C}=useButton({"aria-expanded":c.has(r),"aria-controls":t,onPress:h,isDisabled:y},l),{pressProps:w}=usePress({onPress:h,isDisabled:y}),{focusProps:P,isFocusVisible:k}=useFocusRing(),{hoverProps:N,isHovered:R}=useHover({isDisabled:y}),{focusProps:I,isFocusVisible:B}=useFocusRing({within:!0}),L=c.has(r);return jsxs("h3",{...mergeProps(g,w,N,I),className:jp({isFocusVisible:k,isHovered:R,isDisabled:y}),ref:p,children:[jsxs("div",{className:Up({isDisabled:!!y}),children:[jsx(ChevronRightIcon,{className:Vp({isExpanded:L}),size:8}),jsx("button",{...mergeProps(C,P),id:a,"data-key":r,className:$p,ref:l,children:e})]}),o?.length?jsx("div",{"data-testid":"action-buttons",className:Op({showActionsOnTriggerOnly:n,isTriggered:B||R}),children:o.map((x,S)=>jsx(D,{variant:"secondary",size:"sm",excludeFromTabOrder:!0,isDisabled:y,...x},S))}):null,s?jsx("div",{className:Ap,children:s}):null]})});Ya.displayName="AccordionHeader";var oc=to.forwardRef(({title:e,actions:o,children:t,value:r,index:a,subLabel:i,style:s,className:n,showActionsOnTriggerOnly:p},l)=>{let c=useId(),m=useId(),{expandedKeys:u}=useContext($e),d=to.useRef(null),f=u.has(r),y=Ae(),b=useReducedMotion(),_=useTransition(f?[r]:[],{from:!y&&!b&&{height:0,opacity:0},enter:()=>async z=>{await z({height:d.current?.scrollHeight,opacity:1});},leave:{height:0,opacity:0},keys:z=>z});return jsxs(Fragment,{children:[jsx(FocusScope,{children:jsx(Ya,{value:r,actions:o,id:m,title:e,controlId:c,ref:l,index:a,subLabel:i,showActionsOnTriggerOnly:p})}),_(z=>jsx(animated.div,{role:"region","aria-labelledby":m,id:c,style:{...z,overflow:"hidden"},children:jsx("div",{ref:d,className:n,style:s,children:t})}))]})});oc.displayName="AccordionItem";var ct=to.forwardRef(({variant:e,isOpen:o,selectedIcon:t,validationState:r="valid",valueProps:a,label:i,...s},n)=>{let p=to.useRef(null),{buttonProps:l,isPressed:c}=useButton({...s,isDisabled:s.isDisabled||s.isReadOnly},p),{hoverProps:m,isHovered:u}=useHover({isDisabled:s.isDisabled}),{focusProps:d,isFocused:f,isFocusVisible:y}=useFocusRing(),b=ko({isReadOnly:s.isReadOnly,validationState:r});s.isReadOnly&&(l.disabled=!1);let _=filterTruthyValues({"data-disabled":s.isDisabled,"data-readonly":s.isReadOnly,"data-focused":f,"data-focus-visible":y,"data-hovered":u,"data-pressed":c,"data-open":o});return jsxs("button",{...mergeProps(l,m,d,_),ref:T(n,p),className:classNames(Jn({isFocused:y,isDisabled:s.isDisabled}),uo({variant:e,isHovered:u,isFocused:y,validationState:r,isDisabled:!!s.isDisabled,isReadOnly:s.isReadOnly}),"BaselineUI-Select-Button"),children:[jsxs("span",{className:tl,children:[t?jsx(t,{size:24}):null,jsx("span",{...a,children:i})]}),b?jsx("span",{"aria-hidden":!0,className:classNames(mo({validationState:r,isReadOnly:!!s.isReadOnly}),ol),children:jsx(b,{size:16})}):null,jsx("span",{"aria-hidden":!0,children:jsx(ChevronDownIcon,{size:8,className:Qn({isOpen:o})})})]})});ct.displayName="SelectButton";var Ja=to.createContext(null),ei=to.forwardRef(({className:e,style:o,labelPosition:t="top",variant:r="primary","data-block-id":a,"data-block-class":i,optionStyle:s,optionClassName:n,placement:p="bottom start",state:l,renderTrigger:c=({buttonProps:d,selectedValue:f,valueProps:y,isOpen:b,ref:_})=>{let z=f&&"icon"in f&&f.icon;return jsx(ct,{...d,isOpen:b,isReadOnly:m.isReadOnly,ref:_,variant:r,validationState:m.validationState,selectedIcon:z||void 0,label:f?"label"in f&&f?.label:m.placeholder,valueProps:y})},...m},u)=>{let d=to.useRef(null),f=ue(m.portalContainer),{labelProps:y,triggerProps:b,valueProps:_,menuProps:z,descriptionProps:g,errorMessageProps:h}=useSelect({...m,validationState:m.validationState==="error"?"invalid":"valid"},l,d),C=xe({...m,descriptionProps:g,errorMessageProps:h,labelPosition:t}),w=l.selectedItem?.value??null;return jsxs(Ze.Provider,{value:l,children:[jsxs("div",{style:o,className:classNames(Oe({labelPosition:t}),"BaselineUI-Select",e),"data-block-id":a,"data-block-class":i,ref:u,children:[m.label||C?jsxs("div",{className:He({labelPosition:t,hasMessage:!!C}),children:[m.label?jsx("div",{...y,className:classNames(Fe,"BaselineUI-Select-Label"),children:m.label}):null,t==="start"&&C]}):null,jsx(HiddenSelect,{state:l,triggerRef:d,isDisabled:m.isDisabled,label:m.label,name:m.name}),c({buttonProps:b,selectedValue:w,valueProps:_,isOpen:l.isOpen,ref:d}),t==="top"&&C]}),l.isOpen?jsx(ce,{placement:p,portalContainer:f,offset:2,state:l,triggerRef:d,style:o,className:classNames(xo,"BaselineUI-Select-Popover"),...m,children:jsx(re,{...z,label:m.label,items:m.items,showSelectedIcon:m.showSelectedIcon,className:el,optionStyle:s,optionClassName:n})}):null]})});ei.displayName="SelectCore";var ic=to.forwardRef((e,o)=>{let t=te(),r=useSelectState({...e,validationState:e.validationState==="error"?"invalid":"valid",children:t});return jsx(ei,{...e,ref:o,state:r})});ic.displayName="SelectStandalone";var qe=to.forwardRef((e,o)=>{let t=useContext(Ja);return useEffect(()=>{invariant(t||e.items,"Select: A `state` that can be passed via context or `items` are required.");},[e.items,t]),t?jsx(ei,{state:t,...e,ref:o}):jsx(ic,{...e,ref:o})});qe.displayName="Select";var nc=to.forwardRef(({className:e,style:o,variant:t,"data-block-id":r,icon:a,tooltipProps:i,...s},n)=>{let p=to.useRef(null),l=useCallback(({buttonProps:c,selectedValue:m,valueProps:u,isOpen:d,ref:f})=>{let y=m&&"icon"in m&&m.icon;return jsx(ke,{variant:"inverse",size:"sm",includeArrow:!1,text:s["aria-label"],offset:4,...i,children:jsx(ct,{...c,isOpen:d,isReadOnly:s.isReadOnly,ref:f,variant:t,validationState:s.validationState,selectedIcon:y||void 0,label:m?"label"in m&&m?.label:s.placeholder,valueProps:u})})},[s,i,t]);return jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:classNames("BaselineUI-IconSelect",e),"data-block-id":r,style:o,ref:T(n,p),children:[a?jsx(a,{size:24,className:sprinkles({color:"icon.primary"})}):null,jsx(qe,{...s,renderTrigger:l})]})});nc.displayName="IconSelect";var lc="_1017q4c5",pc=v({defaultClassName:"_1017q4c0",variantClassNames:{size:{md:"_1017q4c1",sm:"_1017q4c2"},isDisabled:{true:"_1017q4c3"}},defaultVariants:{},compoundVariants:[]}),cc="_1017q4c4";var J6={sm:AvatarIcon,md:AvatarIcon$1},Lo=to.forwardRef(({className:e,style:o,size:t="md",icon:r=J6[t],name:a,imgSrc:i,showInitials:s,isDisabled:n,hasNotifications:p,imgLoading:l,"data-block-id":c,"data-block-class":m},u)=>{let{imgProps:d}=bo({src:i,alt:a}),f=a?.split(" ").map(y=>y[0]).join("");return jsxs("span",{className:classNames(pc({size:t,isDisabled:n}),"BaselineUI-Avatar",e),"data-disabled":n,ref:u,style:o,"aria-disabled":n,"data-block-id":c,"data-block-class":m,children:[i?jsx("img",{...d,loading:l,className:cc}):null,!s&&!i&&jsx(r,{size:t==="sm"?16:24}),s&&!i?t==="sm"?f[0]:f:null,p?jsx("div",{"data-testid":"notification",className:lc}):null]})});Lo.displayName="Avatar";var dc="_1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",mc=v({defaultClassName:"_1x62fhb6 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6ev _1yep5z69i _1yep5z69j _1yep5z69k",variantClassNames:{isHovered:{true:"_1yep5z6105"},isSelected:{true:"_1x62fhb8"},isFocusVisible:{true:"_1x62fhb9"},isDisabled:{true:"_1x62fhba _1yep5z6109"},variant:{primary:"_1x62fhbb _1yep5z6z6",ghost:"_1yep5z6z9"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:!0,isDisabled:!1},"_1yep5z61lg"],[{variant:"primary",isSelected:!0},"_1yep5z61me"],[{variant:"ghost",isSelected:!0,isFocusVisible:!1},"_1x62fhbd"],[{variant:"ghost",isSelected:!0,isDisabled:!1},"_1yep5z61lr"],[{variant:"ghost",isDisabled:!0,isSelected:!0},"_1x62fhbe _1yep5z6ey"],[{variant:"primary",isHovered:!0},"_1yep5z61mf"]]}),uc=v({defaultClassName:"_1x62fhb3 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1x62fhb4",ghost:"_1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),fc="_1x62fhbf",yc="_1yep5z6l2 _1yep5z6kz _1yep5z6hc _1yep5z6l1",bc=v({defaultClassName:"_1x62fhb0 _1yep5z6kv _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1yep5z6115",ghost:"_1x62fhb2"}},defaultVariants:{},compoundVariants:[]});var gc=({state:e,...o})=>{let t=to.useRef(null),{tabPanelProps:r}=useTabPanel(o,e,t),{selectedItem:a}=e,{focusProps:i,isFocusVisible:s}=useFocusRing();if(!a?.value)return null;let{className:n,style:p,"data-block-id":l}=a.value;return jsx("div",{...mergeProps(r,i),ref:t,className:classNames({[yc]:s},"Baseline-Tabs-TabPanel",n),"data-block-id":l,style:p,children:a?.props.children})};var ai=to.forwardRef(({className:e,style:o,tabHeaderStyle:t,tabHeaderClassName:r,variant:a="primary",actions:i,onRemove:s,"data-block-id":n,...p},l)=>{let c=useTabListState({...p,selectedKey:p.selectedValue,defaultSelectedKey:p.defaultSelectedValue,disabledKeys:p.disabledValues}),m=to.useRef(null),{tabListProps:u}=useTabList({...p,selectedKey:p.selectedValue,defaultSelectedKey:p.defaultSelectedValue,disabledKeys:p.disabledValues},c,m);return jsxs("div",{className:classNames("BaselineUI-Tabs",e),style:o,ref:l,"data-block-id":n,children:[jsxs("div",{className:classNames(bc({variant:a}),r),style:t,children:[jsx("div",{...u,className:uc({variant:a}),ref:m,children:[...c.collection].map(d=>(invariant(d.value,"TabItem requires a value prop"),jsx(_c,{item:d,state:c,onRemove:s,variant:a},d.key)))}),i?.map((d,f)=>jsx("div",{className:dc,children:jsx(D,{...d,variant:"secondary",size:"sm",className:classNames(fc,d.className)})},f))]}),jsx(gc,{state:c},c.selectedItem?.key)]})});ai.displayName="TabsBase";var _c=({item:e,onRemove:o,state:t,variant:r})=>{let{key:a,value:i}=e,s=to.useRef(null),{tabProps:n,isSelected:p,isDisabled:l}=useTab({key:a},t,s),{hoverProps:c,isHovered:m}=useHover({});invariant(i,"TabButton requires a value prop");let{title:u,icon:d,titleStyle:f,titleClassName:y}=i,{focusProps:b,isFocusVisible:_,isFocused:z}=useFocusRing(),{keyboardProps:g}=useKeyboard({onKeyDown:C=>{C.key==="Backspace"&&o?o(a):C.continuePropagation();}}),h=filterTruthyValues({"data-selected":p,"data-disabled":l,"data-focused":z,"data-hovered":m,"data-focus-visible":_});return jsxs("div",{...mergeProps(g,n,c,b,h),className:classNames(mc({isHovered:m,isSelected:p,isFocusVisible:_,isDisabled:l,variant:r}),"BaselineUI-Tabs-TabButton",y),style:f,ref:s,children:[d?jsx(d,{size:20}):null,u,o?jsx(D,{variant:"secondary",elementType:"div",icon:XIcon$1,size:"xxs",onPress:()=>{o(a);},excludeFromTabOrder:!0,UNSAFE_NON_INTERACTIVE:!0,style:{display:"inline-flex",color:"inherit",opacity:p||z||m?1:0}}):null]})};_c.displayName="TabButton";var hc=to.forwardRef(({children:e,...o},t)=>{let r=useMemo(()=>to.Children.map(e,a=>!a||!to.isValidElement(a)||typeof a.type=="string"?null:{...a.props,id:a.props.value}).filter(Boolean),[e]);return jsx(ai,{...o,ref:t,items:r,children:a=>jsx(Item,{title:a.title,children:a.children},a.key)})});hc.displayName="Tabs";var xc=({children:e,title:o,value:t})=>(invariant(t,"TabItem requires a value prop"),invariant(o,"TabItem requires a title prop"),invariant(e,"TabItem requires children"),e);xc.displayName="TabItem";var Cc={ar:{close:"\u0625\u063A\u0644\u0627\u0642"},cs:{close:"Zav\u0159\xEDt"},cy:{close:"Cau"},da:{close:"Luk"},de:{close:"Schlie\xDFen"},el:{close:"\u039A\u03BB\u03B5\u03AF\u03C3\u03B9\u03BC\u03BF"},"en-GB":{close:"Close"},en:{close:"Close"},es:{close:"Cerrar"},fi:{close:"Sulje"},"fr-CA":{close:"Fermer"},fr:{close:"Fermer"},he:{close:"\u05E1\u05D2\u05D9\u05E8\u05D4"},hr:{close:"Zatvori"},id:{close:"Tutup"},it:{close:"Chiudi"},ja:{close:"\u9589\u3058\u308B"},ko:{close:"\uB2EB\uAE30"},ms:{close:"Tutup"},"nb-NO":{close:"Lukk"},nl:{close:"Sluit"},pl:{close:"Zamknij"},"pt-PT":{close:"Fechar"},pt:{close:"Fechar"},ru:{close:"\u0417\u0430\u043A\u0440\u044B\u0442\u044C"},sk:{close:"Zavrie\u0165"},sl:{close:"Zapri"},sv:{close:"St\xE4ng"},th:{close:"\u0E1B\u0E34\u0E14"},tr:{close:"Kapat"},uk:{close:"\u0417\u0430\u043A\u0440\u0438\u0442\u0438"},"zh-Hans":{close:"\u5173\u95ED"},"zh-Hant":{close:"\u95DC\u9589"}};var Pc=v({defaultClassName:"kfun6yw",variantClassNames:{arrangement:{single:"kfun6yx",multi:"kfun6yy",compact:"kfun6yz"}},defaultVariants:{},compoundVariants:[]}),kc=v({defaultClassName:"kfun6y0 z9nup82",variantClassNames:{variant:{info:"kfun6y1",warning:"kfun6y2",error:"kfun6y3",success:"kfun6y4"},arrangement:{single:"kfun6y5",multi:"kfun6y6",compact:"kfun6y7"},hasButton:{true:"kfun6y8"},hasCloseButton:{true:"kfun6y9"}},defaultVariants:{},compoundVariants:[[{hasButton:!1,arrangement:"single"},"kfun6ya"],[{hasButton:!0,arrangement:"compact"},"kfun6yb"],[{hasCloseButton:!0,arrangement:"compact"},"kfun6yc"]]}),wc=v({defaultClassName:"kfun6yt",variantClassNames:{size:{sm:"kfun6yu",md:"kfun6yv"}},defaultVariants:{},compoundVariants:[]}),Rc=v({defaultClassName:"kfun6yp",variantClassNames:{arrangement:{single:"kfun6yq",multi:"kfun6yr",compact:"kfun6ys"}},defaultVariants:{},compoundVariants:[]}),Ic=v({defaultClassName:"kfun6yk",variantClassNames:{variant:{info:"kfun6yl",warning:"kfun6ym",error:"kfun6yn",success:"kfun6yo"}},defaultVariants:{},compoundVariants:[]}),Nc=v({defaultClassName:"kfun6yh",variantClassNames:{size:{sm:"kfun6yi",md:"kfun6yj"}},defaultVariants:{},compoundVariants:[]}),Tc=v({defaultClassName:"kfun6yd z9nup82",variantClassNames:{arrangement:{single:"kfun6ye",multi:"kfun6yf",compact:"kfun6yg"}},defaultVariants:{},compoundVariants:[]});var T5={error:{sm:ErrorAltFilledIcon,md:ErrorAltFilledIcon$1},info:{sm:InfoFilledIcon,md:InfoFilledIcon$1},success:{sm:CheckFilledIcon,md:CheckFilledIcon$1},warning:{sm:WarningFilledIcon,md:WarningFilledIcon$1}},Sc=to.forwardRef(({className:e,description:o,actionLabel:t,onAction:r,style:a,variant:i="info",title:s,arrangement:n="single",onClose:p,size:l="sm","data-block-id":c,"data-block-class":m},u)=>{let d=F(Cc),f=t&&jsx(A,{variant:n==="compact"?"tertiary":"ghost",label:t,onPress:r}),y=T5[i][l];return jsxs("div",{className:classNames(kc({variant:i,arrangement:n,hasButton:!!t||!!p,hasCloseButton:!!p}),"BaselineUI-InlineAlert",e),"data-block-id":c,"data-block-class":m,style:a,role:"alert",ref:u,children:[jsxs("div",{className:Tc({arrangement:n}),children:[jsx(y,{className:Ic({variant:i}),size:16}),jsxs("div",{className:Pc({arrangement:n}),children:[jsx("h3",{className:Nc({size:l}),children:s}),jsx("section",{className:wc({size:l}),children:o})]}),n==="compact"&&f]}),jsxs("div",{className:Rc({arrangement:n}),children:[n!=="compact"&&f,p?jsx(D,{variant:"secondary",icon:CloseIcon,size:"sm",onPress:p,"aria-label":d.formatMessage("close")}):null]})]})});Sc.displayName="InlineAlert";var Ke={ar:{add:"\u0625\u0636\u0627\u0641\u0629",addColor:"\u0625\u0636\u0627\u0641\u0629 \u0644\u0648\u0646",cancel:"\u0625\u0644\u063A\u0627\u0621",colorFormat:"\u062A\u0646\u0633\u064A\u0642 \u0627\u0644\u0644\u0648\u0646",colorPresets:"\u0627\u0644\u0623\u0644\u0648\u0627\u0646 \u0627\u0644\u0645\u0633\u0628\u0642\u0629",customColors:"\u0623\u0644\u0648\u0627\u0646 \u0645\u062E\u0635\u0635\u0629",newColor:"\u0644\u0648\u0646 \u0645\u062E\u0635\u0635 \u062C\u062F\u064A\u062F",noColor:"\u0644\u0627 \u064A\u0648\u062C\u062F",removeColor:"\u0625\u0632\u0627\u0644\u0629 \u0627\u0644\u0644\u0648\u0646",transparent:"\u0634\u0641\u0627\u0641"},cs:{add:"P\u0159idat",addColor:"P\u0159idat barvu",cancel:"Zru\u0161it",colorFormat:"Form\xE1t barvy",colorPresets:"P\u0159edvolby barev",customColors:"Vlastn\xED barvy",newColor:"Vlastn\xED barva",noColor:"Nen\xED",removeColor:"Odebrat barvu",transparent:"Pr\u016Fhledn\xE1"},cy:{add:"Ychwanegu",addColor:"Ychwanegu Lliw",cancel:"Canslo",colorFormat:"Fformat Lliw",colorPresets:"Rhagosodiadau Lliw",customColors:"Lliwiau Custom",newColor:"Lliw Personol Newydd",noColor:"Dim",removeColor:"Tynnu Lliw",transparent:"Tryloyw"},da:{add:"Tilf\xF8j",addColor:"Tilf\xF8j Farve",cancel:"Annuller",colorFormat:"Farveformat",colorPresets:"Farvevalg",customColors:"Brugerdefinerede farver",newColor:"Ny tilpasset farve",noColor:"Ingen",removeColor:"Fjern Farve",transparent:"Transparent"},de:{add:"Hinzuf\xFCgen",addColor:"Farbe hinzuf\xFCgen",cancel:"Abbrechen",colorFormat:"Farbformat",colorPresets:"Farbvorlagen",customColors:"Benutzerdefinierte Farben",newColor:"Neue benutzerdefinierte Farbe",noColor:"Kein",removeColor:"Farbe entfernen",transparent:"Transparent"},el:{add:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7",addColor:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",cancel:"\u0391\u03BA\u03CD\u03C1\u03C9\u03C3\u03B7",colorFormat:"\u039C\u03BF\u03C1\u03C6\u03AE \u03C7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",colorPresets:"\u03A0\u03C1\u03BF\u03B5\u03C0\u03B9\u03BB\u03BF\u03B3\u03AD\u03C2 \u03C7\u03C1\u03C9\u03BC\u03AC\u03C4\u03C9\u03BD",customColors:"\u03A0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03B1 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03B1",newColor:"\u039D\u03AD\u03BF \u03C0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03BF \u03C7\u03C1\u03CE\u03BC\u03B1",noColor:"\u039A\u03B1\u03BD\u03AD\u03BD\u03B1\u03C2",removeColor:"\u0391\u03C6\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",transparent:"\u0397\u03BC\u03B9\u03B4\u03B9\u03B1\u03C6\u03B1\u03BD\u03AE\u03C2"},"en-GB":{add:"Add",addColor:"Add Colour",cancel:"Cancel",colorFormat:"Colour Format",colorPresets:"Colour Presets",customColors:"Custom Colours",newColor:"New Custom Colour",noColor:"None",removeColor:"Remove Colour",transparent:"Transparent"},en:{add:"Add",addColor:"Add Color",cancel:"Cancel",colorFormat:"Color Format",colorPresets:"Color Presets",customColors:"Custom Colors",newColor:"New Custom Color",noColor:"None",removeColor:"Remove Color",transparent:"Transparent"},es:{add:"A\xF1adir",addColor:"A\xF1adir color",cancel:"Cancelar",colorFormat:"Formato de color",colorPresets:"Preajustes de color",customColors:"Colores personalizados",newColor:"Nuevo color personalizado",noColor:"Ninguna",removeColor:"Eliminar color",transparent:"Transparente"},fi:{add:"Lis\xE4\xE4",addColor:"Lis\xE4\xE4 v\xE4ri",cancel:"Kumoa",colorFormat:"V\xE4rimuoto",colorPresets:"V\xE4rin esiasetukset",customColors:"Mukautetut v\xE4rit",newColor:"Uusi muokattu v\xE4ri",noColor:"Ei mit\xE4\xE4n",removeColor:"Poista v\xE4ri",transparent:"L\xE4pin\xE4kyv\xE4"},"fr-CA":{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},fr:{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},he:{add:"\u05D4\u05D5\u05E1\u05E4\u05D4",addColor:"\u05D4\u05D5\u05E1\u05E3 \u05E6\u05D1\u05E2",cancel:"\u05D1\u05D9\u05D8\u05D5\u05DC",colorFormat:"\u05E4\u05D5\u05E8\u05DE\u05D8 \u05E6\u05D1\u05E2",colorPresets:"\u05DE\u05E6\u05D1\u05D9 \u05E6\u05D1\u05E2 \u05DE\u05EA\u05D5\u05DB\u05E0\u05EA\u05D9\u05DD",customColors:"\u05E6\u05D1\u05E2\u05D9\u05DD \u05DE\u05D5\u05EA\u05D0\u05DE\u05D9\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA",newColor:"\u05E6\u05D1\u05E2 \u05DE\u05D5\u05EA\u05D0\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA \u05D7\u05D3\u05E9",noColor:"\u05DC\u05DC\u05D0",removeColor:"\u05D4\u05E1\u05E8 \u05E6\u05D1\u05E2",transparent:"\u05E9\u05E7\u05D5\u05E3"},hr:{add:"Dodati",addColor:"Dodaj boju",cancel:"Otka\u017Ei",colorFormat:"Format boje",colorPresets:"Prijedlozi boja",customColors:"Prilago\u0111ene boje",newColor:"Nova prilago\u0111ena boja",noColor:"Prazno",removeColor:"Ukloni boju",transparent:"Prozirna"},id:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batalkan",colorFormat:"Format Warna",colorPresets:"Preset Warna",customColors:"Warna Kustom",newColor:"Warna Khusus Baru",noColor:"Tidak ada",removeColor:"Hapus Warna",transparent:"Transparan"},it:{add:"Aggiungi",addColor:"Aggiungi colore",cancel:"Annulla",colorFormat:"Formato del colore",colorPresets:"Colori predefiniti",customColors:"Colori personalizzati",newColor:"Nuovo colore personalizzato",noColor:"Nessuno",removeColor:"Rimuovi colore",transparent:"Trasparente"},ja:{add:"\u8FFD\u52A0",addColor:"\u8272\u3092\u8FFD\u52A0",cancel:"\u30AD\u30E3\u30F3\u30BB\u30EB",colorFormat:"\u30AB\u30E9\u30FC\u30D5\u30A9\u30FC\u30DE\u30C3\u30C8",colorPresets:"\u30AB\u30E9\u30FC\u30D7\u30EA\u30BB\u30C3\u30C8",customColors:"\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",newColor:"\u65B0\u898F\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",noColor:"\u306A\u3057",removeColor:"\u8272\u3092\u524A\u9664",transparent:"\u900F\u660E"},ko:{add:"\uCD94\uAC00",addColor:"\uC0C9\uC0C1 \uCD94\uAC00",cancel:"\uCDE8\uC18C",colorFormat:"\uC0C9\uC0C1 \uD615\uC2DD",colorPresets:"\uC0C9\uC0C1 \uBBF8\uB9AC\uC124\uC815",customColors:"\uC0AC\uC6A9\uC790 \uC815\uC758 \uC0C9\uC0C1",newColor:"\uC0C8\uB85C\uC6B4 \uC0AC\uC6A9\uC790\uC9C0\uC815 \uC0C9\uC0C1",noColor:"\uC5C6\uC74C",removeColor:"\uC0C9\uC0C1 \uC81C\uAC70",transparent:"\uD22C\uBA85"},ms:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batal",colorFormat:"Format Warna",colorPresets:"Praset Warna",customColors:"Warna Kustom",newColor:"Warna Tersuai Baharu",noColor:"Tiada",removeColor:"Buang Warna",transparent:"Lut Sinar"},"nb-NO":{add:"Legg til",addColor:"Legg til farge",cancel:"Avbryt",colorFormat:"Fargeformat",colorPresets:"Fargeinnstillinger",customColors:"Egendefinerte farger",newColor:"Ny tilpasset farge",noColor:"Ingen",removeColor:"Fjern farge",transparent:"Gjennomsiktig"},nl:{add:"Voeg toe",addColor:"Kleur toevoegen",cancel:"Annuleer",colorFormat:"Kleurformaat",colorPresets:"Kleurvoorinstellingen",customColors:"Aangepaste kleuren",newColor:"Nieuwe aangepaste kleur",noColor:"Geen",removeColor:"Kleur verwijderen",transparent:"Doorzichtig"},pl:{add:"Dodaj",addColor:"Dodaj kolor",cancel:"Anuluj",colorFormat:"Format koloru",colorPresets:"Wst\u0119pnie ustawione kolory",customColors:"Niestandardowe kolory",newColor:"Nowy kolor niestandardowy",noColor:"Brak",removeColor:"Usu\u0144 kolor",transparent:"Prze\u015Bwiecaj\u0105ce"},"pt-PT":{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Predefini\xE7\xF5es de cor",customColors:"Cores personalizadas",newColor:"Nova cor personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},pt:{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Pr\xE9-ajustes de Cores",customColors:"Cores personalizadas",newColor:"Nova Cor Personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},ru:{add:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C",addColor:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0446\u0432\u0435\u0442",cancel:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u0446\u0432\u0435\u0442\u0430",colorPresets:"\u0411\u0438\u0431\u043B\u0438\u043E\u0442\u0435\u043A\u0430 \u0446\u0432\u0435\u0442\u043E\u0432",customColors:"\u041F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u0435\u043B\u044C\u0441\u043A\u0438\u0435 \u0446\u0432\u0435\u0442\u0430",newColor:"\u041D\u043E\u0432\u044B\u0439 \u0441\u043E\u0431\u0441\u0442\u0432\u0435\u043D\u043D\u044B\u0439 \u0446\u0432\u0435\u0442",noColor:"\u041D\u0435\u0442",removeColor:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0446\u0432\u0435\u0442",transparent:"\u041F\u0440\u043E\u0437\u0440\u0430\u0447\u043D\u044B\u0439"},sk:{add:"Prida\u0165",addColor:"Prida\u0165 farbu",cancel:"Zru\u0161i\u0165",colorFormat:"Form\xE1t farby",colorPresets:"Predvo\u013Eby farieb",customColors:"Vlastn\xE9 farby",newColor:"Vlastn\xE1 farba",noColor:"\u017Diadny",removeColor:"Odstr\xE1ni\u0165 farbu",transparent:"Prieh\u013Eadn\xE1"},sl:{add:"Dodaj",addColor:"Dodaj barvo",cancel:"Prekli\u010Di",colorFormat:"Barvni format",colorPresets:"Barvne predloge",customColors:"Prilagojene barve",newColor:"Nova barva po meri",noColor:"Prazna stran",removeColor:"Odstrani barvo",transparent:"Prosojna"},sv:{add:"L\xE4gg till",addColor:"L\xE4gg till f\xE4rg",cancel:"Avbryt",colorFormat:"F\xE4rgformat",colorPresets:"F\xF6rval f\xF6r f\xE4rger",customColors:"Anpassade f\xE4rger",newColor:"Ny anpassad f\xE4rg",noColor:"Ingen",removeColor:"Ta bort f\xE4rg",transparent:"Genomskinligt"},th:{add:"\u0E40\u0E1E\u0E34\u0E48\u0E21",addColor:"\u0E40\u0E1E\u0E34\u0E48\u0E21\u0E2A\u0E35",cancel:"\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01",colorFormat:"\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E2A\u0E35",colorPresets:"\u0E04\u0E48\u0E32\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E15\u0E31\u0E49\u0E07\u0E44\u0E27\u0E49\u0E25\u0E48\u0E27\u0E07\u0E2B\u0E19\u0E49\u0E32",customColors:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07",newColor:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07\u0E43\u0E2B\u0E21\u0E48",noColor:"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E40\u0E25\u0E22",removeColor:"\u0E25\u0E1A\u0E2A\u0E35",transparent:"\u0E42\u0E1B\u0E23\u0E48\u0E07\u0E43\u0E2A"},tr:{add:"Ekle",addColor:"Renk Ekle",cancel:"Vazge\xE7",colorFormat:"Renk Format\u0131",colorPresets:"Renk \xD6nayarlar\u0131",customColors:"\xD6zel Renkler",newColor:"Yeni \xF6zel renk",noColor:"Hi\xE7biri",removeColor:"Rengi Kald\u0131r",transparent:"\u015Eeffaf"},uk:{add:"\u0414\u043E\u0434\u0430\u0442\u0438",addColor:"\u0414\u043E\u0434\u0430\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",cancel:"\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u043A\u043E\u043B\u044C\u043E\u0440\u0443",colorPresets:"\u0411\u0456\u0431\u043B\u0456\u043E\u0442\u0435\u043A\u0430 \u043A\u043E\u043B\u044C\u043E\u0440\u0456\u0432",customColors:"\u041A\u043E\u0440\u0438\u0441\u0442\u0443\u0432\u0430\u0446\u044C\u043A\u0456 \u043A\u043E\u043B\u044C\u043E\u0440\u0438",newColor:"\u041D\u043E\u0432\u0438\u0439 \u0432\u043B\u0430\u0441\u043D\u0438\u0439 \u043A\u043E\u043B\u0456\u0440",noColor:"\u041D\u0435\u043C\u0430\u0454",removeColor:"\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",transparent:"\u041F\u0440\u043E\u0437\u043E\u0440\u0438\u0439"},"zh-Hans":{add:"\u6DFB\u52A0",addColor:"\u6DFB\u52A0\u989C\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u989C\u8272\u683C\u5F0F",colorPresets:"\u989C\u8272\u9884\u8BBE",customColors:"\u81EA\u5B9A\u4E49\u989C\u8272",newColor:"\u65B0\u81EA\u5B9A\u4E49\u989C\u8272",noColor:"\u65E0",removeColor:"\u79FB\u9664\u989C\u8272",transparent:"\u900F\u660E"},"zh-Hant":{add:"\u52A0\u5165",addColor:"\u6DFB\u52A0\u984F\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u984F\u8272\u683C\u5F0F",colorPresets:"\u984F\u8272\u9810\u8A2D\u9805",customColors:"\u81EA\u8A02\u984F\u8272",newColor:"\u65B0\u81EA\u8A02\u984F\u8272",noColor:"\u7121",removeColor:"\u79FB\u9664\u984F\u8272",transparent:"\u900F\u660E"}};var xr=({children:e})=>{let{triggerProps:o}=to.useContext(je);return jsx(Slot,{...o,children:e})};xr.displayName="ModalTrigger";var F5=({children:e})=>{let{state:o}=to.useContext(je);return jsx(Slot,{onPress:()=>o?.close(),children:e})};var Lc="_1dbkl53 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6kv",Mc="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt",Bc="_1dbkl5e",Dc=v({defaultClassName:"_1dbkl54 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l6 _1yep5z6ky _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6kx _1yep5z6dy",variantClassNames:{isHovered:{true:"_1dbkl55"},isFocusVisible:{true:"_1dbkl56"},isDisabled:{true:"z9nup83 _1yep5z6109"},labelPosition:{top:"_1dbkl58",start:"_1dbkl59"}},defaultVariants:{},compoundVariants:[]}),Ec=v({defaultClassName:"_1dbkl50 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6dy _1yep5z6ev",variantClassNames:{labelPosition:{top:"_1yep5z6nq _1yep5z6nr _1yep5z6ns",start:"_1dbkl52"}},defaultVariants:{},compoundVariants:[]}),Cr="_1dbkl5l _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69f _1yep5z69g _1yep5z69h",Fc="_1dbkl5f z9nup87",Pr="_1dbkl5m _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn",Hc="_1dbkl5k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ky",Oc="_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy _1yep5z6ev _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it",kr=v({defaultClassName:"_1dbkl5h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs",variantClassNames:{includesCustomColorPicker:{true:"_1yep5z6me _1yep5z6mf _1yep5z6mg"}},defaultVariants:{},compoundVariants:[]}),ni="_1dbkl5v _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",Vc=v({defaultClassName:"_1dbkl5q _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6br _1yep5z6bs _1yep5z6bt _1yep5z6d3 _1yep5z6d4 _1yep5z6d5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocused:{true:"_1dbkl5r _1yep5z611y"},isHovered:{true:"_1dbkl5s"},allowAlpha:{false:"_1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6166"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,isFocused:!1},"_1yep5z61nd"]]}),Ac=v({defaultClassName:"_1dbkl5a _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62c _1yep5z62d _1yep5z62e _1yep5z63i _1yep5z63j _1yep5z63k _1yep5z616 _1yep5z617 _1yep5z618 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e _1yep5z6f0 _1yep5z6kx _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kl",variantClassNames:{isHovered:{true:"_1yep5z6115"},isFocusVisible:{true:"_1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612n"},isDisabled:{true:"_1yep5z610d"}},defaultVariants:{},compoundVariants:[]}),ut="_1dbkl5u",wr="_1dbkl5g _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Rr="_1dbkl5j _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",li="_1dbkl5x",jc="_1dbkl5w",pi="_1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69l _1yep5z69m _1yep5z69n",Ir=v({defaultClassName:"_1dbkl5n _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6l2 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6l7 _1yep5z6la",variantClassNames:{isFocusVisible:{true:"_1dbkl5o _1yep5z616a _1yep5z612n _1yep5z616c"}},defaultVariants:{},compoundVariants:[]}),ci="z9nup84 z9nup86 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6ho _1yep5z6hp _1yep5z6hq";var $c=v({defaultClassName:"_1344e9q0 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ks _1yep5z6hk _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",variantClassNames:{isFocusVisible:{true:"_1344e9q1"},isDisabled:{true:"_1344e9q2"},removeBlendMode:{true:"_1344e9q3"},isSelected:{true:"_1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616f"},isHovered:{true:"_1344e9q5"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isFocusVisible:!0},"_1344e9q6"],[{isSelected:!0,isFocusVisible:!0},"_1344e9q7 _1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq _1yep5z61o5"],[{isHovered:!0,isSelected:!1},"_1yep5z61rq _1yep5z61rn _1yep5z61rl _1yep5z61o2"]]});var we=to.forwardRef(({color:e,isFocusVisible:o,isSelected:t,isInteractive:r,isDisabled:a,style:i,className:s,id:n,"data-block-id":p,"data-block-class":l,...c},m)=>{let u=e&&e!==Re&&(typeof e=="string"?parseColor(e):e),{formatMessage:d}=F(),f=!u,{colorSwatchProps:y}=useColorSwatch({color:f?"#000000":e}),{hoverProps:b,isHovered:_}=useHover({isDisabled:a||!r}),z=filterTruthyValues({"data-focus-visible":o,"data-selected":t,"data-hovered":_,"data-block-id":p,"data-block-class":l,"data-disabled":a,"data-interactive":r});return jsx("div",{...mergeProps(b,z,f?{}:y),style:i,"aria-label":f?d(G5.none):y["aria-label"],role:"img",className:classNames($c({removeBlendMode:f,isFocusVisible:o,isDisabled:!!a,isSelected:!!t,isHovered:_}),"BaselineUI-ColorSwatch",s),ref:m,id:n,...c,children:jsx(M,{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"full",height:"full",width:"full",opacity:a?"medium":void 0,style:u?Uc(u,4):void 0,children:f?jsx(NoneIcon,{size:14}):null})})});we.displayName="ColorSwatch";var G5=$({none:{id:"none",defaultMessage:"None"}});var Kc=[{id:"hex",label:"HEX"},{id:"rgb",label:"RGB"}],Mo=parseColor("#000000").toFormat("hsla"),J="hsla",ft="hexa";function Je(e){return typeof e=="string"?parseColor(e).toFormat(J):e?e.toFormat(J):null}function Gc(e,o){return e?.getChannelValue("alpha")?o?.toString(ft)===e.toString(ft):!o?.getChannelValue("alpha")}function Wc(e,o,t){return o?.label?o.label:e?.getChannelValue("alpha")===0?t:e?.toString("rgba")}var Re="NONE";function Xc(e,o){let t=o?.map(a=>({id:parseColor(a.color).toString(ft),label:a.label}))||[],r={id:Re,label:e};return [...t,r]}var Nr=(e,{optionProps:o,isFocusVisible:t,isSelected:r},a)=>(invariant(e.value&&"label"in e.value,"Item must have label"),jsx("li",{...o,ref:a,className:Hc,children:jsx(we,{color:e.value.id,isFocusVisible:t,isSelected:r,"aria-label":e.value.label,isInteractive:!0})})),Uc=(e,o=4)=>{let t=e.getChannelValue("alpha")===0,r=`repeating-conic-gradient(transparent 0% 25%, ${themeVars.color.background.secondary.medium} 25% 50%)`;return {backgroundImage:t?r:`linear-gradient(${e.toString("hexa")}, ${e.toString("hexa")}), ${r}`,backgroundSize:`${o}px ${o}px`}};var Zc=({value:e,...o})=>{let t=to.useRef(null),r=to.useRef(null),a=to.useRef(null),i=useColorAreaState({...o,value:e}),{colorAreaProps:s,xInputProps:n,yInputProps:p,thumbProps:l}=useColorArea({...o,value:e,inputXRef:t,inputYRef:r,containerRef:a},i);useEffect(()=>{t.current?.focus();},[]);let{focusProps:c,isFocusVisible:m}=useFocusRing();return jsx("div",{ref:a,...s,className:classNames(Lc,"BaselineUI-ColorInput-ColorArea"),children:jsxs("div",{...l,className:classNames(Ir({isFocusVisible:m}),"BaselineUI-ColorInput-ColorAreaThumb"),style:{...l.style,transform:"translate(-50%, -50%)",backgroundColor:Je(e)?.withChannelValue("alpha",1).toString("css")},children:[jsx("input",{ref:t,...n,...c}),jsx("input",{ref:r,...p,...c})]})})};var ed=({color:e,setColor:o,allowAlpha:t,...r})=>{let a=useColorFieldState({value:e,onChange:m=>{o(Je(m)?.toFormat(J).withChannelValue("alpha",e.getChannelValue("alpha")??1)||Mo);}}),i=to.useRef(null),{inputProps:s}=useColorField({...r,"aria-label":"Hex"},a,i),{focusProps:n,isFocused:p}=useFocusRing({isTextInput:!0}),{hoverProps:l,isHovered:c}=useHover({});return jsxs("div",{className:classNames(ni,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":t?"hexa":"hex",children:[jsx("input",{...mergeProps(s,n,l),ref:i,className:Vc({isFocused:p,isHovered:c,allowAlpha:t})}),t?jsx(td,{color:e,setColor:o}):null]})},od=({color:e,setColor:o,allowAlpha:t})=>{let r=e.toFormat("rgba"),{locale:a}=useLocale();return jsxs("div",{className:classNames(ni,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":t?"rgba":"rgb",children:[jsx(Me,{"aria-label":e.getChannelName("red",a),value:r.getChannelValue("red"),showStepper:!1,className:ut,onChange:i=>{o(r.withChannelValue("red",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsx(Me,{"aria-label":e.getChannelName("green",a),value:r.getChannelValue("green"),showStepper:!1,className:ut,onChange:i=>{o(r.withChannelValue("green",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsx(Me,{"aria-label":e.getChannelName("blue",a),value:r.getChannelValue("blue"),showStepper:!1,className:ut,onChange:i=>{o(r.withChannelValue("blue",i).toFormat(J));},step:1,minValue:0,maxValue:255}),t?jsx(td,{color:e,setColor:o}):null]})},lz={style:"percent",maximumFractionDigits:0},td=({color:e,setColor:o})=>{let{locale:t}=useLocale(),r=useCallback(a=>{o(e.withChannelValue("alpha",a));},[e,o]);return jsx(Me,{"aria-label":e.getChannelName("alpha",t),value:e.getChannelValue("alpha"),formatOptions:lz,className:ut,showStepper:!1,onChange:r,minValue:0,maxValue:1})};var yi=({channel:e,...o})=>{let{locale:t}=useLocale(),r=useColorSliderState({...o,channel:e,locale:t}),a=to.useRef(null),i=to.useRef(null),{trackProps:s,thumbProps:n,inputProps:p}=useColorSlider({...o,channel:e,trackRef:a,inputRef:i,"aria-label":r.value.getChannelName(e,t)},r),{focusProps:l,isFocusVisible:c}=useFocusRing();return jsxs("div",{className:classNames(Pr,{[Qs({size:"xs"})]:e==="alpha"},"BaselineUI-ColorInput-ColorSlider"),"data-channel":e,...s,ref:a,children:[e==="alpha"&&jsx("div",{className:ci}),jsx("div",{className:Pr,style:s.style}),jsxs("div",{className:classNames(Ir({isFocusVisible:c}),"BaselineUI-ColorInput-ColorSliderThumb"),...n,children:[jsx("div",{className:ci,style:{backgroundColor:"#ffffff"}}),jsx("div",{style:{backgroundColor:r.getDisplayColor().toString("css"),height:8},className:Pr}),jsx(VisuallyHidden,{children:jsx("input",{ref:i,...p,...l})})]})]})};var Tr=({color:e,setColor:o,allowAlpha:t})=>{let[r,a]=to.useState("hex"),{formatMessage:i}=F(Ke);return jsxs(Fragment,{children:[jsx(Zc,{value:e,xChannel:"saturation",yChannel:"lightness",onChange:o}),jsxs("div",{className:pi,children:[jsx(yi,{channel:"hue",value:e,onChange:o}),t?jsx(yi,{channel:"alpha",value:e,onChange:o}):null]}),jsxs("div",{className:classNames(pi,sprinkles.variants({paddingTop:"none",gap:"sm"})),children:[jsx(qe,{label:i("colorFormat"),labelPosition:"start",variant:"ghost",items:Kc,selectedKey:r,onSelectionChange:s=>{a(s);}}),r==="hex"&&jsx(ed,{color:e,setColor:o,allowAlpha:t}),r==="rgb"&&jsx(od,{color:e,setColor:o,allowAlpha:t})]})]})};var vi=({color:e,setColor:o,storePickedColorKey:t,addColorButtonLabel:r,removeColorButtonLabel:a,customColorsLabel:i,pickerMode:s,allowAlpha:n})=>{let{locale:p}=useLocale(),{formatMessage:l}=F(Ke),c=to.useRef(null),m=go(c.current),[u,d]=Pn(t,[]),f=to.useRef(null),[y,b]=to.useState(e),_=to.useMemo(()=>u.map(P=>({id:P,label:parseColor(P).getColorName(p),description:P})),[u,p]),z=useCallback(()=>{let P=s==="active"?e:y;if(u.includes(P.toString(J))){f.current?.querySelector(`[data-key='${P.toString(J)}']`)?.classList.add(li);return}d([...u,P.toString(J)]);},[u,e,d,y,s]);useEffect(()=>{let P=f.current;function k(N){N.animationName===jc&&N.target?.classList.remove(li);}return P?.addEventListener("animationend",k),()=>{P?.removeEventListener("animationend",k);}},[]);let g=useId(),h=jsx(D,{ref:c,variant:"secondary",size:"md","aria-label":r,icon:PlusIcon$1,onPress:s==="active"?z:void 0}),C=useCallback(P=>jsxs(le,{size:"content",className:kr({includesCustomColorPicker:!0}),style:{paddingBlockEnd:0},"aria-label":l("newColor"),children:[jsx(Tr,{color:y,setColor:b,allowAlpha:n}),jsx(O,{}),jsx(M,{padding:"lg",display:"flex",flexDirection:"row-reverse",children:jsxs(M,{display:"inline-flex",gap:"lg",children:[jsx(A,{label:l("cancel"),size:"sm",variant:"secondary",onPress:P}),jsx(A,{label:l("add"),variant:"primary",onPress:()=>{z(),P();},size:"sm"})]})})]}),[y,z,l,n]),w=useCallback(P=>{invariant(P instanceof Set,"Key must be a set");let k=[...P][0];k&&o(parseColor(k).toFormat(J));},[o]);return jsxs(Fragment,{children:[jsx(O,{}),jsxs("div",{className:classNames(Oc,"BaselineUI-ColorInput-CustomColors"),children:[jsx("span",{id:g,children:i}),jsxs(M,{display:"flex",children:[!!u.length&&u.includes(e.toString(J))&&jsx(D,{variant:"secondary",size:"md",elementType:"div",icon:MinusIcon$2,"aria-label":a,onPress:()=>{d(u.filter(P=>P!==e.toString(J)));}}),s==="active"&&h,s==="lazy"&&(m==="mobile"?jsxs(Ce,{children:[jsx(xr,{children:h}),jsx(Be,{style:{zIndex:1e5},children:({close:P})=>C(P)})]}):jsx(Se,{type:"dialog",children:({close:P})=>jsxs(Fragment,{children:[jsx(Le,{children:h}),jsx(Pe,{placement:"right top",className:wr,offset:6,children:C(P)})]})}))]})]}),!!u.length&&jsx(re,{items:_,layout:"grid","aria-labelledby":g,className:classNames(Cr,Rr,sprinkles.variants({paddingTop:"xs"}),"BaselineUI-ColorInput-CustomColorsListBox"),renderOption:Nr,ref:f,autoFocus:!1,selectionMode:"single",selectedKeys:[e.toString(J)],onSelectionChange:w})]})};var _i=to.forwardRef(({setColor:e,color:o,triggerRef:t,autoFocus:r,presets:a,state:i},s)=>{let{formatMessage:n}=F(Ke),p=useCallback(l=>{if(l instanceof Set&&l.size){let c=[...l][0],m=a.find(u=>u.id===c);invariant(m,"Preset not found"),e(m.id===Re?null:parseColor(m.id).toFormat(J)),i.close();}},[i,a,e]);return jsx("div",{className:classNames(Rr,"BaselineUI-ColorInput-Presets"),style:{minWidth:t.current?.offsetWidth},ref:s,children:jsx(re,{autoFocus:r,items:a,layout:"grid","aria-label":n("colorPresets"),className:Cr,renderOption:Nr,selectionMode:"single",selectedKeys:[o?.toString(ft)||Re],onSelectionChange:p})})});_i.displayName="ColorPresetList";var bt=to.forwardRef(({color:e,colorLabel:o,colorName:t,...r},a)=>{let i=to.useRef(null),{hoverProps:s,isHovered:n}=useHover({isDisabled:r.isDisabled}),{buttonProps:p,isPressed:l}=useButton(r,i),{isFocusVisible:c,focusProps:m}=useFocusRing(),u=filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":c,"data-focus-visible":c,"data-disabled":r.isDisabled,"data-hovered":n,"data-pressed":l});return jsxs("button",{...mergeProps(p,s,m,u),style:r.style,className:classNames(Dc({isHovered:n,isFocusVisible:c||r.isOpen,isDisabled:r.isDisabled,labelPosition:r.labelPosition}),"BaselineUI-ColorInputButton",r.className),ref:T(a,i),children:[jsx(we,{color:e?.toString("hexa")}),o?jsx("div",{className:Fc,children:t}):jsx(VisuallyHidden,{children:t})]})});bt.displayName="ColorInputButton";var Mr=to.forwardRef(({className:e,style:o,icon:t,...r},a)=>{let i=to.useRef(null),{hoverProps:s,isHovered:n}=useHover({isDisabled:r.isDisabled}),{buttonProps:p,isPressed:l}=useButton(r,i),{isFocusVisible:c,focusProps:m}=useFocusRing(),u=filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":c,"data-focus-visible":c,"data-disabled":r.isDisabled,"data-hovered":n,"data-pressed":l});return jsxs("button",{...mergeProps(p,s,m,u),ref:T(a,i),style:o,className:classNames(Ac({isHovered:n||l||r.isOpen,isFocusVisible:c,isDisabled:r.isDisabled}),"BaselineUI-IconColorInputButton",e),children:[jsx(t,{size:16}),jsx("div",{className:Bc,style:{backgroundColor:r.color||void 0}})]})});Mr.displayName="IconColorInputButton";function vd({colorLabel:e,color:o,presets:t}){let{formatMessage:r}=F(),{locale:a}=useLocale(),i=useMemo(()=>t.find(p=>p.id===Re?!o:o?Gc(o,parseColor(p.id)):!1),[t,o]),s=useMemo(()=>typeof e=="function"?e?.(o):e?Wc(o,i,r(Mz.transparent)):!1,[o,e,r,i]),n=useMemo(()=>{if(i?.label)return i.label;o?.getColorName(a);},[o,a,i?.label]);return {colorName:s,humanReadableName:n}}var Mz=$({transparent:{defaultMessage:"Transparent",id:"transparent"}});var Eo=to.forwardRef(({className:e,style:o,allowRemoval:t,allowAlpha:r=!0,presets:a,labelPosition:i="top",colorLabel:s=!0,includePicker:n=!0,onChange:p,defaultValue:l,storePickedColorKey:c="baselinePickedColor",value:m,addColorButtonLabel:u,removeColorButtonLabel:d,customColorsLabel:f,renderTriggerButton:y=({isOpen:P,color:k,ref:N,colorName:R,triggerProps:I,labelId:B})=>jsx(bt,{...mergeProps(I,{...C.label?{"aria-labelledby":B}:{"aria-label":C["aria-label"]}}),ref:N,isOpen:P,isDisabled:C.isDisabled,labelPosition:i,color:k,colorLabel:s,colorName:R}),pickerMode:b="active",offset:_=2,placement:z=i==="start"?"bottom end":"bottom start","data-block-id":g,"data-block-class":h,...C},w)=>{let P=to.useRef(null),k=to.useRef(null),N=useOverlayTriggerState(C),{triggerProps:R,overlayProps:I}=useOverlayTrigger({type:"listbox"},N,P),B=ue(C.portalContainer),[L,x]=useControlledState(m===void 0?void 0:Je(m),Je(l),V=>p?.(V?.toFormat("rgba")||null)),{formatMessage:S}=F(Ke),H=useMemo(()=>Xc(S(Br.noColor),a),[a,S]),j=useId(),{colorName:ae}=vd({colorLabel:s,color:L,presets:H}),ie=useMemo(()=>H.filter(V=>t||V.id!==Re),[H,t]),G=u||S(Br.addColor),U=d||S(Br.removeColor),pe=f||S(Br.customColors);return jsxs(Fragment,{children:[jsxs("div",{className:classNames({[Mc]:i==="start"},"BaselineUI-ColorInput-Trigger",e),"data-block-id":g,"data-block-class":h,style:o,ref:w,children:[C.label?jsx("label",{id:j,className:Ec({labelPosition:i}),children:C.label}):null,y({isOpen:N.isOpen,color:L,ref:P,colorName:ae,triggerProps:R,labelId:j})]}),N.isOpen?jsx(ce,{...C,portalContainer:B,placement:z,state:N,offset:_,className:classNames(wr,"BaselineUI-ColorInput-Popover"),triggerRef:P,overlayProps:I,children:jsxs(le,{size:"content",className:kr({includesCustomColorPicker:n}),ref:k,"aria-labelledby":j,"aria-label":C["aria-label"],children:[n&&b==="active"?jsxs(Fragment,{children:[jsx(Tr,{color:L||Mo,setColor:x,allowAlpha:r}),jsx(vi,{color:L||Mo,setColor:x,storePickedColorKey:c,addColorButtonLabel:G,removeColorButtonLabel:U,customColorsLabel:pe,pickerMode:b,allowAlpha:r})]}):null,!!ie.length&&jsxs(Fragment,{children:[n&&b==="active"?jsx(O,{}):null,jsx(_i,{autoFocus:n&&b==="active"?!1:"first",state:N,triggerRef:P,presets:ie,color:L,setColor:x})]}),n&&b==="lazy"?jsx(vi,{color:L||Mo,setColor:x,storePickedColorKey:c,addColorButtonLabel:G,removeColorButtonLabel:U,customColorsLabel:pe,pickerMode:b,allowAlpha:r}):null]})}):null]})});Eo.displayName="ColorInput";var Br=$({addColor:{defaultMessage:"Add color",id:"addColor"},removeColor:{defaultMessage:"Remove color",id:"removeColor"},customColors:{defaultMessage:"Custom colors",id:"customColors"},noColor:{defaultMessage:"No color",id:"noColor"},transparent:{defaultMessage:"Transparent",id:"transparent"}});var xd=to.forwardRef(({className:e,style:o,icon:t,variant:r="standard","data-block-id":a,tooltipProps:i,...s},n)=>{let p=to.useRef(null),l=useCallback(({isOpen:c,color:m,ref:u,colorName:d,triggerProps:f})=>jsx(ke,{variant:"inverse",size:"sm",includeArrow:!1,text:s["aria-label"],placement:"bottom start",offset:4,...i,children:r==="standard"?jsx(bt,{...f,"aria-label":s["aria-label"],ref:u,isOpen:c,isDisabled:s.isDisabled,color:m,colorLabel:!1,colorName:d}):jsx(Mr,{...f,isOpen:c,icon:TextIcon,color:m?.toString("hexa"),ref:u,isDisabled:s.isDisabled,"aria-label":s["aria-label"]})}),[s,i,r]);return jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:r==="standard"?"md":"none",alignItems:"center",className:classNames("BaselineUI-IconColorInput",e),"data-block-id":a,style:o,ref:T(n,p),children:[r==="standard"&&t?jsx(t,{size:24,className:sprinkles({color:"icon.primary"})}):null,jsx(Eo,{...s,colorLabel:!1,renderTriggerButton:l})]})});xd.displayName="IconColorInput";var Cd={ar:{redo:"\u0625\u0639\u0627\u062F\u0629",undo:"\u062A\u0631\u0627\u062C\u0639"},cs:{redo:"Opakovat",undo:"Zru\u0161it"},cy:{redo:"Ail-wneud",undo:"Dad-wneud"},da:{redo:"Gentag",undo:"Fortryd"},de:{redo:"Wiederholen",undo:"R\xFCckg\xE4ngig machen"},el:{redo:"\u0395\u03C0\u03B1\u03BD\u03AC\u03BB\u03B7\u03C8\u03B7",undo:"\u0391\u03BD\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7"},"en-GB":{redo:"Redo",undo:"Undo"},en:{redo:"Redo",undo:"Undo"},es:{redo:"Rehacer",undo:"Deshacer"},fi:{redo:"Tee sittenkin",undo:"Peru"},"fr-CA":{redo:"R\xE9tablir",undo:"Annuler"},fr:{redo:"R\xE9tablir",undo:"Annuler"},he:{redo:"\u05D1\u05D9\u05E6\u05D5\u05E2 \u05DE\u05D7\u05D3\u05E9",undo:"\u05D1\u05D9\u05D8\u05D5\u05DC \u05E4\u05E2\u05D5\u05DC\u05D4"},hr:{redo:"Ponovi",undo:"Vrati"},id:{redo:"Ulangi",undo:"Kembalikan"},it:{redo:"Ripristina",undo:"Annulla"},ja:{redo:"\u3084\u308A\u76F4\u3059",undo:"\u53D6\u308A\u6D88\u3059"},ko:{redo:"\uC2E4\uD589\uBCF5\uADC0",undo:"\uC2E4\uD589\uCDE8\uC18C"},ms:{redo:"Buat Semula",undo:"Buat Asal"},"nb-NO":{redo:"Gj\xF8r om igjen",undo:"Angre"},nl:{redo:"Opnieuw",undo:"Herstel"},pl:{redo:"Pon\xF3w",undo:"Cofnij"},"pt-PT":{redo:"Refazer",undo:"Desfazer"},pt:{redo:"Refazer",undo:"Desfazer"},ru:{redo:"\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u044C",undo:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C"},sk:{redo:"Opakova\u0165",undo:"Zru\u0161i\u0165"},sl:{redo:"Uveljavi",undo:"Razveljavi"},sv:{redo:"G\xF6r om",undo:"\xC5ngra"},th:{redo:"\u0E17\u0E33\u0E0B\u0E49\u0E33",undo:"\u0E16\u0E2D\u0E19\u0E04\u0E33\u0E2A\u0E31\u0E48\u0E07\u0E01\u0E25\u0E31\u0E1A"},tr:{redo:"Yinele",undo:"Geri Al"},uk:{redo:"\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u0438",undo:"\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438"},"zh-Hans":{redo:"\u91CD\u505A",undo:"\u64A4\u9500"},"zh-Hant":{redo:"\u91CD\u4F5C",undo:"\u5FA9\u539F"}};var Dr=v({defaultClassName:"mnnh5s1 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ki _1yep5z6kl _1yep5z6kx _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{true:"mnnh5s2 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy _1yep5z6122 _1yep5z616j _1yep5z616k",false:"_1yep5z6166 _1yep5z6116"},isHovered:{true:"mnnh5s4"},hasLoadedImage:{true:"_1yep5z6115"},includeCheckeredBackground:{true:"mnnh5s6"},showFocusRing:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 _1yep5z6yl"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,hasLoadedImage:!1},"_1yep5z61mo"],[{isHovered:!0,hasLoadedImage:!0},"mnnh5s9"],[{isInline:!0,isDisabled:!0},"_1yep5z61nd"],[{hasLoadedImage:!0,includeCheckeredBackground:!0},"_1yep5z61mg"]]}),Pd="_1yep5z6d8",Er=v({defaultClassName:"mnnh5sa",variantClassNames:{isInline:{true:"mnnh5sb",false:"mnnh5sc"},isDisabled:{true:"mnnh5sd"},hasLoadedImage:{true:"mnnh5s0"}},defaultVariants:{},compoundVariants:[]});var kd=v({defaultClassName:"_1i0ytqa3 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6kw _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1i0ytqa4"},isInline:{true:"_1yep5z611e",false:"_1yep5z611g"},isDisabled:{true:"_1i0ytqa7 _1yep5z6yl",false:"_1i0ytqa8"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isFocusVisible:!0},"_1i0ytqa9 _1yep5z61n9 _1yep5z61rt _1yep5z61rv"],[{isInline:!1,isFocusVisible:!0},"_1i0ytqaa"],[{isInline:!0,isDisabled:!0},"_1yep5z61mp"],[{isInline:!1,isDisabled:!0},"_1yep5z61mr"]]}),wd="_1i0ytqa0",Fr=v({defaultClassName:"_1i0ytqab _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z6115"},isDisabled:{true:"_1i0ytqad _1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),Rd=v({defaultClassName:"_1i0ytqa1 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b"}},defaultVariants:{},compoundVariants:[]});var rh={size:1,thinning:0,smoothing:0,streamline:0,easing:e=>e,start:{taper:0,easing:e=>e,cap:!0},end:{taper:0,easing:e=>e,cap:!0},simulatePressure:!1},Td=to.forwardRef(({className:e,style:o,canvasClassName:t,canvasStyle:r,isBound:a=!0,strokeWidth:i=2,strokeColor:s="#3A87FD",onChange:n,defaultValue:p,onChangeEnd:l,enableHistory:c=!1,isInline:m=!0,isDisabled:u,placeholder:d,clearLabel:f,undoLabel:y,redoLabel:b,footerClassName:_,canvasRef:z,value:g,footerStyle:h,"data-block-id":C,"data-block-class":w,"aria-label":P="Drawing canvas",description:k="This is a canvas for drawing using a mouse or touch input.",...N},R)=>{let I=F(Cd),B=to.useRef(null),[L,x]=to.useState(g?ki(g):p?ki(p):[]),S=to.useMemo(()=>({...rh,...N}),[N]),[H,j]=to.useState(),ae=useId(),{labelProps:ie,fieldProps:G}=useLabel({...N,"aria-label":P,labelElementType:"span"}),{isFocusVisible:U,focusProps:pe}=useFocusRing({within:!0}),{hoverProps:V,isHovered:Z}=useHover({isDisabled:u}),{undo:de,redo:Ie,canRedo:_e,canUndo:ze,push:he}=_n(L,{onAction:E=>{E&&(x(E),l?.(E.map(q=>getStroke(q,S))));},isDisabled:!c}),{keyboardProps:Ye}=useKeyboard({onKeyDown:E=>{E.key==="Backspace"?Vt():E.key==="z"&&(E.metaKey||E.ctrlKey)&&(E.shiftKey?_e&&Ie():ze&&de());}}),[ee,me]=useState(!1),ia=useCallback(E=>{let q=E.currentTarget.getBoundingClientRect();j(q),E.target.setPointerCapture(E.pointerId);let oe={x:E.clientX-q.x,y:E.clientY-q.y,pressure:E.pressure};x(W=>[...W,[oe]]),me(!0);},[]),sa=useCallback(E=>{if(E.buttons!==1||!H)return;let oe=Md(E.nativeEvent).map(W=>({x:a?clamp(W.clientX-H.left,0,H.width):W.clientX-H.left,y:a?clamp(W.clientY-H.top,0,H.height):W.clientY-H.top,pressure:W.pressure}));x(W=>{let Ne=[...W];return Ne[W.length-1]=[...Ne[W.length-1],...oe],Ne});},[H,a]),na=useCallback(()=>{H&&(l?.(L.map(E=>getStroke(E,S))),he(L),me(!1));},[H,l,L,he,S]),Ot=Ae();useGranularEffect(()=>{Ot||n?.(L.map(E=>getStroke(E,S)));},[L],[n,S,Ot]);let Vt=()=>{x([]),n?.([]),he([]);};return jsxs("div",{ref:T(B,R),className:classNames(wd,"BaselineUI-FreehandCanvas",e),style:o,"aria-disabled":u,"data-block-id":C,"data-block-class":w,children:[N.label||c?jsxs("div",{className:Rd({isInline:m}),children:[N.label?jsx(X,{type:"label",size:"sm",...ie,children:N.label}):jsx("span",{}),c?jsxs("div",{children:[jsx(D,{variant:"secondary",size:"sm",isDisabled:!ze||u,icon:UndoIcon,onPress:de,"aria-label":y||I.formatMessage("undo")}),jsx(D,{variant:"secondary",size:"sm",isDisabled:!_e||u,icon:RedoIcon,onPress:Ie,"aria-label":b||I.formatMessage("redo")})]}):null]}):null,jsxs("div",{role:"application",...mergeProps(pe,Ye,V,G),tabIndex:u?void 0:0,className:classNames(Dr({isInline:m,isHovered:Z}),kd({isFocusVisible:U,isInline:m,isDisabled:!!u}),t),"aria-describedby":N["aria-describedby"]||ae,style:r,ref:z,children:[jsx(VisuallyHidden,{children:jsx("div",{id:ae,children:k})}),jsx("svg",{width:r?.width||"100%",height:r?.height||"100%",onPointerDown:ia,onPointerMove:sa,onPointerUp:na,children:(g?ki(g):L).map((E,q,oe)=>q<oe.length-1||!ee?jsx(Sd,{points:E,options:S,strokeColor:s,strokeWidth:i},q):jsx(Ld,{points:E,options:S,strokeColor:s,strokeWidth:i},q))})]}),d||f?jsx("div",{style:h,className:classNames(Fr({isInline:m,isDisabled:u}),_),children:(L.length||!d)&&f?jsx(A,{size:"sm",variant:"ghost",label:f,isDisabled:u,onPress:Vt}):jsx(A,{size:"sm",variant:"ghost",label:d,isDisabled:!0})}):null]})});Td.displayName="FreehandCanvas";var Sd=to.memo(({points:e,options:o,strokeColor:t,strokeWidth:r})=>{let a=useMemo(()=>getSvgPathFromStroke(getStroke(e,o)),[e,o]);return jsx("path",{d:a,stroke:t,strokeWidth:r})});Sd.displayName="Stroke";var Ld=to.memo(({points:e,options:o,strokeColor:t,strokeWidth:r})=>{let a=useRef([]),i=useMemo(()=>{let s=[],n=Math.ceil(e.length/Hr);for(let p=0;p<n;p++)if(p===n-1){let l=e.slice(p*Hr-(p>0?1:0),p*Hr+Hr),c=getSvgPathFromStroke(getStroke(l,o));s.push(c),a.current[p]=c;}else s.push(a.current[p]);return s},[e,o]);return jsx(Fragment,{children:i.map((s,n)=>jsx("path",{d:s,stroke:t,strokeWidth:r},n))})});Ld.displayName="SplitStroke";var ki=e=>e.map(o=>o.map(([t,r])=>({x:t,y:r,pressure:0}))),Hr=60*3;function Md(e){if(typeof e.getCoalescedEvents=="function"){let o=e.getCoalescedEvents();return [e,...o.flatMap(t=>Md(t))]}return [e]}var Bd="_1vac7ws0",Dd=v({defaultClassName:"_1vac7ws1",variantClassNames:{isDragging:{true:"_1vac7ws2"}},defaultVariants:{},compoundVariants:[]});function Fd(e,o){let[t,r]=useState([]),a=()=>e?.flatMap(i=>[...o.querySelectorAll(i)]).map(i=>({current:i}));return useGranularEffect(()=>{r(a());},[],[a]),useGranularEffect(()=>{let i=a();r(i);},[e],[a]),t}function Hd(e){let{scrollable:o,ownerDocument:t,onScroll:r}=e;useEffect(()=>{let a=getHTMLElement(o,t);if(a)return (a.style.position==="static"||!a.style.position)&&console.warn("Scrollable ancestor passed to `Transform` component should not be statically positioned."),a.addEventListener("scroll",r),()=>{a.removeEventListener("scroll",r);}},[o,r,t]);}var zh=makeMoveable([Draggable,Resizable,Rotatable,Snappable]),Vd=to.forwardRef(({className:e,children:o,isRotatable:t,isResizable:r,isDraggable:a,style:i,onTransform:s,onTransformStart:n,onTransformEnd:p,onDoubleClick:l,onDragStart:c,onDragEnd:m,onDrag:u,onResizeStart:d,onResizeEnd:f,onResize:y,onRotateStart:b,onRotateEnd:_,onRotate:z,onSnap:g,isSnappable:h,elementGuidelines:C,hideAnchorOnDrag:w=!0,title:P,rotationPosition:k,autoUpdate:N,bound:R,snapRotationDegrees:I,snapRotationThreshold:B,scrollableAncestor:L,renderDirections:x,stopPropagation:S,transformOrigin:H,preventDefault:j},ae)=>{let ie=useRef(null),G=useRef(null),[U,pe]=useState(document),V=useRef(U.createElement("div")),[Z,de]=useState({}),[Ie,_e]=useState(!1),[ze,he]=useState(!1),[Ye,ee]=useState(),me=Fd(C,U);useLayoutEffect(()=>{let E=V.current;return V.current=U.createElement("div"),()=>{E.remove();}},[U]);let{keyboardProps:ia}=useKeyboard({onKeyDown:E=>{let q=E.shiftKey?10:1,oe=E.metaKey||E.ctrlKey;oe&&E.shiftKey&&(q=45);function W(Ne,Rf="x"){oe?G.current?.request("rotatable",{deltaRotate:Ne*q},!0):G.current?.request("draggable",Rf==="x"?{deltaX:Ne*q}:{deltaY:Ne*q},!0);}switch(E.key){case"ArrowRight":{W(1);break}case"ArrowLeft":{W(-1);break}case"ArrowUp":{W(-1,"y");break}case"ArrowDown":W(1,"y");}requestAnimationFrame(()=>{G.current?.updateRect();});}});useEffect(()=>{let E=be(ie.current);pe(E);let q=V.current;E.body.append(V.current);function oe(Ne){he(Ne.shiftKey);}function W(){he(!1);}return E.addEventListener("keydown",oe),E.addEventListener("keyup",W),()=>{E.removeEventListener("keydown",oe),E.removeEventListener("keyup",W),q.remove();}},[]),Hd({scrollable:L,onScroll:()=>{G.current?.updateRect();},ownerDocument:U});let sa=useCallback(E=>{de(q=>({...q,...E.style})),s?.(E);},[s]),na=useCallback(E=>{if(_e(!0),ie.current?.focus(),R){let oe=getHTMLElement(R,U)?.getBoundingClientRect();ee({position:"client",left:oe?.left??0,top:oe?.top??0,right:oe?.right??0,bottom:oe?.bottom??0});}c?.(E);},[R,U,c]),Ot=useCallback(E=>{_e(!1),m?.(E);},[m]),Vt=o({style:{...Z.width&&{width:Z.width},...Z.height&&{height:Z.height}}});return jsxs(Fragment,{children:[jsx("div",{role:"button",...ia,ref:T(ie,ae),style:{display:"inline-block",...i,...Z},className:classNames(Bd,e),onDoubleClick:l,tabIndex:0,title:P,children:Vt}),createPortal(jsx(zh,{ref:G,target:ie,draggable:a,resizable:r,rotatable:t,keepRatio:ze,throttleDrag:1,snappable:h||!!R,elementGuidelines:me,snapRenderThreshold:.9,className:Dd({isDragging:Ie&&w}),onRender:sa,onDragStart:na,onDragEnd:Ot,useResizeObserver:N,useMutationObserver:N,onRenderEnd:p,onDrag:u,onResizeStart:d,onResizeEnd:f,onResize:y,onRotateStart:b,onRotateEnd:_,onRotate:z,onRenderStart:n,onSnap:g,rotationPosition:k,bounds:Ye,snapRotationDegrees:I,snapRotationThreshold:B,renderDirections:x,stopPropagation:S,preventDefault:j,transformOrigin:H}),V.current)]})});Vd.displayName="Transform";var Ad={ar:{delete:"\u062D\u0630\u0641",selectImage:"\u062A\u062D\u062F\u064A\u062F \u0635\u0648\u0631\u0629"},cs:{delete:"Smazat",selectImage:"Vybrat obr\xE1zek"},cy:{delete:"Dileu",selectImage:"Dewiswch Ddelwedd"},da:{delete:"Slet",selectImage:"V\xE6lg billede"},de:{delete:"L\xF6schen",selectImage:"Bild ausw\xE4hlen"},el:{delete:"\u0394\u03B9\u03B1\u03B3\u03C1\u03B1\u03C6\u03AE",selectImage:"\u0395\u03C0\u03B9\u03BB\u03BF\u03B3\u03AE \u03B5\u03B9\u03BA\u03CC\u03BD\u03B1\u03C2"},"en-GB":{delete:"Delete",selectImage:"Select Image"},en:{delete:"Delete",selectImage:"Select Image"},es:{delete:"Eliminar",selectImage:"Seleccionar imagen"},fi:{delete:"Poista",selectImage:"Valitse kuva"},"fr-CA":{delete:"Supprimer",selectImage:"S\xE9lectionner une image"},fr:{delete:"Supprimer",selectImage:"S\xE9lectionner une image"},he:{delete:"\u05DE\u05D7\u05D9\u05E7\u05D4",selectImage:"\u05D1\u05D7\u05D9\u05E8\u05EA \u05EA\u05DE\u05D5\u05E0\u05D4"},hr:{delete:"Obri\u0161i",selectImage:"Odaberi sliku"},id:{delete:"Hapus",selectImage:"Pilih Gambar"},it:{delete:"Elimina",selectImage:"Seleziona immagine"},ja:{delete:"\u524A\u9664",selectImage:"\u30A4\u30E1\u30FC\u30B8\u3092\u9078\u629E"},ko:{delete:"\uC0AD\uC81C",selectImage:"\uC774\uBBF8\uC9C0 \uC120\uD0DD"},ms:{delete:"Padam",selectImage:"Pilih Imej"},"nb-NO":{delete:"Slett",selectImage:"Velg bilde"},nl:{delete:"Verwijder",selectImage:"Selecteer afbeelding"},pl:{delete:"Usu\u0144",selectImage:"Wybierz obraz"},"pt-PT":{delete:"Apagar",selectImage:"Selecionar imagem"},pt:{delete:"Apagar",selectImage:"Selecionar Imagem"},ru:{delete:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C",selectImage:"\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0438\u0437\u043E\u0431\u0440."},sk:{delete:"Zmaza\u0165",selectImage:"Vybra\u0165 obr\xE1zok"},sl:{delete:"Izbri\u0161i",selectImage:"Izberi sliko"},sv:{delete:"Radera",selectImage:"V\xE4lj bild"},th:{delete:"\u0E25\u0E1A",selectImage:"\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E23\u0E39\u0E1B\u0E20\u0E32\u0E1E"},tr:{delete:"Sil",selectImage:"Resim Se\xE7"},uk:{delete:"\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438",selectImage:"\u041E\u0431\u0440\u0430\u0442\u0438 \u0437\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u043D\u044F"},"zh-Hans":{delete:"\u5220\u9664",selectImage:"\u9009\u62E9\u56FE\u50CF"},"zh-Hant":{delete:"\u522A\u9664",selectImage:"\u9078\u53D6\u5716\u50CF"}};var Ud=to.forwardRef(({className:e,style:o,isInline:t=!0,accept:r="image/*",defaultImageSrc:a,imageSrc:i,imageAlt:s,pickerButtonLabel:n,isDisabled:p,onDrop:l,onPaste:c,includeCheckeredBackground:m=!0,"data-block-id":u,"data-block-class":d,pickerButtonStyle:f,pickerButtonClassName:y,footerClassName:b,footerStyle:_,clearLabel:z,placeholder:g,labelStyle:h,labelClassName:C,...w},P)=>{let k=to.useRef(null),N=to.useRef(null),{formatMessage:R}=F(Ad),[I,B]=useControlledState(i,a||null,ee=>{invariant(typeof ee!="string"),w.onValueChange?.(ee?[ee]:[]);}),L=useMemo(()=>Bh(I||void 0),[I]),{fieldProps:x,labelProps:S}=useField(w),{dropProps:H,isDropTarget:j}=useDrop({ref:k,onDrop:async ee=>{if(p)return;let me=await ja({items:ee.items});me.length&&B(me[0]),l?.(ee);},...w}),{clipboardProps:ae}=useClipboard({onPaste:async ee=>{if(p)return;let me=await ja({items:ee});me.length&&B(me[0]),c?.(ee);},...w}),ie=()=>{B(null),N.current&&(N.current.value="");},G={type:"file",onChange:ee=>{let me=[...ee.target.files];B(me[0]),w.onChange?.(ee);},accept:r,disabled:p},{focusProps:U,isFocused:pe,isFocusVisible:V}=useFocusRing({within:!0}),{hoverProps:Z,isHovered:de}=useHover({isDisabled:p}),{imgProps:Ie,isLoading:_e,isLoaded:ze}=bo({src:L,alt:s||""}),he={label:n||R("selectImage"),onPress:()=>k.current?.click(),variant:"secondary",isDisabled:p,excludeFromTabOrder:!0,className:classNames(Wt({isFocusVisible:V}),{[Pd]:j&&!p},y),style:f},Ye=filterTruthyValues({"data-loaded":ze,"data-block-id":u,"data-block-class":d,"data-hovered":de,"data-focused":pe,"data-drop-target":j,"data-disabled":p,"data-focus-visible":V});return jsxs(M,{...Ye,className:classNames("BaselineUI-ImageDropZone",e),display:"flex",flexDirection:"column",alignItems:"center",style:o,ref:P,children:[jsxs("label",{...mergeProps(H,Z,U,S),className:classNames(Dr({isInline:t,isHovered:de,isDisabled:p,hasLoadedImage:!!L&&ze,showFocusRing:j||!!L&&V}),C),style:h,ref:k,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(x,ae,G),ref:N})}),!L&&jsx(A,{...he}),!!L&&(_e?jsx(No,{}):jsx("img",{className:Er({isInline:t,isDisabled:p,hasLoadedImage:!!L&&ze&&m}),...Ie}))]}),g||z?jsx("div",{style:_,className:classNames(Fr({isInline:t,isDisabled:p}),b),children:(L||!g)&&z?jsx(A,{size:"sm",variant:"ghost",label:z,isDisabled:p,onPress:ie}):jsx(A,{size:"sm",variant:"ghost",label:g,isDisabled:!0})}):null]})});Ud.displayName="ImageDropZone";function Bh(e){return e instanceof File?URL.createObjectURL(e):e}var qd="_1vm2oh49 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6fv",Ni="_1vm2oh48 _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6jc _1yep5z6jd _1yep5z6je",Kd=v({defaultClassName:"_1vm2oh40 mnnh5s1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6l1 _1yep5z6kz _1yep5z6hk _1yep5z6l2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kx _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{accent:{theme:"_1vm2oh41",positive:"_1vm2oh42"},isInline:{true:"mnnh5s2 _1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6121 _1yep5z616i _1yep5z616k",false:"_1yep5z611g"},isFocusVisible:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 z9nup83 _1yep5z6yl"},isHovered:{true:"_1vm2oh47"}},defaultVariants:{},compoundVariants:[[{accent:"positive",isInline:!0},"_1yep5z61mp"],[{accent:"theme",isInline:!0},"_1yep5z61me"],[{accent:"positive",isInline:!1},"_1yep5z61mr"],[{accent:"theme",isInline:!1},"_1yep5z61mg"],[{isFocusVisible:!0,isInline:!0},"_1yep5z61ny _1yep5z61rl _1yep5z61rn _1yep5z61ro"],[{isHovered:!0,isInline:!0},"_1yep5z61ro _1yep5z61ny _1yep5z61rl _1yep5z61rn"],[{isHovered:!0,isInline:!1,accent:"positive"},"_1yep5z61mq"],[{isHovered:!0,isInline:!1,accent:"theme"},"_1yep5z61mi"],[{isHovered:!0,isInline:!0,accent:"theme"},"_1yep5z61mf"]]});var Xd=to.forwardRef(({className:e,style:o,isDisabled:t,isInline:r=!0,imageAlt:a,imageSrc:i,svgSrc:s,textValue:n,textStyle:p,onPress:l,onDelete:c,deleteAriaLabel:m,addAriaLabel:u,accent:d="positive","data-block-id":f,"data-block-class":y,...b},_)=>{let{focusProps:z,isFocused:g,isFocusVisible:h}=useFocusRing({within:!0}),{isHovered:C,hoverProps:w}=useHover({isDisabled:t}),{pressProps:P}=usePress({isDisabled:t,onPress:l});invariant(i||s||n,"Preview must have content. You must provide either an `imageSrc`, `svgSrc`, or `textValue` prop.");let k=filterTruthyValues({"data-hovered":C,"data-focus-visible":h,"data-focused":g,"data-disabled":t});return jsxs("div",{...b,className:classNames(Kd({isInline:r,isFocusVisible:h,isDisabled:t,isHovered:C,accent:d}),"BaselineUI-Preview",e),"data-block-id":f,"data-block-class":y,"aria-label":b["aria-label"]||a||n,style:o,ref:_,children:[typeof s=="string"?jsx("button",{disabled:t,...mergeProps(w,z,P,k),className:Ni,"aria-label":u,dangerouslySetInnerHTML:{__html:s}}):jsxs("button",{...mergeProps(w,z,P,k),disabled:t,style:p,"aria-label":u,className:Ni,children:[i?jsx("img",{src:i,alt:a,className:Er({isInline:r,isDisabled:t})}):null,!!s&&typeof s=="object"&&s,n]}),c?jsx(D,{isDisabled:t,className:qd,"aria-label":m,size:"xs",icon:TrashIcon,onPress:c}):null]})});Xd.displayName="Preview";var Yd="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e",Zd=v({defaultClassName:"cw3m0n8 _1yep5z6ew _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Qd="cw3m0n7",Jd=v({defaultClassName:"cw3m0n0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),em="_1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ks",om=v({defaultClassName:"cw3m0n3 _16vugd05",variantClassNames:{isFocusVisible:{true:"_16vugd08"},isSelected:{true:"_16vugd07"},isDisabled:{true:"_16vugd0a"}},defaultVariants:{},compoundVariants:[]});var Zh=({label:e,description:o},{isSelected:t,isFocusVisible:r,isDisabled:a,optionLabelPosition:i})=>jsxs("div",{className:Jd({labelPosition:i}),children:[jsx("div",{className:om({isSelected:t,isFocusVisible:r,isDisabled:a}),children:t?jsx("div",{className:Qd}):null}),e?jsxs("div",{className:Yd,children:[jsx("span",{className:br({isDisabled:a}),children:e}),o?jsx("span",{className:Zd({isDisabled:a}),children:o}):null]}):null]}),tm=({state:e,renderOption:o=Zh,item:t,optionLabelPosition:r="end",optionStyle:a,optionClassName:i,isReadOnly:s,...n})=>{let p=!!n.isDisabled||!!n.disabledValues?.includes(t.id),l=to.useRef(null),{inputProps:c,isPressed:m,isSelected:u}=useRadio({...n,isDisabled:p,children:t.label,value:t.id},e,l),{focusProps:d,isFocusVisible:f,isFocused:y}=useFocusRing(),{isHovered:b}=useHover({isDisabled:p}),_=filterTruthyValues({"data-selected":u,"data-focused":y,"data-focus-visible":f,"data-hovered":b,"data-disabled":p,"data-pressed":m,"data-read-only":s});return jsxs("label",{..._,style:a,className:classNames("BaselineUI-Radio-Item",i),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(c,d),ref:l})}),o(t,{isFocusVisible:f,isSelected:u,isFocused:y,isHovered:b,isDisabled:p,optionLabelPosition:r,isReadOnly:s})]})};var jr=to.forwardRef(({className:e,style:o,optionsContainerClassName:t,optionsContainerStyle:r,items:a,labelPosition:i="top",renderOption:s,"aria-label":n,"aria-labelledby":p,"aria-describedby":l,"aria-details":c,"data-block-id":m,"data-block-class":u,...d},f)=>{let y=useRadioGroupState(d),{radioGroupProps:b,labelProps:_,descriptionProps:z,errorMessageProps:g}=useRadioGroup({...d,"aria-label":n,"aria-labelledby":p,"aria-describedby":l,"aria-details":c},y),h=xe({...d,descriptionProps:z,errorMessageProps:g,labelPosition:i}),C=filterTruthyValues({"data-orientation":d.orientation,"data-block-id":m,"data-block-class":u,"data-disabled":d.isDisabled,"data-readonly":d.isReadOnly});return jsxs("div",{...mergeProps(b,C),className:classNames(Oe({labelPosition:i}),"BaselineUI-RadioGroup",e),style:o,ref:f,children:[d.label||h?jsxs("div",{className:He({labelPosition:i,hasMessage:!!h}),children:[jsx("span",{..._,className:classNames(Fe,"BaselineUI-RadioGroup-Label"),children:d.label}),i==="start"&&h]}):null,jsxs("div",{className:classNames({[po]:d.isDisabled}),children:[jsx("div",{className:classNames(em,t),style:r,children:a.map(w=>jsx(tm,{state:y,renderOption:s,item:w,...d,value:w.id},w.id))}),i==="top"&&h]})]})});jr.displayName="RadioGroup";var rm=({id:e,defaultMessage:o,elementType:t=Fragment$1})=>{invariant(e||o,"`id` or `defaultMessage` is required.");let r=F();return jsx(t,{children:r.formatMessage(e)||o})};rm.displayName="MessageFormat";var am=to.forwardRef(({className:e,style:o,children:t,role:r="group",isDisabled:a,...i},s)=>{let{hoverProps:n,isHovered:p}=useHover({isDisabled:a});return jsx("div",{...n,role:r,"data-hovered":p,"data-disabled":a,className:e,style:o,...i,ref:s,children:t})});am.displayName="Group";var $r="_46ioju0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e",Ur="_1yep5z61ov _1yep5z61ow _1yep5z61ox _1yep5z61g1 _1yep5z61g2 _1yep5z61g3";var sm=to.forwardRef(({items:e,optionsContainerClassName:o,...t},r)=>{let a=useMemo(()=>e.map(i=>({id:i.color,label:i.label})),[e]);return useEffect(()=>{console.warn("`ColorPresetInlineInput` is deprecated. Please use `ColorSwatchPicker` instead.");},[]),jsx(jr,{items:a,optionsContainerClassName:classNames(Ur,o),orientation:"horizontal",renderOption:({label:i,id:s},{isSelected:n,isFocusVisible:p})=>jsx("div",{className:$r,children:jsx(we,{isFocusVisible:p,color:s,isSelected:n,"aria-label":i,isInteractive:!0})}),...t,className:classNames(t.className,"BaselineUI-ColorPresetInput"),ref:r})});sm.displayName="ColorPresetInput";var Di="UNSUPPORTED_IN_MENU";function pm(e){return useMemo(()=>to.Children.toArray(e).map(o=>{let t=o,r=uniqueId("item"),a=xt(t,Se),i=lm(t),s,n;if(a){let _=xt(a,Le);invariant(_),s=lm(_),n=xt(a,Pe).props.children;}else i?s=i:s=t;let{onPress:p,label:l,"aria-label":c,iconStart:m,isDisabled:u,icon:d}=s.props,f=l||c||Di;invariant(typeof f=="string","ActionGroup children must have a string label");let y=`${r}-${f}`;return createElement(Item,{...{key:y,onPress:p,textValue:f,"aria-label":c,icon:m||d,dialogContent:n,isDisabled:u},key:y},t)}),[e])}function xt(e,o){return o?flatMapDeep(to.Children.toArray(e),r=>to.isValidElement(r)&&r.props.children?[r,...to.Children.toArray(r.props.children)]:[r]).find(r=>to.isValidElement(r)&&r.type===o):void 0}function lm(e){return xt(e,A)||xt(e,D)}var cm="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6kn",dm={horizontal:"xvr3wn0",vertical:"xvr3wn1"};var Fi=to.forwardRef(({className:e,style:o,children:t,collapsibleMenuProps:r,"data-block-id":a,"data-block-class":i,renderSpacer:s,...n},p)=>{let{formatMessage:l}=F(),[c,m]=useState(),u=pm(t),d=useListState({...n,children:u}),f=ge(p),y=useRef(null),[{visibleItems:b,isMeasuring:_},z]=pa({visibleItems:d.collection.size,isMeasuring:!1}),g=useCallback(()=>{let R=I=>{if(y.current&&f.current){let B=[...y.current.children],L=f.current.getBoundingClientRect().width,x=I<d.collection.size,S=0,H=0;if(x){let j=B.pop();j&&(S+=ym(j,!1,!0));}for(let[j,ae]of B.entries())if(S+=ym(ae,j===0,j===B.length-1),Math.round(S)<=Math.round(L))H++;else break;return H}return I};z(function*(){yield {visibleItems:d.collection.size,isMeasuring:!0};let I=R(d.collection.size),B=I<d.collection.size&&I>0;yield {visibleItems:I,isMeasuring:B},B&&(yield {visibleItems:R(I),isMeasuring:!1});});},[z,f,d.collection.size]),h=useMemo(()=>({get current(){return f.current?.parentElement}}),[f]);fa({ref:h,onResize:g}),Te(g,[d.collection,g]);let{toolbarProps:C}=useToolbar(n,f),w=[...d.collection],P=w.slice(0,b),k=w.slice(b).filter(R=>R.textValue!==Di),N=k.length>0;return useEffect(()=>{m(void 0);},[k.length]),useEffect(()=>{n.orientation==="vertical"&&console.warn("Toolbar: Vertical orientation is not supported when `isCollapsible` is true.");},[n.orientation]),jsxs(FocusScope,{children:[jsx("div",{...C,className:e,"data-block-id":a,"data-block-class":i,"data-collapse":!0,style:{...o,flexBasis:_?"100%":void 0},ref:f,children:jsxs("div",{ref:y,className:cm,children:[P.map(R=>R.rendered),N?jsxs(Fragment,{children:[!_&&s?.(),jsx(dr,{placement:"bottom end",renderTrigger:({buttonProps:R,ref:I})=>jsx(D,{...R,size:"md",icon:MoreIcon,"aria-label":l(kx.more),variant:"toolbar",ref:I}),...r,disabledKeys:k.filter(R=>R.props?.isDisabled).map(R=>R.key),items:k.map(R=>{let I=R.textValue||R["aria-label"];return invariant(I,"ActionItem must have a label"),{id:R.key,label:I,icon:R.props.icon}}),onAction:R=>{let I=d.collection.getItem(R);invariant(I,"Item not found");let{onPress:B,dialogContent:L}=I.props;B?.(),m(L);}})]}):null]})}),jsx(Ce,{isOpen:!!c,onOpenChange:R=>{R||m(void 0);},children:jsx(Be,{enableDrawer:"auto",style:{zIndex:1e5},children:c?to.cloneElement(c,{inheritDrawer:!0}):null})})]})});Fi.displayName="CollapsibleToolbar";function ym(e,o,t){let a=Q(e).getComputedStyle(e);return e.getBoundingClientRect().width+(o?0:bm(a.marginLeft))+(t?0:bm(a.marginRight))}function bm(e){let o=Number.parseInt(e,10);return Number.isNaN(o)?0:o}var kx=$({more:{id:"more",defaultMessage:"More"}});var Hi=to.forwardRef(({className:e,style:o,"data-block-id":t,"data-block-class":r,"aria-controls":a,...i},s)=>{let n=to.useRef(null),{toolbarProps:p}=useToolbar(i,n);return jsx("div",{...p,"aria-controls":a,className:classNames(dm[i.orientation||"horizontal"],"BaselineUI-Toolbar",e),style:o,"data-block-id":t,"data-block-class":r,ref:T(s,n),children:i.children})});Hi.displayName="WrappedToolbar";var qr=to.forwardRef((e,o)=>{let t=e.isCollapsible?Fi:Hi;return jsx(t,{...e,ref:o})});qr.displayName="Toolbar";var vm=v({defaultClassName:"_1j5skr71",variantClassNames:{size:{xxs:"_1j5skr72",xs:"_1j5skr73",sm:"_1j5skr74",md:"_1j5skr75",lg:"_1j5skr76"}},defaultVariants:{},compoundVariants:[]}),_m=v({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7g"},isFocusVisible:{true:"_1j5skr7h"},isDisabled:{true:"z9nup83 _1yep5z610d"},isSelected:{true:"_1j5skr7j"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61rl _1yep5z61o5 _1yep5z61lo"],[{isSelected:!1,isHovered:!0,isDisabled:!1},"_1yep5z6fu"],[{isSelected:!1,isFocusVisible:!0,isDisabled:!1},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0,isDisabled:!1},"_1j5skr7k _1yep5z61rm _1yep5z61rl _1yep5z61nz _1yep5z61lp"],[{isSelected:!0,isFocusVisible:!1,isDisabled:!1},"_1yep5z61rl _1yep5z61rn _1yep5z61ny _1yep5z61ro"]]}),zm=v({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7m"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1yep5z610c"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61ln"]]}),hm=v({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7r"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1j5skr7t"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!0,isDisabled:!1},"_1yep5z61mg _1yep5z61lq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61mg _1yep5z61lo"]]}),xm=v({defaultClassName:"_1j5skr77 _1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr78"},isFocusVisible:{true:"_1j5skr79"},isSelected:{true:"_1j5skr7a"},isDisabled:{true:"_1j5skr7b z9nup83 _1yep5z610e"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1},"_1j5skr7c _1yep5z61lp"],[{isSelected:!1,isDisabled:!0},"_1j5skr7d _1yep5z61lo"],[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!1,isFocusVisible:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0},"_1j5skr7e _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]});var Vx={xxs:8,xs:12,sm:16,md:20,lg:24},ve=to.forwardRef(({className:e,style:o,icon:t,size:r="md",variant:a="primary","data-block-id":i,"data-block-class":s,...n},p)=>{let l=useToggleState(n),{buttonProps:c,isPressed:m,ref:u}=Gt(n,l),{hoverProps:d,isHovered:f}=useHover({isDisabled:n.isDisabled}),{isFocusVisible:y,isFocused:b,focusProps:_}=useFocusRing(),z=useMemo(()=>typeof t=="function"?t:l.isSelected?t.selected:t.unselected,[t,l.isSelected]),g={isSelected:l.isSelected,isHovered:f,isFocusVisible:y,isDisabled:!!n.isDisabled},h=filterTruthyValues({"data-hovered":f,"data-selected":l.isSelected,"data-focus-visible":y,"data-disabled":n.isDisabled,"data-block-id":i,"data-block-class":s,"data-focused":b,"data-pressed":m});return jsx("button",{...mergeProps(c,d,_,h),className:classNames(a==="toolbar"&&xm(g),a==="primary"&&_m(g),a==="secondary"&&zm(g),a==="tertiary"&&hm(g),vm({size:r}),"BaselineUI-ToggleIconButton",e),style:o,ref:T(u,p),children:jsx(z,{size:Vx[r]})})});ve.displayName="ToggleIconButton";var Pm="f6jv6bm",km="_1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z6j0 _1yep5z6j1 _1yep5z6j2",Ho="_1yep5z689 _1yep5z68a _1yep5z68b _1yep5z65x _1yep5z65y _1yep5z65z",wm=v({defaultClassName:"f6jv6b0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6fs",variantClassNames:{isInline:{true:"f6jv6b1"},isMinimal:{true:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6uw _1yep5z6ux _1yep5z6uy _1yep5z6142 _1yep5z6143 _1yep5z6144",false:"_1yep5z613n _1yep5z613o _1yep5z613p"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isMinimal:!1},"_1yep5z61h7 _1yep5z61h8 _1yep5z61h9 _1yep5z61hv _1yep5z61hw _1yep5z61hx _1yep5z61ij _1yep5z61ik _1yep5z61il _1yep5z61j7 _1yep5z61j8 _1yep5z61j9 _1yep5z61rv _1yep5z61rt _1yep5z61nc"]]}),Kr=v({defaultClassName:"f6jv6b4 _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6e3 _1yep5z6eu _1yep5z6ky",variantClassNames:{isDisabled:{true:"f6jv6b5 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Rm="f6jv6bj _1yep5z6vz _1yep5z6w0 _1yep5z6w1 _1yep5z6wn _1yep5z6wo _1yep5z6wp _1yep5z6xb _1yep5z6xc _1yep5z6xd _1yep5z6xz _1yep5z6y0 _1yep5z6y1",Im="f6jv6bk";var Nm="f6jv6bn _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6l6 _1yep5z6l1 _1yep5z6kz _1yep5z6hc _1yep5z6eu",Tm=v({defaultClassName:"f6jv6bf _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6kx",variantClassNames:{isHovered:{true:"_1yep5z6115"},isDisabled:{true:"_1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),Sm="f6jv6bi _1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs _1yep5z6l0 _1yep5z6kz _1yep5z6hf _1yep5z6l3",Lm="_1yep5z6j6 _1yep5z6j7 _1yep5z6j8",Mm="f6jv6be f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu _1yep5z6e3 _1yep5z6kv",Bm=v({defaultClassName:"f6jv6bb _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jc _1yep5z6jd _1yep5z6je",variantClassNames:{isInline:{true:"_1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z616k _1yep5z616i _1yep5z6121",false:"_1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg"}},defaultVariants:{},compoundVariants:[]}),Dm="f6jv6bl",Em="f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu",Gr=v({defaultClassName:"f6jv6b6",variantClassNames:{isInline:{true:"f6jv6b7",false:"f6jv6b8"}},defaultVariants:{},compoundVariants:[]}),Wr="f6jv6b9 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it",Pt="f6jv6bo";var Hm=[["Toolbar Focus","Alt+F10"],["Bold","Ctrl+B"],["Italic","Ctrl+I"],["Underline","Ctrl+U"],["Select All","Ctrl+A"],["Cut","Ctrl+X"],["Copy","Ctrl+C"],["Paste","Ctrl+V"],["Undo","Ctrl+Z"],["Redo","Ctrl+Shift+Z"],["Submit","Ctrl+Enter"],["Open Help Dialog","Ctrl+Shift+H"]],{dialog:{row:kt}}=layoutSprinkleValues,Om=({isOpen:e,onClose:o})=>{let{formatMessage:t}=F(),r=useId();return jsx(Ce,{isOpen:e,onOpenChange:a=>{a||o();},children:jsx(Be,{enableDrawer:"auto",style:{zIndex:999999},children:jsxs(le,{"aria-labelledby":r,className:Rm,drawerBackground:"subtle",children:[jsxs(M,{paddingLeft:kt.padding.horizontal.lg,paddingRight:kt.padding.horizontal.sm,display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",backgroundColor:"background.primary.subtle",className:Im,children:[jsx(X,{id:r,elementType:"h3",type:"title",size:"md",children:t(wt.help)}),jsx(D,{icon:XIcon,size:"md",variant:"secondary","aria-label":t(wt.close),onPress:o})]}),jsx(O,{className:Dm}),jsxs(M,{paddingX:kt.padding.horizontal.lg,role:"table","aria-labelledby":r,backgroundColor:"background.primary.subtle",children:[jsx("div",{role:"rowgroup",children:jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:kt.padding.vertical.md,color:"text.primary",children:[jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",children:t(wt.action)}),jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",style:{textTransform:"capitalize"},children:t(wt.shortcut)})]})}),jsx("div",{role:"rowgroup",children:Hm.map(([a,i],s)=>jsxs(Fragment$1,{children:[jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:kt.padding.vertical.xs,style:{minHeight:40},children:[jsx(X,{type:"subtitle",size:"sm",role:"cell",children:t(wt[camelCase(a)])}),jsx(X,{elementType:"kbd",type:"subtitle",size:"sm",role:"cell",children:getOsSpecificKeyboardShortcutLabel(i,!0)})]}),s!==Hm.length-1&&jsx(O,{})]},a))})]})]})})})},wt=$({toolbarFocus:{id:"toolbarFocus",defaultMessage:"Toolbar Focus"},help:{id:"help",defaultMessage:"Help"},close:{id:"close",defaultMessage:"Close"},action:{id:"action",defaultMessage:"Action"},shortcut:{id:"shortcut",defaultMessage:"Shortcut"},bold:{id:"bold",defaultMessage:"Bold"},italic:{id:"italic",defaultMessage:"Italic"},underline:{id:"underline",defaultMessage:"Underline"},selectAll:{id:"selectAll",defaultMessage:"Select All"},cut:{id:"cut",defaultMessage:"Cut"},copy:{id:"copy",defaultMessage:"Copy"},paste:{id:"paste",defaultMessage:"Paste"},undo:{id:"undo",defaultMessage:"Undo"},redo:{id:"redo",defaultMessage:"Redo"},openHelpDialog:{id:"openHelpDialog",defaultMessage:"Open Help Dialog"},submit:{id:"submit",defaultMessage:"Submit"}});var Xr=to.forwardRef(({value:e,defaultValue:o,onChange:t,placeholder:r,spellCheck:a,textBoxRef:i,isInline:s,isMinimal:n,isDisabled:p,editableContentAriaLabel:l,editorHandle:c,autoFocus:m,saveOnEnter:u,onSave:d},f)=>{let y=to.useRef(null),[b,_]=useControlledState(e,o||"",t),z=useCallback(I=>{_(I.currentTarget.value||"");},[_]),g=useCallback(I=>{(u&&I.key==="Enter"&&!I.shiftKey||(I.ctrlKey||I.metaKey)&&I.key==="Enter")&&(I.preventDefault(),d());},[u,d]);useImperativeHandle(f,()=>({clear:()=>{_("");}}));let h=useCallback(I=>{I.currentTarget.style.height="16px",I.currentTarget.style.height=I.currentTarget.scrollHeight+"px";},[]);useGranularLayoutEffect(()=>{let I=y.current;I&&(I.style.height="16px",I.style.height=I.scrollHeight+"px");},[n],[b]),useImperativeHandle(c,()=>({setCaretPosition:I=>{y.current&&(y.current.focus(),y.current.setSelectionRange(I,I));}}));let{focusProps:C,isFocused:w,isFocusVisible:P}=useFocusRing(),{hoverProps:k,isHovered:N}=useHover({}),R=filterTruthyValues({"data-focus-visible":P,"data-hovered":N,"data-focused":w});return jsx("textarea",{...mergeProps(C,k,R),ref:T(y,i),className:classNames(n?Mm:[Kr(),Gr({isInline:s}),Em]),autoFocus:m,onChange:z,disabled:p,onInput:h,value:b,placeholder:r,spellCheck:a,"aria-label":l,onKeyDown:g})});Xr.displayName="PlainEditor";var Nt="mention",Yr="mention_input",Zm=to.forwardRef(({onCancel:e,editor:o,element:t,onSelectionChange:r},a)=>{let{containerRef:i,items:s,maxMentionableUsersSuggestions:n}=useContext(Qr),p=useSelected(),[l,c]=useState(""),{contains:m}=useFilter({sensitivity:"base"}),{formatMessage:u}=F(),d=useMemo(()=>{let x=s.filter(S=>l===""||m(S.displayName,l)).map(S=>({id:S.id,label:S.displayName,data:S}));return n?take(x,n):x},[s,n,l,m]),f=useCallback(x=>jsx(Item,{children:x.label},x.id),[]),y=useCallback((x=!1)=>{let S=findNodePath(o,t);S&&(removeNodes(o,{at:S}),x&&focusEditor(o));},[o,t]),b=useComboBoxState({items:d,children:f,menuTrigger:"focus",onSelectionChange:x=>{y(!0),r?.(x);}}),_=to.useRef(null),z=to.useRef(null),g=to.useRef(null),h=to.useRef(null),C=useHTMLInputCursorState(z);useInteractOutside({ref:h,onInteractOutside:()=>{b.close();}});let{inputProps:w,listBoxProps:P}=useComboBox({defaultItems:d,inputRef:z,buttonRef:_,listBoxRef:g,popoverRef:h,menuTrigger:"focus","aria-label":u(hC.mention)},b);useEffect(()=>{z.current?.focus();},[]);let k=useCallback((x="manual",S=!1)=>{y(S),e?.(x,b.inputValue);},[e,y,b.inputValue]),N=useRef(p);useEffect(()=>{N.current&&!p&&k("deselect"),N.current=p;},[p,k]);let R=C?.atStart??!1,I=C?.atEnd??!1,B=useCallback(x=>{x.key==="Backspace"&&R?k("backspace",!0):x.key==="Escape"?k("escape",!0):x.key==="ArrowLeft"&&R?k("arrowLeft",!0):x.key==="ArrowRight"&&I&&k("arrowRight",!0);let S=Hotkeys.isUndo(x)&&o.history.undos.length>0,H=Hotkeys.isRedo(x)&&o.history.redos.length>0;(S||H)&&(x.preventDefault(),o[S?"undo":"redo"](),focusEditor(o));},[R,I,k,o]),L=useMemo(()=>{if(!CSS.supports("field-sizing","content")){let x=Q(z.current),S=z.current?x?.getComputedStyle(z.current).font:void 0;return {width:S?getTextDimensions({text:b.inputValue,font:S}).width+10:"4ch"}}},[b.inputValue]);return jsxs(Ze.Provider,{value:b,children:[jsx("input",{...mergeProps(w,{onKeyDown:B,onBlur:()=>{k("blur",!0);},onChange:x=>{c(x.target.value);}}),style:L,className:Nm,ref:T(a,z)}),b.isOpen?jsx(ce,{triggerRef:i,className:Sm,isNonModal:!0,ref:h,state:b,children:jsx(re,{...P,items:void 0,autoFocus:"first",ref:g,className:sprinkles({width:"full"}),renderOption:Jm})}):null]})});Zm.displayName="MentionInputContentElement";var $i=withRef(({className:e,...o},t)=>{let{children:r,editor:a,element:i}=o,{items:s}=useContext(Qr),n=useRef(null),[p,l]=useState(null);useEffect(()=>{let u=findNodePath(a,i);if(!u)return;let d=getPointBefore(a,u);if(!d)return;let f=createPointRef(a,d);return l(f),()=>{f.unref();}},[a,i]);let c=useCallback(()=>{let u=n.current?.getRootNode()instanceof ShadowRoot;moveSelection(a,{unit:"offset"}),moveSelection(a,{unit:"character",distance:1}),Go()&&u&&focusEditor(a);},[a]),m=useCallback(u=>{if(!u)return;let d=n.current?.getRootNode()instanceof ShadowRoot,f=s.find(b=>b.id===u);invariant(f,"User not found");let y={type:Nt,value:f.id,displayName:f.displayName,children:[{text:""}]};insertNodes(a,[y,{text:" "}]),d?setTimeout(()=>{c();},0):c();},[a,s,c]);return jsxs(PlateElement,{as:"span","data-slate-value":i.value,contentEditable:!1,className:e,ref:t,...o,children:[jsx(Zm,{onCancel:(u,d)=>{u!=="backspace"&&insertText(a,"@"+d,{at:p?.current??void 0}),(u==="arrowLeft"||u==="arrowRight")&&moveSelection(a,{distance:1,reverse:u==="arrowLeft"});},onSelectionChange:m,ref:n,element:i,editor:a}),r]})});$i.displayName="MentionInputElement";var Ui=withRef(({className:e,onClick:o,children:t,...r},a)=>{let i=useElement();return jsxs(PlateElement,{as:"span",className:e,contentEditable:!1,"data-user-id":i.value,onClick:getHandler(o,i),ref:a,...r,children:["@",i.displayName,t]})});Ui.displayName="MentionElement";var Qm=(e,{options:{trigger:o,triggerPreviousCharPattern:t,triggerQuery:r}})=>{let{insertText:a}=e,i=s=>s===o;return e.insertText=s=>{if(!e.selection||!i(s)||r&&!r(e)){a(s);return}let n=getEditorString(e,getRange(e,e.selection,getPointBefore(e,e.selection)));if(t?.test(n)){Zr(e);return}a(s);},e},hC=$({mention:{defaultMessage:"Mention",id:"mention"}});function ou({className:e,children:o,...t}){return jsx(PlateElement,{asChild:!0,className:e,...t,children:jsx("p",{children:o})})}function FC(e){return Object.entries(e).map(([o,t])=>`${kebabCase(o)}:${t}`).filter(([,o])=>!!o).join(";")}function HC(e){return "text"in e}function Tt(e){if(!e)return "";function o(t){if(HC(t)){let a=t.text;return t.bold&&(a=`<b>${a}</b>`),t.italic&&(a=`<i>${a}</i>`),t.underline&&(a=`<u>${a}</u>`),(t.color||t.backgroundColor)&&(a=`<span style="${FC(filterTruthyValues({color:t.color||void 0,backgroundColor:t.backgroundColor||void 0}))}">${a}</span>`),a}let r=t.children?.map(Tt).join("");switch(t.type){case ELEMENT_PARAGRAPH:return `<p>${r}</p>`;case ELEMENT_LINK:return `<a href="${t.url}">${r}</a>`;case Nt:return `<span data-user-id="${t.value}">${t.displayName}</span>`;default:return r}}return Array.isArray(e)?e.map(t=>o(t)).join(""):o(e)}function OC(e){return e?(e=e.trim(),e.endsWith(";")&&(e=e.slice(0,-1)),Object.fromEntries(e.split(";").map(o=>o.split(":").map(t=>t.trim())).map(([o,t])=>[camelCase(o),t]))):{}}function Xi(e){e.startsWith("<p>")||(e=`<p>${e}</p>`);let o=new DOMParser().parseFromString(tu.default.sanitize(e),"text/html"),t=o.querySelectorAll("[style]");for(let a of t)a.style.textDecoration==="underline"&&(a.style.textDecoration="",a.style.cssText||a.removeAttribute("style"),a.hasAttributes()?a.innerHTML=`<u>${a.innerHTML}</u>`:a.outerHTML=`<u>${a.innerHTML}</u>`);let r=o.querySelectorAll("br");for(let a of r)a.outerHTML=a.closest("p")?`
52
+ `:"<p>";return au(o.body)}function au(e,o){if(e.nodeType===Node.TEXT_NODE)return jsx$1("text",o,e.textContent);if(e.nodeType!==Node.ELEMENT_NODE)return null;let t={...o};switch(e.nodeName.toUpperCase()){case"B":{t.bold=!0;break}case"I":{t.italic=!0;break}case"EM":{t.italic=!0;break}case"U":{t.underline=!0;break}case"SPAN":{let a=OC(e.getAttribute("style")||"");a["text-decoration"]==="underline"&&(t.underline=!0),a.color&&(t.color=a.color),a.backgroundColor&&(t.backgroundColor=a.backgroundColor);break}}let r=[...e.childNodes].flatMap(a=>au(a,t));switch(r.length===0&&r.push(jsx$1("text",t,"")),e.nodeName.toUpperCase()){case"BR":return jsx$1("text",o,`
53
+ `);case"SPAN":{let a=e.dataset.userId;return a?jsx$1("element",{type:Nt,value:a,displayName:e.textContent},{text:""}):r}case"P":return jsx$1("element",{type:ELEMENT_PARAGRAPH},r);case"A":return jsx$1("element",{type:ELEMENT_LINK,url:e.getAttribute("href")},r);default:return r}}function iu(e){let o=findNode(e,{match:{type:getPluginType(e,ELEMENT_LINK)}}),[t]=o||[{url:""}];return t?.url}function Zr(e){let o={children:[{text:" "}],type:Yr};e.insertNode(o);}var VC=createPluginFactory({isElement:!0,isInline:!0,isMarkableVoid:!0,isVoid:!0,key:Nt,options:{trigger:"@",triggerPreviousCharPattern:/^$|^[\s"']$/},plugins:[{isElement:!0,isInline:!0,isVoid:!0,key:Yr}],withOverrides:Qm}),su=createPlugins([createParagraphPlugin({component:ou}),createBoldPlugin({component:withProps(PlateLeaf,{as:"b"})}),createItalicPlugin({component:withProps(PlateLeaf,{as:"i"})}),createUnderlinePlugin({component:withProps(PlateLeaf,{as:"u"})}),createFontColorPlugin(),createFontBackgroundColorPlugin(),createLinkPlugin({component:nu}),VC({component:Ui})],{components:{[Yr]:$i}});var du=({isDisabled:e})=>{let{formatMessage:o}=F(),t=useEditorRef();return jsx(Se,{type:"dialog",children:({close:r})=>jsxs(Fragment,{children:[jsx(Le,{children:jsx(D,{icon:LinkIcon,size:"sm",isDisabled:e,"aria-label":o(ro.addLink),className:Ho,preventFocusOnPress:!0})}),jsx(Pe,{className:sprinkles({boxShadow:"medium"}),placement:"top end",children:jsx(le,{size:"content",style:{minWidth:240},children:jsx(WC,{close:()=>{r(),setTimeout(()=>{focusEditor(t,t.selection);},0);}})})})]})})},WC=({close:e})=>{let o=useEditorRef(),{formatMessage:t}=F(),r=useEditorSelector(l=>iu(l),[]),[a,i]=to.useState(r?"show":"add"),[s,n]=to.useState(r||""),p=jsx(M,{padding:"lg",children:jsx(wo,{label:t(ro.link),value:s,autoFocus:!0,onChange:n,placeholder:"https://yourdomain.com"})});return jsxs(Fragment,{children:[a==="add"&&jsxs(Fragment,{children:[p,jsx(M,{display:"flex",justifyContent:"flex-end",padding:"lg",className:Pm,children:jsx(A,{isDisabled:!isUrl(s,!0),label:t(ro.addLink),size:"sm",onPress:()=>{upsertLink(o,{url:s,skipValidation:!0}),e?.();},preventFocusOnPress:!0})})]}),a==="show"&&jsxs(Fragment,{children:[jsx(M,{padding:"lg",children:jsx(X,{type:"subtitle",size:"sm",children:r})}),jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(A,{label:t(ro.editLink),size:"sm",variant:"secondary",onPress:()=>{i("edit");},style:{flex:1,justifyContent:"center"}}),jsx(A,{label:t(ro.removeLink),size:"sm",onPress:()=>{unwrapLink(o),e?.();},preventFocusOnPress:!0,style:{flex:1,justifyContent:"center"}})]})]}),a==="edit"&&jsxs(Fragment,{children:[p,jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(A,{label:t(ro.cancel),size:"sm",variant:"secondary",onPress:()=>{i("show"),e?.();}}),jsx(A,{label:t(ro.save),size:"sm",onPress:()=>{upsertLink(o,{url:s,skipValidation:!0}),e?.();}})]})]})]})};function nu({className:e,children:o,...t}){return jsx(PlateElement,{asChild:!0,className:e,...t,children:jsx("a",{className:mr({size:"sm"}),children:o})})}var ro=$({addLink:{id:"addLink",defaultMessage:"Add Link",description:"Add Link"},editLink:{id:"editLink",defaultMessage:"Edit Link",description:"Edit Link"},removeLink:{id:"removeLink",defaultMessage:"Remove Link",description:"Remove Link"},cancel:{id:"cancel",defaultMessage:"Cancel",description:"Cancel"},save:{id:"save",defaultMessage:"Save",description:"Save"},link:{id:"linkAnnotation",defaultMessage:"Link",description:"Link"}});var YC=parseColor("#ffffff00").toString("hexa"),Yi=[{label:"Red",color:"#ff0000"},{label:"Green",color:"#00ff00"},{label:"Blue",color:"#0000ff"},{label:"Yellow",color:"#ffff00"},{label:"Cyan",color:"#00ffff"},{label:"Magenta",color:"#ff00ff"},{label:"Black",color:"#000000"},{label:"White",color:"#ffffff"},{label:"Gray",color:"#808080"},{label:"Orange",color:"#ffa500"},{label:"Brown",color:"#a52a2a"},{label:"Purple",color:"#800080"}];[...Yi,{label:"Transparent",color:YC}];var Jr=({nodeType:e,icon:o,ariaLabel:t,isDisabled:r})=>{let a=useEditorSelector(s=>isMarkActive(s,e),[]),i=useEditorRef();return jsx(ve,{variant:"tertiary",isSelected:a,size:"sm",icon:o,"aria-label":t,isDisabled:r,onPress:()=>{toggleMark(i,{key:e});},preventFocusOnPress:!0})},Qi=({nodeType:e,"aria-label":o,isDisabled:t})=>{let{updateColor:r,clearColor:a,color:i}=useColorDropdownMenuState({customColors:[],colors:[],nodeType:e}),s=useCallback(({ref:p,triggerProps:l})=>jsx(D,{icon:e==="color"?TextIcon$1:HighlightTextIcon,"aria-label":o,size:"md",variant:"popover",isDisabled:t,className:Ho,preventFocusOnPress:!0,...l,ref:p}),[e,o,t]),n=useCallback(p=>{p?r(p.toString("rgba")):a();},[a,r]);return jsx(Eo,{presets:Yi,allowRemoval:!0,pickerMode:"lazy",placement:"top end",colorLabel:!1,renderTriggerButton:s,value:i||"#000000",onChange:n,isDisabled:t})};var wP=[{type:ELEMENT_PARAGRAPH,children:[{text:""}]}],Qr=to.createContext({items:[],containerRef:{current:null},maxMentionableUsersSuggestions:10}),es=to.forwardRef(({value:e,defaultValue:o,onChange:t,style:r,spellCheck:a,placeholder:i,isInline:s,isDisabled:n,editableContentAriaLabel:p,containerRef:l,onHelpDialogOpenRequest:c,mentionableUsers:m,editorHandle:u,maxMentionableUsersSuggestions:d,autoFocus:f,editorRef:y,saveOnEnter:b,onSave:_},z)=>{let g=useRef(null),h=useId(),{formatMessage:C}=F(),w=useRef(null),P=w.current,k=useRef(null),N=useMemo(()=>P?.getRootNode()instanceof ShadowRoot,[P]),[R,I]=useControlledState(e?Xi(e):void 0,Xi(o||"<p></p>"),x=>{t&&t(Tt(x));}),{keyboardProps:B}=useKeyboard({onKeyDown:x=>{(b&&x.key==="Enter"&&!x.shiftKey||(x.ctrlKey||x.metaKey)&&x.key==="Enter")&&(x.preventDefault(),_()),x.altKey&&x.key==="F10"?(x.preventDefault(),g.current&&g.current.querySelector("button")?.focus()):x.continuePropagation(),Go()&&N&&k.current&&focusEditor(k.current);}});useEffect(()=>{n&&k.current&&deselect(k.current);},[n]),useImperativeHandle(z,()=>({startMention:()=>{k.current&&!w.current?.querySelector("input[role='combobox']")&&Zr(k.current);}})),useImperativeHandle(u,()=>({setCaretPosition:x=>{k.current&&(focusEditor(k.current),moveSelection(k.current,{distance:x,unit:"character"}));}}));let L=useMemo(()=>({items:m||[],containerRef:l,maxMentionableUsersSuggestions:d}),[m,l,d]);return jsx(Qr.Provider,{value:L,children:jsxs(Plate,{initialValue:R||wP,plugins:su,editorRef:T(k,y||null),onChange:x=>{I(x);},children:[jsxs(qr,{className:Wr,"aria-controls":h,ref:g,children:[jsxs(M,{display:"flex",flexDirection:"row",role:"group",gap:"xs",paddingX:"sm",children:[jsx(Jr,{nodeType:MARK_BOLD,icon:BoldIcon,ariaLabel:C(jo.bold),isDisabled:n}),jsx(Jr,{nodeType:MARK_ITALIC,icon:ItalicIcon,ariaLabel:C(jo.italic),isDisabled:n}),jsx(Jr,{nodeType:MARK_UNDERLINE,icon:UnderlineIcon,ariaLabel:C(jo.underline),isDisabled:n})]}),jsx(O,{orientation:"vertical",className:Pt}),jsx(Qi,{nodeType:MARK_COLOR,"aria-label":C(jo.fontColor),isDisabled:n}),jsx(O,{orientation:"vertical",className:Pt}),jsx(Qi,{nodeType:MARK_BG_COLOR,"aria-label":C(jo.backgroundColor),isDisabled:n}),jsx(O,{orientation:"vertical",className:Pt}),jsx(du,{isDisabled:n}),jsx(O,{orientation:"vertical",className:Pt}),jsx(D,{className:Ho,icon:QuestionmarkCircleIcon,size:"sm","aria-label":C(jo.help),onPress:c})]}),jsx(O,{variant:"secondary"}),jsx("div",{...B,ref:w,children:jsx(PlateContent,{id:h,disabled:n,readOnly:n,style:r,placeholder:i,autoFocus:f,spellCheck:a,"aria-label":p,className:classNames(Kr({isDisabled:n}),Gr({isInline:s})),renderPlaceholder:({attributes:x,children:S})=>jsx("span",{...x,className:sprinkles({paddingY:"lg"}),children:S})})})]})})});es.displayName="RichEditor";var Jm=({key:e,value:o},{isDisabled:t,optionProps:r,isFocused:a,_state:i},s)=>{let{hoverProps:n}=useHover({isDisabled:t}),{label:p,data:l}=o;return jsxs(Fragment,{children:[jsxs("li",{...mergeProps(r,n),className:Tm({isDisabled:t,isHovered:a}),"data-active":a,ref:s,children:[jsx(Lo,{name:p,...l?.avatar}),jsxs(M,{display:"flex",flexDirection:"column",children:[jsx(X,{type:"subtitle",size:"sm",children:p}),jsx(X,{type:"helper",size:"sm",children:l?.description})]})]}),e===i.collection.getLastKey()?null:jsx(O,{})]})},jo=$({bold:{defaultMessage:"Bold",id:"bold"},italic:{defaultMessage:"Italic",id:"italic"},underline:{defaultMessage:"Underline",id:"underline"},backgroundColor:{defaultMessage:"Background color",id:"backgroundColor"},fontColor:{defaultMessage:"Font color",id:"fontColor"},help:{defaultMessage:"Help",id:"help"}});var vu=to.memo(to.forwardRef(({className:e,style:o,"data-block-id":t,"data-block-class":r,enableRichText:a=!1,onCancel:i,onSave:s,isInline:n=!0,submitButtonIcon:p=ArrowUpCircleFilledIcon,submitButtonAriaLabel:l,cancelButtonAriaLabel:c,"aria-label":m,"aria-describedby":u,"aria-labelledby":d,"aria-details":f,editableContentAriaLabel:y="Editing Area",footerButtons:b,clearOnCancel:_,clearOnSave:z,...g},h)=>{let C=useRef(null),{formatMessage:w}=F(),P=useRef(null),k=useRef(null),N=useRef(null),R=!a&&g.variant==="minimal",I=useRef(null),[B,L]=to.useState(g.value||g.defaultValue),x=g.isDisabled||g.isSaveDisabled||!getPlainText(B||""),{fieldProps:S}=useLabel({"aria-label":m,"aria-labelledby":d,"aria-describedby":u,"aria-details":f,labelElementType:"div"});R&&!g.avatarName&&console.warn("Editor: When using the minimal `variant` and `enableRichText` is `false`, you should provide an `avatarName`.");let H=useCallback(()=>{L(""),a?C.current?.reset():k.current?.clear();},[a]),j=useCallback(()=>{x||(s?.(a?Tt(C.current?.children):P.current.value),z&&H());},[H,z,a,s,x]),ae=jsx(D,{variant:"ghost","aria-label":l||w(ts.save),icon:p,isDisabled:x,size:"md",excludeFromTabOrder:R,className:R?Lm:void 0,onPress:j,preventFocusOnPress:!0}),[ie,G]=to.useState(!1),{keyboardProps:U}=useKeyboard({onKeyDown:V=>{(V.metaKey||V.ctrlKey)&&V.shiftKey&&V.key==="h"&&(V.preventDefault(),G(!0));}}),pe=useCallback(V=>{L(V),g.onChange?.(V);},[g]);return jsxs("div",{...mergeProps(S,a?U:{}),role:"application",ref:T(N,h),style:o,"data-block-id":t,"data-block-class":r,className:classNames(wm({isInline:n,isMinimal:R}),"BaselineUI-Editor",e),"aria-disabled":g.isDisabled,children:[R?jsxs(Fragment,{children:[n?jsx(Lo,{className:km,name:g.avatarName||""}):null,jsxs("div",{className:Bm({isInline:n}),children:[jsx(Xr,{isMinimal:R,textBoxRef:P,isInline:n,editableContentAriaLabel:y,...g,onChange:pe,onSave:j}),ae]})]}):jsxs(Fragment,{children:[a?jsx(es,{containerRef:N,ref:I,editorRef:C,isInline:n,editableContentAriaLabel:y,onHelpDialogOpenRequest:()=>{G(!0);},...g,onChange:pe,onSave:j}):jsxs(Fragment,{children:[!n&&jsx(O,{variant:"secondary"}),jsx(Xr,{onCancel:i,textBoxRef:P,ref:k,isInline:n,editableContentAriaLabel:y,...g,onChange:V=>{L(V),g.onChange?.(V);},onSave:j})]}),jsx(O,{variant:"secondary"}),jsxs("div",{className:classNames(Wr,sprinkles({justifyContent:"space-between"})),children:[jsxs(M,{paddingX:"sm",gap:"sm",display:"flex",children:[a&&g.mentionableUsers?jsx(D,{icon:AtIcon,size:"sm","aria-label":w(ts.mention),onPress:()=>I.current?.startMention(),preventFocusOnPress:!0}):null,b?.map(({type:V,props:Z},de)=>V==="action"?jsx(D,{...Z,size:"sm",isDisabled:g.isDisabled||Z.isDisabled},de):jsx(ve,{...Z,size:"sm",variant:"tertiary",isDisabled:g.isDisabled||Z.isDisabled},de))]}),jsxs(M,{children:[!!i&&jsx(D,{variant:"secondary",icon:CrossCircleFilledIcon,isDisabled:g.isDisabled,size:"md",onPress:()=>{i(),_&&H();},"aria-label":c||w(ts.cancel)}),ae]})]})]}),jsx(Om,{isOpen:ie,onClose:()=>{G(!1);}})]})}));vu.displayName="Editor";var ts=$({cancel:{defaultMessage:"Cancel",id:"cancel"},save:{defaultMessage:"Save",id:"save"},mention:{defaultMessage:"Mention",id:"mention"}});var oa=to.forwardRef(({className:e,style:o,"data-block-id":t,"data-block-class":r,isMounted:a,children:i,transitions:s,elementType:n="div",...p},l)=>{let c=useTransition(a,s),m=animated[n];return c((u,d)=>d&&jsx(m,{className:e,"data-block-id":t,"data-block-class":r,style:{...o,...u},...p,ref:l,children:i}))});oa.displayName="Transition";var _u="_8kqf970 _1yep5z6ow _1yep5z6ox _1yep5z6oy _1yep5z613b _1yep5z613c _1yep5z613d _1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6142 _1yep5z6143 _1yep5z6144 _1yep5z6yh _1yep5z6uq _1yep5z6ur _1yep5z6us _1yep5z6168";var hu=2,xu=to.forwardRef(({className:e,style:o,hideForKeyboard:t,scrollRef:r,label:a,delay:i=1500,smoothScroll:s=!0,"data-block-id":n,"data-block-class":p},l)=>{let c=to.useRef(null),m=useInteractionModality(),[u,d]=to.useState(!1),f=useCallback(()=>{let R=r?.current||be(c.current).body;return Q(R).getComputedStyle(R).flexDirection==="column-reverse"?R.scrollTop+hu>=0:R.scrollTop+R.clientHeight+hu>=R.scrollHeight},[r]),[y,b]=to.useState(f),_=Ae(),{buttonProps:z,isPressed:g}=useButton({onPress:()=>{let R=r?.current||be(c.current).body;R.scrollTo({top:R.scrollHeight,behavior:s?"smooth":"auto"});}},c),{focusProps:h,isFocused:C,isFocusVisible:w}=useFocusRing(),{hoverProps:P,isHovered:k}=useHover({}),N=filterTruthyValues({"data-block-id":n,"data-block-class":p,"data-pressed":g,"data-focus-visible":w,"data-hovered":k,"data-focused":C});return useEffect(()=>{b(f());},[f]),useEffect(()=>{let R=r?.current||be(c.current).body,I="onscrollend"in Q(R),B=()=>{setTimeout(()=>{d(!1),b(f());},i);},L=()=>{d(!0),I||B();};return R.addEventListener("scroll",L),R.addEventListener("scrollend",B),()=>{R.removeEventListener("scroll",L),R.removeEventListener("scrollend",B);}},[r,i,f]),jsxs(oa,{isMounted:(t?m!=="keyboard":!0)&&!u&&!y,elementType:"button",transitions:{from:{opacity:0,transform:"translateX(-50%) translateY(10px)"},enter:{opacity:1,transform:"translateX(-50%) translateY(0)"},leave:{opacity:0,transform:"translateX(-50%) translateY(10px)"},immediate:_},...mergeProps(z,h,P,N),className:classNames(_u,gr({isFocusVisible:w,variant:"high-contrast",isHovered:k}),"BaselineUI-ScrollControlButton",e),style:o,ref:T(l,c),children:[jsx(ArrowDownCircleFilledIcon,{size:16}),a]})});xu.displayName="ScrollControlButton";var as="_1yep5z6jc _1yep5z6jd _1yep5z6je _1yep5z6jl _1yep5z6jm _1yep5z6jn",Cu=v({defaultClassName:"_1v0p2z10 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",variantClassNames:{hasTitleAndIcon:{true:"_1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nw _1yep5z6nx _1yep5z6ny"},hasNoCloseBtn:{true:"_1yep5z6lk _1yep5z6ll _1yep5z6lm _1yep5z6nw _1yep5z6nx _1yep5z6ny _1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6mq _1yep5z6mr _1yep5z6ms"}},defaultVariants:{},compoundVariants:[[{hasTitleAndIcon:!0,hasNoCloseBtn:!0},"_1yep5z61g7 _1yep5z61g8 _1yep5z61g9"]]}),Pu="_1v0p2z10";var ra=to.forwardRef(({className:e,style:o,"data-block-id":t,"data-block-class":r,message:a,title:i,primaryActionLabel:s,cancelLabel:n,textInputProps:p,icon:l,iconColor:c,showCloseButton:m=!0,onPrimaryAction:u,onCancel:d,autoFocusButton:f,isPrimaryActionDisabled:y},b)=>{let _=useId(),{formatMessage:z}=F(),g=i&&jsx(X,{id:_,type:"title",size:"sm",elementType:"h3",children:i});return jsxs(le,{className:e,style:o,"data-block-id":t,"data-block-class":r,size:"sm",variant:"primary",role:"alertdialog",ref:b,"aria-labelledby":_,children:[jsxs("div",{className:Cu({hasTitleAndIcon:!!(l&&i),hasNoCloseBtn:!m}),children:[jsxs(M,{display:"flex",justifyContent:"space-between",alignItems:"center",flexDirection:"row",children:[l?jsx(l,{style:{color:c},size:24}):null,!l&&g,m?jsx(D,{icon:XIcon,variant:"secondary",size:"md","aria-label":z(ek.close),onPress:d}):null]}),l?g:null]}),a?jsx(M,{elementType:"section",className:Pu,paddingX:"lg",paddingBottom:"lg",typography:"body.sm.regular",color:"text.primary",children:a}):null,p?jsx(M,{paddingX:"lg",paddingBottom:"lg",children:jsx(wo,{...p})}):null,n||s?jsxs(Fragment,{children:[jsx(O,{}),jsxs(M,{padding:"lg",display:"flex",gap:"xl",children:[n?jsx(A,{variant:"secondary",className:as,label:n,onPress:d,autoFocus:f==="cancel"}):null,s?jsx(A,{className:as,label:s,onPress:u,autoFocus:f==="primary",isDisabled:y}):null]})]}):null]})});ra.displayName="AlertDialog";var ek=$({close:{id:"close",defaultMessage:"Close",description:"Close button label"}});var ku="_1t55bp71",wu="_1yep5z6e3 _1yep5z6eu _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69i _1yep5z69j _1yep5z69k",Ru="_1t55bp70";var sk=ik(),Iu=to.forwardRef(({className:e,style:o,children:t,"data-block-id":r,"data-block-class":a,showCaret:i},s)=>{let n=useMemo(()=>{let p=t;return (!t||Array.isArray(t)&&t.length===0)&&(p=""),sk.render(p)},[t]);return jsx("div",{className:classNames(wu,Ru,{[ku]:i},"BaselineUI-Markdown",e),"data-block-id":r,"data-block-class":a,style:o,ref:s,dangerouslySetInnerHTML:{__html:n}})});Iu.displayName="Markdown";function Lu(e){let{formatMessage:o,locale:t}=F(),[r,a]=to.useState(!1),[i,s]=to.useState(0),[n,p]=to.useState(0),[l,c]=to.useState(!1);useEffect(()=>{if(!e.current)return;let d=e.current,f=()=>{a(!1),s(0);},y=()=>{l||s(d.currentTime*100/d.duration);},b=()=>{p(d.duration);};return d.addEventListener("ended",f),d.addEventListener("timeupdate",y),d.addEventListener("loadedmetadata",b),()=>{d.removeEventListener("ended",f),d.removeEventListener("timeupdate",y),d.removeEventListener("loadedmetadata",b);}},[l,e]);let m=useCallback(()=>{(async()=>e.current&&(e.current.paused?(await e.current.play(),a(!0),announce(o(Tu.playing),"polite")):(e.current.pause(),a(!1),announce(o(Tu.paused),"polite"))))();},[o,e]),u=useCallback(d=>{e.current&&(e.current.currentTime=d*e.current.duration/100,announce(pk(e.current.currentTime,t.locale),"assertive"));},[t.locale,e]);return {isPlaying:r,progress:i,duration:n,togglePlay:m,seek:u,setProgress:s,formattedCurrentTime:e.current?.currentTime?Su(e.current?.currentTime):"00:00",formattedDuration:n?Su(n):"00:00",setIsSliderDragging:c}}var Tu=$({playing:{id:"playing",defaultMessage:"Playing"},paused:{id:"paused",defaultMessage:"Paused"}});function pk(e,o){let t=Math.floor(e/3600),r=Math.floor(e%3600/60),a=e%60,i={...t&&{hours:t},...r&&{minutes:r},seconds:Math.floor(a)};return new Intl.DurationFormat(o,{style:"long"}).format(i)}function Su(e){let o=Math.floor(e%3600/60),t=Math.floor(e%60);return [o,t].map(r=>r.toString().padStart(2,"0")).join(":")}var Mu="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q",Bu="rta2n91 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6z9 _1yep5z6ut _1yep5z6uu _1yep5z6uv _1yep5z6166 _1yep5z6106",Du="rta2n90";var Hu=to.forwardRef(({className:e,style:o,size:t="lg",sources:r,"data-block-id":a,"data-block-class":i,...s},n)=>{let p=to.useRef(null),{isPlaying:l,progress:c,duration:m,togglePlay:u,seek:d,formattedDuration:f,formattedCurrentTime:y,setProgress:b,setIsSliderDragging:_}=Lu(p),{formatMessage:z}=F(),g=filterTruthyValues({"data-block-id":a,"data-block-class":i,"data-state":l?"playing":"paused","data-loaded":m>0});return jsxs("div",{...g,...s,className:classNames(Mu,"BaselineUI-AudioPlayer",e),role:"group",style:o,ref:n,children:[jsx(VisuallyHidden,{children:jsx("audio",{ref:p,children:r.map(({url:h,type:C})=>jsx("source",{src:h,type:C},h))})}),jsx(ve,{icon:l?PauseIcon:PlayIcon,variant:"toolbar",isSelected:l,size:t,"aria-label":z(l?ss.pause:ss.play),style:{borderRadius:"50%"},onPress:u}),jsxs("div",{className:Bu,children:[jsx("span",{"aria-hidden":!0,children:y}),jsx(yo,{"aria-label":z(ss.audioTimeline),value:c,minValue:0,maxValue:100,className:Du,onChange:h=>{b(h),_(!0);},onChangeEnd:h=>{d(h),_(!1);}}),jsx("span",{"aria-hidden":!0,children:f})]})]})});Hu.displayName="AudioPlayer";var ss=$({play:{id:"play",defaultMessage:"Play"},pause:{id:"pause",defaultMessage:"Pause"},audioTimeline:{id:"audioTimeline",defaultMessage:"Audio timeline"}});var Ou="_1w920rnf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6ho _1yep5z6hp _1yep5z6hq",Vu="_1w920rn1 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k",Au="_1w920rn0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6km",Bt=v({defaultClassName:"_1w920rn2 _1yep5z6d6 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{isFocusVisible:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isLoading:{true:"_1yep5z614w _1yep5z614x _1yep5z614y"},imageWidth:{sm:"_1w920rn6",md:"_1w920rn7"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rn8 _1yep5z6l1 _1yep5z6kz _1yep5z6hc"]]}),ju="_1w920rnd _1yep5z6kw",$u=v({defaultClassName:"_1w920rn9 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6fw _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocusVisible:{true:"_1w920rna _1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1w920rnb"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rnc _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]}),Uu="_1w920rne";var Ku=({items:e,ulRef:o})=>{let{length:t}=e,r=to.useRef(null);return useLayoutEffect(()=>{if(!r.current)return;let a=r.current.closest(".BaselineUI-ImageGallery")?.querySelector(`[data-image-key='${e?.at(-1)?.key}']`)?.cloneNode(!0);invariant(a,"Node is not defined."),r.current?.prepend(a);},[e,o]),jsx("div",{className:Bt(),ref:r,children:jsx(M,{backgroundColor:"background.secondary.medium",borderRadius:"full",typography:"label.md.medium",color:"text.primary",position:"absolute",paddingX:"md",className:Uu,children:t})})};var Wu=({item:{value:e},options:{optionProps:o,isFocusVisible:t,isSelected:r},liRef:a,fit:i="contain",imageWidth:s=102,onDelete:n,aspectRatio:p,className:l,imageClassName:c,imageLabelClassName:m})=>{let u=useId(),{formatMessage:d}=F();invariant(e&&(e?.type==="option"||e?.type===void 0));let{imgProps:f,isLoading:y,isLoaded:b}=bo({src:e.data?.src,alt:e.data?.alt??""}),_=useTransition(b,{from:{opacity:0},enter:{opacity:1},leave:{opacity:0}}),z=isNumber(s)?void 0:Bt({imageWidth:s}),g=isNumber(s)?{width:s}:void 0;return jsxs("li",{...o,ref:a,className:classNames(Vu,l),"aria-labelledby":u,children:[jsx("div",{className:classNames(Bt({isFocusVisible:t,isSelected:r,isLoading:!0}),z,c),style:{aspectRatio:p?.toString(),...g},"data-image-key":e.id,children:y?jsx(No,{"aria-label":d(Dt.loading)}):_((h,C)=>C&&jsx(animated.div,{role:"img","aria-label":f.alt,style:{...h,backgroundImage:`url(${f.src})`,backgroundSize:i},className:ju,children:n?jsx("div",{className:Ou,children:jsx(D,{"aria-label":d(Dt.delete),size:"xs",icon:XIcon$2,onPress:()=>{n(e.id);},UNSAFE_NON_INTERACTIVE:!0})}):null}))}),jsx("span",{id:u,className:classNames($u({isFocusVisible:t,isSelected:r}),m),children:e.label})]})};function Xu(e,o){return e.find(t=>t.id===o)}function Yu(e,o,t){let r=e.findIndex(s=>s.id===o),a=[...t].map(s=>e.findIndex(n=>n.id===s)),i=[...e];for(let s of a){let[n]=i.splice(s,1);i.splice(r,0,n);}return i}function Zu(e,o,t){let r=e.findIndex(n=>n.id===o),a=[...t].map(n=>e.findIndex(p=>p.id===n)),i=[...e],s=0;for(let n of a){let[p]=i.splice(n-s,1);i.splice(r+1,0,p),s++;}return i}function ls(e){return e.map(o=>({id:o.id,label:o.label,data:{src:o.src,alt:o.alt}}))}function Qu(e){return e.map(o=>({id:o.id,label:o.label,src:o.data?.src,alt:o.data?.alt}))}var Rk={width:0,display:"block"};var of=to.forwardRef(({className:e,style:o,fit:t="cover",onReorder:r,"data-block-id":a,"data-block-class":i,onDelete:s,imageWidth:n="sm",aspectRatio:p=3/4,items:l,defaultItems:c=[],onKeyDown:m,imageContainerClassName:u,imageClassName:d,labelClassName:f,onListChange:y,...b},_)=>{let z=to.useRef(null),[g,h]=useState([]),{formatMessage:C}=F(),[w,P]=useControlledState(b.selectedKeys,b.defaultSelectedKeys??[],b.onSelectionChange),[k,N]=useControlledState(l?ls(l):void 0,ls(c),y?x=>{y?.(Qu(x));}:void 0),R=useCallback(x=>{let S=x.target.key,H=x.keys;if(x.target.dropPosition==="before"){let j=Yu(k,S,H);N(j);}else if(x.target.dropPosition==="after"){let j=Zu(k,S,H);N(j);}r?.(x);},[k,r,N]),I=useCallback(()=>{s&&g.length&&(N(k.filter(x=>!g.includes(x.id))),s(new Set(g)),h([]));},[g,k,s,N]),B=useCallback((x,S,H)=>jsx(Wu,{item:x,options:S,liRef:H,fit:t,imageWidth:n,aspectRatio:p,onDelete:s?j=>{h([j]);}:void 0,className:u,imageClassName:d,imageLabelClassName:f}),[p,t,s,n,u,d,f]),{keyboardProps:L}=useKeyboard({onKeyDown(x){if(m?.(x),x.key==="Backspace"||x.key==="Delete"){if(!s)return;if([...w].length)h([...w]);else {let H=x.target.dataset.key;h([H]);}}}});return jsxs("div",{...L,ref:_,style:o,className:classNames("BaselineUI-ImageGallery",e),"data-block-id":a,"data-block-class":i,children:[jsx(re,{...b,selectedKeys:w,items:k,onReorder:R,layout:"grid",orientation:"vertical",className:Au,ref:z,dropIndicatorStyle:Rk,renderOption:B,renderDragPreview:x=>jsx(Ku,{items:x,ulRef:z}),onSelectionChange:P,getItems:x=>[...x].map(S=>{let H=Xu(k,S);return {src:H?.src||"",alt:H?.alt||"",key:S}})}),jsx(Ce,{isOpen:!![...g].length,onOpenChange:x=>{x||h([]);},children:jsx(Be,{isDismissable:!0,children:jsx(ra,{showCloseButton:!1,title:"Are you sure you want to delete this item?",primaryActionLabel:C(Dt.delete),cancelLabel:C(Dt.cancel),onCancel:()=>{h([]);},onPrimaryAction:I,autoFocusButton:"cancel"})})})]})});of.displayName="ImageGallery";var Dt=$({delete:{id:"delete",defaultMessage:"Delete"},cancel:{id:"cancel",defaultMessage:"Cancel"},loading:{id:"loading",defaultMessage:"Loading"}});var tf="_1sexph00",rf="_1sexph01 _1yep5z616p _1yep5z616q _1yep5z616r _1yep5z6191 _1yep5z6192 _1yep5z6193 _1yep5z61a7 _1yep5z61a8 _1yep5z61a9 _1yep5z617v _1yep5z617w _1yep5z617x _1yep5z61q4 _1yep5z61q5 _1yep5z61q6";var sf=to.forwardRef(({className:e,style:o,items:t,"data-block-id":r,"data-block-class":a,hideLabel:i,size:s="md",isDisabled:n,showSelectedIcon:p=!0,excludeFromTabOrder:l,...c},m)=>{let u=te(),d=useSelectState({items:t,...c,children:u,validationState:c.validationState==="error"?"invalid":"valid",onSelectionChange:w=>{w&&y(w),c.onSelectionChange?.(w);}}),[f,y]=useState(d.selectedKey||d.collection.getFirstKey()),b=useMemo(()=>d.collection.getItem(f),[f,d.collection]),{hoverProps:_,isHovered:z}=useHover({isDisabled:n}),g=useMemo(()=>{let w=b.textValue||b["aria-label"],P=b.value.icon,k=f===d.selectedKey,R={size:s,isSelected:k,onPress:()=>{d.setSelectedKey(k?null:f);},isDisabled:n,excludeFromTabOrder:l};return i&&P?jsx(ve,{icon:P,"aria-label":w,variant:"toolbar",...R}):jsx(yr,{iconStart:P,label:w,...R})},[f,b,l,i,n,s,d]),h=useCallback(({buttonProps:w,isOpen:P,ref:k})=>{let N=f===d.selectedKey;return jsx(ve,{...w,ref:k,icon:ChevronDownIcon,"aria-expanded":P,variant:"toolbar",size:s,isSelected:N,className:rf,isDisabled:n,excludeFromTabOrder:l})},[f,l,n,s,d.selectedKey]),C=filterTruthyValues({"data-block-id":r,"data-block-class":a,"data-hovered":z,"data-selected":f===d.selectedKey});return jsx(Ja.Provider,{value:d,children:jsxs(M,{..._,role:"group",display:"inline-flex",flexDirection:"row",alignItems:"center",className:classNames(tf,"BaselineUI-ButtonSelect",e),"aria-label":c["aria-label"],"aria-labelledby":c["aria-labelledby"],"aria-describedby":c["aria-describedby"],"aria-details":c["aria-details"],style:o,ref:m,...C,children:[g,jsx(qe,{isDisabled:n,showSelectedIcon:p,placement:"bottom end",items:t,...c,variant:"ghost",renderTrigger:h})]})})});sf.displayName="ButtonSelect";var nf=v({defaultClassName:"_18v88n10 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6kv",variantClassNames:{labelPosition:{top:"_1yep5z613n _1yep5z613o _1yep5z613p",start:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6152 _1yep5z6153 _1yep5z6154 _1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),lf=v({defaultClassName:"_18v88n1p _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6eu _1yep5z6kv _1yep5z6l6 _1yep5z6ky _1yep5z6dy",variantClassNames:{isDisabled:{true:"_18v88n1q _1yep5z6109"},labelPosition:{top:"_18v88n1r",start:"_18v88n1s"}},defaultVariants:{},compoundVariants:[]}),pf=v({defaultClassName:"_18v88n1t _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ks",variantClassNames:{validationState:{valid:"_18v88n1u",error:"_1yep5z6zp",warning:"_1yep5z6zx"},isReadOnly:{true:"_1yep5z610b"}},defaultVariants:{},compoundVariants:[]}),cf=v({defaultClassName:"_18v88n1d _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{validationState:{valid:"_18v88n1e",error:"_1yep5z611k",warning:"_18v88n1g"},isHovered:{true:"_18v88n1h"},isFocused:{true:"_1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z616k _1yep5z616i _1yep5z611y _1yep5z616b _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"_18v88n1j"},variant:{primary:"_18v88n1k",ghost:"_18v88n1l"},isReadOnly:{true:"_1yep5z612n"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"_1yep5z61rv _1yep5z61rt _1yep5z61nc"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"_18v88n1n"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"_1yep5z61nd"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"_1yep5z61nd"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"_18v88n1o"]]}),df=v({defaultClassName:"_18v88n13 _1yep5z6dy _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),mf=v({defaultClassName:"_18v88n19 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5",variantClassNames:{labelPosition:{top:"_1yep5z6sh _1yep5z6si _1yep5z6sj",start:"_1yep5z6me _1yep5z6mf _1yep5z6mg _1yep5z613n _1yep5z613o _1yep5z613p"},hasMessage:{true:"_18v88n1c"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"_1yep5z61q7 _1yep5z61q8 _1yep5z61q9"]]}),uf="_1yep5z6kv",ff="_1yep5z6d7 _1yep5z6fs",yf=v({defaultClassName:"_18v88n15 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isHovered:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isOpen:{true:"_1yep5z612v _1yep5z6169"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isHovered:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isOpen:!0},"_1yep5z61o6 _1yep5z61rk"]]});var vf=to.forwardRef(({className:e,style:o,inputStyle:t,inputClassName:r,"data-block-id":a,"data-block-class":i,label:s,items:n,showSelectedIcon:p=!1,onSelectionChange:l,onInputChange:c,isInvalid:m=!1,labelPosition:u="top",validationState:d="valid",variant:f="primary",toggleLabel:y,renderOption:b,showIcon:_=!0,filter:z,...g},h)=>{let{contains:C}=useFilter({sensitivity:"base"}),w=te(),P=useComboBoxState({...g,defaultFilter:z||C,defaultItems:n,onSelectionChange:l,onInputChange:c,children:w,validationState:m?"invalid":"valid"}),k=to.useRef(null),N=to.useRef(null),R=to.useRef(null),I=to.useRef(null),B=to.useRef(null),{buttonProps:L,inputProps:x,listBoxProps:S,labelProps:H,errorMessageProps:j,descriptionProps:ae,validationErrors:ie}=useComboBox({...g,inputRef:N,defaultItems:n,buttonRef:k,listBoxRef:R,popoverRef:I,validationState:d==="error"?"invalid":"valid"},P),G=g.errorMessage||ie.join(" "),U=xe({...g,errorMessage:G,descriptionProps:ae,errorMessageProps:j,labelPosition:u});G&&(d="error");let{hoverProps:pe,isHovered:V}=useHover({isDisabled:g.isDisabled}),{isFocused:Z,focusProps:de,isFocusVisible:Ie}=useFocusRing(),_e=ko({isReadOnly:g.isReadOnly,validationState:d}),ze=filterTruthyValues({"data-read-only":g.isReadOnly,"data-disabled":g.isDisabled,"data-validation-state":d,"data-focused":Z,"data-focus-visible":Ie}),{labelProps:he,fieldProps:Ye}=useLabel({label:s});return jsx(Ze.Provider,{value:P,children:jsxs("div",{className:classNames(nf({labelPosition:u}),e,"BaselineUI-ComboBox"),"data-block-id":a,"data-block-class":i,style:o,ref:h,children:[s||u==="start"&&U?jsxs("div",{className:mf({labelPosition:u,hasMessage:!!U}),children:[jsx("label",{...mergeProps(H,he),className:df({isDisabled:g.isDisabled}),children:s}),u==="start"&&U]}):null,jsxs("div",{...pe,className:cf({validationState:d,isHovered:V,isFocused:Z,variant:f,isReadOnly:!!g.isReadOnly,isDisabled:!!g.isDisabled}),ref:B,children:[jsx("input",{...mergeProps(x,de,ze,Ye),ref:N,className:classNames(lf({isDisabled:g.isDisabled,labelPosition:u}),"BaselineUI-ComboBox-Input",r),style:t}),_e&&_?jsx(_e,{className:pf({validationState:d,isReadOnly:g.isReadOnly}),size:16}):null,jsx(A,{...L,ref:k,variant:"popover",label:y,className:yf({isFocusVisible:!g.isDisabled&&!g.isReadOnly&&Ie,isHovered:!g.isDisabled&&!g.isReadOnly&&V,isOpen:P.isOpen})})]}),P.isOpen?jsx(ce,{className:ff,ref:I,triggerRef:B,state:P,children:jsx(re,{...S,items:n,ref:R,renderOption:b,selectionMode:"single",showSelectedIcon:p,className:uf})}):null,u==="top"&&U]})})});vf.displayName="ComboBox";var _f="byycd00";var ds=to.forwardRef(({item:e,renderGridItem:o,state:t},r)=>{let a=ge(r),i=useGridListItem({node:e},t,a),s=t.selectionManager.selectionMode!=="none"&&t.selectionManager.selectionBehavior==="toggle",{checkboxProps:n}=useGridListSelectionCheckbox({key:e.key},t);return o(e,{...i,checkBoxProps:s?n:void 0},a)});ds.displayName="GridListItem";var hf=to.forwardRef(({className:e,style:o,"data-block-id":t,...r},a)=>{let i=te(),s=useListState({...r,children:i}),n=ge(a),{gridProps:p}=useGridList(r,s,n);return jsx("ul",{...p,className:classNames(_f,e),"data-block-id":t,style:o,ref:n,children:[...s.collection].map(l=>jsx(ds,{item:l,state:s,renderGridItem:r.renderGridItem},l.key))})});hf.displayName="GridList";var xf="_1dc3b8m0";var Pf=to.forwardRef(({className:e,selectionMode:o="single",style:t,"data-block-id":r,tooltipProps:a,...i},s)=>{let n=ge(s),p=te(),l=useListState({...i,selectionMode:o,suppressTextValueWarning:!0,children:p}),{actionGroupProps:c}=useActionGroup({...i,selectionMode:o,children:p},l,n);return jsx(M,{...c,display:"flex",flexDirection:"row",gap:"xs",className:classNames("BaselineUI-ActionGroup",e),"data-block-id":r,style:t,ref:n,children:[...l.collection].map(m=>{invariant(m.value);let u=typeof a=="function"?a(m.value):a;return jsx(a0,{item:m,state:l,isDisabled:i.isDisabled,onAction:i.onAction,tooltipProps:u},m.key)})})});Pf.displayName="ActionGroup";var a0=({item:e,state:o,tooltipProps:t,onAction:r,isDisabled:a})=>{let{buttonProps:i}=useActionGroupItem({key:e.key},o),s=a||o.selectionManager.isDisabled(e.key),n=o.selectionManager.isSelected(e.key);invariant(e.value);let{icon:p}=e.value;return invariant(p),jsx(PressResponder,{...mergeProps(i,{onPress:()=>{r?.(e.key);}}),children:jsx(ke,{text:e.textValue,size:"sm",variant:"inverse",includeArrow:!1,offset:4,...t,children:jsx(D,{variant:"tertiary",icon:p,"aria-label":e.textValue,size:"sm",isDisabled:s,className:classNames({[xf]:n},"BaselineUI-ActionGroup-Item")})})})};var wf=to.forwardRef(({className:e,style:o,items:t,optionsContainerClassName:r,"data-block-id":a,label:i,icon:s,value:n,defaultValue:p,onChange:l,isDisabled:c,optionClassName:m,optionStyle:u,labelPosition:d="top",...f},y)=>{let b=useMemo(()=>t.map(z=>({id:z.color,label:z.label})),[t]),_=useId();return useEffect(()=>{!i&&!f["aria-label"]&&!f["aria-labelledby"]&&console.warn("ColorSwatchPicker: Please provide a label or aria-label for accessibility.");},[i,f]),jsxs(M,{...ca(f),className:classNames("BaselineUI-ColorSwatchPicker",e),"data-block-id":a,display:"flex",flexDirection:d==="top"?"column":"row",alignItems:d==="top"?"flex-start":"center",justifyContent:"space-between",gap:"md",style:o,ref:y,children:[s||i?jsxs(M,{display:"flex",alignItems:"center",gap:"md",children:[s?jsx(s,{size:24,className:sprinkles({color:"icon.primary"})}):null,i?jsx(X,{id:_,type:"label",size:"sm",children:i}):null]}):null,jsx(re,{className:classNames(Ur,r),selectionMode:"single",items:b,orientation:"horizontal",defaultSelectedKeys:p?[p]:void 0,disabledKeys:c?b.map(z=>z.id):void 0,isDisabled:c,selectedKeys:n?[n]:void 0,onSelectionChange:z=>{l?.([...z][0]);},optionClassName:m,optionStyle:u,renderOption:({key:z,textValue:g},{isSelected:h,isFocusVisible:C,isDisabled:w,optionProps:P},k)=>jsx("li",{...P,"data-disabled":w,className:classNames($r,P.className),ref:k,children:jsx(we,{isFocusVisible:C,color:z,isSelected:h,"aria-label":g,isInteractive:!0,isDisabled:w})}),...f,"aria-labelledby":i?_:f["aria-labelledby"]})]})});wf.displayName="ColorSwatchPicker";
55
54
 
56
- export { kp as Accordion, Mp as AccordionItem, O as ActionButton, yf as ActionGroup, ek as ActionGroupItem, L as ActionIconButton, ia as AlertDialog, Mu as AudioPlayer, So as Avatar, M as Box, Xu as ButtonSelect, Ql as Checkbox, Bo as ColorInput, om as ColorPresetInlineInput, he as ColorSwatch, gf as ColorSwatchPicker, lf as ComboBox, lp as DateFormat, me as Dialog, wc as DialogTitle, es as DomNodeRenderer, hr as Drawer, uu as Editor, gl as FileUpload, kd as FreehandCanvas, df as GridList, Jd as Group, Es as I18nProvider, gd as IconColorInput, Br as IconColorInputButton, Op as IconSelect, Od as ImageDropZone, qu as ImageGallery, pc as InlineAlert, ll as Link, te as ListBox, Cu as Markdown, lr as Menu, Qd as MessageFormat, ze as Modal, P5 as ModalClose, Te as ModalContent, Pr as ModalTrigger, wo as NumberFormat, Ie as NumberInput, sp as Pagination, Xe as Popover, Ue as PopoverContent, Ye as PopoverTrigger, ho as Portal, Vs as PortalContainerProvider, Ud as Preview, wl as ProgressBar, Io as ProgressSpinner, Ur as RadioGroup, Dl as Reaction, gu as ScrollControlButton, Is as SearchInput, Ae as Select, F as Separator, Qt as Slider, Cs as Switch, ec as TabItem, Jp as Tabs, yp as TagGroup, W as Text, ko as TextInput, zo as ThemeProvider, mr as ToggleButton, ve as ToggleIconButton, Gr as Toolbar, He as Tooltip, Bd as Transform, ra as Transition, j as defineMessages, rY as isInsideOverlayContent, Wn as isRect, go as useDevice, js as useDynamicListData, B as useI18n, bo as useImage, Ns as useIntersectionObserver, Fe as useIsFirstRender, Hs as useLocalStorage, wN as useMutationObserver, de as usePortalContainer, Ss as useResizeObserver, MN as useTextSelection, Ms as useUndoRedo, La as useUserPreferences };
55
+ export { Gp as Accordion, oc as AccordionItem, A as ActionButton, Pf as ActionGroup, a0 as ActionGroupItem, D as ActionIconButton, ra as AlertDialog, Hu as AudioPlayer, Lo as Avatar, M as Box, sf as ButtonSelect, gp as Checkbox, Eo as ColorInput, sm as ColorPresetInlineInput, we as ColorSwatch, wf as ColorSwatchPicker, vf as ComboBox, Rp as DateFormat, le as Dialog, Gn as DialogTitle, en as DomNodeRenderer, rr as Drawer, vu as Editor, Vl as FileUpload, Td as FreehandCanvas, hf as GridList, am as Group, xn as I18nProvider, xd as IconColorInput, Mr as IconColorInputButton, nc as IconSelect, pl as IconSlider, Ud as ImageDropZone, of as ImageGallery, Sc as InlineAlert, Sl as Link, re as ListBox, Iu as Markdown, dr as Menu, rm as MessageFormat, Ce as Modal, F5 as ModalClose, Be as ModalContent, xr as ModalTrigger, Ro as NumberFormat, Me as NumberInput, wp as Pagination, Se as Popover, Pe as PopoverContent, Le as PopoverTrigger, zo as Portal, wn as PortalContainerProvider, Xd as Preview, Xl as ProgressBar, No as ProgressSpinner, jr as RadioGroup, rp as Reaction, xu as ScrollControlButton, Pl as SearchInput, qe as Select, O as Separator, yo as Slider, _l as Switch, xc as TabItem, hc as Tabs, Fp as TagGroup, X as Text, wo as TextInput, _o as ThemeProvider, yr as ToggleButton, ve as ToggleIconButton, qr as Toolbar, ke as Tooltip, Vd as Transform, oa as Transition, $ as defineMessages, FR as isInsideOverlayContent, Ws as isRect, go as useDevice, F as useI18n, bo as useImage, bn as useIntersectionObserver, Ae as useIsFirstRender, Pn as useLocalStorage, rT as useMutationObserver, ue as usePortalContainer, gn as useResizeObserver, cT as useTextSelection, _n as useUndoRedo, Ia as useUserPreferences };