rizzo-next
Version:
The next generation of Lonely Planet's style guide and pattern library.
1,515 lines • 69.6 kB
JSON
{
"type": "Program",
"start": 0,
"end": 1135,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 40,
"column": 0
}
},
"sourceType": "module",
"body": [
{
"type": "ImportDeclaration",
"start": 0,
"end": 42,
"loc": {
"start": {
"line": 1,
"column": 0
},
"end": {
"line": 1,
"column": 42
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 7,
"end": 13,
"loc": {
"start": {
"line": 1,
"column": 7
},
"end": {
"line": 1,
"column": 13
}
},
"local": {
"type": "Identifier",
"start": 7,
"end": 13,
"loc": {
"start": {
"line": 1,
"column": 7
},
"end": {
"line": 1,
"column": 13
}
},
"name": "assign"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 19,
"end": 41,
"loc": {
"start": {
"line": 1,
"column": 19
},
"end": {
"line": 1,
"column": 41
}
},
"value": "lodash/object/assign",
"rawValue": "lodash/object/assign",
"raw": "\"lodash/object/assign\""
}
},
{
"type": "ImportDeclaration",
"start": 43,
"end": 89,
"loc": {
"start": {
"line": 2,
"column": 0
},
"end": {
"line": 2,
"column": 46
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 50,
"end": 56,
"loc": {
"start": {
"line": 2,
"column": 7
},
"end": {
"line": 2,
"column": 13
}
},
"local": {
"type": "Identifier",
"start": 50,
"end": 56,
"loc": {
"start": {
"line": 2,
"column": 7
},
"end": {
"line": 2,
"column": 13
}
},
"name": "Events"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 62,
"end": 88,
"loc": {
"start": {
"line": 2,
"column": 19
},
"end": {
"line": 2,
"column": 45
}
},
"value": "../../core/mixins/events",
"rawValue": "../../core/mixins/events",
"raw": "\"../../core/mixins/events\""
}
},
{
"type": "ImportDeclaration",
"start": 90,
"end": 129,
"loc": {
"start": {
"line": 3,
"column": 0
},
"end": {
"line": 3,
"column": 39
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 97,
"end": 103,
"loc": {
"start": {
"line": 3,
"column": 7
},
"end": {
"line": 3,
"column": 13
}
},
"local": {
"type": "Identifier",
"start": 97,
"end": 103,
"loc": {
"start": {
"line": 3,
"column": 7
},
"end": {
"line": 3,
"column": 13
}
},
"name": "Arkham"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 109,
"end": 128,
"loc": {
"start": {
"line": 3,
"column": 19
},
"end": {
"line": 3,
"column": 38
}
},
"value": "../../core/arkham",
"rawValue": "../../core/arkham",
"raw": "\"../../core/arkham\""
}
},
{
"type": "ImportDeclaration",
"start": 130,
"end": 187,
"loc": {
"start": {
"line": 4,
"column": 0
},
"end": {
"line": 4,
"column": 57
}
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"start": 137,
"end": 151,
"loc": {
"start": {
"line": 4,
"column": 7
},
"end": {
"line": 4,
"column": 21
}
},
"local": {
"type": "Identifier",
"start": 137,
"end": 151,
"loc": {
"start": {
"line": 4,
"column": 7
},
"end": {
"line": 4,
"column": 21
}
},
"name": "ShopCookieUtil"
}
}
],
"importKind": "value",
"source": {
"type": "Literal",
"start": 157,
"end": 186,
"loc": {
"start": {
"line": 4,
"column": 27
},
"end": {
"line": 4,
"column": 56
}
},
"value": "../../core/shop_cookie_util",
"rawValue": "../../core/shop_cookie_util",
"raw": "\"../../core/shop_cookie_util\""
},
"trailingComments": [
{
"type": "Block",
"value": " mock data ",
"start": 189,
"end": 204,
"loc": {
"start": {
"line": 6,
"column": 0
},
"end": {
"line": 6,
"column": 15
}
},
"range": [
189,
204
]
}
]
},
{
"type": "VariableDeclaration",
"start": 206,
"end": 861,
"loc": {
"start": {
"line": 8,
"column": 0
},
"end": {
"line": 23,
"column": 2
}
},
"declarations": [
{
"type": "VariableDeclarator",
"start": 210,
"end": 860,
"loc": {
"start": {
"line": 8,
"column": 4
},
"end": {
"line": 23,
"column": 1
}
},
"id": {
"type": "Identifier",
"start": 210,
"end": 215,
"loc": {
"start": {
"line": 8,
"column": 4
},
"end": {
"line": 8,
"column": 9
}
},
"name": "state",
"leadingComments": null
},
"init": {
"type": "ObjectExpression",
"start": 218,
"end": 860,
"loc": {
"start": {
"line": 8,
"column": 12
},
"end": {
"line": 23,
"column": 1
}
},
"properties": [
{
"type": "Property",
"start": 222,
"end": 235,
"loc": {
"start": {
"line": 9,
"column": 2
},
"end": {
"line": 9,
"column": 15
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 222,
"end": 228,
"loc": {
"start": {
"line": 9,
"column": 2
},
"end": {
"line": 9,
"column": 8
}
},
"name": "isOpen"
},
"value": {
"type": "Literal",
"start": 230,
"end": 235,
"loc": {
"start": {
"line": 9,
"column": 10
},
"end": {
"line": 9,
"column": 15
}
},
"value": false,
"rawValue": false,
"raw": "false"
},
"kind": "init"
},
{
"type": "Property",
"start": 239,
"end": 255,
"loc": {
"start": {
"line": 10,
"column": 2
},
"end": {
"line": 10,
"column": 18
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 239,
"end": 248,
"loc": {
"start": {
"line": 10,
"column": 2
},
"end": {
"line": 10,
"column": 11
}
},
"name": "isNavOpen"
},
"value": {
"type": "Literal",
"start": 250,
"end": 255,
"loc": {
"start": {
"line": 10,
"column": 13
},
"end": {
"line": 10,
"column": 18
}
},
"value": false,
"rawValue": false,
"raw": "false"
},
"kind": "init"
},
{
"type": "Property",
"start": 259,
"end": 313,
"loc": {
"start": {
"line": 11,
"column": 2
},
"end": {
"line": 11,
"column": 56
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 259,
"end": 272,
"loc": {
"start": {
"line": 11,
"column": 2
},
"end": {
"line": 11,
"column": 15
}
},
"name": "cartItemCount"
},
"value": {
"type": "CallExpression",
"start": 274,
"end": 313,
"loc": {
"start": {
"line": 11,
"column": 17
},
"end": {
"line": 11,
"column": 56
}
},
"callee": {
"type": "MemberExpression",
"start": 274,
"end": 311,
"loc": {
"start": {
"line": 11,
"column": 17
},
"end": {
"line": 11,
"column": 54
}
},
"object": {
"type": "NewExpression",
"start": 274,
"end": 294,
"loc": {
"start": {
"line": 11,
"column": 17
},
"end": {
"line": 11,
"column": 37
}
},
"callee": {
"type": "Identifier",
"start": 278,
"end": 292,
"loc": {
"start": {
"line": 11,
"column": 21
},
"end": {
"line": 11,
"column": 35
}
},
"name": "ShopCookieUtil"
},
"arguments": []
},
"property": {
"type": "Identifier",
"start": 295,
"end": 311,
"loc": {
"start": {
"line": 11,
"column": 38
},
"end": {
"line": 11,
"column": 54
}
},
"name": "getShopItemCount"
},
"computed": false
},
"arguments": []
},
"kind": "init"
},
{
"type": "Property",
"start": 317,
"end": 858,
"loc": {
"start": {
"line": 12,
"column": 2
},
"end": {
"line": 22,
"column": 3
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 317,
"end": 321,
"loc": {
"start": {
"line": 12,
"column": 2
},
"end": {
"line": 12,
"column": 6
}
},
"name": "cart"
},
"value": {
"type": "ObjectExpression",
"start": 323,
"end": 858,
"loc": {
"start": {
"line": 12,
"column": 8
},
"end": {
"line": 22,
"column": 3
}
},
"properties": [
{
"type": "Property",
"start": 329,
"end": 356,
"loc": {
"start": {
"line": 13,
"column": 4
},
"end": {
"line": 13,
"column": 31
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 329,
"end": 334,
"loc": {
"start": {
"line": 13,
"column": 4
},
"end": {
"line": 13,
"column": 9
}
},
"name": "title"
},
"value": {
"type": "Literal",
"start": 336,
"end": 356,
"loc": {
"start": {
"line": 13,
"column": 11
},
"end": {
"line": 13,
"column": 31
}
},
"value": "YOUR SHOPPING CART",
"rawValue": "YOUR SHOPPING CART",
"raw": "\"YOUR SHOPPING CART\""
},
"kind": "init"
},
{
"type": "Property",
"start": 362,
"end": 765,
"loc": {
"start": {
"line": 14,
"column": 4
},
"end": {
"line": 19,
"column": 46
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 362,
"end": 367,
"loc": {
"start": {
"line": 14,
"column": 4
},
"end": {
"line": 14,
"column": 9
}
},
"name": "items"
},
"value": {
"type": "ArrayExpression",
"start": 369,
"end": 765,
"loc": {
"start": {
"line": 14,
"column": 11
},
"end": {
"line": 19,
"column": 46
}
},
"elements": [
{
"type": "ObjectExpression",
"start": 371,
"end": 558,
"loc": {
"start": {
"line": 14,
"column": 13
},
"end": {
"line": 16,
"column": 44
}
},
"properties": [
{
"type": "Property",
"start": 373,
"end": 402,
"loc": {
"start": {
"line": 14,
"column": 15
},
"end": {
"line": 14,
"column": 44
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 373,
"end": 377,
"loc": {
"start": {
"line": 14,
"column": 15
},
"end": {
"line": 14,
"column": 19
}
},
"name": "name"
},
"value": {
"type": "Literal",
"start": 379,
"end": 402,
"loc": {
"start": {
"line": 14,
"column": 21
},
"end": {
"line": 14,
"column": 44
}
},
"value": "Thailand Travel Guide",
"rawValue": "Thailand Travel Guide",
"raw": "\"Thailand Travel Guide\""
},
"kind": "init"
},
{
"type": "Property",
"start": 404,
"end": 419,
"loc": {
"start": {
"line": 14,
"column": 46
},
"end": {
"line": 14,
"column": 61
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 404,
"end": 409,
"loc": {
"start": {
"line": 14,
"column": 46
},
"end": {
"line": 14,
"column": 51
}
},
"name": "price"
},
"value": {
"type": "Literal",
"start": 411,
"end": 419,
"loc": {
"start": {
"line": 14,
"column": 53
},
"end": {
"line": 14,
"column": 61
}
},
"value": "$19.99",
"rawValue": "$19.99",
"raw": "\"$19.99\""
},
"kind": "init"
},
{
"type": "Property",
"start": 435,
"end": 512,
"loc": {
"start": {
"line": 15,
"column": 14
},
"end": {
"line": 15,
"column": 91
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 435,
"end": 440,
"loc": {
"start": {
"line": 15,
"column": 14
},
"end": {
"line": 15,
"column": 19
}
},
"name": "image"
},
"value": {
"type": "Literal",
"start": 442,
"end": 512,
"loc": {
"start": {
"line": 15,
"column": 21
},
"end": {
"line": 15,
"column": 91
}
},
"value": "http://www.trentcap.com/wp/wp-content/uploads/2012/02/sample-img.png",
"rawValue": "http://www.trentcap.com/wp/wp-content/uploads/2012/02/sample-img.png",
"raw": "\"http://www.trentcap.com/wp/wp-content/uploads/2012/02/sample-img.png\""
},
"kind": "init"
},
{
"type": "Property",
"start": 528,
"end": 556,
"loc": {
"start": {
"line": 16,
"column": 14
},
"end": {
"line": 16,
"column": 42
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 528,
"end": 531,
"loc": {
"start": {
"line": 16,
"column": 14
},
"end": {
"line": 16,
"column": 17
}
},
"name": "alt"
},
"value": {
"type": "Literal",
"start": 533,
"end": 556,
"loc": {
"start": {
"line": 16,
"column": 19
},
"end": {
"line": 16,
"column": 42
}
},
"value": "Thailand Travel Guide",
"rawValue": "Thailand Travel Guide",
"raw": "\"Thailand Travel Guide\""
},
"kind": "init"
}
]
},
{
"type": "ObjectExpression",
"start": 572,
"end": 763,
"loc": {
"start": {
"line": 17,
"column": 12
},
"end": {
"line": 19,
"column": 44
}
},
"properties": [
{
"type": "Property",
"start": 574,
"end": 607,
"loc": {
"start": {
"line": 17,
"column": 14
},
"end": {
"line": 17,
"column": 47
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 574,
"end": 578,
"loc": {
"start": {
"line": 17,
"column": 14
},
"end": {
"line": 17,
"column": 18
}
},
"name": "name"
},
"value": {
"type": "Literal",
"start": 580,
"end": 607,
"loc": {
"start": {
"line": 17,
"column": 20
},
"end": {
"line": 17,
"column": 47
}
},
"value": "Southeast Asia on a Shoes",
"rawValue": "Southeast Asia on a Shoes",
"raw": "\"Southeast Asia on a Shoes\""
},
"kind": "init"
},
{
"type": "Property",
"start": 609,
"end": 624,
"loc": {
"start": {
"line": 17,
"column": 49
},
"end": {
"line": 17,
"column": 64
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 609,
"end": 614,
"loc": {
"start": {
"line": 17,
"column": 49
},
"end": {
"line": 17,
"column": 54
}
},
"name": "price"
},
"value": {
"type": "Literal",
"start": 616,
"end": 624,
"loc": {
"start": {
"line": 17,
"column": 56
},
"end": {
"line": 17,
"column": 64
}
},
"value": "$29.99",
"rawValue": "$29.99",
"raw": "\"$29.99\""
},
"kind": "init"
},
{
"type": "Property",
"start": 640,
"end": 717,
"loc": {
"start": {
"line": 18,
"column": 14
},
"end": {
"line": 18,
"column": 91
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 640,
"end": 645,
"loc": {
"start": {
"line": 18,
"column": 14
},
"end": {
"line": 18,
"column": 19
}
},
"name": "image"
},
"value": {
"type": "Literal",
"start": 647,
"end": 717,
"loc": {
"start": {
"line": 18,
"column": 21
},
"end": {
"line": 18,
"column": 91
}
},
"value": "http://www.trentcap.com/wp/wp-content/uploads/2012/02/sample-img.png",
"rawValue": "http://www.trentcap.com/wp/wp-content/uploads/2012/02/sample-img.png",
"raw": "\"http://www.trentcap.com/wp/wp-content/uploads/2012/02/sample-img.png\""
},
"kind": "init"
},
{
"type": "Property",
"start": 733,
"end": 761,
"loc": {
"start": {
"line": 19,
"column": 14
},
"end": {
"line": 19,
"column": 42
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 733,
"end": 736,
"loc": {
"start": {
"line": 19,
"column": 14
},
"end": {
"line": 19,
"column": 17
}
},
"name": "alt"
},
"value": {
"type": "Literal",
"start": 738,
"end": 761,
"loc": {
"start": {
"line": 19,
"column": 19
},
"end": {
"line": 19,
"column": 42
}
},
"value": "Thailand Travel Guide",
"rawValue": "Thailand Travel Guide",
"raw": "\"Thailand Travel Guide\""
},
"kind": "init"
}
]
}
]
},
"kind": "init"
},
{
"type": "Property",
"start": 771,
"end": 814,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 20,
"column": 47
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 771,
"end": 777,
"loc": {
"start": {
"line": 20,
"column": 4
},
"end": {
"line": 20,
"column": 10
}
},
"name": "action"
},
"value": {
"type": "Literal",
"start": 779,
"end": 814,
"loc": {
"start": {
"line": 20,
"column": 12
},
"end": {
"line": 20,
"column": 47
}
},
"value": "//shop.lonelyplanet.com/cart/view",
"rawValue": "//shop.lonelyplanet.com/cart/view",
"raw": "\"//shop.lonelyplanet.com/cart/view\""
},
"kind": "init"
},
{
"type": "Property",
"start": 820,
"end": 854,
"loc": {
"start": {
"line": 21,
"column": 4
},
"end": {
"line": 21,
"column": 38
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 820,
"end": 831,
"loc": {
"start": {
"line": 21,
"column": 4
},
"end": {
"line": 21,
"column": 15
}
},
"name": "actiontitle"
},
"value": {
"type": "Literal",
"start": 833,
"end": 854,
"loc": {
"start": {
"line": 21,
"column": 17
},
"end": {
"line": 21,
"column": 38
}
},
"value": "PROCEED TO CHECKOUT",
"rawValue": "PROCEED TO CHECKOUT",
"raw": "\"PROCEED TO CHECKOUT\""
},
"kind": "init"
}
]
},
"kind": "init"
}
]
},
"leadingComments": null
}
],
"kind": "let",
"leadingComments": [
{
"type": "Block",
"value": " mock data ",
"start": 189,
"end": 204,
"loc": {
"start": {
"line": 6,
"column": 0
},
"end": {
"line": 6,
"column": 15
}
},
"range": [
189,
204
]
}
]
},
{
"type": "Identifier",
"start": 863,
"end": 931,
"loc": {
"start": {
"line": 25,
"column": 0
},
"end": {
"line": 29,
"column": 2
}
},
"declarations": [
{
"type": "VariableDeclarator",
"start": 867,
"end": 930,
"loc": {
"start": {
"line": 25,
"column": 4
},
"end": {
"line": 29,
"column": 1
}
},
"id": {
"type": "Identifier",
"start": 867,
"end": 882,
"loc": {
"start": {
"line": 25,
"column": 4
},
"end": {
"line": 25,
"column": 19
}
},
"name": "NavigationState"
},
"init": {
"type": "ObjectExpression",
"start": 885,
"end": 930,
"loc": {
"start": {
"line": 25,
"column": 22
},
"end": {
"line": 29,
"column": 1
}
},
"properties": [
{
"type": "Property",
"start": 889,
"end": 928,
"loc": {
"start": {
"line": 26,
"column": 2
},
"end": {
"line": 28,
"column": 3
}
},
"method": false,
"shorthand": false,
"computed": false,
"key": {
"type": "Identifier",
"start": 889,
"end": 897,
"loc": {
"start": {
"line": 26,
"column": 2
},
"end": {
"line": 26,
"column": 10
}
},
"name": "getState"
},
"value": {
"type": "ArrowFunctionExpression",
"start": 899,
"end": 928,
"loc": {
"start": {
"line": 26,
"column": 12
},
"end": {
"line": 28,
"column": 3
}
},
"id": null,
"generator": false,
"expression": false,
"async": false,
"params": [],
"body": {
"type": "BlockStatement",
"start": 905,
"end": 928,
"loc": {
"start": {
"line": 26,
"column": 18
},
"end": {
"line": 28,
"column": 3
}
},
"body": [
{
"type": "ReturnStatement",
"start": 911,
"end": 924,
"loc": {
"start": {
"line": 27,
"column": 4
},
"end": {
"line": 27,
"column": 17
}
},
"argument": {
"type": "Identifier",
"start": 918,
"end": 923,
"loc": {
"start": {
"line": 27,
"column": 11
},
"end": {
"line": 27,
"column": 16
}
},
"name": "state"
}
}
]
}
},
"kind": "init"
}
]
}
}
],
"kind": "let",
"name": "_",
"leadingComments": [],
"trailingComments": []
},
{
"type": "ExpressionStatement",
"start": 933,
"end": 965,
"loc":