mediawiki-extensions-CodeMi.../resources
Thiemo Kreuz 3e9bb4fb08 Replace all .png images with rgba() background colors
The rgba() syntax is supported for a very, very long time now:
https://caniuse.com/#feat=mdn-css_types_color_alpha

Notes:

I realized the numbers in these file names are actually their
transparency in percent (more precisely their opaqueness).
4 is 4% which translates to 0.04 in the rgba() syntax.

I used Gimp to pick the opaque color values from the images.
Gimp makes this easy. No guesswork or calculations needed.

For multiple, stacked images I calculated the colors by
averaging their RGB values (considering how opaque each color
is). Note this is actually *more* precise than the stacked
images before. Stacking alpha colors is flawed. For example:
Let's say we have an rgba(255, 255, 255, 1) background.
Layering a half transparent rgba(255, 0, 0, 0.5) on top means
half the background shines through. This averages to
rgba( 255, 127, 127, 1). Now we stack rgba(0, 0, 0, 0.5) on
top. Again, half the background shines through, resulting in
rgba(127, 63, 63, 1).

When we apply the two colors the other way around, the result
is rgba(191, 63, 63, 1), a much brighter red.

This flaw doesn't happen when precalculating the averages, as
done in this patch.

Change-Id: I29026864714c5f90c2613af57f08693e7e2b996c
2020-08-11 14:24:20 +02:00
..
lib Unify monospace font stack. Avoid potential sizing bug caused by weird browser behavior with font-family: monospace; 2020-02-28 04:44:07 +00:00
mode/mediawiki Replace all .png images with rgba() background colors 2020-08-11 14:24:20 +02:00
modules/ve-cm Load pluginModules in CodeMirrorAction class 2020-07-10 17:12:23 +06:00
ext.CodeMirror.js Fix 'setSelection' in textSelection API 2020-07-12 15:10:58 +00:00
ext.CodeMirror.less Don't let CodeMirror set the font to monospace if it's set on an ancestor. 2020-02-29 18:01:27 +00:00