trusty-cms 4.0.1 → 4.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +3 -3
- data/Gemfile.lock +106 -106
- data/Rakefile +7 -7
- data/app/assets/images/admin/spinner.gif +0 -0
- data/app/assets/javascripts/admin.js +3 -0
- data/app/assets/javascripts/admin/more-or-less.js +2 -2
- data/app/assets/javascripts/admin/tabcontrol.js.erb +1 -2
- data/app/assets/stylesheets/admin/_base.scss +22 -6
- data/app/assets/stylesheets/admin/_multi_site_main.scss +28 -29
- data/app/assets/stylesheets/admin/_reset.scss +5 -4
- data/app/assets/stylesheets/admin/_site_chooser.scss +44 -69
- data/app/assets/stylesheets/admin/assets.scss +138 -141
- data/app/assets/stylesheets/admin/main.scss +10 -12
- data/app/assets/stylesheets/admin/modules/_boxes.scss +0 -3
- data/app/assets/stylesheets/admin/modules/_buttons.scss +30 -0
- data/app/assets/stylesheets/admin/modules/_links.scss +1 -1
- data/app/assets/stylesheets/admin/partials/_actions.scss +29 -46
- data/app/assets/stylesheets/admin/partials/_avatars.scss +3 -2
- data/app/assets/stylesheets/admin/partials/_content.scss +15 -38
- data/app/assets/stylesheets/admin/partials/_dateinput.scss +23 -14
- data/app/assets/stylesheets/admin/partials/_drawer.scss +78 -0
- data/app/assets/stylesheets/admin/partials/_dropdown.scss +9 -12
- data/app/assets/stylesheets/admin/partials/_footer.scss +4 -3
- data/app/assets/stylesheets/admin/partials/_forms.scss +64 -491
- data/app/assets/stylesheets/admin/partials/_header.scss +9 -118
- data/app/assets/stylesheets/admin/partials/_layout.scss +26 -2
- data/app/assets/stylesheets/admin/partials/_login_form.scss +28 -0
- data/app/assets/stylesheets/admin/partials/_messages.scss +10 -5
- data/app/assets/stylesheets/admin/partials/_popup.scss +61 -50
- data/app/assets/stylesheets/admin/partials/_preferences.scss +37 -0
- data/app/assets/stylesheets/admin/partials/_sidebar.scss +55 -0
- data/app/assets/stylesheets/admin/partials/_tabcontrol.scss +24 -36
- data/app/assets/stylesheets/admin/partials/{_index.scss → _table.scss} +53 -84
- data/app/assets/stylesheets/admin/partials/_toolbar.scss +11 -6
- data/app/assets/stylesheets/admin/partials/_treetable.scss +1 -71
- data/app/assets/stylesheets/admin/partials/_typography.scss +30 -55
- data/app/assets/stylesheets/admin/partials/_validations.scss +6 -5
- data/app/assets/stylesheets/rad_social/rad_screen.scss +65 -64
- data/app/controllers/admin/assets_controller.rb +21 -31
- data/app/controllers/admin/configuration_controller.rb +9 -11
- data/app/controllers/admin/extensions_controller.rb +3 -3
- data/app/controllers/admin/layouts_controller.rb +3 -4
- data/app/controllers/admin/page_attachments_controller.rb +5 -5
- data/app/controllers/admin/page_fields_controller.rb +3 -4
- data/app/controllers/admin/page_parts_controller.rb +4 -5
- data/app/controllers/admin/pages_controller.rb +55 -56
- data/app/controllers/admin/references_controller.rb +1 -1
- data/app/controllers/admin/resource_controller.rb +132 -128
- data/app/controllers/admin/sites_controller.rb +4 -4
- data/app/controllers/admin/snippets_controller.rb +3 -4
- data/app/controllers/admin/users_controller.rb +16 -16
- data/app/controllers/application_controller.rb +47 -48
- data/app/controllers/site_controller.rb +51 -48
- data/app/controllers/social_mailer_controller.rb +13 -16
- data/app/helpers/admin/configuration_helper.rb +19 -20
- data/app/helpers/admin/layouts_helper.rb +0 -1
- data/app/helpers/admin/node_helper.rb +27 -24
- data/app/helpers/admin/pages_helper.rb +2 -2
- data/app/helpers/admin/preferences_helper.rb +0 -1
- data/app/helpers/admin/references_helper.rb +9 -10
- data/app/helpers/admin/regions_helper.rb +3 -3
- data/app/helpers/application_helper.rb +34 -35
- data/app/helpers/rad_social_helper.rb +8 -11
- data/app/helpers/scoped_helper.rb +1 -3
- data/app/helpers/sites_helper.rb +4 -4
- data/app/mailers/devise_mailer.rb +3 -4
- data/app/mailers/rad_social_mailer.rb +8 -8
- data/app/models/asset.rb +62 -63
- data/app/models/asset_type.rb +38 -39
- data/app/models/deprecated_tags.rb +3 -4
- data/app/models/file_not_found_page.rb +1 -3
- data/app/models/haml_filter.rb +1 -1
- data/app/models/layout.rb +4 -5
- data/app/models/legacy_user.rb +2 -2
- data/app/models/menu_renderer.rb +16 -18
- data/app/models/page.rb +96 -93
- data/app/models/page_attachment.rb +1 -2
- data/app/models/page_context.rb +11 -12
- data/app/models/page_part.rb +3 -4
- data/app/models/rails_page.rb +10 -12
- data/app/models/site.rb +22 -21
- data/app/models/snippet.rb +6 -8
- data/app/models/snippet_finder.rb +3 -3
- data/app/models/snippet_tags.rb +4 -4
- data/app/models/standard_tags.rb +258 -252
- data/app/models/status.rb +8 -8
- data/app/models/trusty_cms/config.rb +25 -25
- data/app/models/trusty_cms/page_response_cache_director.rb +2 -3
- data/app/models/user.rb +15 -14
- data/app/models/user_action_observer.rb +3 -3
- data/app/users/_choose_site.html.haml +3 -7
- data/app/views/admin/assets/_form.html.haml +2 -1
- data/app/views/admin/assets/_search.html.haml +2 -1
- data/app/views/admin/assets/edit.html.haml +2 -10
- data/app/views/admin/assets/index.html.haml +4 -2
- data/app/views/admin/assets/new.html.haml +4 -8
- data/app/views/admin/assets/remove.html.haml +2 -1
- data/app/views/admin/configuration/edit.html.haml +7 -7
- data/app/views/admin/configuration/show.html.haml +6 -8
- data/app/views/admin/layouts/_choose_site.html.haml +2 -3
- data/app/views/admin/layouts/_form.html.haml +13 -12
- data/app/views/admin/layouts/_site_chooser.html.haml +2 -2
- data/app/views/admin/layouts/index.html.haml +11 -4
- data/app/views/admin/layouts/remove.html.haml +6 -5
- data/app/views/admin/page_attachments/_attachment.html.haml +2 -2
- data/app/views/admin/page_fields/_page_field.html.haml +3 -3
- data/app/views/admin/page_parts/_page_part.html.haml +5 -6
- data/app/views/admin/pages/_asset_popups.html.haml +15 -16
- data/app/views/admin/pages/_assets.html.haml +8 -7
- data/app/views/admin/pages/_fields.html.haml +16 -13
- data/app/views/admin/pages/_node.html.haml +3 -3
- data/app/views/admin/pages/_popups.html.haml +11 -11
- data/app/views/admin/pages/edit.html.haml +2 -2
- data/app/views/admin/pages/index.html.haml +5 -2
- data/app/views/admin/pages/new.html.haml +3 -3
- data/app/views/admin/pages/remove.html.haml +4 -3
- data/app/views/admin/preferences/edit.html.haml +5 -5
- data/app/views/admin/references/filters.haml +1 -1
- data/app/views/admin/references/tags.haml +3 -3
- data/app/views/admin/removed/_assets_bucket.html.haml +3 -3
- data/app/views/admin/removed/_assets_container.html.haml +18 -18
- data/app/views/admin/removed/_bucket.html.haml +1 -1
- data/app/views/admin/removed/_bucket_asset.html.haml +3 -3
- data/app/views/admin/removed/_show_bucket_link.html.haml +1 -1
- data/app/views/admin/removed/_upload_to_page.html.haml +5 -5
- data/app/views/admin/sites/_form.haml +18 -18
- data/app/views/admin/sites/edit.haml +1 -1
- data/app/views/admin/sites/index.haml +8 -4
- data/app/views/admin/sites/new.haml +1 -1
- data/app/views/admin/snippets/_choose_site.html.haml +4 -5
- data/app/views/admin/snippets/_form.html.haml +8 -9
- data/app/views/admin/snippets/edit.html.haml +1 -1
- data/app/views/admin/snippets/index.html.haml +11 -4
- data/app/views/admin/snippets/new.html.haml +1 -1
- data/app/views/admin/snippets/remove.html.haml +7 -6
- data/app/views/admin/users/_avatar.html.haml +2 -2
- data/app/views/admin/users/_choose_site.html.haml +3 -7
- data/app/views/admin/users/_form.html.haml +18 -21
- data/app/views/admin/users/_password_fields.html.haml +6 -6
- data/app/views/admin/users/index.html.haml +13 -6
- data/app/views/admin/users/remove.html.haml +4 -4
- data/app/views/admin/welcome/login.html.haml +8 -8
- data/app/views/devise/passwords/edit.html.haml +6 -6
- data/app/views/devise/passwords/new.html.haml +3 -3
- data/app/views/devise/sessions/new.html.haml +8 -8
- data/app/views/devise/shared/_links.html.haml +2 -2
- data/app/views/layouts/application.html.haml +24 -19
- data/app/views/rad_social_mailer/social_mail_form.html.haml +15 -15
- data/app/views/widget/_email_form.html.haml +14 -14
- data/app/views/widget/_horizontal_widget.html.haml +5 -5
- data/bin/rails +4 -4
- data/bin/trusty_cms +3 -5
- data/config.ru +1 -1
- data/config/application.rb +14 -15
- data/config/boot.rb +1 -2
- data/config/environment.rb +1 -1
- data/config/environments/production.rb +0 -1
- data/config/environments/test.rb +1 -2
- data/config/initializers/devise.rb +1 -1
- data/config/initializers/kraken.rb +2 -2
- data/config/initializers/tmp.rb +1 -1
- data/config/initializers/trusty_cms_config.rb +48 -48
- data/config/locales/en.yml +8 -8
- data/config/routes.rb +6 -7
- data/lib/active_record_extensions/active_record_extensions.rb +1 -2
- data/lib/annotatable.rb +3 -5
- data/lib/configuration_extensions/configuration_extensions.rb +1 -1
- data/lib/inheritable_class_attributes.rb +13 -9
- data/lib/login_system.rb +73 -73
- data/lib/method_observer.rb +13 -12
- data/lib/ostruct.rb +7 -10
- data/lib/simpleton.rb +0 -4
- data/lib/string_extensions/string_extensions.rb +3 -3
- data/lib/symbol_extensions/symbol_extensions.rb +1 -1
- data/lib/tasks/database.rake +28 -28
- data/lib/tasks/extensions.rake +18 -18
- data/lib/tasks/framework.rake +68 -68
- data/lib/tasks/radiant_config.rake +4 -4
- data/lib/tasks/snippets_extension_tasks.rake +11 -11
- data/lib/tasks/translate.rake +14 -14
- data/lib/tasks/upgrade_to_devise.rake +1 -1
- data/lib/translation_support.rb +22 -22
- data/lib/trusty_cms.rb +2 -2
- data/lib/trusty_cms/admin_ui.rb +19 -16
- data/lib/trusty_cms/admin_ui/region_partials.rb +4 -3
- data/lib/trusty_cms/admin_ui/region_set.rb +4 -5
- data/lib/trusty_cms/available_locales.rb +2 -4
- data/lib/trusty_cms/config/definition.rb +11 -8
- data/lib/trusty_cms/engine.rb +14 -14
- data/lib/trusty_cms/extension.rb +14 -16
- data/lib/trusty_cms/extension_loader.rb +6 -6
- data/lib/trusty_cms/extension_migrator.rb +42 -41
- data/lib/trusty_cms/extension_path.rb +20 -19
- data/lib/trusty_cms/initializer.rb +5 -8
- data/lib/trusty_cms/pagination/controller.rb +7 -10
- data/lib/trusty_cms/pagination/link_renderer.rb +2 -2
- data/lib/trusty_cms/resource_responses.rb +3 -3
- data/lib/trusty_cms/setup.rb +130 -132
- data/lib/trusty_cms/taggable.rb +19 -22
- data/lib/trusty_cms/task_support.rb +9 -6
- data/package.json +10 -2
- data/public/dispatch.fcgi +1 -1
- data/public/dispatch.rb +2 -2
- data/script/extension +1 -1
- data/script/rails +2 -2
- data/spec/dummy/package.json +1 -1
- data/spec/dummy/yarn.lock +3 -3
- data/trusty_cms.gemspec +25 -25
- data/vendor/extensions/clipped-extension/lib/clipped_admin_ui.rb +1 -1
- data/yarn.lock +1992 -4
- metadata +54 -42
- data/app/assets/stylesheets/admin/partials/_deprecated.scss +0 -65
- data/app/assets/stylesheets/admin/partials/_jquery-ui-structure.scss +0 -258
- data/app/assets/stylesheets/admin/partials/_jquery-ui-theme.scss +0 -410
- data/app/assets/stylesheets/admin/partials/_jquery-ui.scss +0 -650
- 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'=>
|
6
|
-
= render :partial =>
|
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 =>
|
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
|
-
%
|
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'=>
|
16
|
+
= form_for [:admin, @page.becomes(Page)], :html => {:method => :delete, 'data-onsubmit_status'=>'Removing pages…'} do
|
16
17
|
.buttons
|
17
|
-
%input.button{:type=>
|
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 =>
|
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 =>
|
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 =>
|
29
|
-
= f.text_field
|
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
|
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
|
@@ -2,10 +2,10 @@
|
|
2
2
|
.popup_title
|
3
3
|
=t('available_tags_for', :name => _display_name)
|
4
4
|
%p
|
5
|
-
%fieldset{:id =>
|
5
|
+
%fieldset{:id => 'live-search'}
|
6
6
|
%label.inline{:for => "search_#{class_of_page.name.underscore}_tag_reference"} Filter Tags
|
7
|
-
%input{:id =>
|
8
|
-
%span{:id =>
|
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 =>
|
2
|
-
= render :partial =>
|
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(
|
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 =>
|
10
|
-
= t(
|
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 =>
|
13
|
-
= t(
|
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 =>
|
16
|
-
= t(
|
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 =>
|
19
|
-
= t(
|
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(
|
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(
|
31
|
+
!= t('clipped_extension.asset_note')
|
32
32
|
%ul#attachments
|
33
|
-
= render :partial =>
|
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(
|
41
|
-
= render :partial =>
|
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(
|
49
|
-
%input{ :type =>
|
50
|
-
%input{ :type =>
|
51
|
-
= submit_tag t(
|
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)"
|
@@ -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 =>
|
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 =>
|
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 =>
|
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,12 +1,12 @@
|
|
1
1
|
#upload-form
|
2
|
-
- form_for :asset, :url => admin_assets_path(:page => @page, :format => 'js'), :html => { :id => 'asset-upload', :method =>
|
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(
|
6
|
-
= form.file_field :asset, :class =>
|
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(
|
9
|
+
= form.submit t('clipped_extension.save_and_upload'), :class => 'button'
|
10
10
|
%div.spinner
|
11
11
|
|
12
|
-
%iframe{:id => 'ulframe', :name =>
|
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
|
-
%
|
8
|
-
%i.
|
7
|
+
%h4
|
8
|
+
%i.fas.fa-sitemap
|
9
9
|
Site Information
|
10
|
-
%label{:for =>
|
11
|
-
= f.text_field :name, :class =>
|
10
|
+
%label{:for => 'site_name'} Site title
|
11
|
+
= f.text_field :name, :class => 'textbox', :size => 50
|
12
12
|
%br
|
13
|
-
%label{:for =>
|
14
|
-
= f.text_field :subtitle, :class =>
|
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
|
-
%
|
19
|
-
%i.
|
18
|
+
%h4
|
19
|
+
%i.fas.fa-lightbulb
|
20
20
|
Domain Information
|
21
|
-
%label{:for =>
|
21
|
+
%label{:for => 'site_domain'}
|
22
22
|
Domain pattern
|
23
|
-
= f.text_field :domain, :class =>
|
23
|
+
= f.text_field :domain, :class => 'textbox', :size => 50
|
24
24
|
%br
|
25
|
-
%label{:for =>
|
25
|
+
%label{:for => 'site_base_domain'}
|
26
26
|
Base domain name
|
27
|
-
= f.text_field :base_domain, :class =>
|
27
|
+
= f.text_field :base_domain, :class => 'textbox', :size => 50
|
28
28
|
|
29
29
|
- form.edit_homepage do
|
30
30
|
%fieldset.homepage
|
31
|
-
%
|
32
|
-
%i.
|
31
|
+
%h4
|
32
|
+
%i.fas.fa-home
|
33
33
|
Homepage ID
|
34
|
-
%label{:for =>
|
35
|
-
= f.text_field :homepage_id, :class =>
|
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
|
-
|
47
|
+
.buttons
|
48
48
|
= save_model_button(@site)
|
49
49
|
or
|
50
|
-
= link_to
|
50
|
+
= link_to 'cancel', admin_sites_path
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
%h1 Sites
|
4
4
|
|
5
|
-
%table
|
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
|
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
|
-
|
42
|
-
= link_to
|
43
|
+
.page-actions
|
44
|
+
= link_to new_admin_site_path, class: 'action_button' do
|
45
|
+
%i.fas.fa-plus-circle
|
46
|
+
New Site
|
@@ -1,6 +1,5 @@
|
|
1
1
|
- unless current_user.site
|
2
|
-
%
|
3
|
-
|
4
|
-
|
5
|
-
|
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
|
-
|
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
|
-
|
11
|
+
.textarea_content
|
12
12
|
= f.label :content, t('body')
|
13
|
-
~ f.text_area :content
|
13
|
+
~ f.text_area :content
|
14
14
|
- form.edit_filter do
|
15
15
|
.set
|
16
|
-
%
|
17
|
-
|
18
|
-
|
19
|
-
|
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=>
|
22
|
+
.buttons{:style=>'clear: left'}
|
24
23
|
= save_model_button(@snippet)
|
25
24
|
= save_model_and_continue_editing_button(@snippet)
|
26
25
|
= t('or')
|
@@ -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=>
|
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
|
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
|
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
|
37
|
+
%li
|
38
|
+
= link_to new_admin_snippet_url, class: 'action_button' do
|
39
|
+
%i.fas.fa-plus-circle
|
40
|
+
=t('new_snippet')
|
@@ -1,17 +1,18 @@
|
|
1
|
+
- body_classes << 'reversed'
|
2
|
+
|
1
3
|
%h1= t('remove_snippet')
|
2
4
|
|
3
|
-
%
|
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'=>
|
14
|
+
= form_for [:admin, @snippet], :html => {:method => :delete, 'data-onsubmit_status'=>'Removing snippet…'} do
|
14
15
|
.buttons
|
15
|
-
%input.button{:type=>
|
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=>
|
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
|
5
|
+
= link_to 'gravatar.com', 'http://gravatar.com/site/signup/'
|