mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
Update test over user css over widget css to show important widget css can be overridden by users too
This commit is contained in:
@@ -2,5 +2,5 @@
|
|||||||
height: 50%;
|
height: 50%;
|
||||||
width: 50%;
|
width: 50%;
|
||||||
align: center middle;
|
align: center middle;
|
||||||
background: green;
|
background: blue;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -108,7 +108,7 @@ def test_stylesheet_apply_user_css_over_widget_css():
|
|||||||
user_css = ".a {color: red; tint: yellow;}"
|
user_css = ".a {color: red; tint: yellow;}"
|
||||||
|
|
||||||
class MyWidget(Widget):
|
class MyWidget(Widget):
|
||||||
CSS = ".a {color: blue; background: lime;}"
|
CSS = ".a {color: blue !important; background: lime;}"
|
||||||
|
|
||||||
node = MyWidget()
|
node = MyWidget()
|
||||||
node.add_class("a")
|
node.add_class("a")
|
||||||
|
|||||||
Reference in New Issue
Block a user