MCPcopy Index your code
hub / github.com/ionic-team/ionic-framework / isAfter

Function isAfter

core/src/components/datetime/utils/comparison.ts:31–40  ·  view source on GitHub ↗
(baseParts: DatetimeParts, compareParts: DatetimeParts)

Source from the content-addressed store, hash-verified

29 * Returns true is the selected day is after the reference day.
30 */
31export const isAfter = (baseParts: DatetimeParts, compareParts: DatetimeParts) => {
32 return !!(
33 baseParts.year > compareParts.year ||
34 (baseParts.year === compareParts.year && baseParts.month > compareParts.month) ||
35 (baseParts.year === compareParts.year &&
36 baseParts.month === compareParts.month &&
37 baseParts.day !== null &&
38 baseParts.day > compareParts.day!)
39 );
40};
41
42export const warnIfValueOutOfBounds = (
43 value: DatetimeParts | DatetimeParts[],

Callers 8

getClosestValidDateFunction · 0.90
generateTimeFunction · 0.90
clampDateFunction · 0.90
isDayDisabledFunction · 0.90
isMonthDisabledFunction · 0.90
comparison.spec.tsFile · 0.90
warnIfValueOutOfBoundsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected