@baseline-ui/core 0.39.0 → 0.40.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,4 +1,4 @@
1
- import {classNames,invariant,filterTruthyValues,getSvgPathFromStroke,getHTMLElement,getTextDimensions,getPlainText,getAbsolutePosition,cleanKeyFromGlobImport,getOsSpecificKeyboardShortcutLabel,getAbsoluteBounds,isUrl,findFocusableElements,getActiveElement,isInputThatOpensKeyboard}from'@baseline-ui/utils';import wt,{useMemo,createElement,useContext,useEffect,createContext,useLayoutEffect,useCallback,useState,useRef,useImperativeHandle,forwardRef,useReducer,Fragment as Fragment$1,isValidElement}from'react';import {useControlledState,clamp}from'@react-stately/utils';import {useSeparator,useHover,mergeProps,useOption,useLocale,useListBox,ListKeyboardDelegate,useFocusRing,DragPreview,usePress,useTooltip,Overlay,useTooltipTrigger,useOverlayPosition,useNumberField,useNumberFormatter,useSlider,useSliderThumb,VisuallyHidden,useDialog,usePopover,DismissButton,useKeyboard,FocusScope,useSwitch,useSearchField,useMenu,useMenuTrigger,useLink,useDrop,useId,useProgressBar,useTextField,useCheckbox,useTagGroup,useFocusManager,useButton,useSelect,HiddenSelect,useTabList,useTab,useOverlayTrigger,useLabel,useField,useClipboard,useRadioGroup,useFilter,useInteractOutside,useComboBox,useObjectRef,useFocus,useGridListItem,useGridListSelectionCheckbox,useDraggableItem,useGridList,useTimeField,useDateField,useDraggableCollection,useDroppableCollection,ListDropTargetDelegate,useListBoxSection,useMessageFormatter,useMenuSection,useMenuItem,useToggleButton,useTag,useTabPanel,useRadio,useModalOverlay,useDropIndicator,useDateSegment,I18nProvider,useDateFormatter}from'react-aria';export{useCollator,useDateFormatter,useNumberFormatter}from'react-aria';import {useListState,useTooltipTriggerState,useNumberFieldState,useSliderState,useToggleState,useSearchFieldState,useTreeState,useMenuTriggerState,useSelectState,useTabListState,Item,useOverlayTriggerState,useRadioGroupState,useComboBoxState,useTimeFieldState,useDateFieldState,useDraggableCollectionState,useDroppableCollectionState,Section}from'react-stately';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {CheckmarkIcon,SearchIcon,CaretLeftIcon,CaretRightIcon,AvatarIcon,MoreIcon,QuestionmarkCircleIcon,PauseIcon,PlayIcon,TextIcon as TextIcon$1,HighlightTextIcon}from'@baseline-ui/icons/24';import {sprinkles,breakpoints,lightTheme,darkTheme,themeVars,layoutSprinkleValues}from'@baseline-ui/tokens';import {useGranularLayoutEffect,useGranularEffect}from'granular-hooks';import {CaretDownIcon,MinusIcon,PlusIcon,ChevronRightIcon,XIcon as XIcon$3}from'@baseline-ui/icons/8';import {ReadOnlyIcon,ErrorCircleFilledIcon,XIcon as XIcon$2,CheckmarkIcon as CheckmarkIcon$2,CheckmarkCircleFilledIcon,ErrorAltCircleFilledIcon as ErrorAltCircleFilledIcon$1,CaretLeftIcon as CaretLeftIcon$2,CaretRightIcon as CaretRightIcon$2,AvatarIcon as AvatarIcon$1,WarningFilledIcon as WarningFilledIcon$1,InfoCircleFilledIcon as InfoCircleFilledIcon$1,UndoIcon,RedoIcon,TrashIcon,ArrowDownCircleFilledIcon}from'@baseline-ui/icons/16';import {FocusableProvider,useFocusable,createFocusManager,useFocusRing as useFocusRing$1}from'@react-aria/focus';import {motion,MotionConfig,AnimatePresence,useReducedMotion,MotionGlobalConfig}from'motion/react';export{MotionGlobalConfig}from'motion/react';import {assignInlineVars,setElementVars}from'@vanilla-extract/dynamic';import r0 from'lodash/isEmpty';import {XIcon,SearchIcon as SearchIcon$1,CheckmarkIcon as CheckmarkIcon$1,CheckCircleFilledIcon,ErrorAltCircleFilledIcon,CaretLeftIcon as CaretLeftIcon$1,CaretRightIcon as CaretRightIcon$1,WarningFilledIcon,InfoCircleFilledIcon,TextIcon,BoldIcon,ItalicIcon,UnderlineIcon,ArrowUpCircleFilledIcon,AtIcon,XCircleFilledIcon,PlusIcon as PlusIcon$1,MinusIcon as MinusIcon$2,LinkIcon}from'@baseline-ui/icons/20';import wx,{createPortal}from'react-dom';import {XIcon as XIcon$1,CheckmarkIcon as CheckmarkIcon$3,MinusIcon as MinusIcon$1,CaretLeftIcon as CaretLeftIcon$3,CaretRightIcon as CaretRightIcon$3}from'@baseline-ui/icons/12';import {useInteractionModality,PressResponder,useFocus as useFocus$1,useInteractOutside as useInteractOutside$1}from'@react-aria/interactions';import {parseColor,useColorAreaState,useColorSliderState,useColorFieldState}from'@react-stately/color';import {useColorSwatch,useColorArea,useColorSlider,useColorField}from'@react-aria/color';import {getStroke}from'perfect-freehand';import {makeMoveable,Draggable,Resizable,Rotatable,Snappable}from'react-moveable';import {useToolbar}from'@react-aria/toolbar';import {take,clamp as clamp$1,uniqueId,camelCase,flatMapDeep,kebabCase}from'lodash';import {createBoldPlugin,createItalicPlugin,createUnderlinePlugin,MARK_BOLD,MARK_ITALIC,MARK_UNDERLINE}from'@udecode/plate-basic-marks';import {findNodePath,removeNodes,focusEditor,Hotkeys,getPointBefore,createPointRef,moveSelection,insertNodes,PlateElement,insertText,useElement,getHandler,createPluginFactory,createPlugins,PlateLeaf,deselect,Plate,PlateContent,getEditorString,getRange,useEditorSelector,isMarkActive,useEditorRef,toggleMark,findNode,getPluginType}from'@udecode/plate-common';import {createFontColorPlugin,createFontBackgroundColorPlugin,MARK_COLOR,MARK_BG_COLOR,useColorDropdownMenuState}from'@udecode/plate-font';import {createParagraphPlugin,ELEMENT_PARAGRAPH}from'@udecode/plate-paragraph';import {createLinkPlugin,ELEMENT_LINK,upsertLink,unwrapLink}from'@udecode/plate-link';import {withRef,withProps}from'@udecode/cn';import*as Pb from'dompurify';import {jsx as jsx$1}from'slate-hyperscript';import {useHTMLInputCursorState}from'@udecode/plate-combobox';import {useSelected}from'slate-react';import f4 from'markdown-it';import {announce}from'@react-aria/live-announcer';import {useActionGroup,useActionGroupItem}from'@react-aria/actiongroup';import {ControlledTreeEnvironment,Tree}from'react-complex-tree';import {Panel,PanelGroup,PanelResizeHandle}from'react-resizable-panels';import {useToastQueue}from'@react-stately/toast';export{ToastQueue}from'@react-stately/toast';import {useToastRegion,useToast}from'@react-aria/toast';/**
1
+ import {classNames,invariant,filterTruthyValues,getSvgPathFromStroke,getHTMLElement,getTextDimensions,getPlainText,getAbsolutePosition,cleanKeyFromGlobImport,getOsSpecificKeyboardShortcutLabel,getAbsoluteBounds,isUrl,findFocusableElements,getActiveElement,isInputThatOpensKeyboard}from'@baseline-ui/utils';import ht,{useMemo,createElement,useContext,useEffect,createContext,useLayoutEffect,useCallback,useState,useRef,useImperativeHandle,forwardRef,useReducer,Fragment as Fragment$1,isValidElement}from'react';import {useControlledState,clamp}from'@react-stately/utils';import {useSeparator,useHover,mergeProps,useOption,useLocale,useListBox,ListKeyboardDelegate,useFocusRing,DragPreview,usePress,useTooltip,Overlay,useTooltipTrigger,useOverlayPosition,useNumberField,useNumberFormatter,useSlider,useSliderThumb,VisuallyHidden,useDialog,usePopover,DismissButton,useKeyboard,FocusScope,useSwitch,useSearchField,useMenu,useMenuTrigger,useLink,useDrop,useId,useProgressBar,useTextField,useCheckbox,useTagGroup,useFocusManager,useButton,useSelect,HiddenSelect,useTabList,useTab,useOverlayTrigger,useLabel,useField,useClipboard,useRadioGroup,useFilter,useInteractOutside,useComboBox,useObjectRef,useFocus,useGridListItem,useGridListSelectionCheckbox,useDraggableItem,useGridList,useTimeField,useDateField,useDraggableCollection,useDroppableCollection,ListDropTargetDelegate,useListBoxSection,useMessageFormatter,useMenuSection,useMenuItem,useToggleButton,useTag,useTabPanel,useRadio,useModalOverlay,useDropIndicator,useDateSegment,I18nProvider,useDateFormatter}from'react-aria';export{useCollator,useDateFormatter,useNumberFormatter}from'react-aria';import {useListState,useTooltipTriggerState,useNumberFieldState,useSliderState,useToggleState,useSearchFieldState,useTreeState,useMenuTriggerState,useSelectState,useTabListState,Item,useOverlayTriggerState,useRadioGroupState,useComboBoxState,useTimeFieldState,useDateFieldState,useDraggableCollectionState,useDroppableCollectionState,Section}from'react-stately';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {CheckmarkIcon,SearchIcon,CaretLeftIcon,CaretRightIcon,AvatarIcon,MoreIcon,QuestionmarkCircleIcon,PauseIcon,PlayIcon,TextIcon as TextIcon$1,HighlightTextIcon}from'@baseline-ui/icons/24';import {sprinkles,breakpoints,lightTheme,darkTheme,themeVars,layoutSprinkleValues}from'@baseline-ui/tokens';import {useGranularLayoutEffect,useGranularEffect}from'granular-hooks';import {CaretDownIcon,MinusIcon,PlusIcon,ChevronRightIcon,XIcon as XIcon$3}from'@baseline-ui/icons/8';import {ReadOnlyIcon,ErrorCircleFilledIcon,XIcon as XIcon$2,CheckmarkIcon as CheckmarkIcon$2,CheckmarkCircleFilledIcon,ErrorAltCircleFilledIcon as ErrorAltCircleFilledIcon$1,CaretLeftIcon as CaretLeftIcon$2,CaretRightIcon as CaretRightIcon$2,AvatarIcon as AvatarIcon$1,WarningFilledIcon as WarningFilledIcon$1,InfoCircleFilledIcon as InfoCircleFilledIcon$1,HelpIcon,UndoIcon,RedoIcon,TrashIcon,ArrowDownCircleFilledIcon}from'@baseline-ui/icons/16';import {FocusableProvider,useFocusable,createFocusManager,useFocusRing as useFocusRing$1}from'@react-aria/focus';import {motion,MotionConfig,AnimatePresence,useReducedMotion,MotionGlobalConfig}from'motion/react';export{MotionGlobalConfig}from'motion/react';import Fv from'lodash/isEmpty';import {assignInlineVars}from'@vanilla-extract/dynamic';import {XIcon,SearchIcon as SearchIcon$1,CheckmarkIcon as CheckmarkIcon$1,CheckCircleFilledIcon,ErrorAltCircleFilledIcon,CaretLeftIcon as CaretLeftIcon$1,CaretRightIcon as CaretRightIcon$1,WarningFilledIcon,InfoCircleFilledIcon,TextIcon,BoldIcon,ItalicIcon,UnderlineIcon,ArrowUpCircleFilledIcon,AtIcon,XCircleFilledIcon,PlusIcon as PlusIcon$1,MinusIcon as MinusIcon$2,LinkIcon}from'@baseline-ui/icons/20';import Bz,{createPortal}from'react-dom';import {XIcon as XIcon$1,CheckmarkIcon as CheckmarkIcon$3,MinusIcon as MinusIcon$1,CaretLeftIcon as CaretLeftIcon$3,CaretRightIcon as CaretRightIcon$3}from'@baseline-ui/icons/12';import {useInteractionModality,PressResponder,useFocus as useFocus$1,useInteractOutside as useInteractOutside$1}from'@react-aria/interactions';import {parseColor,useColorAreaState,useColorSliderState,useColorFieldState}from'@react-stately/color';import {useColorSwatch,useColorArea,useColorSlider,useColorField}from'@react-aria/color';import {getStroke}from'perfect-freehand';import {makeMoveable,Draggable,Resizable,Rotatable,Snappable}from'react-moveable';import {take,clamp as clamp$1,uniqueId,camelCase,flatMapDeep,kebabCase}from'lodash';import {useToolbar}from'@react-aria/toolbar';import {createBoldPlugin,createItalicPlugin,createUnderlinePlugin,MARK_BOLD,MARK_ITALIC,MARK_UNDERLINE}from'@udecode/plate-basic-marks';import {findNodePath,removeNodes,focusEditor,Hotkeys,getPointBefore,createPointRef,moveSelection,insertNodes,PlateElement,insertText,useElement,getHandler,createPluginFactory,createPlugins,PlateLeaf,deselect,Plate,PlateContent,getEditorString,getRange,useEditorSelector,isMarkActive,useEditorRef,toggleMark,findNode,getPluginType}from'@udecode/plate-common';import {createFontColorPlugin,createFontBackgroundColorPlugin,MARK_COLOR,MARK_BG_COLOR,useColorDropdownMenuState}from'@udecode/plate-font';import {createParagraphPlugin,ELEMENT_PARAGRAPH}from'@udecode/plate-paragraph';import {createLinkPlugin,ELEMENT_LINK,upsertLink,unwrapLink}from'@udecode/plate-link';import {withRef,withProps}from'@udecode/cn';import*as c1 from'dompurify';import {jsx as jsx$1}from'slate-hyperscript';import {useHTMLInputCursorState}from'@udecode/plate-combobox';import {useSelected}from'slate-react';import wR from'markdown-it';import {announce}from'@react-aria/live-announcer';import {useActionGroup,useActionGroupItem}from'@react-aria/actiongroup';import {ControlledTreeEnvironment,Tree}from'react-complex-tree';import {Panel,PanelGroup,PanelResizeHandle}from'react-resizable-panels';import {useToastQueue}from'@react-stately/toast';export{ToastQueue}from'@react-stately/toast';import {useToastRegion,useToast}from'@react-aria/toast';/**
2
2
  * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
3
  *
4
4
  * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
@@ -7,10 +7,7 @@ import {classNames,invariant,filterTruthyValues,getSvgPathFromStroke,getHTMLElem
7
7
  * This notice may not be removed from this file.
8
8
  *
9
9
  */
10
- var wh=Object.create;var wp=Object.defineProperty;var kh=Object.getOwnPropertyDescriptor;var Ih=Object.getOwnPropertyNames;var Sh=Object.getPrototypeOf,Rh=Object.prototype.hasOwnProperty;var kp=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports);var $h=(r,e,t,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of Ih(e))!Rh.call(r,a)&&a!==t&&wp(r,a,{get:()=>e[a],enumerable:!(o=kh(e,a))||o.enumerable});return r};var yi=(r,e,t)=>(t=r!=null?wh(Sh(r)):{},$h(!r||!r.__esModule?wp(t,"default",{value:r,enumerable:true}):t,r));var Wi=kp((bB,xd)=>{var N_={},L_=N_.hasOwnProperty,A_=function(e,t){if(!e)return t;var o={};for(var a in t)o[a]=L_.call(e,a)?e[a]:t[a];return o},B_=/[ -,\.\/:-@\[-\^`\{-~]/,O_=/[ -,\.\/:-@\[\]\^`\{-~]/,F_=/(^|\\+)?(\\[A-F0-9]{1,6})\x20(?![a-fA-F0-9\x20])/g,Ki=function r(e,t){t=A_(t,r.options),t.quotes!="single"&&t.quotes!="double"&&(t.quotes="single");for(var o=t.quotes=="double"?'"':"'",a=t.isIdentifier,n=e.charAt(0),i="",s=0,l=e.length;s<l;){var p=e.charAt(s++),c=p.charCodeAt(),d=void 0;if(c<32||c>126){if(c>=55296&&c<=56319&&s<l){var m=e.charCodeAt(s++);(m&64512)==56320?c=((c&1023)<<10)+(m&1023)+65536:s--;}d="\\"+c.toString(16).toUpperCase()+" ";}else t.escapeEverything?B_.test(p)?d="\\"+p:d="\\"+c.toString(16).toUpperCase()+" ":/[\t\n\f\r\x0B]/.test(p)?d="\\"+c.toString(16).toUpperCase()+" ":p=="\\"||!a&&(p=='"'&&o==p||p=="'"&&o==p)||a&&O_.test(p)?d="\\"+p:d=p;i+=d;}return a&&(/^-[-\d]/.test(i)?i="\\-"+i.slice(1):/\d/.test(n)&&(i="\\3"+n+" "+i.slice(1))),i=i.replace(F_,function(u,b,y){return b&&b.length%2?u:(b||"")+y}),!a&&t.wrap?o+i+o:i};Ki.options={escapeEverything:false,isIdentifier:false,quotes:"single",wrap:false};Ki.version="3.0.0";xd.exports=Ki;});var Xd=kp((lO,Zd)=>{var Fz=function(e){return jz(e)&&!Hz(e)};function jz(r){return !!r&&typeof r=="object"}function Hz(r){var e=Object.prototype.toString.call(r);return e==="[object RegExp]"||e==="[object Date]"||qz(r)}var Vz=typeof Symbol=="function"&&Symbol.for,Uz=Vz?Symbol.for("react.element"):60103;function qz(r){return r.$$typeof===Uz}function Gz(r){return Array.isArray(r)?[]:{}}function no(r,e){return e.clone!==false&&e.isMergeableObject(r)?dr(Gz(r),r,e):r}function Kz(r,e,t){return r.concat(e).map(function(o){return no(o,t)})}function Wz(r,e){if(!e.customMerge)return dr;var t=e.customMerge(r);return typeof t=="function"?t:dr}function Yz(r){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(r).filter(function(e){return Object.propertyIsEnumerable.call(r,e)}):[]}function Wd(r){return Object.keys(r).concat(Yz(r))}function Yd(r,e){try{return e in r}catch{return false}}function Zz(r,e){return Yd(r,e)&&!(Object.hasOwnProperty.call(r,e)&&Object.propertyIsEnumerable.call(r,e))}function Xz(r,e,t){var o={};return t.isMergeableObject(r)&&Wd(r).forEach(function(a){o[a]=no(r[a],t);}),Wd(e).forEach(function(a){Zz(r,a)||(Yd(r,a)&&t.isMergeableObject(e[a])?o[a]=Wz(a,t)(r[a],e[a],t):o[a]=no(e[a],t));}),o}function dr(r,e,t){t=t||{},t.arrayMerge=t.arrayMerge||Kz,t.isMergeableObject=t.isMergeableObject||Fz,t.cloneUnlessOtherwiseSpecified=no;var o=Array.isArray(e),a=Array.isArray(r),n=o===a;return n?o?t.arrayMerge(r,e,t):Xz(r,e,t):no(e,t)}dr.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(o,a){return dr(o,a,t)},{})};var Jz=dr;Zd.exports=Jz;});var Te=typeof document<"u"?wt.useLayoutEffect:()=>{};function bi(r){let e=useRef(null);return Te(()=>{e.current=r;},[r]),useCallback((...t)=>{let o=e.current;return o?.(...t)},[])}function gi(r){let[e,t]=useState(r),o=useRef(null),a=bi(()=>{if(!o.current)return;let i=o.current.next();if(i.done){o.current=null;return}e===i.value?a():t(i.value);});Te(()=>{o.current&&a();});let n=bi(i=>{o.current=i(e),a();});return [e,n]}var Xo={prefix:String(Math.round(Math.random()*1e10)),current:0},Ip=wt.createContext(Xo),Bh=wt.createContext(false);var Oh=!!(typeof window<"u"&&window.document&&window.document.createElement),vi=new WeakMap;function Fh(r=false){let e=useContext(Ip),t=useRef(null);if(t.current===null&&!r){var o,a;let n=(a=wt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)===null||a===void 0||(o=a.ReactCurrentOwner)===null||o===void 0?void 0:o.current;if(n){let i=vi.get(n);i==null?vi.set(n,{id:e.current,state:n.memoizedState}):n.memoizedState!==i.state&&(e.current=i.id,vi.delete(n));}t.current=++e.current;}return t.current}function jh(r){let e=useContext(Ip);e===Xo&&!Oh&&console.warn("When server rendering, you must wrap your application in an <SSRProvider> to ensure consistent ids are generated between the client and server.");let t=Fh(!!r),o=e===Xo&&process.env.NODE_ENV==="test"?"react-aria":`react-aria${e.prefix}`;return r||`${o}-${t}`}function Hh(r){let e=wt.useId(),[t]=useState(Sp()),o=t||process.env.NODE_ENV==="test"?"react-aria":`react-aria${Xo.prefix}`;return r||`${o}-${e}`}var _i=typeof wt.useId=="function"?Hh:jh;function Vh(){return false}function Uh(){return true}function qh(r){return ()=>{}}function Sp(){return typeof wt.useSyncExternalStore=="function"?wt.useSyncExternalStore(qh,Vh,Uh):useContext(Bh)}var Zh=!!(typeof window<"u"&&window.document&&window.document.createElement),Qe=new Map;function Jo(r){let[e,t]=useState(r),o=useRef(null),a=_i(e),n=useCallback(i=>{o.current=i;},[]);return Zh&&(Qe.has(a)&&!Qe.get(a).includes(n)?Qe.set(a,[...Qe.get(a),n]):Qe.set(a,[n])),Te(()=>{let i=a;return ()=>{Qe.delete(i);}},[a]),useEffect(()=>{let i=o.current;i&&(o.current=null,t(i));}),a}function zi(r,e){if(r===e)return r;let t=Qe.get(r);if(t)return t.forEach(a=>a(e)),e;let o=Qe.get(e);return o?(o.forEach(a=>a(r)),r):e}function Rp(...r){return (...e)=>{for(let t of r)typeof t=="function"&&t(...e);}}var be=r=>{var e;return (e=r?.ownerDocument)!==null&&e!==void 0?e:document},re=r=>r&&"window"in r&&r.window===r?r:be(r).defaultView||window;function Xh(r){return r!==null&&typeof r=="object"&&"nodeType"in r&&typeof r.nodeType=="number"}function xi(r){return Xh(r)&&r.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&"host"in r}var Qo=(r=document)=>{var e;let t=r.activeElement;for(;t&&"shadowRoot"in t&&(!((e=t.shadowRoot)===null||e===void 0)&&e.activeElement);)t=t.shadowRoot.activeElement;return t};function $p(r){var e,t,o="";if(typeof r=="string"||typeof r=="number")o+=r;else if(typeof r=="object")if(Array.isArray(r)){var a=r.length;for(e=0;e<a;e++)r[e]&&(t=$p(r[e]))&&(o&&(o+=" "),o+=t);}else for(t in r)r[t]&&(o&&(o+=" "),o+=t);return o}function Jh(){for(var r,e,t=0,o="",a=arguments.length;t<a;t++)(r=arguments[t])&&(e=$p(r))&&(o&&(o+=" "),o+=e);return o}var Tp=Jh;function et(...r){let e={...r[0]};for(let t=1;t<r.length;t++){let o=r[t];for(let a in o){let n=e[a],i=o[a];typeof n=="function"&&typeof i=="function"&&a[0]==="o"&&a[1]==="n"&&a.charCodeAt(2)>=65&&a.charCodeAt(2)<=90?e[a]=Rp(n,i):(a==="className"||a==="UNSAFE_className")&&typeof n=="string"&&typeof i=="string"?e[a]=Tp(n,i):a==="id"&&n&&i?e.id=zi(n,i):e[a]=i!==void 0?i:n;}}return e}function M(...r){return r.length===1&&r[0]?r[0]:e=>{for(let t of r)typeof t=="function"?t(e):t!=null&&(t.current=e);}}var Qh=new Set(["id"]),e5=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),t5=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),r5=/^(data-.*)$/;function Ci(r,e={}){let{labelable:t,isLink:o,propNames:a}=e,n={};for(let i in r)Object.prototype.hasOwnProperty.call(r,i)&&(Qh.has(i)||t&&e5.has(i)||o&&t5.has(i)||a?.has(i)||r5.test(i))&&(n[i]=r[i]);return n}function ea(r){var e;return typeof window>"u"||window.navigator==null?false:((e=window.navigator.userAgentData)===null||e===void 0?void 0:e.brands.some(t=>r.test(t.brand)))||r.test(window.navigator.userAgent)}function Fe(r){let e=null;return ()=>(e==null&&(e=r()),e)}var Kr=Fe(function(){return ea(/Firefox/i)});function oe(r){let e=useRef(null);return useMemo(()=>({get current(){return e.current},set current(t){e.current=t,typeof r=="function"?r(t):r&&(r.current=t);}}),[r])}function p5(){return typeof window.ResizeObserver<"u"}function ki(r){let{ref:e,box:t,onResize:o}=r;useEffect(()=>{let a=e?.current;if(a)if(p5()){let n=new window.ResizeObserver(i=>{i.length&&o();});return n.observe(a,{box:t}),()=>{a&&n.unobserve(a);}}else return window.addEventListener("resize",o,false),()=>{window.removeEventListener("resize",o,false);}},[o,e,t]);}function tt(r){return !!r&&"label"in r&&!!r.label}function ta(r){return !!r&&"children"in r&&!!r.children&&"title"in r}function u5(r){return ta(r)?jsx(Section,{items:r.children,title:r.title,"aria-label":r.title,children:e=>jsx(Item,{textValue:e.label,children:e.label},e.id)},r.id):jsx(Item,{textValue:r.label,children:r.label},r.id)}function pe(){return useCallback(r=>u5(r),[])}function ra(r,e,t){let{direction:o}=useLocale(),a=useDraggableCollectionState({...r,collection:e.collection,selectionManager:e.selectionManager,isDisabled:!r.enableReorder,getItems:r.getItems||(s=>[...s].map(l=>{let p=e.collection.getItem(l);return invariant(p,"Expected item to be defined."),{"text/plain":p.textValue}}))});useDraggableCollection(r,a,t);let n=useDroppableCollectionState({...r,collection:e.collection,selectionManager:e.selectionManager}),{collectionProps:i}=useDroppableCollection({...r,keyboardDelegate:new ListKeyboardDelegate({collection:e.collection,disabledKeys:e.disabledKeys,ref:t,orientation:r.orientation,layout:r.layout,direction:o}),dropTargetDelegate:new ListDropTargetDelegate(e.collection,t)},n,t);return {collectionProps:i,dragState:a,dropState:n}}function z5(r,e){if(typeof r!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var o=t.call(r,e);if(typeof o!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return (e==="string"?String:Number)(r)}function x5(r){var e=z5(r,"string");return typeof e=="symbol"?e:String(e)}function C5(r,e,t){return e=x5(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:true,configurable:true,writable:true}):r[e]=t,r}function Ap(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(r);e&&(o=o.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,o);}return t}function Bp(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?Ap(Object(t),true).forEach(function(o){C5(r,o,t[o]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):Ap(Object(t)).forEach(function(o){Object.defineProperty(r,o,Object.getOwnPropertyDescriptor(t,o));});}return r}function Op(r,e){var t={};for(var o in r)t[o]=e(r[o],o);return t}var P5=(r,e,t)=>{for(var o of Object.keys(r)){var a;if(r[o]!==((a=e[o])!==null&&a!==void 0?a:t[o]))return false}return true},x=r=>{var e=t=>{var o=r.defaultClassName,a=Bp(Bp({},r.defaultVariants),t);for(var n in a){var i,s=(i=a[n])!==null&&i!==void 0?i:r.defaultVariants[n];if(s!=null){var l=s;typeof l=="boolean"&&(l=l===true?"true":"false");var p=r.variantClassNames[n][l];p&&(o+=" "+p);}}for(var[c,d]of r.compoundVariants)P5(c,a,r.defaultVariants)&&(o+=" "+d);return o};return e.variants=()=>Object.keys(r.variantClassNames),e.classNames={get base(){return r.defaultClassName.split(" ")[0]},get variants(){return Op(r.variantClassNames,t=>Op(t,o=>o.split(" ")[0]))}},e};var Fp=x({defaultClassName:"_6n12k9b _1yep5z6ls _1yep5z6lr _1yep5z6ic _1yep5z6la",variantClassNames:{isDropTarget:{true:"_1yep5z6140"},orientation:{vertical:"_1yep5z617q",horizontal:"_1yep5z617r"}},defaultVariants:{},compoundVariants:[]}),jp="_6n12k98 _1yep5z6lq _1yep5z6is _1yep5z6it _1yep5z6iu",Hp=x({defaultClassName:"_6n12k99 _1yep5z6ev _1yep5z6da _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),Vp=x({defaultClassName:"_6n12k91 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6dy _1yep5z6eu _1yep5z6la _1yep5z6ld _1yep5z6lq _1yep5z6lp _1yep5z6ln _1yep5z6lk",variantClassNames:{isSelected:{},isFocused:{true:"_1yep5z6140 _1yep5z617w _1yep5z617u _1yep5z617x _1yep5z614g _1yep5z614h _1yep5z614i"},isHovered:{true:"_1yep5z6125",false:"_1yep5z6124"},isFirstChild:{true:"_6n12k95"},isLastChild:{true:"_6n12k96"},isDisabled:{true:"z9nup83 _1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),Up="_6n12k9f _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",qp="_6n12k90";var Gp=x({defaultClassName:"gukncs0",variantClassNames:{isVertical:{true:"gukncs1"},isSecondary:{true:"gukncs2"}},defaultVariants:{},compoundVariants:[]});var U=wt.forwardRef(({className:r,style:e,variant:t="primary",orientation:o="horizontal",UNSAFE_omitRole:a,elementType:n="div","data-block-id":i,"data-block-class":s,...l},p)=>{let{separatorProps:c}=useSeparator({...l,orientation:o,elementType:n});return jsx(n,{...c,className:classNames(Gp({isVertical:o==="vertical",isSecondary:t==="secondary"}),"BaselineUI-Separator",r),"data-orientation":o,"data-block-id":i,"data-block-class":s,style:e,role:a?void 0:c.role,ref:p})});U.displayName="Separator";function D5(r){return sprinkles.properties.has(r)}var D=wt.forwardRef(({elementType:r="div",children:e,...t},o)=>{let a=r,{sprinkleProps:n,domProps:i}=useMemo(()=>{let s={},l={};for(let p in t)D5(p)?s[p]=t[p]:l[p]=t[p];return {sprinkleProps:s,domProps:l}},[t]);return jsx(a,{...i,className:classNames(sprinkles(n),"BaselineUI-Box",i.className),ref:o,children:e})});D.displayName="Box";var Yr=wt.forwardRef(({item:r,isDisabled:e,isFocusVisible:t,isSelected:o,liProps:a,showSelectedIcon:n,description:i,descriptionProps:s,labelProps:l,isFocused:p,isPressed:c,_state:d},m)=>{invariant(r.value&&tt(r.value),"Item cannot be a section");let{icon:u,label:b}=r.value,{hoverProps:y,isHovered:f}=useHover({isDisabled:e}),g=filterTruthyValues({"data-selected":o,"data-disabled":e,"data-focused":p,"data-hovered":f,"data-pressed":c,"data-focus-visible":t,"data-selection-mode":d.selectionManager.selectionMode});return jsxs("li",{...mergeProps(a,y,g),className:classNames(Vp({isHovered:f,isFocused:t,isFirstChild:d.collection.getFirstKey()===r.key,isLastChild:d.collection.getLastKey()===r.key,isDisabled:e}),a.className,"BaselineUI-ListBox-Option"),style:a.style,ref:m,children:[jsxs(D,{display:"flex",alignItems:"center",gap:"lg",children:[n?jsx("span",{"aria-hidden":true,style:{height:24,width:24},children:o?jsx(CheckmarkIcon,{size:24}):null}):null,u?jsx(u,{size:24}):null,jsx("span",{...l,children:b})]}),i?jsx("span",{className:Hp({isDisabled:e}),...s,children:i}):null]})});Yr.displayName="DefaultRenderOption";var Wt=({dropState:r,orientation:e="vertical",dropIndicatorStyle:t,dropIndicatorClassName:o,renderDropIndicator:a=({isDropTarget:i,isHidden:s,dropIndicatorProps:l,orientation:p},c)=>s?null:jsx("li",{...l,ref:c,"data-drop-target":i,className:classNames(Fp({isDropTarget:i,orientation:p}),"BaselineUI-DropIndicator",o),style:t}),...n})=>{let i=wt.useRef(null),{dropIndicatorProps:s,isHidden:l,isDropTarget:p}=useDropIndicator(n,r,i);return a({dropIndicatorProps:{...s,role:"option"},isHidden:l,isDropTarget:p,orientation:e},i)};function rt(r,e,t){return typeof r=="function"?r(e,t):r}function oa(r,e,t){return typeof r=="function"?r(e,t):r}function aa(r,e){return typeof r=="function"?r(e):r}function Ri(r,e){return typeof r=="function"?r(e):r}var Zp=({item:r,children:e,state:t,dragState:o,...a})=>{let{dragProps:n}=useDraggableItem({key:r.key},o);return jsxs(Fragment,{children:[jsx(Wt,{target:{type:"item",key:r.key,dropPosition:"before"},...a}),e(n),t.collection.getKeyAfter(r.key)==null&&jsx(Wt,{target:{type:"item",key:r.key,dropPosition:"after"},...a})]})};Zp.displayName="DraggableListOption";var Zr=wt.forwardRef(({item:r,renderOption:e=(m,u,b)=>jsx(Yr,{item:m,liProps:u.optionProps,...u,ref:b}),showSelectedIcon:t,state:o,dragState:a,dropState:n,orientation:i,dropIndicatorStyle:s,dropIndicatorClassName:l,optionStyle:p,optionClassName:c},d)=>{let m=wt.useRef(null),u=useOption({key:r.key},o,m),{value:b}=r;invariant(b&&tt(b),"ListSection should not be passed to ListOption");let y={isFocusVisible:u.isFocusVisible,isSelected:u.isSelected,isFocused:u.isFocused,isDisabled:u.isDisabled,isPressed:u.isPressed},f={style:oa(p,b,y),className:rt(c,b,y)};return a&&n?jsx(Zp,{orientation:i,state:o,item:r,dropState:n,dragState:a,dropIndicatorStyle:s,dropIndicatorClassName:l,children:g=>e(r,{...u,showSelectedIcon:t,_state:o,optionProps:{...mergeProps(u.optionProps,g),...f}},M(m,d))}):e(r,{...u,showSelectedIcon:t,_state:o,optionProps:{...u.optionProps,...f}},M(m,d))});Zr.displayName="Option";var ec=({section:r,state:e,sectionClassName:t,sectionStyle:o,showSectionHeader:a,renderSectionHeader:n,withSectionHeaderPadding:i=false,...s})=>{let l=wt.useRef(null),{itemProps:p,groupProps:c,headingProps:d}=useListBoxSection({heading:a?n?.(r,l)||r.rendered:void 0,"aria-label":r["aria-label"]}),m=e.collection.getChildren?.(r.key);invariant(m,"children must be defined");let{value:u}=r;invariant(u&&ta(u),"section must be a ListSection");let b=typeof o=="function"?o(u):o,y=typeof t=="function"?t(u):t;return jsxs(Fragment,{children:[r.key===e.collection.getFirstKey()?null:jsx(U,{UNSAFE_omitRole:true}),jsxs("li",{...p,style:{...p.style,...b},className:classNames(qp,y,"BaselineUI-ListBox-Section"),children:[r.rendered&&a?n?.(r,l)||jsx(D,{...d,className:classNames("BaselineUI-ListBox-SectionHeader",Up),ref:l,paddingX:"lg",typography:"label.md.medium",color:"text.primary",paddingInlineStart:i?"5xl":"lg",paddingInlineEnd:"lg",children:r.rendered}):null,jsx("ul",{...c,children:[...m].map(f=>jsx(Zr,{item:f,state:e,...s},f.key))})]})]})};function sa({type:r="listbox",handle:e},t,o){let a=useCallback(i=>r==="listbox"?o.current?.querySelector(`[data-key="${i}"][role="option"]`):o.current?.querySelector(`[data-key="${i}"][role="row"]`),[r,o]),n=useCallback((i,s)=>{let l=a(i);l&&l?.scrollIntoView({block:"nearest",inline:"nearest",...s});},[a]);useImperativeHandle(e,()=>({scrollIntoView:n,setFocusedKey:i=>{t.selectionManager.setFocused(true),t.selectionManager.setFocusedKey(i),n(i),a(i)?.focus();}}),[n,t.selectionManager,a]),useGranularEffect(()=>{let i=o.current?.getRootNode(),s=i&&xi(i),l=t.selectionManager.focusedKey;s&&l&&n(l);},[t.selectionManager.focusedKey],[n,o]);}var kt=wt.createContext(null),$i=wt.forwardRef(({className:r,layout:e="stack",orientation:t="vertical",showSelectedIcon:o=true,style:a,renderOption:n,enableReorder:i=false,"data-block-id":s,"data-block-class":l,renderDragPreview:p,onReorder:c,state:d,listBoxHandle:m,...u},b)=>{let y=wt.useRef(null),{direction:f}=useLocale(),g=wt.useRef(null),{listBoxProps:v}=useListBox({...u,shouldSelectOnPressUp:i,keyboardDelegate:new ListKeyboardDelegate({collection:d.collection,ref:g,layout:e,orientation:t,direction:f,disabledKeys:d.disabledKeys})},d,g);sa({handle:m},d,g);let{collectionProps:h,dragState:_,dropState:z}=ra({...u,onReorder:c,layout:e,orientation:t,enableReorder:i,preview:y},d,g),{isFocusVisible:P,isFocused:w,focusProps:C}=useFocusRing(),k=filterTruthyValues({"data-block-id":s,"data-block-class":l,"data-layout":e,"data-empty":d.collection.size===0,"data-focused":w,"data-focus-visible":P,"data-orientation":t});return jsxs("ul",{...mergeProps(v,C,k,h),className:classNames(jp,"BaselineUI-ListBox",r),style:a,ref:M(b,g),children:[[...d.collection].map($=>{let R={key:$.key,state:d,dragState:_,dropState:z,renderOption:n,renderDropIndicator:u.renderDropIndicator,renderSectionHeader:u.renderSectionHeader,showSelectedIcon:o,orientation:t,dropIndicatorStyle:u.dropIndicatorStyle,dropIndicatorClassName:u.dropIndicatorClassName,optionStyle:u.optionStyle,optionClassName:u.optionClassName,sectionClassName:u.sectionClassName,sectionStyle:u.sectionStyle,showSectionHeader:u.showSectionHeader,withSectionHeaderPadding:u.withSectionHeaderPadding};return $.type==="section"?createElement(ec,{...R,key:$.key,section:$}):createElement(Zr,{...R,key:$.key,item:$})}),p?jsx(DragPreview,{ref:y,children:p}):null]})});$i.displayName="ListBoxCore";var oc=wt.forwardRef((r,e)=>{let t=pe(),o=useListState({...r,children:t});return jsx($i,{...r,ref:e,state:o})});oc.displayName="ListBoxStandalone";var me=wt.forwardRef((r,e)=>{let t=useContext(kt);return useEffect(()=>{if(!r.items&&!t)throw new Error("ListBox: You must provide a `state` or `items` prop to render the listbox.")},[r.items,t]),t?jsx($i,{...r,ref:e,state:t}):jsx(oc,{...r,ref:e})});me.displayName="ListBox";var pa="uf19bsf _1yep5z6la",ac=x({defaultClassName:"uf19bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f5 _1yep5z6lp _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6lk",variantClassNames:{size:{xxs:"uf19bs1",xs:"uf19bs2",sm:"uf19bs3",md:"uf19bs4",lg:"uf19bs5 _1yep5z6wo _1yep5z6wp _1yep5z6wq _1yep5z6xc _1yep5z6xd _1yep5z6xe _1yep5z6y0 _1yep5z6y1 _1yep5z6y2 _1yep5z6yo _1yep5z6yp _1yep5z6yq"},isHovered:{true:"uf19bs6"},isDisabled:{true:"uf19bs7 _1yep5z611a"},isFocusVisible:{true:"uf19bs8"},variant:{primary:"uf19bs9",secondary:"uf19bsa",tertiary:"uf19bsb",ghost:"uf19bsc",toolbar:"uf19bsd _1yep5z6x6 _1yep5z6x7 _1yep5z6x8 _1yep5z6xu _1yep5z6xv _1yep5z6xw _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8",popover:"uf19bse _1yep5z6pr _1yep5z6ps _1yep5z6pt _1yep5z6nf _1yep5z6ng _1yep5z6nh _1yep5z6m6 _1yep5z6m7 _1yep5z6m8 _1yep5z6oi _1yep5z6oj _1yep5z6ok _1yep5z6vr _1yep5z6vs _1yep5z6vt"}},defaultVariants:{},compoundVariants:[[{variant:"toolbar",isHovered:true,isFocusVisible:false},"_1yep5z61o9"],[{variant:"primary",isHovered:true,isFocusVisible:false},"_1yep5z61o9"],[{variant:"secondary",isHovered:true,isFocusVisible:false},"_1yep5z61nc"],[{variant:"tertiary",isHovered:true,isFocusVisible:false},"_1yep5z61nb _1yep5z61o9"],[{variant:"ghost",isHovered:true,isFocusVisible:false},"_1yep5z61nh"],[{variant:"popover",isHovered:true,isFocusVisible:false},"_1yep5z61q6 _1yep5z61tx _1yep5z61u1 _1yep5z61ty"],[{variant:"ghost",isDisabled:false},"_1yep5z61ng"],[{variant:"popover",size:"lg"},"_1yep5z61io _1yep5z61ip _1yep5z61iq _1yep5z61jc _1yep5z61jd _1yep5z61je _1yep5z61k0 _1yep5z61k1 _1yep5z61k2 _1yep5z61ko _1yep5z61kp _1yep5z61kq"]]});var Xr=wt.createContext({state:null,overlayTriggerAria:{triggerProps:{},overlayProps:{}},triggerRef:void 0}),je=({children:r,...e})=>{let t=wt.useRef(null),o=useOverlayTriggerState(e),a=useOverlayTrigger(e,o),n=useMemo(()=>({state:o,overlayTriggerAria:a,triggerRef:t}),[o,a]);return jsx(Xr.Provider,{value:n,children:r})};var ic=x({defaultClassName:"_1gzftth2",variantClassNames:{placement:{bottom:"_1gzftth3",top:"_1gzftth4",right:"_1gzftth5",left:"_1gzftth6"}},defaultVariants:{},compoundVariants:[]}),sc=x({defaultClassName:"_1gzftth7",variantClassNames:{placement:{bottom:"_1gzftth8",top:"_1gzftth9",right:"_1gzfttha",left:"_1gzftthb"}},defaultVariants:{},compoundVariants:[]}),lc="_1gzftth1 _1yep5z6is _1yep5z6it _1yep5z6iu",pc="_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6k4 _1yep5z6k5 _1yep5z6k6 _1yep5z6d7",cc="_1gzftthd",dc="_1gzftthc",uc="var(--_1gzftth0)";function GD(r){return r.closest(".BaselineUI-Portal")||r.closest(".BaselineUI-Popover-Content")}function mc(r){return typeof r=="object"&&typeof r.left=="number"&&typeof r.top=="number"&&(typeof r.width=="number"||r.width===void 0)&&(typeof r.height=="number"||r.height===void 0)}var ca=wt.createContext({isSelected:false,ref:void 0}),He=({children:r,anchorRect:e})=>{let{state:t,overlayTriggerAria:o,triggerRef:a}=useContext(Xr);invariant(t,"PopoverTrigger must be used within a Popover");let{triggerProps:n}=o,i=useMemo(()=>({...n,isSelected:t.isOpen,ref:a}),[n,t.isOpen,a]);return invariant(!e&&r||e&&!r,"Either one of anchorRect or children has to be provided."),invariant(!e||mc(e),"If provided, the anchorRect prop must be an object with left and top number values, and optionally width and height."),jsx(ca.Provider,{value:i,children:e?jsx("div",{className:classNames(cc,"BaselineUI-PopoverTrigger-Hidden"),style:e,ref:a,tabIndex:-1},JSON.stringify(e)):r})};var da=({label:r,tooltip:e})=>({tooltipProps:useMemo(()=>{let o={size:"sm",variant:"inverse",text:r,includeArrow:false,placement:"bottom start",offset:4};if(typeof e=="object")return {...o,...e};if(e)return o},[r,e])});function ua({tooltip:r,"aria-label":e,"aria-labelledby":t},o){let[a,n]=useState(e||"");useEffect(()=>{if(t){let l=be(o.current).querySelector(`#${t}`);l&&n(l.textContent||"");}else e&&n(e);},[t,o,e]);let{tooltipProps:i}=da({label:a,tooltip:r});return {tooltipProps:i}}var ma=r=>{let e=wt.useRef(null),{ref:t,...o}=useContext(ca)||{},{buttonProps:a,isPressed:n}=useButton({...r,...o},e),{isFocusVisible:i,isFocused:s,focusProps:l}=useFocusRing(),{hoverProps:p,isHovered:c}=useHover({isDisabled:r.isDisabled});return {buttonProps:et(a,l,p),isPressed:n,ref:M(e,t||null),isFocusVisible:i,isFocused:s,isHovered:c,uiStateOptions:{isHovered:c,isFocused:s,isPressed:n,isDisabled:r.isDisabled,isFocusVisible:i}}},fa=(r,e)=>{let t=wt.useRef(null),{ref:o,...a}=useContext(ca)||{},{buttonProps:n,isPressed:i}=useToggleButton({...r,...a},e,t);(n.role==="radio"||n.role==="checkbox")&&(n["aria-pressed"]=void 0);let{isFocusVisible:s,isFocused:l,focusProps:p}=useFocusRing(),{hoverProps:c,isHovered:d}=useHover({isDisabled:r.isDisabled});return {buttonProps:et(n,p,c),isPressed:i,ref:M(t,o||null),isFocusVisible:s,isFocused:l,isHovered:d,uiStateOptions:{isHovered:d,isFocused:l,isPressed:i,isDisabled:r.isDisabled,isFocusVisible:s,isSelected:e.isSelected}}};var ya=x({defaultClassName:"oom8bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6dy _1yep5z6la",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:true},"oom8bsg"],[{variant:"secondary",isHovered:true},"oom8bsh"],[{variant:"tertiary",isHovered:true},"oom8bsi"],[{variant:"popover",isHovered:true},"oom8bsj"],[{variant:"ghost",isHovered:true},"oom8bsk"],[{variant:"success",isHovered:true},"oom8bsl"],[{variant:"warning",isHovered:true},"oom8bsm"],[{variant:"error",isHovered:true},"oom8bsn"],[{variant:"primary",isFocusVisible:true},"oom8bso"],[{variant:"tertiary",isFocusVisible:true},"oom8bsp"],[{variant:"success",isFocusVisible:true},"oom8bsq"],[{variant:"warning",isFocusVisible:true},"oom8bsr"],[{variant:"error",isFocusVisible:true},"oom8bss"]]}),Di=x({defaultClassName:"oom8bst _1yep5z6la",variantClassNames:{isDisabled:{true:"oom8bsu"},isFocusVisible:{true:"oom8bsv"},isHovered:{true:"_1yep5z6115"},variant:{primary:"_1yep5z611c",secondary:"_1yep5z6118",tertiary:"_1yep5z611d",ghost:"_1yep5z611d",popover:"_1yep5z6118",toolbar:"_1yep5z6118",success:"_1yep5z611b",warning:"_1yep5z611b",error:"_1yep5z611b"}},defaultVariants:{},compoundVariants:[[{variant:"tertiary",isHovered:true},"_1yep5z61nf"],[{variant:"ghost",isHovered:true},"_1yep5z61nh"],[{variant:"tertiary",isFocusVisible:true},"_1yep5z61nf"],[{variant:"secondary",isDisabled:true},"_1yep5z61nd"],[{variant:"tertiary",isDisabled:true},"_1yep5z61nd"],[{variant:"ghost",isDisabled:true},"_1yep5z61nd"],[{variant:"popover",isDisabled:true},"_1yep5z61nd"],[{variant:"toolbar",isDisabled:true},"_1yep5z61nd"]]});var D6={sm:16,md:20,lg:24},K=wt.forwardRef(({label:r,style:e,className:t,iconStart:o,iconEnd:a,variant:n="primary",elementType:i="button",isDisabled:s,size:l="sm","data-block-id":p,"data-block-class":c,...d},m)=>{let{buttonProps:u,isPressed:b,ref:y,isFocusVisible:f,isFocused:g,isHovered:v,uiStateOptions:h}=ma({...d,elementType:i,isDisabled:s}),_=D6[l],z=filterTruthyValues({"data-block-id":p,"data-block-class":c,"data-disabled":s,"data-focused":g,"data-focus-visible":f,"data-hovered":v,"data-pressed":b});return jsxs(i,{...mergeProps(u,z),className:classNames(ya({isDisabled:!!s,isFocusVisible:f,isHovered:v,variant:n,size:l}),"BaselineUI-ActionButton",typeof t=="function"?t(h):t),style:typeof e=="function"?e(h):e,ref:M(m,y),children:[!!o&&jsx(o,{size:_,className:Di({variant:n,isDisabled:s,isFocusVisible:f,isHovered:v})}),r,!!a&&jsx(a,{size:_,className:Di({variant:n,isDisabled:s,isFocusVisible:f,isHovered:v})}),n==="popover"&&jsx(CaretDownIcon,{size:8,className:pa})]})});K.displayName="ActionButton";var ba=wt.forwardRef(({className:r,style:e,node:t,"data-block-id":o,"data-block-class":a,...n},i)=>{let s=wt.useRef(null);wt.useEffect(()=>{let c=s.current;return c?.append(t),()=>{c?.contains(t)&&t.remove();}},[t]);let{pressProps:l,isPressed:p}=usePress(n);return jsx("div",{...l,className:r,style:e,"data-block-id":o,"data-block-class":a,"data-pressed":p,"data-testid":"dom-node-renderer",ref:M(i,s)})});ba.displayName="DomNodeRenderer";var hc="_14uvjig0 z9nup81",_c="_14uvjig7",zc="_14uvjig3",xc=x({defaultClassName:"_14uvjig4",variantClassNames:{isDisabled:{true:"_14uvjig5"},hasNumberInput:{false:"_14uvjig6"}},defaultVariants:{},compoundVariants:[]}),Cc=x({defaultClassName:"_14uvjigf _14uvjig1",variantClassNames:{active:{true:"_14uvjigg _14uvjig2"},isDisabled:{true:"_14uvjigh"},isReadOnly:{true:"_14uvjigi"},isFocusVisible:{true:"_14uvjigj _14uvjig2"},isHovered:{true:"_14uvjigk _14uvjig2"}},defaultVariants:{},compoundVariants:[]}),Pc="_14uvjige _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf",wc="_14uvjig8",kc=x({defaultClassName:"_14uvjig9 _14uvjig1",variantClassNames:{active:{true:"_14uvjig2"},isFocusVisible:{true:"_14uvjig2"},isDisabled:{true:"_14uvjigc"},isHovered:{true:"_14uvjig2"}},defaultVariants:{},compoundVariants:[]});var Zt=x({defaultClassName:"nrh1ehy",variantClassNames:{isDisabled:{true:"nrh1ehz"},hasError:{true:"nrh1eh10"},labelPosition:{start:"nrh1eh11",top:"nrh1eh12"}},defaultVariants:{},compoundVariants:[]}),ga=x({defaultClassName:"nrh1ehp",variantClassNames:{isDisabled:{true:"nrh1ehq"},labelPosition:{top:"nrh1ehr",start:"nrh1ehs"}},defaultVariants:{},compoundVariants:[]}),Xt=x({defaultClassName:"nrh1eht",variantClassNames:{validationState:{valid:"nrh1ehu",error:"nrh1ehv",warning:"nrh1ehw"},isReadOnly:{true:"nrh1ehx"}},defaultVariants:{},compoundVariants:[]}),Jt="nrh1eh3",ot=x({defaultClassName:"nrh1eh4",variantClassNames:{labelPosition:{top:"nrh1eh5",start:"nrh1eh6"},hasMessage:{true:"nrh1eh7"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:false},"nrh1eh8"]]}),at=x({defaultClassName:"nrh1eh0",variantClassNames:{labelPosition:{top:"z9nup81",start:"nrh1eh2 z9nup82"}},defaultVariants:{},compoundVariants:[]}),Qt=x({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:true,isFocused:false,validationState:"valid"},"nrh1ehj"],[{variant:"ghost",isFocused:false,isHovered:false,validationState:"valid"},"nrh1ehk"],[{isHovered:true,validationState:"valid",isDisabled:false,isReadOnly:false,isFocused:false,variant:"primary"},"nrh1ehl"],[{isHovered:true,validationState:"warning",isDisabled:false,isReadOnly:false,isFocused:false},"nrh1ehm"],[{isReadOnly:true,variant:"primary",isFocused:false},"nrh1ehn"],[{isReadOnly:true,isFocused:true},"nrh1eho"]]});function ge({description:r,errorMessageProps:e,descriptionProps:t,warningMessage:o,errorMessage:a,labelPosition:n,isDisabled:i}){return r?jsx("div",{...t,className:Zt({isDisabled:i,labelPosition:n}),"aria-disabled":i,children:r}):a?jsx("div",{...e,className:Zt({hasError:true,labelPosition:n}),"aria-disabled":i,children:a}):o?jsx("div",{className:Zt({isDisabled:i,labelPosition:n}),"aria-disabled":i,children:o}):null}var Ic=x({defaultClassName:"_1lnwne1 z9nup82",variantClassNames:{isHoveredOrFocused:{true:"_1lnwne2"},isInteractive:{false:"z9nup83"}},defaultVariants:{},compoundVariants:[[{isHoveredOrFocused:true,isInteractive:true},"_1lnwne4"]]}),Sc="_1lnwne0";var Rc=x({defaultClassName:"_1jwycy80",variantClassNames:{placement:{bottom:"_1jwycy81",left:"_1jwycy82",right:"_1jwycy83",top:"_1jwycy84"},variant:{default:"_1jwycy85",inverse:"_1jwycy86"}},defaultVariants:{},compoundVariants:[]}),$c=x({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:"_1yep5z6g9 _1yep5z6ez",inverse:"_1yep5z6d7 _1yep5z6g1 _1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});function va({placement:r}){let e=useMemo(()=>{switch(r){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:4}}},[r]);return {transitionProps:{initial:{opacity:0,transform:`translate3d(${e.x}px, ${e.y}px, 0) scale(0.98)`},animate:{opacity:1,transform:"translate3d(0, 0, 0) scale(1)"},transition:{ease:"easeOut"}}}}var Li=wt.forwardRef(({children:r,state:e,overlayProps:t,arrowProps:o,placement:a,variant:n,size:i,tooltipProps:s,includeArrow:l},p)=>{let{tooltipProps:c}=useTooltip({isOpen:e.isOpen},e),d=a==="center"?"bottom":a,{transitionProps:m}=va({placement:a});return jsxs(motion.span,{...mergeProps(t,m),ref:p,"data-placement":d,children:[l?jsx("div",{className:Rc({placement:d,variant:n}),...o}):null,jsx("div",{...mergeProps(c,s),className:$c({variant:n,size:i}),children:r})]})});Li.displayName="TooltipContent";var Ai=wt.createContext(void 0),ha=({portalContainer:r,children:e})=>jsx(Ai.Provider,{value:r,children:e});ha.displayName="PortalContainerProvider";var _a="var(--lz9qs1)",Mc="var(--lz9qs0)";function Nc({ref:r,onIntersect:e,isDisabled:t,threshold:o,rootMargin:a,root:n}){let i=wt.useRef(null);useEffect(()=>{if(t){i.current?.disconnect(),i.current=null;return}i.current=new IntersectionObserver(([s])=>{e(s);},{root:n?.current,rootMargin:a,threshold:o});},[e,t,n,a,o]),useEffect(()=>{let{current:s}=i;return r.current&&s?.observe(r.current),()=>s?.disconnect()},[r]);}function Lc({ref:r,onResize:e,isDisabled:t}){let o=wt.useRef(null),[a,n]=wt.useState();return wt.useEffect(()=>{if(t){o.current?.disconnect(),o.current=null;return}o.current=new ResizeObserver(([i])=>{n(i.contentRect),e?.(i);});},[e,t,n]),wt.useEffect(()=>{let{current:i}=o;return r.current&&i?.observe(r.current),()=>i?.disconnect()},[r]),{size:a}}function er({src:r,alt:e}){let[t,o]=useState(false),[a,n]=useState(false),[i,s]=useState(false),l=()=>{o(true),s(false);},p=()=>{n(true),s(false);};return useEffect(()=>{if(!r)return;s(true);let c=new Image;return c.src=r,c.addEventListener("load",l),c.addEventListener("error",p),()=>{c.removeEventListener("load",l),c.removeEventListener("error",p);}},[r]),{isLoaded:t,hasError:a,isLoading:i,imgProps:{src:t?r:void 0,alt:e}}}function xa(){let r=useRef(true);return useEffect(()=>{r.current=false;},[]),r.current}var Ac="SET_STATE",Ca="UNDO",Pa="REDO",Z6=(r,e)=>{let{past:t,present:o,future:a}=r;switch(e.type){case Ac:return {past:[...t,o],present:e.data,future:[]};case Ca:return {past:t.slice(0,t?.length-1),present:t[t?.length-1],future:[o,...a]};case Pa:return {past:[...t,o],present:a[0],future:a.slice(1)};default:throw new Error("Invalid action type")}},Bc=(r={},{isDisabled:e,onAction:t})=>{let o=xa(),[a,n]=useReducer(Z6,{past:[],present:r,future:[]}),{past:i,present:s,future:l}=a,p=y=>{n({type:Ac,data:y});},c=useRef(),d=()=>{c.current=Ca,n({type:Ca});},m=()=>{c.current=Pa,n({type:Pa});},u=!!i?.length,b=!!l?.length;return useGranularEffect(()=>{(c.current===Ca||c.current===Pa)&&(t?.(s,c.current),c.current=void 0);},[s],[t,o]),{state:s,push:e?()=>{}:p,undo:e?()=>{}:d,redo:e?()=>{}:m,pastStates:i,futureStates:l,canUndo:u,canRedo:b}};var Oi=wt.createContext({messages:{},shouldLogMissingMessages:true,hasMissingErrorLoggedFor:{current:new Set},setLang:()=>{}}),jc=({children:r,messages:e={},shouldLogMissingMessages:t=true,...o})=>{let a=useRef(new Set),[n,i]=useState(o.locale||"");useEffect(()=>{a.current.clear();},[n,o.locale]);let s=wt.useMemo(()=>({messages:e,shouldLogMissingMessages:t,hasMissingErrorLoggedFor:a,setLang:i}),[e,t,i]);return jsx(I18nProvider,{...o,children:jsx(Oi.Provider,{value:s,children:r})})};jc.displayName="I18nProvider";function A(r){let{messages:e,shouldLogMissingMessages:t,hasMissingErrorLoggedFor:o,setLang:a}=useContext(Oi);useEffect(()=>{!r&&r0(e)&&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.");},[r,e]);let n=useMemo(()=>r?cleanKeyFromGlobImport(r):e,[r,e]),i=useMessageFormatter(n),s=useLocale();useEffect(()=>{a(s.locale);},[s.locale,a]);let l=useCallback(c=>{t&&!o.current.has(c)&&(console.log(`BUI \u{1F30D}: Translation not found for key: \`${c}\` for locale: \`${s.locale}\`. The default message, i.e. \`${c}\`, will be used instead.`),o.current.add(c));},[o,s.locale,t]),p=useCallback((c,d)=>{if(typeof c=="object")try{return i(c.id,d)}catch{return l(c.id),c.defaultMessage||c.id}else try{return i(c,d)}catch{return l(c),c}},[i,l]);return useMemo(()=>({formatMessage:p,locale:s}),[p,s])}var G=r=>r;function YE(r,e,t){let o=wt.useRef(null);return wt.useEffect(()=>{if(r)return o.current=new MutationObserver(t),o.current.observe(r,e),()=>{o.current&&o.current.disconnect();}},[r,e,t]),o.current}function Gc(r,e){let[t,o]=useState(()=>{try{let n=window.localStorage.getItem(r);return n?JSON.parse(n):e}catch(n){return console.log(n),e}});return [t,n=>{try{let i=n instanceof Function?n(t):n;o(i),window.localStorage.setItem(r,JSON.stringify(i));}catch(i){console.log(i);}}]}function rN({ref:r,onSelectionChange:e,onSelectionEnd:t,isDisabled:o}){let a=wt.useRef(null);usePress({ref:r,isDisabled:o,onPressEnd(){let i=re(r.current).getSelection();i&&r.current?.contains(i.anchorNode)&&t?.(i);},onPressStart(){let n=re(r.current);a.current=n.getSelection(),a.current&&a.current.removeAllRanges();}}),useEffect(()=>{let n=r.current;if(!n||o)return;function i(){let p=re(n).getSelection();p&&r.current?.contains(p.anchorNode)&&e(p);}let s=be(n);return s.addEventListener("selectionchange",i),()=>{s.removeEventListener("selectionchange",i);}},[r,e,o]);}var wa=wt.createContext({breakpoints:breakpoints}),u0=({children:r,breakpoints:e=breakpoints})=>{let t=useMemo(()=>({breakpoints:e}),[e]);return jsx(wa.Provider,{value:t,children:r})};function Ne(r){let{breakpoints:e=breakpoints}=useContext(wa),t=useMemo(()=>({tablet:`screen and (min-width: ${e.tablet}px)`,desktop:`screen and (min-width: ${e.desktop}px)`}),[e]),o=useCallback(()=>{let i=re(r??typeof window>"u"?void 0:r),s=i.matchMedia(t.tablet);return i.matchMedia(t.desktop).matches?"desktop":s.matches?"tablet":"mobile"},[r,t]),[a,n]=wt.useState(o);return Te(()=>{let i=re(r),s=()=>{n(o());};return i.addEventListener("resize",s),s(),()=>{i.removeEventListener("resize",s);}},[r,o]),a}var C0=typeof window<"u";function Fi(){return C0?document.body:null}var It=wt.createContext({container:null,portalContainer:null,shouldContainOverlays:false,isContainerPositioned:false}),P0=({children:r,container:e=Fi(),portalContainer:t,shouldContainOverlays:o="auto"})=>{let a=Ne(),n=useMemo(()=>e===Fi()||o==="never"?false:o==="always"?true:a!=="mobile",[o,a,e]),[i,s]=useState(false),l=xa();useEffect(()=>{if(!e||l)return;let d=re(e).getComputedStyle(e),m=!!d.position&&d.position!=="static";s(m);let u=e.getBoundingClientRect();(u.width===0||u.height===0)&&console.error("FrameProvider: container does not have a width or height. Please ensure that the container is visible and has a width and height.");function b({width:f,height:g}){e&&setElementVars(e,{[Mc]:f,[_a]:g});}let y=new ResizeObserver(f=>{for(let g of f)b({width:`${g.contentRect.width}px`,height:`${g.contentRect.height}px`});});return n&&(b({width:`${u.width}px`,height:`${u.height}px`}),y.observe(e)),e.dataset.shouldContainOverlays=n.toString(),()=>{y.disconnect(),b({width:"",height:""}),e.dataset.shouldContainOverlays="";}},[e,l,n]);let p=useMemo(()=>({container:e,portalContainer:t||e||Fi(),shouldContainOverlays:n,isContainerPositioned:i}),[e,t,n,i]);return jsx(It.Provider,{value:p,children:jsx(ha,{portalContainer:p.portalContainer||void 0,children:r})})};function ve(r){let e=useContext(Ai),{portalContainer:t}=useContext(It);return r||e||t||void 0}var Xc=x({defaultClassName:"z9nup84",variantClassNames:{size:{xs:"z9nup85",sm:"z9nup86"}},defaultVariants:{},compoundVariants:[]});var Jc="z9nup80",tr="z9nup83",Qc="z9nup87";function ji(r=typeof window>"u"?void 0:window){let[e,t]=useState("light"),[o,a]=useState(false),[n,i]=useState(false),[s,l]=useState(false);return useEffect(()=>{if(!r)return;let p=r.matchMedia("(prefers-color-scheme: dark)"),c=d=>{t(d.matches?"dark":"light");};return p.matches&&t("dark"),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[r]),useEffect(()=>{if(!r)return;let p=r.matchMedia("(prefers-contrast: more)"),c=d=>{a(d.matches);};return a(p.matches),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[r]),useEffect(()=>{if(!r)return;let p=r.matchMedia("(prefers-reduced-motion: reduce)"),c=d=>{i(d.matches);};return p.matches&&i(true),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[r]),useEffect(()=>{if(!r)return;let p=r.matchMedia("(prefers-reduced-transparency: reduce)"),c=d=>{l(d.matches);};return p.matches&&l(true),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[r]),{colorScheme:e,highContrast:o,reducedMotion:n,transparency:s}}var rr=createContext({theme:lightTheme,setTheme:()=>{},shouldHandleVirtualKeyboard:true});var ed="var(--hj25q10)";var Sa={LIGHT:{name:"light",theme:lightTheme},DARK:{name:"dark",theme:darkTheme}},Ra=wt.forwardRef(({theme:r="system",children:e,setTheme:t,onThemeChange:o,className:a,style:n,UNSAFE_domProps:i,"data-block-id":s,"data-block-class":l,reducedMotion:p="user",shouldHandleVirtualKeyboard:c=true},d)=>{let{direction:m}=useLocale(),{colorScheme:u,reducedMotion:b,highContrast:y,transparency:f}=ji(),{name:g,theme:v}=useMemo(()=>{switch(r){case "system":return u==="light"?Sa.LIGHT:Sa.DARK;case "light":return Sa.LIGHT;case "dark":return Sa.DARK;default:return {name:"custom",theme:r}}},[u,r]),h=Ne(),_={"data-theme":g,"data-block-id":s,"data-block-class":l,"data-reduced-motion":p==="user"?b:p==="always","data-high-contrast":y,"data-transparency":f,"data-device":h},z=useMemo(()=>({theme:v,setTheme:P=>{t?.(P),o?.(P);},shouldHandleVirtualKeyboard:c}),[v,t,o,c]);return useEffect(()=>{t&&console.warn("ThemeProvider: The `setTheme` prop is deprecated and will be removed in a future version of Baseline UI. Use the `onThemeChange` prop instead.");},[t]),jsx(rr.Provider,{value:z,children:jsx(MotionConfig,{reducedMotion:p,children:jsx("div",{...mergeProps(i,_),className:classNames(Jc,"BaselineUI-ThemeProvider",a),style:{...assignInlineVars(themeVars,v),...assignInlineVars({[ed]:m==="rtl"?"-1":"1"}),...n},ref:d,children:e})})})});Ra.displayName="ThemeProvider";function iL(){MotionGlobalConfig.skipAnimations=true;}function sL(){MotionGlobalConfig.skipAnimations=false;}var he=wt.forwardRef(({className:r,style:e,children:t,"data-block-id":o,"data-block-class":a,portalContainer:n,...i},s)=>{let{theme:l}=useContext(rr),p=ve();return jsx(Overlay,{...i,portalContainer:n??p,children:jsx(Ra,{ref:s,theme:l,style:e,className:classNames("BaselineUI-Portal",r),"data-block-id":o,"data-block-class":a,children:t})})});he.displayName="Portal";var ie=wt.forwardRef(({children:r,placement:e="bottom",delay:t=1e3,closeDelay:o=500,variant:a="default",size:n="md",includeArrow:i=true,portalContainer:s,className:l,style:p,"data-block-id":c,"data-block-class":d,...m},u)=>{let b=wt.useRef(null),y=wt.useRef(null),f=!m.text||m.isDisabled,g=useTooltipTriggerState({...m,delay:t,closeDelay:o,isDisabled:f}),{triggerProps:v,tooltipProps:h}=useTooltipTrigger({...m,isDisabled:f,delay:t,closeDelay:o},g,b),_=ve(s),{overlayProps:z,arrowProps:P,placement:w,updatePosition:C}=useOverlayPosition({arrowSize:i?13:0,targetRef:b,arrowBoundaryOffset:i?8:0,offset:i?12:2,overlayRef:y,placement:e,isOpen:g.isOpen,...m});return Nc({ref:y,threshold:1,onIntersect:C,isDisabled:!g.isOpen}),Lc({ref:b,onResize:C,isDisabled:!g.isOpen}),jsxs(FocusableProvider,{...v,ref:b,children:[r,g.isOpen?jsx(he,{disableFocusManagement:true,portalContainer:_,className:l,style:p,"data-block-id":c,"data-block-class":d,children:jsx(Li,{ref:M(u,y),state:g,arrowProps:P,overlayProps:z,placement:w,tooltipProps:h,variant:a,size:n,includeArrow:i,children:m.text})}):null]})});ie.displayName="Tooltip";var $a=wt.forwardRef(({elementType:r,children:e,...t},o)=>{let a=oe(o),{focusableProps:n}=useFocusable(t,a);return jsx(r??"div",{ref:a,...n,children:e})});$a.displayName="Focusable";var Q0={xxs:8,xs:12,sm:16,md:20,lg:24},L=wt.forwardRef((r,e)=>{let t=oe(e),{tooltipProps:o}=ua(r,t);return o?jsx(ie,{...o,children:jsx(Ui,{...r,ref:t})}):jsx(Ui,{...r,ref:t})});L.displayName="ActionIconButton";var Ui=wt.forwardRef(({className:r,style:e,icon:t,size:o="md",variant:a="primary",UNSAFE_NON_INTERACTIVE:n,elementType:i=n?"div":"button",...s},l)=>{let p=s["aria-label"],c=s["aria-labelledby"];useEffect(()=>{!p&&!c&&console.warn("An `ActionIconButton` requires an aria-label or aria-labelledby prop.");},[p,c]);let{buttonProps:d,isPressed:m,ref:u,isFocusVisible:b,isFocused:y,isHovered:f,uiStateOptions:g}=ma({...s,elementType:i}),v=filterTruthyValues({"data-block-id":s["data-block-id"],"data-block-class":s["data-block-class"],"data-focused":y,"data-focus-visible":b,"data-disabled":s.isDisabled,"data-hovered":f,"data-pressed":m});return jsxs(i,{...mergeProps(d,v),className:classNames(ac({variant:a,size:o,isDisabled:!!s.isDisabled,isFocusVisible:b,isHovered:f}),"BaselineUI-ActionIconButton",typeof r=="function"?r(g):r),ref:M(l,u),style:typeof e=="function"?e(g):e,...n&&{tabIndex:void 0,role:void 0,"aria-label":void 0,"aria-labelledby":void 0,"aria-disabled":void 0},children:[jsx(t,{role:"presentation",size:Q0[o]}),a==="popover"&&jsx(CaretDownIcon,{size:8,className:pa})]})});Ui.displayName="ActionIconButtonCore";var Ve=wt.forwardRef(({className:r,style:e,labelPosition:t="top",variant:o="primary",showStepper:a=true,...n},i)=>{let s=wt.useRef(null),{locale:l}=useLocale(),p=useNumberFieldState({...n,locale:l}),{hoverProps:c,isHovered:d}=useHover({isDisabled:n.isDisabled}),{focusProps:m,isFocusVisible:u,isFocused:b}=useFocusRing(),{labelProps:y,decrementButtonProps:f,inputProps:g,incrementButtonProps:v,groupProps:h,descriptionProps:_,errorMessageProps:z}=useNumberField(n,p,s),P=useMemo(()=>n.isReadOnly?ReadOnlyIcon:n.isInvalid?ErrorCircleFilledIcon:null,[n.isInvalid,n.isReadOnly]),w=ge({description:n.description,errorMessageProps:z,descriptionProps:_,errorMessage:n.errorMessage,labelPosition:t,isDisabled:n.isDisabled}),C=filterTruthyValues({"data-disabled":n.isDisabled,"data-readonly":n.isReadOnly,"data-hovered":d,"data-focused":b,"data-focus-visible":u,"data-invalid":n.isInvalid,"data-block-id":n["data-block-id"],"data-block-class":n["data-block-class"]});return jsxs("div",{style:e,className:classNames(at({labelPosition:t}),"BaselineUI-NumberInput",r),...C,ref:i,children:[n.label?jsxs("div",{className:ot({labelPosition:t,hasMessage:!!w}),children:[jsx("label",{...y,className:Jt,children:n.label}),t==="start"&&w]}):null,jsxs("div",{className:classNames({[tr]:n.isDisabled}),children:[jsxs("div",{...mergeProps(h,c),className:classNames(Qt({isHovered:d,isDisabled:!!n.isDisabled,isReadOnly:!!n.isReadOnly,validationState:n.isInvalid?"error":"valid",isFocused:b,variant:o}),{[Sc]:t==="start"},"BaselineUI-NumberInput-Container"),children:[jsx("input",{...mergeProps(g,m),ref:s,className:classNames("BaselineUI-NumberInput-Input",ga({isDisabled:n.isDisabled,labelPosition:t}))}),P?jsx(P,{className:Xt({validationState:"error",isReadOnly:n.isReadOnly}),size:16}):null,a?jsxs("div",{className:Ic({isHoveredOrFocused:d||b,isInteractive:!n.isReadOnly&&!n.isDisabled}),children:[jsx(L,{variant:"secondary",size:"xxs",icon:MinusIcon,...f,className:"BaselineUI-NumberInput-DecrementButton"}),jsx(U,{style:{height:16},orientation:"vertical"}),jsx(L,{variant:"secondary",size:"xxs",icon:PlusIcon,...v,className:"BaselineUI-NumberInput-DecrementButton"})]}):null]}),t==="top"&&w]})]})});Ve.displayName="NumberInput";var nr=wt.forwardRef(({className:r,style:e,onChange:t,onChangeEnd:o,numberFormatOptions:a,isDisabled:n,step:i,minValue:s,maxValue:l,value:p,"aria-label":c,"aria-labelledby":d,"aria-details":m,"aria-describedby":u,"data-block-id":b,"data-block-class":y,defaultValue:f,isReadOnly:g,label:v,id:h,includeNumberInput:_},z)=>{let P=wt.useRef(null),w={onChange:t===void 0?void 0:S=>{t(S[0]);},isDisabled:n||g,step:i,minValue:s,maxValue:l,onChangeEnd:o===void 0?void 0:S=>{o(S[0]);},value:p===void 0?void 0:[p],defaultValue:f===void 0?void 0:[f],"aria-label":c,"aria-labelledby":d,"aria-details":m,"aria-describedby":u,id:h,label:v},C=useNumberFormatter(a),k=useSliderState({...w,numberFormatter:C}),{trackProps:$,groupProps:R,labelProps:T}=useSlider(w,k,P),I=jsx(Ve,{variant:"ghost",showStepper:false,"aria-label":c,"aria-labelledby":T.id,value:k.getThumbValue(0),formatOptions:a,onChange:S=>{k.setThumbValue(0,S);},style:{width:55,textAlign:"right",flexShrink:0}});return jsxs("div",{...R,style:e,"data-block-id":b,"data-block-class":y,className:classNames(hc,"BaselineUI-Slider",r),children:[v?jsxs("div",{className:zc,children:[jsx("label",{...T,className:classNames(xc({isDisabled:n,hasNumberInput:!!_}),"BaselineUI-Slider-Label"),children:v}),_?I:null]}):null,jsxs("div",{className:_c,children:[jsx("div",{...$,className:classNames(wc,"BaselineUI-Slider-Track"),ref:M(P,z),"data-testid":"track",children:jsx(__,{state:k,trackRef:P,isDisabled:n,isReadOnly:g})}),_&&!v?I:null]})]})});nr.displayName="Slider";function __({state:r,trackRef:e,isDisabled:t,isReadOnly:o}){let a=wt.useRef(null),{thumbProps:n,inputProps:i,isDragging:s}=useSliderThumb({trackRef:e,inputRef:a},r),{focusProps:l,isFocused:p,isFocusVisible:c}=useFocusRing(),{hoverProps:d,isHovered:m}=useHover({isDisabled:t}),u=filterTruthyValues({"data-disabled":t,"data-readonly":o,"data-hovered":m,"data-focus-visible":c,"data-dragging":s,"data-focused":p});return jsxs(Fragment,{children:[jsx("div",{className:classNames(kc({isDisabled:t,isFocusVisible:c,active:s,isHovered:m}),"BaselineUI-Slider-TrackHighlight"),style:{width:n.style?.left},"data-testid":"track-highlight"}),jsxs("div",{...mergeProps(n,d,u),className:classNames(Pc,"BaselineUI-Slider-ThumbHandle"),"data-testid":"thumb",children:[jsx("div",{className:classNames(Cc({isDisabled:t,isFocusVisible:c,active:s,isReadOnly:o,isHovered:m}),"BaselineUI-Slider-Thumb")}),jsx(VisuallyHidden,{children:jsx("input",{ref:a,...mergeProps(i,l)})})]})]})}var cd=x({defaultClassName:"_1tkzayn0 _1yep5z6dy",variantClassNames:{size:{sm:"_1tkzayn1",md:"_1tkzayn2",lg:"_1tkzayn3"},type:{subtitle:"_1yep5z610x",title:"_1yep5z610x",label:"_1yep5z610y",value:"_1yep5z610y",helper:"_1yep5z610z",body:"_1yep5z610x"}},defaultVariants:{},compoundVariants:[[{type:"title",size:"sm"},"_1yep5z61lj"],[{type:"title",size:"md"},"_1yep5z61lm"],[{type:"title",size:"lg"},"_1yep5z61lp"],[{type:"body",size:"sm"},"_1yep5z61m9"],[{type:"body",size:"md"},"_1yep5z61mc"],[{type:"body",size:"lg"},"_1yep5z61mc"],[{type:"subtitle",size:"sm"},"_1yep5z61m5"],[{type:"subtitle",size:"md"},"_1yep5z61m8"],[{type:"subtitle",size:"lg"},"_1yep5z61m8"],[{type:"label",size:"md"},"_1yep5z61m7"],[{type:"label",size:"lg"},"_1yep5z61m7"],[{type:"value",size:"md"},"_1yep5z61m7"],[{type:"value",size:"lg"},"_1yep5z61m7"],[{type:"helper",size:"sm"},"_1yep5z61m1"]]});var Q=wt.forwardRef(({elementType:r="span",type:e="title",children:t,size:o="md",...a},n)=>jsx(r,{...a,className:classNames(cd({size:o,type:e}),"BaselineUI-Text",a.className),ref:n,children:t}));Q.displayName="Text";var dd=x({defaultClassName:"siobe20 _1yep5z6ao _1yep5z6ap _1yep5z6aq _1yep5z6bc _1yep5z6bd _1yep5z6be _1yep5z6d7 _1yep5z6m1 _1yep5z6lz _1yep5z6h4 _1yep5z6lq _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6",variantClassNames:{background:{subtle:"_1yep5z6124",medium:"_1yep5z6125"},isFocusVisible:{true:"_1yep5z617u _1yep5z617w _1yep5z617x _1yep5z6140"}},defaultVariants:{},compoundVariants:[]}),ud="siobe24";var Da=wt.forwardRef(({className:r,style:e,children:t,background:o="medium",title:a,action:n,"data-block-id":i,"data-block-class":s,onCloseRequest:l,contentStyle:p,contentClassName:c,...d},m)=>{let{formatMessage:u}=A(),b=wt.useRef(null),{dialogProps:y,titleProps:f}=useDialog(d,b),{focusProps:g,isFocusVisible:v}=useFocusRing();return jsxs("div",{...mergeProps(y,g),className:classNames(dd({background:o,isFocusVisible:v}),"BaselineUI-Drawer",r),"data-block-id":i,"data-block-class":s,style:e,ref:M(m,b),children:[jsxs(D,{paddingLeft:"lg",paddingRight:"sm",backgroundColor:"background.primary.subtle",display:"flex",justifyContent:"space-between",alignItems:"center",gap:"lg",className:ud,children:[jsx(Q,{type:"title",size:"sm",...f,className:Qc,children:a}),jsxs(D,{children:[n?jsx(L,{...n,variant:"secondary"}):null,jsx(L,{variant:"secondary",size:"md",icon:XIcon,onPress:l,"aria-label":u(R_.close)})]})]}),jsx(U,{variant:o==="subtle"?"primary":"secondary"}),jsx(D,{display:"flex",flexDirection:"column",flex:1,style:{overflow:"auto",...p},className:classNames(c,"BaselineUI-Drawer-Content"),children:t})]})});Da.displayName="Drawer";var R_=G({close:{id:"close",defaultMessage:"Close"}});var yd="aml2vl8 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6ij _1yep5z6ik _1yep5z6il",bd="_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",gd=x({defaultClassName:"aml2vl3 _1yep5z6lg _1yep5z6lh _1yep5z6lj _1yep5z6li _1yep5z6is _1yep5z6it _1yep5z6iu",variantClassNames:{enableDrawer:{false:"_1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf",true:"aml2vl5"},shouldContainOverlays:{true:"aml2vl6",false:"aml2vl7"}},defaultVariants:{},compoundVariants:[]}),vd=x({defaultClassName:"aml2vl0 _1yep5z6lg _1yep5z6lh _1yep5z6lj _1yep5z6li _1yep5z6gb",variantClassNames:{shouldContainOverlays:{true:"aml2vl1",false:"aml2vl2"}},defaultVariants:{},compoundVariants:[]});var St=wt.createContext({state:null,triggerProps:{},overlayProps:{}}),Le=({children:r,...e})=>{let t=useOverlayTriggerState(e),{triggerProps:o,overlayProps:a}=useOverlayTrigger({type:"dialog"},t),n=useMemo(()=>({state:t,triggerProps:o,overlayProps:a}),[t,o,a]);return jsx(St.Provider,{value:n,children:r})};Le.displayName="Modal";yi(Wi());var Pd=false,wd=r=>{Pd||V_(r);},V_=r=>{if(!r)throw new Error('No adapter provided when calling "setAdapter"');Pd=true;};var ee;(function(r){r.Attribute="attribute",r.Pseudo="pseudo",r.PseudoElement="pseudo-element",r.Tag="tag",r.Universal="universal",r.Adjacent="adjacent",r.Child="child",r.Descendant="descendant",r.Parent="parent",r.Sibling="sibling",r.ColumnCombinator="column-combinator";})(ee||(ee={}));var Pe;(function(r){r.Any="any",r.Element="element",r.End="end",r.Equals="equals",r.Exists="exists",r.Hyphen="hyphen",r.Not="not",r.Start="start";})(Pe||(Pe={}));new Map([[126,Pe.Element],[94,Pe.Start],[36,Pe.End],[42,Pe.Any],[33,Pe.Not],[124,Pe.Hyphen]]);function $d(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(r);e&&(o=o.filter(function(a){return Object.getOwnPropertyDescriptor(r,a).enumerable})),t.push.apply(t,o);}return t}function Td(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?$d(Object(t),true).forEach(function(o){Y_(r,o,t[o]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):$d(Object(t)).forEach(function(o){Object.defineProperty(r,o,Object.getOwnPropertyDescriptor(t,o));});}return r}function Y_(r,e,t){return e=Z_(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:true,configurable:true,writable:true}):r[e]=t,r}function Z_(r){var e=X_(r,"string");return typeof e=="symbol"?e:String(e)}function X_(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var o=t.call(r,e);if(typeof o!="object")return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return (e==="string"?String:Number)(r)}Dd({});function Dd(r){return e.withOptions=t=>Dd(Td(Td({},r),t)),e;function e(t,...o){let a=typeof t=="string"?[t]:t.raw,{escapeSpecialCharacters:n=Array.isArray(t)}=r,i="";for(let p=0;p<a.length;p++){let c=a[p];n&&(c=c.replace(/\\\n[ \t]*/g,"").replace(/\\`/g,"`").replace(/\\\$/g,"$").replace(/\\\{/g,"{")),i+=c,p<o.length&&(i+=o[p]);}let s=i.split(`
11
- `),l=null;for(let p of s){let c=p.match(/^(\s+)\S+/);if(c){let d=c[1].length;l?l=Math.min(l,d):l=d;}}if(l!==null){let p=l;i=s.map(c=>c[0]===" "||c[0]===" "?c.slice(p):c).join(`
12
- `);}return i=i.trim(),n&&(i=i.replace(/\\n/g,`
13
- `)),i}}var jd={":-moz-any-link":true,":-moz-full-screen":true,":-moz-placeholder":true,":-moz-read-only":true,":-moz-read-write":true,":-ms-fullscreen":true,":-ms-input-placeholder":true,":-webkit-any-link":true,":-webkit-full-screen":true,"::-moz-color-swatch":true,"::-moz-list-bullet":true,"::-moz-list-number":true,"::-moz-page-sequence":true,"::-moz-page":true,"::-moz-placeholder":true,"::-moz-progress-bar":true,"::-moz-range-progress":true,"::-moz-range-thumb":true,"::-moz-range-track":true,"::-moz-scrolled-page-sequence":true,"::-moz-selection":true,"::-ms-backdrop":true,"::-ms-browse":true,"::-ms-check":true,"::-ms-clear":true,"::-ms-fill-lower":true,"::-ms-fill-upper":true,"::-ms-fill":true,"::-ms-reveal":true,"::-ms-thumb":true,"::-ms-ticks-after":true,"::-ms-ticks-before":true,"::-ms-tooltip":true,"::-ms-track":true,"::-ms-value":true,"::-webkit-backdrop":true,"::-webkit-calendar-picker-indicator":true,"::-webkit-inner-spin-button":true,"::-webkit-input-placeholder":true,"::-webkit-meter-bar":true,"::-webkit-meter-even-less-good-value":true,"::-webkit-meter-inner-element":true,"::-webkit-meter-optimum-value":true,"::-webkit-meter-suboptimum-value":true,"::-webkit-outer-spin-button":true,"::-webkit-progress-bar":true,"::-webkit-progress-inner-element":true,"::-webkit-progress-inner-value":true,"::-webkit-progress-value":true,"::-webkit-resizer":true,"::-webkit-scrollbar-button":true,"::-webkit-scrollbar-corner":true,"::-webkit-scrollbar-thumb":true,"::-webkit-scrollbar-track-piece":true,"::-webkit-scrollbar-track":true,"::-webkit-scrollbar":true,"::-webkit-search-cancel-button":true,"::-webkit-search-results-button":true,"::-webkit-slider-runnable-track":true,"::-webkit-slider-thumb":true,"::after":true,"::backdrop":true,"::before":true,"::cue":true,"::file-selector-button":true,"::first-letter":true,"::first-line":true,"::grammar-error":true,"::marker":true,"::placeholder":true,"::selection":true,"::spelling-error":true,"::target-text":true,"::view-transition-group":true,"::view-transition-image-pair":true,"::view-transition-new":true,"::view-transition-old":true,"::view-transition":true,":active":true,":after":true,":any-link":true,":before":true,":blank":true,":checked":true,":default":true,":defined":true,":disabled":true,":empty":true,":enabled":true,":first-child":true,":first-letter":true,":first-line":true,":first-of-type":true,":first":true,":focus-visible":true,":focus-within":true,":focus":true,":fullscreen":true,":hover":true,":in-range":true,":indeterminate":true,":invalid":true,":last-child":true,":last-of-type":true,":left":true,":link":true,":only-child":true,":only-of-type":true,":optional":true,":out-of-range":true,":placeholder-shown":true,":read-only":true,":read-write":true,":required":true,":right":true,":root":true,":scope":true,":target":true,":valid":true,":visited":true},Cz=Object.keys(jd);[...Cz,"@layer","@media","@supports","@container","selectors"];var pr=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,qd=new Set,as=typeof process=="object"&&process?process:{},Gd=(r,e,t,o)=>{typeof as.emitWarning=="function"?as.emitWarning(r,e,t,o):console.error(`[${t}] ${e}: ${r}`);},Oa=globalThis.AbortController,Ud=globalThis.AbortSignal;if(typeof Oa>"u"){Ud=class{onabort;_onabort=[];reason;aborted=false;addEventListener(o,a){this._onabort.push(a);}},Oa=class{constructor(){e();}signal=new Ud;abort(o){if(!this.signal.aborted){this.signal.reason=o,this.signal.aborted=true;for(let a of this.signal._onabort)a(o);this.signal.onabort?.(o);}}};let r=as.env?.LRU_CACHE_IGNORE_AC_WARNING!=="1",e=()=>{r&&(r=false,Gd("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",e));};}var Dz=r=>!qd.has(r),st=r=>r&&r===Math.floor(r)&&r>0&&isFinite(r),Kd=r=>st(r)?r<=Math.pow(2,8)?Uint8Array:r<=Math.pow(2,16)?Uint16Array:r<=Math.pow(2,32)?Uint32Array:r<=Number.MAX_SAFE_INTEGER?cr:null:null,cr=class extends Array{constructor(e){super(e),this.fill(0);}},ns=class r{heap;length;static#l=false;static create(e){let t=Kd(e);if(!t)return [];r.#l=true;let o=new r(e,t);return r.#l=false,o}constructor(e,t){if(!r.#l)throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new t(e),this.length=0;}push(e){this.heap[this.length++]=e;}pop(){return this.heap[--this.length]}},Fa=class r{#l;#d;#y;#b;#$;#T;ttl;ttlResolution;ttlAutopurge;updateAgeOnGet;updateAgeOnHas;allowStale;noDisposeOnSet;noUpdateTTL;maxEntrySize;sizeCalculation;noDeleteOnFetchRejection;noDeleteOnStaleGet;allowStaleOnFetchAbort;allowStaleOnFetchRejection;ignoreFetchAbort;#a;#g;#o;#r;#e;#p;#u;#s;#n;#v;#i;#h;#_;#m;#z;#k;#c;static unsafeExposeInternals(e){return {starts:e.#_,ttls:e.#m,sizes:e.#h,keyMap:e.#o,keyList:e.#r,valList:e.#e,next:e.#p,prev:e.#u,get head(){return e.#s},get tail(){return e.#n},free:e.#v,isBackgroundFetch:t=>e.#t(t),backgroundFetch:(t,o,a,n)=>e.#E(t,o,a,n),moveToTail:t=>e.#R(t),indexes:t=>e.#x(t),rindexes:t=>e.#C(t),isStale:t=>e.#f(t)}}get max(){return this.#l}get maxSize(){return this.#d}get calculatedSize(){return this.#g}get size(){return this.#a}get fetchMethod(){return this.#$}get memoMethod(){return this.#T}get dispose(){return this.#y}get disposeAfter(){return this.#b}constructor(e){let{max:t=0,ttl:o,ttlResolution:a=1,ttlAutopurge:n,updateAgeOnGet:i,updateAgeOnHas:s,allowStale:l,dispose:p,disposeAfter:c,noDisposeOnSet:d,noUpdateTTL:m,maxSize:u=0,maxEntrySize:b=0,sizeCalculation:y,fetchMethod:f,memoMethod:g,noDeleteOnFetchRejection:v,noDeleteOnStaleGet:h,allowStaleOnFetchRejection:_,allowStaleOnFetchAbort:z,ignoreFetchAbort:P}=e;if(t!==0&&!st(t))throw new TypeError("max option must be a nonnegative integer");let w=t?Kd(t):Array;if(!w)throw new Error("invalid max value: "+t);if(this.#l=t,this.#d=u,this.maxEntrySize=b||this.#d,this.sizeCalculation=y,this.sizeCalculation){if(!this.#d&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(g!==void 0&&typeof g!="function")throw new TypeError("memoMethod must be a function if defined");if(this.#T=g,f!==void 0&&typeof f!="function")throw new TypeError("fetchMethod must be a function if specified");if(this.#$=f,this.#k=!!f,this.#o=new Map,this.#r=new Array(t).fill(void 0),this.#e=new Array(t).fill(void 0),this.#p=new w(t),this.#u=new w(t),this.#s=0,this.#n=0,this.#v=ns.create(t),this.#a=0,this.#g=0,typeof p=="function"&&(this.#y=p),typeof c=="function"?(this.#b=c,this.#i=[]):(this.#b=void 0,this.#i=void 0),this.#z=!!this.#y,this.#c=!!this.#b,this.noDisposeOnSet=!!d,this.noUpdateTTL=!!m,this.noDeleteOnFetchRejection=!!v,this.allowStaleOnFetchRejection=!!_,this.allowStaleOnFetchAbort=!!z,this.ignoreFetchAbort=!!P,this.maxEntrySize!==0){if(this.#d!==0&&!st(this.#d))throw new TypeError("maxSize must be a positive integer if specified");if(!st(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");this.#j();}if(this.allowStale=!!l,this.noDeleteOnStaleGet=!!h,this.updateAgeOnGet=!!i,this.updateAgeOnHas=!!s,this.ttlResolution=st(a)||a===0?a:1,this.ttlAutopurge=!!n,this.ttl=o||0,this.ttl){if(!st(this.ttl))throw new TypeError("ttl must be a positive integer if specified");this.#N();}if(this.#l===0&&this.ttl===0&&this.#d===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.#l&&!this.#d){let C="LRU_CACHE_UNBOUNDED";Dz(C)&&(qd.add(C),Gd("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",C,r));}}getRemainingTTL(e){return this.#o.has(e)?1/0:0}#N(){let e=new cr(this.#l),t=new cr(this.#l);this.#m=e,this.#_=t,this.#L=(n,i,s=pr.now())=>{if(t[n]=i!==0?s:0,e[n]=i,i!==0&&this.ttlAutopurge){let l=setTimeout(()=>{this.#f(n)&&this.#P(this.#r[n],"expire");},i+1);l.unref&&l.unref();}},this.#I=n=>{t[n]=e[n]!==0?pr.now():0;},this.#w=(n,i)=>{if(e[i]){let s=e[i],l=t[i];if(!s||!l)return;n.ttl=s,n.start=l,n.now=o||a();let p=n.now-l;n.remainingTTL=s-p;}};let o=0,a=()=>{let n=pr.now();if(this.ttlResolution>0){o=n;let i=setTimeout(()=>o=0,this.ttlResolution);i.unref&&i.unref();}return n};this.getRemainingTTL=n=>{let i=this.#o.get(n);if(i===void 0)return 0;let s=e[i],l=t[i];if(!s||!l)return 1/0;let p=(o||a())-l;return s-p},this.#f=n=>{let i=t[n],s=e[n];return !!s&&!!i&&(o||a())-i>s};}#I=()=>{};#w=()=>{};#L=()=>{};#f=()=>false;#j(){let e=new cr(this.#l);this.#g=0,this.#h=e,this.#S=t=>{this.#g-=e[t],e[t]=0;},this.#A=(t,o,a,n)=>{if(this.#t(o))return 0;if(!st(a))if(n){if(typeof n!="function")throw new TypeError("sizeCalculation must be a function");if(a=n(o,t),!st(a))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return a},this.#D=(t,o,a)=>{if(e[t]=o,this.#d){let n=this.#d-e[t];for(;this.#g>n;)this.#M(true);}this.#g+=e[t],a&&(a.entrySize=o,a.totalCalculatedSize=this.#g);};}#S=e=>{};#D=(e,t,o)=>{};#A=(e,t,o,a)=>{if(o||a)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0};*#x({allowStale:e=this.allowStale}={}){if(this.#a)for(let t=this.#n;!(!this.#B(t)||((e||!this.#f(t))&&(yield t),t===this.#s));)t=this.#u[t];}*#C({allowStale:e=this.allowStale}={}){if(this.#a)for(let t=this.#s;!(!this.#B(t)||((e||!this.#f(t))&&(yield t),t===this.#n));)t=this.#p[t];}#B(e){return e!==void 0&&this.#o.get(this.#r[e])===e}*entries(){for(let e of this.#x())this.#e[e]!==void 0&&this.#r[e]!==void 0&&!this.#t(this.#e[e])&&(yield [this.#r[e],this.#e[e]]);}*rentries(){for(let e of this.#C())this.#e[e]!==void 0&&this.#r[e]!==void 0&&!this.#t(this.#e[e])&&(yield [this.#r[e],this.#e[e]]);}*keys(){for(let e of this.#x()){let t=this.#r[e];t!==void 0&&!this.#t(this.#e[e])&&(yield t);}}*rkeys(){for(let e of this.#C()){let t=this.#r[e];t!==void 0&&!this.#t(this.#e[e])&&(yield t);}}*values(){for(let e of this.#x())this.#e[e]!==void 0&&!this.#t(this.#e[e])&&(yield this.#e[e]);}*rvalues(){for(let e of this.#C())this.#e[e]!==void 0&&!this.#t(this.#e[e])&&(yield this.#e[e]);}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="LRUCache";find(e,t={}){for(let o of this.#x()){let a=this.#e[o],n=this.#t(a)?a.__staleWhileFetching:a;if(n!==void 0&&e(n,this.#r[o],this))return this.get(this.#r[o],t)}}forEach(e,t=this){for(let o of this.#x()){let a=this.#e[o],n=this.#t(a)?a.__staleWhileFetching:a;n!==void 0&&e.call(t,n,this.#r[o],this);}}rforEach(e,t=this){for(let o of this.#C()){let a=this.#e[o],n=this.#t(a)?a.__staleWhileFetching:a;n!==void 0&&e.call(t,n,this.#r[o],this);}}purgeStale(){let e=false;for(let t of this.#C({allowStale:true}))this.#f(t)&&(this.#P(this.#r[t],"expire"),e=true);return e}info(e){let t=this.#o.get(e);if(t===void 0)return;let o=this.#e[t],a=this.#t(o)?o.__staleWhileFetching:o;if(a===void 0)return;let n={value:a};if(this.#m&&this.#_){let i=this.#m[t],s=this.#_[t];if(i&&s){let l=i-(pr.now()-s);n.ttl=l,n.start=Date.now();}}return this.#h&&(n.size=this.#h[t]),n}dump(){let e=[];for(let t of this.#x({allowStale:true})){let o=this.#r[t],a=this.#e[t],n=this.#t(a)?a.__staleWhileFetching:a;if(n===void 0||o===void 0)continue;let i={value:n};if(this.#m&&this.#_){i.ttl=this.#m[t];let s=pr.now()-this.#_[t];i.start=Math.floor(Date.now()-s);}this.#h&&(i.size=this.#h[t]),e.unshift([o,i]);}return e}load(e){this.clear();for(let[t,o]of e){if(o.start){let a=Date.now()-o.start;o.start=pr.now()-a;}this.set(t,o.value,o);}}set(e,t,o={}){if(t===void 0)return this.delete(e),this;let{ttl:a=this.ttl,start:n,noDisposeOnSet:i=this.noDisposeOnSet,sizeCalculation:s=this.sizeCalculation,status:l}=o,{noUpdateTTL:p=this.noUpdateTTL}=o,c=this.#A(e,t,o.size||0,s);if(this.maxEntrySize&&c>this.maxEntrySize)return l&&(l.set="miss",l.maxEntrySizeExceeded=true),this.#P(e,"set"),this;let d=this.#a===0?void 0:this.#o.get(e);if(d===void 0)d=this.#a===0?this.#n:this.#v.length!==0?this.#v.pop():this.#a===this.#l?this.#M(false):this.#a,this.#r[d]=e,this.#e[d]=t,this.#o.set(e,d),this.#p[this.#n]=d,this.#u[d]=this.#n,this.#n=d,this.#a++,this.#D(d,c,l),l&&(l.set="add"),p=false;else {this.#R(d);let m=this.#e[d];if(t!==m){if(this.#k&&this.#t(m)){m.__abortController.abort(new Error("replaced"));let{__staleWhileFetching:u}=m;u!==void 0&&!i&&(this.#z&&this.#y?.(u,e,"set"),this.#c&&this.#i?.push([u,e,"set"]));}else i||(this.#z&&this.#y?.(m,e,"set"),this.#c&&this.#i?.push([m,e,"set"]));if(this.#S(d),this.#D(d,c,l),this.#e[d]=t,l){l.set="replace";let u=m&&this.#t(m)?m.__staleWhileFetching:m;u!==void 0&&(l.oldValue=u);}}else l&&(l.set="update");}if(a!==0&&!this.#m&&this.#N(),this.#m&&(p||this.#L(d,a,n),l&&this.#w(l,d)),!i&&this.#c&&this.#i){let m=this.#i,u;for(;u=m?.shift();)this.#b?.(...u);}return this}pop(){try{for(;this.#a;){let e=this.#e[this.#s];if(this.#M(!0),this.#t(e)){if(e.__staleWhileFetching)return e.__staleWhileFetching}else if(e!==void 0)return e}}finally{if(this.#c&&this.#i){let e=this.#i,t;for(;t=e?.shift();)this.#b?.(...t);}}}#M(e){let t=this.#s,o=this.#r[t],a=this.#e[t];return this.#k&&this.#t(a)?a.__abortController.abort(new Error("evicted")):(this.#z||this.#c)&&(this.#z&&this.#y?.(a,o,"evict"),this.#c&&this.#i?.push([a,o,"evict"])),this.#S(t),e&&(this.#r[t]=void 0,this.#e[t]=void 0,this.#v.push(t)),this.#a===1?(this.#s=this.#n=0,this.#v.length=0):this.#s=this.#p[t],this.#o.delete(o),this.#a--,t}has(e,t={}){let{updateAgeOnHas:o=this.updateAgeOnHas,status:a}=t,n=this.#o.get(e);if(n!==void 0){let i=this.#e[n];if(this.#t(i)&&i.__staleWhileFetching===void 0)return false;if(this.#f(n))a&&(a.has="stale",this.#w(a,n));else return o&&this.#I(n),a&&(a.has="hit",this.#w(a,n)),true}else a&&(a.has="miss");return false}peek(e,t={}){let{allowStale:o=this.allowStale}=t,a=this.#o.get(e);if(a===void 0||!o&&this.#f(a))return;let n=this.#e[a];return this.#t(n)?n.__staleWhileFetching:n}#E(e,t,o,a){let n=t===void 0?void 0:this.#e[t];if(this.#t(n))return n;let i=new Oa,{signal:s}=o;s?.addEventListener("abort",()=>i.abort(s.reason),{signal:i.signal});let l={signal:i.signal,options:o,context:a},p=(y,f=false)=>{let{aborted:g}=i.signal,v=o.ignoreFetchAbort&&y!==void 0;if(o.status&&(g&&!f?(o.status.fetchAborted=true,o.status.fetchError=i.signal.reason,v&&(o.status.fetchAbortIgnored=true)):o.status.fetchResolved=true),g&&!v&&!f)return d(i.signal.reason);let h=u;return this.#e[t]===u&&(y===void 0?h.__staleWhileFetching?this.#e[t]=h.__staleWhileFetching:this.#P(e,"fetch"):(o.status&&(o.status.fetchUpdated=true),this.set(e,y,l.options))),y},c=y=>(o.status&&(o.status.fetchRejected=true,o.status.fetchError=y),d(y)),d=y=>{let{aborted:f}=i.signal,g=f&&o.allowStaleOnFetchAbort,v=g||o.allowStaleOnFetchRejection,h=v||o.noDeleteOnFetchRejection,_=u;if(this.#e[t]===u&&(!h||_.__staleWhileFetching===void 0?this.#P(e,"fetch"):g||(this.#e[t]=_.__staleWhileFetching)),v)return o.status&&_.__staleWhileFetching!==void 0&&(o.status.returnedStale=true),_.__staleWhileFetching;if(_.__returned===_)throw y},m=(y,f)=>{let g=this.#$?.(e,n,l);g&&g instanceof Promise&&g.then(v=>y(v===void 0?void 0:v),f),i.signal.addEventListener("abort",()=>{(!o.ignoreFetchAbort||o.allowStaleOnFetchAbort)&&(y(void 0),o.allowStaleOnFetchAbort&&(y=v=>p(v,true)));});};o.status&&(o.status.fetchDispatched=true);let u=new Promise(m).then(p,c),b=Object.assign(u,{__abortController:i,__staleWhileFetching:n,__returned:void 0});return t===void 0?(this.set(e,b,{...l.options,status:void 0}),t=this.#o.get(e)):this.#e[t]=b,b}#t(e){if(!this.#k)return false;let t=e;return !!t&&t instanceof Promise&&t.hasOwnProperty("__staleWhileFetching")&&t.__abortController instanceof Oa}async fetch(e,t={}){let{allowStale:o=this.allowStale,updateAgeOnGet:a=this.updateAgeOnGet,noDeleteOnStaleGet:n=this.noDeleteOnStaleGet,ttl:i=this.ttl,noDisposeOnSet:s=this.noDisposeOnSet,size:l=0,sizeCalculation:p=this.sizeCalculation,noUpdateTTL:c=this.noUpdateTTL,noDeleteOnFetchRejection:d=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:m=this.allowStaleOnFetchRejection,ignoreFetchAbort:u=this.ignoreFetchAbort,allowStaleOnFetchAbort:b=this.allowStaleOnFetchAbort,context:y,forceRefresh:f=false,status:g,signal:v}=t;if(!this.#k)return g&&(g.fetch="get"),this.get(e,{allowStale:o,updateAgeOnGet:a,noDeleteOnStaleGet:n,status:g});let h={allowStale:o,updateAgeOnGet:a,noDeleteOnStaleGet:n,ttl:i,noDisposeOnSet:s,size:l,sizeCalculation:p,noUpdateTTL:c,noDeleteOnFetchRejection:d,allowStaleOnFetchRejection:m,allowStaleOnFetchAbort:b,ignoreFetchAbort:u,status:g,signal:v},_=this.#o.get(e);if(_===void 0){g&&(g.fetch="miss");let z=this.#E(e,_,h,y);return z.__returned=z}else {let z=this.#e[_];if(this.#t(z)){let $=o&&z.__staleWhileFetching!==void 0;return g&&(g.fetch="inflight",$&&(g.returnedStale=true)),$?z.__staleWhileFetching:z.__returned=z}let P=this.#f(_);if(!f&&!P)return g&&(g.fetch="hit"),this.#R(_),a&&this.#I(_),g&&this.#w(g,_),z;let w=this.#E(e,_,h,y),k=w.__staleWhileFetching!==void 0&&o;return g&&(g.fetch=P?"stale":"refresh",k&&P&&(g.returnedStale=true)),k?w.__staleWhileFetching:w.__returned=w}}async forceFetch(e,t={}){let o=await this.fetch(e,t);if(o===void 0)throw new Error("fetch() returned undefined");return o}memo(e,t={}){let o=this.#T;if(!o)throw new Error("no memoMethod provided to constructor");let{context:a,forceRefresh:n,...i}=t,s=this.get(e,i);if(!n&&s!==void 0)return s;let l=o(e,s,{options:i,context:a});return this.set(e,l,i),l}get(e,t={}){let{allowStale:o=this.allowStale,updateAgeOnGet:a=this.updateAgeOnGet,noDeleteOnStaleGet:n=this.noDeleteOnStaleGet,status:i}=t,s=this.#o.get(e);if(s!==void 0){let l=this.#e[s],p=this.#t(l);return i&&this.#w(i,s),this.#f(s)?(i&&(i.get="stale"),p?(i&&o&&l.__staleWhileFetching!==void 0&&(i.returnedStale=true),o?l.__staleWhileFetching:void 0):(n||this.#P(e,"expire"),i&&o&&(i.returnedStale=true),o?l:void 0)):(i&&(i.get="hit"),p?l.__staleWhileFetching:(this.#R(s),a&&this.#I(s),l))}else i&&(i.get="miss");}#O(e,t){this.#u[t]=e,this.#p[e]=t;}#R(e){e!==this.#n&&(e===this.#s?this.#s=this.#p[e]:this.#O(this.#u[e],this.#p[e]),this.#O(this.#n,e),this.#n=e);}delete(e){return this.#P(e,"delete")}#P(e,t){let o=false;if(this.#a!==0){let a=this.#o.get(e);if(a!==void 0)if(o=true,this.#a===1)this.#F(t);else {this.#S(a);let n=this.#e[a];if(this.#t(n)?n.__abortController.abort(new Error("deleted")):(this.#z||this.#c)&&(this.#z&&this.#y?.(n,e,t),this.#c&&this.#i?.push([n,e,t])),this.#o.delete(e),this.#r[a]=void 0,this.#e[a]=void 0,a===this.#n)this.#n=this.#u[a];else if(a===this.#s)this.#s=this.#p[a];else {let i=this.#u[a];this.#p[i]=this.#p[a];let s=this.#p[a];this.#u[s]=this.#u[a];}this.#a--,this.#v.push(a);}}if(this.#c&&this.#i?.length){let a=this.#i,n;for(;n=a?.shift();)this.#b?.(...n);}return o}clear(){return this.#F("delete")}#F(e){for(let t of this.#C({allowStale:true})){let o=this.#e[t];if(this.#t(o))o.__abortController.abort(new Error("deleted"));else {let a=this.#r[t];this.#z&&this.#y?.(o,a,e),this.#c&&this.#i?.push([o,a,e]);}}if(this.#o.clear(),this.#e.fill(void 0),this.#r.fill(void 0),this.#m&&this.#_&&(this.#m.fill(0),this.#_.fill(0)),this.#h&&this.#h.fill(0),this.#s=0,this.#n=0,this.#v.length=0,this.#g=0,this.#a=0,this.#c&&this.#i){let t=this.#i,o;for(;o=t?.shift();)this.#b?.(...o);}}};yi(Wi());yi(Xd());var tx={};typeof window<"u"&&wd(tx);var eu=(r,e)=>{for(var t=e-1;t>=0;){if(r[t]==="/")return t;t--;}return -1},rx=r=>{var e,t=r.lastIndexOf(".css");if(t===-1)return "";var o=eu(r,t);if(e=r.slice(o+1,t),o===-1)return e;var a=eu(r,o-1),n=r.slice(a+1,o),i=e!=="index"?e:n;return i},ox=()=>{var r=new Fa({max:500});return e=>{var t=r.get(e);if(t)return t;var o=rx(e);return r.set(e,o),o}};ox();function ax(r){if(typeof r!="string"||!/^var\(--.*\)$/.test(r))throw new Error("Invalid variable name: ".concat(r))}function tu(){for(var r="",e=arguments.length,t=new Array(e),o=0;o<e;o++)t[o]=arguments[o];return t.reverse().forEach(a=>{r===""?r=String(a):(ax(a),r=a.replace(/\)$/,", ".concat(r,")")));}),r}function su(r,e,t){let[o,a]=useState({}),n=useRef(false),[i,s]=useState(null),{container:l,shouldContainOverlays:p,isContainerPositioned:c}=useContext(It);useEffect(()=>{if(!r||!t)return;let u=re(r),b=u.visualViewport,y=()=>{let f=b?.height,g=u.innerHeight-(f||0);if(n.current=g>60,n.current){let v=getActiveElement(r);v&&isInputThatOpensKeyboard(v)&&v.scrollIntoView({behavior:"smooth",block:"center"});}if(e)a({maxHeight:(f||0)*.8,bottom:g});else {let v=`${f||0}px`,h=p?`min(${v}, ${tu(_a,v)})`:v;a({maxHeight:`calc(${h} - (2 * ${themeVars.spacing.xl} + env(safe-area-inset-top) + env(safe-area-inset-bottom)))`,top:n.current?`calc(env(safe-area-inset-top) + ${themeVars.spacing.xl})`:void 0});}};return y(),b?.addEventListener("resize",y),u.addEventListener("resize",y),()=>{b?.removeEventListener("resize",y),u.removeEventListener("resize",y);}},[r,e,p,t]),useEffect(()=>{if(!l||!p||c)return;let u=()=>{l&&s(getAbsoluteBounds(l));};u();let b=new ResizeObserver(()=>{u();});return b.observe(l),()=>{b.disconnect();}},[l,p,c]);let d=useMemo(()=>({...o,overflow:"auto",position:"relative"}),[o]),m=useMemo(()=>{if(!e&&n.current)return {alignItems:"flex-start"};if(p&&!c){let u=i||(l?getAbsoluteBounds(l):{x:0,y:0,height:0,width:0});return {position:"absolute",left:u.x,top:u.y,height:u.height,width:u.width}}return {}},[e,n.current,l,c,p,i]);return {dialogStyle:d,containerStyle:m}}var ds=wt.createContext({isDrawer:false,closeDrawer:()=>{},dialogStyle:{},setDialogElement:()=>{},isWithinModal:false}),us=wt.createContext({setIsPopoverSafelyClosed:()=>{}}),Ue=({children:r,className:e,style:t,isDismissable:o=true,isKeyboardDismissDisabled:a=false,portalContainer:n,disableAnimation:i,enableDrawer:s=false,"data-block-id":l,"data-block-class":p,shouldCloseOnInteractOutside:c})=>{let{state:d}=wt.useContext(St),[m,u]=wt.useState(true),b=wt.useRef(null),[y,f]=wt.useState(null),{shouldHandleVirtualKeyboard:g}=useContext(rr),{shouldContainOverlays:v,container:h}=useContext(It),_=Ne(),z=typeof s=="boolean"&&s||s==="auto"&&_==="mobile";invariant(d,"ModalContent must be a child of Modal");let P=wt.useRef(null),w=typeof o=="function"?o(z):o,C=typeof a=="function"?a(z):a,{modalProps:k,underlayProps:$}=useModalOverlay({isDismissable:m&&w,shouldCloseOnInteractOutside:B=>!h?.contains(B)&&v?false:c?.(B)??true,isKeyboardDismissDisabled:C},d,P),{dialogStyle:R,containerStyle:T}=su(y,z,g),I=useMemo(()=>({isDrawer:z,closeDrawer:d.close,dialogStyle:R,dialogRef:b,setDialogElement:f,isWithinModal:true}),[z,d.close,R,b,f]),S=useMemo(()=>({setIsPopoverSafelyClosed:u}),[u]),E={duration:.3,type:"tween",ease:"easeOut"},N={type:"spring",duration:.3},O={open:{opacity:1,transform:z?"translateY(0%)":"scale(1)"},closed:i?{opacity:1,transform:z?"translateY(0%)":"scale(1)"}:{opacity:0,transform:z?"translateY(100%)":"scale(0.95)"}};return jsx(AnimatePresence,{initial:false,children:d.isOpen?jsx(ds.Provider,{value:I,children:jsx(us.Provider,{value:S,children:jsxs(he,{className:classNames(gd({enableDrawer:z,shouldContainOverlays:v}),e),"data-block-id":l,"data-block-class":p,style:{...t,...T},portalContainer:n,children:[jsx(motion.div,{...$,variants:{open:{opacity:1},closed:{opacity:i?1:0}},initial:"closed",animate:"open",exit:"closed","data-testid":"underlay",transition:E,className:classNames(vd({shouldContainOverlays:v}),"BaselineUI-Modal-Underlay")}),jsx(motion.div,{...k,ref:P,"data-drawer":z,className:classNames(z?yd:bd,"BaselineUI-Modal-Content"),variants:O,transition:z?E:N,initial:"closed",animate:"open",exit:"closed",children:typeof r=="function"?r(d):r})]})})}):null})};var du=x({defaultClassName:"cjv3et0 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6g1 _1yep5z6lz _1yep5z6m1",variantClassNames:{size:{sm:"cjv3et1",md:"cjv3et2",lg:"cjv3et3",content:"cjv3et4"},variant:{primary:"_1yep5z6137",ghost:"cjv3et6"},overlayType:{modal:"cjv3et7",popover:"cjv3et8"},isDrawer:{true:"cjv3et9 _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8 _1yep5z617q"},isFocusVisible:{true:"_1yep5z61q3 _1yep5z61tx _1yep5z61tz _1yep5z61u1"}},defaultVariants:{},compoundVariants:[]});var fs=wt.createContext({titleProps:{}}),ze=wt.forwardRef(({children:r,className:e,style:t,inheritDrawer:o,size:a="md",variant:n="primary","data-block-id":i,"data-block-class":s,drawerBackground:l,...p},c)=>{let d=wt.useRef(null),m=wt.useRef(null),{isDrawer:u,closeDrawer:b,dialogStyle:y,setDialogElement:f,isWithinModal:g}=useContext(ds),[v,h]=wt.useState(""),{focusProps:_,isFocusVisible:z}=useFocusRing();useLayoutEffect(()=>{let k=m.current?.getRootNode(),$=p["aria-label"]||"";p["aria-labelledby"]&&($=k?.querySelector(`#${p["aria-labelledby"].replaceAll(":",String.raw`\:`)}`)?.textContent||""),h($);},[p]);let{dialogProps:P,titleProps:w}=useDialog(p,d),C=useMemo(()=>({titleProps:w}),[w]);return u&&o?jsx(Da,{title:v,onCloseRequest:b,className:e,style:y,...p,"data-drawer":true,"data-block-id":i,"data-block-class":s,ref:M(m,c,k=>{f(k);}),background:l,children:r}):jsx(fs.Provider,{value:C,children:jsx("section",{...mergeProps(P,_),"data-block-id":i,"data-block-class":s,"data-focus-visible":z,"data-overlay-type":g?"modal":"popover",ref:M(d,c,k=>{f(k);}),style:{...y,...t},className:classNames(du({size:u?"content":a,variant:n,isDrawer:u,isFocusVisible:z,overlayType:g?"modal":"popover"}),"BaselineUI-Dialog",e),children:r})})});ze.displayName="Dialog";var uu=wt.forwardRef(({children:r,className:e,style:t},o)=>{let{titleProps:a}=useContext(fs);return wt.isValidElement(r)?wt.cloneElement(r,{...a,ref:o,className:classNames(r.props.className,e),style:{...r.props.style,...t}}):jsx("h3",{...a,ref:o,className:e,style:t,children:r})});uu.displayName="DialogTitle";var fu=({children:r,isOpen:e,popoverContentRef:t,portalContainer:o=document.body,style:a})=>{let[n,i]=useState(false),[s,l]=useState(null),p=useRef(null),{setIsPopoverSafelyClosed:c}=useContext(us);useEffect(()=>{e?(i(true),p.current&&clearTimeout(p.current)):p.current=setTimeout(()=>{i(false);},300);},[e]),useEffect(()=>()=>{p.current&&clearTimeout(p.current);},[]);let d=t.current;return useEffect(()=>{d&&l(d.getBoundingClientRect());},[d]),useEffect(()=>{c(!n);},[n,c]),jsxs(Fragment,{children:[n?wx.createPortal(jsx("div",{style:{position:"absolute",left:a?.left,top:a?.top,width:s?.width,height:s?.height,zIndex:a?.zIndex?+a.zIndex-1:void 0},className:"BaselineUI-Popover-ClickPreventionLayer"}),o):null,r]})};var{color:ur}=themeVars,we=wt.forwardRef(({portalClassName:r,portalStyle:e,className:t,style:o,state:a,overlayProps:n,underlayClassName:i,children:s,includeArrow:l=false,offset:p=2,portalContainer:c,contentContainerClassName:d,contentContainerStyle:m,"data-block-id":u,"data-block-class":b,...y},f)=>{let g=wt.useRef(null),v=ve(c),h=l?8:0,{underlayProps:_,popoverProps:z,placement:P,arrowProps:w}=usePopover({...y,offset:p+h,popoverRef:g,containerPadding:y.containerPadding||0},a);delete z.style?.position;let C=P==="center"?"bottom":P,k=useMemo(()=>({isOpen:a.isOpen}),[a.isOpen]),{transitionProps:$}=va({placement:P}),R=useMemo(()=>({...z.style,...assignInlineVars({[uc]:`${y.triggerRef?.current?.offsetWidth}px`}),...Ri(o,k)}),[z.style,y.triggerRef,o,k]);return jsx(fu,{isOpen:a.isOpen,popoverContentRef:g,portalContainer:v,style:z.style,children:a.isOpen?jsxs(he,{portalContainer:v,style:e,className:r,ref:f,"data-block-id":u,"data-block-class":b,children:[!y.isNonModal&&jsx("div",{..._,className:classNames(dc,aa(i,k),"BaselineUI-Popover-Underlay")}),jsxs(motion.div,{...mergeProps(z,$),style:R,ref:M(g,f),className:classNames(lc,"BaselineUI-Popover-ContentContainer",aa(t,k)),"data-placement":["top","bottom","left","right"].filter(T=>P?.includes(T)),children:[l?jsxs(Fragment,{children:[jsxs("svg",{className:classNames(ic({placement:C}),"BaselineUI-PopoverContent-Arrow"),...w,style:{...w.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:ur.border.medium}),jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:ur.background.primary.subtle,stroke:ur.background.primary.subtle})]}),jsxs("svg",{className:classNames(sc({placement:C}),"BaselineUI-PopoverContent-Arrow-Focused"),width:"15",height:"11",viewBox:"0 0 15 11",fill:"none",xmlns:"http://www.w3.org/2000/svg",...w,style:{...w.style,position:"absolute"},children:[jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M0.543371 2H0V0H1.45663L7.5 6.97312L13.5434 0H15V2H14.4566L7.5 10.0269L0.543371 2Z",fill:ur.border.interactive.enabled}),jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:ur.background.primary.subtle,stroke:ur.background.primary.subtle})]})]}):null,jsx(DismissButton,{onDismiss:a.close}),jsx("div",{...n,style:Ri(m,k),className:classNames(pc,aa(d,k),"BaselineUI-Popover-Content"),children:typeof s=="function"?s(a):s}),jsx(DismissButton,{onDismiss:a.close})]})]}):null})});we.displayName="PopoverContentCore";var Ae=wt.forwardRef((r,e)=>{let{state:t,overlayTriggerAria:{overlayProps:o},triggerRef:a}=useContext(Xr);return invariant(a),t?jsx(we,{ref:e,...r,triggerRef:r.triggerRef||a,overlayProps:o,state:t}):null});Ae.displayName="PopoverContent";var _u=wt.forwardRef(({className:r,style:e,onChange:t,"data-block-id":o,icon:a,formatValue:n=d=>d,tooltipProps:i,popoverContentProps:s,isDisabled:l,...p},c)=>{let d=oe(c),[m,u]=useControlledState(p.value,p.defaultValue||0,t),[b,y]=wt.useState(false),{keyboardProps:f}=useKeyboard({onKeyDown:h=>{(h.key==="Enter"||h.key==="Escape")&&y(false);}}),g=n(m||0),v=i?.isDisabled||p["aria-label"]?`${p["aria-label"]}, ${g}`:g.toString();return jsxs(D,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:classNames("BaselineUI-IconSlider",r),"data-block-id":o,style:e,ref:d,children:[a?jsx(a,{"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary"})}):null,jsxs(je,{type:"dialog",isOpen:b,onOpenChange:y,children:[jsx(He,{children:jsx(ie,{text:p["aria-label"],size:"sm",variant:"inverse",includeArrow:false,isDisabled:l,...i,children:jsx(K,{label:g,variant:"popover","aria-label":v,isDisabled:l,style:{fontVariantNumeric:"tabular-nums",minWidth:68,justifyContent:"space-between"}})})}),jsx(Ae,{placement:"bottom start",...s,children:jsx(ze,{size:"content","aria-label":v,children:jsx(FocusScope,{autoFocus:true,children:jsx(D,{paddingY:"sm",paddingX:"lg",marginY:"md",style:{width:215},...f,children:jsx(nr,{...p,onChange:h=>{u(h),t?.(h);},value:m})})})})})]})]})});_u.displayName="IconSlider";var zu=x({defaultClassName:"bpklwa7",variantClassNames:{isReadOnly:{true:"bpklwa8"},isDisabled:{true:"bpklwa9"},isSelected:{true:"bpklwaa"},isFocused:{true:"bpklwab"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:false,isReadOnly:false},"bpklwac"]]}),xu=x({defaultClassName:"bpklwae",variantClassNames:{isDisabled:{true:"bpklwaf"},isSelected:{true:"bpklwag"},isReadOnly:{true:"bpklwah"}},defaultVariants:{},compoundVariants:[]}),Cu="bpklwad",Pu=x({defaultClassName:"bpklwa0",variantClassNames:{labelPosition:{top:"bpklwa1",left:"bpklwa2"}},defaultVariants:{},compoundVariants:[]}),wu="bpklwa6",ku=x({defaultClassName:"bpklwa3",variantClassNames:{labelPosition:{top:"bpklwa4",left:"bpklwa5"}},defaultVariants:{},compoundVariants:[]});var $u=wt.forwardRef(({className:r,label:e,labelPosition:t="top",statusLabel:o,style:a,"data-block-id":n,"data-block-class":i,...s},l)=>{let p=wt.useRef(null),c=useToggleState(s),{inputProps:d,isPressed:m}=useSwitch({...s,children:e},c,p),{isFocusVisible:u,focusProps:b}=useFocusRing(),{hoverProps:y,isHovered:f}=useHover({isDisabled:s.isDisabled}),g=filterTruthyValues({"data-block-id":n,"data-block-class":i,"data-focused":u,"data-disabled":s.isDisabled,"data-focus-visible":u,"data-selected":c.isSelected,"data-readonly":s.isReadOnly,"data-hovered":f,"data-pressed":m}),v=jsx("div",{className:classNames(zu({isSelected:c.isSelected,isDisabled:!!s.isDisabled,isFocused:u,isReadOnly:!!s.isReadOnly}),"BaselineUI-Switch-Track"),children:jsx("div",{className:classNames(xu({isSelected:c.isSelected,isDisabled:s.isDisabled,isReadOnly:s.isReadOnly}),"BaselineUI-Switch-Knob"),"data-testid":"switch-knob"})});return jsxs("label",{...mergeProps(g,y),className:classNames(Pu({labelPosition:t}),"BaselineUI-Switch",r),style:a,ref:l,children:[e?jsx("span",{className:classNames(Cu,"BaselineUI-Switch-Label"),children:e}):null,jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(d,b),ref:p})}),o?jsxs("div",{className:ku({labelPosition:t}),children:[jsx("span",{className:classNames("BaselineUI-Switch-Status-Label",wu),children:c.isSelected?o.on:o.off}),v]}):v]})});$u.displayName="Switch";var Tu="_19n40yy9",Du=x({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 nC={sm:SearchIcon$1,md:SearchIcon,lg:SearchIcon},Nu=wt.forwardRef(({className:r,size:e="md",variant:t="primary","data-block-id":o,"data-block-class":a,style:n,...i},s)=>{let l=wt.useRef(null),p=useSearchFieldState(i),{inputProps:c,clearButtonProps:d}=useSearchField({...i,"aria-haspopup":false,"aria-autocomplete":"none",type:"search"},p,l),{focusProps:m,isFocusVisible:u,isFocused:b}=useFocusRing({within:true,isTextInput:true}),y=nC[e],f=e==="sm"?XIcon$1:XIcon$2,g=filterTruthyValues({"data-block-id":o,"data-block-class":a,"data-focused":b,"data-disabled":i.isDisabled,"data-focus-visible":u});return jsxs("div",{...g,className:classNames(Du({size:e,isFocused:b,variant:t,hasText:!!p.value,isDisabled:i.isDisabled}),"BaselineUI-SearchInput",r),style:n,ref:s,children:[jsx(y,{size:e==="sm"?20:24}),jsx("input",{...mergeProps(c,m),className:Tu,ref:l}),p.value!==""&&jsx(L,{icon:f,...d,size:e==="sm"?"xs":"sm",variant:"secondary"})]})});Nu.displayName="SearchInput";var Lu="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 _1yep5z6ls _1yep5z6lr _1yep5z6i0 _1yep5z6lv _1yep5z6g1",Au="xyd2ss0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b";var gs=({section:r,showSelectedIcon:e,state:t})=>{let{itemProps:o,groupProps:a,headingProps:n}=useMenuSection({heading:r.value?.title,"aria-label":r["aria-label"]});return jsxs(Fragment,{children:[r.key!==t.collection.getFirstKey()&&jsx(U,{elementType:"li"}),jsxs("li",{...o,children:[r.value?.title?jsx(VisuallyHidden,{children:jsx("span",{...n,children:r.value.title})}):null,jsx("ul",{...a,className:Au,children:[...r.childNodes].map(i=>(invariant(i.type==="item"),jsx(Ha,{item:i,state:t,showSelectedIcon:e},i.key)))})]})]})};gs.displayName="MenuSection";var Ha=({item:r,state:e,className:t,showSelectedIcon:o})=>{let a=wt.useRef(null),n=useMenuItem({key:r.key},e,a),{isFocusVisible:i,focusProps:s}=useFocusRing();return jsx(Yr,{item:r,liProps:mergeProps(n.menuItemProps,s,{className:t}),...n,isFocusVisible:i,ref:a,description:r.value?.keyboardShortcut,descriptionProps:n.keyboardShortcutProps,_state:e,showSelectedIcon:o})};Ha.displayName="MenuItem";var hs=wt.forwardRef(({className:r,itemClassName:e,onContentKeyDown:t,...o},a)=>{let n=useTreeState(o),i=wt.useRef(null),{menuProps:s}=useMenu(o,n,i),{keyboardProps:l}=useKeyboard({onKeyDown:t});return jsx("ul",{...mergeProps(s,l),className:classNames(Lu,r),ref:M(i,a),children:[...n.collection].map(p=>p.type==="section"?jsx(gs,{section:p,state:n,showSelectedIcon:o.selectionMode==="multiple"||o.selectionMode==="single"},p.key):jsx(Ha,{item:p,state:n,className:e,showSelectedIcon:o.selectionMode==="multiple"||o.selectionMode==="single"},p.key))})});hs.displayName="MenuContent";var Fu=x({defaultClassName:"_1mdhlqv8",variantClassNames:{isOpen:{true:"_1mdhlqv9"}},defaultVariants:{},compoundVariants:[]}),lt="_1mdhlqvb cjv3et0 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6g1 _1yep5z6lz _1yep5z6m1 _1yep5z6137 cjv3et4",ju=x({defaultClassName:"_1mdhlqv0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6eu _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6dy",variantClassNames:{isFocused:{false:"_1mdhlqv1"},isOpen:{true:"_1mdhlqv2"},isDisabled:{true:"z9nup83 _1yep5z6ey"},isHovered:{true:"_1mdhlqv4"},variant:{primary:"_1mdhlqv5",ghost:"_1mdhlqv6"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isHovered:true},"_1mdhlqv7"]]}),Hu="_1yep5z66x _1yep5z66y _1yep5z66z",Vu="_1mdhlqva _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k";var Va=wt.forwardRef(({defaultOpen:r,onOpenChange:e,isOpen:t,isDisabled:o,contentClassName:a,placement:n="bottom start",isNonModal:i,shouldFlip:s,shouldUpdatePosition:l,boundaryElement:p,crossOffset:c,offset:d,triggerLabel:m,renderTrigger:u=({buttonProps:g,ref:v})=>jsx(K,{...g,variant:"popover",ref:v}),portalContainer:b,...y},f)=>{let g=wt.useRef(null),v=ve(b),h=useMenuTriggerState({defaultOpen:r,isOpen:t,onOpenChange:e}),{menuTriggerProps:_,menuProps:z}=useMenuTrigger({isDisabled:o,type:"menu"},h,g),P=pe(),w=useMemo(()=>mergeProps(_,{isDisabled:o,isSelected:h.isOpen,className:"BaselineUI-Menu-Trigger",label:typeof m=="function"?m(h.isOpen):m}),[_,o,h.isOpen,m]);return useEffect(()=>{!m&&!u&&console.warn("The `triggerLabel` prop is required when no `renderTrigger` or `children` is provided.");},[u,m]),jsxs(Fragment,{children:[u({buttonProps:w,ref:g}),jsx(we,{triggerRef:g,state:h,placement:n,isNonModal:i,shouldFlip:s,shouldUpdatePosition:l,boundaryElement:p,crossOffset:c,offset:d||2,className:"BaselineUI-Menu-Popover",portalContainer:v,children:jsx(hs,{className:classNames(lt,a),...z,...y,ref:f,autoFocus:h.focusStrategy||"first",children:P})})]})});Va.displayName="Menu";var Ua=x({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:true,isDisabled:false},"_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 Gu=wt.forwardRef(({className:r,style:e,children:t,variant:o="default",size:a="md",elementType:n="a",type:i="body","data-block-id":s,"data-block-class":l,title:p,role:c,...d},m)=>{let u=wt.useRef(null),{linkProps:b,isPressed:y}=useLink({...d,elementType:d.onPress?"span":n},u),{isFocusVisible:f,isFocused:g,focusProps:v}=useFocusRing(),{hoverProps:h,isHovered:_}=useHover({isDisabled:d.isDisabled}),z=n,P=filterTruthyValues({"data-block-id":s,"data-block-class":l,"data-disabled":d.isDisabled,"data-focused":g,"data-pressed":y,"data-focus-visible":f,"data-hovered":_,role:c,title:p});return jsx(z,{...mergeProps(b,v,h,P),className:classNames(Ua({variant:o,isFocusVisible:f,isHovered:_,isDisabled:d.isDisabled,size:a,isActive:y,type:i}),"BaselineUI-Link",r),ref:M(u,m),style:e,children:t})});Gu.displayName="Link";function Ku({isDisabled:r,onValueChange:e,onChange:t,name:o,"aria-describedby":a,"aria-label":n,accept:i,multiple:s}){let l=useId(),p=useId(),c=useId();return {inputProps:{type:"file",id:p,disabled:!!r,"aria-labelledby":n?void 0:l,"aria-describedby":a||c,"aria-label":n,onChange:m=>{let u=[...m.target.files||[]];e?.(u),t?.(m);},name:o,accept:i,multiple:s},labelProps:{htmlFor:p,id:l},descriptionProps:{id:c}}}async function xs({items:r}){let e=r.filter(t=>t.kind==="file").map(async t=>(invariant(t.kind==="file"),t.getFile()));return await Promise.all(e)}var Wu=x({defaultClassName:"_180w5ed0",variantClassNames:{variant:{default:"_180w5ed1",inline:"_180w5ed2"},hoveredOrFocusedOrActive:{true:"_180w5ed3"},disabled:{true:"_180w5ed4"}},defaultVariants:{},compoundVariants:[[{variant:"inline",hoveredOrFocusedOrActive:true},"_180w5ed5"],[{variant:"default",hoveredOrFocusedOrActive:true},"_180w5ed6"],[{variant:"default",disabled:true},"_180w5ed7"],[{variant:"inline",disabled:true},"_180w5ed8"]]}),Yu=x({defaultClassName:"_180w5ede",variantClassNames:{disabled:{true:"_180w5edf"}},defaultVariants:{},compoundVariants:[]}),Zu=x({defaultClassName:"_180w5ed9",variantClassNames:{disabled:{true:"_180w5eda"}},defaultVariants:{},compoundVariants:[]}),Xu=x({defaultClassName:"_180w5edb",variantClassNames:{disabled:{true:"_180w5edc"},hovered:{true:"_180w5edd"}},defaultVariants:{},compoundVariants:[]});var tm=wt.forwardRef(({className:r,label:e,description:t,icon:o,variant:a="default",...n},i)=>{let s=wt.useRef(null),{inputProps:l,descriptionProps:p,labelProps:c}=Ku(n),{dropProps:d}=useDrop({ref:s,onDrop:async({items:f})=>{let g=f.filter(h=>h.kind==="file").map(async h=>(invariant(h.kind==="file"),h.getFile())),v=await Promise.all(g);n.onValueChange?.(v);}}),{focusProps:m,isFocusVisible:u}=useFocusRing(),{hoverProps:b,isHovered:y}=useHover({isDisabled:n.isDisabled});return jsxs("label",{...mergeProps(d,b,c),className:classNames(Wu({variant:a,disabled:n.isDisabled,hoveredOrFocusedOrActive:y||u}),r),ref:M(i,s),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(m,l)})}),o?jsx(o,{size:20,className:Zu({disabled:n.isDisabled})}):null,jsxs("div",{children:[jsx("div",{className:Xu({disabled:n.isDisabled,hovered:y}),children:e}),t?jsx("div",{...p,className:Yu({disabled:n.isDisabled}),children:t}):null]})]})});tm.displayName="FileUpload";var rm="_12vfhl40 z9nup81",om="_12vfhl41 z9nup82",am=x({defaultClassName:"_12vfhl48",variantClassNames:{variant:{success:"_12vfhl49",error:"_12vfhl4a",active:"_12vfhl4b"}},defaultVariants:{},compoundVariants:[]}),nm="_12vfhl42",im="_12vfhl47",sm="_12vfhl46 z9nup82",lm="_12vfhl45",pm=x({defaultClassName:"_12vfhl43 _12vfhl42",variantClassNames:{hasLabel:{false:"_12vfhl44"}},defaultVariants:{},compoundVariants:[]});var cm=wt.forwardRef(({className:r,style:e,variant:t="active",showValue:o,description:a,errorMessage:n,"data-block-id":i,"data-block-class":s,...l},p)=>{let c=useId(),{labelProps:d,progressBarProps:m}=useProgressBar({...l,"aria-describedby":a?c:l["aria-describedby"]}),{minValue:u=0,maxValue:b=100,value:y=0,label:f}=l,g=(y-u)/(b-u),v=`${Math.round(g*100)}%`,h=jsx("output",{className:pm({hasLabel:!!f}),children:m["aria-valuetext"]}),_=t==="error"?n:a;return jsxs("div",{...m,style:e,className:classNames(rm,"BaselineUI-ProgressBar",r),"data-block-id":i,"data-block-class":s,ref:p,children:[f?jsxs("div",{className:om,children:[jsx("label",{...d,className:nm,children:f}),o?h:null]}):null,jsxs("div",{className:lm,children:[jsxs("div",{className:sm,children:[jsx("div",{className:im,children:jsx("div",{style:{width:v},className:am({variant:t})})}),!f&&o?h:null]}),_?jsx("div",{className:Zt({hasError:t==="error"}),id:c,children:_}):null]})]})});cm.displayName="ProgressBar";function yr({isReadOnly:r,validationState:e}){return r?ReadOnlyIcon:e==="error"?ErrorCircleFilledIcon:e==="warning"?WarningFilledIcon$1:null}var $t=wt.forwardRef(({labelPosition:r="top",className:e,style:t,labelProps:o,isDisabled:a,isReadOnly:n,label:i,message:s,"data-block-id":l,validationState:p="valid",isFocused:c,variant:d="primary",children:m,fieldProps:u,wrapperRef:b,wrapperClassName:y,isInvalid:f},g)=>{let{hoverProps:v,isHovered:h}=useHover({isDisabled:a}),_=yr({isReadOnly:n,validationState:p});return jsxs("div",{className:classNames(at({labelPosition:r}),e),"data-block-id":l,style:t,ref:g,children:[i||r==="start"&&s?jsxs("div",{className:ot({labelPosition:r,hasMessage:!!s}),children:[jsx(D,{...o,elementType:"label",color:"text.secondary",typography:"label.md.medium",children:i}),r==="start"&&s]}):null,jsxs("div",{className:classNames({[tr]:a}),children:[jsxs("div",{...mergeProps(u,v),className:classNames(Qt({validationState:f?"error":p,isHovered:h,isFocused:c,variant:d,isReadOnly:n,isDisabled:a}),y),ref:b,children:[m,_?jsx(_,{className:Xt({validationState:p,isReadOnly:n}),size:16}):null]}),r==="top"&&s]})]})});$t.displayName="SharedInput";var pt=wt.forwardRef(({className:r,validationState:e,variant:t="primary",labelPosition:o="top",inputStyle:a,inputClassName:n,"data-block-id":i,"data-block-class":s,...l},p)=>{let c=wt.useRef(null),{inputProps:d,labelProps:m,descriptionProps:u,errorMessageProps:b,validationErrors:y}=useTextField({...l,validationState:e?e==="error"?"invalid":"valid":void 0},c),f=l.errorMessage||y.join(" "),g=ge({...l,errorMessage:f,descriptionProps:u,errorMessageProps:b,labelPosition:o});f&&(e="error");let{isFocused:v,focusProps:h,isFocusVisible:_}=useFocusRing(),z=filterTruthyValues({"data-readonly":l.isReadOnly,"data-disabled":l.isDisabled,"data-validation-state":e,"data-focused":v,"data-focus-visible":_});return jsx($t,{variant:t,labelProps:m,isFocused:v,message:g,ref:p,labelPosition:o,className:classNames("BaselineUI-TextInput",r),validationState:e,"data-block-id":i,"data-block-class":s,...l,children:jsx("input",{...mergeProps(d,h,z),className:classNames(ga({isDisabled:l.isDisabled,labelPosition:o}),"BaselineUI-TextInput-Input",n),style:a,ref:c})})});pt.displayName="TextInput";var br=({value:r,...e})=>{let t=useNumberFormatter(e);return jsx(Fragment,{children:t.format(r)})};br.displayName="NumberFormat";var ym="_1yep5z6iv _1yep5z6iw _1yep5z6ix",bm=x({defaultClassName:"_9b1tml0",variantClassNames:{isSelected:{true:"_9b1tml1",false:"_9b1tml2"},isDisabled:{true:"z9nup83"},isHovered:{true:"_9b1tml4"},isFocusVisible:{true:"_9b1tml5"},isReadOnly:{true:"_9b1tml6"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isFocusVisible:true,isReadOnly:false},"_9b1tml7"],[{isSelected:true,isHovered:true,isDisabled:false,isReadOnly:false},"_9b1tml8"],[{isSelected:false,isHovered:true,isDisabled:false,isReadOnly:false},"_9b1tml9"],[{isSelected:true,isDisabled:true},"_9b1tmla"],[{isSelected:true,isReadOnly:true},"_9b1tmlb"]]}),gm=x({defaultClassName:"_9b1tmlf _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6eu _1yep5z6la _1yep5z6e9",variantClassNames:{isSelected:{true:"_9b1tmlg"},size:{sm:"_9b1tmlh",md:"_9b1tmli"},isDisabled:{true:"_9b1tmlj"},isReadOnly:{true:"_1yep5z610x"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:false,isReadOnly:false},"_1yep5z61n6"],[{isSelected:true,isDisabled:true},"_1yep5z61n6"],[{isSelected:false,isDisabled:true},"_1yep5z61n4"]]}),vm=x({defaultClassName:"_9b1tmlc",variantClassNames:{isDisabled:{true:"_9b1tmld"},isReadOnly:{true:"_9b1tmle"}},defaultVariants:{},compoundVariants:[]});var zm=wt.forwardRef(({className:r,count:e,style:t,size:o="md",icon:a,"data-block-id":n,"data-block-class":i,...s},l)=>{let p={isRequired:false},c=a||(o==="md"?CheckmarkIcon$1:CheckmarkIcon$2);!s["aria-label"]&&!s["aria-labelledby"]&&console.warn("You must provide either an `aria-label` or `aria-labelledby` prop to the `Reaction` component.");let d=wt.useRef(null),m=useToggleState({...s,...p}),{inputProps:u,isPressed:b,isDisabled:y,isReadOnly:f,isSelected:g}=useSwitch({...s,...p},m,d),{focusProps:v,isFocused:h,isFocusVisible:_}=useFocusRing(),{hoverProps:z,isHovered:P}=useHover({}),w=filterTruthyValues({"data-block-id":n,"data-block-class":i,"data-focused":h,"data-focus-visible":_,"data-disabled":y,"data-hovered":P,"data-pressed":b,"data-selected":g});return jsxs("label",{ref:l,style:t,className:classNames(ym,"BaselineUI-Reaction",r),...w,children:[jsx(VisuallyHidden,{children:jsx("input",{...u,...v,ref:d})}),jsxs("div",{...z,className:bm({isSelected:g,isFocusVisible:_,isHovered:P,isReadOnly:f,isDisabled:y}),children:[jsx("div",{className:vm({isDisabled:y,isReadOnly:f}),children:jsx(c,{size:o==="md"?20:16})}),jsx("div",{className:gm({isSelected:m.isSelected,isDisabled:y,isReadOnly:f,size:o}),children:jsx(br,{value:e})})]})]})});zm.displayName="Reaction";var xm="_1azy5686",Cm="_1azy5685",Pm="var(--_1azy5680)",wm="_1azy5688",km="_1azy5689",Im="_1azy5681 z9nup82",Sm="_1azy5682";var Rm="_1azy5687";var xP={sm:16,md:20},CP={sm:[CheckmarkCircleFilledIcon,ErrorAltCircleFilledIcon$1],md:[CheckCircleFilledIcon,ErrorAltCircleFilledIcon]},vr=wt.forwardRef(({className:r,style:e,size:t="md",variant:o="active","data-block-id":a,"data-block-class":n,...i},s)=>{let{labelProps:l,progressBarProps:p}=useProgressBar({...i,isIndeterminate:true}),c=xP[t],d=c/2-2,m=2*d*Math.PI,u=CP[t][o==="success"?0:1];return jsxs("div",{className:classNames(Im,"BaselineUI-ProgressSpinner",r),ref:s,style:{...assignInlineVars({[Pm]:`${m}px`}),...e},"data-block-id":a,"data-block-class":n,children:[jsxs("div",{...p,className:Sm,children:[(o==="active"||o==="inactive")&&jsxs("svg",{height:c,width:c,viewBox:`0 0 ${c} ${c}`,children:[jsx("circle",{role:"presentation",className:xm,cx:c/2,cy:c/2,r:d}),o==="active"&&jsx("circle",{role:"presentation",className:Cm,cx:c/2,cy:c/2,r:d})]}),o==="success"&&jsx(u,{className:Rm,size:c}),o==="error"&&jsx(u,{className:wm,size:c})]}),i.label?jsx("span",{...l,className:km,children:i.label}):null]})});vr.displayName="ProgressSpinner";var Ka=x({defaultClassName:"_5uw3kp0 oom8bs0 z9nup82",variantClassNames:{isHovered:{true:"_5uw3kp1"},isFocusVisible:{true:"_5uw3kp2"},isDisabled:{true:"_5uw3kp3"},isSelected:{true:"_5uw3kp4"},size:{sm:"_5uw3kp5",md:"_5uw3kp6",lg:"_5uw3kp7"},variant:{primary:"_5uw3kp8",toolbar:"_5uw3kp9"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isFocusVisible:true},"_5uw3kpa"],[{isSelected:true,isDisabled:true},"_5uw3kpb"],[{variant:"primary",size:"lg"},"_5uw3kpc"]]}),$m=x({defaultClassName:"_5uw3kpd _1yep5z6f5",variantClassNames:{isDisabled:{true:"_1yep5z611a"},isSelected:{true:"_1yep5z611c"}},defaultVariants:{},compoundVariants:[]});var RP={sm:16,md:20,lg:24},Wa=wt.forwardRef(({className:r,style:e,iconStart:t,size:o="md",elementType:a="button",variant:n="toolbar",...i},s)=>{let l=useToggleState(i),{buttonProps:p,isPressed:c,ref:d,isFocusVisible:m,isFocused:u,isHovered:b,uiStateOptions:y}=fa(i,l),f=filterTruthyValues({"data-block-id":i["data-block-id"],"data-block-class":i["data-block-class"],"data-focused":u,"data-focus-visible":m,"data-disabled":i.isDisabled,"data-hovered":b,"data-pressed":c,"data-selected":l.isSelected});return jsxs(a,{...mergeProps(p,f),className:classNames(Ka({isHovered:b,isFocusVisible:m,isSelected:l.isSelected,size:o,isDisabled:i.isDisabled,variant:n}),"BaselineUI-ToggleButton",typeof r=="function"?r(y):r),style:typeof e=="function"?e(y):e,ref:M(d,s),children:[t?jsx(t,{size:RP[o],className:$m({isDisabled:i.isDisabled,isSelected:l.isSelected})}):null,i.label]})});Wa.displayName="ToggleButton";var Ya=x({defaultClassName:"_16vugd0f",variantClassNames:{isDisabled:{true:"_16vugd0g"}},defaultVariants:{},compoundVariants:[]}),Tm=x({defaultClassName:"_16vugd02 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{labelPosition:{end:"_1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z6vl _1yep5z6vm _1yep5z6vn",start:"_1yep5z615a _1yep5z615b _1yep5z615c _1yep5z616m _1yep5z616n _1yep5z616o"}},defaultVariants:{},compoundVariants:[]}),Dm=x({defaultClassName:"_16vugd06",variantClassNames:{isIndeterminate:{true:"_16vugd05"},isSelected:{true:"_16vugd05"},isFocusVisible:{true:"_16vugd09"},isHovered:{true:"_16vugd0a"},isDisabled:{true:"_16vugd0b"},isReadOnly:{true:"_16vugd0c"},hasError:{true:"_16vugd0d"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:true},"_16vugd0e"]]});var Nm=wt.forwardRef(({className:r,style:e,label:t,labelPosition:o="end","data-block-id":a,"data-block-class":n,...i},s)=>{let l=wt.useRef(null),p=useToggleState(i),{isFocusVisible:c,isFocused:d,focusProps:m}=useFocusRing(),{inputProps:u,isPressed:b,isDisabled:y,isSelected:f,isReadOnly:g}=useCheckbox({...i,children:t},p,l),{hoverProps:v,isHovered:h}=useHover({isDisabled:y}),_=filterTruthyValues({"data-disabled":y,"data-readonly":g,"data-hovered":h,"data-selected":f,"data-pressed":b,"data-indeterminate":i.isIndeterminate,"data-invalid":i.isInvalid,"data-focus-visible":c,"data-focused":d,"data-block-id":a,"data-block-class":n});return jsxs("label",{..._,className:classNames(Tm({labelPosition:o}),"BaselineUI-Checkbox",r),style:e,ref:s,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(u,m),ref:l})}),jsxs("div",{...v,className:Dm({isSelected:f&&!i.isIndeterminate,isIndeterminate:i.isIndeterminate,isFocusVisible:c,isDisabled:y,isReadOnly:g,hasError:i.isInvalid,isHovered:h}),children:[f&&!i.isIndeterminate?jsx(CheckmarkIcon$3,{size:12}):null,i.isIndeterminate?jsx(MinusIcon$1,{size:12}):null]}),t?jsx("span",{className:Ya({isDisabled:y}),children:t}):null]})});Nm.displayName="Checkbox";var Lm={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 Am=x({defaultClassName:"_1nsi9h17",variantClassNames:{isFocused:{true:"_1nsi9h18"},variant:{pinned:"_1nsi9h19",floating:"_1nsi9h1a"},size:{xs:"_1nsi9h1b",sm:"_1nsi9h1c",md:"_1nsi9h1d",lg:"_1nsi9h1e"}},defaultVariants:{},compoundVariants:[]}),Bm="_1nsi9h1f _1yep5z6ly _1yep5z6lq _1yep5z6eu",Om=x({defaultClassName:"_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6g1 _1yep5z6e1",variantClassNames:{size:{xs:"_1nsi9h11 _1yep5z6wl _1yep5z6wm _1yep5z6wn _1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6xx _1yep5z6xy _1yep5z6xz _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z6zy",sm:"_1nsi9h12 _1yep5z6101",md:"_1nsi9h13",lg:"_1nsi9h14"},variant:{floating:"_1yep5z6za _1yep5z6184 _1yep5z6182 _1yep5z6136",pinned:"_1yep5z617q"}},defaultVariants:{},compoundVariants:[]}),Fm=x({defaultClassName:"_1nsi9h1g _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6111"}},defaultVariants:{},compoundVariants:[]});var aw={style:"decimal"},nw={xs:[CaretLeftIcon$3,CaretRightIcon$3],sm:[CaretLeftIcon$2,CaretRightIcon$2],md:[CaretLeftIcon$1,CaretRightIcon$1],lg:[CaretLeftIcon,CaretRightIcon]},qm=wt.forwardRef(({className:r,style:e,minValue:t=1,defaultValue:o=1,incrementAriaLabel:a,decrementAriaLabel:n,"aria-label":i,size:s="md",variant:l="floating",hideActions:p,isDisabled:c,...d},m)=>{let{locale:u}=useLocale(),b=A(Lm),y={...d,formatOptions:aw,minValue:t,incrementAriaLabel:a||b.formatMessage("nextPage"),decrementAriaLabel:n||b.formatMessage("prevPage"),defaultValue:o,"aria-label":i||b.formatMessage("goToPage")},f=wt.useRef(null),g=useNumberFieldState({...y,locale:u}),{inputProps:v,decrementButtonProps:h,incrementButtonProps:_,groupProps:z}=useNumberField({...y,onKeyDown:O=>{O.key==="Enter"&&f.current?.blur(),d.onKeyDown?.(O);},isDisabled:c},g,f),{hoverProps:P,isHovered:w}=useHover({}),{focusProps:C,isFocused:k,isFocusVisible:$}=useFocusRing(),R=l==="floating",[T,I]=nw[s],S=filterTruthyValues({"data-focus-visible":$,"data-focused":k,"data-hovered":w,"data-block-id":d["data-block-id"],"data-block-class":d["data-block-class"]}),N=useInteractionModality()==="keyboard";return jsxs("div",{...mergeProps(z,P,S),className:classNames(Om({size:s,variant:l}),"BaselineUI-Pagination",r),style:e,ref:m,children:[p?null:jsxs(Fragment,{children:[jsx(L,{icon:T,...h,elementType:"div",size:s,style:{height:"100%",...R&&{borderRadius:0}},className:"BaselineUI-Pagination-DecrementButton",UNSAFE_NON_INTERACTIVE:N,isDisabled:c||h.isDisabled}),l==="floating"&&jsx(U,{orientation:"vertical"})]}),jsxs("div",{className:Am({isFocused:k,variant:l,size:s}),"aria-label":b.formatMessage("pageXofY",{arg0:v.value,arg1:g.maxValue}),children:[jsx("input",{...mergeProps(v,C),ref:f,className:classNames("BaselineUI-Pagination-Input",Bm),style:{width:`${v.value?.toString().length||1}ch`}}),jsxs("span",{className:Fm({isDisabled:c}),children:["/ ",jsx(br,{value:g.maxValue})]})]}),p?null:jsxs(Fragment,{children:[l==="floating"&&jsx(U,{orientation:"vertical"}),jsx(L,{icon:I,..._,elementType:"div",size:s,style:{height:"100%",...R&&{borderRadius:0}},className:"BaselineUI-Pagination-IncrementButton",UNSAFE_NON_INTERACTIVE:N,isDisabled:c||_.isDisabled})]})]})});qm.displayName="Pagination";var Gm=({date:r,...e})=>{let t=useDateFormatter(e);return jsx(Fragment,{children:t.format(r)})};Gm.displayName="DateFormat";var go=x({defaultClassName:"_1f789qjm",variantClassNames:{variant:{neutral:"_1yep5z6118",red:"_1yep5z610i",green:"_1yep5z610m",blue:"_1yep5z610u","high-contrast":"_1yep5z611b"},isDisabled:{true:"_1yep5z61nd"},isSelected:{true:"_1yep5z611c"}},defaultVariants:{},compoundVariants:[]}),Za=x({defaultClassName:"_1f789qj0 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ax _1yep5z6ay _1yep5z6az _1yep5z6bl _1yep5z6bm _1yep5z6bn _1yep5z6c9 _1yep5z6ca _1yep5z6cb _1yep5z6cx _1yep5z6cy _1yep5z6cz _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6la _1yep5z6lq _1yep5z6ld",variantClassNames:{isFocusVisible:{true:"_1f789qj1"},variant:{neutral:"_1yep5z6128",red:"_1yep5z611n",green:"_1yep5z611r",blue:"_1yep5z611z","high-contrast":"_1yep5z612c"},isDisabled:{true:"_1f789qj7 _1yep5z6127"},allowsRemoving:{true:"_1f789qj8"},isSelected:{true:"_1yep5z612i"},allowsSelection:{true:"_1f789qja"},isHovered:{true:"_1f789qjb"},size:{md:"_1f789qjc",sm:"_1f789qjd"}},defaultVariants:{},compoundVariants:[[{allowsSelection:true,isHovered:true,variant:"neutral"},"_1yep5z61oa"],[{allowsSelection:true,isHovered:true,variant:"red"},"_1yep5z61np"],[{allowsSelection:true,isHovered:true,variant:"blue"},"_1yep5z61o1"],[{allowsSelection:true,isHovered:true,variant:"green"},"_1yep5z61nt"],[{allowsSelection:true,isHovered:true,variant:"high-contrast"},"_1yep5z61oe"],[{allowsSelection:true,isSelected:true,isHovered:true},"_1yep5z61om"],[{variant:"high-contrast",isDisabled:true},"_1yep5z61oa"],[{allowsRemoving:true,size:"md"},"_1yep5z619c _1yep5z619d _1yep5z619e"],[{allowsRemoving:true,size:"sm"},"_1yep5z61af _1yep5z61ag _1yep5z61ah"]]}),Km="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69f _1yep5z69g _1yep5z69h",Wm="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z69i _1yep5z69j _1yep5z69k",Ym=x({defaultClassName:"_1f789qju",variantClassNames:{variant:{neutral:"_1f789qjv",red:"_1f789qjw",green:"_1f789qjx",blue:"_1f789qjy","high-contrast":"_1f789qjz"},isHovered:{true:"_1f789qj10"}},defaultVariants:{},compoundVariants:[[{isHovered:true,variant:"neutral"},"_1f789qj11"],[{isHovered:true,variant:"red"},"_1f789qj12"],[{isHovered:true,variant:"blue"},"_1f789qj13"],[{isHovered:true,variant:"green"},"_1f789qj14"],[{isHovered:true,variant:"high-contrast"},"_1f789qj15"]]}),Xa=x({defaultClassName:"_1f789qje",variantClassNames:{variant:{neutral:"_1yep5z610x",red:"_1yep5z610i",green:"_1yep5z610m",blue:"_1yep5z610u","high-contrast":"_1yep5z6112"},isDisabled:{true:"_1yep5z61n4"},isSelected:{true:"_1yep5z6113"}},defaultVariants:{},compoundVariants:[]});var Qm=({item:r,state:e,variant:t="neutral",size:o="md"})=>{let a=wt.useRef(null),{focusProps:n,isFocusVisible:i}=useFocusRing({within:true}),{rowProps:s,gridCellProps:l,removeButtonProps:p,allowsRemoving:c,isDisabled:d,isSelected:m,allowsSelection:u}=useTag({item:r},e,a),b=wt.useRef(null),{buttonProps:y}=useButton(p,b),{hoverProps:f,isHovered:g}=useHover({isDisabled:d}),{hoverProps:v,isHovered:h}=useHover({isDisabled:d}),_=r.value?.icon,z=r.value?.data?.variant??t,P=o==="md"?XIcon$1:XIcon$3,w=o==="md"?CheckmarkIcon$2:CheckmarkIcon$3;return jsx("div",{...mergeProps(s,n,v),ref:a,className:classNames(Za({isFocusVisible:i,variant:z,isDisabled:d,allowsRemoving:c,isSelected:m,allowsSelection:u,isHovered:h,size:o}),Xa({variant:z,isDisabled:d,isSelected:m}),"BaselineUI-Tag"),children:jsxs("div",{...l,className:Km,children:[m?jsx(w,{size:o==="md"?16:12,className:classNames(go({variant:z,isDisabled:d,isSelected:m}),"BaselineUI-Tag-Icon")}):null,!m&&_?jsx(_,{size:o==="md"?16:12,className:classNames(go({variant:z,isDisabled:d,isSelected:m}),"BaselineUI-Tag-Icon")}):null,jsx(D,{paddingY:o==="md"?"sm":"none",typography:o==="sm"?"label.sm.medium":"label.md.medium",children:r.rendered}),c?jsx("button",{...mergeProps(y,f),className:Ym({variant:z,isHovered:g}),children:jsx(P,{size:o==="md"?12:8})}):null]})})};var rf=wt.forwardRef(({className:r,style:e,"data-block-id":t,"data-block-class":o,items:a,size:n="md",...i},s)=>{let l=useMemo(()=>a.map(u=>({...u,data:{variant:u.variant}})),[a]),p=pe(),c=wt.useRef(null),d=useListState({...i,items:l,children:p}),{gridProps:m}=useTagGroup(i,d,c);return jsx("div",{...m,className:classNames(Wm,"BaselineUI-TagGroup",r),style:e,"data-block-id":t,"data-block-class":o,ref:M(s,c),children:[...d.collection].map(u=>jsx(Qm,{state:d,item:u,variant:i.variant,size:n},u.key))})});rf.displayName="TagGroup";var of="_1yep5z6ln",af=x({defaultClassName:"_1kvz17db _1yep5z6la _1yep5z6lc",variantClassNames:{showActionsOnTriggerOnly:{true:"_1kvz17dc"},isTriggered:{true:"_1kvz17dd"}},defaultVariants:{},compoundVariants:[]}),nf=x({defaultClassName:"_1kvz17d0 _1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z68c _1yep5z68d _1yep5z68e _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6la _1yep5z6lb",variantClassNames:{isExpanded:{true:"_1kvz17d1"}},defaultVariants:{},compoundVariants:[]}),sf="_1kvz17de",lf="_1yep5z6ev _1yep5z6dy",pf=x({defaultClassName:"_1kvz17d2 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6la _1yep5z6ld",variantClassNames:{isFocusVisible:{true:"_1kvz17d3"},isHovered:{true:"_1yep5z6g2",false:"_1yep5z6g3"},isDisabled:{true:"z9nup83"}},defaultVariants:{},compoundVariants:[]}),cf="_1kvz17da _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6dz",df=x({defaultClassName:"_1kvz17d7 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{isDisabled:{true:"_1yep5z6ey",false:"_1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var Is=wt.forwardRef(({children:r,className:e,style:t},o)=>{let{headers:a}=useContext(ct),{disabledKeys:n}=useContext(ct),{keyboardProps:i}=useKeyboard({onKeyDown:s=>{let l=be(s.target),p=l?Qo(l):Qo(),c=[...a?.keys()||[]].findIndex(y=>a?.get(y)?.current===p),d=a?.get(c||0),m=a?.size||0,u=y=>{let f=a.get(y-1<0?m-1:y-1);n?.has(f?.current?.getAttribute("data-key")||"")?u(y-1):f?.current?.focus();},b=y=>{let f=a.get((y+1)%m);n?.has(f?.current?.getAttribute("data-key")||"")?b(y+1):f?.current?.focus();};if(d)switch(s.key){case "Home":{s.preventDefault(),b(-1);break}case "End":{s.preventDefault(),u(m);break}case "ArrowDown":{s.preventDefault(),b(c);break}case "ArrowUp":{s.preventDefault(),u(c);break}default:s.continuePropagation();}}});return jsx("div",{...i,style:t,className:classNames(of,e),ref:o,children:wt.Children.map(r,(s,l)=>wt.cloneElement(s,{index:l}))})});Is.displayName="AccordionBase";var ct=wt.createContext({expandedKeys:new Set,setExpandedKeys:()=>{},disabledKeys:new Set,headers:new Map,expansionMode:"multiple"}),ff=wt.forwardRef(({children:r,disabledKeys:e,defaultExpandedKeys:t=new Set,expandedKeys:o,expansionMode:a="multiple",onChange:n,className:i,style:s},l)=>{let[p,c]=wt.useState(t),d=wt.useRef(new Map).current,[m,u]=wt.useState(a);useEffect(()=>{u(a);},[a]),useEffect(()=>{n?.(p);},[p,n]);let b=useMemo(()=>({expandedKeys:o||p,setExpandedKeys:o?()=>{}:c,disabledKeys:e,headers:d,expansionMode:m}),[o,p,e,d,m]);return jsx(ct.Provider,{value:b,children:jsx(FocusScope,{children:jsx(Is,{className:i,style:s,ref:l,children:r})})})});ff.displayName="Accordion";var Rs=wt.forwardRef(({title:r,actions:e,controlId:t,value:o,id:a,index:n,subLabel:i,showActionsOnTriggerOnly:s},l)=>{let p=wt.useRef(null),{expandedKeys:c,setExpandedKeys:d,expansionMode:m,disabledKeys:u,headers:b}=useContext(ct),y=u?.has(o),f=useFocusManager();invariant(f);let{focusNext:g,focusPrevious:v}=f,{keyboardProps:h}=useKeyboard({onKeyDown:S=>{S.key==="ArrowRight"?g({wrap:true}):S.key==="ArrowLeft"?v({wrap:true}):S.continuePropagation();},isDisabled:y});useEffect(()=>{invariant(typeof n=="number","AccordionItem must have an index"),b?.set(n,p);},[n,b]);let _=()=>{d(S=>{let E=new Set(S);return E.has(o)?E.delete(o):(m==="single"&&E.clear(),E.add(o)),E});},{buttonProps:z}=useButton({"aria-expanded":c.has(o),"aria-controls":t,onPress:_,isDisabled:y},p),{pressProps:P}=usePress({onPress:_,isDisabled:y}),{focusProps:w,isFocusVisible:C}=useFocusRing(),{hoverProps:k,isHovered:$}=useHover({isDisabled:y}),{focusProps:R,isFocusVisible:T}=useFocusRing({within:true}),I=c.has(o);return jsxs("h3",{...mergeProps(h,P,k,R),className:pf({isFocusVisible:C,isHovered:$,isDisabled:y}),ref:l,children:[jsxs("div",{className:df({isDisabled:!!y}),children:[jsx(ChevronRightIcon,{className:nf({isExpanded:I}),size:8}),jsx("button",{...mergeProps(z,w),id:a,"data-key":o,className:cf,ref:p,children:r})]}),e?.length?jsx("div",{"data-testid":"action-buttons",className:af({showActionsOnTriggerOnly:s,isTriggered:T||$}),children:e.map((S,E)=>jsx(L,{variant:"secondary",size:"sm",excludeFromTabOrder:true,isDisabled:y,...S},E))}):null,i?jsx("div",{className:lf,children:i}):null]})});Rs.displayName="AccordionHeader";var zf=wt.forwardRef(({title:r,actions:e,children:t,value:o,index:a,subLabel:n,style:i,className:s,showActionsOnTriggerOnly:l},p)=>{let c=useId(),d=useId(),{expandedKeys:m}=useContext(ct),u=m.has(o);return jsxs(Fragment,{children:[jsx(FocusScope,{children:jsx(Rs,{value:o,actions:e,id:d,title:r,controlId:c,ref:p,index:a,subLabel:n,showActionsOnTriggerOnly:l})}),jsx(AnimatePresence,{initial:false,children:u?jsx(motion.section,{role:"region","aria-labelledby":d,id:c,className:sf,variants:{open:{height:"auto",opacity:1},closed:{height:0,opacity:0}},initial:"closed",animate:"open",exit:"closed",children:jsx("div",{style:i,className:s,children:t})}):null})]})});zf.displayName="AccordionItem";var zo=wt.forwardRef(({variant:r,isOpen:e,selectedIcon:t,validationState:o="valid",valueProps:a,label:n,className:i,style:s,"data-block-id":l,"data-block-class":p,...c},d)=>{let m=wt.useRef(null),{buttonProps:u,isPressed:b}=useButton({...c,isDisabled:c.isDisabled||c.isReadOnly},m),{hoverProps:y,isHovered:f}=useHover({isDisabled:c.isDisabled}),{focusProps:g,isFocused:v,isFocusVisible:h}=useFocusRing(),_=yr({isReadOnly:c.isReadOnly,validationState:o});c.isReadOnly&&(u.disabled=false);let z=filterTruthyValues({"data-disabled":c.isDisabled,"data-readonly":c.isReadOnly,"data-focused":v,"data-focus-visible":h,"data-hovered":f,"data-pressed":b,"data-open":e,"data-block-id":l,"data-block-class":p});return jsxs("button",{...mergeProps(u,y,g,z),ref:M(d,m),className:classNames(ju({isFocused:h,isDisabled:c.isDisabled,isOpen:e,isHovered:f,variant:r}),Qt({variant:r,isHovered:f,isFocused:h,validationState:o,isDisabled:!!c.isDisabled,isReadOnly:c.isReadOnly}),i,"BaselineUI-Select-Button"),style:s,children:[jsxs("span",{className:Vu,children:[t?jsx(t,{size:24}):null,jsx("span",{...a,children:n})]}),_?jsx("span",{"aria-hidden":true,className:classNames(Xt({validationState:o,isReadOnly:!!c.isReadOnly}),Hu),children:jsx(_,{size:16})}):null,jsx("span",{"aria-hidden":true,children:jsx(CaretDownIcon,{size:8,className:Fu({isOpen:e})})})]})});zo.displayName="SelectButton";var Ja=wt.createContext({state:null,popoverAnchorRef:null}),Ts=wt.forwardRef(({className:r,style:e,labelPosition:t="top",variant:o="primary","data-block-id":a,"data-block-class":n,optionStyle:i,optionClassName:s,placement:l="bottom start",triggerClassName:p,triggerStyle:c,state:d,renderTrigger:m=({buttonProps:y,selectedValue:f,valueProps:g,isOpen:v,ref:h})=>{let _=f&&"icon"in f&&f.icon;return jsx(zo,{...y,className:p,style:c,isOpen:v,isReadOnly:u.isReadOnly,ref:h,variant:o,validationState:u.validationState,selectedIcon:_||void 0,label:f?"label"in f&&f?.label:u.placeholder,valueProps:g})},...u},b)=>{let{popoverAnchorRef:y}=useContext(Ja),f=wt.useRef(null),g=ve(u.portalContainer),{labelProps:v,triggerProps:h,valueProps:_,menuProps:z,descriptionProps:P,errorMessageProps:w}=useSelect({...u,validationState:u.validationState==="error"?"invalid":"valid"},d,f),C=ge({...u,descriptionProps:P,errorMessageProps:w,labelPosition:t}),k=d.selectedItem?.value??null;return jsxs(kt.Provider,{value:d,children:[jsxs("div",{style:e,className:classNames(at({labelPosition:t}),"BaselineUI-Select",r),"data-block-id":a,"data-block-class":n,ref:b,children:[u.label||C?jsxs("div",{className:ot({labelPosition:t,hasMessage:!!C}),children:[u.label?jsx("div",{...v,className:classNames(Jt,"BaselineUI-Select-Label"),children:u.label}):null,t==="start"&&C]}):null,jsx(HiddenSelect,{state:d,triggerRef:f,isDisabled:u.isDisabled,label:u.label,name:u.name}),m({buttonProps:h,selectedValue:k,valueProps:_,isOpen:d.isOpen,ref:f}),t==="top"&&C]}),d?jsx(we,{placement:l,portalContainer:g,offset:2,state:d,triggerRef:y||f,style:e,className:"BaselineUI-Select-Popover",...u,children:jsx(me,{...z,label:u.label,items:u.items,showSelectedIcon:u.showSelectedIcon,className:lt,optionStyle:i,optionClassName:s})}):null]})});Ts.displayName="SelectCore";var If=wt.forwardRef((r,e)=>{let t=pe(),o=useSelectState({...r,validationState:r.validationState==="error"?"invalid":"valid",children:t});return jsx(Ts,{...r,ref:e,state:o})});If.displayName="SelectStandalone";var ut=wt.forwardRef((r,e)=>{let{state:t}=useContext(Ja);return useEffect(()=>{invariant(t||r.items,"Select: A `state` that can be passed via context or `items` are required.");},[r.items,t]),t?jsx(Ts,{state:t,...r,ref:e}):jsx(If,{...r,ref:e})});ut.displayName="Select";var Rf=wt.forwardRef(({className:r,style:e,variant:t,"data-block-id":o,icon:a,tooltipProps:n,...i},s)=>{let l=wt.useRef(null),p=useCallback(({buttonProps:c,selectedValue:d,valueProps:m,isOpen:u,ref:b})=>{let y=d&&"icon"in d&&d.icon;return jsx(ie,{variant:"inverse",size:"sm",includeArrow:false,text:i["aria-label"],offset:4,...n,children:jsx(zo,{...c,isOpen:u,isReadOnly:i.isReadOnly,ref:b,variant:t,validationState:i.validationState,selectedIcon:y||void 0,label:d?"label"in d&&d?.label:i.placeholder,valueProps:m})})},[i,n,t]);return jsxs(D,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:classNames("BaselineUI-IconSelect",r),"data-block-id":o,style:e,ref:M(s,l),children:[a?jsx(a,{"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary",display:"flex",flexShrink:0})}):null,jsx(ut,{...i,renderTrigger:p})]})});Rf.displayName="IconSelect";var $f="_1017q4c5",Tf=x({defaultClassName:"_1017q4c0",variantClassNames:{size:{md:"_1017q4c1",sm:"_1017q4c2"},isDisabled:{true:"_1017q4c3"}},defaultVariants:{},compoundVariants:[]}),Df="_1017q4c4";var i2={sm:AvatarIcon$1,md:AvatarIcon},xr=wt.forwardRef(({className:r,style:e,size:t="md",icon:o=i2[t],name:a,imgSrc:n,showInitials:i,isDisabled:s,hasNotifications:l,imgLoading:p,"data-block-id":c,"data-block-class":d},m)=>{let{imgProps:u}=er({src:n,alt:a}),b=a?.split(" ").map(y=>y[0]).join("");return jsxs("span",{className:classNames(Tf({size:t,isDisabled:s}),"BaselineUI-Avatar",r),"data-disabled":s,ref:m,style:e,"aria-disabled":s,"data-block-id":c,"data-block-class":d,children:[n?jsx("img",{...u,loading:p,className:Df}):null,!i&&!n&&jsx(o,{size:t==="sm"?16:24}),i&&!n?t==="sm"?b[0]:b:null,l?jsx("div",{"data-testid":"notification",className:$f}):null]})});xr.displayName="Avatar";var Mf="_1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",Ef=x({defaultClassName:"_1x62fhb6 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6la _1yep5z6ld _1yep5z6ev _1yep5z69i _1yep5z69j _1yep5z69k",variantClassNames:{isHovered:{true:"_1yep5z610x"},isSelected:{true:"_1x62fhb8"},isFocusVisible:{true:"_1x62fhb9"},isDisabled:{true:"_1x62fhba _1yep5z6111"},variant:{primary:"_1x62fhbb _1yep5z6zy",ghost:"_1yep5z6101"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:true,isDisabled:false},"_1yep5z61n0"],[{variant:"primary",isSelected:true},"_1yep5z61o7"],[{variant:"ghost",isSelected:true,isFocusVisible:false},"_1x62fhbd"],[{variant:"ghost",isSelected:true,isDisabled:false},"_1yep5z61n7"],[{variant:"ghost",isDisabled:true,isSelected:true},"_1x62fhbe _1yep5z6ey"],[{variant:"primary",isHovered:true},"_1yep5z61o8"]]}),Nf=x({defaultClassName:"_1x62fhb3 _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",variantClassNames:{variant:{primary:"_1x62fhb4",ghost:"_1yep5z6vl _1yep5z6vm _1yep5z6vn"}},defaultVariants:{},compoundVariants:[]}),Lf="_1x62fhbl",Ms=x({defaultClassName:"_1x62fhbf _1yep5z6f6",variantClassNames:{isHovered:{true:"_1yep5z6118"},isSelected:{true:"_1x62fhbh"},isDisabled:{true:"_1yep5z611a"},variant:{primary:"_1x62fhbj",ghost:"_1x62fhbk"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:true,isDisabled:false},"_1yep5z61nb"],[{variant:"ghost",isSelected:true,isDisabled:false},"_1yep5z61ng"],[{variant:"ghost",isDisabled:true,isSelected:true},"_1yep5z61nd"]]}),Af="_1yep5z6lu _1yep5z6lr _1yep5z6hx _1yep5z6lt",Bf=x({defaultClassName:"_1x62fhb0 _1yep5z6ln _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",variantClassNames:{variant:{primary:"_1yep5z6126",ghost:"_1x62fhb2"}},defaultVariants:{},compoundVariants:[]});var Of=({state:r,...e})=>{let t=wt.useRef(null),{tabPanelProps:o}=useTabPanel(e,r,t),{selectedItem:a}=r,{focusProps:n,isFocusVisible:i}=useFocusRing();if(!a?.value)return null;let{className:s,style:l,"data-block-id":p}=a.value;return jsx("div",{...mergeProps(o,n),ref:t,className:classNames({[Af]:i},"Baseline-Tabs-TabPanel",s),"data-block-id":p,style:l,children:a?.props.children})};var Ls=wt.forwardRef(({className:r,style:e,tabHeaderStyle:t,tabHeaderClassName:o,variant:a="primary",actions:n,onRemove:i,"data-block-id":s,...l},p)=>{let c=useTabListState({...l,selectedKey:l.selectedValue,defaultSelectedKey:l.defaultSelectedValue,disabledKeys:l.disabledValues}),d=wt.useRef(null),{tabListProps:m}=useTabList({...l,selectedKey:l.selectedValue,defaultSelectedKey:l.defaultSelectedValue,disabledKeys:l.disabledValues},c,d);return jsxs("div",{className:classNames("BaselineUI-Tabs",r),style:e,ref:p,"data-block-id":s,children:[jsxs("div",{className:classNames(Bf({variant:a}),o),style:t,children:[jsx("div",{...m,className:Nf({variant:a}),ref:d,children:[...c.collection].map(u=>(invariant(u.value,"TabItem requires a value prop"),jsx(jf,{item:u,state:c,onRemove:i,variant:a},u.key)))}),n?.map((u,b)=>jsx("div",{className:Mf,children:jsx(L,{...u,variant:"secondary",size:"sm",className:classNames(Lf,u.className)})},b))]}),jsx(Of,{state:c},c.selectedItem?.key)]})});Ls.displayName="TabsBase";var jf=({item:r,onRemove:e,state:t,variant:o})=>{let{key:a,value:n}=r,i=wt.useRef(null),{tabProps:s,isSelected:l,isDisabled:p}=useTab({key:a},t,i),{hoverProps:c,isHovered:d}=useHover({});invariant(n,"TabButton requires a value prop");let{title:m,icon:u,titleStyle:b,titleClassName:y}=n,{focusProps:f,isFocusVisible:g,isFocused:v}=useFocusRing(),{keyboardProps:h}=useKeyboard({onKeyDown:z=>{z.key==="Backspace"&&e?e(a):z.continuePropagation();}}),_=filterTruthyValues({"data-selected":l,"data-disabled":p,"data-focused":v,"data-hovered":d,"data-focus-visible":g});return jsxs("div",{...mergeProps(h,s,c,f,_),className:classNames(Ef({isHovered:d,isSelected:l,isFocusVisible:g,isDisabled:p,variant:o}),"BaselineUI-Tabs-TabButton",y),style:b,ref:i,children:[u?jsx(u,{size:20,className:Ms({isHovered:d,isSelected:l,isDisabled:p,variant:o})}):null,m,e?jsx(L,{variant:"secondary",elementType:"div",icon:XIcon$3,size:"xxs",onPress:()=>{e(a);},excludeFromTabOrder:true,UNSAFE_NON_INTERACTIVE:true,style:{display:"inline-flex",opacity:l||v||d?1:0},className:Ms({isHovered:d,isSelected:l,isDisabled:p,variant:o})}):null]})};jf.displayName="TabButton";var Vf=wt.forwardRef(function({children:e,...t},o){let a=useMemo(()=>wt.Children.map(e,n=>!n||!wt.isValidElement(n)||typeof n.type=="string"?null:{...n.props,id:n.props.value}).filter(Boolean),[e]);return jsx(Ls,{...t,ref:o,items:a,children:n=>jsx(Item,{title:n.title,children:n.children},n.key)})});Vf.displayName="Tabs";var Uf=({children:r,title:e,value:t})=>(invariant(t,"TabItem requires a value prop"),invariant(e,"TabItem requires a title prop"),invariant(r,"TabItem requires children"),r);Uf.displayName="TabItem";var qf={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 Gf=x({defaultClassName:"kfun6yt _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6af _1yep5z6ag _1yep5z6ah",variantClassNames:{arrangement:{single:"_1yep5z6vi _1yep5z6vj _1yep5z6vk",multi:"_1yep5z6157 _1yep5z6158 _1yep5z6159",compact:"_1yep5z6157 _1yep5z6158 _1yep5z6159"}},defaultVariants:{},compoundVariants:[]}),Kf=x({defaultClassName:"kfun6y0 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ln",variantClassNames:{variant:{info:"_1yep5z611y",warning:"_1yep5z611u",error:"_1yep5z611m",success:"_1yep5z611q"},arrangement:{single:"kfun6y5 _1yep5z616m _1yep5z616n _1yep5z616o _1yep5z615m _1yep5z615n _1yep5z615o",multi:"kfun6y6",compact:"kfun6y7 _1yep5z6mc _1yep5z6md _1yep5z6me _1yep5z6oo _1yep5z6op _1yep5z6oq _1yep5z6pu _1yep5z6pv _1yep5z6pw _1yep5z6ni _1yep5z6nj _1yep5z6nk _1yep5z615d _1yep5z615e _1yep5z615f _1yep5z6wi _1yep5z6wj _1yep5z6wk"},hasButton:{true:"kfun6y8"},hasCloseButton:{true:"kfun6y9"}},defaultVariants:{},compoundVariants:[[{hasButton:false,arrangement:"single"},"_1yep5z618f _1yep5z618g _1yep5z618h _1yep5z61ar _1yep5z61as _1yep5z61at _1yep5z61bx _1yep5z61by _1yep5z61bz _1yep5z619l _1yep5z619m _1yep5z619n"],[{hasButton:true,arrangement:"compact"},"_1yep5z618f _1yep5z618g _1yep5z618h _1yep5z61ar _1yep5z61as _1yep5z61at _1yep5z61bx _1yep5z61by _1yep5z61bz _1yep5z619l _1yep5z619m _1yep5z619n"],[{hasCloseButton:true,arrangement:"compact"},"_1yep5z61af _1yep5z61ag _1yep5z61ah _1yep5z6199 _1yep5z619a _1yep5z619b"]]}),Wf=x({defaultClassName:"kfun6yq _1yep5z6eu",variantClassNames:{size:{sm:"_1yep5z6106",md:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Yf=x({defaultClassName:"kfun6ym _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{arrangement:{single:"kfun6yn",multi:"_1yep5z615j _1yep5z615k _1yep5z615l",compact:"_1yep5z6n6 _1yep5z6n7 _1yep5z6n8 _1yep5z6pi _1yep5z6pj _1yep5z6pk _1yep5z6qo _1yep5z6qp _1yep5z6qq _1yep5z6oc _1yep5z6od _1yep5z6oe _1yep5z6161 _1yep5z6162 _1yep5z6163"}},defaultVariants:{},compoundVariants:[]}),Zf=x({defaultClassName:"kfun6yh _1yep5z6lk",variantClassNames:{variant:{info:"_1yep5z610t",warning:"_1yep5z610p",error:"_1yep5z610h",success:"_1yep5z610l"}},defaultVariants:{},compoundVariants:[]}),Xf=x({defaultClassName:"kfun6ye _1yep5z6eu",variantClassNames:{size:{sm:"_1yep5z6108",md:"_1yep5z610b"}},defaultVariants:{},compoundVariants:[]}),Jf=x({defaultClassName:"kfun6ya _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",variantClassNames:{arrangement:{single:"_1yep5z615m _1yep5z615n _1yep5z615o",multi:"_1yep5z6r0 _1yep5z6r1 _1yep5z6r2 _1yep5z6tc _1yep5z6td _1yep5z6te",compact:"_1yep5z6157 _1yep5z6158 _1yep5z6159"}},defaultVariants:{},compoundVariants:[]});var A2={error:{sm:ErrorAltCircleFilledIcon$1,md:ErrorAltCircleFilledIcon},info:{sm:InfoCircleFilledIcon$1,md:InfoCircleFilledIcon},success:{sm:CheckmarkCircleFilledIcon,md:CheckCircleFilledIcon},warning:{sm:WarningFilledIcon$1,md:WarningFilledIcon}},rn=wt.forwardRef(({className:r,description:e,actionLabel:t,onAction:o,style:a,variant:n="info",title:i,arrangement:s="single",onClose:l,size:p="sm","data-block-id":c,"data-block-class":d,elementProps:m},u)=>{let b=A(qf),y=t&&jsx(K,{variant:s==="compact"?"tertiary":"ghost",label:t,onPress:o}),f=A2[n][p];return jsxs("div",{className:classNames(Kf({variant:n,arrangement:s,hasButton:!!t||!!l,hasCloseButton:!!l}),"BaselineUI-InlineAlert",r),"data-block-id":c,"data-block-class":d,style:a,role:"alert",ref:u,...m?.root,children:[jsxs("div",{className:Jf({arrangement:s}),children:[jsx(f,{className:Zf({variant:n}),size:16}),jsxs("div",{className:Gf({arrangement:s}),...m?.content,children:[jsx("h3",{className:Xf({size:p}),...m?.title,children:i}),jsx("section",{className:Wf({size:p}),...m?.description,children:e})]}),s==="compact"&&y]}),jsxs("div",{className:Yf({arrangement:s}),children:[s!=="compact"&&y,l?jsx(L,{variant:"secondary",icon:XIcon$2,size:"sm",onPress:l,"aria-label":b.formatMessage("close"),...m?.close}):null]})]})});rn.displayName="InlineAlert";var mt={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 on=({children:r})=>{let{triggerProps:e}=wt.useContext(St);return jsx(PressResponder,{...e,children:r})};on.displayName="ModalTrigger";var U2=({children:r})=>{let{state:e}=wt.useContext(St);return jsx(PressResponder,{onPress:()=>{e?.close();},children:r})};var Qf="_1dbkl53 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6ln",ey="_1dbkl5e",ty=x({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 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6ly _1yep5z6lq _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6lp _1yep5z6dy",variantClassNames:{isHovered:{true:"_1dbkl55"},isFocusVisible:{true:"_1dbkl56"},isDisabled:{true:"z9nup83 _1yep5z6111"},labelPosition:{top:"_1dbkl58",start:"_1dbkl59"}},defaultVariants:{},compoundVariants:[]}),ry="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kj _1yep5z6kk _1yep5z6kl",oy=x({defaultClassName:"_1dbkl50 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6dy _1yep5z6ev",variantClassNames:{labelPosition:{top:"_1yep5z6oi _1yep5z6oj _1yep5z6ok",start:"_1dbkl52"}},defaultVariants:{},compoundVariants:[]}),an="_1dbkl5l _1yep5z6iy _1yep5z6iz _1yep5z6j0 _1yep5z69f _1yep5z69g _1yep5z69h",ay="_1dbkl5f z9nup87",nn="_1dbkl5m _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6id _1yep5z6ie _1yep5z6if",ny="_1dbkl5k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6lq",iy="_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6dy _1yep5z6ev _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jj _1yep5z6jk _1yep5z6jl",sn=x({defaultClassName:"_1dbkl5h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6g1",variantClassNames:{includesCustomColorPicker:{true:"_1yep5z6n6 _1yep5z6n7 _1yep5z6n8"}},defaultVariants:{},compoundVariants:[]}),Os="_1dbkl5v _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",sy=x({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 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lz _1yep5z6h4 _1yep5z6lq _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocused:{true:"_1dbkl5r _1yep5z6134"},isHovered:{true:"_1dbkl5s"},allowAlpha:{false:"_1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z617q"}},defaultVariants:{},compoundVariants:[[{isHovered:true,isFocused:false},"_1yep5z61pb"]]}),ly=x({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 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69c _1yep5z69d _1yep5z69e _1yep5z6f5 _1yep5z6lp _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6la _1yep5z6ld",variantClassNames:{isHovered:{true:"_1yep5z6126"},isFocusVisible:{true:"_1yep5z617w _1yep5z617u _1yep5z617x _1yep5z6140"},isDisabled:{true:"_1yep5z611a"}},defaultVariants:{},compoundVariants:[]}),Po="_1dbkl5u",ln="_1dbkl5g",pn="_1dbkl5j _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69f _1yep5z69g _1yep5z69h",Fs="_1dbkl5x",py="_1dbkl5w",js="_1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69l _1yep5z69m _1yep5z69n",cn=x({defaultClassName:"_1dbkl5n _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6lu _1yep5z6ig _1yep5z6ih _1yep5z6ii _1yep5z6lz _1yep5z6m2",variantClassNames:{isFocusVisible:{true:"_1dbkl5o _1yep5z617u _1yep5z6140 _1yep5z617w"}},defaultVariants:{},compoundVariants:[]}),Hs="z9nup84 z9nup86 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6lg _1yep5z6lh _1yep5z6lj _1yep5z6li _1yep5z6ig _1yep5z6ih _1yep5z6ii";var cy=x({defaultClassName:"_1344e9q0 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6lk _1yep5z6ic _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf",variantClassNames:{isFocusVisible:{true:"_1344e9q1"},isDisabled:{true:"_1344e9q2"},removeBlendMode:{true:"_1344e9q3"},isSelected:{true:"_1yep5z617w _1yep5z617u _1yep5z6140 _1yep5z617z"},isHovered:{true:"_1344e9q5"}},defaultVariants:{},compoundVariants:[[{isSelected:false,isFocusVisible:true},"_1344e9q6"],[{isSelected:true,isFocusVisible:true},"_1344e9q7 _1yep5z61tz _1yep5z61tx _1yep5z61q3 _1yep5z61u2"],[{isSelected:true,isDisabled:true},"_1yep5z61tz _1yep5z61tx _1yep5z61q3 _1yep5z61u2 _1yep5z61qd"],[{isHovered:true,isSelected:false},"_1yep5z61u2 _1yep5z61tz _1yep5z61tx _1yep5z61q7"]]}),dy="_1344e9q9 _1yep5z6fl";var ft=wt.forwardRef(({color:r,isFocusVisible:e,isSelected:t,isInteractive:o,isDisabled:a,style:n,className:i,id:s,tooltip:l,"data-block-id":p,"data-block-class":c,...d},m)=>{let u=r&&r!==Be&&(typeof r=="string"?parseColor(r):r),{formatMessage:b}=A(),y=!u,{colorSwatchProps:f}=useColorSwatch({color:y?"#000000":r}),{hoverProps:g,isHovered:v}=useHover({isDisabled:a||!o}),h=filterTruthyValues({"data-focus-visible":e,"data-selected":t,"data-hovered":v,"data-block-id":p,"data-block-class":c,"data-disabled":a,"data-interactive":o}),_=y?b(uy.none):f["aria-label"],z=d["aria-label"]??_,{tooltipProps:P}=da({tooltip:l,label:z}),w=jsx("div",{...mergeProps(g,h,y?{}:f),style:n,"aria-label":y?b(uy.none):f["aria-label"],role:"img",className:classNames(cy({removeBlendMode:y,isFocusVisible:e,isDisabled:!!a,isSelected:!!t,isHovered:v}),"BaselineUI-ColorSwatch",i),ref:m,id:s,...d,children:jsx(D,{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"full",height:"full",width:"full",opacity:a?"medium":void 0,style:u?my(u,4):void 0,children:y?jsx("div",{className:dy}):null})});return P&&!a?jsx(ie,{...P,children:jsx($a,{children:w})}):w});ft.displayName="ColorSwatch";var uy=G({none:{id:"none",defaultMessage:"None"}});var yy=[{id:"hex",label:"HEX"},{id:"rgb",label:"RGB"}],Io=parseColor("#000000").toFormat("hsla"),de="hsla",ko="hexa";function Dt(r){return typeof r=="string"?parseColor(r).toFormat(de):r?r.toFormat(de):null}function by(r,e){return r?.getChannelValue("alpha")?e?.toString(ko)===r.toString(ko):!e?.getChannelValue("alpha")}function gy(r,e,t){return e?.label?e.label:r?.getChannelValue("alpha")===0?t:r?.toString("rgba")}var Be="NONE";function vy(r,e){let t=e?.map(a=>({id:parseColor(a.color).toString(ko),label:a.label}))||[],o={id:Be,label:r};return [...t,o]}var dn=(r,{optionProps:e,isFocusVisible:t,isSelected:o},a)=>(invariant(r.value&&"label"in r.value,"Item must have label"),jsx("li",{...e,ref:a,className:ny,children:jsx(ft,{color:r.value.id,isFocusVisible:t,isSelected:o,"aria-label":r.value.label,isInteractive:true})})),my=(r,e=4)=>{let t=r.getChannelValue("alpha")===0,o=`repeating-conic-gradient(transparent 0% 25%, ${themeVars.color.background.secondary.medium} 25% 50%)`;return {backgroundImage:t?o:`linear-gradient(${r.toString("hexa")}, ${r.toString("hexa")}), ${o}`,backgroundSize:`${e}px ${e}px`}};var _y=({value:r,...e})=>{let t=wt.useRef(null),o=wt.useRef(null),a=wt.useRef(null),n=useColorAreaState({...e,value:r}),{colorAreaProps:i,xInputProps:s,yInputProps:l,thumbProps:p}=useColorArea({...e,value:r,inputXRef:t,inputYRef:o,containerRef:a},n);useEffect(()=>{t.current?.focus();},[]);let{focusProps:c,isFocusVisible:d}=useFocusRing();return jsx("div",{ref:a,...i,className:classNames(Qf,"BaselineUI-ColorInput-ColorArea"),children:jsxs("div",{...p,className:classNames(cn({isFocusVisible:d}),"BaselineUI-ColorInput-ColorAreaThumb"),style:{...p.style,transform:"translate(-50%, -50%)",backgroundColor:Dt(r)?.withChannelValue("alpha",1).toString("css")},children:[jsx("input",{ref:t,...s,...c}),jsx("input",{ref:o,...l,...c})]})})};var Cy=({color:r,setColor:e,allowAlpha:t,...o})=>{let a=useColorFieldState({value:r,onChange:d=>{e(Dt(d)?.toFormat(de).withChannelValue("alpha",r.getChannelValue("alpha")??1)||Io);}}),n=wt.useRef(null),{inputProps:i}=useColorField({...o,"aria-label":"Hex"},a,n),{focusProps:s,isFocused:l}=useFocusRing({isTextInput:true}),{hoverProps:p,isHovered:c}=useHover({});return jsxs("div",{className:classNames(Os,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":t?"hexa":"hex",children:[jsx("input",{...mergeProps(i,s,p),ref:n,className:sy({isFocused:l,isHovered:c,allowAlpha:t})}),t?jsx(wy,{color:r,setColor:e}):null]})},Py=({color:r,setColor:e,allowAlpha:t})=>{let o=r.toFormat("rgba"),{locale:a}=useLocale();return jsxs("div",{className:classNames(Os,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":t?"rgba":"rgb",children:[jsx(Ve,{"aria-label":r.getChannelName("red",a),value:o.getChannelValue("red"),showStepper:false,className:Po,onChange:n=>{e(o.withChannelValue("red",n).toFormat(de));},step:1,minValue:0,maxValue:255}),jsx(Ve,{"aria-label":r.getChannelName("green",a),value:o.getChannelValue("green"),showStepper:false,className:Po,onChange:n=>{e(o.withChannelValue("green",n).toFormat(de));},step:1,minValue:0,maxValue:255}),jsx(Ve,{"aria-label":r.getChannelName("blue",a),value:o.getChannelValue("blue"),showStepper:false,className:Po,onChange:n=>{e(o.withChannelValue("blue",n).toFormat(de));},step:1,minValue:0,maxValue:255}),t?jsx(wy,{color:r,setColor:e}):null]})},mk={style:"percent",maximumFractionDigits:0},wy=({color:r,setColor:e})=>{let{locale:t}=useLocale(),o=useCallback(a=>{e(r.withChannelValue("alpha",a));},[r,e]);return jsx(Ve,{"aria-label":r.getChannelName("alpha",t),value:r.getChannelValue("alpha"),formatOptions:mk,className:Po,showStepper:false,onChange:o,minValue:0,maxValue:1})};var Gs=({channel:r,...e})=>{let{locale:t}=useLocale(),o=useColorSliderState({...e,channel:r,locale:t}),a=wt.useRef(null),n=wt.useRef(null),{trackProps:i,thumbProps:s,inputProps:l}=useColorSlider({...e,channel:r,trackRef:a,inputRef:n,"aria-label":o.value.getChannelName(r,t)},o),{focusProps:p,isFocusVisible:c}=useFocusRing();return jsxs("div",{className:classNames(nn,{[Xc({size:"xs"})]:r==="alpha"},"BaselineUI-ColorInput-ColorSlider"),"data-channel":r,...i,ref:a,children:[r==="alpha"&&jsx("div",{className:Hs}),jsx("div",{className:nn,style:i.style}),jsxs("div",{className:classNames(cn({isFocusVisible:c}),"BaselineUI-ColorInput-ColorSliderThumb"),...s,children:[jsx("div",{className:Hs,style:{backgroundColor:"#ffffff"}}),jsx("div",{style:{backgroundColor:o.getDisplayColor().toString("css"),height:8},className:nn}),jsx(VisuallyHidden,{children:jsx("input",{ref:n,...l,...p})})]})]})};var un=({color:r,setColor:e,allowAlpha:t,onChangeEnd:o})=>{let[a,n]=wt.useState("hex"),{formatMessage:i}=A(mt);return jsxs(Fragment,{children:[jsx(_y,{value:r,xChannel:"saturation",yChannel:"lightness",onChange:e,onChangeEnd:o}),jsxs("div",{className:js,children:[jsx(Gs,{channel:"hue",value:r,onChange:e,onChangeEnd:o}),t?jsx(Gs,{channel:"alpha",value:r,onChange:e,onChangeEnd:o}):null]}),jsxs("div",{className:classNames(js,sprinkles.variants({paddingTop:"none",gap:"sm"})),children:[jsx(ut,{label:i("colorFormat"),labelPosition:"start",variant:"ghost",items:yy,selectedKey:a,onSelectionChange:s=>{n(s);}}),a==="hex"&&jsx(Cy,{color:r,setColor:s=>{e(s),o?.(s);},allowAlpha:t}),a==="rgb"&&jsx(Py,{color:r,setColor:s=>{e(s),o?.(s);},allowAlpha:t})]})]})};var Dy=({color:r,setColor:e,storePickedColorKey:t,addColorButtonLabel:o,removeColorButtonLabel:a,customColorsLabel:n,pickerMode:i,allowAlpha:s})=>{let{locale:l}=useLocale(),{formatMessage:p}=A(mt),c=wt.useRef(null),d=Ne(c.current),[m,u]=Gc(t,[]),b=wt.useRef(null),[y,f]=wt.useState(r),g=wt.useMemo(()=>m.map(w=>({id:w,label:parseColor(w).getColorName(l),description:w})),[m,l]),v=useCallback(()=>{let w=i==="active"?r:y;if(m.includes(w.toString(de))){b.current?.querySelector(`[data-key='${w.toString(de)}']`)?.classList.add(Fs);return}u([...m,w.toString(de)]);},[m,r,u,y,i]);useEffect(()=>{let w=b.current;function C(k){k.animationName===py&&k.target?.classList.remove(Fs);}return w?.addEventListener("animationend",C),()=>{w?.removeEventListener("animationend",C);}},[]);let h=useId(),_=jsx(L,{ref:c,variant:"secondary",size:"md","aria-label":o,icon:PlusIcon$1,onPress:i==="active"?v:void 0}),z=useCallback(w=>jsxs(ze,{size:"content",className:sn({includesCustomColorPicker:true}),style:{paddingBlockEnd:0},"aria-label":p("newColor"),children:[jsx(un,{color:y,setColor:f,allowAlpha:s}),jsx(U,{}),jsx(D,{padding:"lg",display:"flex",flexDirection:"row-reverse",children:jsxs(D,{display:"inline-flex",gap:"lg",children:[jsx(K,{label:p("cancel"),size:"sm",variant:"secondary",onPress:w}),jsx(K,{label:p("add"),variant:"primary",onPress:()=>{v(),w();},size:"sm"})]})})]}),[y,v,p,s]),P=useCallback(w=>{invariant(w instanceof Set,"Key must be a set");let C=[...w][0];C&&e(parseColor(C).toFormat(de));},[e]);return jsxs(Fragment,{children:[jsx(U,{}),jsxs("div",{className:classNames(iy,"BaselineUI-ColorInput-CustomColors"),children:[jsx("span",{id:h,children:n}),jsxs(D,{display:"flex",children:[!!m.length&&m.includes(r.toString(de))&&jsx(L,{variant:"secondary",size:"md",elementType:"div",icon:MinusIcon$2,"aria-label":a,onPress:()=>{u(m.filter(w=>w!==r.toString(de)));}}),i==="active"&&_,i==="lazy"&&(d==="mobile"?jsxs(Le,{children:[jsx(on,{children:_}),jsx(Ue,{style:{zIndex:1e5},children:({close:w})=>z(w)})]}):jsxs(je,{type:"dialog",children:[jsx(He,{children:_}),jsx(Ae,{placement:"right top",className:ln,offset:6,children:({close:w})=>z(w)})]}))]})]}),!!m.length&&jsx(me,{items:g,layout:"grid","aria-labelledby":h,className:classNames(an,pn,sprinkles.variants({paddingTop:"xs"}),"BaselineUI-ColorInput-CustomColorsListBox"),renderOption:dn,ref:b,autoFocus:false,selectionMode:"single",selectedKeys:[r.toString(de)],onSelectionChange:P})]})};var Ys=wt.forwardRef(({setColor:r,color:e,triggerRef:t,autoFocus:o,presets:a,state:n},i)=>{let{formatMessage:s}=A(mt),l=useCallback(p=>{if(p instanceof Set&&p.size){let c=[...p][0],d=a.find(m=>m.id===c);invariant(d,"Preset not found"),r(d.id===Be?null:parseColor(d.id).toFormat(de)),n.close();}},[n,a,r]);return jsx("div",{className:classNames(pn,"BaselineUI-ColorInput-Presets"),style:{minWidth:t.current?.offsetWidth},ref:i,children:jsx(me,{autoFocus:o,items:a,layout:"grid","aria-label":s("colorPresets"),className:an,renderOption:dn,selectionMode:"single",selectedKeys:[e?.toString(ko)||Be],onSelectionChange:l})})});Ys.displayName="ColorPresetList";var Ro=wt.forwardRef(({color:r,colorLabel:e,colorName:t,...o},a)=>{let n=wt.useRef(null),{hoverProps:i,isHovered:s}=useHover({isDisabled:o.isDisabled}),{buttonProps:l,isPressed:p}=useButton(o,n),{isFocusVisible:c,focusProps:d}=useFocusRing(),m=filterTruthyValues({"data-block-id":o["data-block-id"],"data-focused":c,"data-focus-visible":c,"data-disabled":o.isDisabled,"data-hovered":s,"data-pressed":p}),u=Jo(),b=Jo();return jsxs("button",{...mergeProps(l,i,d,m),style:o.style,className:classNames(ty({isHovered:s,isFocusVisible:c||o.isOpen,isDisabled:o.isDisabled,labelPosition:o.labelPosition}),"BaselineUI-ColorInputButton",o.className),ref:M(a,n),id:u,"aria-labelledby":o["aria-labelledby"]||`${u} ${b}`,children:[jsx(ft,{color:r?.toString("hexa")}),e?jsx("div",{className:ay,id:b,"aria-hidden":"true",children:t}):typeof t=="string"&&jsx(VisuallyHidden,{children:t})]})});Ro.displayName="ColorInputButton";var yn=wt.forwardRef(({className:r,style:e,icon:t,...o},a)=>{let n=wt.useRef(null),{hoverProps:i,isHovered:s}=useHover({isDisabled:o.isDisabled}),{buttonProps:l,isPressed:p}=useButton(o,n),{isFocusVisible:c,focusProps:d}=useFocusRing(),m=filterTruthyValues({"data-block-id":o["data-block-id"],"data-focused":c,"data-focus-visible":c,"data-disabled":o.isDisabled,"data-hovered":s,"data-pressed":p});return jsxs("button",{...mergeProps(l,i,d,m),ref:M(a,n),style:e,className:classNames(ly({isHovered:s||p||o.isOpen,isFocusVisible:c,isDisabled:o.isDisabled}),"BaselineUI-IconColorInputButton",r),children:[jsx(t,{size:16}),jsx("div",{className:ey,style:{backgroundColor:o.color||void 0}})]})});yn.displayName="IconColorInputButton";function jy({colorLabel:r,color:e,presets:t}){let{formatMessage:o}=A(),{locale:a}=useLocale(),n=useMemo(()=>t.find(l=>l.id===Be?!e:e?by(e,parseColor(l.id)):false),[t,e]),i=useMemo(()=>typeof r=="function"?r?.(e):r?gy(e,n,o(Ok.transparent)):false,[e,r,o,n]),s=useMemo(()=>{if(n?.label)return n.label;e?.getColorName(a);},[e,a,n?.label]);return {colorName:i,humanReadableName:s}}var Ok=G({transparent:{defaultMessage:"Transparent",id:"transparent"}});var wr=wt.forwardRef(({className:r,style:e,allowRemoval:t,allowAlpha:o=true,presets:a,labelPosition:n="top",colorLabel:i=true,includePicker:s=true,onChange:l,onChangeEnd:p,defaultValue:c,storePickedColorKey:d="baselinePickedColor",value:m,addColorButtonLabel:u,removeColorButtonLabel:b,customColorsLabel:y,renderTriggerButton:f=({isOpen:C,color:k,ref:$,colorName:R,triggerProps:T,labelId:I})=>jsx(Ro,{...mergeProps(T,{...P.label?{"aria-labelledby":I}:{"aria-label":P["aria-label"]}}),ref:$,isOpen:C,isDisabled:P.isDisabled,labelPosition:n,color:k,colorLabel:i,colorName:R}),pickerMode:g="active",offset:v=2,placement:h=n==="start"?"bottom end":"bottom start","data-block-id":_,"data-block-class":z,...P},w)=>{let C=wt.useRef(null),k=wt.useRef(null),$=useOverlayTriggerState(P),{triggerProps:R,overlayProps:T}=useOverlayTrigger({type:"listbox"},$,C),I=ve(P.portalContainer),[S,E]=useControlledState(m===void 0?void 0:Dt(m),Dt(c),Y=>l?.(Y?.toFormat("rgba")||null)),{formatMessage:N}=A(mt),O=useMemo(()=>vy(N(bn.noColor),a),[a,N]),B=useId(),{colorName:H}=jy({colorLabel:i,color:S,presets:O}),V=useMemo(()=>O.filter(Y=>t||Y.id!==Be),[O,t]),F=u||N(bn.addColor),te=b||N(bn.removeColor),j=y||N(bn.customColors),J=jsx(Dy,{color:S||Io,setColor:Y=>{E(Y),p?.(Y?.toFormat("rgba")||null);},storePickedColorKey:d,addColorButtonLabel:F,removeColorButtonLabel:te,customColorsLabel:j,pickerMode:g,allowAlpha:o});return jsxs(Fragment,{children:[jsxs("div",{className:classNames({[ry]:n==="start"},"BaselineUI-ColorInput-Trigger",r),"data-block-id":_,"data-block-class":z,style:e,ref:w,children:[P.label?jsx("label",{id:B,className:oy({labelPosition:n}),children:P.label}):null,f({isOpen:$.isOpen,color:S,ref:C,colorName:H,triggerProps:R,labelId:B})]}),jsx(we,{...P,portalContainer:I,placement:h,state:$,offset:v,className:classNames(ln,"BaselineUI-ColorInput-Popover"),triggerRef:C,overlayProps:T,children:jsxs(ze,{size:"content",className:sn({includesCustomColorPicker:s}),ref:k,"aria-labelledby":B,"aria-label":P["aria-label"],children:[s&&g==="active"?jsxs(Fragment,{children:[jsx(un,{color:S||Io,setColor:E,allowAlpha:o,onChangeEnd:Y=>{p?.(Y?.toFormat("rgba")||null);}}),J]}):null,!!V.length&&jsxs(Fragment,{children:[s&&g==="active"?jsx(U,{}):null,jsx(Ys,{autoFocus:s&&g==="active"?false:"first",state:$,triggerRef:C,presets:V,color:S,setColor:Y=>{E(Y),p?.(Y?.toFormat("rgba")||null);}})]}),s&&g==="lazy"?J:null]})})]})});wr.displayName="ColorInput";var bn=G({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 qy=wt.forwardRef(({className:r,style:e,icon:t,variant:o="standard","data-block-id":a,tooltipProps:n,...i},s)=>{let l=wt.useRef(null),p=useCallback(({isOpen:c,color:d,ref:m,colorName:u,triggerProps:b})=>jsx(ie,{variant:"inverse",size:"sm",includeArrow:false,text:i["aria-label"],placement:"bottom start",offset:4,...n,children:o==="standard"?jsx(Ro,{...b,"aria-label":i["aria-label"],ref:m,isOpen:c,isDisabled:i.isDisabled,color:d,colorLabel:false,colorName:u}):jsx(yn,{...b,isOpen:c,icon:TextIcon,color:d?.toString("hexa"),ref:m,isDisabled:i.isDisabled,"aria-label":i["aria-label"]})}),[i,n,o]);return jsxs(D,{display:"flex",flexDirection:"row",gap:"md",paddingX:o==="standard"?"md":"none",alignItems:"center",className:classNames("BaselineUI-IconColorInput",r),"data-block-id":a,style:e,ref:M(s,l),children:[o==="standard"&&t?jsx(t,{"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary"})}):null,jsx(wr,{...i,colorLabel:false,renderTriggerButton:p})]})});qy.displayName="IconColorInput";var Gy={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 gn=x({defaultClassName:"mnnh5s1 _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6la _1yep5z6ld _1yep5z6lp _1yep5z6lo _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ln",variantClassNames:{isInline:{true:"mnnh5s2 _1yep5z6wo _1yep5z6wp _1yep5z6wq _1yep5z6xc _1yep5z6xd _1yep5z6xe _1yep5z6y0 _1yep5z6y1 _1yep5z6y2 _1yep5z6yo _1yep5z6yp _1yep5z6yq _1yep5z6138 _1yep5z6183 _1yep5z6184",false:"_1yep5z617q _1yep5z6127"},isHovered:{true:"mnnh5s4"},hasLoadedImage:{true:"_1yep5z6126"},includeCheckeredBackground:{true:"mnnh5s6"},showFocusRing:{true:"_1yep5z613j _1yep5z617w _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"mnnh5s8 _1yep5z6zd"}},defaultVariants:{},compoundVariants:[[{isHovered:true,hasLoadedImage:false},"_1yep5z61oh"],[{isHovered:true,hasLoadedImage:true},"mnnh5s9"],[{isInline:true,isDisabled:true},"_1yep5z61pb"],[{hasLoadedImage:true,includeCheckeredBackground:true},"_1yep5z61o9"]]}),Ky="_1yep5z6d8",vn=x({defaultClassName:"mnnh5sa",variantClassNames:{isInline:{true:"mnnh5sb",false:"mnnh5sc"},isDisabled:{true:"mnnh5sd"},hasLoadedImage:{true:"mnnh5s0"}},defaultVariants:{},compoundVariants:[]});var Wy=x({defaultClassName:"_1i0ytqa3 _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6ln _1yep5z6lo _1yep5z6lq",variantClassNames:{isFocusVisible:{true:"_1i0ytqa4"},isInline:{true:"_1yep5z612f",false:"_1yep5z612h"},isDisabled:{true:"_1i0ytqa7 _1yep5z6zd",false:"_1i0ytqa8"}},defaultVariants:{},compoundVariants:[[{isInline:true,isFocusVisible:true},"_1i0ytqa9 _1yep5z61p7 _1yep5z61u5 _1yep5z61u7"],[{isInline:false,isFocusVisible:true},"_1i0ytqaa"],[{isInline:true,isDisabled:true},"_1yep5z61oi"],[{isInline:false,isDisabled:true},"_1yep5z61ok"]]}),Yy="_1i0ytqa0",hn=x({defaultClassName:"_1i0ytqab _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ln",variantClassNames:{isInline:{false:"_1yep5z6126"},isDisabled:{true:"_1i0ytqad _1yep5z6zd"}},defaultVariants:{},compoundVariants:[]}),Zy=x({defaultClassName:"_1i0ytqa1 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6ln",variantClassNames:{isInline:{false:"_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b"}},defaultVariants:{},compoundVariants:[]});function Xy({line:r,options:e}){let t=useRef([]),o=useMemo(()=>{let a=Math.ceil(r.length/kr),n;for(let i=0;i<a;i++)if(!(!(i===a-1)&&!!t.current[i])){let p=r.slice(i*kr-(i>0?1:0),i*kr+kr);n=getSvgPathFromStroke(getStroke(p.map(([c,d,m])=>({x:c,y:d,pressure:m})),e)),p.length>=(i>0?kr+1:kr)&&(t.current[i]=n);}return n},[r,e]);return [...t.current,o]}var kr=60*3;var yI={size:1,thinning:0,smoothing:0,streamline:0,easing:r=>r,start:{taper:0,easing:r=>r,cap:true},end:{taper:0,easing:r=>r,cap:true},simulatePressure:false},Qy=wt.forwardRef(({className:r,style:e,canvasClassName:t,canvasStyle:o,isBound:a=true,strokeWidth:n=2,strokeColor:i="#3A87FD",onChange:s,defaultValue:l,onChangeEnd:p,enableHistory:c=false,isInline:d=true,isDisabled:m,placeholder:u,clearLabel:b,undoLabel:y,redoLabel:f,footerClassName:g,canvasRef:v,value:h,footerStyle:_,"data-block-id":z,"data-block-class":P,"aria-label":w="Drawing canvas",description:C="This is a canvas for drawing using a mouse or touch input.",...k},$)=>{let R=A(Gy),T=wt.useRef(null),[I,S]=wt.useState(h||l||[]),E=wt.useMemo(()=>({...yI,...k}),[k]),[N,O]=wt.useState(),B=useId(),{labelProps:H,fieldProps:V}=useLabel({...k,"aria-label":w,labelElementType:"span"}),{isFocusVisible:F,focusProps:te}=useFocusRing({within:true}),{hoverProps:j,isHovered:J}=useHover({isDisabled:m}),{undo:Y,redo:Me,canRedo:Ee,canUndo:Ce,push:Oe}=Bc(I,{onAction:X=>{X&&(S(X),p?.(X));},isDisabled:!c}),{keyboardProps:Je}=useKeyboard({onKeyDown:X=>{X.key==="Backspace"?Kt():X.key==="z"&&(X.metaKey||X.ctrlKey)&&(X.shiftKey?Ee&&Me():Ce&&Y());}}),[ne,ye]=useState(false),qt=useCallback(X=>{let q=X.currentTarget.getBoundingClientRect();O(q),X.target.setPointerCapture(X.pointerId);let ce=[X.clientX-q.x,X.clientY-q.y,X.pressure];S(W=>[...W,[ce]]),ye(true);},[]),Gt=useCallback(X=>{if(X.buttons!==1||!N)return;let ce=r1(X.nativeEvent).map(W=>[a?clamp(W.clientX-N.left,0,N.width):W.clientX-N.left,a?clamp(W.clientY-N.top,0,N.height):W.clientY-N.top,W.pressure]);S(W=>{let $e=[...W];return $e[W.length-1]=[...$e[W.length-1],...ce],$e});},[N,a]),qr=()=>{N&&(p?.(I),Oe(I),ye(false));};useEffect(()=>{s?.(I);},[I,s]);let Kt=()=>{S([]),s?.([]),Oe([]);};return jsxs("div",{ref:M(T,$),className:classNames(Yy,"BaselineUI-FreehandCanvas",r),style:e,"aria-disabled":m,"data-block-id":z,"data-block-class":P,children:[k.label||c?jsxs("div",{className:Zy({isInline:d}),children:[k.label?jsx(Q,{type:"label",size:"sm",...H,children:k.label}):jsx("span",{}),c?jsxs("div",{children:[jsx(L,{variant:"secondary",size:"sm",isDisabled:!Ce||m,icon:UndoIcon,onPress:Y,"aria-label":y||R.formatMessage("undo")}),jsx(L,{variant:"secondary",size:"sm",isDisabled:!Ee||m,icon:RedoIcon,onPress:Me,"aria-label":f||R.formatMessage("redo")})]}):null]}):null,jsxs("div",{role:"application",...mergeProps(te,Je,j,V),tabIndex:m?void 0:0,className:classNames(gn({isInline:d,isHovered:J}),Wy({isFocusVisible:F,isInline:d,isDisabled:!!m}),t),"aria-describedby":k["aria-describedby"]||B,style:o,ref:v,children:[jsx(VisuallyHidden,{children:jsx("div",{id:B,children:C})}),jsx("svg",{width:o?.width||"100%",height:o?.height||"100%",onPointerDown:qt,onPointerMove:Gt,onPointerUp:qr,children:(h||I).map((X,q,ce)=>q<ce.length-1||!ne?jsx(e1,{line:X,options:E,strokeColor:i,strokeWidth:n},q):jsx(t1,{line:X,options:E,strokeColor:i,strokeWidth:n},q))})]}),u||b?jsx("div",{style:_,className:classNames(hn({isInline:d,isDisabled:m}),g),children:(I.length||!u)&&b?jsx(K,{size:"sm",variant:"ghost",label:b,isDisabled:m,onPress:Kt}):jsx(K,{size:"sm",variant:"ghost",label:u,isDisabled:true})}):null]})});Qy.displayName="FreehandCanvas";var e1=wt.memo(({line:r,options:e,strokeColor:t,strokeWidth:o})=>{let a=useMemo(()=>getSvgPathFromStroke(getStroke(r.map(([n,i,s])=>({x:n,y:i,pressure:s})),e)),[r,e]);return jsx("path",{d:a,stroke:t,strokeWidth:o})});e1.displayName="Stroke";var t1=wt.memo(({line:r,options:e,strokeColor:t,strokeWidth:o})=>{let a=Xy({line:r,options:e});return jsx(Fragment,{children:a.map((n,i)=>jsx("path",{d:n,stroke:t,strokeWidth:o},i))})});t1.displayName="SplitStroke";function r1(r){if(typeof r.getCoalescedEvents=="function"){let e=r.getCoalescedEvents();return e.length>0?e.flatMap(t=>r1(t)):[r]}return [r]}var o1="_1vac7ws0",a1=x({defaultClassName:"_1vac7ws1",variantClassNames:{isDragging:{true:"_1vac7ws2"}},defaultVariants:{},compoundVariants:[]});function i1(r,e){let[t,o]=useState([]),a=()=>r?.flatMap(n=>[...e.querySelectorAll(n)]).map(n=>({current:n}));return useGranularEffect(()=>{o(a());},[],[a]),useGranularEffect(()=>{let n=a();o(n);},[r],[a]),t}function s1(r){let{scrollable:e,ownerDocument:t,onScroll:o}=r;useEffect(()=>{let a=getHTMLElement(e,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",o),()=>{a.removeEventListener("scroll",o);}},[e,o,t]);}var DI=makeMoveable([Draggable,Resizable,Rotatable,Snappable]),p1=wt.forwardRef(({className:r,children:e,isRotatable:t,isResizable:o,isDraggable:a,style:n,onTransform:i,onTransformStart:s,onTransformEnd:l,onDoubleClick:p,onDragStart:c,onDragEnd:d,onDrag:m,onResizeStart:u,onResizeEnd:b,onResize:y,onRotateStart:f,onRotateEnd:g,onRotate:v,onSnap:h,isSnappable:_,elementGuidelines:z,hideAnchorOnDrag:P=true,title:w,rotationPosition:C,autoUpdate:k,bound:$,snapRotationDegrees:R,snapRotationThreshold:T,scrollableAncestor:I,renderDirections:S,stopPropagation:E,transformOrigin:N,preventDefault:O},B)=>{let H=useRef(null),V=useRef(null),[F,te]=useState(document),j=useRef(F.createElement("div")),[J,Y]=useState({}),[Me,Ee]=useState(false),[Ce,Oe]=useState(false),[Je,ne]=useState(),ye=i1(z,F);useLayoutEffect(()=>{let q=j.current;return j.current=F.createElement("div"),()=>{q.remove();}},[F]);let{keyboardProps:qt}=useKeyboard({onKeyDown:q=>{let ce=q.shiftKey?10:1,W=q.metaKey||q.ctrlKey;W&&q.shiftKey&&(ce=45);function $e(Gr,Ph="x"){W?V.current?.request("rotatable",{deltaRotate:Gr*ce},true):V.current?.request("draggable",Ph==="x"?{deltaX:Gr*ce}:{deltaY:Gr*ce},true);}switch(q.key){case "ArrowRight":{$e(1);break}case "ArrowLeft":{$e(-1);break}case "ArrowUp":{$e(-1,"y");break}case "ArrowDown":$e(1,"y");}requestAnimationFrame(()=>{V.current?.updateRect();});}});useEffect(()=>{let q=be(H.current);te(q);let ce=j.current;q.body.append(j.current);function W(Gr){Oe(Gr.shiftKey);}function $e(){Oe(false);}return q.addEventListener("keydown",W),q.addEventListener("keyup",$e),()=>{q.removeEventListener("keydown",W),q.removeEventListener("keyup",$e),ce.remove();}},[]),s1({scrollable:I,onScroll:()=>{V.current?.updateRect();},ownerDocument:F});let Gt=useCallback(q=>{Y(ce=>({...ce,...q.style})),i?.(q);},[i]),qr=useCallback(q=>{if(Ee(true),H.current?.focus(),$){let W=getHTMLElement($,F)?.getBoundingClientRect();ne({position:"client",left:W?.left??0,top:W?.top??0,right:W?.right??0,bottom:W?.bottom??0});}c?.(q);},[$,F,c]),Kt=useCallback(q=>{Ee(false),d?.(q);},[d]),X=e({style:{...J.width&&{width:J.width},...J.height&&{height:J.height}}});return jsxs(Fragment,{children:[jsx("div",{role:"button",...qt,ref:M(H,B),style:{display:"inline-block",...n,...J},className:classNames(o1,r),onDoubleClick:p,tabIndex:0,title:w,children:X}),createPortal(jsx(DI,{ref:V,target:H,draggable:a,resizable:o,rotatable:t,keepRatio:Ce,throttleDrag:1,snappable:_||!!$,elementGuidelines:ye,snapRenderThreshold:.9,className:a1({isDragging:Me&&P}),onRender:Gt,onDragStart:qr,onDragEnd:Kt,useResizeObserver:k,useMutationObserver:k,onRenderEnd:l,onDrag:m,onResizeStart:u,onResizeEnd:b,onResize:y,onRotateStart:f,onRotateEnd:g,onRotate:v,onRenderStart:s,onSnap:h,rotationPosition:C,bounds:Je,snapRotationDegrees:R,snapRotationThreshold:T,renderDirections:S,stopPropagation:E,preventDefault:O,transformOrigin:N}),j.current)]})});p1.displayName="Transform";var c1={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 m1=wt.forwardRef(({className:r,style:e,isInline:t=true,accept:o="image/*",defaultImageSrc:a,imageSrc:n,imageAlt:i,pickerButtonLabel:s,isDisabled:l,onDrop:p,onPaste:c,includeCheckeredBackground:d=true,"data-block-id":m,"data-block-class":u,pickerButtonStyle:b,pickerButtonClassName:y,footerClassName:f,footerStyle:g,clearLabel:v,placeholder:h,labelStyle:_,labelClassName:z,...P},w)=>{let C=wt.useRef(null),k=wt.useRef(null),{formatMessage:$}=A(c1),[R,T]=useControlledState(n,a||null,ne=>{invariant(typeof ne!="string"),P.onValueChange?.(ne?[ne]:[]);}),I=useMemo(()=>GI(R||void 0),[R]),{fieldProps:S,labelProps:E}=useField(P),{dropProps:N,isDropTarget:O}=useDrop({ref:C,onDrop:async ne=>{if(l)return;let ye=await xs({items:ne.items});ye.length&&T(ye[0]),p?.(ne);},...P}),{clipboardProps:B}=useClipboard({onPaste:async ne=>{if(l)return;let ye=await xs({items:ne});ye.length&&T(ye[0]),c?.(ne);},...P}),H=()=>{T(null),k.current&&(k.current.value="");},V={type:"file",onChange:ne=>{let ye=[...ne.target.files];T(ye[0]),P.onChange?.(ne);},accept:o,disabled:l},{focusProps:F,isFocused:te,isFocusVisible:j}=useFocusRing({within:true}),{hoverProps:J,isHovered:Y}=useHover({isDisabled:l}),{imgProps:Me,isLoading:Ee,isLoaded:Ce}=er({src:I,alt:i||""}),Oe={label:s||$("selectImage"),onPress:()=>C.current?.click(),variant:"secondary",isDisabled:l,excludeFromTabOrder:true,className:classNames(ya({isFocusVisible:j}),{[Ky]:O&&!l},y),style:b},Je=filterTruthyValues({"data-loaded":Ce,"data-block-id":m,"data-block-class":u,"data-hovered":Y,"data-focused":te,"data-drop-target":O,"data-disabled":l,"data-focus-visible":j});return jsxs(D,{...Je,className:classNames("BaselineUI-ImageDropZone",r),display:"flex",flexDirection:"column",alignItems:"center",style:e,ref:w,children:[jsxs("label",{...mergeProps(N,J,F,E),className:classNames(gn({isInline:t,isHovered:Y,isDisabled:l,hasLoadedImage:!!I&&Ce,showFocusRing:O||!!I&&j}),z),style:_,ref:C,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(S,B,V),ref:k})}),!I&&jsx(K,{...Oe}),!!I&&(Ee?jsx(vr,{}):jsx("img",{className:vn({isInline:t,isDisabled:l,hasLoadedImage:!!I&&Ce&&d}),...Me}))]}),h||v?jsx("div",{style:g,className:classNames(hn({isInline:t,isDisabled:l}),f),children:(I||!h)&&v?jsx(K,{size:"sm",variant:"ghost",label:v,isDisabled:l,onPress:H}):jsx(K,{size:"sm",variant:"ghost",label:h,isDisabled:true})}):null]})});m1.displayName="ImageDropZone";function GI(r){return r instanceof File?URL.createObjectURL(r):r}var f1="_1vm2oh49 _1yep5z6ig _1yep5z6ih _1yep5z6ii _1yep5z6g4",ol="_1vm2oh48 _1yep5z6lo _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6k4 _1yep5z6k5 _1yep5z6k6",y1=x({defaultClassName:"_1vm2oh40 mnnh5s1 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6lt _1yep5z6lr _1yep5z6ic _1yep5z6lu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6la _1yep5z6lp _1yep5z6id _1yep5z6ie _1yep5z6if",variantClassNames:{accent:{theme:"_1vm2oh41",positive:"_1vm2oh42"},isInline:{true:"mnnh5s2 _1yep5z6wl _1yep5z6wm _1yep5z6wn _1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6xx _1yep5z6xy _1yep5z6xz _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z6137 _1yep5z6182 _1yep5z6184",false:"_1yep5z612h"},isFocusVisible:{true:"_1yep5z613j _1yep5z617w _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"mnnh5s8 z9nup83 _1yep5z6zd"},isHovered:{true:"_1vm2oh47"}},defaultVariants:{},compoundVariants:[[{accent:"positive",isInline:true},"_1yep5z61oi"],[{accent:"theme",isInline:true},"_1yep5z61o7"],[{accent:"positive",isInline:false},"_1yep5z61ok"],[{accent:"theme",isInline:false},"_1yep5z61o9"],[{isFocusVisible:true,isInline:true},"_1yep5z61q3 _1yep5z61tx _1yep5z61tz _1yep5z61u0"],[{isHovered:true,isInline:true},"_1yep5z61u0 _1yep5z61q3 _1yep5z61tx _1yep5z61tz"],[{isHovered:true,isInline:false,accent:"positive"},"_1yep5z61oj"],[{isHovered:true,isInline:false,accent:"theme"},"_1yep5z61ob"],[{isHovered:true,isInline:true,accent:"theme"},"_1yep5z61o8"]]});var v1=wt.forwardRef(({className:r,style:e,isDisabled:t,isInline:o=true,imageAlt:a,imageSrc:n,svgSrc:i,textValue:s,textStyle:l,onPress:p,onDelete:c,deleteAriaLabel:d,addAriaLabel:m,accent:u="positive","data-block-id":b,"data-block-class":y,...f},g)=>{let{focusProps:v,isFocused:h,isFocusVisible:_}=useFocusRing({within:true}),{isHovered:z,hoverProps:P}=useHover({isDisabled:t}),{pressProps:w}=usePress({isDisabled:t,onPress:p});invariant(n||i||s,"Preview must have content. You must provide either an `imageSrc`, `svgSrc`, or `textValue` prop.");let C=filterTruthyValues({"data-hovered":z,"data-focus-visible":_,"data-focused":h,"data-disabled":t});return jsxs("div",{...f,className:classNames(y1({isInline:o,isFocusVisible:_,isDisabled:t,isHovered:z,accent:u}),"BaselineUI-Preview",r),"data-block-id":b,"data-block-class":y,"aria-label":f["aria-label"]||a||s,style:e,ref:g,children:[typeof i=="string"?jsx("button",{disabled:t,...mergeProps(P,v,w,C),className:ol,"aria-label":m,dangerouslySetInnerHTML:{__html:i}}):jsxs("button",{...mergeProps(P,v,w,C),disabled:t,style:l,"aria-label":m,className:ol,children:[n?jsx("img",{src:n,alt:a,className:vn({isInline:o,isDisabled:t})}):null,!!i&&typeof i=="object"&&i,s]}),c?jsx(L,{isDisabled:t,className:f1,"aria-label":d,size:"xs",icon:TrashIcon,onPress:c}):null]})});v1.displayName="Preview";var h1="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69c _1yep5z69d _1yep5z69e",_1=x({defaultClassName:"cw3m0n8 _1yep5z6ew _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),z1="cw3m0n7",x1=x({defaultClassName:"cw3m0n0 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",variantClassNames:{labelPosition:{end:"_1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z6vl _1yep5z6vm _1yep5z6vn",start:"_1yep5z615a _1yep5z615b _1yep5z615c _1yep5z616m _1yep5z616n _1yep5z616o"}},defaultVariants:{},compoundVariants:[]}),C1="_1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6lk",P1=x({defaultClassName:"cw3m0n3 _16vugd06",variantClassNames:{isFocusVisible:{true:"_16vugd09"},isSelected:{true:"_16vugd08"},isDisabled:{true:"_16vugd0b"}},defaultVariants:{},compoundVariants:[]});var pS=({label:r,description:e},{isSelected:t,isFocusVisible:o,isDisabled:a,optionLabelPosition:n})=>jsxs("div",{className:x1({labelPosition:n}),children:[jsx("div",{className:P1({isSelected:t,isFocusVisible:o,isDisabled:a}),children:t?jsx("div",{className:z1}):null}),r?jsxs("div",{className:h1,children:[jsx("span",{className:Ya({isDisabled:a}),children:r}),e?jsx("span",{className:_1({isDisabled:a}),children:e}):null]}):null]}),w1=({state:r,renderOption:e=pS,item:t,optionLabelPosition:o="end",optionStyle:a,optionClassName:n,isReadOnly:i,...s})=>{let l=!!s.isDisabled||!!s.disabledValues?.includes(t.id),p=wt.useRef(null),{inputProps:c,isPressed:d,isSelected:m}=useRadio({...s,isDisabled:l,children:t.label,value:t.id},r,p),{focusProps:u,isFocusVisible:b,isFocused:y}=useFocusRing(),{isHovered:f}=useHover({isDisabled:l}),g=filterTruthyValues({"data-selected":m,"data-focused":y,"data-focus-visible":b,"data-hovered":f,"data-disabled":l,"data-pressed":d,"data-read-only":i});return jsxs("label",{...g,style:a,className:classNames("BaselineUI-Radio-Item",n),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(c,u),ref:p})}),e(t,{isFocusVisible:b,isSelected:m,isFocused:y,isHovered:f,isDisabled:l,optionLabelPosition:o,isReadOnly:i})]})};var I1=wt.forwardRef(({className:r,style:e,optionsContainerClassName:t,optionsContainerStyle:o,items:a,labelPosition:n="top",renderOption:i,"aria-label":s,"aria-labelledby":l,"aria-describedby":p,"aria-details":c,"data-block-id":d,"data-block-class":m,...u},b)=>{let y=useRadioGroupState(u),{radioGroupProps:f,labelProps:g,descriptionProps:v,errorMessageProps:h}=useRadioGroup({...u,"aria-label":s,"aria-labelledby":l,"aria-describedby":p,"aria-details":c},y),_=ge({...u,descriptionProps:v,errorMessageProps:h,labelPosition:n}),z=filterTruthyValues({"data-orientation":u.orientation,"data-block-id":d,"data-block-class":m,"data-disabled":u.isDisabled,"data-readonly":u.isReadOnly});return jsxs("div",{...mergeProps(f,z),className:classNames(at({labelPosition:n}),"BaselineUI-RadioGroup",r),style:e,ref:b,children:[u.label||_?jsxs("div",{className:ot({labelPosition:n,hasMessage:!!_}),children:[jsx("span",{...g,className:classNames(Jt,"BaselineUI-RadioGroup-Label"),children:u.label}),n==="start"&&_]}):null,jsx("div",{className:classNames(C1,{[tr]:u.isDisabled},t),style:o,children:a.map(P=>jsx(w1,{state:y,renderOption:i,item:P,...u,value:P.id},P.id))}),n==="top"&&_]})});I1.displayName="RadioGroup";var S1=({id:r,defaultMessage:e,elementType:t=Fragment$1})=>{invariant(r||e,"`id` or `defaultMessage` is required.");let o=A();return jsx(t,{children:o.formatMessage(r)||e})};S1.displayName="MessageFormat";var R1=wt.forwardRef(({className:r,style:e,children:t,"data-block-id":o,"data-block-class":a,role:n="group",isDisabled:i,...s},l)=>{let{hoverProps:p,isHovered:c}=useHover({isDisabled:i});return jsx("div",{...p,role:n,"data-hovered":c,"data-disabled":i,"data-block-id":o,"data-block-class":a,className:r,style:e,...s,ref:l,children:t})});R1.displayName="Group";var ll="UNSUPPORTED_IN_MENU";function D1(r){return useMemo(()=>wt.Children.toArray(r).map(e=>{let t=e,o=uniqueId("item"),a=Eo(t,je),n=T1(t),i,s;if(a){let g=Eo(a,He);invariant(g),i=T1(g),s=Eo(a,Ae).props.children;}else n?i=n:i=t;let{onPress:l,label:p,"aria-label":c,iconStart:d,isDisabled:m,icon:u}=i.props,b=p||c||ll;invariant(typeof b=="string","ActionGroup children must have a string label");let y=`${o}-${b}`;return createElement(Item,{...{key:y,onPress:l,textValue:b,"aria-label":c,icon:d||u,dialogContent:s,isDisabled:m},key:y},t)}),[r])}function Eo(r,e){return e?flatMapDeep(wt.Children.toArray(r),o=>wt.isValidElement(o)&&o.props.children?[o,...wt.Children.toArray(o.props.children)]:[o]).find(o=>wt.isValidElement(o)&&o.type===e):void 0}function T1(r){return Eo(r,K)||Eo(r,L)}var M1="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6ln _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6lf",E1={horizontal:"xvr3wn0",vertical:"xvr3wn1"};var cl=wt.forwardRef(({className:r,style:e,children:t,collapsibleMenuProps:o,"data-block-id":a,"data-block-class":n,renderSpacer:i,onKeyDown:s,...l},p)=>{let{formatMessage:c}=A(),[d,m]=useState(),u=D1(t),b=useListState({...l,children:u}),y=oe(p),f=useRef(null),[{visibleItems:g,isMeasuring:v},h]=gi({visibleItems:b.collection.size,isMeasuring:false}),_=useCallback(()=>{let T=I=>{if(f.current&&y.current){let S=[...f.current.children],E=y.current.getBoundingClientRect().width,N=I<b.collection.size,O=0,B=0;if(N){let H=S.pop();H&&(O+=B1(H,false,true));}for(let[H,V]of S.entries())if(O+=B1(V,H===0,H===S.length-1),Math.round(O)<=Math.round(E))B++;else break;return B}return I};h(function*(){yield {visibleItems:b.collection.size,isMeasuring:true};let I=T(b.collection.size),S=I<b.collection.size&&I>0;yield {visibleItems:I,isMeasuring:S},S&&(yield {visibleItems:T(I),isMeasuring:false});});},[h,y,b.collection.size]),z=useMemo(()=>({get current(){return y.current?.parentElement}}),[y]);ki({ref:z,onResize:_}),Te(_,[b.collection,_]);let{toolbarProps:P}=useToolbar(l,y),w=[...b.collection],C=w.slice(0,g),k=w.slice(g).filter(T=>T.textValue!==ll),$=k.length>0;useEffect(()=>{m(void 0);},[k.length]),useEffect(()=>{l.orientation==="vertical"&&console.warn("Toolbar: Vertical orientation is not supported when `isCollapsible` is true.");},[l.orientation]);let{keyboardProps:R}=useKeyboard({onKeyDown:s});return jsxs(FocusScope,{children:[jsx("div",{...mergeProps(P,R),className:r,"data-block-id":a,"data-block-class":n,"data-collapse":true,style:{...e,flexBasis:v?"100%":void 0},ref:y,children:jsxs("div",{ref:f,className:M1,children:[C.map(T=>T.rendered),$?jsxs(Fragment,{children:[!v&&i?jsx(D,{flexGrow:1}):null,jsx(Va,{placement:"bottom end",renderTrigger:({buttonProps:T,ref:I})=>jsx(L,{...T,size:"md",icon:MoreIcon,"aria-label":c(LS.more),variant:"toolbar",ref:I,tooltip:true}),...o,disabledKeys:k.filter(T=>T.props?.isDisabled).map(T=>T.key),items:k.map(T=>{let I=T.textValue||T["aria-label"];return invariant(I,"ActionItem must have a label"),{id:T.key,label:I,icon:T.props.icon}}),onAction:T=>{let I=b.collection.getItem(T);invariant(I,"Item not found");let{onPress:S,dialogContent:E}=I.props;S?.(),m(E);}})]}):null]})}),jsx(Le,{isOpen:!!d,onOpenChange:T=>{T||m(void 0);},children:jsx(Ue,{enableDrawer:"auto",style:{zIndex:1e5},children:d?wt.cloneElement(d,{inheritDrawer:true}):null})})]})});cl.displayName="CollapsibleToolbar";function B1(r,e,t){let a=re(r).getComputedStyle(r);return r.getBoundingClientRect().width+(e?0:O1(a.marginLeft))+(t?0:O1(a.marginRight))}function O1(r){let e=Number.parseInt(r,10);return Number.isNaN(e)?0:e}var LS=G({more:{id:"more",defaultMessage:"More"}});var dl=wt.forwardRef(({className:r,style:e,"data-block-id":t,"data-block-class":o,"aria-controls":a,onKeyDown:n,...i},s)=>{let l=wt.useRef(null),{toolbarProps:p}=useToolbar(i,l),{keyboardProps:c}=useKeyboard({onKeyDown:n});return jsx("div",{...mergeProps(p,c),"aria-controls":a,className:classNames(E1[i.orientation||"horizontal"],"BaselineUI-Toolbar",r),style:e,"data-block-id":t,"data-block-class":o,ref:M(s,l),children:i.children})});dl.displayName="WrappedToolbar";var xn=wt.forwardRef((r,e)=>{let t=r.isCollapsible?cl:dl;return jsx(t,{...r,ref:e})});xn.displayName="Toolbar";var j1=x({defaultClassName:"_1j5skr71",variantClassNames:{size:{xxs:"_1j5skr72",xs:"_1j5skr73",sm:"_1j5skr74",md:"_1j5skr75",lg:"_1j5skr76"}},defaultVariants:{},compoundVariants:[]}),H1=x({defaultClassName:"_1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6g1 _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr7g"},isFocusVisible:{true:"_1j5skr7h"},isDisabled:{true:"z9nup83 _1yep5z611a"},isSelected:{true:"_1j5skr7j"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:true},"_1yep5z61u0 _1yep5z61tz _1yep5z61tx _1yep5z61qd _1yep5z61nd"],[{isSelected:false,isHovered:true,isDisabled:false},"_1yep5z6g3"],[{isSelected:false,isFocusVisible:true,isDisabled:false},"_1yep5z61u0 _1yep5z61tz _1yep5z61q3 _1yep5z61tx"],[{isSelected:true,isFocusVisible:true,isDisabled:false},"_1j5skr7k _1yep5z61ty _1yep5z61tx _1yep5z61q4 _1yep5z61ne"],[{isSelected:true,isFocusVisible:false,isDisabled:false},"_1yep5z61tx _1yep5z61tz _1yep5z61q3 _1yep5z61u0"]]}),V1=x({defaultClassName:"_1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr7m"},isFocusVisible:{true:"_1yep5z617x _1yep5z617w _1yep5z6140 _1yep5z617u"},isSelected:{true:"_1yep5z6119"},isDisabled:{true:"z9nup83 _1yep5z611a"}},defaultVariants:{},compoundVariants:[[{isSelected:false,isHovered:true},"_1yep5z61nc"]]}),U1=x({defaultClassName:"_1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr7r"},isFocusVisible:{true:"_1yep5z617x _1yep5z617w _1yep5z6140 _1yep5z617u"},isSelected:{true:"_1j5skr7t"},isDisabled:{true:"z9nup83 _1yep5z611a"}},defaultVariants:{},compoundVariants:[[{isSelected:false,isHovered:true},"_1yep5z61o9"],[{isSelected:true,isDisabled:false},"_1yep5z61o9 _1yep5z61ng"],[{isSelected:true,isDisabled:true},"_1yep5z61o9 _1yep5z61nd"]]}),q1=x({defaultClassName:"_1j5skr77 _1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr78"},isFocusVisible:{true:"_1j5skr79"},isSelected:{true:"_1j5skr7a"},isDisabled:{true:"_1j5skr7b z9nup83 _1yep5z611c"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:false},"_1j5skr7c _1yep5z61nf"],[{isSelected:false,isDisabled:true},"_1j5skr7d _1yep5z61nd"],[{isSelected:false,isHovered:true},"_1yep5z61o9"],[{isSelected:false,isFocusVisible:true},"_1yep5z61u0 _1yep5z61tz _1yep5z61q3 _1yep5z61tx"],[{isSelected:true,isFocusVisible:true},"_1j5skr7e _1yep5z61ty _1yep5z61tx _1yep5z61q4"]]});var ZS={xxs:8,xs:12,sm:16,md:20,lg:24},ke=wt.forwardRef((r,e)=>{let t=oe(e),{tooltipProps:o}=ua(r,t);return o?jsx(ie,{...o,children:jsx(ul,{...r,ref:e})}):jsx(ul,{...r,ref:e})});ke.displayName="ToggleIconButton";var ul=wt.forwardRef(({className:r,style:e,icon:t,size:o="md",variant:a="primary","data-block-id":n,"data-block-class":i,...s},l)=>{let p=useToggleState(s),{buttonProps:c,isPressed:d,ref:m,isFocusVisible:u,isFocused:b,isHovered:y,uiStateOptions:f}=fa(s,p),g=useMemo(()=>typeof t=="function"?t:p.isSelected?t.selected:t.unselected,[t,p.isSelected]),v={isSelected:p.isSelected,isHovered:y,isFocusVisible:u,isDisabled:!!s.isDisabled},h=filterTruthyValues({"data-hovered":y,"data-selected":p.isSelected,"data-focus-visible":u,"data-disabled":s.isDisabled,"data-block-id":n,"data-block-class":i,"data-focused":b,"data-pressed":d});return jsx("button",{...mergeProps(c,h),className:classNames(a==="toolbar"&&q1(v),a==="primary"&&H1(v),a==="secondary"&&V1(v),a==="tertiary"&&U1(v),j1({size:o}),"BaselineUI-ToggleIconButton",typeof r=="function"?r(f):r),style:typeof e=="function"?e(f):e,ref:M(m,l),children:jsx(g,{size:ZS[o]})})});ul.displayName="ToggleIconButtonCore";var K1="f6jv6bl",W1="_1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z6js _1yep5z6jt _1yep5z6ju",Rr="_1yep5z689 _1yep5z68a _1yep5z68b _1yep5z65x _1yep5z65y _1yep5z65z",Y1=x({defaultClassName:"f6jv6b0 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6g1",variantClassNames:{isInline:{true:"f6jv6b1"},isMinimal:{true:"_1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z6vo _1yep5z6vp _1yep5z6vq _1yep5z615m _1yep5z615n _1yep5z615o",false:"_1yep5z6157 _1yep5z6158 _1yep5z6159"}},defaultVariants:{},compoundVariants:[[{isInline:true,isMinimal:false},"_1yep5z61ir _1yep5z61is _1yep5z61it _1yep5z61jf _1yep5z61jg _1yep5z61jh _1yep5z61k3 _1yep5z61k4 _1yep5z61k5 _1yep5z61kr _1yep5z61ks _1yep5z61kt _1yep5z61u7 _1yep5z61u5 _1yep5z61pa"]]}),Cn=x({defaultClassName:"f6jv6b4 _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6e3 _1yep5z6eu _1yep5z6lq",variantClassNames:{isDisabled:{true:"f6jv6b5 _1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),Z1="f6jv6bi _1yep5z6wr _1yep5z6ws _1yep5z6wt _1yep5z6xf _1yep5z6xg _1yep5z6xh _1yep5z6y3 _1yep5z6y4 _1yep5z6y5 _1yep5z6yr _1yep5z6ys _1yep5z6yt",X1="f6jv6bj";var J1="f6jv6bm _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6ly _1yep5z6lt _1yep5z6lr _1yep5z6hx _1yep5z6eu",Q1=x({defaultClassName:"f6jv6bf _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6lq _1yep5z6la _1yep5z6ld _1yep5z6lp",variantClassNames:{isHovered:{true:"_1yep5z6126"},isDisabled:{true:"_1yep5z6zd"}},defaultVariants:{},compoundVariants:[]}),eb="_1yep5z6jy _1yep5z6jz _1yep5z6k0",tb="f6jv6be f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6ip _1yep5z6iq _1yep5z6ir _1yep5z6eu _1yep5z6e3 _1yep5z6ln",rb=x({defaultClassName:"f6jv6bb _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6k4 _1yep5z6k5 _1yep5z6k6",variantClassNames:{isInline:{true:"_1yep5z6pr _1yep5z6ps _1yep5z6pt _1yep5z6184 _1yep5z6182 _1yep5z6137",false:"_1yep5z6pu _1yep5z6pv _1yep5z6pw _1yep5z6x6 _1yep5z6x7 _1yep5z6x8 _1yep5z6xu _1yep5z6xv _1yep5z6xw _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8"}},defaultVariants:{},compoundVariants:[]}),ob="f6jv6bk",ab="f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6ip _1yep5z6iq _1yep5z6ir _1yep5z6eu",Pn=x({defaultClassName:"f6jv6b6",variantClassNames:{isInline:{true:"f6jv6b7",false:"f6jv6b8"}},defaultVariants:{},compoundVariants:[]}),wn="f6jv6b9 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl",Lo="f6jv6bn";var ib=[["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:Ao}}=layoutSprinkleValues,sb=({isOpen:r,onClose:e})=>{let{formatMessage:t}=A(),o=useId();return jsx(Le,{isOpen:r,onOpenChange:a=>{a||e();},children:jsx(Ue,{enableDrawer:"auto",style:{zIndex:999999},children:jsxs(ze,{"aria-labelledby":o,className:Z1,drawerBackground:"subtle",children:[jsxs(D,{paddingLeft:Ao.padding.horizontal.lg,paddingRight:Ao.padding.horizontal.sm,display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",backgroundColor:"background.primary.subtle",className:X1,children:[jsx(Q,{id:o,elementType:"h3",type:"title",size:"md",children:t(Bo.help)}),jsx(L,{icon:XIcon,size:"md",variant:"secondary","aria-label":t(Bo.close),onPress:e})]}),jsx(U,{className:ob}),jsxs(D,{paddingX:Ao.padding.horizontal.lg,role:"table","aria-labelledby":o,backgroundColor:"background.primary.subtle",children:[jsx("div",{role:"rowgroup",children:jsxs(D,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Ao.padding.vertical.md,color:"text.primary",children:[jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",children:t(Bo.action)}),jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",style:{textTransform:"capitalize"},children:t(Bo.shortcut)})]})}),jsx("div",{role:"rowgroup",children:ib.map(([a,n],i)=>jsxs(Fragment$1,{children:[jsxs(D,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Ao.padding.vertical.xs,style:{minHeight:40},children:[jsx(Q,{type:"subtitle",size:"sm",role:"cell",children:t(Bo[camelCase(a)])}),jsx(Q,{elementType:"kbd",type:"subtitle",size:"sm",role:"cell",children:getOsSpecificKeyboardShortcutLabel(n,true)})]}),i!==ib.length-1&&jsx(U,{})]},a))})]})]})})})},Bo=G({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 kn=wt.forwardRef(({value:r,defaultValue:e,onChange:t,placeholder:o,spellCheck:a,textBoxRef:n,isInline:i,isMinimal:s,isDisabled:l,editableContentAriaLabel:p,editorHandle:c,autoFocus:d,saveOnEnter:m,onSave:u},b)=>{let y=wt.useRef(null),[f,g]=useControlledState(r,e||"",t),v=useCallback(R=>{g(R.currentTarget.value||"");},[g]),h=useCallback(R=>{(m&&R.key==="Enter"&&!R.shiftKey||(R.ctrlKey||R.metaKey)&&R.key==="Enter")&&(R.preventDefault(),u());},[m,u]);useImperativeHandle(b,()=>({clear:()=>{g("");}}));let _=useCallback(R=>{R.currentTarget.style.height="16px",R.currentTarget.style.height=R.currentTarget.scrollHeight+"px";},[]);useGranularLayoutEffect(()=>{let R=y.current;R&&(R.style.height="16px",R.style.height=R.scrollHeight+"px");},[s],[f]),useImperativeHandle(c,()=>({setCaretPosition:R=>{y.current&&(y.current.focus(),y.current.setSelectionRange(R,R));},focus:()=>{y.current&&y.current.focus();}}));let{focusProps:z,isFocused:P,isFocusVisible:w}=useFocusRing(),{hoverProps:C,isHovered:k}=useHover({}),$=filterTruthyValues({"data-focus-visible":w,"data-hovered":k,"data-focused":P});return jsx("textarea",{...mergeProps(z,C,$),ref:M(y,n),className:classNames(s?tb:[Cn(),Pn({isInline:i}),ab]),autoFocus:d,onChange:v,disabled:l,onInput:_,value:f,placeholder:o,spellCheck:a,"aria-label":p,onKeyDown:h})});kn.displayName="PlainEditor";var jo="mention",In="mention_input",hb=wt.forwardRef(({onCancel:r,editor:e,element:t,onSelectionChange:o},a)=>{let{containerRef:n,items:i,maxMentionableUsersSuggestions:s}=useContext(Rn),l=useSelected(),[p,c]=useState(""),{contains:d}=useFilter({sensitivity:"base"}),{formatMessage:m}=A(),u=useMemo(()=>{let S=i.filter(E=>p===""||d(E.displayName,p)).map(E=>({id:E.id,label:E.displayName,data:E}));return s?take(S,s):S},[i,s,p,d]),b=useCallback(S=>jsx(Item,{children:S.label},S.id),[]),y=useCallback((S=false)=>{let E=findNodePath(e,t);E&&(removeNodes(e,{at:E}),S&&focusEditor(e));},[e,t]),f=useComboBoxState({items:u,children:b,menuTrigger:"focus",onSelectionChange:S=>{y(true),o?.(S);}}),g=wt.useRef(null),v=wt.useRef(null),h=wt.useRef(null),_=wt.useRef(null),z=useHTMLInputCursorState(v);useInteractOutside({ref:_,onInteractOutside:()=>{f.close();}});let{inputProps:P,listBoxProps:w}=useComboBox({defaultItems:u,inputRef:v,buttonRef:g,listBoxRef:h,popoverRef:_,menuTrigger:"focus","aria-label":m(DR.mention)},f);useEffect(()=>{v.current?.focus();},[]);let C=useCallback((S="manual",E=false)=>{y(E),r?.(S,f.inputValue);},[r,y,f.inputValue]),k=useRef(l);useEffect(()=>{k.current&&!l&&C("deselect"),k.current=l;},[l,C]);let $=z?.atStart??false,R=z?.atEnd??false,T=useCallback(S=>{S.key==="Backspace"&&$?C("backspace",true):S.key==="Escape"?C("escape",true):S.key==="ArrowLeft"&&$?C("arrowLeft",true):S.key==="ArrowRight"&&R&&C("arrowRight",true);let E=Hotkeys.isUndo(S)&&e.history.undos.length>0,N=Hotkeys.isRedo(S)&&e.history.redos.length>0;(E||N)&&(S.preventDefault(),e[E?"undo":"redo"](),focusEditor(e));},[$,R,C,e]),I=useMemo(()=>{if(!CSS.supports("field-sizing","content")){let S=re(v.current),E=v.current?S?.getComputedStyle(v.current).font:void 0;return {width:E?getTextDimensions({text:f.inputValue,font:E}).width+10:"4ch"}}},[f.inputValue]);return jsxs(kt.Provider,{value:f,children:[jsx("input",{...mergeProps(P,{onKeyDown:T,onBlur:()=>{C("blur",true);},onChange:S=>{c(S.target.value);}}),style:I,className:J1,ref:M(a,v)}),jsx(we,{triggerRef:n,isNonModal:true,ref:_,state:f,crossOffset:-2,children:jsx(me,{...w,items:void 0,autoFocus:"first",ref:h,className:classNames(lt,sprinkles({width:"full"})),renderOption:zb})})]})});hb.displayName="MentionInputContentElement";var gl=withRef(({className:r,...e},t)=>{let{children:o,editor:a,element:n}=e,{items:i}=useContext(Rn),s=useRef(null),[l,p]=useState(null);useEffect(()=>{let m=findNodePath(a,n);if(!m)return;let u=getPointBefore(a,m);if(!u)return;let b=createPointRef(a,u);return p(b),()=>{b.unref();}},[a,n]);let c=useCallback(()=>{let m=s.current?.getRootNode()instanceof ShadowRoot;moveSelection(a,{unit:"offset"}),moveSelection(a,{unit:"character",distance:1}),Kr()&&m&&focusEditor(a);},[a]),d=useCallback(m=>{if(!m)return;let u=s.current?.getRootNode()instanceof ShadowRoot,b=i.find(f=>f.id===m);invariant(b,"User not found");let y={type:jo,value:b.id,displayName:b.displayName,children:[{text:""}]};insertNodes(a,[y,{text:" "}]),u?setTimeout(()=>{c();},0):c();},[a,i,c]);return jsxs(PlateElement,{as:"span","data-slate-value":n.value,contentEditable:false,className:r,ref:t,...e,children:[jsx(hb,{onCancel:(m,u)=>{m!=="backspace"&&insertText(a,"@"+u,{at:l?.current??void 0}),(m==="arrowLeft"||m==="arrowRight")&&moveSelection(a,{distance:1,reverse:m==="arrowLeft"});},onSelectionChange:d,ref:s,element:n,editor:a}),o]})});gl.displayName="MentionInputElement";var vl=withRef(({className:r,onClick:e,children:t,...o},a)=>{let n=useElement();return jsxs(PlateElement,{as:"span",className:r,contentEditable:false,"data-user-id":n.value,onClick:getHandler(e,n),ref:a,...o,children:["@",n.displayName,t]})});vl.displayName="MentionElement";var _b=(r,{options:{trigger:e,triggerPreviousCharPattern:t,triggerQuery:o}})=>{let{insertText:a}=r,n=i=>i===e;return r.insertText=i=>{if(!r.selection||!n(i)||o&&!o(r)){a(i);return}let s=getEditorString(r,getRange(r,r.selection,getPointBefore(r,r.selection)));if(t?.test(s)){Sn(r);return}a(i);},r},DR=G({mention:{defaultMessage:"Mention",id:"mention"}});function Cb({className:r,children:e,...t}){return jsx(PlateElement,{asChild:true,className:r,...t,children:jsx("p",{children:e})})}function WR(r){return Object.entries(r).map(([e,t])=>`${kebabCase(e)}:${t}`).filter(([,e])=>!!e).join(";")}function YR(r){return "text"in r}function ZR(r){return r.replaceAll("&","&amp;").replaceAll("<","&lt;").replaceAll(">","&gt;").replaceAll('"',"&quot;").replaceAll("'","&#039;")}function Ho(r){if(!r)return "";function e(t){if(YR(t)){let a=ZR(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="${WR(filterTruthyValues({color:t.color||void 0,backgroundColor:t.backgroundColor||void 0}))}">${a}</span>`),a}let o=t.children?.map(Ho).join("");switch(t.type){case ELEMENT_PARAGRAPH:return `<p>${o}</p>`;case ELEMENT_LINK:return `<a href="${t.url}">${o}</a>`;case jo:return `<span data-user-id="${t.value}">${t.displayName}</span>`;default:return o}}return Array.isArray(r)?r.map(t=>e(t)).join(""):e(r)}function XR(r){return r?(r=r.trim(),r.endsWith(";")&&(r=r.slice(0,-1)),Object.fromEntries(r.split(";").map(e=>e.split(":").map(t=>t.trim())).map(([e,t])=>[camelCase(e),t]))):{}}function Cl(r){r.startsWith("<p>")||(r=`<p>${r}</p>`);let e=new DOMParser().parseFromString(Pb.default.sanitize(r),"text/html"),t=e.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 o=e.querySelectorAll("br");for(let a of o)a.outerHTML=a.closest("p")?`
14
- `:"<p>";return kb(e.body)}function kb(r,e){if(r.nodeType===Node.TEXT_NODE)return jsx$1("text",e,r.textContent);if(r.nodeType!==Node.ELEMENT_NODE)return null;let t={...e};switch(r.nodeName.toUpperCase()){case "B":{t.bold=true;break}case "I":{t.italic=true;break}case "EM":{t.italic=true;break}case "U":{t.underline=true;break}case "SPAN":{let a=XR(r.getAttribute("style")||"");a["text-decoration"]==="underline"&&(t.underline=true),a.color&&(t.color=a.color),a.backgroundColor&&(t.backgroundColor=a.backgroundColor);break}}let o=[...r.childNodes].flatMap(a=>kb(a,t));switch(o.length===0&&o.push(jsx$1("text",t,"")),r.nodeName.toUpperCase()){case "BR":return jsx$1("text",e,`
15
- `);case "SPAN":{let a=r.dataset.userId;return a?jsx$1("element",{type:jo,value:a,displayName:r.textContent},{text:""}):o}case "P":return jsx$1("element",{type:ELEMENT_PARAGRAPH},o);case "A":return jsx$1("element",{type:ELEMENT_LINK,url:r.getAttribute("href")},o);default:return o}}function Ib(r){let e=findNode(r,{match:{type:getPluginType(r,ELEMENT_LINK)}}),[t]=e||[{url:""}];return t?.url}function Sn(r){let e={children:[{text:" "}],type:In};r.insertNode(e);}var JR=createPluginFactory({isElement:true,isInline:true,isMarkableVoid:true,isVoid:true,key:jo,options:{trigger:"@",triggerPreviousCharPattern:/^$|^[\s"']$/},plugins:[{isElement:true,isInline:true,isVoid:true,key:In}],withOverrides:_b}),Sb=createPlugins([createParagraphPlugin({component:Cb}),createBoldPlugin({component:withProps(PlateLeaf,{as:"b"})}),createItalicPlugin({component:withProps(PlateLeaf,{as:"i"})}),createUnderlinePlugin({component:withProps(PlateLeaf,{as:"u"})}),createFontColorPlugin(),createFontBackgroundColorPlugin(),createLinkPlugin({component:Rb}),JR({component:vl})],{components:{[In]:gl}});var At={Add:"add",Edit:"edit",Show:"show"},Mb=({isDisabled:r})=>{let{formatMessage:e}=A(),t=useEditorRef();return jsxs(je,{type:"dialog",children:[jsx(He,{children:jsx(L,{icon:LinkIcon,size:"sm",isDisabled:r,"aria-label":e(Bt.addLink),className:Rr,preventFocusOnPress:true})}),jsx(Ae,{className:sprinkles({boxShadow:"medium"}),placement:"top end",children:({close:o})=>jsx(ze,{size:"content",style:{minWidth:240},children:jsx(i$,{close:()=>{o(),setTimeout(()=>{focusEditor(t,t.selection);},0);}})})})]})},i$=({close:r})=>{let e=useEditorRef(),{formatMessage:t}=A(),o=useEditorSelector(p=>Ib(p),[]),[a,n]=wt.useState(o?At.Show:At.Add),[i,s]=wt.useState(o||""),l=jsx(D,{padding:"lg",children:jsx(pt,{label:t(Bt.link),value:i,autoFocus:true,onChange:s,placeholder:"https://yourdomain.com"})});return jsxs(Fragment,{children:[a===At.Add&&jsxs(Fragment,{children:[l,jsx(D,{display:"flex",justifyContent:"flex-end",padding:"lg",className:K1,children:jsx(K,{isDisabled:!isUrl(i,true),label:t(Bt.addLink),size:"sm",onPress:()=>{upsertLink(e,{url:i,skipValidation:true}),r?.();},preventFocusOnPress:true})})]}),a===At.Show&&jsxs(Fragment,{children:[jsx(D,{padding:"lg",children:jsx(Q,{type:"subtitle",size:"sm",children:o})}),jsxs(D,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(K,{label:t(Bt.editLink),size:"sm",variant:"secondary",onPress:()=>{n(At.Edit);},style:{flex:1,justifyContent:"center"}}),jsx(K,{label:t(Bt.removeLink),size:"sm",onPress:()=>{unwrapLink(e),r?.();},preventFocusOnPress:true,style:{flex:1,justifyContent:"center"}})]})]}),a===At.Edit&&jsxs(Fragment,{children:[l,jsxs(D,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(K,{label:t(Bt.cancel),size:"sm",variant:"secondary",onPress:()=>{n(At.Show),r?.();}}),jsx(K,{label:t(Bt.save),size:"sm",onPress:()=>{upsertLink(e,{url:i,skipValidation:true}),r?.();}})]})]})]})};function Rb({className:r,children:e,...t}){return jsx(PlateElement,{asChild:true,className:r,...t,children:jsx("a",{className:Ua({size:"sm"}),children:e})})}var Bt=G({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 l$=parseColor("#ffffff00").toString("hexa"),Pl=[{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"}];[...Pl,{label:"Transparent",color:l$}];var Tn=({nodeType:r,icon:e,ariaLabel:t,isDisabled:o})=>{let a=useEditorSelector(i=>isMarkActive(i,r),[]),n=useEditorRef();return jsx(ke,{variant:"tertiary",isSelected:a,size:"sm",icon:e,"aria-label":t,isDisabled:o,onPress:()=>{toggleMark(n,{key:r});},preventFocusOnPress:true})},kl=({nodeType:r,"aria-label":e,isDisabled:t})=>{let{updateColor:o,clearColor:a,color:n}=useColorDropdownMenuState({customColors:[],colors:[],nodeType:r}),i=useCallback(({ref:l,triggerProps:p})=>jsx(L,{icon:r==="color"?TextIcon$1:HighlightTextIcon,"aria-label":e,size:"md",variant:"popover",isDisabled:t,className:Rr,preventFocusOnPress:true,...p,ref:l}),[r,e,t]),s=useCallback(l=>{l?o(l.toString("rgba")):a();},[a,o]);return jsx(wr,{presets:Pl,allowRemoval:true,pickerMode:"lazy",placement:"top end",colorLabel:false,renderTriggerButton:i,value:n||"#000000",onChange:s,isDisabled:t})};var B$=[{type:ELEMENT_PARAGRAPH,children:[{text:""}]}],Rn=wt.createContext({items:[],containerRef:{current:null},maxMentionableUsersSuggestions:10}),Rl=wt.forwardRef(({value:r,defaultValue:e,onChange:t,style:o,spellCheck:a,placeholder:n,isInline:i,isDisabled:s,editableContentAriaLabel:l,containerRef:p,onHelpDialogOpenRequest:c,mentionableUsers:d,editorHandle:m,maxMentionableUsersSuggestions:u,autoFocus:b,editorRef:y,saveOnEnter:f,onSave:g},v)=>{let h=useRef(null),_=useId(),{formatMessage:z}=A(),P=useRef(null),w=P.current,C=useRef(null),k=useMemo(()=>w?.getRootNode()instanceof ShadowRoot,[w]),[$,R]=useControlledState(r?Cl(r):void 0,Cl(e||"<p></p>"),S=>{t&&t(Ho(S));}),{keyboardProps:T}=useKeyboard({onKeyDown:S=>{(f&&S.key==="Enter"&&!S.shiftKey||(S.ctrlKey||S.metaKey)&&S.key==="Enter")&&(S.preventDefault(),g()),S.altKey&&S.key==="F10"?(S.preventDefault(),h.current&&h.current.querySelector("button")?.focus()):S.continuePropagation(),Kr()&&k&&C.current&&focusEditor(C.current);}});useEffect(()=>{s&&C.current&&deselect(C.current);},[s]),useImperativeHandle(v,()=>({startMention:()=>{C.current&&!P.current?.querySelector("input[role='combobox']")&&Sn(C.current);}})),useImperativeHandle(m,()=>({setCaretPosition:S=>{C.current&&(focusEditor(C.current),moveSelection(C.current,{distance:S,unit:"character"}));},focus:()=>{C.current&&focusEditor(C.current);}}));let I=useMemo(()=>({items:d||[],containerRef:p,maxMentionableUsersSuggestions:u}),[d,p,u]);return jsx(Rn.Provider,{value:I,children:jsxs(Plate,{initialValue:$||B$,plugins:Sb,editorRef:M(C,y||null),onChange:S=>{R(S);},children:[jsxs(xn,{className:wn,"aria-controls":_,ref:h,children:[jsxs(D,{display:"flex",flexDirection:"row",role:"group",gap:"xs",paddingX:"sm",children:[jsx(Tn,{nodeType:MARK_BOLD,icon:BoldIcon,ariaLabel:z(Mr.bold),isDisabled:s}),jsx(Tn,{nodeType:MARK_ITALIC,icon:ItalicIcon,ariaLabel:z(Mr.italic),isDisabled:s}),jsx(Tn,{nodeType:MARK_UNDERLINE,icon:UnderlineIcon,ariaLabel:z(Mr.underline),isDisabled:s})]}),jsx(U,{orientation:"vertical",className:Lo}),jsx(kl,{nodeType:MARK_COLOR,"aria-label":z(Mr.fontColor),isDisabled:s}),jsx(U,{orientation:"vertical",className:Lo}),jsx(kl,{nodeType:MARK_BG_COLOR,"aria-label":z(Mr.backgroundColor),isDisabled:s}),jsx(U,{orientation:"vertical",className:Lo}),jsx(Mb,{isDisabled:s}),jsx(U,{orientation:"vertical",className:Lo}),jsx(L,{className:Rr,icon:QuestionmarkCircleIcon,size:"sm","aria-label":z(Mr.help),onPress:c})]}),jsx(U,{variant:"secondary"}),jsx("div",{...T,ref:P,children:jsx(PlateContent,{id:_,disabled:s,readOnly:s,style:o,placeholder:n,autoFocus:b,spellCheck:a,"aria-label":l,className:classNames(Cn({isDisabled:s}),Pn({isInline:i})),renderPlaceholder:({attributes:S,children:E})=>jsx("span",{...S,className:sprinkles({paddingY:"lg"}),children:E})})})]})})});Rl.displayName="RichEditor";var zb=({key:r,value:e},{isDisabled:t,optionProps:o,isFocused:a,_state:n},i)=>{let{hoverProps:s}=useHover({isDisabled:t}),{label:l,data:p}=e;return jsxs(Fragment,{children:[jsxs("li",{...mergeProps(o,s),className:Q1({isDisabled:t,isHovered:a}),"data-active":a,ref:i,children:[jsx(xr,{name:l,...p?.avatar}),jsxs(D,{display:"flex",flexDirection:"column",children:[jsx(Q,{type:"subtitle",size:"sm",children:l}),jsx(Q,{type:"helper",size:"sm",children:p?.description})]})]}),r===n.collection.getLastKey()?null:jsx(U,{})]})},Mr=G({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 Ob=wt.memo(wt.forwardRef(({className:r,style:e,"data-block-id":t,"data-block-class":o,enableRichText:a=false,onCancel:n,onSave:i,isInline:s=true,submitButtonIcon:l=ArrowUpCircleFilledIcon,submitButtonAriaLabel:p,cancelButtonAriaLabel:c,"aria-label":d,"aria-describedby":m,"aria-labelledby":u,"aria-details":b,editableContentAriaLabel:y="Editing Area",footerButtons:f,clearOnCancel:g,clearOnSave:v,...h},_)=>{let z=useRef(null),{formatMessage:P}=A(),w=useRef(null),C=useRef(null),k=useRef(null),$=!a&&h.variant==="minimal",R=useRef(null),[T,I]=wt.useState(h.value||h.defaultValue),S=h.isDisabled||h.isSaveDisabled||!getPlainText(T||""),{fieldProps:E}=useLabel({"aria-label":d,"aria-labelledby":u,"aria-describedby":m,"aria-details":b,labelElementType:"div"});$&&!h.avatarName&&console.warn("Editor: When using the minimal `variant` and `enableRichText` is `false`, you should provide an `avatarName`.");let N=useCallback(()=>{I(""),a?z.current?.reset():C.current?.clear();},[a]),O=useCallback(()=>{S||(i?.(a?Ho(z.current?.children):w.current.value),v&&N());},[N,v,a,i,S]),B=jsx(L,{variant:"ghost","aria-label":p||P(Tl.save),icon:l,isDisabled:S,size:"md",excludeFromTabOrder:$,className:$?eb:void 0,onPress:O,preventFocusOnPress:true}),[H,V]=wt.useState(false),{keyboardProps:F}=useKeyboard({onKeyDown:j=>{(j.metaKey||j.ctrlKey)&&j.shiftKey&&j.key==="h"&&(j.preventDefault(),V(true));}}),te=useCallback(j=>{I(j),h.onChange?.(j);},[h]);return jsxs("div",{...mergeProps(E,a?F:{}),role:"application",ref:M(k,_),style:e,"data-block-id":t,"data-block-class":o,className:classNames(Y1({isInline:s,isMinimal:$}),"BaselineUI-Editor",r),"aria-disabled":h.isDisabled,children:[$?jsxs(Fragment,{children:[s?jsx(xr,{className:W1,name:h.avatarName||""}):null,jsxs("div",{className:rb({isInline:s}),children:[jsx(kn,{isMinimal:$,textBoxRef:w,isInline:s,editableContentAriaLabel:y,...h,onChange:te,onSave:O}),B]})]}):jsxs(Fragment,{children:[a?jsx(Rl,{containerRef:k,ref:R,editorRef:z,isInline:s,editableContentAriaLabel:y,onHelpDialogOpenRequest:()=>{V(true);},...h,onChange:te,onSave:O}):jsxs(Fragment,{children:[!s&&jsx(U,{variant:"secondary"}),jsx(kn,{onCancel:n,textBoxRef:w,ref:C,isInline:s,editableContentAriaLabel:y,...h,onChange:j=>{I(j),h.onChange?.(j);},onSave:O})]}),jsx(U,{variant:"secondary"}),jsxs("div",{className:classNames(wn,sprinkles({justifyContent:"space-between"})),children:[jsxs(D,{paddingX:"sm",gap:"sm",display:"flex",children:[a&&h.mentionableUsers?jsx(L,{icon:AtIcon,size:"sm","aria-label":P(Tl.mention),onPress:()=>R.current?.startMention(),preventFocusOnPress:true}):null,f?.map(({type:j,props:J},Y)=>j==="action"?jsx(L,{...J,size:"sm",isDisabled:h.isDisabled||J.isDisabled},Y):jsx(ke,{...J,size:"sm",variant:"tertiary",isDisabled:h.isDisabled||J.isDisabled},Y))]}),jsxs(D,{children:[!!n&&jsx(L,{variant:"secondary",icon:XCircleFilledIcon,isDisabled:h.isDisabled,size:"md",onPress:()=>{n(),g&&N();},"aria-label":c||P(Tl.cancel)}),B]})]})]}),jsx(sb,{isOpen:H,onClose:()=>{V(false);}})]})}));Ob.displayName="Editor";var Tl=G({cancel:{defaultMessage:"Cancel",id:"cancel"},save:{defaultMessage:"Save",id:"save"},mention:{defaultMessage:"Mention",id:"mention"}});var Fb="_8kqf970 _1yep5z6po _1yep5z6pp _1yep5z6pq _1yep5z6m6 _1yep5z6m7 _1yep5z6m8 _1yep5z6oi _1yep5z6oj _1yep5z6ok _1yep5z614v _1yep5z614w _1yep5z614x _1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z615m _1yep5z615n _1yep5z615o _1yep5z6z9 _1yep5z6vi _1yep5z6vj _1yep5z6vk _1yep5z617s _1yep5z6101";var Hb=2,Ub=wt.forwardRef(({className:r,style:e,hideForKeyboard:t,scrollRef:o,label:a,delay:n=1500,smoothScroll:i=true,"data-block-id":s,"data-block-class":l},p)=>{let c=wt.useRef(null),d=useInteractionModality(),[m,u]=wt.useState(false),b=useCallback(()=>{let k=o?.current||be(c.current).body;return re(k).getComputedStyle(k).flexDirection==="column-reverse"?k.scrollTop+Hb>=0:k.scrollTop+k.clientHeight+Hb>=k.scrollHeight},[o]),[y,f]=wt.useState(b),{buttonProps:g,isPressed:v}=useButton({onPress:()=>{let k=o?.current||be(c.current).body;k.scrollTo({top:k.scrollHeight,behavior:i?"smooth":"auto"});}},c),{focusProps:h,isFocused:_,isFocusVisible:z}=useFocusRing(),{hoverProps:P,isHovered:w}=useHover({}),C=filterTruthyValues({"data-block-id":s,"data-block-class":l,"data-pressed":v,"data-focus-visible":z,"data-hovered":w,"data-focused":_});return useEffect(()=>{f(b());},[b]),useEffect(()=>{let k=o?.current||be(c.current).body,$="onscrollend"in re(k),R=()=>{setTimeout(()=>{u(false),f(b());},n);},T=()=>{u(true),$||R();};return k.addEventListener("scroll",T),k.addEventListener("scrollend",R),()=>{k.removeEventListener("scroll",T),k.removeEventListener("scrollend",R);}},[o,n,b]),jsx(AnimatePresence,{initial:false,children:(!t||d!=="keyboard")&&!m&&!y?jsxs(motion.button,{initial:{opacity:0,transform:"translateX(-50%) translateY(10px)"},animate:{opacity:1,transform:"translateX(-50%) translateY(0)"},exit:{opacity:0,transform:"translateX(-50%) translateY(10px)"},transition:{duration:.3},...mergeProps(g,h,P,C),className:classNames(Fb,Za({isFocusVisible:z,variant:"high-contrast",isHovered:w}),Xa({variant:"high-contrast"}),"BaselineUI-ScrollControlButton",r),style:e,ref:M(p,c),children:[jsx(ArrowDownCircleFilledIcon,{size:16,className:go({variant:"high-contrast"})}),a]}):null})});Ub.displayName="ScrollControlButton";var Ml="_1yep5z6k4 _1yep5z6k5 _1yep5z6k6 _1yep5z6kd _1yep5z6ke _1yep5z6kf",qb=x({defaultClassName:"_1v0p2z10 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69f _1yep5z69g _1yep5z69h",variantClassNames:{hasTitleAndIcon:{true:"_1yep5z6m6 _1yep5z6m7 _1yep5z6m8 _1yep5z6oo _1yep5z6op _1yep5z6oq"},hasNoCloseBtn:{true:"_1yep5z6mc _1yep5z6md _1yep5z6me _1yep5z6oo _1yep5z6op _1yep5z6oq _1yep5z6pu _1yep5z6pv _1yep5z6pw _1yep5z6ni _1yep5z6nj _1yep5z6nk"}},defaultVariants:{},compoundVariants:[[{hasTitleAndIcon:true,hasNoCloseBtn:true},"_1yep5z61hr _1yep5z61hs _1yep5z61ht"]]}),Gb="_1v0p2z10";var En=wt.forwardRef(({className:r,style:e,"data-block-id":t,"data-block-class":o,message:a,title:n,primaryActionLabel:i,cancelLabel:s,textInputProps:l,icon:p,iconColor:c,showCloseButton:d=true,onPrimaryAction:m,onCancel:u,autoFocusButton:b,isPrimaryActionDisabled:y},f)=>{let g=useId(),{formatMessage:v}=A(),h=n&&jsx(Q,{id:g,type:"title",size:"sm",elementType:"h3",children:n});return jsxs(ze,{className:r,style:e,"data-block-id":t,"data-block-class":o,size:"sm",variant:"primary",role:"alertdialog",ref:f,"aria-labelledby":g,children:[jsxs("div",{className:qb({hasTitleAndIcon:!!(p&&n),hasNoCloseBtn:!d}),children:[jsxs(D,{display:"flex",justifyContent:"space-between",alignItems:"center",flexDirection:"row",children:[p?jsx(p,{style:{color:c},size:24}):null,!p&&h,d?jsx(L,{icon:XIcon,variant:"secondary",size:"md","aria-label":v(p4.close),onPress:u}):null]}),p?h:null]}),a?jsx(D,{elementType:"section",className:Gb,paddingX:"lg",paddingBottom:"lg",typography:"body.sm.regular",color:"text.primary",children:a}):null,l?jsx(D,{paddingX:"lg",paddingBottom:"lg",children:jsx(pt,{...l})}):null,s||i?jsxs(Fragment,{children:[jsx(U,{}),jsxs(D,{padding:"lg",display:"flex",gap:"xl",children:[s?jsx(K,{variant:"secondary",className:Ml,label:s,onPress:u,autoFocus:b==="cancel"}):null,i?jsx(K,{className:Ml,label:i,onPress:m,autoFocus:b==="primary",isDisabled:y}):null]})]}):null]})});En.displayName="AlertDialog";var p4=G({close:{id:"close",defaultMessage:"Close",description:"Close button label"}});var Kb="_1t55bp71",Wb="_1yep5z6e3 _1yep5z6eu _1yep5z6iy _1yep5z6iz _1yep5z6j0 _1yep5z69i _1yep5z69j _1yep5z69k",Yb="_1t55bp70";var y4=f4(),Zb=wt.forwardRef(({className:r,style:e,children:t,"data-block-id":o,"data-block-class":a,showCaret:n},i)=>{let s=useMemo(()=>{let l=t;return (!t||Array.isArray(t)&&t.length===0)&&(l=""),y4.render(l)},[t]);return jsx("div",{className:classNames(Wb,Yb,{[Kb]:n},"BaselineUI-Markdown",r),"data-block-id":o,"data-block-class":a,style:e,ref:i,dangerouslySetInnerHTML:{__html:s}})});Zb.displayName="Markdown";function eg(r){let{formatMessage:e,locale:t}=A(),[o,a]=wt.useState(false),[n,i]=wt.useState(0),[s,l]=wt.useState(0),[p,c]=wt.useState(false);useEffect(()=>{if(!r.current)return;let u=r.current,b=()=>{a(false),i(0);},y=()=>{p||i(u.currentTime*100/u.duration);},f=()=>{l(u.duration);};return u.addEventListener("ended",b),u.addEventListener("timeupdate",y),u.addEventListener("loadedmetadata",f),()=>{u.removeEventListener("ended",b),u.removeEventListener("timeupdate",y),u.removeEventListener("loadedmetadata",f);}},[p,r]);let d=useCallback(()=>{(async()=>r.current&&(r.current.paused?(await r.current.play(),a(true),announce(e(Jb.playing),"polite")):(r.current.pause(),a(false),announce(e(Jb.paused),"polite"))))();},[e,r]),m=useCallback(u=>{r.current&&(r.current.currentTime=u*r.current.duration/100,announce(v4(r.current.currentTime,t.locale),"assertive"));},[t.locale,r]);return {isPlaying:o,progress:n,duration:s,togglePlay:d,seek:m,setProgress:i,formattedCurrentTime:r.current?.currentTime?Qb(r.current?.currentTime):"00:00",formattedDuration:s?Qb(s):"00:00",setIsSliderDragging:c}}var Jb=G({playing:{id:"playing",defaultMessage:"Playing"},paused:{id:"paused",defaultMessage:"Paused"}});function v4(r,e){let t=Math.floor(r/3600),o=Math.floor(r%3600/60),a=r%60,n={...t&&{hours:t},...o&&{minutes:o},seconds:Math.floor(a)};return new Intl.DurationFormat(e,{style:"long"}).format(n)}function Qb(r){let e=Math.floor(r%3600/60),t=Math.floor(r%60);return [e,t].map(o=>o.toString().padStart(2,"0")).join(":")}var tg="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69o _1yep5z69p _1yep5z69q",rg="rta2n91 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6101 _1yep5z6vl _1yep5z6vm _1yep5z6vn _1yep5z617q _1yep5z610y",og="rta2n90";var ig=wt.forwardRef(({className:r,style:e,size:t="lg",sources:o,"data-block-id":a,"data-block-class":n,...i},s)=>{let l=wt.useRef(null),{isPlaying:p,progress:c,duration:d,togglePlay:m,seek:u,formattedDuration:b,formattedCurrentTime:y,setProgress:f,setIsSliderDragging:g}=eg(l),{formatMessage:v}=A(),h=filterTruthyValues({"data-block-id":a,"data-block-class":n,"data-state":p?"playing":"paused","data-loaded":d>0});return jsxs("div",{...h,...i,className:classNames(tg,"BaselineUI-AudioPlayer",r),role:"group",style:e,ref:s,children:[jsx(VisuallyHidden,{children:jsx("audio",{ref:l,children:o.map(({url:_,type:z})=>jsx("source",{src:_,type:z},_))})}),jsx(ke,{icon:p?PauseIcon:PlayIcon,variant:"toolbar",isSelected:p,size:t,"aria-label":v(p?Nl.pause:Nl.play),style:{borderRadius:"50%"},onPress:m}),jsxs("div",{className:rg,children:[jsx("span",{"aria-hidden":true,children:y}),jsx(nr,{"aria-label":v(Nl.audioTimeline),value:c,minValue:0,maxValue:100,className:og,onChange:_=>{f(_),g(true);},onChangeEnd:_=>{u(_),g(false);}}),jsx("span",{"aria-hidden":true,children:b})]})]})});ig.displayName="AudioPlayer";var Nl=G({play:{id:"play",defaultMessage:"Play"},pause:{id:"pause",defaultMessage:"Pause"},audioTimeline:{id:"audioTimeline",defaultMessage:"Audio timeline"}});var sg="_1w920rnd _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6g1 _1yep5z6ig _1yep5z6ih _1yep5z6ii",lg="_1w920rn1 _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k",pg="_1w920rn0 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6le",Ln=x({defaultClassName:"_1w920rn2 _1yep5z6d6 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6id _1yep5z6ie _1yep5z6if",variantClassNames:{isFocusVisible:{true:"_1yep5z6lt _1yep5z6lr _1yep5z6hx"},isSelected:{true:"_1yep5z6lt _1yep5z6lr _1yep5z6hx"},isLoading:{true:"_1yep5z616g _1yep5z616h _1yep5z616i"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:true,isSelected:true},"_1w920rn6 _1yep5z6lt _1yep5z6lr _1yep5z6hx"]]}),cg="_1w920rnb _1yep5z6lo",dg=x({defaultClassName:"_1w920rn7 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6g5 _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocusVisible:{true:"_1w920rn8 _1yep5z6lt _1yep5z6lr _1yep5z6hx"},isSelected:{true:"_1w920rn9"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:true,isSelected:true},"_1w920rna _1yep5z61ty _1yep5z61tx _1yep5z61q4"]]}),ug="_1w920rnc";var An=({items:r,ulRef:e,containerClassName:t,previewClassName:o,itemDataAttribute:a,showCount:n=false})=>{let{length:i}=r,s=wt.useRef(null);return useLayoutEffect(()=>{if(!s.current)return;let l=s.current.closest(t)?.querySelector(`[${a}='${r?.at(-1)?.key}']`)?.cloneNode(true);invariant(l,"Node is not defined."),s.current?.prepend(l);},[r,e,t,a]),jsx("div",{className:o,ref:s,children:n&&i>1?jsx(D,{backgroundColor:"background.secondary.medium",borderRadius:"full",typography:"label.md.medium",color:"text.primary",position:"absolute",paddingX:"md",className:ug,children:i}):null})};function fg(r,e){return r.find(t=>t.id===e)}function yg(r,e,t){let o=[...r],a=o.filter(s=>t.has(s.id)),n=o.filter(s=>!t.has(s.id)),i=n.findIndex(s=>s.id===e);return n.flatMap((s,l)=>l===i?[...a,s]:s)}function bg(r,e,t){let o=[...r],a=o.filter(s=>t.has(s.id)),n=o.filter(s=>!t.has(s.id)),i=n.findIndex(s=>s.id===e);return n.flatMap((s,l)=>l===i?[s,...a]:s)}function Ll(r){return r.map(e=>({id:e.id,label:e.label,data:{src:e.src,alt:e.alt}}))}function Bn(r){return r.map(e=>({id:e.id,label:e.label,src:e.data?.src,alt:e.data?.alt}))}var M4=({fit:r,item:e,deleteElement:t})=>{let{formatMessage:o}=A(),a=useReducedMotion(),{imgProps:n,isLoading:i}=er({src:e.data?.src,alt:e.data?.alt??""});return i?jsx(vr,{"aria-label":o(qo.loading)}):jsx(motion.div,{role:"img",initial:{opacity:a?1:0},animate:{opacity:1},exit:{opacity:a?1:0},"aria-label":n.alt,style:{backgroundImage:`url(${n.src})`,backgroundSize:r},className:cg,children:t})},hg=({item:r,options:{optionProps:e,isFocusVisible:t,isSelected:o,isFocused:a,isDisabled:n,isPressed:i},liRef:s,fit:l="contain",onDelete:p,className:c,imageClassName:d,imageLabelClassName:m,imageDimensions:u,style:b,layoutTransition:y=true,renderImage:f=(g,{deleteElement:v})=>jsx(M4,{item:g,deleteElement:v,fit:l})})=>{let g=useId(),{formatMessage:v}=A(),{value:h}=r;invariant(h&&tt(h),"Expected value to be a list option");let _=p?jsx("div",{className:sg,children:jsx(L,{"aria-label":v(qo.delete),size:"xs",icon:XIcon$1,onPress:()=>{p(h.id);},UNSAFE_NON_INTERACTIVE:true})}):null,z=Bn([h])[0],P=useCallback(T=>{let I={},S=typeof T=="function"?T(z,{isSelected:o}):T;return S&&(I.width=typeof S.width=="string"?Bl[S.width]:S.width,I.aspectRatio="height"in S?`${I.width} / ${S.height}`:S?.aspectRatio?.toString()),I},[z,o]),w=useMemo(()=>({isFocusVisible:t,isSelected:o,isFocused:a,isDisabled:n,isPressed:i}),[t,o,a,n,i]),C=useReducedMotion(),k=typeof y=="boolean"?y:!C,$=typeof y=="object"?y:void 0,R=k?motion.li:"li";return jsxs(R,{...mergeProps(e,k?{layout:true,transition:$}:void 0),ref:s,className:classNames(lg,rt(c,z,w)),"aria-labelledby":g,style:oa(b,z,w),children:[jsx(D,{display:"flex",flexDirection:"column",flex:1,justifyContent:"center",alignItems:"center",children:jsx("div",{className:classNames(Ln({isFocusVisible:t,isSelected:o,isLoading:true}),rt(d,z,w)),style:P(u),"data-image-key":h.id,children:f(h,{deleteElement:_??void 0,onDelete:p})})}),jsx("span",{id:g,className:classNames(dg({isFocusVisible:t,isSelected:o}),rt(m,z,w)),children:h.label})]})};var F4={width:0,display:"block"},xg={src:"src",alt:"alt"},Bl={sm:102,md:170},Cg=wt.forwardRef(({className:r,style:e,fit:t="cover",onReorder:o,"data-block-id":a,"data-block-class":n,onDelete:i,imageWidth:s=Bl.sm,aspectRatio:l=3/4,items:p,defaultItems:c=[],onKeyDown:d,imageContainerClassName:m,imageClassName:u,labelClassName:b,onListChange:y,renderImage:f,layoutTransition:g,imageDimensions:v={width:s,aspectRatio:l},imageContainerStyle:h,..._},z)=>{let P=wt.useRef(null),[w,C]=useState([]),{formatMessage:k}=A();useEffect(()=>{(l||s)&&console.warn("ImageGallery: aspectRatio and imageWidth are deprecated. Use imageDimensions instead.");},[s,l]);let[$,R]=useControlledState(_.selectedKeys,_.defaultSelectedKeys??[],_.onSelectionChange),[T,I]=useControlledState(p?Ll(p):void 0,Ll(c),y?B=>{y?.(Bn(B));}:void 0),S=useCallback(B=>{let H=B.target.key,V=B.keys;if(B.target.dropPosition==="before"){let F=yg(T,H,V);I(F);}else if(B.target.dropPosition==="after"){let F=bg(T,H,V);I(F);}o?.(B);},[T,o,I]),E=useCallback(()=>{i&&w.length&&(I(T.filter(B=>!w.includes(B.id))),i(new Set(w)),C([]));},[w,T,i,I]),N=useCallback((B,H,V)=>{let{value:F}=B;invariant(tt(F));let te={id:F.id,label:F.label,src:F.data?.src,alt:F.data?.alt};return jsx(hg,{item:B,options:H,liRef:V,fit:t,onDelete:i?j=>{C([j]);}:void 0,renderImage:f,className:rt(m,te,H),imageClassName:u,imageLabelClassName:b,imageDimensions:v,style:h,layoutTransition:g})},[t,i,f,m,u,b,v,h,g]),{keyboardProps:O}=useKeyboard({onKeyDown(B){if(d?.(B),B.key==="Backspace"||B.key==="Delete"){if(!i)return;if([...$].length)C([...$]);else {let V=B.target.dataset.key;C([V]);}}}});return jsxs("div",{...O,ref:z,style:e,className:classNames("BaselineUI-ImageGallery",r),"data-block-id":a,"data-block-class":n,children:[jsx(me,{..._,selectedKeys:$,items:T,onReorder:S,layout:"grid",orientation:"vertical",className:pg,ref:P,dropIndicatorStyle:F4,renderOption:N,renderDragPreview:B=>jsx(An,{items:B,ulRef:P,containerClassName:".BaselineUI-ImageGallery",previewClassName:Ln(),itemDataAttribute:"data-image-key",showCount:true}),onSelectionChange:R,getItems:B=>[...B].map(H=>{let V=fg(T,H);return {[xg.src]:V?.src||"",[xg.alt]:V?.alt||"",key:H}})}),jsx(Le,{isOpen:!![...w].length,onOpenChange:B=>{B||C([]);},children:jsx(Ue,{isDismissable:true,children:jsx(En,{showCloseButton:false,title:"Are you sure you want to delete this item?",primaryActionLabel:k(qo.delete),cancelLabel:k(qo.cancel),onCancel:()=>{C([]);},onPrimaryAction:E,autoFocusButton:"cancel"})})})]})});Cg.displayName="ImageGallery";var qo=G({delete:{id:"delete",defaultMessage:"Delete"},cancel:{id:"cancel",defaultMessage:"Cancel"},loading:{id:"loading",defaultMessage:"Loading"}});var Pg="_1sexph00",wg="_1sexph01 _1yep5z6189 _1yep5z618a _1yep5z618b _1yep5z61al _1yep5z61am _1yep5z61an _1yep5z61br _1yep5z61bs _1yep5z61bt _1yep5z619f _1yep5z619g _1yep5z619h _1yep5z61sg _1yep5z61sh _1yep5z61si";var Sg=wt.forwardRef(({className:r,style:e,items:t,"data-block-id":o,"data-block-class":a,hideLabel:n,size:i="md",isDisabled:s,showSelectedIcon:l=true,excludeFromTabOrder:p,onPress:c,isSelected:d,defaultSelected:m,onButtonSelectionChange:u,moreAriaLabel:b,optionStyle:y,optionClassName:f,triggerClassName:g,triggerStyle:v,tooltipProps:h,..._},z)=>{let{formatMessage:P}=A(),w=pe(),C=useSelectState({items:t,..._,defaultSelectedKey:_.defaultSelectedKey||t?.[0]?.id,children:w,validationState:_.validationState==="error"?"invalid":"valid"}),[k,$]=useControlledState(d,!!m,F=>{u?.({isSelected:F,selectedKey:C.selectedKey});}),{hoverProps:R,isHovered:T}=useHover({isDisabled:s}),I=useMemo(()=>{let F=C.collection.getItem(C.selectedKey),te=F?.textValue||F?.["aria-label"],j=F?.value,J=j?.icon,Y={size:i,isSelected:k,onPress:Me=>{$(!k),c?.(Me);},isDisabled:s,excludeFromTabOrder:p,className:typeof f=="function"?f(j,{isButton:true,isSelected:k}):f,style:typeof y=="function"?y(j,{isButton:true,isSelected:k}):y};return n&&J?jsx(ie,{variant:"inverse",size:"sm",includeArrow:false,text:te,placement:"bottom start",offset:4,...typeof h=="function"?h("button"):h,children:jsx(ke,{icon:J,"aria-label":te,variant:"toolbar",...Y})}):jsx(Wa,{iconStart:J,label:te,variant:"toolbar",...Y})},[p,n,k,s,c,f,y,$,i,C.collection,C.selectedKey,h]),S=_["aria-label"],E=useCallback(({buttonProps:F,ref:te})=>{delete F["aria-labelledby"];let j=b||`${P(Y4.more)} ${S}`;return jsx(ie,{variant:"inverse",size:"sm",includeArrow:false,text:j,placement:"bottom start",offset:4,...h,children:jsx(PressResponder,{...F,children:jsx(L,{"aria-label":j,ref:te,icon:CaretDownIcon,variant:"toolbar",size:i,className:({isFocusVisible:J})=>classNames(Ka({isSelected:k,isFocusVisible:J}),wg,g),style:v,isDisabled:s,excludeFromTabOrder:p})})})},[S,p,P,k,s,b,i,h,g,v]),N=filterTruthyValues({"data-block-id":o,"data-block-class":a,"data-hovered":T,"data-selected":k,"data-disabled":s,"data-expanded":C.isOpen}),O=oe(z),B=useMemo(()=>({state:C,popoverAnchorRef:O}),[C,O]),H=useCallback(F=>typeof f=="function"?f(F,{isButton:false,isSelected:C.selectionManager.isSelected(F.id)}):f,[f,C.selectionManager]),V=useCallback(F=>typeof y=="function"?y(F,{isButton:false,isSelected:C.selectionManager.isSelected(F.id)}):y,[y,C.selectionManager]);return jsx(Ja.Provider,{value:B,children:jsxs(D,{...R,role:"group",display:"inline-flex",flexDirection:"row",alignItems:"center",className:classNames(Pg,"BaselineUI-ButtonSelect",r),"aria-label":_["aria-label"],"aria-labelledby":_["aria-labelledby"],"aria-describedby":_["aria-describedby"],"aria-details":_["aria-details"],style:e,ref:O,...N,children:[I,jsx(ut,{isDisabled:s,showSelectedIcon:l,placement:"bottom start",items:t,..._,style:{width:20},optionClassName:H,optionStyle:V,variant:"ghost",renderTrigger:E})]})})});Sg.displayName="ButtonSelect";var Y4=G({more:{id:"more",defaultMessage:"More"}});var Rg=x({defaultClassName:"_18v88n10 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6ln",variantClassNames:{labelPosition:{top:"_1yep5z6157 _1yep5z6158 _1yep5z6159",start:"_1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z616m _1yep5z616n _1yep5z616o _1yep5z6vl _1yep5z6vm _1yep5z6vn"}},defaultVariants:{},compoundVariants:[]}),$g=x({defaultClassName:"_18v88n1p _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6eu _1yep5z6ln _1yep5z6ly _1yep5z6lq _1yep5z6dy",variantClassNames:{isDisabled:{true:"_18v88n1q _1yep5z6111"},labelPosition:{top:"_18v88n1r",start:"_18v88n1s"}},defaultVariants:{},compoundVariants:[]}),Tg=x({defaultClassName:"_18v88n1t _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6lk",variantClassNames:{validationState:{valid:"_18v88n1u",error:"_1yep5z610h",warning:"_1yep5z610p"},isReadOnly:{true:"_1yep5z6118"}},defaultVariants:{},compoundVariants:[]}),Dg=x({defaultClassName:"_18v88n1d _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6m1 _1yep5z6lz _1yep5z6h4 _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{validationState:{valid:"_18v88n1e",error:"_1yep5z612q",warning:"_18v88n1g"},isHovered:{true:"_18v88n1h"},isFocused:{true:"_1yep5z6wl _1yep5z6wm _1yep5z6wn _1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6xx _1yep5z6xy _1yep5z6xz _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z6184 _1yep5z6182 _1yep5z6134 _1yep5z617v _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"_18v88n1j"},variant:{primary:"_18v88n1k",ghost:"_18v88n1l"},isReadOnly:{true:"_1yep5z6140"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:true,isFocused:false,validationState:"valid"},"_1yep5z61u7 _1yep5z61u5 _1yep5z61pa"],[{variant:"ghost",isFocused:false,isHovered:false,validationState:"valid"},"_18v88n1n"],[{isHovered:true,validationState:"valid",isDisabled:false,isReadOnly:false,isFocused:false,variant:"primary"},"_1yep5z61pb"],[{isHovered:true,validationState:"warning",isDisabled:false,isReadOnly:false,isFocused:false},"_1yep5z61pb"],[{isReadOnly:true,variant:"primary",isFocused:false},"_18v88n1o"]]}),Mg=x({defaultClassName:"_18v88n13 _1yep5z6dy _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),Eg=x({defaultClassName:"_18v88n19 _1yep5z6iv _1yep5z6iw _1yep5z6ix",variantClassNames:{labelPosition:{top:"_1yep5z6t9 _1yep5z6ta _1yep5z6tb",start:"_1yep5z6n6 _1yep5z6n7 _1yep5z6n8 _1yep5z6157 _1yep5z6158 _1yep5z6159"},hasMessage:{true:"_18v88n1c"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:false},"_1yep5z61sj _1yep5z61sk _1yep5z61sl"]]}),Ng=x({defaultClassName:"_18v88n15 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z6lq",variantClassNames:{isFocusVisible:{true:"_1yep5z6127 _1yep5z614f _1yep5z617t"},isHovered:{true:"_1yep5z6127 _1yep5z614f _1yep5z617t"},isOpen:{true:"_1yep5z614f _1yep5z617t"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:true},"_1yep5z61oa _1yep5z61qi _1yep5z61tw"],[{isHovered:true},"_1yep5z61oa _1yep5z61qi _1yep5z61tw"],[{isOpen:true},"_1yep5z61qi _1yep5z61tw"]]});function Lg({allowsCustomValue:r,onValueChange:e,inputValue:t},o,a,n,i){let[s,l]=useState(null),p=useRef(false);useEffect(()=>{if(!e)return;let d=a.current,m=u=>{l(u.target);};return d?.addEventListener("focusin",m),()=>{d?.removeEventListener("focusin",m);}},[e,a,o.selectedKey]),useGranularEffect(()=>{o.selectedKey&&(e?.({value:o.selectedItem?.textValue,key:o.selectedKey}),p.current=false);},[o.selectedKey],[e,o.selectedItem]),useInteractOutside({ref:n,isDisabled:!e,onInteractOutside:d=>{!i.current?.contains(d.target)&&s===n.current&&r&&p.current&&(e?.({value:n.current?.value,key:null}),p.current=false);}}),useEffect(()=>{if(!e)return;let d=n.current,m=()=>{p.current=true;};return d?.addEventListener("input",m),()=>{d?.removeEventListener("input",m);}},[n,e]),useEffect(()=>{p.current=false;},[t]);let{keyboardProps:c}=useKeyboard({isDisabled:!e,onKeyDown:d=>{r&&d.key==="Enter"&&p.current?(e?.({value:n.current?.value,key:null}),p.current=false):d.key==="Escape"&&o.close(),d.continuePropagation();}});return {inputProps:c}}var Bg=wt.forwardRef(({className:r,style:e,inputStyle:t,inputClassName:o,"data-block-id":a,"data-block-class":n,label:i,items:s,showSelectedIcon:l=false,onSelectionChange:p,onInputChange:c,isInvalid:d=false,labelPosition:m="top",validationState:u="valid",variant:b="primary",toggleLabel:y,renderOption:f,showIcon:g=true,filter:v,minValue:h,maxValue:_,inputType:z="text",onInputSubmit:P,onValueChange:w,...C},k)=>{let $=useObjectRef(k),{contains:R}=useFilter({sensitivity:"base"}),T=pe(),I=useComboBoxState({...C,defaultFilter:v||R,defaultItems:s,onSelectionChange:p,onInputChange:c,children:T,validationState:d?"invalid":"valid"}),S=wt.useRef(null),E=wt.useRef(null),N=wt.useRef(null),O=wt.useRef(null),B=wt.useRef(null),{inputProps:H}=Lg({onValueChange:w,allowsCustomValue:C.allowsCustomValue,inputValue:C.inputValue},I,$,E,O),{buttonProps:V,inputProps:F,listBoxProps:te,labelProps:j,errorMessageProps:J,descriptionProps:Y,validationErrors:Me}=useComboBox({...C,inputRef:E,defaultItems:s,buttonRef:S,listBoxRef:N,popoverRef:O,validationState:u==="error"?"invalid":"valid"},I),Ee=C.errorMessage||Me.join(" "),Ce=ge({...C,errorMessage:Ee,descriptionProps:Y,errorMessageProps:J,labelPosition:m});Ee&&(u="error");let{hoverProps:Oe,isHovered:Je}=useHover({isDisabled:C.isDisabled}),{isFocused:ne,focusProps:ye,isFocusVisible:qt}=useFocusRing(),Gt=yr({isReadOnly:C.isReadOnly,validationState:u}),qr=filterTruthyValues({"data-read-only":C.isReadOnly,"data-disabled":C.isDisabled,"data-validation-state":u,"data-focused":ne,"data-focus-visible":qt}),{labelProps:Kt,fieldProps:X}=useLabel({label:i,"aria-label":C["aria-label"],"aria-labelledby":C["aria-labelledby"],"aria-describedby":C["aria-describedby"],"aria-details":C["aria-details"]}),{keyboardProps:q}=useKeyboard({onKeyDown:W=>{C.allowsCustomValue&&W.key==="Enter"&&P?.(F.value?.toString()??"");}}),{focusProps:ce}=useFocus({onBlur:()=>{C.allowsCustomValue&&F.value&&P?.(F.value?.toString()??"");}});return jsx(kt.Provider,{value:I,children:jsxs("div",{className:classNames(Rg({labelPosition:m}),r,"BaselineUI-ComboBox"),"data-block-id":a,"data-block-class":n,style:e,ref:$,children:[i||m==="start"&&Ce?jsxs("div",{className:Eg({labelPosition:m,hasMessage:!!Ce}),children:[jsx("label",{...mergeProps(j,Kt),className:Mg({isDisabled:C.isDisabled}),children:i}),m==="start"&&Ce]}):null,jsxs("div",{...Oe,className:Dg({validationState:u,isHovered:Je,isFocused:ne,variant:b,isReadOnly:!!C.isReadOnly,isDisabled:!!C.isDisabled}),ref:B,children:[jsx("input",{...mergeProps(F,H,ye,qr,X,ce,q,z==="number"?{type:"number",min:h,max:_,onKeyDown:W=>{(W.key==="ArrowUp"||W.key==="ArrowDown")&&W.preventDefault();}}:null),id:C.id,ref:E,className:classNames($g({isDisabled:C.isDisabled,labelPosition:m}),"BaselineUI-ComboBox-Input",o),style:t}),Gt&&g?jsx(Gt,{className:Tg({validationState:u,isReadOnly:C.isReadOnly}),size:16}):null,jsx(K,{...V,ref:S,variant:"popover",label:y,className:Ng({isFocusVisible:!C.isDisabled&&!C.isReadOnly&&qt,isHovered:!C.isDisabled&&!C.isReadOnly&&Je,isOpen:I.isOpen})})]}),jsx(we,{ref:O,triggerRef:B,state:I,crossOffset:-2,className:"BaselineUI-ComboBox-Popover",children:jsx(me,{...te,items:s,ref:N,renderOption:f,selectionMode:"single",showSelectedIcon:l,className:classNames(lt,"BaselineUI-ComboBox-ListBox")})}),m==="top"&&Ce]})})});Bg.displayName="ComboBox";var Og=x({defaultClassName:"byycd01 _1yep5z6d6 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6id _1yep5z6ie _1yep5z6if",variantClassNames:{},defaultVariants:{},compoundVariants:[]});var ql=wt.forwardRef(({enableReorder:r,...e},t)=>r?jsx(Fg,{ref:t,...e}):jsx(Gl,{ref:t,...e}));ql.displayName="GridListItem";var Gl=wt.forwardRef(({item:r,state:e,dropState:t,renderGridItem:o,dragHandleProps:a},n)=>{let i=oe(n),s=useGridListItem({node:r},e,i),l=e.selectionManager.selectionMode!=="none"&&e.selectionManager.selectionBehavior==="toggle",{checkboxProps:p}=useGridListSelectionCheckbox({key:r.key},e),c={...s,checkBoxProps:l?p:void 0,dragHandleProps:a};return jsxs("div",{"data-grid-list-item-key":r.key,children:[t?jsx(Wt,{target:{type:"item",key:r.key,dropPosition:"before"},dropState:t}):null,o?o(r,c,i):null,t&&e.collection.getKeyAfter(r.key)==null?jsx(Wt,{target:{type:"item",key:r.key,dropPosition:"after"},dropState:t}):null]},r.key)});Gl.displayName="BaseGridListItem";var Fg=wt.forwardRef(({dragState:r,item:e,...t},o)=>{let a=useDraggableItem({key:e.key,hasDragButton:true},r);return jsx(Gl,{item:e,dragHandleProps:a,ref:o,...t})});Fg.displayName="DraggableGridListItem";var xT=r=>{r.key==="Enter"||r.key==="Escape"||r.stopPropagation();},Hg=wt.forwardRef(({className:r,style:e,isEditing:t=false,"data-block-id":o,"data-block-class":a,gridListHandle:n,onReorder:i,enableReorder:s=false,layout:l="stack",orientation:p="vertical",renderGridItem:c,...d},m)=>{let u=pe(),b=useListState({...d,children:u}),y=wt.useRef(null),f=oe(m),{gridProps:g}=useGridList(d,b,f);sa({handle:n,type:"gridlist"},b,f);let{collectionProps:v,dragState:h,dropState:_}=ra({...d,onReorder:i,enableReorder:s,layout:l,orientation:p,preview:y,getItems:w=>[...w].map(C=>{let k=b.collection.getItem(C);return invariant(k,"Expected item to be defined."),{key:k.key.toString()}})},b,f),z=t?xT:g.onKeyDownCapture,P={state:b,dragState:h,dropState:_,enableReorder:s,renderGridItem:c};return jsxs("ul",{...mergeProps(g,v),className:classNames("BaselineUI-GridList",r),"data-block-id":o,"data-block-class":a,style:e,ref:f,"aria-rowcount":b.collection.size,onKeyDownCapture:z,children:[[...b.collection].map(w=>jsx(ql,{item:w,...P},w.key)),s?jsx(DragPreview,{ref:y,children:w=>jsx(An,{items:w,ulRef:f,containerClassName:".BaselineUI-GridList",previewClassName:Og(),itemDataAttribute:"data-grid-list-item-key"})}):null]})});Hg.displayName="GridList";var Vg="_1yep5z6f5",Ug="_1dc3b8m0";var qg=wt.forwardRef(({className:r,selectionMode:e,style:t,"data-block-id":o,"data-block-class":a,tooltipProps:n,icon:i,renderActionItem:s,...l},p)=>{let c=oe(p),d=pe(),m=useListState({...l,selectionMode:e,suppressTextValueWarning:true,children:d}),{actionGroupProps:u}=useActionGroup({...l,selectionMode:e,children:d},m,c),b=[...m.collection].map(y=>(invariant(y.value),jsx(TT,{item:y,state:m,isDisabled:l.isDisabled,onAction:l.onAction,tooltipProps:n,renderActionItem:s},y.key)));return i?jsxs(D,{...u,display:"flex",flexDirection:"row",gap:"md",alignItems:"center",className:classNames("BaselineUI-ActionGroup",r),"data-block-id":o,"data-block-class":a,style:t,ref:c,children:[jsx(i,{"aria-hidden":"true",size:24,className:Vg}),jsx(D,{display:"flex",flexDirection:"row",gap:"xs",flex:1,children:b})]}):jsx(D,{...u,display:"flex",flexDirection:"row",gap:"xs",className:classNames("BaselineUI-ActionGroup",r),"data-block-id":o,"data-block-class":a,style:t,ref:c,children:b})});qg.displayName="ActionGroup";var TT=({item:r,state:e,tooltipProps:t,renderActionItem:o,onAction:a,isDisabled:n})=>{let{buttonProps:i}=useActionGroupItem({key:r.key},e),s=n||e.selectionManager.isDisabled(r.key),l=e.selectionManager.isSelected(r.key);invariant(r.value);let{icon:p}=r.value;invariant(p);let c=useMemo(()=>(invariant(r.value),typeof t=="function"?t(r.value):t),[t,r.value]);return jsx(PressResponder,{...mergeProps(i,{onPress:()=>{a?.(r.key);}}),children:jsx(ie,{text:r.textValue,size:"sm",variant:"inverse",includeArrow:false,offset:4,...c,children:o?.(r,{isSelected:l,isDisabled:s})||jsx(L,{variant:"tertiary",icon:p,"aria-label":r.textValue,size:"sm",isDisabled:s,className:classNames({[Ug]:l},"BaselineUI-ActionGroup-Item")})})})};var Gg="ujkypy0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e",Kg="_1yep5z61r7 _1yep5z61r8 _1yep5z61r9 _1yep5z61hl _1yep5z61hm _1yep5z61hn";var Yg=wt.forwardRef(({className:r,style:e,items:t,optionsContainerClassName:o,label:a,icon:n,value:i,defaultValue:s,onChange:l,isDisabled:p,optionClassName:c,optionStyle:d,labelPosition:m="top","data-block-id":u,"data-block-class":b,shouldFocusWrap:y,tooltip:f=true,...g},v)=>{let h=useMemo(()=>t.map(z=>({id:z.color,label:z.label})),[t]),_=useId();return useEffect(()=>{!a&&!g["aria-label"]&&!g["aria-labelledby"]&&console.warn("ColorSwatchPicker: Please provide a label or aria-label for accessibility.");},[a,g]),jsxs(D,{...Ci(g),className:classNames("BaselineUI-ColorSwatchPicker",r),"data-block-id":u,"data-block-class":b,display:"flex",flexDirection:m==="top"?"column":"row",alignItems:m==="top"?"flex-start":"center",justifyContent:"space-between",gap:"md",style:e,ref:v,children:[n||a?jsxs(D,{display:"flex",alignItems:"center",gap:"md",children:[n?jsx(n,{"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary"})}):null,a?jsx(Q,{id:_,type:"label",size:"sm",children:a}):null]}):null,jsx(me,{className:classNames(Kg,o),selectionMode:"single",items:h,orientation:"horizontal",defaultSelectedKeys:s?[s]:void 0,disabledKeys:p?h.map(z=>z.id):void 0,isDisabled:p,selectedKeys:i?[i]:void 0,onSelectionChange:z=>{l?.([...z][0]);},optionClassName:c,optionStyle:d,renderOption:({key:z,textValue:P},{isSelected:w,isFocusVisible:C,isDisabled:k,optionProps:$},R)=>jsx("li",{...$,"data-disabled":k,className:classNames(Gg,$.className),ref:R,children:jsx(ft,{isFocusVisible:C,color:z,isSelected:w,"aria-label":P,isInteractive:true,isDisabled:k,tooltip:f})}),shouldFocusWrap:y,...g,"aria-labelledby":a?_:g["aria-labelledby"]})]})});Yg.displayName="ColorSwatchPicker";var Zg=x({defaultClassName:"_1lrwegk0",variantClassNames:{isSeparator:{true:"_1yep5z610y"}},defaultVariants:{},compoundVariants:[]}),Fn="_1yep5z63o _1yep5z63p _1yep5z63q _1yep5z629 _1yep5z62a _1yep5z62b _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6kj _1yep5z6kk _1yep5z6kl";var Zl="\u2013";function jn({segment:r,state:e}){let t=wt.useRef(null),{segmentProps:o}=useDateSegment(r,e,t),{focusProps:a,isFocused:n}=useFocusRing(),i=useMemo(()=>{let{text:s,type:l}=r;switch(l){case "hour":return s.replaceAll(Zl,"H");case "minute":return s.replaceAll(Zl,"M");case "second":return s.replaceAll(Zl,"S");default:return s}},[r]);return jsx(D,{...mergeProps(o,a),typography:"label.md.medium",color:r.isPlaceholder?"text.placeholder":"text.primary",backgroundColor:n?"support.info.subtle":void 0,ref:t,marginLeft:r.type==="timeZoneName"?"xs":void 0,className:Zg({isSeparator:r.text===":"||r.text==="/"}),children:r.isPlaceholder?i:r.text})}var Jg=wt.forwardRef(({className:r,labelPosition:e,"data-block-id":t,"data-block-class":o,...a},n)=>{let{locale:i}=useLocale(),s={...a,validationState:void 0,isInvalid:a.validationState==="error"||void 0},l=useTimeFieldState({...s,locale:i}),p=wt.useRef(null),{labelProps:c,fieldProps:d,descriptionProps:m,errorMessageProps:u,validationErrors:b,isInvalid:y,inputProps:f}=useTimeField(s,l,p),g=a.errorMessage||b.join(" "),v=ge({...a,errorMessage:g,descriptionProps:m,errorMessageProps:u,labelPosition:e}),{focusProps:h,isFocused:_}=useFocusRing({within:true});return jsxs($t,{className:classNames("BaselineUI-TimeField",r),labelProps:c,fieldProps:d,ref:n,wrapperRef:p,wrapperClassName:Fn,labelPosition:e,message:v,isFocused:_,"data-block-id":t,"data-block-class":o,isInvalid:y,...a,children:[jsx(VisuallyHidden,{children:jsx("input",{...f})}),jsx(D,{display:"flex",flexDirection:"row",paddingRight:"md",...h,children:l.segments.map((z,P)=>jsx(jn,{segment:z,state:l},P))})]})});Jg.displayName="TimeField";var Qg="_10dw1p96",ev="_10dw1p95",tv=x({defaultClassName:"_10dw1p90 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69f _1yep5z69g _1yep5z69h _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lq _1yep5z6ld _1yep5z6la",variantClassNames:{isSelected:{true:"_1yep5z6126"},isHovered:{true:"_10dw1p92"},isRenaming:{true:"_10dw1p93"},isFocusVisible:{true:"_1yep5z6140 _1yep5z617w _1yep5z617u"}},defaultVariants:{},compoundVariants:[[{isHovered:true,isSelected:false,isRenaming:false},"_1yep5z61o8 _1yep5z61q9 _1yep5z61ty _1yep5z61tx"]]});function av(r,e){if(typeof r=="function"&&!r.prototype?.isReactComponent){let t=r(e);return isValidElement(t)?r:t}return r}var nv=({context:r,depth:e,children:t,item:o,onPrimaryAction:a,onSecondaryAction:n,actionsPosition:i,primaryActionIcon:s,secondaryActionIcon:l,primaryActionAriaLabel:p,secondaryActionAriaLabel:c,onRename:d,onAction:m,renderItemTitle:u=b=>b.data.label})=>{let{formatMessage:b}=A(),{hoverProps:y,isHovered:f}=useHover({}),g=useRef(null),{onKeyDown:v,...h}=r.interactiveElementProps;delete h.onFocus,delete h.onClick;let _=createFocusManager(g),z=useCallback(I=>{if(I.key==="ArrowRight"&&(r.isExpanded||!o.children?.length))g.current?.setAttribute("tabindex","-1"),I.preventDefault(),I.stopPropagation(),_.focusNext();else switch(I.key){case "ArrowLeft":{_.focusPrevious()?(I.preventDefault(),I.stopPropagation()):(v?.(I),r.focusItem(true));break}case "Enter":{r.toggleExpandedState();break}default:v?.(I);}},[r,_,v,o,g]),P=useMemo(()=>{let I=av(s,o.index),S=av(l,o.index),E=typeof p=="function"?p(o.index):p,N=typeof c=="function"?c(o.index):c;return I||S?jsxs(D,{display:"flex",flexDirection:"row",children:[I?jsx(ke,{icon:I,"aria-label":E,size:"sm",excludeFromTabOrder:true,variant:"secondary",onPress:()=>{a?.(o.index);},tooltip:true}):null,S?jsx(ke,{icon:S,"aria-label":N,size:"sm",excludeFromTabOrder:true,variant:"secondary",onPress:()=>{n?.(o.index);},tooltip:true}):null]}):null},[s,o.index,l,p,c,a,n]),w=useCallback(I=>{I.key==="Enter"?(d?.({key:o.index,value:I.target.value}),r.stopRenamingItem()):I.key==="Escape"?(r.stopRenamingItem(),g.current?.setAttribute("tabindex","0"),g.current?.focus()):I.key!=="ArrowRight"&&I.key!=="ArrowLeft"&&I.key!=="ArrowUp"&&I.key!=="ArrowDown"&&!I.metaKey&&I.continuePropagation();},[o.index,r,d,g]),C=o.data.icon,k=!!d,{pressProps:$}=usePress({onPress:()=>{m?.(o.index);}}),{isFocusVisible:R,focusProps:T}=useFocusRing$1();return jsxs(Fragment,{children:[jsx("div",{...mergeProps({onKeyDown:z,onFocus:()=>{r.focusItem(false);}},$,T,y,r.itemContainerWithoutChildrenProps,h),className:classNames(ev,tv({isHovered:f,isSelected:r.isSelected,isFocusVisible:R,isRenaming:r.isRenaming}),"BaselineUI-TreeView-Row"),role:"row","data-key":o.index,"data-expanded":o.isFolder?r.isExpanded:void 0,"aria-expanded":o.isFolder?r.isExpanded:void 0,"data-selected":r.isSelected,"aria-selected":r.isSelected,"data-depth":e,"aria-level":e+1,"aria-posinset":o.data.posInset,"aria-setsize":o.data.setSize,"aria-label":o.data.label,style:{justifyContent:i==="end"?"space-between":void 0},ref:g,children:jsxs(D,{role:"gridcell",style:{display:"contents"},"aria-colindex":1,children:[i==="start"?P:null,jsxs(D,{display:"flex",flexDirection:"row",alignItems:"center",children:[jsxs(D,{display:"flex",padding:"sm",flexDirection:"row",alignItems:"center",gap:"md",style:{marginInlineStart:`calc(${e*2} * ${themeVars.spacing.lg})`},children:[jsx(L,{icon:ChevronRightIcon,size:"xxs",variant:"secondary",onPress:()=>{r.toggleExpandedState();},"aria-label":b(r.isExpanded?Jl.collapse:Jl.expand),style:{visibility:o.children?.length?"visible":"hidden"},className:classNames(Qg,"BaselineUI-TreeView-ExpansionToggle"),UNSAFE_NON_INTERACTIVE:true}),C?jsx(C,{size:16,style:{color:themeVars.color.icon.interactive.disabled}}):null]}),jsxs(D,{paddingLeft:"sm",paddingY:r.isRenaming?"none":"md",display:"flex",flexDirection:"column",gap:"xs",onDoubleClick:I=>{k&&(I.stopPropagation(),I.preventDefault(),r.startRenamingItem());},children:[r.isRenaming?jsx("div",{onClick:I=>{I.stopPropagation();},children:jsx(pt,{defaultValue:o.data.label,autoFocus:true,onBlur:I=>{d?.({key:o.index,value:I.target.value}),r.stopRenamingItem();},"aria-label":b(Jl.rename),onKeyDown:w,className:"BaselineUI-TreeView-RenameInput"})}):jsx(Q,{type:"label",size:"sm",className:classNames(sprinkles.compoundVariants({color:"text.primary"}),"BaselineUI-TreeView-Title"),children:u(o)}),o.data.description?jsx(Q,{type:"helper",size:"sm",className:"BaselineUI-TreeView-Description",children:o.data.description}):null]})]}),i==="end"?P:null]})}),t]})},Jl=G({expand:{id:"expand",defaultMessage:"Expand"},collapse:{id:"collapse",defaultMessage:"Collapse"},rename:{id:"rename",defaultMessage:"Rename"}});function y9(r,{posInset:e,setSize:t}){return {index:r.id,children:r.children?r.children.map(o=>o.id):[],data:{label:r.label,description:r.description,icon:r.icon,...r.data,posInset:e,setSize:t},isFolder:!!r.children?.length}}function b9(r,e){let t={};function o(a,n,i){if(t[a.id]=e(a,{posInset:n,setSize:i}),a.children)for(let s=0;s<a.children.length;s++)o(a.children[s],s+1,a.children.length);}return o(r,0,0),t}var pv=wt.forwardRef(({className:r,style:e,"data-block-id":t,"data-block-class":o,items:a,rootId:n=a.id,onPrimaryAction:i,onSecondaryAction:s,primaryActionIcon:l,secondaryActionIcon:p,primaryActionAriaLabel:c,secondaryActionAriaLabel:d,actionsPosition:m="start",onRename:u,onAction:b,renderItemTitle:y,...f},g)=>{let v=pe(),h=useRef(null),_=useTreeState({...f,selectionMode:"multiple",items:a.children,children:v}),z=useMemo(()=>Object.fromEntries(Object.entries(b9(a,y9)).map(([R,T])=>[R,{...T,canRename:!!u}])),[a,u]),P=useId(),[w,C]=wt.useState(a.children?.[0]?.id??""),k=useRef(w),$=useMemo(()=>({[`tree-${P}`]:{focusedItem:w,expandedItems:[..._.expandedKeys],selectedItems:[..._.selectionManager.selectedKeys]}}),[w,_.expandedKeys,_.selectionManager.selectedKeys,P]);return useEffect(()=>{if(!h.current)return;let R=h.current.getRootNode(),T=R instanceof ShadowRoot,I=h.current?.contains(R?.activeElement??null);T&&I&&R?.querySelector(`[data-rct-item-id="${w}"]`)?.focus();},[w]),jsx(ControlledTreeEnvironment,{items:z,getItemTitle:R=>R.data?.label,viewState:$,onExpandItem:R=>{_.setExpandedKeys(new Set([..._.expandedKeys,R.index])),f.onExpand?.(R.index.toString());},onFocusItem:R=>{C(R.index),R.index&&(k.current=R.index);},onCollapseItem:R=>{_.setExpandedKeys(new Set([..._.expandedKeys].filter(T=>T!==R.index))),f.onCollapse?.(R.index.toString());},onSelectItems:R=>{_.selectionManager.setSelectedKeys(new Set(R));},renderItem:R=>jsx(nv,{...R,onPrimaryAction:i,onSecondaryAction:s,actionsPosition:m,primaryActionIcon:l,secondaryActionIcon:p,primaryActionAriaLabel:c,secondaryActionAriaLabel:d,onRename:u,onAction:b,renderItemTitle:y}),renderLiveDescriptorContainer:({children:R})=>jsx(he,{children:jsx(VisuallyHidden,{children:R})}),renderTreeContainer:({containerProps:R,children:T})=>jsx("div",{...et(R,{onBlur:I=>{I.currentTarget.contains(I.relatedTarget)||I.currentTarget.querySelector(`[data-key="${k.current}"]`)?.setAttribute("tabindex","0");}}),"data-block-id":t,"data-block-class":o,style:{...e,...R.style},className:classNames(r,"BaselineUI-TreeView"),ref:M(g,R.ref,h),role:"treegrid",children:T}),renderItemsContainer:({children:R})=>R,children:jsx(Tree,{treeId:`tree-${P}`,rootItem:n,treeLabel:f["aria-label"],treeLabelledBy:f["aria-labelledby"]})})});pv.displayName="TreeView";var C9=forwardRef(({className:r,isCollapsible:e=false,...t},o)=>{let a=useRef(null),n=useId();return useImperativeHandle(o,()=>({resize:a.current?.resize})),jsx(Panel,{className:classNames("BaselineUI-Panel",r),collapsible:e,ref:a,id:n,...t})});C9.displayName="Panel";var $9=forwardRef(({className:r,...e},t)=>{let o=useRef(null);return useImperativeHandle(t,()=>({setLayout:o.current?.setLayout})),jsx(PanelGroup,{className:classNames("BaselineUI-PanelGroup",r),ref:o,...e})});$9.displayName="PanelGroup";var cv="_6abhjk0";var E9=({className:r,isDisabled:e=false,...t})=>jsx(PanelResizeHandle,{disabled:e,className:classNames(cv,"BaselineUI-PanelResizeHandle",r),...t});E9.displayName="PanelResizeHandle";var dv=x({defaultClassName:"_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7 _1yep5z6lz _1yep5z6m1",variantClassNames:{variant:{info:"_1yep5z6131",warning:"_1yep5z612x",error:"_1yep5z612p",success:"_1yep5z612t"}},defaultVariants:{},compoundVariants:[]}),uv="_1udvgpn5 _1yep5z6ij _1yep5z6ik _1yep5z6il _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69l _1yep5z69m _1yep5z69n";var F9=()=>{};function j9({state:r,...e}){let t=wt.useRef(null),{toastProps:o,contentProps:a,titleProps:n,descriptionProps:i,closeButtonProps:s}=useToast(e,r,t),l=useMemo(()=>({root:o,title:n,content:a,description:i,close:s}),[o,n,a,i,s]),{canClose:p=true,...c}=e.toast.content;return jsx(rn,{elementProps:l,...c,className:classNames(dv({variant:c.variant||"info"}),c.className),onClose:p?F9:void 0})}var fv=wt.forwardRef(({state:r,style:e,className:t,...o},a)=>{let n=oe(a),{regionProps:i}=useToastRegion(o,r,n),s={zIndex:1,...e,...i.style};return jsx("div",{...i,ref:n,className:classNames(uv,t),style:s,children:r.visibleToasts.map(l=>jsx(j9,{toast:l,state:r},l.key))})});fv.displayName="ToastRegion";var yv=wt.forwardRef(({toastQueue:r,portalContainer:e,...t},o)=>{let a=useToastQueue(r),n=ve(e);return a.visibleToasts.length>0?jsx(he,{portalContainer:n,ref:o,children:jsx(fv,{state:a,...t})}):null});yv.displayName="GlobalToastRegion";function Ye(r,e){return r-e*Math.floor(r/e)}var bv=1721426;function ht(r,e,t,o){e=_t(r,e);let a=e-1,n=-2;return t<=2?n=0:Ze(e)&&(n=-1),bv-1+365*a+Math.floor(a/4)-Math.floor(a/100)+Math.floor(a/400)+Math.floor((367*t-362)/12+n+o)}function Ze(r){return r%4===0&&(r%100!==0||r%400===0)}function _t(r,e){return r==="BC"?1-e:e}function Vt(r){let e="AD";return r<=0&&(e="BC",r=1-r),[e,r]}var H9={standard:[31,28,31,30,31,30,31,31,30,31,30,31],leapyear:[31,29,31,30,31,30,31,31,30,31,30,31]},le=class{fromJulianDay(e){let t=e,o=t-bv,a=Math.floor(o/146097),n=Ye(o,146097),i=Math.floor(n/36524),s=Ye(n,36524),l=Math.floor(s/1461),p=Ye(s,1461),c=Math.floor(p/365),d=a*400+i*100+l*4+c+(i!==4&&c!==4?1:0),[m,u]=Vt(d),b=t-ht(m,u,1,1),y=2;t<ht(m,u,3,1)?y=0:Ze(u)&&(y=1);let f=Math.floor(((b+y)*12+373)/367),g=t-ht(m,u,f,1)+1;return new Z(m,u,f,g)}toJulianDay(e){return ht(e.era,e.year,e.month,e.day)}getDaysInMonth(e){return H9[Ze(e.year)?"leapyear":"standard"][e.month-1]}getMonthsInYear(e){return 12}getDaysInYear(e){return Ze(e.year)?366:365}getYearsInEra(e){return 9999}getEras(){return ["BC","AD"]}isInverseEra(e){return e.era==="BC"}balanceDate(e){e.year<=0&&(e.era=e.era==="BC"?"AD":"BC",e.year=1-e.year);}constructor(){this.identifier="gregory";}};function tp(r,e){return r.calendar.toJulianDay(r)-e.calendar.toJulianDay(e)}function vv(r,e){return gv(r)-gv(e)}function gv(r){return r.hour*36e5+r.minute*6e4+r.second*1e3+r.millisecond}var ep=null;function rp(){return ep==null&&(ep=new Intl.DateTimeFormat().resolvedOptions().timeZone),ep}function op(r){r=Un(r,new le);let e=_t(r.era,r.year);return xv(e,r.month,r.day,r.hour,r.minute,r.second,r.millisecond)}function xv(r,e,t,o,a,n,i){let s=new Date;return s.setUTCHours(o,a,n,i),s.setUTCFullYear(r,e-1,t),s.getTime()}function hv(r,e){if(e==="UTC")return 0;if(r>0&&e===rp())return new Date(r).getTimezoneOffset()*-6e4;let{year:t,month:o,day:a,hour:n,minute:i,second:s}=Cv(r,e);return xv(t,o,a,n,i,s,0)-Math.floor(r/1e3)*1e3}var _v=new Map;function Cv(r,e){let t=_v.get(e);t||(t=new Intl.DateTimeFormat("en-US",{timeZone:e,hour12:false,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),_v.set(e,t));let o=t.formatToParts(new Date(r)),a={};for(let n of o)n.type!=="literal"&&(a[n.type]=n.value);return {year:a.era==="BC"||a.era==="B"?-a.year+1:+a.year,month:+a.month,day:+a.day,hour:a.hour==="24"?0:+a.hour,minute:+a.minute,second:+a.second}}var zv=864e5;function V9(r,e,t,o){return (t===o?[t]:[t,o]).filter(n=>U9(r,e,n))}function U9(r,e,t){let o=Cv(t,e);return r.year===o.year&&r.month===o.month&&r.day===o.day&&r.hour===o.hour&&r.minute===o.minute&&r.second===o.second}function Pv(r,e,t="compatible"){let o=Vn(r);if(e==="UTC")return op(o);if(e===rp()&&t==="compatible"){o=Un(o,new le);let l=new Date,p=_t(o.era,o.year);return l.setFullYear(p,o.month-1,o.day),l.setHours(o.hour,o.minute,o.second,o.millisecond),l.getTime()}let a=op(o),n=hv(a-zv,e),i=hv(a+zv,e),s=V9(o,e,a-n,a-i);if(s.length===1)return s[0];if(s.length>1)switch(t){case "compatible":case "earlier":return s[0];case "later":return s[s.length-1];case "reject":throw new RangeError("Multiple possible absolute times found")}switch(t){case "earlier":return Math.min(a-n,a-i);case "compatible":case "later":return Math.max(a-n,a-i);case "reject":throw new RangeError("No such absolute time found")}}function ap(r,e,t="compatible"){return new Date(Pv(r,e,t))}function Vn(r,e){let t=0,o=0,a=0,n=0;if("timeZone"in r)({hour:t,minute:o,second:a,millisecond:n}=r);else if("hour"in r&&true)return r;return new qn(r.calendar,r.era,r.year,r.month,r.day,t,o,a,n)}function Un(r,e){if(r.calendar.identifier===e.identifier)return r;let t=e.fromJulianDay(r.calendar.toJulianDay(r)),o=r.copy();return o.calendar=e,o.era=t.era,o.year=t.year,o.month=t.month,o.day=t.day,zt(o),o}function Kn(r,e){let t=r.copy(),o="hour"in t?W9(t,e):0;np(t,e.years||0),t.calendar.balanceYearMonth&&t.calendar.balanceYearMonth(t,r),t.month+=e.months||0,ip(t),wv(t),t.day+=(e.weeks||0)*7,t.day+=e.days||0,t.day+=o,q9(t),t.calendar.balanceDate&&t.calendar.balanceDate(t),t.year<1&&(t.year=1,t.month=1,t.day=1);let a=t.calendar.getYearsInEra(t);if(t.year>a){var n,i;let l=(n=(i=t.calendar).isInverseEra)===null||n===void 0?void 0:n.call(i,t);t.year=a,t.month=l?1:t.calendar.getMonthsInYear(t),t.day=l?1:t.calendar.getDaysInMonth(t);}t.month<1&&(t.month=1,t.day=1);let s=t.calendar.getMonthsInYear(t);return t.month>s&&(t.month=s,t.day=t.calendar.getDaysInMonth(t)),t.day=Math.max(1,Math.min(t.calendar.getDaysInMonth(t),t.day)),t}function np(r,e){var t,o;!((t=(o=r.calendar).isInverseEra)===null||t===void 0)&&t.call(o,r)&&(e=-e),r.year+=e;}function ip(r){for(;r.month<1;)np(r,-1),r.month+=r.calendar.getMonthsInYear(r);let e=0;for(;r.month>(e=r.calendar.getMonthsInYear(r));)r.month-=e,np(r,1);}function q9(r){for(;r.day<1;)r.month--,ip(r),r.day+=r.calendar.getDaysInMonth(r);for(;r.day>r.calendar.getDaysInMonth(r);)r.day-=r.calendar.getDaysInMonth(r),r.month++,ip(r);}function wv(r){r.month=Math.max(1,Math.min(r.calendar.getMonthsInYear(r),r.month)),r.day=Math.max(1,Math.min(r.calendar.getDaysInMonth(r),r.day));}function zt(r){r.calendar.constrainDate&&r.calendar.constrainDate(r),r.year=Math.max(1,Math.min(r.calendar.getYearsInEra(r),r.year)),wv(r);}function G9(r){let e={};for(let t in r)typeof r[t]=="number"&&(e[t]=-r[t]);return e}function sp(r,e){return Kn(r,G9(e))}function lp(r,e){let t=r.copy();return e.era!=null&&(t.era=e.era),e.year!=null&&(t.year=e.year),e.month!=null&&(t.month=e.month),e.day!=null&&(t.day=e.day),zt(t),t}function kv(r,e){let t=r.copy();return e.hour!=null&&(t.hour=e.hour),e.minute!=null&&(t.minute=e.minute),e.second!=null&&(t.second=e.second),e.millisecond!=null&&(t.millisecond=e.millisecond),Iv(t),t}function K9(r){r.second+=Math.floor(r.millisecond/1e3),r.millisecond=Gn(r.millisecond,1e3),r.minute+=Math.floor(r.second/60),r.second=Gn(r.second,60),r.hour+=Math.floor(r.minute/60),r.minute=Gn(r.minute,60);let e=Math.floor(r.hour/24);return r.hour=Gn(r.hour,24),e}function Iv(r){r.millisecond=Math.max(0,Math.min(r.millisecond,1e3)),r.second=Math.max(0,Math.min(r.second,59)),r.minute=Math.max(0,Math.min(r.minute,59)),r.hour=Math.max(0,Math.min(r.hour,23));}function Gn(r,e){let t=r%e;return t<0&&(t+=e),t}function W9(r,e){return r.hour+=e.hours||0,r.minute+=e.minutes||0,r.second+=e.seconds||0,r.millisecond+=e.milliseconds||0,K9(r)}function pp(r,e,t,o){let a=r.copy();switch(e){case "era":{let s=r.calendar.getEras(),l=s.indexOf(r.era);if(l<0)throw new Error("Invalid era: "+r.era);l=xt(l,t,0,s.length-1,o?.round),a.era=s[l],zt(a);break}case "year":var n,i;!((n=(i=a.calendar).isInverseEra)===null||n===void 0)&&n.call(i,a)&&(t=-t),a.year=xt(r.year,t,-1/0,9999,o?.round),a.year===-1/0&&(a.year=1),a.calendar.balanceYearMonth&&a.calendar.balanceYearMonth(a,r);break;case "month":a.month=xt(r.month,t,1,r.calendar.getMonthsInYear(r),o?.round);break;case "day":a.day=xt(r.day,t,1,r.calendar.getDaysInMonth(r),o?.round);break;default:throw new Error("Unsupported field "+e)}return r.calendar.balanceDate&&r.calendar.balanceDate(a),zt(a),a}function Sv(r,e,t,o){let a=r.copy();switch(e){case "hour":{let n=r.hour,i=0,s=23;if(o?.hourCycle===12){let l=n>=12;i=l?12:0,s=l?23:11;}a.hour=xt(n,t,i,s,o?.round);break}case "minute":a.minute=xt(r.minute,t,0,59,o?.round);break;case "second":a.second=xt(r.second,t,0,59,o?.round);break;case "millisecond":a.millisecond=xt(r.millisecond,t,0,999,o?.round);break;default:throw new Error("Unsupported field "+e)}return a}function xt(r,e,t,o,a=false){if(a){r+=Math.sign(e),r<t&&(r=o);let n=Math.abs(e);e>0?r=Math.ceil(r/n)*n:r=Math.floor(r/n)*n,r>o&&(r=t);}else r+=e,r<t?r=o-(t-r-1):r>o&&(r=t+(r-o-1));return r}function Rv(r){return `${String(r.hour).padStart(2,"0")}:${String(r.minute).padStart(2,"0")}:${String(r.second).padStart(2,"0")}${r.millisecond?String(r.millisecond/1e3).slice(1):""}`}function cp(r){let e=Un(r,new le),t;return e.era==="BC"?t=e.year===1?"0000":"-"+String(Math.abs(1-e.year)).padStart(6,"00"):t=String(e.year).padStart(4,"0"),`${t}-${String(e.month).padStart(2,"0")}-${String(e.day).padStart(2,"0")}`}function $v(r){return `${cp(r)}T${Rv(r)}`}function Tv(r,e){if(e.has(r))throw new TypeError("Cannot initialize the same private elements twice on an object")}function dp(r,e,t){Tv(r,e),e.set(r,t);}function Dv(r){let e=typeof r[0]=="object"?r.shift():new le,t;if(typeof r[0]=="string")t=r.shift();else {let i=e.getEras();t=i[i.length-1];}let o=r.shift(),a=r.shift(),n=r.shift();return [e,t,o,a,n]}var Z9=new WeakMap,Z=class r{copy(){return this.era?new r(this.calendar,this.era,this.year,this.month,this.day):new r(this.calendar,this.year,this.month,this.day)}add(e){return Kn(this,e)}subtract(e){return sp(this,e)}set(e){return lp(this,e)}cycle(e,t,o){return pp(this,e,t,o)}toDate(e){return ap(this,e)}toString(){return cp(this)}compare(e){return tp(this,e)}constructor(...e){dp(this,Z9,{writable:true,value:void 0});let[t,o,a,n,i]=Dv(e);this.calendar=t,this.era=o,this.year=a,this.month=n,this.day=i,zt(this);}};var X9=new WeakMap,qn=class r{copy(){return this.era?new r(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new r(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(e){return Kn(this,e)}subtract(e){return sp(this,e)}set(e){return lp(kv(this,e),e)}cycle(e,t,o){switch(e){case "era":case "year":case "month":case "day":return pp(this,e,t,o);default:return Sv(this,e,t,o)}}toDate(e,t){return ap(this,e,t)}toString(){return $v(this)}compare(e){let t=tp(this,e);return t===0?vv(this,Vn(e)):t}constructor(...e){dp(this,X9,{writable:true,value:void 0});let[t,o,a,n,i]=Dv(e);this.calendar=t,this.era=o,this.year=a,this.month=n,this.day=i,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,zt(this);}};var Or=[[1868,9,8],[1912,7,30],[1926,12,25],[1989,1,8],[2019,5,1]],J9=[[1912,7,29],[1926,12,24],[1989,1,7],[2019,4,30]],Wn=[1867,1911,1925,1988,2018],Ct=["meiji","taisho","showa","heisei","reiwa"];function Mv(r){let e=Or.findIndex(([t,o,a])=>r.year<t||r.year===t&&r.month<o||r.year===t&&r.month===o&&r.day<a);return e===-1?Or.length-1:e===0?0:e-1}function up(r){let e=Wn[Ct.indexOf(r.era)];if(!e)throw new Error("Unknown era: "+r.era);return new Z(r.year+e,r.month,r.day)}var Yn=class extends le{fromJulianDay(e){let t=super.fromJulianDay(e),o=Mv(t);return new Z(this,Ct[o],t.year-Wn[o],t.month,t.day)}toJulianDay(e){return super.toJulianDay(up(e))}balanceDate(e){let t=up(e),o=Mv(t);Ct[o]!==e.era&&(e.era=Ct[o],e.year=t.year-Wn[o]),this.constrainDate(e);}constrainDate(e){let t=Ct.indexOf(e.era),o=J9[t];if(o!=null){let[a,n,i]=o,s=a-Wn[t];e.year=Math.max(1,Math.min(s,e.year)),e.year===s&&(e.month=Math.min(n,e.month),e.month===n&&(e.day=Math.min(i,e.day)));}if(e.year===1&&t>=0){let[,a,n]=Or[t];e.month=Math.max(a,e.month),e.month===a&&(e.day=Math.max(n,e.day));}}getEras(){return Ct}getYearsInEra(e){let t=Ct.indexOf(e.era),o=Or[t],a=Or[t+1];if(a==null)return 9999-o[0]+1;let n=a[0]-o[0];return (e.month<a[1]||e.month===a[1]&&e.day<a[2])&&n++,n}getDaysInMonth(e){return super.getDaysInMonth(up(e))}getMinimumMonthInYear(e){let t=Ev(e);return t?t[1]:1}getMinimumDayInMonth(e){let t=Ev(e);return t&&e.month===t[1]?t[2]:1}constructor(...e){super(...e),this.identifier="japanese";}};function Ev(r){if(r.year===1){let e=Ct.indexOf(r.era);return Or[e]}}var Lv=-543,Zn=class extends le{fromJulianDay(e){let t=super.fromJulianDay(e),o=_t(t.era,t.year);return new Z(this,o-Lv,t.month,t.day)}toJulianDay(e){return super.toJulianDay(Nv(e))}getEras(){return ["BE"]}getDaysInMonth(e){return super.getDaysInMonth(Nv(e))}balanceDate(){}constructor(...e){super(...e),this.identifier="buddhist";}};function Nv(r){let[e,t]=Vt(r.year+Lv);return new Z(e,t,r.month,r.day)}var Xn=1911;function Ov(r){return r.era==="minguo"?r.year+Xn:1-r.year+Xn}function Av(r){let e=r-Xn;return e>0?["minguo",e]:["before_minguo",1-e]}var Jn=class extends le{fromJulianDay(e){let t=super.fromJulianDay(e),o=_t(t.era,t.year),[a,n]=Av(o);return new Z(this,a,n,t.month,t.day)}toJulianDay(e){return super.toJulianDay(Bv(e))}getEras(){return ["before_minguo","minguo"]}balanceDate(e){let[t,o]=Av(Ov(e));e.era=t,e.year=o;}isInverseEra(e){return e.era==="before_minguo"}getDaysInMonth(e){return super.getDaysInMonth(Bv(e))}getYearsInEra(e){return e.era==="before_minguo"?9999:9999-Xn}constructor(...e){super(...e),this.identifier="roc";}};function Bv(r){let[e,t]=Vt(Ov(r));return new Z(e,t,r.month,r.day)}var Fv=1948320,jv=[0,31,62,93,124,155,186,216,246,276,306,336],Qn=class{fromJulianDay(e){let t=e-Fv,o=1+Math.floor((33*t+3)/12053),a=365*(o-1)+Math.floor((8*o+21)/33),n=t-a,i=n<216?Math.floor(n/31):Math.floor((n-6)/30),s=n-jv[i]+1;return new Z(this,o,i+1,s)}toJulianDay(e){let t=Fv-1+365*(e.year-1)+Math.floor((8*e.year+21)/33);return t+=jv[e.month-1],t+=e.day,t}getMonthsInYear(){return 12}getDaysInMonth(e){return e.month<=6?31:e.month<=11||Ye(25*e.year+11,33)<8?30:29}getEras(){return ["AP"]}getYearsInEra(){return 9377}constructor(){this.identifier="persian";}};var mp=78,Hv=80,ei=class extends le{fromJulianDay(e){let t=super.fromJulianDay(e),o=t.year-mp,a=e-ht(t.era,t.year,1,1),n;a<Hv?(o--,n=Ze(t.year-1)?31:30,a+=n+155+90+10):(n=Ze(t.year)?31:30,a-=Hv);let i,s;if(a<n)i=1,s=a+1;else {let l=a-n;l<155?(i=Math.floor(l/31)+2,s=l%31+1):(l-=155,i=Math.floor(l/30)+7,s=l%30+1);}return new Z(this,o,i,s)}toJulianDay(e){let t=e.year+mp,[o,a]=Vt(t),n,i;return Ze(a)?(n=31,i=ht(o,a,3,21)):(n=30,i=ht(o,a,3,22)),e.month===1?i+e.day-1:(i+=n+Math.min(e.month-2,5)*31,e.month>=8&&(i+=(e.month-7)*30),i+=e.day-1,i)}getDaysInMonth(e){return e.month===1&&Ze(e.year+mp)||e.month>=2&&e.month<=6?31:30}getYearsInEra(){return 9919}getEras(){return ["saka"]}balanceDate(){}constructor(...e){super(...e),this.identifier="indian";}};var ri=1948440,Vv=1948439,Re=1300,Fr=1600,Q9=460322;function oi(r,e,t,o){return o+Math.ceil(29.5*(t-1))+(e-1)*354+Math.floor((3+11*e)/30)+r-1}function Kv(r,e,t){let o=Math.floor((30*(t-e)+10646)/10631),a=Math.min(12,Math.ceil((t-(29+oi(e,o,1,1)))/29.5)+1),n=t-oi(e,o,a,1)+1;return new Z(r,o,a,n)}function Uv(r){return (14+11*r)%30<11}var Hr=class{fromJulianDay(e){return Kv(this,ri,e)}toJulianDay(e){return oi(ri,e.year,e.month,e.day)}getDaysInMonth(e){let t=29+e.month%2;return e.month===12&&Uv(e.year)&&t++,t}getMonthsInYear(){return 12}getDaysInYear(e){return Uv(e.year)?355:354}getYearsInEra(){return 9665}getEras(){return ["AH"]}constructor(){this.identifier="islamic-civil";}},ai=class extends Hr{fromJulianDay(e){return Kv(this,Vv,e)}toJulianDay(e){return oi(Vv,e.year,e.month,e.day)}constructor(...e){super(...e),this.identifier="islamic-tbla";}},e3="qgpUDckO1AbqBmwDrQpVBakGkgepC9QF2gpcBS0NlQZKB1QLagutBa4ETwoXBYsGpQbVCtYCWwmdBE0KJg2VDawFtgm6AlsKKwWVCsoG6Qr0AnYJtgJWCcoKpAvSC9kF3AJtCU0FpQpSC6ULtAW2CVcFlwJLBaMGUgdlC2oFqworBZUMSg2lDcoF1gpXCasESwmlClILagt1BXYCtwhbBFUFqQW0BdoJ3QRuAjYJqgpUDbIN1QXaAlsJqwRVCkkLZAtxC7QFtQpVCiUNkg7JDtQG6QprCasEkwpJDaQNsg25CroEWworBZUKKgtVC1wFvQQ9Ah0JlQpKC1oLbQW2AjsJmwRVBqkGVAdqC2wFrQpVBSkLkgupC9QF2gpaBasKlQVJB2QHqgu1BbYCVgpNDiULUgtqC60FrgIvCZcESwalBqwG1gpdBZ0ETQoWDZUNqgW1BdoCWwmtBJUFygbkBuoK9QS2AlYJqgpUC9IL2QXqAm0JrQSVCkoLpQuyBbUJ1gSXCkcFkwZJB1ULagVrCisFiwpGDaMNygXWCtsEawJLCaUKUgtpC3UFdgG3CFsCKwVlBbQF2gntBG0BtgimClINqQ3UBdoKWwmrBFMGKQdiB6kLsgW1ClUFJQuSDckO0gbpCmsFqwRVCikNVA2qDbUJugQ7CpsETQqqCtUK2gJdCV4ELgqaDFUNsga5BroEXQotBZUKUguoC7QLuQXaAloJSgukDdEO6AZqC20FNQWVBkoNqA3UDdoGWwWdAisGFQtKC5ULqgWuCi4JjwwnBZUGqgbWCl0FnQI=",fp,jr;function ti(r){return Q9+jr[r-Re]}function Yo(r,e){let t=r-Re,o=1<<11-(e-1);return (fp[t]&o)===0?29:30}function qv(r,e){let t=ti(r);for(let o=1;o<e;o++)t+=Yo(r,o);return t}function Gv(r){return jr[r+1-Re]-jr[r-Re]}var ni=class extends Hr{fromJulianDay(e){let t=e-ri,o=ti(Re),a=ti(Fr);if(t<o||t>a)return super.fromJulianDay(e);{let n=Re-1,i=1,s=1;for(;s>0;){n++,s=t-ti(n)+1;let l=Gv(n);if(s===l){i=12;break}else if(s<l){let p=Yo(n,i);for(i=1;s>p;)s-=p,i++,p=Yo(n,i);break}}return new Z(this,n,i,t-qv(n,i)+1)}}toJulianDay(e){return e.year<Re||e.year>Fr?super.toJulianDay(e):ri+qv(e.year,e.month)+(e.day-1)}getDaysInMonth(e){return e.year<Re||e.year>Fr?super.getDaysInMonth(e):Yo(e.year,e.month)}getDaysInYear(e){return e.year<Re||e.year>Fr?super.getDaysInYear(e):Gv(e.year)}constructor(){if(super(),this.identifier="islamic-umalqura",fp||(fp=new Uint16Array(Uint8Array.from(atob(e3),e=>e.charCodeAt(0)).buffer)),!jr){jr=new Uint32Array(Fr-Re+1);let e=0;for(let t=Re;t<=Fr;t++){jr[t-Re]=e;for(let o=1;o<=12;o++)e+=Yo(t,o);}}}};var Wv=347997,Yv=1080,Zv=24*Yv,t3=29,r3=12*Yv+793,o3=t3*Zv+r3;function Ut(r){return Ye(r*7+1,19)<7}function si(r){let e=Math.floor((235*r-234)/19),t=12084+13753*e,o=e*29+Math.floor(t/25920);return Ye(3*(o+1),7)<3&&(o+=1),o}function a3(r){let e=si(r-1),t=si(r);return si(r+1)-t===356?2:t-e===382?1:0}function Zo(r){return si(r)+a3(r)}function Xv(r){return Zo(r+1)-Zo(r)}function n3(r){let e=Xv(r);switch(e>380&&(e-=30),e){case 353:return 0;case 354:return 1;case 355:return 2}}function ii(r,e){if(e>=6&&!Ut(r)&&e++,e===4||e===7||e===9||e===11||e===13)return 29;let t=n3(r);return e===2?t===2?30:29:e===3?t===0?29:30:e===6?Ut(r)?30:0:30}var li=class{fromJulianDay(e){let t=e-Wv,o=t*Zv/o3,a=Math.floor((19*o+234)/235)+1,n=Zo(a),i=Math.floor(t-n);for(;i<1;)a--,n=Zo(a),i=Math.floor(t-n);let s=1,l=0;for(;l<i;)l+=ii(a,s),s++;s--,l-=ii(a,s);let p=i-l;return new Z(this,a,s,p)}toJulianDay(e){let t=Zo(e.year);for(let o=1;o<e.month;o++)t+=ii(e.year,o);return t+e.day+Wv}getDaysInMonth(e){return ii(e.year,e.month)}getMonthsInYear(e){return Ut(e.year)?13:12}getDaysInYear(e){return Xv(e.year)}getYearsInEra(){return 9999}getEras(){return ["AM"]}balanceYearMonth(e,t){t.year!==e.year&&(Ut(t.year)&&!Ut(e.year)&&t.month>6?e.month--:!Ut(t.year)&&Ut(e.year)&&t.month>6&&e.month++);}constructor(){this.identifier="hebrew";}};var yp=1723856,Jv=1824665,bp=5500;function pi(r,e,t,o){return r+365*e+Math.floor(e/4)+30*(t-1)+o-1}function gp(r,e){let t=Math.floor(4*(e-r)/1461),o=1+Math.floor((e-pi(r,t,1,1))/30),a=e+1-pi(r,t,o,1);return [t,o,a]}function Qv(r){return Math.floor(r%4/3)}function eh(r,e){return e%13!==0?30:Qv(r)+5}var Vr=class{fromJulianDay(e){let[t,o,a]=gp(yp,e),n="AM";return t<=0&&(n="AA",t+=bp),new Z(this,n,t,o,a)}toJulianDay(e){let t=e.year;return e.era==="AA"&&(t-=bp),pi(yp,t,e.month,e.day)}getDaysInMonth(e){return eh(e.year,e.month)}getMonthsInYear(){return 13}getDaysInYear(e){return 365+Qv(e.year)}getYearsInEra(e){return e.era==="AA"?9999:9991}getEras(){return ["AA","AM"]}constructor(){this.identifier="ethiopic";}},ci=class extends Vr{fromJulianDay(e){let[t,o,a]=gp(yp,e);return t+=bp,new Z(this,"AA",t,o,a)}getEras(){return ["AA"]}getYearsInEra(){return 9999}constructor(...e){super(...e),this.identifier="ethioaa";}},di=class extends Vr{fromJulianDay(e){let[t,o,a]=gp(Jv,e),n="CE";return t<=0&&(n="BCE",t=1-t),new Z(this,n,t,o,a)}toJulianDay(e){let t=e.year;return e.era==="BCE"&&(t=1-t),pi(Jv,t,e.month,e.day)}getDaysInMonth(e){let t=e.year;return e.era==="BCE"&&(t=1-t),eh(t,e.month)}isInverseEra(e){return e.era==="BCE"}balanceDate(e){e.year<=0&&(e.era=e.era==="BCE"?"CE":"BCE",e.year=1-e.year);}getEras(){return ["BCE","CE"]}getYearsInEra(e){return e.era==="BCE"?9999:9715}constructor(...e){super(...e),this.identifier="coptic";}};function vp(r){switch(r){case "buddhist":return new Zn;case "ethiopic":return new Vr;case "ethioaa":return new ci;case "coptic":return new di;case "hebrew":return new li;case "indian":return new ei;case "islamic-civil":return new Hr;case "islamic-tbla":return new ai;case "islamic-umalqura":return new ni;case "japanese":return new Yn;case "persian":return new Qn;case "roc":return new Jn;case "gregory":default:return new le}}var rh=wt.forwardRef(({className:r,labelPosition:e,"data-block-id":t,"data-block-class":o,...a},n)=>{let{locale:i}=useLocale(),s={...a,validationState:void 0,isInvalid:a.validationState==="error"||void 0},l=useDateFieldState({...s,locale:i,createCalendar:vp}),p=wt.useRef(null),{labelProps:c,fieldProps:d,validationErrors:m,descriptionProps:u,inputProps:b,errorMessageProps:y,isInvalid:f}=useDateField(s,l,p),g=a.errorMessage||m.join(" "),v=ge({...a,errorMessage:g,descriptionProps:u,errorMessageProps:y,labelPosition:e}),{focusProps:h,isFocused:_}=useFocusRing({within:true});return jsxs($t,{className:classNames("BaselineUI-DateField",r),labelProps:c,fieldProps:d,ref:n,wrapperRef:p,wrapperClassName:Fn,labelPosition:e,message:v,isFocused:_,"data-block-id":t,"data-block-class":o,isInvalid:f,...a,children:[jsx(VisuallyHidden,{children:jsx("input",{...b})}),jsx(D,{display:"flex",flexDirection:"row",paddingRight:"md",...h,children:l.segments.map((z,P)=>jsx(jn,{segment:z,state:l},P))})]})});rh.displayName="DateField";var oh={x:0,y:0},y3={node:null,setNode:()=>{},coordinates:oh,setCoordinates:()=>{},displayId:"",boundsRef:{current:null},isDisabled:false},Xe=wt.createContext(y3),ah=({children:r,isDisabled:e=false,coordinates:t,onMove:o})=>{let[a,n]=wt.useState(null),i=wt.useRef(null),[s,l]=useControlledState(t,oh,d=>{o?.({coordinates:d,boundingRect:i.current});}),p=useId(),c=wt.useMemo(()=>({node:a,setNode:n,coordinates:s,setCoordinates:l,displayId:p,boundsRef:i,isDisabled:e}),[a,s,p,l,n,i,e]);return jsx(Xe.Provider,{value:c,children:r})};ah.displayName="Magnifier";var nh="_1yep5z6f6",ih=x({defaultClassName:"_1aj2a4v6",variantClassNames:{isDisabled:{true:"_1aj2a4v7",false:"_1aj2a4v8"},isIndicatorVisible:{true:"_1aj2a4v9",false:"_1aj2a4va"}},defaultVariants:{},compoundVariants:[[{isDisabled:false,isIndicatorVisible:true},"_1aj2a4vb"],[{isDisabled:false,isIndicatorVisible:false},"_1aj2a4vc"]]}),sh="_1aj2a4vd",lh="_1aj2a4v1",ph="_1aj2a4v4",hp="_1aj2a4v3 _1yep5z6hd _1yep5z6lz",ch="_1aj2a4v2 _1yep5z6iy _1yep5z6iz _1yep5z6j0 _1yep5z6h4 _1yep5z6lz _1yep5z6id _1yep5z6ie _1yep5z6if",dh="_1aj2a4v0",uh="_1aj2a4v5";var fh=r=>jsxs("svg",{width:92,height:92,viewBox:"0 0 92 92",fill:"none",xmlns:"http://www.w3.org/2000/svg",...r,children:[jsxs("g",{filter:"url(#filter0_d_11407_457970)",children:[jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M49 43V4h-6v39H4v6h39v39h6V49h39v-6H49zm38 5H48v39h-4V48H5v-4h39V5h4v39h39v4zm-5 28v6h-6v6h12V76h-6zm5 11H77v-4h6v-6h4v10zm-77-5v-6H4v12h12v-6h-6zm5 5H5V77h4v6h6v4zM76 4v6h6v6h6V4H76zm11 11h-4V9h-6V5h10v10zM4 4v12h6v-6h6V4H4zm11 5H9v6H5V5h10v4z",fill:themeVars.color.background.positive.subtle}),jsx("path",{d:"M48 44v4h39v-4H48zm-4 4v39h4V48h-4zM5 44v4h39v-4H5zM44 5v39h4V5h-4zm39 72v6h-6v4h10V77h-4zM9 83v-6H5v10h10v-4H9zM77 5v4h6v6h4V5H77zM5 5v10h4V9h6V5H5z",fill:themeVars.color.background.positive.interactive.enabled})]}),jsx("defs",{children:jsxs("filter",{id:"filter0_d_11407_457970",x:0,y:0,width:92,height:92,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[jsx("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),jsx("feColorMatrix",{in:"SourceAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),jsx("feOffset",{}),jsx("feGaussianBlur",{stdDeviation:2}),jsx("feComposite",{in2:"hardAlpha",operator:"out"}),jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.4 0"}),jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_11407_457970"}),jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_11407_457970",result:"shape"})]})})]});function yh({coordinates:r,setCoordinates:e,boundsRef:t,onKeyDown:o,onKeyUp:a}){let{isDisabled:n}=useContext(Xe);return useKeyboard({isDisabled:n,onKeyDown:i=>{o?.(i);let s=i.shiftKey?10:1,l=t.current;if(!l)return;let p;switch(i.key){case "ArrowRight":{i.preventDefault(),p={x:clamp$1(r.x+s,0,l.width),y:clamp$1(r.y,0,l.height)};break}case "ArrowLeft":{i.preventDefault(),p={x:clamp$1(r.x-s,0,l.width),y:clamp$1(r.y,0,l.height)};break}case "ArrowDown":{i.preventDefault(),p={x:clamp$1(r.x,0,l.width),y:clamp$1(r.y+s,0,l.height)};break}case "ArrowUp":{i.preventDefault(),p={x:clamp$1(r.x,0,l.width),y:clamp$1(r.y-s,0,l.height)};break}}p&&e(p);},onKeyUp:a})}var gh=wt.forwardRef(({children:r,onPress:e,className:t,style:o,"data-block-id":a,"data-block-class":n,onFocusChange:i,onBlur:s,onFocus:l,onKeyDown:p,onKeyUp:c,...d},m)=>{let{setNode:u,setCoordinates:b,coordinates:y,displayId:f,boundsRef:g,isDisabled:v}=useContext(Xe),h=useRef(null),[_,z]=useState(false),P=useInteractionModality(),w=Ne();useEffect(()=>{let N=h.current;if(!N||v)return;let O=H=>{let V=N.getBoundingClientRect();g.current=V;let F="clientX"in H?H.clientX:H.touches[0].clientX,te="clientY"in H?H.clientY:H.touches[0].clientY,j={x:clamp$1(F-V.left,0,V.width),y:clamp$1(te-V.top,0,V.height)};b(j),z(true);},B=()=>{z(false);};return N.addEventListener("mousemove",O),N.addEventListener("touchmove",O),N.addEventListener("mouseleave",B),()=>{N.removeEventListener("mousemove",O),N.removeEventListener("touchmove",O),N.removeEventListener("mouseleave",B);}},[b,g,v]);let{pressProps:C}=usePress({isDisabled:v,onPress:N=>{N.pointerType==="keyboard"?e?.({...N,x:y.x,y:y.y}):e?.(N);}}),{focusProps:k,isFocusVisible:$,isFocused:R}=useFocusRing(),{focusProps:T}=useFocus$1({isDisabled:v,onFocusChange:N=>{if(P==="keyboard")if(N){z(true);let O=h.current?.getBoundingClientRect();if(!O)return;g.current=O,b({x:clamp$1(O.width/2,0,O.width),y:clamp$1(O.height/2,0,O.height)});}else z(false);i?.(N);},onFocus:l,onBlur:s}),{keyboardProps:I}=yh({coordinates:y,setCoordinates:b,boundsRef:g,onKeyDown:p,onKeyUp:c}),S=useMemo(()=>h.current?getAbsolutePosition(h.current,y):{x:0,y:0},[y]);useInteractOutside$1({isDisabled:v,ref:h,onInteractOutside:()=>{z(false);}});let E=useMemo(()=>_&&!v&&(w==="mobile"||P==="keyboard"),[_,v,w,P]);return jsxs("div",{ref:M(m,h),className:classNames(sh,"BaselineUI-Magnifier-Content",t),style:o,"data-block-id":a,"data-block-class":n,"aria-controls":f,role:"application",...d,children:[E?jsx(he,{children:jsx(fh,{style:{left:S.x,top:S.y},className:classNames(dh,"BaselineUI-Magnifier-Cursor")})}):null,jsx("div",{...et(C,k,I,T),ref:u,className:classNames(ih({isDisabled:v,isIndicatorVisible:E}),"BaselineUI-Magnifier-ContentInner"),"data-focus-visible":$,"data-focused":R,tabIndex:v?void 0:0,children:r})]})});gh.displayName="MagnifierContent";function N3(r){let e=[];for(let t=0;t<r.length;t++){let o=r[t],a=r.getPropertyValue(o);a&&e.push(`${o}: ${a}`);}for(let t of r)if(t.startsWith("--")){let o=r.getPropertyValue(t);o&&e.push(`${t}: ${o}`);}return e.join("; ")}function vh(r){let[e,t]=useState(null),{isDisabled:o}=useContext(Xe);return useEffect(()=>{if(!r||o)return;let a=r,n=re(a);function i(){let p=n.getComputedStyle(a),c=a.cloneNode(true);c.style.cssText=N3(p);let d=a.getBoundingClientRect();c.style.setProperty("width",`${d.width}px`),c.style.setProperty("height",`${d.height}px`),c.style.setProperty("position","static"),c.style.setProperty("margin","0"),c.style.setProperty("left","0"),c.style.setProperty("top","0"),c.style.setProperty("transform","none"),c.style.removeProperty("-webkit-text-fill-color"),c.style.removeProperty("-webkit-text-stroke-color"),c.removeAttribute("aria-controls"),c.setAttribute("tabindex","-1"),c.setAttribute("aria-hidden","true");let m=findFocusableElements(c);if(m)for(let u of m)u.setAttribute("tabindex","-1");"scrollTop"in a&&(c.scrollTop=a.scrollTop),"scrollLeft"in a&&(c.scrollLeft=a.scrollLeft),t(c);}i();let s=new ResizeObserver(i),l=new MutationObserver(i);return s.observe(a),l.observe(a,{attributes:true,childList:true,subtree:true,characterData:true}),()=>{s.disconnect(),l.disconnect();}},[r,o]),e}var _h=8,zh=7,xh=7,Ch=wt.forwardRef(({className:r,style:e,description:t,scale:o=2,"data-block-id":a,"data-block-class":n},i)=>{let{coordinates:s,node:l,boundsRef:p,displayId:c,isDisabled:d}=useContext(Xe),m=vh(l),u=useMemo(()=>typeof t=="function"?t({coordinates:{x:s.x,y:s.y},boundingRect:p.current}):t,[t,s,p]),b=useMemo(()=>p.current?{x:s.x/p.current.width,y:s.y/p.current.height}:{x:0,y:0},[p,s]);return jsxs(D,{ref:i,className:classNames(lh,"BaselineUI-Magnifier-Display",r),backgroundColor:"background.primary.subtle",boxShadow:"medium",borderRadius:"sm",outlineWidth:1,outlineColor:"border.medium",outlineOffset:-1,outlineStyle:"solid",paddingY:"md",paddingLeft:"md",paddingRight:u?.length?"xl":"md",display:"flex",flexDirection:"row",gap:"lg",alignItems:"center",style:e,id:c,"data-block-id":a,"data-block-class":n,role:"complementary",children:[jsxs("div",{className:ch,children:[m&&!d?jsx(ba,{node:m,style:{transform:`scale(${o}) translate(calc(-${b.x*100}% + ${_h*zh/(2*o)}px), calc(-${b.y*100}% + ${_h*xh/(2*o)}px))`},className:classNames(uh,"BaselineUI-Magnifier-DisplayNode")}):null,Array.from({length:zh*xh}).map((y,f)=>f===24?jsx("div",{className:classNames(hp,ph)},f):jsx("div",{className:hp},f))]}),u?.length?jsx(D,{display:"flex",gap:"lg",flexDirection:"column",children:u?.map(({label:y,icon:f},g)=>jsxs(D,{display:"flex",gap:"md",flexDirection:"row",color:"text.secondary",alignItems:"center",children:[jsx(f,{size:12,className:nh}),jsx(Q,{type:"label",size:"sm",children:y})]},y+g))}):null]})});Ch.displayName="MagnifierDisplay";
16
- export{ff as Accordion,zf as AccordionItem,K as ActionButton,qg as ActionGroup,TT as ActionGroupItem,L as ActionIconButton,En as AlertDialog,ig as AudioPlayer,xr as Avatar,D as Box,Sg as ButtonSelect,Nm as Checkbox,wr as ColorInput,ft as ColorSwatch,Yg as ColorSwatchPicker,Bg as ComboBox,rh as DateField,Gm as DateFormat,u0 as DeviceProvider,wa as DeviceProviderContext,ze as Dialog,uu as DialogTitle,ba as DomNodeRenderer,Da as Drawer,Ob as Editor,tm as FileUpload,$a as Focusable,P0 as FrameProvider,Qy as FreehandCanvas,yv as GlobalToastRegion,Hg as GridList,R1 as Group,jc as I18nProvider,qy as IconColorInput,yn as IconColorInputButton,Rf as IconSelect,_u as IconSlider,m1 as ImageDropZone,Cg as ImageGallery,rn as InlineAlert,Gu as Link,me as ListBox,ah as Magnifier,gh as MagnifierContent,Ch as MagnifierDisplay,Zb as Markdown,Va as Menu,S1 as MessageFormat,Le as Modal,U2 as ModalClose,Ue as ModalContent,on as ModalTrigger,br as NumberFormat,Ve as NumberInput,qm as Pagination,C9 as Panel,$9 as PanelGroup,E9 as PanelResizeHandle,je as Popover,Ae as PopoverContent,He as PopoverTrigger,he as Portal,ha as PortalContainerProvider,v1 as Preview,cm as ProgressBar,vr as ProgressSpinner,I1 as RadioGroup,zm as Reaction,Ub as ScrollControlButton,Nu as SearchInput,ut as Select,U as Separator,nr as Slider,$u as Switch,Uf as TabItem,Vf as Tabs,rf as TagGroup,Q as Text,pt as TextInput,Ra as ThemeProvider,Jg as TimeField,Wa as ToggleButton,ke as ToggleIconButton,xn as Toolbar,ie as Tooltip,p1 as Transform,pv as TreeView,G as defineMessages,iL as disableAnimations,sL as enableAnimations,GD as isInsideOverlayContent,mc as isRect,Ne as useDevice,A as useI18n,er as useImage,Nc as useIntersectionObserver,xa as useIsFirstRender,Gc as useLocalStorage,YE as useMutationObserver,ve as usePortalContainer,Lc as useResizeObserver,rN as useTextSelection,Bc as useUndoRedo,ji as useUserPreferences};
10
+ var Se=typeof document<"u"?ht.useLayoutEffect:()=>{};function Qn(e){let t=useRef(null);return Se(()=>{t.current=e;},[e]),useCallback((...o)=>{let r=t.current;return r?.(...o)},[])}function ei(e){let[t,o]=useState(e),r=useRef(null),a=Qn(()=>{if(!r.current)return;let i=r.current.next();if(i.done){r.current=null;return}t===i.value?a():o(i.value);});Se(()=>{r.current&&a();});let n=Qn(i=>{r.current=i(t),a();});return [t,n]}var Ar={prefix:String(Math.round(Math.random()*1e10)),current:0},Zl=ht.createContext(Ar),hg=ht.createContext(false);var xg=!!(typeof window<"u"&&window.document&&window.document.createElement),ti=new WeakMap;function Cg(e=false){let t=useContext(Zl),o=useRef(null);if(o.current===null&&!e){var r,a;let n=(a=ht.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)===null||a===void 0||(r=a.ReactCurrentOwner)===null||r===void 0?void 0:r.current;if(n){let i=ti.get(n);i==null?ti.set(n,{id:t.current,state:n.memoizedState}):n.memoizedState!==i.state&&(t.current=i.id,ti.delete(n));}o.current=++t.current;}return o.current}function Pg(e){let t=useContext(Zl);t===Ar&&!xg&&console.warn("When server rendering, you must wrap your application in an <SSRProvider> to ensure consistent ids are generated between the client and server.");let o=Cg(!!e),r=t===Ar&&process.env.NODE_ENV==="test"?"react-aria":`react-aria${t.prefix}`;return e||`${r}-${o}`}function kg(e){let t=ht.useId(),[o]=useState(Jl()),r=o||process.env.NODE_ENV==="test"?"react-aria":`react-aria${Ar.prefix}`;return e||`${r}-${t}`}var ri=typeof ht.useId=="function"?kg:Pg;function wg(){return false}function Ig(){return true}function Rg(e){return ()=>{}}function Jl(){return typeof ht.useSyncExternalStore=="function"?ht.useSyncExternalStore(Rg,wg,Ig):useContext(hg)}var Mg=!!(typeof window<"u"&&window.document&&window.document.createElement),Qe=new Map;function Fr(e){let[t,o]=useState(e),r=useRef(null),a=ri(t),n=useCallback(i=>{r.current=i;},[]);return Mg&&(Qe.has(a)&&!Qe.get(a).includes(n)?Qe.set(a,[...Qe.get(a),n]):Qe.set(a,[n])),Se(()=>{let i=a;return ()=>{Qe.delete(i);}},[a]),useEffect(()=>{let i=r.current;i&&(r.current=null,o(i));}),a}function ai(e,t){if(e===t)return e;let o=Qe.get(e);if(o)return o.forEach(a=>a(t)),t;let r=Qe.get(t);return r?(r.forEach(a=>a(e)),e):t}function Ql(...e){return (...t)=>{for(let o of e)typeof o=="function"&&o(...t);}}var ge=e=>{var t;return (t=e?.ownerDocument)!==null&&t!==void 0?t:document},re=e=>e&&"window"in e&&e.window===e?e:ge(e).defaultView||window;function Ng(e){return e!==null&&typeof e=="object"&&"nodeType"in e&&typeof e.nodeType=="number"}function ni(e){return Ng(e)&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&"host"in e}var jr=(e=document)=>{var t;let o=e.activeElement;for(;o&&"shadowRoot"in o&&(!((t=o.shadowRoot)===null||t===void 0)&&t.activeElement);)o=o.shadowRoot.activeElement;return o};function ep(e){var t,o,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(o=ep(e[t]))&&(r&&(r+=" "),r+=o);}else for(o in e)e[o]&&(r&&(r+=" "),r+=o);return r}function Eg(){for(var e,t,o=0,r="",a=arguments.length;o<a;o++)(e=arguments[o])&&(t=ep(e))&&(r&&(r+=" "),r+=t);return r}var tp=Eg;function Me(...e){let t={...e[0]};for(let o=1;o<e.length;o++){let r=e[o];for(let a in r){let n=t[a],i=r[a];typeof n=="function"&&typeof i=="function"&&a[0]==="o"&&a[1]==="n"&&a.charCodeAt(2)>=65&&a.charCodeAt(2)<=90?t[a]=Ql(n,i):(a==="className"||a==="UNSAFE_className")&&typeof n=="string"&&typeof i=="string"?t[a]=tp(n,i):a==="id"&&n&&i?t.id=ai(n,i):t[a]=i!==void 0?i:n;}}return t}function M(...e){return e.length===1&&e[0]?e[0]:t=>{for(let o of e)typeof o=="function"?o(t):o!=null&&(o.current=t);}}var Lg=new Set(["id"]),Bg=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),Ag=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),Fg=/^(data-.*)$/;function ii(e,t={}){let{labelable:o,isLink:r,propNames:a}=t,n={};for(let i in e)Object.prototype.hasOwnProperty.call(e,i)&&(Lg.has(i)||o&&Bg.has(i)||r&&Ag.has(i)||a?.has(i)||Fg.test(i))&&(n[i]=e[i]);return n}function Or(e){var t;return typeof window>"u"||window.navigator==null?false:((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.brands.some(o=>e.test(o.brand)))||e.test(window.navigator.userAgent)}function Fe(e){let t=null;return ()=>(t==null&&(t=e()),t)}var Fo=Fe(function(){return Or(/Firefox/i)});function ae(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 Kg(){return typeof window.ResizeObserver<"u"}function pi(e){let{ref:t,box:o,onResize:r}=e;useEffect(()=>{let a=t?.current;if(a)if(Kg()){let n=new window.ResizeObserver(i=>{i.length&&r();});return n.observe(a,{box:o}),()=>{a&&n.unobserve(a);}}else return window.addEventListener("resize",r,false),()=>{window.removeEventListener("resize",r,false);}},[r,t,o]);}function et(e){return !!e&&"label"in e&&!!e.label}function Hr(e){return !!e&&"children"in e&&!!e.children&&"title"in e}function Yg(e){return Hr(e)?jsx(Section,{items:e.children,title:e.title,"aria-label":e.title,children:t=>jsx(Item,{textValue:t.label,children:t.label},t.id)},e.id):jsx(Item,{textValue:e.label,children:e.label},e.id)}function pe(){return useCallback(e=>Yg(e),[])}function Vr(e,t,o){let{direction:r}=useLocale(),a=useDraggableCollectionState({...e,collection:t.collection,selectionManager:t.selectionManager,isDisabled:!e.enableReorder,getItems:e.getItems||(s=>[...s].map(l=>{let p=t.collection.getItem(l);return invariant(p,"Expected item to be defined."),{"text/plain":p.textValue}}))});useDraggableCollection(e,a,o);let n=useDroppableCollectionState({...e,collection:t.collection,selectionManager:t.selectionManager}),{collectionProps:i}=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)},n,o);return {collectionProps:i,dragState:a,dropState:n}}function a6(e,t){if(typeof e!="object"||!e)return e;var o=e[Symbol.toPrimitive];if(o!==void 0){var r=o.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return (t==="string"?String:Number)(e)}function n6(e){var t=a6(e,"string");return typeof t=="symbol"?t:String(t)}function i6(e,t,o){return t=n6(t),t in e?Object.defineProperty(e,t,{value:o,enumerable:true,configurable:true,writable:true}):e[t]=o,e}function sp(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 lp(e){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?sp(Object(o),true).forEach(function(r){i6(e,r,o[r]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):sp(Object(o)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(o,r));});}return e}function pp(e,t){var o={};for(var r in e)o[r]=t(e[r],r);return o}var s6=(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 false}return true},z=e=>{var t=o=>{var r=e.defaultClassName,a=lp(lp({},e.defaultVariants),o);for(var n in a){var i,s=(i=a[n])!==null&&i!==void 0?i:e.defaultVariants[n];if(s!=null){var l=s;typeof l=="boolean"&&(l=l===true?"true":"false");var p=e.variantClassNames[n][l];p&&(r+=" "+p);}}for(var[c,u]of e.compoundVariants)s6(c,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 pp(e.variantClassNames,o=>pp(o,r=>r.split(" ")[0]))}},t};var cp=z({defaultClassName:"_6n12k9b _1yep5z6ls _1yep5z6lr _1yep5z6ic _1yep5z6la",variantClassNames:{isDropTarget:{true:"_1yep5z6140"},orientation:{vertical:"_1yep5z617q",horizontal:"_1yep5z617r"}},defaultVariants:{},compoundVariants:[]}),dp="_6n12k98 _1yep5z6lq _1yep5z6is _1yep5z6it _1yep5z6iu",up=z({defaultClassName:"_6n12k99 _1yep5z6ev _1yep5z6da _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),mp=z({defaultClassName:"_6n12k91 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6dy _1yep5z6eu _1yep5z6la _1yep5z6ld _1yep5z6lq _1yep5z6lp _1yep5z6ln _1yep5z6lk",variantClassNames:{isSelected:{},isFocused:{true:"_1yep5z6140 _1yep5z617w _1yep5z617u _1yep5z617x _1yep5z614g _1yep5z614h _1yep5z614i"},isHovered:{true:"_1yep5z6125",false:"_1yep5z6124"},isFirstChild:{true:"_6n12k95"},isLastChild:{true:"_6n12k96"},isDisabled:{true:"z9nup82 _1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),fp="_6n12k9f _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",yp="_6n12k90";var bp=z({defaultClassName:"gukncs0",variantClassNames:{isVertical:{true:"gukncs1"},isSecondary:{true:"gukncs2"}},defaultVariants:{},compoundVariants:[]});var U=ht.forwardRef(({className:e,style:t,variant:o="primary",orientation:r="horizontal",UNSAFE_omitRole:a,elementType:n="div","data-block-id":i,"data-block-class":s,...l},p)=>{let{separatorProps:c}=useSeparator({...l,orientation:r,elementType:n});return jsx(n,{...c,className:classNames(bp({isVertical:r==="vertical",isSecondary:o==="secondary"}),"BaselineUI-Separator",e),"data-orientation":r,"data-block-id":i,"data-block-class":s,style:t,role:a?void 0:c.role,ref:p})});U.displayName="Separator";function y6(e){return sprinkles.properties.has(e)}var S=ht.forwardRef(({elementType:e="div",children:t,...o},r)=>{let a=e,{sprinkleProps:n,domProps:i}=useMemo(()=>{let s={},l={};for(let p in o)y6(p)?s[p]=o[p]:l[p]=o[p];return {sprinkleProps:s,domProps:l}},[o]);return jsx(a,{...i,className:classNames(sprinkles(n),"BaselineUI-Box",i.className),ref:r,children:t})});S.displayName="Box";var Oo=ht.forwardRef(({item:e,isDisabled:t,isFocusVisible:o,isSelected:r,liProps:a,showSelectedIcon:n,description:i,descriptionProps:s,labelProps:l,isFocused:p,isPressed:c,_state:u},m)=>{invariant(e.value&&et(e.value),"Item cannot be a section");let{icon:d,label:b}=e.value,{hoverProps:f,isHovered:y}=useHover({isDisabled:t}),g=filterTruthyValues({"data-selected":r,"data-disabled":t,"data-focused":p,"data-hovered":y,"data-pressed":c,"data-focus-visible":o,"data-selection-mode":u.selectionManager.selectionMode});return jsxs("li",{...mergeProps(a,f,g),className:classNames(mp({isHovered:y,isFocused:o,isFirstChild:u.collection.getFirstKey()===e.key,isLastChild:u.collection.getLastKey()===e.key,isDisabled:t}),a.className,"BaselineUI-ListBox-Option"),style:a.style,ref:m,children:[jsxs(S,{display:"flex",alignItems:"center",gap:"lg",children:[n?jsx("span",{"aria-hidden":true,style:{height:24,width:24},children:r?jsx(CheckmarkIcon,{size:24}):null}):null,d?jsx(d,{size:24}):null,jsx("span",{...l,children:b})]}),i?jsx("span",{className:up({isDisabled:t}),...s,children:i}):null]})});Oo.displayName="DefaultRenderOption";var Ut=({dropState:e,orientation:t="vertical",dropIndicatorStyle:o,dropIndicatorClassName:r,renderDropIndicator:a=({isDropTarget:i,isHidden:s,dropIndicatorProps:l,orientation:p},c)=>s?null:jsx("li",{...l,ref:c,"data-drop-target":i,className:classNames(cp({isDropTarget:i,orientation:p}),"BaselineUI-DropIndicator",r),style:o}),...n})=>{let i=ht.useRef(null),{dropIndicatorProps:s,isHidden:l,isDropTarget:p}=useDropIndicator(n,e,i);return a({dropIndicatorProps:{...s,role:"option"},isHidden:l,isDropTarget:p,orientation:t},i)};function xt(e,t,o){return typeof e=="function"?e(t,o):e}function Ur(e,t,o){return typeof e=="function"?e(t,o):e}function qr(e,t){return typeof e=="function"?e(t):e}function ui(e,t){return typeof e=="function"?e(t):e}var zp=({item:e,children:t,state:o,dragState:r,...a})=>{let{dragProps:n}=useDraggableItem({key:e.key},r);return jsxs(Fragment,{children:[jsx(Ut,{target:{type:"item",key:e.key,dropPosition:"before"},...a}),t(n),o.collection.getKeyAfter(e.key)==null&&jsx(Ut,{target:{type:"item",key:e.key,dropPosition:"after"},...a})]})};zp.displayName="DraggableListOption";var Ho=ht.forwardRef(({item:e,renderOption:t=(m,d,b)=>jsx(Oo,{item:m,liProps:d.optionProps,...d,ref:b}),showSelectedIcon:o,state:r,dragState:a,dropState:n,orientation:i,dropIndicatorStyle:s,dropIndicatorClassName:l,optionStyle:p,optionClassName:c},u)=>{let m=ht.useRef(null),d=useOption({key:e.key},r,m),{value:b}=e;invariant(b&&et(b),"ListSection should not be passed to ListOption");let f={isFocusVisible:d.isFocusVisible,isSelected:d.isSelected,isFocused:d.isFocused,isDisabled:d.isDisabled,isPressed:d.isPressed},y={style:Ur(p,b,f),className:xt(c,b,f)};return a&&n?jsx(zp,{orientation:i,state:r,item:e,dropState:n,dragState:a,dropIndicatorStyle:s,dropIndicatorClassName:l,children:g=>t(e,{...d,showSelectedIcon:o,_state:r,optionProps:{...mergeProps(d.optionProps,g),...y}},M(m,u))}):t(e,{...d,showSelectedIcon:o,_state:r,optionProps:{...d.optionProps,...y}},M(m,u))});Ho.displayName="Option";var Pp=({section:e,state:t,sectionClassName:o,sectionStyle:r,showSectionHeader:a,renderSectionHeader:n,withSectionHeaderPadding:i=false,...s})=>{let l=ht.useRef(null),{itemProps:p,groupProps:c,headingProps:u}=useListBoxSection({heading:a?n?.(e,l)||e.rendered:void 0,"aria-label":e["aria-label"]}),m=t.collection.getChildren?.(e.key);invariant(m,"children must be defined");let{value:d}=e;invariant(d&&Hr(d),"section must be a ListSection");let b=typeof r=="function"?r(d):r,f=typeof o=="function"?o(d):o;return jsxs(Fragment,{children:[e.key===t.collection.getFirstKey()?null:jsx(U,{UNSAFE_omitRole:true}),jsxs("li",{...p,style:{...p.style,...b},className:classNames(yp,f,"BaselineUI-ListBox-Section"),children:[e.rendered&&a?n?.(e,l)||jsx(S,{...u,className:classNames("BaselineUI-ListBox-SectionHeader",fp),ref:l,paddingX:"lg",typography:"label.md.medium",color:"text.primary",paddingInlineStart:i?"5xl":"lg",paddingInlineEnd:"lg",children:e.rendered}):null,jsx("ul",{...c,children:[...m].map(y=>jsx(Ho,{item:y,state:t,...s},y.key))})]})]})};function Wr({type:e="listbox",handle:t},o,r){let a=useCallback(i=>e==="listbox"?r.current?.querySelector(`[data-key="${i}"][role="option"]`):r.current?.querySelector(`[data-key="${i}"][role="row"]`),[e,r]),n=useCallback((i,s)=>{let l=a(i);l&&l?.scrollIntoView({block:"nearest",inline:"nearest",...s});},[a]);useImperativeHandle(t,()=>({scrollIntoView:n,setFocusedKey:i=>{o.selectionManager.setFocused(true),o.selectionManager.setFocusedKey(i),n(i),a(i)?.focus();}}),[n,o.selectionManager,a]),useGranularEffect(()=>{let i=r.current?.getRootNode(),s=i&&ni(i),l=o.selectionManager.focusedKey;s&&l&&n(l);},[o.selectionManager.focusedKey],[n,r]);}var Ct=ht.createContext(null),mi=ht.forwardRef(({className:e,layout:t="stack",orientation:o="vertical",showSelectedIcon:r=true,style:a,renderOption:n,enableReorder:i=false,"data-block-id":s,"data-block-class":l,renderDragPreview:p,onReorder:c,state:u,listBoxHandle:m,...d},b)=>{let f=ht.useRef(null),{direction:y}=useLocale(),g=ht.useRef(null),{listBoxProps:v}=useListBox({...d,shouldSelectOnPressUp:i,keyboardDelegate:new ListKeyboardDelegate({collection:u.collection,ref:g,layout:t,orientation:o,direction:y,disabledKeys:u.disabledKeys})},u,g);Wr({handle:m},u,g);let{collectionProps:_,dragState:h,dropState:x}=Vr({...d,onReorder:c,layout:t,orientation:o,enableReorder:i,preview:f},u,g),{isFocusVisible:R,isFocused:P,focusProps:w}=useFocusRing(),C=filterTruthyValues({"data-block-id":s,"data-block-class":l,"data-layout":t,"data-empty":u.collection.size===0,"data-focused":P,"data-focus-visible":R,"data-orientation":o});return jsxs("ul",{...mergeProps(v,w,C,_),className:classNames(dp,"BaselineUI-ListBox",e),style:a,ref:M(b,g),children:[[...u.collection].map(D=>{let k={key:D.key,state:u,dragState:h,dropState:x,renderOption:n,renderDropIndicator:d.renderDropIndicator,renderSectionHeader:d.renderSectionHeader,showSelectedIcon:r,orientation:o,dropIndicatorStyle:d.dropIndicatorStyle,dropIndicatorClassName:d.dropIndicatorClassName,optionStyle:d.optionStyle,optionClassName:d.optionClassName,sectionClassName:d.sectionClassName,sectionStyle:d.sectionStyle,showSectionHeader:d.showSectionHeader,withSectionHeaderPadding:d.withSectionHeaderPadding};return D.type==="section"?createElement(Pp,{...k,key:D.key,section:D}):createElement(Ho,{...k,key:D.key,item:D})}),p?jsx(DragPreview,{ref:f,children:p}):null]})});mi.displayName="ListBoxCore";var Ip=ht.forwardRef((e,t)=>{let o=pe(),r=useListState({...e,children:o});return jsx(mi,{...e,ref:t,state:r})});Ip.displayName="ListBoxStandalone";var me=ht.forwardRef((e,t)=>{let o=useContext(Ct);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(mi,{...e,ref:t,state:o}):jsx(Ip,{...e,ref:t})});me.displayName="ListBox";var Xr="uf19bsf _1yep5z6la",Rp=z({defaultClassName:"uf19bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f5 _1yep5z6lp _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6lk",variantClassNames:{size:{xxs:"uf19bs1",xs:"uf19bs2",sm:"uf19bs3",md:"uf19bs4",lg:"uf19bs5 _1yep5z6wo _1yep5z6wp _1yep5z6wq _1yep5z6xc _1yep5z6xd _1yep5z6xe _1yep5z6y0 _1yep5z6y1 _1yep5z6y2 _1yep5z6yo _1yep5z6yp _1yep5z6yq"},isHovered:{true:"uf19bs6"},isDisabled:{true:"uf19bs7 _1yep5z611a"},isFocusVisible:{true:"uf19bs8"},variant:{primary:"uf19bs9",secondary:"uf19bsa",tertiary:"uf19bsb",ghost:"uf19bsc",toolbar:"uf19bsd _1yep5z6x6 _1yep5z6x7 _1yep5z6x8 _1yep5z6xu _1yep5z6xv _1yep5z6xw _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8",popover:"uf19bse _1yep5z6pr _1yep5z6ps _1yep5z6pt _1yep5z6nf _1yep5z6ng _1yep5z6nh _1yep5z6m6 _1yep5z6m7 _1yep5z6m8 _1yep5z6oi _1yep5z6oj _1yep5z6ok _1yep5z6vr _1yep5z6vs _1yep5z6vt"}},defaultVariants:{},compoundVariants:[[{variant:"toolbar",isHovered:true,isFocusVisible:false},"_1yep5z61o9"],[{variant:"primary",isHovered:true,isFocusVisible:false},"_1yep5z61o9"],[{variant:"secondary",isHovered:true,isFocusVisible:false},"_1yep5z61nc"],[{variant:"tertiary",isHovered:true,isFocusVisible:false},"_1yep5z61nb _1yep5z61o9"],[{variant:"ghost",isHovered:true,isFocusVisible:false},"_1yep5z61nh"],[{variant:"popover",isHovered:true,isFocusVisible:false},"_1yep5z61q6 _1yep5z61tx _1yep5z61u1 _1yep5z61ty"],[{variant:"ghost",isDisabled:false},"_1yep5z61ng"],[{variant:"popover",size:"lg"},"_1yep5z61io _1yep5z61ip _1yep5z61iq _1yep5z61jc _1yep5z61jd _1yep5z61je _1yep5z61k0 _1yep5z61k1 _1yep5z61k2 _1yep5z61ko _1yep5z61kp _1yep5z61kq"]]});var Vo=ht.createContext({state:null,overlayTriggerAria:{triggerProps:{},overlayProps:{}},triggerRef:void 0}),je=({children:e,...t})=>{let o=ht.useRef(null),r=useOverlayTriggerState(t),a=useOverlayTrigger(t,r),n=useMemo(()=>({state:r,overlayTriggerAria:a,triggerRef:o}),[r,a]);return jsx(Vo.Provider,{value:n,children:e})};var Tp=z({defaultClassName:"_1gzftth2",variantClassNames:{placement:{bottom:"_1gzftth3",top:"_1gzftth4",right:"_1gzftth5",left:"_1gzftth6"}},defaultVariants:{},compoundVariants:[]}),Sp=z({defaultClassName:"_1gzftth7",variantClassNames:{placement:{bottom:"_1gzftth8",top:"_1gzftth9",right:"_1gzfttha",left:"_1gzftthb"}},defaultVariants:{},compoundVariants:[]}),Dp="_1gzftth1 _1yep5z6is _1yep5z6it _1yep5z6iu",Mp="_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6k4 _1yep5z6k5 _1yep5z6k6 _1yep5z6d7",Np="_1gzftthd",Ep="_1gzftthc",Lp="var(--_1gzftth0)";function c3(e){return e.closest(".BaselineUI-Portal")||e.closest(".BaselineUI-Popover-Content")}function Bp(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 Zr=ht.createContext({isSelected:false,ref:void 0}),Oe=({children:e,anchorRect:t})=>{let{state:o,overlayTriggerAria:r,triggerRef:a}=useContext(Vo);invariant(o,"PopoverTrigger must be used within a Popover");let{triggerProps:n}=r,i=useMemo(()=>({...n,isSelected:o.isOpen,ref:a}),[n,o.isOpen,a]);return invariant(!t&&e||t&&!e,"Either one of anchorRect or children has to be provided."),invariant(!t||Bp(t),"If provided, the anchorRect prop must be an object with left and top number values, and optionally width and height."),jsx(Zr.Provider,{value:i,children:t?jsx("div",{className:classNames(Np,"BaselineUI-PopoverTrigger-Hidden"),style:t,ref:a,tabIndex:-1},JSON.stringify(t)):e})};var ve=({label:e,tooltip:t,...o})=>({tooltipProps:useMemo(()=>{let a={size:"sm",variant:"inverse",text:e,includeArrow:false,placement:"bottom start",offset:4,...o};if(typeof t=="object")return {...a,...t};if(t)return a},[e,o,t])});function Jr({tooltip:e,"aria-label":t,"aria-labelledby":o},r){let[a,n]=useState(t||"");useEffect(()=>{if(o){let l=ge(r.current).querySelector(`#${o}`);l&&n(l.textContent||"");}else t&&n(t);},[o,r,t]);let{tooltipProps:i}=ve({label:a,tooltip:e});return {tooltipProps:i}}var Qr=e=>{let t=ht.useRef(null),{ref:o,...r}=useContext(Zr)||{},{buttonProps:a,isPressed:n}=useButton({...e,...r},t),{isFocusVisible:i,isFocused:s,focusProps:l}=useFocusRing(),{hoverProps:p,isHovered:c}=useHover({isDisabled:e.isDisabled});return {buttonProps:Me(a,l,p),isPressed:n,ref:M(t,o||null),isFocusVisible:i,isFocused:s,isHovered:c,uiStateOptions:{isHovered:c,isFocused:s,isPressed:n,isDisabled:e.isDisabled,isFocusVisible:i}}},ea=(e,t)=>{let o=ht.useRef(null),{ref:r,...a}=useContext(Zr)||{},{buttonProps:n,isPressed:i}=useToggleButton({...e,...a},t,o);(n.role==="radio"||n.role==="checkbox")&&(n["aria-pressed"]=void 0);let{isFocusVisible:s,isFocused:l,focusProps:p}=useFocusRing(),{hoverProps:c,isHovered:u}=useHover({isDisabled:e.isDisabled});return {buttonProps:Me(n,p,c),isPressed:i,ref:M(o,r||null),isFocusVisible:s,isFocused:l,isHovered:u,uiStateOptions:{isHovered:u,isFocused:l,isPressed:i,isDisabled:e.isDisabled,isFocusVisible:s,isSelected:t.isSelected}}};var ta=z({defaultClassName:"oom8bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6dy _1yep5z6la",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:true},"oom8bsg"],[{variant:"secondary",isHovered:true},"oom8bsh"],[{variant:"tertiary",isHovered:true},"oom8bsi"],[{variant:"popover",isHovered:true},"oom8bsj"],[{variant:"ghost",isHovered:true},"oom8bsk"],[{variant:"success",isHovered:true},"oom8bsl"],[{variant:"warning",isHovered:true},"oom8bsm"],[{variant:"error",isHovered:true},"oom8bsn"],[{variant:"primary",isFocusVisible:true},"oom8bso"],[{variant:"tertiary",isFocusVisible:true},"oom8bsp"],[{variant:"success",isFocusVisible:true},"oom8bsq"],[{variant:"warning",isFocusVisible:true},"oom8bsr"],[{variant:"error",isFocusVisible:true},"oom8bss"]]}),yi=z({defaultClassName:"oom8bst _1yep5z6la",variantClassNames:{isDisabled:{true:"oom8bsu"},isFocusVisible:{true:"oom8bsv"},isHovered:{true:"_1yep5z6115"},variant:{primary:"_1yep5z611c",secondary:"_1yep5z6118",tertiary:"_1yep5z611d",ghost:"_1yep5z611d",popover:"_1yep5z6118",toolbar:"_1yep5z6118",success:"_1yep5z611b",warning:"_1yep5z611b",error:"_1yep5z611b"}},defaultVariants:{},compoundVariants:[[{variant:"tertiary",isHovered:true},"_1yep5z61nf"],[{variant:"ghost",isHovered:true},"_1yep5z61nh"],[{variant:"tertiary",isFocusVisible:true},"_1yep5z61nf"],[{variant:"secondary",isDisabled:true},"_1yep5z61nd"],[{variant:"tertiary",isDisabled:true},"_1yep5z61nd"],[{variant:"ghost",isDisabled:true},"_1yep5z61nd"],[{variant:"popover",isDisabled:true},"_1yep5z61nd"],[{variant:"toolbar",isDisabled:true},"_1yep5z61nd"]]});var yv={sm:16,md:20,lg:24},q=ht.forwardRef(({label:e,style:t,className:o,iconStart:r,iconEnd:a,variant:n="primary",elementType:i="button",isDisabled:s,size:l="sm","data-block-id":p,"data-block-class":c,...u},m)=>{let{buttonProps:d,isPressed:b,ref:f,isFocusVisible:y,isFocused:g,isHovered:v,uiStateOptions:_}=Qr({...u,elementType:i,isDisabled:s}),h=yv[l],x=filterTruthyValues({"data-block-id":p,"data-block-class":c,"data-disabled":s,"data-focused":g,"data-focus-visible":y,"data-hovered":v,"data-pressed":b});return jsxs(i,{...mergeProps(d,x),className:classNames(ta({isDisabled:!!s,isFocusVisible:y,isHovered:v,variant:n,size:l}),"BaselineUI-ActionButton",typeof o=="function"?o(_):o),style:typeof t=="function"?t(_):t,ref:M(m,f),children:[!!r&&jsx(r,{size:h,className:yi({variant:n,isDisabled:s,isFocusVisible:y,isHovered:v})}),e,!!a&&jsx(a,{size:h,className:yi({variant:n,isDisabled:s,isFocusVisible:y,isHovered:v})}),n==="popover"&&jsx(CaretDownIcon,{size:8,className:Xr})]})});q.displayName="ActionButton";var oa=ht.forwardRef(({className:e,style:t,node:o,"data-block-id":r,"data-block-class":a,...n},i)=>{let s=ht.useRef(null);ht.useEffect(()=>{let c=s.current;return c?.append(o),()=>{c?.contains(o)&&o.remove();}},[o]);let{pressProps:l,isPressed:p}=usePress(n);return jsx("div",{...l,className:e,style:t,"data-block-id":r,"data-block-class":a,"data-pressed":p,"data-testid":"dom-node-renderer",ref:M(i,s)})});oa.displayName="DomNodeRenderer";var Vp="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z6ln",Up="_14uvjig3 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k",qp="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6jj _1yep5z6jk _1yep5z6jl",Kp=z({defaultClassName:"_14uvjig0 _1yep5z6dy _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6111"},hasNumberInput:{false:"_1yep5z6ol _1yep5z6om _1yep5z6on"}},defaultVariants:{},compoundVariants:[]}),Gp=z({defaultClassName:"_14uvjigb _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6g9 _1yep5z6lp _1yep5z6la",variantClassNames:{active:{true:"_14uvjigc _1yep5z612i _1yep5z6181 _1yep5z617t"},isDisabled:{true:"_14uvjigd _1yep5z612m"},isReadOnly:{true:"_1yep5z614p _1yep5z614q _1yep5z614r"},isFocusVisible:{true:"_14uvjigf _1yep5z612i _1yep5z617d"},isHovered:{true:"_14uvjigg _1yep5z612i"}},defaultVariants:{},compoundVariants:[]}),Wp="_14uvjiga _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf",Yp="_14uvjig4 _1yep5z6g3 _1yep5z6ln",Xp=z({defaultClassName:"_14uvjig5 _1yep5z6g9 _1yep5z6ig _1yep5z6ih _1yep5z6ii _1yep5z6lo",variantClassNames:{active:{true:"_1yep5z612i"},isFocusVisible:{true:"_1yep5z612i"},isDisabled:{true:"_1yep5z612m"},isHovered:{true:"_1yep5z612i"}},defaultVariants:{},compoundVariants:[]});var Kt=z({defaultClassName:"nrh1ehr _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z6ew _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6111"},hasError:{true:"_1yep5z610h"},labelPosition:{start:"nrh1ehu",top:"nrh1ehv"}},defaultVariants:{},compoundVariants:[]}),ra=z({defaultClassName:"nrh1ehi _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6eu _1yep5z6ln _1yep5z6ly _1yep5z6lq _1yep5z6dy",variantClassNames:{isDisabled:{true:"nrh1ehj"},labelPosition:{top:"nrh1ehk",start:"nrh1ehl"}},defaultVariants:{},compoundVariants:[]}),Gt=z({defaultClassName:"nrh1ehm _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6lk",variantClassNames:{validationState:{valid:"nrh1ehn",error:"_1yep5z610h",warning:"_1yep5z610p"},isReadOnly:{true:"_1yep5z6118"}},defaultVariants:{},compoundVariants:[]}),Wt="_1yep5z6ev _1yep5z6dy",tt=z({defaultClassName:"nrh1eh3 _1yep5z6iv _1yep5z6iw _1yep5z6ix",variantClassNames:{labelPosition:{top:"_1yep5z6t9 _1yep5z6ta _1yep5z6tb",start:"_1yep5z6n6 _1yep5z6n7 _1yep5z6n8 _1yep5z6157 _1yep5z6158 _1yep5z6159"},hasMessage:{true:"nrh1eh6"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:false},"_1yep5z61sj _1yep5z61sk _1yep5z61sl"]]}),ot=z({defaultClassName:"nrh1eh0 _1yep5z6ln",variantClassNames:{labelPosition:{top:"_1yep5z614v _1yep5z614w _1yep5z614x _1yep5z6157 _1yep5z6158 _1yep5z6159",start:"_1yep5z614v _1yep5z614w _1yep5z614x _1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z616m _1yep5z616n _1yep5z616o _1yep5z6vl _1yep5z6vm _1yep5z6vn"}},defaultVariants:{},compoundVariants:[]}),Yt=z({defaultClassName:"nrh1eh7 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6m1 _1yep5z6lz _1yep5z6h4 _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{validationState:{valid:"nrh1eh8",error:"_1yep5z612q",warning:"nrh1eha"},isHovered:{true:"nrh1ehb"},isFocused:{true:"_1yep5z6wl _1yep5z6wm _1yep5z6wn _1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6xx _1yep5z6xy _1yep5z6xz _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z6184 _1yep5z6182 _1yep5z6134 _1yep5z617v _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"nrh1ehd"},variant:{primary:"nrh1ehe",ghost:"nrh1ehf"},isReadOnly:{true:"_1yep5z6x6 _1yep5z6x7 _1yep5z6x8 _1yep5z6xu _1yep5z6xv _1yep5z6xw _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:true,isFocused:false,validationState:"valid"},"_1yep5z61pa _1yep5z61u5 _1yep5z61u7"],[{variant:"ghost",isFocused:false,isHovered:false,validationState:"valid"},"_1yep5z61pm"],[{isHovered:true,validationState:"valid",isDisabled:false,isReadOnly:false,isFocused:false,variant:"primary"},"_1yep5z61pb"],[{isHovered:true,validationState:"warning",isDisabled:false,isReadOnly:false,isFocused:false},"_1yep5z61pb"],[{isReadOnly:true,variant:"primary",isFocused:false},"nrh1ehh"],[{isReadOnly:true,isFocused:true},"_1yep5z61io _1yep5z61ip _1yep5z61iq _1yep5z61jc _1yep5z61jd _1yep5z61je _1yep5z61k0 _1yep5z61k1 _1yep5z61k2 _1yep5z61ko _1yep5z61kp _1yep5z61kq"],[{isHovered:true,isFocused:false,isDisabled:false,isReadOnly:false},"_1yep5z61tg"]]});function _e({description:e,errorMessageProps:t,descriptionProps:o,warningMessage:r,errorMessage:a,labelPosition:n,isDisabled:i}){return e?jsx("div",{...o,className:Kt({isDisabled:i,labelPosition:n}),"aria-disabled":i,children:e}):a?jsx("div",{...t,className:Kt({hasError:true,labelPosition:n}),"aria-disabled":i,children:a}):r?jsx("div",{className:Kt({isDisabled:i,labelPosition:n}),"aria-disabled":i,children:r}):null}var Zp=z({defaultClassName:"_1lnwne1 z9nup81",variantClassNames:{isHoveredOrFocused:{true:"_1lnwne2"},isInteractive:{false:"z9nup82"}},defaultVariants:{},compoundVariants:[[{isHoveredOrFocused:true,isInteractive:true},"_1lnwne4"]]}),Jp="_1lnwne0";var Qp=z({defaultClassName:"_1jwycy80",variantClassNames:{placement:{bottom:"_1jwycy81",left:"_1jwycy82",right:"_1jwycy83",top:"_1jwycy84"},variant:{default:"_1jwycy85",inverse:"_1jwycy86"}},defaultVariants:{},compoundVariants:[]}),ec=z({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:"_1yep5z6g9 _1yep5z6ez",inverse:"_1yep5z6d7 _1yep5z6g1 _1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});function aa({placement:e}){let t=useMemo(()=>{switch(e){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:4}}},[e]);return {transitionProps:{initial:{opacity:0,transform:`translate3d(${t.x}px, ${t.y}px, 0) scale(0.98)`},animate:{opacity:1,transform:"translate3d(0, 0, 0) scale(1)"},transition:{ease:"easeOut"}}}}var _i=ht.forwardRef(({children:e,state:t,overlayProps:o,arrowProps:r,placement:a,variant:n,size:i,tooltipProps:s,includeArrow:l},p)=>{let{tooltipProps:c}=useTooltip({isOpen:t.isOpen},t),u=a==="center"?"bottom":a,{transitionProps:m}=aa({placement:a});return jsxs(motion.span,{...mergeProps(o,m),ref:p,"data-placement":u,children:[l?jsx("div",{className:Qp({placement:u,variant:n}),...r}):null,jsx("div",{...mergeProps(c,s),className:ec({variant:n,size:i}),children:e})]})});_i.displayName="TooltipContent";var zi=ht.createContext(void 0),na=({portalContainer:e,children:t})=>jsx(zi.Provider,{value:e,children:t});na.displayName="PortalContainerProvider";function ac({ref:e,onIntersect:t,isDisabled:o,threshold:r,rootMargin:a,root:n}){let i=ht.useRef(null);useEffect(()=>{if(o){i.current?.disconnect(),i.current=null;return}i.current=new IntersectionObserver(([s])=>{t(s);},{root:n?.current,rootMargin:a,threshold:r});},[t,o,n,a,r]),useEffect(()=>{let{current:s}=i;return e.current&&s?.observe(e.current),()=>s?.disconnect()},[e]);}function nc({ref:e,onResize:t,isDisabled:o}){let r=ht.useRef(null),[a,n]=ht.useState();return ht.useEffect(()=>{if(o){r.current?.disconnect(),r.current=null;return}r.current=new ResizeObserver(([i])=>{n(i.contentRect),t?.(i);});},[t,o,n]),ht.useEffect(()=>{let{current:i}=r;return e.current&&i?.observe(e.current),()=>i?.disconnect()},[e]),{size:a}}function Xt({src:e,alt:t}){let[o,r]=useState(false),[a,n]=useState(false),[i,s]=useState(false),l=()=>{r(true),s(false);},p=()=>{n(true),s(false);};return useEffect(()=>{if(!e)return;s(true);let c=new Image;return c.src=e,c.addEventListener("load",l),c.addEventListener("error",p),()=>{c.removeEventListener("load",l),c.removeEventListener("error",p);}},[e]),{isLoaded:o,hasError:a,isLoading:i,imgProps:{src:o?e:void 0,alt:t}}}function sa(){let e=useRef(true);return useEffect(()=>{e.current=false;},[]),e.current}var ic="SET_STATE",la="UNDO",pa="REDO",Mv=(e,t)=>{let{past:o,present:r,future:a}=e;switch(t.type){case ic:return {past:[...o,r],present:t.data,future:[]};case la:return {past:o.slice(0,o?.length-1),present:o[o?.length-1],future:[r,...a]};case pa:return {past:[...o,r],present:a[0],future:a.slice(1)};default:throw new Error("Invalid action type")}},sc=(e={},{isDisabled:t,onAction:o})=>{let r=sa(),[a,n]=useReducer(Mv,{past:[],present:e,future:[]}),{past:i,present:s,future:l}=a,p=f=>{n({type:ic,data:f});},c=useRef(),u=()=>{c.current=la,n({type:la});},m=()=>{c.current=pa,n({type:pa});},d=!!i?.length,b=!!l?.length;return useGranularEffect(()=>{(c.current===la||c.current===pa)&&(o?.(s,c.current),c.current=void 0);},[s],[o,r]),{state:s,push:t?()=>{}:p,undo:t?()=>{}:u,redo:t?()=>{}:m,pastStates:i,futureStates:l,canUndo:d,canRedo:b}};var xi=ht.createContext({messages:{},shouldLogMissingMessages:true,hasMissingErrorLoggedFor:{current:new Set},setLang:()=>{}}),cc=({children:e,messages:t={},shouldLogMissingMessages:o=true,...r})=>{let a=useRef(new Set),[n,i]=useState(r.locale||"");useEffect(()=>{a.current.clear();},[n,r.locale]);let s=ht.useMemo(()=>({messages:t,shouldLogMissingMessages:o,hasMissingErrorLoggedFor:a,setLang:i}),[t,o,i]);return jsx(I18nProvider,{...r,children:jsx(xi.Provider,{value:s,children:e})})};cc.displayName="I18nProvider";function A(e){let{messages:t,shouldLogMissingMessages:o,hasMissingErrorLoggedFor:r,setLang:a}=useContext(xi);useEffect(()=>{!e&&Fv(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.");},[e,t]);let n=useMemo(()=>e?cleanKeyFromGlobImport(e):t,[e,t]),i=useMessageFormatter(n),s=useLocale();useEffect(()=>{a(s.locale);},[s.locale,a]);let l=useCallback(c=>{o&&!r.current.has(c)&&(console.log(`BUI \u{1F30D}: Translation not found for key: \`${c}\` for locale: \`${s.locale}\`. The default message, i.e. \`${c}\`, will be used instead.`),r.current.add(c));},[r,s.locale,o]),p=useCallback((c,u)=>{if(typeof c=="object")try{return i(c.id,u)}catch{return l(c.id),c.defaultMessage||c.id}else try{return i(c,u)}catch{return l(c),c}},[i,l]);return useMemo(()=>({formatMessage:p,locale:s}),[p,s])}var G=e=>e;function cD(e,t,o){let r=ht.useRef(null);return ht.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 yc(e,t){let[o,r]=useState(()=>{try{let n=window.localStorage.getItem(e);return n?JSON.parse(n):t}catch(n){return console.log(n),t}});return [o,n=>{try{let i=n instanceof Function?n(o):n;r(i),window.localStorage.setItem(e,JSON.stringify(i));}catch(i){console.log(i);}}]}function gD({ref:e,onSelectionChange:t,onSelectionEnd:o,isDisabled:r}){let a=ht.useRef(null);usePress({ref:e,isDisabled:r,onPressEnd(){let i=re(e.current).getSelection();i&&e.current?.contains(i.anchorNode)&&o?.(i);},onPressStart(){let n=re(e.current);a.current=n.getSelection(),a.current&&a.current.removeAllRanges();}}),useEffect(()=>{let n=e.current;if(!n||r)return;function i(){let p=re(n).getSelection();p&&e.current?.contains(p.anchorNode)&&t(p);}let s=ge(n);return s.addEventListener("selectionchange",i),()=>{s.removeEventListener("selectionchange",i);}},[e,t,r]);}var ca=ht.createContext({breakpoints:breakpoints}),Yv=({children:e,breakpoints:t=breakpoints})=>{let o=useMemo(()=>({breakpoints:t}),[t]);return jsx(ca.Provider,{value:o,children:e})};function Ne(e){let{breakpoints:t=breakpoints}=useContext(ca),o=useMemo(()=>({tablet:`screen and (min-width: ${t.tablet}px)`,desktop:`screen and (min-width: ${t.desktop}px)`}),[t]),r=useCallback(()=>{let i=re(e??typeof window>"u"?void 0:e),s=i.matchMedia(o.tablet);return i.matchMedia(o.desktop).matches?"desktop":s.matches?"tablet":"mobile"},[e,o]),[a,n]=ht.useState(r);return Se(()=>{let i=re(e),s=()=>{n(r());};return i.addEventListener("resize",s),s(),()=>{i.removeEventListener("resize",s);}},[e,r]),a}var a_=typeof window<"u";function Pi(){return a_?document.body:null}var He=ht.createContext({container:null,portalContainer:null,shouldContainOverlays:false,isContainerPositioned:false,containerWidth:void 0,containerHeight:void 0}),n_=({children:e,container:t=Pi(),portalContainer:o,shouldContainOverlays:r="auto"})=>{let a=Ne(),[n,i]=useState(),[s,l]=useState(),p=useMemo(()=>t===Pi()||r==="never"?false:r==="always"?true:a!=="mobile",[r,a,t]),[c,u]=useState(false),m=sa();useEffect(()=>{if(!t||m)return;let f=re(t).getComputedStyle(t),y=!!f.position&&f.position!=="static";u(y);let g=t.getBoundingClientRect();(g.width===0||g.height===0)&&console.error("FrameProvider: container does not have a width or height. Please ensure that the container is visible and has a width and height.");function v({width:h,height:x}){t&&(i(h),l(x));}let _=new ResizeObserver(h=>{for(let x of h)v({width:x.contentRect.width,height:x.contentRect.height});});return p&&(v({width:g.width,height:g.height}),_.observe(t)),t.dataset.shouldContainOverlays=p.toString(),()=>{_.disconnect(),t.dataset.shouldContainOverlays="";}},[t,m,p]);let d=useMemo(()=>({container:t,portalContainer:o||t||Pi(),shouldContainOverlays:p,isContainerPositioned:c,containerWidth:n,containerHeight:s}),[t,o,p,c,n,s]);return jsx(He.Provider,{value:d,children:jsx(na,{portalContainer:d.portalContainer||void 0,children:e})})};function ze(e){let t=useContext(zi),{portalContainer:o}=useContext(He);return e||t||o||void 0}var zc=z({defaultClassName:"z9nup83",variantClassNames:{size:{xs:"z9nup84",sm:"z9nup85"}},defaultVariants:{},compoundVariants:[]}),hc="z9nup80",Zt="z9nup82",xc="z9nup86";function ki(e=typeof window>"u"?void 0:window){let[t,o]=useState("light"),[r,a]=useState(false),[n,i]=useState(false),[s,l]=useState(false);return useEffect(()=>{if(!e)return;let p=e.matchMedia("(prefers-color-scheme: dark)"),c=u=>{o(u.matches?"dark":"light");};return p.matches&&o("dark"),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[e]),useEffect(()=>{if(!e)return;let p=e.matchMedia("(prefers-contrast: more)"),c=u=>{a(u.matches);};return a(p.matches),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[e]),useEffect(()=>{if(!e)return;let p=e.matchMedia("(prefers-reduced-motion: reduce)"),c=u=>{i(u.matches);};return p.matches&&i(true),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[e]),useEffect(()=>{if(!e)return;let p=e.matchMedia("(prefers-reduced-transparency: reduce)"),c=u=>{l(u.matches);};return p.matches&&l(true),p.addEventListener("change",c),()=>{p.addEventListener("change",c);}},[e]),{colorScheme:t,highContrast:r,reducedMotion:n,transparency:s}}var Jt=createContext({theme:lightTheme,setTheme:()=>{},shouldHandleVirtualKeyboard:true});var Cc="var(--hj25q10)";var ma={LIGHT:{name:"light",theme:lightTheme},DARK:{name:"dark",theme:darkTheme}},fa=ht.forwardRef(({theme:e="system",children:t,setTheme:o,onThemeChange:r,className:a,style:n,UNSAFE_domProps:i,"data-block-id":s,"data-block-class":l,reducedMotion:p="user",shouldHandleVirtualKeyboard:c=true},u)=>{let{direction:m}=useLocale(),{colorScheme:d,reducedMotion:b,highContrast:f,transparency:y}=ki(),{name:g,theme:v}=useMemo(()=>{switch(e){case "system":return d==="light"?ma.LIGHT:ma.DARK;case "light":return ma.LIGHT;case "dark":return ma.DARK;default:return {name:"custom",theme:e}}},[d,e]),_=Ne(),h={"data-theme":g,"data-block-id":s,"data-block-class":l,"data-reduced-motion":p==="user"?b:p==="always","data-high-contrast":f,"data-transparency":y,"data-device":_},x=useMemo(()=>({theme:v,setTheme:R=>{o?.(R),r?.(R);},shouldHandleVirtualKeyboard:c}),[v,o,r,c]);return useEffect(()=>{o&&console.warn("ThemeProvider: The `setTheme` prop is deprecated and will be removed in a future version of Baseline UI. Use the `onThemeChange` prop instead.");},[o]),jsx(Jt.Provider,{value:x,children:jsx(MotionConfig,{reducedMotion:p,children:jsx("div",{...mergeProps(i,h),className:classNames(hc,"BaselineUI-ThemeProvider",a),style:{...assignInlineVars(themeVars,v),...assignInlineVars({[Cc]:m==="rtl"?"-1":"1"}),...n},ref:u,children:t})})})});fa.displayName="ThemeProvider";function _M(){MotionGlobalConfig.skipAnimations=true;}function zM(){MotionGlobalConfig.skipAnimations=false;}var he=ht.forwardRef(({className:e,style:t,children:o,"data-block-id":r,"data-block-class":a,portalContainer:n,...i},s)=>{let{theme:l}=useContext(Jt),p=ze();return jsx(Overlay,{...i,portalContainer:n??p,children:jsx(fa,{ref:s,theme:l,style:t,className:classNames("BaselineUI-Portal",e),"data-block-id":r,"data-block-class":a,children:o})})});he.displayName="Portal";var J=ht.forwardRef(({children:e,placement:t="bottom",delay:o=1e3,closeDelay:r=500,variant:a="default",size:n="md",includeArrow:i=true,portalContainer:s,className:l,style:p,"data-block-id":c,"data-block-class":u,...m},d)=>{let b=ht.useRef(null),f=ht.useRef(null),y=!m.text||m.isDisabled,g=useTooltipTriggerState({...m,delay:o,closeDelay:r,isDisabled:y}),{triggerProps:v,tooltipProps:_}=useTooltipTrigger({...m,isDisabled:y,delay:o,closeDelay:r},g,b),h=ze(s),{overlayProps:x,arrowProps:R,placement:P,updatePosition:w}=useOverlayPosition({arrowSize:i?13:0,targetRef:b,arrowBoundaryOffset:i?8:0,offset:i?12:2,overlayRef:f,placement:t,isOpen:g.isOpen,...m});ac({ref:f,threshold:1,onIntersect:w,isDisabled:!g.isOpen}),nc({ref:b,onResize:w,isDisabled:!g.isOpen});let C=ht.isValidElement(e)?jsx(FocusableProvider,{...v,ref:b,children:e}):typeof e=="function"?e({triggerProps:v,triggerRef:b}):null;return jsxs(Fragment,{children:[C,g.isOpen?jsx(he,{disableFocusManagement:true,portalContainer:h,className:l,style:p,"data-block-id":c,"data-block-class":u,children:jsx(_i,{ref:M(d,f),state:g,arrowProps:R,overlayProps:x,placement:P,tooltipProps:_,variant:a,size:n,includeArrow:i,children:m.text})}):null]})});J.displayName="Tooltip";var ba=ht.forwardRef(({elementType:e,children:t,...o},r)=>{let a=ae(r),{focusableProps:n}=useFocusable(o,a);return jsx(e??"div",{ref:a,...n,children:t})});ba.displayName="Focusable";var E_={xxs:8,xs:12,sm:16,md:20,lg:24},L=ht.forwardRef((e,t)=>{let o=ae(t),{tooltipProps:r}=Jr(e,o);return r?jsx(J,{...r,children:jsx(Ri,{...e,ref:o})}):jsx(Ri,{...e,ref:o})});L.displayName="ActionIconButton";var Ri=ht.forwardRef(({className:e,style:t,icon:o,size:r="md",variant:a="primary",UNSAFE_NON_INTERACTIVE:n,elementType:i=n?"div":"button",...s},l)=>{let p=s["aria-label"],c=s["aria-labelledby"];useEffect(()=>{!p&&!c&&console.warn("An `ActionIconButton` requires an aria-label or aria-labelledby prop.");},[p,c]);let{buttonProps:u,isPressed:m,ref:d,isFocusVisible:b,isFocused:f,isHovered:y,uiStateOptions:g}=Qr({...s,elementType:i}),v=filterTruthyValues({"data-block-id":s["data-block-id"],"data-block-class":s["data-block-class"],"data-focused":f,"data-focus-visible":b,"data-disabled":s.isDisabled,"data-hovered":y,"data-pressed":m});return jsxs(i,{...mergeProps(u,v),className:classNames(Rp({variant:a,size:r,isDisabled:!!s.isDisabled,isFocusVisible:b,isHovered:y}),"BaselineUI-ActionIconButton",typeof e=="function"?e(g):e),ref:M(l,d),style:typeof t=="function"?t(g):t,...n&&{tabIndex:void 0,role:void 0,"aria-label":void 0,"aria-labelledby":void 0,"aria-disabled":void 0},children:[jsx(o,{role:"presentation",size:E_[r]}),a==="popover"&&jsx(CaretDownIcon,{size:8,className:Xr})]})});Ri.displayName="ActionIconButtonCore";var Ve=ht.forwardRef(({className:e,style:t,labelPosition:o="top",variant:r="primary",showStepper:a=true,...n},i)=>{let s=ht.useRef(null),{locale:l}=useLocale(),p=useNumberFieldState({...n,locale:l}),{hoverProps:c,isHovered:u}=useHover({isDisabled:n.isDisabled}),{focusProps:m,isFocusVisible:d,isFocused:b}=useFocusRing(),{labelProps:f,decrementButtonProps:y,inputProps:g,incrementButtonProps:v,groupProps:_,descriptionProps:h,errorMessageProps:x}=useNumberField(n,p,s),R=useMemo(()=>n.isReadOnly?ReadOnlyIcon:n.isInvalid?ErrorCircleFilledIcon:null,[n.isInvalid,n.isReadOnly]),P=_e({description:n.description,errorMessageProps:x,descriptionProps:h,errorMessage:n.errorMessage,labelPosition:o,isDisabled:n.isDisabled}),w=filterTruthyValues({"data-disabled":n.isDisabled,"data-readonly":n.isReadOnly,"data-hovered":u,"data-focused":b,"data-focus-visible":d,"data-invalid":n.isInvalid,"data-block-id":n["data-block-id"],"data-block-class":n["data-block-class"]});return jsxs("div",{style:t,className:classNames(ot({labelPosition:o}),"BaselineUI-NumberInput",e),...w,ref:i,children:[n.label?jsxs("div",{className:tt({labelPosition:o,hasMessage:!!P}),children:[jsx("label",{...f,className:Wt,children:n.label}),o==="start"&&P]}):null,jsxs("div",{className:classNames({[Zt]:n.isDisabled}),children:[jsxs("div",{...mergeProps(_,c),className:classNames(Yt({isHovered:u,isDisabled:!!n.isDisabled,isReadOnly:!!n.isReadOnly,validationState:n.isInvalid?"error":"valid",isFocused:b,variant:r}),{[Jp]:o==="start"},"BaselineUI-NumberInput-Container"),children:[jsx("input",{...mergeProps(g,m),ref:s,className:classNames("BaselineUI-NumberInput-Input",ra({isDisabled:n.isDisabled,labelPosition:o}))}),R?jsx(R,{className:Gt({validationState:"error",isReadOnly:n.isReadOnly}),size:16}):null,a?jsxs("div",{className:Zp({isHoveredOrFocused:u||b,isInteractive:!n.isReadOnly&&!n.isDisabled}),children:[jsx(L,{variant:"secondary",size:"xxs",icon:MinusIcon,...y,className:"BaselineUI-NumberInput-DecrementButton"}),jsx(U,{style:{height:16},orientation:"vertical"}),jsx(L,{variant:"secondary",size:"xxs",icon:PlusIcon,...v,className:"BaselineUI-NumberInput-DecrementButton"})]}):null]}),o==="top"&&P]})]})});Ve.displayName="NumberInput";var to=ht.forwardRef(({className:e,style:t,onChange:o,onChangeEnd:r,numberFormatOptions:a,isDisabled:n,step:i,minValue:s,maxValue:l,value:p,"aria-label":c,"aria-labelledby":u,"aria-details":m,"aria-describedby":d,"data-block-id":b,"data-block-class":f,defaultValue:y,isReadOnly:g,label:v,id:_,includeNumberInput:h},x)=>{let R=ht.useRef(null),P={onChange:o===void 0?void 0:I=>{o(I[0]);},isDisabled:n||g,step:i,minValue:s,maxValue:l,onChangeEnd:r===void 0?void 0:I=>{r(I[0]);},value:p===void 0?void 0:[p],defaultValue:y===void 0?void 0:[y],"aria-label":c,"aria-labelledby":u,"aria-details":m,"aria-describedby":d,id:_,label:v},w=useNumberFormatter(a),C=useSliderState({...P,numberFormatter:w}),{trackProps:D,groupProps:k,labelProps:T}=useSlider(P,C,R),$=jsx(Ve,{variant:"ghost",showStepper:false,"aria-label":c,"aria-labelledby":T.id,value:C.getThumbValue(0),formatOptions:a,onChange:I=>{C.setThumbValue(0,I);},style:{width:55,textAlign:"right",flexShrink:0}});return jsxs("div",{...k,style:t,"data-block-id":b,"data-block-class":f,className:classNames(Vp,"BaselineUI-Slider",e),children:[v?jsxs("div",{className:qp,children:[jsx("label",{...T,className:classNames(Kp({isDisabled:n,hasNumberInput:!!h}),"BaselineUI-Slider-Label"),children:v}),h?$:null]}):null,jsxs("div",{className:Up,children:[jsx("div",{...D,className:classNames(Yp,"BaselineUI-Slider-Track"),ref:M(R,x),"data-testid":"track",children:jsx(oz,{state:C,trackRef:R,isDisabled:n,isReadOnly:g})}),h&&!v?$:null]})]})});to.displayName="Slider";function oz({state:e,trackRef:t,isDisabled:o,isReadOnly:r}){let a=ht.useRef(null),{thumbProps:n,inputProps:i,isDragging:s}=useSliderThumb({trackRef:t,inputRef:a},e),{focusProps:l,isFocused:p,isFocusVisible:c}=useFocusRing(),{hoverProps:u,isHovered:m}=useHover({isDisabled:o}),d=filterTruthyValues({"data-disabled":o,"data-readonly":r,"data-hovered":m,"data-focus-visible":c,"data-dragging":s,"data-focused":p});return jsxs(Fragment,{children:[jsx("div",{className:classNames(Xp({isDisabled:o,isFocusVisible:c,active:s,isHovered:m}),"BaselineUI-Slider-TrackHighlight"),style:{width:n.style?.left},"data-testid":"track-highlight"}),jsxs("div",{...mergeProps(n,u,d),className:classNames(Wp,"BaselineUI-Slider-ThumbHandle"),"data-testid":"thumb",children:[jsx("div",{className:classNames(Gp({isDisabled:o,isFocusVisible:c,active:s,isReadOnly:r,isHovered:m}),"BaselineUI-Slider-Thumb")}),jsx(VisuallyHidden,{children:jsx("input",{ref:a,...mergeProps(i,l)})})]})]})}var Dc=z({defaultClassName:"_1tkzayn0 _1yep5z6dy",variantClassNames:{size:{sm:"_1tkzayn1",md:"_1tkzayn2",lg:"_1tkzayn3"},type:{subtitle:"_1yep5z610x",title:"_1yep5z610x",label:"_1yep5z610y",value:"_1yep5z610y",helper:"_1yep5z610z",body:"_1yep5z610x"}},defaultVariants:{},compoundVariants:[[{type:"title",size:"sm"},"_1yep5z61lj"],[{type:"title",size:"md"},"_1yep5z61lm"],[{type:"title",size:"lg"},"_1yep5z61lp"],[{type:"body",size:"sm"},"_1yep5z61m9"],[{type:"body",size:"md"},"_1yep5z61mc"],[{type:"body",size:"lg"},"_1yep5z61mc"],[{type:"subtitle",size:"sm"},"_1yep5z61m5"],[{type:"subtitle",size:"md"},"_1yep5z61m8"],[{type:"subtitle",size:"lg"},"_1yep5z61m8"],[{type:"label",size:"md"},"_1yep5z61m7"],[{type:"label",size:"lg"},"_1yep5z61m7"],[{type:"value",size:"md"},"_1yep5z61m7"],[{type:"value",size:"lg"},"_1yep5z61m7"],[{type:"helper",size:"sm"},"_1yep5z61m1"]]});var te=ht.forwardRef(({elementType:e="span",type:t="title",children:o,size:r="md",...a},n)=>jsx(e,{...a,className:classNames(Dc({size:r,type:t}),"BaselineUI-Text",a.className),ref:n,children:o}));te.displayName="Text";var Mc=z({defaultClassName:"siobe20 _1yep5z6ao _1yep5z6ap _1yep5z6aq _1yep5z6bc _1yep5z6bd _1yep5z6be _1yep5z6d7 _1yep5z6m1 _1yep5z6lz _1yep5z6h4 _1yep5z6lq _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6",variantClassNames:{background:{subtle:"_1yep5z6124",medium:"_1yep5z6125"},isFocusVisible:{true:"_1yep5z617u _1yep5z617w _1yep5z617x _1yep5z6140"}},defaultVariants:{},compoundVariants:[]}),Nc="siobe24";var va=ht.forwardRef(({className:e,style:t,children:o,background:r="medium",title:a,action:n,"data-block-id":i,"data-block-class":s,onCloseRequest:l,contentStyle:p,contentClassName:c,...u},m)=>{let{formatMessage:d}=A(),b=ht.useRef(null),{dialogProps:f,titleProps:y}=useDialog(u,b),{focusProps:g,isFocusVisible:v}=useFocusRing();return jsxs("div",{...mergeProps(f,g),className:classNames(Mc({background:r,isFocusVisible:v}),"BaselineUI-Drawer",e),"data-block-id":i,"data-block-class":s,style:t,ref:M(m,b),children:[jsxs(S,{paddingLeft:"lg",paddingRight:"sm",backgroundColor:"background.primary.subtle",display:"flex",justifyContent:"space-between",alignItems:"center",gap:"lg",className:Nc,children:[jsx(te,{type:"title",size:"sm",...y,className:xc,children:a}),jsxs(S,{children:[n?jsx(L,{...n,variant:"secondary"}):null,jsx(L,{variant:"secondary",size:"md",icon:XIcon,onPress:l,"aria-label":d(dz.close)})]})]}),jsx(U,{variant:r==="subtle"?"primary":"secondary"}),jsx(S,{display:"flex",flexDirection:"column",flex:1,style:{overflow:"auto",...p},className:classNames(c,"BaselineUI-Drawer-Content"),children:o})]})});va.displayName="Drawer";var dz=G({close:{id:"close",defaultMessage:"Close"}});var Bc="aml2vl8 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6ij _1yep5z6ik _1yep5z6il",Ac="_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Fc=z({defaultClassName:"aml2vl3 _1yep5z6lg _1yep5z6lh _1yep5z6lj _1yep5z6li _1yep5z6is _1yep5z6it _1yep5z6iu",variantClassNames:{enableDrawer:{false:"_1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf",true:"aml2vl5"},shouldContainOverlays:{true:"aml2vl6",false:"aml2vl7"}},defaultVariants:{},compoundVariants:[]}),jc=z({defaultClassName:"aml2vl0 _1yep5z6lg _1yep5z6lh _1yep5z6lj _1yep5z6li _1yep5z6gb",variantClassNames:{shouldContainOverlays:{true:"aml2vl1",false:"aml2vl2"}},defaultVariants:{},compoundVariants:[]});var Pt=ht.createContext({state:null,triggerProps:{},overlayProps:{}}),Ee=({children:e,...t})=>{let o=useOverlayTriggerState(t),{triggerProps:r,overlayProps:a}=useOverlayTrigger({type:"dialog"},o),n=useMemo(()=>({state:o,triggerProps:r,overlayProps:a}),[o,r,a]);return jsx(Pt.Provider,{value:n,children:e})};Ee.displayName="Modal";function Kc(e,t,o){let[r,a]=useState({}),n=useRef(false),[i,s]=useState(null),{container:l,shouldContainOverlays:p,isContainerPositioned:c,containerHeight:u,portalContainer:m}=useContext(He);useEffect(()=>{if(!e||!o)return;let y=re(e),g=y.visualViewport,v=()=>{let _=g?.height,h=y.innerHeight-(_||0);if(n.current=h>60,n.current){let x=getActiveElement(e);x&&isInputThatOpensKeyboard(x)&&x.scrollIntoView({behavior:"smooth",block:"center"});}if(t)a({maxHeight:(_||0)*.8,bottom:h});else {let x=`${_||0}px`,R=p?`min(${x}, ${u?u+"px":x})`:x;a({maxHeight:`calc(${R} - (2 * ${themeVars.spacing.xl} + env(safe-area-inset-top) + env(safe-area-inset-bottom)))`,top:n.current?`calc(env(safe-area-inset-top) + ${themeVars.spacing.xl})`:void 0});}};return v(),g?.addEventListener("resize",v),y.addEventListener("resize",v),()=>{g?.removeEventListener("resize",v),y.removeEventListener("resize",v);}},[e,t,p,o,u]);let d=m&&!l?.contains(m);useEffect(()=>{if(!l||!p||c&&!d)return;let y=()=>{l&&s(getAbsoluteBounds(l));};y();let g=new ResizeObserver(()=>{y();});return g.observe(l),()=>{g.disconnect();}},[l,p,c,d]);let b=useMemo(()=>({...r,overflow:"auto",position:"relative"}),[r]),f=useMemo(()=>{if(!t&&n.current)return {alignItems:"flex-start"};if(p&&(!c||d)){let y=i||(l?getAbsoluteBounds(l):{x:0,y:0,height:0,width:0});return {position:"absolute",left:y.x,top:y.y,height:y.height,width:y.width}}return {}},[t,n.current,l,c,p,i,d]);return {dialogStyle:b,containerStyle:f}}var Di=ht.createContext({isDrawer:false,closeDrawer:()=>{},dialogStyle:{},setDialogElement:()=>{},isWithinModal:false}),Mi=ht.createContext({setIsPopoverSafelyClosed:()=>{}}),Ue=({children:e,className:t,style:o,isDismissable:r=true,isKeyboardDismissDisabled:a=false,portalContainer:n,disableAnimation:i,enableDrawer:s=false,"data-block-id":l,"data-block-class":p,shouldCloseOnInteractOutside:c,shouldAnimateOnMount:u=true})=>{let{state:m}=ht.useContext(Pt),[d,b]=ht.useState(true),f=ht.useRef(null),[y,g]=ht.useState(null),{shouldHandleVirtualKeyboard:v}=useContext(Jt),{shouldContainOverlays:_,container:h,portalContainer:x}=useContext(He),R=Ne(),P=typeof s=="boolean"&&s||s==="auto"&&R==="mobile";invariant(m,"ModalContent must be a child of Modal");let w=ht.useRef(null),C=typeof r=="function"?r(P):r,D=typeof a=="function"?a(P):a,{modalProps:k,underlayProps:T}=useModalOverlay({isDismissable:d&&C,shouldCloseOnInteractOutside:V=>{let Q=n||x;return !h?.contains(V)&&_&&!Q?.contains(V)?false:c?.(V)??true},isKeyboardDismissDisabled:D},m,w),{dialogStyle:$,containerStyle:I}=Kc(y,P,v),N=useMemo(()=>({isDrawer:P,closeDrawer:m.close,dialogStyle:$,dialogRef:f,setDialogElement:g,isWithinModal:true}),[P,m.close,$,f,g]),E=useMemo(()=>({setIsPopoverSafelyClosed:b}),[b]),j={duration:.3,type:"tween",ease:"easeOut"},B={type:"spring",duration:.3},O={open:{opacity:1,transform:P?"translateY(0%)":"scale(1)"},closed:i?{opacity:1,transform:P?"translateY(0%)":"scale(1)"}:{opacity:0,transform:P?"translateY(100%)":"scale(0.95)"}};return jsx(AnimatePresence,{initial:u&&!i,children:m.isOpen?jsx(Di.Provider,{value:N,children:jsx(Mi.Provider,{value:E,children:jsxs(he,{className:classNames(Fc({enableDrawer:P,shouldContainOverlays:_}),t),"data-block-id":l,"data-block-class":p,style:{...o,...I},portalContainer:n,children:[jsx(motion.div,{...T,variants:{open:{opacity:1},closed:{opacity:i?1:0}},initial:"closed",animate:"open",exit:"closed","data-testid":"underlay",transition:j,className:classNames(jc({shouldContainOverlays:_}),"BaselineUI-Modal-Underlay")}),jsx(motion.div,{...k,ref:w,"data-drawer":P,className:classNames(P?Bc:Ac,"BaselineUI-Modal-Content"),variants:O,transition:P?j:B,initial:"closed",animate:"open",exit:"closed",children:typeof e=="function"?e(m):e})]})})}):null})};var Xc="var(--cjv3et0)",Zc=z({defaultClassName:"cjv3et1 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6g1 _1yep5z6lz _1yep5z6m1",variantClassNames:{size:{sm:"cjv3et2",md:"cjv3et3",lg:"cjv3et4",content:"cjv3et5"},variant:{primary:"_1yep5z6137",ghost:"cjv3et7"},overlayType:{modal:"cjv3et8",popover:"cjv3et9"},isDrawer:{true:"cjv3eta _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8 _1yep5z617q"},isFocusVisible:{true:"_1yep5z61q3 _1yep5z61tx _1yep5z61tz _1yep5z61u1"}},defaultVariants:{},compoundVariants:[]});var Ei=ht.createContext({titleProps:{}}),xe=ht.forwardRef(({children:e,className:t,style:o,inheritDrawer:r,size:a="md",variant:n="primary","data-block-id":i,"data-block-class":s,drawerBackground:l,...p},c)=>{let u=ht.useRef(null),m=ht.useRef(null),{containerWidth:d,shouldContainOverlays:b}=useContext(He),{isDrawer:f,closeDrawer:y,dialogStyle:g,setDialogElement:v,isWithinModal:_}=useContext(Di),[h,x]=ht.useState(""),{focusProps:R,isFocusVisible:P}=useFocusRing();useLayoutEffect(()=>{let k=m.current?.getRootNode(),T=p["aria-label"]||"";p["aria-labelledby"]&&(T=k?.querySelector(`#${p["aria-labelledby"].replaceAll(":",String.raw`\:`)}`)?.textContent||""),x(T);},[p]);let{dialogProps:w,titleProps:C}=useDialog(p,u),D=useMemo(()=>({titleProps:C}),[C]);return f&&r?jsx(va,{title:h,onCloseRequest:y,className:t,style:g,...p,"data-drawer":true,"data-block-id":i,"data-block-class":s,ref:M(m,c,k=>{v(k);}),background:l,children:e}):jsx(Ei.Provider,{value:D,children:jsx("section",{...mergeProps(w,R),"data-block-id":i,"data-block-class":s,"data-focus-visible":P,"data-overlay-type":_?"modal":"popover",ref:M(u,c,k=>{v(k);}),style:{...g,...o,...assignInlineVars({[Xc]:d&&b?`${d}px`:"100vw"})},className:classNames(Zc({size:f?"content":a,variant:n,isDrawer:f,isFocusVisible:P,overlayType:_?"modal":"popover"}),"BaselineUI-Dialog",t),children:e})})});xe.displayName="Dialog";var Qc=ht.forwardRef(({children:e,className:t,style:o},r)=>{let{titleProps:a}=useContext(Ei);return ht.isValidElement(e)?ht.cloneElement(e,{...a,ref:r,className:classNames(e.props.className,t),style:{...e.props.style,...o}}):jsx("h3",{...a,ref:r,className:t,style:o,children:e})});Qc.displayName="DialogTitle";var td=({children:e,isOpen:t,popoverContentRef:o,portalContainer:r=document.body,style:a})=>{let[n,i]=useState(false),[s,l]=useState(null),p=useRef(null),{setIsPopoverSafelyClosed:c}=useContext(Mi);useEffect(()=>{t?(i(true),p.current&&clearTimeout(p.current)):p.current=setTimeout(()=>{i(false);},300);},[t]),useEffect(()=>()=>{p.current&&clearTimeout(p.current);},[]);let u=o.current;return useEffect(()=>{u&&l(u.getBoundingClientRect());},[u]),useEffect(()=>{c(!n);},[n,c]),jsxs(Fragment,{children:[n?Bz.createPortal(jsx("div",{style:{position:"absolute",left:a?.left,top:a?.top,width:s?.width,height:s?.height,zIndex:a?.zIndex?+a.zIndex-1:void 0},className:"BaselineUI-Popover-ClickPreventionLayer"}),r):null,e]})};var{color:oo}=themeVars,ke=ht.forwardRef(({portalClassName:e,portalStyle:t,className:o,style:r,state:a,overlayProps:n,underlayClassName:i,children:s,includeArrow:l=false,offset:p=2,portalContainer:c,contentContainerClassName:u,contentContainerStyle:m,"data-block-id":d,"data-block-class":b,...f},y)=>{let g=ht.useRef(null),v=ze(c),_=l?8:0,{underlayProps:h,popoverProps:x,placement:R,arrowProps:P}=usePopover({...f,offset:p+_,popoverRef:g,containerPadding:f.containerPadding||0},a);delete x.style?.position;let w=R==="center"?"bottom":R,C=useMemo(()=>({isOpen:a.isOpen}),[a.isOpen]),{transitionProps:D}=aa({placement:R}),k=useMemo(()=>({...x.style,...assignInlineVars({[Lp]:`${f.triggerRef?.current?.offsetWidth}px`}),...ui(r,C)}),[x.style,f.triggerRef,r,C]);return jsx(td,{isOpen:a.isOpen,popoverContentRef:g,portalContainer:v,style:x.style,children:a.isOpen?jsxs(he,{portalContainer:v,style:t,className:e,ref:y,"data-block-id":d,"data-block-class":b,children:[!f.isNonModal&&jsx("div",{...h,className:classNames(Ep,qr(i,C),"BaselineUI-Popover-Underlay")}),jsxs(motion.div,{...mergeProps(x,D),style:k,ref:M(g,y),className:classNames(Dp,"BaselineUI-Popover-ContentContainer",qr(o,C)),"data-placement":["top","bottom","left","right"].filter(T=>R?.includes(T)),children:[l?jsxs(Fragment,{children:[jsxs("svg",{className:classNames(Tp({placement:w}),"BaselineUI-PopoverContent-Arrow"),...P,style:{...P.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:oo.border.medium}),jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:oo.background.primary.subtle,stroke:oo.background.primary.subtle})]}),jsxs("svg",{className:classNames(Sp({placement:w}),"BaselineUI-PopoverContent-Arrow-Focused"),width:"15",height:"11",viewBox:"0 0 15 11",fill:"none",xmlns:"http://www.w3.org/2000/svg",...P,style:{...P.style,position:"absolute"},children:[jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M0.543371 2H0V0H1.45663L7.5 6.97312L13.5434 0H15V2H14.4566L7.5 10.0269L0.543371 2Z",fill:oo.border.interactive.enabled}),jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:oo.background.primary.subtle,stroke:oo.background.primary.subtle})]})]}):null,jsx(DismissButton,{onDismiss:a.close}),jsx("div",{...n,style:ui(m,C),className:classNames(Mp,qr(u,C),"BaselineUI-Popover-Content"),children:typeof s=="function"?s(a):s}),jsx(DismissButton,{onDismiss:a.close})]})]}):null})});ke.displayName="PopoverContentCore";var Le=ht.forwardRef((e,t)=>{let{state:o,overlayTriggerAria:{overlayProps:r},triggerRef:a}=useContext(Vo);return invariant(a),o?jsx(ke,{ref:t,...e,triggerRef:e.triggerRef||a,overlayProps:r,state:o}):null});Le.displayName="PopoverContent";var ro=({icon:e,tooltip:t,label:o,...r})=>{let{tooltipProps:a}=ve({label:o,tooltip:t,offset:9});return jsx(J,{...a,children:({triggerProps:n,triggerRef:i})=>jsx(S,{display:"inline-flex",...n,ref:i,children:jsx(e,{...r})})})};var sd=ht.forwardRef(({className:e,style:t,onChange:o,"data-block-id":r,icon:a,formatValue:n=m=>m,tooltip:i=true,iconTooltip:s=true,popoverContentProps:l,isDisabled:p,...c},u)=>{let m=ae(u),[d,b]=useControlledState(c.value,c.defaultValue||0,o),[f,y]=ht.useState(false),{keyboardProps:g}=useKeyboard({onKeyDown:x=>{(x.key==="Enter"||x.key==="Escape")&&y(false);}}),{tooltipProps:v}=ve({label:c["aria-label"],tooltip:i}),_=n(d||0),h=v?.isDisabled||c["aria-label"]?`${c["aria-label"]}, ${_}`:_.toString();return jsxs(S,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:classNames("BaselineUI-IconSlider",e),"data-block-id":r,style:t,ref:m,children:[a?jsx(ro,{icon:a,label:c["aria-label"],tooltip:s,"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary"})}):null,jsxs(je,{type:"dialog",isOpen:f,onOpenChange:y,children:[jsx(Oe,{children:jsx(J,{...v,children:jsx(q,{label:_,variant:"popover","aria-label":h,isDisabled:p,style:{fontVariantNumeric:"tabular-nums",minWidth:68,justifyContent:"space-between"}})})}),jsx(Le,{placement:"bottom start",...l,children:jsx(xe,{size:"content","aria-label":h,children:jsx(FocusScope,{autoFocus:true,children:jsx(S,{paddingY:"sm",paddingX:"lg",marginY:"md",style:{width:215},...g,children:jsx(to,{...c,onChange:x=>{b(x),o?.(x);},value:d})})})})})]})]})});sd.displayName="IconSlider";var ld=z({defaultClassName:"bpklwa7",variantClassNames:{isReadOnly:{true:"bpklwa8"},isDisabled:{true:"bpklwa9"},isSelected:{true:"bpklwaa"},isFocused:{true:"bpklwab"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:false,isReadOnly:false},"bpklwac"]]}),pd=z({defaultClassName:"bpklwae",variantClassNames:{isDisabled:{true:"bpklwaf"},isSelected:{true:"bpklwag"},isReadOnly:{true:"bpklwah"}},defaultVariants:{},compoundVariants:[]}),cd="bpklwad",dd=z({defaultClassName:"bpklwa0",variantClassNames:{labelPosition:{top:"bpklwa1",left:"bpklwa2"}},defaultVariants:{},compoundVariants:[]}),ud="bpklwa6",md=z({defaultClassName:"bpklwa3",variantClassNames:{labelPosition:{top:"bpklwa4",left:"bpklwa5"}},defaultVariants:{},compoundVariants:[]});var gd=ht.forwardRef(({className:e,label:t,labelPosition:o="top",statusLabel:r,style:a,"data-block-id":n,"data-block-class":i,...s},l)=>{let p=ht.useRef(null),c=useToggleState(s),{inputProps:u,isPressed:m}=useSwitch({...s,children:t},c,p),{isFocusVisible:d,focusProps:b}=useFocusRing(),{hoverProps:f,isHovered:y}=useHover({isDisabled:s.isDisabled}),g=filterTruthyValues({"data-block-id":n,"data-block-class":i,"data-focused":d,"data-disabled":s.isDisabled,"data-focus-visible":d,"data-selected":c.isSelected,"data-readonly":s.isReadOnly,"data-hovered":y,"data-pressed":m}),v=jsx("div",{className:classNames(ld({isSelected:c.isSelected,isDisabled:!!s.isDisabled,isFocused:d,isReadOnly:!!s.isReadOnly}),"BaselineUI-Switch-Track"),children:jsx("div",{className:classNames(pd({isSelected:c.isSelected,isDisabled:s.isDisabled,isReadOnly:s.isReadOnly}),"BaselineUI-Switch-Knob"),"data-testid":"switch-knob"})});return jsxs("label",{...mergeProps(g,f),className:classNames(dd({labelPosition:o}),"BaselineUI-Switch",e),style:a,ref:l,children:[t?jsx("span",{className:classNames(cd,"BaselineUI-Switch-Label"),children:t}):null,jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(u,b),ref:p})}),r?jsxs("div",{className:md({labelPosition:o}),children:[jsx("span",{className:classNames("BaselineUI-Switch-Status-Label",ud),children:c.isSelected?r.on:r.off}),v]}):v]})});gd.displayName="Switch";var vd="_19n40yy9",_d=z({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 gh={sm:SearchIcon$1,md:SearchIcon,lg:SearchIcon},xd=ht.forwardRef(({className:e,size:t="md",variant:o="primary","data-block-id":r,"data-block-class":a,style:n,...i},s)=>{let l=ht.useRef(null),p=useSearchFieldState(i),{inputProps:c,clearButtonProps:u}=useSearchField({...i,"aria-haspopup":false,"aria-autocomplete":"none",type:"search"},p,l),{focusProps:m,isFocusVisible:d,isFocused:b}=useFocusRing({within:true,isTextInput:true}),f=gh[t],y=t==="sm"?XIcon$1:XIcon$2,g=filterTruthyValues({"data-block-id":r,"data-block-class":a,"data-focused":b,"data-disabled":i.isDisabled,"data-focus-visible":d});return jsxs("div",{...g,className:classNames(_d({size:t,isFocused:b,variant:o,hasText:!!p.value,isDisabled:i.isDisabled}),"BaselineUI-SearchInput",e),style:n,ref:s,children:[jsx(f,{size:t==="sm"?20:24}),jsx("input",{...mergeProps(c,m),className:vd,ref:l}),p.value!==""&&jsx(L,{icon:y,...u,size:t==="sm"?"xs":"sm",variant:"secondary"})]})});xd.displayName="SearchInput";var Cd="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 _1yep5z6ls _1yep5z6lr _1yep5z6i0 _1yep5z6lv _1yep5z6g1",Pd="xyd2ss0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b";var Fi=({section:e,showSelectedIcon:t,state:o})=>{let{itemProps:r,groupProps:a,headingProps:n}=useMenuSection({heading:e.value?.title,"aria-label":e["aria-label"]});return jsxs(Fragment,{children:[e.key!==o.collection.getFirstKey()&&jsx(U,{elementType:"li"}),jsxs("li",{...r,children:[e.value?.title?jsx(VisuallyHidden,{children:jsx("span",{...n,children:e.value.title})}):null,jsx("ul",{...a,className:Pd,children:[...e.childNodes].map(i=>(invariant(i.type==="item"),jsx(za,{item:i,state:o,showSelectedIcon:t},i.key)))})]})]})};Fi.displayName="MenuSection";var za=({item:e,state:t,className:o,showSelectedIcon:r})=>{let a=ht.useRef(null),n=useMenuItem({key:e.key},t,a),{isFocusVisible:i,focusProps:s}=useFocusRing();return jsx(Oo,{item:e,liProps:mergeProps(n.menuItemProps,s,{className:o}),...n,isFocusVisible:i,ref:a,description:e.value?.keyboardShortcut,descriptionProps:n.keyboardShortcutProps,_state:t,showSelectedIcon:r})};za.displayName="MenuItem";var Oi=ht.forwardRef(({className:e,itemClassName:t,onContentKeyDown:o,...r},a)=>{let n=useTreeState(r),i=ht.useRef(null),{menuProps:s}=useMenu(r,n,i),{keyboardProps:l}=useKeyboard({onKeyDown:o});return jsx("ul",{...mergeProps(s,l),className:classNames(Cd,e),ref:M(i,a),children:[...n.collection].map(p=>p.type==="section"?jsx(Fi,{section:p,state:n,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},p.key):jsx(za,{item:p,state:n,className:t,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},p.key))})});Oi.displayName="MenuContent";var Id=z({defaultClassName:"_1mdhlqv8",variantClassNames:{isOpen:{true:"_1mdhlqv9"}},defaultVariants:{},compoundVariants:[]}),at="_1mdhlqvb cjv3et1 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6g1 _1yep5z6lz _1yep5z6m1 _1yep5z6137 cjv3et5",Rd=z({defaultClassName:"_1mdhlqv0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6dy",variantClassNames:{isFocused:{false:"_1mdhlqv1"},isOpen:{true:"_1mdhlqv2"},isDisabled:{true:"z9nup82 _1yep5z6ey"},isHovered:{true:"_1mdhlqv4"},variant:{primary:"_1mdhlqv5",ghost:"_1mdhlqv6"},isReadOnly:{true:"_1mdhlqv7"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isHovered:true,isReadOnly:false,isDisabled:false},"_1yep5z6h5"],[{isHovered:true,isReadOnly:false,isDisabled:false},"_1yep5z6la"]]}),$d="_1yep5z66x _1yep5z66y _1yep5z66z",Td="_1mdhlqva _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k";var ha=ht.forwardRef(({defaultOpen:e,onOpenChange:t,isOpen:o,isDisabled:r,contentClassName:a,placement:n="bottom start",isNonModal:i,shouldFlip:s,shouldUpdatePosition:l,boundaryElement:p,crossOffset:c,offset:u,triggerLabel:m,renderTrigger:d=({buttonProps:g,ref:v})=>jsx(q,{...g,variant:"popover",ref:v}),portalContainer:b,...f},y)=>{let g=ht.useRef(null),v=ze(b),_=useMenuTriggerState({defaultOpen:e,isOpen:o,onOpenChange:t}),{menuTriggerProps:h,menuProps:x}=useMenuTrigger({isDisabled:r,type:"menu"},_,g),R=pe(),P=useMemo(()=>mergeProps(h,{isDisabled:r,isSelected:_.isOpen,className:"BaselineUI-Menu-Trigger",label:typeof m=="function"?m(_.isOpen):m}),[h,r,_.isOpen,m]);return useEffect(()=>{!m&&!d&&console.warn("The `triggerLabel` prop is required when no `renderTrigger` or `children` is provided.");},[d,m]),jsxs(Fragment,{children:[d({buttonProps:P,ref:g}),jsx(ke,{triggerRef:g,state:_,placement:n,isNonModal:i,shouldFlip:s,shouldUpdatePosition:l,boundaryElement:p,crossOffset:c,offset:u||2,className:"BaselineUI-Menu-Popover",portalContainer:v,children:jsx(Oi,{className:classNames(at,a),...x,...f,ref:y,autoFocus:_.focusStrategy||"first",children:R})})]})});ha.displayName="Menu";var xa=z({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:true,isDisabled:false},"_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 Md=ht.forwardRef(({className:e,style:t,children:o,variant:r="default",size:a="md",elementType:n="a",type:i="body","data-block-id":s,"data-block-class":l,title:p,role:c,...u},m)=>{let d=ht.useRef(null),{linkProps:b,isPressed:f}=useLink({...u,elementType:u.onPress?"span":n},d),{isFocusVisible:y,isFocused:g,focusProps:v}=useFocusRing(),{hoverProps:_,isHovered:h}=useHover({isDisabled:u.isDisabled}),x=n,R=filterTruthyValues({"data-block-id":s,"data-block-class":l,"data-disabled":u.isDisabled,"data-focused":g,"data-pressed":f,"data-focus-visible":y,"data-hovered":h,role:c,title:p});return jsx(x,{...mergeProps(b,v,_,R),className:classNames(xa({variant:r,isFocusVisible:y,isHovered:h,isDisabled:u.isDisabled,size:a,isActive:f,type:i}),"BaselineUI-Link",e),ref:M(d,m),style:t,children:o})});Md.displayName="Link";function Nd({isDisabled:e,onValueChange:t,onChange:o,name:r,"aria-describedby":a,"aria-label":n,accept:i,multiple:s}){let l=useId(),p=useId(),c=useId();return {inputProps:{type:"file",id:p,disabled:!!e,"aria-labelledby":n?void 0:l,"aria-describedby":a||c,"aria-label":n,onChange:m=>{let d=[...m.target.files||[]];t?.(d),o?.(m);},name:r,accept:i,multiple:s},labelProps:{htmlFor:p,id:l},descriptionProps:{id:c}}}async function Ui({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 Ed=z({defaultClassName:"_180w5ed0",variantClassNames:{variant:{default:"_180w5ed1",inline:"_180w5ed2"},hoveredOrFocusedOrActive:{true:"_180w5ed3"},disabled:{true:"_180w5ed4"}},defaultVariants:{},compoundVariants:[[{variant:"inline",hoveredOrFocusedOrActive:true},"_180w5ed5"],[{variant:"default",hoveredOrFocusedOrActive:true},"_180w5ed6"],[{variant:"default",disabled:true},"_180w5ed7"],[{variant:"inline",disabled:true},"_180w5ed8"]]}),Ld=z({defaultClassName:"_180w5ede",variantClassNames:{disabled:{true:"_180w5edf"}},defaultVariants:{},compoundVariants:[]}),Bd=z({defaultClassName:"_180w5ed9",variantClassNames:{disabled:{true:"_180w5eda"}},defaultVariants:{},compoundVariants:[]}),Ad=z({defaultClassName:"_180w5edb",variantClassNames:{disabled:{true:"_180w5edc"},hovered:{true:"_180w5edd"}},defaultVariants:{},compoundVariants:[]});var Hd=ht.forwardRef(({className:e,label:t,description:o,icon:r,variant:a="default",...n},i)=>{let s=ht.useRef(null),{inputProps:l,descriptionProps:p,labelProps:c}=Nd(n),{dropProps:u}=useDrop({ref:s,onDrop:async({items:y})=>{let g=y.filter(_=>_.kind==="file").map(async _=>(invariant(_.kind==="file"),_.getFile())),v=await Promise.all(g);n.onValueChange?.(v);}}),{focusProps:m,isFocusVisible:d}=useFocusRing(),{hoverProps:b,isHovered:f}=useHover({isDisabled:n.isDisabled});return jsxs("label",{...mergeProps(u,b,c),className:classNames(Ed({variant:a,disabled:n.isDisabled,hoveredOrFocusedOrActive:f||d}),e),ref:M(i,s),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(m,l)})}),r?jsx(r,{size:20,className:Bd({disabled:n.isDisabled})}):null,jsxs("div",{children:[jsx("div",{className:Ad({disabled:n.isDisabled,hovered:f}),children:t}),o?jsx("div",{...p,className:Ld({disabled:n.isDisabled}),children:o}):null]})]})});Hd.displayName="FileUpload";var Vd="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z6ln",Ud="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kj _1yep5z6kk _1yep5z6kl",qd=z({defaultClassName:"_12vfhl44",variantClassNames:{variant:{success:"_1yep5z611s",error:"_1yep5z611o",active:"_1yep5z6120"}},defaultVariants:{},compoundVariants:[]}),Kd="_1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6ev _1yep5z6dy",Gd="_12vfhl43 _1yep5z6g3 _1yep5z6ln",Wd="_12vfhl42 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k",Yd="_1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k",Xd=z({defaultClassName:"_12vfhl40 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6dy _1yep5z6eu",variantClassNames:{hasLabel:{false:"_1yep5z6pi _1yep5z6pj _1yep5z6pk"}},defaultVariants:{},compoundVariants:[]});var Zd=ht.forwardRef(({className:e,style:t,variant:o="active",showValue:r,description:a,errorMessage:n,"data-block-id":i,"data-block-class":s,...l},p)=>{let c=useId(),{labelProps:u,progressBarProps:m}=useProgressBar({...l,"aria-describedby":a?c:l["aria-describedby"]}),{minValue:d=0,maxValue:b=100,value:f=0,label:y}=l,g=(f-d)/(b-d),v=`${Math.round(g*100)}%`,_=jsx("output",{className:Xd({hasLabel:!!y}),children:m["aria-valuetext"]}),h=o==="error"?n:a;return jsxs("div",{...m,style:t,className:classNames(Vd,"BaselineUI-ProgressBar",e),"data-block-id":i,"data-block-class":s,ref:p,children:[y?jsxs("div",{className:Ud,children:[jsx("label",{...u,className:Kd,children:y}),r?_:null]}):null,jsxs("div",{className:Yd,children:[jsxs("div",{className:Wd,children:[jsx("div",{className:Gd,children:jsx("div",{style:{width:v},className:qd({variant:o})})}),!y&&r?_:null]}),h?jsx("div",{className:Kt({hasError:o==="error"}),id:c,children:h}):null]})]})});Zd.displayName="ProgressBar";function io({isReadOnly:e,validationState:t}){return e?ReadOnlyIcon:t==="error"?ErrorCircleFilledIcon:t==="warning"?WarningFilledIcon$1:null}var wt=ht.forwardRef(({labelPosition:e="top",className:t,style:o,labelProps:r,isDisabled:a=false,isReadOnly:n=false,label:i,message:s,"data-block-id":l,validationState:p="valid",isFocused:c=false,variant:u="primary",children:m,fieldProps:d,wrapperRef:b,wrapperClassName:f,isInvalid:y},g)=>{let{hoverProps:v,isHovered:_}=useHover({isDisabled:a}),h=io({isReadOnly:n,validationState:p});return jsxs("div",{className:classNames(ot({labelPosition:e}),t),"data-block-id":l,style:o,ref:g,children:[i||e==="start"&&s?jsxs("div",{className:tt({labelPosition:e,hasMessage:!!s}),children:[jsx(S,{...r,elementType:"label",color:"text.secondary",typography:"label.md.medium",children:i}),e==="start"&&s]}):null,jsxs("div",{className:classNames({[Zt]:a}),children:[jsxs("div",{...mergeProps(d,v),className:classNames(Yt({validationState:y?"error":p,isHovered:_,isFocused:c,variant:u,isReadOnly:n,isDisabled:a}),f),ref:b,children:[m,h?jsx(h,{className:Gt({validationState:p,isReadOnly:n}),size:16}):null]}),e==="top"&&s]})]})});wt.displayName="SharedInput";var nt=ht.forwardRef(({className:e,validationState:t,variant:o="primary",labelPosition:r="top",inputStyle:a,inputClassName:n,"data-block-id":i,"data-block-class":s,...l},p)=>{let c=ht.useRef(null),{inputProps:u,labelProps:m,descriptionProps:d,errorMessageProps:b,validationErrors:f}=useTextField({...l,validationState:t?t==="error"?"invalid":"valid":void 0},c),y=l.errorMessage||f.join(" "),g=_e({...l,errorMessage:y,descriptionProps:d,errorMessageProps:b,labelPosition:r});y&&(t="error");let{isFocused:v,focusProps:_,isFocusVisible:h}=useFocusRing(),x=filterTruthyValues({"data-readonly":l.isReadOnly,"data-disabled":l.isDisabled,"data-validation-state":t,"data-focused":v,"data-focus-visible":h});return jsx(wt,{variant:o,labelProps:m,isFocused:v,message:g,ref:p,labelPosition:r,className:classNames("BaselineUI-TextInput",e),validationState:t,"data-block-id":i,"data-block-class":s,...l,children:jsx("input",{...mergeProps(u,_,x),className:classNames(ra({isDisabled:l.isDisabled,labelPosition:r}),"BaselineUI-TextInput-Input",n),style:a,ref:c})})});nt.displayName="TextInput";var so=({value:e,...t})=>{let o=useNumberFormatter(t);return jsx(Fragment,{children:o.format(e)})};so.displayName="NumberFormat";var ou="_1yep5z6iv _1yep5z6iw _1yep5z6ix",ru=z({defaultClassName:"_9b1tml0",variantClassNames:{isSelected:{true:"_9b1tml1",false:"_9b1tml2"},isDisabled:{true:"z9nup82"},isHovered:{true:"_9b1tml4"},isFocusVisible:{true:"_9b1tml5"},isReadOnly:{true:"_9b1tml6"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isFocusVisible:true,isReadOnly:false},"_9b1tml7"],[{isSelected:true,isHovered:true,isDisabled:false,isReadOnly:false},"_9b1tml8"],[{isSelected:false,isHovered:true,isDisabled:false,isReadOnly:false},"_9b1tml9"],[{isSelected:true,isDisabled:true},"_9b1tmla"],[{isSelected:true,isReadOnly:true},"_9b1tmlb"]]}),au=z({defaultClassName:"_9b1tmlf _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6eu _1yep5z6la _1yep5z6e9",variantClassNames:{isSelected:{true:"_9b1tmlg"},size:{sm:"_9b1tmlh",md:"_9b1tmli"},isDisabled:{true:"_9b1tmlj"},isReadOnly:{true:"_1yep5z610x"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:false,isReadOnly:false},"_1yep5z61n6"],[{isSelected:true,isDisabled:true},"_1yep5z61n6"],[{isSelected:false,isDisabled:true},"_1yep5z61n4"]]}),nu=z({defaultClassName:"_9b1tmlc",variantClassNames:{isDisabled:{true:"_9b1tmld"},isReadOnly:{true:"_9b1tmle"}},defaultVariants:{},compoundVariants:[]});var lu=ht.forwardRef(({className:e,count:t,style:o,size:r="md",icon:a,"data-block-id":n,"data-block-class":i,...s},l)=>{let p={isRequired:false},c=a||(r==="md"?CheckmarkIcon$1:CheckmarkIcon$2);!s["aria-label"]&&!s["aria-labelledby"]&&console.warn("You must provide either an `aria-label` or `aria-labelledby` prop to the `Reaction` component.");let u=ht.useRef(null),m=useToggleState({...s,...p}),{inputProps:d,isPressed:b,isDisabled:f,isReadOnly:y,isSelected:g}=useSwitch({...s,...p},m,u),{focusProps:v,isFocused:_,isFocusVisible:h}=useFocusRing(),{hoverProps:x,isHovered:R}=useHover({}),P=filterTruthyValues({"data-block-id":n,"data-block-class":i,"data-focused":_,"data-focus-visible":h,"data-disabled":f,"data-hovered":R,"data-pressed":b,"data-selected":g});return jsxs("label",{ref:l,style:o,className:classNames(ou,"BaselineUI-Reaction",e),...P,children:[jsx(VisuallyHidden,{children:jsx("input",{...d,...v,ref:u})}),jsxs("div",{...x,className:ru({isSelected:g,isFocusVisible:h,isHovered:R,isReadOnly:y,isDisabled:f}),children:[jsx("div",{className:nu({isDisabled:f,isReadOnly:y}),children:jsx(c,{size:r==="md"?20:16})}),jsx("div",{className:au({isSelected:m.isSelected,isDisabled:f,isReadOnly:y,size:r}),children:jsx(so,{value:t})})]})]})});lu.displayName="Reaction";var pu="_1azy5686",cu="_1azy5685",du="var(--_1azy5680)",uu="_1azy5688",mu="_1azy5689",fu="_1azy5681 z9nup81",yu="_1azy5682";var bu="_1azy5687";var Nx={sm:16,md:20},Ex={sm:[CheckmarkCircleFilledIcon,ErrorAltCircleFilledIcon$1],md:[CheckCircleFilledIcon,ErrorAltCircleFilledIcon]},po=ht.forwardRef(({className:e,style:t,size:o="md",variant:r="active","data-block-id":a,"data-block-class":n,...i},s)=>{let{labelProps:l,progressBarProps:p}=useProgressBar({...i,isIndeterminate:true}),c=Nx[o],u=c/2-2,m=2*u*Math.PI,d=Ex[o][r==="success"?0:1];return jsxs("div",{className:classNames(fu,"BaselineUI-ProgressSpinner",e),ref:s,style:{...assignInlineVars({[du]:`${m}px`}),...t},"data-block-id":a,"data-block-class":n,children:[jsxs("div",{...p,className:yu,children:[(r==="active"||r==="inactive")&&jsxs("svg",{height:c,width:c,viewBox:`0 0 ${c} ${c}`,children:[jsx("circle",{role:"presentation",className:pu,cx:c/2,cy:c/2,r:u}),r==="active"&&jsx("circle",{role:"presentation",className:cu,cx:c/2,cy:c/2,r:u})]}),r==="success"&&jsx(d,{className:bu,size:c}),r==="error"&&jsx(d,{className:uu,size:c})]}),i.label?jsx("span",{...l,className:mu,children:i.label}):null]})});po.displayName="ProgressSpinner";var ka=z({defaultClassName:"_5uw3kp0 oom8bs0 z9nup81",variantClassNames:{isHovered:{true:"_5uw3kp1"},isFocusVisible:{true:"_5uw3kp2"},isDisabled:{true:"_5uw3kp3"},isSelected:{true:"_5uw3kp4"},size:{sm:"_5uw3kp5",md:"_5uw3kp6",lg:"_5uw3kp7"},variant:{primary:"_5uw3kp8",toolbar:"_5uw3kp9"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isFocusVisible:true},"_5uw3kpa"],[{isSelected:true,isDisabled:true},"_5uw3kpb"],[{variant:"primary",size:"lg"},"_5uw3kpc"]]}),gu=z({defaultClassName:"_5uw3kpd _1yep5z6f5",variantClassNames:{isDisabled:{true:"_1yep5z611a"},isSelected:{true:"_1yep5z611c"}},defaultVariants:{},compoundVariants:[]});var Ox={sm:16,md:20,lg:24},wa=ht.forwardRef(({className:e,style:t,iconStart:o,size:r="md",elementType:a="button",variant:n="toolbar",...i},s)=>{let l=useToggleState(i),{buttonProps:p,isPressed:c,ref:u,isFocusVisible:m,isFocused:d,isHovered:b,uiStateOptions:f}=ea(i,l),y=filterTruthyValues({"data-block-id":i["data-block-id"],"data-block-class":i["data-block-class"],"data-focused":d,"data-focus-visible":m,"data-disabled":i.isDisabled,"data-hovered":b,"data-pressed":c,"data-selected":l.isSelected});return jsxs(a,{...mergeProps(p,y),className:classNames(ka({isHovered:b,isFocusVisible:m,isSelected:l.isSelected,size:r,isDisabled:i.isDisabled,variant:n}),"BaselineUI-ToggleButton",typeof e=="function"?e(f):e),style:typeof t=="function"?t(f):t,ref:M(u,s),children:[o?jsx(o,{size:Ox[r],className:gu({isDisabled:i.isDisabled,isSelected:l.isSelected})}):null,i.label]})});wa.displayName="ToggleButton";var Ia=z({defaultClassName:"_16vugd0b _1yep5z6ev _1yep5z6dy",variantClassNames:{isDisabled:{true:"_1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),Ra=z({defaultClassName:"_16vugd00 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{labelPosition:{end:"_1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z6vl _1yep5z6vm _1yep5z6vn",start:"_1yep5z615a _1yep5z615b _1yep5z615c _1yep5z616m _1yep5z616n _1yep5z616o"}},defaultVariants:{},compoundVariants:[]}),$a=z({defaultClassName:"_16vugd03 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6m1 _1yep5z6lz _1yep5z6h6 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6f8 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6lp _1yep5z6la",variantClassNames:{isIndeterminate:{true:"_1yep5z6181 _1yep5z612c"},isSelected:{true:"_16vugd05"},isFocusVisible:{true:"_16vugd06"},isHovered:{true:"_1yep5z613a"},isDisabled:{true:"_16vugd08 _1yep5z613e"},isReadOnly:{true:"_16vugd09 _1yep5z6118 _1yep5z6184 _1yep5z6182 _1yep5z613e"},hasError:{true:"_1yep5z612q _1yep5z6184 _1yep5z6182"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:false,isReadOnly:false},"_1yep5z61of"],[{isSelected:true,isDisabled:false,isReadOnly:false,hasError:false},"_1yep5z61u4"],[{isSelected:true,isDisabled:true},"_1yep5z61op _1yep5z61nf"],[{isSelected:true,isDisabled:true,hasError:false},"_1yep5z61u4"],[{isHovered:true,isSelected:true,isReadOnly:false},"_1yep5z61ol _1yep5z61nf"],[{isHovered:true,isSelected:true,isReadOnly:false,hasError:false},"_1yep5z61u4"],[{isHovered:true,isSelected:false,isIndeterminate:true,isReadOnly:false},"_1yep5z61ol _1yep5z61nf"],[{isHovered:true,isSelected:false,isIndeterminate:true,isReadOnly:false,hasError:false},"_1yep5z61u4"]]});var zu=ht.forwardRef(({className:e,style:t,label:o,labelPosition:r="end","data-block-id":a,"data-block-class":n,...i},s)=>{let l=ht.useRef(null),p=useToggleState(i),{isFocusVisible:c,isFocused:u,focusProps:m}=useFocusRing(),{inputProps:d,isPressed:b,isDisabled:f,isSelected:y,isReadOnly:g}=useCheckbox({...i,children:o},p,l),{hoverProps:v,isHovered:_}=useHover({isDisabled:f}),h=filterTruthyValues({"data-disabled":f,"data-readonly":g,"data-hovered":_,"data-selected":y,"data-pressed":b,"data-indeterminate":i.isIndeterminate,"data-invalid":i.isInvalid,"data-focus-visible":c,"data-focused":u,"data-block-id":a,"data-block-class":n});return jsxs("label",{...h,className:classNames(Ra({labelPosition:r}),"BaselineUI-Checkbox",e),style:t,ref:s,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(d,m),ref:l})}),jsxs("div",{...v,className:$a({isSelected:y&&!i.isIndeterminate,isIndeterminate:i.isIndeterminate,isFocusVisible:c,isDisabled:f,isReadOnly:g,hasError:i.isInvalid,isHovered:_}),children:[y&&!i.isIndeterminate?jsx(CheckmarkIcon$3,{size:12}):null,i.isIndeterminate?jsx(MinusIcon$1,{size:12}):null]}),o?jsx("span",{className:Ia({isDisabled:f}),children:o}):null]})});zu.displayName="Checkbox";var hu={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 xu=z({defaultClassName:"_1nsi9h17",variantClassNames:{isFocused:{true:"_1nsi9h18"},variant:{pinned:"_1nsi9h19",floating:"_1nsi9h1a"},size:{xs:"_1nsi9h1b",sm:"_1nsi9h1c",md:"_1nsi9h1d",lg:"_1nsi9h1e"}},defaultVariants:{},compoundVariants:[]}),Cu="_1nsi9h1f _1yep5z6ly _1yep5z6lq _1yep5z6eu",Pu=z({defaultClassName:"_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6g1 _1yep5z6e1",variantClassNames:{size:{xs:"_1nsi9h11 _1yep5z6wl _1yep5z6wm _1yep5z6wn _1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6xx _1yep5z6xy _1yep5z6xz _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z6zy",sm:"_1nsi9h12 _1yep5z6101",md:"_1nsi9h13",lg:"_1nsi9h14"},variant:{floating:"_1yep5z6za _1yep5z6184 _1yep5z6182 _1yep5z6136",pinned:"_1yep5z617q"}},defaultVariants:{},compoundVariants:[]}),ku=z({defaultClassName:"_1nsi9h1g _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6111"}},defaultVariants:{},compoundVariants:[]});var b0={style:"decimal"},g0={xs:[CaretLeftIcon$3,CaretRightIcon$3],sm:[CaretLeftIcon$2,CaretRightIcon$2],md:[CaretLeftIcon$1,CaretRightIcon$1],lg:[CaretLeftIcon,CaretRightIcon]},Tu=ht.forwardRef(({className:e,style:t,minValue:o=1,defaultValue:r=1,incrementAriaLabel:a,decrementAriaLabel:n,"aria-label":i,size:s="md",variant:l="floating",hideActions:p,isDisabled:c,...u},m)=>{let{locale:d}=useLocale(),b=A(hu),f={...u,formatOptions:b0,minValue:o,incrementAriaLabel:a||b.formatMessage("nextPage"),decrementAriaLabel:n||b.formatMessage("prevPage"),defaultValue:r,"aria-label":i||b.formatMessage("goToPage")},y=ht.useRef(null),g=useNumberFieldState({...f,locale:d}),{inputProps:v,decrementButtonProps:_,incrementButtonProps:h,groupProps:x}=useNumberField({...f,onKeyDown:j=>{j.key==="Enter"&&y.current?.blur(),u.onKeyDown?.(j);},isDisabled:c},g,y),{hoverProps:R,isHovered:P}=useHover({}),{focusProps:w,isFocused:C,isFocusVisible:D}=useFocusRing(),k=l==="floating",[T,$]=g0[s],I=filterTruthyValues({"data-focus-visible":D,"data-focused":C,"data-hovered":P,"data-block-id":u["data-block-id"],"data-block-class":u["data-block-class"]}),E=useInteractionModality()==="keyboard";return jsxs("div",{...mergeProps(x,R,I),className:classNames(Pu({size:s,variant:l}),"BaselineUI-Pagination",e),style:t,ref:m,children:[p?null:jsxs(Fragment,{children:[jsx(L,{icon:T,..._,elementType:"div",size:s,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-DecrementButton",UNSAFE_NON_INTERACTIVE:E,isDisabled:c||_.isDisabled}),l==="floating"&&jsx(U,{orientation:"vertical"})]}),jsxs("div",{className:xu({isFocused:C,variant:l,size:s}),"aria-label":b.formatMessage("pageXofY",{arg0:v.value,arg1:g.maxValue}),children:[jsx("input",{...mergeProps(v,w),ref:y,className:classNames("BaselineUI-Pagination-Input",Cu),style:{width:`${v.value?.toString().length||1}ch`}}),jsxs("span",{className:ku({isDisabled:c}),children:["/ ",jsx(so,{value:g.maxValue})]})]}),p?null:jsxs(Fragment,{children:[l==="floating"&&jsx(U,{orientation:"vertical"}),jsx(L,{icon:$,...h,elementType:"div",size:s,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-IncrementButton",UNSAFE_NON_INTERACTIVE:E,isDisabled:c||h.isDisabled})]})]})});Tu.displayName="Pagination";var Su=({date:e,...t})=>{let o=useDateFormatter(t);return jsx(Fragment,{children:o.format(e)})};Su.displayName="DateFormat";var ar=z({defaultClassName:"_1f789qjm",variantClassNames:{variant:{neutral:"_1yep5z6118",red:"_1yep5z610i",green:"_1yep5z610m",blue:"_1yep5z610u","high-contrast":"_1yep5z611b"},isDisabled:{true:"_1yep5z61nd"},isSelected:{true:"_1yep5z611c"}},defaultVariants:{},compoundVariants:[]}),Ta=z({defaultClassName:"_1f789qj0 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ax _1yep5z6ay _1yep5z6az _1yep5z6bl _1yep5z6bm _1yep5z6bn _1yep5z6c9 _1yep5z6ca _1yep5z6cb _1yep5z6cx _1yep5z6cy _1yep5z6cz _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6la _1yep5z6lq _1yep5z6ld",variantClassNames:{isFocusVisible:{true:"_1f789qj1"},variant:{neutral:"_1yep5z6128",red:"_1yep5z611n",green:"_1yep5z611r",blue:"_1yep5z611z","high-contrast":"_1yep5z612c"},isDisabled:{true:"_1f789qj7 _1yep5z6127"},allowsRemoving:{true:"_1f789qj8"},isSelected:{true:"_1yep5z612i"},allowsSelection:{true:"_1f789qja"},isHovered:{true:"_1f789qjb"},size:{md:"_1f789qjc",sm:"_1f789qjd"}},defaultVariants:{},compoundVariants:[[{allowsSelection:true,isHovered:true,variant:"neutral"},"_1yep5z61oa"],[{allowsSelection:true,isHovered:true,variant:"red"},"_1yep5z61np"],[{allowsSelection:true,isHovered:true,variant:"blue"},"_1yep5z61o1"],[{allowsSelection:true,isHovered:true,variant:"green"},"_1yep5z61nt"],[{allowsSelection:true,isHovered:true,variant:"high-contrast"},"_1yep5z61oe"],[{allowsSelection:true,isSelected:true,isHovered:true},"_1yep5z61om"],[{variant:"high-contrast",isDisabled:true},"_1yep5z61oa"],[{allowsRemoving:true,size:"md"},"_1yep5z619c _1yep5z619d _1yep5z619e"],[{allowsRemoving:true,size:"sm"},"_1yep5z61af _1yep5z61ag _1yep5z61ah"]]}),Du="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69f _1yep5z69g _1yep5z69h",Mu="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z69i _1yep5z69j _1yep5z69k",Nu=z({defaultClassName:"_1f789qju",variantClassNames:{variant:{neutral:"_1f789qjv",red:"_1f789qjw",green:"_1f789qjx",blue:"_1f789qjy","high-contrast":"_1f789qjz"},isHovered:{true:"_1f789qj10"}},defaultVariants:{},compoundVariants:[[{isHovered:true,variant:"neutral"},"_1f789qj11"],[{isHovered:true,variant:"red"},"_1f789qj12"],[{isHovered:true,variant:"blue"},"_1f789qj13"],[{isHovered:true,variant:"green"},"_1f789qj14"],[{isHovered:true,variant:"high-contrast"},"_1f789qj15"]]}),Sa=z({defaultClassName:"_1f789qje",variantClassNames:{variant:{neutral:"_1yep5z610x",red:"_1yep5z610i",green:"_1yep5z610m",blue:"_1yep5z610u","high-contrast":"_1yep5z6112"},isDisabled:{true:"_1yep5z61n4"},isSelected:{true:"_1yep5z6113"}},defaultVariants:{},compoundVariants:[]});var Au=({item:e,state:t,variant:o="neutral",size:r="md"})=>{let a=ht.useRef(null),{focusProps:n,isFocusVisible:i}=useFocusRing({within:true}),{rowProps:s,gridCellProps:l,removeButtonProps:p,allowsRemoving:c,isDisabled:u,isSelected:m,allowsSelection:d}=useTag({item:e},t,a),b=ht.useRef(null),{buttonProps:f}=useButton(p,b),{hoverProps:y,isHovered:g}=useHover({isDisabled:u}),{hoverProps:v,isHovered:_}=useHover({isDisabled:u}),h=e.value?.icon,x=e.value?.data?.variant??o,R=r==="md"?XIcon$1:XIcon$3,P=r==="md"?CheckmarkIcon$2:CheckmarkIcon$3;return jsx("div",{...mergeProps(s,n,v),ref:a,className:classNames(Ta({isFocusVisible:i,variant:x,isDisabled:u,allowsRemoving:c,isSelected:m,allowsSelection:d,isHovered:_,size:r}),Sa({variant:x,isDisabled:u,isSelected:m}),"BaselineUI-Tag"),children:jsxs("div",{...l,className:Du,children:[m?jsx(P,{size:r==="md"?16:12,className:classNames(ar({variant:x,isDisabled:u,isSelected:m}),"BaselineUI-Tag-Icon")}):null,!m&&h?jsx(h,{size:r==="md"?16:12,className:classNames(ar({variant:x,isDisabled:u,isSelected:m}),"BaselineUI-Tag-Icon")}):null,jsx(S,{paddingY:r==="md"?"sm":"none",typography:r==="sm"?"label.sm.medium":"label.md.medium",children:e.rendered}),c?jsx("button",{...mergeProps(f,y),className:Nu({variant:x,isHovered:g}),children:jsx(R,{size:r==="md"?12:8})}):null]})})};var Ou=ht.forwardRef(({className:e,style:t,"data-block-id":o,"data-block-class":r,items:a,size:n="md",...i},s)=>{let l=useMemo(()=>a.map(d=>({...d,data:{variant:d.variant}})),[a]),p=pe(),c=ht.useRef(null),u=useListState({...i,items:l,children:p}),{gridProps:m}=useTagGroup(i,u,c);return jsx("div",{...m,className:classNames(Mu,"BaselineUI-TagGroup",e),style:t,"data-block-id":o,"data-block-class":r,ref:M(s,c),children:[...u.collection].map(d=>jsx(Au,{state:u,item:d,variant:i.variant,size:n},d.key))})});Ou.displayName="TagGroup";var Hu="_1yep5z6ln",Vu=z({defaultClassName:"_1kvz17db _1yep5z6la _1yep5z6lc",variantClassNames:{showActionsOnTriggerOnly:{true:"_1kvz17dc"},isTriggered:{true:"_1kvz17dd"}},defaultVariants:{},compoundVariants:[]}),Uu=z({defaultClassName:"_1kvz17d0 _1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z68c _1yep5z68d _1yep5z68e _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6la _1yep5z6lb",variantClassNames:{isExpanded:{true:"_1kvz17d1"}},defaultVariants:{},compoundVariants:[]}),qu="_1kvz17de",Ku="_1yep5z6ev _1yep5z6dy",Gu=z({defaultClassName:"_1kvz17d2 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6la _1yep5z6ld",variantClassNames:{isFocusVisible:{true:"_1kvz17d3"},isHovered:{true:"_1yep5z6g2",false:"_1yep5z6g3"},isDisabled:{true:"z9nup82"}},defaultVariants:{},compoundVariants:[]}),Wu="_1kvz17da _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6dz",Yu=z({defaultClassName:"_1kvz17d7 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{isDisabled:{true:"_1yep5z6ey",false:"_1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var Yi=ht.forwardRef(({children:e,className:t,style:o},r)=>{let{headers:a}=useContext(it),{disabledKeys:n}=useContext(it),{keyboardProps:i}=useKeyboard({onKeyDown:s=>{let l=ge(s.target),p=l?jr(l):jr(),c=[...a?.keys()||[]].findIndex(f=>a?.get(f)?.current===p),u=a?.get(c||0),m=a?.size||0,d=f=>{let y=a.get(f-1<0?m-1:f-1);n?.has(y?.current?.getAttribute("data-key")||"")?d(f-1):y?.current?.focus();},b=f=>{let y=a.get((f+1)%m);n?.has(y?.current?.getAttribute("data-key")||"")?b(f+1):y?.current?.focus();};if(u)switch(s.key){case "Home":{s.preventDefault(),b(-1);break}case "End":{s.preventDefault(),d(m);break}case "ArrowDown":{s.preventDefault(),b(c);break}case "ArrowUp":{s.preventDefault(),d(c);break}default:s.continuePropagation();}}});return jsx("div",{...i,style:o,className:classNames(Hu,t),ref:r,children:ht.Children.map(e,(s,l)=>ht.cloneElement(s,{index:l}))})});Yi.displayName="AccordionBase";var it=ht.createContext({expandedKeys:new Set,setExpandedKeys:()=>{},disabledKeys:new Set,headers:new Map,expansionMode:"multiple"}),Ju=ht.forwardRef(({children:e,disabledKeys:t,defaultExpandedKeys:o=new Set,expandedKeys:r,expansionMode:a="multiple",onChange:n,className:i,style:s},l)=>{let[p,c]=ht.useState(o),u=ht.useRef(new Map).current,[m,d]=ht.useState(a);useEffect(()=>{d(a);},[a]),useEffect(()=>{n?.(p);},[p,n]);let b=useMemo(()=>({expandedKeys:r||p,setExpandedKeys:r?()=>{}:c,disabledKeys:t,headers:u,expansionMode:m}),[r,p,t,u,m]);return jsx(it.Provider,{value:b,children:jsx(FocusScope,{children:jsx(Yi,{className:i,style:s,ref:l,children:e})})})});Ju.displayName="Accordion";var Zi=ht.forwardRef(({title:e,actions:t,controlId:o,value:r,id:a,index:n,subLabel:i,showActionsOnTriggerOnly:s},l)=>{let p=ht.useRef(null),{expandedKeys:c,setExpandedKeys:u,expansionMode:m,disabledKeys:d,headers:b}=useContext(it),f=d?.has(r),y=useFocusManager();invariant(y);let{focusNext:g,focusPrevious:v}=y,{keyboardProps:_}=useKeyboard({onKeyDown:I=>{I.key==="ArrowRight"?g({wrap:true}):I.key==="ArrowLeft"?v({wrap:true}):I.continuePropagation();},isDisabled:f});useEffect(()=>{invariant(typeof n=="number","AccordionItem must have an index"),b?.set(n,p);},[n,b]);let h=()=>{u(I=>{let N=new Set(I);return N.has(r)?N.delete(r):(m==="single"&&N.clear(),N.add(r)),N});},{buttonProps:x}=useButton({"aria-expanded":c.has(r),"aria-controls":o,onPress:h,isDisabled:f},p),{pressProps:R}=usePress({onPress:h,isDisabled:f}),{focusProps:P,isFocusVisible:w}=useFocusRing(),{hoverProps:C,isHovered:D}=useHover({isDisabled:f}),{focusProps:k,isFocusVisible:T}=useFocusRing({within:true}),$=c.has(r);return jsxs("h3",{...mergeProps(_,R,C,k),className:Gu({isFocusVisible:w,isHovered:D,isDisabled:f}),ref:l,children:[jsxs("div",{className:Yu({isDisabled:!!f}),children:[jsx(ChevronRightIcon,{className:Uu({isExpanded:$}),size:8}),jsx("button",{...mergeProps(x,P),id:a,"data-key":r,className:Wu,ref:p,children:e})]}),t?.length?jsx("div",{"data-testid":"action-buttons",className:Vu({showActionsOnTriggerOnly:s,isTriggered:T||D}),children:t.map((I,N)=>jsx(L,{variant:"secondary",size:"sm",excludeFromTabOrder:true,isDisabled:f,...I},N))}):null,i?jsx("div",{className:Ku,children:i}):null]})});Zi.displayName="AccordionHeader";var nm=ht.forwardRef(({title:e,actions:t,children:o,value:r,index:a,subLabel:n,style:i,className:s,showActionsOnTriggerOnly:l},p)=>{let c=useId(),u=useId(),{expandedKeys:m}=useContext(it),d=m.has(r);return jsxs(Fragment,{children:[jsx(FocusScope,{children:jsx(Zi,{value:r,actions:t,id:u,title:e,controlId:c,ref:p,index:a,subLabel:n,showActionsOnTriggerOnly:l})}),jsx(AnimatePresence,{initial:false,children:d?jsx(motion.section,{role:"region","aria-labelledby":u,id:c,className:qu,variants:{open:{height:"auto",opacity:1},closed:{height:0,opacity:0}},initial:"closed",animate:"open",exit:"closed",children:jsx("div",{style:i,className:s,children:o})}):null})]})});nm.displayName="AccordionItem";var lr=ht.forwardRef(({variant:e,isOpen:t,selectedIcon:o,validationState:r="valid",valueProps:a,label:n,className:i,style:s,"data-block-id":l,"data-block-class":p,...c},u)=>{let m=ht.useRef(null),{buttonProps:d,isPressed:b}=useButton({...c,isDisabled:c.isDisabled||c.isReadOnly},m),{hoverProps:f,isHovered:y}=useHover({isDisabled:c.isDisabled}),{focusProps:g,isFocused:v,isFocusVisible:_}=useFocusRing(),h=io({isReadOnly:c.isReadOnly,validationState:r});c.isReadOnly&&(d.disabled=false);let x=filterTruthyValues({"data-disabled":c.isDisabled,"data-readonly":c.isReadOnly,"data-focused":v,"data-focus-visible":_,"data-hovered":y,"data-pressed":b,"data-open":t,"data-block-id":l,"data-block-class":p});return jsxs("button",{...mergeProps(d,f,g,x),ref:M(u,m),className:classNames(Rd({isFocused:_,isDisabled:!!c.isDisabled,isOpen:t,isHovered:y,variant:e,isReadOnly:!!c.isReadOnly}),Yt({variant:e,isHovered:y,isFocused:_,validationState:r,isDisabled:!!c.isDisabled,isReadOnly:c.isReadOnly}),i,"BaselineUI-Select-Button"),style:s,children:[jsxs(S,{display:"flex",flexDirection:"row",alignItems:"center",gap:"md",flex:1,paddingRight:"md",children:[jsxs("span",{className:Td,children:[o?jsx(o,{size:24}):null,jsx("span",{...a,children:n})]}),h?jsx("span",{"aria-hidden":true,className:classNames(Gt({validationState:r,isReadOnly:!!c.isReadOnly}),$d),children:jsx(h,{size:16})}):null]}),jsx("span",{"aria-hidden":true,children:jsx(CaretDownIcon,{size:8,className:Id({isOpen:t})})})]})});lr.displayName="SelectButton";var Da=ht.createContext({state:null,popoverAnchorRef:null}),es=ht.forwardRef(({className:e,style:t,labelPosition:o="top",variant:r="primary","data-block-id":a,"data-block-class":n,optionStyle:i,optionClassName:s,placement:l="bottom start",triggerClassName:p,triggerStyle:c,state:u,renderTrigger:m=({buttonProps:f,selectedValue:y,valueProps:g,isOpen:v,ref:_})=>{let h=y&&"icon"in y&&y.icon;return jsx(lr,{...f,className:p,style:c,isOpen:v,isReadOnly:d.isReadOnly,ref:_,variant:r,validationState:d.validationState,selectedIcon:h||void 0,label:y?"label"in y&&y?.label:d.placeholder,valueProps:g})},...d},b)=>{let{popoverAnchorRef:f}=useContext(Da),y=ht.useRef(null),g=ze(d.portalContainer),{labelProps:v,triggerProps:_,valueProps:h,menuProps:x,descriptionProps:R,errorMessageProps:P}=useSelect({...d,validationState:d.validationState==="error"?"invalid":"valid"},u,y),w=_e({...d,descriptionProps:R,errorMessageProps:P,labelPosition:o}),C=u.selectedItem?.value??null;return jsxs(Ct.Provider,{value:u,children:[jsxs("div",{style:t,className:classNames(ot({labelPosition:o}),"BaselineUI-Select",e),"data-block-id":a,"data-block-class":n,ref:b,children:[d.label||w?jsxs("div",{className:tt({labelPosition:o,hasMessage:!!w}),children:[d.label?jsx("div",{...v,className:classNames(Wt,"BaselineUI-Select-Label"),children:d.label}):null,o==="start"&&w]}):null,jsx(HiddenSelect,{state:u,triggerRef:y,isDisabled:d.isDisabled,label:d.label,name:d.name}),m({buttonProps:_,selectedValue:C,valueProps:h,isOpen:u.isOpen,ref:y}),o==="top"&&w]}),u?jsx(ke,{placement:l,portalContainer:g,offset:2,state:u,triggerRef:f||y,style:t,className:"BaselineUI-Select-Popover",...d,children:jsx(me,{...x,label:d.label,items:d.items,showSelectedIcon:d.showSelectedIcon,className:at,optionStyle:i,optionClassName:s})}):null]})});es.displayName="SelectCore";var cm=ht.forwardRef((e,t)=>{let o=pe(),r=useSelectState({...e,validationState:e.validationState==="error"?"invalid":"valid",children:o});return jsx(es,{...e,ref:t,state:r})});cm.displayName="SelectStandalone";var lt=ht.forwardRef((e,t)=>{let{state:o}=useContext(Da);return useEffect(()=>{invariant(o||e.items,"Select: A `state` that can be passed via context or `items` are required.");},[e.items,o]),o?jsx(es,{state:o,...e,ref:t}):jsx(cm,{...e,ref:t})});lt.displayName="Select";var um=ht.forwardRef(({className:e,style:t,variant:o,"data-block-id":r,icon:a,tooltip:n=true,iconTooltip:i=true,...s},l)=>{let p=ht.useRef(null),{tooltipProps:c}=ve({label:s["aria-label"],tooltip:n}),u=useCallback(({buttonProps:m,selectedValue:d,valueProps:b,isOpen:f,ref:y})=>{let g=d&&"icon"in d&&d.icon;return jsx(J,{...c,children:jsx(lr,{...m,isOpen:f,isReadOnly:s.isReadOnly,ref:y,variant:o,validationState:s.validationState,selectedIcon:g||void 0,label:d?"label"in d&&d?.label:s.placeholder,valueProps:b})})},[s,c,o]);return jsxs(S,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:classNames("BaselineUI-IconSelect",e),"data-block-id":r,style:t,ref:M(l,p),children:[a?jsx(ro,{icon:a,label:s["aria-label"],tooltip:i,"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary",display:"flex",flexShrink:0})}):null,jsx(lt,{...s,renderTrigger:u})]})});um.displayName="IconSelect";var mm="_1017q4c5",fm=z({defaultClassName:"_1017q4c0",variantClassNames:{size:{md:"_1017q4c1",sm:"_1017q4c2"},isDisabled:{true:"_1017q4c3"}},defaultVariants:{},compoundVariants:[]}),ym="_1017q4c4";var vC={sm:AvatarIcon$1,md:AvatarIcon},fo=ht.forwardRef(({className:e,style:t,size:o="md",icon:r=vC[o],name:a,imgSrc:n,showInitials:i,isDisabled:s,hasNotifications:l,imgLoading:p,"data-block-id":c,"data-block-class":u},m)=>{let{imgProps:d}=Xt({src:n,alt:a}),b=a?.split(" ").map(f=>f[0]).join("");return jsxs("span",{className:classNames(fm({size:o,isDisabled:s}),"BaselineUI-Avatar",e),"data-disabled":s,ref:m,style:t,"aria-disabled":s,"data-block-id":c,"data-block-class":u,children:[n?jsx("img",{...d,loading:p,className:ym}):null,!i&&!n&&jsx(r,{size:o==="sm"?16:24}),i&&!n?o==="sm"?b[0]:b:null,l?jsx("div",{"data-testid":"notification",className:mm}):null]})});fo.displayName="Avatar";var bm="_1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",gm=z({defaultClassName:"_1x62fhb6 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6la _1yep5z6ld _1yep5z6ev _1yep5z69i _1yep5z69j _1yep5z69k",variantClassNames:{isHovered:{true:"_1yep5z610x"},isSelected:{true:"_1x62fhb8"},isFocusVisible:{true:"_1x62fhb9"},isDisabled:{true:"_1x62fhba _1yep5z6111"},variant:{primary:"_1x62fhbb _1yep5z6zy",ghost:"_1yep5z6101"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:true,isDisabled:false},"_1yep5z61n0"],[{variant:"primary",isSelected:true},"_1yep5z61o7"],[{variant:"ghost",isSelected:true,isFocusVisible:false},"_1x62fhbd"],[{variant:"ghost",isSelected:true,isDisabled:false},"_1yep5z61n7"],[{variant:"ghost",isDisabled:true,isSelected:true},"_1x62fhbe _1yep5z6ey"],[{variant:"primary",isHovered:true},"_1yep5z61o8"]]}),vm=z({defaultClassName:"_1x62fhb3 _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",variantClassNames:{variant:{primary:"_1x62fhb4",ghost:"_1yep5z6vl _1yep5z6vm _1yep5z6vn"}},defaultVariants:{},compoundVariants:[]}),_m="_1x62fhbl",os=z({defaultClassName:"_1x62fhbf _1yep5z6f6",variantClassNames:{isHovered:{true:"_1yep5z6118"},isSelected:{true:"_1x62fhbh"},isDisabled:{true:"_1yep5z611a"},variant:{primary:"_1x62fhbj",ghost:"_1x62fhbk"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:true,isDisabled:false},"_1yep5z61nb"],[{variant:"ghost",isSelected:true,isDisabled:false},"_1yep5z61ng"],[{variant:"ghost",isDisabled:true,isSelected:true},"_1yep5z61nd"]]}),zm="_1yep5z6lu _1yep5z6lr _1yep5z6hx _1yep5z6lt",hm=z({defaultClassName:"_1x62fhb0 _1yep5z6ln _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",variantClassNames:{variant:{primary:"_1yep5z6126",ghost:"_1x62fhb2"}},defaultVariants:{},compoundVariants:[]});var xm=({state:e,...t})=>{let o=ht.useRef(null),{tabPanelProps:r}=useTabPanel(t,e,o),{selectedItem:a}=e,{focusProps:n,isFocusVisible:i}=useFocusRing();if(!a?.value)return null;let{className:s,style:l,"data-block-id":p}=a.value;return jsx("div",{...mergeProps(r,n),ref:o,className:classNames({[zm]:i},"Baseline-Tabs-TabPanel",s),"data-block-id":p,style:l,children:a?.props.children})};var ns=ht.forwardRef(({className:e,style:t,tabHeaderStyle:o,tabHeaderClassName:r,variant:a="primary",actions:n,onRemove:i,"data-block-id":s,...l},p)=>{let c=useTabListState({...l,selectedKey:l.selectedValue,defaultSelectedKey:l.defaultSelectedValue,disabledKeys:l.disabledValues}),u=ht.useRef(null),{tabListProps:m}=useTabList({...l,selectedKey:l.selectedValue,defaultSelectedKey:l.defaultSelectedValue,disabledKeys:l.disabledValues},c,u);return jsxs("div",{className:classNames("BaselineUI-Tabs",e),style:t,ref:p,"data-block-id":s,children:[jsxs("div",{className:classNames(hm({variant:a}),r),style:o,children:[jsx("div",{...m,className:vm({variant:a}),ref:u,children:[...c.collection].map(d=>(invariant(d.value,"TabItem requires a value prop"),jsx(Pm,{item:d,state:c,onRemove:i,variant:a},d.key)))}),n?.map((d,b)=>jsx("div",{className:bm,children:jsx(L,{...d,variant:"secondary",size:"sm",className:classNames(_m,d.className)})},b))]}),jsx(xm,{state:c},c.selectedItem?.key)]})});ns.displayName="TabsBase";var Pm=({item:e,onRemove:t,state:o,variant:r})=>{let{key:a,value:n}=e,i=ht.useRef(null),{tabProps:s,isSelected:l,isDisabled:p}=useTab({key:a},o,i),{hoverProps:c,isHovered:u}=useHover({});invariant(n,"TabButton requires a value prop");let{title:m,icon:d,titleStyle:b,titleClassName:f}=n,{focusProps:y,isFocusVisible:g,isFocused:v}=useFocusRing(),{keyboardProps:_}=useKeyboard({onKeyDown:x=>{x.key==="Backspace"&&t?t(a):x.continuePropagation();}}),h=filterTruthyValues({"data-selected":l,"data-disabled":p,"data-focused":v,"data-hovered":u,"data-focus-visible":g});return jsxs("div",{...mergeProps(_,s,c,y,h),className:classNames(gm({isHovered:u,isSelected:l,isFocusVisible:g,isDisabled:p,variant:r}),"BaselineUI-Tabs-TabButton",f),style:b,ref:i,children:[d?jsx(d,{size:20,className:os({isHovered:u,isSelected:l,isDisabled:p,variant:r})}):null,m,t?jsx(L,{variant:"secondary",elementType:"div",icon:XIcon$3,size:"xxs",onPress:()=>{t(a);},excludeFromTabOrder:true,UNSAFE_NON_INTERACTIVE:true,style:{display:"inline-flex",opacity:l||v||u?1:0},className:os({isHovered:u,isSelected:l,isDisabled:p,variant:r})}):null]})};Pm.displayName="TabButton";var wm=ht.forwardRef(function({children:t,...o},r){let a=useMemo(()=>ht.Children.map(t,n=>!n||!ht.isValidElement(n)||typeof n.type=="string"?null:{...n.props,id:n.props.value}).filter(Boolean),[t]);return jsx(ns,{...o,ref:r,items:a,children:n=>jsx(Item,{title:n.title,children:n.children},n.key)})});wm.displayName="Tabs";var Im=({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);Im.displayName="TabItem";var Rm={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 $m=z({defaultClassName:"kfun6yt _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6af _1yep5z6ag _1yep5z6ah",variantClassNames:{arrangement:{single:"_1yep5z6vi _1yep5z6vj _1yep5z6vk",multi:"_1yep5z6157 _1yep5z6158 _1yep5z6159",compact:"_1yep5z6157 _1yep5z6158 _1yep5z6159"}},defaultVariants:{},compoundVariants:[]}),Tm=z({defaultClassName:"kfun6y0 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ln",variantClassNames:{variant:{info:"_1yep5z611y",warning:"_1yep5z611u",error:"_1yep5z611m",success:"_1yep5z611q"},arrangement:{single:"kfun6y5 _1yep5z616m _1yep5z616n _1yep5z616o _1yep5z615m _1yep5z615n _1yep5z615o",multi:"kfun6y6",compact:"kfun6y7 _1yep5z6mc _1yep5z6md _1yep5z6me _1yep5z6oo _1yep5z6op _1yep5z6oq _1yep5z6pu _1yep5z6pv _1yep5z6pw _1yep5z6ni _1yep5z6nj _1yep5z6nk _1yep5z615d _1yep5z615e _1yep5z615f _1yep5z6wi _1yep5z6wj _1yep5z6wk"},hasButton:{true:"kfun6y8"},hasCloseButton:{true:"kfun6y9"}},defaultVariants:{},compoundVariants:[[{hasButton:false,arrangement:"single"},"_1yep5z618f _1yep5z618g _1yep5z618h _1yep5z61ar _1yep5z61as _1yep5z61at _1yep5z61bx _1yep5z61by _1yep5z61bz _1yep5z619l _1yep5z619m _1yep5z619n"],[{hasButton:true,arrangement:"compact"},"_1yep5z618f _1yep5z618g _1yep5z618h _1yep5z61ar _1yep5z61as _1yep5z61at _1yep5z61bx _1yep5z61by _1yep5z61bz _1yep5z619l _1yep5z619m _1yep5z619n"],[{hasCloseButton:true,arrangement:"compact"},"_1yep5z61af _1yep5z61ag _1yep5z61ah _1yep5z6199 _1yep5z619a _1yep5z619b"]]}),Sm=z({defaultClassName:"kfun6yq _1yep5z6eu",variantClassNames:{size:{sm:"_1yep5z6106",md:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Dm=z({defaultClassName:"kfun6ym _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{arrangement:{single:"kfun6yn",multi:"_1yep5z615j _1yep5z615k _1yep5z615l",compact:"_1yep5z6n6 _1yep5z6n7 _1yep5z6n8 _1yep5z6pi _1yep5z6pj _1yep5z6pk _1yep5z6qo _1yep5z6qp _1yep5z6qq _1yep5z6oc _1yep5z6od _1yep5z6oe _1yep5z6161 _1yep5z6162 _1yep5z6163"}},defaultVariants:{},compoundVariants:[]}),Mm=z({defaultClassName:"kfun6yh _1yep5z6lk",variantClassNames:{variant:{info:"_1yep5z610t",warning:"_1yep5z610p",error:"_1yep5z610h",success:"_1yep5z610l"}},defaultVariants:{},compoundVariants:[]}),Nm=z({defaultClassName:"kfun6ye _1yep5z6eu",variantClassNames:{size:{sm:"_1yep5z6108",md:"_1yep5z610b"}},defaultVariants:{},compoundVariants:[]}),Em=z({defaultClassName:"kfun6ya _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",variantClassNames:{arrangement:{single:"_1yep5z615m _1yep5z615n _1yep5z615o",multi:"_1yep5z6r0 _1yep5z6r1 _1yep5z6r2 _1yep5z6tc _1yep5z6td _1yep5z6te",compact:"_1yep5z6157 _1yep5z6158 _1yep5z6159"}},defaultVariants:{},compoundVariants:[]});var YC={error:{sm:ErrorAltCircleFilledIcon$1,md:ErrorAltCircleFilledIcon},info:{sm:InfoCircleFilledIcon$1,md:InfoCircleFilledIcon},success:{sm:CheckmarkCircleFilledIcon,md:CheckCircleFilledIcon},warning:{sm:WarningFilledIcon$1,md:WarningFilledIcon}},La=ht.forwardRef(({className:e,description:t,actionLabel:o,onAction:r,style:a,variant:n="info",title:i,arrangement:s="single",onClose:l,size:p="sm","data-block-id":c,"data-block-class":u,elementProps:m},d)=>{let b=A(Rm),f=o&&jsx(q,{variant:s==="compact"?"tertiary":"ghost",label:o,onPress:r}),y=YC[n][p];return jsxs("div",{className:classNames(Tm({variant:n,arrangement:s,hasButton:!!o||!!l,hasCloseButton:!!l}),"BaselineUI-InlineAlert",e),"data-block-id":c,"data-block-class":u,style:a,role:"alert",ref:d,...m?.root,children:[jsxs("div",{className:Em({arrangement:s}),children:[jsx(y,{className:Mm({variant:n}),size:16}),jsxs("div",{className:$m({arrangement:s}),...m?.content,children:[jsx("h3",{className:Nm({size:p}),...m?.title,children:i}),jsx("section",{className:Sm({size:p}),...m?.description,children:t})]}),s==="compact"&&f]}),jsxs("div",{className:Dm({arrangement:s}),children:[s!=="compact"&&f,l?jsx(L,{variant:"secondary",icon:XIcon$2,size:"sm",onPress:l,"aria-label":b.formatMessage("close"),...m?.close}):null]})]})});La.displayName="InlineAlert";var pt={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 Ba=({children:e})=>{let{triggerProps:t}=ht.useContext(Pt);return jsx(PressResponder,{...t,children:e})};Ba.displayName="ModalTrigger";var oP=({children:e})=>{let{state:t}=ht.useContext(Pt);return jsx(PressResponder,{onPress:()=>{t?.close();},children:e})};var Lm="_1dbkl53 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6ln",Bm="_1dbkl5e",Am=z({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 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6ly _1yep5z6lq _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6lp _1yep5z6dy",variantClassNames:{isHovered:{true:"_1dbkl55"},isFocusVisible:{true:"_1dbkl56"},isDisabled:{true:"z9nup82 _1yep5z6111"},labelPosition:{top:"_1dbkl58",start:"_1dbkl59"}},defaultVariants:{},compoundVariants:[]}),Fm="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kj _1yep5z6kk _1yep5z6kl",jm=z({defaultClassName:"_1dbkl50 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6dy _1yep5z6ev",variantClassNames:{labelPosition:{top:"_1yep5z6oi _1yep5z6oj _1yep5z6ok",start:"_1dbkl52"}},defaultVariants:{},compoundVariants:[]}),Aa="_1dbkl5l _1yep5z6iy _1yep5z6iz _1yep5z6j0 _1yep5z69f _1yep5z69g _1yep5z69h",Om="_1dbkl5f z9nup86",Fa="_1dbkl5m _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6id _1yep5z6ie _1yep5z6if",Hm="_1dbkl5k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6lq",Vm="_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6dy _1yep5z6ev _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jj _1yep5z6jk _1yep5z6jl",ja=z({defaultClassName:"_1dbkl5h _1dbkl5g _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6g1",variantClassNames:{includesCustomColorPicker:{true:"_1yep5z6n6 _1yep5z6n7 _1yep5z6n8"}},defaultVariants:{},compoundVariants:[]}),ls="_1dbkl5v _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3",Um=z({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 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lz _1yep5z6h4 _1yep5z6lq _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocused:{true:"_1dbkl5r _1yep5z6134"},isHovered:{true:"_1dbkl5s"},allowAlpha:{false:"_1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z617q"}},defaultVariants:{},compoundVariants:[[{isHovered:true,isFocused:false},"_1yep5z61pb"]]}),qm=z({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 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69c _1yep5z69d _1yep5z69e _1yep5z6f5 _1yep5z6lp _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6la _1yep5z6ld",variantClassNames:{isHovered:{true:"_1yep5z6126"},isFocusVisible:{true:"_1yep5z617w _1yep5z617u _1yep5z617x _1yep5z6140"},isDisabled:{true:"_1yep5z611a"}},defaultVariants:{},compoundVariants:[]}),Oa="_1dbkl5g",dr="_1dbkl5u",Ha="_1dbkl5j _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69f _1yep5z69g _1yep5z69h",ps="_1dbkl5x",Km="_1dbkl5w",cs="_1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69l _1yep5z69m _1yep5z69n",Va=z({defaultClassName:"_1dbkl5n _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6lu _1yep5z6ig _1yep5z6ih _1yep5z6ii _1yep5z6lz _1yep5z6m2",variantClassNames:{isFocusVisible:{true:"_1dbkl5o _1yep5z617u _1yep5z6140 _1yep5z617w"}},defaultVariants:{},compoundVariants:[]}),ds="z9nup83 z9nup85 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6lg _1yep5z6lh _1yep5z6lj _1yep5z6li _1yep5z6ig _1yep5z6ih _1yep5z6ii";var Gm=z({defaultClassName:"_1344e9q0 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6lk _1yep5z6ic _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf",variantClassNames:{isFocusVisible:{true:"_1344e9q1"},isDisabled:{true:"_1344e9q2"},removeBlendMode:{true:"_1344e9q3"},isSelected:{true:"_1yep5z617w _1yep5z617u _1yep5z6140 _1yep5z617z"},isHovered:{true:"_1344e9q5"}},defaultVariants:{},compoundVariants:[[{isSelected:false,isFocusVisible:true},"_1344e9q6"],[{isSelected:true,isFocusVisible:true},"_1344e9q7 _1yep5z61tz _1yep5z61tx _1yep5z61q3 _1yep5z61u2"],[{isSelected:true,isDisabled:true},"_1yep5z61tz _1yep5z61tx _1yep5z61q3 _1yep5z61u2 _1yep5z61qd"],[{isHovered:true,isSelected:false},"_1yep5z61u2 _1yep5z61tz _1yep5z61tx _1yep5z61q7"]]}),Wm="_1yep5z6f6",Ym="_1344e9q9 _1yep5z6fl";var ct=ht.forwardRef(({color:e,isFocusVisible:t,isSelected:o,isInteractive:r,isDisabled:a,style:n,className:i,id:s,tooltip:l,isIndeterminate:p,indeterminateIcon:c=HelpIcon,"data-block-id":u,"data-block-class":m,...d},b)=>{let f=e&&e!==Be&&(typeof e=="string"?parseColor(e):e),{formatMessage:y}=A(),g=!f,{colorSwatchProps:v}=useColorSwatch({color:g?"#000000":e}),{hoverProps:_,isHovered:h}=useHover({isDisabled:a||!r}),x=filterTruthyValues({"data-focus-visible":t,"data-selected":o,"data-hovered":h,"data-block-id":u,"data-block-class":m,"data-disabled":a,"data-interactive":r,"data-indeterminate":p}),R=g?y(Xm.none):v["aria-label"],P=d["aria-label"]??R,{tooltipProps:w}=ve({tooltip:l,label:P}),C=jsx("div",{...mergeProps(_,x,g?{}:v),style:n,"aria-label":g?y(Xm.none):v["aria-label"],role:"img",className:classNames(Gm({removeBlendMode:g,isFocusVisible:t,isDisabled:!!a,isSelected:!!o,isHovered:h}),"BaselineUI-ColorSwatch",i),ref:b,id:s,...d,children:jsxs(S,{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"full",height:"full",width:"full",opacity:a?"medium":void 0,style:f&&!p?Zm(f,4):void 0,children:[g&&!p?jsx("div",{className:Ym}):null,p&&c?jsx(c,{role:"presentation",size:16,className:Wm,"aria-hidden":"true"}):null]})});return w&&!a?jsx(J,{...w,children:jsx(ba,{children:C})}):C});ct.displayName="ColorSwatch";var Xm=G({none:{id:"none",defaultMessage:"None"}});var Qm=[{id:"hex",label:"HEX"},{id:"rgb",label:"RGB"}],fr=parseColor("#000000").toFormat("hsla"),de="hsla",mr="hexa";function Rt(e){return typeof e=="string"?parseColor(e).toFormat(de):e?e.toFormat(de):null}function ef(e,t){return e?.getChannelValue("alpha")?t?.toString(mr)===e.toString(mr):!t?.getChannelValue("alpha")}function tf(e,t,o){return t?.label?t.label:e?.getChannelValue("alpha")===0?o:e?.toString("rgba")}var Be="NONE";function of(e,t){let o=t?.map(a=>({id:parseColor(a.color).toString(mr),label:a.label}))||[],r={id:Be,label:e};return [...o,r]}var Ua=(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:Hm,children:jsx(ct,{color:e.value.id,isFocusVisible:o,isSelected:r,"aria-label":e.value.label,isInteractive:true})})),Zm=(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 af=({value:e,...t})=>{let o=ht.useRef(null),r=ht.useRef(null),a=ht.useRef(null),n=useColorAreaState({...t,value:e}),{colorAreaProps:i,xInputProps:s,yInputProps:l,thumbProps:p}=useColorArea({...t,value:e,inputXRef:o,inputYRef:r,containerRef:a},n);useEffect(()=>{o.current?.focus();},[]);let{focusProps:c,isFocusVisible:u}=useFocusRing();return jsx("div",{ref:a,...i,className:classNames(Lm,"BaselineUI-ColorInput-ColorArea"),children:jsxs("div",{...p,className:classNames(Va({isFocusVisible:u}),"BaselineUI-ColorInput-ColorAreaThumb"),style:{...p.style,transform:"translate(-50%, -50%)",backgroundColor:Rt(e)?.withChannelValue("alpha",1).toString("css")},children:[jsx("input",{ref:o,...s,...c}),jsx("input",{ref:r,...l,...c})]})})};var lf=({color:e,setColor:t,allowAlpha:o,...r})=>{let a=useColorFieldState({value:e,onChange:u=>{t(Rt(u)?.toFormat(de).withChannelValue("alpha",e.getChannelValue("alpha")??1)||fr);}}),n=ht.useRef(null),{inputProps:i}=useColorField({...r,"aria-label":"Hex"},a,n),{focusProps:s,isFocused:l}=useFocusRing({isTextInput:true}),{hoverProps:p,isHovered:c}=useHover({});return jsxs("div",{className:classNames(ls,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"hexa":"hex",children:[jsx("input",{...mergeProps(i,s,p),ref:n,className:Um({isFocused:l,isHovered:c,allowAlpha:o})}),o?jsx(cf,{color:e,setColor:t}):null]})},pf=({color:e,setColor:t,allowAlpha:o})=>{let r=e.toFormat("rgba"),{locale:a}=useLocale();return jsxs("div",{className:classNames(ls,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"rgba":"rgb",children:[jsx(Ve,{"aria-label":e.getChannelName("red",a),value:r.getChannelValue("red"),showStepper:false,className:dr,onChange:n=>{t(r.withChannelValue("red",n).toFormat(de));},step:1,minValue:0,maxValue:255}),jsx(Ve,{"aria-label":e.getChannelName("green",a),value:r.getChannelValue("green"),showStepper:false,className:dr,onChange:n=>{t(r.withChannelValue("green",n).toFormat(de));},step:1,minValue:0,maxValue:255}),jsx(Ve,{"aria-label":e.getChannelName("blue",a),value:r.getChannelValue("blue"),showStepper:false,className:dr,onChange:n=>{t(r.withChannelValue("blue",n).toFormat(de));},step:1,minValue:0,maxValue:255}),o?jsx(cf,{color:e,setColor:t}):null]})},IP={style:"percent",maximumFractionDigits:0},cf=({color:e,setColor:t})=>{let{locale:o}=useLocale(),r=useCallback(a=>{t(e.withChannelValue("alpha",a));},[e,t]);return jsx(Ve,{"aria-label":e.getChannelName("alpha",o),value:e.getChannelValue("alpha"),formatOptions:IP,className:dr,showStepper:false,onChange:r,minValue:0,maxValue:1})};var ys=({channel:e,...t})=>{let{locale:o}=useLocale(),r=useColorSliderState({...t,channel:e,locale:o}),a=ht.useRef(null),n=ht.useRef(null),{trackProps:i,thumbProps:s,inputProps:l}=useColorSlider({...t,channel:e,trackRef:a,inputRef:n,"aria-label":r.value.getChannelName(e,o)},r),{focusProps:p,isFocusVisible:c}=useFocusRing();return jsxs("div",{className:classNames(Fa,{[zc({size:"xs"})]:e==="alpha"},"BaselineUI-ColorInput-ColorSlider"),"data-channel":e,...i,ref:a,children:[e==="alpha"&&jsx("div",{className:ds}),jsx("div",{className:Fa,style:i.style}),jsxs("div",{className:classNames(Va({isFocusVisible:c}),"BaselineUI-ColorInput-ColorSliderThumb"),...s,children:[jsx("div",{className:ds,style:{backgroundColor:"#ffffff"}}),jsx("div",{style:{backgroundColor:r.getDisplayColor().toString("css"),height:8},className:Fa}),jsx(VisuallyHidden,{children:jsx("input",{ref:n,...l,...p})})]})]})};var qa=({color:e,setColor:t,allowAlpha:o,onChangeEnd:r})=>{let[a,n]=ht.useState("hex"),{formatMessage:i}=A(pt);return jsxs(Fragment,{children:[jsx(af,{value:e,xChannel:"saturation",yChannel:"lightness",onChange:t,onChangeEnd:r}),jsxs("div",{className:cs,children:[jsx(ys,{channel:"hue",value:e,onChange:t,onChangeEnd:r}),o?jsx(ys,{channel:"alpha",value:e,onChange:t,onChangeEnd:r}):null]}),jsxs("div",{className:classNames(cs,sprinkles.variants({paddingTop:"none",gap:"sm"})),children:[jsx(lt,{label:i("colorFormat"),labelPosition:"start",variant:"ghost",items:Qm,selectedKey:a,onSelectionChange:s=>{n(s);}}),a==="hex"&&jsx(lf,{color:e,setColor:s=>{t(s),r?.(s);},allowAlpha:o}),a==="rgb"&&jsx(pf,{color:e,setColor:s=>{t(s),r?.(s);},allowAlpha:o})]})]})};var gf=({color:e,setColor:t,storePickedColorKey:o,addColorButtonLabel:r,removeColorButtonLabel:a,customColorsLabel:n,pickerMode:i,allowAlpha:s})=>{let{locale:l}=useLocale(),{formatMessage:p}=A(pt),c=ht.useRef(null),u=Ne(c.current),[m,d]=yc(o,[]),b=ht.useRef(null),[f,y]=ht.useState(e),g=ht.useMemo(()=>m.map(P=>({id:P,label:parseColor(P).getColorName(l),description:P})),[m,l]),v=useCallback(()=>{let P=i==="active"?e:f;if(m.includes(P.toString(de))){b.current?.querySelector(`[data-key='${P.toString(de)}']`)?.classList.add(ps);return}d([...m,P.toString(de)]);},[m,e,d,f,i]);useEffect(()=>{let P=b.current;function w(C){C.animationName===Km&&C.target?.classList.remove(ps);}return P?.addEventListener("animationend",w),()=>{P?.removeEventListener("animationend",w);}},[]);let _=useId(),h=jsx(L,{ref:c,variant:"secondary",size:"md","aria-label":r,icon:PlusIcon$1,onPress:i==="active"?v:void 0}),x=useCallback(P=>jsxs(xe,{size:"content",className:ja({includesCustomColorPicker:true}),style:{paddingBlockEnd:0},"aria-label":p("newColor"),children:[jsx(qa,{color:f,setColor:y,allowAlpha:s}),jsx(U,{}),jsx(S,{padding:"lg",display:"flex",flexDirection:"row-reverse",children:jsxs(S,{display:"inline-flex",gap:"lg",children:[jsx(q,{label:p("cancel"),size:"sm",variant:"secondary",onPress:P}),jsx(q,{label:p("add"),variant:"primary",onPress:()=>{v(),P();},size:"sm"})]})})]}),[f,v,p,s]),R=useCallback(P=>{invariant(P instanceof Set,"Key must be a set");let w=[...P][0];w&&t(parseColor(w).toFormat(de));},[t]);return jsxs(Fragment,{children:[jsx(U,{}),jsxs("div",{className:classNames(Vm,"BaselineUI-ColorInput-CustomColors"),children:[jsx("span",{id:_,children:n}),jsxs(S,{display:"flex",children:[!!m.length&&m.includes(e.toString(de))&&jsx(L,{variant:"secondary",size:"md",elementType:"div",icon:MinusIcon$2,"aria-label":a,onPress:()=>{d(m.filter(P=>P!==e.toString(de)));}}),i==="active"&&h,i==="lazy"&&(u==="mobile"?jsxs(Ee,{children:[jsx(Ba,{children:h}),jsx(Ue,{style:{zIndex:1e5},children:({close:P})=>x(P)})]}):jsxs(je,{type:"dialog",children:[jsx(Oe,{children:h}),jsx(Le,{placement:"right top",className:Oa,offset:6,children:({close:P})=>x(P)})]}))]})]}),!!m.length&&jsx(me,{items:g,layout:"grid","aria-labelledby":_,className:classNames(Aa,Ha,sprinkles.variants({paddingTop:"xs"}),"BaselineUI-ColorInput-CustomColorsListBox"),renderOption:Ua,ref:b,autoFocus:false,selectionMode:"single",selectedKeys:[e.toString(de)],onSelectionChange:R})]})};var vs=ht.forwardRef(({setColor:e,color:t,triggerRef:o,autoFocus:r,presets:a,state:n},i)=>{let{formatMessage:s}=A(pt),l=useCallback(p=>{if(p instanceof Set&&p.size){let c=[...p][0],u=a.find(m=>m.id===c);invariant(u,"Preset not found"),e(u.id===Be?null:parseColor(u.id).toFormat(de)),n.close();}},[n,a,e]);return jsx("div",{className:classNames(Ha,"BaselineUI-ColorInput-Presets"),style:{minWidth:o.current?.offsetWidth},ref:i,children:jsx(me,{autoFocus:r,items:a,layout:"grid","aria-label":s("colorPresets"),className:Aa,renderOption:Ua,selectionMode:"single",selectedKeys:[t?.toString(mr)||Be],onSelectionChange:l})})});vs.displayName="ColorPresetList";var br=ht.forwardRef(({color:e,colorLabel:t,colorName:o,isIndeterminate:r,indeterminateIcon:a,...n},i)=>{let s=ht.useRef(null),{hoverProps:l,isHovered:p}=useHover({isDisabled:n.isDisabled}),{buttonProps:c,isPressed:u}=useButton(n,s),{isFocusVisible:m,focusProps:d}=useFocusRing(),b=filterTruthyValues({"data-block-id":n["data-block-id"],"data-focused":m,"data-focus-visible":m,"data-disabled":n.isDisabled,"data-hovered":p,"data-pressed":u}),f=Fr(),y=Fr();return jsxs("button",{...mergeProps(c,l,d,b),style:n.style,className:classNames(Am({isHovered:p,isFocusVisible:m||n.isOpen,isDisabled:n.isDisabled,labelPosition:n.labelPosition}),"BaselineUI-ColorInputButton",n.className),ref:M(i,s),id:f,"aria-labelledby":n["aria-labelledby"]||`${f} ${y}`,children:[jsx(ct,{color:e?.toString("hexa"),isIndeterminate:r,indeterminateIcon:a}),t?jsx("div",{className:Om,id:y,"aria-hidden":"true",children:o}):typeof o=="string"&&jsx(VisuallyHidden,{children:o})]})});br.displayName="ColorInputButton";var Wa=ht.forwardRef(({className:e,style:t,icon:o,...r},a)=>{let n=ht.useRef(null),{hoverProps:i,isHovered:s}=useHover({isDisabled:r.isDisabled}),{buttonProps:l,isPressed:p}=useButton(r,n),{isFocusVisible:c,focusProps:u}=useFocusRing(),m=filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":c,"data-focus-visible":c,"data-disabled":r.isDisabled,"data-hovered":s,"data-pressed":p});return jsxs("button",{...mergeProps(l,i,u,m),ref:M(a,n),style:t,className:classNames(qm({isHovered:s||p||r.isOpen,isFocusVisible:c,isDisabled:r.isDisabled}),"BaselineUI-IconColorInputButton","BaselineUI-IconColorInput-Button",e),children:[jsx(o,{size:16}),jsx("div",{className:Bm,style:{backgroundColor:r.color||void 0}})]})});Wa.displayName="IconColorInputButton";function If({colorLabel:e,color:t,presets:o,isIndeterminate:r}){let{formatMessage:a}=A(),{locale:n}=useLocale(),i=useMemo(()=>r?{id:"indeterminate",label:a(wf.indeterminate)}:o.find(p=>p.id===Be?!t:t?ef(t,parseColor(p.id)):false),[o,t,r,a]),s=useMemo(()=>{if(typeof e=="function")return e?.(t,{isIndeterminate:!!r});if(typeof e=="boolean")return e?tf(t,i,a(wf.transparent)):false;throw new TypeError("`colorLabel` must be a function or a boolean")},[t,e,a,i,r]),l=useMemo(()=>{if(i?.label)return i.label;t?.getColorName(n);},[t,n,i?.label]);return {colorName:s,humanReadableName:l}}var wf=G({transparent:{defaultMessage:"Transparent",id:"transparent"},indeterminate:{defaultMessage:"Indeterminate",id:"indeterminate"}});var go=ht.forwardRef(({className:e,style:t,allowRemoval:o,allowAlpha:r=true,presets:a,labelPosition:n="top",colorLabel:i=true,includePicker:s=true,onChange:l,onChangeEnd:p,defaultValue:c,storePickedColorKey:u="baselinePickedColor",value:m,addColorButtonLabel:d,removeColorButtonLabel:b,customColorsLabel:f,renderTriggerButton:y=({isOpen:D,color:k,ref:T,colorName:$,triggerProps:I,labelId:N,isIndeterminate:E,indeterminateIcon:j})=>jsx(br,{...mergeProps(I,{...w.label?{"aria-labelledby":N}:{"aria-label":w["aria-label"]}}),ref:T,isOpen:D,isDisabled:w.isDisabled,labelPosition:n,color:k,colorLabel:i,colorName:$,isIndeterminate:E,indeterminateIcon:j}),pickerMode:g="active",offset:v=2,placement:_=n==="start"?"bottom end":"bottom start","data-block-id":h,"data-block-class":x,isIndeterminate:R,indeterminateIcon:P,...w},C)=>{let D=ht.useRef(null),k=ht.useRef(null),T=useOverlayTriggerState(w),{triggerProps:$,overlayProps:I}=useOverlayTrigger({type:"listbox"},T,D),N=ze(w.portalContainer),[E,j]=useControlledState(m===void 0?void 0:Rt(m),Rt(c),X=>l?.(X?.toFormat("rgba")||null)),{formatMessage:B}=A(pt),O=useMemo(()=>of(B(Ya.noColor),a),[a,B]),H=useId(),{colorName:V}=If({colorLabel:i,color:E,presets:O,isIndeterminate:R}),Q=useMemo(()=>O.filter(X=>o||X.id!==Be),[O,o]),F=d||B(Ya.addColor),Y=b||B(Ya.removeColor),oe=f||B(Ya.customColors),le=jsx(gf,{color:E||fr,setColor:X=>{j(X),p?.(X?.toFormat("rgba")||null);},storePickedColorKey:u,addColorButtonLabel:F,removeColorButtonLabel:Y,customColorsLabel:oe,pickerMode:g,allowAlpha:r});return jsxs(Fragment,{children:[jsxs("div",{className:classNames({[Fm]:n==="start"},"BaselineUI-ColorInput-Trigger",e),"data-block-id":h,"data-block-class":x,style:t,ref:C,children:[w.label?jsx("label",{id:H,className:jm({labelPosition:n}),children:w.label}):null,y({isOpen:T.isOpen,color:E,ref:D,colorName:V,triggerProps:$,labelId:H,isIndeterminate:R,indeterminateIcon:P})]}),jsx(ke,{...w,portalContainer:N,placement:_,state:T,offset:v,className:classNames(Oa,"BaselineUI-ColorInput-Popover"),triggerRef:D,overlayProps:I,children:jsxs(xe,{size:"content",className:ja({includesCustomColorPicker:s}),ref:k,"aria-labelledby":H,"aria-label":w["aria-label"],children:[s&&g==="active"?jsxs(Fragment,{children:[jsx(qa,{color:E||fr,setColor:j,allowAlpha:r,onChangeEnd:X=>{p?.(X?.toFormat("rgba")||null);}}),le]}):null,!!Q.length&&jsxs(Fragment,{children:[s&&g==="active"?jsx(U,{}):null,jsx(vs,{autoFocus:s&&g==="active"?false:"first",state:T,triggerRef:D,presets:Q,color:E,setColor:X=>{j(X),p?.(X?.toFormat("rgba")||null);}})]}),s&&g==="lazy"?le:null]})})]})});go.displayName="ColorInput";var Ya=G({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 Sf=ht.forwardRef(({className:e,style:t,icon:o,variant:r="standard","data-block-id":a,tooltip:n=true,iconTooltip:i=true,...s},l)=>{let p=ht.useRef(null),{tooltipProps:c}=ve({label:s["aria-label"],tooltip:n}),u=useCallback(({isOpen:m,color:d,ref:b,colorName:f,triggerProps:y,isIndeterminate:g,indeterminateIcon:v})=>jsx(J,{...c,children:r==="standard"?jsx(br,{...y,"aria-label":s["aria-label"],ref:b,isOpen:m,isDisabled:s.isDisabled,color:d,colorLabel:false,colorName:f,isIndeterminate:g,indeterminateIcon:v}):jsx(Wa,{...y,isOpen:m,icon:TextIcon,color:d?.toString("hexa"),ref:b,isDisabled:s.isDisabled,"aria-label":s["aria-label"],isIndeterminate:g,indeterminateIcon:v})}),[s,c,r]);return jsxs(S,{display:"flex",flexDirection:"row",gap:"md",paddingX:r==="standard"?"md":"none",alignItems:"center",className:classNames("BaselineUI-IconColorInput",e),"data-block-id":a,style:t,ref:M(l,p),children:[r==="standard"&&o?jsx(ro,{icon:o,label:s["aria-label"],tooltip:i,"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary"})}):null,jsx(go,{...s,colorLabel:false,renderTriggerButton:u})]})});Sf.displayName="IconColorInput";var Df={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 Xa=z({defaultClassName:"mnnh5s1 _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6la _1yep5z6ld _1yep5z6lp _1yep5z6lo _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ln",variantClassNames:{isInline:{true:"mnnh5s2 _1yep5z6wo _1yep5z6wp _1yep5z6wq _1yep5z6xc _1yep5z6xd _1yep5z6xe _1yep5z6y0 _1yep5z6y1 _1yep5z6y2 _1yep5z6yo _1yep5z6yp _1yep5z6yq _1yep5z6138 _1yep5z6183 _1yep5z6184",false:"_1yep5z617q _1yep5z6127"},isHovered:{true:"mnnh5s4"},hasLoadedImage:{true:"_1yep5z6126"},includeCheckeredBackground:{true:"mnnh5s6"},showFocusRing:{true:"_1yep5z613j _1yep5z617w _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"mnnh5s8 _1yep5z6zd"}},defaultVariants:{},compoundVariants:[[{isHovered:true,hasLoadedImage:false},"_1yep5z61oh"],[{isHovered:true,hasLoadedImage:true},"mnnh5s9"],[{isInline:true,isDisabled:true},"_1yep5z61pb"],[{hasLoadedImage:true,includeCheckeredBackground:true},"_1yep5z61o9"]]}),Mf="_1yep5z6d8",Za=z({defaultClassName:"mnnh5sa",variantClassNames:{isInline:{true:"mnnh5sb",false:"mnnh5sc"},isDisabled:{true:"mnnh5sd"},hasLoadedImage:{true:"mnnh5s0"}},defaultVariants:{},compoundVariants:[]});var Nf=z({defaultClassName:"_1i0ytqa3 _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6ln _1yep5z6lo _1yep5z6lq",variantClassNames:{isFocusVisible:{true:"_1i0ytqa4"},isInline:{true:"_1yep5z612f",false:"_1yep5z612h"},isDisabled:{true:"_1i0ytqa7 _1yep5z6zd",false:"_1i0ytqa8"}},defaultVariants:{},compoundVariants:[[{isInline:true,isFocusVisible:true},"_1i0ytqa9 _1yep5z61p7 _1yep5z61u5 _1yep5z61u7"],[{isInline:false,isFocusVisible:true},"_1i0ytqaa"],[{isInline:true,isDisabled:true},"_1yep5z61oi"],[{isInline:false,isDisabled:true},"_1yep5z61ok"]]}),Ef="_1i0ytqa0",Ja=z({defaultClassName:"_1i0ytqab _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ln",variantClassNames:{isInline:{false:"_1yep5z6126"},isDisabled:{true:"_1i0ytqad _1yep5z6zd"}},defaultVariants:{},compoundVariants:[]}),Lf=z({defaultClassName:"_1i0ytqa1 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6ln",variantClassNames:{isInline:{false:"_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b"}},defaultVariants:{},compoundVariants:[]});function Bf({line:e,options:t}){let o=useRef([]),r=useMemo(()=>{let a=Math.ceil(e.length/vo),n;for(let i=0;i<a;i++)if(!(!(i===a-1)&&!!o.current[i])){let p=e.slice(i*vo-(i>0?1:0),i*vo+vo);n=getSvgPathFromStroke(getStroke(p.map(([c,u,m])=>({x:c,y:u,pressure:m})),t)),p.length>=(i>0?vo+1:vo)&&(o.current[i]=n);}return n},[e,t]);return [...o.current,r]}var vo=60*3;var R2={size:1,thinning:0,smoothing:0,streamline:0,easing:e=>e,start:{taper:0,easing:e=>e,cap:true},end:{taper:0,easing:e=>e,cap:true},simulatePressure:false},Ff=ht.forwardRef(({className:e,style:t,canvasClassName:o,canvasStyle:r,isBound:a=true,strokeWidth:n=2,strokeColor:i="#3A87FD",onChange:s,defaultValue:l,onChangeEnd:p,enableHistory:c=false,isInline:u=true,isDisabled:m,placeholder:d,clearLabel:b,undoLabel:f,redoLabel:y,footerClassName:g,canvasRef:v,value:_,footerStyle:h,"data-block-id":x,"data-block-class":R,"aria-label":P="Drawing canvas",description:w="This is a canvas for drawing using a mouse or touch input.",...C},D)=>{let k=A(Df),T=ht.useRef(null),[$,I]=ht.useState(_||l||[]),N=ht.useMemo(()=>({...R2,...C}),[C]),[E,j]=ht.useState(),B=useId(),{labelProps:O,fieldProps:H}=useLabel({...C,"aria-label":P,labelElementType:"span"}),{isFocusVisible:V,focusProps:Q}=useFocusRing({within:true}),{hoverProps:F,isHovered:Y}=useHover({isDisabled:m}),{undo:oe,redo:le,canRedo:X,canUndo:Pe,push:Ie}=sc($,{onAction:Z=>{Z&&(I(Z),p?.(Z));},isDisabled:!c}),{keyboardProps:zt}=useKeyboard({onKeyDown:Z=>{Z.key==="Backspace"?Vt():Z.key==="z"&&(Z.metaKey||Z.ctrlKey)&&(Z.shiftKey?X&&le():Pe&&oe());}}),[ie,fe]=useState(false),Bo=useCallback(Z=>{let K=Z.currentTarget.getBoundingClientRect();j(K),Z.target.setPointerCapture(Z.pointerId);let ce=[Z.clientX-K.x,Z.clientY-K.y,Z.pressure];I(ee=>[...ee,[ce]]),fe(true);},[]),Ot=useCallback(Z=>{if(Z.buttons!==1||!E)return;let ce=Hf(Z.nativeEvent).map(ee=>[a?clamp(ee.clientX-E.left,0,E.width):ee.clientX-E.left,a?clamp(ee.clientY-E.top,0,E.height):ee.clientY-E.top,ee.pressure]);I(ee=>{let be=[...ee];return be[ee.length-1]=[...be[ee.length-1],...ce],be});},[E,a]),Ht=()=>{E&&(p?.($),Ie($),fe(false));};useEffect(()=>{s?.($);},[$,s]);let Vt=()=>{I([]),s?.([]),Ie([]);};return jsxs("div",{ref:M(T,D),className:classNames(Ef,"BaselineUI-FreehandCanvas",e),style:t,"aria-disabled":m,"data-block-id":x,"data-block-class":R,children:[C.label||c?jsxs("div",{className:Lf({isInline:u}),children:[C.label?jsx(te,{type:"label",size:"sm",...O,children:C.label}):jsx("span",{}),c?jsxs("div",{children:[jsx(L,{variant:"secondary",size:"sm",isDisabled:!Pe||m,icon:UndoIcon,onPress:oe,"aria-label":f||k.formatMessage("undo")}),jsx(L,{variant:"secondary",size:"sm",isDisabled:!X||m,icon:RedoIcon,onPress:le,"aria-label":y||k.formatMessage("redo")})]}):null]}):null,jsxs("div",{role:"application",...mergeProps(Q,zt,F,H),tabIndex:m?void 0:0,className:classNames(Xa({isInline:u,isHovered:Y}),Nf({isFocusVisible:V,isInline:u,isDisabled:!!m}),o),"aria-describedby":C["aria-describedby"]||B,style:r,ref:v,children:[jsx(VisuallyHidden,{children:jsx("div",{id:B,children:w})}),jsx("svg",{width:r?.width||"100%",height:r?.height||"100%",onPointerDown:Bo,onPointerMove:Ot,onPointerUp:Ht,children:(_||$).map((Z,K,ce)=>K<ce.length-1||!ie?jsx(jf,{line:Z,options:N,strokeColor:i,strokeWidth:n},K):jsx(Of,{line:Z,options:N,strokeColor:i,strokeWidth:n},K))})]}),d||b?jsx("div",{style:h,className:classNames(Ja({isInline:u,isDisabled:m}),g),children:($.length||!d)&&b?jsx(q,{size:"sm",variant:"ghost",label:b,isDisabled:m,onPress:Vt}):jsx(q,{size:"sm",variant:"ghost",label:d,isDisabled:true})}):null]})});Ff.displayName="FreehandCanvas";var jf=ht.memo(({line:e,options:t,strokeColor:o,strokeWidth:r})=>{let a=useMemo(()=>getSvgPathFromStroke(getStroke(e.map(([n,i,s])=>({x:n,y:i,pressure:s})),t)),[e,t]);return jsx("path",{d:a,stroke:o,strokeWidth:r})});jf.displayName="Stroke";var Of=ht.memo(({line:e,options:t,strokeColor:o,strokeWidth:r})=>{let a=Bf({line:e,options:t});return jsx(Fragment,{children:a.map((n,i)=>jsx("path",{d:n,stroke:o,strokeWidth:r},i))})});Of.displayName="SplitStroke";function Hf(e){if(typeof e.getCoalescedEvents=="function"){let t=e.getCoalescedEvents();return t.length>0?t.flatMap(o=>Hf(o)):[e]}return [e]}var Vf="_1vac7ws0",Uf=z({defaultClassName:"_1vac7ws1",variantClassNames:{isDragging:{true:"_1vac7ws2"}},defaultVariants:{},compoundVariants:[]});function Kf(e,t){let[o,r]=useState([]),a=()=>e?.flatMap(n=>[...t.querySelectorAll(n)]).map(n=>({current:n}));return useGranularEffect(()=>{r(a());},[],[a]),useGranularEffect(()=>{let n=a();r(n);},[e],[a]),o}function Gf(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 q2=makeMoveable([Draggable,Resizable,Rotatable,Snappable]),Yf=ht.forwardRef(({className:e,children:t,isRotatable:o,isResizable:r,isDraggable:a,style:n,onTransform:i,onTransformStart:s,onTransformEnd:l,onDoubleClick:p,onDragStart:c,onDragEnd:u,onDrag:m,onResizeStart:d,onResizeEnd:b,onResize:f,onRotateStart:y,onRotateEnd:g,onRotate:v,onSnap:_,isSnappable:h,elementGuidelines:x,hideAnchorOnDrag:R=true,title:P,rotationPosition:w,autoUpdate:C,bound:D,snapRotationDegrees:k,snapRotationThreshold:T,scrollableAncestor:$,renderDirections:I,stopPropagation:N,transformOrigin:E,preventDefault:j},B)=>{let O=useRef(null),H=useRef(null),[V,Q]=useState(document),F=useRef(V.createElement("div")),[Y,oe]=useState({}),[le,X]=useState(false),[Pe,Ie]=useState(false),[zt,ie]=useState(),fe=Kf(x,V);useLayoutEffect(()=>{let K=F.current;return F.current=V.createElement("div"),()=>{K.remove();}},[V]);let{keyboardProps:Bo}=useKeyboard({onKeyDown:K=>{let ce=K.shiftKey?10:1,ee=K.metaKey||K.ctrlKey;ee&&K.shiftKey&&(ce=45);function be(Je,Ao="x"){ee?H.current?.request("rotatable",{deltaRotate:Je*ce},true):H.current?.request("draggable",Ao==="x"?{deltaX:Je*ce}:{deltaY:Je*ce},true);}switch(K.key){case "ArrowRight":{be(1);break}case "ArrowLeft":{be(-1);break}case "ArrowUp":{be(-1,"y");break}case "ArrowDown":be(1,"y");}requestAnimationFrame(()=>{H.current?.updateRect();});}});useEffect(()=>{let K=ge(O.current);Q(K);let ce=F.current;K.body.append(F.current);function ee(Je){Ie(Je.shiftKey);}function be(){Ie(false);}return K.addEventListener("keydown",ee),K.addEventListener("keyup",be),()=>{K.removeEventListener("keydown",ee),K.removeEventListener("keyup",be),ce.remove();}},[]),Gf({scrollable:$,onScroll:()=>{H.current?.updateRect();},ownerDocument:V});let Ot=useCallback(K=>{oe(ce=>({...ce,...K.style})),i?.(K);},[i]),Ht=useCallback(K=>{if(X(true),O.current?.focus(),D){let ee=getHTMLElement(D,V)?.getBoundingClientRect();ie({position:"client",left:ee?.left??0,top:ee?.top??0,right:ee?.right??0,bottom:ee?.bottom??0});}c?.(K);},[D,V,c]),Vt=useCallback(K=>{X(false),u?.(K);},[u]),Z=t({style:{...Y.width&&{width:Y.width},...Y.height&&{height:Y.height}}});return jsxs(Fragment,{children:[jsx("div",{role:"button",...Bo,ref:M(O,B),style:{display:"inline-block",...n,...Y},className:classNames(Vf,e),onDoubleClick:p,tabIndex:0,title:P,children:Z}),createPortal(jsx(q2,{ref:H,target:O,draggable:a,resizable:r,rotatable:o,keepRatio:Pe,throttleDrag:1,snappable:h||!!D,elementGuidelines:fe,snapRenderThreshold:.9,className:Uf({isDragging:le&&R}),onRender:Ot,onDragStart:Ht,onDragEnd:Vt,useResizeObserver:C,useMutationObserver:C,onRenderEnd:l,onDrag:m,onResizeStart:d,onResizeEnd:b,onResize:f,onRotateStart:y,onRotateEnd:g,onRotate:v,onRenderStart:s,onSnap:_,rotationPosition:w,bounds:zt,snapRotationDegrees:k,snapRotationThreshold:T,renderDirections:I,stopPropagation:N,preventDefault:j,transformOrigin:E}),F.current)]})});Yf.displayName="Transform";var Xf={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 Qf=ht.forwardRef(({className:e,style:t,isInline:o=true,accept:r="image/*",defaultImageSrc:a,imageSrc:n,imageAlt:i,pickerButtonLabel:s,isDisabled:l,onDrop:p,onPaste:c,includeCheckeredBackground:u=true,"data-block-id":m,"data-block-class":d,pickerButtonStyle:b,pickerButtonClassName:f,footerClassName:y,footerStyle:g,clearLabel:v,placeholder:_,labelStyle:h,labelClassName:x,...R},P)=>{let w=ht.useRef(null),C=ht.useRef(null),{formatMessage:D}=A(Xf),[k,T]=useControlledState(n,a||null,ie=>{invariant(typeof ie!="string"),R.onValueChange?.(ie?[ie]:[]);}),$=useMemo(()=>nk(k||void 0),[k]),{fieldProps:I,labelProps:N}=useField(R),{dropProps:E,isDropTarget:j}=useDrop({ref:w,onDrop:async ie=>{if(l)return;let fe=await Ui({items:ie.items});fe.length&&T(fe[0]),p?.(ie);},...R}),{clipboardProps:B}=useClipboard({onPaste:async ie=>{if(l)return;let fe=await Ui({items:ie});fe.length&&T(fe[0]),c?.(ie);},...R}),O=()=>{T(null),C.current&&(C.current.value="");},H={type:"file",onChange:ie=>{let fe=[...ie.target.files];T(fe[0]),R.onChange?.(ie);},accept:r,disabled:l},{focusProps:V,isFocused:Q,isFocusVisible:F}=useFocusRing({within:true}),{hoverProps:Y,isHovered:oe}=useHover({isDisabled:l}),{imgProps:le,isLoading:X,isLoaded:Pe}=Xt({src:$,alt:i||""}),Ie={label:s||D("selectImage"),onPress:()=>w.current?.click(),variant:"secondary",isDisabled:l,excludeFromTabOrder:true,className:classNames(ta({isFocusVisible:F}),{[Mf]:j&&!l},f),style:b},zt=filterTruthyValues({"data-loaded":Pe,"data-block-id":m,"data-block-class":d,"data-hovered":oe,"data-focused":Q,"data-drop-target":j,"data-disabled":l,"data-focus-visible":F});return jsxs(S,{...zt,className:classNames("BaselineUI-ImageDropZone",e),display:"flex",flexDirection:"column",alignItems:"center",style:t,ref:P,children:[jsxs("label",{...mergeProps(E,Y,V,N),className:classNames(Xa({isInline:o,isHovered:oe,isDisabled:l,hasLoadedImage:!!$&&Pe,showFocusRing:j||!!$&&F}),x),style:h,ref:w,children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(I,B,H),ref:C})}),!$&&jsx(q,{...Ie}),!!$&&(X?jsx(po,{}):jsx("img",{className:Za({isInline:o,isDisabled:l,hasLoadedImage:!!$&&Pe&&u}),...le}))]}),_||v?jsx("div",{style:g,className:classNames(Ja({isInline:o,isDisabled:l}),y),children:($||!_)&&v?jsx(q,{size:"sm",variant:"ghost",label:v,isDisabled:l,onPress:O}):jsx(q,{size:"sm",variant:"ghost",label:_,isDisabled:true})}):null]})});Qf.displayName="ImageDropZone";function nk(e){return e instanceof File?URL.createObjectURL(e):e}var ey="_1vm2oh49 _1yep5z6ig _1yep5z6ih _1yep5z6ii _1yep5z6g4",ws="_1vm2oh48 _1yep5z6lo _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6k4 _1yep5z6k5 _1yep5z6k6",ty=z({defaultClassName:"_1vm2oh40 mnnh5s1 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6lt _1yep5z6lr _1yep5z6ic _1yep5z6lu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6la _1yep5z6lp _1yep5z6id _1yep5z6ie _1yep5z6if",variantClassNames:{accent:{theme:"_1vm2oh41",positive:"_1vm2oh42"},isInline:{true:"mnnh5s2 _1yep5z6wl _1yep5z6wm _1yep5z6wn _1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6xx _1yep5z6xy _1yep5z6xz _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z6137 _1yep5z6182 _1yep5z6184",false:"_1yep5z612h"},isFocusVisible:{true:"_1yep5z613j _1yep5z617w _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"mnnh5s8 z9nup82 _1yep5z6zd"},isHovered:{true:"_1vm2oh47"}},defaultVariants:{},compoundVariants:[[{accent:"positive",isInline:true},"_1yep5z61oi"],[{accent:"theme",isInline:true},"_1yep5z61o7"],[{accent:"positive",isInline:false},"_1yep5z61ok"],[{accent:"theme",isInline:false},"_1yep5z61o9"],[{isFocusVisible:true,isInline:true},"_1yep5z61q3 _1yep5z61tx _1yep5z61tz _1yep5z61u0"],[{isHovered:true,isInline:true},"_1yep5z61u0 _1yep5z61q3 _1yep5z61tx _1yep5z61tz"],[{isHovered:true,isInline:false,accent:"positive"},"_1yep5z61oj"],[{isHovered:true,isInline:false,accent:"theme"},"_1yep5z61ob"],[{isHovered:true,isInline:true,accent:"theme"},"_1yep5z61o8"]]});var ay=ht.forwardRef(({className:e,style:t,isDisabled:o,isInline:r=true,imageAlt:a,imageSrc:n,svgSrc:i,textValue:s,textStyle:l,onPress:p,onDelete:c,deleteAriaLabel:u,addAriaLabel:m,accent:d="positive","data-block-id":b,"data-block-class":f,...y},g)=>{let{focusProps:v,isFocused:_,isFocusVisible:h}=useFocusRing({within:true}),{isHovered:x,hoverProps:R}=useHover({isDisabled:o}),{pressProps:P}=usePress({isDisabled:o,onPress:p});invariant(n||i||s,"Preview must have content. You must provide either an `imageSrc`, `svgSrc`, or `textValue` prop.");let w=filterTruthyValues({"data-hovered":x,"data-focus-visible":h,"data-focused":_,"data-disabled":o});return jsxs("div",{...y,className:classNames(ty({isInline:r,isFocusVisible:h,isDisabled:o,isHovered:x,accent:d}),"BaselineUI-Preview",e),"data-block-id":b,"data-block-class":f,"aria-label":y["aria-label"]||a||s,style:t,ref:g,children:[typeof i=="string"?jsx("button",{disabled:o,...mergeProps(R,v,P,w),className:ws,"aria-label":m,dangerouslySetInnerHTML:{__html:i}}):jsxs("button",{...mergeProps(R,v,P,w),disabled:o,style:l,"aria-label":m,className:ws,children:[n?jsx("img",{src:n,alt:a,className:Za({isInline:r,isDisabled:o})}):null,!!i&&typeof i=="object"&&i,s]}),c?jsx(L,{isDisabled:o,className:ey,"aria-label":u,size:"xs",icon:TrashIcon,onPress:c}):null]})});ay.displayName="Preview";var ny="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69c _1yep5z69d _1yep5z69e",iy=z({defaultClassName:"cw3m0n5 _1yep5z6ew _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),sy="cw3m0n4",ly="_1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6lk",py=z({defaultClassName:"cw3m0n0 _1yep5z61j6 _1yep5z61j7 _1yep5z61j8 _1yep5z61ju _1yep5z61jv _1yep5z61jw _1yep5z61ki _1yep5z61kj _1yep5z61kk _1yep5z61l6 _1yep5z61l7 _1yep5z61l8 _1yep5z61nb _1yep5z61tg",variantClassNames:{isHovered:{true:"cw3m0n1"},isReadOnly:{true:"cw3m0n2"}},defaultVariants:{},compoundVariants:[[{isHovered:true,isReadOnly:false},"cw3m0n3"]]});var hk=({label:e,description:t},{isSelected:o,isFocusVisible:r,isDisabled:a,optionLabelPosition:n,isHovered:i,isReadOnly:s})=>jsxs("div",{className:Ra({labelPosition:n}),children:[jsx("div",{className:classNames($a({isSelected:o,isFocusVisible:r,isDisabled:a,isReadOnly:s,isHovered:i}),py({isHovered:i})),children:o?jsx("div",{className:sy}):null}),e?jsxs("div",{className:ny,children:[jsx("span",{className:Ia({isDisabled:a}),children:e}),t?jsx("span",{className:iy({isDisabled:a}),children:t}):null]}):null]}),dy=({state:e,renderOption:t=hk,item:o,optionLabelPosition:r="end",optionStyle:a,optionClassName:n,isReadOnly:i,...s})=>{let l=!!s.isDisabled||!!s.disabledValues?.includes(o.id),p=ht.useRef(null),{inputProps:c,isPressed:u,isSelected:m}=useRadio({...s,isDisabled:l,children:o.label,value:o.id},e,p),{focusProps:d,isFocusVisible:b,isFocused:f}=useFocusRing(),{hoverProps:y,isHovered:g}=useHover({isDisabled:l}),v=filterTruthyValues({"data-selected":m,"data-focused":f,"data-focus-visible":b,"data-hovered":g,"data-disabled":l,"data-pressed":u,"data-read-only":i});return jsxs("label",{...y,...v,style:a,className:classNames("BaselineUI-Radio-Item",n),children:[jsx(VisuallyHidden,{children:jsx("input",{...mergeProps(c,d),ref:p})}),t(o,{isFocusVisible:b,isSelected:m,isFocused:f,isHovered:g,isDisabled:l,optionLabelPosition:r,isReadOnly:i})]})};var my=ht.forwardRef(({className:e,style:t,optionsContainerClassName:o,optionsContainerStyle:r,items:a,labelPosition:n="top",renderOption:i,"aria-label":s,"aria-labelledby":l,"aria-describedby":p,"aria-details":c,"data-block-id":u,"data-block-class":m,...d},b)=>{let f=useRadioGroupState(d),{radioGroupProps:y,labelProps:g,descriptionProps:v,errorMessageProps:_}=useRadioGroup({...d,"aria-label":s,"aria-labelledby":l,"aria-describedby":p,"aria-details":c},f),h=_e({...d,descriptionProps:v,errorMessageProps:_,labelPosition:n}),x=filterTruthyValues({"data-orientation":d.orientation,"data-block-id":u,"data-block-class":m,"data-disabled":d.isDisabled,"data-readonly":d.isReadOnly});return jsxs("div",{...mergeProps(y,x),className:classNames(ot({labelPosition:n}),"BaselineUI-RadioGroup",e),style:t,ref:b,children:[d.label||h?jsxs("div",{className:tt({labelPosition:n,hasMessage:!!h}),children:[jsx("span",{...g,className:classNames(Wt,"BaselineUI-RadioGroup-Label"),children:d.label}),n==="start"&&h]}):null,jsx("div",{className:classNames(ly,{[Zt]:d.isDisabled},o),style:r,children:a.map(R=>jsx(dy,{state:f,renderOption:i,item:R,...d,value:R.id},R.id))}),n==="top"&&h]})});my.displayName="RadioGroup";var fy=({id:e,defaultMessage:t,elementType:o=Fragment$1})=>{invariant(e||t,"`id` or `defaultMessage` is required.");let r=A();return jsx(o,{children:r.formatMessage(e)||t})};fy.displayName="MessageFormat";var yy=ht.forwardRef(({className:e,style:t,children:o,"data-block-id":r,"data-block-class":a,role:n="group",isDisabled:i,...s},l)=>{let{hoverProps:p,isHovered:c}=useHover({isDisabled:i});return jsx("div",{...p,role:n,"data-hovered":c,"data-disabled":i,"data-block-id":r,"data-block-class":a,className:e,style:t,...s,ref:l,children:o})});yy.displayName="Group";var Ss="UNSUPPORTED_IN_MENU";function vy(e){return useMemo(()=>ht.Children.toArray(e).map(t=>{let o=t,r=uniqueId("item"),a=hr(o,je),n=gy(o),i,s;if(a){let g=hr(a,Oe);invariant(g),i=gy(g),s=hr(a,Le).props.children;}else n?i=n:i=o;let{onPress:l,label:p,"aria-label":c,iconStart:u,isDisabled:m,icon:d}=i.props,b=p||c||Ss;invariant(typeof b=="string","ActionGroup children must have a string label");let f=`${r}-${b}`;return createElement(Item,{...{key:f,onPress:l,textValue:b,"aria-label":c,icon:u||d,dialogContent:s,isDisabled:m},key:f},o)}),[e])}function hr(e,t){return t?flatMapDeep(ht.Children.toArray(e),r=>ht.isValidElement(r)&&r.props.children?[r,...ht.Children.toArray(r.props.children)]:[r]).find(r=>ht.isValidElement(r)&&r.type===t):void 0}function gy(e){return hr(e,q)||hr(e,L)}var _y="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6ln _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6lf",zy={horizontal:"xvr3wn0",vertical:"xvr3wn1"};var Fk=new Set(["text","search","password","tel","url"]);function tn(e,t){let{toolbarProps:o}=useToolbar(e,t);return {toolbarProps:{...o,onKeyDownCapture:r=>{if(r.target instanceof HTMLInputElement&&Fk.has(r.target.type)){let a=r.target.selectionStart===0,n=r.target.selectionEnd===r.target.value.length;(a&&r.key==="ArrowLeft"||n&&r.key==="ArrowRight")&&o.onKeyDownCapture?.(r);return}o.onKeyDownCapture?.(r);}}}}var Ms=ht.forwardRef(({className:e,style:t,children:o,collapsibleMenuProps:r,"data-block-id":a,"data-block-class":n,renderSpacer:i,onKeyDown:s,...l},p)=>{let{formatMessage:c}=A(),[u,m]=useState(),d=vy(o),b=useListState({...l,children:d}),f=ae(p),y=useRef(null),[{visibleItems:g,isMeasuring:v},_]=ei({visibleItems:b.collection.size,isMeasuring:false}),h=useCallback(()=>{let T=$=>{if(y.current&&f.current){let I=[...y.current.children],N=f.current.getBoundingClientRect().width,E=$<b.collection.size,j=0,B=0;if(E){let O=I.pop();O&&(j+=Py(O,false,true));}for(let[O,H]of I.entries())if(j+=Py(H,O===0,O===I.length-1),Math.round(j)<=Math.round(N))B++;else break;return B}return $};_(function*(){yield {visibleItems:b.collection.size,isMeasuring:true};let $=T(b.collection.size),I=$<b.collection.size&&$>0;yield {visibleItems:$,isMeasuring:I},I&&(yield {visibleItems:T($),isMeasuring:false});});},[_,f,b.collection.size]),x=useMemo(()=>({get current(){return f.current?.parentElement}}),[f]);pi({ref:x,onResize:h}),Se(h,[b.collection,h]);let{toolbarProps:R}=tn(l,f),P=[...b.collection],w=P.slice(0,g),C=P.slice(g).filter(T=>T.textValue!==Ss),D=C.length>0;useEffect(()=>{m(void 0);},[C.length]),useEffect(()=>{l.orientation==="vertical"&&console.warn("Toolbar: Vertical orientation is not supported when `isCollapsible` is true.");},[l.orientation]);let{keyboardProps:k}=useKeyboard({onKeyDown:s});return jsxs(FocusScope,{children:[jsx("div",{...mergeProps(R,k),className:e,"data-block-id":a,"data-block-class":n,"data-collapse":true,style:{...t,flexBasis:v?"100%":void 0},ref:f,children:jsxs("div",{ref:y,className:_y,children:[w.map(T=>T.rendered),D?jsxs(Fragment,{children:[!v&&i?jsx(S,{flexGrow:1}):null,jsx(ha,{placement:"bottom end",renderTrigger:({buttonProps:T,ref:$})=>jsx(L,{...T,size:"md",icon:MoreIcon,"aria-label":c(Yk.more),variant:"toolbar",ref:$,tooltip:true}),...r,disabledKeys:C.filter(T=>T.props?.isDisabled).map(T=>T.key),items:C.map(T=>{let $=T.textValue||T["aria-label"];return invariant($,"ActionItem must have a label"),{id:T.key,label:$,icon:T.props.icon}}),onAction:T=>{let $=b.collection.getItem(T);invariant($,"Item not found");let{onPress:I,dialogContent:N}=$.props;I?.(),m(N);}})]}):null]})}),jsx(Ee,{isOpen:!!u,onOpenChange:T=>{T||m(void 0);},children:jsx(Ue,{enableDrawer:"auto",style:{zIndex:1e5},children:u?ht.cloneElement(u,{inheritDrawer:true}):null})})]})});Ms.displayName="CollapsibleToolbar";function Py(e,t,o){let a=re(e).getComputedStyle(e);return e.getBoundingClientRect().width+(t?0:ky(a.marginLeft))+(o?0:ky(a.marginRight))}function ky(e){let t=Number.parseInt(e,10);return Number.isNaN(t)?0:t}var Yk=G({more:{id:"more",defaultMessage:"More"}});var Ns=ht.forwardRef(({className:e,style:t,"data-block-id":o,"data-block-class":r,"aria-controls":a,onKeyDown:n,...i},s)=>{let l=ht.useRef(null),{toolbarProps:p}=tn(i,l),{keyboardProps:c}=useKeyboard({onKeyDown:n});return jsx("div",{...mergeProps(p,c),"aria-controls":a,className:classNames(zy[i.orientation||"horizontal"],"BaselineUI-Toolbar",e),style:t,"data-block-id":o,"data-block-class":r,ref:M(s,l),children:i.children})});Ns.displayName="WrappedToolbar";var on=ht.forwardRef((e,t)=>{let o=e.isCollapsible?Ms:Ns;return jsx(o,{...e,ref:t})});on.displayName="Toolbar";var Iy=z({defaultClassName:"_1j5skr71",variantClassNames:{size:{xxs:"_1j5skr72",xs:"_1j5skr73",sm:"_1j5skr74",md:"_1j5skr75",lg:"_1j5skr76"}},defaultVariants:{},compoundVariants:[]}),Ry=z({defaultClassName:"_1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6g1 _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr7g"},isFocusVisible:{true:"_1j5skr7h"},isDisabled:{true:"z9nup82 _1yep5z611a"},isSelected:{true:"_1j5skr7j"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:true},"_1yep5z61u0 _1yep5z61tz _1yep5z61tx _1yep5z61qd _1yep5z61nd"],[{isSelected:false,isHovered:true,isDisabled:false},"_1yep5z6g3"],[{isSelected:false,isFocusVisible:true,isDisabled:false},"_1yep5z61u0 _1yep5z61tz _1yep5z61q3 _1yep5z61tx"],[{isSelected:true,isFocusVisible:true,isDisabled:false},"_1j5skr7k _1yep5z61ty _1yep5z61tx _1yep5z61q4 _1yep5z61ne"],[{isSelected:true,isFocusVisible:false,isDisabled:false},"_1yep5z61tx _1yep5z61tz _1yep5z61q3 _1yep5z61u0"]]}),$y=z({defaultClassName:"_1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr7m"},isFocusVisible:{true:"_1yep5z617x _1yep5z617w _1yep5z6140 _1yep5z617u"},isSelected:{true:"_1yep5z6119"},isDisabled:{true:"z9nup82 _1yep5z611a"}},defaultVariants:{},compoundVariants:[[{isSelected:false,isHovered:true},"_1yep5z61nc"]]}),Ty=z({defaultClassName:"_1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr7r"},isFocusVisible:{true:"_1yep5z617x _1yep5z617w _1yep5z6140 _1yep5z617u"},isSelected:{true:"_1j5skr7t"},isDisabled:{true:"z9nup82 _1yep5z611a"}},defaultVariants:{},compoundVariants:[[{isSelected:false,isHovered:true},"_1yep5z61o9"],[{isSelected:true,isDisabled:false},"_1yep5z61o9 _1yep5z61ng"],[{isSelected:true,isDisabled:true},"_1yep5z61o9 _1yep5z61nd"]]}),Sy=z({defaultClassName:"_1j5skr77 _1j5skr70 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lp _1yep5z6lq _1yep5z6lk _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6f5",variantClassNames:{isHovered:{true:"_1j5skr78"},isFocusVisible:{true:"_1j5skr79"},isSelected:{true:"_1j5skr7a"},isDisabled:{true:"_1j5skr7b z9nup82 _1yep5z611c"}},defaultVariants:{},compoundVariants:[[{isSelected:true,isDisabled:false},"_1j5skr7c _1yep5z61nf"],[{isSelected:false,isDisabled:true},"_1j5skr7d _1yep5z61nd"],[{isSelected:false,isHovered:true},"_1yep5z61o9"],[{isSelected:false,isFocusVisible:true},"_1yep5z61u0 _1yep5z61tz _1yep5z61q3 _1yep5z61tx"],[{isSelected:true,isFocusVisible:true},"_1j5skr7e _1yep5z61ty _1yep5z61tx _1yep5z61q4"]]});var lw={xxs:8,xs:12,sm:16,md:20,lg:24},we=ht.forwardRef((e,t)=>{let o=ae(t),{tooltipProps:r}=Jr(e,o);return r?jsx(J,{...r,children:jsx(Es,{...e,ref:t})}):jsx(Es,{...e,ref:t})});we.displayName="ToggleIconButton";var Es=ht.forwardRef(({className:e,style:t,icon:o,size:r="md",variant:a="primary","data-block-id":n,"data-block-class":i,...s},l)=>{let p=useToggleState(s),{buttonProps:c,isPressed:u,ref:m,isFocusVisible:d,isFocused:b,isHovered:f,uiStateOptions:y}=ea(s,p),g=useMemo(()=>typeof o=="function"?o:p.isSelected?o.selected:o.unselected,[o,p.isSelected]),v={isSelected:p.isSelected,isHovered:f,isFocusVisible:d,isDisabled:!!s.isDisabled},_=filterTruthyValues({"data-hovered":f,"data-selected":p.isSelected,"data-focus-visible":d,"data-disabled":s.isDisabled,"data-block-id":n,"data-block-class":i,"data-focused":b,"data-pressed":u});return jsx("button",{...mergeProps(c,_),className:classNames(a==="toolbar"&&Sy(v),a==="primary"&&Ry(v),a==="secondary"&&$y(v),a==="tertiary"&&Ty(v),Iy({size:r}),"BaselineUI-ToggleIconButton",typeof e=="function"?e(y):e),style:typeof t=="function"?t(y):t,ref:M(m,l),children:jsx(g,{size:lw[r]})})});Es.displayName="ToggleIconButtonCore";var My="f6jv6bl",Ny="_1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z6js _1yep5z6jt _1yep5z6ju",ho="_1yep5z689 _1yep5z68a _1yep5z68b _1yep5z65x _1yep5z65y _1yep5z65z",Ey=z({defaultClassName:"f6jv6b0 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6g1",variantClassNames:{isInline:{true:"f6jv6b1"},isMinimal:{true:"_1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z6vo _1yep5z6vp _1yep5z6vq _1yep5z615m _1yep5z615n _1yep5z615o",false:"_1yep5z6157 _1yep5z6158 _1yep5z6159"}},defaultVariants:{},compoundVariants:[[{isInline:true,isMinimal:false},"_1yep5z61ir _1yep5z61is _1yep5z61it _1yep5z61jf _1yep5z61jg _1yep5z61jh _1yep5z61k3 _1yep5z61k4 _1yep5z61k5 _1yep5z61kr _1yep5z61ks _1yep5z61kt _1yep5z61u7 _1yep5z61u5 _1yep5z61pa"]]}),rn=z({defaultClassName:"f6jv6b4 _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6e3 _1yep5z6eu _1yep5z6lq",variantClassNames:{isDisabled:{true:"f6jv6b5 _1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),Ly="f6jv6bi _1yep5z6wr _1yep5z6ws _1yep5z6wt _1yep5z6xf _1yep5z6xg _1yep5z6xh _1yep5z6y3 _1yep5z6y4 _1yep5z6y5 _1yep5z6yr _1yep5z6ys _1yep5z6yt",By="f6jv6bj";var Ay="f6jv6bm _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6ly _1yep5z6lt _1yep5z6lr _1yep5z6hx _1yep5z6eu",Fy=z({defaultClassName:"f6jv6bf _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6lq _1yep5z6la _1yep5z6ld _1yep5z6lp",variantClassNames:{isHovered:{true:"_1yep5z6126"},isDisabled:{true:"_1yep5z6zd"}},defaultVariants:{},compoundVariants:[]}),jy="_1yep5z6jy _1yep5z6jz _1yep5z6k0",Oy="f6jv6be f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6ip _1yep5z6iq _1yep5z6ir _1yep5z6eu _1yep5z6e3 _1yep5z6ln",Hy=z({defaultClassName:"f6jv6bb _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6k4 _1yep5z6k5 _1yep5z6k6",variantClassNames:{isInline:{true:"_1yep5z6pr _1yep5z6ps _1yep5z6pt _1yep5z6184 _1yep5z6182 _1yep5z6137",false:"_1yep5z6pu _1yep5z6pv _1yep5z6pw _1yep5z6x6 _1yep5z6x7 _1yep5z6x8 _1yep5z6xu _1yep5z6xv _1yep5z6xw _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8"}},defaultVariants:{},compoundVariants:[]}),Vy="f6jv6bk",Uy="f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6ip _1yep5z6iq _1yep5z6ir _1yep5z6eu",an=z({defaultClassName:"f6jv6b6",variantClassNames:{isInline:{true:"f6jv6b7",false:"f6jv6b8"}},defaultVariants:{},compoundVariants:[]}),nn="f6jv6b9 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl",Cr="f6jv6bn";var Ky=[["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:Pr}}=layoutSprinkleValues,Gy=({isOpen:e,onClose:t})=>{let{formatMessage:o}=A(),r=useId();return jsx(Ee,{isOpen:e,onOpenChange:a=>{a||t();},children:jsx(Ue,{enableDrawer:"auto",style:{zIndex:999999},children:jsxs(xe,{"aria-labelledby":r,className:Ly,drawerBackground:"subtle",children:[jsxs(S,{paddingLeft:Pr.padding.horizontal.lg,paddingRight:Pr.padding.horizontal.sm,display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",backgroundColor:"background.primary.subtle",className:By,children:[jsx(te,{id:r,elementType:"h3",type:"title",size:"md",children:o(kr.help)}),jsx(L,{icon:XIcon,size:"md",variant:"secondary","aria-label":o(kr.close),onPress:t})]}),jsx(U,{className:Vy}),jsxs(S,{paddingX:Pr.padding.horizontal.lg,role:"table","aria-labelledby":r,backgroundColor:"background.primary.subtle",children:[jsx("div",{role:"rowgroup",children:jsxs(S,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Pr.padding.vertical.md,color:"text.primary",children:[jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",children:o(kr.action)}),jsx("h6",{className:sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",style:{textTransform:"capitalize"},children:o(kr.shortcut)})]})}),jsx("div",{role:"rowgroup",children:Ky.map(([a,n],i)=>jsxs(Fragment$1,{children:[jsxs(S,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Pr.padding.vertical.xs,style:{minHeight:40},children:[jsx(te,{type:"subtitle",size:"sm",role:"cell",children:o(kr[camelCase(a)])}),jsx(te,{elementType:"kbd",type:"subtitle",size:"sm",role:"cell",children:getOsSpecificKeyboardShortcutLabel(n,true)})]}),i!==Ky.length-1&&jsx(U,{})]},a))})]})]})})})},kr=G({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 sn=ht.forwardRef(({value:e,defaultValue:t,onChange:o,placeholder:r,spellCheck:a,textBoxRef:n,isInline:i,isMinimal:s,isDisabled:l,editableContentAriaLabel:p,editorHandle:c,autoFocus:u,saveOnEnter:m,onSave:d},b)=>{let f=ht.useRef(null),[y,g]=useControlledState(e,t||"",o),v=useCallback(k=>{g(k.currentTarget.value||"");},[g]),_=useCallback(k=>{(m&&k.key==="Enter"&&!k.shiftKey||(k.ctrlKey||k.metaKey)&&k.key==="Enter")&&(k.preventDefault(),d());},[m,d]);useImperativeHandle(b,()=>({clear:()=>{g("");}}));let h=useCallback(k=>{k.currentTarget.style.height="16px",k.currentTarget.style.height=k.currentTarget.scrollHeight+"px";},[]);useGranularLayoutEffect(()=>{let k=f.current;k&&(k.style.height="16px",k.style.height=k.scrollHeight+"px");},[s],[y]),useImperativeHandle(c,()=>({setCaretPosition:k=>{f.current&&(f.current.focus(),f.current.setSelectionRange(k,k));},focus:()=>{f.current&&f.current.focus();}}));let{focusProps:x,isFocused:R,isFocusVisible:P}=useFocusRing(),{hoverProps:w,isHovered:C}=useHover({}),D=filterTruthyValues({"data-focus-visible":P,"data-hovered":C,"data-focused":R});return jsx("textarea",{...mergeProps(x,w,D),ref:M(f,n),className:classNames(s?Oy:[rn(),an({isInline:i}),Uy]),autoFocus:u,onChange:v,disabled:l,onInput:h,value:y,placeholder:r,spellCheck:a,"aria-label":p,onKeyDown:_})});sn.displayName="PlainEditor";var Rr="mention",ln="mention_input",n1=ht.forwardRef(({onCancel:e,editor:t,element:o,onSelectionChange:r},a)=>{let{containerRef:n,items:i,maxMentionableUsersSuggestions:s}=useContext(cn),l=useSelected(),[p,c]=useState(""),{contains:u}=useFilter({sensitivity:"base"}),{formatMessage:m}=A(),d=useMemo(()=>{let I=i.filter(N=>p===""||u(N.displayName,p)).map(N=>({id:N.id,label:N.displayName,data:N}));return s?take(I,s):I},[i,s,p,u]),b=useCallback(I=>jsx(Item,{children:I.label},I.id),[]),f=useCallback((I=false)=>{let N=findNodePath(t,o);N&&(removeNodes(t,{at:N}),I&&focusEditor(t));},[t,o]),y=useComboBoxState({items:d,children:b,menuTrigger:"focus",onSelectionChange:I=>{f(true),r?.(I);}}),g=ht.useRef(null),v=ht.useRef(null),_=ht.useRef(null),h=ht.useRef(null),x=useHTMLInputCursorState(v);useInteractOutside({ref:h,onInteractOutside:()=>{y.close();}});let{inputProps:R,listBoxProps:P}=useComboBox({defaultItems:d,inputRef:v,buttonRef:g,listBoxRef:_,popoverRef:h,menuTrigger:"focus","aria-label":m(Uw.mention)},y);useEffect(()=>{v.current?.focus();},[]);let w=useCallback((I="manual",N=false)=>{f(N),e?.(I,y.inputValue);},[e,f,y.inputValue]),C=useRef(l);useEffect(()=>{C.current&&!l&&w("deselect"),C.current=l;},[l,w]);let D=x?.atStart??false,k=x?.atEnd??false,T=useCallback(I=>{I.key==="Backspace"&&D?w("backspace",true):I.key==="Escape"?w("escape",true):I.key==="ArrowLeft"&&D?w("arrowLeft",true):I.key==="ArrowRight"&&k&&w("arrowRight",true);let N=Hotkeys.isUndo(I)&&t.history.undos.length>0,E=Hotkeys.isRedo(I)&&t.history.redos.length>0;(N||E)&&(I.preventDefault(),t[N?"undo":"redo"](),focusEditor(t));},[D,k,w,t]),$=useMemo(()=>{if(!CSS.supports("field-sizing","content")){let I=re(v.current),N=v.current?I?.getComputedStyle(v.current).font:void 0;return {width:N?getTextDimensions({text:y.inputValue,font:N}).width+10:"4ch"}}},[y.inputValue]);return jsxs(Ct.Provider,{value:y,children:[jsx("input",{...mergeProps(R,{onKeyDown:T,onBlur:()=>{w("blur",true);},onChange:I=>{c(I.target.value);}}),style:$,className:Ay,ref:M(a,v)}),jsx(ke,{triggerRef:n,isNonModal:true,ref:h,state:y,crossOffset:-2,children:jsx(me,{...P,items:void 0,autoFocus:"first",ref:_,className:classNames(at,sprinkles({width:"full"})),renderOption:s1})})]})});n1.displayName="MentionInputContentElement";var js=withRef(({className:e,...t},o)=>{let{children:r,editor:a,element:n}=t,{items:i}=useContext(cn),s=useRef(null),[l,p]=useState(null);useEffect(()=>{let m=findNodePath(a,n);if(!m)return;let d=getPointBefore(a,m);if(!d)return;let b=createPointRef(a,d);return p(b),()=>{b.unref();}},[a,n]);let c=useCallback(()=>{let m=s.current?.getRootNode()instanceof ShadowRoot;moveSelection(a,{unit:"offset"}),moveSelection(a,{unit:"character",distance:1}),Fo()&&m&&focusEditor(a);},[a]),u=useCallback(m=>{if(!m)return;let d=s.current?.getRootNode()instanceof ShadowRoot,b=i.find(y=>y.id===m);invariant(b,"User not found");let f={type:Rr,value:b.id,displayName:b.displayName,children:[{text:""}]};insertNodes(a,[f,{text:" "}]),d?setTimeout(()=>{c();},0):c();},[a,i,c]);return jsxs(PlateElement,{as:"span","data-slate-value":n.value,contentEditable:false,className:e,ref:o,...t,children:[jsx(n1,{onCancel:(m,d)=>{m!=="backspace"&&insertText(a,"@"+d,{at:l?.current??void 0}),(m==="arrowLeft"||m==="arrowRight")&&moveSelection(a,{distance:1,reverse:m==="arrowLeft"});},onSelectionChange:u,ref:s,element:n,editor:a}),r]})});js.displayName="MentionInputElement";var Os=withRef(({className:e,onClick:t,children:o,...r},a)=>{let n=useElement();return jsxs(PlateElement,{as:"span",className:e,contentEditable:false,"data-user-id":n.value,onClick:getHandler(t,n),ref:a,...r,children:["@",n.displayName,o]})});Os.displayName="MentionElement";var i1=(e,{options:{trigger:t,triggerPreviousCharPattern:o,triggerQuery:r}})=>{let{insertText:a}=e,n=i=>i===t;return e.insertText=i=>{if(!e.selection||!n(i)||r&&!r(e)){a(i);return}let s=getEditorString(e,getRange(e,e.selection,getPointBefore(e,e.selection)));if(o?.test(s)){pn(e);return}a(i);},e},Uw=G({mention:{defaultMessage:"Mention",id:"mention"}});function p1({className:e,children:t,...o}){return jsx(PlateElement,{asChild:true,className:e,...o,children:jsx("p",{children:t})})}function iI(e){return Object.entries(e).map(([t,o])=>`${kebabCase(t)}:${o}`).filter(([,t])=>!!t).join(";")}function sI(e){return "text"in e}function lI(e){return e.replaceAll("&","&amp;").replaceAll("<","&lt;").replaceAll(">","&gt;").replaceAll('"',"&quot;").replaceAll("'","&#039;")}function $r(e){if(!e)return "";function t(o){if(sI(o)){let a=lI(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="${iI(filterTruthyValues({color:o.color||void 0,backgroundColor:o.backgroundColor||void 0}))}">${a}</span>`),a}let r=o.children?.map($r).join("");switch(o.type){case ELEMENT_PARAGRAPH:return `<p>${r}</p>`;case ELEMENT_LINK:return `<a href="${o.url}">${r}</a>`;case Rr: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 pI(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 Ks(e){e.startsWith("<p>")||(e=`<p>${e}</p>`);let t=new DOMParser().parseFromString(c1.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")?`
11
+ `:"<p>";return u1(t.body)}function u1(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=true;break}case "I":{o.italic=true;break}case "EM":{o.italic=true;break}case "U":{o.underline=true;break}case "SPAN":{let a=pI(e.getAttribute("style")||"");a["text-decoration"]==="underline"&&(o.underline=true),a.color&&(o.color=a.color),a.backgroundColor&&(o.backgroundColor=a.backgroundColor);break}}let r=[...e.childNodes].flatMap(a=>u1(a,o));switch(r.length===0&&r.push(jsx$1("text",o,"")),e.nodeName.toUpperCase()){case "BR":return jsx$1("text",t,`
12
+ `);case "SPAN":{let a=e.dataset.userId;return a?jsx$1("element",{type:Rr,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 m1(e){let t=findNode(e,{match:{type:getPluginType(e,ELEMENT_LINK)}}),[o]=t||[{url:""}];return o?.url}function pn(e){let t={children:[{text:" "}],type:ln};e.insertNode(t);}var cI=createPluginFactory({isElement:true,isInline:true,isMarkableVoid:true,isVoid:true,key:Rr,options:{trigger:"@",triggerPreviousCharPattern:/^$|^[\s"']$/},plugins:[{isElement:true,isInline:true,isVoid:true,key:ln}],withOverrides:i1}),f1=createPlugins([createParagraphPlugin({component:p1}),createBoldPlugin({component:withProps(PlateLeaf,{as:"b"})}),createItalicPlugin({component:withProps(PlateLeaf,{as:"i"})}),createUnderlinePlugin({component:withProps(PlateLeaf,{as:"u"})}),createFontColorPlugin(),createFontBackgroundColorPlugin(),createLinkPlugin({component:y1}),cI({component:Os})],{components:{[ln]:js}});var Mt={Add:"add",Edit:"edit",Show:"show"},_1=({isDisabled:e})=>{let{formatMessage:t}=A(),o=useEditorRef();return jsxs(je,{type:"dialog",children:[jsx(Oe,{children:jsx(L,{icon:LinkIcon,size:"sm",isDisabled:e,"aria-label":t(Nt.addLink),className:ho,preventFocusOnPress:true})}),jsx(Le,{className:sprinkles({boxShadow:"medium"}),placement:"top end",children:({close:r})=>jsx(xe,{size:"content",style:{minWidth:240},children:jsx(vI,{close:()=>{r(),setTimeout(()=>{focusEditor(o,o.selection);},0);}})})})]})},vI=({close:e})=>{let t=useEditorRef(),{formatMessage:o}=A(),r=useEditorSelector(p=>m1(p),[]),[a,n]=ht.useState(r?Mt.Show:Mt.Add),[i,s]=ht.useState(r||""),l=jsx(S,{padding:"lg",children:jsx(nt,{label:o(Nt.link),value:i,autoFocus:true,onChange:s,placeholder:"https://yourdomain.com"})});return jsxs(Fragment,{children:[a===Mt.Add&&jsxs(Fragment,{children:[l,jsx(S,{display:"flex",justifyContent:"flex-end",padding:"lg",className:My,children:jsx(q,{isDisabled:!isUrl(i,true),label:o(Nt.addLink),size:"sm",onPress:()=>{upsertLink(t,{url:i,skipValidation:true}),e?.();},preventFocusOnPress:true})})]}),a===Mt.Show&&jsxs(Fragment,{children:[jsx(S,{padding:"lg",children:jsx(te,{type:"subtitle",size:"sm",children:r})}),jsxs(S,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(q,{label:o(Nt.editLink),size:"sm",variant:"secondary",onPress:()=>{n(Mt.Edit);},style:{flex:1,justifyContent:"center"}}),jsx(q,{label:o(Nt.removeLink),size:"sm",onPress:()=>{unwrapLink(t),e?.();},preventFocusOnPress:true,style:{flex:1,justifyContent:"center"}})]})]}),a===Mt.Edit&&jsxs(Fragment,{children:[l,jsxs(S,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsx(q,{label:o(Nt.cancel),size:"sm",variant:"secondary",onPress:()=>{n(Mt.Show),e?.();}}),jsx(q,{label:o(Nt.save),size:"sm",onPress:()=>{upsertLink(t,{url:i,skipValidation:true}),e?.();}})]})]})]})};function y1({className:e,children:t,...o}){return jsx(PlateElement,{asChild:true,className:e,...o,children:jsx("a",{className:xa({size:"sm"}),children:t})})}var Nt=G({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 zI=parseColor("#ffffff00").toString("hexa"),Gs=[{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"}];[...Gs,{label:"Transparent",color:zI}];var un=({nodeType:e,icon:t,ariaLabel:o,isDisabled:r})=>{let a=useEditorSelector(i=>isMarkActive(i,e),[]),n=useEditorRef();return jsx(we,{variant:"tertiary",isSelected:a,size:"sm",icon:t,"aria-label":o,isDisabled:r,onPress:()=>{toggleMark(n,{key:e});},preventFocusOnPress:true})},Ys=({nodeType:e,"aria-label":t,isDisabled:o})=>{let{updateColor:r,clearColor:a,color:n}=useColorDropdownMenuState({customColors:[],colors:[],nodeType:e}),i=useCallback(({ref:l,triggerProps:p})=>jsx(L,{icon:e==="color"?TextIcon$1:HighlightTextIcon,"aria-label":t,size:"md",variant:"popover",isDisabled:o,className:ho,preventFocusOnPress:true,...p,ref:l}),[e,t,o]),s=useCallback(l=>{l?r(l.toString("rgba")):a();},[a,r]);return jsx(go,{presets:Gs,allowRemoval:true,pickerMode:"lazy",placement:"top end",colorLabel:false,renderTriggerButton:i,value:n||"#000000",onChange:s,isDisabled:o})};var XI=[{type:ELEMENT_PARAGRAPH,children:[{text:""}]}],cn=ht.createContext({items:[],containerRef:{current:null},maxMentionableUsersSuggestions:10}),Js=ht.forwardRef(({value:e,defaultValue:t,onChange:o,style:r,spellCheck:a,placeholder:n,isInline:i,isDisabled:s,editableContentAriaLabel:l,containerRef:p,onHelpDialogOpenRequest:c,mentionableUsers:u,editorHandle:m,maxMentionableUsersSuggestions:d,autoFocus:b,editorRef:f,saveOnEnter:y,onSave:g},v)=>{let _=useRef(null),h=useId(),{formatMessage:x}=A(),R=useRef(null),P=R.current,w=useRef(null),C=useMemo(()=>P?.getRootNode()instanceof ShadowRoot,[P]),[D,k]=useControlledState(e?Ks(e):void 0,Ks(t||"<p></p>"),I=>{o&&o($r(I));}),{keyboardProps:T}=useKeyboard({onKeyDown:I=>{(y&&I.key==="Enter"&&!I.shiftKey||(I.ctrlKey||I.metaKey)&&I.key==="Enter")&&(I.preventDefault(),g()),I.altKey&&I.key==="F10"?(I.preventDefault(),_.current&&_.current.querySelector("button")?.focus()):I.continuePropagation(),Fo()&&C&&w.current&&focusEditor(w.current);}});useEffect(()=>{s&&w.current&&deselect(w.current);},[s]),useImperativeHandle(v,()=>({startMention:()=>{w.current&&!R.current?.querySelector("input[role='combobox']")&&pn(w.current);}})),useImperativeHandle(m,()=>({setCaretPosition:I=>{w.current&&(focusEditor(w.current),moveSelection(w.current,{distance:I,unit:"character"}));},focus:()=>{w.current&&focusEditor(w.current);}}));let $=useMemo(()=>({items:u||[],containerRef:p,maxMentionableUsersSuggestions:d}),[u,p,d]);return jsx(cn.Provider,{value:$,children:jsxs(Plate,{initialValue:D||XI,plugins:f1,editorRef:M(w,f||null),onChange:I=>{k(I);},children:[jsxs(on,{className:nn,"aria-controls":h,ref:_,children:[jsxs(S,{display:"flex",flexDirection:"row",role:"group",gap:"xs",paddingX:"sm",children:[jsx(un,{nodeType:MARK_BOLD,icon:BoldIcon,ariaLabel:x(ko.bold),isDisabled:s}),jsx(un,{nodeType:MARK_ITALIC,icon:ItalicIcon,ariaLabel:x(ko.italic),isDisabled:s}),jsx(un,{nodeType:MARK_UNDERLINE,icon:UnderlineIcon,ariaLabel:x(ko.underline),isDisabled:s})]}),jsx(U,{orientation:"vertical",className:Cr}),jsx(Ys,{nodeType:MARK_COLOR,"aria-label":x(ko.fontColor),isDisabled:s}),jsx(U,{orientation:"vertical",className:Cr}),jsx(Ys,{nodeType:MARK_BG_COLOR,"aria-label":x(ko.backgroundColor),isDisabled:s}),jsx(U,{orientation:"vertical",className:Cr}),jsx(_1,{isDisabled:s}),jsx(U,{orientation:"vertical",className:Cr}),jsx(L,{className:ho,icon:QuestionmarkCircleIcon,size:"sm","aria-label":x(ko.help),onPress:c})]}),jsx(U,{variant:"secondary"}),jsx("div",{...T,ref:R,children:jsx(PlateContent,{id:h,disabled:s,readOnly:s,style:r,placeholder:n,autoFocus:b,spellCheck:a,"aria-label":l,className:classNames(rn({isDisabled:s}),an({isInline:i})),renderPlaceholder:({attributes:I,children:N})=>jsx("span",{...I,className:sprinkles({paddingY:"lg"}),children:N})})})]})})});Js.displayName="RichEditor";var s1=({key:e,value:t},{isDisabled:o,optionProps:r,isFocused:a,_state:n},i)=>{let{hoverProps:s}=useHover({isDisabled:o}),{label:l,data:p}=t;return jsxs(Fragment,{children:[jsxs("li",{...mergeProps(r,s),className:Fy({isDisabled:o,isHovered:a}),"data-active":a,ref:i,children:[jsx(fo,{name:l,...p?.avatar}),jsxs(S,{display:"flex",flexDirection:"column",children:[jsx(te,{type:"subtitle",size:"sm",children:l}),jsx(te,{type:"helper",size:"sm",children:p?.description})]})]}),e===n.collection.getLastKey()?null:jsx(U,{})]})},ko=G({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 k1=ht.memo(ht.forwardRef(({className:e,style:t,"data-block-id":o,"data-block-class":r,enableRichText:a=false,onCancel:n,onSave:i,isInline:s=true,submitButtonIcon:l=ArrowUpCircleFilledIcon,submitButtonAriaLabel:p,cancelButtonAriaLabel:c,"aria-label":u,"aria-describedby":m,"aria-labelledby":d,"aria-details":b,editableContentAriaLabel:f="Editing Area",footerButtons:y,clearOnCancel:g,clearOnSave:v,..._},h)=>{let x=useRef(null),{formatMessage:R}=A(),P=useRef(null),w=useRef(null),C=useRef(null),D=!a&&_.variant==="minimal",k=useRef(null),[T,$]=ht.useState(_.value||_.defaultValue),I=_.isDisabled||_.isSaveDisabled||!getPlainText(T||""),{fieldProps:N}=useLabel({"aria-label":u,"aria-labelledby":d,"aria-describedby":m,"aria-details":b,labelElementType:"div"});D&&!_.avatarName&&console.warn("Editor: When using the minimal `variant` and `enableRichText` is `false`, you should provide an `avatarName`.");let E=useCallback(()=>{$(""),a?x.current?.reset():w.current?.clear();},[a]),j=useCallback(()=>{I||(i?.(a?$r(x.current?.children):P.current.value),v&&E());},[E,v,a,i,I]),B=jsx(L,{variant:"ghost","aria-label":p||R(el.save),icon:l,isDisabled:I,size:"md",excludeFromTabOrder:D,className:D?jy:void 0,onPress:j,preventFocusOnPress:true}),[O,H]=ht.useState(false),{keyboardProps:V}=useKeyboard({onKeyDown:F=>{(F.metaKey||F.ctrlKey)&&F.shiftKey&&F.key==="h"&&(F.preventDefault(),H(true));}}),Q=useCallback(F=>{$(F),_.onChange?.(F);},[_]);return jsxs("div",{...mergeProps(N,a?V:{}),role:"application",ref:M(C,h),style:t,"data-block-id":o,"data-block-class":r,className:classNames(Ey({isInline:s,isMinimal:D}),"BaselineUI-Editor",e),"aria-disabled":_.isDisabled,children:[D?jsxs(Fragment,{children:[s?jsx(fo,{className:Ny,name:_.avatarName||""}):null,jsxs("div",{className:Hy({isInline:s}),children:[jsx(sn,{isMinimal:D,textBoxRef:P,isInline:s,editableContentAriaLabel:f,..._,onChange:Q,onSave:j}),B]})]}):jsxs(Fragment,{children:[a?jsx(Js,{containerRef:C,ref:k,editorRef:x,isInline:s,editableContentAriaLabel:f,onHelpDialogOpenRequest:()=>{H(true);},..._,onChange:Q,onSave:j}):jsxs(Fragment,{children:[!s&&jsx(U,{variant:"secondary"}),jsx(sn,{onCancel:n,textBoxRef:P,ref:w,isInline:s,editableContentAriaLabel:f,..._,onChange:F=>{$(F),_.onChange?.(F);},onSave:j})]}),jsx(U,{variant:"secondary"}),jsxs("div",{className:classNames(nn,sprinkles({justifyContent:"space-between"})),children:[jsxs(S,{paddingX:"sm",gap:"sm",display:"flex",children:[a&&_.mentionableUsers?jsx(L,{icon:AtIcon,size:"sm","aria-label":R(el.mention),onPress:()=>k.current?.startMention(),preventFocusOnPress:true}):null,y?.map(({type:F,props:Y},oe)=>F==="action"?jsx(L,{...Y,size:"sm",isDisabled:_.isDisabled||Y.isDisabled},oe):jsx(we,{...Y,size:"sm",variant:"tertiary",isDisabled:_.isDisabled||Y.isDisabled},oe))]}),jsxs(S,{children:[!!n&&jsx(L,{variant:"secondary",icon:XCircleFilledIcon,isDisabled:_.isDisabled,size:"md",onPress:()=>{n(),g&&E();},"aria-label":c||R(el.cancel)}),B]})]})]}),jsx(Gy,{isOpen:O,onClose:()=>{H(false);}})]})}));k1.displayName="Editor";var el=G({cancel:{defaultMessage:"Cancel",id:"cancel"},save:{defaultMessage:"Save",id:"save"},mention:{defaultMessage:"Mention",id:"mention"}});var w1="_8kqf970 _1yep5z6po _1yep5z6pp _1yep5z6pq _1yep5z6m6 _1yep5z6m7 _1yep5z6m8 _1yep5z6oi _1yep5z6oj _1yep5z6ok _1yep5z614v _1yep5z614w _1yep5z614x _1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z615m _1yep5z615n _1yep5z615o _1yep5z6z9 _1yep5z6vi _1yep5z6vj _1yep5z6vk _1yep5z617s _1yep5z6101";var R1=2,T1=ht.forwardRef(({className:e,style:t,hideForKeyboard:o,scrollRef:r,label:a,delay:n=1500,smoothScroll:i=true,"data-block-id":s,"data-block-class":l},p)=>{let c=ht.useRef(null),u=useInteractionModality(),[m,d]=ht.useState(false),b=useCallback(()=>{let C=r?.current||ge(c.current).body;return re(C).getComputedStyle(C).flexDirection==="column-reverse"?C.scrollTop+R1>=0:C.scrollTop+C.clientHeight+R1>=C.scrollHeight},[r]),[f,y]=ht.useState(b),{buttonProps:g,isPressed:v}=useButton({onPress:()=>{let C=r?.current||ge(c.current).body;C.scrollTo({top:C.scrollHeight,behavior:i?"smooth":"auto"});}},c),{focusProps:_,isFocused:h,isFocusVisible:x}=useFocusRing(),{hoverProps:R,isHovered:P}=useHover({}),w=filterTruthyValues({"data-block-id":s,"data-block-class":l,"data-pressed":v,"data-focus-visible":x,"data-hovered":P,"data-focused":h});return useEffect(()=>{y(b());},[b]),useEffect(()=>{let C=r?.current||ge(c.current).body,D="onscrollend"in re(C),k=()=>{setTimeout(()=>{d(false),y(b());},n);},T=()=>{d(true),D||k();};return C.addEventListener("scroll",T),C.addEventListener("scrollend",k),()=>{C.removeEventListener("scroll",T),C.removeEventListener("scrollend",k);}},[r,n,b]),jsx(AnimatePresence,{initial:false,children:(!o||u!=="keyboard")&&!m&&!f?jsxs(motion.button,{initial:{opacity:0,transform:"translateX(-50%) translateY(10px)"},animate:{opacity:1,transform:"translateX(-50%) translateY(0)"},exit:{opacity:0,transform:"translateX(-50%) translateY(10px)"},transition:{duration:.3},...mergeProps(g,_,R,w),className:classNames(w1,Ta({isFocusVisible:x,variant:"high-contrast",isHovered:P}),Sa({variant:"high-contrast"}),"BaselineUI-ScrollControlButton",e),style:t,ref:M(p,c),children:[jsx(ArrowDownCircleFilledIcon,{size:16,className:ar({variant:"high-contrast"})}),a]}):null})});T1.displayName="ScrollControlButton";var ol="_1yep5z6k4 _1yep5z6k5 _1yep5z6k6 _1yep5z6kd _1yep5z6ke _1yep5z6kf",S1=z({defaultClassName:"_1v0p2z10 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69f _1yep5z69g _1yep5z69h",variantClassNames:{hasTitleAndIcon:{true:"_1yep5z6m6 _1yep5z6m7 _1yep5z6m8 _1yep5z6oo _1yep5z6op _1yep5z6oq"},hasNoCloseBtn:{true:"_1yep5z6mc _1yep5z6md _1yep5z6me _1yep5z6oo _1yep5z6op _1yep5z6oq _1yep5z6pu _1yep5z6pv _1yep5z6pw _1yep5z6ni _1yep5z6nj _1yep5z6nk"}},defaultVariants:{},compoundVariants:[[{hasTitleAndIcon:true,hasNoCloseBtn:true},"_1yep5z61hr _1yep5z61hs _1yep5z61ht"]]}),D1="_1v0p2z10";var yn=ht.forwardRef(({className:e,style:t,"data-block-id":o,"data-block-class":r,message:a,title:n,primaryActionLabel:i,cancelLabel:s,textInputProps:l,icon:p,iconColor:c,showCloseButton:u=true,onPrimaryAction:m,onCancel:d,autoFocusButton:b,isPrimaryActionDisabled:f},y)=>{let g=useId(),{formatMessage:v}=A(),_=n&&jsx(te,{id:g,type:"title",size:"sm",elementType:"h3",children:n});return jsxs(xe,{className:e,style:t,"data-block-id":o,"data-block-class":r,size:"sm",variant:"primary",role:"alertdialog",ref:y,"aria-labelledby":g,children:[jsxs("div",{className:S1({hasTitleAndIcon:!!(p&&n),hasNoCloseBtn:!u}),children:[jsxs(S,{display:"flex",justifyContent:"space-between",alignItems:"center",flexDirection:"row",children:[p?jsx(p,{style:{color:c},size:24}):null,!p&&_,u?jsx(L,{icon:XIcon,variant:"secondary",size:"md","aria-label":v(hR.close),onPress:d}):null]}),p?_:null]}),a?jsx(S,{elementType:"section",className:D1,paddingX:"lg",paddingBottom:"lg",typography:"body.sm.regular",color:"text.primary",children:a}):null,l?jsx(S,{paddingX:"lg",paddingBottom:"lg",children:jsx(nt,{...l})}):null,s||i?jsxs(Fragment,{children:[jsx(U,{}),jsxs(S,{padding:"lg",display:"flex",gap:"xl",children:[s?jsx(q,{variant:"secondary",className:ol,label:s,onPress:d,autoFocus:b==="cancel"}):null,i?jsx(q,{className:ol,label:i,onPress:m,autoFocus:b==="primary",isDisabled:f}):null]})]}):null]})});yn.displayName="AlertDialog";var hR=G({close:{id:"close",defaultMessage:"Close",description:"Close button label"}});var M1="_1t55bp71",N1="_1yep5z6e3 _1yep5z6eu _1yep5z6iy _1yep5z6iz _1yep5z6j0 _1yep5z69i _1yep5z69j _1yep5z69k",E1="_1t55bp70";var IR=wR(),L1=ht.forwardRef(({className:e,style:t,children:o,"data-block-id":r,"data-block-class":a,showCaret:n},i)=>{let s=useMemo(()=>{let l=o;return (!o||Array.isArray(o)&&o.length===0)&&(l=""),IR.render(l)},[o]);return jsx("div",{className:classNames(N1,E1,{[M1]:n},"BaselineUI-Markdown",e),"data-block-id":r,"data-block-class":a,style:t,ref:i,dangerouslySetInnerHTML:{__html:s}})});L1.displayName="Markdown";function j1(e){let{formatMessage:t,locale:o}=A(),[r,a]=ht.useState(false),[n,i]=ht.useState(0),[s,l]=ht.useState(0),[p,c]=ht.useState(false);useEffect(()=>{if(!e.current)return;let d=e.current,b=()=>{a(false),i(0);},f=()=>{p||i(d.currentTime*100/d.duration);},y=()=>{l(d.duration);};return d.addEventListener("ended",b),d.addEventListener("timeupdate",f),d.addEventListener("loadedmetadata",y),()=>{d.removeEventListener("ended",b),d.removeEventListener("timeupdate",f),d.removeEventListener("loadedmetadata",y);}},[p,e]);let u=useCallback(()=>{(async()=>e.current&&(e.current.paused?(await e.current.play(),a(true),announce(t(A1.playing),"polite")):(e.current.pause(),a(false),announce(t(A1.paused),"polite"))))();},[t,e]),m=useCallback(d=>{e.current&&(e.current.currentTime=d*e.current.duration/100,announce(TR(e.current.currentTime,o.locale),"assertive"));},[o.locale,e]);return {isPlaying:r,progress:n,duration:s,togglePlay:u,seek:m,setProgress:i,formattedCurrentTime:e.current?.currentTime?F1(e.current?.currentTime):"00:00",formattedDuration:s?F1(s):"00:00",setIsSliderDragging:c}}var A1=G({playing:{id:"playing",defaultMessage:"Playing"},paused:{id:"paused",defaultMessage:"Paused"}});function TR(e,t){let o=Math.floor(e/3600),r=Math.floor(e%3600/60),a=e%60,n={...o&&{hours:o},...r&&{minutes:r},seconds:Math.floor(a)};return new Intl.DurationFormat(t,{style:"long"}).format(n)}function F1(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 O1="_1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69o _1yep5z69p _1yep5z69q",H1="rta2n91 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6101 _1yep5z6vl _1yep5z6vm _1yep5z6vn _1yep5z617q _1yep5z610y",V1="rta2n90";var K1=ht.forwardRef(({className:e,style:t,size:o="lg",sources:r,"data-block-id":a,"data-block-class":n,...i},s)=>{let l=ht.useRef(null),{isPlaying:p,progress:c,duration:u,togglePlay:m,seek:d,formattedDuration:b,formattedCurrentTime:f,setProgress:y,setIsSliderDragging:g}=j1(l),{formatMessage:v}=A(),_=filterTruthyValues({"data-block-id":a,"data-block-class":n,"data-state":p?"playing":"paused","data-loaded":u>0});return jsxs("div",{..._,...i,className:classNames(O1,"BaselineUI-AudioPlayer",e),role:"group",style:t,ref:s,children:[jsx(VisuallyHidden,{children:jsx("audio",{ref:l,children:r.map(({url:h,type:x})=>jsx("source",{src:h,type:x},h))})}),jsx(we,{icon:p?PauseIcon:PlayIcon,variant:"toolbar",isSelected:p,size:o,"aria-label":v(p?al.pause:al.play),style:{borderRadius:"50%"},onPress:m}),jsxs("div",{className:H1,children:[jsx("span",{"aria-hidden":true,children:f}),jsx(to,{"aria-label":v(al.audioTimeline),value:c,minValue:0,maxValue:100,className:V1,onChange:h=>{y(h),g(true);},onChangeEnd:h=>{d(h),g(false);}}),jsx("span",{"aria-hidden":true,children:b})]})]})});K1.displayName="AudioPlayer";var al=G({play:{id:"play",defaultMessage:"Play"},pause:{id:"pause",defaultMessage:"Pause"},audioTimeline:{id:"audioTimeline",defaultMessage:"Audio timeline"}});var G1="_1w920rnd _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6g1 _1yep5z6ig _1yep5z6ih _1yep5z6ii",W1="_1w920rn1 _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k",Y1="_1w920rn0 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6le",gn=z({defaultClassName:"_1w920rn2 _1yep5z6d6 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6id _1yep5z6ie _1yep5z6if",variantClassNames:{isFocusVisible:{true:"_1yep5z6lt _1yep5z6lr _1yep5z6hx"},isSelected:{true:"_1yep5z6lt _1yep5z6lr _1yep5z6hx"},isLoading:{true:"_1yep5z616g _1yep5z616h _1yep5z616i"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:true,isSelected:true},"_1w920rn6 _1yep5z6lt _1yep5z6lr _1yep5z6hx"]]}),X1="_1w920rnb _1yep5z6lo",Z1=z({defaultClassName:"_1w920rn7 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6ar _1yep5z6as _1yep5z6at _1yep5z6bf _1yep5z6bg _1yep5z6bh _1yep5z6c3 _1yep5z6c4 _1yep5z6c5 _1yep5z6cr _1yep5z6cs _1yep5z6ct _1yep5z6g5 _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocusVisible:{true:"_1w920rn8 _1yep5z6lt _1yep5z6lr _1yep5z6hx"},isSelected:{true:"_1w920rn9"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:true,isSelected:true},"_1w920rna _1yep5z61ty _1yep5z61tx _1yep5z61q4"]]}),J1="_1w920rnc";var vn=({items:e,ulRef:t,containerClassName:o,previewClassName:r,itemDataAttribute:a,showCount:n=false})=>{let{length:i}=e,s=ht.useRef(null);return useLayoutEffect(()=>{if(!s.current)return;let l=s.current.closest(o)?.querySelector(`[${a}='${e?.at(-1)?.key}']`)?.cloneNode(true);invariant(l,"Node is not defined."),s.current?.prepend(l);},[e,t,o,a]),jsx("div",{className:r,ref:s,children:n&&i>1?jsx(S,{backgroundColor:"background.secondary.medium",borderRadius:"full",typography:"label.md.medium",color:"text.primary",position:"absolute",paddingX:"md",className:J1,children:i}):null})};function eb(e,t){return e.find(o=>o.id===t)}function tb(e,t,o){let r=[...e],a=r.filter(s=>o.has(s.id)),n=r.filter(s=>!o.has(s.id)),i=n.findIndex(s=>s.id===t);return n.flatMap((s,l)=>l===i?[...a,s]:s)}function ob(e,t,o){let r=[...e],a=r.filter(s=>o.has(s.id)),n=r.filter(s=>!o.has(s.id)),i=n.findIndex(s=>s.id===t);return n.flatMap((s,l)=>l===i?[s,...a]:s)}function nl(e){return e.map(t=>({id:t.id,label:t.label,data:{src:t.src,alt:t.alt}}))}function _n(e){return e.map(t=>({id:t.id,label:t.label,src:t.data?.src,alt:t.data?.alt}))}function rb(){let[e,t]=useState(false);return useEffect(()=>{let o=window.matchMedia("(pointer: coarse)");t(o.matches);let r=a=>{t(a.matches);};return o.addEventListener("change",r),()=>{o.removeEventListener("change",r);}},[]),e}var nb=ht.forwardRef(({id:e,className:t,children:o,style:r,isDisabled:a,onTruncatedChange:n,onHoverChange:i},s)=>{let l=useRef(null),{buttonProps:p}=useButton({elementType:"span",isDisabled:a},l);useLayoutEffect(()=>{l.current&&n?.(l.current.scrollWidth>l.current.clientWidth);},[o,n]);let{hoverProps:c}=useHover({isDisabled:a,onHoverChange:i});return jsx("span",{...Me(p,c),className:classNames(t,"BaselineUI-AdaptiveText"),id:e,tabIndex:-1,ref:M(l,s),style:r,role:void 0,children:o})});nb.displayName="Label";var ll=ht.memo(ht.forwardRef(({children:e,isOpen:t,isDisabled:o,...r},a)=>{let[n,i]=useState(false),[s,l]=useState(false),p=rb(),c=o||!s||p;return jsx(J,{text:e,variant:"inverse",includeArrow:false,size:"sm",placement:"bottom start",isOpen:(n||t)&&s,isDisabled:c,children:jsx(nb,{...r,isDisabled:c,onTruncatedChange:l,onHoverChange:i,ref:a,children:e})})}));ll.displayName="AdaptiveText";var JR=({fit:e,item:t,deleteElement:o})=>{let{formatMessage:r}=A(),a=useReducedMotion(),{imgProps:n,isLoading:i}=Xt({src:t.data?.src,alt:t.data?.alt??""});return i?jsx(po,{"aria-label":r(Dr.loading)}):jsx(motion.div,{role:"img",initial:{opacity:a?1:0},animate:{opacity:1},exit:{opacity:a?1:0},"aria-label":n.alt,style:{backgroundImage:`url(${n.src})`,backgroundSize:e},className:X1,children:o})},lb=({item:e,options:{optionProps:t,isFocusVisible:o,isSelected:r,isFocused:a,isDisabled:n,isPressed:i},liRef:s,fit:l="contain",onDelete:p,className:c,imageClassName:u,imageLabelClassName:m,imageDimensions:d,style:b,layoutTransition:f=true,renderImage:y=(g,{deleteElement:v})=>jsx(JR,{item:g,deleteElement:v,fit:l})})=>{let g=useId(),{formatMessage:v}=A(),{value:_}=e;invariant(_&&et(_),"Expected value to be a list option");let h=p?jsx("div",{className:G1,children:jsx(L,{"aria-label":v(Dr.delete),size:"xs",icon:XIcon$1,onPress:()=>{p(_.id);},UNSAFE_NON_INTERACTIVE:true})}):null,x=_n([_])[0],R=useCallback($=>{let I={},N=typeof $=="function"?$(x,{isSelected:r}):$;return N&&(I.width=typeof N.width=="string"?cl[N.width]:N.width,I.aspectRatio="height"in N?`${I.width} / ${N.height}`:N?.aspectRatio?.toString()),I},[x,r]),P=useMemo(()=>({isFocusVisible:o,isSelected:r,isFocused:a,isDisabled:n,isPressed:i}),[o,r,a,n,i]),w=useReducedMotion(),C=typeof f=="boolean"?f:!w,D=typeof f=="object"?f:void 0,k=C?motion.li:"li",T=R(d);return jsxs(k,{...mergeProps(t,C?{layout:true,transition:D}:void 0),ref:s,className:classNames(W1,xt(c,x,P)),"aria-labelledby":g,style:Ur(b,x,P),children:[jsx(S,{display:"flex",flexDirection:"column",flex:1,justifyContent:"center",alignItems:"center",flexGrow:0,children:jsx("div",{className:classNames(gn({isFocusVisible:o,isSelected:r,isLoading:true}),xt(u,x,P)),style:T,"data-image-key":_.id,children:y(_,{deleteElement:h??void 0,onDelete:p})})}),jsx(ll,{id:g,className:classNames(Z1({isFocusVisible:o,isSelected:r}),m),style:{maxWidth:T.width},isOpen:o,children:_.label})]})};var n$={width:0,display:"block"},db={src:"src",alt:"alt"},cl={sm:102,md:170},ub=ht.forwardRef(({className:e,style:t,fit:o="cover",onReorder:r,"data-block-id":a,"data-block-class":n,onDelete:i,imageWidth:s=cl.sm,aspectRatio:l=3/4,items:p,defaultItems:c=[],onKeyDown:u,imageContainerClassName:m,imageClassName:d,labelClassName:b,onListChange:f,renderImage:y,layoutTransition:g,imageDimensions:v={width:s,aspectRatio:l},imageContainerStyle:_,...h},x)=>{let R=ht.useRef(null),[P,w]=useState([]),{formatMessage:C}=A();useEffect(()=>{(l||s)&&console.warn("ImageGallery: aspectRatio and imageWidth are deprecated. Use imageDimensions instead.");},[s,l]);let[D,k]=useControlledState(h.selectedKeys,h.defaultSelectedKeys??[],h.onSelectionChange),[T,$]=useControlledState(p?nl(p):void 0,nl(c),f?B=>{f?.(_n(B));}:void 0),I=useCallback(B=>{let O=B.target.key,H=B.keys;if(B.target.dropPosition==="before"){let V=tb(T,O,H);$(V);}else if(B.target.dropPosition==="after"){let V=ob(T,O,H);$(V);}r?.(B);},[T,r,$]),N=useCallback(()=>{i&&P.length&&($(T.filter(B=>!P.includes(B.id))),i(new Set(P)),w([]));},[P,T,i,$]),E=useCallback((B,O,H)=>{let{value:V}=B;invariant(et(V));let Q={id:V.id,label:V.label,src:V.data?.src,alt:V.data?.alt};return jsx(lb,{item:B,options:O,liRef:H,fit:o,onDelete:i?F=>{w([F]);}:void 0,renderImage:y,className:xt(m,Q,O),imageClassName:d,imageLabelClassName:b,imageDimensions:v,style:_,layoutTransition:g})},[o,i,y,m,d,b,v,_,g]),{keyboardProps:j}=useKeyboard({onKeyDown(B){if(u?.(B),B.key==="Backspace"||B.key==="Delete"){if(!i)return;if([...D].length)w([...D]);else {let H=B.target.dataset.key;w([H]);}}}});return jsxs("div",{...j,ref:x,style:t,className:classNames("BaselineUI-ImageGallery",e),"data-block-id":a,"data-block-class":n,children:[jsx(me,{...h,selectedKeys:D,items:T,onReorder:I,layout:"grid",orientation:"vertical",className:Y1,ref:R,dropIndicatorStyle:n$,renderOption:E,renderDragPreview:B=>jsx(vn,{items:B,ulRef:R,containerClassName:".BaselineUI-ImageGallery",previewClassName:gn(),itemDataAttribute:"data-image-key",showCount:true}),onSelectionChange:k,getItems:B=>[...B].map(O=>{let H=eb(T,O);return {[db.src]:H?.src||"",[db.alt]:H?.alt||"",key:O}})}),jsx(Ee,{isOpen:!![...P].length,onOpenChange:B=>{B||w([]);},children:jsx(Ue,{isDismissable:true,children:jsx(yn,{showCloseButton:false,title:"Are you sure you want to delete this item?",primaryActionLabel:C(Dr.delete),cancelLabel:C(Dr.cancel),onCancel:()=>{w([]);},onPrimaryAction:N,autoFocusButton:"cancel"})})})]})});ub.displayName="ImageGallery";var Dr=G({delete:{id:"delete",defaultMessage:"Delete"},cancel:{id:"cancel",defaultMessage:"Cancel"},loading:{id:"loading",defaultMessage:"Loading"}});var mb="_1sexph00",fb="_1sexph02",yb="_1sexph01 _1yep5z6189 _1yep5z618a _1yep5z618b _1yep5z61al _1yep5z61am _1yep5z61an _1yep5z61br _1yep5z61bs _1yep5z61bt _1yep5z619f _1yep5z619g _1yep5z619h _1yep5z61sg _1yep5z61sh _1yep5z61si";var bb=ht.forwardRef(({className:e,style:t,items:o,"data-block-id":r,"data-block-class":a,hideLabel:n,size:i="md",isDisabled:s,showSelectedIcon:l=true,excludeFromTabOrder:p,onPress:c,isSelected:u,defaultSelected:m,onButtonSelectionChange:d,moreAriaLabel:b,optionStyle:f,optionClassName:y,triggerClassName:g,triggerStyle:v,tooltipProps:_,buttonBehaviour:h="toggle",...x},R)=>{let{formatMessage:P}=A(),w=pe(),C=useSelectState({items:o,...x,defaultSelectedKey:x.defaultSelectedKey||o?.[0]?.id,children:w,validationState:x.validationState==="error"?"invalid":"valid"}),D=useMemo(()=>typeof h=="function"?h(C.selectedKey):h,[h,C.selectedKey]),[k,T]=useControlledState(u,!!m,F=>{d?.({isSelected:F,selectedKey:C.selectedKey});}),{hoverProps:$,isHovered:I}=useHover({isDisabled:s}),N=useMemo(()=>{let F=C.collection.getItem(C.selectedKey),Y=F?.textValue||F?.["aria-label"],oe=F?.value,le=oe?.icon,X={size:i,...D==="toggle"&&{isSelected:k},onPress:Pe=>{D==="toggle"&&T(!k),c?.(Pe);},isDisabled:s,excludeFromTabOrder:p,className:classNames(typeof y=="function"?y(oe,{isButton:true,isSelected:k}):y,"BaselineUI-ButtonSelect-Button"),style:typeof f=="function"?f(oe,{isButton:true,isSelected:k}):f};return n&&le?jsx(J,{variant:"inverse",size:"sm",includeArrow:false,text:Y,placement:"bottom start",offset:4,...typeof _=="function"?_("button"):_,children:D==="action"?jsx(L,{icon:le,"aria-label":Y,variant:"toolbar",...X}):jsx(we,{icon:le,"aria-label":Y,variant:"toolbar",...X})}):D==="toggle"?jsx(wa,{iconStart:le,label:Y,variant:"toolbar",...X}):jsx(q,{label:Y,variant:"toolbar",...X})},[p,n,k,s,c,y,f,T,i,C.collection,C.selectedKey,_,D]),E=x["aria-label"],j=useCallback(({buttonProps:F,ref:Y})=>{delete F["aria-labelledby"];let oe=b||`${P(f$.more)} ${E}`;return jsx(J,{variant:"inverse",size:"sm",includeArrow:false,text:oe,placement:"bottom start",offset:4,..._,children:jsx(PressResponder,{...F,children:jsx(L,{"aria-label":oe,ref:Y,icon:CaretDownIcon,variant:"toolbar",size:i,className:({isFocusVisible:le})=>classNames(ka({isSelected:k&&D==="toggle",isFocusVisible:le}),yb,g,"BaselineUI-ButtonSelect-Trigger"),style:v,isDisabled:s,excludeFromTabOrder:p})})})},[E,D,p,P,k,s,b,i,_,g,v]),B=filterTruthyValues({"data-block-id":r,"data-block-class":a,"data-hovered":I,"data-selected":k,"data-disabled":s,"data-expanded":C.isOpen,"data-button-behaviour":D}),O=ae(R),H=useMemo(()=>({state:C,popoverAnchorRef:O}),[C,O]),V=useCallback(F=>typeof y=="function"?y(F,{isButton:false,isSelected:C.selectionManager.isSelected(F.id)}):y,[y,C.selectionManager]),Q=useCallback(F=>typeof f=="function"?f(F,{isButton:false,isSelected:C.selectionManager.isSelected(F.id)}):f,[f,C.selectionManager]);return jsx(Da.Provider,{value:H,children:jsxs(S,{...$,role:"group",display:"inline-flex",flexDirection:"row",alignItems:"center",className:classNames(mb,"BaselineUI-ButtonSelect",e),"aria-label":x["aria-label"],"aria-labelledby":x["aria-labelledby"],"aria-describedby":x["aria-describedby"],"aria-details":x["aria-details"],style:t,ref:O,...B,children:[N,jsx(lt,{isDisabled:s,showSelectedIcon:l,placement:"bottom start",items:o,...x,optionClassName:V,optionStyle:Q,variant:"ghost",renderTrigger:j,className:classNames(fb,"BaselineUI-ButtonSelect-Select")})]})})});bb.displayName="ButtonSelect";var f$=G({more:{id:"more",defaultMessage:"More"}});var gb=z({defaultClassName:"_18v88n10 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6ln",variantClassNames:{labelPosition:{top:"_1yep5z6157 _1yep5z6158 _1yep5z6159",start:"_1yep5z6154 _1yep5z6155 _1yep5z6156 _1yep5z616m _1yep5z616n _1yep5z616o _1yep5z6vl _1yep5z6vm _1yep5z6vn"}},defaultVariants:{},compoundVariants:[]}),vb=z({defaultClassName:"_18v88n1p _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6eu _1yep5z6ln _1yep5z6ly _1yep5z6lq _1yep5z6dy",variantClassNames:{isDisabled:{true:"_18v88n1q _1yep5z6111"},labelPosition:{top:"_18v88n1r",start:"_18v88n1s"}},defaultVariants:{},compoundVariants:[]}),_b=z({defaultClassName:"_18v88n1t _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6iv _1yep5z6iw _1yep5z6ix _1yep5z6lk",variantClassNames:{validationState:{valid:"_18v88n1u",error:"_1yep5z610h",warning:"_1yep5z610p"},isReadOnly:{true:"_1yep5z6118"}},defaultVariants:{},compoundVariants:[]}),zb=z({defaultClassName:"_18v88n1d _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6m1 _1yep5z6lz _1yep5z6h4 _1yep5z6jj _1yep5z6jk _1yep5z6jl",variantClassNames:{validationState:{valid:"_18v88n1e",error:"_1yep5z612q",warning:"_18v88n1g"},isHovered:{true:"_18v88n1h"},isFocused:{true:"_1yep5z6wl _1yep5z6wm _1yep5z6wn _1yep5z6x9 _1yep5z6xa _1yep5z6xb _1yep5z6xx _1yep5z6xy _1yep5z6xz _1yep5z6yl _1yep5z6ym _1yep5z6yn _1yep5z6184 _1yep5z6182 _1yep5z6134 _1yep5z617v _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"_18v88n1j"},variant:{primary:"_18v88n1k",ghost:"_18v88n1l"},isReadOnly:{true:"_1yep5z6140"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:true,isFocused:false,validationState:"valid"},"_1yep5z61u7 _1yep5z61u5 _1yep5z61pa"],[{variant:"ghost",isFocused:false,isHovered:false,validationState:"valid"},"_18v88n1n"],[{isHovered:true,validationState:"valid",isDisabled:false,isReadOnly:false,isFocused:false,variant:"primary"},"_1yep5z61pb"],[{isHovered:true,validationState:"warning",isDisabled:false,isReadOnly:false,isFocused:false},"_1yep5z61pb"],[{isReadOnly:true,variant:"primary",isFocused:false},"_18v88n1o"]]}),hb=z({defaultClassName:"_18v88n13 _1yep5z6dy _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6111"}},defaultVariants:{},compoundVariants:[]}),xb=z({defaultClassName:"_18v88n19 _1yep5z6iv _1yep5z6iw _1yep5z6ix",variantClassNames:{labelPosition:{top:"_1yep5z6t9 _1yep5z6ta _1yep5z6tb",start:"_1yep5z6n6 _1yep5z6n7 _1yep5z6n8 _1yep5z6157 _1yep5z6158 _1yep5z6159"},hasMessage:{true:"_18v88n1c"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:false},"_1yep5z61sj _1yep5z61sk _1yep5z61sl"]]}),Cb=z({defaultClassName:"_18v88n15 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z6lq",variantClassNames:{isFocusVisible:{true:"_1yep5z6127 _1yep5z614f _1yep5z617t"},isHovered:{true:"_1yep5z6127 _1yep5z614f _1yep5z617t"},isOpen:{true:"_1yep5z614f _1yep5z617t"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:true},"_1yep5z61oa _1yep5z61qi _1yep5z61tw"],[{isHovered:true},"_1yep5z61oa _1yep5z61qi _1yep5z61tw"],[{isOpen:true},"_1yep5z61qi _1yep5z61tw"]]});function Pb({allowsCustomValue:e,onValueChange:t,inputValue:o},r,a,n,i){let[s,l]=useState(null),p=useRef(false);useEffect(()=>{if(!t)return;let u=a.current,m=d=>{l(d.target);};return u?.addEventListener("focusin",m),()=>{u?.removeEventListener("focusin",m);}},[t,a,r.selectedKey]),useGranularEffect(()=>{r.selectedKey&&(t?.({value:r.selectedItem?.textValue,key:r.selectedKey}),p.current=false);},[r.selectedKey],[t,r.selectedItem]),useInteractOutside({ref:n,isDisabled:!t,onInteractOutside:u=>{!i.current?.contains(u.target)&&s===n.current&&e&&p.current&&(t?.({value:n.current?.value,key:null}),p.current=false);}}),useEffect(()=>{if(!t)return;let u=n.current,m=()=>{p.current=true;};return u?.addEventListener("input",m),()=>{u?.removeEventListener("input",m);}},[n,t]),useEffect(()=>{p.current=false;},[o]);let{keyboardProps:c}=useKeyboard({isDisabled:!t,onKeyDown:u=>{e&&u.key==="Enter"&&p.current?(t?.({value:n.current?.value,key:null}),p.current=false):u.key==="Escape"&&r.close(),u.continuePropagation();}});return {inputProps:c}}var wb=ht.forwardRef(({className:e,style:t,inputStyle:o,inputClassName:r,"data-block-id":a,"data-block-class":n,label:i,items:s,showSelectedIcon:l=false,onSelectionChange:p,onInputChange:c,isInvalid:u=false,labelPosition:m="top",validationState:d="valid",variant:b="primary",toggleLabel:f,renderOption:y,showIcon:g=true,filter:v,minValue:_,maxValue:h,inputType:x="text",onInputSubmit:R,onValueChange:P,tooltip:w,...C},D)=>{let k=useObjectRef(D),{contains:T}=useFilter({sensitivity:"base"}),$=pe(),I=useComboBoxState({...C,defaultFilter:v||T,defaultItems:s,onSelectionChange:p,onInputChange:c,children:$,validationState:u?"invalid":"valid"}),N=ht.useRef(null),E=ht.useRef(null),j=ht.useRef(null),B=ht.useRef(null),O=ht.useRef(null),{inputProps:H}=Pb({onValueChange:P,allowsCustomValue:C.allowsCustomValue,inputValue:C.inputValue},I,k,E,B),{buttonProps:V,inputProps:Q,listBoxProps:F,labelProps:Y,errorMessageProps:oe,descriptionProps:le,validationErrors:X}=useComboBox({...C,inputRef:E,defaultItems:s,buttonRef:N,listBoxRef:j,popoverRef:B,validationState:d==="error"?"invalid":"valid"},I),Pe=C.errorMessage||X.join(" "),Ie=_e({...C,errorMessage:Pe,descriptionProps:le,errorMessageProps:oe,labelPosition:m});Pe&&(d="error");let{hoverProps:zt,isHovered:ie}=useHover({isDisabled:C.isDisabled}),{isFocused:fe,focusProps:Bo,isFocusVisible:Ot}=useFocusRing(),Ht=io({isReadOnly:C.isReadOnly,validationState:d}),Vt=filterTruthyValues({"data-read-only":C.isReadOnly,"data-disabled":C.isDisabled,"data-validation-state":d,"data-focused":fe,"data-focus-visible":Ot}),{labelProps:Z,fieldProps:K}=useLabel({label:i,"aria-label":C["aria-label"],"aria-labelledby":C["aria-labelledby"],"aria-describedby":C["aria-describedby"],"aria-details":C["aria-details"]}),{keyboardProps:ce}=useKeyboard({onKeyDown:Ao=>{C.allowsCustomValue&&Ao.key==="Enter"&&R?.(Q.value?.toString()??"");}}),{focusProps:ee}=useFocus({onBlur:()=>{C.allowsCustomValue&&Q.value&&R?.(Q.value?.toString()??"");}}),{tooltipProps:be}=ve({tooltip:w,label:C["aria-label"]}),Je=Ao=>{let{triggerProps:ug,triggerRef:mg}=Ao??{};return jsxs("div",{className:classNames(gb({labelPosition:m}),e,"BaselineUI-ComboBox"),"data-block-id":a,"data-block-class":n,style:t,ref:k,children:[i||m==="start"&&Ie?jsxs("div",{className:xb({labelPosition:m,hasMessage:!!Ie}),children:[jsx("label",{...mergeProps(Y,Z),className:hb({isDisabled:C.isDisabled}),children:i}),m==="start"&&Ie]}):null,jsxs("div",{...zt,className:zb({validationState:d,isHovered:ie,isFocused:fe,variant:b,isReadOnly:!!C.isReadOnly,isDisabled:!!C.isDisabled}),ref:O,children:[jsx("input",{...mergeProps(ug,Q,H,Bo,Vt,K,ee,ce,x==="number"?{type:"number",min:_,max:h,onKeyDown:Jn=>{(Jn.key==="ArrowUp"||Jn.key==="ArrowDown")&&Jn.preventDefault();}}:null),id:C.id,ref:M(mg,E),className:classNames(vb({isDisabled:C.isDisabled,labelPosition:m}),"BaselineUI-ComboBox-Input",r),style:o}),Ht&&g?jsx(Ht,{className:_b({validationState:d,isReadOnly:C.isReadOnly}),size:16}):null,jsx(q,{...V,ref:N,variant:"popover",label:f,className:Cb({isFocusVisible:!C.isDisabled&&!C.isReadOnly&&Ot,isHovered:!C.isDisabled&&!C.isReadOnly&&ie,isOpen:I.isOpen})})]}),m==="top"&&Ie]})};return jsxs(Ct.Provider,{value:I,children:[be?jsx(J,{...be,children:Je}):Je(),jsx(ke,{ref:B,triggerRef:O,state:I,crossOffset:-2,className:"BaselineUI-ComboBox-Popover",children:jsx(me,{...F,items:s,ref:j,renderOption:y,selectionMode:"single",showSelectedIcon:l,className:classNames(at,"BaselineUI-ComboBox-ListBox")})})]})});wb.displayName="ComboBox";var Ib=z({defaultClassName:"byycd01 _1yep5z6d6 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6id _1yep5z6ie _1yep5z6if",variantClassNames:{},defaultVariants:{},compoundVariants:[]});var gl=ht.forwardRef(({enableReorder:e,...t},o)=>e?jsx(Rb,{ref:o,...t}):jsx(vl,{ref:o,...t}));gl.displayName="GridListItem";var vl=ht.forwardRef(({item:e,state:t,dropState:o,renderGridItem:r,dragHandleProps:a},n)=>{let i=ae(n),s=useGridListItem({node:e},t,i),l=t.selectionManager.selectionMode!=="none"&&t.selectionManager.selectionBehavior==="toggle",{checkboxProps:p}=useGridListSelectionCheckbox({key:e.key},t),c={...s,checkBoxProps:l?p:void 0,dragHandleProps:a};return jsxs("div",{"data-grid-list-item-key":e.key,children:[o?jsx(Ut,{target:{type:"item",key:e.key,dropPosition:"before"},dropState:o}):null,r?r(e,c,i):null,o&&t.collection.getKeyAfter(e.key)==null?jsx(Ut,{target:{type:"item",key:e.key,dropPosition:"after"},dropState:o}):null]},e.key)});vl.displayName="BaseGridListItem";var Rb=ht.forwardRef(({dragState:e,item:t,...o},r)=>{let a=useDraggableItem({key:t.key,hasDragButton:true},e);return jsx(vl,{item:t,dragHandleProps:a,ref:r,...o})});Rb.displayName="DraggableGridListItem";var O$=e=>{e.key==="Enter"||e.key==="Escape"||e.stopPropagation();},Tb=ht.forwardRef(({className:e,style:t,isEditing:o=false,"data-block-id":r,"data-block-class":a,gridListHandle:n,onReorder:i,enableReorder:s=false,layout:l="stack",orientation:p="vertical",renderGridItem:c,...u},m)=>{let d=pe(),b=useListState({...u,children:d}),f=ht.useRef(null),y=ae(m),{gridProps:g}=useGridList(u,b,y);Wr({handle:n,type:"gridlist"},b,y);let{collectionProps:v,dragState:_,dropState:h}=Vr({...u,onReorder:i,enableReorder:s,layout:l,orientation:p,preview:f,getItems:P=>[...P].map(w=>{let C=b.collection.getItem(w);return invariant(C,"Expected item to be defined."),{key:C.key.toString()}})},b,y),x=o?O$:g.onKeyDownCapture,R={state:b,dragState:_,dropState:h,enableReorder:s,renderGridItem:c};return jsxs("ul",{...mergeProps(g,v),className:classNames("BaselineUI-GridList",e),"data-block-id":r,"data-block-class":a,style:t,ref:y,"aria-rowcount":b.collection.size,onKeyDownCapture:x,children:[[...b.collection].map(P=>jsx(gl,{item:P,...R},P.key)),s?jsx(DragPreview,{ref:f,children:P=>jsx(vn,{items:P,ulRef:y,containerClassName:".BaselineUI-GridList",previewClassName:Ib(),itemDataAttribute:"data-grid-list-item-key"})}):null]})});Tb.displayName="GridList";var Sb="_1yep5z6f5",Db="_1dc3b8m0";var Mb=ht.forwardRef(({className:e,selectionMode:t,style:o,"data-block-id":r,"data-block-class":a,tooltipProps:n,icon:i,renderActionItem:s,...l},p)=>{let c=ae(p),u=pe(),m=useListState({...l,selectionMode:t,suppressTextValueWarning:true,children:u}),{actionGroupProps:d}=useActionGroup({...l,selectionMode:t,children:u},m,c),b=[...m.collection].map(f=>(invariant(f.value),jsx(X$,{item:f,state:m,isDisabled:l.isDisabled,onAction:l.onAction,tooltipProps:n,renderActionItem:s},f.key)));return i?jsxs(S,{...d,display:"flex",flexDirection:"row",gap:"md",alignItems:"center",className:classNames("BaselineUI-ActionGroup",e),"data-block-id":r,"data-block-class":a,style:o,ref:c,children:[jsx(i,{"aria-hidden":"true",size:24,className:Sb}),jsx(S,{display:"flex",flexDirection:"row",gap:"xs",flex:1,children:b})]}):jsx(S,{...d,display:"flex",flexDirection:"row",gap:"xs",className:classNames("BaselineUI-ActionGroup",e),"data-block-id":r,"data-block-class":a,style:o,ref:c,children:b})});Mb.displayName="ActionGroup";var X$=({item:e,state:t,tooltipProps:o,renderActionItem:r,onAction:a,isDisabled:n})=>{let{buttonProps:i}=useActionGroupItem({key:e.key},t),s=n||t.selectionManager.isDisabled(e.key),l=t.selectionManager.isSelected(e.key);invariant(e.value);let{icon:p}=e.value;invariant(p);let c=useMemo(()=>(invariant(e.value),typeof o=="function"?o(e.value):o),[o,e.value]);return jsx(PressResponder,{...mergeProps(i,{onPress:()=>{a?.(e.key);}}),children:jsx(J,{text:e.textValue,size:"sm",variant:"inverse",includeArrow:false,offset:4,...c,children:r?.(e,{isSelected:l,isDisabled:s})||jsx(L,{variant:"tertiary",icon:p,"aria-label":e.textValue,size:"sm",isDisabled:s,className:classNames({[Db]:l},"BaselineUI-ActionGroup-Item")})})})};var Nb="ujkypy0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e",Eb="_1yep5z61r7 _1yep5z61r8 _1yep5z61r9 _1yep5z61hl _1yep5z61hm _1yep5z61hn";var Bb=ht.forwardRef(({className:e,style:t,items:o,optionsContainerClassName:r,label:a,icon:n,value:i,defaultValue:s,onChange:l,isDisabled:p,optionClassName:c,optionStyle:u,labelPosition:m="top","data-block-id":d,"data-block-class":b,shouldFocusWrap:f,tooltip:y=true,...g},v)=>{let _=useMemo(()=>o.map(x=>({id:x.color,label:x.label})),[o]),h=useId();return useEffect(()=>{!a&&!g["aria-label"]&&!g["aria-labelledby"]&&console.warn("ColorSwatchPicker: Please provide a label or aria-label for accessibility.");},[a,g]),jsxs(S,{...ii(g),className:classNames("BaselineUI-ColorSwatchPicker",e),"data-block-id":d,"data-block-class":b,display:"flex",flexDirection:m==="top"?"column":"row",alignItems:m==="top"?"flex-start":"center",justifyContent:"space-between",gap:"md",style:t,ref:v,children:[n||a?jsxs(S,{display:"flex",alignItems:"center",gap:"md",children:[n?jsx(n,{"aria-hidden":"true",size:24,className:sprinkles({color:"icon.primary"})}):null,a?jsx(te,{id:h,type:"label",size:"sm",children:a}):null]}):null,jsx(me,{className:classNames(Eb,r),selectionMode:"single",items:_,orientation:"horizontal",defaultSelectedKeys:s?[s]:void 0,disabledKeys:p?_.map(x=>x.id):void 0,isDisabled:p,selectedKeys:i?[i]:void 0,onSelectionChange:x=>{l?.([...x][0]);},optionClassName:c,optionStyle:u,renderOption:({key:x,textValue:R},{isSelected:P,isFocusVisible:w,isDisabled:C,optionProps:D},k)=>jsx("li",{...D,"data-disabled":C,className:classNames(Nb,D.className),ref:k,children:jsx(ct,{isFocusVisible:w,color:x,isSelected:P,"aria-label":R,isInteractive:true,isDisabled:C,tooltip:y})}),shouldFocusWrap:f,...g,"aria-labelledby":a?h:g["aria-labelledby"]})]})});Bb.displayName="ColorSwatchPicker";var Ab=z({defaultClassName:"_1lrwegk0",variantClassNames:{isSeparator:{true:"_1yep5z610y"}},defaultVariants:{},compoundVariants:[]}),Cn="_1yep5z63o _1yep5z63p _1yep5z63q _1yep5z629 _1yep5z62a _1yep5z62b _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6kj _1yep5z6kk _1yep5z6kl";var xl="\u2013";function Pn({segment:e,state:t}){let o=ht.useRef(null),{segmentProps:r}=useDateSegment(e,t,o),{focusProps:a,isFocused:n}=useFocusRing(),i=useMemo(()=>{let{text:s,type:l}=e;switch(l){case "hour":return s.replaceAll(xl,"H");case "minute":return s.replaceAll(xl,"M");case "second":return s.replaceAll(xl,"S");default:return s}},[e]);return jsx(S,{...mergeProps(r,a),typography:"label.md.medium",color:e.isPlaceholder?"text.placeholder":"text.primary",backgroundColor:n?"support.info.subtle":void 0,ref:o,marginLeft:e.type==="timeZoneName"?"xs":void 0,className:Ab({isSeparator:e.text===":"||e.text==="/"}),children:e.isPlaceholder?i:e.text})}var jb=ht.forwardRef(({className:e,labelPosition:t,"data-block-id":o,"data-block-class":r,...a},n)=>{let{locale:i}=useLocale(),s={...a,validationState:void 0,isInvalid:a.validationState==="error"||void 0},l=useTimeFieldState({...s,locale:i}),p=ht.useRef(null),{labelProps:c,fieldProps:u,descriptionProps:m,errorMessageProps:d,validationErrors:b,isInvalid:f,inputProps:y}=useTimeField(s,l,p),g=a.errorMessage||b.join(" "),v=_e({...a,errorMessage:g,descriptionProps:m,errorMessageProps:d,labelPosition:t}),{focusProps:_,isFocused:h}=useFocusRing({within:true});return jsxs(wt,{className:classNames("BaselineUI-TimeField",e),labelProps:c,fieldProps:u,ref:n,wrapperRef:p,wrapperClassName:Cn,labelPosition:t,message:v,isFocused:h,"data-block-id":o,"data-block-class":r,isInvalid:f,...a,children:[jsx(VisuallyHidden,{children:jsx("input",{...y})}),jsx(S,{display:"flex",flexDirection:"row",paddingRight:"md",..._,children:l.segments.map((x,R)=>jsx(Pn,{segment:x,state:l},R))})]})});jb.displayName="TimeField";var Ob="_10dw1p96",Hb="_10dw1p95",Vb=z({defaultClassName:"_10dw1p90 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69f _1yep5z69g _1yep5z69h _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lq _1yep5z6ld _1yep5z6la",variantClassNames:{isSelected:{true:"_1yep5z6126"},isHovered:{true:"_10dw1p92"},isRenaming:{true:"_10dw1p93"},isFocusVisible:{true:"_1yep5z6140 _1yep5z617w _1yep5z617u"}},defaultVariants:{},compoundVariants:[[{isHovered:true,isSelected:false,isRenaming:false},"_1yep5z61o8 _1yep5z61q9 _1yep5z61ty _1yep5z61tx"]]});function Kb(e,t){if(typeof e=="function"&&!e.prototype?.isReactComponent){let o=e(t);return isValidElement(o)?e:o}return e}var Gb=({context:e,depth:t,children:o,item:r,onPrimaryAction:a,onSecondaryAction:n,actionsPosition:i,primaryActionIcon:s,secondaryActionIcon:l,primaryActionAriaLabel:p,secondaryActionAriaLabel:c,onRename:u,onAction:m,renderItemTitle:d=b=>b.data.label})=>{let{formatMessage:b}=A(),{hoverProps:f,isHovered:y}=useHover({}),g=useRef(null),{onKeyDown:v,..._}=e.interactiveElementProps;delete _.onFocus,delete _.onClick;let h=createFocusManager(g),x=useCallback($=>{if($.key==="ArrowRight"&&(e.isExpanded||!r.children?.length))g.current?.setAttribute("tabindex","-1"),$.preventDefault(),$.stopPropagation(),h.focusNext();else switch($.key){case "ArrowLeft":{h.focusPrevious()?($.preventDefault(),$.stopPropagation()):(v?.($),e.focusItem(true));break}case "Enter":{e.toggleExpandedState();break}default:v?.($);}},[e,h,v,r,g]),R=useMemo(()=>{let $=Kb(s,r.index),I=Kb(l,r.index),N=typeof p=="function"?p(r.index):p,E=typeof c=="function"?c(r.index):c;return $||I?jsxs(S,{display:"flex",flexDirection:"row",children:[$?jsx(we,{icon:$,"aria-label":N,size:"sm",excludeFromTabOrder:true,variant:"secondary",onPress:()=>{a?.(r.index);},tooltip:true}):null,I?jsx(we,{icon:I,"aria-label":E,size:"sm",excludeFromTabOrder:true,variant:"secondary",onPress:()=>{n?.(r.index);},tooltip:true}):null]}):null},[s,r.index,l,p,c,a,n]),P=useCallback($=>{$.key==="Enter"?(u?.({key:r.index,value:$.target.value}),e.stopRenamingItem()):$.key==="Escape"?(e.stopRenamingItem(),g.current?.setAttribute("tabindex","0"),g.current?.focus()):$.key!=="ArrowRight"&&$.key!=="ArrowLeft"&&$.key!=="ArrowUp"&&$.key!=="ArrowDown"&&!$.metaKey&&$.continuePropagation();},[r.index,e,u,g]),w=r.data.icon,C=!!u,{pressProps:D}=usePress({onPress:()=>{m?.(r.index);}}),{isFocusVisible:k,focusProps:T}=useFocusRing$1();return jsxs(Fragment,{children:[jsx("div",{...mergeProps({onKeyDown:x,onFocus:()=>{e.focusItem(false);}},D,T,f,e.itemContainerWithoutChildrenProps,_),className:classNames(Hb,Vb({isHovered:y,isSelected:e.isSelected,isFocusVisible:k,isRenaming:e.isRenaming}),"BaselineUI-TreeView-Row"),role:"row","data-key":r.index,"data-expanded":r.isFolder?e.isExpanded:void 0,"aria-expanded":r.isFolder?e.isExpanded:void 0,"data-selected":e.isSelected,"aria-selected":e.isSelected,"data-depth":t,"aria-level":t+1,"aria-posinset":r.data.posInset,"aria-setsize":r.data.setSize,"aria-label":r.data.label,style:{justifyContent:i==="end"?"space-between":void 0},ref:g,children:jsxs(S,{role:"gridcell",style:{display:"contents"},"aria-colindex":1,children:[i==="start"?R:null,jsxs(S,{display:"flex",flexDirection:"row",alignItems:"center",children:[jsxs(S,{display:"flex",padding:"sm",flexDirection:"row",alignItems:"center",gap:"md",style:{marginInlineStart:`calc(${t*2} * ${themeVars.spacing.lg})`},children:[jsx(L,{icon:ChevronRightIcon,size:"xxs",variant:"secondary",onPress:()=>{e.toggleExpandedState();},"aria-label":b(e.isExpanded?Pl.collapse:Pl.expand),style:{visibility:r.children?.length?"visible":"hidden"},className:classNames(Ob,"BaselineUI-TreeView-ExpansionToggle"),UNSAFE_NON_INTERACTIVE:true}),w?jsx(w,{size:16,style:{color:themeVars.color.icon.interactive.disabled}}):null]}),jsxs(S,{paddingLeft:"sm",paddingY:e.isRenaming?"none":"md",display:"flex",flexDirection:"column",gap:"xs",onDoubleClick:$=>{C&&($.stopPropagation(),$.preventDefault(),e.startRenamingItem());},children:[e.isRenaming?jsx("div",{onClick:$=>{$.stopPropagation();},children:jsx(nt,{defaultValue:r.data.label,autoFocus:true,onBlur:$=>{u?.({key:r.index,value:$.target.value}),e.stopRenamingItem();},"aria-label":b(Pl.rename),onKeyDown:P,className:"BaselineUI-TreeView-RenameInput"})}):jsx(te,{type:"label",size:"sm",className:classNames(sprinkles.compoundVariants({color:"text.primary"}),"BaselineUI-TreeView-Title"),children:d(r)}),r.data.description?jsx(te,{type:"helper",size:"sm",className:"BaselineUI-TreeView-Description",children:r.data.description}):null]})]}),i==="end"?R:null]})}),o]})},Pl=G({expand:{id:"expand",defaultMessage:"Expand"},collapse:{id:"collapse",defaultMessage:"Collapse"},rename:{id:"rename",defaultMessage:"Rename"}});function NT(e,{posInset:t,setSize:o}){return {index:e.id,children:e.children?e.children.map(r=>r.id):[],data:{label:e.label,description:e.description,icon:e.icon,...e.data,posInset:t,setSize:o},isFolder:!!e.children?.length}}function ET(e,t){let o={};function r(a,n,i){if(o[a.id]=t(a,{posInset:n,setSize:i}),a.children)for(let s=0;s<a.children.length;s++)r(a.children[s],s+1,a.children.length);}return r(e,0,0),o}var Zb=ht.forwardRef(({className:e,style:t,"data-block-id":o,"data-block-class":r,items:a,rootId:n=a.id,onPrimaryAction:i,onSecondaryAction:s,primaryActionIcon:l,secondaryActionIcon:p,primaryActionAriaLabel:c,secondaryActionAriaLabel:u,actionsPosition:m="start",onRename:d,onAction:b,renderItemTitle:f,...y},g)=>{let v=pe(),_=useRef(null),h=useTreeState({...y,selectionMode:"multiple",items:a.children,children:v}),x=useMemo(()=>Object.fromEntries(Object.entries(ET(a,NT)).map(([k,T])=>[k,{...T,canRename:!!d}])),[a,d]),R=useId(),[P,w]=ht.useState(a.children?.[0]?.id??""),C=useRef(P),D=useMemo(()=>({[`tree-${R}`]:{focusedItem:P,expandedItems:[...h.expandedKeys],selectedItems:[...h.selectionManager.selectedKeys]}}),[P,h.expandedKeys,h.selectionManager.selectedKeys,R]);return useEffect(()=>{if(!_.current)return;let k=_.current.getRootNode(),T=k instanceof ShadowRoot,$=_.current?.contains(k?.activeElement??null);T&&$&&k?.querySelector(`[data-rct-item-id="${P}"]`)?.focus();},[P]),jsx(ControlledTreeEnvironment,{items:x,getItemTitle:k=>k.data?.label,viewState:D,onExpandItem:k=>{h.setExpandedKeys(new Set([...h.expandedKeys,k.index])),y.onExpand?.(k.index.toString());},onFocusItem:k=>{w(k.index),k.index&&(C.current=k.index);},onCollapseItem:k=>{h.setExpandedKeys(new Set([...h.expandedKeys].filter(T=>T!==k.index))),y.onCollapse?.(k.index.toString());},onSelectItems:k=>{h.selectionManager.setSelectedKeys(new Set(k));},renderItem:k=>jsx(Gb,{...k,onPrimaryAction:i,onSecondaryAction:s,actionsPosition:m,primaryActionIcon:l,secondaryActionIcon:p,primaryActionAriaLabel:c,secondaryActionAriaLabel:u,onRename:d,onAction:b,renderItemTitle:f}),renderLiveDescriptorContainer:({children:k})=>jsx(he,{children:jsx(VisuallyHidden,{children:k})}),renderTreeContainer:({containerProps:k,children:T})=>jsx("div",{...Me(k,{onBlur:$=>{$.currentTarget.contains($.relatedTarget)||$.currentTarget.querySelector(`[data-key="${C.current}"]`)?.setAttribute("tabindex","0");}}),"data-block-id":o,"data-block-class":r,style:{...t,...k.style},className:classNames(e,"BaselineUI-TreeView"),ref:M(g,k.ref,_),role:"treegrid",children:T}),renderItemsContainer:({children:k})=>k,children:jsx(Tree,{treeId:`tree-${R}`,rootItem:n,treeLabel:y["aria-label"],treeLabelledBy:y["aria-labelledby"]})})});Zb.displayName="TreeView";var HT=forwardRef(({className:e,isCollapsible:t=false,...o},r)=>{let a=useRef(null),n=useId();return useImperativeHandle(r,()=>({resize:a.current?.resize})),jsx(Panel,{className:classNames("BaselineUI-Panel",e),collapsible:t,ref:a,id:n,...o})});HT.displayName="Panel";var YT=forwardRef(({className:e,...t},o)=>{let r=useRef(null);return useImperativeHandle(o,()=>({setLayout:r.current?.setLayout})),jsx(PanelGroup,{className:classNames("BaselineUI-PanelGroup",e),ref:r,...t})});YT.displayName="PanelGroup";var Jb="_6abhjk0";var QT=({className:e,isDisabled:t=false,...o})=>jsx(PanelResizeHandle,{disabled:t,className:classNames(Jb,"BaselineUI-PanelResizeHandle",e),...o});QT.displayName="PanelResizeHandle";var Qb=z({defaultClassName:"_1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7 _1yep5z6lz _1yep5z6m1",variantClassNames:{variant:{info:"_1yep5z6131",warning:"_1yep5z612x",error:"_1yep5z612p",success:"_1yep5z612t"}},defaultVariants:{},compoundVariants:[]}),e5="_1udvgpn5 _1yep5z6ij _1yep5z6ik _1yep5z6il _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j4 _1yep5z6j5 _1yep5z6j6 _1yep5z69l _1yep5z69m _1yep5z69n";var n4=()=>{};function i4({state:e,...t}){let o=ht.useRef(null),{toastProps:r,contentProps:a,titleProps:n,descriptionProps:i,closeButtonProps:s}=useToast(t,e,o),l=useMemo(()=>({root:r,title:n,content:a,description:i,close:s}),[r,n,a,i,s]),{canClose:p=true,...c}=t.toast.content;return jsx(La,{elementProps:l,...c,className:classNames(Qb({variant:c.variant||"info"}),c.className),onClose:p?n4:void 0})}var o5=ht.forwardRef(({state:e,style:t,className:o,...r},a)=>{let n=ae(a),{regionProps:i}=useToastRegion(r,e,n),s={zIndex:1,...t,...i.style};return jsx("div",{...i,ref:n,className:classNames(e5,o),style:s,children:e.visibleToasts.map(l=>jsx(i4,{toast:l,state:e},l.key))})});o5.displayName="ToastRegion";var r5=ht.forwardRef(({toastQueue:e,portalContainer:t,...o},r)=>{let a=useToastQueue(e),n=ze(t);return a.visibleToasts.length>0?jsx(he,{portalContainer:n,ref:r,children:jsx(o5,{state:a,...o})}):null});r5.displayName="GlobalToastRegion";function Ye(e,t){return e-t*Math.floor(e/t)}var a5=1721426;function ft(e,t,o,r){t=yt(e,t);let a=t-1,n=-2;return o<=2?n=0:Xe(t)&&(n=-1),a5-1+365*a+Math.floor(a/4)-Math.floor(a/100)+Math.floor(a/400)+Math.floor((367*o-362)/12+n+r)}function Xe(e){return e%4===0&&(e%100!==0||e%400===0)}function yt(e,t){return e==="BC"?1-t:t}function Ft(e){let t="AD";return e<=0&&(t="BC",e=1-e),[t,e]}var s4={standard:[31,28,31,30,31,30,31,31,30,31,30,31],leapyear:[31,29,31,30,31,30,31,31,30,31,30,31]},se=class{fromJulianDay(t){let o=t,r=o-a5,a=Math.floor(r/146097),n=Ye(r,146097),i=Math.floor(n/36524),s=Ye(n,36524),l=Math.floor(s/1461),p=Ye(s,1461),c=Math.floor(p/365),u=a*400+i*100+l*4+c+(i!==4&&c!==4?1:0),[m,d]=Ft(u),b=o-ft(m,d,1,1),f=2;o<ft(m,d,3,1)?f=0:Xe(d)&&(f=1);let y=Math.floor(((b+f)*12+373)/367),g=o-ft(m,d,y,1)+1;return new W(m,d,y,g)}toJulianDay(t){return ft(t.era,t.year,t.month,t.day)}getDaysInMonth(t){return s4[Xe(t.year)?"leapyear":"standard"][t.month-1]}getMonthsInYear(t){return 12}getDaysInYear(t){return Xe(t.year)?366:365}getYearsInEra(t){return 9999}getEras(){return ["BC","AD"]}isInverseEra(t){return t.era==="BC"}balanceDate(t){t.year<=0&&(t.era=t.era==="BC"?"AD":"BC",t.year=1-t.year);}constructor(){this.identifier="gregory";}};function Il(e,t){return e.calendar.toJulianDay(e)-t.calendar.toJulianDay(t)}function i5(e,t){return n5(e)-n5(t)}function n5(e){return e.hour*36e5+e.minute*6e4+e.second*1e3+e.millisecond}var wl=null;function Rl(){return wl==null&&(wl=new Intl.DateTimeFormat().resolvedOptions().timeZone),wl}function $l(e){e=In(e,new se);let t=yt(e.era,e.year);return c5(t,e.month,e.day,e.hour,e.minute,e.second,e.millisecond)}function c5(e,t,o,r,a,n,i){let s=new Date;return s.setUTCHours(r,a,n,i),s.setUTCFullYear(e,t-1,o),s.getTime()}function s5(e,t){if(t==="UTC")return 0;if(e>0&&t===Rl())return new Date(e).getTimezoneOffset()*-6e4;let{year:o,month:r,day:a,hour:n,minute:i,second:s}=d5(e,t);return c5(o,r,a,n,i,s,0)-Math.floor(e/1e3)*1e3}var l5=new Map;function d5(e,t){let o=l5.get(t);o||(o=new Intl.DateTimeFormat("en-US",{timeZone:t,hour12:false,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),l5.set(t,o));let r=o.formatToParts(new Date(e)),a={};for(let n of r)n.type!=="literal"&&(a[n.type]=n.value);return {year:a.era==="BC"||a.era==="B"?-a.year+1:+a.year,month:+a.month,day:+a.day,hour:a.hour==="24"?0:+a.hour,minute:+a.minute,second:+a.second}}var p5=864e5;function l4(e,t,o,r){return (o===r?[o]:[o,r]).filter(n=>p4(e,t,n))}function p4(e,t,o){let r=d5(o,t);return e.year===r.year&&e.month===r.month&&e.day===r.day&&e.hour===r.hour&&e.minute===r.minute&&e.second===r.second}function u5(e,t,o="compatible"){let r=wn(e);if(t==="UTC")return $l(r);if(t===Rl()&&o==="compatible"){r=In(r,new se);let l=new Date,p=yt(r.era,r.year);return l.setFullYear(p,r.month-1,r.day),l.setHours(r.hour,r.minute,r.second,r.millisecond),l.getTime()}let a=$l(r),n=s5(a-p5,t),i=s5(a+p5,t),s=l4(r,t,a-n,a-i);if(s.length===1)return s[0];if(s.length>1)switch(o){case "compatible":case "earlier":return s[0];case "later":return s[s.length-1];case "reject":throw new RangeError("Multiple possible absolute times found")}switch(o){case "earlier":return Math.min(a-n,a-i);case "compatible":case "later":return Math.max(a-n,a-i);case "reject":throw new RangeError("No such absolute time found")}}function Tl(e,t,o="compatible"){return new Date(u5(e,t,o))}function wn(e,t){let o=0,r=0,a=0,n=0;if("timeZone"in e)({hour:o,minute:r,second:a,millisecond:n}=e);else if("hour"in e&&true)return e;return new Rn(e.calendar,e.era,e.year,e.month,e.day,o,r,a,n)}function In(e,t){if(e.calendar.identifier===t.identifier)return e;let o=t.fromJulianDay(e.calendar.toJulianDay(e)),r=e.copy();return r.calendar=t,r.era=o.era,r.year=o.year,r.month=o.month,r.day=o.day,bt(r),r}function Tn(e,t){let o=e.copy(),r="hour"in o?m4(o,t):0;Sl(o,t.years||0),o.calendar.balanceYearMonth&&o.calendar.balanceYearMonth(o,e),o.month+=t.months||0,Dl(o),m5(o),o.day+=(t.weeks||0)*7,o.day+=t.days||0,o.day+=r,c4(o),o.calendar.balanceDate&&o.calendar.balanceDate(o),o.year<1&&(o.year=1,o.month=1,o.day=1);let a=o.calendar.getYearsInEra(o);if(o.year>a){var n,i;let l=(n=(i=o.calendar).isInverseEra)===null||n===void 0?void 0:n.call(i,o);o.year=a,o.month=l?1:o.calendar.getMonthsInYear(o),o.day=l?1:o.calendar.getDaysInMonth(o);}o.month<1&&(o.month=1,o.day=1);let s=o.calendar.getMonthsInYear(o);return o.month>s&&(o.month=s,o.day=o.calendar.getDaysInMonth(o)),o.day=Math.max(1,Math.min(o.calendar.getDaysInMonth(o),o.day)),o}function Sl(e,t){var o,r;!((o=(r=e.calendar).isInverseEra)===null||o===void 0)&&o.call(r,e)&&(t=-t),e.year+=t;}function Dl(e){for(;e.month<1;)Sl(e,-1),e.month+=e.calendar.getMonthsInYear(e);let t=0;for(;e.month>(t=e.calendar.getMonthsInYear(e));)e.month-=t,Sl(e,1);}function c4(e){for(;e.day<1;)e.month--,Dl(e),e.day+=e.calendar.getDaysInMonth(e);for(;e.day>e.calendar.getDaysInMonth(e);)e.day-=e.calendar.getDaysInMonth(e),e.month++,Dl(e);}function m5(e){e.month=Math.max(1,Math.min(e.calendar.getMonthsInYear(e),e.month)),e.day=Math.max(1,Math.min(e.calendar.getDaysInMonth(e),e.day));}function bt(e){e.calendar.constrainDate&&e.calendar.constrainDate(e),e.year=Math.max(1,Math.min(e.calendar.getYearsInEra(e),e.year)),m5(e);}function d4(e){let t={};for(let o in e)typeof e[o]=="number"&&(t[o]=-e[o]);return t}function Ml(e,t){return Tn(e,d4(t))}function Nl(e,t){let o=e.copy();return t.era!=null&&(o.era=t.era),t.year!=null&&(o.year=t.year),t.month!=null&&(o.month=t.month),t.day!=null&&(o.day=t.day),bt(o),o}function f5(e,t){let o=e.copy();return t.hour!=null&&(o.hour=t.hour),t.minute!=null&&(o.minute=t.minute),t.second!=null&&(o.second=t.second),t.millisecond!=null&&(o.millisecond=t.millisecond),y5(o),o}function u4(e){e.second+=Math.floor(e.millisecond/1e3),e.millisecond=$n(e.millisecond,1e3),e.minute+=Math.floor(e.second/60),e.second=$n(e.second,60),e.hour+=Math.floor(e.minute/60),e.minute=$n(e.minute,60);let t=Math.floor(e.hour/24);return e.hour=$n(e.hour,24),t}function y5(e){e.millisecond=Math.max(0,Math.min(e.millisecond,1e3)),e.second=Math.max(0,Math.min(e.second,59)),e.minute=Math.max(0,Math.min(e.minute,59)),e.hour=Math.max(0,Math.min(e.hour,23));}function $n(e,t){let o=e%t;return o<0&&(o+=t),o}function m4(e,t){return e.hour+=t.hours||0,e.minute+=t.minutes||0,e.second+=t.seconds||0,e.millisecond+=t.milliseconds||0,u4(e)}function El(e,t,o,r){let a=e.copy();switch(t){case "era":{let s=e.calendar.getEras(),l=s.indexOf(e.era);if(l<0)throw new Error("Invalid era: "+e.era);l=gt(l,o,0,s.length-1,r?.round),a.era=s[l],bt(a);break}case "year":var n,i;!((n=(i=a.calendar).isInverseEra)===null||n===void 0)&&n.call(i,a)&&(o=-o),a.year=gt(e.year,o,-1/0,9999,r?.round),a.year===-1/0&&(a.year=1),a.calendar.balanceYearMonth&&a.calendar.balanceYearMonth(a,e);break;case "month":a.month=gt(e.month,o,1,e.calendar.getMonthsInYear(e),r?.round);break;case "day":a.day=gt(e.day,o,1,e.calendar.getDaysInMonth(e),r?.round);break;default:throw new Error("Unsupported field "+t)}return e.calendar.balanceDate&&e.calendar.balanceDate(a),bt(a),a}function b5(e,t,o,r){let a=e.copy();switch(t){case "hour":{let n=e.hour,i=0,s=23;if(r?.hourCycle===12){let l=n>=12;i=l?12:0,s=l?23:11;}a.hour=gt(n,o,i,s,r?.round);break}case "minute":a.minute=gt(e.minute,o,0,59,r?.round);break;case "second":a.second=gt(e.second,o,0,59,r?.round);break;case "millisecond":a.millisecond=gt(e.millisecond,o,0,999,r?.round);break;default:throw new Error("Unsupported field "+t)}return a}function gt(e,t,o,r,a=false){if(a){e+=Math.sign(t),e<o&&(e=r);let n=Math.abs(t);t>0?e=Math.ceil(e/n)*n:e=Math.floor(e/n)*n,e>r&&(e=o);}else e+=t,e<o?e=r-(o-e-1):e>r&&(e=o+(e-r-1));return e}function g5(e){return `${String(e.hour).padStart(2,"0")}:${String(e.minute).padStart(2,"0")}:${String(e.second).padStart(2,"0")}${e.millisecond?String(e.millisecond/1e3).slice(1):""}`}function Ll(e){let t=In(e,new se),o;return t.era==="BC"?o=t.year===1?"0000":"-"+String(Math.abs(1-t.year)).padStart(6,"00"):o=String(t.year).padStart(4,"0"),`${o}-${String(t.month).padStart(2,"0")}-${String(t.day).padStart(2,"0")}`}function v5(e){return `${Ll(e)}T${g5(e)}`}function _5(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Bl(e,t,o){_5(e,t),t.set(e,o);}function z5(e){let t=typeof e[0]=="object"?e.shift():new se,o;if(typeof e[0]=="string")o=e.shift();else {let i=t.getEras();o=i[i.length-1];}let r=e.shift(),a=e.shift(),n=e.shift();return [t,o,r,a,n]}var y4=new WeakMap,W=class e{copy(){return this.era?new e(this.calendar,this.era,this.year,this.month,this.day):new e(this.calendar,this.year,this.month,this.day)}add(t){return Tn(this,t)}subtract(t){return Ml(this,t)}set(t){return Nl(this,t)}cycle(t,o,r){return El(this,t,o,r)}toDate(t){return Tl(this,t)}toString(){return Ll(this)}compare(t){return Il(this,t)}constructor(...t){Bl(this,y4,{writable:true,value:void 0});let[o,r,a,n,i]=z5(t);this.calendar=o,this.era=r,this.year=a,this.month=n,this.day=i,bt(this);}};var b4=new WeakMap,Rn=class e{copy(){return this.era?new e(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new e(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(t){return Tn(this,t)}subtract(t){return Ml(this,t)}set(t){return Nl(f5(this,t),t)}cycle(t,o,r){switch(t){case "era":case "year":case "month":case "day":return El(this,t,o,r);default:return b5(this,t,o,r)}}toDate(t,o){return Tl(this,t,o)}toString(){return v5(this)}compare(t){let o=Il(this,t);return o===0?i5(this,wn(t)):o}constructor(...t){Bl(this,b4,{writable:true,value:void 0});let[o,r,a,n,i]=z5(t);this.calendar=o,this.era=r,this.year=a,this.month=n,this.day=i,this.hour=t.shift()||0,this.minute=t.shift()||0,this.second=t.shift()||0,this.millisecond=t.shift()||0,bt(this);}};var So=[[1868,9,8],[1912,7,30],[1926,12,25],[1989,1,8],[2019,5,1]],g4=[[1912,7,29],[1926,12,24],[1989,1,7],[2019,4,30]],Sn=[1867,1911,1925,1988,2018],vt=["meiji","taisho","showa","heisei","reiwa"];function h5(e){let t=So.findIndex(([o,r,a])=>e.year<o||e.year===o&&e.month<r||e.year===o&&e.month===r&&e.day<a);return t===-1?So.length-1:t===0?0:t-1}function Al(e){let t=Sn[vt.indexOf(e.era)];if(!t)throw new Error("Unknown era: "+e.era);return new W(e.year+t,e.month,e.day)}var Dn=class extends se{fromJulianDay(t){let o=super.fromJulianDay(t),r=h5(o);return new W(this,vt[r],o.year-Sn[r],o.month,o.day)}toJulianDay(t){return super.toJulianDay(Al(t))}balanceDate(t){let o=Al(t),r=h5(o);vt[r]!==t.era&&(t.era=vt[r],t.year=o.year-Sn[r]),this.constrainDate(t);}constrainDate(t){let o=vt.indexOf(t.era),r=g4[o];if(r!=null){let[a,n,i]=r,s=a-Sn[o];t.year=Math.max(1,Math.min(s,t.year)),t.year===s&&(t.month=Math.min(n,t.month),t.month===n&&(t.day=Math.min(i,t.day)));}if(t.year===1&&o>=0){let[,a,n]=So[o];t.month=Math.max(a,t.month),t.month===a&&(t.day=Math.max(n,t.day));}}getEras(){return vt}getYearsInEra(t){let o=vt.indexOf(t.era),r=So[o],a=So[o+1];if(a==null)return 9999-r[0]+1;let n=a[0]-r[0];return (t.month<a[1]||t.month===a[1]&&t.day<a[2])&&n++,n}getDaysInMonth(t){return super.getDaysInMonth(Al(t))}getMinimumMonthInYear(t){let o=x5(t);return o?o[1]:1}getMinimumDayInMonth(t){let o=x5(t);return o&&t.month===o[1]?o[2]:1}constructor(...t){super(...t),this.identifier="japanese";}};function x5(e){if(e.year===1){let t=vt.indexOf(e.era);return So[t]}}var P5=-543,Mn=class extends se{fromJulianDay(t){let o=super.fromJulianDay(t),r=yt(o.era,o.year);return new W(this,r-P5,o.month,o.day)}toJulianDay(t){return super.toJulianDay(C5(t))}getEras(){return ["BE"]}getDaysInMonth(t){return super.getDaysInMonth(C5(t))}balanceDate(){}constructor(...t){super(...t),this.identifier="buddhist";}};function C5(e){let[t,o]=Ft(e.year+P5);return new W(t,o,e.month,e.day)}var Nn=1911;function I5(e){return e.era==="minguo"?e.year+Nn:1-e.year+Nn}function k5(e){let t=e-Nn;return t>0?["minguo",t]:["before_minguo",1-t]}var En=class extends se{fromJulianDay(t){let o=super.fromJulianDay(t),r=yt(o.era,o.year),[a,n]=k5(r);return new W(this,a,n,o.month,o.day)}toJulianDay(t){return super.toJulianDay(w5(t))}getEras(){return ["before_minguo","minguo"]}balanceDate(t){let[o,r]=k5(I5(t));t.era=o,t.year=r;}isInverseEra(t){return t.era==="before_minguo"}getDaysInMonth(t){return super.getDaysInMonth(w5(t))}getYearsInEra(t){return t.era==="before_minguo"?9999:9999-Nn}constructor(...t){super(...t),this.identifier="roc";}};function w5(e){let[t,o]=Ft(I5(e));return new W(t,o,e.month,e.day)}var R5=1948320,$5=[0,31,62,93,124,155,186,216,246,276,306,336],Ln=class{fromJulianDay(t){let o=t-R5,r=1+Math.floor((33*o+3)/12053),a=365*(r-1)+Math.floor((8*r+21)/33),n=o-a,i=n<216?Math.floor(n/31):Math.floor((n-6)/30),s=n-$5[i]+1;return new W(this,r,i+1,s)}toJulianDay(t){let o=R5-1+365*(t.year-1)+Math.floor((8*t.year+21)/33);return o+=$5[t.month-1],o+=t.day,o}getMonthsInYear(){return 12}getDaysInMonth(t){return t.month<=6?31:t.month<=11||Ye(25*t.year+11,33)<8?30:29}getEras(){return ["AP"]}getYearsInEra(){return 9377}constructor(){this.identifier="persian";}};var Fl=78,T5=80,Bn=class extends se{fromJulianDay(t){let o=super.fromJulianDay(t),r=o.year-Fl,a=t-ft(o.era,o.year,1,1),n;a<T5?(r--,n=Xe(o.year-1)?31:30,a+=n+155+90+10):(n=Xe(o.year)?31:30,a-=T5);let i,s;if(a<n)i=1,s=a+1;else {let l=a-n;l<155?(i=Math.floor(l/31)+2,s=l%31+1):(l-=155,i=Math.floor(l/30)+7,s=l%30+1);}return new W(this,r,i,s)}toJulianDay(t){let o=t.year+Fl,[r,a]=Ft(o),n,i;return Xe(a)?(n=31,i=ft(r,a,3,21)):(n=30,i=ft(r,a,3,22)),t.month===1?i+t.day-1:(i+=n+Math.min(t.month-2,5)*31,t.month>=8&&(i+=(t.month-7)*30),i+=t.day-1,i)}getDaysInMonth(t){return t.month===1&&Xe(t.year+Fl)||t.month>=2&&t.month<=6?31:30}getYearsInEra(){return 9919}getEras(){return ["saka"]}balanceDate(){}constructor(...t){super(...t),this.identifier="indian";}};var Fn=1948440,S5=1948439,Te=1300,Do=1600,v4=460322;function jn(e,t,o,r){return r+Math.ceil(29.5*(o-1))+(t-1)*354+Math.floor((3+11*t)/30)+e-1}function E5(e,t,o){let r=Math.floor((30*(o-t)+10646)/10631),a=Math.min(12,Math.ceil((o-(29+jn(t,r,1,1)))/29.5)+1),n=o-jn(t,r,a,1)+1;return new W(e,r,a,n)}function D5(e){return (14+11*e)%30<11}var No=class{fromJulianDay(t){return E5(this,Fn,t)}toJulianDay(t){return jn(Fn,t.year,t.month,t.day)}getDaysInMonth(t){let o=29+t.month%2;return t.month===12&&D5(t.year)&&o++,o}getMonthsInYear(){return 12}getDaysInYear(t){return D5(t.year)?355:354}getYearsInEra(){return 9665}getEras(){return ["AH"]}constructor(){this.identifier="islamic-civil";}},On=class extends No{fromJulianDay(t){return E5(this,S5,t)}toJulianDay(t){return jn(S5,t.year,t.month,t.day)}constructor(...t){super(...t),this.identifier="islamic-tbla";}},_4="qgpUDckO1AbqBmwDrQpVBakGkgepC9QF2gpcBS0NlQZKB1QLagutBa4ETwoXBYsGpQbVCtYCWwmdBE0KJg2VDawFtgm6AlsKKwWVCsoG6Qr0AnYJtgJWCcoKpAvSC9kF3AJtCU0FpQpSC6ULtAW2CVcFlwJLBaMGUgdlC2oFqworBZUMSg2lDcoF1gpXCasESwmlClILagt1BXYCtwhbBFUFqQW0BdoJ3QRuAjYJqgpUDbIN1QXaAlsJqwRVCkkLZAtxC7QFtQpVCiUNkg7JDtQG6QprCasEkwpJDaQNsg25CroEWworBZUKKgtVC1wFvQQ9Ah0JlQpKC1oLbQW2AjsJmwRVBqkGVAdqC2wFrQpVBSkLkgupC9QF2gpaBasKlQVJB2QHqgu1BbYCVgpNDiULUgtqC60FrgIvCZcESwalBqwG1gpdBZ0ETQoWDZUNqgW1BdoCWwmtBJUFygbkBuoK9QS2AlYJqgpUC9IL2QXqAm0JrQSVCkoLpQuyBbUJ1gSXCkcFkwZJB1ULagVrCisFiwpGDaMNygXWCtsEawJLCaUKUgtpC3UFdgG3CFsCKwVlBbQF2gntBG0BtgimClINqQ3UBdoKWwmrBFMGKQdiB6kLsgW1ClUFJQuSDckO0gbpCmsFqwRVCikNVA2qDbUJugQ7CpsETQqqCtUK2gJdCV4ELgqaDFUNsga5BroEXQotBZUKUguoC7QLuQXaAloJSgukDdEO6AZqC20FNQWVBkoNqA3UDdoGWwWdAisGFQtKC5ULqgWuCi4JjwwnBZUGqgbWCl0FnQI=",jl,Mo;function An(e){return v4+Mo[e-Te]}function Lr(e,t){let o=e-Te,r=1<<11-(t-1);return (jl[o]&r)===0?29:30}function M5(e,t){let o=An(e);for(let r=1;r<t;r++)o+=Lr(e,r);return o}function N5(e){return Mo[e+1-Te]-Mo[e-Te]}var Hn=class extends No{fromJulianDay(t){let o=t-Fn,r=An(Te),a=An(Do);if(o<r||o>a)return super.fromJulianDay(t);{let n=Te-1,i=1,s=1;for(;s>0;){n++,s=o-An(n)+1;let l=N5(n);if(s===l){i=12;break}else if(s<l){let p=Lr(n,i);for(i=1;s>p;)s-=p,i++,p=Lr(n,i);break}}return new W(this,n,i,o-M5(n,i)+1)}}toJulianDay(t){return t.year<Te||t.year>Do?super.toJulianDay(t):Fn+M5(t.year,t.month)+(t.day-1)}getDaysInMonth(t){return t.year<Te||t.year>Do?super.getDaysInMonth(t):Lr(t.year,t.month)}getDaysInYear(t){return t.year<Te||t.year>Do?super.getDaysInYear(t):N5(t.year)}constructor(){if(super(),this.identifier="islamic-umalqura",jl||(jl=new Uint16Array(Uint8Array.from(atob(_4),t=>t.charCodeAt(0)).buffer)),!Mo){Mo=new Uint32Array(Do-Te+1);let t=0;for(let o=Te;o<=Do;o++){Mo[o-Te]=t;for(let r=1;r<=12;r++)t+=Lr(o,r);}}}};var L5=347997,B5=1080,A5=24*B5,z4=29,h4=12*B5+793,x4=z4*A5+h4;function jt(e){return Ye(e*7+1,19)<7}function Un(e){let t=Math.floor((235*e-234)/19),o=12084+13753*t,r=t*29+Math.floor(o/25920);return Ye(3*(r+1),7)<3&&(r+=1),r}function C4(e){let t=Un(e-1),o=Un(e);return Un(e+1)-o===356?2:o-t===382?1:0}function Br(e){return Un(e)+C4(e)}function F5(e){return Br(e+1)-Br(e)}function P4(e){let t=F5(e);switch(t>380&&(t-=30),t){case 353:return 0;case 354:return 1;case 355:return 2}}function Vn(e,t){if(t>=6&&!jt(e)&&t++,t===4||t===7||t===9||t===11||t===13)return 29;let o=P4(e);return t===2?o===2?30:29:t===3?o===0?29:30:t===6?jt(e)?30:0:30}var qn=class{fromJulianDay(t){let o=t-L5,r=o*A5/x4,a=Math.floor((19*r+234)/235)+1,n=Br(a),i=Math.floor(o-n);for(;i<1;)a--,n=Br(a),i=Math.floor(o-n);let s=1,l=0;for(;l<i;)l+=Vn(a,s),s++;s--,l-=Vn(a,s);let p=i-l;return new W(this,a,s,p)}toJulianDay(t){let o=Br(t.year);for(let r=1;r<t.month;r++)o+=Vn(t.year,r);return o+t.day+L5}getDaysInMonth(t){return Vn(t.year,t.month)}getMonthsInYear(t){return jt(t.year)?13:12}getDaysInYear(t){return F5(t.year)}getYearsInEra(){return 9999}getEras(){return ["AM"]}balanceYearMonth(t,o){o.year!==t.year&&(jt(o.year)&&!jt(t.year)&&o.month>6?t.month--:!jt(o.year)&&jt(t.year)&&o.month>6&&t.month++);}constructor(){this.identifier="hebrew";}};var Ol=1723856,j5=1824665,Hl=5500;function Kn(e,t,o,r){return e+365*t+Math.floor(t/4)+30*(o-1)+r-1}function Vl(e,t){let o=Math.floor(4*(t-e)/1461),r=1+Math.floor((t-Kn(e,o,1,1))/30),a=t+1-Kn(e,o,r,1);return [o,r,a]}function O5(e){return Math.floor(e%4/3)}function H5(e,t){return t%13!==0?30:O5(e)+5}var Eo=class{fromJulianDay(t){let[o,r,a]=Vl(Ol,t),n="AM";return o<=0&&(n="AA",o+=Hl),new W(this,n,o,r,a)}toJulianDay(t){let o=t.year;return t.era==="AA"&&(o-=Hl),Kn(Ol,o,t.month,t.day)}getDaysInMonth(t){return H5(t.year,t.month)}getMonthsInYear(){return 13}getDaysInYear(t){return 365+O5(t.year)}getYearsInEra(t){return t.era==="AA"?9999:9991}getEras(){return ["AA","AM"]}constructor(){this.identifier="ethiopic";}},Gn=class extends Eo{fromJulianDay(t){let[o,r,a]=Vl(Ol,t);return o+=Hl,new W(this,"AA",o,r,a)}getEras(){return ["AA"]}getYearsInEra(){return 9999}constructor(...t){super(...t),this.identifier="ethioaa";}},Wn=class extends Eo{fromJulianDay(t){let[o,r,a]=Vl(j5,t),n="CE";return o<=0&&(n="BCE",o=1-o),new W(this,n,o,r,a)}toJulianDay(t){let o=t.year;return t.era==="BCE"&&(o=1-o),Kn(j5,o,t.month,t.day)}getDaysInMonth(t){let o=t.year;return t.era==="BCE"&&(o=1-o),H5(o,t.month)}isInverseEra(t){return t.era==="BCE"}balanceDate(t){t.year<=0&&(t.era=t.era==="BCE"?"CE":"BCE",t.year=1-t.year);}getEras(){return ["BCE","CE"]}getYearsInEra(t){return t.era==="BCE"?9999:9715}constructor(...t){super(...t),this.identifier="coptic";}};function Ul(e){switch(e){case "buddhist":return new Mn;case "ethiopic":return new Eo;case "ethioaa":return new Gn;case "coptic":return new Wn;case "hebrew":return new qn;case "indian":return new Bn;case "islamic-civil":return new No;case "islamic-tbla":return new On;case "islamic-umalqura":return new Hn;case "japanese":return new Dn;case "persian":return new Ln;case "roc":return new En;case "gregory":default:return new se}}var U5=ht.forwardRef(({className:e,labelPosition:t,"data-block-id":o,"data-block-class":r,...a},n)=>{let{locale:i}=useLocale(),s={...a,validationState:void 0,isInvalid:a.validationState==="error"||void 0},l=useDateFieldState({...s,locale:i,createCalendar:Ul}),p=ht.useRef(null),{labelProps:c,fieldProps:u,validationErrors:m,descriptionProps:d,inputProps:b,errorMessageProps:f,isInvalid:y}=useDateField(s,l,p),g=a.errorMessage||m.join(" "),v=_e({...a,errorMessage:g,descriptionProps:d,errorMessageProps:f,labelPosition:t}),{focusProps:_,isFocused:h}=useFocusRing({within:true});return jsxs(wt,{className:classNames("BaselineUI-DateField",e),labelProps:c,fieldProps:u,ref:n,wrapperRef:p,wrapperClassName:Cn,labelPosition:t,message:v,isFocused:h,"data-block-id":o,"data-block-class":r,isInvalid:y,...a,children:[jsx(VisuallyHidden,{children:jsx("input",{...b})}),jsx(S,{display:"flex",flexDirection:"row",paddingRight:"md",..._,children:l.segments.map((x,R)=>jsx(Pn,{segment:x,state:l},R))})]})});U5.displayName="DateField";var q5={x:0,y:0},N4={node:null,setNode:()=>{},coordinates:q5,setCoordinates:()=>{},displayId:"",boundsRef:{current:null},isDisabled:false},Ze=ht.createContext(N4),K5=({children:e,isDisabled:t=false,coordinates:o,onMove:r})=>{let[a,n]=ht.useState(null),i=ht.useRef(null),[s,l]=useControlledState(o,q5,u=>{r?.({coordinates:u,boundingRect:i.current});}),p=useId(),c=ht.useMemo(()=>({node:a,setNode:n,coordinates:s,setCoordinates:l,displayId:p,boundsRef:i,isDisabled:t}),[a,s,p,l,n,i,t]);return jsx(Ze.Provider,{value:c,children:e})};K5.displayName="Magnifier";var G5="_1yep5z6f6",W5=z({defaultClassName:"_1aj2a4v6",variantClassNames:{isDisabled:{true:"_1aj2a4v7",false:"_1aj2a4v8"},isIndicatorVisible:{true:"_1aj2a4v9",false:"_1aj2a4va"}},defaultVariants:{},compoundVariants:[[{isDisabled:false,isIndicatorVisible:true},"_1aj2a4vb"],[{isDisabled:false,isIndicatorVisible:false},"_1aj2a4vc"]]}),Y5="_1aj2a4vd",X5="_1aj2a4v1",Z5="_1aj2a4v4",ql="_1aj2a4v3 _1yep5z6hd _1yep5z6lz",J5="_1aj2a4v2 _1yep5z6iy _1yep5z6iz _1yep5z6j0 _1yep5z6h4 _1yep5z6lz _1yep5z6id _1yep5z6ie _1yep5z6if",Q5="_1aj2a4v0",eg="_1aj2a4v5";var og=e=>jsxs("svg",{width:92,height:92,viewBox:"0 0 92 92",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:[jsxs("g",{filter:"url(#filter0_d_11407_457970)",children:[jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M49 43V4h-6v39H4v6h39v39h6V49h39v-6H49zm38 5H48v39h-4V48H5v-4h39V5h4v39h39v4zm-5 28v6h-6v6h12V76h-6zm5 11H77v-4h6v-6h4v10zm-77-5v-6H4v12h12v-6h-6zm5 5H5V77h4v6h6v4zM76 4v6h6v6h6V4H76zm11 11h-4V9h-6V5h10v10zM4 4v12h6v-6h6V4H4zm11 5H9v6H5V5h10v4z",fill:themeVars.color.background.positive.subtle}),jsx("path",{d:"M48 44v4h39v-4H48zm-4 4v39h4V48h-4zM5 44v4h39v-4H5zM44 5v39h4V5h-4zm39 72v6h-6v4h10V77h-4zM9 83v-6H5v10h10v-4H9zM77 5v4h6v6h4V5H77zM5 5v10h4V9h6V5H5z",fill:themeVars.color.background.positive.interactive.enabled})]}),jsx("defs",{children:jsxs("filter",{id:"filter0_d_11407_457970",x:0,y:0,width:92,height:92,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[jsx("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),jsx("feColorMatrix",{in:"SourceAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),jsx("feOffset",{}),jsx("feGaussianBlur",{stdDeviation:2}),jsx("feComposite",{in2:"hardAlpha",operator:"out"}),jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.4 0"}),jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_11407_457970"}),jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_11407_457970",result:"shape"})]})})]});function rg({coordinates:e,setCoordinates:t,boundsRef:o,onKeyDown:r,onKeyUp:a}){let{isDisabled:n}=useContext(Ze);return useKeyboard({isDisabled:n,onKeyDown:i=>{r?.(i);let s=i.shiftKey?10:1,l=o.current;if(!l)return;let p;switch(i.key){case "ArrowRight":{i.preventDefault(),p={x:clamp$1(e.x+s,0,l.width),y:clamp$1(e.y,0,l.height)};break}case "ArrowLeft":{i.preventDefault(),p={x:clamp$1(e.x-s,0,l.width),y:clamp$1(e.y,0,l.height)};break}case "ArrowDown":{i.preventDefault(),p={x:clamp$1(e.x,0,l.width),y:clamp$1(e.y+s,0,l.height)};break}case "ArrowUp":{i.preventDefault(),p={x:clamp$1(e.x,0,l.width),y:clamp$1(e.y-s,0,l.height)};break}}p&&t(p);},onKeyUp:a})}var ng=ht.forwardRef(({children:e,onPress:t,className:o,style:r,"data-block-id":a,"data-block-class":n,onFocusChange:i,onBlur:s,onFocus:l,onKeyDown:p,onKeyUp:c,...u},m)=>{let{setNode:d,setCoordinates:b,coordinates:f,displayId:y,boundsRef:g,isDisabled:v}=useContext(Ze),_=useRef(null),[h,x]=useState(false),R=useInteractionModality(),P=Ne();useEffect(()=>{let E=_.current;if(!E||v)return;let j=O=>{let H=E.getBoundingClientRect();g.current=H;let V="clientX"in O?O.clientX:O.touches[0].clientX,Q="clientY"in O?O.clientY:O.touches[0].clientY,F={x:clamp$1(V-H.left,0,H.width),y:clamp$1(Q-H.top,0,H.height)};b(F),x(true);},B=()=>{x(false);};return E.addEventListener("mousemove",j),E.addEventListener("touchmove",j),E.addEventListener("mouseleave",B),()=>{E.removeEventListener("mousemove",j),E.removeEventListener("touchmove",j),E.removeEventListener("mouseleave",B);}},[b,g,v]);let{pressProps:w}=usePress({isDisabled:v,onPress:E=>{E.pointerType==="keyboard"?t?.({...E,x:f.x,y:f.y}):t?.(E);}}),{focusProps:C,isFocusVisible:D,isFocused:k}=useFocusRing(),{focusProps:T}=useFocus$1({isDisabled:v,onFocusChange:E=>{if(R==="keyboard")if(E){x(true);let j=_.current?.getBoundingClientRect();if(!j)return;g.current=j,b({x:clamp$1(j.width/2,0,j.width),y:clamp$1(j.height/2,0,j.height)});}else x(false);i?.(E);},onFocus:l,onBlur:s}),{keyboardProps:$}=rg({coordinates:f,setCoordinates:b,boundsRef:g,onKeyDown:p,onKeyUp:c}),I=useMemo(()=>_.current?getAbsolutePosition(_.current,f):{x:0,y:0},[f]);useInteractOutside$1({isDisabled:v,ref:_,onInteractOutside:()=>{x(false);}});let N=useMemo(()=>h&&!v&&(P==="mobile"||R==="keyboard"),[h,v,P,R]);return jsxs("div",{ref:M(m,_),className:classNames(Y5,"BaselineUI-Magnifier-Content",o),style:r,"data-block-id":a,"data-block-class":n,"aria-controls":y,role:"application",...u,children:[N?jsx(he,{children:jsx(og,{style:{left:I.x,top:I.y},className:classNames(Q5,"BaselineUI-Magnifier-Cursor")})}):null,jsx("div",{...Me(w,C,$,T),ref:d,className:classNames(W5({isDisabled:v,isIndicatorVisible:N}),"BaselineUI-Magnifier-ContentInner"),"data-focus-visible":D,"data-focused":k,tabIndex:v?void 0:0,children:e})]})});ng.displayName="MagnifierContent";function e8(e){let t=[];for(let o=0;o<e.length;o++){let r=e[o],a=e.getPropertyValue(r);a&&t.push(`${r}: ${a}`);}for(let o of e)if(o.startsWith("--")){let r=e.getPropertyValue(o);r&&t.push(`${o}: ${r}`);}return t.join("; ")}function ig(e){let[t,o]=useState(null),{isDisabled:r}=useContext(Ze);return useEffect(()=>{if(!e||r)return;let a=e,n=re(a);function i(){let p=n.getComputedStyle(a),c=a.cloneNode(true);c.style.cssText=e8(p);let u=a.getBoundingClientRect();c.style.setProperty("width",`${u.width}px`),c.style.setProperty("height",`${u.height}px`),c.style.setProperty("position","static"),c.style.setProperty("margin","0"),c.style.setProperty("left","0"),c.style.setProperty("top","0"),c.style.setProperty("transform","none"),c.style.removeProperty("-webkit-text-fill-color"),c.style.removeProperty("-webkit-text-stroke-color"),c.removeAttribute("aria-controls"),c.setAttribute("tabindex","-1"),c.setAttribute("aria-hidden","true");let m=findFocusableElements(c);if(m)for(let d of m)d.setAttribute("tabindex","-1");"scrollTop"in a&&(c.scrollTop=a.scrollTop),"scrollLeft"in a&&(c.scrollLeft=a.scrollLeft),o(c);}i();let s=new ResizeObserver(i),l=new MutationObserver(i);return s.observe(a),l.observe(a,{attributes:true,childList:true,subtree:true,characterData:true}),()=>{s.disconnect(),l.disconnect();}},[e,r]),t}var lg=8,pg=7,cg=7,dg=ht.forwardRef(({className:e,style:t,description:o,scale:r=2,"data-block-id":a,"data-block-class":n},i)=>{let{coordinates:s,node:l,boundsRef:p,displayId:c,isDisabled:u}=useContext(Ze),m=ig(l),d=useMemo(()=>typeof o=="function"?o({coordinates:{x:s.x,y:s.y},boundingRect:p.current}):o,[o,s,p]),b=useMemo(()=>p.current?{x:s.x/p.current.width,y:s.y/p.current.height}:{x:0,y:0},[p,s]);return jsxs(S,{ref:i,className:classNames(X5,"BaselineUI-Magnifier-Display",e),backgroundColor:"background.primary.subtle",boxShadow:"medium",borderRadius:"sm",outlineWidth:1,outlineColor:"border.medium",outlineOffset:-1,outlineStyle:"solid",paddingY:"md",paddingLeft:"md",paddingRight:d?.length?"xl":"md",display:"flex",flexDirection:"row",gap:"lg",alignItems:"center",style:t,id:c,"data-block-id":a,"data-block-class":n,role:"complementary",children:[jsxs("div",{className:J5,children:[m&&!u?jsx(oa,{node:m,style:{transform:`scale(${r}) translate(calc(-${b.x*100}% + ${lg*pg/(2*r)}px), calc(-${b.y*100}% + ${lg*cg/(2*r)}px))`},className:classNames(eg,"BaselineUI-Magnifier-DisplayNode")}):null,Array.from({length:pg*cg}).map((f,y)=>y===24?jsx("div",{className:classNames(ql,Z5)},y):jsx("div",{className:ql},y))]}),d?.length?jsx(S,{display:"flex",gap:"lg",flexDirection:"column",children:d?.map(({label:f,icon:y},g)=>jsxs(S,{display:"flex",gap:"md",flexDirection:"row",color:"text.secondary",alignItems:"center",children:[jsx(y,{size:12,className:G5}),jsx(te,{type:"label",size:"sm",children:f})]},f+g))}):null]})});dg.displayName="MagnifierDisplay";
13
+ export{Ju as Accordion,nm as AccordionItem,q as ActionButton,Mb as ActionGroup,X$ as ActionGroupItem,L as ActionIconButton,yn as AlertDialog,K1 as AudioPlayer,fo as Avatar,S as Box,bb as ButtonSelect,zu as Checkbox,go as ColorInput,ct as ColorSwatch,Bb as ColorSwatchPicker,wb as ComboBox,U5 as DateField,Su as DateFormat,Yv as DeviceProvider,ca as DeviceProviderContext,xe as Dialog,Qc as DialogTitle,oa as DomNodeRenderer,va as Drawer,k1 as Editor,Hd as FileUpload,ba as Focusable,n_ as FrameProvider,Ff as FreehandCanvas,r5 as GlobalToastRegion,Tb as GridList,yy as Group,cc as I18nProvider,Sf as IconColorInput,Wa as IconColorInputButton,um as IconSelect,sd as IconSlider,Qf as ImageDropZone,ub as ImageGallery,La as InlineAlert,Md as Link,me as ListBox,K5 as Magnifier,ng as MagnifierContent,dg as MagnifierDisplay,L1 as Markdown,ha as Menu,fy as MessageFormat,Ee as Modal,oP as ModalClose,Ue as ModalContent,Ba as ModalTrigger,so as NumberFormat,Ve as NumberInput,Tu as Pagination,HT as Panel,YT as PanelGroup,QT as PanelResizeHandle,je as Popover,Le as PopoverContent,Oe as PopoverTrigger,he as Portal,na as PortalContainerProvider,ay as Preview,Zd as ProgressBar,po as ProgressSpinner,my as RadioGroup,lu as Reaction,T1 as ScrollControlButton,xd as SearchInput,lt as Select,U as Separator,to as Slider,gd as Switch,Im as TabItem,wm as Tabs,Ou as TagGroup,te as Text,nt as TextInput,fa as ThemeProvider,jb as TimeField,wa as ToggleButton,we as ToggleIconButton,on as Toolbar,J as Tooltip,Yf as Transform,Zb as TreeView,G as defineMessages,_M as disableAnimations,zM as enableAnimations,c3 as isInsideOverlayContent,Bp as isRect,Ne as useDevice,A as useI18n,Xt as useImage,ac as useIntersectionObserver,sa as useIsFirstRender,yc as useLocalStorage,cD as useMutationObserver,ze as usePortalContainer,nc as useResizeObserver,gD as useTextSelection,sc as useUndoRedo,ki as useUserPreferences};