diff --git a/components/organismes/OrganismeView.vue b/components/organismes/OrganismeView.vue index 6f7d1d62..4a7e9216 100644 --- a/components/organismes/OrganismeView.vue +++ b/components/organismes/OrganismeView.vue @@ -155,8 +155,17 @@ getName(props.id).then(result => { ogDescription: () => t("meta.descPersonne") + name.value, ogImage: "https://beta.theses.fr/logo-theses-beta.png", ogImageAlt: 'Logo Theses.fr', - twitterCard: 'summary_large_image', - }) + twitterCard: 'summary', + ogType: 'website', + }); + + useHead({ + meta: [ + { name: 'DC.title', content: `${name.value} | Theses.fr` }, + { name: 'DC.description.abstract', content: `${name.value} | Theses.fr` }, + { name: 'DC.source', content: `theses.fr` } + ] + }); }).catch(error => { if (error.response) { displayError(error.response.data.message, { isSticky: true }); diff --git a/components/personnes/PersonneView.vue b/components/personnes/PersonneView.vue index f59711c5..d8ab6ef5 100644 --- a/components/personnes/PersonneView.vue +++ b/components/personnes/PersonneView.vue @@ -141,8 +141,17 @@ getPersonne(props.id).then(result => { ogDescription: () => t("meta.descPersonne") + item.prenom + " " + item.nom, ogImage: "https://beta.theses.fr/logo-theses-beta.png", ogImageAlt: 'Logo Theses.fr', - twitterCard: 'summary_large_image', - }) + twitterCard: 'summary', + ogType: 'website', + }); + + useHead({ + meta: [ + { name: 'DC.title', content: `${item.value.prenom} ${item.value.nom} | Theses.fr` }, + { name: 'DC.description.abstract', content: `${item.value.prenom} ${item.value.nom} | Theses.fr` }, + { name: 'DC.source', content: `theses.fr` } + ] + }); }).catch(error => { if (error.response) { diff --git a/components/theses/ThesisComponent.vue b/components/theses/ThesisComponent.vue index f4cc0983..0184ee24 100644 --- a/components/theses/ThesisComponent.vue +++ b/components/theses/ThesisComponent.vue @@ -82,8 +82,36 @@ watchEffect(() => { ogDescription: () => props.these.resumes.fr, ogImage: "https://beta.theses.fr/logo-theses-beta.png", ogImageAlt: 'Logo Theses.fr', - twitterCard: 'summary_large_image', - }) + twitterCard: 'summary', + ogType: 'website', + author: () => props.these.auteurs[0].prenom + " " + props.these.auteurs[0].nom, + creator: () => props.these.auteurs[0].prenom + " " + props.these.auteurs[0].nom + }); + + let listeSujetsFR = ""; + props.these.mapSujets.fr.forEach(element => { + listeSujetsFR += element.keyword + ", "; + }); + + useHead({ + meta: [ + { name: 'DC.type', content: 'thesis' }, + { name: 'citation_dissertation_name', content: 'thesis' }, + { name: 'DC.title', content: `${titleThese} | Theses.fr` }, + { name: 'citation_title', content: `${titleThese} | Theses.fr` }, + { name: 'DC.description.abstract', content: props.these.resumes.fr }, + { name: 'citation_abstract', content: props.these.resumes.fr }, + { name: 'DC.subject', content: listeSujetsFR }, + { name: 'citation_keywords', content: listeSujetsFR }, + { name: 'DC.creator', content: props.these.auteurs[0].prenom + " " + props.these.auteurs[0].nom }, + { name: 'citation_author', content: props.these.auteurs[0].prenom + " " + props.these.auteurs[0].nom }, + { name: 'DC.contributor', content: props.these.directeurs[0].prenom + " " + props.these.directeurs[0].nom }, + { name: 'DC.publisher', content: props.these.etabSoutenance.nom }, + { name: 'citation_dissertation_institution', content: props.these.etabSoutenance.nom }, + { name: 'DC.date', content: props.these.dateSoutenance }, + { name: 'citation_publication_date', content: props.these.dateSoutenance } + ] + }); }); diff --git a/pages/resultats.vue b/pages/resultats.vue index 9cc437e5..0ca35dea 100644 --- a/pages/resultats.vue +++ b/pages/resultats.vue @@ -124,7 +124,7 @@ onMounted(async () => { ogDescription: () => `Résultats pour ${request.value} | Theses.fr`, ogImage: "https://beta.theses.fr/logo-theses-beta.png", ogImageAlt: 'Logo Theses.fr', - twitterCard: 'summary_large_image', + twitterCard: 'summary', }) }); });