@synerise/ds-toast 2.0.8 → 2.0.10
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 +20 -0
- package/CLAUDE.md +1 -2
- package/dist/Toast.js +2 -2
- package/package.json +10 -9
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,26 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [2.0.10](https://github.com/Synerise/synerise-design/compare/@synerise/ds-toast@2.0.9...@synerise/ds-toast@2.0.10) (2026-10-26)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* drop vitest peer dependency and bump vulnerable runtime deps ([2467d36](https://github.com/Synerise/synerise-design/commit/2467d3606aa97141a3a2d80c3ef396e78bee285c))
|
|
12
|
+
* remove per-render random keys and guard against them with a Biome plugin ([fcea7c5](https://github.com/Synerise/synerise-design/commit/fcea7c5d60b80c28cbbd191bfa2792379782a0e8))
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
## [2.0.9](https://github.com/Synerise/synerise-design/compare/@synerise/ds-toast@2.0.8...@synerise/ds-toast@2.0.9) (2026-10-22)
|
|
19
|
+
|
|
20
|
+
**Note:** Version bump only for package @synerise/ds-toast
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
6
26
|
## [2.0.8](https://github.com/Synerise/synerise-design/compare/@synerise/ds-toast@2.0.7...@synerise/ds-toast@2.0.8) (2026-10-20)
|
|
7
27
|
|
|
8
28
|
**Note:** Version bump only for package @synerise/ds-toast
|
package/CLAUDE.md
CHANGED
|
@@ -54,7 +54,7 @@ Extends `WithHTMLAttributes<HTMLDivElement, ..>` — all standard div props are
|
|
|
54
54
|
| `props` | `ShowToastProps` | All `ToastProps` except `type` and `show` |
|
|
55
55
|
| `options` | `ToastCustomisationOptions` | Subset of react-hot-toast `ToastOptions`: `duration`, `position`, `id`, `removeDelay`, `className`, `style` |
|
|
56
56
|
|
|
57
|
-
Returns the `toastId` string. If `props.toastId` is not provided
|
|
57
|
+
Returns the `toastId` string. If `props.toastId` is not provided one is generated with `generateUuid()` from `@synerise/ds-utils`.
|
|
58
58
|
|
|
59
59
|
### Static shortcut methods on `Toast`
|
|
60
60
|
| Method | Maps to type |
|
|
@@ -122,7 +122,6 @@ import Toast from '@synerise/ds-toast';
|
|
|
122
122
|
|
|
123
123
|
## Key dependencies
|
|
124
124
|
- `react-hot-toast ^2.5.2` — Toaster and imperative toast API
|
|
125
|
-
- `uuid ^8.3.2` — Auto-generates `toastId` when not provided
|
|
126
125
|
- `@synerise/ds-icon` — `Check3M`, `WarningFillM`, `InfoFillM`, `AngleDownS`, `CloseM`
|
|
127
126
|
- `@synerise/ds-unordered-list` — style import for list layout inside expanded content
|
|
128
127
|
- `@synerise/ds-core` (peer) — theme tokens; `DSProvider` embeds the Toaster via `TOASTER_DEFAULTS`
|
package/dist/Toast.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useMemo, useCallback, useEffect } from "react";
|
|
3
3
|
import toast from "react-hot-toast";
|
|
4
|
-
import { v4 } from "uuid";
|
|
5
4
|
import Icon, { AngleDownS, CloseM } from "@synerise/ds-icon";
|
|
5
|
+
import { generateUuid } from "@synerise/ds-utils";
|
|
6
6
|
import { ICONS } from "./constants.js";
|
|
7
7
|
import { AnimationContainer, Container, IconWrapper, WrapperSectionMessage, AlertMessage, ButtonWrapper, IconExpanderWrapper, IconCloseWrapper, AlertContent, AlertDescription, ListWrapper } from "./Toast.styles.js";
|
|
8
8
|
const Toast = ({
|
|
@@ -58,7 +58,7 @@ const Toast = ({
|
|
|
58
58
|
] }) });
|
|
59
59
|
};
|
|
60
60
|
const showToast = (type, props, options) => {
|
|
61
|
-
const toastId = props.toastId || `toast-${
|
|
61
|
+
const toastId = props.toastId || `toast-${generateUuid()}`;
|
|
62
62
|
return toast.custom((t) => /* @__PURE__ */ jsx(Toast, { ...props, toastId, type, show: t.visible }), {
|
|
63
63
|
...options,
|
|
64
64
|
id: toastId
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@synerise/ds-toast",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.10",
|
|
4
4
|
"description": "Toast UI Component for the Synerise Design System",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"repository": "Synerise/synerise-design",
|
|
@@ -42,17 +42,18 @@
|
|
|
42
42
|
],
|
|
43
43
|
"types": "dist/index.d.ts",
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@synerise/ds-icon": "^2.2.
|
|
46
|
-
"@synerise/ds-unordered-list": "^2.0.
|
|
47
|
-
"@synerise/ds-utils": "^2.2.
|
|
48
|
-
"react-hot-toast": "^2.6.0"
|
|
49
|
-
|
|
45
|
+
"@synerise/ds-icon": "^2.2.3",
|
|
46
|
+
"@synerise/ds-unordered-list": "^2.0.10",
|
|
47
|
+
"@synerise/ds-utils": "^2.2.2",
|
|
48
|
+
"react-hot-toast": "^2.6.0"
|
|
49
|
+
},
|
|
50
|
+
"devDependencies": {
|
|
51
|
+
"vitest": "4"
|
|
50
52
|
},
|
|
51
53
|
"peerDependencies": {
|
|
52
54
|
"@synerise/ds-core": "*",
|
|
53
55
|
"react": ">=16.9.0 <= 18.3.1",
|
|
54
|
-
"styled-components": "^5.3.3"
|
|
55
|
-
"vitest": "4"
|
|
56
|
+
"styled-components": "^5.3.3"
|
|
56
57
|
},
|
|
57
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "5ac0f7dcb7c3995b402c86c087d8f32770f80a1d"
|
|
58
59
|
}
|