@databiosphere/findable-ui 35.0.3 → 35.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.release-please-manifest.json +1 -1
- package/CHANGELOG.md +19 -0
- package/lib/common/entities.d.ts +1 -0
- package/lib/components/DataDictionary/components/Table/hook.js +1 -0
- package/lib/components/DataDictionary/hooks/UseDataDictionary/hook.js +15 -2
- package/lib/components/Export/components/ManifestDownload/components/ManifestDownloadEntity/components/FileManifestDownload/fileManifestDownload.js +21 -29
- package/lib/components/Export/components/ManifestDownload/components/ManifestDownloadEntity/components/FileManifestSpreadsheet/fileManifestSpreadsheet.js +21 -36
- package/lib/components/Export/components/ManifestDownload/components/ManifestDownloadEntity/constants.d.ts +2 -0
- package/lib/components/Export/components/ManifestDownload/components/ManifestDownloadEntity/constants.js +22 -0
- package/lib/components/Table/components/TableCell/components/CodeCell/codeCell.d.ts +3 -0
- package/lib/components/Table/components/TableCell/components/CodeCell/codeCell.js +9 -0
- package/lib/components/Table/components/TableCell/components/CodeCell/codeCell.styles.d.ts +5 -0
- package/lib/components/Table/components/TableCell/components/CodeCell/codeCell.styles.js +15 -0
- package/lib/hooks/useFileManifest/useFileManifestDownload.d.ts +2 -2
- package/lib/hooks/useFileManifest/useFileManifestDownload.js +3 -10
- package/lib/hooks/useFileManifest/useFileManifestSpreadsheet.d.ts +5 -4
- package/lib/hooks/useFileManifest/useFileManifestSpreadsheet.js +24 -20
- package/package.json +1 -1
- package/src/common/entities.ts +1 -0
- package/src/components/DataDictionary/components/Table/hook.ts +1 -0
- package/src/components/DataDictionary/hooks/UseDataDictionary/hook.ts +17 -4
- package/src/components/Export/components/ManifestDownload/components/ManifestDownloadEntity/components/FileManifestDownload/fileManifestDownload.tsx +43 -71
- package/src/components/Export/components/ManifestDownload/components/ManifestDownloadEntity/components/FileManifestSpreadsheet/fileManifestSpreadsheet.tsx +52 -74
- package/src/components/Export/components/ManifestDownload/components/ManifestDownloadEntity/constants.ts +24 -0
- package/src/components/Table/components/TableCell/components/CodeCell/codeCell.styles.ts +16 -0
- package/src/components/Table/components/TableCell/components/CodeCell/codeCell.tsx +21 -0
- package/src/hooks/useFileManifest/useFileManifestDownload.ts +9 -16
- package/src/hooks/useFileManifest/useFileManifestSpreadsheet.ts +41 -26
- package/lib/components/DataDictionary/components/Table/columns/columnDef.d.ts +0 -6
- package/lib/components/DataDictionary/components/Table/columns/columnDef.js +0 -33
- package/lib/components/DataDictionary/components/Table/columns/columnIdentifier.d.ts +0 -5
- package/lib/components/DataDictionary/components/Table/columns/columnIdentifier.js +0 -5
- package/lib/components/DataDictionary/components/Table/columns/types.d.ts +0 -2
- package/lib/components/DataDictionary/components/Table/columns/types.js +0 -1
- package/lib/components/DataDictionary/components/Table/components/BasicCell/types.d.ts +0 -4
- package/lib/components/DataDictionary/components/Table/components/BasicCell/types.js +0 -1
- package/lib/components/Detail/components/Table/components/TableHead/tableHead.d.ts +0 -8
- package/lib/components/Detail/components/Table/components/TableHead/tableHead.js +0 -36
- package/lib/components/Filter/components/Filter/filter.stories.d.ts +0 -25
- package/lib/components/Filter/components/Filter/filter.stories.js +0 -42
- package/lib/components/Filter/components/FilterTag/filterTag.stories.d.ts +0 -16
- package/lib/components/Filter/components/FilterTag/filterTag.stories.js +0 -17
- package/lib/components/Filter/components/Filters/filters.stories.d.ts +0 -6
- package/lib/components/Filter/components/Filters/filters.stories.js +0 -91
- package/lib/components/Index/components/Cell/cell.d.ts +0 -7
- package/lib/components/Index/components/Cell/cell.js +0 -10
- package/lib/components/Index/components/EntitiesView/constants.d.ts +0 -1
- package/lib/components/Index/components/EntitiesView/constants.js +0 -1
- package/lib/components/Index/components/Hero/components/Summaries/summaries.stories.d.ts +0 -13
- package/lib/components/Index/components/Hero/components/Summaries/summaries.stories.js +0 -18
- package/lib/components/Index/components/Hero/hero.stories.d.ts +0 -23
- package/lib/components/Index/components/Hero/hero.stories.js +0 -22
- package/lib/components/Index/components/NTag/components/Tooltip/tooltip.d.ts +0 -8
- package/lib/components/Index/components/NTag/components/Tooltip/tooltip.js +0 -57
- package/lib/components/Index/components/NTag/components/Tooltip/tooltip.styles.d.ts +0 -4
- package/lib/components/Index/components/NTag/components/Tooltip/tooltip.styles.js +0 -10
- package/lib/components/Index/components/NTag/nTag.d.ts +0 -10
- package/lib/components/Index/components/NTag/nTag.js +0 -8
- package/lib/components/Index/components/NTagCell/nTagCell.d.ts +0 -11
- package/lib/components/Index/components/NTagCell/nTagCell.js +0 -29
- package/lib/components/Index/components/NTagCell/nTagCell.stories.d.ts +0 -5
- package/lib/components/Index/components/NTagCell/nTagCell.stories.js +0 -16
- package/lib/components/Index/components/TitleCell/titleCell.d.ts +0 -6
- package/lib/components/Index/components/TitleCell/titleCell.js +0 -10
- package/lib/components/Index/components/TitleCell/titleCell.styles.d.ts +0 -3
- package/lib/components/Index/components/TitleCell/titleCell.styles.js +0 -6
- package/lib/components/Index/index.stories.d.ts +0 -6
- package/lib/components/Index/index.stories.js +0 -26
- package/lib/components/Layout/components/BackPage/components/BackPageHero/backPageHero.stories.d.ts +0 -6
- package/lib/components/Layout/components/BackPage/components/BackPageHero/backPageHero.stories.js +0 -10
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Authentication/components/AuthenticationMenu/authenticationMenu.stories.d.ts +0 -5
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Authentication/components/AuthenticationMenu/authenticationMenu.stories.js +0 -29
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Authentication/components/RequestAuthentication/requestAuthentication.d.ts +0 -6
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Authentication/components/RequestAuthentication/requestAuthentication.js +0 -13
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Authentication/components/RequestAuthentication/requestAuthentication.styles.d.ts +0 -36
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Authentication/components/RequestAuthentication/requestAuthentication.styles.js +0 -9
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Search/components/SearchButton/searchButton.d.ts +0 -5
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Search/components/SearchButton/searchButton.js +0 -10
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Search/components/SearchButton/searchButton.styles.d.ts +0 -36
- package/lib/components/Layout/components/Header/components/Content/components/Actions/components/Search/components/SearchButton/searchButton.styles.js +0 -9
- package/lib/components/Layout/components/Header/hooks/useMeasureHeader.d.ts +0 -5
- package/lib/components/Layout/components/Header/hooks/useMeasureHeader.js +0 -19
- package/lib/components/Layout/components/Outline/common/constants.d.ts +0 -2
- package/lib/components/Layout/components/Outline/common/constants.js +0 -1
- package/lib/components/Login/login.stories.d.ts +0 -6
- package/lib/components/Login/login.stories.js +0 -31
- package/lib/components/Table/components/CheckboxMenu/checkboxMenu.d.ts +0 -16
- package/lib/components/Table/components/CheckboxMenu/checkboxMenu.js +0 -28
- package/lib/components/Table/components/CheckboxMenu/checkboxMenu.stories.d.ts +0 -5
- package/lib/components/Table/components/CheckboxMenu/checkboxMenu.stories.js +0 -46
- package/lib/components/Table/components/CheckboxMenu/checkboxMenu.styles.d.ts +0 -3
- package/lib/components/Table/components/CheckboxMenu/checkboxMenu.styles.js +0 -21
- package/lib/components/Table/components/EntityViewToggle/entityViewToggle.d.ts +0 -2
- package/lib/components/Table/components/EntityViewToggle/entityViewToggle.js +0 -37
- package/lib/components/TableCreator/common/constants.d.ts +0 -6
- package/lib/components/TableCreator/common/constants.js +0 -19
- package/lib/components/TableCreator/common/entities.d.ts +0 -5
- package/lib/components/TableCreator/common/entities.js +0 -1
- package/lib/components/TableCreator/tableCreator.styles.d.ts +0 -4
- package/lib/components/TableCreator/tableCreator.styles.js +0 -4
- package/lib/components/common/Alert/alert.stories.d.ts +0 -6
- package/lib/components/common/Alert/alert.stories.js +0 -36
- package/lib/components/common/Alert/components/AlertText/alertText.styles.d.ts +0 -4
- package/lib/components/common/Alert/components/AlertText/alertText.styles.js +0 -19
- package/lib/components/common/Banner/components/BannerPrimary/bannerPrimary.d.ts +0 -7
- package/lib/components/common/Banner/components/BannerPrimary/bannerPrimary.js +0 -5
- package/lib/components/common/Banner/components/BannerPrimary/bannerPrimary.styles.d.ts +0 -3
- package/lib/components/common/Banner/components/BannerPrimary/bannerPrimary.styles.js +0 -19
- package/lib/components/common/Banner/components/DismissibleBanner/dismissibleBanner.d.ts +0 -10
- package/lib/components/common/Banner/components/DismissibleBanner/dismissibleBanner.js +0 -16
- package/lib/components/common/Banner/components/SessionTimeout/sessionTimeout.styles.d.ts +0 -3
- package/lib/components/common/Banner/components/SessionTimeout/sessionTimeout.styles.js +0 -21
- package/lib/components/common/Button/components/LoginButton/loginButton.d.ts +0 -3
- package/lib/components/common/Button/components/LoginButton/loginButton.js +0 -6
- package/lib/components/common/Button/components/LoginButton/loginButton.styles.d.ts +0 -7
- package/lib/components/common/Button/components/LoginButton/loginButton.styles.js +0 -11
- package/lib/components/common/IconButton/components/LoadingIconButton/loadingIconButton.d.ts +0 -5
- package/lib/components/common/IconButton/components/LoadingIconButton/loadingIconButton.js +0 -10
- package/lib/components/common/IconButton/components/LoadingIconButton/loadingIconButton.stories.d.ts +0 -3
- package/lib/components/common/IconButton/components/LoadingIconButton/loadingIconButton.stories.js +0 -9
- package/lib/hooks/useAuthentication/common/constants.d.ts +0 -4
- package/lib/hooks/useAuthentication/common/constants.js +0 -19
- package/lib/hooks/useAuthentication/common/entities.d.ts +0 -25
- package/lib/hooks/useAuthentication/common/entities.js +0 -11
- package/lib/hooks/useAuthentication/common/utils.d.ts +0 -15
- package/lib/hooks/useAuthentication/common/utils.js +0 -25
- package/lib/hooks/useAuthentication/useAuthentication.d.ts +0 -6
- package/lib/hooks/useAuthentication/useAuthentication.js +0 -9
- package/lib/hooks/useAuthentication/useAuthenticationComplete.d.ts +0 -6
- package/lib/hooks/useAuthentication/useAuthenticationComplete.js +0 -55
- package/lib/hooks/useAuthentication/useAuthenticationForm.d.ts +0 -20
- package/lib/hooks/useAuthentication/useAuthenticationForm.js +0 -88
- package/lib/hooks/useAuthentication/useAuthenticationNIHExpiry.d.ts +0 -18
- package/lib/hooks/useAuthentication/useAuthenticationNIHExpiry.js +0 -50
- package/lib/hooks/useAuthentication/useAuthenticationStatus.d.ts +0 -20
- package/lib/hooks/useAuthentication/useAuthenticationStatus.js +0 -32
- package/lib/hooks/useAuthentication/useFetchGoogleProfile.d.ts +0 -21
- package/lib/hooks/useAuthentication/useFetchGoogleProfile.js +0 -41
- package/lib/hooks/useAuthentication/useFetchTerraNIHProfile.d.ts +0 -18
- package/lib/hooks/useAuthentication/useFetchTerraNIHProfile.js +0 -62
- package/lib/hooks/useAuthentication/useFetchTerraProfile.d.ts +0 -24
- package/lib/hooks/useAuthentication/useFetchTerraProfile.js +0 -62
- package/lib/hooks/useAuthentication/useFetchTerraTermsOfService.d.ts +0 -15
- package/lib/hooks/useAuthentication/useFetchTerraTermsOfService.js +0 -62
- package/lib/hooks/useAuthentication/useTokenClient.d.ts +0 -11
- package/lib/hooks/useAuthentication/useTokenClient.js +0 -29
- package/lib/hooks/useAuthenticationConfig.d.ts +0 -6
- package/lib/hooks/useAuthenticationConfig.js +0 -14
- package/lib/hooks/useCategoryConfigs.d.ts +0 -6
- package/lib/hooks/useCategoryConfigs.js +0 -17
- package/lib/hooks/useEntityListRelatedView.d.ts +0 -15
- package/lib/hooks/useEntityListRelatedView.js +0 -62
- package/lib/hooks/useExploreMode.d.ts +0 -14
- package/lib/hooks/useExploreMode.js +0 -20
- package/lib/hooks/useFileManifest/common/buildFileManifestRequestURL.d.ts +0 -15
- package/lib/hooks/useFileManifest/common/buildFileManifestRequestURL.js +0 -27
- package/lib/hooks/useFileManifest/useFileManifestURL.d.ts +0 -5
- package/lib/hooks/useFileManifest/useFileManifestURL.js +0 -11
- package/lib/hooks/useFileManifest/useRequestFileManifest.d.ts +0 -9
- package/lib/hooks/useFileManifest/useRequestFileManifest.js +0 -37
- package/lib/hooks/useLayoutState.d.ts +0 -6
- package/lib/hooks/useLayoutState.js +0 -9
- package/lib/hooks/useMenu.d.ts +0 -10
- package/lib/hooks/useMenu.js +0 -17
- package/lib/hooks/useMenuWithPosition.d.ts +0 -14
- package/lib/hooks/useMenuWithPosition.js +0 -33
- package/lib/hooks/useSessionTimeout.d.ts +0 -11
- package/lib/hooks/useSessionTimeout.js +0 -28
- package/lib/providers/authentication.d.ts +0 -51
- package/lib/providers/authentication.js +0 -110
- package/lib/providers/layoutState.d.ts +0 -40
- package/lib/providers/layoutState.js +0 -47
- package/lib/styles/common/mixins/shadows.d.ts +0 -3
- package/lib/styles/common/mixins/shadows.js +0 -4
- package/lib/styles/common/mui/palette.d.ts +0 -47
- package/lib/styles/common/mui/palette.js +0 -47
- package/lib/theme/common/entities.d.ts +0 -6
- package/lib/theme/common/entities.js +0 -1
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.TableHead = void 0;
|
|
27
|
-
const material_1 = require("@mui/material");
|
|
28
|
-
const react_table_1 = require("@tanstack/react-table");
|
|
29
|
-
const react_1 = __importStar(require("react"));
|
|
30
|
-
const entities_1 = require("../../../../../Table/common/entities");
|
|
31
|
-
const TableHead = ({ rowDirection, tableInstance, }) => {
|
|
32
|
-
return (react_1.default.createElement(react_1.Fragment, null, rowDirection === entities_1.ROW_DIRECTION.DEFAULT &&
|
|
33
|
-
tableInstance.getHeaderGroups().map((headerGroup) => (react_1.default.createElement(material_1.TableHead, { key: headerGroup.id },
|
|
34
|
-
react_1.default.createElement(material_1.TableRow, null, headerGroup.headers.map((header) => (react_1.default.createElement(material_1.TableCell, { key: header.id }, (0, react_table_1.flexRender)(header.column.columnDef.header, header.getContext()))))))))));
|
|
35
|
-
};
|
|
36
|
-
exports.TableHead = TableHead;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { StoryObj } from "@storybook/react";
|
|
2
|
-
import React from "react";
|
|
3
|
-
declare const meta: {
|
|
4
|
-
argTypes: {
|
|
5
|
-
tags: {
|
|
6
|
-
control: {
|
|
7
|
-
disable: true;
|
|
8
|
-
};
|
|
9
|
-
};
|
|
10
|
-
};
|
|
11
|
-
component: ({ categorySection, categoryView, closeAncestor, isFilterDrawer, onFilter, tags, trackFilterOpened, }: import("./filter").FilterProps) => JSX.Element;
|
|
12
|
-
decorators: ((Story: import("@storybook/core/csf").PartialStoryFn<import("@storybook/react").ReactRenderer, {
|
|
13
|
-
categorySection?: string | undefined;
|
|
14
|
-
categoryView: import("../../../../common/entities").SelectCategoryView;
|
|
15
|
-
closeAncestor?: (() => void) | undefined;
|
|
16
|
-
isFilterDrawer: boolean;
|
|
17
|
-
onFilter: import("../../../../hooks/useCategoryFilter").OnFilterFn;
|
|
18
|
-
tags?: React.ReactNode;
|
|
19
|
-
trackFilterOpened?: import("../../../../config/entities").TrackFilterOpenedFunction | undefined;
|
|
20
|
-
}>) => JSX.Element)[];
|
|
21
|
-
title: string;
|
|
22
|
-
};
|
|
23
|
-
export default meta;
|
|
24
|
-
type Story = StoryObj<typeof meta>;
|
|
25
|
-
export declare const FilterStory: Story;
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Filter } from "./filter";
|
|
3
|
-
const meta = {
|
|
4
|
-
argTypes: {
|
|
5
|
-
tags: { control: { disable: true } },
|
|
6
|
-
},
|
|
7
|
-
component: Filter,
|
|
8
|
-
decorators: [
|
|
9
|
-
(Story) => (React.createElement("div", { style: { padding: "8px 12px 8px 16px", width: 264 } },
|
|
10
|
-
React.createElement(Story, null))),
|
|
11
|
-
],
|
|
12
|
-
title: "Components/Filter/Filter",
|
|
13
|
-
};
|
|
14
|
-
export default meta;
|
|
15
|
-
const onFilter = () => {
|
|
16
|
-
// onFilter function
|
|
17
|
-
};
|
|
18
|
-
export const FilterStory = {
|
|
19
|
-
args: {
|
|
20
|
-
categoryView: {
|
|
21
|
-
isDisabled: false,
|
|
22
|
-
key: "genusSpecies",
|
|
23
|
-
label: "Genus Species",
|
|
24
|
-
values: [
|
|
25
|
-
{
|
|
26
|
-
count: 12,
|
|
27
|
-
key: "homoSapiens",
|
|
28
|
-
label: "Homo sapiens",
|
|
29
|
-
selected: false,
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
count: 6,
|
|
33
|
-
key: "musMusculus",
|
|
34
|
-
label: "Mus musculus",
|
|
35
|
-
selected: false,
|
|
36
|
-
},
|
|
37
|
-
],
|
|
38
|
-
},
|
|
39
|
-
isFilterDrawer: false,
|
|
40
|
-
onFilter,
|
|
41
|
-
},
|
|
42
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { StoryObj } from "@storybook/react";
|
|
2
|
-
declare const meta: {
|
|
3
|
-
argTypes: {
|
|
4
|
-
label: {
|
|
5
|
-
control: "text";
|
|
6
|
-
};
|
|
7
|
-
superseded: {
|
|
8
|
-
control: "boolean";
|
|
9
|
-
};
|
|
10
|
-
};
|
|
11
|
-
component: ({ label, onRemove, superseded, }: import("./filterTag").FilterTagProps) => JSX.Element;
|
|
12
|
-
title: string;
|
|
13
|
-
};
|
|
14
|
-
export default meta;
|
|
15
|
-
type Story = StoryObj<typeof meta>;
|
|
16
|
-
export declare const FilterTagStory: Story;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { FilterTag } from "./filterTag";
|
|
2
|
-
const meta = {
|
|
3
|
-
argTypes: {
|
|
4
|
-
label: { control: "text" },
|
|
5
|
-
superseded: { control: "boolean" },
|
|
6
|
-
},
|
|
7
|
-
component: FilterTag,
|
|
8
|
-
title: "Components/Filter/FilterTag",
|
|
9
|
-
};
|
|
10
|
-
export default meta;
|
|
11
|
-
export const FilterTagStory = {
|
|
12
|
-
args: {
|
|
13
|
-
label: "Male",
|
|
14
|
-
onRemove: () => { },
|
|
15
|
-
superseded: false,
|
|
16
|
-
},
|
|
17
|
-
};
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { FilterMenuStory } from "../FilterMenu/filterMenu.stories";
|
|
3
|
-
import { Filters } from "./filters";
|
|
4
|
-
export default {
|
|
5
|
-
argTypes: {
|
|
6
|
-
categories: { control: { disable: true } },
|
|
7
|
-
onFilter: { control: { disable: true } },
|
|
8
|
-
},
|
|
9
|
-
component: Filters,
|
|
10
|
-
decorators: [
|
|
11
|
-
(Story) => (React.createElement("div", { style: { width: 264 } },
|
|
12
|
-
React.createElement(Story, null))),
|
|
13
|
-
],
|
|
14
|
-
title: "Components/Filter/Filters",
|
|
15
|
-
};
|
|
16
|
-
const onFilter = () => {
|
|
17
|
-
// onFilter function
|
|
18
|
-
};
|
|
19
|
-
const defaultValues = [
|
|
20
|
-
{
|
|
21
|
-
count: 1,
|
|
22
|
-
key: "item1",
|
|
23
|
-
label: "Item 1",
|
|
24
|
-
selected: false,
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
count: 10,
|
|
28
|
-
key: "item2",
|
|
29
|
-
label: "Item 2",
|
|
30
|
-
selected: false,
|
|
31
|
-
},
|
|
32
|
-
];
|
|
33
|
-
export const FiltersStory = {
|
|
34
|
-
args: {
|
|
35
|
-
categoryFilters: [
|
|
36
|
-
{
|
|
37
|
-
categoryViews: [
|
|
38
|
-
{
|
|
39
|
-
isDisabled: false,
|
|
40
|
-
key: "genusSpecies",
|
|
41
|
-
label: "Genus Species",
|
|
42
|
-
values: [
|
|
43
|
-
{
|
|
44
|
-
count: 12,
|
|
45
|
-
key: "homoSapiens",
|
|
46
|
-
label: "Homo sapiens",
|
|
47
|
-
selected: false,
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
count: 6,
|
|
51
|
-
key: "musMusculus",
|
|
52
|
-
label: "Mus musculus",
|
|
53
|
-
selected: false,
|
|
54
|
-
},
|
|
55
|
-
],
|
|
56
|
-
},
|
|
57
|
-
],
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
categoryViews: [
|
|
61
|
-
{
|
|
62
|
-
isDisabled: false,
|
|
63
|
-
key: "donorDisease",
|
|
64
|
-
label: "Donor Disease",
|
|
65
|
-
values: FilterMenuStory.args?.values || defaultValues,
|
|
66
|
-
},
|
|
67
|
-
{
|
|
68
|
-
isDisabled: true,
|
|
69
|
-
key: "anatomicalEntity",
|
|
70
|
-
label: "Anatomical Entity",
|
|
71
|
-
values: [
|
|
72
|
-
{
|
|
73
|
-
count: 12,
|
|
74
|
-
key: "oralCavity",
|
|
75
|
-
label: "oral cavity",
|
|
76
|
-
selected: true,
|
|
77
|
-
},
|
|
78
|
-
{
|
|
79
|
-
count: 6,
|
|
80
|
-
key: "pancreas",
|
|
81
|
-
label: "pancreas",
|
|
82
|
-
selected: false,
|
|
83
|
-
},
|
|
84
|
-
],
|
|
85
|
-
},
|
|
86
|
-
],
|
|
87
|
-
},
|
|
88
|
-
],
|
|
89
|
-
onFilter: onFilter,
|
|
90
|
-
},
|
|
91
|
-
};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
export interface CellProps {
|
|
2
|
-
value?: number | string | string[];
|
|
3
|
-
}
|
|
4
|
-
/**
|
|
5
|
-
* @deprecated - use BasicCell from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/BasicCell/basicCell"
|
|
6
|
-
*/
|
|
7
|
-
export declare const Cell: ({ value }: CellProps) => JSX.Element;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
/**
|
|
3
|
-
* @deprecated - use BasicCell from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/BasicCell/basicCell"
|
|
4
|
-
*/
|
|
5
|
-
export const Cell = ({ value = "Unspecified" }) => {
|
|
6
|
-
if (typeof value === "string" || typeof value === "number") {
|
|
7
|
-
return React.createElement("div", null, value);
|
|
8
|
-
}
|
|
9
|
-
return (React.createElement(React.Fragment, null, value.map((v) => (React.createElement("div", { key: v }, v)))));
|
|
10
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const ENTITIES_VIEW_TEST_ID = "entities-view";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export const ENTITIES_VIEW_TEST_ID = "entities-view";
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { StoryObj } from "@storybook/react";
|
|
2
|
-
declare const meta: {
|
|
3
|
-
argTypes: {
|
|
4
|
-
summaries: {
|
|
5
|
-
control: "object";
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
component: ({ summaries }: import("./summaries").SummariesProps) => JSX.Element;
|
|
9
|
-
title: string;
|
|
10
|
-
};
|
|
11
|
-
export default meta;
|
|
12
|
-
type Story = StoryObj<typeof meta>;
|
|
13
|
-
export declare const SummariesStory: Story;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Summaries } from "./summaries";
|
|
2
|
-
const meta = {
|
|
3
|
-
argTypes: {
|
|
4
|
-
summaries: { control: "object" },
|
|
5
|
-
},
|
|
6
|
-
component: Summaries,
|
|
7
|
-
title: "Components/Summary",
|
|
8
|
-
};
|
|
9
|
-
export default meta;
|
|
10
|
-
export const SummariesStory = {
|
|
11
|
-
args: {
|
|
12
|
-
summaries: [
|
|
13
|
-
{ count: "1", label: "Species" },
|
|
14
|
-
{ count: "1.1k", label: "Donors" },
|
|
15
|
-
{ count: "508.5k", label: "Files" },
|
|
16
|
-
],
|
|
17
|
-
},
|
|
18
|
-
};
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { StoryObj } from "@storybook/react";
|
|
2
|
-
declare const meta: {
|
|
3
|
-
argTypes: {
|
|
4
|
-
Summaries: {
|
|
5
|
-
table: {
|
|
6
|
-
disable: true;
|
|
7
|
-
};
|
|
8
|
-
};
|
|
9
|
-
title: {
|
|
10
|
-
table: {
|
|
11
|
-
disable: true;
|
|
12
|
-
};
|
|
13
|
-
};
|
|
14
|
-
};
|
|
15
|
-
component: ({ SideBarButton, Summaries, title, }: import("./hero").HeroProps) => JSX.Element;
|
|
16
|
-
parameters: {
|
|
17
|
-
layout: string;
|
|
18
|
-
};
|
|
19
|
-
title: string;
|
|
20
|
-
};
|
|
21
|
-
export default meta;
|
|
22
|
-
type Story = StoryObj<typeof meta>;
|
|
23
|
-
export declare const HeroStory: Story;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Summaries } from "./components/Summaries/summaries";
|
|
3
|
-
import { SummariesStory } from "./components/Summaries/summaries.stories";
|
|
4
|
-
import { Hero } from "./hero";
|
|
5
|
-
const meta = {
|
|
6
|
-
argTypes: {
|
|
7
|
-
Summaries: { table: { disable: true } },
|
|
8
|
-
title: { table: { disable: true } },
|
|
9
|
-
},
|
|
10
|
-
component: Hero,
|
|
11
|
-
parameters: {
|
|
12
|
-
layout: "fullscreen",
|
|
13
|
-
},
|
|
14
|
-
title: "Components/Hero/ExploreView",
|
|
15
|
-
};
|
|
16
|
-
export default meta;
|
|
17
|
-
export const HeroStory = {
|
|
18
|
-
args: {
|
|
19
|
-
Summaries: React.createElement(Summaries, { ...SummariesStory.args }),
|
|
20
|
-
title: "Data Explorer",
|
|
21
|
-
},
|
|
22
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { TooltipProps as MTooltipProps } from "@mui/material";
|
|
2
|
-
export interface TooltipProps extends MTooltipProps {
|
|
3
|
-
className?: string;
|
|
4
|
-
}
|
|
5
|
-
/**
|
|
6
|
-
* @deprecated - use Tooltip from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/NTagCell/components/NTag/components/Tooltip/tooltip"
|
|
7
|
-
*/
|
|
8
|
-
export declare const Tooltip: ({ children, className, title, ...props }: TooltipProps) => JSX.Element;
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import { Tooltip as MTooltip, } from "@mui/material";
|
|
2
|
-
import { detectOverflow } from "@popperjs/core";
|
|
3
|
-
import React, { useMemo, useState } from "react";
|
|
4
|
-
import { TooltipContent } from "./tooltip.styles";
|
|
5
|
-
const DEFAULT_FLIP_MODIFIER = {
|
|
6
|
-
enabled: true,
|
|
7
|
-
name: "flip",
|
|
8
|
-
options: {
|
|
9
|
-
fallbackPlacements: ["bottom", "right", "left"],
|
|
10
|
-
},
|
|
11
|
-
};
|
|
12
|
-
const DEFAULT_PREVENT_OVERFLOW_MODIFIER = {
|
|
13
|
-
enabled: true,
|
|
14
|
-
name: "preventOverflow",
|
|
15
|
-
options: {
|
|
16
|
-
padding: 16,
|
|
17
|
-
},
|
|
18
|
-
};
|
|
19
|
-
/**
|
|
20
|
-
* @deprecated - use Tooltip from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/NTagCell/components/NTag/components/Tooltip/tooltip"
|
|
21
|
-
*/
|
|
22
|
-
export const Tooltip = ({ children, className, title, ...props /* Spread props to allow for Mui Tooltip specific prop overrides. */ }) => {
|
|
23
|
-
const [maxHeight, setMaxHeight] = useState();
|
|
24
|
-
const modifiers = useMemo(() => [
|
|
25
|
-
{
|
|
26
|
-
enabled: true,
|
|
27
|
-
fn: ({ state }) => setMaxHeight(calculateMaxHeight(state)),
|
|
28
|
-
name: "maxHeight",
|
|
29
|
-
phase: "main",
|
|
30
|
-
requiresIfExists: ["offset"],
|
|
31
|
-
},
|
|
32
|
-
DEFAULT_FLIP_MODIFIER,
|
|
33
|
-
DEFAULT_PREVENT_OVERFLOW_MODIFIER,
|
|
34
|
-
], []);
|
|
35
|
-
return (React.createElement(MTooltip, { arrow: true, className: className, onClose: () => setMaxHeight(undefined), slotProps: {
|
|
36
|
-
popper: { modifiers },
|
|
37
|
-
tooltip: { style: { display: "flex", maxHeight, padding: 0 } },
|
|
38
|
-
}, title: React.createElement(TooltipContent, null, title), ...props }, children));
|
|
39
|
-
};
|
|
40
|
-
/**
|
|
41
|
-
* Calculate the max height of the tooltip based on the current popper modifier state.
|
|
42
|
-
* @param state - Popper modifier state.
|
|
43
|
-
* @returns tooltip maximum height.
|
|
44
|
-
*/
|
|
45
|
-
function calculateMaxHeight(state) {
|
|
46
|
-
const overflow = detectOverflow(state);
|
|
47
|
-
const { placement } = state;
|
|
48
|
-
if (placement === "left" || placement === "right") {
|
|
49
|
-
return window.innerHeight - 32;
|
|
50
|
-
}
|
|
51
|
-
if (placement === "top") {
|
|
52
|
-
return state.rects.popper.height - overflow.top - 24;
|
|
53
|
-
}
|
|
54
|
-
if (placement === "bottom") {
|
|
55
|
-
return state.rects.popper.height - overflow.bottom - 24;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { ReactElement } from "react";
|
|
2
|
-
export interface NTagProps {
|
|
3
|
-
className?: string;
|
|
4
|
-
Tag: ReactElement;
|
|
5
|
-
TooltipTitle: ReactElement;
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* @deprecated - use NTag from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/NTagCell/components/NTag/nTag"
|
|
9
|
-
*/
|
|
10
|
-
export declare const NTag: ({ className, Tag, TooltipTitle, ...props }: NTagProps) => JSX.Element;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Tooltip } from "./components/Tooltip/tooltip";
|
|
3
|
-
/**
|
|
4
|
-
* @deprecated - use NTag from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/NTagCell/components/NTag/nTag"
|
|
5
|
-
*/
|
|
6
|
-
export const NTag = ({ className, Tag, TooltipTitle, ...props /* Spread props to allow for Mui Tooltip specific prop overrides. */ }) => {
|
|
7
|
-
return (React.createElement(Tooltip, { className: className, title: TooltipTitle, ...props }, Tag));
|
|
8
|
-
};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { TypographyProps } from "../../../common/Typography/common/entities";
|
|
2
|
-
export type MetadataValue = string;
|
|
3
|
-
export interface NTagCellProps {
|
|
4
|
-
label: string;
|
|
5
|
-
TypographyProps?: TypographyProps;
|
|
6
|
-
values: MetadataValue[];
|
|
7
|
-
}
|
|
8
|
-
/**
|
|
9
|
-
* @deprecated - use NTagCell from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/NTagCell/nTagCell"
|
|
10
|
-
*/
|
|
11
|
-
export declare const NTagCell: ({ label, TypographyProps, values, }: NTagCellProps) => JSX.Element;
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { Chip as MChip, Typography, } from "@mui/material";
|
|
2
|
-
import React, { forwardRef } from "react";
|
|
3
|
-
import { TEXT_BODY_SMALL_400 } from "../../../../theme/common/typography";
|
|
4
|
-
import { NTag } from "../NTag/nTag";
|
|
5
|
-
// Template constants
|
|
6
|
-
const MAX_DISPLAYABLE_VALUES = 1;
|
|
7
|
-
/**
|
|
8
|
-
* String-concatenates the specified list of metadata values to a string value, joined by a comma ",".
|
|
9
|
-
* @param metadataValues - List of metadata values.
|
|
10
|
-
* @returns the metadata values in a string, each value joined by a comma.
|
|
11
|
-
*/
|
|
12
|
-
function stringifyMetadataValues(metadataValues) {
|
|
13
|
-
return metadataValues.join(", ");
|
|
14
|
-
}
|
|
15
|
-
/**
|
|
16
|
-
* Renders tag for NTag component.
|
|
17
|
-
* Tooltip children require forward ref.
|
|
18
|
-
*/
|
|
19
|
-
const Tag = forwardRef(function Tag(props, ref) {
|
|
20
|
-
return React.createElement(MChip, { ref: ref, ...props });
|
|
21
|
-
});
|
|
22
|
-
/**
|
|
23
|
-
* @deprecated - use NTagCell from "@databiosphere/findable-ui/lib/components/Table/components/TableCell/components/NTagCell/nTagCell"
|
|
24
|
-
*/
|
|
25
|
-
export const NTagCell = ({ label, TypographyProps, values, }) => {
|
|
26
|
-
const metadataCount = values.length;
|
|
27
|
-
const showNTag = metadataCount > MAX_DISPLAYABLE_VALUES;
|
|
28
|
-
return (React.createElement(React.Fragment, null, showNTag ? (React.createElement(NTag, { Tag: React.createElement(Tag, { label: `${metadataCount} ${label}`, variant: "ntag" }), TooltipTitle: React.createElement(Typography, { display: "block", variant: TEXT_BODY_SMALL_400 }, stringifyMetadataValues(values)) })) : (values.map((value, v) => (React.createElement(Typography, { key: `${value}${v}`, variant: "inherit", ...TypographyProps }, value))))));
|
|
29
|
-
};
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { ComponentMeta } from "@storybook/react";
|
|
2
|
-
import { NTagCell } from "./nTagCell";
|
|
3
|
-
declare const _default: ComponentMeta<typeof NTagCell>;
|
|
4
|
-
export default _default;
|
|
5
|
-
export declare const NTagCellStory: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./nTagCell").NTagCellProps>;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { NTagCell } from "./nTagCell";
|
|
3
|
-
export default {
|
|
4
|
-
argTypes: {
|
|
5
|
-
label: { control: "text" },
|
|
6
|
-
values: { control: "array" },
|
|
7
|
-
},
|
|
8
|
-
component: NTagCell,
|
|
9
|
-
title: "Components/Table/Cell/NTagCell",
|
|
10
|
-
};
|
|
11
|
-
const NTagCellTemplate = (args) => (React.createElement(NTagCell, { ...args }));
|
|
12
|
-
export const NTagCellStory = NTagCellTemplate.bind({});
|
|
13
|
-
NTagCellStory.args = {
|
|
14
|
-
label: "species",
|
|
15
|
-
values: ["Homo sapiens", "Mus musculus"],
|
|
16
|
-
};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { Typography } from "@mui/material";
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { TEXT_BODY_400 } from "../../../../theme/common/typography";
|
|
4
|
-
import { Link } from "../../../Links/components/Link/link";
|
|
5
|
-
import { TitleCell as Cell } from "./titleCell.styles";
|
|
6
|
-
export const TitleCell = ({ title, ...props }) => {
|
|
7
|
-
return (React.createElement(Cell, { gridSx: { gap: 1 } },
|
|
8
|
-
typeof title === "string" ? (React.createElement(Typography, { variant: TEXT_BODY_400 }, title)) : (title),
|
|
9
|
-
React.createElement(Link, { ...props })));
|
|
10
|
-
};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { Summaries } from "./components/Hero/components/Summaries/summaries";
|
|
3
|
-
import { SummariesStory } from "./components/Hero/components/Summaries/summaries.stories";
|
|
4
|
-
import { Index } from "./index";
|
|
5
|
-
export default {
|
|
6
|
-
argTypes: {
|
|
7
|
-
Summaries: { table: { disable: true } },
|
|
8
|
-
Tabs: { table: { disable: true } },
|
|
9
|
-
list: { table: { disable: true } },
|
|
10
|
-
title: { table: { disable: true } },
|
|
11
|
-
},
|
|
12
|
-
component: Index,
|
|
13
|
-
parameters: {
|
|
14
|
-
layout: "fullscreen",
|
|
15
|
-
},
|
|
16
|
-
title: "Views/ExploreView",
|
|
17
|
-
};
|
|
18
|
-
export const IndexStory = {
|
|
19
|
-
args: {
|
|
20
|
-
Summaries: React.createElement(Summaries, { ...SummariesStory.args }),
|
|
21
|
-
Tabs: undefined,
|
|
22
|
-
chart: undefined,
|
|
23
|
-
list: undefined,
|
|
24
|
-
title: "Explore Data",
|
|
25
|
-
},
|
|
26
|
-
};
|
package/lib/components/Layout/components/BackPage/components/BackPageHero/backPageHero.stories.d.ts
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { Meta, StoryObj } from "@storybook/react";
|
|
2
|
-
import { BackPageHero } from "./backPageHero";
|
|
3
|
-
declare const _default: Meta<typeof BackPageHero>;
|
|
4
|
-
export default _default;
|
|
5
|
-
type Story = StoryObj<typeof BackPageHero>;
|
|
6
|
-
export declare const BackPageHeroStory: Story;
|
package/lib/components/Layout/components/BackPage/components/BackPageHero/backPageHero.stories.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { BackPageHero } from "./backPageHero";
|
|
2
|
-
export default {
|
|
3
|
-
component: BackPageHero,
|
|
4
|
-
title: "Components/Hero",
|
|
5
|
-
};
|
|
6
|
-
export const BackPageHeroStory = {
|
|
7
|
-
args: {
|
|
8
|
-
title: "A Single-Cell Transcriptomic Map of the Human and Mouse Pancreas Reveals Inter- and Intra-cell Population Structure",
|
|
9
|
-
},
|
|
10
|
-
};
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { Meta } from "@storybook/react";
|
|
2
|
-
import { AuthenticationMenu } from "./authenticationMenu";
|
|
3
|
-
declare const _default: Meta<typeof AuthenticationMenu>;
|
|
4
|
-
export default _default;
|
|
5
|
-
export declare const AuthenticationMenuStory: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./authenticationMenu").AuthenticationMenuProps>;
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { AuthenticationMenu } from "./authenticationMenu";
|
|
3
|
-
export default {
|
|
4
|
-
argTypes: {
|
|
5
|
-
onLogout: {
|
|
6
|
-
description: "Callback to be called when 'Logout' button is clicked",
|
|
7
|
-
},
|
|
8
|
-
userProfile: {
|
|
9
|
-
description: "User profile with name and avatar",
|
|
10
|
-
},
|
|
11
|
-
},
|
|
12
|
-
component: AuthenticationMenu,
|
|
13
|
-
title: "Components/Navigation/AuthenticationMenu",
|
|
14
|
-
};
|
|
15
|
-
const AuthenticationMenuTemplate = (args) => React.createElement(AuthenticationMenu, { ...args });
|
|
16
|
-
export const AuthenticationMenuStory = AuthenticationMenuTemplate.bind({});
|
|
17
|
-
AuthenticationMenuStory.args = {
|
|
18
|
-
userProfile: {
|
|
19
|
-
email: "john@smith.com",
|
|
20
|
-
email_verified: true,
|
|
21
|
-
family_name: "Smith",
|
|
22
|
-
given_name: "John",
|
|
23
|
-
hd: "",
|
|
24
|
-
locale: "",
|
|
25
|
-
name: "john_smith",
|
|
26
|
-
picture: "https://i.pravatar.cc/200",
|
|
27
|
-
sub: "",
|
|
28
|
-
},
|
|
29
|
-
};
|