refactor: adjust stylings and add more normalization to the styles

pull/129/head
Kia Ishii 4 years ago
parent 6931ebd22a
commit 6aa13ce9e8

@ -22,10 +22,10 @@
<style> <style>
.icon.outbound { .icon.outbound {
color: #aaa;
display: inline-block;
vertical-align: middle;
position: relative; position: relative;
top: -1px; top: -1px;
display: inline-block;
color: #aaa;
vertical-align: middle;
} }
</style> </style>

@ -3,9 +3,9 @@ import './styles/layout.css'
import './styles/code.css' import './styles/code.css'
import './styles/custom-blocks.css' import './styles/custom-blocks.css'
import { Theme } from '/@app/theme'
import Layout from './Layout.vue' import Layout from './Layout.vue'
import NotFound from './NotFound.vue' import NotFound from './NotFound.vue'
import { Theme } from '../app/theme'
const theme: Theme = { const theme: Theme = {
Layout, Layout,

@ -1,15 +1,33 @@
*,
::before,
::after {
box-sizing: border-box;
}
html {
line-height: 1.15;
-webkit-text-size-adjust: 100%;
}
body { body {
padding: 0; width: 100%;
margin: 0; min-width: 320px;
background-color: #fff; min-height: 100vh;
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, line-height: 1.4;
Ubuntu, Cantarell, 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
font-size: 16px;
font-weight: 400;
color: var(--text-color);
background-color: #ffffff;
direction: ltr;
font-synthesis: none;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased; -webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale; -moz-osx-font-smoothing: grayscale;
} }
* { main {
box-sizing: border-box; display: block;
} }
.theme { .theme {
@ -155,13 +173,28 @@ b {
line-height: 1.6; line-height: 1.6;
} }
h1:hover .header-anchor,
h1:focus .header-anchor,
h2:hover .header-anchor,
h2:focus .header-anchor,
h3:hover .header-anchor,
h3:focus .header-anchor,
h4:hover .header-anchor,
h4:focus .header-anchor,
h5:hover .header-anchor,
h5:focus .header-anchor,
h6:hover .header-anchor,
h6:focus .header-anchor {
opacity: 1;
}
h1 { h1 {
font-size: 2.2rem; font-size: 2.2rem;
} }
h2 { h2 {
font-size: 1.65rem; font-size: 1.65rem;
padding-bottom: 0.3rem; padding-bottom: .3rem;
border-bottom: 1px solid var(--border-color); border-bottom: 1px solid var(--border-color);
} }
@ -182,30 +215,15 @@ a.header-anchor {
opacity: 0; opacity: 0;
} }
a.header-anchor:focus, a.header-anchor:hover,
a.header-anchor:hover { a.header-anchor:focus {
text-decoration: none; text-decoration: none;
} }
h1:focus .header-anchor,
h1:hover .header-anchor,
h2:focus .header-anchor,
h2:hover .header-anchor,
h3:focus .header-anchor,
h3:hover .header-anchor,
h4:focus .header-anchor,
h4:hover .header-anchor,
h5:focus .header-anchor,
h5:hover .header-anchor,
h6:focus .header-anchor,
h6:hover .header-anchor {
opacity: 1;
}
p, p,
ol, ol,
ul { ul {
line-height: 1.6; line-height: 1.7;
} }
ul, ul,
@ -214,9 +232,9 @@ ol {
} }
table { table {
display: block;
border-collapse: collapse; border-collapse: collapse;
margin: 1rem 0; margin: 1rem 0;
display: block;
overflow-x: auto; overflow-x: auto;
} }

Loading…
Cancel
Save