From 532ef4e9d46ff470015668c4af42eae9be2d2250 Mon Sep 17 00:00:00 2001 From: Matteo Cominetti Date: Thu, 29 Jul 2021 17:00:07 +0200 Subject: [PATCH] feat(frontend): uniforms stream pages --- .../src/components/CollaboratorsManage.vue | 252 ++++++++++++++++++ .../src/components/GlobalsBuilder.vue | 41 +-- .../components/dialogs/StreamInviteDialog.vue | 6 +- packages/frontend/src/router/index.js | 9 + packages/frontend/src/views/Frontend.vue | 63 +++-- .../frontend/src/views/stream/Activity.vue | 1 + packages/frontend/src/views/stream/Branch.vue | 23 +- .../frontend/src/views/stream/Branches.vue | 26 +- .../src/views/stream/Collaborators.vue | 22 ++ .../frontend/src/views/stream/Globals.vue | 52 ++-- packages/frontend/src/views/stream/Home.vue | 38 +-- .../frontend/src/views/stream/Settings.vue | 142 +++++----- .../frontend/src/views/stream/Webhooks.vue | 23 +- 13 files changed, 521 insertions(+), 177 deletions(-) create mode 100644 packages/frontend/src/components/CollaboratorsManage.vue create mode 100644 packages/frontend/src/views/stream/Collaborators.vue diff --git a/packages/frontend/src/components/CollaboratorsManage.vue b/packages/frontend/src/components/CollaboratorsManage.vue new file mode 100644 index 000000000..a16730356 --- /dev/null +++ b/packages/frontend/src/components/CollaboratorsManage.vue @@ -0,0 +1,252 @@ + + diff --git a/packages/frontend/src/components/GlobalsBuilder.vue b/packages/frontend/src/components/GlobalsBuilder.vue index a08902d18..e0b853e3f 100644 --- a/packages/frontend/src/components/GlobalsBuilder.vue +++ b/packages/frontend/src/components/GlobalsBuilder.vue @@ -13,22 +13,33 @@ mdi-earth Globals - - Selected commit: - mdi-source-commit - {{ commitMessage }} - - - These global variables can be used for storing design values, project requirements, notes, or - any info you want to keep track of alongside your geometry. Variable values can be text, - numbers, lists, or booleans. Click the box icon next to any field to turn it into a nested - group of fields, and drag and drop fields in and out of groups as you please! Note that field - order may not always be preserved. - - - You are free to play around with the globals here, but you do not have the required stream - permission to save your changes. + + + Click the box icon next to any field to turn it into a nested group of fields, and drag and + drop fields in and out of groups as you please! Note that field order may not always be + preserved. + +
+
+ You are free to play around with the globals here, but you do not have the required stream + permission to save your changes. +
+ + Read the docs + +
+ Selected commit: + mdi-source-commit + {{ commitMessage }} +
+ import('@/views/stream/Activity.vue') }, + { + path: 'collaborators/', + name: 'collaborators', + meta: { + title: 'Stream Collaborators | Speckle' + }, + props: true, + component: () => import('@/views/stream/Collaborators.vue') + }, { path: 'settings/', name: 'settings', diff --git a/packages/frontend/src/views/Frontend.vue b/packages/frontend/src/views/Frontend.vue index f9f363ca4..ef8e53e3b 100644 --- a/packages/frontend/src/views/Frontend.vue +++ b/packages/frontend/src/views/Frontend.vue @@ -76,26 +76,43 @@ - - + + Stream menu - - - {{ menu.icon }} - + + + + {{ menu.icon }} + - - {{ menu.name }} - - + + {{ menu.name }} + + + + + mdi-email-send-outline + Invite to this +
+ stream by email +
+
@@ -134,9 +151,10 @@ import gql from 'graphql-tag' import userQuery from '../graphql/user.gql' import UserMenuTop from '../components/UserMenuTop' import SearchBar from '../components/SearchBar' +import StreamInviteDialog from '../components/dialogs/StreamInviteDialog' export default { - components: { UserMenuTop, SearchBar }, + components: { UserMenuTop, SearchBar, StreamInviteDialog }, data() { return { search: '', @@ -247,7 +265,7 @@ export default { { name: 'Collaborators', icon: 'mdi-account-group-outline', - click: 'manageCollabrators', + to: '/streams/' + this.$route.params.streamId + '/collaborators', disabled: this.stream.role !== 'stream:owner' }, { @@ -259,7 +277,7 @@ export default { { name: 'Settings', icon: 'mdi-cog-outline', - click: 'editStream', + to: '/streams/' + this.$route.params.streamId + '/settings', disabled: this.stream.role !== 'stream:owner' } ] @@ -274,11 +292,16 @@ export default { methods: { handleFunction(f) { if (this[f]) this[f]() + }, + showStreamInviteDialog() { + this.$refs.streamInviteDialog.show() } } }