import{a as m}from"./chunk-2E4P66QC.js";import{I as u}from"./chunk-JIDGXFMJ.js";import{ha as i,za as c}from"./chunk-FWZCAEAJ.js";var I="-",p=":",f=(()=>{let n=class n extends m{fromModel(r){if(r){let e=r.split("T"),o=e[0].split(I),a=e[1].split(p);return{year:parseInt(o[0],10),month:parseInt(o[1],10),day:parseInt(o[2],10),hour:parseInt(a[0],10),minute:parseInt(a[1],10),second:parseInt(a[2],10)}}return null}toModel(r){return r?l(r):null}};n.\u0275fac=(()=>{let r;return function(o){return(r||(r=c(n)))(o||n)}})(),n.\u0275prov=i({token:n,factory:n.\u0275fac});let t=n;return t})();function l(t){return`${t.year}${I}${t.month.toString().padStart(2,"0")}${I}${t.day.toString().padStart(2,"0")}T${t.hour.toString().padStart(2,"0")}${p}${t.minute.toString().padStart(2,"0")}${p}${t.second.toString().padStart(2,"0")}.000Z`}function d(t){return l({year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds()})}var g=(()=>{let n=class n extends u{constructor(){super(...arguments),this.SPLIT_DELIMITER="-",this.DELIMITER="."}parse(r){if(r){let e;if(r.includes(this.SPLIT_DELIMITER)){e=r.split(this.SPLIT_DELIMITER);let o=parseInt(e[0],10),a=parseInt(e[1],10),s=parseInt(e[2],10);return isNaN(o)||isNaN(a)||isNaN(s)?null:{year:o,month:a,day:s}}else{e=r.split(this.DELIMITER);let o=parseInt(e[2],10),a=parseInt(e[1],10),s=parseInt(e[0],10);return isNaN(o)||isNaN(a)||isNaN(s)?null:{year:o,month:a,day:s}}}return null}format(r){return r?`${r.day.toString().padStart(2,"0")}${this.DELIMITER}${r.month.toString().padStart(2,"0")}${this.DELIMITER}${r.year}`:""}};n.\u0275fac=(()=>{let r;return function(o){return(r||(r=c(n)))(o||n)}})(),n.\u0275prov=i({token:n,factory:n.\u0275fac});let t=n;return t})();export{f as a,d as b,g as c};
