Merge branch 'release/v2.0.0' into feature/new-form-gallery
This commit is contained in:
commit
b49933787d
@ -27,6 +27,7 @@ import PersonManagerReactSvgUrl from "PUBLIC_DIR/images/person.manager.react.svg
|
|||||||
import PersonUserReactSvgUrl from "PUBLIC_DIR/images/person.user.react.svg?url";
|
import PersonUserReactSvgUrl from "PUBLIC_DIR/images/person.user.react.svg?url";
|
||||||
import InviteAgainReactSvgUrl from "PUBLIC_DIR/images/invite.again.react.svg?url";
|
import InviteAgainReactSvgUrl from "PUBLIC_DIR/images/invite.again.react.svg?url";
|
||||||
import PublicRoomIconUrl from "PUBLIC_DIR/images/public-room.react.svg?url";
|
import PublicRoomIconUrl from "PUBLIC_DIR/images/public-room.react.svg?url";
|
||||||
|
import PluginMoreReactSvgUrl from "PUBLIC_DIR/images/plugin.more.react.svg?url";
|
||||||
|
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import { inject, observer } from "mobx-react";
|
import { inject, observer } from "mobx-react";
|
||||||
@ -427,12 +428,24 @@ const SectionHeaderContent = (props) => {
|
|||||||
];
|
];
|
||||||
|
|
||||||
if (mainButtonItemsList && enablePlugins) {
|
if (mainButtonItemsList && enablePlugins) {
|
||||||
|
const pluginItems = [];
|
||||||
|
|
||||||
mainButtonItemsList.forEach((option) => {
|
mainButtonItemsList.forEach((option) => {
|
||||||
options.splice(option.value.position, 0, {
|
pluginItems.push({
|
||||||
key: option.key,
|
key: option.key,
|
||||||
...option.value,
|
...option.value,
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
options.splice(5, 0, {
|
||||||
|
id: "actions_more-plugins",
|
||||||
|
className: "main-button_drop-down",
|
||||||
|
icon: PluginMoreReactSvgUrl,
|
||||||
|
label: t("Common:More"),
|
||||||
|
disabled: false,
|
||||||
|
key: "more-plugins",
|
||||||
|
items: pluginItems,
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
return options;
|
return options;
|
||||||
|
@ -23,7 +23,12 @@ import { Trans } from "react-i18next";
|
|||||||
|
|
||||||
import { AvatarEditorDialog } from "SRC_DIR/components/dialogs";
|
import { AvatarEditorDialog } from "SRC_DIR/components/dialogs";
|
||||||
|
|
||||||
import { StyledWrapper, StyledInfo, StyledLabel, StyledAvatarWrapper } from "./styled-main-profile";
|
import {
|
||||||
|
StyledWrapper,
|
||||||
|
StyledInfo,
|
||||||
|
StyledLabel,
|
||||||
|
StyledAvatarWrapper,
|
||||||
|
} from "./styled-main-profile";
|
||||||
import { HelpButton, Tooltip } from "@docspace/components";
|
import { HelpButton, Tooltip } from "@docspace/components";
|
||||||
import withCultureNames from "@docspace/common/hoc/withCultureNames";
|
import withCultureNames from "@docspace/common/hoc/withCultureNames";
|
||||||
import { isMobile } from "@docspace/components/utils/device";
|
import { isMobile } from "@docspace/components/utils/device";
|
||||||
@ -84,17 +89,20 @@ const MainProfile = (props) => {
|
|||||||
setChangePasswordVisible(true);
|
setChangePasswordVisible(true);
|
||||||
};
|
};
|
||||||
|
|
||||||
const userAvatar = profile.hasAvatar ? profile.avatarMax : DefaultUserAvatarMax;
|
const userAvatar = profile.hasAvatar
|
||||||
|
? profile.avatarMax
|
||||||
|
: DefaultUserAvatarMax;
|
||||||
|
|
||||||
const tooltipLanguage = (
|
const tooltipLanguage = (
|
||||||
<Text as="div" fontSize="12px" color="#333333">
|
<Text as="div" fontSize="12px" color="#333333">
|
||||||
<Trans t={t} i18nKey="NotFoundLanguage" ns="Common">
|
<Trans t={t} i18nKey="NotFoundLanguage" ns="Common">
|
||||||
"In case you cannot find your language in the list of the available ones, feel free to write
|
"In case you cannot find your language in the list of the available
|
||||||
to us at
|
ones, feel free to write to us at
|
||||||
<Link
|
<Link
|
||||||
href={`mailto:${documentationEmail}`}
|
href={`mailto:${documentationEmail}`}
|
||||||
isHovered={true}
|
isHovered={true}
|
||||||
color={theme.profileInfo.tooltipLinkColor}>
|
color={currentColorScheme?.main?.accent}
|
||||||
|
>
|
||||||
{{ supportEmail: documentationEmail }}
|
{{ supportEmail: documentationEmail }}
|
||||||
</Link>
|
</Link>
|
||||||
to take part in the translation and get up to 1 year free of charge."
|
to take part in the translation and get up to 1 year free of charge."
|
||||||
@ -106,7 +114,8 @@ const MainProfile = (props) => {
|
|||||||
color="#333333"
|
color="#333333"
|
||||||
fontSize="13px"
|
fontSize="13px"
|
||||||
href={`${helpLink}/guides/become-translator.aspx`}
|
href={`${helpLink}/guides/become-translator.aspx`}
|
||||||
target="_blank">
|
target="_blank"
|
||||||
|
>
|
||||||
{t("Common:LearnMore")}
|
{t("Common:LearnMore")}
|
||||||
</Link>
|
</Link>
|
||||||
</Box>
|
</Box>
|
||||||
@ -161,7 +170,10 @@ const MainProfile = (props) => {
|
|||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</StyledAvatarWrapper>
|
</StyledAvatarWrapper>
|
||||||
<StyledInfo withActivationBar={withActivationBar} currentColorScheme={currentColorScheme}>
|
<StyledInfo
|
||||||
|
withActivationBar={withActivationBar}
|
||||||
|
currentColorScheme={currentColorScheme}
|
||||||
|
>
|
||||||
<div className="rows-container">
|
<div className="rows-container">
|
||||||
<div className="profile-block">
|
<div className="profile-block">
|
||||||
<StyledLabel as="div">{t("Common:Name")}</StyledLabel>
|
<StyledLabel as="div">{t("Common:Name")}</StyledLabel>
|
||||||
@ -170,11 +182,18 @@ const MainProfile = (props) => {
|
|||||||
{t("Common:Email")}
|
{t("Common:Email")}
|
||||||
</StyledLabel>
|
</StyledLabel>
|
||||||
|
|
||||||
<StyledLabel as="div" marginTopProp={withActivationBar ? "34px" : "16px"}>
|
<StyledLabel
|
||||||
|
as="div"
|
||||||
|
marginTopProp={withActivationBar ? "34px" : "16px"}
|
||||||
|
>
|
||||||
{t("Common:Password")}
|
{t("Common:Password")}
|
||||||
</StyledLabel>
|
</StyledLabel>
|
||||||
|
|
||||||
<StyledLabel as="div" className="profile-language" marginTopProp="15px">
|
<StyledLabel
|
||||||
|
as="div"
|
||||||
|
className="profile-language"
|
||||||
|
marginTopProp="15px"
|
||||||
|
>
|
||||||
{t("Common:Language")}
|
{t("Common:Language")}
|
||||||
<HelpButton
|
<HelpButton
|
||||||
size={12}
|
size={12}
|
||||||
@ -219,14 +238,17 @@ const MainProfile = (props) => {
|
|||||||
data-tooltip-content={t("EmailNotVerified")}
|
data-tooltip-content={t("EmailNotVerified")}
|
||||||
as="div"
|
as="div"
|
||||||
className="email-text-container"
|
className="email-text-container"
|
||||||
fontWeight={600}>
|
fontWeight={600}
|
||||||
|
>
|
||||||
{profile.email}
|
{profile.email}
|
||||||
</Text>
|
</Text>
|
||||||
{withActivationBar && (
|
{withActivationBar && (
|
||||||
<Tooltip
|
<Tooltip
|
||||||
float
|
float
|
||||||
id="emailTooltip"
|
id="emailTooltip"
|
||||||
getContent={({ content }) => <Text fontSize="12px">{content}</Text>}
|
getContent={({ content }) => (
|
||||||
|
<Text fontSize="12px">{content}</Text>
|
||||||
|
)}
|
||||||
place="bottom"
|
place="bottom"
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
@ -240,8 +262,14 @@ const MainProfile = (props) => {
|
|||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
{withActivationBar && (
|
{withActivationBar && (
|
||||||
<div className="send-again-container" onClick={sendActivationLinkAction}>
|
<div
|
||||||
<ReactSVG className="send-again-icon" src={SendClockReactSvgUrl} />
|
className="send-again-container"
|
||||||
|
onClick={sendActivationLinkAction}
|
||||||
|
>
|
||||||
|
<ReactSVG
|
||||||
|
className="send-again-icon"
|
||||||
|
src={SendClockReactSvgUrl}
|
||||||
|
/>
|
||||||
<Text className="send-again-text" fontWeight={600} noSelect>
|
<Text className="send-again-text" fontWeight={600} noSelect>
|
||||||
{t("SendAgain")}
|
{t("SendAgain")}
|
||||||
</Text>
|
</Text>
|
||||||
@ -272,7 +300,9 @@ const MainProfile = (props) => {
|
|||||||
dropDownMaxHeight={364}
|
dropDownMaxHeight={364}
|
||||||
manualWidth="250px"
|
manualWidth="250px"
|
||||||
isDefaultMode={
|
isDefaultMode={
|
||||||
isMobileHorizontalOrientation ? isMobileHorizontalOrientation : !isMobile()
|
isMobileHorizontalOrientation
|
||||||
|
? isMobileHorizontalOrientation
|
||||||
|
: !isMobile()
|
||||||
}
|
}
|
||||||
withBlur={isMobileHorizontalOrientation ? false : isMobile()}
|
withBlur={isMobileHorizontalOrientation ? false : isMobile()}
|
||||||
fillIcon={false}
|
fillIcon={false}
|
||||||
@ -287,7 +317,11 @@ const MainProfile = (props) => {
|
|||||||
<Text className="mobile-profile-label" as="div">
|
<Text className="mobile-profile-label" as="div">
|
||||||
{t("Common:Name")}
|
{t("Common:Name")}
|
||||||
</Text>
|
</Text>
|
||||||
<Text className="mobile-profile-label-field" fontWeight={600} truncate>
|
<Text
|
||||||
|
className="mobile-profile-label-field"
|
||||||
|
fontWeight={600}
|
||||||
|
truncate
|
||||||
|
>
|
||||||
{profile.displayName}
|
{profile.displayName}
|
||||||
</Text>
|
</Text>
|
||||||
</div>
|
</div>
|
||||||
@ -310,7 +344,8 @@ const MainProfile = (props) => {
|
|||||||
data-tooltip-content={t("EmailNotVerified")}
|
data-tooltip-content={t("EmailNotVerified")}
|
||||||
as="div"
|
as="div"
|
||||||
className="email-text-container"
|
className="email-text-container"
|
||||||
fontWeight={600}>
|
fontWeight={600}
|
||||||
|
>
|
||||||
{profile.email}
|
{profile.email}
|
||||||
</Text>
|
</Text>
|
||||||
</div>
|
</div>
|
||||||
@ -318,14 +353,22 @@ const MainProfile = (props) => {
|
|||||||
<Tooltip
|
<Tooltip
|
||||||
float
|
float
|
||||||
id="emailTooltip"
|
id="emailTooltip"
|
||||||
getContent={({ content }) => <Text fontSize="12px">{content}</Text>}
|
getContent={({ content }) => (
|
||||||
|
<Text fontSize="12px">{content}</Text>
|
||||||
|
)}
|
||||||
place="bottom"
|
place="bottom"
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
{withActivationBar && (
|
{withActivationBar && (
|
||||||
<div className="send-again-container" onClick={sendActivationLinkAction}>
|
<div
|
||||||
<ReactSVG className="send-again-icon" src={SendClockReactSvgUrl} />
|
className="send-again-container"
|
||||||
|
onClick={sendActivationLinkAction}
|
||||||
|
>
|
||||||
|
<ReactSVG
|
||||||
|
className="send-again-icon"
|
||||||
|
src={SendClockReactSvgUrl}
|
||||||
|
/>
|
||||||
<Text className="send-again-text" fontWeight={600} noSelect>
|
<Text className="send-again-text" fontWeight={600} noSelect>
|
||||||
{t("SendAgain")}
|
{t("SendAgain")}
|
||||||
</Text>
|
</Text>
|
||||||
@ -380,7 +423,9 @@ const MainProfile = (props) => {
|
|||||||
dropDownMaxHeight={364}
|
dropDownMaxHeight={364}
|
||||||
manualWidth="250px"
|
manualWidth="250px"
|
||||||
isDefaultMode={
|
isDefaultMode={
|
||||||
isMobileHorizontalOrientation ? isMobileHorizontalOrientation : !isMobile()
|
isMobileHorizontalOrientation
|
||||||
|
? isMobileHorizontalOrientation
|
||||||
|
: !isMobile()
|
||||||
}
|
}
|
||||||
withBlur={isMobileHorizontalOrientation ? false : isMobile()}
|
withBlur={isMobileHorizontalOrientation ? false : isMobile()}
|
||||||
fillIcon={false}
|
fillIcon={false}
|
||||||
@ -404,7 +449,8 @@ const MainProfile = (props) => {
|
|||||||
|
|
||||||
export default inject(({ auth, peopleStore }) => {
|
export default inject(({ auth, peopleStore }) => {
|
||||||
const { withActivationBar, sendActivationLink } = auth.userStore;
|
const { withActivationBar, sendActivationLink } = auth.userStore;
|
||||||
const { theme, helpLink, culture, currentColorScheme, documentationEmail } = auth.settingsStore;
|
const { theme, helpLink, culture, currentColorScheme, documentationEmail } =
|
||||||
|
auth.settingsStore;
|
||||||
|
|
||||||
const {
|
const {
|
||||||
targetUser: profile,
|
targetUser: profile,
|
||||||
|
@ -109,7 +109,7 @@ const SocialNetworks = (props) => {
|
|||||||
label={getProviderTranslation(label, t, item.linked)}
|
label={getProviderTranslation(label, t, item.linked)}
|
||||||
$iconOptions={iconOptions}
|
$iconOptions={iconOptions}
|
||||||
onClick={onClick}
|
onClick={onClick}
|
||||||
size="small"
|
size="base"
|
||||||
isConnect={item.linked}
|
isConnect={item.linked}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
@ -317,9 +317,9 @@ const Base = {
|
|||||||
width: "100%",
|
width: "100%",
|
||||||
height: "16px",
|
height: "16px",
|
||||||
margin: "0 11px",
|
margin: "0 11px",
|
||||||
fontWeight: "600",
|
fontWeight: "500",
|
||||||
fontSize: "14px",
|
fontSize: "14px",
|
||||||
lineHeight: "14px",
|
lineHeight: "16px",
|
||||||
letterSpacing: "0.21875px",
|
letterSpacing: "0.21875px",
|
||||||
overflow: "hidden",
|
overflow: "hidden",
|
||||||
textOverflow: "ellipsis",
|
textOverflow: "ellipsis",
|
||||||
|
@ -315,9 +315,9 @@ const Dark = {
|
|||||||
width: "100%",
|
width: "100%",
|
||||||
height: "16px",
|
height: "16px",
|
||||||
margin: "0 11px",
|
margin: "0 11px",
|
||||||
fontWeight: "600",
|
fontWeight: "500",
|
||||||
fontSize: "14px",
|
fontSize: "14px",
|
||||||
lineHeight: "14px",
|
lineHeight: "16px",
|
||||||
letterSpacing: "0.21875px",
|
letterSpacing: "0.21875px",
|
||||||
overflow: "hidden",
|
overflow: "hidden",
|
||||||
textOverflow: "ellipsis",
|
textOverflow: "ellipsis",
|
||||||
@ -3068,7 +3068,7 @@ const Dark = {
|
|||||||
|
|
||||||
profile: {
|
profile: {
|
||||||
main: {
|
main: {
|
||||||
background: "#1f1f1f",
|
background: "#3D3D3D",
|
||||||
textColor: white,
|
textColor: white,
|
||||||
|
|
||||||
descriptionTextColor: "#858585",
|
descriptionTextColor: "#858585",
|
||||||
|
Loading…
Reference in New Issue
Block a user