var l=["second","minute","hour","day","week","month","year"];function v(e,r){if(r===0)return["just now","right now"];var a=l[Math.floor(r/2)];return e>1&&(a+="s"),[e+" "+a+" ago","in "+e+" "+a]}var s=["秒","分钟","小时","天","周","个月","年"];function h(e,r){if(r===0)return["刚刚","片刻后"];var a=s[~~(r/2)];return[e+" "+a+"前",e+" "+a+"后"]}var c={},u=function(e,r){c[e]=r},D=function(e){return c[e]||c.en_US},o=[60,60,24,7,365/7/12,12];function S(e){return e instanceof Date?e:!isNaN(e)||/^\d+$/.test(e)?new Date(parseInt(e)):(e=(e||"").trim().replace(/\.\d+/,"").replace(/-/,"/").replace(/-/,"/").replace(/(\d)T(\d)/,"$1 $2").replace(/Z/," UTC").replace(/([+-]\d\d):?(\d\d)/," $1$2"),new Date(e))}function _(e,r){var a=e<0?1:0;e=Math.abs(e);for(var n=e,t=0;e>=o[t]&&t<o.length;t++)e/=o[t];return e=Math.floor(e),t*=2,e>(t===0?9:1)&&(t+=1),r(e,t,n)[a].replace("%s",e.toString())}function g(e,r){var a=new Date;return(+a-+S(e))/1e3}var i=function(e,r,a){var n=g(e);return _(n,D(r))};u("en_US",v);u("zh_CN",h);export{i as f};
//# sourceMappingURL=BojVbZw0.chunk.js.map
