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

fix: APPS-2385 byline error on production news article #721

Merged
merged 1 commit into from
Aug 16, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 9 additions & 41 deletions pages/about/news/_slug.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
:category="parsedCategory"
:title="page.title"
:text="page.text"
:byline="parsedBylineBannerText"
:byline="parsedByline"
:locations="parsedLocations"
:date-created="page.postDate"
/>
Expand Down Expand Up @@ -102,24 +102,14 @@ export default {
},
computed: {
parsedByline() {
let byline = (this.page.contributors || []).map((entry) => {
return `${entry.byline || ""} ${
entry.title || entry.staffMember[0].title
}`
let byline = (this.page.contributors || []).map((contributor) => {
if ((contributor.staffMember && contributor.staffMember.length > 0) || contributor.title)
return `${contributor.byline || ""} ${ contributor.title || contributor.staffMember[0].title}`
})
return byline.map((entry) => {
return entry
return byline.map((contributor) => {
return contributor
})
},
parsedBylineBannerText() {
return (this.page.contributors || []).map((entry) => {
return `${entry.byline} ${
entry.title || entry.staffMember[0].title
}`
})
},
parsedDate() {
return format(new Date(this.page.postDate), "MMMM d, Y")
},
Expand Down Expand Up @@ -151,30 +141,8 @@ export default {

<style lang="scss" scoped>
.page-news-detail {
.highlighted-news {
@include visually-hidden;
}
// .flexible-content {
// margin: 0 auto;
// }
// @media #{$medium} {
// .block-campus-map,
// .section-block-spaces,
// .block-hours,
// .block-amenities,
// .simple-cards,
// .section-teaser-list,
// .section-teaser-card {
// padding: 0 var(--unit-gutter);
// }
// }
// @media #{$small} {
// .page {
// width: 100%;
// }
// }
.highlighted-news {
@include visually-hidden;
}
}
</style>
Loading