2010-05-11 21:38:52 +00:00
|
|
|
- content_for :head do
|
2011-12-07 01:09:13 +00:00
|
|
|
= render '/locomotive/theme_assets/picker'
|
|
|
|
|
|
|
|
- content_for :backbone_view_data do
|
|
|
|
:plain
|
|
|
|
{ theme_asset: #{@theme_asset.persisted? ? @theme_asset.to_json : 'null'} }
|
2010-05-11 21:38:52 +00:00
|
|
|
|
|
|
|
= f.hidden_field :performing_plain_text
|
|
|
|
|
2011-01-29 16:24:37 +00:00
|
|
|
#file-selector{ :class => "selector #{'hidden' if display_plain_text?(@theme_asset)}" }
|
2010-05-11 21:38:52 +00:00
|
|
|
= f.inputs :name => :information do
|
|
|
|
= f.input :source
|
|
|
|
|
2011-01-29 16:24:37 +00:00
|
|
|
- if allow_plain_text_editing?(@theme_asset)
|
2011-12-07 01:09:13 +00:00
|
|
|
= link_to t('locomotive.theme_assets.form.choose_plain_text'), '#', :class => 'alt'
|
2010-05-11 21:38:52 +00:00
|
|
|
|
2010-07-13 00:46:17 +00:00
|
|
|
- if allow_plain_text_editing?(@theme_asset)
|
2011-01-29 16:24:37 +00:00
|
|
|
#text-selector{ :class => "selector #{'hidden' unless display_plain_text?(@theme_asset)}", :style => "#{'display: none' unless display_plain_text?(@theme_asset)}" }
|
2010-05-11 21:38:52 +00:00
|
|
|
= f.inputs :name => :code, :class => 'inputs code' do
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2010-07-13 00:46:17 +00:00
|
|
|
- if @theme_asset.new_record?
|
2010-10-10 14:37:34 +00:00
|
|
|
= f.input :plain_text_name
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2011-12-07 01:09:13 +00:00
|
|
|
= f.input :plain_text_type, :as => 'select', :collection => %w(stylesheet javascript), :include_blank => false
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2011-11-28 14:40:25 +00:00
|
|
|
= f.input :plain_text, :as => :'Locomotive::Code', :type => plain_text_type(@theme_asset)
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2011-12-07 01:09:13 +00:00
|
|
|
= link_to t('locomotive.theme_assets.form.choose_file'), '#', :class => 'alt'
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2011-12-07 01:09:13 +00:00
|
|
|
= f.inputs :name => :options, :class => "inputs foldable #{'folded' if inputs_folded?(@theme_asset)}" do
|
2011-07-04 17:40:14 +00:00
|
|
|
= f.input :folder
|