From cb1407b70bb91e9e5d29041987ec8077689728fc Mon Sep 17 00:00:00 2001 From: nokhnaton Date: Fri, 24 Jan 2025 14:58:40 +0900 Subject: [PATCH 1/5] =?UTF-8?q?Qall=E4=B8=AD=E3=83=81=E3=83=A3=E3=83=B3?= =?UTF-8?q?=E3=83=8D=E3=83=AB=E3=81=AE=E8=A1=A8=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../NavigationContent/HomeTab.vue | 16 +++++-- src/composables/qall/useLiveKitSDK.ts | 22 ++++------ src/composables/qall/useQall.ts | 42 +++++++++++++++++++ 3 files changed, 63 insertions(+), 17 deletions(-) diff --git a/src/components/Main/NavigationBar/NavigationContent/HomeTab.vue b/src/components/Main/NavigationBar/NavigationContent/HomeTab.vue index 8cce33b66..622a61737 100644 --- a/src/components/Main/NavigationBar/NavigationContent/HomeTab.vue +++ b/src/components/Main/NavigationBar/NavigationContent/HomeTab.vue @@ -41,17 +41,19 @@ import ChannelList from '/@/components/Main/NavigationBar/ChannelList/ChannelLis import ChannelTree from '/@/components/Main/NavigationBar/ChannelList/ChannelTree.vue' import NavigationContentContainer from '/@/components/Main/NavigationBar/NavigationContentContainer.vue' import DMChannelList from '/@/components/Main/NavigationBar/DMChannelList/DMChannelList.vue' -import { computed, toRaw } from 'vue' +import { computed, toRaw, watchEffect } from 'vue' import { constructTreeFromIds } from '/@/lib/channelTree' import { useChannelTree } from '/@/store/domain/channelTree' import { useMeStore } from '/@/store/domain/me' import { useChannelsStore } from '/@/store/entities/channels' import useChannelsWithNotification from '/@/composables/subscription/useChannelsWithNotification' import { filterTrees } from '/@/lib/basic/tree' +import { useQall } from '/@/composables/qall/useQall' const { homeChannelTree } = useChannelTree() const { detail } = useMeStore() const { channelsMap } = useChannelsStore() +const { roomWithParticipants } = useQall() const homeChannelWithTree = computed(() => { if (!detail.value?.homeChannel) return [] @@ -70,8 +72,16 @@ const topLevelChannels = computed(() => // filterTreesは重いのと内部ではreactiveである必要がないのでtoRawする filterTrees(toRaw(homeChannelTree.value.children), node => !node.archived) ) -// TODO: Qall -const qallingChannels = [] + +const qallingChannels = computed(() => + roomWithParticipants.value + .map(room => channelsMap.value.get(room.roomId)) + .flatMap(channel => (channel?.archived === false ? [channel] : [])) +) + +watchEffect(() => { + console.log('qalling', qallingChannels.value) +}) diff --git a/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallController.vue b/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallController.vue deleted file mode 100644 index 9da2db7e3..000000000 --- a/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallController.vue +++ /dev/null @@ -1,39 +0,0 @@ - - - diff --git a/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallDetailsPanel.vue b/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallDetailsPanel.vue deleted file mode 100644 index e26781e05..000000000 --- a/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallDetailsPanel.vue +++ /dev/null @@ -1,60 +0,0 @@ - - - - - diff --git a/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallDetailsPanelUser.vue b/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallDetailsPanelUser.vue deleted file mode 100644 index adf5578aa..000000000 --- a/src/components/Main/NavigationBar/EphemeralNavigationContent/QallController/QallDetailsPanelUser.vue +++ /dev/null @@ -1,138 +0,0 @@ - - - - -