forgejo/web_src/less
silverwind fd4e7447e7
Fix opaque background on mermaid diagrams (#21642) (#21652)
Backport #21642

Browsers introduce a opaque background on iframes if the iframe
element's color-scheme does not match the document's color scheme which
in case of a dark theme results in a mismatch and the browser adds a
white background. Avoid this by specifying the same color scheme outside
and inside the iframe.

See https://fvsch.com/transparent-iframes for more info.

My initial attempt was to make the iframe document the same color-scheme
as the parent page (light or dark) but with that, there was a ugly
background flash on load in Chrome because Chrome apparently always
loads iframe in light scheme initially. Firefox still shows a background
flash on load but this is not possible to get rid of and it's certainly
a browser bug.

Before:
<img width="1147" alt="Screen Shot 2022-10-31 at 13 30 55"
src="https://user-images.githubusercontent.com/115237/199017132-9828aace-bdd0-4ede-8118-359e72bcf2fe.png">

After:
<img width="1152" alt="Screen Shot 2022-10-31 at 13 30 36"
src="https://user-images.githubusercontent.com/115237/199017137-989a9e67-3fe0-445f-a191-df5bf290dabf.png">
2022-11-01 22:31:17 +00:00
..
chroma Improve arc-green code theme (#21039) 2022-09-03 23:24:18 +08:00
code
codemirror Support Issue forms and PR forms (#20987) 2022-09-02 15:58:49 +08:00
console
features Fix doc and heatmap for the Vue3 refactoring (#21312) 2022-10-02 10:13:44 +08:00
markup Fix opaque background on mermaid diagrams (#21642) (#21652) 2022-11-01 22:31:17 +00:00
modules
shared
standalone
themes Use CSS color-scheme instead of invert (#21616) (#21623) 2022-10-29 13:24:57 +08:00
_admin.less
_base.less Use CSS color-scheme instead of invert (#21616) (#21623) 2022-10-29 13:24:57 +08:00
_dashboard.less Add code highlighting in issue titles (#21432) 2022-10-16 02:24:41 +08:00
_editor.less
_explore.less Remove fomantic image module (#21145) 2022-09-12 17:08:46 +08:00
_font_i18n.less
_form.less Add system setting table with cache and also add cache supports for user setting (#18058) 2022-10-17 07:29:26 +08:00
_home.less
_install.less
_organization.less Add team member invite by email (#20307) 2022-10-19 14:40:28 +02:00
_package.less Fix empty container layer history and UI (#21251) 2022-09-27 15:03:24 +02:00
_repository.less Improve code comment review on mobile (#21461) 2022-10-25 19:11:49 +08:00
_review.less Improve code comment review on mobile (#21461) 2022-10-25 19:11:49 +08:00
_svg.less
_tribute.less CSS color enhancements (#21534) 2022-10-23 12:05:20 +08:00
_user.less
animations.less Consolidate more CSS colors into variables (#21402) 2022-10-12 12:26:27 -04:00
helpers.less Improve code comment review on mobile (#21461) 2022-10-25 19:11:49 +08:00
index.less Fix empty container layer history and UI (#21251) 2022-09-27 15:03:24 +02:00
variables.less