Slackbot
05/01/2023, 7:40 PMangie
05/01/2023, 7:42 PMGordon Tu
05/01/2023, 8:03 PMviewof
cell.
1. You can set the programmatic value as something like chartCell1 = {…return html
chartElement` }`, and it presents a HTML UI in return.
2. but you can change chartElement.value
when clicking or hovering the elements. It will be returned as chartCell1
. Use chartCell1
as the interactively updated variable in the second chart cell.
Just a thought. It would be awesome if there are other approaches or examples.😅Fabian Iwand
05/01/2023, 8:36 PMhtl.html`<div>
${swatch}
<div style="margin-top: 20px; display: grid; grid-template-columns: .8fr 1fr">
${donutchart}
${parallelchart}
`
Doing so will remove them from their original cells, as an element can only exist at one place in the DOM. You'll notice that the original cells will now display <detached>
.Fabian Iwand
05/01/2023, 9:04 PMangie
05/01/2023, 9:13 PMcolorView = html`<value=chart>`
doesn't do itGordon Tu
05/01/2023, 9:15 PMviewof color = {
`let angie = html`<input type="color" value="#0000ff">``
console.log(angie.value)
return angie
}
Fabian Iwand
05/01/2023, 9:27 PMFabian Iwand
05/01/2023, 10:21 PMangie
05/01/2023, 10:41 PM