From b4cb00ed97491d6bb927a397f2a35eb0d649c146 Mon Sep 17 00:00:00 2001 From: neverland Date: Mon, 21 Dec 2020 13:34:36 +0800 Subject: [PATCH 1/2] style(Cascader): fix style details (#7779) * style(Cascader): fix style details * style(Tabs): use less var --- src/cascader/README.md | 4 +-- src/cascader/README.zh-CN.md | 14 ++++---- src/cascader/demo/index.vue | 33 +++++++++++++++---- src/cascader/index.less | 10 ++++-- .../test/__snapshots__/demo.spec.js.snap | 9 ++--- src/tabs/index.less | 10 +++--- 6 files changed, 51 insertions(+), 29 deletions(-) diff --git a/src/cascader/README.md b/src/cascader/README.md index 7b2ffbd62..688b752a1 100644 --- a/src/cascader/README.md +++ b/src/cascader/README.md @@ -15,10 +15,10 @@ Vue.use(Cascader); ```html @@ -78,10 +78,10 @@ export default { ```html diff --git a/src/cascader/README.zh-CN.md b/src/cascader/README.zh-CN.md index 7627cce01..09e9f9832 100644 --- a/src/cascader/README.zh-CN.md +++ b/src/cascader/README.zh-CN.md @@ -21,17 +21,17 @@ Vue.use(Cascader); ```html @@ -77,7 +77,7 @@ export default { ```html - + - + - + option.text).join('/'); this[type] = { + ...this[type], show: false, value, result, diff --git a/src/cascader/index.less b/src/cascader/index.less index cc43b2750..27871e3c4 100644 --- a/src/cascader/index.less +++ b/src/cascader/index.less @@ -17,7 +17,7 @@ &__close-icon { color: @cascader-close-icon-color; - font-size: @cascader-close-icon-color; + font-size: @cascader-close-icon-size; &:active { color: @cascader-close-icon-active-color; @@ -32,7 +32,11 @@ &.van-tabs--line .van-tabs__wrap { height: @cascader-tabs-height; - padding: 0 6px; + } + + .van-tabs__nav--complete { + padding-right: 6px; + padding-left: 6px; } } @@ -42,6 +46,7 @@ &--unselected { color: @cascader-unselected-tab-color; + font-weight: normal; } } @@ -59,6 +64,7 @@ &--selected { color: @cascader-active-color; + font-weight: @font-weight-bold; } } diff --git a/src/cascader/test/__snapshots__/demo.spec.js.snap b/src/cascader/test/__snapshots__/demo.spec.js.snap index 8e4fb1c8d..26f02dc21 100644 --- a/src/cascader/test/__snapshots__/demo.spec.js.snap +++ b/src/cascader/test/__snapshots__/demo.spec.js.snap @@ -6,31 +6,28 @@ exports[`renders demo correctly 1`] = `
地区
-
+
-
地区
-
+
-
地区
-
+
-
`; diff --git a/src/tabs/index.less b/src/tabs/index.less index b4e1a54c0..00bf41dd4 100644 --- a/src/tabs/index.less +++ b/src/tabs/index.less @@ -66,11 +66,6 @@ &::-webkit-scrollbar { display: none; } - - &--complete { - padding-right: 8px; - padding-left: 8px; - } } } } @@ -87,6 +82,11 @@ padding-bottom: 15px; /* 15px padding to hide scrollbar in mobile safari */ } + &--complete { + padding-right: @padding-xs; + padding-left: @padding-xs; + } + &--card { box-sizing: border-box; height: @tabs-card-height; From cdd48318db79da253430b151e449406bfc83a961 Mon Sep 17 00:00:00 2001 From: neverland Date: Mon, 21 Dec 2020 16:28:32 +0800 Subject: [PATCH 2/2] fix(cli): failed to throw error (#7783) * fix(cli): failed to throw error * fix: stat --- packages/vant-cli/src/compiler/compile-package.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/vant-cli/src/compiler/compile-package.ts b/packages/vant-cli/src/compiler/compile-package.ts index 1da7d1915..4d8d19e38 100644 --- a/packages/vant-cli/src/compiler/compile-package.ts +++ b/packages/vant-cli/src/compiler/compile-package.ts @@ -7,7 +7,7 @@ export async function compilePackage(isMinify: boolean) { webpack(config, (err, stats) => { if (err || stats.hasErrors()) { - reject(); + reject(err || stats.toString()); } else { resolve(); }