trusty-cms 4.0.2 → 4.1.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (221) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +3 -3
  3. data/Gemfile.lock +89 -89
  4. data/Rakefile +7 -7
  5. data/app/assets/images/admin/spinner.gif +0 -0
  6. data/app/assets/javascripts/admin.js +3 -0
  7. data/app/assets/javascripts/admin/more-or-less.js +2 -2
  8. data/app/assets/javascripts/admin/tabcontrol.js.erb +1 -2
  9. data/app/assets/javascripts/rad_social/rad_ajax_form.js +3 -0
  10. data/app/assets/javascripts/rad_social/rad_email.js +0 -1
  11. data/app/assets/javascripts/rad_social/rad_email_form.js +2 -7
  12. data/app/assets/stylesheets/admin/_base.scss +22 -6
  13. data/app/assets/stylesheets/admin/_multi_site_main.scss +28 -29
  14. data/app/assets/stylesheets/admin/_reset.scss +5 -4
  15. data/app/assets/stylesheets/admin/_site_chooser.scss +44 -69
  16. data/app/assets/stylesheets/admin/assets.scss +138 -141
  17. data/app/assets/stylesheets/admin/main.scss +10 -12
  18. data/app/assets/stylesheets/admin/modules/_boxes.scss +0 -3
  19. data/app/assets/stylesheets/admin/modules/_buttons.scss +30 -0
  20. data/app/assets/stylesheets/admin/modules/_links.scss +1 -1
  21. data/app/assets/stylesheets/admin/partials/_actions.scss +29 -46
  22. data/app/assets/stylesheets/admin/partials/_avatars.scss +3 -2
  23. data/app/assets/stylesheets/admin/partials/_content.scss +15 -38
  24. data/app/assets/stylesheets/admin/partials/_dateinput.scss +23 -14
  25. data/app/assets/stylesheets/admin/partials/_drawer.scss +78 -0
  26. data/app/assets/stylesheets/admin/partials/_dropdown.scss +9 -12
  27. data/app/assets/stylesheets/admin/partials/_footer.scss +4 -3
  28. data/app/assets/stylesheets/admin/partials/_forms.scss +64 -493
  29. data/app/assets/stylesheets/admin/partials/_header.scss +9 -118
  30. data/app/assets/stylesheets/admin/partials/_layout.scss +26 -2
  31. data/app/assets/stylesheets/admin/partials/_login_form.scss +28 -0
  32. data/app/assets/stylesheets/admin/partials/_messages.scss +10 -5
  33. data/app/assets/stylesheets/admin/partials/_popup.scss +61 -50
  34. data/app/assets/stylesheets/admin/partials/_preferences.scss +37 -0
  35. data/app/assets/stylesheets/admin/partials/_sidebar.scss +55 -0
  36. data/app/assets/stylesheets/admin/partials/_tabcontrol.scss +24 -36
  37. data/app/assets/stylesheets/admin/partials/{_index.scss → _table.scss} +53 -84
  38. data/app/assets/stylesheets/admin/partials/_toolbar.scss +11 -6
  39. data/app/assets/stylesheets/admin/partials/_treetable.scss +1 -71
  40. data/app/assets/stylesheets/admin/partials/_typography.scss +30 -55
  41. data/app/assets/stylesheets/admin/partials/_validations.scss +6 -5
  42. data/app/assets/stylesheets/rad_social/rad_screen.scss +64 -67
  43. data/app/controllers/admin/assets_controller.rb +21 -31
  44. data/app/controllers/admin/configuration_controller.rb +9 -11
  45. data/app/controllers/admin/extensions_controller.rb +3 -3
  46. data/app/controllers/admin/layouts_controller.rb +3 -4
  47. data/app/controllers/admin/page_attachments_controller.rb +5 -5
  48. data/app/controllers/admin/page_fields_controller.rb +3 -4
  49. data/app/controllers/admin/page_parts_controller.rb +4 -5
  50. data/app/controllers/admin/pages_controller.rb +55 -56
  51. data/app/controllers/admin/references_controller.rb +1 -1
  52. data/app/controllers/admin/resource_controller.rb +132 -130
  53. data/app/controllers/admin/sites_controller.rb +4 -4
  54. data/app/controllers/admin/snippets_controller.rb +3 -4
  55. data/app/controllers/admin/users_controller.rb +16 -16
  56. data/app/controllers/application_controller.rb +47 -48
  57. data/app/controllers/site_controller.rb +51 -48
  58. data/app/controllers/social_mailer_controller.rb +12 -22
  59. data/app/helpers/admin/configuration_helper.rb +19 -20
  60. data/app/helpers/admin/layouts_helper.rb +0 -1
  61. data/app/helpers/admin/node_helper.rb +27 -24
  62. data/app/helpers/admin/pages_helper.rb +2 -2
  63. data/app/helpers/admin/preferences_helper.rb +0 -1
  64. data/app/helpers/admin/references_helper.rb +9 -10
  65. data/app/helpers/admin/regions_helper.rb +3 -3
  66. data/app/helpers/application_helper.rb +34 -35
  67. data/app/helpers/rad_social_helper.rb +8 -11
  68. data/app/helpers/scoped_helper.rb +1 -3
  69. data/app/helpers/sites_helper.rb +4 -4
  70. data/app/mailers/devise_mailer.rb +3 -4
  71. data/app/mailers/rad_social_mailer.rb +8 -8
  72. data/app/models/asset.rb +62 -63
  73. data/app/models/asset_type.rb +38 -39
  74. data/app/models/deprecated_tags.rb +3 -4
  75. data/app/models/file_not_found_page.rb +1 -3
  76. data/app/models/haml_filter.rb +1 -1
  77. data/app/models/layout.rb +4 -5
  78. data/app/models/legacy_user.rb +2 -2
  79. data/app/models/menu_renderer.rb +16 -18
  80. data/app/models/page.rb +96 -93
  81. data/app/models/page_attachment.rb +1 -2
  82. data/app/models/page_context.rb +11 -12
  83. data/app/models/page_part.rb +3 -4
  84. data/app/models/rails_page.rb +10 -12
  85. data/app/models/site.rb +22 -21
  86. data/app/models/snippet.rb +6 -8
  87. data/app/models/snippet_finder.rb +3 -3
  88. data/app/models/snippet_tags.rb +4 -4
  89. data/app/models/standard_tags.rb +258 -252
  90. data/app/models/status.rb +8 -8
  91. data/app/models/trusty_cms/config.rb +25 -25
  92. data/app/models/trusty_cms/page_response_cache_director.rb +2 -3
  93. data/app/models/user.rb +15 -14
  94. data/app/models/user_action_observer.rb +3 -3
  95. data/app/users/_choose_site.html.haml +3 -7
  96. data/app/views/admin/assets/_form.html.haml +2 -1
  97. data/app/views/admin/assets/_search.html.haml +2 -1
  98. data/app/views/admin/assets/edit.html.haml +2 -10
  99. data/app/views/admin/assets/index.html.haml +4 -2
  100. data/app/views/admin/assets/new.html.haml +4 -8
  101. data/app/views/admin/assets/remove.html.haml +2 -1
  102. data/app/views/admin/configuration/edit.html.haml +7 -7
  103. data/app/views/admin/configuration/show.html.haml +6 -8
  104. data/app/views/admin/layouts/_choose_site.html.haml +2 -3
  105. data/app/views/admin/layouts/_form.html.haml +13 -12
  106. data/app/views/admin/layouts/_site_chooser.html.haml +2 -2
  107. data/app/views/admin/layouts/index.html.haml +11 -4
  108. data/app/views/admin/layouts/remove.html.haml +6 -5
  109. data/app/views/admin/page_attachments/_attachment.html.haml +2 -2
  110. data/app/views/admin/page_fields/_page_field.html.haml +3 -3
  111. data/app/views/admin/page_parts/_page_part.html.haml +5 -6
  112. data/app/views/admin/pages/_asset_popups.html.haml +15 -16
  113. data/app/views/admin/pages/_assets.html.haml +8 -7
  114. data/app/views/admin/pages/_fields.html.haml +16 -13
  115. data/app/views/admin/pages/_node.html.haml +3 -3
  116. data/app/views/admin/pages/_popups.html.haml +11 -11
  117. data/app/views/admin/pages/edit.html.haml +2 -2
  118. data/app/views/admin/pages/index.html.haml +5 -2
  119. data/app/views/admin/pages/new.html.haml +3 -3
  120. data/app/views/admin/pages/remove.html.haml +4 -3
  121. data/app/views/admin/preferences/edit.html.haml +5 -5
  122. data/app/views/admin/references/filters.haml +1 -1
  123. data/app/views/admin/references/tags.haml +3 -3
  124. data/app/views/admin/removed/_assets_bucket.html.haml +3 -3
  125. data/app/views/admin/removed/_assets_container.html.haml +18 -18
  126. data/app/views/admin/removed/_bucket.html.haml +1 -1
  127. data/app/views/admin/removed/_bucket_asset.html.haml +3 -3
  128. data/app/views/admin/removed/_show_bucket_link.html.haml +1 -1
  129. data/app/views/admin/removed/_upload_to_page.html.haml +5 -5
  130. data/app/views/admin/sites/_form.haml +18 -18
  131. data/app/views/admin/sites/edit.haml +1 -1
  132. data/app/views/admin/sites/index.haml +8 -4
  133. data/app/views/admin/sites/new.haml +1 -1
  134. data/app/views/admin/snippets/_choose_site.html.haml +4 -5
  135. data/app/views/admin/snippets/_form.html.haml +8 -9
  136. data/app/views/admin/snippets/edit.html.haml +1 -1
  137. data/app/views/admin/snippets/index.html.haml +11 -4
  138. data/app/views/admin/snippets/new.html.haml +1 -1
  139. data/app/views/admin/snippets/remove.html.haml +7 -6
  140. data/app/views/admin/users/_avatar.html.haml +2 -2
  141. data/app/views/admin/users/_choose_site.html.haml +3 -7
  142. data/app/views/admin/users/_form.html.haml +18 -21
  143. data/app/views/admin/users/_password_fields.html.haml +6 -6
  144. data/app/views/admin/users/index.html.haml +13 -6
  145. data/app/views/admin/users/remove.html.haml +4 -4
  146. data/app/views/admin/welcome/login.html.haml +8 -8
  147. data/app/views/devise/passwords/edit.html.haml +6 -6
  148. data/app/views/devise/passwords/new.html.haml +3 -3
  149. data/app/views/devise/sessions/new.html.haml +8 -8
  150. data/app/views/devise/shared/_links.html.haml +2 -2
  151. data/app/views/layouts/application.html.haml +24 -19
  152. data/app/views/rad_social_mailer/social_mail_form.html.haml +15 -17
  153. data/app/views/widget/_email_form.html.haml +13 -18
  154. data/app/views/widget/_horizontal_widget.html.haml +5 -5
  155. data/bin/rails +4 -4
  156. data/bin/trusty_cms +3 -5
  157. data/config.ru +1 -1
  158. data/config/application.rb +14 -15
  159. data/config/boot.rb +1 -2
  160. data/config/environment.rb +1 -1
  161. data/config/environments/production.rb +0 -1
  162. data/config/environments/test.rb +1 -2
  163. data/config/initializers/devise.rb +1 -1
  164. data/config/initializers/kraken.rb +2 -2
  165. data/config/initializers/tmp.rb +1 -1
  166. data/config/initializers/trusty_cms_config.rb +48 -48
  167. data/config/locales/en.yml +8 -8
  168. data/config/routes.rb +6 -7
  169. data/lib/active_record_extensions/active_record_extensions.rb +1 -2
  170. data/lib/annotatable.rb +3 -5
  171. data/lib/configuration_extensions/configuration_extensions.rb +1 -1
  172. data/lib/inheritable_class_attributes.rb +13 -9
  173. data/lib/login_system.rb +73 -73
  174. data/lib/method_observer.rb +13 -12
  175. data/lib/ostruct.rb +7 -10
  176. data/lib/simpleton.rb +0 -4
  177. data/lib/string_extensions/string_extensions.rb +3 -3
  178. data/lib/symbol_extensions/symbol_extensions.rb +1 -1
  179. data/lib/tasks/database.rake +28 -28
  180. data/lib/tasks/extensions.rake +18 -18
  181. data/lib/tasks/framework.rake +68 -68
  182. data/lib/tasks/radiant_config.rake +4 -4
  183. data/lib/tasks/snippets_extension_tasks.rake +11 -11
  184. data/lib/tasks/translate.rake +14 -14
  185. data/lib/tasks/upgrade_to_devise.rake +1 -1
  186. data/lib/translation_support.rb +22 -22
  187. data/lib/trusty_cms.rb +2 -2
  188. data/lib/trusty_cms/admin_ui.rb +19 -16
  189. data/lib/trusty_cms/admin_ui/region_partials.rb +4 -3
  190. data/lib/trusty_cms/admin_ui/region_set.rb +4 -5
  191. data/lib/trusty_cms/available_locales.rb +2 -4
  192. data/lib/trusty_cms/config/definition.rb +11 -8
  193. data/lib/trusty_cms/engine.rb +13 -14
  194. data/lib/trusty_cms/extension.rb +14 -16
  195. data/lib/trusty_cms/extension_loader.rb +6 -6
  196. data/lib/trusty_cms/extension_migrator.rb +42 -41
  197. data/lib/trusty_cms/extension_path.rb +20 -19
  198. data/lib/trusty_cms/initializer.rb +5 -8
  199. data/lib/trusty_cms/pagination/controller.rb +7 -10
  200. data/lib/trusty_cms/pagination/link_renderer.rb +2 -2
  201. data/lib/trusty_cms/resource_responses.rb +3 -3
  202. data/lib/trusty_cms/setup.rb +130 -132
  203. data/lib/trusty_cms/taggable.rb +19 -22
  204. data/lib/trusty_cms/task_support.rb +9 -6
  205. data/package.json +10 -2
  206. data/public/dispatch.fcgi +1 -1
  207. data/public/dispatch.rb +2 -2
  208. data/script/extension +1 -1
  209. data/script/rails +2 -2
  210. data/spec/dummy/package.json +1 -1
  211. data/spec/dummy/yarn.lock +3 -3
  212. data/trusty_cms.gemspec +25 -25
  213. data/vendor/extensions/clipped-extension/lib/clipped_admin_ui.rb +1 -1
  214. data/yarn.lock +1992 -4
  215. metadata +54 -43
  216. data/app/assets/javascripts/rad_social/captcha.js +0 -42
  217. data/app/assets/stylesheets/admin/partials/_deprecated.scss +0 -65
  218. data/app/assets/stylesheets/admin/partials/_jquery-ui-structure.scss +0 -258
  219. data/app/assets/stylesheets/admin/partials/_jquery-ui-theme.scss +0 -410
  220. data/app/assets/stylesheets/admin/partials/_jquery-ui.scss +0 -650
  221. data/app/views/admin/assets/refresh.html.haml +0 -14
@@ -2,7 +2,7 @@
2
2
  - main.edit_header do
3
3
  %h1= t('new_page')
4
4
  - main.edit_form do
5
- = form_for @page, :as => :page, :url => admin_pages_path, :html => {:id => 'new_page', :multipart => true, 'data-onsubmit_status'=>"Creating page…"} do |f|
6
- = render :partial => "fields", :object => f
5
+ = form_for @page, :as => :page, :url => admin_pages_path, :html => {:id => 'new_page', :multipart => true, 'data-onsubmit_status'=>'Creating page…'} do |f|
6
+ = render :partial => 'fields', :object => f
7
7
  - main.edit_popups do
8
- = render :partial => "popups"
8
+ = render :partial => 'popups'
@@ -1,9 +1,10 @@
1
1
  - pages = @page.children.count > 1 ? t('pages') : t('page')
2
+ - body_classes << 'reversed'
2
3
 
3
4
  %h1
4
5
  = t('remove_pages', :pages => pages)
5
6
 
6
- %p
7
+ %h4
7
8
  = t('text.pages.remove_warning', :pages => pages).html_safe
8
9
 
9
10
  .inset
@@ -12,8 +13,8 @@
12
13
  - render_nodes @page, @page.id, nil, true
13
14
  = @rendered_html.html_safe
14
15
 
15
- = form_for [:admin, @page.becomes(Page)], :html => {:method => :delete, 'data-onsubmit_status'=>"Removing pages&#8230;"} do
16
+ = form_for [:admin, @page.becomes(Page)], :html => {:method => :delete, 'data-onsubmit_status'=>'Removing pages&#8230;'} do
16
17
  .buttons
17
- %input.button{:type=>"submit", :value => t('delete_pages', :pages => pages) }/
18
+ %input.button{:type=>'submit', :value => t('delete_pages', :pages => pages) }/
18
19
  = t('or')
19
20
  = link_to t('cancel'), admin_pages_path, class: 'alt'
@@ -16,20 +16,20 @@
16
16
  - form.edit_first_name do
17
17
  %p
18
18
  = f.label :name, t("first_name")
19
- = f.text_field :first_name, :class => "textbox", :size => 32, :maxlength => 100
19
+ = f.text_field :first_name, :class => 'textbox', :size => 32, :maxlength => 100
20
20
 
21
21
  - form.edit_last_name do
22
22
  %p
23
23
  = f.label :name, t("last_name")
24
- = f.text_field :last_name, :class => "textbox", :size => 32, :maxlength => 100
24
+ = f.text_field :last_name, :class => 'textbox', :size => 32, :maxlength => 100
25
25
 
26
26
  - form.edit_email do
27
27
  %p
28
- = f.label :email, t("email_address"), :class => "optional"
29
- = f.text_field "email", :class => 'textbox', :size => 32, :maxlength => 255
28
+ = f.label :email, t("email_address"), :class => 'optional'
29
+ = f.text_field 'email', :class => 'textbox', :maxlength => 255
30
30
 
31
31
  - form.edit_password do
32
- = render "admin/users/password_fields", :f => f
32
+ = render 'admin/users/password_fields', :f => f
33
33
 
34
34
  - render_region :form_bottom, :locals => {:f => f} do |form_bottom|
35
35
  - form_bottom.edit_buttons do
@@ -3,4 +3,4 @@
3
3
  = _display_name
4
4
  Reference
5
5
  .reference=filter_reference
6
- %p.close_link=link_to_function "Close Help", "$(this).closePopup();"
6
+ %p.close_link=link_to_function 'Close Help', '$(this).closePopup();'
@@ -2,10 +2,10 @@
2
2
  .popup_title
3
3
  =t('available_tags_for', :name => _display_name)
4
4
  %p
5
- %fieldset{:id => "live-search"}
5
+ %fieldset{:id => 'live-search'}
6
6
  %label.inline{:for => "search_#{class_of_page.name.underscore}_tag_reference"} Filter Tags
7
- %input{:id => "filter", :type => "text", :name => "search_tag_reference", :value => ""}/
8
- %span{:id => "filter-count"}
7
+ %input{:id => 'filter', :type => 'text', :name => 'search_tag_reference', :value => ''}/
8
+ %span{:id => 'filter-count'}
9
9
  .reference= tag_reference.html_safe
10
10
  %p.close_link
11
11
  %a.close_tags{href:'#'}
@@ -1,8 +1,8 @@
1
- #asset-bucket{ :style => "display: none" }
2
- = render :partial => "/admin/assets/assets_container"
1
+ #asset-bucket{ :style => 'display: none' }
2
+ = render :partial => '/admin/assets/assets_container'
3
3
 
4
4
  %p.note
5
5
  = automatic_size_descriptions
6
6
  = t('clipped_extension.images_automatically_created')
7
7
  #close-link
8
- = link_to t("close"), "#"
8
+ = link_to t('close'), '#'
@@ -6,21 +6,21 @@
6
6
  - render_region :asset_tabs do |asset_tabs|
7
7
  - if @page && !@page.new_record?
8
8
  - asset_tabs.attachment_tab do
9
- %a.asset-tab{ :href => "#page-attachments", :id => "tab_page-attachments" }
10
- = t("clipped_extension.attached_assets")
9
+ %a.asset-tab{ :href => '#page-attachments', :id => 'tab_page-attachments' }
10
+ = t('clipped_extension.attached_assets')
11
11
  - asset_tabs.upload_tab do
12
- %a.asset-tab{ :href => "#upload_assets", :id => "tab_upload_assets" }
13
- = t("clipped_extension.upload")
12
+ %a.asset-tab{ :href => '#upload_assets', :id => 'tab_upload_assets' }
13
+ = t('clipped_extension.upload')
14
14
  - asset_tabs.bucket_tab do
15
- %a.asset-tab{ :href => "#bucket", :id => "tab_bucket" }
16
- = t("clipped_extension.bucket")
15
+ %a.asset-tab{ :href => '#bucket', :id => 'tab_bucket' }
16
+ = t('clipped_extension.bucket')
17
17
  - asset_tabs.search_tab do
18
- %a.asset-tab{ :href => "#search-assets" }
19
- = t("clipped_extension.search")
18
+ %a.asset-tab{ :href => '#search-assets' }
19
+ = t('clipped_extension.search')
20
20
  - else
21
21
  - asset_tabs.bucket_tab do
22
- %a.asset-tab.here{ :href => "#" }
23
- = t("clipped_extension.bucket")
22
+ %a.asset-tab.here{ :href => '#' }
23
+ = t('clipped_extension.bucket')
24
24
  - if @page && !@page.new_record?
25
25
  - render_region :asset_panes do |asset_panes|
26
26
 
@@ -28,27 +28,27 @@
28
28
  #page-attachments.pane
29
29
  %p
30
30
  %span.note
31
- != t("clipped_extension.asset_note")
31
+ != t('clipped_extension.asset_note')
32
32
  %ul#attachments
33
- = render :partial => "admin/assets/page_assets"
33
+ = render :partial => 'admin/assets/page_assets'
34
34
  .clear
35
35
 
36
36
  - asset_panes.upload do
37
37
  #upload_assets.pane
38
38
  %p
39
39
  %span.note
40
- != t("clipped_extension.asset_page_upload_note")
41
- = render :partial => "admin/assets/upload_to_page"
40
+ != t('clipped_extension.asset_page_upload_note')
41
+ = render :partial => 'admin/assets/upload_to_page'
42
42
  .clear
43
43
  - asset_panes.search do
44
44
  #search-assets.pane
45
45
  - form_tag do
46
46
  %p
47
47
  %label.note{ :for => 'search' }
48
- = t("clipped_extension.search_assets")
49
- %input{ :type => "hidden", :name => "search", :value => @page.id }
50
- %input{ :type => "search", :id => "search", :name => "search" }
51
- = submit_tag t("clipped_extension.search")
48
+ = t('clipped_extension.search_assets')
49
+ %input{ :type => 'hidden', :name => 'search', :value => @page.id }
50
+ %input{ :type => 'search', :id => 'search', :name => 'search' }
51
+ = submit_tag t('clipped_extension.search')
52
52
  #search-results
53
53
  .clear
54
54
  = observe_field 'search', :frequency => 1, :update => 'search-results', :url => admin_assets_path(:asset_page => @page), :method => 'get', :with => "'search=' + escape(value)"
@@ -5,7 +5,7 @@
5
5
  - else
6
6
  %li
7
7
  %p.note
8
- = t("clipped_extension.empty_bucket")
8
+ = t('clipped_extension.empty_bucket')
9
9
 
10
10
 
11
11
 
@@ -1,9 +1,9 @@
1
1
  %li
2
2
 
3
3
  %div{ :class => "#{asset_type} asset", :id => "bucket_#{asset_id}" }
4
- = link_to image_tag(asset_thumbnail), asset_url, :title => asset_title, :class => "bucket_link"
4
+ = link_to image_tag(asset_thumbnail), asset_url, :title => asset_title, :class => 'bucket_link'
5
5
 
6
6
  .info{ :id => "#{asset_id}_info" }
7
- = link_to image('assets/edit'), edit_admin_asset_url(asset_id), :class => "edit_asset", :title => t("clipped_extension.edit_asset", :asset => asset_title)
7
+ = link_to image('assets/edit'), edit_admin_asset_url(asset_id), :class => 'edit_asset', :title => t('clipped_extension.edit_asset', :asset => asset_title)
8
8
  - if page && !page.new_record?
9
- = link_to image('assets/add'), attach_page_asset_url(:asset => asset_id, :page => page.id), :class => "add_asset", :title => t("clipped_extension.attach_to_page")
9
+ = link_to image('assets/add'), attach_page_asset_url(:asset => asset_id, :page => page.id), :class => 'add_asset', :title => t('clipped_extension.attach_to_page')
@@ -1,4 +1,4 @@
1
1
  - unless @page.nil? || @page.new_record?
2
2
  %span#show-bucket
3
3
  = t('clipped_extension.bucket')
4
- = link_to t("clipped_extension.show_assets_bucket"), "#"
4
+ = link_to t('clipped_extension.show_assets_bucket'), '#'
@@ -1,12 +1,12 @@
1
1
  #upload-form
2
- - form_for :asset, :url => admin_assets_path(:page => @page, :format => 'js'), :html => { :id => 'asset-upload', :method => "post", :multipart => true, :target => 'ulframe' } do |form|
2
+ - form_for :asset, :url => admin_assets_path(:page => @page, :format => 'js'), :html => { :id => 'asset-upload', :method => 'post', :multipart => true, :target => 'ulframe' } do |form|
3
3
  %div.file
4
4
  %label.upload
5
- = t("clipped_extension.choose_upload")
6
- = form.file_field :asset, :class => "", :style => "width: 100%"
5
+ = t('clipped_extension.choose_upload')
6
+ = form.file_field :asset, :class => '', :style => 'width: 100%'
7
7
 
8
8
  .upload-buttons
9
- = form.submit t("clipped_extension.save_and_upload"), :class => "button"
9
+ = form.submit t('clipped_extension.save_and_upload'), :class => 'button'
10
10
  %div.spinner
11
11
 
12
- %iframe{:id => 'ulframe', :name => "ulframe", :src => "about:blank"}
12
+ %iframe{:id => 'ulframe', :name => 'ulframe', :src => 'about:blank'}
@@ -4,35 +4,35 @@
4
4
 
5
5
  - form.edit_name do
6
6
  %fieldset.title
7
- %h1
8
- %i.fa.fa-sitemap
7
+ %h4
8
+ %i.fas.fa-sitemap
9
9
  Site Information
10
- %label{:for => "site_name"} Site title
11
- = f.text_field :name, :class => "textbox", :size => 50
10
+ %label{:for => 'site_name'} Site title
11
+ = f.text_field :name, :class => 'textbox', :size => 50
12
12
  %br
13
- %label{:for => "site_subtitle"} and subtitle
14
- = f.text_field :subtitle, :class => "textbox"
13
+ %label{:for => 'site_subtitle'} and subtitle
14
+ = f.text_field :subtitle, :class => 'textbox'
15
15
 
16
16
  - form.edit_domain do
17
17
  %fieldset.domain
18
- %h1
19
- %i.fa.fa-lightbulb-o
18
+ %h4
19
+ %i.fas.fa-lightbulb
20
20
  Domain Information
21
- %label{:for => "site_domain"}
21
+ %label{:for => 'site_domain'}
22
22
  Domain pattern
23
- = f.text_field :domain, :class => "textbox", :size => 50
23
+ = f.text_field :domain, :class => 'textbox', :size => 50
24
24
  %br
25
- %label{:for => "site_base_domain"}
25
+ %label{:for => 'site_base_domain'}
26
26
  Base domain name
27
- = f.text_field :base_domain, :class => "textbox", :size => 50
27
+ = f.text_field :base_domain, :class => 'textbox', :size => 50
28
28
 
29
29
  - form.edit_homepage do
30
30
  %fieldset.homepage
31
- %h1
32
- %i.fa.fa-home
31
+ %h4
32
+ %i.fas.fa-home
33
33
  Homepage ID
34
- %label{:for => "site_homepage_id"} Homepage ID
35
- = f.text_field :homepage_id, :class => "textbox"
34
+ %label{:for => 'site_homepage_id'} Homepage ID
35
+ = f.text_field :homepage_id, :class => 'textbox'
36
36
 
37
37
  %p.formnote
38
38
  - if f.object.new_record?
@@ -44,7 +44,7 @@
44
44
  - form_bottom.edit_timestamp do
45
45
  = updated_stamp @site
46
46
  - form_bottom.edit_buttons do
47
- %p.buttons
47
+ .buttons
48
48
  = save_model_button(@site)
49
49
  or
50
- = link_to "cancel", admin_sites_path
50
+ = link_to 'cancel', admin_sites_path
@@ -3,4 +3,4 @@
3
3
  %h1 Edit Site
4
4
  - main.edit_form do
5
5
  = form_for @site, :url => admin_site_path(@site), :html => {:method => :put} do |f|
6
- = render :partial => "form", :locals => {:f => f}
6
+ = render :partial => 'form', :locals => {:f => f}
@@ -2,7 +2,7 @@
2
2
 
3
3
  %h1 Sites
4
4
 
5
- %table{:class => "index", :cellspacing => "0"}
5
+ %table.index.tablesaw
6
6
  %thead
7
7
  %tr
8
8
  - render_region :thead do |thead|
@@ -31,12 +31,16 @@
31
31
  = h(site.base_domain)
32
32
  - tbody.modify_cell do
33
33
  %td.remove
34
- = link_to image("remove.png", :alt => "Remove"), admin_site_path(site), :method => :delete, :onclick => "return confirm('Are you sure you want to permanently remove #{site.name}?')"
34
+ = link_to admin_site_path(site), :method => :delete, :onclick => "return confirm('Are you sure you want to permanently remove #{site.name}?')" do
35
+ %i.fas.fa-minus-circle
36
+ = t('remove')
35
37
  - tbody.order_cell do
36
38
  %td.order
37
39
  = order_links(site).html_safe
38
40
 
39
41
  - render_region :bottom do |bottom|
40
42
  - bottom.new_button do
41
- %p
42
- = link_to "New Site", new_admin_site_path
43
+ .page-actions
44
+ = link_to new_admin_site_path, class: 'action_button' do
45
+ %i.fas.fa-plus-circle
46
+ New Site
@@ -3,4 +3,4 @@
3
3
  %h1 New Site
4
4
  - main.edit_form do
5
5
  = form_for @site, :url => admin_sites_path do |f|
6
- = render :partial => "form", :locals => {:f => f}
6
+ = render :partial => 'form', :locals => {:f => f}
@@ -1,6 +1,5 @@
1
1
  - unless current_user.site
2
- %p{:style => 'float: left; margin-right: 32px'}
3
- %label{:for=>"snippet_site_id", :Class => "admin_only"}
4
- Site
5
- - sites = Site.all.map { |s| [s.name, s.id] }
6
- = select :snippet, :site_id, sites, :include_blank => Snippet.is_shareable?, :selected => @snippet.site_id || current_site.id
2
+ %label{:for=>'snippet_site_id', :Class => 'admin_only'}
3
+ Site
4
+ - sites = Site.all.map { |s| [s.name, s.id] }
5
+ = select :snippet, :site_id, sites, :include_blank => Snippet.is_shareable?, :selected => @snippet.site_id || current_site.id
@@ -4,23 +4,22 @@
4
4
  .form_area
5
5
  - render_region :form, :locals => {:f => f} do |form|
6
6
  - form.edit_title do
7
- %p.title
7
+ .title
8
8
  = f.label :name, t('name')
9
9
  = f.text_field :name, :class => 'textbox activate', :maxlength => 100
10
10
  - form.edit_content do
11
- %p.content
11
+ .textarea_content
12
12
  = f.label :content, t('body')
13
- ~ f.text_area :content, :class => "textarea large", :style => "width: 100%"
13
+ ~ f.text_area :content
14
14
  - form.edit_filter do
15
15
  .set
16
- %p
17
- %span.reference_links
18
- == #{t('reference')}:
19
- %span{:id => "tag_reference_link"}
20
- = link_to t('available_tags'), admin_reference_url(:tags), id: 'tag_reference'
16
+ %span.reference_links
17
+ == #{t('reference')}:
18
+ %span{:id => 'tag_reference_link'}
19
+ = link_to t('available_tags'), admin_reference_url(:tags), id: 'tag_reference'
21
20
  - render_region :form_bottom, :locals => {:f => f} do |form_bottom|
22
21
  - form_bottom.edit_buttons do
23
- .buttons{:style=>"clear: left"}
22
+ .buttons{:style=>'clear: left'}
24
23
  = save_model_button(@snippet)
25
24
  = save_model_and_continue_editing_button(@snippet)
26
25
  = t('or')
@@ -6,6 +6,6 @@
6
6
  - main.edit_form do
7
7
  = render :partial => 'form'
8
8
  - main.edit_popups do
9
- = render :partial => "popups"
9
+ = render :partial => 'popups'
10
10
 
11
11
  - content_for 'page_scripts'
@@ -9,7 +9,7 @@
9
9
  - thead.title_header do
10
10
  %th.name= t('snippet')
11
11
  - thead.actions_header do
12
- %th.actions{:style=>"width:9em"}= t('modify')
12
+ %th.actions{:style=>'width:9em'}= t('modify')
13
13
  %tbody
14
14
  - if @snippets.any?
15
15
  - @snippets.each do |snippet|
@@ -17,10 +17,14 @@
17
17
  - render_region :tbody, :locals => {:snippet => snippet} do |tbody|
18
18
  - tbody.title_cell do
19
19
  %td.name
20
- = link_to image('snippet', :alt => '') + ' ' + snippet.name, edit_admin_snippet_url(snippet)
20
+ = link_to edit_admin_snippet_url(snippet) do
21
+ %i.far.fa-sticky-note
22
+ = snippet.name
21
23
  - tbody.actions_cell do
22
24
  %td.actions
23
- = link_to image('minus') + ' ' + t('remove'), remove_admin_snippet_url(snippet), :class => "action"
25
+ = link_to remove_admin_snippet_url(snippet), :class => 'action' do
26
+ %i.fas.fa-minus-circle
27
+ = t('remove')
24
28
  - else
25
29
  %tr
26
30
  %td.empty{:colspan => admin.snippet.index.tbody.length}= t('no_snippets')
@@ -30,4 +34,7 @@
30
34
  #actions
31
35
  = pagination_for(@snippets)
32
36
  %ul
33
- %li= link_to image('plus') + " " + t('new_snippet'), new_admin_snippet_url, :class => 'action_button'
37
+ %li
38
+ = link_to new_admin_snippet_url, class: 'action_button' do
39
+ %i.fas.fa-plus-circle
40
+ =t('new_snippet')
@@ -4,6 +4,6 @@
4
4
  - main.edit_form do
5
5
  = render :partial => 'form'
6
6
  - main.edit_popups do
7
- = render :partial => "popups"
7
+ = render :partial => 'popups'
8
8
 
9
9
  - content_for 'page_scripts'
@@ -1,17 +1,18 @@
1
+ - body_classes << 'reversed'
2
+
1
3
  %h1= t('remove_snippet')
2
4
 
3
- %p
4
- = t('text.snippets.remove_warning')
5
+ %h4
6
+ = t('text.snippets.remove_warning').html_safe
5
7
 
6
- %table.index#snippets
8
+ %table.tablesaw.index#snippets
7
9
  %tbody
8
10
  %tr.node.level_1
9
11
  %td.snippet
10
- = image('snippet', :alt => "")
11
12
  %span.title= @snippet.name
12
13
 
13
- = form_for [:admin, @snippet], :html => {:method => :delete, 'data-onsubmit_status'=>"Removing snippet&#8230;"} do
14
+ = form_for [:admin, @snippet], :html => {:method => :delete, 'data-onsubmit_status'=>'Removing snippet&#8230;'} do
14
15
  .buttons
15
- %input.button{:type=>"submit", :value => t('delete_snippet')}/
16
+ %input.button{:type=>'submit', :value => t('delete_snippet')}/
16
17
  = t('or')
17
18
  = link_to t('cancel'), admin_snippets_url
@@ -1,5 +1,5 @@
1
1
  #avatar
2
- = image_tag(gravatar_url(@user.email, :size=>"96px"), :class=>"avatar", :width=>96, :height=>96, :alt=>"")
2
+ = image_tag(gravatar_url(@user.email, :size=>'96px'), :class=>'avatar', :width=>96, :height=>96, :alt=>'')
3
3
  %p.caption
4
4
  Avatar provided by
5
- = link_to "gravatar.com", 'http://gravatar.com/site/signup/'
5
+ = link_to 'gravatar.com', 'http://gravatar.com/site/signup/'