locomotivecms 3.0.0.rc2 → 3.0.0.rc3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (109) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +2 -2
  3. data/README.md +2 -1
  4. data/app/api/locomotive/api/entities/site_entity.rb +8 -0
  5. data/app/api/locomotive/api/exception_rescuers.rb +1 -1
  6. data/app/api/locomotive/api/forms/content_entry_form.rb +4 -3
  7. data/app/api/locomotive/api/helpers/params_helper.rb +21 -3
  8. data/app/api/locomotive/api/resources/current_site_resource.rb +1 -1
  9. data/app/api/locomotive/api/resources/site_resource.rb +2 -2
  10. data/app/assets/images/locomotive/deadend.png +0 -0
  11. data/app/assets/javascripts/locomotive/not_logged_in.js.coffee +1 -1
  12. data/app/assets/javascripts/locomotive/utils/core_ext.js +1 -1
  13. data/app/assets/javascripts/locomotive/utils/wysihtml5.js.coffee +43 -17
  14. data/app/assets/javascripts/locomotive/views/application_view.js.coffee +5 -1
  15. data/app/assets/javascripts/locomotive/views/editable_elements/edit_view.js.coffee +47 -0
  16. data/app/assets/javascripts/locomotive/views/editable_elements/iframe_view.js.coffee +59 -0
  17. data/app/assets/javascripts/locomotive/views/editable_elements/index_view.js.coffee +19 -92
  18. data/app/assets/javascripts/locomotive/views/editable_elements/page_view.js.coffee +81 -0
  19. data/app/assets/javascripts/locomotive/views/editable_elements/text_highlighter_view.js.coffee +76 -0
  20. data/app/assets/javascripts/locomotive/views/inputs/rte/edit_table_view.js.coffee +35 -0
  21. data/app/assets/javascripts/locomotive/views/inputs/rte/file_view.js.coffee +14 -10
  22. data/app/assets/javascripts/locomotive/views/inputs/rte/link_view.js.coffee +25 -15
  23. data/app/assets/javascripts/locomotive/views/inputs/rte/table_view.js.coffee +82 -0
  24. data/app/assets/javascripts/locomotive/views/inputs/rte_view.js.coffee.erb +64 -23
  25. data/app/assets/javascripts/locomotive/views/inputs/text_view.js.coffee +11 -6
  26. data/app/assets/javascripts/locomotive.js +2 -2
  27. data/app/assets/stylesheets/locomotive/application.scss +1 -3
  28. data/app/assets/stylesheets/locomotive/base/_form.scss +2 -1
  29. data/app/assets/stylesheets/locomotive/base/_typography.scss +3 -2
  30. data/app/assets/stylesheets/locomotive/base/form/_base.scss +5 -0
  31. data/app/assets/stylesheets/locomotive/base/form/_rte.scss +42 -0
  32. data/app/assets/stylesheets/locomotive/error.scss +1 -1
  33. data/app/assets/stylesheets/locomotive/globals/_mixins.scss +41 -48
  34. data/app/assets/stylesheets/locomotive/globals/_variables.scss +202 -121
  35. data/app/assets/stylesheets/locomotive/layouts/_not_logged_in.scss +8 -9
  36. data/app/assets/stylesheets/locomotive/live_editing_error.scss +19 -0
  37. data/app/assets/stylesheets/locomotive/live_editing_iframe.scss +84 -0
  38. data/app/assets/stylesheets/locomotive/unauthorized/_forms.scss +63 -0
  39. data/app/assets/stylesheets/locomotive/unauthorized/_keyframes.scss +31 -0
  40. data/app/assets/stylesheets/locomotive/unauthorized/_notify.scss +85 -0
  41. data/app/assets/stylesheets/locomotive/unauthorized/_public.scss +129 -0
  42. data/app/assets/stylesheets/locomotive/unauthorized/_type.scss +14 -0
  43. data/app/assets/stylesheets/locomotive/unauthorized/_variables.scss +54 -0
  44. data/app/assets/stylesheets/locomotive/unauthorized.scss +34 -0
  45. data/app/helpers/locomotive/dashboard_helper.rb +1 -1
  46. data/app/inputs/locomotive/rte_input.rb +12 -0
  47. data/app/models/locomotive/concerns/page/editable_elements.rb +0 -2
  48. data/app/models/locomotive/editable_element.rb +1 -1
  49. data/app/services/locomotive/content_asset_service.rb +1 -1
  50. data/app/services/locomotive/page_parsing_service.rb +4 -2
  51. data/app/views/locomotive/editable_elements/index.html.slim +1 -1
  52. data/app/views/locomotive/layouts/not_logged_in.html.slim +13 -9
  53. data/app/views/locomotive/passwords/edit.html.slim +13 -13
  54. data/app/views/locomotive/passwords/new.html.slim +14 -11
  55. data/app/views/locomotive/registrations/new.html.slim +14 -13
  56. data/app/views/locomotive/sessions/new.html.slim +14 -13
  57. data/app/views/locomotive/shared/rte/_markdown_toolbar.html.slim +0 -30
  58. data/app/views/locomotive/shared/rte/_table_popover.html.slim +17 -0
  59. data/app/views/locomotive/shared/rte/_toolbar.html.slim +48 -11
  60. data/config/initializers/simple_form.rb +2 -0
  61. data/config/locales/carrierwave.lt.yml +4 -0
  62. data/config/locales/carrierwave.nl.yml +4 -0
  63. data/config/locales/carrierwave.ru.yml +4 -0
  64. data/config/locales/default.nl.yml +13 -0
  65. data/config/locales/devise.nl.yml +61 -0
  66. data/config/locales/en.yml +28 -10
  67. data/config/locales/flash.nl.yml +79 -0
  68. data/config/locales/inputs.lt.yml +18 -0
  69. data/config/locales/inputs.nl.yml +18 -0
  70. data/config/locales/mongoid.nl.yml +47 -0
  71. data/config/locales/nl.yml +316 -0
  72. data/config/locales/simple_form.en.yml +6 -0
  73. data/config/locales/simple_form.nl.yml +148 -0
  74. data/lib/locomotive/carrierwave/asset.rb +5 -1
  75. data/lib/locomotive/dependencies.rb +0 -1
  76. data/lib/locomotive/engine.rb +7 -1
  77. data/lib/locomotive/middlewares/site.rb +14 -2
  78. data/lib/locomotive/mongoid/patches.rb +29 -0
  79. data/lib/locomotive/steam/middlewares/catch_error.rb +78 -0
  80. data/lib/locomotive/steam/middlewares/wysihtml_css.rb +32 -0
  81. data/lib/locomotive/steam_adaptor.rb +4 -7
  82. data/lib/locomotive/version.rb +1 -1
  83. data/spec/requests/locomotive/steam/cache_spec.rb +3 -3
  84. data/spec/requests/locomotive/steam/wysihtml_css_spec.rb +42 -0
  85. data/spec/requests/site_spec.rb +13 -2
  86. data/spec/support/features/session_helpers.rb +3 -3
  87. data/vendor/assets/components/locomotive/backbone/backbone.js +1894 -0
  88. data/vendor/assets/components/locomotive/underscore/underscore.js +1548 -0
  89. data/vendor/assets/components/locomotive_sources/backbone/LICENSE +22 -0
  90. data/vendor/assets/components/locomotive_sources/backbone/backbone-min.js +2 -0
  91. data/vendor/assets/components/locomotive_sources/backbone/backbone-min.map +1 -0
  92. data/vendor/assets/components/locomotive_sources/backbone/backbone.js +1894 -0
  93. data/vendor/assets/components/locomotive_sources/backbone/bower.json +8 -0
  94. data/vendor/assets/components/locomotive_sources/underscore/LICENSE +23 -0
  95. data/vendor/assets/components/locomotive_sources/underscore/README.md +22 -0
  96. data/vendor/assets/components/locomotive_sources/underscore/bower.json +7 -0
  97. data/vendor/assets/components/locomotive_sources/underscore/underscore-min.js +6 -0
  98. data/vendor/assets/components/locomotive_sources/underscore/underscore-min.map +1 -0
  99. data/vendor/assets/components/locomotive_sources/underscore/underscore.js +1548 -0
  100. data/vendor/assets/javascripts/locomotive/wysihtml5/parser_rules/advanced.js +22 -48
  101. data/vendor/assets/javascripts/locomotive/wysihtml5/parser_rules/advanced_unwrap.js +13 -12
  102. data/vendor/assets/javascripts/locomotive/wysihtml5x-toolbar.js +7324 -3862
  103. data/vendor/assets/stylesheets/locomotive/wysihtml5_editor.css +27 -1
  104. metadata +53 -28
  105. data/app/assets/stylesheets/locomotive/globals/_all.scss +0 -3
  106. data/app/assets/stylesheets/locomotive/globals/_bootstrap.scss +0 -841
  107. data/app/assets/stylesheets/locomotive/globals/_colors.scss +0 -1
  108. data/app/assets/stylesheets/locomotive/globals/_nprogress.scss +0 -3
  109. data/app/assets/stylesheets/locomotive/not_logged_in.scss +0 -15
@@ -130,4 +130,30 @@
130
130
 
131
131
  .wysiwyg-clear-left {
132
132
  clear: left;
133
- }
133
+ }
134
+
135
+ .wysihtml5-editor table {
136
+ width: 100%;
137
+ border-collapse: collapse;
138
+ border: 1px solid #eee;
139
+ }
140
+
141
+ .wysihtml5-editor table th, .wysihtml5-editor table td {
142
+ padding: 8px;
143
+ }
144
+
145
+ .wysihtml5-editor table th {
146
+ border: 1px solid #dfdfdf;
147
+ }
148
+
149
+ .wysihtml5-editor table td {
150
+ border: 1px solid #eee;
151
+ }
152
+
153
+ .wysihtml5-editor table td.wysiwyg-tmp-selected-cell, .wysihtml5-editor table th.wysiwyg-tmp-selected-cell {
154
+ background-color: #fafafa;
155
+ }
156
+
157
+ .wysihtml5-editor a {
158
+ color: #4fb9ce;
159
+ }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: locomotivecms
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0.rc2
4
+ version: 3.0.0.rc3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Didier Lafforgue
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-10-26 00:00:00.000000000 Z
11
+ date: 2015-11-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 4.2.4
33
+ version: 4.2.5
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 4.2.4
40
+ version: 4.2.5
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: net-ssh
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -184,14 +184,14 @@ dependencies:
184
184
  requirements:
185
185
  - - "~>"
186
186
  - !ruby/object:Gem::Version
187
- version: 1.0.0.rc2
187
+ version: 1.0.0.rc3
188
188
  type: :runtime
189
189
  prerelease: false
190
190
  version_requirements: !ruby/object:Gem::Requirement
191
191
  requirements:
192
192
  - - "~>"
193
193
  - !ruby/object:Gem::Version
194
- version: 1.0.0.rc2
194
+ version: 1.0.0.rc3
195
195
  - !ruby/object:Gem::Dependency
196
196
  name: slim
197
197
  requirement: !ruby/object:Gem::Requirement
@@ -304,20 +304,6 @@ dependencies:
304
304
  - - "~>"
305
305
  - !ruby/object:Gem::Version
306
306
  version: 5.0.3
307
- - !ruby/object:Gem::Dependency
308
- name: backbone-on-rails
309
- requirement: !ruby/object:Gem::Requirement
310
- requirements:
311
- - - "~>"
312
- - !ruby/object:Gem::Version
313
- version: 1.2.0.0
314
- type: :runtime
315
- prerelease: false
316
- version_requirements: !ruby/object:Gem::Requirement
317
- requirements:
318
- - - "~>"
319
- - !ruby/object:Gem::Version
320
- version: 1.2.0.0
321
307
  - !ruby/object:Gem::Dependency
322
308
  name: codemirror-rails
323
309
  requirement: !ruby/object:Gem::Requirement
@@ -380,14 +366,14 @@ dependencies:
380
366
  requirements:
381
367
  - - "~>"
382
368
  - !ruby/object:Gem::Version
383
- version: 3.3.3
369
+ version: 3.3.5.1
384
370
  type: :runtime
385
371
  prerelease: false
386
372
  version_requirements: !ruby/object:Gem::Requirement
387
373
  requirements:
388
374
  - - "~>"
389
375
  - !ruby/object:Gem::Version
390
- version: 3.3.3
376
+ version: 3.3.5.1
391
377
  - !ruby/object:Gem::Dependency
392
378
  name: autoprefixer-rails
393
379
  requirement: !ruby/object:Gem::Requirement
@@ -664,6 +650,7 @@ files:
664
650
  - app/api/locomotive/api/resources/translation_resource.rb
665
651
  - app/api/locomotive/api/resources/version_resource.rb
666
652
  - app/assets/images/locomotive/datepicker/ui-widget-content-top.png
653
+ - app/assets/images/locomotive/deadend.png
667
654
  - app/assets/images/locomotive/favicon.png
668
655
  - app/assets/images/locomotive/icons/flags/bf.png
669
656
  - app/assets/images/locomotive/icons/flags/bg.png
@@ -714,13 +701,18 @@ files:
714
701
  - app/assets/javascripts/locomotive/views/dashboard/show_view.js.coffee
715
702
  - app/assets/javascripts/locomotive/views/developers_documentation/show_view.js.coffee
716
703
  - app/assets/javascripts/locomotive/views/editable_elements/edit_view.js.coffee
704
+ - app/assets/javascripts/locomotive/views/editable_elements/iframe_view.js.coffee
717
705
  - app/assets/javascripts/locomotive/views/editable_elements/index_view.js.coffee
706
+ - app/assets/javascripts/locomotive/views/editable_elements/page_view.js.coffee
707
+ - app/assets/javascripts/locomotive/views/editable_elements/text_highlighter_view.js.coffee
718
708
  - app/assets/javascripts/locomotive/views/inputs/array_view.js.coffee
719
709
  - app/assets/javascripts/locomotive/views/inputs/document_picker_view.js.coffee
720
710
  - app/assets/javascripts/locomotive/views/inputs/file_view.js.coffee
721
711
  - app/assets/javascripts/locomotive/views/inputs/markdown_view.js.coffee
712
+ - app/assets/javascripts/locomotive/views/inputs/rte/edit_table_view.js.coffee
722
713
  - app/assets/javascripts/locomotive/views/inputs/rte/file_view.js.coffee
723
714
  - app/assets/javascripts/locomotive/views/inputs/rte/link_view.js.coffee
715
+ - app/assets/javascripts/locomotive/views/inputs/rte/table_view.js.coffee
724
716
  - app/assets/javascripts/locomotive/views/inputs/rte_view.js.coffee.erb
725
717
  - app/assets/javascripts/locomotive/views/inputs/text_view.js.coffee
726
718
  - app/assets/javascripts/locomotive/views/memberships/edit_view.js.coffee
@@ -795,17 +787,21 @@ files:
795
787
  - app/assets/stylesheets/locomotive/components/sidebar/_my_account.scss
796
788
  - app/assets/stylesheets/locomotive/components/sidebar/_pages_tree.scss
797
789
  - app/assets/stylesheets/locomotive/error.scss
798
- - app/assets/stylesheets/locomotive/globals/_all.scss
799
- - app/assets/stylesheets/locomotive/globals/_bootstrap.scss
800
- - app/assets/stylesheets/locomotive/globals/_colors.scss
801
790
  - app/assets/stylesheets/locomotive/globals/_mixins.scss
802
- - app/assets/stylesheets/locomotive/globals/_nprogress.scss
803
791
  - app/assets/stylesheets/locomotive/globals/_variables.scss
804
792
  - app/assets/stylesheets/locomotive/layouts/_live_editing.scss
805
793
  - app/assets/stylesheets/locomotive/layouts/_main.scss
806
794
  - app/assets/stylesheets/locomotive/layouts/_not_logged_in.scss
807
795
  - app/assets/stylesheets/locomotive/layouts/_responsive.scss
808
- - app/assets/stylesheets/locomotive/not_logged_in.scss
796
+ - app/assets/stylesheets/locomotive/live_editing_error.scss
797
+ - app/assets/stylesheets/locomotive/live_editing_iframe.scss
798
+ - app/assets/stylesheets/locomotive/unauthorized.scss
799
+ - app/assets/stylesheets/locomotive/unauthorized/_forms.scss
800
+ - app/assets/stylesheets/locomotive/unauthorized/_keyframes.scss
801
+ - app/assets/stylesheets/locomotive/unauthorized/_notify.scss
802
+ - app/assets/stylesheets/locomotive/unauthorized/_public.scss
803
+ - app/assets/stylesheets/locomotive/unauthorized/_type.scss
804
+ - app/assets/stylesheets/locomotive/unauthorized/_variables.scss
809
805
  - app/controllers/locomotive/accounts_controller.rb
810
806
  - app/controllers/locomotive/base_controller.rb
811
807
  - app/controllers/locomotive/concerns/account_controller.rb
@@ -1043,6 +1039,7 @@ files:
1043
1039
  - app/views/locomotive/shared/rte/_image_popover.html.slim
1044
1040
  - app/views/locomotive/shared/rte/_link_popover.html.slim
1045
1041
  - app/views/locomotive/shared/rte/_markdown_toolbar.html.slim
1042
+ - app/views/locomotive/shared/rte/_table_popover.html.slim
1046
1043
  - app/views/locomotive/shared/rte/_toolbar.html.slim
1047
1044
  - app/views/locomotive/shared/sidebar/_content_types.html.slim
1048
1045
  - app/views/locomotive/shared/sidebar/_link.html.slim
@@ -1064,20 +1061,31 @@ files:
1064
1061
  - config/initializers/time_format.rb
1065
1062
  - config/locales/carrierwave.en.yml
1066
1063
  - config/locales/carrierwave.fr.yml
1064
+ - config/locales/carrierwave.lt.yml
1065
+ - config/locales/carrierwave.nl.yml
1066
+ - config/locales/carrierwave.ru.yml
1067
1067
  - config/locales/default.en.yml
1068
1068
  - config/locales/default.fr.yml
1069
+ - config/locales/default.nl.yml
1069
1070
  - config/locales/devise.en.yml
1070
1071
  - config/locales/devise.fr.yml
1072
+ - config/locales/devise.nl.yml
1071
1073
  - config/locales/en.yml
1072
1074
  - config/locales/flash.en.yml
1073
1075
  - config/locales/flash.fr.yml
1076
+ - config/locales/flash.nl.yml
1074
1077
  - config/locales/fr.yml
1075
1078
  - config/locales/inputs.en.yml
1076
1079
  - config/locales/inputs.fr.yml
1080
+ - config/locales/inputs.lt.yml
1081
+ - config/locales/inputs.nl.yml
1077
1082
  - config/locales/mongoid.en.yml
1078
1083
  - config/locales/mongoid.fr.yml
1084
+ - config/locales/mongoid.nl.yml
1085
+ - config/locales/nl.yml
1079
1086
  - config/locales/simple_form.en.yml
1080
1087
  - config/locales/simple_form.fr.yml
1088
+ - config/locales/simple_form.nl.yml
1081
1089
  - config/old-locales/admin_ui.bg.yml
1082
1090
  - config/old-locales/admin_ui.cs.yml
1083
1091
  - config/old-locales/admin_ui.de.yml
@@ -1294,8 +1302,10 @@ files:
1294
1302
  - lib/locomotive/simple_form.rb
1295
1303
  - lib/locomotive/simple_token_authentication.rb
1296
1304
  - lib/locomotive/steam/middlewares/cache.rb
1305
+ - lib/locomotive/steam/middlewares/catch_error.rb
1297
1306
  - lib/locomotive/steam/middlewares/missing_translations.rb
1298
1307
  - lib/locomotive/steam/middlewares/page_editing.rb
1308
+ - lib/locomotive/steam/middlewares/wysihtml_css.rb
1299
1309
  - lib/locomotive/steam/services/api_entry_submission_service.rb
1300
1310
  - lib/locomotive/steam/services/liquid_parser_with_cache_service.rb
1301
1311
  - lib/locomotive/steam_adaptor.rb
@@ -1385,6 +1395,7 @@ files:
1385
1395
  - spec/models/locomotive/translation_spec.rb
1386
1396
  - spec/requests/admin_ssl_spec.rb
1387
1397
  - spec/requests/locomotive/steam/cache_spec.rb
1398
+ - spec/requests/locomotive/steam/wysihtml_css_spec.rb
1388
1399
  - spec/requests/site_spec.rb
1389
1400
  - spec/support/capybara.rb
1390
1401
  - spec/support/carrierwave.rb
@@ -1401,6 +1412,19 @@ files:
1401
1412
  - spec/support/shared_contexts/api_header_setup.rb
1402
1413
  - spec/support/shared_contexts/api_site_setup.rb
1403
1414
  - spec/support/shared_examples/site_scope_examples.rb
1415
+ - vendor/assets/components/locomotive/backbone/backbone.js
1416
+ - vendor/assets/components/locomotive/underscore/underscore.js
1417
+ - vendor/assets/components/locomotive_sources/backbone/LICENSE
1418
+ - vendor/assets/components/locomotive_sources/backbone/backbone-min.js
1419
+ - vendor/assets/components/locomotive_sources/backbone/backbone-min.map
1420
+ - vendor/assets/components/locomotive_sources/backbone/backbone.js
1421
+ - vendor/assets/components/locomotive_sources/backbone/bower.json
1422
+ - vendor/assets/components/locomotive_sources/underscore/LICENSE
1423
+ - vendor/assets/components/locomotive_sources/underscore/README.md
1424
+ - vendor/assets/components/locomotive_sources/underscore/bower.json
1425
+ - vendor/assets/components/locomotive_sources/underscore/underscore-min.js
1426
+ - vendor/assets/components/locomotive_sources/underscore/underscore-min.map
1427
+ - vendor/assets/components/locomotive_sources/underscore/underscore.js
1404
1428
  - vendor/assets/images/locomotive/bootstrap-colorpicker/alpha-horizontal.png
1405
1429
  - vendor/assets/images/locomotive/bootstrap-colorpicker/alpha.png
1406
1430
  - vendor/assets/images/locomotive/bootstrap-colorpicker/hue-horizontal.png
@@ -1473,7 +1497,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
1473
1497
  version: 1.3.1
1474
1498
  requirements: []
1475
1499
  rubyforge_project:
1476
- rubygems_version: 2.4.5
1500
+ rubygems_version: 2.5.0
1477
1501
  signing_key:
1478
1502
  specification_version: 4
1479
1503
  summary: A platform to create, publish and edit sites
@@ -1609,6 +1633,7 @@ test_files:
1609
1633
  - spec/models/locomotive/translation_spec.rb
1610
1634
  - spec/requests/admin_ssl_spec.rb
1611
1635
  - spec/requests/locomotive/steam/cache_spec.rb
1636
+ - spec/requests/locomotive/steam/wysihtml_css_spec.rb
1612
1637
  - spec/requests/site_spec.rb
1613
1638
  - spec/support/capybara.rb
1614
1639
  - spec/support/carrierwave.rb
@@ -1,3 +0,0 @@
1
- @import "./colors";
2
- @import "./variables";
3
- @import "./mixins";