Soc/app/views/layouts/application.html.erb

37 lines
1.1 KiB
Plaintext
Raw Permalink Normal View History

<!DOCTYPE html>
<html>
<head>
<title><%= @title.present? ? "#{@title} | #{t('.site_title')}" : t(".site_title") %></title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<%= csrf_meta_tags %>
<%= csp_meta_tag %>
<%= javascript_importmap_tags %>
2024-08-08 08:12:01 +00:00
<%= stylesheet_link_tag :all, "data-turbo-track": "reload" %>
</head>
<body>
2023-08-18 16:20:31 +00:00
<header>
<nav>
<ul>
<li><%= link_to t(".home"), root_path %></li>
2023-10-05 18:46:09 +00:00
<li><%= link_to t(".blog_posts"), blog_posts_path %></li>
<li><%= link_to t(".microposts"), microposts_path %></li>
2023-08-18 16:20:31 +00:00
<% if logged_in? %>
<li><%= link_to t(".diary_entries"), diary_entries_path %></li>
<li><%= link_to t(".profile"), user_path(current_user) %></li>
<li><%= link_to t(".log_out"), log_out_path, data: { turbo_method: :delete } %></li>
2023-08-18 16:20:31 +00:00
<% end %>
</ul>
</nav>
2024-03-06 20:31:14 +00:00
<%= link_to root_path do %>
<h1><%= t(".site_title") %></h1>
<% end %>
2023-08-18 16:20:31 +00:00
</header>
<main>
<%= render "shared/flash" %>
<%= yield %>
</main>
</body>
</html>