popover and palette
This commit is contained in:
parent
89b05cfc57
commit
07a48315a1
5 changed files with 112 additions and 55 deletions
24
src/components/tooltip/tooltip.vue
Normal file
24
src/components/tooltip/tooltip.vue
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
<template>
|
||||
<Popover trigger="hover">
|
||||
<template #trigger>
|
||||
<slot />
|
||||
</template>
|
||||
<template #content>
|
||||
<div class="tooltip">
|
||||
{{ props.text }}
|
||||
</div>
|
||||
</template>
|
||||
</Popover>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import Popover from 'src/components/popover/popover.vue'
|
||||
|
||||
const props = defineProps(['text'])
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.tooltip {
|
||||
margin: 0.5em 1em;
|
||||
}
|
||||
</style>
|
||||
Loading…
Add table
Add a link
Reference in a new issue