part 4 of filter/sort drilldown onChartDatum click (#16142)

This commit is contained in:
nitin
2025-11-27 22:33:10 +05:30
committed by GitHub
parent d4b3a8978d
commit 32a876bbd4
10 changed files with 629 additions and 4 deletions
@@ -0,0 +1,13 @@
import { ObjectRecordGroupByDateGranularity } from 'twenty-shared/types';
import { isDefined } from 'twenty-shared/utils';
export const isCyclicalDateGranularity = (
granularity?: ObjectRecordGroupByDateGranularity | null,
): boolean => {
if (!isDefined(granularity)) return false;
return [
ObjectRecordGroupByDateGranularity.DAY_OF_THE_WEEK,
ObjectRecordGroupByDateGranularity.MONTH_OF_THE_YEAR,
ObjectRecordGroupByDateGranularity.QUARTER_OF_THE_YEAR,
].includes(granularity);
};