import dayjs from './dayjs.js';
import '../defineProperty-CrCYjjU3.js';
import '../typeof-D-UKOauR.js';
import '../toConsumableArray-B7CFjjkW.js';
import '../unsupportedIterableToArray-Dqz8Y8_I.js';
import 'dayjs';

/* eslint-disable @bigbinary/neeto/use-standard-date-time-formats */
var getDefaultFormat = function getDefaultFormat() {
  var _globalProps$user$dat, _globalProps;
  return (_globalProps$user$dat = (_globalProps = globalProps) === null || _globalProps === void 0 || (_globalProps = _globalProps.user) === null || _globalProps === void 0 ? void 0 : _globalProps.dateFormat) !== null && _globalProps$user$dat !== void 0 ? _globalProps$user$dat : "DD/MM/YYYY";
};
var timeFormat = {
  fromNow: function fromNow(time) {
    return dayjs(time).fromNow();
  },
  time: function time(_time) {
    return dayjs(_time).format("LT");
  },
  timeWithSeconds: function timeWithSeconds(time) {
    return dayjs(time).format("LTS");
  },
  date: function date(time) {
    return dayjs(time).format("ll");
  },
  dateWeek: function dateWeek(time) {
    return dayjs(time).format("ll ddd");
  },
  dateWeekDayExtended: function dateWeekDayExtended(time) {
    return dayjs(time).format("ll dddd");
  },
  dateWeekWithoutYear: function dateWeekWithoutYear(time) {
    return dayjs(time).format("MMM D, ddd");
  },
  dateWeekWithoutYearDayExtended: function dateWeekWithoutYearDayExtended(time) {
    return dayjs(time).format("MMM D, dddd");
  },
  dateTime: function dateTime(time) {
    return dayjs(time).format("ll LT");
  },
  dateTimeWithSeconds: function dateTimeWithSeconds(time) {
    return dayjs(time).format("ll LTS");
  },
  dateWeekTime: function dateWeekTime(time) {
    return dayjs(time).format("ll ddd LT");
  },
  dateWeekTimeDayExtended: function dateWeekTimeDayExtended(time) {
    return dayjs(time).format("ll dddd LT");
  },
  extended: function extended(time) {
    var dateTime = dayjs(time).format("dddd LL LT");
    var fromNow = dayjs(time).fromNow();
    return "".concat(dateTime, " (").concat(fromNow, ")");
  },
  "default": function _default(time) {
    return dayjs(time).format(getDefaultFormat());
  },
  defaultWithTime: function defaultWithTime(time) {
    return dayjs(time).format("".concat(getDefaultFormat(), " LT"));
  }
};
var dateFormat = timeFormat;

export { dateFormat, timeFormat };
//# sourceMappingURL=datetime.js.map
