Skip to content

Commit

Permalink
Merge pull request #4341 from traPtitech/feat/hide_popupmenu_onitemcl…
Browse files Browse the repository at this point in the history
…icked

emitの追加によるclosePopupMenuの発火
  • Loading branch information
alter334 authored Jul 4, 2024
2 parents 492cfad + 63de970 commit a75c655
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
:channel-id="channelId"
:show-notification-setting-btn="!channelState.forced"
:is-archived="channelState.archived"
@click-item="closePopupMenu"
/>
</click-outside>
</channel-header-tools-list>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,38 +9,44 @@
:disabled="!canToggleQall"
:data-is-active="$boolAttr(isQallSessionOpened)"
@click="toggleQall"
@click-item="emit('clickItem')"
/>
<header-tools-menu-item
v-if="isChildChannelCreatable"
icon-name="hash"
label="子チャンネルを作成"
@click="openChannelCreateModal"
@click-item="emit('clickItem')"
/>
<header-tools-menu-item
v-if="showNotificationSettingBtn"
icon-name="notified-or-subscribed"
label="通知設定"
@click="openNotificationModal"
@click-item="emit('clickItem')"
/>
<header-tools-menu-item
v-if="isSearchEnabled"
icon-name="search"
icon-mdi
label="チャンネル内検索"
@click="openCommandPalette('search', 'in:here ')"
@click-item="emit('clickItem')"
/>
<header-tools-menu-item
icon-name="link"
icon-mdi
label="チャンネルリンクをコピー"
@click="copyLink"
@click-item="emit('clickItem')"
/>
<header-tools-menu-item
v-if="hasChannelEditPermission"
icon-name="hash"
:class="$style.manageChannel"
label="チャンネル管理"
@click="openChannelManageModal"
@click-item="emit('clickItem')"
/>
</primary-view-header-popup-frame>
</template>
Expand All @@ -60,6 +66,10 @@ import { useCommandPalette } from '/@/store/app/commandPalette'
import useChannelManageModal from './composables/useChannelManageModal'
import useCopyChannelLink from './composables/useCopyChannelLink'
const emit = defineEmits<{
(e: 'clickItem'): void
}>()
const props = withDefaults(
defineProps<{
channelId: ChannelId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,13 @@ const props = withDefaults(
const emit = defineEmits<{
(e: 'click'): void
(f: 'clickItem'): void
}>()
const onClick = () => {
if (props.disabled) return
emit('click')
emit('clickItem')
}
</script>

Expand Down

0 comments on commit a75c655

Please sign in to comment.