-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
19386 checklist template #810
base: Sitewide-integration
Are you sure you want to change the base?
Conversation
@@ -1,38 +0,0 @@ | |||
import { render } from '@testing-library/react' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not used; all instances of are imported directly from 'next/link'
src/templates/common/link/index.tsx
Outdated
@@ -1,44 +0,0 @@ | |||
import React from 'react' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not used; all instances of are imported directly from 'next/link'
const vagovstagingsurveys = { | ||
'/search': 20, | ||
'/contact-us/virtual-agent': 26, | ||
const SURVEY_NUMBERS = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Medallia setup here was quite different from what was in content-build. It was missing the subpath string matching, so I brought over the existing logic and variables here so we don't end up with regressions.
Note: this cannot be tested fully until we get to the staging environment; it's a known limitation with the Medallia survey.
src/lib/drupal/query.ts
Outdated
@@ -135,6 +135,7 @@ export const entityBaseFields = (entity: NodeTypes): PublishedEntity => { | |||
title: entity.title, | |||
metatags: entity.metatag, | |||
breadcrumbs: entity.breadcrumbs, | |||
lastUpdated: entity.field_last_saved_by_an_editor || entity.created, | |||
lastUpdated: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Slack thread for context: https://dsva.slack.com/archives/C07B86KV4P4/p1729097328269789?thread_ts=1729096713.224239&cid=C07B86KV4P4
content-build was handling this value a little differently; next-build simplifies the implementation of the "Last updated" timestamp but still needs to consider all 3 of these fields.
@@ -12,6 +11,18 @@ export const params: QueryParams<null> = () => { | |||
]) | |||
} | |||
|
|||
const formatBeneficiariesData = (beneficiaries) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file was missing logic to handle a single object of beneficiaries rather than an array, so I added a formatter function instead.
src/data/queries/index.ts
Outdated
import * as PersonProfile from './personProfile' | ||
import * as Button from './button' | ||
import * as AudienceTopics from './audienceTopics' | ||
import * as Accordion from './accordion' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added Checklist query files and alphabetized everything else for easier reading
{paragraphs?.map((paragraph) => ( | ||
<Paragraph key={paragraph.id} {...paragraph} /> | ||
{paragraphs?.map((paragraph, index) => ( | ||
<Paragraph key={index} {...paragraph} /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was throwing a type error in the build so I adjusted the key
@@ -41,7 +41,7 @@ export const CollapsiblePanelItem = ({ | |||
<WysiwygField html={wysiwyg} /> | |||
|
|||
{paragraphs.map((paragraph, index) => { | |||
return <Paragraph key={paragraph.id} {...paragraph} /> | |||
return <Paragraph key={index} {...paragraph} /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was throwing a type error in the build so I adjusted the key
@@ -1,36 +0,0 @@ | |||
import { Meta, StoryObj } from '@storybook/react' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed all BenefitsHubLink things as it became a common component (RelatedLink(s))
@@ -1,32 +0,0 @@ | |||
import { render, screen } from '@testing-library/react' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed all BenefitsHubLink things as it became a common component (RelatedLink(s))
@@ -1,41 +0,0 @@ | |||
import { recordEvent } from '@/lib/analytics/recordEvent' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed all BenefitsHubLink things as it became a common component (RelatedLink(s))
@@ -1,13 +0,0 @@ | |||
export type BenefitsHubLink = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed all BenefitsHubLink things as it became a common component (RelatedLink(s))
render(<RateYourExperience />) | ||
|
||
const goodRatingInput = document.querySelector( | ||
'#rate-your-experience--good' | ||
const good = document.querySelector('#Good') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that web components are notoriously impregnable in unit tests, so refactoring to use those has limited our unit testing capability.
src/types/formatted/relatedLinks.ts
Outdated
@@ -0,0 +1,10 @@ | |||
export type RelatedLink = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the shared component that took the place of the BenefitHubLinks
and RelatedInformation
since they were essentially the same thing.
96c3cc6
to
4f24ef8
Compare
3f0f09c
to
846c4a6
Compare
f341c2e
to
72b188f
Compare
Tugboat has finished building the preview for this pull request! Links:
Link (redis): Dashboard: |
Description
Adds Resources & Support Checklist template.
Specifics:
data-next-template
attributes on everything in thetemplates
folder. I saw that this was partly implemented and thought it would be helpful to get it done so we can easily identify components from the browser as we developdata-
attributes that pointed specifically tocontent-build
templates to avoid confusion<Link>
componentyarn build
Design System specifics
Ticket
Developer Task
Tasks
Testing Steps
QA steps
What needs to be checked to prove this works?
What needs to be checked to prove it didn't break any related things?
What variations of circumstances (users, actions, values) need to be checked?
Screenshots
Mobile
Tablet
Desktop
Reviewer
Reviewing a PR
This section lists items that need to be checked or updated when making changes to this repository.
Standard Checks
Tasks
Merging an Approved Layout
When merging a layout, you must ensure that the content type has been turned on for
next-build
inside theCMS
. This CMS flag must be turned on for editors to preview their work using the next build preview server.Resource types (layouts) that have not been approved by design should NOT be pushed to production. Ensure that slug.tsx does not include your resource type if it is not approved.
The status of layouts should be kept up to date inside templates.md. This includes QA progress, development progress, etc. A link should be provided for where testing can occur.
Merging a Non-Approved Layout
Your new resource type should not be included inside slug.tsx. Items added here will go into production once merged into the
main
branch. It is imperative that we do not push anything live that has not been approved.Ensure that this layout has been added to the templates.md file with the current status of the work.