Browse Source

chore: improve API table style in small screen

close #26510
pull/26557/head
afc163 4 years ago
committed by 偏右
parent
commit
a204040a07
  1. 20
      site/theme/static/markdown.less

20
site/theme/static/markdown.less

@ -254,15 +254,16 @@
} }
.markdown.api-container { .markdown.api-container {
overflow-x: auto;
table { table {
min-width: 720px; display: block;
margin: 2em 0; margin: 2em 0;
overflow-x: auto;
overflow-y: hidden;
font-size: max(@font-size-base - 1px, 12px); font-size: max(@font-size-base - 1px, 12px);
font-family: @code-family; font-family: @code-family;
line-height: @line-height-base; line-height: @line-height-base;
border: 1px solid @border-color-split; border: 1px solid @border-color-split;
-webkit-overflow-scrolling: touch;
th, th,
td { td {
@ -285,18 +286,25 @@
td { td {
&:first-child { &:first-child {
width: 20%; width: 18%;
color: @gray-8; color: @gray-8;
font-weight: 600; font-weight: 600;
white-space: nowrap;
}
&:nth-child(2) {
width: 55%;
} }
&:nth-child(3) { &:nth-child(3) {
width: 22%; width: 22%;
color: @magenta-7; color: @magenta-7;
font-size: max(@font-size-base - 1px, 12px); font-size: max(@font-size-base - 1px, 12px);
word-break: break-all;
} }
&:nth-child(4) { &:nth-child(4) {
width: 16%; width: 15%;
font-size: max(@font-size-base - 1px, 12px);
}
&:nth-child(5) {
width: 8%;
font-size: max(@font-size-base - 1px, 12px); font-size: max(@font-size-base - 1px, 12px);
} }
} }

Loading…
Cancel
Save