Skip to content

Clickable/Linkable Ticks #219

Answered by rokotyan
errantmind asked this question in Q&A
Jun 2, 2023 · 1 comments · 4 replies
Discussion options

You must be logged in to vote

@errantmind You can set up events for Axis components just like for any other component. Here's how to do it for a click event:

import { VisAxis,  ... } from '@unovis/react'
import { Axis } from '@unovis/ts'

...
<VisAxis
  ...
  events={{
    [Axis.selectors.tick]: {
      click: (tickValue: number) => console.log(tickValue),
    },
  }}
/>

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@errantmind
Comment options

@rokotyan
Comment options

@rokotyan
Comment options

@errantmind
Comment options

Answer selected by errantmind
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants