@lokalise/harmony 1.36.1 → 1.37.1-exp-epic2x.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (365) hide show
  1. package/dist/harmony.cjs +1 -3
  2. package/dist/harmony.cjs.map +1 -1
  3. package/dist/harmony.css +110 -317
  4. package/dist/harmony.mjs +2 -4
  5. package/dist/harmony100.cjs +10 -12
  6. package/dist/harmony100.cjs.map +1 -1
  7. package/dist/harmony100.mjs +9 -11
  8. package/dist/harmony100.mjs.map +1 -1
  9. package/dist/harmony101.cjs +27 -9
  10. package/dist/harmony101.cjs.map +1 -1
  11. package/dist/harmony101.mjs +29 -11
  12. package/dist/harmony101.mjs.map +1 -1
  13. package/dist/harmony102.cjs +14 -21
  14. package/dist/harmony102.cjs.map +1 -1
  15. package/dist/harmony102.mjs +13 -20
  16. package/dist/harmony102.mjs.map +1 -1
  17. package/dist/harmony103.cjs +35 -12
  18. package/dist/harmony103.cjs.map +1 -1
  19. package/dist/harmony103.mjs +35 -12
  20. package/dist/harmony103.mjs.map +1 -1
  21. package/dist/harmony104.cjs +14 -18
  22. package/dist/harmony104.cjs.map +1 -1
  23. package/dist/harmony104.mjs +14 -18
  24. package/dist/harmony104.mjs.map +1 -1
  25. package/dist/harmony105.cjs +22 -21
  26. package/dist/harmony105.cjs.map +1 -1
  27. package/dist/harmony105.mjs +21 -20
  28. package/dist/harmony105.mjs.map +1 -1
  29. package/dist/harmony106.cjs +34 -5
  30. package/dist/harmony106.cjs.map +1 -1
  31. package/dist/harmony106.mjs +34 -5
  32. package/dist/harmony106.mjs.map +1 -1
  33. package/dist/harmony107.cjs +21 -132
  34. package/dist/harmony107.cjs.map +1 -1
  35. package/dist/harmony107.mjs +20 -131
  36. package/dist/harmony107.mjs.map +1 -1
  37. package/dist/harmony108.cjs +21 -12
  38. package/dist/harmony108.cjs.map +1 -1
  39. package/dist/harmony108.mjs +20 -11
  40. package/dist/harmony108.mjs.map +1 -1
  41. package/dist/harmony109.cjs +7 -6
  42. package/dist/harmony109.cjs.map +1 -1
  43. package/dist/harmony109.mjs +6 -5
  44. package/dist/harmony109.mjs.map +1 -1
  45. package/dist/harmony110.cjs +15 -40
  46. package/dist/harmony110.cjs.map +1 -1
  47. package/dist/harmony110.mjs +14 -39
  48. package/dist/harmony110.mjs.map +1 -1
  49. package/dist/harmony111.cjs +6 -61
  50. package/dist/harmony111.cjs.map +1 -1
  51. package/dist/harmony111.mjs +5 -60
  52. package/dist/harmony111.mjs.map +1 -1
  53. package/dist/harmony112.cjs +6 -8
  54. package/dist/harmony112.cjs.map +1 -1
  55. package/dist/harmony112.mjs +5 -7
  56. package/dist/harmony112.mjs.map +1 -1
  57. package/dist/harmony113.cjs +6 -3
  58. package/dist/harmony113.cjs.map +1 -1
  59. package/dist/harmony113.mjs +6 -3
  60. package/dist/harmony113.mjs.map +1 -1
  61. package/dist/harmony114.cjs +6 -99
  62. package/dist/harmony114.cjs.map +1 -1
  63. package/dist/harmony114.mjs +5 -81
  64. package/dist/harmony114.mjs.map +1 -1
  65. package/dist/harmony115.cjs +10 -63
  66. package/dist/harmony115.cjs.map +1 -1
  67. package/dist/harmony115.mjs +9 -62
  68. package/dist/harmony115.mjs.map +1 -1
  69. package/dist/harmony116.cjs +24 -88
  70. package/dist/harmony116.cjs.map +1 -1
  71. package/dist/harmony116.mjs +23 -87
  72. package/dist/harmony116.mjs.map +1 -1
  73. package/dist/harmony117.cjs +3 -15
  74. package/dist/harmony117.cjs.map +1 -1
  75. package/dist/harmony117.mjs +3 -15
  76. package/dist/harmony117.mjs.map +1 -1
  77. package/dist/harmony118.cjs +12 -5
  78. package/dist/harmony118.cjs.map +1 -1
  79. package/dist/harmony118.mjs +12 -5
  80. package/dist/harmony118.mjs.map +1 -1
  81. package/dist/harmony119.cjs +6 -5
  82. package/dist/harmony119.cjs.map +1 -1
  83. package/dist/harmony119.mjs +6 -5
  84. package/dist/harmony122.cjs +1 -1
  85. package/dist/harmony122.mjs +1 -1
  86. package/dist/harmony123.cjs +2 -2
  87. package/dist/harmony123.mjs +2 -2
  88. package/dist/harmony125.cjs +13 -7
  89. package/dist/harmony125.cjs.map +1 -1
  90. package/dist/harmony125.mjs +13 -7
  91. package/dist/harmony125.mjs.map +1 -1
  92. package/dist/harmony126.cjs +15 -57
  93. package/dist/harmony126.cjs.map +1 -1
  94. package/dist/harmony126.mjs +15 -57
  95. package/dist/harmony126.mjs.map +1 -1
  96. package/dist/harmony127.cjs +15 -59
  97. package/dist/harmony127.cjs.map +1 -1
  98. package/dist/harmony127.mjs +15 -59
  99. package/dist/harmony127.mjs.map +1 -1
  100. package/dist/harmony128.cjs +12 -19
  101. package/dist/harmony128.cjs.map +1 -1
  102. package/dist/harmony128.mjs +11 -18
  103. package/dist/harmony128.mjs.map +1 -1
  104. package/dist/harmony129.cjs +15 -12
  105. package/dist/harmony129.cjs.map +1 -1
  106. package/dist/harmony129.mjs +15 -12
  107. package/dist/harmony129.mjs.map +1 -1
  108. package/dist/harmony13.cjs +1 -1
  109. package/dist/harmony13.mjs +1 -1
  110. package/dist/harmony130.cjs +19 -13
  111. package/dist/harmony130.cjs.map +1 -1
  112. package/dist/harmony130.mjs +19 -13
  113. package/dist/harmony130.mjs.map +1 -1
  114. package/dist/harmony131.cjs +10 -14
  115. package/dist/harmony131.cjs.map +1 -1
  116. package/dist/harmony131.mjs +10 -14
  117. package/dist/harmony131.mjs.map +1 -1
  118. package/dist/harmony132.cjs +5 -10
  119. package/dist/harmony132.cjs.map +1 -1
  120. package/dist/harmony132.mjs +5 -10
  121. package/dist/harmony132.mjs.map +1 -1
  122. package/dist/harmony133.cjs +11 -15
  123. package/dist/harmony133.cjs.map +1 -1
  124. package/dist/harmony133.mjs +11 -15
  125. package/dist/harmony133.mjs.map +1 -1
  126. package/dist/harmony134.cjs +28 -17
  127. package/dist/harmony134.cjs.map +1 -1
  128. package/dist/harmony134.mjs +28 -17
  129. package/dist/harmony134.mjs.map +1 -1
  130. package/dist/harmony135.cjs +12 -10
  131. package/dist/harmony135.cjs.map +1 -1
  132. package/dist/harmony135.mjs +12 -10
  133. package/dist/harmony135.mjs.map +1 -1
  134. package/dist/harmony16.cjs +1 -1
  135. package/dist/harmony16.mjs +1 -1
  136. package/dist/harmony23.cjs +1 -1
  137. package/dist/harmony23.mjs +1 -1
  138. package/dist/harmony24.cjs +1 -1
  139. package/dist/harmony24.mjs +1 -1
  140. package/dist/harmony31.cjs +4 -4
  141. package/dist/harmony31.cjs.map +1 -1
  142. package/dist/harmony31.mjs +5 -5
  143. package/dist/harmony31.mjs.map +1 -1
  144. package/dist/harmony38.cjs.map +1 -1
  145. package/dist/harmony38.mjs.map +1 -1
  146. package/dist/harmony4.cjs +15 -24
  147. package/dist/harmony4.cjs.map +1 -1
  148. package/dist/harmony4.mjs +15 -24
  149. package/dist/harmony4.mjs.map +1 -1
  150. package/dist/harmony40.cjs.map +1 -1
  151. package/dist/harmony40.mjs.map +1 -1
  152. package/dist/harmony44.cjs.map +1 -1
  153. package/dist/harmony44.mjs.map +1 -1
  154. package/dist/harmony5.cjs +1 -1
  155. package/dist/harmony5.mjs +1 -1
  156. package/dist/harmony6.cjs +3 -3
  157. package/dist/harmony6.mjs +3 -3
  158. package/dist/harmony64.cjs +4 -15
  159. package/dist/harmony64.cjs.map +1 -1
  160. package/dist/harmony64.mjs +4 -15
  161. package/dist/harmony64.mjs.map +1 -1
  162. package/dist/harmony7.cjs +1 -1
  163. package/dist/harmony7.mjs +1 -1
  164. package/dist/harmony72.cjs +1 -1
  165. package/dist/harmony72.mjs +1 -1
  166. package/dist/harmony73.cjs +51 -6
  167. package/dist/harmony73.cjs.map +1 -1
  168. package/dist/harmony73.mjs +50 -5
  169. package/dist/harmony73.mjs.map +1 -1
  170. package/dist/harmony74.cjs +38 -8
  171. package/dist/harmony74.cjs.map +1 -1
  172. package/dist/harmony74.mjs +38 -8
  173. package/dist/harmony74.mjs.map +1 -1
  174. package/dist/harmony75.cjs +9 -18
  175. package/dist/harmony75.cjs.map +1 -1
  176. package/dist/harmony75.mjs +8 -17
  177. package/dist/harmony75.mjs.map +1 -1
  178. package/dist/harmony76.cjs +6 -21
  179. package/dist/harmony76.cjs.map +1 -1
  180. package/dist/harmony76.mjs +8 -23
  181. package/dist/harmony76.mjs.map +1 -1
  182. package/dist/harmony77.cjs +28 -4
  183. package/dist/harmony77.cjs.map +1 -1
  184. package/dist/harmony77.mjs +28 -4
  185. package/dist/harmony77.mjs.map +1 -1
  186. package/dist/harmony78.cjs +3 -32
  187. package/dist/harmony78.cjs.map +1 -1
  188. package/dist/harmony78.mjs +3 -32
  189. package/dist/harmony78.mjs.map +1 -1
  190. package/dist/harmony79.cjs +30 -29
  191. package/dist/harmony79.cjs.map +1 -1
  192. package/dist/harmony79.mjs +31 -30
  193. package/dist/harmony79.mjs.map +1 -1
  194. package/dist/harmony80.cjs +25 -17
  195. package/dist/harmony80.cjs.map +1 -1
  196. package/dist/harmony80.mjs +25 -17
  197. package/dist/harmony80.mjs.map +1 -1
  198. package/dist/harmony81.cjs +3 -31
  199. package/dist/harmony81.cjs.map +1 -1
  200. package/dist/harmony81.mjs +3 -31
  201. package/dist/harmony81.mjs.map +1 -1
  202. package/dist/harmony82.cjs +12 -53
  203. package/dist/harmony82.cjs.map +1 -1
  204. package/dist/harmony82.mjs +14 -55
  205. package/dist/harmony82.mjs.map +1 -1
  206. package/dist/harmony83.cjs +75 -9
  207. package/dist/harmony83.cjs.map +1 -1
  208. package/dist/harmony83.mjs +74 -8
  209. package/dist/harmony83.mjs.map +1 -1
  210. package/dist/harmony84.cjs +11 -7
  211. package/dist/harmony84.cjs.map +1 -1
  212. package/dist/harmony84.mjs +12 -8
  213. package/dist/harmony84.mjs.map +1 -1
  214. package/dist/harmony85.cjs +29 -28
  215. package/dist/harmony85.cjs.map +1 -1
  216. package/dist/harmony85.mjs +29 -28
  217. package/dist/harmony85.mjs.map +1 -1
  218. package/dist/harmony86.cjs +9 -3
  219. package/dist/harmony86.cjs.map +1 -1
  220. package/dist/harmony86.mjs +9 -3
  221. package/dist/harmony86.mjs.map +1 -1
  222. package/dist/harmony87.cjs +42 -28
  223. package/dist/harmony87.cjs.map +1 -1
  224. package/dist/harmony87.mjs +44 -30
  225. package/dist/harmony87.mjs.map +1 -1
  226. package/dist/harmony88.cjs +6 -3
  227. package/dist/harmony88.cjs.map +1 -1
  228. package/dist/harmony88.mjs +6 -3
  229. package/dist/harmony88.mjs.map +1 -1
  230. package/dist/harmony89.cjs +12 -10
  231. package/dist/harmony89.cjs.map +1 -1
  232. package/dist/harmony89.mjs +11 -9
  233. package/dist/harmony89.mjs.map +1 -1
  234. package/dist/harmony90.cjs +20 -8
  235. package/dist/harmony90.cjs.map +1 -1
  236. package/dist/harmony90.mjs +20 -8
  237. package/dist/harmony90.mjs.map +1 -1
  238. package/dist/harmony91.cjs +9 -54
  239. package/dist/harmony91.cjs.map +1 -1
  240. package/dist/harmony91.mjs +11 -56
  241. package/dist/harmony91.mjs.map +1 -1
  242. package/dist/harmony92.cjs +12 -42
  243. package/dist/harmony92.cjs.map +1 -1
  244. package/dist/harmony92.mjs +11 -41
  245. package/dist/harmony92.mjs.map +1 -1
  246. package/dist/harmony93.cjs +98 -4
  247. package/dist/harmony93.cjs.map +1 -1
  248. package/dist/harmony93.mjs +82 -5
  249. package/dist/harmony93.mjs.map +1 -1
  250. package/dist/harmony94.cjs +14 -9
  251. package/dist/harmony94.cjs.map +1 -1
  252. package/dist/harmony94.mjs +13 -8
  253. package/dist/harmony94.mjs.map +1 -1
  254. package/dist/harmony95.cjs +21 -25
  255. package/dist/harmony95.cjs.map +1 -1
  256. package/dist/harmony95.mjs +20 -24
  257. package/dist/harmony95.mjs.map +1 -1
  258. package/dist/harmony96.cjs +6 -3
  259. package/dist/harmony96.cjs.map +1 -1
  260. package/dist/harmony96.mjs +6 -3
  261. package/dist/harmony96.mjs.map +1 -1
  262. package/dist/harmony97.cjs +11 -18
  263. package/dist/harmony97.cjs.map +1 -1
  264. package/dist/harmony97.mjs +12 -19
  265. package/dist/harmony97.mjs.map +1 -1
  266. package/dist/harmony98.cjs +17 -12
  267. package/dist/harmony98.cjs.map +1 -1
  268. package/dist/harmony98.mjs +16 -11
  269. package/dist/harmony98.mjs.map +1 -1
  270. package/dist/harmony99.cjs +17 -8
  271. package/dist/harmony99.cjs.map +1 -1
  272. package/dist/harmony99.mjs +19 -10
  273. package/dist/harmony99.mjs.map +1 -1
  274. package/dist/types/src/components/Sidebar/Sidebar.d.ts +15 -49
  275. package/dist/types/src/components/Sidebar/SidebarContent/SidebarContent.d.ts +7 -0
  276. package/dist/types/src/components/Sidebar/SidebarContext.d.ts +3 -0
  277. package/dist/types/src/components/Sidebar/SidebarProvider.d.ts +3 -0
  278. package/dist/types/src/components/Sidebar/Widgets/Avatar/Avatar.d.ts +5 -0
  279. package/dist/types/src/components/Sidebar/Widgets/HelpMenu/HelpMenu.d.ts +13 -0
  280. package/dist/types/src/components/Sidebar/Widgets/HelpMenu/HelpMenu.test.d.ts +1 -0
  281. package/dist/types/src/components/Sidebar/Widgets/IconLink/IconLink.test.d.ts +1 -0
  282. package/dist/types/src/components/Sidebar/Widgets/Menu/Menu.d.ts +3 -2
  283. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/BillingMenuItem/BillingMenuItem.d.ts +13 -0
  284. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/CreateNewTeam/CreateNewTeam.d.ts +17 -0
  285. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/CreateNewTeam/CreateNewTeam.test.d.ts +1 -0
  286. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/CreateNewTeamPlaceholder/CreateNewTeamPlaceholder.d.ts +17 -0
  287. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/CreateNewTeamPlaceholder/CreateNewTeamPlaceholder.test.d.ts +1 -0
  288. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/DarkModeToggle/DarkModeToggle.d.ts +18 -0
  289. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProfileMenu.d.ts +11 -24
  290. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProfileMenu.stories.d.ts +3 -5
  291. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProfileSettingsMenuItem/ProfileSettingsMenuItem.d.ts +10 -35
  292. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProfileSettingsMenuItem/ProfileSettingsMenuItem.test.d.ts +1 -0
  293. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProviderMenuItem/ProviderMenuItem.d.ts +13 -0
  294. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProviderMenuItem/ProviderMenuItem.test.d.ts +1 -0
  295. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/TeamMenuItem/TeamMenuItem.d.ts +1 -3
  296. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/TeamMenuItem/TeamMenuItem.test.d.ts +1 -0
  297. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/TeamSettingsMenuItem/TeamSettingsMenuItem.d.ts +13 -0
  298. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/TeamSettingsMenuItem/TeamSettingsMenuItem.test.d.ts +1 -0
  299. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/TeamSwitch/TeamSwitch.d.ts +5 -7
  300. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/TeamSwitch/TeamSwitch.test.d.ts +1 -0
  301. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/UpgradeMenuItem/UpgradeMenuItem.d.ts +6 -9
  302. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/UpgradeMenuItem/UpgradeMenuItem.test.d.ts +1 -0
  303. package/dist/types/src/components/Sidebar/Widgets/Tasks/utils/content.d.ts +4 -0
  304. package/dist/types/src/components/Sidebar/hooks/useSidebar.d.ts +1 -0
  305. package/dist/types/src/components/Sidebar/hooks/useSidebarDataLoader.d.ts +5 -0
  306. package/dist/types/src/components/Sidebar/types.d.ts +72 -0
  307. package/dist/types/src/features/auth/core/types/jwtTokenPayload.d.ts +16 -10
  308. package/dist/types/src/features/auth/core/types/jwtTokenPayload.fixture.d.ts +15 -11
  309. package/dist/types/src/features/auth/frontend/hooks/useAuthenticatedSessionPayload.d.ts +7 -5
  310. package/dist/types/src/features/auth/frontend/hooks/useAuthenticatedUser.d.ts +1 -1
  311. package/dist/types/src/features/publicApi/hooks/useCreateProjectMutation.d.ts +1 -1
  312. package/dist/types/src/features/publicApi/hooks/useCreateScoreMutation.d.ts +2 -2
  313. package/dist/types/src/features/publicApi/hooks/useDeleteScoreMutation.d.ts +2 -2
  314. package/dist/types/src/features/publicApi/hooks/useGetProjectPermissionMetaQuery.d.ts +2 -2
  315. package/dist/types/src/features/publicApi/hooks/useGetScoreQuery.d.ts +4 -3
  316. package/dist/types/src/features/publicApi/hooks/useGetTeamUsersQuery.d.ts +1 -1
  317. package/dist/types/src/features/publicApi/hooks/useListPermissionTemplates.d.ts +1 -1
  318. package/dist/types/src/features/publicApi/hooks/useListProjectsQuery.d.ts +1 -1
  319. package/dist/types/src/features/publicApi/hooks/useListTeamUsersQuery.d.ts +1 -1
  320. package/dist/types/src/features/publicApi/hooks/useRetrieveProjectQuery.d.ts +1 -1
  321. package/dist/types/src/features/publicApi/hooks/useUpdateProjectMutation.d.ts +1 -1
  322. package/dist/types/src/features/publicApi/permissionTemplates.d.ts +4 -4
  323. package/dist/types/src/features/publicApi/projects.d.ts +18 -18
  324. package/dist/types/src/features/publicApi/score.d.ts +8 -4
  325. package/dist/types/src/features/publicApi/teamUsers.d.ts +8 -8
  326. package/dist/types/src/features/publicApi/types/permissionTemplateTypes.d.ts +6 -6
  327. package/dist/types/src/features/publicApi/types/permissionTypes.d.ts +2 -2
  328. package/dist/types/src/features/publicApi/types/projectTypes.d.ts +18 -18
  329. package/dist/types/src/features/publicApi/types/scoreTypes.d.ts +8 -33
  330. package/dist/types/src/features/publicApi/types/teamUserTypes.d.ts +10 -10
  331. package/dist/types/src/utils/user/permissions.d.ts +9 -0
  332. package/dist/types/src/utils/user/permissions.test.d.ts +1 -0
  333. package/dist/types/tests/mocks/sidebar/sidebar.d.ts +19 -0
  334. package/dist/types/tests/utils/sidebar.d.ts +4 -0
  335. package/package.json +1 -1
  336. package/dist/harmony136.cjs +0 -9
  337. package/dist/harmony136.cjs.map +0 -1
  338. package/dist/harmony136.mjs +0 -9
  339. package/dist/harmony136.mjs.map +0 -1
  340. package/dist/harmony137.cjs +0 -15
  341. package/dist/harmony137.cjs.map +0 -1
  342. package/dist/harmony137.mjs +0 -15
  343. package/dist/harmony137.mjs.map +0 -1
  344. package/dist/harmony138.cjs +0 -35
  345. package/dist/harmony138.cjs.map +0 -1
  346. package/dist/harmony138.mjs +0 -35
  347. package/dist/harmony138.mjs.map +0 -1
  348. package/dist/harmony139.cjs +0 -17
  349. package/dist/harmony139.cjs.map +0 -1
  350. package/dist/harmony139.mjs +0 -17
  351. package/dist/harmony139.mjs.map +0 -1
  352. package/dist/harmony140.cjs +0 -49
  353. package/dist/harmony140.cjs.map +0 -1
  354. package/dist/harmony140.mjs +0 -49
  355. package/dist/harmony140.mjs.map +0 -1
  356. package/dist/harmony141.cjs +0 -15
  357. package/dist/harmony141.cjs.map +0 -1
  358. package/dist/harmony141.mjs +0 -15
  359. package/dist/harmony141.mjs.map +0 -1
  360. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProfileMenuContent.d.ts +0 -6
  361. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProfileMenuContext.d.ts +0 -3
  362. package/dist/types/src/components/Sidebar/Widgets/ProfileMenu/ProfileMenuProvider.d.ts +0 -7
  363. package/dist/types/src/components/Sidebar/utils/index.d.ts +0 -4
  364. /package/dist/types/src/components/Sidebar/Widgets/{ProfileMenu/ProfileMenu.test.d.ts → Avatar/Avatar.test.d.ts} +0 -0
  365. /package/dist/types/src/components/Sidebar/{UpgradeIcon → Widgets/ProfileMenu/UpgradeIcon}/UpgradeIcon.d.ts +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"harmony64.mjs","sources":["../src/features/publicApi/types/scoreTypes.ts"],"sourcesContent":["import { z } from 'zod'\n\nexport const SEVERITY_ENUM = z.enum(['critical', 'major', 'minor', 'neutral'])\n\nexport type Severity = z.infer<typeof SEVERITY_ENUM>\n\nexport const ISSUE_SCHEMA = z.object({\n\tcategory: z.string(),\n\tcomment: z.string(),\n\tseverity: SEVERITY_ENUM,\n})\n\nexport type Issue = z.infer<typeof ISSUE_SCHEMA>\n\nexport const GET_SCORE_REQUEST_QUERY_SCHEMA = z.object({\n\tprojectId: z.string(),\n\ttranslationId: z.number(),\n})\n\nexport type GetScoreRequestQuery = z.infer<typeof GET_SCORE_REQUEST_QUERY_SCHEMA>\n\nexport const GET_SCORE_RESPONSE_SCHEMA = z.object({\n\tscore: z.number(),\n\thasMajorIssue: z.boolean(),\n\thasCriticalIssue: z.boolean(),\n\tissues: z.array(ISSUE_SCHEMA),\n})\n\nexport type GetScoreResponseBody = z.infer<typeof GET_SCORE_RESPONSE_SCHEMA>\n\nexport const DELETE_SCORE_PATH_PARAMS_SCHEMA = z.object({\n\tprojectId: z.string(),\n\tkeyId: z.number(),\n\tlanguageId: z.string(),\n})\n\nexport type DeleteScorePathParms = z.infer<typeof DELETE_SCORE_PATH_PARAMS_SCHEMA>\n\nexport const DELETE_SCORE_RESPONSE_SCHEMA = z.null()\n\nexport type DeleteScoreResponseBody = z.infer<typeof DELETE_SCORE_RESPONSE_SCHEMA>\n\nexport const CREATE_SCORE_PATH_PARAMS_SCHEMA = z.object({\n\tprojectId: z.string(),\n\tkeyId: z.number(),\n\tlanguageId: z.string(),\n})\n\nexport type CreateScorePathParams = z.infer<typeof CREATE_SCORE_PATH_PARAMS_SCHEMA>\n\nexport const CREATE_SCORE_REQUEST_BODY_SCHEMA = z.object({\n\tsegmentId: z.number(),\n\tsourceLanguageId: z.number(),\n})\n\nexport type CreateScoreRequestBody = z.infer<typeof CREATE_SCORE_REQUEST_BODY_SCHEMA>\n\nexport const CREATE_SCORE_RESPONSE_SCHEMA = z.object({\n\tscore: z.number(),\n\thasCriticalIssue: z.boolean(),\n\thasMajorIssue: z.boolean(),\n\tissues: z.array(ISSUE_SCHEMA),\n})\n\nexport type CreateScoreResponseBody = z.infer<typeof CREATE_SCORE_RESPONSE_SCHEMA>\n"],"names":[],"mappings":";AAEa,MAAA,gBAAgB,EAAE,KAAK,CAAC,YAAY,SAAS,SAAS,SAAS,CAAC;AAIhE,MAAA,eAAe,EAAE,OAAO;AAAA,EACpC,UAAU,EAAE,OAAO;AAAA,EACnB,SAAS,EAAE,OAAO;AAAA,EAClB,UAAU;AACX,CAAC;AAIY,MAAA,iCAAiC,EAAE,OAAO;AAAA,EACtD,WAAW,EAAE,OAAO;AAAA,EACpB,eAAe,EAAE,OAAO;AACzB,CAAC;AAIY,MAAA,4BAA4B,EAAE,OAAO;AAAA,EACjD,OAAO,EAAE,OAAO;AAAA,EAChB,eAAe,EAAE,QAAQ;AAAA,EACzB,kBAAkB,EAAE,QAAQ;AAAA,EAC5B,QAAQ,EAAE,MAAM,YAAY;AAC7B,CAAC;AAIY,MAAA,kCAAkC,EAAE,OAAO;AAAA,EACvD,WAAW,EAAE,OAAO;AAAA,EACpB,OAAO,EAAE,OAAO;AAAA,EAChB,YAAY,EAAE,OAAO;AACtB,CAAC;AAIY,MAAA,+BAA+B,EAAE,KAAK;AAItC,MAAA,kCAAkC,EAAE,OAAO;AAAA,EACvD,WAAW,EAAE,OAAO;AAAA,EACpB,OAAO,EAAE,OAAO;AAAA,EAChB,YAAY,EAAE,OAAO;AACtB,CAAC;AAIY,MAAA,mCAAmC,EAAE,OAAO;AAAA,EACxD,WAAW,EAAE,OAAO;AAAA,EACpB,kBAAkB,EAAE,OAAO;AAC5B,CAAC;AAIY,MAAA,+BAA+B,EAAE,OAAO;AAAA,EACpD,OAAO,EAAE,OAAO;AAAA,EAChB,kBAAkB,EAAE,QAAQ;AAAA,EAC5B,eAAe,EAAE,QAAQ;AAAA,EACzB,QAAQ,EAAE,MAAM,YAAY;AAC7B,CAAC;"}
1
+ {"version":3,"file":"harmony64.mjs","sources":["../src/features/publicApi/types/scoreTypes.ts"],"sourcesContent":["import { z } from 'zod'\n\nexport const SEVERITY_ENUM = z.enum(['critical', 'major', 'minor', 'neutral'])\n\nexport type Severity = z.infer<typeof SEVERITY_ENUM>\n\nexport const ISSUE_SCHEMA = z.object({\n\tcategory: z.string(),\n\tcomment: z.string(),\n\tseverity: SEVERITY_ENUM,\n})\n\nexport type Issue = z.infer<typeof ISSUE_SCHEMA>\n\nexport const SCORE_REQUEST_QUERY_SCHEMA = z.object({\n\tprojectId: z.string(),\n\tkeyId: z.number(),\n\tlanguageId: z.string(),\n})\n\nexport type ScoreRequestQuery = z.infer<typeof SCORE_REQUEST_QUERY_SCHEMA>\n\nexport const GET_SCORE_RESPONSE_SCHEMA = z.object({\n\tscore: z.number(),\n\thasMajorIssue: z.boolean(),\n\thasCriticalIssue: z.boolean(),\n\tissues: z.array(ISSUE_SCHEMA),\n})\n\nexport type GetScoreResponseBody = z.infer<typeof GET_SCORE_RESPONSE_SCHEMA>\n\nexport const DELETE_SCORE_RESPONSE_SCHEMA = z.null()\n\nexport type DeleteScoreResponseBody = z.infer<typeof DELETE_SCORE_RESPONSE_SCHEMA>\n\nexport const CREATE_SCORE_REQUEST_BODY_SCHEMA = z.object({\n\tsegmentId: z.number(),\n\tsourceLanguageId: z.number(),\n})\n\nexport type CreateScoreRequestBody = z.infer<typeof CREATE_SCORE_REQUEST_BODY_SCHEMA>\n\nexport const CREATE_SCORE_RESPONSE_SCHEMA = z.object({\n\tscore: z.number(),\n\thasCriticalIssue: z.boolean(),\n\thasMajorIssue: z.boolean(),\n\tissues: z.array(ISSUE_SCHEMA),\n})\n\nexport type CreateScoreResponseBody = z.infer<typeof CREATE_SCORE_RESPONSE_SCHEMA>\n"],"names":[],"mappings":";AAEa,MAAA,gBAAgB,EAAE,KAAK,CAAC,YAAY,SAAS,SAAS,SAAS,CAAC;AAIhE,MAAA,eAAe,EAAE,OAAO;AAAA,EACpC,UAAU,EAAE,OAAO;AAAA,EACnB,SAAS,EAAE,OAAO;AAAA,EAClB,UAAU;AACX,CAAC;AAIY,MAAA,6BAA6B,EAAE,OAAO;AAAA,EAClD,WAAW,EAAE,OAAO;AAAA,EACpB,OAAO,EAAE,OAAO;AAAA,EAChB,YAAY,EAAE,OAAO;AACtB,CAAC;AAIY,MAAA,4BAA4B,EAAE,OAAO;AAAA,EACjD,OAAO,EAAE,OAAO;AAAA,EAChB,eAAe,EAAE,QAAQ;AAAA,EACzB,kBAAkB,EAAE,QAAQ;AAAA,EAC5B,QAAQ,EAAE,MAAM,YAAY;AAC7B,CAAC;AAIY,MAAA,+BAA+B,EAAE,KAAK;AAItC,MAAA,mCAAmC,EAAE,OAAO;AAAA,EACxD,WAAW,EAAE,OAAO;AAAA,EACpB,kBAAkB,EAAE,OAAO;AAC5B,CAAC;AAIY,MAAA,+BAA+B,EAAE,OAAO;AAAA,EACpD,OAAO,EAAE,OAAO;AAAA,EAChB,kBAAkB,EAAE,QAAQ;AAAA,EAC5B,eAAe,EAAE,QAAQ;AAAA,EACzB,QAAQ,EAAE,MAAM,YAAY;AAC7B,CAAC;"}
package/dist/harmony7.cjs CHANGED
@@ -3,7 +3,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const louis = require("@lokalise/louis");
5
5
  const reactTable = require("@tanstack/react-table");
6
- const TableHeaderCell = require("./harmony87.cjs");
6
+ const TableHeaderCell = require("./harmony79.cjs");
7
7
  const Table = ({ headers, rows, tbodyRef }) => {
8
8
  return /* @__PURE__ */ jsxRuntime.jsxs(louis.Table, { children: [
9
9
  /* @__PURE__ */ jsxRuntime.jsx(louis.TableHeader, { children: headers.map((headerGroup) => /* @__PURE__ */ jsxRuntime.jsx(louis.TableRow, { children: headerGroup.headers.map((header) => /* @__PURE__ */ jsxRuntime.jsx(
package/dist/harmony7.mjs CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import { Table as Table$1, TableHeader, TableRow, TableBody, TableCell } from "@lokalise/louis";
3
3
  import { flexRender } from "@tanstack/react-table";
4
- import { TableHeaderCell } from "./harmony87.mjs";
4
+ import { TableHeaderCell } from "./harmony79.mjs";
5
5
  const Table = ({ headers, rows, tbodyRef }) => {
6
6
  return /* @__PURE__ */ jsxs(Table$1, { children: [
7
7
  /* @__PURE__ */ jsx(TableHeader, { children: headers.map((headerGroup) => /* @__PURE__ */ jsx(TableRow, { children: headerGroup.headers.map((header) => /* @__PURE__ */ jsx(
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
3
  const React = require("react");
4
- const utils = require("./harmony114.cjs");
4
+ const utils = require("./harmony93.cjs");
5
5
  function useResizeDetector({ skipOnMount = false, refreshMode, refreshRate = 1e3, refreshOptions, handleWidth = true, handleHeight = true, targetRef, observerOptions, onResize } = {}) {
6
6
  const skipResize = React.useRef(skipOnMount);
7
7
  const onResizeRef = utils.useCallbackRef(onResize);
@@ -1,5 +1,5 @@
1
1
  import { useRef, useState, useCallback, useEffect } from "react";
2
- import { useCallbackRef, useRefProxy, getDimensions, patchResizeCallback } from "./harmony114.mjs";
2
+ import { useCallbackRef, useRefProxy, getDimensions, patchResizeCallback } from "./harmony93.mjs";
3
3
  function useResizeDetector({ skipOnMount = false, refreshMode, refreshRate = 1e3, refreshOptions, handleWidth = true, handleHeight = true, targetRef, observerOptions, onResize } = {}) {
4
4
  const skipResize = useRef(skipOnMount);
5
5
  const onResizeRef = useCallbackRef(onResize);
@@ -1,9 +1,54 @@
1
1
  "use strict";
2
- Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
- const sidebarContainer = "_sidebarContainer_bmdti_1";
4
- const styles = {
5
- sidebarContainer
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const jsxRuntime = require("react/jsx-runtime");
4
+ const useSidebarDataLoader = require("./harmony80.cjs");
5
+ const useEffectOnce = require("./harmony12.cjs");
6
+ const React = require("react");
7
+ const SidebarContext = require("./harmony81.cjs");
8
+ const SidebarProvider = ({ config, children }) => {
9
+ const { getJWTPayload, getUserTeams, getCurrentTeam } = config;
10
+ const getOtherTeams = async ({
11
+ userTeams,
12
+ currentTeam
13
+ }) => Promise.resolve(userTeams.filter((userTeam) => userTeam.id !== currentTeam.id));
14
+ const jwtLoader = useSidebarDataLoader.useSidebarDataLoader(getJWTPayload);
15
+ const userTeamsLoader = useSidebarDataLoader.useSidebarDataLoader(getUserTeams);
16
+ const currentTeamLoader = useSidebarDataLoader.useSidebarDataLoader(
17
+ getCurrentTeam
18
+ );
19
+ const otherTeamsData = useSidebarDataLoader.useSidebarDataLoader(getOtherTeams);
20
+ const loadUserData = (teamId) => {
21
+ Promise.all([currentTeamLoader.loadData({ teamId }), userTeamsLoader.loadData()]).then(
22
+ ([currentTeam, userTeams]) => {
23
+ if (currentTeam && userTeams) {
24
+ otherTeamsData.loadData({
25
+ userTeams,
26
+ currentTeam
27
+ }).then(() => {
28
+ });
29
+ }
30
+ }
31
+ );
32
+ };
33
+ useEffectOnce.useEffectOnce(() => {
34
+ jwtLoader.loadData().then((jwt) => {
35
+ if (jwt) {
36
+ loadUserData(jwt.userCurrentTeamId);
37
+ }
38
+ });
39
+ });
40
+ const providerValue = React.useMemo(
41
+ () => ({
42
+ data: {
43
+ jwt: jwtLoader.data,
44
+ userTeams: userTeamsLoader.data,
45
+ currentTeam: currentTeamLoader.data,
46
+ otherTeams: otherTeamsData.data
47
+ }
48
+ }),
49
+ [jwtLoader, userTeamsLoader, currentTeamLoader, otherTeamsData]
50
+ );
51
+ return /* @__PURE__ */ jsxRuntime.jsx(SidebarContext.SidebarContext.Provider, { value: providerValue, children });
6
52
  };
7
- exports.default = styles;
8
- exports.sidebarContainer = sidebarContainer;
53
+ exports.SidebarProvider = SidebarProvider;
9
54
  //# sourceMappingURL=harmony73.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony73.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;"}
1
+ {"version":3,"file":"harmony73.cjs","sources":["../src/components/Sidebar/SidebarProvider.tsx"],"sourcesContent":["import { useSidebarDataLoader } from '@components/Sidebar/hooks/useSidebarDataLoader'\nimport type { JwtTokenPayload } from '@features/auth/core/types/jwtTokenPayload'\nimport { useEffectOnce } from '@utils'\nimport { type PropsWithChildren, useMemo } from 'react'\nimport { SidebarContext } from './SidebarContext'\nimport type {\n\tSidebarContextProps,\n\tSidebarProviderProps,\n\tSidebarTeam,\n\tSidebarTeamExtended,\n} from './types'\n\nexport const SidebarProvider = ({ config, children }: PropsWithChildren<SidebarProviderProps>) => {\n\tconst { getJWTPayload, getUserTeams, getCurrentTeam } = config\n\n\tconst getOtherTeams = async ({\n\t\tuserTeams,\n\t\tcurrentTeam,\n\t}: {\n\t\tuserTeams: SidebarTeam[]\n\t\tcurrentTeam: SidebarTeamExtended\n\t}) => Promise.resolve(userTeams.filter((userTeam) => userTeam.id !== currentTeam.id))\n\n\tconst jwtLoader = useSidebarDataLoader<JwtTokenPayload>(getJWTPayload)\n\n\tconst userTeamsLoader = useSidebarDataLoader<SidebarTeam[]>(getUserTeams)\n\n\tconst currentTeamLoader = useSidebarDataLoader<SidebarTeamExtended, { teamId: number }>(\n\t\tgetCurrentTeam,\n\t)\n\n\tconst otherTeamsData = useSidebarDataLoader<\n\t\tSidebarTeam[],\n\t\t{ userTeams: SidebarTeam[]; currentTeam: SidebarTeamExtended }\n\t>(getOtherTeams)\n\n\tconst loadUserData = (teamId: number) => {\n\t\tPromise.all([currentTeamLoader.loadData({ teamId }), userTeamsLoader.loadData()]).then(\n\t\t\t([currentTeam, userTeams]) => {\n\t\t\t\tif (currentTeam && userTeams) {\n\t\t\t\t\totherTeamsData\n\t\t\t\t\t\t.loadData({\n\t\t\t\t\t\t\tuserTeams,\n\t\t\t\t\t\t\tcurrentTeam,\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.then(() => {\n\t\t\t\t\t\t\t// TODO - do we need to mark all loaders completed somehow?\n\t\t\t\t\t\t})\n\t\t\t\t} else {\n\t\t\t\t\t// TODO - some data did not load - handle this\n\t\t\t\t}\n\t\t\t},\n\t\t)\n\t}\n\n\tuseEffectOnce(() => {\n\t\tjwtLoader.loadData().then((jwt) => {\n\t\t\tif (jwt) {\n\t\t\t\tloadUserData(jwt.userCurrentTeamId)\n\t\t\t}\n\t\t})\n\t})\n\n\tconst providerValue = useMemo<SidebarContextProps>(\n\t\t() => ({\n\t\t\tdata: {\n\t\t\t\tjwt: jwtLoader.data,\n\t\t\t\tuserTeams: userTeamsLoader.data,\n\t\t\t\tcurrentTeam: currentTeamLoader.data,\n\t\t\t\totherTeams: otherTeamsData.data,\n\t\t\t},\n\t\t}),\n\t\t[jwtLoader, userTeamsLoader, currentTeamLoader, otherTeamsData],\n\t)\n\n\treturn <SidebarContext.Provider value={providerValue}>{children}</SidebarContext.Provider>\n}\n"],"names":["useSidebarDataLoader","useEffectOnce","useMemo","SidebarContext"],"mappings":";;;;;;;AAYO,MAAM,kBAAkB,CAAC,EAAE,QAAQ,eAAwD;AACjG,QAAM,EAAE,eAAe,cAAc,eAAmB,IAAA;AAExD,QAAM,gBAAgB,OAAO;AAAA,IAC5B;AAAA,IACA;AAAA,EACD,MAGM,QAAQ,QAAQ,UAAU,OAAO,CAAC,aAAa,SAAS,OAAO,YAAY,EAAE,CAAC;AAE9E,QAAA,YAAYA,0CAAsC,aAAa;AAE/D,QAAA,kBAAkBA,0CAAoC,YAAY;AAExE,QAAM,oBAAoBA,qBAAA;AAAA,IACzB;AAAA,EACD;AAEM,QAAA,iBAAiBA,0CAGrB,aAAa;AAET,QAAA,eAAe,CAAC,WAAmB;AACxC,YAAQ,IAAI,CAAC,kBAAkB,SAAS,EAAE,OAAQ,CAAA,GAAG,gBAAgB,SAAU,CAAA,CAAC,EAAE;AAAA,MACjF,CAAC,CAAC,aAAa,SAAS,MAAM;AAC7B,YAAI,eAAe,WAAW;AAC7B,yBACE,SAAS;AAAA,YACT;AAAA,YACA;AAAA,UAAA,CACA,EACA,KAAK,MAAM;AAAA,UAAA,CAEX;AAAA,QAAA;AAAA,MAGH;AAAA,IAEF;AAAA,EACD;AAEAC,gBAAAA,cAAc,MAAM;AACnB,cAAU,SAAS,EAAE,KAAK,CAAC,QAAQ;AAClC,UAAI,KAAK;AACR,qBAAa,IAAI,iBAAiB;AAAA,MAAA;AAAA,IACnC,CACA;AAAA,EAAA,CACD;AAED,QAAM,gBAAgBC,MAAA;AAAA,IACrB,OAAO;AAAA,MACN,MAAM;AAAA,QACL,KAAK,UAAU;AAAA,QACf,WAAW,gBAAgB;AAAA,QAC3B,aAAa,kBAAkB;AAAA,QAC/B,YAAY,eAAe;AAAA,MAAA;AAAA,IAC5B;AAAA,IAED,CAAC,WAAW,iBAAiB,mBAAmB,cAAc;AAAA,EAC/D;AAEA,wCAAQC,eAAAA,eAAe,UAAf,EAAwB,OAAO,eAAgB,UAAS;AACjE;;"}
@@ -1,9 +1,54 @@
1
- const sidebarContainer = "_sidebarContainer_bmdti_1";
2
- const styles = {
3
- sidebarContainer
1
+ import { jsx } from "react/jsx-runtime";
2
+ import { useSidebarDataLoader } from "./harmony80.mjs";
3
+ import { useEffectOnce } from "./harmony12.mjs";
4
+ import { useMemo } from "react";
5
+ import { SidebarContext } from "./harmony81.mjs";
6
+ const SidebarProvider = ({ config, children }) => {
7
+ const { getJWTPayload, getUserTeams, getCurrentTeam } = config;
8
+ const getOtherTeams = async ({
9
+ userTeams,
10
+ currentTeam
11
+ }) => Promise.resolve(userTeams.filter((userTeam) => userTeam.id !== currentTeam.id));
12
+ const jwtLoader = useSidebarDataLoader(getJWTPayload);
13
+ const userTeamsLoader = useSidebarDataLoader(getUserTeams);
14
+ const currentTeamLoader = useSidebarDataLoader(
15
+ getCurrentTeam
16
+ );
17
+ const otherTeamsData = useSidebarDataLoader(getOtherTeams);
18
+ const loadUserData = (teamId) => {
19
+ Promise.all([currentTeamLoader.loadData({ teamId }), userTeamsLoader.loadData()]).then(
20
+ ([currentTeam, userTeams]) => {
21
+ if (currentTeam && userTeams) {
22
+ otherTeamsData.loadData({
23
+ userTeams,
24
+ currentTeam
25
+ }).then(() => {
26
+ });
27
+ }
28
+ }
29
+ );
30
+ };
31
+ useEffectOnce(() => {
32
+ jwtLoader.loadData().then((jwt) => {
33
+ if (jwt) {
34
+ loadUserData(jwt.userCurrentTeamId);
35
+ }
36
+ });
37
+ });
38
+ const providerValue = useMemo(
39
+ () => ({
40
+ data: {
41
+ jwt: jwtLoader.data,
42
+ userTeams: userTeamsLoader.data,
43
+ currentTeam: currentTeamLoader.data,
44
+ otherTeams: otherTeamsData.data
45
+ }
46
+ }),
47
+ [jwtLoader, userTeamsLoader, currentTeamLoader, otherTeamsData]
48
+ );
49
+ return /* @__PURE__ */ jsx(SidebarContext.Provider, { value: providerValue, children });
4
50
  };
5
51
  export {
6
- styles as default,
7
- sidebarContainer
52
+ SidebarProvider
8
53
  };
9
54
  //# sourceMappingURL=harmony73.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony73.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
1
+ {"version":3,"file":"harmony73.mjs","sources":["../src/components/Sidebar/SidebarProvider.tsx"],"sourcesContent":["import { useSidebarDataLoader } from '@components/Sidebar/hooks/useSidebarDataLoader'\nimport type { JwtTokenPayload } from '@features/auth/core/types/jwtTokenPayload'\nimport { useEffectOnce } from '@utils'\nimport { type PropsWithChildren, useMemo } from 'react'\nimport { SidebarContext } from './SidebarContext'\nimport type {\n\tSidebarContextProps,\n\tSidebarProviderProps,\n\tSidebarTeam,\n\tSidebarTeamExtended,\n} from './types'\n\nexport const SidebarProvider = ({ config, children }: PropsWithChildren<SidebarProviderProps>) => {\n\tconst { getJWTPayload, getUserTeams, getCurrentTeam } = config\n\n\tconst getOtherTeams = async ({\n\t\tuserTeams,\n\t\tcurrentTeam,\n\t}: {\n\t\tuserTeams: SidebarTeam[]\n\t\tcurrentTeam: SidebarTeamExtended\n\t}) => Promise.resolve(userTeams.filter((userTeam) => userTeam.id !== currentTeam.id))\n\n\tconst jwtLoader = useSidebarDataLoader<JwtTokenPayload>(getJWTPayload)\n\n\tconst userTeamsLoader = useSidebarDataLoader<SidebarTeam[]>(getUserTeams)\n\n\tconst currentTeamLoader = useSidebarDataLoader<SidebarTeamExtended, { teamId: number }>(\n\t\tgetCurrentTeam,\n\t)\n\n\tconst otherTeamsData = useSidebarDataLoader<\n\t\tSidebarTeam[],\n\t\t{ userTeams: SidebarTeam[]; currentTeam: SidebarTeamExtended }\n\t>(getOtherTeams)\n\n\tconst loadUserData = (teamId: number) => {\n\t\tPromise.all([currentTeamLoader.loadData({ teamId }), userTeamsLoader.loadData()]).then(\n\t\t\t([currentTeam, userTeams]) => {\n\t\t\t\tif (currentTeam && userTeams) {\n\t\t\t\t\totherTeamsData\n\t\t\t\t\t\t.loadData({\n\t\t\t\t\t\t\tuserTeams,\n\t\t\t\t\t\t\tcurrentTeam,\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.then(() => {\n\t\t\t\t\t\t\t// TODO - do we need to mark all loaders completed somehow?\n\t\t\t\t\t\t})\n\t\t\t\t} else {\n\t\t\t\t\t// TODO - some data did not load - handle this\n\t\t\t\t}\n\t\t\t},\n\t\t)\n\t}\n\n\tuseEffectOnce(() => {\n\t\tjwtLoader.loadData().then((jwt) => {\n\t\t\tif (jwt) {\n\t\t\t\tloadUserData(jwt.userCurrentTeamId)\n\t\t\t}\n\t\t})\n\t})\n\n\tconst providerValue = useMemo<SidebarContextProps>(\n\t\t() => ({\n\t\t\tdata: {\n\t\t\t\tjwt: jwtLoader.data,\n\t\t\t\tuserTeams: userTeamsLoader.data,\n\t\t\t\tcurrentTeam: currentTeamLoader.data,\n\t\t\t\totherTeams: otherTeamsData.data,\n\t\t\t},\n\t\t}),\n\t\t[jwtLoader, userTeamsLoader, currentTeamLoader, otherTeamsData],\n\t)\n\n\treturn <SidebarContext.Provider value={providerValue}>{children}</SidebarContext.Provider>\n}\n"],"names":[],"mappings":";;;;;AAYO,MAAM,kBAAkB,CAAC,EAAE,QAAQ,eAAwD;AACjG,QAAM,EAAE,eAAe,cAAc,eAAmB,IAAA;AAExD,QAAM,gBAAgB,OAAO;AAAA,IAC5B;AAAA,IACA;AAAA,EACD,MAGM,QAAQ,QAAQ,UAAU,OAAO,CAAC,aAAa,SAAS,OAAO,YAAY,EAAE,CAAC;AAE9E,QAAA,YAAY,qBAAsC,aAAa;AAE/D,QAAA,kBAAkB,qBAAoC,YAAY;AAExE,QAAM,oBAAoB;AAAA,IACzB;AAAA,EACD;AAEM,QAAA,iBAAiB,qBAGrB,aAAa;AAET,QAAA,eAAe,CAAC,WAAmB;AACxC,YAAQ,IAAI,CAAC,kBAAkB,SAAS,EAAE,OAAQ,CAAA,GAAG,gBAAgB,SAAU,CAAA,CAAC,EAAE;AAAA,MACjF,CAAC,CAAC,aAAa,SAAS,MAAM;AAC7B,YAAI,eAAe,WAAW;AAC7B,yBACE,SAAS;AAAA,YACT;AAAA,YACA;AAAA,UAAA,CACA,EACA,KAAK,MAAM;AAAA,UAAA,CAEX;AAAA,QAAA;AAAA,MAGH;AAAA,IAEF;AAAA,EACD;AAEA,gBAAc,MAAM;AACnB,cAAU,SAAS,EAAE,KAAK,CAAC,QAAQ;AAClC,UAAI,KAAK;AACR,qBAAa,IAAI,iBAAiB;AAAA,MAAA;AAAA,IACnC,CACA;AAAA,EAAA,CACD;AAED,QAAM,gBAAgB;AAAA,IACrB,OAAO;AAAA,MACN,MAAM;AAAA,QACL,KAAK,UAAU;AAAA,QACf,WAAW,gBAAgB;AAAA,QAC3B,aAAa,kBAAkB;AAAA,QAC/B,YAAY,eAAe;AAAA,MAAA;AAAA,IAC5B;AAAA,IAED,CAAC,WAAW,iBAAiB,mBAAmB,cAAc;AAAA,EAC/D;AAEA,6BAAQ,eAAe,UAAf,EAAwB,OAAO,eAAgB,UAAS;AACjE;"}
@@ -1,12 +1,42 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
- const Avatar_module = require("./harmony88.cjs");
5
- const Avatar = ({
6
- src,
7
- href = "/",
8
- ariaLabel = "Lokalise App Home",
9
- alt = "Lokalise Logo"
10
- }) => /* @__PURE__ */ jsxRuntime.jsx("a", { className: Avatar_module.default.logoLink, href, "aria-label": ariaLabel, children: /* @__PURE__ */ jsxRuntime.jsx("img", { src, alt }) });
11
- exports.Avatar = Avatar;
4
+ const IconLink = require("./harmony82.cjs");
5
+ const ProfileMenu = require("./harmony83.cjs");
6
+ const useSidebar = require("./harmony84.cjs");
7
+ const louis = require("@lokalise/louis");
8
+ const permissions = require("./harmony85.cjs");
9
+ const Avatar = require("./harmony86.cjs");
10
+ const HelpMenu = require("./harmony87.cjs");
11
+ const SidebarContent_module = require("./harmony88.cjs");
12
+ const SidebarContent = ({ widgetsConfig, children, ...navProps }) => {
13
+ const sidebarContextProps = useSidebar.useSidebar();
14
+ const {
15
+ data: { jwt }
16
+ } = sidebarContextProps;
17
+ const { avatar } = widgetsConfig;
18
+ return /* @__PURE__ */ jsxRuntime.jsxs("nav", { ...navProps, className: SidebarContent_module.default.sidebarContainer, children: [
19
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
20
+ /* @__PURE__ */ jsxRuntime.jsx(Avatar.Avatar, { ...avatar }),
21
+ jwt.loading ? /* @__PURE__ */ jsxRuntime.jsx(louis.Skeleton, { description: "Top Section Loader", animated: true, className: SidebarContent_module.default.sidebarSkeleton, children: Array.from({ length: 3 }).map(() => /* @__PURE__ */ jsxRuntime.jsx(
22
+ louis.Rectangle,
23
+ {
24
+ height: 40,
25
+ width: 40
26
+ },
27
+ `sidebar-top-widget-loader-${crypto.randomUUID()}`
28
+ )) }) : /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: jwt.result && !jwt.result.isEndOfTrialActive && !jwt.result.isTeamSuspended && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
29
+ /* @__PURE__ */ jsxRuntime.jsx(IconLink.IconLink, { to: "/projects", label: "Projects", icon: louis.ProjectIcon }),
30
+ /* @__PURE__ */ jsxRuntime.jsx(IconLink.IconLink, { to: "/order", label: "Order", icon: louis.ShoppingBagIcon }),
31
+ permissions.canAccessReporting(jwt.result) && /* @__PURE__ */ jsxRuntime.jsx(IconLink.IconLink, { to: "/analytics", label: "Analytics", icon: louis.ChartLineIcon })
32
+ ] }) }),
33
+ /* @__PURE__ */ jsxRuntime.jsx(HelpMenu.HelpMenu, { ...widgetsConfig.helpMenu })
34
+ ] }),
35
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
36
+ children && typeof children === "function" ? children(sidebarContextProps) : children,
37
+ /* @__PURE__ */ jsxRuntime.jsx(ProfileMenu.ProfileMenu, { config: widgetsConfig.profileMenu })
38
+ ] })
39
+ ] });
40
+ };
41
+ exports.SidebarContent = SidebarContent;
12
42
  //# sourceMappingURL=harmony74.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony74.cjs","sources":["../src/components/Sidebar/Widgets/Avatar/Avatar.tsx"],"sourcesContent":["import styles from './Avatar.module.css'\n\ntype AvatarProps = {\n\t/** URL of the avatar/logo image */\n\tsrc: string\n\t/** Link destination when avatar is clicked. Defaults to '/' */\n\thref?: string\n\t/** Accessibility label for the avatar link. Defaults to 'Home' */\n\tariaLabel?: string\n\t/** Alt text for the avatar image. Defaults to 'Lokalise' */\n\talt?: string\n}\n\n/**\n * Display company main avatar / logo in the top section of the Sidebar.\n * Used as the main branding element and home navigation link.\n */\nexport const Avatar = ({\n\tsrc,\n\thref = '/',\n\tariaLabel = 'Lokalise App Home',\n\talt = 'Lokalise Logo',\n}: AvatarProps) => (\n\t<a className={styles.logoLink} href={href} aria-label={ariaLabel}>\n\t\t<img src={src} alt={alt} />\n\t</a>\n)\n"],"names":["jsx","styles"],"mappings":";;;;AAiBO,MAAM,SAAS,CAAC;AAAA,EACtB;AAAA,EACA,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,MAAM;AACP,MACEA,2BAAAA,IAAA,KAAA,EAAE,WAAWC,cAAA,QAAO,UAAU,MAAY,cAAY,WACtD,UAACD,2BAAAA,IAAA,OAAA,EAAI,KAAU,IAAA,CAAU,EAC1B,CAAA;;"}
1
+ {"version":3,"file":"harmony74.cjs","sources":["../src/components/Sidebar/SidebarContent/SidebarContent.tsx"],"sourcesContent":["import { IconLink } from '@components/Sidebar/Widgets/IconLink/IconLink'\nimport { ProfileMenu } from '@components/Sidebar/Widgets/ProfileMenu/ProfileMenu'\nimport { useSidebar } from '@components/Sidebar/hooks/useSidebar'\nimport type { SidebarWidgetsConfig } from '@components/Sidebar/types'\nimport type { SidebarContextProps } from '@components/Sidebar/types'\nimport { ChartLineIcon, ProjectIcon, Rectangle, ShoppingBagIcon, Skeleton } from '@lokalise/louis'\nimport { canAccessReporting } from '@utils/user/permissions'\nimport type { HTMLProps, ReactNode } from 'react'\nimport { Avatar } from '../Widgets/Avatar/Avatar'\nimport { HelpMenu } from '../Widgets/HelpMenu/HelpMenu'\nimport styles from './SidebarContent.module.css'\n\nexport type SidebarContentProps = HTMLProps<HTMLElement> & {\n\twidgetsConfig: SidebarWidgetsConfig\n\tchildren?: ((props: SidebarContextProps) => ReactNode) | ReactNode\n}\n\nexport const SidebarContent = ({ widgetsConfig, children, ...navProps }: SidebarContentProps) => {\n\tconst sidebarContextProps = useSidebar()\n\n\tconst {\n\t\tdata: { jwt },\n\t} = sidebarContextProps\n\n\tconst { avatar } = widgetsConfig\n\n\treturn (\n\t\t<nav {...navProps} className={styles.sidebarContainer}>\n\t\t\t<div>\n\t\t\t\t<Avatar {...avatar} />\n\n\t\t\t\t{jwt.loading ? (\n\t\t\t\t\t<Skeleton description={'Top Section Loader'} animated className={styles.sidebarSkeleton}>\n\t\t\t\t\t\t{Array.from({ length: 3 }).map(() => (\n\t\t\t\t\t\t\t<Rectangle\n\t\t\t\t\t\t\t\tkey={`sidebar-top-widget-loader-${crypto.randomUUID()}`}\n\t\t\t\t\t\t\t\theight={40}\n\t\t\t\t\t\t\t\twidth={40}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</Skeleton>\n\t\t\t\t) : (\n\t\t\t\t\t<>\n\t\t\t\t\t\t{jwt.result && !jwt.result.isEndOfTrialActive && !jwt.result.isTeamSuspended && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t{/** TODO - All URLs should be pointing to Expert here. We need resolve URL function to deal with this */}\n\t\t\t\t\t\t\t\t<IconLink to=\"/projects\" label={'Projects'} icon={ProjectIcon} />\n\t\t\t\t\t\t\t\t<IconLink to=\"/order\" label=\"Order\" icon={ShoppingBagIcon} />\n\n\t\t\t\t\t\t\t\t{canAccessReporting(jwt.result) && (\n\t\t\t\t\t\t\t\t\t<IconLink to=\"/analytics\" label=\"Analytics\" icon={ChartLineIcon} />\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t\t<HelpMenu {...widgetsConfig.helpMenu} />\n\t\t\t</div>\n\t\t\t<div>\n\t\t\t\t{children && typeof children === 'function' ? children(sidebarContextProps) : children}\n\t\t\t\t<ProfileMenu config={widgetsConfig.profileMenu} />\n\t\t\t</div>\n\t\t</nav>\n\t)\n}\n"],"names":["useSidebar","styles","jsxs","jsx","Avatar","Skeleton","Rectangle","Fragment","IconLink","ProjectIcon","ShoppingBagIcon","canAccessReporting","ChartLineIcon","HelpMenu","ProfileMenu"],"mappings":";;;;;;;;;;;AAiBO,MAAM,iBAAiB,CAAC,EAAE,eAAe,UAAU,GAAG,eAAoC;AAChG,QAAM,sBAAsBA,WAAAA,WAAW;AAEjC,QAAA;AAAA,IACL,MAAM,EAAE,IAAI;AAAA,EAAA,IACT;AAEE,QAAA,EAAE,WAAW;AAEnB,yCACE,OAAK,EAAA,GAAG,UAAU,WAAWC,8BAAO,kBACpC,UAAA;AAAA,IAAAC,gCAAC,OACA,EAAA,UAAA;AAAA,MAACC,2BAAAA,IAAAC,OAAA,QAAA,EAAQ,GAAG,QAAQ;AAAA,MAEnB,IAAI,UACJD,2BAAAA,IAACE,kBAAS,aAAa,sBAAsB,UAAQ,MAAC,WAAWJ,8BAAO,iBACtE,UAAA,MAAM,KAAK,EAAE,QAAQ,EAAG,CAAA,EAAE,IAAI,MAC9BE,2BAAA;AAAA,QAACG,MAAA;AAAA,QAAA;AAAA,UAEA,QAAQ;AAAA,UACR,OAAO;AAAA,QAAA;AAAA,QAFF,6BAA6B,OAAO,YAAY;AAAA,MAAA,CAItD,EAAA,CACF,IAEAH,+BAAAI,WAAAA,UAAA,EACE,cAAI,UAAU,CAAC,IAAI,OAAO,sBAAsB,CAAC,IAAI,OAAO,mBAG3DL,gCAAAK,WAAAA,UAAA,EAAA,UAAA;AAAA,QAAAJ,+BAACK,SAAAA,YAAS,IAAG,aAAY,OAAO,YAAY,MAAMC,MAAAA,aAAa;AAAA,uCAC9DD,SAAAA,UAAS,EAAA,IAAG,UAAS,OAAM,SAAQ,MAAME,MAAAA,iBAAiB;AAAA,QAE1DC,YAAAA,mBAAmB,IAAI,MAAM,KAC7BR,2BAAA,IAACK,SAAS,UAAA,EAAA,IAAG,cAAa,OAAM,aAAY,MAAMI,MAAAA,cAAe,CAAA;AAAA,MAAA,EAAA,CAEnE,EAEF,CAAA;AAAA,MAEAT,2BAAAA,IAAAU,SAAA,UAAA,EAAU,GAAG,cAAc,SAAU,CAAA;AAAA,IAAA,GACvC;AAAA,oCACC,OACC,EAAA,UAAA;AAAA,MAAA,YAAY,OAAO,aAAa,aAAa,SAAS,mBAAmB,IAAI;AAAA,MAC7EV,2BAAAA,IAAAW,YAAAA,aAAA,EAAY,QAAQ,cAAc,YAAa,CAAA;AAAA,IAAA,EACjD,CAAA;AAAA,EAAA,GACD;AAEF;;"}
@@ -1,12 +1,42 @@
1
- import { jsx } from "react/jsx-runtime";
1
+ import { jsxs, jsx, Fragment } from "react/jsx-runtime";
2
+ import { IconLink } from "./harmony82.mjs";
3
+ import { ProfileMenu } from "./harmony83.mjs";
4
+ import { useSidebar } from "./harmony84.mjs";
5
+ import { Skeleton, Rectangle, ProjectIcon, ShoppingBagIcon, ChartLineIcon } from "@lokalise/louis";
6
+ import { canAccessReporting } from "./harmony85.mjs";
7
+ import { Avatar } from "./harmony86.mjs";
8
+ import { HelpMenu } from "./harmony87.mjs";
2
9
  import styles from "./harmony88.mjs";
3
- const Avatar = ({
4
- src,
5
- href = "/",
6
- ariaLabel = "Lokalise App Home",
7
- alt = "Lokalise Logo"
8
- }) => /* @__PURE__ */ jsx("a", { className: styles.logoLink, href, "aria-label": ariaLabel, children: /* @__PURE__ */ jsx("img", { src, alt }) });
10
+ const SidebarContent = ({ widgetsConfig, children, ...navProps }) => {
11
+ const sidebarContextProps = useSidebar();
12
+ const {
13
+ data: { jwt }
14
+ } = sidebarContextProps;
15
+ const { avatar } = widgetsConfig;
16
+ return /* @__PURE__ */ jsxs("nav", { ...navProps, className: styles.sidebarContainer, children: [
17
+ /* @__PURE__ */ jsxs("div", { children: [
18
+ /* @__PURE__ */ jsx(Avatar, { ...avatar }),
19
+ jwt.loading ? /* @__PURE__ */ jsx(Skeleton, { description: "Top Section Loader", animated: true, className: styles.sidebarSkeleton, children: Array.from({ length: 3 }).map(() => /* @__PURE__ */ jsx(
20
+ Rectangle,
21
+ {
22
+ height: 40,
23
+ width: 40
24
+ },
25
+ `sidebar-top-widget-loader-${crypto.randomUUID()}`
26
+ )) }) : /* @__PURE__ */ jsx(Fragment, { children: jwt.result && !jwt.result.isEndOfTrialActive && !jwt.result.isTeamSuspended && /* @__PURE__ */ jsxs(Fragment, { children: [
27
+ /* @__PURE__ */ jsx(IconLink, { to: "/projects", label: "Projects", icon: ProjectIcon }),
28
+ /* @__PURE__ */ jsx(IconLink, { to: "/order", label: "Order", icon: ShoppingBagIcon }),
29
+ canAccessReporting(jwt.result) && /* @__PURE__ */ jsx(IconLink, { to: "/analytics", label: "Analytics", icon: ChartLineIcon })
30
+ ] }) }),
31
+ /* @__PURE__ */ jsx(HelpMenu, { ...widgetsConfig.helpMenu })
32
+ ] }),
33
+ /* @__PURE__ */ jsxs("div", { children: [
34
+ children && typeof children === "function" ? children(sidebarContextProps) : children,
35
+ /* @__PURE__ */ jsx(ProfileMenu, { config: widgetsConfig.profileMenu })
36
+ ] })
37
+ ] });
38
+ };
9
39
  export {
10
- Avatar
40
+ SidebarContent
11
41
  };
12
42
  //# sourceMappingURL=harmony74.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony74.mjs","sources":["../src/components/Sidebar/Widgets/Avatar/Avatar.tsx"],"sourcesContent":["import styles from './Avatar.module.css'\n\ntype AvatarProps = {\n\t/** URL of the avatar/logo image */\n\tsrc: string\n\t/** Link destination when avatar is clicked. Defaults to '/' */\n\thref?: string\n\t/** Accessibility label for the avatar link. Defaults to 'Home' */\n\tariaLabel?: string\n\t/** Alt text for the avatar image. Defaults to 'Lokalise' */\n\talt?: string\n}\n\n/**\n * Display company main avatar / logo in the top section of the Sidebar.\n * Used as the main branding element and home navigation link.\n */\nexport const Avatar = ({\n\tsrc,\n\thref = '/',\n\tariaLabel = 'Lokalise App Home',\n\talt = 'Lokalise Logo',\n}: AvatarProps) => (\n\t<a className={styles.logoLink} href={href} aria-label={ariaLabel}>\n\t\t<img src={src} alt={alt} />\n\t</a>\n)\n"],"names":[],"mappings":";;AAiBO,MAAM,SAAS,CAAC;AAAA,EACtB;AAAA,EACA,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,MAAM;AACP,MACE,oBAAA,KAAA,EAAE,WAAW,OAAO,UAAU,MAAY,cAAY,WACtD,UAAC,oBAAA,OAAA,EAAI,KAAU,IAAA,CAAU,EAC1B,CAAA;"}
1
+ {"version":3,"file":"harmony74.mjs","sources":["../src/components/Sidebar/SidebarContent/SidebarContent.tsx"],"sourcesContent":["import { IconLink } from '@components/Sidebar/Widgets/IconLink/IconLink'\nimport { ProfileMenu } from '@components/Sidebar/Widgets/ProfileMenu/ProfileMenu'\nimport { useSidebar } from '@components/Sidebar/hooks/useSidebar'\nimport type { SidebarWidgetsConfig } from '@components/Sidebar/types'\nimport type { SidebarContextProps } from '@components/Sidebar/types'\nimport { ChartLineIcon, ProjectIcon, Rectangle, ShoppingBagIcon, Skeleton } from '@lokalise/louis'\nimport { canAccessReporting } from '@utils/user/permissions'\nimport type { HTMLProps, ReactNode } from 'react'\nimport { Avatar } from '../Widgets/Avatar/Avatar'\nimport { HelpMenu } from '../Widgets/HelpMenu/HelpMenu'\nimport styles from './SidebarContent.module.css'\n\nexport type SidebarContentProps = HTMLProps<HTMLElement> & {\n\twidgetsConfig: SidebarWidgetsConfig\n\tchildren?: ((props: SidebarContextProps) => ReactNode) | ReactNode\n}\n\nexport const SidebarContent = ({ widgetsConfig, children, ...navProps }: SidebarContentProps) => {\n\tconst sidebarContextProps = useSidebar()\n\n\tconst {\n\t\tdata: { jwt },\n\t} = sidebarContextProps\n\n\tconst { avatar } = widgetsConfig\n\n\treturn (\n\t\t<nav {...navProps} className={styles.sidebarContainer}>\n\t\t\t<div>\n\t\t\t\t<Avatar {...avatar} />\n\n\t\t\t\t{jwt.loading ? (\n\t\t\t\t\t<Skeleton description={'Top Section Loader'} animated className={styles.sidebarSkeleton}>\n\t\t\t\t\t\t{Array.from({ length: 3 }).map(() => (\n\t\t\t\t\t\t\t<Rectangle\n\t\t\t\t\t\t\t\tkey={`sidebar-top-widget-loader-${crypto.randomUUID()}`}\n\t\t\t\t\t\t\t\theight={40}\n\t\t\t\t\t\t\t\twidth={40}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</Skeleton>\n\t\t\t\t) : (\n\t\t\t\t\t<>\n\t\t\t\t\t\t{jwt.result && !jwt.result.isEndOfTrialActive && !jwt.result.isTeamSuspended && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t{/** TODO - All URLs should be pointing to Expert here. We need resolve URL function to deal with this */}\n\t\t\t\t\t\t\t\t<IconLink to=\"/projects\" label={'Projects'} icon={ProjectIcon} />\n\t\t\t\t\t\t\t\t<IconLink to=\"/order\" label=\"Order\" icon={ShoppingBagIcon} />\n\n\t\t\t\t\t\t\t\t{canAccessReporting(jwt.result) && (\n\t\t\t\t\t\t\t\t\t<IconLink to=\"/analytics\" label=\"Analytics\" icon={ChartLineIcon} />\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</>\n\t\t\t\t)}\n\t\t\t\t<HelpMenu {...widgetsConfig.helpMenu} />\n\t\t\t</div>\n\t\t\t<div>\n\t\t\t\t{children && typeof children === 'function' ? children(sidebarContextProps) : children}\n\t\t\t\t<ProfileMenu config={widgetsConfig.profileMenu} />\n\t\t\t</div>\n\t\t</nav>\n\t)\n}\n"],"names":[],"mappings":";;;;;;;;;AAiBO,MAAM,iBAAiB,CAAC,EAAE,eAAe,UAAU,GAAG,eAAoC;AAChG,QAAM,sBAAsB,WAAW;AAEjC,QAAA;AAAA,IACL,MAAM,EAAE,IAAI;AAAA,EAAA,IACT;AAEE,QAAA,EAAE,WAAW;AAEnB,8BACE,OAAK,EAAA,GAAG,UAAU,WAAW,OAAO,kBACpC,UAAA;AAAA,IAAA,qBAAC,OACA,EAAA,UAAA;AAAA,MAAC,oBAAA,QAAA,EAAQ,GAAG,QAAQ;AAAA,MAEnB,IAAI,UACJ,oBAAC,YAAS,aAAa,sBAAsB,UAAQ,MAAC,WAAW,OAAO,iBACtE,UAAA,MAAM,KAAK,EAAE,QAAQ,EAAG,CAAA,EAAE,IAAI,MAC9B;AAAA,QAAC;AAAA,QAAA;AAAA,UAEA,QAAQ;AAAA,UACR,OAAO;AAAA,QAAA;AAAA,QAFF,6BAA6B,OAAO,YAAY;AAAA,MAAA,CAItD,EAAA,CACF,IAEA,oBAAA,UAAA,EACE,cAAI,UAAU,CAAC,IAAI,OAAO,sBAAsB,CAAC,IAAI,OAAO,mBAG3D,qBAAA,UAAA,EAAA,UAAA;AAAA,QAAA,oBAAC,YAAS,IAAG,aAAY,OAAO,YAAY,MAAM,aAAa;AAAA,4BAC9D,UAAS,EAAA,IAAG,UAAS,OAAM,SAAQ,MAAM,iBAAiB;AAAA,QAE1D,mBAAmB,IAAI,MAAM,KAC7B,oBAAC,UAAS,EAAA,IAAG,cAAa,OAAM,aAAY,MAAM,cAAe,CAAA;AAAA,MAAA,EAAA,CAEnE,EAEF,CAAA;AAAA,MAEA,oBAAA,UAAA,EAAU,GAAG,cAAc,SAAU,CAAA;AAAA,IAAA,GACvC;AAAA,yBACC,OACC,EAAA,UAAA;AAAA,MAAA,YAAY,OAAO,aAAa,aAAa,SAAS,mBAAmB,IAAI;AAAA,MAC7E,oBAAA,aAAA,EAAY,QAAQ,cAAc,YAAa,CAAA;AAAA,IAAA,EACjD,CAAA;AAAA,EAAA,GACD;AAEF;"}
@@ -1,21 +1,12 @@
1
1
  "use strict";
2
- Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const jsxRuntime = require("react/jsx-runtime");
4
- const louis = require("@lokalise/louis");
5
- const clsx = require("./harmony70.cjs");
6
- const IconLink_module = require("./harmony89.cjs");
7
- const IconLink = ({ label, to, icon: Icon }) => {
8
- return /* @__PURE__ */ jsxRuntime.jsx(louis.Tooltip, { placement: "right", tooltip: label, children: /* @__PURE__ */ jsxRuntime.jsx(
9
- louis.Link,
10
- {
11
- "aria-label": label,
12
- className: clsx.clsx(IconLink_module.default.link, {
13
- [IconLink_module.default.active]: window.location.pathname.startsWith(to)
14
- }),
15
- href: to,
16
- children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { size: "25px" })
17
- }
18
- ) });
2
+ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
+ const breadcrumbsItem = "_breadcrumbsItem_1hm6a_1";
4
+ const breadcrumbs = "_breadcrumbs_1hm6a_1";
5
+ const classes = {
6
+ breadcrumbsItem,
7
+ breadcrumbs
19
8
  };
20
- exports.IconLink = IconLink;
9
+ exports.breadcrumbs = breadcrumbs;
10
+ exports.breadcrumbsItem = breadcrumbsItem;
11
+ exports.default = classes;
21
12
  //# sourceMappingURL=harmony75.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony75.cjs","sources":["../src/components/Sidebar/Widgets/IconLink/IconLink.tsx"],"sourcesContent":["import { Link, type SvgIconProps, Tooltip } from '@lokalise/louis'\nimport clsx from 'clsx'\nimport type { FC } from 'react'\nimport styles from './IconLink.module.css'\n\ntype IconLinkProps = {\n\t/** URL destination for the link */\n\tto: string\n\t/** Text to display in the tooltip when hovering over the icon */\n\tlabel: string\n\t/** Icon component from @lokalise/louis to display */\n\ticon: FC<SvgIconProps>\n}\n\n/**\n * A navigation link component that displays an icon with a tooltip.\n * When hovered, shows a tooltip with the label text.\n * The link is highlighted when the current URL matches its destination.\n *\n * @example\n * ```tsx\n * <IconLink to=\"/projects\" label=\"Projects\" icon={FolderOpenIcon} />\n * ```\n */\nexport const IconLink = ({ label, to, icon: Icon }: IconLinkProps) => {\n\treturn (\n\t\t<Tooltip placement=\"right\" tooltip={label}>\n\t\t\t<Link\n\t\t\t\taria-label={label}\n\t\t\t\tclassName={clsx(styles.link, {\n\t\t\t\t\t[styles.active]: window.location.pathname.startsWith(to),\n\t\t\t\t})}\n\t\t\t\thref={to}\n\t\t\t>\n\t\t\t\t<Icon size=\"25px\" />\n\t\t\t</Link>\n\t\t</Tooltip>\n\t)\n}\n"],"names":["jsx","Tooltip","Link","clsx","styles"],"mappings":";;;;;;AAwBO,MAAM,WAAW,CAAC,EAAE,OAAO,IAAI,MAAM,WAA0B;AACrE,SACEA,2BAAA,IAAAC,MAAA,SAAA,EAAQ,WAAU,SAAQ,SAAS,OACnC,UAAAD,2BAAA;AAAA,IAACE,MAAA;AAAA,IAAA;AAAA,MACA,cAAY;AAAA,MACZ,WAAWC,KAAAA,KAAKC,gBAAA,QAAO,MAAM;AAAA,QAC5B,CAACA,gBAAAA,QAAO,MAAM,GAAG,OAAO,SAAS,SAAS,WAAW,EAAE;AAAA,MAAA,CACvD;AAAA,MACD,MAAM;AAAA,MAEN,UAAAJ,2BAAAA,IAAC,MAAK,EAAA,MAAK,OAAO,CAAA;AAAA,IAAA;AAAA,EAAA,GAEpB;AAEF;;"}
1
+ {"version":3,"file":"harmony75.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;"}
@@ -1,21 +1,12 @@
1
- import { jsx } from "react/jsx-runtime";
2
- import { Tooltip, Link } from "@lokalise/louis";
3
- import { clsx } from "./harmony70.mjs";
4
- import styles from "./harmony89.mjs";
5
- const IconLink = ({ label, to, icon: Icon }) => {
6
- return /* @__PURE__ */ jsx(Tooltip, { placement: "right", tooltip: label, children: /* @__PURE__ */ jsx(
7
- Link,
8
- {
9
- "aria-label": label,
10
- className: clsx(styles.link, {
11
- [styles.active]: window.location.pathname.startsWith(to)
12
- }),
13
- href: to,
14
- children: /* @__PURE__ */ jsx(Icon, { size: "25px" })
15
- }
16
- ) });
1
+ const breadcrumbsItem = "_breadcrumbsItem_1hm6a_1";
2
+ const breadcrumbs = "_breadcrumbs_1hm6a_1";
3
+ const classes = {
4
+ breadcrumbsItem,
5
+ breadcrumbs
17
6
  };
18
7
  export {
19
- IconLink
8
+ breadcrumbs,
9
+ breadcrumbsItem,
10
+ classes as default
20
11
  };
21
12
  //# sourceMappingURL=harmony75.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony75.mjs","sources":["../src/components/Sidebar/Widgets/IconLink/IconLink.tsx"],"sourcesContent":["import { Link, type SvgIconProps, Tooltip } from '@lokalise/louis'\nimport clsx from 'clsx'\nimport type { FC } from 'react'\nimport styles from './IconLink.module.css'\n\ntype IconLinkProps = {\n\t/** URL destination for the link */\n\tto: string\n\t/** Text to display in the tooltip when hovering over the icon */\n\tlabel: string\n\t/** Icon component from @lokalise/louis to display */\n\ticon: FC<SvgIconProps>\n}\n\n/**\n * A navigation link component that displays an icon with a tooltip.\n * When hovered, shows a tooltip with the label text.\n * The link is highlighted when the current URL matches its destination.\n *\n * @example\n * ```tsx\n * <IconLink to=\"/projects\" label=\"Projects\" icon={FolderOpenIcon} />\n * ```\n */\nexport const IconLink = ({ label, to, icon: Icon }: IconLinkProps) => {\n\treturn (\n\t\t<Tooltip placement=\"right\" tooltip={label}>\n\t\t\t<Link\n\t\t\t\taria-label={label}\n\t\t\t\tclassName={clsx(styles.link, {\n\t\t\t\t\t[styles.active]: window.location.pathname.startsWith(to),\n\t\t\t\t})}\n\t\t\t\thref={to}\n\t\t\t>\n\t\t\t\t<Icon size=\"25px\" />\n\t\t\t</Link>\n\t\t</Tooltip>\n\t)\n}\n"],"names":[],"mappings":";;;;AAwBO,MAAM,WAAW,CAAC,EAAE,OAAO,IAAI,MAAM,WAA0B;AACrE,SACE,oBAAA,SAAA,EAAQ,WAAU,SAAQ,SAAS,OACnC,UAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACA,cAAY;AAAA,MACZ,WAAW,KAAK,OAAO,MAAM;AAAA,QAC5B,CAAC,OAAO,MAAM,GAAG,OAAO,SAAS,SAAS,WAAW,EAAE;AAAA,MAAA,CACvD;AAAA,MACD,MAAM;AAAA,MAEN,UAAA,oBAAC,MAAK,EAAA,MAAK,OAAO,CAAA;AAAA,IAAA;AAAA,EAAA,GAEpB;AAEF;"}
1
+ {"version":3,"file":"harmony75.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;"}
@@ -2,25 +2,10 @@
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const louis = require("@lokalise/louis");
5
- const clsx = require("./harmony70.cjs");
6
- const Menu_module = require("./harmony90.cjs");
7
- const Menu = ({ children, icon: Icon }) => {
8
- return /* @__PURE__ */ jsxRuntime.jsx(
9
- louis.Menu,
10
- {
11
- menuButton: ({ opened }) => /* @__PURE__ */ jsxRuntime.jsx(louis.Tooltip, { placement: "right", tooltip: "Help", children: /* @__PURE__ */ jsxRuntime.jsx(
12
- "button",
13
- {
14
- type: "button",
15
- className: clsx.clsx(Menu_module.default.dropdownButton, {
16
- [Menu_module.default.dropdownButtonActive]: opened
17
- }),
18
- children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { size: "25px" })
19
- }
20
- ) }),
21
- children: /* @__PURE__ */ jsxRuntime.jsx(louis.MenuList, { placement: "right-start", children })
22
- }
23
- );
24
- };
25
- exports.Menu = Menu;
5
+ const React = require("react");
6
+ const DropdownContent = ({ items }) => /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: items.map((item, index) => /* @__PURE__ */ jsxRuntime.jsxs(React.Fragment, { children: [
7
+ !!index && item.some((value) => value.visible) && /* @__PURE__ */ jsxRuntime.jsx(louis.MenuDivider, {}),
8
+ item.filter(({ visible }) => visible).map(({ link, label, onClick }) => /* @__PURE__ */ jsxRuntime.jsx(louis.MenuItem, { href: link || "#", "aria-label": label, onClick, children: label }, label))
9
+ ] }, item[0].label)) });
10
+ exports.DropdownContent = DropdownContent;
26
11
  //# sourceMappingURL=harmony76.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony76.cjs","sources":["../src/components/Sidebar/Widgets/Menu/Menu.tsx"],"sourcesContent":["import { MenuList, type SvgIconProps, Tooltip, Menu as UIMenu } from '@lokalise/louis'\nimport clsx from 'clsx'\nimport type { FC, PropsWithChildren } from 'react'\nimport styles from './Menu.module.css'\n\ntype MenuProps = PropsWithChildren<{\n\t/** Icon component from @lokalise/louis to display in the menu button */\n\ticon: FC<SvgIconProps>\n}>\n\n/**\n * A dropdown menu component that displays an icon button which reveals a menu list when clicked.\n * The menu is positioned to the right of the button and includes a tooltip.\n *\n * Used primarily for dropdown menus in the Sidebar, such as the Help menu.\n *\n * @example\n * ```tsx\n * <Menu icon={HelpCenterIcon}>\n * <MenuItem href=\"/docs\">Documentation</MenuItem>\n * <MenuItem href=\"/tutorial\">Tutorials</MenuItem>\n * <MenuDivider />\n * <MenuItem href=\"/blog\">Blog</MenuItem>\n * </Menu>\n * ```\n */\nexport const Menu = ({ children, icon: Icon }: MenuProps) => {\n\treturn (\n\t\t<UIMenu\n\t\t\tmenuButton={({ opened }) => (\n\t\t\t\t<Tooltip placement=\"right\" tooltip=\"Help\">\n\t\t\t\t\t<button\n\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\tclassName={clsx(styles.dropdownButton, {\n\t\t\t\t\t\t\t[styles.dropdownButtonActive]: opened,\n\t\t\t\t\t\t})}\n\t\t\t\t\t>\n\t\t\t\t\t\t<Icon size=\"25px\" />\n\t\t\t\t\t</button>\n\t\t\t\t</Tooltip>\n\t\t\t)}\n\t\t>\n\t\t\t<MenuList placement=\"right-start\">{children}</MenuList>\n\t\t</UIMenu>\n\t)\n}\n"],"names":["jsx","UIMenu","Tooltip","clsx","styles","MenuList"],"mappings":";;;;;;AA0BO,MAAM,OAAO,CAAC,EAAE,UAAU,MAAM,WAAsB;AAE3D,SAAAA,2BAAA;AAAA,IAACC,MAAA;AAAA,IAAA;AAAA,MACA,YAAY,CAAC,EAAE,OAAO,qCACpBC,MAAQ,SAAA,EAAA,WAAU,SAAQ,SAAQ,QAClC,UAAAF,2BAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACA,MAAK;AAAA,UACL,WAAWG,KAAAA,KAAKC,YAAA,QAAO,gBAAgB;AAAA,YACtC,CAACA,YAAAA,QAAO,oBAAoB,GAAG;AAAA,UAAA,CAC/B;AAAA,UAED,UAAAJ,2BAAAA,IAAC,MAAK,EAAA,MAAK,OAAO,CAAA;AAAA,QAAA;AAAA,MAAA,GAEpB;AAAA,MAGD,UAACA,2BAAA,IAAAK,MAAA,UAAA,EAAS,WAAU,eAAe,SAAS,CAAA;AAAA,IAAA;AAAA,EAC7C;AAEF;;"}
1
+ {"version":3,"file":"harmony76.cjs","sources":["../src/components/NavigationPanel/components/DropdownContent/DropdownContent.tsx"],"sourcesContent":["import { MenuDivider, MenuItem } from '@lokalise/louis'\nimport { Fragment } from 'react'\nimport type { DropdownItem } from '../../types/navigation'\n\nexport const DropdownContent = ({ items }: { items: DropdownItem[][] }) => (\n\t<>\n\t\t{items.map((item, index) => (\n\t\t\t<Fragment key={item[0].label}>\n\t\t\t\t{!!index && item.some((value) => value.visible) && <MenuDivider />}\n\t\t\t\t{item\n\t\t\t\t\t.filter(({ visible }) => visible)\n\t\t\t\t\t.map(({ link, label, onClick }) => (\n\t\t\t\t\t\t<MenuItem key={label} href={link || '#'} aria-label={label} onClick={onClick}>\n\t\t\t\t\t\t\t{label}\n\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t))}\n\t\t\t</Fragment>\n\t\t))}\n\t</>\n)\n"],"names":["jsx","Fragment","jsxs","MenuDivider","MenuItem"],"mappings":";;;;;AAIO,MAAM,kBAAkB,CAAC,EAAE,MAAA,MACjCA,2BAAAA,IAAAC,WAAAA,UAAA,EACE,UAAM,MAAA,IAAI,CAAC,MAAM,UACjBC,2BAAAA,KAACD,MAAAA,UAAA,EACC,UAAA;AAAA,EAAC,CAAA,CAAC,SAAS,KAAK,KAAK,CAAC,UAAU,MAAM,OAAO,KAAKD,+BAACG,MAAAA,aAAY,CAAA,CAAA;AAAA,EAC/D,KACC,OAAO,CAAC,EAAE,cAAc,OAAO,EAC/B,IAAI,CAAC,EAAE,MAAM,OAAO,QAAQ,MAC3BH,+BAAAI,MAAAA,UAAA,EAAqB,MAAM,QAAQ,KAAK,cAAY,OAAO,SAC1D,UADa,MAAA,GAAA,KAEf,CACA;AAAA,EAAA,GARY,KAAK,CAAC,EAAE,KASvB,CACA,EACF,CAAA;;"}
@@ -1,26 +1,11 @@
1
- import { jsx } from "react/jsx-runtime";
2
- import { Menu as Menu$1, MenuList, Tooltip } from "@lokalise/louis";
3
- import { clsx } from "./harmony70.mjs";
4
- import styles from "./harmony90.mjs";
5
- const Menu = ({ children, icon: Icon }) => {
6
- return /* @__PURE__ */ jsx(
7
- Menu$1,
8
- {
9
- menuButton: ({ opened }) => /* @__PURE__ */ jsx(Tooltip, { placement: "right", tooltip: "Help", children: /* @__PURE__ */ jsx(
10
- "button",
11
- {
12
- type: "button",
13
- className: clsx(styles.dropdownButton, {
14
- [styles.dropdownButtonActive]: opened
15
- }),
16
- children: /* @__PURE__ */ jsx(Icon, { size: "25px" })
17
- }
18
- ) }),
19
- children: /* @__PURE__ */ jsx(MenuList, { placement: "right-start", children })
20
- }
21
- );
22
- };
1
+ import { jsx, Fragment, jsxs } from "react/jsx-runtime";
2
+ import { MenuDivider, MenuItem } from "@lokalise/louis";
3
+ import { Fragment as Fragment$1 } from "react";
4
+ const DropdownContent = ({ items }) => /* @__PURE__ */ jsx(Fragment, { children: items.map((item, index) => /* @__PURE__ */ jsxs(Fragment$1, { children: [
5
+ !!index && item.some((value) => value.visible) && /* @__PURE__ */ jsx(MenuDivider, {}),
6
+ item.filter(({ visible }) => visible).map(({ link, label, onClick }) => /* @__PURE__ */ jsx(MenuItem, { href: link || "#", "aria-label": label, onClick, children: label }, label))
7
+ ] }, item[0].label)) });
23
8
  export {
24
- Menu
9
+ DropdownContent
25
10
  };
26
11
  //# sourceMappingURL=harmony76.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony76.mjs","sources":["../src/components/Sidebar/Widgets/Menu/Menu.tsx"],"sourcesContent":["import { MenuList, type SvgIconProps, Tooltip, Menu as UIMenu } from '@lokalise/louis'\nimport clsx from 'clsx'\nimport type { FC, PropsWithChildren } from 'react'\nimport styles from './Menu.module.css'\n\ntype MenuProps = PropsWithChildren<{\n\t/** Icon component from @lokalise/louis to display in the menu button */\n\ticon: FC<SvgIconProps>\n}>\n\n/**\n * A dropdown menu component that displays an icon button which reveals a menu list when clicked.\n * The menu is positioned to the right of the button and includes a tooltip.\n *\n * Used primarily for dropdown menus in the Sidebar, such as the Help menu.\n *\n * @example\n * ```tsx\n * <Menu icon={HelpCenterIcon}>\n * <MenuItem href=\"/docs\">Documentation</MenuItem>\n * <MenuItem href=\"/tutorial\">Tutorials</MenuItem>\n * <MenuDivider />\n * <MenuItem href=\"/blog\">Blog</MenuItem>\n * </Menu>\n * ```\n */\nexport const Menu = ({ children, icon: Icon }: MenuProps) => {\n\treturn (\n\t\t<UIMenu\n\t\t\tmenuButton={({ opened }) => (\n\t\t\t\t<Tooltip placement=\"right\" tooltip=\"Help\">\n\t\t\t\t\t<button\n\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\tclassName={clsx(styles.dropdownButton, {\n\t\t\t\t\t\t\t[styles.dropdownButtonActive]: opened,\n\t\t\t\t\t\t})}\n\t\t\t\t\t>\n\t\t\t\t\t\t<Icon size=\"25px\" />\n\t\t\t\t\t</button>\n\t\t\t\t</Tooltip>\n\t\t\t)}\n\t\t>\n\t\t\t<MenuList placement=\"right-start\">{children}</MenuList>\n\t\t</UIMenu>\n\t)\n}\n"],"names":["UIMenu"],"mappings":";;;;AA0BO,MAAM,OAAO,CAAC,EAAE,UAAU,MAAM,WAAsB;AAE3D,SAAA;AAAA,IAACA;AAAAA,IAAA;AAAA,MACA,YAAY,CAAC,EAAE,OAAO,0BACpB,SAAQ,EAAA,WAAU,SAAQ,SAAQ,QAClC,UAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACA,MAAK;AAAA,UACL,WAAW,KAAK,OAAO,gBAAgB;AAAA,YACtC,CAAC,OAAO,oBAAoB,GAAG;AAAA,UAAA,CAC/B;AAAA,UAED,UAAA,oBAAC,MAAK,EAAA,MAAK,OAAO,CAAA;AAAA,QAAA;AAAA,MAAA,GAEpB;AAAA,MAGD,UAAC,oBAAA,UAAA,EAAS,WAAU,eAAe,SAAS,CAAA;AAAA,IAAA;AAAA,EAC7C;AAEF;"}
1
+ {"version":3,"file":"harmony76.mjs","sources":["../src/components/NavigationPanel/components/DropdownContent/DropdownContent.tsx"],"sourcesContent":["import { MenuDivider, MenuItem } from '@lokalise/louis'\nimport { Fragment } from 'react'\nimport type { DropdownItem } from '../../types/navigation'\n\nexport const DropdownContent = ({ items }: { items: DropdownItem[][] }) => (\n\t<>\n\t\t{items.map((item, index) => (\n\t\t\t<Fragment key={item[0].label}>\n\t\t\t\t{!!index && item.some((value) => value.visible) && <MenuDivider />}\n\t\t\t\t{item\n\t\t\t\t\t.filter(({ visible }) => visible)\n\t\t\t\t\t.map(({ link, label, onClick }) => (\n\t\t\t\t\t\t<MenuItem key={label} href={link || '#'} aria-label={label} onClick={onClick}>\n\t\t\t\t\t\t\t{label}\n\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t))}\n\t\t\t</Fragment>\n\t\t))}\n\t</>\n)\n"],"names":["Fragment"],"mappings":";;;AAIO,MAAM,kBAAkB,CAAC,EAAE,MAAA,MACjC,oBAAA,UAAA,EACE,UAAM,MAAA,IAAI,CAAC,MAAM,UACjB,qBAACA,YAAA,EACC,UAAA;AAAA,EAAC,CAAA,CAAC,SAAS,KAAK,KAAK,CAAC,UAAU,MAAM,OAAO,KAAK,oBAAC,aAAY,CAAA,CAAA;AAAA,EAC/D,KACC,OAAO,CAAC,EAAE,cAAc,OAAO,EAC/B,IAAI,CAAC,EAAE,MAAM,OAAO,QAAQ,MAC3B,oBAAA,UAAA,EAAqB,MAAM,QAAQ,KAAK,cAAY,OAAO,SAC1D,UADa,MAAA,GAAA,KAEf,CACA;AAAA,EAAA,GARY,KAAK,CAAC,EAAE,KASvB,CACA,EACF,CAAA;"}
@@ -1,8 +1,32 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
- const ProfileMenuContent = require("./harmony91.cjs");
5
- const ProfileMenuProvider = require("./harmony92.cjs");
6
- const ProfileMenu = ({ config, children }) => /* @__PURE__ */ jsxRuntime.jsx(ProfileMenuProvider.ProfileMenuProvider, { config, children: /* @__PURE__ */ jsxRuntime.jsx(ProfileMenuContent.ProfileMenuContent, { children }) });
7
- exports.ProfileMenu = ProfileMenu;
4
+ const louis = require("@lokalise/louis");
5
+ const clsx = require("./harmony70.cjs");
6
+ const React = require("react");
7
+ const NavItemContents = require("./harmony89.cjs");
8
+ const styles_module = require("./harmony90.cjs");
9
+ const NavigationTabsItem = React.forwardRef(
10
+ ({ label, href = "", disabled = false, badge, onClick, novel }, ref) => /* @__PURE__ */ jsxRuntime.jsx(louis.Tooltip, { tooltip: "You do not have access to this function", show: disabled, children: /* @__PURE__ */ jsxRuntime.jsx(
11
+ "div",
12
+ {
13
+ className: disabled ? styles_module.default.projectNavigationItemDisabled : styles_module.default.projectNavigationItem,
14
+ children: onClick || disabled || !href ? /* @__PURE__ */ jsxRuntime.jsx(
15
+ "button",
16
+ {
17
+ type: "button",
18
+ ref,
19
+ className: clsx.clsx(styles_module.default.withNavLinkStyle, {
20
+ [styles_module.default.disabled]: disabled
21
+ }),
22
+ disabled,
23
+ onClick,
24
+ children: /* @__PURE__ */ jsxRuntime.jsx(NavItemContents.NavItemContents, { label, badge, novel })
25
+ }
26
+ ) : /* @__PURE__ */ jsxRuntime.jsx("a", { href, className: styles_module.default.withNavLinkStyle, children: /* @__PURE__ */ jsxRuntime.jsx(NavItemContents.NavItemContents, { label, badge, novel }) })
27
+ }
28
+ ) })
29
+ );
30
+ NavigationTabsItem.displayName = "NavigationTabsItem";
31
+ exports.NavigationTabsItem = NavigationTabsItem;
8
32
  //# sourceMappingURL=harmony77.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"harmony77.cjs","sources":["../src/components/Sidebar/Widgets/ProfileMenu/ProfileMenu.tsx"],"sourcesContent":["import { ProfileMenuContent, type ProfileMenuContentProps } from './ProfileMenuContent'\nimport { ProfileMenuProvider } from './ProfileMenuProvider'\nimport type { SidebarProfileMenuConfig } from './types'\n\ntype ProfileMenuProps = {\n\t/** Configuration object containing team and user settings */\n\tconfig: SidebarProfileMenuConfig\n\t/** Render function for the menu content */\n\tchildren: ProfileMenuContentProps['children']\n}\n\n/**\n * A contextual menu component that provides team management functionality.\n * It manages team switching, profile settings, billing options, and upgrade prompts.\n *\n * The component uses a render prop pattern to provide context values to its children,\n * allowing flexible composition of menu items based on user permissions and team status.\n *\n * @example\n * ```tsx\n * <ProfileMenu config={profileMenuConfig}>\n * {({ allowTeamCreation, showBillingButton }) => (\n * <>\n * <TeamSwitch onSwitchTeam={handleTeamSwitch} />\n * {allowTeamCreation && <MenuItem>Create new team</MenuItem>}\n * {showBillingButton && <MenuItem href=\"/billing\">Billing</MenuItem>}\n * </>\n * )}\n * </ProfileMenu>\n * ```\n */\nexport const ProfileMenu = ({ config, children }: ProfileMenuProps) => (\n\t<ProfileMenuProvider config={config}>\n\t\t<ProfileMenuContent>{children}</ProfileMenuContent>\n\t</ProfileMenuProvider>\n)\n"],"names":["jsx","ProfileMenuProvider","ProfileMenuContent"],"mappings":";;;;;AA+BO,MAAM,cAAc,CAAC,EAAE,QAAQ,SAAS,MAC7CA,2BAAA,IAAAC,oBAAA,qBAAA,EAAoB,QACpB,UAAAD,2BAAA,IAACE,mBAAoB,oBAAA,EAAA,SAAS,CAAA,EAC/B,CAAA;;"}
1
+ {"version":3,"file":"harmony77.cjs","sources":["../src/components/NavigationPanel/components/NavigationTabs/NavigationTabsItem/NavigationTabsItem.tsx"],"sourcesContent":["import { Tooltip } from '@lokalise/louis'\nimport clsx from 'clsx'\nimport { forwardRef } from 'react'\nimport { NavItemContents } from './NavItemContents'\nimport classes from './styles.module.css'\n\ntype NavigationTabsItemProps = {\n\tlabel: string\n\tbadge?: number\n\tdisabled?: boolean\n\tactive?: boolean\n\tonClick?: () => void\n\thref?: string\n\tnovel?: string\n}\n\nexport const NavigationTabsItem = forwardRef<HTMLButtonElement, NavigationTabsItemProps>(\n\t({ label, href = '', disabled = false, badge, onClick, novel }, ref) => (\n\t\t<Tooltip tooltip=\"You do not have access to this function\" show={disabled}>\n\t\t\t<div\n\t\t\t\tclassName={disabled ? classes.projectNavigationItemDisabled : classes.projectNavigationItem}\n\t\t\t>\n\t\t\t\t{onClick || disabled || !href ? (\n\t\t\t\t\t<button\n\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\tref={ref}\n\t\t\t\t\t\tclassName={clsx(classes.withNavLinkStyle, {\n\t\t\t\t\t\t\t[classes.disabled]: disabled,\n\t\t\t\t\t\t})}\n\t\t\t\t\t\tdisabled={disabled}\n\t\t\t\t\t\tonClick={onClick}\n\t\t\t\t\t>\n\t\t\t\t\t\t<NavItemContents label={label} badge={badge} novel={novel} />\n\t\t\t\t\t</button>\n\t\t\t\t) : (\n\t\t\t\t\t<a href={href} className={classes.withNavLinkStyle}>\n\t\t\t\t\t\t<NavItemContents label={label} badge={badge} novel={novel} />\n\t\t\t\t\t</a>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t</Tooltip>\n\t),\n)\n\nNavigationTabsItem.displayName = 'NavigationTabsItem'\n"],"names":["forwardRef","jsx","Tooltip","classes","clsx","NavItemContents"],"mappings":";;;;;;;;AAgBO,MAAM,qBAAqBA,MAAA;AAAA,EACjC,CAAC,EAAE,OAAO,OAAO,IAAI,WAAW,OAAO,OAAO,SAAS,MAAA,GAAS,QAC/DC,2BAAA,IAACC,iBAAQ,SAAQ,2CAA0C,MAAM,UAChE,UAAAD,2BAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACA,WAAW,WAAWE,cAAAA,QAAQ,gCAAgCA,cAAQ,QAAA;AAAA,MAErE,UAAA,WAAW,YAAY,CAAC,OACxBF,2BAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACA,MAAK;AAAA,UACL;AAAA,UACA,WAAWG,KAAAA,KAAKD,cAAA,QAAQ,kBAAkB;AAAA,YACzC,CAACA,cAAAA,QAAQ,QAAQ,GAAG;AAAA,UAAA,CACpB;AAAA,UACD;AAAA,UACA;AAAA,UAEA,UAACF,2BAAA,IAAAI,gBAAA,iBAAA,EAAgB,OAAc,OAAc,MAAc,CAAA;AAAA,QAAA;AAAA,MAAA,IAG5DJ,2BAAAA,IAAC,KAAE,EAAA,MAAY,WAAWE,cAAA,QAAQ,kBACjC,UAAAF,2BAAA,IAACI,gBAAgB,iBAAA,EAAA,OAAc,OAAc,MAAc,CAAA,EAC5D,CAAA;AAAA,IAAA;AAAA,EAAA,EAGH,CAAA;AAEF;AAEA,mBAAmB,cAAc;;"}