Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds Tooltip to Y Axis Number of Ticks #1344

Merged
merged 1 commit into from
Jun 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion packages/chart/src/components/EditorPanel/EditorPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1173,7 +1173,17 @@ const EditorPanel = () => {
{config.runtime.seriesKeys && config.runtime.seriesKeys.length === 1 && !['Box Plot', 'Deviation Bar', 'Forest Plot'].includes(config.visualizationType) && (
<CheckBox value={config.isLegendValue} fieldName='isLegendValue' label='Use Legend Value in Hover' updateField={updateField} />
)}
<TextField value={config.yAxis.numTicks} placeholder='Auto' type='number' section='yAxis' fieldName='numTicks' label='Number of ticks' className='number-narrow' updateField={updateField} />
<TextField value={config.yAxis.numTicks} placeholder='Auto' type='number' section='yAxis' fieldName='numTicks' label='Number of ticks' className='number-narrow'
tooltip={
<Tooltip style={{ textTransform: 'none' }}>
<Tooltip.Target>
<Icon display='question' style={{ marginLeft: '0.5rem', display: 'inline-block', whiteSpace: 'nowrap' }} />
</Tooltip.Target>
<Tooltip.Content>
<p>Apporoximate number of ticks. Other factors such as space available and data may change the exact number of ticks used.</p>
</Tooltip.Content>
</Tooltip>
} updateField={updateField} />
<TextField
value={config.yAxis.size}
type='number'
Expand Down