2020-10-12 17:51:35 +02:00
|
|
|
extends layout.pug
|
|
|
|
block append scripts
|
|
|
|
script(src="/JS/polyfill.app.js" defer)
|
2022-01-28 17:37:19 +01:00
|
|
|
script(src="/JS/groupElement.app.js" defer)
|
2020-10-12 17:51:35 +02:00
|
|
|
block content
|
|
|
|
div(id="tags" class="cardboard")
|
|
|
|
ul
|
|
|
|
li
|
|
|
|
a(href="/") #{config.siteName}
|
|
|
|
for tag in questionnaire.Tags
|
|
|
|
li
|
|
|
|
a(href="/quizs/"+tag.slug+".html") #{tag.name}
|
|
|
|
-
|
|
|
|
const imgAttributes = { alt: txtIllustration.defaultAlt, style: "opacity: 0.0;" };
|
|
|
|
if(questionnaire.Illustrations!=undefined && questionnaire.Illustrations.length!==0)
|
|
|
|
{
|
|
|
|
if (tool.isEmpty(questionnaire.Illustrations[0].alt)===false)
|
|
|
|
imgAttributes.alt=questionnaire.Illustrations[0].alt;
|
|
|
|
if(tool.isEmpty(questionnaire.Illustrations[0].title)===false)
|
|
|
|
imgAttributes.title=questionnaire.Illustrations[0].title;
|
|
|
|
}
|
|
|
|
const publishedAtTxt=tool.dateFormat(questionnaire.Questionnaire.publishingAt, questionnaire.Questionnaire.language);
|
|
|
|
const updatedAtTxt=tool.dateFormat(questionnaire.Questionnaire.updatedAt, questionnaire.Questionnaire.language);
|
2020-10-20 11:01:52 +02:00
|
|
|
if(questionnaire.Illustrations != undefined && questionnaire.Illustrations.length !== 0)
|
2020-10-12 17:51:35 +02:00
|
|
|
div(id="content-picture" class="cardboard")
|
|
|
|
div(style="background-image: url('/img/quizs/"+questionnaire.Illustrations[0].url+"');")
|
|
|
|
img(src="/img/quizs/"+questionnaire.Illustrations[0].url)&attributes(imgAttributes)
|
|
|
|
if(questionnaire.Illustrations[0].caption)
|
|
|
|
p !{questionnaire.Illustrations[0].caption}
|
|
|
|
div(id="content-side")
|
|
|
|
div(id="content-title")
|
|
|
|
h1(class="cardboard")
|
|
|
|
img(id="required-time-icon" src="/themes/wikilerni/img/time-required-"+questionnaire.Questionnaire.estimatedTime+".png" title=txtQuestionnaire.estimatedTime+" "+txtQuestionnaire.estimatedTimeOption[questionnaire.Questionnaire.estimatedTime])
|
|
|
|
span #{questionnaire.Questionnaire.title}
|
2020-10-20 11:01:52 +02:00
|
|
|
if(questionnaire.Illustrations != undefined && questionnaire.Illustrations.length !== 0)
|
2020-10-12 17:51:35 +02:00
|
|
|
a(href="/img/quizs/"+questionnaire.Illustrations[0].url target="_blank" rel="noopener")
|
|
|
|
img(src="/img/quizs/min/"+questionnaire.Illustrations[0].url class="thumb")&attributes(imgAttributes)
|
|
|
|
div(id="content-title-corner")
|
|
|
|
div(id="content" class="cardboard")
|
|
|
|
p(id="author-date") #{txtQuestionnaire.publishedBy} #{author}#{txtQuestionnaire.publishedAt} #{publishedAtTxt}. #{txtQuestionnaire.lastUpdated}#{updatedAtTxt}.
|
|
|
|
if(questionnaire.Questionnaire.introduction)
|
|
|
|
div#introduction !{questionnaire.Questionnaire.introduction}
|
2020-10-20 11:01:52 +02:00
|
|
|
if(questionnaire.Links != undefined && questionnaire.Links.length !== 0)
|
2020-10-20 12:11:19 +02:00
|
|
|
div#quizElementLinks
|
2020-10-20 11:01:52 +02:00
|
|
|
h4 #{configTpl.quizElementLinksIntro}
|
2020-10-20 12:11:19 +02:00
|
|
|
ul
|
|
|
|
for link in questionnaire.Links
|
|
|
|
li
|
|
|
|
a(href=link.url target="_blank" rel="noopener" title=link.anchor+" ("+txtGeneral.alertNewWindow+")") #{link.anchor}
|
2020-10-20 11:01:52 +02:00
|
|
|
-
|
|
|
|
let nextLink={};
|
|
|
|
if(nextQuestionnaire != null && nextQuestionnaire.Questionnaire.isPublished)
|
|
|
|
{
|
|
|
|
nextLink.href="/"+configQuestionnaires.dirWebQuestionnaires+"/"+nextQuestionnaire.Questionnaire.slug+".html";
|
|
|
|
nextLink.title=nextQuestionnaire.Questionnaire.title;
|
|
|
|
nextLink.anchor=txtQuestionnaire.linkGoToNextElement;
|
|
|
|
}
|
|
|
|
else if(group.Group.isPublishable)
|
|
|
|
{
|
|
|
|
nextLink.href="/"+configQuestionnaires.dirWebGroups+"/"+group.Group.slug+".html";
|
|
|
|
nextLink.title=group.Group.title;
|
|
|
|
nextLink.anchor=txtQuestionnaire.linkGoToQuiz;
|
|
|
|
}
|
|
|
|
if(nextLink.href!=undefined)
|
2020-11-04 10:02:04 +01:00
|
|
|
p
|
|
|
|
span #{nextLink.anchor+" : "}
|
|
|
|
a(href=nextLink.href title=nextLink.title) #{nextLink.title}
|
2020-10-20 11:01:52 +02:00
|
|
|
div#nextLink
|
|
|
|
a(href=nextLink.href class="button cardboard" title=nextLink.title) !{"➔ "+nextLink.anchor}
|
2020-12-07 12:55:24 +01:00
|
|
|
div#licence
|
2022-01-28 17:37:19 +01:00
|
|
|
p !{configTpl.licenceTxt}
|
2020-10-12 17:51:35 +02:00
|
|
|
div#zerozozio
|
2020-11-04 10:02:04 +01:00
|
|
|
a(href="mailto:?to=&subject="+questionnaire.Questionnaire.title+"&body="+txtQuestionnaire.btnShareQuizMailBody+linkCanonical rel="nofollow noopener" title=txtQuestionnaire.btnShareQuizTxt+"e-mail* ("+txtGeneral.alertNewWindow+")" target="_blank")
|
|
|
|
img(src="/themes/wikilerni/img/email.png" alt=txtQuestionnaire.btnShareQuizTxt+"mail")
|
|
|
|
a(href="http://sharetodiaspora.github.io/?url="+linkCanonical+"&title="+questionnaire.Questionnaire.title rel="nofollow noopener" title=txtQuestionnaire.btnShareQuizTxt+"diaspora* ("+txtGeneral.alertNewWindow+")" target="_blank")
|
|
|
|
img(src="/themes/wikilerni/img/diaspora.png" alt=txtQuestionnaire.btnShareQuizTxt+"diaspora*")
|
|
|
|
a(href="https://www.facebook.com/sharer.php?u="+linkCanonical rel="nofollow noopener" title=txtQuestionnaire.btnShareQuizTxt+"facebook ("+txtGeneral.alertNewWindow+")" target="_blank")
|
|
|
|
img(src="/themes/wikilerni/img/facebook.png" alt=txtQuestionnaire.btnShareQuizTxt+"facebook")
|
|
|
|
a(href="https://www.linkedin.com/shareArticle?mini=true&url="+linkCanonical+";title="+questionnaire.Questionnaire.title rel="nofollow noopener" title=txtQuestionnaire.btnShareQuizTxt+"LinkedIn ("+txtGeneral.alertNewWindow+")" target="_blank")
|
|
|
|
img(src="/themes/wikilerni/img/linkedin.png" alt=txtQuestionnaire.btnShareQuizTxt+"LinkedIn")
|
|
|
|
a(href="https://twitter.com/intent/tweet?url="+linkCanonical+"&text="+questionnaire.Questionnaire.title+" via @"+configTpl.twitterAccount rel="nofollow noopener" title=txtQuestionnaire.btnShareQuizTxt+"twitter ("+txtGeneral.alertNewWindow+")" target="_blank")
|
2022-01-28 17:37:19 +01:00
|
|
|
img(src="/themes/wikilerni/img/twitter.png" alt=txtQuestionnaire.btnShareQuizTxt+"twitter")
|
2020-10-12 17:51:35 +02:00
|
|
|
div#explanations(class="engraved framed")
|
|
|
|
h3#explanationsTitle #{configTpl.explanationTitle}
|
|
|
|
div#explanationsContent
|
2020-11-04 10:02:04 +01:00
|
|
|
p !{configTpl.explanationElementTxt}
|
|
|
|
p
|
2020-12-07 12:55:24 +01:00
|
|
|
a(href="/"+configTpl.aboutPage class="button cardboard" title=configTpl.homeBtnAboutTxt) #{configTpl.homeBtnAboutTxt}
|