Ghost/core/client/templates/editor-save-button.hbs
Matt Enlow cef680aa6b Ember editor save and publish button functionality
Closes #2747
- Added new 'editor-save-button' view and template.
- Added save action to post controller.
- Set a new post as the default model for the /editor/ route.
- Set the `posts/post` controller as the controller for the /editor/
  route.
- Needs ghost-popover #2418 component for full pop-up functionality
2014-05-24 07:47:55 -06:00

12 lines
768 B
Handlebars

<button type="button" {{action "save"}} {{bind-attr class="view.isDangerous:button-delete:button-save :js-publish-button" }}>{{view.save-text}}</button>
<button {{action 'viewSaveTypes'}} {{bind-attr class="controller.isViewingSaveTypes:active :options :up" }} title="Post Settings"><span class="hidden">Post Settings</span>
</button>
{{!-- @TODO: implement popover --}}
<ul {{bind-attr class="controller.isViewingSaveTypes::hidden :editor-options :overlay" }}>
<li {{bind-attr class="controller.willPublish:active"}}>
<a {{action "setSaveType" "publish"}} href="#">{{view.publish-text}}</a>
</li>
<li {{bind-attr class="controller.willPublish::active"}}>
<a {{action "setSaveType" "draft"}} href="#">{{view.draft-text}}</a>
</li>
</ul>