-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
27 changed files
with
1,779 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
VUE_APP_RES_URL=http://192.168.197.1:8081 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,5 @@ | ||
@import 'reset'; | ||
@import "reset"; | ||
@import "./mixin"; | ||
@import "./transition.scss" | ||
|
||
// 1rem = fontSize px | ||
// 1px = (1 / fontSize)rem 为什么缩放比例是37.5呢? | ||
$fontSize: 37.5; | ||
@function px2rem($px) { | ||
@return ($px / $fontSize) + rem; | ||
} | ||
|
||
@mixin center() { | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
} | ||
|
||
.icon { | ||
color: #333; | ||
font-size: px2rem(20); | ||
} | ||
|
||
.slide-down-enter, .slide-down-leave-to { | ||
transform: translate3d(0, -100%, 0) | ||
} | ||
.slide-down-enter-to, .slide-down-leave, .slide-up-enter-to, .slide-up-leave { | ||
transform: translate3d(0, 0, 0) | ||
} | ||
.slide-down-enter-active, .slide-down-leave-active, .slide-up-enter-active, .slide-up-leave-active, .fade-enter-active, .fade-leave-active, .slide-right-enter-active, .slide-right-leave-active { | ||
transition: all .3s linear; | ||
} | ||
.slide-up-enter, .slide-up-leave-to { | ||
transform: translate3d(0, px2rem(108), 0) | ||
} | ||
.fade-enter, .fade-leave-to { | ||
opacity: 0; | ||
} | ||
.fade-enter-to, .fade-leave { | ||
opacity: 1; | ||
} | ||
.slide-right-enter, .slide-right-leave-to { | ||
transform: translate3d(-100%, 0, 0); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
$ratio: 375 / 10; | ||
@function px2rem($px) { | ||
@return ($px / $ratio) + rem; // rem ? 'rem'? equal? | ||
} | ||
|
||
@mixin center { | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
} | ||
|
||
@mixin left { | ||
display: flex; | ||
justify-content: flex-start; | ||
align-items: center; | ||
} | ||
|
||
@mixin right { | ||
display: flex; | ||
justify-content: flex-end; | ||
align-items: center; | ||
} | ||
|
||
@mixin ellipsis { | ||
text-overflow: ellipsis; // 如果超出使用省略号 | ||
overflow: hidden; // 超出部分隐藏 | ||
white-space: nowrap; // 不换行 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
.slide-down-enter, .slide-down-leave-to { | ||
transform: translate3d(0, -100%, 0) | ||
} | ||
.slide-down-enter-to, .slide-down-leave, .slide-up-enter-to, .slide-up-leave { | ||
transform: translate3d(0, 0, 0) | ||
} | ||
.slide-down-enter-active, .slide-down-leave-active, | ||
.slide-up-enter-active, .slide-up-leave-active, | ||
.fade-enter-active, .fade-leave-active, | ||
.slide-right-enter-active, .slide-right-leave-active, | ||
.popup-slide-up-enter-active, .popup-slide-up-leave-active | ||
{ | ||
transition: all .2s linear; | ||
} | ||
.slide-up-enter, .slide-up-leave-to { | ||
transform: translate3d(0, px2rem(138), 0) | ||
} | ||
.fade-enter, .fade-leave-to { | ||
opacity: 0; | ||
} | ||
.fade-enter-to, .fade-leave { | ||
opacity: 1; | ||
} | ||
.slide-right-enter, .slide-right-leave-to { | ||
transform: translate3d(-100%, 0, 0); | ||
} | ||
.popup-slide-up-enter, .popup-slide-up-leave-to { | ||
transform: translate3d(0, 100%, 0); | ||
opacity: 0; | ||
} | ||
.popup-slide-up-enter-to, .popup-slide-up-leave { | ||
transform: translate3d(0, 0, 0); | ||
opacity: 1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
<template> | ||
<div> | ||
<transition name="slide-up"> | ||
<div class="menu-wrapper" | ||
:class="{'hide-box-shadow': !menuVisible || settingVisible >= 0}" | ||
v-show="menuVisible"> | ||
<div class="icon-wrapper"> | ||
<span class="icon-menu" @click="showSetting(3)"></span> | ||
</div> | ||
<div class="icon-wrapper"> | ||
<span class="icon-progress" @click="showSetting(2)"></span> | ||
</div> | ||
<div class="icon-wrapper"> | ||
<span class="icon-bright" @click="showSetting(1)"></span> | ||
</div> | ||
<div class="icon-wrapper"> | ||
<span class="icon-A" @click="showSetting(0)"></span> | ||
</div> | ||
</div> | ||
</transition> | ||
<ebook-setting-font></ebook-setting-font> | ||
<ebook-setting-font-popup></ebook-setting-font-popup> | ||
<ebook-setting-theme></ebook-setting-theme> | ||
<ebook-setting-progress></ebook-setting-progress> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
/* eslint-disable */ | ||
import EbookSettingFont from './EbookSettingFont' | ||
import EbookSettingFontPopup from './EbookSettingFontPopup' | ||
import EbookSettingTheme from './EbookSettingTheme' | ||
import EbookSettingProgress from './EbookSettingProgress' | ||
import { ebookMixin } from '../../utils/mixin' | ||
export default { | ||
mixins: [ebookMixin], | ||
components: { | ||
EbookSettingFont, | ||
EbookSettingFontPopup, | ||
EbookSettingTheme, | ||
EbookSettingProgress | ||
}, | ||
methods: { | ||
showSetting (key) { | ||
this.setSettingVisible(key) | ||
} | ||
} | ||
} | ||
</script> | ||
|
||
<style lang='scss' scoped> | ||
@import "../../assets/styles/global"; | ||
.menu-wrapper { | ||
position: absolute; | ||
bottom: 0; | ||
left: 0; | ||
z-index: 102; | ||
display: flex; | ||
width: 100%; | ||
height: px2rem(48); | ||
background: white; | ||
box-shadow: 0 px2rem(-8) px2rem(8) rgba(0, 0, 0, .15); | ||
font-size: px2rem(20); | ||
&.hide-box-shadow { | ||
box-shadow: none; | ||
} | ||
.icon-wrapper { | ||
flex: 1; | ||
@include center; | ||
.icon-progress { | ||
font-size: px2rem(24); | ||
} | ||
.icon-bright { | ||
font-size: px2rem(21); | ||
} | ||
} | ||
} | ||
</style> |
Oops, something went wrong.