@kolkrabbi/kol-workshop 0.26.0 → 0.27.0
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/package.json +4 -4
- package/src/shell/ShellLayout.jsx +11 -0
- package/src/shell/index.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kolkrabbi/kol-workshop",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.27.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "KOL workshop/docs system — a handrolled markdown engine, search, tag system (incl. a d3 tag graph), docs viewer, and docs shell. Sits above @kolkrabbi/kol-{theme,icons,component,framework}; content is consumer-injected (the package never globs docs).",
|
|
6
6
|
"license": "MIT",
|
|
@@ -25,10 +25,10 @@
|
|
|
25
25
|
"react-router-dom": "^6.0.0 || ^7.0.0"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@kolkrabbi/kol-
|
|
28
|
+
"@kolkrabbi/kol-framework": "^0.36.0",
|
|
29
29
|
"@kolkrabbi/kol-icons": "^0.25.0",
|
|
30
|
-
"@kolkrabbi/kol-theme": "^0.
|
|
31
|
-
"@kolkrabbi/kol-
|
|
30
|
+
"@kolkrabbi/kol-theme": "^0.122.0",
|
|
31
|
+
"@kolkrabbi/kol-component": "^0.153.0"
|
|
32
32
|
},
|
|
33
33
|
"files": [
|
|
34
34
|
"src",
|
|
@@ -36,6 +36,15 @@ export const ShellContentWidthContext = createContext(null)
|
|
|
36
36
|
// useLayoutEffect(() => { setTocCollapsed(true) ; return () => setTocCollapsed(false) }, [setTocCollapsed])
|
|
37
37
|
export const ShellTocCollapsedContext = createContext(null)
|
|
38
38
|
|
|
39
|
+
// THE LEFT RAIL IS THE PAGE'S CALL TOO (2026-09-01). The TOC had this seam and
|
|
40
|
+
// the nav did not, so a landing page could shed one rail and not the other —
|
|
41
|
+
// the showcase home claimed "top nav (no sidebar)" in its docstring and rendered
|
|
42
|
+
// under both. Same shape as the TOC seam: set on mount, restore on unmount, and
|
|
43
|
+
// the header's own toggles keep working on top of it.
|
|
44
|
+
// Usage: const setNavCollapsed = useContext(ShellNavCollapsedContext)
|
|
45
|
+
// useLayoutEffect(() => { setNavCollapsed(true) ; return () => setNavCollapsed(false) }, [setNavCollapsed])
|
|
46
|
+
export const ShellNavCollapsedContext = createContext(null)
|
|
47
|
+
|
|
39
48
|
/* overflow-x-hidden (2026-07-30): long tree rows (component names + counters)
|
|
40
49
|
* overflowed the 256px rail into an internal horizontal scroll — with the
|
|
41
50
|
* scrollbar hidden it read as content silently walking off, and the pan
|
|
@@ -279,6 +288,7 @@ const ShellLayout = ({ routes = [], basePath = '/', brand: brandProp, brandLogoS
|
|
|
279
288
|
<ShellFullHeightContext.Provider value={setIsFullHeight}>
|
|
280
289
|
<ShellContentWidthContext.Provider value={setContentWidth}>
|
|
281
290
|
<ShellTocCollapsedContext.Provider value={setTocCollapsed}>
|
|
291
|
+
<ShellNavCollapsedContext.Provider value={setNavCollapsed}>
|
|
282
292
|
<div className="fixed inset-0 flex flex-col bg-surface-primary text-auto">
|
|
283
293
|
<ShellHeader
|
|
284
294
|
brand={brand}
|
|
@@ -452,6 +462,7 @@ const ShellLayout = ({ routes = [], basePath = '/', brand: brandProp, brandLogoS
|
|
|
452
462
|
</div>
|
|
453
463
|
)}
|
|
454
464
|
</div>
|
|
465
|
+
</ShellNavCollapsedContext.Provider>
|
|
455
466
|
</ShellTocCollapsedContext.Provider>
|
|
456
467
|
</ShellContentWidthContext.Provider>
|
|
457
468
|
</ShellFullHeightContext.Provider>
|
package/src/shell/index.js
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* against.
|
|
8
8
|
*/
|
|
9
9
|
export { default as ShellLayout } from './ShellLayout.jsx'
|
|
10
|
-
export { ShellTocContext, ShellFullHeightContext, ShellTocCollapsedContext, ShellContentWidthContext } from './ShellLayout.jsx'
|
|
10
|
+
export { ShellTocContext, ShellFullHeightContext, ShellTocCollapsedContext, ShellNavCollapsedContext, ShellContentWidthContext } from './ShellLayout.jsx'
|
|
11
11
|
export { default as ShellSidebar } from './ShellSidebar.jsx'
|
|
12
12
|
/* RailSection — THE rail ladder. Every rail header at every rung comes from
|
|
13
13
|
* here, in both rails; see the file header for why a class alone was not
|