import{c as a,e as r}from"./preload-helper-DadE4qT2.chunk.mjs";import{u as s,a as n}from"./useFormatDateTime-DuMg0AS_.chunk.mjs";import{n as l}from"./index-CTabiXQG.chunk.mjs";const p={name:"NcDateTime",props:{timestamp:{type:[Date,Number],required:!0},format:{type:Object,default:()=>({timeStyle:"medium",dateStyle:"short"})},relativeTime:{type:[Boolean,String],default:"long",validator:t=>t===!1||["long","short","narrow"].includes(t)},ignoreSeconds:{type:Boolean,default:!1}},setup(t){const e=a(()=>({format:t.format})),i=a(()=>({ignoreSeconds:t.ignoreSeconds,relativeTime:t.relativeTime||"long",update:t.relativeTime!==!1})),o=s(r(t,"timestamp"),e),m=n(r(t,"timestamp"),i);return{formattedTime:a(()=>t.relativeTime?m.value:o.value),title:o}}};var d=function(){var t=this,e=t._self._c;return e("span",{staticClass:"nc-datetime",attrs:{dir:"auto","data-timestamp":t.timestamp,title:t.title},domProps:{textContent:t._s(t.formattedTime)}})},u=[],c=l(p,d,u,!1,null,null);const g=c.exports;export{g as N};
//# sourceMappingURL=NcDateTime-enXYuwj8-CrCRQy-Y.chunk.mjs.map
