import { createFormatter } from '../datelib/formatting' ; export function computeFallbackHeaderFormat ( datesRepDistinctDays , dayCnt ) { if ( ! datesRepDistinctDays || dayCnt > 10 ) { return createFormatter ( { weekday : 'short' } ) ; } if ( dayCnt > 1 ) { return createFormatter ( { weekday : 'short' , month : 'numeric' , day : 'numeric' , omitCommas : true } ) ; } return createFormatter ( { weekday : 'long' } ) ; }