Skip to content

Commit 6c27ff9

Browse files
committed
fix: exclude year
1 parent 98b8297 commit 6c27ff9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/timeunit.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ export function timeUnitSpecifierExpression(timeUnit: TimeUnit, {isAxis}: {isAxi
345345

346346
const timeUnitParts = getTimeUnitParts(timeUnit);
347347
if (isAxis) {
348-
if (timeUnitParts.includes('year')) {
348+
if (timeUnitParts.includes('year') && !timeUnitParts.includes('week')) {
349349
// If the timeUnit includes year (meaning it's a chronological timeUnit (aka datetime truncation),
350350
// then the default axis format is actually pretty smart.
351351
return undefined;

0 commit comments

Comments
 (0)