47df04a58ba37decb0c2021c10d0a07079a5f1bf
[platform/framework/web/crosswalk-tizen.git] /
1 var unprefixedKeys = {
2         Identifier: [],
3         NamespacedName: ['namespace', 'name'],
4         MemberExpression: ['object', 'property'],
5         EmptyExpression: [],
6         ExpressionContainer: ['expression'],
7         Element: ['openingElement', 'closingElement', 'children'],
8         ClosingElement: ['name'],
9         OpeningElement: ['name', 'attributes'],
10         Attribute: ['name', 'value'],
11         Text: null,
12         SpreadAttribute: ['argument']
13 };
14
15 var flowKeys = {
16         Type: [],
17         AnyTypeAnnotation: [],
18         VoidTypeAnnotation: [],
19         NumberTypeAnnotation: [],
20         StringTypeAnnotation: [],
21         StringLiteralTypeAnnotation: ["value", "raw"],
22         BooleanTypeAnnotation: [],
23         TypeAnnotation: ["typeAnnotation"],
24         NullableTypeAnnotation: ["typeAnnotation"],
25         FunctionTypeAnnotation: ["params", "returnType", "rest", "typeParameters"],
26         FunctionTypeParam: ["name", "typeAnnotation", "optional"],
27         ObjectTypeAnnotation: ["properties"],
28         ObjectTypeProperty: ["key", "value", "optional"],
29         ObjectTypeIndexer: ["id", "key", "value"],
30         ObjectTypeCallProperty: ["value"],
31         QualifiedTypeIdentifier: ["qualification", "id"],
32         GenericTypeAnnotation: ["id", "typeParameters"],
33         MemberTypeAnnotation: ["object", "property"],
34         UnionTypeAnnotation: ["types"],
35         IntersectionTypeAnnotation: ["types"],
36         TypeofTypeAnnotation: ["argument"],
37         TypeParameterDeclaration: ["params"],
38         TypeParameterInstantiation: ["params"],
39         ClassProperty: ["key", "typeAnnotation"],
40         ClassImplements: [],
41         InterfaceDeclaration: ["id", "body", "extends"],
42         InterfaceExtends: ["id"],
43         TypeAlias: ["id", "typeParameters", "right"],
44         TupleTypeAnnotation: ["types"],
45         DeclareVariable: ["id"],
46         DeclareFunction: ["id"],
47         DeclareClass: ["id"],
48         DeclareModule: ["id", "body"]
49 };
50
51 for (var key in unprefixedKeys) {
52         exports['XJS' + key] = exports['JSX' + key] = unprefixedKeys[key];
53 }
54
55 for (var key in flowKeys) {
56         exports[key] = flowKeys[key];
57 }