MediaWiki:Gadget-ohc-copy-code.css: Difference between revisions
MediaWiki interface page
More languages
More actions
Content deleted Content added
Style the code copy buttons (via create-page on MediaWiki MCP Server) |
Bot: careui — stub out; superseded by the token-based rules in MediaWiki:Common.css. Removes a stale copy of the retired teal palette - Claude |
||
| Line 1: | Line 1: | ||
/* MediaWiki:Gadget-ohc-copy-code.css |
|||
/* ohc-copy-code — pill "Copy" buttons on code blocks (OHC teal) */ |
|||
SUPERSEDED -- do not restore the rules that used to live here. |
|||
pre.ohc-copy-code { |
|||
position: relative; |
|||
} |
|||
These styles are now in MediaWiki:Common.css section 5, built on the careui |
|||
pre.ohc-copy-code .ohc-copy-btn { |
|||
--ohc-* token layer. That file is part of `site.styles`, which MediaWiki |
|||
position: absolute; |
|||
loads on every page for every skin, so the styling applies whether or not |
|||
top: 0.55em; |
|||
the Gadgets extension is ever enabled. |
|||
right: 0.55em; |
|||
z-index: 1; |
|||
font-family: 'Switzer', 'Figtree', system-ui, sans-serif; |
|||
font-size: 0.72em; |
|||
font-weight: 600; |
|||
line-height: 1; |
|||
padding: 0.4em 0.8em; |
|||
border-radius: 999px; |
|||
cursor: pointer; |
|||
color: #0f8b6c; |
|||
background: rgba(247, 249, 246, 0.92); |
|||
border: 1px solid #d8e1db; |
|||
box-shadow: 0 1px 3px rgba(23, 61, 52, 0.12); |
|||
transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease; |
|||
} |
|||
The previous contents hardcoded the retired ohc.network palette (teal |
|||
pre.ohc-copy-code .ohc-copy-btn:hover { |
|||
#0f8b6c, ink #173d34, lime #b8f36f, sage #d8e1db) and had no dark-mode |
|||
background: #0f8b6c; |
|||
handling. Kept as an empty stub rather than deleted so that |
|||
color: #ffffff; |
|||
MediaWiki:Gadgets-definition keeps resolving if Gadgets is installed later. |
|||
transform: translateY(-1px); |
|||
} |
|||
Reference: [[OHC Network Wiki:Design/careui]] */ |
|||
pre.ohc-copy-code .ohc-copy-btn.ohc-copied { |
|||
background: #12806a; |
|||
color: #ffffff; |
|||
} |
|||
@media (prefers-reduced-motion: reduce) { |
|||
pre.ohc-copy-code .ohc-copy-btn { |
|||
transition: none; |
|||
} |
|||
} |
|||