56 lines
916 B
Vue
56 lines
916 B
Vue
<template>
|
|
<view class="title-pull border-box pad-zy20 flex" :style="{'justify-content':moreUrl==''?'center':'space-between'}">
|
|
<view class="txt font32">
|
|
<text>{{nameTxt}}</text>
|
|
<view class="line"></view>
|
|
</view>
|
|
<view class="more font20 opacity-06" @tap="toMore(moreUrl)" v-if="moreUrl!==''">更多+</view>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name: 'title-pull',
|
|
props: {
|
|
// 标题
|
|
nameTxt: {
|
|
type: String,
|
|
default: ''
|
|
},
|
|
// 链接
|
|
moreUrl: {
|
|
type: String,
|
|
default: ''
|
|
},
|
|
},
|
|
data() {
|
|
return {
|
|
|
|
}
|
|
},
|
|
methods: {
|
|
// 查看更多
|
|
toMore(url) {
|
|
uni.navigateTo({
|
|
url:url
|
|
})
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped>
|
|
.title-pull{
|
|
align-items: center;
|
|
}
|
|
.title-pull .txt{
|
|
line-height: 1.5;
|
|
}
|
|
.title-pull .line{
|
|
width: 100%;
|
|
height: 8rpx;
|
|
background-color: rgba(28,37,136,.5);
|
|
margin-top: -15rpx;
|
|
}
|
|
</style>
|