Problem/Motivation

The design of the article banner shows the author's name on its own, in a medium weight, at the start of the row that ends with the Share links (media-banner/article-node in the design file). The Byline component always prints "By" before the name and has no font weight option, so an article page cannot match the design: it shows "By Chiara Romano" in the regular weight.

Screenshots

The article banner at 1440px, before and after the Byline options are used in the news article template. Before: the author reads "By Chiara Romano" in the regular weight and the Share links sit on the next line. After: the author reads "Chiara Romano" in the medium weight and the Share links are at the end of the same row, between two light dividers.

 By Chiara Romano in the regular weight, with the Share links on the line below

 Chiara Romano in the medium weight on the left and the Share links at the end of the same row, between two dividers; the summary at 20px, the caption at 16px and 24px under the image, and 144px between the text column and the image

Proposed resolution

Add two options to the Byline component, named like the Heading component's weight option:

  • show_prefix (boolean, default true): print "By" before the author's name. Off prints the name alone.
  • font_weight (fw-light to fw-bold, empty by default): the Bootstrap weight utility for the byline.

Existing bylines render as before. The Byline README and Storybook controls list the new options.

Remaining tasks

  • ✅ File an issue
  • ✅ Addition/Change/Update/Fix
  • ❌ Testing to ensure no regression
  • ➖ Automated unit/functional testing coverage
  • ✅ Developer Documentation support
  • ➖ User Guide Documentation support
  • ➖ UX/UI designer responsibilities
  • ❌ Accessibility and Readability
  • ❌ Reviewed by a human
  • ❌ Code review by maintainers
  • ❌ Full testing and approval
  • ❌ Credit contributors
  • ❌ Review with the product owner
  • ❌ Update Release Notes
  • ❌ Release

User interface changes

  • Canvas editors get two new options on the Byline component.

API changes

  • Two optional props on the Byline component, show_prefix and font_weight. The component's version hash changes.

Data model changes

  • N/A

Release notes snippet

  • The Byline component can print the author's name without "By" and in a chosen font weight.

AI-Generated: Yes. Drafted and tested with Claude Code, reviewed by the contributor.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

rajab natshah created an issue. See original summary.

rajab natshah’s picture

rajab natshah’s picture

Issue summary: View changes
rajab natshah’s picture

Issue summary: View changes
StatusFileSize
new236.12 KB

  • rajab natshah committed 5c69db8b on 1.0.x
    feat: #3628417 Let the Byline print the author name alone and in a...
rajab natshah’s picture

Issue summary: View changes
StatusFileSize
new238.88 KB

Updated the "after" screenshot in the summary: the article banner as it renders with the Byline options from this issue and the news template merged in https://git.drupalcode.org/project/rightup/-/merge_requests/73 (author name alone and Share on one row, summary at 20px, caption at 16px 24px under the image, 144px between the text column and the image).

rajab natshah’s picture

Status: Active » Fixed
Issue tags: +vartheme_bs5_rightup-1.0.4

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.