Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit0cf2502

Browse files
simplesmileryyx990803
authored andcommitted
Test non-prefixed attributes before prefixed (vuejs#2668)
1 parentf28260a commit0cf2502

File tree

2 files changed

+12
-6
lines changed

2 files changed

+12
-6
lines changed

‎src/directives/internal/style.js‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,12 @@ function prefix (prop) {
112112
}
113113
vari=prefixes.length
114114
varprefixed
115+
if(camel!=='filter'&&(camelintestEl.style)){
116+
return{
117+
kebab:prop,
118+
camel:camel
119+
}
120+
}
115121
while(i--){
116122
prefixed=camelPrefixes[i]+upper
117123
if(prefixedintestEl.style){
@@ -121,10 +127,4 @@ function prefix (prop) {
121127
}
122128
}
123129
}
124-
if(camelintestEl.style){
125-
return{
126-
kebab:prop,
127-
camel:camel
128-
}
129-
}
130130
}

‎test/unit/specs/directives/internal/style_spec.js‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,4 +121,10 @@ describe(':style', function () {
121121
done()
122122
})
123123
})
124+
125+
// #2654
126+
it('background size with only one value',function(){
127+
dir.update({backgroundSize:'100%'})
128+
expect(el.style.cssText.replace(/\s/g,'')).toBe('background-size:100%;')
129+
})
124130
})

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp