Skip to content

AI-native knowledge base & Evernote/Obsidian alternative with instant sync & native MCP. Free on Cloudflare or self-hosted via Docker.

style(extension): use status colors only for notification icons

tianma-ifc6bc788dec53
diff --git a/apps/extension/src/ui/components/sonner.tsx b/apps/extension/src/ui/components/sonner.tsx
index 2d262440..cdd2ff74 100644
--- a/apps/extension/src/ui/components/sonner.tsx
+++ b/apps/extension/src/ui/components/sonner.tsx
@@ -21,10 +21,10 @@ export function Toaster({
hotkey={hotkey}
className="toaster group"
icons={{
- success: <CircleCheckIcon size={16} className="size-4" aria-hidden="true" />,
+ success: <CircleCheckIcon size={16} className="size-4 text-[var(--notification-success-icon)]" aria-hidden="true" />,
info: <InfoIcon size={16} className="size-4" aria-hidden="true" />,
warning: <TriangleAlertIcon size={16} className="size-4" aria-hidden="true" />,
- error: <OctagonXIcon size={16} className="size-4" aria-hidden="true" />,
+ error: <OctagonXIcon size={16} className="size-4 text-[var(--notification-error-icon)]" aria-hidden="true" />,
loading: <Loader2Icon size={16} className="size-4 animate-spin motion-reduce:animate-none" aria-hidden="true" />,
...icons,
}}
diff --git a/apps/extension/src/ui/notification.css b/apps/extension/src/ui/notification.css
index 5fc63499..d81e893d 100644
--- a/apps/extension/src/ui/notification.css
+++ b/apps/extension/src/ui/notification.css
@@ -2,9 +2,3 @@
.toaster [data-sonner-toast] {
pointer-events: auto;
}
-
-.toaster [data-sonner-toast][data-type="error"] {
- --normal-bg: var(--notification-error-background);
- --normal-text: var(--notification-error-foreground);
- --normal-border: var(--notification-error-border);
-}
diff --git a/apps/extension/src/ui/theme-tokens.css b/apps/extension/src/ui/theme-tokens.css
index dfa95e3a..3e0974d7 100644
--- a/apps/extension/src/ui/theme-tokens.css
+++ b/apps/extension/src/ui/theme-tokens.css
@@ -13,7 +13,6 @@
--border: #e0e0e0;
--ring: #262626;
--radius: 0.5rem;
- --notification-error-background: #fff1f2;
- --notification-error-foreground: #be123c;
- --notification-error-border: #ffe4e6;
+ --notification-success-icon: #16a06e;
+ --notification-error-icon: #be123c;
}