@stokr/components-library 3.0.77 → 3.1.0-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/dist/components/Input/InputPassword.js +3 -5
- package/dist/components/Input/OtpInput.js +1 -3
- package/dist/components/MenuNav/MenuNav.styles.js +1 -2
- package/dist/components/Modal/Modal.styles.js +2 -3
- package/dist/components/Newsletter/Newsletter.js +1 -3
- package/dist/components/NotificationCounter/NotificationCounter.styles.js +1 -2
- package/dist/components/SmartLink/SmartLink.js +0 -2
- package/dist/components/StepController/StepController.js +3 -5
- package/dist/components/StepController/StepController.styles.js +102 -1
- package/dist/components/StepController/StepControllerProgress.js +1 -1
- package/dist/components/Switch/Switch.js +1 -3
- package/dist/components/ToDoList/ToDoListTask.js +15 -3
- package/dist/components/taxId/register-taxid.js +7 -5
- package/dist/index.js +67 -141
- package/dist/runtime-config.js +4 -70
- package/dist/styles/global.js +1 -2
- package/dist/utils/check-todo-status.js +1 -2
- package/package.json +8 -14
- package/dist/api/authenticationApi.js +0 -13
- package/dist/auth/index.js +0 -34
- package/dist/components/2FA/Connect2FA.js +0 -58
- package/dist/components/2FA/EnterCode.js +0 -74
- package/dist/components/2FA/InstallAuthApp.js +0 -68
- package/dist/components/2FA/ResetCode.js +0 -34
- package/dist/components/2FA/Sucess2FA.js +0 -63
- package/dist/components/2FA/disable-2fa-flow.js +0 -104
- package/dist/components/2FA/enable-2fa-flow.js +0 -167
- package/dist/components/2FA/login-with-otp-flow.js +0 -262
- package/dist/components/2FA/main-flow.js +0 -273
- package/dist/components/Footer/Footer.js +0 -69
- package/dist/components/Footer/Footer.styles.js +0 -277
- package/dist/components/Footer/FooterLayout.js +0 -150
- package/dist/components/Footer/FooterMenu.js +0 -107
- package/dist/components/Footer/FooterMenu.styles.js +0 -334
- package/dist/components/ForgotPasswordModal/ForgotPasswordModal.js +0 -121
- package/dist/components/Header/Header.js +0 -441
- package/dist/components/Header/Header.styles.js +0 -568
- package/dist/components/Layout/Layout.js +0 -76
- package/dist/components/LoginModal/LoginModal.js +0 -165
- package/dist/components/MainMenu/DynamicMainMenu.js +0 -38
- package/dist/components/MainMenu/MainMenu.js +0 -220
- package/dist/components/MainMenu/MainMenu.styles.js +0 -362
- package/dist/components/Modal/NewVentureModal/NewVentureModal.js +0 -273
- package/dist/components/RegisterConfirmModal/RegisterConfirmModal.js +0 -74
- package/dist/components/RegisterConfirmModal/RegisterConfirmModal.styles.js +0 -20
- package/dist/components/RegisterModal/RegisterModal.js +0 -278
- package/dist/components/ResetConfirmModal/ResetConfirmModal.js +0 -40
- package/dist/components/ResetConfirmModal/ResetConfirmModal.styles.js +0 -41
- package/dist/components/ResetPasswordModal/ResetPasswordModal.js +0 -145
- package/dist/components/StepsProgress/StepIndicator.js +0 -40
- package/dist/components/StepsProgress/StepIndicator.styles.js +0 -69
- package/dist/components/StepsProgress/StepsProgress.js +0 -67
- package/dist/components/StepsProgress/StepsProgress.styles.js +0 -105
- package/dist/components/TermsModal/TermsModal.js +0 -145
- package/dist/components/TermsModal/_styles.js +0 -313
- package/dist/components/VerifyEmailModal/VerifyEmailModal.js +0 -122
- package/dist/components/headerHo/HeaderHo.js +0 -707
- package/dist/config.js +0 -33
- package/dist/context/Auth.js +0 -423
- package/dist/context/AuthContext.js +0 -1016
- package/dist/firebase-config.js +0 -56
- package/dist/hooks/useNewVentureForm.js +0 -235
- package/dist/static/images/background3.png.js +0 -4
- package/dist/static/images/google_auth.png.js +0 -4
- package/dist/static/images/iso27001-black.svg.js +0 -4
- package/dist/static/images/mangopay.svg.js +0 -4
- package/dist/static/images/social/Facebook_Logo.png.js +0 -4
- package/dist/static/images/social/LI-In-Bug.png.js +0 -4
- package/dist/static/images/social/Telegram-Logo.png.js +0 -4
- package/dist/static/images/social/X-logo-black.png.js +0 -4
- package/dist/static/images/social/youtube_social_circle_red.png.js +0 -4
- package/dist/utils/show-account-locked-modal.js +0 -23
- package/dist/utils/user-identity.js +0 -10
- package/dist/utils/withRouter.js +0 -26
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { useState, useEffect } from "react";
|
|
3
3
|
import PropTypes from "prop-types";
|
|
4
|
-
import stdin_default
|
|
4
|
+
import stdin_default from "../SvgIcons/CapsLockSvg.js";
|
|
5
5
|
import { InfoIcon } from "../InfoIcon/InfoIcon.js";
|
|
6
6
|
import { Wrapper, Label, InputWrap } from "./Input.styles.js";
|
|
7
7
|
import { getPasswordEntropy, ENTROPY_WEAK, ENTROPY_MEDIUM } from "../../utils/password-validation.js";
|
|
@@ -105,7 +105,7 @@ const InputPassword = (props) => {
|
|
|
105
105
|
// )
|
|
106
106
|
/* @__PURE__ */ jsx(Fragment, {})
|
|
107
107
|
),
|
|
108
|
-
/* @__PURE__ */ jsx(CapslockIndicator, { children: isCapslockOn && /* @__PURE__ */ jsx(stdin_default
|
|
108
|
+
/* @__PURE__ */ jsx(CapslockIndicator, { children: isCapslockOn && /* @__PURE__ */ jsx(stdin_default, {}) })
|
|
109
109
|
] })
|
|
110
110
|
] });
|
|
111
111
|
};
|
|
@@ -124,9 +124,7 @@ InputPassword.propTypes = {
|
|
|
124
124
|
autoComplete: PropTypes.string,
|
|
125
125
|
toggleDataCy: PropTypes.string
|
|
126
126
|
};
|
|
127
|
-
var stdin_default = InputPassword;
|
|
128
127
|
export {
|
|
129
128
|
InputPassword,
|
|
130
|
-
PasswordStrength
|
|
131
|
-
stdin_default as default
|
|
129
|
+
PasswordStrength
|
|
132
130
|
};
|
|
@@ -393,7 +393,7 @@ const ModalLink = styled(Link)`
|
|
|
393
393
|
}
|
|
394
394
|
}
|
|
395
395
|
`;
|
|
396
|
-
|
|
396
|
+
styled.div`
|
|
397
397
|
display: flex;
|
|
398
398
|
flex-direction: column;
|
|
399
399
|
height: 100%;
|
|
@@ -453,6 +453,5 @@ export {
|
|
|
453
453
|
ModalLink,
|
|
454
454
|
ModalLinkWrap,
|
|
455
455
|
ModalRoot,
|
|
456
|
-
ModalScroll
|
|
457
|
-
ModalWrapper
|
|
456
|
+
ModalScroll
|
|
458
457
|
};
|
|
@@ -2,7 +2,7 @@ import { jsxs, jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import PropTypes from "prop-types";
|
|
3
3
|
import { Transition } from "../../utils/transition.js";
|
|
4
4
|
import React__default, { PureComponent, Fragment } from "react";
|
|
5
|
-
import stdin_default
|
|
5
|
+
import stdin_default from "./StepControllerProgress.js";
|
|
6
6
|
import { StepsProgressContainer, StepContainer } from "./StepController.styles.js";
|
|
7
7
|
const timeout = 300;
|
|
8
8
|
const getTransitionStyles = {
|
|
@@ -30,7 +30,7 @@ class StepController extends PureComponent {
|
|
|
30
30
|
const { children, stepsProgressList, currentStep, activeStepIndex, doneStepsIndexes, touchedStepsIndexes } = this.props;
|
|
31
31
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
32
32
|
/* @__PURE__ */ jsx(StepsProgressContainer, { children: /* @__PURE__ */ jsx(
|
|
33
|
-
stdin_default
|
|
33
|
+
stdin_default,
|
|
34
34
|
{
|
|
35
35
|
activeStepIndex,
|
|
36
36
|
doneStepsIndexes,
|
|
@@ -77,8 +77,6 @@ StepController.propTypes = {
|
|
|
77
77
|
doneStepsIndexes: PropTypes.arrayOf(PropTypes.number).isRequired,
|
|
78
78
|
changeStep: PropTypes.func.isRequired
|
|
79
79
|
};
|
|
80
|
-
var stdin_default = StepController;
|
|
81
80
|
export {
|
|
82
|
-
StepController
|
|
83
|
-
stdin_default as default
|
|
81
|
+
StepController
|
|
84
82
|
};
|
|
@@ -1,6 +1,103 @@
|
|
|
1
1
|
import styled from "styled-components";
|
|
2
2
|
import rwd from "../../styles/rwd.js";
|
|
3
3
|
import theme from "../../styles/theme.js";
|
|
4
|
+
import { colors } from "../../styles/colors.js";
|
|
5
|
+
const Container = styled.div`
|
|
6
|
+
display: block;
|
|
7
|
+
width: 100%;
|
|
8
|
+
height: 100%;
|
|
9
|
+
`;
|
|
10
|
+
const Wrap = styled.div`
|
|
11
|
+
display: block;
|
|
12
|
+
margin: 0 auto;
|
|
13
|
+
`;
|
|
14
|
+
const Items = styled.div`
|
|
15
|
+
display: flex;
|
|
16
|
+
height: 100%;
|
|
17
|
+
font-size: 0;
|
|
18
|
+
flex-direction: row;
|
|
19
|
+
flex-wrap: nowrap;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
margin: 0 -6px;
|
|
22
|
+
text-align: center;
|
|
23
|
+
|
|
24
|
+
${rwd.Medium`
|
|
25
|
+
display: block;
|
|
26
|
+
`}
|
|
27
|
+
`;
|
|
28
|
+
const Item = styled.div.withConfig({
|
|
29
|
+
shouldForwardProp: (props) => !["isDone", "isActive"].includes(props)
|
|
30
|
+
})`
|
|
31
|
+
position: relative;
|
|
32
|
+
display: inline-block;
|
|
33
|
+
vertical-align: middle;
|
|
34
|
+
padding: 0;
|
|
35
|
+
flex: 1;
|
|
36
|
+
margin: 0 4px;
|
|
37
|
+
height: 32px;
|
|
38
|
+
max-width: 32px;
|
|
39
|
+
cursor: pointer;
|
|
40
|
+
|
|
41
|
+
&:before {
|
|
42
|
+
z-index: 0;
|
|
43
|
+
content: '';
|
|
44
|
+
display: block;
|
|
45
|
+
width: 100%;
|
|
46
|
+
height: 4px;
|
|
47
|
+
position: absolute;
|
|
48
|
+
top: 14px;
|
|
49
|
+
left: 0;
|
|
50
|
+
border-radius: 3px;
|
|
51
|
+
box-shadow: inset 0 1px 3px 0 rgba(0, 0, 0, 0.05);
|
|
52
|
+
background-color: ${colors.lightGrey};
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
&:after {
|
|
56
|
+
z-index: 1;
|
|
57
|
+
content: '';
|
|
58
|
+
display: block;
|
|
59
|
+
width: 100%;
|
|
60
|
+
height: 4px;
|
|
61
|
+
position: absolute;
|
|
62
|
+
top: 14px;
|
|
63
|
+
left: 0;
|
|
64
|
+
border-radius: 3px;
|
|
65
|
+
background-color: transparent;
|
|
66
|
+
transition: background-color 0.2s;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
&:focus {
|
|
70
|
+
outline: none;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
&:hover:after {
|
|
74
|
+
background-color: ${colors.black};
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
${(props) => props.isDone && `
|
|
78
|
+
&:after {
|
|
79
|
+
background-color: ${colors.progressGreen};
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
&:hover:after {
|
|
83
|
+
background-color: ${colors.black};
|
|
84
|
+
}
|
|
85
|
+
`}
|
|
86
|
+
|
|
87
|
+
${(props) => props.isActive && `
|
|
88
|
+
&:after {
|
|
89
|
+
background-color: ${colors.grey2};
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
&:hover:after {
|
|
93
|
+
background-color: ${colors.black};
|
|
94
|
+
}
|
|
95
|
+
`}
|
|
96
|
+
|
|
97
|
+
${rwd.Medium`
|
|
98
|
+
width: 32px;
|
|
99
|
+
`}
|
|
100
|
+
`;
|
|
4
101
|
const StepsProgressContainer = styled.div`
|
|
5
102
|
position: relative;
|
|
6
103
|
width: 100%;
|
|
@@ -29,6 +126,10 @@ const StepContainer = styled.div.withConfig({
|
|
|
29
126
|
`}
|
|
30
127
|
`;
|
|
31
128
|
export {
|
|
129
|
+
Container,
|
|
130
|
+
Item,
|
|
131
|
+
Items,
|
|
32
132
|
StepContainer,
|
|
33
|
-
StepsProgressContainer
|
|
133
|
+
StepsProgressContainer,
|
|
134
|
+
Wrap
|
|
34
135
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
3
|
import PropTypes from "prop-types";
|
|
4
|
-
import { Container, Wrap, Items, Item } from "
|
|
4
|
+
import { Container, Wrap, Items, Item } from "./StepController.styles.js";
|
|
5
5
|
const StepControllerProgress = ({
|
|
6
6
|
touchedStepsIndexes,
|
|
7
7
|
doneStepsIndexes,
|
|
@@ -5,7 +5,6 @@ import { Tooltip } from "../Tooltip/Tooltip.js";
|
|
|
5
5
|
import { Container, IconContainer, Icon, Content, TitleContainer, Title, State } from "./ToDoListTask.styles.js";
|
|
6
6
|
import { TooltipIcon } from "../Icon/Icon.style.js";
|
|
7
7
|
import setRedirectCookie from "../../utils/set-redirect-cookie.js";
|
|
8
|
-
import { AuthProvider } from "../../context/AuthContext.js";
|
|
9
8
|
import { ToDoModal } from "./ToDoList.js";
|
|
10
9
|
import stdin_default$1 from "../taxId/flow.js";
|
|
11
10
|
const ToDoTask = ({
|
|
@@ -19,7 +18,11 @@ const ToDoTask = ({
|
|
|
19
18
|
disabled,
|
|
20
19
|
openModal,
|
|
21
20
|
redirectCookie = false,
|
|
22
|
-
onTaxIdComplete
|
|
21
|
+
onTaxIdComplete,
|
|
22
|
+
/** @deprecated Passed through to RegisterTaxIdFlow's tax-id form when openModal is TAX_ID. */
|
|
23
|
+
user,
|
|
24
|
+
/** @deprecated Passed through to RegisterTaxIdFlow's tax-id form when openModal is TAX_ID. */
|
|
25
|
+
updateUser
|
|
23
26
|
}) => {
|
|
24
27
|
const [modalOpen, setmodalOpen] = React__default.useState(false);
|
|
25
28
|
const handleOpenModal = () => {
|
|
@@ -58,7 +61,16 @@ const ToDoTask = ({
|
|
|
58
61
|
message ? /* @__PURE__ */ jsx(State, { children: message }) : ""
|
|
59
62
|
] })
|
|
60
63
|
] }),
|
|
61
|
-
modalOpen &&
|
|
64
|
+
modalOpen && openModal === ToDoModal.TAX_ID && /* @__PURE__ */ jsx(
|
|
65
|
+
stdin_default$1,
|
|
66
|
+
{
|
|
67
|
+
showFlow: modalOpen,
|
|
68
|
+
setShowFlow: setmodalOpen,
|
|
69
|
+
onComplete: onTaxIdComplete,
|
|
70
|
+
user,
|
|
71
|
+
updateUser
|
|
72
|
+
}
|
|
73
|
+
)
|
|
62
74
|
] });
|
|
63
75
|
};
|
|
64
76
|
ToDoTask.propTypes = {
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { useState } from "react";
|
|
3
3
|
import { useNavigate } from "react-router-dom";
|
|
4
|
-
import { AuthContext } from "../../context/AuthContext.js";
|
|
5
4
|
import { track } from "../../analytics/index.js";
|
|
6
5
|
import { Text } from "../Text/Text.styles.js";
|
|
7
6
|
import * as Yup from "yup";
|
|
@@ -53,10 +52,13 @@ const RegisterTaxId = ({
|
|
|
53
52
|
backButtonText = "Back to verify identity",
|
|
54
53
|
textHeader = defaultTextHeader,
|
|
55
54
|
textFieldLabel = "enter your tax id",
|
|
56
|
-
faqItems = defaultFaqItems
|
|
55
|
+
faqItems = defaultFaqItems,
|
|
56
|
+
/** @deprecated Consumer no longer provides a local AuthContext — pass the authenticated user object explicitly. */
|
|
57
|
+
user = {},
|
|
58
|
+
/** @deprecated Consumer no longer provides a local AuthContext — pass the update-user function explicitly. */
|
|
59
|
+
updateUser
|
|
57
60
|
}) => {
|
|
58
61
|
let navigate = useNavigate();
|
|
59
|
-
const { user = {}, updateUser } = useContext(AuthContext);
|
|
60
62
|
const { taxId } = user;
|
|
61
63
|
const [isUpdatingUser, setIsUpdatingUser] = useState(false);
|
|
62
64
|
const [error, setError] = useState("");
|
|
@@ -69,7 +71,7 @@ const RegisterTaxId = ({
|
|
|
69
71
|
const handleOnSubmit = async (e) => {
|
|
70
72
|
setIsUpdatingUser(true);
|
|
71
73
|
try {
|
|
72
|
-
await updateUser({
|
|
74
|
+
await updateUser?.({
|
|
73
75
|
taxId: e.taxId
|
|
74
76
|
});
|
|
75
77
|
track("tax_id_form_submitted_success");
|