{{- $block := .block -}} {{- $block_class := partial "GetBlockClass" .block -}} {{- with .block.data -}}
{{ partial "blocks/top.html" $block.top }} {{ $heading_rank := $block.ranks.children | default 2 }} {{ $heading_name := partial "GetHeadingTag" ( dict "level" $heading_rank "attributes" "itemprop='name'" ) }} {{ $a11y_name := .name | default (i18n "commons.contact.empty_name") }} {{ if .name }} {{ $heading_rank = $heading_rank | add 1 }} {{ end }} {{ $heading_items := partial "GetHeadingTag" $heading_rank }}
{{ with .information }}
{{ end }} {{ if .name }} {{ $heading_name.open }} {{ .name }} {{ $heading_name.close }} {{ end }} {{ with .information }}
{{ partial "PrepareHTML" . }}
{{ end }}
{{ with .contact_details }} {{ with .postal_address }}
{{ $heading_items.open }} {{- i18n "commons.contact.address" -}} {{ $heading_items.close }} {{ partial "commons/address.html" . }}
{{ end }} {{ if or .websites .emails }}
{{ $heading_items.open }} {{ if .websites }} {{- i18n "commons.contact.web" -}} {{ else }} {{- i18n "commons.contact.email.label" -}} {{ end }} {{ $heading_items.close }} {{ with .emails }} {{ $emails := cond .list .list .email }} {{ range $emails }}

{{ .label }}

{{ end }} {{ end }} {{ with .websites.website }}

{{ .label }}

{{ end }}
{{ end }} {{ with .phone_numbers.list }}
{{ $heading_items.open }} {{- i18n "commons.contact.phone.label" -}} {{ $heading_items.close }} {{ range . }}

{{ .label }}

{{ end }}
{{ end }} {{ if .social_networks }}
{{ $heading_items.open }} {{- i18n "commons.contact.socials.title" -}} {{ $heading_items.close }}
    {{ partial "commons/socials" (dict "context" . "name" $a11y_name ) }}
{{ end }} {{ end }} {{ if .timetable }} {{ $time_size := "full-size" }} {{ $contacts := .contact_details }} {{ if and (or $contacts.emails.list $contacts.websites.website) $contacts.phone_numbers.list $contacts.social_networks }} {{ $time_size = "reduced" }} {{ end}}
{{ $heading_items.open }} {{- i18n "commons.contact.schedule" -}} {{ $heading_items.close }}
    {{ range .timetable }} {{ if or .time_slot_morning.from .time_slot_morning.to .time_slot_afternoon.from .time_slot_afternoon.to }}
  • {{ .title }} {{ if or .time_slot_morning.from .time_slot_morning.to }} {{- if .time_slot_morning.from }} {{ end -}} {{- if .time_slot_morning.to }} {{ end -}} {{ end }} {{ if or .time_slot_afternoon.from .time_slot_afternoon.to }} {{- if .time_slot_afternoon.from }} {{ end -}} {{- if .time_slot_afternoon.to }} {{ end -}} {{ end -}}
  • {{ end }} {{ end }}
{{ end }}
{{- end -}}