mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
Merge pull request #566 from Textualize/hsl
Support HSL colour space, allow spaces in RGB/HSL values
This commit is contained in:
11
sandbox/hsl.py
Normal file
11
sandbox/hsl.py
Normal file
@@ -0,0 +1,11 @@
|
||||
from textual.app import App, ComposeResult
|
||||
from textual.widgets import Static
|
||||
|
||||
|
||||
class HSLApp(App):
|
||||
def compose(self) -> ComposeResult:
|
||||
yield Static(classes="box")
|
||||
|
||||
|
||||
app = HSLApp(css_path="hsl.scss", watch_css=True)
|
||||
app.run()
|
||||
5
sandbox/hsl.scss
Normal file
5
sandbox/hsl.scss
Normal file
@@ -0,0 +1,5 @@
|
||||
.box {
|
||||
height: 1fr;
|
||||
/*background: rgb(180,50, 50);*/
|
||||
background: hsl(180,50%, 50%);
|
||||
}
|
||||
Reference in New Issue
Block a user