Are you removing, renaming or moving a folder in this PR?
[x] No, I'm not changing any folders (skip to TeamSites and delete the rest of this section)
[ ] Yes, I'm removing, renaming or moving a folder
:warning: TeamSites :warning:
Examples of a TeamSite: https://va.gov/health and https://benefits.va.gov/benefits/. This scenario is also referred to as the "injected" header and footer. You can reach out in the #sitewide-public-websites Slack channel for questions.
Did you change site-wide styles, platform utilities or other infrastructure?
[x] No
[ ] Yes, and I used the proxy-rewrite steps to test the injected header scenario
Summary
Use the Preferred name attribute that was recently added to the /v0/user API (sourced from the MPI preferred_name).
This PR:
adds preferred name to the state
updates the Welcome component to use preferredName from the /v0/user API
updates Profile link to use <a> element instead of <va-link /> component and add link click tracking by:
Google Analytics navigation with 'nav-linkslist' event,
Turn on mhvLandingPagePersonalization feature flag on mhv-landing-page/mock/api/feature-toggles/index.js
Run vets-website locally yarn watch --env entry=mhv-landing-page
Run mock apis on another terminal yarn mock-api --responses src/applications/mhv-landing-page/mocks/api/index.js
Navigate to MHV Landing Page and verify that preferred name is shown correctly
Inspect network activity using Chrome devtools to verify that PreferredName attribute is returned on the user API and that personal_information API is not fetched
Screenshots
Screenshots are expected to remain the same:
Before
After
Mobile
Desktop
What areas of the site does it impact?
Adds perferredName to the user state
MHV landing page
Acceptance criteria
Quality Assurance & Testing
[x] I fixed|updated|added unit tests and integration tests for each feature (if applicable).
[x] No sensitive information (i.e. PII/credentials/internal URLs/etc.) is captured in logging, hardcoded, or specs
Are you removing, renaming or moving a folder in this PR?
:warning: TeamSites :warning:
Examples of a TeamSite: https://va.gov/health and https://benefits.va.gov/benefits/. This scenario is also referred to as the "injected" header and footer. You can reach out in the
#sitewide-public-websites
Slack channel for questions.Did you change site-wide styles, platform utilities or other infrastructure?
Summary
Use the Preferred name attribute that was recently added to the
/v0/user
API (sourced from the MPIpreferred_name
).This PR:
/v0/user
API<a>
element instead of<va-link />
component and add link click tracking by:data-dd-action-name
Related issue(s)
Testing done
updated unit tests for GA and Datadog tracking
Local testing:
mhvLandingPagePersonalization
feature flag onmhv-landing-page/mock/api/feature-toggles/index.js
yarn watch --env entry=mhv-landing-page
yarn mock-api --responses src/applications/mhv-landing-page/mocks/api/index.js
user
API and thatpersonal_information
API is not fetchedScreenshots
Screenshots are expected to remain the same:
What areas of the site does it impact?
Acceptance criteria
Quality Assurance & Testing
Error Handling
Authentication
Requested Feedback