You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

47 lines
770 B

<template>
<view>
<view class="scan_float" @click="goScan('bottom')">
<image src="@/static/icons_ui/icon_add.svg"></image>
<view>{{btnName}}</view>
</view>
</view>
</template>
<script setup lang="ts">
import {
ref,
nextTick
} from 'vue'
const props = defineProps({
btnName: {
type: String,
default: '创建'
},
})
const x = ref(0)
const y = ref(0)
const old= ref({
x: 0,
y: 0
})
const goScan=(content)=> {
emit("goScan", '');
}
const tap=(e) =>{
x.value = old.value.x
y.value = old.value.y
nextTick(function() {
x.value = 30
y.value = 30
})
}
const onChange=(e) =>{
old.value.x = e.detail.x
old.value.y = e.detail.y
}
// 传递给父类
const emit = defineEmits(['goScan'])
</script>
<style>
</style>