diff options
Diffstat (limited to 'app/views/layouts')
| -rw-r--r-- | app/views/layouts/admin.html.erb | 45 | ||||
| -rw-r--r-- | app/views/layouts/application.html.erb | 21 | ||||
| -rw-r--r-- | app/views/layouts/events.html.erb | 17 |
3 files changed, 35 insertions, 48 deletions
diff --git a/app/views/layouts/admin.html.erb b/app/views/layouts/admin.html.erb index 4536693..e220beb 100644 --- a/app/views/layouts/admin.html.erb +++ b/app/views/layouts/admin.html.erb | |||
| @@ -7,16 +7,18 @@ | |||
| 7 | <%= csrf_meta_tags %> | 7 | <%= csrf_meta_tags %> |
| 8 | 8 | ||
| 9 | <title><%= "#{params[:controller]} | #{params[:action]}" %></title> | 9 | <title><%= "#{params[:controller]} | #{params[:action]}" %></title> |
| 10 | <%= javascript_tag "var AUTH_TOKEN = #{form_authenticity_token.inspect};" if protect_against_forgery? %> | ||
| 11 | <%= javascript_include_tag 'admin_bundle' %> | 10 | <%= javascript_include_tag 'admin_bundle' %> |
| 12 | <%= tinymce_assets %> | 11 | <%= tinymce_assets %> |
| 13 | <link rel="stylesheet" href="/stylesheets/admin.css"> | 12 | <link rel="stylesheet" href="<%= mtime_busted_path('/stylesheets/admin.css') %>"> |
| 14 | <script src="/javascripts/admin_search.js"></script> | 13 | <script src="<%= mtime_busted_path('/javascripts/admin_search.js') %>"></script> |
| 15 | <script src="/javascripts/admin_interface.js"></script> | 14 | <script src="<%= mtime_busted_path('/javascripts/admin_interface.js') %>"></script> |
| 16 | <script> | 15 | <script src="<%= mtime_busted_path('/javascripts/related_assets.js') %>"></script> |
| 16 | <%= javascript_tag nonce: true do %> | ||
| 17 | var ADMIN_SEARCH_URL = "<%= admin_search_path %>"; | 17 | var ADMIN_SEARCH_URL = "<%= admin_search_path %>"; |
| 18 | var ADMIN_MENU_SEARCH_URL = "<%= admin_menu_search_path %>"; | 18 | var ADMIN_MENU_SEARCH_URL = "<%= admin_menu_search_path %>"; |
| 19 | </script> | 19 | var PARAMETERIZE_PREVIEW_URL = "<%= parameterize_preview_nodes_path %>"; |
| 20 | var DASHBOARD_SEARCH_URL = "<%= admin_dashboard_search_path %>"; | ||
| 21 | <% end %> | ||
| 20 | </head> | 22 | </head> |
| 21 | 23 | ||
| 22 | <body> | 24 | <body> |
| @@ -25,33 +27,36 @@ | |||
| 25 | <div id="main_navigation"> | 27 | <div id="main_navigation"> |
| 26 | <%= render :partial => 'admin/menu' if current_user %> | 28 | <%= render :partial => 'admin/menu' if current_user %> |
| 27 | </div> | 29 | </div> |
| 28 | <div id="sub_navigation"> | 30 | <div id="search_widget" style="display: none;"> |
| 29 | <%= yield :subnavigation %> | 31 | <div> |
| 32 | <%= form_tag admin_search_path, method: :get do %> | ||
| 33 | <%= text_field_tag :search_term, nil, placeholder: "Search nodes…", autocomplete: "off" %> | ||
| 34 | <% end %> | ||
| 35 | </div> | ||
| 36 | <div id="menu_search_results" class="search_results" style="display: none"></div> | ||
| 30 | </div> | 37 | </div> |
| 31 | </div> | 38 | </div> |
| 32 | <div style="clear: both;"></div> | 39 | <div class="admin_content_spacer"></div> |
| 40 | <% if flash[:notice].present? || flash[:error].present? %> | ||
| 33 | <div id="flash"> | 41 | <div id="flash"> |
| 34 | <%= flash[:notice] %> | 42 | <%= flash[:notice] %> |
| 43 | <% if flash[:status_path] %> | ||
| 44 | <%= link_to 'Go to Status', flash[:status_path] %> | ||
| 45 | <% end %> | ||
| 46 | <% if flash[:stale_locale_path] %> | ||
| 47 | The <%= flash[:stale_locale] %> translation may be out of date — | ||
| 48 | <%= link_to 'review it', flash[:stale_locale_path] %> too. | ||
| 49 | <% end %> | ||
| 35 | <% if flash[:error] %> | 50 | <% if flash[:error] %> |
| 36 | <span id="flash_error"><%= flash[:error] %></span> | 51 | <span id="flash_error"><%= flash[:error] %></span> |
| 37 | <% end %> | 52 | <% end %> |
| 38 | </div> | 53 | </div> |
| 54 | <% end %> | ||
| 39 | <div id="content"> | 55 | <div id="content"> |
| 40 | <%= yield %> | 56 | <%= yield %> |
| 41 | </div> | 57 | </div> |
| 42 | 58 | ||
| 43 | <div id="results"></div> | 59 | <div id="results"></div> |
| 44 | </div> | 60 | </div> |
| 45 | |||
| 46 | <div id="search_widget" style="display: none;"> | ||
| 47 | <div> | ||
| 48 | <%= form_tag admin_search_path, method: :get do %> | ||
| 49 | <span>Search: </span><%= text_field_tag :search_term, nil, autocomplete: "off" %> | ||
| 50 | <% end %> | ||
| 51 | </div> | ||
| 52 | <div id="search_results" style="display: none"> | ||
| 53 | |||
| 54 | </div> | ||
| 55 | </div> | ||
| 56 | </body> | 61 | </body> |
| 57 | </html> | 62 | </html> |
diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index edab5fc..f981fc1 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb | |||
| @@ -10,20 +10,20 @@ | |||
| 10 | <meta property="og:description" content="Der Chaos Computer Club ist eine galaktische Gemeinschaft von Lebewesen für Informationsfreiheit und Technikfolgenabschätzung." /> | 10 | <meta property="og:description" content="Der Chaos Computer Club ist eine galaktische Gemeinschaft von Lebewesen für Informationsfreiheit und Technikfolgenabschätzung." /> |
| 11 | 11 | ||
| 12 | <title><%= page_title %></title> | 12 | <title><%= page_title %></title> |
| 13 | <link rel="stylesheet" href="/stylesheets/ccc.css"> | 13 | <link rel="stylesheet" href="<%= mtime_busted_path('/stylesheets/ccc.css') %>"> |
| 14 | <link rel="stylesheet" href="/stylesheets/glightbox.min.css"> | 14 | <link rel="stylesheet" href="<%= mtime_busted_path('/stylesheets/glightbox.min.css') %>"> |
| 15 | <script src="/javascripts/glightbox.min.js"></script> | 15 | <script src="<%= mtime_busted_path('/javascripts/glightbox.min.js') %>"></script> |
| 16 | <script src="/javascripts/public.js"></script> | 16 | <script src="<%= mtime_busted_path('/javascripts/public.js') %>"></script> |
| 17 | 17 | ||
| 18 | <%= auto_discovery_link_tag(:atom, '/rss/updates.xml', title: "ATOM") %> | 18 | <%= auto_discovery_link_tag(:atom, '/rss/updates.xml', title: "ATOM") %> |
| 19 | <%= auto_discovery_link_tag(:rss, '/rss/updates.rdf', title: "RSS") %> | 19 | <%= auto_discovery_link_tag(:rss, '/rss/updates.rdf', title: "RSS") %> |
| 20 | 20 | ||
| 21 | <script> | 21 | <%= javascript_tag nonce: true do %> |
| 22 | (function() { document.addEventListener("DOMContentLoaded", function() { | 22 | document.addEventListener("DOMContentLoaded", function() { |
| 23 | if (localStorage.getItem('override-prefers-color-scheme', false)) | 23 | if (localStorage.getItem('override-prefers-color-scheme')) |
| 24 | document.getElementById("light-mode").checked = true; | 24 | document.getElementById("light-mode").checked = true; |
| 25 | }); })(); | 25 | }); |
| 26 | </script> | 26 | <% end %> |
| 27 | 27 | ||
| 28 | </head> | 28 | </head> |
| 29 | 29 | ||
| @@ -62,16 +62,15 @@ | |||
| 62 | <div id="center_column"> | 62 | <div id="center_column"> |
| 63 | <%= yield :layout %> | 63 | <%= yield :layout %> |
| 64 | <div id="footer"> | 64 | <div id="footer"> |
| 65 | <br /> | ||
| 66 | <p style="text-align: center"> | 65 | <p style="text-align: center"> |
| 67 | <%= link_to "Impressum", content_path("imprint") %> | 66 | <%= link_to "Impressum", content_path("imprint") %> |
| 68 | <%= link_to "Datenschutz", content_path("datenschutz") %> | 67 | <%= link_to "Datenschutz", content_path("datenschutz") %> |
| 69 | <%= language_selector %> | 68 | <%= language_selector %> |
| 70 | <!-- %= link_to t(:sponsors), content_path("sponsors") % --> | ||
| 71 | </p> | 69 | </p> |
| 72 | </div> | 70 | </div> |
| 73 | </div> | 71 | </div> |
| 74 | <div id="right_column"> | 72 | <div id="right_column"> |
| 73 | <%= open_erfas_today %> | ||
| 75 | <%= tags %> | 74 | <%= tags %> |
| 76 | <%= featured_articles %> | 75 | <%= featured_articles %> |
| 77 | </div> | 76 | </div> |
diff --git a/app/views/layouts/events.html.erb b/app/views/layouts/events.html.erb deleted file mode 100644 index 93a6c0c..0000000 --- a/app/views/layouts/events.html.erb +++ /dev/null | |||
| @@ -1,17 +0,0 @@ | |||
| 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | ||
| 2 | "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | ||
| 3 | |||
| 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> | ||
| 5 | <head> | ||
| 6 | <meta http-equiv="content-type" content="text/html;charset=UTF-8" /> | ||
| 7 | <title>Events: <%= controller.action_name %></title> | ||
| 8 | <%= stylesheet_link_tag 'scaffold' %> | ||
| 9 | </head> | ||
| 10 | <body> | ||
| 11 | |||
| 12 | <p style="color: green"><%= flash[:notice] %></p> | ||
| 13 | |||
| 14 | <%= yield %> | ||
| 15 | |||
| 16 | </body> | ||
| 17 | </html> | ||
