1
1
---
2
2
import Layout from ' ../layouts/Layout.astro' ;
3
3
import Card from ' ../components/Card.astro' ;
4
+ import { Image } from ' astro:assets' ;
5
+ import icon from ' ../assets/icon.jpg' ;
6
+ import icon2 from ' ../assets/2331964-2.output.png' ;
4
7
import RustCoder from ' ../assets/RustCoder.png' ;
5
8
---
6
9
@@ -17,8 +20,17 @@ import RustCoder from '../assets/RustCoder.png';
17
20
</Card >
18
21
<Card >
19
22
<h2 >アイコン</h2 >
20
- <img src =" favicon.jpg" />
21
- <p ><a href =" https://x.com/Cafrette" >@Cafrette</a > さんに書いていただきました。</p >
23
+ <p >(クリック/タップで拡大)</p >
24
+ <Image id =" icon" class =" image" src ={ icon } alt =" とがのアイコン(Cafrette さん)" width =" 144" />
25
+ <dialog id =" iconDialog" >
26
+ <Image src =" /icon.jpg" alt =" とがのアイコン" width =" 1080" height =" 1080" />
27
+ </dialog >
28
+ <p >Cafrette さんに描いていただきました。</p >
29
+ <Image id =" icon2" class =" image" src ={ icon2 } alt =" とがのアイコン(ふいしゆさん)" width =" 144" />
30
+ <dialog id =" icon2Dialog" >
31
+ <Image src =" /2331964-2.output.png" alt =" とがのアイコン" width =" 400" height =" 400" />
32
+ </dialog >
33
+ <p >ふいしゆさんに描いていただきました。</p >
22
34
</Card >
23
35
<Card >
24
36
<h2 >OSS Contribution</h2 >
@@ -35,7 +47,10 @@ import RustCoder from '../assets/RustCoder.png';
35
47
<li >ICPC 2021 … アジア横浜地区大会出場(<b >t</b >oxic)</li >
36
48
<li >ICPC 2022 … アジア横浜地区大会出場(h<b >a</b >unting)</li >
37
49
</ul >
38
- <img src ={ RustCoder .src } alt =" とが『RustCoder ―― AtCoder と Rust で始める競技プログラミング入門』の表紙" />
50
+ <Image id =" rustCoder" src ={ RustCoder } class =" image" alt =" とが『RustCoder ―― AtCoder と Rust で始める競技プログラミング入門』の表紙" width =" 144" />
51
+ <dialog id =" rustCoderDialog" >
52
+ <Image src =" /RustCoder.png" alt =" とが『RustCoder ―― AtCoder と Rust で始める競技プログラミング入門』の表紙" width =" 1043" height =" 1459" />
53
+ </dialog >
39
54
<p >『RustCoder――AtCoder と Rust で始める競技プログラミング入門』は<a href =" https://zenn.dev/toga/books/rust-atcoder/viewer/intro" >終了しました</a >。</p >
40
55
</Card >
41
56
<Card >
@@ -68,6 +83,15 @@ import RustCoder from '../assets/RustCoder.png';
68
83
</footer >
69
84
</Layout >
70
85
86
+ <script >
87
+ icon.addEventListener("click", () => iconDialog.showModal());
88
+ iconDialog.addEventListener("click", () => iconDialog.close());
89
+ icon2.addEventListener("click", () => icon2Dialog.showModal());
90
+ icon2Dialog.addEventListener("click", () => icon2Dialog.close());
91
+ rustCoder.addEventListener("click", () => rustCoderDialog.showModal());
92
+ rustCoderDialog.addEventListener("click", () => rustCoderDialog.close());
93
+ </script >
94
+
71
95
<style >
72
96
body {
73
97
font-family: "Noto Sans CJK JP", sans-serif;
@@ -110,9 +134,17 @@ import RustCoder from '../assets/RustCoder.png';
110
134
}
111
135
}
112
136
137
+ .image {
138
+ width: 30%;
139
+ max-width: 144px;
140
+ cursor: pointer;
141
+ }
142
+ dialog {
143
+ text-align: center;
144
+ }
113
145
img {
114
- width: 60 %;
115
- max-width: 270px ;
146
+ width: 100 %;
147
+ height: auto ;
116
148
}
117
149
118
150
h2, p {
0 commit comments