Shared: restored Table.constants.ts
This commit is contained in:
parent
ef85f2d5c4
commit
64ea57f0eb
@ -28,7 +28,7 @@ import { makeAutoObservable } from "mobx";
|
||||
import { isMobile } from "@docspace/shared/utils";
|
||||
import { checkDialogsOpen } from "@docspace/shared/utils/checkDialogsOpen";
|
||||
import { TUser, TUserGroup } from "@docspace/shared/api/people/types";
|
||||
import { TABLE_HEADER_HEIGHT } from "@docspace/shared/utils/device";
|
||||
import { TABLE_HEADER_HEIGHT } from "@docspace/shared/components/table/Table.constants";
|
||||
|
||||
type AccountsType = TUser | TUserGroup;
|
||||
|
||||
|
@ -37,7 +37,7 @@ import getFilesFromEvent from "@docspace/shared/components/drag-and-drop/get-fil
|
||||
import config from "PACKAGE_FILE";
|
||||
import { getCategoryUrl } from "SRC_DIR/helpers/utils";
|
||||
import { encryptionUploadDialog } from "../helpers/encryptionUploadDialog";
|
||||
import { TABLE_HEADER_HEIGHT } from "@docspace/shared/utils/device";
|
||||
import { TABLE_HEADER_HEIGHT } from "@docspace/shared/components/table/Table.constants";
|
||||
|
||||
class HotkeyStore {
|
||||
filesStore;
|
||||
|
30
packages/shared/components/table/Table.constants.ts
Normal file
30
packages/shared/components/table/Table.constants.ts
Normal file
@ -0,0 +1,30 @@
|
||||
// (c) Copyright Ascensio System SIA 2009-2024
|
||||
//
|
||||
// This program is a free software product.
|
||||
// You can redistribute it and/or modify it under the terms
|
||||
// of the GNU Affero General Public License (AGPL) version 3 as published by the Free Software
|
||||
// Foundation. In accordance with Section 7(a) of the GNU AGPL its Section 15 shall be amended
|
||||
// to the effect that Ascensio System SIA expressly excludes the warranty of non-infringement of
|
||||
// any third-party rights.
|
||||
//
|
||||
// This program is distributed WITHOUT ANY WARRANTY, without even the implied warranty
|
||||
// of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For details, see
|
||||
// the GNU AGPL at: http://www.gnu.org/licenses/agpl-3.0.html
|
||||
//
|
||||
// You can contact Ascensio System SIA at Lubanas st. 125a-25, Riga, Latvia, EU, LV-1021.
|
||||
//
|
||||
// The interactive user interfaces in modified source and object code versions of the Program must
|
||||
// display Appropriate Legal Notices, as required under Section 5 of the GNU AGPL version 3.
|
||||
//
|
||||
// Pursuant to Section 7(b) of the License you must retain the original Product logo when
|
||||
// distributing the program. Pursuant to Section 7(e) we decline to grant you any rights under
|
||||
// trademark law for use of our trademarks.
|
||||
//
|
||||
// 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
|
||||
|
||||
export const DEFAULT_MIN_COLUMN_SIZE = 110;
|
||||
export const SETTINGS_SIZE = 24;
|
||||
export const MIN_SIZE_FIRST_COLUMN = 210;
|
||||
export const TABLE_HEADER_HEIGHT = 40;
|
@ -24,10 +24,7 @@
|
||||
// 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
|
||||
|
||||
export const MIN_SIZE_FIRST_COLUMN = 210;
|
||||
export const DEFAULT_MIN_COLUMN_SIZE = 110;
|
||||
export const SETTINGS_SIZE = 24;
|
||||
export const HANDLE_OFFSET = 8;
|
||||
import { SETTINGS_SIZE } from "./Table.constants";
|
||||
|
||||
export const getSubstring = (str: string) => +str.substring(0, str.length - 2);
|
||||
|
||||
|
@ -38,14 +38,12 @@ import {
|
||||
import { TTableColumn, TableHeaderProps } from "./Table.types";
|
||||
import { TableSettings } from "./sub-components/TableSettings";
|
||||
import { TableHeaderCell } from "./sub-components/TableHeaderCell";
|
||||
import { checkingForUnfixedSize, getSubstring } from "./Table.utils";
|
||||
import {
|
||||
DEFAULT_MIN_COLUMN_SIZE,
|
||||
MIN_SIZE_FIRST_COLUMN,
|
||||
SETTINGS_SIZE,
|
||||
HANDLE_OFFSET,
|
||||
checkingForUnfixedSize,
|
||||
getSubstring,
|
||||
} from "./Table.utils";
|
||||
MIN_SIZE_FIRST_COLUMN,
|
||||
} from "./Table.constants";
|
||||
import { isDesktop } from "../../utils";
|
||||
|
||||
class TableHeaderComponent extends React.Component<
|
||||
|
@ -25,7 +25,6 @@
|
||||
// International. See the License terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
|
||||
export const INFO_PANEL_WIDTH = 400;
|
||||
export const TABLE_HEADER_HEIGHT = 40;
|
||||
export const MAX_INFINITE_LOADER_SHIFT = 800;
|
||||
|
||||
export function checkIsSSR() {
|
||||
|
Loading…
Reference in New Issue
Block a user