effective_form_inputs 1.0.6 → 1.0.7

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: ed2e62cb98163b553604cc8c56b03ee829be19c7
4
- data.tar.gz: b8e51e57c5b0a7d2694a6fffc2d3a3a7a34ced08
3
+ metadata.gz: 955b9dad38eb946e1d6a5e67ca1574150eec7625
4
+ data.tar.gz: 3861925d4320f1a69e6042731f3f0ffcb01e0595
5
5
  SHA512:
6
- metadata.gz: f88656841ad37272c555f539ae870f342eaa4253f1a5752c6e794832bd6ecd34925a208072f32c94959a5e14f0d6ec796f425c04873c368a017ba466c429e456
7
- data.tar.gz: 6c0083f4fed0a8fbbda3abeb42ec4861c9606481aa14b0d8e17f27c7fc99b27fa857934ae27a8693e0df0dc345337ce7115eaa76601204905d62fe60d936687d
6
+ metadata.gz: da44dd8e67e5025ae61e3e3ab962019d7db38c5344a0609df49edbdd9c3256594507c14a4412c7b6567b7be886e9b098c76c393183a27d4b482cec87583c370c
7
+ data.tar.gz: 7b975a830d46f06d9600a92e6dfbce4ccb919d82e37f45757c97398ffa6e2dc9144b897d372fb0a9d1ec8d0889541d0e8468d25358b308a0ba4036df67fa7211
@@ -91,4 +91,7 @@ initCkeditor = (textarea) ->
91
91
  $ -> initialize()
92
92
  $(document).on 'page:change', -> initialize()
93
93
  $(document).on 'turbolinks:load', -> initialize()
94
+ $(document).on 'turbolinks:render', -> initialize()
94
95
  $(document).on 'cocoon:after-insert', -> initialize()
96
+ $(document).on 'turbolinks:before-cache', ->
97
+ CKEDITOR.instances[name].destroy() for name, _ of CKEDITOR.instances
@@ -10,4 +10,8 @@ initialize = ->
10
10
  $ -> initialize()
11
11
  $(document).on 'page:change', -> initialize()
12
12
  $(document).on 'turbolinks:load', -> initialize()
13
+ $(document).on 'turbolinks:render', -> initialize()
13
14
  $(document).on 'cocoon:after-insert', -> initialize()
15
+ $(document).on 'turbolinks:before-cache', ->
16
+ $('input.effective_date_picker.initialized').datetimepicker('destroy')
17
+
@@ -10,4 +10,7 @@ initialize = ->
10
10
  $ -> initialize()
11
11
  $(document).on 'page:change', -> initialize()
12
12
  $(document).on 'turbolinks:load', -> initialize()
13
+ $(document).on 'turbolinks:render', -> initialize()
13
14
  $(document).on 'cocoon:after-insert', -> initialize()
15
+ $(document).on 'turbolinks:before-cache', ->
16
+ $('input.effective_date_time_picker.initialized').datetimepicker('destroy')
@@ -9,4 +9,5 @@ initialize = ->
9
9
  $ -> initialize()
10
10
  $(document).on 'page:change', -> initialize()
11
11
  $(document).on 'turbolinks:load', -> initialize()
12
+ $(document).on 'turbolinks:render', -> initialize()
12
13
  $(document).on 'cocoon:after-insert', -> initialize()
@@ -9,9 +9,9 @@ initialize = ->
9
9
  $ -> initialize()
10
10
  $(document).on 'page:change', -> initialize()
11
11
  $(document).on 'turbolinks:load', -> initialize()
12
+ $(document).on 'turbolinks:render', -> initialize()
12
13
  $(document).on 'cocoon:after-insert', -> initialize()
13
14
 
14
-
15
15
  # Prevent non-currency buttons from being pressed
16
16
  $(document).on 'keydown', "input[type='text'].effective_price", (event) ->
17
17
  allowed = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '-', ',', '.']
@@ -16,7 +16,9 @@ initialize = ->
16
16
  $ -> initialize()
17
17
  $(document).on 'page:change', -> initialize()
18
18
  $(document).on 'turbolinks:load', -> initialize()
19
+ $(document).on 'turbolinks:render', -> initialize()
19
20
  $(document).on 'cocoon:after-insert', -> initialize()
21
+ $(document).on 'turbolinks:before-cache', -> $('select.effective_select.initialized').select2('destroy')
20
22
 
21
23
  # If we're working with a polymorphic select, split out the ID and assign the hidden _type and _id fields
22
24
  $(document).on 'change', "select.effective_select.polymorphic", (event) ->
@@ -13,4 +13,5 @@ initialize = ->
13
13
  $ -> initialize()
14
14
  $(document).on 'page:change', -> initialize()
15
15
  $(document).on 'turbolinks:load', -> initialize()
16
+ $(document).on 'turbolinks:render', -> initialize()
16
17
  $(document).on 'cocoon:after-insert', -> initialize()
@@ -11,4 +11,5 @@ initialize = ->
11
11
  $ -> initialize()
12
12
  $(document).on 'page:change', -> initialize()
13
13
  $(document).on 'turbolinks:load', -> initialize()
14
+ $(document).on 'turbolinks:render', -> initialize()
14
15
  $(document).on 'cocoon:after-insert', -> initialize()
@@ -24,11 +24,11 @@ module Inputs
24
24
 
25
25
  def render_item(builder)
26
26
  if options[:inline] || options[:buttons]
27
- item = builder.radio_button + item_image_or_text(builder)
27
+ item = builder.radio_button(item_html_options) + item_image_or_text(builder)
28
28
  elsif options[:nested_boolean_style] == :nested
29
- item = builder.label { builder.radio_button + item_image_or_text(builder) }
29
+ item = builder.label { builder.radio_button(item_html_options) + item_image_or_text(builder) }
30
30
  else
31
- item = builder.radio_button + builder.label { item_image_or_text(builder) }
31
+ item = builder.radio_button(item_html_options) + builder.label { item_image_or_text(builder) }
32
32
  end
33
33
 
34
34
  if options[:buttons]
@@ -62,7 +62,7 @@ module Inputs
62
62
  end
63
63
 
64
64
  def item_html_options
65
- @item_html_options ||= { class: tag_options[:class], name: tag_options[:name] }.delete_if { |k, v| v.blank? }
65
+ @item_html_options ||= tag_options
66
66
  end
67
67
 
68
68
  def html_options
@@ -1,3 +1,3 @@
1
1
  module EffectiveFormInputs
2
- VERSION = '1.0.6'.freeze
2
+ VERSION = '1.0.7'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: effective_form_inputs
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Code and Effect
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-26 00:00:00.000000000 Z
11
+ date: 2017-05-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails