Verdere opmaak van gestructureerde data, aanbrengen onderscheid tussen webpagina's en profielpagina's, markeren content die uitgesproken kan worden
This commit is contained in:
parent
3d2a7b3b65
commit
029409826a
|
@ -5,13 +5,15 @@
|
||||||
<!-- Accessibility: skip-link voor mobiele apparaten -->
|
<!-- Accessibility: skip-link voor mobiele apparaten -->
|
||||||
<a class="skip-link" href="#main">Ga naar hoofd</a>
|
<a class="skip-link" href="#main">Ga naar hoofd</a>
|
||||||
<main id="main">
|
<main id="main">
|
||||||
|
{{ partialCached "header.html" . }}
|
||||||
|
{{ partial "breadcrumb.html" . }}
|
||||||
<div class="content">
|
<div class="content">
|
||||||
{{ partialCached "header.html" . }}
|
<h1 class="post speakable">{{ .Title }}</h1>
|
||||||
{{ partial "breadcrumb.html" . }}
|
<div class="speakable">
|
||||||
<h1 class="post">{{ .Title }}</h1>
|
|
||||||
{{- block "main" . }}
|
{{- block "main" . }}
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
</div>
|
||||||
|
|
||||||
{{ partial "show-call-to-action.html" . }}
|
{{ partial "show-call-to-action.html" . }}
|
||||||
|
|
||||||
|
|
|
@ -53,6 +53,7 @@
|
||||||
<li>BundleType = {{ .BundleType }}</li>
|
<li>BundleType = {{ .BundleType }}</li>
|
||||||
<li>IsPage = {{ .IsPage }}</li>
|
<li>IsPage = {{ .IsPage }}</li>
|
||||||
<li>IsSection = {{ .IsSection }}</li>
|
<li>IsSection = {{ .IsSection }}</li>
|
||||||
|
<li>Content types = {{ .Params.content_types }}</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
|
@ -2,13 +2,16 @@
|
||||||
|
|
||||||
{{ partial "schemas/schema_Organization.html" . }}
|
{{ partial "schemas/schema_Organization.html" . }}
|
||||||
{{ partial "schemas/schema_WebSite.html" . }}
|
{{ partial "schemas/schema_WebSite.html" . }}
|
||||||
|
{{ partial "schemas/schema_WebPage.html" . }}
|
||||||
|
|
||||||
{{- else if .IsPage -}}
|
{{- else if .IsPage -}}
|
||||||
|
|
||||||
{{ partial "schemas/schema_BreadcrumbList.html" . }}
|
|
||||||
|
|
||||||
{{ if in .Params.content_types "person" }}
|
{{ if in .Params.content_types "person" }}
|
||||||
{{ partial "schemas/schema_Person.html" . }}
|
{{ partial "schemas/schema_Person.html" . }}
|
||||||
|
{{ else }}
|
||||||
|
{{ partial "schemas/schema_WebPage.html" . }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
|
{{ partial "schemas/schema_BreadcrumbList.html" . }}
|
||||||
|
|
|
@ -1,42 +1,56 @@
|
||||||
{{ if .Params.slug }}
|
{{ $author := index .Site.Data.personen (substr $.File.LogicalName 0 -3) }}
|
||||||
{{ $author := index .Site.Data.personen .Params.slug }}
|
|
||||||
{{ $location := index .Site.Data.location .Site.Params.primarylocation }}
|
{{ $location := index .Site.Data.location .Site.Params.primarylocation }}
|
||||||
<script type="application/ld+json">
|
<script type="application/ld+json">
|
||||||
{
|
{
|
||||||
"@context": "https://www.schema.org",
|
"@context": "https://www.schema.org",
|
||||||
"@type": "Person",
|
"@type": "Person",
|
||||||
"@id": "{{ .Permalink }}",
|
"@id": "{{ .Permalink }}#person",
|
||||||
"name": "{{ $author.name | default .Site.Params.textEmptyValue }}",
|
"url": "{{ .Permalink }}",
|
||||||
{{ if $author.nationality }}"nationality": "{{ $author.nationality }}",{{ end }}
|
"name": "{{ $author.name | default .Site.Params.textEmptyValue }}",
|
||||||
"affiliation": [
|
{{ if $author.nationality }}"nationality": "{{ $author.nationality }}",{{ end }}
|
||||||
{
|
"affiliation": [
|
||||||
"@type": "Organization",
|
{
|
||||||
"name": "{{ $.Site.Params.organization_name | default .Site.Params.textEmptyValue }}",
|
"@type": "Organization",
|
||||||
"sameAs": {{ .Site.Params.organization_sameas }}
|
"name": "{{ $.Site.Params.organization_name | default .Site.Params.textEmptyValue }}",
|
||||||
|
"sameAs": {{ .Site.Params.organization_sameas }}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
{{ if $author.gender }}"gender": "{{ $author.gender }}",{{ end }}
|
||||||
|
{{ if $author.jobfunction }}"Description": "{{ $author.jobfunction }}",{{ end }}
|
||||||
|
{{ if $author.description }}"disambiguatingDescription": "{{ $author.description }}",{{ end }}
|
||||||
|
{{ if $author.jobtitle }}"jobTitle": "{{ $author.jobtitle }}",{{ end }}
|
||||||
|
{{ if $author.worksfor }}
|
||||||
|
"worksFor": [
|
||||||
|
{
|
||||||
|
"@type": "Organization",
|
||||||
|
"name": "{{ .Site.Params.name | default .Site.Params.textEmptyValue }}"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
{{ end }}
|
||||||
|
{{ if $author.sameas }}"sameAs": "{{ $author.sameas }}",{{ end }}
|
||||||
|
{{ if $author.address }}
|
||||||
|
"address": {
|
||||||
|
"@type": "PostalAddress",
|
||||||
|
"addressLocality": "{{ $author.address.city }}",
|
||||||
|
"addressRegion": "{{ $author.address.region }}",
|
||||||
|
"addressCountry": "{{ $author.address.country }}"
|
||||||
|
},{{ end }}
|
||||||
|
"image": "{{ $author.thumbnail | absURL }}",
|
||||||
|
"mainEntityOfPage": {
|
||||||
|
"@type": "ProfilePage",
|
||||||
|
"@id": "{{ .Permalink }}#profilepage",
|
||||||
|
"url": "{{ .Permalink }}",
|
||||||
|
"name": "{{ .Title }}",
|
||||||
|
"speakable": {
|
||||||
|
"@type": "SpeakableSpecification",
|
||||||
|
"cssSelector": ".speakable"
|
||||||
|
},
|
||||||
|
"isPartOf": {
|
||||||
|
"@type": "WebSite",
|
||||||
|
"@id": "{{ .Site.BaseURL }}#website",
|
||||||
|
"url": "{{ .Site.BaseURL }}",
|
||||||
|
"name": "{{ .Site.Title | default .Site.Params.textNoTitle }}"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
],
|
|
||||||
{{ if $author.gender }}"gender": "{{ $author.gender }}",{{ end }}
|
|
||||||
{{ if $author.jobfunction }}"Description": "{{ $author.jobfunction }}",{{ end }}
|
|
||||||
{{ if $author.description }}"disambiguatingDescription": "{{ $author.description }}",{{ end }}
|
|
||||||
{{ if $author.jobtitle }}"jobTitle": "{{ $author.jobtitle }}",{{ end }}
|
|
||||||
{{ if $author.worksfor }}
|
|
||||||
"worksFor": [
|
|
||||||
{
|
|
||||||
"@type": "Organization",
|
|
||||||
"name": "{{ .Site.Params.name | default .Site.Params.textEmptyValue }}"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
{{ end }}
|
|
||||||
{{ if $author.sameas }}"sameAs": "{{ $author.sameas }}",{{ end }}
|
|
||||||
{{ if $author.address }}
|
|
||||||
"address": {
|
|
||||||
"@type": "PostalAddress",
|
|
||||||
"addressLocality": "{{ $author.address.city }}",
|
|
||||||
"addressRegion": "{{ $author.address.region }}",
|
|
||||||
"addressCountry": "{{ $author.address.country }}"
|
|
||||||
},{{ end }}
|
|
||||||
"image": "{{ $author.thumbnail | absURL }}",
|
|
||||||
"url": "{{ .Permalink }}"
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
{{ end }}
|
|
||||||
|
|
25
themes/nluug/layouts/partials/schemas/schema_WebPage.html
Normal file
25
themes/nluug/layouts/partials/schemas/schema_WebPage.html
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
<script type="application/ld+json">
|
||||||
|
{
|
||||||
|
"@context": "https://www.schema.org",
|
||||||
|
"@type": "WebPage",
|
||||||
|
"@id": "{{ .Permalink }}#webpage",
|
||||||
|
"name": "{{ .Title | default .Site.Params.textEmptyValue }}",
|
||||||
|
"datePublished": {{ .Date }},
|
||||||
|
"dateModified": {{ .Lastmod }},
|
||||||
|
"inLanguage": "{{ .Site.LanguageCode }}",
|
||||||
|
"mainContentOfPage": {
|
||||||
|
"@type": "WebPageElement",
|
||||||
|
"cssSelector": ".content"
|
||||||
|
},
|
||||||
|
"speakable": {
|
||||||
|
"@type": "SpeakableSpecification",
|
||||||
|
"cssSelector": ".speakable"
|
||||||
|
},
|
||||||
|
"isPartOf": {
|
||||||
|
"@type": "WebSite",
|
||||||
|
"@id": "{{ .Site.BaseURL }}#website",
|
||||||
|
"url": "{{ .Site.BaseURL }}",
|
||||||
|
"name": "{{ .Site.Title | default .Site.Params.textNoTitle }}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
|
@ -4,27 +4,16 @@
|
||||||
|
|
||||||
<script type="application/ld+json">
|
<script type="application/ld+json">
|
||||||
[
|
[
|
||||||
{
|
|
||||||
"@context": "https://schema.org",
|
|
||||||
"@type": "Webpage",
|
|
||||||
"specialty": "{{ .Site.Params.description | default .Site.Params.textEmptyValue }}",
|
|
||||||
"mainContentOfPage": {
|
|
||||||
"@context": "https://schema.org/",
|
|
||||||
"@type": "WebPageElement",
|
|
||||||
"cssSelector": ".body-contentTODO"
|
|
||||||
},
|
|
||||||
"primaryImageOfPage": "{{ .Site.Params.imageurl | absURL | default .Site.Params.textEmptyValue }}"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"@context": "https://schema.org",
|
"@context": "https://schema.org",
|
||||||
"@type": "WebSite",
|
"@type": "WebSite",
|
||||||
"@id": "{{ .Site.BaseURL }}",
|
"@id": "{{ .Site.BaseURL }}#website",
|
||||||
"additionalType": ["CreativeWork", "Person"],
|
"additionalType": ["CreativeWork"],
|
||||||
"url": "{{ .Site.BaseURL }}",
|
"url": "{{ .Site.BaseURL }}",
|
||||||
"name": "{{ .Site.Title | default .Site.Params.textNoTitle }}",
|
"name": "{{ .Site.Title | default .Site.Params.textNoTitle }}",
|
||||||
"alternateName": "{{ .Site.Title | default .Site.Params.textNoTitle }}",
|
"alternateName": "{{ .Site.Title | default .Site.Params.textNoTitle }}",
|
||||||
"headline": "{{ .Site.Params.description | default .Site.Params.textNoTitle }}",
|
"headline": "{{ .Site.Params.description | default .Site.Params.textNoTitle }}",
|
||||||
"image": "{{ .Site.Params.imageurl | absURL | default .Site.Params.textNoTitle }}",
|
{{ if .Site.Params.imageurl }}"image": "{{ .Site.Params.imageurl | absURL | default .Site.Params.textNoTitle }}",{{ end }}
|
||||||
"inLanguage": "{{ .Site.LanguageCode }}",
|
"inLanguage": "{{ .Site.LanguageCode }}",
|
||||||
"author": "{{ .Site.Params.author | default .Site.Params.textNoValue }}",
|
"author": "{{ .Site.Params.author | default .Site.Params.textNoValue }}",
|
||||||
"description": "{{ .Site.Params.description }}",
|
"description": "{{ .Site.Params.description }}",
|
||||||
|
|
Reference in a new issue