mirror of
https://github.com/TryGhost/Ghost-Admin.git
synced 2023-12-14 02:33:04 +01:00
525e6c85d0
no issue - cleans up some of the render code - aligns things with the "ember way" - move metaTitleScratch and metaDescriptionScratch bindings to post model
29 lines
668 B
JavaScript
29 lines
668 B
JavaScript
import Mixin from 'ember-metal/mixin';
|
|
import computed from 'ember-computed';
|
|
|
|
export default Mixin.create({
|
|
showSettingsMenu: false,
|
|
|
|
isViewingSubview: computed('showSettingsMenu', {
|
|
get() {
|
|
return false;
|
|
},
|
|
set(key, value) {
|
|
// Not viewing a subview if we can't even see the PSM
|
|
if (!this.get('showSettingsMenu')) {
|
|
return false;
|
|
}
|
|
return value;
|
|
}
|
|
}),
|
|
|
|
actions: {
|
|
showSubview() {
|
|
this.set('isViewingSubview', true);
|
|
},
|
|
|
|
closeSubview() {
|
|
this.set('isViewingSubview', false);
|
|
}
|
|
}
|
|
});
|