- Edit page on Wikitech
- Insert Template: Archive with parameter date having value 2013.
- Insert
Expected: Rainbow background color on the right.
Actual: No background color on the right.
This is because the HTML that was inserted by VisualEditor is as follows
<span style="display: inline-block; float: right; margin: rgba(255, 0, 0, 0.3), rgba(255, 255, 0, 0.3), rgba(0, 255, 0, 0.3), rgba(0, 255, 255, 0.3), rgba(0, 0, 255, 0.3), rgba(255, 0, 255, 0.3), rgba(255, 0, 0, 0.3)); color: #fff; text-shadow: 0 0 20px deepskyblue, 0 0 20px deepskyblue, 0 0 20px deepskyblue, 0 0 30px deepskyblue, 0 0 45px deepskyblue, 0 0 50px deepskyblue, 0 0 55px deepskyblue, 0 0 60px deepskyblue, 0 0 70px deepskyblue;">2013</span>
Note the part margin: rgba(255, 0, 0, 0.3), ....
Original template:
<span style="display: inline-block; float: right; margin: /*negate mbox-text padding */-0.125em -0.45em; padding: 1em 2em; font-weight: bold; font-size: 2em; text-align: center; line-height: 2; letter-spacing: -1px; background-color: #111; background-image: linear-gradient(to right, /*rainbow*/ rgba(255, 0, 0, 0.3), ...
It seems Parsoid or the Parse API or Tidy is breaking this somehow. By stripping all of /*negate mbox-text padding */-0.125em -0.45em; padding: 1em 2em; font-weight: bold; font-size: 2em; text-align: center; line-height: 2; letter-spacing: -1px; background-color: #111; background-image: linear-gradient(to right, /*rainbow*/.
This does not happen when saving a page and having it rendered by the PHP Parser.

