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.
66 lines
1006 B
66 lines
1006 B
<template>
|
|
<view>
|
|
<view class="btn" :style="{'--bgColor':bgColor,'width':btnWidth}" @click="$u.throttle(emitClick, 900)">
|
|
<text>{{ btnTitle }}</text>
|
|
</view>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name:"Btn",
|
|
props: {
|
|
btnTitle: {
|
|
type: String,
|
|
default () {
|
|
return '确认'
|
|
}
|
|
},
|
|
btnWidth: {
|
|
type: String,
|
|
default () {
|
|
return ''
|
|
}
|
|
},
|
|
bgColor: {
|
|
type: String,
|
|
default () {
|
|
return '#006BFF'
|
|
}
|
|
}
|
|
},
|
|
data() {
|
|
return {
|
|
|
|
};
|
|
},
|
|
methods: {
|
|
emitClick() {
|
|
this.$emit('emitClick')
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss" scoped>
|
|
.btn {
|
|
margin: 0 auto;
|
|
height: 92rpx;
|
|
line-height: 92rpx;
|
|
border-radius: 200rpx;
|
|
text-align: center;
|
|
letter-spacing: 3px;
|
|
color: #FFFFFF;
|
|
background: #006BFF;
|
|
// position:relative;
|
|
// left: 50%;
|
|
// transform: translateX(-50%);
|
|
// bottom:-150rpx;
|
|
// bottom:-200rpx;
|
|
margin-top: 80rpx;
|
|
.btnTttle {
|
|
font-size: 36rpx;
|
|
line-height: 32rpx;
|
|
}
|
|
}
|
|
</style>
|
|
|