store replyFlags on this

This commit is contained in:
RMidhunSuresh 2022-01-14 18:31:22 +05:30
parent 41fffdf155
commit d18f4d341c

View File

@ -29,10 +29,12 @@ export class BaseMessageView extends TemplateView {
this._menuPopup = null;
this._tagName = tagName;
// TODO An enum could be nice to make code easier to read at call sites.
this._interactive = renderFlags?.interactive ?? true;
this._isReplyPreview = renderFlags?.reply;
this._renderFlags = renderFlags;
}
get _interactive() { return this._renderFlags?.interactive ?? true; }
get _isReplyPreview() { return this._renderFlags?.reply; }
render(t, vm) {
const children = [this.renderMessageBody(t, vm)];
if (this._interactive) {