text field: show more after editing

This commit is contained in:
Yuri Kuznetsov
2025-02-10 16:31:51 +02:00
parent 44b9f60478
commit 137b6fcff7
+8
View File
@@ -178,6 +178,14 @@ class TextFieldView extends BaseFieldView {
this.addActionHandler('previewText', () => this.preview());
}
this.listenTo(this.model, `change:${this.name}`, (m, v, /** Record*/o) => {
if (o.ui === true && this.mode === this.MODE_EDIT) {
// After changing the field content it's reasonable to show all text
// when returning to the detail mode.
this.seeMoreText = true;
}
})
/** @private */
this.controlSeeMoreBind = this.controlSeeMore.bind(this);
/** @private */