@stack-spot/portal-layout 0.0.65 → 1.0.0-dev.1768482785050

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 (363) hide show
  1. package/CHANGELOG.md +779 -0
  2. package/dist/Layout.d.ts +60 -8
  3. package/dist/Layout.d.ts.map +1 -1
  4. package/dist/Layout.js +59 -24
  5. package/dist/Layout.js.map +1 -1
  6. package/dist/LayoutOverlayManager.d.ts +274 -19
  7. package/dist/LayoutOverlayManager.d.ts.map +1 -1
  8. package/dist/LayoutOverlayManager.js +373 -82
  9. package/dist/LayoutOverlayManager.js.map +1 -1
  10. package/dist/WelcomeTour.d.ts +2 -0
  11. package/dist/WelcomeTour.d.ts.map +1 -0
  12. package/dist/WelcomeTour.js +8 -0
  13. package/dist/WelcomeTour.js.map +1 -0
  14. package/dist/components/Backdrop.d.ts +75 -0
  15. package/dist/components/Backdrop.d.ts.map +1 -0
  16. package/dist/components/Backdrop.js +69 -0
  17. package/dist/components/Backdrop.js.map +1 -0
  18. package/dist/components/Contact/show-contact-modal.d.ts +5 -0
  19. package/dist/components/Contact/show-contact-modal.d.ts.map +1 -0
  20. package/dist/components/Contact/show-contact-modal.js +37 -0
  21. package/dist/components/Contact/show-contact-modal.js.map +1 -0
  22. package/dist/components/ContactModal.d.ts +1 -0
  23. package/dist/components/ContactModal.d.ts.map +1 -0
  24. package/dist/components/ContactModal.js +2 -0
  25. package/dist/components/ContactModal.js.map +1 -0
  26. package/dist/components/Dialog.d.ts +54 -7
  27. package/dist/components/Dialog.d.ts.map +1 -1
  28. package/dist/components/Dialog.js +8 -2
  29. package/dist/components/Dialog.js.map +1 -1
  30. package/dist/components/Header.d.ts +38 -2
  31. package/dist/components/Header.d.ts.map +1 -1
  32. package/dist/components/Header.js +9 -4
  33. package/dist/components/Header.js.map +1 -1
  34. package/dist/components/NotificationCenter/NotificationPanel.d.ts +3 -0
  35. package/dist/components/NotificationCenter/NotificationPanel.d.ts.map +1 -0
  36. package/dist/components/NotificationCenter/NotificationPanel.js +19 -0
  37. package/dist/components/NotificationCenter/NotificationPanel.js.map +1 -0
  38. package/dist/components/NotificationCenter/NotificationPanelHeader.d.ts +3 -0
  39. package/dist/components/NotificationCenter/NotificationPanelHeader.d.ts.map +1 -0
  40. package/dist/components/NotificationCenter/NotificationPanelHeader.js +16 -0
  41. package/dist/components/NotificationCenter/NotificationPanelHeader.js.map +1 -0
  42. package/dist/components/NotificationCenter/NotificationsPanelFooter.d.ts +4 -0
  43. package/dist/components/NotificationCenter/NotificationsPanelFooter.d.ts.map +1 -0
  44. package/dist/components/NotificationCenter/NotificationsPanelFooter.js +12 -0
  45. package/dist/components/NotificationCenter/NotificationsPanelFooter.js.map +1 -0
  46. package/dist/components/NotificationCenter/dictionary.d.ts +2 -0
  47. package/dist/components/NotificationCenter/dictionary.d.ts.map +1 -0
  48. package/dist/components/NotificationCenter/dictionary.js +43 -0
  49. package/dist/components/NotificationCenter/dictionary.js.map +1 -0
  50. package/dist/components/NotificationCenter/index.d.ts +2 -0
  51. package/dist/components/NotificationCenter/index.d.ts.map +1 -0
  52. package/dist/components/NotificationCenter/index.js +34 -0
  53. package/dist/components/NotificationCenter/index.js.map +1 -0
  54. package/dist/components/NotificationCenter/styled.d.ts +3 -0
  55. package/dist/components/NotificationCenter/styled.d.ts.map +1 -0
  56. package/dist/components/NotificationCenter/styled.js +74 -0
  57. package/dist/components/NotificationCenter/styled.js.map +1 -0
  58. package/dist/components/NotificationCenter/types.d.ts +21 -0
  59. package/dist/components/NotificationCenter/types.d.ts.map +1 -0
  60. package/dist/components/NotificationCenter/types.js.map +1 -0
  61. package/dist/components/NotificationCenter/utils.d.ts +5 -0
  62. package/dist/components/NotificationCenter/utils.d.ts.map +1 -0
  63. package/dist/components/NotificationCenter/utils.js +18 -0
  64. package/dist/components/NotificationCenter/utils.js.map +1 -0
  65. package/dist/components/OverlayContent.d.ts +27 -1
  66. package/dist/components/OverlayContent.d.ts.map +1 -1
  67. package/dist/components/OverlayContent.js +8 -4
  68. package/dist/components/OverlayContent.js.map +1 -1
  69. package/dist/components/PortalSwitcher.d.ts +19 -1
  70. package/dist/components/PortalSwitcher.d.ts.map +1 -1
  71. package/dist/components/PortalSwitcher.js +16 -31
  72. package/dist/components/PortalSwitcher.js.map +1 -1
  73. package/dist/components/PrivacyPolicyMessage/hooks.d.ts +10 -0
  74. package/dist/components/PrivacyPolicyMessage/hooks.d.ts.map +1 -0
  75. package/dist/components/PrivacyPolicyMessage/hooks.js +33 -0
  76. package/dist/components/PrivacyPolicyMessage/hooks.js.map +1 -0
  77. package/dist/components/PrivacyPolicyMessage/index.d.ts +7 -0
  78. package/dist/components/PrivacyPolicyMessage/index.d.ts.map +1 -0
  79. package/dist/components/PrivacyPolicyMessage/index.js +5 -0
  80. package/dist/components/PrivacyPolicyMessage/index.js.map +1 -0
  81. package/dist/components/Rate/FeedbackModal.d.ts +8 -0
  82. package/dist/components/Rate/FeedbackModal.d.ts.map +1 -0
  83. package/dist/components/Rate/FeedbackModal.js +52 -0
  84. package/dist/components/Rate/FeedbackModal.js.map +1 -0
  85. package/dist/components/Rate/hook.d.ts +3 -0
  86. package/dist/components/Rate/hook.d.ts.map +1 -0
  87. package/dist/components/Rate/hook.js +48 -0
  88. package/dist/components/Rate/hook.js.map +1 -0
  89. package/dist/components/Rate/index.d.ts +10 -0
  90. package/dist/components/Rate/index.d.ts.map +1 -0
  91. package/dist/components/Rate/index.js +16 -0
  92. package/dist/components/Rate/index.js.map +1 -0
  93. package/dist/components/Rate/on-nps-submit.d.ts +7 -0
  94. package/dist/components/Rate/on-nps-submit.d.ts.map +1 -0
  95. package/dist/components/Rate/on-nps-submit.js +8 -0
  96. package/dist/components/Rate/on-nps-submit.js.map +1 -0
  97. package/dist/components/Rate/show-rate-us-modals.d.ts +17 -0
  98. package/dist/components/Rate/show-rate-us-modals.d.ts.map +1 -0
  99. package/dist/components/Rate/show-rate-us-modals.js +14 -0
  100. package/dist/components/Rate/show-rate-us-modals.js.map +1 -0
  101. package/dist/components/Rate/utils.d.ts +2 -0
  102. package/dist/components/Rate/utils.d.ts.map +1 -0
  103. package/dist/components/Rate/utils.js +10 -0
  104. package/dist/components/Rate/utils.js.map +1 -0
  105. package/dist/components/Toaster.d.ts +35 -0
  106. package/dist/components/Toaster.d.ts.map +1 -1
  107. package/dist/components/Toaster.js +32 -4
  108. package/dist/components/Toaster.js.map +1 -1
  109. package/dist/components/TypeForm/hook.d.ts +2 -0
  110. package/dist/components/TypeForm/hook.d.ts.map +1 -0
  111. package/dist/components/TypeForm/hook.js +11 -0
  112. package/dist/components/TypeForm/hook.js.map +1 -0
  113. package/dist/components/TypeForm/index.d.ts +6 -0
  114. package/dist/components/TypeForm/index.d.ts.map +1 -0
  115. package/dist/components/TypeForm/index.js +23 -0
  116. package/dist/components/TypeForm/index.js.map +1 -0
  117. package/dist/components/TypeForm/show-typeform-modal.d.ts +5 -0
  118. package/dist/components/TypeForm/show-typeform-modal.d.ts.map +1 -0
  119. package/dist/components/TypeForm/show-typeform-modal.js +11 -0
  120. package/dist/components/TypeForm/show-typeform-modal.js.map +1 -0
  121. package/dist/components/TypeForm/utils.d.ts +2 -0
  122. package/dist/components/TypeForm/utils.d.ts.map +1 -0
  123. package/dist/components/TypeForm/utils.js +9 -0
  124. package/dist/components/TypeForm/utils.js.map +1 -0
  125. package/dist/components/UserMenu.d.ts +19 -2
  126. package/dist/components/UserMenu.d.ts.map +1 -1
  127. package/dist/components/UserMenu.js +12 -6
  128. package/dist/components/UserMenu.js.map +1 -1
  129. package/dist/components/error/ErrorBoundary.d.ts +25 -4
  130. package/dist/components/error/ErrorBoundary.d.ts.map +1 -1
  131. package/dist/components/error/ErrorBoundary.js +10 -1
  132. package/dist/components/error/ErrorBoundary.js.map +1 -1
  133. package/dist/components/error/ErrorManager.d.ts +22 -6
  134. package/dist/components/error/ErrorManager.d.ts.map +1 -1
  135. package/dist/components/error/ErrorManager.js +21 -1
  136. package/dist/components/error/ErrorManager.js.map +1 -1
  137. package/dist/components/error/SilentErrorBoundary.d.ts +26 -5
  138. package/dist/components/error/SilentErrorBoundary.d.ts.map +1 -1
  139. package/dist/components/error/SilentErrorBoundary.js +10 -0
  140. package/dist/components/error/SilentErrorBoundary.js.map +1 -1
  141. package/dist/components/menu/MenuContent.d.ts +20 -4
  142. package/dist/components/menu/MenuContent.d.ts.map +1 -1
  143. package/dist/components/menu/MenuContent.js +89 -88
  144. package/dist/components/menu/MenuContent.js.map +1 -1
  145. package/dist/components/menu/MenuSectionGroup.d.ts +2 -0
  146. package/dist/components/menu/MenuSectionGroup.d.ts.map +1 -0
  147. package/dist/components/menu/MenuSectionGroup.js +121 -0
  148. package/dist/components/menu/MenuSectionGroup.js.map +1 -0
  149. package/dist/components/menu/MenuSections.d.ts +17 -0
  150. package/dist/components/menu/MenuSections.d.ts.map +1 -1
  151. package/dist/components/menu/MenuSections.js +159 -39
  152. package/dist/components/menu/MenuSections.js.map +1 -1
  153. package/dist/components/menu/PageSelector.d.ts +5 -0
  154. package/dist/components/menu/PageSelector.d.ts.map +1 -1
  155. package/dist/components/menu/PageSelector.js +9 -4
  156. package/dist/components/menu/PageSelector.js.map +1 -1
  157. package/dist/components/menu/types.d.ts +219 -8
  158. package/dist/components/menu/types.d.ts.map +1 -1
  159. package/dist/components/tour/StepContainer.d.ts +37 -0
  160. package/dist/components/tour/StepContainer.d.ts.map +1 -0
  161. package/dist/components/tour/StepContainer.js +51 -0
  162. package/dist/components/tour/StepContainer.js.map +1 -0
  163. package/dist/components/tour/StepNavigation.d.ts +29 -0
  164. package/dist/components/tour/StepNavigation.d.ts.map +1 -0
  165. package/dist/components/tour/StepNavigation.js +37 -0
  166. package/dist/components/tour/StepNavigation.js.map +1 -0
  167. package/dist/components/tour/StepTitle.d.ts +17 -0
  168. package/dist/components/tour/StepTitle.d.ts.map +1 -0
  169. package/dist/components/tour/StepTitle.js +10 -0
  170. package/dist/components/tour/StepTitle.js.map +1 -0
  171. package/dist/components/tour/hook.d.ts +3 -0
  172. package/dist/components/tour/hook.d.ts.map +1 -0
  173. package/dist/components/tour/hook.js +10 -0
  174. package/dist/components/tour/hook.js.map +1 -0
  175. package/dist/components/tour/index.d.ts +5 -0
  176. package/dist/components/tour/index.d.ts.map +1 -0
  177. package/dist/components/tour/index.js +5 -0
  178. package/dist/components/tour/index.js.map +1 -0
  179. package/dist/components/tour/manager.d.ts +34 -0
  180. package/dist/components/tour/manager.d.ts.map +1 -0
  181. package/dist/components/tour/manager.js +104 -0
  182. package/dist/components/tour/manager.js.map +1 -0
  183. package/dist/components/tour/utils.d.ts +67 -0
  184. package/dist/components/tour/utils.d.ts.map +1 -0
  185. package/dist/components/tour/utils.js +60 -0
  186. package/dist/components/tour/utils.js.map +1 -0
  187. package/dist/components/user-menu-manager.d.ts +13 -0
  188. package/dist/components/user-menu-manager.d.ts.map +1 -0
  189. package/dist/components/user-menu-manager.js +36 -0
  190. package/dist/components/user-menu-manager.js.map +1 -0
  191. package/dist/dictionary.d.ts +6 -1
  192. package/dist/dictionary.d.ts.map +1 -1
  193. package/dist/dictionary.js +7 -2
  194. package/dist/dictionary.js.map +1 -1
  195. package/dist/elements.d.ts +7 -0
  196. package/dist/elements.d.ts.map +1 -1
  197. package/dist/elements.js +7 -0
  198. package/dist/elements.js.map +1 -1
  199. package/dist/index.d.ts +15 -8
  200. package/dist/index.d.ts.map +1 -1
  201. package/dist/index.js +15 -8
  202. package/dist/index.js.map +1 -1
  203. package/dist/layout.css +190 -35
  204. package/dist/svg/StarFillWithGradient.d.ts +6 -0
  205. package/dist/svg/StarFillWithGradient.d.ts.map +1 -0
  206. package/dist/svg/StarFillWithGradient.js +4 -0
  207. package/dist/svg/StarFillWithGradient.js.map +1 -0
  208. package/dist/toaster.d.ts +55 -9
  209. package/dist/toaster.d.ts.map +1 -1
  210. package/dist/toaster.js +34 -6
  211. package/dist/toaster.js.map +1 -1
  212. package/dist/types.d.ts +5 -0
  213. package/dist/types.d.ts.map +1 -0
  214. package/dist/types.js +2 -0
  215. package/dist/types.js.map +1 -0
  216. package/dist/utils.d.ts +6 -69
  217. package/dist/utils.d.ts.map +1 -1
  218. package/dist/utils.js +9 -130
  219. package/dist/utils.js.map +1 -1
  220. package/package.dev.json +3 -0
  221. package/package.json +24 -13
  222. package/package.stg.json +3 -0
  223. package/readme.md +147 -0
  224. package/src/Layout.tsx +166 -58
  225. package/src/LayoutOverlayManager.tsx +499 -85
  226. package/src/WelcomeTour.tsx +8 -0
  227. package/src/components/Backdrop.tsx +116 -0
  228. package/src/components/Contact/show-contact-modal.tsx +71 -0
  229. package/src/components/Dialog.tsx +58 -9
  230. package/src/components/Header.tsx +53 -5
  231. package/src/components/NotificationCenter/NotificationPanel.tsx +40 -0
  232. package/src/components/NotificationCenter/NotificationPanelHeader.tsx +53 -0
  233. package/src/components/NotificationCenter/NotificationsPanelFooter.tsx +25 -0
  234. package/src/components/NotificationCenter/dictionary.ts +44 -0
  235. package/src/components/NotificationCenter/index.tsx +58 -0
  236. package/src/components/NotificationCenter/styled.ts +75 -0
  237. package/src/components/NotificationCenter/types.ts +24 -0
  238. package/src/components/NotificationCenter/utils.ts +20 -0
  239. package/src/components/OverlayContent.tsx +40 -5
  240. package/src/components/PortalSwitcher.tsx +33 -39
  241. package/src/components/PrivacyPolicyMessage/hooks.tsx +49 -0
  242. package/src/components/PrivacyPolicyMessage/index.tsx +21 -0
  243. package/src/components/Rate/FeedbackModal.tsx +86 -0
  244. package/src/components/Rate/hook.tsx +61 -0
  245. package/src/components/Rate/index.tsx +36 -0
  246. package/src/components/Rate/on-nps-submit.ts +18 -0
  247. package/src/components/Rate/show-rate-us-modals.tsx +29 -0
  248. package/src/components/Rate/utils.ts +11 -0
  249. package/src/components/Toaster.tsx +82 -3
  250. package/src/components/TypeForm/hook.tsx +13 -0
  251. package/src/components/TypeForm/index.tsx +50 -0
  252. package/src/components/TypeForm/show-typeform-modal.tsx +10 -0
  253. package/src/components/TypeForm/utils.ts +8 -0
  254. package/src/components/UserMenu.tsx +32 -8
  255. package/src/components/error/ErrorBoundary.tsx +11 -2
  256. package/src/components/error/ErrorManager.ts +22 -6
  257. package/src/components/error/SilentErrorBoundary.tsx +12 -2
  258. package/src/components/menu/MenuContent.tsx +102 -110
  259. package/src/components/menu/MenuSectionGroup.tsx +121 -0
  260. package/src/components/menu/MenuSections.tsx +342 -93
  261. package/src/components/menu/PageSelector.tsx +16 -4
  262. package/src/components/menu/types.ts +221 -9
  263. package/src/components/tour/StepContainer.tsx +92 -0
  264. package/src/components/tour/StepNavigation.tsx +72 -0
  265. package/src/components/tour/StepTitle.tsx +28 -0
  266. package/src/components/tour/hook.ts +12 -0
  267. package/src/components/tour/index.ts +6 -0
  268. package/src/components/tour/manager.tsx +119 -0
  269. package/src/components/tour/utils.tsx +119 -0
  270. package/src/components/user-menu-manager.ts +31 -0
  271. package/src/dictionary.ts +7 -2
  272. package/src/elements.ts +7 -0
  273. package/src/index.ts +15 -8
  274. package/src/layout.css +190 -35
  275. package/src/svg/StarFillWithGradient.tsx +14 -0
  276. package/src/toaster.tsx +90 -13
  277. package/src/types.ts +4 -0
  278. package/src/utils.ts +9 -142
  279. package/dist/components/BottomNotification.d.ts +0 -1
  280. package/dist/components/BottomNotification.d.ts.map +0 -1
  281. package/dist/components/BottomNotification.js +0 -2
  282. package/dist/components/BottomNotification.js.map +0 -1
  283. package/dist/components/BottomPanel.d.ts +0 -1
  284. package/dist/components/BottomPanel.d.ts.map +0 -1
  285. package/dist/components/BottomPanel.js +0 -2
  286. package/dist/components/BottomPanel.js.map +0 -1
  287. package/dist/components/SelectionList.d.ts +0 -36
  288. package/dist/components/SelectionList.d.ts.map +0 -1
  289. package/dist/components/SelectionList.js +0 -140
  290. package/dist/components/SelectionList.js.map +0 -1
  291. package/dist/components/error/ErrorFeedback.d.ts +0 -3
  292. package/dist/components/error/ErrorFeedback.d.ts.map +0 -1
  293. package/dist/components/error/ErrorFeedback.js +0 -66
  294. package/dist/components/error/ErrorFeedback.js.map +0 -1
  295. package/dist/components/menu/use-check-text-overflow.d.ts +0 -6
  296. package/dist/components/menu/use-check-text-overflow.d.ts.map +0 -1
  297. package/dist/components/menu/use-check-text-overflow.js +0 -20
  298. package/dist/components/menu/use-check-text-overflow.js.map +0 -1
  299. package/dist/components/menu/use-keyboard-controls.d.ts +0 -23
  300. package/dist/components/menu/use-keyboard-controls.d.ts.map +0 -1
  301. package/dist/components/menu/use-keyboard-controls.js +0 -49
  302. package/dist/components/menu/use-keyboard-controls.js.map +0 -1
  303. package/dist/components/tour/PortalSwitcherStep.d.ts +0 -3
  304. package/dist/components/tour/PortalSwitcherStep.d.ts.map +0 -1
  305. package/dist/components/tour/PortalSwitcherStep.js +0 -29
  306. package/dist/components/tour/PortalSwitcherStep.js.map +0 -1
  307. package/dist/components/types.d.ts +0 -15
  308. package/dist/components/types.d.ts.map +0 -1
  309. package/dist/components/types.js.map +0 -1
  310. package/dist/layout-context.d.ts +0 -10
  311. package/dist/layout-context.d.ts.map +0 -1
  312. package/dist/layout-context.js +0 -11
  313. package/dist/layout-context.js.map +0 -1
  314. package/dist/svg/AI.d.ts +0 -6
  315. package/dist/svg/AI.d.ts.map +0 -1
  316. package/dist/svg/AI.js +0 -9
  317. package/dist/svg/AI.js.map +0 -1
  318. package/dist/svg/EDP.d.ts +0 -6
  319. package/dist/svg/EDP.d.ts.map +0 -1
  320. package/dist/svg/EDP.js +0 -5
  321. package/dist/svg/EDP.js.map +0 -1
  322. package/dist/svg/Forbidden.d.ts +0 -6
  323. package/dist/svg/Forbidden.d.ts.map +0 -1
  324. package/dist/svg/Forbidden.js +0 -4
  325. package/dist/svg/Forbidden.js.map +0 -1
  326. package/dist/svg/HUB.d.ts +0 -6
  327. package/dist/svg/HUB.d.ts.map +0 -1
  328. package/dist/svg/HUB.js +0 -5
  329. package/dist/svg/HUB.js.map +0 -1
  330. package/dist/svg/Logo.d.ts +0 -2
  331. package/dist/svg/Logo.d.ts.map +0 -1
  332. package/dist/svg/Logo.js +0 -4
  333. package/dist/svg/Logo.js.map +0 -1
  334. package/dist/svg/NotFound.d.ts +0 -6
  335. package/dist/svg/NotFound.d.ts.map +0 -1
  336. package/dist/svg/NotFound.js +0 -4
  337. package/dist/svg/NotFound.js.map +0 -1
  338. package/dist/svg/ServerError.d.ts +0 -6
  339. package/dist/svg/ServerError.d.ts.map +0 -1
  340. package/dist/svg/ServerError.js +0 -4
  341. package/dist/svg/ServerError.js.map +0 -1
  342. package/dist/svg/Unauthenticated.d.ts +0 -6
  343. package/dist/svg/Unauthenticated.d.ts.map +0 -1
  344. package/dist/svg/Unauthenticated.js +0 -4
  345. package/dist/svg/Unauthenticated.js.map +0 -1
  346. package/src/components/BottomPanel.tsx +0 -0
  347. package/src/components/SelectionList.tsx +0 -272
  348. package/src/components/error/ErrorFeedback.tsx +0 -114
  349. package/src/components/menu/use-check-text-overflow.tsx +0 -26
  350. package/src/components/menu/use-keyboard-controls.tsx +0 -70
  351. package/src/components/tour/PortalSwitcherStep.tsx +0 -36
  352. package/src/components/types.ts +0 -15
  353. package/src/layout-context.tsx +0 -22
  354. package/src/svg/AI.tsx +0 -37
  355. package/src/svg/EDP.tsx +0 -35
  356. package/src/svg/Forbidden.tsx +0 -22
  357. package/src/svg/HUB.tsx +0 -35
  358. package/src/svg/Logo.tsx +0 -35
  359. package/src/svg/NotFound.tsx +0 -16
  360. package/src/svg/ServerError.tsx +0 -33
  361. package/src/svg/Unauthenticated.tsx +0 -16
  362. /package/dist/components/{types.js → NotificationCenter/types.js} +0 -0
  363. /package/src/components/{BottomNotification.tsx → ContactModal.tsx} +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationPanelHeader.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/NotificationPanelHeader.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA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OAAO,EAAE,OAAO,EAAE,EAAE,EAAE,EAAE,YAAY,EAAE,KAAK,EAAE,YAClG,KAAC,OAAO,IAAC,IAAI,EAAC,IAAI,YAChB,KAAC,SAAS,KAAG,GACL,GACC,IACR,EACP,cAAI,SAAS,EAAC,aAAa,aACzB,uBAAI,KAAC,YAAY,IAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,cAAc,EAAE,KAAK,EAAC,KAAK,GAAG,GAAK,EACtF,uBAAI,KAAC,YAAY,IAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,cAAc,EAAE,KAAK,EAAC,QAAQ,GAAG,GAAK,EACzF,uBAAI,KAAC,YAAY,IAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,cAAc,EAAE,KAAK,EAAC,MAAM,GAAG,GAAK,EACvF,uBAAI,KAAC,YAAY,IAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,cAAc,EAAE,KAAK,EAAC,QAAQ,GAAG,GAAK,EACzF,uBAAI,KAAC,YAAY,IAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,cAAc,EAAE,KAAK,EAAC,KAAK,GAAG,GAAK,IACnF,IACA,CACR,CAAA;AACH,CAAC,CAAA"}
@@ -0,0 +1,4 @@
1
+ export declare const NotificationPanelFooter: ({ onClose }: {
2
+ onClose: () => void;
3
+ }) => import("react/jsx-runtime").JSX.Element;
4
+ //# sourceMappingURL=NotificationsPanelFooter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationsPanelFooter.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/NotificationsPanelFooter.tsx"],"names":[],"mappings":"AAKA,eAAO,MAAM,uBAAuB,GAAI,aAAa;IAAE,OAAO,EAAE,MAAM,IAAI,CAAA;CAAE,4CAmB3E,CAAA"}
@@ -0,0 +1,12 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { Button, Text } from '@citric/core';
3
+ import { useAnchorTag } from '@stack-spot/portal-components/anchor';
4
+ import { useNotificationController } from '@stack-spot/portal-components/Notifications';
5
+ import { useNotificationsDictionary } from './dictionary.js';
6
+ export const NotificationPanelFooter = ({ onClose }) => {
7
+ const t = useNotificationsDictionary();
8
+ const controller = useNotificationController();
9
+ const Link = useAnchorTag();
10
+ return (_jsx(Button, { as: Link, onClick: onClose, size: "sm", colorScheme: "inverse", appearance: "text", className: "see-all", href: controller.config.notificationsPath, children: _jsx(Text, { appearance: "microtext1", children: t.viewAll }) }));
11
+ };
12
+ //# sourceMappingURL=NotificationsPanelFooter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NotificationsPanelFooter.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/NotificationsPanelFooter.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAA;AACnE,OAAO,EAAE,yBAAyB,EAAE,MAAM,6CAA6C,CAAA;AACvF,OAAO,EAAE,0BAA0B,EAAE,MAAM,cAAc,CAAA;AAEzD,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,EAAE,OAAO,EAA2B,EAAE,EAAE;IAC9E,MAAM,CAAC,GAAG,0BAA0B,EAAE,CAAA;IACtC,MAAM,UAAU,GAAG,yBAAyB,EAAE,CAAA;IAC9C,MAAM,IAAI,GAAG,YAAY,EAAE,CAAA;IAC3B,OAAO,CACL,KAAC,MAAM,IACL,EAAE,EAAE,IAAI,EACR,OAAO,EAAE,OAAO,EAChB,IAAI,EAAC,IAAI,EACT,WAAW,EAAC,SAAS,EACrB,UAAU,EAAC,MAAM,EACjB,SAAS,EAAC,SAAS,EACnB,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,iBAAiB,YAEzC,KAAC,IAAI,IAAC,UAAU,EAAC,YAAY,YAC1B,CAAC,CAAC,OAAO,GACL,GACA,CACV,CAAA;AACH,CAAC,CAAA"}
@@ -0,0 +1,2 @@
1
+ export declare const useNotificationsDictionary: () => Record<"close" | "notifications" | "ALL.ariaLabel" | "UNREAD.ariaLabel" | "HIGH.ariaLabel" | "MEDIUM.ariaLabel" | "LOW.ariaLabel" | "ALL.label" | "UNREAD.label" | "HIGH.label" | "MEDIUM.label" | "LOW.label" | "viewAll" | "openNotifications" | "hasUnread" | "loadingNotifications" | "tour", string>;
2
+ //# sourceMappingURL=dictionary.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dictionary.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/dictionary.ts"],"names":[],"mappings":"AA2CA,eAAO,MAAM,0BAA0B,iTAAiC,CAAA"}
@@ -0,0 +1,43 @@
1
+ import { useTranslate } from '@stack-spot/portal-translate';
2
+ const dictionary = {
3
+ en: {
4
+ notifications: 'Notifications',
5
+ 'ALL.ariaLabel': 'Show all notifications',
6
+ 'UNREAD.ariaLabel': 'Show unread notifications',
7
+ 'HIGH.ariaLabel': 'Show critical notifications',
8
+ 'MEDIUM.ariaLabel': 'Show notifications with medium criticality',
9
+ 'LOW.ariaLabel': 'Show notifications with low criticality',
10
+ 'ALL.label': 'All',
11
+ 'UNREAD.label': 'Unread',
12
+ 'HIGH.label': 'High',
13
+ 'MEDIUM.label': 'Medium',
14
+ 'LOW.label': 'Low',
15
+ viewAll: 'View all notifications',
16
+ openNotifications: 'View notifications',
17
+ hasUnread: 'Has Unread notifications',
18
+ close: 'Close',
19
+ loadingNotifications: "Loading notifications. You'll be able to click this button and see them in a few seconds.",
20
+ tour: 'Now we have Notifications, this will help you stay informed of the latest updates about your Workspaces, Studios, and the Stackspot platform.',
21
+ },
22
+ pt: {
23
+ notifications: 'Notificações',
24
+ 'ALL.ariaLabel': 'Mostrar todas as notificações',
25
+ 'UNREAD.ariaLabel': 'Mostrar notificações não lidas',
26
+ 'HIGH.ariaLabel': 'Mostrar notificações críticas',
27
+ 'MEDIUM.ariaLabel': 'Mostrar notificações com criticidade média',
28
+ 'LOW.ariaLabel': 'Mostrar notificações com criticidade baixa',
29
+ 'ALL.label': 'Todas',
30
+ 'UNREAD.label': 'Não lidas',
31
+ 'HIGH.label': 'Alto',
32
+ 'MEDIUM.label': 'Médio',
33
+ 'LOW.label': 'Baixo',
34
+ viewAll: 'Ver todas as notificações',
35
+ openNotifications: 'Visualizar notificações',
36
+ hasUnread: 'Existem notificações não lidas',
37
+ close: 'Fechar',
38
+ loadingNotifications: 'Carregando notificações. Você poderá clicar neste botão e vê-las em alguns segundos.',
39
+ tour: 'Agora temos Notificações, isso irá ajudá-lo a se manter informado sobre as últimas atualizações sobre seus Workspaces, estúdios e a plataforma Stackspot.',
40
+ },
41
+ };
42
+ export const useNotificationsDictionary = () => useTranslate(dictionary);
43
+ //# sourceMappingURL=dictionary.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dictionary.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/dictionary.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAEvE,MAAM,UAAU,GAAG;IACjB,EAAE,EAAE;QACF,aAAa,EAAE,eAAe;QAC9B,eAAe,EAAE,wBAAwB;QACzC,kBAAkB,EAAE,2BAA2B;QAC/C,gBAAgB,EAAE,6BAA6B;QAC/C,kBAAkB,EAAE,4CAA4C;QAChE,eAAe,EAAE,yCAAyC;QAC1D,WAAW,EAAE,KAAK;QAClB,cAAc,EAAE,QAAQ;QACxB,YAAY,EAAE,MAAM;QACpB,cAAc,EAAE,QAAQ;QACxB,WAAW,EAAE,KAAK;QAClB,OAAO,EAAE,wBAAwB;QACjC,iBAAiB,EAAE,oBAAoB;QACvC,SAAS,EAAE,0BAA0B;QACrC,KAAK,EAAE,OAAO;QACd,oBAAoB,EAAE,2FAA2F;QACjH,IAAI,EAAE,+IAA+I;KACtJ;IACD,EAAE,EAAE;QACF,aAAa,EAAE,cAAc;QAC7B,eAAe,EAAE,+BAA+B;QAChD,kBAAkB,EAAE,gCAAgC;QACpD,gBAAgB,EAAE,+BAA+B;QACjD,kBAAkB,EAAE,4CAA4C;QAChE,eAAe,EAAE,4CAA4C;QAC7D,WAAW,EAAE,OAAO;QACpB,cAAc,EAAE,WAAW;QAC3B,YAAY,EAAE,MAAM;QACpB,cAAc,EAAE,OAAO;QACvB,WAAW,EAAE,OAAO;QACpB,OAAO,EAAE,2BAA2B;QACpC,iBAAiB,EAAE,yBAAyB;QAC5C,SAAS,EAAE,gCAAgC;QAC3C,KAAK,EAAE,QAAQ;QACf,oBAAoB,EAAE,sFAAsF;QAC5G,IAAI,EAAE,2JAA2J;KAClK;CACmB,CAAA;AAEtB,MAAM,CAAC,MAAM,0BAA0B,GAAG,GAAG,EAAE,CAAC,YAAY,CAAC,UAAU,CAAC,CAAA"}
@@ -0,0 +1,2 @@
1
+ export declare const NotificationCenter: () => import("react/jsx-runtime").JSX.Element;
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/index.tsx"],"names":[],"mappings":"AAcA,eAAO,MAAM,kBAAkB,+CA2C9B,CAAA"}
@@ -0,0 +1,34 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { IconBox } from '@citric/core';
3
+ import { Bell } from '@citric/icons';
4
+ import { IconButton } from '@citric/ui';
5
+ import { useEffectOnce } from '@stack-spot/portal-components';
6
+ import { useNotificationController, useNotificationList, useUnreadNotifications } from '@stack-spot/portal-components/Notifications';
7
+ import { listToClass } from '@stack-spot/portal-theme';
8
+ import { useEffect, useState } from 'react';
9
+ import { useNotificationsDictionary } from './dictionary.js';
10
+ import { NotificationPanel } from './NotificationPanel.js';
11
+ import { NotificationBox } from './styled.js';
12
+ import { getFiltersFromName, getNameFromFilters } from './utils.js';
13
+ const MAX_ITEMS = 10;
14
+ export const NotificationCenter = () => {
15
+ const [open, setOpen] = useState(false);
16
+ const t = useNotificationsDictionary();
17
+ const { applyFilters, filters, items, status, error } = useNotificationList({ size: MAX_ITEMS });
18
+ const hasUnreadNotification = useUnreadNotifications();
19
+ const controller = useNotificationController();
20
+ useEffectOnce(() => {
21
+ controller.checkUnread();
22
+ });
23
+ useEffect(() => {
24
+ if (open && (hasUnreadNotification || getNameFromFilters(filters) !== 'ALL')) {
25
+ applyFilters(getFiltersFromName('ALL'));
26
+ }
27
+ }, [open]);
28
+ return (_jsxs(NotificationBox, { children: [_jsx(IconButton, { "aria-label": status === 'startup' ? t.loadingNotifications : t.openNotifications, onClick: status === 'startup' ? undefined : () => setOpen(true), className: listToClass([
29
+ 'notification-button',
30
+ status === 'startup' && 'loading',
31
+ status !== 'startup' && hasUnreadNotification && 'unread',
32
+ ]), children: _jsx(IconBox, { size: "md", className: "notificationsTour", children: _jsx(Bell, {}) }) }), _jsx(NotificationPanel, { filter: getNameFromFilters(filters), loading: status === 'loading', error: error, items: items, visible: open, onClose: () => setOpen(false), onFilter: filter => applyFilters({ ...getFiltersFromName(filter), size: MAX_ITEMS }) })] }));
33
+ };
34
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/index.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AACtC,OAAO,EAAE,IAAI,EAAE,MAAM,eAAe,CAAA;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAA;AAC7D,OAAO,EAAE,yBAAyB,EAAE,mBAAmB,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAA;AACpI,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAA;AACtD,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,EAAE,0BAA0B,EAAE,MAAM,cAAc,CAAA;AACzD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E,WAAW,CAAC;oBACrB,qBAAqB;oBACrB,MAAM,KAAK,SAAS,IAAI,SAAS;oBACjC,MAAM,KAAK,SAAS,IAAI,qBAAqB,IAAI,QAAQ;iBAC1D,CAAC,YAEF,KAAC,OAAO,IAAC,IAAI,EAAC,IAAI,EAAC,SAAS,EAAC,mBAAmB,YAC9C,KAAC,IAAI,KAAG,GACA,GACC,EACb,KAAC,iBAAiB,IAChB,MAAM,EAAE,kBAAkB,CAAC,OAAO,CAAC,EACnC,OAAO,EAAE,MAAM,KAAK,SAAS,EAC7B,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,IAAI,EACb,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC,EAC7B,QAAQ,EAAE,MAAM,CAAC,EAAE,CAAC,YAAY,CAAC,EAAE,GAAG,kBAAkB,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC,GACpF,IACc,CACnB,CAAA;AACH,CAAC,CAAA"}
@@ -0,0 +1,3 @@
1
+ export declare const NotificationBox: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
2
+ export declare const StyledBackdrop: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").FastOmit<import("../Backdrop.js").BackdropProps, never>> & string & Omit<({ children, visible, onClose, className, actAs, persistent, animationMS, style }: import("../Backdrop.js").BackdropProps) => import("react").ReactPortal | null, keyof import("react").Component<any, {}, any>>;
3
+ //# sourceMappingURL=styled.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styled.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/styled.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,eAAe,wOA6B3B,CAAA;AAED,eAAO,MAAM,cAAc,+XAuC1B,CAAA"}
@@ -0,0 +1,74 @@
1
+ import { theme } from '@stack-spot/portal-theme';
2
+ import { styled } from 'styled-components';
3
+ import { Backdrop } from '../Backdrop.js';
4
+ export const NotificationBox = styled.div `
5
+ .notification-button {
6
+ border: none;
7
+ background: transparent;
8
+ margin: 0 40px;
9
+ position: relative;
10
+
11
+ &.loading {
12
+ cursor: progress;
13
+ opacity: 0.5;
14
+ }
15
+
16
+ &:before {
17
+ content: '';
18
+ position: absolute;
19
+ right: 9px;
20
+ top: 9px;
21
+ width: 12px;
22
+ height: 12px;
23
+ border-radius: 50%;
24
+ background-color: ${theme.color.danger['500']};
25
+ transform: scale(0);
26
+ transition: transform ease-in 0.3s;
27
+ }
28
+
29
+ &.unread:before {
30
+ transform: scale(1);
31
+ }
32
+ }
33
+ `;
34
+ export const StyledBackdrop = styled(Backdrop) `
35
+ position: absolute;
36
+ top: calc(var(--header-height) + 10px);
37
+ right: 60px;
38
+ box-shadow: 4px 4px 48px ${theme.color.danger.contrastText};
39
+
40
+ .notification-panel {
41
+ width: 400px;
42
+ padding: 16px;
43
+ border-radius: 4px;
44
+ background-color: ${theme.color.light[300]};
45
+ border: 1px solid ${theme.color.light[400]};
46
+ }
47
+
48
+ .filter-list {
49
+ list-style: none;
50
+ margin: 16px 0;
51
+ padding: 0;
52
+ display: flex;
53
+ flex-direction: row;
54
+ justify-content: space-between;
55
+ .filter-btn {
56
+ &:focus {
57
+ border-color: transparent;
58
+ }
59
+ &[aria-pressed="true"] {
60
+ border-color: ${theme.color.primary[500]};
61
+ }
62
+ }
63
+ }
64
+
65
+ .see-all {
66
+ margin-top: 8px;
67
+ width: 100%;
68
+ }
69
+
70
+ .error-feedback {
71
+ flex-direction: column;
72
+ }
73
+ `;
74
+ //# sourceMappingURL=styled.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styled.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/styled.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAA;AAChD,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAA;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AAEtC,MAAM,CAAC,MAAM,eAAe,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;0BAoBf,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;;;;;;;;;CASlD,CAAA;AAED,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAA;;;;6BAIjB,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,YAAY;;;;;;wBAMpC,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC;wBACtB,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;wBAetB,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC;;;;;;;;;;;;;CAa/C,CAAA"}
@@ -0,0 +1,21 @@
1
+ import { NotificationListProps } from '@stack-spot/portal-components/Notifications';
2
+ export type NotificationFilter = 'ALL' | 'UNREAD' | 'HIGH' | 'MEDIUM' | 'LOW';
3
+ export interface NotificationPanelProps extends Omit<NotificationListProps, 'compact' | 'onCommit' | 'onUncommit'> {
4
+ filter: NotificationFilter;
5
+ loading: boolean;
6
+ error: any;
7
+ onFilter: (filter: NotificationFilter) => Promise<void>;
8
+ visible: boolean;
9
+ onClose: () => void;
10
+ }
11
+ export interface NotificationPanelHeaderProps {
12
+ filter: NotificationFilter;
13
+ onChangeFilter: (value: NotificationFilter) => Promise<void>;
14
+ onClose: () => void;
15
+ }
16
+ export interface FilterButtonProps {
17
+ value: NotificationFilter;
18
+ current: NotificationFilter;
19
+ onChangeFilter: (value: NotificationFilter) => void;
20
+ }
21
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,MAAM,6CAA6C,CAAA;AAEnF,MAAM,MAAM,kBAAkB,GAAG,KAAK,GAAG,QAAQ,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,CAAA;AAE7E,MAAM,WAAW,sBAAuB,SAAQ,IAAI,CAAC,qBAAqB,EAAE,SAAS,GAAG,UAAU,GAAG,YAAY,CAAC;IAChH,MAAM,EAAE,kBAAkB,CAAC;IAC3B,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,EAAE,GAAG,CAAC;IACX,QAAQ,EAAE,CAAC,MAAM,EAAE,kBAAkB,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACxD,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,MAAM,WAAW,4BAA4B;IAC3C,MAAM,EAAE,kBAAkB,CAAC;IAC3B,cAAc,EAAE,CAAC,KAAK,EAAE,kBAAkB,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC7D,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,kBAAkB,CAAC;IAC1B,OAAO,EAAE,kBAAkB,CAAC;IAC5B,cAAc,EAAE,CAAC,KAAK,EAAE,kBAAkB,KAAK,IAAI,CAAC;CACrD"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/types.ts"],"names":[],"mappings":""}
@@ -0,0 +1,5 @@
1
+ import { LoadNotificationsFilters } from '@stack-spot/portal-components/Notifications';
2
+ import { NotificationFilter } from './types.js';
3
+ export declare function getFiltersFromName(filterName: NotificationFilter): LoadNotificationsFilters;
4
+ export declare function getNameFromFilters(filters: LoadNotificationsFilters): NotificationFilter;
5
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,6CAA6C,CAAA;AACtF,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAI5C,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,kBAAkB,GAAG,wBAAwB,CAQ3F;AAED,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,wBAAwB,GAAG,kBAAkB,CAIxF"}
@@ -0,0 +1,18 @@
1
+ const empty = { committed: undefined, context: undefined, criticality: undefined, search: undefined };
2
+ export function getFiltersFromName(filterName) {
3
+ switch (filterName) {
4
+ case 'ALL': return empty;
5
+ case 'HIGH': return { ...empty, criticality: 'HIGH' };
6
+ case 'LOW': return { ...empty, criticality: 'LOW' };
7
+ case 'MEDIUM': return { ...empty, criticality: 'MEDIUM' };
8
+ case 'UNREAD': return { ...empty, committed: false };
9
+ }
10
+ }
11
+ export function getNameFromFilters(filters) {
12
+ if (filters.committed === false)
13
+ return 'UNREAD';
14
+ if (filters.criticality)
15
+ return filters.criticality;
16
+ return 'ALL';
17
+ }
18
+ //# sourceMappingURL=utils.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/utils.ts"],"names":[],"mappings":"AAGA,MAAM,KAAK,GAA6B,EAAE,SAAS,EAAE,SAAS,EAAE,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,CAAA;AAE/H,MAAM,UAAU,kBAAkB,CAAC,UAA8B;IAC/D,QAAQ,UAAU,EAAE,CAAC;QACnB,KAAK,KAAK,CAAC,CAAC,OAAO,KAAK,CAAA;QACxB,KAAK,MAAM,CAAC,CAAC,OAAO,EAAE,GAAG,KAAK,EAAE,WAAW,EAAE,MAAM,EAAE,CAAA;QACrD,KAAK,KAAK,CAAC,CAAC,OAAO,EAAE,GAAG,KAAK,EAAE,WAAW,EAAE,KAAK,EAAE,CAAA;QACnD,KAAK,QAAQ,CAAC,CAAC,OAAO,EAAE,GAAG,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,CAAA;QACzD,KAAK,QAAQ,CAAC,CAAC,OAAO,EAAE,GAAG,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,CAAA;IACtD,CAAC;AACH,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,OAAiC;IAClE,IAAI,OAAO,CAAC,SAAS,KAAK,KAAK;QAAE,OAAO,QAAQ,CAAA;IAChD,IAAI,OAAO,CAAC,WAAW;QAAE,OAAO,OAAO,CAAC,WAAW,CAAA;IACnD,OAAO,KAAK,CAAA;AACd,CAAC"}
@@ -2,15 +2,41 @@ import { WithStyle } from '@stack-spot/portal-theme';
2
2
  import { ReactNode } from 'react';
3
3
  export declare const CLOSE_OVERLAY_ID = "close-overlay";
4
4
  export interface OverlayContentProps extends WithStyle {
5
+ /**
6
+ * The title for the modal or right panel.
7
+ */
5
8
  title: string;
9
+ /**
10
+ * The subtitle for the modal or right panel.
11
+ */
6
12
  subtitle?: string;
13
+ /**
14
+ * Function to call when the "go back" button is pressed. If unset, the button is not shown.
15
+ */
16
+ onGoBack?: () => void;
17
+ /**
18
+ * The content for the modal or right panel.
19
+ */
7
20
  children: ReactNode;
21
+ /**
22
+ * A function to run when the close button is pressed.
23
+ */
8
24
  onClose?: () => void;
9
25
  }
10
26
  interface Props extends OverlayContentProps {
27
+ /**
28
+ * A function to run when the close button is pressed.
29
+ */
11
30
  onClose: () => void;
31
+ /**
32
+ * Whether this is a modal or a right panel.
33
+ */
12
34
  type: 'modal' | 'panel';
13
35
  }
14
- export declare const OverlayContent: ({ children, title, subtitle, className, style, onClose, type }: Props) => import("react/jsx-runtime").JSX.Element;
36
+ /**
37
+ * Renders a modal or right panel with title, subtitle, close button and content.
38
+ * @param props the React props for the component {@link Props}.
39
+ */
40
+ export declare const OverlayContent: ({ children, title, subtitle, className, style, onClose, onGoBack, type }: Props) => import("react/jsx-runtime").JSX.Element;
15
41
  export {};
16
42
  //# sourceMappingURL=OverlayContent.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"OverlayContent.d.ts","sourceRoot":"","sources":["../../src/components/OverlayContent.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,SAAS,EAAsB,MAAM,0BAA0B,CAAA;AACxE,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAIjC,eAAO,MAAM,gBAAgB,kBAAkB,CAAA;AAE/C,MAAM,WAAW,mBAAoB,SAAQ,SAAS;IACpD,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,SAAS,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,UAAU,KAAM,SAAQ,mBAAmB;IACzC,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC;CACzB;AAuBD,eAAO,MAAM,cAAc,mEAAoE,KAAK,4CAcnG,CAAA"}
1
+ {"version":3,"file":"OverlayContent.d.ts","sourceRoot":"","sources":["../../src/components/OverlayContent.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,SAAS,EAAsB,MAAM,0BAA0B,CAAA;AACxE,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAIjC,eAAO,MAAM,gBAAgB,kBAAkB,CAAA;AAE/C,MAAM,WAAW,mBAAoB,SAAQ,SAAS;IACpD;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;IACpB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,UAAU,KAAM,SAAQ,mBAAmB;IACzC;;OAEG;IACH,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB;;OAEG;IACH,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC;CACzB;AAuBD;;;GAGG;AACH,eAAO,MAAM,cAAc,GAAI,0EAA0E,KAAK,4CAuB7G,CAAA"}
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { Flex, Text } from '@citric/core';
3
- import { TimesMini } from '@citric/icons';
3
+ import { ArrowLeft, TimesMini } from '@citric/icons';
4
4
  import { IconButton } from '@citric/ui';
5
5
  import { listToClass, theme } from '@stack-spot/portal-theme';
6
6
  import { styled } from 'styled-components';
@@ -20,14 +20,18 @@ const ContentBox = styled.section `
20
20
  flex-direction: column;
21
21
  flex: 1;
22
22
  }
23
- header {
23
+ > header {
24
24
  display: flex;
25
25
  flex-direction: row;
26
26
  margin-bottom: 1.25rem;
27
27
  }
28
28
  `;
29
- export const OverlayContent = ({ children, title, subtitle, className, style, onClose, type }) => {
29
+ /**
30
+ * Renders a modal or right panel with title, subtitle, close button and content.
31
+ * @param props the React props for the component {@link Props}.
32
+ */
33
+ export const OverlayContent = ({ children, title, subtitle, className, style, onClose, onGoBack, type }) => {
30
34
  const t = useDictionary();
31
- return (_jsxs(ContentBox, { style: style, className: listToClass([className, type]), children: [_jsxs("header", { children: [_jsxs(Flex, { flexDirection: "column", flex: 1, children: [_jsx(Text, { as: "h2", appearance: type === 'modal' ? 'h3' : 'h4', children: title }), subtitle && _jsx(Text, { appearance: "body2", colorScheme: "light.700", children: subtitle })] }), _jsx(IconButton, { onClick: onClose, title: t.close, "aria-label": t.close, id: CLOSE_OVERLAY_ID, children: _jsx(TimesMini, {}) })] }), children] }));
35
+ return (_jsxs(ContentBox, { style: style, className: listToClass([className, type]), children: [_jsxs("header", { children: [_jsxs(Flex, { flexDirection: "column", flex: 1, children: [_jsxs(Flex, { style: { gap: '6px' }, children: [onGoBack && (_jsx(IconButton, { appearance: "circle", onClick: onGoBack, title: t.goBack, "aria-label": t.goBack, children: _jsx(ArrowLeft, {}) })), _jsx(Text, { as: "h1", appearance: type === 'modal' ? 'h3' : 'h4', children: title })] }), subtitle && _jsx(Text, { appearance: "body2", colorScheme: "light.700", children: subtitle })] }), _jsx(IconButton, { appearance: "circle", onClick: onClose, title: t.close, "aria-label": t.close, id: CLOSE_OVERLAY_ID, children: _jsx(TimesMini, {}) })] }), children] }));
32
36
  };
33
37
  //# sourceMappingURL=OverlayContent.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"OverlayContent.js","sourceRoot":"","sources":["../../src/components/OverlayContent.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AACzC,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AACvC,OAAO,EAAa,WAAW,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAA;AAExE,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAA;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAA;AAE7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,eAAe,CAAA;AAc/C,MAAM,UAAU,GAAG,MAAM,CAAC,OAAO,CAAA;;;;sBAIX,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC;;;;;;;;;;;;;;;CAe7C,CAAA;AAED,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,EAAS,EAAE,EAAE;IACtG,MAAM,CAAC,GAAG,aAAa,EAAE,CAAA;IACzB,OAAO,CACL,MAAC,UAAU,IAAC,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,WAAW,CAAC,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC,aACjE,6BACE,MAAC,IAAI,IAAC,aAAa,EAAC,QAAQ,E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AAE,IAAI,EAAS,EAAE,EAAE;IAChH,MAAM,CAAC,GAAG,aAAa,EAAE,CAAA;IACzB,OAAO,CACL,MAAC,UAAU,IAAC,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,WAAW,CAAC,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC,aACjE,6BACE,MAAC,IAAI,IAAC,aAAa,EAAC,QAAQ,EAAC,IAAI,EAAE,CAAC,aAClC,MAAC,IAAI,IAAC,KAAK,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE,aACxB,QAAQ,IAAI,CACX,KAAC,UAAU,IAAC,UAAU,EAAC,QAAQ,EAAC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC,CAAC,MAAM,gBAAc,CAAC,CAAC,MAAM,YACtF,KAAC,SAAS,KAAG,GACF,CACd,EACD,KAAC,IAAI,IAAC,EAAE,EAAC,IAAI,EAAC,UAAU,EAAE,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,YAAG,KAAK,GAAQ,IACnE,EACN,QAAQ,IAAI,KAAC,IAAI,IAAC,UAAU,EAAC,OAAO,EAAC,WAAW,EAAC,WAAW,YAAE,QAAQ,GAAQ,IAC1E,EACP,KAAC,UAAU,IAAC,UAAU,EAAC,QAAQ,EAAC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC,CAAC,KAAK,gBAAc,CAAC,CAAC,KAAK,EAAE,EAAE,EAAE,gBAAgB,YACzG,KAAC,SAAS,KAAG,GACF,IACN,EACR,QAAQ,IACE,CACd,CAAA;AACH,CAAC,CAAA"}
@@ -1,10 +1,28 @@
1
- import { PortalAcronym } from './types.js';
1
+ import { PortalAcronym } from '../types.js';
2
2
  export interface Portal {
3
+ /**
4
+ * A Stackspot Portal.
5
+ */
3
6
  acronym: PortalAcronym;
7
+ /**
8
+ * The URL to the Stackspot Portal.
9
+ */
4
10
  url: string;
11
+ /**
12
+ * Show portal on List
13
+ */
14
+ showOnList?: boolean;
5
15
  }
6
16
  export interface PortalSwitcherProps {
17
+ /**
18
+ * The Stackspot portals to show in the selector.
19
+ */
7
20
  portals?: Portal[];
8
21
  }
22
+ /**
23
+ * A selector with different Stackspot portals.
24
+ * Each item contains a logo with a link to the portal.
25
+ * @param props the component Props {@link PortalSwitcherProps}.
26
+ */
9
27
  export declare const PortalSwitcher: ({ portals }: PortalSwitcherProps) => import("react/jsx-runtime").JSX.Element;
10
28
  //# sourceMappingURL=PortalSwitcher.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PortalSwitcher.d.ts","sourceRoot":"","sources":["../../src/components/PortalSwitcher.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AASvC,MAAM,WAAW,MAAM;IAAG,OAAO,EAAE,aAAa,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE;AAE/D,MAAM,WAAW,mBAAmB;IAClC,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;CACpB;AA0DD,eAAO,MAAM,cAAc,gBAAsB,mBAAmB,4CA8CnE,CAAA"}
1
+ {"version":3,"file":"PortalSwitcher.d.ts","sourceRoot":"","sources":["../../src/components/PortalSwitcher.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AAUxC,MAAM,WAAW,MAAM;IACrB;;OAEG;IACH,OAAO,EAAE,aAAa,CAAC;IACvB;;OAEG;IACH,GAAG,EAAE,MAAM,CAAC;IACZ;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;CACpB;AA0DD;;;;GAIG;AACH,eAAO,MAAM,cAAc,GAAI,aAAkB,mBAAmB,4CAwCnE,CAAA"}
@@ -1,19 +1,17 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Button, Flex, IconBox, Text } from '@citric/core';
2
+ import { Button, Flex, IconBox } from '@citric/core';
3
3
  import { ArrowRight, CheckCircleFill, Select } from '@citric/icons';
4
+ import { SelectionList } from '@stack-spot/portal-components/SelectionList';
5
+ import { AI, CS, EDP, HUB, Logo } from '@stack-spot/portal-components/svg';
4
6
  import { theme } from '@stack-spot/portal-theme';
5
- import { useTranslate } from '@stack-spot/portal-translate';
6
7
  import { useState } from 'react';
7
8
  import styled from 'styled-components';
8
- import { SelectionList, announce } from '../index.js';
9
- import { AI } from '../svg/AI.js';
10
- import { EDP } from '../svg/EDP.js';
11
- import { HUB } from '../svg/HUB.js';
12
- import { Logo } from '../svg/Logo.js';
13
9
  const Logos = {
14
10
  'AI': _jsx(AI, {}),
15
11
  'EDP': _jsx(EDP, {}),
16
12
  'HUB': _jsx(HUB, {}),
13
+ 'CS': _jsx(CS, {}),
14
+ 'ACCOUNT': _jsx(Logo, {}),
17
15
  };
18
16
  const PortalSwitcherBox = styled(Flex) `
19
17
  flex-direction: column;
@@ -48,7 +46,6 @@ const PortalSwitcherBox = styled(Flex) `
48
46
  }
49
47
 
50
48
  .action {
51
- padding: 16px;
52
49
  background-color: ${theme.color.light['400']};
53
50
  border-width: 1px;
54
51
  border-style: solid;
@@ -60,6 +57,7 @@ const PortalSwitcherBox = styled(Flex) `
60
57
  }
61
58
 
62
59
  a {
60
+ padding: 16px;
63
61
  height: auto;
64
62
  transition: unset;
65
63
  align-items: flex-start;
@@ -70,41 +68,28 @@ const PortalSwitcherBox = styled(Flex) `
70
68
 
71
69
  `;
72
70
  const PORTAL_SWITCHER_ID = 'PortalSwitcher';
71
+ /**
72
+ * A selector with different Stackspot portals.
73
+ * Each item contains a logo with a link to the portal.
74
+ * @param props the component Props {@link PortalSwitcherProps}.
75
+ */
73
76
  export const PortalSwitcher = ({ portals = [] }) => {
74
77
  const [visible, setVisible] = useState(false);
75
- const t = useTranslate(translations);
76
78
  const currentPortal = portals?.find(portal => location.href.startsWith(portal.url));
77
79
  return _jsxs(PortalSwitcherBox, { children: [currentPortal ?
78
- _jsx(Button, { className: "current-portal", appearance: "text", colorScheme: "light", "aria-controls": PORTAL_SWITCHER_ID, "aria-expanded": visible, "aria-label": `${t.portalSwitcher}: ${currentPortal?.acronym} ${t.selected}`, onClick: () => {
79
- setVisible(true);
80
- announce(`${t.portalSwitcher} ${t.selected}`);
80
+ _jsx(Button, { className: "current-portal", appearance: "text", colorScheme: "light", "aria-controls": PORTAL_SWITCHER_ID, "aria-expanded": visible, onClick: () => {
81
+ setVisible(!visible);
81
82
  }, children: _jsxs(Flex, { alignItems: "center", className: "portal-switcher", children: [Logos[currentPortal.acronym], _jsx(IconBox, { size: "xs", ml: 3, children: _jsx(Select, {}) })] }) }) :
82
- _jsx(Logo, {}), _jsx(SelectionList, { id: PORTAL_SWITCHER_ID, items: portals?.map(portal => ({
83
+ _jsx(Logo, {}), _jsx(SelectionList, { id: PORTAL_SWITCHER_ID, items: portals?.filter((portal) => portal.showOnList !== false).map(portal => ({
83
84
  label: {
84
85
  id: portal.acronym,
85
- element: _jsxs(Flex, { flexDirection: "column", children: [Logos[portal.acronym], _jsx(Text, { appearance: "microtext1", mt: 3, colorScheme: "light.700", children: t[portal.acronym] })] }),
86
+ element: _jsx(Flex, { w: "250px", children: Logos[portal.acronym] }),
86
87
  },
87
88
  target: '_self',
88
89
  href: portal.url,
89
90
  active: currentPortal?.acronym == portal.acronym,
90
- iconActive: _jsx(CheckCircleFill, { "aria-label": t.selected }),
91
+ iconActive: _jsx(CheckCircleFill, {}),
91
92
  iconRight: portal.acronym !== currentPortal?.acronym ? _jsx(ArrowRight, {}) : undefined,
92
93
  })), visible: visible, maxHeight: "21rem", onHide: () => setVisible(false) })] });
93
94
  };
94
- const translations = {
95
- en: {
96
- EDP: 'Efficient and secure solutions from code to production deployment.',
97
- AI: 'Speed up coding with efficient suggestions and high-quality results.',
98
- HUB: 'Discover AI Stacks, knowledge sources, and quick commands, all in one streamlined hub.',
99
- portalSwitcher: 'Portal switcher',
100
- selected: 'selected',
101
- },
102
- pt: {
103
- EDP: 'Soluções eficientes e seguras do código até a implantação em produção.',
104
- AI: 'Acelere o desenvolvimento com sugestões eficientes e resultados de alta qualidade.',
105
- HUB: 'Descubra AI Stacks, knownledge sources e quick commands, tudo em um hub simplificado.',
106
- portalSwitcher: 'Seletor de portais',
107
- selected: 'selecionado',
108
- },
109
- };
110
95
  //# sourceMappingURL=PortalSwitcher.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PortalSwitcher.js","sourceRoot":"","sources":["../../src/components/PortalSwitcher.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AAC1D,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AACnE,OAAO,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAA;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EAAa,QAAQ,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,MAAM,MAAM,mBAAmB,CAAA;AACtC,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAA;AAC5C,OAAO,EAAE,EAAE,EAAE,MAAM,WAAW,CAAA;AAC9B,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAA;AAChC,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAA;AAChC,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAIlC,MAAM,KAAK,GAAqC;IAC9C,IAAI,EAAE,KAAC,EAAE,KAAG;IACZ,KAAK,EAAE,KAAC,GAAG,KAAG;IACd,KAAK,EAAE,KAAC,GAAG,KAAG;CACf,CAAA;AAQD,MAAM,iBAAiB,GAAG,MAAM,CAAC,IAAI,CAAC,CAAA;;;;;;;;;;0BAUZ,KAAK,CAAC,KAAK,CAAC,KA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AAE,KAAC,IAAI,IAAC,CAAC,EAAC,OAAO,YAAE,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,GAAQ;qBACxD;oBACD,MAAM,EAAE,OAAO;oBACf,IAAI,EAAE,MAAM,CAAC,GAAG;oBAChB,MAAM,EAAE,aAAa,EAAE,OAAO,IAAI,MAAM,CAAC,OAAO;oBAChD,UAAU,EAAE,KAAC,eAAe,KAAG;oBAC/B,SAAS,EAAE,MAAM,CAAC,OAAO,KAAK,aAAa,EAAE,OAAO,CAAC,CAAC,CAAC,KAAC,UAAU,KAAG,CAAC,CAAC,CAAC,SAAS;iBAClF,CAAC,CAAC,EACH,OAAO,EAAE,OAAO,EAChB,SAAS,EAAC,OAAO,EACjB,MAAM,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,GAAI,IAClB,CAAA;AACvB,CAAC,CAAA"}
@@ -0,0 +1,10 @@
1
+ import { PrivacyPolicyMessageProps } from './index.js';
2
+ interface PrivacyPolicyProps extends PrivacyPolicyMessageProps {
3
+ policy?: string;
4
+ policyValue?: string;
5
+ domain?: string;
6
+ confirmText?: string;
7
+ }
8
+ export declare function usePrivacyPolicyEffect({ policy, policyValue, domain, privacyPoliceUrl, message, policyText, confirmText, }: PrivacyPolicyProps): void;
9
+ export {};
10
+ //# sourceMappingURL=hooks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../../src/components/PrivacyPolicyMessage/hooks.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAwB,yBAAyB,EAAE,MAAM,GAAG,CAAA;AAEnE,UAAU,kBAAmB,SAAQ,yBAAyB;IAC5D,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,wBAAgB,sBAAsB,CAAC,EACrC,MAAoB,EACpB,WAAoB,EACpB,MAAyB,EACzB,gBAAgB,EAChB,OAAO,EACP,UAAU,EACV,WAAW,GACZ,EAAE,kBAAkB,QAmBpB"}
@@ -0,0 +1,33 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { useTranslate } from '@stack-spot/portal-translate';
3
+ import { useEffect, useState } from 'react';
4
+ import { overlay } from '../../LayoutOverlayManager.js';
5
+ import { PrivacyPolicyMessage } from './index.js';
6
+ export function usePrivacyPolicyEffect({ policy = 'okCookies', policyValue = 'true', domain = '.stackspot.com', privacyPoliceUrl, message, policyText, confirmText, }) {
7
+ const t = useTranslate(dictionary);
8
+ const [visible, setVisible] = useState(!document.cookie.match(new RegExp(`${policy}=([^;]+)`))?.[1]);
9
+ async function checkPolicy() {
10
+ if (visible) {
11
+ await overlay.showBottomDialog({
12
+ confirm: confirmText || t.ok,
13
+ children: _jsx(PrivacyPolicyMessage, { privacyPoliceUrl: privacyPoliceUrl, message: message, policyText: policyText }),
14
+ });
15
+ document.cookie = `${policy}=${policyValue};path=/${location.host.endsWith(domain) ? `;domain=${domain}` : ''}`;
16
+ setVisible(false);
17
+ }
18
+ else
19
+ overlay.closeBottomDialog();
20
+ }
21
+ useEffect(() => {
22
+ checkPolicy();
23
+ }, [visible]);
24
+ }
25
+ const dictionary = {
26
+ en: {
27
+ ok: 'Ok',
28
+ },
29
+ pt: {
30
+ ok: 'Ok',
31
+ },
32
+ };
33
+ //# sourceMappingURL=hooks.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hooks.js","sourceRoot":"","sources":["../../../src/components/PrivacyPolicyMessage/hooks.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAc,YAAY,EAAE,MAAM,8BAA8B,CAAA;AACvE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AACpD,OAAO,EAAE,oBAAoB,EAA6B,MAAM,GAAG,CAAA;AASnE,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yPolicyMessageProps {
2
+ message: string;
3
+ policyText?: string;
4
+ privacyPoliceUrl?: string;
5
+ }
6
+ export declare const PrivacyPolicyMessage: ({ message, policyText, privacyPoliceUrl }: PrivacyPolicyMessageProps) => import("react/jsx-runtime").JSX.Element;
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/PrivacyPolicyMessage/index.tsx"],"names":[],"mappings":"AAGA,MAAM,WAAW,yBAAyB;IACxC,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,eAAO,MAAM,oBAAoB,GAAI,2CAA2C,yBAAyB,4CAUtG,CAAA"}
@@ -0,0 +1,5 @@
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import { IconBox, Link, Text } from '@citric/core';
3
+ import { Cookie } from '@citric/icons';
4
+ export const PrivacyPolicyMessage = ({ message, policyText, privacyPoliceUrl }) => _jsxs(_Fragment, { children: [_jsx(IconBox, { size: "md", colorIcon: "inverse", children: _jsx(Cookie, {}) }), _jsxs(Text, { children: [message, privacyPoliceUrl && _jsx(Link, { colorScheme: "inverse.contrastText", weight: "bold", href: privacyPoliceUrl, target: "_blank", children: policyText })] })] });
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/PrivacyPolicyMessage/index.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AAClD,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAQtC,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,EAAE,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAA6B,EAAE,EAAE,CAAC,8BAC5G,KAAC,OAAO,IAAC,IAAI,EAAC,IAAI,EAAC,SAAS,EAAC,SAAS,YACpC,KAAC,MAAM,KAAG,GACF,EACV,MAAC,IAAI,eACF,OAAO,EACP,gBAAgB,IAAI,KAAC,IAAI,IAAC,WAAW,EAAC,sBAAsB,EAAC,MAAM,EAAC,MAAM,EAAC,IAAI,EAAE,gBAAgB,EAAE,MAAM,EAAC,QAAQ,YAChH,UAAU,GACN,IACF,IACN,CAAA"}