Hi I am using TS visual embed SDK to

Hi, I am using TS visual embed SDK to display a visualization. The visualization contains table with rows and columns. I am aiming to add a click event on one of the column names. On click I need to access the row info and use it to navigate to other page within my application. Tried multiple solution from docs(ex: EmbedEvent.VizPointClick) and some other sources. Still getting errors. What is the right way to implement this? import { LiveboardEmbed, EmbedEvent } from '@thoughtspot/visual-embed-sdk/react'; const handleVizPointClick = (data) => { // Access the row information from the data object const row = data.clickedPoint.selectedAttributes[0].value; console.log('Clicked row:', row); }; <LiveboardEmbed // Other props on={EmbedEvent.VizPointClick} callback={handleVizPointClick} />
5 Replies
bill_da_golfer
bill_da_golfer17mo ago
What's the error you are getting?
ashish
ashish17mo ago
<LiveboardEmbed
// Other props
onVizPointClick={handleVizPointClick}
/>
<LiveboardEmbed
// Other props
onVizPointClick={handleVizPointClick}
/>
Reference https://developers.thoughtspot.com/docs/react-app-embed#_liveboard_embed_code_sample
CallMeSam
CallMeSamOP17mo ago
Type ' { frameParams: { height: string; }; on: EmbedEvent; callback: (data: any) => void; runtimeFilters: RuntimeFilter[]; visibleActions: undefined[]; liveboardId: string; vizId: string; }' is not assignable to type 'IntrinsicAttributes & LiveboardProps & RefAttributes<LiveboardEmbed>'. Property 'on' does not exist on type 'IntrinsicAttributes & LiveboardProps & RefAttributes<LiveboardEmbed>'.ts(2322) (property) on: EmbedEvent
Mohamed Abdulla
Mohamed Abdulla17mo ago
@CallMeSam I hope the issue is already resolved

Did you find this page helpful?