@selfcommunity/react-core 0.1.2-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (285) hide show
  1. package/LICENSE.md +21 -0
  2. package/README.md +13 -0
  3. package/lib/cjs/components/provider/SCAlertMessagesProvider/index.js +67 -0
  4. package/lib/cjs/components/provider/SCContextProvider/index.js +117 -0
  5. package/lib/cjs/components/provider/SCLocaleProvider/index.js +158 -0
  6. package/lib/cjs/components/provider/SCNotificationProvider/index.js +73 -0
  7. package/lib/cjs/components/provider/SCPreferencesProvider/index.js +93 -0
  8. package/lib/cjs/components/provider/SCRoutingProvider/index.js +146 -0
  9. package/lib/cjs/components/provider/SCThemeProvider/index.js +123 -0
  10. package/lib/cjs/components/provider/SCUserProvider/index.js +310 -0
  11. package/lib/cjs/components/router/index.js +91 -0
  12. package/lib/cjs/constants/Actions.js +6 -0
  13. package/lib/cjs/constants/ContextProviders.js +29 -0
  14. package/lib/cjs/constants/Device.js +11 -0
  15. package/lib/cjs/constants/Errors.js +10 -0
  16. package/lib/cjs/constants/Features.js +84 -0
  17. package/lib/cjs/constants/Locale.js +19 -0
  18. package/lib/cjs/constants/Notification.js +67 -0
  19. package/lib/cjs/constants/Notifications.js +27 -0
  20. package/lib/cjs/constants/Preferences.js +344 -0
  21. package/lib/cjs/constants/Routes.js +68 -0
  22. package/lib/cjs/constants/Session.js +22 -0
  23. package/lib/cjs/constants/Theme.js +6 -0
  24. package/lib/cjs/constants/WebSocket.js +10 -0
  25. package/lib/cjs/hooks/useSCAuth.js +340 -0
  26. package/lib/cjs/hooks/useSCCachingManager.js +58 -0
  27. package/lib/cjs/hooks/useSCConnectionsManager.js +285 -0
  28. package/lib/cjs/hooks/useSCFetchCategories.js +71 -0
  29. package/lib/cjs/hooks/useSCFetchCategory.js +68 -0
  30. package/lib/cjs/hooks/useSCFetchCommentObject.js +68 -0
  31. package/lib/cjs/hooks/useSCFetchCommentObjects.js +296 -0
  32. package/lib/cjs/hooks/useSCFetchCustomAdv.js +84 -0
  33. package/lib/cjs/hooks/useSCFetchFeedObject.js +79 -0
  34. package/lib/cjs/hooks/useSCFetchIncubator.js +68 -0
  35. package/lib/cjs/hooks/useSCFetchTag.js +68 -0
  36. package/lib/cjs/hooks/useSCFetchUser.js +68 -0
  37. package/lib/cjs/hooks/useSCFollowedCategoriesManager.js +162 -0
  38. package/lib/cjs/hooks/useSCFollowersManager.js +232 -0
  39. package/lib/cjs/hooks/useSCMediaClick.js +27 -0
  40. package/lib/cjs/hooks/useSCSubscribedIncubatorsManager.js +165 -0
  41. package/lib/cjs/hooks/useSCWebPushMessaging.js +286 -0
  42. package/lib/cjs/hooks/useSCWebSocket.js +120 -0
  43. package/lib/cjs/index.js +169 -0
  44. package/lib/cjs/scss/styles.scss +1 -0
  45. package/lib/cjs/themes/theme.js +165 -0
  46. package/lib/cjs/types/context.js +3 -0
  47. package/lib/cjs/types/index.js +22 -0
  48. package/lib/cjs/utils/errors.js +196 -0
  49. package/lib/cjs/utils/locale.js +56 -0
  50. package/lib/cjs/utils/logger.js +32 -0
  51. package/lib/cjs/utils/object.js +44 -0
  52. package/lib/cjs/utils/session.js +17 -0
  53. package/lib/cjs/utils/string.js +57 -0
  54. package/lib/cjs/utils/url.js +70 -0
  55. package/lib/cjs/utils/user.js +83 -0
  56. package/lib/cjs/utils/validator.js +771 -0
  57. package/lib/cjs/utils/webPushMessaging.js +110 -0
  58. package/lib/cjs/utils/websocket.js +307 -0
  59. package/lib/esm/api-services/src/client/index.d.ts +115 -0
  60. package/lib/esm/api-services/src/client/index.d.ts.map +1 -0
  61. package/lib/esm/api-services/src/constants/Endpoints.d.ts +10 -0
  62. package/lib/esm/api-services/src/constants/Endpoints.d.ts.map +1 -0
  63. package/lib/esm/api-services/src/index.d.ts +24 -0
  64. package/lib/esm/api-services/src/index.d.ts.map +1 -0
  65. package/lib/esm/api-services/src/services/category/index.d.ts +13 -0
  66. package/lib/esm/api-services/src/services/category/index.d.ts.map +1 -0
  67. package/lib/esm/api-services/src/services/feature/index.d.ts +10 -0
  68. package/lib/esm/api-services/src/services/feature/index.d.ts.map +1 -0
  69. package/lib/esm/api-services/src/services/preference/index.d.ts +16 -0
  70. package/lib/esm/api-services/src/services/preference/index.d.ts.map +1 -0
  71. package/lib/esm/api-services/src/services/user/index.d.ts +16 -0
  72. package/lib/esm/api-services/src/services/user/index.d.ts.map +1 -0
  73. package/lib/esm/api-services/src/utils/http.d.ts +6 -0
  74. package/lib/esm/api-services/src/utils/http.d.ts.map +1 -0
  75. package/lib/esm/api-services/src/utils/token.d.ts +16 -0
  76. package/lib/esm/api-services/src/utils/token.d.ts.map +1 -0
  77. package/lib/esm/components/provider/SCAlertMessagesProvider/index.js +67 -0
  78. package/lib/esm/components/provider/SCContextProvider/index.js +117 -0
  79. package/lib/esm/components/provider/SCLocaleProvider/index.js +158 -0
  80. package/lib/esm/components/provider/SCNotificationProvider/index.js +73 -0
  81. package/lib/esm/components/provider/SCPreferencesProvider/index.js +93 -0
  82. package/lib/esm/components/provider/SCRoutingProvider/index.js +146 -0
  83. package/lib/esm/components/provider/SCThemeProvider/index.js +123 -0
  84. package/lib/esm/components/provider/SCUserProvider/index.js +310 -0
  85. package/lib/esm/components/router/index.js +91 -0
  86. package/lib/esm/constants/Actions.js +6 -0
  87. package/lib/esm/constants/ContextProviders.js +29 -0
  88. package/lib/esm/constants/Device.js +11 -0
  89. package/lib/esm/constants/Errors.js +10 -0
  90. package/lib/esm/constants/Features.js +84 -0
  91. package/lib/esm/constants/Locale.js +19 -0
  92. package/lib/esm/constants/Notification.js +67 -0
  93. package/lib/esm/constants/Notifications.js +27 -0
  94. package/lib/esm/constants/Preferences.js +344 -0
  95. package/lib/esm/constants/Routes.js +68 -0
  96. package/lib/esm/constants/Session.js +22 -0
  97. package/lib/esm/constants/Theme.js +6 -0
  98. package/lib/esm/constants/WebSocket.js +10 -0
  99. package/lib/esm/hooks/useSCAuth.js +340 -0
  100. package/lib/esm/hooks/useSCCachingManager.js +58 -0
  101. package/lib/esm/hooks/useSCConnectionsManager.js +285 -0
  102. package/lib/esm/hooks/useSCFetchCategories.js +71 -0
  103. package/lib/esm/hooks/useSCFetchCategory.js +68 -0
  104. package/lib/esm/hooks/useSCFetchCommentObject.js +68 -0
  105. package/lib/esm/hooks/useSCFetchCommentObjects.js +296 -0
  106. package/lib/esm/hooks/useSCFetchCustomAdv.js +84 -0
  107. package/lib/esm/hooks/useSCFetchFeedObject.js +79 -0
  108. package/lib/esm/hooks/useSCFetchIncubator.js +68 -0
  109. package/lib/esm/hooks/useSCFetchTag.js +68 -0
  110. package/lib/esm/hooks/useSCFetchUser.js +68 -0
  111. package/lib/esm/hooks/useSCFollowedCategoriesManager.js +162 -0
  112. package/lib/esm/hooks/useSCFollowersManager.js +232 -0
  113. package/lib/esm/hooks/useSCMediaClick.js +27 -0
  114. package/lib/esm/hooks/useSCSubscribedIncubatorsManager.js +165 -0
  115. package/lib/esm/hooks/useSCWebPushMessaging.js +286 -0
  116. package/lib/esm/hooks/useSCWebSocket.js +120 -0
  117. package/lib/esm/index.js +169 -0
  118. package/lib/esm/react-core/src/components/provider/SCAlertMessagesProvider/index.d.ts +37 -0
  119. package/lib/esm/react-core/src/components/provider/SCAlertMessagesProvider/index.d.ts.map +1 -0
  120. package/lib/esm/react-core/src/components/provider/SCContextProvider/index.d.ts +35 -0
  121. package/lib/esm/react-core/src/components/provider/SCContextProvider/index.d.ts.map +1 -0
  122. package/lib/esm/react-core/src/components/provider/SCLocaleProvider/index.d.ts +42 -0
  123. package/lib/esm/react-core/src/components/provider/SCLocaleProvider/index.d.ts.map +1 -0
  124. package/lib/esm/react-core/src/components/provider/SCNotificationProvider/index.d.ts +37 -0
  125. package/lib/esm/react-core/src/components/provider/SCNotificationProvider/index.d.ts.map +1 -0
  126. package/lib/esm/react-core/src/components/provider/SCPreferencesProvider/index.d.ts +38 -0
  127. package/lib/esm/react-core/src/components/provider/SCPreferencesProvider/index.d.ts.map +1 -0
  128. package/lib/esm/react-core/src/components/provider/SCRoutingProvider/index.d.ts +39 -0
  129. package/lib/esm/react-core/src/components/provider/SCRoutingProvider/index.d.ts.map +1 -0
  130. package/lib/esm/react-core/src/components/provider/SCThemeProvider/index.d.ts +49 -0
  131. package/lib/esm/react-core/src/components/provider/SCThemeProvider/index.d.ts.map +1 -0
  132. package/lib/esm/react-core/src/components/provider/SCUserProvider/index.d.ts +38 -0
  133. package/lib/esm/react-core/src/components/provider/SCUserProvider/index.d.ts.map +1 -0
  134. package/lib/esm/react-core/src/components/router/index.d.ts +34 -0
  135. package/lib/esm/react-core/src/components/router/index.d.ts.map +1 -0
  136. package/lib/esm/react-core/src/constants/Actions.d.ts +2 -0
  137. package/lib/esm/react-core/src/constants/Actions.d.ts.map +1 -0
  138. package/lib/esm/react-core/src/constants/ContextProviders.d.ts +6 -0
  139. package/lib/esm/react-core/src/constants/ContextProviders.d.ts.map +1 -0
  140. package/lib/esm/react-core/src/constants/Device.d.ts +6 -0
  141. package/lib/esm/react-core/src/constants/Device.d.ts.map +1 -0
  142. package/lib/esm/react-core/src/constants/Errors.d.ts +5 -0
  143. package/lib/esm/react-core/src/constants/Errors.d.ts.map +1 -0
  144. package/lib/esm/react-core/src/constants/Features.d.ts +41 -0
  145. package/lib/esm/react-core/src/constants/Features.d.ts.map +1 -0
  146. package/lib/esm/react-core/src/constants/Locale.d.ts +8 -0
  147. package/lib/esm/react-core/src/constants/Locale.d.ts.map +1 -0
  148. package/lib/esm/react-core/src/constants/Notification.d.ts +55 -0
  149. package/lib/esm/react-core/src/constants/Notification.d.ts.map +1 -0
  150. package/lib/esm/react-core/src/constants/Notifications.d.ts +11 -0
  151. package/lib/esm/react-core/src/constants/Notifications.d.ts.map +1 -0
  152. package/lib/esm/react-core/src/constants/Routes.d.ts +29 -0
  153. package/lib/esm/react-core/src/constants/Routes.d.ts.map +1 -0
  154. package/lib/esm/react-core/src/constants/Session.d.ts +10 -0
  155. package/lib/esm/react-core/src/constants/Session.d.ts.map +1 -0
  156. package/lib/esm/react-core/src/constants/Theme.d.ts +2 -0
  157. package/lib/esm/react-core/src/constants/Theme.d.ts.map +1 -0
  158. package/lib/esm/react-core/src/hooks/useSCAuth.d.ts +56 -0
  159. package/lib/esm/react-core/src/hooks/useSCAuth.d.ts.map +1 -0
  160. package/lib/esm/react-core/src/hooks/useSCCachingManager.d.ts +19 -0
  161. package/lib/esm/react-core/src/hooks/useSCCachingManager.d.ts.map +1 -0
  162. package/lib/esm/react-core/src/hooks/useSCConnectionsManager.d.ts +40 -0
  163. package/lib/esm/react-core/src/hooks/useSCConnectionsManager.d.ts.map +1 -0
  164. package/lib/esm/react-core/src/hooks/useSCFetchCategories.d.ts +17 -0
  165. package/lib/esm/react-core/src/hooks/useSCFetchCategories.d.ts.map +1 -0
  166. package/lib/esm/react-core/src/hooks/useSCFetchCategory.d.ts +19 -0
  167. package/lib/esm/react-core/src/hooks/useSCFetchCategory.d.ts.map +1 -0
  168. package/lib/esm/react-core/src/hooks/useSCFetchCommentObject.d.ts +19 -0
  169. package/lib/esm/react-core/src/hooks/useSCFetchCommentObject.d.ts.map +1 -0
  170. package/lib/esm/react-core/src/hooks/useSCFetchCommentObjects.d.ts +54 -0
  171. package/lib/esm/react-core/src/hooks/useSCFetchCommentObjects.d.ts.map +1 -0
  172. package/lib/esm/react-core/src/hooks/useSCFetchCustomAdv.d.ts +19 -0
  173. package/lib/esm/react-core/src/hooks/useSCFetchCustomAdv.d.ts.map +1 -0
  174. package/lib/esm/react-core/src/hooks/useSCFetchFeedObject.d.ts +21 -0
  175. package/lib/esm/react-core/src/hooks/useSCFetchFeedObject.d.ts.map +1 -0
  176. package/lib/esm/react-core/src/hooks/useSCFetchIncubator.d.ts +19 -0
  177. package/lib/esm/react-core/src/hooks/useSCFetchIncubator.d.ts.map +1 -0
  178. package/lib/esm/react-core/src/hooks/useSCFetchTag.d.ts +19 -0
  179. package/lib/esm/react-core/src/hooks/useSCFetchTag.d.ts.map +1 -0
  180. package/lib/esm/react-core/src/hooks/useSCFetchUser.d.ts +19 -0
  181. package/lib/esm/react-core/src/hooks/useSCFetchUser.d.ts.map +1 -0
  182. package/lib/esm/react-core/src/hooks/useSCFollowedCategoriesManager.d.ts +37 -0
  183. package/lib/esm/react-core/src/hooks/useSCFollowedCategoriesManager.d.ts.map +1 -0
  184. package/lib/esm/react-core/src/hooks/useSCFollowersManager.d.ts +37 -0
  185. package/lib/esm/react-core/src/hooks/useSCFollowersManager.d.ts.map +1 -0
  186. package/lib/esm/react-core/src/hooks/useSCMediaClick.d.ts +4 -0
  187. package/lib/esm/react-core/src/hooks/useSCMediaClick.d.ts.map +1 -0
  188. package/lib/esm/react-core/src/hooks/useSCSubscribedIncubatorsManager.d.ts +27 -0
  189. package/lib/esm/react-core/src/hooks/useSCSubscribedIncubatorsManager.d.ts.map +1 -0
  190. package/lib/esm/react-core/src/hooks/useSCWebPushMessaging.d.ts +9 -0
  191. package/lib/esm/react-core/src/hooks/useSCWebPushMessaging.d.ts.map +1 -0
  192. package/lib/esm/react-core/src/hooks/useSCWebSocket.d.ts +12 -0
  193. package/lib/esm/react-core/src/hooks/useSCWebSocket.d.ts.map +1 -0
  194. package/lib/esm/react-core/src/index.d.ts +77 -0
  195. package/lib/esm/react-core/src/index.d.ts.map +1 -0
  196. package/lib/esm/react-core/src/types/context.d.ts +428 -0
  197. package/lib/esm/react-core/src/types/context.d.ts.map +1 -0
  198. package/lib/esm/react-core/src/types/index.d.ts +3 -0
  199. package/lib/esm/react-core/src/types/index.d.ts.map +1 -0
  200. package/lib/esm/react-core/src/utils/errors.d.ts +98 -0
  201. package/lib/esm/react-core/src/utils/errors.d.ts.map +1 -0
  202. package/lib/esm/react-core/src/utils/locale.d.ts +10 -0
  203. package/lib/esm/react-core/src/utils/locale.d.ts.map +1 -0
  204. package/lib/esm/react-core/src/utils/logger.d.ts +11 -0
  205. package/lib/esm/react-core/src/utils/logger.d.ts.map +1 -0
  206. package/lib/esm/react-core/src/utils/object.d.ts +13 -0
  207. package/lib/esm/react-core/src/utils/object.d.ts.map +1 -0
  208. package/lib/esm/react-core/src/utils/session.d.ts +6 -0
  209. package/lib/esm/react-core/src/utils/session.d.ts.map +1 -0
  210. package/lib/esm/react-core/src/utils/string.d.ts +21 -0
  211. package/lib/esm/react-core/src/utils/string.d.ts.map +1 -0
  212. package/lib/esm/react-core/src/utils/url.d.ts +22 -0
  213. package/lib/esm/react-core/src/utils/url.d.ts.map +1 -0
  214. package/lib/esm/react-core/src/utils/user.d.ts +41 -0
  215. package/lib/esm/react-core/src/utils/user.d.ts.map +1 -0
  216. package/lib/esm/react-core/src/utils/validator.d.ts +239 -0
  217. package/lib/esm/react-core/src/utils/validator.d.ts.map +1 -0
  218. package/lib/esm/react-core/src/utils/webPushMessaging.d.ts +14 -0
  219. package/lib/esm/react-core/src/utils/webPushMessaging.d.ts.map +1 -0
  220. package/lib/esm/react-core/src/utils/websocket.d.ts +177 -0
  221. package/lib/esm/react-core/src/utils/websocket.d.ts.map +1 -0
  222. package/lib/esm/react-i18n/src/index.d.ts +815 -0
  223. package/lib/esm/react-i18n/src/index.d.ts.map +1 -0
  224. package/lib/esm/scss/styles.scss +1 -0
  225. package/lib/esm/themes/theme.js +165 -0
  226. package/lib/esm/types/context.js +3 -0
  227. package/lib/esm/types/index.js +22 -0
  228. package/lib/esm/types/src/index.d.ts +9 -0
  229. package/lib/esm/types/src/index.d.ts.map +1 -0
  230. package/lib/esm/types/src/types/auth.d.ts +26 -0
  231. package/lib/esm/types/src/types/auth.d.ts.map +1 -0
  232. package/lib/esm/types/src/types/broadcastMessage.d.ts +73 -0
  233. package/lib/esm/types/src/types/broadcastMessage.d.ts.map +1 -0
  234. package/lib/esm/types/src/types/category.d.ts +100 -0
  235. package/lib/esm/types/src/types/category.d.ts.map +1 -0
  236. package/lib/esm/types/src/types/comment.d.ts +97 -0
  237. package/lib/esm/types/src/types/comment.d.ts.map +1 -0
  238. package/lib/esm/types/src/types/customAdv.d.ts +53 -0
  239. package/lib/esm/types/src/types/customAdv.d.ts.map +1 -0
  240. package/lib/esm/types/src/types/customNotification.d.ts +28 -0
  241. package/lib/esm/types/src/types/customNotification.d.ts.map +1 -0
  242. package/lib/esm/types/src/types/embed.d.ts +33 -0
  243. package/lib/esm/types/src/types/embed.d.ts.map +1 -0
  244. package/lib/esm/types/src/types/feed.d.ts +208 -0
  245. package/lib/esm/types/src/types/feed.d.ts.map +1 -0
  246. package/lib/esm/types/src/types/incubator.d.ts +53 -0
  247. package/lib/esm/types/src/types/incubator.d.ts.map +1 -0
  248. package/lib/esm/types/src/types/index.d.ts +22 -0
  249. package/lib/esm/types/src/types/index.d.ts.map +1 -0
  250. package/lib/esm/types/src/types/location.d.ts +61 -0
  251. package/lib/esm/types/src/types/location.d.ts.map +1 -0
  252. package/lib/esm/types/src/types/media.d.ts +52 -0
  253. package/lib/esm/types/src/types/media.d.ts.map +1 -0
  254. package/lib/esm/types/src/types/notification.d.ts +416 -0
  255. package/lib/esm/types/src/types/notification.d.ts.map +1 -0
  256. package/lib/esm/types/src/types/poll.d.ts +77 -0
  257. package/lib/esm/types/src/types/poll.d.ts.map +1 -0
  258. package/lib/esm/types/src/types/privateMessage.d.ts +109 -0
  259. package/lib/esm/types/src/types/privateMessage.d.ts.map +1 -0
  260. package/lib/esm/types/src/types/prize.d.ts +48 -0
  261. package/lib/esm/types/src/types/prize.d.ts.map +1 -0
  262. package/lib/esm/types/src/types/tag.d.ts +47 -0
  263. package/lib/esm/types/src/types/tag.d.ts.map +1 -0
  264. package/lib/esm/types/src/types/user.d.ts +227 -0
  265. package/lib/esm/types/src/types/user.d.ts.map +1 -0
  266. package/lib/esm/utils/errors.js +196 -0
  267. package/lib/esm/utils/locale.js +56 -0
  268. package/lib/esm/utils/logger.js +32 -0
  269. package/lib/esm/utils/object.js +44 -0
  270. package/lib/esm/utils/session.js +17 -0
  271. package/lib/esm/utils/src/index.d.ts +7 -0
  272. package/lib/esm/utils/src/index.d.ts.map +1 -0
  273. package/lib/esm/utils/src/utils/string.d.ts +21 -0
  274. package/lib/esm/utils/src/utils/string.d.ts.map +1 -0
  275. package/lib/esm/utils/src/utils/url.d.ts +22 -0
  276. package/lib/esm/utils/src/utils/url.d.ts.map +1 -0
  277. package/lib/esm/utils/string.js +57 -0
  278. package/lib/esm/utils/url.js +70 -0
  279. package/lib/esm/utils/user.js +83 -0
  280. package/lib/esm/utils/validator.js +771 -0
  281. package/lib/esm/utils/webPushMessaging.js +110 -0
  282. package/lib/esm/utils/websocket.js +307 -0
  283. package/lib/umd/react-core.js +2 -0
  284. package/lib/umd/react-core.js.LICENSE.txt +1 -0
  285. package/package.json +128 -0
@@ -0,0 +1,98 @@
1
+ /**
2
+ * Manage Validation Error
3
+ * Used to check the initial configurations
4
+ */
5
+ export declare class ValidationError {
6
+ static ERROR_INVALID_CONF: number;
7
+ static ERROR_INVALID_SESSION: number;
8
+ static ERROR_INVALID_SESSION_TYPE: number;
9
+ static ERROR_INVALID_SESSION_AUTH_TOKEN: number;
10
+ static ERROR_INVALID_SESSION_CLIENT_ID: number;
11
+ static ERROR_INVALID_SESSION_REFRESH_TOKEN_CALLBACK: number;
12
+ static ERROR_INVALID_PORTAL: number;
13
+ static ERROR_INVALID_LOCALE: number;
14
+ static ERROR_INVALID_TRANSLATIONS: number;
15
+ static ERROR_INVALID_THEME: number;
16
+ static ERROR_INVALID_ROUTER: number;
17
+ static ERROR_INVALID_PROVIDERS: number;
18
+ static ERROR_INVALID_HANDLE_ANONYMOUS_ACTION: number;
19
+ static ERROR_INVALID_NOTIFICATIONS: number;
20
+ static ERROR_INVALID_NOTIFICATIONS_WEBSOCKET: number;
21
+ static ERROR_INVALID_NOTIFICATIONS_WEBSOCKET_DISABLE_TOAST_MESSAGE: number;
22
+ static ERROR_INVALID_NOTIFICATIONS_WEB_PUSH_MESSAGING: number;
23
+ static ERROR_INVALID_NOTIFICATIONS_WEB_PUSH_MESSAGING_DISABLE_TOAST_MESSAGE: number;
24
+ static ERROR_INVALID_NOTIFICATIONS_WEB_PUSH_MESSAGING_APPLICATION_SERVER_KEY: number;
25
+ static defaultErrorMessageMap: {
26
+ [x: number]: string;
27
+ };
28
+ errorCode: any;
29
+ errorData: any;
30
+ errorMessage: any;
31
+ constructor(errorCode: any, errorData: any, errorMessage?: string);
32
+ }
33
+ /**
34
+ * Manage Validation Warnings
35
+ * Used to check the initial configurations
36
+ */
37
+ export declare class ValidationWarnings {
38
+ static WARNING_SESSION_REFRESH_TOKEN_CALLBACK_NOT_FOUND: number;
39
+ static WARNING_LOCALE_FALLBACK: number;
40
+ static WARNING_ROUTER_FALLBACK: number;
41
+ static WARNING_HANDLE_ANONYMOUS_ACTION_FALLBACK: number;
42
+ static defaultErrorMessageMap: {
43
+ [x: number]: string;
44
+ };
45
+ warningCode: any;
46
+ warningData: any;
47
+ warningMessage: any;
48
+ constructor(warningCode: any, warningData: any, warningMessage?: string);
49
+ }
50
+ /**
51
+ * /**
52
+ * Manage Validation Error/Warnings
53
+ * of the initial configuration
54
+ */
55
+ export declare class ValidationResult {
56
+ errors: any[];
57
+ warnings: any[];
58
+ scope: string;
59
+ constructor(scope?: string);
60
+ /**
61
+ * Add an error
62
+ * @param errorCode
63
+ * @param errorData
64
+ */
65
+ addError(errorCode: any, errorData: any): any[];
66
+ /**
67
+ * Add a warning
68
+ * @param errorCode
69
+ * @param errorData
70
+ */
71
+ addWarnings(warningCode: any, warningData: any): any[];
72
+ /**
73
+ * Check if contains errors
74
+ */
75
+ hasErrors(): boolean;
76
+ /**
77
+ * Check if contains warnings
78
+ */
79
+ hasWarnings(): boolean;
80
+ /**
81
+ * Emit in console all the errors
82
+ */
83
+ emitErrors(): void;
84
+ /**
85
+ * Emit in console all the warnings
86
+ */
87
+ emitWarnings(): void;
88
+ /**
89
+ * Emit in console errors/warnings
90
+ */
91
+ emit(): void;
92
+ }
93
+ /**
94
+ * Check if v is a func
95
+ * @param v
96
+ */
97
+ export declare function isFunc(v: any): boolean;
98
+ //# sourceMappingURL=errors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../../src/utils/errors.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,qBAAa,eAAe;IAC1B,MAAM,CAAC,kBAAkB,SAAQ;IACjC,MAAM,CAAC,qBAAqB,SAAQ;IACpC,MAAM,CAAC,0BAA0B,SAAQ;IACzC,MAAM,CAAC,gCAAgC,SAAQ;IAC/C,MAAM,CAAC,+BAA+B,SAAQ;IAC9C,MAAM,CAAC,4CAA4C,SAAQ;IAC3D,MAAM,CAAC,oBAAoB,SAAQ;IACnC,MAAM,CAAC,oBAAoB,SAAQ;IACnC,MAAM,CAAC,0BAA0B,SAAQ;IACzC,MAAM,CAAC,mBAAmB,SAAQ;IAClC,MAAM,CAAC,oBAAoB,SAAQ;IACnC,MAAM,CAAC,uBAAuB,SAAQ;IACtC,MAAM,CAAC,qCAAqC,SAAQ;IACpD,MAAM,CAAC,2BAA2B,SAAQ;IAC1C,MAAM,CAAC,qCAAqC,SAAQ;IACpD,MAAM,CAAC,2DAA2D,SAAQ;IAC1E,MAAM,CAAC,8CAA8C,SAAQ;IAC7D,MAAM,CAAC,oEAAoE,SAAQ;IACnF,MAAM,CAAC,qEAAqE,SAAQ;IACpF,MAAM,CAAC,sBAAsB;;MAwB3B;IAEF,SAAS,MAAQ;IACjB,SAAS,MAAQ;IACjB,YAAY,MAAQ;gBAER,SAAS,KAAA,EAAE,SAAS,KAAA,EAAE,YAAY,SAAoD;CAKnG;AAED;;;GAGG;AACH,qBAAa,kBAAkB;IAC7B,MAAM,CAAC,gDAAgD,SAAQ;IAC/D,MAAM,CAAC,uBAAuB,SAAQ;IACtC,MAAM,CAAC,uBAAuB,SAAQ;IACtC,MAAM,CAAC,wCAAwC,SAAQ;IAEvD,MAAM,CAAC,sBAAsB;;MAO3B;IAEF,WAAW,MAAQ;IACnB,WAAW,MAAQ;IACnB,cAAc,MAAQ;gBAEV,WAAW,KAAA,EAAE,WAAW,KAAA,EAAE,cAAc,SAAyD;CAK9G;AAED;;;;GAIG;AACH,qBAAa,gBAAgB;IAC3B,MAAM,QAAM;IACZ,QAAQ,QAAM;IACd,KAAK,SAAM;gBAEC,KAAK,SAAmB;IAIpC;;;;OAIG;IACH,QAAQ,CAAC,SAAS,KAAA,EAAE,SAAS,KAAA;IAK7B;;;;OAIG;IACH,WAAW,CAAC,WAAW,KAAA,EAAE,WAAW,KAAA;IAKpC;;OAEG;IACH,SAAS;IAIT;;OAEG;IACH,WAAW;IAIX;;OAEG;IACH,UAAU;IAMV;;OAEG;IACH,YAAY;IAMZ;;OAEG;IACH,IAAI;CAIL;AAED;;;GAGG;AACH,wBAAgB,MAAM,CAAC,CAAC,KAAA,WAEvB"}
@@ -0,0 +1,10 @@
1
+ import { createIntl } from 'react-intl';
2
+ /**
3
+ * Load Locale Data
4
+ */
5
+ export declare function loadLocaleData(locale: any, settings: any): {
6
+ messages: any;
7
+ locale: any;
8
+ };
9
+ export default createIntl;
10
+ //# sourceMappingURL=locale.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"locale.d.ts","sourceRoot":"","sources":["../../../../../src/utils/locale.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,UAAU,EAAC,MAAM,YAAY,CAAC;AAItC;;GAEG;AACH,wBAAgB,cAAc,CAAC,MAAM,KAAA,EAAE,QAAQ,KAAA;;;EAoB9C;AAED,eAAe,UAAU,CAAC"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Emit styled message
3
+ */
4
+ export declare class Logger {
5
+ static info(scope: any, message: any): void;
6
+ static warn(scope: any, message: any): void;
7
+ static error(scope: any, message: any): void;
8
+ static log(scope: any, message: any): void;
9
+ static debug(scope: any, message: any): void;
10
+ }
11
+ //# sourceMappingURL=logger.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../../../../../src/utils/logger.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,qBAAa,MAAM;IACjB,MAAM,CAAC,IAAI,CAAC,KAAK,KAAA,EAAE,OAAO,KAAA;IAI1B,MAAM,CAAC,IAAI,CAAC,KAAK,KAAA,EAAE,OAAO,KAAA;IAI1B,MAAM,CAAC,KAAK,CAAC,KAAK,KAAA,EAAE,OAAO,KAAA;IAI3B,MAAM,CAAC,GAAG,CAAC,KAAK,KAAA,EAAE,OAAO,KAAA;IAIzB,MAAM,CAAC,KAAK,CAAC,KAAK,KAAA,EAAE,OAAO,KAAA;CAG5B"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Check if v is an object
3
+ * @param v
4
+ */
5
+ export declare function isObject(v: any): boolean;
6
+ /**
7
+ * Perfrom deep merge of two objects (not a shallow merge)
8
+ * @param target
9
+ * @param source
10
+ * @return {*}
11
+ */
12
+ export declare function mergeDeep(target: object, source: object): object;
13
+ //# sourceMappingURL=object.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"object.d.ts","sourceRoot":"","sources":["../../../../../src/utils/object.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,CAAC,KAAA,WAEzB;AAED;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAgBhE"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Extract from a jwt token payload
3
+ * @param token
4
+ */
5
+ export declare function parseJwt(token: any): any;
6
+ //# sourceMappingURL=session.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"session.d.ts","sourceRoot":"","sources":["../../../../../src/utils/session.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,KAAK,KAAA,OAY7B"}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Check if v is a string
3
+ * @param v
4
+ */
5
+ export declare function isString(v: any): boolean;
6
+ /**
7
+ * Capitalize a string
8
+ * @param str
9
+ */
10
+ export declare function capitalize(str: string): string;
11
+ /**
12
+ * CamelCase a string
13
+ * @param str
14
+ */
15
+ export declare function camelCase(str: string): string;
16
+ /**
17
+ * Stripe html tags from a string
18
+ * @param str
19
+ */
20
+ export declare function stripHtml(str: string): string;
21
+ //# sourceMappingURL=string.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"string.d.ts","sourceRoot":"","sources":["../../../../../src/utils/string.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,CAAC,KAAA,WAEzB;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAO9C;AAED;;;GAGG;AACH,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAiB7C;AAED;;;GAGG;AACH,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAE7C"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Utility Url Replacer
3
+ * @param path
4
+ */
5
+ export declare const urlReplacer: (path: string) => (params: object) => any;
6
+ /**
7
+ * Get domain
8
+ * @param url
9
+ */
10
+ export declare const getDomain: (url: string) => string;
11
+ /**
12
+ * Check a str is a valid url pattern
13
+ * @param url
14
+ */
15
+ export declare const isValidUrl: (url: string) => boolean;
16
+ /**
17
+ * Check a str is a valid list of urls separated by delimiter
18
+ * @param value
19
+ * @param delimiter
20
+ */
21
+ export declare const isValidUrls: (value: string, delimiter: string) => boolean;
22
+ //# sourceMappingURL=url.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"url.d.ts","sourceRoot":"","sources":["../../../../../src/utils/url.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,eAAO,MAAM,WAAW,SAAU,MAAM,cAWtB,MAAM,QACvB,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,SAAS,QAAS,MAAM,KAAG,MAOvC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,UAAU,QAAS,MAAM,KAAG,OAGxC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,WAAW,UAAW,MAAM,aAAa,MAAM,KAAG,OAG9D,CAAC"}
@@ -0,0 +1,41 @@
1
+ import { SCUserType } from '@selfcommunity/types';
2
+ /**
3
+ * Staff Roles
4
+ * @type {string}
5
+ */
6
+ export declare const ADMIN_ROLE = "admin";
7
+ export declare const MODERATOR_ROLE = "moderator";
8
+ /**
9
+ * Get user role from roles(set)
10
+ * @param user
11
+ * @returns role or null
12
+ */
13
+ export declare function getUserRole(user: SCUserType): string | null;
14
+ /**
15
+ * Check if user is admin
16
+ * @param user
17
+ * @returns boolean
18
+ */
19
+ export declare function isAdmin(user: SCUserType): boolean;
20
+ /**
21
+ * Check if user is moderator
22
+ * @param user
23
+ * @returns boolean
24
+ */
25
+ export declare function isModerator(user: SCUserType): boolean;
26
+ /**
27
+ * Check if user is admin or moderator
28
+ * @param user
29
+ * @returns boolean
30
+ */
31
+ export declare function isStaff(user: SCUserType): boolean;
32
+ /**
33
+ * Check if user is blocked/banned
34
+ * User status values:
35
+ * a (approved), b (blocked), d (deleted; soft deleted),
36
+ * u (unregistered; hard deleted). Default: a.
37
+ * @param user
38
+ * @returns {*}
39
+ */
40
+ export declare function isBlocked(user: SCUserType): boolean;
41
+ //# sourceMappingURL=user.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../../../src/utils/user.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,UAAU,EAAC,MAAM,sBAAsB,CAAC;AAE9D;;;GAGG;AACH,eAAO,MAAM,UAAU,UAAU,CAAC;AAClC,eAAO,MAAM,cAAc,cAAc,CAAC;AAE1C;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,UAAU,GAAG,MAAM,GAAG,IAAI,CAU3D;AAED;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,IAAI,EAAE,UAAU,WAEvC;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,UAAU,WAE3C;AAED;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,IAAI,EAAE,UAAU,WAEvC;AAED;;;;;;;GAOG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,UAAU,WAEzC"}
@@ -0,0 +1,239 @@
1
+ import { SCNotificationsType, SCNotificationsWebPushMessagingType, SCNotificationsWebSocketType, SCSettingsType } from '../types/context';
2
+ import { ValidationResult } from './errors';
3
+ import { SCLocaleType } from '../types';
4
+ /**
5
+ * Validate session option
6
+ * @param session
7
+ * @return {}
8
+ */
9
+ export declare function validateSession(v: Record<string, any>): {
10
+ errors: any[];
11
+ warnings: any[];
12
+ value: Record<string, any>;
13
+ };
14
+ /**
15
+ * Validate session type
16
+ * @param value
17
+ * @return {}
18
+ */
19
+ export declare const validateSessionType: (value: any, session: any) => {
20
+ errors: any[];
21
+ warnings: any[];
22
+ value: any;
23
+ };
24
+ /**
25
+ * Validate session client id
26
+ * @param value
27
+ * @return {}
28
+ */
29
+ export declare const validateSessionClientId: (value: any, session: any) => {
30
+ errors: any[];
31
+ warnings: any[];
32
+ value: any;
33
+ };
34
+ /**
35
+ * Validate session auth token
36
+ * @param value
37
+ * @return {}
38
+ */
39
+ export declare const validateSessionAuthTokenOption: (value: any, session: any) => {
40
+ errors: any[];
41
+ warnings: any[];
42
+ value: any;
43
+ };
44
+ /**
45
+ * Validate handleRefreshToken option
46
+ * @param value
47
+ * @return {}
48
+ */
49
+ export declare const validateHandleRefreshToken: (value: any, session: any) => {
50
+ errors: any[];
51
+ warnings: any[];
52
+ value: any;
53
+ };
54
+ /**
55
+ * Validate notifications option
56
+ * @param notifications
57
+ * @return {}
58
+ */
59
+ export declare function validateNotifications(v: SCNotificationsType): {
60
+ errors: any[];
61
+ warnings: any[];
62
+ value: SCNotificationsType;
63
+ };
64
+ /**
65
+ * Validate webSocket
66
+ * @param value
67
+ * @param {}
68
+ */
69
+ export declare const validateWebSocket: (v: any) => {
70
+ errors: any[];
71
+ warnings: any[];
72
+ v: any;
73
+ value?: undefined;
74
+ } | {
75
+ errors: any[];
76
+ warnings: any[];
77
+ value: SCNotificationsWebSocketType;
78
+ v?: undefined;
79
+ };
80
+ /**
81
+ * Validate default disableToastMessage (webSocket)
82
+ * @param value
83
+ * @param {}
84
+ */
85
+ export declare const validateWebSocketDisableToastMessage: (value: any, notifications: any) => {
86
+ errors: any[];
87
+ warnings: any[];
88
+ value: any;
89
+ };
90
+ /**
91
+ * Validate webPushMessaging
92
+ * @param value
93
+ * @param {}
94
+ */
95
+ export declare const validateWebPushMessaging: (v: any) => {
96
+ errors: any[];
97
+ warnings: any[];
98
+ v: any;
99
+ value?: undefined;
100
+ } | {
101
+ errors: any[];
102
+ warnings: any[];
103
+ value: SCNotificationsWebPushMessagingType;
104
+ v?: undefined;
105
+ };
106
+ /**
107
+ * Validate default disableToastMessage (webPushMessaging)
108
+ * @param value
109
+ * @param {}
110
+ */
111
+ export declare const validateWebPushMessagingDisableToastMessage: (value: any, notifications: any) => {
112
+ errors: any[];
113
+ warnings: any[];
114
+ value: any;
115
+ };
116
+ /**
117
+ * Validate default applicationServerKey (webPushMessaging)
118
+ * @param value
119
+ * @param {}
120
+ */
121
+ export declare const validateWebPushMessagingApplicationServerKey: (value: any, notifications: any) => {
122
+ errors: any[];
123
+ warnings: any[];
124
+ value: any;
125
+ };
126
+ /**
127
+ * Validate portal option
128
+ * @param portal
129
+ * @return {}
130
+ */
131
+ export declare const validatePortal: (value: any) => {
132
+ errors: any[];
133
+ warnings: any[];
134
+ value: any;
135
+ };
136
+ /**
137
+ * Validate default locale
138
+ * @param value
139
+ * @param {}
140
+ */
141
+ export declare const validateLocaleDefault: (value: any, locale: any) => {
142
+ errors: any[];
143
+ warnings: any[];
144
+ value: any;
145
+ };
146
+ /**
147
+ * Validate default locale
148
+ * @param value
149
+ * @param {}
150
+ */
151
+ export declare const validateLocaleMessages: (value: any) => {
152
+ errors: any[];
153
+ warnings: any[];
154
+ value: any;
155
+ };
156
+ /**
157
+ * Validate locale option
158
+ * @param locale
159
+ * @return {}
160
+ */
161
+ export declare const validateLocale: (v: any) => {
162
+ errors: any[];
163
+ warnings: any[];
164
+ v: any;
165
+ value?: undefined;
166
+ } | {
167
+ errors: any[];
168
+ warnings: any[];
169
+ value: SCLocaleType;
170
+ v?: undefined;
171
+ };
172
+ /**
173
+ * Validate router option
174
+ * @param router
175
+ * @return {}
176
+ */
177
+ export declare const validateRouter: (value: any) => {
178
+ errors: any[];
179
+ warnings: any[];
180
+ value: any;
181
+ };
182
+ /**
183
+ * Validate theme option
184
+ * @param theme
185
+ * @return {}
186
+ */
187
+ export declare const validateTheme: (value: any) => {
188
+ errors: any[];
189
+ warnings: any[];
190
+ value: any;
191
+ };
192
+ /**
193
+ * Validate handleAnonymousAction option
194
+ * @param handleAnonymousAction
195
+ * @return {}
196
+ */
197
+ export declare const validateHandleAnonymousAction: (v: any) => {
198
+ errors: any[];
199
+ warnings: any[];
200
+ value: any;
201
+ };
202
+ /**
203
+ * Validate contextProviders option
204
+ * @param contextProviders
205
+ * @return [...contextProviders]
206
+ */
207
+ export declare const validateContextProviders: (value: any) => {
208
+ errors: any[];
209
+ warnings: any[];
210
+ value: any;
211
+ };
212
+ /**
213
+ * Valid options
214
+ * @type {{}}
215
+ */
216
+ export declare const settingsOptions: Record<string, any>;
217
+ export declare const sessionOptions: Record<string, any>;
218
+ export declare const localeOptions: Record<string, any>;
219
+ export declare const notificationsOptions: Record<string, any>;
220
+ export declare const notificationsWebSocketOptions: Record<string, any>;
221
+ export declare const notificationsWebSPushMessagingOptions: Record<string, any>;
222
+ export declare const validOptions: {
223
+ [x: string]: any;
224
+ };
225
+ /**
226
+ * Validate all options by type
227
+ * @param options
228
+ * @return {options hydrated}
229
+ */
230
+ export declare const validateOptions: (values: SCSettingsType, schemaOptions: Record<string, any>) => {
231
+ validationResult: ValidationResult;
232
+ values: SCSettingsType;
233
+ settings?: undefined;
234
+ } | {
235
+ validationResult: ValidationResult;
236
+ settings: SCSettingsType;
237
+ values?: undefined;
238
+ };
239
+ //# sourceMappingURL=validator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validator.d.ts","sourceRoot":"","sources":["../../../../../src/utils/validator.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EACnC,4BAA4B,EAE5B,cAAc,EACf,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAA0B,gBAAgB,EAAqB,MAAM,UAAU,CAAC;AAGvF,OAAO,EAAC,YAAY,EAAC,MAAM,UAAU,CAAC;AAQtC;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;;;;EAkBrD;AAED;;;;GAIG;AACH,eAAO,MAAM,mBAAmB;;;;CAO/B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,uBAAuB;;;;CAenC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,8BAA8B;;;;CAY1C,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,0BAA0B;;;;CAetC,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,CAAC,EAAE,mBAAmB;;;;EAiB3D;AAED;;;;GAIG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;CAkB7B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,oCAAoC;;;;CAgBhD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,wBAAwB;;;;;;;;;;CAkBpC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,2CAA2C;;;;CAkBvD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,4CAA4C;;;;CASxD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,cAAc;;;;CAO1B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,qBAAqB;;;;CAWjC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,sBAAsB;;;;CAOlC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,cAAc;;;;;;;;;;CAkB1B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,cAAc;;;;CAe1B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,aAAa;;;;CAOzB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,6BAA6B;;;;CAkBzC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,wBAAwB;;;;CAgBpC,CAAC;AAsFF;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAS/C,CAAC;AACF,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAK9C,CAAC;AACF,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAG7C,CAAC;AACF,eAAO,MAAM,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAGpD,CAAC;AACF,eAAO,MAAM,6BAA6B,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAE7D,CAAC;AACF,eAAO,MAAM,qCAAqC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAGrE,CAAC;AAEF,eAAO,MAAM,YAAY;;CAExB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,eAAe,WAAY,cAAc,iBAAiB,OAAO,MAAM,EAAE,GAAG,CAAC;;;;;;;;CAwBzF,CAAC"}
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Take the application server's public key, which is Base64 URL-safe encoded,
3
+ * and convert it to a UInt8Array, because this is the expected input of the subscribe()
4
+ */
5
+ export declare const urlB64ToUint8Array: (base64String: any) => Uint8Array;
6
+ /**
7
+ * Get browser version to track on backend
8
+ * @return {{name: string, version: null}|{name: string, version: string}|{name: *, version: *}|{name: string, version}}
9
+ */
10
+ export declare const loadVersionBrowser: () => {
11
+ name: any;
12
+ version: any;
13
+ };
14
+ //# sourceMappingURL=webPushMessaging.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"webPushMessaging.d.ts","sourceRoot":"","sources":["../../../../../src/utils/webPushMessaging.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,eAAO,MAAM,kBAAkB,mCAW9B,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,kBAAkB;;;CAgE9B,CAAC"}