Skip to content

Commit 7ef287a

Browse files
committed
docs: improve dark mode documentation for Toaster component setup
1 parent c7f59a6 commit 7ef287a

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

website/src/docs/dark-mode.mdx

+6-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "Dark Mode"
3-
description: "This page shows examples of how to use next-themes (Next.js) or remix-themes (Remix) libraries"
3+
description: "This page shows examples of how to set up the dark mode theme for the Toaster component. Using Vite, Next.js (with next-themes) or Remix (with remix-themes)."
44
category: "Customization"
55
---
66

@@ -116,7 +116,7 @@ export default ToasterProvider;
116116

117117
2. Import the `ToasterProvider` component in the `main.tsx` file:
118118

119-
```tsx
119+
```tsx {3, 9}
120120
// 📄 main.tsx
121121

122122
import ToasterProvider from "./providers/toasterProvider";
@@ -163,9 +163,11 @@ export default ToasterNextTheme;
163163

164164
2. Import the `ToasterNextTheme` component in the `layout/app.tsx` file:
165165

166-
```tsx
166+
```tsx {3, 20}
167167
// 📄 layout/app.tsx
168168

169+
import ToasterNextTheme from "@/components/ToasterNextTheme";
170+
169171
export default function RootLayout({
170172
children,
171173
}: Readonly<{
@@ -195,7 +197,7 @@ export default function RootLayout({
195197
196198
Import the `useTheme` hook from `remix-themes` and change the theme value:
197199

198-
```tsx
200+
```tsx {4, 19}
199201
// 📄 app/root.tsx
200202

201203
import clsx from 'clsx';

0 commit comments

Comments
 (0)