模板:Mainpage/styles.css:修订间差异
来自星露谷物语扩展百科
更多操作
无编辑摘要 |
无编辑摘要 |
||
| (未显示同一用户的6个中间版本) | |||
| 第1行: | 第1行: | ||
.mp-wrapper { | .mp-wrapper { | ||
--button-color-progressive: #9cbf57; | |||
--button-border-color: #68686b; | |||
display: flex; | display: flex; | ||
flex-wrap: wrap; | flex-wrap: wrap; | ||
width: 100%; | width: 100%; | ||
gap: 6px; | gap: 6px; | ||
--button-color: #d7f3ff; | |||
--button-text-color: #0095d3; | |||
--icon-background: #e4faffa1; | |||
--icon-background-hover: #e0f9ff; | |||
--section-background: #00000008; | |||
--section-border: transparent; | |||
--hover-mask: #7f7c7c1a; | |||
} | |||
html.skin-theme-clientpref-night .mp-wrapper { | |||
--button-color: #4e4f51; | |||
--button-text-color: #fff; | |||
--icon-background: #ffffff10; | |||
--icon-background-hover: #ffffff20; | |||
--section-background: #1c1b1b; | |||
--section-border: #212121; | |||
--hover-mask:#ffffff1a; | |||
} | |||
@media screen and (prefers-color-scheme: dark) { | |||
html.skin-theme-clientpref-os .mp-section { | |||
--button-color: #4e4f51; | |||
--button-text-color: #fff; | |||
--icon-background: #ffffff10; | |||
--icon-background-hover: #ffffff20; | |||
--section-background: #1c1b1b; | |||
--section-border: #212121; | |||
--hover-mask:#ffffff1a; | |||
} | |||
} | } | ||
| 第12行: | 第43行: | ||
} | } | ||
.mp-section { | |||
width: 100%; | width: 100%; | ||
padding: 12px; | |||
background: var(--section-background); | |||
border: 2px solid var(--section-border); | |||
box-shadow: inset rgba(0, 0, 0, 0.08) 0px 0px 0px 2px; | |||
} | } | ||
.mp-wrapper | .mp-wrapper>.mp-section { | ||
width: 100%; | |||
.mp- | |||
} | } | ||
| 第40行: | 第65行: | ||
#mp-section-site { | #mp-section-site { | ||
grid-area: site; | grid-area: site; | ||
display: flex; | |||
flex-direction: column; | |||
gap: 8px; | |||
align-items: center; | |||
} | } | ||
| 第48行: | 第77行: | ||
.mp-right { | .mp-right { | ||
grid-area: right; | grid-area: right; | ||
} | |||
.mp-left, | |||
.mp-right { | |||
display: flex; | |||
flex-direction: column; | |||
gap: 6px; | |||
} | |||
.mp-right>:last-child { | |||
flex: 1; | |||
} | |||
.mp-left-row { | |||
flex: 10 10 0; | |||
} | } | ||
| 第63行: | 第107行: | ||
} | } | ||
.mp- | .mp-wrapper h2 { | ||
font-family: revert; | |||
font-weight: bold; | |||
font-size: 1.2em; | |||
color: var(--wiki-content-link-color); | |||
} | } | ||
| 第82行: | 第120行: | ||
} | } | ||
. | .mw-headline { | ||
font-family: var(--wiki-content-heading-font-family); | |||
} | } | ||
| 第168行: | 第138行: | ||
} | } | ||
.mp-button | .mp-button>* { | ||
--content-text-color: #fff; | |||
-- | |||
} | } | ||
| 第180行: | 第147行: | ||
margin: -2px; | margin: -2px; | ||
text-shadow: 1px 1px 0 var(--button-text-shadow-color); | text-shadow: 1px 1px 0 var(--button-text-shadow-color); | ||
display: flex; | display: flex; | ||
gap: 6px; | gap: 6px; | ||
padding: 8px 10px !important; | padding: 8px 10px !important; | ||
text-align: center; | text-align: center; | ||
align-items: center; | align-items: center; | ||
justify-content: center; | justify-content: center; | ||
transition-property: padding, margin; | transition-property: padding, margin; | ||
transition-duration: .1s; | transition-duration: .1s; | ||
| 第196行: | 第160行: | ||
color: var(--button-text-color, #000) !important; | color: var(--button-text-color, #000) !important; | ||
text-decoration: none; | text-decoration: none; | ||
} | } | ||
| 第216行: | 第176行: | ||
} | } | ||
.mp- | .mp-button:hover:not(:active)::after, | ||
.mp-icon:hover:not(:active) .mp-button::after { | |||
background-color: var(--hover-mask); | |||
} | |||
.mp-button-wrapper { | |||
display: flex; | display: flex; | ||
flex-direction: row; | |||
flex-wrap: wrap; | |||
gap: 4px; | gap: 4px; | ||
} | } | ||
.mp- | .mp-button-wrapper .mp-button { | ||
flex: 1 0 0; | |||
min-width: max-content; | |||
white-space: nowrap; | |||
} | |||
.mp-button.mp-button-progressive { | |||
background-color: var(--button-color-progressive); | |||
--button-text-color: #fff; | |||
--button-text-shadow-color: #157298cf; | |||
background: linear-gradient(to bottom right, var(--color-progressive--hover), var(--color-progressive)); | |||
} | } | ||
| 第237行: | 第207行: | ||
.mp-button.mp-social-qq { | .mp-button.mp-social-qq { | ||
background-color: #1ebafc; | background-color: #1ebafc; | ||
} | |||
.mp-wrapper .collapsible-content { | |||
display: grid; | |||
grid-template-rows: 1fr; | |||
transition: grid-template-rows 300ms, visibility 300ms; | |||
} | |||
.mp-wrapper .collapsible-content>* { | |||
overflow: hidden; | |||
} | |||
.mp-wrapper .collapsible.collapsed .collapsible-content { | |||
display: grid; | |||
grid-template-rows: 0fr; | |||
visibility: hidden; | |||
overflow: hidden; | |||
} | |||
.mp-wrapper .collapsible.collapsed .collapsible-content>.mp-section { | |||
padding: 0; | |||
transition: padding 200ms; | |||
} | |||
.mp-button .collapsetoggle-custom { | |||
position: absolute; | |||
left: 0; | |||
right: 0; | |||
top: 0; | |||
bottom: 0; | |||
color: transparent !important; | |||
--button-text-color: transparent; | |||
user-select: none; | |||
display: flex; | |||
align-items: center; | |||
} | |||
body.mediawiki .collapsible .mp-button.mp-button-collapsetoggle>h4, | |||
body.mediawiki .collapsible .mp-button.mp-button-collapsetoggle:active>h4 { | |||
padding-left: 12px !important; | |||
padding-right: 12px !important; | |||
} | |||
.mp-button.mp-button-collapsetoggle>::after { | |||
content: ""; | |||
display: block; | |||
pointer-events: none; | |||
width: 16px; | |||
height: 16px; | |||
margin-left: auto; | |||
--mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' class='icon icon-tabler icon-tabler-chevron-down' width='24' height='24' viewBox='0 0 24 24' stroke-width='2' stroke='currentColor' fill='none' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath stroke='none' d='M0 0h24v24H0z' fill='none'%3E%3C/path%3E%3Cpath d='M6 9l6 6l6 -6'%3E%3C/path%3E%3C/svg%3E") no-repeat; | |||
mask: var(--mask); | |||
mask-size: 100% 100%; | |||
mask-position: center center; | |||
background-color: var(--content-text-color); | |||
transform: rotate(180deg); | |||
transition: 300ms transform; | |||
} | |||
.collapsible.collapsed .mp-button.mp-button-collapsetoggle>::after { | |||
transform: rotate(0); | |||
} | } | ||
| 第257行: | 第288行: | ||
transition-property: padding, margin; | transition-property: padding, margin; | ||
transition-duration: .1s; | transition-duration: .1s; | ||
} | } | ||
| 第285行: | 第302行: | ||
align-items: center; | align-items: center; | ||
justify-content: center; | justify-content: center; | ||
background-color: | background-color: var(--icon-background); | ||
transition-property: background-color, color, border-color, box-shadow, opacity, padding, margin; | transition-property: background-color, color, border-color, box-shadow, opacity, padding, margin; | ||
transition-duration: .4s; | transition-duration: .4s; | ||
| 第292行: | 第309行: | ||
.mp-icon:hover .mp-icon-img { | .mp-icon:hover .mp-icon-img { | ||
background-color: | background-color: var(--icon-background-hover); | ||
} | } | ||
| 第309行: | 第326行: | ||
.mp-icon-img img { | .mp-icon-img img { | ||
max-width: unset !important; | max-width: unset !important; | ||
width: | width: 40px !important; | ||
height: | height: 40px !important; | ||
filter: drop-shadow(2px 2px 1px #00000030); | filter: drop-shadow(2px 2px 1px #00000030); | ||
object-fit: contain; | object-fit: contain; | ||
} | } | ||
@media screen and (min-width: 1500px) and (max-width: 2600px) { | |||
.mp-main-icons { | |||
--icon-base-width: 6vw; | |||
} | |||
} | |||
@media screen and (max-width: 950px) { | @media screen and (max-width: 950px) { | ||
.mp-icon-wrapper.mp-main-icons { | |||
--icon-base-width: 70px; | |||
--icon-max-width: 100px; | |||
} | |||
.mp-icon-link { | .mp-icon-link { | ||
font-size: 12px; | font-size: 12px; | ||
| 第331行: | 第358行: | ||
} | } | ||
.mp-highlight-wrapper { | .mp-highlight-wrapper { | ||
display: flex; | display: flex; | ||
flex-wrap: wrap; | flex-wrap: wrap; | ||
gap: 8px; | gap: 8px; | ||
flex: 0 7 0; | |||
} | } | ||
| 第384行: | 第372行: | ||
min-width: 300px; | min-width: 300px; | ||
min-height: calc(150px + 5vh); | min-height: calc(150px + 5vh); | ||
max-height: 300px; | |||
position: relative; | position: relative; | ||
padding: 0; | padding: 0; | ||
color: #fff !important; | color: #fff !important; | ||
font-size: small; | font-size: small; | ||
text-shadow: 1px 1px 8px #333, | text-shadow: 1px 1px 8px #333, -1px -1px 8px #333; | ||
} | } | ||
| 第419行: | 第407行: | ||
} | } | ||
.mp-highlight- | .mp-highlight-image, | ||
.mp-highlight-image img { | |||
object-fit: cover; | |||
width: 100%; | |||
height: 100%; | |||
max-height: 300px; | |||
user-select: none; | |||
} | |||
.mp-highlight-top-description, | |||
.mp-highlight-bottom-description { | |||
width: 100%; | |||
} | |||
.mp-highlight-top-description { | |||
background: linear-gradient(180deg, #0008 24px, transparent); | |||
padding: 12px; | |||
position: absolute; | |||
top: 0; | |||
} | } | ||
.mp- | .mp-highlight-bottom-description { | ||
background: linear-gradient(to top, #0008 50%, transparent); | |||
padding: 12px; | |||
position: absolute; | |||
bottom: 0; | |||
} | } | ||
.mp- | .mp-social-wrapper { | ||
display: flex; | display: flex; | ||
display: grid; | |||
grid-auto-columns: minmax(0, 1fr); | |||
grid-auto-flow: column; | |||
gap: 4px; | gap: 4px; | ||
width: 100%; | |||
} | } | ||
.mp- | .mp-social-wrapper img { | ||
margin: 2px 0; | |||
user-select: none; | |||
} | } | ||
.mp-platform-wrapper { | .mp-platform-wrapper { | ||
| 第462行: | 第470行: | ||
flex-wrap: wrap; | flex-wrap: wrap; | ||
} | } | ||
} | } | ||
| 第503行: | 第506行: | ||
border-radius: 16px; | border-radius: 16px; | ||
} | } | ||
2026年1月22日 (四) 22:46的最新版本
.mp-wrapper {
--button-color-progressive: #9cbf57;
--button-border-color: #68686b;
display: flex;
flex-wrap: wrap;
width: 100%;
gap: 6px;
--button-color: #d7f3ff;
--button-text-color: #0095d3;
--icon-background: #e4faffa1;
--icon-background-hover: #e0f9ff;
--section-background: #00000008;
--section-border: transparent;
--hover-mask: #7f7c7c1a;
}
html.skin-theme-clientpref-night .mp-wrapper {
--button-color: #4e4f51;
--button-text-color: #fff;
--icon-background: #ffffff10;
--icon-background-hover: #ffffff20;
--section-background: #1c1b1b;
--section-border: #212121;
--hover-mask:#ffffff1a;
}
@media screen and (prefers-color-scheme: dark) {
html.skin-theme-clientpref-os .mp-section {
--button-color: #4e4f51;
--button-text-color: #fff;
--icon-background: #ffffff10;
--icon-background-hover: #ffffff20;
--section-background: #1c1b1b;
--section-border: #212121;
--hover-mask:#ffffff1a;
}
}
.mp-wrapper *,
.mp-wrapper *::before,
.mp-wrapper *::after {
box-sizing: border-box;
}
.mp-section {
width: 100%;
padding: 12px;
background: var(--section-background);
border: 2px solid var(--section-border);
box-shadow: inset rgba(0, 0, 0, 0.08) 0px 0px 0px 2px;
}
.mp-wrapper>.mp-section {
width: 100%;
}
.mp-inline-sections {
display: grid;
grid-template-columns: 1fr;
grid-template-areas: "site" "right" "left";
gap: 6px;
width: 100%;
}
#mp-section-site {
grid-area: site;
display: flex;
flex-direction: column;
gap: 8px;
align-items: center;
}
.mp-left {
grid-area: left;
}
.mp-right {
grid-area: right;
}
.mp-left,
.mp-right {
display: flex;
flex-direction: column;
gap: 6px;
}
.mp-right>:last-child {
flex: 1;
}
.mp-left-row {
flex: 10 10 0;
}
.mp-sticky {
position: sticky;
top: 20px;
}
@media screen and (min-width: 990px) {
.mp-inline-sections {
grid-template-columns: 1fr 2fr;
grid-template-rows: auto 1fr;
grid-template-areas: "site right" "left right";
}
}
.mp-wrapper h2 {
font-family: revert;
font-weight: bold;
font-size: 1.2em;
color: var(--wiki-content-link-color);
}
.mp-title {
border: none;
margin: 0;
padding: 0 !important;
}
.mw-headline {
font-family: var(--wiki-content-heading-font-family);
}
.mp-button {
width: 100%;
gap: 6px;
cursor: pointer;
position: relative;
text-align: center;
background-color: var(--button-color);
color: var(--button-text-color, #000);
font-size: 1em;
font-weight: bold;
transition-property: background-color, color, border-color, box-shadow, opacity, padding, margin;
transition-duration: .1s;
}
.mp-button>* {
--content-text-color: #fff;
}
body.mediawiki .mp-button>* {
width: calc(100% + 4px);
height: calc(100% + 4px);
margin: -2px;
text-shadow: 1px 1px 0 var(--button-text-shadow-color);
display: flex;
gap: 6px;
padding: 8px 10px !important;
text-align: center;
align-items: center;
justify-content: center;
transition-property: padding, margin;
transition-duration: .1s;
}
body.mediawiki .mp-button span>* {
color: var(--button-text-color, #000) !important;
text-decoration: none;
}
.mp-button::after {
display: block;
content: '';
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
z-index: 1;
mix-blend-mode: hard-light;
transition: .4s background-color, box-shadow;
pointer-events: none;
}
.mp-button:hover:not(:active)::after,
.mp-icon:hover:not(:active) .mp-button::after {
background-color: var(--hover-mask);
}
.mp-button-wrapper {
display: flex;
flex-direction: row;
flex-wrap: wrap;
gap: 4px;
}
.mp-button-wrapper .mp-button {
flex: 1 0 0;
min-width: max-content;
white-space: nowrap;
}
.mp-button.mp-button-progressive {
background-color: var(--button-color-progressive);
--button-text-color: #fff;
--button-text-shadow-color: #157298cf;
background: linear-gradient(to bottom right, var(--color-progressive--hover), var(--color-progressive));
}
.mp-button.mp-social-discord {
--button-color: #5865f2;
}
.mp-button.mp-social-qq {
background-color: #1ebafc;
}
.mp-wrapper .collapsible-content {
display: grid;
grid-template-rows: 1fr;
transition: grid-template-rows 300ms, visibility 300ms;
}
.mp-wrapper .collapsible-content>* {
overflow: hidden;
}
.mp-wrapper .collapsible.collapsed .collapsible-content {
display: grid;
grid-template-rows: 0fr;
visibility: hidden;
overflow: hidden;
}
.mp-wrapper .collapsible.collapsed .collapsible-content>.mp-section {
padding: 0;
transition: padding 200ms;
}
.mp-button .collapsetoggle-custom {
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
color: transparent !important;
--button-text-color: transparent;
user-select: none;
display: flex;
align-items: center;
}
body.mediawiki .collapsible .mp-button.mp-button-collapsetoggle>h4,
body.mediawiki .collapsible .mp-button.mp-button-collapsetoggle:active>h4 {
padding-left: 12px !important;
padding-right: 12px !important;
}
.mp-button.mp-button-collapsetoggle>::after {
content: "";
display: block;
pointer-events: none;
width: 16px;
height: 16px;
margin-left: auto;
--mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' class='icon icon-tabler icon-tabler-chevron-down' width='24' height='24' viewBox='0 0 24 24' stroke-width='2' stroke='currentColor' fill='none' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath stroke='none' d='M0 0h24v24H0z' fill='none'%3E%3C/path%3E%3Cpath d='M6 9l6 6l6 -6'%3E%3C/path%3E%3C/svg%3E") no-repeat;
mask: var(--mask);
mask-size: 100% 100%;
mask-position: center center;
background-color: var(--content-text-color);
transform: rotate(180deg);
transition: 300ms transform;
}
.collapsible.collapsed .mp-button.mp-button-collapsetoggle>::after {
transform: rotate(0);
}
.mp-icon-wrapper {
display: flex;
flex-wrap: wrap;
justify-content: center;
gap: 8px;
margin: auto;
--icon-base-width: 90px;
--icon-max-width: 200px;
}
.mp-icon {
flex: 1 1 auto;
width: var(--icon-base-width);
max-width: var(--icon-max-width);
display: flex;
flex-direction: column;
transition-property: padding, margin;
transition-duration: .1s;
}
.mp-icon-link {
flex: 1;
margin: -2px 0 0;
font-size: 14px;
padding-left: 2px;
padding-right: 2px;
}
.mp-icon-img {
display: flex;
align-items: center;
justify-content: center;
background-color: var(--icon-background);
transition-property: background-color, color, border-color, box-shadow, opacity, padding, margin;
transition-duration: .4s;
user-select: none;
}
.mp-icon:hover .mp-icon-img {
background-color: var(--icon-background-hover);
}
.mp-icon-img a {
padding: 12px;
}
.mp-icon-img a,
.mp-icon-img span {
display: block;
width: 100%;
height: 100%;
text-align: center;
}
.mp-icon-img img {
max-width: unset !important;
width: 40px !important;
height: 40px !important;
filter: drop-shadow(2px 2px 1px #00000030);
object-fit: contain;
}
@media screen and (min-width: 1500px) and (max-width: 2600px) {
.mp-main-icons {
--icon-base-width: 6vw;
}
}
@media screen and (max-width: 950px) {
.mp-icon-wrapper.mp-main-icons {
--icon-base-width: 70px;
--icon-max-width: 100px;
}
.mp-icon-link {
font-size: 12px;
}
.mp-icon-img a {
padding: 6px;
}
.mp-icon-img img {
width: 40px !important;
height: 40px !important;
}
}
.mp-highlight-wrapper {
display: flex;
flex-wrap: wrap;
gap: 8px;
flex: 0 7 0;
}
.mp-highlight {
background-size: cover;
background-position: center;
background-repeat: no-repeat;
flex: 1 1 0;
min-width: 300px;
min-height: calc(150px + 5vh);
max-height: 300px;
position: relative;
padding: 0;
color: #fff !important;
font-size: small;
text-shadow: 1px 1px 8px #333, -1px -1px 8px #333;
}
.mp-section.mp-highlight::after {
position: absolute;
content: '';
top: 0;
bottom: 0;
left: 0;
right: 0;
pointer-events: none;
}
.mp-highlight *:not(a):not(.sprite-text) {
color: #fff !important;
}
.mp-highlight a {
color: #bed9ff !important;
}
.mp-highlight .hlist li:after {
background-color: #fff !important;
}
.mp-highlight .mp-title {
line-height: 1.2;
margin-bottom: 6px;
}
.mp-highlight-image,
.mp-highlight-image img {
object-fit: cover;
width: 100%;
height: 100%;
max-height: 300px;
user-select: none;
}
.mp-highlight-top-description,
.mp-highlight-bottom-description {
width: 100%;
}
.mp-highlight-top-description {
background: linear-gradient(180deg, #0008 24px, transparent);
padding: 12px;
position: absolute;
top: 0;
}
.mp-highlight-bottom-description {
background: linear-gradient(to top, #0008 50%, transparent);
padding: 12px;
position: absolute;
bottom: 0;
}
.mp-social-wrapper {
display: flex;
display: grid;
grid-auto-columns: minmax(0, 1fr);
grid-auto-flow: column;
gap: 4px;
width: 100%;
}
.mp-social-wrapper img {
margin: 2px 0;
user-select: none;
}
.mp-platform-wrapper {
display: flex;
flex-wrap: wrap;
justify-content: center;
gap: 6px;
margin-top: 5px;
}
.mp-platform {
min-width: 260px;
display: flex;
gap: 5px;
flex-direction: row;
align-items: center;
}
@media screen and (max-width: 989px) {
.mp-platform {
flex-direction: row;
flex-wrap: wrap;
}
}
.sr-only:not(:focus):not(:active) {
clip-path: inset(50%);
height: 1px;
overflow: hidden;
position: absolute;
white-space: nowrap;
width: 1px;
}
.hlist ul {
display: inline;
margin: 0;
padding: 0;
}
.hlist li {
display: inline;
}
.hlist li:not(:last-child) {
padding-right: 0.286em;
}
.hlist li:not(:last-child)::after {
content: "";
display: inline-block;
position: relative;
left: 0.286em;
bottom: 0.214em;
background-color: #fff;
height: 3px;
width: 3px;
border-radius: 16px;
}