ant-design-vue/site/components/geektime.vue

47 lines
940 B
Vue
Raw Normal View History

2019-03-18 17:09:41 +08:00
<template>
2019-07-04 18:28:27 +08:00
<div id="geektime" v-show="visible">
2019-03-18 17:09:41 +08:00
<a
2019-03-18 17:27:45 +08:00
href="https://time.geekbang.org/course/intro/163?code=KHKYcoBU6vZa8nMglg7AWfDxxi3BWrz9INAzAY3umPk%3D"
2019-03-18 17:09:41 +08:00
target="_blank"
>
<img
2019-07-04 18:28:27 +08:00
width="170"
2019-03-18 17:09:41 +08:00
alt="Vue 实战教程"
2019-07-04 18:28:27 +08:00
src="https://cdn.nlark.com/yuque/0/2019/jpeg/87084/1562230861353-assets/web-upload/2fab2df7-5cc9-4791-b344-a97da29eb400.jpeg"
2019-03-18 17:09:41 +08:00
>
</a>
2019-07-04 18:28:27 +08:00
<div v-if="isMobile" class="close" @click="visible=false">
<a-icon type="close"></a-icon>
</div>
</div>
2019-03-18 17:09:41 +08:00
</template>
<script>
export default {
2019-07-04 18:28:27 +08:00
props: ['isMobile'],
data() {
return {
visible: true
}
}
2019-03-18 17:09:41 +08:00
};
</script>
2019-07-04 18:28:27 +08:00
<style lang="less" scoped>
2019-03-18 17:09:41 +08:00
#geektime {
position: fixed;
2019-03-19 15:35:51 +08:00
bottom: 15px;
right: 15px;
2019-07-04 18:28:27 +08:00
.close {
position: absolute;
text-align: center;
top: -8px;
right: -8px;
font-size: 16px;
padding: 15px;
color: #6e3041;
}
2019-03-18 17:09:41 +08:00
}
</style>