Files
dvcp_v2_wxcp_app/src/components/AiBottomBtn.vue

58 lines
1.1 KiB
Vue
Raw Normal View History

2022-05-19 17:28:53 +08:00
<template>
<section class="AiBottomBtn">
2022-12-12 12:02:23 +08:00
<div class="transport" v-if="$slots.default">
<slot/>
</div>
2022-05-19 17:28:53 +08:00
<u-gap v-else height="112"/>
2022-12-29 14:35:15 +08:00
<div class="fixed" @click="$emit('click')" :style="{background}">
2022-05-19 17:28:53 +08:00
<slot v-if="$slots.default"/>
2022-12-29 14:35:15 +08:00
<div v-else class="text" :class="{circle}" v-text="text"/>
2022-05-19 17:28:53 +08:00
</div>
</section>
</template>
<script>
export default {
name: "AiBottomBtn",
props: {
2022-12-29 14:35:15 +08:00
text: {default: ""},
circle: Boolean,
background: {default: "inherit"}
2022-05-19 17:28:53 +08:00
}
}
</script>
<style lang="scss" scoped>
.AiBottomBtn {
.fixed {
position: fixed;
bottom: 0;
width: 100vw;
2023-01-03 10:20:41 +08:00
z-index: 202301031019;
2022-05-19 17:28:53 +08:00
}
.text {
width: 100%;
font-family: PingFangSC-Medium, PingFang SC;
line-height: 112px;
text-align: center;
font-weight: 500;
color: #FFFFFF;
background: #1365DD;
box-shadow: inset 0px 1px 0px 0px #EEEEEE;
2022-12-29 14:35:15 +08:00
&.circle {
border-radius: 52px;
line-height: 80px;
flex-shrink: 0;
padding: 0 70px;
width: auto;
}
2022-05-19 17:28:53 +08:00
}
2022-12-12 12:02:23 +08:00
.transport {
opacity: 0;
}
2022-05-19 17:28:53 +08:00
}
</style>