mirror of
https://github.com/elk-zone/elk.git
synced 2024-09-16 08:59:59 +01:00
18 lines
271 B
Vue
18 lines
271 B
Vue
|
<script setup lang="ts">
|
||
|
const { modelValue } = defineModel<{
|
||
|
modelValue: boolean
|
||
|
}>()
|
||
|
|
||
|
const el = ref<HTMLDivElement>()
|
||
|
|
||
|
onClickOutside(el, () => {
|
||
|
modelValue.value = false
|
||
|
})
|
||
|
</script>
|
||
|
|
||
|
<template>
|
||
|
<div ref="el" absolute bg-base>
|
||
|
<slot />
|
||
|
</div>
|
||
|
</template>
|