@umami/shiso 0.31.0 → 0.32.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/dist/index.css +19 -17
- package/dist/index.js +39 -38
- package/dist/index.mjs +53 -53
- package/package.json +1 -1
package/dist/index.css
CHANGED
|
@@ -1,39 +1,40 @@
|
|
|
1
1
|
/* virtual-css:css:e01d9571088b882a03b91eb2755da783 */
|
|
2
|
-
.
|
|
2
|
+
.PageLinks_links__ZWUxN {
|
|
3
3
|
position: sticky;
|
|
4
4
|
top: 30px;
|
|
5
5
|
height: max-content;
|
|
6
|
+
min-width: 240px;
|
|
6
7
|
}
|
|
7
|
-
.
|
|
8
|
+
.PageLinks_links__ZWUxN a.PageLinks_link__MTJmN {
|
|
8
9
|
display: block;
|
|
9
10
|
color: var(--font-color-muted);
|
|
10
11
|
font-size: var(--font-size);
|
|
11
12
|
text-wrap: nowrap;
|
|
12
13
|
text-decoration: none;
|
|
13
14
|
}
|
|
14
|
-
.
|
|
15
|
+
.PageLinks_links__ZWUxN a.PageLinks_link__MTJmN:hover {
|
|
15
16
|
color: var(--primary-color);
|
|
16
17
|
text-decoration: none;
|
|
17
18
|
}
|
|
18
|
-
.PageLinks_indent-
|
|
19
|
+
.PageLinks_indent-1__MGExM {
|
|
19
20
|
margin-left: 0;
|
|
20
21
|
}
|
|
21
|
-
.PageLinks_indent-
|
|
22
|
+
.PageLinks_indent-2__NDM3O {
|
|
22
23
|
margin-left: 0;
|
|
23
24
|
}
|
|
24
|
-
.PageLinks_indent-
|
|
25
|
+
.PageLinks_indent-3__YmJlN {
|
|
25
26
|
margin-left: 10px;
|
|
26
27
|
}
|
|
27
|
-
.PageLinks_indent-
|
|
28
|
+
.PageLinks_indent-4__OTNjM {
|
|
28
29
|
margin-left: 20px;
|
|
29
30
|
}
|
|
30
|
-
.PageLinks_indent-
|
|
31
|
+
.PageLinks_indent-5__YTIwM {
|
|
31
32
|
margin-left: 30px;
|
|
32
33
|
}
|
|
33
|
-
.PageLinks_indent-
|
|
34
|
+
.PageLinks_indent-6__MjQwY {
|
|
34
35
|
margin-left: 40px;
|
|
35
36
|
}
|
|
36
|
-
.
|
|
37
|
+
.PageLinks_links__ZWUxN a.PageLinks_selected__NDA0Y {
|
|
37
38
|
color: var(--primary-color);
|
|
38
39
|
}
|
|
39
40
|
|
|
@@ -96,36 +97,37 @@
|
|
|
96
97
|
}
|
|
97
98
|
|
|
98
99
|
/* virtual-css:css:62c31e195181c97259fa56b13d20ea6d */
|
|
99
|
-
.
|
|
100
|
+
.SideNav_nav__ZDkzM {
|
|
100
101
|
overflow-y: auto;
|
|
101
102
|
scrollbar-width: thin;
|
|
102
103
|
scrollbar-color: var(--border-color) var(--background-color);
|
|
103
104
|
scrollbar-gutter: stable;
|
|
105
|
+
min-width: 240px;
|
|
104
106
|
}
|
|
105
|
-
.
|
|
107
|
+
.SideNav_nav__ZDkzM.SideNav_sticky__YzM2M {
|
|
106
108
|
position: sticky;
|
|
107
109
|
top: 30px;
|
|
108
110
|
}
|
|
109
|
-
.
|
|
111
|
+
.SideNav_nav__ZDkzM .SideNav_item__ZWQwY {
|
|
110
112
|
color: var(--font-color-muted);
|
|
111
113
|
padding: 0;
|
|
112
114
|
border-radius: 0;
|
|
113
115
|
border-left: var(--border-size-1) solid var(--border-color);
|
|
114
116
|
}
|
|
115
|
-
.
|
|
117
|
+
.SideNav_nav__ZDkzM .SideNav_item__ZWQwY a {
|
|
116
118
|
color: currentColor;
|
|
117
119
|
width: 100%;
|
|
118
120
|
padding: var(--padding-y) var(--padding-x);
|
|
119
121
|
text-decoration: none;
|
|
120
122
|
}
|
|
121
|
-
.
|
|
123
|
+
.SideNav_nav__ZDkzM .SideNav_item__ZWQwY a:hover {
|
|
122
124
|
color: var(--primary-color);
|
|
123
125
|
}
|
|
124
|
-
.
|
|
126
|
+
.SideNav_nav__ZDkzM .SideNav_item__ZWQwY.SideNav_selected__OGVhZ {
|
|
125
127
|
color: var(--font-color);
|
|
126
128
|
border-color: var(--primary-color);
|
|
127
129
|
}
|
|
128
|
-
.
|
|
130
|
+
.SideNav_items__OWFkN header {
|
|
129
131
|
padding: var(--padding-y) 0;
|
|
130
132
|
}
|
|
131
133
|
|
package/dist/index.js
CHANGED
|
@@ -49,7 +49,7 @@ var import_react_zen = require("@umami/react-zen");
|
|
|
49
49
|
var import_classnames = __toESM(require("classnames"));
|
|
50
50
|
|
|
51
51
|
// css-modules:E:\dev\umami-shiso\src\components\PageLinks.module.css
|
|
52
|
-
var PageLinks_default = { "links": "
|
|
52
|
+
var PageLinks_default = { "links": "PageLinks_links__ZWUxN", "link": "PageLinks_link__MTJmN", "indent-1": "PageLinks_indent-1__MGExM", "indent-2": "PageLinks_indent-2__NDM3O", "indent-3": "PageLinks_indent-3__YmJlN", "indent-4": "PageLinks_indent-4__OTNjM", "indent-5": "PageLinks_indent-5__YTIwM", "indent-6": "PageLinks_indent-6__MjQwY", "selected": "PageLinks_selected__NDA0Y" };
|
|
53
53
|
|
|
54
54
|
// src/components/PageLinks.tsx
|
|
55
55
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -130,6 +130,14 @@ function Markdown({ code }) {
|
|
|
130
130
|
// src/components/Blog.tsx
|
|
131
131
|
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
132
132
|
function Blog({ title, description, code, author, date, image, anchors }) {
|
|
133
|
+
const linksDisplay = {
|
|
134
|
+
default: "none",
|
|
135
|
+
xs: "none",
|
|
136
|
+
sm: "none",
|
|
137
|
+
md: "none",
|
|
138
|
+
lg: "block",
|
|
139
|
+
xl: "block"
|
|
140
|
+
};
|
|
133
141
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_react_zen3.Column, { gap: "8", maxWidth: "900px", style: { margin: "0 auto" }, children: [
|
|
134
142
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_zen3.Box, { flexGrow: 1, children: title && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_zen3.Heading, { size: "1", as: "h1", align: "center", children: title }) }),
|
|
135
143
|
image && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_zen3.Box, { height: "480px", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_zen3.Image, { src: image, alt: title, objectFit: "cover", borderRadius: "3" }) }),
|
|
@@ -137,9 +145,9 @@ function Blog({ title, description, code, author, date, image, anchors }) {
|
|
|
137
145
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_zen3.Text, { children: author }),
|
|
138
146
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_zen3.Text, { children: date && (0, import_date_fns.format)(new Date(date), "PP") })
|
|
139
147
|
] }),
|
|
140
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_react_zen3.
|
|
148
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_react_zen3.Row, { gap: "6", children: [
|
|
141
149
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Markdown, { code }),
|
|
142
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(PageLinks, { items: anchors })
|
|
150
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(PageLinks, { display: linksDisplay, items: anchors })
|
|
143
151
|
] })
|
|
144
152
|
] });
|
|
145
153
|
}
|
|
@@ -155,7 +163,7 @@ var import_navigation = require("next/navigation");
|
|
|
155
163
|
var import_link = __toESM(require("next/link"));
|
|
156
164
|
|
|
157
165
|
// css-modules:E:\dev\umami-shiso\src\components\SideNav.module.css
|
|
158
|
-
var SideNav_default = { "nav": "
|
|
166
|
+
var SideNav_default = { "nav": "SideNav_nav__ZDkzM", "sticky": "SideNav_sticky__YzM2M", "item": "SideNav_item__ZWQwY", "selected": "SideNav_selected__OGVhZ", "items": "SideNav_items__OWFkN" };
|
|
159
167
|
|
|
160
168
|
// src/components/SideNav.tsx
|
|
161
169
|
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
@@ -320,38 +328,31 @@ function Docs({ content, config }) {
|
|
|
320
328
|
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_react_zen7.Box, { flexGrow: "1", children: [
|
|
321
329
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_react_zen7.Row, { display: menuDisplay, justifyContent: "flex-end", children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(MobileMenuButton, {}) }),
|
|
322
330
|
tabs && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(TopNav, { tabs }),
|
|
323
|
-
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
prev
|
|
349
|
-
}
|
|
350
|
-
),
|
|
351
|
-
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(PageLinks, { display: linksDisplay, items: anchors, style: { top } })
|
|
352
|
-
]
|
|
353
|
-
}
|
|
354
|
-
)
|
|
331
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_react_zen7.Row, { gap: "6", children: [
|
|
332
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
333
|
+
SideNav,
|
|
334
|
+
{
|
|
335
|
+
display: navDisplay,
|
|
336
|
+
tabs,
|
|
337
|
+
navigation,
|
|
338
|
+
style: { top },
|
|
339
|
+
isSticky: true,
|
|
340
|
+
autoHeight: true
|
|
341
|
+
}
|
|
342
|
+
),
|
|
343
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
344
|
+
DocContent,
|
|
345
|
+
{
|
|
346
|
+
section,
|
|
347
|
+
title: meta?.title,
|
|
348
|
+
description: meta?.description,
|
|
349
|
+
code,
|
|
350
|
+
next,
|
|
351
|
+
prev
|
|
352
|
+
}
|
|
353
|
+
),
|
|
354
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(PageLinks, { display: linksDisplay, items: anchors, style: { top } })
|
|
355
|
+
] })
|
|
355
356
|
] });
|
|
356
357
|
}
|
|
357
358
|
|
|
@@ -398,11 +399,11 @@ function Card({ title, description, date, author, url, image }) {
|
|
|
398
399
|
image && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Box, { height: "240px", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Image, { src: image, alt: title, objectFit: "cover" }) }),
|
|
399
400
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_react_zen9.Column, { padding: "6", gap: "4", children: [
|
|
400
401
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Heading, { size: "4", as: "header", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_link4.default, { href: url, children: title }) }),
|
|
401
|
-
/* @__PURE__ */ (0, import_jsx_runtime9.
|
|
402
|
-
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_react_zen9.Row, { justifyContent: "space-between", marginTop: "5", children: [
|
|
402
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_react_zen9.Row, { justifyContent: "space-between", children: [
|
|
403
403
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Text, { color: "muted", children: date && (0, import_date_fns2.format)(new Date(date), "PP") }),
|
|
404
404
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Text, { color: "muted", children: author })
|
|
405
405
|
] }),
|
|
406
|
+
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Box, { marginY: "5", as: "p", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Text, { size: "3", children: description }) }),
|
|
406
407
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Button, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_link4.default, { href: url, children: [
|
|
407
408
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Text, { children: "Read more" }),
|
|
408
409
|
/* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Icon, { children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_zen9.Icons.Arrow, {}) })
|
package/dist/index.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import "@umami/react-zen/styles.css";
|
|
|
5
5
|
import "highlight.js/styles/github-dark.css";
|
|
6
6
|
|
|
7
7
|
// src/components/Blog.tsx
|
|
8
|
-
import { Heading, Box as Box3, Text as Text2, Row, Column as Column2,
|
|
8
|
+
import { Heading, Box as Box3, Text as Text2, Row, Column as Column2, Image } from "@umami/react-zen";
|
|
9
9
|
import { format } from "date-fns";
|
|
10
10
|
|
|
11
11
|
// src/components/PageLinks.tsx
|
|
@@ -14,7 +14,7 @@ import { Column, Text, Box } from "@umami/react-zen";
|
|
|
14
14
|
import classNames from "classnames";
|
|
15
15
|
|
|
16
16
|
// css-modules:E:\dev\umami-shiso\src\components\PageLinks.module.css
|
|
17
|
-
var PageLinks_default = { "links": "
|
|
17
|
+
var PageLinks_default = { "links": "PageLinks_links__ZWUxN", "link": "PageLinks_link__MTJmN", "indent-1": "PageLinks_indent-1__MGExM", "indent-2": "PageLinks_indent-2__NDM3O", "indent-3": "PageLinks_indent-3__YmJlN", "indent-4": "PageLinks_indent-4__OTNjM", "indent-5": "PageLinks_indent-5__YTIwM", "indent-6": "PageLinks_indent-6__MjQwY", "selected": "PageLinks_selected__NDA0Y" };
|
|
18
18
|
|
|
19
19
|
// src/components/PageLinks.tsx
|
|
20
20
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -94,6 +94,14 @@ function Markdown({ code }) {
|
|
|
94
94
|
// src/components/Blog.tsx
|
|
95
95
|
import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
96
96
|
function Blog({ title, description, code, author, date, image, anchors }) {
|
|
97
|
+
const linksDisplay = {
|
|
98
|
+
default: "none",
|
|
99
|
+
xs: "none",
|
|
100
|
+
sm: "none",
|
|
101
|
+
md: "none",
|
|
102
|
+
lg: "block",
|
|
103
|
+
xl: "block"
|
|
104
|
+
};
|
|
97
105
|
return /* @__PURE__ */ jsxs3(Column2, { gap: "8", maxWidth: "900px", style: { margin: "0 auto" }, children: [
|
|
98
106
|
/* @__PURE__ */ jsx3(Box3, { flexGrow: 1, children: title && /* @__PURE__ */ jsx3(Heading, { size: "1", as: "h1", align: "center", children: title }) }),
|
|
99
107
|
image && /* @__PURE__ */ jsx3(Box3, { height: "480px", children: /* @__PURE__ */ jsx3(Image, { src: image, alt: title, objectFit: "cover", borderRadius: "3" }) }),
|
|
@@ -101,21 +109,20 @@ function Blog({ title, description, code, author, date, image, anchors }) {
|
|
|
101
109
|
/* @__PURE__ */ jsx3(Text2, { children: author }),
|
|
102
110
|
/* @__PURE__ */ jsx3(Text2, { children: date && format(new Date(date), "PP") })
|
|
103
111
|
] }),
|
|
104
|
-
/* @__PURE__ */ jsxs3(
|
|
112
|
+
/* @__PURE__ */ jsxs3(Row, { gap: "6", children: [
|
|
105
113
|
/* @__PURE__ */ jsx3(Markdown, { code }),
|
|
106
|
-
/* @__PURE__ */ jsx3(PageLinks, { items: anchors })
|
|
114
|
+
/* @__PURE__ */ jsx3(PageLinks, { display: linksDisplay, items: anchors })
|
|
107
115
|
] })
|
|
108
116
|
] });
|
|
109
117
|
}
|
|
110
118
|
|
|
111
119
|
// src/components/Docs.tsx
|
|
112
120
|
import {
|
|
113
|
-
Grid as Grid2,
|
|
114
121
|
Box as Box6,
|
|
115
122
|
Heading as Heading3,
|
|
116
123
|
Button,
|
|
117
|
-
Icon as
|
|
118
|
-
Icons as
|
|
124
|
+
Icon as Icon2,
|
|
125
|
+
Icons as Icons2,
|
|
119
126
|
Row as Row3,
|
|
120
127
|
Modal,
|
|
121
128
|
DialogTrigger,
|
|
@@ -131,7 +138,7 @@ import { usePathname } from "next/navigation";
|
|
|
131
138
|
import Link from "next/link";
|
|
132
139
|
|
|
133
140
|
// css-modules:E:\dev\umami-shiso\src\components\SideNav.module.css
|
|
134
|
-
var SideNav_default = { "nav": "
|
|
141
|
+
var SideNav_default = { "nav": "SideNav_nav__ZDkzM", "sticky": "SideNav_sticky__YzM2M", "item": "SideNav_item__ZWQwY", "selected": "SideNav_selected__OGVhZ", "items": "SideNav_items__OWFkN" };
|
|
135
142
|
|
|
136
143
|
// src/components/SideNav.tsx
|
|
137
144
|
import { jsx as jsx4 } from "react/jsx-runtime";
|
|
@@ -196,7 +203,7 @@ function TopNav({ tabs }) {
|
|
|
196
203
|
}
|
|
197
204
|
|
|
198
205
|
// src/components/DocContent.tsx
|
|
199
|
-
import { Heading as Heading2, Box as Box5, Text as Text3, Row as Row2, Icon
|
|
206
|
+
import { Heading as Heading2, Box as Box5, Text as Text3, Row as Row2, Icon, Icons } from "@umami/react-zen";
|
|
200
207
|
import Link3 from "next/link";
|
|
201
208
|
import { jsx as jsx6, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
202
209
|
function DocContent({ section, title, description, code, next, prev }) {
|
|
@@ -220,9 +227,9 @@ var NavigationButton = ({
|
|
|
220
227
|
return /* @__PURE__ */ jsx6(Box5, {});
|
|
221
228
|
}
|
|
222
229
|
return /* @__PURE__ */ jsx6(Link3, { href: url, children: /* @__PURE__ */ jsxs4(Row2, { alignItems: "center", gap: "3", marginY: "3", children: [
|
|
223
|
-
isPrev && /* @__PURE__ */ jsx6(
|
|
230
|
+
isPrev && /* @__PURE__ */ jsx6(Icon, { size: "sm", rotate: 180, children: /* @__PURE__ */ jsx6(Icons.Chevron, {}) }),
|
|
224
231
|
/* @__PURE__ */ jsx6(Text3, { size: "3", weight: "bold", children: label }),
|
|
225
|
-
!isPrev && /* @__PURE__ */ jsx6(
|
|
232
|
+
!isPrev && /* @__PURE__ */ jsx6(Icon, { size: "sm", children: /* @__PURE__ */ jsx6(Icons.Chevron, {}) })
|
|
226
233
|
] }) });
|
|
227
234
|
};
|
|
228
235
|
|
|
@@ -283,12 +290,12 @@ function Docs({ content, config }) {
|
|
|
283
290
|
};
|
|
284
291
|
const MobileMenuButton = () => /* @__PURE__ */ jsxs5(DialogTrigger, { children: [
|
|
285
292
|
/* @__PURE__ */ jsxs5(Button, { children: [
|
|
286
|
-
/* @__PURE__ */ jsx7(
|
|
293
|
+
/* @__PURE__ */ jsx7(Icon2, { children: /* @__PURE__ */ jsx7(Icons2.Menu, {}) }),
|
|
287
294
|
/* @__PURE__ */ jsx7(Text4, { children: "Menu" })
|
|
288
295
|
] }),
|
|
289
296
|
/* @__PURE__ */ jsx7(Modal, { position: "bottom", offset: "40px", children: /* @__PURE__ */ jsx7(Dialog, { variant: "sheet", children: ({ close }) => {
|
|
290
297
|
return /* @__PURE__ */ jsxs5(Fragment, { children: [
|
|
291
|
-
/* @__PURE__ */ jsx7(Row3, { justifyContent: "flex-end", children: /* @__PURE__ */ jsx7(Button, { onPress: () => close(), variant: "quiet", children: /* @__PURE__ */ jsx7(
|
|
298
|
+
/* @__PURE__ */ jsx7(Row3, { justifyContent: "flex-end", children: /* @__PURE__ */ jsx7(Button, { onPress: () => close(), variant: "quiet", children: /* @__PURE__ */ jsx7(Icon2, { size: "sm", children: /* @__PURE__ */ jsx7(Icons2.Close, {}) }) }) }),
|
|
292
299
|
/* @__PURE__ */ jsx7(Box6, { height: "100%", overflow: "auto", children: /* @__PURE__ */ jsx7(SideNav, { tabs, navigation }) })
|
|
293
300
|
] });
|
|
294
301
|
} }) })
|
|
@@ -296,38 +303,31 @@ function Docs({ content, config }) {
|
|
|
296
303
|
return /* @__PURE__ */ jsxs5(Box6, { flexGrow: "1", children: [
|
|
297
304
|
/* @__PURE__ */ jsx7(Row3, { display: menuDisplay, justifyContent: "flex-end", children: /* @__PURE__ */ jsx7(MobileMenuButton, {}) }),
|
|
298
305
|
tabs && /* @__PURE__ */ jsx7(TopNav, { tabs }),
|
|
299
|
-
/* @__PURE__ */ jsxs5(
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
prev
|
|
325
|
-
}
|
|
326
|
-
),
|
|
327
|
-
/* @__PURE__ */ jsx7(PageLinks, { display: linksDisplay, items: anchors, style: { top } })
|
|
328
|
-
]
|
|
329
|
-
}
|
|
330
|
-
)
|
|
306
|
+
/* @__PURE__ */ jsxs5(Row3, { gap: "6", children: [
|
|
307
|
+
/* @__PURE__ */ jsx7(
|
|
308
|
+
SideNav,
|
|
309
|
+
{
|
|
310
|
+
display: navDisplay,
|
|
311
|
+
tabs,
|
|
312
|
+
navigation,
|
|
313
|
+
style: { top },
|
|
314
|
+
isSticky: true,
|
|
315
|
+
autoHeight: true
|
|
316
|
+
}
|
|
317
|
+
),
|
|
318
|
+
/* @__PURE__ */ jsx7(
|
|
319
|
+
DocContent,
|
|
320
|
+
{
|
|
321
|
+
section,
|
|
322
|
+
title: meta?.title,
|
|
323
|
+
description: meta?.description,
|
|
324
|
+
code,
|
|
325
|
+
next,
|
|
326
|
+
prev
|
|
327
|
+
}
|
|
328
|
+
),
|
|
329
|
+
/* @__PURE__ */ jsx7(PageLinks, { display: linksDisplay, items: anchors, style: { top } })
|
|
330
|
+
] })
|
|
331
331
|
] });
|
|
332
332
|
}
|
|
333
333
|
|
|
@@ -338,7 +338,7 @@ import { Code } from "@umami/react-zen";
|
|
|
338
338
|
|
|
339
339
|
// src/components/CodeBlock.tsx
|
|
340
340
|
import { useState as useState3, useRef } from "react";
|
|
341
|
-
import { Icon as
|
|
341
|
+
import { Icon as Icon3, Icons as Icons3 } from "@umami/react-zen";
|
|
342
342
|
|
|
343
343
|
// css-modules:E:\dev\umami-shiso\src\components\CodeBlock.module.css
|
|
344
344
|
var CodeBlock_default = { "container": "CodeBlock_container__ZTkxY", "button": "CodeBlock_button__MmZkO", "copy": "CodeBlock_copy__M2I0N", "check": "CodeBlock_check__MjkzY" };
|
|
@@ -357,15 +357,15 @@ function CodeBlock(props) {
|
|
|
357
357
|
};
|
|
358
358
|
return /* @__PURE__ */ jsxs6("pre", { ref: textInput, className: CodeBlock_default.container, children: [
|
|
359
359
|
props.children,
|
|
360
|
-
/* @__PURE__ */ jsx8("button", { "aria-label": "Copy code", className: CodeBlock_default.button, onClick: handleCopy, children: /* @__PURE__ */ jsx8(
|
|
360
|
+
/* @__PURE__ */ jsx8("button", { "aria-label": "Copy code", className: CodeBlock_default.button, onClick: handleCopy, children: /* @__PURE__ */ jsx8(Icon3, { size: "sm", className: copied ? CodeBlock_default.check : CodeBlock_default.copy, children: copied ? /* @__PURE__ */ jsx8(Icons3.Check, {}) : /* @__PURE__ */ jsx8(Icons3.Copy, {}) }) })
|
|
361
361
|
] });
|
|
362
362
|
}
|
|
363
363
|
|
|
364
364
|
// src/components/Blogs.tsx
|
|
365
|
-
import { Grid
|
|
365
|
+
import { Grid } from "@umami/react-zen";
|
|
366
366
|
|
|
367
367
|
// src/components/Card.tsx
|
|
368
|
-
import { Box as Box7, Image as Image2, Column as Column3, Row as Row4, Heading as Heading4, Text as Text5, Button as Button2, Icon as
|
|
368
|
+
import { Box as Box7, Image as Image2, Column as Column3, Row as Row4, Heading as Heading4, Text as Text5, Button as Button2, Icon as Icon4, Icons as Icons4 } from "@umami/react-zen";
|
|
369
369
|
import Link4 from "next/link";
|
|
370
370
|
import { format as format2 } from "date-fns";
|
|
371
371
|
import { jsx as jsx9, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
@@ -374,14 +374,14 @@ function Card({ title, description, date, author, url, image }) {
|
|
|
374
374
|
image && /* @__PURE__ */ jsx9(Box7, { height: "240px", children: /* @__PURE__ */ jsx9(Image2, { src: image, alt: title, objectFit: "cover" }) }),
|
|
375
375
|
/* @__PURE__ */ jsxs7(Column3, { padding: "6", gap: "4", children: [
|
|
376
376
|
/* @__PURE__ */ jsx9(Heading4, { size: "4", as: "header", children: /* @__PURE__ */ jsx9(Link4, { href: url, children: title }) }),
|
|
377
|
-
/* @__PURE__ */
|
|
378
|
-
/* @__PURE__ */ jsxs7(Row4, { justifyContent: "space-between", marginTop: "5", children: [
|
|
377
|
+
/* @__PURE__ */ jsxs7(Row4, { justifyContent: "space-between", children: [
|
|
379
378
|
/* @__PURE__ */ jsx9(Text5, { color: "muted", children: date && format2(new Date(date), "PP") }),
|
|
380
379
|
/* @__PURE__ */ jsx9(Text5, { color: "muted", children: author })
|
|
381
380
|
] }),
|
|
381
|
+
/* @__PURE__ */ jsx9(Box7, { marginY: "5", as: "p", children: /* @__PURE__ */ jsx9(Text5, { size: "3", children: description }) }),
|
|
382
382
|
/* @__PURE__ */ jsx9(Button2, { asChild: true, children: /* @__PURE__ */ jsxs7(Link4, { href: url, children: [
|
|
383
383
|
/* @__PURE__ */ jsx9(Text5, { children: "Read more" }),
|
|
384
|
-
/* @__PURE__ */ jsx9(
|
|
384
|
+
/* @__PURE__ */ jsx9(Icon4, { children: /* @__PURE__ */ jsx9(Icons4.Arrow, {}) })
|
|
385
385
|
] }) })
|
|
386
386
|
] })
|
|
387
387
|
] });
|
|
@@ -395,7 +395,7 @@ function Blogs({ content, config }) {
|
|
|
395
395
|
return /* @__PURE__ */ jsx10(Blog, { ...meta, code, anchors });
|
|
396
396
|
}
|
|
397
397
|
console.log({ content });
|
|
398
|
-
return /* @__PURE__ */ jsx10(
|
|
398
|
+
return /* @__PURE__ */ jsx10(Grid, { gap: "5", columns: "repeat(auto-fit, minmax(400px, 1fr)", children: content?.sort((a, b) => new Date(b.meta.date).getTime() - new Date(a.meta.date).getTime()).map(({ meta, slug }) => /* @__PURE__ */ jsx10(Card, { url: `/blog/${slug}`, ...meta }, slug)) });
|
|
399
399
|
}
|
|
400
400
|
|
|
401
401
|
// src/components/Shiso.tsx
|