var t = require; var e = module; var a = exports; e = (this && this.__decorate) || function (t, e, i, s) { var o, a = arguments.length, n = a < 3 ? e : null === s ? (s = Object.getOwnPropertyDescriptor(e, i)) : s; if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) n = Reflect.decorate(t, e, i, s); else for (var r = t.length - 1; 0 <= r; r--) (o = t[r]) && (n = (a < 3 ? o(n) : 3 < a ? o(e, i, n) : o(e, i)) || n); return 3 < a && n && Object.defineProperty(e, i, n), n; }; Object.defineProperty(a, "__esModule", {value: !0}), (a.ReadColor = a.NotReadColor = void 0); const n = t("App"), i = t("SwitchFrame"), s = t("NotificationConst"), r = (t("ViewConst"), t("MailController")); (a.NotReadColor = cc.color().fromHEX("#B86860")), (a.ReadColor = cc.color().fromHEX("#B6B6B6")); const {ccclass: o, property: l} = cc._decorator; t = class extends cc.Component { constructor() { super(...arguments), (this.mailIconFrame = null), (this.title = null), (this.expireTime = null), (this.expireTimeOutline = null), (this.id = 0), (this.state = 0); } setData(t, e, i, s, o) { n.default.DateUtils.getTimezoneOffset(), (this.id = t), (this.state = o), (this.title.string = e); i = new Date(1e3 * i).Format("yyyy-MM-dd"); (this.expireTime.string = i), o === r.MailStatus.new ? ((this.expireTimeOutline.color = a.NotReadColor), (this.mailIconFrame.frameIndex = 0)) : ((this.expireTimeOutline.color = a.ReadColor), (this.mailIconFrame.frameIndex = 1)); } onTouchEmail() { console.log("参数", this.id, this.state), n.default.ViewManager.open(44, this.id, this.state), n.default.NotificationCenter.dispatch(s.NotificationConst.UPDATE_MAIL_LIST); } }; e([l(i.default)], t.prototype, "mailIconFrame", void 0), e([l(cc.Label)], t.prototype, "title", void 0), e([l(cc.Label)], t.prototype, "expireTime", void 0), e([l(cc.LabelOutline)], t.prototype, "expireTimeOutline", void 0), (t = e([o], t)), (a.default = t);