Merge pull request #566 from Textualize/hsl

Support HSL colour space, allow spaces in RGB/HSL values
This commit is contained in:
Will McGugan
2022-06-08 16:25:15 +01:00
committed by GitHub
9 changed files with 138 additions and 18 deletions

11
sandbox/hsl.py Normal file
View 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
View File

@@ -0,0 +1,5 @@
.box {
height: 1fr;
/*background: rgb(180,50, 50);*/
background: hsl(180,50%, 50%);
}