You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am creating an application with Tauri and using the shadcn-svelte integration of this library, and one thing I noticed is that with the dev mode, I get about half of the intended styling from shadcn-svelte, and half from this component's built-in styles. The white outline around a toast is from the classes applied through toastOptions, but the style for the action button through toastOptions.actionButton to make it white does not apply.
Then, in the final bundle, the card's white outline is gone but the button styling actually starts to work.
This is even more apparent when I try to use richColors.
In dev mode:
The final bundle for richColors looks the same as if I hadn't applied richColors at all.
I understand I can use the unstyled option for the toast, but I was hoping to keep some of the layout styling, like padding and text size. Maybe the answer is that shadcn-svelte should be using unstyled for their integration and needs to handle all of the styling rather than just adding to existing styles.
Reproduction
Create a clean Tauri app with Svelte and TypeScript as your frontend (maybe optional).
Install shadcn-svelte
Install their Sonner component
Set up the Toaster and create a toast
Observe in the dev mode the button styles don't apply, but toast styles do.
Observe that in the final release build, the toast styles don't apply but the button styles do.
Describe the bug
(I'm not sure if this is an issue for https://github.com/huntabyte/shadcn-svelte or this repo.)
I am creating an application with Tauri and using the shadcn-svelte integration of this library, and one thing I noticed is that with the dev mode, I get about half of the intended styling from shadcn-svelte, and half from this component's built-in styles. The white outline around a toast is from the classes applied through
toastOptions
, but the style for the action button throughtoastOptions.actionButton
to make it white does not apply.Then, in the final bundle, the card's white outline is gone but the button styling actually starts to work.
This is even more apparent when I try to use
richColors
.In dev mode:
The final bundle for richColors looks the same as if I hadn't applied richColors at all.
I understand I can use the
unstyled
option for the toast, but I was hoping to keep some of the layout styling, like padding and text size. Maybe the answer is that shadcn-svelte should be usingunstyled
for their integration and needs to handle all of the styling rather than just adding to existing styles.Reproduction
Logs
No response
System Info
Severity
annoyance
The text was updated successfully, but these errors were encountered: