loading up the forgejo repo on tangled to test page performance
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add dark mode to API Docs (#24971)

Add a dark mode to Swagger UI via CSS `invert`. No toggle or anything,
but I think it's better than nothing. Users can toggle via their OS.

Also includes a few misc CSS cleanups on the page.

<img width="1264" alt="Screenshot 2023-05-28 at 20 25 06"
src="https://github.com/go-gitea/gitea/assets/115237/de761b85-ca0c-4220-bee4-73798a4360a0">
<img width="1260" alt="Screenshot 2023-05-28 at 20 02 54"
src="https://github.com/go-gitea/gitea/assets/115237/29188ed2-c167-47f5-bf28-46193d1da22c">

authored by

silverwind and committed by
GitHub
faf8557b acb13afb

+17 -6
+17 -6
web_src/css/standalone/swagger.css
··· 1 - html { 2 - box-sizing: border-box; 3 - overflow-y: scroll; 4 - } 5 - 6 1 *, 7 2 *::before, 8 3 *::after { 9 - box-sizing: inherit; 4 + box-sizing: border-box; 10 5 } 11 6 12 7 body { ··· 24 19 align-items: center; 25 20 } 26 21 22 + .swagger-back-link:hover { 23 + text-decoration: underline; 24 + } 25 + 27 26 .swagger-back-link svg { 28 27 color: inherit; 29 28 fill: currentcolor; 30 29 margin-right: 0.5rem; 31 30 } 31 + 32 + @media (prefers-color-scheme: dark) { 33 + body { 34 + background: #1e1e1e; 35 + } 36 + .swagger-ui, .swagger-back-link { 37 + filter: invert(88%) hue-rotate(180deg); 38 + } 39 + .swagger-ui .microlight { 40 + filter: invert(100%) hue-rotate(180deg); 41 + } 42 + }