{"version":3,"sources":["../src/diffSeconds.ts"],"sourcesContent":["import { diffMilliseconds } from \"./diffMilliseconds\"\nimport { DiffRoundingMethod, diffRound } from \"./diffRound\"\nimport type { DateInput, MaybeDateInput } from \"./types\"\n\n/**\n * Returns the difference between 2 dates in seconds.\n * @param dateA - A date to compare with the right date\n * @param [dateB] - A date to compare with the left date or nothing to compare with the current time.\n * @param [roundingMethod] - the rounding method to use, default: trunc\n */\nexport function diffSeconds(\n  dateA: DateInput,\n  dateB?: MaybeDateInput,\n  roundingMethod?: DiffRoundingMethod\n): number\n\n/**\n * Returns the difference between 2 dates in seconds.\n * @param [dateA] - A date to compare with the right date or null to compare with the current time\n * @param dateB - A date to compare with the left date\n * @param [roundingMethod] - the rounding method to use, default: trunc\n */\nexport function diffSeconds(\n  dateA: MaybeDateInput,\n  dateB: DateInput,\n  roundingMethod?: DiffRoundingMethod\n): number\n\nexport function diffSeconds(\n  dateA: MaybeDateInput,\n  dateB?: MaybeDateInput,\n  roundingMethod?: DiffRoundingMethod\n): number {\n  return diffRound(\n    // @ts-ignore\n    diffMilliseconds(dateA, dateB) / 1000,\n    roundingMethod\n  )\n}\n"],"mappings":";AAAA,SAAS,wBAAwB;AACjC,SAA6B,iBAAiB;AA2BvC,SAAS,YACd,OACA,OACA,gBACQ;AACR,SAAO;AAAA;AAAA,IAEL,iBAAiB,OAAO,KAAK,IAAI;AAAA,IACjC;AAAA,EACF;AACF;","names":[]}