rizzo-next
Version:
The next generation of Lonely Planet's style guide and pattern library.
1,538 lines (1,537 loc) • 333 kB
JSON
{
"type": "Program",
"start": 0,
"end": 1600,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 70,
"column": 0
}
},
"sourceType": "module",
"body": [
{
"type": "ImportDeclaration",
"start": 0,
"end": 44,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 1,
"column": 44
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 9,
"end": 18,
"loc": {
"start": {
"line": 1,
"column": 9
},
"end": {
"line": 1,
"column": 18
}
},
"imported": {
"type": "Identifier",
"start": 9,
"end": 18,
"loc": {
"start": {
"line": 1,
"column": 9
},
"end": {
"line": 1,
"column": 18
}
},
"name": "Component"
},
"local": {
"type": "Identifier",
"start": 9,
"end": 18,
"loc": {
"start": {
"line": 1,
"column": 9
},
"end": {
"line": 1,
"column": 18
}
},
"name": "Component"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 26,
"end": 43,
"loc": {
"start": {
"line": 1,
"column": 26
},
"end": {
"line": 1,
"column": 43
}
},
"value": "../../core/bane",
"rawValue": "../../core/bane",
"raw": "\"../../core/bane\""
}
},
{
"type": "ImportDeclaration",
"start": 45,
"end": 71,
"loc": {
"start": {
"line": 2,
"column": 0
},
"end": {
"line": 2,
"column": 26
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 52,
"end": 57,
"loc": {
"start": {
"line": 2,
"column": 7
},
"end": {
"line": 2,
"column": 12
}
},
"local": {
"type": "Identifier",
"start": 52,
"end": 57,
"loc": {
"start": {
"line": 2,
"column": 7
},
"end": {
"line": 2,
"column": 12
}
},
"name": "React"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 63,
"end": 70,
"loc": {
"start": {
"line": 2,
"column": 18
},
"end": {
"line": 2,
"column": 25
}
},
"value": "react",
"rawValue": "react",
"raw": "\"react\""
}
},
{
"type": "ImportDeclaration",
"start": 72,
"end": 112,
"loc": {
"start": {
"line": 3,
"column": 0
},
"end": {
"line": 3,
"column": 40
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 79,
"end": 87,
"loc": {
"start": {
"line": 3,
"column": 7
},
"end": {
"line": 3,
"column": 15
}
},
"local": {
"type": "Identifier",
"start": 79,
"end": 87,
"loc": {
"start": {
"line": 3,
"column": 7
},
"end": {
"line": 3,
"column": 15
}
},
"name": "MainView"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 93,
"end": 111,
"loc": {
"start": {
"line": 3,
"column": 21
},
"end": {
"line": 3,
"column": 39
}
},
"value": "./views/main.jsx",
"rawValue": "./views/main.jsx",
"raw": "\"./views/main.jsx\""
}
},
{
"type": "ImportDeclaration",
"start": 113,
"end": 148,
"loc": {
"start": {
"line": 4,
"column": 0
},
"end": {
"line": 4,
"column": 35
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 120,
"end": 130,
"loc": {
"start": {
"line": 4,
"column": 7
},
"end": {
"line": 4,
"column": 17
}
},
"local": {
"type": "Identifier",
"start": 120,
"end": 130,
"loc": {
"start": {
"line": 4,
"column": 7
},
"end": {
"line": 4,
"column": 17
}
},
"name": "MapActions"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 136,
"end": 147,
"loc": {
"start": {
"line": 4,
"column": 23
},
"end": {
"line": 4,
"column": 34
}
},
"value": "./actions",
"rawValue": "./actions",
"raw": "\"./actions\""
}
},
{
"type": "ImportDeclaration",
"start": 149,
"end": 188,
"loc": {
"start": {
"line": 5,
"column": 0
},
"end": {
"line": 5,
"column": 39
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 156,
"end": 162,
"loc": {
"start": {
"line": 5,
"column": 7
},
"end": {
"line": 5,
"column": 13
}
},
"local": {
"type": "Identifier",
"start": 156,
"end": 162,
"loc": {
"start": {
"line": 5,
"column": 7
},
"end": {
"line": 5,
"column": 13
}
},
"name": "Arkham"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 168,
"end": 187,
"loc": {
"start": {
"line": 5,
"column": 19
},
"end": {
"line": 5,
"column": 38
}
},
"value": "../../core/arkham",
"rawValue": "../../core/arkham",
"raw": "\"../../core/arkham\""
}
},
{
"type": "ImportDeclaration",
"start": 189,
"end": 229,
"loc": {
"start": {
"line": 6,
"column": 0
},
"end": {
"line": 6,
"column": 40
}
},
"specifiers": [
{
"type": "ImportSpecifier",
"start": 198,
"end": 211,
"loc": {
"start": {
"line": 6,
"column": 9
},
"end": {
"line": 6,
"column": 22
}
},
"imported": {
"type": "Identifier",
"start": 198,
"end": 211,
"loc": {
"start": {
"line": 6,
"column": 9
},
"end": {
"line": 6,
"column": 22
}
},
"name": "createHistory"
},
"local": {
"type": "Identifier",
"start": 198,
"end": 211,
"loc": {
"start": {
"line": 6,
"column": 9
},
"end": {
"line": 6,
"column": 22
}
},
"name": "createHistory"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 219,
"end": 228,
"loc": {
"start": {
"line": 6,
"column": 30
},
"end": {
"line": 6,
"column": 39
}
},
"value": "history",
"rawValue": "history",
"raw": "\"history\""
}
},
{
"type": "ImportDeclaration",
"start": 230,
"end": 253,
"loc": {
"start": {
"line": 7,
"column": 0
},
"end": {
"line": 7,
"column": 23
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 237,
"end": 238,
"loc": {
"start": {
"line": 7,
"column": 7
},
"end": {
"line": 7,
"column": 8
}
},
"local": {
"type": "Identifier",
"start": 237,
"end": 238,
"loc": {
"start": {
"line": 7,
"column": 7
},
"end": {
"line": 7,
"column": 8
}
},
"name": "$"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 244,
"end": 252,
"loc": {
"start": {
"line": 7,
"column": 14
},
"end": {
"line": 7,
"column": 22
}
},
"value": "jquery",
"rawValue": "jquery",
"raw": "\"jquery\""
}
},
{
"type": "ImportDeclaration",
"start": 255,
"end": 286,
"loc": {
"start": {
"line": 8,
"column": 0
},
"end": {
"line": 8,
"column": 31
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 262,
"end": 268,
"loc": {
"start": {
"line": 8,
"column": 7
},
"end": {
"line": 8,
"column": 13
}
},
"local": {
"type": "Identifier",
"start": 262,
"end": 268,
"loc": {
"start": {
"line": 8,
"column": 7
},
"end": {
"line": 8,
"column": 13
}
},
"name": "MapApi"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 274,
"end": 285,
"loc": {
"start": {
"line": 8,
"column": 19
},
"end": {
"line": 8,
"column": 30
}
},
"value": "./map_api",
"rawValue": "./map_api",
"raw": "\"./map_api\""
}
},
{
"type": "VariableDeclaration",
"start": 288,
"end": 318,
"loc": {
"start": {
"line": 10,
"column": 0
},
"end": {
"line": 10,
"column": 30
}
},
"declarations": [
{
"type": "VariableDeclarator",
"start": 292,
"end": 317,
"loc": {
"start": {
"line": 10,
"column": 4
},
"end": {
"line": 10,
"column": 29
}
},
"id": {
"type": "Identifier",
"start": 292,
"end": 299,
"loc": {
"start": {
"line": 10,
"column": 4
},
"end": {
"line": 10,
"column": 11
}
},
"name": "history"
},
"init": {
"type": "CallExpression",
"start": 302,
"end": 317,
"loc": {
"start": {
"line": 10,
"column": 14
},
"end": {
"line": 10,
"column": 29
}
},
"callee": {
"type": "Identifier",
"start": 302,
"end": 315,
"loc": {
"start": {
"line": 10,
"column": 14
},
"end": {
"line": 10,
"column": 27
}
},
"name": "createHistory"
},
"arguments": []
}
}
],
"kind": "let"
},
{
"type": "Identifier",
"start": 320,
"end": 1569,
"loc": {
"start": {
"line": 12,
"column": 0
},
"end": {
"line": 67,
"column": 1
}
},
"id": {
"type": "Identifier",
"start": 326,
"end": 338,
"loc": {
"start": {
"line": 12,
"column": 6
},
"end": {
"line": 12,
"column": 18
}
},
"name": "MapComponent"
},
"superClass": {
"type": "Identifier",
"start": 347,
"end": 356,
"loc": {
"start": {
"line": 12,
"column": 27
},
"end": {
"line": 12,
"column": 36
}
},
"name": "Component"
},
"body": {
"type": "ClassBody",
"start": 357,
"end": 1569,
"loc": {
"start": {
"line": 12,
"column": 37
},
"end": {
"line": 67,
"column": 1
}
},
"body": [
{
"type": "MethodDefinition",
"start": 362,
"end": 663,
"loc": {
"start": {
"line": 14,
"column": 2
},
"end": {
"line": 25,
"column": 3
}
},
"computed": false,
"key": {
"type": "Identifier",
"start": 362,
"end": 372,
"loc": {
"start": {
"line": 14,
"column": 2
},
"end": {
"line": 14,
"column": 12
}
},
"name": "initialize"
},
"static": false,
"kind": "method",
"value": {
"type": "FunctionExpression",
"start": 372,
"end": 663,
"loc": {
"start": {
"line": 14,
"column": 12
},
"end": {
"line": 25,
"column": 3
}
},
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [],
"body": {
"type": "BlockStatement",
"start": 375,
"end": 663,
"loc": {
"start": {
"line": 14,
"column": 15
},
"end": {
"line": 25,
"column": 3
}
},
"body": [
{
"type": "ExpressionStatement",
"start": 381,
"end": 541,
"loc": {
"start": {
"line": 15,
"column": 4
},
"end": {
"line": 18,
"column": 7
}
},
"expression": {
"type": "CallExpression",
"start": 381,
"end": 540,
"loc": {
"start": {
"line": 15,
"column": 4
},
"end": {
"line": 18,
"column": 6
}
},
"callee": {
"type": "MemberExpression",
"start": 381,
"end": 435,
"loc": {
"start": {
"line": 15,
"column": 4
},
"end": {
"line": 15,
"column": 58
}
},
"object": {
"type": "CallExpression",
"start": 381,
"end": 430,
"loc": {
"start": {
"line": 15,
"column": 4
},
"end": {
"line": 15,
"column": 53
}
},
"callee": {
"type": "MemberExpression",
"start": 381,
"end": 393,
"loc": {
"start": {
"line": 15,
"column": 4
},
"end": {
"line": 15,
"column": 16
}
},
"object": {
"type": "Identifier",
"start": 381,
"end": 387,
"loc": {
"start": {
"line": 15,
"column": 4
},
"end": {
"line": 15,
"column": 10
}
},
"name": "MapApi"
},
"property": {
"type": "Identifier",
"start": 388,
"end": 393,
"loc": {
"start": {
"line": 15,
"column": 11
},
"end": {
"line": 15,
"column": 16
}
},
"name": "fetch"
},
"computed": false
},
"arguments": [
{
"type": "TemplateLiteral",
"start": 394,
"end": 429,
"loc": {
"start": {
"line": 15,
"column": 17
},
"end": {
"line": 15,
"column": 52
}
},
"expressions": [
{
"type": "MemberExpression",
"start": 398,
"end": 418,
"loc": {
"start": {
"line": 15,
"column": 21
},
"end": {
"line": 15,
"column": 41
}
},
"object": {
"type": "MemberExpression",
"start": 398,
"end": 413,
"loc": {
"start": {
"line": 15,
"column": 21
},
"end": {
"line": 15,
"column": 36
}
},
"object": {
"type": "MemberExpression",
"start": 398,
"end": 407,
"loc": {
"start": {
"line": 15,
"column": 21
},
"end": {
"line": 15,
"column": 30
}
},
"object": {
"type": "Identifier",
"start": 398,
"end": 404,
"loc": {
"start": {
"line": 15,
"column": 21
},
"end": {
"line": 15,
"column": 27
}
},
"name": "window"
},
"property": {
"type": "Identifier",
"start": 405,
"end": 407,
"loc": {
"start": {
"line": 15,
"column": 28
},
"end": {
"line": 15,
"column": 30
}
},
"name": "lp"
},
"computed": false
},
"property": {
"type": "Identifier",
"start": 408,
"end": 413,
"loc": {
"start": {
"line": 15,
"column": 31
},
"end": {
"line": 15,
"column": 36
}
},
"name": "place"
},
"computed": false
},
"property": {
"type": "Identifier",
"start": 414,
"end": 418,
"loc": {
"start": {
"line": 15,
"column": 37
},
"end": {
"line": 15,
"column": 41
}
},
"name": "slug"
},
"computed": false
}
],
"quasis": [
{
"type": "TemplateElement",
"start": 395,
"end": 396,
"loc": {
"start": {
"line": 15,
"column": 18
},
"end": {
"line": 15,
"column": 19
}
},
"value": {
"raw": "/",
"cooked": "/"
},
"tail": false
},
{
"type": "TemplateElement",
"start": 419,
"end": 428,
"loc": {
"start": {
"line": 15,
"column": 42
},
"end": {
"line": 15,
"column": 51
}
},
"value": {
"raw": "/map.json",
"cooked": "/map.json"
},
"tail": true
}
]
}
]
},
"property": {
"type": "Identifier",
"start": 431,
"end": 435,
"loc": {
"start": {
"line": 15,
"column": 54
},
"end": {
"line": 15,
"column": 58
}
},
"name": "done"
},
"computed": false
},
"arguments": [
{
"type": "ArrowFunctionExpression",
"start": 436,
"end": 539,
"loc": {
"start": {
"line": 15,
"column": 59
},
"end": {
"line": 18,
"column": 5
}
},
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [
{
"type": "Identifier",
"start": 437,
"end": 444,
"loc": {
"start": {
"line": 15,
"column": 60
},
"end": {
"line": 15,
"column": 67
}
},
"name": "results"
}
],
"body": {
"type": "BlockStatement",
"start": 449,
"end": 539,
"loc": {
"start": {
"line": 15,
"column": 72
},
"end": {
"line": 18,
"column": 5
}
},
"body": [
{
"type": "ExpressionStatement",
"start": 457,
"end": 486,
"loc": {
"start": {
"line": 16,
"column": 6
},
"end": {
"line": 16,
"column": 35
}
},
"expression": {
"type": "CallExpression",
"start": 457,
"end": 485,
"loc": {
"start": {
"line": 16,
"column": 6
},
"end": {
"line": 16,
"column": 34
}
},
"callee": {
"type": "MemberExpression",
"start": 457,
"end": 476,
"loc": {
"start": {
"line": 16,
"column": 6
},
"end": {
"line": 16,
"column": 25
}
},
"object": {
"type": "Identifier",
"start": 457,
"end": 467,
"loc": {
"start": {
"line": 16,
"column": 6
},
"end": {
"line": 16,
"column": 16
}
},
"name": "MapActions"
},
"property": {
"type": "Identifier",
"start": 468,
"end": 476,
"loc": {
"start": {
"line": 16,
"column": 17
},
"end": {
"line": 16,
"column": 25
}
},
"name": "setState"
},
"computed": false
},
"arguments": [
{
"type": "Identifier",
"start": 477,
"end": 484,
"loc": {
"start": {
"line": 16,
"column": 26
},
"end": {
"line": 16,
"column": 33
}
},
"name": "results"
}
]
}
},
{
"type": "ExpressionStatement",
"start": 493,
"end": 533,
"loc": {
"start": {
"line": 17,
"column": 6
},
"end": {
"line": 17,
"column": 46
}
},
"expression": {
"type": "CallExpression",
"start": 493,
"end": 532,
"loc": {
"start": {
"line": 17,
"column": 6
},
"end": {
"line": 17,
"column": 45
}
},
"callee": {
"type": "MemberExpression",
"start": 493,
"end": 505,
"loc": {
"start": {
"line": 17,
"column": 6
},
"end": {
"line": 17,
"column": 18
}
},
"object": {
"type": "Identifier",
"start": 493,
"end": 498,
"loc": {
"start": {
"line": 17,
"column": 6
},
"end": {
"line": 17,
"column": 11
}
},
"name": "React"
},
"property": {
"type": "Identifier",
"start": 499,
"end": 505,
"loc": {
"start": {
"line": 17,
"column": 12
},
"end": {
"line": 17,
"column": 18
}
},
"name": "render"
},
"computed": false
},
"arguments": [
{
"type": "JSXElement",
"start": 506,
"end": 518,
"loc": {
"start": {
"line": 17,
"column": 19
},
"end": {
"line": 17,
"column": 31
}
},
"openingElement": {
"type": "JSXOpeningElement",
"start": 506,
"end": 518,
"loc": {
"start": {
"line": 17,
"column": 19
},
"end": {
"line": 17,
"column": 31
}
},
"attributes": [],
"name": {
"type": "JSXIdentifier",
"start": 507,
"end": 515,
"loc": {
"start": {
"line": 17,
"column": 20
},
"end": {
"line": 17,
"column": 28
}
},
"name": "MainView"
},
"selfClosing": true
},
"closingElement": null,
"children": []
},
{
"type": "MemberExpression",
"start": 520,
"end": 531,
"loc": {
"start": {
"line": 17,
"column": 33
},
"end": {
"line": 17,
"column": 44
}
},
"object": {
"type": "MemberExpression",
"start": 520,
"end": 528,
"loc": {
"start": {
"line": 17,
"column": 33
},
"end": {
"line": 17,
"column": 41
}
},
"object": {
"type": "ThisExpression",
"start": 520,
"end": 524,
"loc": {
"start": {
"line": 17,
"column": 33
},
"end": {
"line": 17,
"column": 37
}
}
},
"property": {
"type": "Identifier",
"start": 525,
"end": 528,
"loc": {
"start": {
"line": 17,
"column": 38
},
"end": {
"line": 17,
"column": 41
}
},
"name": "$el"
},
"computed": false
},
"property": {
"type": "Literal",
"start": 529,
"end": 530,
"loc": {
"start": {
"line": 17,
"column": 42
},
"end": {
"line": 17,
"column": 43
}
},
"value": 0,
"rawValue": 0,
"raw": "0"
},
"computed": true
}
]
}
}
]
}
}
]
}
},
{
"type": "ExpressionStatement",
"start": 547,
"end": 606,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 22,
"column": 7
}
},
"expression": {
"type": "CallExpression",
"start": 547,
"end": 605,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 22,
"column": 6
}
},
"callee": {
"type": "MemberExpression",
"start": 547,
"end": 556,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 20,
"column": 13
}
},
"object": {
"type": "Identifier",
"start": 547,
"end": 553,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 20,
"column": 10
}
},
"name": "Arkham"
},
"property": {
"type": "Identifier",
"start": 554,
"end": 556,
"loc": {
"start": {
"line": 20,
"column": 11
},
"end": {
"line": 20,
"column": 13
}
},
"name": "on"
},
"computed": false
},
"arguments": [
{
"type": "Literal",
"start": 557,
"end": 569,
"loc": {
"start": {