You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2 lines
937 B
2 lines
937 B
var y=Object.defineProperty,h=Object.defineProperties;var g=Object.getOwnPropertyDescriptors;var c=Object.getOwnPropertySymbols;var p=Object.prototype.hasOwnProperty,v=Object.prototype.propertyIsEnumerable;var m=(n,e,t)=>e in n?y(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,u=(n,e)=>{for(var t in e||(e={}))p.call(e,t)&&m(n,t,e[t]);if(c)for(var t of c(e))v.call(e,t)&&m(n,t,e[t]);return n},i=(n,e)=>h(n,g(e));import{q as w,cE as I,C as H,aN as M,aY as N}from"./index-f4658ae7.js";function k(n=!0){let e;const t=w({year:0,month:0,week:"",day:0,hour:"",minute:"",second:0,meridiem:""}),a=()=>{const o=N(),d=o.format("HH"),f=o.format("mm"),l=o.get("s");t.year=o.get("y"),t.month=o.get("M")+1,t.day=o.get("D"),t.hour=d,t.minute=f,t.second=l};function r(){a(),clearInterval(e),e=setInterval(()=>a(),1e3)}function s(){clearInterval(e)}return I(()=>{n&&r()}),H(()=>{s()}),i(u({},M(t)),{start:r,stop:s})}export{k as useNow};
|