fumadocs-core 15.6.7 → 15.6.8
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/dist/framework/waku.d.ts +8 -0
- package/dist/framework/waku.js +51 -0
- package/package.json +24 -11
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import {
|
|
3
|
+
FrameworkProvider
|
|
4
|
+
} from "../chunk-BBP7MIO4.js";
|
|
5
|
+
import "../chunk-JSBRDJBE.js";
|
|
6
|
+
|
|
7
|
+
// src/framework/waku.tsx
|
|
8
|
+
import { useMemo } from "react";
|
|
9
|
+
import { Link as WakuLink, useRouter } from "waku";
|
|
10
|
+
import { jsx } from "react/jsx-runtime";
|
|
11
|
+
var framework = {
|
|
12
|
+
usePathname() {
|
|
13
|
+
const { path } = useRouter();
|
|
14
|
+
return path;
|
|
15
|
+
},
|
|
16
|
+
useParams() {
|
|
17
|
+
const { query } = useRouter();
|
|
18
|
+
return useMemo(() => {
|
|
19
|
+
const params = new URLSearchParams(query);
|
|
20
|
+
return Object.fromEntries(
|
|
21
|
+
Array.from(params.entries()).map(([key, value]) => [
|
|
22
|
+
key,
|
|
23
|
+
Array.isArray(value) ? value[0] : value
|
|
24
|
+
])
|
|
25
|
+
);
|
|
26
|
+
}, [query]);
|
|
27
|
+
},
|
|
28
|
+
useRouter() {
|
|
29
|
+
const router = useRouter();
|
|
30
|
+
return useMemo(
|
|
31
|
+
() => ({
|
|
32
|
+
push(url) {
|
|
33
|
+
void router.push(url);
|
|
34
|
+
},
|
|
35
|
+
refresh() {
|
|
36
|
+
void router.push(router.path);
|
|
37
|
+
}
|
|
38
|
+
}),
|
|
39
|
+
[router]
|
|
40
|
+
);
|
|
41
|
+
},
|
|
42
|
+
Link({ href, prefetch: _prefetch, ...props }) {
|
|
43
|
+
return /* @__PURE__ */ jsx(WakuLink, { to: href, ...props, children: props.children });
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
function WakuProvider({ children }) {
|
|
47
|
+
return /* @__PURE__ */ jsx(FrameworkProvider, { ...framework, children });
|
|
48
|
+
}
|
|
49
|
+
export {
|
|
50
|
+
WakuProvider
|
|
51
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fumadocs-core",
|
|
3
|
-
"version": "15.6.
|
|
3
|
+
"version": "15.6.8",
|
|
4
4
|
"description": "The library for building a documentation website in Next.js",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"NextJs",
|
|
@@ -87,8 +87,8 @@
|
|
|
87
87
|
"dependencies": {
|
|
88
88
|
"@formatjs/intl-localematcher": "^0.6.1",
|
|
89
89
|
"@orama/orama": "^3.1.11",
|
|
90
|
-
"@shikijs/rehype": "^3.
|
|
91
|
-
"@shikijs/transformers": "^3.
|
|
90
|
+
"@shikijs/rehype": "^3.9.1",
|
|
91
|
+
"@shikijs/transformers": "^3.9.1",
|
|
92
92
|
"github-slugger": "^2.0.0",
|
|
93
93
|
"hast-util-to-estree": "^3.1.3",
|
|
94
94
|
"hast-util-to-jsx-runtime": "^2.3.6",
|
|
@@ -100,42 +100,46 @@
|
|
|
100
100
|
"remark-gfm": "^4.0.1",
|
|
101
101
|
"remark-rehype": "^11.1.2",
|
|
102
102
|
"scroll-into-view-if-needed": "^3.1.0",
|
|
103
|
-
"shiki": "^3.
|
|
103
|
+
"shiki": "^3.9.1",
|
|
104
104
|
"unist-util-visit": "^5.0.0"
|
|
105
105
|
},
|
|
106
106
|
"devDependencies": {
|
|
107
107
|
"@mdx-js/mdx": "^3.1.0",
|
|
108
108
|
"@mixedbread/sdk": "^0.19.0",
|
|
109
109
|
"@oramacloud/client": "^2.1.4",
|
|
110
|
-
"@tanstack/react-router": "^1.
|
|
110
|
+
"@tanstack/react-router": "^1.130.12",
|
|
111
111
|
"@types/estree-jsx": "^1.0.5",
|
|
112
112
|
"@types/hast": "^3.0.4",
|
|
113
113
|
"@types/mdast": "^4.0.3",
|
|
114
114
|
"@types/negotiator": "^0.6.4",
|
|
115
115
|
"@types/node": "24.1.0",
|
|
116
|
-
"@types/react": "^19.1.
|
|
117
|
-
"@types/react-dom": "^19.1.
|
|
118
|
-
"algoliasearch": "5.
|
|
116
|
+
"@types/react": "^19.1.9",
|
|
117
|
+
"@types/react-dom": "^19.1.7",
|
|
118
|
+
"algoliasearch": "5.35.0",
|
|
119
119
|
"mdast-util-mdx-jsx": "^3.2.0",
|
|
120
120
|
"mdast-util-mdxjs-esm": "^2.0.1",
|
|
121
|
-
"next": "^15.4.
|
|
121
|
+
"next": "^15.4.5",
|
|
122
122
|
"react-router": "^7.7.1",
|
|
123
123
|
"remark-mdx": "^3.1.0",
|
|
124
124
|
"remove-markdown": "^0.6.2",
|
|
125
|
-
"typescript": "^5.
|
|
125
|
+
"typescript": "^5.9.2",
|
|
126
126
|
"unified": "^11.0.5",
|
|
127
127
|
"vfile": "^6.0.3",
|
|
128
|
+
"waku": "^0.23.7",
|
|
128
129
|
"eslint-config-custom": "0.0.0",
|
|
129
130
|
"tsconfig": "0.0.0"
|
|
130
131
|
},
|
|
131
132
|
"peerDependencies": {
|
|
132
133
|
"@mixedbread/sdk": "^0.19.0",
|
|
133
134
|
"@oramacloud/client": "1.x.x || 2.x.x",
|
|
135
|
+
"@tanstack/react-router": "1.x.x",
|
|
134
136
|
"@types/react": "*",
|
|
135
137
|
"algoliasearch": "5.x.x",
|
|
136
138
|
"next": "14.x.x || 15.x.x",
|
|
137
139
|
"react": "18.x.x || 19.x.x",
|
|
138
|
-
"react-dom": "18.x.x || 19.x.x"
|
|
140
|
+
"react-dom": "18.x.x || 19.x.x",
|
|
141
|
+
"react-router": "7.x.x",
|
|
142
|
+
"waku": "^0.23.0"
|
|
139
143
|
},
|
|
140
144
|
"peerDependenciesMeta": {
|
|
141
145
|
"@mixedbread/sdk": {
|
|
@@ -158,6 +162,15 @@
|
|
|
158
162
|
},
|
|
159
163
|
"react-dom": {
|
|
160
164
|
"optional": true
|
|
165
|
+
},
|
|
166
|
+
"waku": {
|
|
167
|
+
"optional": true
|
|
168
|
+
},
|
|
169
|
+
"@tanstack/react-router": {
|
|
170
|
+
"optional": true
|
|
171
|
+
},
|
|
172
|
+
"react-router": {
|
|
173
|
+
"optional": true
|
|
161
174
|
}
|
|
162
175
|
},
|
|
163
176
|
"publishConfig": {
|