Skip to content

Commit 9481a65

Browse files
authored
feat: APPS-2865 Create EventSeries detail page / slug template to verify gql query data (#31)
* get the data on the page! * image carousel and responsive image working * Card Meta working * add link to series list page * update component-library, design tokens & linting * update the slug page name * update query * fix input of data * update watch * update page date visually on the page for clarity * update breadcrumb with screening dettails * recommended updates * add h3 to to index * cleanup * cleanup * resonsive image update * fixed the page.value = _get(newVal * update library components & linting
1 parent 3b967da commit 9481a65

File tree

8 files changed

+409
-40
lines changed

8 files changed

+409
-40
lines changed

gql/queries/FTVAEventDetailSeries.gql

Lines changed: 0 additions & 23 deletions
This file was deleted.

gql/queries/FTVAEventSeriesDetail.gql

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
#import "../gql/fragments/Image.gql"
2+
3+
query FTVAEventSeriesDetail ($slug: [String!]) {
4+
ftvaEventSeries: entry(section: "ftvaEventSeries", slug: $slug) {
5+
imageCarousel {
6+
... on imageCarousel_imageCarousel_BlockType {
7+
image {
8+
...Image
9+
}
10+
creditText
11+
}
12+
}
13+
title
14+
guestSpeaker
15+
ftvaEventIntroduction
16+
eventDescription
17+
richText
18+
startDate
19+
endDate
20+
ongoing
21+
location {
22+
title
23+
campusMapId
24+
publicUrl
25+
address {
26+
addressLine1
27+
addressLine2
28+
addressCity
29+
addressState
30+
addressZipCode
31+
addressCountry
32+
}
33+
}
34+
ftvaTicketInformation {
35+
title
36+
}
37+
ftvaEvent {
38+
uri
39+
eventTitle
40+
startDateWithTime
41+
ftvaImage {
42+
...Image
43+
}
44+
ftvaEventFilters {
45+
title
46+
}
47+
}
48+
}
49+
upcomingEvents: entries(section: "ftvaEvent", relatedToEntries: { section: "ftvaEventSeries", slug: $slug }, startDateWithTime: ">= now", orderBy: "startDateWithTime ASC") {
50+
uri
51+
eventTitle
52+
startDateWithTime
53+
ftvaImage {
54+
...Image
55+
}
56+
ftvaEventFilters {
57+
title
58+
}
59+
}
60+
pastEvents: entries(section: "ftvaEvent", relatedToEntries: { section: "ftvaEventSeries", slug: $slug }, startDateWithTime: "< now", orderBy: "startDateWithTime ASC") {
61+
uri
62+
eventTitle
63+
startDateWithTime
64+
ftvaImage {
65+
...Image
66+
}
67+
ftvaEventFilters {
68+
title
69+
}
70+
}
71+
otherSeriesOngoing: entries(section: "ftvaEventSeries", limit: 3, ongoing: true) {
72+
uri
73+
title
74+
startDate
75+
endDate
76+
ongoing
77+
ftvaImage {
78+
...Image
79+
}
80+
}
81+
otherSeriesUpcoming: entries(section: "ftvaEventSeries", limit: 3, endDate: ">=now", orderBy: "startDate ASC") {
82+
uri
83+
title
84+
startDate
85+
endDate
86+
ongoing
87+
ftvaImage {
88+
...Image
89+
}
90+
}
91+
}

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
"lodash": "^4.17.21",
3939
"nuxt-graphql-request": "^7.0.5",
4040
"sass": "^1.66.1",
41-
"ucla-library-design-tokens": "^5.20.0",
42-
"ucla-library-website-components": "3.9.0"
41+
"ucla-library-design-tokens": "^5.22.0",
42+
"ucla-library-website-components": "3.10.0"
4343
}
4444
}

pages/[...slug].vue.bak

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,10 @@ onMounted(() => {
132132
</main>
133133
</template>
134134

135-
<style lang="scss" scoped>
135+
<style
136+
lang="scss"
137+
scoped
138+
>
136139
.page-general-content {
137140
.section-banner {
138141
margin-top: 0;

pages/events/[slug].vue

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ const series = ref(_get(data.value, 'ftvaEventSeries', {}))
3838
3939
watch(data, (newVal, oldVal) => {
4040
console.log('In watch preview enabled, newVal, oldVal', newVal, oldVal)
41-
page.value = _get(data.value, 'ftvaEvent', {})
42-
series.value = _get(data.value, 'ftvaEventSeries', {})
41+
page.value = _get(newVal, 'ftvaEvent', {})
42+
series.value = _get(newVal, 'ftvaEventSeries', {})
4343
})
4444
4545
// Get data for Image or Carousel at top of page
@@ -219,7 +219,10 @@ const parsedFTVAEventScreeningDetails = computed(() => {
219219
</main>
220220
</template>
221221
222-
<style lang="scss" scoped>
222+
<style
223+
lang="scss"
224+
scoped
225+
>
223226
// VARS - TO DO move to global? reference tokens?
224227
// WIDTH, HEIGHT, SPACING
225228
$max-width: 1160px;

0 commit comments

Comments
 (0)