@accelint/design-toolkit 5.0.0 → 5.2.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 (179) hide show
  1. package/dist/components/accordion/index.js +2 -0
  2. package/dist/components/accordion/styles.js +1 -1
  3. package/dist/components/accordion/styles.js.map +1 -1
  4. package/dist/components/action-bar/index.js +2 -0
  5. package/dist/components/action-bar/styles.d.ts +1 -1
  6. package/dist/components/action-bar/styles.js +1 -1
  7. package/dist/components/action-bar/styles.js.map +1 -1
  8. package/dist/components/avatar/index.js +2 -0
  9. package/dist/components/badge/index.js +2 -0
  10. package/dist/components/breadcrumbs/index.d.ts +15 -0
  11. package/dist/components/breadcrumbs/index.js +4 -0
  12. package/dist/components/breadcrumbs/index.js.map +1 -0
  13. package/dist/components/breadcrumbs/styles.d.ts +48 -0
  14. package/dist/components/breadcrumbs/styles.js +2 -0
  15. package/dist/components/breadcrumbs/styles.js.map +1 -0
  16. package/dist/components/breadcrumbs/types.d.ts +20 -0
  17. package/dist/components/breadcrumbs/types.js +2 -0
  18. package/dist/components/breadcrumbs/types.js.map +1 -0
  19. package/dist/components/button/index.d.ts +2 -2
  20. package/dist/components/button/index.js +3 -1
  21. package/dist/components/button/index.js.map +1 -1
  22. package/dist/components/button/styles.d.ts +15 -15
  23. package/dist/components/button/styles.js +1 -1
  24. package/dist/components/button/styles.js.map +1 -1
  25. package/dist/components/button/types.d.ts +7 -5
  26. package/dist/components/checkbox/index.js +2 -0
  27. package/dist/components/chip/index.js +2 -0
  28. package/dist/components/classification-badge/index.js +3 -1
  29. package/dist/components/classification-badge/index.js.map +1 -1
  30. package/dist/components/classification-badge/styles.d.ts +1 -1
  31. package/dist/components/classification-badge/styles.js +1 -1
  32. package/dist/components/classification-badge/styles.js.map +1 -1
  33. package/dist/components/classification-banner/index.js +3 -1
  34. package/dist/components/classification-banner/index.js.map +1 -1
  35. package/dist/components/classification-banner/styles.d.ts +1 -1
  36. package/dist/components/classification-banner/styles.js +1 -1
  37. package/dist/components/classification-banner/styles.js.map +1 -1
  38. package/dist/components/color-picker/index.js +2 -0
  39. package/dist/components/color-picker/styles.d.ts +3 -3
  40. package/dist/components/combobox-field/index.js +2 -0
  41. package/dist/components/combobox-field/styles.d.ts +1 -1
  42. package/dist/components/combobox-field/styles.js +1 -1
  43. package/dist/components/combobox-field/styles.js.map +1 -1
  44. package/dist/components/date-field/index.js +2 -0
  45. package/dist/components/date-field/index.js.map +1 -1
  46. package/dist/components/date-field/styles.d.ts +1 -1
  47. package/dist/components/date-field/styles.js +1 -1
  48. package/dist/components/date-field/styles.js.map +1 -1
  49. package/dist/components/details-list/index.js +2 -0
  50. package/dist/components/dialog/index.js +2 -0
  51. package/dist/components/dialog/styles.d.ts +1 -1
  52. package/dist/components/dialog/styles.js +1 -1
  53. package/dist/components/dialog/styles.js.map +1 -1
  54. package/dist/components/divider/index.d.ts +32 -0
  55. package/dist/components/divider/index.js +4 -0
  56. package/dist/components/divider/index.js.map +1 -0
  57. package/dist/components/divider/styles.d.ts +5 -0
  58. package/dist/components/divider/styles.js +2 -0
  59. package/dist/components/divider/styles.js.map +1 -0
  60. package/dist/components/divider/types.d.ts +11 -0
  61. package/dist/components/divider/types.js +2 -0
  62. package/dist/components/divider/types.js.map +1 -0
  63. package/dist/components/drawer/index.d.ts +12 -2
  64. package/dist/components/drawer/index.js +3 -1
  65. package/dist/components/drawer/index.js.map +1 -1
  66. package/dist/components/drawer/styles.d.ts +3 -3
  67. package/dist/components/drawer/styles.js +1 -1
  68. package/dist/components/drawer/styles.js.map +1 -1
  69. package/dist/components/drawer/types.d.ts +13 -7
  70. package/dist/components/hero/index.js +2 -0
  71. package/dist/components/hotkey/index.js +2 -0
  72. package/dist/components/icon/index.js +3 -1
  73. package/dist/components/icon/index.js.map +1 -1
  74. package/dist/components/input/index.js +2 -0
  75. package/dist/components/input/styles.js +1 -1
  76. package/dist/components/input/styles.js.map +1 -1
  77. package/dist/components/label/index.js +2 -0
  78. package/dist/components/link/index.js +2 -0
  79. package/dist/components/link/styles.d.ts +1 -1
  80. package/dist/components/link/styles.js +1 -1
  81. package/dist/components/link/styles.js.map +1 -1
  82. package/dist/components/menu/index.js +2 -0
  83. package/dist/components/menu/styles.js +1 -1
  84. package/dist/components/menu/styles.js.map +1 -1
  85. package/dist/components/options/index.js +2 -0
  86. package/dist/components/options/styles.d.ts +1 -1
  87. package/dist/components/options/styles.js +1 -1
  88. package/dist/components/options/styles.js.map +1 -1
  89. package/dist/components/popover/index.js +2 -0
  90. package/dist/components/popover/index.js.map +1 -1
  91. package/dist/components/query-builder/action-element.js +2 -0
  92. package/dist/components/query-builder/group.js +2 -0
  93. package/dist/components/query-builder/rule.js +2 -0
  94. package/dist/components/query-builder/value-editor.js +2 -0
  95. package/dist/components/radio/index.js +2 -0
  96. package/dist/components/search-field/index.js +2 -0
  97. package/dist/components/search-field/styles.js +1 -1
  98. package/dist/components/search-field/styles.js.map +1 -1
  99. package/dist/components/select-field/index.js +2 -0
  100. package/dist/components/select-field/types.d.ts +0 -1
  101. package/dist/components/sidenav/index.d.ts +16 -8
  102. package/dist/components/sidenav/index.js +3 -1
  103. package/dist/components/sidenav/index.js.map +1 -1
  104. package/dist/components/sidenav/styles.d.ts +43 -1
  105. package/dist/components/sidenav/styles.js +1 -1
  106. package/dist/components/sidenav/styles.js.map +1 -1
  107. package/dist/components/sidenav/types.d.ts +40 -8
  108. package/dist/components/slider/index.js +2 -0
  109. package/dist/components/slider/styles.d.ts +1 -1
  110. package/dist/components/slider/styles.js +1 -1
  111. package/dist/components/slider/styles.js.map +1 -1
  112. package/dist/components/switch/index.js +2 -0
  113. package/dist/components/table/context.d.ts +11 -0
  114. package/dist/components/table/context.js +2 -0
  115. package/dist/components/table/context.js.map +1 -0
  116. package/dist/components/table/index.d.ts +27 -0
  117. package/dist/components/table/index.js +4 -0
  118. package/dist/components/table/index.js.map +1 -0
  119. package/dist/components/table/styles.d.ts +134 -0
  120. package/dist/components/table/styles.js +2 -0
  121. package/dist/components/table/styles.js.map +1 -0
  122. package/dist/components/table/table-body.d.ts +12 -0
  123. package/dist/components/table/table-body.js +2 -0
  124. package/dist/components/table/table-body.js.map +1 -0
  125. package/dist/components/table/table-cell.d.ts +12 -0
  126. package/dist/components/table/table-cell.js +2 -0
  127. package/dist/components/table/table-cell.js.map +1 -0
  128. package/dist/components/table/table-header-cell.d.ts +12 -0
  129. package/dist/components/table/table-header-cell.js +2 -0
  130. package/dist/components/table/table-header-cell.js.map +1 -0
  131. package/dist/components/table/table-header.d.ts +12 -0
  132. package/dist/components/table/table-header.js +2 -0
  133. package/dist/components/table/table-header.js.map +1 -0
  134. package/dist/components/table/table-row.d.ts +12 -0
  135. package/dist/components/table/table-row.js +2 -0
  136. package/dist/components/table/table-row.js.map +1 -0
  137. package/dist/components/table/types.d.ts +185 -0
  138. package/dist/components/table/types.js +2 -0
  139. package/dist/components/table/types.js.map +1 -0
  140. package/dist/components/tabs/index.js +2 -0
  141. package/dist/components/tabs/styles.d.ts +1 -1
  142. package/dist/components/tabs/styles.js +1 -1
  143. package/dist/components/tabs/styles.js.map +1 -1
  144. package/dist/components/text-area-field/index.js +2 -0
  145. package/dist/components/text-field/index.js +2 -0
  146. package/dist/components/time-field/index.d.ts +10 -0
  147. package/dist/components/time-field/index.js +4 -0
  148. package/dist/components/time-field/index.js.map +1 -0
  149. package/dist/components/time-field/styles.d.ts +69 -0
  150. package/dist/components/time-field/styles.js +2 -0
  151. package/dist/components/time-field/styles.js.map +1 -0
  152. package/dist/components/time-field/types.d.ts +23 -0
  153. package/dist/components/time-field/types.js +2 -0
  154. package/dist/components/time-field/types.js.map +1 -0
  155. package/dist/components/tooltip/index.js +3 -1
  156. package/dist/components/tooltip/index.js.map +1 -1
  157. package/dist/components/tree/index.js +3 -1
  158. package/dist/components/tree/index.js.map +1 -1
  159. package/dist/components/tree/styles.js +1 -1
  160. package/dist/components/tree/styles.js.map +1 -1
  161. package/dist/components/view-stack/index.js +2 -0
  162. package/dist/foundation/token-data.js +1 -1
  163. package/dist/foundation/token-data.js.map +1 -1
  164. package/dist/hooks/use-tree/actions/cache.js +1 -1
  165. package/dist/hooks/use-tree/actions/cache.js.map +1 -1
  166. package/dist/hooks/use-tree/actions/index.js +2 -0
  167. package/dist/index.d.ts +21 -2
  168. package/dist/index.js +1 -1
  169. package/dist/metafile-esm.json +1 -1
  170. package/dist/providers/theme-provider.js +2 -0
  171. package/dist/styles.css +3079 -901
  172. package/dist/tokens/themes.css +56 -24
  173. package/dist/tokens/tokens.css +8 -8
  174. package/dist/tokens/tokens.d.ts +18 -0
  175. package/dist/tokens/tokens.js +1 -1
  176. package/dist/tokens/tokens.js.map +1 -1
  177. package/dist/tokens/types.d.ts +9 -0
  178. package/dist/variants/variants.css +3 -0
  179. package/package.json +12 -5
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx,jsxs}from'react/jsx-runtime';import'client-only';import T from'@accelint/icons/chevron-right';import {createContext,useContext}from'react';import {useContextProps,Popover,composeRenderProps,Menu,MenuTrigger,SubmenuTrigger,MenuSection,Header,Collection,Separator,Text,MenuItem,Provider,KeyboardContext,DEFAULT_SLOT}from'react-aria-components';import {isSlottedContextValue}from'./../../lib/utils.js';import {IconContext,Icon}from'../icon/index.js';import {MenuStyles,MenuStylesDefaults}from'./styles.js';const {menu:U,icon:_,item:q,label:z,description:B,more:G,section:J,header:Q,separator:W,hotkey:X,popover:Y}=MenuStyles(),d=createContext(null);function P({children:t,classNames:e,items:n,title:a,...s}){return jsxs(MenuSection,{...s,className:J({className:e?.section}),children:[a&&jsx(Header,{className:Q({className:e?.header}),children:a}),jsx(Collection,{items:n,children:t})]})}P.displayName="Menu.Section";function S({className:t,...e}){return jsx(Separator,{...e,className:W({className:t})})}S.displayName="Menu.Separator";function N({children:t,className:e,...n}){return jsx(Text,{...n,slot:"label",className:z({className:e}),children:t})}N.displayName="Menu.Item.Label";function v({children:t,className:e,...n}){return jsx(Text,{...n,slot:"description",className:B({className:e}),children:t})}v.displayName="Menu.Item.Description";function m({children:t,classNames:e,color:n="info",...a}){const s=useContext(d),l=(isSlottedContextValue(s)?void 0:s?.variant)??MenuStylesDefaults.variant;return jsx(MenuItem,{...a,className:composeRenderProps(e?.item,r=>q({className:r,variant:l})),"data-color":n,children:composeRenderProps(t,(r,{hasSubmenu:p})=>jsxs(Provider,{values:[[KeyboardContext,{className:X({className:e?.hotkey})}],[IconContext,{slots:{[DEFAULT_SLOT]:{className:_({className:e?.icon})},submenu:{className:G({className:e?.more})}}}]],children:[typeof r=="string"?jsx(Text,{slot:"label",className:e?.text,children:r}):r,p&&jsx(Icon,{slot:"submenu",children:jsx(T,{})})]}))})}m.displayName="Menu.Item",m.Label=N,m.Description=v;function i({ref:t,...e}){[e,t]=useContextProps(e,t??null,d);const{children:n,classNames:a,popoverProps:s,selectionMode:l="single",variant:r=MenuStylesDefaults.variant,...p}=e;return jsx(Popover,{...s,className:composeRenderProps(a?.popover,c=>Y({className:c})),children:jsx(d.Provider,{value:{variant:r},children:jsx(Menu,{...p,ref:t,className:composeRenderProps(a?.menu,c=>U({className:c,variant:r})),selectionMode:l,children:n})})})}i.displayName="Menu",i.Trigger=MenuTrigger,i.Submenu=SubmenuTrigger,i.Item=m,i.Separator=S,i.Section=P;export{i as Menu,d as MenuContext};//# sourceMappingURL=index.js.map
2
4
  //# sourceMappingURL=index.js.map
@@ -1,2 +1,2 @@
1
- import {tv}from'./../../lib/utils.js';const o={variant:"cozy"},i=tv({slots:{menu:"group/menu overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static",item:["group/menu-item flex items-center gap-x-s px-s text-body-s outline outline-transparent",'grid grid-cols-[auto_auto_1fr_auto] [grid-template-areas:"icon_label_space_action"_"icon_description_space_action"]',"enabled:focus-visible:outline-interactive-hover","color-info:enabled:fg-primary-bold","color-info:enabled:focus-visible:fg-a11y-on-accent color-info:enabled:focus-visible:bg-accent-primary-bold","color-info:enabled:hover:fg-a11y-on-accent color-info:enabled:hover:bg-accent-primary-bold","color-info:enabled:open:fg-a11y-on-accent color-info:enabled:open:bg-accent-primary-bold","color-info:enabled:selected:fg-a11y-on-accent color-info:enabled:selected:bg-accent-primary-bold","color-serious:enabled:fg-serious-bold","color-serious:enabled:focus-visible:fg-a11y-on-utility color-serious:enabled:focus-visible:bg-serious-bold","color-serious:enabled:hover:fg-a11y-on-utility color-serious:enabled:hover:bg-serious-bold","color-serious:enabled:open:fg-a11y-on-utility color-serious:enabled:open:bg-serious-bold","color-serious:enabled:selected:fg-a11y-on-utility color-serious:enabled:selected:bg-serious-bold","disabled:fg-disabled disabled:bg-transparent"],icon:"[grid-area:icon]",label:"truncate [grid-area:label] group-not-has-[>_[slot=description]]/menu-item:row-span-full",description:["[grid-area:description]","fg-primary-muted truncate text-body-xs","group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent","group-disabled/menu-item:fg-disabled"],more:"[grid-area:action]",section:"",header:"fg-primary-muted px-s py-xs text-header-xs",separator:"mx-3 my-1 outline outline-static",hotkey:["[grid-area:action]","group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent","group-disabled/menu-item:fg-disabled"],popover:"outline-none"},variants:{variant:{cozy:{item:"pt-s pb-s"},compact:{item:"pt-xs pb-xs"}}},defaultVariants:o});export{i as MenuStyles,o as MenuStylesDefaults};//# sourceMappingURL=styles.js.map
1
+ import {tv}from'./../../lib/utils.js';const o={variant:"cozy"},i=tv({slots:{menu:"group/menu overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static",item:["group/menu-item flex cursor-pointer items-center gap-x-s px-s text-body-s outline outline-transparent",'grid grid-cols-[auto_auto_1fr_auto] [grid-template-areas:"icon_label_space_action"_"icon_description_space_action"]',"enabled:focus-visible:outline-interactive-hover","color-info:enabled:fg-primary-bold","color-info:enabled:focus-visible:fg-a11y-on-accent color-info:enabled:focus-visible:bg-accent-primary-bold","color-info:enabled:hover:fg-a11y-on-accent color-info:enabled:hover:bg-accent-primary-bold","color-info:enabled:open:fg-a11y-on-accent color-info:enabled:open:bg-accent-primary-bold","color-info:enabled:selected:fg-a11y-on-accent color-info:enabled:selected:bg-accent-primary-bold","color-serious:enabled:fg-serious-bold","color-serious:enabled:focus-visible:fg-a11y-on-utility color-serious:enabled:focus-visible:bg-serious-bold","color-serious:enabled:hover:fg-a11y-on-utility color-serious:enabled:hover:bg-serious-bold","color-serious:enabled:open:fg-a11y-on-utility color-serious:enabled:open:bg-serious-bold","color-serious:enabled:selected:fg-a11y-on-utility color-serious:enabled:selected:bg-serious-bold","disabled:fg-disabled disabled:cursor-not-allowed disabled:bg-transparent"],icon:"[grid-area:icon]",label:"truncate [grid-area:label] group-not-has-[>_[slot=description]]/menu-item:row-span-full",description:["[grid-area:description]","fg-primary-muted truncate text-body-xs","group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent","group-disabled/menu-item:fg-disabled"],more:"[grid-area:action]",section:"",header:"fg-primary-muted px-s py-xs text-header-xs",separator:"mx-3 my-1 outline outline-static",hotkey:["[grid-area:action]","group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent","group-disabled/menu-item:fg-disabled"],popover:"outline-none"},variants:{variant:{cozy:{item:"pt-s pb-s"},compact:{item:"pt-xs pb-xs"}}},defaultVariants:o});export{i as MenuStyles,o as MenuStylesDefaults};//# sourceMappingURL=styles.js.map
2
2
  //# sourceMappingURL=styles.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/menu/styles.ts"],"names":["MenuStyles","tv","e"],"mappings":"sCAeE,MAAA,CAAS,CAAA,CAAA,OAGEA,CAAaC,MACxB,CAAA,CAAA,CAAO,CACLC,EAAA,CAAA,CAAA,0IAEE,CAAA,IAAA,CAAA,CAAA,wFACA,CAAA,uKAIA,CAAA,oCACA,CAAA,4GACA,CAAA,4FACA,CAAA,6LAIA,CAAA,uCACA,CAAA,4GACA,CAAA,4FACA,CAAA,6LAGA,CAAA,8CAEI,CAAA,CAAA,IAAA,CAAA,kHAGN,CAAA,WACE,CAAA,CAAA,yBACA,CAAA,kIAEA,CAAA,sCAEI,CAAA,CAAA,IAAA,CAAA,oBACG,CAAA,OACT,CAAQ,EAAA,CAAA,MAAA,CAAA,4CACR,CAAW,yEAGT,CAAA,yFACA,CAAA,sCAEO,CAAA,CAAA,OAAA,CAAA,cAEX,CAAU,CACR,QAAS,CACP,CAAA,aACQ,CAAA,CAAA,IAAA,CAAA,WAEC,CACP,QAAM,CAAA,CAAA,IAAA,CAAA,aAIZ,CAAA,CAAA,CAAA,CAAA,eACD,CAAA,CAAA,CAAA","file":"styles.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport { tv } from '@/lib/utils';\n\nexport const MenuStylesDefaults = {\n variant: 'cozy',\n} as const;\n\nexport const MenuStyles = tv({\n slots: {\n menu: 'group/menu overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static',\n item: [\n 'group/menu-item flex items-center gap-x-s px-s text-body-s outline outline-transparent',\n 'grid grid-cols-[auto_auto_1fr_auto] [grid-template-areas:\"icon_label_space_action\"_\"icon_description_space_action\"]',\n 'enabled:focus-visible:outline-interactive-hover',\n\n // Info\n 'color-info:enabled:fg-primary-bold',\n 'color-info:enabled:focus-visible:fg-a11y-on-accent color-info:enabled:focus-visible:bg-accent-primary-bold',\n 'color-info:enabled:hover:fg-a11y-on-accent color-info:enabled:hover:bg-accent-primary-bold',\n 'color-info:enabled:open:fg-a11y-on-accent color-info:enabled:open:bg-accent-primary-bold',\n 'color-info:enabled:selected:fg-a11y-on-accent color-info:enabled:selected:bg-accent-primary-bold',\n\n // Serious\n 'color-serious:enabled:fg-serious-bold',\n 'color-serious:enabled:focus-visible:fg-a11y-on-utility color-serious:enabled:focus-visible:bg-serious-bold',\n 'color-serious:enabled:hover:fg-a11y-on-utility color-serious:enabled:hover:bg-serious-bold',\n 'color-serious:enabled:open:fg-a11y-on-utility color-serious:enabled:open:bg-serious-bold',\n 'color-serious:enabled:selected:fg-a11y-on-utility color-serious:enabled:selected:bg-serious-bold',\n\n 'disabled:fg-disabled disabled:bg-transparent',\n ],\n icon: '[grid-area:icon]',\n label:\n 'truncate [grid-area:label] group-not-has-[>_[slot=description]]/menu-item:row-span-full',\n description: [\n '[grid-area:description]',\n 'fg-primary-muted truncate text-body-xs',\n 'group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent',\n 'group-disabled/menu-item:fg-disabled',\n ],\n more: '[grid-area:action]',\n section: '',\n header: 'fg-primary-muted px-s py-xs text-header-xs',\n separator: 'mx-3 my-1 outline outline-static',\n hotkey: [\n '[grid-area:action]',\n 'group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent',\n 'group-disabled/menu-item:fg-disabled',\n ],\n popover: 'outline-none',\n },\n variants: {\n variant: {\n cozy: {\n item: 'pt-s pb-s',\n },\n compact: {\n item: 'pt-xs pb-xs',\n },\n },\n },\n defaultVariants: MenuStylesDefaults,\n});\n"]}
1
+ {"version":3,"sources":["../../../src/components/menu/styles.ts"],"names":["MenuStyles","tv","e"],"mappings":"sCAeE,MAAA,CAAS,CAAA,CAAA,OAGEA,CAAaC,MACxB,CAAA,CAAA,CAAO,CACLC,EAAA,CAAA,CAAA,0IAEE,CAAA,IAAA,CAAA,CAAA,uGACA,CAAA,uKAIA,CAAA,oCACA,CAAA,4GACA,CAAA,4FACA,CAAA,6LAIA,CAAA,uCACA,CAAA,4GACA,CAAA,4FACA,CAAA,6LAGA,CAAA,0EAEI,CAAA,CAAA,IAAA,CAAA,kHAGN,CAAA,WACE,CAAA,CAAA,yBACA,CAAA,kIAEA,CAAA,sCAEI,CAAA,CAAA,IAAA,CAAA,oBACG,CAAA,OACT,CAAQ,EAAA,CAAA,MAAA,CAAA,4CACR,CAAW,yEAGT,CAAA,yFACA,CAAA,sCAEO,CAAA,CAAA,OAAA,CAAA,cAEX,CAAU,CACR,QAAS,CACP,CAAA,aACQ,CAAA,CAAA,IAAA,CAAA,WAEC,CACP,QAAM,CAAA,CAAA,IAAA,CAAA,aAIZ,CAAA,CAAA,CAAA,CAAA,eACD,CAAA,CAAA,CAAA","file":"styles.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport { tv } from '@/lib/utils';\n\nexport const MenuStylesDefaults = {\n variant: 'cozy',\n} as const;\n\nexport const MenuStyles = tv({\n slots: {\n menu: 'group/menu overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static',\n item: [\n 'group/menu-item flex cursor-pointer items-center gap-x-s px-s text-body-s outline outline-transparent',\n 'grid grid-cols-[auto_auto_1fr_auto] [grid-template-areas:\"icon_label_space_action\"_\"icon_description_space_action\"]',\n 'enabled:focus-visible:outline-interactive-hover',\n\n // Info\n 'color-info:enabled:fg-primary-bold',\n 'color-info:enabled:focus-visible:fg-a11y-on-accent color-info:enabled:focus-visible:bg-accent-primary-bold',\n 'color-info:enabled:hover:fg-a11y-on-accent color-info:enabled:hover:bg-accent-primary-bold',\n 'color-info:enabled:open:fg-a11y-on-accent color-info:enabled:open:bg-accent-primary-bold',\n 'color-info:enabled:selected:fg-a11y-on-accent color-info:enabled:selected:bg-accent-primary-bold',\n\n // Serious\n 'color-serious:enabled:fg-serious-bold',\n 'color-serious:enabled:focus-visible:fg-a11y-on-utility color-serious:enabled:focus-visible:bg-serious-bold',\n 'color-serious:enabled:hover:fg-a11y-on-utility color-serious:enabled:hover:bg-serious-bold',\n 'color-serious:enabled:open:fg-a11y-on-utility color-serious:enabled:open:bg-serious-bold',\n 'color-serious:enabled:selected:fg-a11y-on-utility color-serious:enabled:selected:bg-serious-bold',\n\n 'disabled:fg-disabled disabled:cursor-not-allowed disabled:bg-transparent',\n ],\n icon: '[grid-area:icon]',\n label:\n 'truncate [grid-area:label] group-not-has-[>_[slot=description]]/menu-item:row-span-full',\n description: [\n '[grid-area:description]',\n 'fg-primary-muted truncate text-body-xs',\n 'group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent',\n 'group-disabled/menu-item:fg-disabled',\n ],\n more: '[grid-area:action]',\n section: '',\n header: 'fg-primary-muted px-s py-xs text-header-xs',\n separator: 'mx-3 my-1 outline outline-static',\n hotkey: [\n '[grid-area:action]',\n 'group-hover/menu-item:fg-a11y-on-accent group-focus-visible/menu-item:fg-a11y-on-accent',\n 'group-disabled/menu-item:fg-disabled',\n ],\n popover: 'outline-none',\n },\n variants: {\n variant: {\n cozy: {\n item: 'pt-s pb-s',\n },\n compact: {\n item: 'pt-xs pb-xs',\n },\n },\n },\n defaultVariants: MenuStylesDefaults,\n});\n"]}
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx,jsxs}from'react/jsx-runtime';import'client-only';import {createContext}from'react';import {useContextProps,ListBox,composeRenderProps,ListBoxSection,Header,Collection,Text,ListBoxItem}from'react-aria-components';import {Icon}from'../icon/index.js';import {OptionsStyles}from'./styles.js';const {list:S,section:b,header:B,item:v,content:z,icon:H,label:V,description:g}=OptionsStyles(),E=createContext(null);function O({children:t,classNames:e,header:n,items:i}){return jsxs(ListBoxSection,{id:n,className:b({className:e?.section}),children:[jsx(Header,{className:B({className:e?.header}),children:n}),jsx(Collection,{items:i,children:t})]})}O.displayName="Options.Section";function I({className:t,...e}){return jsx("div",{...e,className:z({className:t})})}I.displayName="Options.Item.Content";function r({className:t,...e}){return jsx(Text,{...e,slot:"label",className:V({className:t})})}r.displayName="Options.Item.Label";function x({className:t,...e}){return jsx(Text,{...e,slot:"description",className:g({className:t})})}x.displayName="Options.Item.Description";function p({children:t,classNames:e,color:n="info",textValue:i=typeof t=="string"?t:"",...a}){return jsx(ListBoxItem,{...a,className:composeRenderProps(e?.item,s=>v({className:s})),textValue:i,"data-color":n,children:composeRenderProps(t,s=>jsx(Icon.Provider,{className:H({className:e?.icon}),size:"small",children:typeof s=="string"?jsx(r,{children:s}):s}))})}p.displayName="Options.Item",p.Label=r,p.Content=I,p.Description=x;function l({ref:t,...e}){[e,t]=useContextProps(e,t??null,E);const{children:n,className:i,size:a,...s}=e;return jsx(ListBox,{...s,ref:t,className:composeRenderProps(i,d=>S({className:d})),"data-size":a,children:n})}l.displayName="Options",l.Item=p,l.Section=O;export{l as Options,E as OptionsContext};//# sourceMappingURL=index.js.map
2
4
  //# sourceMappingURL=index.js.map
@@ -67,6 +67,6 @@ declare const OptionsStyles: tailwind_variants.TVReturnType<{
67
67
  icon: string[];
68
68
  label: string[];
69
69
  description: string[];
70
- }, undefined, unknown, unknown, undefined>>;
70
+ }, undefined, unknown, unknown>>;
71
71
 
72
72
  export { OptionsStyles };
@@ -1,2 +1,2 @@
1
- import {tv}from'tailwind-variants';const i=tv({slots:{list:"group/options max-h-[200px] overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static",section:"mt-s",header:"fg-primary-muted m-xs my-s text-header-xs",item:["group/options-item fg-primary-bold flex items-center gap-s p-s text-body-s outline outline-transparent","group-size-small/options:pt-xs group-size-small/options:pb-xs","group-size-large/options:pt-s group-size-large/options:pb-s","enabled:cursor-pointer","enabled:hover:fg-a11y-on-accent","enabled:focus-visible:fg-a11y-on-accent enabled:focus-visible:outline-interactive-hover","enabled:focus-visible:color-info:bg-accent-primary-bold","enabled:hover:color-info:bg-accent-primary-bold","enabled:hover:color-serious:bg-serious-bold","enabled:focus-visible:color-serious:bg-serious-bold","disabled:fg-disabled disabled:cursor-not-allowed disabled:bg-transparent"],content:"flex min-w-0 flex-auto flex-col gap-xxs",icon:["group-enabled/options-item:group-color-info/options-item:fg-primary-bold","group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-color-serious/options-item:fg-serious-bold","group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent"],label:["truncate","group-enabled/options-item:group-color-info/options-item:fg-primary-bold","group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-color-serious/options-item:fg-serious-bold","group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent"],description:["group-enabled/options-item:fg-primary-muted truncate text-body-xs","group-enabled/options-item:group-hover/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:fg-a11y-on-accent","group-disabled/options-item:fg-disabled"]}});export{i as OptionsStyles};//# sourceMappingURL=styles.js.map
1
+ import {tv}from'./../../lib/utils.js';const i=tv({slots:{list:"group/options max-h-[200px] overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static",section:"mt-s",header:"fg-primary-muted m-xs my-s text-header-xs",item:["group/options-item fg-primary-bold flex items-center gap-s p-s text-body-s outline outline-transparent","group-size-small/options:pt-xs group-size-small/options:pb-xs","group-size-large/options:pt-s group-size-large/options:pb-s","enabled:cursor-pointer","enabled:hover:fg-a11y-on-accent","enabled:focus-visible:fg-a11y-on-accent enabled:focus-visible:outline-interactive-hover","enabled:focus-visible:color-info:bg-accent-primary-bold","enabled:hover:color-info:bg-accent-primary-bold","enabled:hover:color-serious:bg-serious-bold","enabled:focus-visible:color-serious:bg-serious-bold","disabled:fg-disabled disabled:cursor-not-allowed disabled:bg-transparent"],content:"flex min-w-0 flex-auto flex-col gap-xxs",icon:["group-enabled/options-item:group-color-info/options-item:fg-primary-bold","group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-color-serious/options-item:fg-serious-bold","group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent"],label:["truncate","group-enabled/options-item:group-color-info/options-item:fg-primary-bold","group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent","group-enabled/options-item:group-color-serious/options-item:fg-serious-bold","group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent"],description:["group-enabled/options-item:fg-primary-muted truncate text-body-xs","group-enabled/options-item:group-hover/options-item:fg-a11y-on-accent","group-enabled/options-item:group-focus-visible/options-item:fg-a11y-on-accent","group-disabled/options-item:fg-disabled"]}});export{i as OptionsStyles};//# sourceMappingURL=styles.js.map
2
2
  //# sourceMappingURL=styles.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/options/styles.ts"],"names":["OptionsStyles","tv"],"mappings":"mCAcO,MAAMA,CAAAA,CAAgBC,EAAAA,CAAG,CAC9B,KAAA,CAAO,CACL,IAAA,CAAM,+IAAA,CACN,OAAA,CAAS,MAAA,CACT,MAAA,CAAQ,2CAAA,CACR,IAAA,CAAM,CACJ,wGAAA,CACA,+DAAA,CACA,6DAAA,CACA,wBAAA,CACA,iCAAA,CACA,yFAAA,CACA,yDAAA,CACA,iDAAA,CACA,6CAAA,CACA,qDAAA,CACA,0EACF,CAAA,CACA,QAAS,yCAAA,CACT,IAAA,CAAM,CACJ,0EAAA,CACA,qGAAA,CACA,6GAAA,CACA,6EAAA,CACA,wGAAA,CACA,gHACF,CAAA,CACA,KAAA,CAAO,CACL,UAAA,CACA,0EAAA,CACA,qGAAA,CACA,6GAAA,CACA,6EAAA,CACA,wGAAA,CACA,gHACF,CAAA,CACA,WAAA,CAAa,CACX,mEAAA,CACA,uEAAA,CACA,+EAAA,CACA,yCACF,CACF,CACF,CAAC","file":"styles.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport { tv } from 'tailwind-variants';\n\nexport const OptionsStyles = tv({\n slots: {\n list: 'group/options max-h-[200px] overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static',\n section: 'mt-s',\n header: 'fg-primary-muted m-xs my-s text-header-xs',\n item: [\n 'group/options-item fg-primary-bold flex items-center gap-s p-s text-body-s outline outline-transparent',\n 'group-size-small/options:pt-xs group-size-small/options:pb-xs',\n 'group-size-large/options:pt-s group-size-large/options:pb-s',\n 'enabled:cursor-pointer',\n 'enabled:hover:fg-a11y-on-accent',\n 'enabled:focus-visible:fg-a11y-on-accent enabled:focus-visible:outline-interactive-hover',\n 'enabled:focus-visible:color-info:bg-accent-primary-bold',\n 'enabled:hover:color-info:bg-accent-primary-bold',\n 'enabled:hover:color-serious:bg-serious-bold',\n 'enabled:focus-visible:color-serious:bg-serious-bold',\n 'disabled:fg-disabled disabled:cursor-not-allowed disabled:bg-transparent',\n ],\n content: 'flex min-w-0 flex-auto flex-col gap-xxs',\n icon: [\n 'group-enabled/options-item:group-color-info/options-item:fg-primary-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-color-serious/options-item:fg-serious-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n ],\n label: [\n 'truncate',\n 'group-enabled/options-item:group-color-info/options-item:fg-primary-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-color-serious/options-item:fg-serious-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n ],\n description: [\n 'group-enabled/options-item:fg-primary-muted truncate text-body-xs',\n 'group-enabled/options-item:group-hover/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:fg-a11y-on-accent',\n 'group-disabled/options-item:fg-disabled',\n ],\n },\n});\n"]}
1
+ {"version":3,"sources":["../../../src/components/options/styles.ts"],"names":["o"],"mappings":"sCAeE,MAAA,CAAO,CACLA,EAAA,CAAA,CAAA,KAAM,CAAA,CAAA,IAAA,CAAA,+IACG,CAAA,OACT,CAAA,MAAQ,CAAA,MAAA,CAAA,2CAEN,CAAA,IAAA,CAAA,CAAA,wGACA,CAAA,+DACA,CAAA,6DACA,CAAA,wBACA,CAAA,iCACA,CAAA,yFACA,CAAA,yDACA,CAAA,iDACA,CAAA,6CACA,CAAA,qDACA,CAAA,0EAEO,CAAA,CAAA,OAAA,CAAA,yCAEP,CAAA,IAAA,CAAA,CAAA,0EACA,CAAA,qGACA,CAAA,6GACA,CAAA,6EACA,CAAA,wGACA,CAAA,gHAGA,CAAA,CAAA,KAAA,CAAA,CAAA,UACA,CAAA,0EACA,CAAA,qGACA,CAAA,6GACA,CAAA,6EACA,CAAA,wGACA,CAAA,gHAEF,CAAA,CAAA,WACE,CAAA,CAAA,mEACA,CAAA,uEACA,CAAA,+EACA,CAAA,yCAGL,CAAA,CAAA,CAAA","file":"styles.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport { tv } from '@/lib/utils';\n\nexport const OptionsStyles = tv({\n slots: {\n list: 'group/options max-h-[200px] overflow-y-auto overflow-x-clip rounded-medium bg-surface-overlay shadow-elevation-overlay outline outline-static',\n section: 'mt-s',\n header: 'fg-primary-muted m-xs my-s text-header-xs',\n item: [\n 'group/options-item fg-primary-bold flex items-center gap-s p-s text-body-s outline outline-transparent',\n 'group-size-small/options:pt-xs group-size-small/options:pb-xs',\n 'group-size-large/options:pt-s group-size-large/options:pb-s',\n 'enabled:cursor-pointer',\n 'enabled:hover:fg-a11y-on-accent',\n 'enabled:focus-visible:fg-a11y-on-accent enabled:focus-visible:outline-interactive-hover',\n 'enabled:focus-visible:color-info:bg-accent-primary-bold',\n 'enabled:hover:color-info:bg-accent-primary-bold',\n 'enabled:hover:color-serious:bg-serious-bold',\n 'enabled:focus-visible:color-serious:bg-serious-bold',\n 'disabled:fg-disabled disabled:cursor-not-allowed disabled:bg-transparent',\n ],\n content: 'flex min-w-0 flex-auto flex-col gap-xxs',\n icon: [\n 'group-enabled/options-item:group-color-info/options-item:fg-primary-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-color-serious/options-item:fg-serious-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n ],\n label: [\n 'truncate',\n 'group-enabled/options-item:group-color-info/options-item:fg-primary-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-info/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-color-serious/options-item:fg-serious-bold',\n 'group-enabled/options-item:group-hover/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:group-color-serious/options-item:fg-a11y-on-accent',\n ],\n description: [\n 'group-enabled/options-item:fg-primary-muted truncate text-body-xs',\n 'group-enabled/options-item:group-hover/options-item:fg-a11y-on-accent',\n 'group-enabled/options-item:group-focus-visible/options-item:fg-a11y-on-accent',\n 'group-disabled/options-item:fg-disabled',\n ],\n },\n});\n"]}
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx}from'react/jsx-runtime';import'client-only';import {DialogTrigger,Popover,Dialog,Heading,Pressable}from'react-aria-components';import {PopoverStyles}from'./styles.js';const {content:c,body:y,title:N,footer:T}=PopoverStyles(),e=({placement:r="bottom",children:o,...p})=>jsx(DialogTrigger,{...p,children:o});e.displayName="Popover";const A=({children:r,...o})=>jsx(Pressable,{...o,children:r});e.displayName="Popover.Trigger";const i=({children:r,className:o,...p})=>jsx(Popover,{className:c({className:o}),...p,children:jsx(Dialog,{children:r})});i.displayName="Popover.Content";const a=({children:r,className:o,...p})=>jsx(Heading,{slot:"title",className:N({className:o}),...p,children:r});a.displayName="Popover.Title";const s=({children:r,className:o})=>jsx("div",{className:y({className:o}),children:r});s.displayName="Popover.Body";const P=({children:r,className:o})=>jsx("div",{className:T({className:o}),children:r});P.displayName="Popover.Footer",e.Title=a,e.Content=i,e.Body=s,e.Footer=P,e.Trigger=A;export{e as Popover};//# sourceMappingURL=index.js.map
2
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/popover/index.tsx"],"names":["PopoverStyles","Popover","rest","jsx","t","n","props","g","l","PopoverContent","v","PopoverTitle","PopoverBody","PopoverFooter","PopoverTrigger"],"mappings":"mLA+BQ,MAAA,CAAA,OAAS,CAAA,CAAA,CAAA,YAAa,CAAA,CAAA,CAAA,MAAWA,CAAAA,CAAc,CAAA,CAqC1CC,aAAAA,EAAW,CACtB,aAAY,CAAA,CAAA,CAAA,iBAEZ,CAAA,CAAGC,CACL,GAAA,CACSC,CAAAA,GAACC,GAAmB,CAAAC,aAAA,CAAGH,CAAAA,aAAgB,CAEhDD,EAAQ,EAAA,CAAA,CAAA,WAAc,CAAA,gBAEI,CAAA,CAAA,CAAA,CAAA,UAAaK,CAAM,GAAA,CACpCH,IAACC,GAAW,WAAGE,CAAAA,GAAQ,CAAA,CAAA,QAAS,CAEzCL,CAAAA,CAAQ,CAAA,CAAA,CAAA,CAAA,6BAER,CAAA,MACE,CAAA,CAAA,CAAA,CAAA,QACA,CAAA,CAAA,CAAA,SACA,CAAA,CAAGC,CACL,GAAA,CAEIC,CAAAA,GAACC,GAAY,CAAAG,OAAA,CAAA,CAAA,SAAqB,CAAA,CAAA,CAAA,CAAA,SAAW,CAAI,CAAA,CAAA,CAAGL,CAAAA,GAElD,CAAA,CAAA,SAACE,GAAY,CAAAI,MAAA,CAAA,CAAA,QAAS,CACxB,CAAA,CAGJC,EAAe,CAAA,CAAA,CAAA,CAAA,WAAc,CAAA,wBAEL,CAAA,CAAA,CAAA,CAAA,oBAAqB,CAAA,CAAGP,CAAK,GAAA,CAEjDC,CAAAA,GAACC,GAAY,CAAAM,OAAA,CAAA,CAAA,IAAK,CAAA,iBAA2B,cAAe,CAAA,CAAA,CAAGR,CAAAA,GAC5D,CAAA,CAAA,QACH,CAIJS,CAAAA,CAAa,eAAc,CAAA,eAE3B,CAAA,MAAuB,YAAU,CAAA,CAAA,CAAA,SAAU,CAAA,CAClCR,CAAAA,GAACC,GAAA,CAAA,gBAAsB,cAAe,CAAA,CAAA,CAAA,CAAA,QAAS,CAExDQ,CAAAA,CAAY,CAAA,CAAA,CAAA,CAAA,WAAc,CAAA,qBAGxB,CAAA,CAAA,CAAA,CAAA,oBAEF,CAAA,CAIST,CAAAA,GAACC,GAAA,CAAA,KAAI,CAAA,CAAA,SAAoB,CAAA,CAAA,CAAA,CAAA,SAAW,CAAI,CAAA,CAAA,CAAA,CAAA,QAAS,CAE1DS,CAAAA,CAAc,CAAA,CAAA,CAAA,CAAA,WAAc,CAAA,gBAEpB,CAAA,CAAA,CAAA,KACRZ,CAAQ,CAAA,CAAA,CAAA,CAAA,OACRA,CAAQ,CAAA,CAAA,CAAA,CAAA,IACRA,CAAQ,CAAA,CAAA,CAAA,CAAA,MACRA,CAAQ,CAAA,CAAA,CAAA,CAAA,OAAUa,CAAAA,CAAAA","file":"index.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n'use client';\nimport 'client-only';\nimport {\n Dialog as AriaDialog,\n DialogTrigger as AriaDialogTrigger,\n Heading as AriaHeading,\n Popover as AriaPopover,\n Pressable,\n} from 'react-aria-components';\nimport { PopoverStyles } from './styles';\nimport type { ReactNode } from 'react';\nimport type {\n PopoverBodyProps,\n PopoverContentProps,\n PopoverProps,\n PopoverTitleProps,\n PopoverTriggerProps,\n} from './types';\n\nconst { content, body, title, footer } = PopoverStyles();\n\n/**\n * Popover - A floating content container positioned relative to a trigger element\n *\n * Provides accessible popover functionality with flexible positioning and content\n * organization. Perfect for contextual information, menus, or supplementary content\n * that appears on demand without interrupting the user's workflow.\n *\n * @example\n * // Basic popover\n * <Popover>\n * <Popover.Trigger>\n * <Button>Show Info</Button>\n * </Popover.Trigger>\n * <Popover.Content>\n * <Popover.Body>\n * <p>Additional information appears here</p>\n * </Popover.Body>\n * </Popover.Content>\n * </Popover>\n *\n * @example\n * // Popover with title and actions\n * <Popover placement=\"top\">\n * <Popover.Trigger>\n * <Button>Options</Button>\n * </Popover.Trigger>\n * <Popover.Content>\n * <Popover.Title>Quick Actions</Popover.Title>\n * <Popover.Body>\n * <Button>Edit</Button>\n * <Button>Delete</Button>\n * </Popover.Body>\n * </Popover.Content>\n * </Popover>\n */\nexport const Popover = ({\n placement = 'bottom',\n children,\n ...rest\n}: PopoverProps) => {\n return <AriaDialogTrigger {...rest}>{children}</AriaDialogTrigger>;\n};\nPopover.displayName = 'Popover';\n\nconst PopoverTrigger = ({ children, ...props }: PopoverTriggerProps) => {\n return <Pressable {...props}>{children}</Pressable>;\n};\nPopover.displayName = 'Popover.Trigger';\n\nconst PopoverContent = ({\n children,\n className,\n ...rest\n}: PopoverContentProps) => {\n return (\n <AriaPopover className={content({ className })} {...rest}>\n {/* @ts-expect-error package version mismatch TODO */}\n <AriaDialog>{children}</AriaDialog>\n </AriaPopover>\n );\n};\nPopoverContent.displayName = 'Popover.Content';\n\nconst PopoverTitle = ({ children, className, ...rest }: PopoverTitleProps) => {\n return (\n <AriaHeading slot='title' className={title({ className })} {...rest}>\n {children}\n </AriaHeading>\n );\n};\n\nPopoverTitle.displayName = 'Popover.Title';\n\nconst PopoverBody = ({ children, className }: PopoverBodyProps) => {\n return <div className={body({ className })}>{children}</div>;\n};\nPopoverBody.displayName = 'Popover.Body';\n\nconst PopoverFooter = ({\n children,\n className,\n}: {\n children: ReactNode;\n className?: string;\n}) => {\n return <div className={footer({ className })}>{children}</div>;\n};\nPopoverFooter.displayName = 'Popover.Footer';\n\nPopover.Title = PopoverTitle;\nPopover.Content = PopoverContent;\nPopover.Body = PopoverBody;\nPopover.Footer = PopoverFooter;\nPopover.Trigger = PopoverTrigger;\n"]}
1
+ {"version":3,"sources":["../../../src/components/popover/index.tsx"],"names":["PopoverStyles","Popover","rest","jsx","t","n","props","g","l","PopoverContent","v","PopoverTitle","PopoverBody","PopoverFooter","PopoverTrigger"],"mappings":"mLAgCQ,MAAA,CAAA,OAAS,CAAA,CAAA,CAAA,YAAa,CAAA,CAAA,CAAA,MAAWA,CAAAA,CAAc,CAAA,CAqC1CC,aAAAA,EAAW,CACtB,aAAY,CAAA,CAAA,CAAA,iBAEZ,CAAA,CAAGC,CACL,GAAA,CACSC,CAAAA,GAACC,GAAmB,CAAAC,aAAA,CAAGH,CAAAA,aAAgB,CAEhDD,EAAQ,EAAA,CAAA,CAAA,WAAc,CAAA,gBAEI,CAAA,CAAA,CAAA,CAAA,UAAaK,CAAM,GAAA,CACpCH,IAACC,GAAW,WAAGE,CAAAA,GAAQ,CAAA,CAAA,QAAS,CAEzCL,CAAAA,CAAQ,CAAA,CAAA,CAAA,CAAA,6BAER,CAAA,MACE,CAAA,CAAA,CAAA,CAAA,QACA,CAAA,CAAA,CAAA,SACA,CAAA,CAAGC,CACL,GAAA,CAEIC,CAAAA,GAACC,GAAY,CAAAG,OAAA,CAAA,CAAA,SAAqB,CAAA,CAAA,CAAA,CAAA,SAAW,CAAI,CAAA,CAAA,CAAGL,CAAAA,GAElD,CAAA,CAAA,SAACE,GAAY,CAAAI,MAAA,CAAA,CAAA,QAAS,CACxB,CAAA,CAGJC,EAAe,CAAA,CAAA,CAAA,CAAA,WAAc,CAAA,wBAEL,CAAA,CAAA,CAAA,CAAA,oBAAqB,CAAA,CAAGP,CAAK,GAAA,CAEjDC,CAAAA,GAACC,GAAY,CAAAM,OAAA,CAAA,CAAA,IAAK,CAAA,iBAA2B,cAAe,CAAA,CAAA,CAAGR,CAAAA,GAC5D,CAAA,CAAA,QACH,CAIJS,CAAAA,CAAa,eAAc,CAAA,eAE3B,CAAA,MAAuB,YAAU,CAAA,CAAA,CAAA,SAAU,CAAA,CAClCR,CAAAA,GAACC,GAAA,CAAA,gBAAsB,cAAe,CAAA,CAAA,CAAA,CAAA,QAAS,CAExDQ,CAAAA,CAAY,CAAA,CAAA,CAAA,CAAA,WAAc,CAAA,qBAGxB,CAAA,CAAA,CAAA,CAAA,oBAEF,CAAA,CAIST,CAAAA,GAACC,GAAA,CAAA,KAAI,CAAA,CAAA,SAAoB,CAAA,CAAA,CAAA,CAAA,SAAW,CAAI,CAAA,CAAA,CAAA,CAAA,QAAS,CAE1DS,CAAAA,CAAc,CAAA,CAAA,CAAA,CAAA,WAAc,CAAA,gBAEpB,CAAA,CAAA,CAAA,KACRZ,CAAQ,CAAA,CAAA,CAAA,CAAA,OACRA,CAAQ,CAAA,CAAA,CAAA,CAAA,IACRA,CAAQ,CAAA,CAAA,CAAA,CAAA,MACRA,CAAQ,CAAA,CAAA,CAAA,CAAA,OAAUa,CAAAA,CAAAA","file":"index.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n'use client';\n\nimport 'client-only';\nimport {\n Dialog as AriaDialog,\n DialogTrigger as AriaDialogTrigger,\n Heading as AriaHeading,\n Popover as AriaPopover,\n Pressable,\n} from 'react-aria-components';\nimport { PopoverStyles } from './styles';\nimport type { ReactNode } from 'react';\nimport type {\n PopoverBodyProps,\n PopoverContentProps,\n PopoverProps,\n PopoverTitleProps,\n PopoverTriggerProps,\n} from './types';\n\nconst { content, body, title, footer } = PopoverStyles();\n\n/**\n * Popover - A floating content container positioned relative to a trigger element\n *\n * Provides accessible popover functionality with flexible positioning and content\n * organization. Perfect for contextual information, menus, or supplementary content\n * that appears on demand without interrupting the user's workflow.\n *\n * @example\n * // Basic popover\n * <Popover>\n * <Popover.Trigger>\n * <Button>Show Info</Button>\n * </Popover.Trigger>\n * <Popover.Content>\n * <Popover.Body>\n * <p>Additional information appears here</p>\n * </Popover.Body>\n * </Popover.Content>\n * </Popover>\n *\n * @example\n * // Popover with title and actions\n * <Popover placement=\"top\">\n * <Popover.Trigger>\n * <Button>Options</Button>\n * </Popover.Trigger>\n * <Popover.Content>\n * <Popover.Title>Quick Actions</Popover.Title>\n * <Popover.Body>\n * <Button>Edit</Button>\n * <Button>Delete</Button>\n * </Popover.Body>\n * </Popover.Content>\n * </Popover>\n */\nexport const Popover = ({\n placement = 'bottom',\n children,\n ...rest\n}: PopoverProps) => {\n return <AriaDialogTrigger {...rest}>{children}</AriaDialogTrigger>;\n};\nPopover.displayName = 'Popover';\n\nconst PopoverTrigger = ({ children, ...props }: PopoverTriggerProps) => {\n return <Pressable {...props}>{children}</Pressable>;\n};\nPopover.displayName = 'Popover.Trigger';\n\nconst PopoverContent = ({\n children,\n className,\n ...rest\n}: PopoverContentProps) => {\n return (\n <AriaPopover className={content({ className })} {...rest}>\n {/* @ts-expect-error package version mismatch TODO */}\n <AriaDialog>{children}</AriaDialog>\n </AriaPopover>\n );\n};\nPopoverContent.displayName = 'Popover.Content';\n\nconst PopoverTitle = ({ children, className, ...rest }: PopoverTitleProps) => {\n return (\n <AriaHeading slot='title' className={title({ className })} {...rest}>\n {children}\n </AriaHeading>\n );\n};\n\nPopoverTitle.displayName = 'Popover.Title';\n\nconst PopoverBody = ({ children, className }: PopoverBodyProps) => {\n return <div className={body({ className })}>{children}</div>;\n};\nPopoverBody.displayName = 'Popover.Body';\n\nconst PopoverFooter = ({\n children,\n className,\n}: {\n children: ReactNode;\n className?: string;\n}) => {\n return <div className={footer({ className })}>{children}</div>;\n};\nPopoverFooter.displayName = 'Popover.Footer';\n\nPopover.Title = PopoverTitle;\nPopover.Content = PopoverContent;\nPopover.Body = PopoverBody;\nPopover.Footer = PopoverFooter;\nPopover.Trigger = PopoverTrigger;\n"]}
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx}from'react/jsx-runtime';import'client-only';import {useCallback,useMemo}from'react';import {Button}from'../button/index.js';import {pressToMouseEvent}from'./utils.js';function E({disabled:e,disabledTranslation:t,title:o,handleOnClick:r}){const s=useCallback(p=>r(pressToMouseEvent(p)),[r]),m=useMemo(()=>t?.title&&e?t.title:o,[t?.title,e,o]);return jsx(Button,{isDisabled:e&&!t,onPress:s,size:"small",variant:"outline",children:m})}export{E as ActionElement};//# sourceMappingURL=action-element.js.map
2
4
  //# sourceMappingURL=action-element.js.map
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsxs,jsx,Fragment}from'react/jsx-runtime';import'client-only';import {useMemo}from'react';import {useRuleGroup,useStopEventPropagation,TestID}from'react-querybuilder';import {cn}from'./../../lib/utils.js';function O(t){const a=useRuleGroup(t),{schema:{controls:{ruleGroupBodyElements:s}}}=a,{schema:{classNames:n}}=t,c=useStopEventPropagation(a.addRule),i=useStopEventPropagation(a.addGroup),d=useStopEventPropagation(a.cloneGroup),m=useStopEventPropagation(a.toggleLockGroup),p=useStopEventPropagation(a.removeGroup),v=useMemo(()=>({...a,addGroup:i,addRule:c,cloneGroup:d,removeGroup:p,toggleLockGroup:m}),[i,c,d,a,p,m]);return jsxs("div",{className:cn(n.ruleGroup),children:[jsx("div",{className:cn(n.header),children:jsx(C,{...v})}),jsx("div",{className:cn(n.body),children:jsx(s,{...v})}),jsx("div",{className:cn(n.header),children:jsx(N,{...v})})]})}function C(t){const a=t.schema.showLockButtons,s=t.path.length>0,n=t.schema.showCloneButtons&&s,{schema:{controls:{combinatorSelector:c,cloneGroupAction:i,lockGroupAction:d,removeGroupAction:m}}}=t;return jsxs(Fragment,{children:[jsx(c,{testID:TestID.combinators,options:t.schema.combinators,ruleGroup:t.ruleGroup,value:t.combinator,title:t.translations.combinators.title,className:t.classNames.combinators,handleOnChange:t.onCombinatorChange,rules:t.ruleGroup.rules,level:t.path.length,path:t.path,disabled:t.disabled,context:t.context,validation:t.validationResult,schema:t.schema},TestID.combinators),n&&jsx("div",{children:jsx(i,{testID:TestID.cloneGroup,label:t.translations.cloneRuleGroup.label,title:t.translations.cloneRuleGroup.title,className:t.classNames.cloneGroup,handleOnClick:t.cloneGroup,rules:t.ruleGroup.rules,level:t.path.length,path:t.path,disabled:t.disabled,context:t.context,validation:t.validationResult,ruleOrGroup:t.ruleGroup,schema:t.schema},TestID.cloneGroup)}),a&&jsx("div",{children:jsx(d,{testID:TestID.lockGroup,label:t.translations.lockGroup.label,title:t.translations.lockGroup.title,className:t.classNames.lockGroup,handleOnClick:t.toggleLockGroup,rules:t.ruleGroup.rules,level:t.path.length,path:t.path,disabled:t.disabled,disabledTranslation:t.parentDisabled?void 0:t.translations.lockGroupDisabled,context:t.context,validation:t.validationResult,ruleOrGroup:t.ruleGroup,schema:t.schema},TestID.lockGroup)}),s&&jsx("div",{children:jsx(m,{testID:TestID.removeGroup,label:t.translations.removeGroup.label,title:t.translations.removeGroup.title,className:t.classNames.removeGroup,handleOnClick:t.removeGroup,rules:t.ruleGroup.rules,level:t.path.length,path:t.path,disabled:t.disabled,context:t.context,validation:t.validationResult,ruleOrGroup:t.ruleGroup,schema:t.schema},TestID.removeGroup)})]})}function N(t){const{schema:{controls:{addGroupAction:a,addRuleAction:s}}}=t;return jsxs(Fragment,{children:[jsx(s,{testID:TestID.addRule,label:t.translations.addRule.label,title:t.translations.addRule.title,className:t.classNames.addRule,handleOnClick:t.addRule,rules:t.ruleGroup.rules,level:t.path.length,path:t.path,disabled:t.disabled,context:t.context,validation:t.validationResult,ruleOrGroup:t.ruleGroup,schema:t.schema},TestID.addRule),jsx(a,{testID:TestID.addGroup,label:t.translations.addGroup.label,title:t.translations.addGroup.title,className:t.classNames.addGroup,handleOnClick:t.addGroup,rules:t.ruleGroup.rules,level:t.path.length,path:t.path,disabled:t.disabled,context:t.context,validation:t.validationResult,ruleOrGroup:t.ruleGroup,schema:t.schema},TestID.addGroup)]})}export{O as RuleGroup,N as RuleGroupFooterComponent,C as RuleGroupHeaderComponent};//# sourceMappingURL=group.js.map
2
4
  //# sourceMappingURL=group.js.map
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsxs,Fragment,jsx}from'react/jsx-runtime';import'client-only';import {useContext}from'react';import {useRule,useStopEventPropagation,TestID}from'react-querybuilder';function Z(d){const e=useRule(d),v=useContext(d.context),{classNames:r,disabled:C,operators:S,outerClassName:p,rule:{field:u,operator:n,value:f,valueSource:m},schema:{controls:{fieldSelector:N,operatorSelector:g,valueSourceSelector:k,valueEditor:D,cloneRuleAction:O,lockRuleAction:y,removeRuleAction:E},fields:b,listsAsArrays:A,parseNumbers:I,showCloneButtons:T,showLockButtons:x},fieldData:R,generateOnChangeHandler:s,inputType:L,parentDisabled:B,path:h,translations:l,valueEditorType:P,valueEditorSeparator:w,values:G,valueSources:V,valueSourceOptions:H,validationResult:Q}=e,F=useStopEventPropagation(e.cloneRule),q=useStopEventPropagation(e.toggleLockRule),z=useStopEventPropagation(e.removeRule),o={context:v,disabled:C,level:h.length,path:h,schema:e.schema,validation:Q},J=!["null","notNull"].includes(n)&&V.length>1;return jsxs(Fragment,{children:[v.showRuleLines&&jsx("span",{className:"rule-lines relative"}),jsxs("div",{className:p,children:[jsx(N,{testID:TestID.fields,options:b,title:l.fields.title,value:u,operator:n,className:r.fields,handleOnChange:s("field"),rule:e.rule,...o}),jsx(g,{testID:TestID.operators,field:u,fieldData:e.fieldData,title:e.translations.operators.title,options:S,value:n,className:e.classNames.operators,handleOnChange:e.generateOnChangeHandler("operator"),rule:e.rule,...o}),jsx(D,{testID:TestID.valueEditor,field:u,fieldData:R,title:l.value.title,operator:n,value:f,valueSource:m??"value",type:P,inputType:L,values:G,listsAsArrays:A,parseNumbers:I,separator:w,className:r.value,handleOnChange:s("value"),rule:e.rule,...o}),J&&jsx(k,{testID:TestID.valueSourceSelector,field:u,fieldData:R,title:l.valueSourceSelector.title,options:H,value:m??"value",className:r.valueSource,handleOnChange:s("valueSource"),rule:e.rule,...o})]}),jsxs("div",{className:p,children:[jsx(E,{testID:TestID.removeRule,label:l.removeRule.label??"remove",title:l.removeRule.title??"remove",className:r.removeRule,handleOnClick:z,ruleOrGroup:e.rule,...o}),T&&jsx(O,{testID:TestID.cloneRule,label:l.cloneRule.label??"clone",title:l.cloneRule.title??"clone",className:r.cloneRule,handleOnClick:F,ruleOrGroup:e.rule,...o}),x&&jsx(y,{testID:TestID.lockRule,label:l.lockRule.label??"lock",title:l.lockRule.title??"lock",className:r.lockRule,handleOnClick:q,disabledTranslation:B?void 0:l.lockRuleDisabled,ruleOrGroup:e.rule,...o})]})]})}export{Z as Rule};//# sourceMappingURL=rule.js.map
2
4
  //# sourceMappingURL=rule.js.map
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx,Fragment}from'react/jsx-runtime';import'client-only';import {useCallback}from'react';import {useValueEditor}from'react-querybuilder';import {Checkbox}from'../checkbox/index.js';import {Radio}from'../radio/index.js';import {Switch}from'../switch/index.js';import {TextAreaField}from'../text-area-field/index.js';import {TextField}from'../text-field/index.js';import {multiValueOperators}from'./constants.js';import {getValidationResult}from'./utils.js';import {ValueSelector}from'./value-selector.js';function k({disabled:a,fieldData:{name:e,validator:t},handleOnChange:i,rule:o,value:r}){const{valid:l}=getValidationResult(o,t);return jsx(Checkbox,{isDisabled:a,isSelected:r,onChange:i,"aria-invalid":!l,"aria-label":e})}function x({disabled:a,fieldData:{name:e,validator:t},handleOnChange:i,rule:o,value:r,values:l}){const{valid:d}=getValidationResult(o,t);return jsx(Radio.Group,{value:r,isDisabled:a,onChange:i,"aria-invalid":!d,"aria-label":e,"aria-labelledby":e,children:l?.map(n=>jsx(Radio,{value:n.value,children:n.label},n.name))})}const R=[];function S({disabled:a,fieldData:{name:e,validator:t},handleOnChange:i,rule:o,type:r,value:l,values:d=R,...n}){const{valid:c}=getValidationResult(o,t);return jsx(ValueSelector,{...n,disabled:a,multiple:r==="multiselect",options:d,title:e,validation:!c,value:l,handleOnChange:i,"aria-labelledby":e})}function T({disabled:a,fieldData:{name:e,validator:t},handleOnChange:i,rule:o,value:r}){const{valid:l}=getValidationResult(o,t);return jsx(Switch,{isDisabled:a,isSelected:!!r,onChange:i,"aria-invalid":!l,"aria-label":e,"aria-labelledby":e})}function w({disabled:a,fieldData:{name:e,placeholder:t,validator:i},handleOnChange:o,inputType:r,rule:l,value:d}){const{valid:n,reasons:c}=getValidationResult(l,i);return jsx(TextField,{inputProps:{placeholder:t,type:r??"text"},size:"small",value:d,isDisabled:a,isInvalid:!n,onChange:o,"aria-invalid":!n,"aria-label":e,"aria-labelledby":e,errorMessage:c?.join("/n")})}function I({disabled:a,fieldData:{name:e,placeholder:t,validator:i},handleOnChange:o,rule:r,value:l}){const{valid:d,reasons:n}=getValidationResult(r,i);return jsx(TextAreaField,{size:"small",errorMessage:n?.join("/n"),inputProps:{placeholder:t},value:l,isDisabled:a,isInvalid:!d,onChange:o,"aria-label":e,"aria-invalid":!d,"aria-labelledby":e})}const O={checkbox:k,radio:x,select:S,switch:T,text:w,textarea:I};function J(a){const{fieldData:{name:e,valueEditorType:t},operator:i,rule:o}=a,{valueAsArray:r,multiValueHandler:l}=useValueEditor({...a,skipHook:true}),d=useCallback(s=>({...o,value:r[s]}),[o,r]),n=useCallback(s=>l(s,0),[l]),c=useCallback(s=>l(s,1),[l]),E=(typeof t=="function"?t(i):t)??"text",f=O?.[E];return i==="null"||i==="notNull"||!f?null:multiValueOperators.includes(i)?jsx(Fragment,{children:["start","end"].map((s,m)=>jsx("div",{children:jsx(f,{...a,rule:d(m),value:r[m],handleOnChange:m?c:n})},`${e}-${s}`))}):jsx("div",{children:jsx(f,{...a})})}export{J as ValueEditor};//# sourceMappingURL=value-editor.js.map
2
4
  //# sourceMappingURL=value-editor.js.map
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx,jsxs,Fragment}from'react/jsx-runtime';import'client-only';import {createContext}from'react';import {Radio,composeRenderProps,useContextProps,RadioGroup}from'react-aria-components';import {Label}from'../label/index.js';import {RadioStyles}from'./styles.js';const {group:y,groupLabel:C,radio:A,control:L,label:g}=RadioStyles(),D=createContext(null);function p({ref:o,...r}){[r,o]=useContextProps(r,o??null,D);const{children:s,classNames:a,label:t,...m}=r;return jsx(RadioGroup,{...m,ref:o,className:composeRenderProps(a?.group,l=>y({className:l})),children:composeRenderProps(s,(l,{isDisabled:R,isRequired:c})=>jsxs(Fragment,{children:[t&&jsx(Label,{className:C({className:a?.label}),isDisabled:R,isRequired:c,children:t}),l]}))})}p.displayName="Radio.Group";function d({classNames:o,children:r,...s}){return jsx(Radio,{...s,className:composeRenderProps(o?.radio,a=>A({className:a})),children:composeRenderProps(r,a=>jsxs(Fragment,{children:[jsx("span",{className:L({className:o?.control})}),jsx("span",{className:g({className:o?.label}),children:a})]}))})}d.displayName="Radio",d.Group=p;export{d as Radio,D as RadioContext};//# sourceMappingURL=index.js.map
2
4
  //# sourceMappingURL=index.js.map
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx,jsxs}from'react/jsx-runtime';import'client-only';import {Search,Loop,CancelFill}from'@accelint/icons';import {createContext}from'react';import {useContextProps,SearchField,composeRenderProps,Input,Button}from'react-aria-components';import {Icon}from'../icon/index.js';import {SearchFieldStyles,SearchFieldStylesDefaults}from'./styles.js';const {field:I,input:g,search:L,loading:A,clear:B}=SearchFieldStyles(),c=createContext(null);function n({children:r,...a}){return jsx(c.Provider,{value:a,children:r})}n.displayName="SearchField.Provider";function d({ref:r,...a}){[a,r]=useContextProps(a,r??null,c);const{classNames:o,inputProps:p,isLoading:m=false,variant:i=SearchFieldStylesDefaults.variant,...h}=a;return jsx(Icon.Provider,{size:"small",children:jsxs(SearchField,{...h,ref:r,className:composeRenderProps(o?.field,l=>I({className:l,variant:i})),children:[jsx(Icon,{className:L({className:o?.search,variant:i}),children:jsx(Search,{})}),jsx(Input,{...p,className:composeRenderProps(o?.input,l=>g({className:l,variant:i})),type:"search"}),m?jsx(Icon,{className:A({className:o?.loading,variant:i}),children:jsx(Loop,{})}):jsx(Button,{className:composeRenderProps(o?.clear,l=>B({className:l,variant:i})),children:jsx(Icon,{children:jsx(CancelFill,{})})})]})})}d.displayName="SearchField",d.Provider=n;export{d as SearchField,c as SearchFieldContext};//# sourceMappingURL=index.js.map
2
4
  //# sourceMappingURL=index.js.map
@@ -1,2 +1,2 @@
1
- import {tv}from'./../../lib/utils.js';const i={variant:"outlined"},o=tv({slots:{field:["group/search-field fg-primary-bold flex items-center gap-s rounded-round p-s outline","focus-visible-within:outline-accent-primary-bold","hover:outline-interactive-hover","disabled:fg-disabled disabled:placeholder:fg-disabled disabled:cursor-not-allowed disabled:outline-interactive-disabled"],input:["hide-cancel block w-full font-display text-body-s outline-none","placeholder:fg-primary-muted","disabled:cursor-not-allowed"],clear:["fg-info-bold cursor-pointer","focus-visible:fg-info-hover","hover:fg-info-hover","group-empty/search-field:invisible group-disabled/search-field:invisible"],loading:"motion-safe:animate-spin",search:""},variants:{variant:{filled:{field:"bg-surface-raised outline-static"},outlined:{field:"outline-interactive"}}},defaultVariants:i});export{o as SearchFieldStyles,i as SearchFieldStylesDefaults};//# sourceMappingURL=styles.js.map
1
+ import {tv}from'./../../lib/utils.js';const i={variant:"outlined"},o=tv({slots:{field:["group/search-field fg-primary-bold flex items-center gap-s rounded-round p-s outline","focus-visible-within:outline-accent-primary-bold","hover:outline-interactive-hover","pressed:outline-interactive-pressed","disabled:fg-disabled disabled:placeholder:fg-disabled disabled:cursor-not-allowed disabled:outline-interactive-disabled"],input:["hide-cancel block w-full font-display text-body-s outline-none","placeholder:fg-primary-muted","disabled:cursor-not-allowed"],clear:["fg-info-bold cursor-pointer","focus-visible:fg-info-hover","hover:fg-info-hover","group-empty/search-field:invisible group-disabled/search-field:invisible"],loading:"motion-safe:animate-spin",search:""},variants:{variant:{filled:{field:"bg-surface-raised outline-static"},outlined:{field:"outline-interactive"}}},defaultVariants:i});export{o as SearchFieldStyles,i as SearchFieldStylesDefaults};//# sourceMappingURL=styles.js.map
2
2
  //# sourceMappingURL=styles.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/search-field/styles.ts"],"names":["e"],"mappings":"sCAeE,MAAA,CAAS,CAAA,CAAA,OAAA,CACX,UAGE,CAAA,CAAA,CAAO,CACLA,EAAA,CAAA,CAAA,KACE,CAAA,CAAA,KAAA,CAAA,CAAA,sFACA,CAAA,kDACA,CAAA,iCACA,CAAA,yHAGA,CAAA,CAAA,KAAA,CAAA,CAAA,gEACA,CAAA,8BACA,CAAA,6BAGA,CAAA,CAAA,KAAA,CAAA,CAAA,6BACA,CAAA,6BACA,CAAA,qBACA,CAAA,0EAEO,CAAA,CAAA,OAAA,CAAA,0BAEX,CAAA,MACA,CAAA,EAAA,CAAU,CACR,QAAS,CACP,CAAA,OACE,CAAA,CAAA,MAAO,CAAA,CAAA,KAAA,CAAA,kCAET,CAAU,CACR,QAAO,CAAA,CAAA,KAAA,CAAA,qBAIb,CAAA,CAAA,CAAA,CAAA,eACD,CAAA,CAAA,CAAA","file":"styles.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport { tv } from '@/lib/utils';\n\nexport const SearchFieldStylesDefaults = {\n variant: 'outlined',\n} as const;\n\nexport const SearchFieldStyles = tv({\n slots: {\n field: [\n 'group/search-field fg-primary-bold flex items-center gap-s rounded-round p-s outline',\n 'focus-visible-within:outline-accent-primary-bold',\n 'hover:outline-interactive-hover',\n 'disabled:fg-disabled disabled:placeholder:fg-disabled disabled:cursor-not-allowed disabled:outline-interactive-disabled',\n ],\n input: [\n 'hide-cancel block w-full font-display text-body-s outline-none',\n 'placeholder:fg-primary-muted',\n 'disabled:cursor-not-allowed',\n ],\n clear: [\n 'fg-info-bold cursor-pointer',\n 'focus-visible:fg-info-hover',\n 'hover:fg-info-hover',\n 'group-empty/search-field:invisible group-disabled/search-field:invisible',\n ],\n loading: 'motion-safe:animate-spin',\n search: '',\n },\n variants: {\n variant: {\n filled: {\n field: 'bg-surface-raised outline-static',\n },\n outlined: {\n field: 'outline-interactive',\n },\n },\n },\n defaultVariants: SearchFieldStylesDefaults,\n});\n"]}
1
+ {"version":3,"sources":["../../../src/components/search-field/styles.ts"],"names":["e"],"mappings":"sCAeE,MAAA,CAAS,CAAA,CAAA,OAAA,CACX,UAGE,CAAA,CAAA,CAAO,CACLA,EAAA,CAAA,CAAA,KACE,CAAA,CAAA,KAAA,CAAA,CAAA,sFACA,CAAA,kDACA,CAAA,iCACA,CAAA,qCACA,CAAA,yHAGA,CAAA,CAAA,KAAA,CAAA,CAAA,gEACA,CAAA,8BACA,CAAA,6BAGA,CAAA,CAAA,KAAA,CAAA,CAAA,6BACA,CAAA,6BACA,CAAA,qBACA,CAAA,0EAEO,CAAA,CAAA,OAAA,CAAA,0BAEX,CAAA,MACA,CAAA,EAAA,CAAU,CACR,QAAS,CACP,CAAA,OACE,CAAA,CAAA,MAAO,CAAA,CAAA,KAAA,CAAA,kCAET,CAAU,CACR,QAAO,CAAA,CAAA,KAAA,CAAA,qBAIb,CAAA,CAAA,CAAA,CAAA,eACD,CAAA,CAAA,CAAA","file":"styles.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport { tv } from '@/lib/utils';\n\nexport const SearchFieldStylesDefaults = {\n variant: 'outlined',\n} as const;\n\nexport const SearchFieldStyles = tv({\n slots: {\n field: [\n 'group/search-field fg-primary-bold flex items-center gap-s rounded-round p-s outline',\n 'focus-visible-within:outline-accent-primary-bold',\n 'hover:outline-interactive-hover',\n 'pressed:outline-interactive-pressed',\n 'disabled:fg-disabled disabled:placeholder:fg-disabled disabled:cursor-not-allowed disabled:outline-interactive-disabled',\n ],\n input: [\n 'hide-cancel block w-full font-display text-body-s outline-none',\n 'placeholder:fg-primary-muted',\n 'disabled:cursor-not-allowed',\n ],\n clear: [\n 'fg-info-bold cursor-pointer',\n 'focus-visible:fg-info-hover',\n 'hover:fg-info-hover',\n 'group-empty/search-field:invisible group-disabled/search-field:invisible',\n ],\n loading: 'motion-safe:animate-spin',\n search: '',\n },\n variants: {\n variant: {\n filled: {\n field: 'bg-surface-raised outline-static',\n },\n outlined: {\n field: 'outline-interactive',\n },\n },\n },\n defaultVariants: SearchFieldStylesDefaults,\n});\n"]}
@@ -1,2 +1,4 @@
1
+ 'use client';
2
+
1
3
  import {jsx,jsxs,Fragment}from'react/jsx-runtime';import'client-only';import V from'@accelint/icons/chevron-down';import {createContext}from'react';import {useContextProps,Select,composeRenderProps,SelectValue,Text,FieldError,Popover,Virtualizer,ListLayout}from'react-aria-components';import {Button}from'../button/index.js';import {Icon}from'../icon/index.js';import {Label}from'../label/index.js';import {Options}from'../options/index.js';import {SelectFieldStyles}from'./styles.js';const {description:k,error:G,trigger:J,label:d,field:K,value:Q}=SelectFieldStyles(),m=createContext(null);function u({children:o,...t}){return jsx(m.Provider,{value:t,children:o})}u.displayName="SelectField.Provider";function P({ref:o,...t}){[t,o]=useContextProps(t,o??null,m);const{size:i="medium",children:S,classNames:r,description:n,errorMessage:f,label:N,layoutOptions:F,isInvalid:y,...g}=t,c=f||null,p=i==="small",b=!p&&!!d;return jsx(Select,{...g,ref:o,className:composeRenderProps(r?.field,s=>K({className:s})),isInvalid:y||(c?true:void 0),"data-size":i,children:composeRenderProps(S,(s,{isRequired:x,isDisabled:C,isInvalid:L})=>jsxs(Fragment,{children:[b&&jsx(Label,{className:d({className:r?.label}),isRequired:x,isDisabled:C,children:N}),jsxs(Button,{className:composeRenderProps(r?.trigger,a=>J({className:a})),variant:"outline",size:i,children:[jsx(SelectValue,{className:Q({className:r?.value})}),jsx(Icon,{children:jsx(V,{className:"transform group-open/select-field:rotate-180"})})]}),!!n&&!(p||L)&&jsx(Text,{className:k({className:r?.description}),slot:"description",children:n}),jsx(FieldError,{className:composeRenderProps(r?.error,a=>G({className:a})),children:c}),jsx(Popover,{className:"min-w-(--trigger-width)",children:jsx(Virtualizer,{layout:ListLayout,layoutOptions:F,children:jsx(Options,{children:s})})})]}))})}P.displayName="SelectField",P.Provider=u;export{P as SelectField,m as SelectFieldContext};//# sourceMappingURL=index.js.map
2
4
  //# sourceMappingURL=index.js.map
@@ -21,7 +21,6 @@ type SelectFieldProps = Omit<SelectProps, 'className'> & Pick<VirtualizerProps<L
21
21
  description?: string;
22
22
  errorMessage?: string;
23
23
  size?: 'medium' | 'small';
24
- isReadOnly?: boolean;
25
24
  };
26
25
 
27
26
  export type { SelectFieldProps };
@@ -1,19 +1,22 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { SidenavProps, SidenavTriggerProps, SidenavHeaderProps, SidenavItemProps, SidenavLinkProps, SidenavDividerProps, SidenavAvatarProps, SidenavFooterProps, SidenavContentProps } from './types.js';
2
+ import { SidenavProps, SidenavTriggerProps, SidenavHeaderProps, SidenavItemProps, SidenavLinkProps, SidenavAvatarProps, SidenavFooterProps, SidenavContentProps, SidenavMenuProps, SidenavMenuItemProps } from './types.js';
3
+ import '@accelint/bus';
4
+ import '@accelint/core';
3
5
  import 'react';
4
6
  import 'react-aria-components';
7
+ import './events.js';
5
8
 
6
- declare function Sidenav({ className, isHiddenWhenClosed, children, ...rest }: SidenavProps): react_jsx_runtime.JSX.Element | null;
9
+ declare function Sidenav({ id, className, isHiddenWhenClosed, children, ...rest }: SidenavProps): react_jsx_runtime.JSX.Element | null;
7
10
  declare namespace Sidenav {
8
11
  var displayName: string;
9
12
  var Trigger: typeof SidenavTrigger;
10
13
  var Header: typeof SidenavHeader;
11
14
  var Item: typeof SidenavItem;
12
15
  var Link: typeof SidenavLink;
13
- var Divider: typeof SidenavDivider;
14
16
  var Avatar: typeof SidenavAvatar;
15
17
  var Footer: typeof SidenavFooter;
16
18
  var Content: typeof SidenavContent;
19
+ var Menu: typeof SidenavMenu;
17
20
  }
18
21
  declare function SidenavContent({ className, children, ...rest }: SidenavContentProps): react_jsx_runtime.JSX.Element;
19
22
  declare namespace SidenavContent {
@@ -27,7 +30,7 @@ declare function SidenavFooter(props: SidenavFooterProps): react_jsx_runtime.JSX
27
30
  declare namespace SidenavFooter {
28
31
  var displayName: string;
29
32
  }
30
- declare function SidenavTrigger({ children, ...rest }: SidenavTriggerProps): react_jsx_runtime.JSX.Element;
33
+ declare function SidenavTrigger({ children, for: type, ...rest }: SidenavTriggerProps): react_jsx_runtime.JSX.Element;
31
34
  declare namespace SidenavTrigger {
32
35
  var displayName: string;
33
36
  }
@@ -39,13 +42,18 @@ declare function SidenavLink({ children, classNames, textValue, ...rest }: Siden
39
42
  declare namespace SidenavLink {
40
43
  var displayName: string;
41
44
  }
42
- declare function SidenavDivider({ className, ...rest }: SidenavDividerProps): react_jsx_runtime.JSX.Element;
43
- declare namespace SidenavDivider {
44
- var displayName: string;
45
- }
46
45
  declare function SidenavAvatar({ children, className, ...rest }: SidenavAvatarProps): react_jsx_runtime.JSX.Element;
47
46
  declare namespace SidenavAvatar {
48
47
  var displayName: string;
49
48
  }
49
+ declare function SidenavMenu({ icon, title, classNames, children, ...rest }: SidenavMenuProps): react_jsx_runtime.JSX.Element;
50
+ declare namespace SidenavMenu {
51
+ var displayName: string;
52
+ var Item: typeof SidenavMenuItem;
53
+ }
54
+ declare function SidenavMenuItem({ className, children, ...rest }: SidenavMenuItemProps): react_jsx_runtime.JSX.Element;
55
+ declare namespace SidenavMenuItem {
56
+ var displayName: string;
57
+ }
50
58
 
51
59
  export { Sidenav };
@@ -1,2 +1,4 @@
1
- import {jsx,jsxs,Fragment}from'react/jsx-runtime';import'client-only';import {useOn,useEmit}from'@accelint/bus/react';import {ChevronLeft,ArrowNortheast}from'@accelint/icons';import {createContext,useState,useContext,useRef}from'react';import {Provider,HeadingContext,Header,Button,Pressable,Text,TextContext,ToggleButton,Link,composeRenderProps,Heading}from'react-aria-components';import {containsExactChildren,containsAnyOfExactChildren}from'./../../lib/react.js';import {Icon,IconContext}from'../icon/index.js';import {Tooltip}from'../tooltip/index.js';import {SidenavEventTypes}from'./events.js';import {SidenavStyles}from'./styles.js';const{sidenav:X,content:Y,header:Z,toggle:_,heading:$,divider:j,item:ee,text:D,transient:m,avatar:ae,avatarHeading:ne,avatarIcon:ie,avatarText:te,link:oe,tooltip:h}=SidenavStyles(),x=createContext({open:false});function t({className:a,isHiddenWhenClosed:n,children:i,...o}){containsExactChildren({children:i,componentName:t.displayName,restrictions:[[T,{min:1,max:1}],[y,{min:1,max:1}],[C,{min:0,max:1}]]});const[r,s]=useState(false);return useOn(SidenavEventTypes.toggle,()=>s(u=>!u)),n&&!r?null:jsx(Provider,{values:[[HeadingContext,{className:$({className:m()})}],[x,{open:r}]],children:jsx("nav",{...o,className:X({className:a}),"data-open":r||null,children:i})})}t.displayName="Sidenav";function y({className:a,children:n,...i}){return jsx("div",{...i,className:Y({className:a}),children:n})}y.displayName="Sidenav.Content";function T({children:a,classNames:n,...i}){const o=useEmit(SidenavEventTypes.toggle);return jsx(Header,{...i,className:Z({className:n?.header}),children:jsxs(Button,{className:_({className:n?.button}),onPress:()=>o(),children:[a,jsx(Icon,{className:m(),children:jsx(ChevronLeft,{})})]})})}T.displayName="Sidenav.Header";function C(a){return jsx("footer",{...a})}C.displayName="Sidenav.Footer";function z({children:a,...n}){const i=useEmit(SidenavEventTypes.toggle);return jsx(Pressable,{...n,onPress:()=>i(),children:a})}z.displayName="Sidenav.Trigger";function I({children:a,classNames:n,textValue:i,...o}){containsAnyOfExactChildren({children:a,componentName:I.displayName,restrictions:[[[c,{min:1,max:1}]],[[Icon,{min:1,max:1}],[Text,{min:1,max:1}]]]});const{open:r}=useContext(x),s=useRef(null);return jsx(Provider,{values:[[IconContext,{size:"medium"}],[TextContext,{className:D({className:m()})}]],children:jsxs(Tooltip,{isDisabled:r,children:[jsx(Tooltip.Trigger,{children:jsx(ToggleButton,{...o,ref:s,className:ee({className:n?.button}),children:a})}),jsx(Tooltip.Body,{parentRef:s,placement:"right",className:h(),children:i})]})})}I.displayName="Sidenav.Item";function H({children:a,classNames:n,textValue:i,...o}){containsExactChildren({children:a,componentName:H.displayName,restrictions:[[Icon,{min:1,max:1}],[Text,{min:1,max:1}]]});const{open:r}=useContext(x),s=useRef(null);return jsx(Provider,{values:[[IconContext,{size:"medium",slot:"icon"}],[TextContext,{className:D({className:m()})}]],children:jsxs(Tooltip,{isDisabled:r,children:[jsx(Tooltip.Trigger,{children:jsx(Link,{...o,ref:s,className:oe({className:n?.button}),children:composeRenderProps(a,u=>jsxs(Fragment,{children:[u,jsx(Icon,{size:"medium",className:m(),children:jsx(ArrowNortheast,{})})]}))})}),jsxs(Tooltip.Body,{parentRef:s,placement:"right",className:h(),children:[i,jsx(Icon,{size:"medium",children:jsx(ArrowNortheast,{})})]})]})})}H.displayName="Sidenav.Link";function F({className:a,...n}){return jsx("hr",{...n,className:j({className:a})})}F.displayName="Sidenav.Divider";function c({children:a,className:n,...i}){return containsExactChildren({children:a,componentName:c.displayName,restrictions:[[Icon,{min:1,max:1}],[Heading,{min:1,max:1}],[Text,{min:1,max:1}]]}),jsx(Provider,{values:[[IconContext,{size:"large",className:ie()}],[HeadingContext,{className:ne({className:m()})}],[TextContext,{className:te({className:m()})}]],children:jsx("div",{...i,className:ae({className:n}),children:a})})}c.displayName="Sidenav.Avatar",t.Trigger=z,t.Header=T,t.Item=I,t.Link=H,t.Divider=F,t.Avatar=c,t.Footer=C,t.Content=y;export{t as Sidenav};//# sourceMappingURL=index.js.map
1
+ 'use client';
2
+
3
+ import {jsx,jsxs,Fragment}from'react/jsx-runtime';import'client-only';import {useOn,useEmit}from'@accelint/bus/react';import {uuid,isUUID}from'@accelint/core';import {ChevronLeft,ArrowNortheast,ChevronDown}from'@accelint/icons';import {createContext,useState,useContext,useRef}from'react';import {Provider,HeadingContext,DEFAULT_SLOT,Header,Button,composeRenderProps,Pressable,Text,TextContext,ToggleButton,Link,Heading,Disclosure,DisclosurePanel,DialogTrigger,Popover}from'react-aria-components';import {containsExactChildren,containsAnyOfExactChildren}from'./../../lib/react.js';import {Avatar,AvatarContext}from'../avatar/index.js';import {DividerContext}from'../divider/index.js';import {Icon,IconContext}from'../icon/index.js';import {Tooltip}from'../tooltip/index.js';import {SidenavEventTypes}from'./events.js';import {SidenavStyles}from'./styles.js';const{sidenav:pe,content:ve,header:ce,toggle:ue,heading:ge,divider:Ne,item:Se,text:z,transient:c,avatar:fe,avatarHeading:Pe,avatarIcon:V,avatarText:Te,link:xe,tooltip:O,menu:ye,menuButton:_,menuHeading:Ce,menuPanel:Ie,menuItem:Be,panelHeading:Ee,panelContent:G}=SidenavStyles(),f=createContext({id:uuid(),isOpen:false});function d({id:a,className:o,isHiddenWhenClosed:n,children:i,...r}){containsExactChildren({children:i,componentName:d.displayName,restrictions:[[A,{min:1,max:1}],[b,{min:1,max:1}],[L,{min:0,max:1}]]});const[t,m]=useState(false);return useOn(SidenavEventTypes.toggle,s=>{s.payload.id===a&&m(K=>!K);}),useOn(SidenavEventTypes.open,s=>{!t&&s.payload.id===a&&m(true);}),useOn(SidenavEventTypes.close,s=>{t&&s.payload.id===a&&m(false);}),n&&!t?null:jsx(Provider,{values:[[HeadingContext,{slots:{[DEFAULT_SLOT]:{className:ge({className:c()})},menu:{className:Ce({className:c()})},panel:{className:Ee()}}}],[f,{id:a,isOpen:t}]],children:jsx("nav",{...r,className:pe({className:o}),"data-open":t||null,children:i})})}d.displayName="Sidenav";function b({className:a,children:o,...n}){return jsx(Provider,{values:[[DividerContext,{className:Ne()}]],children:jsx("div",{...n,className:ve({className:a}),children:o})})}b.displayName="Sidenav.Content";function A({children:a,classNames:o,...n}){const i=useEmit(SidenavEventTypes.toggle),{id:r}=useContext(f);return jsx(Header,{...n,className:ce({className:o?.header}),children:jsxs(Button,{className:composeRenderProps(o?.button,t=>ue({className:t})),onPress:()=>i({id:r}),children:[a,jsx(Icon,{className:c(),children:jsx(ChevronLeft,{})})]})})}A.displayName="Sidenav.Header";function L(a){return jsx("footer",{...a})}L.displayName="Sidenav.Footer";function J({children:a,for:o,...n}){const[i,r]=isUUID(o)?["toggle",o]:o.split(":"),t=useEmit(SidenavEventTypes[i]);return jsx(Pressable,{...n,onPress:()=>t({id:r}),children:a})}J.displayName="Sidenav.Trigger";function M({children:a,classNames:o,textValue:n,...i}){containsAnyOfExactChildren({children:a,componentName:M.displayName,restrictions:[[[y,{min:1,max:1}]],[[Icon,{min:1,max:1}],[Text,{min:1,max:1}]]]});const{isOpen:r}=useContext(f),t=useRef(null);return jsx(Provider,{values:[[IconContext,{size:"medium"}],[TextContext,{className:z({className:c()})}]],children:jsxs(Tooltip,{isDisabled:r,children:[jsx(Tooltip.Trigger,{children:jsx(ToggleButton,{...i,ref:t,className:composeRenderProps(o?.button,m=>Se({className:m})),children:a})}),jsx(Tooltip.Body,{parentRef:t,placement:"right",className:O(),children:n})]})})}M.displayName="Sidenav.Item";function k({children:a,classNames:o,textValue:n,...i}){containsExactChildren({children:a,componentName:k.displayName,restrictions:[[Icon,{min:1,max:1}],[Text,{min:1,max:1}]]});const{isOpen:r}=useContext(f),t=useRef(null);return jsx(Provider,{values:[[TextContext,{className:z({className:c()})}]],children:jsxs(Tooltip,{isDisabled:r,children:[jsx(Tooltip.Trigger,{children:jsx(Link,{...i,ref:t,className:composeRenderProps(o?.button,m=>xe({className:m})),children:composeRenderProps(a,m=>jsxs(Fragment,{children:[m,jsx(Icon,{className:c(),children:jsx(ArrowNortheast,{})})]}))})}),jsxs(Tooltip.Body,{parentRef:t,placement:"right",className:O(),children:[n,jsx(Icon,{children:jsx(ArrowNortheast,{})})]})]})})}k.displayName="Sidenav.Link";function y({children:a,className:o,...n}){return containsAnyOfExactChildren({children:a,componentName:y.displayName,restrictions:[[[Avatar,{min:1,max:1}],[Heading,{min:1,max:1}],[Text,{min:0,max:1}]],[[Icon,{min:1,max:1}],[Heading,{min:1,max:1}],[Text,{min:0,max:1}]]]}),jsx(Provider,{values:[[IconContext,{size:"large",className:V()}],[HeadingContext,{className:Pe({className:c()})}],[TextContext,{className:Te({className:c()})}],[AvatarContext,{classNames:{avatar:V()}}]],children:jsx("div",{...n,className:fe({className:o}),children:a})})}y.displayName="Sidenav.Avatar";function C({icon:a,title:o,classNames:n,children:i,...r}){containsExactChildren({children:i,componentName:C.displayName,restrictions:[[I,{min:2}]]});const{isOpen:t}=useContext(f),m=useRef(null);return t?jsxs(Disclosure,{className:composeRenderProps(n?.menu,s=>ye({className:s})),children:[jsxs(Button,{...r,slot:"trigger",className:composeRenderProps(n?.button,s=>_({className:s})),children:[a,jsx(Heading,{slot:"menu",children:o}),jsx(Icon,{className:c({className:n?.icon}),children:jsx(ChevronDown,{className:"transform group-expanded/menu:rotate-180"})})]}),jsx(DisclosurePanel,{className:composeRenderProps(n?.disclosurePanel,s=>s??""),children:jsx("div",{className:G({className:n?.panelContent}),children:i})})]}):jsxs(DialogTrigger,{children:[jsxs(Tooltip,{isDisabled:t,children:[jsx(Tooltip.Trigger,{children:jsx(Button,{...r,ref:m,className:composeRenderProps(n?.button,s=>_({className:s})),children:a})}),jsx(Tooltip.Body,{parentRef:m,placement:"right",className:O(),children:o})]}),jsxs(Popover,{className:composeRenderProps(n?.popoverPanel,s=>Ie({className:s})),placement:"right top",shouldFlip:false,children:[jsx(Heading,{slot:"panel",children:o}),jsx("div",{className:G({className:n?.panelContent}),children:i})]})]})}C.displayName="Sidenav.Menu";function I({className:a,children:o,...n}){return containsExactChildren({children:o,componentName:I.displayName,restrictions:[[Text,{min:1,max:1}]]}),jsx(ToggleButton,{...n,className:composeRenderProps(a,i=>Be({className:i})),children:o})}I.displayName="Sidenav.Menu.Item",C.Item=I,d.Trigger=J,d.Header=A,d.Item=M,d.Link=k,d.Avatar=y,d.Footer=L,d.Content=b,d.Menu=C;export{d as Sidenav};//# sourceMappingURL=index.js.map
2
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/sidenav/index.tsx"],"names":["toggle","heading","divider","item","transient","avatar","avatarHeading","avatarIcon","link","SidenavContext","W","className","rest","Sidenav","g","SidenavFooter","open","setOpen","useState","useOn","SidenavEventTypes","prev","isHiddenWhenClosed","Provider","P","e","A","sidenav","SidenavContent","jsx","content","children","emit","Header","k","header","G","Button","classNames","v","w","SidenavHeader","R","SidenavTrigger","useEmit","Pressable","textValue","SidenavItem","U","Icon","Text","d","useContext","N","ref","IconContext","L","b","f","S","l","ToggleButton","SidenavLink","useRef","p","text","Link","jsxs","q","re","B","SidenavDivider","containsExactChildren","SidenavAvatar","HeadingContext","TextContext","avatarText"],"mappings":"goBAoDE,KAAAA,CACA,OAAA,CAAAC,CAAAA,CACA,OAAA,CAAAC,EACA,MAAAC,CAAAA,CACA,CAAA,MACA,CAAA,CAAA,CAAA,OAAAC,CAAAA,CACA,QAAAC,CAAAA,CACA,CAAA,IAAA,CAAA,EAAA,CAAA,IAAA,CAAAC,CAAAA,CAAAA,SACA,CAAA,CAAA,CAAAC,MACA,CAAA,EAAA,CAAA,aACAC,CAAAA,cAEgB,EAEZC,CAAAA,UAA4D,CAAM,EAAC,CAElE,IAAA,CAAA,EAAA,CAAA,OACL,CAAA,CAAA,CAAA,CAAAC,aAAA,EAAAC,CAAAA,CACA,sCACA,CAAA,CAAA,CAAA,SACGC,CACL,CAAA,CAAiB,kBAGb,CAAA,CAAA,CAAA,QAAeC,EAAQ,CAAA,GAAA,CAAA,CAAA,CAAA,CAAAC,qBAAA,CAAA,CAAA,QACvB,CAAA,CAAA,CAAA,aACyB,CAAG,CAAA,CAAA,WACP,CAAA,YACnB,CAACC,CAAAA,CAAe,CAAE,CAAA,CAAA,GAAK,CAAG,KAAO,CAAC,CACpC,CACF,CAAC,CAAA,CACD,MAAOC,CAAAA,CAAMC,CAAO,GAAIC,CAAS,CAAA,CAAK,EAItC,CAAA,CAAA,CAAA,CAAA,GAFAC,CAAAA,CAAMC,CAAAA,GAAkB,CAAA,CAAA,CAAA,CAAA,CAAQ,CAAA,CAAA,CAAA,MAAwB,CAACC,CAAI,CAAC,CAAA,CAE1DC,QAAAA,CAAAA,KAAuBN,EAClB,OAINO,KAAAA,CAAAC,iBACC,CAAA,MAAQ,CACN,IAAmB,CAAA,CAAA,CAAA,EA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sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n'use client';\n\nimport 'client-only';\nimport { useEmit, useOn } from '@accelint/bus/react';\nimport { ArrowNortheast, ChevronLeft } from '@accelint/icons';\nimport { createContext, useContext, useRef, useState } from 'react';\nimport {\n Button,\n composeRenderProps,\n Header,\n Heading,\n HeadingContext,\n Link,\n Pressable,\n Provider,\n Text,\n TextContext,\n ToggleButton,\n} from 'react-aria-components';\nimport { containsAnyOfExactChildren, containsExactChildren } from '@/lib/react';\nimport { Icon, IconContext } from '../icon';\nimport { Tooltip } from '../tooltip';\nimport { SidenavEventTypes } from './events';\nimport { SidenavStyles } from './styles';\nimport type {\n SidenavAvatarProps,\n SidenavContentProps,\n SidenavContextValue,\n SidenavDividerProps,\n SidenavFooterProps,\n SidenavHeaderProps,\n SidenavItemProps,\n SidenavLinkProps,\n SidenavProps,\n SidenavTriggerProps,\n} from './types';\n\nconst {\n sidenav,\n content,\n header,\n toggle,\n heading,\n divider,\n item,\n text,\n transient,\n avatar,\n avatarHeading,\n avatarIcon,\n avatarText,\n link,\n tooltip,\n} = SidenavStyles();\n\nconst SidenavContext = createContext<SidenavContextValue>({ open: false });\n\nexport function Sidenav({\n className,\n isHiddenWhenClosed,\n children,\n ...rest\n}: SidenavProps) {\n containsExactChildren({\n children,\n componentName: Sidenav.displayName,\n restrictions: [\n [SidenavHeader, { min: 1, max: 1 }],\n [SidenavContent, { min: 1, max: 1 }],\n [SidenavFooter, { min: 0, max: 1 }],\n ],\n });\n const [open, setOpen] = useState(false);\n\n useOn(SidenavEventTypes.toggle, () => setOpen((prev) => !prev));\n\n if (isHiddenWhenClosed && !open) {\n return null;\n }\n\n return (\n <Provider\n values={[\n [HeadingContext, { className: heading({ className: transient() }) }],\n [SidenavContext, { open }],\n ]}\n >\n <nav\n {...rest}\n className={sidenav({ className })}\n data-open={open || null}\n >\n {children}\n </nav>\n </Provider>\n );\n}\nSidenav.displayName = 'Sidenav';\n\nfunction SidenavContent({ className, children, ...rest }: SidenavContentProps) {\n return (\n <div {...rest} className={content({ className })}>\n {children}\n </div>\n );\n}\nSidenavContent.displayName = 'Sidenav.Content';\n\nfunction SidenavHeader({ children, classNames, ...rest }: SidenavHeaderProps) {\n const emit = useEmit(SidenavEventTypes.toggle);\n\n return (\n <Header {...rest} className={header({ className: classNames?.header })}>\n <Button\n className={toggle({ className: classNames?.button })}\n onPress={() => emit()}\n >\n {children}\n <Icon className={transient()}>\n <ChevronLeft />\n </Icon>\n </Button>\n </Header>\n );\n}\nSidenavHeader.displayName = 'Sidenav.Header';\n\nfunction SidenavFooter(props: SidenavFooterProps) {\n return <footer {...props} />;\n}\nSidenavFooter.displayName = 'Sidenav.Footer';\n\nfunction SidenavTrigger({ children, ...rest }: SidenavTriggerProps) {\n const emit = useEmit(SidenavEventTypes.toggle);\n\n return (\n <Pressable {...rest} onPress={() => emit()}>\n {children}\n </Pressable>\n );\n}\nSidenavTrigger.displayName = 'Sidenav.Trigger';\n\nfunction SidenavItem({\n children,\n classNames,\n textValue,\n ...rest\n}: SidenavItemProps) {\n containsAnyOfExactChildren({\n children,\n componentName: SidenavItem.displayName,\n restrictions: [\n [[SidenavAvatar, { min: 1, max: 1 }]],\n [\n [Icon, { min: 1, max: 1 }],\n [Text, { min: 1, max: 1 }],\n ],\n ],\n });\n\n const { open } = useContext(SidenavContext);\n\n // Implement ref to place tooltip inside Button DOM to enable contextual styling\n const ref = useRef(null);\n\n return (\n <Provider\n values={[\n [IconContext, { size: 'medium' }],\n [TextContext, { className: text({ className: transient() }) }],\n ]}\n >\n <Tooltip isDisabled={open}>\n <Tooltip.Trigger>\n <ToggleButton\n {...rest}\n ref={ref}\n className={item({ className: classNames?.button })}\n >\n {children}\n </ToggleButton>\n </Tooltip.Trigger>\n <Tooltip.Body parentRef={ref} placement='right' className={tooltip()}>\n {textValue}\n </Tooltip.Body>\n </Tooltip>\n </Provider>\n );\n}\nSidenavItem.displayName = 'Sidenav.Item';\n\nfunction SidenavLink({\n children,\n classNames,\n textValue,\n ...rest\n}: SidenavLinkProps) {\n containsExactChildren({\n children,\n componentName: SidenavLink.displayName,\n restrictions: [\n [Icon, { min: 1, max: 1 }],\n [Text, { min: 1, max: 1 }],\n ],\n });\n\n const { open } = useContext(SidenavContext);\n\n // Implement ref to place tooltip inside Link DOM to enable contextual styling\n const ref = useRef(null);\n\n return (\n <Provider\n values={[\n [IconContext, { size: 'medium', slot: 'icon' }],\n [TextContext, { className: text({ className: transient() }) }],\n ]}\n >\n <Tooltip isDisabled={open}>\n <Tooltip.Trigger>\n <Link\n {...rest}\n ref={ref}\n className={link({ className: classNames?.button })}\n >\n {composeRenderProps(children, (children) => (\n <>\n {children}\n <Icon size='medium' className={transient()}>\n <ArrowNortheast />\n </Icon>\n </>\n ))}\n </Link>\n </Tooltip.Trigger>\n <Tooltip.Body parentRef={ref} placement='right' className={tooltip()}>\n {textValue}\n <Icon size='medium'>\n <ArrowNortheast />\n </Icon>\n </Tooltip.Body>\n </Tooltip>\n </Provider>\n );\n}\nSidenavLink.displayName = 'Sidenav.Link';\n\nfunction SidenavDivider({ className, ...rest }: SidenavDividerProps) {\n return <hr {...rest} className={divider({ className })} />;\n}\nSidenavDivider.displayName = 'Sidenav.Divider';\n\nfunction SidenavAvatar({ children, className, ...rest }: SidenavAvatarProps) {\n containsExactChildren({\n children,\n componentName: SidenavAvatar.displayName,\n restrictions: [\n [Icon, { min: 1, max: 1 }],\n [Heading, { min: 1, max: 1 }],\n [Text, { min: 1, max: 1 }],\n ],\n });\n\n return (\n <Provider\n values={[\n [IconContext, { size: 'large', className: avatarIcon() }],\n [\n HeadingContext,\n { className: avatarHeading({ className: transient() }) },\n ],\n [TextContext, { className: avatarText({ className: transient() }) }],\n ]}\n >\n <div {...rest} className={avatar({ className })}>\n {children}\n </div>\n </Provider>\n );\n}\nSidenavAvatar.displayName = 'Sidenav.Avatar';\n\nSidenav.Trigger = SidenavTrigger;\nSidenav.Header = SidenavHeader;\nSidenav.Item = SidenavItem;\nSidenav.Link = SidenavLink;\nSidenav.Divider = SidenavDivider;\nSidenav.Avatar = SidenavAvatar;\nSidenav.Footer = SidenavFooter;\nSidenav.Content = SidenavContent;\n"]}
1
+ {"version":3,"sources":["../../../src/components/sidenav/index.tsx"],"names":["heading","item","text","transient","avatar","avatarIcon","menuItem","panelHeading","panelContent","SidenavStyles","uuid","Sidenav","className","de","Z","W","containsExactChildren","SidenavHeader","setIsOpen","useState","SidenavEventTypes","data","id","prev","useOn","isOpen","isHiddenWhenClosed","jsx","Provider","B","S","HeadingContext","e","g","R","j","SidenavContext","sidenav","children","SidenavContent","rest","content","le","useContext","classNames","P","Button","oe","p","H","emit","l","Icon","u","props","Y","SidenavFooter","SidenavTrigger","type","useEmit","event","Pressable","se","SidenavItem","SidenavAvatar","ref","N","IconContext","TextContext","E","w","jsxs","Tooltip","D","v","composeRenderProps","U","SidenavLink","useRef","te","He","h","tooltip","Avatar","Heading","T","Text","avatarHeading","avatarText","AvatarContext","me","SidenavMenu","title","SidenavMenuItem","Disclosure","menu","X","ne","ee","icon","menuPanel","ie"],"mappings":"01BAkEEA,KACA,CAAA,OACA,CAAA,EAAA,CAAAC,OACA,CAAAC,EACA,UAAAC,CAAAA,MACA,CAAA,EAAAC,CAAAA,OACA,CAAA,EAAA,CAAA,OACA,CAAA,EAAA,CAAA,IAAA,CAAA,EAAAC,CAAAA,IACA,CAAA,CAAA,CAAA,kBAEA,CAAA,EAAA,CAAA,2BAGA,CAAA,CAAA,CAAA,UACA,CAAA,EAAA,CAAA,IAAA,CAAA,UACA,CAAA,C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EAAA,YAE1B,CAAA,CAASuD,SACP,CAAA,CAAA,CAAA,CAAAjF,CAAAA,CACA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,WAGA,yBAEE,CAAA,CAAA,CAAA,SAA+B,CAAA,CAAA,CAAA,QAAA,CAC/B,CAAA,CAAA,GAAA,CAAA,CAAA,CAAA,CAAA,4BAAsB,CAAE,CAAA,QAAQ,CAAK,CAAE,CAAC,aAKlC4B,CAAAA,CACJ,YAA8B5B,CAAAA,YACjB,CAAA,CAAA,CAAAsD,IAAA,CAAA,CAAAtD,GACb,EAEC,CAAA,GAAA,CAAA,CAAA,CAAA,CAAA,CAAA0B,CAAAA,CACH,CAEJN,GACA6D,aAAgB,CAAA,CAAA,GAAA,CAAA,CAAA,SAAc,CAAA1C,kBAAA,CAAA,CAAA,CAAA,CAAA,EAAA,EAAA,CAAA,CAAA,SAElB,CAAA,CAAO0C,CAAAA,CAEnBlF,EAAQ,QAAU8C,CAAAA,CAClB9C,CAAAA,CAAQ,CAAA,CAAA,CAAA,WACA,CAAA,mBAEA,CAAA,CAASqD,CAAAA,IACT,CAAA,CAAA,CAAA,CAAA,CAAA,OACA,CAAA,CAAA,CAAA,CAAA,CAAA,MACA,CAAA,CAAA,CAAA,CAAO2B,CAAAA,IAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,IAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,MAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,MAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,OAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,IAAAA,CAAAA,CAAAA","file":"index.js","sourcesContent":["/*\n * Copyright 2025 Hypergiant Galactic Systems Inc. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at https://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n'use client';\n\nimport 'client-only';\nimport { useEmit, useOn } from '@accelint/bus/react';\nimport { isUUID, type UniqueId, uuid } from '@accelint/core';\nimport { ArrowNortheast, ChevronDown, ChevronLeft } from '@accelint/icons';\nimport { createContext, useContext, useRef, useState } from 'react';\nimport {\n Button,\n composeRenderProps,\n DEFAULT_SLOT,\n DialogTrigger,\n Disclosure,\n DisclosurePanel,\n Header,\n Heading,\n HeadingContext,\n Link,\n Popover,\n Pressable,\n Provider,\n Text,\n TextContext,\n ToggleButton,\n} from 'react-aria-components';\nimport { containsAnyOfExactChildren, containsExactChildren } from '@/lib/react';\nimport { Avatar, AvatarContext } from '../avatar';\nimport { DividerContext } from '../divider';\nimport { Icon, IconContext } from '../icon';\nimport { Tooltip } from '../tooltip';\nimport { SidenavEventTypes } from './events';\nimport { SidenavStyles } from './styles';\nimport type {\n SidenavAvatarProps,\n SidenavCloseEvent,\n SidenavContentProps,\n SidenavContextValue,\n SidenavEvent,\n SidenavFooterProps,\n SidenavHeaderProps,\n SidenavItemProps,\n SidenavLinkProps,\n SidenavMenuItemProps,\n SidenavMenuProps,\n SidenavOpenEvent,\n SidenavProps,\n SidenavToggleEvent,\n SidenavTriggerProps,\n} from './types';\n\nconst {\n sidenav,\n content,\n header,\n toggle,\n heading,\n divider,\n item,\n text,\n transient,\n avatar,\n avatarHeading,\n avatarIcon,\n avatarText,\n link,\n tooltip,\n menu,\n menuButton,\n menuHeading,\n menuPanel,\n menuItem,\n panelHeading,\n panelContent,\n} = SidenavStyles();\n\nconst SidenavContext = createContext<SidenavContextValue>({\n id: uuid(),\n isOpen: false,\n});\n\nexport function Sidenav({\n id,\n className,\n isHiddenWhenClosed,\n children,\n ...rest\n}: SidenavProps) {\n containsExactChildren({\n children,\n componentName: Sidenav.displayName,\n restrictions: [\n [SidenavHeader, { min: 1, max: 1 }],\n [SidenavContent, { min: 1, max: 1 }],\n [SidenavFooter, { min: 0, max: 1 }],\n ],\n });\n const [isOpen, setIsOpen] = useState(false);\n\n useOn(SidenavEventTypes.toggle, (data: SidenavToggleEvent) => {\n if (data.payload.id === id) {\n setIsOpen((prev) => !prev);\n }\n });\n\n useOn(SidenavEventTypes.open, (data: SidenavOpenEvent) => {\n if (!isOpen && data.payload.id === id) {\n setIsOpen(true);\n }\n });\n\n useOn(SidenavEventTypes.close, (data: SidenavCloseEvent) => {\n if (isOpen && data.payload.id === id) {\n setIsOpen(false);\n }\n });\n\n if (isHiddenWhenClosed && !isOpen) {\n return null;\n }\n\n return (\n <Provider\n values={[\n [\n HeadingContext,\n {\n slots: {\n [DEFAULT_SLOT]: {\n className: heading({ className: transient() }),\n },\n menu: { className: menuHeading({ className: transient() }) },\n panel: { className: panelHeading() },\n },\n },\n ],\n [SidenavContext, { id, isOpen }],\n ]}\n >\n <nav\n {...rest}\n className={sidenav({ className })}\n data-open={isOpen || null}\n >\n {children}\n </nav>\n </Provider>\n );\n}\nSidenav.displayName = 'Sidenav';\n\nfunction SidenavContent({ className, children, ...rest }: SidenavContentProps) {\n return (\n <Provider values={[[DividerContext, { className: divider() }]]}>\n <div {...rest} className={content({ className })}>\n {children}\n </div>\n </Provider>\n );\n}\nSidenavContent.displayName = 'Sidenav.Content';\n\nfunction SidenavHeader({ children, classNames, ...rest }: SidenavHeaderProps) {\n const emit = useEmit<SidenavToggleEvent>(SidenavEventTypes.toggle);\n const { id } = useContext(SidenavContext);\n\n return (\n <Header {...rest} className={header({ className: classNames?.header })}>\n <Button\n className={composeRenderProps(classNames?.button, (className) =>\n toggle({ className }),\n )}\n onPress={() => emit({ id })}\n >\n {children}\n <Icon className={transient()}>\n <ChevronLeft />\n </Icon>\n </Button>\n </Header>\n );\n}\nSidenavHeader.displayName = 'Sidenav.Header';\n\nfunction SidenavFooter(props: SidenavFooterProps) {\n return <footer {...props} />;\n}\nSidenavFooter.displayName = 'Sidenav.Footer';\n\nfunction SidenavTrigger({ children, for: type, ...rest }: SidenavTriggerProps) {\n const [event, id] = (isUUID(type) ? ['toggle', type] : type.split(':')) as [\n 'close' | 'open' | 'toggle',\n UniqueId,\n ];\n const emit = useEmit<SidenavEvent>(SidenavEventTypes[event]);\n\n return (\n <Pressable {...rest} onPress={() => emit({ id })}>\n {children}\n </Pressable>\n );\n}\nSidenavTrigger.displayName = 'Sidenav.Trigger';\n\nfunction SidenavItem({\n children,\n classNames,\n textValue,\n ...rest\n}: SidenavItemProps) {\n containsAnyOfExactChildren({\n children,\n componentName: SidenavItem.displayName,\n restrictions: [\n [[SidenavAvatar, { min: 1, max: 1 }]],\n [\n [Icon, { min: 1, max: 1 }],\n [Text, { min: 1, max: 1 }],\n ],\n ],\n });\n\n const { isOpen } = useContext(SidenavContext);\n\n // Implement ref to place tooltip inside Button DOM to enable contextual styling\n const ref = useRef(null);\n\n return (\n <Provider\n values={[\n [IconContext, { size: 'medium' }],\n [TextContext, { className: text({ className: transient() }) }],\n ]}\n >\n <Tooltip isDisabled={isOpen}>\n <Tooltip.Trigger>\n <ToggleButton\n {...rest}\n ref={ref}\n className={composeRenderProps(classNames?.button, (className) =>\n item({ className }),\n )}\n >\n {children}\n </ToggleButton>\n </Tooltip.Trigger>\n <Tooltip.Body parentRef={ref} placement='right' className={tooltip()}>\n {textValue}\n </Tooltip.Body>\n </Tooltip>\n </Provider>\n );\n}\nSidenavItem.displayName = 'Sidenav.Item';\n\nfunction SidenavLink({\n children,\n classNames,\n textValue,\n ...rest\n}: SidenavLinkProps) {\n containsExactChildren({\n children,\n componentName: SidenavLink.displayName,\n restrictions: [\n [Icon, { min: 1, max: 1 }],\n [Text, { min: 1, max: 1 }],\n ],\n });\n\n const { isOpen } = useContext(SidenavContext);\n\n // Implement ref to place tooltip inside Link DOM to enable contextual styling\n const ref = useRef(null);\n\n return (\n <Provider\n values={[[TextContext, { className: text({ className: transient() }) }]]}\n >\n <Tooltip isDisabled={isOpen}>\n <Tooltip.Trigger>\n <Link\n {...rest}\n ref={ref}\n className={composeRenderProps(classNames?.button, (className) =>\n link({ className }),\n )}\n >\n {composeRenderProps(children, (children) => (\n <>\n {children}\n <Icon className={transient()}>\n <ArrowNortheast />\n </Icon>\n </>\n ))}\n </Link>\n </Tooltip.Trigger>\n <Tooltip.Body parentRef={ref} placement='right' className={tooltip()}>\n {textValue}\n <Icon>\n <ArrowNortheast />\n </Icon>\n </Tooltip.Body>\n </Tooltip>\n </Provider>\n );\n}\nSidenavLink.displayName = 'Sidenav.Link';\n\nfunction SidenavAvatar({ children, className, ...rest }: SidenavAvatarProps) {\n containsAnyOfExactChildren({\n children,\n componentName: SidenavAvatar.displayName,\n restrictions: [\n [\n [Avatar, { min: 1, max: 1 }],\n [Heading, { min: 1, max: 1 }],\n [Text, { min: 0, max: 1 }],\n ],\n [\n [Icon, { min: 1, max: 1 }],\n [Heading, { min: 1, max: 1 }],\n [Text, { min: 0, max: 1 }],\n ],\n ],\n });\n\n return (\n <Provider\n values={[\n [IconContext, { size: 'large', className: avatarIcon() }],\n [\n HeadingContext,\n { className: avatarHeading({ className: transient() }) },\n ],\n [TextContext, { className: avatarText({ className: transient() }) }],\n [AvatarContext, { classNames: { avatar: avatarIcon() } }],\n ]}\n >\n <div {...rest} className={avatar({ className })}>\n {children}\n </div>\n </Provider>\n );\n}\nSidenavAvatar.displayName = 'Sidenav.Avatar';\n\nfunction SidenavMenu({\n icon,\n title,\n classNames,\n children,\n ...rest\n}: SidenavMenuProps) {\n containsExactChildren({\n children,\n componentName: SidenavMenu.displayName,\n restrictions: [[SidenavMenuItem, { min: 2 }]],\n });\n\n const { isOpen } = useContext(SidenavContext);\n const ref = useRef(null);\n\n return isOpen ? (\n <Disclosure\n className={composeRenderProps(classNames?.menu, (className) =>\n menu({ className }),\n )}\n >\n <Button\n {...rest}\n slot='trigger'\n className={composeRenderProps(classNames?.button, (className) =>\n menuButton({ className }),\n )}\n >\n {icon}\n <Heading slot='menu'>{title}</Heading>\n <Icon className={transient({ className: classNames?.icon })}>\n <ChevronDown className='transform group-expanded/menu:rotate-180' />\n </Icon>\n </Button>\n <DisclosurePanel\n className={composeRenderProps(\n classNames?.disclosurePanel,\n (className) => className ?? '',\n )}\n >\n <div className={panelContent({ className: classNames?.panelContent })}>\n {children}\n </div>\n </DisclosurePanel>\n </Disclosure>\n ) : (\n <DialogTrigger>\n <Tooltip isDisabled={isOpen}>\n <Tooltip.Trigger>\n <Button\n {...rest}\n ref={ref}\n className={composeRenderProps(classNames?.button, (className) =>\n menuButton({ className }),\n )}\n >\n {icon}\n </Button>\n </Tooltip.Trigger>\n <Tooltip.Body parentRef={ref} placement='right' className={tooltip()}>\n {title}\n </Tooltip.Body>\n </Tooltip>\n <Popover\n className={composeRenderProps(classNames?.popoverPanel, (className) =>\n menuPanel({ className }),\n )}\n placement='right top'\n shouldFlip={false}\n >\n <Heading slot='panel'>{title}</Heading>\n <div className={panelContent({ className: classNames?.panelContent })}>\n {children}\n </div>\n </Popover>\n </DialogTrigger>\n );\n}\nSidenavMenu.displayName = 'Sidenav.Menu';\n\nfunction SidenavMenuItem({\n className,\n children,\n ...rest\n}: SidenavMenuItemProps) {\n containsExactChildren({\n children,\n componentName: SidenavMenuItem.displayName,\n restrictions: [[Text, { min: 1, max: 1 }]],\n });\n\n return (\n <ToggleButton\n {...rest}\n className={composeRenderProps(className, (className) =>\n menuItem({ className }),\n )}\n >\n {children}\n </ToggleButton>\n );\n}\nSidenavMenuItem.displayName = 'Sidenav.Menu.Item';\n\nSidenavMenu.Item = SidenavMenuItem;\n\nSidenav.Trigger = SidenavTrigger;\nSidenav.Header = SidenavHeader;\nSidenav.Item = SidenavItem;\nSidenav.Link = SidenavLink;\nSidenav.Avatar = SidenavAvatar;\nSidenav.Footer = SidenavFooter;\nSidenav.Content = SidenavContent;\nSidenav.Menu = SidenavMenu;\n"]}
@@ -8,6 +8,7 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
8
8
  text?: tailwind_merge.ClassNameValue;
9
9
  link?: tailwind_merge.ClassNameValue;
10
10
  heading?: tailwind_merge.ClassNameValue;
11
+ menu?: tailwind_merge.ClassNameValue;
11
12
  tooltip?: tailwind_merge.ClassNameValue;
12
13
  header?: tailwind_merge.ClassNameValue;
13
14
  toggle?: tailwind_merge.ClassNameValue;
@@ -18,7 +19,13 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
18
19
  avatarText?: tailwind_merge.ClassNameValue;
19
20
  divider?: tailwind_merge.ClassNameValue;
20
21
  transient?: tailwind_merge.ClassNameValue;
22
+ menuHeading?: tailwind_merge.ClassNameValue;
23
+ panelHeading?: tailwind_merge.ClassNameValue;
24
+ panelContent?: tailwind_merge.ClassNameValue;
21
25
  sidenav?: tailwind_merge.ClassNameValue;
26
+ menuButton?: tailwind_merge.ClassNameValue;
27
+ menuPanel?: tailwind_merge.ClassNameValue;
28
+ menuItem?: tailwind_merge.ClassNameValue;
22
29
  };
23
30
  };
24
31
  } | {
@@ -28,6 +35,7 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
28
35
  text?: tailwind_merge.ClassNameValue;
29
36
  link?: tailwind_merge.ClassNameValue;
30
37
  heading?: tailwind_merge.ClassNameValue;
38
+ menu?: tailwind_merge.ClassNameValue;
31
39
  tooltip?: tailwind_merge.ClassNameValue;
32
40
  header?: tailwind_merge.ClassNameValue;
33
41
  toggle?: tailwind_merge.ClassNameValue;
@@ -38,7 +46,13 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
38
46
  avatarText?: tailwind_merge.ClassNameValue;
39
47
  divider?: tailwind_merge.ClassNameValue;
40
48
  transient?: tailwind_merge.ClassNameValue;
49
+ menuHeading?: tailwind_merge.ClassNameValue;
50
+ panelHeading?: tailwind_merge.ClassNameValue;
51
+ panelContent?: tailwind_merge.ClassNameValue;
41
52
  sidenav?: tailwind_merge.ClassNameValue;
53
+ menuButton?: tailwind_merge.ClassNameValue;
54
+ menuPanel?: tailwind_merge.ClassNameValue;
55
+ menuItem?: tailwind_merge.ClassNameValue;
42
56
  };
43
57
  };
44
58
  } | {}, {
@@ -57,6 +71,13 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
57
71
  transient: string;
58
72
  link: string[];
59
73
  tooltip: string[];
74
+ menu: string;
75
+ menuButton: string[];
76
+ menuHeading: string;
77
+ menuPanel: string[];
78
+ menuItem: string[];
79
+ panelHeading: string;
80
+ panelContent: string;
60
81
  }, undefined, {
61
82
  [key: string]: {
62
83
  [key: string]: tailwind_merge.ClassNameValue | {
@@ -64,6 +85,7 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
64
85
  text?: tailwind_merge.ClassNameValue;
65
86
  link?: tailwind_merge.ClassNameValue;
66
87
  heading?: tailwind_merge.ClassNameValue;
88
+ menu?: tailwind_merge.ClassNameValue;
67
89
  tooltip?: tailwind_merge.ClassNameValue;
68
90
  header?: tailwind_merge.ClassNameValue;
69
91
  toggle?: tailwind_merge.ClassNameValue;
@@ -74,7 +96,13 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
74
96
  avatarText?: tailwind_merge.ClassNameValue;
75
97
  divider?: tailwind_merge.ClassNameValue;
76
98
  transient?: tailwind_merge.ClassNameValue;
99
+ menuHeading?: tailwind_merge.ClassNameValue;
100
+ panelHeading?: tailwind_merge.ClassNameValue;
101
+ panelContent?: tailwind_merge.ClassNameValue;
77
102
  sidenav?: tailwind_merge.ClassNameValue;
103
+ menuButton?: tailwind_merge.ClassNameValue;
104
+ menuPanel?: tailwind_merge.ClassNameValue;
105
+ menuItem?: tailwind_merge.ClassNameValue;
78
106
  };
79
107
  };
80
108
  } | {}, {
@@ -93,6 +121,13 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
93
121
  transient: string;
94
122
  link: string[];
95
123
  tooltip: string[];
124
+ menu: string;
125
+ menuButton: string[];
126
+ menuHeading: string;
127
+ menuPanel: string[];
128
+ menuItem: string[];
129
+ panelHeading: string;
130
+ panelContent: string;
96
131
  }, tailwind_variants.TVReturnType<unknown, {
97
132
  sidenav: string[];
98
133
  content: string;
@@ -109,6 +144,13 @@ declare const SidenavStyles: tailwind_variants.TVReturnType<{
109
144
  transient: string;
110
145
  link: string[];
111
146
  tooltip: string[];
112
- }, undefined, unknown, unknown, undefined>>;
147
+ menu: string;
148
+ menuButton: string[];
149
+ menuHeading: string;
150
+ menuPanel: string[];
151
+ menuItem: string[];
152
+ panelHeading: string;
153
+ panelContent: string;
154
+ }, undefined, unknown, unknown>>;
113
155
 
114
156
  export { SidenavStyles };
@@ -1,2 +1,2 @@
1
- import {tv}from'tailwind-variants';const r=tv({slots:{sidenav:["group/sidenav fg-a11y-on-accent absolute left-0 row-span-full flex h-full flex-col gap-xs bg-surface-default p-m","closed:items-center","group-data-[push~=left]/layout:relative"],content:"flex h-full max-h-full flex-col gap-xs overflow-y-auto",header:"mb-m flex justify-center",avatar:['grid grid-cols-[auto_1fr] grid-rows-2 items-center gap-x-m [grid-template-areas:"icon_heading"_"icon_text"] group-closed/sidenav:flex'],avatarIcon:"[grid-area:icon]",avatarHeading:"fg-primary-bold text-body-m [grid-area:heading]",avatarText:"fg-primary-muted grow-1 text-left text-body-s [grid-area:text]",toggle:["flex cursor-pointer items-center gap-s rounded-medium p-xs group-open/sidenav:px-s","enabled:hover:bg-interactive-muted-hover","enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none","enabled:pressed:bg-interactive-muted-pressed"],divider:"my-s h-[1px] w-full shrink-0 grow-0 border-0 bg-[var(--outline-static)]",heading:"text-body-xs uppercase",item:["group/item flex w-full cursor-pointer items-center gap-s rounded-medium p-xs text-body-m","group-open/sidenav:px-s","enabled:hover:bg-interactive-muted-hover","enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none","enabled:pressed:bg-accent-primary-pressed","enabled:selected:bg-accent-primary-bold","enabled:selected:hover:bg-accent-primary-hover","enabled:selected:focus-visible:bg-accent-primary-hover","enabled:selected:pressed:bg-accent-primary-pressed","disabled:fg-disabled disabled:cursor-not-allowed"],text:"grow-1 text-left text-body-s",transient:"group-closed/sidenav:hidden",link:["group/link flex w-full cursor-pointer items-center gap-s rounded-medium p-xs text-body-m","group-open/sidenav:w-full","enabled:hover:bg-interactive-muted-hover","enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none","enabled:pressed:bg-accent-primary-pressed","disabled:fg-disabled disabled:cursor-not-allowed"],tooltip:["absolute flex items-center gap-s whitespace-nowrap text-body-s","group-disabled/item:fg-disabled group-disabled/link:fg-disabled"]}});export{r as SidenavStyles};//# sourceMappingURL=styles.js.map
1
+ import {tv}from'./../../lib/utils.js';const d=tv({slots:{sidenav:["group/sidenav fg-a11y-on-accent absolute left-0 row-span-full flex h-full flex-col gap-xs bg-surface-default p-m","closed:items-center","group-data-[push~=left]/layout:relative"],content:"flex h-full max-h-full w-fit flex-col gap-xs group-open/sidenav:w-full group-closed/sidenav:items-center",header:"mb-m flex justify-center",avatar:['grid w-full grid-cols-[auto_1fr] grid-rows-2 items-center gap-x-m [grid-template-areas:"content_heading"_"content_text"] group-closed/sidenav:flex'],avatarIcon:"[grid-area:content]",avatarHeading:"fg-primary-bold text-left text-body-m [grid-area:heading]",avatarText:"fg-primary-muted grow-1 text-left text-body-s [grid-area:text]",toggle:["flex cursor-pointer items-center gap-s rounded-medium p-xs group-open/sidenav:px-s","enabled:hover:bg-interactive-muted-hover","enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none","enabled:pressed:bg-interactive-muted-pressed"],divider:"my-s",heading:"text-body-xs uppercase",item:["group/item flex w-full cursor-pointer items-center justify-center gap-s rounded-medium p-xs text-body-m","group-open/sidenav:px-s group-closed/sidenav:max-w-fit","enabled:hover:bg-interactive-muted-hover","enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none","enabled:pressed:bg-accent-primary-pressed","enabled:selected:bg-accent-primary-bold","enabled:selected:hover:bg-accent-primary-hover","enabled:selected:focus-visible:bg-accent-primary-hover","enabled:selected:pressed:bg-accent-primary-pressed","disabled:fg-disabled disabled:cursor-not-allowed"],text:"grow-1 text-left text-body-s",transient:"group-closed/sidenav:hidden",link:["group/link flex w-full cursor-pointer items-center justify-center gap-s rounded-medium p-xs text-body-m","group-open/sidenav:w-full group-closed/sidenav:max-w-fit","enabled:hover:bg-interactive-muted-hover","enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none","enabled:pressed:bg-accent-primary-pressed","disabled:fg-disabled disabled:cursor-not-allowed"],tooltip:["absolute flex items-center gap-s whitespace-nowrap text-body-s","group-disabled/item:fg-disabled group-disabled/link:fg-disabled"],menu:"group/menu relative text-body-s",menuButton:["flex w-full cursor-pointer items-center justify-center gap-s rounded-medium p-xs","group-closed/sidenav:max-w-fit","enabled:hover:bg-interactive-muted-hover","enabled:pressed:bg-interactive-muted-hover enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none"],menuHeading:"flex-1 text-left",menuPanel:["fg-primary-bold rounded-medium bg-surface-raised outline outline-static"],menuItem:["flex w-full cursor-pointer items-center gap-s rounded-medium p-s text-left text-body-s","group-expanded/menu:block group-open/sidenav:group-expanded/menu:pl-[32px]","enabled:hover:bg-interactive-muted-hover","enabled:focus-visible:bg-interactive-muted-hover enabled:focus-visible:outline-none","enabled:pressed:bg-accent-primary-pressed","enabled:selected:bg-accent-primary-bold","enabled:selected:hover:bg-accent-primary-hover","enabled:selected:focus-visible:bg-accent-primary-hover","enabled:selected:pressed:bg-accent-primary-pressed","disabled:fg-disabled disabled:cursor-not-allowed"],panelHeading:"min-w-[172px] rounded-t-medium bg-surface-overlay px-m py-s text-body-s",panelContent:"flex flex-col gap-xs bg-surface-default px-xs py-xs"}});export{d as SidenavStyles};//# sourceMappingURL=styles.js.map
2
2
  //# sourceMappingURL=styles.js.map