aboutsummaryrefslogtreecommitdiff
path: root/doc/docs/.vuepress/theme/components/SidebarButton.vue
diff options
context:
space:
mode:
authorLi Jin <dragon-fly@qq.com>2021-04-19 23:41:33 +0800
committerLi Jin <dragon-fly@qq.com>2021-04-19 23:41:33 +0800
commit5d3b07801456d16dcc2c75dcccd48d508a6b60cc (patch)
tree2df1a154bf58d93f2475df02afbd15f1a8ba2963 /doc/docs/.vuepress/theme/components/SidebarButton.vue
parentea82666506b57d6e905b7f2e5fe78498fe5a7abd (diff)
downloadyuescript-5d3b07801456d16dcc2c75dcccd48d508a6b60cc.tar.gz
yuescript-5d3b07801456d16dcc2c75dcccd48d508a6b60cc.tar.bz2
yuescript-5d3b07801456d16dcc2c75dcccd48d508a6b60cc.zip
first commit for Yuescript document site.
Diffstat (limited to 'doc/docs/.vuepress/theme/components/SidebarButton.vue')
-rw-r--r--doc/docs/.vuepress/theme/components/SidebarButton.vue40
1 files changed, 40 insertions, 0 deletions
diff --git a/doc/docs/.vuepress/theme/components/SidebarButton.vue b/doc/docs/.vuepress/theme/components/SidebarButton.vue
new file mode 100644
index 0000000..3f54afd
--- /dev/null
+++ b/doc/docs/.vuepress/theme/components/SidebarButton.vue
@@ -0,0 +1,40 @@
1<template>
2 <div
3 class="sidebar-button"
4 @click="$emit('toggle-sidebar')"
5 >
6 <svg
7 class="icon"
8 xmlns="http://www.w3.org/2000/svg"
9 aria-hidden="true"
10 role="img"
11 viewBox="0 0 448 512"
12 >
13 <path
14 fill="currentColor"
15 d="M436 124H12c-6.627 0-12-5.373-12-12V80c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12z"
16 class=""
17 />
18 </svg>
19 </div>
20</template>
21
22<style lang="stylus">
23.sidebar-button
24 cursor pointer
25 display none
26 width 1.25rem
27 height 1.25rem
28 position absolute
29 padding 0.6rem
30 top 0.6rem
31 left 1rem
32 .icon
33 display block
34 width 1.25rem
35 height 1.25rem
36
37@media (max-width: $MQMobile)
38 .sidebar-button
39 display block
40</style>