Spaces:
Running
Running
Marc Skov Madsen commited on
Commit ·
ffec32f
1
Parent(s): 5fc3721
document issue
Browse files
README.md
CHANGED
|
@@ -30,3 +30,7 @@ panel serve app.py --dev
|
|
| 30 |
ruff format
|
| 31 |
ruff check --fix;
|
| 32 |
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 30 |
ruff format
|
| 31 |
ruff check --fix;
|
| 32 |
```
|
| 33 |
+
|
| 34 |
+
## Known Issues
|
| 35 |
+
|
| 36 |
+
- [ColorMap dark styling](https://github.com/holoviz/panel/issues/7360)
|
script.py
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import panel as pn
|
| 2 |
+
import colorcet as cc
|
| 3 |
+
|
| 4 |
+
pn.extension()
|
| 5 |
+
|
| 6 |
+
CMAP_CSS = (
|
| 7 |
+
"div, div:hover {background: var(--panel-surface-color); color: current}" if pn.config.theme == "dark" else ""
|
| 8 |
+
)
|
| 9 |
+
|
| 10 |
+
cmap = pn.widgets.ColorMap(options=cc.palette, ncols=3, swatch_width=100, margin=(0, 0, 200, 0), stylesheet=[CMAP_CSS])
|
| 11 |
+
|
| 12 |
+
pn.template.FastListTemplate(
|
| 13 |
+
sidebar=[cmap],
|
| 14 |
+
main_layout=None,
|
| 15 |
+
theme="dark"
|
| 16 |
+
).servable()
|