@akinon/pz-masterpass 1.34.0 → 1.35.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.
- package/CHANGELOG.md +6 -0
- package/package.json +1 -1
- package/src/views/otp-modal/index.tsx +6 -2
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
|
@@ -10,7 +10,7 @@ import { formCreator } from '../../utils';
|
|
|
10
10
|
import CountdownTimer from '../countdown-timer/countdown-timer';
|
|
11
11
|
import { OtpForm, OtpFormProps, defaultTranslations } from './otp-form';
|
|
12
12
|
import { useAppDispatch, useAppSelector } from '@akinon/next/redux/hooks';
|
|
13
|
-
import { setOtpResponse } from '../../redux/reducer';
|
|
13
|
+
import { setOtpModalVisible, setOtpResponse } from '../../redux/reducer';
|
|
14
14
|
import { Image } from '@akinon/next/components/image';
|
|
15
15
|
|
|
16
16
|
export interface MasterpassOtpModalProps {
|
|
@@ -97,6 +97,10 @@ export const MasterpassOtpModal = ({
|
|
|
97
97
|
setOtpTime(otpTimeout + nowInMs);
|
|
98
98
|
};
|
|
99
99
|
|
|
100
|
+
const handleModalVisibility = (visibility: boolean) => {
|
|
101
|
+
dispatch(setOtpModalVisible(visibility));
|
|
102
|
+
};
|
|
103
|
+
|
|
100
104
|
useEffect(() => {
|
|
101
105
|
setIsModalOpen(otp.isModalVisible);
|
|
102
106
|
}, [otp.isModalVisible]);
|
|
@@ -119,7 +123,7 @@ export const MasterpassOtpModal = ({
|
|
|
119
123
|
/>
|
|
120
124
|
}
|
|
121
125
|
open={isModalOpen}
|
|
122
|
-
setOpen={
|
|
126
|
+
setOpen={handleModalVisibility}
|
|
123
127
|
className="w-full sm:w-[28rem] max-h-[90vh] overflow-y-auto"
|
|
124
128
|
>
|
|
125
129
|
<div className="px-6 py-4">
|