2011-02-27 11:18:48 +00:00
|
|
|
- title t('.title')
|
|
|
|
|
2011-12-07 01:09:13 +00:00
|
|
|
- content_for :head do
|
|
|
|
= render 'asset'
|
|
|
|
|
|
|
|
= render 'list', :name => 'images', :title => t('.images'), :empty_message => t('.no_items', :url => new_theme_asset_url)
|
|
|
|
= render 'list', :name => 'media', :title => t('.media'), :empty_message => t('.no_items', :url => new_theme_asset_url)
|
|
|
|
|
|
|
|
- if can?(:manage, Locomotive::Snippet)
|
|
|
|
= render '/locomotive/snippets/snippet'
|
|
|
|
= render 'list', :name => 'snippets', :title => t('.snippets'), :empty_message => t('locomotive.snippets.index.no_items', :url => new_snippet_url)
|
|
|
|
|
|
|
|
- if can?(:manage, Locomotive::ThemeAsset)
|
|
|
|
= render 'list', :name => 'js_and_css', :title => t('.css_and_js'), :empty_message => t('.no_items', :url => new_theme_asset_url)
|
|
|
|
= render 'list', :name => 'fonts', :title => t('.fonts'), :empty_message => t('.no_items', :url => new_theme_asset_url)
|
|
|
|
|
2011-12-06 11:39:32 +00:00
|
|
|
- content_for :backbone_view_data do
|
|
|
|
:plain
|
2011-12-07 01:09:13 +00:00
|
|
|
{
|
|
|
|
snippets: #{can?(:manage, Locomotive::Snippet) ? @snippets.to_json : 'null'},
|
|
|
|
images: #{@assets[:images].to_json},
|
|
|
|
media: #{@assets[:media].to_json},
|
|
|
|
js_and_css_assets: #{can?(:manage, Locomotive::ThemeAsset) ? @js_and_css_assets.to_json : 'null'},
|
|
|
|
fonts: #{can?(:manage, Locomotive::ThemeAsset) ? @assets[:fonts].to_json : 'null'}
|
|
|
|
}
|
2011-12-06 11:39:32 +00:00
|
|
|
|
2011-02-27 11:18:48 +00:00
|
|
|
- content_for :submenu do
|
2011-11-08 00:11:15 +00:00
|
|
|
= render_cell 'locomotive/settings_menu', :show
|
2011-02-27 11:18:48 +00:00
|
|
|
|
|
|
|
- content_for :buttons do
|
2011-12-07 01:09:13 +00:00
|
|
|
- if can?(:manage, Locomotive::ThemeAsset)
|
2011-12-07 11:25:30 +00:00
|
|
|
= form_tag theme_assets_url(:json), :id => 'theme-assets-quick-upload', :class => 'quick-upload' do
|
|
|
|
= file_field_tag 'theme_asset[source]', :multiple => 'multiple'
|
|
|
|
= local_action_button :quick_upload, '#', :class => 'new'
|
|
|
|
|
2011-11-08 14:34:25 +00:00
|
|
|
= local_action_button t('locomotive.snippets.index.new'), new_snippet_url, :class => 'new' if can?(:manage, Locomotive::Snippet)
|
|
|
|
= local_action_button :new, new_theme_asset_url, :class => 'new' if can?(:manage, Locomotive::ThemeAsset)
|
2011-02-27 11:18:48 +00:00
|
|
|
|
|
|
|
%p!= t('.help')
|
|
|
|
|
2011-11-08 14:34:25 +00:00
|
|
|
- if can?(:manage, Locomotive::Snippet)
|
2011-12-06 11:39:32 +00:00
|
|
|
#snippets-anchor
|
|
|
|
|
2011-11-08 14:34:25 +00:00
|
|
|
- if can?(:manage, Locomotive::ThemeAsset)
|
2011-12-07 01:09:13 +00:00
|
|
|
#js-and-css-anchor
|
2011-12-03 00:11:31 +00:00
|
|
|
|
2011-12-07 01:09:13 +00:00
|
|
|
#images-anchor
|
2011-02-27 11:18:48 +00:00
|
|
|
|
2011-11-08 14:34:25 +00:00
|
|
|
- if can?(:manage, Locomotive::ThemeAsset)
|
2011-12-07 01:09:13 +00:00
|
|
|
#fonts-anchor
|
2011-02-27 11:18:48 +00:00
|
|
|
|
2011-12-07 01:09:13 +00:00
|
|
|
#media-anchor
|