Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f680d58

Browse filesBrowse files
committed
Add react-dropzone dependency and update related lockfile
1 parent 9e6063e commit f680d58
Copy full SHA for f680d58

File tree

Expand file treeCollapse file tree

10 files changed

+114
-46
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

10 files changed

+114
-46
lines changed
Open diff view settings
Collapse file

‎app/docs/layout.tsx‎

Copy file name to clipboard
+10-28Lines changed: 10 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { DocsLayout } from "fumadocs-ui/layouts/docs";
1+
import { DocsLayout } from "fumadocs-ui/layouts/notebook";
22

33
import { baseOptions } from "@/lib/layout.shared";
44
import { source } from "@/lib/source";
@@ -12,37 +12,19 @@ export default function Layout({ children }: LayoutProps<"/docs">) {
1212
tree={source.pageTree}
1313
nav={{
1414
...base.nav,
15+
mode: "top",
16+
// transparentMode: "always",
1517
}}
1618
sidebar={{
17-
tabs: {
18-
transform(option, node) {
19-
const meta = source.getNodeMeta(node);
20-
if (!meta || !node.icon) return option;
21-
22-
const color = `var(--${
23-
meta.path.split("/")[0]
24-
}-color, var(--color-fd-foreground))`;
25-
26-
return {
27-
...option,
28-
icon: (
29-
<div
30-
className="[&_svg]:size-full rounded-lg size-full text-(--tab-color) max-md:bg-(--tab-color)/10 max-md:border max-md:p-1.5"
31-
style={
32-
{
33-
"--tab-color": color,
34-
} as object
35-
}
36-
>
37-
{node.icon}
38-
</div>
39-
),
40-
};
41-
},
42-
},
19+
prefetch: false,
20+
}}
21+
containerProps={{
22+
className:
23+
"min-h-screen dark:bg-[#050505] bg-fixed dark:bg-[radial-gradient(circle_at_20%_10%,var(--color-slate-950)_0%,var(--color-stone-950)_40%)]",
4324
}}
4425
>
45-
{children}
26+
<div className="absolute inset-0 bg-fixed z-[0] dark:bg-[radial-gradient(circle_at_100%_90%,var(--color-slate-950)_0%,transparent_30%)]" />
27+
<div className="relative z-[1]">{children}</div>
4628
</DocsLayout>
4729
);
4830
}
Collapse file

‎app/global.css‎

Copy file name to clipboardExpand all lines: app/global.css
+27-13Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,29 @@
177177
button:active {
178178
@apply opacity-60 md:opacity-100;
179179
}
180+
181+
#nd-sidebar {
182+
--color-fd-card: transparent;
183+
184+
& [data-radix-scroll-area-viewport] {
185+
@apply !pt-12;
186+
}
187+
188+
& p {
189+
@apply text-base font-semibold;
190+
}
191+
192+
& > div:nth-child(1) {
193+
@apply shadow-lg;
194+
}
195+
}
196+
197+
#nd-subnav {
198+
& > div {
199+
@apply !border-0 shadow-lg;
200+
}
201+
}
202+
180203
/*
181204
* {
182205
box-sizing: border-box;
@@ -237,19 +260,6 @@
237260
}
238261

239262
@layer components {
240-
/* .docs-body,
241-
[data-docs-body] {
242-
@apply px-2 sm:px-4 md:px-6 w-full max-w-none;
243-
}
244-
245-
.prose {
246-
@apply w-full;
247-
}
248-
249-
.prose > * {
250-
@apply px-0;
251-
} */
252-
253263
.steps {
254264
&:first-child {
255265
@apply !mt-0;
@@ -268,6 +278,10 @@
268278
}
269279
}
270280

281+
.border-e {
282+
border-color: transparent !important;
283+
}
284+
271285
/* feat: Background image utilities for theme support */
272286
.bg-pattern {
273287
background: transparent;
Collapse file

‎components/ComponentPreviewTabs.tsx‎

Copy file name to clipboardExpand all lines: components/ComponentPreviewTabs.tsx
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ export function ComponentPreviewTabs({
6363
<div
6464
data-slot="preview"
6565
data-active={tab === "preview"}
66-
className="invisible data-[active=true]:visible"
66+
className="invisible data-[active=true]:visible bg-secondary rounded-lg !border-0"
6767
>
6868
<ScrollArea>
6969
<div
Collapse file

‎components/Sidebar.tsx‎

Copy file name to clipboard
+19Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
"use client";
2+
3+
import type React from "react";
4+
5+
import { usePathname } from "next/navigation";
6+
7+
// import { source } from "@/lib/source";
8+
9+
const Sidebar: React.FC = () => {
10+
const pathname = usePathname();
11+
12+
// console.log(source.pageTree);
13+
14+
return (
15+
<aside className="fixed left-0 rtl:left-auto rtl:right-(--removed-body-scroll-bar-size,0) flex flex-col items-end top-(--fd-sidebar-top) bottom-(--fd-sidebar-margin) z-20 bg-fd-card text-sm border-e transition-[top,opacity,translate,width] duration-200 max-md:hidden *:w-(--fd-sidebar-width)"></aside>
16+
);
17+
};
18+
19+
export default Sidebar;
Collapse file

‎package.json‎

Copy file name to clipboardExpand all lines: package.json
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
"next-themes": "^0.4.6",
4343
"react": "^19.2.0",
4444
"react-dom": "^19.2.0",
45+
"react-dropzone": "^14.3.8",
4546
"shiki": "^3.13.0",
4647
"sonner": "^2.0.7",
4748
"tailwind-merge": "^3.3.1",
Collapse file

‎pnpm-lock.yaml‎

Copy file name to clipboardExpand all lines: pnpm-lock.yaml
+52Lines changed: 52 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.