pixelize-design-library 2.4.1-beta.2 → 2.4.1-beta.3

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 (329) hide show
  1. package/dist/Components/Accordion/accordionColors.d.ts.map +1 -1
  2. package/dist/Components/Accordion/accordionColors.js +17 -3
  3. package/dist/Components/Checkbox/Checkbox.styles.d.ts.map +1 -1
  4. package/dist/Components/Checkbox/Checkbox.styles.js +13 -2
  5. package/dist/Components/CustomModulesTable/EditModuleModal.d.ts.map +1 -1
  6. package/dist/Components/CustomModulesTable/EditModuleModal.js +5 -1
  7. package/dist/Components/DatePicker/CalendarPanel.d.ts.map +1 -1
  8. package/dist/Components/DatePicker/CalendarPanel.js +3 -1
  9. package/dist/Components/Editor/joditThemeVars.d.ts.map +1 -1
  10. package/dist/Components/Editor/joditThemeVars.js +9 -0
  11. package/dist/Components/FilePreview/FilePreview.d.ts.map +1 -1
  12. package/dist/Components/FilePreview/FilePreview.js +3 -1
  13. package/dist/Components/FileUploader/FileUploader.js +2 -2
  14. package/dist/Components/FilterSidebar/FilterSidebar.js +1 -1
  15. package/dist/Components/NavigationBar/NavigationBar.d.ts.map +1 -1
  16. package/dist/Components/NavigationBar/NavigationBar.js +10 -6
  17. package/dist/Components/OrgSwitcher/OrgSwitcher.d.ts.map +1 -1
  18. package/dist/Components/OrgSwitcher/OrgSwitcher.js +22 -3
  19. package/dist/Components/OrgSwitcher/OrgSwitcherProps.d.ts +1 -0
  20. package/dist/Components/OrgSwitcher/OrgSwitcherProps.d.ts.map +1 -1
  21. package/dist/Components/OrgSwitcher/OrgSwitcherProps.js +3 -3
  22. package/dist/Components/OrganizationDetails/CreateOrgModal.js +6 -4
  23. package/dist/Components/OrganizationDetails/OrganizationDetails.d.ts.map +1 -1
  24. package/dist/Components/OrganizationDetails/OrganizationDetails.js +55 -7
  25. package/dist/Components/OrganizationDetails/OrganizationDetailsProps.d.ts +24 -14
  26. package/dist/Components/OrganizationDetails/OrganizationDetailsProps.d.ts.map +1 -1
  27. package/dist/Components/PlanPill/PlanPill.d.ts +5 -0
  28. package/dist/Components/PlanPill/PlanPill.d.ts.map +1 -0
  29. package/dist/Components/PlanPill/PlanPill.js +41 -0
  30. package/dist/Components/PlanPill/PlanPillProps.d.ts +28 -0
  31. package/dist/Components/PlanPill/PlanPillProps.d.ts.map +1 -0
  32. package/dist/Components/PlanPill/PlanPillProps.js +2 -0
  33. package/dist/Components/Search/Search.d.ts.map +1 -1
  34. package/dist/Components/Search/Search.js +4 -2
  35. package/dist/Components/Select/Select.styles.d.ts.map +1 -1
  36. package/dist/Components/Select/Select.styles.js +29 -20
  37. package/dist/Components/SelectSearch/SelectSearch.js +1 -1
  38. package/dist/Components/SideBar/SecondaryBar.d.ts.map +1 -1
  39. package/dist/Components/SideBar/SecondaryBar.js +10 -2
  40. package/dist/Components/SideBar/SideBar.js +1 -1
  41. package/dist/Components/SideBar/components/MenuItemBox.d.ts.map +1 -1
  42. package/dist/Components/SideBar/components/MenuItemBox.js +7 -6
  43. package/dist/Components/Table/components/tableRowHoverStyle.d.ts +9 -8
  44. package/dist/Components/Table/components/tableRowHoverStyle.d.ts.map +1 -1
  45. package/dist/Components/Table/components/tableRowHoverStyle.js +12 -12
  46. package/dist/Components/Table/settings/ManageColumns.js +2 -2
  47. package/dist/Components/UpgradeButton/UpgradeButton.d.ts.map +1 -1
  48. package/dist/Components/UpgradeButton/UpgradeButton.js +25 -7
  49. package/dist/Components/UserDetails/UserDetails.d.ts.map +1 -1
  50. package/dist/Components/UserDetails/UserDetails.js +5 -2
  51. package/dist/Theme/chakra/componentStyles.d.ts +2 -0
  52. package/dist/Theme/chakra/componentStyles.d.ts.map +1 -1
  53. package/dist/Theme/chakra/componentStyles.js +74 -0
  54. package/dist/Theme/chakra/createBrandTheme.d.ts.map +1 -1
  55. package/dist/Theme/chakra/createBrandTheme.js +47 -0
  56. package/dist/Theme/tokens/brands/index.d.ts.map +1 -1
  57. package/dist/Theme/tokens/brands/index.js +20 -18
  58. package/dist/Theme/tokens/brands/zinc/palette.dark.d.ts.map +1 -1
  59. package/dist/Theme/tokens/brands/zinc/palette.dark.js +4 -2
  60. package/dist/Theme/tokens/builders/outlineRung.d.ts +35 -0
  61. package/dist/Theme/tokens/builders/outlineRung.d.ts.map +1 -0
  62. package/dist/Theme/tokens/builders/outlineRung.js +69 -0
  63. package/dist/Theme/tokens/builders/statusTone.d.ts +35 -0
  64. package/dist/Theme/tokens/builders/statusTone.d.ts.map +1 -0
  65. package/dist/Theme/tokens/builders/statusTone.js +63 -0
  66. package/dist/Utils/planExpiry.d.ts +19 -0
  67. package/dist/Utils/planExpiry.d.ts.map +1 -0
  68. package/dist/Utils/planExpiry.js +61 -0
  69. package/dist/index.d.ts +7 -1
  70. package/dist/index.d.ts.map +1 -1
  71. package/dist/index.js +21 -3
  72. package/package.json +5 -1
  73. package/.claude/settings.local.json +0 -51
  74. package/.cursor/TASK-SETUP.md +0 -43
  75. package/.cursor/agents/be-impl.md +0 -37
  76. package/.cursor/agents/fe-impl.md +0 -39
  77. package/.cursor/agents/task-plan.md +0 -56
  78. package/.cursor/agents/test-create.md +0 -31
  79. package/.cursor/agents/test-exec.md +0 -26
  80. package/.cursor/hooks/task-hint.env +0 -1
  81. package/.cursor/hooks/task-skill-nudge.sh +0 -71
  82. package/.cursor/hooks/task-slash-guard.sh +0 -31
  83. package/.cursor/hooks.json +0 -13
  84. package/.cursor/modules/account-management/MODULE.md +0 -41
  85. package/.cursor/modules/buttons/MODULE.md +0 -47
  86. package/.cursor/modules/cards/MODULE.md +0 -55
  87. package/.cursor/modules/charts/MODULE.md +0 -40
  88. package/.cursor/modules/common/MODULE.md +0 -36
  89. package/.cursor/modules/contact-auth/MODULE.md +0 -19
  90. package/.cursor/modules/data-display/MODULE.md +0 -42
  91. package/.cursor/modules/feedback/MODULE.md +0 -38
  92. package/.cursor/modules/form/MODULE.md +0 -13
  93. package/.cursor/modules/inputs-basic/MODULE.md +0 -42
  94. package/.cursor/modules/inputs-date-file/MODULE.md +0 -67
  95. package/.cursor/modules/inputs-select/MODULE.md +0 -89
  96. package/.cursor/modules/inputs-toggle/MODULE.md +0 -24
  97. package/.cursor/modules/kanban/MODULE.md +0 -22
  98. package/.cursor/modules/layout-navigation/MODULE.md +0 -319
  99. package/.cursor/modules/overlays/MODULE.md +0 -82
  100. package/.cursor/modules/playground/MODULE.md +0 -28
  101. package/.cursor/modules/table/MODULE.md +0 -84
  102. package/.cursor/modules/theme/MODULE.md +0 -431
  103. package/.cursor/modules/types-exports/MODULE.md +0 -17
  104. package/.cursor/modules/utility-ui/MODULE.md +0 -50
  105. package/.cursor/modules/utils-hooks/MODULE.md +0 -35
  106. package/.cursor/pixelize-task-statusline.sh +0 -64
  107. package/.cursor/plans/blocked/.gitkeep +0 -0
  108. package/.cursor/plans/current.md +0 -12
  109. package/.cursor/plans/current.theme-tokens-dark-mode.md +0 -77
  110. package/.cursor/plans/current.theme-tokens-dark.md +0 -155
  111. package/.cursor/plans/done/.gitkeep +0 -0
  112. package/.cursor/rules +0 -31
  113. package/.cursor/skills/task/SKILL.md +0 -167
  114. package/CLAUDE.md +0 -148
  115. package/__mocks__/styleMock.js +0 -8
  116. package/coverage/clover.xml +0 -405
  117. package/coverage/coverage-final.json +0 -16
  118. package/coverage/coverage-summary.json +0 -50
  119. package/coverage/lcov-report/Button/Button.tsx.html +0 -244
  120. package/coverage/lcov-report/Button/index.html +0 -116
  121. package/coverage/lcov-report/Checkbox/Checkbox.tsx.html +0 -433
  122. package/coverage/lcov-report/Checkbox/index.html +0 -116
  123. package/coverage/lcov-report/Common/ErrorMessage.tsx.html +0 -148
  124. package/coverage/lcov-report/Common/FormLabel.tsx.html +0 -331
  125. package/coverage/lcov-report/Common/HelperText.tsx.html +0 -124
  126. package/coverage/lcov-report/Common/index.html +0 -146
  127. package/coverage/lcov-report/Components/Button/Button.tsx.html +0 -244
  128. package/coverage/lcov-report/Components/Button/index.html +0 -116
  129. package/coverage/lcov-report/Components/Checkbox/Checkbox.tsx.html +0 -433
  130. package/coverage/lcov-report/Components/Checkbox/index.html +0 -116
  131. package/coverage/lcov-report/Components/Common/ErrorMessage.tsx.html +0 -148
  132. package/coverage/lcov-report/Components/Common/FormLabel.tsx.html +0 -331
  133. package/coverage/lcov-report/Components/Common/HelperText.tsx.html +0 -124
  134. package/coverage/lcov-report/Components/Common/index.html +0 -146
  135. package/coverage/lcov-report/Components/CustomModulesTable/CustomModulesTable.tsx.html +0 -712
  136. package/coverage/lcov-report/Components/CustomModulesTable/DeleteModuleModal.tsx.html +0 -343
  137. package/coverage/lcov-report/Components/CustomModulesTable/EditModuleModal.tsx.html +0 -313
  138. package/coverage/lcov-report/Components/CustomModulesTable/index.html +0 -146
  139. package/coverage/lcov-report/Components/Divider/Divider.tsx.html +0 -133
  140. package/coverage/lcov-report/Components/Divider/index.html +0 -116
  141. package/coverage/lcov-report/Components/Dropdown/DropDown.tsx.html +0 -994
  142. package/coverage/lcov-report/Components/Dropdown/index.html +0 -116
  143. package/coverage/lcov-report/Components/EmptyState/EmptyState.tsx.html +0 -466
  144. package/coverage/lcov-report/Components/EmptyState/index.html +0 -116
  145. package/coverage/lcov-report/Components/Header/HeaderActions.tsx.html +0 -373
  146. package/coverage/lcov-report/Components/Header/index.html +0 -116
  147. package/coverage/lcov-report/Components/Input/TextInput.tsx.html +0 -487
  148. package/coverage/lcov-report/Components/Input/index.html +0 -116
  149. package/coverage/lcov-report/Components/Input/textInputIconSize.ts.html +0 -205
  150. package/coverage/lcov-report/Components/KanbanBoard/AccountCard.tsx.html +0 -547
  151. package/coverage/lcov-report/Components/KanbanBoard/AccountRow.tsx.html +0 -190
  152. package/coverage/lcov-report/Components/KanbanBoard/KanbanActions/KanbanActions.tsx.html +0 -247
  153. package/coverage/lcov-report/Components/KanbanBoard/KanbanActions/index.html +0 -116
  154. package/coverage/lcov-report/Components/KanbanBoard/KanbanBoard.tsx.html +0 -3598
  155. package/coverage/lcov-report/Components/KanbanBoard/MeasuredItem.tsx.html +0 -283
  156. package/coverage/lcov-report/Components/KanbanBoard/index.html +0 -161
  157. package/coverage/lcov-report/Components/OrganizationDetails/CreateOrgModal.tsx.html +0 -511
  158. package/coverage/lcov-report/Components/OrganizationDetails/DeleteOrgModal.tsx.html +0 -334
  159. package/coverage/lcov-report/Components/OrganizationDetails/OrganizationDetails.tsx.html +0 -1519
  160. package/coverage/lcov-report/Components/OrganizationDetails/index.html +0 -146
  161. package/coverage/lcov-report/Components/RolesPermission/DeleteRoleModal.tsx.html +0 -328
  162. package/coverage/lcov-report/Components/RolesPermission/RolesPermission.tsx.html +0 -1732
  163. package/coverage/lcov-report/Components/RolesPermission/index.html +0 -131
  164. package/coverage/lcov-report/Components/SearchSelect/SearchSelect.tsx.html +0 -2575
  165. package/coverage/lcov-report/Components/SearchSelect/SelectTruncatedLabel.tsx.html +0 -202
  166. package/coverage/lcov-report/Components/SearchSelect/index.html +0 -146
  167. package/coverage/lcov-report/Components/SearchSelect/searchSelectSize.ts.html +0 -496
  168. package/coverage/lcov-report/Components/Select/Select.tsx.html +0 -361
  169. package/coverage/lcov-report/Components/Select/index.html +0 -116
  170. package/coverage/lcov-report/Components/SideBar/components/OtherApps.tsx.html +0 -562
  171. package/coverage/lcov-report/Components/SideBar/components/OverflowTooltipText.tsx.html +0 -346
  172. package/coverage/lcov-report/Components/SideBar/components/index.html +0 -116
  173. package/coverage/lcov-report/Components/SignInActivityTable/SignInActivityTable.tsx.html +0 -490
  174. package/coverage/lcov-report/Components/SignInActivityTable/index.html +0 -116
  175. package/coverage/lcov-report/Components/Table/components/TableActions.tsx.html +0 -595
  176. package/coverage/lcov-report/Components/Table/components/TableBody.tsx.html +0 -2212
  177. package/coverage/lcov-report/Components/Table/components/TableGroupRow.tsx.html +0 -358
  178. package/coverage/lcov-report/Components/Table/components/TableLoading.tsx.html +0 -358
  179. package/coverage/lcov-report/Components/Table/components/index.html +0 -161
  180. package/coverage/lcov-report/Components/Table/settings/ManageColumns.tsx.html +0 -856
  181. package/coverage/lcov-report/Components/Table/settings/index.html +0 -116
  182. package/coverage/lcov-report/Components/Tag/Tag.styles.tsx.html +0 -331
  183. package/coverage/lcov-report/Components/Tag/Tag.tsx.html +0 -256
  184. package/coverage/lcov-report/Components/Tag/index.html +0 -131
  185. package/coverage/lcov-report/Components/ToolTip/ToolTip.tsx.html +0 -286
  186. package/coverage/lcov-report/Components/ToolTip/index.html +0 -116
  187. package/coverage/lcov-report/Components/UserDetails/AddUserModal.tsx.html +0 -709
  188. package/coverage/lcov-report/Components/UserDetails/ChangeRoleModal.tsx.html +0 -505
  189. package/coverage/lcov-report/Components/UserDetails/DeactivateConfirmModal.tsx.html +0 -379
  190. package/coverage/lcov-report/Components/UserDetails/UserDetails.tsx.html +0 -1900
  191. package/coverage/lcov-report/Components/UserDetails/index.html +0 -161
  192. package/coverage/lcov-report/EmptyState/EmptyState.tsx.html +0 -466
  193. package/coverage/lcov-report/EmptyState/index.html +0 -116
  194. package/coverage/lcov-report/Hooks/index.html +0 -116
  195. package/coverage/lcov-report/Hooks/usePreferences.ts.html +0 -421
  196. package/coverage/lcov-report/Input/TextInput.tsx.html +0 -487
  197. package/coverage/lcov-report/Input/index.html +0 -131
  198. package/coverage/lcov-report/Input/textInputIconSize.ts.html +0 -205
  199. package/coverage/lcov-report/KanbanBoard.tsx.html +0 -3481
  200. package/coverage/lcov-report/OrganizationDetails/CreateOrgModal.tsx.html +0 -511
  201. package/coverage/lcov-report/OrganizationDetails/DeleteOrgModal.tsx.html +0 -334
  202. package/coverage/lcov-report/OrganizationDetails/OrganizationDetails.tsx.html +0 -1519
  203. package/coverage/lcov-report/OrganizationDetails/index.html +0 -146
  204. package/coverage/lcov-report/RolesPermission/DeleteRoleModal.tsx.html +0 -328
  205. package/coverage/lcov-report/RolesPermission/RolesPermission.tsx.html +0 -1732
  206. package/coverage/lcov-report/RolesPermission/index.html +0 -116
  207. package/coverage/lcov-report/SearchSelect/SearchSelect.tsx.html +0 -2575
  208. package/coverage/lcov-report/SearchSelect/SelectTruncatedLabel.tsx.html +0 -202
  209. package/coverage/lcov-report/SearchSelect/index.html +0 -146
  210. package/coverage/lcov-report/SearchSelect/searchSelectSize.ts.html +0 -496
  211. package/coverage/lcov-report/Table/CompactSelect.tsx.html +0 -379
  212. package/coverage/lcov-report/Table/Components/ActiveFilters.tsx.html +0 -514
  213. package/coverage/lcov-report/Table/Components/HeaderActions.tsx.html +0 -373
  214. package/coverage/lcov-report/Table/Components/Pagination.tsx.html +0 -574
  215. package/coverage/lcov-report/Table/Components/TableActions.tsx.html +0 -574
  216. package/coverage/lcov-report/Table/Components/TableBody.tsx.html +0 -1027
  217. package/coverage/lcov-report/Table/Components/TableFilters.tsx.html +0 -397
  218. package/coverage/lcov-report/Table/Components/TableHeader.tsx.html +0 -1060
  219. package/coverage/lcov-report/Table/Components/TableLoading.tsx.html +0 -361
  220. package/coverage/lcov-report/Table/Components/TableSearch.tsx.html +0 -337
  221. package/coverage/lcov-report/Table/Components/index.html +0 -266
  222. package/coverage/lcov-report/Table/Components/useDebounce.ts.html +0 -178
  223. package/coverage/lcov-report/Table/Components/useTable.ts.html +0 -778
  224. package/coverage/lcov-report/Table/LeftFilterPane.tsx.html +0 -1810
  225. package/coverage/lcov-report/Table/SelectOperationControls.tsx.html +0 -178
  226. package/coverage/lcov-report/Table/Table.tsx.html +0 -1567
  227. package/coverage/lcov-report/Table/TableProps.tsx.html +0 -658
  228. package/coverage/lcov-report/Table/TableSettings/ManageColumns.tsx.html +0 -619
  229. package/coverage/lcov-report/Table/TableSettings/TableFilters.tsx.html +0 -229
  230. package/coverage/lcov-report/Table/TableSettings/TableSettings.tsx.html +0 -532
  231. package/coverage/lcov-report/Table/TableSettings/index.html +0 -146
  232. package/coverage/lcov-report/Table/TableToDo.tsx.html +0 -973
  233. package/coverage/lcov-report/Table/TextOperationControls.tsx.html +0 -271
  234. package/coverage/lcov-report/Table/filterTypes.ts.html +0 -97
  235. package/coverage/lcov-report/Table/index.html +0 -176
  236. package/coverage/lcov-report/Table/settings/ManageColumns.tsx.html +0 -856
  237. package/coverage/lcov-report/Table/settings/index.html +0 -116
  238. package/coverage/lcov-report/Tag/Tag.tsx.html +0 -256
  239. package/coverage/lcov-report/Tag/index.html +0 -116
  240. package/coverage/lcov-report/Theme/buildBrandTokens.ts.html +0 -175
  241. package/coverage/lcov-report/Theme/chartColorsFromTheme.ts.html +0 -214
  242. package/coverage/lcov-report/Theme/index.html +0 -131
  243. package/coverage/lcov-report/Theme/useCustomTheme.ts.html +0 -100
  244. package/coverage/lcov-report/ToolTip/ToolTip.tsx.html +0 -286
  245. package/coverage/lcov-report/ToolTip/index.html +0 -116
  246. package/coverage/lcov-report/UserDetails/AddUserModal.tsx.html +0 -709
  247. package/coverage/lcov-report/UserDetails/ChangeRoleModal.tsx.html +0 -505
  248. package/coverage/lcov-report/UserDetails/index.html +0 -116
  249. package/coverage/lcov-report/Utils/functions.ts.html +0 -106
  250. package/coverage/lcov-report/Utils/index.html +0 -116
  251. package/coverage/lcov-report/Utils/table.ts.html +0 -1189
  252. package/coverage/lcov-report/base.css +0 -224
  253. package/coverage/lcov-report/block-navigation.js +0 -87
  254. package/coverage/lcov-report/favicon.png +0 -0
  255. package/coverage/lcov-report/index.html +0 -251
  256. package/coverage/lcov-report/prettify.css +0 -1
  257. package/coverage/lcov-report/prettify.js +0 -2
  258. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  259. package/coverage/lcov-report/sorter.js +0 -210
  260. package/coverage/lcov.info +0 -981
  261. package/dist/Theme/Dark/theme.d.ts +0 -3
  262. package/dist/Theme/Dark/theme.d.ts.map +0 -1
  263. package/dist/Theme/Dark/theme.js +0 -277
  264. package/dist/Theme/Default/palette.d.ts +0 -375
  265. package/dist/Theme/Default/palette.d.ts.map +0 -1
  266. package/dist/Theme/Default/palette.js +0 -306
  267. package/dist/Theme/Default/theme.d.ts +0 -3
  268. package/dist/Theme/Default/theme.d.ts.map +0 -1
  269. package/dist/Theme/Default/theme.js +0 -19
  270. package/dist/Theme/Emerald/palette.d.ts +0 -375
  271. package/dist/Theme/Emerald/palette.d.ts.map +0 -1
  272. package/dist/Theme/Emerald/palette.js +0 -125
  273. package/dist/Theme/Emerald/theme.d.ts +0 -3
  274. package/dist/Theme/Emerald/theme.d.ts.map +0 -1
  275. package/dist/Theme/Emerald/theme.js +0 -19
  276. package/dist/Theme/Meadow/palette.d.ts +0 -375
  277. package/dist/Theme/Meadow/palette.d.ts.map +0 -1
  278. package/dist/Theme/Meadow/palette.js +0 -123
  279. package/dist/Theme/Meadow/theme.d.ts +0 -3
  280. package/dist/Theme/Meadow/theme.d.ts.map +0 -1
  281. package/dist/Theme/Meadow/theme.js +0 -19
  282. package/dist/Theme/Radiant/palette.d.ts +0 -375
  283. package/dist/Theme/Radiant/palette.d.ts.map +0 -1
  284. package/dist/Theme/Radiant/palette.js +0 -125
  285. package/dist/Theme/Radiant/theme.d.ts +0 -3
  286. package/dist/Theme/Radiant/theme.d.ts.map +0 -1
  287. package/dist/Theme/Radiant/theme.js +0 -19
  288. package/dist/Theme/Rosewood/palette.d.ts +0 -375
  289. package/dist/Theme/Rosewood/palette.d.ts.map +0 -1
  290. package/dist/Theme/Rosewood/palette.js +0 -125
  291. package/dist/Theme/Rosewood/theme.d.ts +0 -3
  292. package/dist/Theme/Rosewood/theme.d.ts.map +0 -1
  293. package/dist/Theme/Rosewood/theme.js +0 -19
  294. package/dist/Theme/Skyline/palette.d.ts +0 -375
  295. package/dist/Theme/Skyline/palette.d.ts.map +0 -1
  296. package/dist/Theme/Skyline/palette.js +0 -123
  297. package/dist/Theme/Skyline/theme.d.ts +0 -3
  298. package/dist/Theme/Skyline/theme.d.ts.map +0 -1
  299. package/dist/Theme/Skyline/theme.js +0 -19
  300. package/dist/Theme/Slate/palette.d.ts +0 -375
  301. package/dist/Theme/Slate/palette.d.ts.map +0 -1
  302. package/dist/Theme/Slate/palette.js +0 -123
  303. package/dist/Theme/Slate/theme.d.ts +0 -3
  304. package/dist/Theme/Slate/theme.d.ts.map +0 -1
  305. package/dist/Theme/Slate/theme.js +0 -19
  306. package/dist/Theme/buildBrandTokens.d.ts +0 -16
  307. package/dist/Theme/buildBrandTokens.d.ts.map +0 -1
  308. package/dist/Theme/buildBrandTokens.js +0 -33
  309. package/dist/Theme/chartColorsFromTheme.d.ts +0 -19
  310. package/dist/Theme/chartColorsFromTheme.d.ts.map +0 -1
  311. package/dist/Theme/chartColorsFromTheme.js +0 -34
  312. package/dist/Theme/common.d.ts +0 -167
  313. package/dist/Theme/common.d.ts.map +0 -1
  314. package/dist/Theme/common.js +0 -112
  315. package/dist/Theme/componentStyles.d.ts +0 -10
  316. package/dist/Theme/componentStyles.d.ts.map +0 -1
  317. package/dist/Theme/componentStyles.js +0 -19
  318. package/dist/Theme/fonts.d.ts +0 -37
  319. package/dist/Theme/fonts.d.ts.map +0 -1
  320. package/dist/Theme/fonts.js +0 -41
  321. package/dist/Theme/space.d.ts +0 -34
  322. package/dist/Theme/space.d.ts.map +0 -1
  323. package/dist/Theme/space.js +0 -35
  324. package/dist/Theme/theme.d.ts +0 -3
  325. package/dist/Theme/theme.d.ts.map +0 -1
  326. package/dist/Theme/theme.js +0 -12
  327. package/eslint.config.js +0 -48
  328. package/index.html +0 -13
  329. package/vite.config.ts +0 -13
@@ -1 +1 @@
1
- {"version":3,"file":"accordionColors.d.ts","sourceRoot":"","sources":["../../../src/Components/Accordion/accordionColors.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAE7D,eAAO,MAAM,uBAAuB,GAClC,QAAQ,YAAY,EACpB,QAAQ,OAAO,KACd;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAczC,CAAC"}
1
+ {"version":3,"file":"accordionColors.d.ts","sourceRoot":"","sources":["../../../src/Components/Accordion/accordionColors.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAW7D,eAAO,MAAM,uBAAuB,GAClC,QAAQ,YAAY,EACpB,QAAQ,OAAO,KACd;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAuBzC,CAAC"}
@@ -1,8 +1,18 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getAccordionHoverColors = void 0;
4
+ const color_1 = require("../../Theme/tokens/builders/color");
5
+ const outlineRung_1 = require("../../Theme/tokens/builders/outlineRung");
6
+ /**
7
+ * Same perceptibility floor the SideBar ladder uses — a state a user cannot see is not a state.
8
+ * Light mode `softHover` measured 1.042-1.105 across all 9 brands (invisible) while dark sat at
9
+ * 1.58-1.85; `expandedBg` (`primary.opacity[8]`, an 8%-alpha tint) is the same bug class — an
10
+ * 8% tint composited over a near-white canvas is itself near-white. Both are resolved against
11
+ * the rest surface so light and dark actually agree on "you can see this".
12
+ */
13
+ const MIN_HOVER_STEP = 1.15;
4
14
  const getAccordionHoverColors = (colors, isDark) => {
5
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
15
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
6
16
  if (isDark) {
7
17
  // primary.opacity[8] composited over the dark canvas collapses to ~1.07:1 (near-black on
8
18
  // near-black) — gray[200] is an opaque rung that stays visibly above canvas (~1.6:1) without
@@ -12,9 +22,13 @@ const getAccordionHoverColors = (colors, isDark) => {
12
22
  softHover: (_j = (_g = (_f = colors.gray) === null || _f === void 0 ? void 0 : _f[200]) !== null && _g !== void 0 ? _g : (_h = colors.gray) === null || _h === void 0 ? void 0 : _h[300]) !== null && _j !== void 0 ? _j : (_k = colors.gray) === null || _k === void 0 ? void 0 : _k[50],
13
23
  };
14
24
  }
25
+ const rest = (_m = (_l = colors.background) === null || _l === void 0 ? void 0 : _l[50]) !== null && _m !== void 0 ? _m : "#ffffff";
26
+ const expandedTint = ((_p = (_o = colors.primary) === null || _o === void 0 ? void 0 : _o.opacity) === null || _p === void 0 ? void 0 : _p[8])
27
+ ? (0, color_1.compositeOver)(colors.primary.opacity[8], rest)
28
+ : ((_r = (_q = colors.gray) === null || _q === void 0 ? void 0 : _q[50]) !== null && _r !== void 0 ? _r : rest);
15
29
  return {
16
- expandedBg: (_o = (_m = (_l = colors.primary) === null || _l === void 0 ? void 0 : _l.opacity) === null || _m === void 0 ? void 0 : _m[8]) !== null && _o !== void 0 ? _o : (_p = colors.gray) === null || _p === void 0 ? void 0 : _p[50],
17
- softHover: (_s = (_r = (_q = colors.table) === null || _q === void 0 ? void 0 : _q.hover) === null || _r === void 0 ? void 0 : _r[100]) !== null && _s !== void 0 ? _s : (_t = colors.gray) === null || _t === void 0 ? void 0 : _t[50],
30
+ expandedBg: (0, outlineRung_1.liftToContrast)(expandedTint, rest, "light", MIN_HOVER_STEP),
31
+ softHover: (0, outlineRung_1.liftToContrast)((_u = (_t = (_s = colors.table) === null || _s === void 0 ? void 0 : _s.hover) === null || _t === void 0 ? void 0 : _t[100]) !== null && _u !== void 0 ? _u : (_v = colors.gray) === null || _v === void 0 ? void 0 : _v[50], rest, "light", MIN_HOVER_STEP),
18
32
  };
19
33
  };
20
34
  exports.getAccordionHoverColors = getAccordionHoverColors;
@@ -1 +1 @@
1
- {"version":3,"file":"Checkbox.styles.d.ts","sourceRoot":"","sources":["../../../src/Components/Checkbox/Checkbox.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAExD,eAAO,MAAM,QAAQ,EAAE,oBA4DtB,CAAC"}
1
+ {"version":3,"file":"Checkbox.styles.d.ts","sourceRoot":"","sources":["../../../src/Components/Checkbox/Checkbox.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAGxD,eAAO,MAAM,QAAQ,EAAE,oBAsEtB,CAAC"}
@@ -1,10 +1,17 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Checkbox = void 0;
4
+ const outlineRung_1 = require("../../Theme/tokens/builders/outlineRung");
4
5
  exports.Checkbox = {
5
6
  baseStyle: ({ theme, colorScheme = "primary" }) => {
6
7
  var _a;
7
8
  const palette = (_a = theme.colors[colorScheme]) !== null && _a !== void 0 ? _a : theme.colors.primary;
9
+ // A browser probe found the checked checkbox's hover repeating its own resting `[600]` fill.
10
+ // Chakra's stock control also carries a checked-hover at `_checked._hover` (this override
11
+ // nests the other way, `_hover._checked`) — two different key paths landing on the same
12
+ // selector, so whichever one the cascade picks must still differ from resting. Setting both
13
+ // paths to the same lifted value removes that ambiguity outright.
14
+ const hoverChecked = (0, outlineRung_1.resolveHoverTint)(palette[600], palette[600]);
8
15
  return {
9
16
  control: {
10
17
  width: "1.25rem",
@@ -27,13 +34,17 @@ exports.Checkbox = {
27
34
  _checked: {
28
35
  bg: palette[600],
29
36
  borderColor: palette[600],
37
+ _hover: {
38
+ bg: hoverChecked,
39
+ borderColor: hoverChecked,
40
+ },
30
41
  },
31
42
  _hover: {
32
43
  bg: theme.colors.background[100],
33
44
  borderColor: palette[400],
34
45
  _checked: {
35
- bg: palette[600],
36
- borderColor: palette[600],
46
+ bg: hoverChecked,
47
+ borderColor: hoverChecked,
37
48
  },
38
49
  _indeterminate: {
39
50
  bg: "none",
@@ -1 +1 @@
1
- {"version":3,"file":"EditModuleModal.d.ts","sourceRoot":"","sources":["../../../src/Components/CustomModulesTable/EditModuleModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAcnD,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AAEjE,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CA+DnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
1
+ {"version":3,"file":"EditModuleModal.d.ts","sourceRoot":"","sources":["../../../src/Components/CustomModulesTable/EditModuleModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAcnD,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AAEjE,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAkEnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
@@ -16,6 +16,10 @@ const EditModuleModal = ({ isOpen, onClose, initialName, isLoading, onSubmit, la
16
16
  if (isOpen)
17
17
  setName(initialName);
18
18
  }, [isOpen, initialName]);
19
- return ((0, jsx_runtime_1.jsxs)(react_2.Modal, { isOpen: isOpen, onClose: onClose, isCentered: true, children: [(0, jsx_runtime_1.jsx)(react_2.ModalOverlay, { backdropFilter: "blur(4px)" }), (0, jsx_runtime_1.jsxs)(react_2.ModalContent, { borderRadius: "2xl", overflow: "hidden", bg: (_a = colors === null || colors === void 0 ? void 0 : colors.background) === null || _a === void 0 ? void 0 : _a[50], children: [(0, jsx_runtime_1.jsx)(react_2.ModalHeader, { borderBottom: "1px solid", borderColor: (_c = (_b = colors === null || colors === void 0 ? void 0 : colors.boxborder) === null || _b === void 0 ? void 0 : _b[200]) !== null && _c !== void 0 ? _c : (_d = colors === null || colors === void 0 ? void 0 : colors.gray) === null || _d === void 0 ? void 0 : _d[200], fontSize: "1.05rem", fontWeight: 600, children: labels.editModuleTitle }), (0, jsx_runtime_1.jsx)(react_2.ModalCloseButton, {}), (0, jsx_runtime_1.jsxs)(react_2.ModalBody, { py: 6, children: [(0, jsx_runtime_1.jsx)(react_2.Input, { value: name, onChange: (e) => setName(e.target.value), placeholder: labels.moduleNamePlaceholder, borderColor: (_f = (_e = colors === null || colors === void 0 ? void 0 : colors.boxborder) === null || _e === void 0 ? void 0 : _e[200]) !== null && _f !== void 0 ? _f : (_g = colors === null || colors === void 0 ? void 0 : colors.gray) === null || _g === void 0 ? void 0 : _g[200], mb: 5 }), (0, jsx_runtime_1.jsxs)(react_2.HStack, { justifyContent: "flex-end", spacing: 3, children: [(0, jsx_runtime_1.jsx)(Button_1.default, { label: labels.cancel, onClick: onClose, variant: "outline", colorScheme: "gray", size: "sm" }), (0, jsx_runtime_1.jsx)(Button_1.default, { label: labels.update, onClick: () => onSubmit(name.trim()), colorScheme: "primary", size: "sm", isLoading: isLoading, isDisabled: !name.trim() })] })] })] })] }));
19
+ return ((0, jsx_runtime_1.jsxs)(react_2.Modal, { isOpen: isOpen, onClose: onClose, isCentered: true, children: [(0, jsx_runtime_1.jsx)(react_2.ModalOverlay, { backdropFilter: "blur(4px)" }), (0, jsx_runtime_1.jsxs)(react_2.ModalContent, { borderRadius: "2xl", overflow: "hidden", bg: (_a = colors === null || colors === void 0 ? void 0 : colors.background) === null || _a === void 0 ? void 0 : _a[50], children: [(0, jsx_runtime_1.jsx)(react_2.ModalHeader, { borderBottom: "1px solid", borderColor: (_c = (_b = colors === null || colors === void 0 ? void 0 : colors.boxborder) === null || _b === void 0 ? void 0 : _b[200]) !== null && _c !== void 0 ? _c : (_d = colors === null || colors === void 0 ? void 0 : colors.gray) === null || _d === void 0 ? void 0 : _d[200], fontSize: "1.05rem", fontWeight: 600, children: labels.editModuleTitle }), (0, jsx_runtime_1.jsx)(react_2.ModalCloseButton, {}), (0, jsx_runtime_1.jsxs)(react_2.ModalBody, { py: 6, children: [(0, jsx_runtime_1.jsx)(react_2.Input, { value: name, onChange: (e) => setName(e.target.value), placeholder: labels.moduleNamePlaceholder,
20
+ // [200] is the decorative divider rung (~1.2:1, correct for the ModalHeader border
21
+ // above) — a real control's resting outline needs 1.4.11's 3:1, which is what every
22
+ // other input in this library (TextInput, NumberInput, DatePicker) reads from [800].
23
+ borderColor: (_f = (_e = colors === null || colors === void 0 ? void 0 : colors.boxborder) === null || _e === void 0 ? void 0 : _e[800]) !== null && _f !== void 0 ? _f : (_g = colors === null || colors === void 0 ? void 0 : colors.gray) === null || _g === void 0 ? void 0 : _g[400], mb: 5 }), (0, jsx_runtime_1.jsxs)(react_2.HStack, { justifyContent: "flex-end", spacing: 3, children: [(0, jsx_runtime_1.jsx)(Button_1.default, { label: labels.cancel, onClick: onClose, variant: "outline", colorScheme: "gray", size: "sm" }), (0, jsx_runtime_1.jsx)(Button_1.default, { label: labels.update, onClick: () => onSubmit(name.trim()), colorScheme: "primary", size: "sm", isLoading: isLoading, isDisabled: !name.trim() })] })] })] })] }));
20
24
  };
21
25
  exports.default = EditModuleModal;
@@ -1 +1 @@
1
- {"version":3,"file":"CalendarPanel.d.ts","sourceRoot":"","sources":["../../../src/Components/DatePicker/CalendarPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,MAAM,MAAM,kBAAkB,GAAG;IAC/B,YAAY,EAAE,IAAI,CAAC;IACnB,eAAe,EAAE,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,KAAK,IAAI,CAAC;IACzD,KAAK,EAAE,IAAI,CAAC;IACZ,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,IAAI,GAAG,IAAI,CAAC;IACtB,cAAc,EAAE,IAAI,GAAG,IAAI,CAAC;IAC5B,YAAY,EAAE,IAAI,GAAG,IAAI,CAAC;IAC1B,SAAS,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,KAAK,OAAO,CAAC;IACzC,QAAQ,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,KAAK,OAAO,CAAC;IACxC,OAAO,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,KAAK,OAAO,CAAC;IACvC,OAAO,CAAC,EAAE,IAAI,CAAC;IACf,OAAO,CAAC,EAAE,IAAI,CAAC;IACf,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,WAAW,EAAE,CAAC,CAAC,EAAE,IAAI,KAAK,IAAI,CAAC;IAE/B,WAAW,CAAC,EAAE,IAAI,GAAG,IAAI,CAAC;IAC1B,UAAU,CAAC,EAAE,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,KAAK,IAAI,CAAC;IACtC,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAClC,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAsRtD,CAAC;AAEF,eAAe,aAAa,CAAC"}
1
+ {"version":3,"file":"CalendarPanel.d.ts","sourceRoot":"","sources":["../../../src/Components/DatePicker/CalendarPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,MAAM,MAAM,kBAAkB,GAAG;IAC/B,YAAY,EAAE,IAAI,CAAC;IACnB,eAAe,EAAE,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,KAAK,IAAI,CAAC;IACzD,KAAK,EAAE,IAAI,CAAC;IACZ,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,IAAI,GAAG,IAAI,CAAC;IACtB,cAAc,EAAE,IAAI,GAAG,IAAI,CAAC;IAC5B,YAAY,EAAE,IAAI,GAAG,IAAI,CAAC;IAC1B,SAAS,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,KAAK,OAAO,CAAC;IACzC,QAAQ,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,KAAK,OAAO,CAAC;IACxC,OAAO,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,KAAK,OAAO,CAAC;IACvC,OAAO,CAAC,EAAE,IAAI,CAAC;IACf,OAAO,CAAC,EAAE,IAAI,CAAC;IACf,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,WAAW,EAAE,CAAC,CAAC,EAAE,IAAI,KAAK,IAAI,CAAC;IAE/B,WAAW,CAAC,EAAE,IAAI,GAAG,IAAI,CAAC;IAC1B,UAAU,CAAC,EAAE,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,KAAK,IAAI,CAAC;IACtC,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAClC,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAwRtD,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -27,7 +27,9 @@ const CalendarPanel = ({ currentMonth, setCurrentMonth, today, isRange, tempDate
27
27
  const hasRange = !!(rangeStart && rangeEnd && !isSameDay(rangeStart, rangeEnd));
28
28
  const selectStyles = {
29
29
  border: "1px solid",
30
- borderColor: (_a = theme.colors.boxborder) === null || _a === void 0 ? void 0 : _a[300],
30
+ // boxborder[500] is the control-outline rung the sibling pickers already use; boxborder[300]
31
+ // is decorative and measured 1.85:1 on the dark canvas — the select read as borderless.
32
+ borderColor: (_a = theme.colors.boxborder) === null || _a === void 0 ? void 0 : _a[500],
31
33
  borderRadius: "md",
32
34
  px: 2,
33
35
  py: 1,
@@ -1 +1 @@
1
- {"version":3,"file":"joditThemeVars.d.ts","sourceRoot":"","sources":["../../../src/Components/Editor/joditThemeVars.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAE7D;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,iBAAiB,GAAI,QAAQ,YAAY,EAAE,QAAQ,OAAO,KAAG,aAkDzE,CAAC"}
1
+ {"version":3,"file":"joditThemeVars.d.ts","sourceRoot":"","sources":["../../../src/Components/Editor/joditThemeVars.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAE7D;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,iBAAiB,GAAI,QAAQ,YAAY,EAAE,QAAQ,OAAO,KAAG,aA2DzE,CAAC"}
@@ -40,6 +40,15 @@ const getJoditThemeVars = (colors, isDark) => {
40
40
  if (isDark) {
41
41
  return {
42
42
  ...shared,
43
+ // `.jodit-workplace`'s own background rule in jodit.css (`.jodit-container:not(.jodit_inline)
44
+ // .jodit-workplace { background-color: var(--jd-color-background-default) }`) is NOT scoped
45
+ // under `.jodit_theme_dark` — that scope only re-themes the *border* on this selector, never
46
+ // the background. `--jd-color-background-default` itself is declared once, at `:root`, as
47
+ // `var(--jd-color-white)`, and our `--jd-color-white` override lives on this instance's wrapper
48
+ // (a descendant), so it never reaches `:root`'s own computed value. Left unset here, the
49
+ // workplace canvas fell back to Jodit's own white default even with `.jodit_theme_dark` active
50
+ // — this is the reported "canvas renders white in dark mode" bug.
51
+ "--jd-color-background-default": colors.backgroundColor.main, // .jodit-workplace canvas bg
43
52
  "--jd-dark-background-color": colors.backgroundColor.main, // canvas / toolbar-box / wysiwyg bg
44
53
  "--jd-dark-toolbar-color": colors.backgroundColor.secondary, // toolbar + status-bar bg
45
54
  "--jd-dark-text-color": colors.text[900], // body/button/status-bar ink
@@ -1 +1 @@
1
- {"version":3,"file":"FilePreview.d.ts","sourceRoot":"","sources":["../../../src/Components/FilePreview/FilePreview.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAyBxC,OAAO,EAEL,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,oBAAoB,CAAC;AA6B5B,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAyKlD,CAAC;AAEF,kFAAkF;AAClF,eAAO,MAAM,kBAAkB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CAuEhE,CAAC;AAEF,eAAe,WAAW,CAAC"}
1
+ {"version":3,"file":"FilePreview.d.ts","sourceRoot":"","sources":["../../../src/Components/FilePreview/FilePreview.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAyBxC,OAAO,EAEL,gBAAgB,EAChB,uBAAuB,EACxB,MAAM,oBAAoB,CAAC;AA6B5B,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAyKlD,CAAC;AAEF,kFAAkF;AAClF,eAAO,MAAM,kBAAkB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CAwEhE,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -77,9 +77,11 @@ const FilePreview = ({ isOpen, onClose, fileUrl, fileName, fileType, hideDownloa
77
77
  exports.FilePreview = FilePreview;
78
78
  /** Thumbnail with a hover "preview" affordance that opens {@link FilePreview}. */
79
79
  const FilePreviewTrigger = ({ fileUrl, fileName, fileType, thumbWidth = "100px", thumbHeight = "60px", hideDownload = false, }) => {
80
+ var _a, _b;
81
+ const theme = (0, useCustomTheme_1.useCustomTheme)();
80
82
  const { isOpen, onOpen, onClose } = (0, react_2.useDisclosure)();
81
83
  const kind = fileType || inferKind(fileUrl, fileName);
82
- return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsxs)(react_2.Box, { position: "relative", display: "inline-flex", alignItems: "center", justifyContent: "center", role: "group", maxW: thumbWidth, minW: "40px", minH: thumbHeight, borderRadius: "8px", overflow: "hidden", cursor: "pointer", onClick: onOpen, children: [kind === "image" ? ((0, jsx_runtime_1.jsx)(react_2.Image, { src: fileUrl, alt: fileName || "file", maxH: thumbHeight, maxW: thumbWidth, objectFit: "contain", borderRadius: "8px" })) : ((0, jsx_runtime_1.jsx)(react_2.Flex, { align: "center", justify: "center", boxSize: thumbHeight, bg: "gray.100", borderRadius: "8px", children: (0, jsx_runtime_1.jsx)(lucide_react_1.Eye, { size: 18 }) })), (0, jsx_runtime_1.jsx)(react_2.Flex, { position: "absolute", inset: 0, align: "center", justify: "center", bg: "blackAlpha.500", color: "white", opacity: 0, transition: "opacity 0.15s ease", _groupHover: { opacity: 1 }, children: (0, jsx_runtime_1.jsx)(lucide_react_1.Eye, { size: 18 }) })] }), (0, jsx_runtime_1.jsx)(exports.FilePreview, { isOpen: isOpen, onClose: onClose, fileUrl: fileUrl, fileName: fileName, fileType: fileType, hideDownload: hideDownload })] }));
84
+ return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsxs)(react_2.Box, { position: "relative", display: "inline-flex", alignItems: "center", justifyContent: "center", role: "group", maxW: thumbWidth, minW: "40px", minH: thumbHeight, borderRadius: "8px", overflow: "hidden", cursor: "pointer", onClick: onOpen, children: [kind === "image" ? ((0, jsx_runtime_1.jsx)(react_2.Image, { src: fileUrl, alt: fileName || "file", maxH: thumbHeight, maxW: thumbWidth, objectFit: "contain", borderRadius: "8px" })) : ((0, jsx_runtime_1.jsx)(react_2.Flex, { align: "center", justify: "center", boxSize: thumbHeight, bg: (_b = (_a = theme.colors.gray) === null || _a === void 0 ? void 0 : _a[100]) !== null && _b !== void 0 ? _b : "#EDF2F7", borderRadius: "8px", children: (0, jsx_runtime_1.jsx)(lucide_react_1.Eye, { size: 18 }) })), (0, jsx_runtime_1.jsx)(react_2.Flex, { position: "absolute", inset: 0, align: "center", justify: "center", bg: "blackAlpha.500", color: "white", opacity: 0, transition: "opacity 0.15s ease", _groupHover: { opacity: 1 }, children: (0, jsx_runtime_1.jsx)(lucide_react_1.Eye, { size: 18 }) })] }), (0, jsx_runtime_1.jsx)(exports.FilePreview, { isOpen: isOpen, onClose: onClose, fileUrl: fileUrl, fileName: fileName, fileType: fileType, hideDownload: hideDownload })] }));
83
85
  };
84
86
  exports.FilePreviewTrigger = FilePreviewTrigger;
85
87
  exports.default = exports.FilePreview;
@@ -73,8 +73,8 @@ const FileUploader = ({ maxFiles = 10, maxTotalSize = 20, onFilesChange, acceptT
73
73
  // ✅ Convert ["png","pdf","zip"] → ".png,.pdf,.zip" for input accept
74
74
  const acceptString = acceptTypes.map((ext) => `.${ext}`).join(",");
75
75
  return ((0, jsx_runtime_1.jsxs)(react_2.Box, { maxW: "500px", mx: "auto", p: 6, children: [(0, jsx_runtime_1.jsxs)(react_2.Text, { fontSize: "sm", color: "gray.600", mb: 4, children: ["Files Uploaded:", " ", (0, jsx_runtime_1.jsxs)(react_2.Text, { as: "span", fontWeight: "medium", color: accentColor, children: [uploadedFiles.length, " / ", maxFiles] }), " ", "| Total size:", " ", (0, jsx_runtime_1.jsxs)(react_2.Text, { as: "span", fontWeight: "medium", children: [formatFileSize(totalSize), " / ", maxTotalSize, " MB"] })] }), (0, jsx_runtime_1.jsxs)(react_2.Box, { border: "1px dashed", borderColor: "gray.300", borderRadius: "md", p: 1, mt: 1, mb: 1, children: [uploadedFiles.length > 0 && ((0, jsx_runtime_1.jsx)(react_2.Box, { children: (0, jsx_runtime_1.jsx)(react_2.Grid, { templateColumns: "repeat(2, 1fr)", gap: 3, children: uploadedFiles.map((file) => {
76
- var _a;
77
- return ((0, jsx_runtime_1.jsxs)(react_2.Flex, { align: "center", justify: "space-between", border: "1px solid", borderColor: "gray.200", borderRadius: "md", pl: 1, bg: "gray.50", children: [(0, jsx_runtime_1.jsxs)(react_2.HStack, { spacing: 3, flex: "1", minW: "0", children: [file.previewUrl ? ((0, jsx_runtime_1.jsx)(react_2.Image, { src: file.previewUrl, alt: file.name, boxSize: "28px", borderRadius: "sm", objectFit: "cover" })) : ((0, jsx_runtime_1.jsx)(react_2.Box, { boxSize: "28px", borderRadius: "sm", bg: "gray.200", display: "flex", alignItems: "center", justifyContent: "center", fontSize: "xs", color: "gray.600", children: (_a = file.name.split(".").pop()) === null || _a === void 0 ? void 0 : _a.toUpperCase() })), (0, jsx_runtime_1.jsxs)(react_2.Box, { minW: "0", children: [(0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: "sm", fontWeight: "medium", noOfLines: 1, children: file.name }), (0, jsx_runtime_1.jsxs)(react_2.Text, { fontSize: "xs", color: "gray.600", children: ["(", formatFileSize(file.size), ")"] })] })] }), (0, jsx_runtime_1.jsx)(react_2.HStack, { spacing: 1, children: (0, jsx_runtime_1.jsx)(react_2.Tooltip, { label: "Remove", children: (0, jsx_runtime_1.jsx)(react_2.IconButton, { "aria-label": "Remove", icon: (0, jsx_runtime_1.jsx)(lucide_react_1.X, { size: 14 }), size: "xs", variant: "ghost", colorScheme: "red", onClick: () => removeFile(file.id) }) }) })] }, file.id));
76
+ var _a, _b, _c, _d, _e, _f, _g;
77
+ return ((0, jsx_runtime_1.jsxs)(react_2.Flex, { align: "center", justify: "space-between", border: "1px solid", borderColor: "gray.200", borderRadius: "md", pl: 1, bg: colors.backgroundColor.secondary, children: [(0, jsx_runtime_1.jsxs)(react_2.HStack, { spacing: 3, flex: "1", minW: "0", children: [file.previewUrl ? ((0, jsx_runtime_1.jsx)(react_2.Image, { src: file.previewUrl, alt: file.name, boxSize: "28px", borderRadius: "sm", objectFit: "cover" })) : ((0, jsx_runtime_1.jsx)(react_2.Box, { boxSize: "28px", borderRadius: "sm", bg: (_b = (_a = colors.gray) === null || _a === void 0 ? void 0 : _a[200]) !== null && _b !== void 0 ? _b : "#e5e7eb", display: "flex", alignItems: "center", justifyContent: "center", fontSize: "xs", color: (_d = (_c = colors.gray) === null || _c === void 0 ? void 0 : _c[600]) !== null && _d !== void 0 ? _d : "#4A5568", children: (_e = file.name.split(".").pop()) === null || _e === void 0 ? void 0 : _e.toUpperCase() })), (0, jsx_runtime_1.jsxs)(react_2.Box, { minW: "0", children: [(0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: "sm", fontWeight: "medium", noOfLines: 1, children: file.name }), (0, jsx_runtime_1.jsxs)(react_2.Text, { fontSize: "xs", color: (_g = (_f = colors.gray) === null || _f === void 0 ? void 0 : _f[600]) !== null && _g !== void 0 ? _g : "#4A5568", children: ["(", formatFileSize(file.size), ")"] })] })] }), (0, jsx_runtime_1.jsx)(react_2.HStack, { spacing: 1, children: (0, jsx_runtime_1.jsx)(react_2.Tooltip, { label: "Remove", children: (0, jsx_runtime_1.jsx)(react_2.IconButton, { "aria-label": "Remove", icon: (0, jsx_runtime_1.jsx)(lucide_react_1.X, { size: 14 }), size: "xs", variant: "ghost", colorScheme: "red", onClick: () => removeFile(file.id) }) }) })] }, file.id));
78
78
  }) }) })), (0, jsx_runtime_1.jsx)("input", { ref: fileInputRef, type: "file", multiple: true, accept: acceptString, onChange: handleFileInput, style: { display: "none" } }), (0, jsx_runtime_1.jsxs)(react_2.Box, { p: uploadedFiles.length ? 0 : 5, mb: 2, textAlign: uploadedFiles.length ? "left" : "center", pt: uploadedFiles.length ? 5 : 5, transition: "all 0.2s", onDrop: handleDrop, onDragOver: handleDragOver, onDragLeave: handleDragLeave, cursor: "pointer", onClick: handleBrowseClick, children: [(0, jsx_runtime_1.jsx)(react_2.Box, { children: (0, jsx_runtime_1.jsxs)(react_2.Text, { fontWeight: "medium", fontSize: "md", children: ["Drag and drop the files here, or", (0, jsx_runtime_1.jsx)(react_2.Box, { as: "span", color: accentColor, ml: 1, children: "Click here" })] }) }), (0, jsx_runtime_1.jsxs)(react_2.Text, { fontSize: "xs", color: "gray.500", children: ["Supported formats: ", acceptTypes.map((t) => t.toUpperCase()).join(", "), "."] })] })] })] }));
79
79
  };
80
80
  exports.default = FileUploader;
@@ -126,7 +126,7 @@ panelPadding = 3, clearAllButton = true, onClearAllHandler,
126
126
  border: none;
127
127
  cursor: pointer;
128
128
  }
129
- ` }), (0, jsx_runtime_1.jsxs)(react_2.Box, { w: "full", position: "relative", h: { base: "24px", md: "30px" }, display: "flex", alignItems: "center", children: [(0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: "0", right: "0", height: "6px", bg: "gray.200", borderRadius: "full" }), (0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${minPercent}%`, width: `${maxPercent - minPercent}%`, height: "6px", style: { background: `linear-gradient(to right, ${primaryColor}, ${secondaryColor})` }, borderRadius: "full", boxShadow: `0 0 8px ${primaryGlowColor}` }), (0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${minPercent}%`, transform: "translate(-50%, 0)", w: { base: "16px", md: "20px" }, h: { base: "16px", md: "20px" }, borderRadius: "full", bg: theme.colors.background[50], border: "3px solid", borderColor: primaryColor, boxShadow: thumbShadow, zIndex: 2 }), (0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${maxPercent}%`, transform: "translate(-50%, 0)", w: { base: "16px", md: "20px" }, h: { base: "16px", md: "20px" }, borderRadius: "full", bg: theme.colors.background[50], border: "3px solid", borderColor: secondaryColor, boxShadow: thumbShadow, zIndex: 2 }), (0, jsx_runtime_1.jsxs)(react_2.Box, { position: "absolute", left: `${minPercent}%`, top: { base: "-18px", md: "-22px" }, transform: "translate(-50%, -100%)", px: 2, py: 1, bg: theme.colors.background[50], border: `1px solid ${theme.colors.gray[200]}`, borderRadius: "6px", fontSize: "10px", color: theme.colors.gray[700], boxShadow: "sm", zIndex: 3, children: [currentMin, range.unit ? ` ${range.unit}` : ""] }), (0, jsx_runtime_1.jsxs)(react_2.Box, { position: "absolute", left: `${maxPercent}%`, top: { base: "-18px", md: "-22px" }, transform: "translate(-50%, -100%)", px: 2, py: 1, bg: theme.colors.background[50], border: `1px solid ${theme.colors.gray[200]}`, borderRadius: "6px", fontSize: "10px", color: theme.colors.gray[700], boxShadow: "sm", zIndex: 3, children: [currentMax, range.unit ? ` ${range.unit}` : ""] }), [0, 25, 50, 75, 100].map((p) => ((0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${p}%`, bottom: "-8px", transform: "translateX(-50%)", w: "1px", h: "8px", bg: theme.colors.gray[300] }, `tick-${p}`))), (0, jsx_runtime_1.jsx)("input", { type: "range", min: range.min, max: range.max, step: step, value: currentMin, className: "custom-range-slider", onChange: (e) => {
129
+ ` }), (0, jsx_runtime_1.jsxs)(react_2.Box, { w: "full", position: "relative", h: { base: "24px", md: "30px" }, display: "flex", alignItems: "center", children: [(0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: "0", right: "0", height: "6px", bg: theme.colors.gray[200], borderRadius: "full" }), (0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${minPercent}%`, width: `${maxPercent - minPercent}%`, height: "6px", style: { background: `linear-gradient(to right, ${primaryColor}, ${secondaryColor})` }, borderRadius: "full", boxShadow: `0 0 8px ${primaryGlowColor}` }), (0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${minPercent}%`, transform: "translate(-50%, 0)", w: { base: "16px", md: "20px" }, h: { base: "16px", md: "20px" }, borderRadius: "full", bg: theme.colors.background[50], border: "3px solid", borderColor: primaryColor, boxShadow: thumbShadow, zIndex: 2 }), (0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${maxPercent}%`, transform: "translate(-50%, 0)", w: { base: "16px", md: "20px" }, h: { base: "16px", md: "20px" }, borderRadius: "full", bg: theme.colors.background[50], border: "3px solid", borderColor: secondaryColor, boxShadow: thumbShadow, zIndex: 2 }), (0, jsx_runtime_1.jsxs)(react_2.Box, { position: "absolute", left: `${minPercent}%`, top: { base: "-18px", md: "-22px" }, transform: "translate(-50%, -100%)", px: 2, py: 1, bg: theme.colors.background[50], border: `1px solid ${theme.colors.gray[200]}`, borderRadius: "6px", fontSize: "10px", color: theme.colors.gray[700], boxShadow: "sm", zIndex: 3, children: [currentMin, range.unit ? ` ${range.unit}` : ""] }), (0, jsx_runtime_1.jsxs)(react_2.Box, { position: "absolute", left: `${maxPercent}%`, top: { base: "-18px", md: "-22px" }, transform: "translate(-50%, -100%)", px: 2, py: 1, bg: theme.colors.background[50], border: `1px solid ${theme.colors.gray[200]}`, borderRadius: "6px", fontSize: "10px", color: theme.colors.gray[700], boxShadow: "sm", zIndex: 3, children: [currentMax, range.unit ? ` ${range.unit}` : ""] }), [0, 25, 50, 75, 100].map((p) => ((0, jsx_runtime_1.jsx)(react_2.Box, { position: "absolute", left: `${p}%`, bottom: "-8px", transform: "translateX(-50%)", w: "1px", h: "8px", bg: theme.colors.gray[300] }, `tick-${p}`))), (0, jsx_runtime_1.jsx)("input", { type: "range", min: range.min, max: range.max, step: step, value: currentMin, className: "custom-range-slider", onChange: (e) => {
130
130
  const min = Math.min(Number(e.target.value), currentMax - (step || 1));
131
131
  const nextVal = [min, currentMax];
132
132
  setInternalSelected((prev) => { const next = { ...prev, [section.id]: nextVal }; onChange === null || onChange === void 0 ? void 0 : onChange(next); return next; });
@@ -1 +1 @@
1
- {"version":3,"file":"NavigationBar.d.ts","sourceRoot":"","sources":["../../../src/Components/NavigationBar/NavigationBar.tsx"],"names":[],"mappings":"AAcA,OAAO,EAAa,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAU9D,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,EAC9B,WAAW,EACX,QAAQ,EACR,QAAQ,EACR,OAAO,EACP,QAAQ,EACR,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,cAAc,EACd,gBAAgB,EAChB,kBAA0B,GAC1B,EAAE,WAAW,2CAwKb"}
1
+ {"version":3,"file":"NavigationBar.d.ts","sourceRoot":"","sources":["../../../src/Components/NavigationBar/NavigationBar.tsx"],"names":[],"mappings":"AAcA,OAAO,EAAa,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAW9D,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,EAC9B,WAAW,EACX,QAAQ,EACR,QAAQ,EACR,OAAO,EACP,QAAQ,EACR,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,cAAc,EACd,gBAAgB,EAChB,kBAA0B,GAC1B,EAAE,WAAW,2CA+Kb"}
@@ -5,9 +5,10 @@ const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_1 = require("@chakra-ui/react");
6
6
  const useCustomTheme_1 = require("../../Theme/useCustomTheme");
7
7
  const accentText_1 = require("../../Theme/tokens/builders/accentText");
8
+ const outlineRung_1 = require("../../Theme/tokens/builders/outlineRung");
8
9
  const lucide_react_1 = require("lucide-react");
9
10
  function NavBar({ userAvathar, userName, userRole, navMenu, moreIcon, handleNavOnClick, handleLogout, logoutText, navigationBarText, sideBarToggole, onSideBarToggole, forceSideBarToggle = false, }) {
10
- var _a, _b, _c, _d, _e;
11
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
11
12
  const theme = (0, useCustomTheme_1.useCustomTheme)();
12
13
  // Shared rounded pill affordance for the bar's icon controls.
13
14
  const iconButtonStyle = {
@@ -20,6 +21,9 @@ function NavBar({ userAvathar, userName, userRole, navMenu, moreIcon, handleNavO
20
21
  transition: "background 0.15s",
21
22
  _hover: { bg: "blackAlpha.50" },
22
23
  };
24
+ // For a near-neutral brand (e.g. zinc), `primary[50]` is itself a pale near-white tint — on
25
+ // the menu's own near-white surface that measured as low as ~1.02:1, an invisible hover.
26
+ const menuHoverBg = (0, outlineRung_1.resolveHoverTint)(theme.colors.primary[50], (_d = (_b = (_a = theme.colors.backgroundColor) === null || _a === void 0 ? void 0 : _a.light) !== null && _b !== void 0 ? _b : (_c = theme.colors.background) === null || _c === void 0 ? void 0 : _c[50]) !== null && _d !== void 0 ? _d : "#ffffff");
23
27
  // Light elevated pill item.
24
28
  const menuItemStyle = {
25
29
  bg: "transparent",
@@ -32,16 +36,16 @@ function NavBar({ userAvathar, userName, userRole, navMenu, moreIcon, handleNavO
32
36
  color: "gray.700",
33
37
  gap: theme.space["2"],
34
38
  transition: "background 0.12s",
35
- _hover: { bg: theme.colors.primary[50], color: theme.colors.primary[700] },
36
- _focus: { bg: theme.colors.primary[50], color: theme.colors.primary[700] },
37
- _active: { bg: theme.colors.primary[50], color: theme.colors.primary[700] },
39
+ _hover: { bg: menuHoverBg, color: theme.colors.primary[700] },
40
+ _focus: { bg: menuHoverBg, color: theme.colors.primary[700] },
41
+ _active: { bg: menuHoverBg, color: theme.colors.primary[700] },
38
42
  };
39
- return ((0, jsx_runtime_1.jsx)(react_1.Box, { bg: theme.colors.backgroundColor.light, px: 4, borderBottom: "1px solid", borderColor: "blackAlpha.100", children: (0, jsx_runtime_1.jsxs)(react_1.Flex, { h: 16, alignItems: "center", justifyContent: "space-between", children: [(0, jsx_runtime_1.jsxs)(react_1.Box, { display: "flex", gap: 1.5, alignItems: "center", children: [(0, jsx_runtime_1.jsx)(react_1.Box, { onClick: () => onSideBarToggole === null || onSideBarToggole === void 0 ? void 0 : onSideBarToggole(), display: forceSideBarToggle ? "flex" : { base: "flex", lg: "none" }, "aria-label": sideBarToggole ? "Close navigation menu" : "Open navigation menu", ...iconButtonStyle, children: sideBarToggole ? ((0, jsx_runtime_1.jsx)(lucide_react_1.PanelLeftClose, { size: "1.25rem" })) : ((0, jsx_runtime_1.jsx)(lucide_react_1.PanelRightClose, { size: "1.25rem" })) }), (navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.onIconClick) && ((0, jsx_runtime_1.jsx)(react_1.Box, { ...iconButtonStyle, display: "flex", onClick: () => { var _a; return (_a = navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.onIconClick) === null || _a === void 0 ? void 0 : _a.call(navigationBarText); }, children: (0, jsx_runtime_1.jsx)(lucide_react_1.CircleArrowLeft, { size: "1.25rem", color: (_b = (_a = theme === null || theme === void 0 ? void 0 : theme.colors) === null || _a === void 0 ? void 0 : _a.text) === null || _b === void 0 ? void 0 : _b[500] }) })), (navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.text) && ((0, jsx_runtime_1.jsx)(react_1.Text, { color: (0, accentText_1.accentTextOnCanvas)((_c = theme === null || theme === void 0 ? void 0 : theme.colors) === null || _c === void 0 ? void 0 : _c.secondary, (_e = (_d = theme === null || theme === void 0 ? void 0 : theme.colors) === null || _d === void 0 ? void 0 : _d.backgroundColor) === null || _e === void 0 ? void 0 : _e.light), fontSize: "1.25rem", fontWeight: 600, fontFamily: "open-sans, sans-serif", letterSpacing: "-0.013rem", children: navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.text }))] }), (0, jsx_runtime_1.jsx)(react_1.Flex, { minW: 0, flexShrink: 1, children: (0, jsx_runtime_1.jsxs)(react_1.Stack, { direction: "row", alignItems: "center", spacing: 4, minW: 0, children: [moreIcon && ((0, jsx_runtime_1.jsx)(react_1.Box, { display: "flex", alignItems: "center", minW: 0, children: moreIcon })), (0, jsx_runtime_1.jsxs)(react_1.Menu, { children: [(0, jsx_runtime_1.jsx)(react_1.MenuButton, { as: react_1.Button, rounded: "full", variant: "link", cursor: "pointer", minW: 0, flexShrink: 0, children: (0, jsx_runtime_1.jsx)(react_1.Avatar, { size: "sm", name: userName, src: userAvathar }) }), (0, jsx_runtime_1.jsx)(react_1.MenuList, { alignItems: "center", zIndex: 5, p: 0, py: "0.375rem", bg: theme.colors.backgroundColor.light,
43
+ return ((0, jsx_runtime_1.jsx)(react_1.Box, { bg: theme.colors.backgroundColor.light, px: 4, borderBottom: "1px solid", borderColor: "blackAlpha.100", children: (0, jsx_runtime_1.jsxs)(react_1.Flex, { h: 16, alignItems: "center", justifyContent: "space-between", children: [(0, jsx_runtime_1.jsxs)(react_1.Box, { display: "flex", gap: 1.5, alignItems: "center", children: [(0, jsx_runtime_1.jsx)(react_1.Box, { onClick: () => onSideBarToggole === null || onSideBarToggole === void 0 ? void 0 : onSideBarToggole(), display: forceSideBarToggle ? "flex" : { base: "flex", lg: "none" }, "aria-label": sideBarToggole ? "Close navigation menu" : "Open navigation menu", ...iconButtonStyle, children: sideBarToggole ? ((0, jsx_runtime_1.jsx)(lucide_react_1.PanelLeftClose, { size: "1.25rem" })) : ((0, jsx_runtime_1.jsx)(lucide_react_1.PanelRightClose, { size: "1.25rem" })) }), (navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.onIconClick) && ((0, jsx_runtime_1.jsx)(react_1.Box, { ...iconButtonStyle, display: "flex", onClick: () => { var _a; return (_a = navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.onIconClick) === null || _a === void 0 ? void 0 : _a.call(navigationBarText); }, children: (0, jsx_runtime_1.jsx)(lucide_react_1.CircleArrowLeft, { size: "1.25rem", color: (_f = (_e = theme === null || theme === void 0 ? void 0 : theme.colors) === null || _e === void 0 ? void 0 : _e.text) === null || _f === void 0 ? void 0 : _f[500] }) })), (navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.text) && ((0, jsx_runtime_1.jsx)(react_1.Text, { color: (0, accentText_1.accentTextOnCanvas)((_g = theme === null || theme === void 0 ? void 0 : theme.colors) === null || _g === void 0 ? void 0 : _g.secondary, (_j = (_h = theme === null || theme === void 0 ? void 0 : theme.colors) === null || _h === void 0 ? void 0 : _h.backgroundColor) === null || _j === void 0 ? void 0 : _j.light), fontSize: "1.25rem", fontWeight: 600, fontFamily: "open-sans, sans-serif", letterSpacing: "-0.013rem", children: navigationBarText === null || navigationBarText === void 0 ? void 0 : navigationBarText.text }))] }), (0, jsx_runtime_1.jsx)(react_1.Flex, { minW: 0, flexShrink: 1, children: (0, jsx_runtime_1.jsxs)(react_1.Stack, { direction: "row", alignItems: "center", spacing: 4, minW: 0, children: [moreIcon && ((0, jsx_runtime_1.jsx)(react_1.Box, { display: "flex", alignItems: "center", minW: 0, children: moreIcon })), (0, jsx_runtime_1.jsxs)(react_1.Menu, { children: [(0, jsx_runtime_1.jsx)(react_1.MenuButton, { as: react_1.Button, rounded: "full", variant: "link", cursor: "pointer", minW: 0, flexShrink: 0, children: (0, jsx_runtime_1.jsx)(react_1.Avatar, { size: "sm", name: userName, src: userAvathar }) }), (0, jsx_runtime_1.jsx)(react_1.MenuList, { alignItems: "center", zIndex: 5, p: 0, py: "0.375rem", bg: theme.colors.backgroundColor.light,
40
44
  // Chakra's MenuItem renders `background: var(--menu-bg)` at rest; its MenuList
41
45
  // baseStyle hardcodes that var to "#fff" (gated behind `_dark`, which this theme-swap
42
46
  // app never triggers). The `bg` prop above only recolors the list itself, not the
43
47
  // inherited var, so items fall back to white until hover/focus — set the var too.
44
- sx: { "--menu-bg": theme.colors.backgroundColor.light }, border: "1px solid", borderColor: "blackAlpha.100", borderRadius: "0.75rem", boxShadow: "lg", color: "gray.700", overflow: "hidden", children: (0, jsx_runtime_1.jsxs)(react_1.Box, { display: "flex", flexDirection: "column", maxH: "90vh", children: [(0, jsx_runtime_1.jsx)(react_1.Center, { pt: 4, pb: 2, children: (0, jsx_runtime_1.jsx)(react_1.Avatar, { size: "xl", name: userName, src: userAvathar }) }), (0, jsx_runtime_1.jsxs)(react_1.Center, { flexDirection: "column", gap: "0.125rem", pb: 2, px: 4, children: [(0, jsx_runtime_1.jsx)(react_1.Text, { fontWeight: 600, fontSize: "14px", color: "gray.800", isTruncated: true, maxW: "100%", children: userName }), userRole && ((0, jsx_runtime_1.jsx)(react_1.Text, { fontSize: "11px", color: "gray.500", isTruncated: true, maxW: "100%", children: userRole }))] }), (0, jsx_runtime_1.jsx)(react_1.MenuDivider, { borderColor: "blackAlpha.100" }), (0, jsx_runtime_1.jsx)(react_1.Box, { flex: 1, overflowY: "auto", children: navMenu === null || navMenu === void 0 ? void 0 : navMenu.map((menu, idx) => {
48
+ sx: { "--menu-bg": theme.colors.backgroundColor.light }, border: "1px solid", borderColor: "blackAlpha.100", borderRadius: "0.75rem", boxShadow: "lg", color: theme.colors.text[900], overflow: "hidden", children: (0, jsx_runtime_1.jsxs)(react_1.Box, { display: "flex", flexDirection: "column", maxH: "90vh", children: [(0, jsx_runtime_1.jsx)(react_1.Center, { pt: 4, pb: 2, children: (0, jsx_runtime_1.jsx)(react_1.Avatar, { size: "xl", name: userName, src: userAvathar }) }), (0, jsx_runtime_1.jsxs)(react_1.Center, { flexDirection: "column", gap: "0.125rem", pb: 2, px: 4, children: [(0, jsx_runtime_1.jsx)(react_1.Text, { fontWeight: 600, fontSize: "14px", color: theme.colors.text[900], isTruncated: true, maxW: "100%", children: userName }), userRole && ((0, jsx_runtime_1.jsx)(react_1.Text, { fontSize: "11px", color: theme.colors.text[500], isTruncated: true, maxW: "100%", children: userRole }))] }), (0, jsx_runtime_1.jsx)(react_1.MenuDivider, { borderColor: "blackAlpha.100" }), (0, jsx_runtime_1.jsx)(react_1.Box, { flex: 1, overflowY: "auto", children: navMenu === null || navMenu === void 0 ? void 0 : navMenu.map((menu, idx) => {
45
49
  var _a, _b, _c;
46
50
  return ((0, jsx_runtime_1.jsxs)(react_1.MenuItem, { onClick: () => handleNavOnClick(menu.url), sx: menuItemStyle, children: [menu.icon && ((0, jsx_runtime_1.jsx)(react_1.Box, { display: "flex", alignItems: "center", flexShrink: 0, sx: { "& svg": { width: "16px", height: "16px" } }, children: menu === null || menu === void 0 ? void 0 : menu.icon })), (0, jsx_runtime_1.jsx)(react_1.Box, { children: menu.title })] }, `${String((_c = (_b = (_a = menu.id) !== null && _a !== void 0 ? _a : menu.url) !== null && _b !== void 0 ? _b : menu.title) !== null && _c !== void 0 ? _c : idx)}-${idx}`));
47
51
  }) }), (0, jsx_runtime_1.jsx)(react_1.MenuDivider, { borderColor: "blackAlpha.100" }), (0, jsx_runtime_1.jsxs)(react_1.MenuItem, { onClick: handleLogout, sx: {
@@ -1 +1 @@
1
- {"version":3,"file":"OrgSwitcher.d.ts","sourceRoot":"","sources":["../../../src/Components/OrgSwitcher/OrgSwitcher.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAkBzD,OAAO,EAGL,gBAAgB,EAGjB,MAAM,oBAAoB,CAAC;AA6C5B,QAAA,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CA4M3C,CAAC;AAEF,eAAe,WAAW,CAAC"}
1
+ {"version":3,"file":"OrgSwitcher.d.ts","sourceRoot":"","sources":["../../../src/Components/OrgSwitcher/OrgSwitcher.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAoBzD,OAAO,EAGL,gBAAgB,EAGjB,MAAM,oBAAoB,CAAC;AAkD5B,QAAA,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CA4N3C,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -5,6 +5,8 @@ const react_1 = require("react");
5
5
  const react_2 = require("@chakra-ui/react");
6
6
  const lucide_react_1 = require("lucide-react");
7
7
  const useCustomTheme_1 = require("../../Theme/useCustomTheme");
8
+ const accentText_1 = require("../../Theme/tokens/builders/accentText");
9
+ const outlineRung_1 = require("../../Theme/tokens/builders/outlineRung");
8
10
  const OrgSwitcherProps_1 = require("./OrgSwitcherProps");
9
11
  const sizeMap = {
10
12
  sm: { h: "32px", avatar: "22px", font: "0.8rem", sub: "0.65rem", px: 2 },
@@ -15,7 +17,12 @@ const Avatar = ({ org, boxSize, fontSize, }) => {
15
17
  if (org.logoUrl) {
16
18
  return ((0, jsx_runtime_1.jsx)(react_2.Image, { src: org.logoUrl, alt: org.name, boxSize: boxSize, borderRadius: "8px", objectFit: "cover", flexShrink: 0 }));
17
19
  }
18
- return ((0, jsx_runtime_1.jsx)(react_2.Flex, { align: "center", justify: "center", boxSize: boxSize, borderRadius: "8px", flexShrink: 0, bg: (0, OrgSwitcherProps_1.avatarColor)(org.name), color: "white", fontSize: fontSize, fontWeight: 700, children: (0, OrgSwitcherProps_1.orgInitial)(org.name) }));
20
+ // `AVATAR_COLORS` is a fixed 8-swatch palette hashed from the org name (not theme-derived, so
21
+ // it can't lean on a per-brand text rung). Two of the eight — amber `#F59E0B`, teal `#14B8A6` —
22
+ // measure 2.15:1 / 2.49:1 against hardcoded white, well under AA. `onFilled` is provably >=4.5
23
+ // against ANY fill, so it's the correct ink for an arbitrary, theme-independent swatch.
24
+ const fill = (0, OrgSwitcherProps_1.avatarColor)(org.name);
25
+ return ((0, jsx_runtime_1.jsx)(react_2.Flex, { align: "center", justify: "center", boxSize: boxSize, borderRadius: "8px", flexShrink: 0, bg: fill, color: (0, accentText_1.onFilled)(fill, "#ffffff", "#000000"), fontSize: fontSize, fontWeight: 700, children: (0, OrgSwitcherProps_1.orgInitial)(org.name) }));
19
26
  };
20
27
  const OrgSwitcher = ({ organizations, value, onChange, isLoading = false, isSearchable, searchThreshold = 6, triggerVariant = "ghost", size = "md", maxWidth = "200px", menuMinWidth = "280px", placeholder = "Select organization", ariaLabel = "Switch organization", showRole = true, }) => {
21
28
  var _a, _b, _c;
@@ -40,6 +47,11 @@ const OrgSwitcher = ({ organizations, value, onChange, isLoading = false, isSear
40
47
  : triggerVariant === "subtle"
41
48
  ? { bg: theme.colors.gray[50] }
42
49
  : { bg: "transparent" };
50
+ // `gray[100]` hover on a "transparent" trigger reads against whatever's actually behind it —
51
+ // this control lives in a navbar-like shell, so `backgroundColor.light` is that surface. For a
52
+ // near-neutral brand (zinc) the two measured near-1.0: an invisible hover, same bug shape as
53
+ // NavigationBar's menu items.
54
+ const triggerHoverBg = (0, outlineRung_1.resolveHoverTint)(theme.colors.gray[100], theme.colors.backgroundColor.light);
43
55
  const handleSelect = (org) => {
44
56
  onClose();
45
57
  setQuery("");
@@ -49,14 +61,21 @@ const OrgSwitcher = ({ organizations, value, onChange, isLoading = false, isSear
49
61
  return ((0, jsx_runtime_1.jsxs)(react_2.Popover, { isOpen: isOpen, onOpen: onOpen, onClose: () => {
50
62
  onClose();
51
63
  setQuery("");
52
- }, placement: "bottom-start", initialFocusRef: showSearch ? searchRef : undefined, isLazy: true, children: [(0, jsx_runtime_1.jsx)(react_2.PopoverTrigger, { children: (0, jsx_runtime_1.jsxs)(react_2.Flex, { as: "button", type: "button", "aria-label": ariaLabel, align: "center", gap: s.px === 2 ? "8px" : "10px", h: s.h, px: s.px, borderRadius: "10px", cursor: isLoading ? "default" : "pointer", opacity: isLoading ? 0.6 : 1, pointerEvents: isLoading ? "none" : "auto", transition: "background 0.15s ease", _hover: { bg: triggerVariant === "ghost" ? theme.colors.gray[100] : undefined }, ...triggerStyles, children: [selected ? ((0, jsx_runtime_1.jsx)(Avatar, { org: selected, boxSize: s.avatar, fontSize: s.sub })) : ((0, jsx_runtime_1.jsx)(react_2.Flex, { align: "center", justify: "center", boxSize: s.avatar, borderRadius: "8px", bg: theme.colors.gray[100], color: theme.colors.gray[400], flexShrink: 0, children: (0, jsx_runtime_1.jsx)(lucide_react_1.Building2, { size: 14 }) })), (0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: s.font, fontWeight: 600, color: theme.colors.gray[700], maxW: maxWidth, overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", textAlign: "left", children: (_c = selected === null || selected === void 0 ? void 0 : selected.name) !== null && _c !== void 0 ? _c : placeholder }), isLoading ? ((0, jsx_runtime_1.jsx)(react_2.Spinner, { size: "xs", thickness: "1.5px", color: theme.colors.primary[500], flexShrink: 0 })) : ((0, jsx_runtime_1.jsx)(react_2.Box, { as: lucide_react_1.ChevronsUpDown, size: 16, color: theme.colors.gray[400], flexShrink: 0 }))] }) }), (0, jsx_runtime_1.jsx)(react_2.PopoverContent, { minW: menuMinWidth, w: "auto",
64
+ }, placement: "bottom-start", initialFocusRef: showSearch ? searchRef : undefined, isLazy: true, children: [(0, jsx_runtime_1.jsx)(react_2.PopoverTrigger, { children: (0, jsx_runtime_1.jsxs)(react_2.Flex, { as: "button", type: "button", "aria-label": ariaLabel, align: "center", gap: s.px === 2 ? "8px" : "10px", h: s.h, px: s.px, borderRadius: "10px", cursor: isLoading ? "default" : "pointer", opacity: isLoading ? 0.6 : 1, pointerEvents: isLoading ? "none" : "auto", transition: "background 0.15s ease", _hover: { bg: triggerVariant === "ghost" ? triggerHoverBg : undefined }, ...triggerStyles, children: [selected ? ((0, jsx_runtime_1.jsx)(Avatar, { org: selected, boxSize: s.avatar, fontSize: s.sub })) : ((0, jsx_runtime_1.jsx)(react_2.Flex, { align: "center", justify: "center", boxSize: s.avatar, borderRadius: "8px", bg: theme.colors.gray[100], color: theme.colors.gray[400], flexShrink: 0, children: (0, jsx_runtime_1.jsx)(lucide_react_1.Building2, { size: 14 }) })), (0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: s.font, fontWeight: 600, color: theme.colors.gray[700], maxW: maxWidth, overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", textAlign: "left", children: (_c = selected === null || selected === void 0 ? void 0 : selected.name) !== null && _c !== void 0 ? _c : placeholder }), isLoading ? ((0, jsx_runtime_1.jsx)(react_2.Spinner, { size: "xs", thickness: "1.5px", color: theme.colors.primary[500], flexShrink: 0 })) : ((0, jsx_runtime_1.jsx)(react_2.Box, { as: lucide_react_1.ChevronsUpDown, size: 16, color: theme.colors.gray[400], flexShrink: 0 }))] }) }), (0, jsx_runtime_1.jsx)(react_2.PopoverContent, { minW: menuMinWidth, w: "auto",
53
65
  // Chakra's PopoverContent baseStyle defaults bg to var(--popper-bg), which is hardcoded
54
66
  // to colors.white and only repointed under Chakra's own `_dark` — dead code here since
55
67
  // this app toggles dark mode by swapping the palette, not Chakra's colorMode. Without an
56
68
  // explicit bg the panel always rendered white regardless of the active theme.
57
69
  bg: theme.colors.backgroundColor.light, borderRadius: "12px", overflow: "hidden", boxShadow: `0 10px 30px ${theme.colors.boxShadow.default}`, _focus: { outline: "none", boxShadow: `0 10px 30px ${theme.colors.boxShadow.default}` }, children: (0, jsx_runtime_1.jsxs)(react_2.PopoverBody, { p: 0, children: [showSearch && ((0, jsx_runtime_1.jsx)(react_2.Box, { p: 2, borderBottom: "1px solid", borderColor: theme.colors.gray[100], children: (0, jsx_runtime_1.jsxs)(react_2.InputGroup, { size: "sm", children: [(0, jsx_runtime_1.jsx)(react_2.InputLeftElement, { pointerEvents: "none", children: (0, jsx_runtime_1.jsx)(lucide_react_1.Search, { size: 15, color: theme.colors.gray[400] }) }), (0, jsx_runtime_1.jsx)(react_2.Input, { ref: searchRef, placeholder: "Search organizations", value: query, onChange: (e) => setQuery(e.target.value), borderRadius: "8px" })] }) })), (0, jsx_runtime_1.jsxs)(react_2.Box, { maxH: "320px", overflowY: "auto", py: 1, children: [filtered.map((org) => {
58
70
  const isActive = org.id === value;
59
- return ((0, jsx_runtime_1.jsxs)(react_2.Flex, { align: "center", gap: "10px", px: 3, py: 2, cursor: "pointer", bg: isActive ? theme.colors.primary[50] : "transparent", transition: "background 0.12s ease", _hover: { bg: isActive ? theme.colors.primary[50] : theme.colors.gray[50] }, onClick: () => handleSelect(org), children: [(0, jsx_runtime_1.jsx)(Avatar, { org: org, boxSize: s.avatar, fontSize: s.sub }), (0, jsx_runtime_1.jsxs)(react_2.Box, { flex: "1", minW: 0, children: [(0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: s.font, fontWeight: isActive ? 600 : 500, color: theme.colors.text[900], overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", children: org.name }), showRole && org.role && ((0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: s.sub, color: theme.colors.text[500], overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", children: org.role }))] }), isActive && ((0, jsx_runtime_1.jsx)(react_2.Box, { as: lucide_react_1.Check, size: 16, color: theme.colors.primary[500], flexShrink: 0 }))] }, org.id));
71
+ // Active row's hover repeated its own resting `primary[50]` fill a zero-delta
72
+ // hover, invisible by construction. `resolveHoverTint` walks a fill away from a
73
+ // backdrop until distinguishable, so handing it its own resting bg as the backdrop
74
+ // is enough to make hover read as a real state change on both active and inactive rows.
75
+ const rowHoverBg = isActive
76
+ ? (0, outlineRung_1.resolveHoverTint)(theme.colors.primary[50], theme.colors.primary[50])
77
+ : (0, outlineRung_1.resolveHoverTint)(theme.colors.gray[50], theme.colors.backgroundColor.light);
78
+ return ((0, jsx_runtime_1.jsxs)(react_2.Flex, { align: "center", gap: "10px", px: 3, py: 2, cursor: "pointer", bg: isActive ? theme.colors.primary[50] : "transparent", transition: "background 0.12s ease", _hover: { bg: rowHoverBg }, onClick: () => handleSelect(org), children: [(0, jsx_runtime_1.jsx)(Avatar, { org: org, boxSize: s.avatar, fontSize: s.sub }), (0, jsx_runtime_1.jsxs)(react_2.Box, { flex: "1", minW: 0, children: [(0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: s.font, fontWeight: isActive ? 600 : 500, color: theme.colors.text[900], overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", children: org.name }), showRole && org.role && ((0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: s.sub, color: theme.colors.text[500], overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", children: org.role }))] }), isActive && ((0, jsx_runtime_1.jsx)(react_2.Box, { as: lucide_react_1.Check, size: 16, color: theme.colors.primary[500], flexShrink: 0 }))] }, org.id));
60
79
  }), filtered.length === 0 && ((0, jsx_runtime_1.jsx)(react_2.Text, { fontSize: "sm", color: theme.colors.gray[500], textAlign: "center", py: 6, children: "No organizations found" }))] })] }) })] }));
61
80
  };
62
81
  exports.default = OrgSwitcher;
@@ -35,6 +35,7 @@ export interface OrgSwitcherProps {
35
35
  /** Show the role subtitle inside the dropdown rows. Default true. */
36
36
  showRole?: boolean;
37
37
  }
38
+ export declare const AVATAR_COLORS: string[];
38
39
  /** Deterministically pick an avatar color from an org name. */
39
40
  export declare const avatarColor: (seed: string) => string;
40
41
  /** First letter (uppercased) of an org name, for the fallback avatar. */
@@ -1 +1 @@
1
- {"version":3,"file":"OrgSwitcherProps.d.ts","sourceRoot":"","sources":["../../../src/Components/OrgSwitcher/OrgSwitcherProps.tsx"],"names":[],"mappings":"AAAA,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,GAAG,MAAM,CAAC;IACpB,iCAAiC;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,uEAAuE;IACvE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,sEAAsE;IACtE,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,MAAM,eAAe,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAEjD,MAAM,WAAW,gBAAgB;IAC/B,oCAAoC;IACpC,aAAa,EAAE,SAAS,EAAE,CAAC;IAC3B,+CAA+C;IAC/C,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,qDAAqD;IACrD,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,EAAE,SAAS,KAAK,IAAI,CAAC;IACxD,+EAA+E;IAC/E,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,0EAA0E;IAC1E,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,+DAA+D;IAC/D,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,6EAA6E;IAC7E,cAAc,CAAC,EAAE,OAAO,GAAG,SAAS,GAAG,QAAQ,CAAC;IAChD,IAAI,CAAC,EAAE,eAAe,CAAC;IACvB,wDAAwD;IACxD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,uCAAuC;IACvC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,qCAAqC;IACrC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wCAAwC;IACxC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,qEAAqE;IACrE,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAaD,+DAA+D;AAC/D,eAAO,MAAM,WAAW,GAAI,MAAM,MAAM,KAAG,MAM1C,CAAC;AAEF,yEAAyE;AACzE,eAAO,MAAM,UAAU,GAAI,MAAM,MAAM,KAAG,MACA,CAAC"}
1
+ {"version":3,"file":"OrgSwitcherProps.d.ts","sourceRoot":"","sources":["../../../src/Components/OrgSwitcher/OrgSwitcherProps.tsx"],"names":[],"mappings":"AAAA,MAAM,WAAW,SAAS;IACxB,EAAE,EAAE,MAAM,GAAG,MAAM,CAAC;IACpB,iCAAiC;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,uEAAuE;IACvE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,sEAAsE;IACtE,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,MAAM,eAAe,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAEjD,MAAM,WAAW,gBAAgB;IAC/B,oCAAoC;IACpC,aAAa,EAAE,SAAS,EAAE,CAAC;IAC3B,+CAA+C;IAC/C,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,qDAAqD;IACrD,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,EAAE,SAAS,KAAK,IAAI,CAAC;IACxD,+EAA+E;IAC/E,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,0EAA0E;IAC1E,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,+DAA+D;IAC/D,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,6EAA6E;IAC7E,cAAc,CAAC,EAAE,OAAO,GAAG,SAAS,GAAG,QAAQ,CAAC;IAChD,IAAI,CAAC,EAAE,eAAe,CAAC;IACvB,wDAAwD;IACxD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,uCAAuC;IACvC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,qCAAqC;IACrC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wCAAwC;IACxC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,qEAAqE;IACrE,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,aAAa,UASzB,CAAC;AAEF,+DAA+D;AAC/D,eAAO,MAAM,WAAW,GAAI,MAAM,MAAM,KAAG,MAM1C,CAAC;AAEF,yEAAyE;AACzE,eAAO,MAAM,UAAU,GAAI,MAAM,MAAM,KAAG,MACA,CAAC"}
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.orgInitial = exports.avatarColor = void 0;
4
- const AVATAR_COLORS = [
3
+ exports.orgInitial = exports.avatarColor = exports.AVATAR_COLORS = void 0;
4
+ exports.AVATAR_COLORS = [
5
5
  "#6366F1",
6
6
  "#0EA5E9",
7
7
  "#10B981",
@@ -17,7 +17,7 @@ const avatarColor = (seed) => {
17
17
  for (let i = 0; i < seed.length; i += 1) {
18
18
  hash = seed.charCodeAt(i) + ((hash << 5) - hash);
19
19
  }
20
- return AVATAR_COLORS[Math.abs(hash) % AVATAR_COLORS.length];
20
+ return exports.AVATAR_COLORS[Math.abs(hash) % exports.AVATAR_COLORS.length];
21
21
  };
22
22
  exports.avatarColor = avatarColor;
23
23
  /** First letter (uppercased) of an org name, for the fallback avatar. */
@@ -31,28 +31,30 @@ const CreateOrgModal = ({ isOpen, onClose, isLoading, onSubmit, labels, }) => {
31
31
  setErrors((prev) => ({ ...prev, [key]: undefined }));
32
32
  };
33
33
  const validate = () => {
34
+ var _a, _b;
34
35
  const next = {};
35
36
  if (!values.company_name.trim())
36
37
  next.company_name = labels.requiredField;
37
38
  if (!values.company_address.trim())
38
39
  next.company_address = labels.requiredField;
39
- const digits = values.phone.replace(/\D/g, "");
40
- if (!values.phone.trim()) {
40
+ const digits = (_a = values === null || values === void 0 ? void 0 : values.phone) === null || _a === void 0 ? void 0 : _a.replace(/\D/g, "");
41
+ if (!((_b = values === null || values === void 0 ? void 0 : values.phone) === null || _b === void 0 ? void 0 : _b.trim())) {
41
42
  next.phone = labels.requiredField;
42
43
  }
43
- else if (digits.length < 8) {
44
+ else if (digits && (digits === null || digits === void 0 ? void 0 : digits.length) < 8) {
44
45
  next.phone = labels.invalidPhone;
45
46
  }
46
47
  setErrors(next);
47
48
  return Object.keys(next).length === 0;
48
49
  };
49
50
  const handleSubmit = () => {
51
+ var _a;
50
52
  if (!validate())
51
53
  return;
52
54
  onSubmit({
53
55
  company_name: values.company_name.trim(),
54
56
  company_address: values.company_address.trim(),
55
- phone: values.phone.trim(),
57
+ phone: (_a = values === null || values === void 0 ? void 0 : values.phone) === null || _a === void 0 ? void 0 : _a.trim(),
56
58
  });
57
59
  };
58
60
  return ((0, jsx_runtime_1.jsxs)(react_2.Modal, { isOpen: isOpen, onClose: onClose, isCentered: true, autoFocus: false, children: [(0, jsx_runtime_1.jsx)(react_2.ModalOverlay, { backdropFilter: "blur(4px)" }), (0, jsx_runtime_1.jsxs)(react_2.ModalContent, { bg: colors.background[50], borderRadius: "2xl", overflow: "hidden", children: [(0, jsx_runtime_1.jsx)(react_2.ModalHeader, { borderBottom: "1px solid", borderColor: (_b = (_a = colors === null || colors === void 0 ? void 0 : colors.boxborder) === null || _a === void 0 ? void 0 : _a[200]) !== null && _b !== void 0 ? _b : (_c = colors === null || colors === void 0 ? void 0 : colors.gray) === null || _c === void 0 ? void 0 : _c[200], fontSize: "1.05rem", fontWeight: 600, children: labels.createOrganization }), (0, jsx_runtime_1.jsx)(react_2.ModalCloseButton, {}), (0, jsx_runtime_1.jsxs)(react_2.ModalBody, { py: 6, children: [(0, jsx_runtime_1.jsxs)(react_2.VStack, { spacing: 4, align: "stretch", children: [(0, jsx_runtime_1.jsx)(TextInput_1.default, { label: labels.companyName, value: values.company_name, onChange: (e) => setField("company_name", e.target.value), isRequired: true, width: "100%", placeholder: "Enter Company Name", error: !!errors.company_name, errorMessage: errors.company_name }), (0, jsx_runtime_1.jsx)(TextInput_1.default, { label: labels.companyAddress, value: values.company_address, onChange: (e) => setField("company_address", e.target.value), isRequired: true, width: "100%", placeholder: "Enter Company Address", error: !!errors.company_address, errorMessage: errors.company_address }), (0, jsx_runtime_1.jsx)(TextInput_1.default, { label: labels.phone, value: values.phone, onChange: (e) => setField("phone", e.target.value), isRequired: true, width: "100%", placeholder: "Enter Phone Number", error: !!errors.phone, errorMessage: errors.phone })] }), (0, jsx_runtime_1.jsxs)(react_2.HStack, { justifyContent: "center", spacing: 4, mt: 6, children: [(0, jsx_runtime_1.jsx)(Button_1.default, { label: labels.cancel, onClick: onClose, variant: "outline", colorScheme: "red", size: "sm" }), (0, jsx_runtime_1.jsx)(Button_1.default, { label: labels.submit, onClick: handleSubmit, colorScheme: "primary", size: "sm", isLoading: isLoading })] })] })] })] }));
@@ -1 +1 @@
1
- {"version":3,"file":"OrganizationDetails.d.ts","sourceRoot":"","sources":["../../../src/Components/OrganizationDetails/OrganizationDetails.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAgCjD,OAAO,EAEL,wBAAwB,EAEzB,MAAM,4BAA4B,CAAC;AAoCpC,QAAA,MAAM,mBAAmB,EAAE,KAAK,CAAC,EAAE,CAAC,wBAAwB,CAmZ3D,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
1
+ {"version":3,"file":"OrganizationDetails.d.ts","sourceRoot":"","sources":["../../../src/Components/OrganizationDetails/OrganizationDetails.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAoCjD,OAAO,EAEL,wBAAwB,EAEzB,MAAM,4BAA4B,CAAC;AAwCpC,QAAA,MAAM,mBAAmB,EAAE,KAAK,CAAC,EAAE,CAAC,wBAAwB,CAgf3D,CAAC;AAEF,eAAe,mBAAmB,CAAC"}