scrivito_editors 0.1.0 → 0.30.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: 0d1fad0bd2f61f1a4ca7360163cdd9786be89c6f
4
- data.tar.gz: ccb27b9ef5d94ab65350b3bfcd7d42256c994d2e
3
+ metadata.gz: a0ecb3d05cdbda3a829167c1691ef7416e1cd3f6
4
+ data.tar.gz: 7b96a801eecf1819fd030976a52e6785c4f0e16a
5
5
  SHA512:
6
- metadata.gz: 7eb183eada8a9582448bfaaa1d8b6243f5f049eb3fbcb8898d6276262ce612bc3f05bd72024b44b29009d2699e740b2f4a1ccf7a0cab507c1e751a4f65af6c9f
7
- data.tar.gz: fa1887e7d224be0f6d8335f4cfeac040782b2ea035689cfa22b2ce09b85a8dd7e5672a6a7b6b4a09a2f8e047cd40223849acc906ca2047b5b3357c5b37b6eca6
6
+ metadata.gz: ad906138ed1935baed7917b8f73f6a30ab9ea55b183d4a941abc01071364da23df71ba23ed36c63520abebcfa4f99a9382c77637d3dccc9e23915882ab18c81a
7
+ data.tar.gz: 301a3d8aea349cbec41fcf68f85e3584aef68a74bfac15de839bbd0a15fec2bea11f1d985437fe4d60a32da13c7af8b58021f8b107aa68060caddccbe983e6eb
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ # v0.30.0
2
+ * Compatibility with https://rubygems.org/gems/scrivito 0.30.0
3
+ * Scrivito editors no longer provide icon font support. We recommend to use screenshots or an
4
+ open font CSS library when migrating thumbnail views to the SDK's `scrivito_thumbnail` helper.
5
+
1
6
  # v0.1.0
2
7
  * Changed dependency to `scrivito_content_browser` due to gem renaming
3
8
  * Removed deprecated content browser API calls, use new API
@@ -24,206 +24,61 @@
24
24
  vertical-align: middle;
25
25
  }
26
26
 
27
- .editing-icon-ip:after {
28
- content: "\F000";
29
- }
30
-
31
- .editing-icon-text:after {
32
- content: "\F001";
33
- }
34
-
35
- .editing-icon-image:after {
36
- content: "\F002";
37
- }
38
-
39
- .editing-icon-headline:after {
40
- content: "\F003";
41
- }
42
-
43
- .editing-icon-video:after {
44
- content: "\F004";
45
- }
46
-
47
- .editing-icon-map:after {
48
- content: "\F005";
49
- }
50
-
51
- .editing-icon-table:after {
52
- content: "\F006";
53
- }
54
-
55
- .editing-icon-slider:after {
56
- content: "\F007";
57
- }
58
-
59
- .editing-icon-list:after {
60
- content: "\F008";
61
- }
62
-
63
- .editing-icon-downloads:after {
64
- content: "\F009";
65
- }
66
-
67
- .editing-icon-person:after {
68
- content: "\F00A";
69
- }
70
-
71
- .editing-icon-presentation:after {
72
- content: "\F00B";
73
- }
74
-
75
- .editing-icon-login:after {
76
- content: "\F00C";
77
- }
78
-
79
- .editing-icon-teaser:after {
80
- content: "\F00D";
81
- }
82
-
83
- .editing-icon-interactive:after {
84
- content: "\F00E";
85
- }
86
-
87
- .editing-icon-hr:after {
88
- content: "\F00F";
89
- }
90
-
91
- .editing-icon-1col:after {
92
- content: "\F010";
93
- }
94
-
95
- .editing-icon-2cols:after {
96
- content: "\F011";
97
- }
98
-
99
- .editing-icon-2colsl:after {
100
- content: "\F012";
101
- }
102
-
103
- .editing-icon-2colsr:after {
104
- content: "\F013";
105
- }
106
-
107
- .editing-icon-3cols:after {
108
- content: "\F014";
109
- }
110
-
111
- .editing-icon-workspaces:after {
112
- content: "\F015";
113
- }
114
-
115
- .editing-icon-tag:after {
116
- content: "\F018";
117
- }
118
-
119
- .editing-icon-link:after {
120
- content: "\F01D";
121
- }
122
-
123
- .editing-icon-box:after {
124
- content: "\F020";
125
- }
126
-
127
- .editing-icon-puzzle:after {
128
- content: "\F021";
129
- }
130
-
131
- .editing-icon-search:after {
132
- content: "\F022";
133
- }
134
-
135
- .editing-icon-dates:after {
136
- content: "\F023";
137
- }
138
-
139
- .editing-icon-newsletter:after {
140
- content: "\F024";
141
- }
142
-
143
- .editing-icon-special:after {
144
- content: "\F025";
145
- }
146
-
147
- .editing-icon-edit:after {
148
- content: "\F026";
149
- }
150
-
151
- .editing-icon-ok:after {
152
- content: "\F027";
153
- }
154
-
155
- .editing-icon-cancel:after {
156
- content: "\F028";
157
- }
158
-
159
- .editing-icon-eye:after {
160
- content: "\F029";
161
- }
162
-
163
- .editing-icon-ok-box:after {
164
- content: "\F02B";
165
- }
166
-
167
- .editing-icon-group:after {
168
- content: "\F02C";
169
- }
170
-
171
- .editing-icon-generic:after {
172
- content: "\F02E";
173
- }
174
-
175
- .editing-icon-pdf:after {
176
- content: "\F02F";
177
- }
178
-
179
- .editing-icon-trash:after {
180
- content: "\F038";
181
- }
182
-
183
- .editing-icon-chevron-up:after {
184
- content: "\F039";
185
- }
186
-
187
- .editing-icon-chevron-down:after {
188
- content: "\F03A";
189
- }
190
-
191
- .editing-icon-chevron-left:after {
192
- content: "\F03B";
193
- }
194
-
195
- .editing-icon-chevron-right:after {
196
- content: "\F03C";
197
- }
198
-
199
- .editing-icon-refresh:after {
200
- content: "\F03D";
201
- }
202
-
203
- .editing-icon-reorder:after {
204
- content: "\F03E";
205
- }
206
-
207
- .editing-icon-th-small:after {
208
- content: "\F03F";
209
- }
210
-
211
- .editing-icon-th-medium:after {
212
- content: "\F040";
213
- }
214
-
215
- .editing-icon-th:after {
216
- content: "\F041";
217
- }
218
-
27
+ /* kept for backwards compatibility reasons */
28
+ .editing-icon-search:after { content: "\F043"; }
29
+ .editing-icon-trash:after { content: "\F038"; }
30
+ .editing-icon-plus:after { content: "\F044"; }
31
+
32
+ /* deprecated */
33
+ .editing-icon-ip:after,
34
+ .editing-icon-text:after,
35
+ .editing-icon-image:after,
36
+ .editing-icon-headline:after,
37
+ .editing-icon-video:after,
38
+ .editing-icon-map:after,
39
+ .editing-icon-table:after,
40
+ .editing-icon-slider:after,
41
+ .editing-icon-list:after,
42
+ .editing-icon-downloads:after,
43
+ .editing-icon-person:after,
44
+ .editing-icon-presentation:after,
45
+ .editing-icon-login:after,
46
+ .editing-icon-teaser:after,
47
+ .editing-icon-interactive:after,
48
+ .editing-icon-hr:after,
49
+ .editing-icon-1col:after,
50
+ .editing-icon-2cols:after,
51
+ .editing-icon-2colsl:after,
52
+ .editing-icon-2colsr:after,
53
+ .editing-icon-3cols:after,
54
+ .editing-icon-workspaces:after,
55
+ .editing-icon-tag:after,
56
+ .editing-icon-link:after,
57
+ .editing-icon-box:after,
58
+ .editing-icon-puzzle:after,
59
+ .editing-icon-dates:after,
60
+ .editing-icon-newsletter:after,
61
+ .editing-icon-special:after,
62
+ .editing-icon-edit:after,
63
+ .editing-icon-ok:after,
64
+ .editing-icon-cancel:after,
65
+ .editing-icon-eye:after,
66
+ .editing-icon-ok-box:after,
67
+ .editing-icon-group:after,
68
+ .editing-icon-generic:after,
69
+ .editing-icon-pdf:after,
70
+ .editing-icon-chevron-up:after,
71
+ .editing-icon-chevron-down:after,
72
+ .editing-icon-chevron-left:after,
73
+ .editing-icon-chevron-right:after,
74
+ .editing-icon-refresh:after,
75
+ .editing-icon-reorder:after,
76
+ .editing-icon-th-small:after,
77
+ .editing-icon-th-medium:after,
78
+ .editing-icon-th:after,
219
79
  .editing-icon-th-large:after {
220
- content: "\F042";
221
- }
222
-
223
- .editing-icon-search:after {
224
- content: "\F043";
225
- }
226
-
227
- .editing-icon-plus:after {
228
- content: "\F044";
80
+ content: "\F000";
81
+ font-family: 'scrivito_content_browser_iconsregular';
82
+ vertical-align: top;
83
+ font-size: 110px;
229
84
  }
@@ -1,140 +1,36 @@
1
1
  module ScrivitoEditors
2
- # This module includes helpers that render the HTML for specfic CMS
3
- # attributes and their JS editors. These special methods are needed
4
- # because the editors need additional information that is not provided
5
- # by the Scrivito SDK's ++cms_tag++ method.
2
+ # @deprecated Please use ScrivitoEditors::ScrivitoTagHelper
6
3
  module CmsTagHelper
7
4
 
8
- # Allows you to edit a CMS ++enum++ attribute using a dropdown
9
- #
10
- # @param [Obj, Widgegt] object
11
- # @param [String, Symbol] attribute_name
12
- # @param [Hash] options passed to the ++cms_tag++ helper
13
5
  def cms_edit_enum(object, attribute_name, options = {})
14
- values = object.obj_class.attributes[attribute_name].values
15
- values |= [object[attribute_name].to_s]
16
-
17
- options.reverse_merge!({
18
- data: {
19
- values: values,
20
- min: values.min,
21
- max: values.max,
22
- }
23
- })
24
-
25
- cms_tag(:div, object, attribute_name, options)
6
+ _cms_edit_deprecated __method__
26
7
  end
27
8
 
28
- # Allows you to edit a CMS ++multienum++ attribute using a multi-select.
29
- #
30
- # @param [Obj, Widget] object
31
- # @param [String, Symbol] attribute_name
32
- # @param [Hash] options passed to the ++cms_tag++ helper
33
9
  def cms_edit_multienum(object, attribute_name, options = {})
34
- values = object.obj_class.attributes[attribute_name].values
35
-
36
- options.reverse_merge!({
37
- multiple: true,
38
- data: {
39
- values: values,
40
- }
41
- })
42
-
43
- cms_tag(:div, object, attribute_name, options) do |tag|
44
- (object[attribute_name] || []).join(', ')
45
- end
10
+ _cms_edit_deprecated __method__
46
11
  end
47
12
 
48
- # Allows you to edit a CMS ++reference++ attribute using the resource
49
- # browser.
50
- #
51
- # @param [Obj, Widget] object
52
- # @param [String, Symbol] attribute_name
53
- # @param [Hash] options passed to the ++cms_tag++ helper
54
13
  def cms_edit_reference(object, attribute_name, options = {})
55
- reference = object[attribute_name]
56
-
57
- cms_tag(:div, object, attribute_name, options) do
58
- if reference
59
- reference.description_for_editor
60
- end
61
- end
14
+ _cms_edit_deprecated __method__
62
15
  end
63
16
 
64
- # Allows you to edit a CMS ++referencelist++ attribute using the resource
65
- # browser.
66
- #
67
- # @param [Obj, Widget] object
68
- # @param [String, Symbol] attribute_name
69
- # @param [Hash] options passed to the ++cms_tag++ helper
70
17
  def cms_edit_referencelist(object, attribute_name, options = {})
71
- reference_list = object[attribute_name]
72
-
73
- cms_tag(:div, object, attribute_name, options) do
74
- if reference_list.present?
75
- content_tag(:ul) do
76
- html = ''.html_safe
77
-
78
- reference_list.each do |reference|
79
- html << content_tag(:li, data: { name: reference.name, id: reference.id }) do
80
- content_tag(:span, reference.description_for_editor, class: 'list-content')
81
- end
82
- end
83
-
84
- html
85
- end
86
- end
87
- end
18
+ _cms_edit_deprecated __method__
88
19
  end
89
20
 
90
- # Allows you to edit a CMS ++linklist++ attribute
91
- #
92
- # @param [Obj, Widget] object
93
- # @param [String, Symbol] attribute_name
94
- # @param [Hash] options passed to the ++cms_tag++ helper
95
21
  def cms_edit_linklist(object, attribute_name, options = {})
96
- linklist = object[attribute_name]
97
-
98
- cms_tag(:div, object, attribute_name, options) do
99
- if linklist
100
- content_tag(:ul) do
101
- html = ''.html_safe
102
-
103
- linklist.each do |link|
104
- html << _edit_link_li(link)
105
- end
106
-
107
- html
108
- end
109
- end
110
- end
22
+ _cms_edit_deprecated __method__
111
23
  end
112
24
 
113
- # Allows you to edit a CMS ++link++ attribute
114
- #
115
- # @param [Obj, Widget] object
116
- # @param [String, Symbol] attribute_name
117
- # @param [Hash] options passed to the ++cms_tag++ helper
118
25
  def cms_edit_link(object, attribute_name, options = {})
119
- link = object[attribute_name]
120
-
121
- cms_tag(:div, object, attribute_name, options) do
122
- content_tag(:ul) { _edit_link_li(link) } if link
123
- end
26
+ _cms_edit_deprecated __method__
124
27
  end
125
28
 
126
29
  private
127
30
 
128
- def _edit_link_li(link)
129
- query = link.query.present? ? "?#{link.query}" : ""
130
- url = link.internal? ? cms_path(link).sub(/\?.*/, query) : link.url
131
- description = link.internal? ? link.obj.description_for_editor : link.url
132
-
133
- content_tag(:li, data: { title: link.title, url: url }) do
134
- content_tag(:span, class: 'list-content') do
135
- "#{link.title} #{link_to(description, url, target: :_blank)}".html_safe
136
- end
137
- end
31
+ def _cms_edit_deprecated(method)
32
+ raise "The helper method `#{method}' has been removed.\n" +
33
+ "Please use `#{method.to_s.sub("cms", "scrivito")}' instead."
138
34
  end
139
35
  end
140
36
  end
@@ -1,3 +1,3 @@
1
1
  module ScrivitoEditors
2
- VERSION = '0.1.0'
2
+ VERSION = '0.30.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scrivito_editors
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.30.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scrivito
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-30 00:00:00.000000000 Z
11
+ date: 2014-11-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties
@@ -39,7 +39,7 @@ dependencies:
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
- name: scrivito_sdk
42
+ name: scrivito
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - ">="