sodtrack-web-ui 0.120.0 → 0.122.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (103) hide show
  1. package/dist/{chunk-QSZHWUTE.js → chunk-DW7EO724.js} +1 -1
  2. package/dist/chunk-IFHVHLTC.js +1 -0
  3. package/dist/components/alert-message.d.ts +2 -1
  4. package/dist/components/attachment-card.d.ts +2 -1
  5. package/dist/components/autocomplete-multiple-skeleton.d.ts +2 -1
  6. package/dist/components/autocomplete-multiple.d.ts +4 -3
  7. package/dist/components/autocomplete-skeleton.d.ts +3 -2
  8. package/dist/components/autocomplete.d.ts +3 -2
  9. package/dist/components/avatar-skeleton.d.ts +2 -1
  10. package/dist/components/avatar.d.ts +2 -1
  11. package/dist/components/badge-alert.d.ts +2 -1
  12. package/dist/components/badge-category-skeleton.d.ts +2 -1
  13. package/dist/components/badge-category.d.ts +2 -1
  14. package/dist/components/badge-expandable-skeleton.d.ts +2 -1
  15. package/dist/components/badge-expandable.d.ts +3 -2
  16. package/dist/components/badge-number.d.ts +2 -1
  17. package/dist/components/badge-status-skeleton.d.ts +2 -1
  18. package/dist/components/badge-status.d.ts +2 -1
  19. package/dist/components/button-active.d.ts +2 -1
  20. package/dist/components/button-menu.d.ts +2 -1
  21. package/dist/components/button.d.ts +2 -1
  22. package/dist/components/calendar.d.ts +2 -1
  23. package/dist/components/card-action.d.ts +80 -0
  24. package/dist/components/card-action.js +1 -0
  25. package/dist/components/card-basic.d.ts +2 -1
  26. package/dist/components/card-expandable.d.ts +2 -1
  27. package/dist/components/card-form.d.ts +2 -1
  28. package/dist/components/checkbox.d.ts +3 -2
  29. package/dist/components/chip-context.d.ts +2 -1
  30. package/dist/components/chip-expandable.d.ts +2 -1
  31. package/dist/components/chip-form-complementary.d.ts +2 -1
  32. package/dist/components/chip-input.d.ts +4 -3
  33. package/dist/components/chip-status-complementary.d.ts +2 -1
  34. package/dist/components/chip-status-table.d.ts +2 -1
  35. package/dist/components/chip-status.d.ts +2 -1
  36. package/dist/components/chip.d.ts +2 -1
  37. package/dist/components/choice-chips.d.ts +3 -2
  38. package/dist/components/country-code.d.ts +2 -1
  39. package/dist/components/country-flag.d.ts +2 -1
  40. package/dist/components/data-table.d.ts +1 -1
  41. package/dist/components/date-picker-popover.d.ts +2 -1
  42. package/dist/components/date-picker.d.ts +3 -2
  43. package/dist/components/divider.d.ts +2 -1
  44. package/dist/components/drawer-bar.d.ts +1 -1
  45. package/dist/components/drawer.d.ts +2 -1
  46. package/dist/components/dropzone.d.ts +3 -2
  47. package/dist/components/empty-state.d.ts +2 -1
  48. package/dist/components/error-screen.d.ts +2 -1
  49. package/dist/components/floating-button.d.ts +2 -1
  50. package/dist/components/icon-button.d.ts +2 -1
  51. package/dist/components/index.d.ts +9 -7
  52. package/dist/components/index.js +1 -1
  53. package/dist/components/list-item-arrow.js +1 -1
  54. package/dist/components/list-item-button.js +1 -1
  55. package/dist/components/list-item-checkbox-left.d.ts +2 -1
  56. package/dist/components/list-item-checkbox-left.js +1 -1
  57. package/dist/components/list-item-checkbox.js +1 -1
  58. package/dist/components/list-item.d.ts +3 -2
  59. package/dist/components/list-item_old.js +1 -1
  60. package/dist/components/menu.d.ts +2 -1
  61. package/dist/components/multi-select-chips.d.ts +3 -2
  62. package/dist/components/note-card.d.ts +2 -1
  63. package/dist/components/number-field-skeleton.d.ts +2 -1
  64. package/dist/components/number-field.d.ts +3 -2
  65. package/dist/components/passive-tabs.d.ts +2 -1
  66. package/dist/components/phone-input-skeleton.d.ts +2 -1
  67. package/dist/components/popover.d.ts +2 -1
  68. package/dist/components/radio.d.ts +4 -3
  69. package/dist/components/rating.d.ts +2 -1
  70. package/dist/components/scrollarea.d.ts +2 -1
  71. package/dist/components/search-bar.d.ts +2 -1
  72. package/dist/components/select-skeleton.d.ts +3 -2
  73. package/dist/components/select.d.ts +3 -2
  74. package/dist/components/select_old.d.ts +2 -1
  75. package/dist/components/sidebar.d.ts +2 -1
  76. package/dist/components/signature-pad.d.ts +3 -2
  77. package/dist/components/skeleton.d.ts +2 -1
  78. package/dist/components/snackbar.d.ts +2 -1
  79. package/dist/components/spinner.d.ts +2 -1
  80. package/dist/components/step-item.d.ts +2 -1
  81. package/dist/components/switch.d.ts +2 -1
  82. package/dist/components/tab.d.ts +2 -1
  83. package/dist/components/table.d.ts +1 -1
  84. package/dist/components/text-field.d.ts +3 -2
  85. package/dist/components/text-field_old.d.ts +2 -1
  86. package/dist/components/textarea.d.ts +3 -2
  87. package/dist/components/textarea_old.d.ts +2 -1
  88. package/dist/components/time-picker.d.ts +3 -2
  89. package/dist/components/toast.d.ts +2 -1
  90. package/dist/components/tooltip.d.ts +2 -1
  91. package/dist/components/tracker-item.d.ts +2 -1
  92. package/dist/{data-table-BiA9OyDW.d.ts → data-table-81xmB7iN.d.ts} +2 -1
  93. package/dist/format.d.ts +2 -1
  94. package/dist/identification-number.d.ts +2 -1
  95. package/dist/{label-CsJyLlgF.d.ts → label-CwyjuBj_.d.ts} +2 -1
  96. package/dist/preferences/domain.d.ts +2 -1
  97. package/dist/preferences.d.ts +2 -1
  98. package/dist/styles/base.d.ts +1 -1
  99. package/dist/styles/fonts.d.ts +1 -1
  100. package/dist/styles/index.css +1 -1
  101. package/dist/styles/index.d.ts +1 -1
  102. package/dist/styles/utilities.d.ts +1 -1
  103. package/package.json +2 -2
@@ -1 +1 @@
1
- import {a as a$3}from'./chunk-ORDWXBDZ.js';import {c as c$3,h}from'./chunk-XRFPQJ5P.js';import {a as a$7}from'./chunk-B5KKVXLE.js';import {b}from'./chunk-5B6ZOVKE.js';import {c as c$6}from'./chunk-JYNJHAGL.js';import {d as d$1}from'./chunk-WAUY2MS6.js';import {a as a$4,b as b$2,c as c$4,d as d$2}from'./chunk-NYURVOJI.js';import {c as c$5}from'./chunk-FYB3QRNL.js';import {a as a$8}from'./chunk-AKR7AIFQ.js';import {c as c$1,e as e$1,a as a$5,b as b$1,d}from'./chunk-MQL3NZ6S.js';import {a as a$6}from'./chunk-VIMWKUML.js';import {c as c$2}from'./chunk-QZUQ6AZK.js';import {d as d$3}from'./chunk-MP4CHZ2K.js';import {a as a$2}from'./chunk-R6NIURLZ.js';import {a}from'./chunk-AWRP67K4.js';import {e as e$2}from'./chunk-PI7DECIN.js';import {c,q,k,h as h$1}from'./chunk-QMPBFFFC.js';import {e}from'./chunk-WWQW5ZXG.js';import {a as a$1}from'./chunk-OBZIYJO7.js';import*as H from'react';import H__default,{createContext,useMemo,useCallback,forwardRef,useRef,useContext,useEffect,useId,useState}from'react';import*as Ht from'@radix-ui/react-portal';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {Field,useFieldContext}from'@ark-ui/react/field';import {useListCollection,Combobox}from'@ark-ui/react/combobox';import {useFilter}from'@ark-ui/react/locale';import {Portal}from'@ark-ui/react/portal';import {getDefaultOptions}from'date-fns';import Pn from'react-phone-number-input/locale/en.json';import En from'react-phone-number-input/locale/es.json';import Nn from'react-phone-number-input/locale/pt.json';import {LexicalComposer}from'@lexical/react/LexicalComposer';import {RichTextPlugin}from'@lexical/react/LexicalRichTextPlugin';import {ContentEditable}from'@lexical/react/LexicalContentEditable';import {HistoryPlugin}from'@lexical/react/LexicalHistoryPlugin';import {ListPlugin}from'@lexical/react/LexicalListPlugin';import {AutoFocusPlugin}from'@lexical/react/LexicalAutoFocusPlugin';import {OnChangePlugin}from'@lexical/react/LexicalOnChangePlugin';import {LexicalErrorBoundary}from'@lexical/react/LexicalErrorBoundary';import {HeadingNode,$isHeadingNode,$createHeadingNode}from'@lexical/rich-text';import {ListNode,ListItemNode,$isListNode,REMOVE_LIST_COMMAND,INSERT_UNORDERED_LIST_COMMAND,INSERT_ORDERED_LIST_COMMAND}from'@lexical/list';import {useLexicalComposerContext}from'@lexical/react/LexicalComposerContext';import {$generateHtmlFromNodes,$generateNodesFromDOM}from'@lexical/html';import {$getSelection,$isRangeSelection,$isElementNode,SELECTION_CHANGE_COMMAND,CAN_UNDO_COMMAND,CAN_REDO_COMMAND,UNDO_COMMAND,REDO_COMMAND,OUTDENT_CONTENT_COMMAND,INDENT_CONTENT_COMMAND,FORMAT_ELEMENT_COMMAND,$createParagraphNode,FORMAT_TEXT_COMMAND,$getRoot,$insertNodes}from'lexical';import {$setBlocksType}from'@lexical/selection';import {$findMatchingParent,mergeRegister}from'@lexical/utils';import {AlignJustifyIcon,AlignRightIcon,AlignCenterIcon,AlignLeftIcon,UnderlineIcon,ItalicIcon,BoldIcon,UndoIcon,RedoIcon,ListIcon,ListOrderedIcon,IndentDecreaseIcon,IndentIncreaseIcon}from'lucide-react';import vl,{parsePhoneNumber,getCountryCallingCode}from'react-phone-number-input';import {getExampleNumber}from'libphonenumber-js/mobile';import pl from'libphonenumber-js/mobile/examples';var wo=(e,t)=>{let o=useCallback(n=>{e.current&&!e.current.contains(n.target)&&t();},[]);useEffect(()=>(document.addEventListener("pointerdown",o),()=>{document.removeEventListener("pointerdown",o);}),[]);},Ge=wo;var Do=({title:e,titleLines:t=2,description:o,descriptionLines:n=1,Icon:r,iconAsColumn:l=true,className:i,...s})=>jsxs("div",{className:a$1("flex gap-2 py-4 pr-6 pl-4",l&&"flex-col items-center gap-1",!l&&!o&&"items-center",i),...s,children:[r&&jsx(r,{className:a$1("shrink-0 text-neutral-300"),size:24}),jsxs("div",{className:a$1("flex flex-col gap-1",l&&"text-center"),children:[jsx("p",{className:a$1("leading-[130%] text-neutral-500",!!o&&"font-medium"),style:t?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:t}:void 0,children:e}),o&&jsx("p",{className:"text-sm leading-[130%] text-neutral-500",style:n?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:n}:void 0,children:o})]})]}),je=Do;var So=H__default.memo(({handleSelect:e$1,NoResultsIcon:t,noResultsLabel:o,noResultsDescription:n,noResultsDescriptionLines:r,noResultsAsColumn:l,noResultsButtonOnClick:i,optionDescriptionLines:s,noResultsButtonLabel:a$2,filteredOptions:d,inputRect:c,inputRef:R,popoverPosition:x,optionsListRef:g,selectedOption:u,options:I,setFilteredOptions:P})=>jsx(Ht.Root,{asChild:true,children:jsxs("div",{ref:g,className:"elevation-8 pointer-events-auto fixed z-50 mb-2 hidden max-h-[336px] w-full flex-col overflow-y-auto rounded-lg bg-neutral-50",style:c?{width:`${c.width}px`,left:c.left,top:x==="bottom"?`${c.bottom}px`:void 0,bottom:x==="top"?`${window.innerHeight-c.top}px`:void 0}:void 0,children:[d.length===0&&jsxs("div",{className:"elevation-8 flex max-h-88 flex-1 flex-col justify-center rounded-lg bg-neutral-50",children:[jsx(je,{title:o,description:n,Icon:t,iconAsColumn:l,descriptionLines:r}),i&&jsxs(Fragment,{children:[jsx(a,{}),jsx(e,{variant:"ghost",className:"my-3 w-fit self-center",onClick:()=>{g.current.style.display="none",R.current.value="",P(I),i();},children:a$2})]})]}),d.map(L=>jsx(b.Root,{disabled:L.disabled,selected:u?.value===L.value,onClick:()=>e$1(L),children:jsxs(b.Content,{children:[jsx(b.Headline,{children:L.label}),L.description&&jsx(b.Description,{className:a$1({"line-clamp-1":s===1,"line-clamp-2":s===2,"line-clamp-3":s===3,"line-clamp-4":s===4}),children:L.description})]})},L.key??L.value))]})})),wt=So;var zo=336,Jl=({options:e,defaultSelectedOption:t,onSelect:o,onClick:n,onInputChange:r,error:l,helperText:i,label:s,placeholder:a,value:d,size:c="md",optionDescriptionLines:R=1,noResultsLabel:x,noResultsIcon:g,noResultsDescription:u,noResultsDescriptionLines:I,noResultsAsColumn:P,noResultsButtonOnClick:L,noResultsButtonLabel:T,className:y,disabled:N})=>{let[b,E]=useState(t??null),f=useRef(null),C=useRef(null),[_,F]=useState(),[U,h]=useState([]),[m,M]=useState("bottom"),[w,A]=useState(),$=zo,j=useCallback(D=>{f.current.style.display="none",C.current.value=D.label,E(D),o?.(D);},[o]),K=useCallback(()=>{if(!C?.current)return;let D=C.current.getBoundingClientRect();F(D);let Z=w?w.height:$,Q=window.innerHeight-D.bottom>Z,we=D.top>Z;M(Q?"bottom":we?"top":"bottom");},[w?.height]),Le=useCallback(()=>{let D=e.filter(Z=>Z.label.toLowerCase().includes(C?.current?.value.toLowerCase()??""));if(h(D),f?.current){let Z=f.current.getBoundingClientRect();A(Z);}},[e]);return useEffect(()=>{h(e);},[e]),useEffect(()=>{if(!d){E(null),C.current&&(C.current.value="");return}(!C.current?.value||b?.value!==d.value)&&(E(d),C.current.value=d.label);},[d]),Ge(f,()=>{f.current.style.display="none",b&&C.current&&(C.current.value=b.label);}),useEffect(()=>{if(C?.current)return K(),C.current.addEventListener("mousedown",K),C.current.addEventListener("input",Le),window.addEventListener("scroll",K,true),window.addEventListener("resize",K),()=>{C.current?.removeEventListener("mousedown",K),C.current?.removeEventListener("input",Le),window.removeEventListener("scroll",K,true),window.removeEventListener("resize",K);}},[K,Le]),jsxs("div",{className:a$1("relative",y),children:[jsx(a$3,{ref:C,autoComplete:"off",list:"",selectMode:true,onChange:D=>{D.target.value||(E(null),o?.(null)),r?.(D);},onClean:()=>{E(null),h(e),o?.(null);},onClick:D=>{f.current.style.display="flex",n?.(D);},onBlur:()=>{b&&C.current&&(C.current.value=b.label);},label:s,helperText:i,placeholder:a,size:c,error:l,disabled:N}),jsx(wt,{handleSelect:j,noResultsLabel:x,NoResultsIcon:g,optionDescriptionLines:R,noResultsAsColumn:P,noResultsButtonLabel:T,noResultsButtonOnClick:L,noResultsDescription:u,noResultsDescriptionLines:I,filteredOptions:U,inputRect:_,inputRef:C,popoverPosition:m,optionsListRef:f,selectedOption:b,options:e,setFilteredOptions:h})]})};var Uo=({children:e,title:t,titleLines:o,description:n="",descriptionLines:r,disabled:l=false,className:i,...s})=>jsxs("div",{className:a$1("flex w-full flex-col gap-1",i),...s,children:[jsx("p",{className:a$1("text-sm leading-[130%] break-all",!!n&&"font-medium"),style:o?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:o}:void 0,children:t}),n&&jsx("p",{className:a$1("text-xs leading-[130%]",l?"text-neutral-400":"text-neutral-700"),style:r?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:r}:void 0,children:n})]}),ce=Uo;var mi=({children:e,title:t,titleLines:o,description:n="",descriptionLines:r,startIcon:l,badgeContent:i,hasDivider:s=false,disabled:a=false,onSelect:d,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:a,onClick:d,hasDivider:s,className:a$1(!a&&"cursor-pointer",c),...R,children:[l&&H__default.cloneElement(l,{className:"shrink-0 mr-2 h-4.5 w-4.5"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:a}),jsxs("div",{className:"ml-4 flex gap-2",children:[i&&jsx(a$2,{content:i,size:"lg",variant:"alert",className:a$1("self-center",a&&"bg-neutral-400")}),jsx(h$1,{className:"h-4.5 w-4.5 self-center"})]})]});var Li=({children:e,title:t,titleLines:o=1,description:n="",descriptionLines:r,startIcon:l,hasDivider:i=false,disabled:s=false,checked:a,onCheckedChange:d,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:s,hasDivider:i,...R,className:a$1("pr-6",c),children:[l&&H__default.cloneElement(l,{className:"shrink-0 w-4.5 h-4.5 mr-2"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:s}),jsx(c$5,{checked:a,onCheckedChange:d,className:"ml-4 self-center",disabled:s})]});var ne=336,Ut=createContext({inputRef:null,optionsListRef:null,autocompleteId:"",inputRect:void 0,showChips:false,filteredOptions:[],currentFocus:-1,popoverPosition:"bottom",setFilteredOptions:()=>{},setCurrentFocus:()=>{},setShowChips:()=>{},setPopoverPosition:()=>{},setInputRect:()=>{},optionsListHeight:ne,setOptionsListHeight:()=>{},optionsListRect:void 0,setOptionsListRect:()=>{}}),oe=()=>{let e=useContext(Ut);if(e===null)throw new Error("useAutocompleteMultipleContext must be used within a AutocompleteMultipleProvider");return e},$t=({children:e})=>{let t=useRef(null),o=useRef(null),n=useId(),[r,l]=useState(),[i,s]=useState(true),[a,d]=useState([]),[c,R]=useState(-1),[x,g]=useState("bottom"),[u,I]=useState(),[P,L]=useState(ne);return jsx(Ut.Provider,{value:{optionsListRef:t,inputRef:o,autocompleteId:n,inputRect:r,showChips:i,filteredOptions:a,currentFocus:c,popoverPosition:x,setFilteredOptions:d,setCurrentFocus:R,setShowChips:s,setPopoverPosition:g,setInputRect:l,optionsListHeight:P,optionsListRect:u,setOptionsListRect:I,setOptionsListHeight:L},children:e})};var Jo=({option:e,onMountWidth:t})=>{let o=useRef(null);return useEffect(()=>{o.current&&t?.(o.current.clientWidth);},[]),jsx(d$1,{variant:"fill",color:"neutral",ref:o,className:"shrink-0",size:"md",hasCloseIcon:false,children:e.label})},Wt=Jo;var nn=150,rn=H__default.memo(({selectedOptions:e,error:t,onCleanSelectedOptions:o,disabled:n,size:r})=>{let{autocompleteId:l,inputRect:i,inputRef:s,optionsListRef:a}=oe(),d=H__default.useRef(null),[c$1,R]=H__default.useState(new Map),x=useMemo(()=>{if(!i?.width)return [];let u=0,I=i.width-nn,P=0;for(let L=0;L<e.length&&(P+=c$1.get(L)??0,!(P>I));L++)u++;return e.slice(0,u)},[i?.width,e,c$1]),g=useCallback(()=>{n||(s?.current?.focus(),a.current.style.display="flex");},[n]);return jsxs("div",{onClick:g,className:a$1("absolute top-0 z-30 flex w-full cursor-pointer flex-nowrap items-center gap-2 pr-12 pl-3",n&&"cursor-not-allowed"),style:{maxWidth:i?.width?i?.width:void 0,height:i?.height?i?.height:void 0},children:[jsx("div",{className:"flex flex-1 gap-1 overflow-hidden",ref:d,children:x.map((u,I)=>jsx(Wt,{option:u,onMountWidth:P=>R(L=>new Map(L).set(I,P))},`chip-input-${l}-${u.value}`))}),e.length>x.length&&jsx("span",{className:"text-base",children:"..."}),e.length>0&&!t&&jsx(a$2,{content:String(e.length),size:r}),t&&e.length>0&&jsx(c,{className:"text-error-700 h-6 w-6",onClick:u=>{u.stopPropagation(),o();}})]})}),qt=rn;var an=H__default.memo(({option:e,index:t,onPressOption:o,isSelected:n,optionDescriptionLines:r})=>{let{currentFocus:l,inputRef:i}=oe();return jsxs(b.Root,{selected:l===t,disabled:e.disabled,onMouseDown:s=>{e.disabled||(i?.current?.value&&s.preventDefault(),o?.(e,s));},children:[jsxs(b.Content,{children:[jsx(b.Headline,{children:e.label}),e.description&&jsx(b.Description,{className:a$1({"line-clamp-1":r===1,"line-clamp-2":r===2,"line-clamp-3":r===3,"line-clamp-4":r===4}),children:e.description})]}),jsx(b.Trailing,{children:jsx(b.CheckboxControl,{checked:n})})]})}),rt=an;var un=H__default.memo(({selectedOptions:e$1,handleSelect:t,NoResultsIcon:o,noResultsLabel:n,noResultsDescription:r,noResultsDescriptionLines:l,noResultsAsColumn:i,noResultsButtonOnClick:s,optionDescriptionLines:a$1,noResultsButtonLabel:d})=>{let{popoverPosition:c,optionsListRef:R,filteredOptions:x,inputRect:g,autocompleteId:u,inputRef:I,optionsListHeight:P}=oe(),L=useCallback(y=>e$1.some(N=>N.value===y.value),[e$1]),T=useMemo(()=>e$1.filter(y=>y.label.toLowerCase().includes(I?.current?.value.toLowerCase()??"")),[e$1,I?.current?.value]);return jsx(Ht.Root,{asChild:true,children:jsxs("div",{ref:R,className:"elevation-8 pointer-events-auto fixed z-50 mb-2 hidden w-full flex-col overflow-y-auto rounded-lg bg-neutral-50",style:g?{width:`${g.width}px`,left:g.left,top:c==="bottom"?`${g.bottom}px`:void 0,bottom:c==="top"?`${window.innerHeight-g.top}px`:void 0,maxHeight:P+"px"}:void 0,children:[x.length===0&&jsxs("div",{className:"elevation-8 flex max-h-88 flex-1 flex-col justify-center rounded-lg bg-neutral-50",children:[jsx(je,{title:n,description:r,Icon:o,iconAsColumn:i,descriptionLines:l}),s&&jsxs(Fragment,{children:[jsx(a,{}),jsx(e,{variant:"ghost",className:"my-3 w-fit self-center",onClick:()=>{R.current.style.display="none",I.current.value="",s();},children:d})]})]}),T.map((y,N)=>jsx(rt,{option:y,index:N,onPressOption:b=>t(b),isSelected:L(y),optionDescriptionLines:a$1},`autocomplete-option-${u}-${y.key??y.value}`)),x.map((y,N)=>!e$1.some(b=>b.value===y.value)&&jsx(rt,{option:y,index:N,onPressOption:b=>t(b),isSelected:L(y),optionDescriptionLines:a$1},`autocomplete-option-${u}-${y.key??y.value}`))]})})}),Kt=un;var hn=H__default.memo(({selectedOptions:e,onSelect:t,error:o,helperText:n,label:r,placeholder:l,options:i,onInputChange:s,size:a,disabled:d})=>{let{setCurrentFocus:c,setFilteredOptions:R,optionsListRef:x,inputRef:g}=oe();return jsx(a$3,{ref:g,autoComplete:"off",list:"",disabled:d,selectMode:true,onChange:u=>{c(-1),s?.(u.target.value);},onClean:()=>{c(-1),R(i),t?.(null,e);},onClick:()=>{d||(x.current.style.display="flex");},error:o,helperText:n,label:r,placeholder:l,fixedTopLabel:e.length>0,size:a})}),Qt=hn;var Yt=({options:e,defaultSelectedOptions:t,onSelect:o,error:n,helperText:r,label:l,placeholder:i,noResultsLabel:s,noResultsIcon:a,noResultsDescription:d,noResultsDescriptionLines:c,noResultsAsColumn:R,noResultsButtonOnClick:x,noResultsButtonLabel:g,className:u,onInputChange:I,value:P,loading:L,size:T="md",optionDescriptionLines:y=1,disabled:N})=>{let{inputRef:b,optionsListRef:E,setFilteredOptions:f,setShowChips:C,setInputRect:_,setPopoverPosition:F,setCurrentFocus:U,showChips:h,setOptionsListRect:m,optionsListRect:M,setOptionsListHeight:w}=oe(),A=useRef(false),[$,j]=useState(t??[]),K=useCallback(W=>{j(J=>{let le,ye=J.findIndex(Fo=>Fo.value===W.value);return ye===-1?(le=J.concat(W),o?.(W,le),le):(le=J.toSpliced(ye,1),o?.(W,le),le)});},[o]),Le=useCallback(()=>{j([]),f(e),o?.(null,[]);},[]),D=useCallback(()=>{C(false);},[]),Z=useCallback(()=>{C(true);},[]),Q=useCallback(()=>{if(!b?.current)return;let W=b.current.getBoundingClientRect();_(W);let J=M?M.height>ne?ne:M.height:ne,le=window.innerHeight-W.bottom>J,ye=W.top>J;F(le?"bottom":ye?"top":"bottom"),w(ye?ne:window.innerHeight-W.bottom>ne?ne:window.innerHeight-W.bottom);},[M?.height]),we=useCallback(()=>{let W=e.filter(J=>J.label.toLowerCase().includes(b?.current?.value.toLowerCase()??""));if(f(W),E?.current){let J=E.current.getBoundingClientRect();m(J);}},[e,E?.current]);return useEffect(()=>{f(e);},[e]),Ge(E,()=>{E.current.style.display="none",U(-1);}),useEffect(()=>{if(b?.current)return Q(),b.current.addEventListener("mousedown",Q),b.current.addEventListener("input",we),b.current.addEventListener("focusin",D),b.current.addEventListener("focusout",Z),window.addEventListener("scroll",Q,true),window.addEventListener("resize",Q),()=>{b.current?.removeEventListener("mousedown",Q),b.current?.removeEventListener("input",Q),b.current?.removeEventListener("focusout",Z),b.current?.removeEventListener("focusin",D),window.removeEventListener("scroll",Q,true),window.removeEventListener("resize",Q);}},[Q,Z,D,we]),useEffect(()=>{P&&(j(P),C(true));},[P]),useEffect(()=>{L||t&&t.length&&!A.current&&(j(t),A.current=true,C(true));},[t,L]),jsxs("div",{className:a$1("relative",u),children:[jsx(Qt,{selectedOptions:$,onSelect:o,error:n,helperText:r,label:l,placeholder:i,handleSelect:K,options:e,onInputChange:I,size:T,disabled:N}),h&&jsx(qt,{selectedOptions:$,disabled:N,error:n,onCleanSelectedOptions:Le,size:T}),jsx(Kt,{handleSelect:K,selectedOptions:$,noResultsLabel:s,NoResultsIcon:a,optionDescriptionLines:y,noResultsAsColumn:R,noResultsButtonLabel:g,noResultsButtonOnClick:x,noResultsDescription:d,noResultsDescriptionLines:c})]})};var Ns=e=>jsx($t,{children:jsx(Yt,{...e})});var vn=({code:e,codeClassName:t})=>jsxs("div",{className:"flex justify-center gap-2",children:[jsx(a$7,{country:e,className:"size-4.5"}),jsx("span",{className:a$1("text-sm leading-[143%] font-medium text-neutral-800",t),children:e})]}),Zt=({className:e,disabled:t,error:o,onChange:n,options:r,readOnly:l,translations:i,value:s})=>{let a$2=useFieldContext(),d=H.useRef(null),c=H.useId(),[R,x]=H.useState(""),{contains:g}=useFilter({sensitivity:"base"}),u=c$1({disabled:t,error:o,readOnly:l}),I=H.useMemo(()=>r.map(f=>({...f,key:f.code})),[r]),P=H.useMemo(()=>I.find(f=>f.key===s),[I,s]),{collection:L,filter:T,set:y}=useListCollection({initialItems:I,itemToString:f=>`${f.label} ${f.code}`,itemToValue:f=>f.key,filter:(f,C,_)=>g(f,C)||g(_.code,C.toUpperCase())});H.useEffect(()=>{y(I);},[I,y]);let N=H.useCallback(({inputValue:f})=>{let C=f??"";x(C),T(C),d.current?.scrollTo({top:0});},[T]),b=H.useCallback(({open:f})=>{f&&(x(""),T(""));},[T]),E=H.useCallback(({items:f})=>{let C=f[0]?.code;C&&n(C);},[n]);return jsxs(Combobox.Root,{className:"h-full shrink-0",collection:L,disabled:t||l,ids:{input:c,label:a$2.ids.label},inputBehavior:"autohighlight",inputValue:R,lazyMount:true,openOnChange:false,openOnClick:false,positioning:{placement:"bottom-end",offset:{mainAxis:12},sameWidth:false},selectionBehavior:"preserve",unmountOnExit:true,value:P?[P.key]:[],onInputValueChange:N,onOpenChange:b,onValueChange:E,children:[jsx(Combobox.Control,{className:"h-full",children:jsx(Combobox.Trigger,{className:a$1("relative flex h-full w-19.5 shrink-0 items-center justify-center rounded-l after:pointer-events-none after:absolute after:top-0 after:right-0 after:h-full after:w-px after:content-['']",u==="error"?"bg-danger-20 after:bg-input-ring-error":u==="disabled"||u==="readOnly"?"after:bg-input-ring-disabled bg-neutral-200":u==="errorReadOnly"?"after:bg-input-ring-error bg-neutral-200":"group-focus-within/id-field:after:bg-input-ring-focus after:bg-input-ring data-[state=open]:after:bg-input-ring-focus bg-neutral-200",e),disabled:t||l,focusable:true,children:P&&jsx(vn,{code:P.code,codeClassName:a$1(u==="error"&&"text-danger-600",(u==="disabled"||u==="readOnly"||u==="errorReadOnly")&&"text-input-text-disabled")})})}),jsx(Portal,{children:jsx(Combobox.Positioner,{children:jsxs(Combobox.Content,{className:"elevation-9 z-layer data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 w-75 origin-(--transform-origin) overflow-hidden rounded-sm bg-neutral-50",children:[jsxs("div",{className:"pb-0",children:[jsx(Combobox.Context,{children:f=>jsx(e$1,{className:"m-1 mb-0",size:"md",state:"default",clearAdornment:!t&&f.inputValue.length>0?jsx(a$5,{onClick:()=>{f.setInputValue("","clear-trigger");}}):void 0,indicator:jsx(q,{className:"pointer-events-none size-4.5 text-neutral-800"}),children:C=>jsx(Combobox.Input,{autoComplete:"off","data-1p-ignore":true,"data-lpignore":"true",placeholder:i.searchCountryPlaceholder,className:C})})}),jsx(a,{className:"mt-2"})]}),jsx(Combobox.List,{ref:d,className:a$1("h-72 overflow-auto outline-none",{"flex flex-col items-center justify-center":L.items.length===0}),children:L.items.length===0?jsx(a$8,{size:"sm",variant:"not-found"}):jsx(Combobox.ItemGroup,{children:L.items.map(f=>jsxs(Combobox.Item,{item:f,className:"data-highlighted:bg-primary-100 relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm text-neutral-900 outline-none select-none data-disabled:pointer-events-none data-disabled:opacity-50",children:[jsx(a$7,{country:f.code,className:"size-4.5"}),jsx(Combobox.ItemText,{className:"min-w-0 flex-1 truncate text-sm leading-[143%] font-medium",children:f.label}),jsx("span",{className:"shrink-0 text-sm text-neutral-600",children:f.code}),jsx(k,{className:a$1("ml-auto size-4 shrink-0",f.key===s?"opacity-100":"opacity-0")})]},f.key))})})]})})})]})};var st={en:"Clear identification number",es:"Limpiar n\xFAmero de identificaci\xF3n",pt:"Limpar n\xFAmero de identifica\xE7\xE3o"},Jt={en:Pn,es:En,pt:Nn},An=st.en,Mn=Jt.en,On={es:{clearIdLabel:st.es,searchCountryPlaceholder:"Buscar..."},pt:{clearIdLabel:st.pt,searchCountryPlaceholder:"Pesquisar..."}},Fn={clearIdLabel:An,searchCountryPlaceholder:"Search..."},eo=()=>{let e=getDefaultOptions().locale?.code?.split("-")[0];return e==="es"||e==="pt"?e:"en"},to=e=>On[e]??Fn,kn=(e,t)=>(Jt[t]??Mn)[e]??e,oo=({localeCode:e})=>c$3.map(t=>({code:t,label:kn(t,e)})).sort((t,o)=>t.label.localeCompare(o.label)),no=a$4,ro=b$2,lo=(e,t)=>{let o=t.trim();return !o||!c$4(e,o).isValid?o:d$2(e,o)};var io=()=>{},ao=H.forwardRef(({autoComplete:e,className:t,country:o,disabled:n,error:r,helperText:l,id:i,label:s,labelProps:a,name:d$1,onBlur:c,onChange:R=io,onCountryChange:x=io,placeholder:g,readOnly:u,required:I,value:P},L)=>{let[T,y]=H.useState(P??""),N=H.useRef(null),b=eo(),E=H.useRef(P??""),f=c$1({disabled:n,error:r,readOnly:u});H.useEffect(()=>{let A=P??"";A!==E.current&&(E.current=A,y(A));},[P]);let C=H.useMemo(()=>to(b),[b]),_=H.useMemo(()=>oo({localeCode:b}),[b]),F=H.useMemo(()=>ro(o??"")||g||no,[o,g]),U=H.useCallback((A,$)=>{let j=lo(A,$);E.current=j,R(j);},[R]),h=H.useCallback(A=>{y(A),U(o??"",A);},[o,U]),m=H.useCallback(A=>{x(A),U(A,T);},[T,x,U]),M=H.useCallback(A=>{N.current=A,typeof L=="function"?L(A):L&&(L.current=A);},[L]),w=H.useCallback(()=>{h(""),N.current?.focus();},[h]);return jsxs(Field.Root,{"data-error":d(f)||void 0,disabled:n,id:i,invalid:r,readOnly:u,className:a$1(b$1,t),children:[s&&jsx(c$2,{...a,as:Field.Label,label:s,required:I}),jsx(e$1,{state:f,className:"group/id-field pl-0",clearAdornment:T?jsx(a$5,{ariaLabel:C.clearIdLabel,onClick:w}):void 0,children:A=>jsxs(Fragment,{children:[jsx(Zt,{disabled:n,error:r,onChange:m,options:_,readOnly:u,translations:C,value:o}),jsx(Field.Input,{"aria-required":I||void 0,autoComplete:e,className:a$1(A,"pl-3"),name:d$1,onBlur:c,onChange:$=>h($.target.value),placeholder:F,value:T,ref:M})]})}),l&&jsx(a$6,{as:r?Field.ErrorText:Field.HelperText,children:l})]})});ao.displayName="IdField";var ga=({children:e$1,title:t,titleLines:o=1,description:n,descriptionLines:r=1,StartIcon:l,hasDivider:i=false,disabled:s=false,actionButton:a,isSelected:d=false,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:s,hasDivider:i,isSelected:d,...R,className:c,children:[l&&jsx(l,{className:"mr-2 h-4.5 w-4.5 shrink-0 grow-0"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:s}),a&&jsx(Fragment,{children:a.isIcon?jsx(e$2,{...a,className:"ml-4 self-center",variant:"ghost",size:"sm",disabled:s??a.disabled}):jsx(e,{...a,className:"ml-4 self-center",size:"sm",variant:"ghost",disabled:s??a.disabled})})]});var Na=({title:e,description:t="",descriptionLines:o,hasDivider:n=false,disabled:r=false,checked:l,onCheckedChange:i,className:s,chipStatus:a,chipExpandable:d,...c})=>jsxs(te,{hasDescription:!!t,disabled:r,hasDivider:n,...c,className:a$1("pr-6",s),children:[jsx(c$5,{checked:l,onCheckedChange:i,className:"mr-4 self-center",disabled:r}),jsxs("div",{className:"flex-1",children:[jsxs("div",{className:"flex items-center justify-between gap-2",children:[jsx("p",{className:a$1("line-clamp-1 text-sm leading-[130%] break-all",!!t&&"font-medium"),children:e}),d&&jsx("div",{className:"ml-auto flex min-w-0 flex-shrink-0 items-center justify-end",children:jsx(c$6,{...d})}),a&&jsx("div",{className:"ml-4 flex shrink-0 items-center gap-1",children:jsx(d$3,{...a,size:"xs",className:"shrink-0"})})]}),t&&jsx("p",{className:a$1("text-xs leading-[130%]",r?"text-neutral-400":"text-neutral-700",{"line-clamp-1":o===1,"line-clamp-2":o===2,"line-clamp-3":o===3,"line-clamp-4":o===4}),children:t})]})]});var ct={paragraph:"m-0",ltr:"text-left",rtl:"text-right",heading:{h1:"mb-2 text-2xl leading-[130%] font-semibold text-neutral-900",h2:"mb-2 text-xl leading-[130%] font-semibold text-neutral-900",h3:"mb-2 text-lg leading-[130%] font-semibold text-neutral-900",h4:"mb-2 text-base leading-[130%] font-semibold text-neutral-900",h5:"mb-2 text-sm leading-[130%] font-semibold text-neutral-900",h6:"mb-2 text-xs leading-[130%] font-semibold text-neutral-900"},list:{ul:"my-2 list-disc pl-5",ol:"my-2 list-decimal pl-5",listitem:"my-1",nested:{listitem:"my-1"}},text:{bold:"font-semibold",italic:"italic",underline:"underline",strikethrough:"line-through",code:"rounded bg-neutral-100 px-1 py-0.5 font-mono text-xs"},code:"rounded bg-neutral-100 p-2 font-mono text-xs",quote:"border-l-2 border-neutral-300 pl-3 italic text-neutral-700",link:"text-primary-700 underline hover:text-primary-800"},pt={headings:["h1","h2","h3"],textFormat:["bold","italic","underline"],lists:true,indent:true,alignment:["left","center","right","justify"],undoRedo:true};var mt=({readOnly:e})=>{let[t]=useLexicalComposerContext();return useEffect(()=>{t.setEditable(!e);},[t,e]),null};var ut=({editorRef:e})=>{let[t]=useLexicalComposerContext();return useEffect(()=>(e.current=t,()=>{e.current===t&&(e.current=null);}),[t,e]),null};var Vn={"ql-align-left":"left","ql-align-center":"center","ql-align-right":"right","ql-align-justify":"justify"},Un={center:"ql-align-center",right:"ql-align-right",justify:"ql-align-justify"},$n=()=>typeof window<"u"&&typeof window.DOMParser<"u",co=e=>$n()?new DOMParser().parseFromString(e,"text/html"):null,Wn=e=>(e??"").replace(/\s+/g," ").trim(),ft=e=>{let t=0;for(let o of Array.from(e.classList)){let n=o.match(/^ql-indent-(\d+)$/);if(!n)continue;let r=Number.parseInt(n[1],10);Number.isFinite(r)&&(t=Math.max(t,r)),e.classList.remove(o);}return t},qn=e=>{let t=e.querySelectorAll("[class*='ql-align-']");for(let o of Array.from(t))for(let n of Array.from(o.classList)){let r=Vn[n];r&&(r!=="left"&&(o.style.textAlign=r),o.classList.remove(n));}},Gn=e=>{let t=e.querySelectorAll("[class*='ql-indent-']");for(let o of Array.from(t)){if(o.tagName==="LI")continue;let n=ft(o);n>0&&(o.style.paddingInlineStart=`${n*3}em`);}},jn=(e,t)=>{let o=e.getAttribute("data-list");return o==="bullet"?"ul":o==="ordered"?"ol":t},Kn=e=>{let t=e.cloneNode(true);return t.removeAttribute("data-list"),t.removeAttribute("data-checked"),t.removeAttribute("data-indent"),ft(t),t},dt=(e,t)=>e.createElement(t),Qn=(e,t)=>{let o=Array.from(e.children).filter(a=>a.tagName==="LI");if(o.length===0||!o.some(a=>a.hasAttribute("data-list")?true:Array.from(a.classList).some(d=>/^ql-indent-\d+$/.test(d))))return;let r=[],l=[],i=e.tagName==="UL"?"ul":"ol";for(let a of o){let d=ft(a),c=jn(a,i),R=Kn(a);for(;l.length>0&&l[l.length-1].level>d;)l.pop();if(l.length===0){let g=dt(t,c);r.push(g),l.push({level:0,kind:c,listElement:g});}let x=l[l.length-1];for(;x.level<d;){let g=x.listElement.lastElementChild;if(!g||g.tagName!=="LI")break;let u=dt(t,c);g.appendChild(u),x={level:x.level+1,kind:c,listElement:u},l.push(x);}if(x=l[l.length-1],x.kind!==c){let g=dt(t,c);if(l.length===1)r.push(g),l[0]={level:0,kind:c,listElement:g};else {let I=l[l.length-2].listElement.lastElementChild;I&&I.tagName==="LI"?(I.appendChild(g),l[l.length-1]={level:x.level,kind:c,listElement:g}):(r.push(g),l.length=1,l[0]={level:0,kind:c,listElement:g});}x=l[l.length-1];}x.listElement.appendChild(R);}if(r.length===0)return;let s=t.createDocumentFragment();for(let a of r)s.appendChild(a);e.replaceWith(s);},Yn=(e,t)=>{let o=Array.from(e.querySelectorAll("ol, ul"));for(let n of o)Qn(n,t);},po=(e,t)=>{let o=e.tagName==="UL"?"bullet":"ordered",n=Array.from(e.children).filter(r=>r.tagName==="LI");for(let r of n){r.setAttribute("data-list",o);for(let i of Array.from(r.classList))/^ql-indent-\d+$/.test(i)&&r.classList.remove(i);t>0&&r.classList.add(`ql-indent-${t}`);let l=Array.from(r.children).filter(i=>i.tagName==="UL"||i.tagName==="OL");for(let i of l)po(i,t+1);}},Xn=e=>{let t=e.querySelectorAll("p, h1, h2, h3, h4, h5, h6, li");for(let o of Array.from(t)){let n=o;for(let i of Array.from(n.classList))i.startsWith("ql-align-")&&n.classList.remove(i);let r=n.style.textAlign.trim().toLowerCase(),l=Un[r];l&&n.classList.add(l);}},ge=e=>Wn(e).replace(/>\s+</g,"><").replace(/&nbsp;/g," "),ht=e=>{let t=e??"";if(!t.trim())return "";let o=co(t);if(!o)return t;let{body:n}=o;return qn(n),Gn(n),Yn(n,o),n.innerHTML},bt=e=>{if(!e.trim())return "";let t=co(e);if(!t)return e;let{body:o}=t,n=Array.from(o.querySelectorAll("ul, ol"));for(let r of n)po(r,0);return Xn(o),o.innerHTML};var Xe=e=>{let t="";return e.getEditorState().read(()=>{t=$generateHtmlFromNodes(e,null);}),bt(t)},lr=(e,t)=>{let o=ht(t);e.update(()=>{let n=$getRoot();if(n.clear(),!o.trim()){n.append($createParagraphNode());return}let l=new DOMParser().parseFromString(o,"text/html"),i=$generateNodesFromDOM(e,l);if(i.length===0){n.append($createParagraphNode());return}n.select(),$insertNodes(i);});},gt=({value:e,isSyncingRef:t})=>{let[o]=useLexicalComposerContext(),n=useRef(null);return useEffect(()=>{let r=e??"";if(n.current!==null&&ge(r)===ge(n.current))return;let l=Xe(o);ge(l)!==ge(r)&&(t.current=true,lr(o,r),queueMicrotask(()=>{t.current=false;})),n.current=r;},[o,t,e]),null};var uo=["left","center","right","justify"];var fo=["bold","italic","underline","strikethrough","code"];var Vr={bold:"bold",italic:"italic",underline:"underline",strikethrough:"strikethrough",code:"code"},Ur={left:jsx(AlignLeftIcon,{className:"size-4"}),center:jsx(AlignCenterIcon,{className:"size-4"}),right:jsx(AlignRightIcon,{className:"size-4"}),justify:jsx(AlignJustifyIcon,{className:"size-4"})},$r={left:"Align left",center:"Align center",right:"Align right",justify:"Align justify"},Ae={bold:jsx(BoldIcon,{className:"size-4"}),italic:jsx(ItalicIcon,{className:"size-4"}),underline:jsx(UnderlineIcon,{className:"size-4"}),strikethrough:jsx("span",{className:"text-xs font-semibold",children:"S"}),code:jsx("span",{className:"font-mono text-xs",children:"</>"})},Me={bold:"Bold",italic:"Italic",underline:"Underline",strikethrough:"Strikethrough",code:"Inline code"},Wr=e=>{let t=e.textFormat;return t===false?[]:Array.isArray(t)?fo.filter(o=>t.includes(o)):["bold","italic","underline"]},qr=e=>{let t=e.alignment;return t===false?[]:Array.isArray(t)?uo.filter(o=>t.includes(o)):["left","center","right","justify"]},Gr=e=>{if(e.headings===false)return [];let t=Array.isArray(e.headings)?e.headings:["h1","h2","h3"];return [{value:"paragraph",label:"Normal"},...t.map(o=>({value:o,label:o.toUpperCase()}))]},Oe=()=>jsx("div",{className:"mx-1 h-5 w-px bg-neutral-300"}),G=({label:e,onClick:t,icon:o,active:n=false,disabled:r=false})=>jsx("button",{type:"button","aria-label":e,title:e,disabled:r,onClick:t,className:a$1("inline-flex size-8 items-center justify-center rounded-md border border-transparent text-neutral-700 transition-colors","focus-visible:ring-primary-800 hover:bg-neutral-200 focus-visible:ring-2 focus-visible:ring-offset-1 focus-visible:outline-none","disabled:cursor-not-allowed disabled:opacity-40",n&&"border-neutral-300 bg-neutral-200 text-neutral-900"),children:o}),Lt=({config:e,className:t})=>{let[o]=useLexicalComposerContext(),n=useId(),[r,l]=useState(false),[i,s]=useState(false),[a,d]=useState(false),[c,R]=useState(false),[x,g]=useState(false),[u,I]=useState(false),[P,L]=useState(false),[T,y]=useState("paragraph"),[N,b]=useState("left"),E=useMemo(()=>Wr(e),[e]),f=useMemo(()=>qr(e),[e]),C=useMemo(()=>Gr(e),[e]),_=useCallback(()=>{let m=$getSelection();if(!$isRangeSelection(m))return;d(m.hasFormat("bold")),R(m.hasFormat("italic")),g(m.hasFormat("underline")),I(m.hasFormat("strikethrough")),L(m.hasFormat("code"));let M=m.anchor.getNode(),w=M.getKey()==="root"?M:M.getTopLevelElementOrThrow();if($isListNode(w))y(w.getListType()==="number"?"ol":"ul");else {let $=$findMatchingParent(w,j=>$isListNode(j));$isListNode($)?y($.getListType()==="number"?"ol":"ul"):y($isHeadingNode(w)?w.getTag():w.getType());}let A=$isElementNode(w)?w.getFormatType():"";b(A==="center"||A==="right"||A==="justify"?A:"left");},[]);useEffect(()=>mergeRegister(o.registerUpdateListener(({editorState:m})=>{m.read(()=>{_();});}),o.registerCommand(SELECTION_CHANGE_COMMAND,()=>(_(),false),1),o.registerCommand(CAN_UNDO_COMMAND,m=>(l(m),false),1),o.registerCommand(CAN_REDO_COMMAND,m=>(s(m),false),1)),[o,_]);let F=m=>{o.dispatchCommand(FORMAT_TEXT_COMMAND,Vr[m]);},U=m=>{o.update(()=>{let M=$getSelection();if($isRangeSelection(M)){if(m==="paragraph"){$setBlocksType(M,()=>$createParagraphNode());return}$setBlocksType(M,()=>$createHeadingNode(m));}});},h=m=>{if(T===(m==="bullet"?"ul":"ol")){o.dispatchCommand(REMOVE_LIST_COMMAND,void 0);return}o.dispatchCommand(m==="bullet"?INSERT_UNORDERED_LIST_COMMAND:INSERT_ORDERED_LIST_COMMAND,void 0);};return jsxs("div",{className:a$1("flex flex-wrap items-center gap-1 border-b border-neutral-300 bg-neutral-100 px-2 py-1.5",t),children:[e.undoRedo!==false&&jsxs(Fragment,{children:[jsx(G,{label:"Undo",onClick:()=>o.dispatchCommand(UNDO_COMMAND,void 0),disabled:!r,icon:jsx(UndoIcon,{className:"size-4"})}),jsx(G,{label:"Redo",onClick:()=>o.dispatchCommand(REDO_COMMAND,void 0),disabled:!i,icon:jsx(RedoIcon,{className:"size-4"})}),jsx(Oe,{})]}),C.length>0&&jsxs(Fragment,{children:[jsx("label",{className:"sr-only",htmlFor:n,children:"Text style"}),jsx("select",{id:n,value:T.startsWith("h")?T:"paragraph",onChange:m=>U(m.target.value),className:a$1("h-8 rounded-md border border-neutral-300 bg-white px-2 text-xs font-medium text-neutral-800","focus-visible:ring-primary-800 focus-visible:ring-2 focus-visible:ring-offset-1 focus-visible:outline-none"),children:C.map(m=>jsx("option",{value:m.value,children:m.label},m.value))}),jsx(Oe,{})]}),E.length>0&&jsxs(Fragment,{children:[E.includes("bold")&&jsx(G,{label:Me.bold,onClick:()=>F("bold"),icon:Ae.bold,active:a}),E.includes("italic")&&jsx(G,{label:Me.italic,onClick:()=>F("italic"),icon:Ae.italic,active:c}),E.includes("underline")&&jsx(G,{label:Me.underline,onClick:()=>F("underline"),icon:Ae.underline,active:x}),E.includes("strikethrough")&&jsx(G,{label:Me.strikethrough,onClick:()=>F("strikethrough"),icon:Ae.strikethrough,active:u}),E.includes("code")&&jsx(G,{label:Me.code,onClick:()=>F("code"),icon:Ae.code,active:P}),jsx(Oe,{})]}),e.lists!==false&&jsxs(Fragment,{children:[jsx(G,{label:"Bulleted list",onClick:()=>h("bullet"),icon:jsx(ListIcon,{className:"size-4"}),active:T==="ul"}),jsx(G,{label:"Numbered list",onClick:()=>h("number"),icon:jsx(ListOrderedIcon,{className:"size-4"}),active:T==="ol"}),jsx(Oe,{})]}),e.indent!==false&&jsxs(Fragment,{children:[jsx(G,{label:"Decrease indent",onClick:()=>o.dispatchCommand(OUTDENT_CONTENT_COMMAND,void 0),icon:jsx(IndentDecreaseIcon,{className:"size-4"})}),jsx(G,{label:"Increase indent",onClick:()=>o.dispatchCommand(INDENT_CONTENT_COMMAND,void 0),icon:jsx(IndentIncreaseIcon,{className:"size-4"})}),jsx(Oe,{})]}),f.length>0&&jsx(Fragment,{children:f.map(m=>jsx(G,{label:$r[m],onClick:()=>o.dispatchCommand(FORMAT_ELEMENT_COMMAND,m),icon:Ur[m],active:N===m},m))})]})};var Co=e=>{if(e!==void 0)return typeof e=="number"?`${e}px`:e},sl=forwardRef(({value:e,onChange:t,onBlur:o,onError:n,placeholder:r="Write your content...",readOnly:l=false,showToolbar:i=true,toolbarConfig:s=pt,className:a,editorClassName:d,toolbarClassName:c,autoFocus:R=false,minHeight:x=160,maxHeight:g,error:u=false,errorMessage:I,editorRef:P},L)=>{let T=useRef(false),y=useMemo(()=>({namespace:"SodtrackRichTextEditor",theme:ct,onError:(b,E)=>{if(n){n(b,E);return}console.error("RichTextEditor error",b);},nodes:[HeadingNode,ListNode,ListItemNode]}),[n]),N={minHeight:Co(x),maxHeight:Co(g),overflowY:g?"auto":void 0};return jsx(LexicalComposer,{initialConfig:y,children:jsxs("div",{className:"w-full",children:[jsxs("div",{ref:L,className:a$1("group flex w-full flex-col overflow-hidden rounded-lg border bg-white transition-colors","focus-within:ring-primary-800 focus-within:ring-2 focus-within:ring-offset-0",u?"border-error-500 focus-within:border-error-500 focus-within:ring-error-500":"border-neutral-500",l&&"border-neutral-300 bg-neutral-50 focus-within:ring-0",a),"data-error":u,"data-readonly":l,children:[i&&!l&&jsx(Lt,{config:s,className:c}),jsx(RichTextPlugin,{contentEditable:jsx(ContentEditable,{className:a$1("relative w-full px-4 py-3 text-sm leading-[142%] text-neutral-900 outline-none","[&_h1]:mt-2 [&_h1]:mb-2 [&_h2]:mt-2 [&_h2]:mb-2 [&_h3]:mt-2 [&_h3]:mb-2","[&_li]:my-1 [&_ol]:my-2 [&_ul]:my-2","[&_a]:text-primary-700 [&_a]:underline",l&&"cursor-default",d),style:N,onBlur:o,"aria-invalid":u}),placeholder:l?null:jsx("div",{className:"pointer-events-none absolute top-3 left-4 text-sm text-neutral-500",children:r}),ErrorBoundary:LexicalErrorBoundary}),jsx(HistoryPlugin,{}),jsx(ListPlugin,{}),jsx(mt,{readOnly:l}),jsx(gt,{value:e,isSyncingRef:T}),R&&!l&&jsx(AutoFocusPlugin,{}),P&&jsx(ut,{editorRef:P}),jsx(OnChangePlugin,{ignoreSelectionChange:true,onChange:(b,E)=>{!t||T.current||t(Xe(E),b);}})]}),u&&I&&jsx("p",{className:"text-error-500 mt-1 text-xs leading-[133%]",children:I})]})})});sl.displayName="RichTextEditor";var Lo={en:Pn,es:En,pt:Nn},hl={es:{clearPhoneNumberLabel:"Eliminar n\xFAmero de tel\xE9fono",searchCountryPlaceholder:"Buscar..."},pt:{clearPhoneNumberLabel:"Limpar n\xFAmero de telefone",searchCountryPlaceholder:"Pesquisar..."}},bl={clearPhoneNumberLabel:"Clear phone number",searchCountryPlaceholder:"Search..."},gl=Lo.en,yo="9 1234 5678",yt="ZZ",Ro=()=>{},Io=e=>hl[e]??bl,vo=e=>Lo[e]??gl,To=e=>{if(e)try{let t=parsePhoneNumber(e)?.country;return !t||!h(t)?void 0:t}catch{return}},Po=e=>{if(e)return getExampleNumber(e,pl)?.formatNational()},Ze=e=>e??yt,Eo=()=>{let e=getDefaultOptions().locale?.code?.split("-")[0];return e==="es"||e==="pt"?e:"en"};var Il=({Icon:e,callingCode:t,country:o,countryName:n,callingCodeClassName:r})=>jsxs("div",{className:"flex justify-center gap-2",children:[jsx("span",{className:"flex size-4.5 shrink-0 items-center justify-center",children:jsx(e,{"aria-hidden":true,country:o,label:n})}),t&&jsx("span",{className:a$1("text-sm leading-[143%] font-medium text-neutral-800",r),children:`+${t}`})]}),No=({"aria-label":e,className:t,disabled:o,error:n,iconComponent:r,name:l,onBlur:i,onChange:s,onFocus:a$2,options:d,readOnly:c,translations:R,value:x})=>{let g=useFieldContext(),u=H.useRef(null),I=H.useId(),[P,L]=H.useState(""),{contains:T}=useFilter({sensitivity:"base"}),y=c$1({disabled:o,error:n,readOnly:c}),N=H.useMemo(()=>d.filter(h$1=>h$1.value!==void 0&&h(h$1.value)).map(h=>({callingCode:getCountryCallingCode(h.value),country:h.value,key:Ze(h.value),label:h.label})),[d]),b=H.useMemo(()=>N.find(h=>h.key===Ze(x)),[N,x]),{collection:E,filter:f,set:C}=useListCollection({initialItems:N,itemToString:h=>h.callingCode?`${h.label} +${h.callingCode}`:h.label,itemToValue:h=>h.key,filter:(h,m,M)=>{let w=m.trim().replace(/^\+/,"");return T(h,m)||(M.country?T(M.country,m.toUpperCase()):false)||(M.callingCode?T(M.callingCode,w)||T(`+${M.callingCode}`,m):false)}});H.useEffect(()=>{C(N);},[N,C]);let _=H.useCallback(({inputValue:h})=>{let m=h??"";L(m),f(m),u.current?.scrollTo({top:0});},[f]),F=H.useCallback(({open:h})=>{h&&(L(""),f(""));},[f]),U=H.useCallback(({value:h$1})=>{let m=h$1[0];if(!m||m===yt){s(void 0);return}h(m)&&s(m);},[s]);return jsxs(Combobox.Root,{className:"h-full shrink-0",collection:E,disabled:o||c,ids:{input:I,label:g.ids.label},inputBehavior:"autohighlight",inputValue:P,lazyMount:true,openOnChange:false,openOnClick:false,positioning:{placement:"bottom-end",offset:{mainAxis:12},sameWidth:false},selectionBehavior:"preserve",unmountOnExit:true,value:b?[b.key]:[],onInputValueChange:_,onOpenChange:F,onValueChange:U,children:[jsx(Combobox.Control,{className:"h-full",children:jsx(Combobox.Trigger,{"aria-label":e,className:a$1("relative flex h-full w-19.5 shrink-0 items-center justify-center rounded-l after:pointer-events-none after:absolute after:top-0 after:right-0 after:h-full after:w-px after:content-['']",y==="error"?"bg-danger-20 after:bg-input-ring-error":y==="disabled"||y==="readOnly"?"after:bg-input-ring-disabled bg-neutral-200":y==="errorReadOnly"?"after:bg-input-ring-error bg-neutral-200":"group-focus-within/phone:after:bg-input-ring-focus after:bg-input-ring data-[state=open]:after:bg-input-ring-focus bg-neutral-200",t),disabled:o||c,focusable:true,name:l,onBlur:i,onFocus:a$2,children:b&&jsx(Il,{Icon:r,callingCode:b.callingCode,country:b.country,countryName:b.label,callingCodeClassName:a$1(y==="error"&&"text-danger-600",(y==="disabled"||y==="readOnly"||y==="errorReadOnly")&&"text-input-text-disabled")})})}),jsx(Portal,{children:jsx(Combobox.Positioner,{children:jsxs(Combobox.Content,{className:"elevation-9 z-layer data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 w-75 origin-(--transform-origin) overflow-hidden rounded-sm bg-neutral-50",children:[jsxs("div",{className:"pb-0",children:[jsx(Combobox.Context,{children:h=>jsx(e$1,{className:"m-1 mb-0",size:"md",state:"default",clearAdornment:!o&&h.inputValue.length>0?jsx(a$5,{onClick:()=>{h.setInputValue("","clear-trigger");}}):void 0,indicator:jsx(q,{className:"pointer-events-none size-4.5 text-neutral-800"}),children:m=>jsx(Combobox.Input,{autoComplete:"off","data-1p-ignore":true,"data-lpignore":"true",placeholder:R.searchCountryPlaceholder,className:m})})}),jsx(a,{className:"mt-2"})]}),jsx(Combobox.List,{ref:u,className:a$1("h-72 overflow-auto outline-none",{"flex flex-col items-center justify-center":E.items.length===0}),children:E.items.length===0?jsx(a$8,{size:"sm",variant:"not-found"}):jsx(Combobox.ItemGroup,{children:E.items.map(h=>jsxs(Combobox.Item,{item:h,className:"data-highlighted:bg-primary-100 relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm text-neutral-900 outline-none select-none data-disabled:pointer-events-none data-disabled:opacity-50",children:[jsx("span",{className:"flex size-4.5 shrink-0 items-center justify-center [&_.PhoneInputCountryIconImg]:size-4.5!",children:jsx(r,{"aria-hidden":true,country:h.country,label:h.label})}),jsx(Combobox.ItemText,{className:"min-w-0 flex-1 truncate text-sm leading-[143%] font-medium",children:h.label}),h.callingCode&&jsx("span",{className:"shrink-0 text-sm text-neutral-600",children:`+${h.callingCode}`}),jsx(k,{className:a$1("ml-auto size-4 shrink-0",h.key===Ze(x)?"opacity-100":"opacity-0")})]},h.key))})})]})})})]})};var Tl=vl,Ao=H.forwardRef(({className:e,defaultCountry:t,disabled:o,error:n,helperText:r,id:l,label:i,labelProps:s,onChange:a=Ro,placeholder:d$1,readOnly:c,required:R,value:x,...g},u)=>{let[I,P]=H.useState(()=>To(x)??t),L=H.useRef(null),T=Eo(),y=c$1({disabled:o,error:n,readOnly:c}),N=H.useMemo(()=>Io(T),[T]),b=H.useMemo(()=>vo(T),[T]),E=H.useMemo(()=>Po(I)??d$1??yo,[d$1,I]),f=H.useCallback(F=>{P(F);},[]),C=H.useCallback(F=>{L.current=F,typeof u=="function"?u(F):u&&(u.current=F);},[u]),_=H.useCallback(()=>{a(void 0),L.current?.focus();},[a]);return jsxs(Field.Root,{"data-error":d(y)||void 0,disabled:o,id:l,invalid:n,readOnly:c,className:a$1(b$1,e),children:[i&&jsx(c$2,{...s,as:Field.Label,label:i,required:R}),jsx(e$1,{state:y,className:"group/phone pl-0 [&_.PhoneInputCountryIconImg]:size-4.5!",clearAdornment:x?jsx(a$5,{ariaLabel:N.clearPhoneNumberLabel,onClick:_}):void 0,children:F=>jsx(Tl,{...g,className:"contents",ref:C,countrySelectComponent:No,countrySelectProps:{error:n,translations:N},defaultCountry:t,disabled:o,flagComponent:a$7,initialValueFormat:"national",inputComponent:Field.Input,labels:b,numberInputProps:{"aria-required":R||void 0,className:a$1(F,"pl-3"),placeholder:E},readOnly:c,value:x,onChange:a,onCountryChange:f})}),r&&jsx(a$6,{as:n?Field.ErrorText:Field.HelperText,children:r})]})});Ao.displayName="PhoneInput";var El=({children:e,hasDescription:t=false,disabled:o=false,hasDivider:n=false,className:r,isSelected:l,onClick:i,...s})=>jsxs(Fragment,{children:[jsx("div",{className:a$1("flex flex-row px-3 py-4 text-neutral-900 transition-colors",t?"py-3":"py-3.5",o?"cursor-not-allowed text-neutral-400":a$1("hover:bg-primary-100 focus:bg-primary-200",!!i?"cursor-pointer":"cursor-default"),l&&"bg-primary-200",r),onClick:d=>{o||i?.(d);},...s,children:e}),n&&jsx(a,{})]}),te=El;var uu=({children:e,title:t,titleLines:o,description:n="",descriptionLines:r,startIcon:l,endIcon:i,hasDivider:s=false,disabled:a=false,isSelected:d=false,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:a,hasDivider:s,className:c,isSelected:d,...R,children:[l&&H__default.cloneElement(l,{className:"shrink-0 mr-2 h-4.5 w-4.5"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:a}),i&&H__default.cloneElement(i,{className:"min-h-4.5 min-w-4.5 self-center ml-4"})]});export{Jl as a,uu as b,mi as c,Li as d,Ns as e,ao as f,ga as g,Na as h,ct as i,pt as j,ge as k,ht as l,bt as m,sl as n,Ao as o};
1
+ import {a as a$3}from'./chunk-ORDWXBDZ.js';import {c as c$3,h}from'./chunk-XRFPQJ5P.js';import {a as a$7}from'./chunk-B5KKVXLE.js';import {c as c$6}from'./chunk-JYNJHAGL.js';import {b}from'./chunk-5B6ZOVKE.js';import {d as d$1}from'./chunk-WAUY2MS6.js';import {a as a$4,b as b$2,c as c$4,d as d$2}from'./chunk-NYURVOJI.js';import {c as c$5}from'./chunk-FYB3QRNL.js';import {a as a$8}from'./chunk-AKR7AIFQ.js';import {c as c$1,e as e$1,a as a$5,b as b$1,d}from'./chunk-MQL3NZ6S.js';import {a as a$6}from'./chunk-VIMWKUML.js';import {c as c$2}from'./chunk-QZUQ6AZK.js';import {d as d$3}from'./chunk-MP4CHZ2K.js';import {a as a$2}from'./chunk-R6NIURLZ.js';import {a}from'./chunk-AWRP67K4.js';import {e as e$2}from'./chunk-PI7DECIN.js';import {c,q,k,h as h$1}from'./chunk-QMPBFFFC.js';import {e}from'./chunk-WWQW5ZXG.js';import {a as a$1}from'./chunk-OBZIYJO7.js';import*as H from'react';import H__default,{createContext,useMemo,useCallback,forwardRef,useRef,useContext,useEffect,useId,useState}from'react';import*as Ht from'@radix-ui/react-portal';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {Field,useFieldContext}from'@ark-ui/react/field';import {useListCollection,Combobox}from'@ark-ui/react/combobox';import {useFilter}from'@ark-ui/react/locale';import {Portal}from'@ark-ui/react/portal';import {getDefaultOptions}from'date-fns';import Pn from'react-phone-number-input/locale/en.json';import En from'react-phone-number-input/locale/es.json';import Nn from'react-phone-number-input/locale/pt.json';import {LexicalComposer}from'@lexical/react/LexicalComposer';import {RichTextPlugin}from'@lexical/react/LexicalRichTextPlugin';import {ContentEditable}from'@lexical/react/LexicalContentEditable';import {HistoryPlugin}from'@lexical/react/LexicalHistoryPlugin';import {ListPlugin}from'@lexical/react/LexicalListPlugin';import {AutoFocusPlugin}from'@lexical/react/LexicalAutoFocusPlugin';import {OnChangePlugin}from'@lexical/react/LexicalOnChangePlugin';import {LexicalErrorBoundary}from'@lexical/react/LexicalErrorBoundary';import {HeadingNode,$isHeadingNode,$createHeadingNode}from'@lexical/rich-text';import {ListNode,ListItemNode,$isListNode,REMOVE_LIST_COMMAND,INSERT_UNORDERED_LIST_COMMAND,INSERT_ORDERED_LIST_COMMAND}from'@lexical/list';import {useLexicalComposerContext}from'@lexical/react/LexicalComposerContext';import {$generateHtmlFromNodes,$generateNodesFromDOM}from'@lexical/html';import {$getSelection,$isRangeSelection,$isElementNode,SELECTION_CHANGE_COMMAND,CAN_UNDO_COMMAND,CAN_REDO_COMMAND,UNDO_COMMAND,REDO_COMMAND,OUTDENT_CONTENT_COMMAND,INDENT_CONTENT_COMMAND,FORMAT_ELEMENT_COMMAND,$createParagraphNode,FORMAT_TEXT_COMMAND,$getRoot,$insertNodes}from'lexical';import {$setBlocksType}from'@lexical/selection';import {$findMatchingParent,mergeRegister}from'@lexical/utils';import {AlignJustifyIcon,AlignRightIcon,AlignCenterIcon,AlignLeftIcon,UnderlineIcon,ItalicIcon,BoldIcon,UndoIcon,RedoIcon,ListIcon,ListOrderedIcon,IndentDecreaseIcon,IndentIncreaseIcon}from'lucide-react';import vl,{parsePhoneNumber,getCountryCallingCode}from'react-phone-number-input';import {getExampleNumber}from'libphonenumber-js/mobile';import pl from'libphonenumber-js/mobile/examples';var wo=(e,t)=>{let o=useCallback(n=>{e.current&&!e.current.contains(n.target)&&t();},[]);useEffect(()=>(document.addEventListener("pointerdown",o),()=>{document.removeEventListener("pointerdown",o);}),[]);},Ge=wo;var Do=({title:e,titleLines:t=2,description:o,descriptionLines:n=1,Icon:r,iconAsColumn:l=true,className:i,...s})=>jsxs("div",{className:a$1("flex gap-2 py-4 pr-6 pl-4",l&&"flex-col items-center gap-1",!l&&!o&&"items-center",i),...s,children:[r&&jsx(r,{className:a$1("shrink-0 text-neutral-300"),size:24}),jsxs("div",{className:a$1("flex flex-col gap-1",l&&"text-center"),children:[jsx("p",{className:a$1("leading-[130%] text-neutral-500",!!o&&"font-medium"),style:t?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:t}:void 0,children:e}),o&&jsx("p",{className:"text-sm leading-[130%] text-neutral-500",style:n?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:n}:void 0,children:o})]})]}),je=Do;var So=H__default.memo(({handleSelect:e$1,NoResultsIcon:t,noResultsLabel:o,noResultsDescription:n,noResultsDescriptionLines:r,noResultsAsColumn:l,noResultsButtonOnClick:i,optionDescriptionLines:s,noResultsButtonLabel:a$2,filteredOptions:d,inputRect:c,inputRef:R,popoverPosition:x,optionsListRef:g,selectedOption:u,options:I,setFilteredOptions:P})=>jsx(Ht.Root,{asChild:true,children:jsxs("div",{ref:g,className:"elevation-8 pointer-events-auto fixed z-50 mb-2 hidden max-h-[336px] w-full flex-col overflow-y-auto rounded-lg bg-neutral-50",style:c?{width:`${c.width}px`,left:c.left,top:x==="bottom"?`${c.bottom}px`:void 0,bottom:x==="top"?`${window.innerHeight-c.top}px`:void 0}:void 0,children:[d.length===0&&jsxs("div",{className:"elevation-8 flex max-h-88 flex-1 flex-col justify-center rounded-lg bg-neutral-50",children:[jsx(je,{title:o,description:n,Icon:t,iconAsColumn:l,descriptionLines:r}),i&&jsxs(Fragment,{children:[jsx(a,{}),jsx(e,{variant:"ghost",className:"my-3 w-fit self-center",onClick:()=>{g.current.style.display="none",R.current.value="",P(I),i();},children:a$2})]})]}),d.map(L=>jsx(b.Root,{disabled:L.disabled,selected:u?.value===L.value,onClick:()=>e$1(L),children:jsxs(b.Content,{children:[jsx(b.Headline,{children:L.label}),L.description&&jsx(b.Description,{className:a$1({"line-clamp-1":s===1,"line-clamp-2":s===2,"line-clamp-3":s===3,"line-clamp-4":s===4}),children:L.description})]})},L.key??L.value))]})})),wt=So;var zo=336,Jl=({options:e,defaultSelectedOption:t,onSelect:o,onClick:n,onInputChange:r,error:l,helperText:i,label:s,placeholder:a,value:d,size:c="md",optionDescriptionLines:R=1,noResultsLabel:x,noResultsIcon:g,noResultsDescription:u,noResultsDescriptionLines:I,noResultsAsColumn:P,noResultsButtonOnClick:L,noResultsButtonLabel:T,className:y,disabled:N})=>{let[b,E]=useState(t??null),f=useRef(null),C=useRef(null),[_,F]=useState(),[U,h]=useState([]),[m,M]=useState("bottom"),[w,A]=useState(),$=zo,j=useCallback(D=>{f.current.style.display="none",C.current.value=D.label,E(D),o?.(D);},[o]),K=useCallback(()=>{if(!C?.current)return;let D=C.current.getBoundingClientRect();F(D);let Z=w?w.height:$,Q=window.innerHeight-D.bottom>Z,we=D.top>Z;M(Q?"bottom":we?"top":"bottom");},[w?.height]),Le=useCallback(()=>{let D=e.filter(Z=>Z.label.toLowerCase().includes(C?.current?.value.toLowerCase()??""));if(h(D),f?.current){let Z=f.current.getBoundingClientRect();A(Z);}},[e]);return useEffect(()=>{h(e);},[e]),useEffect(()=>{if(!d){E(null),C.current&&(C.current.value="");return}(!C.current?.value||b?.value!==d.value)&&(E(d),C.current.value=d.label);},[d]),Ge(f,()=>{f.current.style.display="none",b&&C.current&&(C.current.value=b.label);}),useEffect(()=>{if(C?.current)return K(),C.current.addEventListener("mousedown",K),C.current.addEventListener("input",Le),window.addEventListener("scroll",K,true),window.addEventListener("resize",K),()=>{C.current?.removeEventListener("mousedown",K),C.current?.removeEventListener("input",Le),window.removeEventListener("scroll",K,true),window.removeEventListener("resize",K);}},[K,Le]),jsxs("div",{className:a$1("relative",y),children:[jsx(a$3,{ref:C,autoComplete:"off",list:"",selectMode:true,onChange:D=>{D.target.value||(E(null),o?.(null)),r?.(D);},onClean:()=>{E(null),h(e),o?.(null);},onClick:D=>{f.current.style.display="flex",n?.(D);},onBlur:()=>{b&&C.current&&(C.current.value=b.label);},label:s,helperText:i,placeholder:a,size:c,error:l,disabled:N}),jsx(wt,{handleSelect:j,noResultsLabel:x,NoResultsIcon:g,optionDescriptionLines:R,noResultsAsColumn:P,noResultsButtonLabel:T,noResultsButtonOnClick:L,noResultsDescription:u,noResultsDescriptionLines:I,filteredOptions:U,inputRect:_,inputRef:C,popoverPosition:m,optionsListRef:f,selectedOption:b,options:e,setFilteredOptions:h})]})};var Uo=({children:e,title:t,titleLines:o,description:n="",descriptionLines:r,disabled:l=false,className:i,...s})=>jsxs("div",{className:a$1("flex w-full flex-col gap-1",i),...s,children:[jsx("p",{className:a$1("text-sm leading-[130%] break-all",!!n&&"font-medium"),style:o?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:o}:void 0,children:t}),n&&jsx("p",{className:a$1("text-xs leading-[130%]",l?"text-neutral-400":"text-neutral-700"),style:r?{overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:r}:void 0,children:n})]}),ce=Uo;var mi=({children:e,title:t,titleLines:o,description:n="",descriptionLines:r,startIcon:l,badgeContent:i,hasDivider:s=false,disabled:a=false,onSelect:d,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:a,onClick:d,hasDivider:s,className:a$1(!a&&"cursor-pointer",c),...R,children:[l&&H__default.cloneElement(l,{className:"shrink-0 mr-2 h-4.5 w-4.5"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:a}),jsxs("div",{className:"ml-4 flex gap-2",children:[i&&jsx(a$2,{content:i,size:"lg",variant:"alert",className:a$1("self-center",a&&"bg-neutral-400")}),jsx(h$1,{className:"h-4.5 w-4.5 self-center"})]})]});var Li=({children:e,title:t,titleLines:o=1,description:n="",descriptionLines:r,startIcon:l,hasDivider:i=false,disabled:s=false,checked:a,onCheckedChange:d,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:s,hasDivider:i,...R,className:a$1("pr-6",c),children:[l&&H__default.cloneElement(l,{className:"shrink-0 w-4.5 h-4.5 mr-2"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:s}),jsx(c$5,{checked:a,onCheckedChange:d,className:"ml-4 self-center",disabled:s})]});var ne=336,Ut=createContext({inputRef:null,optionsListRef:null,autocompleteId:"",inputRect:void 0,showChips:false,filteredOptions:[],currentFocus:-1,popoverPosition:"bottom",setFilteredOptions:()=>{},setCurrentFocus:()=>{},setShowChips:()=>{},setPopoverPosition:()=>{},setInputRect:()=>{},optionsListHeight:ne,setOptionsListHeight:()=>{},optionsListRect:void 0,setOptionsListRect:()=>{}}),oe=()=>{let e=useContext(Ut);if(e===null)throw new Error("useAutocompleteMultipleContext must be used within a AutocompleteMultipleProvider");return e},$t=({children:e})=>{let t=useRef(null),o=useRef(null),n=useId(),[r,l]=useState(),[i,s]=useState(true),[a,d]=useState([]),[c,R]=useState(-1),[x,g]=useState("bottom"),[u,I]=useState(),[P,L]=useState(ne);return jsx(Ut.Provider,{value:{optionsListRef:t,inputRef:o,autocompleteId:n,inputRect:r,showChips:i,filteredOptions:a,currentFocus:c,popoverPosition:x,setFilteredOptions:d,setCurrentFocus:R,setShowChips:s,setPopoverPosition:g,setInputRect:l,optionsListHeight:P,optionsListRect:u,setOptionsListRect:I,setOptionsListHeight:L},children:e})};var Jo=({option:e,onMountWidth:t})=>{let o=useRef(null);return useEffect(()=>{o.current&&t?.(o.current.clientWidth);},[]),jsx(d$1,{variant:"fill",color:"neutral",ref:o,className:"shrink-0",size:"md",hasCloseIcon:false,children:e.label})},Wt=Jo;var nn=150,rn=H__default.memo(({selectedOptions:e,error:t,onCleanSelectedOptions:o,disabled:n,size:r})=>{let{autocompleteId:l,inputRect:i,inputRef:s,optionsListRef:a}=oe(),d=H__default.useRef(null),[c$1,R]=H__default.useState(new Map),x=useMemo(()=>{if(!i?.width)return [];let u=0,I=i.width-nn,P=0;for(let L=0;L<e.length&&(P+=c$1.get(L)??0,!(P>I));L++)u++;return e.slice(0,u)},[i?.width,e,c$1]),g=useCallback(()=>{n||(s?.current?.focus(),a.current.style.display="flex");},[n]);return jsxs("div",{onClick:g,className:a$1("absolute top-0 z-30 flex w-full cursor-pointer flex-nowrap items-center gap-2 pr-12 pl-3",n&&"cursor-not-allowed"),style:{maxWidth:i?.width?i?.width:void 0,height:i?.height?i?.height:void 0},children:[jsx("div",{className:"flex flex-1 gap-1 overflow-hidden",ref:d,children:x.map((u,I)=>jsx(Wt,{option:u,onMountWidth:P=>R(L=>new Map(L).set(I,P))},`chip-input-${l}-${u.value}`))}),e.length>x.length&&jsx("span",{className:"text-base",children:"..."}),e.length>0&&!t&&jsx(a$2,{content:String(e.length),size:r}),t&&e.length>0&&jsx(c,{className:"text-error-700 h-6 w-6",onClick:u=>{u.stopPropagation(),o();}})]})}),qt=rn;var an=H__default.memo(({option:e,index:t,onPressOption:o,isSelected:n,optionDescriptionLines:r})=>{let{currentFocus:l,inputRef:i}=oe();return jsxs(b.Root,{selected:l===t,disabled:e.disabled,onMouseDown:s=>{e.disabled||(i?.current?.value&&s.preventDefault(),o?.(e,s));},children:[jsxs(b.Content,{children:[jsx(b.Headline,{children:e.label}),e.description&&jsx(b.Description,{className:a$1({"line-clamp-1":r===1,"line-clamp-2":r===2,"line-clamp-3":r===3,"line-clamp-4":r===4}),children:e.description})]}),jsx(b.Trailing,{children:jsx(b.CheckboxControl,{checked:n})})]})}),rt=an;var un=H__default.memo(({selectedOptions:e$1,handleSelect:t,NoResultsIcon:o,noResultsLabel:n,noResultsDescription:r,noResultsDescriptionLines:l,noResultsAsColumn:i,noResultsButtonOnClick:s,optionDescriptionLines:a$1,noResultsButtonLabel:d})=>{let{popoverPosition:c,optionsListRef:R,filteredOptions:x,inputRect:g,autocompleteId:u,inputRef:I,optionsListHeight:P}=oe(),L=useCallback(y=>e$1.some(N=>N.value===y.value),[e$1]),T=useMemo(()=>e$1.filter(y=>y.label.toLowerCase().includes(I?.current?.value.toLowerCase()??"")),[e$1,I?.current?.value]);return jsx(Ht.Root,{asChild:true,children:jsxs("div",{ref:R,className:"elevation-8 pointer-events-auto fixed z-50 mb-2 hidden w-full flex-col overflow-y-auto rounded-lg bg-neutral-50",style:g?{width:`${g.width}px`,left:g.left,top:c==="bottom"?`${g.bottom}px`:void 0,bottom:c==="top"?`${window.innerHeight-g.top}px`:void 0,maxHeight:P+"px"}:void 0,children:[x.length===0&&jsxs("div",{className:"elevation-8 flex max-h-88 flex-1 flex-col justify-center rounded-lg bg-neutral-50",children:[jsx(je,{title:n,description:r,Icon:o,iconAsColumn:i,descriptionLines:l}),s&&jsxs(Fragment,{children:[jsx(a,{}),jsx(e,{variant:"ghost",className:"my-3 w-fit self-center",onClick:()=>{R.current.style.display="none",I.current.value="",s();},children:d})]})]}),T.map((y,N)=>jsx(rt,{option:y,index:N,onPressOption:b=>t(b),isSelected:L(y),optionDescriptionLines:a$1},`autocomplete-option-${u}-${y.key??y.value}`)),x.map((y,N)=>!e$1.some(b=>b.value===y.value)&&jsx(rt,{option:y,index:N,onPressOption:b=>t(b),isSelected:L(y),optionDescriptionLines:a$1},`autocomplete-option-${u}-${y.key??y.value}`))]})})}),Kt=un;var hn=H__default.memo(({selectedOptions:e,onSelect:t,error:o,helperText:n,label:r,placeholder:l,options:i,onInputChange:s,size:a,disabled:d})=>{let{setCurrentFocus:c,setFilteredOptions:R,optionsListRef:x,inputRef:g}=oe();return jsx(a$3,{ref:g,autoComplete:"off",list:"",disabled:d,selectMode:true,onChange:u=>{c(-1),s?.(u.target.value);},onClean:()=>{c(-1),R(i),t?.(null,e);},onClick:()=>{d||(x.current.style.display="flex");},error:o,helperText:n,label:r,placeholder:l,fixedTopLabel:e.length>0,size:a})}),Qt=hn;var Yt=({options:e,defaultSelectedOptions:t,onSelect:o,error:n,helperText:r,label:l,placeholder:i,noResultsLabel:s,noResultsIcon:a,noResultsDescription:d,noResultsDescriptionLines:c,noResultsAsColumn:R,noResultsButtonOnClick:x,noResultsButtonLabel:g,className:u,onInputChange:I,value:P,loading:L,size:T="md",optionDescriptionLines:y=1,disabled:N})=>{let{inputRef:b,optionsListRef:E,setFilteredOptions:f,setShowChips:C,setInputRect:_,setPopoverPosition:F,setCurrentFocus:U,showChips:h,setOptionsListRect:m,optionsListRect:M,setOptionsListHeight:w}=oe(),A=useRef(false),[$,j]=useState(t??[]),K=useCallback(W=>{j(J=>{let le,ye=J.findIndex(Fo=>Fo.value===W.value);return ye===-1?(le=J.concat(W),o?.(W,le),le):(le=J.toSpliced(ye,1),o?.(W,le),le)});},[o]),Le=useCallback(()=>{j([]),f(e),o?.(null,[]);},[]),D=useCallback(()=>{C(false);},[]),Z=useCallback(()=>{C(true);},[]),Q=useCallback(()=>{if(!b?.current)return;let W=b.current.getBoundingClientRect();_(W);let J=M?M.height>ne?ne:M.height:ne,le=window.innerHeight-W.bottom>J,ye=W.top>J;F(le?"bottom":ye?"top":"bottom"),w(ye?ne:window.innerHeight-W.bottom>ne?ne:window.innerHeight-W.bottom);},[M?.height]),we=useCallback(()=>{let W=e.filter(J=>J.label.toLowerCase().includes(b?.current?.value.toLowerCase()??""));if(f(W),E?.current){let J=E.current.getBoundingClientRect();m(J);}},[e,E?.current]);return useEffect(()=>{f(e);},[e]),Ge(E,()=>{E.current.style.display="none",U(-1);}),useEffect(()=>{if(b?.current)return Q(),b.current.addEventListener("mousedown",Q),b.current.addEventListener("input",we),b.current.addEventListener("focusin",D),b.current.addEventListener("focusout",Z),window.addEventListener("scroll",Q,true),window.addEventListener("resize",Q),()=>{b.current?.removeEventListener("mousedown",Q),b.current?.removeEventListener("input",Q),b.current?.removeEventListener("focusout",Z),b.current?.removeEventListener("focusin",D),window.removeEventListener("scroll",Q,true),window.removeEventListener("resize",Q);}},[Q,Z,D,we]),useEffect(()=>{P&&(j(P),C(true));},[P]),useEffect(()=>{L||t&&t.length&&!A.current&&(j(t),A.current=true,C(true));},[t,L]),jsxs("div",{className:a$1("relative",u),children:[jsx(Qt,{selectedOptions:$,onSelect:o,error:n,helperText:r,label:l,placeholder:i,handleSelect:K,options:e,onInputChange:I,size:T,disabled:N}),h&&jsx(qt,{selectedOptions:$,disabled:N,error:n,onCleanSelectedOptions:Le,size:T}),jsx(Kt,{handleSelect:K,selectedOptions:$,noResultsLabel:s,NoResultsIcon:a,optionDescriptionLines:y,noResultsAsColumn:R,noResultsButtonLabel:g,noResultsButtonOnClick:x,noResultsDescription:d,noResultsDescriptionLines:c})]})};var Ns=e=>jsx($t,{children:jsx(Yt,{...e})});var vn=({code:e,codeClassName:t})=>jsxs("div",{className:"flex justify-center gap-2",children:[jsx(a$7,{country:e,className:"size-4.5"}),jsx("span",{className:a$1("text-sm leading-[143%] font-medium text-neutral-800",t),children:e})]}),Zt=({className:e,disabled:t,error:o,onChange:n,options:r,readOnly:l,translations:i,value:s})=>{let a$2=useFieldContext(),d=H.useRef(null),c=H.useId(),[R,x]=H.useState(""),{contains:g}=useFilter({sensitivity:"base"}),u=c$1({disabled:t,error:o,readOnly:l}),I=H.useMemo(()=>r.map(f=>({...f,key:f.code})),[r]),P=H.useMemo(()=>I.find(f=>f.key===s),[I,s]),{collection:L,filter:T,set:y}=useListCollection({initialItems:I,itemToString:f=>`${f.label} ${f.code}`,itemToValue:f=>f.key,filter:(f,C,_)=>g(f,C)||g(_.code,C.toUpperCase())});H.useEffect(()=>{y(I);},[I,y]);let N=H.useCallback(({inputValue:f})=>{let C=f??"";x(C),T(C),d.current?.scrollTo({top:0});},[T]),b=H.useCallback(({open:f})=>{f&&(x(""),T(""));},[T]),E=H.useCallback(({items:f})=>{let C=f[0]?.code;C&&n(C);},[n]);return jsxs(Combobox.Root,{className:"h-full shrink-0",collection:L,disabled:t||l,ids:{input:c,label:a$2.ids.label},inputBehavior:"autohighlight",inputValue:R,lazyMount:true,openOnChange:false,openOnClick:false,positioning:{placement:"bottom-end",offset:{mainAxis:12},sameWidth:false},selectionBehavior:"preserve",unmountOnExit:true,value:P?[P.key]:[],onInputValueChange:N,onOpenChange:b,onValueChange:E,children:[jsx(Combobox.Control,{className:"h-full",children:jsx(Combobox.Trigger,{className:a$1("relative flex h-full w-19.5 shrink-0 items-center justify-center rounded-l after:pointer-events-none after:absolute after:top-0 after:right-0 after:h-full after:w-px after:content-['']",u==="error"?"bg-danger-20 after:bg-input-ring-error":u==="disabled"||u==="readOnly"?"after:bg-input-ring-disabled bg-neutral-200":u==="errorReadOnly"?"after:bg-input-ring-error bg-neutral-200":"group-focus-within/id-field:after:bg-input-ring-focus after:bg-input-ring data-[state=open]:after:bg-input-ring-focus bg-neutral-200",e),disabled:t||l,focusable:true,children:P&&jsx(vn,{code:P.code,codeClassName:a$1(u==="error"&&"text-danger-600",(u==="disabled"||u==="readOnly"||u==="errorReadOnly")&&"text-input-text-disabled")})})}),jsx(Portal,{children:jsx(Combobox.Positioner,{children:jsxs(Combobox.Content,{className:"elevation-9 z-layer data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 w-75 origin-(--transform-origin) overflow-hidden rounded-sm bg-neutral-50",children:[jsxs("div",{className:"pb-0",children:[jsx(Combobox.Context,{children:f=>jsx(e$1,{className:"m-1 mb-0",size:"md",state:"default",clearAdornment:!t&&f.inputValue.length>0?jsx(a$5,{onClick:()=>{f.setInputValue("","clear-trigger");}}):void 0,indicator:jsx(q,{className:"pointer-events-none size-4.5 text-neutral-800"}),children:C=>jsx(Combobox.Input,{autoComplete:"off","data-1p-ignore":true,"data-lpignore":"true",placeholder:i.searchCountryPlaceholder,className:C})})}),jsx(a,{className:"mt-2"})]}),jsx(Combobox.List,{ref:d,className:a$1("h-72 overflow-auto outline-none",{"flex flex-col items-center justify-center":L.items.length===0}),children:L.items.length===0?jsx(a$8,{size:"sm",variant:"not-found"}):jsx(Combobox.ItemGroup,{children:L.items.map(f=>jsxs(Combobox.Item,{item:f,className:"data-highlighted:bg-primary-100 relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm text-neutral-900 outline-none select-none data-disabled:pointer-events-none data-disabled:opacity-50",children:[jsx(a$7,{country:f.code,className:"size-4.5"}),jsx(Combobox.ItemText,{className:"min-w-0 flex-1 truncate text-sm leading-[143%] font-medium",children:f.label}),jsx("span",{className:"shrink-0 text-sm text-neutral-600",children:f.code}),jsx(k,{className:a$1("ml-auto size-4 shrink-0",f.key===s?"opacity-100":"opacity-0")})]},f.key))})})]})})})]})};var st={en:"Clear identification number",es:"Limpiar n\xFAmero de identificaci\xF3n",pt:"Limpar n\xFAmero de identifica\xE7\xE3o"},Jt={en:Pn,es:En,pt:Nn},An=st.en,Mn=Jt.en,On={es:{clearIdLabel:st.es,searchCountryPlaceholder:"Buscar..."},pt:{clearIdLabel:st.pt,searchCountryPlaceholder:"Pesquisar..."}},Fn={clearIdLabel:An,searchCountryPlaceholder:"Search..."},eo=()=>{let e=getDefaultOptions().locale?.code?.split("-")[0];return e==="es"||e==="pt"?e:"en"},to=e=>On[e]??Fn,kn=(e,t)=>(Jt[t]??Mn)[e]??e,oo=({localeCode:e})=>c$3.map(t=>({code:t,label:kn(t,e)})).sort((t,o)=>t.label.localeCompare(o.label)),no=a$4,ro=b$2,lo=(e,t)=>{let o=t.trim();return !o||!c$4(e,o).isValid?o:d$2(e,o)};var io=()=>{},ao=H.forwardRef(({autoComplete:e,className:t,country:o,disabled:n,error:r,helperText:l,id:i,label:s,labelProps:a,name:d$1,onBlur:c,onChange:R=io,onCountryChange:x=io,placeholder:g,readOnly:u,required:I,value:P},L)=>{let[T,y]=H.useState(P??""),N=H.useRef(null),b=eo(),E=H.useRef(P??""),f=c$1({disabled:n,error:r,readOnly:u});H.useEffect(()=>{let A=P??"";A!==E.current&&(E.current=A,y(A));},[P]);let C=H.useMemo(()=>to(b),[b]),_=H.useMemo(()=>oo({localeCode:b}),[b]),F=H.useMemo(()=>ro(o??"")||g||no,[o,g]),U=H.useCallback((A,$)=>{let j=lo(A,$);E.current=j,R(j);},[R]),h=H.useCallback(A=>{y(A),U(o??"",A);},[o,U]),m=H.useCallback(A=>{x(A),U(A,T);},[T,x,U]),M=H.useCallback(A=>{N.current=A,typeof L=="function"?L(A):L&&(L.current=A);},[L]),w=H.useCallback(()=>{h(""),N.current?.focus();},[h]);return jsxs(Field.Root,{"data-error":d(f)||void 0,disabled:n,id:i,invalid:r,readOnly:u,className:a$1(b$1,t),children:[s&&jsx(c$2,{...a,as:Field.Label,label:s,required:I}),jsx(e$1,{state:f,className:"group/id-field pl-0",clearAdornment:T?jsx(a$5,{ariaLabel:C.clearIdLabel,onClick:w}):void 0,children:A=>jsxs(Fragment,{children:[jsx(Zt,{disabled:n,error:r,onChange:m,options:_,readOnly:u,translations:C,value:o}),jsx(Field.Input,{"aria-required":I||void 0,autoComplete:e,className:a$1(A,"pl-3"),name:d$1,onBlur:c,onChange:$=>h($.target.value),placeholder:F,value:T,ref:M})]})}),l&&jsx(a$6,{as:r?Field.ErrorText:Field.HelperText,children:l})]})});ao.displayName="IdField";var ga=({children:e$1,title:t,titleLines:o=1,description:n,descriptionLines:r=1,StartIcon:l,hasDivider:i=false,disabled:s=false,actionButton:a,isSelected:d=false,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:s,hasDivider:i,isSelected:d,...R,className:c,children:[l&&jsx(l,{className:"mr-2 h-4.5 w-4.5 shrink-0 grow-0"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:s}),a&&jsx(Fragment,{children:a.isIcon?jsx(e$2,{...a,className:"ml-4 self-center",variant:"ghost",size:"sm",disabled:s??a.disabled}):jsx(e,{...a,className:"ml-4 self-center",size:"sm",variant:"ghost",disabled:s??a.disabled})})]});var Na=({title:e,description:t="",descriptionLines:o,hasDivider:n=false,disabled:r=false,checked:l,onCheckedChange:i,className:s,chipStatus:a,chipExpandable:d,...c})=>jsxs(te,{hasDescription:!!t,disabled:r,hasDivider:n,...c,className:a$1("pr-6",s),children:[jsx(c$5,{checked:l,onCheckedChange:i,className:"mr-4 self-center",disabled:r}),jsxs("div",{className:"flex-1",children:[jsxs("div",{className:"flex items-center justify-between gap-2",children:[jsx("p",{className:a$1("line-clamp-1 text-sm leading-[130%] break-all",!!t&&"font-medium"),children:e}),d&&jsx("div",{className:"ml-auto flex min-w-0 flex-shrink-0 items-center justify-end",children:jsx(c$6,{...d})}),a&&jsx("div",{className:"ml-4 flex shrink-0 items-center gap-1",children:jsx(d$3,{...a,size:"xs",className:"shrink-0"})})]}),t&&jsx("p",{className:a$1("text-xs leading-[130%]",r?"text-neutral-400":"text-neutral-700",{"line-clamp-1":o===1,"line-clamp-2":o===2,"line-clamp-3":o===3,"line-clamp-4":o===4}),children:t})]})]});var ct={paragraph:"m-0",ltr:"text-left",rtl:"text-right",heading:{h1:"mb-2 text-2xl leading-[130%] font-semibold text-neutral-900",h2:"mb-2 text-xl leading-[130%] font-semibold text-neutral-900",h3:"mb-2 text-lg leading-[130%] font-semibold text-neutral-900",h4:"mb-2 text-base leading-[130%] font-semibold text-neutral-900",h5:"mb-2 text-sm leading-[130%] font-semibold text-neutral-900",h6:"mb-2 text-xs leading-[130%] font-semibold text-neutral-900"},list:{ul:"my-2 list-disc pl-5",ol:"my-2 list-decimal pl-5",listitem:"my-1",nested:{listitem:"my-1"}},text:{bold:"font-semibold",italic:"italic",underline:"underline",strikethrough:"line-through",code:"rounded bg-neutral-100 px-1 py-0.5 font-mono text-xs"},code:"rounded bg-neutral-100 p-2 font-mono text-xs",quote:"border-l-2 border-neutral-300 pl-3 italic text-neutral-700",link:"text-primary-700 underline hover:text-primary-800"},pt={headings:["h1","h2","h3"],textFormat:["bold","italic","underline"],lists:true,indent:true,alignment:["left","center","right","justify"],undoRedo:true};var mt=({readOnly:e})=>{let[t]=useLexicalComposerContext();return useEffect(()=>{t.setEditable(!e);},[t,e]),null};var ut=({editorRef:e})=>{let[t]=useLexicalComposerContext();return useEffect(()=>(e.current=t,()=>{e.current===t&&(e.current=null);}),[t,e]),null};var Vn={"ql-align-left":"left","ql-align-center":"center","ql-align-right":"right","ql-align-justify":"justify"},Un={center:"ql-align-center",right:"ql-align-right",justify:"ql-align-justify"},$n=()=>typeof window<"u"&&typeof window.DOMParser<"u",co=e=>$n()?new DOMParser().parseFromString(e,"text/html"):null,Wn=e=>(e??"").replace(/\s+/g," ").trim(),ft=e=>{let t=0;for(let o of Array.from(e.classList)){let n=o.match(/^ql-indent-(\d+)$/);if(!n)continue;let r=Number.parseInt(n[1],10);Number.isFinite(r)&&(t=Math.max(t,r)),e.classList.remove(o);}return t},qn=e=>{let t=e.querySelectorAll("[class*='ql-align-']");for(let o of Array.from(t))for(let n of Array.from(o.classList)){let r=Vn[n];r&&(r!=="left"&&(o.style.textAlign=r),o.classList.remove(n));}},Gn=e=>{let t=e.querySelectorAll("[class*='ql-indent-']");for(let o of Array.from(t)){if(o.tagName==="LI")continue;let n=ft(o);n>0&&(o.style.paddingInlineStart=`${n*3}em`);}},jn=(e,t)=>{let o=e.getAttribute("data-list");return o==="bullet"?"ul":o==="ordered"?"ol":t},Kn=e=>{let t=e.cloneNode(true);return t.removeAttribute("data-list"),t.removeAttribute("data-checked"),t.removeAttribute("data-indent"),ft(t),t},dt=(e,t)=>e.createElement(t),Qn=(e,t)=>{let o=Array.from(e.children).filter(a=>a.tagName==="LI");if(o.length===0||!o.some(a=>a.hasAttribute("data-list")?true:Array.from(a.classList).some(d=>/^ql-indent-\d+$/.test(d))))return;let r=[],l=[],i=e.tagName==="UL"?"ul":"ol";for(let a of o){let d=ft(a),c=jn(a,i),R=Kn(a);for(;l.length>0&&l[l.length-1].level>d;)l.pop();if(l.length===0){let g=dt(t,c);r.push(g),l.push({level:0,kind:c,listElement:g});}let x=l[l.length-1];for(;x.level<d;){let g=x.listElement.lastElementChild;if(!g||g.tagName!=="LI")break;let u=dt(t,c);g.appendChild(u),x={level:x.level+1,kind:c,listElement:u},l.push(x);}if(x=l[l.length-1],x.kind!==c){let g=dt(t,c);if(l.length===1)r.push(g),l[0]={level:0,kind:c,listElement:g};else {let I=l[l.length-2].listElement.lastElementChild;I&&I.tagName==="LI"?(I.appendChild(g),l[l.length-1]={level:x.level,kind:c,listElement:g}):(r.push(g),l.length=1,l[0]={level:0,kind:c,listElement:g});}x=l[l.length-1];}x.listElement.appendChild(R);}if(r.length===0)return;let s=t.createDocumentFragment();for(let a of r)s.appendChild(a);e.replaceWith(s);},Yn=(e,t)=>{let o=Array.from(e.querySelectorAll("ol, ul"));for(let n of o)Qn(n,t);},po=(e,t)=>{let o=e.tagName==="UL"?"bullet":"ordered",n=Array.from(e.children).filter(r=>r.tagName==="LI");for(let r of n){r.setAttribute("data-list",o);for(let i of Array.from(r.classList))/^ql-indent-\d+$/.test(i)&&r.classList.remove(i);t>0&&r.classList.add(`ql-indent-${t}`);let l=Array.from(r.children).filter(i=>i.tagName==="UL"||i.tagName==="OL");for(let i of l)po(i,t+1);}},Xn=e=>{let t=e.querySelectorAll("p, h1, h2, h3, h4, h5, h6, li");for(let o of Array.from(t)){let n=o;for(let i of Array.from(n.classList))i.startsWith("ql-align-")&&n.classList.remove(i);let r=n.style.textAlign.trim().toLowerCase(),l=Un[r];l&&n.classList.add(l);}},ge=e=>Wn(e).replace(/>\s+</g,"><").replace(/&nbsp;/g," "),ht=e=>{let t=e??"";if(!t.trim())return "";let o=co(t);if(!o)return t;let{body:n}=o;return qn(n),Gn(n),Yn(n,o),n.innerHTML},bt=e=>{if(!e.trim())return "";let t=co(e);if(!t)return e;let{body:o}=t,n=Array.from(o.querySelectorAll("ul, ol"));for(let r of n)po(r,0);return Xn(o),o.innerHTML};var Xe=e=>{let t="";return e.getEditorState().read(()=>{t=$generateHtmlFromNodes(e,null);}),bt(t)},lr=(e,t)=>{let o=ht(t);e.update(()=>{let n=$getRoot();if(n.clear(),!o.trim()){n.append($createParagraphNode());return}let l=new DOMParser().parseFromString(o,"text/html"),i=$generateNodesFromDOM(e,l);if(i.length===0){n.append($createParagraphNode());return}n.select(),$insertNodes(i);});},gt=({value:e,isSyncingRef:t})=>{let[o]=useLexicalComposerContext(),n=useRef(null);return useEffect(()=>{let r=e??"";if(n.current!==null&&ge(r)===ge(n.current))return;let l=Xe(o);ge(l)!==ge(r)&&(t.current=true,lr(o,r),queueMicrotask(()=>{t.current=false;})),n.current=r;},[o,t,e]),null};var uo=["left","center","right","justify"];var fo=["bold","italic","underline","strikethrough","code"];var Vr={bold:"bold",italic:"italic",underline:"underline",strikethrough:"strikethrough",code:"code"},Ur={left:jsx(AlignLeftIcon,{className:"size-4"}),center:jsx(AlignCenterIcon,{className:"size-4"}),right:jsx(AlignRightIcon,{className:"size-4"}),justify:jsx(AlignJustifyIcon,{className:"size-4"})},$r={left:"Align left",center:"Align center",right:"Align right",justify:"Align justify"},Ae={bold:jsx(BoldIcon,{className:"size-4"}),italic:jsx(ItalicIcon,{className:"size-4"}),underline:jsx(UnderlineIcon,{className:"size-4"}),strikethrough:jsx("span",{className:"text-xs font-semibold",children:"S"}),code:jsx("span",{className:"font-mono text-xs",children:"</>"})},Me={bold:"Bold",italic:"Italic",underline:"Underline",strikethrough:"Strikethrough",code:"Inline code"},Wr=e=>{let t=e.textFormat;return t===false?[]:Array.isArray(t)?fo.filter(o=>t.includes(o)):["bold","italic","underline"]},qr=e=>{let t=e.alignment;return t===false?[]:Array.isArray(t)?uo.filter(o=>t.includes(o)):["left","center","right","justify"]},Gr=e=>{if(e.headings===false)return [];let t=Array.isArray(e.headings)?e.headings:["h1","h2","h3"];return [{value:"paragraph",label:"Normal"},...t.map(o=>({value:o,label:o.toUpperCase()}))]},Oe=()=>jsx("div",{className:"mx-1 h-5 w-px bg-neutral-300"}),G=({label:e,onClick:t,icon:o,active:n=false,disabled:r=false})=>jsx("button",{type:"button","aria-label":e,title:e,disabled:r,onClick:t,className:a$1("inline-flex size-8 items-center justify-center rounded-md border border-transparent text-neutral-700 transition-colors","focus-visible:ring-primary-800 hover:bg-neutral-200 focus-visible:ring-2 focus-visible:ring-offset-1 focus-visible:outline-none","disabled:cursor-not-allowed disabled:opacity-40",n&&"border-neutral-300 bg-neutral-200 text-neutral-900"),children:o}),Lt=({config:e,className:t})=>{let[o]=useLexicalComposerContext(),n=useId(),[r,l]=useState(false),[i,s]=useState(false),[a,d]=useState(false),[c,R]=useState(false),[x,g]=useState(false),[u,I]=useState(false),[P,L]=useState(false),[T,y]=useState("paragraph"),[N,b]=useState("left"),E=useMemo(()=>Wr(e),[e]),f=useMemo(()=>qr(e),[e]),C=useMemo(()=>Gr(e),[e]),_=useCallback(()=>{let m=$getSelection();if(!$isRangeSelection(m))return;d(m.hasFormat("bold")),R(m.hasFormat("italic")),g(m.hasFormat("underline")),I(m.hasFormat("strikethrough")),L(m.hasFormat("code"));let M=m.anchor.getNode(),w=M.getKey()==="root"?M:M.getTopLevelElementOrThrow();if($isListNode(w))y(w.getListType()==="number"?"ol":"ul");else {let $=$findMatchingParent(w,j=>$isListNode(j));$isListNode($)?y($.getListType()==="number"?"ol":"ul"):y($isHeadingNode(w)?w.getTag():w.getType());}let A=$isElementNode(w)?w.getFormatType():"";b(A==="center"||A==="right"||A==="justify"?A:"left");},[]);useEffect(()=>mergeRegister(o.registerUpdateListener(({editorState:m})=>{m.read(()=>{_();});}),o.registerCommand(SELECTION_CHANGE_COMMAND,()=>(_(),false),1),o.registerCommand(CAN_UNDO_COMMAND,m=>(l(m),false),1),o.registerCommand(CAN_REDO_COMMAND,m=>(s(m),false),1)),[o,_]);let F=m=>{o.dispatchCommand(FORMAT_TEXT_COMMAND,Vr[m]);},U=m=>{o.update(()=>{let M=$getSelection();if($isRangeSelection(M)){if(m==="paragraph"){$setBlocksType(M,()=>$createParagraphNode());return}$setBlocksType(M,()=>$createHeadingNode(m));}});},h=m=>{if(T===(m==="bullet"?"ul":"ol")){o.dispatchCommand(REMOVE_LIST_COMMAND,void 0);return}o.dispatchCommand(m==="bullet"?INSERT_UNORDERED_LIST_COMMAND:INSERT_ORDERED_LIST_COMMAND,void 0);};return jsxs("div",{className:a$1("flex flex-wrap items-center gap-1 border-b border-neutral-300 bg-neutral-100 px-2 py-1.5",t),children:[e.undoRedo!==false&&jsxs(Fragment,{children:[jsx(G,{label:"Undo",onClick:()=>o.dispatchCommand(UNDO_COMMAND,void 0),disabled:!r,icon:jsx(UndoIcon,{className:"size-4"})}),jsx(G,{label:"Redo",onClick:()=>o.dispatchCommand(REDO_COMMAND,void 0),disabled:!i,icon:jsx(RedoIcon,{className:"size-4"})}),jsx(Oe,{})]}),C.length>0&&jsxs(Fragment,{children:[jsx("label",{className:"sr-only",htmlFor:n,children:"Text style"}),jsx("select",{id:n,value:T.startsWith("h")?T:"paragraph",onChange:m=>U(m.target.value),className:a$1("h-8 rounded-md border border-neutral-300 bg-white px-2 text-xs font-medium text-neutral-800","focus-visible:ring-primary-800 focus-visible:ring-2 focus-visible:ring-offset-1 focus-visible:outline-none"),children:C.map(m=>jsx("option",{value:m.value,children:m.label},m.value))}),jsx(Oe,{})]}),E.length>0&&jsxs(Fragment,{children:[E.includes("bold")&&jsx(G,{label:Me.bold,onClick:()=>F("bold"),icon:Ae.bold,active:a}),E.includes("italic")&&jsx(G,{label:Me.italic,onClick:()=>F("italic"),icon:Ae.italic,active:c}),E.includes("underline")&&jsx(G,{label:Me.underline,onClick:()=>F("underline"),icon:Ae.underline,active:x}),E.includes("strikethrough")&&jsx(G,{label:Me.strikethrough,onClick:()=>F("strikethrough"),icon:Ae.strikethrough,active:u}),E.includes("code")&&jsx(G,{label:Me.code,onClick:()=>F("code"),icon:Ae.code,active:P}),jsx(Oe,{})]}),e.lists!==false&&jsxs(Fragment,{children:[jsx(G,{label:"Bulleted list",onClick:()=>h("bullet"),icon:jsx(ListIcon,{className:"size-4"}),active:T==="ul"}),jsx(G,{label:"Numbered list",onClick:()=>h("number"),icon:jsx(ListOrderedIcon,{className:"size-4"}),active:T==="ol"}),jsx(Oe,{})]}),e.indent!==false&&jsxs(Fragment,{children:[jsx(G,{label:"Decrease indent",onClick:()=>o.dispatchCommand(OUTDENT_CONTENT_COMMAND,void 0),icon:jsx(IndentDecreaseIcon,{className:"size-4"})}),jsx(G,{label:"Increase indent",onClick:()=>o.dispatchCommand(INDENT_CONTENT_COMMAND,void 0),icon:jsx(IndentIncreaseIcon,{className:"size-4"})}),jsx(Oe,{})]}),f.length>0&&jsx(Fragment,{children:f.map(m=>jsx(G,{label:$r[m],onClick:()=>o.dispatchCommand(FORMAT_ELEMENT_COMMAND,m),icon:Ur[m],active:N===m},m))})]})};var Co=e=>{if(e!==void 0)return typeof e=="number"?`${e}px`:e},sl=forwardRef(({value:e,onChange:t,onBlur:o,onError:n,placeholder:r="Write your content...",readOnly:l=false,showToolbar:i=true,toolbarConfig:s=pt,className:a,editorClassName:d,toolbarClassName:c,autoFocus:R=false,minHeight:x=160,maxHeight:g,error:u=false,errorMessage:I,editorRef:P},L)=>{let T=useRef(false),y=useMemo(()=>({namespace:"SodtrackRichTextEditor",theme:ct,onError:(b,E)=>{if(n){n(b,E);return}console.error("RichTextEditor error",b);},nodes:[HeadingNode,ListNode,ListItemNode]}),[n]),N={minHeight:Co(x),maxHeight:Co(g),overflowY:g?"auto":void 0};return jsx(LexicalComposer,{initialConfig:y,children:jsxs("div",{className:"w-full",children:[jsxs("div",{ref:L,className:a$1("group flex w-full flex-col overflow-hidden rounded-lg border bg-white transition-colors","focus-within:ring-primary-800 focus-within:ring-2 focus-within:ring-offset-0",u?"border-error-500 focus-within:border-error-500 focus-within:ring-error-500":"border-neutral-500",l&&"border-neutral-300 bg-neutral-50 focus-within:ring-0",a),"data-error":u,"data-readonly":l,children:[i&&!l&&jsx(Lt,{config:s,className:c}),jsx(RichTextPlugin,{contentEditable:jsx(ContentEditable,{className:a$1("relative w-full px-4 py-3 text-sm leading-[142%] text-neutral-900 outline-none","[&_h1]:mt-2 [&_h1]:mb-2 [&_h2]:mt-2 [&_h2]:mb-2 [&_h3]:mt-2 [&_h3]:mb-2","[&_li]:my-1 [&_ol]:my-2 [&_ul]:my-2","[&_a]:text-primary-700 [&_a]:underline",l&&"cursor-default",d),style:N,onBlur:o,"aria-invalid":u}),placeholder:l?null:jsx("div",{className:"pointer-events-none absolute top-3 left-4 text-sm text-neutral-500",children:r}),ErrorBoundary:LexicalErrorBoundary}),jsx(HistoryPlugin,{}),jsx(ListPlugin,{}),jsx(mt,{readOnly:l}),jsx(gt,{value:e,isSyncingRef:T}),R&&!l&&jsx(AutoFocusPlugin,{}),P&&jsx(ut,{editorRef:P}),jsx(OnChangePlugin,{ignoreSelectionChange:true,onChange:(b,E)=>{!t||T.current||t(Xe(E),b);}})]}),u&&I&&jsx("p",{className:"text-error-500 mt-1 text-xs leading-[133%]",children:I})]})})});sl.displayName="RichTextEditor";var Lo={en:Pn,es:En,pt:Nn},hl={es:{clearPhoneNumberLabel:"Eliminar n\xFAmero de tel\xE9fono",searchCountryPlaceholder:"Buscar..."},pt:{clearPhoneNumberLabel:"Limpar n\xFAmero de telefone",searchCountryPlaceholder:"Pesquisar..."}},bl={clearPhoneNumberLabel:"Clear phone number",searchCountryPlaceholder:"Search..."},gl=Lo.en,yo="9 1234 5678",yt="ZZ",Ro=()=>{},Io=e=>hl[e]??bl,vo=e=>Lo[e]??gl,To=e=>{if(e)try{let t=parsePhoneNumber(e)?.country;return !t||!h(t)?void 0:t}catch{return}},Po=e=>{if(e)return getExampleNumber(e,pl)?.formatNational()},Ze=e=>e??yt,Eo=()=>{let e=getDefaultOptions().locale?.code?.split("-")[0];return e==="es"||e==="pt"?e:"en"};var Il=({Icon:e,callingCode:t,country:o,countryName:n,callingCodeClassName:r})=>jsxs("div",{className:"flex justify-center gap-2",children:[jsx("span",{className:"flex size-4.5 shrink-0 items-center justify-center",children:jsx(e,{"aria-hidden":true,country:o,label:n})}),t&&jsx("span",{className:a$1("text-sm leading-[143%] font-medium text-neutral-800",r),children:`+${t}`})]}),No=({"aria-label":e,className:t,disabled:o,error:n,iconComponent:r,name:l,onBlur:i,onChange:s,onFocus:a$2,options:d,readOnly:c,translations:R,value:x})=>{let g=useFieldContext(),u=H.useRef(null),I=H.useId(),[P,L]=H.useState(""),{contains:T}=useFilter({sensitivity:"base"}),y=c$1({disabled:o,error:n,readOnly:c}),N=H.useMemo(()=>d.filter(h$1=>h$1.value!==void 0&&h(h$1.value)).map(h=>({callingCode:getCountryCallingCode(h.value),country:h.value,key:Ze(h.value),label:h.label})),[d]),b=H.useMemo(()=>N.find(h=>h.key===Ze(x)),[N,x]),{collection:E,filter:f,set:C}=useListCollection({initialItems:N,itemToString:h=>h.callingCode?`${h.label} +${h.callingCode}`:h.label,itemToValue:h=>h.key,filter:(h,m,M)=>{let w=m.trim().replace(/^\+/,"");return T(h,m)||(M.country?T(M.country,m.toUpperCase()):false)||(M.callingCode?T(M.callingCode,w)||T(`+${M.callingCode}`,m):false)}});H.useEffect(()=>{C(N);},[N,C]);let _=H.useCallback(({inputValue:h})=>{let m=h??"";L(m),f(m),u.current?.scrollTo({top:0});},[f]),F=H.useCallback(({open:h})=>{h&&(L(""),f(""));},[f]),U=H.useCallback(({value:h$1})=>{let m=h$1[0];if(!m||m===yt){s(void 0);return}h(m)&&s(m);},[s]);return jsxs(Combobox.Root,{className:"h-full shrink-0",collection:E,disabled:o||c,ids:{input:I,label:g.ids.label},inputBehavior:"autohighlight",inputValue:P,lazyMount:true,openOnChange:false,openOnClick:false,positioning:{placement:"bottom-end",offset:{mainAxis:12},sameWidth:false},selectionBehavior:"preserve",unmountOnExit:true,value:b?[b.key]:[],onInputValueChange:_,onOpenChange:F,onValueChange:U,children:[jsx(Combobox.Control,{className:"h-full",children:jsx(Combobox.Trigger,{"aria-label":e,className:a$1("relative flex h-full w-19.5 shrink-0 items-center justify-center rounded-l after:pointer-events-none after:absolute after:top-0 after:right-0 after:h-full after:w-px after:content-['']",y==="error"?"bg-danger-20 after:bg-input-ring-error":y==="disabled"||y==="readOnly"?"after:bg-input-ring-disabled bg-neutral-200":y==="errorReadOnly"?"after:bg-input-ring-error bg-neutral-200":"group-focus-within/phone:after:bg-input-ring-focus after:bg-input-ring data-[state=open]:after:bg-input-ring-focus bg-neutral-200",t),disabled:o||c,focusable:true,name:l,onBlur:i,onFocus:a$2,children:b&&jsx(Il,{Icon:r,callingCode:b.callingCode,country:b.country,countryName:b.label,callingCodeClassName:a$1(y==="error"&&"text-danger-600",(y==="disabled"||y==="readOnly"||y==="errorReadOnly")&&"text-input-text-disabled")})})}),jsx(Portal,{children:jsx(Combobox.Positioner,{children:jsxs(Combobox.Content,{className:"elevation-9 z-layer data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 w-75 origin-(--transform-origin) overflow-hidden rounded-sm bg-neutral-50",children:[jsxs("div",{className:"pb-0",children:[jsx(Combobox.Context,{children:h=>jsx(e$1,{className:"m-1 mb-0",size:"md",state:"default",clearAdornment:!o&&h.inputValue.length>0?jsx(a$5,{onClick:()=>{h.setInputValue("","clear-trigger");}}):void 0,indicator:jsx(q,{className:"pointer-events-none size-4.5 text-neutral-800"}),children:m=>jsx(Combobox.Input,{autoComplete:"off","data-1p-ignore":true,"data-lpignore":"true",placeholder:R.searchCountryPlaceholder,className:m})})}),jsx(a,{className:"mt-2"})]}),jsx(Combobox.List,{ref:u,className:a$1("h-72 overflow-auto outline-none",{"flex flex-col items-center justify-center":E.items.length===0}),children:E.items.length===0?jsx(a$8,{size:"sm",variant:"not-found"}):jsx(Combobox.ItemGroup,{children:E.items.map(h=>jsxs(Combobox.Item,{item:h,className:"data-highlighted:bg-primary-100 relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm text-neutral-900 outline-none select-none data-disabled:pointer-events-none data-disabled:opacity-50",children:[jsx("span",{className:"flex size-4.5 shrink-0 items-center justify-center [&_.PhoneInputCountryIconImg]:size-4.5!",children:jsx(r,{"aria-hidden":true,country:h.country,label:h.label})}),jsx(Combobox.ItemText,{className:"min-w-0 flex-1 truncate text-sm leading-[143%] font-medium",children:h.label}),h.callingCode&&jsx("span",{className:"shrink-0 text-sm text-neutral-600",children:`+${h.callingCode}`}),jsx(k,{className:a$1("ml-auto size-4 shrink-0",h.key===Ze(x)?"opacity-100":"opacity-0")})]},h.key))})})]})})})]})};var Tl=vl,Ao=H.forwardRef(({className:e,defaultCountry:t,disabled:o,error:n,helperText:r,id:l,label:i,labelProps:s,onChange:a=Ro,placeholder:d$1,readOnly:c,required:R,value:x,...g},u)=>{let[I,P]=H.useState(()=>To(x)??t),L=H.useRef(null),T=Eo(),y=c$1({disabled:o,error:n,readOnly:c}),N=H.useMemo(()=>Io(T),[T]),b=H.useMemo(()=>vo(T),[T]),E=H.useMemo(()=>Po(I)??d$1??yo,[d$1,I]),f=H.useCallback(F=>{P(F);},[]),C=H.useCallback(F=>{L.current=F,typeof u=="function"?u(F):u&&(u.current=F);},[u]),_=H.useCallback(()=>{a(void 0),L.current?.focus();},[a]);return jsxs(Field.Root,{"data-error":d(y)||void 0,disabled:o,id:l,invalid:n,readOnly:c,className:a$1(b$1,e),children:[i&&jsx(c$2,{...s,as:Field.Label,label:i,required:R}),jsx(e$1,{state:y,className:"group/phone pl-0 [&_.PhoneInputCountryIconImg]:size-4.5!",clearAdornment:x?jsx(a$5,{ariaLabel:N.clearPhoneNumberLabel,onClick:_}):void 0,children:F=>jsx(Tl,{...g,className:"contents",ref:C,countrySelectComponent:No,countrySelectProps:{error:n,translations:N},defaultCountry:t,disabled:o,flagComponent:a$7,initialValueFormat:"national",inputComponent:Field.Input,labels:b,numberInputProps:{"aria-required":R||void 0,className:a$1(F,"pl-3"),placeholder:E},readOnly:c,value:x,onChange:a,onCountryChange:f})}),r&&jsx(a$6,{as:n?Field.ErrorText:Field.HelperText,children:r})]})});Ao.displayName="PhoneInput";var El=({children:e,hasDescription:t=false,disabled:o=false,hasDivider:n=false,className:r,isSelected:l,onClick:i,...s})=>jsxs(Fragment,{children:[jsx("div",{className:a$1("flex flex-row px-3 py-4 text-neutral-900 transition-colors",t?"py-3":"py-3.5",o?"cursor-not-allowed text-neutral-400":a$1("hover:bg-primary-100 focus:bg-primary-200",!!i?"cursor-pointer":"cursor-default"),l&&"bg-primary-200",r),onClick:d=>{o||i?.(d);},...s,children:e}),n&&jsx(a,{})]}),te=El;var du=({children:e,title:t,titleLines:o,description:n="",descriptionLines:r,startIcon:l,endIcon:i,hasDivider:s=false,disabled:a=false,isSelected:d=false,className:c,...R})=>jsxs(te,{hasDescription:!!n,disabled:a,hasDivider:s,className:c,isSelected:d,...R,children:[l&&H__default.cloneElement(l,{className:"shrink-0 mr-2 h-4.5 w-4.5"}),jsx(ce,{title:t,titleLines:o,description:n,descriptionLines:r,disabled:a}),i&&H__default.cloneElement(i,{className:"min-h-4.5 min-w-4.5 self-center ml-4"})]});export{Jl as a,du as b,mi as c,Li as d,Ns as e,ao as f,ga as g,Na as h,ct as i,pt as j,ge as k,ht as l,bt as m,sl as n,Ao as o};
@@ -0,0 +1 @@
1
+ import {a as a$1}from'./chunk-UIZFLYFP.js';import {c as c$1}from'./chunk-QQM4FVO7.js';import {c as c$3}from'./chunk-CY5DLXHV.js';import {d as d$1}from'./chunk-4CAN7PGG.js';import {d as d$2}from'./chunk-7JM2X4UD.js';import {c as c$2}from'./chunk-FYB3QRNL.js';import {d as d$3}from'./chunk-YFDUDY6Y.js';import {a as a$2}from'./chunk-TN46TEUP.js';import {e}from'./chunk-PI7DECIN.js';import {a}from'./chunk-HZYZAFW3.js';import {a as a$3}from'./chunk-7TTDAJTY.js';import {createContext,useContext}from'react';import {tv}from'tailwind-variants';import {jsx}from'react/jsx-runtime';var B=["ring-1 outline-none ring-inset","not-data-disabled:data-selected:not-focus:ring-2","not-data-disabled:focus:ring-primary-800 not-data-disabled:focus:ring-3"],d=tv({slots:{root:["grid grid-cols-[auto_minmax(0,1fr)] rounded-md p-3 [&>:not([data-part=card-action-description])]:col-span-full","transition-[background-color] duration-150 ease-out motion-reduce:transition-none","data-disabled:cursor-not-allowed","data-disabled:[&_[data-part=card-action-title]]:text-neutral-600","data-disabled:[&_[data-part=card-action-description]]:text-neutral-500","data-disabled:[&_[data-part=card-action-icon]]:text-neutral-600"],header:"grid grid-cols-subgrid items-start",leading:["col-start-1 mr-1.5 shrink-0","[&_[data-part=card-action-icon]]:mt-0.75","has-[[data-scope=checkbox][data-part=control]]:mr-1","has-[[data-scope=radio-group][data-part=item-control]]:mr-1","[&_[data-part=card-action-badge-category]]:p-1.25","[&_[data-part=card-action-badge-category]>svg]:size-3.5"],headerContent:"col-start-2 grid min-w-0 grid-cols-[minmax(0,1fr)_auto] items-center self-center [&>:not([data-part=card-action-title]):not([data-part=card-action-trailing])]:col-span-full",trailing:"col-start-2 row-start-1 ml-6 flex shrink-0 items-center gap-2",title:"font-inter col-start-1 row-start-1 line-clamp-2 text-base leading-[150%] font-medium text-neutral-900",description:"font-inter col-start-2 mt-1 block text-sm leading-[143%] font-normal text-neutral-800",icon:"size-4.5 shrink-0 text-neutral-900",fileIcon:"shrink-0"},variants:{variant:{outline:{root:[...B,"bg-neutral-50"]},fill:{root:[...B,"data-disabled:bg-neutral-100"]},elevated:{root:["bg-neutral-50 outline-0 outline-solid data-disabled:bg-neutral-100","not-data-disabled:data-selected:not-focus:outline-2 not-data-disabled:data-selected:not-focus:-outline-offset-2","not-data-disabled:focus:outline-primary-800 not-data-disabled:focus:outline-3 not-data-disabled:focus:-outline-offset-3"]}},tone:{neutral:{root:"not-data-disabled:data-selected:bg-neutral-200"},primary:{root:["not-data-disabled:[&_[data-part=card-action-title]]:text-primary-700","not-data-disabled:[&_[data-part=card-action-description]]:text-primary-600","not-data-disabled:[&_[data-part=card-action-icon]]:text-primary-700"]}}},compoundVariants:[{variant:["outline","fill"],tone:"neutral",class:{root:"not-data-disabled:data-selected:not-focus:ring-neutral-800"}},{variant:"outline",tone:"neutral",class:{root:"ring-neutral-400 not-data-disabled:not-data-selected:hover:bg-neutral-100"}},{variant:"fill",tone:"neutral",class:{root:"bg-neutral-100 ring-neutral-300 not-data-disabled:not-data-selected:hover:bg-neutral-200 data-disabled:ring-neutral-400"}},{variant:["outline","fill"],tone:"primary",class:{root:["ring-primary-400 data-disabled:ring-neutral-400","not-data-disabled:data-selected:not-focus:ring-primary-800"]}},{variant:"outline",tone:"primary",class:{root:"not-data-disabled:not-data-selected:hover:bg-primary-50 not-data-disabled:data-selected:bg-primary-100"}},{variant:"fill",tone:"primary",class:{root:"bg-primary-50 not-data-disabled:not-data-selected:hover:bg-primary-100 not-data-disabled:data-selected:bg-primary-200"}},{variant:"elevated",tone:"neutral",class:{root:"elevation-9 not-data-disabled:not-data-selected:hover:bg-neutral-100 not-data-disabled:data-selected:not-focus:outline-neutral-800"}},{variant:"elevated",tone:"primary",class:{root:"elevation-3 not-data-disabled:not-data-selected:hover:bg-primary-50 not-data-disabled:data-selected:bg-primary-100 not-data-disabled:data-selected:not-focus:outline-primary-800"}}]}),c=createContext(false),T=({variant:t="outline",tone:a="neutral",selected:i,disabled:e=false,onClick:r,onKeyDown:l,tabIndex:p,children:h,className:I,...k})=>{let S=n=>{!e&&!n.defaultPrevented&&r?.(n);},z=n=>{l?.(n),!(e||n.defaultPrevented||n.target!==n.currentTarget||n.key!=="Enter"&&n.key!==" ")&&(n.preventDefault(),n.repeat||n.currentTarget.click());};return jsx(c.Provider,{value:e,children:jsx("div",{...k,"data-part":"card-action-root","data-variant":t,"data-tone":a,"data-selected":i||void 0,"data-disabled":e||void 0,tabIndex:r?e?-1:p??0:p,className:d({variant:t,tone:a}).root({className:I}),onClick:r?S:void 0,onKeyDown:r?z:l,children:h})})},E=({className:t,...a})=>jsx("div",{...a,"data-part":"card-action-header",className:d().header({className:t})}),w=({className:t,...a})=>jsx("div",{...a,"data-part":"card-action-leading",className:d().leading({className:t})}),D=({className:t,...a})=>jsx("div",{...a,"data-part":"card-action-header-content",className:d().headerContent({className:t})}),_=({className:t,...a})=>jsx("div",{...a,"data-part":"card-action-trailing",className:d().trailing({className:t})}),H=({className:t,...a})=>jsx("span",{...a,"data-part":"card-action-title",className:d().title({className:t})}),O=({className:t,...a})=>jsx("span",{...a,"data-part":"card-action-description",className:d().description({className:t})}),L=({icon:t,className:a,...i})=>jsx(t,{...i,"data-part":"card-action-icon",className:d().icon({className:a})}),W=({className:t,...a$1})=>jsx(a,{...a$1,"data-part":"card-action-file-icon",className:d().fileIcon({className:t})}),F=t=>jsx("img",{...t,"data-part":"card-action-image"}),M=t=>jsx(c$1,{...t,size:"sm"}),G=({disabled:t,onClick:a,...i})=>{let e$1=useContext(c);return jsx(e,{variant:"ghost",tone:"neutral",...i,size:"sm",disabled:e$1||t,onClick:r=>{r.stopPropagation(),a?.(r);}})},K=({disabled:t,onClick:a,...i})=>{let e=useContext(c);return jsx(c$2,{...i,onClick:r=>{r.stopPropagation(),a?.(r);},disabled:e||t})},V=({disabled:t,onClick:a,...i})=>{let e=useContext(c);return jsx(d$1,{...i,onClick:r=>{r.stopPropagation(),a?.(r);},disabled:e||t})},q=({disabled:t,onClick:a,...i})=>{let e=useContext(c);return jsx(d$2,{...i,onClick:r=>{r.stopPropagation(),a?.(r);},size:"sm",disabled:e||t})},J=t=>jsx(a$1,{...t,size:"lg"}),Q=t=>jsx(a$2,{...t,size:"md"}),U=t=>jsx(a$3,{variant:"primary",type:"square",...t,size:"lg"}),X=t=>jsx(d$3,{variant:"light",color:"neutral",...t,"data-part":"card-action-badge-category",size:"sm"}),Y=t=>jsx(c$3,{...t,size:"lg"}),lt={Root:T,Header:E,Leading:w,HeaderContent:D,Trailing:_,Title:H,Description:O,Icon:L,Avatar:M,Image:F,FileIcon:W,Checkbox:K,RadioControl:V,Switch:q,IconButton:G,BadgeStatus:J,BadgeExpandable:Q,BadgeNumber:U,BadgeCategory:X,BadgeAlert:Y};export{lt as a};
@@ -142,4 +142,5 @@ type AlertMessageProps = {
142
142
  } & VariantProps<typeof alertMessageStyles>;
143
143
  declare const AlertMessage: FC<AlertMessageProps>;
144
144
 
145
- export { AlertMessage, type AlertMessageProps, type AlertMessageSize, AlertMessageSizes, type AlertMessageVariant, AlertMessageVariants };
145
+ export { AlertMessage, AlertMessageSizes, AlertMessageVariants };
146
+ export type { AlertMessageProps, AlertMessageSize, AlertMessageVariant };
@@ -76,4 +76,5 @@ declare const AttachmentCard: FC<Omit<{
76
76
  ReferenceAddButton: FC<AttachmentCardReferenceAddButtonProps>;
77
77
  };
78
78
 
79
- export { AttachmentCard, type AttachmentCardActionButtonProps, type AttachmentCardAuthorProps, type AttachmentCardBodyFileProps, type AttachmentCardDateProps, type AttachmentCardReferenceAddButtonProps, type AttachmentCardReferenceBadgeProps, type AttachmentCardReferenceProps };
79
+ export { AttachmentCard };
80
+ export type { AttachmentCardActionButtonProps, AttachmentCardAuthorProps, AttachmentCardBodyFileProps, AttachmentCardDateProps, AttachmentCardReferenceAddButtonProps, AttachmentCardReferenceBadgeProps, AttachmentCardReferenceProps };
@@ -5,4 +5,5 @@ type AutocompleteMultipleSkeletonProps = {
5
5
  };
6
6
  declare const AutocompleteMultipleSkeleton: FC<AutocompleteMultipleSkeletonProps>;
7
7
 
8
- export { AutocompleteMultipleSkeleton, type AutocompleteMultipleSkeletonProps };
8
+ export { AutocompleteMultipleSkeleton };
9
+ export type { AutocompleteMultipleSkeletonProps };
@@ -1,8 +1,8 @@
1
1
  import * as React from 'react';
2
2
  import { HTMLAttributes } from 'react';
3
- import { L as LabelOptions } from '../label-CsJyLlgF.js';
3
+ import { LabelOptions } from './index.js';
4
4
  import { EmptyStateOverrides } from './empty-state.js';
5
- import { A as AutocompleteLoad } from '../use-autocomplete-options-Bu6wJH2i.js';
5
+ import { AutocompleteLoad } from './autocomplete.js';
6
6
  import 'tailwind-variants';
7
7
  import './button.js';
8
8
  import 'lucide-react';
@@ -44,4 +44,5 @@ declare const AutocompleteMultiple: {
44
44
  displayName: string;
45
45
  };
46
46
 
47
- export { AutocompleteMultiple, type AutocompleteMultipleBaseProps, type AutocompleteMultipleOption, type AutocompleteMultipleProps, type AutocompleteMultipleSource };
47
+ export { AutocompleteMultiple };
48
+ export type { AutocompleteMultipleBaseProps, AutocompleteMultipleOption, AutocompleteMultipleProps, AutocompleteMultipleSource };
@@ -1,7 +1,7 @@
1
1
  import { FC, HTMLAttributes } from 'react';
2
2
  import { AutocompleteSize } from './autocomplete.js';
3
3
  import '../input-field-size-ZaYx46-q.js';
4
- import '../label-CsJyLlgF.js';
4
+ import '../label-CwyjuBj_.js';
5
5
  import 'tailwind-variants';
6
6
  import './badge-expandable.js';
7
7
  import 'lucide-react';
@@ -16,4 +16,5 @@ type AutocompleteSkeletonProps = {
16
16
  };
17
17
  declare const AutocompleteSkeleton: FC<AutocompleteSkeletonProps>;
18
18
 
19
- export { AutocompleteSkeleton, type AutocompleteSkeletonProps };
19
+ export { AutocompleteSkeleton };
20
+ export type { AutocompleteSkeletonProps };
@@ -1,7 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import { HTMLAttributes } from 'react';
3
3
  import { I as InputFieldSize } from '../input-field-size-ZaYx46-q.js';
4
- import { L as LabelOptions } from '../label-CsJyLlgF.js';
4
+ import { LabelOptions } from './index.js';
5
5
  import { BadgeExpandableProps } from './badge-expandable.js';
6
6
  import { EmptyStateOverrides } from './empty-state.js';
7
7
  import { A as AutocompleteLoad } from '../use-autocomplete-options-Bu6wJH2i.js';
@@ -49,4 +49,5 @@ declare const Autocomplete: {
49
49
  displayName: string;
50
50
  };
51
51
 
52
- export { Autocomplete, type AutocompleteBaseProps, AutocompleteLoad, type AutocompleteOption, type AutocompleteProps, type AutocompleteSize, AutocompleteSizeDefault, AutocompleteSizes, type AutocompleteSource };
52
+ export { Autocomplete, AutocompleteLoad, AutocompleteSizeDefault, AutocompleteSizes };
53
+ export type { AutocompleteBaseProps, AutocompleteOption, AutocompleteProps, AutocompleteSize, AutocompleteSource };
@@ -10,4 +10,5 @@ type AvatarSkeletonProps = {
10
10
  };
11
11
  declare const AvatarSkeleton: FC<AvatarSkeletonProps>;
12
12
 
13
- export { AvatarSkeleton, type AvatarSkeletonProps };
13
+ export { AvatarSkeleton };
14
+ export type { AvatarSkeletonProps };
@@ -185,4 +185,5 @@ type AvatarProps = {
185
185
  } & Omit<AvatarRootProps, "size">;
186
186
  declare const Avatar: FC<AvatarProps>;
187
187
 
188
- export { Avatar, type AvatarProps, type AvatarSize, AvatarSizes, avatarStyles };
188
+ export { Avatar, AvatarSizes, avatarStyles };
189
+ export type { AvatarProps, AvatarSize };
@@ -68,4 +68,5 @@ declare const badgeAlertStyles: tailwind_variants.TVReturnType<{
68
68
  type BadgeAlertProps = HTMLAttributes<HTMLSpanElement> & VariantProps<typeof badgeAlertStyles>;
69
69
  declare const BadgeAlert: ({ className, size, status, hasBorder, "aria-label": ariaLabel, ...rest }: BadgeAlertProps) => React.JSX.Element;
70
70
 
71
- export { BadgeAlert, type BadgeAlertProps, type BadgeAlertSize, BadgeAlertSizes, type BadgeAlertStatus, BadgeAlertStatuses };
71
+ export { BadgeAlert, BadgeAlertSizes, BadgeAlertStatuses };
72
+ export type { BadgeAlertProps, BadgeAlertSize, BadgeAlertStatus };
@@ -39,4 +39,5 @@ type BadgeCategorySkeletonProps = {
39
39
  } & VariantProps<typeof badgeCategorySkeleton>;
40
40
  declare const BadgeCategorySkeleton: FC<BadgeCategorySkeletonProps>;
41
41
 
42
- export { BadgeCategorySkeleton, type BadgeCategorySkeletonProps };
42
+ export { BadgeCategorySkeleton };
43
+ export type { BadgeCategorySkeletonProps };
@@ -179,4 +179,5 @@ type BadgeCategoryProps = {
179
179
  } & Omit<VariantProps<typeof badgeCategory>, "size" | "variant" | "color" | "isIconOnly">;
180
180
  declare const BadgeCategory: FC<BadgeCategoryProps>;
181
181
 
182
- export { BadgeCategory, type BadgeCategoryColor, BadgeCategoryColors, type BadgeCategoryProps, type BadgeCategorySize, BadgeCategorySizes, type BadgeCategoryVariant, BadgeCategoryVariants };
182
+ export { BadgeCategory, BadgeCategoryColors, BadgeCategorySizes, BadgeCategoryVariants };
183
+ export type { BadgeCategoryColor, BadgeCategoryProps, BadgeCategorySize, BadgeCategoryVariant };
@@ -39,4 +39,5 @@ type BadgeExpandableSkeletonProps = {
39
39
  } & VariantProps<typeof badgeExpandableSkeleton>;
40
40
  declare const BadgeExpandableSkeleton: FC<BadgeExpandableSkeletonProps>;
41
41
 
42
- export { BadgeExpandableSkeleton, type BadgeExpandableSkeletonProps };
42
+ export { BadgeExpandableSkeleton };
43
+ export type { BadgeExpandableSkeletonProps };
@@ -1039,6 +1039,7 @@ declare const BadgeExpandable: React.ForwardRefExoticComponent<Omit<HTMLAttribut
1039
1039
  text: string;
1040
1040
  dot: string;
1041
1041
  leadingSymbolContainer: string;
1042
- }, undefined, unknown, unknown, undefined>>>, "color" | "size"> & React.RefAttributes<HTMLDivElement>>;
1042
+ }, undefined, unknown, unknown, undefined>>>, "size" | "color"> & React.RefAttributes<HTMLDivElement>>;
1043
1043
 
1044
- export { BadgeExpandable, type BadgeExpandableColor, type BadgeExpandableLeading, type BadgeExpandableProps, type BadgeExpandableSize };
1044
+ export { BadgeExpandable };
1045
+ export type { BadgeExpandableColor, BadgeExpandableLeading, BadgeExpandableProps, BadgeExpandableSize };
@@ -14,4 +14,5 @@ type BadgeNumberProps = {
14
14
  };
15
15
  declare const BadgeNumber: FC<BadgeNumberProps>;
16
16
 
17
- export { BadgeNumber, type BadgeNumberAffix, type BadgeNumberProps, type BadgeNumberSize, type BadgeNumberType, type BadgeNumberVariant };
17
+ export { BadgeNumber };
18
+ export type { BadgeNumberAffix, BadgeNumberProps, BadgeNumberSize, BadgeNumberType, BadgeNumberVariant };
@@ -42,4 +42,5 @@ type BadgeStatusSkeletonProps = {
42
42
  } & VariantProps<typeof badgeStatusSkeleton>;
43
43
  declare const BadgeStatusSkeleton: FC<BadgeStatusSkeletonProps>;
44
44
 
45
- export { BadgeStatusSkeleton, type BadgeStatusSkeletonProps };
45
+ export { BadgeStatusSkeleton };
46
+ export type { BadgeStatusSkeletonProps };
@@ -20,4 +20,5 @@ type BadgeStatusProps = {
20
20
  } & BadgeStatusSizeTypeCombo;
21
21
  declare const BadgeStatus: FC<BadgeStatusProps>;
22
22
 
23
- export { BadgeStatus, type BadgeStatusLeading, type BadgeStatusProps, type BadgeStatusSize, type BadgeStatusType, type BadgeStatusVariant };
23
+ export { BadgeStatus };
24
+ export type { BadgeStatusLeading, BadgeStatusProps, BadgeStatusSize, BadgeStatusType, BadgeStatusVariant };
@@ -34,4 +34,5 @@ type ButtonActiveProps<TValue extends string = string> = {
34
34
  } & Omit<MenuRootProps, "onSelect">;
35
35
  declare const ButtonActive: <TValue extends string = string>({ label, StartIcon, options, onSelect, variant, size, disabled, className, tone, ...props }: ButtonActiveProps<TValue>) => React.JSX.Element;
36
36
 
37
- export { ButtonActive, type ButtonActiveOption, type ButtonActiveProps, ButtonActiveSizes, ButtonActiveTones, ButtonActiveVariants };
37
+ export { ButtonActive, ButtonActiveSizes, ButtonActiveTones, ButtonActiveVariants };
38
+ export type { ButtonActiveOption, ButtonActiveProps };
@@ -186,4 +186,5 @@ type ButtonMenuProps = Omit<React__default.ButtonHTMLAttributes<HTMLButtonElemen
186
186
  };
187
187
  declare const ButtonMenu: FC<ButtonMenuProps>;
188
188
 
189
- export { ButtonMenu, type ButtonMenuOption, type ButtonMenuProps, type ButtonMenuSize, ButtonMenuSizes, type ButtonMenuTone, ButtonMenuTones, type ButtonMenuWeight, ButtonMenuWeights };
189
+ export { ButtonMenu, ButtonMenuSizes, ButtonMenuTones, ButtonMenuWeights };
190
+ export type { ButtonMenuOption, ButtonMenuProps, ButtonMenuSize, ButtonMenuTone, ButtonMenuWeight };
@@ -211,4 +211,5 @@ type ButtonProps = {
211
211
  } & React__default.DetailedHTMLProps<React__default.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement> & VariantProps<typeof buttonStyles>;
212
212
  declare const Button: FC<ButtonProps>;
213
213
 
214
- export { Button, type ButtonProps, ButtonSizes, ButtonTones, ButtonVariants, buttonStyles };
214
+ export { Button, ButtonSizes, ButtonTones, ButtonVariants, buttonStyles };
215
+ export type { ButtonProps };
@@ -14,4 +14,5 @@ declare const useCalendar: (props?: _ark_ui_react.UseDatePickerProps) => UseDate
14
14
  declare const parseDate: typeof parseDate$1;
15
15
  declare const Calendar: FC<CalendarProps>;
16
16
 
17
- export { Calendar, type CalendarProps, CalendarProvider, parseDate, useCalendar };
17
+ export { Calendar, CalendarProvider, parseDate, useCalendar };
18
+ export type { CalendarProps };
@@ -0,0 +1,80 @@
1
+ import * as React from 'react';
2
+ import { ComponentPropsWithoutRef } from 'react';
3
+ import { LucideIcon } from 'lucide-react';
4
+ import { AvatarProps } from './avatar.js';
5
+ import { BadgeAlertProps } from './badge-alert.js';
6
+ import { BadgeCategoryProps } from './badge-category.js';
7
+ import { BadgeExpandableProps } from './badge-expandable.js';
8
+ import { BadgeNumberProps } from './badge-number.js';
9
+ import { BadgeStatusProps } from './badge-status.js';
10
+ import { CheckboxProps } from './checkbox.js';
11
+ import { IconButtonProps } from './icon-button.js';
12
+ import { RadioGroupItemProps } from './radio.js';
13
+ import { SwitchProps } from './switch.js';
14
+ import 'tailwind-variants';
15
+ import '@ark-ui/react/avatar';
16
+ import '@ark-ui/react';
17
+ import '@ark-ui/react/radio-group';
18
+ import '../label-CwyjuBj_.js';
19
+ import './tooltip.js';
20
+ import '@ark-ui/react/tooltip';
21
+ import '@ark-ui/react/switch';
22
+
23
+ type CardActionVariant = "outline" | "fill" | "elevated";
24
+ type CardActionTone = "neutral" | "primary";
25
+ type CardActionRootProps = ComponentPropsWithoutRef<"div"> & {
26
+ variant?: CardActionVariant;
27
+ tone?: CardActionTone;
28
+ selected?: boolean;
29
+ disabled?: boolean;
30
+ };
31
+ type CardActionSectionProps = ComponentPropsWithoutRef<"div">;
32
+ type CardActionTextProps = ComponentPropsWithoutRef<"span">;
33
+ type CardActionTitleProps = CardActionTextProps;
34
+ type CardActionIconProps = ComponentPropsWithoutRef<"svg"> & {
35
+ icon: LucideIcon;
36
+ };
37
+ type CardActionFileIconProps = Omit<CardActionIconProps, "icon">;
38
+ type CardActionImageProps = ComponentPropsWithoutRef<"img">;
39
+ type CardActionAvatarProps = Omit<AvatarProps, "size">;
40
+ type CardActionIconButtonProps = Omit<IconButtonProps, "size">;
41
+ type CardActionCheckboxProps = CheckboxProps;
42
+ type CardActionRadioControlProps = RadioGroupItemProps;
43
+ type CardActionSwitchProps = Omit<SwitchProps, "size">;
44
+ type CardActionBadgeStatusProps = Omit<BadgeStatusProps, "size">;
45
+ type CardActionBadgeExpandableProps = Omit<BadgeExpandableProps, "size">;
46
+ type CardActionBadgeNumberProps = Omit<BadgeNumberProps, "size" | "variant" | "type"> & {
47
+ variant?: BadgeNumberProps["variant"];
48
+ type?: BadgeNumberProps["type"];
49
+ };
50
+ type CardActionBadgeCategoryProps = Omit<BadgeCategoryProps, "size" | "variant" | "color"> & {
51
+ variant?: BadgeCategoryProps["variant"];
52
+ color?: BadgeCategoryProps["color"];
53
+ };
54
+ type CardActionBadgeAlertProps = Omit<BadgeAlertProps, "size">;
55
+ /** Compose Header and optional Description as root children; other root children are consumer-owned content. */
56
+ declare const CardAction: {
57
+ Root: ({ variant, tone, selected, disabled, onClick, onKeyDown, tabIndex, children, className, ...props }: CardActionRootProps) => React.JSX.Element;
58
+ Header: ({ className, ...props }: CardActionSectionProps) => React.JSX.Element;
59
+ Leading: ({ className, ...props }: CardActionSectionProps) => React.JSX.Element;
60
+ HeaderContent: ({ className, ...props }: CardActionSectionProps) => React.JSX.Element;
61
+ Trailing: ({ className, ...props }: CardActionSectionProps) => React.JSX.Element;
62
+ Title: ({ className, ...props }: CardActionTitleProps) => React.JSX.Element;
63
+ Description: ({ className, ...props }: CardActionTextProps) => React.JSX.Element;
64
+ Icon: ({ icon: Icon, className, ...props }: CardActionIconProps) => React.JSX.Element;
65
+ Avatar: (props: CardActionAvatarProps) => React.JSX.Element;
66
+ Image: (props: CardActionImageProps) => React.JSX.Element;
67
+ FileIcon: ({ className, ...props }: CardActionFileIconProps) => React.JSX.Element;
68
+ Checkbox: ({ disabled, onClick, ...props }: CardActionCheckboxProps) => React.JSX.Element;
69
+ RadioControl: ({ disabled, onClick, ...props }: CardActionRadioControlProps) => React.JSX.Element;
70
+ Switch: ({ disabled, onClick, ...props }: CardActionSwitchProps) => React.JSX.Element;
71
+ IconButton: ({ disabled, onClick, ...props }: CardActionIconButtonProps) => React.JSX.Element;
72
+ BadgeStatus: (props: CardActionBadgeStatusProps) => React.JSX.Element;
73
+ BadgeExpandable: (props: CardActionBadgeExpandableProps) => React.JSX.Element;
74
+ BadgeNumber: (props: CardActionBadgeNumberProps) => React.JSX.Element;
75
+ BadgeCategory: (props: CardActionBadgeCategoryProps) => React.JSX.Element;
76
+ BadgeAlert: (props: CardActionBadgeAlertProps) => React.JSX.Element;
77
+ };
78
+
79
+ export { CardAction };
80
+ export type { CardActionAvatarProps, CardActionBadgeAlertProps, CardActionBadgeCategoryProps, CardActionBadgeExpandableProps, CardActionBadgeNumberProps, CardActionBadgeStatusProps, CardActionCheckboxProps, CardActionFileIconProps, CardActionIconButtonProps, CardActionIconProps, CardActionImageProps, CardActionRadioControlProps, CardActionRootProps, CardActionSectionProps, CardActionSwitchProps, CardActionTextProps, CardActionTitleProps, CardActionTone, CardActionVariant };
@@ -0,0 +1 @@
1
+ export{a as CardAction}from'../chunk-IFHVHLTC.js';import'../chunk-UIZFLYFP.js';import'../chunk-QQM4FVO7.js';import'../chunk-CY5DLXHV.js';import'../chunk-4CAN7PGG.js';import'../chunk-7JM2X4UD.js';import'../chunk-FYB3QRNL.js';import'../chunk-YFDUDY6Y.js';import'../chunk-TN46TEUP.js';import'../chunk-QZUQ6AZK.js';import'../chunk-MW7DL42Z.js';import'../chunk-PI7DECIN.js';import'../chunk-QMPBFFFC.js';import'../chunk-ICF6RQIW.js';import'../chunk-HZYZAFW3.js';import'../chunk-C7TLKKPT.js';import'../chunk-CQI4KDR4.js';import'../chunk-7TTDAJTY.js';import'../chunk-OBZIYJO7.js';
@@ -69,4 +69,5 @@ declare const CardBasic: {
69
69
  Footer: FC<CardBasicSectionProps>;
70
70
  };
71
71
 
72
- export { CardBasic, type CardBasicActions, CardBasicBody, CardBasicFooter, CardBasicHeader, type CardBasicHeaderProps, type CardBasicLeading, type CardBasicSectionProps, type CardBasicTone, type CardBasicVariant };
72
+ export { CardBasic, CardBasicBody, CardBasicFooter, CardBasicHeader };
73
+ export type { CardBasicActions, CardBasicHeaderProps, CardBasicLeading, CardBasicSectionProps, CardBasicTone, CardBasicVariant };
@@ -40,4 +40,5 @@ declare const CardExpandableContent: FC<HTMLAttributes<HTMLDivElement>>;
40
40
  declare const CardExpandableFixedContent: FC<HTMLAttributes<HTMLDivElement>>;
41
41
  declare const CardExpandable: FC<CardExpandableProps>;
42
42
 
43
- export { CardExpandable, type CardExpandableBackground, CardExpandableContent, CardExpandableFixedContent, CardExpandableHeader, type CardExpandableHeaderProps, type CardExpandableProps };
43
+ export { CardExpandable, CardExpandableContent, CardExpandableFixedContent, CardExpandableHeader };
44
+ export type { CardExpandableBackground, CardExpandableHeaderProps, CardExpandableProps };
@@ -19,4 +19,5 @@ type CardFormFooterProps = HTMLAttributes<HTMLDivElement> & {
19
19
  };
20
20
  declare const CardFormFooter: FC<CardFormFooterProps>;
21
21
 
22
- export { CardForm, CardFormBody, CardFormFooter, CardFormHeader, type CardFormProps };
22
+ export { CardForm, CardFormBody, CardFormFooter, CardFormHeader };
23
+ export type { CardFormProps };
@@ -1,5 +1,5 @@
1
1
  import * as tailwind_variants from 'tailwind-variants';
2
- import { CheckboxCheckedState as CheckboxCheckedState$1, CheckboxRootProps } from '@ark-ui/react';
2
+ import { CheckboxRootProps, CheckboxCheckedState as CheckboxCheckedState$1 } from '@ark-ui/react';
3
3
  import { FC } from 'react';
4
4
 
5
5
  type CheckboxCheckedState = CheckboxCheckedState$1;
@@ -70,4 +70,5 @@ type CheckboxProps = Omit<CheckboxRootProps, "onCheckedChange"> & {
70
70
  };
71
71
  declare const Checkbox: FC<CheckboxProps>;
72
72
 
73
- export { Checkbox, type CheckboxCheckedState, CheckboxCheckedStates, type CheckboxProps, checkboxStyles };
73
+ export { Checkbox, CheckboxCheckedStates, checkboxStyles };
74
+ export type { CheckboxCheckedState, CheckboxProps };