添加list头

This commit is contained in:
jmal 2020-02-17 17:59:14 +08:00
parent 022d8e1ef1
commit ad96e6a446
3 changed files with 26 additions and 3 deletions

View File

@ -0,0 +1 @@
<svg t="1581932721716" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="29668" width="32" height="32"><path d="M864 0H160a128.384 128.384 0 0 0-128 128v768a128.384 128.384 0 0 0 128 128h545.792L992 739.488V128a128.384 128.384 0 0 0-128-128z m-288 736H224a32 32 0 0 1 0-64h352a32 32 0 0 1 0 64z m224-224H224a32 32 0 0 1 0-64h576a32 32 0 0 1 0 64z m0-224H224a32 32 0 0 1 0-64h576a32 32 0 0 1 0 64z" fill="#FFC177" p-id="29669"></path><path d="M704 1024v-288h288z" fill="#FFD4A6" p-id="29670"></path></svg>

After

Width:  |  Height:  |  Size: 547 B

View File

@ -98,7 +98,6 @@ export function formatTime(agoTime) {
}
export function formatSize(size) {
console.log(size)
if (size < 1024) {
return size + 'B'
} else if (size < 1024 * 1024) {

View File

@ -6,11 +6,31 @@
finished-text="没有更多了"
@load="getFileList"
>
<van-row class="classification">
<van-col span="6" align="center">
<svg-icon icon-class="image" />
<div>图片</div>
</van-col>
<van-col span="6" align="center">
<svg-icon icon-class="document" />
<div>文档</div>
</van-col>
<van-col span="6" align="center">
<svg-icon icon-class="video" />
<div>视屏</div>
</van-col>
<van-col span="6" align="center">
<svg-icon icon-class="audio" />
<div>音乐</div>
</van-col>
</van-row>
<!--<van-cell v-for="item in fileList" :key="item.id" :title="item.name"></van-cell>-->
<!--<van-cell v-for="item in fileList" :key="item.id" :title="item.name" :label="item.updateDate"></van-cell>-->
<van-swipe-cell v-for="(item,index) in fileList" :key="item.id" :title="item.name">
<van-divider v-if="index === 0" style="margin: 0 15px 10px 15px;"></van-divider>
<van-row type="flex" justify="center">
<van-divider v-if="index === 0" style="margin: 0 15px 0px 15px;"></van-divider>
<van-row>
<van-col span="4" align="center">
<svg-icon v-if="item.isFavorite" icon-class="menu-favorite-hover" style="font-size: 1rem;float: right;margin-bottom: -1rem;position: relative;" />
<svg-icon v-if="item.isFolder" icon-class="folder" />
@ -134,4 +154,7 @@ export default {
white-space: nowrap;
text-overflow:ellipsis;
}
.classification {
padding: 1rem 0 1rem 0;
}
</style>