{"version":3,"file":"startOfDay.mjs","names":[],"sources":["../../src/date/startOfDay.ts"],"sourcesContent":["/**\n * Returns a new Date object set to the start of the day (00:00:00.000).\n *\n * @param date - The date to modify\n * @returns A new Date object set to the start of the day\n *\n * @example\n * startOfDay(new Date('2024-01-15T14:30:45.123Z'))\n * // => Date object for 2024-01-15T00:00:00.000Z\n */\nexport function startOfDay(date: Date): Date {\n  if (!(date instanceof Date) || isNaN(date.getTime())) {\n    return new Date(NaN);\n  }\n\n  const result = new Date(date);\n  result.setHours(0, 0, 0, 0);\n  return result;\n}\n"],"mappings":";;;;;;;;;;;AAUA,SAAgB,WAAW,MAAkB;CAC3C,IAAI,EAAE,gBAAgB,SAAS,MAAM,KAAK,QAAQ,CAAC,GACjD,uBAAO,IAAI,KAAK,GAAG;CAGrB,MAAM,SAAS,IAAI,KAAK,IAAI;CAC5B,OAAO,SAAS,GAAG,GAAG,GAAG,CAAC;CAC1B,OAAO;AACT"}