@yourdash/uikit 1.0.1 → 1.0.3
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/components/box/box.module.scss +1 -1
- package/components/box/box.tsx +3 -3
- package/components/button/button.module.scss +3 -3
- package/components/button/button.tsx +2 -1
- package/components/buttonLink/buttonLink.module.scss +5 -1
- package/components/buttonLink/buttonLink.tsx +13 -12
- package/components/buttonWithIcon/buttonWithIcon.module.scss +56 -0
- package/components/buttonWithIcon/buttonWithIcon.tsx +36 -0
- package/components/card/card.module.scss +6 -6
- package/components/card/card.tsx +23 -20
- package/components/container/container.module.scss +20 -0
- package/components/container/container.tsx +22 -0
- package/components/contextMenu/contextMenu.tsx +1 -1
- package/components/contextMenu/contextMenuRoot.module.scss +1 -1
- package/components/contextMenu/contextMenuRoot.tsx +83 -83
- package/components/flex/flex.module.scss +31 -19
- package/components/flex/flex.tsx +23 -2
- package/components/heading/heading.module.scss +1 -1
- package/components/heading/heading.tsx +1 -1
- package/components/icon/icon.tsx +1 -1
- package/components/iconButton/iconButton.module.scss +1 -1
- package/components/iconButton/iconButton.tsx +3 -3
- package/components/image/image.module.scss +72 -1
- package/components/image/image.tsx +65 -10
- package/components/link/link.module.scss +1 -1
- package/components/link/link.tsx +1 -1
- package/components/progressBar/progressBar.module.scss +25 -0
- package/components/progressBar/progressBar.tsx +21 -0
- package/components/redirect/redirect.tsx +1 -1
- package/components/separator/separator.module.scss +9 -4
- package/components/separator/separator.tsx +3 -3
- package/components/spinner/spinner.module.scss +1 -6
- package/components/spinner/spinner.tsx +1 -1
- package/components/subtext/subtext.module.scss +1 -1
- package/components/subtext/subtext.tsx +1 -1
- package/components/tag/tag.module.scss +13 -0
- package/components/tag/tag.tsx +21 -0
- package/components/text/text.module.scss +1 -1
- package/components/text/text.tsx +1 -1
- package/components/textButton/textButton.module.scss +1 -1
- package/components/textButton/textButton.tsx +1 -1
- package/components/textInput/textInput.module.scss +1 -1
- package/components/textInput/textInput.tsx +40 -10
- package/components/toast/toast.module.scss +71 -31
- package/components/toast/toast.ts +12 -0
- package/components/toast/toastAction.ts +12 -0
- package/components/toast/toastContext.ts +5 -3
- package/components/toast/toasts.tsx +99 -0
- package/core/decrementLevel.tsx +13 -13
- package/core/incrementLevel.tsx +1 -1
- package/core/level.tsx +1 -1
- package/core/remToPx.ts +8 -0
- package/core/root.tsx +26 -32
- package/core/toast.ts +18 -17
- package/imports.d.ts +81 -0
- package/package.json +9 -40
- package/theme/defaultTheme.module.scss +16 -4
- package/theme/themeValues.scss +8 -5
- package/tsconfig.json +19 -9
- package/utilityComponent/hasBeenShown/hasBeenShown.tsx +47 -0
- package/utilityComponent/onInView/onInView.tsx +83 -0
- package/views/carousel/carousel.module.scss +77 -0
- package/views/carousel/carousel.tsx +138 -0
- package/views/header/header.module.scss +16 -0
- package/views/header/header.tsx +28 -0
- package/views/infiniteScroll/infiniteScroll.module.scss +26 -0
- package/views/infiniteScroll/infiniteScroll.tsx +90 -0
- package/views/navBar/components/navImage/navImage.module.scss +7 -0
- package/views/navBar/components/navImage/navImage.tsx +15 -0
- package/views/navBar/components/navTitle/navTitle.tsx +13 -0
- package/views/navBar/navBar.module.scss +22 -0
- package/views/navBar/navBar.tsx +37 -0
- package/views/onBoarding/onBoarding.module.scss +84 -0
- package/views/onBoarding/onBoarding.tsx +138 -0
- package/views/panAndZoom/panAndZoom.tsx +121 -114
- package/views/sidebar/Sidebar.module.scss +49 -0
- package/views/sidebar/Sidebar.tsx +30 -0
- package/views/sidebar/SidebarContainer.module.scss +22 -0
- package/views/sidebar/SidebarContainer.tsx +38 -0
- package/views/sidebar/SidebarContext.tsx +15 -0
- package/views/sidebar/SidebarToggleButton.tsx +25 -0
- package/components/toast/toast.tsx +0 -65
@@ -1,114 +1,121 @@
|
|
1
|
-
/*
|
2
|
-
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
-
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
-
*/
|
5
|
-
|
6
|
-
import React, { FC, useRef, useState } from "react";
|
7
|
-
|
8
|
-
const PanAndZoom: FC<{ children: React.ReactNode; minZoom?: number; maxZoom?: number }> = ({
|
9
|
-
children,
|
10
|
-
minZoom,
|
11
|
-
maxZoom,
|
12
|
-
|
13
|
-
|
14
|
-
const
|
15
|
-
const [
|
16
|
-
const [
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
}
|
24
|
-
|
25
|
-
const
|
26
|
-
event.stopPropagation();
|
27
|
-
const
|
28
|
-
const
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
event.
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
}}
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
{
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
1
|
+
/*
|
2
|
+
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
+
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
+
*/
|
5
|
+
|
6
|
+
import React, { FC, useEffect, useRef, useState } from "react";
|
7
|
+
|
8
|
+
const PanAndZoom: FC<{ children: React.ReactNode; minZoom?: number; maxZoom?: number; onScaleChange?: (scale: number) => void }> = ({
|
9
|
+
children,
|
10
|
+
minZoom,
|
11
|
+
maxZoom,
|
12
|
+
onScaleChange,
|
13
|
+
}) => {
|
14
|
+
const containerRef = useRef<HTMLDivElement>(null);
|
15
|
+
const [translateX, setTranslateX] = useState(0);
|
16
|
+
const [translateY, setTranslateY] = useState(0);
|
17
|
+
const [scale, setScale] = useState(1);
|
18
|
+
|
19
|
+
if (onScaleChange) {
|
20
|
+
useEffect(() => {
|
21
|
+
onScaleChange(scale);
|
22
|
+
}, [scale]);
|
23
|
+
}
|
24
|
+
|
25
|
+
const handleWheel = (event: WheelEvent) => {
|
26
|
+
event.stopPropagation();
|
27
|
+
const delta = event.deltaY;
|
28
|
+
const newScale = scale + delta / 1000;
|
29
|
+
setScale(Math.min(Math.max(newScale, minZoom ?? 0.1), maxZoom ?? 10));
|
30
|
+
};
|
31
|
+
|
32
|
+
const handleMouseDown = (event: React.MouseEvent<HTMLDivElement>) => {
|
33
|
+
event.stopPropagation();
|
34
|
+
const startX = event.clientX;
|
35
|
+
const startY = event.clientY;
|
36
|
+
const startTranslateX = translateX;
|
37
|
+
const startTranslateY = translateY;
|
38
|
+
|
39
|
+
// eslint-disable-next-line @typescript-eslint/no-shadow
|
40
|
+
const handleMouseMove = (event: MouseEvent) => {
|
41
|
+
event.stopPropagation();
|
42
|
+
const deltaX = event.clientX - startX;
|
43
|
+
const deltaY = event.clientY - startY;
|
44
|
+
setTranslateX(startTranslateX + deltaX);
|
45
|
+
setTranslateY(startTranslateY + deltaY);
|
46
|
+
};
|
47
|
+
|
48
|
+
const handleMouseUp = () => {
|
49
|
+
event.stopPropagation();
|
50
|
+
document.removeEventListener("mousemove", handleMouseMove);
|
51
|
+
document.removeEventListener("mouseup", handleMouseUp);
|
52
|
+
};
|
53
|
+
|
54
|
+
document.addEventListener("mousemove", handleMouseMove);
|
55
|
+
document.addEventListener("mouseup", handleMouseUp);
|
56
|
+
};
|
57
|
+
|
58
|
+
const handleTouchStart = (event: React.TouchEvent<HTMLDivElement>) => {
|
59
|
+
event.stopPropagation();
|
60
|
+
const startTouches = event.touches;
|
61
|
+
const startTranslateX = translateX;
|
62
|
+
const startTranslateY = translateY;
|
63
|
+
|
64
|
+
// eslint-disable-next-line @typescript-eslint/no-shadow
|
65
|
+
const handleTouchMove = (event: TouchEvent) => {
|
66
|
+
event.stopPropagation();
|
67
|
+
const currentTouches = event.touches;
|
68
|
+
const deltaX = currentTouches[0].clientX - startTouches[0].clientX;
|
69
|
+
const deltaY = currentTouches[0].clientY - startTouches[0].clientY;
|
70
|
+
setTranslateX(startTranslateX + deltaX);
|
71
|
+
setTranslateY(startTranslateY + deltaY);
|
72
|
+
};
|
73
|
+
|
74
|
+
const handleTouchEnd = () => {
|
75
|
+
event.stopPropagation();
|
76
|
+
document.removeEventListener("touchmove", handleTouchMove);
|
77
|
+
document.removeEventListener("touchend", handleTouchEnd);
|
78
|
+
};
|
79
|
+
|
80
|
+
document.addEventListener("touchmove", handleTouchMove);
|
81
|
+
document.addEventListener("touchend", handleTouchEnd);
|
82
|
+
};
|
83
|
+
|
84
|
+
return (
|
85
|
+
<div
|
86
|
+
ref={containerRef}
|
87
|
+
style={{
|
88
|
+
width: "100%",
|
89
|
+
height: "100%",
|
90
|
+
overflow: "hidden",
|
91
|
+
display: "flex",
|
92
|
+
alignItems: "center",
|
93
|
+
justifyContent: "center",
|
94
|
+
}}
|
95
|
+
onWheel={handleWheel as unknown as React.WheelEventHandler<HTMLDivElement>}
|
96
|
+
onMouseDown={handleMouseDown}
|
97
|
+
onTouchStart={handleTouchStart}
|
98
|
+
onDragStart={(event) => {
|
99
|
+
event.stopPropagation();
|
100
|
+
event.preventDefault();
|
101
|
+
}}
|
102
|
+
onContextMenu={(event) => {
|
103
|
+
event.preventDefault();
|
104
|
+
event.stopPropagation();
|
105
|
+
}}
|
106
|
+
>
|
107
|
+
<div
|
108
|
+
style={{
|
109
|
+
transform: `translate(${translateX}px, ${translateY}px) scale(${scale})`,
|
110
|
+
transformOrigin: "center center",
|
111
|
+
maxWidth: "max-content",
|
112
|
+
pointerEvents: "none",
|
113
|
+
}}
|
114
|
+
>
|
115
|
+
{children}
|
116
|
+
</div>
|
117
|
+
</div>
|
118
|
+
);
|
119
|
+
};
|
120
|
+
|
121
|
+
export default PanAndZoom;
|
@@ -0,0 +1,49 @@
|
|
1
|
+
/*!
|
2
|
+
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
+
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
+
*/
|
5
|
+
|
6
|
+
@use "@yourdash/uikit/theme/themeValues" as *;
|
7
|
+
|
8
|
+
.component {
|
9
|
+
height: 100%;
|
10
|
+
background: var(#{$theme+$background});
|
11
|
+
pointer-events: none;
|
12
|
+
opacity: 0;
|
13
|
+
border: var(#{$theme+$border});
|
14
|
+
border-top: 0;
|
15
|
+
border-bottom: 0;
|
16
|
+
border-left: 0;
|
17
|
+
flex-direction: column;
|
18
|
+
max-height: 100%;
|
19
|
+
max-width: 0;
|
20
|
+
transition: transform var(#{$theme+$transition+$transition}), max-height var(#{$theme+$transition+$transition});
|
21
|
+
transform: translateX(-100%);
|
22
|
+
visibility: hidden;
|
23
|
+
padding: 0;
|
24
|
+
|
25
|
+
@media (max-width: $sizeTablet) {
|
26
|
+
max-width: 100%;
|
27
|
+
max-height: 0;
|
28
|
+
height: max-content;
|
29
|
+
border-right: 0;
|
30
|
+
border-bottom: unset;
|
31
|
+
}
|
32
|
+
|
33
|
+
>*[type="button"] {
|
34
|
+
min-width: 100%;
|
35
|
+
}
|
36
|
+
}
|
37
|
+
|
38
|
+
.open {
|
39
|
+
pointer-events: all;
|
40
|
+
opacity: 1;
|
41
|
+
transform: translateX(0);
|
42
|
+
visibility: visible;
|
43
|
+
max-width: 32rem;
|
44
|
+
padding: var(#{$theme+$padding});
|
45
|
+
|
46
|
+
@media (max-width: $sizeTablet) {
|
47
|
+
height: max-content;
|
48
|
+
}
|
49
|
+
}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
+
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
+
*/
|
5
|
+
|
6
|
+
import clippy from "@yourdash/shared/web/helpers/clippy.ts";
|
7
|
+
import Flex from "../../components/flex/flex.tsx";
|
8
|
+
import IncrementLevel from "../../core/incrementLevel.tsx";
|
9
|
+
import { useLevel, useLevelClass } from "../../core/level.tsx";
|
10
|
+
import styles from "./Sidebar.module.scss";
|
11
|
+
import SidebarContext from "./SidebarContext.tsx";
|
12
|
+
import { FC, useContext } from "react";
|
13
|
+
|
14
|
+
const Sidebar: FC<{ children: React.ReactNode | React.ReactNode[] }> = ({ children }) => {
|
15
|
+
const sidebarContext = useContext(SidebarContext);
|
16
|
+
const level = useLevel();
|
17
|
+
|
18
|
+
return (
|
19
|
+
<IncrementLevel>
|
20
|
+
<Flex
|
21
|
+
direction={"column"}
|
22
|
+
className={clippy(styles.component, sidebarContext.isOpen && styles.open, useLevelClass(level + 1))}
|
23
|
+
>
|
24
|
+
{children}
|
25
|
+
</Flex>
|
26
|
+
</IncrementLevel>
|
27
|
+
);
|
28
|
+
};
|
29
|
+
|
30
|
+
export default Sidebar;
|
@@ -0,0 +1,22 @@
|
|
1
|
+
/*!
|
2
|
+
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
+
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
+
*/
|
5
|
+
|
6
|
+
@import '@yourdash/uikit/theme/themeValues';
|
7
|
+
|
8
|
+
.component {
|
9
|
+
display: flex;
|
10
|
+
flex-direction: row;
|
11
|
+
width: 100%;
|
12
|
+
height: 100%;
|
13
|
+
overflow: hidden;
|
14
|
+
|
15
|
+
&[dir=rtl] {
|
16
|
+
flex-direction: row-reverse;
|
17
|
+
}
|
18
|
+
|
19
|
+
@media (max-width: $sizeTablet) {
|
20
|
+
flex-direction: column;
|
21
|
+
}
|
22
|
+
}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
+
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
+
*/
|
5
|
+
|
6
|
+
import React, { FC, useState } from "react";
|
7
|
+
import SidebarContext from "./SidebarContext.tsx";
|
8
|
+
import styles from "./SidebarContainer.module.scss";
|
9
|
+
import clippy from "@yourdash/shared/web/helpers/clippy.ts";
|
10
|
+
|
11
|
+
const SidebarContainer: FC<{ children: React.ReactNode | React.ReactNode[]; showSidebarByDefault?: boolean; className?: string }> = ({
|
12
|
+
children,
|
13
|
+
showSidebarByDefault,
|
14
|
+
className,
|
15
|
+
}) => {
|
16
|
+
const [showSidebar, setShowSidebar] = useState<boolean>(showSidebarByDefault || true);
|
17
|
+
|
18
|
+
return (
|
19
|
+
<SidebarContext.Provider
|
20
|
+
value={{
|
21
|
+
closeSidebar: () => {
|
22
|
+
setShowSidebar(false);
|
23
|
+
},
|
24
|
+
toggleSidebar: () => {
|
25
|
+
setShowSidebar(!showSidebar);
|
26
|
+
},
|
27
|
+
openSidebar: () => {
|
28
|
+
setShowSidebar(true);
|
29
|
+
},
|
30
|
+
isOpen: showSidebar,
|
31
|
+
}}
|
32
|
+
>
|
33
|
+
<div className={clippy(styles.component, className)}>{children}</div>
|
34
|
+
</SidebarContext.Provider>
|
35
|
+
);
|
36
|
+
};
|
37
|
+
|
38
|
+
export default SidebarContainer;
|
@@ -0,0 +1,15 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
+
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
+
*/
|
5
|
+
|
6
|
+
import { createContext } from "react";
|
7
|
+
|
8
|
+
const SidebarContext = createContext({
|
9
|
+
openSidebar: () => {},
|
10
|
+
closeSidebar: () => {},
|
11
|
+
toggleSidebar: () => {},
|
12
|
+
isOpen: true,
|
13
|
+
});
|
14
|
+
|
15
|
+
export default SidebarContext;
|
@@ -0,0 +1,25 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
+
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
+
*/
|
5
|
+
|
6
|
+
import { FC, useContext } from "react";
|
7
|
+
import { UKIcon } from "../../components/icon/iconDictionary.ts";
|
8
|
+
import SidebarContext from "./SidebarContext.tsx";
|
9
|
+
import IconButton from "../../components/iconButton/iconButton.tsx";
|
10
|
+
|
11
|
+
const SidebarToggleButton: FC = () => {
|
12
|
+
const sidebarContext = useContext(SidebarContext);
|
13
|
+
|
14
|
+
return (
|
15
|
+
<IconButton
|
16
|
+
accessibleLabel={sidebarContext.isOpen ? "Collapse Sidebar" : "Expand Sidebar"}
|
17
|
+
icon={sidebarContext.isOpen ? UKIcon.SidebarCollapse : UKIcon.SidebarExpand}
|
18
|
+
onClick={() => {
|
19
|
+
sidebarContext.toggleSidebar();
|
20
|
+
}}
|
21
|
+
/>
|
22
|
+
);
|
23
|
+
};
|
24
|
+
|
25
|
+
export default SidebarToggleButton;
|
@@ -1,65 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
* Copyright ©2024 Ewsgit<https://github.com/ewsgit> and YourDash<https://github.com/yourdash> contributors.
|
3
|
-
* YourDash is licensed under the MIT License. (https://ewsgit.mit-license.org)
|
4
|
-
*/
|
5
|
-
|
6
|
-
import clippy from "@yourdash/shared/web/helpers/clippy.js";
|
7
|
-
import { FC, useState } from "react";
|
8
|
-
import Card from "../card/card.js";
|
9
|
-
import { UKIcon } from "../icon/iconDictionary.js";
|
10
|
-
import IconButton from "../iconButton/iconButton.js";
|
11
|
-
import Text from "../text/text.js";
|
12
|
-
import ToastContext from "./toastContext.js";
|
13
|
-
import React from "react";
|
14
|
-
import styles from "./toast.module.scss";
|
15
|
-
|
16
|
-
const Toast: FC<{ children: React.ReactNode | React.ReactNode[] }> = ({ children }) => {
|
17
|
-
const [toasts, setToasts] = useState<
|
18
|
-
{ type: "success" | "error" | "warning" | "info"; content: string; persist?: boolean; timestamp: number }[]
|
19
|
-
>([]);
|
20
|
-
|
21
|
-
return (
|
22
|
-
<>
|
23
|
-
<ToastContext.Provider
|
24
|
-
value={{
|
25
|
-
showToast: (data: { type: "success" | "error" | "warning" | "info"; content: string; persist?: boolean }) => {
|
26
|
-
const timestamp = Date.now();
|
27
|
-
|
28
|
-
setToasts([...toasts, { ...data, timestamp: timestamp }]);
|
29
|
-
|
30
|
-
if (!data.persist) {
|
31
|
-
setTimeout(() => {
|
32
|
-
setToasts(toasts.filter((t) => t.timestamp !== timestamp));
|
33
|
-
}, 5000);
|
34
|
-
}
|
35
|
-
},
|
36
|
-
}}
|
37
|
-
>
|
38
|
-
<div className={styles.container}>
|
39
|
-
{toasts.map((t) => {
|
40
|
-
return (
|
41
|
-
<Card
|
42
|
-
key={t.timestamp}
|
43
|
-
actions={
|
44
|
-
t.persist ? (
|
45
|
-
<IconButton
|
46
|
-
accessibleLabel={"Close toast"}
|
47
|
-
icon={UKIcon.X}
|
48
|
-
onClick={() => setToasts(toasts.filter((x) => x.timestamp !== t.timestamp))}
|
49
|
-
/>
|
50
|
-
) : null
|
51
|
-
}
|
52
|
-
containerClassName={clippy(styles.component, t.type && styles[t.type])}
|
53
|
-
>
|
54
|
-
<Text text={t.content} />
|
55
|
-
</Card>
|
56
|
-
);
|
57
|
-
})}
|
58
|
-
</div>
|
59
|
-
{children}
|
60
|
-
</ToastContext.Provider>
|
61
|
-
</>
|
62
|
-
);
|
63
|
-
};
|
64
|
-
|
65
|
-
export default Toast;
|