Merge branch 'feature/VDR-room' into feature/VDR-indexing
# Conflicts: # packages/client/public/locales/en/CreateEditRoomDialog.json # packages/client/public/locales/en/Files.json # packages/client/src/components/dialogs/CreateEditRoomDialog/data/index.js # packages/client/src/helpers/filesUtils.js # packages/client/src/pages/Home/Section/Body/TableView/sub-components/RowData.js # packages/shared/components/table/TableHeader.tsx # public/locales/en/Common.json
This commit is contained in:
commit
a1f37ebc04
@ -21,5 +21,16 @@
|
||||
"ThirdPartyStorageDescription": "Use third-party services as data storage for this room. You can create a new folder or select the existing one in the connected storage.",
|
||||
"ThirdPartyStorageNoStorageAlert": "Before, you need to connect the corresponding service in the “Integration” section. Otherwise, the connection will not be possible.",
|
||||
"ThirdPartyStoragePermanentSettingDescription": "Files are stored in a third-party {{thirdpartyTitle}} storage in the \"{{thirdpartyFolderName}}\" folder.\n<strong>{{thirdpartyPath}}</strong>",
|
||||
"ThirdPartyStorageRoomAdminNoStorageAlert": "To connect a third-party storage, you need to add the corresponding service in the Integration section of {{productName}} settings. Contact {{productName}} owner or administrator to enable the integration."
|
||||
"ThirdPartyStorageRoomAdminNoStorageAlert": "To connect a third-party storage, you need to add the corresponding service in the Integration section of {{productName}} settings. Contact {{productName}} owner or administrator to enable the integration.",
|
||||
"ViewOnlyRoomDescription": "Share any ready documents, reports, documentation, and other files for viewing.",
|
||||
"ViewOnlyRoomTitle": "View-only room",
|
||||
"AutomaticIndexing": "Automatic indexing",
|
||||
"AutomaticIndexingDescription": "Enable automatic indexing to index files and folders by serial number. Sorting by number will be set as default for all users.",
|
||||
"FileLifetime": "File lifetime",
|
||||
"FileLifetimeDescription": "Set file lifetime to automatically delete the files in this room after a defined period. Lifetime begins on the date of upload/creation of the file.",
|
||||
"RestrictCopyAndDownload": "Restrict copy and download",
|
||||
"RestrictCopyAndDownloadDescription": "Enable this setting to disable downloads and content copying for users with the \"{{role}}\" role.",
|
||||
"AddWatermarksToDocuments": "Add watermarks to documents",
|
||||
"AddWatermarksToDocumentsDescription": "Protect all documents in this room with watermarks. If a document already contains one, it will not be replaced.",
|
||||
"FilesOlderThan": "Files older than:"
|
||||
}
|
||||
|
@ -131,7 +131,6 @@
|
||||
"PrivateRoomDescriptionUnbreakable": "Unbreakable AES-256 algorithm.",
|
||||
"PrivateRoomHeader": "Welcome to {{organizationName}} private room where every symbol you type is encrypted",
|
||||
"PrivateRoomSupport": "Work in Private Room is available via {{organizationName}} desktop app. <3>Instructions</3>",
|
||||
"VirtualDataRoom": "Virtual Data Room",
|
||||
"RecentlyAccessible": "Recently accessible via link",
|
||||
"RecentViaLinkEmptyContainerDescription": "Here you will find a list of the recently opened files shared with you via an external link.",
|
||||
"RemovedFromFavorites": "Removed from favorites",
|
||||
|
@ -131,8 +131,8 @@ export default function withBadges(WrappedComponent) {
|
||||
|
||||
const file = {
|
||||
...options,
|
||||
ExtraLocationTitle: draftLocation.folderTitle,
|
||||
ExtraLocation: draftLocation.folderId,
|
||||
parentId: draftLocation.folderId,
|
||||
parentTitle: draftLocation.folderTitle,
|
||||
id: draftLocation.fileId,
|
||||
title: draftLocation.fileTitle,
|
||||
};
|
||||
|
@ -40,6 +40,8 @@ export const getRoomTypeDefaultTagTranslation = (roomType = 1, t) => {
|
||||
return t("Common:CustomRooms");
|
||||
case RoomsType.PublicRoom:
|
||||
return t("Common:PublicRoom");
|
||||
case RoomsType.VirtualDataRoom:
|
||||
return t("Common:VirtualDataRoom");
|
||||
case RoomsType.FormRoom:
|
||||
return t("Common:FormRoom");
|
||||
}
|
||||
|
@ -23,9 +23,10 @@
|
||||
// All the Product's GUI elements, including illustrations and icon sets, as well as technical writing
|
||||
// content are licensed under the terms of the Creative Commons Attribution-ShareAlike 4.0
|
||||
// International. See the License terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
|
||||
import { useMemo } from "react";
|
||||
import { inject } from "mobx-react";
|
||||
import { withTranslation } from "react-i18next";
|
||||
import { decode } from "he";
|
||||
|
||||
import { Avatar } from "@docspace/shared/components/avatar";
|
||||
import { Text } from "@docspace/shared/components/text";
|
||||
@ -39,7 +40,10 @@ const ChangeRoomOwner = ({
|
||||
onOwnerChange,
|
||||
currentColorScheme,
|
||||
}) => {
|
||||
const userName = roomOwner.displayName ?? roomOwner.label;
|
||||
const userName = useMemo(
|
||||
() => decode(roomOwner.displayName ?? roomOwner.label),
|
||||
[roomOwner.displayName, roomOwner.label],
|
||||
);
|
||||
|
||||
return (
|
||||
<Styled.ChangeRoomOwner>
|
||||
|
@ -32,13 +32,17 @@ import { Backdrop } from "@docspace/shared/components/backdrop";
|
||||
import PeopleSelector from "@docspace/shared/selectors/People";
|
||||
import { withTranslation } from "react-i18next";
|
||||
import Filter from "@docspace/shared/api/people/filter";
|
||||
import { EmployeeType, DeviceType } from "@docspace/shared/enums";
|
||||
import { EmployeeType } from "@docspace/shared/enums";
|
||||
import { Portal } from "@docspace/shared/components/portal";
|
||||
import { PRODUCT_NAME } from "@docspace/shared/constants";
|
||||
|
||||
const StyledChangeRoomOwner = styled.div`
|
||||
display: contents;
|
||||
|
||||
.change-owner_people-selector {
|
||||
overflow: visible;
|
||||
}
|
||||
|
||||
${({ showBackButton }) =>
|
||||
!showBackButton &&
|
||||
css`
|
||||
@ -93,12 +97,7 @@ const ChangeRoomOwner = (props) => {
|
||||
if (e.keyCode === 13 || e.which === 13) onChangeRoomOwner();
|
||||
};
|
||||
|
||||
const onChangeRoomOwner = async (
|
||||
user,
|
||||
selectedAccess,
|
||||
newFooterInputValue,
|
||||
isChecked,
|
||||
) => {
|
||||
const onChangeRoomOwner = async (user, isChecked) => {
|
||||
if (showBackButton) {
|
||||
setRoomParams && setRoomParams(user[0]);
|
||||
} else {
|
||||
@ -164,16 +163,13 @@ const ChangeRoomOwner = (props) => {
|
||||
emptyScreenDescription={t("CreateEditRoomDialog:PeopleSelectorInfo", {
|
||||
productName: PRODUCT_NAME,
|
||||
})}
|
||||
className="change-owner_people-selector"
|
||||
/>
|
||||
</Aside>
|
||||
</StyledChangeRoomOwner>
|
||||
);
|
||||
|
||||
return currentDeviceType === DeviceType.mobile ? (
|
||||
<Portal visible={visible} element={asideComponent} />
|
||||
) : (
|
||||
asideComponent
|
||||
);
|
||||
return <Portal visible={visible} element={asideComponent} />;
|
||||
};
|
||||
|
||||
export default inject(
|
||||
|
@ -88,7 +88,7 @@ export const getDefaultRoomName = (room, t) => {
|
||||
return t("Common:PublicRoom");
|
||||
|
||||
case RoomsType.VirtualDataRoom:
|
||||
return t("Files:VirtualDataRoom");
|
||||
return t("Common:VirtualDataRoom");
|
||||
case RoomsType.FormRoom:
|
||||
return t("Common:FormRoom");
|
||||
}
|
||||
|
@ -406,6 +406,12 @@ const StyledTableRow = styled(TableRow)`
|
||||
`}
|
||||
}
|
||||
`}
|
||||
|
||||
.no-extra-space {
|
||||
p {
|
||||
margin-right: 0px !important;
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
const StyledDragAndDrop = styled(DragAndDrop)`
|
||||
|
@ -113,7 +113,7 @@ class FilesTableHeader extends React.Component {
|
||||
key: "QuickButtons",
|
||||
title: "",
|
||||
enable: this.props.roomColumnQuickButtonsIsEnabled,
|
||||
defaultSize: 75,
|
||||
defaultSize: 52,
|
||||
resizable: false,
|
||||
},
|
||||
];
|
||||
@ -203,7 +203,7 @@ class FilesTableHeader extends React.Component {
|
||||
key: "QuickButtons",
|
||||
title: "",
|
||||
enable: this.props.quickButtonsColumnIsEnabled,
|
||||
defaultSize: 75,
|
||||
defaultSize: 52,
|
||||
resizable: false,
|
||||
},
|
||||
];
|
||||
@ -282,7 +282,7 @@ class FilesTableHeader extends React.Component {
|
||||
key: "QuickButtons",
|
||||
title: "",
|
||||
enable: this.props.quickButtonsColumnIsEnabled,
|
||||
defaultSize: 75,
|
||||
defaultSize: 52,
|
||||
resizable: false,
|
||||
},
|
||||
];
|
||||
@ -352,7 +352,7 @@ class FilesTableHeader extends React.Component {
|
||||
key: "QuickButtons",
|
||||
title: "",
|
||||
enable: this.props.quickButtonsColumnIsEnabled,
|
||||
defaultSize: 75,
|
||||
defaultSize: 52,
|
||||
resizable: false,
|
||||
},
|
||||
];
|
||||
|
@ -32,7 +32,7 @@ import TypeCell from "./TypeCell";
|
||||
import AuthorCell from "./AuthorCell";
|
||||
import DateCell from "./DateCell";
|
||||
import SizeCell from "./SizeCell";
|
||||
import { classNames } from "@docspace/shared/utils";
|
||||
import { classNames, getLastColumn } from "@docspace/shared/utils";
|
||||
import {
|
||||
StyledBadgesContainer,
|
||||
StyledQuickButtonsContainer,
|
||||
@ -59,8 +59,11 @@ const RecentRowDataComponent = (props) => {
|
||||
showHotkeyBorder,
|
||||
badgesComponent,
|
||||
quickButtonsComponent,
|
||||
tableStorageName,
|
||||
} = props;
|
||||
|
||||
const lastColumn = getLastColumn(tableStorageName);
|
||||
|
||||
return (
|
||||
<>
|
||||
<TableCell
|
||||
@ -90,6 +93,10 @@ const RecentRowDataComponent = (props) => {
|
||||
!authorColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Author" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<AuthorCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -108,6 +115,10 @@ const RecentRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Created" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<DateCell
|
||||
create
|
||||
@ -127,6 +138,10 @@ const RecentRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "LastOpened" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<DateCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -143,6 +158,10 @@ const RecentRowDataComponent = (props) => {
|
||||
!modifiedColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Modified" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<DateCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -159,6 +178,10 @@ const RecentRowDataComponent = (props) => {
|
||||
!sizeColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Size" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<SizeCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -177,6 +200,10 @@ const RecentRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Type" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<TypeCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -219,6 +246,7 @@ export default inject(({ tableStore }) => {
|
||||
typeColumnIsEnabled,
|
||||
quickButtonsColumnIsEnabled,
|
||||
lastOpenedColumnIsEnabled,
|
||||
tableStorageName,
|
||||
} = tableStore;
|
||||
|
||||
return {
|
||||
@ -229,5 +257,6 @@ export default inject(({ tableStore }) => {
|
||||
typeColumnIsEnabled,
|
||||
quickButtonsColumnIsEnabled,
|
||||
lastOpenedColumnIsEnabled,
|
||||
tableStorageName,
|
||||
};
|
||||
})(observer(RecentRowDataComponent));
|
||||
|
@ -32,7 +32,7 @@ import TypeCell from "./TypeCell";
|
||||
import TagsCell from "./TagsCell";
|
||||
import AuthorCell from "./AuthorCell";
|
||||
import DateCell from "./DateCell";
|
||||
import { classNames } from "@docspace/shared/utils";
|
||||
import { classNames, getLastColumn } from "@docspace/shared/utils";
|
||||
import { StyledBadgesContainer } from "../StyledTable";
|
||||
import { StyledQuickButtonsContainer } from "../StyledTable";
|
||||
import SpaceQuota from "SRC_DIR/components/SpaceQuota";
|
||||
@ -59,8 +59,11 @@ const RoomsRowDataComponent = (props) => {
|
||||
badgesComponent,
|
||||
quickButtonsComponent,
|
||||
item,
|
||||
tableStorageName,
|
||||
} = props;
|
||||
|
||||
const lastColumn = getLastColumn(tableStorageName);
|
||||
|
||||
return (
|
||||
<>
|
||||
<TableCell
|
||||
@ -92,6 +95,10 @@ const RoomsRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Type" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<TypeCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -128,6 +135,10 @@ const RoomsRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Owner" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<AuthorCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -146,6 +157,10 @@ const RoomsRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Activity" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<DateCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -200,6 +215,7 @@ export default inject(({ currentQuotaStore, tableStore }) => {
|
||||
roomColumnTagsIsEnabled,
|
||||
roomColumnActivityIsEnabled,
|
||||
roomQuotaColumnIsEnable,
|
||||
tableStorageName,
|
||||
} = tableStore;
|
||||
|
||||
const { showStorageInfo } = currentQuotaStore;
|
||||
@ -211,5 +227,6 @@ export default inject(({ currentQuotaStore, tableStore }) => {
|
||||
roomColumnTagsIsEnabled,
|
||||
roomColumnActivityIsEnabled,
|
||||
showStorageInfo,
|
||||
tableStorageName,
|
||||
};
|
||||
})(observer(RoomsRowDataComponent));
|
||||
|
@ -33,7 +33,7 @@ import AuthorCell from "./AuthorCell";
|
||||
import DateCell from "./DateCell";
|
||||
import SizeCell from "./SizeCell";
|
||||
import IndexCell from "./IndexCell";
|
||||
import { classNames } from "@docspace/shared/utils";
|
||||
import { classNames, getLastColumn } from "@docspace/shared/utils";
|
||||
import { RoomsType } from "@docspace/shared/enums";
|
||||
import {
|
||||
StyledBadgesContainer,
|
||||
@ -63,8 +63,11 @@ const RowDataComponent = (props) => {
|
||||
quickButtonsComponent,
|
||||
|
||||
isIndexing,
|
||||
tableStorageName,
|
||||
} = props;
|
||||
|
||||
const lastColumn = getLastColumn(tableStorageName);
|
||||
|
||||
return (
|
||||
<>
|
||||
{indexColumnIsEnabled && isIndexing && (
|
||||
@ -112,6 +115,10 @@ const RowDataComponent = (props) => {
|
||||
!authorColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Author" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<AuthorCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -130,6 +137,10 @@ const RowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Created" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<DateCell
|
||||
create
|
||||
@ -147,6 +158,10 @@ const RowDataComponent = (props) => {
|
||||
!modifiedColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Modified" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<DateCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -163,6 +178,10 @@ const RowDataComponent = (props) => {
|
||||
!sizeColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Size" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<SizeCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -181,6 +200,10 @@ const RowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Type" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<TypeCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -223,6 +246,7 @@ export default inject(({ tableStore, indexingStore }) => {
|
||||
indexColumnIsEnabled,
|
||||
typeColumnIsEnabled,
|
||||
quickButtonsColumnIsEnabled,
|
||||
tableStorageName,
|
||||
} = tableStore;
|
||||
|
||||
const { isIndexing } = indexingStore;
|
||||
@ -237,5 +261,6 @@ export default inject(({ tableStore, indexingStore }) => {
|
||||
quickButtonsColumnIsEnabled,
|
||||
|
||||
isIndexing,
|
||||
tableStorageName,
|
||||
};
|
||||
})(observer(RowDataComponent));
|
||||
|
@ -32,7 +32,7 @@ import TypeCell from "./TypeCell";
|
||||
import AuthorCell from "./AuthorCell";
|
||||
import DateCell from "./DateCell";
|
||||
import SizeCell from "./SizeCell";
|
||||
import { classNames } from "@docspace/shared/utils";
|
||||
import { classNames, getLastColumn } from "@docspace/shared/utils";
|
||||
import {
|
||||
StyledBadgesContainer,
|
||||
StyledQuickButtonsContainer,
|
||||
@ -61,8 +61,11 @@ const TrashRowDataComponent = (props) => {
|
||||
showHotkeyBorder,
|
||||
badgesComponent,
|
||||
quickButtonsComponent,
|
||||
tableStorageName,
|
||||
} = props;
|
||||
|
||||
const lastColumn = getLastColumn(tableStorageName);
|
||||
|
||||
return (
|
||||
<>
|
||||
<TableCell
|
||||
@ -92,6 +95,10 @@ const TrashRowDataComponent = (props) => {
|
||||
!roomColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Room" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<RoomCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -110,6 +117,10 @@ const TrashRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "AuthorTrash" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<AuthorCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -128,6 +139,10 @@ const TrashRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "CreatedTrash" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<DateCell
|
||||
create
|
||||
@ -145,6 +160,10 @@ const TrashRowDataComponent = (props) => {
|
||||
!erasureColumnIsEnabled ? { background: "none" } : dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "Erasure" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<ErasureCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -163,6 +182,10 @@ const TrashRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "SizeTrash" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<SizeCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -181,6 +204,10 @@ const TrashRowDataComponent = (props) => {
|
||||
: dragStyles.style
|
||||
}
|
||||
{...selectionProp}
|
||||
className={classNames(
|
||||
selectionProp?.className,
|
||||
lastColumn === "TypeTrash" ? "no-extra-space" : "",
|
||||
)}
|
||||
>
|
||||
<TypeCell
|
||||
sideColor={theme.filesSection.tableView.row.sideColor}
|
||||
@ -223,6 +250,7 @@ export default inject(({ tableStore }) => {
|
||||
sizeTrashColumnIsEnabled,
|
||||
typeTrashColumnIsEnabled,
|
||||
quickButtonsColumnIsEnabled,
|
||||
tableStorageName,
|
||||
} = tableStore;
|
||||
|
||||
return {
|
||||
@ -233,5 +261,6 @@ export default inject(({ tableStore }) => {
|
||||
sizeTrashColumnIsEnabled,
|
||||
typeTrashColumnIsEnabled,
|
||||
quickButtonsColumnIsEnabled,
|
||||
tableStorageName,
|
||||
};
|
||||
})(observer(TrashRowDataComponent));
|
||||
|
@ -1625,7 +1625,7 @@ const SectionFilterContent = ({
|
||||
id: "filter_type-virtual-data",
|
||||
key: RoomsType.VirtualDataRoom,
|
||||
group: FilterGroups.roomFilterType,
|
||||
label: t("VirtualDataRoom"),
|
||||
label: t("Common:VirtualDataRoom"),
|
||||
};
|
||||
case RoomsType.CustomRoom:
|
||||
default:
|
||||
|
@ -548,6 +548,7 @@ const SectionHeaderContent = (props) => {
|
||||
disabled:
|
||||
isRecycleBinFolder ||
|
||||
isPersonalRoom ||
|
||||
!security?.CopyLink ||
|
||||
((isPublicRoomType || isCustomRoomType || isFormRoomType) &&
|
||||
haveLinksRight &&
|
||||
!isArchive),
|
||||
|
@ -74,7 +74,7 @@ const LDAP = ({
|
||||
}
|
||||
};
|
||||
|
||||
if (!isLoaded) return <LdapLoader />;
|
||||
if (!isLoaded && isLdapAvailable) return <LdapLoader />;
|
||||
return (
|
||||
<StyledLdapPage
|
||||
isSmallWindow={isSmallWindow}
|
||||
|
@ -74,6 +74,10 @@ const StyledTableRow = styled(TableRow)`
|
||||
margin-left: 8px;
|
||||
`}
|
||||
}
|
||||
|
||||
.remove-cell {
|
||||
justify-content: flex-end;
|
||||
}
|
||||
`;
|
||||
|
||||
StyledTableRow.defaultProps = { theme: Base };
|
||||
@ -137,15 +141,13 @@ const SessionsTableRow = (props) => {
|
||||
</TableCell>
|
||||
|
||||
{showRemoveIcon && (
|
||||
<TableCell>
|
||||
<Box style={{ marginLeft: "8px" }}>
|
||||
<IconButton
|
||||
size={20}
|
||||
iconName={RemoveSessionSvgUrl}
|
||||
isClickable
|
||||
onClick={onRemoveClick}
|
||||
/>
|
||||
</Box>
|
||||
<TableCell className="remove-cell">
|
||||
<IconButton
|
||||
size={20}
|
||||
iconName={RemoveSessionSvgUrl}
|
||||
isClickable
|
||||
onClick={onRemoveClick}
|
||||
/>
|
||||
</TableCell>
|
||||
)}
|
||||
</StyledTableRow>
|
||||
|
@ -102,7 +102,9 @@ const VersionRow = (props) => {
|
||||
|
||||
const versionDate = getCorrectDate(culture, info.updated, "L", "LTS");
|
||||
|
||||
const title = `${Encoder.htmlDecode(info.updatedBy?.displayName)}`;
|
||||
const title = info.updatedBy?.isAnonim
|
||||
? t("Common:Anonymous")
|
||||
: `${Encoder.htmlDecode(info.updatedBy?.displayName)}`;
|
||||
|
||||
const onDownloadAction = () =>
|
||||
openUrl(`${info.viewUrl}&version=${info.version}`, UrlActionType.Download);
|
||||
@ -278,16 +280,27 @@ const VersionRow = (props) => {
|
||||
>
|
||||
{versionDate}
|
||||
</Link>
|
||||
<Link
|
||||
onClick={onUserClick}
|
||||
fontWeight={600}
|
||||
fontSize="14px"
|
||||
title={title}
|
||||
isTextOverflow={true}
|
||||
className="version-link-file"
|
||||
>
|
||||
{title}
|
||||
</Link>
|
||||
{info.updatedBy?.isAnonim ? (
|
||||
<Text
|
||||
fontWeight={600}
|
||||
color={theme.filesVersionHistory.color}
|
||||
fontSize="14px"
|
||||
title={title}
|
||||
>
|
||||
{title}
|
||||
</Text>
|
||||
) : (
|
||||
<Link
|
||||
onClick={onUserClick}
|
||||
fontWeight={600}
|
||||
fontSize="14px"
|
||||
title={title}
|
||||
isTextOverflow={true}
|
||||
className="version-link-file"
|
||||
>
|
||||
{title}
|
||||
</Link>
|
||||
)}
|
||||
</Box>
|
||||
|
||||
{/*<Text
|
||||
|
@ -36,7 +36,7 @@ const StyledBackdrop = styled.div<BackdropProps & { needBackground: boolean }>`
|
||||
${(props) =>
|
||||
props.needBackground &&
|
||||
css`
|
||||
backdrop-filter: blur(3px);
|
||||
backdrop-filter: ${`blur(${props.theme.modalDialog.backdrop.blur}px)`};
|
||||
`};
|
||||
|
||||
display: ${(props) => (props.visible ? "block" : "none")};
|
||||
|
@ -20,6 +20,8 @@ export const getRoomTypeTitleTranslation = (
|
||||
return t("Common:CustomRoomTitle");
|
||||
case RoomsType.PublicRoom:
|
||||
return t("Common:PublicRoom");
|
||||
case RoomsType.VirtualDataRoom:
|
||||
return t("Common:VirtualDataRoom");
|
||||
case RoomsType.FormRoom:
|
||||
return t("Common:FormFilingRoomTitle");
|
||||
default:
|
||||
@ -46,6 +48,8 @@ export const getRoomTypeDescriptionTranslation = (
|
||||
return t("Common:CustomRoomDescription");
|
||||
case RoomsType.PublicRoom:
|
||||
return t("Common:PublicRoomDescription");
|
||||
case RoomsType.VirtualDataRoom:
|
||||
return t("Common:VirtualDataRoomDescription");
|
||||
case RoomsType.FormRoom:
|
||||
return t("Common:FormFilingRoomDescription");
|
||||
default:
|
||||
|
@ -44,6 +44,7 @@ const defaultMinColumnSize = 110;
|
||||
const settingsSize = 24;
|
||||
|
||||
const minSizeFirstColumn = 75;
|
||||
const handleOffset = 8;
|
||||
|
||||
class TableHeader extends React.Component<
|
||||
TableHeaderProps,
|
||||
@ -113,7 +114,7 @@ class TableHeader extends React.Component<
|
||||
? leftColumn.dataset.minWidth
|
||||
: defaultMinColumnSize;
|
||||
|
||||
if (leftColumn.clientWidth <= +minSize) {
|
||||
if (leftColumn.getBoundingClientRect().width <= +minSize) {
|
||||
if (colIndex < 0) return false;
|
||||
this.moveToLeft(widths, newWidth, colIndex - 1);
|
||||
return;
|
||||
@ -159,11 +160,17 @@ class TableHeader extends React.Component<
|
||||
const defaultColumn = document.getElementById(`column_${colIndex}`);
|
||||
if (!defaultColumn || defaultColumn.dataset.defaultSize) return;
|
||||
|
||||
const handleOffset = 8;
|
||||
|
||||
if (column2Width + offset - handleOffset >= defaultMinColumnSize) {
|
||||
widths[+columnIndex] = `${newWidth + handleOffset}px`;
|
||||
widths[colIndex] = `${column2Width + offset - handleOffset}px`;
|
||||
} else if (column2Width !== defaultMinColumnSize) {
|
||||
const width =
|
||||
getSubstring(widths[+columnIndex]) +
|
||||
getSubstring(widths[+colIndex]) -
|
||||
defaultMinColumnSize;
|
||||
|
||||
widths[+columnIndex] = `${width}px`;
|
||||
widths[colIndex] = `${defaultMinColumnSize}px`;
|
||||
} else {
|
||||
if (colIndex === columns.length) return false;
|
||||
this.moveToRight(widths, newWidth, colIndex + 1);
|
||||
@ -237,7 +244,7 @@ class TableHeader extends React.Component<
|
||||
if (!column) return;
|
||||
|
||||
const columnSize = column.getBoundingClientRect();
|
||||
const newWidth = isRtl
|
||||
let newWidth = isRtl
|
||||
? columnSize.right - e.clientX
|
||||
: e.clientX - columnSize.left;
|
||||
|
||||
@ -248,12 +255,14 @@ class TableHeader extends React.Component<
|
||||
? column.dataset.minWidth
|
||||
: defaultMinColumnSize;
|
||||
|
||||
if (newWidth <= +minSize) {
|
||||
const columnChanged = this.moveToLeft(widths, newWidth);
|
||||
if (newWidth <= +minSize - handleOffset) {
|
||||
const currentWidth = getSubstring(widths[+columnIndex]);
|
||||
|
||||
if (!columnChanged) {
|
||||
widths[+columnIndex] = widths[+columnIndex];
|
||||
}
|
||||
// Move left
|
||||
if (currentWidth !== +minSize) {
|
||||
newWidth = +minSize - handleOffset;
|
||||
this.moveToRight(widths, newWidth);
|
||||
} else this.moveToLeft(widths, newWidth);
|
||||
} else {
|
||||
this.moveToRight(widths, newWidth);
|
||||
}
|
||||
@ -339,6 +348,9 @@ class TableHeader extends React.Component<
|
||||
const storageSize =
|
||||
!resetColumnsSize && localStorage.getItem(columnStorageName);
|
||||
|
||||
const storageInfoSize =
|
||||
!resetColumnsSize && localStorage.getItem(columnInfoPanelStorageName);
|
||||
|
||||
// TODO: If defaultSize(75px) is less than defaultMinColumnSize(110px) the calculations work correctly
|
||||
const defaultSize =
|
||||
columns.find((col) => col.defaultSize && col.enable)?.defaultSize || 0;
|
||||
@ -372,6 +384,10 @@ class TableHeader extends React.Component<
|
||||
? storageSize.split(" ")
|
||||
: containerGridTemplateColumns;
|
||||
|
||||
const tableInfoContainer = storageInfoSize
|
||||
? storageInfoSize.split(" ")
|
||||
: containerGridTemplateColumns;
|
||||
|
||||
const { hideColumns } = this.state;
|
||||
|
||||
if (
|
||||
@ -407,7 +423,11 @@ class TableHeader extends React.Component<
|
||||
const oldWidth =
|
||||
defaultWidth - defaultSize - settingsSize - indexColumnDifference;
|
||||
|
||||
if (Math.round(defaultWidth) !== Math.round(containerWidth) && !isResized) {
|
||||
const isDifferentWindowSize = infoPanelVisible
|
||||
? Math.round(defaultInfoWidth) !== Math.round(containerWidth)
|
||||
: Math.round(defaultWidth) !== Math.round(containerWidth);
|
||||
|
||||
if (isDifferentWindowSize && !isResized) {
|
||||
if (infoPanelVisible) localStorage.removeItem(columnInfoPanelStorageName);
|
||||
else localStorage.removeItem(columnStorageName);
|
||||
this.onResize(true);
|
||||
|
@ -666,7 +666,7 @@ export const getBaseTheme = () => {
|
||||
b: 38,
|
||||
a: 0.2,
|
||||
},
|
||||
blur: 10,
|
||||
blur: 9,
|
||||
},
|
||||
|
||||
content: {
|
||||
|
@ -611,9 +611,9 @@ const Dark: TTheme = {
|
||||
},
|
||||
|
||||
scrollbar: {
|
||||
bgColor: "rgba(20, 20, 20, 0.4)",
|
||||
hoverBgColor: "rgba(20, 20, 20, 0.64)",
|
||||
pressBgColor: "rgba(20, 20, 20, 0.8)",
|
||||
bgColor: "rgba(136, 136, 136, 0.4)",
|
||||
hoverBgColor: "rgba(136, 136, 136, 0.64)",
|
||||
pressBgColor: "rgba(136, 136, 136, 0.8)",
|
||||
paddingInlineEnd: "17px !important",
|
||||
paddingInlineEndMobile: "8px !important",
|
||||
},
|
||||
@ -637,7 +637,7 @@ const Dark: TTheme = {
|
||||
b: 27,
|
||||
a: 0.4,
|
||||
},
|
||||
blur: 10,
|
||||
blur: 9,
|
||||
},
|
||||
|
||||
content: {
|
||||
|
@ -164,3 +164,19 @@ export const getTitleWithoutExtension = (
|
||||
? titleWithoutExst
|
||||
: item.title;
|
||||
};
|
||||
|
||||
export const getLastColumn = (tableStorageName: string) => {
|
||||
if (!tableStorageName) return;
|
||||
|
||||
const storageColumns = localStorage.getItem(tableStorageName);
|
||||
if (!storageColumns) return;
|
||||
|
||||
const columns = storageColumns.split(",");
|
||||
const filterColumns = columns.filter(
|
||||
(column) => column !== "false" && column !== "QuickButtons",
|
||||
);
|
||||
|
||||
if (filterColumns.length > 1) return filterColumns[filterColumns.length - 1];
|
||||
|
||||
return null;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user