diff --git a/README.md b/README.md index df3eb2b..ea27526 100644 --- a/README.md +++ b/README.md @@ -51,6 +51,8 @@ You can listen to the events triggered by the modal inside the Backbone.View Set up the modal with the following options: - {String|View} [options.content] Modal content. Default: none +- {String} [options.classHeader] Add class to modal header. Default none. +- {String} [options.width] Override bootstrap width.Default none. - {String} [options.title] Title. Default: none - {String} [options.okText] Text for the OK button. Default: 'OK' - {Boolean} [options.focusOk] Wether the 'OK' button should have the focus or not. Default: true diff --git a/src/backbone.bootstrap-modal.js b/src/backbone.bootstrap-modal.js index 5df9ead..ed45500 100644 --- a/src/backbone.bootstrap-modal.js +++ b/src/backbone.bootstrap-modal.js @@ -1,6 +1,6 @@ /** * Bootstrap Modal wrapper for use with Backbone. - * + * * Takes care of instantiation, manages multiple modals, * adds several options and removes the element from the DOM when closed * @@ -13,24 +13,22 @@ * ok: The user clicked OK */ (function($, _, Backbone) { - //Set custom template settings var _interpolateBackup = _.templateSettings; _.templateSettings = { interpolate: /\{\{(.+?)\}\}/g, evaluate: /<%([\s\S]+?)%>/g } - var template = _.template('\ <% if (title) { %>\ -