biola_wcms_components 0.9.1 → 0.10.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5424902484c065aa03fe39d2363344f0a8d05258
4
- data.tar.gz: 4a137308bc3a79c1ca7c16320f4bf0cd81c30025
3
+ metadata.gz: 31e37c8293b1910400c4c1e4daee6161404a67cc
4
+ data.tar.gz: d617616b942e10b9731f1fd2257e4edaf6cea8fd
5
5
  SHA512:
6
- metadata.gz: 81b4dc6a24ecc65faaebe81afd3e19694b0bdfafcf07bf35b139eda219612aebd92f0f1dee82cce273003845d275d9c9c02b627897964514432247e2447f2726
7
- data.tar.gz: 5302a97c5a4bcc4465267dcbe6de7a5b198d27ce8cd7784a7a2913c464d1a1e89dca76f2b9d08bf4cb0128712f03257b084839308165974e56ecbe33a743f14e
6
+ metadata.gz: eb68ef14a59d7658093071782b1f9961feea9a6b165c32e0515ebbb63f218f727d41a813b714b0f2f69b9328a248a62d949789e6de48e71c34a4f4e2a8b353bf
7
+ data.tar.gz: 88e5349dfe2ea7371a43470e1bfc5366b4efea4a9cec71cdcb9b89d47eb92ec4a19a8419cf8cb5404073f5cdb2e8654a6f224650f3d56bddc416a6cdb991beab
@@ -2,7 +2,7 @@ setupRedactor = (obj) ->
2
2
  # Default Options
3
3
  options =
4
4
  minHeight: 200
5
- allowedTags: ['p', 'br']
5
+ allowedTags: ['p', 'br', 'span']
6
6
  buttons: []
7
7
  plugins: []
8
8
  toolbarFixed: false
@@ -14,6 +14,9 @@ setupRedactor = (obj) ->
14
14
  # Add any custom data attributes to the default options
15
15
  if obj.data('linkable') # in case you want to support links without explicitly giving a link button.
16
16
  options.allowedTags = $.merge(options.allowedTags, ['a'])
17
+ if obj.data('allow-divs')
18
+ options.allowedTags = $.merge(options.allowedTags, ['div'])
19
+ options.replaceDivs = false
17
20
  if data = obj.data('buttons')
18
21
  buttons = data.split(' ')
19
22
  options.buttons = $.merge(options.buttons, buttons)
@@ -13,6 +13,7 @@ ruby:
13
13
  add_class ||= "" # string of additional classes that get appended to class
14
14
  input_class ||= "form-control redactor #{add_class}"
15
15
  value ||= nil # only used if form is nil
16
+ allow_divs ||= nil
16
17
 
17
18
  # Configure buttons
18
19
  buttons ||= BiolaWcmsComponents.config.default_redactor_buttons
@@ -33,6 +34,6 @@ ruby:
33
34
  = wcms_component "shared/embedded_image_uploader"
34
35
 
35
36
  - if form
36
- = form.text_area attribute, class: input_class, 'data-buttons' => buttons, 'data-formatting' => formatting
37
+ = form.text_area attribute, class: input_class, 'data-buttons' => buttons, 'data-formatting' => formatting, 'data-allow-divs' => allow_divs
37
38
  - else
38
- = text_area_tag attribute, value, class: input_class, 'data-buttons' => buttons, 'data-formatting' => formatting
39
+ = text_area_tag attribute, value, class: input_class, 'data-buttons' => buttons, 'data-formatting' => formatting, 'data-allow-divs' => allow_divs
@@ -1,3 +1,3 @@
1
1
  module BiolaWcmsComponents
2
- VERSION = "0.9.1"
2
+ VERSION = "0.10.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: biola_wcms_components
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.1
4
+ version: 0.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Hall
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-27 00:00:00.000000000 Z
11
+ date: 2015-06-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ace-rails-ap