Skip to content

Commit 85b7d6b

Browse files
committed
feat: update website ui to be modern
1 parent 6aa0aed commit 85b7d6b

19 files changed

+1208
-171
lines changed

theme/css/chrome.css

+654
Large diffs are not rendered by default.

theme/css/general.css

+77-32
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
}
1010

1111
html {
12-
font-family: "Open Sans", sans-serif;
1312
color: var(--fg);
1413
background-color: var(--bg);
1514
text-size-adjust: none;
@@ -39,26 +38,45 @@ main {
3938
}
4039

4140
/* Don't change font size in headers. */
42-
h1 code, h2 code, h3 code, h4 code, h5 code, h6 code {
41+
h1 code,
42+
h2 code,
43+
h3 code,
44+
h4 code,
45+
h5 code,
46+
h6 code {
4347
font-size: unset;
4448
}
4549

46-
.left { float: left; }
47-
.right { float: right; }
48-
.boring { opacity: 0.6; }
49-
.hide-boring .boring { display: none; }
50-
.hidden { display: none !important; }
50+
.left {
51+
float: left;
52+
}
53+
54+
.right {
55+
float: right;
56+
}
57+
58+
.boring {
59+
opacity: 0.6;
60+
}
5161

52-
h1 > a {
62+
.hide-boring .boring {
63+
display: none;
64+
}
65+
66+
.hidden {
67+
display: none !important;
68+
}
69+
70+
h1>a {
5371
background-image: linear-gradient(to right, rgb(245 158 11) 0%, rgb(239 68 68) 100%);
5472
-webkit-background-clip: text;
5573
background-clip: text;
5674
color: transparent !important;
5775
}
5876

59-
.header + .header h3,
60-
.header + .header h4,
61-
.header + .header h5 {
77+
.header+.header h3,
78+
.header+.header h4,
79+
.header+.header h5 {
6280
margin-block-start: 1em;
6381
}
6482

@@ -86,39 +104,56 @@ h6:target::before {
86104
.page {
87105
outline: 0;
88106
padding: 0 var(--page-padding);
89-
margin-block-start: calc(0px - var(--menu-bar-height)); /* Compensate for the #menu-bar-hover-placeholder */
107+
margin-block-start: calc(0px - var(--menu-bar-height));
108+
/* Compensate for the #menu-bar-hover-placeholder */
90109
}
110+
91111
.page-wrapper {
92112
box-sizing: border-box;
93113
background-color: var(--bg);
94114
}
95-
.no-js .page-wrapper,
96-
.js:not(.sidebar-resizing) .page-wrapper {
97-
transition: margin-left 0.3s ease, transform 0.3s ease; /* Animation: slide away */
98-
}
99-
[dir=rtl] .js:not(.sidebar-resizing) .page-wrapper {
100-
transition: margin-right 0.3s ease, transform 0.3s ease; /* Animation: slide away */
101-
}
102115

103116
.content {
104117
overflow-y: auto;
105118
padding: 0 5px 50px 5px;
106119
}
120+
107121
.content main {
108122
margin-inline-start: auto;
109123
margin-inline-end: auto;
110124
max-width: var(--content-max-width);
111125
}
112-
.content p { line-height: 1.45em; }
113-
.content ol { line-height: 1.45em; }
114-
.content ul { line-height: 1.45em; }
115-
.content a { text-decoration: none; }
116-
.content a:hover { text-decoration: underline; }
117-
.content img, .content video { max-width: 100%; }
126+
127+
.content p {
128+
line-height: 1.45em;
129+
}
130+
131+
.content ol {
132+
line-height: 1.45em;
133+
}
134+
135+
.content ul {
136+
line-height: 1.45em;
137+
}
138+
139+
.content a {
140+
text-decoration: none;
141+
}
142+
143+
.content a:hover {
144+
text-decoration: underline;
145+
}
146+
147+
.content img,
148+
.content video {
149+
max-width: 100%;
150+
}
151+
118152
.content .header:link,
119153
.content .header:visited {
120154
color: var(--fg);
121155
}
156+
122157
.content .header:link,
123158
.content .header:visited:hover {
124159
text-decoration: none;
@@ -128,29 +163,34 @@ table {
128163
margin: 0 auto;
129164
border-collapse: collapse;
130165
}
166+
131167
table td {
132-
padding: 3px 20px;
168+
padding: 1rem 2rem;
133169
border: 1px var(--table-border-color) solid;
134170
}
171+
135172
table thead {
136173
background: var(--table-header-bg);
137174
}
175+
138176
table thead td {
139177
font-weight: 700;
140178
border: none;
141179
}
180+
142181
table thead th {
143-
padding: 3px 20px;
182+
padding: 1rem 2rem;
144183
}
184+
145185
table thead tr {
146186
border: 1px var(--table-header-bg) solid;
147187
}
188+
148189
/* Alternate background colors for rows */
149190
table tbody tr:nth-child(2n) {
150191
background: var(--table-alternate-bg);
151192
}
152193

153-
154194
blockquote {
155195
margin: 20px 0;
156196
padding: 0 20px;
@@ -196,14 +236,16 @@ kbd {
196236
vertical-align: middle;
197237
}
198238

199-
:not(.footnote-definition) + .footnote-definition,
200-
.footnote-definition + :not(.footnote-definition) {
239+
:not(.footnote-definition)+.footnote-definition,
240+
.footnote-definition+ :not(.footnote-definition) {
201241
margin-block-start: 2em;
202242
}
243+
203244
.footnote-definition {
204245
font-size: 0.9em;
205246
margin: 0.5em 0;
206247
}
248+
207249
.footnote-definition p {
208250
display: inline;
209251
}
@@ -213,8 +255,10 @@ kbd {
213255
visibility: hidden;
214256
color: #fff;
215257
background-color: #333;
216-
transform: translateX(-50%); /* Center by moving tooltip 50% of its width left */
217-
left: -8px; /* Half of the width of the icon */
258+
transform: translateX(-50%);
259+
/* Center by moving tooltip 50% of its width left */
260+
left: -8px;
261+
/* Half of the width of the icon */
218262
top: -35px;
219263
font-size: 0.8em;
220264
text-align: center;
@@ -223,6 +267,7 @@ kbd {
223267
margin: 5px;
224268
z-index: 1000;
225269
}
270+
226271
.tooltipped .tooltiptext {
227272
visibility: visible;
228273
}

theme/css/variables.css

+3-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,9 @@
66
--content-max-width: 750px;
77
--menu-bar-height: 50px;
88
--mono-font: "Source Code Pro", Consolas, "Ubuntu Mono", Menlo, "DejaVu Sans Mono", monospace, monospace;
9-
--code-font-size: 0.875em /* please adjust the ace font size accordingly in editor.js */
9+
--code-font-size: 0.875em
10+
/* please adjust the ace font size accordingly in editor.js */
11+
;
1012
}
1113

1214
.hljs {

theme/fonts/Rubik-Black.ttf

203 KB
Binary file not shown.

theme/fonts/Rubik-BlackItalic.ttf

202 KB
Binary file not shown.

theme/fonts/Rubik-Bold.ttf

203 KB
Binary file not shown.

theme/fonts/Rubik-BoldItalic.ttf

202 KB
Binary file not shown.

theme/fonts/Rubik-ExtraBold.ttf

203 KB
Binary file not shown.

theme/fonts/Rubik-ExtraBoldItalic.ttf

202 KB
Binary file not shown.

theme/fonts/Rubik-Italic.ttf

202 KB
Binary file not shown.

theme/fonts/Rubik-Light.ttf

202 KB
Binary file not shown.

theme/fonts/Rubik-LightItalic.ttf

201 KB
Binary file not shown.

theme/fonts/Rubik-Medium.ttf

203 KB
Binary file not shown.

theme/fonts/Rubik-MediumItalic.ttf

202 KB
Binary file not shown.

theme/fonts/Rubik-Regular.ttf

203 KB
Binary file not shown.

theme/fonts/Rubik-SemiBold.ttf

203 KB
Binary file not shown.

theme/fonts/Rubik-SemiBoldItalic.ttf

202 KB
Binary file not shown.

theme/fonts/fonts.css

+98
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
@font-face {
2+
font-family: 'Rubik';
3+
src: url(/fonts/Rubik-Light.ttf) format('truetype');
4+
font-weight: 300;
5+
font-style: normal;
6+
font-display: swap;
7+
}
8+
@font-face {
9+
font-family: 'Rubik';
10+
src: url(/fonts/Rubik-Light.ttf) format('truetype');
11+
font-weight: 300;
12+
font-style: italic;
13+
font-display: swap;
14+
}
15+
@font-face {
16+
font-family: 'Rubik';
17+
src: url(/fonts/Rubik-Regular.ttf) format('truetype');
18+
font-weight: 400;
19+
font-style: normal;
20+
font-display: swap;
21+
}
22+
@font-face {
23+
font-family: 'Rubik';
24+
src: url(/fonts/Rubik-Regular.ttf) format('truetype');
25+
font-weight: 400;
26+
font-style: italic;
27+
font-display: swap;
28+
}
29+
@font-face {
30+
font-family: 'Rubik';
31+
src: url(/fonts/Rubik-Medium.ttf) format('truetype');
32+
font-weight: 500;
33+
font-style: normal;
34+
font-display: swap;
35+
}
36+
@font-face {
37+
font-family: 'Rubik';
38+
src: url(/fonts/Rubik-Medium.ttf) format('truetype');
39+
font-weight: 500;
40+
font-style: italic;
41+
font-display: swap;
42+
}
43+
@font-face {
44+
font-family: 'Rubik';
45+
src: url(/fonts/Rubik-SemiBold.ttf) format('truetype');
46+
font-weight: 600;
47+
font-style: normal;
48+
font-display: swap;
49+
}
50+
@font-face {
51+
font-family: 'Rubik';
52+
src: url(/fonts/Rubik-SemiBold.ttf) format('truetype');
53+
font-weight: 600;
54+
font-style: italic;
55+
font-display: swap;
56+
}
57+
@font-face {
58+
font-family: 'Rubik';
59+
src: url(/fonts/Rubik-Bold.ttf) format('truetype');
60+
font-weight: 700;
61+
font-style: normal;
62+
font-display: swap;
63+
}
64+
@font-face {
65+
font-family: 'Rubik';
66+
src: url(/fonts/Rubik-Bold.ttf) format('truetype');
67+
font-weight: 700;
68+
font-style: italic;
69+
font-display: swap;
70+
}
71+
@font-face {
72+
font-family: 'Rubik';
73+
src: url(/fonts/Rubik-ExtraBold.ttf) format('truetype');
74+
font-weight: 800;
75+
font-style: normal;
76+
font-display: swap;
77+
}
78+
@font-face {
79+
font-family: 'Rubik';
80+
src: url(/fonts/Rubik-ExtraBold.ttf) format('truetype');
81+
font-weight: 800;
82+
font-style: italic;
83+
font-display: swap;
84+
}
85+
@font-face {
86+
font-family: 'Rubik';
87+
src: url(/fonts/Rubik-Black.ttf) format('truetype');
88+
font-weight: 900;
89+
font-style: normal;
90+
font-display: swap;
91+
}
92+
@font-face {
93+
font-family: 'Rubik';
94+
src: url(/fonts/Rubik-Black.ttf) format('truetype');
95+
font-weight: 900;
96+
font-style: italic;
97+
font-display: swap;
98+
}

0 commit comments

Comments
 (0)