مدیاویکی:Common.css: تفاوت میان نسخهها
از آیتالله گنجی
بدون خلاصۀ ویرایش |
بدون خلاصۀ ویرایش |
||
| خط ۱: | خط ۱: | ||
/* پایگاه اطلاعرسانی آیتالله گنجی — MediaWiki:Common.css */ | |||
/* پایگاه اطلاعرسانی آیتالله گنجی — MediaWiki:Common.css | |||
/* رنگها و فونت محلی */ | |||
@font-face { | @font-face { | ||
font-family: "Vazir"; | font-family: "Vazir"; | ||
| خط ۲۸: | خط ۲۱: | ||
--ganji-link: #075c87; | --ganji-link: #075c87; | ||
--ganji-border: #d5e1df; | --ganji-border: #d5e1df; | ||
--ganji-surface: # | --ganji-surface: #fff; | ||
--ganji-surface-soft: #f7faf9; | --ganji-surface-soft: #f7faf9; | ||
--ganji-radius: 8px; | --ganji-radius: 8px; | ||
| خط ۶۳: | خط ۵۶: | ||
} | } | ||
/* متن مقاله */ | |||
/* متن مقاله | |||
.mw-body-content, | .mw-body-content, | ||
.mw-parser-output { | .mw-parser-output { | ||
| خط ۸۱: | خط ۷۱: | ||
.mw-parser-output p { | .mw-parser-output p { | ||
margin | margin: .55em 0 1em; | ||
} | } | ||
.mw-body h1, | .mw-body h1, | ||
.mw-body h2, | .mw-body h2, | ||
| خط ۱۱۰: | خط ۹۸: | ||
} | } | ||
.mw-body a, | .mw-body a, | ||
.mw-parser-output a { | .mw-parser-output a { | ||
| خط ۱۳۸: | خط ۱۲۵: | ||
} | } | ||
pre, | pre, | ||
code, | code, | ||
| خط ۱۵۴: | خط ۱۴۰: | ||
} | } | ||
.mw-parser-output img, | .mw-parser-output img, | ||
.mw-file-description img, | .mw-file-description img, | ||
| خط ۱۶۷: | خط ۱۵۲: | ||
} | } | ||
.mw-parser-output blockquote { | .mw-parser-output blockquote { | ||
margin: 1.25em 0; | margin: 1.25em 0; | ||
| خط ۱۷۷: | خط ۱۶۱: | ||
} | } | ||
ol.references { | ol.references { | ||
font-size: 92%; | font-size: 92%; | ||
| خط ۱۸۹: | خط ۱۷۲: | ||
} | } | ||
/* جدولهای عمومی */ | |||
/* جدولهای عمومی | |||
.mw-parser-output .wikitable { | .mw-parser-output .wikitable { | ||
max-width: 100%; | max-width: 100%; | ||
| خط ۲۲۳: | خط ۲۰۳: | ||
} | } | ||
/* | /* جعبههای اطلاعاتی */ | ||
.infobox { | .infobox { | ||
float: left; | float: left; | ||
| خط ۲۸۴: | خط ۲۶۱: | ||
} | } | ||
/* گریدهای قدیمی */ | |||
/* گریدهای قدیمی | |||
.portal-container-2, | .portal-container-2, | ||
.portal-container-3, | .portal-container-3, | ||
| خط ۳۲۱: | خط ۲۹۵: | ||
} | } | ||
/* | /* صفحهٔ اصلی */ | ||
body.page-صفحهٔ_اصلی #firstHeading, | body.page-صفحهٔ_اصلی #firstHeading, | ||
body.page-صفحهٔ_اصلی .firstHeading { | body.page-صفحهٔ_اصلی .firstHeading { | ||
| خط ۳۳۴: | خط ۳۰۵: | ||
} | } | ||
/* جدول آرشیو دروس */ | |||
/* جدول آرشیو دروس | |||
.ganji-table-scroll { | .ganji-table-scroll { | ||
width: 100%; | width: 100%; | ||
| خط ۳۵۰: | خط ۳۱۸: | ||
table-layout: auto; | table-layout: auto; | ||
white-space: nowrap; | white-space: nowrap; | ||
} | } | ||
| خط ۳۶۱: | خط ۳۲۷: | ||
} | } | ||
/* | /* ستون جلسه هنگام اسکرول ثابت میماند. */ | ||
.ganji-archive-table th: | .ganji-archive-table th:first-child, | ||
.ganji-archive-table td: | .ganji-archive-table td:first-child { | ||
position: sticky; | position: sticky; | ||
right: 0; | right: 0; | ||
| خط ۳۷۴: | خط ۳۴۰: | ||
} | } | ||
.ganji-archive-table th:first-child { | |||
.ganji-archive-table th: | |||
z-index: 4; | z-index: 4; | ||
background: var(--ganji-primary-soft); | background: var(--ganji-primary-soft); | ||
| خط ۳۸۷: | خط ۳۵۲: | ||
border-radius: 6px; | border-radius: 6px; | ||
background: #fff; | background: #fff; | ||
color: | color: var(--ganji-text); | ||
font: inherit; | font: inherit; | ||
} | } | ||
| خط ۴۰۱: | خط ۳۶۶: | ||
} | } | ||
/* فهرست مطالب سفارشی */ | |||
/* فهرست مطالب سفارشی | |||
.ganji-sidebar-toc { | .ganji-sidebar-toc { | ||
width: 100%; | width: 100%; | ||
| خط ۴۳۹: | خط ۴۰۱: | ||
} | } | ||
.ganji-sidebar-toc a:hover { | .ganji-sidebar-toc a:hover, | ||
.ganji-sidebar-toc a.is-active { | |||
color: var(--ganji-primary); | color: var(--ganji-primary); | ||
} | } | ||
| خط ۴۵۳: | خط ۴۱۶: | ||
} | } | ||
/* ناوبری چسبان در دسکتاپ */ | |||
/* ناوبری | |||
@media (min-width: 768px) { | @media (min-width: 768px) { | ||
#mw-main-container > .row { | #mw-main-container > .row { | ||
| خط ۴۸۴: | خط ۴۴۴: | ||
} | } | ||
/* رابط مهمان: موارد مدیریتی و فوتر مخفی میشوند. */ | |||
/* رابط | |||
body.ganji-anonymous #p-namespaces, | body.ganji-anonymous #p-namespaces, | ||
body.ganji-anonymous #p-associated-pages, | body.ganji-anonymous #p-associated-pages, | ||
| خط ۵۰۰: | خط ۴۵۶: | ||
body.ganji-anonymous #footer-info, | body.ganji-anonymous #footer-info, | ||
body.ganji-anonymous #footer-places, | body.ganji-anonymous #footer-places, | ||
body.ganji-anonymous #footer-icons { | body.ganji-anonymous #footer-icons, | ||
body.ganji-anonymous .dropdown:has(#p-views), | |||
body.ganji-anonymous .dropdown:has(#p-cactions), | |||
body.ganji-anonymous .dropdown:has(#p-tb) { | |||
display: none !important; | display: none !important; | ||
} | } | ||
/* | /* برای کاربر واردشده هیچ منوی مدیریتی مخفی نمیشود. */ | ||
body.ganji- | body.ganji-authenticated #p-namespaces, | ||
body.ganji- | body.ganji-authenticated #p-views, | ||
body.ganji- | body.ganji-authenticated #p-cactions, | ||
body.ganji- | body.ganji-authenticated #p-tb, | ||
body.ganji- | body.ganji-authenticated #ca-ve-edit, | ||
body.ganji-authenticated #ca-edit { | |||
body.ganji- | visibility: visible !important; | ||
} | } | ||
/* | /* تبلت */ | ||
@media (max-width: 900px) { | @media (max-width: 900px) { | ||
.portal-container-4, | .portal-container-4, | ||
| خط ۵۳۵: | خط ۴۸۹: | ||
} | } | ||
/* موبایل */ | |||
@media (max-width: 650px) { | @media (max-width: 650px) { | ||
.mw-body-content, | .mw-body-content, | ||
| خط ۵۷۴: | خط ۵۲۹: | ||
} | } | ||
.mw-parser-output .wikitable:not(.ganji-archive-table) { | .mw-parser-output .wikitable:not(.ganji-archive-table) { | ||
display: block; | display: block; | ||
| خط ۵۸۳: | خط ۵۳۷: | ||
} | } | ||
.ganji-archive-table th: | .ganji-archive-table th:first-child, | ||
.ganji-archive-table td: | .ganji-archive-table td:first-child { | ||
width: 56px; | width: 56px; | ||
min-width: 56px; | min-width: 56px; | ||
max-width: 56px; | max-width: 56px; | ||
} | } | ||
} | } | ||
/* چاپ تمیز | /* چاپ تمیز */ | ||
@media print { | @media print { | ||
.ganji-table-search, | .ganji-table-search, | ||
| خط ۶۰۳: | خط ۵۵۶: | ||
text-decoration: none; | text-decoration: none; | ||
} | } | ||
} | } | ||
نسخهٔ ۱۰ سپتامبر ۲۰۲۶، ساعت ۱۸:۱۳
/* پایگاه اطلاعرسانی آیتالله گنجی — MediaWiki:Common.css */
/* رنگها و فونت محلی */
@font-face {
font-family: "Vazir";
src: url("/fonts/Vazir.woff2") format("woff2"),
url("/fonts/Vazir.woff") format("woff"),
url("/fonts/Vazir.ttf") format("truetype");
font-style: normal;
font-weight: 400;
font-display: swap;
}
:root {
--ganji-primary: #176b5b;
--ganji-primary-dark: #0f4c43;
--ganji-primary-soft: #eaf3f1;
--ganji-gold: #c69c42;
--ganji-text: #203b3f;
--ganji-muted: #66777b;
--ganji-link: #075c87;
--ganji-border: #d5e1df;
--ganji-surface: #fff;
--ganji-surface-soft: #f7faf9;
--ganji-radius: 8px;
}
*,
*::before,
*::after {
box-sizing: border-box;
}
html,
body {
direction: rtl;
}
html,
body,
.mw-body,
.mw-body-content,
.mw-parser-output,
.mw-ui-button,
button,
input,
textarea,
select {
font-family: "Vazir", Tahoma, Arial, sans-serif !important;
}
body {
color: var(--ganji-text);
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
}
/* متن مقاله */
.mw-body-content,
.mw-parser-output {
font-size: 16px;
line-height: 2.05;
}
.mw-parser-output p,
.mw-parser-output li {
overflow-wrap: anywhere;
text-align: justify;
text-justify: inter-word;
}
.mw-parser-output p {
margin: .55em 0 1em;
}
.mw-body h1,
.mw-body h2,
.mw-body h3,
.mw-body h4,
.mw-body h5,
.mw-body h6,
.mw-page-title-main,
.mw-headline {
color: var(--ganji-primary-dark);
font-family: "Vazir", Tahoma, Arial, sans-serif !important;
font-weight: 700;
line-height: 1.65;
}
.mw-body h2 {
margin-top: 1.8em;
padding-bottom: .35em;
border-bottom: 1px solid var(--ganji-border);
}
.mw-body h3 {
margin-top: 1.45em;
}
.mw-body a,
.mw-parser-output a {
color: var(--ganji-link);
text-decoration-thickness: 1px;
text-underline-offset: 3px;
}
.mw-parser-output a:visited {
color: #4f6680;
}
.mw-body a:hover,
.mw-body a:focus-visible,
.mw-parser-output a:hover,
.mw-parser-output a:focus-visible {
color: var(--ganji-primary-dark);
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
outline: 2px solid rgba(23, 107, 91, .45);
outline-offset: 2px;
}
pre,
code,
kbd,
samp,
.mw-code {
direction: ltr;
font-family: Consolas, "Courier New", monospace !important;
text-align: left;
}
pre {
max-width: 100%;
overflow-x: auto;
}
.mw-parser-output img,
.mw-file-description img,
.thumb img {
max-width: 100%;
height: auto !important;
}
.thumbinner,
.mw-default-size img {
border-radius: 6px;
}
.mw-parser-output blockquote {
margin: 1.25em 0;
padding: .8em 1.1em;
border: 0;
border-right: 4px solid var(--ganji-primary);
border-radius: var(--ganji-radius);
background: var(--ganji-surface-soft);
}
ol.references {
font-size: 92%;
line-height: 1.9;
}
li.mw-cite-dir-ltr,
.mw-content-ltr {
direction: ltr;
text-align: left;
}
/* جدولهای عمومی */
.mw-parser-output .wikitable {
max-width: 100%;
margin: 1.2em auto;
border: 1px solid var(--ganji-border);
border-collapse: collapse;
background: var(--ganji-surface);
}
.mw-parser-output .wikitable th,
.mw-parser-output .wikitable td {
padding: .6em .8em;
border: 1px solid var(--ganji-border);
text-align: right;
vertical-align: top;
}
.mw-parser-output .wikitable th {
background: var(--ganji-primary-soft);
color: var(--ganji-primary-dark);
font-weight: 700;
}
.mw-parser-output .wikitable tr:nth-child(even) td {
background: #fbfcfc;
}
.mw-parser-output .wikitable tr:hover td {
background: #f4f9f8;
}
/* جعبههای اطلاعاتی */
.infobox {
float: left;
clear: left;
width: 22em;
max-width: 38%;
margin: .5em 1.25em 1em 0;
padding: .3em;
border: 1px solid var(--ganji-border);
border-radius: var(--ganji-radius);
background: var(--ganji-surface-soft);
color: var(--ganji-text);
font-size: 92%;
line-height: 1.8;
}
.infobox th,
.infobox td {
padding: .4em .55em;
text-align: right;
vertical-align: top;
}
.infobox-title,
.infobox-above,
.infobox caption {
padding: .55em;
background: var(--ganji-primary-soft);
color: var(--ganji-primary-dark);
font-weight: 700;
text-align: center;
}
.navbox {
width: 100%;
margin: 1.25em auto;
overflow: hidden;
border: 1px solid var(--ganji-border);
border-radius: var(--ganji-radius);
background: var(--ganji-surface);
font-size: 92%;
text-align: center;
}
.navbox-title,
.navbox-abovebelow,
.navbox-group {
padding: .45em .75em;
background: var(--ganji-primary-soft);
color: var(--ganji-primary-dark);
font-weight: 700;
}
.navbox-list {
padding: .55em;
line-height: 1.9;
}
/* گریدهای قدیمی */
.portal-container-2,
.portal-container-3,
.portal-container-4,
.portal-container-5,
.portal-container-6 {
display: grid;
width: 100%;
gap: 15px;
}
.portal-container-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.portal-container-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.portal-container-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.portal-container-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.portal-container-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.portal-column-1-2,
.portal-column-1-3,
.portal-column-1-4,
.portal-column-1-5,
.portal-column-1-6 {
grid-column: span 1;
}
.portal-column-2-3,
.portal-column-2-4 {
grid-column: span 2;
}
.portal-column-3-4 {
grid-column: span 3;
}
/* صفحهٔ اصلی */
body.page-صفحهٔ_اصلی #firstHeading,
body.page-صفحهٔ_اصلی .firstHeading {
display: none;
}
body.page-صفحهٔ_اصلی .mw-body-content {
padding-top: 0;
}
/* جدول آرشیو دروس */
.ganji-table-scroll {
width: 100%;
overflow-x: auto;
overscroll-behavior-inline: contain;
-webkit-overflow-scrolling: touch;
}
.ganji-archive-table {
width: max-content !important;
min-width: 100%;
table-layout: auto;
white-space: nowrap;
}
.ganji-archive-table th,
.ganji-archive-table td {
white-space: nowrap;
text-align: right;
vertical-align: middle;
}
/* ستون جلسه هنگام اسکرول ثابت میماند. */
.ganji-archive-table th:first-child,
.ganji-archive-table td:first-child {
position: sticky;
right: 0;
z-index: 3;
width: 64px;
min-width: 64px;
max-width: 64px;
background: #f4f9f8;
box-shadow: -1px 0 0 var(--ganji-border);
}
.ganji-archive-table th:first-child {
z-index: 4;
background: var(--ganji-primary-soft);
}
.ganji-table-search {
width: min(100%, 430px);
margin: 0 0 1em;
padding: .65em .85em;
border: 1px solid #aebfbd;
border-radius: 6px;
background: #fff;
color: var(--ganji-text);
font: inherit;
}
.ganji-table-search:focus {
border-color: var(--ganji-primary);
outline: 2px solid rgba(31, 119, 112, .18);
}
.ganji-table-no-results {
margin: .5em 0 1em;
color: #8a3b32;
}
/* فهرست مطالب سفارشی */
.ganji-sidebar-toc {
width: 100%;
margin-top: 1.4em;
padding-top: 1em;
border-top: 1px solid var(--ganji-border);
direction: rtl;
text-align: right;
}
.ganji-sidebar-toc-title {
margin-bottom: .55em;
color: var(--ganji-primary-dark);
font-size: 110%;
font-weight: 700;
}
.ganji-sidebar-toc ul {
margin: 0;
padding: 0;
list-style: none;
}
.ganji-sidebar-toc li {
margin: .25em 0;
line-height: 1.7;
text-align: right;
}
.ganji-sidebar-toc a {
display: block;
color: var(--ganji-muted);
text-decoration: none;
}
.ganji-sidebar-toc a:hover,
.ganji-sidebar-toc a.is-active {
color: var(--ganji-primary);
}
.ganji-sidebar-toc .ganji-toc-level-h3 {
padding-right: .9em;
font-size: 94%;
}
.ganji-sidebar-toc .ganji-toc-level-h4 {
padding-right: 1.7em;
font-size: 90%;
}
/* ناوبری چسبان در دسکتاپ */
@media (min-width: 768px) {
#mw-main-container > .row {
align-items: flex-start;
}
#mw-navigation {
position: sticky !important;
top: 1rem;
align-self: flex-start;
max-height: calc(100vh - 2rem);
overflow-x: hidden;
overflow-y: auto;
overscroll-behavior: contain;
scrollbar-width: thin;
scrollbar-color: #aebfbd transparent;
}
#mw-navigation::-webkit-scrollbar {
width: 6px;
}
#mw-navigation::-webkit-scrollbar-thumb {
border-radius: 8px;
background: #aebfbd;
}
}
/* رابط مهمان: موارد مدیریتی و فوتر مخفی میشوند. */
body.ganji-anonymous #p-namespaces,
body.ganji-anonymous #p-associated-pages,
body.ganji-anonymous #p-views,
body.ganji-anonymous #p-cactions,
body.ganji-anonymous #p-tb,
body.ganji-anonymous .page-actions,
body.ganji-anonymous .printfooter,
body.ganji-anonymous .mw-body-footer,
body.ganji-anonymous footer.mw-footer,
body.ganji-anonymous #footer-info,
body.ganji-anonymous #footer-places,
body.ganji-anonymous #footer-icons,
body.ganji-anonymous .dropdown:has(#p-views),
body.ganji-anonymous .dropdown:has(#p-cactions),
body.ganji-anonymous .dropdown:has(#p-tb) {
display: none !important;
}
/* برای کاربر واردشده هیچ منوی مدیریتی مخفی نمیشود. */
body.ganji-authenticated #p-namespaces,
body.ganji-authenticated #p-views,
body.ganji-authenticated #p-cactions,
body.ganji-authenticated #p-tb,
body.ganji-authenticated #ca-ve-edit,
body.ganji-authenticated #ca-edit {
visibility: visible !important;
}
/* تبلت */
@media (max-width: 900px) {
.portal-container-4,
.portal-container-5,
.portal-container-6 {
grid-template-columns: repeat(2, minmax(0, 1fr));
}
.infobox {
float: none;
width: 100%;
max-width: 100%;
margin: 1em 0;
}
}
/* موبایل */
@media (max-width: 650px) {
.mw-body-content,
.mw-parser-output {
font-size: 15px;
line-height: 1.95;
}
.mw-body h1,
.mw-page-title-main {
font-size: 1.65rem;
}
.mw-body h2 {
margin-top: 1.5em;
font-size: 1.35rem;
}
.portal-container-2,
.portal-container-3,
.portal-container-4,
.portal-container-5,
.portal-container-6 {
display: block;
}
.portal-container-2 > *,
.portal-container-3 > *,
.portal-container-4 > *,
.portal-container-5 > *,
.portal-container-6 > * {
margin-bottom: 14px;
}
.portal-column-2-3,
.portal-column-2-4,
.portal-column-3-4 {
grid-column: auto;
}
.mw-parser-output .wikitable:not(.ganji-archive-table) {
display: block;
width: 100%;
overflow-x: auto;
white-space: nowrap;
-webkit-overflow-scrolling: touch;
}
.ganji-archive-table th:first-child,
.ganji-archive-table td:first-child {
width: 56px;
min-width: 56px;
max-width: 56px;
}
}
/* چاپ تمیز */
@media print {
.ganji-table-search,
.ganji-sidebar-toc {
display: none !important;
}
.mw-parser-output a {
color: #000;
text-decoration: none;
}
}