mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Ensure that text nodes don't inherit opacity.
This commit is contained in:
parent
9baa59a6b4
commit
b954432b60
4 changed files with 71 additions and 0 deletions
|
@ -6958,6 +6958,12 @@ pub fn modify_style_for_text(style: &mut Arc<ComputedValues>) {
|
|||
padding.padding_bottom = computed::LengthOrPercentage::Length(Au(0));
|
||||
padding.padding_left = computed::LengthOrPercentage::Length(Au(0));
|
||||
}
|
||||
|
||||
if style.effects.opacity != 1.0 {
|
||||
let mut style = Arc::make_mut(style);
|
||||
let mut effects = Arc::make_mut(&mut style.effects);
|
||||
effects.opacity = 1.0;
|
||||
}
|
||||
}
|
||||
|
||||
/// Adjusts the `margin` property as necessary to account for the text of an `input` element.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue