Skip to content

Commit

Permalink
chore(client-core): extend client types with custom granularity support
Browse files Browse the repository at this point in the history
  • Loading branch information
KSDaemon committed Sep 18, 2024
1 parent 4875b8e commit 05fea71
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/cubejs-client-core/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -943,10 +943,15 @@ declare module '@cubejs-client/core' {
format?: 'currency' | 'percent';
};

export type TCubeTimeDimensionGranularity = {
name: string;
title: string;
}

export type TCubeDimension = BaseCubeMember & {
primaryKey?: boolean;
suggestFilterValues: boolean;
};
} & (BaseCubeMember["type"] extends 'time' ? { granularities?: TCubeTimeDimensionGranularity[] } : {});

export type TCubeSegment = Omit<BaseCubeMember, 'type'>;

Expand Down

0 comments on commit 05fea71

Please sign in to comment.