File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed
lib/components/data-vis/line-chart
wrappers/components/data-vis/line-chart/line-chart Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change 40
40
fill ={labelTextColor }
41
41
bind:contentRect ={textDimensions }
42
42
>
43
- {tooltipContent }
43
+ {#if typeof tooltipContent === " string" }
44
+ {tooltipContent }
45
+ {:else }
46
+ {@render tooltipContent ()}
47
+ {/if }
44
48
</text >
45
49
</g >
46
50
</svg >
Original file line number Diff line number Diff line change 80
80
<CodeBlock code ={codeBlocks .codeBlock1 } language =" svelte" ></CodeBlock >
81
81
{/ snippet }
82
82
83
+ {#snippet ContentSnippet ()}
84
+ <p >Service update</p >
85
+ {/ snippet }
86
+
83
87
{#snippet Example4 ()}
84
88
<div class =" p-5 bg-white" >
85
89
<LineChart
88
92
y =" y"
89
93
series =" areaCode"
90
94
basicLineParams ={{ markers : true , interactive : true }}
95
+ tooltipContent ={ContentSnippet }
91
96
></LineChart >
92
97
</div >
93
98
<CodeBlock code ={codeBlocks .codeBlock1 } language =" svelte" ></CodeBlock >
You can’t perform that action at this time.
0 commit comments