feat(ui, dashboard): Toast rework (#7076)

**What**
- Re-works how toasts work in Medusa UI. API is now built on top of `sonner` instead of `@radix-ui/react-toast`. This is a breaking change, and we will need to update the documentation once this has been merged and released (cc: @shahednasser).
- Adds an example of usage in the products list table in the new admin dashboard. As part of the coming weeks cleanup we will add toasts everywhere that they are currently missing.

CLOSES CORE-1977
This commit is contained in:
Kasper Fabricius Kristensen authored and GitHub committed 2024-04-16 13:14:58 +00:00
1 parent 379ff7a36d
commit c3260a2c5a
15 files changed
+730 -516

No files matched your search

+4 -4
View File
@@ -60,19 +60,19 @@
"@types/react-dom": "^18.2.0",
"@vitejs/plugin-react": "^4.0.1",
"@vitest/coverage-v8": "^0.32.2",
"autoprefixer": "^10.4.17",
"autoprefixer": "^10.4.19",
"chromatic": "^6.20.0",
"eslint": "^7.32.0",
"eslint-plugin-storybook": "^0.6.12",
"jsdom": "^22.1.0",
"postcss": "^8.4.33",
"postcss": "^8.4.38",
"prop-types": "^15.8.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"resize-observer-polyfill": "^1.5.1",
"rimraf": "^5.0.1",
"storybook": "^7.0.23",
"tailwindcss": "^3.4.1",
"tailwindcss": "^3.4.3",
"tsc-alias": "^1.8.7",
"typescript": "^5.1.6",
"vite": "^4.3.9",
@@ -96,7 +96,6 @@
"@radix-ui/react-slot": "^1.0.2",
"@radix-ui/react-switch": "^1.0.3",
"@radix-ui/react-tabs": "^1.0.4",
"@radix-ui/react-toast": "^1.1.4",
"@radix-ui/react-tooltip": "^1.0.6",
"@react-aria/datepicker": "^3.5.0",
"@react-stately/datepicker": "^3.5.0",
@@ -108,6 +107,7 @@
"prismjs": "^1.29.0",
"react-currency-input-field": "^3.6.11",
"react-day-picker": "^8.8.0",
"sonner": "^1.4.41",
"tailwind-merge": "^2.2.1"
},
"peerDependencies": {