Skip to content
This repository was archived by the owner on Mar 15, 2025. It is now read-only.

Commit 3d4e190

Browse files
committed
layoutをcssで定義できる様になった
Pandacssでも書ける+Config.jsの意味はわからん
1 parent 9e0997f commit 3d4e190

13 files changed

+252
-23
lines changed
8.29 KB
Loading
Loading

articles/test.md

-13
This file was deleted.

articles/uploaded/test.md

+68
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
---
2+
tags:
3+
- アニメ
4+
- ゲーム
5+
excalidraw-open-md: false
6+
cssclasses:
7+
---
8+
9+
Blogを表示できたら成功。
10+
11+
# アニメ
12+
13+
![vike-square-gradient.yySbJPh3.svg](..\assets\vike-square-gradient.yySbJPh3.svg)
14+
15+
![Test20240406233811738.jpg](../assets/Test20240406233811738.jpg)
16+
17+
# [笹川真生 - 日本の九月の気層です / Mao Sasagawa - Japan's September Air Layer](https://www.youtube.com/watch?v=4-3Ogspng1I&list=RDRcDBofJ-_oA&index=12)
18+
19+
<iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/4-3Ogspng1I" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
20+
21+
Markdownの構文一覧
22+
23+
> 引用
24+
> > 引用のネスト
25+
> あふぁds
26+
27+
**bold**
28+
29+
*itaric*
30+
31+
`code`
32+
33+
~~cancel~~
34+
35+
---
36+
37+
# タイトル
38+
39+
| test | table |
40+
| ---- | --- |
41+
| row | aaa |
42+
43+
- list
44+
- nest
45+
- aaa
46+
47+
1. number
48+
2. test
49+
1. i
50+
2. ii
51+
3. iii
52+
4. iv
53+
5. v
54+
55+
codeblock
56+
57+
``` typescript
58+
const [number,setNumber] =useState(0)
59+
60+
export default funciton home ():ReactElement {
61+
return(
62+
<h1> home page </h1>
63+
{number}
64+
)
65+
}
66+
```
67+
68+
LinkCard

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@
2525
"react-dom": "^18.2.0",
2626
"react-router-dom": "^6.22.3",
2727
"recharts": "2",
28-
"vike": "^0.4.168"
28+
"vike": "^0.4.168",
29+
"vike-react": "^0.4.6"
2930
},
3031
"devDependencies": {
3132
"@iconify/react": "^4.1.1",

src/global.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
/* @layer reset, base, tokens, recipes, utilities; */
1+
@layer reset, base, tokens, recipes, utilities;

src/pages/blogs/+Layout.tsx

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { type ReactElement } from "react";
2+
import { styled as p } from "@panda/jsx";
3+
import "./Layout.css";
4+
5+
6+
7+
function Layout({ children }: { children: ReactElement }): ReactElement {
8+
return (
9+
<p.div
10+
fontFamily="Noto Sans JP, sans-serif"
11+
>
12+
{children}
13+
</p.div>
14+
);
15+
}
16+
export default Layout;

src/pages/blogs/+Page.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { type ReactElement } from "react";
22
import { styled as p } from "@panda/jsx";
3-
import Test from "../../../articles/test.md";
3+
import Test from "../../../articles/uploaded/test.md";
44

55
export default function Blogs(): ReactElement {
66
return (

src/pages/blogs/+config.js

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import vikeReact from "vike-react/config";
2+
3+
export default {
4+
// Install vike-react.
5+
// In technical terms: inherit the configuration set by `vike-react/config`.
6+
extends: vikeReact,
7+
};

src/pages/blogs/@id/index.tsx

Whitespace-only changes.

src/pages/blogs/Layout.css

+68
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
button {
2+
background-color: aqua;
3+
}
4+
5+
html body h1,
6+
html body h2,
7+
html body h3,
8+
html body h4 {
9+
font-family:
10+
Noto Sans JP,
11+
sans-serif;
12+
color: #586e75;
13+
}
14+
p,
15+
li,
16+
td {
17+
font-family:
18+
Noto Sans JP,
19+
sans-serif;
20+
}
21+
html body table th {
22+
background-color: #93a1a1;
23+
color: #eee8d5;
24+
}
25+
26+
html body table tr:nth-child(even) {
27+
background-color: #eee8d5;
28+
}
29+
30+
h1 {
31+
color: inherit;
32+
padding-bottom: 0.3em;
33+
border-bottom: 1px solid #eee;
34+
font-size: 2em;
35+
font-weight: 600;
36+
}
37+
h2 {
38+
color: inherit;
39+
padding-bottom: 0.3em;
40+
border-bottom: 1px solid #eee;
41+
font-size: 1.5em;
42+
}
43+
h3 {
44+
color: inherit;
45+
font-size: 1.25em;
46+
}
47+
h4 {
48+
color: inherit;
49+
font-size: 1em;
50+
}
51+
code {
52+
font-family: Menlo, Monaco, Consolas, monospace;
53+
}
54+
pre {
55+
font-family: Menlo, Monaco, Consolas, monospace;
56+
background-color: #f8f8f8;
57+
padding: 1em;
58+
border-radius: 0.3em;
59+
overflow-x: auto;
60+
}
61+
pre code {
62+
font-family: Menlo, Monaco, Consolas, monospace;
63+
}
64+
ul li {
65+
list-style-type: disc;
66+
}
67+
68+
@layer reset, base, tokens, recipes, utilities;

src/pages/blogs/ambient.d.ts

-6
This file was deleted.

yarn.lock

+22-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
resolved "https://registry.yarnpkg.com/@brillout/import/-/import-0.2.3.tgz#98f04656692b35d70664cc917f3cb0e8f74942dd"
2525
integrity sha512-1T8WlD75eeFSMrptGy8jiLHmfHgMmSjWvLOIUvHmSVZt+6k0eQqYUoK4KbmE4T9pVLIfxvZSOm2D68VEqKRHRw==
2626

27-
"@brillout/json-serializer@^0.5.8":
27+
"@brillout/json-serializer@^0.5.1", "@brillout/json-serializer@^0.5.8":
2828
version "0.5.8"
2929
resolved "https://registry.yarnpkg.com/@brillout/json-serializer/-/json-serializer-0.5.8.tgz#ffb8e99fb50ec27cd6df59843dd43b687fb7901b"
3030
integrity sha512-vEuXw30ok+mJfJutOxXKBb4lBJ0HymA7lev9PcYK6W/hzjhCTPk9Bdk85HrcNcKZWRQiwoWtw0F2Di4TRJ7ssQ==
@@ -3023,6 +3023,11 @@ isarray@^2.0.5:
30233023
resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.5.tgz#8af1e4c1221244cc62459faf38940d4e644a5723"
30243024
integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==
30253025

3026+
3027+
version "1.2.0"
3028+
resolved "https://registry.yarnpkg.com/isbot-fast/-/isbot-fast-1.2.0.tgz#ef0ef1d5db34eb60777250ae26fceb72b94153e2"
3029+
integrity sha512-twjuQzy2gKMDVfKGQyQqrx6Uy4opu/fiVUTTpdqtFsd7OQijIp5oXvb27n5EemYXaijh5fomndJt/SPRLsEdSg==
3030+
30263031
isexe@^2.0.0:
30273032
version "2.0.0"
30283033
resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10"
@@ -4255,6 +4260,15 @@ react-smooth@^4.0.0:
42554260
prop-types "^15.8.1"
42564261
react-transition-group "^4.4.5"
42574262

4263+
react-streaming@^0.3.22:
4264+
version "0.3.24"
4265+
resolved "https://registry.yarnpkg.com/react-streaming/-/react-streaming-0.3.24.tgz#3a4d98afeeb78a31391def3d06828f1118523be1"
4266+
integrity sha512-sKqhgFJswZR3yFDmtwKYVZMJB7nkjQ0r4BHEQTZHLQzM5Ro8Bv4F/kgygdYfivncOu+H6apUugK2bL/WB7z5qQ==
4267+
dependencies:
4268+
"@brillout/import" "^0.2.3"
4269+
"@brillout/json-serializer" "^0.5.1"
4270+
isbot-fast "1.2.0"
4271+
42584272
react-style-singleton@^2.2.1:
42594273
version "2.2.1"
42604274
resolved "https://registry.yarnpkg.com/react-style-singleton/-/react-style-singleton-2.2.1.tgz#f99e420492b2d8f34d38308ff660b60d0b1205b4"
@@ -5015,6 +5029,13 @@ victory-vendor@^36.6.8:
50155029
d3-time "^3.0.0"
50165030
d3-timer "^3.0.1"
50175031

5032+
vike-react@^0.4.6:
5033+
version "0.4.6"
5034+
resolved "https://registry.yarnpkg.com/vike-react/-/vike-react-0.4.6.tgz#509e5342809f49b9729346f646b57928ac4ce790"
5035+
integrity sha512-CjfhmPX/OtQhMaFCC8UzPr2O4RlB7FlRX3EDa/EP3q7wRRdb5AGVkkUkx+NNj7bxQiMHlR2+njiKrr0x5ITEUw==
5036+
dependencies:
5037+
react-streaming "^0.3.22"
5038+
50185039
vike@^0.4.168:
50195040
version "0.4.168"
50205041
resolved "https://registry.yarnpkg.com/vike/-/vike-0.4.168.tgz#7837fd937c650510db48c3e6f2e94edc49a0caa2"

0 commit comments

Comments
 (0)