Table style for article page.
* 書式 Table by MaruniUmebachi
Details
AuthorMaruniUmebachi
LicenseCC 0
Category*
Created
Updated
Size4.7 kB
Statistics
Learn how we calculate statistics in the FAQ.
Failed to fetch stats.
Description
Notes
Userstyle doesn't have notes.Source code
/* ==UserStyle==
@name * 書式 Table
@version 20241102.07.43
@namespace https://userstyles.world/user/MaruniUmebachi
@description Table style for article page.
@author MaruniUmebachi
@license CC 0
==/UserStyle== */
@-moz-document regexp("*") {
:has(:not(form:has(table, table#mvDaynamesTable.mv-daynames-table))) {
:is(table, th, td) {
--Stylus-CSS: "Table Stylus";
--border-block-Stylus-table: 1px solid;
}
table {
--Stylus-CSS: "Table Stylus";
--width-Stylus-table: 100%;
--max-width-Stylus-table: calc(16px * 50);
--height-Stylus-table: 240px;
--margin-Stylus-table: 0 auto;
--display-Stylus-table: block;
--overflow-x-Stylus-table: auto;
--border-spacing-Stylus-table: 0;
tbody {
--Stylus-CSS: "Table Stylus";
--border-block-Stylus-table: 1px solid;
--white-space-Stylus-table: nowrap;
:is(th, td) {
--Stylus-CSS: "Table Stylus";
--padding-Stylus-table: 5px 10px;
--border-top-width-Stylus-table: 0;
--border-left-width-Stylus-table: 0;
&:last-child {
--Stylus-CSS: "Table Stylus";
--border-right-width-Stylus-table: 0;
}
}
th {
--Stylus-CSS: "Table Stylus";
--position-Stylus-table: sticky;
--top-Stylus-table: 0;
--background-Stylus-table: white;
--color-Stylus-table: black;
--vertical-align-Stylus-table: bottom;
}
tr {
--Stylus-CSS: "Table Stylus";
--max-inline-size-Stylus-table: 100%;
th + td:last-child,
td:only-child {
--Stylus-CSS: "Table Stylus";
--word-break-Stylus-table: keep-all;
--text-wrap-Stylus-table: balance;
--font-size-Stylus-table: calc(16px * 1.25);
font-family: serif;
&:not(:nth-child(2)) {
--Stylus-CSS: "Table Stylus";
--max-inline-size-Stylus-table: 20em;
}
&:nth-child(2) {
--Stylus-CSS: "Table Stylus";
--inline-size-Stylus-table: 100%;
}
}
}
tr:last-child td {
--Stylus-CSS: "Table Stylus";
--border-bottom-width-Stylus-table: 0;
}
}
}
}
}
@-moz-document regexp("*") {
:not(form) {
:is(table, th, td) {
--Stylus-CSS: "Table Stylus";
border-block: var(--border-block-Stylus-table);
}
table {
--Stylus-CSS: "Table Stylus";
width: var(--width-Stylus-table);
max-width: var(--max-width-Stylus-table);
height: var(--height-Stylus-table);
margin: var(--margin-Stylus-table);
display: var(--display-Stylus-table);
overflow-x: var(--overflow-x-Stylus-table);
border-spacing: var(--border-spacing-Stylus-table);
}
tbody {
--Stylus-CSS: "Table Stylus";
border-block: var(--border-block-Stylus-table);
white-space: var(--white-space-Stylus-table);
}
:is(th, td) {
--Stylus-CSS: "Table Stylus";
padding: var(--padding-Stylus-table);
border-top-width: var(--border-top-width-Stylus-table);
border-left-width: var(--border-left-width-Stylus-table);
}
th {
--Stylus-CSS: "Table Stylus";
position: var(--position-Stylus-table);
top: var(--top-Stylus-table);
background: var(--background-Stylus-table);
color: var(--color-Stylus-table);
vertical-align: var(--vertical-align-Stylus-table);
}
tr {
--Stylus-CSS: "Table Stylus";
max-inline-size: var(--max-inline-size-Stylus-table);
th + td:last-child,
td:only-child {
--Stylus-CSS: "Table Stylus";
max-inline-size: var(--max-inline-size-Stylus-table);
inline-size: var(--inline-size-Stylus-table);
word-break: var(--word-break-Stylus-table);
text-wrap: var(--text-wrap-Stylus-table);
font-size: var(--font-size-Stylus-table);
}
}
:is(th, td):last-child {
--Stylus-CSS: "Table Stylus";
border-right-width: var(--border-right-width-Stylus-table);
}
tr:last-child td {
--Stylus-CSS: "Table Stylus";
border-bottom-width: var(--border-bottom-width-Stylus-table);
}
}
}