@piu-company/react-toolkit 1.0.1 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (239) hide show
  1. package/dist/AppProvider.d.ts +16 -16
  2. package/dist/animations/QuadSpinner.d.ts +13 -13
  3. package/dist/animations/Ripple.d.ts +15 -15
  4. package/dist/animations/SvgAnimations.d.ts +11 -11
  5. package/dist/animations/index.d.ts +3 -3
  6. package/dist/authentication/AuthenticationProvider.d.ts +11 -11
  7. package/dist/authentication/context.d.ts +5 -5
  8. package/dist/authentication/duck.d.ts +36 -36
  9. package/dist/authentication/index.d.ts +4 -4
  10. package/dist/authentication/types.d.ts +1 -1
  11. package/dist/axios.d.ts +167 -167
  12. package/dist/breadCrumb/BreadCrumbProvider.d.ts +5 -5
  13. package/dist/breadCrumb/context.d.ts +8 -8
  14. package/dist/breadCrumb/index.d.ts +3 -3
  15. package/dist/breadCrumb/types.d.ts +4 -4
  16. package/dist/components/Consumers/NotificationConsumer.d.ts +1 -1
  17. package/dist/components/Consumers/SnackbarsConsumer.d.ts +1 -1
  18. package/dist/components/Consumers/ToolTipConsumer.d.ts +1 -1
  19. package/dist/components/Consumers/index.d.ts +3 -3
  20. package/dist/components/Firebase/FbImage.d.ts +7 -7
  21. package/dist/components/Firebase/index.d.ts +2 -2
  22. package/dist/components/Firebase/types.d.ts +14 -14
  23. package/dist/components/Forms/ChangePassword.d.ts +9 -9
  24. package/dist/components/Forms/index.d.ts +1 -1
  25. package/dist/components/GoogleCalendar/GoogleCalendarProvider.d.ts +6 -6
  26. package/dist/components/GoogleCalendar/context.d.ts +5 -5
  27. package/dist/components/GoogleCalendar/index.d.ts +2 -2
  28. package/dist/components/GoogleCalendar/types.d.ts +10 -10
  29. package/dist/components/GoogleMaps/GMap.d.ts +27 -27
  30. package/dist/components/GoogleMaps/GMapInput.d.ts +15 -15
  31. package/dist/components/GoogleMaps/GoogleMapsProvider.d.ts +6 -6
  32. package/dist/components/GoogleMaps/context.d.ts +5 -5
  33. package/dist/components/GoogleMaps/index.d.ts +4 -4
  34. package/dist/components/Layout/TitledRow.d.ts +14 -14
  35. package/dist/components/Layout/index.d.ts +1 -1
  36. package/dist/components/Level1/A.d.ts +6 -6
  37. package/dist/components/Level1/Button.d.ts +29 -29
  38. package/dist/components/Level1/Container.d.ts +57 -57
  39. package/dist/components/Level1/DropdownButton.d.ts +11 -11
  40. package/dist/components/Level1/FadeInOut.d.ts +7 -7
  41. package/dist/components/Level1/Hr.d.ts +13 -13
  42. package/dist/components/Level1/Icon.d.ts +18 -18
  43. package/dist/components/Level1/Slider.d.ts +19 -19
  44. package/dist/components/Level1/Spacer.d.ts +5 -5
  45. package/dist/components/Level1/Typography.d.ts +37 -37
  46. package/dist/components/Level1/index.d.ts +10 -10
  47. package/dist/components/Level2/Card.d.ts +9 -9
  48. package/dist/components/Level2/Checkbox.d.ts +29 -29
  49. package/dist/components/Level2/Cover.d.ts +10 -10
  50. package/dist/components/Level2/DatePicker/DatePicker.d.ts +17 -17
  51. package/dist/components/Level2/DatePicker/DayPicker.d.ts +43 -43
  52. package/dist/components/Level2/DatePicker/MonthPicker.d.ts +27 -27
  53. package/dist/components/Level2/DatePicker/index.d.ts +4 -4
  54. package/dist/components/Level2/DatePicker/types.d.ts +8 -8
  55. package/dist/components/Level2/FloatingDiv.d.ts +17 -17
  56. package/dist/components/Level2/IconButton.d.ts +23 -23
  57. package/dist/components/Level2/Linker.d.ts +7 -7
  58. package/dist/components/Level2/MultiButtonSelect.d.ts +24 -24
  59. package/dist/components/Level2/Overlay.d.ts +36 -36
  60. package/dist/components/Level2/PanelForm/PanelForm.d.ts +9 -9
  61. package/dist/components/Level2/PanelForm/PanelFormContent.d.ts +5 -5
  62. package/dist/components/Level2/PanelForm/PanelFormSaveSection.d.ts +10 -10
  63. package/dist/components/Level2/PanelForm/PanelFormSection.d.ts +6 -6
  64. package/dist/components/Level2/PanelForm/PanelFormTitleSection.d.ts +6 -6
  65. package/dist/components/Level2/PanelForm/index.d.ts +5 -5
  66. package/dist/components/Level2/PillContainer.d.ts +13 -13
  67. package/dist/components/Level2/RadioButton.d.ts +10 -10
  68. package/dist/components/Level2/SideMenu/SideMenu.d.ts +24 -24
  69. package/dist/components/Level2/SideMenu/SideMenuButton.d.ts +16 -16
  70. package/dist/components/Level2/SideMenu/SideMenuNav.d.ts +12 -12
  71. package/dist/components/Level2/SideMenu/index.d.ts +3 -3
  72. package/dist/components/Level2/SideMenu/types.d.ts +25 -25
  73. package/dist/components/Level2/SocialButtons/FacebookButton.d.ts +12 -12
  74. package/dist/components/Level2/SocialButtons/GoogleButton.d.ts +12 -12
  75. package/dist/components/Level2/SocialButtons/index.d.ts +2 -2
  76. package/dist/components/Level2/Switch.d.ts +11 -11
  77. package/dist/components/Level2/TargetCard.d.ts +43 -42
  78. package/dist/components/Level2/TextField/Masker.d.ts +13 -13
  79. package/dist/components/Level2/TextField/TextField.d.ts +16 -16
  80. package/dist/components/Level2/TextField/TextFieldContainer.d.ts +18 -18
  81. package/dist/components/Level2/TextField/index.d.ts +3 -3
  82. package/dist/components/Level2/ThemeToggle.d.ts +5 -5
  83. package/dist/components/Level2/Tooltip.d.ts +21 -21
  84. package/dist/components/Level2/Uploader/UploadPreview.d.ts +9 -9
  85. package/dist/components/Level2/Uploader/Uploader.d.ts +30 -30
  86. package/dist/components/Level2/Uploader/index.d.ts +3 -3
  87. package/dist/components/Level2/Uploader/types.d.ts +7 -7
  88. package/dist/components/Level2/index.d.ts +20 -20
  89. package/dist/components/Level3/AreaChart.d.ts +29 -29
  90. package/dist/components/Level3/BarChart.d.ts +26 -26
  91. package/dist/components/Level3/BreadCrumb.d.ts +5 -5
  92. package/dist/components/Level3/Chart.d.ts +22 -22
  93. package/dist/components/Level3/ColorPicker.d.ts +9 -9
  94. package/dist/components/Level3/DashboardCard.d.ts +18 -18
  95. package/dist/components/Level3/DashboardCardV2.d.ts +13 -13
  96. package/dist/components/Level3/DashboardSelector/DashboardSelector.d.ts +8 -8
  97. package/dist/components/Level3/DashboardSelector/index.d.ts +2 -2
  98. package/dist/components/Level3/DashboardSelector/types.d.ts +4 -4
  99. package/dist/components/Level3/DateField.d.ts +31 -31
  100. package/dist/components/Level3/FloatingIconButton.d.ts +19 -19
  101. package/dist/components/Level3/FloatingIconButtonList.d.ts +13 -13
  102. package/dist/components/Level3/FullScreenButton.d.ts +2 -2
  103. package/dist/components/Level3/ListEditor.d.ts +12 -12
  104. package/dist/components/Level3/MultiChart.d.ts +27 -27
  105. package/dist/components/Level3/OptionSelector/OptionSelector.d.ts +18 -18
  106. package/dist/components/Level3/OptionSelector/index.d.ts +2 -2
  107. package/dist/components/Level3/OptionSelector/types.d.ts +8 -8
  108. package/dist/components/Level3/OverlayTopBar.d.ts +32 -32
  109. package/dist/components/Level3/PasswordField.d.ts +17 -17
  110. package/dist/components/Level3/PhoneField/PhoneField.d.ts +12 -12
  111. package/dist/components/Level3/PhoneField/PhoneSelection.d.ts +15 -15
  112. package/dist/components/Level3/PhoneField/countryData.d.ts +7 -7
  113. package/dist/components/Level3/PhoneField/flags/index.d.ts +243 -243
  114. package/dist/components/Level3/PhoneField/functions.d.ts +4 -4
  115. package/dist/components/Level3/PhoneField/index.d.ts +6 -6
  116. package/dist/components/Level3/PhoneField/types.d.ts +5 -5
  117. package/dist/components/Level3/PieChart.d.ts +30 -30
  118. package/dist/components/Level3/Popup.d.ts +23 -23
  119. package/dist/components/Level3/ProfileBox.d.ts +27 -27
  120. package/dist/components/Level3/Snackbar.d.ts +16 -16
  121. package/dist/components/Level3/TimeField/TimeField.d.ts +23 -22
  122. package/dist/components/Level3/TimeField/TimePicker.d.ts +23 -23
  123. package/dist/components/Level3/TimeField/index.d.ts +2 -2
  124. package/dist/components/Level3/Topbar.d.ts +36 -36
  125. package/dist/components/Level3/index.d.ts +24 -24
  126. package/dist/components/Level4/ConfirmPopup.d.ts +14 -14
  127. package/dist/components/Level4/index.d.ts +1 -1
  128. package/dist/components/NextJS/NEXTGlobalStyle.d.ts +7 -7
  129. package/dist/components/NextJS/index.d.ts +2 -2
  130. package/dist/components/NextJS/utils.d.ts +1 -1
  131. package/dist/components/Stripe/CardCvc.d.ts +17 -17
  132. package/dist/components/Stripe/CardExpiry.d.ts +17 -17
  133. package/dist/components/Stripe/CardNumber.d.ts +17 -17
  134. package/dist/components/Stripe/StripeProvider.d.ts +9 -9
  135. package/dist/components/Stripe/context.d.ts +6 -6
  136. package/dist/components/Stripe/functions.d.ts +5 -5
  137. package/dist/components/Stripe/index.d.ts +6 -6
  138. package/dist/components/UseDataLayer/Autocomplete/Autocomplete.d.ts +10 -10
  139. package/dist/components/UseDataLayer/Autocomplete/AutocompleteUI.d.ts +21 -21
  140. package/dist/components/UseDataLayer/Autocomplete/OptionDiv.d.ts +12 -12
  141. package/dist/components/UseDataLayer/Autocomplete/Selection.d.ts +13 -13
  142. package/dist/components/UseDataLayer/Autocomplete/index.d.ts +5 -5
  143. package/dist/components/UseDataLayer/Autocomplete/types.d.ts +10 -10
  144. package/dist/components/UseDataLayer/CountrySelection.d.ts +11 -11
  145. package/dist/components/UseDataLayer/EntityList/EntityList.d.ts +10 -10
  146. package/dist/components/UseDataLayer/EntityList/EntityListUI.d.ts +12 -12
  147. package/dist/components/UseDataLayer/EntityList/index.d.ts +3 -3
  148. package/dist/components/UseDataLayer/EntityList/types.d.ts +1 -1
  149. package/dist/components/UseDataLayer/Table/Header.d.ts +24 -24
  150. package/dist/components/UseDataLayer/Table/PaginationControl.d.ts +8 -8
  151. package/dist/components/UseDataLayer/Table/Row.d.ts +22 -22
  152. package/dist/components/UseDataLayer/Table/ShowingControl.d.ts +18 -18
  153. package/dist/components/UseDataLayer/Table/ShowingFooter.d.ts +6 -6
  154. package/dist/components/UseDataLayer/Table/Table.d.ts +10 -10
  155. package/dist/components/UseDataLayer/Table/TableUI.d.ts +24 -24
  156. package/dist/components/UseDataLayer/Table/index.d.ts +8 -8
  157. package/dist/components/UseDataLayer/Table/types.d.ts +13 -13
  158. package/dist/components/UseDataLayer/TownSelection.d.ts +11 -11
  159. package/dist/components/UseDataLayer/index.d.ts +5 -5
  160. package/dist/components/UseRedux/Sidebar/Sidebar.d.ts +48 -48
  161. package/dist/components/UseRedux/Sidebar/SidebarButton.d.ts +25 -25
  162. package/dist/components/UseRedux/Sidebar/SidebarTitle.d.ts +14 -14
  163. package/dist/components/UseRedux/Sidebar/SidebarToggler.d.ts +16 -16
  164. package/dist/components/UseRedux/Sidebar/duck.d.ts +30 -30
  165. package/dist/components/UseRedux/Sidebar/index.d.ts +6 -6
  166. package/dist/components/UseRedux/Sidebar/types.d.ts +13 -13
  167. package/dist/components/UseRedux/index.d.ts +1 -1
  168. package/dist/components/index.d.ts +15 -15
  169. package/dist/components/pages/AuthPage/AuthPage.d.ts +18 -18
  170. package/dist/components/pages/AuthPage/index.d.ts +2 -2
  171. package/dist/components/pages/AuthPage/types.d.ts +14 -14
  172. package/dist/components/pages/AuthPageV2.d.ts +16 -16
  173. package/dist/components/pages/ErrorPage.d.ts +13 -13
  174. package/dist/components/pages/ForbiddenPage.d.ts +15 -15
  175. package/dist/components/pages/ForgotPasswordPage/ForgotPasswordForm.d.ts +5 -5
  176. package/dist/components/pages/ForgotPasswordPage/ForgotPasswordPage.d.ts +4 -4
  177. package/dist/components/pages/ForgotPasswordPage/index.d.ts +2 -2
  178. package/dist/components/pages/LoadingPage.d.ts +14 -14
  179. package/dist/components/pages/LoginPage/LoginForm.d.ts +20 -20
  180. package/dist/components/pages/LoginPage/LoginPage.d.ts +9 -9
  181. package/dist/components/pages/LoginPage/index.d.ts +2 -2
  182. package/dist/components/pages/LogoutPage.d.ts +5 -5
  183. package/dist/components/pages/NotFoundPage.d.ts +6 -6
  184. package/dist/components/pages/UnverifiedUserPage.d.ts +6 -6
  185. package/dist/components/pages/index.d.ts +10 -10
  186. package/dist/contextCheckers.d.ts +4 -4
  187. package/dist/dataEnums.d.ts +370 -370
  188. package/dist/dataLayer/DataContext.d.ts +11 -11
  189. package/dist/dataLayer/DataProvider.d.ts +53 -53
  190. package/dist/dataLayer/duck.d.ts +32 -32
  191. package/dist/dataLayer/index.d.ts +4 -4
  192. package/dist/dataLayer/types.d.ts +17 -17
  193. package/dist/generalTypes.d.ts +48 -48
  194. package/dist/geoUtils.d.ts +35 -35
  195. package/dist/hooks/index.d.ts +8 -8
  196. package/dist/hooks/types.d.ts +3 -3
  197. package/dist/hooks/useClickOutside.d.ts +3 -3
  198. package/dist/hooks/useCombinedRef.d.ts +1 -1
  199. package/dist/hooks/useEnterSubmit.d.ts +2 -2
  200. package/dist/hooks/useFBAuth.d.ts +2 -2
  201. package/dist/hooks/useInterval.d.ts +2 -2
  202. package/dist/hooks/useResize.d.ts +2 -2
  203. package/dist/hooks/useTimeout.d.ts +2 -2
  204. package/dist/index.cjs.js +44 -4
  205. package/dist/index.d.ts +22 -22
  206. package/dist/index.esm.js +44 -4
  207. package/dist/masker.d.ts +15 -15
  208. package/dist/navigation/NavProvider.d.ts +7 -7
  209. package/dist/navigation/context.d.ts +6 -6
  210. package/dist/navigation/index.d.ts +3 -3
  211. package/dist/navigation/types.d.ts +6 -6
  212. package/dist/notification/NotificationProvider.d.ts +21 -21
  213. package/dist/notification/context.d.ts +8 -8
  214. package/dist/notification/duck.d.ts +30 -30
  215. package/dist/notification/index.d.ts +3 -3
  216. package/dist/redux.d.ts +25 -25
  217. package/dist/size/SizeProvider.d.ts +6 -6
  218. package/dist/size/context.d.ts +5 -5
  219. package/dist/size/index.d.ts +3 -3
  220. package/dist/size/types.d.ts +5 -5
  221. package/dist/snackbar/SnackbarProvider.d.ts +5 -5
  222. package/dist/snackbar/context.d.ts +8 -8
  223. package/dist/snackbar/functions.d.ts +14 -14
  224. package/dist/snackbar/index.d.ts +4 -4
  225. package/dist/snackbar/types.d.ts +28 -28
  226. package/dist/styleEnums.d.ts +156 -156
  227. package/dist/theming/ThemeProvider.d.ts +26 -26
  228. package/dist/theming/context.d.ts +11 -11
  229. package/dist/theming/duck.d.ts +23 -23
  230. package/dist/theming/functions.d.ts +2 -2
  231. package/dist/theming/index.d.ts +5 -5
  232. package/dist/theming/types.d.ts +60 -60
  233. package/dist/tooltip/ToolTipProvider.d.ts +5 -5
  234. package/dist/tooltip/context.d.ts +10 -10
  235. package/dist/tooltip/index.d.ts +3 -3
  236. package/dist/tooltip/types.d.ts +8 -8
  237. package/dist/tsconfig.rollup.tsbuildinfo +1 -1
  238. package/dist/utils.d.ts +39 -39
  239. package/package.json +1 -1
package/dist/index.esm.js CHANGED
@@ -15673,7 +15673,7 @@ function requireLodash () {
15673
15673
  var undefined$1;
15674
15674
 
15675
15675
  /** Used as the semantic version number. */
15676
- var VERSION = '4.17.21';
15676
+ var VERSION = '4.17.23';
15677
15677
 
15678
15678
  /** Used as the size to enable large array optimizations. */
15679
15679
  var LARGE_ARRAY_SIZE = 200;
@@ -19427,7 +19427,7 @@ function requireLodash () {
19427
19427
  if (isArray(iteratee)) {
19428
19428
  return function(value) {
19429
19429
  return baseGet(value, iteratee.length === 1 ? iteratee[0] : iteratee);
19430
- }
19430
+ };
19431
19431
  }
19432
19432
  return iteratee;
19433
19433
  });
@@ -20031,8 +20031,47 @@ function requireLodash () {
20031
20031
  */
20032
20032
  function baseUnset(object, path) {
20033
20033
  path = castPath(path, object);
20034
- object = parent(object, path);
20035
- return object == null || delete object[toKey(last(path))];
20034
+
20035
+ // Prevent prototype pollution, see: https://github.com/lodash/lodash/security/advisories/GHSA-xxjr-mmjv-4gpg
20036
+ var index = -1,
20037
+ length = path.length;
20038
+
20039
+ if (!length) {
20040
+ return true;
20041
+ }
20042
+
20043
+ var isRootPrimitive = object == null || (typeof object !== 'object' && typeof object !== 'function');
20044
+
20045
+ while (++index < length) {
20046
+ var key = path[index];
20047
+
20048
+ // skip non-string keys (e.g., Symbols, numbers)
20049
+ if (typeof key !== 'string') {
20050
+ continue;
20051
+ }
20052
+
20053
+ // Always block "__proto__" anywhere in the path if it's not expected
20054
+ if (key === '__proto__' && !hasOwnProperty.call(object, '__proto__')) {
20055
+ return false;
20056
+ }
20057
+
20058
+ // Block "constructor.prototype" chains
20059
+ if (key === 'constructor' &&
20060
+ (index + 1) < length &&
20061
+ typeof path[index + 1] === 'string' &&
20062
+ path[index + 1] === 'prototype') {
20063
+
20064
+ // Allow ONLY when the path starts at a primitive root, e.g., _.unset(0, 'constructor.prototype.a')
20065
+ if (isRootPrimitive && index === 0) {
20066
+ continue;
20067
+ }
20068
+
20069
+ return false;
20070
+ }
20071
+ }
20072
+
20073
+ var obj = parent(object, path);
20074
+ return obj == null || delete obj[toKey(last(path))];
20036
20075
  }
20037
20076
 
20038
20077
  /**
@@ -42544,6 +42583,7 @@ const AuthPage = ({ apiCall, loadExtraData, setExtraData, ...props }) => {
42544
42583
  if (!props.loginRequired && !props.anonymousLogin) {
42545
42584
  setDenied(false);
42546
42585
  setLoading(false);
42586
+ ready = true;
42547
42587
  }
42548
42588
  else {
42549
42589
  if (state && props.firebaseConfig) {
package/dist/masker.d.ts CHANGED
@@ -1,15 +1,15 @@
1
- export declare enum MaskerCharacters {
2
- digit = "d",
3
- letter = "x",
4
- empty = "-"
5
- }
6
- export interface IMaskerConfig {
7
- template: string;
8
- placeholder: string;
9
- }
10
- export declare const maskLetterChecker: (config: IMaskerConfig, raw: string) => boolean;
11
- export declare const maskOutput: (config: IMaskerConfig, raw: string) => string;
12
- export declare const idCardMask: IMaskerConfig;
13
- export declare const dateMask: IMaskerConfig;
14
- export declare const timeMask: IMaskerConfig;
15
- export declare const vatMTMask: IMaskerConfig;
1
+ export declare enum MaskerCharacters {
2
+ digit = "d",
3
+ letter = "x",
4
+ empty = "-"
5
+ }
6
+ export interface IMaskerConfig {
7
+ template: string;
8
+ placeholder: string;
9
+ }
10
+ export declare const maskLetterChecker: (config: IMaskerConfig, raw: string) => boolean;
11
+ export declare const maskOutput: (config: IMaskerConfig, raw: string) => string;
12
+ export declare const idCardMask: IMaskerConfig;
13
+ export declare const dateMask: IMaskerConfig;
14
+ export declare const timeMask: IMaskerConfig;
15
+ export declare const vatMTMask: IMaskerConfig;
@@ -1,7 +1,7 @@
1
- import { ReactNode } from 'react';
2
- import { Browser } from './types';
3
- export interface INavigationProvider {
4
- browser: Browser;
5
- children?: ReactNode;
6
- }
7
- export declare const NavigationProvider: (props: INavigationProvider) => import("react/jsx-runtime").JSX.Element;
1
+ import { ReactNode } from 'react';
2
+ import { Browser } from './types';
3
+ export interface INavigationProvider {
4
+ browser: Browser;
5
+ children?: ReactNode;
6
+ }
7
+ export declare const NavigationProvider: (props: INavigationProvider) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +1,6 @@
1
- import { Browser } from './types';
2
- export interface INavigationContext {
3
- browser?: Browser;
4
- }
5
- export declare const defaultNavigationContext: INavigationContext;
6
- export declare const NavigationContext: import("react").Context<INavigationContext>;
1
+ import { Browser } from './types';
2
+ export interface INavigationContext {
3
+ browser?: Browser;
4
+ }
5
+ export declare const defaultNavigationContext: INavigationContext;
6
+ export declare const NavigationContext: import("react").Context<INavigationContext>;
@@ -1,3 +1,3 @@
1
- export * from './context';
2
- export * from './types';
3
- export * from './NavProvider';
1
+ export * from './context';
2
+ export * from './types';
3
+ export * from './NavProvider';
@@ -1,6 +1,6 @@
1
- export declare enum Browser {
2
- firefox = "firefox",
3
- edge = "edge",
4
- chrome = "chrome",
5
- safari = "safari"
6
- }
1
+ export declare enum Browser {
2
+ firefox = "firefox",
3
+ edge = "edge",
4
+ chrome = "chrome",
5
+ safari = "safari"
6
+ }
@@ -1,21 +1,21 @@
1
- import { ReactNode } from 'react';
2
- import { INotificationState, INotificationStoreActions } from './duck';
3
- import { PlayFunction } from 'use-sound/dist/types';
4
- export interface Notification {
5
- title: string;
6
- body: string;
7
- link?: string;
8
- dismissable?: boolean;
9
- sound?: boolean;
10
- type?: string;
11
- data?: any;
12
- }
13
- export interface INotificationConfig {
14
- sound?: PlayFunction;
15
- customConsumer?: boolean;
16
- onAddNotification?: (notification: Notification) => void;
17
- }
18
- export interface INotificationProvider extends INotificationConfig, INotificationState, INotificationStoreActions {
19
- children: ReactNode;
20
- }
21
- export declare const NotificationProvider: any;
1
+ import { ReactNode } from 'react';
2
+ import { INotificationState, INotificationStoreActions } from './duck';
3
+ import { PlayFunction } from 'use-sound/dist/types';
4
+ export interface Notification {
5
+ title: string;
6
+ body: string;
7
+ link?: string;
8
+ dismissable?: boolean;
9
+ sound?: boolean;
10
+ type?: string;
11
+ data?: any;
12
+ }
13
+ export interface INotificationConfig {
14
+ sound?: PlayFunction;
15
+ customConsumer?: boolean;
16
+ onAddNotification?: (notification: Notification) => void;
17
+ }
18
+ export interface INotificationProvider extends INotificationConfig, INotificationState, INotificationStoreActions {
19
+ children: ReactNode;
20
+ }
21
+ export declare const NotificationProvider: any;
@@ -1,8 +1,8 @@
1
- import { Notification } from './NotificationProvider';
2
- export interface INotificationContext {
3
- notifications?: Notification[];
4
- addNotification?: (newNotif: Notification) => void;
5
- removeNotification?: (index: number) => void;
6
- }
7
- export declare const defaultNotificationContext: INotificationContext;
8
- export declare const NotificationContext: import("react").Context<INotificationContext>;
1
+ import { Notification } from './NotificationProvider';
2
+ export interface INotificationContext {
3
+ notifications?: Notification[];
4
+ addNotification?: (newNotif: Notification) => void;
5
+ removeNotification?: (index: number) => void;
6
+ }
7
+ export declare const defaultNotificationContext: INotificationContext;
8
+ export declare const NotificationContext: import("react").Context<INotificationContext>;
@@ -1,30 +1,30 @@
1
- import { Notification } from './NotificationProvider';
2
- export interface INotificationAction {
3
- type: NotificationActionTypes;
4
- payload: INotificationState;
5
- }
6
- export declare enum NotificationActionTypes {
7
- setNotifications = "setNotifications"
8
- }
9
- export interface INotificationState {
10
- notifications?: Notification[];
11
- }
12
- export interface INotificationStoreActions {
13
- setNotifications: (notifications: Notification[]) => void;
14
- }
15
- export interface INotificationMapStore {
16
- notifications: INotificationState;
17
- }
18
- export declare const persistNotification: string[];
19
- export declare const notificationReducer: (state: INotificationState | undefined, action: INotificationAction) => INotificationState;
20
- export declare const notificationActions: {
21
- setNotifications: (notifications: Notification[]) => {
22
- type: NotificationActionTypes;
23
- payload: {
24
- notifications: Notification[];
25
- };
26
- };
27
- };
28
- export declare const mapStateToPropsNotification: (store: INotificationMapStore) => {
29
- notifications: Notification[] | undefined;
30
- };
1
+ import { Notification } from './NotificationProvider';
2
+ export interface INotificationAction {
3
+ type: NotificationActionTypes;
4
+ payload: INotificationState;
5
+ }
6
+ export declare enum NotificationActionTypes {
7
+ setNotifications = "setNotifications"
8
+ }
9
+ export interface INotificationState {
10
+ notifications?: Notification[];
11
+ }
12
+ export interface INotificationStoreActions {
13
+ setNotifications: (notifications: Notification[]) => void;
14
+ }
15
+ export interface INotificationMapStore {
16
+ notifications: INotificationState;
17
+ }
18
+ export declare const persistNotification: string[];
19
+ export declare const notificationReducer: (state: INotificationState | undefined, action: INotificationAction) => INotificationState;
20
+ export declare const notificationActions: {
21
+ setNotifications: (notifications: Notification[]) => {
22
+ type: NotificationActionTypes;
23
+ payload: {
24
+ notifications: Notification[];
25
+ };
26
+ };
27
+ };
28
+ export declare const mapStateToPropsNotification: (store: INotificationMapStore) => {
29
+ notifications: Notification[] | undefined;
30
+ };
@@ -1,3 +1,3 @@
1
- export * from './NotificationProvider';
2
- export * from './context';
3
- export * from './duck';
1
+ export * from './NotificationProvider';
2
+ export * from './context';
3
+ export * from './duck';
package/dist/redux.d.ts CHANGED
@@ -1,25 +1,25 @@
1
- import { Reducer } from 'react';
2
- import { PersistConfig } from 'redux-persist';
3
- import { IAuthAction, IAuthState } from './authentication';
4
- import { ISidebarAction, ISidebarState } from './components';
5
- import { IThemeAction, IThemeState } from './theming';
6
- import { IDataLayerAction, IDataLayerState } from './dataLayer';
7
- import { PersistPartial } from 'redux-persist/es/persistReducer';
8
- import { INotificationAction, INotificationState } from './notification';
9
- export declare const generateModulePersistConfig: <T>(appName: string, moduleName: string, whitelist: string[]) => PersistConfig<T, any, any, any>;
10
- export declare const defaultStorageSetup: IStorageSetup;
11
- export interface IStorageSetup {
12
- theme?: boolean;
13
- authentication?: boolean;
14
- sidebar?: boolean;
15
- notifications?: boolean;
16
- dataLayer?: string[];
17
- }
18
- export interface IConfig<UserType> {
19
- theme?: Reducer<IThemeState, IThemeAction> | Reducer<IThemeState & PersistPartial, IThemeAction>;
20
- sidebar?: Reducer<ISidebarState & PersistPartial, ISidebarAction> | Reducer<ISidebarState, ISidebarAction>;
21
- authentication?: Reducer<IAuthState<UserType> & PersistPartial, IAuthAction<UserType>> | Reducer<IAuthState<UserType>, IAuthAction<UserType>>;
22
- notifications?: Reducer<INotificationState & PersistPartial, INotificationAction> | Reducer<INotificationState, INotificationAction>;
23
- dataLayer?: Reducer<IDataLayerState & PersistPartial, IDataLayerAction> | Reducer<IDataLayerState, IDataLayerAction>;
24
- }
25
- export declare const reducerCombiner: <T>(appName: string, setup?: IStorageSetup) => IConfig<T>;
1
+ import { Reducer } from 'react';
2
+ import { PersistConfig } from 'redux-persist';
3
+ import { IAuthAction, IAuthState } from './authentication';
4
+ import { ISidebarAction, ISidebarState } from './components';
5
+ import { IThemeAction, IThemeState } from './theming';
6
+ import { IDataLayerAction, IDataLayerState } from './dataLayer';
7
+ import { PersistPartial } from 'redux-persist/es/persistReducer';
8
+ import { INotificationAction, INotificationState } from './notification';
9
+ export declare const generateModulePersistConfig: <T>(appName: string, moduleName: string, whitelist: string[]) => PersistConfig<T, any, any, any>;
10
+ export declare const defaultStorageSetup: IStorageSetup;
11
+ export interface IStorageSetup {
12
+ theme?: boolean;
13
+ authentication?: boolean;
14
+ sidebar?: boolean;
15
+ notifications?: boolean;
16
+ dataLayer?: string[];
17
+ }
18
+ export interface IConfig<UserType> {
19
+ theme?: Reducer<IThemeState, IThemeAction> | Reducer<IThemeState & PersistPartial, IThemeAction>;
20
+ sidebar?: Reducer<ISidebarState & PersistPartial, ISidebarAction> | Reducer<ISidebarState, ISidebarAction>;
21
+ authentication?: Reducer<IAuthState<UserType> & PersistPartial, IAuthAction<UserType>> | Reducer<IAuthState<UserType>, IAuthAction<UserType>>;
22
+ notifications?: Reducer<INotificationState & PersistPartial, INotificationAction> | Reducer<INotificationState, INotificationAction>;
23
+ dataLayer?: Reducer<IDataLayerState & PersistPartial, IDataLayerAction> | Reducer<IDataLayerState, IDataLayerAction>;
24
+ }
25
+ export declare const reducerCombiner: <T>(appName: string, setup?: IStorageSetup) => IConfig<T>;
@@ -1,6 +1,6 @@
1
- import { ReactNode } from 'react';
2
- export interface ISizeProvider {
3
- children: ReactNode;
4
- mobileWidth?: number;
5
- }
6
- export declare const SizeProvider: (props: ISizeProvider) => import("react/jsx-runtime").JSX.Element;
1
+ import { ReactNode } from 'react';
2
+ export interface ISizeProvider {
3
+ children: ReactNode;
4
+ mobileWidth?: number;
5
+ }
6
+ export declare const SizeProvider: (props: ISizeProvider) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +1,5 @@
1
- export interface ISizeContext {
2
- mobile: boolean;
3
- }
4
- export declare const defaultSizeContext: ISizeContext;
5
- export declare const SizeContext: import("react").Context<ISizeContext>;
1
+ export interface ISizeContext {
2
+ mobile: boolean;
3
+ }
4
+ export declare const defaultSizeContext: ISizeContext;
5
+ export declare const SizeContext: import("react").Context<ISizeContext>;
@@ -1,3 +1,3 @@
1
- export * from './context';
2
- export * from './SizeProvider';
3
- export * from './types';
1
+ export * from './context';
2
+ export * from './SizeProvider';
3
+ export * from './types';
@@ -1,5 +1,5 @@
1
- export interface ISize {
2
- width: number;
3
- height: number;
4
- }
5
- export declare const mobileWidth = 768;
1
+ export interface ISize {
2
+ width: number;
3
+ height: number;
4
+ }
5
+ export declare const mobileWidth = 768;
@@ -1,5 +1,5 @@
1
- import { ReactNode } from 'react';
2
- export interface ISnackbarProvider {
3
- children: ReactNode;
4
- }
5
- export declare const SnackbarProvider: (props: ISnackbarProvider) => import("react/jsx-runtime").JSX.Element;
1
+ import { ReactNode } from 'react';
2
+ export interface ISnackbarProvider {
3
+ children: ReactNode;
4
+ }
5
+ export declare const SnackbarProvider: (props: ISnackbarProvider) => import("react/jsx-runtime").JSX.Element;
@@ -1,8 +1,8 @@
1
- import { ISnackbar } from '../components';
2
- import { SnackbarStateHandler } from './types';
3
- export interface ISnackbarContext {
4
- state?: ISnackbar;
5
- addData?: SnackbarStateHandler;
6
- }
7
- export declare const defaultSnackbarsContext: ISnackbarContext;
8
- export declare const SnackbarContext: import("react").Context<ISnackbarContext>;
1
+ import { ISnackbar } from '../components';
2
+ import { SnackbarStateHandler } from './types';
3
+ export interface ISnackbarContext {
4
+ state?: ISnackbar;
5
+ addData?: SnackbarStateHandler;
6
+ }
7
+ export declare const defaultSnackbarsContext: ISnackbarContext;
8
+ export declare const SnackbarContext: import("react").Context<ISnackbarContext>;
@@ -1,14 +1,14 @@
1
- import { ISnackbarConfig, SnackbarStateHandler, SnackbarType } from './types';
2
- export declare const generateSnackbarConfig: (message: string, type: SnackbarType, snackbarData?: ISnackbarConfig) => {
3
- data: {
4
- message: string;
5
- snackbarType: SnackbarType;
6
- interval: number;
7
- show: boolean;
8
- };
9
- horizontalPos: import("..").FloatingPosH;
10
- verticalPos: import("..").FloatingPosV;
11
- icon: boolean;
12
- width?: string;
13
- };
14
- export declare const displaySnackbar: (message: string, barType: SnackbarType, snackbarAddData?: SnackbarStateHandler) => void;
1
+ import { ISnackbarConfig, SnackbarStateHandler, SnackbarType } from './types';
2
+ export declare const generateSnackbarConfig: (message: string, type: SnackbarType, snackbarData?: ISnackbarConfig) => {
3
+ data: {
4
+ message: string;
5
+ snackbarType: SnackbarType;
6
+ interval: number;
7
+ show: boolean;
8
+ };
9
+ horizontalPos: import("..").FloatingPosH;
10
+ verticalPos: import("..").FloatingPosV;
11
+ icon: boolean;
12
+ width?: string;
13
+ };
14
+ export declare const displaySnackbar: (message: string, barType: SnackbarType, snackbarAddData?: SnackbarStateHandler) => void;
@@ -1,4 +1,4 @@
1
- export * from './types';
2
- export * from './context';
3
- export * from './SnackbarProvider';
4
- export * from './functions';
1
+ export * from './types';
2
+ export * from './context';
3
+ export * from './SnackbarProvider';
4
+ export * from './functions';
@@ -1,28 +1,28 @@
1
- import { ISnackbar } from '../components';
2
- import { FloatingPosH, FloatingPosV } from '../styleEnums';
3
- export type SnackbarHandler = (newState: ISnackbar) => void;
4
- export type SnackbarStateHandler = (newState: ISnackbar) => void;
5
- export declare const initialSnackbarData: ISnackbarData;
6
- export declare const CommonSnackbar: ISnackbarConfig;
7
- export interface ISnackbarData {
8
- show?: boolean;
9
- message: string;
10
- snackbarType?: SnackbarType;
11
- interval?: number;
12
- }
13
- export declare enum SnackbarType {
14
- success = "success",
15
- warning = "warning",
16
- info = "info",
17
- error = "error"
18
- }
19
- export interface ISnackbarConfig {
20
- horizontalPos: FloatingPosH;
21
- verticalPos: FloatingPosV;
22
- icon: boolean;
23
- width?: string;
24
- data: {
25
- interval: number;
26
- show: boolean;
27
- };
28
- }
1
+ import { ISnackbar } from '../components';
2
+ import { FloatingPosH, FloatingPosV } from '../styleEnums';
3
+ export type SnackbarHandler = (newState: ISnackbar) => void;
4
+ export type SnackbarStateHandler = (newState: ISnackbar) => void;
5
+ export declare const initialSnackbarData: ISnackbarData;
6
+ export declare const CommonSnackbar: ISnackbarConfig;
7
+ export interface ISnackbarData {
8
+ show?: boolean;
9
+ message: string;
10
+ snackbarType?: SnackbarType;
11
+ interval?: number;
12
+ }
13
+ export declare enum SnackbarType {
14
+ success = "success",
15
+ warning = "warning",
16
+ info = "info",
17
+ error = "error"
18
+ }
19
+ export interface ISnackbarConfig {
20
+ horizontalPos: FloatingPosH;
21
+ verticalPos: FloatingPosV;
22
+ icon: boolean;
23
+ width?: string;
24
+ data: {
25
+ interval: number;
26
+ show: boolean;
27
+ };
28
+ }