You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
A descendant can remove a text decoration it should only add to, because text-decoration is inherited instead of propagated #544
Part of #520 (step 23). Changes existing output: needs a decision.
In CSS, text-decoration is not inherited. An ancestor's decoration propagates to its in-flow descendants and is drawn over their text whatever they set, and text-decoration: none on a descendant removes only the descendant's own. Decorations do not propagate into floats, positioned blocks, inline blocks or tables.
mPDF carries text-decoration as an inherited property (InlinePropertyConverter, whose comment notes CSS does not inherit it). Measured on gravitypdf at d660a410, PHP 8.5.4.
vertical-align (super, sub) is carried to child blocks the same way, and CSS does not inherit it either.
Fix. Keep the decorations an element propagates as a set of their own, drawn over its descendants' text, and stop carrying text-decoration and vertical-align as inherited properties. This changes output where a document relies on text-decoration: none inside an underlined parent.
Tests. The rows above, a positioned block and a float inside an underlined block, and decorations from two ancestors combining.
Activity