|
|
|
@ -104,20 +104,13 @@ async function onOpenModal({
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
const isEasterEggEnabled = ref(false) |
|
|
|
|
|
|
|
|
|
watch(isOpen, (val) => { |
|
|
|
|
if (!val) { |
|
|
|
|
isEasterEggEnabled.value = false |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
</script> |
|
|
|
|
|
|
|
|
|
<template> |
|
|
|
|
<NcDropdown v-model:visible="isOpen" :overlay-class-name="overlayClassName" destroy-popup-on-hide @click.stop="isOpen = true"> |
|
|
|
|
<slot /> |
|
|
|
|
<template #overlay> |
|
|
|
|
<NcMenu class="max-w-48" @dblclick.stop="isEasterEggEnabled = true"> |
|
|
|
|
<NcMenu class="max-w-48"> |
|
|
|
|
<NcMenuItem @click.stop="onOpenModal({ type: ViewTypes.GRID })"> |
|
|
|
|
<div class="item" data-testid="sidebar-view-create-grid"> |
|
|
|
|
<div class="item-inner"> |
|
|
|
@ -164,7 +157,6 @@ watch(isOpen, (val) => {
|
|
|
|
|
</div> |
|
|
|
|
</NcMenuItem> |
|
|
|
|
<NcMenuItem |
|
|
|
|
v-if="isEasterEggEnabled" |
|
|
|
|
data-testid="sidebar-view-create-calendar" |
|
|
|
|
@click="onOpenModal({ type: ViewTypes.CALENDAR })" |
|
|
|
|
> |
|
|
|
|