- content_for :sidebar do .sidebar .content %h2= t('tenon.pages.pages') %h4= t('tenon.common.edit_options') %nav %ul %li.active= link_to t('tenon.pages.page_content'), '#details', data: {toggle: 'tab'} %li= link_to t('tenon.common.search_optimization'), '#seo', data: {toggle: 'tab'} = i18n_language_nav(:'tenon/pages') = autosaving_form_for @page do |f| = error_messages_for :page .fields.large.tabs .tab-pane.active#details .form-group = f.text_field :title, explanation: t('tenon.pages.this_is_the_title') .form-group= f.tenon_content :content .tab-pane#seo= render 'tenon/shared/seo_fields', f: f .fields.small %h4.box-label= t('tenon.common.details') .box .form-group.bordered = f.super_label :parent_id, t('tenon.pages.parent_page') = f.collection_select :parent_id, @potential_parents, :id, :option_title, { :include_blank => t('tenon.pages.no_parent') } .form-group.inline.bordered = f.check_box :show_in_menu, class: 'tn-checkbox-right' = f.super_label :show_in_menu, t('tenon.pages.show_in_menu') .form-group.inline.bordered = f.check_box :show_contact_form, class: 'tn-checkbox-right' = f.super_label :show_contact_form, t('tenon.pages.show_contact_form') %h4.box-label= t('tenon.pages.publish_your_page') .box .form-group = f.text_field :publish_at, label: t('tenon.common.publish_date'), data: { behaviour: 'datetime-picker' }, placeholder: '--' .row.content - if can?(:publish, @page) %button.btn.btn-comp.btn-block.submit{ data: { disable_with: t('tenon.common.please_wait') } }= t('tenon.common.save') - if can?(:create, Tenon::ItemVersion) = save_draft_button(@page) .last-autosave %hr .content = clear_draft_link if params[:version] = load_draft_link(@page) - if @page.persisted? = link_to t('tenon.common.delete'), @page, data: { method: :delete, confirm: t('tenon.common.are_you_sure') }, class: 'delete-link'