Skip to content

Commit

Permalink
style: icon and code optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
hq001 committed Dec 2, 2020
1 parent 3968e85 commit 855ae10
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 11 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

- 打造一款跨端播放器,减低用户学习成本。
- 希望完成全音乐播放,避免版权问题不能播放。
- 通过完成此项目,接触 vue3 新功能以及周边生态。
- 接触 vue3 新功能以及周边生态,提升编码水平、有效合理的组织代码结构与逻辑
- [TypeScript 4.x](https://github.com/Microsoft/TypeScript) 已经发布,它的好处已经足够明显,故借此项目深入学习。
- 使用前沿技术让一个项目从 0 到 1 的过程不仅可以提升我们的 coding 水平,还可以提升非 coding (设计、 git 、 nginx 等)的能力。

Expand Down Expand Up @@ -64,6 +64,8 @@ yarn
| 歌手搜索、专辑列表 | | | |
| 排行榜(歌单、歌手) | | | |
| 朋友动态查看、点赞等 | | | |
| 下载管理 | | | |
| 音乐云盘 | | | |
| 视频播放、收藏 | | | |
| 歌单列表、全部播放、收藏、添加待播放队列 | | | |
| 推荐歌单、推荐歌曲、热搜榜 | | | |
Expand Down
1 change: 1 addition & 0 deletions script/theme.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ fs.watchFile(path.resolve(themePath, 'color.less'), (curr, prev) => {
}`
let { css } = await less.render(lessSource)
css = css.split('\n')

content = ''
for (let i = 0; i < css.length; i++) {
const v = css[i]
Expand Down
2 changes: 1 addition & 1 deletion src/iconfont/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ import $script from 'scriptjs'
import { noop } from '@/utils/index'

// repair electron packaging '//' protocol problem
$script('https://at.alicdn.com/t/font_2132275_2fbtdtwvogo.js', noop)
$script('https://at.alicdn.com/t/font_2132275_l43m9hqmon.js', noop)
18 changes: 9 additions & 9 deletions src/pages/footer/component/volume-history/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,6 @@ export const VolumeAndHistory = defineComponent({
const volume = useGetter('volume')
const current = ref(volume * 100)

const slots = {
prefix: () => (
<ve-button type="text">
<icon icon="volume" color="#333"></icon>
</ve-button>
)
}

const updateCurrent = (v: number) => {
current.value = v
const volume = toFixed(v / 100, 2)
Expand All @@ -43,6 +35,14 @@ export const VolumeAndHistory = defineComponent({
volume && useMutations(Mutations.SET_VOLUME, volume < 0 ? 0 : volume)
})

const slots = {
prefix: () => (
<ve-button type="text">
<icon icon="volume" color="#333" size={26}></icon>
</ve-button>
)
}

return () => (
<div class="volume">
<div class="volume-bar">
Expand All @@ -65,7 +65,7 @@ export const VolumeAndHistory = defineComponent({
visible.value = !visible.value
}}
>
<icon icon="play-list-fill" color="#333"></icon>
<icon icon="play-list-fill" color="#333" size={20}></icon>
</ve-button>
</div>
</div>
Expand Down

0 comments on commit 855ae10

Please sign in to comment.