@stokr/components-library 3.0.76 → 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/README.md +177 -177
- 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.js +6 -3
- package/dist/components/Modal/Modal.styles.js +2 -3
- package/dist/components/Modal/SuccessModal/SuccessModal.js +6 -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/manifest.json +25 -25
- package/dist/robots.txt +3 -3
- package/dist/runtime-config.js +5 -71
- package/dist/static/fonts/icomoon/icomoon.eot +0 -0
- package/dist/static/fonts/icomoon/icomoon.svg +52 -52
- package/dist/static/fonts/icomoon/icomoon.ttf +0 -0
- package/dist/static/fonts/icomoon/icomoon.woff +0 -0
- package/dist/static/fonts/icomoon/selection.json +0 -0
- package/dist/static/fonts/icomoon/style.css +0 -0
- package/dist/static/images/Glassess.svg +5 -5
- package/dist/static/images/add-folder-icon.svg +4 -4
- package/dist/static/images/arrow-down-black.svg +21 -21
- package/dist/static/images/check-icon.svg +3 -3
- package/dist/static/images/checkmark-circle-icon.svg +3 -3
- package/dist/static/images/close-circle-icon.svg +2 -2
- package/dist/static/images/copy_icon.svg +4 -4
- package/dist/static/images/cross-icon.svg +3 -3
- package/dist/static/images/currency/eth.svg +10 -10
- package/dist/static/images/currency/eth_logo.svg +8 -8
- package/dist/static/images/currency/eur.svg +4 -4
- package/dist/static/images/currency/eur.svg.js +1 -1
- package/dist/static/images/currency/usd.svg +4 -4
- package/dist/static/images/currency/usd.svg.js +1 -1
- package/dist/static/images/currency/usdc-logo.svg +5 -5
- package/dist/static/images/doc-icon.svg +3 -3
- package/dist/static/images/download_icon.svg +3 -3
- package/dist/static/images/external-link-icon.svg +3 -3
- package/dist/static/images/filter-icon.svg +6 -6
- package/dist/static/images/globe.svg +15 -15
- package/dist/static/images/mangopay.svg +20 -20
- package/dist/static/images/numbers/number_eight.svg +3 -3
- package/dist/static/images/numbers/number_five.svg +4 -4
- package/dist/static/images/numbers/number_four.svg +3 -3
- package/dist/static/images/numbers/number_nine.svg +4 -4
- package/dist/static/images/numbers/number_one.svg +4 -4
- package/dist/static/images/numbers/number_seven.svg +4 -4
- package/dist/static/images/numbers/number_six.svg +4 -4
- package/dist/static/images/numbers/number_three.svg +3 -3
- package/dist/static/images/numbers/number_two.svg +4 -4
- package/dist/static/images/numbers/number_zero.svg +3 -3
- package/dist/static/images/plus-icon.svg +4 -4
- package/dist/static/images/prof-inv.svg +3 -3
- package/dist/static/images/search-icon.svg +3 -3
- package/dist/static/images/transfer-icon.svg +10 -10
- package/dist/static/images/trash.svg +16 -16
- package/dist/static/images/upload.svg +5 -5
- package/dist/static/images/warning-filled.svg +3 -3
- package/dist/styles/global.js +1 -2
- package/dist/utils/check-todo-status.js +1 -2
- package/package.json +137 -143
- 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,441 +0,0 @@
|
|
|
1
|
-
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { useMemo, useState, useEffect } from "react";
|
|
3
|
-
import PropTypes from "prop-types";
|
|
4
|
-
import stdin_default$1 from "../SmartLink/SmartLink.js";
|
|
5
|
-
import stdin_default$3 from "../Button/Button.styles.js";
|
|
6
|
-
import stdin_default$2 from "../SvgIcons/LogoSvg.js";
|
|
7
|
-
import { MenuNav } from "../MenuNav/MenuNav.styles.js";
|
|
8
|
-
import stdin_default$5 from "../MainMenu/MainMenu.js";
|
|
9
|
-
import { StepsProgressSignup, StepsProgressHeader } from "../StepsProgress/StepsProgress.js";
|
|
10
|
-
import { NotificationCounter } from "../NotificationCounter/NotificationCounter.styles.js";
|
|
11
|
-
import avatarPlaceholder from "../../static/images/avatar-placeholder.png.js";
|
|
12
|
-
import { StyledHeader, SidebarToggle, HamburgerIcon, HeaderInner, MainNavWrap, Logo, HeaderMainNav, ProgressWrap, QuickNavWrap, MobileMenuToggler, HeaderQuickNav, LoginButton, UserAccount, UserButton, SignupButton, MobileMenu, MobileMenuPart, MobileMenuItem, MobileMenuLink, CTAContainer, SocialLinksContainer, UserAvatar, MobileMenuWrapper, StyledSubMenu } from "./Header.styles.js";
|
|
13
|
-
import stdin_default$4 from "../MainMenu/DynamicMainMenu.js";
|
|
14
|
-
import { SocialLink, ArrowDown } from "../Footer/FooterMenu.styles.js";
|
|
15
|
-
import { Collapse } from "react-collapse";
|
|
16
|
-
import { usePrevious, useMobileView } from "../../utils/customHooks.js";
|
|
17
|
-
import { checkTodoStatus } from "../../utils/check-todo-status.js";
|
|
18
|
-
import { hasLoggedInSession } from "../../utils/user-identity.js";
|
|
19
|
-
import { socialSvg } from "../Footer/FooterMenu.js";
|
|
20
|
-
import { Wrapper, FlexContainer } from "../Grid/Grid.styles.js";
|
|
21
|
-
import { getFooterGroups } from "../Footer/FooterLayout.js";
|
|
22
|
-
import { getPlatformURL, getConfig } from "../../runtime-config.js";
|
|
23
|
-
import { withRouter } from "../../utils/withRouter.js";
|
|
24
|
-
import { sizes } from "../../styles/rwd.js";
|
|
25
|
-
import { track } from "../../analytics/index.js";
|
|
26
|
-
import { navigateToHref } from "../../routing/navigate-app.js";
|
|
27
|
-
import { Breakdown } from "../breakdown/Breakdown.js";
|
|
28
|
-
const UserAvatarComponent = ({ avatar }) => /* @__PURE__ */ jsx(UserAvatar, { src: avatar || avatarPlaceholder });
|
|
29
|
-
const RenderSubMenu = ({
|
|
30
|
-
title,
|
|
31
|
-
isActive,
|
|
32
|
-
subMenuItems = [],
|
|
33
|
-
onClick = () => {
|
|
34
|
-
},
|
|
35
|
-
_platformURL = "",
|
|
36
|
-
platformURL: platformURLProp = ""
|
|
37
|
-
}) => {
|
|
38
|
-
const basePlatformUrl = _platformURL || platformURLProp;
|
|
39
|
-
return /* @__PURE__ */ jsxs(MobileMenuWrapper, { onClick, children: [
|
|
40
|
-
/* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsxs(StyledSubMenu, { children: [
|
|
41
|
-
/* @__PURE__ */ jsx("a", { children: title }),
|
|
42
|
-
/* @__PURE__ */ jsx(ArrowDown, { displayAlways: true, isOpened: isActive, style: { right: "-2em", position: "absolute" } })
|
|
43
|
-
] }) }),
|
|
44
|
-
/* @__PURE__ */ jsx(Collapse, { isOpened: isActive, children: subMenuItems.map((item) => /* @__PURE__ */ jsx(MobileMenuItem, { red: true, children: /* @__PURE__ */ jsx(MobileMenuLink, { to: basePlatformUrl + item.link, children: item.name }) }, item.name)) })
|
|
45
|
-
] });
|
|
46
|
-
};
|
|
47
|
-
function HeaderView({
|
|
48
|
-
navigate = null,
|
|
49
|
-
activeMenu = null,
|
|
50
|
-
activateMenu = () => {
|
|
51
|
-
},
|
|
52
|
-
user = {},
|
|
53
|
-
userPhoto = avatarPlaceholder,
|
|
54
|
-
logoutUser = () => {
|
|
55
|
-
},
|
|
56
|
-
onLoginClick = () => {
|
|
57
|
-
},
|
|
58
|
-
onSignUpClick = () => {
|
|
59
|
-
},
|
|
60
|
-
useRelativePathForMenu = false,
|
|
61
|
-
useRelativePathForUserMenu = false,
|
|
62
|
-
progress = null,
|
|
63
|
-
withSidebar = false,
|
|
64
|
-
isSidebarExpanded = false,
|
|
65
|
-
sidebarHandler = () => {
|
|
66
|
-
},
|
|
67
|
-
signupFlow = false,
|
|
68
|
-
noFixedPosition = false,
|
|
69
|
-
withoutLoginSignupButton = false
|
|
70
|
-
}) {
|
|
71
|
-
const platformURL = getPlatformURL();
|
|
72
|
-
const productMenuItems = useMemo(
|
|
73
|
-
() => [
|
|
74
|
-
{
|
|
75
|
-
name: "End-to-End Tokenization",
|
|
76
|
-
onClick: () => {
|
|
77
|
-
track("header_link_clicked", { link: "end-to-end tokenization" });
|
|
78
|
-
navigateToHref(navigate, `${platformURL}/solutions/asset-tokenization`);
|
|
79
|
-
},
|
|
80
|
-
link: "/solutions/asset-tokenization"
|
|
81
|
-
},
|
|
82
|
-
{
|
|
83
|
-
name: "Tokenization-as-a-Service",
|
|
84
|
-
onClick: () => {
|
|
85
|
-
track("header_link_clicked", { link: "tokenization-as-a-service" });
|
|
86
|
-
navigateToHref(navigate, `${platformURL}/solutions/tokenization-as-service`);
|
|
87
|
-
},
|
|
88
|
-
link: "/solutions/tokenization-as-service"
|
|
89
|
-
}
|
|
90
|
-
],
|
|
91
|
-
[navigate, platformURL]
|
|
92
|
-
);
|
|
93
|
-
const mediaMenuItems = useMemo(
|
|
94
|
-
() => [
|
|
95
|
-
{
|
|
96
|
-
name: "Press Releases",
|
|
97
|
-
onClick: () => {
|
|
98
|
-
track("header_link_clicked", { link: "press releases" });
|
|
99
|
-
navigateToHref(navigate, `${platformURL}/press-releases`);
|
|
100
|
-
},
|
|
101
|
-
link: "/press-releases"
|
|
102
|
-
},
|
|
103
|
-
{
|
|
104
|
-
name: "Stoke Post",
|
|
105
|
-
onClick: () => {
|
|
106
|
-
track("header_link_clicked", { link: "stoke post" });
|
|
107
|
-
navigateToHref(navigate, `${platformURL}/stoke-post`);
|
|
108
|
-
},
|
|
109
|
-
link: "/stoke-post"
|
|
110
|
-
}
|
|
111
|
-
],
|
|
112
|
-
[navigate, platformURL]
|
|
113
|
-
);
|
|
114
|
-
const [currentActiveMenu, setcurrentActiveMenu] = useState(null);
|
|
115
|
-
const [currentActiveSubMenu, setcurrentActiveSubMenu] = useState(null);
|
|
116
|
-
const prevActiveMenu = usePrevious(activeMenu);
|
|
117
|
-
const isMobile = useMobileView(sizes.MLarge);
|
|
118
|
-
useEffect(() => {
|
|
119
|
-
return () => {
|
|
120
|
-
document.body.style.overflow = "unset";
|
|
121
|
-
document.body.style.position = "relative";
|
|
122
|
-
document.body.style.width = "auto";
|
|
123
|
-
document.documentElement.style.overflowY = "unset";
|
|
124
|
-
};
|
|
125
|
-
}, []);
|
|
126
|
-
useEffect(() => {
|
|
127
|
-
if (prevActiveMenu !== activeMenu) {
|
|
128
|
-
if (activeMenu !== null) {
|
|
129
|
-
setcurrentActiveMenu(null);
|
|
130
|
-
activateMenu();
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
}, [activeMenu, activateMenu]);
|
|
134
|
-
const toggleMenu = (type, mobile = false) => {
|
|
135
|
-
if (activeMenu === false) {
|
|
136
|
-
setcurrentActiveMenu(null);
|
|
137
|
-
}
|
|
138
|
-
const newActiveMenu = currentActiveMenu === type ? null : type;
|
|
139
|
-
if (isMobile) {
|
|
140
|
-
if (newActiveMenu) {
|
|
141
|
-
document.body.style.overflowY = "hidden";
|
|
142
|
-
document.documentElement.style.overflowY = "hidden";
|
|
143
|
-
document.body.style.position = "fixed";
|
|
144
|
-
document.body.style.width = "100%";
|
|
145
|
-
} else {
|
|
146
|
-
document.body.style.overflowY = "unset";
|
|
147
|
-
document.documentElement.style.overflowY = "unset";
|
|
148
|
-
document.body.style.position = "relative";
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
if (mobile && type !== "main") {
|
|
152
|
-
setcurrentActiveSubMenu(currentActiveSubMenu === type ? null : type);
|
|
153
|
-
} else {
|
|
154
|
-
setcurrentActiveMenu(newActiveMenu);
|
|
155
|
-
}
|
|
156
|
-
activateMenu();
|
|
157
|
-
};
|
|
158
|
-
const userType = user && user.user_type;
|
|
159
|
-
const isAdmin = userType === "company_pa" || userType === "company_sa" || userType === "sa";
|
|
160
|
-
const isVentureDashboard = withSidebar;
|
|
161
|
-
const socialLinks = getFooterGroups()?.filter((group) => group.social)[0]?.items || [];
|
|
162
|
-
const newPlatformUrl = useRelativePathForMenu ? "" : platformURL;
|
|
163
|
-
const newPlatformUrlForUserMenu = useRelativePathForUserMenu ? "" : getConfig("dashboardUrl");
|
|
164
|
-
return /* @__PURE__ */ jsx(StyledHeader, { noFixedPosition, children: /* @__PURE__ */ jsxs(Wrapper, { flex: withSidebar, children: [
|
|
165
|
-
withSidebar && /* @__PURE__ */ jsx(SidebarToggle, { isSidebarExpanded, onClick: sidebarHandler, children: /* @__PURE__ */ jsx(HamburgerIcon, {}) }),
|
|
166
|
-
/* @__PURE__ */ jsxs(HeaderInner, { withSidebar, children: [
|
|
167
|
-
/* @__PURE__ */ jsxs(MainNavWrap, { hasProgress: progress, children: [
|
|
168
|
-
/* @__PURE__ */ jsx(Logo, { isHighlight: currentActiveMenu === "main", children: /* @__PURE__ */ jsx(stdin_default$1, { to: useRelativePathForMenu ? "/" : platformURL, "data-cy": "logo-nav-link", "aria-label": "STOKR home", children: /* @__PURE__ */ jsx(stdin_default$2, {}) }) }),
|
|
169
|
-
!progress && /* @__PURE__ */ jsx(HeaderMainNav, { children: /* @__PURE__ */ jsx(MenuNav, { children: /* @__PURE__ */ jsxs("ul", { children: [
|
|
170
|
-
/* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
|
|
171
|
-
stdin_default$1,
|
|
172
|
-
{
|
|
173
|
-
to: newPlatformUrl + "/featured-assets",
|
|
174
|
-
"data-cy": "invest-nav-link",
|
|
175
|
-
onClick: () => track("header_link_clicked", { link: "invest" }),
|
|
176
|
-
children: "Invest"
|
|
177
|
-
}
|
|
178
|
-
) }),
|
|
179
|
-
/* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
|
|
180
|
-
"a",
|
|
181
|
-
{
|
|
182
|
-
onClick: () => {
|
|
183
|
-
track("header_link_clicked", { link: "solutions" });
|
|
184
|
-
toggleMenu("products");
|
|
185
|
-
},
|
|
186
|
-
"data-cy": "products-nav-link",
|
|
187
|
-
children: "Solutions"
|
|
188
|
-
}
|
|
189
|
-
) }),
|
|
190
|
-
/* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
|
|
191
|
-
"a",
|
|
192
|
-
{
|
|
193
|
-
onClick: () => {
|
|
194
|
-
track("header_link_clicked", { link: "media" });
|
|
195
|
-
toggleMenu("media");
|
|
196
|
-
},
|
|
197
|
-
"data-cy": "media-nav-link",
|
|
198
|
-
children: "Media"
|
|
199
|
-
}
|
|
200
|
-
) }),
|
|
201
|
-
/* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
|
|
202
|
-
stdin_default$1,
|
|
203
|
-
{
|
|
204
|
-
to: newPlatformUrl + "/team",
|
|
205
|
-
"data-cy": "team-nav-link",
|
|
206
|
-
onClick: () => track("header_link_clicked", { link: "team" }),
|
|
207
|
-
children: "Team"
|
|
208
|
-
}
|
|
209
|
-
) })
|
|
210
|
-
] }) }) })
|
|
211
|
-
] }),
|
|
212
|
-
progress && /* @__PURE__ */ jsx(Fragment, { children: signupFlow ? /* @__PURE__ */ jsx(StepsProgressSignup, { user }) : /* @__PURE__ */ jsx(ProgressWrap, { children: /* @__PURE__ */ jsx(
|
|
213
|
-
StepsProgressHeader,
|
|
214
|
-
{
|
|
215
|
-
items: progress.items,
|
|
216
|
-
doneIndex: progress.doneIndex,
|
|
217
|
-
activeIndex: progress.activeIndex
|
|
218
|
-
}
|
|
219
|
-
) }) }),
|
|
220
|
-
/* @__PURE__ */ jsxs(QuickNavWrap, { hasProgress: progress, children: [
|
|
221
|
-
/* @__PURE__ */ jsxs(
|
|
222
|
-
MobileMenuToggler,
|
|
223
|
-
{
|
|
224
|
-
isActive: currentActiveMenu === "main",
|
|
225
|
-
onClick: () => toggleMenu("main"),
|
|
226
|
-
withSidebar,
|
|
227
|
-
type: "button",
|
|
228
|
-
"aria-label": "Toggle navigation menu",
|
|
229
|
-
"aria-expanded": currentActiveMenu === "main",
|
|
230
|
-
children: [
|
|
231
|
-
/* @__PURE__ */ jsx("span", {}),
|
|
232
|
-
/* @__PURE__ */ jsx("span", {}),
|
|
233
|
-
/* @__PURE__ */ jsx("span", {})
|
|
234
|
-
]
|
|
235
|
-
}
|
|
236
|
-
),
|
|
237
|
-
isMobile && checkTodoStatus(user) > 0 && !signupFlow && /* @__PURE__ */ jsx(NotificationCounter, { mobile: true, isActive: currentActiveMenu === "main", children: checkTodoStatus(user) }),
|
|
238
|
-
/* @__PURE__ */ jsx(HeaderQuickNav, { isUserLogged: hasLoggedInSession(user), children: /* @__PURE__ */ jsx(Fragment, { children: hasLoggedInSession(user) ? /* @__PURE__ */ jsx(Fragment, { children: signupFlow ? /* @__PURE__ */ jsx(stdin_default$3, { onClick: logoutUser, children: "Log Out" }) : /* @__PURE__ */ jsxs(FlexContainer, { itemsCenter: true, children: [
|
|
239
|
-
/* @__PURE__ */ jsx(Breakdown, { children: /* @__PURE__ */ jsx(
|
|
240
|
-
LoginButton,
|
|
241
|
-
{
|
|
242
|
-
onClick: () => {
|
|
243
|
-
isAdmin ? navigateToHref(navigate, getConfig("adminUrl")) : !newPlatformUrlForUserMenu ? navigate("/overview") : navigateToHref(navigate, getConfig("dashboardUrl") + "/overview");
|
|
244
|
-
},
|
|
245
|
-
"data-cy": "dashboard-nav-link",
|
|
246
|
-
children: "Dashboard"
|
|
247
|
-
}
|
|
248
|
-
) }),
|
|
249
|
-
/* @__PURE__ */ jsxs(UserAccount, { children: [
|
|
250
|
-
/* @__PURE__ */ jsx(UserButton, { onClick: () => toggleMenu("main"), children: /* @__PURE__ */ jsx(UserAvatarComponent, { avatar: userPhoto }) }),
|
|
251
|
-
checkTodoStatus(user) > 0 && /* @__PURE__ */ jsx(NotificationCounter, { avatar: true, children: checkTodoStatus(user) })
|
|
252
|
-
] })
|
|
253
|
-
] }) }) : /* @__PURE__ */ jsx(Fragment, { children: withoutLoginSignupButton ? /* @__PURE__ */ jsx(Fragment, {}) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
254
|
-
/* @__PURE__ */ jsx(Breakdown, { children: /* @__PURE__ */ jsx(
|
|
255
|
-
LoginButton,
|
|
256
|
-
{
|
|
257
|
-
onClick: () => {
|
|
258
|
-
track("header_link_clicked", { link: "login" });
|
|
259
|
-
onLoginClick();
|
|
260
|
-
},
|
|
261
|
-
"data-cy": "login-nav-button",
|
|
262
|
-
children: "Log in"
|
|
263
|
-
}
|
|
264
|
-
) }),
|
|
265
|
-
/* @__PURE__ */ jsx(
|
|
266
|
-
SignupButton,
|
|
267
|
-
{
|
|
268
|
-
onClick: () => {
|
|
269
|
-
track("signup_cta_clicked");
|
|
270
|
-
onSignUpClick();
|
|
271
|
-
},
|
|
272
|
-
"data-cy": "signup-nav-button",
|
|
273
|
-
children: "Sign Up"
|
|
274
|
-
}
|
|
275
|
-
)
|
|
276
|
-
] }) }) }) })
|
|
277
|
-
] }),
|
|
278
|
-
/* @__PURE__ */ jsxs(MobileMenu, { isActive: currentActiveMenu === "main", withSidebar, children: [
|
|
279
|
-
/* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(MobileMenuPart, { withPadding: true, children: /* @__PURE__ */ jsx(MenuNav, { mobile: true, children: /* @__PURE__ */ jsxs("ul", { children: [
|
|
280
|
-
/* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsx(
|
|
281
|
-
MobileMenuLink,
|
|
282
|
-
{
|
|
283
|
-
to: newPlatformUrl + "/featured-assets",
|
|
284
|
-
"data-cy": "invest-nav-link",
|
|
285
|
-
onClick: () => toggleMenu("main"),
|
|
286
|
-
children: "Invest"
|
|
287
|
-
}
|
|
288
|
-
) }),
|
|
289
|
-
/* @__PURE__ */ jsx(
|
|
290
|
-
RenderSubMenu,
|
|
291
|
-
{
|
|
292
|
-
title: "solutions",
|
|
293
|
-
isActive: currentActiveSubMenu === "products",
|
|
294
|
-
subMenuItems: productMenuItems,
|
|
295
|
-
platformURL: newPlatformUrl,
|
|
296
|
-
onClick: () => {
|
|
297
|
-
toggleMenu("products", true);
|
|
298
|
-
}
|
|
299
|
-
}
|
|
300
|
-
),
|
|
301
|
-
/* @__PURE__ */ jsx(
|
|
302
|
-
RenderSubMenu,
|
|
303
|
-
{
|
|
304
|
-
title: "media",
|
|
305
|
-
isActive: currentActiveSubMenu === "media",
|
|
306
|
-
subMenuItems: mediaMenuItems,
|
|
307
|
-
platformURL: newPlatformUrl,
|
|
308
|
-
onClick: () => {
|
|
309
|
-
toggleMenu("media", true);
|
|
310
|
-
}
|
|
311
|
-
}
|
|
312
|
-
),
|
|
313
|
-
/* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsx(MobileMenuLink, { to: newPlatformUrl + "/team", onClick: () => toggleMenu("main"), children: "Team" }) })
|
|
314
|
-
] }) }) }) }),
|
|
315
|
-
hasLoggedInSession(user) ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
316
|
-
!signupFlow && /* @__PURE__ */ jsx(MobileMenuPart, { withPadding: true, flexColumn: true, borderTop: true, children: /* @__PURE__ */ jsx(MenuNav, { mobile: true, children: /* @__PURE__ */ jsx("ul", { children: isAdmin ? /* @__PURE__ */ jsx(Fragment, { children: isVentureDashboard ? /* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsx(stdin_default$1, { to: "/settings", children: "Settings" }) }) : /* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsx(stdin_default$1, { to: getConfig("adminUrl"), onClick: () => toggleMenu("main"), children: "Dashboard" }) }) }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
317
|
-
/* @__PURE__ */ jsxs(MobileMenuItem, { children: [
|
|
318
|
-
/* @__PURE__ */ jsx(
|
|
319
|
-
stdin_default$1,
|
|
320
|
-
{
|
|
321
|
-
to: `${newPlatformUrlForUserMenu}/overview`,
|
|
322
|
-
onClick: () => toggleMenu("main"),
|
|
323
|
-
children: "Dashboard"
|
|
324
|
-
}
|
|
325
|
-
),
|
|
326
|
-
checkTodoStatus(user) > 0 && /* @__PURE__ */ jsx(NotificationCounter, { mobileMenu: true, children: checkTodoStatus(user) })
|
|
327
|
-
] }),
|
|
328
|
-
/* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsx(
|
|
329
|
-
stdin_default$1,
|
|
330
|
-
{
|
|
331
|
-
to: `${newPlatformUrlForUserMenu}/settings/profile-and-privacy`,
|
|
332
|
-
onClick: () => toggleMenu("main"),
|
|
333
|
-
children: "Profile and Privacy"
|
|
334
|
-
}
|
|
335
|
-
) }),
|
|
336
|
-
/* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsx(
|
|
337
|
-
stdin_default$1,
|
|
338
|
-
{
|
|
339
|
-
to: `${newPlatformUrlForUserMenu}/settings/liquid-address`,
|
|
340
|
-
onClick: () => toggleMenu("main"),
|
|
341
|
-
children: "Liquid Addresses"
|
|
342
|
-
}
|
|
343
|
-
) }),
|
|
344
|
-
/* @__PURE__ */ jsx(MobileMenuItem, { children: /* @__PURE__ */ jsx(
|
|
345
|
-
stdin_default$1,
|
|
346
|
-
{
|
|
347
|
-
to: `${newPlatformUrlForUserMenu}/settings/investment-eligibility`,
|
|
348
|
-
onClick: () => toggleMenu("main"),
|
|
349
|
-
children: "Investment eligibility"
|
|
350
|
-
}
|
|
351
|
-
) })
|
|
352
|
-
] }) }) }) }),
|
|
353
|
-
/* @__PURE__ */ jsx(MobileMenuPart, { withPadding: true, flexColumn: true, noPaddingTop: !signupFlow, borderTop: signupFlow, isLast: true, children: /* @__PURE__ */ jsx(stdin_default$3, { minWidth: "160px", secondary: true, onClick: () => logoutUser(), children: "log out" }) })
|
|
354
|
-
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
355
|
-
withoutLoginSignupButton ? /* @__PURE__ */ jsx(Fragment, {}) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
356
|
-
/* @__PURE__ */ jsx(Breakdown, { alignCenter: true, children: /* @__PURE__ */ jsx(
|
|
357
|
-
stdin_default$3,
|
|
358
|
-
{
|
|
359
|
-
onClick: () => {
|
|
360
|
-
track("header_link_clicked", { link: "login" });
|
|
361
|
-
onLoginClick();
|
|
362
|
-
},
|
|
363
|
-
secondary: true,
|
|
364
|
-
isLoginMobile: true,
|
|
365
|
-
children: "Log in"
|
|
366
|
-
}
|
|
367
|
-
) }),
|
|
368
|
-
/* @__PURE__ */ jsx(
|
|
369
|
-
"div",
|
|
370
|
-
{
|
|
371
|
-
style: {
|
|
372
|
-
display: "flex",
|
|
373
|
-
justifyContent: "center",
|
|
374
|
-
paddingBottom: 30
|
|
375
|
-
},
|
|
376
|
-
children: /* @__PURE__ */ jsx(
|
|
377
|
-
SignupButton,
|
|
378
|
-
{
|
|
379
|
-
onClick: () => {
|
|
380
|
-
track("signup_cta_clicked");
|
|
381
|
-
onSignUpClick();
|
|
382
|
-
},
|
|
383
|
-
isMobile: true,
|
|
384
|
-
children: "Sign Up"
|
|
385
|
-
}
|
|
386
|
-
)
|
|
387
|
-
}
|
|
388
|
-
)
|
|
389
|
-
] }),
|
|
390
|
-
socialLinks.length > 0 && /* @__PURE__ */ jsxs(CTAContainer, { children: [
|
|
391
|
-
/* @__PURE__ */ jsx("span", { children: "FOLLOW US" }),
|
|
392
|
-
/* @__PURE__ */ jsx(SocialLinksContainer, { isHeader: true, children: socialLinks.map((item) => /* @__PURE__ */ jsx(SocialLink, { href: item.url, target: "_blank", rel: "noopener noreferrer", children: socialSvg[item.name] }, item.name)) })
|
|
393
|
-
] })
|
|
394
|
-
] })
|
|
395
|
-
] }),
|
|
396
|
-
/* @__PURE__ */ jsx(stdin_default$4, { isMenuActive: currentActiveMenu === "products", options: productMenuItems }),
|
|
397
|
-
/* @__PURE__ */ jsx(stdin_default$4, { isMenuActive: currentActiveMenu === "media", options: mediaMenuItems }),
|
|
398
|
-
/* @__PURE__ */ jsx(
|
|
399
|
-
stdin_default$5,
|
|
400
|
-
{
|
|
401
|
-
isMenuActive: currentActiveMenu === "main",
|
|
402
|
-
logoutUser,
|
|
403
|
-
user,
|
|
404
|
-
isAdmin,
|
|
405
|
-
notifications: checkTodoStatus(user),
|
|
406
|
-
isVentureDashboard,
|
|
407
|
-
platformUrlForUserMenu: newPlatformUrlForUserMenu,
|
|
408
|
-
navigate
|
|
409
|
-
}
|
|
410
|
-
)
|
|
411
|
-
] })
|
|
412
|
-
] }) });
|
|
413
|
-
}
|
|
414
|
-
const Header = withRouter(HeaderView);
|
|
415
|
-
HeaderView.propTypes = {
|
|
416
|
-
navigate: PropTypes.func,
|
|
417
|
-
progress: PropTypes.shape({
|
|
418
|
-
items: PropTypes.arrayOf(PropTypes.object).isRequired,
|
|
419
|
-
doneIndex: PropTypes.number,
|
|
420
|
-
activeIndex: PropTypes.number
|
|
421
|
-
}),
|
|
422
|
-
signupFlow: PropTypes.bool,
|
|
423
|
-
activeMenu: PropTypes.any,
|
|
424
|
-
activateMenu: PropTypes.func,
|
|
425
|
-
user: PropTypes.object,
|
|
426
|
-
userPhoto: PropTypes.string,
|
|
427
|
-
logoutUser: PropTypes.func,
|
|
428
|
-
onLoginClick: PropTypes.func,
|
|
429
|
-
onSignUpClick: PropTypes.func,
|
|
430
|
-
useRelativePathForMenu: PropTypes.bool,
|
|
431
|
-
useRelativePathForUserMenu: PropTypes.bool,
|
|
432
|
-
withSidebar: PropTypes.bool,
|
|
433
|
-
isSidebarExpanded: PropTypes.bool,
|
|
434
|
-
sidebarHandler: PropTypes.func,
|
|
435
|
-
noFixedPosition: PropTypes.bool
|
|
436
|
-
};
|
|
437
|
-
var stdin_default = Header;
|
|
438
|
-
export {
|
|
439
|
-
Header,
|
|
440
|
-
stdin_default as default
|
|
441
|
-
};
|