Commit 4c4b398
committed
fix(docs): render the Copy page button on real docs pages and fix hydration 404s
The Copy page split button shipped in #739 never rendered: it was wired
into pages/[...slug].vue while all /docs/* routes are handled by the
more specific pages/docs/[...slug].vue, and it was referenced as
<CopyPageDropdown /> while the auto-import name is DocsCopyPageDropdown.
- Render DocsCopyPageDropdown in the title row of pages/docs/[...slug].vue
- Delete the root catch-all pages/[...slug].vue: it served no content
(only /docs/** exists in the content collection) and its competing
route caused client-side 404s after hydration on trailing-slash docs
URLs
- Drop the redundant nested <article> that caused hydration mismatches
on every docs page
- Fix doubled item descriptions in the copy dropdown (UDropdownMenu
renders item.description natively)
- Remove dead layouts/default.vue + TheHeader/TheSidebar/TheTableOfContents
(unused since the docs layout took over) and add the ⌘K hint to the
active search button
Verified with a full static build + headless-browser checks: button in
the title row in light/dark, 4-item dropdown with correct .md/ChatGPT/
Claude targets, fuzzy section-level search with the AI-tip footer, and
no hydration 404s on slash/no-slash hard loads.1 parent c40b0d1 commit 4c4b398
8 files changed
Lines changed: 13 additions & 252 deletions
File tree
- docs-v3
- components
- docs
- website
- layouts
- pages
- docs
This file was deleted.
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
| 33 | + | |
39 | 34 | | |
40 | 35 | | |
41 | 36 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
38 | 43 | | |
39 | 44 | | |
40 | 45 | | |
| |||
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
5 | | - | |
| 4 | + | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
| 9 | + | |
13 | 10 | | |
14 | | - | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
15 | 14 | | |
16 | 15 | | |
17 | 16 | | |
| |||
0 commit comments