swc/crates/swc_css_parser/tests/fixture/at-rule/keyframe/output.json

1312 lines
33 KiB
JSON
Raw Normal View History

{
"type": "Stylesheet",
"span": {
"start": 0,
"end": 784,
"ctxt": 0
},
"rules": [
{
"type": "KeyframesRule",
"span": {
"start": 0,
"end": 28,
"ctxt": 0
},
"name": {
"type": "CustomIdentifier",
"span": {
"start": 11,
"end": 14,
"ctxt": 0
},
"value": "foo",
"raw": "foo"
},
"blocks": []
},
{
"type": "KeyframesRule",
"span": {
"start": 29,
"end": 59,
"ctxt": 0
},
"name": {
"type": "String",
"span": {
"start": 40,
"end": 45,
"ctxt": 0
},
"value": "foo",
"raw": "\"foo\""
},
"blocks": []
},
{
"type": "KeyframesRule",
"span": {
"start": 60,
"end": 94,
"ctxt": 0
},
"name": {
"type": "CustomIdentifier",
"span": {
"start": 74,
"end": 77,
"ctxt": 0
},
"value": "foo",
"raw": "foo"
},
"blocks": []
},
{
"type": "KeyframesRule",
"span": {
"start": 96,
"end": 223,
"ctxt": 0
},
"name": {
"type": "CustomIdentifier",
"span": {
"start": 107,
"end": 114,
"ctxt": 0
},
"value": "slidein",
"raw": "slidein"
},
"blocks": [
{
"span": {
"start": 121,
"end": 168,
"ctxt": 0
},
"prelude": [
{
"type": "Identifier",
"span": {
"start": 121,
"end": 125,
"ctxt": 0
},
"value": "from",
"raw": "from"
}
],
"block": {
"type": "Block",
"span": {
"start": 126,
"end": 168,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 136,
"end": 161,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 136,
"end": 145,
"ctxt": 0
},
"value": "transform",
"raw": "transform"
},
"value": [
{
"type": "Function",
"span": {
"start": 147,
"end": 161,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 147,
"end": 157,
"ctxt": 0
},
"value": "translateX",
"raw": "translateX"
},
"value": [
{
"type": "Percent",
"span": {
"start": 158,
"end": 160,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 158,
"end": 159,
"ctxt": 0
},
"value": 0.0,
"raw": "0"
}
}
]
}
],
"important": null
}
]
}
},
{
"span": {
"start": 174,
"end": 221,
"ctxt": 0
},
"prelude": [
{
"type": "Identifier",
"span": {
"start": 174,
"end": 176,
"ctxt": 0
},
"value": "to",
"raw": "to"
}
],
"block": {
"type": "Block",
"span": {
"start": 177,
"end": 221,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 187,
"end": 214,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 187,
"end": 196,
"ctxt": 0
},
"value": "transform",
"raw": "transform"
},
"value": [
{
"type": "Function",
"span": {
"start": 198,
"end": 214,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 198,
"end": 208,
"ctxt": 0
},
"value": "translateX",
"raw": "translateX"
},
"value": [
{
"type": "Percent",
"span": {
"start": 209,
"end": 213,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 209,
"end": 212,
"ctxt": 0
},
"value": 100.0,
"raw": "100"
}
}
]
}
],
"important": null
}
]
}
}
]
},
{
"type": "KeyframesRule",
"span": {
"start": 225,
"end": 367,
"ctxt": 0
},
"name": {
"type": "CustomIdentifier",
"span": {
"start": 236,
"end": 246,
"ctxt": 0
},
"value": "identifier",
"raw": "identifier"
},
"blocks": [
{
"span": {
"start": 253,
"end": 276,
"ctxt": 0
},
"prelude": [
{
"type": "Percent",
"span": {
"start": 253,
"end": 255,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 253,
"end": 254,
"ctxt": 0
},
"value": 0.0,
"raw": "0"
}
}
],
"block": {
"type": "Block",
"span": {
"start": 256,
"end": 276,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 258,
"end": 264,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 258,
"end": 261,
"ctxt": 0
},
"value": "top",
"raw": "top"
},
"value": [
{
"type": "Number",
"span": {
"start": 263,
"end": 264,
"ctxt": 0
},
"value": 0.0,
"raw": "0"
}
],
"important": null
},
{
"type": "Declaration",
"span": {
"start": 266,
"end": 273,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 266,
"end": 270,
"ctxt": 0
},
"value": "left",
"raw": "left"
},
"value": [
{
"type": "Number",
"span": {
"start": 272,
"end": 273,
"ctxt": 0
},
"value": 0.0,
"raw": "0"
}
],
"important": null
}
]
}
},
{
"span": {
"start": 281,
"end": 299,
"ctxt": 0
},
"prelude": [
{
"type": "Percent",
"span": {
"start": 281,
"end": 284,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 281,
"end": 283,
"ctxt": 0
},
"value": 30.0,
"raw": "30"
}
}
],
"block": {
"type": "Block",
"span": {
"start": 285,
"end": 299,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 287,
"end": 296,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 287,
"end": 290,
"ctxt": 0
},
"value": "top",
"raw": "top"
},
"value": [
{
"type": "Dimension",
"span": {
"start": 292,
"end": 296,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 292,
"end": 294,
"ctxt": 0
},
"value": 50.0,
"raw": "50"
},
"unit": {
"type": "Identifier",
"span": {
"start": 294,
"end": 296,
"ctxt": 0
},
"value": "px",
"raw": "px"
}
}
],
"important": null
}
]
}
},
{
"span": {
"start": 304,
"end": 328,
"ctxt": 0
},
"prelude": [
{
"type": "Percent",
"span": {
"start": 304,
"end": 307,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 304,
"end": 306,
"ctxt": 0
},
"value": 68.0,
"raw": "68"
}
},
{
"type": "Percent",
"span": {
"start": 309,
"end": 312,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 309,
"end": 311,
"ctxt": 0
},
"value": 72.0,
"raw": "72"
}
}
],
"block": {
"type": "Block",
"span": {
"start": 313,
"end": 328,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 315,
"end": 325,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 315,
"end": 319,
"ctxt": 0
},
"value": "left",
"raw": "left"
},
"value": [
{
"type": "Dimension",
"span": {
"start": 321,
"end": 325,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 321,
"end": 323,
"ctxt": 0
},
"value": 50.0,
"raw": "50"
},
"unit": {
"type": "Identifier",
"span": {
"start": 323,
"end": 325,
"ctxt": 0
},
"value": "px",
"raw": "px"
}
}
],
"important": null
}
]
}
},
{
"span": {
"start": 333,
"end": 365,
"ctxt": 0
},
"prelude": [
{
"type": "Percent",
"span": {
"start": 333,
"end": 337,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 333,
"end": 336,
"ctxt": 0
},
"value": 100.0,
"raw": "100"
}
}
],
"block": {
"type": "Block",
"span": {
"start": 338,
"end": 365,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 340,
"end": 350,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 340,
"end": 343,
"ctxt": 0
},
"value": "top",
"raw": "top"
},
"value": [
{
"type": "Dimension",
"span": {
"start": 345,
"end": 350,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 345,
"end": 348,
"ctxt": 0
},
"value": 100.0,
"raw": "100"
},
"unit": {
"type": "Identifier",
"span": {
"start": 348,
"end": 350,
"ctxt": 0
},
"value": "px",
"raw": "px"
}
}
],
"important": null
},
{
"type": "Declaration",
"span": {
"start": 352,
"end": 362,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 352,
"end": 356,
"ctxt": 0
},
"value": "left",
"raw": "left"
},
"value": [
{
"type": "Percent",
"span": {
"start": 358,
"end": 362,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 358,
"end": 361,
"ctxt": 0
},
"value": 100.0,
"raw": "100"
}
}
],
"important": null
}
]
}
}
]
},
{
"type": "KeyframesRule",
"span": {
"start": 369,
"end": 386,
"ctxt": 0
},
"name": {
"type": "CustomIdentifier",
"span": {
"start": 380,
"end": 383,
"ctxt": 0
},
"value": "FOO",
"raw": "FOO"
},
"blocks": []
},
{
"type": "KeyframesRule",
"span": {
"start": 387,
"end": 410,
"ctxt": 0
},
"name": {
"type": "String",
"span": {
"start": 398,
"end": 407,
"ctxt": 0
},
"value": "initial",
"raw": "\"initial\""
},
"blocks": []
},
{
"type": "KeyframesRule",
"span": {
"start": 411,
"end": 431,
"ctxt": 0
},
"name": {
"type": "String",
"span": {
"start": 422,
"end": 428,
"ctxt": 0
},
"value": "None",
"raw": "\"None\""
},
"blocks": []
},
{
"type": "KeyframesRule",
"span": {
"start": 432,
"end": 651,
"ctxt": 0
},
"name": {
"type": "CustomIdentifier",
"span": {
"start": 443,
"end": 454,
"ctxt": 0
},
"value": "slide-right",
"raw": "slide-right"
},
"blocks": [
{
"span": {
"start": 462,
"end": 500,
"ctxt": 0
},
"prelude": [
{
"type": "Identifier",
"span": {
"start": 462,
"end": 466,
"ctxt": 0
},
"value": "from",
"raw": "from"
}
],
"block": {
"type": "Block",
"span": {
"start": 467,
"end": 500,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 477,
"end": 493,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 477,
"end": 488,
"ctxt": 0
},
"value": "margin-left",
"raw": "margin-left"
},
"value": [
{
"type": "Dimension",
"span": {
"start": 490,
"end": 493,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 490,
"end": 491,
"ctxt": 0
},
"value": 0.0,
"raw": "0"
},
"unit": {
"type": "Identifier",
"span": {
"start": 491,
"end": 493,
"ctxt": 0
},
"value": "px",
"raw": "px"
}
}
],
"important": null
}
]
}
},
{
"span": {
"start": 506,
"end": 565,
"ctxt": 0
},
"prelude": [
{
"type": "Percent",
"span": {
"start": 506,
"end": 509,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 506,
"end": 508,
"ctxt": 0
},
"value": 50.0,
"raw": "50"
}
}
],
"block": {
"type": "Block",
"span": {
"start": 510,
"end": 565,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 520,
"end": 538,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 520,
"end": 531,
"ctxt": 0
},
"value": "margin-left",
"raw": "margin-left"
},
"value": [
{
"type": "Dimension",
"span": {
"start": 533,
"end": 538,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 533,
"end": 536,
"ctxt": 0
},
"value": 110.0,
"raw": "110"
},
"unit": {
"type": "Identifier",
"span": {
"start": 536,
"end": 538,
"ctxt": 0
},
"value": "px",
"raw": "px"
}
}
],
"important": null
},
{
"type": "Declaration",
"span": {
"start": 548,
"end": 558,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 548,
"end": 555,
"ctxt": 0
},
"value": "opacity",
"raw": "opacity"
},
"value": [
{
"type": "Number",
"span": {
"start": 557,
"end": 558,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
}
],
"important": null
}
]
}
},
{
"span": {
"start": 571,
"end": 604,
"ctxt": 0
},
"prelude": [
{
"type": "Percent",
"span": {
"start": 571,
"end": 574,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 571,
"end": 573,
"ctxt": 0
},
"value": 50.0,
"raw": "50"
}
}
],
"block": {
"type": "Block",
"span": {
"start": 575,
"end": 604,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 585,
"end": 597,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 585,
"end": 592,
"ctxt": 0
},
"value": "opacity",
"raw": "opacity"
},
"value": [
{
"type": "Number",
"span": {
"start": 594,
"end": 597,
"ctxt": 0
},
"value": 0.9,
"raw": "0.9"
}
],
"important": null
}
]
}
},
{
"span": {
"start": 610,
"end": 648,
"ctxt": 0
},
"prelude": [
{
"type": "Identifier",
"span": {
"start": 610,
"end": 612,
"ctxt": 0
},
"value": "to",
"raw": "to"
}
],
"block": {
"type": "Block",
"span": {
"start": 613,
"end": 648,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 623,
"end": 641,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 623,
"end": 634,
"ctxt": 0
},
"value": "margin-left",
"raw": "margin-left"
},
"value": [
{
"type": "Dimension",
"span": {
"start": 636,
"end": 641,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 636,
"end": 639,
"ctxt": 0
},
"value": 200.0,
"raw": "200"
},
"unit": {
"type": "Identifier",
"span": {
"start": 639,
"end": 641,
"ctxt": 0
},
"value": "px",
"raw": "px"
}
}
],
"important": null
}
]
}
}
]
},
{
"type": "KeyframesRule",
"span": {
"start": 653,
"end": 783,
"ctxt": 0
},
"name": {
"type": "CustomIdentifier",
"span": {
"start": 664,
"end": 674,
"ctxt": 0
},
"value": "slidein-up",
"raw": "slidein-up"
},
"blocks": [
{
"span": {
"start": 681,
"end": 728,
"ctxt": 0
},
"prelude": [
{
"type": "Identifier",
"span": {
"start": 681,
"end": 685,
"ctxt": 0
},
"value": "fRoM",
"raw": "fRoM"
}
],
"block": {
"type": "Block",
"span": {
"start": 686,
"end": 728,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 696,
"end": 721,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 696,
"end": 705,
"ctxt": 0
},
"value": "transform",
"raw": "transform"
},
"value": [
{
"type": "Function",
"span": {
"start": 707,
"end": 721,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 707,
"end": 717,
"ctxt": 0
},
"value": "translateX",
"raw": "translateX"
},
"value": [
{
"type": "Percent",
"span": {
"start": 718,
"end": 720,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 718,
"end": 719,
"ctxt": 0
},
"value": 0.0,
"raw": "0"
}
}
]
}
],
"important": null
}
]
}
},
{
"span": {
"start": 734,
"end": 781,
"ctxt": 0
},
"prelude": [
{
"type": "Identifier",
"span": {
"start": 734,
"end": 736,
"ctxt": 0
},
"value": "tO",
"raw": "tO"
}
],
"block": {
"type": "Block",
"span": {
"start": 737,
"end": 781,
"ctxt": 0
},
"value": [
{
"type": "Declaration",
"span": {
"start": 747,
"end": 774,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 747,
"end": 756,
"ctxt": 0
},
"value": "transform",
"raw": "transform"
},
"value": [
{
"type": "Function",
"span": {
"start": 758,
"end": 774,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 758,
"end": 768,
"ctxt": 0
},
"value": "translateX",
"raw": "translateX"
},
"value": [
{
"type": "Percent",
"span": {
"start": 769,
"end": 773,
"ctxt": 0
},
"value": {
"type": "Number",
"span": {
"start": 769,
"end": 772,
"ctxt": 0
},
"value": 100.0,
"raw": "100"
}
}
]
}
],
"important": null
}
]
}
}
]
}
]
}