diff --git a/gui/app/components/section/base-editor-inline.js b/gui/app/components/section/base-editor-inline.js index 2971172c..a7459701 100644 --- a/gui/app/components/section/base-editor-inline.js +++ b/gui/app/components/section/base-editor-inline.js @@ -27,10 +27,16 @@ export default Component.extend(TooltipMixin, ModalMixin, { return `page-editor-${page.id}`; }), previewText: 'Preview', + pageTitle: '', + + didReceiveAttrs() { + this._super(...arguments); + this.set('pageTitle', this.get('page.title')); + }, didRender() { this._super(...arguments); - + let msContainer = document.getElementById('section-editor-' + this.get('containerId')); let mousetrap = this.get('mousetrap'); if (is.null(mousetrap)) { @@ -69,7 +75,7 @@ export default Component.extend(TooltipMixin, ModalMixin, { actions: { onAction() { - if (this.get('busy') || is.empty(this.get('page.title'))) { + if (this.get('busy') || is.empty(this.get('pageTitle'))) { return; } @@ -78,7 +84,7 @@ export default Component.extend(TooltipMixin, ModalMixin, { } let cb = this.get('onAction'); - cb(this.get('page.title')); + cb(this.get('pageTitle')); }, onCancel() { diff --git a/gui/app/templates/components/section/base-editor-inline.hbs b/gui/app/templates/components/section/base-editor-inline.hbs index be607498..fc329496 100644 --- a/gui/app/templates/components/section/base-editor-inline.hbs +++ b/gui/app/templates/components/section/base-editor-inline.hbs @@ -3,14 +3,14 @@