diff --git a/components/atoms/SessionArchivedHeader.vue b/components/atoms/SessionArchivedHeader.vue
new file mode 100644
index 00000000..1b8ee8e2
--- /dev/null
+++ b/components/atoms/SessionArchivedHeader.vue
@@ -0,0 +1,24 @@
+
+
+
+
+
+
+
diff --git a/components/molecules/TrackList.vue b/components/molecules/TrackList.vue
index 6f97efa6..46d72e3b 100644
--- a/components/molecules/TrackList.vue
+++ b/components/molecules/TrackList.vue
@@ -71,7 +71,9 @@ export default class extends Vue {
background-color: $bg-color;
}
#windowWrapper {
- min-height: calc(100vh - 56px);
+ // 56px: Toolbar
+ // 12px: 再生中の曲の上margin
+ min-height: calc(100vh - 56px - 12px);
}
.v-subheader {
diff --git a/components/organisms/BottomController.vue b/components/organisms/BottomController.vue
index 88dc19cb..be42a9a3 100644
--- a/components/organisms/BottomController.vue
+++ b/components/organisms/BottomController.vue
@@ -2,7 +2,12 @@
-
+
devices
@@ -11,11 +16,15 @@
pause
-
-
- playlist_add
-
-
+
+ playlist_add
+
@@ -36,7 +45,10 @@ import ActiveDeviceNotFoundDialog from '@/components/organisms/ActiveDeviceNotFo
},
computed: {
...mapState('pages/sessions/detail', ['session']),
- ...mapGetters('pages/sessions/detail', ['canControlPlayback'])
+ ...mapGetters('pages/sessions/detail', [
+ 'canControlPlayback',
+ 'isSessionArchived'
+ ])
}
})
export default class extends Vue {
diff --git a/components/organisms/TrackListContainer.vue b/components/organisms/TrackListContainer.vue
index 6bda1218..44f0d6e5 100644
--- a/components/organisms/TrackListContainer.vue
+++ b/components/organisms/TrackListContainer.vue
@@ -1,5 +1,5 @@
-
+
@@ -44,9 +44,6 @@ export default class extends Vue {
+
diff --git a/store/pages/sessions/detail.ts b/store/pages/sessions/detail.ts
index 43204392..64479f0a 100644
--- a/store/pages/sessions/detail.ts
+++ b/store/pages/sessions/detail.ts
@@ -44,11 +44,16 @@ export const getters = {
return state.session.creator.id === rootState.user.me?.id
},
canControlPlayback(state: State, getters): boolean {
+ if (getters.isSessionArchived) return false
return (
getters.isMyOwnSession ||
// eslint-disable-next-line camelcase
(state.session?.allow_to_control_by_others ?? false)
)
+ },
+ isSessionArchived(state: State): boolean {
+ if (!state.session) return false
+ return state.session.playback.state.type === 'ARCHIVED'
}
}