Published
Edited
Jul 27, 2022
2 stars
Insert cell
Insert cell
Insert cell
Color = import("https://colorjs.io/dist/color.js").then((r) => r.default)
Insert cell
Insert cell
Color2 = (await import("https://colorjs.io/dist/color.js")).default
Insert cell
Insert cell
Insert cell
color = new Color(input)
Insert cell
Insert cell
changed = new Color(input).to("lch").set(lch)
Insert cell
<div style=${{background: changed, color: changed.lch.l > 50 ? "black" : "white", padding: "50px"}}>
${changed}
</div>
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more