NCIOCPL / cgov-digital-platform

The Cancer.gov Digital Communications Platform
GNU General Public License v2.0
11 stars 33 forks source link

Story: Update Cancer Information Summary content type with Intro Text field #3229

Closed sarinapadilla closed 2 years ago

sarinapadilla commented 3 years ago

As the system, I want to be able to render a Cancer Information Summary content item with an intro text field, so that users can display intro text aligning with SEO best practice for the SVPC initiative.

We need to update Drupal to reflect the inclusion of an “intro text” field on CDR cancer information summary documents, and be able to display this intro text on the front end. This will also update the Publish Preview display of the summary in the CDR.

Tasks: update schema for incoming CDR cancer information summaries, update pdq_cancer_information_summary UI, update pdq_cancer_information_summary front-end display (which also updates CDR Publish Preview), update syndication template

ESTIMATE 2

Acceptance Criteria

Drupal/CGov

UI:

Scenario: Content editor can see intro text on the Liver Cancer Treatment content item in Drupal
Given the user is logged into the CMS as an editor
  And the incoming Liver Cancer Treatment CDR document has the intro text field filled
  And this CDR document has been successfully processed into the CMS
  When the user edits the Liver Cancer Treatment pdq_cancer_information_summary content item
Then the system displays the intro text field above the first body section title/body section field
  And the field has the content from the CDR document
Scenario: Content editor can see intro text on the Liver Cancer Screening content item in Drupal
Given the user is logged into the CMS as an editor
  And the incoming Liver Cancer Screening CDR document does not have the intro text field filled
  And this CDR document has been successfully processed into the CMS
  When the user edits the Liver Cancer Screening pdq_cancer_information_summary content item
Then the system displays the intro text field above the first body section title/body section field
  And the field is empty

Desktop:

Scenario: User views the Liver Cancer Treatment content item with intro text on CGov on desktop
Given the Liver Cancer Treatment pdq_cancer_information_summary content item exists in the CMS
  And the content item has intro text
When a user views the Liver Cancer Treatment page on CGov at the desktop breakpoint
Then the intro text appears on the CGov page following the H2
  And there is no link to the intro text from the On This Page (if it displays)
Scenario: User views the Liver Cancer Screening content item without intro text on CGov on desktop
Given the Liver Cancer Screening pdq_cancer_information_summary content item exists in the CMS
  And the content item does not have intro text
When a user views the Liver Cancer Screening page on CGov at the desktop breakpoint
Then no intro text appears on the CGov page
  And the next page section (On This Page or body section title/body section) appears on the CGov page following the H2

Tablet:

Scenario: User views the Liver Cancer Treatment content item with intro text on CGov on tablet
Given the Liver Cancer Treatment pdq_cancer_information_summary content item exists in the CMS
  And the content item has intro text
When a user views the Liver Cancer Treatment page on CGov at the tablet breakpoint
Then the intro text appears on the CGov page following the H2
  And there is no link to the intro text from the On This Page (if it displays)
Scenario: User views the Liver Cancer Screening content item with intro text on CGov on tablet
Given the Liver Cancer Screening pdq_cancer_information_summary content item exists in the CMS
  And the content item does not have intro text
When a user views the Liver Cancer Screening page on CGov at the tablet breakpoint
Then no intro text appears on the CGov page
  And the next page section (On This Page or body section title/body section) appears on the CGov page following the H2

Mobile:

Scenario: User views the Liver Cancer Treatment content item with intro text on CGov on mobile
Given the Liver Cancer Treatment pdq_cancer_information_summary content item exists in the CMS
  And the content item has intro text
When a user views the Liver Cancer Treatment page on CGov at the mobile breakpoint
Then the intro text appears on the CGov page following the H2
Scenario: User views the Liver Cancer Screening content item with intro text on CGov on mobile
Given the Liver Cancer Screening pdq_cancer_information_summary content item exists in the CMS
  And the content item does not have intro text
When a user views the Liver Cancer Screening page on CGov at the tablet breakpoint
Then no intro text appears on the CGov page
  And the body section accordion displays on the CGov page following the H2

Syndication:

TBD

Publish Preview

Scenario: User views the Liver Cancer Treatment content item with intro text in CDR Publish Preview
Given the Liver Cancer Treatment CDR document has an intro text section
When a user views the Liver Cancer Treatment page on CDR Publish Preview
Then the intro text appears on the Publish Preview page following the H2
  And there is no link to the section from the On This Page (if it displays)
Scenario: User views the Liver Cancer Screening content item with intro text in CDR Publish Preview
Given the Liver Cancer Screening CDR document does not have an intro text section
When a user views the Liver Cancer Screening page on CDR Publish Preview
Then no intro text appears on the Publish Preview page
  And the next page section (On This Page or body section title/body section) appears on the CGov page following the H2

Resources:

Notes

Some complementary notes if necessary:


Solution

Prerequisites

Tasks

Technical Notes

bkline commented 2 years ago

I think most of the scenarios in this issue belong with #3230.

sarinapadilla commented 2 years ago

@bkline I'll rewrite this and #3230 so they are decoupled!

bkline commented 2 years ago

@sarinapadilla I'm starting in on this ticket. Have anything for the syndication TBD above?

bkline commented 2 years ago

I just went ahead and modified the syndication template to include the intro text before the summary sections.

bkline commented 2 years ago

Installed on https://ncigovcdode444.prod.acquia-sites.com/