mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
more docs
This commit is contained in:
17
docs/examples/styles/width.py
Normal file
17
docs/examples/styles/width.py
Normal file
@@ -0,0 +1,17 @@
|
||||
from textual.app import App
|
||||
from textual.widget import Widget
|
||||
|
||||
|
||||
class WidthApp(App):
|
||||
CSS = """
|
||||
Widget {
|
||||
background: blue;
|
||||
width: 50%;
|
||||
}
|
||||
"""
|
||||
|
||||
def compose(self):
|
||||
yield Widget()
|
||||
|
||||
|
||||
app = WidthApp()
|
||||
Reference in New Issue
Block a user