Skip to content

Commit f25fc9a

Browse files
committed
Merge branch 'weapp' of https://github.com/didi/mand-mobile into weapp
2 parents f1eb365 + 3741183 commit f25fc9a

74 files changed

Lines changed: 1519 additions & 1443 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

build/rollup/build-component.rollup.js

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ function compileVueStylus (content, cb, compiler, filePath) {
4242
throw err
4343
}
4444
postcss([autoprefixer])
45-
.process(css)
45+
.process(css, {
46+
from: undefined
47+
})
4648
.then(result => {
4749
cb(null, result.css)
4850
})
@@ -75,20 +77,22 @@ function computedCompilerConfig(filePath) {
7577

7678
function move(destDir) {
7779
return new Promise((resolve, reject) => {
78-
copy(SRC_BASE, destDir, {filter: function(item) {
79-
if (/demo|test/.test(item)) {
80-
return false
81-
}
82-
if (/^index.js$/.test(item)) {
83-
return false
84-
}
85-
return true
86-
}}, function (err, result) {
87-
if (err) {
88-
reject(err)
89-
}
90-
resolve(result)
91-
})
80+
copy(SRC_BASE, destDir, {
81+
overwrite: true,
82+
filter: function(item) {
83+
if (/demo|test/.test(item)) {
84+
return false
85+
}
86+
if (/^index.js$/.test(item)) {
87+
return false
88+
}
89+
return true
90+
}}, function (err, result) {
91+
if (err) {
92+
reject(err)
93+
}
94+
resolve(result)
95+
})
9296
})
9397
}
9498

build/rollup/rollup-plugin-example-config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ function vueWarpper() {
3737
use: [stylusMixin],
3838
},
3939
postcss: [
40-
px2rem({ rootValue: 100, propWhiteList: [] })
40+
px2rem({ rootValue: 100, minPixelValue: 2, propWhiteList: [] })
4141
]
4242
})
4343
}

build/webpack/webpack.dev.conf.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ const pkg = require('../../package.json')
1313
// Object.keys(baseWebpackConfig.entry).forEach(function (name) {
1414
// baseWebpackConfig.entry[name] = ['./build/dev-client'].concat(baseWebpackConfig.entry[name])
1515
// })
16-
const pxtoremConfig = pxtorem({ rootValue: 100, propWhiteList: [] })
16+
const pxtoremConfig = pxtorem({ rootValue: 100, propWhiteList: [], minPixelValue: 2 })
1717
const argv = require('yargs').argv
1818

1919
let entry = {

build/webpack/webpack.example.conf.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,7 @@ const webpackConfig = merge(baseWebpackConfig, {
107107
use: [poststylus([
108108
pxtorem({
109109
rootValue: 100,
110+
minPixelValue: 2,
110111
propWhiteList: [],
111112
})
112113
])]

components/_style/mixin/theme.components.styl

Lines changed: 19 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ button-small-font-size = font-body-large
6767
button-radius = radius-normal
6868

6969
// captcha
70-
captcha-zindex = 1400
70+
captcha-zindex = 1301
7171
captcha-title-color = color-text-base
7272
captcha-title-font-size = font-heading-normal
7373
captcha-color = color-text-caption
@@ -162,35 +162,24 @@ drop-menu-disabled-opacity = opacity-disabled
162162
field-padding-h = h-gap-sl
163163
field-padding-v = v-gap-sl
164164
field-bg-color = color-bg-inverse
165+
field-header-gap = v-gap-lg
166+
field-footer-gap = v-gap-md
165167
field-title-color = color-text-base
166168
field-title-font-size = font-caption-large
167169
field-title-font-weight = font-weight-normal
168-
field-title-operator-color = color-text-minor
169-
field-title-operator-font-size = font-body-large
170-
field-title-margin = 36px
171-
field-item-padding-v = v-gap-lg
172-
field-item-bg-tap-color = color-bg-tap
173-
field-item-label-color = color-text-base
174-
field-item-label-font-size = font-caption-normal
175-
field-item-label-font-weight = font-weight-normal
176-
field-item-content-color = color-text-base
177-
field-item-content-font-size = font-caption-normal
178-
field-item-content-font-weight = font-weight-medium
179-
field-item-icon-color = #ccc
170+
field-describe-color = color-text-caption
171+
field-describe-font-size = font-body-large
172+
field-action-color = color-text-minor
173+
field-action-font-size = font-body-large
174+
175+
// field-item
176+
field-item-min-height = 108px
177+
field-item-padding-v = 30px
178+
field-item-color = color-text-base
179+
field-item-font-size = font-caption-normal
180+
field-item-after-color = color-text-caption
181+
field-item-after-font-size = font-body-large
180182
field-item-border-color = color-border-base
181-
field-item-color-disabled = opacity-disabled
182-
field-item-brief-font-size = font-body-normal
183-
field-item-brief-color = color-text-caption
184-
field-title-plain-color = color-text-body
185-
field-title-plain-font-size = font-body-large
186-
field-padding-plain-h = h-gap-lg
187-
field-padding-plain-v = v-gap-lg
188-
field-bg-plain-color = color-bg-base
189-
field-item-padding-plain-v = h-gap-md
190-
field-item-label-plain-color = color-text-caption
191-
field-item-label-plain-font-size = font-body-large
192-
field-item-content-plain-color = color-text-body
193-
field-item-content-plain-font-size = font-body-large
194183

195184
// icon
196185
icon-size-xs = 20px
@@ -205,6 +194,7 @@ image-viewer-index-bottom = 100px
205194

206195
// input-item
207196
input-item-height = 100px
197+
input-item-border-color = color-border-base
208198
input-item-title-width = 170px
209199
input-item-title-gap = 22px
210200
input-item-font-size = font-caption-normal
@@ -346,13 +336,14 @@ tag-small-font-size = font-minor-normal
346336
tag-tiny-font-size = 12px
347337

348338
// tip
349-
tip-fill = rgba(65, 72, 93, .77)
339+
tip-fill = #41485D
340+
tip-fill-opacity = .77
350341
tip-font-size = font-minor-large
351342
tip-color = color-text-base-inverse
352343
tip-radius = 1000px
353344
tip-padding = 15px 32px
354345
tip-close-size = 32px
355-
tip-zindex = 1300
346+
tip-zindex = 1303
356347
tip-shadow = 0 5px 20px #C5CAD5
357348

358349
// toast

components/_style/mixin/theme.variable.styl

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -105,23 +105,27 @@ tag-small-font-size = var(--tag-small-font-size)
105105
tag-tiny-font-size = var(--tag-tiny-font-size)
106106

107107
// field
108-
field-padding = var(--field-padding)
109108
field-padding-h = var(--field-padding-h)
110109
field-padding-v = var(--field-padding-v)
111-
field-title-font-size = var(--field-title-font-size)
110+
field-bg-color = var(--field-bg-color)
111+
field-header-gap = var(--field-header-gap)
112+
field-footer-gap = var(--field-footer-gap)
112113
field-title-color = var(--field-title-color)
114+
field-title-font-size = var(--field-title-font-size)
113115
field-title-font-weight = var(--field-title-font-weight)
114-
field-title-margin = var(--field-title-margin)
116+
field-describe-color = var(--field-describe-color)
117+
field-describe-font-size = var(--field-describe-font-size)
118+
field-action-color = var(--field-action-color)
119+
field-action-font-size = var(--field-action-font-size)
120+
121+
// field-item
122+
field-item-min-height = var(--field-item-min-height)
115123
field-item-padding-v = var(--field-item-padding-v)
116-
field-item-bg-color = var(--field-item-bg-color)
117-
field-item-bg-tap-color = var(--field-item-bg-tap-color)
118124
field-item-color = var(--field-item-color)
119125
field-item-font-size = var(--field-item-font-size)
120-
field-item-icon-color = var(--field-item-icon-color)
126+
field-item-after-color = var(--field-item-after-color)
127+
field-item-after-font-size = var(--field-item-after-font-size)
121128
field-item-border-color = var(--field-item-border-color)
122-
field-item-color-disabled = var(--field-item-color-disabled)
123-
field-item-brief-font-size = var(--field-item-brief-font-size)
124-
field-item-brief-color = var(--field-item-brief-color)
125129

126130
// input-item
127131
input-item-height = var(--input-item-height)

components/action-bar/index.vue

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
<div class="md-action-bar-text" v-if="hasSlots">
44
<slot></slot>
55
</div>
6-
<div class="md-action-bar-button">
6+
<div class="md-action-bar-group">
77
<template v-for="(item, index) in coerceActions">
88
<md-button
9-
class="button-item"
9+
class="md-action-bar-button"
1010
:type="!!item.disabled ? 'disabled' : 'primary'"
1111
:plain="index !== coerceActions.length - 1"
1212
:key="index"
@@ -79,16 +79,17 @@ export default {
7979
align-items center
8080
overflow hidden
8181
82-
.md-action-bar-button
82+
.md-action-bar-group
8383
display flex
8484
flex 1
8585
height 100%
86-
.button-item
87-
display flex
88-
float right
89-
align-items center
90-
justify-content center
91-
flex 1
92-
&:nth-of-type(2)
93-
margin-left action-bar-button-gap
86+
87+
.md-action-bar-button
88+
display flex
89+
float right
90+
align-items center
91+
justify-content center
92+
flex 1
93+
&:nth-of-type(2)
94+
margin-left action-bar-button-gap
9495
</style>

components/action-sheet/action-sheet.vue

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
v-html="item.text || item.label"
2424
></li>
2525
</template>
26-
<li class="cancel-btn" @click="$_onCancel">{{ cancelText }}</li>
26+
<li class="md-action-sheet-cancel" @click="$_onCancel">{{ cancelText }}</li>
2727
</ul>
2828
</div>
2929
</md-popup>
@@ -156,14 +156,15 @@ export default {
156156
color action-sheet-color-highlight
157157
&.disabled
158158
opacity action-sheet-disabled-opacity
159-
&.cancel-btn
160-
height 132px
161-
line-height 120px
162-
color action-sheet-color-cancel
163-
font-weight font-weight-medium
164-
&::before
165-
display block
166-
content ''
167-
height 12px
168-
background action-sheet-cancel-gap-bg
159+
160+
.md-action-sheet-cancel
161+
height 132px
162+
line-height 120px
163+
color action-sheet-color-cancel
164+
font-weight font-weight-medium
165+
&::before
166+
display block
167+
content ''
168+
height 12px
169+
background action-sheet-cancel-gap-bg
169170
</style>

components/agree/index.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
value ? 'checked' : ''
1111
]"
1212
@click="$_onChange($event)">
13-
<div class="md-agree-checked-wrap">
13+
<div class="md-agree-checked">
1414
<md-icon
1515
name="circle-right"
1616
:size="size">
@@ -81,11 +81,11 @@ export default {
8181
color agree-fill-inverse
8282
&.checked
8383
color agree-fill
84-
.md-agree-checked-wrap
84+
.md-agree-checked
8585
svg
8686
transform scale(1)
8787
88-
.md-agree-checked-wrap
88+
.md-agree-checked
8989
position absolute
9090
top 0
9191
left 0

components/bill/index.vue

Lines changed: 15 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,23 +3,21 @@
33
class="md-bill"
44
:content="waterMark"
55
>
6-
<div>
7-
<md-field
8-
:title="name"
9-
:value="no ? `NO.${no}` : ''"
10-
plain
11-
>
12-
<div class="bill-radius">
13-
<i></i><i></i>
14-
</div>
15-
<div class="bill-detail">
16-
<slot></slot>
17-
</div>
18-
<div class="bill-description">
19-
<slot name="description"></slot>
20-
</div>
21-
</md-field>
22-
</div>
6+
<md-field
7+
:title="name"
8+
:value="no ? `NO.${no}` : ''"
9+
plain
10+
>
11+
<div class="bill-radius">
12+
<i></i><i></i>
13+
</div>
14+
<div class="bill-detail">
15+
<slot></slot>
16+
</div>
17+
<div class="bill-description">
18+
<slot name="description"></slot>
19+
</div>
20+
</md-field>
2321
<div slot="watermark" slot-scope="props" v-if="!!$scopedSlots.watermark">
2422
<slot name="watermark" @index="1"></slot>
2523
</div>

0 commit comments

Comments
 (0)