ember-arcgis-page-layout
Version:
Page Layout infrastructure components
26 lines (22 loc) • 666 B
JavaScript
import Ember from 'ember';
import layout from './template';
export default Ember.Component.extend({
layout,
attributeBindings:['style'],
classNames: ['settings-editor-container'],
// only show if the editor has been set
style: Ember.computed('editorComponentName', function() {
let display = this.get('editorComponentName') ? 'block' : 'none';
return Ember.String.htmlSafe(`display:${display};`);
}),
actions: {
// hide editor and this container component
clearEditor() {
this.set('editorComponentName', null);
this.set('model', null);
},
onModelChanged() {
this.sendAction('onModelChanged');
}
}
});