Skip to content

Commit

Permalink
feat(frontend): Parent Details Screen (#274)
Browse files Browse the repository at this point in the history
* feat(frontend): Parent Details Screen

* update date utils (#276)

* update gender field from PP in personal info screen (#282)

* chore(deps-dev): bump the dev-minor-versions group (#284)

Bumps the dev-minor-versions group in /frontend with 2 updates: [@tailwindcss/vite](https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/@tailwindcss-vite) and [tailwindcss](https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss).


Updates `@tailwindcss/vite` from 4.0.8 to 4.0.9
- [Release notes](https://github.com/tailwindlabs/tailwindcss/releases)
- [Changelog](https://github.com/tailwindlabs/tailwindcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tailwindlabs/tailwindcss/commits/v4.0.9/packages/@tailwindcss-vite)

Updates `tailwindcss` from 4.0.8 to 4.0.9
- [Release notes](https://github.com/tailwindlabs/tailwindcss/releases)
- [Changelog](https://github.com/tailwindlabs/tailwindcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tailwindlabs/tailwindcss/commits/v4.0.9/packages/tailwindcss)

---
updated-dependencies:
- dependency-name: "@tailwindcss/vite"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: dev-minor-versions
- dependency-name: tailwindcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: dev-minor-versions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* chore(deps): bump jose in /frontend in the prod-minor-versions group (#285)

Bumps the prod-minor-versions group in /frontend with 1 update: [jose](https://github.com/panva/jose).


Updates `jose` from 6.0.7 to 6.0.8
- [Release notes](https://github.com/panva/jose/releases)
- [Changelog](https://github.com/panva/jose/blob/main/CHANGELOG.md)
- [Commits](panva/jose@v6.0.7...v6.0.8)

---
updated-dependencies:
- dependency-name: jose
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: prod-minor-versions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* refactor province input in /birth-details (#283)

* fix(frontend): correctly propagage path params in `<LanguageSwitcher>` (#281)

* refactor(frontend): tweak parent-details.tsx

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: faiza-jahanzeb <95882212+faiza-jahanzeb@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Frank <48450599+Fbasham@users.noreply.github.com>
Co-authored-by: Greg Baker <48123208+gregory-j-baker@users.noreply.github.com>
Co-authored-by: Greg Baker <gregory.j.baker@hrsdc-rhdcc.gc.ca>
  • Loading branch information
6 people authored Feb 27, 2025
1 parent 94a9b02 commit f793196
Show file tree
Hide file tree
Showing 5 changed files with 570 additions and 1 deletion.
55 changes: 55 additions & 0 deletions frontend/app/.server/locales/protected-en.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,27 @@
"no-cases": "No cases are currently assigned to you.",
"coming-soon": "Coming soon"
},
"countries": {
"select-option": "Select option",
"CAN": "Canada",
"FRA": "France"
},
"provinces": {
"select-option": "Select option",
"AB": "Alberta",
"BC": "British Columbia",
"MB": "Manitoba",
"NB": "New Brunswick",
"NL": "Newfoundland and Labrador",
"NT": "Northwest Territories",
"NS": "Nova Scotia",
"NU": "Nunavut",
"ON": "Ontario",
"PE": "Prince Edward Island",
"QC": "Quebec",
"SK": "Saskatchewan",
"YT": "Yukon"
},
"in-person": {
"title": "In-person SIN request",
"description": "Process an application or amendment"
Expand Down Expand Up @@ -335,5 +356,39 @@
"required-from-multiple": "Is applicant from multiple birth is required.",
"invalid-from-multiple": "Is applicant from multiple birth is invalid."
}
},
"parent-details": {
"page-title": "Parents/legal guardians",
"section-title": "Parent/legal guardian",
"details-unavailable": "Parent/legal guardian details unavailable",
"given-name": "Given name(s)",
"last-name": "Last name at birth",
"country": "Country of birth",
"province": "Province, state, or region of birth",
"city": "City, town, or village of birth",
"add-parent": "Add a parent/legal guardian",
"remove": "Remove",
"given-name-error": {
"format-error": "Given name must not contain any digits.",
"max-length-error": "Given name must contain at most {{maximum}} character(s).",
"required-error": "Given name is required."
},
"last-name-error": {
"format-error": "Last name must not contain any digits.",
"max-length-error": "Last name must contain at most {{maximum}} character(s).",
"required-error": "Last name is required."
},
"country-error": {
"required-country": "Country of birth is required.",
"invalid-country": "Country of birth is invalid."
},
"province-error": {
"required-province": "Province, state, or region of birth is required.",
"invalid-province": "Province, state, or region of birth is invalid."
},
"city-error": {
"required-city": "City, town, or village of birth is required.",
"invalid-city": "City, town, or village of birth is invalid."
}
}
}
55 changes: 55 additions & 0 deletions frontend/app/.server/locales/protected-fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,27 @@
"no-cases": "Aucun dossier n'est actuellement assigné à vous.",
"coming-soon": "Bientôt disponible"
},
"countries": {
"select-option": "Sélectionner une option",
"CAN": "Canada",
"FRA": "France"
},
"provinces": {
"select-option": "Sélectionner une option",
"AB": "Alberta",
"BC": "Colombie-Britannique",
"MB": "Manitoba",
"NB": "Nouveau-Brunswick",
"NL": "Terre-Neuve-et-Labrador",
"NT": "Territoires du Nord-Ouest",
"NS": "Nouvelle-Écosse",
"NU": "Nunavut",
"ON": "Ontario",
"PE": "Île-du-Prince-Édouard",
"QC": "Québec",
"SK": "Saskatchewan",
"YT": "Yukon"
},
"in-person": {
"title": "Demande NAS en personne",
"description": "Traiter une demande ou une modification"
Expand Down Expand Up @@ -336,5 +357,39 @@
"required-from-multiple": "Il est requis de savoir si le demandeur fait partie d'une naissance multiple.",
"invalid-from-multiple": "Le statut de naissance multiple du demandeur est invalide."
}
},
"parent-details": {
"page-title": "Parents/tuteurs légaux",
"section-title": "Parent/tuteur légal",
"details-unavailable": "Informations sur le parent/tuteur légal non disponibles",
"given-name": "Prénom(s)",
"last-name": "Nom de naissance",
"country": "Pays de naissance",
"province": "Province, état ou région de naissance",
"city": "Ville, commune ou village de naissance",
"add-parent": "Ajouter un parent/tuteur légal",
"remove": "Supprimer",
"given-name-error": {
"format-error": "Le prénom ne doit pas contenir de chiffres.",
"max-length-error": "Le prénom ne doit pas contenir plus de {{maximum}} caractère(s).",
"required-error": "Le prénom est requis."
},
"last-name-error": {
"format-error": "Le nom de famille ne doit pas contenir de chiffres.",
"max-length-error": "Le nom de famille ne doit pas contenir plus de {{maximum}} caractère(s).",
"required-error": "Le nom de famille est requis."
},
"country-error": {
"required-country": "Le pays de naissance est requis.",
"invalid-country": "Le pays de naissance est invalide."
},
"province-error": {
"required-province": "La province, l'état ou la région de naissance est requis.",
"invalid-province": "La province, l'état ou la région de naissance est invalide."
},
"city-error": {
"required-city": "La ville, la commune ou le village de naissance est requis.",
"invalid-city": "La ville, la commune ou le village de naissance est invalide."
}
}
}
10 changes: 9 additions & 1 deletion frontend/app/i18n-routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,14 +152,22 @@ export const i18nRoutes = [
},
{
id: 'PROT-0011',
file: 'routes/protected/person-case/parent-details.tsx',
paths: {
en: '/en/protected/person-case/parent-details',
fr: '/fr/protege/cas-personnel/details-des-parents',
},
},
{
id: 'PROT-0012',
file: 'routes/protected/person-case/previous-sin.tsx',
paths: {
en: '/en/protected/person-case/previous-sin',
fr: '/fr/protege/cas-personnel/previous-sin',
},
},
{
id: 'PROT-0012',
id: 'PROT-0013',
file: 'routes/protected/person-case/contact-information.tsx',
paths: {
en: '/en/protected/person-case/contact-information',
Expand Down
19 changes: 19 additions & 0 deletions frontend/app/routes/protected/person-case/@types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,25 @@ declare module 'express-session' {
birthDetails:
| { country: ServerEnvironment['PP_CANADA_COUNTRY_CODE']; province: string; city: string; fromMultipleBirth: boolean }
| { country: string; province?: string; city?: string; fromMultipleBirth: boolean };
parentDetails: (
| { unavailable: true }
| {
unavailable: false;
givenName: string;
lastName: string;
birthLocation:
| {
country: 'CAN';
province: string;
city: string;
}
| {
country: string;
province?: string;
city?: string;
};
}
)[];
}>;
}
}
Expand Down
Loading

0 comments on commit f793196

Please sign in to comment.