WebApp【公共组件库】@前端(For Git Submodule)
4 files modified
57 ■■■■ changed files
forms/checkbox/CCheckBox.vue 11 ●●●●● patch | view | raw | blame | history
forms/checkbox/cCheckBox.scss 17 ●●●●● patch | view | raw | blame | history
layout/navCustomBar/CNavCustomBar.vue 17 ●●●●● patch | view | raw | blame | history
layout/navCustomBar/cNavCustomBar.scss 12 ●●●● patch | view | raw | blame | history
forms/checkbox/CCheckBox.vue
@@ -9,7 +9,7 @@
<template>
    <view
        class="c-check-box"
        :class="displayType==='dialog'?'c-check-box-dialog':''"
        :class="displayType==='dialog'?'c-check-box-dialog':'c-check-box-plane'"
    >
        <AtInput
            ref="input"
@@ -27,6 +27,10 @@
                v-if="displayType==='dialog'"
                class="at-icon at-icon-chevron-right"
            />
            <text
                class="empty-text"
                v-if="displayType==='plane' && options.length<=0"
            >{{emptyText}}</text>
        </AtInput>
        <AtCheckbox
            ref="check"
@@ -111,6 +115,11 @@
        },
        // 占位提示
        placeholder: String,
        // 空选项的提示
        emptyText: {
            type: String,
            default: '',
        },
    },
    data() {
        return {
forms/checkbox/cCheckBox.scss
@@ -99,4 +99,21 @@
            max-width: calc(100% - 80px);
        }
    }
}
.c-check-box-plane {
    .at-input {
        padding: 24px 0;
        .at-input__children {
            padding-right: 20px;
            &::after {
                display: none;
            }
            .empty-text {
                color: #ccc;
                font-size: 34px;
            }
        }
    }
}
layout/navCustomBar/CNavCustomBar.vue
@@ -21,7 +21,7 @@
            <view
                v-if="isNeedBackIcon"
                class="c-nav-back-icon"
                @tap="evt => onBack()"
                @tap="evt => handleBack()"
            >
                <AtIcon
                    value='chevron-left'
@@ -30,7 +30,7 @@
                ></AtIcon>
            </view>
        </view>
        <view class="c-nav-title">
        <view :class="[isNeedBackIcon ? 'c-nav-title-back' : 'c-nav-title']">
            {{ title }}
        </view>
    </view>
@@ -54,6 +54,10 @@
        title: {
            type: String,
            default: '',
        },
        onBack: {
            type: Function,
            default: () => {},
        },
    },
    computed: {},
@@ -85,10 +89,11 @@
            this.statusBarHeight = statusBarHeight;
        },
        onBack() {
            Taro.navigateBack({
                delta: 1,
            });
        handleBack() {
            this.onBack();
            // Taro.navigateBack({
            //     delta: 1,
            // });
        },
        $getStatusBarHeight() {
layout/navCustomBar/cNavCustomBar.scss
@@ -23,7 +23,7 @@
            align-items: center;
            width: 100%;
            height: 100%;
            padding-left: 20px;
            padding-left: 16px;
            box-sizing: border-box;
        }
        .c-nav-back-icon {
@@ -31,10 +31,18 @@
            align-items: center;
            width: 100%;
            height: 100%;
            padding-left: 20px;
            padding-left: 4px;
            box-sizing: border-box;
        }
    }
    .c-nav-title-back {
        font-size: 34px;
        color: #000;
        font-weight: 500;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .c-nav-title {
        display: flex;
        align-items: center;