Browse Source

refactor: 删除更改

develop
xuesinan 4 years ago
parent
commit
70865cf50d
  1. 1
      CHANGELOG.md
  2. 21
      src/components/Globals/Globals.vue
  3. 11
      src/components/Roles/Roles.vue

1
CHANGELOG.md

@ -147,6 +147,7 @@
### 🔨 代码重构 ### 🔨 代码重构
范围|描述|commitId 范围|描述|commitId
--|--|-- --|--|--
- | 改变时间轴角色栏、日常任务面板的样式 | 1b8958f
- | 界面样式调整 | 4367249 - | 界面样式调整 | 4367249
- | 任务状态重构 | 4693655 - | 任务状态重构 | 4693655
- | 删除多余的技术验证界面 | 542ae5b - | 删除多余的技术验证界面 | 542ae5b

21
src/components/Globals/Globals.vue

@ -1,24 +1,15 @@
<template> <template>
<view class="m-2" v-if="globals && globals.length"> <view class="m-2" v-if="globals && globals.length">
<!-- <u-card
@click="openCard"
:show-foot="false"
:show-head="false"
:style="{ 'max-height': isShrink ? '120rpx' : '340rpx' }"
border-radius="25"
margin="0"
> -->
<u-card <u-card
@click="openCard" @click="openCard"
:show-foot="false" :show-foot="false"
:show-head="false" :show-head="false"
:style="{ 'min-height': '42px', 'max-height': globalsHeight + 'px' }" :style="{ 'max-height': isShrink ? '106rpx' : '340rpx' }"
border-radius="25" border-radius="25"
margin="0" margin="0"
> >
<view slot="body"> <view slot="body">
<!-- <scroll-view :scrollY="true" :style="{ 'max-height': isShrink ? '60rpx' : '280rpx' }"> --> <scroll-view :scrollY="true" :style="{ 'max-height': isShrink ? '50rpx' : '280rpx' }">
<scroll-view :scrollY="true" :style="{ 'min-height': '24rpx', 'max-height': globalsHeight - 30 + 'px' }">
<skeleton :banner="false" :loading="!globals.length" :row="4" animate class="u-line-2 skeleton"></skeleton> <skeleton :banner="false" :loading="!globals.length" :row="4" animate class="u-line-2 skeleton"></skeleton>
<view class="grid gap-2"> <view class="grid gap-2">
<block v-for="item in globals" :key="item.id"> <block v-for="item in globals" :key="item.id">
@ -49,8 +40,6 @@
import { mapGetters, mapMutations, mapState } from 'vuex'; import { mapGetters, mapMutations, mapState } from 'vuex';
import Skeleton from '@/components/Skeleton/Skeleton'; import Skeleton from '@/components/Skeleton/Skeleton';
const sysHeight = uni.getSystemInfoSync().screenHeight;
export default { export default {
name: 'Global', name: 'Global',
components: { Skeleton }, components: { Skeleton },
@ -59,18 +48,12 @@ export default {
return { return {
// loading: true, // loading: true,
task: null, task: null,
sysHeight: sysHeight,
}; };
}, },
computed: { computed: {
...mapState('task', ['isShrink']), ...mapState('task', ['isShrink']),
...mapGetters('task', ['globals']), ...mapGetters('task', ['globals']),
globalsHeight: function () {
let h = ((this.sysHeight - 44 - 30 - 10) / 5) * 4;
return h;
},
}, },
methods: { methods: {

11
src/components/Roles/Roles.vue

@ -150,21 +150,16 @@ export default {
.tab-box { .tab-box {
position: relative; position: relative;
white-space: nowrap; white-space: nowrap;
height: 60rpx;
display: flex;
align-items: center;
// height: 84rpx; // height: 84rpx;
.tab-item { .tab-item {
// width: 20%; // width: 20%;
// height: 84rpx; // height: 84rpx;
padding: 0 24rpx; padding: 20rpx 24rpx;
position: relative; position: relative;
// display: inline-block; display: inline-block;
// text-align: center; text-align: center;
font-size: 30rpx; font-size: 30rpx;
height: 60rpx;
line-height: 60rpx;
transition-property: background-color, width; transition-property: background-color, width;
} }

Loading…
Cancel
Save