Closed ivan-dalmet closed 1 month ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
start-ui | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Oct 14, 2024 3:44pm |
The pull request updates the package.json
for the start-ui-web
project to version 2.0.0
, introducing a new dependency on the sonner
library for toast notifications. The Providers
component now incorporates a Toaster
for displaying notifications. A new Storybook file for the Toast
component has been created, showcasing various notification scenarios. Additionally, several components have been modified to utilize the new toastCustom
function instead of the previous toast hooks, streamlining the notification process across the application.
File Path | Change Summary |
---|---|
package.json | Updated to version 2.0.0 , requiring Node.js >=20 , added dependency "sonner": "1.5.0" . |
src/app/Providers.tsx | Updated to include a Toaster component in the returned JSX. |
src/components/Toast/docs.stories.tsx | Created new stories: Default , WithDescription , WithActions , HideIcon . |
src/components/Toast/index.ts | Removed file containing old toast hooks and configurations. |
src/components/Toast/index.tsx | Introduced toastCustom function for customizable toast notifications. |
src/features/account/AccountDeleteButton.tsx | Updated to use toastCustom instead of useToastError . |
src/features/account/AccountEmailForm.tsx | Updated to use toastCustom , removed useToastError . |
src/features/account/AccountProfileForm.tsx | Updated to use toastCustom , removed useToastError and useToastSuccess . |
src/features/account/EmailVerificationCodeModal.tsx | Updated to use toastCustom , removed useToastSuccess . |
src/features/auth/LoginForm.tsx | Updated to use toastCustom , removed useToastError . |
src/features/auth/PageRegister.tsx | Updated to use toastCustom , removed useToastError . |
src/features/repositories/AdminRepositoryActions.tsx | No changes made. |
src/features/repositories/PageAdminRepository.tsx | Updated to use toastCustom , removed useToastError . |
src/features/repositories/PageAdminRepositoryCreate.tsx | Updated to use toastCustom , removed useToastError and useToastSuccess . |
src/features/repositories/PageAdminRepositoryUpdate.tsx | Updated to use toastCustom , removed useToastError and useToastSuccess . |
src/features/users/AdminUserActions.tsx | Updated to use toastCustom , removed useToastError and useToastSuccess . |
src/features/users/PageAdminUserCreate.tsx | Updated to use toastCustom , removed useToastError and useToastSuccess . |
src/features/users/PageAdminUserUpdate.tsx | Updated to use toastCustom , removed useToastError and useToastSuccess . |
src/features/demo-mode/DemoModalInterceptor.tsx | Updated to use toast from sonner , replaced toast.closeAll with toast.dismiss , added cleanup function. |
src/locales/ar/components.json | Updated with new entries for toast notifications. |
src/locales/en/components.json | Updated with new entries for toast notifications. |
src/locales/fr/components.json | Updated with new entries for toast notifications. |
src/locales/sw/components.json | Updated with new entries for toast notifications. |
package.json
file in both the main PR and this retrieved PR has been updated to version 2.0.0
and specifies Node.js version >=20
, indicating a direct connection in dependency management.Failed conditions
8.0% Duplication on New Code (required ≤ 3%)
Describe your changes
Add sonner for toasts instead of Chakra toasts.
Screenshots
Documentation
https://github.com/BearStudio/start-ui-web-docs/pull/57
Checklist
pnpm storybook
command and everything is working(If you cannot update the french language, just let us know in the PR description)
Summary by CodeRabbit
New Features
toastCustom
function, enhancing user feedback for various actions.Toast
component to showcase its functionality.Bug Fixes
Chores
package.json
.