plot
plot copied to clipboard
variable styles
This PR wants to make all of the common styles (or most of them) "variable" (#175, #380)
- [x] strokeDasharray (difficult case: we can't consider that an array is a columnar representation of a channel) 🌶
- [x] strokeDashoffset (number)
- [x] dx and dy
- [ ] DX without X, DY without Y?
- [ ] ~~mixBlendMode~~
- [ ] more?
for the text mark:
- [x] textAnchor
- [x] fontFamily
- [x] ~~fontSize~~ (was already variable)
- [x] fontStyle
- [x] fontVariant
- [x] fontWeight
I'm not sure how to make dx and dy variable when X or Y are not channels; I think I'll punt on this for now, because I don't want to overcomplicate the PR—my first prototype was making changes in each and every mark, depending on X, Y, and possibly cx, cy when X and Y were not defined… booo. The current approach which shifts X seems much better, but doesn't work when X is not a channel.
rebased
Fil, thanks for the work here. I would like to put this on hold to focus on animation and interaction. I am concerned that this generalization may make animation more difficult to implement. Let’s discuss this week.