promethee 4.1.12 → 4.1.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5c791f3fc87492c74cf0943f04ee9d7c65731ed6769688294dfbe45baee5d663
4
- data.tar.gz: e584208ada91f6c1d8e38f2f10d10e6605d3e44db13219c2dbb5f9300e235f43
3
+ metadata.gz: 5995134837ab9a1ecff1e378a5cd6c2c773661bba57fb3a5a4a312421b689ac6
4
+ data.tar.gz: 3a832f11734ccbcbddd6f725d4842b71ab924a2ea882481028b43d0feec3ff2f
5
5
  SHA512:
6
- metadata.gz: 3c1de9aed61106c72bc8db3e9dcd3fc2481edc42bddfc5ca8adc3015b5cb6620e84f0b991f61a3b7d58f7bbef4eb34eda76705d2265f1d9ce315aac05462d83a
7
- data.tar.gz: 0e829aabd72bd3e964cd6d0d8d0ce5872d05f69281e88f114e87d72aaae5268f44e50c4e4206f74331312f07eacf7949be2ff9cc11d70bcda565c9f4e35fb147
6
+ metadata.gz: 79e066c623432ba0eaefab072649c311fa0d6ca72f329f6813b55db52e0b19b44feff6961420c894c14ee656825e926e636b4ad4deed735eec6cca5f4b589d68
7
+ data.tar.gz: e392f5c4b4a3c56b0f19d896ab287e0624a24c2db5429d7bfa8d2e117415e94b950846a040fe477a92e53457156604cc8c69735fb72064cd274929c826e1436e
@@ -1,7 +1,7 @@
1
1
  <script>
2
2
  angular.injector(['ng', 'Promethee']).get('presets').push({
3
3
  name: 'Image with text',
4
- icon: <%= render('promethee/presets/icon.image-with-text').to_json.html_safe %>,
4
+ icon: <%= promethee_preset_render_icon 'image-with-text' %>,
5
5
  position: 1,
6
6
  components: [
7
7
  {
@@ -9,7 +9,8 @@ module ActionView
9
9
  @options[:master_data] = object.send @method_name unless object.nil?
10
10
  @options[:master_data] = @options[:value] if @options.key?(:value)
11
11
  @options[:disable_page_attributes] ||= false
12
- ApplicationController.renderer.render partial: 'promethee/edit', locals: @options
12
+
13
+ @template_object.render partial: 'promethee/edit', locals: @options
13
14
  end
14
15
  end
15
16
 
@@ -18,15 +19,16 @@ module ActionView
18
19
  localization_data = object.send @method_name unless object.nil?
19
20
  localization_data = @options[:value] if @options.include? :value
20
21
  @options[:disable_page_attributes] ||= false
21
- ApplicationController.renderer.render partial: 'promethee/localize',
22
- locals: {
23
- object_name: @object_name,
24
- method_name: @method_name,
25
- localization_data: localization_data,
26
- master_data: @options[:master],
27
- other_data: @options[:other],
28
- disable_page_attributes: @options[:disable_page_attributes]
29
- }
22
+
23
+ @template_object.render partial: 'promethee/localize',
24
+ locals: {
25
+ object_name: @object_name,
26
+ method_name: @method_name,
27
+ localization_data: localization_data,
28
+ master_data: @options[:master],
29
+ other_data: @options[:other],
30
+ disable_page_attributes: @options[:disable_page_attributes]
31
+ }
30
32
  end
31
33
  end
32
34
  end
@@ -26,6 +26,10 @@ module Promethee::Rails::Helper
26
26
  render("promethee/components/#{icon}/icon.svg").to_json.html_safe
27
27
  end
28
28
 
29
+ def promethee_preset_render_icon(icon)
30
+ render("promethee/presets/icon.#{icon}.svg").to_json.html_safe
31
+ end
32
+
29
33
  def promethee_util_partials
30
34
  promethee_partials_for 'utils/_*.html.erb'
31
35
  end
@@ -1,5 +1,5 @@
1
1
  module Promethee
2
2
  module Rails
3
- VERSION = '4.1.12'
3
+ VERSION = '4.1.13'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: promethee
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.12
4
+ version: 4.1.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sébastien Gaya
@@ -14,7 +14,7 @@ authors:
14
14
  autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
- date: 2020-09-03 00:00:00.000000000 Z
17
+ date: 2020-09-10 00:00:00.000000000 Z
18
18
  dependencies:
19
19
  - !ruby/object:Gem::Dependency
20
20
  name: rails
@@ -504,7 +504,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
504
504
  - !ruby/object:Gem::Version
505
505
  version: '0'
506
506
  requirements: []
507
- rubygems_version: 3.0.3
507
+ rubygems_version: 3.1.2
508
508
  signing_key:
509
509
  specification_version: 4
510
510
  summary: Bring fire to your page