app/views/admin/layouts/_form.html.haml in radiant-0.8.2 vs app/views/admin/layouts/_form.html.haml in radiant-0.9.0.rc2
- old
+ new
@@ -1,36 +1,39 @@
-- form_for [:admin, @layout] do |f|
- .form-area
- = render_region :form_top
- = hidden_field 'layout', 'lock_version'
+- form_for [:admin, @layout], :html => {'data-onsubmit_status' => onsubmit_status(@layout)} do |f|
+ = f.hidden_field :lock_version
+ = render_region :form_top
+ .form_area
- render_region :form do |form|
- form.edit_title do
%p.title
- = f.label :name
- = f.text_field 'name', :maxlength => 100, :class => "textbox"
+ = f.label :name, t('name')
+ = f.text_field :name, :maxlength => 100, :class => "textbox"
- form.edit_extended_metadata do
- #extended-metadata.row{meta_visible(:meta)}
- %table.fieldset{:cellpadding=>"0", :cellspacing=>"0", :border=>"0"}
- %tr
- %th.label
- = f.label :content_type, "Context‑Type"
- %td.field
- = f.text_field 'content_type', :maxlength => 40, :class => "textbox"
- = render_region :extended_metadata
- %p.more-or-less
- %small
- %a#more-extended-metadata{meta_visible(:meta_more), :href => "#", :onclick=>toggle_javascript_for('extended-metadata')} More
- %a#less-extended-metadata{meta_visible(:meta_less), :href => "#", :onclick=>toggle_javascript_for('extended-metadata')} Less
+ .drawer
+ .drawer_contents#attributes
+ %table.fieldset
+ %tr
+ %th.label= f.label :content_type, t('content_type')
+ %td.field= f.text_field :content_type, :maxlength => 40, :class => "textbox"
+ = render_region :extended_metadata
+ .drawer_handle
+ %a.toggle{:href=>'#attributes', :rel=>"toggle[attributes]", :class=>"#{(meta_errors? ? 'less' : 'more')}"}= meta_label
- form.edit_content do
%p.content
= f.label :layout_content, "Body"
- ~ f.text_area 'content', :size => '40x20', :style => 'width: 100%', :class => "textarea"
- - form.edit_timestamp do
- = updated_stamp @layout
+ ~ f.text_area :content, :size => "40x20", :style => "width: 100%", :class => "textarea large"
= javascript_tag "$('layout_name').activate()"
- render_region :form_bottom do |form_bottom|
+ - form_bottom.reference_links do
+ %p
+ %span.reference_links
+ Reference:
+ %span{:id => "tag_reference_link"}
+ = link_to_function 'Available Tags', "loadTagReference('Page');"
- form_bottom.edit_buttons do
%p.buttons
= save_model_button @layout
= save_model_and_continue_editing_button @layout
- or
- = link_to "Cancel", admin_layouts_url
\ No newline at end of file
+ = t('or')
+ = link_to t('cancel'), admin_layouts_url
+ - form_bottom.edit_timestamp do
+ = updated_stamp @layout