Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/convert password #493

Merged
merged 76 commits into from
Jan 24, 2022
Merged
Changes from 1 commit
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
4a2342f
Files: added new checkconversion method's param
pavelbannov Dec 8, 2021
c3afe77
Web: Files: Components rewritten, added button to show input.
TatianaLopaeva Dec 21, 2021
1168faf
Web: Files: The displayed error has been moved to a separate file.
TatianaLopaeva Dec 21, 2021
43b1c18
WEb: Files: refactoring.
TatianaLopaeva Dec 21, 2021
6295dc8
Web: Files: Actions of uploaded files has been moved to a separate file.
TatianaLopaeva Dec 21, 2021
0fc88ad
Web: files: Fixed styles according layouts.
TatianaLopaeva Dec 21, 2021
99ac480
Web: files: Added password input component.
TatianaLopaeva Dec 21, 2021
47681bb
Merge branch 'hotfix/v1.1.1' into feature/convert-password
TatianaLopaeva Dec 21, 2021
b047ae3
Web: Common: Added password field to api method.
TatianaLopaeva Dec 22, 2021
6ae2438
Web: Files: UploadPanel: Added hide input prop.
TatianaLopaeva Dec 22, 2021
5a6147b
Web: Files: Added logic for converting with password.
TatianaLopaeva Dec 22, 2021
c9f1765
Web: Files: Added the ability to enter a password and convert.
TatianaLopaeva Dec 22, 2021
76d423a
Web: files: Fixed styles.
TatianaLopaeva Dec 22, 2021
332aec8
Web: Files: Added translations.
TatianaLopaeva Dec 22, 2021
35cac88
Web: Files: UploadPanel: Added error handler for password input.
TatianaLopaeva Dec 22, 2021
55cb04d
Web: Files: Added adaptive layout.
TatianaLopaeva Dec 22, 2021
858e508
WEb: Files: Refactoring.
TatianaLopaeva Dec 22, 2021
604354f
Web: Files: Changed title for actions.
TatianaLopaeva Dec 23, 2021
757bee9
Web: Files: Renaming.
TatianaLopaeva Dec 23, 2021
331bc95
Web: Files: Redesign of upload panel.
TatianaLopaeva Dec 23, 2021
4c72f35
Web: Files: Fixed styles for iOS.
TatianaLopaeva Dec 23, 2021
3423696
Web: Files: Fixed translation.
TatianaLopaeva Dec 23, 2021
0484bd5
Web: Files: Fixed file name according layouts.
TatianaLopaeva Dec 23, 2021
c02624c
WEb: Files: Refactoring.
TatianaLopaeva Dec 23, 2021
79b7fee
Web: Files: Fixed style.
TatianaLopaeva Dec 23, 2021
e7aff4a
Web: Files: Added simulate password for convert file.
TatianaLopaeva Dec 27, 2021
c5c4705
Web: Files: Renaming.
TatianaLopaeva Dec 27, 2021
fdf6f0a
Web: Files: Added translations.
TatianaLopaeva Dec 28, 2021
3dd22c4
Web: Files: Refactoring.
TatianaLopaeva Dec 28, 2021
5e0747e
Web: Files: Added folder for sub components.
TatianaLopaeva Dec 28, 2021
3b42a6e
Web: files: deleted useless code.
TatianaLopaeva Dec 28, 2021
c9e7503
Web: Files: Changed password input logic.
TatianaLopaeva Dec 29, 2021
ddead9c
WEb: Files: Refactoring.
TatianaLopaeva Dec 29, 2021
3c23f4d
Merge branch 'hotfix/v1.1.1' into feature/convert-password
TatianaLopaeva Dec 30, 2021
0c341f0
Merge branch 'hotfix/v1.1.1' into feature/convert-password
TatianaLopaeva Jan 11, 2022
5fcf5cc
Files: copyas method now has "Password" param
pavelbannov Jan 11, 2022
d8ee3de
Web: Files: Moving a component to a separate folder.
TatianaLopaeva Jan 13, 2022
94a4ddb
Web: files: Fixed import.
TatianaLopaeva Jan 13, 2022
e6f89af
Web: Files: Transferring actions to a row file.
TatianaLopaeva Jan 13, 2022
6fd00f5
Merge branch 'hotfix/v1.1.1' into feature/convert-password
TatianaLopaeva Jan 13, 2022
23c8a83
Web: Files: Added password dialog.
TatianaLopaeva Jan 13, 2022
9a236ca
Web: Files: Added possibility to change width of password input.
TatianaLopaeva Jan 13, 2022
bed51de
Web: Files: Refactoring.
TatianaLopaeva Jan 13, 2022
e6647c8
Web: Files: Simplification of the password imitating component.
TatianaLopaeva Jan 14, 2022
783bdd2
WEb: Files: Change the password dialog due to modification of the pas…
TatianaLopaeva Jan 14, 2022
a853d51
Web: Files: Added new prop.
TatianaLopaeva Jan 17, 2022
aa8903b
Web: Files: Added copy method to save in 'oform' format.
TatianaLopaeva Jan 17, 2022
87fa4af
Web: Files: Refactoring.
TatianaLopaeva Jan 17, 2022
9e49ae6
Web: Files: Refactoring, removed bug with memory leak.
TatianaLopaeva Jan 17, 2022
1271bae
Web: Files: Added copy api method to create form template, added clos…
TatianaLopaeva Jan 18, 2022
0a90636
Web: Files: When confirming the creation of a file, the buttons were …
TatianaLopaeva Jan 18, 2022
832b422
Web: Files: Added logic for entering a password when creating a form …
TatianaLopaeva Jan 19, 2022
53eee98
Web: Files: Added warning toastr about file protecting.
TatianaLopaeva Jan 19, 2022
fd5b61d
Web: Files: Added warning about successful file creation.
TatianaLopaeva Jan 19, 2022
384a3b1
Web: files: Added dialog description.
TatianaLopaeva Jan 19, 2022
c3687bc
Web: Files: Added warning about creating a file with an error.
TatianaLopaeva Jan 19, 2022
68f2952
Web: Files: Added loader for button.
TatianaLopaeva Jan 19, 2022
4cbb250
Web: Files: Added password error handler.
TatianaLopaeva Jan 20, 2022
1e5877f
Web: Files: Added row loader when creation file or folder.
TatianaLopaeva Jan 21, 2022
720ca53
Web: Files: Added password error handler to HOCs.
TatianaLopaeva Jan 21, 2022
f7779b3
Web: Files: refactoring.
TatianaLopaeva Jan 21, 2022
9762445
Web: Files: Fixed Regular expression.
TatianaLopaeva Jan 21, 2022
e1d07c5
Web: Files: Added English translation.
TatianaLopaeva Jan 21, 2022
e3497f0
Web: Files: Added header translation.
TatianaLopaeva Jan 21, 2022
8de8ffb
Web: Files: Deleted useless code.
TatianaLopaeva Jan 21, 2022
efe799d
Merge branch 'hotfix/v1.1.1' into feature/convert-password
TatianaLopaeva Jan 21, 2022
893c4dd
Wen: Editor: Added a new parameter to the conversion api method.
TatianaLopaeva Jan 21, 2022
88a6f82
Web: Files: Deleted useless code.
TatianaLopaeva Jan 21, 2022
292f00e
WEb: files: Moved api copy method.
TatianaLopaeva Jan 21, 2022
2abdb3f
Web: Files: Fixed button color, the button is disabled if the user ha…
TatianaLopaeva Jan 21, 2022
9137620
Web: Files: Added KeyDown support in the upload panel, added auto-foc…
TatianaLopaeva Jan 24, 2022
a36b564
Web: Files: Added KeyDown support in the convert dialog with password.
TatianaLopaeva Jan 24, 2022
7f70742
Web: Files: Added auto-focus when entering a password with an error.
TatianaLopaeva Jan 24, 2022
d865a96
Web: Files: Fixed floating button deletion if the floating button was…
TatianaLopaeva Jan 24, 2022
226dd96
Web: Files: Fixed translation.
TatianaLopaeva Jan 24, 2022
83e7b11
Web: Files: Fixed translation.
TatianaLopaeva Jan 24, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Web: Files: The displayed error has been moved to a separate file.
TatianaLopaeva committed Dec 21, 2021

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit 1168fafb483a29aefbe7850205f131b6c65ba844
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
import PasswordInput from "./PasswordInput";
import Tooltip from "@appserver/components/tooltip";
import LoadErrorIcon from "../../../../public/images/load.error.react.svg";
import styled from "styled-components";
import Text from "@appserver/components/text";
import React from "react";

const StyledLoadErrorIcon = styled(LoadErrorIcon)`
outline: none !important;
`;

const ErrorFileUpload = ({ item, onTextClick }) => (
<>
<div className="upload_panel-icon">
{item.needPassword && (
<Text
className="enter-password"
fontWeight="600"
color="#A3A9AE"
onClick={onTextClick}
>
{"Enter Password"}
</Text>
)}
<StyledLoadErrorIcon
size="medium"
data-for="errorTooltip"
data-tip={item.error || t("Common:UnknownError")}
/>
<Tooltip
id="errorTooltip"
offsetTop={0}
getContent={(dataTip) => (
<Text fontSize="13px" noSelect>
{dataTip}
</Text>
)}
effect="float"
place="left"
maxWidth={320}
color="#f8f7bf"
/>
</div>
</>
);
export default ErrorFileUpload;
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
import React, { useState, useEffect, Component } from "react";
import React, { Component } from "react";
import styled, { css } from "styled-components";
import Tooltip from "@appserver/components/tooltip";
import Row from "@appserver/components/row";
import Text from "@appserver/components/text";
import Link from "@appserver/components/link";
import LoadingButton from "./LoadingButton";
import ShareButton from "./ShareButton";
import LoadErrorIcon from "../../../../public/images/load.error.react.svg";
import IconButton from "@appserver/components/icon-button";
import { inject, observer } from "mobx-react";
import { withTranslation } from "react-i18next";
import PasswordInput from "./PasswordInput";
import ErrorFileUpload from "./ErrorFileUpload.js";

const StyledFileRow = styled(Row)`
/* margin: 0 16px; */
@@ -101,31 +100,22 @@ const StyledFileRow = styled(Row)`
`}
}
`;
const StyledLoadErrorIcon = styled(LoadErrorIcon)`
outline: none !important;
`;

class FileRow extends Component {
constructor(props) {
super(props);

this.state = {
showPasswordInput: false,
};
console.log("constructor");
}

componentWillUnmount() {
console.log("unmount");
}
onTextClick = () => {
const { showPasswordInput } = this.state;
const { updateRowsHeight, index } = this.props;

const newState = !showPasswordInput;

this.setState({ showPasswordInput: newState }, () => {
console.log("newState", newState);
updateRowsHeight(index, newState);
});
};
@@ -253,43 +243,7 @@ class FileRow extends Component {
)}
</>
) : item.error || (!item.fileId && uploaded) ? (
<>
<div className="upload_panel-icon">
{item.needPassword && (
<Text
className="enter-password"
fontWeight="600"
color="#A3A9AE"
onClick={this.onTextClick}
>
{"Enter Password"}
</Text>
)}
<StyledLoadErrorIcon
size="medium"
data-for="errorTooltip"
data-tip={item.error || t("Common:UnknownError")}
/>
<Tooltip
id="errorTooltip"
offsetTop={0}
getContent={(dataTip) => (
<Text fontSize="13px" noSelect>
{dataTip}
</Text>
)}
effect="float"
place="left"
maxWidth={320}
color="#f8f7bf"
/>
{showPasswordInput && (
<div className="password-input">
<PasswordInput />
</div>
)}
</div>
</>
<ErrorFileUpload item={item} onTextClick={this.onTextClick} />
) : (
<div
className="upload_panel-icon"
@@ -299,6 +253,11 @@ class FileRow extends Component {
<LoadingButton percent={currentFileUploadProgress} />
</div>
)}
{showPasswordInput && (
<div className="password-input">
<PasswordInput />
</div>
)}
</>
</StyledFileRow>
</>