Skip to content

Commit 869e08c

Browse files
committed
feat: prefer rem unit
1 parent cb18654 commit 869e08c

File tree

14 files changed

+36
-43
lines changed

14 files changed

+36
-43
lines changed

e2e/docs/.vuepress/layouts/Category.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const routePath = useRoutePath()
4444
& {
4545
padding-top: calc(var(--navbar-height) + 1rem) !important;
4646
padding-bottom: 0 !important;
47-
font-size: 14px;
47+
font-size: 0.875rem;
4848
}
4949

5050
.route-link {

e2e/docs/.vuepress/layouts/Tag.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const routePath = useRoutePath()
4444
& {
4545
padding-top: calc(var(--navbar-height) + 1rem) !important;
4646
padding-bottom: 0 !important;
47-
font-size: 14px;
47+
font-size: 0.875rem;
4848
}
4949

5050
.route-link {

plugins/blog/plugin-feed/templates/atom.xsl

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,6 @@
4444
background: var(--c-bg);
4545
}
4646

47-
html {
48-
font-size: 16px;
49-
}
50-
5147
body {
5248
min-height: 100vh;
5349
color: var(--c-text);
@@ -254,7 +250,7 @@
254250
margin: 0.5rem auto;
255251
border: 1px solid #fff;
256252
border-collapse: collapse;
257-
border-radius: 8px;
253+
border-radius: 0.5rem;
258254

259255
text-align: start;
260256
}
@@ -334,13 +330,13 @@
334330
}
335331

336332
.atom-info {
337-
margin-top: 4px;
338-
font-size: 14px;
333+
margin-top: 0.25rem;
334+
font-size: 0.875rem;
339335
}
340336

341337
.atom-info > span {
342338
display: inline-block;
343-
margin: 4px 8px 4px 0;
339+
margin: 0.25em 0.5em 0.25em 0;
344340
}
345341

346342
.atom-info > span:last-child {
@@ -353,14 +349,14 @@
353349
}
354350

355351
.atom-body {
356-
padding: 4px 16px;
352+
padding: 0.25rem 1rem;
357353
}
358354

359355
.atom-footer {
360356
display: flex;
361357
justify-content: space-between;
362-
padding: 8px 16px;
363-
font-size: 14px;
358+
padding: 0.5rem 1rem;
359+
font-size: 0.875rem;
364360
}
365361

366362
.atom-footer label {
@@ -370,20 +366,20 @@
370366
.atom-link {
371367
display: inline-block;
372368

373-
padding: 6px 12px;
374-
border-radius: 8px;
369+
padding: 0.375em 0.75em;
370+
border-radius: 0.5em;
375371

376372
background: var(--c-accent);
377373
color: var(--c-bg-elv);
378374
}
379375

380376
footer {
381-
margin-top: 10px;
382-
padding: 4px;
377+
margin-top: 0.75rem;
378+
padding: 0.25rem;
383379

384380
color: #888;
385381

386-
font-size: 12px;
382+
font-size: 0.75rem;
387383
text-align: center;
388384
}
389385
</style>

plugins/features/plugin-notice/src/client/styles/notice.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@
8080

8181
.vp-notice-content {
8282
margin: 1rem 0.75rem;
83-
font-size: 14px;
83+
font-size: 0.875rem;
8484
line-height: 1.5;
8585
}
8686

plugins/markdown/plugin-revealjs/src/client/styles/_normalize.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
ol ol,
4040
ol ul {
4141
display: block;
42-
margin-left: 40px;
42+
margin-left: 2.5rem;
4343
}
4444

4545
ul {
@@ -59,7 +59,7 @@
5959
}
6060

6161
dd {
62-
margin-left: 40px;
62+
margin-left: 2.5rem;
6363
}
6464

6565
blockquote {

plugins/search/plugin-slimsearch/src/client/styles/search-modal.scss

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -191,13 +191,13 @@
191191
float: right;
192192

193193
margin: 0 0.5rem;
194-
padding: 4px;
194+
padding: 0.25rem;
195195
border: 1px solid var(--vp-c-border);
196-
border-radius: 4px;
196+
border-radius: 0.25rem;
197197

198198
box-shadow: 1px 1px 4px 0 var(--vp-c-shadow);
199199

200-
font-size: 12px;
200+
font-size: 0.75rem;
201201
line-height: 1;
202202

203203
.slimsearch-suggestion.active & {
@@ -228,7 +228,7 @@
228228
padding: 1.5rem;
229229

230230
font-weight: 600;
231-
font-size: 22px;
231+
font-size: 1.3rem;
232232
text-align: center;
233233
}
234234
}

plugins/seo/plugin-sitemap/templates/sitemap.xsl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767

6868
table {
6969
width: 100%;
70-
border-radius: 8px;
70+
border-radius: 0.5rem;
7171
border-collapse: collapse;
7272
text-align: center;
7373
overflow: hidden;
@@ -80,7 +80,7 @@
8080
}
8181

8282
th {
83-
min-width: 56px;
83+
min-width: 3.5em;
8484
padding: 0.6em 1em;
8585

8686
background-color: var(--brand-color);

plugins/tools/plugin-redirect/src/client/styles/redirect-modal.scss

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232

3333
max-width: 80vw;
3434
padding: 1rem 2rem;
35-
border-radius: 8px;
35+
border-radius: 0.5rem;
3636

3737
background: var(--redirect-c-bg);
3838
box-shadow: 0 2px 6px 0 var(--redirect-c-shadow);
@@ -41,7 +41,7 @@
4141
.redirect-modal-hint {
4242
margin-top: 0.5rem;
4343
color: var(--vp-c-text-mute);
44-
font-size: 14px;
44+
font-size: 0.875rem;
4545
text-align: start;
4646

4747
input[type='checkbox'] {
@@ -115,7 +115,7 @@
115115
margin: 1rem 0;
116116
padding: 0.5rem 0.75rem;
117117
border: none;
118-
border-radius: 8px;
118+
border-radius: 0.5rem;
119119

120120
background-color: var(--redirect-c-control);
121121
color: inherit;

themes/theme-default/src/client/components/VPNavbarDropdown.vue

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,6 @@ onContentUpdated(() => {
273273
}
274274
275275
.vp-navbar-dropdown-wrapper.mobile & > a {
276-
font-size: 15px;
277276
line-height: 2rem;
278277
}
279278
}
@@ -290,7 +289,6 @@ onContentUpdated(() => {
290289
padding-bottom: 0;
291290
border-top: 0;
292291
293-
font-size: 15px;
294292
line-height: 2rem;
295293
}
296294
@@ -325,7 +323,6 @@ onContentUpdated(() => {
325323
326324
.vp-navbar-dropdown-wrapper.mobile & {
327325
padding-left: 1rem;
328-
font-size: 14px;
329326
}
330327
}
331328
</style>

themes/theme-default/src/client/components/VPPageMeta.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ const contributors = useContributors()
103103
margin-top: 0.25rem;
104104
margin-right: 0.5rem;
105105
margin-bottom: 0.25rem;
106-
font-size: 14px;
106+
font-size: 0.875em;
107107
108108
@media print {
109109
display: none;
@@ -123,10 +123,10 @@ const contributors = useContributors()
123123
.contributors {
124124
margin-top: 0.25rem;
125125
margin-bottom: 0.25rem;
126-
font-size: 14px;
126+
font-size: 0.875em;
127127
128128
@media (max-width: $MQMobile) {
129-
font-size: 13px;
129+
font-size: 0.825em;
130130
text-align: start;
131131
}
132132
}

themes/theme-default/src/client/components/VPSidebar.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ defineSlots<{
3939
4040
background-color: var(--vp-sidebar-c-bg);
4141
42-
font-size: 16px;
42+
font-size: 1rem;
4343
4444
transition:
4545
transform var(--vp-t-transform),
@@ -52,7 +52,7 @@ defineSlots<{
5252
// narrow desktop / iPad
5353
@media (max-width: $MQNarrow) {
5454
width: var(--sidebar-width-mobile);
55-
font-size: 15px;
55+
font-size: 0.9rem;
5656
}
5757
5858
// wide mobile

themes/theme-default/src/client/components/global/Badge.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,15 +45,15 @@ defineSlots<{
4545
display: inline-block;
4646
vertical-align: top;
4747
48-
height: 18px;
48+
height: 1.3em;
4949
padding: 0 6px;
5050
border-radius: 3px;
5151
5252
background: var(--vp-c-accent-soft);
5353
color: var(--vp-c-accent);
5454
55-
font-size: 14px;
56-
line-height: 18px;
55+
font-size: 0.875em;
56+
line-height: 1.3;
5757
5858
transition:
5959
background var(--vp-t-color),

tools/create-vuepress/template/blog/.vuepress/layouts/Category.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ const routePath = useRoutePath()
4141
4242
padding-top: calc(var(--navbar-height) + 1rem) !important;
4343
padding-bottom: 0 !important;
44-
font-size: 14px;
44+
font-size: 0.875em;
4545
4646
.route-link {
4747
color: inherit;

tools/create-vuepress/template/blog/.vuepress/layouts/Tag.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ const routePath = useRoutePath()
4141
4242
padding-top: calc(var(--navbar-height) + 1rem) !important;
4343
padding-bottom: 0 !important;
44-
font-size: 14px;
44+
font-size: 0.875em;
4545
4646
.route-link {
4747
color: inherit;

0 commit comments

Comments
 (0)