[JIT] Support animation lists (#5252)
* Support animation lists * Update tests
This commit is contained in:
parent
ca1a167a83
commit
b56b4c0b14
6 changed files with 248 additions and 80 deletions
|
|
@ -20,9 +20,10 @@ const DIGIT = /^(\d+)$/
|
|||
|
||||
export default function parseAnimationValue(input) {
|
||||
let animations = input.split(COMMA)
|
||||
let result = animations.map((animation) => {
|
||||
let result = {}
|
||||
let parts = animation.trim().split(SPACE)
|
||||
return animations.map((animation) => {
|
||||
let value = animation.trim()
|
||||
let result = { value }
|
||||
let parts = value.split(SPACE)
|
||||
let seen = new Set()
|
||||
|
||||
for (let part of parts) {
|
||||
|
|
@ -58,6 +59,4 @@ export default function parseAnimationValue(input) {
|
|||
|
||||
return result
|
||||
})
|
||||
|
||||
return animations.length > 1 ? result : result[0]
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue