@annalib/anna-core 6.0.3 → 6.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -378,16 +378,16 @@ class AnnaDateTimeFormatService {
378
378
  return isAsc ? dayjs(a).diff(b) : dayjs(b).diff(a);
379
379
  }
380
380
  static formatTwentyFourHourTimeToHHMMAFormat(value, date) {
381
- value = dayjs(date ? date : '01/01/2000 ' + value).format("DD/MM/YYYY HH:mm:ss");
381
+ value = dayjs(date ? date : '01/01/2000 ' + value).format("HH:mm:ss");
382
382
  return value[3] == "0" && value[4] == "0"
383
383
  ? dayjs(value, ["HH:mm:ss"]).format("hA").slice(0, -1)
384
384
  : dayjs(value, ["HH:mm:ss"]).format("h:mmA").slice(0, -1);
385
385
  }
386
386
  static formatTwelveHourTimeToHHMMAFormat(timeValue, date) {
387
- timeValue = dayjs(date ? date : '01/01/2000 ' + timeValue).format("DD/MM/YYYY HH:mm:ss");
387
+ timeValue = dayjs(date ? date : '01/01/2000 ' + timeValue).format("HH:mm:ss");
388
388
  return timeValue[3] == "0" && timeValue[4] == "0"
389
- ? dayjs(timeValue).format("hA").slice(0, -1)
390
- : dayjs(timeValue).format("h:mmA").slice(0, -1);
389
+ ? dayjs(timeValue, ["HH:mm:ss"]).format("hA").slice(0, -1)
390
+ : dayjs(timeValue, ["HH:mm:ss"]).format("h:mmA").slice(0, -1);
391
391
  }
392
392
  formatDateAndHHMMATimeToStandardFormat(dateAndTime) {
393
393
  let standardFormat, date, time;