brightcontent-core 2.0.33 → 2.1.0

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.
Files changed (105) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -0
  3. data/app/assets/javascripts/brightcontent/brightcontent.js.erb +8 -0
  4. data/app/assets/javascripts/brightcontent/core.js.coffee +28 -0
  5. data/app/assets/javascripts/brightcontent/wysithtml5-parser-rules.js +519 -0
  6. data/app/assets/stylesheets/brightcontent/brightcontent.css.erb +10 -0
  7. data/app/assets/stylesheets/brightcontent/core.css.sass +61 -0
  8. data/app/assets/stylesheets/brightcontent/signin.css.sass +34 -0
  9. data/app/controllers/brightcontent/admin_users_controller.rb +1 -3
  10. data/app/controllers/brightcontent/application_controller.rb +12 -2
  11. data/app/controllers/brightcontent/base_controller.rb +7 -18
  12. data/app/controllers/brightcontent/sessions_controller.rb +1 -1
  13. data/app/helpers/brightcontent/application_helper.rb +4 -0
  14. data/app/helpers/brightcontent/base_helper.rb +6 -18
  15. data/app/helpers/brightcontent/translation_helper.rb +38 -0
  16. data/app/views/brightcontent/application/_menu.html.erb +9 -2
  17. data/app/views/brightcontent/application/_resource.html.erb +3 -0
  18. data/app/views/brightcontent/application/_show_flash_names.html.erb +2 -1
  19. data/app/views/brightcontent/application/_user_menu.html.erb +4 -0
  20. data/app/views/brightcontent/base/_form.html.erb +16 -11
  21. data/app/views/brightcontent/base/_list_actions.html.erb +2 -2
  22. data/app/views/brightcontent/base/_list_filters.html.erb +12 -0
  23. data/app/views/brightcontent/base/_list_header.html.erb +6 -0
  24. data/app/views/brightcontent/base/_list_item.html.erb +6 -0
  25. data/app/views/brightcontent/base/edit.html.erb +0 -2
  26. data/app/views/brightcontent/{fields → base/form_fields}/_file.html.erb +0 -0
  27. data/app/views/brightcontent/base/index.html.erb +9 -11
  28. data/app/views/brightcontent/base/list_fields/_boolean.html.erb +5 -0
  29. data/app/views/brightcontent/base/new.html.erb +0 -2
  30. data/app/views/brightcontent/sessions/new.html.erb +5 -11
  31. data/app/views/layouts/brightcontent/application.html.erb +34 -29
  32. data/bin/autospec +16 -0
  33. data/bin/rspec +16 -0
  34. data/brightcontent-core.gemspec +11 -6
  35. data/config/initializers/simple_form.rb +18 -15
  36. data/config/initializers/simple_form_bootstrap.rb +46 -30
  37. data/config/locales/brightcontent_core.en.yml +30 -0
  38. data/config/locales/brightcontent_core.nl.yml +30 -0
  39. data/config/routes.rb +1 -1
  40. data/db/migrate/20121206121725_create_brightcontent_admin_users.rb +1 -1
  41. data/lib/brightcontent/base_controller_ext/default_actions.rb +35 -0
  42. data/lib/brightcontent/base_controller_ext/fields.rb +36 -0
  43. data/lib/brightcontent/base_controller_ext/filtering.rb +21 -0
  44. data/lib/brightcontent/base_controller_ext/pagination.rb +29 -0
  45. data/lib/brightcontent/base_controller_ext.rb +8 -0
  46. data/lib/brightcontent/core.rb +24 -10
  47. data/lib/brightcontent/engine.rb +6 -0
  48. data/lib/brightcontent/resource.rb +15 -0
  49. data/lib/brightcontent/resources.rb +25 -0
  50. data/lib/brightcontent/routes_parser.rb +9 -17
  51. data/lib/brightcontent/view_lookup/abstract.rb +49 -0
  52. data/lib/brightcontent/view_lookup/filter_field.rb +57 -0
  53. data/lib/brightcontent/view_lookup/form_field.rb +14 -0
  54. data/lib/brightcontent/view_lookup/list_field.rb +13 -0
  55. data/lib/brightcontent/view_lookup.rb +8 -0
  56. data/lib/generators/brightcontent/templates/brightcontent_controller.rb +1 -1
  57. data/lib/generators/brightcontent/templates/initializer.rb +14 -2
  58. data/spec/dummy/app/controllers/brightcontent/blogs_controller.rb +1 -1
  59. data/spec/dummy/app/models/author.rb +7 -0
  60. data/spec/dummy/app/models/blog.rb +2 -1
  61. data/spec/dummy/config/application.rb +2 -6
  62. data/spec/dummy/config/environments/development.rb +1 -10
  63. data/spec/dummy/config/environments/production.rb +0 -4
  64. data/spec/dummy/config/environments/test.rb +2 -6
  65. data/spec/dummy/config/initializers/secret_token.rb +1 -1
  66. data/spec/dummy/db/migrate/20130720211920_create_comments.rb +0 -1
  67. data/spec/dummy/db/migrate/20140512085432_add_author_id_to_blogs.rb +5 -0
  68. data/spec/dummy/db/migrate/20140512090832_create_authors.rb +9 -0
  69. data/spec/dummy/db/schema.rb +19 -12
  70. data/spec/factories.rb +15 -0
  71. data/spec/features/login_spec.rb +3 -3
  72. data/spec/features/menu_spec.rb +2 -4
  73. data/spec/features/nested_resource_spec.rb +1 -1
  74. data/spec/features/resources_form_spec.rb +1 -3
  75. data/spec/features/resources_index_spec.rb +30 -6
  76. data/spec/helpers/brightcontent/translation_helper_spec.rb +27 -0
  77. data/spec/lib/brightcontent/model_extensions_spec.rb +1 -1
  78. data/spec/lib/brightcontent/resource_spec.rb +16 -0
  79. data/spec/lib/brightcontent/resources_spec.rb +67 -0
  80. data/spec/lib/brightcontent/routes_parser_spec.rb +4 -9
  81. data/spec/lib/brightcontent/view_lookup/abstract_spec.rb +40 -0
  82. metadata +159 -70
  83. data/app/assets/images/brightcontent/.gitkeep +0 -0
  84. data/app/assets/images/brightcontent/glyphicons-halflings-white.png +0 -0
  85. data/app/assets/images/brightcontent/glyphicons-halflings.png +0 -0
  86. data/app/assets/javascripts/brightcontent/attachments.js +0 -0
  87. data/app/assets/javascripts/brightcontent/bootstrap.min.js +0 -6
  88. data/app/assets/javascripts/brightcontent/brightcontent.js +0 -21
  89. data/app/assets/javascripts/brightcontent/main.js +0 -26
  90. data/app/assets/javascripts/brightcontent/pages.js +0 -0
  91. data/app/assets/stylesheets/brightcontent/attachments.css +0 -0
  92. data/app/assets/stylesheets/brightcontent/bootstrap-responsive.min.css +0 -9
  93. data/app/assets/stylesheets/brightcontent/bootstrap.min.css +0 -9
  94. data/app/assets/stylesheets/brightcontent/brightcontent.css +0 -19
  95. data/app/assets/stylesheets/brightcontent/main.css +0 -95
  96. data/app/assets/stylesheets/brightcontent/pages.css +0 -0
  97. data/app/views/brightcontent/base/_index_top.html.erb +0 -0
  98. data/app/views/brightcontent/base/_list.html.erb +0 -8
  99. data/app/views/brightcontent/base/_scope_filters.html.erb +0 -9
  100. data/config/initializers/will_paginate.rb +0 -28
  101. data/config/locales/brightcontent.en.yml +0 -10
  102. data/config/locales/brightcontent.nl.yml +0 -10
  103. data/lib/brightcontent/default_actions.rb +0 -28
  104. data/lib/brightcontent/pagination.rb +0 -28
  105. data/spec/features/scope_spec.rb +0 -27
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 147c48a77582f6e93c10d4a563c282bd7fbbb765
4
- data.tar.gz: c281ca212990a54336c0b0ce921abb45ed4a9989
3
+ metadata.gz: 785527dbe8ae6e79befb9e074d0ef98893551ba8
4
+ data.tar.gz: 1932114b9e4589e765adffc5d630c2a482332434
5
5
  SHA512:
6
- metadata.gz: 6956ed78f70cfb75f9d2f9cc0d90e7867c78862bee3d583d5a2e48b40645600a76a76a9de97044f68b16c43386e00b0ddc9bf950ac98f126e041be94de194ce0
7
- data.tar.gz: 55a585f385b36d9fb3853ce4dc6aad023bb075f56efb4e2cad3ee5f58db1dc7cfd6c0b548e79623b60ebab5a56bf5f2d683fbba888a01c475f12ae2c01b1c0f5
6
+ metadata.gz: 75f2630d907c0303a7a72a9090d1d4306d446e4d2a33d757ecba8fc3d4947a51e755688f595d4d55d32b335ccc593d3606bcbf3f700aa0cf20a548614e3ab815
7
+ data.tar.gz: 85db810a1df5e53b924b41dc3141322d8c49b67d71e28258ff82532781c1c25ca9451776886b25d7986ae57445b5107db04ef63a40358eebb088f88b2368fadb
data/.gitignore CHANGED
@@ -8,3 +8,4 @@ spec/dummy/log/*.log
8
8
  spec/dummy/tmp/
9
9
  spec/dummy/.sass-cache
10
10
  vendor/bundle
11
+ bin/
@@ -0,0 +1,8 @@
1
+ //= require jquery
2
+ //= require jquery_ujs
3
+ //= require bootstrap
4
+
5
+ <% (Brightcontent.extensions + ['custom']).each do |name|
6
+ require_asset("brightcontent/#{name}")
7
+ end
8
+ %>
@@ -0,0 +1,28 @@
1
+ #= require bootstrap-wysihtml5/b3
2
+ #= require brightcontent/wysithtml5-parser-rules
3
+ #= require bootstrap-wysihtml5/locales/nl-NL
4
+
5
+ $ ->
6
+ editorLocale = $('body').data('editorLocale')
7
+
8
+ $('[data-wysihtml5]').wysihtml5
9
+ html: true
10
+ locale: editorLocale
11
+ parserRules: wysihtml5ParserRules
12
+ events:
13
+ load: ->
14
+ editor = $("#insertable").data("wysihtml5").editor
15
+ editor.focus()
16
+
17
+ $("#attachments").on "click", ".insert_image", (e) ->
18
+ e.preventDefault()
19
+ editor.composer.commands.exec "insertImage",
20
+ src: $(this).data("insertImage")
21
+
22
+ $("#attachments").on "click", ".insert_link", (e) ->
23
+ e.preventDefault()
24
+ editor.composer.commands.exec "createLink",
25
+ href: $(this).data("insertUrl")
26
+ target: "_blank"
27
+ rel: "nofollow"
28
+ text: $(this).data("insertName")
@@ -0,0 +1,519 @@
1
+ var wysihtml5ParserRules = {
2
+ /**
3
+ * CSS Class white-list
4
+ * Following CSS classes won't be removed when parsed by the wysihtml5 HTML parser
5
+ */
6
+ "classes": {
7
+ "wysiwyg-clear-both": 1,
8
+ "wysiwyg-clear-left": 1,
9
+ "wysiwyg-clear-right": 1,
10
+ "wysiwyg-color-aqua": 1,
11
+ "wysiwyg-color-black": 1,
12
+ "wysiwyg-color-blue": 1,
13
+ "wysiwyg-color-fuchsia": 1,
14
+ "wysiwyg-color-gray": 1,
15
+ "wysiwyg-color-green": 1,
16
+ "wysiwyg-color-lime": 1,
17
+ "wysiwyg-color-maroon": 1,
18
+ "wysiwyg-color-navy": 1,
19
+ "wysiwyg-color-olive": 1,
20
+ "wysiwyg-color-purple": 1,
21
+ "wysiwyg-color-red": 1,
22
+ "wysiwyg-color-silver": 1,
23
+ "wysiwyg-color-teal": 1,
24
+ "wysiwyg-color-white": 1,
25
+ "wysiwyg-color-yellow": 1,
26
+ "wysiwyg-float-left": 1,
27
+ "wysiwyg-float-right": 1,
28
+ "wysiwyg-font-size-large": 1,
29
+ "wysiwyg-font-size-larger": 1,
30
+ "wysiwyg-font-size-medium": 1,
31
+ "wysiwyg-font-size-small": 1,
32
+ "wysiwyg-font-size-smaller": 1,
33
+ "wysiwyg-font-size-x-large": 1,
34
+ "wysiwyg-font-size-x-small": 1,
35
+ "wysiwyg-font-size-xx-large": 1,
36
+ "wysiwyg-font-size-xx-small": 1,
37
+ "wysiwyg-text-align-center": 1,
38
+ "wysiwyg-text-align-justify": 1,
39
+ "wysiwyg-text-align-left": 1,
40
+ "wysiwyg-text-align-right": 1
41
+ },
42
+ /**
43
+ * Tag list
44
+ *
45
+ * The following options are available:
46
+ *
47
+ * - add_class: converts and deletes the given HTML4 attribute (align, clear, ...) via the given method to a css class
48
+ * The following methods are implemented in wysihtml5.dom.parse:
49
+ * - align_text: converts align attribute values (right/left/center/justify) to their corresponding css class "wysiwyg-text-align-*")
50
+ * <p align="center">foo</p> ... becomes ... <p> class="wysiwyg-text-align-center">foo</p>
51
+ * - clear_br: converts clear attribute values left/right/all/both to their corresponding css class "wysiwyg-clear-*"
52
+ * <br clear="all"> ... becomes ... <br class="wysiwyg-clear-both">
53
+ * - align_img: converts align attribute values (right/left) on <img> to their corresponding css class "wysiwyg-float-*"
54
+ *
55
+ * - remove: removes the element and its content
56
+ *
57
+ * - rename_tag: renames the element to the given tag
58
+ *
59
+ * - set_class: adds the given class to the element (note: make sure that the class is in the "classes" white list above)
60
+ *
61
+ * - set_attributes: sets/overrides the given attributes
62
+ *
63
+ * - check_attributes: checks the given HTML attribute via the given method
64
+ * - url: allows only valid urls (starting with http:// or https://)
65
+ * - src: allows something like "/foobar.jpg", "http://google.com", ...
66
+ * - href: allows something like "mailto:bert@foo.com", "http://google.com", "/foobar.jpg"
67
+ * - alt: strips unwanted characters. if the attribute is not set, then it gets set (to ensure valid and compatible HTML)
68
+ * - numbers: ensures that the attribute only contains numeric characters
69
+ */
70
+ "tags": {
71
+ "tr": {
72
+ "add_class": {
73
+ "align": "align_text"
74
+ }
75
+ },
76
+ "strike": {
77
+ "remove": 1
78
+ },
79
+ "form": {
80
+ "rename_tag": "div"
81
+ },
82
+ "rt": {
83
+ "rename_tag": "span"
84
+ },
85
+ "code": {},
86
+ "acronym": {
87
+ "rename_tag": "span"
88
+ },
89
+ "br": {
90
+ "add_class": {
91
+ "clear": "clear_br"
92
+ }
93
+ },
94
+ "details": {
95
+ "rename_tag": "div"
96
+ },
97
+ "h4": {
98
+ "add_class": {
99
+ "align": "align_text"
100
+ }
101
+ },
102
+ "em": {},
103
+ "title": {
104
+ "remove": 1
105
+ },
106
+ "multicol": {
107
+ "rename_tag": "div"
108
+ },
109
+ "figure": {
110
+ "rename_tag": "div"
111
+ },
112
+ "xmp": {
113
+ "rename_tag": "span"
114
+ },
115
+ "small": {
116
+ "rename_tag": "span",
117
+ "set_class": "wysiwyg-font-size-smaller"
118
+ },
119
+ "area": {
120
+ "remove": 1
121
+ },
122
+ "time": {
123
+ "rename_tag": "span"
124
+ },
125
+ "dir": {
126
+ "rename_tag": "ul"
127
+ },
128
+ "bdi": {
129
+ "rename_tag": "span"
130
+ },
131
+ "command": {
132
+ "remove": 1
133
+ },
134
+ "ul": {},
135
+ "progress": {
136
+ "rename_tag": "span"
137
+ },
138
+ "dfn": {
139
+ "rename_tag": "span"
140
+ },
141
+ "iframe": {
142
+ "remove": 1
143
+ },
144
+ "figcaption": {
145
+ "rename_tag": "div"
146
+ },
147
+ "a": {
148
+ "check_attributes": {
149
+ "href": "url" // if you compiled master manually then change this from 'url' to 'href'
150
+ },
151
+ "set_attributes": {
152
+ "rel": "nofollow",
153
+ "target": "_blank"
154
+ }
155
+ },
156
+ "img": {
157
+ "check_attributes": {
158
+ "width": "numbers",
159
+ "alt": "alt",
160
+ "src": "url", // if you compiled master manually then change this from 'url' to 'src'
161
+ "height": "numbers"
162
+ },
163
+ "add_class": {
164
+ "align": "align_img"
165
+ }
166
+ },
167
+ "rb": {
168
+ "rename_tag": "span"
169
+ },
170
+ "footer": {
171
+ "rename_tag": "div"
172
+ },
173
+ "noframes": {
174
+ "remove": 1
175
+ },
176
+ "abbr": {
177
+ "rename_tag": "span"
178
+ },
179
+ "u": {},
180
+ "bgsound": {
181
+ "remove": 1
182
+ },
183
+ "sup": {
184
+ "rename_tag": "span"
185
+ },
186
+ "address": {
187
+ "rename_tag": "div"
188
+ },
189
+ "basefont": {
190
+ "remove": 1
191
+ },
192
+ "nav": {
193
+ "rename_tag": "div"
194
+ },
195
+ "h1": {
196
+ "add_class": {
197
+ "align": "align_text"
198
+ }
199
+ },
200
+ "head": {
201
+ "remove": 1
202
+ },
203
+ "tbody": {
204
+ "add_class": {
205
+ "align": "align_text"
206
+ }
207
+ },
208
+ "dd": {
209
+ "rename_tag": "div"
210
+ },
211
+ "s": {
212
+ "rename_tag": "span"
213
+ },
214
+ "li": {},
215
+ "td": {
216
+ "check_attributes": {
217
+ "rowspan": "numbers",
218
+ "colspan": "numbers"
219
+ },
220
+ "add_class": {
221
+ "align": "align_text"
222
+ }
223
+ },
224
+ "object": {
225
+ "remove": 1
226
+ },
227
+ "div": {
228
+ "add_class": {
229
+ "align": "align_text"
230
+ }
231
+ },
232
+ "option": {
233
+ "rename_tag": "span"
234
+ },
235
+ "select": {
236
+ "rename_tag": "span"
237
+ },
238
+ "i": {},
239
+ "track": {
240
+ "remove": 1
241
+ },
242
+ "wbr": {
243
+ "remove": 1
244
+ },
245
+ "fieldset": {
246
+ "rename_tag": "div"
247
+ },
248
+ "big": {
249
+ "rename_tag": "span",
250
+ "set_class": "wysiwyg-font-size-larger"
251
+ },
252
+ "button": {
253
+ "rename_tag": "span"
254
+ },
255
+ "noscript": {
256
+ "remove": 1
257
+ },
258
+ "svg": {
259
+ "remove": 1
260
+ },
261
+ "input": {
262
+ "remove": 1
263
+ },
264
+ "table": {},
265
+ "keygen": {
266
+ "remove": 1
267
+ },
268
+ "h5": {
269
+ "add_class": {
270
+ "align": "align_text"
271
+ }
272
+ },
273
+ "meta": {
274
+ "remove": 1
275
+ },
276
+ "map": {
277
+ "rename_tag": "div"
278
+ },
279
+ "isindex": {
280
+ "remove": 1
281
+ },
282
+ "mark": {
283
+ "rename_tag": "span"
284
+ },
285
+ "caption": {
286
+ "add_class": {
287
+ "align": "align_text"
288
+ }
289
+ },
290
+ "tfoot": {
291
+ "add_class": {
292
+ "align": "align_text"
293
+ }
294
+ },
295
+ "base": {
296
+ "remove": 1
297
+ },
298
+ "video": {
299
+ "remove": 1
300
+ },
301
+ "strong": {},
302
+ "canvas": {
303
+ "remove": 1
304
+ },
305
+ "output": {
306
+ "rename_tag": "span"
307
+ },
308
+ "marquee": {
309
+ "rename_tag": "span"
310
+ },
311
+ "b": {},
312
+ "q": {
313
+ "check_attributes": {
314
+ "cite": "url"
315
+ }
316
+ },
317
+ "applet": {
318
+ "remove": 1
319
+ },
320
+ "span": {},
321
+ "rp": {
322
+ "rename_tag": "span"
323
+ },
324
+ "spacer": {
325
+ "remove": 1
326
+ },
327
+ "source": {
328
+ "remove": 1
329
+ },
330
+ "aside": {
331
+ "rename_tag": "div"
332
+ },
333
+ "frame": {
334
+ "remove": 1
335
+ },
336
+ "section": {
337
+ "rename_tag": "div"
338
+ },
339
+ "body": {
340
+ "rename_tag": "div"
341
+ },
342
+ "ol": {},
343
+ "nobr": {
344
+ "rename_tag": "span"
345
+ },
346
+ "html": {
347
+ "rename_tag": "div"
348
+ },
349
+ "summary": {
350
+ "rename_tag": "span"
351
+ },
352
+ "var": {
353
+ "rename_tag": "span"
354
+ },
355
+ "del": {
356
+ "remove": 1
357
+ },
358
+ "blockquote": {
359
+ "check_attributes": {
360
+ "cite": "url"
361
+ }
362
+ },
363
+ "style": {
364
+ "remove": 1
365
+ },
366
+ "device": {
367
+ "remove": 1
368
+ },
369
+ "meter": {
370
+ "rename_tag": "span"
371
+ },
372
+ "h3": {
373
+ "add_class": {
374
+ "align": "align_text"
375
+ }
376
+ },
377
+ "textarea": {
378
+ "rename_tag": "span"
379
+ },
380
+ "embed": {
381
+ "remove": 1
382
+ },
383
+ "hgroup": {
384
+ "rename_tag": "div"
385
+ },
386
+ "font": {
387
+ "rename_tag": "span",
388
+ "add_class": {
389
+ "size": "size_font"
390
+ }
391
+ },
392
+ "tt": {
393
+ "rename_tag": "span"
394
+ },
395
+ "noembed": {
396
+ "remove": 1
397
+ },
398
+ "thead": {
399
+ "add_class": {
400
+ "align": "align_text"
401
+ }
402
+ },
403
+ "blink": {
404
+ "rename_tag": "span"
405
+ },
406
+ "plaintext": {
407
+ "rename_tag": "span"
408
+ },
409
+ "xml": {
410
+ "remove": 1
411
+ },
412
+ "h6": {
413
+ "add_class": {
414
+ "align": "align_text"
415
+ }
416
+ },
417
+ "param": {
418
+ "remove": 1
419
+ },
420
+ "th": {
421
+ "check_attributes": {
422
+ "rowspan": "numbers",
423
+ "colspan": "numbers"
424
+ },
425
+ "add_class": {
426
+ "align": "align_text"
427
+ }
428
+ },
429
+ "legend": {
430
+ "rename_tag": "span"
431
+ },
432
+ "hr": {},
433
+ "label": {
434
+ "rename_tag": "span"
435
+ },
436
+ "dl": {
437
+ "rename_tag": "div"
438
+ },
439
+ "kbd": {
440
+ "rename_tag": "span"
441
+ },
442
+ "listing": {
443
+ "rename_tag": "div"
444
+ },
445
+ "dt": {
446
+ "rename_tag": "span"
447
+ },
448
+ "nextid": {
449
+ "remove": 1
450
+ },
451
+ "pre": {},
452
+ "center": {
453
+ "rename_tag": "div",
454
+ "set_class": "wysiwyg-text-align-center"
455
+ },
456
+ "audio": {
457
+ "remove": 1
458
+ },
459
+ "datalist": {
460
+ "rename_tag": "span"
461
+ },
462
+ "samp": {
463
+ "rename_tag": "span"
464
+ },
465
+ "col": {
466
+ "remove": 1
467
+ },
468
+ "article": {
469
+ "rename_tag": "div"
470
+ },
471
+ "cite": {},
472
+ "link": {
473
+ "remove": 1
474
+ },
475
+ "script": {
476
+ "remove": 1
477
+ },
478
+ "bdo": {
479
+ "rename_tag": "span"
480
+ },
481
+ "menu": {
482
+ "rename_tag": "ul"
483
+ },
484
+ "colgroup": {
485
+ "remove": 1
486
+ },
487
+ "ruby": {
488
+ "rename_tag": "span"
489
+ },
490
+ "h2": {
491
+ "add_class": {
492
+ "align": "align_text"
493
+ }
494
+ },
495
+ "ins": {
496
+ "rename_tag": "span"
497
+ },
498
+ "p": {
499
+ "add_class": {
500
+ "align": "align_text"
501
+ }
502
+ },
503
+ "sub": {
504
+ "rename_tag": "span"
505
+ },
506
+ "comment": {
507
+ "remove": 1
508
+ },
509
+ "frameset": {
510
+ "remove": 1
511
+ },
512
+ "optgroup": {
513
+ "rename_tag": "span"
514
+ },
515
+ "header": {
516
+ "rename_tag": "div"
517
+ }
518
+ }
519
+ };
@@ -0,0 +1,10 @@
1
+ /*
2
+ *= require bootstrap
3
+ *= require bootstrap-wysihtml5/b3
4
+ *= require brightcontent/signin
5
+ */
6
+
7
+ <% (Brightcontent.extensions + ['custom']).each do |name|
8
+ require_asset("brightcontent/#{name}")
9
+ end
10
+ %>
@@ -0,0 +1,61 @@
1
+ body
2
+ background-color: #FAFAFA
3
+
4
+ .page-header
5
+ padding: 0 15px 10px
6
+ margin: 0
7
+ border-color: #ddd
8
+
9
+ .alert
10
+ margin: 15px
11
+
12
+ .navbar-bc
13
+ background: #40454F
14
+ .navbar-nav
15
+ > li > a
16
+ color: #D8DBDF
17
+ > .active > a
18
+ background: darken(#40454F, 7%)
19
+ .navbar-brand
20
+ color: #fff
21
+
22
+ .avatar
23
+ width: 30px
24
+ height: 30px
25
+ margin: -12px 10px -10px 0
26
+ border-radius: 20px
27
+
28
+ thead
29
+ text-transform: uppercase
30
+ font-size: 11px
31
+ letter-spacing: 1px
32
+
33
+ .table > thead > tr > th
34
+ border-width: 1px
35
+
36
+ .list-actions
37
+ text-align: right
38
+ opacity: 0
39
+ tr:hover &
40
+ opacity: 1
41
+
42
+ .file-preview img
43
+ border: 1px solid #ccc
44
+
45
+ .datetime
46
+ width: 116px
47
+
48
+ .form-fields
49
+ margin-top: 10px
50
+
51
+ .panel-footer-pagination
52
+ text-align: right
53
+
54
+ .pagination
55
+ margin: 0
56
+ margin-top: 3px
57
+
58
+ .list-false
59
+ font-size: 20px
60
+ line-height: 14px
61
+ font-weight: bold
@@ -0,0 +1,34 @@
1
+ .form-signin
2
+ max-width: 330px
3
+ padding: 15px
4
+ margin: 0 auto
5
+
6
+ .form-signin .form-signin-heading,
7
+ .form-signin .checkbox
8
+ margin-bottom: 30px
9
+ text-align: center
10
+
11
+ .form-signin .checkbox
12
+ font-weight: normal
13
+
14
+ .form-signin .form-control
15
+ position: relative
16
+ font-size: 16px
17
+ height: auto
18
+ padding: 10px
19
+ -webkit-box-sizing: border-box
20
+ -moz-box-sizing: border-box
21
+ box-sizing: border-box
22
+
23
+ .form-signin .form-control:focus
24
+ z-index: 2
25
+
26
+ .form-signin input[type="text"]
27
+ margin-bottom: -1px
28
+ border-bottom-left-radius: 0
29
+ border-bottom-right-radius: 0
30
+
31
+ .form-signin input[type="password"]
32
+ margin-bottom: 10px
33
+ border-top-left-radius: 0
34
+ border-top-right-radius: 0
@@ -2,8 +2,6 @@ require_dependency "brightcontent/application_controller"
2
2
 
3
3
  module Brightcontent
4
4
  class AdminUsersController < BaseController
5
- def form_fields
6
- %w( email password )
7
- end
5
+ form_fields :email, :password, :password_confirmation
8
6
  end
9
7
  end