effective_bootstrap 0.12.1 → 0.12.3

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
  SHA256:
3
- metadata.gz: 2eda37da109debf0dd81d3ad6123a3355ac2d1407f82c596388732ea4810fd20
4
- data.tar.gz: 3c9a1e9ebf347a914f975e0d74b6c617bddb0a99448f1cbc57d871dbda6f267f
3
+ metadata.gz: 2171c8eba6131331c93de9c19480cb8e561192bc97b584d2eba5c7715e858714
4
+ data.tar.gz: a6b2d20a34f91470fdca3f7288f6007f56a0cd5f621b2411c25446bbf20ddcf4
5
5
  SHA512:
6
- metadata.gz: 79f1b25a831bfbd5a24e7ca9f96e507a4af85dbe918f311c788fb29034c86557e6df38a71cba0dc972c3e2a9c9cd03d8017aab71ba747cf663cf021c3cea8abb
7
- data.tar.gz: ec23c44ef0524a34d16b674c024b0d76e75361eebb729c547c9a33233e7a737c13a8716e0ae7d2bd1ab588699c9e9a911c1dd73ed2f289bd639a05b94a9b87f7
6
+ metadata.gz: 6c72176995e888db8af16d0490b790a2bbd3dc09ab951d8fb2d5d7fd7a5ffc9925b9de9661478653fd8bad8b5990d97ca9d83ce06939126483b46d424fc53263
7
+ data.tar.gz: 01d7d6974daa925491d2888ab18a9bb844719e9d9ddf460f879e5dcfccaee46df62aef8ac972e57d902d7836c29fb276bef2a234195b731de9c166f85486b80d
@@ -1,5 +1,5 @@
1
1
  (this.EffectiveBootstrap || {}).effective_hide_if = ($element, options) ->
2
- $affects = $element.closest('form').find("input[name='#{options.name}'],select[name='#{options.name}']")
2
+ $affects = $element.closest('form,div.effective-datatables-filters').find("input[name='#{options.name}'],select[name='#{options.name}']")
3
3
 
4
4
  $affects.on 'change', (event) ->
5
5
  $target = $(event.target)
@@ -23,7 +23,7 @@
23
23
 
24
24
 
25
25
  (this.EffectiveBootstrap || {}).effective_show_if = ($element, options) ->
26
- $affects = $element.closest('form').find("input[name='#{options.name}'],select[name='#{options.name}']")
26
+ $affects = $element.closest('form,div.effective-datatables-filters').find("input[name='#{options.name}'],select[name='#{options.name}']")
27
27
 
28
28
  $affects.on 'change', (event) ->
29
29
  $target = $(event.target)
@@ -46,7 +46,7 @@
46
46
  $element.find('input,textarea,select,button').prop('disabled', true)
47
47
 
48
48
  (this.EffectiveBootstrap || {}).effective_show_if_any = ($element, options) ->
49
- $affects = $element.closest('form').find("input[name='#{options.name}'],select[name='#{options.name}']")
49
+ $affects = $element.closest('form,div.effective-datatables-filters').find("input[name='#{options.name}'],select[name='#{options.name}']")
50
50
  values = JSON.parse(options.value)
51
51
 
52
52
  $affects.on 'change', (event) ->
@@ -1,6 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module EffectiveArticleEditorHelper
4
+ ACTION_TEXT_ATTACHMENTS = Regexp.new("<action-text-attachment.*?<\/action-text-attachment>")
4
5
 
5
6
  def render_article_editor_action_text_content(content)
6
7
  raise('expected content to be an ActionText content') unless content.kind_of?(ActionText::Content)
@@ -8,11 +9,7 @@ module EffectiveArticleEditorHelper
8
9
  rendered = content.to_html
9
10
 
10
11
  if rendered.include?('effective-article-editor')
11
- doc = Nokogiri::HTML(rendered)
12
- doc.search('action-text-attachment').each { |fragment| fragment.remove }
13
-
14
- # Filter out <html><body>\n and \n</body></html>
15
- rendered = doc.inner_html.to_s[13..-16]
12
+ rendered.gsub!(ACTION_TEXT_ATTACHMENTS, '')
16
13
  end
17
14
 
18
15
  rendered.html_safe
@@ -1,3 +1,3 @@
1
1
  module EffectiveBootstrap
2
- VERSION = '0.12.1'.freeze
2
+ VERSION = '0.12.3'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: effective_bootstrap
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.1
4
+ version: 0.12.3
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: 2023-02-09 00:00:00.000000000 Z
11
+ date: 2023-03-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails