[ARVADOS-WORKBENCH2] created: 1.1.4-580-gdd89200
Git user
git at public.curoverse.com
Mon Aug 13 01:48:02 EDT 2018
at dd89200ad6fdbfa337fdbab5f54def8712c6746c (commit)
commit dd89200ad6fdbfa337fdbab5f54def8712c6746c
Author: Daniel Kos <daniel.kos at contractors.roche.com>
Date: Fri Aug 10 08:21:07 2018 +0200
Add typescript paths to top level folders
Feature #14007
Arvados-DCO-1.1-Signed-off-by: Daniel Kos <daniel.kos at contractors.roche.com>
diff --git a/package.json b/package.json
index cd8a9c4..e2b6c4e 100644
--- a/package.json
+++ b/package.json
@@ -20,7 +20,7 @@
"react-router": "4.3.1",
"react-router-dom": "4.3.1",
"react-router-redux": "5.0.0-alpha.9",
- "react-scripts-ts": "2.16.0",
+ "react-scripts-ts": "2.17.0",
"redux": "4.0.0",
"redux-thunk": "2.3.0",
"unionize": "2.1.2"
@@ -54,7 +54,9 @@
"redux-form": "7.4.2",
"typescript": "3.0.1"
},
- "moduleNameMapper": {
- "^~/(.*)$": "<rootDir>/src/$1"
+ "jest": {
+ "moduleNameMapper": {
+ "^~/(.*)$": "<rootDir>/src/$1"
+ }
}
}
diff --git a/src/common/api/common-resource-service.test.ts b/src/common/api/common-resource-service.test.ts
index d909c09..a1d5e08 100644
--- a/src/common/api/common-resource-service.test.ts
+++ b/src/common/api/common-resource-service.test.ts
@@ -5,7 +5,7 @@
import { CommonResourceService } from "./common-resource-service";
import axios, { AxiosInstance } from "axios";
import MockAdapter from "axios-mock-adapter";
-import { Resource } from "../../models/resource";
+import { Resource } from "~/models/resource";
export const mockResourceService = <R extends Resource, C extends CommonResourceService<R>>(Service: new (client: AxiosInstance) => C) => {
const axiosInstance = axios.create();
diff --git a/src/common/api/common-resource-service.ts b/src/common/api/common-resource-service.ts
index a836246..36017f0 100644
--- a/src/common/api/common-resource-service.ts
+++ b/src/common/api/common-resource-service.ts
@@ -6,7 +6,7 @@ import * as _ from "lodash";
import { FilterBuilder } from "./filter-builder";
import { OrderBuilder } from "./order-builder";
import { AxiosInstance, AxiosPromise } from "axios";
-import { Resource } from "../../models/resource";
+import { Resource } from "~/models/resource";
export interface ListArguments {
limit?: number;
diff --git a/src/common/labels.ts b/src/common/labels.ts
index ed3a43d..0e3131d 100644
--- a/src/common/labels.ts
+++ b/src/common/labels.ts
@@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { ResourceKind } from "../models/resource";
+import { ResourceKind } from "~/models/resource";
export const resourceLabel = (type: string) => {
switch (type) {
@@ -15,4 +15,4 @@ export const resourceLabel = (type: string) => {
default:
return "Unknown";
}
-};
\ No newline at end of file
+};
diff --git a/src/components/collection-panel-files/collection-panel-files.tsx b/src/components/collection-panel-files/collection-panel-files.tsx
index afe9e85..665758c 100644
--- a/src/components/collection-panel-files/collection-panel-files.tsx
+++ b/src/components/collection-panel-files/collection-panel-files.tsx
@@ -6,12 +6,12 @@ import * as React from 'react';
import { TreeItem, TreeItemStatus } from '../tree/tree';
import { FileTreeData } from '../file-tree/file-tree-data';
import { FileTree } from '../file-tree/file-tree';
-import { IconButton, Grid, Typography, StyleRulesCallback, withStyles, WithStyles, CardHeader, CardContent, Card, Button } from '@material-ui/core';
+import { IconButton, Grid, Typography, StyleRulesCallback, withStyles, WithStyles, CardHeader, Card, Button } from '@material-ui/core';
import { CustomizeTableIcon } from '../icon/icon';
import { connect, DispatchProp } from "react-redux";
import { Dispatch } from "redux";
-import { RootState } from "../../store/store";
-import { ServiceRepository } from "../../services/services";
+import { RootState } from "~/store/store";
+import { ServiceRepository } from "~/services/services";
export interface CollectionPanelFilesProps {
items: Array<TreeItem<FileTreeData>>;
diff --git a/src/components/column-selector/column-selector.tsx b/src/components/column-selector/column-selector.tsx
index f2e42dd..5e4b339 100644
--- a/src/components/column-selector/column-selector.tsx
+++ b/src/components/column-selector/column-selector.tsx
@@ -9,7 +9,7 @@ import { DataColumn } from '../data-table/data-column';
import { Popover } from "../popover/popover";
import { IconButtonProps } from '@material-ui/core/IconButton';
import { DataColumns } from '../data-table/data-table';
-import { ArvadosTheme } from "../../common/custom-theme";
+import { ArvadosTheme } from "~/common/custom-theme";
interface ColumnSelectorDataProps {
columns: DataColumns<any>;
diff --git a/src/components/confirmation-dialog/confirmation-dialog.tsx b/src/components/confirmation-dialog/confirmation-dialog.tsx
index 6e87416..9ca3454 100644
--- a/src/components/confirmation-dialog/confirmation-dialog.tsx
+++ b/src/components/confirmation-dialog/confirmation-dialog.tsx
@@ -3,10 +3,8 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from "react";
-import { defaultTo, property } from 'lodash';
-import { Dialog, DialogTitle, DialogContent, DialogActions, Button, Typography, DialogContentText, CircularProgress } from "@material-ui/core";
+import { Dialog, DialogTitle, DialogContent, DialogActions, Button, DialogContentText } from "@material-ui/core";
import { WithDialogProps } from "../../store/dialog/with-dialog";
-import { TextField } from "../text-field/text-field";
export interface ConfirmationDialogDataProps {
title: string;
diff --git a/src/components/context-menu/context-menu.test.tsx b/src/components/context-menu/context-menu.test.tsx
index 5ced213..faf05f1 100644
--- a/src/components/context-menu/context-menu.test.tsx
+++ b/src/components/context-menu/context-menu.test.tsx
@@ -3,7 +3,7 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from "react";
-import { mount, configure, shallow } from "enzyme";
+import { mount, configure } from "enzyme";
import * as Adapter from "enzyme-adapter-react-16";
import { ContextMenu } from "./context-menu";
import { ListItem } from "@material-ui/core";
diff --git a/src/components/data-explorer/data-explorer.test.tsx b/src/components/data-explorer/data-explorer.test.tsx
index 616a9c1..2be106c 100644
--- a/src/components/data-explorer/data-explorer.test.tsx
+++ b/src/components/data-explorer/data-explorer.test.tsx
@@ -30,7 +30,7 @@ describe("<DataExplorer />", () => {
it("communicates with <ColumnSelector/>", () => {
const onColumnToggle = jest.fn();
- const columns = [{ name: "Column 1", render: jest.fn(), selected: true }];
+ const columns = [{ name: "Column 1", render: jest.fn(), selected: true, configurable: true }];
const dataExplorer = mount(<DataExplorer
{...mockDataExplorerProps()}
columns={columns}
@@ -45,7 +45,7 @@ describe("<DataExplorer />", () => {
const onFiltersChange = jest.fn();
const onSortToggle = jest.fn();
const onRowClick = jest.fn();
- const columns = [{ name: "Column 1", render: jest.fn(), selected: true }];
+ const columns = [{ name: "Column 1", render: jest.fn(), selected: true, configurable: true }];
const items = [{ name: "item 1" }];
const dataExplorer = mount(<DataExplorer
{...mockDataExplorerProps()}
@@ -100,6 +100,7 @@ const mockDataExplorerProps = () => ({
searchValue: "",
page: 0,
rowsPerPage: 0,
+ rowsPerPageOptions: [],
onSearch: jest.fn(),
onFiltersChange: jest.fn(),
onSortToggle: jest.fn(),
diff --git a/src/components/data-explorer/data-explorer.tsx b/src/components/data-explorer/data-explorer.tsx
index 46d5fb5..eaa3464 100644
--- a/src/components/data-explorer/data-explorer.tsx
+++ b/src/components/data-explorer/data-explorer.tsx
@@ -10,7 +10,7 @@ import { DataTable, DataColumns } from "../data-table/data-table";
import { DataColumn } from "../data-table/data-column";
import { DataTableFilterItem } from '../data-table-filters/data-table-filters';
import { SearchInput } from '../search-input/search-input';
-import { ArvadosTheme } from "../../common/custom-theme";
+import { ArvadosTheme } from "~/common/custom-theme";
type CssRules = "searchBox" | "toolbar";
diff --git a/src/components/data-table-filters/data-table-filters.test.tsx b/src/components/data-table-filters/data-table-filters.test.tsx
index b0a84b5..9a3fa4d 100644
--- a/src/components/data-table-filters/data-table-filters.test.tsx
+++ b/src/components/data-table-filters/data-table-filters.test.tsx
@@ -4,7 +4,7 @@
import * as React from "react";
import { mount, configure } from "enzyme";
-import { DataTableFilters, DataTableFilterItem } from "./data-table-filters";
+import { DataTableFilters } from "./data-table-filters";
import * as Adapter from 'enzyme-adapter-react-16';
import { Checkbox, ButtonBase, ListItem, Button, ListItemText } from "@material-ui/core";
diff --git a/src/components/data-table/data-column.ts b/src/components/data-table/data-column.ts
index a5000b9..ac35c02 100644
--- a/src/components/data-table/data-column.ts
+++ b/src/components/data-table/data-column.ts
@@ -3,6 +3,7 @@
// SPDX-License-Identifier: AGPL-3.0
import { DataTableFilterItem } from "../data-table-filters/data-table-filters";
+import * as React from "react";
export interface DataColumn<T, F extends DataTableFilterItem = DataTableFilterItem> {
name: string;
diff --git a/src/components/data-table/data-table.test.tsx b/src/components/data-table/data-table.test.tsx
index 99ed2da..77c7825 100644
--- a/src/components/data-table/data-table.test.tsx
+++ b/src/components/data-table/data-table.test.tsx
@@ -18,17 +18,20 @@ describe("<DataTable />", () => {
{
name: "Column 1",
render: () => <span />,
- selected: true
+ selected: true,
+ configurable: true
},
{
name: "Column 2",
render: () => <span />,
- selected: true
+ selected: true,
+ configurable: true
},
{
name: "Column 3",
render: () => <span />,
- selected: false
+ selected: false,
+ configurable: true
}
];
const dataTable = mount(<DataTable
@@ -47,7 +50,8 @@ describe("<DataTable />", () => {
{
name: "Column 1",
render: () => <span />,
- selected: true
+ selected: true,
+ configurable: true
}
];
const dataTable = mount(<DataTable
@@ -67,7 +71,8 @@ describe("<DataTable />", () => {
name: "Column 1",
renderHeader: () => <span>Column Header</span>,
render: () => <span />,
- selected: true
+ selected: true,
+ configurable: true
}
];
const dataTable = mount(<DataTable
@@ -87,7 +92,8 @@ describe("<DataTable />", () => {
name: "Column 1",
key: "column-1-key",
render: () => <span />,
- selected: true
+ selected: true,
+ configurable: true
}
];
const dataTable = mount(<DataTable
@@ -107,12 +113,14 @@ describe("<DataTable />", () => {
{
name: "Column 1",
render: (item) => <Typography>{item}</Typography>,
- selected: true
+ selected: true,
+ configurable: true
},
{
name: "Column 2",
render: (item) => <Button>{item}</Button>,
- selected: true
+ selected: true,
+ configurable: true
}
];
const dataTable = mount(<DataTable
@@ -132,6 +140,7 @@ describe("<DataTable />", () => {
name: "Column 1",
sortDirection: SortDirection.ASC,
selected: true,
+ configurable: true,
render: (item) => <Typography>{item}</Typography>
}];
const onSortToggle = jest.fn();
@@ -153,6 +162,7 @@ describe("<DataTable />", () => {
name: "Column 1",
sortDirection: SortDirection.ASC,
selected: true,
+ configurable: true,
filters: [{ name: "Filter 1", selected: true }],
render: (item) => <Typography>{item}</Typography>
}];
diff --git a/src/components/data-table/data-table.tsx b/src/components/data-table/data-table.tsx
index f92f97b..34f8168 100644
--- a/src/components/data-table/data-table.tsx
+++ b/src/components/data-table/data-table.tsx
@@ -3,7 +3,7 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from 'react';
-import { Table, TableBody, TableRow, TableCell, TableHead, TableSortLabel, StyleRulesCallback, Theme, WithStyles, withStyles, Typography } from '@material-ui/core';
+import { Table, TableBody, TableRow, TableCell, TableHead, TableSortLabel, StyleRulesCallback, Theme, WithStyles, withStyles } from '@material-ui/core';
import { DataColumn, SortDirection } from './data-column';
import { DataTableFilters, DataTableFilterItem } from "../data-table-filters/data-table-filters";
diff --git a/src/components/details-attribute/details-attribute.tsx b/src/components/details-attribute/details-attribute.tsx
index f9a5b05..d3a8391 100644
--- a/src/components/details-attribute/details-attribute.tsx
+++ b/src/components/details-attribute/details-attribute.tsx
@@ -5,7 +5,7 @@
import * as React from 'react';
import Typography from '@material-ui/core/Typography';
import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core/styles';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import * as classnames from "classnames";
type CssRules = 'attribute' | 'label' | 'value' | 'link';
diff --git a/src/components/dropdown-menu/dropdown-menu.test.tsx b/src/components/dropdown-menu/dropdown-menu.test.tsx
index da232bd..3203993 100644
--- a/src/components/dropdown-menu/dropdown-menu.test.tsx
+++ b/src/components/dropdown-menu/dropdown-menu.test.tsx
@@ -30,13 +30,13 @@ describe("<DropdownMenu />", () => {
it("opens on menu icon click", () => {
const dropdownMenu = shallow(<DropdownMenu id="test-menu" icon={<PaginationRightArrowIcon />} />);
dropdownMenu.find(IconButton).simulate("click", {currentTarget: {}});
- expect(dropdownMenu.state().anchorEl).toBeDefined();
+ expect((dropdownMenu.state() as any).anchorEl).toBeDefined();
});
it("closes on menu click", () => {
const dropdownMenu = shallow(<DropdownMenu id="test-menu" icon={<PaginationRightArrowIcon />} />);
dropdownMenu.find(Menu).simulate("click", {currentTarget: {}});
- expect(dropdownMenu.state().anchorEl).toBeUndefined();
+ expect((dropdownMenu.state() as any).anchorEl).toBeUndefined();
});
});
diff --git a/src/components/file-tree/file-tree-item.tsx b/src/components/file-tree/file-tree-item.tsx
index 5255ded..e2d6b26 100644
--- a/src/components/file-tree/file-tree-item.tsx
+++ b/src/components/file-tree/file-tree-item.tsx
@@ -6,7 +6,7 @@ import * as React from "react";
import { TreeItem } from "../tree/tree";
import { ProjectIcon, MoreOptionsIcon, DefaultIcon, CollectionIcon } from "../icon/icon";
import { Typography, IconButton, StyleRulesCallback, withStyles, WithStyles } from "@material-ui/core";
-import { formatFileSize } from "../../common/formatters";
+import { formatFileSize } from "~/common/formatters";
import { ListItemTextIcon } from "../list-item-text-icon/list-item-text-icon";
import { FileTreeData } from "./file-tree-data";
diff --git a/src/components/file-upload/file-upload.tsx b/src/components/file-upload/file-upload.tsx
index ec4fdc2..74efe00 100644
--- a/src/components/file-upload/file-upload.tsx
+++ b/src/components/file-upload/file-upload.tsx
@@ -13,8 +13,8 @@ import {
import { withStyles } from '@material-ui/core';
import Dropzone from 'react-dropzone';
import { CloudUploadIcon } from "../icon/icon";
-import { formatFileSize, formatProgress, formatUploadSpeed } from "../../common/formatters";
-import { UploadFile } from "../../store/collections/uploader/collection-uploader-actions";
+import { formatFileSize, formatProgress, formatUploadSpeed } from "~/common/formatters";
+import { UploadFile } from "~/store/collections/uploader/collection-uploader-actions";
type CssRules = "root" | "dropzone" | "container" | "uploadIcon";
diff --git a/src/components/list-item-text-icon/list-item-text-icon.tsx b/src/components/list-item-text-icon/list-item-text-icon.tsx
index 6f8a2c4..b34c6ab 100644
--- a/src/components/list-item-text-icon/list-item-text-icon.tsx
+++ b/src/components/list-item-text-icon/list-item-text-icon.tsx
@@ -4,7 +4,7 @@
import * as React from 'react';
import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core/styles';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import { ListItemIcon, ListItemText, Typography } from '@material-ui/core';
import { IconType } from '../icon/icon';
import * as classnames from "classnames";
diff --git a/src/components/popover/popover.test.tsx b/src/components/popover/popover.test.tsx
index 37007ab..4bc2ebd 100644
--- a/src/components/popover/popover.test.tsx
+++ b/src/components/popover/popover.test.tsx
@@ -15,7 +15,7 @@ describe("<Popover />", () => {
it("opens on default trigger click", () => {
const popover = mount(<Popover />);
popover.find(DefaultTrigger).simulate("click");
- expect(popover.state().anchorEl).toBeDefined();
+ expect((popover.state() as any).anchorEl).toBeDefined();
});
it("renders custom trigger", () => {
@@ -26,7 +26,7 @@ describe("<Popover />", () => {
it("opens on custom trigger click", () => {
const popover = mount(<Popover triggerComponent={CustomTrigger} />);
popover.find(CustomTrigger).simulate("click");
- expect(popover.state().anchorEl).toBeDefined();
+ expect((popover.state() as any).anchorEl).toBeDefined();
});
it("renders children when opened", () => {
@@ -47,7 +47,7 @@ describe("<Popover />", () => {
);
popover.find(DefaultTrigger).simulate("click");
popover.find(CustomTrigger).simulate("click");
- expect(popover.state().anchorEl).toBeDefined();
+ expect((popover.state() as any).anchorEl).toBeDefined();
});
it("closes on content click if closeOnContentClick is set", () => {
const popover = mount(
@@ -57,7 +57,7 @@ describe("<Popover />", () => {
);
popover.find(DefaultTrigger).simulate("click");
popover.find(CustomTrigger).simulate("click");
- expect(popover.state().anchorEl).toBeUndefined();
+ expect((popover.state() as any).anchorEl).toBeUndefined();
});
});
diff --git a/src/components/rename-dialog/rename-dialog.tsx b/src/components/rename-dialog/rename-dialog.tsx
index f70d857..e025764 100644
--- a/src/components/rename-dialog/rename-dialog.tsx
+++ b/src/components/rename-dialog/rename-dialog.tsx
@@ -4,8 +4,8 @@
import * as React from "react";
import { InjectedFormProps, Field } from "redux-form";
-import { Dialog, DialogTitle, DialogContent, DialogActions, Button, Typography, DialogContentText, CircularProgress } from "@material-ui/core";
-import { WithDialogProps } from "../../store/dialog/with-dialog";
+import { Dialog, DialogTitle, DialogContent, DialogActions, Button, DialogContentText, CircularProgress } from "@material-ui/core";
+import { WithDialogProps } from "~/store/dialog/with-dialog";
import { TextField } from "../text-field/text-field";
export const RenameDialog = (props: WithDialogProps<string> & InjectedFormProps<{ name: string }>) =>
diff --git a/src/components/side-panel/side-panel.tsx b/src/components/side-panel/side-panel.tsx
index ec648e1..0a62bf2 100644
--- a/src/components/side-panel/side-panel.tsx
+++ b/src/components/side-panel/side-panel.tsx
@@ -5,7 +5,7 @@
import * as React from 'react';
import { ReactElement } from 'react';
import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core/styles';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import { List, ListItem, ListItemIcon, Collapse } from "@material-ui/core";
import { SidePanelRightArrowIcon, IconType } from '../icon/icon';
import * as classnames from "classnames";
diff --git a/src/components/text-field/text-field.tsx b/src/components/text-field/text-field.tsx
index d9f11f4..1fe77ca 100644
--- a/src/components/text-field/text-field.tsx
+++ b/src/components/text-field/text-field.tsx
@@ -4,7 +4,7 @@
import * as React from 'react';
import { WrappedFieldProps } from 'redux-form';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import { TextField as MaterialTextField, StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core';
type CssRules = 'textField';
@@ -25,4 +25,4 @@ export const TextField = withStyles(styles)((props: WrappedFieldProps & WithStyl
autoComplete='off'
fullWidth={true}
{...props.input}
- />);
\ No newline at end of file
+ />);
diff --git a/src/components/tree/tree.tsx b/src/components/tree/tree.tsx
index 669b70c..3e8cf90 100644
--- a/src/components/tree/tree.tsx
+++ b/src/components/tree/tree.tsx
@@ -9,7 +9,7 @@ import { ReactElement } from "react";
import CircularProgress from '@material-ui/core/CircularProgress';
import * as classnames from "classnames";
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import { SidePanelRightArrowIcon } from '../icon/icon';
type CssRules = 'list'
diff --git a/src/services/auth-service/auth-service.ts b/src/services/auth-service/auth-service.ts
index dd47662..57915f7 100644
--- a/src/services/auth-service/auth-service.ts
+++ b/src/services/auth-service/auth-service.ts
@@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { User } from "../../models/user";
+import { User } from "~/models/user";
import { AxiosInstance } from "axios";
export const API_TOKEN_KEY = 'apiToken';
diff --git a/src/services/collection-files-service/collection-files-service.ts b/src/services/collection-files-service/collection-files-service.ts
index 5e6891c..1d9a537 100644
--- a/src/services/collection-files-service/collection-files-service.ts
+++ b/src/services/collection-files-service/collection-files-service.ts
@@ -5,7 +5,7 @@
import { CollectionService } from "../collection-service/collection-service";
import { parseKeepManifestText, stringifyKeepManifest } from "./collection-manifest-parser";
import { mapManifestToCollectionFilesTree } from "./collection-manifest-mapper";
-import { CommonResourceService } from "../../common/api/common-resource-service";
+import { CommonResourceService } from "~/common/api/common-resource-service";
import * as _ from "lodash";
export class CollectionFilesService {
diff --git a/src/services/collection-files-service/collection-manifest-mapper.ts b/src/services/collection-files-service/collection-manifest-mapper.ts
index 8603081..c3fd43e 100644
--- a/src/services/collection-files-service/collection-manifest-mapper.ts
+++ b/src/services/collection-files-service/collection-manifest-mapper.ts
@@ -3,8 +3,8 @@
// SPDX-License-Identifier: AGPL-3.0
import { uniqBy, groupBy } from 'lodash';
-import { KeepManifestStream, KeepManifestStreamFile, KeepManifest } from "../../models/keep-manifest";
-import { TreeNode, setNode, createTree, getNodeDescendants, getNodeValue } from '../../models/tree';
+import { KeepManifestStream, KeepManifestStreamFile, KeepManifest } from "~/models/keep-manifest";
+import { TreeNode, setNode, createTree, getNodeDescendants, getNodeValue } from '~/models/tree';
import { CollectionFilesTree, CollectionFile, CollectionDirectory, createCollectionDirectory, createCollectionFile, CollectionFileType } from '../../models/collection-file';
export const mapCollectionFilesTreeToManifest = (tree: CollectionFilesTree): KeepManifest => {
diff --git a/src/services/collection-files-service/collection-manifest-parser.ts b/src/services/collection-files-service/collection-manifest-parser.ts
index b0fc55a..d564f33 100644
--- a/src/services/collection-files-service/collection-manifest-parser.ts
+++ b/src/services/collection-files-service/collection-manifest-parser.ts
@@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { KeepManifestStream, KeepManifestStreamFile, KeepManifest } from "../../models/keep-manifest";
+import { KeepManifestStream, KeepManifestStreamFile, KeepManifest } from "~/models/keep-manifest";
/**
* Documentation [http://doc.arvados.org/api/storage.html](http://doc.arvados.org/api/storage.html)
diff --git a/src/services/collection-service/collection-service.ts b/src/services/collection-service/collection-service.ts
index 4d75036..f60e81f 100644
--- a/src/services/collection-service/collection-service.ts
+++ b/src/services/collection-service/collection-service.ts
@@ -2,15 +2,15 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { CommonResourceService } from "../../common/api/common-resource-service";
-import { CollectionResource } from "../../models/collection";
+import { CommonResourceService } from "~/common/api/common-resource-service";
+import { CollectionResource } from "~/models/collection";
import axios, { AxiosInstance } from "axios";
import { KeepService } from "../keep-service/keep-service";
-import { FilterBuilder } from "../../common/api/filter-builder";
-import { CollectionFile, createCollectionFile } from "../../models/collection-file";
+import { FilterBuilder } from "~/common/api/filter-builder";
+import { CollectionFile, createCollectionFile } from "~/models/collection-file";
import { parseKeepManifestText, stringifyKeepManifest } from "../collection-files-service/collection-manifest-parser";
import * as _ from "lodash";
-import { KeepManifestStream } from "../../models/keep-manifest";
+import { KeepManifestStream } from "~/models/keep-manifest";
export type UploadProgress = (fileId: number, loaded: number, total: number, currentTime: number) => void;
diff --git a/src/services/favorite-service/favorite-order-builder.ts b/src/services/favorite-service/favorite-order-builder.ts
index 0d9a75e..fc6cbdc 100644
--- a/src/services/favorite-service/favorite-order-builder.ts
+++ b/src/services/favorite-service/favorite-order-builder.ts
@@ -2,14 +2,14 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { LinkResource } from "../../models/link";
+import { LinkResource } from "~/models/link";
import { GroupContentsResource, GroupContentsResourcePrefix } from "../groups-service/groups-service";
-import { OrderBuilder } from "../../common/api/order-builder";
+import { OrderBuilder } from "~/common/api/order-builder";
export class FavoriteOrderBuilder {
static create(
- linkOrder = OrderBuilder.create<LinkResource>(),
+ linkOrder = OrderBuilder.create<LinkResource>(),
contentOrder = OrderBuilder.create<GroupContentsResource>()) {
return new FavoriteOrderBuilder(linkOrder, contentOrder);
}
@@ -45,4 +45,4 @@ export class FavoriteOrderBuilder {
return this.contentOrder;
}
-}
\ No newline at end of file
+}
diff --git a/src/services/favorite-service/favorite-service.test.ts b/src/services/favorite-service/favorite-service.test.ts
index 3bc959d..de59ff8 100644
--- a/src/services/favorite-service/favorite-service.test.ts
+++ b/src/services/favorite-service/favorite-service.test.ts
@@ -3,11 +3,11 @@
// SPDX-License-Identifier: AGPL-3.0
import { LinkService } from "../link-service/link-service";
-import { GroupsService, GroupContentsResource } from "../groups-service/groups-service";
+import { GroupsService } from "../groups-service/groups-service";
import { FavoriteService } from "./favorite-service";
-import { LinkClass, LinkResource } from "../../models/link";
-import { mockResourceService } from "../../common/api/common-resource-service.test";
-import { FilterBuilder } from "../../common/api/filter-builder";
+import { LinkClass } from "~/models/link";
+import { mockResourceService } from "~/common/api/common-resource-service.test";
+import { FilterBuilder } from "~/common/api/filter-builder";
describe("FavoriteService", () => {
diff --git a/src/services/favorite-service/favorite-service.ts b/src/services/favorite-service/favorite-service.ts
index 35dbbaf..d948819 100644
--- a/src/services/favorite-service/favorite-service.ts
+++ b/src/services/favorite-service/favorite-service.ts
@@ -4,11 +4,11 @@
import { LinkService } from "../link-service/link-service";
import { GroupsService, GroupContentsResource } from "../groups-service/groups-service";
-import { LinkResource, LinkClass } from "../../models/link";
-import { FilterBuilder } from "../../common/api/filter-builder";
-import { ListArguments, ListResults } from "../../common/api/common-resource-service";
+import { LinkResource, LinkClass } from "~/models/link";
+import { FilterBuilder } from "~/common/api/filter-builder";
+import { ListResults } from "~/common/api/common-resource-service";
import { FavoriteOrderBuilder } from "./favorite-order-builder";
-import { OrderBuilder } from "../../common/api/order-builder";
+import { OrderBuilder } from "~/common/api/order-builder";
export interface FavoriteListArguments {
limit?: number;
diff --git a/src/services/groups-service/groups-service.ts b/src/services/groups-service/groups-service.ts
index a0f27a4..e4c3167 100644
--- a/src/services/groups-service/groups-service.ts
+++ b/src/services/groups-service/groups-service.ts
@@ -3,14 +3,14 @@
// SPDX-License-Identifier: AGPL-3.0
import * as _ from "lodash";
-import { CommonResourceService, ListResults } from "../../common/api/common-resource-service";
-import { FilterBuilder } from "../../common/api/filter-builder";
-import { OrderBuilder } from "../../common/api/order-builder";
+import { CommonResourceService, ListResults } from "~/common/api/common-resource-service";
+import { FilterBuilder } from "~/common/api/filter-builder";
+import { OrderBuilder } from "~/common/api/order-builder";
import { AxiosInstance } from "axios";
-import { GroupResource } from "../../models/group";
-import { CollectionResource } from "../../models/collection";
-import { ProjectResource } from "../../models/project";
-import { ProcessResource } from "../../models/process";
+import { GroupResource } from "~/models/group";
+import { CollectionResource } from "~/models/collection";
+import { ProjectResource } from "~/models/project";
+import { ProcessResource } from "~/models/process";
export interface ContentsArguments {
limit?: number;
diff --git a/src/services/keep-service/keep-service.ts b/src/services/keep-service/keep-service.ts
index 188e45a..fd49823 100644
--- a/src/services/keep-service/keep-service.ts
+++ b/src/services/keep-service/keep-service.ts
@@ -2,9 +2,9 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { CommonResourceService } from "../../common/api/common-resource-service";
+import { CommonResourceService } from "~/common/api/common-resource-service";
import { AxiosInstance } from "axios";
-import { KeepResource } from "../../models/keep";
+import { KeepResource } from "~/models/keep";
export class KeepService extends CommonResourceService<KeepResource> {
constructor(serverApi: AxiosInstance) {
diff --git a/src/services/link-service/link-service.ts b/src/services/link-service/link-service.ts
index 4c12cd0..8724904 100644
--- a/src/services/link-service/link-service.ts
+++ b/src/services/link-service/link-service.ts
@@ -2,12 +2,12 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { CommonResourceService } from "../../common/api/common-resource-service";
-import { LinkResource } from "../../models/link";
+import { CommonResourceService } from "~/common/api/common-resource-service";
+import { LinkResource } from "~/models/link";
import { AxiosInstance } from "axios";
export class LinkService extends CommonResourceService<LinkResource> {
constructor(serverApi: AxiosInstance) {
super(serverApi, "links");
}
-}
\ No newline at end of file
+}
diff --git a/src/services/project-service/project-service.test.ts b/src/services/project-service/project-service.test.ts
index eb7ea74..688a476 100644
--- a/src/services/project-service/project-service.test.ts
+++ b/src/services/project-service/project-service.test.ts
@@ -4,8 +4,7 @@
import axios from "axios";
import { ProjectService } from "./project-service";
-import { FilterBuilder } from "../../common/api/filter-builder";
-import { ProjectResource } from "../../models/project";
+import { FilterBuilder } from "~/common/api/filter-builder";
describe("CommonResourceService", () => {
const axiosInstance = axios.create();
@@ -20,7 +19,6 @@ describe("CommonResourceService", () => {
});
});
-
it("#list has groupClass filter set by default", async () => {
axiosInstance.get = jest.fn(() => Promise.resolve({ data: {} }));
const projectService = new ProjectService(axiosInstance);
@@ -34,5 +32,4 @@ describe("CommonResourceService", () => {
}
});
});
-
});
diff --git a/src/services/project-service/project-service.ts b/src/services/project-service/project-service.ts
index 13c60ad..3ffaa35 100644
--- a/src/services/project-service/project-service.ts
+++ b/src/services/project-service/project-service.ts
@@ -2,11 +2,11 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { GroupsService, ContentsArguments } from "../groups-service/groups-service";
-import { ProjectResource } from "../../models/project";
-import { GroupClass } from "../../models/group";
-import { ListArguments } from "../../common/api/common-resource-service";
-import { FilterBuilder } from "../../common/api/filter-builder";
+import { GroupsService } from "../groups-service/groups-service";
+import { ProjectResource } from "~/models/project";
+import { GroupClass } from "~/models/group";
+import { ListArguments } from "~/common/api/common-resource-service";
+import { FilterBuilder } from "~/common/api/filter-builder";
export class ProjectService extends GroupsService<ProjectResource> {
diff --git a/src/services/services.ts b/src/services/services.ts
index e77b5d3..427148b 100644
--- a/src/services/services.ts
+++ b/src/services/services.ts
@@ -2,15 +2,14 @@
//
// SPDX-License-Identifier: AGPL-3.0
+import Axios, { AxiosInstance } from "axios";
import { AuthService } from "./auth-service/auth-service";
import { GroupsService } from "./groups-service/groups-service";
import { ProjectService } from "./project-service/project-service";
import { LinkService } from "./link-service/link-service";
import { FavoriteService } from "./favorite-service/favorite-service";
-import { AxiosInstance } from "axios";
import { CollectionService } from "./collection-service/collection-service";
import { TagService } from "./tag-service/tag-service";
-import Axios from "axios";
import { CollectionFilesService } from "./collection-files-service/collection-files-service";
import { KeepService } from "./keep-service/keep-service";
diff --git a/src/services/tag-service/tag-service.ts b/src/services/tag-service/tag-service.ts
index 084603e..78fdcee 100644
--- a/src/services/tag-service/tag-service.ts
+++ b/src/services/tag-service/tag-service.ts
@@ -3,10 +3,10 @@
// SPDX-License-Identifier: AGPL-3.0
import { LinkService } from "../link-service/link-service";
-import { LinkClass } from "../../models/link";
-import { FilterBuilder } from "../../common/api/filter-builder";
-import { TagTailType, TagResource } from "../../models/tag";
-import { OrderBuilder } from "../../common/api/order-builder";
+import { LinkClass } from "~/models/link";
+import { FilterBuilder } from "~/common/api/filter-builder";
+import { TagTailType, TagResource } from "~/models/tag";
+import { OrderBuilder } from "~/common/api/order-builder";
export class TagService {
@@ -41,5 +41,4 @@ export class TagService {
return results.items.map((tag => tag as TagResource ));
});
}
-
}
diff --git a/src/store/auth/auth-action.ts b/src/store/auth/auth-action.ts
index 6b81c31..9f429f0 100644
--- a/src/store/auth/auth-action.ts
+++ b/src/store/auth/auth-action.ts
@@ -4,9 +4,9 @@
import { ofType, default as unionize, UnionOf } from "unionize";
import { Dispatch } from "redux";
-import { User } from "../../models/user";
+import { User } from "~/models/user";
import { RootState } from "../store";
-import { ServiceRepository } from "../../services/services";
+import { ServiceRepository } from "~/services/services";
import { AxiosInstance } from "axios";
export const authActions = unionize({
diff --git a/src/store/auth/auth-actions.test.ts b/src/store/auth/auth-actions.test.ts
index 1ded88e..dd928e0 100644
--- a/src/store/auth/auth-actions.test.ts
+++ b/src/store/auth/auth-actions.test.ts
@@ -11,10 +11,10 @@ import {
USER_LAST_NAME_KEY,
USER_OWNER_UUID_KEY,
USER_UUID_KEY
-} from "../../services/auth-service/auth-service";
+} from "~/services/auth-service/auth-service";
import 'jest-localstorage-mock';
-import { createServices } from "../../services/services";
+import { createServices } from "~/services/services";
import { configureStore, RootStore } from "../store";
import createBrowserHistory from "history/createBrowserHistory";
diff --git a/src/store/auth/auth-reducer.test.ts b/src/store/auth/auth-reducer.test.ts
index 0e05263..bc9d34e 100644
--- a/src/store/auth/auth-reducer.test.ts
+++ b/src/store/auth/auth-reducer.test.ts
@@ -6,7 +6,7 @@ import { authReducer, AuthState } from "./auth-reducer";
import { AuthAction, authActions } from "./auth-action";
import 'jest-localstorage-mock';
-import { createServices } from "../../services/services";
+import { createServices } from "~/services/services";
describe('auth-reducer', () => {
let reducer: (state: AuthState | undefined, action: AuthAction) => any;
diff --git a/src/store/auth/auth-reducer.ts b/src/store/auth/auth-reducer.ts
index 1546212..a419532 100644
--- a/src/store/auth/auth-reducer.ts
+++ b/src/store/auth/auth-reducer.ts
@@ -3,8 +3,8 @@
// SPDX-License-Identifier: AGPL-3.0
import { authActions, AuthAction } from "./auth-action";
-import { User } from "../../models/user";
-import { ServiceRepository } from "../../services/services";
+import { User } from "~/models/user";
+import { ServiceRepository } from "~/services/services";
export interface AuthState {
user?: User;
diff --git a/src/store/collection-panel/collection-panel-action.ts b/src/store/collection-panel/collection-panel-action.ts
index f2774f6..0772210 100644
--- a/src/store/collection-panel/collection-panel-action.ts
+++ b/src/store/collection-panel/collection-panel-action.ts
@@ -4,13 +4,13 @@
import { unionize, ofType, UnionOf } from "unionize";
import { Dispatch } from "redux";
-import { ResourceKind } from "../../models/resource";
-import { CollectionResource } from "../../models/collection";
+import { ResourceKind } from "~/models/resource";
+import { CollectionResource } from "~/models/collection";
import { collectionPanelFilesAction } from "./collection-panel-files/collection-panel-files-actions";
-import { createTree } from "../../models/tree";
+import { createTree } from "~/models/tree";
import { RootState } from "../store";
-import { ServiceRepository } from "../../services/services";
-import { TagResource, TagProperty } from "../../models/tag";
+import { ServiceRepository } from "~/services/services";
+import { TagResource, TagProperty } from "~/models/tag";
import { snackbarActions } from "../snackbar/snackbar-actions";
export const collectionPanelActions = unionize({
@@ -43,7 +43,7 @@ export const loadCollection = (uuid: string, kind: ResourceKind) =>
});
};
-export const loadCollectionTags = (uuid: string) =>
+export const loadCollectionTags = (uuid: string) =>
(dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
dispatch(collectionPanelActions.LOAD_COLLECTION_TAGS({ uuid }));
return services.tagService
@@ -54,7 +54,7 @@ export const loadCollectionTags = (uuid: string) =>
};
-export const createCollectionTag = (data: TagProperty) =>
+export const createCollectionTag = (data: TagProperty) =>
(dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
dispatch(collectionPanelActions.CREATE_COLLECTION_TAG({ data }));
const item = getState().collectionPanel.item;
@@ -70,7 +70,7 @@ export const createCollectionTag = (data: TagProperty) =>
});
};
-export const deleteCollectionTag = (uuid: string) =>
+export const deleteCollectionTag = (uuid: string) =>
(dispatch: Dispatch, getState: () => RootState, services: ServiceRepository) => {
dispatch(collectionPanelActions.DELETE_COLLECTION_TAG({ uuid }));
return services.linkService
@@ -82,4 +82,4 @@ export const deleteCollectionTag = (uuid: string) =>
hideDuration: 2000
}));
});
- };
\ No newline at end of file
+ };
diff --git a/src/store/collection-panel/collection-panel-files/collection-panel-files-actions.ts b/src/store/collection-panel/collection-panel-files/collection-panel-files-actions.ts
index 463d49c..0982108 100644
--- a/src/store/collection-panel/collection-panel-files/collection-panel-files-actions.ts
+++ b/src/store/collection-panel/collection-panel-files/collection-panel-files-actions.ts
@@ -3,7 +3,7 @@
// SPDX-License-Identifier: AGPL-3.0
import { default as unionize, ofType, UnionOf } from "unionize";
-import { CollectionFilesTree } from "../../../models/collection-file";
+import { CollectionFilesTree } from "~/models/collection-file";
export const collectionPanelFilesAction = unionize({
SET_COLLECTION_FILES: ofType<CollectionFilesTree>(),
@@ -13,4 +13,4 @@ export const collectionPanelFilesAction = unionize({
UNSELECT_ALL_COLLECTION_FILES: ofType<{}>(),
}, { tag: 'type', value: 'payload' });
-export type CollectionPanelFilesAction = UnionOf<typeof collectionPanelFilesAction>;
\ No newline at end of file
+export type CollectionPanelFilesAction = UnionOf<typeof collectionPanelFilesAction>;
diff --git a/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.test.ts b/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.test.ts
index 94b71ff..90dedaa 100644
--- a/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.test.ts
+++ b/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.test.ts
@@ -4,8 +4,8 @@
import { collectionPanelFilesReducer } from "./collection-panel-files-reducer";
import { collectionPanelFilesAction } from "./collection-panel-files-actions";
-import { CollectionFile, CollectionDirectory, createCollectionFile, createCollectionDirectory } from "../../../models/collection-file";
-import { createTree, setNode, getNodeValue, mapTreeValues, Tree } from "../../../models/tree";
+import { CollectionFile, CollectionDirectory, createCollectionFile, createCollectionDirectory } from "~/models/collection-file";
+import { createTree, setNode, getNodeValue, mapTreeValues } from "~/models/tree";
import { CollectionPanelFile, CollectionPanelDirectory } from "./collection-panel-files-state";
describe('CollectionPanelFilesReducer', () => {
diff --git a/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.ts b/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.ts
index ca518f0..2a3aac7 100644
--- a/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.ts
+++ b/src/store/collection-panel/collection-panel-files/collection-panel-files-reducer.ts
@@ -4,8 +4,8 @@
import { CollectionPanelFilesState, CollectionPanelFile, CollectionPanelDirectory, mapCollectionFileToCollectionPanelFile } from "./collection-panel-files-state";
import { CollectionPanelFilesAction, collectionPanelFilesAction } from "./collection-panel-files-actions";
-import { createTree, mapTreeValues, getNode, setNode, getNodeAncestors, getNodeDescendants, setNodeValueWith, mapTree } from "../../../models/tree";
-import { CollectionFileType } from "../../../models/collection-file";
+import { createTree, mapTreeValues, getNode, setNode, getNodeAncestors, getNodeDescendants, setNodeValueWith, mapTree } from "~/models/tree";
+import { CollectionFileType } from "~/models/collection-file";
export const collectionPanelFilesReducer = (state: CollectionPanelFilesState = createTree(), action: CollectionPanelFilesAction) => {
return collectionPanelFilesAction.match(action, {
diff --git a/src/store/collection-panel/collection-panel-files/collection-panel-files-state.ts b/src/store/collection-panel/collection-panel-files/collection-panel-files-state.ts
index d6f2fa4..f7955eb 100644
--- a/src/store/collection-panel/collection-panel-files/collection-panel-files-state.ts
+++ b/src/store/collection-panel/collection-panel-files/collection-panel-files-state.ts
@@ -2,8 +2,8 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { CollectionFile, CollectionDirectory, CollectionFileType } from '../../../models/collection-file';
-import { Tree, TreeNode } from '../../../models/tree';
+import { CollectionFile, CollectionDirectory, CollectionFileType } from '~/models/collection-file';
+import { Tree, TreeNode } from '~/models/tree';
export type CollectionPanelFilesState = Tree<CollectionPanelDirectory | CollectionPanelFile>;
@@ -23,4 +23,4 @@ export const mapCollectionFileToCollectionPanelFile = (node: TreeNode<Collection
? { ...node.value, selected: false, collapsed: true }
: { ...node.value, selected: false }
};
-};
\ No newline at end of file
+};
diff --git a/src/store/collection-panel/collection-panel-reducer.ts b/src/store/collection-panel/collection-panel-reducer.ts
index 44b7789..2c3edf1 100644
--- a/src/store/collection-panel/collection-panel-reducer.ts
+++ b/src/store/collection-panel/collection-panel-reducer.ts
@@ -3,8 +3,8 @@
// SPDX-License-Identifier: AGPL-3.0
import { collectionPanelActions, CollectionPanelAction } from "./collection-panel-action";
-import { CollectionResource } from "../../models/collection";
-import { TagResource } from "../../models/tag";
+import { CollectionResource } from "~/models/collection";
+import { TagResource } from "~/models/tag";
export interface CollectionPanelState {
item: CollectionResource | null;
diff --git a/src/store/collections/creator/collection-creator-action.ts b/src/store/collections/creator/collection-creator-action.ts
index d0a66b4..323ba8d 100644
--- a/src/store/collections/creator/collection-creator-action.ts
+++ b/src/store/collections/creator/collection-creator-action.ts
@@ -6,8 +6,8 @@ import { default as unionize, ofType, UnionOf } from "unionize";
import { Dispatch } from "redux";
import { RootState } from "../../store";
-import { CollectionResource } from '../../../models/collection';
-import { ServiceRepository } from "../../../services/services";
+import { CollectionResource } from '~/models/collection';
+import { ServiceRepository } from "~/services/services";
import { collectionUploaderActions } from "../uploader/collection-uploader-actions";
import { reset } from "redux-form";
diff --git a/src/store/collections/updater/collection-updater-action.ts b/src/store/collections/updater/collection-updater-action.ts
index bb9f4d3..25b2f37 100644
--- a/src/store/collections/updater/collection-updater-action.ts
+++ b/src/store/collections/updater/collection-updater-action.ts
@@ -6,8 +6,8 @@ import { default as unionize, ofType, UnionOf } from "unionize";
import { Dispatch } from "redux";
import { RootState } from "../../store";
-import { ServiceRepository } from "../../../services/services";
-import { CollectionResource } from '../../../models/collection';
+import { ServiceRepository } from "~/services/services";
+import { CollectionResource } from '~/models/collection';
import { initialize } from 'redux-form';
import { collectionPanelActions } from "../../collection-panel/collection-panel-action";
import { ContextMenuResource } from "../../context-menu/context-menu-reducer";
diff --git a/src/store/data-explorer/data-explorer-action.ts b/src/store/data-explorer/data-explorer-action.ts
index 6dd7af9..abb293f 100644
--- a/src/store/data-explorer/data-explorer-action.ts
+++ b/src/store/data-explorer/data-explorer-action.ts
@@ -3,8 +3,8 @@
// SPDX-License-Identifier: AGPL-3.0
import { default as unionize, ofType, UnionOf } from "unionize";
-import { DataTableFilterItem } from "../../components/data-table-filters/data-table-filters";
-import { DataColumns } from "../../components/data-table/data-table";
+import { DataTableFilterItem } from "~/components/data-table-filters/data-table-filters";
+import { DataColumns } from "~/components/data-table/data-table";
export const dataExplorerActions = unionize({
RESET_PAGINATION: ofType<{ id: string }>(),
diff --git a/src/store/data-explorer/data-explorer-middleware.test.ts b/src/store/data-explorer/data-explorer-middleware.test.ts
index 6b8297b..d93ccbf 100644
--- a/src/store/data-explorer/data-explorer-middleware.test.ts
+++ b/src/store/data-explorer/data-explorer-middleware.test.ts
@@ -5,12 +5,12 @@
import { DataExplorerMiddlewareService } from "./data-explorer-middleware-service";
import { dataExplorerMiddleware } from "./data-explorer-middleware";
import { MiddlewareAPI } from "redux";
-import { DataColumns } from "../../components/data-table/data-table";
+import { DataColumns } from "~/components/data-table/data-table";
import { dataExplorerActions } from "./data-explorer-action";
describe("DataExplorerMiddleware", () => {
-
+
it("handles only actions that are identified by service id", () => {
const config = {
id: "ServiceId",
diff --git a/src/store/data-explorer/data-explorer-reducer.test.tsx b/src/store/data-explorer/data-explorer-reducer.test.tsx
index c54a86a..6b1c907 100644
--- a/src/store/data-explorer/data-explorer-reducer.test.tsx
+++ b/src/store/data-explorer/data-explorer-reducer.test.tsx
@@ -13,7 +13,8 @@ describe('data-explorer-reducer', () => {
const columns: DataColumns<any> = [{
name: "Column 1",
render: jest.fn(),
- selected: true
+ selected: true,
+ configurable: true
}];
const state = dataExplorerReducer(undefined,
dataExplorerActions.SET_COLUMNS({ id: "Data explorer", columns }));
@@ -25,11 +26,13 @@ describe('data-explorer-reducer', () => {
name: "Column 1",
render: jest.fn(),
selected: true,
+ configurable: true,
sortDirection: SortDirection.ASC
}, {
name: "Column 2",
render: jest.fn(),
selected: true,
+ configurable: true,
sortDirection: SortDirection.NONE,
}];
const state = dataExplorerReducer({ "Data explorer": { ...initialDataExplorer, columns } },
@@ -43,6 +46,7 @@ describe('data-explorer-reducer', () => {
name: "Column 1",
render: jest.fn(),
selected: true,
+ configurable: true
}];
const filters: DataTableFilterItem[] = [{
@@ -55,7 +59,7 @@ describe('data-explorer-reducer', () => {
});
it('should set items', () => {
- const state = dataExplorerReducer({ "Data explorer": undefined },
+ const state = dataExplorerReducer({},
dataExplorerActions.SET_ITEMS({
id: "Data explorer",
items: ["Item 1", "Item 2"],
@@ -67,13 +71,13 @@ describe('data-explorer-reducer', () => {
});
it('should set page', () => {
- const state = dataExplorerReducer({ "Data explorer": undefined },
+ const state = dataExplorerReducer({},
dataExplorerActions.SET_PAGE({ id: "Data explorer", page: 2 }));
expect(state["Data explorer"].page).toEqual(2);
});
it('should set rows per page', () => {
- const state = dataExplorerReducer({ "Data explorer": undefined },
+ const state = dataExplorerReducer({},
dataExplorerActions.SET_ROWS_PER_PAGE({ id: "Data explorer", rowsPerPage: 5 }));
expect(state["Data explorer"].rowsPerPage).toEqual(5);
});
diff --git a/src/store/data-explorer/data-explorer-reducer.ts b/src/store/data-explorer/data-explorer-reducer.ts
index 1fde652..175cd0b 100644
--- a/src/store/data-explorer/data-explorer-reducer.ts
+++ b/src/store/data-explorer/data-explorer-reducer.ts
@@ -2,10 +2,10 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { DataColumn, toggleSortDirection, resetSortDirection } from "../../components/data-table/data-column";
+import { DataColumn, toggleSortDirection, resetSortDirection } from "~/components/data-table/data-column";
import { dataExplorerActions, DataExplorerAction } from "./data-explorer-action";
-import { DataTableFilterItem } from "../../components/data-table-filters/data-table-filters";
-import { DataColumns } from "../../components/data-table/data-table";
+import { DataTableFilterItem } from "~/components/data-table-filters/data-table-filters";
+import { DataColumns } from "~/components/data-table/data-table";
export interface DataExplorer {
columns: DataColumns<any>;
diff --git a/src/store/details-panel/details-panel-action.ts b/src/store/details-panel/details-panel-action.ts
index c4acf5a..cadf517 100644
--- a/src/store/details-panel/details-panel-action.ts
+++ b/src/store/details-panel/details-panel-action.ts
@@ -4,9 +4,9 @@
import { unionize, ofType, UnionOf } from "unionize";
import { Dispatch } from "redux";
-import { Resource, ResourceKind } from "../../models/resource";
+import { Resource, ResourceKind } from "~/models/resource";
import { RootState } from "../store";
-import { ServiceRepository } from "../../services/services";
+import { ServiceRepository } from "~/services/services";
export const detailsPanelActions = unionize({
TOGGLE_DETAILS_PANEL: ofType<{}>(),
diff --git a/src/store/details-panel/details-panel-reducer.ts b/src/store/details-panel/details-panel-reducer.ts
index 97de4a9..adc31e4 100644
--- a/src/store/details-panel/details-panel-reducer.ts
+++ b/src/store/details-panel/details-panel-reducer.ts
@@ -3,7 +3,7 @@
// SPDX-License-Identifier: AGPL-3.0
import { detailsPanelActions, DetailsPanelAction } from "./details-panel-action";
-import { Resource } from "../../models/resource";
+import { Resource } from "~/models/resource";
export interface DetailsPanelState {
item: Resource | null;
diff --git a/src/store/favorite-panel/favorite-panel-middleware-service.ts b/src/store/favorite-panel/favorite-panel-middleware-service.ts
index be4b645..6531841 100644
--- a/src/store/favorite-panel/favorite-panel-middleware-service.ts
+++ b/src/store/favorite-panel/favorite-panel-middleware-service.ts
@@ -3,15 +3,14 @@
// SPDX-License-Identifier: AGPL-3.0
import { DataExplorerMiddlewareService } from "../data-explorer/data-explorer-middleware-service";
-import { FavoritePanelFilter, FavoritePanelColumnNames } from "../../views/favorite-panel/favorite-panel";
+import { FavoritePanelFilter, FavoritePanelColumnNames } from "~/views/favorite-panel/favorite-panel";
import { RootState } from "../store";
-import { DataColumns } from "../../components/data-table/data-table";
-import { FavoritePanelItem, resourceToDataItem } from "../../views/favorite-panel/favorite-panel-item";
-import { FavoriteOrderBuilder } from "../../services/favorite-service/favorite-order-builder";
-import { ServiceRepository } from "../../services/services";
-import { SortDirection } from "../../components/data-table/data-column";
-import { FilterBuilder } from "../../common/api/filter-builder";
-import { LinkResource } from "../../models/link";
+import { DataColumns } from "~/components/data-table/data-table";
+import { FavoritePanelItem, resourceToDataItem } from "~/views/favorite-panel/favorite-panel-item";
+import { FavoriteOrderBuilder } from "~/services/favorite-service/favorite-order-builder";
+import { ServiceRepository } from "~/services/services";
+import { SortDirection } from "~/components/data-table/data-column";
+import { FilterBuilder } from "~/common/api/filter-builder";
import { checkPresenceInFavorites } from "../favorites/favorites-actions";
import { favoritePanelActions } from "./favorite-panel-action";
import { Dispatch, MiddlewareAPI } from "redux";
diff --git a/src/store/favorites/favorites-actions.ts b/src/store/favorites/favorites-actions.ts
index 38229df..9e1b3ef 100644
--- a/src/store/favorites/favorites-actions.ts
+++ b/src/store/favorites/favorites-actions.ts
@@ -7,7 +7,7 @@ import { Dispatch } from "redux";
import { RootState } from "../store";
import { checkFavorite } from "./favorites-reducer";
import { snackbarActions } from "../snackbar/snackbar-actions";
-import { ServiceRepository } from "../../services/services";
+import { ServiceRepository } from "~/services/services";
export const favoritesActions = unionize({
TOGGLE_FAVORITE: ofType<{ resourceUuid: string }>(),
diff --git a/src/store/navigation/navigation-action.ts b/src/store/navigation/navigation-action.ts
index defddad..e50bce0 100644
--- a/src/store/navigation/navigation-action.ts
+++ b/src/store/navigation/navigation-action.ts
@@ -5,18 +5,18 @@
import { Dispatch } from "redux";
import { projectActions, getProjectList } from "../project/project-action";
import { push } from "react-router-redux";
-import { TreeItemStatus } from "../../components/tree/tree";
+import { TreeItemStatus } from "~/components/tree/tree";
import { findTreeItem } from "../project/project-reducer";
import { RootState } from "../store";
-import { Resource, ResourceKind } from "../../models/resource";
+import { Resource, ResourceKind } from "~/models/resource";
import { projectPanelActions } from "../project-panel/project-panel-action";
-import { getCollectionUrl } from "../../models/collection";
-import { getProjectUrl, ProjectResource } from "../../models/project";
-import { ProjectService } from "../../services/project-service/project-service";
-import { ServiceRepository } from "../../services/services";
+import { getCollectionUrl } from "~/models/collection";
+import { getProjectUrl, ProjectResource } from "~/models/project";
+import { ProjectService } from "~/services/project-service/project-service";
+import { ServiceRepository } from "~/services/services";
import { sidePanelActions } from "../side-panel/side-panel-action";
import { SidePanelIdentifiers } from "../side-panel/side-panel-reducer";
-import { getUuidObjectType, ObjectTypes } from "../../models/object-types";
+import { getUuidObjectType, ObjectTypes } from "~/models/object-types";
export const getResourceUrl = <T extends Resource>(resource: T): string => {
switch (resource.kind) {
@@ -60,7 +60,6 @@ export const setProjectItem = (itemId: string, itemMode: ItemMode) =>
dispatch(projectPanelActions.RESET_PAGINATION());
dispatch(projectPanelActions.REQUEST_ITEMS());
}));
-
}
};
diff --git a/src/store/project-panel/project-panel-middleware-service.ts b/src/store/project-panel/project-panel-middleware-service.ts
index fd893a3..cc5207b 100644
--- a/src/store/project-panel/project-panel-middleware-service.ts
+++ b/src/store/project-panel/project-panel-middleware-service.ts
@@ -3,16 +3,15 @@
// SPDX-License-Identifier: AGPL-3.0
import { DataExplorerMiddlewareService } from "../data-explorer/data-explorer-middleware-service";
-import { ProjectPanelColumnNames, ProjectPanelFilter } from "../../views/project-panel/project-panel";
+import { ProjectPanelColumnNames, ProjectPanelFilter } from "~/views/project-panel/project-panel";
import { RootState } from "../store";
-import { DataColumns } from "../../components/data-table/data-table";
-import { ServiceRepository } from "../../services/services";
-import { ProjectPanelItem, resourceToDataItem } from "../../views/project-panel/project-panel-item";
-import { SortDirection } from "../../components/data-table/data-column";
-import { OrderBuilder } from "../../common/api/order-builder";
-import { FilterBuilder } from "../../common/api/filter-builder";
-import { ProcessResource } from "../../models/process";
-import { GroupContentsResourcePrefix, GroupContentsResource } from "../../services/groups-service/groups-service";
+import { DataColumns } from "~/components/data-table/data-table";
+import { ServiceRepository } from "~/services/services";
+import { ProjectPanelItem, resourceToDataItem } from "~/views/project-panel/project-panel-item";
+import { SortDirection } from "~/components/data-table/data-column";
+import { OrderBuilder } from "~/common/api/order-builder";
+import { FilterBuilder } from "~/common/api/filter-builder";
+import { GroupContentsResourcePrefix, GroupContentsResource } from "~/services/groups-service/groups-service";
import { checkPresenceInFavorites } from "../favorites/favorites-actions";
import { projectPanelActions } from "./project-panel-action";
import { Dispatch, MiddlewareAPI } from "redux";
diff --git a/src/store/project/project-action.ts b/src/store/project/project-action.ts
index 5caf012..20b255c 100644
--- a/src/store/project/project-action.ts
+++ b/src/store/project/project-action.ts
@@ -3,12 +3,12 @@
// SPDX-License-Identifier: AGPL-3.0
import { default as unionize, ofType, UnionOf } from "unionize";
-import { ProjectResource } from "../../models/project";
+import { ProjectResource } from "~/models/project";
import { Dispatch } from "redux";
-import { FilterBuilder } from "../../common/api/filter-builder";
+import { FilterBuilder } from "~/common/api/filter-builder";
import { RootState } from "../store";
import { checkPresenceInFavorites } from "../favorites/favorites-actions";
-import { ServiceRepository } from "../../services/services";
+import { ServiceRepository } from "~/services/services";
export const projectActions = unionize({
OPEN_PROJECT_CREATOR: ofType<{ ownerUuid: string }>(),
diff --git a/src/store/project/project-reducer.test.ts b/src/store/project/project-reducer.test.ts
index 92274b3..cd96afc 100644
--- a/src/store/project/project-reducer.test.ts
+++ b/src/store/project/project-reducer.test.ts
@@ -4,8 +4,8 @@
import { projectsReducer, getTreePath } from "./project-reducer";
import { projectActions } from "./project-action";
-import { TreeItem, TreeItemStatus } from "../../components/tree/tree";
-import { mockProjectResource } from "../../models/test-utils";
+import { TreeItem, TreeItemStatus } from "~/components/tree/tree";
+import { mockProjectResource } from "~/models/test-utils";
describe('project-reducer', () => {
diff --git a/src/store/project/project-reducer.ts b/src/store/project/project-reducer.ts
index f5af23a..4249007 100644
--- a/src/store/project/project-reducer.ts
+++ b/src/store/project/project-reducer.ts
@@ -5,8 +5,8 @@
import * as _ from "lodash";
import { projectActions, ProjectAction } from "./project-action";
-import { TreeItem, TreeItemStatus } from "../../components/tree/tree";
-import { ProjectResource } from "../../models/project";
+import { TreeItem, TreeItemStatus } from "~/components/tree/tree";
+import { ProjectResource } from "~/models/project";
export type ProjectState = {
items: Array<TreeItem<ProjectResource>>,
diff --git a/src/store/side-panel/side-panel-reducer.test.ts b/src/store/side-panel/side-panel-reducer.test.ts
index e517fc8..4872a72 100644
--- a/src/store/side-panel/side-panel-reducer.test.ts
+++ b/src/store/side-panel/side-panel-reducer.test.ts
@@ -4,7 +4,7 @@
import { sidePanelReducer } from "./side-panel-reducer";
import { sidePanelActions } from "./side-panel-action";
-import { ProjectsIcon } from "../../components/icon/icon";
+import { ProjectsIcon } from "~/components/icon/icon";
describe('side-panel-reducer', () => {
diff --git a/src/store/side-panel/side-panel-reducer.ts b/src/store/side-panel/side-panel-reducer.ts
index cae42ac..fe06263 100644
--- a/src/store/side-panel/side-panel-reducer.ts
+++ b/src/store/side-panel/side-panel-reducer.ts
@@ -4,8 +4,8 @@
import * as _ from "lodash";
import { sidePanelActions, SidePanelAction } from './side-panel-action';
-import { SidePanelItem } from '../../components/side-panel/side-panel';
-import { ProjectsIcon, ShareMeIcon, WorkflowIcon, RecentIcon, FavoriteIcon, TrashIcon } from "../../components/icon/icon";
+import { SidePanelItem } from '~/components/side-panel/side-panel';
+import { ProjectsIcon, ShareMeIcon, WorkflowIcon, RecentIcon, FavoriteIcon, TrashIcon } from "~/components/icon/icon";
import { Dispatch } from "redux";
import { push } from "react-router-redux";
import { favoritePanelActions } from "../favorite-panel/favorite-panel-action";
diff --git a/src/store/store.ts b/src/store/store.ts
index 0002a6d..a4bf9d6 100644
--- a/src/store/store.ts
+++ b/src/store/store.ts
@@ -26,7 +26,7 @@ import { FavoritePanelMiddlewareService } from "./favorite-panel/favorite-panel-
import { CollectionPanelState, collectionPanelReducer } from './collection-panel/collection-panel-reducer';
import { DialogState, dialogReducer } from './dialog/dialog-reducer';
import { CollectionsState, collectionsReducer } from './collections/collections-reducer';
-import { ServiceRepository } from "../services/services";
+import { ServiceRepository } from "~/services/services";
import { treePickerReducer } from './tree-picker/tree-picker-reducer';
import { TreePicker } from './tree-picker/tree-picker';
diff --git a/src/store/tree-picker/tree-picker-actions.ts b/src/store/tree-picker/tree-picker-actions.ts
index 772d89d..e3bebe1 100644
--- a/src/store/tree-picker/tree-picker-actions.ts
+++ b/src/store/tree-picker/tree-picker-actions.ts
@@ -3,7 +3,6 @@
// SPDX-License-Identifier: AGPL-3.0
import { default as unionize, ofType, UnionOf } from "unionize";
-import { TreeNode } from "../../models/tree";
import { TreePickerNode } from "./tree-picker";
export const treePickerActions = unionize({
diff --git a/src/store/tree-picker/tree-picker-reducer.test.ts b/src/store/tree-picker/tree-picker-reducer.test.ts
index ac4de0c..3248cb2 100644
--- a/src/store/tree-picker/tree-picker-reducer.test.ts
+++ b/src/store/tree-picker/tree-picker-reducer.test.ts
@@ -2,12 +2,11 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { createTree, getNodeValue, getNodeChildren } from "../../models/tree";
+import { createTree, getNodeValue, getNodeChildren } from "~/models/tree";
import { TreePickerNode, createTreePickerNode } from "./tree-picker";
import { treePickerReducer } from "./tree-picker-reducer";
import { treePickerActions } from "./tree-picker-actions";
-import { TreeItemStatus } from "../../components/tree/tree";
-
+import { TreeItemStatus } from "~/components/tree/tree";
describe('TreePickerReducer', () => {
it('LOAD_TREE_PICKER_NODE - initial state', () => {
diff --git a/src/store/tree-picker/tree-picker-reducer.ts b/src/store/tree-picker/tree-picker-reducer.ts
index d195a98..8d61714 100644
--- a/src/store/tree-picker/tree-picker-reducer.ts
+++ b/src/store/tree-picker/tree-picker-reducer.ts
@@ -2,11 +2,10 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { createTree, setNodeValueWith, TreeNode, setNode, mapTree, mapTreeValues } from "../../models/tree";
+import { createTree, setNodeValueWith, TreeNode, setNode, mapTreeValues } from "~/models/tree";
import { TreePicker, TreePickerNode } from "./tree-picker";
import { treePickerActions, TreePickerAction } from "./tree-picker-actions";
-import { TreeItemStatus } from "../../components/tree/tree";
-
+import { TreeItemStatus } from "~/components/tree/tree";
export const treePickerReducer = (state: TreePicker = createTree(), action: TreePickerAction) =>
treePickerActions.match(action, {
@@ -50,4 +49,4 @@ const createTreeNode = (parent: string) => (node: TreePickerNode): TreeNode<Tree
id: node.id,
parent,
value: node
-});
\ No newline at end of file
+});
diff --git a/src/store/tree-picker/tree-picker.ts b/src/store/tree-picker/tree-picker.ts
index ee45bec..e19ce3a 100644
--- a/src/store/tree-picker/tree-picker.ts
+++ b/src/store/tree-picker/tree-picker.ts
@@ -2,8 +2,8 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { Tree } from "../../models/tree";
-import { TreeItemStatus } from "../../components/tree/tree";
+import { Tree } from "~/models/tree";
+import { TreeItemStatus } from "~/components/tree/tree";
export type TreePicker = Tree<TreePickerNode>;
@@ -20,4 +20,4 @@ export const createTreePickerNode = (data: {id: string, value: any}) => ({
selected: false,
collapsed: true,
status: TreeItemStatus.INITIAL
-});
\ No newline at end of file
+});
diff --git a/src/views-components/api-token/api-token.tsx b/src/views-components/api-token/api-token.tsx
index 0ae41c6..3dc6d1a 100644
--- a/src/views-components/api-token/api-token.tsx
+++ b/src/views-components/api-token/api-token.tsx
@@ -5,10 +5,10 @@
import { Redirect, RouteProps } from "react-router";
import * as React from "react";
import { connect, DispatchProp } from "react-redux";
-import { getUserDetails, saveApiToken } from "../../store/auth/auth-action";
-import { getProjectList } from "../../store/project/project-action";
-import { getUrlParameter } from "../../common/url";
-import { AuthService } from "../../services/auth-service/auth-service";
+import { getUserDetails, saveApiToken } from "~/store/auth/auth-action";
+import { getProjectList } from "~/store/project/project-action";
+import { getUrlParameter } from "~/common/url";
+import { AuthService } from "~/services/auth-service/auth-service";
interface ApiTokenProps {
authService: AuthService;
diff --git a/src/views-components/collection-panel-files/collection-panel-files.ts b/src/views-components/collection-panel-files/collection-panel-files.ts
index 0009fc0..ae9b53e 100644
--- a/src/views-components/collection-panel-files/collection-panel-files.ts
+++ b/src/views-components/collection-panel-files/collection-panel-files.ts
@@ -3,17 +3,17 @@
// SPDX-License-Identifier: AGPL-3.0
import { connect } from "react-redux";
-import { CollectionPanelFiles as Component, CollectionPanelFilesProps } from "../../components/collection-panel-files/collection-panel-files";
-import { RootState } from "../../store/store";
-import { TreeItemStatus, TreeItem } from "../../components/tree/tree";
-import { CollectionPanelFilesState, CollectionPanelDirectory, CollectionPanelFile } from "../../store/collection-panel/collection-panel-files/collection-panel-files-state";
-import { FileTreeData } from "../../components/file-tree/file-tree-data";
+import { CollectionPanelFiles as Component, CollectionPanelFilesProps } from "~/components/collection-panel-files/collection-panel-files";
+import { RootState } from "~/store/store";
+import { TreeItemStatus, TreeItem } from "~/components/tree/tree";
+import { CollectionPanelFilesState, CollectionPanelDirectory, CollectionPanelFile } from "~/store/collection-panel/collection-panel-files/collection-panel-files-state";
+import { FileTreeData } from "~/components/file-tree/file-tree-data";
import { Dispatch } from "redux";
-import { collectionPanelFilesAction } from "../../store/collection-panel/collection-panel-files/collection-panel-files-actions";
-import { contextMenuActions } from "../../store/context-menu/context-menu-actions";
+import { collectionPanelFilesAction } from "~/store/collection-panel/collection-panel-files/collection-panel-files-actions";
+import { contextMenuActions } from "~/store/context-menu/context-menu-actions";
import { ContextMenuKind } from "../context-menu/context-menu";
-import { Tree, getNodeChildren, getNode } from "../../models/tree";
-import { CollectionFileType } from "../../models/collection-file";
+import { Tree, getNodeChildren, getNode } from "~/models/tree";
+import { CollectionFileType } from "~/models/collection-file";
const memoizedMapStateToProps = () => {
let prevState: CollectionPanelFilesState;
diff --git a/src/views-components/context-menu/action-sets/collection-action-set.ts b/src/views-components/context-menu/action-sets/collection-action-set.ts
index 10da9ef..4561f9d 100644
--- a/src/views-components/context-menu/action-sets/collection-action-set.ts
+++ b/src/views-components/context-menu/action-sets/collection-action-set.ts
@@ -4,10 +4,10 @@
import { ContextMenuActionSet } from "../context-menu-action-set";
import { ToggleFavoriteAction } from "../actions/favorite-action";
-import { toggleFavorite } from "../../../store/favorites/favorites-actions";
-import { RenameIcon, ShareIcon, MoveToIcon, CopyIcon, DetailsIcon, ProvenanceGraphIcon, AdvancedIcon, RemoveIcon } from "../../../components/icon/icon";
-import { openUpdater } from "../../../store/collections/updater/collection-updater-action";
-import { favoritePanelActions } from "../../../store/favorite-panel/favorite-panel-action";
+import { toggleFavorite } from "~/store/favorites/favorites-actions";
+import { RenameIcon, ShareIcon, MoveToIcon, CopyIcon, DetailsIcon, ProvenanceGraphIcon, AdvancedIcon, RemoveIcon } from "~/components/icon/icon";
+import { openUpdater } from "~/store/collections/updater/collection-updater-action";
+import { favoritePanelActions } from "~/store/favorite-panel/favorite-panel-action";
export const collectionActionSet: ContextMenuActionSet = [[
{
diff --git a/src/views-components/context-menu/action-sets/collection-files-action-set.ts b/src/views-components/context-menu/action-sets/collection-files-action-set.ts
index 91fa2b0..0bed68e 100644
--- a/src/views-components/context-menu/action-sets/collection-files-action-set.ts
+++ b/src/views-components/context-menu/action-sets/collection-files-action-set.ts
@@ -3,9 +3,9 @@
// SPDX-License-Identifier: AGPL-3.0
import { ContextMenuActionSet } from "../context-menu-action-set";
-import { collectionPanelFilesAction } from "../../../store/collection-panel/collection-panel-files/collection-panel-files-actions";
-import { openMultipleFilesRemoveDialog } from "../../file-remove-dialog/multiple-files-remove-dialog";
-import { createCollectionWithSelected } from "../../create-collection-dialog-with-selected/create-collection-dialog-with-selected";
+import { collectionPanelFilesAction } from "~/store/collection-panel/collection-panel-files/collection-panel-files-actions";
+import { openMultipleFilesRemoveDialog } from "~/views-components/file-remove-dialog/multiple-files-remove-dialog";
+import { createCollectionWithSelected } from "~/views-components/create-collection-dialog-with-selected/create-collection-dialog-with-selected";
export const collectionFilesActionSet: ContextMenuActionSet = [[{
diff --git a/src/views-components/context-menu/action-sets/collection-files-item-action-set.ts b/src/views-components/context-menu/action-sets/collection-files-item-action-set.ts
index e24108f..8728ad3 100644
--- a/src/views-components/context-menu/action-sets/collection-files-item-action-set.ts
+++ b/src/views-components/context-menu/action-sets/collection-files-item-action-set.ts
@@ -3,7 +3,7 @@
// SPDX-License-Identifier: AGPL-3.0
import { ContextMenuActionSet } from "../context-menu-action-set";
-import { RenameIcon, DownloadIcon, RemoveIcon } from "../../../components/icon/icon";
+import { RenameIcon, DownloadIcon, RemoveIcon } from "~/components/icon/icon";
import { openRenameFileDialog } from "../../rename-file-dialog/rename-file-dialog";
import { openFileRemoveDialog } from "../../file-remove-dialog/file-remove-dialog";
diff --git a/src/views-components/context-menu/action-sets/collection-resource-action-set.ts b/src/views-components/context-menu/action-sets/collection-resource-action-set.ts
index e6356bb..7d8364b 100644
--- a/src/views-components/context-menu/action-sets/collection-resource-action-set.ts
+++ b/src/views-components/context-menu/action-sets/collection-resource-action-set.ts
@@ -4,10 +4,10 @@
import { ContextMenuActionSet } from "../context-menu-action-set";
import { ToggleFavoriteAction } from "../actions/favorite-action";
-import { toggleFavorite } from "../../../store/favorites/favorites-actions";
-import { RenameIcon, ShareIcon, MoveToIcon, CopyIcon, DetailsIcon, RemoveIcon } from "../../../components/icon/icon";
-import { openUpdater } from "../../../store/collections/updater/collection-updater-action";
-import { favoritePanelActions } from "../../../store/favorite-panel/favorite-panel-action";
+import { toggleFavorite } from "~/store/favorites/favorites-actions";
+import { RenameIcon, ShareIcon, MoveToIcon, CopyIcon, DetailsIcon, RemoveIcon } from "~/components/icon/icon";
+import { openUpdater } from "~/store/collections/updater/collection-updater-action";
+import { favoritePanelActions } from "~/store/favorite-panel/favorite-panel-action";
export const collectionResourceActionSet: ContextMenuActionSet = [[
{
diff --git a/src/views-components/context-menu/action-sets/favorite-action-set.ts b/src/views-components/context-menu/action-sets/favorite-action-set.ts
index 72c72fa..7942937 100644
--- a/src/views-components/context-menu/action-sets/favorite-action-set.ts
+++ b/src/views-components/context-menu/action-sets/favorite-action-set.ts
@@ -4,8 +4,8 @@
import { ContextMenuActionSet } from "../context-menu-action-set";
import { ToggleFavoriteAction } from "../actions/favorite-action";
-import { toggleFavorite } from "../../../store/favorites/favorites-actions";
-import { favoritePanelActions } from "../../../store/favorite-panel/favorite-panel-action";
+import { toggleFavorite } from "~/store/favorites/favorites-actions";
+import { favoritePanelActions } from "~/store/favorite-panel/favorite-panel-action";
export const favoriteActionSet: ContextMenuActionSet = [[{
component: ToggleFavoriteAction,
diff --git a/src/views-components/context-menu/action-sets/project-action-set.ts b/src/views-components/context-menu/action-sets/project-action-set.ts
index 4e7a600..8944685 100644
--- a/src/views-components/context-menu/action-sets/project-action-set.ts
+++ b/src/views-components/context-menu/action-sets/project-action-set.ts
@@ -5,11 +5,11 @@
import { reset } from "redux-form";
import { ContextMenuActionSet } from "../context-menu-action-set";
-import { projectActions } from "../../../store/project/project-action";
-import { NewProjectIcon } from "../../../components/icon/icon";
+import { projectActions } from "~/store/project/project-action";
+import { NewProjectIcon } from "~/components/icon/icon";
import { ToggleFavoriteAction } from "../actions/favorite-action";
-import { toggleFavorite } from "../../../store/favorites/favorites-actions";
-import { favoritePanelActions } from "../../../store/favorite-panel/favorite-panel-action";
+import { toggleFavorite } from "~/store/favorites/favorites-actions";
+import { favoritePanelActions } from "~/store/favorite-panel/favorite-panel-action";
import { PROJECT_CREATE_DIALOG } from "../../dialog-create/dialog-project-create";
export const projectActionSet: ContextMenuActionSet = [[{
diff --git a/src/views-components/context-menu/action-sets/resource-action-set.ts b/src/views-components/context-menu/action-sets/resource-action-set.ts
index 9585a86..f7d1c4e 100644
--- a/src/views-components/context-menu/action-sets/resource-action-set.ts
+++ b/src/views-components/context-menu/action-sets/resource-action-set.ts
@@ -4,7 +4,7 @@
import { ContextMenuActionSet } from "../context-menu-action-set";
import { ToggleFavoriteAction } from "../actions/favorite-action";
-import { toggleFavorite } from "../../../store/favorites/favorites-actions";
+import { toggleFavorite } from "~/store/favorites/favorites-actions";
export const resourceActionSet: ContextMenuActionSet = [[{
component: ToggleFavoriteAction,
diff --git a/src/views-components/context-menu/action-sets/root-project-action-set.ts b/src/views-components/context-menu/action-sets/root-project-action-set.ts
index 8c57f47..556ba5d 100644
--- a/src/views-components/context-menu/action-sets/root-project-action-set.ts
+++ b/src/views-components/context-menu/action-sets/root-project-action-set.ts
@@ -5,8 +5,8 @@
import { reset } from "redux-form";
import { ContextMenuActionSet } from "../context-menu-action-set";
-import { projectActions } from "../../../store/project/project-action";
-import { NewProjectIcon } from "../../../components/icon/icon";
+import { projectActions } from "~/store/project/project-action";
+import { NewProjectIcon } from "~/components/icon/icon";
import { PROJECT_CREATE_DIALOG } from "../../dialog-create/dialog-project-create";
export const rootProjectActionSet: ContextMenuActionSet = [[{
diff --git a/src/views-components/context-menu/actions/favorite-action.tsx b/src/views-components/context-menu/actions/favorite-action.tsx
index 55fe8cf..21f037d 100644
--- a/src/views-components/context-menu/actions/favorite-action.tsx
+++ b/src/views-components/context-menu/actions/favorite-action.tsx
@@ -4,9 +4,9 @@
import * as React from "react";
import { ListItemIcon, ListItemText } from "@material-ui/core";
-import { AddFavoriteIcon, RemoveFavoriteIcon } from "../../../components/icon/icon";
+import { AddFavoriteIcon, RemoveFavoriteIcon } from "~/components/icon/icon";
import { connect } from "react-redux";
-import { RootState } from "../../../store/store";
+import { RootState } from "~/store/store";
const mapStateToProps = (state: RootState) => ({
isFavorite: state.contextMenu.resource !== undefined && state.favorites[state.contextMenu.resource.uuid] === true
diff --git a/src/views-components/context-menu/context-menu-action-set.ts b/src/views-components/context-menu/context-menu-action-set.ts
index 089580c..cbcc0b7 100644
--- a/src/views-components/context-menu/context-menu-action-set.ts
+++ b/src/views-components/context-menu/context-menu-action-set.ts
@@ -3,8 +3,8 @@
// SPDX-License-Identifier: AGPL-3.0
import { Dispatch } from "redux";
-import { ContextMenuItem } from "../../components/context-menu/context-menu";
-import { ContextMenuResource } from "../../store/context-menu/context-menu-reducer";
+import { ContextMenuItem } from "~/components/context-menu/context-menu";
+import { ContextMenuResource } from "~/store/context-menu/context-menu-reducer";
export interface ContextMenuAction extends ContextMenuItem {
execute(dispatch: Dispatch, resource: ContextMenuResource): void;
diff --git a/src/views-components/context-menu/context-menu.tsx b/src/views-components/context-menu/context-menu.tsx
index 0a629b2..8036bb5 100644
--- a/src/views-components/context-menu/context-menu.tsx
+++ b/src/views-components/context-menu/context-menu.tsx
@@ -3,11 +3,11 @@
// SPDX-License-Identifier: AGPL-3.0
import { connect } from "react-redux";
-import { RootState } from "../../store/store";
-import { contextMenuActions } from "../../store/context-menu/context-menu-actions";
-import { ContextMenu as ContextMenuComponent, ContextMenuProps, ContextMenuItem } from "../../components/context-menu/context-menu";
-import { createAnchorAt } from "../../components/popover/helpers";
-import { ContextMenuResource } from "../../store/context-menu/context-menu-reducer";
+import { RootState } from "~/store/store";
+import { contextMenuActions } from "~/store/context-menu/context-menu-actions";
+import { ContextMenu as ContextMenuComponent, ContextMenuProps, ContextMenuItem } from "~/components/context-menu/context-menu";
+import { createAnchorAt } from "~/components/popover/helpers";
+import { ContextMenuResource } from "~/store/context-menu/context-menu-reducer";
import { ContextMenuActionSet, ContextMenuAction } from "./context-menu-action-set";
import { Dispatch } from "redux";
diff --git a/src/views-components/create-collection-dialog-with-selected/create-collection-dialog-with-selected.tsx b/src/views-components/create-collection-dialog-with-selected/create-collection-dialog-with-selected.tsx
index 8a2efca..46bc724 100644
--- a/src/views-components/create-collection-dialog-with-selected/create-collection-dialog-with-selected.tsx
+++ b/src/views-components/create-collection-dialog-with-selected/create-collection-dialog-with-selected.tsx
@@ -4,8 +4,8 @@
import { Dispatch } from "redux";
import { reduxForm, reset, startSubmit, stopSubmit } from "redux-form";
-import { withDialog } from "../../store/dialog/with-dialog";
-import { dialogActions } from "../../store/dialog/dialog-actions";
+import { withDialog } from "~/store/dialog/with-dialog";
+import { dialogActions } from "~/store/dialog/dialog-actions";
import { DialogCollectionCreateWithSelected } from "../dialog-create/dialog-collection-create-selected";
import { loadProjectTreePickerProjects } from "../project-tree-picker/project-tree-picker";
diff --git a/src/views-components/create-collection-dialog/create-collection-dialog.tsx b/src/views-components/create-collection-dialog/create-collection-dialog.tsx
index 9bb469a..94eb82f 100644
--- a/src/views-components/create-collection-dialog/create-collection-dialog.tsx
+++ b/src/views-components/create-collection-dialog/create-collection-dialog.tsx
@@ -6,12 +6,12 @@ import { connect } from "react-redux";
import { Dispatch } from "redux";
import { SubmissionError } from "redux-form";
-import { RootState } from "../../store/store";
+import { RootState } from "~/store/store";
import { DialogCollectionCreate } from "../dialog-create/dialog-collection-create";
-import { collectionCreateActions, createCollection } from "../../store/collections/creator/collection-creator-action";
-import { snackbarActions } from "../../store/snackbar/snackbar-actions";
-import { UploadFile } from "../../store/collections/uploader/collection-uploader-actions";
-import { projectPanelActions } from "../../store/project-panel/project-panel-action";
+import { collectionCreateActions, createCollection } from "~/store/collections/creator/collection-creator-action";
+import { snackbarActions } from "~/store/snackbar/snackbar-actions";
+import { UploadFile } from "~/store/collections/uploader/collection-uploader-actions";
+import { projectPanelActions } from "~/store/project-panel/project-panel-action";
const mapStateToProps = (state: RootState) => ({
open: state.collections.creator.opened
diff --git a/src/views-components/create-project-dialog/create-project-dialog.tsx b/src/views-components/create-project-dialog/create-project-dialog.tsx
index aa0dc7b..43f56ed 100644
--- a/src/views-components/create-project-dialog/create-project-dialog.tsx
+++ b/src/views-components/create-project-dialog/create-project-dialog.tsx
@@ -6,11 +6,11 @@ import { connect } from "react-redux";
import { Dispatch } from "redux";
import { SubmissionError } from "redux-form";
-import { RootState } from "../../store/store";
+import { RootState } from "~/store/store";
import { DialogProjectCreate } from "../dialog-create/dialog-project-create";
-import { projectActions, createProject, getProjectList } from "../../store/project/project-action";
-import { projectPanelActions } from "../../store/project-panel/project-panel-action";
-import { snackbarActions } from "../../store/snackbar/snackbar-actions";
+import { projectActions, createProject, getProjectList } from "~/store/project/project-action";
+import { projectPanelActions } from "~/store/project-panel/project-panel-action";
+import { snackbarActions } from "~/store/snackbar/snackbar-actions";
const mapStateToProps = (state: RootState) => ({
open: state.projects.creator.opened
diff --git a/src/views-components/current-token-dialog/current-token-dialog.tsx b/src/views-components/current-token-dialog/current-token-dialog.tsx
index fe5f850..fca9f05 100644
--- a/src/views-components/current-token-dialog/current-token-dialog.tsx
+++ b/src/views-components/current-token-dialog/current-token-dialog.tsx
@@ -4,7 +4,7 @@
import * as React from 'react';
import { Dialog, DialogActions, DialogTitle, DialogContent, WithStyles, withStyles, StyleRulesCallback, Button, Typography, Paper } from '@material-ui/core';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
type CssRules = 'link' | 'paper' | 'button';
@@ -27,7 +27,7 @@ const styles: StyleRulesCallback<CssRules> = (theme: ArvadosTheme) => ({
});
interface CurrentTokenDataProps {
- currentToken?: string;
+ currentToken?: string;
open: boolean;
}
@@ -37,9 +37,9 @@ interface CurrentTokenActionProps {
type CurrentTokenProps = CurrentTokenDataProps & CurrentTokenActionProps & WithStyles<CssRules>;
-export const CurrentTokenDialog = withStyles(styles)(
+export const CurrentTokenDialog = withStyles(styles)(
class extends React.Component<CurrentTokenProps> {
-
+
render() {
const { classes, open, handleClose, currentToken } = this.props;
return (
@@ -47,7 +47,7 @@ export const CurrentTokenDialog = withStyles(styles)(
<DialogTitle>Current Token</DialogTitle>
<DialogContent>
<Typography variant='body1' paragraph={true}>
- The Arvados API token is a secret key that enables the Arvados SDKs to access Arvados with the proper permissions.
+ The Arvados API token is a secret key that enables the Arvados SDKs to access Arvados with the proper permissions.
<Typography component='p'>
For more information see
<a href='http://doc.arvados.org/user/reference/api-tokens.html' target='blank' className={classes.link}>
@@ -56,13 +56,13 @@ export const CurrentTokenDialog = withStyles(styles)(
</Typography>
</Typography>
- <Typography variant='body1' paragraph={true}>
+ <Typography variant='body1' paragraph={true}>
Paste the following lines at a shell prompt to set up the necessary environment for Arvados SDKs to authenticate to your klingenc account.
</Typography>
<Paper className={classes.paper} elevation={0}>
<Typography variant='body1'>
- HISTIGNORE=$HISTIGNORE:'export ARVADOS_API_TOKEN=*'
+ HISTIGNORE=$HISTIGNORE:'export ARVADOS_API_TOKEN=*'
</Typography>
<Typography variant='body1'>
export ARVADOS_API_TOKEN={currentToken}
@@ -75,8 +75,8 @@ export const CurrentTokenDialog = withStyles(styles)(
</Typography>
</Paper>
<Typography variant='body1'>
- Arvados
- <a href='http://doc.arvados.org/user/reference/api-tokens.html' target='blank' className={classes.link}>virtual machines</a>
+ Arvados
+ <a href='http://doc.arvados.org/user/reference/api-tokens.html' target='blank' className={classes.link}>virtual machines</a>
do this for you automatically. This setup is needed only when you use the API remotely (e.g., from your own workstation).
</Typography>
</DialogContent>
@@ -87,4 +87,4 @@ export const CurrentTokenDialog = withStyles(styles)(
);
}
}
-);
\ No newline at end of file
+);
diff --git a/src/views-components/data-explorer/data-explorer.tsx b/src/views-components/data-explorer/data-explorer.tsx
index e13e8af..68eeb3c 100644
--- a/src/views-components/data-explorer/data-explorer.tsx
+++ b/src/views-components/data-explorer/data-explorer.tsx
@@ -3,14 +3,14 @@
// SPDX-License-Identifier: AGPL-3.0
import { connect } from "react-redux";
-import { RootState } from "../../store/store";
-import { DataExplorer as DataExplorerComponent } from "../../components/data-explorer/data-explorer";
-import { getDataExplorer } from "../../store/data-explorer/data-explorer-reducer";
+import { RootState } from "~/store/store";
+import { DataExplorer as DataExplorerComponent } from "~/components/data-explorer/data-explorer";
+import { getDataExplorer } from "~/store/data-explorer/data-explorer-reducer";
import { Dispatch } from "redux";
-import { dataExplorerActions } from "../../store/data-explorer/data-explorer-action";
-import { DataColumn } from "../../components/data-table/data-column";
-import { DataTableFilterItem } from "../../components/data-table-filters/data-table-filters";
-import { DataColumns } from "../../components/data-table/data-table";
+import { dataExplorerActions } from "~/store/data-explorer/data-explorer-action";
+import { DataColumn } from "~/components/data-table/data-column";
+import { DataTableFilterItem } from "~/components/data-table-filters/data-table-filters";
+import { DataColumns } from "~/components/data-table/data-table";
interface Props {
id: string;
diff --git a/src/views-components/data-explorer/renderers.tsx b/src/views-components/data-explorer/renderers.tsx
index 2b99f02..1b07642 100644
--- a/src/views-components/data-explorer/renderers.tsx
+++ b/src/views-components/data-explorer/renderers.tsx
@@ -5,10 +5,10 @@
import * as React from 'react';
import { Grid, Typography } from '@material-ui/core';
import { FavoriteStar } from '../favorite-star/favorite-star';
-import { ResourceKind } from '../../models/resource';
-import { ProjectIcon, CollectionIcon, ProcessIcon, DefaultIcon } from '../../components/icon/icon';
-import { formatDate, formatFileSize } from '../../common/formatters';
-import { resourceLabel } from '../../common/labels';
+import { ResourceKind } from '~/models/resource';
+import { ProjectIcon, CollectionIcon, ProcessIcon, DefaultIcon } from '~/components/icon/icon';
+import { formatDate, formatFileSize } from '~/common/formatters';
+import { resourceLabel } from '~/common/labels';
export const renderName = (item: {name: string; uuid: string, kind: string}) =>
@@ -64,4 +64,4 @@ export const renderType = (type: string) =>
export const renderStatus = (item: {status?: string}) =>
<Typography noWrap align="center" >
{item.status || "-"}
- </Typography>;
\ No newline at end of file
+ </Typography>;
diff --git a/src/views-components/details-panel/collection-details.tsx b/src/views-components/details-panel/collection-details.tsx
index f0be449..c41e0b8 100644
--- a/src/views-components/details-panel/collection-details.tsx
+++ b/src/views-components/details-panel/collection-details.tsx
@@ -3,13 +3,13 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from 'react';
-import { CollectionIcon } from '../../components/icon/icon';
-import { CollectionResource } from '../../models/collection';
-import { formatDate } from '../../common/formatters';
-import { resourceLabel } from '../../common/labels';
-import { ResourceKind } from '../../models/resource';
+import { CollectionIcon } from '~/components/icon/icon';
+import { CollectionResource } from '~/models/collection';
+import { formatDate } from '~/common/formatters';
+import { resourceLabel } from '~/common/labels';
+import { ResourceKind } from '~/models/resource';
import { DetailsData } from "./details-data";
-import { DetailsAttribute } from "../../components/details-attribute/details-attribute";
+import { DetailsAttribute } from "~/components/details-attribute/details-attribute";
export class CollectionDetails extends DetailsData<CollectionResource> {
diff --git a/src/views-components/details-panel/details-data.tsx b/src/views-components/details-panel/details-data.tsx
index d20269c..5c06188 100644
--- a/src/views-components/details-panel/details-data.tsx
+++ b/src/views-components/details-panel/details-data.tsx
@@ -3,7 +3,7 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from 'react';
-import { DetailsResource } from "../../models/details";
+import { DetailsResource } from "~/models/details";
export abstract class DetailsData<T extends DetailsResource = DetailsResource> {
constructor(protected item: T) {}
diff --git a/src/views-components/details-panel/details-panel.tsx b/src/views-components/details-panel/details-panel.tsx
index 20d3843..a298d67 100644
--- a/src/views-components/details-panel/details-panel.tsx
+++ b/src/views-components/details-panel/details-panel.tsx
@@ -5,21 +5,21 @@
import * as React from 'react';
import { Drawer, IconButton, Tabs, Tab, Typography, Grid } from '@material-ui/core';
import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core/styles';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import * as classnames from "classnames";
import { connect } from 'react-redux';
-import { RootState } from '../../store/store';
-import { detailsPanelActions } from "../../store/details-panel/details-panel-action";
-import { CloseIcon } from '../../components/icon/icon';
-import { EmptyResource } from '../../models/empty';
+import { RootState } from '~/store/store';
+import { detailsPanelActions } from "~/store/details-panel/details-panel-action";
+import { CloseIcon } from '~/components/icon/icon';
+import { EmptyResource } from '~/models/empty';
import { Dispatch } from "redux";
-import { ResourceKind } from "../../models/resource";
+import { ResourceKind } from "~/models/resource";
import { ProjectDetails } from "./project-details";
import { CollectionDetails } from "./collection-details";
import { ProcessDetails } from "./process-details";
import { EmptyDetails } from "./empty-details";
import { DetailsData } from "./details-data";
-import { DetailsResource } from "../../models/details";
+import { DetailsResource } from "~/models/details";
type CssRules = 'drawerPaper' | 'container' | 'opened' | 'headerContainer' | 'headerIcon' | 'tabContainer';
diff --git a/src/views-components/details-panel/empty-details.tsx b/src/views-components/details-panel/empty-details.tsx
index 51112ce..ccaa561 100644
--- a/src/views-components/details-panel/empty-details.tsx
+++ b/src/views-components/details-panel/empty-details.tsx
@@ -3,12 +3,12 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from 'react';
-import { DefaultIcon, IconType, ProjectsIcon } from '../../components/icon/icon';
-import { EmptyResource } from '../../models/empty';
+import { DefaultIcon, IconType, ProjectsIcon } from '~/components/icon/icon';
+import { EmptyResource } from '~/models/empty';
import { DetailsData } from "./details-data";
import Typography from "@material-ui/core/Typography";
import { StyleRulesCallback, WithStyles, withStyles } from "@material-ui/core/styles";
-import { ArvadosTheme } from "../../common/custom-theme";
+import { ArvadosTheme } from "~/common/custom-theme";
import Icon from "@material-ui/core/Icon/Icon";
type CssRules = 'container' | 'icon';
diff --git a/src/views-components/details-panel/process-details.tsx b/src/views-components/details-panel/process-details.tsx
index e195d05..dee6e8b 100644
--- a/src/views-components/details-panel/process-details.tsx
+++ b/src/views-components/details-panel/process-details.tsx
@@ -3,13 +3,13 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from 'react';
-import { ProcessIcon } from '../../components/icon/icon';
-import { ProcessResource } from '../../models/process';
-import { formatDate } from '../../common/formatters';
-import { ResourceKind } from '../../models/resource';
-import { resourceLabel } from '../../common/labels';
+import { ProcessIcon } from '~/components/icon/icon';
+import { ProcessResource } from '~/models/process';
+import { formatDate } from '~/common/formatters';
+import { ResourceKind } from '~/models/resource';
+import { resourceLabel } from '~/common/labels';
import { DetailsData } from "./details-data";
-import { DetailsAttribute } from "../../components/details-attribute/details-attribute";
+import { DetailsAttribute } from "~/components/details-attribute/details-attribute";
export class ProcessDetails extends DetailsData<ProcessResource> {
diff --git a/src/views-components/details-panel/project-details.tsx b/src/views-components/details-panel/project-details.tsx
index b46bdcd..154f0a2 100644
--- a/src/views-components/details-panel/project-details.tsx
+++ b/src/views-components/details-panel/project-details.tsx
@@ -3,13 +3,13 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from 'react';
-import { ProjectIcon } from '../../components/icon/icon';
-import { ProjectResource } from '../../models/project';
-import { formatDate } from '../../common/formatters';
-import { ResourceKind } from '../../models/resource';
-import { resourceLabel } from '../../common/labels';
+import { ProjectIcon } from '~/components/icon/icon';
+import { ProjectResource } from '~/models/project';
+import { formatDate } from '~/common/formatters';
+import { ResourceKind } from '~/models/resource';
+import { resourceLabel } from '~/common/labels';
import { DetailsData } from "./details-data";
-import { DetailsAttribute } from "../../components/details-attribute/details-attribute";
+import { DetailsAttribute } from "~/components/details-attribute/details-attribute";
export class ProjectDetails extends DetailsData<ProjectResource> {
diff --git a/src/views-components/dialog-create/dialog-collection-create-selected.tsx b/src/views-components/dialog-create/dialog-collection-create-selected.tsx
index 5069db9..0dc590a 100644
--- a/src/views-components/dialog-create/dialog-collection-create-selected.tsx
+++ b/src/views-components/dialog-create/dialog-collection-create-selected.tsx
@@ -4,10 +4,10 @@
import * as React from "react";
import { InjectedFormProps, Field, WrappedFieldProps } from "redux-form";
-import { Dialog, DialogTitle, DialogContent, DialogActions, Button, CircularProgress, FormHelperText } from "@material-ui/core";
-import { WithDialogProps } from "../../store/dialog/with-dialog";
-import { TextField } from "../../components/text-field/text-field";
-import { COLLECTION_NAME_VALIDATION, COLLECTION_DESCRIPTION_VALIDATION, COLLECTION_PROJECT_VALIDATION } from "../../validators/create-project/create-project-validator";
+import { Dialog, DialogTitle, DialogContent, DialogActions, Button, CircularProgress } from "@material-ui/core";
+import { WithDialogProps } from "~/store/dialog/with-dialog";
+import { TextField } from "~/components/text-field/text-field";
+import { COLLECTION_NAME_VALIDATION, COLLECTION_DESCRIPTION_VALIDATION, COLLECTION_PROJECT_VALIDATION } from "~/validators/create-project/create-project-validator";
import { ProjectTreePicker } from "../project-tree-picker/project-tree-picker";
export const DialogCollectionCreateWithSelected = (props: WithDialogProps<string> & InjectedFormProps<{ name: string }>) =>
diff --git a/src/views-components/dialog-create/dialog-collection-create.tsx b/src/views-components/dialog-create/dialog-collection-create.tsx
index 226b646..7f2e411 100644
--- a/src/views-components/dialog-create/dialog-collection-create.tsx
+++ b/src/views-components/dialog-create/dialog-collection-create.tsx
@@ -5,15 +5,15 @@
import * as React from 'react';
import { reduxForm, Field } from 'redux-form';
import { compose } from 'redux';
-import { TextField } from '../../components/text-field/text-field';
+import { TextField } from '~/components/text-field/text-field';
import { Dialog, DialogActions, DialogContent, DialogTitle } from '@material-ui/core/';
import { Button, StyleRulesCallback, WithStyles, withStyles, CircularProgress } from '@material-ui/core';
-import { COLLECTION_NAME_VALIDATION, COLLECTION_DESCRIPTION_VALIDATION } from '../../validators/create-collection/create-collection-validator';
-import { FileUpload } from "../../components/file-upload/file-upload";
+import { COLLECTION_NAME_VALIDATION, COLLECTION_DESCRIPTION_VALIDATION } from '~/validators/create-collection/create-collection-validator';
+import { FileUpload } from "~/components/file-upload/file-upload";
import { connect, DispatchProp } from "react-redux";
-import { RootState } from "../../store/store";
-import { collectionUploaderActions, UploadFile } from "../../store/collections/uploader/collection-uploader-actions";
+import { RootState } from "~/store/store";
+import { collectionUploaderActions, UploadFile } from "~/store/collections/uploader/collection-uploader-actions";
type CssRules = "button" | "lastButton" | "formContainer" | "textField" | "createProgress" | "dialogActions";
diff --git a/src/views-components/dialog-create/dialog-project-create.tsx b/src/views-components/dialog-create/dialog-project-create.tsx
index 50e4c98..c3d8415 100644
--- a/src/views-components/dialog-create/dialog-project-create.tsx
+++ b/src/views-components/dialog-create/dialog-project-create.tsx
@@ -5,11 +5,11 @@
import * as React from 'react';
import { reduxForm, Field } from 'redux-form';
import { compose } from 'redux';
-import { TextField } from '../../components/text-field/text-field';
+import { TextField } from '~/components/text-field/text-field';
import { Dialog, DialogActions, DialogContent, DialogTitle } from '@material-ui/core/';
import { Button, StyleRulesCallback, WithStyles, withStyles, CircularProgress } from '@material-ui/core';
-import { PROJECT_NAME_VALIDATION, PROJECT_DESCRIPTION_VALIDATION } from '../../validators/create-project/create-project-validator';
+import { PROJECT_NAME_VALIDATION, PROJECT_DESCRIPTION_VALIDATION } from '~/validators/create-project/create-project-validator';
type CssRules = "button" | "lastButton" | "formContainer" | "textField" | "dialog" | "dialogTitle" | "createProgress" | "dialogActions";
diff --git a/src/views-components/dialog-update/dialog-collection-update.tsx b/src/views-components/dialog-update/dialog-collection-update.tsx
index f3f79fb..d97ff41 100644
--- a/src/views-components/dialog-update/dialog-collection-update.tsx
+++ b/src/views-components/dialog-update/dialog-collection-update.tsx
@@ -5,10 +5,10 @@
import * as React from 'react';
import { reduxForm, Field } from 'redux-form';
import { compose } from 'redux';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import { Dialog, DialogActions, DialogContent, DialogTitle, TextField, StyleRulesCallback, withStyles, WithStyles, Button, CircularProgress } from '@material-ui/core';
-import { COLLECTION_NAME_VALIDATION, COLLECTION_DESCRIPTION_VALIDATION } from '../../validators/create-collection/create-collection-validator';
-import { COLLECTION_FORM_NAME } from '../../store/collections/updater/collection-updater-action';
+import { COLLECTION_NAME_VALIDATION, COLLECTION_DESCRIPTION_VALIDATION } from '~/validators/create-collection/create-collection-validator';
+import { COLLECTION_FORM_NAME } from '~/store/collections/updater/collection-updater-action';
type CssRules = 'content' | 'actions' | 'textField' | 'buttonWrapper' | 'saveButton' | 'circularProgress';
diff --git a/src/views-components/favorite-star/favorite-star.tsx b/src/views-components/favorite-star/favorite-star.tsx
index f896e30..755cc67 100644
--- a/src/views-components/favorite-star/favorite-star.tsx
+++ b/src/views-components/favorite-star/favorite-star.tsx
@@ -3,9 +3,9 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from "react";
-import { FavoriteIcon } from "../../components/icon/icon";
+import { FavoriteIcon } from "~/components/icon/icon";
import { connect } from "react-redux";
-import { RootState } from "../../store/store";
+import { RootState } from "~/store/store";
import { withStyles, StyleRulesCallback, WithStyles } from "@material-ui/core";
type CssRules = "icon";
@@ -24,4 +24,4 @@ const mapStateToProps = (state: RootState, props: { resourceUuid: string; classN
export const FavoriteStar = connect(mapStateToProps)(
withStyles(styles)((props: { visible: boolean; className?: string; } & WithStyles<CssRules>) =>
props.visible ? <FavoriteIcon className={props.className || props.classes.icon} /> : null
- ));
\ No newline at end of file
+ ));
diff --git a/src/views-components/file-remove-dialog/file-remove-dialog.ts b/src/views-components/file-remove-dialog/file-remove-dialog.ts
index 3678e53..0449793 100644
--- a/src/views-components/file-remove-dialog/file-remove-dialog.ts
+++ b/src/views-components/file-remove-dialog/file-remove-dialog.ts
@@ -4,10 +4,10 @@
import { Dispatch } from "redux";
import { connect } from "react-redux";
-import { ConfirmationDialog } from "../../components/confirmation-dialog/confirmation-dialog";
-import { withDialog } from "../../store/dialog/with-dialog";
-import { dialogActions } from "../../store/dialog/dialog-actions";
-import { snackbarActions } from "../../store/snackbar/snackbar-actions";
+import { ConfirmationDialog } from "~/components/confirmation-dialog/confirmation-dialog";
+import { withDialog } from "~/store/dialog/with-dialog";
+import { dialogActions } from "~/store/dialog/dialog-actions";
+import { snackbarActions } from "~/store/snackbar/snackbar-actions";
const FILE_REMOVE_DIALOG = 'fileRemoveDialog';
@@ -35,4 +35,4 @@ export const openFileRemoveDialog = (fileId: string) =>
export const [FileRemoveDialog] = [ConfirmationDialog]
.map(withDialog(FILE_REMOVE_DIALOG))
- .map(connect(undefined, mapDispatchToProps));
\ No newline at end of file
+ .map(connect(undefined, mapDispatchToProps));
diff --git a/src/views-components/file-remove-dialog/multiple-files-remove-dialog.ts b/src/views-components/file-remove-dialog/multiple-files-remove-dialog.ts
index 8810e23..1362de6 100644
--- a/src/views-components/file-remove-dialog/multiple-files-remove-dialog.ts
+++ b/src/views-components/file-remove-dialog/multiple-files-remove-dialog.ts
@@ -4,10 +4,10 @@
import { Dispatch } from "redux";
import { connect } from "react-redux";
-import { ConfirmationDialog } from "../../components/confirmation-dialog/confirmation-dialog";
-import { withDialog } from "../../store/dialog/with-dialog";
-import { dialogActions } from "../../store/dialog/dialog-actions";
-import { snackbarActions } from "../../store/snackbar/snackbar-actions";
+import { ConfirmationDialog } from "~/components/confirmation-dialog/confirmation-dialog";
+import { withDialog } from "~/store/dialog/with-dialog";
+import { dialogActions } from "~/store/dialog/dialog-actions";
+import { snackbarActions } from "~/store/snackbar/snackbar-actions";
const MULTIPLE_FILES_REMOVE_DIALOG = 'multipleFilesRemoveDialog';
@@ -34,4 +34,4 @@ export const openMultipleFilesRemoveDialog = () =>
export const [MultipleFilesRemoveDialog] = [ConfirmationDialog]
.map(withDialog(MULTIPLE_FILES_REMOVE_DIALOG))
- .map(connect(undefined, mapDispatchToProps));
\ No newline at end of file
+ .map(connect(undefined, mapDispatchToProps));
diff --git a/src/views-components/main-app-bar/main-app-bar.test.tsx b/src/views-components/main-app-bar/main-app-bar.test.tsx
index a634d43..75a39fd 100644
--- a/src/views-components/main-app-bar/main-app-bar.test.tsx
+++ b/src/views-components/main-app-bar/main-app-bar.test.tsx
@@ -3,14 +3,14 @@
// SPDX-License-Identifier: AGPL-3.0
import * as React from "react";
-import { mount, configure, ReactWrapper } from "enzyme";
+import { mount, configure } from "enzyme";
import * as Adapter from "enzyme-adapter-react-16";
import { MainAppBar } from "./main-app-bar";
-import { SearchBar } from "../../components/search-bar/search-bar";
-import { Breadcrumbs } from "../../components/breadcrumbs/breadcrumbs";
-import { DropdownMenu } from "../../components/dropdown-menu/dropdown-menu";
+import { SearchBar } from "~/components/search-bar/search-bar";
+import { Breadcrumbs } from "~/components/breadcrumbs/breadcrumbs";
+import { DropdownMenu } from "~/components/dropdown-menu/dropdown-menu";
import { Button, MenuItem, IconButton } from "@material-ui/core";
-import { User } from "../../models/user";
+import { User } from "~/models/user";
configure({ adapter: new Adapter() });
diff --git a/src/views-components/main-app-bar/main-app-bar.tsx b/src/views-components/main-app-bar/main-app-bar.tsx
index 9c03108..8bce325 100644
--- a/src/views-components/main-app-bar/main-app-bar.tsx
+++ b/src/views-components/main-app-bar/main-app-bar.tsx
@@ -4,11 +4,11 @@
import * as React from "react";
import { AppBar, Toolbar, Typography, Grid, IconButton, Badge, Button, MenuItem } from "@material-ui/core";
-import { User, getUserFullname } from "../../models/user";
-import { SearchBar } from "../../components/search-bar/search-bar";
-import { Breadcrumbs, Breadcrumb } from "../../components/breadcrumbs/breadcrumbs";
-import { DropdownMenu } from "../../components/dropdown-menu/dropdown-menu";
-import { DetailsIcon, NotificationIcon, UserPanelIcon, HelpIcon } from "../../components/icon/icon";
+import { User, getUserFullname } from "~/models/user";
+import { SearchBar } from "~/components/search-bar/search-bar";
+import { Breadcrumbs, Breadcrumb } from "~/components/breadcrumbs/breadcrumbs";
+import { DropdownMenu } from "~/components/dropdown-menu/dropdown-menu";
+import { DetailsIcon, NotificationIcon, UserPanelIcon, HelpIcon } from "~/components/icon/icon";
export interface MainAppBarMenuItem {
label: string;
diff --git a/src/views-components/project-tree-picker/project-tree-picker.tsx b/src/views-components/project-tree-picker/project-tree-picker.tsx
index 1c343a2..e09d78a 100644
--- a/src/views-components/project-tree-picker/project-tree-picker.tsx
+++ b/src/views-components/project-tree-picker/project-tree-picker.tsx
@@ -7,15 +7,15 @@ import { Dispatch } from "redux";
import { connect } from "react-redux";
import { Typography } from "@material-ui/core";
import { TreePicker } from "../tree-picker/tree-picker";
-import { TreeProps, TreeItem, TreeItemStatus } from "../../components/tree/tree";
-import { ProjectResource } from "../../models/project";
-import { treePickerActions } from "../../store/tree-picker/tree-picker-actions";
-import { ListItemTextIcon } from "../../components/list-item-text-icon/list-item-text-icon";
-import { ProjectIcon } from "../../components/icon/icon";
-import { createTreePickerNode } from "../../store/tree-picker/tree-picker";
-import { RootState } from "../../store/store";
-import { ServiceRepository } from "../../services/services";
-import { FilterBuilder } from "../../common/api/filter-builder";
+import { TreeProps, TreeItem, TreeItemStatus } from "~/components/tree/tree";
+import { ProjectResource } from "~/models/project";
+import { treePickerActions } from "~/store/tree-picker/tree-picker-actions";
+import { ListItemTextIcon } from "~/components/list-item-text-icon/list-item-text-icon";
+import { ProjectIcon } from "~/components/icon/icon";
+import { createTreePickerNode } from "~/store/tree-picker/tree-picker";
+import { RootState } from "~/store/store";
+import { ServiceRepository } from "~/services/services";
+import { FilterBuilder } from "~/common/api/filter-builder";
type ProjectTreePickerProps = Pick<TreeProps<ProjectResource>, 'toggleItemActive' | 'toggleItemOpen'>;
@@ -72,4 +72,4 @@ const receiveProjectTreePickerData = (id: string, projects: ProjectResource[]) =
nodes: projects.map(project => createTreePickerNode({ id: project.uuid, value: project }))
}));
dispatch(treePickerActions.TOGGLE_TREE_PICKER_NODE_COLLAPSE({ id }));
- };
\ No newline at end of file
+ };
diff --git a/src/views-components/project-tree/project-tree.test.tsx b/src/views-components/project-tree/project-tree.test.tsx
index 98b4a67..140119e 100644
--- a/src/views-components/project-tree/project-tree.test.tsx
+++ b/src/views-components/project-tree/project-tree.test.tsx
@@ -11,9 +11,9 @@ import { Collapse } from '@material-ui/core';
import CircularProgress from '@material-ui/core/CircularProgress';
import { ProjectTree } from './project-tree';
-import { TreeItem } from '../../components/tree/tree';
-import { ProjectResource } from '../../models/project';
-import { mockProjectResource } from '../../models/test-utils';
+import { TreeItem } from '~/components/tree/tree';
+import { ProjectResource } from '~/models/project';
+import { mockProjectResource } from '~/models/test-utils';
Enzyme.configure({ adapter: new Adapter() });
diff --git a/src/views-components/project-tree/project-tree.tsx b/src/views-components/project-tree/project-tree.tsx
index c9d4c3e..8c1ed33 100644
--- a/src/views-components/project-tree/project-tree.tsx
+++ b/src/views-components/project-tree/project-tree.tsx
@@ -4,12 +4,12 @@
import * as React from 'react';
import { ReactElement } from 'react';
-import { StyleRulesCallback, Theme, WithStyles, withStyles } from '@material-ui/core/styles';
-import { Tree, TreeItem, TreeItemStatus } from '../../components/tree/tree';
-import { ProjectResource } from '../../models/project';
-import { ProjectIcon } from '../../components/icon/icon';
-import { ArvadosTheme } from '../../common/custom-theme';
-import { ListItemTextIcon } from '../../components/list-item-text-icon/list-item-text-icon';
+import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core/styles';
+import { Tree, TreeItem, TreeItemStatus } from '~/components/tree/tree';
+import { ProjectResource } from '~/models/project';
+import { ProjectIcon } from '~/components/icon/icon';
+import { ArvadosTheme } from '~/common/custom-theme';
+import { ListItemTextIcon } from '~/components/list-item-text-icon/list-item-text-icon';
type CssRules = 'root';
diff --git a/src/views-components/remove-dialog/remove-dialog.tsx b/src/views-components/remove-dialog/remove-dialog.tsx
index f08727f..1bf76e4 100644
--- a/src/views-components/remove-dialog/remove-dialog.tsx
+++ b/src/views-components/remove-dialog/remove-dialog.tsx
@@ -4,8 +4,8 @@
import * as React from "react";
import { Dialog, DialogTitle, DialogContent, DialogActions, Button } from "@material-ui/core";
-import { withDialog } from "../../store/dialog/with-dialog";
-import { dialogActions } from "../../store/dialog/dialog-actions";
+import { withDialog } from "~/store/dialog/with-dialog";
+import { dialogActions } from "~/store/dialog/dialog-actions";
export const REMOVE_DIALOG = 'removeCollectionFilesDialog';
diff --git a/src/views-components/rename-file-dialog/rename-file-dialog.tsx b/src/views-components/rename-file-dialog/rename-file-dialog.tsx
index 5e2f7c4..37028f9 100644
--- a/src/views-components/rename-file-dialog/rename-file-dialog.tsx
+++ b/src/views-components/rename-file-dialog/rename-file-dialog.tsx
@@ -4,9 +4,9 @@
import { Dispatch } from "redux";
import { reduxForm, reset, startSubmit, stopSubmit } from "redux-form";
-import { withDialog } from "../../store/dialog/with-dialog";
-import { dialogActions } from "../../store/dialog/dialog-actions";
-import { RenameDialog } from "../../components/rename-dialog/rename-dialog";
+import { withDialog } from "~/store/dialog/with-dialog";
+import { dialogActions } from "~/store/dialog/dialog-actions";
+import { RenameDialog } from "~/components/rename-dialog/rename-dialog";
export const RENAME_FILE_DIALOG = 'renameFileDialog';
diff --git a/src/views-components/snackbar/snackbar.tsx b/src/views-components/snackbar/snackbar.tsx
index c65d364..535777e 100644
--- a/src/views-components/snackbar/snackbar.tsx
+++ b/src/views-components/snackbar/snackbar.tsx
@@ -4,10 +4,10 @@
import * as React from "react";
import { connect } from "react-redux";
-import { RootState } from "../../store/store";
+import { RootState } from "~/store/store";
import MaterialSnackbar, { SnackbarProps } from "@material-ui/core/Snackbar";
import { Dispatch } from "redux";
-import { snackbarActions } from "../../store/snackbar/snackbar-actions";
+import { snackbarActions } from "~/store/snackbar/snackbar-actions";
const mapStateToProps = (state: RootState): SnackbarProps => ({
anchorOrigin: { vertical: "bottom", horizontal: "center" },
diff --git a/src/views-components/tree-picker/tree-picker.ts b/src/views-components/tree-picker/tree-picker.ts
index 3e0fc6e..09a0744 100644
--- a/src/views-components/tree-picker/tree-picker.ts
+++ b/src/views-components/tree-picker/tree-picker.ts
@@ -3,10 +3,10 @@
// SPDX-License-Identifier: AGPL-3.0
import { connect } from "react-redux";
-import { Tree, TreeProps, TreeItem } from "../../components/tree/tree";
-import { RootState } from "../../store/store";
-import { TreePicker as TTreePicker, TreePickerNode, createTreePickerNode } from "../../store/tree-picker/tree-picker";
-import { getNodeValue, getNodeChildren } from "../../models/tree";
+import { Tree, TreeProps, TreeItem } from "~/components/tree/tree";
+import { RootState } from "~/store/store";
+import { TreePicker as TTreePicker, TreePickerNode, createTreePickerNode } from "~/store/tree-picker/tree-picker";
+import { getNodeValue, getNodeChildren } from "~/models/tree";
const memoizedMapStateToProps = () => {
let prevState: TTreePicker;
diff --git a/src/views-components/update-collection-dialog/update-collection-dialog..tsx b/src/views-components/update-collection-dialog/update-collection-dialog..tsx
index 1374ac4..239df58 100644
--- a/src/views-components/update-collection-dialog/update-collection-dialog..tsx
+++ b/src/views-components/update-collection-dialog/update-collection-dialog..tsx
@@ -5,11 +5,11 @@
import { connect } from "react-redux";
import { Dispatch } from "redux";
import { SubmissionError } from "redux-form";
-import { RootState } from "../../store/store";
-import { snackbarActions } from "../../store/snackbar/snackbar-actions";
-import { collectionUpdaterActions, updateCollection } from "../../store/collections/updater/collection-updater-action";
-import { dataExplorerActions } from "../../store/data-explorer/data-explorer-action";
-import { PROJECT_PANEL_ID } from "../../views/project-panel/project-panel";
+import { RootState } from "~/store/store";
+import { snackbarActions } from "~/store/snackbar/snackbar-actions";
+import { collectionUpdaterActions, updateCollection } from "~/store/collections/updater/collection-updater-action";
+import { dataExplorerActions } from "~/store/data-explorer/data-explorer-action";
+import { PROJECT_PANEL_ID } from "~/views/project-panel/project-panel";
import { DialogCollectionUpdate } from "../dialog-update/dialog-collection-update";
const mapStateToProps = (state: RootState) => ({
diff --git a/src/views/collection-panel/collection-panel.tsx b/src/views/collection-panel/collection-panel.tsx
index 489d284..5baa6d1 100644
--- a/src/views/collection-panel/collection-panel.tsx
+++ b/src/views/collection-panel/collection-panel.tsx
@@ -9,16 +9,16 @@ import {
} from '@material-ui/core';
import { connect, DispatchProp } from "react-redux";
import { RouteComponentProps } from 'react-router';
-import { ArvadosTheme } from '../../common/custom-theme';
-import { RootState } from '../../store/store';
-import { MoreOptionsIcon, CollectionIcon, CopyIcon } from '../../components/icon/icon';
-import { DetailsAttribute } from '../../components/details-attribute/details-attribute';
-import { CollectionResource } from '../../models/collection';
-import { CollectionPanelFiles } from '../../views-components/collection-panel-files/collection-panel-files';
+import { ArvadosTheme } from '~/common/custom-theme';
+import { RootState } from '~/store/store';
+import { MoreOptionsIcon, CollectionIcon, CopyIcon } from '~/components/icon/icon';
+import { DetailsAttribute } from '~/components/details-attribute/details-attribute';
+import { CollectionResource } from '~/models/collection';
+import { CollectionPanelFiles } from '~/views-components/collection-panel-files/collection-panel-files';
import * as CopyToClipboard from 'react-copy-to-clipboard';
-import { TagResource } from '../../models/tag';
+import { TagResource } from '~/models/tag';
import { CollectionTagForm } from './collection-tag-form';
-import { deleteCollectionTag } from '../../store/collection-panel/collection-panel-action';
+import { deleteCollectionTag } from '~/store/collection-panel/collection-panel-action';
type CssRules = 'card' | 'iconHeader' | 'tag' | 'copyIcon' | 'value';
@@ -60,11 +60,11 @@ type CollectionPanelProps = CollectionPanelDataProps & CollectionPanelActionProp
export const CollectionPanel = withStyles(styles)(
- connect((state: RootState) => ({
- item: state.collectionPanel.item,
- tags: state.collectionPanel.tags
+ connect((state: RootState) => ({
+ item: state.collectionPanel.item,
+ tags: state.collectionPanel.tags
}))(
- class extends React.Component<CollectionPanelProps> {
+ class extends React.Component<CollectionPanelProps> {
render() {
const { classes, item, tags, onContextMenu } = this.props;
@@ -84,8 +84,8 @@ export const CollectionPanel = withStyles(styles)(
<CardContent>
<Grid container direction="column">
<Grid item xs={6}>
- <DetailsAttribute classValue={classes.value}
- label='Collection UUID'
+ <DetailsAttribute classValue={classes.value}
+ label='Collection UUID'
value={item && item.uuid}>
<CopyToClipboard text={item && item.uuid}>
<CopyIcon className={classes.copyIcon} />
diff --git a/src/views/collection-panel/collection-tag-form.tsx b/src/views/collection-panel/collection-tag-form.tsx
index 89cf880..8f25404 100644
--- a/src/views/collection-panel/collection-tag-form.tsx
+++ b/src/views/collection-panel/collection-tag-form.tsx
@@ -5,17 +5,17 @@
import * as React from 'react';
import { reduxForm, Field, reset } from 'redux-form';
import { compose, Dispatch } from 'redux';
-import { ArvadosTheme } from '../../common/custom-theme';
+import { ArvadosTheme } from '~/common/custom-theme';
import { StyleRulesCallback, withStyles, WithStyles, TextField, Button, CircularProgress } from '@material-ui/core';
-import { TagProperty } from '../../models/tag';
-import { createCollectionTag, COLLECTION_TAG_FORM_NAME } from '../../store/collection-panel/collection-panel-action';
-import { TAG_VALUE_VALIDATION, TAG_KEY_VALIDATION } from '../../validators/validators';
+import { TagProperty } from '~/models/tag';
+import { createCollectionTag, COLLECTION_TAG_FORM_NAME } from '~/store/collection-panel/collection-panel-action';
+import { TAG_VALUE_VALIDATION, TAG_KEY_VALIDATION } from '~/validators/validators';
type CssRules = 'form' | 'textField' | 'buttonWrapper' | 'saveButton' | 'circularProgress';
const styles: StyleRulesCallback<CssRules> = (theme: ArvadosTheme) => ({
form: {
- marginBottom: theme.spacing.unit * 4
+ marginBottom: theme.spacing.unit * 4
},
textField: {
marginRight: theme.spacing.unit
@@ -58,15 +58,15 @@ interface TextFieldProps {
type CollectionTagFormProps = CollectionTagFormDataProps & CollectionTagFormActionProps & WithStyles<CssRules>;
export const CollectionTagForm = compose(
- reduxForm({
- form: COLLECTION_TAG_FORM_NAME,
+ reduxForm({
+ form: COLLECTION_TAG_FORM_NAME,
onSubmit: (data: TagProperty, dispatch: Dispatch) => {
dispatch<any>(createCollectionTag(data));
dispatch(reset(COLLECTION_TAG_FORM_NAME));
- }
+ }
}),
withStyles(styles))(
-
+
class CollectionTagForm extends React.Component<CollectionTagFormProps> {
render() {
@@ -115,4 +115,4 @@ export const CollectionTagForm = compose(
}
- );
\ No newline at end of file
+ );
diff --git a/src/views/favorite-panel/favorite-panel-item.ts b/src/views/favorite-panel/favorite-panel-item.ts
index da48298..842b6d6 100644
--- a/src/views/favorite-panel/favorite-panel-item.ts
+++ b/src/views/favorite-panel/favorite-panel-item.ts
@@ -2,8 +2,8 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { GroupContentsResource } from "../../services/groups-service/groups-service";
-import { ResourceKind } from "../../models/resource";
+import { GroupContentsResource } from "~/services/groups-service/groups-service";
+import { ResourceKind } from "~/models/resource";
export interface FavoritePanelItem {
uuid: string;
@@ -16,7 +16,6 @@ export interface FavoritePanelItem {
status?: string;
}
-
export function resourceToDataItem(r: GroupContentsResource): FavoritePanelItem {
return {
uuid: r.uuid,
@@ -28,4 +27,3 @@ export function resourceToDataItem(r: GroupContentsResource): FavoritePanelItem
status: r.kind === ResourceKind.PROCESS ? r.state : undefined
};
}
-
diff --git a/src/views/favorite-panel/favorite-panel.tsx b/src/views/favorite-panel/favorite-panel.tsx
index f99afec..899ef3a 100644
--- a/src/views/favorite-panel/favorite-panel.tsx
+++ b/src/views/favorite-panel/favorite-panel.tsx
@@ -5,19 +5,19 @@
import * as React from 'react';
import { FavoritePanelItem } from './favorite-panel-item';
import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core';
-import { DataExplorer } from "../../views-components/data-explorer/data-explorer";
+import { DataExplorer } from "~/views-components/data-explorer/data-explorer";
import { DispatchProp, connect } from 'react-redux';
-import { DataColumns } from '../../components/data-table/data-table';
+import { DataColumns } from '~/components/data-table/data-table';
import { RouteComponentProps } from 'react-router';
-import { RootState } from '../../store/store';
-import { DataTableFilterItem } from '../../components/data-table-filters/data-table-filters';
-import { ContainerRequestState } from '../../models/container-request';
-import { SortDirection } from '../../components/data-table/data-column';
-import { ResourceKind } from '../../models/resource';
-import { resourceLabel } from '../../common/labels';
-import { ArvadosTheme } from '../../common/custom-theme';
-import { renderName, renderStatus, renderType, renderOwner, renderFileSize, renderDate } from '../../views-components/data-explorer/renderers';
-import { FAVORITE_PANEL_ID } from "../../store/favorite-panel/favorite-panel-action";
+import { RootState } from '~/store/store';
+import { DataTableFilterItem } from '~/components/data-table-filters/data-table-filters';
+import { ContainerRequestState } from '~/models/container-request';
+import { SortDirection } from '~/components/data-table/data-column';
+import { ResourceKind } from '~/models/resource';
+import { resourceLabel } from '~/common/labels';
+import { ArvadosTheme } from '~/common/custom-theme';
+import { renderName, renderStatus, renderType, renderOwner, renderFileSize, renderDate } from '~/views-components/data-explorer/renderers';
+import { FAVORITE_PANEL_ID } from "~/store/favorite-panel/favorite-panel-action";
type CssRules = "toolbar" | "button";
diff --git a/src/views/project-panel/project-panel-item.ts b/src/views/project-panel/project-panel-item.ts
index d81ef50..f031859 100644
--- a/src/views/project-panel/project-panel-item.ts
+++ b/src/views/project-panel/project-panel-item.ts
@@ -2,8 +2,8 @@
//
// SPDX-License-Identifier: AGPL-3.0
-import { GroupContentsResource } from "../../services/groups-service/groups-service";
-import { ResourceKind } from "../../models/resource";
+import { GroupContentsResource } from "~/services/groups-service/groups-service";
+import { ResourceKind } from "~/models/resource";
export interface ProjectPanelItem {
uuid: string;
@@ -17,7 +17,6 @@ export interface ProjectPanelItem {
status?: string;
}
-
export function resourceToDataItem(r: GroupContentsResource): ProjectPanelItem {
return {
uuid: r.uuid,
@@ -30,4 +29,3 @@ export function resourceToDataItem(r: GroupContentsResource): ProjectPanelItem {
status: r.kind === ResourceKind.PROCESS ? r.state : undefined
};
}
-
diff --git a/src/views/project-panel/project-panel.tsx b/src/views/project-panel/project-panel.tsx
index 0cd75ca..fccd93e 100644
--- a/src/views/project-panel/project-panel.tsx
+++ b/src/views/project-panel/project-panel.tsx
@@ -5,19 +5,19 @@
import * as React from 'react';
import { ProjectPanelItem } from './project-panel-item';
import { Button, StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core';
-import { DataExplorer } from "../../views-components/data-explorer/data-explorer";
+import { DataExplorer } from "~/views-components/data-explorer/data-explorer";
import { DispatchProp, connect } from 'react-redux';
-import { DataColumns } from '../../components/data-table/data-table';
+import { DataColumns } from '~/components/data-table/data-table';
import { RouteComponentProps } from 'react-router';
-import { RootState } from '../../store/store';
-import { DataTableFilterItem } from '../../components/data-table-filters/data-table-filters';
-import { ContainerRequestState } from '../../models/container-request';
-import { SortDirection } from '../../components/data-table/data-column';
-import { ResourceKind } from '../../models/resource';
-import { resourceLabel } from '../../common/labels';
-import { ArvadosTheme } from '../../common/custom-theme';
-import { renderName, renderStatus, renderType, renderOwner, renderFileSize, renderDate } from '../../views-components/data-explorer/renderers';
-import { restoreBranch } from '../../store/navigation/navigation-action';
+import { RootState } from '~/store/store';
+import { DataTableFilterItem } from '~/components/data-table-filters/data-table-filters';
+import { ContainerRequestState } from '~/models/container-request';
+import { SortDirection } from '~/components/data-table/data-column';
+import { ResourceKind } from '~/models/resource';
+import { resourceLabel } from '~/common/labels';
+import { ArvadosTheme } from '~/common/custom-theme';
+import { renderName, renderStatus, renderType, renderOwner, renderFileSize, renderDate } from '~/views-components/data-explorer/renderers';
+import { restoreBranch } from '~/store/navigation/navigation-action';
type CssRules = "toolbar" | "button";
diff --git a/src/views/workbench/workbench.test.tsx b/src/views/workbench/workbench.test.tsx
index 8e0b353..3587283 100644
--- a/src/views/workbench/workbench.test.tsx
+++ b/src/views/workbench/workbench.test.tsx
@@ -4,25 +4,26 @@
import * as React from 'react';
import * as ReactDOM from 'react-dom';
-import { Workbench } from '../../views/workbench/workbench';
+import { Workbench } from './workbench';
import { Provider } from "react-redux";
-import { configureStore } from "../../store/store";
+import { configureStore } from "~/store/store";
import createBrowserHistory from "history/createBrowserHistory";
import { ConnectedRouter } from "react-router-redux";
import { MuiThemeProvider } from '@material-ui/core/styles';
-import { CustomTheme } from '../../common/custom-theme';
-import { createServices } from "../../services/services";
+import { CustomTheme } from '~/common/custom-theme';
+import { createServices } from "~/services/services";
const history = createBrowserHistory();
it('renders without crashing', () => {
const div = document.createElement('div');
- const store = configureStore(createBrowserHistory(), createServices("/arvados/v1"));
+ const services = createServices("/arvados/v1");
+ const store = configureStore(createBrowserHistory(), services);
ReactDOM.render(
<MuiThemeProvider theme={CustomTheme}>
<Provider store={store}>
<ConnectedRouter history={history}>
- <Workbench/>
+ <Workbench authService={services.authService}/>
</ConnectedRouter>
</Provider>
</MuiThemeProvider>,
diff --git a/src/views/workbench/workbench.tsx b/src/views/workbench/workbench.tsx
index ab7ac38..a7f14aa 100644
--- a/src/views/workbench/workbench.tsx
+++ b/src/views/workbench/workbench.tsx
@@ -6,49 +6,49 @@ import * as React from 'react';
import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core/styles';
import Drawer from '@material-ui/core/Drawer';
import { connect, DispatchProp } from "react-redux";
-import { Route, Switch, RouteComponentProps } from "react-router";
-import { login, logout } from "../../store/auth/auth-action";
-import { User } from "../../models/user";
-import { RootState } from "../../store/store";
-import { MainAppBar, MainAppBarActionProps, MainAppBarMenuItem } from '../../views-components/main-app-bar/main-app-bar';
-import { Breadcrumb } from '../../components/breadcrumbs/breadcrumbs';
+import { Route, RouteComponentProps, Switch } from "react-router";
+import { login, logout } from "~/store/auth/auth-action";
+import { User } from "~/models/user";
+import { RootState } from "~/store/store";
+import { MainAppBar, MainAppBarActionProps, MainAppBarMenuItem } from '~/views-components/main-app-bar/main-app-bar';
+import { Breadcrumb } from '~/components/breadcrumbs/breadcrumbs';
import { push } from 'react-router-redux';
import { reset } from 'redux-form';
-import { ProjectTree } from '../../views-components/project-tree/project-tree';
-import { TreeItem } from "../../components/tree/tree";
-import { getTreePath } from '../../store/project/project-reducer';
-import { sidePanelActions } from '../../store/side-panel/side-panel-action';
-import { SidePanel, SidePanelItem } from '../../components/side-panel/side-panel';
-import { ItemMode, setProjectItem } from "../../store/navigation/navigation-action";
-import { projectActions } from "../../store/project/project-action";
-import { collectionCreateActions } from '../../store/collections/creator/collection-creator-action';
-import { ProjectPanel } from "../project-panel/project-panel";
-import { DetailsPanel } from '../../views-components/details-panel/details-panel';
-import { ArvadosTheme } from '../../common/custom-theme';
-import { CreateProjectDialog } from "../../views-components/create-project-dialog/create-project-dialog";
+import { ProjectTree } from '~/views-components/project-tree/project-tree';
+import { TreeItem } from "~/components/tree/tree";
+import { getTreePath } from '~/store/project/project-reducer';
+import { sidePanelActions } from '~/store/side-panel/side-panel-action';
+import { SidePanel, SidePanelItem } from '~/components/side-panel/side-panel';
+import { ItemMode, setProjectItem } from "~/store/navigation/navigation-action";
+import { projectActions } from "~/store/project/project-action";
+import { collectionCreateActions } from '~/store/collections/creator/collection-creator-action';
+import { ProjectPanel } from "~/views/project-panel/project-panel";
+import { DetailsPanel } from '~/views-components/details-panel/details-panel';
+import { ArvadosTheme } from '~/common/custom-theme';
+import { CreateProjectDialog } from "~/views-components/create-project-dialog/create-project-dialog";
-import { detailsPanelActions, loadDetails } from "../../store/details-panel/details-panel-action";
-import { contextMenuActions } from "../../store/context-menu/context-menu-actions";
-import { SidePanelIdentifiers } from '../../store/side-panel/side-panel-reducer';
-import { ProjectResource } from '../../models/project';
-import { ResourceKind } from '../../models/resource';
-import { ContextMenu, ContextMenuKind } from "../../views-components/context-menu/context-menu";
+import { detailsPanelActions, loadDetails } from "~/store/details-panel/details-panel-action";
+import { contextMenuActions } from "~/store/context-menu/context-menu-actions";
+import { SidePanelIdentifiers } from '~/store/side-panel/side-panel-reducer';
+import { ProjectResource } from '~/models/project';
+import { ResourceKind } from '~/models/resource';
+import { ContextMenu, ContextMenuKind } from "~/views-components/context-menu/context-menu";
import { FavoritePanel } from "../favorite-panel/favorite-panel";
-import { CurrentTokenDialog } from '../../views-components/current-token-dialog/current-token-dialog';
-import { Snackbar } from '../../views-components/snackbar/snackbar';
-import { favoritePanelActions } from '../../store/favorite-panel/favorite-panel-action';
-import { CreateCollectionDialog } from '../../views-components/create-collection-dialog/create-collection-dialog';
+import { CurrentTokenDialog } from '~/views-components/current-token-dialog/current-token-dialog';
+import { Snackbar } from '~/views-components/snackbar/snackbar';
+import { favoritePanelActions } from '~/store/favorite-panel/favorite-panel-action';
+import { CreateCollectionDialog } from '~/views-components/create-collection-dialog/create-collection-dialog';
import { CollectionPanel } from '../collection-panel/collection-panel';
-import { loadCollection, loadCollectionTags } from '../../store/collection-panel/collection-panel-action';
-import { getCollectionUrl } from '../../models/collection';
-import { UpdateCollectionDialog } from '../../views-components/update-collection-dialog/update-collection-dialog.';
-import { AuthService } from "../../services/auth-service/auth-service";
-import { RenameFileDialog } from '../../views-components/rename-file-dialog/rename-file-dialog';
-import { FileRemoveDialog } from '../../views-components/file-remove-dialog/file-remove-dialog';
-import { MultipleFilesRemoveDialog } from '../../views-components/file-remove-dialog/multiple-files-remove-dialog';
-import { DialogCollectionCreateWithSelectedFile } from '../../views-components/create-collection-dialog-with-selected/create-collection-dialog-with-selected';
-import { COLLECTION_CREATE_DIALOG } from '../../views-components/dialog-create/dialog-collection-create';
-import { PROJECT_CREATE_DIALOG } from '../../views-components/dialog-create/dialog-project-create';
+import { loadCollection, loadCollectionTags } from '~/store/collection-panel/collection-panel-action';
+import { getCollectionUrl } from '~/models/collection';
+import { UpdateCollectionDialog } from '~/views-components/update-collection-dialog/update-collection-dialog.';
+import { AuthService } from "~/services/auth-service/auth-service";
+import { RenameFileDialog } from '~/views-components/rename-file-dialog/rename-file-dialog';
+import { FileRemoveDialog } from '~/views-components/file-remove-dialog/file-remove-dialog';
+import { MultipleFilesRemoveDialog } from '~/views-components/file-remove-dialog/multiple-files-remove-dialog';
+import { DialogCollectionCreateWithSelectedFile } from '~/views-components/create-collection-dialog-with-selected/create-collection-dialog-with-selected';
+import { COLLECTION_CREATE_DIALOG } from '~/views-components/dialog-create/dialog-collection-create';
+import { PROJECT_CREATE_DIALOG } from '~/views-components/dialog-create/dialog-project-create';
const DRAWER_WITDH = 240;
const APP_BAR_HEIGHT = 100;
@@ -251,7 +251,7 @@ export const Workbench = withStyles(styles)(
);
}
- renderCollectionPanel = (props: RouteComponentProps<{ id: string }>) => <CollectionPanel
+ renderCollectionPanel = (props: RouteComponentProps<{ id: string }>) => <CollectionPanel
onItemRouteChange={(collectionId) => {
this.props.dispatch<any>(loadCollection(collectionId, ResourceKind.COLLECTION));
this.props.dispatch<any>(loadCollectionTags(collectionId));
@@ -278,7 +278,7 @@ export const Workbench = withStyles(styles)(
} else {
kind = ContextMenuKind.RESOURCE;
}
-
+
this.openContextMenu(event, {
uuid: item.uuid,
name: item.name,
@@ -296,7 +296,7 @@ export const Workbench = withStyles(styles)(
case ResourceKind.COLLECTION:
this.props.dispatch(loadCollection(item.uuid, item.kind as ResourceKind));
this.props.dispatch(push(getCollectionUrl(item.uuid)));
- default:
+ default:
this.props.dispatch(setProjectItem(item.uuid, ItemMode.ACTIVE));
this.props.dispatch(loadDetails(item.uuid, item.kind as ResourceKind));
}
diff --git a/tsconfig.json b/tsconfig.json
index af933d9..b0e2455 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -1,6 +1,6 @@
{
"compilerOptions": {
- "baseUrl": ".",
+ "baseUrl": "./",
"outDir": "build/dist",
"module": "esnext",
"target": "es5",
@@ -18,11 +18,10 @@
"suppressImplicitAnyIndexErrors": true,
"noUnusedLocals": false,
"experimentalDecorators": true,
- "emitDecoratorMetadata": true
- // waits for moduleNameMapper being able to override
- // "paths": {
- // "~/*": ["src/*"]
- // }
+ "emitDecoratorMetadata": true,
+ "paths": {
+ "~/*": ["src/*"]
+ }
},
"exclude": [
"node_modules",
diff --git a/yarn.lock b/yarn.lock
index 700f4ad..ae2b1c5 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -6226,9 +6226,9 @@ react-router at 4.3.1, react-router@^4.2.0, react-router@^4.3.1:
prop-types "^15.6.1"
warning "^4.0.1"
-react-scripts-ts at 2.16.0:
- version "2.16.0"
- resolved "https://registry.yarnpkg.com/react-scripts-ts/-/react-scripts-ts-2.16.0.tgz#45f831a12139c3b59d6bb729c1b6ef51e0f22908"
+react-scripts-ts at 2.17.0:
+ version "2.17.0"
+ resolved "https://registry.yarnpkg.com/react-scripts-ts/-/react-scripts-ts-2.17.0.tgz#398bae19a30c9b39b3dfe0720ebb40c60c2f6574"
dependencies:
autoprefixer "7.1.6"
babel-jest "^22.1.0"
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list