Merge branch 'release/v2.5.0' of github.com:ONLYOFFICE/DocSpace-client into release/v2.5.0

This commit is contained in:
Elyor Djalilov 2024-04-04 15:04:39 +05:00
commit 94f7304343
11 changed files with 20 additions and 5 deletions

View File

@ -34,6 +34,7 @@ export type FilesSelectorProps = {
isPanelVisible: boolean;
// withoutImmediatelyClose: boolean;
isThirdParty: boolean;
isSelectFolder: boolean;
rootThirdPartyId?: string;
isRoomsOnly: boolean;
isUserOnly: boolean;

View File

@ -62,6 +62,7 @@ const FilesSelectorWrapper = ({
isRoomsOnly = false,
isUserOnly = false,
isEditorDialog = false,
isSelectFolder = false,
rootThirdPartyId,
filterParam,
@ -273,7 +274,7 @@ const FilesSelectorWrapper = ({
isSelect,
filterParam,
isRestore,
isThirdParty,
isSelectFolder,
);
const defaultAcceptButtonLabel = getAcceptButtonLabel(
@ -285,6 +286,7 @@ const FilesSelectorWrapper = ({
isSelect,
filterParam,
isRestore,
isSelectFolder,
);
const getIsDisabledAction = (

View File

@ -41,10 +41,10 @@ export const getHeaderLabel = (
isSelect?: boolean,
filterParam?: string,
isRestore?: boolean,
isThirdParty?: boolean,
isSelectFolder?: boolean,
) => {
if (isRestore) return t("Common:RestoreTo");
if (isThirdParty) return t("Common:SelectFolder");
if (isSelectFolder) return t("Common:SelectFolder");
if (isMove) return t("Common:MoveTo");
if (isCopy && !isEditorDialog) return t("Common:Copy");
if (isRestoreAll) return t("Common:Restore");
@ -68,12 +68,13 @@ export const getAcceptButtonLabel = (
isSelect?: boolean,
filterParam?: string,
isRestore?: boolean,
isSelectFolder?: boolean,
) => {
if (isRestore) return t("Common:RestoreHere");
if (isMove) return t("Common:MoveHere");
if (isCopy && !isEditorDialog) return t("Common:CopyHere");
if (isRestoreAll) return t("Common:RestoreHere");
if (isSelect) return t("Common:SelectAction");
if (isSelect || isSelectFolder) return t("Common:SelectAction");
if (filterParam === FilesSelectorFilterTypes.DOCX) return t("Common:Create");
// if (filterParam === FilesSelectorFilterTypes.DOCXF) return t("Common:SubmitToGallery");

View File

@ -39,6 +39,7 @@ const FilesSelectorInput = (props) => {
id,
isThirdParty,
isRoomsOnly,
isSelectFolder,
setNewPath,
newPath,
onSelectFolder: setSelectedFolder,
@ -126,6 +127,7 @@ const FilesSelectorInput = (props) => {
rootThirdPartyId={rootThirdPartyId}
isThirdParty={isThirdParty}
isRoomsOnly={isRoomsOnly}
isSelectFolder={isSelectFolder}
id={id}
onClose={onClose}
isPanelVisible={isPanelVisible}

View File

@ -214,9 +214,9 @@ const FolderInput = ({
isPanelVisible={isDialogOpen}
onClose={onClose}
isThirdParty
isSelectFolder
onSelectTreeNode={setTreeNode}
passedFoldersTree={[thirdpartyAccount]}
acceptButtonLabel={t("Common:SelectAction")}
currentFolderId={treeNode ? treeNode.id : thirdpartyAccount.id}
/>
)}

View File

@ -59,6 +59,7 @@ class RoomsModule extends React.PureComponent {
isError={isError}
isDisabled={isLoadingData}
isRoomBackup
isSelectFolder
/>
</div>
<ScheduleComponent isLoadingData={isLoadingData} {...rest} />

View File

@ -70,6 +70,8 @@ const DirectThirdPartyConnection = (props) => {
isMobileScale,
accounts,
setThirdPartyAccountsInfo,
isSelect,
isSelectFolder,
} = props;
const [state, setState] = useReducer(
@ -261,6 +263,8 @@ const DirectThirdPartyConnection = (props) => {
isError={isError}
isDisabled={isDisabledSelector}
isThirdParty
isSelectFolder={isSelectFolder}
isSelect={isSelect}
/>
)}
</>

View File

@ -93,6 +93,7 @@ class RoomsModule extends React.Component {
withoutInitPath={!selectedFolder}
isDisabled={isModuleDisabled}
isRoomBackup
isSelectFolder
/>
</div>
<div className="manual-backup_buttons">

View File

@ -128,6 +128,7 @@ class ThirdPartyModule extends React.Component {
withoutInitPath={!selectedFolder}
isError={isError}
buttonSize={buttonSize}
isSelectFolder
/>
{connectedThirdPartyAccount?.id && isTheSameThirdPartyAccount && (

View File

@ -48,6 +48,7 @@ const RoomsModule = (props) => {
onSelectFile={onSelectFile}
filterParam={FilesSelectorFilterTypes.BackupOnly}
descriptionText={t("SelectFileInGZFormat")}
isSelect
/>
);
};

View File

@ -50,6 +50,7 @@ const ThirdPartyResources = (props) => {
withoutInitPath
buttonSize={buttonSize}
isMobileScale
isSelect
/>
</div>
);