-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtext.vue
101 lines (97 loc) · 2.45 KB
/
text.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<template>
<v-row justify="center" align="center">
<v-col
v-for="tool in tools"
:key="tool.name"
cols="12"
md="4"
sm="6"
>
<v-card elevation="2" outlined class="card-outter" height="100%">
<v-card-title>
<v-icon class="accent--text mr-2">
mdi-{{ tool.icon }}
</v-icon>
{{ tool.name.toUpperCase() }}
<v-spacer />
<v-icon v-if="tool.external" class="accent--text">
mdi-signal-variant
</v-icon>
</v-card-title>
<v-card-text class="text--primary">
<div>{{ tool.desc }}</div>
</v-card-text>
<v-spacer />
<v-card-actions class="card-actions pa-4">
<v-dialog
v-model="tool.dialog"
fullscreen
hide-overlay
transition="dialog-bottom-transition"
>
<template v-slot:activator="{ on, attrs }">
<v-btn
color="primary"
v-bind="attrs"
v-on="on"
>
USE ME
</v-btn>
</template>
<component :is="tool.name.split(' ').join('')" :tool="tool" />
</v-dialog>
</v-card-actions>
</v-card>
</v-col>
</v-row>
</template>
<script>
import Info from '@/components/text/info.json'
import Downcase from '@/components/text/Downcase'
import Upcase from '@/components/text/Upcase'
import Capitalize from '@/components/text/Capitalize'
import Reverse from '@/components/text/Reverse'
import CountWords from '@/components/text/CountWords'
import CountCharacters from '@/components/text/CountCharacters'
import Clappy from '@/components/text/Clappy'
import Mock from '@/components/text/Mock'
export default {
components: {
Downcase,
Upcase,
Capitalize,
Reverse,
CountWords,
CountCharacters,
Clappy,
Mock
},
data: () => ({
tools: Info
}),
head () {
const title = 'Text'
const desc = title + 'Tools'
return {
title,
meta: [
{ hid: 'description', name: 'description', content: desc },
{ name: 'og:description', content: desc },
{ name: 'og:title', content: title + ' - Argyle' }
]
}
}
}
</script>
<style lang="less" scoped>
.card-outter {
position: relative;
padding-bottom: 50px;
overflow-x: auto;
.card-actions {
position: absolute;
bottom: 0;
right: 0;
}
}
</style>