Skip to content

Commit

Permalink
Merge pull request #664 from DTS-STN/stefan/shipped-canada-fedex-update
Browse files Browse the repository at this point in the history
Added special notice for clients shipping to states, fixed apostrophe…
  • Loading branch information
stefan-oconnell authored May 24, 2024
2 parents b4af8d7 + 7763d8d commit 1a17a57
Show file tree
Hide file tree
Showing 6 changed files with 96 additions and 28 deletions.
47 changes: 26 additions & 21 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"report:generate": "marge index.json --reportDir report --assetsDir report/assets --reportPageTitle index.html",
"test:unit": "jest",
"test:coverage": "jest --coverage --forceExit",
"prepare": "husky install",
"prepare": "husky",
"tsc:validate": "tsc --noEmit --incremental false"
},
"dependencies": {
Expand All @@ -24,14 +24,14 @@
"date-fns": "3.6.0",
"formik": "2.4.5",
"i18next": "23.11.5",
"markdown-to-jsx": "7.4.6",
"markdown-to-jsx": "7.4.7",
"next": "14.2.3",
"next-i18next": "15.3.0",
"next-seo": "6.5.0",
"pino": "8.20.0",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-focus-on": "3.9.2",
"react-focus-on": "3.9.3",
"react-i18next": "14.1.0",
"react-idle-timer": "5.7.2",
"sharp": "0.33.3",
Expand Down
2 changes: 1 addition & 1 deletion public/locales/en/expectations.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"additional-info": {
"contact-us": "<Link>Contact us</Link> only if you dont receive your documents within 6 weeks of receiving your passport.",
"contact-us": "<Link>Contact us</Link> only if you don't receive your documents within 6 weeks of receiving your passport.",
"documents-separately": "We may send your supporting documents back separately.",
"header": "Additional information"
},
Expand Down
8 changes: 7 additions & 1 deletion public/locales/en/status.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,13 @@
"mailing": "We're mailing it to you by Canada Post",
"remote-area": "If you live in a northern or remote area, it may take up to 8 business days to arrive.",
"supporting-documents": "We may send your supporting documents back separately.",
"take-up-to": "It can take up to 2 to 3 business days to arrive."
"take-up-to": "It can take up to 2 to 3 business days to arrive.",
"united-states": {
"title": "Special instructions for applicants residing in the United States",
"mailed-us": "If your passport is being mailed to the United States, it will be sent to you via FedEx.",
"supporting-documents": "You'll receive your passport and supporting documents in the same envelope.",
"contact-us": "If you don't receive your passport and supporting documents, <Link>contact us</Link>."
}
},
"shipped-fedex": {
"contact-us": "If you don't receive your passport and supporting documents, <Link>contact us</Link>.",
Expand Down
8 changes: 7 additions & 1 deletion public/locales/fr/status.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,13 @@
"mailing": "Nous vous l'envoyons par Postes Canada.",
"remote-area": "Si vous vivez dans une région au nord ou éloignée, cela pourrait prendre jusqu'à 8 jours ouvrables pour arriver.",
"supporting-documents": "Nous pourrions renvoyer vos documents fournis en support de la demande séparément.",
"take-up-to": "Cela peut prendre jusqu'à 2 à 3 jours ouvrables pour arriver."
"take-up-to": "Cela peut prendre jusqu'à 2 à 3 jours ouvrables pour arriver.",
"united-states": {
"title": "Instructions spéciales pour les requérants résidant aux États-Unis.",
"mailed-us": "Si votre passeport est envoyé aux États-Unis, il vous sera envoyé via FedEx.",
"supporting-documents": "Vous recevrez le passeport et les documents justificatifs dans la même enveloppe.",
"contact-us": "Si vous ne recevez pas votre passeport et vos documents, <Link>veuillez nous contacter</Link>."
}
},
"shipped-fedex": {
"contact-us": "Si vous ne recevez pas votre passeport et vos documents, <Link>veuillez nous contacter</Link>.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { Trans, useTranslation } from 'next-i18next'

import AlertBlock from '../AlertBlock'
import AlertSection from '../AlertSection'
import Collapse from '../Collapse'
import ExternalLink from '../ExternalLink'

export interface CheckStatusShippingCanadaPostProps {
Expand All @@ -20,7 +21,7 @@ export const CheckStatusShippingCanadaPost = ({
</h1>
<AlertBlock page="status-shipped-canada" />
<p>{t('shipped-canada-post.header')}.</p>
<AlertSection type="success">
<AlertSection className="mb-4" type="success">
<h2 data-testid="shipped-canada-post" className="h2 mt-0">
{t('shipped-canada-post.mailing')}
</h2>
Expand Down Expand Up @@ -57,6 +58,56 @@ export const CheckStatusShippingCanadaPost = ({
</>
)}
</AlertSection>
<Collapse title={t('shipped-canada-post.united-states.title')}>
<div className="mt-3 border-t">
<p className="mt-3">
{t('shipped-canada-post.united-states.mailed-us')}
</p>
{trackingNumber ? (
<>
<p>
<Trans
i18nKey="status-check-tracking.number"
ns="status"
tOptions={{ trackingNumber }}
/>
</p>
<p>
<Trans
i18nKey={'status-check-tracking.can-track'}
ns="status"
components={{
Link: (
<ExternalLink
data-gc-analytics-exempt={true}
href={t('status-check-tracking.link.fedex', {
trackingNumber: encodeURIComponent(trackingNumber),
})}
/>
),
}}
/>
</p>
</>
) : (
<></>
)}
<p>
<strong>
{t('shipped-canada-post.united-states.supporting-documents')}
</strong>
</p>
<p>
<Trans
i18nKey="shipped-canada-post.united-states.contact-us"
ns="status"
components={{
Link: <ExternalLink href={t('common:contact-us-link')} />,
}}
/>
</p>
</div>
</Collapse>
<p className="h3 mt-6">{t('shipped-canada-post.supporting-documents')}</p>
<p className="mt-6">
<Trans
Expand Down

0 comments on commit 1a17a57

Please sign in to comment.