Sha256: 9078f651bfcda57b494d1fd7a52b2db13bc251066971b8c7b1e0953632c6581c

Contents?: true

Size: 1.46 KB

Versions: 6

Compression:

Stored size: 1.46 KB

Contents

- content_for :head do
  = javascript_include_tag 'admin/plugins/codemirror/codemirror', 'admin/theme_assets.js'
  = image_picker_include_tags

= f.hidden_field :performing_plain_text

#file-selector{ :class => "selector #{'hidden' if @theme_asset.stylesheet_or_javascript?}" }
  = f.inputs :name => :information do
    = f.input :source

  - if @theme_asset.new_record? || @theme_asset.stylesheet_or_javascript?
    %span.alt
      != t('admin.theme_assets.form.choose_plain_text')

- if allow_plain_text_editing?(@theme_asset)
  #text-selector{ :class => "selector #{'hidden' if !@theme_asset.stylesheet_or_javascript?}", :style => "#{'display: none' if !@theme_asset.stylesheet_or_javascript?}" }
    = f.inputs :name => :code, :class => 'inputs code' do

      - if @theme_asset.new_record?
        = f.input :plain_text_name

        = f.custom_input :content_type do
          = f.select :content_type, %w(stylesheet javascript)

      = f.custom_input :plain_text, :css => 'full', :with_label => false do
        %code{ :class => (@theme_asset.size && @theme_asset.size > 40000 ? 'nude' : (@theme_asset.content_type || 'stylesheet')) }
          = f.text_area :plain_text
        .more
          = link_to t('admin.image_picker.link'), admin_theme_assets_path, :id => 'image-picker-link'

    %span.alt
      != t('admin.theme_assets.form.choose_file')

= f.foldable_inputs :name => :options do
  = f.input :folder
  = f.custom_input :hidden, :css => 'toggle' do
    = f.check_box :hidden

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
locomotive_cms-0.0.4.beta5 app/views/admin/theme_assets/_form.html.haml
locomotive_cms-0.0.4.beta4 app/views/admin/theme_assets/_form.html.haml
locomotive_cms-0.0.4.beta3 app/views/admin/theme_assets/_form.html.haml
locomotive_cms-0.0.4.beta2 app/views/admin/theme_assets/_form.html.haml
locomotive_cms-0.0.4.beta1 app/views/admin/theme_assets/_form.html.haml
locomotive_cms-0.0.4 app/views/admin/theme_assets/_form.html.haml