update
This commit is contained in:
28
src/components/XActionsheet.vue
Normal file
28
src/components/XActionsheet.vue
Normal file
@@ -0,0 +1,28 @@
|
||||
<script setup>
|
||||
import {ref} from "vue";
|
||||
|
||||
const emits = defineEmits(['success']);
|
||||
const show = ref(false);
|
||||
|
||||
const success = (e) => {
|
||||
emits('success', e);
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<view @longpress="show=true">
|
||||
<slot></slot>
|
||||
</view>
|
||||
|
||||
<tui-actionsheet
|
||||
v-bind="$attrs"
|
||||
:show="show"
|
||||
@click="success"
|
||||
@cancel="show=false">
|
||||
|
||||
</tui-actionsheet>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
Reference in New Issue
Block a user