engine/app/views/locomotive/public/pages/show_toolbar.html.haml
2012-01-17 12:05:39 +01:00

57 lines
1.7 KiB
Plaintext

!!! XML
!!!
%html{ :xmlns => 'http://www.w3.org/1999/xhtml' }
%head
%title Locomotive
= csrf_meta_tag
- key = Rails.application.config.session_options[:key]
%meta{ :name => 'key-param', :content => Rails.application.config.session_options[:key] }
%meta{ :name => 'key-token', :content => cookies[key] }
= stylesheet_link_tag 'locomotive/inline_editor', :media => 'screen'
= javascript_include_tag 'locomotive/inline_editor'
%script{ :type => 'text/javascript' }
:plain
window.locale = '#{I18n.locale}';
Locomotive.mounted_on = '#{Locomotive.mounted_on}';
Locomotive.current_site = new Locomotive.Models.Site(#{current_site.to_json});
Locomotive.current_account = new Locomotive.Models.Account(#{current_locomotive_account.to_json});
$(document).ready(function() {
window.application_view = new Locomotive.Views.InlinEditor.ApplicationView();
window.application_view.render();
});
%script{ :type => 'text/html', :id => 'toolbar' }
%h1 {{title}}
.back.col
= link_to t('.buttons.back'), '#', :class => 'button back'
.editing-mode.col{ :style => 'display: none' }
%label= t('.editing_mode')
= check_box_tag 'edit', '1', false
.element-actions.col{ :style => 'display: none' }
%label= t('.save_modifications')
= link_to t('.buttons.confirm'), '#', :class => 'button save'
= link_to t('.buttons.cancel'), '#', :class => 'button cancel'
%body
#page
%iframe{ :src => request.fullpath.gsub('_admin', '_edit'), :scrolling => 'no', :frameborder => '0' }
#toolbar
.background
.inner