{"code":"function defineName$__(cls,name){\n\tObject.defineProperty(cls,\"name\",{value:name,configurable:true});\n};;\nfunction inheritClass$__(cls){\n\tObject.getPrototypeOf(cls.prototype).constructor?.inherited?.(cls);\n};;\nfunction extend$__(target,ext){\n\t// @ts-ignore\n\tconst descriptors = Object.getOwnPropertyDescriptors(ext);\n\tdelete descriptors.constructor;\n\tif(target.extend__ instanceof Function){\n\t\ttarget.extend__(descriptors,ext);\n\t} else {\n\t\t// @ts-ignore\n\t\tObject.defineProperties(target,descriptors);\n\t}\n\treturn target;\n};\nconst $__init__$ = Symbol.for('#__init__'), $__patch__$ = Symbol.for('#__patch__'), $__initor__$ = Symbol.for('#__initor__'), $__inited__$ = Symbol.for('#__inited__'), $__hooks__$ = Symbol.for('#__hooks__');\nvar $1 = Symbol(), $2 = Symbol();\n\n/*body*/\nimport './any';\n\nclass OPDateTimeField extends OPField {\n\t[$__patch__$]($$ = {},fields = true){\n\t\tvar $3;\n\t\tsuper[$__patch__$] && super[$__patch__$]($$,fields);\n\t\t($3 = $$.pgtype) !== undefined && (this.pgtype = $3);\n\t\t\n\t}\n\tconstructor(){\n\t\tsuper(...arguments);\n\t\tsuper[$__init__$] || this[$__init__$]();this[$__initor__$]===$1 && (this[$__hooks__$]&&this[$__hooks__$].inited(this),this[$__inited__$] && this[$__inited__$]());\n\t}\n\t[$__init__$]($$ = null,deep = true,fields = true){\n\t\tvar $4;\n\t\tdeep && super[$__init__$] && super[$__init__$](...arguments);\n\t\tthis.pgtype = ($$ && ($4 = $$.pgtype) !== undefined) ? ($4) : 'timestamptz';\n\t\t\n\t}\n\tstatic {\n\t\tthis.prototype[$__initor__$] = $1;defineName$__(this,'OPDateTimeField');inheritClass$__(this);}\n}; globalThis.OPDateTimeField = OPDateTimeField;\n\nclass OPTimestampField extends OPField {\n\t[$__patch__$]($$ = {},fields = true){\n\t\tvar $5;\n\t\tsuper[$__patch__$] && super[$__patch__$]($$,fields);\n\t\t($5 = $$.pgtype) !== undefined && (this.pgtype = $5);\n\t\t\n\t}\n\tconstructor(){\n\t\tsuper(...arguments);\n\t\tsuper[$__init__$] || this[$__init__$]();this[$__initor__$]===$2 && (this[$__hooks__$]&&this[$__hooks__$].inited(this),this[$__inited__$] && this[$__inited__$]());\n\t}\n\t[$__init__$]($$ = null,deep = true,fields = true){\n\t\tvar $6;\n\t\tdeep && super[$__init__$] && super[$__init__$](...arguments);\n\t\tthis.pgtype = ($$ && ($6 = $$.pgtype) !== undefined) ? ($6) : 'integer';\n\t\t\n\t}\n\tstatic {\n\t\tthis.prototype[$__initor__$] = $2;defineName$__(this,'OPTimestampField');inheritClass$__(this);}\n}; globalThis.OPTimestampField = OPTimestampField;\n\nclass ΩOPObject {\n\t\n\t/**\n\t@returns { OPDateTimeField }\n\t*/\n\tαdatetime(){\n\t\t\n\t\tlet field = new OPDateTimeField;\n\t\tfield.pgtype = 'timestamptz';\n\t\treturn field;\n\t}\n\t\n\t/**\n\t@returns { OPDateTimeField }\n\t*/\n\tαdate(){\n\t\t\n\t\tlet field = new OPDateTimeField;\n\t\tfield.pgtype = 'date';\n\t\treturn field;\n\t}\n\tstatic {\n\t\tdefineName$__(this,'OPObject');}\n};\nextend$__(OPObject.prototype,ΩOPObject.prototype);\n;\n","map":{"version":3,"file":"datetime.js","sourceRoot":"","sources":["/Users/abdellah/workspace/scrimba/op/src/fields/datetime.imba"],"sourcesContent":["import './any'\n\nglobal class OPDateTimeField < OPField\n\tpgtype = 'timestamptz'\n\n\tdeclare def $get\\Date do ''\n\nglobal class OPTimestampField < OPField\n\tpgtype = 'integer'\n\nextend class OPObject\n\tdef @datetime\\OPDateTimeField\n\t\tlet field = new OPDateTimeField\n\t\tfield.pgtype = 'timestamptz'\n\t\treturn field\n\n\tdef @date\\OPDateTimeField\n\t\tlet field = new OPDateTimeField\n\t\tfield.pgtype = 'date'\n\t\treturn field"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,MAAM,CAAC,OAAO;;AAEP,KAAK,CAAC,eAAe,SAAG,OAAO,EAAA;qCAFtC;;;WAGC,MAAM,CAAA,wBAAN,MAAM;;EAHP;cAAA;;;EAAA;kDAAA;;;OAGC,MAAM,mBAAN,MAAM,CAAA,qBAAA,IAAG,aAAa;;EAHvB;;;AAK4B,cAHf,eAAe,GAAf,eAAe;;AAKrB,KAAK,CAAC,gBAAgB,SAAG,OAAO,EAAA;qCAPvC;;;WAQC,MAAM,CAAA,wBAAN,MAAM;;EARP;cAAA;;;EAAA;kDAAA;;;OAQC,MAAM,mBAAN,MAAM,CAAA,qBAAA,IAAG,SAAS;;EARnB;;;AAQmB,cADN,gBAAgB,GAAhB,gBAAgB;;AAGtB,KAAK,CAAC,SAAQ,EAAA;;;YACN,eAAe;;CAAzB,SAAS,EAAgB;;MACxB,KAAK,GAAG,GAAG,CAAC,eAAe;EAC/B,KAAK,CAAC,MAAM,GAAG,aAAa;EAC5B,MAAM,CAAC,KAAK;EAAA;;;YAEH,eAAe;;CAArB,KAAK,EAAgB;;MACpB,KAAK,GAAG,GAAG,CAAC,eAAe;EAC/B,KAAK,CAAC,MAAM,GAAG,MAAM;EACrB,MAAM,CAAC,KAAK;EAAA;;;AAAA;UATD,QAAQ;AASP;AAAA;"},"dependencies":[],"meta":{"vite":{"lang":"js"}}}