From 09ffdacfe1c86332a81c320938d30d9c44266c1a Mon Sep 17 00:00:00 2001 From: Randi Mays <19175324+randimays@users.noreply.github.com> Date: Tue, 29 Oct 2024 13:42:37 -0500 Subject: [PATCH] Prettier formatting --- playwright/tests/checklist.spec.js | 16 +- src/data/queries/audienceTopics.ts | 11 +- src/data/queries/benefitsHubLinks.ts | 2 +- src/data/queries/checklist.ts | 20 +- src/data/queries/checklistItem.ts | 9 +- src/data/queries/index.ts | 2 +- .../__snapshots__/contactInfo.test.tsx.snap | 23 - .../__snapshots__/newsStory.test.tsx.snap | 476 ------------ .../__snapshots__/personProfile.test.tsx.snap | 692 ------------------ .../__snapshots__/pressRelease.test.tsx.snap | 153 ---- .../resourcesSupport.test.tsx.snap | 247 ------- src/data/queries/tests/checklist.test.tsx | 14 +- src/data/queries/tests/checklistItem.test.tsx | 13 +- src/lib/drupal/query.ts | 3 +- src/lib/utils/medallia.ts | 20 +- src/templates/common/breadcrumbs/index.tsx | 6 +- .../common/relatedLinks/index.test.tsx | 32 +- src/templates/common/relatedLinks/index.tsx | 23 +- .../relatedLinks/relatedLinks.stories.ts | 4 +- .../secondaryButtonGroup/index.test.tsx | 26 +- .../common/secondaryButtonGroup/index.tsx | 6 +- .../secondaryButtonGroup.stories.ts | 8 +- .../components/contactInfo/index.tsx | 27 +- .../rateYourExperience/index.test.tsx | 8 +- .../components/rateYourExperience/index.tsx | 15 +- src/templates/layouts/checklist/index.tsx | 59 +- src/templates/layouts/newsStory/index.tsx | 5 +- src/templates/layouts/pressRelease/index.tsx | 5 +- .../layouts/pressReleaseListing/index.tsx | 6 +- src/types/drupal/node.ts | 2 +- 30 files changed, 194 insertions(+), 1739 deletions(-) delete mode 100644 src/data/queries/tests/__snapshots__/contactInfo.test.tsx.snap delete mode 100644 src/data/queries/tests/__snapshots__/newsStory.test.tsx.snap delete mode 100644 src/data/queries/tests/__snapshots__/personProfile.test.tsx.snap delete mode 100644 src/data/queries/tests/__snapshots__/pressRelease.test.tsx.snap delete mode 100644 src/data/queries/tests/__snapshots__/resourcesSupport.test.tsx.snap diff --git a/playwright/tests/checklist.spec.js b/playwright/tests/checklist.spec.js index 616bf786c..f11d76e79 100644 --- a/playwright/tests/checklist.spec.js +++ b/playwright/tests/checklist.spec.js @@ -1,18 +1,22 @@ import { test, expect } from '../utils/next-test' test.describe('Checklist', () => { - test('Checklist page renders', async ({ - page, - }) => { - await page.goto('/resources/what-to-bring-to-create-your-online-sign-in-account') - await expect(page).toHaveURL('/resources/what-to-bring-to-create-your-online-sign-in-account') + test('Checklist page renders', async ({ page }) => { + await page.goto( + '/resources/what-to-bring-to-create-your-online-sign-in-account' + ) + await expect(page).toHaveURL( + '/resources/what-to-bring-to-create-your-online-sign-in-account' + ) }) test('Should render without a11y errors', async ({ page, makeAxeBuilder, }) => { - await page.goto('/resources/what-to-bring-to-create-your-online-sign-in-account') + await page.goto( + '/resources/what-to-bring-to-create-your-online-sign-in-account' + ) const accessibilityScanResults = await makeAxeBuilder().analyze() diff --git a/src/data/queries/audienceTopics.ts b/src/data/queries/audienceTopics.ts index d1adfc821..f4ad02426 100644 --- a/src/data/queries/audienceTopics.ts +++ b/src/data/queries/audienceTopics.ts @@ -11,7 +11,7 @@ export const params: QueryParams = () => { ]) } -const formatBeneficiariesData = beneficiaries => { +const formatBeneficiariesData = (beneficiaries) => { if (!beneficiaries || beneficiaries.length === 0) { return [] } @@ -34,7 +34,9 @@ export const getTagsList = ( field_non_beneficiares: fieldNonBeneficiares, } = entity - const audienceBeneficiaries = formatBeneficiariesData(fieldAudienceBeneficiares) + const audienceBeneficiaries = formatBeneficiariesData( + fieldAudienceBeneficiares + ) const nonBeneficiaries = formatBeneficiariesData(fieldNonBeneficiares) const topics = fieldTopics.map((topic) => ({ @@ -44,10 +46,7 @@ export const getTagsList = ( categoryLabel: 'Topics', })) - const audiences = [ - ...audienceBeneficiaries, - ...nonBeneficiaries, - ] + const audiences = [...audienceBeneficiaries, ...nonBeneficiaries] .filter((tag) => !!tag) .map((audience) => ({ id: audience.id, diff --git a/src/data/queries/benefitsHubLinks.ts b/src/data/queries/benefitsHubLinks.ts index 710b95147..83ee16f2a 100644 --- a/src/data/queries/benefitsHubLinks.ts +++ b/src/data/queries/benefitsHubLinks.ts @@ -11,7 +11,7 @@ export const params: QueryParams = () => { export const formatter: QueryFormatter = ( entities: NodeLandingPage[] ) => { - return entities.map(entity => { + return entities.map((entity) => { return { uri: entity.path?.alias, title: entity.field_home_page_hub_label, diff --git a/src/data/queries/checklist.ts b/src/data/queries/checklist.ts index 542722d04..e83a46d2e 100644 --- a/src/data/queries/checklist.ts +++ b/src/data/queries/checklist.ts @@ -2,7 +2,10 @@ import { QueryData, QueryFormatter, QueryParams } from 'next-drupal-query' import { DrupalJsonApiParams } from 'drupal-jsonapi-params' import { queries } from '.' import { formatParagraph } from '@/lib/drupal/paragraphs' -import { PARAGRAPH_RESOURCE_TYPES, RESOURCE_TYPES } from '@/lib/constants/resourceTypes' +import { + PARAGRAPH_RESOURCE_TYPES, + RESOURCE_TYPES, +} from '@/lib/constants/resourceTypes' import { ExpandedStaticPropsContext } from '@/lib/drupal/staticProps' import { entityBaseFields, @@ -48,7 +51,7 @@ export type ChecklistDataOpts = { export const data: QueryData = async ( opts ): Promise => { -const entity = (await fetchSingleEntityOrPreview( + const entity = (await fetchSingleEntityOrPreview( opts, RESOURCE_TYPES.CHECKLIST, params @@ -61,10 +64,10 @@ export const formatter: QueryFormatter = ( entity: NodeChecklist ) => { const formatRelatedLinks = (links): RelatedLink[] => - links?.map(link => ({ + links?.map((link) => ({ uri: link?.field_link?.uri, title: link?.field_link?.title, - summary: link.field_link_summary + summary: link.field_link_summary, })) return { @@ -75,11 +78,8 @@ export const formatter: QueryFormatter = ( entity.field_related_benefit_hubs ), buttons: entity.field_buttons.map?.(formatParagraph) as Button[], - checklist: entity.field_checklist.field_checklist_sections?.map(section => - queries.formatData( - PARAGRAPH_RESOURCE_TYPES.CHECKLIST, - section - ) + checklist: entity.field_checklist.field_checklist_sections?.map((section) => + queries.formatData(PARAGRAPH_RESOURCE_TYPES.CHECKLIST, section) ) as ChecklistItem[], contactInformation: formatParagraph( entity.field_contact_information @@ -87,6 +87,6 @@ export const formatter: QueryFormatter = ( intro: entity.field_intro_text_limited_html.processed, relatedInformation: formatRelatedLinks(entity.field_related_information), repeatButtons: entity.field_buttons_repeat, - tags: formatParagraph(entity.field_tags) as AudienceTopics + tags: formatParagraph(entity.field_tags) as AudienceTopics, } } diff --git a/src/data/queries/checklistItem.ts b/src/data/queries/checklistItem.ts index 6e4479fe6..c5ea0f59a 100644 --- a/src/data/queries/checklistItem.ts +++ b/src/data/queries/checklistItem.ts @@ -2,14 +2,15 @@ import { QueryFormatter } from 'next-drupal-query' import { ParagraphChecklistItem } from '@/types/drupal/paragraph' import { ChecklistItem } from '@/types/formatted/checklist' -export const formatter: QueryFormatter = ( - entity: ParagraphChecklistItem -) => { +export const formatter: QueryFormatter< + ParagraphChecklistItem, + ChecklistItem +> = (entity: ParagraphChecklistItem) => { return { type: entity.type as ChecklistItem['type'], id: entity.id, items: entity.field_checklist_items, header: entity.field_section_header, - intro: entity.field_section_intro + intro: entity.field_section_intro, } } diff --git a/src/data/queries/index.ts b/src/data/queries/index.ts index 37a1a62d8..2e07da7d4 100644 --- a/src/data/queries/index.ts +++ b/src/data/queries/index.ts @@ -8,7 +8,7 @@ import * as AudienceTopics from './audienceTopics' import * as Banners from './banners' import * as BenefitsHub from './benefitsHubLinks' import * as Button from './button' -import * as Checklist from './checklist'; +import * as Checklist from './checklist' import * as ChecklistItem from './checklistItem' import * as CollapsiblePanel from './collapsiblePanel' import * as CollapsiblePanelItem from './collapsiblePanelItem' diff --git a/src/data/queries/tests/__snapshots__/contactInfo.test.tsx.snap b/src/data/queries/tests/__snapshots__/contactInfo.test.tsx.snap deleted file mode 100644 index 7051de88f..000000000 --- a/src/data/queries/tests/__snapshots__/contactInfo.test.tsx.snap +++ /dev/null @@ -1,23 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`ContactInfo formatData outputs formatted data 1`] = ` -{ - "additionalContact": { - "address": "email@email.com", - "entityId": 13333, - "id": "e5184527-0e7f-4071-bb0b-a99c3eb04839", - "label": "Loremipsum label here", - "type": "paragraph--email_contact", - }, - "benefitHubContacts": null, - "contactType": "DC", - "defaultContact": { - "href": "tel:1-800-698-2411", - "title": "MyVA411 main information line:", - "value": "800-698-2411", - }, - "entityId": 13094, - "id": "ebfce5d0-1bc5-45b9-93e9-669a1c1da645", - "type": "paragraph--contact_information", -} -`; diff --git a/src/data/queries/tests/__snapshots__/newsStory.test.tsx.snap b/src/data/queries/tests/__snapshots__/newsStory.test.tsx.snap deleted file mode 100644 index 5f04decb8..000000000 --- a/src/data/queries/tests/__snapshots__/newsStory.test.tsx.snap +++ /dev/null @@ -1,476 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`node--news_story formatData outputs formatted data 1`] = ` -{ - "administration": { - "id": 12, - "name": "VA Pittsburgh health care", - }, - "author": { - "changed": "2019-08-27T17:50:21+00:00", - "created": "2019-05-14T16:10:51+00:00", - "default_langcode": true, - "drupal_internal__nid": 378, - "drupal_internal__vid": 9455, - "field_administration": { - "id": "87832236-1e54-4ce3-8141-8dec27c8a9a7", - "resourceIdObjMeta": [ - null, - ], - "type": "taxonomy_term--administration", - }, - "field_body": null, - "field_complete_biography": null, - "field_complete_biography_create": null, - "field_description": null, - "field_email_address": null, - "field_intro_text": null, - "field_last_name": "Gottschalk", - "field_last_saved_by_editor": "2019-11-12T20:21:16+00:00", - "field_media": null, - "field_meta_tags": null, - "field_name_first": "Keith", - "field_office": null, - "field_phone_number": null, - "field_photo_allow_hires_download": false, - "field_suffix": null, - "id": "c76037be-ebb0-4338-9b31-973a76958929", - "langcode": "en", - "links": { - "self": [ - null, - ], - }, - "metatag": null, - "moderation_state": "published", - "node_type": { - "id": "89b07673-7fd5-4292-8fba-58cc10c4e3ec", - "resourceIdObjMeta": [ - null, - ], - "type": "node_type--node_type", - }, - "path": { - "alias": "/pittsburgh-health-care/staff-profiles/keith-gottschalk", - "langcode": "en", - "pid": 563, - }, - "promote": false, - "relationshipNames": [ - "node_type", - "revision_uid", - "uid", - "field_administration", - "field_complete_biography", - "field_media", - "field_office", - ], - "resourceIdObjMeta": { - "drupal_internal__target_id": 378, - }, - "revision_log": "Bulk operation publish revision", - "revision_timestamp": "2019-08-27T17:50:21+00:00", - "revision_translation_affected": true, - "revision_uid": { - "id": "fd71292f-3dc7-409d-b0e8-500204cb005a", - "resourceIdObjMeta": [ - null, - ], - "type": "user--user", - }, - "status": true, - "sticky": false, - "title": "Keith Gottschalk", - "type": "node--person_profile", - "uid": { - "id": "c0745381-8e20-40da-9540-5a7d2eee1b35", - "resourceIdObjMeta": [ - null, - ], - "type": "user--user", - }, - }, - "bodyContent": "

VA Pittsburgh's Outstanding Physicians of the Year for 2019, Drs. Brooke Decker and Aref M. Rahman, stand out for expertly filling critical medical facility roles while fostering a collaborative spirit among staff in caring for Veterans.

- -

Dr. Decker, director of Infection Prevention, sees herself as a problem solver.

- -

"The problems that cause infections are incredibly varied and sometimes challenging," said Decker. "My job involves getting the right people together to help solve these problems."

- -

Recent examples include ensuring hand sanitizers are plentiful and optimally located to support hand hygiene; safe disposal of needles and syringes; and developing the safest way to shut down and perform maintenance on an air handler in a patient-care area that is always open.

- -

Dr. Rahman, a cardiologist, has been director of the Cardiac Cath Lab for the past six years. He credits his dedicated and skilled team for the lab's success, but he says one other factor plays a big role in that success.

- - -

- "The icing on top is the staff's eagerness to help our Veterans," - said - Rahman. - "All hospital environments can be intense and demanding and come with general and specific challenges. But having co-workers whom one can count on makes my job at VA an invaluable opportunity." -

- n - - -

Decker - said - she - likens - her - investigative - work - to - that - of - the - fictional - private - detective - Sherlock - Holmes - or - Dr. - Gregory - House, - a - fictional - doctor - who - solved - medical - mysteries - on - television - 's "House" series.

- - -

- "For every issue, there may be layers and layers of additional clues to unravel," - said - Decker. - "The 'aha moment' when it all comes together is very gratifying." -

- n - -

Even so, Decker says preventing illness in the first place is even more gratifying.

- - -

- "Caring for a single patient and solving that one patient's illness is our honor and privilege as health care providers," - said - Decker. - "Preventing 10 patients from getting sick is even better, and that's what we strive to do in Infection Prevention." -

- n - -

Rahman said he's been fascinated since childhood with how the human body works.

- - -

- "I would read all kinds of articles about new discoveries in medicine and I found myself being drawn more and more toward what is literally the 'heart' of our bodies," - he - said. - "Cardiology is not just a career choice, but a calling, and I think it found me." -

- n - -

Both doctors said the best part of working at VA is listening to Veterans' stories.

- - -

- "I love sitting down at the bedside and hearing about someone's family, pets, adventures," - said - Decker. - "I've met some truly great people working at VA." -

- n - -

Rahman said Veterans' stories make every day at work interesting.

- - -

- "As I interact with my patients, I get to hear a lot of fascinating stories of their experiences all over the world," - said - Rahman. - "It's never a dull day at work." -

- n - -

Decker and Rahman were formally recognized as Outstanding Physicians of the Year on April 26 during the medical staff's quarterly meeting at University Drive.

", - "breadcrumbs": [ - { - "options": [], - "title": "Home", - "uri": "https://cms-7m0jwgfd3t0pt3txlgzvixowibrfagsq.ci.cms.va.gov/", - }, - ], - "caption": " - "Caring for a single patient and solving that one patient's illness is our honor and privilege as health care providers." - - - Dr. - Brooke - Decker - ", - "date": "2019-05-14T15:35:12+00:00", - "entityId": 377, - "entityPath": "/pittsburgh-health-care/stories/we-honor-outstanding-doctors", - "id": "bb4dcfc1-736b-4a9e-aa48-23c2dd4a4980", - "image": { - "alt": null, - "height": 304, - "id": "c85b7882-f035-4b55-8b71-fcf81fade350", - "links": { - "1_1_square_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/1_1_square_medium_thumbnail/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "240", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "240", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "2_1_large": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/2_1_large/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "512", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "1024", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "2_1_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/2_1_medium_thumbnail/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "240", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "480", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "2_3_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/2_3_medium_thumbnail/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "480", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "320", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "3_2_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/3_2_medium_thumbnail/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "320", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "480", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "7_2_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/7_2_medium_thumbnail/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "300", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "1050", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "full_content_width": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/full_content_width/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "304", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "456", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "large": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/large/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "304", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "456", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "self": { - "href": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/jsonapi/file/file/e638fd17-9090-442b-a724-5113133b4d0f", - }, - "viewport_width": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/viewport_width/public/hub_promos/health-care.png", - "meta": { - "linkParams": { - "height": "304", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "456", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - }, - "title": null, - "type": "media--image", - "width": 456, - }, - "introText": "When a hospital has a host of great doctors, honoring just two every year is challenging. ", - "lastUpdated": "2019-05-14T15:35:12+00:00", - "listing": "/pittsburgh-health-care/stories", - "metatags": [ - { - "attributes": { - "content": "It’s never too late to quit smoking and start breathing easier | VA Minneapolis health care | Veterans Affairs", - "name": "title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "When you stop smoking, you feel the benefits almost immediately, no matter how long you’ve smoked.", - "name": "description", - }, - "tag": "meta", - }, - { - "attributes": { - "href": "https://www.va.gov/img/design/logo/va-og-image.png", - "rel": "image_src", - }, - "tag": "link", - }, - { - "attributes": { - "content": "Veterans Affairs", - "property": "og:site_name", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "It’s never too late to quit smoking and start breathing easier | VA Minneapolis health care | Veterans Affairs", - "property": "og:title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "When you stop smoking, you feel the benefits almost immediately, no matter how long you’ve smoked.", - "property": "og:description", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/3_2_medium_thumbnail/public/2023-10/Great%20American%20Smokeout.jpg", - "property": "og:image", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "Great American Smokeout 2023", - "property": "og:image:alt", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "summary_large_image", - "name": "twitter:card", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "When you stop smoking, you feel the benefits almost immediately, no matter how long you’ve smoked.", - "name": "twitter:description", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "@DeptVetAffairs", - "name": "twitter:site", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "It’s never too late to quit smoking and start breathing easier | VA Minneapolis health care | Veterans Affairs", - "name": "twitter:title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/3_2_medium_thumbnail/public/2023-10/Great%20American%20Smokeout.jpg", - "name": "twitter:image", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "Great American Smokeout 2023", - "name": "twitter:image:alt", - }, - "tag": "meta", - }, - ], - "moderationState": "published", - "published": true, - "socialLinks": { - "path": "http://127.0.0.1:8001/pittsburgh-health-care/stories/we-honor-outstanding-doctors", - "title": "We honor outstanding doctors", - }, - "title": "We honor outstanding doctors", - "type": "node--news_story", -} -`; diff --git a/src/data/queries/tests/__snapshots__/personProfile.test.tsx.snap b/src/data/queries/tests/__snapshots__/personProfile.test.tsx.snap deleted file mode 100644 index e9abde7a0..000000000 --- a/src/data/queries/tests/__snapshots__/personProfile.test.tsx.snap +++ /dev/null @@ -1,692 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`Person profile returns formatted data outputs formatted data 1`] = ` -{ - "body": null, - "breadcrumbs": undefined, - "completeBiography": undefined, - "completeBiographyCreate": null, - "description": "Director, Audiology and Speech Pathology Program Associate Director for Research, GRECC", - "emailAddress": null, - "entityId": 812, - "entityPath": "/pittsburgh-health-care/staff-profiles/patrick-j-doyle", - "firstName": "Patrick J.", - "id": "fe42bc63-0933-40bb-978a-ef951fa75684", - "introText": null, - "lastName": "Doyle", - "lastUpdated": "2019-08-26T22:03:30+00:00", - "media": { - "alt": "Patrick J. Doyle", - "height": 129, - "id": "5bcbdaee-f93f-4b2f-8af5-963e4a547d93", - "links": { - "1_1_square_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/1_1_square_medium_thumbnail/public/2019-08/pat_doyle_0.jpg?h=46bc4a38", - "meta": { - "linkParams": { - "height": "240", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "240", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "2_1_large": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/2_1_large/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "512", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "1024", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "2_1_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/2_1_medium_thumbnail/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "240", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "480", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "2_3_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/2_3_medium_thumbnail/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "480", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "320", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "3_2_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/3_2_medium_thumbnail/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "320", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "480", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "7_2_medium_thumbnail": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/7_2_medium_thumbnail/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "300", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "1050", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "full_content_width": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/full_content_width/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "129", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "100", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "large": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/large/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "129", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "100", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - "self": { - "href": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/jsonapi/file/file/5bcbdaee-f93f-4b2f-8af5-963e4a547d93", - }, - "viewport_width": { - "href": "http://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/sites/default/files/styles/viewport_width/public/2019-08/pat_doyle_0.jpg", - "meta": { - "linkParams": { - "height": "129", - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - "width": "100", - }, - "rel": [ - "drupal://jsonapi/extensions/consumer_image_styles/links/relation-types/#derivative", - ], - }, - }, - }, - "title": "", - "type": "media--image", - "width": 100, - }, - "metatags": null, - "moderationState": "published", - "office": { - "changed": "2022-08-31T15:49:34+00:00", - "created": "2019-05-06T03:30:18+00:00", - "default_langcode": true, - "drupal_internal__nid": 318, - "drupal_internal__vid": 679006, - "field_administration": { - "id": "87832236-1e54-4ce3-8141-8dec27c8a9a7", - "resourceIdObjMeta": { - "drupal_internal__target_id": 12, - }, - "type": "taxonomy_term--administration", - }, - "field_appointments_online": true, - "field_clinical_health_services": [ - { - "id": "a502e932-d460-436e-a67b-83eefdef3a7b", - "resourceIdObjMeta": { - "drupal_internal__target_id": 324, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "7ab831f3-b998-413d-beb9-c17ccf514514", - "resourceIdObjMeta": { - "drupal_internal__target_id": 325, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "a192dca3-0ebd-44a5-8cdb-d70c2d8cc4bc", - "resourceIdObjMeta": { - "drupal_internal__target_id": 96, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "077bad0f-e9f1-4f6b-94cc-fb021b287f0e", - "resourceIdObjMeta": { - "drupal_internal__target_id": 326, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "e1b68b35-f5f7-44ec-9808-9a642d669ce5", - "resourceIdObjMeta": { - "drupal_internal__target_id": 229, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "e65f031a-ad46-47ed-aa0a-9e923bc34f9e", - "resourceIdObjMeta": { - "drupal_internal__target_id": 327, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "fc92e5b2-a387-4421-8943-246140fd497f", - "resourceIdObjMeta": { - "drupal_internal__target_id": 328, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "8bd98812-e275-4740-8d96-a4d293e856b7", - "resourceIdObjMeta": { - "drupal_internal__target_id": 329, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "b6717638-7c4b-4b8e-a7ce-c76f37aff4bf", - "resourceIdObjMeta": { - "drupal_internal__target_id": 330, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "94177aa5-4a5e-4a66-97d5-e721b8f02f92", - "resourceIdObjMeta": { - "drupal_internal__target_id": 331, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "ffa5121a-9775-4825-9f9b-27a20c599f1f", - "resourceIdObjMeta": { - "drupal_internal__target_id": 332, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "c8ea6d96-9263-4d1d-ac90-c90b55ba13c9", - "resourceIdObjMeta": { - "drupal_internal__target_id": 362, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "02e024f0-e9c8-4d11-8d71-6a4f3e91366d", - "resourceIdObjMeta": { - "drupal_internal__target_id": 333, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "c57b1ff5-d845-4862-9dfc-427823485e06", - "resourceIdObjMeta": { - "drupal_internal__target_id": 222, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "e453f2c1-fe99-427f-a256-92fd1f103c25", - "resourceIdObjMeta": { - "drupal_internal__target_id": 742, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "04b5f49e-4a46-481c-a494-bd43a8598094", - "resourceIdObjMeta": { - "drupal_internal__target_id": 334, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "5483b3ee-eeb5-4286-9ff1-2d463784031b", - "resourceIdObjMeta": { - "drupal_internal__target_id": 259, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "f105e35d-b374-4405-a867-6e2e18f80732", - "resourceIdObjMeta": { - "drupal_internal__target_id": 264, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "b516b8f9-af49-4402-8a42-5e4428bfdda0", - "resourceIdObjMeta": { - "drupal_internal__target_id": 335, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "6d59f042-c372-436c-a8ff-7a8f017ad89f", - "resourceIdObjMeta": { - "drupal_internal__target_id": 477, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "a3dbd92d-9e31-4766-962c-5cb52b8353fe", - "resourceIdObjMeta": { - "drupal_internal__target_id": 743, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "a27c5805-47de-4dc1-917c-4e3855fbd3cb", - "resourceIdObjMeta": { - "drupal_internal__target_id": 257, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "54d15687-aac6-4457-8560-5d93fe233967", - "resourceIdObjMeta": { - "drupal_internal__target_id": 260, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "27a7587b-c51b-4eea-956b-587819b1b630", - "resourceIdObjMeta": { - "drupal_internal__target_id": 336, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "c88adf39-6ca4-4859-8877-ad6b5706257e", - "resourceIdObjMeta": { - "drupal_internal__target_id": 267, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "cbd42261-56b9-4bd3-8e95-317797682663", - "resourceIdObjMeta": { - "drupal_internal__target_id": 337, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "45fa1aaa-22f3-44a9-944d-0aef13efbc9a", - "resourceIdObjMeta": { - "drupal_internal__target_id": 338, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "c1bf3481-50a8-4984-a383-37bdcfbe6b0f", - "resourceIdObjMeta": { - "drupal_internal__target_id": 363, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "85ecc815-a3fc-4978-9e7a-2cfd55dc9b72", - "resourceIdObjMeta": { - "drupal_internal__target_id": 592, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "929402f4-2a85-4659-a1bf-900264984903", - "resourceIdObjMeta": { - "drupal_internal__target_id": 269, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "4cad2f34-1e07-49b9-a021-dd0d10016149", - "resourceIdObjMeta": { - "drupal_internal__target_id": 340, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "8c838193-be61-48ea-8f1c-a1839b57f1fc", - "resourceIdObjMeta": { - "drupal_internal__target_id": 270, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "c4f23a23-0885-4e1a-b282-48c421fb9203", - "resourceIdObjMeta": { - "drupal_internal__target_id": 613, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "4aa8d80c-c3b0-4e10-9b0b-e22d71b3d6d4", - "resourceIdObjMeta": { - "drupal_internal__target_id": 101, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "19810ce7-1e0d-4548-92da-5d261bccb75c", - "resourceIdObjMeta": { - "drupal_internal__target_id": 620, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "84515c3f-69da-41ed-81d1-083c995c0642", - "resourceIdObjMeta": { - "drupal_internal__target_id": 341, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "72ff4ca7-0310-4786-b7ff-502486b88efc", - "resourceIdObjMeta": { - "drupal_internal__target_id": 624, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "0a618bda-2a2f-4450-88f2-30d21109d39d", - "resourceIdObjMeta": { - "drupal_internal__target_id": 739, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "3e92eaa8-bbf8-4173-84f8-d187b281d548", - "resourceIdObjMeta": { - "drupal_internal__target_id": 265, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "ddd4532d-9c31-4f87-af7f-ecbc83116592", - "resourceIdObjMeta": { - "drupal_internal__target_id": 342, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "ba3fd7af-1793-4f16-afb4-868edb12537d", - "resourceIdObjMeta": { - "drupal_internal__target_id": 261, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "f88a91dc-918b-40da-a76d-baa3bd19c4ac", - "resourceIdObjMeta": { - "drupal_internal__target_id": 343, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "d6a14b35-382e-4df7-bd42-b3572f0727e9", - "resourceIdObjMeta": { - "drupal_internal__target_id": 99, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "5c2a855e-39b0-4413-8232-1aa143ff5747", - "resourceIdObjMeta": { - "drupal_internal__target_id": 344, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "7bc4ce20-f573-4ea6-b361-b3060be2e2ea", - "resourceIdObjMeta": { - "drupal_internal__target_id": 638, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "f25b7f27-0320-404a-b116-dc2b21178818", - "resourceIdObjMeta": { - "drupal_internal__target_id": 641, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "993ca7e5-e745-4add-890d-66da2f52a52d", - "resourceIdObjMeta": { - "drupal_internal__target_id": 339, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "fa8d2d15-0e41-4ef0-a606-c0da352fe76d", - "resourceIdObjMeta": { - "drupal_internal__target_id": 364, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "fa9fd27d-aa1c-4cc0-b31b-569e779c034d", - "resourceIdObjMeta": { - "drupal_internal__target_id": 346, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "26bd1dc9-e9f5-44eb-a029-73eb54842237", - "resourceIdObjMeta": { - "drupal_internal__target_id": 266, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "1fdda7ec-a660-4fa7-86be-ef2421cb4e6f", - "resourceIdObjMeta": { - "drupal_internal__target_id": 262, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "b2fa010f-4012-4ba2-9faf-4e2ea07b8eaa", - "resourceIdObjMeta": { - "drupal_internal__target_id": 15058, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "ca7bea88-16c7-4d67-b9e6-975e4f5a1a69", - "resourceIdObjMeta": { - "drupal_internal__target_id": 38986, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "471171a1-a82b-4726-a994-d88583778623", - "resourceIdObjMeta": { - "drupal_internal__target_id": 48422, - }, - "type": "node--regional_health_care_service_des", - }, - { - "id": "bcd2c502-d4b3-4308-9175-c52b7126215f", - "resourceIdObjMeta": { - "drupal_internal__target_id": 49003, - }, - "type": "node--regional_health_care_service_des", - }, - ], - "field_description": "Find a health facility near you at VA Pittsburgh health care, and manage your health online. Our health care teams are deeply experienced and guided by the needs of Veterans, their families, and caregivers.", - "field_facebook": { - "options": [], - "title": "VA Pittsburgh health care Facebook", - "uri": "https://www.facebook.com/VAPHS", - }, - "field_flickr": { - "options": [], - "title": "VA Pittsburgh health care Flickr", - "uri": "https://www.flickr.com/photos/vapittsburgh/sets", - }, - "field_govdelivery_id_emerg": "USVHA_396", - "field_govdelivery_id_news": "USVHA_94", - "field_instagram": null, - "field_intro_text": "At VA Pittsburgh Healthcare System, our health care teams are deeply experienced and guided by the needs of Veterans, their families, and caregivers. Find a health facility near you, and manage your health online. Sign up for community events and updates.", - "field_media": { - "id": "de919547-d935-46da-a220-9f0646f2c0e9", - "resourceIdObjMeta": { - "drupal_internal__target_id": 57, - }, - "type": "media--image", - }, - "field_meta_tags": null, - "field_operating_status": { - "options": [], - "title": "VA Pittsburgh health care operating status", - "uri": "entity:node/1010", - }, - "field_other_va_locations": [ - "vc_0211V", - "vc_0233V", - "vc_0220V", - "nca_925", - "vba_311", - ], - "field_related_links": { - "id": "c47aaf53-cd32-47b7-84af-9c004926b211", - "resourceIdObjMeta": { - "drupal_internal__target_id": 3943, - "target_revision_id": 694430, - }, - "type": "paragraph--list_of_link_teasers", - }, - "field_system_menu": { - "id": "83b58096-0fa0-4e12-895b-6dc58a2b9c88", - "resourceIdObjMeta": { - "drupal_internal__target_id": "pittsburgh-health-care", - }, - "type": "menu--menu", - }, - "field_twitter": { - "options": [], - "title": "VA Pittsburgh health care Twitter", - "uri": "https://twitter.com/VAPittsburgh", - }, - "field_va_health_connect_phone": null, - "field_vamc_ehr_system": "vista", - "field_vamc_system_official_name": "VA Pittsburgh Healthcare System", - "id": "2bddb1a7-6fb1-4503-838d-9c2fcb51c46a", - "langcode": "en", - "links": { - "self": { - "href": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/jsonapi/node/health_care_region_page/2bddb1a7-6fb1-4503-838d-9c2fcb51c46a?resourceVersion=id%3A679006", - }, - }, - "metatag": null, - "moderation_state": "published", - "node_type": { - "id": "d611ade3-cc27-4359-8af1-6fba3384200f", - "resourceIdObjMeta": { - "drupal_internal__target_id": "health_care_region_page", - }, - "type": "node_type--node_type", - }, - "path": { - "alias": "/pittsburgh-health-care", - "langcode": "en", - "pid": 503, - }, - "promote": false, - "relationshipNames": [ - "node_type", - "revision_uid", - "uid", - "field_administration", - "field_clinical_health_services", - "field_media", - "field_related_links", - "field_system_menu", - ], - "resourceIdObjMeta": { - "drupal_internal__target_id": 318, - }, - "revision_log": "Set "System Menu" field accordingly (see va.gov-cms/#9520).", - "revision_timestamp": "2022-07-18T13:30:31+00:00", - "revision_translation_affected": true, - "revision_uid": { - "id": "183f10f5-b0dc-4a10-9955-cfa65b6f15af", - "resourceIdObjMeta": { - "drupal_internal__target_id": 1454, - }, - "type": "user--user", - }, - "status": true, - "sticky": false, - "title": "VA Pittsburgh health care", - "type": "node--health_care_region_page", - "uid": { - "id": "fd71292f-3dc7-409d-b0e8-500204cb005a", - "resourceIdObjMeta": { - "drupal_internal__target_id": 65, - }, - "type": "user--user", - }, - }, - "phoneNumber": null, - "photoAllowHiresDownload": false, - "published": true, - "suffix": "Ph.D.", - "title": "Patrick J. Doyle", - "type": "node--person_profile", - "vamcOfficalName": undefined, -} -`; diff --git a/src/data/queries/tests/__snapshots__/pressRelease.test.tsx.snap b/src/data/queries/tests/__snapshots__/pressRelease.test.tsx.snap deleted file mode 100644 index 9136e49f6..000000000 --- a/src/data/queries/tests/__snapshots__/pressRelease.test.tsx.snap +++ /dev/null @@ -1,153 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`node--press_release formatData output formatted data 1`] = ` -{ - "address": { - "administrative_area": "DE", - "country_code": "US", - "langcode": null, - "locality": "Wilmington", - }, - "administration": { - "id": 188, - "name": "VA Wilmington health care", - }, - "breadcrumbs": [ - { - "options": [], - "title": "Home", - "uri": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/", - }, - { - "options": [], - "title": "VA Wilmington health care", - "uri": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/wilmington-health-care", - }, - { - "options": [], - "title": "News releases", - "uri": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/wilmington-health-care/news-releases", - }, - { - "options": [], - "title": "Wilmington VAMC 2019 Annual Report", - "uri": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/wilmington-health-care/news-releases/wilmington-vamc-2019-annual-report", - }, - ], - "contacts": [], - "downloads": [], - "entityId": 18141, - "entityPath": "/wilmington-health-care/news-releases/wilmington-vamc-2019-annual-report", - "fullText": "

We invite you to come and read our 2019 Annual Report.

", - "id": "6153ed5b-85c2-4ead-9893-3d656ad5d758", - "introText": "We invite you to come and read our 2019 Annual Report. ", - "lastUpdated": "2021-04-12T14:25:27+00:00", - "listing": "/wilmington-health-care/news-releases", - "metatags": [ - { - "attributes": { - "content": "Wilmington VAMC 2019 Annual Report | VA Wilmington health care | Veterans Affairs", - "name": "title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "We invite you to come and read our 2019 Annual Report.", - "name": "description", - }, - "tag": "meta", - }, - { - "attributes": { - "href": "https://www.va.gov/img/design/logo/va-og-image.png", - "rel": "image_src", - }, - "tag": "link", - }, - { - "attributes": { - "content": "Veterans Affairs", - "property": "og:site_name", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "Wilmington VAMC 2019 Annual Report | VA Wilmington health care | Veterans Affairs", - "property": "og:title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "We invite you to come and read our 2019 Annual Report.", - "property": "og:description", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "https://www.va.gov/img/design/logo/va-og-image.png", - "property": "og:image", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "U.S. Department of Veterans Affairs", - "property": "og:image:alt", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "summary_large_image", - "name": "twitter:card", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "We invite you to come and read our 2019 Annual Report.", - "name": "twitter:description", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "@DeptVetAffairs", - "name": "twitter:site", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "Wilmington VAMC 2019 Annual Report | VA Wilmington health care | Veterans Affairs", - "name": "twitter:title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "https://www.va.gov/img/design/logo/va-og-image.png", - "name": "twitter:image", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "U.S. Department of Veterans Affairs", - "name": "twitter:image:alt", - }, - "tag": "meta", - }, - ], - "moderationState": "draft", - "pdfVersion": "/sites/default/files/2021-04/WilmingtonVAMC_Annual_Report_2019_web.pdf", - "published": false, - "releaseDate": "2020-06-19T10:25:28-04:00", - "title": "Wilmington VAMC 2019 Annual Report", - "type": "node--press_release", -} -`; diff --git a/src/data/queries/tests/__snapshots__/resourcesSupport.test.tsx.snap b/src/data/queries/tests/__snapshots__/resourcesSupport.test.tsx.snap deleted file mode 100644 index cebed773b..000000000 --- a/src/data/queries/tests/__snapshots__/resourcesSupport.test.tsx.snap +++ /dev/null @@ -1,247 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`Resources Support formatData outputs formatted data 1`] = ` -{ - "alert": { - "alertSelection": "NA", - "blockReference": null, - "entityId": 23307, - "id": "d275ba42-1992-45bf-862a-9b04d5f98c48", - "nonReusableRef": null, - "type": "paragraph--alert_single", - }, - "benefitsHubLinks": [ - { - "id": "33cd69ba-e93c-460a-bf9e-41aaf8ff67af", - "label": "Life insurance", - "path": "/life-insurance", - "teaserText": "Explore VA life insurance options for Veterans, service members, and families. Manage your policy online, file claims for benefits, and access helpful resources.", - "title": "VA life insurance", - }, - ], - "breadcrumbs": [ - { - "options": [], - "title": "Home", - "uri": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/", - }, - { - "options": [], - "title": "Resources and support", - "uri": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/resources", - }, - { - "options": [], - "title": "Closed life insurance programs", - "uri": "https://content-build-medc0xjkxm4jmpzxl3tfbcs7qcddsivh.ci.cms.va.gov/resources/closed-life-insurance-programs", - }, - ], - "buttons": [ - { - "entityId": 23308, - "id": "b5c88633-834f-4fc6-b119-2d1f95999820", - "label": "Explore VA life insurance ", - "type": "paragraph--button", - "url": "entity:node/77", - }, - ], - "contactInformation": { - "additionalContact": null, - "benefitHubContacts": null, - "contactType": "DC", - "defaultContact": { - "href": "tel:1-800-698-2411", - "title": "MyVA411 main information line:", - "value": "800-698-2411", - }, - "entityId": 23309, - "id": "ab6ce4bb-c9c4-426a-a157-7db1b9c4e70e", - "type": "paragraph--contact_information", - }, - "entityId": 15063, - "entityPath": "/resources/closed-life-insurance-programs", - "id": "5b4943dc-764e-454c-a698-dd3f0bc0df32", - "intro": "

We offer some life insurance programs to service members and Veterans that are now closed to new enrollees. Learn more about these programs and what to do if you want to convert your policy.

-", - "lastUpdated": "2020-12-18T18:21:27+00:00", - "mainContent": [ - { - "html": "

United States Government Life Insurance (USGLI)

- -

Veterans insured: WWI
-Years issued: 1919 to 1951
-Policies still in force: Fewer than 8,000
-Average age of policyholders: 88 years old

- -

Policies were issued in a variety of permanent plans and as renewable term insurance. The maximum face amount of a USGLI policy is $10,000. All USGLI policies were declared paid up as of January 1, 1983, meaning that no further premium payments were due. Annual dividends continue to be paid on these policies.

- -

Endowment at age 96

- -

Veterans with a 5-Year Level Premium plan under the USGLI program had the opportunity to exchange it for a special endowment plan payable at age 96. 

- -

This is a term life insurance plan that provides coverage until the year of the Veteran's 96th birthday. If the Veteran dies before age 96, the insurance payout goes to the plan beneficiary. If the Veteran reaches the policy anniversary closest to their 96th birthday, they receive the face value of the policy, minus any amount borrowed against it.

- -

For example, if the Veteran's policy anniversary is September 1 and their birthday is October 1, they would receive the policy payout on September 1. 

- -

Policy proceeds are paid either in a lump sum or on an installment basis.

- -

This plan doesn't provide permanent and total disability benefits. 

- -

It doesn't provide a waiver of premium once in force, though a waiver of premium provision could have been purchased at the time this plan was exchanged for the 5-Year Level Premium plan.

- -

National Service Life Insurance (NSLI)

- -

Veterans insured: WWII
-Years issued: 1940 to 1951
-Policies still in force: 950,000
-Average age of policyholders: 81 years old

- -

Annual dividends are paid on these policies. The maximum face amount of a policy is $10,000. However, this limit doesn't include paid-up additional insurance, which can be purchased with the annual dividends. Certain disability benefits are available under these policies for policyholders who become totally disabled before their 65th birthday. 

- -

Premium rates are capped at age 70. This means that a term policyholder's premium will never increase over the age 70 premium rate.

- -

Effective September 11, 2000, "capped" NSLI term policies receive a termination dividend if a policy lapses, or if the policyholder voluntarily cancels their policy. The termination dividend will be used to purchase paid-up additional whole life insurance.

- -

Veterans' Special Life Insurance (VSLI)

- -

Veterans insured: Korean War
-Years issued: 1951 to 1956
-Policies still in force: 181,000
-Average age of policyholders: 75 years old

- -

Annual dividends are paid on these policies. The maximum face amount of a policy is $10,000. However, this limit does not include paid-up additional insurance, which can be purchased with the annual dividends. Certain disability benefits are available under these policies for policyholders who become totally disabled before their 65th birthday.

- -

Premium rates are capped at age 70. This means that a term policyholder's premium will never increase over the age 70 premium rate. This means that the annual premium for these policies will not exceed $69.73 per $1,000 of coverage.

- -

Effective September 11, 2000, "capped" VSLI term policies receive a termination dividend if a policy lapses, or if the policyholder voluntarily cancels their policy. The termination dividend will be used to purchase paid-up additional whole life insurance.

- -

Veterans' Reopened Insurance

- -

Veterans insured: Disabled WWII and Korean War
-Years issued: 1965 to 1966
-Policies still in force: More than 41,000
-Average age of policyholders: ?? years old

- -

Annual dividends are paid on these policies. The maximum face amount of a policy is $10,000. However, this limit doesn't include paid-up additional insurance, which can be purchased with the dividends that are paid annually on these policies. Certain disability benefits are available under these policies for policyholders who become totally disabled before their 65th birthday.

- -

What should I do if I have more questions?

- -

Call our VA Insurance Center at 800-669-8477. We're here Monday through Friday, 8:30 a.m. to 6:00 p.m. ET.

", - "id": "6f28ef70-df39-413f-b867-ba7ba63ecb30", - "type": "paragraph--wysiwyg", - }, - ], - "metatags": [ - { - "attributes": { - "content": "Closed life insurance programs | Veterans Affairs", - "name": "title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "We offer some life insurance programs to service members and Veterans that are now closed to new enrollees. Learn more about these programs and what to do if you want to convert your policy.", - "name": "description", - }, - "tag": "meta", - }, - { - "attributes": { - "href": "https://www.va.gov/img/design/logo/va-og-image.png", - "rel": "image_src", - }, - "tag": "link", - }, - { - "attributes": { - "content": "Veterans Affairs", - "property": "og:site_name", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "Closed life insurance programs | Veterans Affairs", - "property": "og:title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "We offer some life insurance programs to service members and Veterans that are now closed to new enrollees. Learn more about these programs and what to do if you want to convert your policy.", - "property": "og:description", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "https://www.va.gov/img/design/logo/va-og-image.png", - "property": "og:image", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "U.S. Department of Veterans Affairs", - "property": "og:image:alt", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "summary_large_image", - "name": "twitter:card", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "@DeptVetAffairs", - "name": "twitter:site", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "Closed life insurance programs | Veterans Affairs", - "name": "twitter:title", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "https://www.va.gov/img/design/logo/va-og-image.png", - "name": "twitter:image", - }, - "tag": "meta", - }, - { - "attributes": { - "content": "U.S. Department of Veterans Affairs", - "name": "twitter:image:alt", - }, - "tag": "meta", - }, - ], - "moderationState": "draft", - "published": false, - "repeatButtons": true, - "tags": { - "entityId": 23312, - "id": "fdac0715-f3eb-4a9d-bf5e-298da4a82ef3", - "tags": [ - { - "categoryLabel": "Audience", - "href": "/resources/tag/all-veterans", - "id": "386eb70d-696c-4af3-8986-306ce63d90de", - "name": "All Veterans", - }, - ], - "type": "paragraph--audience_topics", - }, - "title": "Closed life insurance programs", - "toc": false, - "type": "node--support_resources_detail_page", -} -`; diff --git a/src/data/queries/tests/checklist.test.tsx b/src/data/queries/tests/checklist.test.tsx index 107f0a6bd..fc2604f1c 100644 --- a/src/data/queries/tests/checklist.test.tsx +++ b/src/data/queries/tests/checklist.test.tsx @@ -5,7 +5,7 @@ import { NodeChecklist } from '@/types/drupal/node' import { queries } from '@/data/queries' import mockData from '@/mocks/checklist.mock.json' -import { params } from '../checklist'; +import { params } from '../checklist' const ChecklistMock: NodeChecklist = mockData @@ -21,7 +21,7 @@ describe('DrupalJsonApiParams configuration', () => { 'field_contact_information', 'field_related_benefit_hubs', 'field_related_information', - 'field_tags' + 'field_tags', ] expectedIncludes.forEach((include) => { @@ -33,10 +33,7 @@ describe('DrupalJsonApiParams configuration', () => { describe('Checklist formatData', () => { test('outputs formatted data', () => { expect( - queries.formatData( - 'node--checklist', - ChecklistMock - ) + queries.formatData('node--checklist', ChecklistMock) ).toMatchSnapshot() }) @@ -50,10 +47,7 @@ describe('Checklist formatData', () => { field_related_information: [], field_tags: null, } - const formattedData = queries.formatData( - 'node--checklist', - modifiedMock - ) + const formattedData = queries.formatData('node--checklist', modifiedMock) expect(formattedData.alert).toBeNull() expect(formattedData.benefitsHubLinks).toEqual([]) diff --git a/src/data/queries/tests/checklistItem.test.tsx b/src/data/queries/tests/checklistItem.test.tsx index 4febcd092..6ac5f13b7 100644 --- a/src/data/queries/tests/checklistItem.test.tsx +++ b/src/data/queries/tests/checklistItem.test.tsx @@ -22,20 +22,23 @@ describe('ChecklistItem formatData', () => { field_section_intro: '', type: 'paragraph--checklist_item', id: 'c4d10aa1-3bb9-4f39-99fd-f110b465603f', - 'drupal_internal__id': 13919, - 'drupal_internal__revision_id': 149239, + drupal_internal__id: 13919, + drupal_internal__revision_id: 149239, langcode: 'en', - status: true + status: true, } - const formattedDataEmpty = queries.formatData('paragraph--checklist_item', emptyData) + const formattedDataEmpty = queries.formatData( + 'paragraph--checklist_item', + emptyData + ) expect(formattedDataEmpty).toEqual({ items: [], header: '', intro: '', type: 'paragraph--checklist_item', - id: 'c4d10aa1-3bb9-4f39-99fd-f110b465603f' + id: 'c4d10aa1-3bb9-4f39-99fd-f110b465603f', }) }) }) diff --git a/src/lib/drupal/query.ts b/src/lib/drupal/query.ts index 77ea5c6f2..92c87bd13 100644 --- a/src/lib/drupal/query.ts +++ b/src/lib/drupal/query.ts @@ -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.changed || entity.created, + lastUpdated: + entity.field_last_saved_by_an_editor || entity.changed || entity.created, } } diff --git a/src/lib/utils/medallia.ts b/src/lib/utils/medallia.ts index f2b07e638..9e00751af 100644 --- a/src/lib/utils/medallia.ts +++ b/src/lib/utils/medallia.ts @@ -51,12 +51,12 @@ const medalliaSurveys = { staging: SURVEY_NUMBERS.DEFAULT_STAGING_SURVEY, }, }, -}; +} export function getSurveyNumber(url: string, isProduction = false): number { - const defaultSurvey = isProduction ? - SURVEY_NUMBERS.DEFAULT_PROD_SURVEY : - SURVEY_NUMBERS.DEFAULT_STAGING_SURVEY + const defaultSurvey = isProduction + ? SURVEY_NUMBERS.DEFAULT_PROD_SURVEY + : SURVEY_NUMBERS.DEFAULT_STAGING_SURVEY const buildEnv = isProduction ? 'production' : 'staging' @@ -68,21 +68,15 @@ export function getSurveyNumber(url: string, isProduction = false): number { if (url in medalliaSurveys.urls) { const surveyInfo = medalliaSurveys.urls[url] - return ( - surveyInfo[buildEnv] || - defaultSurvey - ) + return surveyInfo[buildEnv] || defaultSurvey } // Check for subpath match for (const [subpath, surveyInfo] of Object.entries( - medalliaSurveys.urlsWithSubPaths, + medalliaSurveys.urlsWithSubPaths )) { if (url.startsWith(subpath)) { - return ( - surveyInfo[buildEnv] || - defaultSurvey - ) + return surveyInfo[buildEnv] || defaultSurvey } } diff --git a/src/templates/common/breadcrumbs/index.tsx b/src/templates/common/breadcrumbs/index.tsx index 3aefc94bb..e915f4281 100644 --- a/src/templates/common/breadcrumbs/index.tsx +++ b/src/templates/common/breadcrumbs/index.tsx @@ -71,11 +71,7 @@ const Breadcrumbs = ({ className="vads-u-padding-x--1p5" data-next-component="templates/common/breadcrumbs" > - + ) } diff --git a/src/templates/common/relatedLinks/index.test.tsx b/src/templates/common/relatedLinks/index.test.tsx index 0aeddde80..9699b4fc1 100644 --- a/src/templates/common/relatedLinks/index.test.tsx +++ b/src/templates/common/relatedLinks/index.test.tsx @@ -15,17 +15,25 @@ describe('RelatedLinks Component', () => { uri: 'https://va.gov/burials-memorials/schedule-a-burial', title: 'Schedule a burial for a Veteran or family member', summary: null, - } + }, ], - sectionTitle: 'Related information' + sectionTitle: 'Related information', } const { container } = render() - expect(container.innerHTML).toContain('Eligibility for burial in a VA national cemetery') - expect(container.innerHTML).toContain('href="https://va.gov/burials-memorials/eligibility"') - expect(container.innerHTML).toContain('Schedule a burial for a Veteran or family member') - expect(container.innerHTML).toContain('href="https://va.gov/burials-memorials/schedule-a-burial"') + expect(container.innerHTML).toContain( + 'Eligibility for burial in a VA national cemetery' + ) + expect(container.innerHTML).toContain( + 'href="https://va.gov/burials-memorials/eligibility"' + ) + expect(container.innerHTML).toContain( + 'Schedule a burial for a Veteran or family member' + ) + expect(container.innerHTML).toContain( + 'href="https://va.gov/burials-memorials/schedule-a-burial"' + ) }) test('renders link correctly when there is only one', () => { @@ -35,14 +43,18 @@ describe('RelatedLinks Component', () => { uri: 'https://va.gov/burials-memorials/schedule-a-burial', title: 'Schedule a burial for a Veteran or family member', summary: null, - } + }, ], - sectionTitle: 'VA benefits' + sectionTitle: 'VA benefits', } const { container } = render() - expect(container.innerHTML).toContain('Schedule a burial for a Veteran or family member') - expect(container.innerHTML).toContain('href="https://va.gov/burials-memorials/schedule-a-burial"') + expect(container.innerHTML).toContain( + 'Schedule a burial for a Veteran or family member' + ) + expect(container.innerHTML).toContain( + 'href="https://va.gov/burials-memorials/schedule-a-burial"' + ) }) }) diff --git a/src/templates/common/relatedLinks/index.tsx b/src/templates/common/relatedLinks/index.tsx index c4a28cdd2..b6aa2493c 100644 --- a/src/templates/common/relatedLinks/index.tsx +++ b/src/templates/common/relatedLinks/index.tsx @@ -5,7 +5,7 @@ import { FormattedRelatedLinks } from '@/types/formatted/relatedLinks' // Does not map directly to any one Drupal type; it is simply a shared UI component export const RelatedLinks = ({ links, - sectionTitle + sectionTitle, }: FormattedRelatedLinks): JSX.Element => { if (isEmpty(links)) { return null @@ -16,10 +16,7 @@ export const RelatedLinks = ({ <>

- +

{summary}

@@ -35,15 +32,19 @@ export const RelatedLinks = ({ className="vads-u-margin-bottom--3 vads-u-display--flex vads-u-flex-direction--column" data-next-component="templates/common/RelatedLinks" > - {sectionTitle &&

{sectionTitle}

} + {sectionTitle && ( +

+ {sectionTitle} +

+ )} {links.length > 1 && (
    - {links.map((link, index) => ( -
  • - {renderLink(link.uri, link.title, link.summary)} -
  • - ))} + {links.map((link, index) => ( +
  • + {renderLink(link.uri, link.title, link.summary)} +
  • + ))}
)} diff --git a/src/templates/common/relatedLinks/relatedLinks.stories.ts b/src/templates/common/relatedLinks/relatedLinks.stories.ts index 5204fde28..113d63ffe 100644 --- a/src/templates/common/relatedLinks/relatedLinks.stories.ts +++ b/src/templates/common/relatedLinks/relatedLinks.stories.ts @@ -23,7 +23,7 @@ export const Example: Story = { uri: 'https://va.gov/burials-memorials/schedule-a-burial', title: 'Schedule a burial for a Veteran or family member', summary: null, - } - ] + }, + ], }, } diff --git a/src/templates/common/secondaryButtonGroup/index.test.tsx b/src/templates/common/secondaryButtonGroup/index.test.tsx index 0bd2627e8..b1889270e 100644 --- a/src/templates/common/secondaryButtonGroup/index.test.tsx +++ b/src/templates/common/secondaryButtonGroup/index.test.tsx @@ -9,21 +9,27 @@ describe('SecondaryButtonGroup Component', () => { { id: '1', label: 'Button one', - url: 'https://www.va.gov/button-one' + url: 'https://www.va.gov/button-one', }, { id: '2', label: 'Button two', - url: 'https://www.va.gov/button-two' - } + url: 'https://www.va.gov/button-two', + }, ] - const { container } = render() + const { container } = render( + + ) expect(container.innerHTML).toContain('Button one') - expect(container.innerHTML).toContain('href="https://www.va.gov/button-one"') + expect(container.innerHTML).toContain( + 'href="https://www.va.gov/button-one"' + ) expect(container.innerHTML).toContain('Button two') - expect(container.innerHTML).toContain('href="https://www.va.gov/button-two"') + expect(container.innerHTML).toContain( + 'href="https://www.va.gov/button-two"' + ) }) test('renders action link correctly when there is only one', () => { @@ -31,13 +37,15 @@ describe('SecondaryButtonGroup Component', () => { { id: '1', label: 'Single button', - url: 'https://www.va.gov/single-button' - } + url: 'https://www.va.gov/single-button', + }, ] const { container } = render() expect(container.innerHTML).toContain('Single button') - expect(container.innerHTML).toContain('href="https://www.va.gov/single-button"') + expect(container.innerHTML).toContain( + 'href="https://www.va.gov/single-button"' + ) }) }) diff --git a/src/templates/common/secondaryButtonGroup/index.tsx b/src/templates/common/secondaryButtonGroup/index.tsx index f12eec6d3..d333626d8 100644 --- a/src/templates/common/secondaryButtonGroup/index.tsx +++ b/src/templates/common/secondaryButtonGroup/index.tsx @@ -3,8 +3,10 @@ import { ParagraphComponent } from '@/types/formatted/paragraph' // Used for R&S pages; either a single blue CTA link or multiple export const SecondaryButtonGroup = ({ - buttons -}: { buttons: ParagraphComponent[] }): JSX.Element => { + buttons, +}: { + buttons: ParagraphComponent[] +}): JSX.Element => { if (buttons.length > 1) { return (
    { +const canUseWebComponent = (telephone) => { if (!telephone || /[a-zA-Z+]/.test(telephone)) { return false } @@ -24,10 +24,7 @@ export const EmailContact = ( return (
  • {label}  - +
  • ) } @@ -44,10 +41,7 @@ export const PhoneContact = ( return (
  • {label}  - +
  • ) } @@ -56,7 +50,9 @@ export const PhoneContact = ( } // nested paragraphs -const AdditionalContact = (contact: FormattedEmailContact | FormattedPhoneContact) => { +const AdditionalContact = ( + contact: FormattedEmailContact | FormattedPhoneContact +) => { switch (contact.type) { case PARAGRAPH_RESOURCE_TYPES.EMAIL_CONTACT: return @@ -68,14 +64,14 @@ const AdditionalContact = (contact: FormattedEmailContact | FormattedPhoneContac // node--support-service nodes that get included const BenefitHubContacts = ({ contacts }) => { - return contacts.map(contact => { - const { href, label, number } = contact; + return contacts.map((contact) => { + const { href, label, number } = contact if (number && canUseWebComponent(number)) { const phone = { extension: null, label, - number + number, } return @@ -84,10 +80,7 @@ const BenefitHubContacts = ({ contacts }) => { return (
  • {label}  - +
  • ) }) diff --git a/src/templates/components/rateYourExperience/index.test.tsx b/src/templates/components/rateYourExperience/index.test.tsx index 413ce2405..d9abe7afb 100644 --- a/src/templates/components/rateYourExperience/index.test.tsx +++ b/src/templates/components/rateYourExperience/index.test.tsx @@ -7,8 +7,12 @@ describe('', () => { const good = document.querySelector('#Good') const bad = document.querySelector('#Bad') - const radioHeader = document.querySelector('[label="How do you rate your experience on this page?') - const submitButton = document.querySelector('va-button[text="Submit feedback"]') + const radioHeader = document.querySelector( + '[label="How do you rate your experience on this page?' + ) + const submitButton = document.querySelector( + 'va-button[text="Submit feedback"]' + ) expect(radioHeader).toBeInTheDocument() expect(good).toBeInTheDocument() diff --git a/src/templates/components/rateYourExperience/index.tsx b/src/templates/components/rateYourExperience/index.tsx index c3ac5fe1f..2a23b340c 100644 --- a/src/templates/components/rateYourExperience/index.tsx +++ b/src/templates/components/rateYourExperience/index.tsx @@ -2,7 +2,10 @@ import { MouseEvent, useState } from 'react' import { BUILD_TYPES } from '@/lib/constants/environment' import { recordEvent } from '@/lib/analytics/recordEvent' import { getSurveyNumber, showForm } from '@/lib/utils/medallia' -import { VaRadio, VaRadioOption } from '@department-of-veterans-affairs/component-library/dist/react-bindings' +import { + VaRadio, + VaRadioOption, +} from '@department-of-veterans-affairs/component-library/dist/react-bindings' export const RateYourExperience = () => { const header = 'How do you rate your experience on this page?' @@ -40,10 +43,7 @@ export const RateYourExperience = () => { const isProduction = process.env.NEXT_PUBLIC_BUILD_TYPE === BUILD_TYPES.PROD - const surveyNumber = getSurveyNumber( - window.location.pathname, - isProduction - ) + const surveyNumber = getSurveyNumber(window.location.pathname, isProduction) showForm(surveyNumber) } @@ -58,7 +58,7 @@ export const RateYourExperience = () => { aria-hidden={isSubmitted} label={header} label-header-level="2" - onVaValueChange={e => handleRatingChange(e.detail.value)} + onVaValueChange={(e) => handleRatingChange(e.detail.value)} > { id="rate-your-experience--thank-you-message" className={`vads-u-margin-bottom-0 ${isSubmitted ? 'vads-u-display--block' : 'vads-u-display--none'}`} > - Want to share more feedback? We'll use it to keep improving VA.gov for all Veterans and their families.  + Want to share more feedback? We'll use it to keep improving VA.gov + for all Veterans and their families.