@mocanvas/mocanvas · interface
interface TLUiSliderPropsThe chrome's slider — opacity, and anything else an app puts in the style panel.
Two callbacks rather than one: onValueChange fires continuously while
dragging, onHistoryMark once when the drag begins. The document mark has
to be taken before the first change, or the whole drag lands in the undo
stack as one entry per pixel.
Methods · 1
onValueChange(value: number): voidProperties · 8
className?: stringdisabled?: booleanlabel: stringonHistoryMark?(id: string): voidCalled once per interaction, before the first onValueChange.
steps: numberNumber of steps. The slider runs 0..steps.
style?: CSSPropertiestitle?: stringvalue: number | nullCurrent value, in steps. null when the selection disagrees.
mocanvas is built by Symbio. Free for non-commercial, non-profit and development use; commercial use needs an agreement. Not affiliated with or endorsed by tldraw.