MediaWiki:Gadget-Infobox.css: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
| (One intermediate revision by the same user not shown) | |||
| Line 169: | Line 169: | ||
} | } | ||
/* | .pi-section-navigation .pi-section-tab, .pi-media-collection .pi-tab-link { | ||
width: 100%; | |||
max-width: 100%; | |||
margin: -2px 0 0 0; | |||
} | |||
/* HNA Infobox Styling */ | |||
.pi-type-item .pi-item.pi-image { | .pi-type-item .pi-item.pi-image { | ||
position: relative; | position: relative; | ||
| Line 212: | Line 218: | ||
*/ | */ | ||
.pi-theme-1 .pi-item.pi-image:before { | .pi-theme-1 .pi-item.pi-image:before { | ||
background-image: url( | background-image: url("filepath://Item_Frame_1-Star.png"); | ||
} | } | ||
.pi-theme-2 .pi-item.pi-image:before { | .pi-theme-2 .pi-item.pi-image:before { | ||
background-image: url( | background-image: url("filepath://Item_Frame_2-Star.png"); | ||
} | } | ||
.pi-theme-3 .pi-item.pi-image:before { | .pi-theme-3 .pi-item.pi-image:before { | ||
background-image: url( | background-image: url("filepath://Item_Frame_3-Star.png"); | ||
} | } | ||
.pi-theme-4 .pi-item.pi-image:before { | .pi-theme-4 .pi-item.pi-image:before { | ||
background-image: url( | background-image: url("filepath://Item_Frame_4-Star.png"); | ||
} | } | ||
.pi-theme-5 .pi-item.pi-image:before { | .pi-theme-5 .pi-item.pi-image:before { | ||
background-image: url( | background-image: url("filepath://Item_Frame_5-Star.png"); | ||
} | } | ||
/* | /* | ||
Latest revision as of 03:07, 14 July 2026
/* Default stuff */
.pi-title, .pi-secondary-background {
background: var(--pi-secondary-background);
color: var(--pi-secondary-background--label);
}
/* Custom stuff */
.portable-infobox {
--pi-background: var(--theme-page-background-color);
--pi-secondary-background: var(--theme-accent-color);
--pi-secondary-background--label: var(--theme-accent-label-color);
border-radius: 5px;
border-style: unset;
border: 1px solid var(--pi-border);
color: var(--theme-page-text-color);
width: 270px;
}
.pi-theme-charnav .pi-navigation {
font-size: 14px;
}
/* Assume that there is already a title */
.portable-infobox .pi-header[data-item-name=secondary_title] {
padding-top: 0;
}
/* remove border between label and format */
.pi-horizontal-group .pi-horizontal-group-item,
.pi-smart-group-body {
border-top: none !important;
}
/* remove extra margin from empty border */
.pi-smart-group .pi-smart-data-label,
.pi-smart-group .pi-smart-data-value {
margin: 0;
}
/* add border above tabber */
.pi-item.pi-panel.pi-border-color.wds-tabber {
border-top: 1px solid var(--pi-border-color);
}
/* add border tabke header */
.pi-item.pi-group.pi-border-color thead tr {
border-top: 1px solid var(--pi-border-color);
}
/* add border below image */
.pi-image { border-bottom: 1px solid var(--pi-border-color); }
/* remove border above secondary title */
.pi-header[data-item-name=secondary_title],
.portable-infobox .pi-secondary-font {
border-top: none;
}
/* center collapsible headers */
.pi-collapse .pi-header:first-child {
padding-left: 40px;
}
/* remove margin added for normal headers */
.page-content .portable-infobox h1,
.page-content .portable-infobox h2,
.page-content .portable-infobox h3,
.page-content .portable-infobox h4,
.page-content .portable-infobox h5,
.page-content .portable-infobox h6 {
margin: 0;
}
/* remove padding for group label and value */
h3.pi-smart-data-label.pi-data-label.pi-secondary-font.pi-item-spacing.pi-border-color {
padding-bottom: 0;
}
.pi-smart-data-value.pi-data-value.pi-font.pi-item-spacing.pi-border-color {
padding-top: 0;
}
.portable-infobox.pi-type-anima .pi-anima-id {
margin-left: 5px !important;
background-color: #fefaf2 !important;
color: var(--theme-accent-color) !important;
padding: 2px 10px !important;
border-radius: 5px !important;
float: right !important;
}
.portable-infobox {
border-radius: 10px !important;
overflow: hidden;
}
.portable-infobox.pi-type-anima .pi-title {
text-align: left;
}
.portable-infobox.pi-type-anima .pi-title-text {
padding: 2px 0 0 5px;
font-size: 20px;
}
.portable-infobox .pi-header {
background-color: var(--pi-header-bg-color);
color: var(--pi-header-color);
padding-top: 10px !important;
text-transform: none;
}
.portable-infobox .pi-group {
color: var(--theme-page-text-color);
background-color: var(--pi-rows-color);
}
.portable-infobox .pi-horizontal-group {
border-top: 1px solid var(--pi-border);
}
.portable-infobox .pi-image { border-bottom: none; }
.portable-infobox .pi-item[data-item-name="center"] {
justify-content: center;
}
.pi-data {
border-color: var(--pi-border);
background-color: var(--pi-rows-color);
}
/* Fix tabs in infobox */
.portable-infobox .wds-tabs {
width: 100%;
background-color: var(--pi-tabber-bg-color);
border-top: 1px solid var(--pi-border);
}
.portable-infobox .wds-tabs .wds-tabs__tab {
text-align: center;
color: var(--pi-tabber-color);
> .wds-tabs__tab-label { height: 30px; }
}
.portable-infobox .wds-tabs .wds-is-current {
color: var(--theme-link-color);
background-color: var(--theme-page-background-color--secondary) !important;
}
.portable-infobox .wds-tabs .wds-tabs__tab:hover {
color: var(--theme-link-color);
background-color: var(--theme-page-background-color--secondary) !important;
}
.portable-infobox section:last-child .wds-tabs .wds-tabs__tab {
text-align: center;
}
/* Fix infobox tabs to not require horizontal scrolling and make better use of space */
aside.portable-infobox .wds-tabs {
display: flex;
flex-wrap: wrap;
}
aside.portable-infobox .wds-tabs__tab {
flex-grow: 1;
text-align: center;
}
.pi-section-navigation .pi-section-tab, .pi-media-collection .pi-tab-link {
width: 100%;
max-width: 100%;
margin: -2px 0 0 0;
}
/* HNA Infobox Styling */
.pi-type-item .pi-item.pi-image {
position: relative;
z-index: 2;
opacity: 100;
}
.pi-type-item .pi-item.pi-image img {
position: relative;
z-index: 2;
opacity: 100;
}
.pi-type-item .pi-item.pi-image:before {
content: ' ';
display: block;
position: absolute;
z-index: 0;
left: 0;
top: 0;
width: 100%;
height: 100%;
background-repeat: no-repeat;
background-position: center;
/*background-size: cover;*/
}
/*
.pi-type-item .pi-item.pi-image:after {
content: ' ';
display: block;
position: absolute;
z-index: 1;
left: 0;
top: 0;
width: 100%;
height: 100%;
opacity: 0.1;
background-repeat: no-repeat;
background-position: center;
background-size: cover;
}
*/
.pi-theme-1 .pi-item.pi-image:before {
background-image: url("filepath://Item_Frame_1-Star.png");
}
.pi-theme-2 .pi-item.pi-image:before {
background-image: url("filepath://Item_Frame_2-Star.png");
}
.pi-theme-3 .pi-item.pi-image:before {
background-image: url("filepath://Item_Frame_3-Star.png");
}
.pi-theme-4 .pi-item.pi-image:before {
background-image: url("filepath://Item_Frame_4-Star.png");
}
.pi-theme-5 .pi-item.pi-image:before {
background-image: url("filepath://Item_Frame_5-Star.png");
}
/*
.pi-theme-4 .pi-item.pi-image:after {
background-image: url('SOMETHING-HERE');
}
*/