Update animate for trendlines

This commit is contained in:
Nate Kelley 2025-05-09 13:12:08 -06:00
parent 49c8f08fe9
commit 0d9bde27de
No known key found for this signature in database
GPG Key ID: FD90372AB8D98B4F
2 changed files with 8 additions and 3 deletions

View File

@ -19,10 +19,12 @@ test('Invite User', async ({ page }) => {
await page.getByRole('button').filter({ hasText: /^$/ }).first().click();
await page.getByRole('link', { name: 'Users' }).click();
await page.waitForTimeout(1000);
await page.waitForTimeout(5000);
await page.waitForLoadState('networkidle');
await page.waitForLoadState('domcontentloaded');
await expect(page.getByRole('link', { name: 'nate+integration-test@buser.' })).toBeVisible();
await expect(page.getByRole('link', { name: 'nate+integration-test@buser.' })).toBeVisible({
timeout: 20000
});
await expect(page.getByRole('main')).toMatchAriaSnapshot(`
- img
- text: nate+integration-test@buser.so Restricted Querier

View File

@ -69,6 +69,7 @@ export const useTrendlines = ({
type: 'line',
borderColor: trendline.trendLineColor || 'black',
borderWidth: 1.5,
label: {
content: labelContent,
display: trendline.showTrendlineLabel,
@ -111,6 +112,7 @@ export const useTrendlines = ({
stack: id,
tension: 0.25,
order: -1,
animation: false,
datalabels: showTrendlineLabel
? {
...defaultLabelOptionConfig,
@ -124,10 +126,11 @@ export const useTrendlines = ({
const trendlineLabel = trendlineLabelProp ? trendlineLabelProp : label[0].value;
return `${trendlineLabel || 'Trendline'}`;
},
//@ts-ignore
yAdjust: -10
}
: undefined
};
} satisfies ChartProps<'line'>['data']['datasets'][number];
}
);