Skip to content

Instantly share code, notes, and snippets.

@benkeen
Created November 25, 2014 17:00
Show Gist options
  • Save benkeen/ae4a4da14f40f3c12497 to your computer and use it in GitHub Desktop.
Save benkeen/ae4a4da14f40f3c12497 to your computer and use it in GitHub Desktop.
code
Views.ConfigHeader = FauxtonAPI.View.extend({
template: 'addons/config/templates/header',
className: 'header-right',
initialize: function () {
this.rightHeader = this.setView('#add-section-button', new Views.AddConfigOptionsButton({
toggleTrayBtnSelector: '#add-new-section',
collection: this.collection
}));
}
});
Views.AddConfigOptionsButton = Components.Tray.extend({
template: 'addons/config/templates/add_config_option',
events: {
'click #js-create-config-section': 'createConfigOption'
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment