Jump to content

Template:Last incident/styles.css

From Wikitech
Revision as of 14:19, 27 June 2024 by Majavah (talk | contribs) (dark mode support)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
.mw-tpl-lastincident-wrapper,
.mw-tpl-createincidentreport-box {
  margin: 0 auto;
  min-width: 80%;
  max-width: 45em;
}


.mw-tpl-createincidentreport-box .mw-inputbox-centered,
.mw-tpl-createincidentreport-box form.createbox {
  /* [[mw:Extension:InputBox]] supports "inline=true" on "type=search2" only, not in "type=create"... */
  display: inline-block;
}

.mw-tpl-lastincident-wrapper .mw-tpl-lastincident-result {
  margin: 1em 0;
  border: 1px solid var( --border-color-content-removed, #fc3 );
  background: var( --background-color-warning-subtle, #fef6e7 );
  font-size: larger;
}

.mw-tpl-lastincident-wrapper .mw-tpl-lastincident-result:before {
  content: "Incident on " attr(data-date);
  font-weight: bold;
  background: var( --background-color-content-removed, #fc3 );
  color: var( --color-emphasized, #000 );
  display: block;
  padding: 0.5em 1em;
}

.mw-tpl-lastincident-wrapper .mw-tpl-lastincident-result ul {
  list-style: none;
  margin: 0.5em 1em;
}

.mw-tpl-lastincident-wrapper .mw-tpl-lastincident-result ul li::first-letter {
  text-transform: uppercase;
}

.mw-tpl-lastincident-wrapper .mw-tpl-lastincident-noresult {
  margin: 1em 0;
  background: var( --background-color-success-subtle, #00af89 );
  color: var( --color-base, #202122 );
  border: 1px solid var( --border-color-success, #096450 );
  padding: 0.5em 1em;
}

/* Hide empty lists. */
.mw-tpl-lastincident-result:empty,
/* Hide any list after the first non-empty list. */
.mw-tpl-lastincident-result:not(:empty) ~ .mw-tpl-lastincident-result,
/* Hide "noresults" if we have any non-empty lists. */
.mw-tpl-lastincident-result:not(:empty) ~ .mw-tpl-lastincident-noresult {
    display: none;
}


/* Hide "Create incident" box when logged-out or on mobile. */
.mw-tpl-createincidentreport-box {
  display: none;
  width: auto;
}
body.mw-editable:not(.skin-minerva) .mw-tpl-createincidentreport-box {
  display: block;
}