% content_for :body do %>
<% if @preview %>
<%= yield %>
<% else %>
<%= render "govuk_publishing_components/components/layout_header", {
environment: GovukPublishingComponents::AppHelpers::Environment.current_acceptance_environment,
product_name: GovukPublishingComponents::Config.component_guide_title,
href: component_guide_path
} %>
<% if @guide_breadcrumbs %>
<%= render 'govuk_publishing_components/components/breadcrumbs', breadcrumbs: @guide_breadcrumbs %>
<% end %>
<%= yield %>
<%= render "govuk_publishing_components/components/layout_footer" %>
<% end %>
<% end %>
">
<% if @preview %>
<%= @component_doc.name %><% if @component_examples.length == 1 %>:
<%= @component_examples.first.name %>
<% end %>
preview -
<% end %>
<%= yield :title %><% if content_for(:title) %> - <% end %><%= GovukPublishingComponents::Config.component_guide_title %>
<%= csrf_meta_tags %>
<%= favicon_link_tag "govuk_publishing_components/favicon-production.png" %>
<%= stylesheet_link_tag "component_guide/application", media: "all" %>
<%= yield :application_stylesheet %>
<%= render_component_stylesheets %>
<%= javascript_include_tag "govuk_publishing_components/vendor/modernizr" %>
<%= yield :extra_headers %>
<%= javascript_tag nonce: true do -%>
document.body.className = ((document.body.className) ? document.body.className + ' js-enabled' : 'js-enabled');
<% end -%>
<%= yield :body %>
<%= javascript_include_tag "component_guide/application" %>
<%= javascript_include_tag "#{GovukPublishingComponents::Config.application_javascript}" %>