UNPKG

rizzo-next

Version:

The next generation of Lonely Planet's style guide and pattern library.

1,272 lines (1,271 loc) 128 kB
{ "type": "Program", "start": 0, "end": 1061, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 50, "column": 0 } }, "sourceType": "module", "body": [ { "type": "ImportDeclaration", "start": 0, "end": 63, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 63 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 7, "end": 11, "loc": { "start": { "line": 1, "column": 7 }, "end": { "line": 1, "column": 11 } }, "local": { "type": "Identifier", "start": 7, "end": 11, "loc": { "start": { "line": 1, "column": 7 }, "end": { "line": 1, "column": 11 } }, "name": "Tabs" } } ], "importKind": "value", "source": { "type": "Literal", "start": 17, "end": 62, "loc": { "start": { "line": 1, "column": 17 }, "end": { "line": 1, "column": 62 } }, "value": "../../../src/components/tabs/tabs_component", "rawValue": "../../../src/components/tabs/tabs_component", "raw": "\"../../../src/components/tabs/tabs_component\"" } }, { "type": "ImportDeclaration", "start": 64, "end": 87, "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 23 } }, "specifiers": [ { "type": "ImportDefaultSpecifier", "start": 71, "end": 72, "loc": { "start": { "line": 2, "column": 7 }, "end": { "line": 2, "column": 8 } }, "local": { "type": "Identifier", "start": 71, "end": 72, "loc": { "start": { "line": 2, "column": 7 }, "end": { "line": 2, "column": 8 } }, "name": "$" } } ], "importKind": "value", "source": { "type": "Literal", "start": 78, "end": 86, "loc": { "start": { "line": 2, "column": 14 }, "end": { "line": 2, "column": 22 } }, "value": "jquery", "rawValue": "jquery", "raw": "\"jquery\"" } }, { "type": "VariableDeclaration", "start": 89, "end": 123, "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 34 } }, "declarations": [ { "type": "VariableDeclarator", "start": 93, "end": 122, "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 33 } }, "id": { "type": "Identifier", "start": 93, "end": 99, "loc": { "start": { "line": 4, "column": 4 }, "end": { "line": 4, "column": 10 } }, "name": "expect" }, "init": { "type": "CallExpression", "start": 102, "end": 122, "loc": { "start": { "line": 4, "column": 13 }, "end": { "line": 4, "column": 33 } }, "callee": { "type": "Identifier", "start": 102, "end": 109, "loc": { "start": { "line": 4, "column": 13 }, "end": { "line": 4, "column": 20 } }, "name": "require" }, "arguments": [ { "type": "Literal", "start": 110, "end": 121, "loc": { "start": { "line": 4, "column": 21 }, "end": { "line": 4, "column": 32 } }, "value": "expect.js", "rawValue": "expect.js", "raw": "\"expect.js\"" } ] } } ], "kind": "let" }, { "type": "VariableDeclaration", "start": 125, "end": 416, "loc": { "start": { "line": 6, "column": 0 }, "end": { "line": 19, "column": 2 } }, "declarations": [ { "type": "VariableDeclarator", "start": 129, "end": 415, "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 19, "column": 1 } }, "id": { "type": "Identifier", "start": 129, "end": 136, "loc": { "start": { "line": 6, "column": 4 }, "end": { "line": 6, "column": 11 } }, "name": "fixture" }, "init": { "type": "TemplateLiteral", "start": 139, "end": 415, "loc": { "start": { "line": 6, "column": 14 }, "end": { "line": 19, "column": 1 } }, "expressions": [], "quasis": [ { "type": "TemplateElement", "start": 140, "end": 414, "loc": { "start": { "line": 6, "column": 15 }, "end": { "line": 19, "column": 0 } }, "value": { "raw": "\n<div class=\"tabs\">\n <ul class=\"tabs__links\">\n <li><a href=\"#tab1\">Tab 1</a></li>\n <li><a href=\"#tab2\">Tab 2</a></li>\n </ul>\n <div class=\"tabs__content\" id=\"tab1\">\n Tab 1 Content\n </div>\n <div class=\"tabs__content\" id=\"tab2\">\n Tab 2 Content\n </div>\n</div>\n", "cooked": "\n<div class=\"tabs\">\n <ul class=\"tabs__links\">\n <li><a href=\"#tab1\">Tab 1</a></li>\n <li><a href=\"#tab2\">Tab 2</a></li>\n </ul>\n <div class=\"tabs__content\" id=\"tab1\">\n Tab 1 Content\n </div>\n <div class=\"tabs__content\" id=\"tab2\">\n Tab 2 Content\n </div>\n</div>\n" }, "tail": true } ] } } ], "kind": "let" }, { "type": "ExpressionStatement", "start": 419, "end": 1060, "loc": { "start": { "line": 22, "column": 0 }, "end": { "line": 49, "column": 3 } }, "expression": { "type": "CallExpression", "start": 419, "end": 1059, "loc": { "start": { "line": 22, "column": 0 }, "end": { "line": 49, "column": 2 } }, "callee": { "type": "Identifier", "start": 419, "end": 427, "loc": { "start": { "line": 22, "column": 0 }, "end": { "line": 22, "column": 8 } }, "name": "describe" }, "arguments": [ { "type": "Literal", "start": 428, "end": 444, "loc": { "start": { "line": 22, "column": 9 }, "end": { "line": 22, "column": 25 } }, "value": "tabs component", "rawValue": "tabs component", "raw": "\"tabs component\"" }, { "type": "ArrowFunctionExpression", "start": 446, "end": 1058, "loc": { "start": { "line": 22, "column": 27 }, "end": { "line": 49, "column": 1 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [], "body": { "type": "BlockStatement", "start": 452, "end": 1058, "loc": { "start": { "line": 22, "column": 33 }, "end": { "line": 49, "column": 1 } }, "body": [ { "type": "ExpressionStatement", "start": 456, "end": 530, "loc": { "start": { "line": 23, "column": 2 }, "end": { "line": 25, "column": 5 } }, "expression": { "type": "CallExpression", "start": 456, "end": 529, "loc": { "start": { "line": 23, "column": 2 }, "end": { "line": 25, "column": 4 } }, "callee": { "type": "Identifier", "start": 456, "end": 458, "loc": { "start": { "line": 23, "column": 2 }, "end": { "line": 23, "column": 4 } }, "name": "it" }, "arguments": [ { "type": "Literal", "start": 459, "end": 486, "loc": { "start": { "line": 23, "column": 5 }, "end": { "line": 23, "column": 32 } }, "value": "should have a constructor", "rawValue": "should have a constructor", "raw": "\"should have a constructor\"" }, { "type": "ArrowFunctionExpression", "start": 488, "end": 528, "loc": { "start": { "line": 23, "column": 34 }, "end": { "line": 25, "column": 3 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [], "body": { "type": "BlockStatement", "start": 494, "end": 528, "loc": { "start": { "line": 23, "column": 40 }, "end": { "line": 25, "column": 3 } }, "body": [ { "type": "ExpressionStatement", "start": 500, "end": 524, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 28 } }, "expression": { "type": "CallExpression", "start": 500, "end": 523, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 27 } }, "callee": { "type": "MemberExpression", "start": 500, "end": 521, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 25 } }, "object": { "type": "MemberExpression", "start": 500, "end": 518, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 22 } }, "object": { "type": "MemberExpression", "start": 500, "end": 515, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 19 } }, "object": { "type": "CallExpression", "start": 500, "end": 512, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 16 } }, "callee": { "type": "Identifier", "start": 500, "end": 506, "loc": { "start": { "line": 24, "column": 4 }, "end": { "line": 24, "column": 10 } }, "name": "expect" }, "arguments": [ { "type": "Identifier", "start": 507, "end": 511, "loc": { "start": { "line": 24, "column": 11 }, "end": { "line": 24, "column": 15 } }, "name": "Tabs" } ] }, "property": { "type": "Identifier", "start": 513, "end": 515, "loc": { "start": { "line": 24, "column": 17 }, "end": { "line": 24, "column": 19 } }, "name": "to" }, "computed": false }, "property": { "type": "Identifier", "start": 516, "end": 518, "loc": { "start": { "line": 24, "column": 20 }, "end": { "line": 24, "column": 22 } }, "name": "be" }, "computed": false }, "property": { "type": "Identifier", "start": 519, "end": 521, "loc": { "start": { "line": 24, "column": 23 }, "end": { "line": 24, "column": 25 } }, "name": "ok" }, "computed": false }, "arguments": [] } } ] } } ], "_esdocTestId": 19, "_esdocTestName": "it19" } }, { "type": "ExpressionStatement", "start": 534, "end": 1056, "loc": { "start": { "line": 27, "column": 2 }, "end": { "line": 48, "column": 4 } }, "expression": { "type": "CallExpression", "start": 534, "end": 1056, "loc": { "start": { "line": 27, "column": 2 }, "end": { "line": 48, "column": 4 } }, "callee": { "type": "Identifier", "start": 534, "end": 542, "loc": { "start": { "line": 27, "column": 2 }, "end": { "line": 27, "column": 10 } }, "name": "describe" }, "arguments": [ { "type": "Literal", "start": 543, "end": 548, "loc": { "start": { "line": 27, "column": 11 }, "end": { "line": 27, "column": 16 } }, "value": "api", "rawValue": "api", "raw": "\"api\"" }, { "type": "ArrowFunctionExpression", "start": 550, "end": 1055, "loc": { "start": { "line": 27, "column": 18 }, "end": { "line": 48, "column": 3 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [], "body": { "type": "BlockStatement", "start": 556, "end": 1055, "loc": { "start": { "line": 27, "column": 24 }, "end": { "line": 48, "column": 3 } }, "body": [ { "type": "VariableDeclaration", "start": 562, "end": 576, "loc": { "start": { "line": 28, "column": 4 }, "end": { "line": 28, "column": 18 } }, "declarations": [ { "type": "VariableDeclarator", "start": 566, "end": 569, "loc": { "start": { "line": 28, "column": 8 }, "end": { "line": 28, "column": 11 } }, "id": { "type": "Identifier", "start": 566, "end": 569, "loc": { "start": { "line": 28, "column": 8 }, "end": { "line": 28, "column": 11 } }, "name": "$el" }, "init": null }, { "type": "VariableDeclarator", "start": 571, "end": 575, "loc": { "start": { "line": 28, "column": 13 }, "end": { "line": 28, "column": 17 } }, "id": { "type": "Identifier", "start": 571, "end": 575, "loc": { "start": { "line": 28, "column": 13 }, "end": { "line": 28, "column": 17 } }, "name": "tabs" }, "init": null } ], "kind": "let" }, { "type": "ExpressionStatement", "start": 582, "end": 682, "loc": { "start": { "line": 30, "column": 4 }, "end": { "line": 36, "column": 7 } }, "expression": { "type": "CallExpression", "start": 582, "end": 681, "loc": { "start": { "line": 30, "column": 4 }, "end": { "line": 36, "column": 6 } }, "callee": { "type": "Identifier", "start": 582, "end": 592, "loc": { "start": { "line": 30, "column": 4 }, "end": { "line": 30, "column": 14 } }, "name": "beforeEach" }, "arguments": [ { "type": "ArrowFunctionExpression", "start": 593, "end": 680, "loc": { "start": { "line": 30, "column": 15 }, "end": { "line": 36, "column": 5 } }, "id": null, "generator": false, "expression": false, "async": false, "params": [], "body": { "type": "BlockStatement", "start": 599, "end": 680, "loc": { "start": { "line": 30, "column": 21 }, "end": { "line": 36, "column": 5 } }, "body": [ { "type": "ExpressionStatement", "start": 607, "end": 623, "loc": { "start": { "line": 31, "column": 6 }, "end": { "line": 31, "column": 22 } }, "expression": { "type": "AssignmentExpression", "start": 607, "end": 623, "loc": { "start": { "line": 31, "column": 6 }, "end": { "line": 31, "column": 22 } }, "operator": "=", "left": { "type": "Identifier", "start": 607, "end": 610, "loc": { "start": { "line": 31, "column": 6 }, "end": { "line": 31, "column": 9 } }, "name": "$el" }, "right": { "type": "CallExpression", "start": 613, "end": 623, "loc": { "start": { "line": 31, "column": 12 }, "end": { "line": 31, "column": 22 } }, "callee": { "type": "Identifier", "start": 613, "end": 614, "loc": { "start": { "line": 31, "column": 12 }, "end": { "line": 31, "column": 13 } }, "name": "$" }, "arguments": [ { "type": "Identifier", "start": 615, "end": 622, "loc": { "start": { "line": 31, "column": 14 }, "end": { "line": 31, "column": 21 } }, "name": "fixture" } ] } } }, { "type": "ExpressionStatement", "start": 631, "end": 674, "loc": { "start": { "line": 33, "column": 6 }, "end": { "line": 35, "column": 9 } }, "expression": { "type": "AssignmentExpression", "start": 631, "end": 673, "loc": { "start": { "line": 33, "column": 6 }, "end": { "line": 35, "column": 8 } }, "operator": "=", "left": { "type": "Identifier", "start": 631, "end": 635, "loc": { "start": { "line": 33, "column": 6 }, "end": { "line": 33, "column": 10 } }, "name": "tabs" }, "right": { "type": "NewExpression", "start": 638, "end": 673, "loc": { "start": { "line": 33, "column": 13 }, "end": { "line": 35, "column": 8 } }, "callee": { "type": "Identifier", "start": 642, "end": 646, "loc": { "start": { "line": 33, "column": 17 }, "end": { "line": 33, "column": 21 } }, "name": "Tabs" }, "arguments": [ { "type": "ObjectExpression", "start": 647, "end": 672, "loc": { "start": { "line": 33, "column": 22 }, "end": { "line": 35, "column": 7 } }, "properties": [ { "type": "Property", "start": 657, "end": 664, "loc": { "start": { "line": 34, "column": 8 }, "end": { "line": 34, "column": 15 } }, "method": false, "shorthand": false, "computed": false, "key": { "type": "Identifier", "start": 657, "end": 659, "loc": { "start": { "line": 34, "column": 8 }, "end": { "line": 34, "column": 10 } }, "name": "el" }, "value": { "type": "Identifier", "start": 661, "end": 664, "loc": { "start": { "line": 34, "column": 12 }, "end": { "line": 34, "column": 15 } }, "name": "$el" }, "kind": "init" } ] } ] } } } ] } } ] } }, { "type": "ExpressionStatement", "start": 688, "end": 792, "loc": { "start": { "line": 38, "column": 4 }, "end": { "line": 40, "column": 7 } }, "expression": { "type": "CallExpression", "start": 688, "end": 791, "loc": { "start": { "line": 38, "column": 4 }, "end": { "line": 40, "column": 6 } }, "callee": { "type": "Identifier", "start": 688, "end": 690, "loc": { "start": { "line": 38, "column": 4 }, "end": { "line": 38, "column": 6 } }, "name": "it" }, "arguments": [ { "type": "Literal", "start": 691,