feat(scss): add table style
Style taken from: https://github.com/lepture/yue.css closes: https://github.com/CaiJimmy/hugo-theme-stack/issues/3
This commit is contained in:
parent
fd816ca9ef
commit
0e0f5edbec
@ -287,4 +287,29 @@
|
|||||||
box-shadow: 0px -10px 0px rgba(var(--link-background-color), var(--link-background-opacity-hover)) inset;
|
box-shadow: 0px -10px 0px rgba(var(--link-background-color), var(--link-background-opacity-hover)) inset;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
table {
|
||||||
|
margin: 0 var(--content-padding);
|
||||||
|
width: 100%;
|
||||||
|
max-width: calc(100% - var(--content-padding) * 2);
|
||||||
|
border-collapse: collapse;
|
||||||
|
border-spacing: 0;
|
||||||
|
margin-bottom: 1.5em;
|
||||||
|
font-size: 0.96em;
|
||||||
|
}
|
||||||
|
|
||||||
|
th,
|
||||||
|
td {
|
||||||
|
text-align: left;
|
||||||
|
padding: 4px 8px 4px 10px;
|
||||||
|
border: 1px solid var(--table-border-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
td {
|
||||||
|
vertical-align: top;
|
||||||
|
}
|
||||||
|
|
||||||
|
tr:nth-child(even) {
|
||||||
|
background-color: var(--tr-even-background-color);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -79,6 +79,9 @@ $on-desktop-large: 1920px;
|
|||||||
|
|
||||||
--code-background-color: rgba(0, 0, 0, 0.12);
|
--code-background-color: rgba(0, 0, 0, 0.12);
|
||||||
--code-text-color: #808080;
|
--code-text-color: #808080;
|
||||||
|
|
||||||
|
--table-border-color: #dadada;
|
||||||
|
--tr-even-background-color: #efefee;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
@ -99,5 +102,8 @@ $on-desktop-large: 1920px;
|
|||||||
|
|
||||||
--code-background-color: #272822;
|
--code-background-color: #272822;
|
||||||
--code-text-color: rgba(255, 255, 255, 0.9);
|
--code-text-color: rgba(255, 255, 255, 0.9);
|
||||||
|
|
||||||
|
--table-border-color: #717171;
|
||||||
|
--tr-even-background-color: #545454;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user