{% extends 'base.html.twig' %}
{% block title %}
{{ entry.title }}|お知らせ|相模原市、厚木市の注文住宅・分譲住宅のアオイ建設株式会社
{% endblock %}
{% block meta_og_title %}
{{ entry.title }}|お知らせ|相模原市、厚木市の注文住宅・分譲住宅のアオイ建設株式会社
{% endblock %}
{% block meta_twitter_title %}
{{ entry.title }}|お知らせ|相模原市、厚木市の注文住宅・分譲住宅のアオイ建設株式会社
{% endblock %}
{% block meta_description %}{% if entry.description %}{{ entry.description }}{% else %}{{ parent() }}{% endif %}{% endblock %}
{% block meta_og_description %}{% if entry.description %}{{ entry.description }}{% else %}{{ parent() }}{% endif %}{% endblock %}
{% block meta_og_image %}
{% if entry.mainImg %}
<meta property="og:image" content="{{ absolute_url(path('news_image', {"filename": entry.mainImg})) }}">
<meta property="og:image:alt" content="{{ entry.title }}">
<meta property="og:image:width" content="{{ entry.mainImgWidth }}">
<meta property="og:image:height" content="{{ entry.mainImgHeight }}">
{% else %}
{{ parent() }}
{% endif %}
{% endblock %}
{% block extraHeader %}
<link rel="canonical" href="https://{{ entry.canonical }}.aoi-cnst.co.jp/news/{{ entry.id }}">
{% endblock %}
{% block body %}
<main id="news">
<div class="breadcrumbs">
<div class="breadcrumbsContainer">
<a href="/">TOP</a>
<span></span>
<a href="{{ path('news_index') }}">お知らせ</a>
<span></span>
<div>{{ entry.title }}</div>
</div>
</div>
<div class="newsDetail">
<h1>{{ entry.title }}</h1>
<div class="newsDetail__timeCategory">
<div class="newsDetail__timeCategoryWrapper">
<time>{{ entry.entryDate|date('Y.m.d') }}</time>
<span>{{ entry.category.name }}</span>
</div>
{% if entry.isNew %}
<span class="new_tag">NEW</span>
{% endif %}
</div>
{% if entry.mainImg %}
<img src="{{ path('news_image', {"filename": entry.mainImg}) }}" alt="{{ entry.title }}">
{% endif %}
<div>{{ entry.content|raw }}</div>
{# repeat feald loop #}
{% for child in entry.children %}
{% if child.headline %}
<h2>{{ child.headline }}</h2>
{% endif %}
{% if child %}
<div>{{ child.content|raw }}</div>
{% endif %}
{% if child.image %}
<img src="{{ path('news_image', {"filename": child.image}) }}" alt="{% if child.headline %}{{ child.headline }}{% else %}{{ entry.title }}{% endif %}">
{% endif %}
{% endfor %}
<a href="{{ path('news_index') }}" class="button_back"><span></span>一覧へ戻る</a>
</div>
</main>
{% endblock %}