import { h } from './index-dd1fc9a4.js';
import { a as applyProps } from './common-ecdc423b.js';
var __rest = (undefined && undefined.__rest) || function (s, e) {
    var t = {};
    for (var p in s)
        if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
            t[p] = s[p];
    if (s != null && typeof Object.getOwnPropertySymbols === "function")
        for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
            if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
                t[p[i]] = s[p[i]];
        }
    return t;
};
var DateTime = function (_a) {
    var date = _a.date, _b = _a.format, format = _b === void 0 ? {
        weekday: 'short',
        year: 'numeric',
        month: 'long',
        day: 'numeric',
    } : _b, props = __rest(_a, ["date", "format"]);
    var formatter = new Intl.DateTimeFormat('en-US', Object.assign({}, format));
    return h("time", Object.assign({}, applyProps(props, { class: 'ui-date' })), formatter.format(date));
};
export { DateTime as D };
