Skip to content

Conversation

@breakdancingcat
Copy link
Member

@breakdancingcat breakdancingcat commented Dec 22, 2025

Reason for Change

The promo-view template does not render HTML in the excerpt field. However, the grid-item, list-item, and spotlight component's excerpts allow some HTML for formatting job titles, quotes, or adding emphasis. Since these components have the option to display the promo with the promo-view template, the excerpt needs to support the same functionality.

The promo grid-item and list-item excerpt fields have been updated to the same allow list as the spotlight component. Line break has been included in the allow list for cases where the individual has multiple job titles and needs them displayed on separate lines.

Resources to review for consistency:
Spotlight component:
https://github.com/waynestate/base-site/blob/master/resources/views/components/spotlight-row.blade.php#L20

Promo grid item:
https://github.com/waynestate/base-site/blob/master/resources/views/components/spotlight-row.blade.php#L20

Promo list item:
https://github.com/waynestate/base-site/blob/master/resources/views/components/promo/list-item.blade.php#L35

Profile template (line break example):
https://github.com/waynestate/base-site/blob/master/resources/views/components/profile.blade.php#L10


Demo / Context

Basecamp: https://3.basecamp.com/5750155/buckets/37389969/todos/9407952665

No visual change when HTML is not used

Before After
image image

When HTML is used

Before After
image image

Final Checklist

  • I have reviewed my code and it follows project standards
  • I have tested the changes locally
  • I have added or updated relevant documentation
  • I have added tests (if applicable)
  • I have communicated with the team about necessary post-deploy actions

@coveralls
Copy link

coveralls commented Dec 22, 2025

Coverage Status

coverage: 99.083%. remained the same
when pulling 5fdf5aa on feature/promo-view
into e96d37c on develop.

Copy link
Contributor

@KyleApsey KyleApsey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Non-blocking: Is there a way to set this in the repository or model?

@breakdancingcat
Copy link
Member Author

Non-blocking: Is there a way to set this in the repository or model?

@KyleApsey - I can't think of one at the moment.

I am a proponent of logic going into the repository as much as possible, but excerpts don't usually contain HTML in a majority of cases which makes it seem inefficient to check every promotion's excerpt rather than handling it in the view.
I am interested in continuing this discussion if there is more to think about!

@breakdancingcat breakdancingcat self-assigned this Dec 22, 2025
@breakdancingcat breakdancingcat added this to the 8.16.0 Release milestone Dec 22, 2025
@breakdancingcat breakdancingcat merged commit 88d9bcd into develop Dec 22, 2025
2 checks passed
Copy link
Member

@nickdenardis nickdenardis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants