@databiosphere/findable-ui 13.0.1 → 14.0.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/CHANGELOG.md +24 -0
- package/lib/common/analytics/entities.d.ts +10 -7
- package/lib/common/analytics/entities.js +2 -3
- package/lib/components/Export/common/tracking.d.ts +12 -3
- package/lib/components/Export/common/tracking.js +23 -12
- package/lib/components/Export/components/DownloadCurlCommand/downloadCurlCommand.d.ts +1 -1
- package/lib/components/Export/components/DownloadCurlCommand/downloadCurlCommand.js +2 -16
- package/lib/components/Export/components/ExportToTerra/components/TerraSetUpForm/components/NIHAccountExpiryWarning/nihAccountExpiryWarning.js +6 -3
- package/lib/components/Export/components/ExportToTerra/exportToTerra.js +9 -1
- package/lib/components/Export/components/ManifestDownload/manifestDownload.js +7 -1
- package/lib/components/Layout/components/Header/components/Content/components/Logo/logo.d.ts +2 -2
- package/lib/components/Layout/components/Header/components/Content/components/Logo/logo.js +1 -1
- package/lib/components/Layout/components/Header/components/Content/components/Logo/logo.styles.js +0 -1
- package/lib/components/Links/components/Link/link.d.ts +2 -3
- package/lib/components/Links/components/Link/link.js +1 -2
- package/lib/components/common/Alert/alert.d.ts +4 -12
- package/lib/components/common/Alert/alert.js +5 -7
- package/lib/components/common/Alert/alert.styles.d.ts +1 -11
- package/lib/components/common/Alert/alert.styles.js +18 -24
- package/lib/components/common/Alert/constants.d.ts +2 -0
- package/lib/components/common/Alert/constants.js +27 -0
- package/lib/components/common/Alert/hooks/useTransition/types.d.ts +5 -0
- package/lib/components/common/Alert/hooks/useTransition/types.js +1 -0
- package/lib/components/common/Alert/hooks/useTransition/useTransition.d.ts +7 -0
- package/lib/components/common/Alert/hooks/useTransition/useTransition.js +20 -0
- package/lib/components/common/Banner/banner.d.ts +4 -7
- package/lib/components/common/Banner/banner.js +4 -3
- package/lib/components/common/Banner/banner.styles.d.ts +3 -0
- package/lib/components/common/Banner/banner.styles.js +28 -0
- package/lib/components/common/Banner/components/CookieBanner/constants.d.ts +2 -0
- package/lib/components/common/Banner/components/CookieBanner/constants.js +7 -0
- package/lib/components/common/Banner/components/CookieBanner/cookieBanner.d.ts +3 -3
- package/lib/components/common/Banner/components/CookieBanner/cookieBanner.js +17 -31
- package/lib/components/common/Banner/components/CookieBanner/cookieBanner.styles.d.ts +1 -1
- package/lib/components/common/Banner/components/CookieBanner/cookieBanner.styles.js +2 -16
- package/lib/components/common/Banner/components/SessionTimeout/sessionTimeout.d.ts +3 -7
- package/lib/components/common/Banner/components/SessionTimeout/sessionTimeout.js +6 -4
- package/lib/components/common/Banner/components/SystemIndexing/systemIndexing.d.ts +3 -8
- package/lib/components/common/Banner/components/SystemIndexing/systemIndexing.js +6 -8
- package/lib/components/common/Banner/components/SystemStatus/systemStatus.d.ts +3 -8
- package/lib/components/common/Banner/components/SystemStatus/systemStatus.js +6 -8
- package/lib/components/common/Banner/constants.d.ts +2 -0
- package/lib/components/common/Banner/constants.js +9 -0
- package/lib/components/common/Breadcrumbs/breadcrumbs.d.ts +2 -2
- package/lib/components/common/Breadcrumbs/breadcrumbs.js +3 -4
- package/lib/components/common/Paper/paper.styles.js +18 -12
- package/lib/components/types.d.ts +10 -0
- package/lib/components/types.js +1 -0
- package/lib/hooks/useLocalStorage/useLocalStorage.d.ts +1 -1
- package/lib/hooks/useLocalStorage/useLocalStorage.js +1 -1
- package/lib/styles/common/constants/size.d.ts +5 -0
- package/lib/styles/common/constants/size.js +6 -0
- package/lib/styles/common/mui/alert.d.ts +4 -0
- package/lib/styles/common/mui/alert.js +20 -0
- package/lib/styles/common/mui/icon.d.ts +2 -0
- package/lib/styles/common/mui/icon.js +6 -0
- package/lib/theme/common/components.d.ts +0 -12
- package/lib/theme/common/components.js +17 -157
- package/lib/theme/components/index.d.ts +2 -0
- package/lib/theme/components/index.js +2 -0
- package/lib/theme/components/muiAlert.d.ts +2 -0
- package/lib/theme/components/muiAlert.js +121 -0
- package/lib/theme/components/muiAlertTitle.d.ts +2 -0
- package/lib/theme/components/muiAlertTitle.js +12 -0
- package/lib/theme/theme.js +3 -2
- package/package.json +4 -4
- package/src/common/analytics/entities.ts +9 -6
- package/src/common/analytics/readme-analytics.md +9 -7
- package/src/components/Export/common/tracking.ts +26 -15
- package/src/components/Export/components/DownloadCurlCommand/downloadCurlCommand.tsx +2 -30
- package/src/components/Export/components/ExportToTerra/components/TerraSetUpForm/components/NIHAccountExpiryWarning/nihAccountExpiryWarning.tsx +16 -18
- package/src/components/Export/components/ExportToTerra/exportToTerra.tsx +11 -1
- package/src/components/Export/components/ManifestDownload/manifestDownload.tsx +9 -1
- package/src/components/Layout/components/Header/components/Content/components/Logo/logo.styles.ts +0 -1
- package/src/components/Layout/components/Header/components/Content/components/Logo/logo.tsx +3 -2
- package/src/components/Links/components/Link/link.tsx +17 -16
- package/src/components/common/Alert/alert.styles.ts +22 -25
- package/src/components/common/Alert/alert.tsx +14 -35
- package/src/components/common/Alert/constants.ts +29 -0
- package/src/components/common/Alert/hooks/useTransition/types.ts +5 -0
- package/src/components/common/Alert/hooks/useTransition/useTransition.ts +25 -0
- package/src/components/common/Banner/banner.styles.ts +29 -0
- package/src/components/common/Banner/banner.tsx +11 -18
- package/src/components/common/Banner/components/CookieBanner/constants.ts +9 -0
- package/src/components/common/Banner/components/CookieBanner/cookieBanner.styles.ts +2 -16
- package/src/components/common/Banner/components/CookieBanner/cookieBanner.tsx +36 -64
- package/src/components/common/Banner/components/SessionTimeout/sessionTimeout.tsx +12 -17
- package/src/components/common/Banner/components/SystemIndexing/systemIndexing.tsx +11 -22
- package/src/components/common/Banner/components/SystemStatus/systemStatus.tsx +11 -22
- package/src/components/common/Banner/constants.ts +11 -0
- package/src/components/common/Breadcrumbs/breadcrumbs.tsx +6 -10
- package/src/components/common/Paper/paper.styles.ts +18 -12
- package/src/components/types.ts +13 -0
- package/src/hooks/useLocalStorage/useLocalStorage.ts +2 -2
- package/src/styles/common/constants/size.ts +5 -0
- package/src/styles/common/mui/alert.ts +24 -0
- package/src/styles/common/mui/icon.ts +8 -0
- package/src/theme/common/components.ts +16 -159
- package/src/theme/components/index.ts +2 -0
- package/src/theme/components/muiAlert.ts +123 -0
- package/src/theme/components/muiAlertTitle.ts +14 -0
- package/src/theme/theme.ts +3 -2
- package/types/data-explorer-ui.d.ts +6 -5
- 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/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/src/components/Index/components/TitleCell/titleCell.styles.ts +0 -7
- package/src/components/Index/components/TitleCell/titleCell.tsx +0 -22
- package/src/components/common/Alert/alert.stories.tsx +0 -41
- package/src/components/common/Alert/components/AlertText/alertText.styles.ts +0 -20
- package/src/components/common/Banner/components/BannerPrimary/bannerPrimary.styles.ts +0 -20
- package/src/components/common/Banner/components/BannerPrimary/bannerPrimary.tsx +0 -27
- package/src/components/common/Banner/components/DismissibleBanner/dismissibleBanner.tsx +0 -44
- package/src/components/common/Banner/components/SessionTimeout/sessionTimeout.styles.ts +0 -22
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import styled from "@emotion/styled";
|
|
2
|
-
|
|
3
|
-
export const AlertText = styled.div`
|
|
4
|
-
ul {
|
|
5
|
-
padding-left: 24px;
|
|
6
|
-
margin: 8px 0;
|
|
7
|
-
|
|
8
|
-
li {
|
|
9
|
-
margin: 4px 0;
|
|
10
|
-
|
|
11
|
-
&:last-child {
|
|
12
|
-
margin-bottom: 0;
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
*:last-child {
|
|
18
|
-
margin-bottom: 0;
|
|
19
|
-
}
|
|
20
|
-
`;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import styled from "@emotion/styled";
|
|
2
|
-
import { Alert as MAlert } from "@mui/material";
|
|
3
|
-
import { primaryMain, white } from "../../../../../styles/common/mixins/colors";
|
|
4
|
-
import { textBodySmall400 } from "../../../../../styles/common/mixins/fonts";
|
|
5
|
-
|
|
6
|
-
export const Alert = styled(MAlert)`
|
|
7
|
-
border-radius: 0;
|
|
8
|
-
justify-content: center;
|
|
9
|
-
padding: 8px;
|
|
10
|
-
|
|
11
|
-
&.MuiAlert-standardPrimary {
|
|
12
|
-
background-color: ${primaryMain};
|
|
13
|
-
color: ${white};
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.MuiAlert-message {
|
|
17
|
-
${textBodySmall400};
|
|
18
|
-
text-align: center;
|
|
19
|
-
}
|
|
20
|
-
`;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { AlertProps as MAlertProps } from "@mui/material";
|
|
2
|
-
import React, { ReactNode } from "react";
|
|
3
|
-
import { Alert } from "./bannerPrimary.styles";
|
|
4
|
-
|
|
5
|
-
export interface BannerPrimaryProps extends MAlertProps {
|
|
6
|
-
children: ReactNode;
|
|
7
|
-
className?: string;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export const BannerPrimary = ({
|
|
11
|
-
children,
|
|
12
|
-
className,
|
|
13
|
-
...props /* Spread props to allow for Mui AlertProps specific prop overrides. */
|
|
14
|
-
}: BannerPrimaryProps): JSX.Element => {
|
|
15
|
-
return (
|
|
16
|
-
<Alert
|
|
17
|
-
className={className}
|
|
18
|
-
color="primary"
|
|
19
|
-
elevation={0}
|
|
20
|
-
icon={false}
|
|
21
|
-
variant="standard"
|
|
22
|
-
{...props}
|
|
23
|
-
>
|
|
24
|
-
{children}
|
|
25
|
-
</Alert>
|
|
26
|
-
);
|
|
27
|
-
};
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
Fade,
|
|
3
|
-
Alert as MAlert,
|
|
4
|
-
AlertProps as MAlertProps,
|
|
5
|
-
} from "@mui/material";
|
|
6
|
-
import React, { ElementType, ReactNode, useEffect, useState } from "react";
|
|
7
|
-
|
|
8
|
-
export interface CookieBannerProps extends MAlertProps {
|
|
9
|
-
Alert?: ElementType;
|
|
10
|
-
children: ReactNode;
|
|
11
|
-
className?: string;
|
|
12
|
-
onDismiss?: () => void;
|
|
13
|
-
open: boolean;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export const DismissibleBanner = ({
|
|
17
|
-
Alert = MAlert /* Requires forwardRef to be used as a child of Fade. */,
|
|
18
|
-
className,
|
|
19
|
-
children,
|
|
20
|
-
onDismiss,
|
|
21
|
-
open,
|
|
22
|
-
...props /* Spread props to allow for Mui AlertProps specific prop overrides. */
|
|
23
|
-
}: CookieBannerProps): JSX.Element => {
|
|
24
|
-
const [isIn, setIsIn] = useState<boolean>(false);
|
|
25
|
-
|
|
26
|
-
// Callback fired when the component requests to be closed.
|
|
27
|
-
const onClose = (): void => {
|
|
28
|
-
onDismiss?.();
|
|
29
|
-
setIsIn(false);
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
// Sets the open state.
|
|
33
|
-
useEffect(() => {
|
|
34
|
-
setIsIn(open);
|
|
35
|
-
}, [open]);
|
|
36
|
-
|
|
37
|
-
return (
|
|
38
|
-
<Fade in={isIn} unmountOnExit>
|
|
39
|
-
<Alert className={className} onClose={onClose} {...props}>
|
|
40
|
-
{children}
|
|
41
|
-
</Alert>
|
|
42
|
-
</Fade>
|
|
43
|
-
);
|
|
44
|
-
};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import styled from "@emotion/styled";
|
|
2
|
-
import { mediaDesktopUp } from "../../../../../styles/common/mixins/breakpoints";
|
|
3
|
-
import { BannerPrimary } from "../BannerPrimary/bannerPrimary";
|
|
4
|
-
|
|
5
|
-
export const Banner = styled(BannerPrimary)`
|
|
6
|
-
gap: 12px;
|
|
7
|
-
padding: 8px 12px;
|
|
8
|
-
|
|
9
|
-
${mediaDesktopUp} {
|
|
10
|
-
padding: 8px 16px;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.MuiAlert-message {
|
|
14
|
-
align-self: center;
|
|
15
|
-
flex: 1;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.MuiAlert-action {
|
|
19
|
-
margin: -8px;
|
|
20
|
-
padding: 0;
|
|
21
|
-
}
|
|
22
|
-
`;
|