@baseline-ui/core 0.24.0 → 0.24.1

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.js CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var utils = require('@baseline-ui/utils');
4
- var so = require('react');
4
+ var to = require('react');
5
5
  var utils$1 = require('@react-stately/utils');
6
6
  var web = require('@react-spring/web');
7
7
  var reactAria = require('react-aria');
@@ -15,7 +15,7 @@ var _12 = require('@baseline-ui/icons/12');
15
15
  var _20 = require('@baseline-ui/icons/20');
16
16
  var dynamic = require('@vanilla-extract/dynamic');
17
17
  var granularHooks = require('granular-hooks');
18
- var ob = require('lodash/isEmpty');
18
+ var sb = require('lodash/isEmpty');
19
19
  var vo = require('lodash/isEqual');
20
20
  var focus = require('@react-aria/focus');
21
21
  var reactSlot = require('@radix-ui/react-slot');
@@ -31,13 +31,13 @@ var plateCommon = require('@udecode/plate-common');
31
31
  var plateFont = require('@udecode/plate-font');
32
32
  var plateParagraph = require('@udecode/plate-paragraph');
33
33
  var plateLink = require('@udecode/plate-link');
34
- var cn = require('@udecode/cn');
35
- var qm = require('dompurify');
34
+ var cn$1 = require('@udecode/cn');
35
+ var Zm = require('dompurify');
36
36
  var slateHyperscript = require('slate-hyperscript');
37
37
  var plateCombobox = require('@udecode/plate-combobox');
38
38
  var slateReact = require('slate-react');
39
39
  var interactions = require('@react-aria/interactions');
40
- var jP = require('markdown-it');
40
+ var YP = require('markdown-it');
41
41
  var liveAnnouncer = require('@react-aria/live-announcer');
42
42
  var actiongroup = require('@react-aria/actiongroup');
43
43
 
@@ -61,11 +61,11 @@ function _interopNamespace(e) {
61
61
  return Object.freeze(n);
62
62
  }
63
63
 
64
- var so__default = /*#__PURE__*/_interopDefault(so);
65
- var ob__default = /*#__PURE__*/_interopDefault(ob);
64
+ var to__default = /*#__PURE__*/_interopDefault(to);
65
+ var sb__default = /*#__PURE__*/_interopDefault(sb);
66
66
  var vo__default = /*#__PURE__*/_interopDefault(vo);
67
- var qm__namespace = /*#__PURE__*/_interopNamespace(qm);
68
- var jP__default = /*#__PURE__*/_interopDefault(jP);
67
+ var Zm__namespace = /*#__PURE__*/_interopNamespace(Zm);
68
+ var YP__default = /*#__PURE__*/_interopDefault(YP);
69
69
 
70
70
  /**
71
71
  * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
@@ -76,9 +76,9 @@ var jP__default = /*#__PURE__*/_interopDefault(jP);
76
76
  * This notice may not be removed from this file.
77
77
  *
78
78
  */
79
- var we=typeof document<"u"?so__default.default.useLayoutEffect:()=>{};function pa(e){let r=so.useRef(null);return we(()=>{r.current=e;},[e]),so.useCallback((...o)=>{let t=r.current;return t?.(...o)},[])}function ca(e){let[r,o]=so.useState(e),t=so.useRef(null),a=pa(()=>{if(!t.current)return;let n=t.current.next();if(n.done){t.current=null;return}r===n.value?a():o(n.value);});we(()=>{t.current&&a();});let i=pa(n=>{t.current=n(r),a();});return [r,i]}var ye=e=>{var r;return (r=e?.ownerDocument)!==null&&r!==void 0?r:document},Q=e=>{if(e&&"window"in e&&e.window===e)return e;let r=Vr(e);return r instanceof ShadowRoot?r.ownerDocument.defaultView||window:r?.defaultView||window},Vr=e=>{if(!e)return document;let r=e.getRootNode?e.getRootNode():document;return e.isConnected?(r):null};function N(...e){return e.length===1?e[0]:r=>{for(let o of e)typeof o=="function"?o(r):o!=null&&(o.current=r);}}var vf=new Set(["id"]),_f=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),zf=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),hf=/^(data-.*)$/;function da(e,r={}){let{labelable:o,isLink:t,propNames:a}=r,i={};for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(vf.has(n)||o&&_f.has(n)||t&&zf.has(n)||a?.has(n)||hf.test(n))&&(i[n]=e[n]);return i}function gn(e){var r;return typeof window>"u"||window.navigator==null?!1:((r=window.navigator.userAgentData)===null||r===void 0?void 0:r.brands.some(o=>e.test(o.brand)))||e.test(window.navigator.userAgent)}function ma(e){var r;return typeof window<"u"&&window.navigator!=null?e.test(((r=window.navigator.userAgentData)===null||r===void 0?void 0:r.platform)||window.navigator.platform):!1}function vn(){return ma(/^Mac/i)}function _n(){return ma(/^iPhone/i)}function zn(){return ma(/^iPad/i)||vn()&&navigator.maxTouchPoints>1}function ua(){return _n()||zn()}function fa(){return gn(/Android/i)}function Go(){return gn(/Firefox/i)}function Re(e){let r=so.useRef(null);return so.useMemo(()=>({get current(){return r.current},set current(o){r.current=o,typeof e=="function"?e(o):e&&(e.current=o);}}),[e])}function kf(){return typeof window.ResizeObserver<"u"}function ya(e){let{ref:r,onResize:o}=e;so.useEffect(()=>{let t=r?.current;if(t)if(kf()){let a=new window.ResizeObserver(i=>{i.length&&o();});return a.observe(t),()=>{t&&a.unobserve(t);}}else return window.addEventListener("resize",o,!1),()=>{window.removeEventListener("resize",o,!1);}},[o,r]);}function Tf(e){return "type"in e&&e.type==="section"?jsxRuntime.jsx(reactStately.Section,{items:e.children,title:e.title,children:r=>jsxRuntime.jsx(reactStately.Item,{children:r.label},r.id)},e.id):(utils.invariant("label"in e,"Item doesn't have a label"),jsxRuntime.jsx(reactStately.Item,{textValue:e.label,children:e.label},e.id))}function ae(){return so.useCallback(e=>Tf(e),[])}function xn(e,r,o){let{direction:t}=reactAria.useLocale(),a=reactStately.useDraggableCollectionState({...e,collection:r.collection,selectionManager:r.selectionManager,getItems:e.getItems||(l=>[...l].map(s=>{let p=r.collection.getItem(s);return utils.invariant(p,"Expected item to be defined."),{"text/plain":p.textValue}}))});reactAria.useDraggableCollection(e,a,o);let i=reactStately.useDroppableCollectionState({...e,collection:r.collection,selectionManager:r.selectionManager}),{collectionProps:n}=reactAria.useDroppableCollection({...e,keyboardDelegate:new reactAria.ListKeyboardDelegate({collection:r.collection,disabledKeys:r.disabledKeys,ref:o,orientation:e.orientation,layout:e.layout,direction:t}),dropTargetDelegate:new reactAria.ListDropTargetDelegate(r.collection,o)},i,o);return e.enableReorder?{collectionProps:n,dragState:a,dropState:i}:{collectionProps:{},dropState:void 0,dragState:void 0}}function Hf(e,r){if(typeof e!="object"||!e)return e;var o=e[Symbol.toPrimitive];if(o!==void 0){var t=o.call(e,r||"default");if(typeof t!="object")return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return (r==="string"?String:Number)(e)}function Of(e){var r=Hf(e,"string");return typeof r=="symbol"?r:String(r)}function Vf(e,r,o){return r=Of(r),r in e?Object.defineProperty(e,r,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[r]=o,e}function Cn(e,r){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);r&&(t=t.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),o.push.apply(o,t);}return o}function Pn(e){for(var r=1;r<arguments.length;r++){var o=arguments[r]!=null?arguments[r]:{};r%2?Cn(Object(o),!0).forEach(function(t){Vf(e,t,o[t]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):Cn(Object(o)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t));});}return e}function kn(e,r){var o={};for(var t in e)o[t]=r(e[t],t);return o}var Af=(e,r,o)=>{for(var t of Object.keys(e)){var a;if(e[t]!==((a=r[t])!==null&&a!==void 0?a:o[t]))return !1}return !0},_=e=>{var r=o=>{var t=e.defaultClassName,a=Pn(Pn({},e.defaultVariants),o);for(var i in a){var n,l=(n=a[i])!==null&&n!==void 0?n:e.defaultVariants[i];if(l!=null){var s=l;typeof s=="boolean"&&(s=s===!0?"true":"false");var p=e.variantClassNames[i][s];p&&(t+=" "+p);}}for(var[d,u]of e.compoundVariants)Af(d,a,e.defaultVariants)&&(t+=" "+u);return t};return r.variants=()=>Object.keys(e.variantClassNames),r.classNames={get base(){return e.defaultClassName.split(" ")[0]},get variants(){return kn(e.variantClassNames,o=>kn(o,t=>t.split(" ")[0]))}},r};var wn=_({defaultClassName:"_6n12k9b _1yep5z6l0 _1yep5z6kz _1yep5z6hk _1yep5z6ki",variantClassNames:{isDropTarget:{true:"_1yep5z612n"},orientation:{vertical:"_1yep5z6166",horizontal:"_1yep5z6167"}},defaultVariants:{},compoundVariants:[]}),Rn="_6n12k98 _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",In=_({defaultClassName:"_6n12k99 _1yep5z6ev _1yep5z6da _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),Tn=_({defaultClassName:"_6n12k91 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6dy _1yep5z6eu _1yep5z6ki _1yep5z6kl _1yep5z6ky _1yep5z6kx _1yep5z6kv _1yep5z6ks",variantClassNames:{isSelected:{},isFocused:{true:"_1yep5z612n _1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612w _1yep5z612x _1yep5z612y"},isHovered:{true:"_1yep5z6114",false:"_1yep5z6113"},isFirstChild:{true:"_6n12k95"},isLastChild:{true:"_6n12k96"},isDisabled:{true:"z9nup83 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Nn="_6n12k90";var Sn=_({defaultClassName:"gukncs0",variantClassNames:{isVertical:{true:"gukncs1"},isSecondary:{true:"gukncs2"}},defaultVariants:{},compoundVariants:[]});var H=so__default.default.forwardRef(({className:e,style:r,variant:o="primary",orientation:t="horizontal",UNSAFE_omitRole:a,elementType:i="div",...n},l)=>{let{separatorProps:s}=reactAria.useSeparator({...n,orientation:t,elementType:i});return jsxRuntime.jsx(i,{...s,className:utils.classNames(Sn({isVertical:t==="vertical",isSecondary:o==="secondary"}),"BaselineUI-Separator",e),"data-orientation":t,"data-block-id":n["data-block-id"],style:r,role:a?void 0:s.role,ref:l})});H.displayName="Separator";function Xf(e){return tokens.sprinkles.properties.has(e)}var M=so__default.default.forwardRef(({elementType:e="div",children:r,...o},t)=>{let a=e,{sprinkleProps:i,domProps:n}=so.useMemo(()=>{let l={},s={};for(let p in o)Xf(p)?l[p]=o[p]:s[p]=o[p];return {sprinkleProps:l,domProps:s}},[o]);return jsxRuntime.jsx(a,{...n,className:utils.classNames(tokens.sprinkles(i),"BaselineUI-Box",n.className),ref:t,children:r})});M.displayName="Box";var Xo=so__default.default.forwardRef(({item:e,isDisabled:r,isFocusVisible:o,isSelected:t,liProps:a,showSelectedIcon:i,description:n,descriptionProps:l,labelProps:s,isFocused:p,isPressed:d,_state:u},c)=>{utils.invariant(e.value&&(e.value.type==="option"||e.value.type===void 0),"Item cannot be a section");let{icon:m,label:f}=e.value,{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:r}),v=utils.filterTruthyValues({"data-selected":t,"data-disabled":r,"data-focused":p,"data-hovered":g,"data-pressed":d,"data-focus-visible":o,"data-selection-mode":u.selectionManager.selectionMode});return jsxRuntime.jsxs("li",{...reactAria.mergeProps(a,y,v),className:utils.classNames(Tn({isHovered:g,isFocused:o,isFirstChild:u.collection.getFirstKey()===e.key,isLastChild:u.collection.getLastKey()===e.key,isDisabled:r}),"BaselineUI-ListBox-Option"),ref:c,children:[jsxRuntime.jsxs(M,{display:"flex",alignItems:"center",gap:"lg",children:[i?jsxRuntime.jsx("span",{"aria-hidden":!0,style:{height:24,width:24},children:t?jsxRuntime.jsx(_24.CheckmarkIcon,{size:24}):null}):null,m?jsxRuntime.jsx(m,{size:24}):null,jsxRuntime.jsx("span",{...s,children:f})]}),n?jsxRuntime.jsx("span",{className:In({isDisabled:r}),...l,children:n}):null]})});Xo.displayName="DefaultRenderOption";var va=({dropState:e,orientation:r="vertical",dropIndicatorStyle:o,dropIndicatorClassName:t,renderDropIndicator:a=({isDropTarget:n,isHidden:l,dropIndicatorProps:s,orientation:p},d)=>l?null:jsxRuntime.jsx("li",{...s,ref:d,"data-drop-target":n,className:utils.classNames(wn({isDropTarget:n,orientation:p}),"BaselineUI-DropIndicator",t),style:o}),...i})=>{let n=so__default.default.useRef(null),{dropIndicatorProps:l,isHidden:s,isDropTarget:p}=reactAria.useDropIndicator(i,e,n);return a({dropIndicatorProps:{...l,role:"option"},isHidden:s,isDropTarget:p,orientation:r},n)};var Fn=({item:e,children:r,state:o,dragState:t,...a})=>{let{dragProps:i}=reactAria.useDraggableItem({key:e.key},t);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(va,{target:{type:"item",key:e.key,dropPosition:"before"},...a}),r(i),o.collection.getKeyAfter(e.key)==null&&jsxRuntime.jsx(va,{target:{type:"item",key:e.key,dropPosition:"after"},...a})]})};Fn.displayName="DraggableListOption";var Yo=so__default.default.forwardRef(({item:e,renderOption:r=(c,m,f)=>jsxRuntime.jsx(Xo,{item:c,liProps:m.optionProps,...m,ref:f}),showSelectedIcon:o,state:t,dragState:a,dropState:i,orientation:n,dropIndicatorStyle:l,dropIndicatorClassName:s,optionStyle:p,optionClassName:d},u)=>{let c=so__default.default.useRef(null),m=reactAria.useOption({key:e.key},t,c),{value:f}=e;utils.invariant(!!f),utils.invariant(!("children"in e),"ListSection should not be passed to ListOption");let y={style:typeof p=="function"?p(f):p,className:typeof d=="function"?d(f):d};return a&&i?jsxRuntime.jsx(Fn,{orientation:n,state:t,item:e,dropState:i,dragState:a,dropIndicatorStyle:l,dropIndicatorClassName:s,children:g=>r(e,{...m,showSelectedIcon:o,_state:t,optionProps:reactAria.mergeProps(m.optionProps,g,y)},N(c,u))}):r(e,{...m,showSelectedIcon:o,_state:t,optionProps:reactAria.mergeProps(m.optionProps,y)},N(c,u))});Yo.displayName="Option";var _a=({section:e,state:r,sectionClassName:o,sectionStyle:t,...a})=>{let{itemProps:i,groupProps:n}=reactAria.useListBoxSection({heading:e.rendered,"aria-label":e["aria-label"]}),l=r.collection.getChildren?.(e.key);utils.invariant(l,"items with type `section` must have children");let{value:s}=e,p=typeof t=="function"?t(s):t,d=typeof o=="function"?o(s):o;return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[e.key!==r.collection.getFirstKey()&&jsxRuntime.jsx(H,{UNSAFE_omitRole:!0}),jsxRuntime.jsx("li",{...i,style:{...i.style,...p},className:utils.classNames(Nn,d,"BaselineUI-ListBox-Section"),children:jsxRuntime.jsx("ul",{...n,children:[...l].map(u=>jsxRuntime.jsx(Yo,{item:u,state:r,...a},u.key))})})]})};_a.displayName="ListBoxSection";var Xe=so__default.default.createContext(null),za=so__default.default.forwardRef(({className:e,layout:r="stack",orientation:o="vertical",showSelectedIcon:t=!0,style:a,renderOption:i,enableReorder:n=!1,"data-block-id":l,renderDragPreview:s,onReorder:p,state:d,...u},c)=>{let m=so__default.default.useRef(null),{direction:f}=reactAria.useLocale(),y=so__default.default.useRef(null),{listBoxProps:g}=reactAria.useListBox({...u,shouldSelectOnPressUp:n,keyboardDelegate:new reactAria.ListKeyboardDelegate({collection:d.collection,ref:y,layout:r,orientation:o,direction:f,disabledKeys:d.disabledKeys})},d,y),v=web.useReducedMotion(),b=so.useCallback(T=>{let I=ye(y.current);p&&(!v&&"startViewTransition"in I?I.startViewTransition(()=>{p(T);}):p(T));},[p,v]),{collectionProps:h,dragState:z,dropState:x}=xn({...u,onReorder:b,layout:r,orientation:o,enableReorder:n,preview:m},d,y),{isFocusVisible:R,isFocused:C,focusProps:P}=reactAria.useFocusRing(),k=utils.filterTruthyValues({"data-block-id":l,"data-layout":r,"data-empty":d.collection.size===0,"data-focused":C,"data-focus-visible":R,"data-orientation":o});return jsxRuntime.jsxs("ul",{...reactAria.mergeProps(g,P,k,h),className:utils.classNames(Rn,"BaselineUI-ListBox",e),style:a,ref:N(c,y),children:[[...d.collection].map(T=>{let I={key:T.key,state:d,dragState:z,dropState:x,renderOption:i,renderDropIndicator:u.renderDropIndicator,showSelectedIcon:t,orientation:o,dropIndicatorStyle:u.dropIndicatorStyle,dropIndicatorClassName:u.dropIndicatorClassName,optionStyle:u.optionStyle,optionClassName:u.optionClassName};return T.type==="section"?jsxRuntime.jsx(_a,{...I,section:T}):jsxRuntime.jsx(Yo,{...I,item:T})}),s?jsxRuntime.jsx(reactAria.DragPreview,{ref:m,children:s}):null]})});za.displayName="ListBoxCore";var Hn=so__default.default.forwardRef((e,r)=>{let o=ae(),t=reactStately.useListState({...e,children:o});return jsxRuntime.jsx(za,{...e,ref:r,state:t})});Hn.displayName="ListBoxStandalone";var oe=so__default.default.forwardRef((e,r)=>{let o=so.useContext(Xe);return so.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?jsxRuntime.jsx(za,{...e,ref:r,state:o}):jsxRuntime.jsx(Hn,{...e,ref:r})});oe.displayName="ListBox";var $r="uf19bsg _1yep5z6ki",On=_({defaultClassName:"uf19bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0 _1yep5z6kx _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ks",variantClassNames:{size:{xxs:"uf19bs1",xs:"uf19bs2",sm:"uf19bs3",md:"uf19bs4",lg:"uf19bs5 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy"},isHovered:{true:"uf19bs6"},isDisabled:{true:"uf19bs7 _1yep5z610d"},isFocusVisible:{true:"uf19bs8"},variant:{primary:"uf19bs9",secondary:"uf19bsa",tertiary:"uf19bsb",ghost:"uf19bsc",toolbar:"_1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg",popover:"uf19bse _1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z6mn _1yep5z6mo _1yep5z6mp _1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nq _1yep5z6nr _1yep5z6ns _1yep5z6uz _1yep5z6v0 _1yep5z6v1"},isPressed:{true:"uf19bsf"}},defaultVariants:{},compoundVariants:[[{variant:"toolbar",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"primary",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"secondary",isHovered:!0,isFocusVisible:!1},"_1yep5z61ln"],[{variant:"tertiary",isHovered:!0,isFocusVisible:!1},"_1yep5z61lm _1yep5z61mg"],[{variant:"ghost",isHovered:!0,isFocusVisible:!1},"_1yep5z61ls"],[{variant:"popover",isHovered:!0,isFocusVisible:!1},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"toolbar",isPressed:!0},"_1yep5z61mg"],[{variant:"primary",isPressed:!0},"_1yep5z61mf"],[{variant:"secondary",isPressed:!0},"_1yep5z61ln"],[{variant:"tertiary",isPressed:!0},"_1yep5z61lq _1yep5z61mg"],[{variant:"ghost",isPressed:!0},"_1yep5z61lt"],[{variant:"popover",isPressed:!0},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"ghost",isDisabled:!1},"_1yep5z61lr"],[{variant:"popover",size:"lg"},"_1yep5z61h4 _1yep5z61h5 _1yep5z61h6 _1yep5z61hs _1yep5z61ht _1yep5z61hu _1yep5z61ig _1yep5z61ih _1yep5z61ii _1yep5z61j4 _1yep5z61j5 _1yep5z61j6"]]});var Zo=so__default.default.createContext({state:null,overlayTriggerAria:{triggerProps:{},overlayProps:{}},triggerRef:void 0}),Ye=({children:e,...r})=>{let o=so__default.default.useRef(null),t=reactStately.useOverlayTriggerState(r),a=reactAria.useOverlayTrigger(r,t),i=so.useMemo(()=>({state:t,overlayTriggerAria:a,triggerRef:o}),[t,a]);return jsxRuntime.jsx(Zo.Provider,{value:i,children:typeof e=="function"?e(t):e})};var An={bottom:"_1gzftth2",top:"_1gzftth3",right:"_1gzftth4",left:"_1gzftth5"},jn="_1gzftth1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",$n="_1gzftth6",Un="_1gzftth8",qn="_1gzftth7",Kn="var(--_1gzftth0)";function Gn(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 Ur=so__default.default.createContext({isSelected:!1,ref:void 0}),Ze=({children:e,anchorRect:r})=>{let{state:o,overlayTriggerAria:t,triggerRef:a}=so.useContext(Zo);utils.invariant(o,"PopoverTrigger must be used within a Popover");let{triggerProps:i}=t,n=so.useMemo(()=>({...i,isSelected:o.isOpen,ref:a}),[i,o.isOpen,a]);return utils.invariant(!r&&e||r&&!e,"Either one of anchorRect or children has to be provided."),utils.invariant(!r||Gn(r),"If provided, the anchorRect prop must be an object with left and top number values, and optionally width and height."),jsxRuntime.jsx(Ur.Provider,{value:n,children:r?jsxRuntime.jsx("button",{className:utils.classNames(Un,"BaselineUI-PopoverTrigger-Hidden"),style:r,ref:a,tabIndex:-1},JSON.stringify(r)):e})};var qr=e=>{let r=so__default.default.useRef(null),{ref:o,...t}=so.useContext(Ur)||{},{buttonProps:a,isPressed:i}=reactAria.useButton({...e,...t},r);return {buttonProps:a,isPressed:i,ref:N(r,o||null)}},Kr=(e,r)=>{let o=so__default.default.useRef(null),{ref:t,...a}=so.useContext(Ur)||{},{buttonProps:i,isPressed:n}=reactAria.useToggleButton({...e,...a},r,o);return {buttonProps:i,isPressed:n,ref:N(o,t||null)}};var Gr=_({defaultClassName:"oom8bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6dy _1yep5z6ki",variantClassNames:{variant:{primary:"oom8bs1",secondary:"oom8bs2",tertiary:"oom8bs3",ghost:"oom8bs4",popover:"oom8bs5",toolbar:"oom8bs6",success:"oom8bs7",warning:"oom8bs8",error:"oom8bs9"},isDisabled:{true:"oom8bsa"},isFocusVisible:{true:"oom8bsb"},isHovered:{true:"oom8bsc"},size:{sm:"oom8bsd",md:"oom8bse",lg:"oom8bsf"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isHovered:!0},"oom8bsg"],[{variant:"secondary",isHovered:!0},"oom8bsh"],[{variant:"tertiary",isHovered:!0},"oom8bsi"],[{variant:"popover",isHovered:!0},"oom8bsj"],[{variant:"ghost",isHovered:!0},"oom8bsk"],[{variant:"success",isHovered:!0},"oom8bsl"],[{variant:"warning",isHovered:!0},"oom8bsm"],[{variant:"error",isHovered:!0},"oom8bsn"],[{variant:"primary",isFocusVisible:!0},"oom8bso"],[{variant:"tertiary",isFocusVisible:!0},"oom8bsp"],[{variant:"success",isFocusVisible:!0},"oom8bsq"],[{variant:"warning",isFocusVisible:!0},"oom8bsr"],[{variant:"error",isFocusVisible:!0},"oom8bss"]]});var Wy={sm:16,md:20,lg:24},O=so__default.default.forwardRef(({label:e,style:r,className:o,iconStart:t,iconEnd:a,variant:i="primary",elementType:n="button",isDisabled:l,size:s="sm","data-block-id":p,...d},u)=>{let{buttonProps:c,isPressed:m,ref:f}=qr({...d,elementType:n,isDisabled:l}),y=Wy[s],{hoverProps:g,isHovered:v}=reactAria.useHover({isDisabled:l}),{isFocusVisible:b,isFocused:h,focusProps:z}=reactAria.useFocusRing(),x=utils.filterTruthyValues({"data-block-id":p,"data-disabled":l,"data-focused":h,"data-focus-visible":b,"data-hovered":v,"data-pressed":m});return jsxRuntime.jsxs(n,{...reactAria.mergeProps(c,g,z,x),className:utils.classNames(Gr({isDisabled:!!l,isFocusVisible:b,isHovered:v,variant:i,size:s}),"BaselineUI-ActionButton",o),style:r,ref:N(u,f),children:[!!t&&jsxRuntime.jsx(t,{size:y}),e,!!a&&jsxRuntime.jsx(a,{size:y}),i==="popover"&&jsxRuntime.jsx(_8.ChevronDownIcon,{size:8,className:$r})]})});O.displayName="ActionButton";var Zn=_({defaultClassName:"z9nup84",variantClassNames:{size:{xs:"z9nup85",sm:"z9nup86"}},defaultVariants:{},compoundVariants:[]});var Wr="z9nup80",po="z9nup83";var Qn="z9nup87";var Jn=so__default.default.forwardRef(({className:e,node:r},o)=>{let t=so__default.default.useRef(null);return so__default.default.useEffect(()=>{let a=t.current;return a?.append(r),()=>{a?.contains(r)&&r.remove();}},[r]),jsxRuntime.jsx("div",{className:utils.classNames(Wr,e),ref:N(o,t)})});Jn.displayName="DomNodeRenderer";var es="_14uvjig0 z9nup81",os="_14uvjig7",rs="_14uvjig3",ts=_({defaultClassName:"_14uvjig4",variantClassNames:{isDisabled:{true:"_14uvjig5"},hasNumberInput:{false:"_14uvjig6"}},defaultVariants:{},compoundVariants:[]}),as=_({defaultClassName:"_14uvjige _14uvjig1",variantClassNames:{active:{true:"_14uvjigf _14uvjig2"},isDisabled:{true:"_14uvjigg"},isReadOnly:{true:"_14uvjigh"},isFocusVisible:{true:"_14uvjigi _14uvjig2"},isHovered:{true:"_14uvjigj _14uvjig2"}},defaultVariants:{},compoundVariants:[]}),is="_14uvjig8",ns=_({defaultClassName:"_14uvjig9 _14uvjig1",variantClassNames:{active:{true:"_14uvjig2"},isFocusVisible:{true:"_14uvjigb _14uvjig2"},isDisabled:{true:"_14uvjigc"},isHovered:{true:"_14uvjig2"}},defaultVariants:{},compoundVariants:[]});var co=_({defaultClassName:"nrh1ehx",variantClassNames:{isDisabled:{true:"nrh1ehy"},hasError:{true:"nrh1ehz"},labelPosition:{start:"nrh1eh10",top:"nrh1eh11"}},defaultVariants:{},compoundVariants:[]}),Xr=_({defaultClassName:"nrh1eho",variantClassNames:{isDisabled:{true:"nrh1ehp"},labelPosition:{top:"nrh1ehq",start:"nrh1ehr"}},defaultVariants:{},compoundVariants:[]}),mo=_({defaultClassName:"nrh1ehs",variantClassNames:{validationState:{valid:"nrh1eht",error:"nrh1ehu",warning:"nrh1ehv"},isReadOnly:{true:"nrh1ehw"}},defaultVariants:{},compoundVariants:[]}),Me="nrh1eh3",Be=_({defaultClassName:"nrh1eh4",variantClassNames:{labelPosition:{top:"nrh1eh5",start:"nrh1eh6"},hasMessage:{true:"nrh1eh7"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"nrh1eh8"]]}),De=_({defaultClassName:"nrh1eh0",variantClassNames:{labelPosition:{top:"z9nup81",start:"nrh1eh2 z9nup82"}},defaultVariants:{},compoundVariants:[]}),uo=_({defaultClassName:"nrh1eh9 z9nup82",variantClassNames:{validationState:{valid:"nrh1eha",error:"nrh1ehb",warning:"nrh1ehc"},isHovered:{true:"nrh1ehd"},isFocused:{true:"nrh1ehe"},isDisabled:{true:"nrh1ehf"},variant:{primary:"nrh1ehg",ghost:"nrh1ehh"},isReadOnly:{true:"nrh1ehi"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"nrh1ehj"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"nrh1ehk"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"nrh1ehl"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"nrh1ehm"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"nrh1ehn"]]});function _e({description:e,errorMessageProps:r,descriptionProps:o,warningMessage:t,errorMessage:a,labelPosition:i,isDisabled:n}){return e?jsxRuntime.jsx("div",{...o,className:co({isDisabled:n,labelPosition:i}),children:e}):a?jsxRuntime.jsx("div",{...r,className:co({hasError:!0,labelPosition:i}),children:a}):t?jsxRuntime.jsx("div",{className:co({isDisabled:n,labelPosition:i}),children:t}):null}var ss=_({defaultClassName:"_1lnwne1 z9nup82",variantClassNames:{isHoveredOrFocused:{true:"_1lnwne2"},isInteractive:{false:"z9nup83"}},defaultVariants:{},compoundVariants:[[{isHoveredOrFocused:!0,isInteractive:!0},"_1lnwne4"]]}),ls="_1lnwne0";var i1={xxs:8,xs:12,sm:16,md:20,lg:24},L=so__default.default.forwardRef(({className:e,style:r,icon:o,size:t="md",variant:a="primary",UNSAFE_NON_INTERACTIVE:i,elementType:n=i?"div":"button",...l},s)=>{!l["aria-label"]&&!l["aria-labelledby"]&&console.warn("An `ActionIconButton` requires an aria-label or aria-labelledby prop.");let{buttonProps:p,isPressed:d,ref:u}=qr({...l,elementType:n}),{isFocusVisible:c,isFocused:m,focusProps:f}=reactAria.useFocusRing(),{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:l.isDisabled}),v=utils.filterTruthyValues({"data-block-id":l["data-block-id"],"data-focused":m,"data-focus-visible":c,"data-disabled":l.isDisabled,"data-hovered":g,"data-pressed":d});return jsxRuntime.jsxs(n,{...reactAria.mergeProps(p,y,f,v),className:utils.classNames(On({variant:a,size:t,isDisabled:!!l.isDisabled,isFocusVisible:c,isHovered:g,isPressed:d}),"BaselineUI-ActionIconButton",e),ref:N(s,u),style:r,...i&&{tabIndex:void 0,role:void 0,"aria-label":void 0,"aria-labelledby":void 0,"aria-disabled":void 0},children:[jsxRuntime.jsx(o,{role:"presentation",size:i1[t]}),a==="popover"&&jsxRuntime.jsx(_8.ChevronDownIcon,{size:8,className:$r})]})});L.displayName="ActionIconButton";var Ie=so__default.default.forwardRef(({className:e,style:r,labelPosition:o="top",variant:t="primary",showStepper:a=!0,...i},n)=>{let l=so__default.default.useRef(null),{locale:s}=reactAria.useLocale(),p=reactStately.useNumberFieldState({...i,locale:s}),{hoverProps:d,isHovered:u}=reactAria.useHover({isDisabled:i.isDisabled}),{focusProps:c,isFocusVisible:m,isFocused:f}=reactAria.useFocusRing(),{labelProps:y,decrementButtonProps:g,inputProps:v,incrementButtonProps:b,groupProps:h,descriptionProps:z,errorMessageProps:x}=reactAria.useNumberField(i,p,l),R=so.useMemo(()=>i.isReadOnly?_16.ReadOnlyIcon:i.isInvalid?_16.ErrorFilledIcon:null,[i.isInvalid,i.isReadOnly]),C=_e({description:i.description,errorMessageProps:x,descriptionProps:z,errorMessage:i.errorMessage,labelPosition:o,isDisabled:i.isDisabled}),P=utils.filterTruthyValues({"data-disabled":i.isDisabled,"data-readonly":i.isReadOnly,"data-hovered":u,"data-focused":f,"data-focus-visible":m,"data-invalid":i.isInvalid,"data-block-id":i["data-block-id"]});return jsxRuntime.jsxs("div",{style:r,className:utils.classNames(De({labelPosition:o}),"BaselineUI-NumberInput",e),...P,ref:n,children:[i.label?jsxRuntime.jsxs("div",{className:Be({labelPosition:o,hasMessage:!!C}),children:[jsxRuntime.jsx("label",{...y,className:Me,children:i.label}),o==="start"&&C]}):null,jsxRuntime.jsxs("div",{className:utils.classNames({[po]:i.isDisabled}),children:[jsxRuntime.jsxs("div",{...reactAria.mergeProps(h,d),className:utils.classNames(uo({isHovered:u,isDisabled:!!i.isDisabled,isReadOnly:!!i.isReadOnly,validationState:i.isInvalid?"error":"valid",isFocused:f,variant:t}),{[ls]:o==="start"},"BaselineUI-NumberInput-Container"),children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(v,c),ref:l,className:utils.classNames("BaselineUI-NumberInput-Input",Xr({isDisabled:i.isDisabled,labelPosition:o}))}),R?jsxRuntime.jsx(R,{className:mo({validationState:"error",isReadOnly:i.isReadOnly}),size:16}):null,a?jsxRuntime.jsxs("div",{className:ss({isHoveredOrFocused:u||f,isInteractive:!i.isReadOnly&&!i.isDisabled}),children:[jsxRuntime.jsx(L,{variant:"secondary",size:"xxs",icon:_8.MinusIcon,...g,className:"BaselineUI-NumberInput-DecrementButton"}),jsxRuntime.jsx(H,{style:{height:16},orientation:"vertical"}),jsxRuntime.jsx(L,{variant:"secondary",size:"xxs",icon:_8.PlusIcon,...b,className:"BaselineUI-NumberInput-DecrementButton"})]}):null]}),o==="top"&&C]})]})});Ie.displayName="NumberInput";var Qr=so__default.default.forwardRef(({className:e,style:r,onChange:o,onChangeEnd:t,numberFormatOptions:a,isDisabled:i,step:n,minValue:l,maxValue:s,value:p,"aria-label":d,"aria-labelledby":u,"aria-details":c,"aria-describedby":m,"data-block-id":f,defaultValue:y,isReadOnly:g,label:v,id:b,includeNumberInput:h},z)=>{let x=so__default.default.useRef(null),R={onChange:o===void 0?void 0:E=>{o(E[0]);},isDisabled:i||g,step:n,minValue:l,maxValue:s,onChangeEnd:t===void 0?void 0:E=>{t(E[0]);},value:p===void 0?void 0:[p],defaultValue:y===void 0?void 0:[y],"aria-label":d,"aria-labelledby":u,"aria-details":c,"aria-describedby":m,id:b,label:v},C=reactAria.useNumberFormatter(a),P=reactStately.useSliderState({...R,numberFormatter:C}),{trackProps:k,groupProps:T,labelProps:I}=reactAria.useSlider(R,P,x),B=jsxRuntime.jsx(Ie,{variant:"ghost",showStepper:!1,"aria-label":d,"aria-labelledby":I.id,value:P.getThumbValue(0),formatOptions:a,onChange:E=>{P.setThumbValue(0,E);},style:{width:55,textAlign:"right",flexShrink:0}});return jsxRuntime.jsxs("div",{...T,style:r,"data-block-id":f,className:utils.classNames(es,"BaselineUI-Slider",e),children:[v?jsxRuntime.jsxs("div",{className:rs,children:[jsxRuntime.jsx("label",{...I,className:utils.classNames(ts({isDisabled:i,hasNumberInput:!!h}),"BaselineUI-Slider-Label"),children:v}),h?B:null]}):null,jsxRuntime.jsxs("div",{className:os,children:[jsxRuntime.jsx("div",{...k,className:utils.classNames(is,"BaselineUI-Slider-Track"),ref:N(x,z),"data-testid":"track",children:jsxRuntime.jsx(w1,{state:P,trackRef:x,isDisabled:i,isReadOnly:g})}),h&&!v?B:null]})]})});Qr.displayName="Slider";function w1({state:e,trackRef:r,isDisabled:o,isReadOnly:t}){let a=so__default.default.useRef(null),{thumbProps:i,inputProps:n,isDragging:l}=reactAria.useSliderThumb({trackRef:r,inputRef:a},e),{focusProps:s,isFocused:p,isFocusVisible:d}=reactAria.useFocusRing(),{hoverProps:u,isHovered:c}=reactAria.useHover({isDisabled:o}),m=utils.filterTruthyValues({"data-disabled":o,"data-readonly":t,"data-hovered":c,"data-focus-visible":d,"data-dragging":l,"data-focused":p});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:utils.classNames(ns({isDisabled:o,isFocusVisible:d,active:l,isHovered:c}),"BaselineUI-Slider-TrackHighlight"),style:{width:i.style?.left},"data-testid":"track-highlight"}),jsxRuntime.jsx("div",{...reactAria.mergeProps(i,u,m),className:utils.classNames(as({isDisabled:o,isFocusVisible:d,active:l,isReadOnly:t,isHovered:c}),"BaselineUI-Slider-Thumb"),"data-testid":"thumb",children:jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{ref:a,...reactAria.mergeProps(n,s)})})})]})}var us=_({defaultClassName:"bpklwa7",variantClassNames:{isReadOnly:{true:"bpklwa8"},isDisabled:{true:"bpklwa9"},isSelected:{true:"bpklwaa"},isFocused:{true:"bpklwab"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"bpklwac"]]}),fs=_({defaultClassName:"bpklwae",variantClassNames:{isDisabled:{true:"bpklwaf"},isSelected:{true:"bpklwag"},isReadOnly:{true:"bpklwah"}},defaultVariants:{},compoundVariants:[]}),ys="bpklwad",bs=_({defaultClassName:"bpklwa0",variantClassNames:{labelPosition:{top:"bpklwa1",left:"bpklwa2"}},defaultVariants:{},compoundVariants:[]}),gs="bpklwa6",vs=_({defaultClassName:"bpklwa3",variantClassNames:{labelPosition:{top:"bpklwa4",left:"bpklwa5"}},defaultVariants:{},compoundVariants:[]});var xs=so__default.default.forwardRef(({className:e,label:r,labelPosition:o="top",statusLabel:t,style:a,"data-block-id":i,...n},l)=>{let s=so__default.default.useRef(null),p=reactStately.useToggleState(n),{inputProps:d,isPressed:u}=reactAria.useSwitch(n,p,s),{isFocusVisible:c,focusProps:m}=reactAria.useFocusRing(),{hoverProps:f,isHovered:y}=reactAria.useHover({isDisabled:n.isDisabled}),g=utils.filterTruthyValues({"data-block-id":i,"data-focused":c,"data-disabled":n.isDisabled,"data-focus-visible":c,"data-selected":p.isSelected,"data-readonly":n.isReadOnly,"data-hovered":y,"data-pressed":u}),v=jsxRuntime.jsx("div",{className:utils.classNames(us({isSelected:p.isSelected,isDisabled:!!n.isDisabled,isFocused:c,isReadOnly:!!n.isReadOnly}),"BaselineUI-Switch-Track"),children:jsxRuntime.jsx("div",{className:utils.classNames(fs({isSelected:p.isSelected,isDisabled:n.isDisabled,isReadOnly:n.isReadOnly}),"BaselineUI-Switch-Knob"),"data-testid":"switch-knob"})});return jsxRuntime.jsxs("label",{...reactAria.mergeProps(g,f),className:utils.classNames(bs({labelPosition:o}),"BaselineUI-Switch",e),style:a,ref:l,children:[r?jsxRuntime.jsx("span",{className:utils.classNames(ys,"BaselineUI-Switch-Label"),children:r}):null,jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(d,m),ref:s})}),t?jsxRuntime.jsxs("div",{className:vs({labelPosition:o}),children:[jsxRuntime.jsx("span",{className:utils.classNames("BaselineUI-Switch-Status-Label",gs),children:p.isSelected?t.on:t.off}),v]}):v]})});xs.displayName="Switch";var Cs="_19n40yy9",Ps=_({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 $1={sm:_20.SearchIcon,md:_24.SearchIcon,lg:_24.SearchIcon},Rs=so__default.default.forwardRef(({className:e,size:r="md",variant:o="primary",...t},a)=>{let i=so__default.default.useRef(null),n=reactStately.useSearchFieldState(t),{inputProps:l,clearButtonProps:s}=reactAria.useSearchField({...t,"aria-haspopup":!1,"aria-autocomplete":"none",type:"search"},n,i),{focusProps:p,isFocusVisible:d,isFocused:u}=reactAria.useFocusRing({within:!0,isTextInput:!0}),c=$1[r],m=r==="sm"?_12.XIcon:_16.XIcon,f=utils.filterTruthyValues({"data-block-id":t["data-block-id"],"data-focused":u,"data-disabled":t.isDisabled,"data-focus-visible":d});return jsxRuntime.jsxs("div",{...f,className:utils.classNames(Ps({size:r,isFocused:u,variant:o,hasText:!!n.value,isDisabled:t.isDisabled}),"BaselineUI-SearchInput",e),ref:a,children:[jsxRuntime.jsx(c,{size:r==="sm"?20:24}),jsxRuntime.jsx("input",{...reactAria.mergeProps(l,p),className:Cs,ref:i}),n.value!==""&&jsxRuntime.jsx(L,{icon:m,...s,size:r==="sm"?"xs":"sm",variant:"secondary"})]})});Rs.displayName="SearchInput";function Ts({ref:e,onIntersect:r,isDisabled:o,threshold:t,rootMargin:a,root:i}){let n=so__default.default.useRef(null);so.useEffect(()=>{if(o){n.current?.disconnect(),n.current=null;return}n.current=new IntersectionObserver(([l])=>{r(l);},{root:i?.current,rootMargin:a,threshold:t});},[r,o,i,a,t]),so.useEffect(()=>{let{current:l}=n;return e.current&&l?.observe(e.current),()=>l?.disconnect()},[e]);}function Ns({ref:e,onResize:r,isDisabled:o}){let t=so__default.default.useRef(null),[a,i]=so__default.default.useState();return so__default.default.useEffect(()=>{if(o){t.current?.disconnect(),t.current=null;return}t.current=new ResizeObserver(([n])=>{i(n.contentRect),r?.(n);});},[r,o,i]),so__default.default.useEffect(()=>{let{current:n}=t;return e.current&&n?.observe(e.current),()=>n?.disconnect()},[e]),{size:a}}function bo({src:e,alt:r}){let[o,t]=so.useState(!1),[a,i]=so.useState(!1),[n,l]=so.useState(!1),s=()=>{t(!0),l(!1);},p=()=>{i(!0),l(!1);};return so.useEffect(()=>{if(!e)return;l(!0);let d=new Image;return d.src=e,d.addEventListener("load",s),d.addEventListener("error",p),()=>{d.removeEventListener("load",s),d.removeEventListener("error",p);}},[e]),{isLoaded:o,hasError:a,isLoading:n,imgProps:{src:o?e:void 0,alt:r}}}function Fe(){let e=so.useRef(!0);return so.useEffect(()=>{e.current=!1;},[]),e.current}var Ss="SET_STATE",et="UNDO",ot="REDO",Q1=(e,r)=>{let{past:o,present:t,future:a}=e;switch(r.type){case Ss:return {past:[...o,t],present:r.data,future:[]};case et:return {past:o.slice(0,o?.length-1),present:o[o?.length-1],future:[t,...a]};case ot:return {past:[...o,t],present:a[0],future:a.slice(1)};default:throw new Error("Invalid action type")}},Ls=(e={},{isDisabled:r,onAction:o})=>{let t=Fe(),[a,i]=so.useReducer(Q1,{past:[],present:e,future:[]}),{past:n,present:l,future:s}=a,p=y=>{i({type:Ss,data:y});},d=so.useRef(),u=()=>{d.current=et,i({type:et});},c=()=>{d.current=ot,i({type:ot});},m=!!n?.length,f=!!s?.length;return granularHooks.useGranularEffect(()=>{(d.current===et||d.current===ot)&&(o?.(l,d.current),d.current=void 0);},[l],[o,t]),{state:l,push:r?()=>{}:p,undo:r?()=>{}:u,redo:r?()=>{}:c,pastStates:n,futureStates:s,canUndo:m,canRedo:f}};var Ia=so__default.default.createContext({messages:{}}),Ds=({children:e,messages:r={},...o})=>{let t=so__default.default.useMemo(()=>({messages:r}),[r]);return jsxRuntime.jsx(reactAria.I18nProvider,{...o,children:jsxRuntime.jsx(Ia.Provider,{value:t,children:e})})};Ds.displayName="I18nProvider";function D(e){let{messages:r}=so.useContext(Ia);!e&&ob__default.default(r)&&console.warn("BUI \u{1F30D}: No messages object provided and no messages found in the `I18nProvider`. Please provide a messages object to the `useI18n` hook.");let o=reactAria.useMessageFormatter(e?utils.cleanKeyFromGlobImport(e):r),t=reactAria.useLocale();return {formatMessage:(a,i)=>{if(typeof a=="object")try{return o(a.id,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.id.toString()}\`. The default message, i.e. \`${a.defaultMessage}\`, will be used instead.`),a.defaultMessage||a.id}else try{return o(a,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.toString()}\`. The default message, i.e. \`${a.toString()}\`, will be used instead.`),a}},locale:t}}var A=e=>e;function vN(e,r,o){let t=so__default.default.useRef(null);return so__default.default.useEffect(()=>{if(e)return t.current=new MutationObserver(o),t.current.observe(e,r),()=>{t.current&&t.current.disconnect();}},[e,r,o]),t.current}function Fs(e,r){let[o,t]=so.useState(()=>{try{let i=window.localStorage.getItem(e);return i?JSON.parse(i):r}catch(i){return console.log(i),r}});return [o,i=>{try{let n=i instanceof Function?i(o):i;t(n),window.localStorage.setItem(e,JSON.stringify(n));}catch(n){console.log(n);}}]}function kN({ref:e,onSelectionChange:r,onSelectionEnd:o,isDisabled:t}){let a=so__default.default.useRef(null);reactAria.usePress({ref:e,isDisabled:t,onPressEnd(){let n=Q(e.current).getSelection();n&&e.current?.contains(n.anchorNode)&&o?.(n);},onPressStart(){let i=Q(e.current);a.current=i.getSelection(),a.current&&a.current.removeAllRanges();}}),so.useEffect(()=>{let i=e.current;if(!i||t)return;function n(){let p=Q(i).getSelection();p&&e.current?.contains(p.anchorNode)&&r(p);}let l=ye(i);return l.addEventListener("selectionchange",n),()=>{l.removeEventListener("selectionchange",n);}},[e,r,t]);}function go(e){let r=so.useCallback(()=>{let a=Q(e??document.body),i=a.matchMedia(tokens.queries.tablet);return a.matchMedia(tokens.queries.desktop).matches?"desktop":i.matches?"tablet":"mobile"},[e]),[o,t]=so__default.default.useState(r);return we(()=>{let a=Q(e),i=()=>{t(r());};return a.addEventListener("resize",i),i(),()=>{a.removeEventListener("resize",i);}},[e,r]),o}var Ta=so__default.default.createContext(void 0),Os=({portalContainer:e,children:r})=>jsxRuntime.jsx(Ta.Provider,{value:e,children:r});Os.displayName="PortalContainerProvider";function le(e){let r=so.useContext(Ta);return e||r}var vb=["append","prepend","insert","insertBefore","insertAfter","remove","removeSelectedItems","move","moveBefore","moveAfter","update"];function As(e){let{onListChange:r,onSelectionChange:o,...t}=e,a=reactStately.useListData({...t,initialItems:e.initialItems||[]}),i=so.useRef(e.initialItems),n=so.useCallback(()=>{r&&r(a.items);},[r,a.items]),l=so.useCallback(()=>{o&&o(a.selectedKeys);},[o,a.selectedKeys]),s=so.useCallback(d=>e.getKey?e.getKey(d):d.id||d.key,[e]);granularHooks.useGranularEffect(n,[a.items,e.initialItems],[n]),granularHooks.useGranularEffect(l,[a.selectedKeys,e.initialItems],[l]),so.useEffect(()=>{let d=(y,g)=>y.filter(v=>!g.some(b=>vo__default.default(v,b))),u=(y,g)=>g.filter(v=>!y.some(b=>vo__default.default(v,b))),c=y=>{y.length>0&&a.remove(...y.map(g=>s(g)));},m=(y,g)=>{if(y.length>0){let v=g.findIndex(b=>y.some(h=>vo__default.default(b,h)));if(v===0)a.prepend(...y);else if(v>0){let b=g[v-1],h=a.items.findIndex(z=>vo__default.default(z,b));a.insertAfter(s(a.items[h]),...y);}else a.append(...y);}},f=y=>{for(let[g,v]of y.entries()){let b=a.items.findIndex(h=>vo__default.default(h,v));b!==-1&&b!==g&&a.move(s(a.items[b]),g);}};if(!vo__default.default(i.current,e.initialItems)){let y=a.items,g=e.initialItems||[],v=d(y,g);c(v);let b=u(y,g);m(b,g),f(g),i.current=g;}},[e.initialItems,a,s]);let p=so.useMemo(()=>{let d={};for(let u of vb)d[u]=(...c)=>{let m=a[u](...c);return n(),(u==="remove"||u==="removeSelectedItems")&&l(),m};return d},[a,n,l]);return {...a,...p}}function Sa(e=window){let[r,o]=so.useState("light"),[t,a]=so.useState(!1),[i,n]=so.useState(!1),[l,s]=so.useState(!1);return so.useEffect(()=>{let p=e.matchMedia("(prefers-color-scheme: dark)"),d=u=>{o(u.matches?"dark":"light");};return p.matches&&o("dark"),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),so.useEffect(()=>{let p=e.matchMedia("(prefers-contrast: more)"),d=u=>{a(u.matches);};return a(p.matches),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),so.useEffect(()=>{let p=e.matchMedia("(prefers-reduced-motion: reduce)"),d=u=>{n(u.matches);};return p.matches&&n(!0),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),so.useEffect(()=>{let p=e.matchMedia("(prefers-reduced-transparency: reduce)"),d=u=>{s(u.matches);};return p.matches&&s(!0),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),{colorScheme:r,highContrast:t,reducedMotion:i,transparency:l}}var _o=so.createContext({theme:tokens.lightTheme,setTheme:()=>{}});var js="var(--hj25q10)";var at={LIGHT:{name:"light",theme:tokens.lightTheme},DARK:{name:"dark",theme:tokens.darkTheme}},zo=so__default.default.forwardRef(({theme:e="system",children:r,setTheme:o,className:t,style:a,UNSAFE_domProps:i,"data-block-id":n},l)=>{let{direction:s}=reactAria.useLocale(),{colorScheme:p,reducedMotion:d,highContrast:u,transparency:c}=Sa(),{name:m,theme:f}=so.useMemo(()=>{switch(e){case"system":return p==="light"?at.LIGHT:at.DARK;case"light":return at.LIGHT;case"dark":return at.DARK;default:return {name:"custom",theme:e}}},[p,e]),y=go(),g={"data-theme":m,"data-block-id":n,"data-reduced-motion":d,"data-high-contrast":u,"data-transparency":c,"data-device":y},v=so.useMemo(()=>({theme:f,setTheme:o}),[f,o]);return jsxRuntime.jsx(_o.Provider,{value:v,children:jsxRuntime.jsx("div",{...reactAria.mergeProps(i,g),className:utils.classNames(Wr,"BaselineUI-ThemeProvider",t),style:{...dynamic.assignInlineVars(tokens.themeVars,f),...dynamic.assignInlineVars({[js]:s==="rtl"?"-1":"1"}),...a},ref:l,children:r})})});zo.displayName="ThemeProvider";var Ks=_({defaultClassName:"_1mdhlqv3",variantClassNames:{isOpen:{true:"_1mdhlqv4"}},defaultVariants:{},compoundVariants:[]}),it="_1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Gs=_({defaultClassName:"_1mdhlqv0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6eu _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy",variantClassNames:{isFocused:{false:"_1mdhlqv1"},isDisabled:{true:"z9nup83 _1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),Ws="_1mdhlqv7 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs",Xs="_1yep5z66x _1yep5z66y _1yep5z66z",Ys="_1mdhlqv5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k";var ho=so__default.default.forwardRef(({className:e,style:r,children:o,...t},a)=>{let{theme:i}=so.useContext(_o);return jsxRuntime.jsx(reactAria.Overlay,{...t,children:jsxRuntime.jsx(zo,{ref:a,theme:i,style:r,className:utils.classNames("BaselineUI-Portal",e),children:o})})});ho.displayName="Portal";function Qs({placement:e}){let r=web.useReducedMotion();return web.useTransition(!0,{from:{opacity:0,transform:`translate3d(${e==="bottom"?"0, 4px, 0":"0, -4px, 0"})`},enter:{opacity:1,transform:"translate3d(0, 0, 0)"},immediate:!!r,config:web.config.stiff})}var{color:La}=tokens.themeVars,ie=so__default.default.forwardRef(({className:e,style:r,state:o,overlayProps:t,underlayClassName:a,children:i,includeArrow:n=!1,offset:l=2,portalContainer:s,contentContainerClassName:p,contentContainerStyle:d,...u},c)=>{let m=so__default.default.useRef(null),f=le(s),y=n?8:0,{underlayProps:g,popoverProps:v,placement:b,arrowProps:h}=reactAria.usePopover({...u,offset:l+y,popoverRef:m,containerPadding:u.containerPadding||0},o),z=Qs({placement:b}),x=b==="center"?"bottom":b;return z((R,C)=>C&&jsxRuntime.jsxs(ho,{portalContainer:f,style:r,ref:c,children:[!u.isNonModal&&jsxRuntime.jsx("div",{...g,className:utils.classNames(qn,a,"BaselineUI-Popover-Underlay")}),jsxRuntime.jsxs(web.animated.div,{...v,style:{...v.style,...R,...dynamic.assignInlineVars({[Kn]:`${u.triggerRef?.current?.offsetWidth}px`})},ref:N(m,c),className:utils.classNames(jn,"BaselineUI-Popover-Content",e),"data-placement":["top","bottom","left","right"].filter(P=>b?.includes(P)),children:[n?jsxRuntime.jsxs("svg",{className:utils.classNames(An[x],"BaselineUI-PopoverContent-Arrow"),...h,style:{...h.style,position:"absolute"},width:"15",height:"9",viewBox:"0 0 15 9",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M.019 0h1.228l6.272 7.237L13.791 0h1.228v1h-.772L7.519 8.763.791 1H.019V0Z",fill:La.border.medium}),jsxRuntime.jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:La.background.primary.subtle,stroke:La.background.primary.subtle})]}):null,jsxRuntime.jsx(reactAria.DismissButton,{onDismiss:o.close}),jsxRuntime.jsx("div",{...t,style:d,className:utils.classNames($n,p),children:i}),jsxRuntime.jsx(reactAria.DismissButton,{onDismiss:o.close})]})]}))});ie.displayName="PopoverContentCore";var ol="xyd2ss1 _1yep5z613 _1yep5z614 _1yep5z615 _1yep5z63f _1yep5z63g _1yep5z63h _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b _1yep5z65r _1yep5z65s _1yep5z65t _1yep5z683 _1yep5z684 _1yep5z685 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z66x _1yep5z66y _1yep5z66z _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6l0 _1yep5z6kz _1yep5z6he _1yep5z6l3 _1yep5z6fs",rl="xyd2ss0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b";var Ba=({section:e,showSelectedIcon:r,state:o})=>{let{itemProps:t,groupProps:a,headingProps:i}=reactAria.useMenuSection({heading:e.value?.title,"aria-label":e["aria-label"]});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[e.key!==o.collection.getFirstKey()&&jsxRuntime.jsx(H,{elementType:"li"}),jsxRuntime.jsxs("li",{...t,children:[e.value?.title?jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("span",{...i,children:e.value.title})}):null,jsxRuntime.jsx("ul",{...a,className:rl,children:[...e.childNodes].map(n=>(utils.invariant(n.type==="item"),jsxRuntime.jsx(st,{item:n,state:o,showSelectedIcon:r},n.key)))})]})]})};Ba.displayName="MenuSection";var st=({item:e,state:r,className:o,showSelectedIcon:t})=>{let a=so__default.default.useRef(null),i=reactAria.useMenuItem({key:e.key},r,a),{isFocusVisible:n,focusProps:l}=reactAria.useFocusRing();return jsxRuntime.jsx(Xo,{item:e,liProps:reactAria.mergeProps(i.menuItemProps,l,{className:o}),...i,isFocusVisible:n,ref:a,description:e.value?.keyboardShortcut,descriptionProps:i.keyboardShortcutProps,_state:r,showSelectedIcon:t})};st.displayName="MenuItem";var Ea=so__default.default.forwardRef(({className:e,itemClassName:r,onContentKeyDown:o,...t},a)=>{let i=reactStately.useTreeState(t),n=so__default.default.useRef(null),{menuProps:l}=reactAria.useMenu(t,i,n),{keyboardProps:s}=reactAria.useKeyboard({onKeyDown:o});return jsxRuntime.jsx("ul",{...reactAria.mergeProps(l,s),className:utils.classNames(ol,e),ref:N(n,a),children:[...i.collection].map(p=>p.type==="section"?jsxRuntime.jsx(Ba,{section:p,state:i,showSelectedIcon:t.selectionMode==="multiple"||t.selectionMode==="single"},p.key):jsxRuntime.jsx(st,{item:p,state:i,className:r,showSelectedIcon:t.selectionMode==="multiple"||t.selectionMode==="single"},p.key))})});Ea.displayName="MenuContent";var lt=so__default.default.forwardRef(({defaultOpen:e,onOpenChange:r,isOpen:o,isDisabled:t,contentClassName:a,placement:i="bottom start",isNonModal:n,shouldFlip:l,shouldUpdatePosition:s,boundaryElement:p,crossOffset:d,offset:u,triggerLabel:c,renderTrigger:m=({buttonProps:v,ref:b})=>jsxRuntime.jsx(O,{...v,variant:"popover",ref:b}),portalContainer:f,...y},g)=>{let v=so__default.default.useRef(null),b=le(f),h=reactStately.useMenuTriggerState({defaultOpen:e,isOpen:o,onOpenChange:r}),{menuTriggerProps:z,menuProps:x}=reactAria.useMenuTrigger({isDisabled:t,type:"menu"},h,v),R=ae(),C=so.useMemo(()=>reactAria.mergeProps(z,{isDisabled:t,isSelected:h.isOpen,className:"BaselineUI-Menu-Trigger",label:c}),[z,t,h.isOpen,c]);return so.useEffect(()=>{!c&&!m&&console.warn("The `triggerLabel` prop is required when no `renderTrigger` or `children` is provided.");},[m,c]),jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[m({buttonProps:C,ref:v}),h.isOpen?jsxRuntime.jsx(ie,{triggerRef:v,state:h,placement:i,isNonModal:n,shouldFlip:l,shouldUpdatePosition:s,boundaryElement:p,crossOffset:d,offset:u||2,className:utils.classNames(it,"BaselineUI-Menu-Popover"),portalContainer:b,children:jsxRuntime.jsx(Ea,{className:a,...x,...y,ref:g,autoFocus:h.focusStrategy||"first",children:R})}):null]})});lt.displayName="Menu";var pt=_({defaultClassName:"_13f0naj0",variantClassNames:{variant:{default:"_13f0naj1",inline:"_13f0naj2"},isHovered:{true:"_13f0naj3"},isFocusVisible:{true:"_13f0naj4"},isDisabled:{true:"_13f0naj5"},size:{sm:"_13f0naj6",md:"_13f0naj7",lg:"_13f0naj8"},type:{body:"_13f0naj9",label:"_13f0naja"},isActive:{true:"_13f0najb"}},defaultVariants:{},compoundVariants:[[{isActive:!0,isDisabled:!1},"_13f0najc"],[{type:"body",size:"sm"},"_13f0najd"],[{type:"body",size:"md"},"_13f0naje"],[{type:"body",size:"lg"},"_13f0najf"],[{type:"label",size:"sm"},"_13f0najg"],[{type:"label",size:"md"},"_13f0najh"],[{type:"label",size:"lg"},"_13f0naji"]]});var sl=so__default.default.forwardRef(({className:e,style:r,children:o,variant:t="default",size:a="md",elementType:i="a",type:n="body","data-block-id":l,title:s,...p},d)=>{let u=so__default.default.useRef(null),{linkProps:c,isPressed:m}=reactAria.useLink({...p,elementType:p.onPress?"span":i},u),{isFocusVisible:f,isFocused:y,focusProps:g}=reactAria.useFocusRing(),{hoverProps:v,isHovered:b}=reactAria.useHover({isDisabled:p.isDisabled}),h=i,z=utils.filterTruthyValues({"data-block-id":l,"data-disabled":p.isDisabled,"data-focused":y,"data-pressed":m,"data-focus-visible":f,"data-hovered":b,title:s});return jsxRuntime.jsx(h,{...reactAria.mergeProps(c,g,v,z),className:utils.classNames(pt({variant:t,isFocusVisible:f,isHovered:b,isDisabled:p.isDisabled,size:a,isActive:m,type:n}),"BaselineUI-Link",e),ref:N(u,d),style:r,children:o})});sl.displayName="Link";function ll({isDisabled:e,onValueChange:r,onChange:o,name:t,"aria-describedby":a,"aria-label":i,accept:n,multiple:l}){let s=reactAria.useId(),p=reactAria.useId(),d=reactAria.useId();return {inputProps:{type:"file",id:p,disabled:!!e,"aria-labelledby":i?void 0:s,"aria-describedby":a||d,"aria-label":i,onChange:c=>{let m=[...c.target.files||[]];r?.(m),o?.(c);},name:t,accept:n,multiple:l},labelProps:{htmlFor:p,id:s},descriptionProps:{id:d}}}async function Oa({items:e}){let r=e.filter(o=>o.kind==="file").map(async o=>(utils.invariant(o.kind==="file"),o.getFile()));return await Promise.all(r)}var pl=_({defaultClassName:"_180w5ed0",variantClassNames:{variant:{default:"_180w5ed1",inline:"_180w5ed2"},hoveredOrFocusedOrActive:{true:"_180w5ed3"},disabled:{true:"_180w5ed4"}},defaultVariants:{},compoundVariants:[[{variant:"inline",hoveredOrFocusedOrActive:!0},"_180w5ed5"],[{variant:"default",hoveredOrFocusedOrActive:!0},"_180w5ed6"],[{variant:"default",disabled:!0},"_180w5ed7"],[{variant:"inline",disabled:!0},"_180w5ed8"]]}),cl=_({defaultClassName:"_180w5ede",variantClassNames:{disabled:{true:"_180w5edf"}},defaultVariants:{},compoundVariants:[]}),dl=_({defaultClassName:"_180w5ed9",variantClassNames:{disabled:{true:"_180w5eda"}},defaultVariants:{},compoundVariants:[]}),ml=_({defaultClassName:"_180w5edb",variantClassNames:{disabled:{true:"_180w5edc"},hovered:{true:"_180w5edd"}},defaultVariants:{},compoundVariants:[]});var bl=so__default.default.forwardRef(({className:e,label:r,description:o,icon:t,variant:a="default",...i},n)=>{let l=so__default.default.useRef(null),{inputProps:s,descriptionProps:p,labelProps:d}=ll(i),{dropProps:u}=reactAria.useDrop({ref:l,onDrop:async({items:g})=>{let v=g.filter(h=>h.kind==="file").map(async h=>(utils.invariant(h.kind==="file"),h.getFile())),b=await Promise.all(v);i.onValueChange?.(b);}}),{focusProps:c,isFocusVisible:m}=reactAria.useFocusRing(),{hoverProps:f,isHovered:y}=reactAria.useHover({isDisabled:i.isDisabled});return jsxRuntime.jsxs("label",{...reactAria.mergeProps(u,f,d),className:utils.classNames(pl({variant:a,disabled:i.isDisabled,hoveredOrFocusedOrActive:y||m}),e),ref:N(n,l),children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(c,s)})}),t?jsxRuntime.jsx(t,{size:20,className:dl({disabled:i.isDisabled})}):null,jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("div",{className:ml({disabled:i.isDisabled,hovered:y}),children:r}),o?jsxRuntime.jsx("div",{...p,className:cl({disabled:i.isDisabled}),children:o}):null]})]})});bl.displayName="FileUpload";var gl="_12vfhl40 z9nup81",vl="_12vfhl41 z9nup82",_l=_({defaultClassName:"_12vfhl48",variantClassNames:{variant:{success:"_12vfhl49",error:"_12vfhl4a",active:"_12vfhl4b"}},defaultVariants:{},compoundVariants:[]}),zl="_12vfhl42",hl="_12vfhl47",xl="_12vfhl46 z9nup82",Cl="_12vfhl45",Pl=_({defaultClassName:"_12vfhl43 _12vfhl42",variantClassNames:{hasLabel:{false:"_12vfhl44"}},defaultVariants:{},compoundVariants:[]});var kl=so__default.default.forwardRef(({className:e,variant:r="active",showValue:o,description:t,errorMessage:a,...i},n)=>{let l=reactAria.useId(),{labelProps:s,progressBarProps:p}=reactAria.useProgressBar({...i,"aria-describedby":t?l:i["aria-describedby"]}),{minValue:d=0,maxValue:u=100,value:c=0,label:m}=i,f=(c-d)/(u-d),y=`${Math.round(f*100)}%`,g=jsxRuntime.jsx("output",{className:Pl({hasLabel:!!m}),children:p["aria-valuetext"]}),v=r==="error"?a:t;return jsxRuntime.jsxs("div",{...p,className:utils.classNames(gl,e),ref:n,children:[m?jsxRuntime.jsxs("div",{className:vl,children:[jsxRuntime.jsx("label",{...s,className:zl,children:m}),o?g:null]}):null,jsxRuntime.jsxs("div",{className:Cl,children:[jsxRuntime.jsxs("div",{className:xl,children:[jsxRuntime.jsx("div",{className:hl,children:jsxRuntime.jsx("div",{style:{width:y},className:_l({variant:r})})}),!m&&o?g:null]}),v?jsxRuntime.jsx("div",{className:co({hasError:r==="error"}),id:l,children:v}):null]})]})});kl.displayName="ProgressBar";function Po({isReadOnly:e,validationState:r}){return e?_16.ReadOnlyIcon:r==="error"?_16.ErrorFilledIcon:r==="warning"?_16.WarningFilledIcon:null}var ko=so__default.default.forwardRef(({className:e,validationState:r,variant:o="primary",style:t,labelPosition:a="top",inputStyle:i,inputClassName:n,"data-block-id":l,...s},p)=>{let d=so__default.default.useRef(null),{inputProps:u,labelProps:c,descriptionProps:m,errorMessageProps:f,validationErrors:y}=reactAria.useTextField({...s,validationState:r?r==="error"?"invalid":"valid":void 0},d),g=s.errorMessage||y.join(" "),v=_e({...s,errorMessage:g,descriptionProps:m,errorMessageProps:f,labelPosition:a});g&&(r="error");let{hoverProps:b,isHovered:h}=reactAria.useHover({isDisabled:s.isDisabled}),{isFocused:z,focusProps:x,isFocusVisible:R}=reactAria.useFocusRing(),C=Po({isReadOnly:s.isReadOnly,validationState:r}),P=utils.filterTruthyValues({"data-readonly":s.isReadOnly,"data-disabled":s.isDisabled,"data-validation-state":r,"data-focused":z,"data-focus-visible":R});return jsxRuntime.jsxs("div",{className:utils.classNames(De({labelPosition:a}),"BaselineUI-TextInput",e),"data-block-id":l,style:t,ref:p,children:[s.label||a==="start"&&v?jsxRuntime.jsxs("div",{className:Be({labelPosition:a,hasMessage:!!v}),children:[jsxRuntime.jsx("label",{...c,className:Me,children:s.label}),a==="start"&&v]}):null,jsxRuntime.jsxs("div",{className:utils.classNames({[po]:s.isDisabled}),children:[jsxRuntime.jsxs("div",{...b,className:uo({validationState:r,isHovered:h,isFocused:z,variant:o,isReadOnly:!!s.isReadOnly,isDisabled:!!s.isDisabled}),children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(u,x,P),className:utils.classNames(Xr({isDisabled:s.isDisabled,labelPosition:a}),"BaselineUI-TextInput-Input",n),style:i,ref:d}),C?jsxRuntime.jsx(C,{className:mo({validationState:r,isReadOnly:s.isReadOnly}),size:16}):null]}),a==="top"&&v]})]})});ko.displayName="TextInput";var wo=({value:e,...r})=>{let o=reactAria.useNumberFormatter(r);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:o.format(e)})};wo.displayName="NumberFormat";var Rl="_1yep5z6i3 _1yep5z6i4 _1yep5z6i5",Il=_({defaultClassName:"_9b1tml0",variantClassNames:{isSelected:{true:"_9b1tml1",false:"_9b1tml2"},isDisabled:{true:"z9nup83"},isHovered:{true:"_9b1tml4"},isFocusVisible:{true:"_9b1tml5"},isReadOnly:{true:"_9b1tml6"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0,isReadOnly:!1},"_9b1tml7"],[{isSelected:!0,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml8"],[{isSelected:!1,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml9"],[{isSelected:!0,isDisabled:!0},"_9b1tmla"],[{isSelected:!0,isReadOnly:!0},"_9b1tmlb"]]}),Tl=_({defaultClassName:"_9b1tmlf",variantClassNames:{isSelected:{true:"_9b1tmlg"},size:{sm:"_9b1tmlh",md:"_9b1tmli"},isDisabled:{true:"_9b1tmlj"},isReadOnly:{true:"_9b1tmlk"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"_9b1tmll"],[{isSelected:!0,isDisabled:!0},"_9b1tmlm"],[{isSelected:!1,isDisabled:!0},"_9b1tmln"]]}),Nl=_({defaultClassName:"_9b1tmlc",variantClassNames:{isDisabled:{true:"_9b1tmld"},isReadOnly:{true:"_9b1tmle"}},defaultVariants:{},compoundVariants:[]});var Ml=so__default.default.forwardRef(({className:e,count:r,style:o,size:t="md",icon:a,...i},n)=>{let l={isRequired:!1},s=a||(t==="md"?_20.CheckmarkIcon:_16.CheckmarkIcon);!i["aria-label"]&&!i["aria-labelledby"]&&console.warn("You must provide either an `aria-label` or `aria-labelledby` prop to the `Reaction` component.");let p=so__default.default.useRef(null),d=reactStately.useToggleState({...i,...l}),{inputProps:u,isPressed:c,isDisabled:m,isReadOnly:f,isSelected:y}=reactAria.useSwitch({...i,...l},d,p),{focusProps:g,isFocused:v,isFocusVisible:b}=reactAria.useFocusRing(),{hoverProps:h,isHovered:z}=reactAria.useHover({});return jsxRuntime.jsxs("label",{ref:n,style:o,className:utils.classNames(Rl,"BaselineUI-Reaction",e),"data-block-id":i["data-block-id"],"data-focused":v,"data-focus-visible":b,"data-disabled":m,"data-hovered":z,"data-pressed":c,"data-selected":y,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...u,...g,ref:p})}),jsxRuntime.jsxs("div",{...h,className:Il({isSelected:y,isFocusVisible:b,isHovered:z,isReadOnly:f,isDisabled:m}),children:[jsxRuntime.jsx("div",{className:Nl({isDisabled:m,isReadOnly:f}),children:jsxRuntime.jsx(s,{size:t==="md"?20:16})}),jsxRuntime.jsx("div",{className:Tl({isSelected:d.isSelected,isDisabled:m,isReadOnly:f,size:t}),children:jsxRuntime.jsx(wo,{value:r})})]})]})});Ml.displayName="Reaction";var Bl=_({defaultClassName:"_1jwycy80",variantClassNames:{placement:{bottom:"_1jwycy81",left:"_1jwycy82",right:"_1jwycy83",top:"_1jwycy84"},variant:{default:"_1jwycy85",inverse:"_1jwycy86"}},defaultVariants:{},compoundVariants:[]}),Dl=_({defaultClassName:"_1jwycy87 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn",variantClassNames:{size:{md:"_1yep5z63u _1yep5z63v _1yep5z63w _1yep5z61i _1yep5z61j _1yep5z61k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6e7",sm:"_1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6dv"},variant:{default:"_1yep5z6g0 _1yep5z6ez",inverse:"_1yep5z6d7 _1yep5z6fs _1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var ja=so__default.default.forwardRef(({children:e,state:r,overlayProps:o,arrowProps:t,placement:a,variant:i,size:n,tooltipProps:l,includeArrow:s},p)=>{let{tooltipProps:d}=reactAria.useTooltip({isOpen:r.isOpen},r),u=so.useMemo(()=>{switch(a){case"top":return {x:0,y:4};case"bottom":return {x:0,y:-4};case"left":return {x:4,y:0};case"right":return {x:-4,y:0};default:return {x:0,y:0}}},[a]),c=web.useReducedMotion(),[m]=web.useSpring(()=>({from:{opacity:0,transform:`translate(${u.x}px, ${u.y}px)`},to:{opacity:1,transform:"translate(0, 0)"},immediate:!!c})),f=a==="center"?"bottom":a;return jsxRuntime.jsxs(web.animated.span,{...o,style:{...m,...o.style},ref:p,"data-placement":f,children:[s?jsxRuntime.jsx("div",{className:Bl({placement:f,variant:i}),...t}):null,jsxRuntime.jsx("div",{...reactAria.mergeProps(d,l),className:Dl({variant:i,size:n}),children:e})]})});ja.displayName="TooltipContent";var He=so__default.default.forwardRef(({children:e,placement:r="bottom",delay:o=1e3,closeDelay:t=500,variant:a="default",size:i="md",includeArrow:n=!0,portalContainer:l,...s},p)=>{let d=so__default.default.useRef(null),u=so__default.default.useRef(null),c=!s.text||s.isDisabled,m=reactStately.useTooltipTriggerState({...s,delay:o,closeDelay:t,isDisabled:c}),{triggerProps:f,tooltipProps:y}=reactAria.useTooltipTrigger({...s,isDisabled:c,delay:o,closeDelay:t},m,d),g=le(l),{overlayProps:v,arrowProps:b,placement:h,updatePosition:z}=reactAria.useOverlayPosition({arrowSize:n?13:0,targetRef:d,arrowBoundaryOffset:n?8:0,offset:n?12:2,overlayRef:u,placement:r,isOpen:m.isOpen,...s});return Ts({ref:u,threshold:1,onIntersect:z,isDisabled:!m.isOpen}),Ns({ref:d,onResize:z,isDisabled:!m.isOpen}),jsxRuntime.jsxs(focus.FocusableProvider,{...f,ref:d,children:[e,m.isOpen?jsxRuntime.jsx(ho,{disableFocusManagement:!0,portalContainer:g,children:jsxRuntime.jsx(ja,{ref:N(p,u),state:m,arrowProps:b,overlayProps:v,placement:h,tooltipProps:y,variant:a,size:i,includeArrow:n,children:s.text})}):null]})});He.displayName="Tooltip";var Hl="_1azy5686",Ol="_1azy5685",Vl="var(--_1azy5680)",Al="_1azy5688",jl="_1azy5689",$l="_1azy5681 z9nup82",Ul="_1azy5682";var ql="_1azy5687";var cv={sm:16,md:20},dv={sm:[_16.CheckFilledIcon,_16.ErrorAltFilledIcon],md:[_20.CheckFilledIcon,_20.ErrorAltFilledIcon]},Io=so__default.default.forwardRef(({className:e,style:r,size:o="md",variant:t="active",...a},i)=>{let{labelProps:n,progressBarProps:l}=reactAria.useProgressBar({...a,isIndeterminate:!0}),s=cv[o],p=s/2-2,d=2*p*Math.PI,u=dv[o][t==="success"?0:1];return jsxRuntime.jsxs("div",{className:utils.classNames($l,e),ref:i,style:{...dynamic.assignInlineVars({[Vl]:`${d}px`}),...r},children:[jsxRuntime.jsxs("div",{...l,className:Ul,children:[(t==="active"||t==="inactive")&&jsxRuntime.jsxs("svg",{height:s,width:s,viewBox:`0 0 ${s} ${s}`,children:[jsxRuntime.jsx("circle",{role:"presentation",className:Hl,cx:s/2,cy:s/2,r:p}),t==="active"&&jsxRuntime.jsx("circle",{role:"presentation",className:Ol,cx:s/2,cy:s/2,r:p})]}),t==="success"&&jsxRuntime.jsx(u,{className:ql,size:s}),t==="error"&&jsxRuntime.jsx(u,{className:Al,size:s})]}),a.label?jsxRuntime.jsx("span",{...n,className:jl,children:a.label}):null]})});Io.displayName="ProgressSpinner";var Kl=_({defaultClassName:"_5uw3kp0 oom8bs0 z9nup82",variantClassNames:{isHovered:{true:"_5uw3kp1"},isFocusVisible:{true:"_5uw3kp2"},isDisabled:{true:"_5uw3kp3"},isSelected:{true:"_5uw3kp4"},size:{sm:"_5uw3kp5",md:"_5uw3kp6",lg:"_5uw3kp7"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0},"_5uw3kp8"],[{isSelected:!0,isDisabled:!0},"_5uw3kp9"]]});var _v={sm:16,md:20,lg:24},mt=so__default.default.forwardRef(({className:e,style:r,iconStart:o,size:t="md",elementType:a="button",...i},n)=>{let l=reactStately.useToggleState(i),{buttonProps:s,isPressed:p,ref:d}=Kr(i,l),{hoverProps:u,isHovered:c}=reactAria.useHover({isDisabled:i.isDisabled}),{isFocusVisible:m,isFocused:f,focusProps:y}=reactAria.useFocusRing(),g=utils.filterTruthyValues({"data-block-id":i["data-block-id"],"data-focused":f,"data-focus-visible":m,"data-disabled":i.isDisabled,"data-hovered":c,"data-pressed":p,"data-selected":l.isSelected});return jsxRuntime.jsxs(a,{...reactAria.mergeProps(s,u,y,g),className:utils.classNames(Kl({isHovered:c,isFocusVisible:m,isSelected:l.isSelected,size:t,isDisabled:i.isDisabled}),"BaselineUI-ToggleButton",e),style:r,ref:N(d,n),children:[o?jsxRuntime.jsx(o,{size:_v[t]}):null,i.label]})});mt.displayName="ToggleButton";var ut=_({defaultClassName:"_16vugd0e",variantClassNames:{isDisabled:{true:"_16vugd0f"}},defaultVariants:{},compoundVariants:[]}),Gl=_({defaultClassName:"_16vugd01 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),Wl=_({defaultClassName:"_16vugd05",variantClassNames:{isIndeterminate:{true:"_16vugd04"},isSelected:{true:"_16vugd04"},isFocusVisible:{true:"_16vugd08"},isHovered:{true:"_16vugd09"},isDisabled:{true:"_16vugd0a"},isReadOnly:{true:"_16vugd0b"},hasError:{true:"_16vugd0c"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_16vugd0d"]]});var Zl=so__default.default.forwardRef(({className:e,style:r,label:o,labelPosition:t="end","data-block-id":a,...i},n)=>{let l=so__default.default.useRef(null),s=reactStately.useToggleState(i),{isFocusVisible:p,isFocused:d,focusProps:u}=reactAria.useFocusRing(),{inputProps:c,isPressed:m,isDisabled:f,isSelected:y,isReadOnly:g}=reactAria.useCheckbox({...i,children:o},s,l),{hoverProps:v,isHovered:b}=reactAria.useHover({isDisabled:f}),h=utils.filterTruthyValues({"data-disabled":f,"data-readonly":g,"data-hovered":b,"data-selected":y,"data-pressed":m,"data-indeterminate":i.isIndeterminate,"data-invalid":i.isInvalid,"data-focus-visible":p,"data-focused":d,"data-block-id":a});return jsxRuntime.jsxs("label",{...h,className:utils.classNames(Gl({labelPosition:t}),"BaselineUI-Checkbox",e),style:r,ref:n,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(c,u),ref:l})}),jsxRuntime.jsxs("div",{...v,className:Wl({isSelected:y&&!i.isIndeterminate,isIndeterminate:i.isIndeterminate,isFocusVisible:p,isDisabled:f,isReadOnly:g,hasError:i.isInvalid,isHovered:b}),children:[y&&!i.isIndeterminate?jsxRuntime.jsx(_12.CheckmarkIcon,{size:12}):null,i.isIndeterminate?jsxRuntime.jsx(_12.MinusIcon,{size:12}):null]}),o?jsxRuntime.jsx("span",{className:ut({isDisabled:f}),children:o}):null]})});Zl.displayName="Checkbox";var Ql={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 Jl=_({defaultClassName:"_1nsi9h17",variantClassNames:{isFocusVisible:{true:"_1nsi9h18"},variant:{pinned:"_1nsi9h19",floating:"_1nsi9h1a"}},defaultVariants:{},compoundVariants:[]}),ep="_1nsi9h1b",op=_({defaultClassName:"_1nsi9h10",variantClassNames:{size:{xs:"_1nsi9h11",sm:"_1nsi9h12",md:"_1nsi9h13",lg:"_1nsi9h14"},variant:{floating:"_1nsi9h15",pinned:"_1nsi9h16"}},defaultVariants:{},compoundVariants:[]}),rp="_1nsi9h1c";var Gv={style:"decimal"},Wv={xs:[_12.CaretLeftIcon,_12.CaretRightIcon],sm:[_16.CaretLeftIcon,_16.CaretRightIcon],md:[_20.CaretLeftIcon,_20.CaretRightIcon],lg:[_24.CaretLeftIcon,_24.CaretRightIcon]},np=so__default.default.forwardRef(({className:e,style:r,minValue:o=1,defaultValue:t=1,incrementAriaLabel:a,decrementAriaLabel:i,"aria-label":n,size:l="md",variant:s="floating",...p},d)=>{let{locale:u}=reactAria.useLocale(),c=D(Ql),m={...p,formatOptions:Gv,minValue:o,incrementAriaLabel:a||c.formatMessage("nextPage"),decrementAriaLabel:i||c.formatMessage("prevPage"),defaultValue:t,"aria-label":n||c.formatMessage("goToPage")},f=so__default.default.useRef(null),y=reactStately.useNumberFieldState({...m,locale:u}),{inputProps:g,decrementButtonProps:v,incrementButtonProps:b,groupProps:h}=reactAria.useNumberField({...m,onKeyDown:E=>{E.key==="Enter"&&f.current?.blur(),p.onKeyDown?.(E);}},y,f),{hoverProps:z,isHovered:x}=reactAria.useHover({}),{focusProps:R,isFocused:C,isFocusVisible:P}=reactAria.useFocusRing(),k=s==="floating",[T,I]=Wv[l],B=utils.filterTruthyValues({"data-focus-visible":P,"data-focused":C,"data-hovered":x,"data-block-id":p["data-block-id"]});return jsxRuntime.jsxs("div",{...reactAria.mergeProps(h,z,B),className:utils.classNames(op({size:l,variant:s}),"BaselineUI-Pagination",e),style:r,ref:d,children:[jsxRuntime.jsx(L,{icon:T,...v,elementType:"div",size:l,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-DecrementButton"}),s==="floating"&&jsxRuntime.jsx(H,{orientation:"vertical"}),jsxRuntime.jsxs("div",{className:Jl({isFocusVisible:P,variant:s}),"aria-label":c.formatMessage("pageXofY",{arg0:g.value,arg1:y.maxValue}),children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(g,R),ref:f,className:utils.classNames("BaselineUI-Pagination-Input",ep),style:{width:`${g.value?.toString().length||1}ch`}}),jsxRuntime.jsxs("span",{className:rp,children:["/ ",jsxRuntime.jsx(wo,{value:y.maxValue})]})]}),s==="floating"&&jsxRuntime.jsx(H,{orientation:"vertical"}),jsxRuntime.jsx(L,{icon:I,...b,elementType:"div",size:l,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-IncrementButton"})]})});np.displayName="Pagination";var sp=({date:e,...r})=>{let o=reactAria.useDateFormatter(r);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:o.format(e)})};sp.displayName="DateFormat";var ft=_({defaultClassName:"_1f789qj1",variantClassNames:{isFocusVisible:{true:"_1f789qj2"},variant:{neutral:"_1f789qj3",red:"_1f789qj4",green:"_1f789qj5",blue:"_1f789qj6","high-contrast":"_1f789qj7"},isDisabled:{true:"_1f789qj8"},allowsRemoving:{true:"_1f789qj9"},isSelected:{true:"_1f789qja"},allowsSelection:{true:"_1f789qjb"},isHovered:{true:"_1f789qjc"}},defaultVariants:{},compoundVariants:[[{allowsSelection:!0,isHovered:!0,variant:"neutral"},"_1f789qjd"],[{allowsSelection:!0,isHovered:!0,variant:"red"},"_1f789qje"],[{allowsSelection:!0,isHovered:!0,variant:"blue"},"_1f789qjf"],[{allowsSelection:!0,isHovered:!0,variant:"green"},"_1f789qjg"],[{allowsSelection:!0,isHovered:!0,variant:"high-contrast"},"_1f789qjh"],[{allowsSelection:!0,isSelected:!0,isHovered:!0},"_1f789qji"]]}),lp="_1f789qjj",pp="_1f789qj0",cp=_({defaultClassName:"_1f789qjk",variantClassNames:{variant:{neutral:"_1f789qjl",red:"_1f789qjm",green:"_1f789qjn",blue:"_1f789qjo","high-contrast":"_1f789qjp"},isHovered:{true:"_1f789qjq"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,variant:"neutral"},"_1f789qjr"],[{isHovered:!0,variant:"red"},"_1f789qjs"],[{isHovered:!0,variant:"blue"},"_1f789qjt"],[{isHovered:!0,variant:"green"},"_1f789qju"],[{isHovered:!0,variant:"high-contrast"},"_1f789qjv"]]});var n_=({item:e,state:r,variant:o="neutral"})=>{let t=so__default.default.useRef(null),{focusProps:a,isFocusVisible:i}=reactAria.useFocusRing({within:!0}),{rowProps:n,gridCellProps:l,removeButtonProps:s,allowsRemoving:p,isDisabled:d,isSelected:u,allowsSelection:c}=reactAria.useTag({item:e},r,t),m=so__default.default.useRef(null),{buttonProps:f}=reactAria.useButton(s,m),{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:d}),{hoverProps:v,isHovered:b}=reactAria.useHover({isDisabled:d}),h=e.value?.icon,z=e.value?.variant??o;return jsxRuntime.jsx("div",{...reactAria.mergeProps(n,a,v),ref:t,className:ft({isFocusVisible:i,variant:z,isDisabled:d,allowsRemoving:p,isSelected:u,allowsSelection:c,isHovered:b}),children:jsxRuntime.jsxs("div",{...l,className:lp,children:[u?jsxRuntime.jsx(_16.CheckmarkIcon,{size:16}):null,!u&&h?jsxRuntime.jsx(h,{size:16}):null,e.rendered,p?jsxRuntime.jsx("button",{...reactAria.mergeProps(f,y),className:cp({variant:z,isHovered:g}),children:jsxRuntime.jsx(_12.XIcon,{})}):null]})})},Ka=so__default.default.forwardRef(({className:e,style:r,...o},t)=>{let a=so__default.default.useRef(null),i=reactStately.useListState(o),{gridProps:n}=reactAria.useTagGroup(o,i,a);return jsxRuntime.jsx("div",{...n,className:utils.classNames(pp,e),style:r,ref:N(t,a),children:[...i.collection].map(l=>jsxRuntime.jsx(n_,{state:i,item:l,variant:o.variant},l.key))})});Ka.displayName="TagGroupBase";var fp=so__default.default.forwardRef(({items:e,...r},o)=>jsxRuntime.jsx(Ka,{...r,items:e,ref:o,children:t=>jsxRuntime.jsx(reactStately.Item,{children:t.label})}));fp.displayName="TagGroup";var yp="_1yep5z6kv",bp=_({defaultClassName:"_1kvz17db _1yep5z6ki _1yep5z6kk",variantClassNames:{showActionsOnTriggerOnly:{true:"_1kvz17dc"},isTriggered:{true:"_1kvz17dd"}},defaultVariants:{},compoundVariants:[]}),gp=_({defaultClassName:"_1kvz17d0 _1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z68c _1yep5z68d _1yep5z68e _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6ki _1yep5z6kj",variantClassNames:{isExpanded:{true:"_1kvz17d1"}},defaultVariants:{},compoundVariants:[]}),vp="_1yep5z6ev _1yep5z6dy",_p=_({defaultClassName:"_1kvz17d2 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ki _1yep5z6kl",variantClassNames:{isFocusVisible:{true:"_1kvz17d3"},isHovered:{true:"_1yep5z6ft",false:"_1yep5z6fu"},isDisabled:{true:"z9nup83"}},defaultVariants:{},compoundVariants:[]}),zp="_1kvz17da _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6dz",hp=_({defaultClassName:"_1kvz17d7 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{isDisabled:{true:"_1yep5z6ey",false:"_1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var Wa=so__default.default.forwardRef(({children:e,className:r,style:o},t)=>{let{headers:a}=so.useContext(Oe),{disabledKeys:i}=so.useContext(Oe),{keyboardProps:n}=reactAria.useKeyboard({onKeyDown:l=>{let s=Vr(l.target),p=[...a?.keys()||[]].findIndex(f=>a?.get(f)?.current===s?.activeElement),d=a?.get(p||0),u=a?.size||0,c=f=>{let y=a.get(f-1<0?u-1:f-1);i?.has(y?.current?.getAttribute("data-key")||"")?c(f-1):y?.current?.focus();},m=f=>{let y=a.get((f+1)%u);i?.has(y?.current?.getAttribute("data-key")||"")?m(f+1):y?.current?.focus();};if(d)switch(l.key){case"Home":{l.preventDefault(),m(-1);break}case"End":{l.preventDefault(),c(u);break}case"ArrowDown":{l.preventDefault(),m(p);break}case"ArrowUp":{l.preventDefault(),c(p);break}default:l.continuePropagation();}}});return jsxRuntime.jsx("div",{...n,style:o,className:utils.classNames(yp,r),ref:t,children:so__default.default.Children.map(e,(l,s)=>so__default.default.cloneElement(l,{index:s}))})});Wa.displayName="AccordionBase";var Oe=so__default.default.createContext({expandedKeys:new Set,setExpandedKeys:()=>{},disabledKeys:new Set,headers:new Map,expansionMode:"multiple"}),Pp=so__default.default.forwardRef(({children:e,disabledKeys:r,defaultExpandedKeys:o=new Set,expandedKeys:t,expansionMode:a="multiple",onChange:i,className:n,style:l},s)=>{let[p,d]=so__default.default.useState(o),u=so__default.default.useRef(new Map).current,[c,m]=so__default.default.useState(a);so.useEffect(()=>{m(c);},[c]),so.useEffect(()=>{i?.(p);},[p,i]);let f=so.useMemo(()=>({expandedKeys:t||p,setExpandedKeys:t?()=>{}:d,disabledKeys:r,headers:u,expansionMode:c}),[t,p,r,u,c]);return jsxRuntime.jsx(Oe.Provider,{value:f,children:jsxRuntime.jsx(reactAria.FocusScope,{children:jsxRuntime.jsx(Wa,{className:n,style:l,ref:s,children:e})})})});Pp.displayName="Accordion";var Ya=so__default.default.forwardRef(({title:e,actions:r,controlId:o,value:t,id:a,index:i,subLabel:n,showActionsOnTriggerOnly:l},s)=>{let p=so__default.default.useRef(null),{expandedKeys:d,setExpandedKeys:u,expansionMode:c,disabledKeys:m,headers:f}=so.useContext(Oe),y=m?.has(t),g=reactAria.useFocusManager();utils.invariant(g);let{focusNext:v,focusPrevious:b}=g,{keyboardProps:h}=reactAria.useKeyboard({onKeyDown:w=>{w.key==="ArrowRight"?v({wrap:!0}):w.key==="ArrowLeft"?b({wrap:!0}):w.continuePropagation();},isDisabled:y});so.useEffect(()=>{utils.invariant(typeof i=="number","AccordionItem must have an index"),f?.set(i,p);},[i,f]);let z=()=>{u(w=>{let S=new Set(w);return S.has(t)?S.delete(t):(c==="single"&&S.clear(),S.add(t)),S});},{buttonProps:x}=reactAria.useButton({"aria-expanded":d.has(t),"aria-controls":o,onPress:z,isDisabled:y},p),{pressProps:R}=reactAria.usePress({onPress:z,isDisabled:y}),{focusProps:C,isFocusVisible:P}=reactAria.useFocusRing(),{hoverProps:k,isHovered:T}=reactAria.useHover({isDisabled:y}),{focusProps:I,isFocusVisible:B}=reactAria.useFocusRing({within:!0}),E=d.has(t);return jsxRuntime.jsxs("h3",{...reactAria.mergeProps(h,R,k,I),className:_p({isFocusVisible:P,isHovered:T,isDisabled:y}),ref:s,children:[jsxRuntime.jsxs("div",{className:hp({isDisabled:!!y}),children:[jsxRuntime.jsx(_8.ChevronRightIcon,{className:gp({isExpanded:E}),size:8}),jsxRuntime.jsx("button",{...reactAria.mergeProps(x,C),id:a,"data-key":t,className:zp,ref:p,children:e})]}),r?.length?jsxRuntime.jsx("div",{"data-testid":"action-buttons",className:bp({showActionsOnTriggerOnly:l,isTriggered:B||T}),children:r.map((w,S)=>jsxRuntime.jsx(L,{variant:"secondary",size:"sm",excludeFromTabOrder:!0,isDisabled:y,...w},S))}):null,n?jsxRuntime.jsx("div",{className:vp,children:n}):null]})});Ya.displayName="AccordionHeader";var Lp=so__default.default.forwardRef(({title:e,actions:r,children:o,value:t,index:a,subLabel:i,style:n,className:l,showActionsOnTriggerOnly:s},p)=>{let d=reactAria.useId(),u=reactAria.useId(),{expandedKeys:c}=so.useContext(Oe),m=so__default.default.useRef(null),f=c.has(t),y=Fe(),g=web.useReducedMotion(),v=web.useTransition(f?[t]:[],{from:!y&&!g&&{height:0,opacity:0},enter:()=>async b=>{await b({height:m.current?.scrollHeight,opacity:1});},leave:{height:0,opacity:0},keys:b=>b});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(reactAria.FocusScope,{children:jsxRuntime.jsx(Ya,{value:t,actions:r,id:u,title:e,controlId:d,ref:p,index:a,subLabel:i,showActionsOnTriggerOnly:s})}),v(b=>jsxRuntime.jsx(web.animated.div,{role:"region","aria-labelledby":u,id:d,style:{...b,overflow:"hidden"},children:jsxRuntime.jsx("div",{ref:m,className:l,style:n,children:o})}))]})});Lp.displayName="AccordionItem";var sr=so__default.default.forwardRef(({variant:e,isOpen:r,selectedIcon:o,validationState:t="valid",valueProps:a,label:i,...n},l)=>{let s=so__default.default.useRef(null),{buttonProps:p,isPressed:d}=reactAria.useButton({...n,isDisabled:n.isDisabled||n.isReadOnly},s),{hoverProps:u,isHovered:c}=reactAria.useHover({isDisabled:n.isDisabled}),{focusProps:m,isFocused:f,isFocusVisible:y}=reactAria.useFocusRing(),g=Po({isReadOnly:n.isReadOnly,validationState:t});n.isReadOnly&&(p.disabled=!1);let v=utils.filterTruthyValues({"data-disabled":n.isDisabled,"data-readonly":n.isReadOnly,"data-focused":f,"data-focus-visible":y,"data-hovered":c,"data-pressed":d,"data-open":r});return jsxRuntime.jsxs("button",{...reactAria.mergeProps(p,u,m,v),ref:N(l,s),className:utils.classNames(Gs({isFocused:y,isDisabled:n.isDisabled}),uo({variant:e,isHovered:c,isFocused:y,validationState:t,isDisabled:!!n.isDisabled,isReadOnly:n.isReadOnly}),"BaselineUI-Select-Button"),children:[jsxRuntime.jsxs("span",{className:Ys,children:[o?jsxRuntime.jsx(o,{size:24}):null,jsxRuntime.jsx("span",{...a,children:i})]}),g?jsxRuntime.jsx("span",{"aria-hidden":!0,className:utils.classNames(mo({validationState:t,isReadOnly:!!n.isReadOnly}),Xs),children:jsxRuntime.jsx(g,{size:16})}):null,jsxRuntime.jsx("span",{"aria-hidden":!0,children:jsxRuntime.jsx(_8.ChevronDownIcon,{size:8,className:Ks({isOpen:r})})})]})});sr.displayName="SelectButton";var Ja=so__default.default.createContext(null),ei=so__default.default.forwardRef(({className:e,style:r,labelPosition:o="top",variant:t="primary","data-block-id":a,optionStyle:i,optionClassName:n,placement:l="bottom start",state:s,renderTrigger:p=({buttonProps:c,selectedValue:m,valueProps:f,isOpen:y,ref:g})=>{let v=m&&"icon"in m&&m.icon;return jsxRuntime.jsx(sr,{...c,isOpen:y,isReadOnly:d.isReadOnly,ref:g,variant:t,validationState:d.validationState,selectedIcon:v||void 0,label:m?"label"in m&&m?.label:d.placeholder,valueProps:f})},...d},u)=>{let c=so__default.default.useRef(null),m=le(d.portalContainer),{labelProps:f,triggerProps:y,valueProps:g,menuProps:v,descriptionProps:b,errorMessageProps:h}=reactAria.useSelect({...d,validationState:d.validationState==="error"?"invalid":"valid"},s,c),z=_e({...d,descriptionProps:b,errorMessageProps:h,labelPosition:o}),x=s.selectedItem?.value??null;return jsxRuntime.jsxs(Xe.Provider,{value:s,children:[jsxRuntime.jsxs("div",{style:r,className:utils.classNames(De({labelPosition:o}),"BaselineUI-Select",e),"data-block-id":a,ref:u,children:[d.label||z?jsxRuntime.jsxs("div",{className:Be({labelPosition:o,hasMessage:!!z}),children:[d.label?jsxRuntime.jsx("div",{...f,className:utils.classNames(Me,"BaselineUI-Select-Label"),children:d.label}):null,o==="start"&&z]}):null,jsxRuntime.jsx(reactAria.HiddenSelect,{state:s,triggerRef:c,isDisabled:d.isDisabled,label:d.label,name:d.name}),p({buttonProps:y,selectedValue:x,valueProps:g,isOpen:s.isOpen,ref:c}),o==="top"&&z]}),s.isOpen?jsxRuntime.jsx(ie,{placement:l,portalContainer:m,offset:2,state:s,triggerRef:c,style:r,className:utils.classNames(it,"BaselineUI-Select-Popover"),...d,children:jsxRuntime.jsx(oe,{...v,label:d.label,items:d.items,showSelectedIcon:d.showSelectedIcon,className:Ws,optionStyle:i,optionClassName:n})}):null]})});ei.displayName="SelectCore";var Ep=so__default.default.forwardRef((e,r)=>{let o=ae(),t=reactStately.useSelectState({...e,validationState:e.validationState==="error"?"invalid":"valid",children:o});return jsxRuntime.jsx(ei,{...e,ref:r,state:t})});Ep.displayName="SelectStandalone";var Ae=so__default.default.forwardRef((e,r)=>{let o=so.useContext(Ja);return so.useEffect(()=>{utils.invariant(o||e.items,"Select: A `state` that can be passed via context or `items` are required.");},[e.items,o]),o?jsxRuntime.jsx(ei,{state:o,...e,ref:r}):jsxRuntime.jsx(Ep,{...e,ref:r})});Ae.displayName="Select";var Hp=so__default.default.forwardRef(({className:e,style:r,variant:o,"data-block-id":t,icon:a,includeTooltip:i,placement:n="bottom start",...l},s)=>{let p=so__default.default.useRef(null),d=so.useCallback(({buttonProps:u,selectedValue:c,valueProps:m,isOpen:f,ref:y})=>{let g=c&&"icon"in c&&c.icon;return jsxRuntime.jsx(He,{isDisabled:!i||l.isDisabled,variant:"inverse",size:"sm",includeArrow:!1,text:l["aria-label"],placement:n,offset:4,children:jsxRuntime.jsx(sr,{...u,isOpen:f,isReadOnly:l.isReadOnly,ref:y,variant:o,validationState:l.validationState,selectedIcon:g||void 0,label:c?"label"in c&&c?.label:l.placeholder,valueProps:m})})},[i,n,l,o]);return jsxRuntime.jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:utils.classNames("BaselineUI-IconSelect",e),"data-block-id":t,style:r,ref:N(s,p),children:[jsxRuntime.jsx(a,{size:24,className:tokens.sprinkles({color:"icon.primary"})}),jsxRuntime.jsx(Ae,{...l,renderTrigger:d})]})});Hp.displayName="IconSelect";var Op="_1017q4c5",Vp=_({defaultClassName:"_1017q4c0",variantClassNames:{size:{md:"_1017q4c1",sm:"_1017q4c2"},isDisabled:{true:"_1017q4c3"}},defaultVariants:{},compoundVariants:[]}),Ap="_1017q4c4";var Y_={sm:_16.AvatarIcon,md:_24.AvatarIcon},So=so__default.default.forwardRef(({className:e,style:r,size:o="md",icon:t=Y_[o],name:a,imgSrc:i,showInitials:n,isDisabled:l,hasNotifications:s,imgLoading:p,"data-block-id":d},u)=>{let{imgProps:c}=bo({src:i,alt:a}),m=a?.split(" ").map(f=>f[0]).join("");return jsxRuntime.jsxs("span",{className:utils.classNames(Vp({size:o,isDisabled:l}),"BaselineUI-Avatar",e),"data-disabled":l,ref:u,style:r,"aria-disabled":l,"data-block-id":d,children:[i?jsxRuntime.jsx("img",{...c,loading:p,className:Ap}):null,!n&&!i&&jsxRuntime.jsx(t,{size:o==="sm"?16:24}),n&&!i?o==="sm"?m[0]:m:null,s?jsxRuntime.jsx("div",{"data-testid":"notification",className:Op}):null]})});So.displayName="Avatar";var jp="_1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",$p=_({defaultClassName:"_1x62fhb6 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6ev _1yep5z69i _1yep5z69j _1yep5z69k",variantClassNames:{isHovered:{true:"_1yep5z6105"},isSelected:{true:"_1x62fhb8"},isFocusVisible:{true:"_1x62fhb9"},isDisabled:{true:"_1x62fhba _1yep5z6109"},variant:{primary:"_1x62fhbb _1yep5z6z6",ghost:"_1yep5z6z9"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:!0,isDisabled:!1},"_1yep5z61lg"],[{variant:"primary",isSelected:!0},"_1yep5z61me"],[{variant:"ghost",isSelected:!0,isFocusVisible:!1},"_1x62fhbd"],[{variant:"ghost",isSelected:!0,isDisabled:!1},"_1yep5z61lr"],[{variant:"ghost",isDisabled:!0,isSelected:!0},"_1x62fhbe _1yep5z6ey"],[{variant:"primary",isHovered:!0},"_1yep5z61mf"]]}),Up=_({defaultClassName:"_1x62fhb3 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1x62fhb4",ghost:"_1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),qp="_1x62fhbf",Kp="_1yep5z6l2 _1yep5z6kz _1yep5z6hc _1yep5z6l1",Gp=_({defaultClassName:"_1x62fhb0 _1yep5z6kv _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1yep5z6115",ghost:"_1x62fhb2"}},defaultVariants:{},compoundVariants:[]});var Wp=({state:e,...r})=>{let o=so__default.default.useRef(null),{tabPanelProps:t}=reactAria.useTabPanel(r,e,o),{selectedItem:a}=e,{focusProps:i,isFocusVisible:n}=reactAria.useFocusRing();if(!a?.value)return null;let{className:l,style:s,"data-block-id":p}=a.value;return jsxRuntime.jsx("div",{...reactAria.mergeProps(t,i),ref:o,className:utils.classNames({[Kp]:n},"Baseline-Tabs-TabPanel",l),"data-block-id":p,style:s,children:a?.props.children})};var ai=so__default.default.forwardRef(({className:e,style:r,tabHeaderStyle:o,tabHeaderClassName:t,variant:a="primary",actions:i,onRemove:n,"data-block-id":l,...s},p)=>{let d=reactStately.useTabListState({...s,selectedKey:s.selectedValue,defaultSelectedKey:s.defaultSelectedValue,disabledKeys:s.disabledValues}),u=so__default.default.useRef(null),{tabListProps:c}=reactAria.useTabList({...s,selectedKey:s.selectedValue,defaultSelectedKey:s.defaultSelectedValue,disabledKeys:s.disabledValues},d,u);return jsxRuntime.jsxs("div",{className:utils.classNames("BaselineUI-Tabs",e),style:r,ref:p,"data-block-id":l,children:[jsxRuntime.jsxs("div",{className:utils.classNames(Gp({variant:a}),t),style:o,children:[jsxRuntime.jsx("div",{...c,className:Up({variant:a}),ref:u,children:[...d.collection].map(m=>(utils.invariant(m.value,"TabItem requires a value prop"),jsxRuntime.jsx(Yp,{item:m,state:d,onRemove:n,variant:a},m.key)))}),i?.map((m,f)=>jsxRuntime.jsx("div",{className:jp,children:jsxRuntime.jsx(L,{...m,variant:"secondary",size:"sm",className:utils.classNames(qp,m.className)})},f))]}),jsxRuntime.jsx(Wp,{state:d},d.selectedItem?.key)]})});ai.displayName="TabsBase";var Yp=({item:e,onRemove:r,state:o,variant:t})=>{let{key:a,value:i}=e,n=so__default.default.useRef(null),{tabProps:l,isSelected:s,isDisabled:p}=reactAria.useTab({key:a},o,n),{hoverProps:d,isHovered:u}=reactAria.useHover({});utils.invariant(i,"TabButton requires a value prop");let{title:c,icon:m,titleStyle:f,titleClassName:y}=i,{focusProps:g,isFocusVisible:v,isFocused:b}=reactAria.useFocusRing(),{keyboardProps:h}=reactAria.useKeyboard({onKeyDown:x=>{x.key==="Backspace"&&r?r(a):x.continuePropagation();}}),z=utils.filterTruthyValues({"data-selected":s,"data-disabled":p,"data-focused":b,"data-hovered":u,"data-focus-visible":v});return jsxRuntime.jsxs("div",{...reactAria.mergeProps(h,l,d,g,z),className:utils.classNames($p({isHovered:u,isSelected:s,isFocusVisible:v,isDisabled:p,variant:t}),"BaselineUI-Tabs-TabButton",y),style:f,ref:n,children:[m?jsxRuntime.jsx(m,{size:20}):null,c,r?jsxRuntime.jsx(L,{variant:"secondary",elementType:"div",icon:_8.XIcon,size:"xxs",onPress:()=>{r(a);},excludeFromTabOrder:!0,UNSAFE_NON_INTERACTIVE:!0,style:{display:"inline-flex",color:"inherit",opacity:s||b||u?1:0}}):null]})};Yp.displayName="TabButton";var Qp=so__default.default.forwardRef(({children:e,...r},o)=>{let t=so.useMemo(()=>so__default.default.Children.map(e,a=>!a||!so__default.default.isValidElement(a)||typeof a.type=="string"?null:{...a.props,id:a.props.value}).filter(Boolean),[e]);return jsxRuntime.jsx(ai,{...r,ref:o,items:t,children:a=>jsxRuntime.jsx(reactStately.Item,{title:a.title,children:a.children},a.key)})});Qp.displayName="Tabs";var Jp=({children:e,title:r,value:o})=>(utils.invariant(o,"TabItem requires a value prop"),utils.invariant(r,"TabItem requires a title prop"),utils.invariant(e,"TabItem requires children"),e);Jp.displayName="TabItem";var ec={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 oc=_({defaultClassName:"kfun6yw",variantClassNames:{arrangement:{single:"kfun6yx",multi:"kfun6yy",compact:"kfun6yz"}},defaultVariants:{},compoundVariants:[]}),rc=_({defaultClassName:"kfun6y0 z9nup82",variantClassNames:{variant:{info:"kfun6y1",warning:"kfun6y2",error:"kfun6y3",success:"kfun6y4"},arrangement:{single:"kfun6y5",multi:"kfun6y6",compact:"kfun6y7"},hasButton:{true:"kfun6y8"},hasCloseButton:{true:"kfun6y9"}},defaultVariants:{},compoundVariants:[[{hasButton:!1,arrangement:"single"},"kfun6ya"],[{hasButton:!0,arrangement:"compact"},"kfun6yb"],[{hasCloseButton:!0,arrangement:"compact"},"kfun6yc"]]}),tc=_({defaultClassName:"kfun6yt",variantClassNames:{size:{sm:"kfun6yu",md:"kfun6yv"}},defaultVariants:{},compoundVariants:[]}),ac=_({defaultClassName:"kfun6yp",variantClassNames:{arrangement:{single:"kfun6yq",multi:"kfun6yr",compact:"kfun6ys"}},defaultVariants:{},compoundVariants:[]}),ic=_({defaultClassName:"kfun6yk",variantClassNames:{variant:{info:"kfun6yl",warning:"kfun6ym",error:"kfun6yn",success:"kfun6yo"}},defaultVariants:{},compoundVariants:[]}),nc=_({defaultClassName:"kfun6yh",variantClassNames:{size:{sm:"kfun6yi",md:"kfun6yj"}},defaultVariants:{},compoundVariants:[]}),sc=_({defaultClassName:"kfun6yd z9nup82",variantClassNames:{arrangement:{single:"kfun6ye",multi:"kfun6yf",compact:"kfun6yg"}},defaultVariants:{},compoundVariants:[]});var R6={error:{sm:_16.ErrorAltFilledIcon,md:_20.ErrorAltFilledIcon},info:{sm:_16.InfoFilledIcon,md:_20.InfoFilledIcon},success:{sm:_16.CheckFilledIcon,md:_20.CheckFilledIcon},warning:{sm:_16.WarningFilledIcon,md:_20.WarningFilledIcon}},lc=so__default.default.forwardRef(({className:e,description:r,actionLabel:o,onAction:t,style:a,variant:i="info",title:n,arrangement:l="single",onClose:s,size:p="sm"},d)=>{let u=D(ec),c=o&&jsxRuntime.jsx(O,{variant:l==="compact"?"tertiary":"ghost",label:o,onPress:t}),m=R6[i][p];return jsxRuntime.jsxs("div",{className:utils.classNames(rc({variant:i,arrangement:l,hasButton:!!o||!!s,hasCloseButton:!!s}),e),style:a,role:"alert",ref:d,children:[jsxRuntime.jsxs("div",{className:sc({arrangement:l}),children:[jsxRuntime.jsx(m,{className:ic({variant:i}),size:16}),jsxRuntime.jsxs("div",{className:oc({arrangement:l}),children:[jsxRuntime.jsx("h3",{className:nc({size:p}),children:n}),jsxRuntime.jsx("section",{className:tc({size:p}),children:r})]}),l==="compact"&&c]}),jsxRuntime.jsxs("div",{className:ac({arrangement:l}),children:[l!=="compact"&&c,s?jsxRuntime.jsx(L,{variant:"secondary",icon:_16.CloseIcon,size:"sm",onPress:s,"aria-label":u.formatMessage("close")}):null]})]})});lc.displayName="InlineAlert";var pc=_({defaultClassName:"_1tkzayn0 _1yep5z6dy",variantClassNames:{size:{sm:"_1tkzayn1",md:"_1tkzayn2",lg:"_1tkzayn3"},type:{subtitle:"_1yep5z6105",title:"_1yep5z6105",label:"_1yep5z6106",value:"_1yep5z6106",helper:"_1yep5z6107",body:"_1yep5z6105"}},defaultVariants:{},compoundVariants:[[{type:"title",size:"sm"},"_1yep5z61jz"],[{type:"title",size:"md"},"_1yep5z61k2"],[{type:"title",size:"lg"},"_1yep5z61k5"],[{type:"body",size:"sm"},"_1yep5z61kp"],[{type:"body",size:"md"},"_1yep5z61ks"],[{type:"body",size:"lg"},"_1yep5z61ks"],[{type:"subtitle",size:"sm"},"_1yep5z61kl"],[{type:"subtitle",size:"md"},"_1yep5z61ko"],[{type:"subtitle",size:"lg"},"_1yep5z61ko"],[{type:"label",size:"md"},"_1yep5z61kn"],[{type:"label",size:"lg"},"_1yep5z61kn"],[{type:"value",size:"md"},"_1yep5z61kn"],[{type:"value",size:"lg"},"_1yep5z61kn"],[{type:"helper",size:"sm"},"_1yep5z61kh"]]});var W=so__default.default.forwardRef(({elementType:e="span",type:r="title",children:o,size:t="md",...a},i)=>jsxRuntime.jsx(e,{...a,className:utils.classNames(pc({size:t,type:r}),"BaselineUI-Text",a.className),ref:i,children:o}));W.displayName="Text";var cc=_({defaultClassName:"siobe21 _1yep5z6ao _1yep5z6ap _1yep5z6aq _1yep5z6bc _1yep5z6bd _1yep5z6be _1yep5z6d7 _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie",variantClassNames:{background:{subtle:"_1yep5z6113",medium:"_1yep5z6114"}},defaultVariants:{},compoundVariants:[]}),dc="siobe24",mc="var(--siobe20)";var ht=so__default.default.forwardRef(({className:e,style:r,children:o,background:t="medium",title:a,action:i,"data-block-id":n,onCloseRequest:l,...s},p)=>{let{formatMessage:d}=D(),u=so__default.default.useRef(null),{dialogProps:c,titleProps:m}=reactAria.useDialog(s,u);return jsxRuntime.jsxs("div",{...c,className:utils.classNames(cc({background:t}),"BaselineUI-Drawer",e),"data-block-id":n,style:r,ref:N(p,u),children:[jsxRuntime.jsxs(M,{paddingLeft:"lg",paddingRight:"sm",backgroundColor:"background.primary.subtle",display:"flex",justifyContent:"space-between",alignItems:"center",gap:"lg",className:dc,children:[jsxRuntime.jsx(W,{type:"title",size:"sm",...m,className:Qn,children:a}),jsxRuntime.jsxs(M,{children:[i?jsxRuntime.jsx(L,{...i,variant:"secondary"}):null,jsxRuntime.jsx(L,{variant:"secondary",size:"md",icon:_20.XIcon,onPress:l,"aria-label":d(B6.close)})]})]}),jsxRuntime.jsx(H,{variant:t==="subtle"?"primary":"secondary"}),o]})});ht.displayName="Drawer";var B6=A({close:{id:"close",defaultMessage:"Close"}});function yc(e,r,o){let{isDisabled:t}=e,a=web.useReducedMotion(),[i,n]=so__default.default.useState("100vh");so.useEffect(()=>{if(!ua()&&!fa())return;let m=Q(o.current);function f(){n(`${m?.visualViewport.height}px`);}return f(),m?.visualViewport.addEventListener("resize",f),()=>{m?.visualViewport.removeEventListener("resize",f);}},[o]);let[{y:l},s]=web.useSpring(()=>({y:0,immediate:a,config:{easing:web.easings.easeOutCubic}})),p=so.useRef(0),d=so.useCallback(()=>{s.start({y:p.current,onRest:()=>{r.close();}});},[s,r]),u=so.useCallback(m=>{m.target.closest("[data-drawer]")||d();},[d]);granularHooks.useGranularLayoutEffect(()=>{p.current=o.current?.offsetHeight||0,s.set({y:p.current}),s.start({y:0,immediate:!!a});},[],[s,a]);let c=l.to({range:[0,p.current/2,p.current],output:[.5,.2,0],extrapolate:"clamp"}).to(m=>`rgba(0,0,0,${m})`);return {overlayProps:{style:t?void 0:{transform:l.to(m=>`translateY(${m}px)`)}},underlayProps:{style:t?void 0:{backgroundColor:c},onPointerDown:t?void 0:u},close:d,containerHeight:t?void 0:i}}var bc=_({defaultClassName:"aml2vl0 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hr _1yep5z6hs _1yep5z6ht",variantClassNames:{enableDrawer:{false:"_1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",true:"aml2vl2"}},defaultVariants:{},compoundVariants:[]}),gc="_1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6g2 _1yep5z6hr _1yep5z6hs _1yep5z6ht";var je=so__default.default.createContext({state:null,triggerProps:{},overlayProps:{}}),ze=({children:e,...r})=>{let o=reactStately.useOverlayTriggerState(r),{triggerProps:t,overlayProps:a}=reactAria.useOverlayTrigger({type:"dialog"},o),i=so.useMemo(()=>({state:o,triggerProps:t,overlayProps:a}),[o,t,a]);return jsxRuntime.jsx(je.Provider,{value:i,children:e})};ze.displayName="Modal";var li=so__default.default.createContext({isDrawer:!1,closeDrawer:()=>{}}),e5=web.animated(zo),o5=({children:e,className:r,style:o,isDismissable:t=!0,isKeyboardDismissDisabled:a=!1,portalContainer:i,disableAnimation:n,enableDrawer:l=!1,"data-block-id":s})=>{let{state:p}=so__default.default.useContext(je),d=go(i),u=le(i),c=typeof l=="boolean"&&l||l==="auto"&&d==="mobile";utils.invariant(p,"ModalContent must be a child of Modal");let m=so__default.default.useRef(null),f=typeof t=="function"?t(c):t,y=typeof a=="function"?a(c):a,{underlayProps:g,overlayProps:v,close:b,containerHeight:h}=yc({isDisabled:!c,isDismissable:f},p,m),{modalProps:z,underlayProps:x}=reactAria.useModalOverlay({isDismissable:!c,isKeyboardDismissDisabled:y},p,m),{theme:R}=so.useContext(_o),C=web.useReducedMotion(),P=web.useSpring({from:{opacity:0,transform:"scale(0.95)"},to:{opacity:1,transform:"scale(1)"},immediate:!!C||n,config:{easing:web.easings.easeInBounce}}),k=so.useMemo(()=>({...z.style,...c?{...v.style,width:"100%"}:P}),[v.style,z.style,c,P]),T=so.useMemo(()=>({isDrawer:c,closeDrawer:b}),[c,b]);return jsxRuntime.jsx(reactAria.Overlay,{portalContainer:u,children:jsxRuntime.jsx(li.Provider,{value:T,children:jsxRuntime.jsxs(e5,{className:utils.classNames(bc({enableDrawer:c}),r),theme:R,"data-block-id":s,style:{...o,height:c?h:"auto",...dynamic.assignInlineVars({[mc]:h})},children:[jsxRuntime.jsx(web.animated.div,{...reactAria.mergeProps(x,g),onPointerDown:c?g.onPointerDown:x.onPointerDown,"data-testid":"underlay",style:g.style,className:utils.classNames(gc,"BaselineUI-Modal-Underlay")}),jsxRuntime.jsx(web.animated.div,{...reactAria.mergeProps(z,v),style:k,ref:m,"data-drawer":c,className:"BaselineUI-Modal-Content",children:e})]})})})},r5=web.animated(o5),Te=({children:e,style:r,...o})=>{let{state:t}=so__default.default.useContext(je);utils.invariant(t,"ModalContent must be a child of Modal");let a=web.useReducedMotion();return web.useTransition(t.isOpen,{from:{opacity:0},enter:{opacity:1},immediate:!!a||o.disableAnimation})((n,l)=>l&&jsxRuntime.jsx(r5,{...o,style:{...r,...n},children:typeof e=="function"?e({close:t.close}):e}))};var Cc=_({defaultClassName:"cjv3et0 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs _1yep5z6d7",variantClassNames:{size:{sm:"cjv3et1",md:"cjv3et2",lg:"cjv3et3",content:"cjv3et4"},variant:{primary:"_1yep5z6121 _1yep5z616i _1yep5z616k",ghost:"cjv3et6"},isDrawer:{true:"cjv3et7 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg _1yep5z6166"}},defaultVariants:{},compoundVariants:[]});var ci=so__default.default.createContext({titleProps:{}}),pe=so__default.default.forwardRef(({children:e,className:r,style:o,inheritDrawer:t,size:a="md",variant:i="primary","data-block-id":n,drawerBackground:l,...s},p)=>{let d=so__default.default.useRef(null),u=so__default.default.useRef(null),{isDrawer:c,closeDrawer:m}=so.useContext(li),[f,y]=so__default.default.useState("");so.useLayoutEffect(()=>{let h=u.current?.getRootNode(),z=s["aria-label"]||"";s["aria-labelledby"]&&(z=h?.querySelector(`#${s["aria-labelledby"].replaceAll(":","\\:")}`)?.textContent||""),y(z);},[s]);let{dialogProps:g,titleProps:v}=reactAria.useDialog(s,d),b=so.useMemo(()=>({titleProps:v}),[v]);return c&&t?jsxRuntime.jsx(ht,{title:f,onCloseRequest:m,className:r,...s,"data-drawer":!0,"data-block-id":n,ref:N(u,p),background:l,children:e}):jsxRuntime.jsx(ci.Provider,{value:b,children:jsxRuntime.jsx("section",{...g,"data-block-id":n,ref:N(d,p),style:o,className:utils.classNames(Cc({size:c?"content":a,variant:i,isDrawer:c}),"BaselineUI-Dialog",r),children:e})})});pe.displayName="Dialog";var kc=so__default.default.forwardRef(({children:e,className:r,style:o},t)=>{let{titleProps:a}=so.useContext(ci),i=so__default.default.isValidElement(e)?reactSlot.Slot:"h3";return jsxRuntime.jsx(i,{...a,ref:t,className:r,style:o,children:e})});kc.displayName="DialogTitle";var $e={ar:{add:"\u0625\u0636\u0627\u0641\u0629",addColor:"\u0625\u0636\u0627\u0641\u0629 \u0644\u0648\u0646",cancel:"\u0625\u0644\u063A\u0627\u0621",colorFormat:"\u062A\u0646\u0633\u064A\u0642 \u0627\u0644\u0644\u0648\u0646",colorPresets:"\u0627\u0644\u0623\u0644\u0648\u0627\u0646 \u0627\u0644\u0645\u0633\u0628\u0642\u0629",customColors:"\u0623\u0644\u0648\u0627\u0646 \u0645\u062E\u0635\u0635\u0629",newColor:"\u0644\u0648\u0646 \u0645\u062E\u0635\u0635 \u062C\u062F\u064A\u062F",noColor:"\u0644\u0627 \u064A\u0648\u062C\u062F",removeColor:"\u0625\u0632\u0627\u0644\u0629 \u0627\u0644\u0644\u0648\u0646",transparent:"\u0634\u0641\u0627\u0641"},cs:{add:"P\u0159idat",addColor:"P\u0159idat barvu",cancel:"Zru\u0161it",colorFormat:"Form\xE1t barvy",colorPresets:"P\u0159edvolby barev",customColors:"Vlastn\xED barvy",newColor:"Vlastn\xED barva",noColor:"Nen\xED",removeColor:"Odebrat barvu",transparent:"Pr\u016Fhledn\xE1"},cy:{add:"Ychwanegu",addColor:"Ychwanegu Lliw",cancel:"Canslo",colorFormat:"Fformat Lliw",colorPresets:"Rhagosodiadau Lliw",customColors:"Lliwiau Custom",newColor:"Lliw Personol Newydd",noColor:"Dim",removeColor:"Tynnu Lliw",transparent:"Tryloyw"},da:{add:"Tilf\xF8j",addColor:"Tilf\xF8j Farve",cancel:"Annuller",colorFormat:"Farveformat",colorPresets:"Farvevalg",customColors:"Brugerdefinerede farver",newColor:"Ny tilpasset farve",noColor:"Ingen",removeColor:"Fjern Farve",transparent:"Transparent"},de:{add:"Hinzuf\xFCgen",addColor:"Farbe hinzuf\xFCgen",cancel:"Abbrechen",colorFormat:"Farbformat",colorPresets:"Farbvorlagen",customColors:"Benutzerdefinierte Farben",newColor:"Neue benutzerdefinierte Farbe",noColor:"Kein",removeColor:"Farbe entfernen",transparent:"Transparent"},el:{add:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7",addColor:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",cancel:"\u0391\u03BA\u03CD\u03C1\u03C9\u03C3\u03B7",colorFormat:"\u039C\u03BF\u03C1\u03C6\u03AE \u03C7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",colorPresets:"\u03A0\u03C1\u03BF\u03B5\u03C0\u03B9\u03BB\u03BF\u03B3\u03AD\u03C2 \u03C7\u03C1\u03C9\u03BC\u03AC\u03C4\u03C9\u03BD",customColors:"\u03A0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03B1 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03B1",newColor:"\u039D\u03AD\u03BF \u03C0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03BF \u03C7\u03C1\u03CE\u03BC\u03B1",noColor:"\u039A\u03B1\u03BD\u03AD\u03BD\u03B1\u03C2",removeColor:"\u0391\u03C6\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",transparent:"\u0397\u03BC\u03B9\u03B4\u03B9\u03B1\u03C6\u03B1\u03BD\u03AE\u03C2"},"en-GB":{add:"Add",addColor:"Add Colour",cancel:"Cancel",colorFormat:"Colour Format",colorPresets:"Colour Presets",customColors:"Custom Colours",newColor:"New Custom Colour",noColor:"None",removeColor:"Remove Colour",transparent:"Transparent"},en:{add:"Add",addColor:"Add Color",cancel:"Cancel",colorFormat:"Color Format",colorPresets:"Color Presets",customColors:"Custom Colors",newColor:"New Custom Color",noColor:"None",removeColor:"Remove Color",transparent:"Transparent"},es:{add:"A\xF1adir",addColor:"A\xF1adir color",cancel:"Cancelar",colorFormat:"Formato de color",colorPresets:"Preajustes de color",customColors:"Colores personalizados",newColor:"Nuevo color personalizado",noColor:"Ninguna",removeColor:"Eliminar color",transparent:"Transparente"},fi:{add:"Lis\xE4\xE4",addColor:"Lis\xE4\xE4 v\xE4ri",cancel:"Kumoa",colorFormat:"V\xE4rimuoto",colorPresets:"V\xE4rin esiasetukset",customColors:"Mukautetut v\xE4rit",newColor:"Uusi muokattu v\xE4ri",noColor:"Ei mit\xE4\xE4n",removeColor:"Poista v\xE4ri",transparent:"L\xE4pin\xE4kyv\xE4"},"fr-CA":{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},fr:{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},he:{add:"\u05D4\u05D5\u05E1\u05E4\u05D4",addColor:"\u05D4\u05D5\u05E1\u05E3 \u05E6\u05D1\u05E2",cancel:"\u05D1\u05D9\u05D8\u05D5\u05DC",colorFormat:"\u05E4\u05D5\u05E8\u05DE\u05D8 \u05E6\u05D1\u05E2",colorPresets:"\u05DE\u05E6\u05D1\u05D9 \u05E6\u05D1\u05E2 \u05DE\u05EA\u05D5\u05DB\u05E0\u05EA\u05D9\u05DD",customColors:"\u05E6\u05D1\u05E2\u05D9\u05DD \u05DE\u05D5\u05EA\u05D0\u05DE\u05D9\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA",newColor:"\u05E6\u05D1\u05E2 \u05DE\u05D5\u05EA\u05D0\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA \u05D7\u05D3\u05E9",noColor:"\u05DC\u05DC\u05D0",removeColor:"\u05D4\u05E1\u05E8 \u05E6\u05D1\u05E2",transparent:"\u05E9\u05E7\u05D5\u05E3"},hr:{add:"Dodati",addColor:"Dodaj boju",cancel:"Otka\u017Ei",colorFormat:"Format boje",colorPresets:"Prijedlozi boja",customColors:"Prilago\u0111ene boje",newColor:"Nova prilago\u0111ena boja",noColor:"Prazno",removeColor:"Ukloni boju",transparent:"Prozirna"},id:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batalkan",colorFormat:"Format Warna",colorPresets:"Preset Warna",customColors:"Warna Kustom",newColor:"Warna Khusus Baru",noColor:"Tidak ada",removeColor:"Hapus Warna",transparent:"Transparan"},it:{add:"Aggiungi",addColor:"Aggiungi colore",cancel:"Annulla",colorFormat:"Formato del colore",colorPresets:"Colori predefiniti",customColors:"Colori personalizzati",newColor:"Nuovo colore personalizzato",noColor:"Nessuno",removeColor:"Rimuovi colore",transparent:"Trasparente"},ja:{add:"\u8FFD\u52A0",addColor:"\u8272\u3092\u8FFD\u52A0",cancel:"\u30AD\u30E3\u30F3\u30BB\u30EB",colorFormat:"\u30AB\u30E9\u30FC\u30D5\u30A9\u30FC\u30DE\u30C3\u30C8",colorPresets:"\u30AB\u30E9\u30FC\u30D7\u30EA\u30BB\u30C3\u30C8",customColors:"\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",newColor:"\u65B0\u898F\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",noColor:"\u306A\u3057",removeColor:"\u8272\u3092\u524A\u9664",transparent:"\u900F\u660E"},ko:{add:"\uCD94\uAC00",addColor:"\uC0C9\uC0C1 \uCD94\uAC00",cancel:"\uCDE8\uC18C",colorFormat:"\uC0C9\uC0C1 \uD615\uC2DD",colorPresets:"\uC0C9\uC0C1 \uBBF8\uB9AC\uC124\uC815",customColors:"\uC0AC\uC6A9\uC790 \uC815\uC758 \uC0C9\uC0C1",newColor:"\uC0C8\uB85C\uC6B4 \uC0AC\uC6A9\uC790\uC9C0\uC815 \uC0C9\uC0C1",noColor:"\uC5C6\uC74C",removeColor:"\uC0C9\uC0C1 \uC81C\uAC70",transparent:"\uD22C\uBA85"},ms:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batal",colorFormat:"Format Warna",colorPresets:"Praset Warna",customColors:"Warna Kustom",newColor:"Warna Tersuai Baharu",noColor:"Tiada",removeColor:"Buang Warna",transparent:"Lut Sinar"},"nb-NO":{add:"Legg til",addColor:"Legg til farge",cancel:"Avbryt",colorFormat:"Fargeformat",colorPresets:"Fargeinnstillinger",customColors:"Egendefinerte farger",newColor:"Ny tilpasset farge",noColor:"Ingen",removeColor:"Fjern farge",transparent:"Gjennomsiktig"},nl:{add:"Voeg toe",addColor:"Kleur toevoegen",cancel:"Annuleer",colorFormat:"Kleurformaat",colorPresets:"Kleurvoorinstellingen",customColors:"Aangepaste kleuren",newColor:"Nieuwe aangepaste kleur",noColor:"Geen",removeColor:"Kleur verwijderen",transparent:"Doorzichtig"},pl:{add:"Dodaj",addColor:"Dodaj kolor",cancel:"Anuluj",colorFormat:"Format koloru",colorPresets:"Wst\u0119pnie ustawione kolory",customColors:"Niestandardowe kolory",newColor:"Nowy kolor niestandardowy",noColor:"Brak",removeColor:"Usu\u0144 kolor",transparent:"Prze\u015Bwiecaj\u0105ce"},"pt-PT":{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Predefini\xE7\xF5es de cor",customColors:"Cores personalizadas",newColor:"Nova cor personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},pt:{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Pr\xE9-ajustes de Cores",customColors:"Cores personalizadas",newColor:"Nova Cor Personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},ru:{add:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C",addColor:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0446\u0432\u0435\u0442",cancel:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u0446\u0432\u0435\u0442\u0430",colorPresets:"\u0411\u0438\u0431\u043B\u0438\u043E\u0442\u0435\u043A\u0430 \u0446\u0432\u0435\u0442\u043E\u0432",customColors:"\u041F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u0435\u043B\u044C\u0441\u043A\u0438\u0435 \u0446\u0432\u0435\u0442\u0430",newColor:"\u041D\u043E\u0432\u044B\u0439 \u0441\u043E\u0431\u0441\u0442\u0432\u0435\u043D\u043D\u044B\u0439 \u0446\u0432\u0435\u0442",noColor:"\u041D\u0435\u0442",removeColor:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0446\u0432\u0435\u0442",transparent:"\u041F\u0440\u043E\u0437\u0440\u0430\u0447\u043D\u044B\u0439"},sk:{add:"Prida\u0165",addColor:"Prida\u0165 farbu",cancel:"Zru\u0161i\u0165",colorFormat:"Form\xE1t farby",colorPresets:"Predvo\u013Eby farieb",customColors:"Vlastn\xE9 farby",newColor:"Vlastn\xE1 farba",noColor:"\u017Diadny",removeColor:"Odstr\xE1ni\u0165 farbu",transparent:"Prieh\u013Eadn\xE1"},sl:{add:"Dodaj",addColor:"Dodaj barvo",cancel:"Prekli\u010Di",colorFormat:"Barvni format",colorPresets:"Barvne predloge",customColors:"Prilagojene barve",newColor:"Nova barva po meri",noColor:"Prazna stran",removeColor:"Odstrani barvo",transparent:"Prosojna"},sv:{add:"L\xE4gg till",addColor:"L\xE4gg till f\xE4rg",cancel:"Avbryt",colorFormat:"F\xE4rgformat",colorPresets:"F\xF6rval f\xF6r f\xE4rger",customColors:"Anpassade f\xE4rger",newColor:"Ny anpassad f\xE4rg",noColor:"Ingen",removeColor:"Ta bort f\xE4rg",transparent:"Genomskinligt"},th:{add:"\u0E40\u0E1E\u0E34\u0E48\u0E21",addColor:"\u0E40\u0E1E\u0E34\u0E48\u0E21\u0E2A\u0E35",cancel:"\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01",colorFormat:"\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E2A\u0E35",colorPresets:"\u0E04\u0E48\u0E32\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E15\u0E31\u0E49\u0E07\u0E44\u0E27\u0E49\u0E25\u0E48\u0E27\u0E07\u0E2B\u0E19\u0E49\u0E32",customColors:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07",newColor:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07\u0E43\u0E2B\u0E21\u0E48",noColor:"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E40\u0E25\u0E22",removeColor:"\u0E25\u0E1A\u0E2A\u0E35",transparent:"\u0E42\u0E1B\u0E23\u0E48\u0E07\u0E43\u0E2A"},tr:{add:"Ekle",addColor:"Renk Ekle",cancel:"Vazge\xE7",colorFormat:"Renk Format\u0131",colorPresets:"Renk \xD6nayarlar\u0131",customColors:"\xD6zel Renkler",newColor:"Yeni \xF6zel renk",noColor:"Hi\xE7biri",removeColor:"Rengi Kald\u0131r",transparent:"\u015Eeffaf"},uk:{add:"\u0414\u043E\u0434\u0430\u0442\u0438",addColor:"\u0414\u043E\u0434\u0430\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",cancel:"\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u043A\u043E\u043B\u044C\u043E\u0440\u0443",colorPresets:"\u0411\u0456\u0431\u043B\u0456\u043E\u0442\u0435\u043A\u0430 \u043A\u043E\u043B\u044C\u043E\u0440\u0456\u0432",customColors:"\u041A\u043E\u0440\u0438\u0441\u0442\u0443\u0432\u0430\u0446\u044C\u043A\u0456 \u043A\u043E\u043B\u044C\u043E\u0440\u0438",newColor:"\u041D\u043E\u0432\u0438\u0439 \u0432\u043B\u0430\u0441\u043D\u0438\u0439 \u043A\u043E\u043B\u0456\u0440",noColor:"\u041D\u0435\u043C\u0430\u0454",removeColor:"\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",transparent:"\u041F\u0440\u043E\u0437\u043E\u0440\u0438\u0439"},"zh-Hans":{add:"\u6DFB\u52A0",addColor:"\u6DFB\u52A0\u989C\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u989C\u8272\u683C\u5F0F",colorPresets:"\u989C\u8272\u9884\u8BBE",customColors:"\u81EA\u5B9A\u4E49\u989C\u8272",newColor:"\u65B0\u81EA\u5B9A\u4E49\u989C\u8272",noColor:"\u65E0",removeColor:"\u79FB\u9664\u989C\u8272",transparent:"\u900F\u660E"},"zh-Hant":{add:"\u52A0\u5165",addColor:"\u6DFB\u52A0\u984F\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u984F\u8272\u683C\u5F0F",colorPresets:"\u984F\u8272\u9810\u8A2D\u9805",customColors:"\u81EA\u8A02\u984F\u8272",newColor:"\u65B0\u81EA\u8A02\u984F\u8272",noColor:"\u7121",removeColor:"\u79FB\u9664\u984F\u8272",transparent:"\u900F\u660E"}};var Pt=({children:e})=>{let{triggerProps:r}=so__default.default.useContext(je);return jsxRuntime.jsx(reactSlot.Slot,{...r,children:e})};Pt.displayName="ModalTrigger";var v5=({children:e})=>{let{state:r}=so__default.default.useContext(je);return jsxRuntime.jsx(reactSlot.Slot,{onPress:()=>r?.close(),children:e})};var Ue=so__default.default.forwardRef((e,r)=>{let{state:o,overlayTriggerAria:{overlayProps:t},triggerRef:a}=so.useContext(Zo);return utils.invariant(a),o?.isOpen?jsxRuntime.jsx(ie,{ref:r,...e,triggerRef:e.triggerRef||a,overlayProps:t,state:o}):null});Ue.displayName="PopoverContent";var wc="_1dbkl53 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6kv",Rc="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt",Ic="_1dbkl5e",Tc=_({defaultClassName:"_1dbkl54 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l6 _1yep5z6ky _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6kx _1yep5z6dy",variantClassNames:{isHovered:{true:"_1dbkl55"},isFocusVisible:{true:"_1dbkl56"},isDisabled:{true:"z9nup83 _1yep5z6109"},labelPosition:{top:"_1dbkl58",start:"_1dbkl59"}},defaultVariants:{},compoundVariants:[]}),Nc=_({defaultClassName:"_1dbkl50 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6dy _1yep5z6ev",variantClassNames:{labelPosition:{top:"_1yep5z6nq _1yep5z6nr _1yep5z6ns",start:"_1dbkl52"}},defaultVariants:{},compoundVariants:[]}),kt="_1dbkl5l _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69f _1yep5z69g _1yep5z69h",Sc="_1dbkl5f z9nup87",wt="_1dbkl5m _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn",Lc="_1dbkl5k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ky",Mc="_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy _1yep5z6ev _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it",Rt=_({defaultClassName:"_1dbkl5h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs",variantClassNames:{includesCustomColorPicker:{true:"_1yep5z6me _1yep5z6mf _1yep5z6mg"}},defaultVariants:{},compoundVariants:[]}),di="_1dbkl5v _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",Bc=_({defaultClassName:"_1dbkl5q _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6br _1yep5z6bs _1yep5z6bt _1yep5z6d3 _1yep5z6d4 _1yep5z6d5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocused:{true:"_1dbkl5r _1yep5z611y"},isHovered:{true:"_1dbkl5s"},allowAlpha:{false:"_1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6166"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,isFocused:!1},"_1yep5z61nd"]]}),Dc=_({defaultClassName:"_1dbkl5a _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62c _1yep5z62d _1yep5z62e _1yep5z63i _1yep5z63j _1yep5z63k _1yep5z616 _1yep5z617 _1yep5z618 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e _1yep5z6f0 _1yep5z6kx _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kl",variantClassNames:{isHovered:{true:"_1yep5z6115"},isFocusVisible:{true:"_1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612n"},isDisabled:{true:"_1yep5z610d"}},defaultVariants:{},compoundVariants:[]}),mr="_1dbkl5u",It="_1dbkl5g _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Tt="_1dbkl5j _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",mi="_1dbkl5x",Ec="_1dbkl5w",ui="_1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69l _1yep5z69m _1yep5z69n",Nt=_({defaultClassName:"_1dbkl5n _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6l2 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6l7 _1yep5z6la",variantClassNames:{isFocusVisible:{true:"_1dbkl5o _1yep5z616a _1yep5z612n _1yep5z616c"}},defaultVariants:{},compoundVariants:[]}),fi="z9nup84 z9nup86 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6ho _1yep5z6hp _1yep5z6hq";var Fc=_({defaultClassName:"_1344e9q0 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ks _1yep5z6hk _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",variantClassNames:{isFocusVisible:{true:"_1344e9q1"},isDisabled:{true:"_1344e9q2"},removeBlendMode:{true:"_1344e9q3"},isSelected:{true:"_1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616f"},isHovered:{true:"_1344e9q5"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isFocusVisible:!0},"_1344e9q6"],[{isSelected:!0,isFocusVisible:!0},"_1344e9q7 _1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq _1yep5z61o5"],[{isHovered:!0,isSelected:!1},"_1yep5z61rq _1yep5z61rn _1yep5z61rl _1yep5z61o2"]]});var he=so__default.default.forwardRef(({color:e,isFocusVisible:r,isSelected:o,isInteractive:t,isDisabled:a,style:i,className:n,id:l,"data-block-id":s,...p},d)=>{let u=e&&e!==xe&&(typeof e=="string"?color.parseColor(e):e),{formatMessage:c}=D(),m=!u,{colorSwatchProps:f}=color$1.useColorSwatch({color:m?"#000000":e}),{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:a||!t}),v=utils.filterTruthyValues({"data-focus-visible":r,"data-selected":o,"data-hovered":g,"data-block-id":s,"data-disabled":a,"data-interactive":t});return jsxRuntime.jsx("div",{...reactAria.mergeProps(y,v,m?{}:f),style:i,"aria-label":m?c(L5.none):f["aria-label"],role:"img",className:utils.classNames(Fc({removeBlendMode:m,isFocusVisible:r,isDisabled:!!a,isSelected:!!o,isHovered:g}),"BaselineUI-ColorSwatch",n),ref:d,id:l,...p,children:jsxRuntime.jsx(M,{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"full",height:"full",width:"full",opacity:a?"medium":void 0,style:u?Hc(u,4):void 0,children:m?jsxRuntime.jsx(_16.NoneIcon,{size:14}):null})})});he.displayName="ColorSwatch";var L5=A({none:{id:"none",defaultMessage:"None"}});var Vc=[{id:"hex",label:"HEX"},{id:"rgb",label:"RGB"}],Lo=color.parseColor("#000000").toFormat("hsla"),J="hsla",ur="hexa";function eo(e){return typeof e=="string"?color.parseColor(e).toFormat(J):e?e.toFormat(J):null}function Ac(e,r){return e?.getChannelValue("alpha")?r?.toString(ur)===e.toString(ur):!r?.getChannelValue("alpha")}function jc(e,r,o){return r?.label?r.label:e?.getChannelValue("alpha")===0?o:e?.toString("rgba")}var xe="NONE";function $c(e,r){let o=r?.map(a=>({id:color.parseColor(a.color).toString(ur),label:a.label}))||[],t={id:xe,label:e};return [...o,t]}var St=(e,{optionProps:r,isFocusVisible:o,isSelected:t},a)=>(utils.invariant(e.value&&"label"in e.value,"Item must have label"),jsxRuntime.jsx("li",{...r,ref:a,className:Lc,children:jsxRuntime.jsx(he,{color:e.value.id,isFocusVisible:o,isSelected:t,"aria-label":e.value.label,isInteractive:!0})})),Hc=(e,r=4)=>{let o=e.getChannelValue("alpha")===0,t=`repeating-conic-gradient(transparent 0% 25%, ${tokens.themeVars.color.background.secondary.medium} 25% 50%)`;return {backgroundImage:o?t:`linear-gradient(${e.toString("hexa")}, ${e.toString("hexa")}), ${t}`,backgroundSize:`${r}px ${r}px`}};var qc=({value:e,...r})=>{let o=so__default.default.useRef(null),t=so__default.default.useRef(null),a=so__default.default.useRef(null),i=color.useColorAreaState({...r,value:e}),{colorAreaProps:n,xInputProps:l,yInputProps:s,thumbProps:p}=color$1.useColorArea({...r,value:e,inputXRef:o,inputYRef:t,containerRef:a},i);so.useEffect(()=>{o.current?.focus();},[]);let{focusProps:d,isFocusVisible:u}=reactAria.useFocusRing();return jsxRuntime.jsx("div",{ref:a,...n,className:utils.classNames(wc,"BaselineUI-ColorInput-ColorArea"),children:jsxRuntime.jsxs("div",{...p,className:utils.classNames(Nt({isFocusVisible:u}),"BaselineUI-ColorInput-ColorAreaThumb"),style:{...p.style,transform:"translate(-50%, -50%)",backgroundColor:eo(e)?.withChannelValue("alpha",1).toString("css")},children:[jsxRuntime.jsx("input",{ref:o,...l,...d}),jsxRuntime.jsx("input",{ref:t,...s,...d})]})})};var Wc=({color:e,setColor:r,allowAlpha:o,...t})=>{let a=color.useColorFieldState({value:e,onChange:u=>{r(eo(u)?.toFormat(J).withChannelValue("alpha",e.getChannelValue("alpha")??1)||Lo);}}),i=so__default.default.useRef(null),{inputProps:n}=color$1.useColorField({...t,"aria-label":"Hex"},a,i),{focusProps:l,isFocused:s}=reactAria.useFocusRing({isTextInput:!0}),{hoverProps:p,isHovered:d}=reactAria.useHover({});return jsxRuntime.jsxs("div",{className:utils.classNames(di,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"hexa":"hex",children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(n,l,p),ref:i,className:Bc({isFocused:s,isHovered:d,allowAlpha:o})}),o?jsxRuntime.jsx(Yc,{color:e,setColor:r}):null]})},Xc=({color:e,setColor:r,allowAlpha:o})=>{let t=e.toFormat("rgba"),{locale:a}=reactAria.useLocale();return jsxRuntime.jsxs("div",{className:utils.classNames(di,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"rgba":"rgb",children:[jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("red",a),value:t.getChannelValue("red"),showStepper:!1,className:mr,onChange:i=>{r(t.withChannelValue("red",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("green",a),value:t.getChannelValue("green"),showStepper:!1,className:mr,onChange:i=>{r(t.withChannelValue("green",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("blue",a),value:t.getChannelValue("blue"),showStepper:!1,className:mr,onChange:i=>{r(t.withChannelValue("blue",i).toFormat(J));},step:1,minValue:0,maxValue:255}),o?jsxRuntime.jsx(Yc,{color:e,setColor:r}):null]})},G5={style:"percent",maximumFractionDigits:0},Yc=({color:e,setColor:r})=>{let{locale:o}=reactAria.useLocale(),t=so.useCallback(a=>{r(e.withChannelValue("alpha",a));},[e,r]);return jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("alpha",o),value:e.getChannelValue("alpha"),formatOptions:G5,className:mr,showStepper:!1,onChange:t,minValue:0,maxValue:1})};var _i=({channel:e,...r})=>{let{locale:o}=reactAria.useLocale(),t=color.useColorSliderState({...r,channel:e,locale:o}),a=so__default.default.useRef(null),i=so__default.default.useRef(null),{trackProps:n,thumbProps:l,inputProps:s}=color$1.useColorSlider({...r,channel:e,trackRef:a,inputRef:i,"aria-label":t.value.getChannelName(e,o)},t),{focusProps:p,isFocusVisible:d}=reactAria.useFocusRing();return jsxRuntime.jsxs("div",{className:utils.classNames(wt,{[Zn({size:"xs"})]:e==="alpha"},"BaselineUI-ColorInput-ColorSlider"),"data-channel":e,...n,ref:a,children:[e==="alpha"&&jsxRuntime.jsx("div",{className:fi}),jsxRuntime.jsx("div",{className:wt,style:n.style}),jsxRuntime.jsxs("div",{className:utils.classNames(Nt({isFocusVisible:d}),"BaselineUI-ColorInput-ColorSliderThumb"),...l,children:[jsxRuntime.jsx("div",{className:fi,style:{backgroundColor:"#ffffff"}}),jsxRuntime.jsx("div",{style:{backgroundColor:t.getDisplayColor().toString("css"),height:8},className:wt}),jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{ref:i,...s,...p})})]})]})};var Lt=({color:e,setColor:r,allowAlpha:o})=>{let[t,a]=so__default.default.useState("hex"),{formatMessage:i}=D($e);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(qc,{value:e,xChannel:"saturation",yChannel:"lightness",onChange:r}),jsxRuntime.jsxs("div",{className:ui,children:[jsxRuntime.jsx(_i,{channel:"hue",value:e,onChange:r}),o?jsxRuntime.jsx(_i,{channel:"alpha",value:e,onChange:r}):null]}),jsxRuntime.jsxs("div",{className:utils.classNames(ui,tokens.sprinkles.variants({paddingTop:"none",gap:"sm"})),children:[jsxRuntime.jsx(Ae,{label:i("colorFormat"),labelPosition:"start",variant:"ghost",items:Vc,selectedKey:t,onSelectionChange:n=>{a(n);}}),t==="hex"&&jsxRuntime.jsx(Wc,{color:e,setColor:r,allowAlpha:o}),t==="rgb"&&jsxRuntime.jsx(Xc,{color:e,setColor:r,allowAlpha:o})]})]})};var xi=({color:e,setColor:r,storePickedColorKey:o,addColorButtonLabel:t,removeColorButtonLabel:a,customColorsLabel:i,pickerMode:n,allowAlpha:l})=>{let{locale:s}=reactAria.useLocale(),{formatMessage:p}=D($e),d=so__default.default.useRef(null),u=go(d.current),[c,m]=Fs(o,[]),f=so__default.default.useRef(null),[y,g]=so__default.default.useState(e),v=so__default.default.useMemo(()=>c.map(C=>({id:C,label:color.parseColor(C).getColorName(s),description:C})),[c,s]),b=so.useCallback(()=>{let C=n==="active"?e:y;if(c.includes(C.toString(J))){f.current?.querySelector(`[data-key='${C.toString(J)}']`)?.classList.add(mi);return}m([...c,C.toString(J)]);},[c,e,m,y,n]);so.useEffect(()=>{let C=f.current;function P(k){k.animationName===Ec&&k.target?.classList.remove(mi);}return C?.addEventListener("animationend",P),()=>{C?.removeEventListener("animationend",P);}},[]);let h=reactAria.useId(),z=jsxRuntime.jsx(L,{ref:d,variant:"secondary",size:"md","aria-label":t,icon:_20.PlusIcon,onPress:n==="active"?b:void 0}),x=so.useCallback(C=>jsxRuntime.jsxs(pe,{size:"content",className:Rt({includesCustomColorPicker:!0}),style:{paddingBlockEnd:0},"aria-label":p("newColor"),children:[jsxRuntime.jsx(Lt,{color:y,setColor:g,allowAlpha:l}),jsxRuntime.jsx(H,{}),jsxRuntime.jsx(M,{padding:"lg",display:"flex",flexDirection:"row-reverse",children:jsxRuntime.jsxs(M,{display:"inline-flex",gap:"lg",children:[jsxRuntime.jsx(O,{label:p("cancel"),size:"sm",variant:"secondary",onPress:C}),jsxRuntime.jsx(O,{label:p("add"),variant:"primary",onPress:()=>{b(),C();},size:"sm"})]})})]}),[y,b,p,l]),R=so.useCallback(C=>{utils.invariant(C instanceof Set,"Key must be a set");let P=[...C][0];P&&r(color.parseColor(P).toFormat(J));},[r]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(H,{}),jsxRuntime.jsxs("div",{className:utils.classNames(Mc,"BaselineUI-ColorInput-CustomColors"),children:[jsxRuntime.jsx("span",{id:h,children:i}),jsxRuntime.jsxs(M,{display:"flex",children:[!!c.length&&c.includes(e.toString(J))&&jsxRuntime.jsx(L,{variant:"secondary",size:"md",elementType:"div",icon:_20.MinusIcon,"aria-label":a,onPress:()=>{m(c.filter(C=>C!==e.toString(J)));}}),n==="active"&&z,n==="lazy"&&(u==="mobile"?jsxRuntime.jsxs(ze,{children:[jsxRuntime.jsx(Pt,{children:z}),jsxRuntime.jsx(Te,{style:{zIndex:1e5},children:({close:C})=>x(C)})]}):jsxRuntime.jsx(Ye,{type:"dialog",children:({close:C})=>jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Ze,{children:z}),jsxRuntime.jsx(Ue,{placement:"right top",className:It,offset:6,children:x(C)})]})}))]})]}),!!c.length&&jsxRuntime.jsx(oe,{items:v,layout:"grid","aria-labelledby":h,className:utils.classNames(kt,Tt,tokens.sprinkles.variants({paddingTop:"xs"}),"BaselineUI-ColorInput-CustomColorsListBox"),renderOption:St,ref:f,autoFocus:!1,selectionMode:"single",selectedKeys:[e.toString(J)],onSelectionChange:R})]})};var Ci=so__default.default.forwardRef(({setColor:e,color:r,triggerRef:o,autoFocus:t,presets:a,state:i},n)=>{let{formatMessage:l}=D($e),s=so.useCallback(p=>{if(p instanceof Set&&p.size){let d=[...p][0],u=a.find(c=>c.id===d);utils.invariant(u,"Preset not found"),e(u.id===xe?null:color.parseColor(u.id).toFormat(J)),i.close();}},[i,a,e]);return jsxRuntime.jsx("div",{className:utils.classNames(Tt,"BaselineUI-ColorInput-Presets"),style:{minWidth:o.current?.offsetWidth},ref:n,children:jsxRuntime.jsx(oe,{autoFocus:t,items:a,layout:"grid","aria-label":l("colorPresets"),className:kt,renderOption:St,selectionMode:"single",selectedKeys:[r?.toString(ur)||xe],onSelectionChange:s})})});Ci.displayName="ColorPresetList";var yr=so__default.default.forwardRef(({color:e,colorLabel:r,colorName:o,...t},a)=>{let i=so__default.default.useRef(null),{hoverProps:n,isHovered:l}=reactAria.useHover({isDisabled:t.isDisabled}),{buttonProps:s,isPressed:p}=reactAria.useButton(t,i),{isFocusVisible:d,focusProps:u}=reactAria.useFocusRing(),c=utils.filterTruthyValues({"data-block-id":t["data-block-id"],"data-focused":d,"data-focus-visible":d,"data-disabled":t.isDisabled,"data-hovered":l,"data-pressed":p});return jsxRuntime.jsxs("button",{...reactAria.mergeProps(s,n,u,c),style:t.style,className:utils.classNames(Tc({isHovered:l,isFocusVisible:d||t.isOpen,isDisabled:t.isDisabled,labelPosition:t.labelPosition}),"BaselineUI-ColorInputButton",t.className),ref:N(a,i),children:[jsxRuntime.jsx(he,{color:e?.toString("hexa")}),r?jsxRuntime.jsx("div",{className:Sc,children:o}):jsxRuntime.jsx(reactAria.VisuallyHidden,{children:o})]})});yr.displayName="ColorInputButton";var Dt=so__default.default.forwardRef(({className:e,style:r,icon:o,...t},a)=>{let i=so__default.default.useRef(null),{hoverProps:n,isHovered:l}=reactAria.useHover({isDisabled:t.isDisabled}),{buttonProps:s,isPressed:p}=reactAria.useButton(t,i),{isFocusVisible:d,focusProps:u}=reactAria.useFocusRing(),c=utils.filterTruthyValues({"data-block-id":t["data-block-id"],"data-focused":d,"data-focus-visible":d,"data-disabled":t.isDisabled,"data-hovered":l,"data-pressed":p});return jsxRuntime.jsxs("button",{...reactAria.mergeProps(s,n,u,c),ref:N(a,i),style:r,className:utils.classNames(Dc({isHovered:l||p||t.isOpen,isFocusVisible:d,isDisabled:t.isDisabled}),"BaselineUI-IconColorInputButton",e),children:[jsxRuntime.jsx(o,{size:16}),jsxRuntime.jsx("div",{className:Ic,style:{backgroundColor:t.color||void 0}})]})});Dt.displayName="IconColorInputButton";function md({colorLabel:e,color:r,presets:o}){let{formatMessage:t}=D(),{locale:a}=reactAria.useLocale(),i=so.useMemo(()=>o.find(s=>s.id===xe?!r:r?Ac(r,color.parseColor(s.id)):!1),[o,r]),n=so.useMemo(()=>typeof e=="function"?e?.(r):e?jc(r,i,t(vz.transparent)):!1,[r,e,t,i]),l=so.useMemo(()=>{if(i?.label)return i.label;r?.getColorName(a);},[r,a,i?.label]);return {colorName:n,humanReadableName:l}}var vz=A({transparent:{defaultMessage:"Transparent",id:"transparent"}});var Do=so__default.default.forwardRef(({className:e,style:r,allowRemoval:o,allowAlpha:t=!0,presets:a,labelPosition:i="top",colorLabel:n=!0,includePicker:l=!0,onChange:s,defaultValue:p,storePickedColorKey:d="baselinePickedColor",value:u,addColorButtonLabel:c,removeColorButtonLabel:m,customColorsLabel:f,renderTriggerButton:y=({isOpen:R,color:C,ref:P,colorName:k,triggerProps:T,labelId:I})=>jsxRuntime.jsx(yr,{...reactAria.mergeProps(T,{...z.label?{"aria-labelledby":I}:{"aria-label":z["aria-label"]}}),ref:P,isOpen:R,isDisabled:z.isDisabled,labelPosition:i,color:C,colorLabel:n,colorName:k}),pickerMode:g="active",offset:v=2,placement:b=i==="start"?"bottom end":"bottom start","data-block-id":h,...z},x)=>{let R=so__default.default.useRef(null),C=so__default.default.useRef(null),P=reactStately.useOverlayTriggerState(z),{triggerProps:k,overlayProps:T}=reactAria.useOverlayTrigger({type:"listbox"},P,R),I=le(z.portalContainer),[B,E]=utils$1.useControlledState(u===void 0?void 0:eo(u),eo(p),V=>s?.(V?.toFormat("rgba")||null)),{formatMessage:w}=D($e),S=so.useMemo(()=>$c(w(Et.noColor),a),[a,w]),$=reactAria.useId(),{colorName:re}=md({colorLabel:n,color:B,presets:S}),ne=so.useMemo(()=>S.filter(V=>o||V.id!==xe),[S,o]),X=c||w(Et.addColor),K=m||w(Et.removeColor),G=f||w(Et.customColors);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("div",{className:utils.classNames({[Rc]:i==="start"},"BaselineUI-ColorInput-Trigger",e),"data-block-id":h,style:r,ref:x,children:[z.label?jsxRuntime.jsx("label",{id:$,className:Nc({labelPosition:i}),children:z.label}):null,y({isOpen:P.isOpen,color:B,ref:R,colorName:re,triggerProps:k,labelId:$})]}),P.isOpen?jsxRuntime.jsx(ie,{...z,portalContainer:I,placement:b,state:P,offset:v,className:utils.classNames(It,"BaselineUI-ColorInput-Popover"),triggerRef:R,overlayProps:T,children:jsxRuntime.jsxs(pe,{size:"content",className:Rt({includesCustomColorPicker:l}),ref:C,"aria-labelledby":$,"aria-label":z["aria-label"],children:[l&&g==="active"?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Lt,{color:B||Lo,setColor:E,allowAlpha:t}),jsxRuntime.jsx(xi,{color:B||Lo,setColor:E,storePickedColorKey:d,addColorButtonLabel:X,removeColorButtonLabel:K,customColorsLabel:G,pickerMode:g,allowAlpha:t})]}):null,!!ne.length&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[l&&g==="active"?jsxRuntime.jsx(H,{}):null,jsxRuntime.jsx(Ci,{autoFocus:l&&g==="active"?!1:"first",state:P,triggerRef:R,presets:ne,color:B,setColor:E})]}),l&&g==="lazy"?jsxRuntime.jsx(xi,{color:B||Lo,setColor:E,storePickedColorKey:d,addColorButtonLabel:X,removeColorButtonLabel:K,customColorsLabel:G,pickerMode:g,allowAlpha:t}):null]})}):null]})});Do.displayName="ColorInput";var Et=A({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 bd=so__default.default.forwardRef(({className:e,style:r,icon:o,includeTooltip:t,variant:a="standard","data-block-id":i,placement:n="bottom start",...l},s)=>{let p=so__default.default.useRef(null),d=so.useCallback(({isOpen:u,color:c,ref:m,colorName:f,triggerProps:y})=>jsxRuntime.jsx(He,{isDisabled:!t||l.isDisabled,variant:"inverse",size:"sm",includeArrow:!1,text:l["aria-label"],placement:n,offset:4,children:a==="standard"?jsxRuntime.jsx(yr,{...y,"aria-label":l["aria-label"],ref:m,isOpen:u,isDisabled:l.isDisabled,color:c,colorLabel:!1,colorName:f}):jsxRuntime.jsx(Dt,{...y,isOpen:u,icon:_20.TextIcon,color:c?.toString("hexa"),ref:m,isDisabled:l.isDisabled,"aria-label":l["aria-label"]})}),[t,n,l,a]);return jsxRuntime.jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:a==="standard"?"md":"none",alignItems:"center",className:utils.classNames("BaselineUI-IconColorInput",e),"data-block-id":i,style:r,ref:N(s,p),children:[a==="standard"&&jsxRuntime.jsx(o,{size:24,className:tokens.sprinkles({color:"icon.primary"})}),jsxRuntime.jsx(Do,{...l,colorLabel:!1,renderTriggerButton:d})]})});bd.displayName="IconColorInput";var gd={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 Ft=_({defaultClassName:"mnnh5s1 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ki _1yep5z6kl _1yep5z6kx _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{true:"mnnh5s2 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy _1yep5z6122 _1yep5z616j _1yep5z616k",false:"_1yep5z6166 _1yep5z6116"},isHovered:{true:"mnnh5s4"},hasLoadedImage:{true:"_1yep5z6115"},includeCheckeredBackground:{true:"mnnh5s6"},showFocusRing:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 _1yep5z6yl"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,hasLoadedImage:!1},"_1yep5z61mo"],[{isHovered:!0,hasLoadedImage:!0},"mnnh5s9"],[{isInline:!0,isDisabled:!0},"_1yep5z61nd"],[{hasLoadedImage:!0,includeCheckeredBackground:!0},"_1yep5z61mg"]]}),vd="_1yep5z6d8",Ht=_({defaultClassName:"mnnh5sa",variantClassNames:{isInline:{true:"mnnh5sb",false:"mnnh5sc"},isDisabled:{true:"mnnh5sd"},hasLoadedImage:{true:"mnnh5s0"}},defaultVariants:{},compoundVariants:[]});var _d=_({defaultClassName:"_1i0ytqa3 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6kw _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1i0ytqa4"},isInline:{true:"_1yep5z611e",false:"_1yep5z611g"},isDisabled:{true:"_1i0ytqa7 _1yep5z6yl",false:"_1i0ytqa8"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isFocusVisible:!0},"_1i0ytqa9 _1yep5z61n9 _1yep5z61rt _1yep5z61rv"],[{isInline:!1,isFocusVisible:!0},"_1i0ytqaa"],[{isInline:!0,isDisabled:!0},"_1yep5z61mp"],[{isInline:!1,isDisabled:!0},"_1yep5z61mr"]]}),zd="_1i0ytqa0",Ot=_({defaultClassName:"_1i0ytqab _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z6115"},isDisabled:{true:"_1i0ytqad _1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),hd=_({defaultClassName:"_1i0ytqa1 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b"}},defaultVariants:{},compoundVariants:[]});var Az={size:1,thinning:0,smoothing:0,streamline:0,easing:e=>e,start:{taper:0,easing:e=>e,cap:!0},end:{taper:0,easing:e=>e,cap:!0},simulatePressure:!1},xd=so__default.default.forwardRef(({className:e,style:r,canvasClassName:o,canvasStyle:t,isBound:a=!0,strokeWidth:i=2,strokeColor:n="#3A87FD",onChange:l,defaultValue:s,onChangeEnd:p,enableHistory:d=!1,isInline:u=!0,isDisabled:c,placeholder:m,clearLabel:f,undoLabel:y,redoLabel:g,footerClassName:v,canvasRef:b,value:h,footerStyle:z,"data-block-id":x,"aria-label":R="Drawing canvas",description:C="This is a canvas for drawing using a mouse or touch input.",...P},k)=>{let T=D(gd),I=so__default.default.useRef(null),[B,E]=so__default.default.useState(h?Ti(h):s?Ti(s):[]),w=so__default.default.useRef((h?.length||s?.length||0)-1),[S,$]=so__default.default.useState(),re=reactAria.useId(),{labelProps:ne,fieldProps:X}=reactAria.useLabel({...P,"aria-label":R,labelElementType:"span"}),{isFocusVisible:K,focusProps:G}=reactAria.useFocusRing({within:!0}),{hoverProps:V,isHovered:Z}=reactAria.useHover({isDisabled:c}),{undo:ee,redo:Ce,canRedo:Pe,canUndo:me,push:ke}=Ls(B,{onAction:F=>{F&&(E(F),w.current=F.length-1,p?.(F.map(fe=>perfectFreehand.getStroke(fe,U))));},isDisabled:!d}),{keyboardProps:Le}=reactAria.useKeyboard({onKeyDown:F=>{F.key==="Backspace"?Or():F.key==="z"&&(F.metaKey||F.ctrlKey)&&(F.shiftKey?Pe&&Ce():me&&ee());}}),U=so__default.default.useMemo(()=>({...Az,...P}),[P]),ue=so.useCallback(F=>{F.persist(),!(F.buttons!==1||!S)&&E(fe=>{let j=[...fe];return j[w.current]=[...j[w.current],{x:a?utils$1.clamp(F.clientX-S.left,0,S.width):F.clientX-S.left,y:a?utils$1.clamp(F.clientY-S.top,0,S.height):F.clientY-S.top,pressure:F.pressure}],j});},[S,a]),sa=so.useCallback(F=>{F.persist();let fe=F.currentTarget.getBoundingClientRect();$(fe),F.target.setPointerCapture(F.pointerId),w.current+=1,E(j=>{let se=[...j];return se[w.current]=[{x:F.clientX-fe.x,y:F.clientY-fe.y,pressure:F.pressure}],se});},[]),Hr=Fe();granularHooks.useGranularEffect(()=>{Hr||l?.(B.map(F=>perfectFreehand.getStroke(F,U)));},[B],[l,U,Hr]);let Or=()=>{E([]),w.current=-1,ke([]);},la=so.useCallback(()=>{S&&(p?.(B.map(F=>perfectFreehand.getStroke(F,U))),ke(B));},[S,p,B,ke,U]);return jsxRuntime.jsxs("div",{ref:N(I,k),className:utils.classNames(zd,"BaselineUI-FreehandCanvas",e),style:r,"aria-disabled":c,"data-block-id":x,children:[P.label||d?jsxRuntime.jsxs("div",{className:hd({isInline:u}),children:[P.label?jsxRuntime.jsx(W,{type:"label",size:"sm",...ne,children:P.label}):jsxRuntime.jsx("span",{}),d?jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx(L,{variant:"secondary",size:"sm",isDisabled:!me||c,icon:_16.UndoIcon,onPress:ee,"aria-label":y||T.formatMessage("undo")}),jsxRuntime.jsx(L,{variant:"secondary",size:"sm",isDisabled:!Pe||c,icon:_16.RedoIcon,onPress:Ce,"aria-label":g||T.formatMessage("redo")})]}):null]}):null,jsxRuntime.jsxs("div",{role:"application",...reactAria.mergeProps(G,Le,V,X),tabIndex:c?void 0:0,className:utils.classNames(Ft({isInline:u,isHovered:Z}),_d({isFocusVisible:K,isInline:u,isDisabled:!!c}),o),"aria-describedby":P["aria-describedby"]||re,style:t,ref:b,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("div",{id:re,children:C})}),jsxRuntime.jsx("svg",{width:t?.width||"100%",height:t?.height||"100%",onPointerDown:sa,onPointerMove:ue,onPointerUp:la,children:(h?Ti(h):B).map((F,fe)=>jsxRuntime.jsx("path",{d:utils.getSvgPathFromStroke(perfectFreehand.getStroke(F,U)),stroke:n,strokeWidth:i},fe))})]}),m||f?jsxRuntime.jsx("div",{style:z,className:utils.classNames(Ot({isInline:u,isDisabled:c}),v),children:(B.length||!m)&&f?jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:f,isDisabled:c,onPress:Or}):jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:m,isDisabled:!0})}):null]})});xd.displayName="FreehandCanvas";var Ti=e=>e.map(r=>r.map(([o,t])=>({x:o,y:t,pressure:0})));var Cd="_1vac7ws0",Pd=_({defaultClassName:"_1vac7ws1",variantClassNames:{isDragging:{true:"_1vac7ws2"}},defaultVariants:{},compoundVariants:[]});function wd(e,r){let[o,t]=so.useState([]),a=()=>e?.flatMap(i=>[...r.querySelectorAll(i)]).map(i=>({current:i}));return granularHooks.useGranularEffect(()=>{t(a());},[],[a]),granularHooks.useGranularEffect(()=>{let i=a();t(i);},[e],[a]),o}function Rd(e){let{scrollable:r,ownerDocument:o,onScroll:t}=e;so.useEffect(()=>{let a=utils.getHTMLElement(r,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",t),()=>{a.removeEventListener("scroll",t);}},[r,t,o]);}var th=reactMoveable.makeMoveable([reactMoveable.Draggable,reactMoveable.Resizable,reactMoveable.Rotatable,reactMoveable.Snappable]),Td=so__default.default.forwardRef(({className:e,children:r,isRotatable:o,isResizable:t,isDraggable:a,style:i,onTransform:n,onTransformStart:l,onTransformEnd:s,onDoubleClick:p,onDragStart:d,onDragEnd:u,onDrag:c,onResizeStart:m,onResizeEnd:f,onResize:y,onRotateStart:g,onRotateEnd:v,onRotate:b,onSnap:h,isSnappable:z,elementGuidelines:x,hideAnchorOnDrag:R=!0,title:C,rotationPosition:P,autoUpdate:k,bound:T,snapRotationDegrees:I,snapRotationThreshold:B,scrollableAncestor:E,renderDirections:w,stopPropagation:S,transformOrigin:$,preventDefault:re},ne)=>{let X=so.useRef(null),K=so.useRef(null),[G,V]=so.useState(document),Z=so.useRef(G.createElement("div")),[ee,Ce]=so.useState({}),[Pe,me]=so.useState(!1),[ke,Le]=so.useState(!1),[U,ue]=so.useState(),sa=wd(x,G);so.useLayoutEffect(()=>{let j=Z.current;return Z.current=G.createElement("div"),()=>{j.remove();}},[G]);let{keyboardProps:Hr}=reactAria.useKeyboard({onKeyDown:j=>{let se=j.shiftKey?10:1,ve=j.metaKey||j.ctrlKey;ve&&j.shiftKey&&(se=45);function We(Ko,mf="x"){ve?K.current?.request("rotatable",{deltaRotate:Ko*se},!0):K.current?.request("draggable",mf==="x"?{deltaX:Ko*se}:{deltaY:Ko*se},!0);}switch(j.key){case"ArrowRight":{We(1);break}case"ArrowLeft":{We(-1);break}case"ArrowUp":{We(-1,"y");break}case"ArrowDown":We(1,"y");}requestAnimationFrame(()=>{K.current?.updateRect();});}});so.useEffect(()=>{let j=ye(X.current);V(j);let se=Z.current;j.body.append(Z.current);function ve(Ko){Le(Ko.shiftKey);}function We(){Le(!1);}return j.addEventListener("keydown",ve),j.addEventListener("keyup",We),()=>{j.removeEventListener("keydown",ve),j.removeEventListener("keyup",We),se.remove();}},[]),Rd({scrollable:E,onScroll:()=>{K.current?.updateRect();},ownerDocument:G});let Or=so.useCallback(j=>{Ce(se=>({...se,...j.style})),n?.(j);},[n]),la=so.useCallback(j=>{if(me(!0),X.current?.focus(),T){let ve=utils.getHTMLElement(T,G)?.getBoundingClientRect();ue({position:"client",left:ve?.left??0,top:ve?.top??0,right:ve?.right??0,bottom:ve?.bottom??0});}d?.(j);},[T,G,d]),F=so.useCallback(j=>{me(!1),u?.(j);},[u]),fe=r({style:{...ee.width&&{width:ee.width},...ee.height&&{height:ee.height}}});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{role:"button",...Hr,ref:N(X,ne),style:{display:"inline-block",...i,...ee},className:utils.classNames(Cd,e),onDoubleClick:p,tabIndex:0,title:C,children:fe}),reactDom.createPortal(jsxRuntime.jsx(th,{ref:K,target:X,draggable:a,resizable:t,rotatable:o,keepRatio:ke,throttleDrag:1,snappable:z||!!T,elementGuidelines:sa,snapRenderThreshold:.9,className:Pd({isDragging:Pe&&R}),onRender:Or,onDragStart:la,onDragEnd:F,useResizeObserver:k,useMutationObserver:k,onRenderEnd:s,onDrag:c,onResizeStart:m,onResizeEnd:f,onResize:y,onRotateStart:g,onRotateEnd:v,onRotate:b,onRenderStart:l,onSnap:h,rotationPosition:P,bounds:U,snapRotationDegrees:I,snapRotationThreshold:B,renderDirections:w,stopPropagation:S,preventDefault:re,transformOrigin:$}),Z.current)]})});Td.displayName="Transform";var Nd={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 Md=so__default.default.forwardRef(({className:e,style:r,isInline:o=!0,accept:t="image/*",defaultImageSrc:a,imageSrc:i,imageAlt:n,pickerButtonLabel:l,isDisabled:s,onDrop:p,onPaste:d,includeCheckeredBackground:u=!0,"data-block-id":c,pickerButtonStyle:m,pickerButtonClassName:f,footerClassName:y,footerStyle:g,clearLabel:v,placeholder:b,labelStyle:h,labelClassName:z,...x},R)=>{let C=so__default.default.useRef(null),P=so__default.default.useRef(null),{formatMessage:k}=D(Nd),[T,I]=utils$1.useControlledState(i,a||null,U=>{utils.invariant(typeof U!="string"),x.onValueChange?.(U?[U]:[]);}),B=so.useMemo(()=>gh(T||void 0),[T]),{fieldProps:E,labelProps:w}=reactAria.useField(x),{dropProps:S,isDropTarget:$}=reactAria.useDrop({ref:C,onDrop:async U=>{if(s)return;let ue=await Oa({items:U.items});ue.length&&I(ue[0]),p?.(U);},...x}),{clipboardProps:re}=reactAria.useClipboard({onPaste:async U=>{if(s)return;let ue=await Oa({items:U});ue.length&&I(ue[0]),d?.(U);},...x}),ne=()=>{I(null),P.current&&(P.current.value="");},X={type:"file",onChange:U=>{let ue=[...U.target.files];I(ue[0]),x.onChange?.(U);},accept:t,disabled:s},{focusProps:K,isFocused:G,isFocusVisible:V}=reactAria.useFocusRing({within:!0}),{hoverProps:Z,isHovered:ee}=reactAria.useHover({isDisabled:s}),{imgProps:Ce,isLoading:Pe,isLoaded:me}=bo({src:B,alt:n||""}),ke={label:l||k("selectImage"),onPress:()=>C.current?.click(),variant:"secondary",isDisabled:s,excludeFromTabOrder:!0,className:utils.classNames(Gr({isFocusVisible:V}),{[vd]:$&&!s},f),style:m},Le=utils.filterTruthyValues({"data-loaded":me,"data-block-id":c,"data-hovered":ee,"data-focused":G,"data-drop-target":$,"data-disabled":s,"data-focus-visible":V});return jsxRuntime.jsxs(M,{...Le,className:utils.classNames("BaselineUI-ImageDropZone",e),display:"flex",flexDirection:"column",alignItems:"center",style:r,ref:R,children:[jsxRuntime.jsxs("label",{...reactAria.mergeProps(S,Z,K,w),className:utils.classNames(Ft({isInline:o,isHovered:ee,isDisabled:s,hasLoadedImage:!!B&&me,showFocusRing:$||!!B&&V}),z),style:h,ref:C,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(E,re,X),ref:P})}),!B&&jsxRuntime.jsx(O,{...ke}),!!B&&(Pe?jsxRuntime.jsx(Io,{}):jsxRuntime.jsx("img",{className:Ht({isInline:o,isDisabled:s,hasLoadedImage:!!B&&me&&u}),...Ce}))]}),b||v?jsxRuntime.jsx("div",{style:g,className:utils.classNames(Ot({isInline:o,isDisabled:s}),y),children:(B||!b)&&v?jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:v,isDisabled:s,onPress:ne}):jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:b,isDisabled:!0})}):null]})});Md.displayName="ImageDropZone";function gh(e){return e instanceof File?URL.createObjectURL(e):e}var Bd="_1vm2oh49 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6fv",Mi="_1vm2oh48 _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6jc _1yep5z6jd _1yep5z6je",Dd=_({defaultClassName:"_1vm2oh40 mnnh5s1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6l1 _1yep5z6kz _1yep5z6hk _1yep5z6l2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kx _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{accent:{theme:"_1vm2oh41",positive:"_1vm2oh42"},isInline:{true:"mnnh5s2 _1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6121 _1yep5z616i _1yep5z616k",false:"_1yep5z611g"},isFocusVisible:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 z9nup83 _1yep5z6yl"},isHovered:{true:"_1vm2oh47"}},defaultVariants:{},compoundVariants:[[{accent:"positive",isInline:!0},"_1yep5z61mp"],[{accent:"theme",isInline:!0},"_1yep5z61me"],[{accent:"positive",isInline:!1},"_1yep5z61mr"],[{accent:"theme",isInline:!1},"_1yep5z61mg"],[{isFocusVisible:!0,isInline:!0},"_1yep5z61ny _1yep5z61rl _1yep5z61rn _1yep5z61ro"],[{isHovered:!0,isInline:!0},"_1yep5z61ro _1yep5z61ny _1yep5z61rl _1yep5z61rn"],[{isHovered:!0,isInline:!1,accent:"positive"},"_1yep5z61mq"],[{isHovered:!0,isInline:!1,accent:"theme"},"_1yep5z61mi"],[{isHovered:!0,isInline:!0,accent:"theme"},"_1yep5z61mf"]]});var Hd=so__default.default.forwardRef(({className:e,style:r,isDisabled:o,isInline:t=!0,imageAlt:a,imageSrc:i,svgSrc:n,textValue:l,textStyle:s,onPress:p,onDelete:d,deleteAriaLabel:u,addAriaLabel:c,accent:m="positive","data-block-id":f,...y},g)=>{let{focusProps:v,isFocused:b,isFocusVisible:h}=reactAria.useFocusRing({within:!0}),{isHovered:z,hoverProps:x}=reactAria.useHover({isDisabled:o}),{pressProps:R}=reactAria.usePress({isDisabled:o,onPress:p});utils.invariant(i||n||l,"Preview must have content. You must provide either an `imageSrc`, `svgSrc`, or `textValue` prop.");let C=utils.filterTruthyValues({"data-hovered":z,"data-focus-visible":h,"data-focused":b,"data-disabled":o});return jsxRuntime.jsxs("div",{...y,className:utils.classNames(Dd({isInline:t,isFocusVisible:h,isDisabled:o,isHovered:z,accent:m}),"BaselineUI-Preview",e),"data-block-id":f,"aria-label":y["aria-label"]||a||l,style:r,ref:g,children:[typeof n=="string"?jsxRuntime.jsx("button",{disabled:o,...reactAria.mergeProps(x,v,R,C),className:Mi,"aria-label":c,dangerouslySetInnerHTML:{__html:n}}):jsxRuntime.jsxs("button",{...reactAria.mergeProps(x,v,R,C),disabled:o,style:s,"aria-label":c,className:Mi,children:[i?jsxRuntime.jsx("img",{src:i,alt:a,className:Ht({isInline:t,isDisabled:o})}):null,!!n&&typeof n=="object"&&n,l]}),d?jsxRuntime.jsx(L,{isDisabled:o,className:Bd,"aria-label":u,size:"xs",icon:_16.TrashIcon,onPress:d}):null]})});Hd.displayName="Preview";var Od="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e",Vd=_({defaultClassName:"cw3m0n8 _1yep5z6ew _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Ad="cw3m0n7",jd=_({defaultClassName:"cw3m0n0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),$d="_1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ks",Ud=_({defaultClassName:"cw3m0n3 _16vugd05",variantClassNames:{isFocusVisible:{true:"_16vugd08"},isSelected:{true:"_16vugd07"},isDisabled:{true:"_16vugd0a"}},defaultVariants:{},compoundVariants:[]});var Bh=({label:e,description:r},{isSelected:o,isFocusVisible:t,isDisabled:a,optionLabelPosition:i})=>jsxRuntime.jsxs("div",{className:jd({labelPosition:i}),children:[jsxRuntime.jsx("div",{className:Ud({isSelected:o,isFocusVisible:t,isDisabled:a}),children:o?jsxRuntime.jsx("div",{className:Ad}):null}),e?jsxRuntime.jsxs("div",{className:Od,children:[jsxRuntime.jsx("span",{className:ut({isDisabled:a}),children:e}),r?jsxRuntime.jsx("span",{className:Vd({isDisabled:a}),children:r}):null]}):null]}),qd=({state:e,renderOption:r=Bh,item:o,optionLabelPosition:t="end",optionStyle:a,optionClassName:i,isReadOnly:n,...l})=>{let s=!!l.isDisabled||!!l.disabledValues?.includes(o.id),p=so__default.default.useRef(null),{inputProps:d,isPressed:u,isSelected:c}=reactAria.useRadio({...l,isDisabled:s,children:o.label,value:o.id},e,p),{focusProps:m,isFocusVisible:f,isFocused:y}=reactAria.useFocusRing(),{isHovered:g}=reactAria.useHover({isDisabled:s}),v=utils.filterTruthyValues({"data-selected":c,"data-focused":y,"data-focus-visible":f,"data-hovered":g,"data-disabled":s,"data-pressed":u,"data-read-only":n});return jsxRuntime.jsxs("label",{...v,style:a,className:utils.classNames("BaselineUI-Radio-Item",i),children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(d,m),ref:p})}),r(o,{isFocusVisible:f,isSelected:c,isFocused:y,isHovered:g,isDisabled:s,optionLabelPosition:t,isReadOnly:n})]})};var Ut=so__default.default.forwardRef(({className:e,style:r,optionsContainerClassName:o,optionsContainerStyle:t,items:a,labelPosition:i="top",renderOption:n,"aria-label":l,"aria-labelledby":s,"aria-describedby":p,"aria-details":d,"data-block-id":u,...c},m)=>{let f=reactStately.useRadioGroupState(c),{radioGroupProps:y,labelProps:g,descriptionProps:v,errorMessageProps:b}=reactAria.useRadioGroup({...c,"aria-label":l,"aria-labelledby":s,"aria-describedby":p,"aria-details":d},f),h=_e({...c,descriptionProps:v,errorMessageProps:b,labelPosition:i}),z=utils.filterTruthyValues({"data-orientation":c.orientation,"data-block-id":u,"data-disabled":c.isDisabled,"data-readonly":c.isReadOnly});return jsxRuntime.jsxs("div",{...reactAria.mergeProps(y,z),className:utils.classNames(De({labelPosition:i}),"BaselineUI-RadioGroup",e),style:r,ref:m,children:[c.label||h?jsxRuntime.jsxs("div",{className:Be({labelPosition:i,hasMessage:!!h}),children:[jsxRuntime.jsx("span",{...g,className:utils.classNames(Me,"BaselineUI-RadioGroup-Label"),children:c.label}),i==="start"&&h]}):null,jsxRuntime.jsxs("div",{className:utils.classNames({[po]:c.isDisabled}),children:[jsxRuntime.jsx("div",{className:utils.classNames($d,o),style:t,children:a.map(x=>jsxRuntime.jsx(qd,{state:f,renderOption:n,item:x,...c,value:x.id},x.id))}),i==="top"&&h]})]})});Ut.displayName="RadioGroup";var Kd=({id:e,defaultMessage:r,elementType:o=so.Fragment})=>{utils.invariant(e||r,"`id` or `defaultMessage` is required.");let t=D();return jsxRuntime.jsx(o,{children:t.formatMessage(e)||r})};Kd.displayName="MessageFormat";var Gd=so__default.default.forwardRef(({className:e,style:r,children:o,role:t="group",isDisabled:a,...i},n)=>{let{hoverProps:l,isHovered:s}=reactAria.useHover({isDisabled:a});return jsxRuntime.jsx("div",{...l,role:t,"data-hovered":s,"data-disabled":a,className:e,style:r,...i,ref:n,children:o})});Gd.displayName="Group";var qt="_46ioju0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e",Kt="_1yep5z61ov _1yep5z61ow _1yep5z61ox _1yep5z61g1 _1yep5z61g2 _1yep5z61g3";var Xd=so__default.default.forwardRef(({items:e,optionsContainerClassName:r,...o},t)=>{let a=so.useMemo(()=>e.map(i=>({id:i.color,label:i.label})),[e]);return so.useEffect(()=>{console.warn("`ColorPresetInlineInput` is deprecated. Please use `ColorSwatchPicker` instead.");},[]),jsxRuntime.jsx(Ut,{items:a,optionsContainerClassName:utils.classNames(Kt,r),orientation:"horizontal",renderOption:({label:i,id:n},{isSelected:l,isFocusVisible:s})=>jsxRuntime.jsx("div",{className:qt,children:jsxRuntime.jsx(he,{isFocusVisible:s,color:n,isSelected:l,"aria-label":i,isInteractive:!0})}),...o,className:utils.classNames(o.className,"BaselineUI-ColorPresetInput"),ref:t})});Xd.displayName="ColorPresetInput";var Oi="UNSUPPORTED_IN_MENU";function Qd(e){return so.useMemo(()=>so__default.default.Children.toArray(e).map(r=>{let o=r,t=lodash.uniqueId("item"),a=zr(o,Ye),i=Zd(o),n,l;if(a){let v=zr(a,Ze);utils.invariant(v),n=Zd(v),l=zr(a,Ue).props.children;}else i?n=i:n=o;let{onPress:s,label:p,"aria-label":d,iconStart:u,isDisabled:c,icon:m}=n.props,f=p||d||Oi;utils.invariant(typeof f=="string","ActionGroup children must have a string label");let y=`${t}-${f}`;return so.createElement(reactStately.Item,{...{key:y,onPress:s,textValue:f,"aria-label":d,icon:u||m,dialogContent:l,isDisabled:c},key:y},o)}),[e])}function zr(e,r){return r?lodash.flatMapDeep(so__default.default.Children.toArray(e),t=>so__default.default.isValidElement(t)&&t.props.children?[t,...so__default.default.Children.toArray(t.props.children)]:[t]).find(t=>so__default.default.isValidElement(t)&&t.type===r):void 0}function Zd(e){return zr(e,O)||zr(e,L)}var Jd="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6kn",em={horizontal:"xvr3wn0",vertical:"xvr3wn1"};var Ai=so__default.default.forwardRef(({className:e,style:r,children:o,collapsibleMenuProps:t,"data-block-id":a,renderSpacer:i,...n},l)=>{let{formatMessage:s}=D(),[p,d]=so.useState(),u=Qd(o),c=reactStately.useListState({...n,children:u}),m=Re(l),f=so.useRef(null),[{visibleItems:y,isMeasuring:g},v]=ca({visibleItems:c.collection.size,isMeasuring:!1}),b=so.useCallback(()=>{let k=T=>{if(f.current&&m.current){let I=[...f.current.children],B=m.current.getBoundingClientRect().width,E=T<c.collection.size,w=0,S=0;if(E){let $=I.pop();$&&(w+=am($,!1,!0));}for(let[$,re]of I.entries())if(w+=am(re,$===0,$===I.length-1),Math.round(w)<=Math.round(B))S++;else break;return S}return T};v(function*(){yield {visibleItems:c.collection.size,isMeasuring:!0};let T=k(c.collection.size),I=T<c.collection.size&&T>0;yield {visibleItems:T,isMeasuring:I},I&&(yield {visibleItems:k(T),isMeasuring:!1});});},[v,m,c.collection.size]),h=so.useMemo(()=>({get current(){return m.current?.parentElement}}),[m]);ya({ref:h,onResize:b}),we(b,[c.collection,b]);let{toolbarProps:z}=toolbar.useToolbar(n,m),x=[...c.collection],R=x.slice(0,y),C=x.slice(y).filter(k=>k.textValue!==Oi),P=C.length>0;return so.useEffect(()=>{d(void 0);},[C.length]),so.useEffect(()=>{n.orientation==="vertical"&&console.warn("Toolbar: Vertical orientation is not supported when `isCollapsible` is true.");},[n.orientation]),jsxRuntime.jsxs(reactAria.FocusScope,{children:[jsxRuntime.jsx("div",{...z,className:e,"data-block-id":a,"data-collapse":!0,style:{...r,flexBasis:g?"100%":void 0},ref:m,children:jsxRuntime.jsxs("div",{ref:f,className:Jd,children:[R.map(k=>k.rendered),P?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[!g&&i?.(),jsxRuntime.jsx(lt,{placement:"bottom end",renderTrigger:({buttonProps:k,ref:T})=>jsxRuntime.jsx(L,{...k,size:"md",icon:_24.MoreIcon,"aria-label":s(lx.more),variant:"toolbar",ref:T}),...t,disabledKeys:C.filter(k=>k.props?.isDisabled).map(k=>k.key),items:C.map(k=>{let T=k.textValue||k["aria-label"];return utils.invariant(T,"ActionItem must have a label"),{id:k.key,label:T,icon:k.props.icon}}),onAction:k=>{let T=c.collection.getItem(k);utils.invariant(T,"Item not found");let{onPress:I,dialogContent:B}=T.props;I?.(),d(B);}})]}):null]})}),jsxRuntime.jsx(ze,{isOpen:!!p,onOpenChange:k=>{k||d(void 0);},children:jsxRuntime.jsx(Te,{enableDrawer:"auto",style:{zIndex:1e5},children:p?so__default.default.cloneElement(p,{inheritDrawer:!0}):null})})]})});Ai.displayName="CollapsibleToolbar";function am(e,r,o){let a=Q(e).getComputedStyle(e);return e.getBoundingClientRect().width+(r?0:im(a.marginLeft))+(o?0:im(a.marginRight))}function im(e){let r=Number.parseInt(e,10);return Number.isNaN(r)?0:r}var lx=A({more:{id:"more",defaultMessage:"More"}});var ji=so__default.default.forwardRef(({className:e,style:r,"data-block-id":o,"aria-controls":t,...a},i)=>{let n=so__default.default.useRef(null),{toolbarProps:l}=toolbar.useToolbar(a,n);return jsxRuntime.jsx("div",{...l,"aria-controls":t,className:utils.classNames(em[a.orientation||"horizontal"],"BaselineUI-Toolbar",e),style:r,"data-block-id":o,ref:N(i,n),children:a.children})});ji.displayName="WrappedToolbar";var Gt=so__default.default.forwardRef((e,r)=>{let o=e.isCollapsible?Ai:ji;return jsxRuntime.jsx(o,{...e,ref:r})});Gt.displayName="Toolbar";var sm=_({defaultClassName:"_1j5skr71",variantClassNames:{size:{xxs:"_1j5skr72",xs:"_1j5skr73",sm:"_1j5skr74",md:"_1j5skr75",lg:"_1j5skr76"}},defaultVariants:{},compoundVariants:[]}),lm=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7g"},isFocusVisible:{true:"_1j5skr7h"},isDisabled:{true:"z9nup83 _1yep5z610d"},isSelected:{true:"_1j5skr7j"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61rl _1yep5z61o5 _1yep5z61lo"],[{isSelected:!1,isHovered:!0,isDisabled:!1},"_1yep5z6fu"],[{isSelected:!1,isFocusVisible:!0,isDisabled:!1},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0,isDisabled:!1},"_1j5skr7k _1yep5z61rm _1yep5z61rl _1yep5z61nz _1yep5z61lp"],[{isSelected:!0,isFocusVisible:!1,isDisabled:!1},"_1yep5z61rl _1yep5z61rn _1yep5z61ny _1yep5z61ro"]]}),pm=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7m"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1yep5z610c"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61ln"]]}),cm=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7r"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1j5skr7t"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!0,isDisabled:!1},"_1yep5z61mg _1yep5z61lq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61mg _1yep5z61lo"]]}),dm=_({defaultClassName:"_1j5skr77 _1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr78"},isFocusVisible:{true:"_1j5skr79"},isSelected:{true:"_1j5skr7a"},isDisabled:{true:"_1j5skr7b z9nup83 _1yep5z610e"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1},"_1j5skr7c _1yep5z61lp"],[{isSelected:!1,isDisabled:!0},"_1j5skr7d _1yep5z61lo"],[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!1,isFocusVisible:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0},"_1j5skr7e _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]});var Cx={xxs:8,xs:12,sm:16,md:20,lg:24},ge=so__default.default.forwardRef(({className:e,style:r,icon:o,size:t="md",variant:a="primary","data-block-id":i,...n},l)=>{let s=reactStately.useToggleState(n),{buttonProps:p,isPressed:d,ref:u}=Kr(n,s),{hoverProps:c,isHovered:m}=reactAria.useHover({isDisabled:n.isDisabled}),{isFocusVisible:f,isFocused:y,focusProps:g}=reactAria.useFocusRing(),v=so.useMemo(()=>typeof o=="function"?o:s.isSelected?o.selected:o.unselected,[o,s.isSelected]),b={isSelected:s.isSelected,isHovered:m,isFocusVisible:f,isDisabled:!!n.isDisabled},h=utils.filterTruthyValues({"data-hovered":m,"data-selected":s.isSelected,"data-focus-visible":f,"data-disabled":n.isDisabled,"data-block-id":i,"data-focused":y,"data-pressed":d});return jsxRuntime.jsx("button",{...reactAria.mergeProps(p,c,g,h),className:utils.classNames(a==="toolbar"&&dm(b),a==="primary"&&lm(b),a==="secondary"&&pm(b),a==="tertiary"&&cm(b),sm({size:t}),"BaselineUI-ToggleIconButton",e),style:r,ref:N(u,l),children:jsxRuntime.jsx(v,{size:Cx[t]})})});ge.displayName="ToggleIconButton";var um="f6jv6bm",fm="_1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z6j0 _1yep5z6j1 _1yep5z6j2",Ho="_1yep5z689 _1yep5z68a _1yep5z68b _1yep5z65x _1yep5z65y _1yep5z65z",ym=_({defaultClassName:"f6jv6b0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6fs",variantClassNames:{isInline:{true:"f6jv6b1"},isMinimal:{true:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6uw _1yep5z6ux _1yep5z6uy _1yep5z6142 _1yep5z6143 _1yep5z6144",false:"_1yep5z613n _1yep5z613o _1yep5z613p"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isMinimal:!1},"_1yep5z61h7 _1yep5z61h8 _1yep5z61h9 _1yep5z61hv _1yep5z61hw _1yep5z61hx _1yep5z61ij _1yep5z61ik _1yep5z61il _1yep5z61j7 _1yep5z61j8 _1yep5z61j9 _1yep5z61rv _1yep5z61rt _1yep5z61nc"]]}),Wt=_({defaultClassName:"f6jv6b4 _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6e3 _1yep5z6eu _1yep5z6ky",variantClassNames:{isDisabled:{true:"f6jv6b5 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),bm="f6jv6bj _1yep5z6vz _1yep5z6w0 _1yep5z6w1 _1yep5z6wn _1yep5z6wo _1yep5z6wp _1yep5z6xb _1yep5z6xc _1yep5z6xd _1yep5z6xz _1yep5z6y0 _1yep5z6y1",gm="f6jv6bk";var vm="f6jv6bn _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6l6 _1yep5z6l1 _1yep5z6kz _1yep5z6hc _1yep5z6eu",_m=_({defaultClassName:"f6jv6bf _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6kx",variantClassNames:{isHovered:{true:"_1yep5z6115"},isDisabled:{true:"_1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),zm="f6jv6bi _1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs _1yep5z6l0 _1yep5z6kz _1yep5z6hf _1yep5z6l3",hm="_1yep5z6j6 _1yep5z6j7 _1yep5z6j8",xm="f6jv6be f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu _1yep5z6e3 _1yep5z6kv",Cm=_({defaultClassName:"f6jv6bb _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jc _1yep5z6jd _1yep5z6je",variantClassNames:{isInline:{true:"_1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z616k _1yep5z616i _1yep5z6121",false:"_1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg"}},defaultVariants:{},compoundVariants:[]}),Pm="f6jv6bl",km="f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu",Xt=_({defaultClassName:"f6jv6b6",variantClassNames:{isInline:{true:"f6jv6b7",false:"f6jv6b8"}},defaultVariants:{},compoundVariants:[]}),Yt="f6jv6b9 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it",xr="f6jv6bo";var Rm=[["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:Cr}}=tokens.layoutSprinkleValues,Im=({isOpen:e,onClose:r})=>{let{formatMessage:o}=D(),t=reactAria.useId();return jsxRuntime.jsx(ze,{isOpen:e,onOpenChange:a=>{a||r();},children:jsxRuntime.jsx(Te,{enableDrawer:"auto",style:{zIndex:999999},children:jsxRuntime.jsxs(pe,{"aria-labelledby":t,className:bm,drawerBackground:"subtle",children:[jsxRuntime.jsxs(M,{paddingLeft:Cr.padding.horizontal.lg,paddingRight:Cr.padding.horizontal.sm,display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",backgroundColor:"background.primary.subtle",className:gm,children:[jsxRuntime.jsx(W,{id:t,elementType:"h3",type:"title",size:"md",children:o(Pr.help)}),jsxRuntime.jsx(L,{icon:_20.XIcon,size:"md",variant:"secondary","aria-label":o(Pr.close),onPress:r})]}),jsxRuntime.jsx(H,{className:Pm}),jsxRuntime.jsxs(M,{paddingX:Cr.padding.horizontal.lg,role:"table","aria-labelledby":t,backgroundColor:"background.primary.subtle",children:[jsxRuntime.jsx("div",{role:"rowgroup",children:jsxRuntime.jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Cr.padding.vertical.md,color:"text.primary",children:[jsxRuntime.jsx("h6",{className:tokens.sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",children:o(Pr.action)}),jsxRuntime.jsx("h6",{className:tokens.sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",style:{textTransform:"capitalize"},children:o(Pr.shortcut)})]})}),jsxRuntime.jsx("div",{role:"rowgroup",children:Rm.map(([a,i],n)=>jsxRuntime.jsxs(so.Fragment,{children:[jsxRuntime.jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Cr.padding.vertical.xs,style:{minHeight:40},children:[jsxRuntime.jsx(W,{type:"subtitle",size:"sm",role:"cell",children:o(Pr[lodash.camelCase(a)])}),jsxRuntime.jsx(W,{elementType:"kbd",type:"subtitle",size:"sm",role:"cell",children:utils.getOsSpecificKeyboardShortcutLabel(i,!0)})]}),n!==Rm.length-1&&jsxRuntime.jsx(H,{})]},a))})]})]})})})},Pr=A({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 Zt=so__default.default.forwardRef(({value:e,defaultValue:r,onChange:o,placeholder:t,spellCheck:a,textBoxRef:i,isInline:n,isMinimal:l,isDisabled:s,editableContentAriaLabel:p,editorHandle:d,autoFocus:u,saveOnEnter:c,onSave:m},f)=>{let y=so__default.default.useRef(null),[g,v]=utils$1.useControlledState(e,r||"",o),b=so.useCallback(I=>{v(I.currentTarget.value||"");},[v]),h=so.useCallback(I=>{(c&&I.key==="Enter"&&!I.shiftKey||(I.ctrlKey||I.metaKey)&&I.key==="Enter")&&(I.preventDefault(),m());},[c,m]);so.useImperativeHandle(f,()=>({clear:()=>{v("");}}));let z=so.useCallback(I=>{I.currentTarget.style.height="16px",I.currentTarget.style.height=I.currentTarget.scrollHeight+"px";},[]);granularHooks.useGranularLayoutEffect(()=>{let I=y.current;I&&(I.style.height="16px",I.style.height=I.scrollHeight+"px");},[l],[g]),so.useImperativeHandle(d,()=>({setCaretPosition:I=>{y.current&&(y.current.focus(),y.current.setSelectionRange(I,I));}}));let{focusProps:x,isFocused:R,isFocusVisible:C}=reactAria.useFocusRing(),{hoverProps:P,isHovered:k}=reactAria.useHover({}),T=utils.filterTruthyValues({"data-focus-visible":C,"data-hovered":k,"data-focused":R});return jsxRuntime.jsx("textarea",{...reactAria.mergeProps(x,P,T),ref:N(y,i),className:utils.classNames(l?xm:[Wt(),Xt({isInline:n}),km]),autoFocus:u,onChange:b,disabled:s,onInput:z,value:g,placeholder:t,spellCheck:a,"aria-label":p,onKeyDown:h})});Zt.displayName="PlainEditor";var Rr="mention",Qt="mention_input",Vm=so__default.default.forwardRef(({onCancel:e,editor:r,element:o,onSelectionChange:t},a)=>{let{containerRef:i,items:n,maxMentionableUsersSuggestions:l}=so.useContext(ea),s=slateReact.useSelected(),[p,d]=so.useState(""),{contains:u}=reactAria.useFilter({sensitivity:"base"}),{formatMessage:c}=D(),m=so.useMemo(()=>{let w=n.filter(S=>p===""||u(S.displayName,p)).map(S=>({id:S.id,label:S.displayName,data:S}));return l?lodash.take(w,l):w},[n,l,p,u]),f=so.useCallback(w=>jsxRuntime.jsx(reactStately.Item,{children:w.label},w.id),[]),y=so.useCallback((w=!1)=>{let S=plateCommon.findNodePath(r,o);S&&(plateCommon.removeNodes(r,{at:S}),w&&plateCommon.focusEditor(r));},[r,o]),g=reactStately.useComboBoxState({items:m,children:f,menuTrigger:"focus",onSelectionChange:w=>{y(!0),t?.(w);}}),v=so__default.default.useRef(null),b=so__default.default.useRef(null),h=so__default.default.useRef(null),z=so__default.default.useRef(null),x=plateCombobox.useHTMLInputCursorState(b);reactAria.useInteractOutside({ref:z,onInteractOutside:()=>{g.close();}});let{inputProps:R,listBoxProps:C}=reactAria.useComboBox({defaultItems:m,inputRef:b,buttonRef:v,listBoxRef:h,popoverRef:z,menuTrigger:"focus","aria-label":c(aC.mention)},g);so.useEffect(()=>{b.current?.focus();},[]);let P=so.useCallback((w="manual",S=!1)=>{y(S),e?.(w,g.inputValue);},[e,y,g.inputValue]),k=so.useRef(s);so.useEffect(()=>{k.current&&!s&&P("deselect"),k.current=s;},[s,P]);let T=x?.atStart??!1,I=x?.atEnd??!1,B=so.useCallback(w=>{w.key==="Backspace"&&T?P("backspace",!0):w.key==="Escape"?P("escape",!0):w.key==="ArrowLeft"&&T?P("arrowLeft",!0):w.key==="ArrowRight"&&I&&P("arrowRight",!0);let S=plateCommon.Hotkeys.isUndo(w)&&r.history.undos.length>0,$=plateCommon.Hotkeys.isRedo(w)&&r.history.redos.length>0;(S||$)&&(w.preventDefault(),r[S?"undo":"redo"](),plateCommon.focusEditor(r));},[T,I,P,r]),E=so.useMemo(()=>{if(!CSS.supports("field-sizing","content")){let w=Q(b.current),S=b.current?w?.getComputedStyle(b.current).font:void 0;return {width:S?utils.getTextDimensions({text:g.inputValue,font:S}).width+10:"4ch"}}},[g.inputValue]);return jsxRuntime.jsxs(Xe.Provider,{value:g,children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(R,{onKeyDown:B,onBlur:()=>{P("blur",!0);},onChange:w=>{d(w.target.value);}}),style:E,className:vm,ref:N(a,b)}),g.isOpen?jsxRuntime.jsx(ie,{triggerRef:i,className:zm,isNonModal:!0,ref:z,state:g,children:jsxRuntime.jsx(oe,{...C,items:void 0,autoFocus:"first",ref:h,className:tokens.sprinkles({width:"full"}),renderOption:jm})}):null]})});Vm.displayName="MentionInputContentElement";var Gi=cn.withRef(({className:e,...r},o)=>{let{children:t,editor:a,element:i}=r,{items:n}=so.useContext(ea),l=so.useRef(null),[s,p]=so.useState(null);so.useEffect(()=>{let c=plateCommon.findNodePath(a,i);if(!c)return;let m=plateCommon.getPointBefore(a,c);if(!m)return;let f=plateCommon.createPointRef(a,m);return p(f),()=>{f.unref();}},[a,i]);let d=so.useCallback(()=>{let c=l.current?.getRootNode()instanceof ShadowRoot;plateCommon.moveSelection(a,{unit:"offset"}),plateCommon.moveSelection(a,{unit:"character",distance:1}),Go()&&c&&plateCommon.focusEditor(a);},[a]),u=so.useCallback(c=>{if(!c)return;let m=l.current?.getRootNode()instanceof ShadowRoot,f=n.find(g=>g.id===c);utils.invariant(f,"User not found");let y={type:Rr,value:f.id,displayName:f.displayName,children:[{text:""}]};plateCommon.insertNodes(a,[y,{text:" "}]),m?setTimeout(()=>{d();},0):d();},[a,n,d]);return jsxRuntime.jsxs(plateCommon.PlateElement,{as:"span","data-slate-value":i.value,contentEditable:!1,className:e,ref:o,...r,children:[jsxRuntime.jsx(Vm,{onCancel:(c,m)=>{c!=="backspace"&&plateCommon.insertText(a,"@"+m,{at:s?.current??void 0}),(c==="arrowLeft"||c==="arrowRight")&&plateCommon.moveSelection(a,{distance:1,reverse:c==="arrowLeft"});},onSelectionChange:u,ref:l,element:i,editor:a}),t]})});Gi.displayName="MentionInputElement";var Wi=cn.withRef(({className:e,onClick:r,children:o,...t},a)=>{let i=plateCommon.useElement();return jsxRuntime.jsxs(plateCommon.PlateElement,{as:"span",className:e,contentEditable:!1,"data-user-id":i.value,onClick:plateCommon.getHandler(r,i),ref:a,...t,children:["@",i.displayName,o]})});Wi.displayName="MentionElement";var Am=(e,{options:{trigger:r,triggerPreviousCharPattern:o,triggerQuery:t}})=>{let{insertText:a}=e,i=n=>n===r;return e.insertText=n=>{if(!e.selection||!i(n)||t&&!t(e)){a(n);return}let l=plateCommon.getEditorString(e,plateCommon.getRange(e,e.selection,plateCommon.getPointBefore(e,e.selection)));if(o?.test(l)){Jt(e);return}a(n);},e},aC=A({mention:{defaultMessage:"Mention",id:"mention"}});function Um({className:e,children:r,...o}){return jsxRuntime.jsx(plateCommon.PlateElement,{asChild:!0,className:e,...o,children:jsxRuntime.jsx("p",{children:r})})}function zC(e){return Object.entries(e).map(([r,o])=>`${lodash.kebabCase(r)}:${o}`).filter(([,r])=>!!r).join(";")}function hC(e){return "text"in e}function Ir(e){if(!e)return "";function r(o){if(hC(o)){let a=o.text;return o.bold&&(a=`<b>${a}</b>`),o.italic&&(a=`<i>${a}</i>`),o.underline&&(a=`<u>${a}</u>`),(o.color||o.backgroundColor)&&(a=`<span style="${zC(utils.filterTruthyValues({color:o.color||void 0,backgroundColor:o.backgroundColor||void 0}))}">${a}</span>`),a}let t=o.children?.map(Ir).join("");switch(o.type){case plateParagraph.ELEMENT_PARAGRAPH:return `<p>${t}</p>`;case plateLink.ELEMENT_LINK:return `<a href="${o.url}">${t}</a>`;case Rr:return `<span data-user-id="${o.value}">${o.displayName}</span>`;default:return t}}return Array.isArray(e)?e.map(o=>r(o)).join(""):r(e)}function xC(e){return e?(e=e.trim(),e.endsWith(";")&&(e=e.slice(0,-1)),Object.fromEntries(e.split(";").map(r=>r.split(":").map(o=>o.trim())).map(([r,o])=>[lodash.camelCase(r),o]))):{}}function Ji(e){e.startsWith("<p>")||(e=`<p>${e}</p>`);let r=new DOMParser().parseFromString(qm__namespace.default.sanitize(e),"text/html"),o=r.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 t=r.querySelectorAll("br");for(let a of t)a.outerHTML=a.closest("p")?`
80
- `:"<p>";return Gm(r.body)}function Gm(e,r){if(e.nodeType===Node.TEXT_NODE)return slateHyperscript.jsx("text",r,e.textContent);if(e.nodeType!==Node.ELEMENT_NODE)return null;let o={...r};switch(e.nodeName.toUpperCase()){case"B":{o.bold=!0;break}case"I":{o.italic=!0;break}case"EM":{o.italic=!0;break}case"U":{o.underline=!0;break}case"SPAN":{let a=xC(e.getAttribute("style")||"");a["text-decoration"]==="underline"&&(o.underline=!0),a.color&&(o.color=a.color),a.backgroundColor&&(o.backgroundColor=a.backgroundColor);break}}let t=[...e.childNodes].flatMap(a=>Gm(a,o));switch(t.length===0&&t.push(slateHyperscript.jsx("text",o,"")),e.nodeName.toUpperCase()){case"BR":return slateHyperscript.jsx("text",r,`
81
- `);case"SPAN":{let a=e.dataset.userId;return a?slateHyperscript.jsx("element",{type:Rr,value:a,displayName:e.textContent},{text:""}):t}case"P":return slateHyperscript.jsx("element",{type:plateParagraph.ELEMENT_PARAGRAPH},t);case"A":return slateHyperscript.jsx("element",{type:plateLink.ELEMENT_LINK,url:e.getAttribute("href")},t);default:return t}}function Wm(e){let r=plateCommon.findNode(e,{match:{type:plateCommon.getPluginType(e,plateLink.ELEMENT_LINK)}}),[o]=r||[{url:""}];return o?.url}function Jt(e){let r={children:[{text:" "}],type:Qt};e.insertNode(r);}var CC=plateCommon.createPluginFactory({isElement:!0,isInline:!0,isMarkableVoid:!0,isVoid:!0,key:Rr,options:{trigger:"@",triggerPreviousCharPattern:/^$|^[\s"']$/},plugins:[{isElement:!0,isInline:!0,isVoid:!0,key:Qt}],withOverrides:Am}),Xm=plateCommon.createPlugins([plateParagraph.createParagraphPlugin({component:Um}),plateBasicMarks.createBoldPlugin({component:cn.withProps(plateCommon.PlateLeaf,{as:"b"})}),plateBasicMarks.createItalicPlugin({component:cn.withProps(plateCommon.PlateLeaf,{as:"i"})}),plateBasicMarks.createUnderlinePlugin({component:cn.withProps(plateCommon.PlateLeaf,{as:"u"})}),plateFont.createFontColorPlugin(),plateFont.createFontBackgroundColorPlugin(),plateLink.createLinkPlugin({component:Ym}),CC({component:Wi})],{components:{[Qt]:Gi}});var eu=({isDisabled:e})=>{let{formatMessage:r}=D(),o=plateCommon.useEditorRef();return jsxRuntime.jsx(Ye,{type:"dialog",children:({close:t})=>jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Ze,{children:jsxRuntime.jsx(L,{icon:_20.LinkIcon,size:"sm",isDisabled:e,"aria-label":r(to.addLink),className:Ho,preventFocusOnPress:!0})}),jsxRuntime.jsx(Ue,{className:tokens.sprinkles({boxShadow:"medium"}),placement:"top end",children:jsxRuntime.jsx(pe,{size:"content",style:{minWidth:240},children:jsxRuntime.jsx(SC,{close:()=>{t(),setTimeout(()=>{plateCommon.focusEditor(o,o.selection);},0);}})})})]})})},SC=({close:e})=>{let r=plateCommon.useEditorRef(),{formatMessage:o}=D(),t=plateCommon.useEditorSelector(p=>Wm(p),[]),[a,i]=so__default.default.useState(t?"show":"add"),[n,l]=so__default.default.useState(t||""),s=jsxRuntime.jsx(M,{padding:"lg",children:jsxRuntime.jsx(ko,{label:o(to.link),value:n,autoFocus:!0,onChange:l,placeholder:"https://yourdomain.com"})});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[a==="add"&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[s,jsxRuntime.jsx(M,{display:"flex",justifyContent:"flex-end",padding:"lg",className:um,children:jsxRuntime.jsx(O,{isDisabled:!utils.isUrl(n,!0),label:o(to.addLink),size:"sm",onPress:()=>{plateLink.upsertLink(r,{url:n,skipValidation:!0}),e?.();},preventFocusOnPress:!0})})]}),a==="show"&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(M,{padding:"lg",children:jsxRuntime.jsx(W,{type:"subtitle",size:"sm",children:t})}),jsxRuntime.jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsxRuntime.jsx(O,{label:o(to.editLink),size:"sm",variant:"secondary",onPress:()=>{i("edit");},style:{flex:1,justifyContent:"center"}}),jsxRuntime.jsx(O,{label:o(to.removeLink),size:"sm",onPress:()=>{plateLink.unwrapLink(r),e?.();},preventFocusOnPress:!0,style:{flex:1,justifyContent:"center"}})]})]}),a==="edit"&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[s,jsxRuntime.jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsxRuntime.jsx(O,{label:o(to.cancel),size:"sm",variant:"secondary",onPress:()=>{i("show"),e?.();}}),jsxRuntime.jsx(O,{label:o(to.save),size:"sm",onPress:()=>{plateLink.upsertLink(r,{url:n,skipValidation:!0}),e?.();}})]})]})]})};function Ym({className:e,children:r,...o}){return jsxRuntime.jsx(plateCommon.PlateElement,{asChild:!0,className:e,...o,children:jsxRuntime.jsx("a",{className:pt({size:"sm"}),children:r})})}var to=A({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 MC=color.parseColor("#ffffff00").toString("hexa"),en=[{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"}];[...en,{label:"Transparent",color:MC}];var oa=({nodeType:e,icon:r,ariaLabel:o,isDisabled:t})=>{let a=plateCommon.useEditorSelector(n=>plateCommon.isMarkActive(n,e),[]),i=plateCommon.useEditorRef();return jsxRuntime.jsx(ge,{variant:"tertiary",isSelected:a,size:"sm",icon:r,"aria-label":o,isDisabled:t,onPress:()=>{plateCommon.toggleMark(i,{key:e});},preventFocusOnPress:!0})},rn=({nodeType:e,"aria-label":r,isDisabled:o})=>{let{updateColor:t,clearColor:a,color:i}=plateFont.useColorDropdownMenuState({customColors:[],colors:[],nodeType:e}),n=so.useCallback(({ref:s,triggerProps:p})=>jsxRuntime.jsx(L,{icon:e==="color"?_24.TextIcon:_24.HighlightTextIcon,"aria-label":r,size:"md",variant:"popover",isDisabled:o,className:Ho,preventFocusOnPress:!0,...p,ref:s}),[e,r,o]),l=so.useCallback(s=>{s?t(s.toString("rgba")):a();},[a,t]);return jsxRuntime.jsx(Do,{presets:en,allowRemoval:!0,pickerMode:"lazy",placement:"top end",colorLabel:!1,renderTriggerButton:n,value:i||"#000000",onChange:l,isDisabled:o})};var pP=[{type:plateParagraph.ELEMENT_PARAGRAPH,children:[{text:""}]}],ea=so__default.default.createContext({items:[],containerRef:{current:null},maxMentionableUsersSuggestions:10}),an=so__default.default.forwardRef(({value:e,defaultValue:r,onChange:o,style:t,spellCheck:a,placeholder:i,isInline:n,isDisabled:l,editableContentAriaLabel:s,containerRef:p,onHelpDialogOpenRequest:d,mentionableUsers:u,editorHandle:c,maxMentionableUsersSuggestions:m,autoFocus:f,editorRef:y,saveOnEnter:g,onSave:v},b)=>{let h=so.useRef(null),z=reactAria.useId(),{formatMessage:x}=D(),R=so.useRef(null),C=R.current,P=so.useRef(null),k=so.useMemo(()=>C?.getRootNode()instanceof ShadowRoot,[C]),[T,I]=utils$1.useControlledState(e?Ji(e):void 0,Ji(r||"<p></p>"),w=>{o&&o(Ir(w));}),{keyboardProps:B}=reactAria.useKeyboard({onKeyDown:w=>{(g&&w.key==="Enter"&&!w.shiftKey||(w.ctrlKey||w.metaKey)&&w.key==="Enter")&&(w.preventDefault(),v()),w.altKey&&w.key==="F10"?(w.preventDefault(),h.current&&h.current.querySelector("button")?.focus()):w.continuePropagation(),Go()&&k&&P.current&&plateCommon.focusEditor(P.current);}});so.useEffect(()=>{l&&P.current&&plateCommon.deselect(P.current);},[l]),so.useImperativeHandle(b,()=>({startMention:()=>{P.current&&Jt(P.current);}})),so.useImperativeHandle(c,()=>({setCaretPosition:w=>{P.current&&(plateCommon.focusEditor(P.current),plateCommon.moveSelection(P.current,{distance:w,unit:"character"}));}}));let E=so.useMemo(()=>({items:u||[],containerRef:p,maxMentionableUsersSuggestions:m}),[u,p,m]);return jsxRuntime.jsx(ea.Provider,{value:E,children:jsxRuntime.jsxs(plateCommon.Plate,{initialValue:T||pP,plugins:Xm,editorRef:N(P,y||null),onChange:w=>{I(w);},children:[jsxRuntime.jsxs(Gt,{className:Yt,"aria-controls":z,ref:h,children:[jsxRuntime.jsxs(M,{display:"flex",flexDirection:"row",role:"group",gap:"xs",paddingX:"sm",children:[jsxRuntime.jsx(oa,{nodeType:plateBasicMarks.MARK_BOLD,icon:_20.BoldIcon,ariaLabel:x(jo.bold),isDisabled:l}),jsxRuntime.jsx(oa,{nodeType:plateBasicMarks.MARK_ITALIC,icon:_20.ItalicIcon,ariaLabel:x(jo.italic),isDisabled:l}),jsxRuntime.jsx(oa,{nodeType:plateBasicMarks.MARK_UNDERLINE,icon:_20.UnderlineIcon,ariaLabel:x(jo.underline),isDisabled:l})]}),jsxRuntime.jsx(H,{orientation:"vertical",className:xr}),jsxRuntime.jsx(rn,{nodeType:plateFont.MARK_COLOR,"aria-label":x(jo.fontColor),isDisabled:l}),jsxRuntime.jsx(H,{orientation:"vertical",className:xr}),jsxRuntime.jsx(rn,{nodeType:plateFont.MARK_BG_COLOR,"aria-label":x(jo.backgroundColor),isDisabled:l}),jsxRuntime.jsx(H,{orientation:"vertical",className:xr}),jsxRuntime.jsx(eu,{isDisabled:l}),jsxRuntime.jsx(H,{orientation:"vertical",className:xr}),jsxRuntime.jsx(L,{className:Ho,icon:_24.QuestionmarkCircleIcon,size:"sm","aria-label":x(jo.help),onPress:d})]}),jsxRuntime.jsx(H,{variant:"secondary"}),jsxRuntime.jsx("div",{...B,ref:R,children:jsxRuntime.jsx(plateCommon.PlateContent,{id:z,disabled:l,readOnly:l,style:t,placeholder:i,autoFocus:f,spellCheck:a,"aria-label":s,className:utils.classNames(Wt({isDisabled:l}),Xt({isInline:n})),renderPlaceholder:({attributes:w,children:S})=>jsxRuntime.jsx("span",{...w,className:tokens.sprinkles({paddingY:"lg"}),children:S})})})]})})});an.displayName="RichEditor";var jm=({key:e,value:r},{isDisabled:o,optionProps:t,isFocused:a,_state:i},n)=>{let{hoverProps:l}=reactAria.useHover({isDisabled:o}),{label:s,data:p}=r;return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("li",{...reactAria.mergeProps(t,l),className:_m({isDisabled:o,isHovered:a}),"data-active":a,ref:n,children:[jsxRuntime.jsx(So,{name:s,...p?.avatar}),jsxRuntime.jsxs(M,{display:"flex",flexDirection:"column",children:[jsxRuntime.jsx(W,{type:"subtitle",size:"sm",children:s}),jsxRuntime.jsx(W,{type:"helper",size:"sm",children:p?.description})]})]}),e===i.collection.getLastKey()?null:jsxRuntime.jsx(H,{})]})},jo=A({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 su=so__default.default.memo(so__default.default.forwardRef(({className:e,style:r,"data-block-id":o,enableRichText:t=!1,onCancel:a,onSave:i,isInline:n=!0,submitButtonIcon:l=_20.ArrowUpCircleFilledIcon,submitButtonAriaLabel:s,cancelButtonAriaLabel:p,"aria-label":d,"aria-describedby":u,"aria-labelledby":c,"aria-details":m,editableContentAriaLabel:f="Editing Area",footerButtons:y,clearOnCancel:g,clearOnSave:v,...b},h)=>{let z=so.useRef(null),{formatMessage:x}=D(),R=so.useRef(null),C=so.useRef(null),P=so.useRef(null),k=!t&&b.variant==="minimal",T=so.useRef(null),[I,B]=so__default.default.useState(b.value||b.defaultValue),E=b.isDisabled||b.isSaveDisabled||!utils.getPlainText(I||""),{fieldProps:w}=reactAria.useLabel({"aria-label":d,"aria-labelledby":c,"aria-describedby":u,"aria-details":m,labelElementType:"div"});k&&!b.avatarName&&console.warn("Editor: When using the minimal `variant` and `enableRichText` is `false`, you should provide an `avatarName`.");let S=so.useCallback(()=>{B(""),t?z.current?.reset():C.current?.clear();},[t]),$=so.useCallback(()=>{E||(i?.(t?Ir(z.current?.children):R.current.value),v&&S());},[S,v,t,i,E]),re=jsxRuntime.jsx(L,{variant:"ghost","aria-label":s||x(sn.save),icon:l,isDisabled:E,size:"md",excludeFromTabOrder:k,className:k?hm:void 0,onPress:$,preventFocusOnPress:!0}),[ne,X]=so__default.default.useState(!1),{keyboardProps:K}=reactAria.useKeyboard({onKeyDown:V=>{(V.metaKey||V.ctrlKey)&&V.shiftKey&&V.key==="h"&&(V.preventDefault(),X(!0));}}),G=so.useCallback(V=>{B(V),b.onChange?.(V);},[b]);return jsxRuntime.jsxs("div",{...reactAria.mergeProps(w,t?K:{}),role:"application",ref:N(P,h),style:r,"data-block-id":o,className:utils.classNames(ym({isInline:n,isMinimal:k}),"BaselineUI-Editor",e),"aria-disabled":b.isDisabled,children:[k?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[n?jsxRuntime.jsx(So,{className:fm,name:b.avatarName||""}):null,jsxRuntime.jsxs("div",{className:Cm({isInline:n}),children:[jsxRuntime.jsx(Zt,{isMinimal:k,textBoxRef:R,isInline:n,editableContentAriaLabel:f,...b,onChange:G,onSave:$}),re]})]}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[t?jsxRuntime.jsx(an,{containerRef:P,ref:T,editorRef:z,isInline:n,editableContentAriaLabel:f,onHelpDialogOpenRequest:()=>{X(!0);},...b,onChange:G,onSave:$}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[!n&&jsxRuntime.jsx(H,{variant:"secondary"}),jsxRuntime.jsx(Zt,{onCancel:a,textBoxRef:R,ref:C,isInline:n,editableContentAriaLabel:f,...b,onChange:V=>{B(V),b.onChange?.(V);},onSave:$})]}),jsxRuntime.jsx(H,{variant:"secondary"}),jsxRuntime.jsxs("div",{className:utils.classNames(Yt,tokens.sprinkles({justifyContent:"space-between"})),children:[jsxRuntime.jsxs(M,{paddingX:"sm",gap:"sm",display:"flex",children:[t&&b.mentionableUsers?jsxRuntime.jsx(L,{icon:_20.AtIcon,size:"sm","aria-label":x(sn.mention),onPress:()=>T.current?.startMention(),preventFocusOnPress:!0}):null,y?.map(({type:V,props:Z},ee)=>V==="action"?jsxRuntime.jsx(L,{...Z,size:"sm",isDisabled:b.isDisabled||Z.isDisabled},ee):jsxRuntime.jsx(ge,{...Z,size:"sm",variant:"tertiary",isDisabled:b.isDisabled||Z.isDisabled},ee))]}),jsxRuntime.jsxs(M,{children:[!!a&&jsxRuntime.jsx(L,{variant:"secondary",icon:_20.CrossCircleFilledIcon,isDisabled:b.isDisabled,size:"md",onPress:()=>{a(),g&&S();},"aria-label":p||x(sn.cancel)}),re]})]})]}),jsxRuntime.jsx(Im,{isOpen:ne,onClose:()=>{X(!1);}})]})}));su.displayName="Editor";var sn=A({cancel:{defaultMessage:"Cancel",id:"cancel"},save:{defaultMessage:"Save",id:"save"},mention:{defaultMessage:"Mention",id:"mention"}});var ta=so__default.default.forwardRef(({className:e,style:r,"data-block-id":o,isMounted:t,children:a,transitions:i,elementType:n="div",...l},s)=>{let p=web.useTransition(t,i),d=web.animated[n];return p((u,c)=>c&&jsxRuntime.jsx(d,{className:e,"data-block-id":o,style:{...r,...u},...l,ref:s,children:a}))});ta.displayName="Transition";var lu="_8kqf970 _1yep5z6ow _1yep5z6ox _1yep5z6oy _1yep5z613b _1yep5z613c _1yep5z613d _1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6142 _1yep5z6143 _1yep5z6144 _1yep5z6yh _1yep5z6uq _1yep5z6ur _1yep5z6us _1yep5z6168";var cu=2,du=so__default.default.forwardRef(({className:e,style:r,hideForKeyboard:o,scrollRef:t,label:a,delay:i=1500,smoothScroll:n=!0,"data-block-id":l},s)=>{let p=so__default.default.useRef(null),d=interactions.useInteractionModality(),[u,c]=so__default.default.useState(!1),m=so.useCallback(()=>{let k=t?.current||ye(p.current).body;return Q(k).getComputedStyle(k).flexDirection==="column-reverse"?k.scrollTop+cu>=0:k.scrollTop+k.clientHeight+cu>=k.scrollHeight},[t]),[f,y]=so__default.default.useState(m),g=Fe(),{buttonProps:v,isPressed:b}=reactAria.useButton({onPress:()=>{let k=t?.current||ye(p.current).body;k.scrollTo({top:k.scrollHeight,behavior:n?"smooth":"auto"});}},p),{focusProps:h,isFocused:z,isFocusVisible:x}=reactAria.useFocusRing(),{hoverProps:R,isHovered:C}=reactAria.useHover({}),P=utils.filterTruthyValues({"data-block-id":l,"data-pressed":b,"data-focus-visible":x,"data-hovered":C,"data-focused":z});return so.useEffect(()=>{y(m());},[m]),so.useEffect(()=>{let k=t?.current||ye(p.current).body,T="onscrollend"in Q(k),I=()=>{setTimeout(()=>{c(!1),y(m());},i);},B=()=>{c(!0),T||I();};return k.addEventListener("scroll",B),k.addEventListener("scrollend",I),()=>{k.removeEventListener("scroll",B),k.removeEventListener("scrollend",I);}},[t,i,m]),jsxRuntime.jsxs(ta,{isMounted:(o?d!=="keyboard":!0)&&!u&&!f,elementType:"button",transitions:{from:{opacity:0,transform:"translateX(-50%) translateY(10px)"},enter:{opacity:1,transform:"translateX(-50%) translateY(0)"},leave:{opacity:0,transform:"translateX(-50%) translateY(10px)"},immediate:g},...reactAria.mergeProps(v,h,R,P),className:utils.classNames(lu,ft({isFocusVisible:x,variant:"high-contrast",isHovered:C}),"BaselineUI-ScrollControlButton",e),style:r,ref:N(s,p),children:[jsxRuntime.jsx(_16.ArrowDownCircleFilledIcon,{size:16}),a]})});du.displayName="ScrollControlButton";var pn="_1yep5z6jc _1yep5z6jd _1yep5z6je _1yep5z6jl _1yep5z6jm _1yep5z6jn",mu=_({defaultClassName:"_1v0p2z10 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",variantClassNames:{hasTitleAndIcon:{true:"_1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nw _1yep5z6nx _1yep5z6ny"},hasNoCloseBtn:{true:"_1yep5z6lk _1yep5z6ll _1yep5z6lm _1yep5z6nw _1yep5z6nx _1yep5z6ny _1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6mq _1yep5z6mr _1yep5z6ms"}},defaultVariants:{},compoundVariants:[[{hasTitleAndIcon:!0,hasNoCloseBtn:!0},"_1yep5z61g7 _1yep5z61g8 _1yep5z61g9"]]}),uu="_1v0p2z10";var ia=so__default.default.forwardRef(({className:e,style:r,"data-block-id":o,message:t,title:a,primaryActionLabel:i,cancelLabel:n,textInputProps:l,icon:s,iconColor:p,showCloseButton:d=!0,onPrimaryAction:u,onCancel:c,autoFocusButton:m,isPrimaryActionDisabled:f},y)=>{let g=reactAria.useId(),{formatMessage:v}=D(),b=a&&jsxRuntime.jsx(W,{id:g,type:"title",size:"sm",elementType:"h3",children:a});return jsxRuntime.jsxs(pe,{className:e,style:r,"data-block-id":o,size:"sm",variant:"primary",role:"alertdialog",ref:y,"aria-labelledby":g,children:[jsxRuntime.jsxs("div",{className:mu({hasTitleAndIcon:!!(s&&a),hasNoCloseBtn:!d}),children:[jsxRuntime.jsxs(M,{display:"flex",justifyContent:"space-between",alignItems:"center",flexDirection:"row",children:[s?jsxRuntime.jsx(s,{style:{color:p},size:24}):null,!s&&b,d?jsxRuntime.jsx(L,{icon:_20.XIcon,variant:"secondary",size:"md","aria-label":v(FP.close),onPress:c}):null]}),s?b:null]}),t?jsxRuntime.jsx(M,{elementType:"section",className:uu,paddingX:"lg",paddingBottom:"lg",typography:"body.sm.regular",color:"text.primary",children:t}):null,l?jsxRuntime.jsx(M,{paddingX:"lg",paddingBottom:"lg",children:jsxRuntime.jsx(ko,{...l})}):null,n||i?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(H,{}),jsxRuntime.jsxs(M,{padding:"lg",display:"flex",gap:"xl",children:[n?jsxRuntime.jsx(O,{variant:"secondary",className:pn,label:n,onPress:c,autoFocus:m==="cancel"}):null,i?jsxRuntime.jsx(O,{className:pn,label:i,onPress:u,autoFocus:m==="primary",isDisabled:f}):null]})]}):null]})});ia.displayName="AlertDialog";var FP=A({close:{id:"close",defaultMessage:"Close",description:"Close button label"}});var fu="_1t55bp71",yu="_1yep5z6e3 _1yep5z6eu _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69i _1yep5z69j _1yep5z69k",bu="_1t55bp70";var $P=jP__default.default(),gu=so__default.default.forwardRef(({className:e,style:r,children:o,"data-block-id":t,showCaret:a},i)=>{let n=so.useMemo(()=>{let l=o;return (!o||Array.isArray(o)&&o.length===0)&&(l=""),$P.render(l)},[o]);return jsxRuntime.jsx("div",{className:utils.classNames(yu,bu,{[fu]:a},"BaselineUI-Markdown",e),"data-block-id":t,style:r,ref:i,dangerouslySetInnerHTML:{__html:n}})});gu.displayName="Markdown";function hu(e){let{formatMessage:r,locale:o}=D(),[t,a]=so__default.default.useState(!1),[i,n]=so__default.default.useState(0),[l,s]=so__default.default.useState(0),[p,d]=so__default.default.useState(!1);so.useEffect(()=>{if(!e.current)return;let m=e.current,f=()=>{a(!1),n(0);},y=()=>{p||n(m.currentTime*100/m.duration);},g=()=>{s(m.duration);};return m.addEventListener("ended",f),m.addEventListener("timeupdate",y),m.addEventListener("loadedmetadata",g),()=>{m.removeEventListener("ended",f),m.removeEventListener("timeupdate",y),m.removeEventListener("loadedmetadata",g);}},[p,e]);let u=so.useCallback(()=>{(async()=>e.current&&(e.current.paused?(await e.current.play(),a(!0),liveAnnouncer.announce(r(_u.playing),"polite")):(e.current.pause(),a(!1),liveAnnouncer.announce(r(_u.paused),"polite"))))();},[r,e]),c=so.useCallback(m=>{e.current&&(e.current.currentTime=m*e.current.duration/100,liveAnnouncer.announce(KP(e.current.currentTime,o.locale),"assertive"));},[o.locale,e]);return {isPlaying:t,progress:i,duration:l,togglePlay:u,seek:c,setProgress:n,formattedCurrentTime:e.current?.currentTime?zu(e.current?.currentTime):"00:00",formattedDuration:l?zu(l):"00:00",setIsSliderDragging:d}}var _u=A({playing:{id:"playing",defaultMessage:"Playing"},paused:{id:"paused",defaultMessage:"Paused"}});function KP(e,r){let o=Math.floor(e/3600),t=Math.floor(e%3600/60),a=e%60,i={...o&&{hours:o},...t&&{minutes:t},seconds:Math.floor(a)};return new Intl.DurationFormat(r,{style:"long"}).format(i)}function zu(e){let r=Math.floor(e%3600/60),o=Math.floor(e%60);return [r,o].map(t=>t.toString().padStart(2,"0")).join(":")}var xu="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q",Cu="rta2n91 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6z9 _1yep5z6ut _1yep5z6uu _1yep5z6uv _1yep5z6166 _1yep5z6106",Pu="rta2n90";var Ru=so__default.default.forwardRef(({className:e,style:r,size:o="lg",sources:t,"data-block-id":a,...i},n)=>{let l=so__default.default.useRef(null),{isPlaying:s,progress:p,duration:d,togglePlay:u,seek:c,formattedDuration:m,formattedCurrentTime:f,setProgress:y,setIsSliderDragging:g}=hu(l),{formatMessage:v}=D(),b=utils.filterTruthyValues({"data-block-id":a,"data-state":s?"playing":"paused","data-loaded":d>0});return jsxRuntime.jsxs("div",{...b,...i,className:utils.classNames(xu,"BaselineUI-AudioPlayer",e),role:"group",style:r,ref:n,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("audio",{ref:l,children:t.map(({url:h,type:z})=>jsxRuntime.jsx("source",{src:h,type:z},h))})}),jsxRuntime.jsx(ge,{icon:s?_24.PauseIcon:_24.PlayIcon,variant:"toolbar",isSelected:s,size:o,"aria-label":v(s?dn.pause:dn.play),style:{borderRadius:"50%"},onPress:u}),jsxRuntime.jsxs("div",{className:Cu,children:[jsxRuntime.jsx("span",{"aria-hidden":!0,children:f}),jsxRuntime.jsx(Qr,{"aria-label":v(dn.audioTimeline),value:p,minValue:0,maxValue:100,className:Pu,onChange:h=>{y(h),g(!0);},onChangeEnd:h=>{c(h),g(!1);}}),jsxRuntime.jsx("span",{"aria-hidden":!0,children:m})]})]})});Ru.displayName="AudioPlayer";var dn=A({play:{id:"play",defaultMessage:"Play"},pause:{id:"pause",defaultMessage:"Pause"},audioTimeline:{id:"audioTimeline",defaultMessage:"Audio timeline"}});var Iu="_1w920rnf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6ho _1yep5z6hp _1yep5z6hq",Tu="_1w920rn1 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k",Nu="_1w920rn0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6km",Lr=_({defaultClassName:"_1w920rn2 _1yep5z6d6 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{isFocusVisible:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isLoading:{true:"_1yep5z614w _1yep5z614x _1yep5z614y"},imageWidth:{sm:"_1w920rn6",md:"_1w920rn7"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rn8 _1yep5z6l1 _1yep5z6kz _1yep5z6hc"]]}),Su="_1w920rnd _1yep5z6kw",Lu=_({defaultClassName:"_1w920rn9 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6fw _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocusVisible:{true:"_1w920rna _1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1w920rnb"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rnc _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]}),Mu="_1w920rne";var Du=({items:e,ulRef:r})=>{let{length:o}=e,t=so__default.default.useRef(null);return so.useLayoutEffect(()=>{if(!t.current)return;let a=t.current.closest(".BaselineUI-ImageGallery")?.querySelector(`[data-image-key='${e?.at(-1)?.key}']`)?.cloneNode(!0);utils.invariant(a,"Node is not defined."),t.current?.prepend(a);},[e,r]),jsxRuntime.jsx("div",{className:Lr(),ref:t,children:jsxRuntime.jsx(M,{backgroundColor:"background.secondary.medium",borderRadius:"full",typography:"label.md.medium",color:"text.primary",position:"absolute",paddingX:"md",className:Mu,children:o})})};var Fu=({item:{value:e},options:{optionProps:r,isFocusVisible:o,isSelected:t},liRef:a,fit:i="contain",imageWidth:n=102,onDelete:l,aspectRatio:s})=>{let p=reactAria.useId(),{formatMessage:d}=D();utils.invariant(e&&(e?.type==="option"||e?.type===void 0));let{imgProps:u,isLoading:c,isLoaded:m}=bo({src:e.data?.src,alt:e.data?.alt??""}),f=web.useTransition(m,{from:{opacity:0},enter:{opacity:1},leave:{opacity:0}}),y=lodash.isNumber(n)?void 0:Lr({imageWidth:n}),g=lodash.isNumber(n)?{width:n}:void 0;return jsxRuntime.jsxs("li",{...r,ref:a,className:Tu,"aria-labelledby":p,children:[jsxRuntime.jsx("div",{className:utils.classNames(Lr({isFocusVisible:o,isSelected:t,isLoading:!0}),y),style:{aspectRatio:s?.toString(),...g},"data-image-key":e.id,children:c?jsxRuntime.jsx(Io,{"aria-label":d(Mr.loading)}):f((v,b)=>b&&jsxRuntime.jsx(web.animated.div,{role:"img","aria-label":u.alt,style:{...v,backgroundImage:`url(${u.src})`,backgroundSize:i},className:Su,children:l?jsxRuntime.jsx("div",{className:Iu,children:jsxRuntime.jsx(L,{"aria-label":d(Mr.delete),size:"xs",icon:_12.XIcon,onPress:()=>{l(e.id);},UNSAFE_NON_INTERACTIVE:!0})}):null}))}),jsxRuntime.jsx("span",{id:p,className:Lu({isFocusVisible:o,isSelected:t}),children:e.label})]})};var f0={width:0,display:"block"};var y0=so__default.default.createContext(null),un=so__default.default.forwardRef(({className:e,style:r,fit:o="cover",onReorder:t,"data-block-id":a,onDelete:i,imageWidth:n="sm",aspectRatio:l=3/4,list:s,onKeyDown:p,...d},u)=>{let c=so__default.default.useRef(null),[m,f]=so.useState([]),{formatMessage:y}=D(),g=so.useCallback(z=>{z.target.dropPosition==="before"?s.moveBefore(z.target.key,z.keys):z.target.dropPosition==="after"&&s.moveAfter(z.target.key,z.keys),t?.(z);},[s,t]),v=so.useCallback(()=>{i&&m.length&&(s.remove(...m),i(new Set(m)),f([]));},[m,s,i]),b=so.useCallback((z,x,R)=>jsxRuntime.jsx(Fu,{item:z,options:x,liRef:R,fit:o,imageWidth:n,aspectRatio:l,onDelete:i?C=>{f([C]);}:void 0}),[l,o,i,n]),{keyboardProps:h}=reactAria.useKeyboard({onKeyDown(z){if(p?.(z),z.key==="Backspace"||z.key==="Delete"){if(!i)return;if([...s.selectedKeys].length)f([...s.selectedKeys]);else {let R=s.getItem(z.target.dataset.key).id;f([R]);}}}});return jsxRuntime.jsxs("div",{...h,ref:u,style:r,className:utils.classNames("BaselineUI-ImageGallery",e),"data-block-id":a,children:[jsxRuntime.jsx(oe,{...d,items:s.items,onReorder:g,layout:"grid",orientation:"vertical",className:Nu,ref:c,dropIndicatorStyle:f0,renderOption:b,renderDragPreview:z=>jsxRuntime.jsx(Du,{items:z,ulRef:c}),onSelectionChange:s.setSelectedKeys,getItems:z=>[...z].map(x=>({src:s.getItem(x).src||"",alt:s.getItem(x).alt||"",key:x}))}),jsxRuntime.jsx(ze,{isOpen:!![...m].length,onOpenChange:z=>{z||f([]);},children:jsxRuntime.jsx(Te,{isDismissable:!0,children:jsxRuntime.jsx(ia,{showCloseButton:!1,title:"Are you sure you want to delete this item?",primaryActionLabel:y(Mr.delete),cancelLabel:y(Mr.cancel),onCancel:()=>{f([]);},onPrimaryAction:v,autoFocusButton:"cancel"})})})]})});un.displayName="ImageGalleryCore";var Hu=so__default.default.forwardRef((e,r)=>{let{items:o=[],onListChange:t,onSelectionChange:a}=e,i=As({initialItems:o.map(n=>({id:n.id,label:n.label,data:{src:n.src,alt:n.alt}})),onListChange:t,onSelectionChange:a});return jsxRuntime.jsx(un,{...e,ref:r,list:i})});Hu.displayName="ImageGalleryStandalone";var Ou=so__default.default.forwardRef((e,r)=>{let o=so.useContext(y0);return so.useEffect(()=>{utils.invariant(o||e.items,"ImageGallery: A `state` that can be passed via context or `items` are required.");},[e.items,o]),o?jsxRuntime.jsx(un,{...e,ref:r,list:o}):jsxRuntime.jsx(Hu,{...e,ref:r})});Ou.displayName="ImageGallery";var Mr=A({delete:{id:"delete",defaultMessage:"Delete"},cancel:{id:"cancel",defaultMessage:"Cancel"},loading:{id:"loading",defaultMessage:"Loading"}});var Vu="_1sexph00",Au="_1sexph01 _1yep5z616p _1yep5z616q _1yep5z616r _1yep5z6191 _1yep5z6192 _1yep5z6193 _1yep5z61a7 _1yep5z61a8 _1yep5z61a9 _1yep5z617v _1yep5z617w _1yep5z617x _1yep5z61q4 _1yep5z61q5 _1yep5z61q6";var $u=so__default.default.forwardRef(({className:e,style:r,items:o,"data-block-id":t,hideLabel:a,size:i="md",isDisabled:n,showSelectedIcon:l=!0,excludeFromTabOrder:s,...p},d)=>{let u=ae(),c=reactStately.useSelectState({items:o,...p,children:u,validationState:p.validationState==="error"?"invalid":"valid",onSelectionChange:x=>{x&&f(x),p.onSelectionChange?.(x);}}),[m,f]=so.useState(c.selectedKey||c.collection.getFirstKey()),y=so.useMemo(()=>c.collection.getItem(m),[m,c.collection]),{hoverProps:g,isHovered:v}=reactAria.useHover({isDisabled:n}),b=so.useMemo(()=>{let x=y.textValue||y["aria-label"],R=y.value.icon,C=m===c.selectedKey,k={size:i,isSelected:C,onPress:()=>{c.setSelectedKey(C?null:m);},isDisabled:n,excludeFromTabOrder:s};return a&&R?jsxRuntime.jsx(ge,{icon:R,"aria-label":x,variant:"toolbar",...k}):jsxRuntime.jsx(mt,{iconStart:R,label:x,...k})},[m,y,s,a,n,v,i,c]),h=so.useCallback(({buttonProps:x,isOpen:R,ref:C})=>{let P=m===c.selectedKey;return jsxRuntime.jsx(ge,{...x,ref:C,icon:_8.ChevronDownIcon,"aria-expanded":R,variant:"toolbar",size:i,isSelected:P,className:Au,isDisabled:n,excludeFromTabOrder:s})},[m,s,n,i,c.selectedKey]),z=utils.filterTruthyValues({"data-block-id":t,"data-hovered":v,"data-selected":m===c.selectedKey});return jsxRuntime.jsx(Ja.Provider,{value:c,children:jsxRuntime.jsxs(M,{...g,role:"group",display:"inline-flex",flexDirection:"row",alignItems:"center",className:utils.classNames(Vu,"BaselineUI-ButtonSelect",e),"aria-label":p["aria-label"],"aria-labelledby":p["aria-labelledby"],"aria-describedby":p["aria-describedby"],"aria-details":p["aria-details"],style:r,ref:d,...z,children:[b,jsxRuntime.jsx(Ae,{isDisabled:n,showSelectedIcon:l,placement:"bottom end",items:o,...p,variant:"ghost",renderTrigger:h})]})})});$u.displayName="ButtonSelect";var Uu=_({defaultClassName:"_18v88n10 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6kv",variantClassNames:{labelPosition:{top:"_1yep5z613n _1yep5z613o _1yep5z613p",start:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6152 _1yep5z6153 _1yep5z6154 _1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),qu=_({defaultClassName:"_18v88n1p _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6eu _1yep5z6kv _1yep5z6l6 _1yep5z6ky _1yep5z6dy",variantClassNames:{isDisabled:{true:"_18v88n1q _1yep5z6109"},labelPosition:{top:"_18v88n1r",start:"_18v88n1s"}},defaultVariants:{},compoundVariants:[]}),Ku=_({defaultClassName:"_18v88n1t _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ks",variantClassNames:{validationState:{valid:"_18v88n1u",error:"_1yep5z6zp",warning:"_1yep5z6zx"},isReadOnly:{true:"_1yep5z610b"}},defaultVariants:{},compoundVariants:[]}),Gu=_({defaultClassName:"_18v88n1d _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{validationState:{valid:"_18v88n1e",error:"_1yep5z611k",warning:"_18v88n1g"},isHovered:{true:"_18v88n1h"},isFocused:{true:"_1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z616k _1yep5z616i _1yep5z611y _1yep5z616b _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"_18v88n1j"},variant:{primary:"_18v88n1k",ghost:"_18v88n1l"},isReadOnly:{true:"_1yep5z612n"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"_1yep5z61rv _1yep5z61rt _1yep5z61nc"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"_18v88n1n"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"_1yep5z61nd"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"_1yep5z61nd"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"_18v88n1o"]]}),Wu=_({defaultClassName:"_18v88n13 _1yep5z6dy _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Xu=_({defaultClassName:"_18v88n19 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5",variantClassNames:{labelPosition:{top:"_1yep5z6sh _1yep5z6si _1yep5z6sj",start:"_1yep5z6me _1yep5z6mf _1yep5z6mg _1yep5z613n _1yep5z613o _1yep5z613p"},hasMessage:{true:"_18v88n1c"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"_1yep5z61q7 _1yep5z61q8 _1yep5z61q9"]]}),Yu="_1yep5z6kv",Zu="_1yep5z6d7 _1yep5z6fs",Qu=_({defaultClassName:"_18v88n15 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isHovered:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isOpen:{true:"_1yep5z612v _1yep5z6169"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isHovered:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isOpen:!0},"_1yep5z61o6 _1yep5z61rk"]]});var of=so__default.default.forwardRef(({className:e,style:r,inputStyle:o,inputClassName:t,"data-block-id":a,label:i,items:n,showSelectedIcon:l=!1,onSelectionChange:s,onInputChange:p,isInvalid:d=!1,labelPosition:u="top",validationState:c="valid",variant:m="primary",toggleLabel:f,renderOption:y,showIcon:g=!0,filter:v,...b},h)=>{let{contains:z}=reactAria.useFilter({sensitivity:"base"}),x=ae(),R=reactStately.useComboBoxState({...b,defaultFilter:v||z,defaultItems:n,onSelectionChange:s,onInputChange:p,children:x,validationState:d?"invalid":"valid"}),C=so__default.default.useRef(null),P=so__default.default.useRef(null),k=so__default.default.useRef(null),T=so__default.default.useRef(null),I=so__default.default.useRef(null),{buttonProps:B,inputProps:E,listBoxProps:w,labelProps:S,errorMessageProps:$,descriptionProps:re,validationErrors:ne}=reactAria.useComboBox({...b,inputRef:P,defaultItems:n,buttonRef:C,listBoxRef:k,popoverRef:T,validationState:c==="error"?"invalid":"valid"},R),X=b.errorMessage||ne.join(" "),K=_e({...b,errorMessage:X,descriptionProps:re,errorMessageProps:$,labelPosition:u});X&&(c="error");let{hoverProps:G,isHovered:V}=reactAria.useHover({isDisabled:b.isDisabled}),{isFocused:Z,focusProps:ee,isFocusVisible:Ce}=reactAria.useFocusRing(),Pe=Po({isReadOnly:b.isReadOnly,validationState:c}),me=utils.filterTruthyValues({"data-read-only":b.isReadOnly,"data-disabled":b.isDisabled,"data-validation-state":c,"data-focused":Z,"data-focus-visible":Ce}),{labelProps:ke,fieldProps:Le}=reactAria.useLabel({label:i});return jsxRuntime.jsx(Xe.Provider,{value:R,children:jsxRuntime.jsxs("div",{className:utils.classNames(Uu({labelPosition:u}),e,"BaselineUI-ComboBox"),"data-block-id":a,style:r,ref:h,children:[i||u==="start"&&K?jsxRuntime.jsxs("div",{className:Xu({labelPosition:u,hasMessage:!!K}),children:[jsxRuntime.jsx("label",{...reactAria.mergeProps(S,ke),className:Wu({isDisabled:b.isDisabled}),children:i}),u==="start"&&K]}):null,jsxRuntime.jsxs("div",{...G,className:Gu({validationState:c,isHovered:V,isFocused:Z,variant:m,isReadOnly:!!b.isReadOnly,isDisabled:!!b.isDisabled}),ref:I,children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(E,ee,me,Le),ref:P,className:utils.classNames(qu({isDisabled:b.isDisabled,labelPosition:u}),"BaselineUI-ComboBox-Input",t),style:o}),Pe&&g?jsxRuntime.jsx(Pe,{className:Ku({validationState:c,isReadOnly:b.isReadOnly}),size:16}):null,jsxRuntime.jsx(O,{...B,ref:C,variant:"popover",label:f,className:Qu({isFocusVisible:!b.isDisabled&&!b.isReadOnly&&Ce,isHovered:!b.isDisabled&&!b.isReadOnly&&V,isOpen:R.isOpen})})]}),R.isOpen?jsxRuntime.jsx(ie,{className:Zu,ref:T,triggerRef:I,state:R,children:jsxRuntime.jsx(oe,{...w,items:n,ref:k,renderOption:y,selectionMode:"single",showSelectedIcon:l,className:Yu})}):null,u==="top"&&K]})})});of.displayName="ComboBox";var rf="byycd00";var yn=so__default.default.forwardRef(({item:e,renderGridItem:r,state:o},t)=>{let a=Re(t),i=reactAria.useGridListItem({node:e},o,a),n=o.selectionManager.selectionMode!=="none"&&o.selectionManager.selectionBehavior==="toggle",{checkboxProps:l}=reactAria.useGridListSelectionCheckbox({key:e.key},o);return r(e,{...i,checkBoxProps:n?l:void 0},a)});yn.displayName="GridListItem";var af=so__default.default.forwardRef(({className:e,style:r,"data-block-id":o,...t},a)=>{let i=ae(),n=reactStately.useListState({...t,children:i}),l=Re(a),{gridProps:s}=reactAria.useGridList(t,n,l);return jsxRuntime.jsx("ul",{...s,className:utils.classNames(rf,e),"data-block-id":o,style:r,ref:l,children:[...n.collection].map(p=>jsxRuntime.jsx(yn,{item:p,state:n,renderGridItem:t.renderGridItem},p.key))})});af.displayName="GridList";var nf="_1dc3b8m0";var pf=so__default.default.forwardRef(({className:e,selectionMode:r="single",style:o,"data-block-id":t,includeTooltip:a,...i},n)=>{let l=Re(n),s=ae(),p=reactStately.useListState({...i,selectionMode:r,suppressTextValueWarning:!0,children:s}),{actionGroupProps:d}=actiongroup.useActionGroup({...i,selectionMode:r,children:s},p,l);return jsxRuntime.jsx(M,{...d,display:"flex",flexDirection:"row",gap:"xs",className:utils.classNames("BaselineUI-ActionGroup",e),"data-block-id":t,style:o,ref:l,children:[...p.collection].map(u=>jsxRuntime.jsx(K0,{item:u,state:p,isDisabled:i.isDisabled,onAction:i.onAction,includeTooltip:a},u.key))})});pf.displayName="ActionGroup";var K0=({item:e,state:r,onAction:o,includeTooltip:t,isDisabled:a})=>{let{buttonProps:i}=actiongroup.useActionGroupItem({key:e.key},r),n=a||r.selectionManager.isDisabled(e.key),l=r.selectionManager.isSelected(e.key);utils.invariant(e.value);let{icon:s}=e.value;return utils.invariant(s),jsxRuntime.jsx(interactions.PressResponder,{...reactAria.mergeProps(i,{onPress:()=>{o?.(e.key);}}),children:jsxRuntime.jsx(He,{text:e.textValue,size:"sm",variant:"inverse",isDisabled:!t,includeArrow:!1,offset:4,children:jsxRuntime.jsx(L,{variant:"tertiary",icon:s,"aria-label":e.textValue,size:"sm",isDisabled:n,className:utils.classNames({[nf]:l},"BaselineUI-ActionGroup-Item")})})})};var df=so__default.default.forwardRef(({className:e,style:r,items:o,optionsContainerClassName:t,"data-block-id":a,label:i,icon:n,value:l,defaultValue:s,onChange:p,isDisabled:d,optionClassName:u,optionStyle:c,labelPosition:m="top",...f},y)=>{let g=so.useMemo(()=>o.map(b=>({id:b.color,label:b.label})),[o]),v=reactAria.useId();return so.useEffect(()=>{!i&&!f["aria-label"]&&!f["aria-labelledby"]&&console.warn("ColorSwatchPicker: Please provide a label or aria-label for accessibility.");},[i,f]),jsxRuntime.jsxs(M,{...da(f),className:utils.classNames("BaselineUI-ColorSwatchPicker",e),"data-block-id":a,display:"flex",flexDirection:m==="top"?"column":"row",alignItems:m==="top"?"flex-start":"center",justifyContent:"space-between",gap:"md",style:r,ref:y,children:[n||i?jsxRuntime.jsxs(M,{display:"flex",alignItems:"center",gap:"md",children:[n?jsxRuntime.jsx(n,{size:24,className:tokens.sprinkles({color:"icon.primary"})}):null,i?jsxRuntime.jsx(W,{id:v,type:"label",size:"sm",children:i}):null]}):null,jsxRuntime.jsx(oe,{className:utils.classNames(Kt,t),selectionMode:"single",items:g,orientation:"horizontal",defaultSelectedKeys:s?[s]:void 0,disabledKeys:d?g.map(b=>b.id):void 0,isDisabled:d,selectedKeys:l?[l]:void 0,onSelectionChange:b=>{p?.([...b][0]);},optionClassName:u,optionStyle:c,renderOption:({key:b,textValue:h},{isSelected:z,isFocusVisible:x,isDisabled:R,optionProps:C},P)=>jsxRuntime.jsx("li",{...C,"data-disabled":R,className:utils.classNames(qt,C.className),ref:P,children:jsxRuntime.jsx(he,{isFocusVisible:x,color:b,isSelected:z,"aria-label":h,isInteractive:!0,isDisabled:R})}),...f,"aria-labelledby":i?v:f["aria-labelledby"]})]})});df.displayName="ColorSwatchPicker";function XX(e){return e.closest(".BaselineUI-Portal")||e.closest(".BaselineUI-Popover-Content")}
79
+ var we=typeof document<"u"?to__default.default.useLayoutEffect:()=>{};function ca(e){let t=to.useRef(null);return we(()=>{t.current=e;},[e]),to.useCallback((...o)=>{let r=t.current;return r?.(...o)},[])}function da(e){let[t,o]=to.useState(e),r=to.useRef(null),a=ca(()=>{if(!r.current)return;let n=r.current.next();if(n.done){r.current=null;return}t===n.value?a():o(n.value);});we(()=>{r.current&&a();});let i=ca(n=>{r.current=n(t),a();});return [t,i]}var ge=e=>{var t;return (t=e?.ownerDocument)!==null&&t!==void 0?t:document},Q=e=>{if(e&&"window"in e&&e.window===e)return e;let t=Vt(e);return t instanceof ShadowRoot?t.ownerDocument.defaultView||window:t?.defaultView||window},Vt=e=>{if(!e)return document;let t=e.getRootNode?e.getRootNode():document;return e.isConnected?(t):null};function N(...e){return e.length===1?e[0]:t=>{for(let o of e)typeof o=="function"?o(t):o!=null&&(o.current=t);}}var Pf=new Set(["id"]),kf=new Set(["aria-label","aria-labelledby","aria-describedby","aria-details"]),wf=new Set(["href","hrefLang","target","rel","download","ping","referrerPolicy"]),Rf=/^(data-.*)$/;function ma(e,t={}){let{labelable:o,isLink:r,propNames:a}=t,i={};for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(Pf.has(n)||o&&kf.has(n)||r&&wf.has(n)||a?.has(n)||Rf.test(n))&&(i[n]=e[n]);return i}function vn(e){var t;return typeof window>"u"||window.navigator==null?!1:((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.brands.some(o=>e.test(o.brand)))||e.test(window.navigator.userAgent)}function ua(e){var t;return typeof window<"u"&&window.navigator!=null?e.test(((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.platform)||window.navigator.platform):!1}function _n(){return ua(/^Mac/i)}function zn(){return ua(/^iPhone/i)}function hn(){return ua(/^iPad/i)||_n()&&navigator.maxTouchPoints>1}function fa(){return zn()||hn()}function ya(){return vn(/Android/i)}function Ko(){return vn(/Firefox/i)}function Re(e){let t=to.useRef(null);return to.useMemo(()=>({get current(){return t.current},set current(o){t.current=o,typeof e=="function"?e(o):e&&(e.current=o);}}),[e])}function Sf(){return typeof window.ResizeObserver<"u"}function ba(e){let{ref:t,onResize:o}=e;to.useEffect(()=>{let r=t?.current;if(r)if(Sf()){let a=new window.ResizeObserver(i=>{i.length&&o();});return a.observe(r),()=>{r&&a.unobserve(r);}}else return window.addEventListener("resize",o,!1),()=>{window.removeEventListener("resize",o,!1);}},[o,t]);}function Bf(e){return "type"in e&&e.type==="section"?jsxRuntime.jsx(reactStately.Section,{items:e.children,title:e.title,children:t=>jsxRuntime.jsx(reactStately.Item,{children:t.label},t.id)},e.id):(utils.invariant("label"in e,"Item doesn't have a label"),jsxRuntime.jsx(reactStately.Item,{textValue:e.label,children:e.label},e.id))}function se(){return to.useCallback(e=>Bf(e),[])}function Cn(e,t,o){let{direction:r}=reactAria.useLocale(),a=reactStately.useDraggableCollectionState({...e,collection:t.collection,selectionManager:t.selectionManager,isDisabled:!e.enableReorder,getItems:e.getItems||(l=>[...l].map(s=>{let p=t.collection.getItem(s);return utils.invariant(p,"Expected item to be defined."),{"text/plain":p.textValue}}))});reactAria.useDraggableCollection(e,a,o);let i=reactStately.useDroppableCollectionState({...e,collection:t.collection,selectionManager:t.selectionManager}),{collectionProps:n}=reactAria.useDroppableCollection({...e,keyboardDelegate:new reactAria.ListKeyboardDelegate({collection:t.collection,disabledKeys:t.disabledKeys,ref:o,orientation:e.orientation,layout:e.layout,direction:r}),dropTargetDelegate:new reactAria.ListDropTargetDelegate(t.collection,o)},i,o);return {collectionProps:n,dragState:a,dropState:i}}function Uf(e,t){if(typeof e!="object"||!e)return e;var o=e[Symbol.toPrimitive];if(o!==void 0){var r=o.call(e,t||"default");if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return (t==="string"?String:Number)(e)}function qf(e){var t=Uf(e,"string");return typeof t=="symbol"?t:String(t)}function Kf(e,t,o){return t=qf(t),t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}function Pn(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),o.push.apply(o,r);}return o}function kn(e){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?Pn(Object(o),!0).forEach(function(r){Kf(e,r,o[r]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):Pn(Object(o)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(o,r));});}return e}function wn(e,t){var o={};for(var r in e)o[r]=t(e[r],r);return o}var Gf=(e,t,o)=>{for(var r of Object.keys(e)){var a;if(e[r]!==((a=t[r])!==null&&a!==void 0?a:o[r]))return !1}return !0},_=e=>{var t=o=>{var r=e.defaultClassName,a=kn(kn({},e.defaultVariants),o);for(var i in a){var n,l=(n=a[i])!==null&&n!==void 0?n:e.defaultVariants[i];if(l!=null){var s=l;typeof s=="boolean"&&(s=s===!0?"true":"false");var p=e.variantClassNames[i][s];p&&(r+=" "+p);}}for(var[d,u]of e.compoundVariants)Gf(d,a,e.defaultVariants)&&(r+=" "+u);return r};return t.variants=()=>Object.keys(e.variantClassNames),t.classNames={get base(){return e.defaultClassName.split(" ")[0]},get variants(){return wn(e.variantClassNames,o=>wn(o,r=>r.split(" ")[0]))}},t};var Rn=_({defaultClassName:"_6n12k9b _1yep5z6l0 _1yep5z6kz _1yep5z6hk _1yep5z6ki",variantClassNames:{isDropTarget:{true:"_1yep5z612n"},orientation:{vertical:"_1yep5z6166",horizontal:"_1yep5z6167"}},defaultVariants:{},compoundVariants:[]}),In="_6n12k98 _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",Tn=_({defaultClassName:"_6n12k99 _1yep5z6ev _1yep5z6da _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),Nn=_({defaultClassName:"_6n12k91 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6dy _1yep5z6eu _1yep5z6ki _1yep5z6kl _1yep5z6ky _1yep5z6kx _1yep5z6kv _1yep5z6ks",variantClassNames:{isSelected:{},isFocused:{true:"_1yep5z612n _1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612w _1yep5z612x _1yep5z612y"},isHovered:{true:"_1yep5z6114",false:"_1yep5z6113"},isFirstChild:{true:"_6n12k95"},isLastChild:{true:"_6n12k96"},isDisabled:{true:"z9nup83 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Sn="_6n12k90";var Ln=_({defaultClassName:"gukncs0",variantClassNames:{isVertical:{true:"gukncs1"},isSecondary:{true:"gukncs2"}},defaultVariants:{},compoundVariants:[]});var F=to__default.default.forwardRef(({className:e,style:t,variant:o="primary",orientation:r="horizontal",UNSAFE_omitRole:a,elementType:i="div",...n},l)=>{let{separatorProps:s}=reactAria.useSeparator({...n,orientation:r,elementType:i});return jsxRuntime.jsx(i,{...s,className:utils.classNames(Ln({isVertical:r==="vertical",isSecondary:o==="secondary"}),"BaselineUI-Separator",e),"data-orientation":r,"data-block-id":n["data-block-id"],style:t,role:a?void 0:s.role,ref:l})});F.displayName="Separator";function oy(e){return tokens.sprinkles.properties.has(e)}var M=to__default.default.forwardRef(({elementType:e="div",children:t,...o},r)=>{let a=e,{sprinkleProps:i,domProps:n}=to.useMemo(()=>{let l={},s={};for(let p in o)oy(p)?l[p]=o[p]:s[p]=o[p];return {sprinkleProps:l,domProps:s}},[o]);return jsxRuntime.jsx(a,{...n,className:utils.classNames(tokens.sprinkles(i),"BaselineUI-Box",n.className),ref:r,children:t})});M.displayName="Box";var Wo=to__default.default.forwardRef(({item:e,isDisabled:t,isFocusVisible:o,isSelected:r,liProps:a,showSelectedIcon:i,description:n,descriptionProps:l,labelProps:s,isFocused:p,isPressed:d,_state:u},c)=>{utils.invariant(e.value&&(e.value.type==="option"||e.value.type===void 0),"Item cannot be a section");let{icon:m,label:f}=e.value,{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:t}),v=utils.filterTruthyValues({"data-selected":r,"data-disabled":t,"data-focused":p,"data-hovered":g,"data-pressed":d,"data-focus-visible":o,"data-selection-mode":u.selectionManager.selectionMode});return jsxRuntime.jsxs("li",{...reactAria.mergeProps(a,y,v),className:utils.classNames(Nn({isHovered:g,isFocused:o,isFirstChild:u.collection.getFirstKey()===e.key,isLastChild:u.collection.getLastKey()===e.key,isDisabled:t}),"BaselineUI-ListBox-Option"),ref:c,children:[jsxRuntime.jsxs(M,{display:"flex",alignItems:"center",gap:"lg",children:[i?jsxRuntime.jsx("span",{"aria-hidden":!0,style:{height:24,width:24},children:r?jsxRuntime.jsx(_24.CheckmarkIcon,{size:24}):null}):null,m?jsxRuntime.jsx(m,{size:24}):null,jsxRuntime.jsx("span",{...s,children:f})]}),n?jsxRuntime.jsx("span",{className:Tn({isDisabled:t}),...l,children:n}):null]})});Wo.displayName="DefaultRenderOption";var _a=({dropState:e,orientation:t="vertical",dropIndicatorStyle:o,dropIndicatorClassName:r,renderDropIndicator:a=({isDropTarget:n,isHidden:l,dropIndicatorProps:s,orientation:p},d)=>l?null:jsxRuntime.jsx("li",{...s,ref:d,"data-drop-target":n,className:utils.classNames(Rn({isDropTarget:n,orientation:p}),"BaselineUI-DropIndicator",r),style:o}),...i})=>{let n=to__default.default.useRef(null),{dropIndicatorProps:l,isHidden:s,isDropTarget:p}=reactAria.useDropIndicator(i,e,n);return a({dropIndicatorProps:{...l,role:"option"},isHidden:s,isDropTarget:p,orientation:t},n)};var Hn=({item:e,children:t,state:o,dragState:r,...a})=>{let{dragProps:i}=reactAria.useDraggableItem({key:e.key},r);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(_a,{target:{type:"item",key:e.key,dropPosition:"before"},...a}),t(i),o.collection.getKeyAfter(e.key)==null&&jsxRuntime.jsx(_a,{target:{type:"item",key:e.key,dropPosition:"after"},...a})]})};Hn.displayName="DraggableListOption";var Xo=to__default.default.forwardRef(({item:e,renderOption:t=(c,m,f)=>jsxRuntime.jsx(Wo,{item:c,liProps:m.optionProps,...m,ref:f}),showSelectedIcon:o,state:r,dragState:a,dropState:i,orientation:n,dropIndicatorStyle:l,dropIndicatorClassName:s,optionStyle:p,optionClassName:d},u)=>{let c=to__default.default.useRef(null),m=reactAria.useOption({key:e.key},r,c),{value:f}=e;utils.invariant(!!f),utils.invariant(!("children"in e),"ListSection should not be passed to ListOption");let y={style:typeof p=="function"?p(f):p,className:typeof d=="function"?d(f):d};return a&&i?jsxRuntime.jsx(Hn,{orientation:n,state:r,item:e,dropState:i,dragState:a,dropIndicatorStyle:l,dropIndicatorClassName:s,children:g=>t(e,{...m,showSelectedIcon:o,_state:r,optionProps:reactAria.mergeProps(m.optionProps,g,y)},N(c,u))}):t(e,{...m,showSelectedIcon:o,_state:r,optionProps:reactAria.mergeProps(m.optionProps,y)},N(c,u))});Xo.displayName="Option";var za=({section:e,state:t,sectionClassName:o,sectionStyle:r,...a})=>{let{itemProps:i,groupProps:n}=reactAria.useListBoxSection({heading:e.rendered,"aria-label":e["aria-label"]}),l=t.collection.getChildren?.(e.key);utils.invariant(l,"items with type `section` must have children");let{value:s}=e,p=typeof r=="function"?r(s):r,d=typeof o=="function"?o(s):o;return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[e.key!==t.collection.getFirstKey()&&jsxRuntime.jsx(F,{UNSAFE_omitRole:!0}),jsxRuntime.jsx("li",{...i,style:{...i.style,...p},className:utils.classNames(Sn,d,"BaselineUI-ListBox-Section"),children:jsxRuntime.jsx("ul",{...n,children:[...l].map(u=>jsxRuntime.jsx(Xo,{item:u,state:t,...a},u.key))})})]})};za.displayName="ListBoxSection";var We=to__default.default.createContext(null),ha=to__default.default.forwardRef(({className:e,layout:t="stack",orientation:o="vertical",showSelectedIcon:r=!0,style:a,renderOption:i,enableReorder:n=!1,"data-block-id":l,renderDragPreview:s,onReorder:p,state:d,...u},c)=>{let m=to__default.default.useRef(null),{direction:f}=reactAria.useLocale(),y=to__default.default.useRef(null),{listBoxProps:g}=reactAria.useListBox({...u,shouldSelectOnPressUp:n,keyboardDelegate:new reactAria.ListKeyboardDelegate({collection:d.collection,ref:y,layout:t,orientation:o,direction:f,disabledKeys:d.disabledKeys})},d,y),v=web.useReducedMotion(),b=to.useCallback(T=>{let I=ge(y.current);p&&(!v&&"startViewTransition"in I?I.startViewTransition(()=>{p(T);}):p(T));},[p,v]),{collectionProps:h,dragState:z,dropState:x}=Cn({...u,onReorder:b,layout:t,orientation:o,enableReorder:n,preview:m},d,y),{isFocusVisible:R,isFocused:C,focusProps:P}=reactAria.useFocusRing(),k=utils.filterTruthyValues({"data-block-id":l,"data-layout":t,"data-empty":d.collection.size===0,"data-focused":C,"data-focus-visible":R,"data-orientation":o});return jsxRuntime.jsxs("ul",{...reactAria.mergeProps(g,P,k,h),className:utils.classNames(In,"BaselineUI-ListBox",e),style:a,ref:N(c,y),children:[[...d.collection].map(T=>{let I={key:T.key,state:d,dragState:z,dropState:x,renderOption:i,renderDropIndicator:u.renderDropIndicator,showSelectedIcon:r,orientation:o,dropIndicatorStyle:u.dropIndicatorStyle,dropIndicatorClassName:u.dropIndicatorClassName,optionStyle:u.optionStyle,optionClassName:u.optionClassName};return T.type==="section"?jsxRuntime.jsx(za,{...I,section:T}):jsxRuntime.jsx(Xo,{...I,item:T})}),s?jsxRuntime.jsx(reactAria.DragPreview,{ref:m,children:s}):null]})});ha.displayName="ListBoxCore";var On=to__default.default.forwardRef((e,t)=>{let o=se(),r=reactStately.useListState({...e,children:o});return jsxRuntime.jsx(ha,{...e,ref:t,state:r})});On.displayName="ListBoxStandalone";var te=to__default.default.forwardRef((e,t)=>{let o=to.useContext(We);return to.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?jsxRuntime.jsx(ha,{...e,ref:t,state:o}):jsxRuntime.jsx(On,{...e,ref:t})});te.displayName="ListBox";var $t="uf19bsg _1yep5z6ki",Vn=_({defaultClassName:"uf19bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0 _1yep5z6kx _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ks",variantClassNames:{size:{xxs:"uf19bs1",xs:"uf19bs2",sm:"uf19bs3",md:"uf19bs4",lg:"uf19bs5 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy"},isHovered:{true:"uf19bs6"},isDisabled:{true:"uf19bs7 _1yep5z610d"},isFocusVisible:{true:"uf19bs8"},variant:{primary:"uf19bs9",secondary:"uf19bsa",tertiary:"uf19bsb",ghost:"uf19bsc",toolbar:"_1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg",popover:"uf19bse _1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z6mn _1yep5z6mo _1yep5z6mp _1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nq _1yep5z6nr _1yep5z6ns _1yep5z6uz _1yep5z6v0 _1yep5z6v1"},isPressed:{true:"uf19bsf"}},defaultVariants:{},compoundVariants:[[{variant:"toolbar",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"primary",isHovered:!0,isFocusVisible:!1},"_1yep5z61mg"],[{variant:"secondary",isHovered:!0,isFocusVisible:!1},"_1yep5z61ln"],[{variant:"tertiary",isHovered:!0,isFocusVisible:!1},"_1yep5z61lm _1yep5z61mg"],[{variant:"ghost",isHovered:!0,isFocusVisible:!1},"_1yep5z61ls"],[{variant:"popover",isHovered:!0,isFocusVisible:!1},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"toolbar",isPressed:!0},"_1yep5z61mg"],[{variant:"primary",isPressed:!0},"_1yep5z61mf"],[{variant:"secondary",isPressed:!0},"_1yep5z61ln"],[{variant:"tertiary",isPressed:!0},"_1yep5z61lq _1yep5z61mg"],[{variant:"ghost",isPressed:!0},"_1yep5z61lt"],[{variant:"popover",isPressed:!0},"_1yep5z61o1 _1yep5z61rl _1yep5z61rp _1yep5z61rm"],[{variant:"ghost",isDisabled:!1},"_1yep5z61lr"],[{variant:"popover",size:"lg"},"_1yep5z61h4 _1yep5z61h5 _1yep5z61h6 _1yep5z61hs _1yep5z61ht _1yep5z61hu _1yep5z61ig _1yep5z61ih _1yep5z61ii _1yep5z61j4 _1yep5z61j5 _1yep5z61j6"]]});var Yo=to__default.default.createContext({state:null,overlayTriggerAria:{triggerProps:{},overlayProps:{}},triggerRef:void 0}),Xe=({children:e,...t})=>{let o=to__default.default.useRef(null),r=reactStately.useOverlayTriggerState(t),a=reactAria.useOverlayTrigger(t,r),i=to.useMemo(()=>({state:r,overlayTriggerAria:a,triggerRef:o}),[r,a]);return jsxRuntime.jsx(Yo.Provider,{value:i,children:typeof e=="function"?e(r):e})};var jn={bottom:"_1gzftth2",top:"_1gzftth3",right:"_1gzftth4",left:"_1gzftth5"},$n="_1gzftth1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2",Un="_1gzftth6",qn="_1gzftth8",Kn="_1gzftth7",Gn="var(--_1gzftth0)";function Wn(e){return typeof e=="object"&&typeof e.left=="number"&&typeof e.top=="number"&&(typeof e.width=="number"||e.width===void 0)&&(typeof e.height=="number"||e.height===void 0)}var Ut=to__default.default.createContext({isSelected:!1,ref:void 0}),Ye=({children:e,anchorRect:t})=>{let{state:o,overlayTriggerAria:r,triggerRef:a}=to.useContext(Yo);utils.invariant(o,"PopoverTrigger must be used within a Popover");let{triggerProps:i}=r,n=to.useMemo(()=>({...i,isSelected:o.isOpen,ref:a}),[i,o.isOpen,a]);return utils.invariant(!t&&e||t&&!e,"Either one of anchorRect or children has to be provided."),utils.invariant(!t||Wn(t),"If provided, the anchorRect prop must be an object with left and top number values, and optionally width and height."),jsxRuntime.jsx(Ut.Provider,{value:n,children:t?jsxRuntime.jsx("button",{className:utils.classNames(qn,"BaselineUI-PopoverTrigger-Hidden"),style:t,ref:a,tabIndex:-1},JSON.stringify(t)):e})};var qt=e=>{let t=to__default.default.useRef(null),{ref:o,...r}=to.useContext(Ut)||{},{buttonProps:a,isPressed:i}=reactAria.useButton({...e,...r},t);return {buttonProps:a,isPressed:i,ref:N(t,o||null)}},Kt=(e,t)=>{let o=to__default.default.useRef(null),{ref:r,...a}=to.useContext(Ut)||{},{buttonProps:i,isPressed:n}=reactAria.useToggleButton({...e,...a},t,o);return {buttonProps:i,isPressed:n,ref:N(o,r||null)}};var Gt=_({defaultClassName:"oom8bs0 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6dy _1yep5z6ki",variantClassNames:{variant:{primary:"oom8bs1",secondary:"oom8bs2",tertiary:"oom8bs3",ghost:"oom8bs4",popover:"oom8bs5",toolbar:"oom8bs6",success:"oom8bs7",warning:"oom8bs8",error:"oom8bs9"},isDisabled:{true:"oom8bsa"},isFocusVisible:{true:"oom8bsb"},isHovered:{true:"oom8bsc"},size:{sm:"oom8bsd",md:"oom8bse",lg:"oom8bsf"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isHovered:!0},"oom8bsg"],[{variant:"secondary",isHovered:!0},"oom8bsh"],[{variant:"tertiary",isHovered:!0},"oom8bsi"],[{variant:"popover",isHovered:!0},"oom8bsj"],[{variant:"ghost",isHovered:!0},"oom8bsk"],[{variant:"success",isHovered:!0},"oom8bsl"],[{variant:"warning",isHovered:!0},"oom8bsm"],[{variant:"error",isHovered:!0},"oom8bsn"],[{variant:"primary",isFocusVisible:!0},"oom8bso"],[{variant:"tertiary",isFocusVisible:!0},"oom8bsp"],[{variant:"success",isFocusVisible:!0},"oom8bsq"],[{variant:"warning",isFocusVisible:!0},"oom8bsr"],[{variant:"error",isFocusVisible:!0},"oom8bss"]]});var e1={sm:16,md:20,lg:24},O=to__default.default.forwardRef(({label:e,style:t,className:o,iconStart:r,iconEnd:a,variant:i="primary",elementType:n="button",isDisabled:l,size:s="sm","data-block-id":p,...d},u)=>{let{buttonProps:c,isPressed:m,ref:f}=qt({...d,elementType:n,isDisabled:l}),y=e1[s],{hoverProps:g,isHovered:v}=reactAria.useHover({isDisabled:l}),{isFocusVisible:b,isFocused:h,focusProps:z}=reactAria.useFocusRing(),x=utils.filterTruthyValues({"data-block-id":p,"data-disabled":l,"data-focused":h,"data-focus-visible":b,"data-hovered":v,"data-pressed":m});return jsxRuntime.jsxs(n,{...reactAria.mergeProps(c,g,z,x),className:utils.classNames(Gt({isDisabled:!!l,isFocusVisible:b,isHovered:v,variant:i,size:s}),"BaselineUI-ActionButton",o),style:t,ref:N(u,f),children:[!!r&&jsxRuntime.jsx(r,{size:y}),e,!!a&&jsxRuntime.jsx(a,{size:y}),i==="popover"&&jsxRuntime.jsx(_8.ChevronDownIcon,{size:8,className:$t})]})});O.displayName="ActionButton";var Qn=_({defaultClassName:"z9nup84",variantClassNames:{size:{xs:"z9nup85",sm:"z9nup86"}},defaultVariants:{},compoundVariants:[]});var Wt="z9nup80",po="z9nup83";var Jn="z9nup87";var es=to__default.default.forwardRef(({className:e,node:t},o)=>{let r=to__default.default.useRef(null);return to__default.default.useEffect(()=>{let a=r.current;return a?.append(t),()=>{a?.contains(t)&&t.remove();}},[t]),jsxRuntime.jsx("div",{className:utils.classNames(Wt,e),ref:N(o,r)})});es.displayName="DomNodeRenderer";var os="_14uvjig0 z9nup81",ts="_14uvjig7",rs="_14uvjig3",as=_({defaultClassName:"_14uvjig4",variantClassNames:{isDisabled:{true:"_14uvjig5"},hasNumberInput:{false:"_14uvjig6"}},defaultVariants:{},compoundVariants:[]}),is=_({defaultClassName:"_14uvjige _14uvjig1",variantClassNames:{active:{true:"_14uvjigf _14uvjig2"},isDisabled:{true:"_14uvjigg"},isReadOnly:{true:"_14uvjigh"},isFocusVisible:{true:"_14uvjigi _14uvjig2"},isHovered:{true:"_14uvjigj _14uvjig2"}},defaultVariants:{},compoundVariants:[]}),ns="_14uvjig8",ss=_({defaultClassName:"_14uvjig9 _14uvjig1",variantClassNames:{active:{true:"_14uvjig2"},isFocusVisible:{true:"_14uvjigb _14uvjig2"},isDisabled:{true:"_14uvjigc"},isHovered:{true:"_14uvjig2"}},defaultVariants:{},compoundVariants:[]});var co=_({defaultClassName:"nrh1ehx",variantClassNames:{isDisabled:{true:"nrh1ehy"},hasError:{true:"nrh1ehz"},labelPosition:{start:"nrh1eh10",top:"nrh1eh11"}},defaultVariants:{},compoundVariants:[]}),Xt=_({defaultClassName:"nrh1eho",variantClassNames:{isDisabled:{true:"nrh1ehp"},labelPosition:{top:"nrh1ehq",start:"nrh1ehr"}},defaultVariants:{},compoundVariants:[]}),mo=_({defaultClassName:"nrh1ehs",variantClassNames:{validationState:{valid:"nrh1eht",error:"nrh1ehu",warning:"nrh1ehv"},isReadOnly:{true:"nrh1ehw"}},defaultVariants:{},compoundVariants:[]}),Me="nrh1eh3",De=_({defaultClassName:"nrh1eh4",variantClassNames:{labelPosition:{top:"nrh1eh5",start:"nrh1eh6"},hasMessage:{true:"nrh1eh7"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"nrh1eh8"]]}),Be=_({defaultClassName:"nrh1eh0",variantClassNames:{labelPosition:{top:"z9nup81",start:"nrh1eh2 z9nup82"}},defaultVariants:{},compoundVariants:[]}),uo=_({defaultClassName:"nrh1eh9 z9nup82",variantClassNames:{validationState:{valid:"nrh1eha",error:"nrh1ehb",warning:"nrh1ehc"},isHovered:{true:"nrh1ehd"},isFocused:{true:"nrh1ehe"},isDisabled:{true:"nrh1ehf"},variant:{primary:"nrh1ehg",ghost:"nrh1ehh"},isReadOnly:{true:"nrh1ehi"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"nrh1ehj"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"nrh1ehk"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"nrh1ehl"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"nrh1ehm"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"nrh1ehn"]]});function _e({description:e,errorMessageProps:t,descriptionProps:o,warningMessage:r,errorMessage:a,labelPosition:i,isDisabled:n}){return e?jsxRuntime.jsx("div",{...o,className:co({isDisabled:n,labelPosition:i}),children:e}):a?jsxRuntime.jsx("div",{...t,className:co({hasError:!0,labelPosition:i}),children:a}):r?jsxRuntime.jsx("div",{className:co({isDisabled:n,labelPosition:i}),children:r}):null}var ls=_({defaultClassName:"_1lnwne1 z9nup82",variantClassNames:{isHoveredOrFocused:{true:"_1lnwne2"},isInteractive:{false:"z9nup83"}},defaultVariants:{},compoundVariants:[[{isHoveredOrFocused:!0,isInteractive:!0},"_1lnwne4"]]}),ps="_1lnwne0";var d1={xxs:8,xs:12,sm:16,md:20,lg:24},L=to__default.default.forwardRef(({className:e,style:t,icon:o,size:r="md",variant:a="primary",UNSAFE_NON_INTERACTIVE:i,elementType:n=i?"div":"button",...l},s)=>{!l["aria-label"]&&!l["aria-labelledby"]&&console.warn("An `ActionIconButton` requires an aria-label or aria-labelledby prop.");let{buttonProps:p,isPressed:d,ref:u}=qt({...l,elementType:n}),{isFocusVisible:c,isFocused:m,focusProps:f}=reactAria.useFocusRing(),{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:l.isDisabled}),v=utils.filterTruthyValues({"data-block-id":l["data-block-id"],"data-focused":m,"data-focus-visible":c,"data-disabled":l.isDisabled,"data-hovered":g,"data-pressed":d});return jsxRuntime.jsxs(n,{...reactAria.mergeProps(p,y,f,v),className:utils.classNames(Vn({variant:a,size:r,isDisabled:!!l.isDisabled,isFocusVisible:c,isHovered:g,isPressed:d}),"BaselineUI-ActionIconButton",e),ref:N(s,u),style:t,...i&&{tabIndex:void 0,role:void 0,"aria-label":void 0,"aria-labelledby":void 0,"aria-disabled":void 0},children:[jsxRuntime.jsx(o,{role:"presentation",size:d1[r]}),a==="popover"&&jsxRuntime.jsx(_8.ChevronDownIcon,{size:8,className:$t})]})});L.displayName="ActionIconButton";var Ie=to__default.default.forwardRef(({className:e,style:t,labelPosition:o="top",variant:r="primary",showStepper:a=!0,...i},n)=>{let l=to__default.default.useRef(null),{locale:s}=reactAria.useLocale(),p=reactStately.useNumberFieldState({...i,locale:s}),{hoverProps:d,isHovered:u}=reactAria.useHover({isDisabled:i.isDisabled}),{focusProps:c,isFocusVisible:m,isFocused:f}=reactAria.useFocusRing(),{labelProps:y,decrementButtonProps:g,inputProps:v,incrementButtonProps:b,groupProps:h,descriptionProps:z,errorMessageProps:x}=reactAria.useNumberField(i,p,l),R=to.useMemo(()=>i.isReadOnly?_16.ReadOnlyIcon:i.isInvalid?_16.ErrorFilledIcon:null,[i.isInvalid,i.isReadOnly]),C=_e({description:i.description,errorMessageProps:x,descriptionProps:z,errorMessage:i.errorMessage,labelPosition:o,isDisabled:i.isDisabled}),P=utils.filterTruthyValues({"data-disabled":i.isDisabled,"data-readonly":i.isReadOnly,"data-hovered":u,"data-focused":f,"data-focus-visible":m,"data-invalid":i.isInvalid,"data-block-id":i["data-block-id"]});return jsxRuntime.jsxs("div",{style:t,className:utils.classNames(Be({labelPosition:o}),"BaselineUI-NumberInput",e),...P,ref:n,children:[i.label?jsxRuntime.jsxs("div",{className:De({labelPosition:o,hasMessage:!!C}),children:[jsxRuntime.jsx("label",{...y,className:Me,children:i.label}),o==="start"&&C]}):null,jsxRuntime.jsxs("div",{className:utils.classNames({[po]:i.isDisabled}),children:[jsxRuntime.jsxs("div",{...reactAria.mergeProps(h,d),className:utils.classNames(uo({isHovered:u,isDisabled:!!i.isDisabled,isReadOnly:!!i.isReadOnly,validationState:i.isInvalid?"error":"valid",isFocused:f,variant:r}),{[ps]:o==="start"},"BaselineUI-NumberInput-Container"),children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(v,c),ref:l,className:utils.classNames("BaselineUI-NumberInput-Input",Xt({isDisabled:i.isDisabled,labelPosition:o}))}),R?jsxRuntime.jsx(R,{className:mo({validationState:"error",isReadOnly:i.isReadOnly}),size:16}):null,a?jsxRuntime.jsxs("div",{className:ls({isHoveredOrFocused:u||f,isInteractive:!i.isReadOnly&&!i.isDisabled}),children:[jsxRuntime.jsx(L,{variant:"secondary",size:"xxs",icon:_8.MinusIcon,...g,className:"BaselineUI-NumberInput-DecrementButton"}),jsxRuntime.jsx(F,{style:{height:16},orientation:"vertical"}),jsxRuntime.jsx(L,{variant:"secondary",size:"xxs",icon:_8.PlusIcon,...b,className:"BaselineUI-NumberInput-DecrementButton"})]}):null]}),o==="top"&&C]})]})});Ie.displayName="NumberInput";var Qt=to__default.default.forwardRef(({className:e,style:t,onChange:o,onChangeEnd:r,numberFormatOptions:a,isDisabled:i,step:n,minValue:l,maxValue:s,value:p,"aria-label":d,"aria-labelledby":u,"aria-details":c,"aria-describedby":m,"data-block-id":f,defaultValue:y,isReadOnly:g,label:v,id:b,includeNumberInput:h},z)=>{let x=to__default.default.useRef(null),R={onChange:o===void 0?void 0:E=>{o(E[0]);},isDisabled:i||g,step:n,minValue:l,maxValue:s,onChangeEnd:r===void 0?void 0:E=>{r(E[0]);},value:p===void 0?void 0:[p],defaultValue:y===void 0?void 0:[y],"aria-label":d,"aria-labelledby":u,"aria-details":c,"aria-describedby":m,id:b,label:v},C=reactAria.useNumberFormatter(a),P=reactStately.useSliderState({...R,numberFormatter:C}),{trackProps:k,groupProps:T,labelProps:I}=reactAria.useSlider(R,P,x),D=jsxRuntime.jsx(Ie,{variant:"ghost",showStepper:!1,"aria-label":d,"aria-labelledby":I.id,value:P.getThumbValue(0),formatOptions:a,onChange:E=>{P.setThumbValue(0,E);},style:{width:55,textAlign:"right",flexShrink:0}});return jsxRuntime.jsxs("div",{...T,style:t,"data-block-id":f,className:utils.classNames(os,"BaselineUI-Slider",e),children:[v?jsxRuntime.jsxs("div",{className:rs,children:[jsxRuntime.jsx("label",{...I,className:utils.classNames(as({isDisabled:i,hasNumberInput:!!h}),"BaselineUI-Slider-Label"),children:v}),h?D:null]}):null,jsxRuntime.jsxs("div",{className:ts,children:[jsxRuntime.jsx("div",{...k,className:utils.classNames(ns,"BaselineUI-Slider-Track"),ref:N(x,z),"data-testid":"track",children:jsxRuntime.jsx(L1,{state:P,trackRef:x,isDisabled:i,isReadOnly:g})}),h&&!v?D:null]})]})});Qt.displayName="Slider";function L1({state:e,trackRef:t,isDisabled:o,isReadOnly:r}){let a=to__default.default.useRef(null),{thumbProps:i,inputProps:n,isDragging:l}=reactAria.useSliderThumb({trackRef:t,inputRef:a},e),{focusProps:s,isFocused:p,isFocusVisible:d}=reactAria.useFocusRing(),{hoverProps:u,isHovered:c}=reactAria.useHover({isDisabled:o}),m=utils.filterTruthyValues({"data-disabled":o,"data-readonly":r,"data-hovered":c,"data-focus-visible":d,"data-dragging":l,"data-focused":p});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:utils.classNames(ss({isDisabled:o,isFocusVisible:d,active:l,isHovered:c}),"BaselineUI-Slider-TrackHighlight"),style:{width:i.style?.left},"data-testid":"track-highlight"}),jsxRuntime.jsx("div",{...reactAria.mergeProps(i,u,m),className:utils.classNames(is({isDisabled:o,isFocusVisible:d,active:l,isReadOnly:r,isHovered:c}),"BaselineUI-Slider-Thumb"),"data-testid":"thumb",children:jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{ref:a,...reactAria.mergeProps(n,s)})})})]})}var fs=_({defaultClassName:"bpklwa7",variantClassNames:{isReadOnly:{true:"bpklwa8"},isDisabled:{true:"bpklwa9"},isSelected:{true:"bpklwaa"},isFocused:{true:"bpklwab"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"bpklwac"]]}),ys=_({defaultClassName:"bpklwae",variantClassNames:{isDisabled:{true:"bpklwaf"},isSelected:{true:"bpklwag"},isReadOnly:{true:"bpklwah"}},defaultVariants:{},compoundVariants:[]}),bs="bpklwad",gs=_({defaultClassName:"bpklwa0",variantClassNames:{labelPosition:{top:"bpklwa1",left:"bpklwa2"}},defaultVariants:{},compoundVariants:[]}),vs="bpklwa6",_s=_({defaultClassName:"bpklwa3",variantClassNames:{labelPosition:{top:"bpklwa4",left:"bpklwa5"}},defaultVariants:{},compoundVariants:[]});var Cs=to__default.default.forwardRef(({className:e,label:t,labelPosition:o="top",statusLabel:r,style:a,"data-block-id":i,...n},l)=>{let s=to__default.default.useRef(null),p=reactStately.useToggleState(n),{inputProps:d,isPressed:u}=reactAria.useSwitch(n,p,s),{isFocusVisible:c,focusProps:m}=reactAria.useFocusRing(),{hoverProps:f,isHovered:y}=reactAria.useHover({isDisabled:n.isDisabled}),g=utils.filterTruthyValues({"data-block-id":i,"data-focused":c,"data-disabled":n.isDisabled,"data-focus-visible":c,"data-selected":p.isSelected,"data-readonly":n.isReadOnly,"data-hovered":y,"data-pressed":u}),v=jsxRuntime.jsx("div",{className:utils.classNames(fs({isSelected:p.isSelected,isDisabled:!!n.isDisabled,isFocused:c,isReadOnly:!!n.isReadOnly}),"BaselineUI-Switch-Track"),children:jsxRuntime.jsx("div",{className:utils.classNames(ys({isSelected:p.isSelected,isDisabled:n.isDisabled,isReadOnly:n.isReadOnly}),"BaselineUI-Switch-Knob"),"data-testid":"switch-knob"})});return jsxRuntime.jsxs("label",{...reactAria.mergeProps(g,f),className:utils.classNames(gs({labelPosition:o}),"BaselineUI-Switch",e),style:a,ref:l,children:[t?jsxRuntime.jsx("span",{className:utils.classNames(bs,"BaselineUI-Switch-Label"),children:t}):null,jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(d,m),ref:s})}),r?jsxRuntime.jsxs("div",{className:_s({labelPosition:o}),children:[jsxRuntime.jsx("span",{className:utils.classNames("BaselineUI-Switch-Status-Label",vs),children:p.isSelected?r.on:r.off}),v]}):v]})});Cs.displayName="Switch";var Ps="_19n40yy9",ks=_({defaultClassName:"_19n40yy0",variantClassNames:{size:{lg:"_19n40yy1",md:"_19n40yy2",sm:"_19n40yy3"},variant:{primary:"_19n40yy4",ghost:"_19n40yy5"},isFocused:{true:"_19n40yy6"},hasText:{true:"_19n40yy7"},isDisabled:{true:"_19n40yy8"}},defaultVariants:{},compoundVariants:[]});var X1={sm:_20.SearchIcon,md:_24.SearchIcon,lg:_24.SearchIcon},Is=to__default.default.forwardRef(({className:e,size:t="md",variant:o="primary",...r},a)=>{let i=to__default.default.useRef(null),n=reactStately.useSearchFieldState(r),{inputProps:l,clearButtonProps:s}=reactAria.useSearchField({...r,"aria-haspopup":!1,"aria-autocomplete":"none",type:"search"},n,i),{focusProps:p,isFocusVisible:d,isFocused:u}=reactAria.useFocusRing({within:!0,isTextInput:!0}),c=X1[t],m=t==="sm"?_12.XIcon:_16.XIcon,f=utils.filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":u,"data-disabled":r.isDisabled,"data-focus-visible":d});return jsxRuntime.jsxs("div",{...f,className:utils.classNames(ks({size:t,isFocused:u,variant:o,hasText:!!n.value,isDisabled:r.isDisabled}),"BaselineUI-SearchInput",e),ref:a,children:[jsxRuntime.jsx(c,{size:t==="sm"?20:24}),jsxRuntime.jsx("input",{...reactAria.mergeProps(l,p),className:Ps,ref:i}),n.value!==""&&jsxRuntime.jsx(L,{icon:m,...s,size:t==="sm"?"xs":"sm",variant:"secondary"})]})});Is.displayName="SearchInput";function Ns({ref:e,onIntersect:t,isDisabled:o,threshold:r,rootMargin:a,root:i}){let n=to__default.default.useRef(null);to.useEffect(()=>{if(o){n.current?.disconnect(),n.current=null;return}n.current=new IntersectionObserver(([l])=>{t(l);},{root:i?.current,rootMargin:a,threshold:r});},[t,o,i,a,r]),to.useEffect(()=>{let{current:l}=n;return e.current&&l?.observe(e.current),()=>l?.disconnect()},[e]);}function Ss({ref:e,onResize:t,isDisabled:o}){let r=to__default.default.useRef(null),[a,i]=to__default.default.useState();return to__default.default.useEffect(()=>{if(o){r.current?.disconnect(),r.current=null;return}r.current=new ResizeObserver(([n])=>{i(n.contentRect),t?.(n);});},[t,o,i]),to__default.default.useEffect(()=>{let{current:n}=r;return e.current&&n?.observe(e.current),()=>n?.disconnect()},[e]),{size:a}}function bo({src:e,alt:t}){let[o,r]=to.useState(!1),[a,i]=to.useState(!1),[n,l]=to.useState(!1),s=()=>{r(!0),l(!1);},p=()=>{i(!0),l(!1);};return to.useEffect(()=>{if(!e)return;l(!0);let d=new Image;return d.src=e,d.addEventListener("load",s),d.addEventListener("error",p),()=>{d.removeEventListener("load",s),d.removeEventListener("error",p);}},[e]),{isLoaded:o,hasError:a,isLoading:n,imgProps:{src:o?e:void 0,alt:t}}}function Fe(){let e=to.useRef(!0);return to.useEffect(()=>{e.current=!1;},[]),e.current}var Ls="SET_STATE",er="UNDO",or="REDO",ab=(e,t)=>{let{past:o,present:r,future:a}=e;switch(t.type){case Ls:return {past:[...o,r],present:t.data,future:[]};case er:return {past:o.slice(0,o?.length-1),present:o[o?.length-1],future:[r,...a]};case or:return {past:[...o,r],present:a[0],future:a.slice(1)};default:throw new Error("Invalid action type")}},Ms=(e={},{isDisabled:t,onAction:o})=>{let r=Fe(),[a,i]=to.useReducer(ab,{past:[],present:e,future:[]}),{past:n,present:l,future:s}=a,p=y=>{i({type:Ls,data:y});},d=to.useRef(),u=()=>{d.current=er,i({type:er});},c=()=>{d.current=or,i({type:or});},m=!!n?.length,f=!!s?.length;return granularHooks.useGranularEffect(()=>{(d.current===er||d.current===or)&&(o?.(l,d.current),d.current=void 0);},[l],[o,r]),{state:l,push:t?()=>{}:p,undo:t?()=>{}:u,redo:t?()=>{}:c,pastStates:n,futureStates:s,canUndo:m,canRedo:f}};var Ta=to__default.default.createContext({messages:{}}),Es=({children:e,messages:t={},...o})=>{let r=to__default.default.useMemo(()=>({messages:t}),[t]);return jsxRuntime.jsx(reactAria.I18nProvider,{...o,children:jsxRuntime.jsx(Ta.Provider,{value:r,children:e})})};Es.displayName="I18nProvider";function B(e){let{messages:t}=to.useContext(Ta);!e&&sb__default.default(t)&&console.warn("BUI \u{1F30D}: No messages object provided and no messages found in the `I18nProvider`. Please provide a messages object to the `useI18n` hook.");let o=reactAria.useMessageFormatter(e?utils.cleanKeyFromGlobImport(e):t),r=reactAria.useLocale();return {formatMessage:(a,i)=>{if(typeof a=="object")try{return o(a.id,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.id.toString()}\`. The default message, i.e. \`${a.defaultMessage}\`, will be used instead.`),a.defaultMessage||a.id}else try{return o(a,i)}catch{return console.log(`BUI \u{1F30D}: Translation not found for key: \`${a.toString()}\`. The default message, i.e. \`${a.toString()}\`, will be used instead.`),a}},locale:r}}var j=e=>e;function wN(e,t,o){let r=to__default.default.useRef(null);return to__default.default.useEffect(()=>{if(e)return r.current=new MutationObserver(o),r.current.observe(e,t),()=>{r.current&&r.current.disconnect();}},[e,t,o]),r.current}function Hs(e,t){let[o,r]=to.useState(()=>{try{let i=window.localStorage.getItem(e);return i?JSON.parse(i):t}catch(i){return console.log(i),t}});return [o,i=>{try{let n=i instanceof Function?i(o):i;r(n),window.localStorage.setItem(e,JSON.stringify(n));}catch(n){console.log(n);}}]}function MN({ref:e,onSelectionChange:t,onSelectionEnd:o,isDisabled:r}){let a=to__default.default.useRef(null);reactAria.usePress({ref:e,isDisabled:r,onPressEnd(){let n=Q(e.current).getSelection();n&&e.current?.contains(n.anchorNode)&&o?.(n);},onPressStart(){let i=Q(e.current);a.current=i.getSelection(),a.current&&a.current.removeAllRanges();}}),to.useEffect(()=>{let i=e.current;if(!i||r)return;function n(){let p=Q(i).getSelection();p&&e.current?.contains(p.anchorNode)&&t(p);}let l=ge(i);return l.addEventListener("selectionchange",n),()=>{l.removeEventListener("selectionchange",n);}},[e,t,r]);}function go(e){let t=to.useCallback(()=>{let a=Q(e??document.body),i=a.matchMedia(tokens.queries.tablet);return a.matchMedia(tokens.queries.desktop).matches?"desktop":i.matches?"tablet":"mobile"},[e]),[o,r]=to__default.default.useState(t);return we(()=>{let a=Q(e),i=()=>{r(t());};return a.addEventListener("resize",i),i(),()=>{a.removeEventListener("resize",i);}},[e,t]),o}var Na=to__default.default.createContext(void 0),Vs=({portalContainer:e,children:t})=>jsxRuntime.jsx(Na.Provider,{value:e,children:t});Vs.displayName="PortalContainerProvider";function de(e){let t=to.useContext(Na);return e||t}var Pb=["append","prepend","insert","insertBefore","insertAfter","remove","removeSelectedItems","move","moveBefore","moveAfter","update"];function js(e){let{onListChange:t,onSelectionChange:o,...r}=e,a=reactStately.useListData({...r,initialItems:e.initialItems||[]}),i=to.useRef(e.initialItems),n=to.useCallback(()=>{t&&t(a.items);},[t,a.items]),l=to.useCallback(()=>{o&&o(a.selectedKeys);},[o,a.selectedKeys]),s=to.useCallback(d=>e.getKey?e.getKey(d):d.id||d.key,[e]);granularHooks.useGranularEffect(n,[a.items,e.initialItems],[n]),granularHooks.useGranularEffect(l,[a.selectedKeys,e.initialItems],[l]),to.useEffect(()=>{let d=(y,g)=>y.filter(v=>!g.some(b=>vo__default.default(v,b))),u=(y,g)=>g.filter(v=>!y.some(b=>vo__default.default(v,b))),c=y=>{y.length>0&&a.remove(...y.map(g=>s(g)));},m=(y,g)=>{if(y.length>0){let v=g.findIndex(b=>y.some(h=>vo__default.default(b,h)));if(v===0)a.prepend(...y);else if(v>0){let b=g[v-1],h=a.items.findIndex(z=>vo__default.default(z,b));a.insertAfter(s(a.items[h]),...y);}else a.append(...y);}},f=y=>{for(let[g,v]of y.entries()){let b=a.items.findIndex(h=>vo__default.default(h,v));b!==-1&&b!==g&&a.move(s(a.items[b]),g);}};if(!vo__default.default(i.current,e.initialItems)){let y=a.items,g=e.initialItems||[],v=d(y,g);c(v);let b=u(y,g);m(b,g),f(g),i.current=g;}},[e.initialItems,a,s]);let p=to.useMemo(()=>{let d={};for(let u of Pb)d[u]=(...c)=>{let m=a[u](...c);return n(),(u==="remove"||u==="removeSelectedItems")&&l(),m};return d},[a,n,l]);return {...a,...p}}function La(e=window){let[t,o]=to.useState("light"),[r,a]=to.useState(!1),[i,n]=to.useState(!1),[l,s]=to.useState(!1);return to.useEffect(()=>{let p=e.matchMedia("(prefers-color-scheme: dark)"),d=u=>{o(u.matches?"dark":"light");};return p.matches&&o("dark"),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),to.useEffect(()=>{let p=e.matchMedia("(prefers-contrast: more)"),d=u=>{a(u.matches);};return a(p.matches),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),to.useEffect(()=>{let p=e.matchMedia("(prefers-reduced-motion: reduce)"),d=u=>{n(u.matches);};return p.matches&&n(!0),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),to.useEffect(()=>{let p=e.matchMedia("(prefers-reduced-transparency: reduce)"),d=u=>{s(u.matches);};return p.matches&&s(!0),p.addEventListener("change",d),()=>{p.addEventListener("change",d);}},[e]),{colorScheme:t,highContrast:r,reducedMotion:i,transparency:l}}var _o=to.createContext({theme:tokens.lightTheme,setTheme:()=>{}});var $s="var(--hj25q10)";var ar={LIGHT:{name:"light",theme:tokens.lightTheme},DARK:{name:"dark",theme:tokens.darkTheme}},zo=to__default.default.forwardRef(({theme:e="system",children:t,setTheme:o,className:r,style:a,UNSAFE_domProps:i,"data-block-id":n},l)=>{let{direction:s}=reactAria.useLocale(),{colorScheme:p,reducedMotion:d,highContrast:u,transparency:c}=La(),{name:m,theme:f}=to.useMemo(()=>{switch(e){case"system":return p==="light"?ar.LIGHT:ar.DARK;case"light":return ar.LIGHT;case"dark":return ar.DARK;default:return {name:"custom",theme:e}}},[p,e]),y=go(),g={"data-theme":m,"data-block-id":n,"data-reduced-motion":d,"data-high-contrast":u,"data-transparency":c,"data-device":y},v=to.useMemo(()=>({theme:f,setTheme:o}),[f,o]);return jsxRuntime.jsx(_o.Provider,{value:v,children:jsxRuntime.jsx("div",{...reactAria.mergeProps(i,g),className:utils.classNames(Wt,"BaselineUI-ThemeProvider",r),style:{...dynamic.assignInlineVars(tokens.themeVars,f),...dynamic.assignInlineVars({[$s]:s==="rtl"?"-1":"1"}),...a},ref:l,children:t})})});zo.displayName="ThemeProvider";var Gs=_({defaultClassName:"_1mdhlqv3",variantClassNames:{isOpen:{true:"_1mdhlqv4"}},defaultVariants:{},compoundVariants:[]}),ir="_1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Ws=_({defaultClassName:"_1mdhlqv0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6eu _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy",variantClassNames:{isFocused:{false:"_1mdhlqv1"},isDisabled:{true:"z9nup83 _1yep5z6ey"}},defaultVariants:{},compoundVariants:[]}),Xs="_1mdhlqv7 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs",Ys="_1yep5z66x _1yep5z66y _1yep5z66z",Zs="_1mdhlqv5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k";var ho=to__default.default.forwardRef(({className:e,style:t,children:o,...r},a)=>{let{theme:i}=to.useContext(_o);return jsxRuntime.jsx(reactAria.Overlay,{...r,children:jsxRuntime.jsx(zo,{ref:a,theme:i,style:t,className:utils.classNames("BaselineUI-Portal",e),children:o})})});ho.displayName="Portal";function Js({placement:e}){let t=web.useReducedMotion();return web.useTransition(!0,{from:{opacity:0,transform:`translate3d(${e==="bottom"?"0, 4px, 0":"0, -4px, 0"})`},enter:{opacity:1,transform:"translate3d(0, 0, 0)"},immediate:!!t,config:web.config.stiff})}var{color:Ma}=tokens.themeVars,le=to__default.default.forwardRef(({className:e,style:t,state:o,overlayProps:r,underlayClassName:a,children:i,includeArrow:n=!1,offset:l=2,portalContainer:s,contentContainerClassName:p,contentContainerStyle:d,...u},c)=>{let m=to__default.default.useRef(null),f=de(s),y=n?8:0,{underlayProps:g,popoverProps:v,placement:b,arrowProps:h}=reactAria.usePopover({...u,offset:l+y,popoverRef:m,containerPadding:u.containerPadding||0},o),z=Js({placement:b}),x=b==="center"?"bottom":b;return z((R,C)=>C&&jsxRuntime.jsxs(ho,{portalContainer:f,style:t,ref:c,children:[!u.isNonModal&&jsxRuntime.jsx("div",{...g,className:utils.classNames(Kn,a,"BaselineUI-Popover-Underlay")}),jsxRuntime.jsxs(web.animated.div,{...v,style:{...v.style,...R,...dynamic.assignInlineVars({[Gn]:`${u.triggerRef?.current?.offsetWidth}px`})},ref:N(m,c),className:utils.classNames($n,"BaselineUI-Popover-Content",e),"data-placement":["top","bottom","left","right"].filter(P=>b?.includes(P)),children:[n?jsxRuntime.jsxs("svg",{className:utils.classNames(jn[x],"BaselineUI-PopoverContent-Arrow"),...h,style:{...h.style,position:"absolute"},width:"15",height:"9",viewBox:"0 0 15 9",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M.019 0h1.228l6.272 7.237L13.791 0h1.228v1h-.772L7.519 8.763.791 1H.019V0Z",fill:Ma.border.medium}),jsxRuntime.jsx("path",{d:"M7.504 6.492 2.248.488h10.511L10.132 3.49 7.504 6.492Z",fill:Ma.background.primary.subtle,stroke:Ma.background.primary.subtle})]}):null,jsxRuntime.jsx(reactAria.DismissButton,{onDismiss:o.close}),jsxRuntime.jsx("div",{...r,style:d,className:utils.classNames(Un,p),children:i}),jsxRuntime.jsx(reactAria.DismissButton,{onDismiss:o.close})]})]}))});le.displayName="PopoverContentCore";var tl="xyd2ss1 _1yep5z613 _1yep5z614 _1yep5z615 _1yep5z63f _1yep5z63g _1yep5z63h _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b _1yep5z65r _1yep5z65s _1yep5z65t _1yep5z683 _1yep5z684 _1yep5z685 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z66x _1yep5z66y _1yep5z66z _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6l0 _1yep5z6kz _1yep5z6he _1yep5z6l3 _1yep5z6fs",rl="xyd2ss0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z64l _1yep5z64m _1yep5z64n _1yep5z629 _1yep5z62a _1yep5z62b";var Ba=({section:e,showSelectedIcon:t,state:o})=>{let{itemProps:r,groupProps:a,headingProps:i}=reactAria.useMenuSection({heading:e.value?.title,"aria-label":e["aria-label"]});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[e.key!==o.collection.getFirstKey()&&jsxRuntime.jsx(F,{elementType:"li"}),jsxRuntime.jsxs("li",{...r,children:[e.value?.title?jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("span",{...i,children:e.value.title})}):null,jsxRuntime.jsx("ul",{...a,className:rl,children:[...e.childNodes].map(n=>(utils.invariant(n.type==="item"),jsxRuntime.jsx(sr,{item:n,state:o,showSelectedIcon:t},n.key)))})]})]})};Ba.displayName="MenuSection";var sr=({item:e,state:t,className:o,showSelectedIcon:r})=>{let a=to__default.default.useRef(null),i=reactAria.useMenuItem({key:e.key},t,a),{isFocusVisible:n,focusProps:l}=reactAria.useFocusRing();return jsxRuntime.jsx(Wo,{item:e,liProps:reactAria.mergeProps(i.menuItemProps,l,{className:o}),...i,isFocusVisible:n,ref:a,description:e.value?.keyboardShortcut,descriptionProps:i.keyboardShortcutProps,_state:t,showSelectedIcon:r})};sr.displayName="MenuItem";var Fa=to__default.default.forwardRef(({className:e,itemClassName:t,onContentKeyDown:o,...r},a)=>{let i=reactStately.useTreeState(r),n=to__default.default.useRef(null),{menuProps:l}=reactAria.useMenu(r,i,n),{keyboardProps:s}=reactAria.useKeyboard({onKeyDown:o});return jsxRuntime.jsx("ul",{...reactAria.mergeProps(l,s),className:utils.classNames(tl,e),ref:N(n,a),children:[...i.collection].map(p=>p.type==="section"?jsxRuntime.jsx(Ba,{section:p,state:i,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},p.key):jsxRuntime.jsx(sr,{item:p,state:i,className:t,showSelectedIcon:r.selectionMode==="multiple"||r.selectionMode==="single"},p.key))})});Fa.displayName="MenuContent";var lr=to__default.default.forwardRef(({defaultOpen:e,onOpenChange:t,isOpen:o,isDisabled:r,contentClassName:a,placement:i="bottom start",isNonModal:n,shouldFlip:l,shouldUpdatePosition:s,boundaryElement:p,crossOffset:d,offset:u,triggerLabel:c,renderTrigger:m=({buttonProps:v,ref:b})=>jsxRuntime.jsx(O,{...v,variant:"popover",ref:b}),portalContainer:f,...y},g)=>{let v=to__default.default.useRef(null),b=de(f),h=reactStately.useMenuTriggerState({defaultOpen:e,isOpen:o,onOpenChange:t}),{menuTriggerProps:z,menuProps:x}=reactAria.useMenuTrigger({isDisabled:r,type:"menu"},h,v),R=se(),C=to.useMemo(()=>reactAria.mergeProps(z,{isDisabled:r,isSelected:h.isOpen,className:"BaselineUI-Menu-Trigger",label:c}),[z,r,h.isOpen,c]);return to.useEffect(()=>{!c&&!m&&console.warn("The `triggerLabel` prop is required when no `renderTrigger` or `children` is provided.");},[m,c]),jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[m({buttonProps:C,ref:v}),h.isOpen?jsxRuntime.jsx(le,{triggerRef:v,state:h,placement:i,isNonModal:n,shouldFlip:l,shouldUpdatePosition:s,boundaryElement:p,crossOffset:d,offset:u||2,className:utils.classNames(ir,"BaselineUI-Menu-Popover"),portalContainer:b,children:jsxRuntime.jsx(Fa,{className:a,...x,...y,ref:g,autoFocus:h.focusStrategy||"first",children:R})}):null]})});lr.displayName="Menu";var pr=_({defaultClassName:"_13f0naj0",variantClassNames:{variant:{default:"_13f0naj1",inline:"_13f0naj2"},isHovered:{true:"_13f0naj3"},isFocusVisible:{true:"_13f0naj4"},isDisabled:{true:"_13f0naj5"},size:{sm:"_13f0naj6",md:"_13f0naj7",lg:"_13f0naj8"},type:{body:"_13f0naj9",label:"_13f0naja"},isActive:{true:"_13f0najb"}},defaultVariants:{},compoundVariants:[[{isActive:!0,isDisabled:!1},"_13f0najc"],[{type:"body",size:"sm"},"_13f0najd"],[{type:"body",size:"md"},"_13f0naje"],[{type:"body",size:"lg"},"_13f0najf"],[{type:"label",size:"sm"},"_13f0najg"],[{type:"label",size:"md"},"_13f0najh"],[{type:"label",size:"lg"},"_13f0naji"]]});var ll=to__default.default.forwardRef(({className:e,style:t,children:o,variant:r="default",size:a="md",elementType:i="a",type:n="body","data-block-id":l,title:s,...p},d)=>{let u=to__default.default.useRef(null),{linkProps:c,isPressed:m}=reactAria.useLink({...p,elementType:p.onPress?"span":i},u),{isFocusVisible:f,isFocused:y,focusProps:g}=reactAria.useFocusRing(),{hoverProps:v,isHovered:b}=reactAria.useHover({isDisabled:p.isDisabled}),h=i,z=utils.filterTruthyValues({"data-block-id":l,"data-disabled":p.isDisabled,"data-focused":y,"data-pressed":m,"data-focus-visible":f,"data-hovered":b,title:s});return jsxRuntime.jsx(h,{...reactAria.mergeProps(c,g,v,z),className:utils.classNames(pr({variant:r,isFocusVisible:f,isHovered:b,isDisabled:p.isDisabled,size:a,isActive:m,type:n}),"BaselineUI-Link",e),ref:N(u,d),style:t,children:o})});ll.displayName="Link";function pl({isDisabled:e,onValueChange:t,onChange:o,name:r,"aria-describedby":a,"aria-label":i,accept:n,multiple:l}){let s=reactAria.useId(),p=reactAria.useId(),d=reactAria.useId();return {inputProps:{type:"file",id:p,disabled:!!e,"aria-labelledby":i?void 0:s,"aria-describedby":a||d,"aria-label":i,onChange:c=>{let m=[...c.target.files||[]];t?.(m),o?.(c);},name:r,accept:n,multiple:l},labelProps:{htmlFor:p,id:s},descriptionProps:{id:d}}}async function Va({items:e}){let t=e.filter(o=>o.kind==="file").map(async o=>(utils.invariant(o.kind==="file"),o.getFile()));return await Promise.all(t)}var cl=_({defaultClassName:"_180w5ed0",variantClassNames:{variant:{default:"_180w5ed1",inline:"_180w5ed2"},hoveredOrFocusedOrActive:{true:"_180w5ed3"},disabled:{true:"_180w5ed4"}},defaultVariants:{},compoundVariants:[[{variant:"inline",hoveredOrFocusedOrActive:!0},"_180w5ed5"],[{variant:"default",hoveredOrFocusedOrActive:!0},"_180w5ed6"],[{variant:"default",disabled:!0},"_180w5ed7"],[{variant:"inline",disabled:!0},"_180w5ed8"]]}),dl=_({defaultClassName:"_180w5ede",variantClassNames:{disabled:{true:"_180w5edf"}},defaultVariants:{},compoundVariants:[]}),ml=_({defaultClassName:"_180w5ed9",variantClassNames:{disabled:{true:"_180w5eda"}},defaultVariants:{},compoundVariants:[]}),ul=_({defaultClassName:"_180w5edb",variantClassNames:{disabled:{true:"_180w5edc"},hovered:{true:"_180w5edd"}},defaultVariants:{},compoundVariants:[]});var gl=to__default.default.forwardRef(({className:e,label:t,description:o,icon:r,variant:a="default",...i},n)=>{let l=to__default.default.useRef(null),{inputProps:s,descriptionProps:p,labelProps:d}=pl(i),{dropProps:u}=reactAria.useDrop({ref:l,onDrop:async({items:g})=>{let v=g.filter(h=>h.kind==="file").map(async h=>(utils.invariant(h.kind==="file"),h.getFile())),b=await Promise.all(v);i.onValueChange?.(b);}}),{focusProps:c,isFocusVisible:m}=reactAria.useFocusRing(),{hoverProps:f,isHovered:y}=reactAria.useHover({isDisabled:i.isDisabled});return jsxRuntime.jsxs("label",{...reactAria.mergeProps(u,f,d),className:utils.classNames(cl({variant:a,disabled:i.isDisabled,hoveredOrFocusedOrActive:y||m}),e),ref:N(n,l),children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(c,s)})}),r?jsxRuntime.jsx(r,{size:20,className:ml({disabled:i.isDisabled})}):null,jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("div",{className:ul({disabled:i.isDisabled,hovered:y}),children:t}),o?jsxRuntime.jsx("div",{...p,className:dl({disabled:i.isDisabled}),children:o}):null]})]})});gl.displayName="FileUpload";var vl="_12vfhl40 z9nup81",_l="_12vfhl41 z9nup82",zl=_({defaultClassName:"_12vfhl48",variantClassNames:{variant:{success:"_12vfhl49",error:"_12vfhl4a",active:"_12vfhl4b"}},defaultVariants:{},compoundVariants:[]}),hl="_12vfhl42",xl="_12vfhl47",Cl="_12vfhl46 z9nup82",Pl="_12vfhl45",kl=_({defaultClassName:"_12vfhl43 _12vfhl42",variantClassNames:{hasLabel:{false:"_12vfhl44"}},defaultVariants:{},compoundVariants:[]});var wl=to__default.default.forwardRef(({className:e,variant:t="active",showValue:o,description:r,errorMessage:a,...i},n)=>{let l=reactAria.useId(),{labelProps:s,progressBarProps:p}=reactAria.useProgressBar({...i,"aria-describedby":r?l:i["aria-describedby"]}),{minValue:d=0,maxValue:u=100,value:c=0,label:m}=i,f=(c-d)/(u-d),y=`${Math.round(f*100)}%`,g=jsxRuntime.jsx("output",{className:kl({hasLabel:!!m}),children:p["aria-valuetext"]}),v=t==="error"?a:r;return jsxRuntime.jsxs("div",{...p,className:utils.classNames(vl,e),ref:n,children:[m?jsxRuntime.jsxs("div",{className:_l,children:[jsxRuntime.jsx("label",{...s,className:hl,children:m}),o?g:null]}):null,jsxRuntime.jsxs("div",{className:Pl,children:[jsxRuntime.jsxs("div",{className:Cl,children:[jsxRuntime.jsx("div",{className:xl,children:jsxRuntime.jsx("div",{style:{width:y},className:zl({variant:t})})}),!m&&o?g:null]}),v?jsxRuntime.jsx("div",{className:co({hasError:t==="error"}),id:l,children:v}):null]})]})});wl.displayName="ProgressBar";function Po({isReadOnly:e,validationState:t}){return e?_16.ReadOnlyIcon:t==="error"?_16.ErrorFilledIcon:t==="warning"?_16.WarningFilledIcon:null}var ko=to__default.default.forwardRef(({className:e,validationState:t,variant:o="primary",style:r,labelPosition:a="top",inputStyle:i,inputClassName:n,"data-block-id":l,...s},p)=>{let d=to__default.default.useRef(null),{inputProps:u,labelProps:c,descriptionProps:m,errorMessageProps:f,validationErrors:y}=reactAria.useTextField({...s,validationState:t?t==="error"?"invalid":"valid":void 0},d),g=s.errorMessage||y.join(" "),v=_e({...s,errorMessage:g,descriptionProps:m,errorMessageProps:f,labelPosition:a});g&&(t="error");let{hoverProps:b,isHovered:h}=reactAria.useHover({isDisabled:s.isDisabled}),{isFocused:z,focusProps:x,isFocusVisible:R}=reactAria.useFocusRing(),C=Po({isReadOnly:s.isReadOnly,validationState:t}),P=utils.filterTruthyValues({"data-readonly":s.isReadOnly,"data-disabled":s.isDisabled,"data-validation-state":t,"data-focused":z,"data-focus-visible":R});return jsxRuntime.jsxs("div",{className:utils.classNames(Be({labelPosition:a}),"BaselineUI-TextInput",e),"data-block-id":l,style:r,ref:p,children:[s.label||a==="start"&&v?jsxRuntime.jsxs("div",{className:De({labelPosition:a,hasMessage:!!v}),children:[jsxRuntime.jsx("label",{...c,className:Me,children:s.label}),a==="start"&&v]}):null,jsxRuntime.jsxs("div",{className:utils.classNames({[po]:s.isDisabled}),children:[jsxRuntime.jsxs("div",{...b,className:uo({validationState:t,isHovered:h,isFocused:z,variant:o,isReadOnly:!!s.isReadOnly,isDisabled:!!s.isDisabled}),children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(u,x,P),className:utils.classNames(Xt({isDisabled:s.isDisabled,labelPosition:a}),"BaselineUI-TextInput-Input",n),style:i,ref:d}),C?jsxRuntime.jsx(C,{className:mo({validationState:t,isReadOnly:s.isReadOnly}),size:16}):null]}),a==="top"&&v]})]})});ko.displayName="TextInput";var wo=({value:e,...t})=>{let o=reactAria.useNumberFormatter(t);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:o.format(e)})};wo.displayName="NumberFormat";var Il="_1yep5z6i3 _1yep5z6i4 _1yep5z6i5",Tl=_({defaultClassName:"_9b1tml0",variantClassNames:{isSelected:{true:"_9b1tml1",false:"_9b1tml2"},isDisabled:{true:"z9nup83"},isHovered:{true:"_9b1tml4"},isFocusVisible:{true:"_9b1tml5"},isReadOnly:{true:"_9b1tml6"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0,isReadOnly:!1},"_9b1tml7"],[{isSelected:!0,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml8"],[{isSelected:!1,isHovered:!0,isDisabled:!1,isReadOnly:!1},"_9b1tml9"],[{isSelected:!0,isDisabled:!0},"_9b1tmla"],[{isSelected:!0,isReadOnly:!0},"_9b1tmlb"]]}),Nl=_({defaultClassName:"_9b1tmlf",variantClassNames:{isSelected:{true:"_9b1tmlg"},size:{sm:"_9b1tmlh",md:"_9b1tmli"},isDisabled:{true:"_9b1tmlj"},isReadOnly:{true:"_9b1tmlk"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1,isReadOnly:!1},"_9b1tmll"],[{isSelected:!0,isDisabled:!0},"_9b1tmlm"],[{isSelected:!1,isDisabled:!0},"_9b1tmln"]]}),Sl=_({defaultClassName:"_9b1tmlc",variantClassNames:{isDisabled:{true:"_9b1tmld"},isReadOnly:{true:"_9b1tmle"}},defaultVariants:{},compoundVariants:[]});var Dl=to__default.default.forwardRef(({className:e,count:t,style:o,size:r="md",icon:a,...i},n)=>{let l={isRequired:!1},s=a||(r==="md"?_20.CheckmarkIcon:_16.CheckmarkIcon);!i["aria-label"]&&!i["aria-labelledby"]&&console.warn("You must provide either an `aria-label` or `aria-labelledby` prop to the `Reaction` component.");let p=to__default.default.useRef(null),d=reactStately.useToggleState({...i,...l}),{inputProps:u,isPressed:c,isDisabled:m,isReadOnly:f,isSelected:y}=reactAria.useSwitch({...i,...l},d,p),{focusProps:g,isFocused:v,isFocusVisible:b}=reactAria.useFocusRing(),{hoverProps:h,isHovered:z}=reactAria.useHover({});return jsxRuntime.jsxs("label",{ref:n,style:o,className:utils.classNames(Il,"BaselineUI-Reaction",e),"data-block-id":i["data-block-id"],"data-focused":v,"data-focus-visible":b,"data-disabled":m,"data-hovered":z,"data-pressed":c,"data-selected":y,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...u,...g,ref:p})}),jsxRuntime.jsxs("div",{...h,className:Tl({isSelected:y,isFocusVisible:b,isHovered:z,isReadOnly:f,isDisabled:m}),children:[jsxRuntime.jsx("div",{className:Sl({isDisabled:m,isReadOnly:f}),children:jsxRuntime.jsx(s,{size:r==="md"?20:16})}),jsxRuntime.jsx("div",{className:Nl({isSelected:d.isSelected,isDisabled:m,isReadOnly:f,size:r}),children:jsxRuntime.jsx(wo,{value:t})})]})]})});Dl.displayName="Reaction";var Bl=_({defaultClassName:"_1jwycy80",variantClassNames:{placement:{bottom:"_1jwycy81",left:"_1jwycy82",right:"_1jwycy83",top:"_1jwycy84"},variant:{default:"_1jwycy85",inverse:"_1jwycy86"}},defaultVariants:{},compoundVariants:[]}),El=_({defaultClassName:"_1jwycy87 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn",variantClassNames:{size:{md:"_1yep5z63u _1yep5z63v _1yep5z63w _1yep5z61i _1yep5z61j _1yep5z61k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6e7",sm:"_1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6dv"},variant:{default:"_1yep5z6g0 _1yep5z6ez",inverse:"_1yep5z6d7 _1yep5z6fs _1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var $a=to__default.default.forwardRef(({children:e,state:t,overlayProps:o,arrowProps:r,placement:a,variant:i,size:n,tooltipProps:l,includeArrow:s},p)=>{let{tooltipProps:d}=reactAria.useTooltip({isOpen:t.isOpen},t),u=to.useMemo(()=>{switch(a){case"top":return {x:0,y:4};case"bottom":return {x:0,y:-4};case"left":return {x:4,y:0};case"right":return {x:-4,y:0};default:return {x:0,y:0}}},[a]),c=web.useReducedMotion(),[m]=web.useSpring(()=>({from:{opacity:0,transform:`translate(${u.x}px, ${u.y}px)`},to:{opacity:1,transform:"translate(0, 0)"},immediate:!!c})),f=a==="center"?"bottom":a;return jsxRuntime.jsxs(web.animated.span,{...o,style:{...m,...o.style},ref:p,"data-placement":f,children:[s?jsxRuntime.jsx("div",{className:Bl({placement:f,variant:i}),...r}):null,jsxRuntime.jsx("div",{...reactAria.mergeProps(d,l),className:El({variant:i,size:n}),children:e})]})});$a.displayName="TooltipContent";var He=to__default.default.forwardRef(({children:e,placement:t="bottom",delay:o=1e3,closeDelay:r=500,variant:a="default",size:i="md",includeArrow:n=!0,portalContainer:l,...s},p)=>{let d=to__default.default.useRef(null),u=to__default.default.useRef(null),c=!s.text||s.isDisabled,m=reactStately.useTooltipTriggerState({...s,delay:o,closeDelay:r,isDisabled:c}),{triggerProps:f,tooltipProps:y}=reactAria.useTooltipTrigger({...s,isDisabled:c,delay:o,closeDelay:r},m,d),g=de(l),{overlayProps:v,arrowProps:b,placement:h,updatePosition:z}=reactAria.useOverlayPosition({arrowSize:n?13:0,targetRef:d,arrowBoundaryOffset:n?8:0,offset:n?12:2,overlayRef:u,placement:t,isOpen:m.isOpen,...s});return Ns({ref:u,threshold:1,onIntersect:z,isDisabled:!m.isOpen}),Ss({ref:d,onResize:z,isDisabled:!m.isOpen}),jsxRuntime.jsxs(focus.FocusableProvider,{...f,ref:d,children:[e,m.isOpen?jsxRuntime.jsx(ho,{disableFocusManagement:!0,portalContainer:g,children:jsxRuntime.jsx($a,{ref:N(p,u),state:m,arrowProps:b,overlayProps:v,placement:h,tooltipProps:y,variant:a,size:i,includeArrow:n,children:s.text})}):null]})});He.displayName="Tooltip";var Ol="_1azy5686",Vl="_1azy5685",Al="var(--_1azy5680)",jl="_1azy5688",$l="_1azy5689",Ul="_1azy5681 z9nup82",ql="_1azy5682";var Kl="_1azy5687";var bv={sm:16,md:20},gv={sm:[_16.CheckFilledIcon,_16.ErrorAltFilledIcon],md:[_20.CheckFilledIcon,_20.ErrorAltFilledIcon]},Io=to__default.default.forwardRef(({className:e,style:t,size:o="md",variant:r="active",...a},i)=>{let{labelProps:n,progressBarProps:l}=reactAria.useProgressBar({...a,isIndeterminate:!0}),s=bv[o],p=s/2-2,d=2*p*Math.PI,u=gv[o][r==="success"?0:1];return jsxRuntime.jsxs("div",{className:utils.classNames(Ul,e),ref:i,style:{...dynamic.assignInlineVars({[Al]:`${d}px`}),...t},children:[jsxRuntime.jsxs("div",{...l,className:ql,children:[(r==="active"||r==="inactive")&&jsxRuntime.jsxs("svg",{height:s,width:s,viewBox:`0 0 ${s} ${s}`,children:[jsxRuntime.jsx("circle",{role:"presentation",className:Ol,cx:s/2,cy:s/2,r:p}),r==="active"&&jsxRuntime.jsx("circle",{role:"presentation",className:Vl,cx:s/2,cy:s/2,r:p})]}),r==="success"&&jsxRuntime.jsx(u,{className:Kl,size:s}),r==="error"&&jsxRuntime.jsx(u,{className:jl,size:s})]}),a.label?jsxRuntime.jsx("span",{...n,className:$l,children:a.label}):null]})});Io.displayName="ProgressSpinner";var Gl=_({defaultClassName:"_5uw3kp0 oom8bs0 z9nup82",variantClassNames:{isHovered:{true:"_5uw3kp1"},isFocusVisible:{true:"_5uw3kp2"},isDisabled:{true:"_5uw3kp3"},isSelected:{true:"_5uw3kp4"},size:{sm:"_5uw3kp5",md:"_5uw3kp6",lg:"_5uw3kp7"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isFocusVisible:!0},"_5uw3kp8"],[{isSelected:!0,isDisabled:!0},"_5uw3kp9"]]});var kv={sm:16,md:20,lg:24},mr=to__default.default.forwardRef(({className:e,style:t,iconStart:o,size:r="md",elementType:a="button",...i},n)=>{let l=reactStately.useToggleState(i),{buttonProps:s,isPressed:p,ref:d}=Kt(i,l),{hoverProps:u,isHovered:c}=reactAria.useHover({isDisabled:i.isDisabled}),{isFocusVisible:m,isFocused:f,focusProps:y}=reactAria.useFocusRing(),g=utils.filterTruthyValues({"data-block-id":i["data-block-id"],"data-focused":f,"data-focus-visible":m,"data-disabled":i.isDisabled,"data-hovered":c,"data-pressed":p,"data-selected":l.isSelected});return jsxRuntime.jsxs(a,{...reactAria.mergeProps(s,u,y,g),className:utils.classNames(Gl({isHovered:c,isFocusVisible:m,isSelected:l.isSelected,size:r,isDisabled:i.isDisabled}),"BaselineUI-ToggleButton",e),style:t,ref:N(d,n),children:[o?jsxRuntime.jsx(o,{size:kv[r]}):null,i.label]})});mr.displayName="ToggleButton";var ur=_({defaultClassName:"_16vugd0e",variantClassNames:{isDisabled:{true:"_16vugd0f"}},defaultVariants:{},compoundVariants:[]}),Wl=_({defaultClassName:"_16vugd01 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),Xl=_({defaultClassName:"_16vugd05",variantClassNames:{isIndeterminate:{true:"_16vugd04"},isSelected:{true:"_16vugd04"},isFocusVisible:{true:"_16vugd08"},isHovered:{true:"_16vugd09"},isDisabled:{true:"_16vugd0a"},isReadOnly:{true:"_16vugd0b"},hasError:{true:"_16vugd0c"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_16vugd0d"]]});var Ql=to__default.default.forwardRef(({className:e,style:t,label:o,labelPosition:r="end","data-block-id":a,...i},n)=>{let l=to__default.default.useRef(null),s=reactStately.useToggleState(i),{isFocusVisible:p,isFocused:d,focusProps:u}=reactAria.useFocusRing(),{inputProps:c,isPressed:m,isDisabled:f,isSelected:y,isReadOnly:g}=reactAria.useCheckbox({...i,children:o},s,l),{hoverProps:v,isHovered:b}=reactAria.useHover({isDisabled:f}),h=utils.filterTruthyValues({"data-disabled":f,"data-readonly":g,"data-hovered":b,"data-selected":y,"data-pressed":m,"data-indeterminate":i.isIndeterminate,"data-invalid":i.isInvalid,"data-focus-visible":p,"data-focused":d,"data-block-id":a});return jsxRuntime.jsxs("label",{...h,className:utils.classNames(Wl({labelPosition:r}),"BaselineUI-Checkbox",e),style:t,ref:n,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(c,u),ref:l})}),jsxRuntime.jsxs("div",{...v,className:Xl({isSelected:y&&!i.isIndeterminate,isIndeterminate:i.isIndeterminate,isFocusVisible:p,isDisabled:f,isReadOnly:g,hasError:i.isInvalid,isHovered:b}),children:[y&&!i.isIndeterminate?jsxRuntime.jsx(_12.CheckmarkIcon,{size:12}):null,i.isIndeterminate?jsxRuntime.jsx(_12.MinusIcon,{size:12}):null]}),o?jsxRuntime.jsx("span",{className:ur({isDisabled:f}),children:o}):null]})});Ql.displayName="Checkbox";var Jl={ar:{goToPage:"\u0627\u0646\u062A\u0642\u0627\u0644 \u0625\u0644\u0649 \u0635\u0641\u062D\u0629",nextPage:"\u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u062A\u0627\u0644\u064A\u0629",pageXofY:"\u0635\u0641\u062D\u0629 {arg0} \u0645\u0646 {arg1}",prevPage:"\u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u0633\u0627\u0628\u0642\u0629"},cs:{goToPage:"P\u0159ej\xEDt na stranu",nextPage:"Dal\u0161\xED str\xE1nka",pageXofY:"Strana {arg0} z {arg1}",prevPage:"P\u0159edchoz\xED strana"},cy:{goToPage:"Mynd i Dudalen",nextPage:"Tudalen Nesaf",pageXofY:"Tudalen {arg0} o {arg1}",prevPage:"Tudalen Blaenorol"},da:{goToPage:"G\xE5 til side",nextPage:"N\xE6ste side",pageXofY:"Side {arg0} af {arg1}",prevPage:"Forrige side"},de:{goToPage:"Zu Seite wechseln",nextPage:"N\xE4chste Seite",pageXofY:"Seite {arg0} von {arg1}",prevPage:"Vorherige Seite"},el:{goToPage:"\u039C\u03B5\u03C4\u03AC\u03B2\u03B1\u03C3\u03B7 \u03C3\u03C4\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1",nextPage:"\u0395\u03C0\u03CC\u03BC\u03B5\u03BD\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1",pageXofY:"\u03A3\u03B5\u03BB\u03AF\u03B4\u03B1 {arg0} \u03B1\u03C0\u03CC {arg1}",prevPage:"\u03A0\u03C1\u03BF\u03B7\u03B3\u03BF\u03CD\u03BC\u03B5\u03BD\u03B7 \u03C3\u03B5\u03BB\u03AF\u03B4\u03B1"},"en-GB":{goToPage:"Go to Page",nextPage:"Next Page",pageXofY:"Page {arg0} of {arg1}",prevPage:"Previous Page"},en:{goToPage:"Go to Page",nextPage:"Next Page",pageXofY:"Page {arg0} of {arg1}",prevPage:"Previous Page"},es:{goToPage:"Ir a la p\xE1gina",nextPage:"P\xE1gina siguiente",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina anterior"},fi:{goToPage:"Mene sivulle",nextPage:"Seuraava sivu",pageXofY:"Sivu {arg0} / {arg1}",prevPage:"Edellinen sivu"},"fr-CA":{goToPage:"Aller \xE0 la page",nextPage:"Page suivante",pageXofY:"Page {arg0} sur {arg1}",prevPage:"Page pr\xE9c\xE9dente"},fr:{goToPage:"Aller \xE0 la page",nextPage:"Page suivante",pageXofY:"Page {arg0} sur {arg1}",prevPage:"Page pr\xE9c\xE9dente"},he:{goToPage:"\u05DE\u05E2\u05D1\u05E8 \u05DC\u05E2\u05DE\u05D5\u05D3",nextPage:"\u05D4\u05E2\u05DE\u05D5\u05D3 \u05D4\u05D1\u05D0",pageXofY:"\u05E2\u05DE\u05D5\u05D3 {arg0} \u05DE\u05EA\u05D5\u05DA {arg1}",prevPage:"\u05D4\u05E2\u05DE\u05D5\u05D3 \u05D4\u05E7\u05D5\u05D3\u05DD"},hr:{goToPage:"Idi na stranicu",nextPage:"Slijede\u0107a stranica",pageXofY:"Stranica {arg0} od {arg1}",prevPage:"Prethodna stranica"},id:{goToPage:"Buka halaman",nextPage:"Halaman Berikutnya",pageXofY:"Halaman {arg0} dari {arg1}",prevPage:"Halaman Sebelumnya"},it:{goToPage:"Vai a pagina",nextPage:"Pagina successiva",pageXofY:"Pagina {arg0} di {arg1}",prevPage:"Pagina precedente"},ja:{goToPage:"\u30DA\u30FC\u30B8\u306B\u79FB\u52D5",nextPage:"\u6B21\u306E\u30DA\u30FC\u30B8",pageXofY:"\u30DA\u30FC\u30B8 {arg0}/{arg1}",prevPage:"\u524D\u306E\u30DA\u30FC\u30B8"},ko:{goToPage:"\uD398\uC774\uC9C0\uB85C \uC774\uB3D9",nextPage:"\uB2E4\uC74C \uD398\uC774\uC9C0",pageXofY:"{arg0}/{arg1} \uD398\uC774\uC9C0",prevPage:"\uC774\uC804 \uD398\uC774\uC9C0"},ms:{goToPage:"Pergi ke Halaman",nextPage:"Halaman Seterusnya",pageXofY:"Halaman {arg0} daripada {arg1}",prevPage:"Halaman Sebelumnya"},"nb-NO":{goToPage:"G\xE5 til side",nextPage:"Neste side",pageXofY:"Side {arg0} av {arg1}",prevPage:"Forrige side"},nl:{goToPage:"Ga naar pagina",nextPage:"Volgende pagina",pageXofY:"Pagina {arg0} van {arg1}",prevPage:"Vorige pagina"},pl:{goToPage:"Przejd\u017A do strony",nextPage:"Nast\u0119pna strona",pageXofY:"Strona {arg0} z {arg1}",prevPage:"Poprzednia strona"},"pt-PT":{goToPage:"Ir para p\xE1gina",nextPage:"P\xE1gina seguinte",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina anterior"},pt:{goToPage:"Ir \xE0 P\xE1gina",nextPage:"P\xE1gina Seguinte",pageXofY:"P\xE1gina {arg0} de {arg1}",prevPage:"P\xE1gina Anterior"},ru:{goToPage:"\u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u043A \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0435",nextPage:"\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430",pageXofY:"\u0421\u0442\u0440\u0430\u043D\u0438\u0446\u0430 {arg0} \u0438\u0437 {arg1}",prevPage:"\u041F\u0440\u0435\u0434\u044B\u0434\u0443\u0449\u0430\u044F \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430"},sk:{goToPage:"\xCDs\u0165 na stranu",nextPage:"Dal\u0161ia strana",pageXofY:"Strana {arg0} z {arg1}",prevPage:"Predch\xE1dzaj\xFAca strana"},sl:{goToPage:"Pojdi na stran",nextPage:"Naslednja stran",pageXofY:"Stran {arg0} od {arg1}",prevPage:"Prej\u0161nja stran"},sv:{goToPage:"G\xE5 till sida",nextPage:"N\xE4sta sida",pageXofY:"Sida {arg0} av {arg1}",prevPage:"F\xF6reg\xE5ende sida"},th:{goToPage:"\u0E44\u0E1B\u0E17\u0E35\u0E48\u0E2B\u0E19\u0E49\u0E32",nextPage:"\u0E2B\u0E19\u0E49\u0E32\u0E16\u0E31\u0E14\u0E44\u0E1B",pageXofY:"\u0E2B\u0E19\u0E49\u0E32 {arg0} \u0E08\u0E32\u0E01 {arg1}",prevPage:"\u0E2B\u0E19\u0E49\u0E32\u0E01\u0E48\u0E2D\u0E19\u0E2B\u0E19\u0E49\u0E32"},tr:{goToPage:"Sayfaya Git",nextPage:"Sonraki Sayfa",pageXofY:"Sayfa {arg0}/{arg1}",prevPage:"\xD6nceki Sayfa"},uk:{goToPage:"\u041F\u0435\u0440\u0435\u0439\u0442\u0438 \u043D\u0430 \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0443",nextPage:"\u041D\u0430\u0441\u0442\u0443\u043F\u043D\u0430 \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0430",pageXofY:"\u0421\u0442\u043E\u0440\u0456\u043D\u043A\u0430 {arg0} \u0437 {arg1}",prevPage:"\u041F\u043E\u043F\u0435\u0440\u0435\u0434\u043D\u044F \u0441\u0442\u043E\u0440\u0456\u043D\u043A\u0430"},"zh-Hans":{goToPage:"\u524D\u5F80\u9875\u9762",nextPage:"\u4E0B\u4E00\u9875",pageXofY:"\u7B2C {arg0}/{arg1} \u9875",prevPage:"\u4E0A\u4E00\u9875"},"zh-Hant":{goToPage:"\u5230\u6B64\u9801",nextPage:"\u4E0B\u4E00\u9801",pageXofY:"\u7B2C{arg0}\u9801\uFF0C\u5171{arg1}\u9801",prevPage:"\u4E0A\u4E00\u9801"}};var ep=_({defaultClassName:"_1nsi9h17",variantClassNames:{isFocusVisible:{true:"_1nsi9h18"},variant:{pinned:"_1nsi9h19",floating:"_1nsi9h1a"}},defaultVariants:{},compoundVariants:[]}),op="_1nsi9h1b",tp=_({defaultClassName:"_1nsi9h10",variantClassNames:{size:{xs:"_1nsi9h11",sm:"_1nsi9h12",md:"_1nsi9h13",lg:"_1nsi9h14"},variant:{floating:"_1nsi9h15",pinned:"_1nsi9h16"}},defaultVariants:{},compoundVariants:[]}),rp="_1nsi9h1c";var Jv={style:"decimal"},e_={xs:[_12.CaretLeftIcon,_12.CaretRightIcon],sm:[_16.CaretLeftIcon,_16.CaretRightIcon],md:[_20.CaretLeftIcon,_20.CaretRightIcon],lg:[_24.CaretLeftIcon,_24.CaretRightIcon]},sp=to__default.default.forwardRef(({className:e,style:t,minValue:o=1,defaultValue:r=1,incrementAriaLabel:a,decrementAriaLabel:i,"aria-label":n,size:l="md",variant:s="floating",...p},d)=>{let{locale:u}=reactAria.useLocale(),c=B(Jl),m={...p,formatOptions:Jv,minValue:o,incrementAriaLabel:a||c.formatMessage("nextPage"),decrementAriaLabel:i||c.formatMessage("prevPage"),defaultValue:r,"aria-label":n||c.formatMessage("goToPage")},f=to__default.default.useRef(null),y=reactStately.useNumberFieldState({...m,locale:u}),{inputProps:g,decrementButtonProps:v,incrementButtonProps:b,groupProps:h}=reactAria.useNumberField({...m,onKeyDown:E=>{E.key==="Enter"&&f.current?.blur(),p.onKeyDown?.(E);}},y,f),{hoverProps:z,isHovered:x}=reactAria.useHover({}),{focusProps:R,isFocused:C,isFocusVisible:P}=reactAria.useFocusRing(),k=s==="floating",[T,I]=e_[l],D=utils.filterTruthyValues({"data-focus-visible":P,"data-focused":C,"data-hovered":x,"data-block-id":p["data-block-id"]});return jsxRuntime.jsxs("div",{...reactAria.mergeProps(h,z,D),className:utils.classNames(tp({size:l,variant:s}),"BaselineUI-Pagination",e),style:t,ref:d,children:[jsxRuntime.jsx(L,{icon:T,...v,elementType:"div",size:l,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-DecrementButton"}),s==="floating"&&jsxRuntime.jsx(F,{orientation:"vertical"}),jsxRuntime.jsxs("div",{className:ep({isFocusVisible:P,variant:s}),"aria-label":c.formatMessage("pageXofY",{arg0:g.value,arg1:y.maxValue}),children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(g,R),ref:f,className:utils.classNames("BaselineUI-Pagination-Input",op),style:{width:`${g.value?.toString().length||1}ch`}}),jsxRuntime.jsxs("span",{className:rp,children:["/ ",jsxRuntime.jsx(wo,{value:y.maxValue})]})]}),s==="floating"&&jsxRuntime.jsx(F,{orientation:"vertical"}),jsxRuntime.jsx(L,{icon:I,...b,elementType:"div",size:l,style:{height:"100%",...k&&{borderRadius:0}},className:"BaselineUI-Pagination-IncrementButton"})]})});sp.displayName="Pagination";var lp=({date:e,...t})=>{let o=reactAria.useDateFormatter(t);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:o.format(e)})};lp.displayName="DateFormat";var fr=_({defaultClassName:"_1f789qj1",variantClassNames:{isFocusVisible:{true:"_1f789qj2"},variant:{neutral:"_1f789qj3",red:"_1f789qj4",green:"_1f789qj5",blue:"_1f789qj6","high-contrast":"_1f789qj7"},isDisabled:{true:"_1f789qj8"},allowsRemoving:{true:"_1f789qj9"},isSelected:{true:"_1f789qja"},allowsSelection:{true:"_1f789qjb"},isHovered:{true:"_1f789qjc"}},defaultVariants:{},compoundVariants:[[{allowsSelection:!0,isHovered:!0,variant:"neutral"},"_1f789qjd"],[{allowsSelection:!0,isHovered:!0,variant:"red"},"_1f789qje"],[{allowsSelection:!0,isHovered:!0,variant:"blue"},"_1f789qjf"],[{allowsSelection:!0,isHovered:!0,variant:"green"},"_1f789qjg"],[{allowsSelection:!0,isHovered:!0,variant:"high-contrast"},"_1f789qjh"],[{allowsSelection:!0,isSelected:!0,isHovered:!0},"_1f789qji"]]}),pp="_1f789qjj",cp="_1f789qj0",dp=_({defaultClassName:"_1f789qjk",variantClassNames:{variant:{neutral:"_1f789qjl",red:"_1f789qjm",green:"_1f789qjn",blue:"_1f789qjo","high-contrast":"_1f789qjp"},isHovered:{true:"_1f789qjq"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,variant:"neutral"},"_1f789qjr"],[{isHovered:!0,variant:"red"},"_1f789qjs"],[{isHovered:!0,variant:"blue"},"_1f789qjt"],[{isHovered:!0,variant:"green"},"_1f789qju"],[{isHovered:!0,variant:"high-contrast"},"_1f789qjv"]]});var m_=({item:e,state:t,variant:o="neutral"})=>{let r=to__default.default.useRef(null),{focusProps:a,isFocusVisible:i}=reactAria.useFocusRing({within:!0}),{rowProps:n,gridCellProps:l,removeButtonProps:s,allowsRemoving:p,isDisabled:d,isSelected:u,allowsSelection:c}=reactAria.useTag({item:e},t,r),m=to__default.default.useRef(null),{buttonProps:f}=reactAria.useButton(s,m),{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:d}),{hoverProps:v,isHovered:b}=reactAria.useHover({isDisabled:d}),h=e.value?.icon,z=e.value?.variant??o;return jsxRuntime.jsx("div",{...reactAria.mergeProps(n,a,v),ref:r,className:fr({isFocusVisible:i,variant:z,isDisabled:d,allowsRemoving:p,isSelected:u,allowsSelection:c,isHovered:b}),children:jsxRuntime.jsxs("div",{...l,className:pp,children:[u?jsxRuntime.jsx(_16.CheckmarkIcon,{size:16}):null,!u&&h?jsxRuntime.jsx(h,{size:16}):null,e.rendered,p?jsxRuntime.jsx("button",{...reactAria.mergeProps(f,y),className:dp({variant:z,isHovered:g}),children:jsxRuntime.jsx(_12.XIcon,{})}):null]})})},Ga=to__default.default.forwardRef(({className:e,style:t,...o},r)=>{let a=to__default.default.useRef(null),i=reactStately.useListState(o),{gridProps:n}=reactAria.useTagGroup(o,i,a);return jsxRuntime.jsx("div",{...n,className:utils.classNames(cp,e),style:t,ref:N(r,a),children:[...i.collection].map(l=>jsxRuntime.jsx(m_,{state:i,item:l,variant:o.variant},l.key))})});Ga.displayName="TagGroupBase";var yp=to__default.default.forwardRef(({items:e,...t},o)=>jsxRuntime.jsx(Ga,{...t,items:e,ref:o,children:r=>jsxRuntime.jsx(reactStately.Item,{children:r.label})}));yp.displayName="TagGroup";var bp="_1yep5z6kv",gp=_({defaultClassName:"_1kvz17db _1yep5z6ki _1yep5z6kk",variantClassNames:{showActionsOnTriggerOnly:{true:"_1kvz17dc"},isTriggered:{true:"_1kvz17dd"}},defaultVariants:{},compoundVariants:[]}),vp=_({defaultClassName:"_1kvz17d0 _1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z68c _1yep5z68d _1yep5z68e _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6ki _1yep5z6kj",variantClassNames:{isExpanded:{true:"_1kvz17d1"}},defaultVariants:{},compoundVariants:[]}),_p="_1yep5z6ev _1yep5z6dy",zp=_({defaultClassName:"_1kvz17d2 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ki _1yep5z6kl",variantClassNames:{isFocusVisible:{true:"_1kvz17d3"},isHovered:{true:"_1yep5z6ft",false:"_1yep5z6fu"},isDisabled:{true:"z9nup83"}},defaultVariants:{},compoundVariants:[]}),hp="_1kvz17da _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6dz",xp=_({defaultClassName:"_1kvz17d7 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{isDisabled:{true:"_1yep5z6ey",false:"_1yep5z6eu"}},defaultVariants:{},compoundVariants:[]});var Xa=to__default.default.forwardRef(({children:e,className:t,style:o},r)=>{let{headers:a}=to.useContext(Oe),{disabledKeys:i}=to.useContext(Oe),{keyboardProps:n}=reactAria.useKeyboard({onKeyDown:l=>{let s=Vt(l.target),p=[...a?.keys()||[]].findIndex(f=>a?.get(f)?.current===s?.activeElement),d=a?.get(p||0),u=a?.size||0,c=f=>{let y=a.get(f-1<0?u-1:f-1);i?.has(y?.current?.getAttribute("data-key")||"")?c(f-1):y?.current?.focus();},m=f=>{let y=a.get((f+1)%u);i?.has(y?.current?.getAttribute("data-key")||"")?m(f+1):y?.current?.focus();};if(d)switch(l.key){case"Home":{l.preventDefault(),m(-1);break}case"End":{l.preventDefault(),c(u);break}case"ArrowDown":{l.preventDefault(),m(p);break}case"ArrowUp":{l.preventDefault(),c(p);break}default:l.continuePropagation();}}});return jsxRuntime.jsx("div",{...n,style:o,className:utils.classNames(bp,t),ref:r,children:to__default.default.Children.map(e,(l,s)=>to__default.default.cloneElement(l,{index:s}))})});Xa.displayName="AccordionBase";var Oe=to__default.default.createContext({expandedKeys:new Set,setExpandedKeys:()=>{},disabledKeys:new Set,headers:new Map,expansionMode:"multiple"}),kp=to__default.default.forwardRef(({children:e,disabledKeys:t,defaultExpandedKeys:o=new Set,expandedKeys:r,expansionMode:a="multiple",onChange:i,className:n,style:l},s)=>{let[p,d]=to__default.default.useState(o),u=to__default.default.useRef(new Map).current,[c,m]=to__default.default.useState(a);to.useEffect(()=>{m(c);},[c]),to.useEffect(()=>{i?.(p);},[p,i]);let f=to.useMemo(()=>({expandedKeys:r||p,setExpandedKeys:r?()=>{}:d,disabledKeys:t,headers:u,expansionMode:c}),[r,p,t,u,c]);return jsxRuntime.jsx(Oe.Provider,{value:f,children:jsxRuntime.jsx(reactAria.FocusScope,{children:jsxRuntime.jsx(Xa,{className:n,style:l,ref:s,children:e})})})});kp.displayName="Accordion";var Za=to__default.default.forwardRef(({title:e,actions:t,controlId:o,value:r,id:a,index:i,subLabel:n,showActionsOnTriggerOnly:l},s)=>{let p=to__default.default.useRef(null),{expandedKeys:d,setExpandedKeys:u,expansionMode:c,disabledKeys:m,headers:f}=to.useContext(Oe),y=m?.has(r),g=reactAria.useFocusManager();utils.invariant(g);let{focusNext:v,focusPrevious:b}=g,{keyboardProps:h}=reactAria.useKeyboard({onKeyDown:w=>{w.key==="ArrowRight"?v({wrap:!0}):w.key==="ArrowLeft"?b({wrap:!0}):w.continuePropagation();},isDisabled:y});to.useEffect(()=>{utils.invariant(typeof i=="number","AccordionItem must have an index"),f?.set(i,p);},[i,f]);let z=()=>{u(w=>{let S=new Set(w);return S.has(r)?S.delete(r):(c==="single"&&S.clear(),S.add(r)),S});},{buttonProps:x}=reactAria.useButton({"aria-expanded":d.has(r),"aria-controls":o,onPress:z,isDisabled:y},p),{pressProps:R}=reactAria.usePress({onPress:z,isDisabled:y}),{focusProps:C,isFocusVisible:P}=reactAria.useFocusRing(),{hoverProps:k,isHovered:T}=reactAria.useHover({isDisabled:y}),{focusProps:I,isFocusVisible:D}=reactAria.useFocusRing({within:!0}),E=d.has(r);return jsxRuntime.jsxs("h3",{...reactAria.mergeProps(h,R,k,I),className:zp({isFocusVisible:P,isHovered:T,isDisabled:y}),ref:s,children:[jsxRuntime.jsxs("div",{className:xp({isDisabled:!!y}),children:[jsxRuntime.jsx(_8.ChevronRightIcon,{className:vp({isExpanded:E}),size:8}),jsxRuntime.jsx("button",{...reactAria.mergeProps(x,C),id:a,"data-key":r,className:hp,ref:p,children:e})]}),t?.length?jsxRuntime.jsx("div",{"data-testid":"action-buttons",className:gp({showActionsOnTriggerOnly:l,isTriggered:D||T}),children:t.map((w,S)=>jsxRuntime.jsx(L,{variant:"secondary",size:"sm",excludeFromTabOrder:!0,isDisabled:y,...w},S))}):null,n?jsxRuntime.jsx("div",{className:_p,children:n}):null]})});Za.displayName="AccordionHeader";var Mp=to__default.default.forwardRef(({title:e,actions:t,children:o,value:r,index:a,subLabel:i,style:n,className:l,showActionsOnTriggerOnly:s},p)=>{let d=reactAria.useId(),u=reactAria.useId(),{expandedKeys:c}=to.useContext(Oe),m=to__default.default.useRef(null),f=c.has(r),y=Fe(),g=web.useReducedMotion(),v=web.useTransition(f?[r]:[],{from:!y&&!g&&{height:0,opacity:0},enter:()=>async b=>{await b({height:m.current?.scrollHeight,opacity:1});},leave:{height:0,opacity:0},keys:b=>b});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(reactAria.FocusScope,{children:jsxRuntime.jsx(Za,{value:r,actions:t,id:u,title:e,controlId:d,ref:p,index:a,subLabel:i,showActionsOnTriggerOnly:s})}),v(b=>jsxRuntime.jsx(web.animated.div,{role:"region","aria-labelledby":u,id:d,style:{...b,overflow:"hidden"},children:jsxRuntime.jsx("div",{ref:m,className:l,style:n,children:o})}))]})});Mp.displayName="AccordionItem";var nt=to__default.default.forwardRef(({variant:e,isOpen:t,selectedIcon:o,validationState:r="valid",valueProps:a,label:i,...n},l)=>{let s=to__default.default.useRef(null),{buttonProps:p,isPressed:d}=reactAria.useButton({...n,isDisabled:n.isDisabled||n.isReadOnly},s),{hoverProps:u,isHovered:c}=reactAria.useHover({isDisabled:n.isDisabled}),{focusProps:m,isFocused:f,isFocusVisible:y}=reactAria.useFocusRing(),g=Po({isReadOnly:n.isReadOnly,validationState:r});n.isReadOnly&&(p.disabled=!1);let v=utils.filterTruthyValues({"data-disabled":n.isDisabled,"data-readonly":n.isReadOnly,"data-focused":f,"data-focus-visible":y,"data-hovered":c,"data-pressed":d,"data-open":t});return jsxRuntime.jsxs("button",{...reactAria.mergeProps(p,u,m,v),ref:N(l,s),className:utils.classNames(Ws({isFocused:y,isDisabled:n.isDisabled}),uo({variant:e,isHovered:c,isFocused:y,validationState:r,isDisabled:!!n.isDisabled,isReadOnly:n.isReadOnly}),"BaselineUI-Select-Button"),children:[jsxRuntime.jsxs("span",{className:Zs,children:[o?jsxRuntime.jsx(o,{size:24}):null,jsxRuntime.jsx("span",{...a,children:i})]}),g?jsxRuntime.jsx("span",{"aria-hidden":!0,className:utils.classNames(mo({validationState:r,isReadOnly:!!n.isReadOnly}),Ys),children:jsxRuntime.jsx(g,{size:16})}):null,jsxRuntime.jsx("span",{"aria-hidden":!0,children:jsxRuntime.jsx(_8.ChevronDownIcon,{size:8,className:Gs({isOpen:t})})})]})});nt.displayName="SelectButton";var ei=to__default.default.createContext(null),oi=to__default.default.forwardRef(({className:e,style:t,labelPosition:o="top",variant:r="primary","data-block-id":a,optionStyle:i,optionClassName:n,placement:l="bottom start",state:s,renderTrigger:p=({buttonProps:c,selectedValue:m,valueProps:f,isOpen:y,ref:g})=>{let v=m&&"icon"in m&&m.icon;return jsxRuntime.jsx(nt,{...c,isOpen:y,isReadOnly:d.isReadOnly,ref:g,variant:r,validationState:d.validationState,selectedIcon:v||void 0,label:m?"label"in m&&m?.label:d.placeholder,valueProps:f})},...d},u)=>{let c=to__default.default.useRef(null),m=de(d.portalContainer),{labelProps:f,triggerProps:y,valueProps:g,menuProps:v,descriptionProps:b,errorMessageProps:h}=reactAria.useSelect({...d,validationState:d.validationState==="error"?"invalid":"valid"},s,c),z=_e({...d,descriptionProps:b,errorMessageProps:h,labelPosition:o}),x=s.selectedItem?.value??null;return jsxRuntime.jsxs(We.Provider,{value:s,children:[jsxRuntime.jsxs("div",{style:t,className:utils.classNames(Be({labelPosition:o}),"BaselineUI-Select",e),"data-block-id":a,ref:u,children:[d.label||z?jsxRuntime.jsxs("div",{className:De({labelPosition:o,hasMessage:!!z}),children:[d.label?jsxRuntime.jsx("div",{...f,className:utils.classNames(Me,"BaselineUI-Select-Label"),children:d.label}):null,o==="start"&&z]}):null,jsxRuntime.jsx(reactAria.HiddenSelect,{state:s,triggerRef:c,isDisabled:d.isDisabled,label:d.label,name:d.name}),p({buttonProps:y,selectedValue:x,valueProps:g,isOpen:s.isOpen,ref:c}),o==="top"&&z]}),s.isOpen?jsxRuntime.jsx(le,{placement:l,portalContainer:m,offset:2,state:s,triggerRef:c,style:t,className:utils.classNames(ir,"BaselineUI-Select-Popover"),...d,children:jsxRuntime.jsx(te,{...v,label:d.label,items:d.items,showSelectedIcon:d.showSelectedIcon,className:Xs,optionStyle:i,optionClassName:n})}):null]})});oi.displayName="SelectCore";var Fp=to__default.default.forwardRef((e,t)=>{let o=se(),r=reactStately.useSelectState({...e,validationState:e.validationState==="error"?"invalid":"valid",children:o});return jsxRuntime.jsx(oi,{...e,ref:t,state:r})});Fp.displayName="SelectStandalone";var Ae=to__default.default.forwardRef((e,t)=>{let o=to.useContext(ei);return to.useEffect(()=>{utils.invariant(o||e.items,"Select: A `state` that can be passed via context or `items` are required.");},[e.items,o]),o?jsxRuntime.jsx(oi,{state:o,...e,ref:t}):jsxRuntime.jsx(Fp,{...e,ref:t})});Ae.displayName="Select";var Op=to__default.default.forwardRef(({className:e,style:t,variant:o,"data-block-id":r,icon:a,includeTooltip:i,placement:n="bottom start",...l},s)=>{let p=to__default.default.useRef(null),d=to.useCallback(({buttonProps:u,selectedValue:c,valueProps:m,isOpen:f,ref:y})=>{let g=c&&"icon"in c&&c.icon;return jsxRuntime.jsx(He,{isDisabled:!i||l.isDisabled,variant:"inverse",size:"sm",includeArrow:!1,text:l["aria-label"],placement:n,offset:4,children:jsxRuntime.jsx(nt,{...u,isOpen:f,isReadOnly:l.isReadOnly,ref:y,variant:o,validationState:l.validationState,selectedIcon:g||void 0,label:c?"label"in c&&c?.label:l.placeholder,valueProps:m})})},[i,n,l,o]);return jsxRuntime.jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:utils.classNames("BaselineUI-IconSelect",e),"data-block-id":r,style:t,ref:N(s,p),children:[jsxRuntime.jsx(a,{size:24,className:tokens.sprinkles({color:"icon.primary"})}),jsxRuntime.jsx(Ae,{...l,renderTrigger:d})]})});Op.displayName="IconSelect";var Vp="_1017q4c5",Ap=_({defaultClassName:"_1017q4c0",variantClassNames:{size:{md:"_1017q4c1",sm:"_1017q4c2"},isDisabled:{true:"_1017q4c3"}},defaultVariants:{},compoundVariants:[]}),jp="_1017q4c4";var t6={sm:_16.AvatarIcon,md:_24.AvatarIcon},So=to__default.default.forwardRef(({className:e,style:t,size:o="md",icon:r=t6[o],name:a,imgSrc:i,showInitials:n,isDisabled:l,hasNotifications:s,imgLoading:p,"data-block-id":d},u)=>{let{imgProps:c}=bo({src:i,alt:a}),m=a?.split(" ").map(f=>f[0]).join("");return jsxRuntime.jsxs("span",{className:utils.classNames(Ap({size:o,isDisabled:l}),"BaselineUI-Avatar",e),"data-disabled":l,ref:u,style:t,"aria-disabled":l,"data-block-id":d,children:[i?jsxRuntime.jsx("img",{...c,loading:p,className:jp}):null,!n&&!i&&jsxRuntime.jsx(r,{size:o==="sm"?16:24}),n&&!i?o==="sm"?m[0]:m:null,s?jsxRuntime.jsx("div",{"data-testid":"notification",className:Vp}):null]})});So.displayName="Avatar";var $p="_1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it",Up=_({defaultClassName:"_1x62fhb6 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6ev _1yep5z69i _1yep5z69j _1yep5z69k",variantClassNames:{isHovered:{true:"_1yep5z6105"},isSelected:{true:"_1x62fhb8"},isFocusVisible:{true:"_1x62fhb9"},isDisabled:{true:"_1x62fhba _1yep5z6109"},variant:{primary:"_1x62fhbb _1yep5z6z6",ghost:"_1yep5z6z9"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isSelected:!0,isDisabled:!1},"_1yep5z61lg"],[{variant:"primary",isSelected:!0},"_1yep5z61me"],[{variant:"ghost",isSelected:!0,isFocusVisible:!1},"_1x62fhbd"],[{variant:"ghost",isSelected:!0,isDisabled:!1},"_1yep5z61lr"],[{variant:"ghost",isDisabled:!0,isSelected:!0},"_1x62fhbe _1yep5z6ey"],[{variant:"primary",isHovered:!0},"_1yep5z61mf"]]}),qp=_({defaultClassName:"_1x62fhb3 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1x62fhb4",ghost:"_1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),Kp="_1x62fhbf",Gp="_1yep5z6l2 _1yep5z6kz _1yep5z6hc _1yep5z6l1",Wp=_({defaultClassName:"_1x62fhb0 _1yep5z6kv _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{variant:{primary:"_1yep5z6115",ghost:"_1x62fhb2"}},defaultVariants:{},compoundVariants:[]});var Xp=({state:e,...t})=>{let o=to__default.default.useRef(null),{tabPanelProps:r}=reactAria.useTabPanel(t,e,o),{selectedItem:a}=e,{focusProps:i,isFocusVisible:n}=reactAria.useFocusRing();if(!a?.value)return null;let{className:l,style:s,"data-block-id":p}=a.value;return jsxRuntime.jsx("div",{...reactAria.mergeProps(r,i),ref:o,className:utils.classNames({[Gp]:n},"Baseline-Tabs-TabPanel",l),"data-block-id":p,style:s,children:a?.props.children})};var ii=to__default.default.forwardRef(({className:e,style:t,tabHeaderStyle:o,tabHeaderClassName:r,variant:a="primary",actions:i,onRemove:n,"data-block-id":l,...s},p)=>{let d=reactStately.useTabListState({...s,selectedKey:s.selectedValue,defaultSelectedKey:s.defaultSelectedValue,disabledKeys:s.disabledValues}),u=to__default.default.useRef(null),{tabListProps:c}=reactAria.useTabList({...s,selectedKey:s.selectedValue,defaultSelectedKey:s.defaultSelectedValue,disabledKeys:s.disabledValues},d,u);return jsxRuntime.jsxs("div",{className:utils.classNames("BaselineUI-Tabs",e),style:t,ref:p,"data-block-id":l,children:[jsxRuntime.jsxs("div",{className:utils.classNames(Wp({variant:a}),r),style:o,children:[jsxRuntime.jsx("div",{...c,className:qp({variant:a}),ref:u,children:[...d.collection].map(m=>(utils.invariant(m.value,"TabItem requires a value prop"),jsxRuntime.jsx(Zp,{item:m,state:d,onRemove:n,variant:a},m.key)))}),i?.map((m,f)=>jsxRuntime.jsx("div",{className:$p,children:jsxRuntime.jsx(L,{...m,variant:"secondary",size:"sm",className:utils.classNames(Kp,m.className)})},f))]}),jsxRuntime.jsx(Xp,{state:d},d.selectedItem?.key)]})});ii.displayName="TabsBase";var Zp=({item:e,onRemove:t,state:o,variant:r})=>{let{key:a,value:i}=e,n=to__default.default.useRef(null),{tabProps:l,isSelected:s,isDisabled:p}=reactAria.useTab({key:a},o,n),{hoverProps:d,isHovered:u}=reactAria.useHover({});utils.invariant(i,"TabButton requires a value prop");let{title:c,icon:m,titleStyle:f,titleClassName:y}=i,{focusProps:g,isFocusVisible:v,isFocused:b}=reactAria.useFocusRing(),{keyboardProps:h}=reactAria.useKeyboard({onKeyDown:x=>{x.key==="Backspace"&&t?t(a):x.continuePropagation();}}),z=utils.filterTruthyValues({"data-selected":s,"data-disabled":p,"data-focused":b,"data-hovered":u,"data-focus-visible":v});return jsxRuntime.jsxs("div",{...reactAria.mergeProps(h,l,d,g,z),className:utils.classNames(Up({isHovered:u,isSelected:s,isFocusVisible:v,isDisabled:p,variant:r}),"BaselineUI-Tabs-TabButton",y),style:f,ref:n,children:[m?jsxRuntime.jsx(m,{size:20}):null,c,t?jsxRuntime.jsx(L,{variant:"secondary",elementType:"div",icon:_8.XIcon,size:"xxs",onPress:()=>{t(a);},excludeFromTabOrder:!0,UNSAFE_NON_INTERACTIVE:!0,style:{display:"inline-flex",color:"inherit",opacity:s||b||u?1:0}}):null]})};Zp.displayName="TabButton";var Jp=to__default.default.forwardRef(({children:e,...t},o)=>{let r=to.useMemo(()=>to__default.default.Children.map(e,a=>!a||!to__default.default.isValidElement(a)||typeof a.type=="string"?null:{...a.props,id:a.props.value}).filter(Boolean),[e]);return jsxRuntime.jsx(ii,{...t,ref:o,items:r,children:a=>jsxRuntime.jsx(reactStately.Item,{title:a.title,children:a.children},a.key)})});Jp.displayName="Tabs";var ec=({children:e,title:t,value:o})=>(utils.invariant(o,"TabItem requires a value prop"),utils.invariant(t,"TabItem requires a title prop"),utils.invariant(e,"TabItem requires children"),e);ec.displayName="TabItem";var oc={ar:{close:"\u0625\u063A\u0644\u0627\u0642"},cs:{close:"Zav\u0159\xEDt"},cy:{close:"Cau"},da:{close:"Luk"},de:{close:"Schlie\xDFen"},el:{close:"\u039A\u03BB\u03B5\u03AF\u03C3\u03B9\u03BC\u03BF"},"en-GB":{close:"Close"},en:{close:"Close"},es:{close:"Cerrar"},fi:{close:"Sulje"},"fr-CA":{close:"Fermer"},fr:{close:"Fermer"},he:{close:"\u05E1\u05D2\u05D9\u05E8\u05D4"},hr:{close:"Zatvori"},id:{close:"Tutup"},it:{close:"Chiudi"},ja:{close:"\u9589\u3058\u308B"},ko:{close:"\uB2EB\uAE30"},ms:{close:"Tutup"},"nb-NO":{close:"Lukk"},nl:{close:"Sluit"},pl:{close:"Zamknij"},"pt-PT":{close:"Fechar"},pt:{close:"Fechar"},ru:{close:"\u0417\u0430\u043A\u0440\u044B\u0442\u044C"},sk:{close:"Zavrie\u0165"},sl:{close:"Zapri"},sv:{close:"St\xE4ng"},th:{close:"\u0E1B\u0E34\u0E14"},tr:{close:"Kapat"},uk:{close:"\u0417\u0430\u043A\u0440\u0438\u0442\u0438"},"zh-Hans":{close:"\u5173\u95ED"},"zh-Hant":{close:"\u95DC\u9589"}};var tc=_({defaultClassName:"kfun6yw",variantClassNames:{arrangement:{single:"kfun6yx",multi:"kfun6yy",compact:"kfun6yz"}},defaultVariants:{},compoundVariants:[]}),rc=_({defaultClassName:"kfun6y0 z9nup82",variantClassNames:{variant:{info:"kfun6y1",warning:"kfun6y2",error:"kfun6y3",success:"kfun6y4"},arrangement:{single:"kfun6y5",multi:"kfun6y6",compact:"kfun6y7"},hasButton:{true:"kfun6y8"},hasCloseButton:{true:"kfun6y9"}},defaultVariants:{},compoundVariants:[[{hasButton:!1,arrangement:"single"},"kfun6ya"],[{hasButton:!0,arrangement:"compact"},"kfun6yb"],[{hasCloseButton:!0,arrangement:"compact"},"kfun6yc"]]}),ac=_({defaultClassName:"kfun6yt",variantClassNames:{size:{sm:"kfun6yu",md:"kfun6yv"}},defaultVariants:{},compoundVariants:[]}),ic=_({defaultClassName:"kfun6yp",variantClassNames:{arrangement:{single:"kfun6yq",multi:"kfun6yr",compact:"kfun6ys"}},defaultVariants:{},compoundVariants:[]}),nc=_({defaultClassName:"kfun6yk",variantClassNames:{variant:{info:"kfun6yl",warning:"kfun6ym",error:"kfun6yn",success:"kfun6yo"}},defaultVariants:{},compoundVariants:[]}),sc=_({defaultClassName:"kfun6yh",variantClassNames:{size:{sm:"kfun6yi",md:"kfun6yj"}},defaultVariants:{},compoundVariants:[]}),lc=_({defaultClassName:"kfun6yd z9nup82",variantClassNames:{arrangement:{single:"kfun6ye",multi:"kfun6yf",compact:"kfun6yg"}},defaultVariants:{},compoundVariants:[]});var M6={error:{sm:_16.ErrorAltFilledIcon,md:_20.ErrorAltFilledIcon},info:{sm:_16.InfoFilledIcon,md:_20.InfoFilledIcon},success:{sm:_16.CheckFilledIcon,md:_20.CheckFilledIcon},warning:{sm:_16.WarningFilledIcon,md:_20.WarningFilledIcon}},pc=to__default.default.forwardRef(({className:e,description:t,actionLabel:o,onAction:r,style:a,variant:i="info",title:n,arrangement:l="single",onClose:s,size:p="sm"},d)=>{let u=B(oc),c=o&&jsxRuntime.jsx(O,{variant:l==="compact"?"tertiary":"ghost",label:o,onPress:r}),m=M6[i][p];return jsxRuntime.jsxs("div",{className:utils.classNames(rc({variant:i,arrangement:l,hasButton:!!o||!!s,hasCloseButton:!!s}),e),style:a,role:"alert",ref:d,children:[jsxRuntime.jsxs("div",{className:lc({arrangement:l}),children:[jsxRuntime.jsx(m,{className:nc({variant:i}),size:16}),jsxRuntime.jsxs("div",{className:tc({arrangement:l}),children:[jsxRuntime.jsx("h3",{className:sc({size:p}),children:n}),jsxRuntime.jsx("section",{className:ac({size:p}),children:t})]}),l==="compact"&&c]}),jsxRuntime.jsxs("div",{className:ic({arrangement:l}),children:[l!=="compact"&&c,s?jsxRuntime.jsx(L,{variant:"secondary",icon:_16.CloseIcon,size:"sm",onPress:s,"aria-label":u.formatMessage("close")}):null]})]})});pc.displayName="InlineAlert";var cc=_({defaultClassName:"_1tkzayn0 _1yep5z6dy",variantClassNames:{size:{sm:"_1tkzayn1",md:"_1tkzayn2",lg:"_1tkzayn3"},type:{subtitle:"_1yep5z6105",title:"_1yep5z6105",label:"_1yep5z6106",value:"_1yep5z6106",helper:"_1yep5z6107",body:"_1yep5z6105"}},defaultVariants:{},compoundVariants:[[{type:"title",size:"sm"},"_1yep5z61jz"],[{type:"title",size:"md"},"_1yep5z61k2"],[{type:"title",size:"lg"},"_1yep5z61k5"],[{type:"body",size:"sm"},"_1yep5z61kp"],[{type:"body",size:"md"},"_1yep5z61ks"],[{type:"body",size:"lg"},"_1yep5z61ks"],[{type:"subtitle",size:"sm"},"_1yep5z61kl"],[{type:"subtitle",size:"md"},"_1yep5z61ko"],[{type:"subtitle",size:"lg"},"_1yep5z61ko"],[{type:"label",size:"md"},"_1yep5z61kn"],[{type:"label",size:"lg"},"_1yep5z61kn"],[{type:"value",size:"md"},"_1yep5z61kn"],[{type:"value",size:"lg"},"_1yep5z61kn"],[{type:"helper",size:"sm"},"_1yep5z61kh"]]});var W=to__default.default.forwardRef(({elementType:e="span",type:t="title",children:o,size:r="md",...a},i)=>jsxRuntime.jsx(e,{...a,className:utils.classNames(cc({size:r,type:t}),"BaselineUI-Text",a.className),ref:i,children:o}));W.displayName="Text";var dc=_({defaultClassName:"siobe21 _1yep5z6ao _1yep5z6ap _1yep5z6aq _1yep5z6bc _1yep5z6bd _1yep5z6be _1yep5z6d7 _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie",variantClassNames:{background:{subtle:"_1yep5z6113",medium:"_1yep5z6114"}},defaultVariants:{},compoundVariants:[]}),mc="siobe24",uc="var(--siobe20)";var hr=to__default.default.forwardRef(({className:e,style:t,children:o,background:r="medium",title:a,action:i,"data-block-id":n,onCloseRequest:l,...s},p)=>{let{formatMessage:d}=B(),u=to__default.default.useRef(null),{dialogProps:c,titleProps:m}=reactAria.useDialog(s,u);return jsxRuntime.jsxs("div",{...c,className:utils.classNames(dc({background:r}),"BaselineUI-Drawer",e),"data-block-id":n,style:t,ref:N(p,u),children:[jsxRuntime.jsxs(M,{paddingLeft:"lg",paddingRight:"sm",backgroundColor:"background.primary.subtle",display:"flex",justifyContent:"space-between",alignItems:"center",gap:"lg",className:mc,children:[jsxRuntime.jsx(W,{type:"title",size:"sm",...m,className:Jn,children:a}),jsxRuntime.jsxs(M,{children:[i?jsxRuntime.jsx(L,{...i,variant:"secondary"}):null,jsxRuntime.jsx(L,{variant:"secondary",size:"md",icon:_20.XIcon,onPress:l,"aria-label":d(V6.close)})]})]}),jsxRuntime.jsx(F,{variant:r==="subtle"?"primary":"secondary"}),o]})});hr.displayName="Drawer";var V6=j({close:{id:"close",defaultMessage:"Close"}});function bc(e,t,o){let{isDisabled:r}=e,a=web.useReducedMotion(),[i,n]=to__default.default.useState("100vh");to.useEffect(()=>{if(!fa()&&!ya())return;let m=Q(o.current);function f(){n(`${m?.visualViewport.height}px`);}return f(),m?.visualViewport.addEventListener("resize",f),()=>{m?.visualViewport.removeEventListener("resize",f);}},[o]);let[{y:l},s]=web.useSpring(()=>({y:0,immediate:a,config:{easing:web.easings.easeOutCubic}})),p=to.useRef(0),d=to.useCallback(()=>{s.start({y:p.current,onRest:()=>{t.close();}});},[s,t]),u=to.useCallback(m=>{m.target.closest("[data-drawer]")||d();},[d]);granularHooks.useGranularLayoutEffect(()=>{p.current=o.current?.offsetHeight||0,s.set({y:p.current}),s.start({y:0,immediate:!!a});},[],[s,a]);let c=l.to({range:[0,p.current/2,p.current],output:[.5,.2,0],extrapolate:"clamp"}).to(m=>`rgba(0,0,0,${m})`);return {overlayProps:{style:r?void 0:{transform:l.to(m=>`translateY(${m}px)`)}},underlayProps:{style:r?void 0:{backgroundColor:c},onPointerDown:r?void 0:u},close:d,containerHeight:r?void 0:i}}var gc=_({defaultClassName:"aml2vl0 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hr _1yep5z6hs _1yep5z6ht",variantClassNames:{enableDrawer:{false:"_1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",true:"aml2vl2"}},defaultVariants:{},compoundVariants:[]}),vc="_1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6g2 _1yep5z6hr _1yep5z6hs _1yep5z6ht";var je=to__default.default.createContext({state:null,triggerProps:{},overlayProps:{}}),ze=({children:e,...t})=>{let o=reactStately.useOverlayTriggerState(t),{triggerProps:r,overlayProps:a}=reactAria.useOverlayTrigger({type:"dialog"},o),i=to.useMemo(()=>({state:o,triggerProps:r,overlayProps:a}),[o,r,a]);return jsxRuntime.jsx(je.Provider,{value:i,children:e})};ze.displayName="Modal";var pi=to__default.default.createContext({isDrawer:!1,closeDrawer:()=>{}}),n5=web.animated(zo),s5=({children:e,className:t,style:o,isDismissable:r=!0,isKeyboardDismissDisabled:a=!1,portalContainer:i,disableAnimation:n,enableDrawer:l=!1,"data-block-id":s})=>{let{state:p}=to__default.default.useContext(je),d=go(i),u=de(i),c=typeof l=="boolean"&&l||l==="auto"&&d==="mobile";utils.invariant(p,"ModalContent must be a child of Modal");let m=to__default.default.useRef(null),f=typeof r=="function"?r(c):r,y=typeof a=="function"?a(c):a,{underlayProps:g,overlayProps:v,close:b,containerHeight:h}=bc({isDisabled:!c,isDismissable:f},p,m),{modalProps:z,underlayProps:x}=reactAria.useModalOverlay({isDismissable:!c,isKeyboardDismissDisabled:y},p,m),{theme:R}=to.useContext(_o),C=web.useReducedMotion(),P=web.useSpring({from:{opacity:0,transform:"scale(0.95)"},to:{opacity:1,transform:"scale(1)"},immediate:!!C||n,config:{easing:web.easings.easeInBounce}}),k=to.useMemo(()=>({...z.style,...c?{...v.style,width:"100%"}:P}),[v.style,z.style,c,P]),T=to.useMemo(()=>({isDrawer:c,closeDrawer:b}),[c,b]);return jsxRuntime.jsx(reactAria.Overlay,{portalContainer:u,children:jsxRuntime.jsx(pi.Provider,{value:T,children:jsxRuntime.jsxs(n5,{className:utils.classNames(gc({enableDrawer:c}),t),theme:R,"data-block-id":s,style:{...o,height:c?h:"auto",...dynamic.assignInlineVars({[uc]:h})},children:[jsxRuntime.jsx(web.animated.div,{...reactAria.mergeProps(x,g),onPointerDown:c?g.onPointerDown:x.onPointerDown,"data-testid":"underlay",style:g.style,className:utils.classNames(vc,"BaselineUI-Modal-Underlay")}),jsxRuntime.jsx(web.animated.div,{...reactAria.mergeProps(z,v),style:k,ref:m,"data-drawer":c,className:"BaselineUI-Modal-Content",children:e})]})})})},l5=web.animated(s5),Te=({children:e,style:t,...o})=>{let{state:r}=to__default.default.useContext(je);utils.invariant(r,"ModalContent must be a child of Modal");let a=web.useReducedMotion();return web.useTransition(r.isOpen,{from:{opacity:0},enter:{opacity:1},immediate:!!a||o.disableAnimation})((n,l)=>l&&jsxRuntime.jsx(l5,{...o,style:{...t,...n},children:typeof e=="function"?e({close:r.close}):e}))};var Pc=_({defaultClassName:"cjv3et0 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6fs _1yep5z6d7",variantClassNames:{size:{sm:"cjv3et1",md:"cjv3et2",lg:"cjv3et3",content:"cjv3et4"},variant:{primary:"_1yep5z6121 _1yep5z616i _1yep5z616k",ghost:"cjv3et6"},isDrawer:{true:"cjv3et7 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg _1yep5z6166"}},defaultVariants:{},compoundVariants:[]});var di=to__default.default.createContext({titleProps:{}}),me=to__default.default.forwardRef(({children:e,className:t,style:o,inheritDrawer:r,size:a="md",variant:i="primary","data-block-id":n,drawerBackground:l,...s},p)=>{let d=to__default.default.useRef(null),u=to__default.default.useRef(null),{isDrawer:c,closeDrawer:m}=to.useContext(pi),[f,y]=to__default.default.useState("");to.useLayoutEffect(()=>{let h=u.current?.getRootNode(),z=s["aria-label"]||"";s["aria-labelledby"]&&(z=h?.querySelector(`#${s["aria-labelledby"].replaceAll(":","\\:")}`)?.textContent||""),y(z);},[s]);let{dialogProps:g,titleProps:v}=reactAria.useDialog(s,d),b=to.useMemo(()=>({titleProps:v}),[v]);return c&&r?jsxRuntime.jsx(hr,{title:f,onCloseRequest:m,className:t,...s,"data-drawer":!0,"data-block-id":n,ref:N(u,p),background:l,children:e}):jsxRuntime.jsx(di.Provider,{value:b,children:jsxRuntime.jsx("section",{...g,"data-block-id":n,ref:N(d,p),style:o,className:utils.classNames(Pc({size:c?"content":a,variant:i,isDrawer:c}),"BaselineUI-Dialog",t),children:e})})});me.displayName="Dialog";var wc=to__default.default.forwardRef(({children:e,className:t,style:o},r)=>{let{titleProps:a}=to.useContext(di),i=to__default.default.isValidElement(e)?reactSlot.Slot:"h3";return jsxRuntime.jsx(i,{...a,ref:r,className:t,style:o,children:e})});wc.displayName="DialogTitle";var $e={ar:{add:"\u0625\u0636\u0627\u0641\u0629",addColor:"\u0625\u0636\u0627\u0641\u0629 \u0644\u0648\u0646",cancel:"\u0625\u0644\u063A\u0627\u0621",colorFormat:"\u062A\u0646\u0633\u064A\u0642 \u0627\u0644\u0644\u0648\u0646",colorPresets:"\u0627\u0644\u0623\u0644\u0648\u0627\u0646 \u0627\u0644\u0645\u0633\u0628\u0642\u0629",customColors:"\u0623\u0644\u0648\u0627\u0646 \u0645\u062E\u0635\u0635\u0629",newColor:"\u0644\u0648\u0646 \u0645\u062E\u0635\u0635 \u062C\u062F\u064A\u062F",noColor:"\u0644\u0627 \u064A\u0648\u062C\u062F",removeColor:"\u0625\u0632\u0627\u0644\u0629 \u0627\u0644\u0644\u0648\u0646",transparent:"\u0634\u0641\u0627\u0641"},cs:{add:"P\u0159idat",addColor:"P\u0159idat barvu",cancel:"Zru\u0161it",colorFormat:"Form\xE1t barvy",colorPresets:"P\u0159edvolby barev",customColors:"Vlastn\xED barvy",newColor:"Vlastn\xED barva",noColor:"Nen\xED",removeColor:"Odebrat barvu",transparent:"Pr\u016Fhledn\xE1"},cy:{add:"Ychwanegu",addColor:"Ychwanegu Lliw",cancel:"Canslo",colorFormat:"Fformat Lliw",colorPresets:"Rhagosodiadau Lliw",customColors:"Lliwiau Custom",newColor:"Lliw Personol Newydd",noColor:"Dim",removeColor:"Tynnu Lliw",transparent:"Tryloyw"},da:{add:"Tilf\xF8j",addColor:"Tilf\xF8j Farve",cancel:"Annuller",colorFormat:"Farveformat",colorPresets:"Farvevalg",customColors:"Brugerdefinerede farver",newColor:"Ny tilpasset farve",noColor:"Ingen",removeColor:"Fjern Farve",transparent:"Transparent"},de:{add:"Hinzuf\xFCgen",addColor:"Farbe hinzuf\xFCgen",cancel:"Abbrechen",colorFormat:"Farbformat",colorPresets:"Farbvorlagen",customColors:"Benutzerdefinierte Farben",newColor:"Neue benutzerdefinierte Farbe",noColor:"Kein",removeColor:"Farbe entfernen",transparent:"Transparent"},el:{add:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7",addColor:"\u03A0\u03C1\u03BF\u03C3\u03B8\u03AE\u03BA\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",cancel:"\u0391\u03BA\u03CD\u03C1\u03C9\u03C3\u03B7",colorFormat:"\u039C\u03BF\u03C1\u03C6\u03AE \u03C7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",colorPresets:"\u03A0\u03C1\u03BF\u03B5\u03C0\u03B9\u03BB\u03BF\u03B3\u03AD\u03C2 \u03C7\u03C1\u03C9\u03BC\u03AC\u03C4\u03C9\u03BD",customColors:"\u03A0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03B1 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03B1",newColor:"\u039D\u03AD\u03BF \u03C0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03BC\u03AD\u03BD\u03BF \u03C7\u03C1\u03CE\u03BC\u03B1",noColor:"\u039A\u03B1\u03BD\u03AD\u03BD\u03B1\u03C2",removeColor:"\u0391\u03C6\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7 \u03A7\u03C1\u03CE\u03BC\u03B1\u03C4\u03BF\u03C2",transparent:"\u0397\u03BC\u03B9\u03B4\u03B9\u03B1\u03C6\u03B1\u03BD\u03AE\u03C2"},"en-GB":{add:"Add",addColor:"Add Colour",cancel:"Cancel",colorFormat:"Colour Format",colorPresets:"Colour Presets",customColors:"Custom Colours",newColor:"New Custom Colour",noColor:"None",removeColor:"Remove Colour",transparent:"Transparent"},en:{add:"Add",addColor:"Add Color",cancel:"Cancel",colorFormat:"Color Format",colorPresets:"Color Presets",customColors:"Custom Colors",newColor:"New Custom Color",noColor:"None",removeColor:"Remove Color",transparent:"Transparent"},es:{add:"A\xF1adir",addColor:"A\xF1adir color",cancel:"Cancelar",colorFormat:"Formato de color",colorPresets:"Preajustes de color",customColors:"Colores personalizados",newColor:"Nuevo color personalizado",noColor:"Ninguna",removeColor:"Eliminar color",transparent:"Transparente"},fi:{add:"Lis\xE4\xE4",addColor:"Lis\xE4\xE4 v\xE4ri",cancel:"Kumoa",colorFormat:"V\xE4rimuoto",colorPresets:"V\xE4rin esiasetukset",customColors:"Mukautetut v\xE4rit",newColor:"Uusi muokattu v\xE4ri",noColor:"Ei mit\xE4\xE4n",removeColor:"Poista v\xE4ri",transparent:"L\xE4pin\xE4kyv\xE4"},"fr-CA":{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},fr:{add:"Ajouter",addColor:"Ajouter une couleur",cancel:"Annuler",colorFormat:"Format de couleur",colorPresets:"Pr\xE9r\xE9glages de couleur",customColors:"Couleurs personnalis\xE9es",newColor:"Nouvelle couleur personnalis\xE9e",noColor:"Aucune",removeColor:"Supprimer la couleur",transparent:"Transparent"},he:{add:"\u05D4\u05D5\u05E1\u05E4\u05D4",addColor:"\u05D4\u05D5\u05E1\u05E3 \u05E6\u05D1\u05E2",cancel:"\u05D1\u05D9\u05D8\u05D5\u05DC",colorFormat:"\u05E4\u05D5\u05E8\u05DE\u05D8 \u05E6\u05D1\u05E2",colorPresets:"\u05DE\u05E6\u05D1\u05D9 \u05E6\u05D1\u05E2 \u05DE\u05EA\u05D5\u05DB\u05E0\u05EA\u05D9\u05DD",customColors:"\u05E6\u05D1\u05E2\u05D9\u05DD \u05DE\u05D5\u05EA\u05D0\u05DE\u05D9\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA",newColor:"\u05E6\u05D1\u05E2 \u05DE\u05D5\u05EA\u05D0\u05DD \u05D0\u05D9\u05E9\u05D9\u05EA \u05D7\u05D3\u05E9",noColor:"\u05DC\u05DC\u05D0",removeColor:"\u05D4\u05E1\u05E8 \u05E6\u05D1\u05E2",transparent:"\u05E9\u05E7\u05D5\u05E3"},hr:{add:"Dodati",addColor:"Dodaj boju",cancel:"Otka\u017Ei",colorFormat:"Format boje",colorPresets:"Prijedlozi boja",customColors:"Prilago\u0111ene boje",newColor:"Nova prilago\u0111ena boja",noColor:"Prazno",removeColor:"Ukloni boju",transparent:"Prozirna"},id:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batalkan",colorFormat:"Format Warna",colorPresets:"Preset Warna",customColors:"Warna Kustom",newColor:"Warna Khusus Baru",noColor:"Tidak ada",removeColor:"Hapus Warna",transparent:"Transparan"},it:{add:"Aggiungi",addColor:"Aggiungi colore",cancel:"Annulla",colorFormat:"Formato del colore",colorPresets:"Colori predefiniti",customColors:"Colori personalizzati",newColor:"Nuovo colore personalizzato",noColor:"Nessuno",removeColor:"Rimuovi colore",transparent:"Trasparente"},ja:{add:"\u8FFD\u52A0",addColor:"\u8272\u3092\u8FFD\u52A0",cancel:"\u30AD\u30E3\u30F3\u30BB\u30EB",colorFormat:"\u30AB\u30E9\u30FC\u30D5\u30A9\u30FC\u30DE\u30C3\u30C8",colorPresets:"\u30AB\u30E9\u30FC\u30D7\u30EA\u30BB\u30C3\u30C8",customColors:"\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",newColor:"\u65B0\u898F\u30AB\u30B9\u30BF\u30E0\u30AB\u30E9\u30FC",noColor:"\u306A\u3057",removeColor:"\u8272\u3092\u524A\u9664",transparent:"\u900F\u660E"},ko:{add:"\uCD94\uAC00",addColor:"\uC0C9\uC0C1 \uCD94\uAC00",cancel:"\uCDE8\uC18C",colorFormat:"\uC0C9\uC0C1 \uD615\uC2DD",colorPresets:"\uC0C9\uC0C1 \uBBF8\uB9AC\uC124\uC815",customColors:"\uC0AC\uC6A9\uC790 \uC815\uC758 \uC0C9\uC0C1",newColor:"\uC0C8\uB85C\uC6B4 \uC0AC\uC6A9\uC790\uC9C0\uC815 \uC0C9\uC0C1",noColor:"\uC5C6\uC74C",removeColor:"\uC0C9\uC0C1 \uC81C\uAC70",transparent:"\uD22C\uBA85"},ms:{add:"Tambah",addColor:"Tambah Warna",cancel:"Batal",colorFormat:"Format Warna",colorPresets:"Praset Warna",customColors:"Warna Kustom",newColor:"Warna Tersuai Baharu",noColor:"Tiada",removeColor:"Buang Warna",transparent:"Lut Sinar"},"nb-NO":{add:"Legg til",addColor:"Legg til farge",cancel:"Avbryt",colorFormat:"Fargeformat",colorPresets:"Fargeinnstillinger",customColors:"Egendefinerte farger",newColor:"Ny tilpasset farge",noColor:"Ingen",removeColor:"Fjern farge",transparent:"Gjennomsiktig"},nl:{add:"Voeg toe",addColor:"Kleur toevoegen",cancel:"Annuleer",colorFormat:"Kleurformaat",colorPresets:"Kleurvoorinstellingen",customColors:"Aangepaste kleuren",newColor:"Nieuwe aangepaste kleur",noColor:"Geen",removeColor:"Kleur verwijderen",transparent:"Doorzichtig"},pl:{add:"Dodaj",addColor:"Dodaj kolor",cancel:"Anuluj",colorFormat:"Format koloru",colorPresets:"Wst\u0119pnie ustawione kolory",customColors:"Niestandardowe kolory",newColor:"Nowy kolor niestandardowy",noColor:"Brak",removeColor:"Usu\u0144 kolor",transparent:"Prze\u015Bwiecaj\u0105ce"},"pt-PT":{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Predefini\xE7\xF5es de cor",customColors:"Cores personalizadas",newColor:"Nova cor personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},pt:{add:"Adicionar",addColor:"Adicionar cor",cancel:"Cancelar",colorFormat:"Formato de cor",colorPresets:"Pr\xE9-ajustes de Cores",customColors:"Cores personalizadas",newColor:"Nova Cor Personalizada",noColor:"Nenhum",removeColor:"Remover cor",transparent:"Transparente"},ru:{add:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C",addColor:"\u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0446\u0432\u0435\u0442",cancel:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u0446\u0432\u0435\u0442\u0430",colorPresets:"\u0411\u0438\u0431\u043B\u0438\u043E\u0442\u0435\u043A\u0430 \u0446\u0432\u0435\u0442\u043E\u0432",customColors:"\u041F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u0435\u043B\u044C\u0441\u043A\u0438\u0435 \u0446\u0432\u0435\u0442\u0430",newColor:"\u041D\u043E\u0432\u044B\u0439 \u0441\u043E\u0431\u0441\u0442\u0432\u0435\u043D\u043D\u044B\u0439 \u0446\u0432\u0435\u0442",noColor:"\u041D\u0435\u0442",removeColor:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0446\u0432\u0435\u0442",transparent:"\u041F\u0440\u043E\u0437\u0440\u0430\u0447\u043D\u044B\u0439"},sk:{add:"Prida\u0165",addColor:"Prida\u0165 farbu",cancel:"Zru\u0161i\u0165",colorFormat:"Form\xE1t farby",colorPresets:"Predvo\u013Eby farieb",customColors:"Vlastn\xE9 farby",newColor:"Vlastn\xE1 farba",noColor:"\u017Diadny",removeColor:"Odstr\xE1ni\u0165 farbu",transparent:"Prieh\u013Eadn\xE1"},sl:{add:"Dodaj",addColor:"Dodaj barvo",cancel:"Prekli\u010Di",colorFormat:"Barvni format",colorPresets:"Barvne predloge",customColors:"Prilagojene barve",newColor:"Nova barva po meri",noColor:"Prazna stran",removeColor:"Odstrani barvo",transparent:"Prosojna"},sv:{add:"L\xE4gg till",addColor:"L\xE4gg till f\xE4rg",cancel:"Avbryt",colorFormat:"F\xE4rgformat",colorPresets:"F\xF6rval f\xF6r f\xE4rger",customColors:"Anpassade f\xE4rger",newColor:"Ny anpassad f\xE4rg",noColor:"Ingen",removeColor:"Ta bort f\xE4rg",transparent:"Genomskinligt"},th:{add:"\u0E40\u0E1E\u0E34\u0E48\u0E21",addColor:"\u0E40\u0E1E\u0E34\u0E48\u0E21\u0E2A\u0E35",cancel:"\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01",colorFormat:"\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E2A\u0E35",colorPresets:"\u0E04\u0E48\u0E32\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E15\u0E31\u0E49\u0E07\u0E44\u0E27\u0E49\u0E25\u0E48\u0E27\u0E07\u0E2B\u0E19\u0E49\u0E32",customColors:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07",newColor:"\u0E2A\u0E35\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E40\u0E2D\u0E07\u0E43\u0E2B\u0E21\u0E48",noColor:"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E40\u0E25\u0E22",removeColor:"\u0E25\u0E1A\u0E2A\u0E35",transparent:"\u0E42\u0E1B\u0E23\u0E48\u0E07\u0E43\u0E2A"},tr:{add:"Ekle",addColor:"Renk Ekle",cancel:"Vazge\xE7",colorFormat:"Renk Format\u0131",colorPresets:"Renk \xD6nayarlar\u0131",customColors:"\xD6zel Renkler",newColor:"Yeni \xF6zel renk",noColor:"Hi\xE7biri",removeColor:"Rengi Kald\u0131r",transparent:"\u015Eeffaf"},uk:{add:"\u0414\u043E\u0434\u0430\u0442\u0438",addColor:"\u0414\u043E\u0434\u0430\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",cancel:"\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438",colorFormat:"\u0424\u043E\u0440\u043C\u0430\u0442 \u043A\u043E\u043B\u044C\u043E\u0440\u0443",colorPresets:"\u0411\u0456\u0431\u043B\u0456\u043E\u0442\u0435\u043A\u0430 \u043A\u043E\u043B\u044C\u043E\u0440\u0456\u0432",customColors:"\u041A\u043E\u0440\u0438\u0441\u0442\u0443\u0432\u0430\u0446\u044C\u043A\u0456 \u043A\u043E\u043B\u044C\u043E\u0440\u0438",newColor:"\u041D\u043E\u0432\u0438\u0439 \u0432\u043B\u0430\u0441\u043D\u0438\u0439 \u043A\u043E\u043B\u0456\u0440",noColor:"\u041D\u0435\u043C\u0430\u0454",removeColor:"\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438 \u043A\u043E\u043B\u0456\u0440",transparent:"\u041F\u0440\u043E\u0437\u043E\u0440\u0438\u0439"},"zh-Hans":{add:"\u6DFB\u52A0",addColor:"\u6DFB\u52A0\u989C\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u989C\u8272\u683C\u5F0F",colorPresets:"\u989C\u8272\u9884\u8BBE",customColors:"\u81EA\u5B9A\u4E49\u989C\u8272",newColor:"\u65B0\u81EA\u5B9A\u4E49\u989C\u8272",noColor:"\u65E0",removeColor:"\u79FB\u9664\u989C\u8272",transparent:"\u900F\u660E"},"zh-Hant":{add:"\u52A0\u5165",addColor:"\u6DFB\u52A0\u984F\u8272",cancel:"\u53D6\u6D88",colorFormat:"\u984F\u8272\u683C\u5F0F",colorPresets:"\u984F\u8272\u9810\u8A2D\u9805",customColors:"\u81EA\u8A02\u984F\u8272",newColor:"\u65B0\u81EA\u8A02\u984F\u8272",noColor:"\u7121",removeColor:"\u79FB\u9664\u984F\u8272",transparent:"\u900F\u660E"}};var Pr=({children:e})=>{let{triggerProps:t}=to__default.default.useContext(je);return jsxRuntime.jsx(reactSlot.Slot,{...t,children:e})};Pr.displayName="ModalTrigger";var P5=({children:e})=>{let{state:t}=to__default.default.useContext(je);return jsxRuntime.jsx(reactSlot.Slot,{onPress:()=>t?.close(),children:e})};var Ue=to__default.default.forwardRef((e,t)=>{let{state:o,overlayTriggerAria:{overlayProps:r},triggerRef:a}=to.useContext(Yo);return utils.invariant(a),o?.isOpen?jsxRuntime.jsx(le,{ref:t,...e,triggerRef:e.triggerRef||a,overlayProps:r,state:o}):null});Ue.displayName="PopoverContent";var Rc="_1dbkl53 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6kv",Ic="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jr _1yep5z6js _1yep5z6jt",Tc="_1dbkl5e",Nc=_({defaultClassName:"_1dbkl54 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l6 _1yep5z6ky _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6kx _1yep5z6dy",variantClassNames:{isHovered:{true:"_1dbkl55"},isFocusVisible:{true:"_1dbkl56"},isDisabled:{true:"z9nup83 _1yep5z6109"},labelPosition:{top:"_1dbkl58",start:"_1dbkl59"}},defaultVariants:{},compoundVariants:[]}),Sc=_({defaultClassName:"_1dbkl50 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6dy _1yep5z6ev",variantClassNames:{labelPosition:{top:"_1yep5z6nq _1yep5z6nr _1yep5z6ns",start:"_1dbkl52"}},defaultVariants:{},compoundVariants:[]}),kr="_1dbkl5l _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69f _1yep5z69g _1yep5z69h",Lc="_1dbkl5f z9nup87",wr="_1dbkl5m _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn",Mc="_1dbkl5k _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ky",Dc="_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6dy _1yep5z6ev _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ir _1yep5z6is _1yep5z6it",Rr=_({defaultClassName:"_1dbkl5h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs",variantClassNames:{includesCustomColorPicker:{true:"_1yep5z6me _1yep5z6mf _1yep5z6mg"}},defaultVariants:{},compoundVariants:[]}),mi="_1dbkl5v _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib",Bc=_({defaultClassName:"_1dbkl5q _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6br _1yep5z6bs _1yep5z6bt _1yep5z6d3 _1yep5z6d4 _1yep5z6d5 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6l7 _1yep5z6gq _1yep5z6ky _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocused:{true:"_1dbkl5r _1yep5z611y"},isHovered:{true:"_1dbkl5s"},allowAlpha:{false:"_1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6166"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,isFocused:!1},"_1yep5z61nd"]]}),Ec=_({defaultClassName:"_1dbkl5a _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62c _1yep5z62d _1yep5z62e _1yep5z63i _1yep5z63j _1yep5z63k _1yep5z616 _1yep5z617 _1yep5z618 _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e _1yep5z6f0 _1yep5z6kx _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kl",variantClassNames:{isHovered:{true:"_1yep5z6115"},isFocusVisible:{true:"_1yep5z616c _1yep5z616a _1yep5z616d _1yep5z612n"},isDisabled:{true:"_1yep5z610d"}},defaultVariants:{},compoundVariants:[]}),dt="_1dbkl5u",Ir="_1dbkl5g _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7",Tr="_1dbkl5j _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",ui="_1dbkl5x",Fc="_1dbkl5w",fi="_1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69l _1yep5z69m _1yep5z69n",Nr=_({defaultClassName:"_1dbkl5n _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6l2 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6l7 _1yep5z6la",variantClassNames:{isFocusVisible:{true:"_1dbkl5o _1yep5z616a _1yep5z612n _1yep5z616c"}},defaultVariants:{},compoundVariants:[]}),yi="z9nup84 z9nup86 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6ko _1yep5z6kp _1yep5z6kr _1yep5z6kq _1yep5z6ho _1yep5z6hp _1yep5z6hq";var Hc=_({defaultClassName:"_1344e9q0 _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ks _1yep5z6hk _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn",variantClassNames:{isFocusVisible:{true:"_1344e9q1"},isDisabled:{true:"_1344e9q2"},removeBlendMode:{true:"_1344e9q3"},isSelected:{true:"_1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616f"},isHovered:{true:"_1344e9q5"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isFocusVisible:!0},"_1344e9q6"],[{isSelected:!0,isFocusVisible:!0},"_1344e9q7 _1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61rn _1yep5z61rl _1yep5z61ny _1yep5z61rq _1yep5z61o5"],[{isHovered:!0,isSelected:!1},"_1yep5z61rq _1yep5z61rn _1yep5z61rl _1yep5z61o2"]]});var he=to__default.default.forwardRef(({color:e,isFocusVisible:t,isSelected:o,isInteractive:r,isDisabled:a,style:i,className:n,id:l,"data-block-id":s,...p},d)=>{let u=e&&e!==xe&&(typeof e=="string"?color.parseColor(e):e),{formatMessage:c}=B(),m=!u,{colorSwatchProps:f}=color$1.useColorSwatch({color:m?"#000000":e}),{hoverProps:y,isHovered:g}=reactAria.useHover({isDisabled:a||!r}),v=utils.filterTruthyValues({"data-focus-visible":t,"data-selected":o,"data-hovered":g,"data-block-id":s,"data-disabled":a,"data-interactive":r});return jsxRuntime.jsx("div",{...reactAria.mergeProps(y,v,m?{}:f),style:i,"aria-label":m?c(H5.none):f["aria-label"],role:"img",className:utils.classNames(Hc({removeBlendMode:m,isFocusVisible:t,isDisabled:!!a,isSelected:!!o,isHovered:g}),"BaselineUI-ColorSwatch",n),ref:d,id:l,...p,children:jsxRuntime.jsx(M,{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"full",height:"full",width:"full",opacity:a?"medium":void 0,style:u?Oc(u,4):void 0,children:m?jsxRuntime.jsx(_16.NoneIcon,{size:14}):null})})});he.displayName="ColorSwatch";var H5=j({none:{id:"none",defaultMessage:"None"}});var Ac=[{id:"hex",label:"HEX"},{id:"rgb",label:"RGB"}],Lo=color.parseColor("#000000").toFormat("hsla"),J="hsla",mt="hexa";function Je(e){return typeof e=="string"?color.parseColor(e).toFormat(J):e?e.toFormat(J):null}function jc(e,t){return e?.getChannelValue("alpha")?t?.toString(mt)===e.toString(mt):!t?.getChannelValue("alpha")}function $c(e,t,o){return t?.label?t.label:e?.getChannelValue("alpha")===0?o:e?.toString("rgba")}var xe="NONE";function Uc(e,t){let o=t?.map(a=>({id:color.parseColor(a.color).toString(mt),label:a.label}))||[],r={id:xe,label:e};return [...o,r]}var Sr=(e,{optionProps:t,isFocusVisible:o,isSelected:r},a)=>(utils.invariant(e.value&&"label"in e.value,"Item must have label"),jsxRuntime.jsx("li",{...t,ref:a,className:Mc,children:jsxRuntime.jsx(he,{color:e.value.id,isFocusVisible:o,isSelected:r,"aria-label":e.value.label,isInteractive:!0})})),Oc=(e,t=4)=>{let o=e.getChannelValue("alpha")===0,r=`repeating-conic-gradient(transparent 0% 25%, ${tokens.themeVars.color.background.secondary.medium} 25% 50%)`;return {backgroundImage:o?r:`linear-gradient(${e.toString("hexa")}, ${e.toString("hexa")}), ${r}`,backgroundSize:`${t}px ${t}px`}};var Kc=({value:e,...t})=>{let o=to__default.default.useRef(null),r=to__default.default.useRef(null),a=to__default.default.useRef(null),i=color.useColorAreaState({...t,value:e}),{colorAreaProps:n,xInputProps:l,yInputProps:s,thumbProps:p}=color$1.useColorArea({...t,value:e,inputXRef:o,inputYRef:r,containerRef:a},i);to.useEffect(()=>{o.current?.focus();},[]);let{focusProps:d,isFocusVisible:u}=reactAria.useFocusRing();return jsxRuntime.jsx("div",{ref:a,...n,className:utils.classNames(Rc,"BaselineUI-ColorInput-ColorArea"),children:jsxRuntime.jsxs("div",{...p,className:utils.classNames(Nr({isFocusVisible:u}),"BaselineUI-ColorInput-ColorAreaThumb"),style:{...p.style,transform:"translate(-50%, -50%)",backgroundColor:Je(e)?.withChannelValue("alpha",1).toString("css")},children:[jsxRuntime.jsx("input",{ref:o,...l,...d}),jsxRuntime.jsx("input",{ref:r,...s,...d})]})})};var Xc=({color:e,setColor:t,allowAlpha:o,...r})=>{let a=color.useColorFieldState({value:e,onChange:u=>{t(Je(u)?.toFormat(J).withChannelValue("alpha",e.getChannelValue("alpha")??1)||Lo);}}),i=to__default.default.useRef(null),{inputProps:n}=color$1.useColorField({...r,"aria-label":"Hex"},a,i),{focusProps:l,isFocused:s}=reactAria.useFocusRing({isTextInput:!0}),{hoverProps:p,isHovered:d}=reactAria.useHover({});return jsxRuntime.jsxs("div",{className:utils.classNames(mi,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"hexa":"hex",children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(n,l,p),ref:i,className:Bc({isFocused:s,isHovered:d,allowAlpha:o})}),o?jsxRuntime.jsx(Zc,{color:e,setColor:t}):null]})},Yc=({color:e,setColor:t,allowAlpha:o})=>{let r=e.toFormat("rgba"),{locale:a}=reactAria.useLocale();return jsxRuntime.jsxs("div",{className:utils.classNames(mi,"BaselineUI-ColorInput-FieldInput"),"data-color-mode":o?"rgba":"rgb",children:[jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("red",a),value:r.getChannelValue("red"),showStepper:!1,className:dt,onChange:i=>{t(r.withChannelValue("red",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("green",a),value:r.getChannelValue("green"),showStepper:!1,className:dt,onChange:i=>{t(r.withChannelValue("green",i).toFormat(J));},step:1,minValue:0,maxValue:255}),jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("blue",a),value:r.getChannelValue("blue"),showStepper:!1,className:dt,onChange:i=>{t(r.withChannelValue("blue",i).toFormat(J));},step:1,minValue:0,maxValue:255}),o?jsxRuntime.jsx(Zc,{color:e,setColor:t}):null]})},J5={style:"percent",maximumFractionDigits:0},Zc=({color:e,setColor:t})=>{let{locale:o}=reactAria.useLocale(),r=to.useCallback(a=>{t(e.withChannelValue("alpha",a));},[e,t]);return jsxRuntime.jsx(Ie,{"aria-label":e.getChannelName("alpha",o),value:e.getChannelValue("alpha"),formatOptions:J5,className:dt,showStepper:!1,onChange:r,minValue:0,maxValue:1})};var zi=({channel:e,...t})=>{let{locale:o}=reactAria.useLocale(),r=color.useColorSliderState({...t,channel:e,locale:o}),a=to__default.default.useRef(null),i=to__default.default.useRef(null),{trackProps:n,thumbProps:l,inputProps:s}=color$1.useColorSlider({...t,channel:e,trackRef:a,inputRef:i,"aria-label":r.value.getChannelName(e,o)},r),{focusProps:p,isFocusVisible:d}=reactAria.useFocusRing();return jsxRuntime.jsxs("div",{className:utils.classNames(wr,{[Qn({size:"xs"})]:e==="alpha"},"BaselineUI-ColorInput-ColorSlider"),"data-channel":e,...n,ref:a,children:[e==="alpha"&&jsxRuntime.jsx("div",{className:yi}),jsxRuntime.jsx("div",{className:wr,style:n.style}),jsxRuntime.jsxs("div",{className:utils.classNames(Nr({isFocusVisible:d}),"BaselineUI-ColorInput-ColorSliderThumb"),...l,children:[jsxRuntime.jsx("div",{className:yi,style:{backgroundColor:"#ffffff"}}),jsxRuntime.jsx("div",{style:{backgroundColor:r.getDisplayColor().toString("css"),height:8},className:wr}),jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{ref:i,...s,...p})})]})]})};var Lr=({color:e,setColor:t,allowAlpha:o})=>{let[r,a]=to__default.default.useState("hex"),{formatMessage:i}=B($e);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Kc,{value:e,xChannel:"saturation",yChannel:"lightness",onChange:t}),jsxRuntime.jsxs("div",{className:fi,children:[jsxRuntime.jsx(zi,{channel:"hue",value:e,onChange:t}),o?jsxRuntime.jsx(zi,{channel:"alpha",value:e,onChange:t}):null]}),jsxRuntime.jsxs("div",{className:utils.classNames(fi,tokens.sprinkles.variants({paddingTop:"none",gap:"sm"})),children:[jsxRuntime.jsx(Ae,{label:i("colorFormat"),labelPosition:"start",variant:"ghost",items:Ac,selectedKey:r,onSelectionChange:n=>{a(n);}}),r==="hex"&&jsxRuntime.jsx(Xc,{color:e,setColor:t,allowAlpha:o}),r==="rgb"&&jsxRuntime.jsx(Yc,{color:e,setColor:t,allowAlpha:o})]})]})};var Ci=({color:e,setColor:t,storePickedColorKey:o,addColorButtonLabel:r,removeColorButtonLabel:a,customColorsLabel:i,pickerMode:n,allowAlpha:l})=>{let{locale:s}=reactAria.useLocale(),{formatMessage:p}=B($e),d=to__default.default.useRef(null),u=go(d.current),[c,m]=Hs(o,[]),f=to__default.default.useRef(null),[y,g]=to__default.default.useState(e),v=to__default.default.useMemo(()=>c.map(C=>({id:C,label:color.parseColor(C).getColorName(s),description:C})),[c,s]),b=to.useCallback(()=>{let C=n==="active"?e:y;if(c.includes(C.toString(J))){f.current?.querySelector(`[data-key='${C.toString(J)}']`)?.classList.add(ui);return}m([...c,C.toString(J)]);},[c,e,m,y,n]);to.useEffect(()=>{let C=f.current;function P(k){k.animationName===Fc&&k.target?.classList.remove(ui);}return C?.addEventListener("animationend",P),()=>{C?.removeEventListener("animationend",P);}},[]);let h=reactAria.useId(),z=jsxRuntime.jsx(L,{ref:d,variant:"secondary",size:"md","aria-label":r,icon:_20.PlusIcon,onPress:n==="active"?b:void 0}),x=to.useCallback(C=>jsxRuntime.jsxs(me,{size:"content",className:Rr({includesCustomColorPicker:!0}),style:{paddingBlockEnd:0},"aria-label":p("newColor"),children:[jsxRuntime.jsx(Lr,{color:y,setColor:g,allowAlpha:l}),jsxRuntime.jsx(F,{}),jsxRuntime.jsx(M,{padding:"lg",display:"flex",flexDirection:"row-reverse",children:jsxRuntime.jsxs(M,{display:"inline-flex",gap:"lg",children:[jsxRuntime.jsx(O,{label:p("cancel"),size:"sm",variant:"secondary",onPress:C}),jsxRuntime.jsx(O,{label:p("add"),variant:"primary",onPress:()=>{b(),C();},size:"sm"})]})})]}),[y,b,p,l]),R=to.useCallback(C=>{utils.invariant(C instanceof Set,"Key must be a set");let P=[...C][0];P&&t(color.parseColor(P).toFormat(J));},[t]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(F,{}),jsxRuntime.jsxs("div",{className:utils.classNames(Dc,"BaselineUI-ColorInput-CustomColors"),children:[jsxRuntime.jsx("span",{id:h,children:i}),jsxRuntime.jsxs(M,{display:"flex",children:[!!c.length&&c.includes(e.toString(J))&&jsxRuntime.jsx(L,{variant:"secondary",size:"md",elementType:"div",icon:_20.MinusIcon,"aria-label":a,onPress:()=>{m(c.filter(C=>C!==e.toString(J)));}}),n==="active"&&z,n==="lazy"&&(u==="mobile"?jsxRuntime.jsxs(ze,{children:[jsxRuntime.jsx(Pr,{children:z}),jsxRuntime.jsx(Te,{style:{zIndex:1e5},children:({close:C})=>x(C)})]}):jsxRuntime.jsx(Xe,{type:"dialog",children:({close:C})=>jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Ye,{children:z}),jsxRuntime.jsx(Ue,{placement:"right top",className:Ir,offset:6,children:x(C)})]})}))]})]}),!!c.length&&jsxRuntime.jsx(te,{items:v,layout:"grid","aria-labelledby":h,className:utils.classNames(kr,Tr,tokens.sprinkles.variants({paddingTop:"xs"}),"BaselineUI-ColorInput-CustomColorsListBox"),renderOption:Sr,ref:f,autoFocus:!1,selectionMode:"single",selectedKeys:[e.toString(J)],onSelectionChange:R})]})};var Pi=to__default.default.forwardRef(({setColor:e,color:t,triggerRef:o,autoFocus:r,presets:a,state:i},n)=>{let{formatMessage:l}=B($e),s=to.useCallback(p=>{if(p instanceof Set&&p.size){let d=[...p][0],u=a.find(c=>c.id===d);utils.invariant(u,"Preset not found"),e(u.id===xe?null:color.parseColor(u.id).toFormat(J)),i.close();}},[i,a,e]);return jsxRuntime.jsx("div",{className:utils.classNames(Tr,"BaselineUI-ColorInput-Presets"),style:{minWidth:o.current?.offsetWidth},ref:n,children:jsxRuntime.jsx(te,{autoFocus:r,items:a,layout:"grid","aria-label":l("colorPresets"),className:kr,renderOption:Sr,selectionMode:"single",selectedKeys:[t?.toString(mt)||xe],onSelectionChange:s})})});Pi.displayName="ColorPresetList";var ft=to__default.default.forwardRef(({color:e,colorLabel:t,colorName:o,...r},a)=>{let i=to__default.default.useRef(null),{hoverProps:n,isHovered:l}=reactAria.useHover({isDisabled:r.isDisabled}),{buttonProps:s,isPressed:p}=reactAria.useButton(r,i),{isFocusVisible:d,focusProps:u}=reactAria.useFocusRing(),c=utils.filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":d,"data-focus-visible":d,"data-disabled":r.isDisabled,"data-hovered":l,"data-pressed":p});return jsxRuntime.jsxs("button",{...reactAria.mergeProps(s,n,u,c),style:r.style,className:utils.classNames(Nc({isHovered:l,isFocusVisible:d||r.isOpen,isDisabled:r.isDisabled,labelPosition:r.labelPosition}),"BaselineUI-ColorInputButton",r.className),ref:N(a,i),children:[jsxRuntime.jsx(he,{color:e?.toString("hexa")}),t?jsxRuntime.jsx("div",{className:Lc,children:o}):jsxRuntime.jsx(reactAria.VisuallyHidden,{children:o})]})});ft.displayName="ColorInputButton";var Br=to__default.default.forwardRef(({className:e,style:t,icon:o,...r},a)=>{let i=to__default.default.useRef(null),{hoverProps:n,isHovered:l}=reactAria.useHover({isDisabled:r.isDisabled}),{buttonProps:s,isPressed:p}=reactAria.useButton(r,i),{isFocusVisible:d,focusProps:u}=reactAria.useFocusRing(),c=utils.filterTruthyValues({"data-block-id":r["data-block-id"],"data-focused":d,"data-focus-visible":d,"data-disabled":r.isDisabled,"data-hovered":l,"data-pressed":p});return jsxRuntime.jsxs("button",{...reactAria.mergeProps(s,n,u,c),ref:N(a,i),style:t,className:utils.classNames(Ec({isHovered:l||p||r.isOpen,isFocusVisible:d,isDisabled:r.isDisabled}),"BaselineUI-IconColorInputButton",e),children:[jsxRuntime.jsx(o,{size:16}),jsxRuntime.jsx("div",{className:Tc,style:{backgroundColor:r.color||void 0}})]})});Br.displayName="IconColorInputButton";function ud({colorLabel:e,color:t,presets:o}){let{formatMessage:r}=B(),{locale:a}=reactAria.useLocale(),i=to.useMemo(()=>o.find(s=>s.id===xe?!t:t?jc(t,color.parseColor(s.id)):!1),[o,t]),n=to.useMemo(()=>typeof e=="function"?e?.(t):e?$c(t,i,r(Pz.transparent)):!1,[t,e,r,i]),l=to.useMemo(()=>{if(i?.label)return i.label;t?.getColorName(a);},[t,a,i?.label]);return {colorName:n,humanReadableName:l}}var Pz=j({transparent:{defaultMessage:"Transparent",id:"transparent"}});var Bo=to__default.default.forwardRef(({className:e,style:t,allowRemoval:o,allowAlpha:r=!0,presets:a,labelPosition:i="top",colorLabel:n=!0,includePicker:l=!0,onChange:s,defaultValue:p,storePickedColorKey:d="baselinePickedColor",value:u,addColorButtonLabel:c,removeColorButtonLabel:m,customColorsLabel:f,renderTriggerButton:y=({isOpen:R,color:C,ref:P,colorName:k,triggerProps:T,labelId:I})=>jsxRuntime.jsx(ft,{...reactAria.mergeProps(T,{...z.label?{"aria-labelledby":I}:{"aria-label":z["aria-label"]}}),ref:P,isOpen:R,isDisabled:z.isDisabled,labelPosition:i,color:C,colorLabel:n,colorName:k}),pickerMode:g="active",offset:v=2,placement:b=i==="start"?"bottom end":"bottom start","data-block-id":h,...z},x)=>{let R=to__default.default.useRef(null),C=to__default.default.useRef(null),P=reactStately.useOverlayTriggerState(z),{triggerProps:k,overlayProps:T}=reactAria.useOverlayTrigger({type:"listbox"},P,R),I=de(z.portalContainer),[D,E]=utils$1.useControlledState(u===void 0?void 0:Je(u),Je(p),V=>s?.(V?.toFormat("rgba")||null)),{formatMessage:w}=B($e),S=to.useMemo(()=>Uc(w(Er.noColor),a),[a,w]),$=reactAria.useId(),{colorName:re}=ud({colorLabel:n,color:D,presets:S}),pe=to.useMemo(()=>S.filter(V=>o||V.id!==xe),[S,o]),X=c||w(Er.addColor),K=m||w(Er.removeColor),G=f||w(Er.customColors);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("div",{className:utils.classNames({[Ic]:i==="start"},"BaselineUI-ColorInput-Trigger",e),"data-block-id":h,style:t,ref:x,children:[z.label?jsxRuntime.jsx("label",{id:$,className:Sc({labelPosition:i}),children:z.label}):null,y({isOpen:P.isOpen,color:D,ref:R,colorName:re,triggerProps:k,labelId:$})]}),P.isOpen?jsxRuntime.jsx(le,{...z,portalContainer:I,placement:b,state:P,offset:v,className:utils.classNames(Ir,"BaselineUI-ColorInput-Popover"),triggerRef:R,overlayProps:T,children:jsxRuntime.jsxs(me,{size:"content",className:Rr({includesCustomColorPicker:l}),ref:C,"aria-labelledby":$,"aria-label":z["aria-label"],children:[l&&g==="active"?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Lr,{color:D||Lo,setColor:E,allowAlpha:r}),jsxRuntime.jsx(Ci,{color:D||Lo,setColor:E,storePickedColorKey:d,addColorButtonLabel:X,removeColorButtonLabel:K,customColorsLabel:G,pickerMode:g,allowAlpha:r})]}):null,!!pe.length&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[l&&g==="active"?jsxRuntime.jsx(F,{}):null,jsxRuntime.jsx(Pi,{autoFocus:l&&g==="active"?!1:"first",state:P,triggerRef:R,presets:pe,color:D,setColor:E})]}),l&&g==="lazy"?jsxRuntime.jsx(Ci,{color:D||Lo,setColor:E,storePickedColorKey:d,addColorButtonLabel:X,removeColorButtonLabel:K,customColorsLabel:G,pickerMode:g,allowAlpha:r}):null]})}):null]})});Bo.displayName="ColorInput";var Er=j({addColor:{defaultMessage:"Add color",id:"addColor"},removeColor:{defaultMessage:"Remove color",id:"removeColor"},customColors:{defaultMessage:"Custom colors",id:"customColors"},noColor:{defaultMessage:"No color",id:"noColor"},transparent:{defaultMessage:"Transparent",id:"transparent"}});var gd=to__default.default.forwardRef(({className:e,style:t,icon:o,includeTooltip:r,variant:a="standard","data-block-id":i,placement:n="bottom start",...l},s)=>{let p=to__default.default.useRef(null),d=to.useCallback(({isOpen:u,color:c,ref:m,colorName:f,triggerProps:y})=>jsxRuntime.jsx(He,{isDisabled:!r||l.isDisabled,variant:"inverse",size:"sm",includeArrow:!1,text:l["aria-label"],placement:n,offset:4,children:a==="standard"?jsxRuntime.jsx(ft,{...y,"aria-label":l["aria-label"],ref:m,isOpen:u,isDisabled:l.isDisabled,color:c,colorLabel:!1,colorName:f}):jsxRuntime.jsx(Br,{...y,isOpen:u,icon:_20.TextIcon,color:c?.toString("hexa"),ref:m,isDisabled:l.isDisabled,"aria-label":l["aria-label"]})}),[r,n,l,a]);return jsxRuntime.jsxs(M,{display:"flex",flexDirection:"row",gap:"md",paddingX:a==="standard"?"md":"none",alignItems:"center",className:utils.classNames("BaselineUI-IconColorInput",e),"data-block-id":i,style:t,ref:N(s,p),children:[a==="standard"&&jsxRuntime.jsx(o,{size:24,className:tokens.sprinkles({color:"icon.primary"})}),jsxRuntime.jsx(Bo,{...l,colorLabel:!1,renderTriggerButton:d})]})});gd.displayName="IconColorInput";var vd={ar:{redo:"\u0625\u0639\u0627\u062F\u0629",undo:"\u062A\u0631\u0627\u062C\u0639"},cs:{redo:"Opakovat",undo:"Zru\u0161it"},cy:{redo:"Ail-wneud",undo:"Dad-wneud"},da:{redo:"Gentag",undo:"Fortryd"},de:{redo:"Wiederholen",undo:"R\xFCckg\xE4ngig machen"},el:{redo:"\u0395\u03C0\u03B1\u03BD\u03AC\u03BB\u03B7\u03C8\u03B7",undo:"\u0391\u03BD\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7"},"en-GB":{redo:"Redo",undo:"Undo"},en:{redo:"Redo",undo:"Undo"},es:{redo:"Rehacer",undo:"Deshacer"},fi:{redo:"Tee sittenkin",undo:"Peru"},"fr-CA":{redo:"R\xE9tablir",undo:"Annuler"},fr:{redo:"R\xE9tablir",undo:"Annuler"},he:{redo:"\u05D1\u05D9\u05E6\u05D5\u05E2 \u05DE\u05D7\u05D3\u05E9",undo:"\u05D1\u05D9\u05D8\u05D5\u05DC \u05E4\u05E2\u05D5\u05DC\u05D4"},hr:{redo:"Ponovi",undo:"Vrati"},id:{redo:"Ulangi",undo:"Kembalikan"},it:{redo:"Ripristina",undo:"Annulla"},ja:{redo:"\u3084\u308A\u76F4\u3059",undo:"\u53D6\u308A\u6D88\u3059"},ko:{redo:"\uC2E4\uD589\uBCF5\uADC0",undo:"\uC2E4\uD589\uCDE8\uC18C"},ms:{redo:"Buat Semula",undo:"Buat Asal"},"nb-NO":{redo:"Gj\xF8r om igjen",undo:"Angre"},nl:{redo:"Opnieuw",undo:"Herstel"},pl:{redo:"Pon\xF3w",undo:"Cofnij"},"pt-PT":{redo:"Refazer",undo:"Desfazer"},pt:{redo:"Refazer",undo:"Desfazer"},ru:{redo:"\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u044C",undo:"\u041E\u0442\u043C\u0435\u043D\u0438\u0442\u044C"},sk:{redo:"Opakova\u0165",undo:"Zru\u0161i\u0165"},sl:{redo:"Uveljavi",undo:"Razveljavi"},sv:{redo:"G\xF6r om",undo:"\xC5ngra"},th:{redo:"\u0E17\u0E33\u0E0B\u0E49\u0E33",undo:"\u0E16\u0E2D\u0E19\u0E04\u0E33\u0E2A\u0E31\u0E48\u0E07\u0E01\u0E25\u0E31\u0E1A"},tr:{redo:"Yinele",undo:"Geri Al"},uk:{redo:"\u041F\u043E\u0432\u0442\u043E\u0440\u0438\u0442\u0438",undo:"\u0421\u043A\u0430\u0441\u0443\u0432\u0430\u0442\u0438"},"zh-Hans":{redo:"\u91CD\u505A",undo:"\u64A4\u9500"},"zh-Hant":{redo:"\u91CD\u4F5C",undo:"\u5FA9\u539F"}};var Fr=_({defaultClassName:"mnnh5s1 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6ki _1yep5z6kl _1yep5z6kx _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{true:"mnnh5s2 _1yep5z6vw _1yep5z6vx _1yep5z6vy _1yep5z6wk _1yep5z6wl _1yep5z6wm _1yep5z6x8 _1yep5z6x9 _1yep5z6xa _1yep5z6xw _1yep5z6xx _1yep5z6xy _1yep5z6122 _1yep5z616j _1yep5z616k",false:"_1yep5z6166 _1yep5z6116"},isHovered:{true:"mnnh5s4"},hasLoadedImage:{true:"_1yep5z6115"},includeCheckeredBackground:{true:"mnnh5s6"},showFocusRing:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 _1yep5z6yl"}},defaultVariants:{},compoundVariants:[[{isHovered:!0,hasLoadedImage:!1},"_1yep5z61mo"],[{isHovered:!0,hasLoadedImage:!0},"mnnh5s9"],[{isInline:!0,isDisabled:!0},"_1yep5z61nd"],[{hasLoadedImage:!0,includeCheckeredBackground:!0},"_1yep5z61mg"]]}),_d="_1yep5z6d8",Hr=_({defaultClassName:"mnnh5sa",variantClassNames:{isInline:{true:"mnnh5sb",false:"mnnh5sc"},isDisabled:{true:"mnnh5sd"},hasLoadedImage:{true:"mnnh5s0"}},defaultVariants:{},compoundVariants:[]});var zd=_({defaultClassName:"_1i0ytqa3 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6kw _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1i0ytqa4"},isInline:{true:"_1yep5z611e",false:"_1yep5z611g"},isDisabled:{true:"_1i0ytqa7 _1yep5z6yl",false:"_1i0ytqa8"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isFocusVisible:!0},"_1i0ytqa9 _1yep5z61n9 _1yep5z61rt _1yep5z61rv"],[{isInline:!1,isFocusVisible:!0},"_1i0ytqaa"],[{isInline:!0,isDisabled:!0},"_1yep5z61mp"],[{isInline:!1,isDisabled:!0},"_1yep5z61mr"]]}),hd="_1i0ytqa0",Or=_({defaultClassName:"_1i0ytqab _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z6115"},isDisabled:{true:"_1i0ytqad _1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),xd=_({defaultClassName:"_1i0ytqa1 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jr _1yep5z6js _1yep5z6jt _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kv",variantClassNames:{isInline:{false:"_1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b"}},defaultVariants:{},compoundVariants:[]});var Wz={size:1,thinning:0,smoothing:0,streamline:0,easing:e=>e,start:{taper:0,easing:e=>e,cap:!0},end:{taper:0,easing:e=>e,cap:!0},simulatePressure:!1},kd=to__default.default.forwardRef(({className:e,style:t,canvasClassName:o,canvasStyle:r,isBound:a=!0,strokeWidth:i=2,strokeColor:n="#3A87FD",onChange:l,defaultValue:s,onChangeEnd:p,enableHistory:d=!1,isInline:u=!0,isDisabled:c,placeholder:m,clearLabel:f,undoLabel:y,redoLabel:g,footerClassName:v,canvasRef:b,value:h,footerStyle:z,"data-block-id":x,"aria-label":R="Drawing canvas",description:C="This is a canvas for drawing using a mouse or touch input.",...P},k)=>{let T=B(vd),I=to__default.default.useRef(null),[D,E]=to__default.default.useState(h?Ni(h):s?Ni(s):[]),w=to__default.default.useMemo(()=>({...Wz,...P}),[P]),[S,$]=to__default.default.useState(),re=reactAria.useId(),{labelProps:pe,fieldProps:X}=reactAria.useLabel({...P,"aria-label":R,labelElementType:"span"}),{isFocusVisible:K,focusProps:G}=reactAria.useFocusRing({within:!0}),{hoverProps:V,isHovered:Z}=reactAria.useHover({isDisabled:c}),{undo:ee,redo:Ce,canRedo:Pe,canUndo:ye,push:ke}=Ms(D,{onAction:A=>{A&&(E(A),p?.(A.map(H=>perfectFreehand.getStroke(H,w))));},isDisabled:!d}),{keyboardProps:Le}=reactAria.useKeyboard({onKeyDown:A=>{A.key==="Backspace"?Ot():A.key==="z"&&(A.metaKey||A.ctrlKey)&&(A.shiftKey?Pe&&Ce():ye&&ee());}}),[oe,ce]=to.useState(!1),sa=to.useCallback(A=>{let H=A.currentTarget.getBoundingClientRect();$(H),A.target.setPointerCapture(A.pointerId);let ae={x:A.clientX-H.x,y:A.clientY-H.y,pressure:A.pressure};E(U=>[...U,[ae]]),ce(!0);},[]),la=to.useCallback(A=>{if(A.buttons!==1||!S)return;let ae=Id(A.nativeEvent).map(U=>({x:a?utils$1.clamp(U.clientX-S.left,0,S.width):U.clientX-S.left,y:a?utils$1.clamp(U.clientY-S.top,0,S.height):U.clientY-S.top,pressure:U.pressure}));E(U=>{let be=[...U];return be[U.length-1]=[...be[U.length-1],...ae],be});},[S,a]),pa=to.useCallback(()=>{S&&(p?.(D.map(A=>perfectFreehand.getStroke(A,w))),ke(D),ce(!1));},[S,p,D,ke,w]),Ht=Fe();granularHooks.useGranularEffect(()=>{Ht||l?.(D.map(A=>perfectFreehand.getStroke(A,w)));},[D],[l,w,Ht]);let Ot=()=>{E([]),l?.([]),ke([]);};return jsxRuntime.jsxs("div",{ref:N(I,k),className:utils.classNames(hd,"BaselineUI-FreehandCanvas",e),style:t,"aria-disabled":c,"data-block-id":x,children:[P.label||d?jsxRuntime.jsxs("div",{className:xd({isInline:u}),children:[P.label?jsxRuntime.jsx(W,{type:"label",size:"sm",...pe,children:P.label}):jsxRuntime.jsx("span",{}),d?jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx(L,{variant:"secondary",size:"sm",isDisabled:!ye||c,icon:_16.UndoIcon,onPress:ee,"aria-label":y||T.formatMessage("undo")}),jsxRuntime.jsx(L,{variant:"secondary",size:"sm",isDisabled:!Pe||c,icon:_16.RedoIcon,onPress:Ce,"aria-label":g||T.formatMessage("redo")})]}):null]}):null,jsxRuntime.jsxs("div",{role:"application",...reactAria.mergeProps(G,Le,V,X),tabIndex:c?void 0:0,className:utils.classNames(Fr({isInline:u,isHovered:Z}),zd({isFocusVisible:K,isInline:u,isDisabled:!!c}),o),"aria-describedby":P["aria-describedby"]||re,style:r,ref:b,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("div",{id:re,children:C})}),jsxRuntime.jsx("svg",{width:r?.width||"100%",height:r?.height||"100%",onPointerDown:sa,onPointerMove:la,onPointerUp:pa,children:(h?Ni(h):D).map((A,H,ae)=>H<ae.length-1||!oe?jsxRuntime.jsx(wd,{points:A,options:w,strokeColor:n,strokeWidth:i},H):jsxRuntime.jsx(Rd,{points:A,options:w,strokeColor:n,strokeWidth:i},H))})]}),m||f?jsxRuntime.jsx("div",{style:z,className:utils.classNames(Or({isInline:u,isDisabled:c}),v),children:(D.length||!m)&&f?jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:f,isDisabled:c,onPress:Ot}):jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:m,isDisabled:!0})}):null]})});kd.displayName="FreehandCanvas";var wd=to__default.default.memo(({points:e,options:t,strokeColor:o,strokeWidth:r})=>{let a=to.useMemo(()=>utils.getSvgPathFromStroke(perfectFreehand.getStroke(e,t)),[e,t]);return jsxRuntime.jsx("path",{d:a,stroke:o,strokeWidth:r})});wd.displayName="Stroke";var Rd=to__default.default.memo(({points:e,options:t,strokeColor:o,strokeWidth:r})=>{let a=to.useRef([]),i=to.useMemo(()=>{let n=[],l=Math.ceil(e.length/Vr);for(let s=0;s<l;s++)if(s===l-1){let p=e.slice(s*Vr-(s>0?1:0),s*Vr+Vr),d=utils.getSvgPathFromStroke(perfectFreehand.getStroke(p,t));n.push(d),a.current[s]=d;}else n.push(a.current[s]);return n},[e,t]);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:i.map((n,l)=>jsxRuntime.jsx("path",{d:n,stroke:o,strokeWidth:r},l))})});Rd.displayName="SplitStroke";var Ni=e=>e.map(t=>t.map(([o,r])=>({x:o,y:r,pressure:0}))),Vr=60*3;function Id(e){if(typeof e.getCoalescedEvents=="function"){let t=e.getCoalescedEvents();return [e,...t.flatMap(o=>Id(o))]}return [e]}var Td="_1vac7ws0",Nd=_({defaultClassName:"_1vac7ws1",variantClassNames:{isDragging:{true:"_1vac7ws2"}},defaultVariants:{},compoundVariants:[]});function Ld(e,t){let[o,r]=to.useState([]),a=()=>e?.flatMap(i=>[...t.querySelectorAll(i)]).map(i=>({current:i}));return granularHooks.useGranularEffect(()=>{r(a());},[],[a]),granularHooks.useGranularEffect(()=>{let i=a();r(i);},[e],[a]),o}function Md(e){let{scrollable:t,ownerDocument:o,onScroll:r}=e;to.useEffect(()=>{let a=utils.getHTMLElement(t,o);if(a)return (a.style.position==="static"||!a.style.position)&&console.warn("Scrollable ancestor passed to `Transform` component should not be statically positioned."),a.addEventListener("scroll",r),()=>{a.removeEventListener("scroll",r);}},[t,r,o]);}var dh=reactMoveable.makeMoveable([reactMoveable.Draggable,reactMoveable.Resizable,reactMoveable.Rotatable,reactMoveable.Snappable]),Bd=to__default.default.forwardRef(({className:e,children:t,isRotatable:o,isResizable:r,isDraggable:a,style:i,onTransform:n,onTransformStart:l,onTransformEnd:s,onDoubleClick:p,onDragStart:d,onDragEnd:u,onDrag:c,onResizeStart:m,onResizeEnd:f,onResize:y,onRotateStart:g,onRotateEnd:v,onRotate:b,onSnap:h,isSnappable:z,elementGuidelines:x,hideAnchorOnDrag:R=!0,title:C,rotationPosition:P,autoUpdate:k,bound:T,snapRotationDegrees:I,snapRotationThreshold:D,scrollableAncestor:E,renderDirections:w,stopPropagation:S,transformOrigin:$,preventDefault:re},pe)=>{let X=to.useRef(null),K=to.useRef(null),[G,V]=to.useState(document),Z=to.useRef(G.createElement("div")),[ee,Ce]=to.useState({}),[Pe,ye]=to.useState(!1),[ke,Le]=to.useState(!1),[oe,ce]=to.useState(),sa=Ld(x,G);to.useLayoutEffect(()=>{let H=Z.current;return Z.current=G.createElement("div"),()=>{H.remove();}},[G]);let{keyboardProps:la}=reactAria.useKeyboard({onKeyDown:H=>{let ae=H.shiftKey?10:1,U=H.metaKey||H.ctrlKey;U&&H.shiftKey&&(ae=45);function be(qo,vf="x"){U?K.current?.request("rotatable",{deltaRotate:qo*ae},!0):K.current?.request("draggable",vf==="x"?{deltaX:qo*ae}:{deltaY:qo*ae},!0);}switch(H.key){case"ArrowRight":{be(1);break}case"ArrowLeft":{be(-1);break}case"ArrowUp":{be(-1,"y");break}case"ArrowDown":be(1,"y");}requestAnimationFrame(()=>{K.current?.updateRect();});}});to.useEffect(()=>{let H=ge(X.current);V(H);let ae=Z.current;H.body.append(Z.current);function U(qo){Le(qo.shiftKey);}function be(){Le(!1);}return H.addEventListener("keydown",U),H.addEventListener("keyup",be),()=>{H.removeEventListener("keydown",U),H.removeEventListener("keyup",be),ae.remove();}},[]),Md({scrollable:E,onScroll:()=>{K.current?.updateRect();},ownerDocument:G});let pa=to.useCallback(H=>{Ce(ae=>({...ae,...H.style})),n?.(H);},[n]),Ht=to.useCallback(H=>{if(ye(!0),X.current?.focus(),T){let U=utils.getHTMLElement(T,G)?.getBoundingClientRect();ce({position:"client",left:U?.left??0,top:U?.top??0,right:U?.right??0,bottom:U?.bottom??0});}d?.(H);},[T,G,d]),Ot=to.useCallback(H=>{ye(!1),u?.(H);},[u]),A=t({style:{...ee.width&&{width:ee.width},...ee.height&&{height:ee.height}}});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{role:"button",...la,ref:N(X,pe),style:{display:"inline-block",...i,...ee},className:utils.classNames(Td,e),onDoubleClick:p,tabIndex:0,title:C,children:A}),reactDom.createPortal(jsxRuntime.jsx(dh,{ref:K,target:X,draggable:a,resizable:r,rotatable:o,keepRatio:ke,throttleDrag:1,snappable:z||!!T,elementGuidelines:sa,snapRenderThreshold:.9,className:Nd({isDragging:Pe&&R}),onRender:pa,onDragStart:Ht,onDragEnd:Ot,useResizeObserver:k,useMutationObserver:k,onRenderEnd:s,onDrag:c,onResizeStart:m,onResizeEnd:f,onResize:y,onRotateStart:g,onRotateEnd:v,onRotate:b,onRenderStart:l,onSnap:h,rotationPosition:P,bounds:oe,snapRotationDegrees:I,snapRotationThreshold:D,renderDirections:w,stopPropagation:S,preventDefault:re,transformOrigin:$}),Z.current)]})});Bd.displayName="Transform";var Ed={ar:{delete:"\u062D\u0630\u0641",selectImage:"\u062A\u062D\u062F\u064A\u062F \u0635\u0648\u0631\u0629"},cs:{delete:"Smazat",selectImage:"Vybrat obr\xE1zek"},cy:{delete:"Dileu",selectImage:"Dewiswch Ddelwedd"},da:{delete:"Slet",selectImage:"V\xE6lg billede"},de:{delete:"L\xF6schen",selectImage:"Bild ausw\xE4hlen"},el:{delete:"\u0394\u03B9\u03B1\u03B3\u03C1\u03B1\u03C6\u03AE",selectImage:"\u0395\u03C0\u03B9\u03BB\u03BF\u03B3\u03AE \u03B5\u03B9\u03BA\u03CC\u03BD\u03B1\u03C2"},"en-GB":{delete:"Delete",selectImage:"Select Image"},en:{delete:"Delete",selectImage:"Select Image"},es:{delete:"Eliminar",selectImage:"Seleccionar imagen"},fi:{delete:"Poista",selectImage:"Valitse kuva"},"fr-CA":{delete:"Supprimer",selectImage:"S\xE9lectionner une image"},fr:{delete:"Supprimer",selectImage:"S\xE9lectionner une image"},he:{delete:"\u05DE\u05D7\u05D9\u05E7\u05D4",selectImage:"\u05D1\u05D7\u05D9\u05E8\u05EA \u05EA\u05DE\u05D5\u05E0\u05D4"},hr:{delete:"Obri\u0161i",selectImage:"Odaberi sliku"},id:{delete:"Hapus",selectImage:"Pilih Gambar"},it:{delete:"Elimina",selectImage:"Seleziona immagine"},ja:{delete:"\u524A\u9664",selectImage:"\u30A4\u30E1\u30FC\u30B8\u3092\u9078\u629E"},ko:{delete:"\uC0AD\uC81C",selectImage:"\uC774\uBBF8\uC9C0 \uC120\uD0DD"},ms:{delete:"Padam",selectImage:"Pilih Imej"},"nb-NO":{delete:"Slett",selectImage:"Velg bilde"},nl:{delete:"Verwijder",selectImage:"Selecteer afbeelding"},pl:{delete:"Usu\u0144",selectImage:"Wybierz obraz"},"pt-PT":{delete:"Apagar",selectImage:"Selecionar imagem"},pt:{delete:"Apagar",selectImage:"Selecionar Imagem"},ru:{delete:"\u0423\u0434\u0430\u043B\u0438\u0442\u044C",selectImage:"\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0438\u0437\u043E\u0431\u0440."},sk:{delete:"Zmaza\u0165",selectImage:"Vybra\u0165 obr\xE1zok"},sl:{delete:"Izbri\u0161i",selectImage:"Izberi sliko"},sv:{delete:"Radera",selectImage:"V\xE4lj bild"},th:{delete:"\u0E25\u0E1A",selectImage:"\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E23\u0E39\u0E1B\u0E20\u0E32\u0E1E"},tr:{delete:"Sil",selectImage:"Resim Se\xE7"},uk:{delete:"\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438",selectImage:"\u041E\u0431\u0440\u0430\u0442\u0438 \u0437\u043E\u0431\u0440\u0430\u0436\u0435\u043D\u043D\u044F"},"zh-Hans":{delete:"\u5220\u9664",selectImage:"\u9009\u62E9\u56FE\u50CF"},"zh-Hant":{delete:"\u522A\u9664",selectImage:"\u9078\u53D6\u5716\u50CF"}};var Od=to__default.default.forwardRef(({className:e,style:t,isInline:o=!0,accept:r="image/*",defaultImageSrc:a,imageSrc:i,imageAlt:n,pickerButtonLabel:l,isDisabled:s,onDrop:p,onPaste:d,includeCheckeredBackground:u=!0,"data-block-id":c,pickerButtonStyle:m,pickerButtonClassName:f,footerClassName:y,footerStyle:g,clearLabel:v,placeholder:b,labelStyle:h,labelClassName:z,...x},R)=>{let C=to__default.default.useRef(null),P=to__default.default.useRef(null),{formatMessage:k}=B(Ed),[T,I]=utils$1.useControlledState(i,a||null,oe=>{utils.invariant(typeof oe!="string"),x.onValueChange?.(oe?[oe]:[]);}),D=to.useMemo(()=>kh(T||void 0),[T]),{fieldProps:E,labelProps:w}=reactAria.useField(x),{dropProps:S,isDropTarget:$}=reactAria.useDrop({ref:C,onDrop:async oe=>{if(s)return;let ce=await Va({items:oe.items});ce.length&&I(ce[0]),p?.(oe);},...x}),{clipboardProps:re}=reactAria.useClipboard({onPaste:async oe=>{if(s)return;let ce=await Va({items:oe});ce.length&&I(ce[0]),d?.(oe);},...x}),pe=()=>{I(null),P.current&&(P.current.value="");},X={type:"file",onChange:oe=>{let ce=[...oe.target.files];I(ce[0]),x.onChange?.(oe);},accept:r,disabled:s},{focusProps:K,isFocused:G,isFocusVisible:V}=reactAria.useFocusRing({within:!0}),{hoverProps:Z,isHovered:ee}=reactAria.useHover({isDisabled:s}),{imgProps:Ce,isLoading:Pe,isLoaded:ye}=bo({src:D,alt:n||""}),ke={label:l||k("selectImage"),onPress:()=>C.current?.click(),variant:"secondary",isDisabled:s,excludeFromTabOrder:!0,className:utils.classNames(Gt({isFocusVisible:V}),{[_d]:$&&!s},f),style:m},Le=utils.filterTruthyValues({"data-loaded":ye,"data-block-id":c,"data-hovered":ee,"data-focused":G,"data-drop-target":$,"data-disabled":s,"data-focus-visible":V});return jsxRuntime.jsxs(M,{...Le,className:utils.classNames("BaselineUI-ImageDropZone",e),display:"flex",flexDirection:"column",alignItems:"center",style:t,ref:R,children:[jsxRuntime.jsxs("label",{...reactAria.mergeProps(S,Z,K,w),className:utils.classNames(Fr({isInline:o,isHovered:ee,isDisabled:s,hasLoadedImage:!!D&&ye,showFocusRing:$||!!D&&V}),z),style:h,ref:C,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(E,re,X),ref:P})}),!D&&jsxRuntime.jsx(O,{...ke}),!!D&&(Pe?jsxRuntime.jsx(Io,{}):jsxRuntime.jsx("img",{className:Hr({isInline:o,isDisabled:s,hasLoadedImage:!!D&&ye&&u}),...Ce}))]}),b||v?jsxRuntime.jsx("div",{style:g,className:utils.classNames(Or({isInline:o,isDisabled:s}),y),children:(D||!b)&&v?jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:v,isDisabled:s,onPress:pe}):jsxRuntime.jsx(O,{size:"sm",variant:"ghost",label:b,isDisabled:!0})}):null]})});Od.displayName="ImageDropZone";function kh(e){return e instanceof File?URL.createObjectURL(e):e}var Vd="_1vm2oh49 _1yep5z6ho _1yep5z6hp _1yep5z6hq _1yep5z6fv",Di="_1vm2oh48 _1yep5z6kw _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6jc _1yep5z6jd _1yep5z6je",Ad=_({defaultClassName:"_1vm2oh40 mnnh5s1 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6l1 _1yep5z6kz _1yep5z6hk _1yep5z6l2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6ki _1yep5z6kx _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{accent:{theme:"_1vm2oh41",positive:"_1vm2oh42"},isInline:{true:"mnnh5s2 _1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z6121 _1yep5z616i _1yep5z616k",false:"_1yep5z611g"},isFocusVisible:{true:"_1yep5z6126 _1yep5z616c _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"mnnh5s8 z9nup83 _1yep5z6yl"},isHovered:{true:"_1vm2oh47"}},defaultVariants:{},compoundVariants:[[{accent:"positive",isInline:!0},"_1yep5z61mp"],[{accent:"theme",isInline:!0},"_1yep5z61me"],[{accent:"positive",isInline:!1},"_1yep5z61mr"],[{accent:"theme",isInline:!1},"_1yep5z61mg"],[{isFocusVisible:!0,isInline:!0},"_1yep5z61ny _1yep5z61rl _1yep5z61rn _1yep5z61ro"],[{isHovered:!0,isInline:!0},"_1yep5z61ro _1yep5z61ny _1yep5z61rl _1yep5z61rn"],[{isHovered:!0,isInline:!1,accent:"positive"},"_1yep5z61mq"],[{isHovered:!0,isInline:!1,accent:"theme"},"_1yep5z61mi"],[{isHovered:!0,isInline:!0,accent:"theme"},"_1yep5z61mf"]]});var Ud=to__default.default.forwardRef(({className:e,style:t,isDisabled:o,isInline:r=!0,imageAlt:a,imageSrc:i,svgSrc:n,textValue:l,textStyle:s,onPress:p,onDelete:d,deleteAriaLabel:u,addAriaLabel:c,accent:m="positive","data-block-id":f,...y},g)=>{let{focusProps:v,isFocused:b,isFocusVisible:h}=reactAria.useFocusRing({within:!0}),{isHovered:z,hoverProps:x}=reactAria.useHover({isDisabled:o}),{pressProps:R}=reactAria.usePress({isDisabled:o,onPress:p});utils.invariant(i||n||l,"Preview must have content. You must provide either an `imageSrc`, `svgSrc`, or `textValue` prop.");let C=utils.filterTruthyValues({"data-hovered":z,"data-focus-visible":h,"data-focused":b,"data-disabled":o});return jsxRuntime.jsxs("div",{...y,className:utils.classNames(Ad({isInline:r,isFocusVisible:h,isDisabled:o,isHovered:z,accent:m}),"BaselineUI-Preview",e),"data-block-id":f,"aria-label":y["aria-label"]||a||l,style:t,ref:g,children:[typeof n=="string"?jsxRuntime.jsx("button",{disabled:o,...reactAria.mergeProps(x,v,R,C),className:Di,"aria-label":c,dangerouslySetInnerHTML:{__html:n}}):jsxRuntime.jsxs("button",{...reactAria.mergeProps(x,v,R,C),disabled:o,style:s,"aria-label":c,className:Di,children:[i?jsxRuntime.jsx("img",{src:i,alt:a,className:Hr({isInline:r,isDisabled:o})}):null,!!n&&typeof n=="object"&&n,l]}),d?jsxRuntime.jsx(L,{isDisabled:o,className:Vd,"aria-label":u,size:"xs",icon:_16.TrashIcon,onPress:d}):null]})});Ud.displayName="Preview";var qd="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69c _1yep5z69d _1yep5z69e",Kd=_({defaultClassName:"cw3m0n8 _1yep5z6ew _1yep5z6dv",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),Gd="cw3m0n7",Wd=_({defaultClassName:"cw3m0n0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6i9 _1yep5z6ia _1yep5z6ib",variantClassNames:{labelPosition:{end:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6ut _1yep5z6uu _1yep5z6uv",start:"_1yep5z613q _1yep5z613r _1yep5z613s _1yep5z6152 _1yep5z6153 _1yep5z6154"}},defaultVariants:{},compoundVariants:[]}),Xd="_1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6ks",Yd=_({defaultClassName:"cw3m0n3 _16vugd05",variantClassNames:{isFocusVisible:{true:"_16vugd08"},isSelected:{true:"_16vugd07"},isDisabled:{true:"_16vugd0a"}},defaultVariants:{},compoundVariants:[]});var jh=({label:e,description:t},{isSelected:o,isFocusVisible:r,isDisabled:a,optionLabelPosition:i})=>jsxRuntime.jsxs("div",{className:Wd({labelPosition:i}),children:[jsxRuntime.jsx("div",{className:Yd({isSelected:o,isFocusVisible:r,isDisabled:a}),children:o?jsxRuntime.jsx("div",{className:Gd}):null}),e?jsxRuntime.jsxs("div",{className:qd,children:[jsxRuntime.jsx("span",{className:ur({isDisabled:a}),children:e}),t?jsxRuntime.jsx("span",{className:Kd({isDisabled:a}),children:t}):null]}):null]}),Zd=({state:e,renderOption:t=jh,item:o,optionLabelPosition:r="end",optionStyle:a,optionClassName:i,isReadOnly:n,...l})=>{let s=!!l.isDisabled||!!l.disabledValues?.includes(o.id),p=to__default.default.useRef(null),{inputProps:d,isPressed:u,isSelected:c}=reactAria.useRadio({...l,isDisabled:s,children:o.label,value:o.id},e,p),{focusProps:m,isFocusVisible:f,isFocused:y}=reactAria.useFocusRing(),{isHovered:g}=reactAria.useHover({isDisabled:s}),v=utils.filterTruthyValues({"data-selected":c,"data-focused":y,"data-focus-visible":f,"data-hovered":g,"data-disabled":s,"data-pressed":u,"data-read-only":n});return jsxRuntime.jsxs("label",{...v,style:a,className:utils.classNames("BaselineUI-Radio-Item",i),children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("input",{...reactAria.mergeProps(d,m),ref:p})}),t(o,{isFocusVisible:f,isSelected:c,isFocused:y,isHovered:g,isDisabled:s,optionLabelPosition:r,isReadOnly:n})]})};var Ur=to__default.default.forwardRef(({className:e,style:t,optionsContainerClassName:o,optionsContainerStyle:r,items:a,labelPosition:i="top",renderOption:n,"aria-label":l,"aria-labelledby":s,"aria-describedby":p,"aria-details":d,"data-block-id":u,...c},m)=>{let f=reactStately.useRadioGroupState(c),{radioGroupProps:y,labelProps:g,descriptionProps:v,errorMessageProps:b}=reactAria.useRadioGroup({...c,"aria-label":l,"aria-labelledby":s,"aria-describedby":p,"aria-details":d},f),h=_e({...c,descriptionProps:v,errorMessageProps:b,labelPosition:i}),z=utils.filterTruthyValues({"data-orientation":c.orientation,"data-block-id":u,"data-disabled":c.isDisabled,"data-readonly":c.isReadOnly});return jsxRuntime.jsxs("div",{...reactAria.mergeProps(y,z),className:utils.classNames(Be({labelPosition:i}),"BaselineUI-RadioGroup",e),style:t,ref:m,children:[c.label||h?jsxRuntime.jsxs("div",{className:De({labelPosition:i,hasMessage:!!h}),children:[jsxRuntime.jsx("span",{...g,className:utils.classNames(Me,"BaselineUI-RadioGroup-Label"),children:c.label}),i==="start"&&h]}):null,jsxRuntime.jsxs("div",{className:utils.classNames({[po]:c.isDisabled}),children:[jsxRuntime.jsx("div",{className:utils.classNames(Xd,o),style:r,children:a.map(x=>jsxRuntime.jsx(Zd,{state:f,renderOption:n,item:x,...c,value:x.id},x.id))}),i==="top"&&h]})]})});Ur.displayName="RadioGroup";var Qd=({id:e,defaultMessage:t,elementType:o=to.Fragment})=>{utils.invariant(e||t,"`id` or `defaultMessage` is required.");let r=B();return jsxRuntime.jsx(o,{children:r.formatMessage(e)||t})};Qd.displayName="MessageFormat";var Jd=to__default.default.forwardRef(({className:e,style:t,children:o,role:r="group",isDisabled:a,...i},n)=>{let{hoverProps:l,isHovered:s}=reactAria.useHover({isDisabled:a});return jsxRuntime.jsx("div",{...l,role:r,"data-hovered":s,"data-disabled":a,className:e,style:t,...i,ref:n,children:o})});Jd.displayName="Group";var qr="_46ioju0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e",Kr="_1yep5z61ov _1yep5z61ow _1yep5z61ox _1yep5z61g1 _1yep5z61g2 _1yep5z61g3";var om=to__default.default.forwardRef(({items:e,optionsContainerClassName:t,...o},r)=>{let a=to.useMemo(()=>e.map(i=>({id:i.color,label:i.label})),[e]);return to.useEffect(()=>{console.warn("`ColorPresetInlineInput` is deprecated. Please use `ColorSwatchPicker` instead.");},[]),jsxRuntime.jsx(Ur,{items:a,optionsContainerClassName:utils.classNames(Kr,t),orientation:"horizontal",renderOption:({label:i,id:n},{isSelected:l,isFocusVisible:s})=>jsxRuntime.jsx("div",{className:qr,children:jsxRuntime.jsx(he,{isFocusVisible:s,color:n,isSelected:l,"aria-label":i,isInteractive:!0})}),...o,className:utils.classNames(o.className,"BaselineUI-ColorPresetInput"),ref:r})});om.displayName="ColorPresetInput";var Vi="UNSUPPORTED_IN_MENU";function am(e){return to.useMemo(()=>to__default.default.Children.toArray(e).map(t=>{let o=t,r=lodash.uniqueId("item"),a=zt(o,Xe),i=rm(o),n,l;if(a){let v=zt(a,Ye);utils.invariant(v),n=rm(v),l=zt(a,Ue).props.children;}else i?n=i:n=o;let{onPress:s,label:p,"aria-label":d,iconStart:u,isDisabled:c,icon:m}=n.props,f=p||d||Vi;utils.invariant(typeof f=="string","ActionGroup children must have a string label");let y=`${r}-${f}`;return to.createElement(reactStately.Item,{...{key:y,onPress:s,textValue:f,"aria-label":d,icon:u||m,dialogContent:l,isDisabled:c},key:y},o)}),[e])}function zt(e,t){return t?lodash.flatMapDeep(to__default.default.Children.toArray(e),r=>to__default.default.isValidElement(r)&&r.props.children?[r,...to__default.default.Children.toArray(r.props.children)]:[r]).find(r=>to__default.default.isValidElement(r)&&r.type===t):void 0}function rm(e){return zt(e,O)||zt(e,L)}var im="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6hl _1yep5z6hm _1yep5z6hn _1yep5z6kv _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6kn",nm={horizontal:"xvr3wn0",vertical:"xvr3wn1"};var ji=to__default.default.forwardRef(({className:e,style:t,children:o,collapsibleMenuProps:r,"data-block-id":a,renderSpacer:i,...n},l)=>{let{formatMessage:s}=B(),[p,d]=to.useState(),u=am(o),c=reactStately.useListState({...n,children:u}),m=Re(l),f=to.useRef(null),[{visibleItems:y,isMeasuring:g},v]=da({visibleItems:c.collection.size,isMeasuring:!1}),b=to.useCallback(()=>{let k=T=>{if(f.current&&m.current){let I=[...f.current.children],D=m.current.getBoundingClientRect().width,E=T<c.collection.size,w=0,S=0;if(E){let $=I.pop();$&&(w+=cm($,!1,!0));}for(let[$,re]of I.entries())if(w+=cm(re,$===0,$===I.length-1),Math.round(w)<=Math.round(D))S++;else break;return S}return T};v(function*(){yield {visibleItems:c.collection.size,isMeasuring:!0};let T=k(c.collection.size),I=T<c.collection.size&&T>0;yield {visibleItems:T,isMeasuring:I},I&&(yield {visibleItems:k(T),isMeasuring:!1});});},[v,m,c.collection.size]),h=to.useMemo(()=>({get current(){return m.current?.parentElement}}),[m]);ba({ref:h,onResize:b}),we(b,[c.collection,b]);let{toolbarProps:z}=toolbar.useToolbar(n,m),x=[...c.collection],R=x.slice(0,y),C=x.slice(y).filter(k=>k.textValue!==Vi),P=C.length>0;return to.useEffect(()=>{d(void 0);},[C.length]),to.useEffect(()=>{n.orientation==="vertical"&&console.warn("Toolbar: Vertical orientation is not supported when `isCollapsible` is true.");},[n.orientation]),jsxRuntime.jsxs(reactAria.FocusScope,{children:[jsxRuntime.jsx("div",{...z,className:e,"data-block-id":a,"data-collapse":!0,style:{...t,flexBasis:g?"100%":void 0},ref:m,children:jsxRuntime.jsxs("div",{ref:f,className:im,children:[R.map(k=>k.rendered),P?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[!g&&i?.(),jsxRuntime.jsx(lr,{placement:"bottom end",renderTrigger:({buttonProps:k,ref:T})=>jsxRuntime.jsx(L,{...k,size:"md",icon:_24.MoreIcon,"aria-label":s(bx.more),variant:"toolbar",ref:T}),...r,disabledKeys:C.filter(k=>k.props?.isDisabled).map(k=>k.key),items:C.map(k=>{let T=k.textValue||k["aria-label"];return utils.invariant(T,"ActionItem must have a label"),{id:k.key,label:T,icon:k.props.icon}}),onAction:k=>{let T=c.collection.getItem(k);utils.invariant(T,"Item not found");let{onPress:I,dialogContent:D}=T.props;I?.(),d(D);}})]}):null]})}),jsxRuntime.jsx(ze,{isOpen:!!p,onOpenChange:k=>{k||d(void 0);},children:jsxRuntime.jsx(Te,{enableDrawer:"auto",style:{zIndex:1e5},children:p?to__default.default.cloneElement(p,{inheritDrawer:!0}):null})})]})});ji.displayName="CollapsibleToolbar";function cm(e,t,o){let a=Q(e).getComputedStyle(e);return e.getBoundingClientRect().width+(t?0:dm(a.marginLeft))+(o?0:dm(a.marginRight))}function dm(e){let t=Number.parseInt(e,10);return Number.isNaN(t)?0:t}var bx=j({more:{id:"more",defaultMessage:"More"}});var $i=to__default.default.forwardRef(({className:e,style:t,"data-block-id":o,"aria-controls":r,...a},i)=>{let n=to__default.default.useRef(null),{toolbarProps:l}=toolbar.useToolbar(a,n);return jsxRuntime.jsx("div",{...l,"aria-controls":r,className:utils.classNames(nm[a.orientation||"horizontal"],"BaselineUI-Toolbar",e),style:t,"data-block-id":o,ref:N(i,n),children:a.children})});$i.displayName="WrappedToolbar";var Gr=to__default.default.forwardRef((e,t)=>{let o=e.isCollapsible?ji:$i;return jsxRuntime.jsx(o,{...e,ref:t})});Gr.displayName="Toolbar";var um=_({defaultClassName:"_1j5skr71",variantClassNames:{size:{xxs:"_1j5skr72",xs:"_1j5skr73",sm:"_1j5skr74",md:"_1j5skr75",lg:"_1j5skr76"}},defaultVariants:{},compoundVariants:[]}),fm=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7g"},isFocusVisible:{true:"_1j5skr7h"},isDisabled:{true:"z9nup83 _1yep5z610d"},isSelected:{true:"_1j5skr7j"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61rl _1yep5z61o5 _1yep5z61lo"],[{isSelected:!1,isHovered:!0,isDisabled:!1},"_1yep5z6fu"],[{isSelected:!1,isFocusVisible:!0,isDisabled:!1},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0,isDisabled:!1},"_1j5skr7k _1yep5z61rm _1yep5z61rl _1yep5z61nz _1yep5z61lp"],[{isSelected:!0,isFocusVisible:!1,isDisabled:!1},"_1yep5z61rl _1yep5z61rn _1yep5z61ny _1yep5z61ro"]]}),ym=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7m"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1yep5z610c"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61ln"]]}),bm=_({defaultClassName:"_1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr7r"},isFocusVisible:{true:"_1yep5z616d _1yep5z616c _1yep5z612n _1yep5z616a"},isSelected:{true:"_1j5skr7t"},isDisabled:{true:"z9nup83 _1yep5z610d"}},defaultVariants:{},compoundVariants:[[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!0,isDisabled:!1},"_1yep5z61mg _1yep5z61lq"],[{isSelected:!0,isDisabled:!0},"_1yep5z61mg _1yep5z61lo"]]}),gm=_({defaultClassName:"_1j5skr77 _1j5skr70 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6kx _1yep5z6ky _1yep5z6ks _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6jl _1yep5z6jm _1yep5z6jn _1yep5z6f0",variantClassNames:{isHovered:{true:"_1j5skr78"},isFocusVisible:{true:"_1j5skr79"},isSelected:{true:"_1j5skr7a"},isDisabled:{true:"_1j5skr7b z9nup83 _1yep5z610e"}},defaultVariants:{},compoundVariants:[[{isSelected:!0,isDisabled:!1},"_1j5skr7c _1yep5z61lp"],[{isSelected:!1,isDisabled:!0},"_1j5skr7d _1yep5z61lo"],[{isSelected:!1,isHovered:!0},"_1yep5z61mg"],[{isSelected:!1,isFocusVisible:!0},"_1yep5z61ro _1yep5z61rn _1yep5z61ny _1yep5z61rl"],[{isSelected:!0,isFocusVisible:!0},"_1j5skr7e _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]});var Sx={xxs:8,xs:12,sm:16,md:20,lg:24},ve=to__default.default.forwardRef(({className:e,style:t,icon:o,size:r="md",variant:a="primary","data-block-id":i,...n},l)=>{let s=reactStately.useToggleState(n),{buttonProps:p,isPressed:d,ref:u}=Kt(n,s),{hoverProps:c,isHovered:m}=reactAria.useHover({isDisabled:n.isDisabled}),{isFocusVisible:f,isFocused:y,focusProps:g}=reactAria.useFocusRing(),v=to.useMemo(()=>typeof o=="function"?o:s.isSelected?o.selected:o.unselected,[o,s.isSelected]),b={isSelected:s.isSelected,isHovered:m,isFocusVisible:f,isDisabled:!!n.isDisabled},h=utils.filterTruthyValues({"data-hovered":m,"data-selected":s.isSelected,"data-focus-visible":f,"data-disabled":n.isDisabled,"data-block-id":i,"data-focused":y,"data-pressed":d});return jsxRuntime.jsx("button",{...reactAria.mergeProps(p,c,g,h),className:utils.classNames(a==="toolbar"&&gm(b),a==="primary"&&fm(b),a==="secondary"&&ym(b),a==="tertiary"&&bm(b),um({size:r}),"BaselineUI-ToggleIconButton",e),style:t,ref:N(u,l),children:jsxRuntime.jsx(v,{size:Sx[r]})})});ve.displayName="ToggleIconButton";var _m="f6jv6bm",zm="_1yep5z64u _1yep5z64v _1yep5z64w _1yep5z676 _1yep5z677 _1yep5z678 _1yep5z6j0 _1yep5z6j1 _1yep5z6j2",Fo="_1yep5z689 _1yep5z68a _1yep5z68b _1yep5z65x _1yep5z65y _1yep5z65z",hm=_({defaultClassName:"f6jv6b0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6fs",variantClassNames:{isInline:{true:"f6jv6b1"},isMinimal:{true:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6uw _1yep5z6ux _1yep5z6uy _1yep5z6142 _1yep5z6143 _1yep5z6144",false:"_1yep5z613n _1yep5z613o _1yep5z613p"}},defaultVariants:{},compoundVariants:[[{isInline:!0,isMinimal:!1},"_1yep5z61h7 _1yep5z61h8 _1yep5z61h9 _1yep5z61hv _1yep5z61hw _1yep5z61hx _1yep5z61ij _1yep5z61ik _1yep5z61il _1yep5z61j7 _1yep5z61j8 _1yep5z61j9 _1yep5z61rv _1yep5z61rt _1yep5z61nc"]]}),Wr=_({defaultClassName:"f6jv6b4 _1yep5z69 _1yep5z6a _1yep5z6b _1yep5z62l _1yep5z62m _1yep5z62n _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z6e3 _1yep5z6eu _1yep5z6ky",variantClassNames:{isDisabled:{true:"f6jv6b5 _1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),xm="f6jv6bj _1yep5z6vz _1yep5z6w0 _1yep5z6w1 _1yep5z6wn _1yep5z6wo _1yep5z6wp _1yep5z6xb _1yep5z6xc _1yep5z6xd _1yep5z6xz _1yep5z6y0 _1yep5z6y1",Cm="f6jv6bk";var Pm="f6jv6bn _1yep5z63l _1yep5z63m _1yep5z63n _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6l6 _1yep5z6l1 _1yep5z6kz _1yep5z6hc _1yep5z6eu",km=_({defaultClassName:"f6jv6bf _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z61f _1yep5z61g _1yep5z61h _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6ky _1yep5z6ki _1yep5z6kl _1yep5z6kx",variantClassNames:{isHovered:{true:"_1yep5z6115"},isDisabled:{true:"_1yep5z6yl"}},defaultVariants:{},compoundVariants:[]}),wm="f6jv6bi _1mdhlqv6 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6d7 _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6fs _1yep5z6l0 _1yep5z6kz _1yep5z6hf _1yep5z6l3",Rm="_1yep5z6j6 _1yep5z6j7 _1yep5z6j8",Im="f6jv6be f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu _1yep5z6e3 _1yep5z6kv",Tm=_({defaultClassName:"f6jv6bb _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z69l _1yep5z69m _1yep5z69n _1yep5z6jc _1yep5z6jd _1yep5z6je",variantClassNames:{isInline:{true:"_1yep5z6oz _1yep5z6p0 _1yep5z6p1 _1yep5z616k _1yep5z616i _1yep5z6121",false:"_1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6we _1yep5z6wf _1yep5z6wg _1yep5z6x2 _1yep5z6x3 _1yep5z6x4 _1yep5z6xq _1yep5z6xr _1yep5z6xs _1yep5z6ye _1yep5z6yf _1yep5z6yg"}},defaultVariants:{},compoundVariants:[]}),Nm="f6jv6bl",Sm="f6jv6ba _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6hx _1yep5z6hy _1yep5z6hz _1yep5z6eu",Xr=_({defaultClassName:"f6jv6b6",variantClassNames:{isInline:{true:"f6jv6b7",false:"f6jv6b8"}},defaultVariants:{},compoundVariants:[]}),Yr="f6jv6b9 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it",xt="f6jv6bo";var Mm=[["Toolbar Focus","Alt+F10"],["Bold","Ctrl+B"],["Italic","Ctrl+I"],["Underline","Ctrl+U"],["Select All","Ctrl+A"],["Cut","Ctrl+X"],["Copy","Ctrl+C"],["Paste","Ctrl+V"],["Undo","Ctrl+Z"],["Redo","Ctrl+Shift+Z"],["Submit","Ctrl+Enter"],["Open Help Dialog","Ctrl+Shift+H"]],{dialog:{row:Ct}}=tokens.layoutSprinkleValues,Dm=({isOpen:e,onClose:t})=>{let{formatMessage:o}=B(),r=reactAria.useId();return jsxRuntime.jsx(ze,{isOpen:e,onOpenChange:a=>{a||t();},children:jsxRuntime.jsx(Te,{enableDrawer:"auto",style:{zIndex:999999},children:jsxRuntime.jsxs(me,{"aria-labelledby":r,className:xm,drawerBackground:"subtle",children:[jsxRuntime.jsxs(M,{paddingLeft:Ct.padding.horizontal.lg,paddingRight:Ct.padding.horizontal.sm,display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",backgroundColor:"background.primary.subtle",className:Cm,children:[jsxRuntime.jsx(W,{id:r,elementType:"h3",type:"title",size:"md",children:o(Pt.help)}),jsxRuntime.jsx(L,{icon:_20.XIcon,size:"md",variant:"secondary","aria-label":o(Pt.close),onPress:t})]}),jsxRuntime.jsx(F,{className:Nm}),jsxRuntime.jsxs(M,{paddingX:Ct.padding.horizontal.lg,role:"table","aria-labelledby":r,backgroundColor:"background.primary.subtle",children:[jsxRuntime.jsx("div",{role:"rowgroup",children:jsxRuntime.jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Ct.padding.vertical.md,color:"text.primary",children:[jsxRuntime.jsx("h6",{className:tokens.sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",children:o(Pt.action)}),jsxRuntime.jsx("h6",{className:tokens.sprinkles({typography:"heading.h6.semibold"}),role:"columnheader",style:{textTransform:"capitalize"},children:o(Pt.shortcut)})]})}),jsxRuntime.jsx("div",{role:"rowgroup",children:Mm.map(([a,i],n)=>jsxRuntime.jsxs(to.Fragment,{children:[jsxRuntime.jsxs(M,{role:"row",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingY:Ct.padding.vertical.xs,style:{minHeight:40},children:[jsxRuntime.jsx(W,{type:"subtitle",size:"sm",role:"cell",children:o(Pt[lodash.camelCase(a)])}),jsxRuntime.jsx(W,{elementType:"kbd",type:"subtitle",size:"sm",role:"cell",children:utils.getOsSpecificKeyboardShortcutLabel(i,!0)})]}),n!==Mm.length-1&&jsxRuntime.jsx(F,{})]},a))})]})]})})})},Pt=j({toolbarFocus:{id:"toolbarFocus",defaultMessage:"Toolbar Focus"},help:{id:"help",defaultMessage:"Help"},close:{id:"close",defaultMessage:"Close"},action:{id:"action",defaultMessage:"Action"},shortcut:{id:"shortcut",defaultMessage:"Shortcut"},bold:{id:"bold",defaultMessage:"Bold"},italic:{id:"italic",defaultMessage:"Italic"},underline:{id:"underline",defaultMessage:"Underline"},selectAll:{id:"selectAll",defaultMessage:"Select All"},cut:{id:"cut",defaultMessage:"Cut"},copy:{id:"copy",defaultMessage:"Copy"},paste:{id:"paste",defaultMessage:"Paste"},undo:{id:"undo",defaultMessage:"Undo"},redo:{id:"redo",defaultMessage:"Redo"},openHelpDialog:{id:"openHelpDialog",defaultMessage:"Open Help Dialog"},submit:{id:"submit",defaultMessage:"Submit"}});var Zr=to__default.default.forwardRef(({value:e,defaultValue:t,onChange:o,placeholder:r,spellCheck:a,textBoxRef:i,isInline:n,isMinimal:l,isDisabled:s,editableContentAriaLabel:p,editorHandle:d,autoFocus:u,saveOnEnter:c,onSave:m},f)=>{let y=to__default.default.useRef(null),[g,v]=utils$1.useControlledState(e,t||"",o),b=to.useCallback(I=>{v(I.currentTarget.value||"");},[v]),h=to.useCallback(I=>{(c&&I.key==="Enter"&&!I.shiftKey||(I.ctrlKey||I.metaKey)&&I.key==="Enter")&&(I.preventDefault(),m());},[c,m]);to.useImperativeHandle(f,()=>({clear:()=>{v("");}}));let z=to.useCallback(I=>{I.currentTarget.style.height="16px",I.currentTarget.style.height=I.currentTarget.scrollHeight+"px";},[]);granularHooks.useGranularLayoutEffect(()=>{let I=y.current;I&&(I.style.height="16px",I.style.height=I.scrollHeight+"px");},[l],[g]),to.useImperativeHandle(d,()=>({setCaretPosition:I=>{y.current&&(y.current.focus(),y.current.setSelectionRange(I,I));}}));let{focusProps:x,isFocused:R,isFocusVisible:C}=reactAria.useFocusRing(),{hoverProps:P,isHovered:k}=reactAria.useHover({}),T=utils.filterTruthyValues({"data-focus-visible":C,"data-hovered":k,"data-focused":R});return jsxRuntime.jsx("textarea",{...reactAria.mergeProps(x,P,T),ref:N(y,i),className:utils.classNames(l?Im:[Wr(),Xr({isInline:n}),Sm]),autoFocus:u,onChange:b,disabled:s,onInput:z,value:g,placeholder:r,spellCheck:a,"aria-label":p,onKeyDown:h})});Zr.displayName="PlainEditor";var Rt="mention",Qr="mention_input",Km=to__default.default.forwardRef(({onCancel:e,editor:t,element:o,onSelectionChange:r},a)=>{let{containerRef:i,items:n,maxMentionableUsersSuggestions:l}=to.useContext(ea),s=slateReact.useSelected(),[p,d]=to.useState(""),{contains:u}=reactAria.useFilter({sensitivity:"base"}),{formatMessage:c}=B(),m=to.useMemo(()=>{let w=n.filter(S=>p===""||u(S.displayName,p)).map(S=>({id:S.id,label:S.displayName,data:S}));return l?lodash.take(w,l):w},[n,l,p,u]),f=to.useCallback(w=>jsxRuntime.jsx(reactStately.Item,{children:w.label},w.id),[]),y=to.useCallback((w=!1)=>{let S=plateCommon.findNodePath(t,o);S&&(plateCommon.removeNodes(t,{at:S}),w&&plateCommon.focusEditor(t));},[t,o]),g=reactStately.useComboBoxState({items:m,children:f,menuTrigger:"focus",onSelectionChange:w=>{y(!0),r?.(w);}}),v=to__default.default.useRef(null),b=to__default.default.useRef(null),h=to__default.default.useRef(null),z=to__default.default.useRef(null),x=plateCombobox.useHTMLInputCursorState(b);reactAria.useInteractOutside({ref:z,onInteractOutside:()=>{g.close();}});let{inputProps:R,listBoxProps:C}=reactAria.useComboBox({defaultItems:m,inputRef:b,buttonRef:v,listBoxRef:h,popoverRef:z,menuTrigger:"focus","aria-label":c(mC.mention)},g);to.useEffect(()=>{b.current?.focus();},[]);let P=to.useCallback((w="manual",S=!1)=>{y(S),e?.(w,g.inputValue);},[e,y,g.inputValue]),k=to.useRef(s);to.useEffect(()=>{k.current&&!s&&P("deselect"),k.current=s;},[s,P]);let T=x?.atStart??!1,I=x?.atEnd??!1,D=to.useCallback(w=>{w.key==="Backspace"&&T?P("backspace",!0):w.key==="Escape"?P("escape",!0):w.key==="ArrowLeft"&&T?P("arrowLeft",!0):w.key==="ArrowRight"&&I&&P("arrowRight",!0);let S=plateCommon.Hotkeys.isUndo(w)&&t.history.undos.length>0,$=plateCommon.Hotkeys.isRedo(w)&&t.history.redos.length>0;(S||$)&&(w.preventDefault(),t[S?"undo":"redo"](),plateCommon.focusEditor(t));},[T,I,P,t]),E=to.useMemo(()=>{if(!CSS.supports("field-sizing","content")){let w=Q(b.current),S=b.current?w?.getComputedStyle(b.current).font:void 0;return {width:S?utils.getTextDimensions({text:g.inputValue,font:S}).width+10:"4ch"}}},[g.inputValue]);return jsxRuntime.jsxs(We.Provider,{value:g,children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(R,{onKeyDown:D,onBlur:()=>{P("blur",!0);},onChange:w=>{d(w.target.value);}}),style:E,className:Pm,ref:N(a,b)}),g.isOpen?jsxRuntime.jsx(le,{triggerRef:i,className:wm,isNonModal:!0,ref:z,state:g,children:jsxRuntime.jsx(te,{...C,items:void 0,autoFocus:"first",ref:h,className:tokens.sprinkles({width:"full"}),renderOption:Wm})}):null]})});Km.displayName="MentionInputContentElement";var Wi=cn$1.withRef(({className:e,...t},o)=>{let{children:r,editor:a,element:i}=t,{items:n}=to.useContext(ea),l=to.useRef(null),[s,p]=to.useState(null);to.useEffect(()=>{let c=plateCommon.findNodePath(a,i);if(!c)return;let m=plateCommon.getPointBefore(a,c);if(!m)return;let f=plateCommon.createPointRef(a,m);return p(f),()=>{f.unref();}},[a,i]);let d=to.useCallback(()=>{let c=l.current?.getRootNode()instanceof ShadowRoot;plateCommon.moveSelection(a,{unit:"offset"}),plateCommon.moveSelection(a,{unit:"character",distance:1}),Ko()&&c&&plateCommon.focusEditor(a);},[a]),u=to.useCallback(c=>{if(!c)return;let m=l.current?.getRootNode()instanceof ShadowRoot,f=n.find(g=>g.id===c);utils.invariant(f,"User not found");let y={type:Rt,value:f.id,displayName:f.displayName,children:[{text:""}]};plateCommon.insertNodes(a,[y,{text:" "}]),m?setTimeout(()=>{d();},0):d();},[a,n,d]);return jsxRuntime.jsxs(plateCommon.PlateElement,{as:"span","data-slate-value":i.value,contentEditable:!1,className:e,ref:o,...t,children:[jsxRuntime.jsx(Km,{onCancel:(c,m)=>{c!=="backspace"&&plateCommon.insertText(a,"@"+m,{at:s?.current??void 0}),(c==="arrowLeft"||c==="arrowRight")&&plateCommon.moveSelection(a,{distance:1,reverse:c==="arrowLeft"});},onSelectionChange:u,ref:l,element:i,editor:a}),r]})});Wi.displayName="MentionInputElement";var Xi=cn$1.withRef(({className:e,onClick:t,children:o,...r},a)=>{let i=plateCommon.useElement();return jsxRuntime.jsxs(plateCommon.PlateElement,{as:"span",className:e,contentEditable:!1,"data-user-id":i.value,onClick:plateCommon.getHandler(t,i),ref:a,...r,children:["@",i.displayName,o]})});Xi.displayName="MentionElement";var Gm=(e,{options:{trigger:t,triggerPreviousCharPattern:o,triggerQuery:r}})=>{let{insertText:a}=e,i=n=>n===t;return e.insertText=n=>{if(!e.selection||!i(n)||r&&!r(e)){a(n);return}let l=plateCommon.getEditorString(e,plateCommon.getRange(e,e.selection,plateCommon.getPointBefore(e,e.selection)));if(o?.test(l)){Jr(e);return}a(n);},e},mC=j({mention:{defaultMessage:"Mention",id:"mention"}});function Ym({className:e,children:t,...o}){return jsxRuntime.jsx(plateCommon.PlateElement,{asChild:!0,className:e,...o,children:jsxRuntime.jsx("p",{children:t})})}function IC(e){return Object.entries(e).map(([t,o])=>`${lodash.kebabCase(t)}:${o}`).filter(([,t])=>!!t).join(";")}function TC(e){return "text"in e}function It(e){if(!e)return "";function t(o){if(TC(o)){let a=o.text;return o.bold&&(a=`<b>${a}</b>`),o.italic&&(a=`<i>${a}</i>`),o.underline&&(a=`<u>${a}</u>`),(o.color||o.backgroundColor)&&(a=`<span style="${IC(utils.filterTruthyValues({color:o.color||void 0,backgroundColor:o.backgroundColor||void 0}))}">${a}</span>`),a}let r=o.children?.map(It).join("");switch(o.type){case plateParagraph.ELEMENT_PARAGRAPH:return `<p>${r}</p>`;case plateLink.ELEMENT_LINK:return `<a href="${o.url}">${r}</a>`;case Rt:return `<span data-user-id="${o.value}">${o.displayName}</span>`;default:return r}}return Array.isArray(e)?e.map(o=>t(o)).join(""):t(e)}function NC(e){return e?(e=e.trim(),e.endsWith(";")&&(e=e.slice(0,-1)),Object.fromEntries(e.split(";").map(t=>t.split(":").map(o=>o.trim())).map(([t,o])=>[lodash.camelCase(t),o]))):{}}function en(e){e.startsWith("<p>")||(e=`<p>${e}</p>`);let t=new DOMParser().parseFromString(Zm__namespace.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")?`
80
+ `:"<p>";return Jm(t.body)}function Jm(e,t){if(e.nodeType===Node.TEXT_NODE)return slateHyperscript.jsx("text",t,e.textContent);if(e.nodeType!==Node.ELEMENT_NODE)return null;let o={...t};switch(e.nodeName.toUpperCase()){case"B":{o.bold=!0;break}case"I":{o.italic=!0;break}case"EM":{o.italic=!0;break}case"U":{o.underline=!0;break}case"SPAN":{let a=NC(e.getAttribute("style")||"");a["text-decoration"]==="underline"&&(o.underline=!0),a.color&&(o.color=a.color),a.backgroundColor&&(o.backgroundColor=a.backgroundColor);break}}let r=[...e.childNodes].flatMap(a=>Jm(a,o));switch(r.length===0&&r.push(slateHyperscript.jsx("text",o,"")),e.nodeName.toUpperCase()){case"BR":return slateHyperscript.jsx("text",t,`
81
+ `);case"SPAN":{let a=e.dataset.userId;return a?slateHyperscript.jsx("element",{type:Rt,value:a,displayName:e.textContent},{text:""}):r}case"P":return slateHyperscript.jsx("element",{type:plateParagraph.ELEMENT_PARAGRAPH},r);case"A":return slateHyperscript.jsx("element",{type:plateLink.ELEMENT_LINK,url:e.getAttribute("href")},r);default:return r}}function eu(e){let t=plateCommon.findNode(e,{match:{type:plateCommon.getPluginType(e,plateLink.ELEMENT_LINK)}}),[o]=t||[{url:""}];return o?.url}function Jr(e){let t={children:[{text:" "}],type:Qr};e.insertNode(t);}var SC=plateCommon.createPluginFactory({isElement:!0,isInline:!0,isMarkableVoid:!0,isVoid:!0,key:Rt,options:{trigger:"@",triggerPreviousCharPattern:/^$|^[\s"']$/},plugins:[{isElement:!0,isInline:!0,isVoid:!0,key:Qr}],withOverrides:Gm}),ou=plateCommon.createPlugins([plateParagraph.createParagraphPlugin({component:Ym}),plateBasicMarks.createBoldPlugin({component:cn$1.withProps(plateCommon.PlateLeaf,{as:"b"})}),plateBasicMarks.createItalicPlugin({component:cn$1.withProps(plateCommon.PlateLeaf,{as:"i"})}),plateBasicMarks.createUnderlinePlugin({component:cn$1.withProps(plateCommon.PlateLeaf,{as:"u"})}),plateFont.createFontColorPlugin(),plateFont.createFontBackgroundColorPlugin(),plateLink.createLinkPlugin({component:tu}),SC({component:Xi})],{components:{[Qr]:Wi}});var nu=({isDisabled:e})=>{let{formatMessage:t}=B(),o=plateCommon.useEditorRef();return jsxRuntime.jsx(Xe,{type:"dialog",children:({close:r})=>jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(Ye,{children:jsxRuntime.jsx(L,{icon:_20.LinkIcon,size:"sm",isDisabled:e,"aria-label":t(ro.addLink),className:Fo,preventFocusOnPress:!0})}),jsxRuntime.jsx(Ue,{className:tokens.sprinkles({boxShadow:"medium"}),placement:"top end",children:jsxRuntime.jsx(me,{size:"content",style:{minWidth:240},children:jsxRuntime.jsx(OC,{close:()=>{r(),setTimeout(()=>{plateCommon.focusEditor(o,o.selection);},0);}})})})]})})},OC=({close:e})=>{let t=plateCommon.useEditorRef(),{formatMessage:o}=B(),r=plateCommon.useEditorSelector(p=>eu(p),[]),[a,i]=to__default.default.useState(r?"show":"add"),[n,l]=to__default.default.useState(r||""),s=jsxRuntime.jsx(M,{padding:"lg",children:jsxRuntime.jsx(ko,{label:o(ro.link),value:n,autoFocus:!0,onChange:l,placeholder:"https://yourdomain.com"})});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[a==="add"&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[s,jsxRuntime.jsx(M,{display:"flex",justifyContent:"flex-end",padding:"lg",className:_m,children:jsxRuntime.jsx(O,{isDisabled:!utils.isUrl(n,!0),label:o(ro.addLink),size:"sm",onPress:()=>{plateLink.upsertLink(t,{url:n,skipValidation:!0}),e?.();},preventFocusOnPress:!0})})]}),a==="show"&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(M,{padding:"lg",children:jsxRuntime.jsx(W,{type:"subtitle",size:"sm",children:r})}),jsxRuntime.jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsxRuntime.jsx(O,{label:o(ro.editLink),size:"sm",variant:"secondary",onPress:()=>{i("edit");},style:{flex:1,justifyContent:"center"}}),jsxRuntime.jsx(O,{label:o(ro.removeLink),size:"sm",onPress:()=>{plateLink.unwrapLink(t),e?.();},preventFocusOnPress:!0,style:{flex:1,justifyContent:"center"}})]})]}),a==="edit"&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[s,jsxRuntime.jsxs(M,{display:"flex",justifyContent:"flex-end",padding:"lg",gap:"lg",borderColor:"border.subtle",borderWidth:1,borderStyle:"solid",children:[jsxRuntime.jsx(O,{label:o(ro.cancel),size:"sm",variant:"secondary",onPress:()=>{i("show"),e?.();}}),jsxRuntime.jsx(O,{label:o(ro.save),size:"sm",onPress:()=>{plateLink.upsertLink(t,{url:n,skipValidation:!0}),e?.();}})]})]})]})};function tu({className:e,children:t,...o}){return jsxRuntime.jsx(plateCommon.PlateElement,{asChild:!0,className:e,...o,children:jsxRuntime.jsx("a",{className:pr({size:"sm"}),children:t})})}var ro=j({addLink:{id:"addLink",defaultMessage:"Add Link",description:"Add Link"},editLink:{id:"editLink",defaultMessage:"Edit Link",description:"Edit Link"},removeLink:{id:"removeLink",defaultMessage:"Remove Link",description:"Remove Link"},cancel:{id:"cancel",defaultMessage:"Cancel",description:"Cancel"},save:{id:"save",defaultMessage:"Save",description:"Save"},link:{id:"linkAnnotation",defaultMessage:"Link",description:"Link"}});var AC=color.parseColor("#ffffff00").toString("hexa"),on=[{label:"Red",color:"#ff0000"},{label:"Green",color:"#00ff00"},{label:"Blue",color:"#0000ff"},{label:"Yellow",color:"#ffff00"},{label:"Cyan",color:"#00ffff"},{label:"Magenta",color:"#ff00ff"},{label:"Black",color:"#000000"},{label:"White",color:"#ffffff"},{label:"Gray",color:"#808080"},{label:"Orange",color:"#ffa500"},{label:"Brown",color:"#a52a2a"},{label:"Purple",color:"#800080"}];[...on,{label:"Transparent",color:AC}];var oa=({nodeType:e,icon:t,ariaLabel:o,isDisabled:r})=>{let a=plateCommon.useEditorSelector(n=>plateCommon.isMarkActive(n,e),[]),i=plateCommon.useEditorRef();return jsxRuntime.jsx(ve,{variant:"tertiary",isSelected:a,size:"sm",icon:t,"aria-label":o,isDisabled:r,onPress:()=>{plateCommon.toggleMark(i,{key:e});},preventFocusOnPress:!0})},rn=({nodeType:e,"aria-label":t,isDisabled:o})=>{let{updateColor:r,clearColor:a,color:i}=plateFont.useColorDropdownMenuState({customColors:[],colors:[],nodeType:e}),n=to.useCallback(({ref:s,triggerProps:p})=>jsxRuntime.jsx(L,{icon:e==="color"?_24.TextIcon:_24.HighlightTextIcon,"aria-label":t,size:"md",variant:"popover",isDisabled:o,className:Fo,preventFocusOnPress:!0,...p,ref:s}),[e,t,o]),l=to.useCallback(s=>{s?r(s.toString("rgba")):a();},[a,r]);return jsxRuntime.jsx(Bo,{presets:on,allowRemoval:!0,pickerMode:"lazy",placement:"top end",colorLabel:!1,renderTriggerButton:n,value:i||"#000000",onChange:l,isDisabled:o})};var gP=[{type:plateParagraph.ELEMENT_PARAGRAPH,children:[{text:""}]}],ea=to__default.default.createContext({items:[],containerRef:{current:null},maxMentionableUsersSuggestions:10}),nn=to__default.default.forwardRef(({value:e,defaultValue:t,onChange:o,style:r,spellCheck:a,placeholder:i,isInline:n,isDisabled:l,editableContentAriaLabel:s,containerRef:p,onHelpDialogOpenRequest:d,mentionableUsers:u,editorHandle:c,maxMentionableUsersSuggestions:m,autoFocus:f,editorRef:y,saveOnEnter:g,onSave:v},b)=>{let h=to.useRef(null),z=reactAria.useId(),{formatMessage:x}=B(),R=to.useRef(null),C=R.current,P=to.useRef(null),k=to.useMemo(()=>C?.getRootNode()instanceof ShadowRoot,[C]),[T,I]=utils$1.useControlledState(e?en(e):void 0,en(t||"<p></p>"),w=>{o&&o(It(w));}),{keyboardProps:D}=reactAria.useKeyboard({onKeyDown:w=>{(g&&w.key==="Enter"&&!w.shiftKey||(w.ctrlKey||w.metaKey)&&w.key==="Enter")&&(w.preventDefault(),v()),w.altKey&&w.key==="F10"?(w.preventDefault(),h.current&&h.current.querySelector("button")?.focus()):w.continuePropagation(),Ko()&&k&&P.current&&plateCommon.focusEditor(P.current);}});to.useEffect(()=>{l&&P.current&&plateCommon.deselect(P.current);},[l]),to.useImperativeHandle(b,()=>({startMention:()=>{P.current&&!R.current?.querySelector("input[role='combobox']")&&Jr(P.current);}})),to.useImperativeHandle(c,()=>({setCaretPosition:w=>{P.current&&(plateCommon.focusEditor(P.current),plateCommon.moveSelection(P.current,{distance:w,unit:"character"}));}}));let E=to.useMemo(()=>({items:u||[],containerRef:p,maxMentionableUsersSuggestions:m}),[u,p,m]);return jsxRuntime.jsx(ea.Provider,{value:E,children:jsxRuntime.jsxs(plateCommon.Plate,{initialValue:T||gP,plugins:ou,editorRef:N(P,y||null),onChange:w=>{I(w);},children:[jsxRuntime.jsxs(Gr,{className:Yr,"aria-controls":z,ref:h,children:[jsxRuntime.jsxs(M,{display:"flex",flexDirection:"row",role:"group",gap:"xs",paddingX:"sm",children:[jsxRuntime.jsx(oa,{nodeType:plateBasicMarks.MARK_BOLD,icon:_20.BoldIcon,ariaLabel:x(Ao.bold),isDisabled:l}),jsxRuntime.jsx(oa,{nodeType:plateBasicMarks.MARK_ITALIC,icon:_20.ItalicIcon,ariaLabel:x(Ao.italic),isDisabled:l}),jsxRuntime.jsx(oa,{nodeType:plateBasicMarks.MARK_UNDERLINE,icon:_20.UnderlineIcon,ariaLabel:x(Ao.underline),isDisabled:l})]}),jsxRuntime.jsx(F,{orientation:"vertical",className:xt}),jsxRuntime.jsx(rn,{nodeType:plateFont.MARK_COLOR,"aria-label":x(Ao.fontColor),isDisabled:l}),jsxRuntime.jsx(F,{orientation:"vertical",className:xt}),jsxRuntime.jsx(rn,{nodeType:plateFont.MARK_BG_COLOR,"aria-label":x(Ao.backgroundColor),isDisabled:l}),jsxRuntime.jsx(F,{orientation:"vertical",className:xt}),jsxRuntime.jsx(nu,{isDisabled:l}),jsxRuntime.jsx(F,{orientation:"vertical",className:xt}),jsxRuntime.jsx(L,{className:Fo,icon:_24.QuestionmarkCircleIcon,size:"sm","aria-label":x(Ao.help),onPress:d})]}),jsxRuntime.jsx(F,{variant:"secondary"}),jsxRuntime.jsx("div",{...D,ref:R,children:jsxRuntime.jsx(plateCommon.PlateContent,{id:z,disabled:l,readOnly:l,style:r,placeholder:i,autoFocus:f,spellCheck:a,"aria-label":s,className:utils.classNames(Wr({isDisabled:l}),Xr({isInline:n})),renderPlaceholder:({attributes:w,children:S})=>jsxRuntime.jsx("span",{...w,className:tokens.sprinkles({paddingY:"lg"}),children:S})})})]})})});nn.displayName="RichEditor";var Wm=({key:e,value:t},{isDisabled:o,optionProps:r,isFocused:a,_state:i},n)=>{let{hoverProps:l}=reactAria.useHover({isDisabled:o}),{label:s,data:p}=t;return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("li",{...reactAria.mergeProps(r,l),className:km({isDisabled:o,isHovered:a}),"data-active":a,ref:n,children:[jsxRuntime.jsx(So,{name:s,...p?.avatar}),jsxRuntime.jsxs(M,{display:"flex",flexDirection:"column",children:[jsxRuntime.jsx(W,{type:"subtitle",size:"sm",children:s}),jsxRuntime.jsx(W,{type:"helper",size:"sm",children:p?.description})]})]}),e===i.collection.getLastKey()?null:jsxRuntime.jsx(F,{})]})},Ao=j({bold:{defaultMessage:"Bold",id:"bold"},italic:{defaultMessage:"Italic",id:"italic"},underline:{defaultMessage:"Underline",id:"underline"},backgroundColor:{defaultMessage:"Background color",id:"backgroundColor"},fontColor:{defaultMessage:"Font color",id:"fontColor"},help:{defaultMessage:"Help",id:"help"}});var uu=to__default.default.memo(to__default.default.forwardRef(({className:e,style:t,"data-block-id":o,enableRichText:r=!1,onCancel:a,onSave:i,isInline:n=!0,submitButtonIcon:l=_20.ArrowUpCircleFilledIcon,submitButtonAriaLabel:s,cancelButtonAriaLabel:p,"aria-label":d,"aria-describedby":u,"aria-labelledby":c,"aria-details":m,editableContentAriaLabel:f="Editing Area",footerButtons:y,clearOnCancel:g,clearOnSave:v,...b},h)=>{let z=to.useRef(null),{formatMessage:x}=B(),R=to.useRef(null),C=to.useRef(null),P=to.useRef(null),k=!r&&b.variant==="minimal",T=to.useRef(null),[I,D]=to__default.default.useState(b.value||b.defaultValue),E=b.isDisabled||b.isSaveDisabled||!utils.getPlainText(I||""),{fieldProps:w}=reactAria.useLabel({"aria-label":d,"aria-labelledby":c,"aria-describedby":u,"aria-details":m,labelElementType:"div"});k&&!b.avatarName&&console.warn("Editor: When using the minimal `variant` and `enableRichText` is `false`, you should provide an `avatarName`.");let S=to.useCallback(()=>{D(""),r?z.current?.reset():C.current?.clear();},[r]),$=to.useCallback(()=>{E||(i?.(r?It(z.current?.children):R.current.value),v&&S());},[S,v,r,i,E]),re=jsxRuntime.jsx(L,{variant:"ghost","aria-label":s||x(ln.save),icon:l,isDisabled:E,size:"md",excludeFromTabOrder:k,className:k?Rm:void 0,onPress:$,preventFocusOnPress:!0}),[pe,X]=to__default.default.useState(!1),{keyboardProps:K}=reactAria.useKeyboard({onKeyDown:V=>{(V.metaKey||V.ctrlKey)&&V.shiftKey&&V.key==="h"&&(V.preventDefault(),X(!0));}}),G=to.useCallback(V=>{D(V),b.onChange?.(V);},[b]);return jsxRuntime.jsxs("div",{...reactAria.mergeProps(w,r?K:{}),role:"application",ref:N(P,h),style:t,"data-block-id":o,className:utils.classNames(hm({isInline:n,isMinimal:k}),"BaselineUI-Editor",e),"aria-disabled":b.isDisabled,children:[k?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[n?jsxRuntime.jsx(So,{className:zm,name:b.avatarName||""}):null,jsxRuntime.jsxs("div",{className:Tm({isInline:n}),children:[jsxRuntime.jsx(Zr,{isMinimal:k,textBoxRef:R,isInline:n,editableContentAriaLabel:f,...b,onChange:G,onSave:$}),re]})]}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[r?jsxRuntime.jsx(nn,{containerRef:P,ref:T,editorRef:z,isInline:n,editableContentAriaLabel:f,onHelpDialogOpenRequest:()=>{X(!0);},...b,onChange:G,onSave:$}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[!n&&jsxRuntime.jsx(F,{variant:"secondary"}),jsxRuntime.jsx(Zr,{onCancel:a,textBoxRef:R,ref:C,isInline:n,editableContentAriaLabel:f,...b,onChange:V=>{D(V),b.onChange?.(V);},onSave:$})]}),jsxRuntime.jsx(F,{variant:"secondary"}),jsxRuntime.jsxs("div",{className:utils.classNames(Yr,tokens.sprinkles({justifyContent:"space-between"})),children:[jsxRuntime.jsxs(M,{paddingX:"sm",gap:"sm",display:"flex",children:[r&&b.mentionableUsers?jsxRuntime.jsx(L,{icon:_20.AtIcon,size:"sm","aria-label":x(ln.mention),onPress:()=>T.current?.startMention(),preventFocusOnPress:!0}):null,y?.map(({type:V,props:Z},ee)=>V==="action"?jsxRuntime.jsx(L,{...Z,size:"sm",isDisabled:b.isDisabled||Z.isDisabled},ee):jsxRuntime.jsx(ve,{...Z,size:"sm",variant:"tertiary",isDisabled:b.isDisabled||Z.isDisabled},ee))]}),jsxRuntime.jsxs(M,{children:[!!a&&jsxRuntime.jsx(L,{variant:"secondary",icon:_20.CrossCircleFilledIcon,isDisabled:b.isDisabled,size:"md",onPress:()=>{a(),g&&S();},"aria-label":p||x(ln.cancel)}),re]})]})]}),jsxRuntime.jsx(Dm,{isOpen:pe,onClose:()=>{X(!1);}})]})}));uu.displayName="Editor";var ln=j({cancel:{defaultMessage:"Cancel",id:"cancel"},save:{defaultMessage:"Save",id:"save"},mention:{defaultMessage:"Mention",id:"mention"}});var ra=to__default.default.forwardRef(({className:e,style:t,"data-block-id":o,isMounted:r,children:a,transitions:i,elementType:n="div",...l},s)=>{let p=web.useTransition(r,i),d=web.animated[n];return p((u,c)=>c&&jsxRuntime.jsx(d,{className:e,"data-block-id":o,style:{...t,...u},...l,ref:s,children:a}))});ra.displayName="Transition";var fu="_8kqf970 _1yep5z6ow _1yep5z6ox _1yep5z6oy _1yep5z613b _1yep5z613c _1yep5z613d _1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6142 _1yep5z6143 _1yep5z6144 _1yep5z6yh _1yep5z6uq _1yep5z6ur _1yep5z6us _1yep5z6168";var bu=2,gu=to__default.default.forwardRef(({className:e,style:t,hideForKeyboard:o,scrollRef:r,label:a,delay:i=1500,smoothScroll:n=!0,"data-block-id":l},s)=>{let p=to__default.default.useRef(null),d=interactions.useInteractionModality(),[u,c]=to__default.default.useState(!1),m=to.useCallback(()=>{let k=r?.current||ge(p.current).body;return Q(k).getComputedStyle(k).flexDirection==="column-reverse"?k.scrollTop+bu>=0:k.scrollTop+k.clientHeight+bu>=k.scrollHeight},[r]),[f,y]=to__default.default.useState(m),g=Fe(),{buttonProps:v,isPressed:b}=reactAria.useButton({onPress:()=>{let k=r?.current||ge(p.current).body;k.scrollTo({top:k.scrollHeight,behavior:n?"smooth":"auto"});}},p),{focusProps:h,isFocused:z,isFocusVisible:x}=reactAria.useFocusRing(),{hoverProps:R,isHovered:C}=reactAria.useHover({}),P=utils.filterTruthyValues({"data-block-id":l,"data-pressed":b,"data-focus-visible":x,"data-hovered":C,"data-focused":z});return to.useEffect(()=>{y(m());},[m]),to.useEffect(()=>{let k=r?.current||ge(p.current).body,T="onscrollend"in Q(k),I=()=>{setTimeout(()=>{c(!1),y(m());},i);},D=()=>{c(!0),T||I();};return k.addEventListener("scroll",D),k.addEventListener("scrollend",I),()=>{k.removeEventListener("scroll",D),k.removeEventListener("scrollend",I);}},[r,i,m]),jsxRuntime.jsxs(ra,{isMounted:(o?d!=="keyboard":!0)&&!u&&!f,elementType:"button",transitions:{from:{opacity:0,transform:"translateX(-50%) translateY(10px)"},enter:{opacity:1,transform:"translateX(-50%) translateY(0)"},leave:{opacity:0,transform:"translateX(-50%) translateY(10px)"},immediate:g},...reactAria.mergeProps(v,h,R,P),className:utils.classNames(fu,fr({isFocusVisible:x,variant:"high-contrast",isHovered:C}),"BaselineUI-ScrollControlButton",e),style:t,ref:N(s,p),children:[jsxRuntime.jsx(_16.ArrowDownCircleFilledIcon,{size:16}),a]})});gu.displayName="ScrollControlButton";var cn="_1yep5z6jc _1yep5z6jd _1yep5z6je _1yep5z6jl _1yep5z6jm _1yep5z6jn",vu=_({defaultClassName:"_1v0p2z10 _1yep5z63r _1yep5z63s _1yep5z63t _1yep5z619 _1yep5z61a _1yep5z61b _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z69f _1yep5z69g _1yep5z69h",variantClassNames:{hasTitleAndIcon:{true:"_1yep5z6le _1yep5z6lf _1yep5z6lg _1yep5z6nw _1yep5z6nx _1yep5z6ny"},hasNoCloseBtn:{true:"_1yep5z6lk _1yep5z6ll _1yep5z6lm _1yep5z6nw _1yep5z6nx _1yep5z6ny _1yep5z6p2 _1yep5z6p3 _1yep5z6p4 _1yep5z6mq _1yep5z6mr _1yep5z6ms"}},defaultVariants:{},compoundVariants:[[{hasTitleAndIcon:!0,hasNoCloseBtn:!0},"_1yep5z61g7 _1yep5z61g8 _1yep5z61g9"]]}),_u="_1v0p2z10";var ia=to__default.default.forwardRef(({className:e,style:t,"data-block-id":o,message:r,title:a,primaryActionLabel:i,cancelLabel:n,textInputProps:l,icon:s,iconColor:p,showCloseButton:d=!0,onPrimaryAction:u,onCancel:c,autoFocusButton:m,isPrimaryActionDisabled:f},y)=>{let g=reactAria.useId(),{formatMessage:v}=B(),b=a&&jsxRuntime.jsx(W,{id:g,type:"title",size:"sm",elementType:"h3",children:a});return jsxRuntime.jsxs(me,{className:e,style:t,"data-block-id":o,size:"sm",variant:"primary",role:"alertdialog",ref:y,"aria-labelledby":g,children:[jsxRuntime.jsxs("div",{className:vu({hasTitleAndIcon:!!(s&&a),hasNoCloseBtn:!d}),children:[jsxRuntime.jsxs(M,{display:"flex",justifyContent:"space-between",alignItems:"center",flexDirection:"row",children:[s?jsxRuntime.jsx(s,{style:{color:p},size:24}):null,!s&&b,d?jsxRuntime.jsx(L,{icon:_20.XIcon,variant:"secondary",size:"md","aria-label":v(qP.close),onPress:c}):null]}),s?b:null]}),r?jsxRuntime.jsx(M,{elementType:"section",className:_u,paddingX:"lg",paddingBottom:"lg",typography:"body.sm.regular",color:"text.primary",children:r}):null,l?jsxRuntime.jsx(M,{paddingX:"lg",paddingBottom:"lg",children:jsxRuntime.jsx(ko,{...l})}):null,n||i?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(F,{}),jsxRuntime.jsxs(M,{padding:"lg",display:"flex",gap:"xl",children:[n?jsxRuntime.jsx(O,{variant:"secondary",className:cn,label:n,onPress:c,autoFocus:m==="cancel"}):null,i?jsxRuntime.jsx(O,{className:cn,label:i,onPress:u,autoFocus:m==="primary",isDisabled:f}):null]})]}):null]})});ia.displayName="AlertDialog";var qP=j({close:{id:"close",defaultMessage:"Close",description:"Close button label"}});var zu="_1t55bp71",hu="_1yep5z6e3 _1yep5z6eu _1yep5z6i6 _1yep5z6i7 _1yep5z6i8 _1yep5z69i _1yep5z69j _1yep5z69k",xu="_1t55bp70";var ZP=YP__default.default(),Cu=to__default.default.forwardRef(({className:e,style:t,children:o,"data-block-id":r,showCaret:a},i)=>{let n=to.useMemo(()=>{let l=o;return (!o||Array.isArray(o)&&o.length===0)&&(l=""),ZP.render(l)},[o]);return jsxRuntime.jsx("div",{className:utils.classNames(hu,xu,{[zu]:a},"BaselineUI-Markdown",e),"data-block-id":r,style:t,ref:i,dangerouslySetInnerHTML:{__html:n}})});Cu.displayName="Markdown";function Ru(e){let{formatMessage:t,locale:o}=B(),[r,a]=to__default.default.useState(!1),[i,n]=to__default.default.useState(0),[l,s]=to__default.default.useState(0),[p,d]=to__default.default.useState(!1);to.useEffect(()=>{if(!e.current)return;let m=e.current,f=()=>{a(!1),n(0);},y=()=>{p||n(m.currentTime*100/m.duration);},g=()=>{s(m.duration);};return m.addEventListener("ended",f),m.addEventListener("timeupdate",y),m.addEventListener("loadedmetadata",g),()=>{m.removeEventListener("ended",f),m.removeEventListener("timeupdate",y),m.removeEventListener("loadedmetadata",g);}},[p,e]);let u=to.useCallback(()=>{(async()=>e.current&&(e.current.paused?(await e.current.play(),a(!0),liveAnnouncer.announce(t(ku.playing),"polite")):(e.current.pause(),a(!1),liveAnnouncer.announce(t(ku.paused),"polite"))))();},[t,e]),c=to.useCallback(m=>{e.current&&(e.current.currentTime=m*e.current.duration/100,liveAnnouncer.announce(e0(e.current.currentTime,o.locale),"assertive"));},[o.locale,e]);return {isPlaying:r,progress:i,duration:l,togglePlay:u,seek:c,setProgress:n,formattedCurrentTime:e.current?.currentTime?wu(e.current?.currentTime):"00:00",formattedDuration:l?wu(l):"00:00",setIsSliderDragging:d}}var ku=j({playing:{id:"playing",defaultMessage:"Playing"},paused:{id:"paused",defaultMessage:"Paused"}});function e0(e,t){let o=Math.floor(e/3600),r=Math.floor(e%3600/60),a=e%60,i={...o&&{hours:o},...r&&{minutes:r},seconds:Math.floor(a)};return new Intl.DurationFormat(t,{style:"long"}).format(i)}function wu(e){let t=Math.floor(e%3600/60),o=Math.floor(e%60);return [t,o].map(r=>r.toString().padStart(2,"0")).join(":")}var Iu="_1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q",Tu="rta2n91 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69o _1yep5z69p _1yep5z69q _1yep5z6z9 _1yep5z6ut _1yep5z6uu _1yep5z6uv _1yep5z6166 _1yep5z6106",Nu="rta2n90";var Mu=to__default.default.forwardRef(({className:e,style:t,size:o="lg",sources:r,"data-block-id":a,...i},n)=>{let l=to__default.default.useRef(null),{isPlaying:s,progress:p,duration:d,togglePlay:u,seek:c,formattedDuration:m,formattedCurrentTime:f,setProgress:y,setIsSliderDragging:g}=Ru(l),{formatMessage:v}=B(),b=utils.filterTruthyValues({"data-block-id":a,"data-state":s?"playing":"paused","data-loaded":d>0});return jsxRuntime.jsxs("div",{...b,...i,className:utils.classNames(Iu,"BaselineUI-AudioPlayer",e),role:"group",style:t,ref:n,children:[jsxRuntime.jsx(reactAria.VisuallyHidden,{children:jsxRuntime.jsx("audio",{ref:l,children:r.map(({url:h,type:z})=>jsxRuntime.jsx("source",{src:h,type:z},h))})}),jsxRuntime.jsx(ve,{icon:s?_24.PauseIcon:_24.PlayIcon,variant:"toolbar",isSelected:s,size:o,"aria-label":v(s?mn.pause:mn.play),style:{borderRadius:"50%"},onPress:u}),jsxRuntime.jsxs("div",{className:Tu,children:[jsxRuntime.jsx("span",{"aria-hidden":!0,children:f}),jsxRuntime.jsx(Qt,{"aria-label":v(mn.audioTimeline),value:p,minValue:0,maxValue:100,className:Nu,onChange:h=>{y(h),g(!0);},onChangeEnd:h=>{c(h),g(!1);}}),jsxRuntime.jsx("span",{"aria-hidden":!0,children:m})]})]})});Mu.displayName="AudioPlayer";var mn=j({play:{id:"play",defaultMessage:"Play"},pause:{id:"pause",defaultMessage:"Pause"},audioTimeline:{id:"audioTimeline",defaultMessage:"Audio timeline"}});var Du="_1w920rnf _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6fs _1yep5z6ho _1yep5z6hp _1yep5z6hq",Bu="_1w920rn1 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ic _1yep5z6id _1yep5z6ie _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z69i _1yep5z69j _1yep5z69k",Eu="_1w920rn0 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6km",Lt=_({defaultClassName:"_1w920rn2 _1yep5z6d6 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6ir _1yep5z6is _1yep5z6it _1yep5z6hl _1yep5z6hm _1yep5z6hn",variantClassNames:{isFocusVisible:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isLoading:{true:"_1yep5z614w _1yep5z614x _1yep5z614y"},imageWidth:{sm:"_1w920rn6",md:"_1w920rn7"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rn8 _1yep5z6l1 _1yep5z6kz _1yep5z6hc"]]}),Fu="_1w920rnd _1yep5z6kw",Hu=_({defaultClassName:"_1w920rn9 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z63 _1yep5z64 _1yep5z65 _1yep5z62f _1yep5z62g _1yep5z62h _1yep5z6b0 _1yep5z6b1 _1yep5z6b2 _1yep5z6bo _1yep5z6bp _1yep5z6bq _1yep5z6cc _1yep5z6cd _1yep5z6ce _1yep5z6d0 _1yep5z6d1 _1yep5z6d2 _1yep5z6fw _1yep5z6eu _1yep5z6dy",variantClassNames:{isFocusVisible:{true:"_1w920rna _1yep5z6l1 _1yep5z6kz _1yep5z6hc"},isSelected:{true:"_1w920rnb"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0,isSelected:!0},"_1w920rnc _1yep5z61rm _1yep5z61rl _1yep5z61nz"]]}),Ou="_1w920rne";var Au=({items:e,ulRef:t})=>{let{length:o}=e,r=to__default.default.useRef(null);return to.useLayoutEffect(()=>{if(!r.current)return;let a=r.current.closest(".BaselineUI-ImageGallery")?.querySelector(`[data-image-key='${e?.at(-1)?.key}']`)?.cloneNode(!0);utils.invariant(a,"Node is not defined."),r.current?.prepend(a);},[e,t]),jsxRuntime.jsx("div",{className:Lt(),ref:r,children:jsxRuntime.jsx(M,{backgroundColor:"background.secondary.medium",borderRadius:"full",typography:"label.md.medium",color:"text.primary",position:"absolute",paddingX:"md",className:Ou,children:o})})};var $u=({item:{value:e},options:{optionProps:t,isFocusVisible:o,isSelected:r},liRef:a,fit:i="contain",imageWidth:n=102,onDelete:l,aspectRatio:s})=>{let p=reactAria.useId(),{formatMessage:d}=B();utils.invariant(e&&(e?.type==="option"||e?.type===void 0));let{imgProps:u,isLoading:c,isLoaded:m}=bo({src:e.data?.src,alt:e.data?.alt??""}),f=web.useTransition(m,{from:{opacity:0},enter:{opacity:1},leave:{opacity:0}}),y=lodash.isNumber(n)?void 0:Lt({imageWidth:n}),g=lodash.isNumber(n)?{width:n}:void 0;return jsxRuntime.jsxs("li",{...t,ref:a,className:Bu,"aria-labelledby":p,children:[jsxRuntime.jsx("div",{className:utils.classNames(Lt({isFocusVisible:o,isSelected:r,isLoading:!0}),y),style:{aspectRatio:s?.toString(),...g},"data-image-key":e.id,children:c?jsxRuntime.jsx(Io,{"aria-label":d(Mt.loading)}):f((v,b)=>b&&jsxRuntime.jsx(web.animated.div,{role:"img","aria-label":u.alt,style:{...v,backgroundImage:`url(${u.src})`,backgroundSize:i},className:Fu,children:l?jsxRuntime.jsx("div",{className:Du,children:jsxRuntime.jsx(L,{"aria-label":d(Mt.delete),size:"xs",icon:_12.XIcon,onPress:()=>{l(e.id);},UNSAFE_NON_INTERACTIVE:!0})}):null}))}),jsxRuntime.jsx("span",{id:p,className:Hu({isFocusVisible:o,isSelected:r}),children:e.label})]})};var x0={width:0,display:"block"};var C0=to__default.default.createContext(null),fn=to__default.default.forwardRef(({className:e,style:t,fit:o="cover",onReorder:r,"data-block-id":a,onDelete:i,imageWidth:n="sm",aspectRatio:l=3/4,list:s,onKeyDown:p,...d},u)=>{let c=to__default.default.useRef(null),[m,f]=to.useState([]),{formatMessage:y}=B(),g=to.useCallback(z=>{z.target.dropPosition==="before"?s.moveBefore(z.target.key,z.keys):z.target.dropPosition==="after"&&s.moveAfter(z.target.key,z.keys),r?.(z);},[s,r]),v=to.useCallback(()=>{i&&m.length&&(s.remove(...m),i(new Set(m)),f([]));},[m,s,i]),b=to.useCallback((z,x,R)=>jsxRuntime.jsx($u,{item:z,options:x,liRef:R,fit:o,imageWidth:n,aspectRatio:l,onDelete:i?C=>{f([C]);}:void 0}),[l,o,i,n]),{keyboardProps:h}=reactAria.useKeyboard({onKeyDown(z){if(p?.(z),z.key==="Backspace"||z.key==="Delete"){if(!i)return;if([...s.selectedKeys].length)f([...s.selectedKeys]);else {let R=s.getItem(z.target.dataset.key).id;f([R]);}}}});return jsxRuntime.jsxs("div",{...h,ref:u,style:t,className:utils.classNames("BaselineUI-ImageGallery",e),"data-block-id":a,children:[jsxRuntime.jsx(te,{...d,items:s.items,onReorder:g,layout:"grid",orientation:"vertical",className:Eu,ref:c,dropIndicatorStyle:x0,renderOption:b,renderDragPreview:z=>jsxRuntime.jsx(Au,{items:z,ulRef:c}),onSelectionChange:s.setSelectedKeys,getItems:z=>[...z].map(x=>({src:s.getItem(x).src||"",alt:s.getItem(x).alt||"",key:x}))}),jsxRuntime.jsx(ze,{isOpen:!![...m].length,onOpenChange:z=>{z||f([]);},children:jsxRuntime.jsx(Te,{isDismissable:!0,children:jsxRuntime.jsx(ia,{showCloseButton:!1,title:"Are you sure you want to delete this item?",primaryActionLabel:y(Mt.delete),cancelLabel:y(Mt.cancel),onCancel:()=>{f([]);},onPrimaryAction:v,autoFocusButton:"cancel"})})})]})});fn.displayName="ImageGalleryCore";var Uu=to__default.default.forwardRef((e,t)=>{let{items:o=[],onListChange:r,onSelectionChange:a}=e,i=js({initialItems:o.map(n=>({id:n.id,label:n.label,data:{src:n.src,alt:n.alt}})),onListChange:r,onSelectionChange:a});return jsxRuntime.jsx(fn,{...e,ref:t,list:i})});Uu.displayName="ImageGalleryStandalone";var qu=to__default.default.forwardRef((e,t)=>{let o=to.useContext(C0);return to.useEffect(()=>{utils.invariant(o||e.items,"ImageGallery: A `state` that can be passed via context or `items` are required.");},[e.items,o]),o?jsxRuntime.jsx(fn,{...e,ref:t,list:o}):jsxRuntime.jsx(Uu,{...e,ref:t})});qu.displayName="ImageGallery";var Mt=j({delete:{id:"delete",defaultMessage:"Delete"},cancel:{id:"cancel",defaultMessage:"Cancel"},loading:{id:"loading",defaultMessage:"Loading"}});var Ku="_1sexph00",Gu="_1sexph01 _1yep5z616p _1yep5z616q _1yep5z616r _1yep5z6191 _1yep5z6192 _1yep5z6193 _1yep5z61a7 _1yep5z61a8 _1yep5z61a9 _1yep5z617v _1yep5z617w _1yep5z617x _1yep5z61q4 _1yep5z61q5 _1yep5z61q6";var Xu=to__default.default.forwardRef(({className:e,style:t,items:o,"data-block-id":r,hideLabel:a,size:i="md",isDisabled:n,showSelectedIcon:l=!0,excludeFromTabOrder:s,...p},d)=>{let u=se(),c=reactStately.useSelectState({items:o,...p,children:u,validationState:p.validationState==="error"?"invalid":"valid",onSelectionChange:x=>{x&&f(x),p.onSelectionChange?.(x);}}),[m,f]=to.useState(c.selectedKey||c.collection.getFirstKey()),y=to.useMemo(()=>c.collection.getItem(m),[m,c.collection]),{hoverProps:g,isHovered:v}=reactAria.useHover({isDisabled:n}),b=to.useMemo(()=>{let x=y.textValue||y["aria-label"],R=y.value.icon,C=m===c.selectedKey,k={size:i,isSelected:C,onPress:()=>{c.setSelectedKey(C?null:m);},isDisabled:n,excludeFromTabOrder:s};return a&&R?jsxRuntime.jsx(ve,{icon:R,"aria-label":x,variant:"toolbar",...k}):jsxRuntime.jsx(mr,{iconStart:R,label:x,...k})},[m,y,s,a,n,v,i,c]),h=to.useCallback(({buttonProps:x,isOpen:R,ref:C})=>{let P=m===c.selectedKey;return jsxRuntime.jsx(ve,{...x,ref:C,icon:_8.ChevronDownIcon,"aria-expanded":R,variant:"toolbar",size:i,isSelected:P,className:Gu,isDisabled:n,excludeFromTabOrder:s})},[m,s,n,i,c.selectedKey]),z=utils.filterTruthyValues({"data-block-id":r,"data-hovered":v,"data-selected":m===c.selectedKey});return jsxRuntime.jsx(ei.Provider,{value:c,children:jsxRuntime.jsxs(M,{...g,role:"group",display:"inline-flex",flexDirection:"row",alignItems:"center",className:utils.classNames(Ku,"BaselineUI-ButtonSelect",e),"aria-label":p["aria-label"],"aria-labelledby":p["aria-labelledby"],"aria-describedby":p["aria-describedby"],"aria-details":p["aria-details"],style:t,ref:d,...z,children:[b,jsxRuntime.jsx(Ae,{isDisabled:n,showSelectedIcon:l,placement:"bottom end",items:o,...p,variant:"ghost",renderTrigger:h})]})})});Xu.displayName="ButtonSelect";var Yu=_({defaultClassName:"_18v88n10 _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6kv",variantClassNames:{labelPosition:{top:"_1yep5z613n _1yep5z613o _1yep5z613p",start:"_1yep5z613k _1yep5z613l _1yep5z613m _1yep5z6152 _1yep5z6153 _1yep5z6154 _1yep5z6ut _1yep5z6uu _1yep5z6uv"}},defaultVariants:{},compoundVariants:[]}),Zu=_({defaultClassName:"_18v88n1p _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6eu _1yep5z6kv _1yep5z6l6 _1yep5z6ky _1yep5z6dy",variantClassNames:{isDisabled:{true:"_18v88n1q _1yep5z6109"},labelPosition:{top:"_18v88n1r",start:"_18v88n1s"}},defaultVariants:{},compoundVariants:[]}),Qu=_({defaultClassName:"_18v88n1t _1yep5z660 _1yep5z661 _1yep5z662 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5 _1yep5z6ks",variantClassNames:{validationState:{valid:"_18v88n1u",error:"_1yep5z6zp",warning:"_1yep5z6zx"},isReadOnly:{true:"_1yep5z610b"}},defaultVariants:{},compoundVariants:[]}),Ju=_({defaultClassName:"_18v88n1d _1yep5z6ai _1yep5z6aj _1yep5z6ak _1yep5z6b6 _1yep5z6b7 _1yep5z6b8 _1yep5z6bu _1yep5z6bv _1yep5z6bw _1yep5z6ci _1yep5z6cj _1yep5z6ck _1yep5z6i0 _1yep5z6i1 _1yep5z6i2 _1yep5z6i9 _1yep5z6ia _1yep5z6ib _1yep5z6l9 _1yep5z6l7 _1yep5z6gq _1yep5z6ir _1yep5z6is _1yep5z6it",variantClassNames:{validationState:{valid:"_18v88n1e",error:"_1yep5z611k",warning:"_18v88n1g"},isHovered:{true:"_18v88n1h"},isFocused:{true:"_1yep5z6vt _1yep5z6vu _1yep5z6vv _1yep5z6wh _1yep5z6wi _1yep5z6wj _1yep5z6x5 _1yep5z6x6 _1yep5z6x7 _1yep5z6xt _1yep5z6xu _1yep5z6xv _1yep5z616k _1yep5z616i _1yep5z611y _1yep5z616b _1yep5z616a _1yep5z612n _1yep5z616d"},isDisabled:{true:"_18v88n1j"},variant:{primary:"_18v88n1k",ghost:"_18v88n1l"},isReadOnly:{true:"_1yep5z612n"}},defaultVariants:{},compoundVariants:[[{variant:"ghost",isHovered:!0,isFocused:!1,validationState:"valid"},"_1yep5z61rv _1yep5z61rt _1yep5z61nc"],[{variant:"ghost",isFocused:!1,isHovered:!1,validationState:"valid"},"_18v88n1n"],[{isHovered:!0,validationState:"valid",isDisabled:!1,isReadOnly:!1,isFocused:!1,variant:"primary"},"_1yep5z61nd"],[{isHovered:!0,validationState:"warning",isDisabled:!1,isReadOnly:!1,isFocused:!1},"_1yep5z61nd"],[{isReadOnly:!0,variant:"primary",isFocused:!1},"_18v88n1o"]]}),ef=_({defaultClassName:"_18v88n13 _1yep5z6dy _1yep5z6ev",variantClassNames:{isDisabled:{true:"_1yep5z6109"}},defaultVariants:{},compoundVariants:[]}),of=_({defaultClassName:"_18v88n19 _1yep5z6i3 _1yep5z6i4 _1yep5z6i5",variantClassNames:{labelPosition:{top:"_1yep5z6sh _1yep5z6si _1yep5z6sj",start:"_1yep5z6me _1yep5z6mf _1yep5z6mg _1yep5z613n _1yep5z613o _1yep5z613p"},hasMessage:{true:"_18v88n1c"}},defaultVariants:{},compoundVariants:[[{labelPosition:"start",hasMessage:!1},"_1yep5z61q7 _1yep5z61q8 _1yep5z61q9"]]}),tf="_1yep5z6kv",rf="_1yep5z6d7 _1yep5z6fs",af=_({defaultClassName:"_18v88n15 _1yep5z699 _1yep5z69a _1yep5z69b _1yep5z6ky",variantClassNames:{isFocusVisible:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isHovered:{true:"_1yep5z6116 _1yep5z612v _1yep5z6169"},isOpen:{true:"_1yep5z612v _1yep5z6169"}},defaultVariants:{},compoundVariants:[[{isFocusVisible:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isHovered:!0},"_1yep5z61mh _1yep5z61o6 _1yep5z61rk"],[{isOpen:!0},"_1yep5z61o6 _1yep5z61rk"]]});var lf=to__default.default.forwardRef(({className:e,style:t,inputStyle:o,inputClassName:r,"data-block-id":a,label:i,items:n,showSelectedIcon:l=!1,onSelectionChange:s,onInputChange:p,isInvalid:d=!1,labelPosition:u="top",validationState:c="valid",variant:m="primary",toggleLabel:f,renderOption:y,showIcon:g=!0,filter:v,...b},h)=>{let{contains:z}=reactAria.useFilter({sensitivity:"base"}),x=se(),R=reactStately.useComboBoxState({...b,defaultFilter:v||z,defaultItems:n,onSelectionChange:s,onInputChange:p,children:x,validationState:d?"invalid":"valid"}),C=to__default.default.useRef(null),P=to__default.default.useRef(null),k=to__default.default.useRef(null),T=to__default.default.useRef(null),I=to__default.default.useRef(null),{buttonProps:D,inputProps:E,listBoxProps:w,labelProps:S,errorMessageProps:$,descriptionProps:re,validationErrors:pe}=reactAria.useComboBox({...b,inputRef:P,defaultItems:n,buttonRef:C,listBoxRef:k,popoverRef:T,validationState:c==="error"?"invalid":"valid"},R),X=b.errorMessage||pe.join(" "),K=_e({...b,errorMessage:X,descriptionProps:re,errorMessageProps:$,labelPosition:u});X&&(c="error");let{hoverProps:G,isHovered:V}=reactAria.useHover({isDisabled:b.isDisabled}),{isFocused:Z,focusProps:ee,isFocusVisible:Ce}=reactAria.useFocusRing(),Pe=Po({isReadOnly:b.isReadOnly,validationState:c}),ye=utils.filterTruthyValues({"data-read-only":b.isReadOnly,"data-disabled":b.isDisabled,"data-validation-state":c,"data-focused":Z,"data-focus-visible":Ce}),{labelProps:ke,fieldProps:Le}=reactAria.useLabel({label:i});return jsxRuntime.jsx(We.Provider,{value:R,children:jsxRuntime.jsxs("div",{className:utils.classNames(Yu({labelPosition:u}),e,"BaselineUI-ComboBox"),"data-block-id":a,style:t,ref:h,children:[i||u==="start"&&K?jsxRuntime.jsxs("div",{className:of({labelPosition:u,hasMessage:!!K}),children:[jsxRuntime.jsx("label",{...reactAria.mergeProps(S,ke),className:ef({isDisabled:b.isDisabled}),children:i}),u==="start"&&K]}):null,jsxRuntime.jsxs("div",{...G,className:Ju({validationState:c,isHovered:V,isFocused:Z,variant:m,isReadOnly:!!b.isReadOnly,isDisabled:!!b.isDisabled}),ref:I,children:[jsxRuntime.jsx("input",{...reactAria.mergeProps(E,ee,ye,Le),ref:P,className:utils.classNames(Zu({isDisabled:b.isDisabled,labelPosition:u}),"BaselineUI-ComboBox-Input",r),style:o}),Pe&&g?jsxRuntime.jsx(Pe,{className:Qu({validationState:c,isReadOnly:b.isReadOnly}),size:16}):null,jsxRuntime.jsx(O,{...D,ref:C,variant:"popover",label:f,className:af({isFocusVisible:!b.isDisabled&&!b.isReadOnly&&Ce,isHovered:!b.isDisabled&&!b.isReadOnly&&V,isOpen:R.isOpen})})]}),R.isOpen?jsxRuntime.jsx(le,{className:rf,ref:T,triggerRef:I,state:R,children:jsxRuntime.jsx(te,{...w,items:n,ref:k,renderOption:y,selectionMode:"single",showSelectedIcon:l,className:tf})}):null,u==="top"&&K]})})});lf.displayName="ComboBox";var pf="byycd00";var bn=to__default.default.forwardRef(({item:e,renderGridItem:t,state:o},r)=>{let a=Re(r),i=reactAria.useGridListItem({node:e},o,a),n=o.selectionManager.selectionMode!=="none"&&o.selectionManager.selectionBehavior==="toggle",{checkboxProps:l}=reactAria.useGridListSelectionCheckbox({key:e.key},o);return t(e,{...i,checkBoxProps:n?l:void 0},a)});bn.displayName="GridListItem";var df=to__default.default.forwardRef(({className:e,style:t,"data-block-id":o,...r},a)=>{let i=se(),n=reactStately.useListState({...r,children:i}),l=Re(a),{gridProps:s}=reactAria.useGridList(r,n,l);return jsxRuntime.jsx("ul",{...s,className:utils.classNames(pf,e),"data-block-id":o,style:t,ref:l,children:[...n.collection].map(p=>jsxRuntime.jsx(bn,{item:p,state:n,renderGridItem:r.renderGridItem},p.key))})});df.displayName="GridList";var mf="_1dc3b8m0";var yf=to__default.default.forwardRef(({className:e,selectionMode:t="single",style:o,"data-block-id":r,includeTooltip:a,...i},n)=>{let l=Re(n),s=se(),p=reactStately.useListState({...i,selectionMode:t,suppressTextValueWarning:!0,children:s}),{actionGroupProps:d}=actiongroup.useActionGroup({...i,selectionMode:t,children:s},p,l);return jsxRuntime.jsx(M,{...d,display:"flex",flexDirection:"row",gap:"xs",className:utils.classNames("BaselineUI-ActionGroup",e),"data-block-id":r,style:o,ref:l,children:[...p.collection].map(u=>jsxRuntime.jsx(ek,{item:u,state:p,isDisabled:i.isDisabled,onAction:i.onAction,includeTooltip:a},u.key))})});yf.displayName="ActionGroup";var ek=({item:e,state:t,onAction:o,includeTooltip:r,isDisabled:a})=>{let{buttonProps:i}=actiongroup.useActionGroupItem({key:e.key},t),n=a||t.selectionManager.isDisabled(e.key),l=t.selectionManager.isSelected(e.key);utils.invariant(e.value);let{icon:s}=e.value;return utils.invariant(s),jsxRuntime.jsx(interactions.PressResponder,{...reactAria.mergeProps(i,{onPress:()=>{o?.(e.key);}}),children:jsxRuntime.jsx(He,{text:e.textValue,size:"sm",variant:"inverse",isDisabled:!r,includeArrow:!1,offset:4,children:jsxRuntime.jsx(L,{variant:"tertiary",icon:s,"aria-label":e.textValue,size:"sm",isDisabled:n,className:utils.classNames({[mf]:l},"BaselineUI-ActionGroup-Item")})})})};var gf=to__default.default.forwardRef(({className:e,style:t,items:o,optionsContainerClassName:r,"data-block-id":a,label:i,icon:n,value:l,defaultValue:s,onChange:p,isDisabled:d,optionClassName:u,optionStyle:c,labelPosition:m="top",...f},y)=>{let g=to.useMemo(()=>o.map(b=>({id:b.color,label:b.label})),[o]),v=reactAria.useId();return to.useEffect(()=>{!i&&!f["aria-label"]&&!f["aria-labelledby"]&&console.warn("ColorSwatchPicker: Please provide a label or aria-label for accessibility.");},[i,f]),jsxRuntime.jsxs(M,{...ma(f),className:utils.classNames("BaselineUI-ColorSwatchPicker",e),"data-block-id":a,display:"flex",flexDirection:m==="top"?"column":"row",alignItems:m==="top"?"flex-start":"center",justifyContent:"space-between",gap:"md",style:t,ref:y,children:[n||i?jsxRuntime.jsxs(M,{display:"flex",alignItems:"center",gap:"md",children:[n?jsxRuntime.jsx(n,{size:24,className:tokens.sprinkles({color:"icon.primary"})}):null,i?jsxRuntime.jsx(W,{id:v,type:"label",size:"sm",children:i}):null]}):null,jsxRuntime.jsx(te,{className:utils.classNames(Kr,r),selectionMode:"single",items:g,orientation:"horizontal",defaultSelectedKeys:s?[s]:void 0,disabledKeys:d?g.map(b=>b.id):void 0,isDisabled:d,selectedKeys:l?[l]:void 0,onSelectionChange:b=>{p?.([...b][0]);},optionClassName:u,optionStyle:c,renderOption:({key:b,textValue:h},{isSelected:z,isFocusVisible:x,isDisabled:R,optionProps:C},P)=>jsxRuntime.jsx("li",{...C,"data-disabled":R,className:utils.classNames(qr,C.className),ref:P,children:jsxRuntime.jsx(he,{isFocusVisible:x,color:b,isSelected:z,"aria-label":h,isInteractive:!0,isDisabled:R})}),...f,"aria-labelledby":i?v:f["aria-labelledby"]})]})});gf.displayName="ColorSwatchPicker";function rY(e){return e.closest(".BaselineUI-Portal")||e.closest(".BaselineUI-Popover-Content")}
82
82
 
83
83
  Object.defineProperty(exports, "useCollator", {
84
84
  enumerable: true,
@@ -92,93 +92,93 @@ Object.defineProperty(exports, "useNumberFormatter", {
92
92
  enumerable: true,
93
93
  get: function () { return reactAria.useNumberFormatter; }
94
94
  });
95
- exports.Accordion = Pp;
96
- exports.AccordionItem = Lp;
95
+ exports.Accordion = kp;
96
+ exports.AccordionItem = Mp;
97
97
  exports.ActionButton = O;
98
- exports.ActionGroup = pf;
99
- exports.ActionGroupItem = K0;
98
+ exports.ActionGroup = yf;
99
+ exports.ActionGroupItem = ek;
100
100
  exports.ActionIconButton = L;
101
101
  exports.AlertDialog = ia;
102
- exports.AudioPlayer = Ru;
102
+ exports.AudioPlayer = Mu;
103
103
  exports.Avatar = So;
104
104
  exports.Box = M;
105
- exports.ButtonSelect = $u;
106
- exports.Checkbox = Zl;
107
- exports.ColorInput = Do;
108
- exports.ColorPresetInlineInput = Xd;
105
+ exports.ButtonSelect = Xu;
106
+ exports.Checkbox = Ql;
107
+ exports.ColorInput = Bo;
108
+ exports.ColorPresetInlineInput = om;
109
109
  exports.ColorSwatch = he;
110
- exports.ColorSwatchPicker = df;
111
- exports.ComboBox = of;
112
- exports.DateFormat = sp;
113
- exports.Dialog = pe;
114
- exports.DialogTitle = kc;
115
- exports.DomNodeRenderer = Jn;
116
- exports.Drawer = ht;
117
- exports.Editor = su;
118
- exports.FileUpload = bl;
119
- exports.FreehandCanvas = xd;
120
- exports.GridList = af;
121
- exports.Group = Gd;
122
- exports.I18nProvider = Ds;
123
- exports.IconColorInput = bd;
124
- exports.IconColorInputButton = Dt;
125
- exports.IconSelect = Hp;
126
- exports.ImageDropZone = Md;
127
- exports.ImageGallery = Ou;
128
- exports.InlineAlert = lc;
129
- exports.Link = sl;
130
- exports.ListBox = oe;
131
- exports.Markdown = gu;
132
- exports.Menu = lt;
133
- exports.MessageFormat = Kd;
110
+ exports.ColorSwatchPicker = gf;
111
+ exports.ComboBox = lf;
112
+ exports.DateFormat = lp;
113
+ exports.Dialog = me;
114
+ exports.DialogTitle = wc;
115
+ exports.DomNodeRenderer = es;
116
+ exports.Drawer = hr;
117
+ exports.Editor = uu;
118
+ exports.FileUpload = gl;
119
+ exports.FreehandCanvas = kd;
120
+ exports.GridList = df;
121
+ exports.Group = Jd;
122
+ exports.I18nProvider = Es;
123
+ exports.IconColorInput = gd;
124
+ exports.IconColorInputButton = Br;
125
+ exports.IconSelect = Op;
126
+ exports.ImageDropZone = Od;
127
+ exports.ImageGallery = qu;
128
+ exports.InlineAlert = pc;
129
+ exports.Link = ll;
130
+ exports.ListBox = te;
131
+ exports.Markdown = Cu;
132
+ exports.Menu = lr;
133
+ exports.MessageFormat = Qd;
134
134
  exports.Modal = ze;
135
- exports.ModalClose = v5;
135
+ exports.ModalClose = P5;
136
136
  exports.ModalContent = Te;
137
- exports.ModalTrigger = Pt;
137
+ exports.ModalTrigger = Pr;
138
138
  exports.NumberFormat = wo;
139
139
  exports.NumberInput = Ie;
140
- exports.Pagination = np;
141
- exports.Popover = Ye;
140
+ exports.Pagination = sp;
141
+ exports.Popover = Xe;
142
142
  exports.PopoverContent = Ue;
143
- exports.PopoverTrigger = Ze;
143
+ exports.PopoverTrigger = Ye;
144
144
  exports.Portal = ho;
145
- exports.PortalContainerProvider = Os;
146
- exports.Preview = Hd;
147
- exports.ProgressBar = kl;
145
+ exports.PortalContainerProvider = Vs;
146
+ exports.Preview = Ud;
147
+ exports.ProgressBar = wl;
148
148
  exports.ProgressSpinner = Io;
149
- exports.RadioGroup = Ut;
150
- exports.Reaction = Ml;
151
- exports.ScrollControlButton = du;
152
- exports.SearchInput = Rs;
149
+ exports.RadioGroup = Ur;
150
+ exports.Reaction = Dl;
151
+ exports.ScrollControlButton = gu;
152
+ exports.SearchInput = Is;
153
153
  exports.Select = Ae;
154
- exports.Separator = H;
155
- exports.Slider = Qr;
156
- exports.Switch = xs;
157
- exports.TabItem = Jp;
158
- exports.Tabs = Qp;
159
- exports.TagGroup = fp;
154
+ exports.Separator = F;
155
+ exports.Slider = Qt;
156
+ exports.Switch = Cs;
157
+ exports.TabItem = ec;
158
+ exports.Tabs = Jp;
159
+ exports.TagGroup = yp;
160
160
  exports.Text = W;
161
161
  exports.TextInput = ko;
162
162
  exports.ThemeProvider = zo;
163
- exports.ToggleButton = mt;
164
- exports.ToggleIconButton = ge;
165
- exports.Toolbar = Gt;
163
+ exports.ToggleButton = mr;
164
+ exports.ToggleIconButton = ve;
165
+ exports.Toolbar = Gr;
166
166
  exports.Tooltip = He;
167
- exports.Transform = Td;
168
- exports.Transition = ta;
169
- exports.defineMessages = A;
170
- exports.isInsideOverlayContent = XX;
171
- exports.isRect = Gn;
167
+ exports.Transform = Bd;
168
+ exports.Transition = ra;
169
+ exports.defineMessages = j;
170
+ exports.isInsideOverlayContent = rY;
171
+ exports.isRect = Wn;
172
172
  exports.useDevice = go;
173
- exports.useDynamicListData = As;
174
- exports.useI18n = D;
173
+ exports.useDynamicListData = js;
174
+ exports.useI18n = B;
175
175
  exports.useImage = bo;
176
- exports.useIntersectionObserver = Ts;
176
+ exports.useIntersectionObserver = Ns;
177
177
  exports.useIsFirstRender = Fe;
178
- exports.useLocalStorage = Fs;
179
- exports.useMutationObserver = vN;
180
- exports.usePortalContainer = le;
181
- exports.useResizeObserver = Ns;
182
- exports.useTextSelection = kN;
183
- exports.useUndoRedo = Ls;
184
- exports.useUserPreferences = Sa;
178
+ exports.useLocalStorage = Hs;
179
+ exports.useMutationObserver = wN;
180
+ exports.usePortalContainer = de;
181
+ exports.useResizeObserver = Ss;
182
+ exports.useTextSelection = MN;
183
+ exports.useUndoRedo = Ms;
184
+ exports.useUserPreferences = La;