@takazudo/zudo-doc 5.26.2 → 5.26.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,16 @@ The format is based on Keep a Changelog, and release notes are generated from th
|
|
|
8
8
|
|
|
9
9
|
No unreleased changes.
|
|
10
10
|
|
|
11
|
+
## [5.26.3] - 2026-09-21
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
- The mobile sidebar toggle no longer renders both of its icons at once in a project whose global CSS contains an unlayered media reset such as `img, svg, video, canvas, audio, iframe, embed, object { display: block }`. The inactive icon used to be hidden with Tailwind's `.hidden` utility, which ships inside `@layer utilities` — an unlayered author rule outranks every layered rule by cascade-layer precedence regardless of source order, so both icons computed to `display: block`, stacked vertically, and made the toggle a 48px control showing the X and the hamburger together. The inactive icon is now hidden with an inline declaration, which no consumer stylesheet can outrank. (30d6625e8)
|
|
16
|
+
|
|
17
|
+
### Other Changes
|
|
18
|
+
|
|
19
|
+
- The `@takazudo/zfb`, `@takazudo/zfb-runtime`, and `@takazudo/zfb-md-wasm` peer dependency floors are now `^2.20.1`. The 2.20.1 release is lockstep metadata only — no upstream package reports a package-specific change, and the published-tarball delta is limited to each package's own version field plus its platform-binary pins. No zudo-doc config migration is required. (07d700356)
|
|
20
|
+
|
|
11
21
|
## [5.26.2] - 2026-09-20
|
|
12
22
|
|
|
13
23
|
### Bug Fixes
|
|
@@ -5,6 +5,7 @@ import { AFTER_NAVIGATE_EVENT, ensureNestedIslandPropsRefresh } from "../transit
|
|
|
5
5
|
import { SidebarTree } from "../sidebar-tree-island/index.js";
|
|
6
6
|
ensureNestedIslandPropsRefresh();
|
|
7
7
|
const cx = (...classes) => classes.filter(Boolean).join(" ");
|
|
8
|
+
const HIDDEN_ICON_STYLE = "display:none";
|
|
8
9
|
function SidebarToggle({
|
|
9
10
|
nodes,
|
|
10
11
|
currentSlug,
|
|
@@ -47,7 +48,8 @@ function SidebarToggle({
|
|
|
47
48
|
"svg",
|
|
48
49
|
{
|
|
49
50
|
xmlns: "http://www.w3.org/2000/svg",
|
|
50
|
-
className:
|
|
51
|
+
className: "h-icon-lg w-icon-lg",
|
|
52
|
+
style: open ? void 0 : HIDDEN_ICON_STYLE,
|
|
51
53
|
"aria-hidden": "true",
|
|
52
54
|
fill: "none",
|
|
53
55
|
viewBox: "0 0 24 24",
|
|
@@ -67,7 +69,8 @@ function SidebarToggle({
|
|
|
67
69
|
"svg",
|
|
68
70
|
{
|
|
69
71
|
xmlns: "http://www.w3.org/2000/svg",
|
|
70
|
-
className:
|
|
72
|
+
className: "h-icon-lg w-icon-lg",
|
|
73
|
+
style: open ? HIDDEN_ICON_STYLE : void 0,
|
|
71
74
|
"aria-hidden": "true",
|
|
72
75
|
fill: "none",
|
|
73
76
|
viewBox: "0 0 24 24",
|
|
@@ -27,6 +27,17 @@ ensureNestedIslandPropsRefresh();
|
|
|
27
27
|
const cx = (...classes: Array<string | false | null | undefined>) =>
|
|
28
28
|
classes.filter(Boolean).join(" ");
|
|
29
29
|
|
|
30
|
+
// Icon visibility deliberately does NOT ride on Tailwind's `.hidden` utility.
|
|
31
|
+
// `.hidden` is emitted inside `@layer utilities`, and a consumer component pack
|
|
32
|
+
// that ships an UNLAYERED media reset — `img, svg, video, … { display: block }`
|
|
33
|
+
// — outranks every layered rule by cascade-layer precedence, no matter the
|
|
34
|
+
// source order. Both icons then computed to `display: block`, stacked, and made
|
|
35
|
+
// the mobile toggle 48px tall (zudolab/zudo-doc#4355). An inline declaration
|
|
36
|
+
// sits above all author rules, layered or not, so the state holds against any
|
|
37
|
+
// consumer stylesheet. It is a plain string so SSR and the initial client
|
|
38
|
+
// render serialise byte-identically for hydration.
|
|
39
|
+
const HIDDEN_ICON_STYLE = "display:none";
|
|
40
|
+
|
|
30
41
|
// Mobile drawer hosts the SidebarTree directly (rather than receiving it as
|
|
31
42
|
// JSX children) so the tree's data props ride across the SSR → hydrate
|
|
32
43
|
// boundary inside the Island marker's `data-props` attribute. zfb's
|
|
@@ -101,10 +112,10 @@ export function SidebarToggle({
|
|
|
101
112
|
<>
|
|
102
113
|
{/* Hamburger button - visible only on mobile.
|
|
103
114
|
Both icons are always rendered so the SSR output has the same
|
|
104
|
-
DOM shape as the post-hydration tree. The
|
|
105
|
-
|
|
106
|
-
hydration walk sees byte-stable markup and keeps the
|
|
107
|
-
handler attached. */}
|
|
115
|
+
DOM shape as the post-hydration tree. The inactive one is hidden
|
|
116
|
+
via an inline `display:none` (see HIDDEN_ICON_STYLE above), so
|
|
117
|
+
Preact's hydration walk sees byte-stable markup and keeps the
|
|
118
|
+
click handler attached. */}
|
|
108
119
|
<button
|
|
109
120
|
type="button"
|
|
110
121
|
onClick={() => setOpen(!open)}
|
|
@@ -115,7 +126,8 @@ export function SidebarToggle({
|
|
|
115
126
|
{/* X icon — visible only when open */}
|
|
116
127
|
<svg
|
|
117
128
|
xmlns="http://www.w3.org/2000/svg"
|
|
118
|
-
className=
|
|
129
|
+
className="h-icon-lg w-icon-lg"
|
|
130
|
+
style={open ? undefined : HIDDEN_ICON_STYLE}
|
|
119
131
|
aria-hidden="true"
|
|
120
132
|
fill="none"
|
|
121
133
|
viewBox="0 0 24 24"
|
|
@@ -131,7 +143,8 @@ export function SidebarToggle({
|
|
|
131
143
|
{/* Hamburger icon — visible only when closed */}
|
|
132
144
|
<svg
|
|
133
145
|
xmlns="http://www.w3.org/2000/svg"
|
|
134
|
-
className=
|
|
146
|
+
className="h-icon-lg w-icon-lg"
|
|
147
|
+
style={open ? HIDDEN_ICON_STYLE : undefined}
|
|
135
148
|
aria-hidden="true"
|
|
136
149
|
fill="none"
|
|
137
150
|
viewBox="0 0 24 24"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@takazudo/zudo-doc",
|
|
3
|
-
"version": "5.26.
|
|
3
|
+
"version": "5.26.3",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "zudo-doc framework primitives layer that sits on top of zfb's engine — sidebar, theme, TOC, breadcrumb, layouts, head injection, View Transitions, SSR-skip wrappers (per ADR-003).",
|
|
6
6
|
"license": "MIT",
|
|
@@ -717,9 +717,9 @@
|
|
|
717
717
|
],
|
|
718
718
|
"peerDependencies": {
|
|
719
719
|
"@takazudo/zdtp": "^0.5.2 || ^0.6.0 || ^0.7.0 || ^0.8.0",
|
|
720
|
-
"@takazudo/zfb": "^2.20.
|
|
721
|
-
"@takazudo/zfb-md-wasm": "^2.20.
|
|
722
|
-
"@takazudo/zfb-runtime": "^2.20.
|
|
720
|
+
"@takazudo/zfb": "^2.20.1",
|
|
721
|
+
"@takazudo/zfb-md-wasm": "^2.20.1",
|
|
722
|
+
"@takazudo/zfb-runtime": "^2.20.1",
|
|
723
723
|
"@takazudo/zudo-doc-history-server": "^5.17.2",
|
|
724
724
|
"diff": "^8.0.0",
|
|
725
725
|
"katex": "^0.16.0",
|
|
@@ -757,9 +757,9 @@
|
|
|
757
757
|
},
|
|
758
758
|
"devDependencies": {
|
|
759
759
|
"@takazudo/mdx-formatter": "1.3.0-next.4",
|
|
760
|
-
"@takazudo/zfb": "2.20.
|
|
761
|
-
"@takazudo/zfb-md-wasm": "2.20.
|
|
762
|
-
"@takazudo/zfb-runtime": "2.20.
|
|
760
|
+
"@takazudo/zfb": "2.20.1",
|
|
761
|
+
"@takazudo/zfb-md-wasm": "2.20.1",
|
|
762
|
+
"@takazudo/zfb-runtime": "2.20.1",
|
|
763
763
|
"@types/fs-extra": "^11.0.4",
|
|
764
764
|
"@types/minimist": "^1.2.5",
|
|
765
765
|
"@types/node": "^25.3.5",
|
|
@@ -771,7 +771,7 @@
|
|
|
771
771
|
"typescript": "^5.0.0",
|
|
772
772
|
"vitest": "^4.1.0",
|
|
773
773
|
"zod": "^4.3.6",
|
|
774
|
-
"@takazudo/zudo-doc-history-server": "5.26.
|
|
774
|
+
"@takazudo/zudo-doc-history-server": "5.26.3"
|
|
775
775
|
},
|
|
776
776
|
"scripts": {
|
|
777
777
|
"gen:search-widget-script": "node scripts/gen-search-widget-script.mjs",
|