promethee 1.5.0 → 1.5.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/promethee/_localize.html.erb +13 -14
- data/app/views/promethee/components/aside/_localize.html.erb +4 -4
- data/app/views/promethee/components/slider/_localize.html.erb +2 -2
- data/app/views/promethee/components/text/_localize.html.erb +4 -2
- data/lib/promethee/rails/helper.rb +4 -0
- data/lib/promethee/rails/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2247f4ed854e9275378c439e372d82b57b488e90
|
4
|
+
data.tar.gz: 67ad9f3e44476b50c6c3116d21ce1e7f3d8d89fe
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3ada62bc8663659b56a41c429352b49ea8a576b7fd04668827ea818303d1e291ff567771ca3d442798e9aef729ac691214f46bf5623b16549707de1c25f5b8ec
|
7
|
+
data.tar.gz: 2b922873945cf709aead1dbfc7c667b72bf10a73edc1bba70b3c2418d5c48383e873eafb6f38a946a47ff42e03ff691ee0de36c94c0e97332992199731c77108
|
@@ -2,8 +2,8 @@
|
|
2
2
|
promethee_data = Promethee::Data.new master_data, localization_data: localization_data
|
3
3
|
%>
|
4
4
|
|
5
|
-
<script>
|
6
|
-
var
|
5
|
+
<script type="text/javascript">
|
6
|
+
var promethee = angular
|
7
7
|
.module('PrometheeLocalizer', ['summernote'])
|
8
8
|
.value('data', <%= promethee_data.localization_data_to_json.html_safe %>)
|
9
9
|
.filter('htmlSafe', ['$sce', function($sce) {
|
@@ -11,25 +11,25 @@ promethee_data = Promethee::Data.new master_data, localization_data: localizatio
|
|
11
11
|
return $sce.trustAsHtml(val);
|
12
12
|
};
|
13
13
|
}]);
|
14
|
+
</script>
|
15
|
+
|
16
|
+
<% promethee_util_partials.each do |partial| %>
|
17
|
+
<%= render partial %>
|
18
|
+
<% end %>
|
14
19
|
|
15
|
-
|
20
|
+
<script type="text/javascript">
|
21
|
+
promethee.controller('PrometheeLocalizerController', ['$scope', 'summernoteConfig', 'data', function($scope, summernoteConfig, data) {
|
16
22
|
|
17
23
|
$scope.data = data;
|
18
24
|
$scope.component = {children: data.components};
|
19
25
|
|
20
|
-
$scope.
|
21
|
-
toolbar: [
|
22
|
-
['headline', ['style']],
|
23
|
-
['style', ['bold', 'italic']],
|
24
|
-
['alignment', ['ul', 'ol', 'paragraph']],
|
25
|
-
['code', ['codeview']]
|
26
|
-
]
|
27
|
-
};
|
26
|
+
$scope.summernoteConfig = summernoteConfig;
|
28
27
|
|
29
28
|
}]);
|
30
29
|
</script>
|
31
30
|
|
32
31
|
|
32
|
+
|
33
33
|
<div id="prometheeLocalizer"
|
34
34
|
class="promethee-localizer"
|
35
35
|
ng-app="PrometheeLocalizer"
|
@@ -41,9 +41,8 @@ promethee_data = Promethee::Data.new master_data, localization_data: localizatio
|
|
41
41
|
|
42
42
|
<input type="hidden" name="<%= object_name %>[<%= method_name %>]" id="page_data" value="{{data}}" />
|
43
43
|
|
44
|
-
<%
|
45
|
-
|
46
|
-
<%= render partial %>
|
44
|
+
<% promethee_localize_partials.each do |partial| %>
|
45
|
+
<%= render partial %>
|
47
46
|
<% end %>
|
48
47
|
|
49
48
|
<% #TODO override templates from current project %>
|
@@ -4,12 +4,12 @@
|
|
4
4
|
<div class="row">
|
5
5
|
<div class="col-md-6">
|
6
6
|
<b>Aside visible content</b>
|
7
|
-
<div
|
7
|
+
<div ng-bind-html="component.master.attributes.visible_content | htmlSafe"></div>
|
8
8
|
</div>
|
9
9
|
<div class="col-md-6">
|
10
10
|
<div class="form-group">
|
11
11
|
<label class="label-control">Aside visible content</label>
|
12
|
-
<
|
12
|
+
<summernote config="summernoteConfig" ng-model="component.attributes.visible_content"></summernote>
|
13
13
|
</div>
|
14
14
|
</div>
|
15
15
|
</div>
|
@@ -17,12 +17,12 @@
|
|
17
17
|
<div class="row" ng-show="component.master.attributes.collapsed_content">
|
18
18
|
<div class="col-md-6">
|
19
19
|
<b>Aside collapsed content</b>
|
20
|
-
<
|
20
|
+
<div ng-bind-html="component.master.attributes.collapsed_content | htmlSafe"></div>
|
21
21
|
</div>
|
22
22
|
<div class="col-md-6">
|
23
23
|
<div class="form-group">
|
24
24
|
<label class="label-control">Aside collapsed content</label>
|
25
|
-
<
|
25
|
+
<summernote config="summernoteConfig" ng-model="component.attributes.collapsed_content"></summernote>
|
26
26
|
</div>
|
27
27
|
</div>
|
28
28
|
</div>
|
@@ -2,13 +2,13 @@
|
|
2
2
|
<div ng-show="(component.master.contents | json) !== '{}'">
|
3
3
|
<hr>
|
4
4
|
|
5
|
-
<div ng-repeat="key, content in component.master.attributes.contents">
|
5
|
+
<div ng-repeat="(key, content) in component.master.attributes.contents">
|
6
6
|
<div class="row">
|
7
7
|
<div class="col-md-6">
|
8
8
|
<div class="promethee-edit__wrapper" ng-bind-html="component.master.attributes.contents[key] | htmlSafe"></div>
|
9
9
|
</div>
|
10
10
|
<div class="col-md-6">
|
11
|
-
<summernote config="
|
11
|
+
<summernote config="summernoteConfig" ng-model="component.attributes.contents[key]"></summernote>
|
12
12
|
</div>
|
13
13
|
</div>
|
14
14
|
</div>
|
@@ -4,10 +4,12 @@
|
|
4
4
|
|
5
5
|
<div class="row">
|
6
6
|
<div class="col-md-6">
|
7
|
-
<
|
7
|
+
<b>Text</b>
|
8
|
+
<div ng-bind-html="component.master.attributes.body | htmlSafe"></div>
|
8
9
|
</div>
|
9
10
|
<div class="col-md-6">
|
10
|
-
<
|
11
|
+
<b>Text</b>
|
12
|
+
<summernote config="summernoteConfig" ng-model="component.attributes.body"></summernote>
|
11
13
|
</div>
|
12
14
|
</div>
|
13
15
|
</div>
|
@@ -30,6 +30,10 @@ module Promethee::Rails::Helper
|
|
30
30
|
promethee_partials_for 'presets/_*.html.erb'
|
31
31
|
end
|
32
32
|
|
33
|
+
def promethee_localize_partials
|
34
|
+
promethee_partials_for 'components/*/_localize.html.erb'
|
35
|
+
end
|
36
|
+
|
33
37
|
# promethee_bem_classes 'promethee-edit__move__droppable', '--{{type}}', '--first'
|
34
38
|
# -> promethee-edit__move__droppable promethee-edit__move__droppable--{{type}} promethee-edit__move__droppable--{{type}}--first"
|
35
39
|
def promethee_bem_classes(*args)
|
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: 1.5.
|
4
|
+
version: 1.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Julien Dargelos
|
@@ -359,7 +359,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
359
359
|
version: '0'
|
360
360
|
requirements: []
|
361
361
|
rubyforge_project:
|
362
|
-
rubygems_version: 2.6.
|
362
|
+
rubygems_version: 2.6.11
|
363
363
|
signing_key:
|
364
364
|
specification_version: 4
|
365
365
|
summary: Bring fire to your page
|