@campxdev/campx-web-utils 0.3.10 → 0.3.11-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@campxdev/campx-web-utils",
3
- "version": "0.3.10",
3
+ "version": "0.3.11-alpha.1",
4
4
  "main": "./export.ts",
5
5
  "private": false,
6
6
  "peerDependencies": {
@@ -14,7 +14,7 @@
14
14
  "react-redux": "=>9.1.2"
15
15
  },
16
16
  "dependencies": {
17
- "@campxdev/react-blueprint": "1.6.0",
17
+ "@campxdev/react-blueprint": "git+ssh://git@bitbucket.org:campx1/react-blueprint.git#2028c08966109227a8c2653354f595a2137d86d3",
18
18
  "@hookform/resolvers": "^3.9.0",
19
19
  "@mui/x-date-pickers": "^7.22.1",
20
20
  "axios": "^1.7.2",
@@ -88,12 +88,12 @@ export function ChangePassword({ close }: ChangePasswordProps) {
88
88
  return (
89
89
  <form onSubmit={handleSubmit(onSubmit)}>
90
90
  <FormControlWrapper control={control}>
91
- <Stack gap={2} direction="column">
91
+ <Stack gap={1} direction="column">
92
92
  {fields.map((item) => {
93
93
  return (
94
94
  <>
95
95
  <TextField
96
- label={item.label || 'hey test'}
96
+ label={item.label}
97
97
  name={item.name}
98
98
  type={showPassword[item.name] ? 'text' : 'password'}
99
99
  required
@@ -111,9 +111,9 @@ export function ChangePassword({ close }: ChangePasswordProps) {
111
111
  edge="end"
112
112
  >
113
113
  {showPassword[item.name] ? (
114
- <VisibilityOff />
115
- ) : (
116
114
  <Visibility />
115
+ ) : (
116
+ <VisibilityOff />
117
117
  )}
118
118
  </IconButton>
119
119
  </InputAdornment>
@@ -124,7 +124,7 @@ export function ChangePassword({ close }: ChangePasswordProps) {
124
124
  );
125
125
  })}
126
126
 
127
- <Stack direction={'row'} gap={2} sx={{ marginTop: '20px' }}>
127
+ <Stack direction={'row'} gap={2} sx={{ marginTop: '15px' }}>
128
128
  <Button variant="outlined" onClick={close}>
129
129
  Cancel
130
130
  </Button>
@@ -1,6 +1,11 @@
1
- import { lightTheme, MuiThemeProvider, store } from '@campxdev/react-blueprint';
1
+ import { lightTheme, MuiThemeProvider } from '@campxdev/react-blueprint';
2
2
  import { LocalizationProvider } from '@mui/x-date-pickers';
3
3
  import { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFnsV3';
4
+ import {
5
+ combineReducers,
6
+ configureStore,
7
+ ReducersMapObject,
8
+ } from '@reduxjs/toolkit';
4
9
  import Cookies from 'js-cookie';
5
10
  import { ReactNode, useEffect } from 'react';
6
11
  import { QueryClient, QueryClientProvider } from 'react-query';
@@ -13,10 +18,12 @@ export const Providers = ({
13
18
  children,
14
19
  basename,
15
20
  theme = lightTheme,
21
+ reducers = {},
16
22
  }: {
17
23
  children: ReactNode;
18
24
  basename?: string;
19
25
  theme?: any;
26
+ reducers?: ReducersMapObject;
20
27
  }) => {
21
28
  const queryClient = new QueryClient({
22
29
  defaultOptions: {
@@ -43,6 +50,10 @@ export const Providers = ({
43
50
  }
44
51
  }, [institutionCode, tenantCode]);
45
52
 
53
+ const store = configureStore({
54
+ reducer: combineReducers(reducers),
55
+ });
56
+
46
57
  return (
47
58
  <Provider store={store}>
48
59
  <BrowserRouter basename={basename ?? baseName}>