mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
Renaming opacity to text-opacity in code
This commit is contained in:
@@ -1098,15 +1098,15 @@ class TestParseOpacity:
|
||||
],
|
||||
)
|
||||
def test_opacity_to_styles(self, css_value, styles_value):
|
||||
css = f"#some-widget {{ opacity: {css_value} }}"
|
||||
css = f"#some-widget {{ text-opacity: {css_value} }}"
|
||||
stylesheet = Stylesheet()
|
||||
stylesheet.add_source(css)
|
||||
|
||||
assert stylesheet.rules[0].styles.opacity == styles_value
|
||||
assert stylesheet.rules[0].styles.text_opacity == styles_value
|
||||
assert not stylesheet.rules[0].errors
|
||||
|
||||
def test_opacity_invalid_value(self):
|
||||
css = "#some-widget { opacity: 123x }"
|
||||
css = "#some-widget { text-opacity: 123x }"
|
||||
stylesheet = Stylesheet()
|
||||
|
||||
with pytest.raises(StylesheetParseError):
|
||||
|
||||
Reference in New Issue
Block a user