Skip to content
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

Adding byline support to text introductions #7348

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

csebianlander
Copy link
Contributor

Blog posts currently support the generation of bylines using the item-introduction block. We have a need for other page types to use a byline. This PR modifies the text-introduction template and corresponding molecule block to create the same byline in the same manner.


Additions

  • New "Published Date (BYLINE ONLY)" field on Text Introduction blocks
  • Byline (date + author/s) in the text-introduction.html template

How to test this PR

  1. localhost
  2. Open a page that uses a text introduction
  3. Add a date into the new "Published Date" field
  4. Add author(s) in the Configuration tab
  5. View the updated/published page

Screenshots

Back-end:
Screen Shot 2022-11-16 at 11 11 35 AM

Front-end:
Screen Shot 2022-11-16 at 11 13 35 AM

Notes and todos

  • The placement of the byline differs from the item-introduction due to differences in how this line relates to the content (i.e. on blog posts the intro content field is used for subheadings and can should have the byline below; on non-blogs that content is usually a full introductory paragraph, which should come after the byline)

Checklist

  • PR has an informative and human-readable title
    • PR titles are used to generate the change log in releases; good ones make that easier to scan.
    • Consider prefixing, e.g., "Mega Menu: fix layout bug", or "Docs: Update Docker installation instructions".
  • Changes are limited to a single goal (no scope creep)
  • Code follows the standards laid out in the CFPB development guidelines
  • Future todos are captured in comments and/or tickets
  • Project documentation has been updated, potentially one or more of:
    • This repo’s docs (edit the files in the /docs folder) – for basic, close-to-the-code docs on working with this repo
    • CFGOV/platform wiki on GHE – for internal CFPB developer guidance
    • CFPB/hubcap wiki on GHE – for internal CFPB design and content guidance

@chosak
Copy link
Member

chosak commented Nov 23, 2022

@csebianlander I rebased and expanded this in #7367 to avoid the duplication of byline code; would you mind giving that a look?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants