Skip to content

Commit 167f344

Browse files
committed
feat: add fab button
1 parent 131929e commit 167f344

File tree

1 file changed

+35
-15
lines changed

1 file changed

+35
-15
lines changed

src/components/Introduction.vue

Lines changed: 35 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,65 @@
11
<template>
2-
<div class="container text-align-center">
3-
<div>
4-
<!-- vuetify -->
5-
<img src="@/assets/img/vuetify-logo-light-atom.svg" alt="vuetify" class="img-size" />
6-
<h1>Material Design Framework</h1>
7-
<p>Vuetify is a Vue UI Library with beautifully handcrafted Material Components. No design skills required — everything you need to create amazing applications is at your fingertips.</p>
8-
<a href="https://vuetifyjs.com/en/introduction/why-vuetify/#what-is-vuetify3f" target="_blank">What is Vuetify</a><br /><br />
9-
</div>
2+
<div class="container-width text-align-center">
103
<div>
114
<!-- vue -->
12-
<img src="@/assets/img/vue-logo.svg" alt="vuetify" class="img-size" />
5+
<img src="@/assets/img/vue-logo.svg" alt="vue-logo" class="img-size" />
136
<h1>The Progressive JavaScript Framework</h1>
147
<p>Vuetify is a Vue UI Library with beautifully handcrafted Material Components. No design skills required — everything you need to create amazing applications is at your fingertips.</p>
158
<a href="https://vuejs.org/index.html" target="_blank">What is vue.js</a><br /><br />
169
</div>
17-
<div>
10+
<div class="margin-top-50">
1811
<!-- d3 -->
19-
<img src="@/assets/img/d3.svg" alt="vuetify" class="img-size" />
12+
<img src="@/assets/img/d3.svg" alt="d3-logo" class="img-size" />
2013
<h1>Data-Driven Documents</h1>
21-
<p>D3.js is a JavaScript library for manipulating documents based on data. D3 helps you bring data to life using HTML, SVG, and CSS. D3’s emphasis on web standards gives you the full capabilities of modern browsers without tying yourself to a proprietary framework, combining powerful visualization components and a data-driven approach to DOM manipulation.</p>
14+
<p>
15+
D3.js is a JavaScript library for manipulating documents based on data. D3 helps you bring data to life using HTML, SVG, and CSS. D3’s emphasis on web standards gives you the full capabilities
16+
of modern browsers without tying yourself to a proprietary framework, combining powerful visualization components and a data-driven approach to DOM manipulation.
17+
</p>
2218
<a href="https://d3js.org/" target="_blank">What is d3.js</a><br /><br />
2319
</div>
20+
<div class="margin-top-50">
21+
<!-- vuetify -->
22+
<img src="@/assets/img/vuetify-logo-light-atom.svg" alt="vuetify-logo" class="img-size" />
23+
<h1>Material Design Framework</h1>
24+
<p>Vuetify is a Vue UI Library with beautifully handcrafted Material Components. No design skills required — everything you need to create amazing applications is at your fingertips.</p>
25+
<a href="https://vuetifyjs.com/en/introduction/why-vuetify/#what-is-vuetify3f" target="_blank">What is Vuetify</a><br /><br />
26+
</div>
27+
<v-fab-transition>
28+
<v-btn v-show="!hidden" color="primary" dark fixed bottom right fab @click="scrollTop">
29+
<v-icon>mdi-chevron-up</v-icon>
30+
</v-btn>
31+
</v-fab-transition>
2432
</div>
2533
</template>
2634
<script>
2735
export default {
2836
data () {
29-
return {}
37+
return {
38+
hidden: false
39+
}
3040
},
3141
mounted () {
3242
console.log('Introduction')
43+
},
44+
methods: {
45+
scrollTop () {
46+
window.scrollTo({
47+
top: 0,
48+
behavior: 'smooth'
49+
})
50+
}
3351
}
3452
}
3553
</script>
3654
<style scoped>
37-
.container {
55+
.container-width {
3856
width: calc(100% - 280px);
39-
/* border: 2px solid red; */
4057
}
4158
.img-size {
4259
width: 300px;
4360
height: 300px;
4461
}
62+
.margin-top-50 {
63+
margin-top: 50px;
64+
}
4565
</style>

0 commit comments

Comments
 (0)