Ghost/ghost/admin/app/routes/editor/new.js
Kevin Ansfield 3c2f3da689 always give editor content focus by default (#748)
closes https://github.com/TryGhost/Ghost/issues/8525
- always give focus to the editor content area by default when loading
the editor
- change the editor placeholder text
2017-06-19 11:16:09 +01:00

22 lines
531 B
JavaScript

import AuthenticatedRoute from 'ghost-admin/routes/authenticated';
import base from 'ghost-admin/mixins/editor-base-route';
export default AuthenticatedRoute.extend(base, {
titleToken: 'Editor',
model() {
return this.get('session.user').then((user) => {
return this.store.createRecord('post', {
author: user
});
});
},
renderTemplate(controller, model) {
this.render('editor/edit', {
controller,
model
});
}
});