noesya/osuny

View on GitHub
app/views/admin/communication/websites/pages/static.html.erb

Summary

Maintainability
Test Coverage
<%
page = @l10n.about
language = @l10n.language
%>---
breadcrumb_title: >-
  <%= prepare_text_for_static @l10n.best_breadcrumb_title %>
<%= render 'admin/application/static/core', about: @l10n %>
<%= render 'admin/application/static/breadcrumbs', about: @l10n %>
<%= render 'admin/application/static/design',
            about: page,
            l10n: @l10n %>
<% if page.static_layout %>
layout: <%= page.static_layout %>
<% end %>
<% if page.is_a?(Communication::Website::Page::Person) %>
has:
  administrators: <%= @website.has_administrators? %>
  authors: <%= @website.has_authors? %>
  researchers: <%= @website.has_researchers? %>
  teachers: <%= @website.has_teachers? %>
<% end %>
position: <%= page.position %>
weight: <%= page.position %>
<%= render 'admin/application/l10n/static', about: @l10n %>
bodyclass: >-
  <%= page.best_bodyclass %>
<%= render 'admin/application/featured_image/static', about: @l10n %>
<%= render 'admin/application/shared_image/static', about: @l10n %>
<% if @l10n.children.published.any? %>
children:
<%
@l10n.children.published.ordered.each do |child|
  next unless child.about.is_listed_among_children?
%>
  - "<%= child.git_path_relative %>"
<% end %>
<% end %>
<%= render 'admin/application/meta_description/static', about: @l10n %>
<%= render 'admin/application/summary/static', about: @l10n %>
header_text: >-
  <%= prepare_html_for_static @l10n.header_text %>
header_cta:
  display: <%= @l10n.header_cta %>
  label: >-
    <%= prepare_text_for_static @l10n.header_cta_label %>
  target: "<%= @l10n.header_cta_url %>"
  external: <%= @l10n.header_cta_url.present? && !(@l10n.header_cta_url.start_with?('/') || @l10n.header_cta_url.start_with?(@website.url)) %>
<%= render 'admin/communication/contents/static', about: @l10n %>
---