From aae9239177d5ad5c8057df623d1141b6df076d9e Mon Sep 17 00:00:00 2001 From: Erik Roberts Date: Tue, 22 Nov 2022 21:00:46 -0500 Subject: [PATCH 01/18] Add start of the individual production view --- .../production/ProductionCarousel.vue | 11 ++++++ .../production/ProductionCredits.vue | 11 ++++++ src/components/production/ProductionTags.vue | 11 ++++++ src/graphql/ReadProduction.graphql | 27 +++++++++++++++ src/graphql/types.ts | 8 +++++ src/router/index.ts | 11 ++++-- src/views/ProductionView.vue | 34 +++++++++++++++++++ 7 files changed, 110 insertions(+), 3 deletions(-) create mode 100644 src/components/production/ProductionCarousel.vue create mode 100644 src/components/production/ProductionCredits.vue create mode 100644 src/components/production/ProductionTags.vue create mode 100644 src/graphql/ReadProduction.graphql create mode 100644 src/views/ProductionView.vue diff --git a/src/components/production/ProductionCarousel.vue b/src/components/production/ProductionCarousel.vue new file mode 100644 index 0000000..ba851b8 --- /dev/null +++ b/src/components/production/ProductionCarousel.vue @@ -0,0 +1,11 @@ + + + + + diff --git a/src/components/production/ProductionCredits.vue b/src/components/production/ProductionCredits.vue new file mode 100644 index 0000000..ba851b8 --- /dev/null +++ b/src/components/production/ProductionCredits.vue @@ -0,0 +1,11 @@ + + + + + diff --git a/src/components/production/ProductionTags.vue b/src/components/production/ProductionTags.vue new file mode 100644 index 0000000..ba851b8 --- /dev/null +++ b/src/components/production/ProductionTags.vue @@ -0,0 +1,11 @@ + + + + + diff --git a/src/graphql/ReadProduction.graphql b/src/graphql/ReadProduction.graphql new file mode 100644 index 0000000..d28beed --- /dev/null +++ b/src/graphql/ReadProduction.graphql @@ -0,0 +1,27 @@ +query ReadProduction($id: ID!) { + ReadProduction: findOneProduction(id: $id) { + name + description + startTime + category { + name + } + images { + image { + id + description + path + } + } + videos { + video { + name + format + metadata + } + } + tags { + tag + } + } +} diff --git a/src/graphql/types.ts b/src/graphql/types.ts index 638f0a6..8f709bb 100644 --- a/src/graphql/types.ts +++ b/src/graphql/types.ts @@ -1717,6 +1717,13 @@ export type PermissionsForQueryVariables = Exact<{ export type PermissionsForQuery = { __typename?: 'Query', permissions: Array<{ __typename?: 'GroupPermission', action: string, subject: Array, fields?: Array | null, conditions?: any | null, inverted: boolean, reason?: string | null } | { __typename?: 'UserPermission', action: string, subject: Array, fields?: Array | null, conditions?: any | null, inverted: boolean, reason?: string | null }> }; +export type ReadProductionQueryVariables = Exact<{ + id: Scalars['ID']; +}>; + + +export type ReadProductionQuery = { __typename?: 'Query', ReadProduction?: { __typename?: 'Production', name: string, description?: string | null, startTime?: any | null, category?: { __typename?: 'Category', name?: string | null } | null, images?: Array<{ __typename?: 'ProductionImage', image: { __typename?: 'Image', id: string, description?: string | null, path: string } }> | null, videos?: Array<{ __typename?: 'ProductionVideo', video: { __typename?: 'Video', name: string, format: VideoFormat, metadata?: any | null } }> | null, tags?: Array<{ __typename?: 'ProductionTag', tag: string }> | null } | null }; + export type SelfIdQueryVariables = Exact<{ [key: string]: never; }>; @@ -1750,6 +1757,7 @@ export const FindAllProductionsDocument = {"kind":"Document","definitions":[{"ki export const ListStreamsDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"ListStreams"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"streams"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"to"}},{"kind":"Field","name":{"kind":"Name","value":"from"}},{"kind":"Field","name":{"kind":"Name","value":"message"}}]}}]}}]} as unknown as DocumentNode; export const LogoutDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"Logout"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","alias":{"kind":"Name","value":"logoutSuccess"},"name":{"kind":"Name","value":"logout"}}]}}]} as unknown as DocumentNode; export const PermissionsForDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"PermissionsFor"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"user"}},"type":{"kind":"NamedType","name":{"kind":"Name","value":"ID"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","alias":{"kind":"Name","value":"permissions"},"name":{"kind":"Name","value":"permissionsFor"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"user"},"value":{"kind":"Variable","name":{"kind":"Name","value":"user"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"InlineFragment","typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"GroupPermission"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"action"}},{"kind":"Field","name":{"kind":"Name","value":"subject"}},{"kind":"Field","name":{"kind":"Name","value":"fields"}},{"kind":"Field","name":{"kind":"Name","value":"conditions"}},{"kind":"Field","name":{"kind":"Name","value":"inverted"}},{"kind":"Field","name":{"kind":"Name","value":"reason"}}]}},{"kind":"InlineFragment","typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"UserPermission"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"action"}},{"kind":"Field","name":{"kind":"Name","value":"subject"}},{"kind":"Field","name":{"kind":"Name","value":"fields"}},{"kind":"Field","name":{"kind":"Name","value":"conditions"}},{"kind":"Field","name":{"kind":"Name","value":"inverted"}},{"kind":"Field","name":{"kind":"Name","value":"reason"}}]}}]}}]}}]} as unknown as DocumentNode; +export const ReadProductionDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"ReadProduction"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"id"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"ID"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","alias":{"kind":"Name","value":"ReadProduction"},"name":{"kind":"Name","value":"findOneProduction"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"id"},"value":{"kind":"Variable","name":{"kind":"Name","value":"id"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"description"}},{"kind":"Field","name":{"kind":"Name","value":"startTime"}},{"kind":"Field","name":{"kind":"Name","value":"category"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"name"}}]}},{"kind":"Field","name":{"kind":"Name","value":"images"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"image"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"description"}},{"kind":"Field","name":{"kind":"Name","value":"path"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"videos"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"video"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"format"}},{"kind":"Field","name":{"kind":"Name","value":"metadata"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"tags"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"tag"}}]}}]}}]}}]} as unknown as DocumentNode; export const SelfIdDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"SelfId"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"self"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]} as unknown as DocumentNode; export const StartStreamDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"StartStream"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"to"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}},{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"from"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","alias":{"kind":"Name","value":"success"},"name":{"kind":"Name","value":"createStream"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"input"},"value":{"kind":"ObjectValue","fields":[{"kind":"ObjectField","name":{"kind":"Name","value":"to"},"value":{"kind":"Variable","name":{"kind":"Name","value":"to"}}},{"kind":"ObjectField","name":{"kind":"Name","value":"from"},"value":{"kind":"Variable","name":{"kind":"Name","value":"from"}}}]}}]}]}}]} as unknown as DocumentNode; export const StopStreamDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"StopStream"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"id"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"ID"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","alias":{"kind":"Name","value":"success"},"name":{"kind":"Name","value":"deleteStream"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"id"},"value":{"kind":"Variable","name":{"kind":"Name","value":"id"}}}]}]}}]} as unknown as DocumentNode; diff --git a/src/router/index.ts b/src/router/index.ts index 513af5a..861ac9b 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -3,6 +3,7 @@ import { createRouter, createWebHistory } from "vue-router"; import HomeView from "../views/HomeView.vue"; import AboutView from "../views/AboutView.vue"; import ProductionsView from "../views/ProductionsView.vue"; +import ProductionView from "../views/ProductionView.vue"; import ContactView from "../views/ContactView.vue"; import LoginView from "../views/LoginView.vue"; import DonateView from "../views/DonateView.vue"; @@ -124,9 +125,13 @@ const router = createRouter({ }, }, { - path: "/productions", - name: "productions", - component: ProductionsView, + path: "/productions/:id", + name: "production", + component: restrictedComponent( + ProductionView, + AbilityActions.Read, + AbilitySubjects.Production + ), meta: { layoutCssName: "plain-layout", }, diff --git a/src/views/ProductionView.vue b/src/views/ProductionView.vue new file mode 100644 index 0000000..3143f16 --- /dev/null +++ b/src/views/ProductionView.vue @@ -0,0 +1,34 @@ + + + + + From d97000632100a8de2b10f15df49089af35e00dc2 Mon Sep 17 00:00:00 2001 From: Erik Roberts Date: Tue, 22 Nov 2022 21:15:08 -0500 Subject: [PATCH 02/18] Add props to ProductionView subcomponents --- src/components/production/ProductionCarousel.vue | 14 ++++++++++++++ src/components/production/ProductionCredits.vue | 8 ++++++++ src/components/production/ProductionTags.vue | 8 ++++++++ 3 files changed, 30 insertions(+) diff --git a/src/components/production/ProductionCarousel.vue b/src/components/production/ProductionCarousel.vue index ba851b8..e2a42a6 100644 --- a/src/components/production/ProductionCarousel.vue +++ b/src/components/production/ProductionCarousel.vue @@ -3,6 +3,20 @@ diff --git a/src/components/production/ProductionCredits.vue b/src/components/production/ProductionCredits.vue index ba851b8..4286f6f 100644 --- a/src/components/production/ProductionCredits.vue +++ b/src/components/production/ProductionCredits.vue @@ -3,7 +3,15 @@ From 33c7a300f23680f17c0ba600ebc2c2d1a6f393bc Mon Sep 17 00:00:00 2001 From: Erik Roberts Date: Wed, 23 Nov 2022 19:51:53 -0500 Subject: [PATCH 04/18] Add 16:9 aspect ratio player --- src/components/production/ProductionCarousel.vue | 7 ++++++- src/views/ProductionView.vue | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/components/production/ProductionCarousel.vue b/src/components/production/ProductionCarousel.vue index e2a42a6..e49a1cc 100644 --- a/src/components/production/ProductionCarousel.vue +++ b/src/components/production/ProductionCarousel.vue @@ -1,5 +1,7 @@ diff --git a/src/views/ProductionView.vue b/src/views/ProductionView.vue index 37b7465..c93af6c 100644 --- a/src/views/ProductionView.vue +++ b/src/views/ProductionView.vue @@ -57,6 +57,7 @@ const productionSubtitle = computed(() => { } .card { width: 80%; + margin-bottom: 3em; } .prod-title, .prod-subtitle { From 66cc72aeded6c30a9e19b874690a526078dfe752 Mon Sep 17 00:00:00 2001 From: 1milibyte Date: Thu, 24 Nov 2022 21:27:04 -0500 Subject: [PATCH 05/18] Mostly finished tags component Made a button that displays tags when clicked on, tags themselves are buttons but do nothing. Could also possibly have the wrong angle bracket. Getting the warning: runtime-core.esm-bundler.js:38 [Vue warn]: Invalid prop: type check failed for prop "tags". Expected Array, got Undefined at However, it doesn't seem to matter? Unsure if I can merge line 17 with 18 in any way. Used hr element instead of the divider component from naive because there are no color props in it. --- src/components/production/ProductionTags.vue | 30 +++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/src/components/production/ProductionTags.vue b/src/components/production/ProductionTags.vue index 37579ad..d730669 100644 --- a/src/components/production/ProductionTags.vue +++ b/src/components/production/ProductionTags.vue @@ -1,10 +1,25 @@ From ca029bd13e27464f9c2d38d7075a698eb412d075 Mon Sep 17 00:00:00 2001 From: Erik Roberts Date: Tue, 29 Nov 2022 20:37:54 -0500 Subject: [PATCH 06/18] Start work on video/image carousel --- .../production/ProductionCarousel.vue | 22 ++++++++++++++--- src/views/ProductionView.vue | 24 +++++++++++++++++-- 2 files changed, 41 insertions(+), 5 deletions(-) diff --git a/src/components/production/ProductionCarousel.vue b/src/components/production/ProductionCarousel.vue index e49a1cc..9a33987 100644 --- a/src/components/production/ProductionCarousel.vue +++ b/src/components/production/ProductionCarousel.vue @@ -1,12 +1,20 @@ diff --git a/src/views/ProductionView.vue b/src/views/ProductionView.vue index 90df965..5904d20 100644 --- a/src/views/ProductionView.vue +++ b/src/views/ProductionView.vue @@ -76,7 +76,8 @@ const productionSubtitle = computed(() => { justify-content: center; } .card { - width: 80%; + height: 100%; + width: 65%; margin-bottom: 3em; } From 70aa759e6a88a74d3fe1989b7c3a09e4f8bd4ac8 Mon Sep 17 00:00:00 2001 From: Erik Roberts Date: Wed, 21 Dec 2022 20:43:20 -0500 Subject: [PATCH 08/18] Add basic image/video display with real data to production page --- .../production/ProductionCarousel.vue | 6 ++- src/util/helper.ts | 9 ++++ src/views/ProductionView.vue | 54 +++++++++++-------- 3 files changed, 47 insertions(+), 22 deletions(-) diff --git a/src/components/production/ProductionCarousel.vue b/src/components/production/ProductionCarousel.vue index bb905c8..81be731 100644 --- a/src/components/production/ProductionCarousel.vue +++ b/src/components/production/ProductionCarousel.vue @@ -22,7 +22,7 @@ diff --git a/src/components/production/ProductionTags.vue b/src/components/production/ProductionTags.vue index d730669..3619635 100644 --- a/src/components/production/ProductionTags.vue +++ b/src/components/production/ProductionTags.vue @@ -5,9 +5,14 @@
+
- {{ tag }} + {{ tag }} +
+
+ No tags available for this production. +
From 43dbc948bf0a2764d4b78e2fbbe5e63d1b98da50 Mon Sep 17 00:00:00 2001 From: Erik Roberts Date: Fri, 30 Dec 2022 19:08:11 -0500 Subject: [PATCH 16/18] Update credits to be sorted and remove profile picture (for now) --- src/components/production/ProductionCredits.vue | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/components/production/ProductionCredits.vue b/src/components/production/ProductionCredits.vue index f36ceb1..95894a0 100644 --- a/src/components/production/ProductionCredits.vue +++ b/src/components/production/ProductionCredits.vue @@ -1,13 +1,9 @@