Authored by htoooth

add article content

<template>
<div v-if="topic" class="topic-wrap">
<div v-if="topic" class="topic-wrap" @click="onClick">
<div class="topic-icon">
<span class="iconfont icon-tag"></span>
</div>
... ... @@ -12,6 +12,11 @@ export default {
name: 'WidgetTopic',
props: {
topic: String,
},
methods: {
onClick() {
this.$emit('click');
}
}
};
</script>
... ...
<template>
<Scroll ref="scroll" class="scroll-wrapper" :options="scrollOpts" :scrollEvents="['scroll']" @scroll="onScroll">
<div class="scroll-wrapper">
<Author v-if="articleDetail" :data="articleDetail.getAuthor"></Author>
<div class="post-content" v-if="articleDetail">
... ... @@ -40,7 +41,7 @@
<Recommend v-if="articleDetail && articleDetail.getRecommendProducts.length > 0">
<RecommendProductList :list="articleDetail.getRecommendProducts"></RecommendProductList>
</Recommend>
</Scroll>
</div>
</template>
<script>
... ...
... ... @@ -84,6 +84,7 @@ export default {
.body {
flex: 1;
overflow: auto;
}
.footer {
... ...
<template>
<div>
<WidgetTopic v-for="(i, index) in list" :topic="i.name" :key="index"></WidgetTopic>
<WidgetTopic v-for="(i, index) in list" :topic="i.name" :key="index" @click="onClick"></WidgetTopic>
</div>
</template>
<script>
export default {
name: 'TagBar',
props: ['list']
props: ['list'],
methods: {
onClick() {
console.log('click');
}
}
};
</script>
<style scoped>
<style :lang="scss" scoped>
</style>
... ...