Update x axis to include source

This commit is contained in:
Nate Kelley 2025-09-24 23:28:36 -06:00
parent 6d50a9ddc3
commit 987644933a
No known key found for this signature in database
GPG Key ID: FD90372AB8D98B4F
2 changed files with 4 additions and 2 deletions

View File

@ -259,8 +259,9 @@ export const useXAxis = ({
ticks: {
...rotation,
major: {
enabled: false, //test
enabled: false,
},
source: type === 'time' ? ('data' as const) : undefined,
autoSkip: true,
maxTicksLimit: type === 'time' ? (timeUnit === 'month' ? 18 : 18) : undefined,
// sampleSize: type === 'time' ? 28 : undefined, //DO NOT USE THIS. IT BREAK TIME SCALES
@ -270,6 +271,7 @@ export const useXAxis = ({
time: {
unit: timeUnit,
},
includeBounds: true,
},
grid,
} satisfies DeepPartial<ScaleChartOptions<'bar'>['scales']['x']>;

View File

@ -2631,7 +2631,7 @@ export const WithQuarterAndYearXAxis: Story = {
},
};
export const WithQuarterNumber: Story = {
export const WithQuarterNumber_PermantBroken: Story = {
args: {
colors: [
'#B399FD',