diff --git a/__mocks__/mockStore.js b/__mocks__/mockStore.js index 28160197a9..bb06ffa723 100644 --- a/__mocks__/mockStore.js +++ b/__mocks__/mockStore.js @@ -564,15 +564,15 @@ export const error404Page = { export const homePageData = { data: { - scLabsPagev1ByPath: { + sclabsPageV1ByPath: { item: { - scId: "SCLABS-HOME-PAGE", + scId: "PAGES-HOME", scPageNameEn: "/en/home", scPageNameFr: "/fr/accueil", scTitleEn: "Service Canada Labs", scTitleFr: "Laboratoires de Service Canada", - scShortTitleEn: "Home - Service Canada Labs", - scShortTitleFr: "Accueil - Laboratoires de Service Canada", + scShortTitleEn: null, + scShortTitleFr: null, scDescriptionEn: { json: [ { @@ -609,227 +609,254 @@ export const homePageData = { scKeywordsFr: "services numériques", scContentType: null, scOwner: null, - scDateModifiedOverwrite: "2022-12-11", + scDateModifiedOverwrite: null, scAudience: null, scRegion: null, scSocialMediaImageEn: { + _path: "/content/dam/decd-endc/images/sclabs/homePage_image1.png", _publishUrl: "https://www.canada.ca/content/dam/decd-endc/images/sclabs/homePage_image1.png", width: 2932, height: 2078, }, scSocialMediaImageFr: { + _path: "/content/dam/decd-endc/images/sclabs/homePage_image1.png", _publishUrl: "https://www.canada.ca/content/dam/decd-endc/images/sclabs/homePage_image1.png", width: 2932, height: 2078, }, - scSocialMediaImageAltTextEn: null, - scSocialMediaImageAltTextFr: null, + scSocialMediaImageAltTextEn: "People adding icons to a mobile screen", + scSocialMediaImageAltTextFr: + "Personnes ajoutant des icônes à un écran mobile", scNoIndex: false, scNoFollow: false, scFragments: [ { - _path: - "/content/dam/decd-endc/content-fragments/sclabs/components/content/home---main-content", - scId: "SCLABS-HOMEPAGE-MAIN-CONTENT", - scContentEn: { - json: [ - { - nodeType: "header", - style: "h1", - content: [ - { - nodeType: "text", - value: "Service Canada Labs", - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Help us make government digital services simple and easy to use.", - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Service Canada Labs is an experimental corner of Canada.ca where we work on new ways of serving you. Here, you can explore projects in their early stages and help us improve them. We might even stop working on some ideas if we learn they’re not adding value and not meeting people’s needs. ", - }, - ], - }, - { - nodeType: "header", - style: "h2", - content: [ + _model: { + title: "SCLabs-Comp-Content-Image-v1", + }, + scId: "COMP-IMAGE-HOME-INTRO", + scLabContent: [ + { + scId: "CONTENT-HOME-MAIN", + scContentEn: { + json: [ { - nodeType: "text", - value: "Your feedback can shape tomorrow’s services", + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: "Service Canada Labs", + }, + ], }, - ], - }, - { - nodeType: "paragraph", - content: [ { - nodeType: "text", - value: "Here is how you can help:", + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Help us make government digital services simple and easy to use. ", + }, + ], }, - ], - }, - { - nodeType: "unordered-list", - content: [ { - nodeType: "list-item", + nodeType: "paragraph", content: [ { nodeType: "text", - value: "try out our projects", + value: + "Service Canada Labs is an experimental corner of Canada.ca where we work on new ways of serving you. Here, you can explore projects in their early stages and help us improve them. We might even stop working on some ideas if we learn they're not adding value and not meeting people's needs. ", + }, + { + nodeType: "line-break", + content: [], }, ], }, { - nodeType: "list-item", + nodeType: "header", + style: "h2", content: [ { nodeType: "text", - value: "give your feedback", + value: "Your feedback can shape tomorrow's services", }, ], }, - ], - }, - { - nodeType: "header", - style: "h2", - content: [ { - nodeType: "text", - value: "Explore our projects", + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "Here is how you can help:", + }, + ], }, - ], - }, - ], - }, - scContentFr: { - json: [ - { - nodeType: "header", - style: "h1", - content: [ { - nodeType: "text", - value: "Laboratoires de Service Canada", + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "try out our projects", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "provide your feedback", + }, + ], + }, + ], }, ], }, - { - nodeType: "paragraph", - content: [ + scContentFr: { + json: [ { - nodeType: "text", - value: - "Aidez-nous à rendre les services numériques gouvernementaux plus simples et faciles à utiliser.", + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: "Laboratoires de Service Canada", + }, + ], }, - ], - }, - { - nodeType: "paragraph", - content: [ { - nodeType: "text", - value: - "Les laboratoires de Service Canada sont un espace expérimental de Canada.ca où nous travaillons sur de nouvelles façons de vous servir. Vous pouvez y explorer des projets à leur stade initial et nous aider à les améliorer. Nous pourrions cesser de travailler sur certaines idées si nous découvrons qu'elles n'apportent pas de valeur ajoutée et ne répondent pas aux besoins des gens.", + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Aidez-nous à rendre les services numériques gouvernementaux plus simples et faciles à utiliser.", + }, + ], }, - ], - }, - { - nodeType: "header", - style: "h2", - content: [ { - nodeType: "text", - value: - "Vos commentaires peuvent façonner les services de demain", + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Les laboratoires de Service Canada sont un espace expérimental de Canada.ca où nous travaillons sur de nouvelles façons de vous servir. Vous pouvez y explorer des projets à leur stade initial et nous aider à les améliorer. Nous pourrions cesser de travailler sur certaines idées si nous découvrons qu'elles n'apportent pas de valeur ajoutée et ne répondent pas aux besoins des gens.", + }, + ], }, - ], - }, - { - nodeType: "paragraph", - content: [ { - nodeType: "text", - value: "Comment participer :", + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: + "Vos commentaires peuvent façonner les services de demain", + }, + ], }, - ], - }, - { - nodeType: "unordered-list", - content: [ { - nodeType: "list-item", + nodeType: "paragraph", content: [ { nodeType: "text", - value: "essayer nos projets", + value: "Comment participer :", }, ], }, { - nodeType: "list-item", + nodeType: "unordered-list", content: [ { - nodeType: "text", - value: "donner vos commentaires", + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "essayer nos projets", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "donner vos commentaires", + }, + ], }, ], }, ], }, + }, + ], + scLabImage: { + scId: "SCLABS-HOMEPAGE-IMAGE", + scImageEn: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/homePage_image1.png", + width: 2932, + height: 2078, + }, + scImageFr: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/homePage_image1.png", + width: 2932, + height: 2078, + }, + scImageMobileEn: null, + scImageMobileFr: null, + scImageAltTextEn: null, + scImageAltTextFr: null, + scImageCaptionEn: { + json: null, + }, + scImageCaptionFr: { + json: null, + }, + }, + scLabLayout: "default", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/home-explore-projects", + scId: "CONTENT-HOME-EXPLORE-PROJECTS", + scContentEn: { + json: [ { nodeType: "header", style: "h2", content: [ { nodeType: "text", - value: "Explorez nos projets", + value: "Explore our projects", }, ], }, ], }, - }, - { - scId: "SCLABS-HOMEPAGE-IMAGE", - scImageEn: { - _publishUrl: - "https://www.canada.ca/content/dam/decd-endc/images/sclabs/homePage_image1.png", - width: 2932, - height: 2078, - }, - scImageFr: { - _publishUrl: - "https://www.canada.ca/content/dam/decd-endc/images/sclabs/homePage_image1.png", - width: 2932, - height: 2078, - }, - scImageMobileEn: null, - scImageMobileFr: null, - scImageAltTextEn: null, - scImageAltTextFr: null, - scImageCaptionEn: { - json: null, - }, - scImageCaptionFr: { - json: null, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Explorez nos projets", + }, + ], + }, + ], }, }, { @@ -887,17 +914,125 @@ export const homePageData = { ], }, }, - ], - }, - }, - }, -}; - -export const experimentsData = { - data: { - scLabsPagev1List: { - items: [ - { + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/home-see-all-projects", + scId: "CONTENT-HOME-SEE-ALL-PROJECTS", + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "link", + data: { + href: "/en/projects.html", + }, + value: "See all projects", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "link", + data: { + href: "/fr/projets.html", + }, + value: "Consulter tous les projets", + }, + ], + }, + ], + }, + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/home-read-updates", + scId: "CONTENT-HOME-READ-UPDATES", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Read our latest project updates", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: + "Consultez les récentes mises à jour de nos projets", + }, + ], + }, + ], + }, + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/home-see-all-updates", + scId: "CONTENT-HOME-SEE-ALL-UPDATES", + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "link", + data: { + href: "/en/updates.html", + }, + value: "See all updates", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "link", + data: { + href: "/fr/mises-a-jour.html", + }, + value: "Consulter toutes les mises à jour", + }, + ], + }, + ], + }, + }, + ], + }, + }, + }, +}; + +export const experimentsData = { + data: { + scLabsPagev1List: { + items: [ + { _path: "/content/dam/decd-endc/content-fragments/sclabs/pages/projects/digital-centre", scId: "SCLABS-DIGITAL-CENTRE", @@ -961,11 +1096,13 @@ export const experimentsData = { _path: "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/overview.jpg", width: 2018, + height: 1000, }, scSocialMediaImageFr: { _path: "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/overview.jpg", width: 2018, + height: 1000, }, scSocialMediaImageAltTextEn: "oas benefits estimator", scSocialMediaImageAltTextFr: "estimateur des prestations de la sv", @@ -1048,11 +1185,13 @@ export const experimentsData = { _path: "/content/dam/decd-endc/images/sclabs/life-journeys/having-a-child-baby.jpg", width: 1740, + height: 1000, }, scSocialMediaImageFr: { _path: "/content/dam/decd-endc/images/sclabs/life-journeys/having-a-child-baby.jpg", width: 1740, + height: 1000, }, scSocialMediaImageAltTextEn: "having a child life journey", scSocialMediaImageAltTextFr: "parcours de vie d'avoir un enfant", @@ -1130,11 +1269,13 @@ export const experimentsData = { _path: "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/overview.jpg", width: 2018, + height: 1000, }, scSocialMediaImageFr: { _path: "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/overview.jpg", width: 2018, + height: 1000, }, scSocialMediaImageAltTextEn: "Shows a piggy bank, a calculator, a pen and a pencil", @@ -1240,10 +1381,12 @@ export const experimentsData = { scSocialMediaImageEn: { _path: "/content/dam/decd-endc/images/sclabs/virtual-assistant.png", width: 1950, + height: 1000, }, scSocialMediaImageFr: { _path: "/content/dam/decd-endc/images/sclabs/virtual-assistant.png", width: 1950, + height: 1000, }, scSocialMediaImageAltTextEn: "virtual concierge", scSocialMediaImageAltTextFr: "concierge virtuel", @@ -1291,462 +1434,1755 @@ export const experimentsData = { export const projectUpdates = { data: { - scLabsPagev1ByPath: { - item: { - scId: "WHAT-WE-LEARNED-BUILDING-THE-SERVICE-CANADA-VIRTUAL-ASSISTANT", - scPageNameEn: - "what-we-learned-building-service-canada-virtual-assistant ", - scPageNameFr: - "ce-que-nous-avons-appris-en-creant-assistant-virtuel-service-canada", - scTitleEn: - "What we learned building the Service Canada Virtual Assistant", - scTitleFr: - "Ce que nous avons appris en créant l'assistant virtuel de Service Canada", - scShortTitleEn: null, - scShortTitleFr: null, - scDescriptionEn: { - json: null, - }, - scDescriptionFr: { - json: null, - }, - scSubject: null, - scKeywordsEn: null, - scKeywordsFr: null, - scContentType: null, - scOwner: null, - scDateModifiedOverwrite: "2022-12-18", - scAudience: null, - scRegion: null, - scSocialMediaImageEn: null, - scSocialMediaImageFr: null, - scSocialMediaImageAltTextEn: null, - scSocialMediaImageAltTextFr: null, - scNoIndex: false, - scNoFollow: false, - scFragments: [ - { + sclabsPageV1List: { + items: [ + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/pages/projects/oas-benefits-estimator/project-updates/how-feedback-is-shaping-the-estimator", + scId: "HOW-FEEDBACK-SHAPING-ESTIMATOR", + scPageNameEn: + "/en/projects/oas-benefits-estimator/how-feedback-shaping", + scPageNameFr: + "/fr/projets/estimateur-prestations-sv/faconner-grace-retroaction", + scTitleEn: "How feedback is shaping the estimator", + scTitleFr: "Façonner l’estimateur grâce à la rétroaction", + scShortTitleEn: null, + scShortTitleFr: null, + scBreadcrumbParentPages: [ + { + scTitleEn: "Service Canada Labs", + scTitleFr: "Laboratoires de Service Canada", + scPageNameEn: "/en/home", + scPageNameFr: "/fr/accueil", + }, + { + scTitleEn: "Old Age Security Benefits Estimator", + scTitleFr: + "Estimateur des prestations de la Sécurité de la vieillesse", + scPageNameEn: "/en/projects/oas-benefits-estimator", + scPageNameFr: "/fr/projets/estimateur-prestations-sv", + }, + ], + scSubject: [ + "gc:subjects/gv-government-and-politics/government-services", + ], + scKeywordsEn: "feedback, benefits, estimator", + scKeywordsFr: "rétroaction, prestations, estimateur", + scContentType: [ + "gc:content-types/promotional-material-featured-articles", + ], + scOwner: ["gc:institutions/service-canada"], + scDateModifiedOverwrite: "2023-12-12", + scAudience: null, + scRegion: null, + scSocialMediaImageEn: { _path: - "/content/dam/decd-endc/content-fragments/sclabs/components/content/projects/virtual-assistant/project-updates/va-update-1-content", - scId: "VA-UPDATE-1-CONTENT", - scContentEn: { - json: [ - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "# What we learned building the Service Canada Virtual Assistant", - }, - ], + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageAltTextEn: + " Different kinds of feedback being gathered", + scSocialMediaImageAltTextFr: + " Un rassemblement de différents types de rétroaction", + scNoIndex: false, + scNoFollow: false, + scFragments: [ + { + _model: { + title: "SCLabs-Comp-Content-Image-v1", + }, + scId: "ESTIMATOR-REVIEWING-FEEDBACK", + scLabContent: [ + { + scId: "ESTIMATOR-REVIEWING-FEEDBACK", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: "How feedback is shaping the estimator ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "There are many ways to do usability research and use insights to improve client experience. In our beta phase, one of the ways we’re doing this is by collecting feedback from people who try the Old Age Security Benefits Estimator through a survey. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "About 450 visitors have sent responses. This has allowed us to analyze feedback and prioritize changes that are important to our clients. We can see what works and what doesn’t in order to refine the estimator based on their needs. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Reviewing feedback ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Every week, our product team meets for “Feedback Friday” to sort through all the new survey responses. We look at the ratings and comments people shared with us about their experience. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We then organize the survey responses by topic (this is called “affinity mapping”). This gives us a wide view of problem areas and their progression over time. If we see the same comment come up a few times, we know we should take a closer look at what we can do to resolve the issue.", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: + "Façonner l’estimateur grâce à la rétroaction ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Il y a de nombreuses façons de mener des recherches sur la convivialité et d’utiliser les résultats pour améliorer l’expérience client. Dans notre phase bêta, nous avons notamment recueilli la rétroaction des personnes qui essaient l’Estimateur des prestations de la Sécurité de la vieillesse au moyen d’un sondage. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Environ 450 visiteurs y ont répondu. Cela nous a permis d’analyser la rétroaction et de prioriser les changements qui sont importants pour nos clients. Nous pouvons voir ce qui fonctionne et ce qui ne fonctionne pas afin d’améliorer l’estimateur en fonction de leurs besoins. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Analyse de la rétroaction ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Chaque semaine, notre équipe de produit se réunit pour le ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "« v", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: "endredi rétroactio", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "n » ", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + "afin de trier toutes les nouvelles réponses au sondage. Nous regardons les évaluations et les commentaires que les gens ont partagés avec nous sur leur expérience. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous organisons ensuite les commentaires par thème (c’est ce qu’on appelle la ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "« c", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: "artographie des affinité", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "s »", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + "). Cela nous permet d’avoir une vue d’ensemble des problèmes et de leur évolution dans le temps. Si le même commentaire revient plusieurs fois, nous savons que nous devrions examiner de plus près ce que nous pouvons faire pour résoudre le problème. ", + }, + ], + }, + ], + }, }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "The Virtual Assistant is a conversational chatbot designed to help Canadians overcome challenges they may face as they apply for and receive benefits.", - }, - { - nodeType: "line-break", - content: [], - }, - ], + ], + scLabImage: { + scId: "ESTIMATOR-HOW-FEEDBACK-SHAPING", + scImageEn: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scImageFr: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scImageMobileEn: null, + scImageMobileFr: null, + scImageAltTextEn: null, + scImageAltTextFr: null, + scImageCaptionEn: { + json: null, + }, + scImageCaptionFr: { + json: null, }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: "## Why was this project important to pursue?", - }, - { - nodeType: "line-break", - content: [], - }, - ], + }, + scLabLayout: "default", + }, + { + _model: { + title: "SCLabs-Content-v1", + }, + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/projects/oas-benefits-estimator/project-updates/how-feedback-shaping-estimator/using-feedback", + scId: "ESTIMATOR-USING-FEEDBACK", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Using feedback", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "The estimator has proven to be user-friendly, but that didn't mean it was serving everyone’s needs. In fact, the initial feedback suggested there were specific things we needed to fix. Below, we show how we’ve used feedback with examples inspired by real survey responses. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Utilisation de la rétroaction", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "L’estimateur a bien montré être convivial, mais cela ne veut pas dire qu’il répondait aux besoins de tout le monde. En effet, les commentaires initiaux suggéraient qu’il y avait des choses spécifiques que nous devions corriger. Nous montrons ci-dessous comment nous avons utilisé la rétroaction à l’aide d’exemples inspirés de vraies réponses au sondage. ", + }, + ], + }, + ], + }, + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-FUTURE-ESTIMATE-COMMENT-1", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "I didn’t like having to change my birth year to get an estimate", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Je n’aimais pas devoir changer mon année de naissance pour avoir une estimation", + }, + ], + }, + ], + }, }, { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Our goal with the Virtual Assistant was to start with user needs and build a prototype that shows how a user-friendly chatbot experience could be. From there, we can work backwards to identify what else needs to be in place to make it possible.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Many chatbots surface general information, but the Virtual Assistant provides personalized support to those who are signed into their accounts.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "By automating processes that recognize problems with applications, the four chatbot prototypes can help Canadians resolve issues with their EI or OAS applications on their own instead of having to call in for support.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "## Were you able to do research with Canadians? What did you learn?", - }, - { - nodeType: "line-break", - content: [], - }, - ], + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We now generate results that give future estimates to those who aren’t eligible yet. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous générons maintenant des résultats qui donnent des estimations futures aux personnes qui ne sont pas encore admissibles. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "We were able to do usability testing on one of our early designs with actual employment insurance (EI) recipients. Research participants found the chatbot to be intuitive and easy to use.", - }, - { - nodeType: "line-break", - content: [], - }, - ], + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-DEFERRED-AMOUNT-COMMENT-2", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "It should show the benefit to deferral if I start to receive after 65", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "On devrait montrer l’avantage d’un report si je commence à recevoir après 65 ans", + }, + ], + }, + ], + }, }, { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "We're hoping that future user research will provide us with more feedback on how we could further improve the Virtual Assistant.", - }, - { - nodeType: "line-break", - content: [], - }, - ], + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We now automatically show a personalized deferred amount to everyone older than 65. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous affichons maintenant automatiquement un montant reporté personnalisé pour toutes les personnes âgées de plus de 65 ans.", + }, + ], + }, + ], + }, }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "## What has been the outcome of your work so far?", - }, - { - nodeType: "line-break", - content: [], - }, - ], + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Content-v1", + }, + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/projects/oas-benefits-estimator/project-updates/how-feedback-shaping-estimator/using-feedback-2", + scId: "ESTIMATOR-USING-FEEDBACK-2", + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Having access to feedback and being able to make quick updates has allowed us to add features like these and improve where you told us it matters most. We still have a lot of work to do and can’t address every pain point. But by grouping the feedback by topic, we can identify the most common concerns and prioritize solutions. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Here are examples of comments that represent common feedback themes and how we plan to address them: ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "En ayant accès aux commentaires et en pouvant faire des mises à jour rapides, nous avons pu ajouter des fonctionnalités comme celles-ci et améliorer ce qui était le plus important pour vous. Nous avons encore beaucoup de travail à faire et nous ne pouvons pas résoudre toutes les difficultés. Mais en regroupant les commentaires par thème, nous pouvons identifier les problèmes les plus courants et prioriser les solutions. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Voici des exemples de commentaires qui illustrent des thèmes communs de la rétroaction et comment nous comptons y répondr", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "e :", + }, + ], + data: { + class: "nowrap", + }, + }, + ], + }, + ], + }, + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-INCOME-QUESTION-COMMENT-3", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "The income question isn’t clear", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "La question du revenu n’est pas claire", + }, + ], + }, + ], + }, }, { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "We've paused work on the Virtual Assistant due to lack of funding and resources needed to address significant technical barriers to implementation.", - }, - { - nodeType: "line-break", - content: [], - }, - ], + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Our new question will clarify the types of income to include and calculate how much of your work income is exempted. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Notre nouvelle question clarifiera les types de revenus à inclure et calculera la part de votre revenu lié au travail qui est exemptée. ", + }, + ], + }, + ], + }, }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - 'For the Virtual Assistant to work, it needs to access data from many different applications. The most effective way for applications to share data is through "application programming interfaces" (APIs), which allow two programs to talk to each other.', - }, - { - nodeType: "line-break", - content: [], - }, - ], + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-ESTIMATE-COMMENT-4", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "I wasn’t given an estimate", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "Je n’ai pas reçu d’estimation", + }, + ], + }, + ], + }, }, { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Unfortunately, the technical systems in our department can't yet provide the APIs we need to build a working version of the Virtual Assistant and no one is available to work on it right now. As a result, the Virtual Assistant is on hold until it is technically possible to launch.", - }, - { - nodeType: "line-break", - content: [], - }, - ], + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’ve already added $0 amounts to estimates to remove ambiguity. We’re also going to be changing the look of the results to make information easier to find. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "Nous avons déjà ajouté des montants de ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "0 $", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + " aux estimations afin de résoudre l’ambiguïté. Nous allons également modifier la présentation des résultats pour que les informations soient plus faciles à trouver. ", + }, + ], + }, + ], + }, }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "The Virtual Assistant is a benchmark of the type of service we aim to deliver to clients in the future, and we look forward to making it a reality.", - }, - { - nodeType: "line-break", - content: [], - }, - ], + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Content-v1", + }, + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/projects/oas-benefits-estimator/project-updates/how-feedback-shaping-estimator/measuring-success", + scId: "ESTIMATOR-MEASURING-SUCCESS", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Measuring success ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "After we implement solutions, we’re able to tell if an issue has been resolved through comments and ratings. If we’ve made the right improvements, we stop seeing the issue mentioned, and the ratings start showing positive trends. This allows us to measure the success of our new features and make sure that we’ve improved our clients’ experience. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "For example, we can look at our data from before and after the 2 initial fixes mentioned above. If we compare survey ratings from July to those in October, we see that: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "20% more people felt that the tool provided the information they needed ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "15% more people said that the tool made them more aware of the benefits available to them ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "To make sure the estimator stays user-friendly as it evolves, we’re also tracking its ease of use, which has stayed roughly the same at 80%. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "By looking at comments and analytics together, we can see how the changes were received and which pain points are resolved. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "What we’re doing next ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’ll keep monitoring our success indicators as we release updated versions of the estimator. In the meantime, keep sending us comments about your experience. We’re listening! ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Mesure du succès ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Après avoir mis en œuvre des solutions, nous pouvons savoir si un problème a été réglé grâce aux commentaires et aux évaluations. Si nous avons apporté les bonnes améliorations, le problème n’est plus mentionné et les évaluations montrent des tendances positives. Cela nous permet de mesurer le succès de nos nouvelles fonctionnalités et de nous assurer que nous avons amélioré l’expérience de nos clients. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Par exemple, nous pouvons regarder nos données avant et après les ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "2 premières", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + " corrections mentionnées ci-dessus. Si nous comparons les résultats du sondage de juillet à ceux d'octobre, nous constatons que : ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "20 % plus de personnes ont trouvé que l’outil leur avait fourni les informations recherchées; ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "15 % plus de personnes ont indiqué que l'outil les avait renseignés sur les prestations qui leur sont offertes. ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Pour nous assurer que l’estimateur reste convivial à mesure qu’il évolue, nous surveillons également sa facilité d'utilisation, qui est restée stable à environ ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "80 %", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: ". ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "En tenant compte à la fois des commentaires et des données analytiques, nous pouvons voir comment les changements ont été reçus et quelles sources de difficultés ont été éliminées. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Ce qui nous attend ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous surveillerons nos indicateurs de succès à mesure que nous publierons de nouvelles versions de l'estimateur. Entre-temps, continuez à nous envoyer des commentaires sur votre expérience. Nous sommes à l'écoute! ", + }, + ], + }, + ], + }, + }, + ], + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/pages/projects/oas-benefits-estimator/project-updates/what-we-learned", + scId: "WHAT-WE-LEARNED", + scPageNameEn: "/en/projects/oas-benefits-estimator/what-we-learned", + scPageNameFr: + "/fr/projets/estimateur-prestations-sv/ce-que-nous-avons-appris", + scTitleEn: + "What we learned on Service Canada Labs before going live on Canada.ca", + scTitleFr: + "Ce que nous avons appris dans les laboratoires avant notre lancement sur Canada.ca", + scShortTitleEn: null, + scShortTitleFr: null, + scBreadcrumbParentPages: [ + { + scTitleEn: "Service Canada Labs", + scTitleFr: "Laboratoires de Service Canada", + scPageNameEn: "/en/home", + scPageNameFr: "/fr/accueil", + }, + { + scTitleEn: "Old Age Security Benefits Estimator", + scTitleFr: + "Estimateur des prestations de la Sécurité de la vieillesse", + scPageNameEn: "/en/projects/oas-benefits-estimator", + scPageNameFr: "/fr/projets/estimateur-prestations-sv", + }, + ], + scSubject: null, + scKeywordsEn: null, + scKeywordsFr: null, + scContentType: [ + "gc:content-types/promotional-material-featured-articles", + ], + scOwner: null, + scDateModifiedOverwrite: "2023-07-02", + scAudience: null, + scRegion: null, + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageAltTextEn: "People giving feedback", + scSocialMediaImageAltTextFr: + "Personnes qui donnent de la rétroaction", + scNoIndex: false, + scNoFollow: false, + scFragments: [ + { + _model: { + title: "SCLabs-Comp-Content-Image-v1", + }, + scId: "ESTIMATOR-WHAT-WE-LEARNED", + scLabContent: [ + { + scId: "OAS-BENEFITS-ESTIMATOR-WHAT-WE-LEARNED", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: + "What we learned on Service Canada Labs before going live on Canada.ca", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "On April 12, 2023, we released an alpha version of the Old Age Security Benefits Estimator to the public. The tool was still in an early development phase, but it was working. We knew the earlier we let everyone use it, the earlier we'd get real feedback.", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Since then, over 4,000 people tried it out, and around 200 provided feedback. Here’s what we learned from the feedback collected in our alpha phase, how it’s helping us improve our tool and what’s next for our beta phase.", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Asking experts what they think ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Ideally, the estimator could save someone a trip or a call to Service Canada. That's why we wanted to know if it answered the most common questions about Old Age Security benefits. To find out, we asked Service Canada employees. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "They confirmed that the estimator was able to give answers to common questions about: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "who these benefits are for ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "how much they can expect to receive ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "when they can expect to receive a letter from Service Canada ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "They told us about other questions they get often, and if they found any missing information. Some even gave us ideas to make this tool even more useful for Canadians. We'll be assessing these during our beta phase and will use this information to continuously improve the estimator. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Using data to improve questions ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We were lucky enough to be able to use data from a similar tool while we were on Service Canada Labs. This helped us gather information about the questions we were asking. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "In alpha, entering an income in the estimator was optional. We wanted to give clients a choice. However, we realized, through our survey, that people were looking for a precise amount in the results. Only providing the maximum income to receive a benefit wasn’t enough. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "The other tool required clients to enter an income. So, we looked at their data. There was nothing to indicate that people didn’t want to do this. The question didn’t stop them from using the tool. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "To give better results, we decided to require income in our beta estimator. This way, we can provide an amount to everyone whose income qualifies, while being confident that the tool is just as easy to use. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: + "Making improvements based on client feedback ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Our main goal for the alpha phase was to get people using the tool and get as much feedback as possible. Anyone who used our tool during our alpha phase could give us their thoughts through an anonymous feedback survey. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We read all the comments and ratings and found it very valuable. Through our survey, we found out that: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "90% thought the tool was easy to use ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "73% were more aware of the benefits available to them ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Some were satisfied, some had questions, and others wanted to see different features. From the survey responses, we’ve identified the main improvements clients want to see. Many wanted: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "the ability to get an estimate from a younger age ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "more clarity about which types of income affect benefits ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "to have more information about their partner’s results ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’ve already started working on these features and other adjustments. For example, in the beta version now on Canada.ca, we’ve added more detailed and visible results for partners. We’re looking forward to having this improvement and other tweaks make the tool better for Canadians. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Share your feedback ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’re still collecting and addressing feedback! The estimator is still in active development and will be evolving to better meet your needs throughout the beta. Expect to see some changes! ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: + "Ce que nous avons appris dans les laboratoires avant notre lancement sur Canada.ca ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Le 12 avril 2023, nous avons publié une version alpha de l’Estimateur des prestations de la Sécurité de la vieillesse. L’outil était encore dans une phase de développement préliminaire, mais il fonctionnait. Nous savions que nous pourrions obtenir de la véritable rétroaction plus tôt si nous permettions à tout le monde de l’utiliser. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Depuis, plus de 4 000 personnes l’ont essayé et environ 200 ont donné leur rétroaction. Voici ce que nous avons appris des avis recueillis au cours de notre phase alpha, comment ils nous aident à améliorer notre outil et ce qui nous attend pour notre phase bêta. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Demander aux experts ce qu’ils en pensent ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Idéalement, l’estimateur pourrait épargner à quelqu’un un voyage ou un appel à Service Canada. Voilà pourquoi nous voulions savoir s’il répondait aux questions les plus fréquentes sur les prestations de la Sécurité de la vieillesse. Pour le savoir, nous avons consulté les employés de Service Canada. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Ils ont confirmé que l’estimateur répondait aux questions les plus courantes concernant : ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "à qui s’adressent ces prestations; ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "le montant qu’ils peuvent s’attendre à recevoir; ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "quand ils peuvent s’attendre à recevoir une lettre de Service Canada. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Ils nous ont fait part d’autres questions qui leur sont souvent posées et nous ont dit s’ils avaient trouvé des informations manquantes. Certains nous ont même donné des idées pour rendre cet outil encore plus utile pour la population canadienne. Nous évaluerons ces idées au cours de notre phase bêta et nous utiliserons ces informations pour continuer à améliorer l’estimateur. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: + "Utiliser des données pour améliorer les questions ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous avions la chance de pouvoir utiliser les données d’un outil similaire lorsque nous étions sur les laboratoires de Service Canada. Cela nous a permis de recueillir des informations sur nos questions. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Dans la version alpha, il était facultatif de saisir un revenu dans I’estimateur. Nous voulions donner le choix aux clients. Cependant, nous nous sommes rendu compte, grâce à notre sondage, que les gens recherchaient un montant précis dans les résultats. Indiquer le revenu maximum pour recevoir une prestation n’était pas suffisant. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "L’autre outil exigeait que les clients entrent un revenu. Nous avons donc examiné leurs données. Rien n’indiquait que les gens ne voulaient pas remplir ce champ. La question ne les empêchait pas d’utiliser l’outil. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Pour fournir de meilleurs résultats, nous avons décidé d’exiger un revenu dans notre estimateur bêta. De cette manière, nous pouvons fournir un montant à toutes les personnes dont le revenu est admissible, tout en étant assurés que l’outil est tout aussi facile à utiliser. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: + "Apporter des améliorations à partir de la rétroaction des clients ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Notre objectif principal pour la phase alpha était d’amener les gens à utiliser l’outil et de recevoir le plus de rétroaction possible. Toute personne ayant utilisé notre outil pendant la phase alpha pouvait nous faire part de ses impressions en répondant à un sondage anonyme. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous avons lu tous les commentaires et évaluations et les avons trouvés très utiles. Notre sondage nous a permis de constater que : ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "90 % ont trouvé que l’outil était facile à utiliser; ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "73 % étaient plus conscients des prestations qui leur étaient offertes. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Certains étaient satisfaits, certains avaient des questions et d’autres voulaient voir d’autres fonctionnalités. À partir des réponses au sondage, nous avons identifié les principales améliorations souhaitées par les clients. De nombreuses personnes voulaient : ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "pouvoir obtenir une estimation d’un plus jeune âge;   ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "plus de clarté sur les types de revenus qui affectent les prestations;  ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "avoir plus d’information sur les résultats de leur partenaire.   ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous avons déjà commencé à travailler sur ces fonctionnalités et sur d’autres ajustements. Par exemple, dans la version bêta actuellement disponible sur Canada.ca, nous avons ajouté des résultats plus détaillés et plus visibles pour les partenaires. Nous avons hâte de voir cette amélioration et d’autres mises à jour améliorer l’outil pour tous. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Partagez votre avis ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous continuons à recueillir et à intégrer la rétroaction! L’estimateur est encore en développement actif et évoluera pour mieux répondre à vos besoins tout au long de la version bêta. Attendez-vous à voir des changements! ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, }, ], - }, - scContentFr: { - json: [ - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "# (FR) What we learned building the Service Canada Virtual Assistant", - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "The Virtual Assistant is a conversational chatbot designed to help Canadians overcome challenges they may face as they apply for and receive benefits.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: "## Why was this project important to pursue?", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Our goal with the Virtual Assistant was to start with user needs and build a prototype that shows how a user-friendly chatbot experience could be. From there, we can work backwards to identify what else needs to be in place to make it possible.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Many chatbots surface general information, but the Virtual Assistant provides personalized support to those who are signed into their accounts.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "By automating processes that recognize problems with applications, the four chatbot prototypes can help Canadians resolve issues with their EI or OAS applications on their own instead of having to call in for support.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "## Were you able to do research with Canadians? What did you learn?", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "We were able to do usability testing on one of our early designs with actual employment insurance (EI) recipients. Research participants found the chatbot to be intuitive and easy to use.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "We're hoping that future user research will provide us with more feedback on how we could further improve the Virtual Assistant.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "## What has been the outcome of your work so far?", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "We've paused work on the Virtual Assistant due to lack of funding and resources needed to address significant technical barriers to implementation.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - 'For the Virtual Assistant to work, it needs to access data from many different applications. The most effective way for applications to share data is through "application programming interfaces" (APIs), which allow two programs to talk to each other.', - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "Unfortunately, the technical systems in our department can't yet provide the APIs we need to build a working version of the Virtual Assistant and no one is available to work on it right now. As a result, the Virtual Assistant is on hold until it is technically possible to launch.", - }, - { - nodeType: "line-break", - content: [], - }, - ], - }, - { - nodeType: "paragraph", - content: [ - { - nodeType: "text", - value: - "The Virtual Assistant is a benchmark of the type of service we aim to deliver to clients in the future, and we look forward to making it a reality.", - }, - { - nodeType: "line-break", - content: [], - }, - ], + scLabImage: { + scId: "WHAT-WE-LEARNED", + scImageEn: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scImageFr: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scImageMobileEn: null, + scImageMobileFr: null, + scImageAltTextEn: null, + scImageAltTextFr: null, + scImageCaptionEn: { + json: null, + }, + scImageCaptionFr: { + json: null, }, - ], - }, - }, - { - scId: "EXPLORE-THE-VIRTUAL-ASSISTANT", - scTitleEn: "Explore the Virtual Assistant", - scTitleFr: "Découvrez l'assistant virtuel", - scContentEn: { - json: null, - }, - scContentFr: { - json: null, + }, + scLabLayout: "default", }, - scImageEn: null, - scImageFr: null, - scImageAltTextEn: null, - scImageAltTextFr: null, - scLabsButton: [ - { - scId: "EXPLORE-THE-VIRTUAL-ASSISTANT", - scTitleEn: "Explore the Virtual Assistant", - scTitleFr: "Découvrez l'assistant virtuel", - scDestinationURLEn: "/en/projects/virtual-assistant/try-it-out", - scDestinationURLFr: "/fr/projets/assistant-virtuel/lessayer", - scButtonType: ["gc:custom/decd-endc/button-type/primary"], + { + _model: { + title: "SCLabs-Button-v1", }, - ], - }, - ], - }, + scId: "GIVE-FEEDBACK-OAS-ESTIMATOR", + scTitleEn: "Give feedback", + scTitleFr: "Fournir des commentaires", + scDestinationURLEn: + "https://srv217.services.gc.ca/ihst4/Intro.aspx?cid=74938e05-8e91-42a9-8e9d-29daf79f6fe0&lc=eng", + scDestinationURLFr: + "https://srv217.services.gc.ca/ihst4/Intro.aspx?cid=74938e05-8e91-42a9-8e9d-29daf79f6fe0&lc=fra", + scButtonType: ["gc:custom/decd-endc/button-type/secondary"], + }, + ], + }, + ], }, }, }; @@ -1755,6 +3191,13 @@ export const dictionaryData = { data: { dictionaryV1List: { items: [ + { + _path: + "/content/dam/decd-endc/content-fragments/sch/dictionary/opens-in-a-new-tab", + scId: "opens-in-a-new-tab", + scTermEn: "(Opens in a new tab)", + scTermFr: "(S'ouvre dans un nouvel onglet)", + }, { _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/all", @@ -1776,6 +3219,27 @@ export const dictionaryData = { scTermEn: "Filter by:", scTermFr: "Filtrer par :", }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/filter-by-project", + scId: "DICTIONARY-FILTER-BY-PROJECT", + scTermEn: "Filter by project", + scTermFr: "Filtrer par projet", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/filter-by-project-status", + scId: "DICTIONARY-FILTER-BY-PROJECT-STATUS", + scTermEn: "Filter by project status", + scTermFr: "Filtrer par état du projet", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/last-updated", + scId: "LAST-UPDATED", + scTermEn: "Last updated:", + scTermFr: "Dernière mise à jour :", + }, { _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/on-this-page", @@ -1801,9 +3265,16 @@ export const dictionaryData = { _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/paused", scId: "PAUSED", - scTermEn: "Paused", + scTermEn: "Paused:", scTermFr: "Interrompu :", }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/posted-on", + scId: "POSTED-ON", + scTermEn: "Posted on:", + scTermFr: "Publié le :", + }, { _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/project-stage", @@ -1811,6 +3282,13 @@ export const dictionaryData = { scTermEn: "Project stage:", scTermFr: "Phase du projet :", }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/project-updates", + scId: "PROJECT-UPDATES", + scTermEn: "Project updates", + scTermFr: "Mises à jour du projet", + }, { _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/required-information", @@ -1818,6 +3296,13 @@ export const dictionaryData = { scTermEn: "Required information", scTermFr: "Renseignements obligatoires", }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/see-all-updates-project", + scId: "DICTIONARY-SEE-ALL-UPDATES-PROJECT", + scTermEn: "See all updates about this project", + scTermFr: "Consulter toutes les mises à jour de ce projet", + }, { _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/started", @@ -1829,7 +3314,7 @@ export const dictionaryData = { _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/summary", scId: "SUMMARY", - scTermEn: "Summary", + scTermEn: "Summary:", scTermFr: "Résumé :", }, { diff --git a/__tests__/pages/home.test.js b/__tests__/pages/home.test.js index 3bb0f2c9b6..70ec73c5c0 100644 --- a/__tests__/pages/home.test.js +++ b/__tests__/pages/home.test.js @@ -5,13 +5,15 @@ import { render, screen } from "@testing-library/react"; import Home from "../../pages/home"; import { homePageData } from "../../__mocks__/mockStore"; import { experimentsData } from "../../__mocks__/mockStore"; +import { dictionaryData } from "../../__mocks__/mockStore"; describe("Home", () => { it("renders without crashing", () => { render( ); expect( diff --git a/__tests__/pages/oas-benefits-estimator.test.js b/__tests__/pages/oas-benefits-estimator.test.js index fe2a41e1d0..e3d5f88389 100644 --- a/__tests__/pages/oas-benefits-estimator.test.js +++ b/__tests__/pages/oas-benefits-estimator.test.js @@ -7,7 +7,9 @@ import { dictionaryData, oasBenefitsEstimatorData, oasUpdatesData, + experimentsData, } from "../../__mocks__/mockStore"; +import { shuffle } from "../../lib/utils/shuffle"; describe("OAS Benefits Estimator", () => { it("renders without crashing", () => { @@ -16,6 +18,7 @@ describe("OAS Benefits Estimator", () => { pageData={oasBenefitsEstimatorData.data.sclabsPageV1ByPath} updatesData={oasUpdatesData} dictionary={dictionaryData.data.dictionaryV1List} + allProjects={shuffle(experimentsData.data.scLabsPagev1List.items)} /> ); }); diff --git a/components/atoms/Link.js b/components/atoms/Link.js index 62fa643450..9cb232c53f 100644 --- a/components/atoms/Link.js +++ b/components/atoms/Link.js @@ -3,10 +3,25 @@ import PropTypes from "prop-types"; // Use this component for Footer link and use Next.js // for all links within the site -export function Link(props) { +export function Link({ + href = "#", + target = "_self", + ariaLabel, + component = "a", + linkStyle, + disabled, + lang, + locale, + onClick, + id, + dataGcAnalyticsCustomClick, + text, + abbr, + ...rest +}) { //Styling for links based on Figma Design let basicStyle = ""; - switch (props.linkStyle) { + switch (linkStyle) { case "basicStyleWithEmphasis": basicStyle = "underline text-multi-blue-blue70b font-body text-browserh5 font-bold text-mobileh5 leading-33px hover:text-multi-blue-blue50b"; @@ -37,7 +52,7 @@ export function Link(props) { break; } - const Component = props.component || "a"; + const Component = component || "a"; function onKeyDown() { true; @@ -45,62 +60,53 @@ export function Link(props) { return Component !== "a" ? ( {/* */} - - {props.text} - + {text} {/* */} - - {props.abbr} + + {abbr} ) : ( {/* */} - - {props.text} - + {text} {/* */} - - {props.abbr} + + {abbr} ); } -Link.defaultProps = { - target: "_self", - href: "#", -}; - Link.propTypes = { /** * The text that Text Link will display diff --git a/components/fragment_renderer/FragmentRender.js b/components/fragment_renderer/FragmentRender.js index 7d0d69b5d0..047f882f24 100644 --- a/components/fragment_renderer/FragmentRender.js +++ b/components/fragment_renderer/FragmentRender.js @@ -17,7 +17,7 @@ const FRAGMENTS = { "SCLabs-Image-v1": ImageWithCollapse, }; -const mapFragmentsToProps = (fragmentData, fragmentName, locale) => { +const mapFragmentsToProps = (fragmentData, fragmentName, locale, excludeH1) => { switch (fragmentName) { case "SCLabs-Feature-v1": return { @@ -63,6 +63,7 @@ const mapFragmentsToProps = (fragmentData, fragmentName, locale) => { ? fragmentData.scLabContent[0].scContentEn.json : fragmentData.scLabContent[0].scContentFr.json, layout: fragmentData.scLabLayout, + excludeH1: excludeH1, }; case "SCLabs-Comp-Content-v1": @@ -146,7 +147,8 @@ export default function FragmentRender(props) { {...mapFragmentsToProps( fragmentData, fragmentData?._model.title, - props.locale + props.locale, + props.excludeH1 )} /> ); diff --git a/components/fragment_renderer/fragment_components/BasicTextWithImage.js b/components/fragment_renderer/fragment_components/BasicTextWithImage.js index bc8c6b5528..dee67fc2b6 100644 --- a/components/fragment_renderer/fragment_components/BasicTextWithImage.js +++ b/components/fragment_renderer/fragment_components/BasicTextWithImage.js @@ -1,7 +1,14 @@ import Image from "next/image"; import TextRender from "../../text_node_renderer/TextRender"; -export default function BasicTextWithImage({ src, alt, width, height, data }) { +export default function BasicTextWithImage({ + src, + alt, + width, + height, + data, + excludeH1, +}) { return (
@@ -19,7 +26,7 @@ export default function BasicTextWithImage({ src, alt, width, height, data }) {
- +
); diff --git a/components/fragment_renderer/fragment_components/TextWithImage.js b/components/fragment_renderer/fragment_components/TextWithImage.js index 9546e51bd2..45db32e216 100644 --- a/components/fragment_renderer/fragment_components/TextWithImage.js +++ b/components/fragment_renderer/fragment_components/TextWithImage.js @@ -8,6 +8,7 @@ export default function TextWithImage({ height, data, layout, + excludeH1, }) { switch (layout) { case "default": @@ -18,6 +19,7 @@ export default function TextWithImage({ width={width} height={height} data={data} + excludeH1={excludeH1} /> ); case "image-vertical-line-content": @@ -28,6 +30,7 @@ export default function TextWithImage({ width={width} height={height} data={data} + excludeH1={excludeH1} /> ); default: diff --git a/components/molecules/Card.js b/components/molecules/Card.js index 8a2f13b006..a36cdf0b98 100644 --- a/components/molecules/Card.js +++ b/components/molecules/Card.js @@ -22,13 +22,13 @@ export const Card = (props) => {
{props.showImage ? ( -
+
{props.imgAlt} { ) : ( "" )} -

- {props.description} -

+ {props.htmlDesc ? ( + props.htmlDesc + ) : ( +

+ {props.description} +

+ )} {props.showButton ? ( { + return ( +
  • + +
  • + ); +}; + +export function ExploreProjects(props) { + //initialize props + const { locale, projects } = props; + //create cards for current projects + const displayCurrentProjects = projects.map((project) => + createCard(locale, project) + ); + return ( + //create html for "Explore other projects" section +
    +
    +

    + {locale === "en" + ? "Explore other projects" + : "Explorer d'autres projets"} +

    +
      + {/*iterate over filteredProjects array and create card for each project */} + {displayCurrentProjects} +
    +
    +
    + ); +} diff --git a/components/organisms/ExploreProjects.stories.js b/components/organisms/ExploreProjects.stories.js new file mode 100644 index 0000000000..9ff54f5178 --- /dev/null +++ b/components/organisms/ExploreProjects.stories.js @@ -0,0 +1,98 @@ +import React from "react"; +import { ExploreProjects } from "./ExploreProjects"; + +export default { + title: "Components/organisms/ExploreProjects", + component: ExploreProjects, +}; + +const Template = (args) => ; + +export const Default = Template.bind({}); + +Default.args = { + locale: "en", + projects: [ + { + scId: "First project", + scTitleEn: "First project", + scTitleFr: "First project fr", + scPageNameEn: "/en/projects/digital-standards-playbook", + scPageNameFr: "/fr/projets/guide-normes-numeriques", + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/benefits-navigator/navigator-overview.jpg", + width: 359, + height: 260, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/benefits-navigator/navigator-overview.jpg", + width: 359, + height: 260, + }, + scSocialMediaImageAltTextEn: "first alt", + scSocialMediaImageAltTextFr: "first alt fr", + scDescriptionEn: { + json: [{ content: [{ value: "first description" }] }], + }, + scDescriptionFr: { + json: [{ content: [{ value: "first description fr" }] }], + }, + }, + { + scId: "Second project", + scTitleEn: "Second project", + scTitleFr: "Second project fr", + scPageNameEn: "/en/projects/digital-standards-playbook", + scPageNameFr: "/fr/projets/guide-normes-numeriques", + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/benefits-navigator/navigator-overview.jpg", + width: 359, + height: 260, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/benefits-navigator/navigator-overview.jpg", + width: 359, + height: 260, + }, + scSocialMediaImageAltTextEn: "second alt", + scSocialMediaImageAltTextFr: "second alt fr", + scDescriptionEn: { + json: [{ content: [{ value: "second description" }] }], + }, + scDescriptionFr: { + json: [{ content: [{ value: "second description fr" }] }], + }, + }, + { + scId: "Third project", + scTitleEn: "Third project", + scTitleFr: "Third project fr", + scPageNameEn: "/en/projects/digital-standards-playbook", + scPageNameFr: "/fr/projets/guide-normes-numeriques", + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/benefits-navigator/navigator-overview.jpg", + width: 359, + height: 260, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/benefits-navigator/navigator-overview.jpg", + width: 359, + height: 260, + }, + scSocialMediaImageAltTextEn: "third alt", + scSocialMediaImageAltTextFr: "third alt fr", + scDescriptionEn: { + json: [{ content: [{ value: "third description" }] }], + }, + scDescriptionFr: { + json: [{ content: [{ value: "third description fr" }] }], + }, + }, + ], +}; diff --git a/components/organisms/ExploreProjects.test.js b/components/organisms/ExploreProjects.test.js new file mode 100644 index 0000000000..aaebe88408 --- /dev/null +++ b/components/organisms/ExploreProjects.test.js @@ -0,0 +1,33 @@ +import React from "react"; +import { render, screen } from "@testing-library/react"; +import { ExploreProjects } from "./ExploreProjects"; +import { Default } from "./ExploreProjects.stories.js"; +import { axe, toHaveNoViolations } from "jest-axe"; + +expect.extend(toHaveNoViolations); + +describe("ExploreProjects", () => { + test("renders component title and card titles with default props", async () => { + const { container } = render(); + expect(screen.getByText("Explore other projects")).toBeInTheDocument(); + expect(screen.getByText("First project")).toBeInTheDocument(); + expect(screen.getByText("Second project")).toBeInTheDocument(); + expect(screen.getByText("Third project")).toBeInTheDocument(); + const results = await axe(container); + expect(results).toHaveNoViolations(); + }); + + test("renders card images with default props", async () => { + render(); + expect(screen.getByAltText("first alt")).toBeInTheDocument(); + expect(screen.getByAltText("second alt")).toBeInTheDocument(); + expect(screen.getByAltText("third alt")).toBeInTheDocument(); + }); + + test("renders card descriptions with default props", async () => { + render(); + expect(screen.getByText("first description")).toBeInTheDocument(); + expect(screen.getByText("second description")).toBeInTheDocument(); + expect(screen.getByText("third description")).toBeInTheDocument(); + }); +}); diff --git a/components/organisms/ExploreUpdates.js b/components/organisms/ExploreUpdates.js new file mode 100644 index 0000000000..5e567ec659 --- /dev/null +++ b/components/organisms/ExploreUpdates.js @@ -0,0 +1,62 @@ +import { Link } from "../atoms/Link"; +import Card from "../molecules/Card"; + +export function ExploreUpdates({ + heading, + updatesData, + href, + linkLabel, + locale, + dictionary, +}) { + const updatesCards = updatesData.map((update) => { + return ( +
  • + + +

    + {locale === "en" ? "Project:" : "Projet :"} +

    +

    {`${update.scDateModifiedOverwrite}`}

    +
    + +

    + {locale === "en" + ? dictionary.items[11].scTermEn + : dictionary.items[11].scTermFr} +

    +

    {`${update.scDateModifiedOverwrite}`}

    +
    +
  • + } + /> + + ); + }); + + return ( +
    +
    +
    +

    {heading}

    +
      {updatesCards}
    +
    +
    + +
    +
    +
    +
    +
    + ); +} diff --git a/components/organisms/ExploreUpdates.stories.js b/components/organisms/ExploreUpdates.stories.js new file mode 100644 index 0000000000..aee7d53cf6 --- /dev/null +++ b/components/organisms/ExploreUpdates.stories.js @@ -0,0 +1,258 @@ +import React from "react"; +import { ExploreUpdates } from "./ExploreUpdates"; + +export default { + title: "Components/organisms/ExploreUpdates", + component: ExploreUpdates, +}; + +const Template = (args) => ; + +export const Default = Template.bind({}); + +Default.args = { + locale: "en", + heading: "Explore more updates", + updatesData: [ + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/pages/projects/oas-benefits-estimator/project-updates/how-feedback-is-shaping-the-estimator", + scId: "HOW-FEEDBACK-SHAPING-ESTIMATOR", + scPageNameEn: "/en/projects/oas-benefits-estimator/how-feedback-shaping", + scPageNameFr: + "/fr/projets/estimateur-prestations-sv/faconner-grace-retroaction", + scTitleEn: "How feedback is shaping the estimator", + scTitleFr: "Façonner l’estimateur grâce à la rétroaction", + scBreadcrumbParentPages: [ + { + scTitleEn: "Service Canada Labs", + scTitleFr: "Laboratoires de Service Canada", + scPageNameEn: "/en/home", + scPageNameFr: "/fr/accueil", + }, + { + scTitleEn: "Old Age Security Benefits Estimator", + scTitleFr: + "Estimateur des prestations de la Sécurité de la vieillesse", + scPageNameEn: "/en/projects/oas-benefits-estimator", + scPageNameFr: "/fr/projets/estimateur-prestations-sv", + }, + ], + scSubject: ["gc:subjects/gv-government-and-politics/government-services"], + scKeywordsEn: "feedback, benefits, estimator", + scKeywordsFr: "rétroaction, prestations, estimateur", + scContentType: [ + "gc:content-types/promotional-material-featured-articles", + ], + scOwner: ["gc:institutions/service-canada"], + scDateModifiedOverwrite: "2023-12-12", + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageAltTextEn: + " Different kinds of feedback being gathered", + scSocialMediaImageAltTextFr: + " Un rassemblement de différents types de rétroaction", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/pages/projects/oas-benefits-estimator/project-updates/what-we-learned", + scId: "WHAT-WE-LEARNED", + scPageNameEn: "/en/projects/oas-benefits-estimator/what-we-learned", + scPageNameFr: + "/fr/projets/estimateur-prestations-sv/ce-que-nous-avons-appris", + scTitleEn: + "What we learned on Service Canada Labs before going live on Canada.ca", + scTitleFr: + "Ce que nous avons appris dans les laboratoires avant notre lancement sur Canada.ca", + scBreadcrumbParentPages: [ + { + scTitleEn: "Service Canada Labs", + scTitleFr: "Laboratoires de Service Canada", + scPageNameEn: "/en/home", + scPageNameFr: "/fr/accueil", + }, + { + scTitleEn: "Old Age Security Benefits Estimator", + scTitleFr: + "Estimateur des prestations de la Sécurité de la vieillesse", + scPageNameEn: "/en/projects/oas-benefits-estimator", + scPageNameFr: "/fr/projets/estimateur-prestations-sv", + }, + ], + scContentType: [ + "gc:content-types/promotional-material-featured-articles", + ], + scDateModifiedOverwrite: "2023-07-02", + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageAltTextEn: "People giving feedback", + scSocialMediaImageAltTextFr: "Personnes qui donnent de la rétroaction", + }, + ], + dictionary: { + items: [ + { + _path: + "/content/dam/decd-endc/content-fragments/sch/dictionary/opens-in-a-new-tab", + scId: "opens-in-a-new-tab", + scTermEn: "(Opens in a new tab)", + scTermFr: "(S'ouvre dans un nouvel onglet)", + }, + { + _path: "/content/dam/decd-endc/content-fragments/sclabs/dictionary/all", + scId: "ALL", + scTermEn: "All", + scTermFr: "Tous", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/ended", + scId: "ENDED", + scTermEn: "Ended", + scTermFr: "Fin", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/filter-by", + scId: "FILTER-BY", + scTermEn: "Filter by:", + scTermFr: "Filtrer par :", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/filter-by-project", + scId: "DICTIONARY-FILTER-BY-PROJECT", + scTermEn: "Filter by project", + scTermFr: "Filtrer par projet", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/filter-by-project-status", + scId: "DICTIONARY-FILTER-BY-PROJECT-STATUS", + scTermEn: "Filter by project status", + scTermFr: "Filtrer par état du projet", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/last-updated", + scId: "LAST-UPDATED", + scTermEn: "Last updated:", + scTermFr: "Dernière mise à jour :", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/on-this-page", + scId: "ON-THIS-PAGE", + scTermEn: "On this page", + scTermFr: "Sur cette page", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/optional-information", + scId: "OPTIONAL-INFORMATION", + scTermEn: "Optional information", + scTermFr: "Renseignements optionnels", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/past-projects", + scId: "PAST-PROJECTS", + scTermEn: "Past projects", + scTermFr: "Projets antérieurs", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/paused", + scId: "PAUSED", + scTermEn: "Paused:", + scTermFr: "Interrompu :", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/posted-on", + scId: "POSTED-ON", + scTermEn: "Posted on:", + scTermFr: "Publié le :", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/project-stage", + scId: "PROJECT-STAGE", + scTermEn: "Project stage:", + scTermFr: "Phase du projet :", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/project-updates", + scId: "PROJECT-UPDATES", + scTermEn: "Project updates", + scTermFr: "Mises à jour du projet", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/required-information", + scId: "REQUIRED-INFORMATION", + scTermEn: "Required information", + scTermFr: "Renseignements obligatoires", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/see-all-updates-project", + scId: "DICTIONARY-SEE-ALL-UPDATES-PROJECT", + scTermEn: "See all updates about this project", + scTermFr: "Consulter toutes les mises à jour de ce projet", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/started", + scId: "STARTED", + scTermEn: "Started:", + scTermFr: "Début :", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/summary", + scId: "SUMMARY", + scTermEn: "Summary:", + scTermFr: "Résumé :", + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/dictionary/upcoming-projects", + scId: "UPCOMING-PROJECTS", + scTermEn: "Upcoming projects", + scTermFr: "Projets à venir", + }, + ], + }, + href: "#", + linkLabel: "See more updates", +}; diff --git a/components/organisms/ExploreUpdates.test.js b/components/organisms/ExploreUpdates.test.js new file mode 100644 index 0000000000..3c07b06699 --- /dev/null +++ b/components/organisms/ExploreUpdates.test.js @@ -0,0 +1,26 @@ +import React from "react"; +import { render, screen } from "@testing-library/react"; +import { Default } from "./ExploreUpdates.stories.js"; +import { axe, toHaveNoViolations } from "jest-axe"; +import { ExploreUpdates } from "./ExploreUpdates"; + +expect.extend(toHaveNoViolations); + +describe("ExploreUpdates", () => { + test("renders properly with default props", async () => { + const { container } = render(); + expect(screen.getByText("Explore more updates")).toBeInTheDocument(); + expect( + screen.getByText("How feedback is shaping the estimator") + ).toBeInTheDocument(); + expect( + screen.getByText( + "What we learned on Service Canada Labs before going live on Canada.ca" + ) + ).toBeInTheDocument(); + expect(screen.getAllByText("Project:")[0]).toBeInTheDocument(); + expect(screen.getAllByText("Posted on:")[0]).toBeInTheDocument(); + const results = await axe(container); + expect(results).toHaveNoViolations(); + }); +}); diff --git a/components/organisms/Footer.js b/components/organisms/Footer.js index c5367ba6ac..799b2c3ab1 100644 --- a/components/organisms/Footer.js +++ b/components/organisms/Footer.js @@ -38,7 +38,9 @@ export const Footer = ({ preFooterTitle, preFooterLink, preFooterLinkText, + contactLink = "https://www.canada.ca/en/contact.html", lang, + withMainBand = true, }) => { return (
    @@ -83,11 +85,6 @@ export const Footer = ({ ); }; -Footer.defaultProps = { - contactLink: "https://www.canada.ca/en/contact.html", - withMainBand: true, -}; - Footer.propTypes = { /** * id of this component diff --git a/components/text_node_renderer/TextRecur.jsx b/components/text_node_renderer/TextRecur.jsx index 65b679ddbb..4f449b94fb 100644 --- a/components/text_node_renderer/TextRecur.jsx +++ b/components/text_node_renderer/TextRecur.jsx @@ -1,6 +1,6 @@ import { v4 as uuid } from "uuid"; -import Header from "./nodes/Header"; +import HeaderText from "./nodes/HeaderText"; import LineBreak from "./nodes/LineBreak"; import ListItem from "./nodes/ListItem"; import OrderedList from "./nodes/OrderedList"; @@ -12,7 +12,7 @@ import Link from "./nodes/Link"; // todo: more components will like need to be added, but for now, these are the only ones returned in the aem json response const NODES = { - header: Header, + header: HeaderText, paragraph: Paragraph, link: Link, text: Text, diff --git a/components/text_node_renderer/nodes/Header.jsx b/components/text_node_renderer/nodes/HeaderText.jsx similarity index 61% rename from components/text_node_renderer/nodes/Header.jsx rename to components/text_node_renderer/nodes/HeaderText.jsx index 3547c816ef..4ab5040fc1 100644 --- a/components/text_node_renderer/nodes/Header.jsx +++ b/components/text_node_renderer/nodes/HeaderText.jsx @@ -1,8 +1,14 @@ -export default function Header(props) { +import { Heading } from "../../molecules/Heading"; + +export default function HeaderText(props) { switch (props.node.style) { case "h1": return ( -

    {props.children}

    + ); case "h2": return ( diff --git a/cypress/e2e/home.cy.js b/cypress/e2e/home.cy.js index b965fac361..158f5efd9c 100644 --- a/cypress/e2e/home.cy.js +++ b/cypress/e2e/home.cy.js @@ -14,10 +14,10 @@ describe("Home page", () => { }) it("navigates to a project page", () => { - cy.get("a[href*=benefits-navigator]").click(); + cy.get("a[href*=making-easier-get-benefits]").click(); cy.url().should( "equal", - Cypress.config().baseUrl + "/en/projects/benefits-navigator" + Cypress.config().baseUrl + "/en/projects/making-easier-get-benefits" ); }); }); diff --git a/graphql/queries/homePageQuery.graphql b/graphql/queries/homePageQuery.graphql index 2988125776..af05f08531 100644 --- a/graphql/queries/homePageQuery.graphql +++ b/graphql/queries/homePageQuery.graphql @@ -1,6 +1,6 @@ query getHomePage { sclabsPageV1ByPath( - _path: "/content/dam/decd-endc/content-fragments/sclabs/pages/home-page" + _path: "/content/dam/decd-endc/content-fragments/sclabs/pages/home" ) { item { scId @@ -122,6 +122,77 @@ query getHomePage { json } } + ... on SclabsCompContentImageV1Model { + _model { + ... on ModelInfo { + title + } + } + scId + scLabContent { + scId + scContentEn { + json + } + scContentFr { + json + } + } + scLabImage { + ... on SclabsImageV1Model { + scId + scImageEn { + ... on ImageRef { + _publishUrl + width + height + } + ... on DocumentRef { + _publishUrl + } + } + scImageFr { + ... on ImageRef { + _publishUrl + width + height + } + ... on DocumentRef { + _publishUrl + } + } + scImageMobileEn { + ... on ImageRef { + _publishUrl + width + height + } + ... on DocumentRef { + _publishUrl + } + } + scImageMobileFr { + ... on ImageRef { + _publishUrl + width + height + } + ... on DocumentRef { + _publishUrl + } + } + scImageAltTextEn + scImageAltTextFr + scImageCaptionEn { + json + } + scImageCaptionFr { + json + } + } + } + scLabLayout + } ... on SclabsButtonV1Model { scId scTitleEn @@ -185,4 +256,4 @@ query getHomePage { } } } -} \ No newline at end of file +} diff --git a/lib/utils/filterItems.js b/lib/utils/filterItems.js new file mode 100644 index 0000000000..167eb47978 --- /dev/null +++ b/lib/utils/filterItems.js @@ -0,0 +1,9 @@ +export const filterItems = (items, activeItem) => { + //filter out current project from projects array + const filteredProjects = items.filter((currentItem) => { + return currentItem.scId !== activeItem; + }); + //slice filtered array to max length of 3 and return new array + const slicedArray = filteredProjects.slice(0, 3); + return slicedArray; +}; diff --git a/lib/utils/shuffle.js b/lib/utils/shuffle.js new file mode 100644 index 0000000000..e0f260aa05 --- /dev/null +++ b/lib/utils/shuffle.js @@ -0,0 +1,8 @@ +export const shuffle = (projects) => { + //randomize order of projects array + for (let i = projects.length - 1; i > 0; i--) { + const j = Math.floor(Math.random() * (i + 1)); + [projects[i], projects[j]] = [projects[j], projects[i]]; + } + return projects; +}; diff --git a/lib/utils/sortUpdatesByDate.js b/lib/utils/sortUpdatesByDate.js new file mode 100644 index 0000000000..86e6387b6d --- /dev/null +++ b/lib/utils/sortUpdatesByDate.js @@ -0,0 +1,5 @@ +export const sortUpdatesByDate = (array) => { + return [...array].sort((a, b) => { + return b.scDateModifiedOverwrite.localeCompare(a.scDateModifiedOverwrite); + }); +}; diff --git a/pages/_app.js b/pages/_app.js index 4e95a2f4e6..611d59e312 100644 --- a/pages/_app.js +++ b/pages/_app.js @@ -23,6 +23,9 @@ const lato = Lato({ function MyApp({ Component, pageProps }) { return ( <> + + +
    diff --git a/pages/home.js b/pages/home.js index 97beb1def4..2a67ff408a 100644 --- a/pages/home.js +++ b/pages/home.js @@ -7,10 +7,1757 @@ import aemServiceInstance from "../services/aemServiceInstance"; import { Heading } from "../components/molecules/Heading"; import { ContextualAlert } from "../components/molecules/ContextualAlert"; import Image from "next/image"; +import { Link } from "../components/atoms/Link"; +import { ExploreUpdates } from "../components/organisms/ExploreUpdates"; +import FragmentRender from "../components/fragment_renderer/FragmentRender"; +import { sortUpdatesByDate } from "../lib/utils/sortUpdatesByDate"; export default function Home(props) { const pageData = props.pageData?.item; const experimentsData = props.experimentsData; + const dictionary = props.dictionary; + const updatesData = [ + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/pages/projects/oas-benefits-estimator/project-updates/how-feedback-is-shaping-the-estimator", + scId: "HOW-FEEDBACK-SHAPING-ESTIMATOR", + scPageNameEn: "/en/projects/oas-benefits-estimator/how-feedback-shaping", + scPageNameFr: + "/fr/projets/estimateur-prestations-sv/faconner-grace-retroaction", + scTitleEn: "How feedback is shaping the estimator", + scTitleFr: "Façonner l’estimateur grâce à la rétroaction", + scShortTitleEn: null, + scShortTitleFr: null, + scBreadcrumbParentPages: [ + { + scTitleEn: "Service Canada Labs", + scTitleFr: "Laboratoires de Service Canada", + scPageNameEn: "/en/home", + scPageNameFr: "/fr/accueil", + }, + { + scTitleEn: "Old Age Security Benefits Estimator", + scTitleFr: + "Estimateur des prestations de la Sécurité de la vieillesse", + scPageNameEn: "/en/projects/oas-benefits-estimator", + scPageNameFr: "/fr/projets/estimateur-prestations-sv", + }, + ], + scSubject: ["gc:subjects/gv-government-and-politics/government-services"], + scKeywordsEn: "feedback, benefits, estimator", + scKeywordsFr: "rétroaction, prestations, estimateur", + scContentType: [ + "gc:content-types/promotional-material-featured-articles", + ], + scOwner: ["gc:institutions/service-canada"], + scDateModifiedOverwrite: "2023-12-12", + scAudience: null, + scRegion: null, + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageAltTextEn: + " Different kinds of feedback being gathered", + scSocialMediaImageAltTextFr: + " Un rassemblement de différents types de rétroaction", + scNoIndex: false, + scNoFollow: false, + scFragments: [ + { + _model: { + title: "SCLabs-Comp-Content-Image-v1", + }, + scId: "ESTIMATOR-REVIEWING-FEEDBACK", + scLabContent: [ + { + scId: "ESTIMATOR-REVIEWING-FEEDBACK", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: "How feedback is shaping the estimator ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "There are many ways to do usability research and use insights to improve client experience. In our beta phase, one of the ways we’re doing this is by collecting feedback from people who try the Old Age Security Benefits Estimator through a survey. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "About 450 visitors have sent responses. This has allowed us to analyze feedback and prioritize changes that are important to our clients. We can see what works and what doesn’t in order to refine the estimator based on their needs. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Reviewing feedback ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Every week, our product team meets for “Feedback Friday” to sort through all the new survey responses. We look at the ratings and comments people shared with us about their experience. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We then organize the survey responses by topic (this is called “affinity mapping”). This gives us a wide view of problem areas and their progression over time. If we see the same comment come up a few times, we know we should take a closer look at what we can do to resolve the issue.", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: "Façonner l’estimateur grâce à la rétroaction ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Il y a de nombreuses façons de mener des recherches sur la convivialité et d’utiliser les résultats pour améliorer l’expérience client. Dans notre phase bêta, nous avons notamment recueilli la rétroaction des personnes qui essaient l’Estimateur des prestations de la Sécurité de la vieillesse au moyen d’un sondage. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Environ 450 visiteurs y ont répondu. Cela nous a permis d’analyser la rétroaction et de prioriser les changements qui sont importants pour nos clients. Nous pouvons voir ce qui fonctionne et ce qui ne fonctionne pas afin d’améliorer l’estimateur en fonction de leurs besoins. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Analyse de la rétroaction ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Chaque semaine, notre équipe de produit se réunit pour le ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "« v", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: "endredi rétroactio", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "n » ", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + "afin de trier toutes les nouvelles réponses au sondage. Nous regardons les évaluations et les commentaires que les gens ont partagés avec nous sur leur expérience. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous organisons ensuite les commentaires par thème (c’est ce qu’on appelle la ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "« c", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: "artographie des affinité", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "s »", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + "). Cela nous permet d’avoir une vue d’ensemble des problèmes et de leur évolution dans le temps. Si le même commentaire revient plusieurs fois, nous savons que nous devrions examiner de plus près ce que nous pouvons faire pour résoudre le problème. ", + }, + ], + }, + ], + }, + }, + ], + scLabImage: { + scId: "ESTIMATOR-HOW-FEEDBACK-SHAPING", + scImageEn: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scImageFr: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/feedback.jpg", + width: 2670, + height: 1543, + }, + scImageMobileEn: null, + scImageMobileFr: null, + scImageAltTextEn: null, + scImageAltTextFr: null, + scImageCaptionEn: { + json: null, + }, + scImageCaptionFr: { + json: null, + }, + }, + scLabLayout: "default", + }, + { + _model: { + title: "SCLabs-Content-v1", + }, + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/projects/oas-benefits-estimator/project-updates/how-feedback-shaping-estimator/using-feedback", + scId: "ESTIMATOR-USING-FEEDBACK", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Using feedback", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "The estimator has proven to be user-friendly, but that didn't mean it was serving everyone’s needs. In fact, the initial feedback suggested there were specific things we needed to fix. Below, we show how we’ve used feedback with examples inspired by real survey responses. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Utilisation de la rétroaction", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "L’estimateur a bien montré être convivial, mais cela ne veut pas dire qu’il répondait aux besoins de tout le monde. En effet, les commentaires initiaux suggéraient qu’il y avait des choses spécifiques que nous devions corriger. Nous montrons ci-dessous comment nous avons utilisé la rétroaction à l’aide d’exemples inspirés de vraies réponses au sondage. ", + }, + ], + }, + ], + }, + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-FUTURE-ESTIMATE-COMMENT-1", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "I didn’t like having to change my birth year to get an estimate", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Je n’aimais pas devoir changer mon année de naissance pour avoir une estimation", + }, + ], + }, + ], + }, + }, + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We now generate results that give future estimates to those who aren’t eligible yet. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous générons maintenant des résultats qui donnent des estimations futures aux personnes qui ne sont pas encore admissibles. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + }, + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-DEFERRED-AMOUNT-COMMENT-2", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "It should show the benefit to deferral if I start to receive after 65", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "On devrait montrer l’avantage d’un report si je commence à recevoir après 65 ans", + }, + ], + }, + ], + }, + }, + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We now automatically show a personalized deferred amount to everyone older than 65. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous affichons maintenant automatiquement un montant reporté personnalisé pour toutes les personnes âgées de plus de 65 ans.", + }, + ], + }, + ], + }, + }, + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Content-v1", + }, + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/projects/oas-benefits-estimator/project-updates/how-feedback-shaping-estimator/using-feedback-2", + scId: "ESTIMATOR-USING-FEEDBACK-2", + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Having access to feedback and being able to make quick updates has allowed us to add features like these and improve where you told us it matters most. We still have a lot of work to do and can’t address every pain point. But by grouping the feedback by topic, we can identify the most common concerns and prioritize solutions. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Here are examples of comments that represent common feedback themes and how we plan to address them: ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "En ayant accès aux commentaires et en pouvant faire des mises à jour rapides, nous avons pu ajouter des fonctionnalités comme celles-ci et améliorer ce qui était le plus important pour vous. Nous avons encore beaucoup de travail à faire et nous ne pouvons pas résoudre toutes les difficultés. Mais en regroupant les commentaires par thème, nous pouvons identifier les problèmes les plus courants et prioriser les solutions. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Voici des exemples de commentaires qui illustrent des thèmes communs de la rétroaction et comment nous comptons y répondr", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "e :", + }, + ], + data: { + class: "nowrap", + }, + }, + ], + }, + ], + }, + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-INCOME-QUESTION-COMMENT-3", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "The income question isn’t clear", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "La question du revenu n’est pas claire", + }, + ], + }, + ], + }, + }, + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Our new question will clarify the types of income to include and calculate how much of your work income is exempted. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Notre nouvelle question clarifiera les types de revenus à inclure et calculera la part de votre revenu lié au travail qui est exemptée. ", + }, + ], + }, + ], + }, + }, + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Comp-Content-v1", + }, + scId: "ESTIMATOR-ESTIMATE-COMMENT-4", + scLabContent: [ + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "I wasn’t given an estimate", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "Je n’ai pas reçu d’estimation", + }, + ], + }, + ], + }, + }, + { + scContentEn: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’ve already added $0 amounts to estimates to remove ambiguity. We’re also going to be changing the look of the results to make information easier to find. ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: "Nous avons déjà ajouté des montants de ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "0 $", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + " aux estimations afin de résoudre l’ambiguïté. Nous allons également modifier la présentation des résultats pour que les informations soient plus faciles à trouver. ", + }, + ], + }, + ], + }, + }, + ], + scLabLayout: "quote", + }, + { + _model: { + title: "SCLabs-Content-v1", + }, + _path: + "/content/dam/decd-endc/content-fragments/sclabs/components/content/projects/oas-benefits-estimator/project-updates/how-feedback-shaping-estimator/measuring-success", + scId: "ESTIMATOR-MEASURING-SUCCESS", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Measuring success ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "After we implement solutions, we’re able to tell if an issue has been resolved through comments and ratings. If we’ve made the right improvements, we stop seeing the issue mentioned, and the ratings start showing positive trends. This allows us to measure the success of our new features and make sure that we’ve improved our clients’ experience. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "For example, we can look at our data from before and after the 2 initial fixes mentioned above. If we compare survey ratings from July to those in October, we see that: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "20% more people felt that the tool provided the information they needed ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "15% more people said that the tool made them more aware of the benefits available to them ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "To make sure the estimator stays user-friendly as it evolves, we’re also tracking its ease of use, which has stayed roughly the same at 80%. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "By looking at comments and analytics together, we can see how the changes were received and which pain points are resolved. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "What we’re doing next ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’ll keep monitoring our success indicators as we release updated versions of the estimator. In the meantime, keep sending us comments about your experience. We’re listening! ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Mesure du succès ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Après avoir mis en œuvre des solutions, nous pouvons savoir si un problème a été réglé grâce aux commentaires et aux évaluations. Si nous avons apporté les bonnes améliorations, le problème n’est plus mentionné et les évaluations montrent des tendances positives. Cela nous permet de mesurer le succès de nos nouvelles fonctionnalités et de nous assurer que nous avons amélioré l’expérience de nos clients. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Par exemple, nous pouvons regarder nos données avant et après les ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "2 premières", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: + " corrections mentionnées ci-dessus. Si nous comparons les résultats du sondage de juillet à ceux d'octobre, nous constatons que : ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "20 % plus de personnes ont trouvé que l’outil leur avait fourni les informations recherchées; ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "15 % plus de personnes ont indiqué que l'outil les avait renseignés sur les prestations qui leur sont offertes. ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Pour nous assurer que l’estimateur reste convivial à mesure qu’il évolue, nous surveillons également sa facilité d'utilisation, qui est restée stable à environ ", + }, + { + nodeType: "span", + content: [ + { + nodeType: "text", + value: "80 %", + }, + ], + data: { + class: "nowrap", + }, + }, + { + nodeType: "text", + value: ". ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "En tenant compte à la fois des commentaires et des données analytiques, nous pouvons voir comment les changements ont été reçus et quelles sources de difficultés ont été éliminées. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Ce qui nous attend ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous surveillerons nos indicateurs de succès à mesure que nous publierons de nouvelles versions de l'estimateur. Entre-temps, continuez à nous envoyer des commentaires sur votre expérience. Nous sommes à l'écoute! ", + }, + ], + }, + ], + }, + }, + ], + }, + { + _path: + "/content/dam/decd-endc/content-fragments/sclabs/pages/projects/oas-benefits-estimator/project-updates/what-we-learned", + scId: "WHAT-WE-LEARNED", + scPageNameEn: "/en/projects/oas-benefits-estimator/what-we-learned", + scPageNameFr: + "/fr/projets/estimateur-prestations-sv/ce-que-nous-avons-appris", + scTitleEn: + "What we learned on Service Canada Labs before going live on Canada.ca", + scTitleFr: + "Ce que nous avons appris dans les laboratoires avant notre lancement sur Canada.ca", + scShortTitleEn: null, + scShortTitleFr: null, + scBreadcrumbParentPages: [ + { + scTitleEn: "Service Canada Labs", + scTitleFr: "Laboratoires de Service Canada", + scPageNameEn: "/en/home", + scPageNameFr: "/fr/accueil", + }, + { + scTitleEn: "Old Age Security Benefits Estimator", + scTitleFr: + "Estimateur des prestations de la Sécurité de la vieillesse", + scPageNameEn: "/en/projects/oas-benefits-estimator", + scPageNameFr: "/fr/projets/estimateur-prestations-sv", + }, + ], + scSubject: null, + scKeywordsEn: null, + scKeywordsFr: null, + scContentType: [ + "gc:content-types/promotional-material-featured-articles", + ], + scOwner: null, + scDateModifiedOverwrite: "2023-07-02", + scAudience: null, + scRegion: null, + scSocialMediaImageEn: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageFr: { + _path: + "/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scSocialMediaImageAltTextEn: "People giving feedback", + scSocialMediaImageAltTextFr: "Personnes qui donnent de la rétroaction", + scNoIndex: false, + scNoFollow: false, + scFragments: [ + { + _model: { + title: "SCLabs-Comp-Content-Image-v1", + }, + scId: "ESTIMATOR-WHAT-WE-LEARNED", + scLabContent: [ + { + scId: "OAS-BENEFITS-ESTIMATOR-WHAT-WE-LEARNED", + scContentEn: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: + "What we learned on Service Canada Labs before going live on Canada.ca", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "On April 12, 2023, we released an alpha version of the Old Age Security Benefits Estimator to the public. The tool was still in an early development phase, but it was working. We knew the earlier we let everyone use it, the earlier we'd get real feedback.", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Since then, over 4,000 people tried it out, and around 200 provided feedback. Here’s what we learned from the feedback collected in our alpha phase, how it’s helping us improve our tool and what’s next for our beta phase.", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Asking experts what they think ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Ideally, the estimator could save someone a trip or a call to Service Canada. That's why we wanted to know if it answered the most common questions about Old Age Security benefits. To find out, we asked Service Canada employees. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "They confirmed that the estimator was able to give answers to common questions about: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "who these benefits are for ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "how much they can expect to receive ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "when they can expect to receive a letter from Service Canada ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "They told us about other questions they get often, and if they found any missing information. Some even gave us ideas to make this tool even more useful for Canadians. We'll be assessing these during our beta phase and will use this information to continuously improve the estimator. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Using data to improve questions ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We were lucky enough to be able to use data from a similar tool while we were on Service Canada Labs. This helped us gather information about the questions we were asking. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "In alpha, entering an income in the estimator was optional. We wanted to give clients a choice. However, we realized, through our survey, that people were looking for a precise amount in the results. Only providing the maximum income to receive a benefit wasn’t enough. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "The other tool required clients to enter an income. So, we looked at their data. There was nothing to indicate that people didn’t want to do this. The question didn’t stop them from using the tool. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "To give better results, we decided to require income in our beta estimator. This way, we can provide an amount to everyone whose income qualifies, while being confident that the tool is just as easy to use. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Making improvements based on client feedback ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Our main goal for the alpha phase was to get people using the tool and get as much feedback as possible. Anyone who used our tool during our alpha phase could give us their thoughts through an anonymous feedback survey. ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We read all the comments and ratings and found it very valuable. Through our survey, we found out that: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "90% thought the tool was easy to use ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "73% were more aware of the benefits available to them ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Some were satisfied, some had questions, and others wanted to see different features. From the survey responses, we’ve identified the main improvements clients want to see. Many wanted: ", + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "the ability to get an estimate from a younger age ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "more clarity about which types of income affect benefits ", + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "to have more information about their partner’s results ", + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’ve already started working on these features and other adjustments. For example, in the beta version now on Canada.ca, we’ve added more detailed and visible results for partners. We’re looking forward to having this improvement and other tweaks make the tool better for Canadians. ", + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Share your feedback ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "We’re still collecting and addressing feedback! The estimator is still in active development and will be evolving to better meet your needs throughout the beta. Expect to see some changes! ", + }, + ], + }, + ], + }, + scContentFr: { + json: [ + { + nodeType: "header", + style: "h1", + content: [ + { + nodeType: "text", + value: + "Ce que nous avons appris dans les laboratoires avant notre lancement sur Canada.ca ", + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Le 12 avril 2023, nous avons publié une version alpha de l’Estimateur des prestations de la Sécurité de la vieillesse. L’outil était encore dans une phase de développement préliminaire, mais il fonctionnait. Nous savions que nous pourrions obtenir de la véritable rétroaction plus tôt si nous permettions à tout le monde de l’utiliser. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Depuis, plus de 4 000 personnes l’ont essayé et environ 200 ont donné leur rétroaction. Voici ce que nous avons appris des avis recueillis au cours de notre phase alpha, comment ils nous aident à améliorer notre outil et ce qui nous attend pour notre phase bêta. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Demander aux experts ce qu’ils en pensent ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Idéalement, l’estimateur pourrait épargner à quelqu’un un voyage ou un appel à Service Canada. Voilà pourquoi nous voulions savoir s’il répondait aux questions les plus fréquentes sur les prestations de la Sécurité de la vieillesse. Pour le savoir, nous avons consulté les employés de Service Canada. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Ils ont confirmé que l’estimateur répondait aux questions les plus courantes concernant : ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: "à qui s’adressent ces prestations; ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "le montant qu’ils peuvent s’attendre à recevoir; ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "quand ils peuvent s’attendre à recevoir une lettre de Service Canada. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Ils nous ont fait part d’autres questions qui leur sont souvent posées et nous ont dit s’ils avaient trouvé des informations manquantes. Certains nous ont même donné des idées pour rendre cet outil encore plus utile pour la population canadienne. Nous évaluerons ces idées au cours de notre phase bêta et nous utiliserons ces informations pour continuer à améliorer l’estimateur. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: + "Utiliser des données pour améliorer les questions ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous avions la chance de pouvoir utiliser les données d’un outil similaire lorsque nous étions sur les laboratoires de Service Canada. Cela nous a permis de recueillir des informations sur nos questions. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Dans la version alpha, il était facultatif de saisir un revenu dans I’estimateur. Nous voulions donner le choix aux clients. Cependant, nous nous sommes rendu compte, grâce à notre sondage, que les gens recherchaient un montant précis dans les résultats. Indiquer le revenu maximum pour recevoir une prestation n’était pas suffisant. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "L’autre outil exigeait que les clients entrent un revenu. Nous avons donc examiné leurs données. Rien n’indiquait que les gens ne voulaient pas remplir ce champ. La question ne les empêchait pas d’utiliser l’outil. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Pour fournir de meilleurs résultats, nous avons décidé d’exiger un revenu dans notre estimateur bêta. De cette manière, nous pouvons fournir un montant à toutes les personnes dont le revenu est admissible, tout en étant assurés que l’outil est tout aussi facile à utiliser. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: + "Apporter des améliorations à partir de la rétroaction des clients ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Notre objectif principal pour la phase alpha était d’amener les gens à utiliser l’outil et de recevoir le plus de rétroaction possible. Toute personne ayant utilisé notre outil pendant la phase alpha pouvait nous faire part de ses impressions en répondant à un sondage anonyme. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous avons lu tous les commentaires et évaluations et les avons trouvés très utiles. Notre sondage nous a permis de constater que : ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "90 % ont trouvé que l’outil était facile à utiliser; ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "73 % étaient plus conscients des prestations qui leur étaient offertes. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Certains étaient satisfaits, certains avaient des questions et d’autres voulaient voir d’autres fonctionnalités. À partir des réponses au sondage, nous avons identifié les principales améliorations souhaitées par les clients. De nombreuses personnes voulaient : ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "unordered-list", + content: [ + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "pouvoir obtenir une estimation d’un plus jeune âge;   ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "plus de clarté sur les types de revenus qui affectent les prestations;  ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "list-item", + content: [ + { + nodeType: "text", + value: + "avoir plus d’information sur les résultats de leur partenaire.   ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous avons déjà commencé à travailler sur ces fonctionnalités et sur d’autres ajustements. Par exemple, dans la version bêta actuellement disponible sur Canada.ca, nous avons ajouté des résultats plus détaillés et plus visibles pour les partenaires. Nous avons hâte de voir cette amélioration et d’autres mises à jour améliorer l’outil pour tous. ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "header", + style: "h2", + content: [ + { + nodeType: "text", + value: "Partagez votre avis ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + { + nodeType: "paragraph", + content: [ + { + nodeType: "text", + value: + "Nous continuons à recueillir et à intégrer la rétroaction! L’estimateur est encore en développement actif et évoluera pour mieux répondre à vos besoins tout au long de la version bêta. Attendez-vous à voir des changements! ", + }, + { + nodeType: "line-break", + content: [], + }, + ], + }, + ], + }, + }, + ], + scLabImage: { + scId: "WHAT-WE-LEARNED", + scImageEn: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scImageFr: { + _publishUrl: + "https://www.canada.ca/content/dam/decd-endc/images/sclabs/oas-benefits-estimator/what-we-learned.jpg", + width: 2670, + height: 1543, + }, + scImageMobileEn: null, + scImageMobileFr: null, + scImageAltTextEn: null, + scImageAltTextFr: null, + scImageCaptionEn: { + json: null, + }, + scImageCaptionFr: { + json: null, + }, + }, + scLabLayout: "default", + }, + { + _model: { + title: "SCLabs-Button-v1", + }, + scId: "GIVE-FEEDBACK-OAS-ESTIMATOR", + scTitleEn: "Give feedback", + scTitleFr: "Fournir des commentaires", + scDestinationURLEn: + "https://srv217.services.gc.ca/ihst4/Intro.aspx?cid=74938e05-8e91-42a9-8e9d-29daf79f6fe0&lc=eng", + scDestinationURLFr: + "https://srv217.services.gc.ca/ihst4/Intro.aspx?cid=74938e05-8e91-42a9-8e9d-29daf79f6fe0&lc=fra", + scButtonType: ["gc:custom/decd-endc/button-type/secondary"], + }, + ], + }, + ]; const currentProjects = experimentsData.filter((project) => { return ( @@ -35,9 +1782,11 @@ export default function Home(props) { } // Sort the objects based on the lookup - return objects.sort((a, b) => { + const sorted = objects.sort((a, b) => { return titleOrder[a.scTitleEn] - titleOrder[b.scTitleEn]; }); + // Trim to first 3 projects + return sorted.slice(0, 3); }; const displayCurrentProjects = sortedProjects(currentProjects).map( @@ -248,93 +1997,17 @@ export default function Home(props) { } /> -
    -
    -
    - -
    -

    - {props.locale === "en" - ? pageData.scFragments[0].scContentEn.json[1].content[0].value - : pageData.scFragments[0].scContentFr.json[1].content[0].value} -

    -

    - {props.locale === "en" - ? pageData.scFragments[0].scContentEn.json[2].content[0].value - : pageData.scFragments[0].scContentFr.json[2].content[0].value} -

    -
    -
    - - - -
    -
    -
    -
    - -

    - {props.locale === "en" - ? pageData.scFragments[0].scContentEn.json[3].content[0].value - : pageData.scFragments[0].scContentFr.json[3].content[0] - .value}{" "} -

    -

    - {props.locale === "en" - ? pageData.scFragments[0].scContentEn.json[4].content[0].value - : pageData.scFragments[0].scContentFr.json[4].content[0] - .value}{" "} -

    -
      -
    • -

      - {props.locale === "en" - ? pageData.scFragments[0].scContentEn.json[5].content[0] - .content[0].value - : pageData.scFragments[0].scContentFr.json[5].content[0] - .content[0].value}{" "} -

      -
    • -
    • -

      - {props.locale === "en" - ? pageData.scFragments[0].scContentEn.json[5].content[1] - .content[0].value - : pageData.scFragments[0].scContentFr.json[5].content[1] - .content[0].value}{" "} -

      -
    • -
    -
    -
    +
    + +
    +

    {props.locale === "en" - ? pageData.scFragments[0].scContentEn.json[6].content[0].value - : pageData.scFragments[0].scContentFr.json[6].content[0] + ? pageData.scFragments[1].scContentEn.json[0].content[0].value + : pageData.scFragments[1].scContentFr.json[0].content[0] .value}{" "}

    @@ -399,9 +2072,55 @@ export default function Home(props) { } />
    -
      - {displayCurrentProjects} -
    +
    +
      + {displayCurrentProjects} +
    +
    + +
    +
    +
    +
    +
    @@ -415,6 +2134,13 @@ export const getStaticProps = async ({ locale }) => { const { data: experimentsData } = await aemServiceInstance.getFragment( "projectQuery" ); + // const { data: updatesData } = await aemServiceInstance.getFragment( + // "updatesQuery" + // ) + // get dictionary + const { data: dictionary } = await aemServiceInstance.getFragment( + "dictionaryQuery" + ); return { props: { @@ -422,6 +2148,8 @@ export const getStaticProps = async ({ locale }) => { adobeAnalyticsUrl: process.env.ADOBE_ANALYTICS_URL ?? null, pageData: pageData.sclabsPageV1ByPath, experimentsData: experimentsData.sclabsPageV1List.items, + // updatesData: + dictionary: dictionary.dictionaryV1List, ...(await serverSideTranslations(locale, ["common"])), }, revalidate: process.env.ISR_ENABLED === "true" ? 10 : false, diff --git a/pages/projects/benefits-navigator/[id].js b/pages/projects/benefits-navigator/[id].js index 0dd14f4522..98e955b7ec 100644 --- a/pages/projects/benefits-navigator/[id].js +++ b/pages/projects/benefits-navigator/[id].js @@ -7,8 +7,11 @@ import { getAllUpdateIds } from "../../../lib/utils/getAllUpdateIds"; import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import FragmentRender from "../../../components/fragment_renderer/FragmentRender"; import { Heading } from "../../../components/molecules/Heading"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; -export default function BenefitNavigatorArticles(props) { +export default function BenefitNavigatorArticles({ key, ...props }) { const [pageData] = useState(props.pageData); const [dictionary] = useState(props.dictionary.items); @@ -75,9 +78,38 @@ export default function BenefitNavigatorArticles(props) {
    + {filterItems(props.updatesData, pageData.scId).length !== 0 ? ( + + ) : null} ); @@ -99,14 +131,14 @@ export async function getStaticPaths() { export const getStaticProps = async ({ locale, params }) => { // Get pages data - const { data } = await aemServiceInstance.getFragment( + const { data: updatesData } = await aemServiceInstance.getFragment( "benefitsNavigatorArticlesQuery" ); // get dictionary const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); - const pages = data.sclabsPageV1List.items; + const pages = updatesData.sclabsPageV1List.items; // Return page data that matches the current page being built const pageData = pages.filter((page) => { return ( @@ -124,8 +156,10 @@ export const getStaticProps = async ({ locale, params }) => { return { props: { + key: params.id, locale: locale, pageData: pageData[0], + updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, adobeAnalyticsUrl: process.env.ADOBE_ANALYTICS_URL ?? null, ...(await serverSideTranslations(locale, ["common", "vc"])), diff --git a/pages/projects/benefits-navigator/index.js b/pages/projects/benefits-navigator/index.js index 1c25e60c2f..120d0f1827 100644 --- a/pages/projects/benefits-navigator/index.js +++ b/pages/projects/benefits-navigator/index.js @@ -4,16 +4,20 @@ import { Layout } from "../../../components/organisms/Layout"; import { useEffect, useState } from "react"; import aemServiceInstance from "../../../services/aemServiceInstance"; import { ProjectInfo } from "../../../components/atoms/ProjectInfo"; -import Card from "../../../components/molecules/Card"; import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import { Heading } from "../../../components/molecules/Heading"; import { Collapse } from "../../../components/molecules/Collapse"; -import { generateCollapseElements } from "../../../lib/utils/generateCollapseElements"; import Image from "next/image"; import stageDictionary from "../../../lib/utils/stageDictionary"; +import { ExploreProjects } from "../../../components/organisms/ExploreProjects"; import TextRender from "../../../components/text_node_renderer/TextRender"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { shuffle } from "../../../lib/utils/shuffle"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; export default function BenefitsNavigatorOverview(props) { + const [allProjects] = useState(props.allProjects); const [pageData] = useState(props.pageData.item); const [updatesData] = useState(props.updatesData); const [filteredDictionary] = useState( @@ -26,33 +30,6 @@ export default function BenefitsNavigatorOverview(props) { ) ); - const displayProjectUpdates = updatesData.map((update) => ( -
  • - -
  • - )); - useEffect(() => { if (props.adobeAnalyticsUrl) { window.adobeDataLayer = window.adobeDataLayer || []; @@ -237,7 +214,7 @@ export default function BenefitsNavigatorOverview(props) { /> -
    +
    @@ -352,22 +329,22 @@ export default function BenefitsNavigatorOverview(props) { ? pageData.scFragments[3].scContentEn.json[2].content[0].value : pageData.scFragments[3].scContentFr.json[2].content[0].value}

    -
      -
    • +
        +
      • {props.locale === "en" ? pageData.scFragments[3].scContentEn.json[3].content[0] .content[0].value : pageData.scFragments[3].scContentFr.json[3].content[0] .content[0].value}
      • -
      • +
      • {props.locale === "en" ? pageData.scFragments[3].scContentEn.json[3].content[1] .content[0].value : pageData.scFragments[3].scContentFr.json[3].content[1] .content[0].value}
      • -
      • +
      • {props.locale === "en" ? pageData.scFragments[3].scContentEn.json[3].content[2] .content[0].value @@ -622,17 +599,36 @@ export default function BenefitsNavigatorOverview(props) {

    - - {/* Todo: add locale files and use i18next for translations */} -

    - {props.locale === "en" - ? "Project updates" - : "Mises à jour du projet"} -

    -
      - {displayProjectUpdates} -
    + {props.updatesData.length !== 0 ? ( + + ) : null} + ); @@ -651,6 +647,10 @@ export const getStaticProps = async ({ locale }) => { const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); + // get all projects data + const { data: allProjects } = await aemServiceInstance.getFragment( + "projectQuery" + ); return { props: { @@ -659,6 +659,7 @@ export const getStaticProps = async ({ locale }) => { pageData: pageData.sclabsPageV1ByPath, updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, + allProjects: shuffle(allProjects.sclabsPageV1List.items), ...(await serverSideTranslations(locale, ["common"])), }, revalidate: process.env.ISR_ENABLED === "true" ? 10 : false, diff --git a/pages/projects/dashboard/[id].js b/pages/projects/dashboard/[id].js index 94a5b8ed4a..02ac4a1c4e 100644 --- a/pages/projects/dashboard/[id].js +++ b/pages/projects/dashboard/[id].js @@ -7,8 +7,11 @@ import { getAllUpdateIds } from "../../../lib/utils/getAllUpdateIds"; import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import FragmentRender from "../../../components/fragment_renderer/FragmentRender"; import { Heading } from "../../../components/molecules/Heading"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; -export default function MscaDashboardArticles(props) { +export default function MscaDashboardArticles({ key, ...props }) { const [pageData] = useState(props.pageData); const [dictionary] = useState(props.dictionary.items); @@ -75,9 +78,37 @@ export default function MscaDashboardArticles(props) {
    + {filterItems(props.updatesData, pageData.scId).length !== 0 ? ( + + ) : null} ); @@ -99,14 +130,14 @@ export async function getStaticPaths() { export const getStaticProps = async ({ locale, params }) => { // Get pages data - const { data } = await aemServiceInstance.getFragment( + const { data: updatesData } = await aemServiceInstance.getFragment( "getMSCADashboardArticles" ); // get dictionary const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); - const pages = data.sclabsPageV1List.items; + const pages = updatesData.sclabsPageV1List.items; // Return page data that matches the current page being built const pageData = pages.filter((page) => { return ( @@ -124,8 +155,10 @@ export const getStaticProps = async ({ locale, params }) => { return { props: { + key: params.id, locale: locale, pageData: pageData[0], + updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, adobeAnalyticsUrl: process.env.ADOBE_ANALYTICS_URL ?? null, ...(await serverSideTranslations(locale, ["common", "vc"])), diff --git a/pages/projects/dashboard/index.js b/pages/projects/dashboard/index.js index 6b67c7bbad..67b7fe748c 100644 --- a/pages/projects/dashboard/index.js +++ b/pages/projects/dashboard/index.js @@ -7,14 +7,20 @@ import { ProjectInfo } from "../../../components/atoms/ProjectInfo"; import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import { Heading } from "../../../components/molecules/Heading"; import { Collapse } from "../../../components/molecules/Collapse"; -import { generateCollapseElements } from "../../../lib/utils/generateCollapseElements"; import { ActionButton } from "../../../components/atoms/ActionButton"; import Image from "next/image"; import stageDictionary from "../../../lib/utils/stageDictionary"; import TextRender from "../../../components/text_node_renderer/TextRender"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { useState } from "react"; +import { ExploreProjects } from "../../../components/organisms/ExploreProjects"; +import { shuffle } from "../../../lib/utils/shuffle"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; export default function MscaDashboard(props) { const pageData = props.pageData?.item; + const [allProjects] = useState(props.allProjects); const filteredDictionary = props.dictionary?.items?.filter( (item) => @@ -204,7 +210,7 @@ export default function MscaDashboard(props) { /> -
    +
    @@ -323,29 +329,29 @@ export default function MscaDashboard(props) { : pageData.scFragments[3].scContentFr.json[2].content[0] .value}

    -
      -
    • +
        +
      • {props.locale === "en" ? pageData.scFragments[3].scContentEn.json[3].content[0] .content[0].value : pageData.scFragments[3].scContentFr.json[3].content[0] .content[0].value}
      • -
      • +
      • {props.locale === "en" ? pageData.scFragments[3].scContentEn.json[3].content[1] .content[0].value : pageData.scFragments[3].scContentFr.json[3].content[1] .content[0].value}
      • -
      • +
      • {props.locale === "en" ? pageData.scFragments[3].scContentEn.json[3].content[2] .content[0].value : pageData.scFragments[3].scContentFr.json[3].content[2] .content[0].value}
      • -
      • +
      • {props.locale === "en" ? pageData.scFragments[3].scContentEn.json[3].content[3] .content[0].value @@ -688,6 +694,35 @@ export default function MscaDashboard(props) {

    + {props.updatesData.length !== 0 ? ( + + ) : null} + ); @@ -698,17 +733,28 @@ export const getStaticProps = async ({ locale }) => { const { data: pageData } = await aemServiceInstance.getFragment( "getMSCADashBoardPage" ); + // get page data from AEM + const { data: updatesData } = await aemServiceInstance.getFragment( + "getMSCADashboardArticles" + ); // get dictionary const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); + // get all projects data + const { data: allProjects } = await aemServiceInstance.getFragment( + "projectQuery" + ); + return { props: { locale: locale, adobeAnalyticsUrl: process.env.ADOBE_ANALYTICS_URL ?? null, pageData: pageData.sclabsPageV1ByPath, + updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, + allProjects: shuffle(allProjects.sclabsPageV1List.items), ...(await serverSideTranslations(locale, ["common"])), }, revalidate: process.env.ISR_ENABLED === "true" ? 10 : false, diff --git a/pages/projects/digital-standards-playbook/[id].js b/pages/projects/digital-standards-playbook/[id].js index a126cd81f5..019ab5671d 100644 --- a/pages/projects/digital-standards-playbook/[id].js +++ b/pages/projects/digital-standards-playbook/[id].js @@ -8,8 +8,11 @@ import { getAllUpdateIds } from "../../../lib/utils/getAllUpdateIds"; import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import FragmentRender from "../../../components/fragment_renderer/FragmentRender"; import { Heading } from "../../../components/molecules/Heading"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; -export default function DigitalStandardsArticles(props) { +export default function DigitalStandardsArticles({ key, ...props }) { const { t } = useTranslation("common"); const [pageData] = useState(props.pageData); const [dictionary] = useState(props.dictionary.items); @@ -77,9 +80,38 @@ export default function DigitalStandardsArticles(props) {
    + {filterItems(props.updatesData, pageData.scId).length !== 0 ? ( + + ) : null} ); @@ -102,14 +134,14 @@ export async function getStaticPaths() { export const getStaticProps = async ({ locale, params }) => { // Get pages data - const { data } = await aemServiceInstance.getFragment( + const { data: updatesData } = await aemServiceInstance.getFragment( "getDigitalStandardsPlaybookArticles" ); // get dictionary const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); - const pages = data.sclabsPageV1List.items; + const pages = updatesData.sclabsPageV1List.items; // Return page data that matches the current page being built const pageData = pages.filter((page) => { return ( @@ -127,8 +159,10 @@ export const getStaticProps = async ({ locale, params }) => { return { props: { + key: params.id, locale: locale, pageData: pageData[0], + updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, adobeAnalyticsUrl: process.env.ADOBE_ANALYTICS_URL ?? null, ...(await serverSideTranslations(locale, ["common"])), diff --git a/pages/projects/digital-standards-playbook/index.js b/pages/projects/digital-standards-playbook/index.js index 856d023cc1..77c606054c 100644 --- a/pages/projects/digital-standards-playbook/index.js +++ b/pages/projects/digital-standards-playbook/index.js @@ -10,10 +10,16 @@ import { Heading } from "../../../components/molecules/Heading"; import { ActionButton } from "../../../components/atoms/ActionButton"; import Image from "next/image"; import stageDictionary from "../../../lib/utils/stageDictionary"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { ExploreProjects } from "../../../components/organisms/ExploreProjects"; +import { shuffle } from "../../../lib/utils/shuffle"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; export default function DigitalStandardsPlaybookPage(props) { const [pageData] = useState(props.pageData.item); const [updatesData] = useState(props.updatesData); + const [allProjects] = useState(props.allProjects); const filteredDictionary = props.dictionary?.items?.filter( (item) => @@ -23,33 +29,6 @@ export default function DigitalStandardsPlaybookPage(props) { item.scId === "SUMMARY" ); - const displayProjectUpdates = updatesData.map((update) => ( -
  • - -
  • - )); - useEffect(() => { if (props.adobeAnalyticsUrl) { window.adobeDataLayer = window.adobeDataLayer || []; @@ -230,7 +209,7 @@ export default function DigitalStandardsPlaybookPage(props) { /> -
    +
    @@ -441,17 +420,36 @@ export default function DigitalStandardsPlaybookPage(props) {

    -
    -

    - {props.locale === "en" - ? props.dictionary.items[11].scTermEn - : props.dictionary.items[11].scTermFr} -

    -
      - {displayProjectUpdates} -
    -
    + {props.updatesData.length !== 0 ? ( + + ) : null} + ); @@ -470,6 +468,10 @@ export const getStaticProps = async ({ locale }) => { const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); + // get all projects data + const { data: allProjects } = await aemServiceInstance.getFragment( + "projectQuery" + ); return { props: { @@ -478,6 +480,7 @@ export const getStaticProps = async ({ locale }) => { pageData: pageData.sclabsPageV1ByPath, updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, + allProjects: shuffle(allProjects.sclabsPageV1List.items), ...(await serverSideTranslations(locale, ["common"])), }, revalidate: process.env.ISR_ENABLED === "true" ? 10 : false, diff --git a/pages/projects/making-easier-get-benefits/[id].js b/pages/projects/making-easier-get-benefits/[id].js index 7270672585..0e235f520b 100644 --- a/pages/projects/making-easier-get-benefits/[id].js +++ b/pages/projects/making-easier-get-benefits/[id].js @@ -8,8 +8,11 @@ import { getAllUpdateIds } from "../../../lib/utils/getAllUpdateIds"; import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import FragmentRender from "../../../components/fragment_renderer/FragmentRender"; import { Heading } from "../../../components/molecules/Heading"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; -export default function IntegratedChannelStrategyArticles(props) { +export default function IntegratedChannelStrategyArticles({ key, ...props }) { const { t } = useTranslation("common"); const [pageData] = useState(props.pageData); const [dictionary] = useState(props.dictionary.items); @@ -77,9 +80,38 @@ export default function IntegratedChannelStrategyArticles(props) {
    + {filterItems(props.updatesData, pageData.scId).length !== 0 ? ( + + ) : null} ); @@ -102,14 +134,14 @@ export async function getStaticPaths() { export const getStaticProps = async ({ locale, params }) => { // Get pages data - const { data } = await aemServiceInstance.getFragment( + const { data: updatesData } = await aemServiceInstance.getFragment( "integratedChannelStrategyArticlesQuery" ); // get dictionary const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); - const pages = data.sclabsPageV1List.items; + const pages = updatesData.sclabsPageV1List.items; // Return page data that matches the current page being built const pageData = pages.filter((page) => { return ( @@ -127,8 +159,10 @@ export const getStaticProps = async ({ locale, params }) => { return { props: { + key: params.id, locale: locale, pageData: pageData[0], + updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, adobeAnalyticsUrl: process.env.ADOBE_ANALYTICS_URL ?? null, ...(await serverSideTranslations(locale, ["common"])), diff --git a/pages/projects/making-easier-get-benefits/index.js b/pages/projects/making-easier-get-benefits/index.js index 7de7a63da4..802ae505a5 100644 --- a/pages/projects/making-easier-get-benefits/index.js +++ b/pages/projects/making-easier-get-benefits/index.js @@ -1,7 +1,6 @@ import Head from "next/head"; import { serverSideTranslations } from "next-i18next/serverSideTranslations"; import { Layout } from "../../../components/organisms/Layout"; -import { ActionButton } from "../../../components//atoms/ActionButton"; import { useEffect, useState } from "react"; import aemServiceInstance from "../../../services/aemServiceInstance"; import { ProjectInfo } from "../../../components/atoms/ProjectInfo"; @@ -11,10 +10,16 @@ import { Heading } from "../../../components/molecules/Heading"; import TextRender from "../../../components/text_node_renderer/TextRender"; import Image from "next/image"; import stageDictionary from "../../../lib/utils/stageDictionary"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { ExploreProjects } from "../../../components/organisms/ExploreProjects"; +import { shuffle } from "../../../lib/utils/shuffle"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; export default function IntegratedChannelStrategyPage(props) { const [pageData] = useState(props.pageData.item); const [updatesData] = useState(props.updatesData); + const [allProjects] = useState(props.allProjects); const [filteredDictionary] = useState( props.dictionary.items.filter( (item) => @@ -25,33 +30,6 @@ export default function IntegratedChannelStrategyPage(props) { ) ); - const displayProjectUpdates = updatesData.map((update) => ( -
  • - -
  • - )); - useEffect(() => { if (props.adobeAnalyticsUrl) { window.adobeDataLayer = window.adobeDataLayer || []; @@ -232,7 +210,7 @@ export default function IntegratedChannelStrategyPage(props) { /> -
    +
    @@ -343,10 +321,36 @@ export default function IntegratedChannelStrategyPage(props) { />
    -
      - {displayProjectUpdates} -
    + {props.updatesData.length !== 0 ? ( + + ) : null} + ); @@ -365,6 +369,10 @@ export const getStaticProps = async ({ locale }) => { const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); + // get all projects data + const { data: allProjects } = await aemServiceInstance.getFragment( + "projectQuery" + ); return { props: { @@ -373,6 +381,7 @@ export const getStaticProps = async ({ locale }) => { pageData: pageData.sclabsPageV1ByPath, updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, + allProjects: shuffle(allProjects.sclabsPageV1List.items), ...(await serverSideTranslations(locale, ["common"])), }, revalidate: process.env.ISR_ENABLED === "true" ? 10 : false, diff --git a/pages/projects/oas-benefits-estimator/[id].js b/pages/projects/oas-benefits-estimator/[id].js index 6ab6cf1564..f1855f286f 100644 --- a/pages/projects/oas-benefits-estimator/[id].js +++ b/pages/projects/oas-benefits-estimator/[id].js @@ -8,8 +8,11 @@ import { getAllUpdateIds } from "../../../lib/utils/getAllUpdateIds"; import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import FragmentRender from "../../../components/fragment_renderer/FragmentRender"; import { Heading } from "../../../components/molecules/Heading"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; -export default function OASBenefitsEstimatorArticles(props) { +export default function OASBenefitsEstimatorArticles({ key, ...props }) { const { t } = useTranslation("common"); const [pageData] = useState(props.pageData); const [dictionary] = useState(props.dictionary.items); @@ -77,9 +80,35 @@ export default function OASBenefitsEstimatorArticles(props) {
    + {props.updatesData.length !== 0 ? ( + + ) : null} ); @@ -102,14 +131,14 @@ export async function getStaticPaths() { export const getStaticProps = async ({ locale, params }) => { // Get pages data - const { data } = await aemServiceInstance.getFragment( + const { data: updatesData } = await aemServiceInstance.getFragment( "oasBenefitsEstimatorArticlesQuery" ); // get dictionary const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); - const pages = data.sclabsPageV1List.items; + const pages = updatesData.sclabsPageV1List.items; // Return page data that matches the current page being built const pageData = pages.filter((page) => { return ( @@ -127,8 +156,12 @@ export const getStaticProps = async ({ locale, params }) => { return { props: { + key: params.id, locale: locale, pageData: pageData[0], + updatesData: sortUpdatesByDate( + filterItems(updatesData.sclabsPageV1List.items, pageData[0].scId) + ), dictionary: dictionary.dictionaryV1List, adobeAnalyticsUrl: process.env.ADOBE_ANALYTICS_URL ?? null, ...(await serverSideTranslations(locale, ["common"])), diff --git a/pages/projects/oas-benefits-estimator/index.js b/pages/projects/oas-benefits-estimator/index.js index 9c0089421e..4879557dc2 100644 --- a/pages/projects/oas-benefits-estimator/index.js +++ b/pages/projects/oas-benefits-estimator/index.js @@ -10,10 +10,16 @@ import { createBreadcrumbs } from "../../../lib/utils/createBreadcrumbs"; import { Heading } from "../../../components/molecules/Heading"; import Image from "next/image"; import stageDictionary from "../../../lib/utils/stageDictionary"; +import { ExploreUpdates } from "../../../components/organisms/ExploreUpdates"; +import { ExploreProjects } from "../../../components/organisms/ExploreProjects"; +import { shuffle } from "../../../lib/utils/shuffle"; +import { filterItems } from "../../../lib/utils/filterItems"; +import { sortUpdatesByDate } from "../../../lib/utils/sortUpdatesByDate"; export default function OasBenefitsEstimator(props) { const [pageData] = useState(props.pageData.item); const [updatesData] = useState(props.updatesData); + const [allProjects] = useState(props.allProjects); const [filteredDictionary] = useState( props.dictionary.items.filter( (item) => @@ -24,33 +30,6 @@ export default function OasBenefitsEstimator(props) { ) ); - const displayProjectUpdates = updatesData.map((update) => ( -
  • - -
  • - )); - useEffect(() => { if (props.adobeAnalyticsUrl) { window.adobeDataLayer = window.adobeDataLayer || []; @@ -231,7 +210,7 @@ export default function OasBenefitsEstimator(props) { /> -
    +
    @@ -395,15 +374,36 @@ export default function OasBenefitsEstimator(props) { ariaExpanded={props.ariaExpanded} />
    -

    - {props.locale === "en" - ? props.dictionary.items[11].scTermEn - : props.dictionary.items[11].scTermFr} -

    -
      - {displayProjectUpdates} -
    + {props.updatesData.length !== 0 ? ( + + ) : null} + ); @@ -422,6 +422,10 @@ export const getStaticProps = async ({ locale }) => { const { data: dictionary } = await aemServiceInstance.getFragment( "dictionaryQuery" ); + // get all projects data + const { data: allProjects } = await aemServiceInstance.getFragment( + "projectQuery" + ); return { props: { @@ -430,6 +434,7 @@ export const getStaticProps = async ({ locale }) => { pageData: pageData.sclabsPageV1ByPath, updatesData: updatesData.sclabsPageV1List.items, dictionary: dictionary.dictionaryV1List, + allProjects: shuffle(allProjects.sclabsPageV1List.items), ...(await serverSideTranslations(locale, ["common"])), }, revalidate: process.env.ISR_ENABLED === "true" ? 10 : false, diff --git a/tailwind.config.js b/tailwind.config.js index a1c69665b3..02b145a8de 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -135,6 +135,7 @@ module.exports = { blue70d: "#334155", blue65: "#16446C", blue65a: "#083C6C", + blue65b: "#6584A6", blue60a: "#2E5274", blue60b: "#335075", blue60c: "#2B4380", @@ -211,6 +212,7 @@ module.exports = { link: "#0535d2", text: "#335075", hover: "#083DCA", + "updates-blue": "#F0F7FF", "experiment-blue": "#004986", "projects-link": "#2B4380", "projects-link-hover": "#0535d2",