提交 b0603133 编写于 作者: H hdx

components: rpx to px; 移除不必要的display: flex;

上级 a1e825d2
...@@ -62,7 +62,7 @@ ...@@ -62,7 +62,7 @@
this.$emit('unmount') this.$emit('unmount')
}, },
setTabBarBadge() { setTabBarBadge() {
if(this.hasShownTabBarRedDot){ if (this.hasShownTabBarRedDot) {
uni.hideTabBarRedDot({ uni.hideTabBarRedDot({
index: 1 index: 1
}) })
...@@ -81,7 +81,7 @@ ...@@ -81,7 +81,7 @@
this.hasSetTabBarBadge = !this.hasSetTabBarBadge this.hasSetTabBarBadge = !this.hasSetTabBarBadge
}, },
showTabBarRedDot() { showTabBarRedDot() {
if(this.hasSetTabBarBadge) { if (this.hasSetTabBarBadge) {
uni.removeTabBarBadge({ uni.removeTabBarBadge({
index: 1 index: 1
}) })
...@@ -145,12 +145,12 @@ ...@@ -145,12 +145,12 @@
<style> <style>
.button { .button {
margin-top: 30rpx; margin-top: 15px;
margin-left: 0; margin-left: 0;
margin-right: 0; margin-right: 0;
} }
.btn-area { .btn-area {
padding-top: 30rpx; padding-top: 15px;
} }
</style> </style>
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
<style> <style>
.button-data-main { .button-data-main {
justify-content: space-between; justify-content: space-between;
padding: 20rpx; padding: 10px;
border-bottom: 1px solid rgba(0,0,0,.06); border-bottom: 1px solid rgba(0, 0, 0, .06);
} }
</style> </style>
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
methods: { methods: {
// @ts-ignore // @ts-ignore
_change(e : RadioGroupChangeEvent) { _change(e : RadioGroupChangeEvent) {
const selected = this.items.find((item: ItemType) : boolean => { const selected = this.items.find((item : ItemType) : boolean => {
return item.name == e.detail.value return item.name == e.detail.value
}) })
if (selected != null) { if (selected != null) {
......
...@@ -82,7 +82,8 @@ ...@@ -82,7 +82,8 @@
</view> </view>
</view> </view>
<view class="input-wrapper"> <view class="input-wrapper">
<input class="uni-input" :type="inputType" :value="inputClearValue" :placeholder="title" @input="input" @blur="blur" @focus="focus" /> <input class="uni-input" :type="inputType" :value="inputClearValue" :placeholder="title" @input="input" @blur="blur"
@focus="focus" />
<image class="input-wrapper_image" src="/static/icons/clear.png" v-if="showClearIcon" @click="clearIcon"> <image class="input-wrapper_image" src="/static/icons/clear.png" v-if="showClearIcon" @click="clearIcon">
</image> </image>
</view> </view>
...@@ -95,7 +96,7 @@ ...@@ -95,7 +96,7 @@
flex-direction: row; flex-direction: row;
justify-content: center; justify-content: center;
padding: 0; padding: 0;
margin: 0 20rpx; margin: 0 10px;
flex-direction: row; flex-direction: row;
flex-wrap: nowrap; flex-wrap: nowrap;
background-color: #ffffff; background-color: #ffffff;
...@@ -105,6 +106,6 @@ ...@@ -105,6 +106,6 @@
width: 22px; width: 22px;
height: 22px; height: 22px;
align-self: center; align-self: center;
margin-right: 10rpx; margin-right: 5px;
} }
</style> </style>
<template> <template>
<view class="uni-collapse-item"> <view class="uni-collapse-item">
<view class="uni-collapse-item__title" @click="openCollapse(!is_open)"> <view class="uni-collapse-item__title" @click="openCollapse(!is_open)">
<text class="uni-collapse-item__title-text" :class="{'is-disabled':disabled,'open--active':is_open}">{{title}}</text> <text class="uni-collapse-item__title-text"
:class="{'is-disabled':disabled,'open--active':is_open}">{{title}}</text>
<view class="down_arrow" :class="{'down_arrow--active': is_open}"></view> <view class="down_arrow" :class="{'down_arrow--active': is_open}"></view>
</view> </view>
<view ref="boxRef" class="uni-collapse-item__content"> <view ref="boxRef" class="uni-collapse-item__content">
...@@ -40,7 +41,7 @@ ...@@ -40,7 +41,7 @@
}; };
}, },
watch: { watch: {
open(value: boolean) { open(value : boolean) {
// this.is_open = value // this.is_open = value
if (this.boxNode != null) { if (this.boxNode != null) {
this.openCollapse(value) this.openCollapse(value)
...@@ -57,14 +58,14 @@ ...@@ -57,14 +58,14 @@
}, },
methods: { methods: {
// 开启或关闭折叠面板 // 开启或关闭折叠面板
openCollapse(open: boolean) { openCollapse(open : boolean) {
if (this.disabled) return if (this.disabled) return
// 关闭其他已打开 // 关闭其他已打开
$dispatch(this, 'UniCollapse', 'cloceAll') $dispatch(this, 'UniCollapse', 'cloceAll')
this.is_open = open this.is_open = open
this.openOrClose(open) this.openOrClose(open)
}, },
openOrClose(open: boolean) { openOrClose(open : boolean) {
const boxNode = this.boxNode?.style!; const boxNode = this.boxNode?.style!;
const contentNode = this.contentNode?.style!; const contentNode = this.contentNode?.style!;
let hide = open ? 'flex' : 'none'; let hide = open ? 'flex' : 'none';
...@@ -84,6 +85,7 @@ ...@@ -84,6 +85,7 @@
.uni-collapse-item { .uni-collapse-item {
background-color: #fff; background-color: #fff;
} }
.uni-collapse-item__title { .uni-collapse-item__title {
flex-direction: row; flex-direction: row;
align-items: center; align-items: center;
...@@ -91,8 +93,6 @@ ...@@ -91,8 +93,6 @@
background-color: #fff; background-color: #fff;
} }
.down_arrow { .down_arrow {
width: 8px; width: 8px;
height: 8px; height: 8px;
...@@ -132,7 +132,7 @@ ...@@ -132,7 +132,7 @@
.uni-collapse-item__content-box { .uni-collapse-item__content-box {
width: 100%; width: 100%;
transition-property: transform , opacity; transition-property: transform, opacity;
transition-duration: 0.2s; transition-duration: 0.2s;
transform: translateY(-100%); transform: translateY(-100%);
opacity: 0; opacity: 0;
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
}, },
methods: { methods: {
init(child: ComponentPublicInstance) { init(child : ComponentPublicInstance) {
this.child_nodes.push(child) this.child_nodes.push(child)
}, },
// 关闭所有 // 关闭所有
......
...@@ -95,7 +95,6 @@ ...@@ -95,7 +95,6 @@
.uni-navbar-inner { .uni-navbar-inner {
position: relative; position: relative;
display: flex;
flex-direction: row; flex-direction: row;
justify-content: space-between; justify-content: space-between;
height: 45px; height: 45px;
...@@ -103,7 +102,6 @@ ...@@ -103,7 +102,6 @@
.left-content, .left-content,
.right-content { .right-content {
display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
width: 45px; width: 45px;
...@@ -117,7 +115,6 @@ ...@@ -117,7 +115,6 @@
bottom: 0; bottom: 0;
left: 45px; left: 45px;
right: 45px; right: 45px;
display: flex;
flex-direction: row; flex-direction: row;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
......
...@@ -65,7 +65,6 @@ ...@@ -65,7 +65,6 @@
.uni-navbar-inner { .uni-navbar-inner {
position: relative; position: relative;
display: flex;
flex-direction: row; flex-direction: row;
justify-content: space-between; justify-content: space-between;
height: 45px; height: 45px;
...@@ -73,7 +72,6 @@ ...@@ -73,7 +72,6 @@
.left-content, .left-content,
.right-content { .right-content {
display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
width: 45px; width: 45px;
...@@ -87,7 +85,6 @@ ...@@ -87,7 +85,6 @@
bottom: 0; bottom: 0;
left: 45px; left: 45px;
right: 45px; right: 45px;
display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册