@oanda/labs-instrument-live-rate-widget 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/codegen.ts +15 -0
- package/dist/main/InstrumentLiveRateWidget/InstrumentLiveRateWidget.js +56 -0
- package/dist/main/InstrumentLiveRateWidget/InstrumentLiveRateWidget.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/Main.js +77 -0
- package/dist/main/InstrumentLiveRateWidget/Main.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/components/InstrumentRateWithData/InstrumentRateWithData.js +83 -0
- package/dist/main/InstrumentLiveRateWidget/components/InstrumentRateWithData/InstrumentRateWithData.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/components/InstrumentRateWithData/index.js +28 -0
- package/dist/main/InstrumentLiveRateWidget/components/InstrumentRateWithData/index.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/components/InstrumentRateWithData/utils.js +25 -0
- package/dist/main/InstrumentLiveRateWidget/components/InstrumentRateWithData/utils.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/components/LineChartWithData/LineChartWithData.js +44 -0
- package/dist/main/InstrumentLiveRateWidget/components/LineChartWithData/LineChartWithData.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/components/LineChartWithData/index.js +17 -0
- package/dist/main/InstrumentLiveRateWidget/components/LineChartWithData/index.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/components/LineChartWithData/types.js +6 -0
- package/dist/main/InstrumentLiveRateWidget/components/LineChartWithData/types.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/components/index.js +17 -0
- package/dist/main/InstrumentLiveRateWidget/components/index.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/constant.js +8 -0
- package/dist/main/InstrumentLiveRateWidget/constant.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/render.js +51 -0
- package/dist/main/InstrumentLiveRateWidget/render.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/types.js +20 -0
- package/dist/main/InstrumentLiveRateWidget/types.js.map +1 -0
- package/dist/main/InstrumentLiveRateWidget/utils.js +43 -0
- package/dist/main/InstrumentLiveRateWidget/utils.js.map +1 -0
- package/dist/main/gql/getInstrumentsChart.js +16 -0
- package/dist/main/gql/getInstrumentsChart.js.map +1 -0
- package/dist/main/gql/types/fragment-masking.js +23 -0
- package/dist/main/gql/types/fragment-masking.js.map +1 -0
- package/dist/main/gql/types/gql.js +17 -0
- package/dist/main/gql/types/gql.js.map +1 -0
- package/dist/main/gql/types/graphql.js +326 -0
- package/dist/main/gql/types/graphql.js.map +1 -0
- package/dist/main/gql/types/index.js +28 -0
- package/dist/main/gql/types/index.js.map +1 -0
- package/dist/main/gql/validateInstruments.js +16 -0
- package/dist/main/gql/validateInstruments.js.map +1 -0
- package/dist/main/index.js +28 -0
- package/dist/main/index.js.map +1 -0
- package/dist/main/translations/index.js +27 -0
- package/dist/main/translations/index.js.map +1 -0
- package/dist/main/translations/sources/en.json +4 -0
- package/dist/main/translations/sources/es.json +4 -0
- package/dist/main/translations/sources/th.json +4 -0
- package/dist/main/translations/sources/zh_TW.json +4 -0
- package/dist/main/translations/translations.js +11 -0
- package/dist/main/translations/translations.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/InstrumentLiveRateWidget.js +49 -0
- package/dist/module/InstrumentLiveRateWidget/InstrumentLiveRateWidget.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/Main.js +69 -0
- package/dist/module/InstrumentLiveRateWidget/Main.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/components/InstrumentRateWithData/InstrumentRateWithData.js +74 -0
- package/dist/module/InstrumentLiveRateWidget/components/InstrumentRateWithData/InstrumentRateWithData.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/components/InstrumentRateWithData/index.js +3 -0
- package/dist/module/InstrumentLiveRateWidget/components/InstrumentRateWithData/index.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/components/InstrumentRateWithData/utils.js +18 -0
- package/dist/module/InstrumentLiveRateWidget/components/InstrumentRateWithData/utils.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/components/LineChartWithData/LineChartWithData.js +37 -0
- package/dist/module/InstrumentLiveRateWidget/components/LineChartWithData/LineChartWithData.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/components/LineChartWithData/index.js +2 -0
- package/dist/module/InstrumentLiveRateWidget/components/LineChartWithData/index.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/components/LineChartWithData/types.js +2 -0
- package/dist/module/InstrumentLiveRateWidget/components/LineChartWithData/types.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/components/index.js +2 -0
- package/dist/module/InstrumentLiveRateWidget/components/index.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/constant.js +3 -0
- package/dist/module/InstrumentLiveRateWidget/constant.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/render.js +48 -0
- package/dist/module/InstrumentLiveRateWidget/render.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/types.js +3 -0
- package/dist/module/InstrumentLiveRateWidget/types.js.map +1 -0
- package/dist/module/InstrumentLiveRateWidget/utils.js +36 -0
- package/dist/module/InstrumentLiveRateWidget/utils.js.map +1 -0
- package/dist/module/gql/getInstrumentsChart.js +10 -0
- package/dist/module/gql/getInstrumentsChart.js.map +1 -0
- package/dist/module/gql/types/fragment-masking.js +15 -0
- package/dist/module/gql/types/fragment-masking.js.map +1 -0
- package/dist/module/gql/types/gql.js +9 -0
- package/dist/module/gql/types/gql.js.map +1 -0
- package/dist/module/gql/types/graphql.js +320 -0
- package/dist/module/gql/types/graphql.js.map +1 -0
- package/dist/module/gql/types/index.js +3 -0
- package/dist/module/gql/types/index.js.map +1 -0
- package/dist/module/gql/validateInstruments.js +10 -0
- package/dist/module/gql/validateInstruments.js.map +1 -0
- package/dist/module/index.js +3 -0
- package/dist/module/index.js.map +1 -0
- package/dist/module/translations/index.js +20 -0
- package/dist/module/translations/index.js.map +1 -0
- package/dist/module/translations/sources/en.json +4 -0
- package/dist/module/translations/sources/es.json +4 -0
- package/dist/module/translations/sources/th.json +4 -0
- package/dist/module/translations/sources/zh_TW.json +4 -0
- package/dist/module/translations/translations.js +5 -0
- package/dist/module/translations/translations.js.map +1 -0
- package/dist/types/InstrumentLiveRateWidget/InstrumentLiveRateWidget.d.ts +4 -0
- package/dist/types/InstrumentLiveRateWidget/Main.d.ts +4 -0
- package/dist/types/InstrumentLiveRateWidget/components/InstrumentRateWithData/InstrumentRateWithData.d.ts +4 -0
- package/dist/types/InstrumentLiveRateWidget/components/InstrumentRateWithData/index.d.ts +2 -0
- package/dist/types/InstrumentLiveRateWidget/components/InstrumentRateWithData/utils.d.ts +3 -0
- package/dist/types/InstrumentLiveRateWidget/components/LineChartWithData/LineChartWithData.d.ts +4 -0
- package/dist/types/InstrumentLiveRateWidget/components/LineChartWithData/index.d.ts +1 -0
- package/dist/types/InstrumentLiveRateWidget/components/LineChartWithData/types.d.ts +11 -0
- package/dist/types/InstrumentLiveRateWidget/components/index.d.ts +1 -0
- package/dist/types/InstrumentLiveRateWidget/constant.d.ts +2 -0
- package/dist/types/InstrumentLiveRateWidget/render.d.ts +1 -0
- package/dist/types/InstrumentLiveRateWidget/types.d.ts +43 -0
- package/dist/types/InstrumentLiveRateWidget/utils.d.ts +12 -0
- package/dist/types/gql/getInstrumentsChart.d.ts +1 -0
- package/dist/types/gql/types/fragment-masking.d.ts +15 -0
- package/dist/types/gql/types/gql.d.ts +45 -0
- package/dist/types/gql/types/graphql.d.ts +397 -0
- package/dist/types/gql/types/index.d.ts +2 -0
- package/dist/types/gql/validateInstruments.d.ts +1 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/translations/index.d.ts +4 -0
- package/dist/types/translations/translations.d.ts +4 -0
- package/index.ts +1 -0
- package/lokalise.config.json +18 -0
- package/package.json +25 -0
- package/src/InstrumentLiveRateWidget/InstrumentLiveRateWidget.tsx +57 -0
- package/src/InstrumentLiveRateWidget/Main.tsx +82 -0
- package/src/InstrumentLiveRateWidget/components/InstrumentRateWithData/InstrumentRateWithData.tsx +92 -0
- package/src/InstrumentLiveRateWidget/components/InstrumentRateWithData/index.ts +2 -0
- package/src/InstrumentLiveRateWidget/components/InstrumentRateWithData/utils.ts +25 -0
- package/src/InstrumentLiveRateWidget/components/LineChartWithData/LineChartWithData.tsx +48 -0
- package/src/InstrumentLiveRateWidget/components/LineChartWithData/index.ts +1 -0
- package/src/InstrumentLiveRateWidget/components/LineChartWithData/types.tsx +12 -0
- package/src/InstrumentLiveRateWidget/components/index.ts +1 -0
- package/src/InstrumentLiveRateWidget/constant.ts +5 -0
- package/src/InstrumentLiveRateWidget/render.tsx +48 -0
- package/src/InstrumentLiveRateWidget/types.tsx +50 -0
- package/src/InstrumentLiveRateWidget/utils.ts +49 -0
- package/src/gql/getInstrumentsChart.ts +10 -0
- package/src/gql/types/fragment-masking.ts +66 -0
- package/src/gql/types/gql.ts +47 -0
- package/src/gql/types/graphql.ts +432 -0
- package/src/gql/types/index.ts +2 -0
- package/src/gql/validateInstruments.ts +10 -0
- package/src/index.ts +2 -0
- package/src/translations/index.ts +17 -0
- package/src/translations/sources/en.json +4 -0
- package/src/translations/sources/es.json +4 -0
- package/src/translations/sources/th.json +4 -0
- package/src/translations/sources/zh_TW.json +4 -0
- package/src/translations/translations.ts +4 -0
- package/test/LineChartWithData.test.tsx +164 -0
- package/test/Main.test.tsx +27 -0
- package/test/components/InstrumentRateWithData.test.tsx +62 -0
- package/test/components/utils.test.ts +13 -0
- package/test/mocks.ts +52 -0
- package/tsconfig.types.json +12 -0
|
@@ -0,0 +1,320 @@
|
|
|
1
|
+
export let AssetClassName = function (AssetClassName) {
|
|
2
|
+
AssetClassName["Commodities"] = "COMMODITIES";
|
|
3
|
+
AssetClassName["Cryptocurrency"] = "CRYPTOCURRENCY";
|
|
4
|
+
AssetClassName["Currency"] = "CURRENCY";
|
|
5
|
+
AssetClassName["EquityShares"] = "EQUITY_SHARES";
|
|
6
|
+
AssetClassName["Indices"] = "INDICES";
|
|
7
|
+
AssetClassName["Rates"] = "RATES";
|
|
8
|
+
return AssetClassName;
|
|
9
|
+
}({});
|
|
10
|
+
export let BookType = function (BookType) {
|
|
11
|
+
BookType["Order"] = "ORDER";
|
|
12
|
+
BookType["Position"] = "POSITION";
|
|
13
|
+
return BookType;
|
|
14
|
+
}({});
|
|
15
|
+
export let CorrelationTimeUnit = function (CorrelationTimeUnit) {
|
|
16
|
+
CorrelationTimeUnit["H1"] = "H1";
|
|
17
|
+
CorrelationTimeUnit["H4"] = "H4";
|
|
18
|
+
CorrelationTimeUnit["H24"] = "H24";
|
|
19
|
+
CorrelationTimeUnit["M1"] = "M1";
|
|
20
|
+
CorrelationTimeUnit["M3"] = "M3";
|
|
21
|
+
CorrelationTimeUnit["M6"] = "M6";
|
|
22
|
+
CorrelationTimeUnit["W1"] = "W1";
|
|
23
|
+
CorrelationTimeUnit["Y1"] = "Y1";
|
|
24
|
+
return CorrelationTimeUnit;
|
|
25
|
+
}({});
|
|
26
|
+
export let CurrencyName = function (CurrencyName) {
|
|
27
|
+
CurrencyName["Aud"] = "AUD";
|
|
28
|
+
CurrencyName["Cad"] = "CAD";
|
|
29
|
+
CurrencyName["Chf"] = "CHF";
|
|
30
|
+
CurrencyName["Eur"] = "EUR";
|
|
31
|
+
CurrencyName["Gbp"] = "GBP";
|
|
32
|
+
CurrencyName["Jpy"] = "JPY";
|
|
33
|
+
CurrencyName["Nzd"] = "NZD";
|
|
34
|
+
CurrencyName["Usd"] = "USD";
|
|
35
|
+
return CurrencyName;
|
|
36
|
+
}({});
|
|
37
|
+
export let CurrencyPowerBalanceTimeUnit = function (CurrencyPowerBalanceTimeUnit) {
|
|
38
|
+
CurrencyPowerBalanceTimeUnit["CurrentDay"] = "CURRENT_DAY";
|
|
39
|
+
CurrencyPowerBalanceTimeUnit["H4"] = "H4";
|
|
40
|
+
CurrencyPowerBalanceTimeUnit["H8"] = "H8";
|
|
41
|
+
CurrencyPowerBalanceTimeUnit["H24"] = "H24";
|
|
42
|
+
CurrencyPowerBalanceTimeUnit["M1"] = "M1";
|
|
43
|
+
CurrencyPowerBalanceTimeUnit["M3"] = "M3";
|
|
44
|
+
CurrencyPowerBalanceTimeUnit["PreviousDay"] = "PREVIOUS_DAY";
|
|
45
|
+
CurrencyPowerBalanceTimeUnit["W1"] = "W1";
|
|
46
|
+
return CurrencyPowerBalanceTimeUnit;
|
|
47
|
+
}({});
|
|
48
|
+
export let DataSource = function (DataSource) {
|
|
49
|
+
DataSource["Ny4"] = "NY4";
|
|
50
|
+
DataSource["Ty3"] = "TY3";
|
|
51
|
+
return DataSource;
|
|
52
|
+
}({});
|
|
53
|
+
export let Division = function (Division) {
|
|
54
|
+
Division["Oap"] = "OAP";
|
|
55
|
+
Division["Oau"] = "OAU";
|
|
56
|
+
Division["Oc"] = "OC";
|
|
57
|
+
Division["Ocan"] = "OCAN";
|
|
58
|
+
Division["Oel"] = "OEL";
|
|
59
|
+
Division["Ogm"] = "OGM";
|
|
60
|
+
Division["Oj"] = "OJ";
|
|
61
|
+
Division["Opt"] = "OPT";
|
|
62
|
+
Division["Otms"] = "OTMS";
|
|
63
|
+
return Division;
|
|
64
|
+
}({});
|
|
65
|
+
export let Region = function (Region) {
|
|
66
|
+
Region["Amer"] = "AMER";
|
|
67
|
+
Region["Apac"] = "APAC";
|
|
68
|
+
Region["Emea"] = "EMEA";
|
|
69
|
+
return Region;
|
|
70
|
+
}({});
|
|
71
|
+
export let Sort = function (Sort) {
|
|
72
|
+
Sort["Bearish"] = "BEARISH";
|
|
73
|
+
Sort["Bullish"] = "BULLISH";
|
|
74
|
+
return Sort;
|
|
75
|
+
}({});
|
|
76
|
+
export let TopicalSort = function (TopicalSort) {
|
|
77
|
+
TopicalSort["Bearish"] = "BEARISH";
|
|
78
|
+
TopicalSort["Bullish"] = "BULLISH";
|
|
79
|
+
TopicalSort["Hot"] = "HOT";
|
|
80
|
+
TopicalSort["Popular"] = "POPULAR";
|
|
81
|
+
TopicalSort["Volatile"] = "VOLATILE";
|
|
82
|
+
return TopicalSort;
|
|
83
|
+
}({});
|
|
84
|
+
export let ValueAtRiskBars = function (ValueAtRiskBars) {
|
|
85
|
+
ValueAtRiskBars["C100"] = "C100";
|
|
86
|
+
ValueAtRiskBars["C200"] = "C200";
|
|
87
|
+
ValueAtRiskBars["C300"] = "C300";
|
|
88
|
+
return ValueAtRiskBars;
|
|
89
|
+
}({});
|
|
90
|
+
export let ValueAtRiskDuration = function (ValueAtRiskDuration) {
|
|
91
|
+
ValueAtRiskDuration["C1"] = "C1";
|
|
92
|
+
ValueAtRiskDuration["C2"] = "C2";
|
|
93
|
+
ValueAtRiskDuration["C3"] = "C3";
|
|
94
|
+
ValueAtRiskDuration["C4"] = "C4";
|
|
95
|
+
ValueAtRiskDuration["C5"] = "C5";
|
|
96
|
+
ValueAtRiskDuration["C10"] = "C10";
|
|
97
|
+
return ValueAtRiskDuration;
|
|
98
|
+
}({});
|
|
99
|
+
export let VolatilityChartTimeSpan = function (VolatilityChartTimeSpan) {
|
|
100
|
+
VolatilityChartTimeSpan["D5"] = "D5";
|
|
101
|
+
VolatilityChartTimeSpan["D10"] = "D10";
|
|
102
|
+
VolatilityChartTimeSpan["M1"] = "M1";
|
|
103
|
+
VolatilityChartTimeSpan["M3"] = "M3";
|
|
104
|
+
VolatilityChartTimeSpan["W5"] = "W5";
|
|
105
|
+
VolatilityChartTimeSpan["W10"] = "W10";
|
|
106
|
+
return VolatilityChartTimeSpan;
|
|
107
|
+
}({});
|
|
108
|
+
export let VolatilityChartTimeUnit = function (VolatilityChartTimeUnit) {
|
|
109
|
+
VolatilityChartTimeUnit["D"] = "D";
|
|
110
|
+
VolatilityChartTimeUnit["H"] = "H";
|
|
111
|
+
VolatilityChartTimeUnit["W"] = "W";
|
|
112
|
+
return VolatilityChartTimeUnit;
|
|
113
|
+
}({});
|
|
114
|
+
export const GetInstrumentsChartDocument = {
|
|
115
|
+
"kind": "Document",
|
|
116
|
+
"definitions": [{
|
|
117
|
+
"kind": "OperationDefinition",
|
|
118
|
+
"operation": "query",
|
|
119
|
+
"name": {
|
|
120
|
+
"kind": "Name",
|
|
121
|
+
"value": "GetInstrumentsChart"
|
|
122
|
+
},
|
|
123
|
+
"variableDefinitions": [{
|
|
124
|
+
"kind": "VariableDefinition",
|
|
125
|
+
"variable": {
|
|
126
|
+
"kind": "Variable",
|
|
127
|
+
"name": {
|
|
128
|
+
"kind": "Name",
|
|
129
|
+
"value": "instruments"
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
"type": {
|
|
133
|
+
"kind": "ListType",
|
|
134
|
+
"type": {
|
|
135
|
+
"kind": "NonNullType",
|
|
136
|
+
"type": {
|
|
137
|
+
"kind": "NamedType",
|
|
138
|
+
"name": {
|
|
139
|
+
"kind": "Name",
|
|
140
|
+
"value": "String"
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
}, {
|
|
146
|
+
"kind": "VariableDefinition",
|
|
147
|
+
"variable": {
|
|
148
|
+
"kind": "Variable",
|
|
149
|
+
"name": {
|
|
150
|
+
"kind": "Name",
|
|
151
|
+
"value": "division"
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"type": {
|
|
155
|
+
"kind": "NamedType",
|
|
156
|
+
"name": {
|
|
157
|
+
"kind": "Name",
|
|
158
|
+
"value": "Division"
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
}],
|
|
162
|
+
"selectionSet": {
|
|
163
|
+
"kind": "SelectionSet",
|
|
164
|
+
"selections": [{
|
|
165
|
+
"kind": "Field",
|
|
166
|
+
"name": {
|
|
167
|
+
"kind": "Name",
|
|
168
|
+
"value": "topicalInstrumentsCharts"
|
|
169
|
+
},
|
|
170
|
+
"arguments": [{
|
|
171
|
+
"kind": "Argument",
|
|
172
|
+
"name": {
|
|
173
|
+
"kind": "Name",
|
|
174
|
+
"value": "instruments"
|
|
175
|
+
},
|
|
176
|
+
"value": {
|
|
177
|
+
"kind": "Variable",
|
|
178
|
+
"name": {
|
|
179
|
+
"kind": "Name",
|
|
180
|
+
"value": "instruments"
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
}, {
|
|
184
|
+
"kind": "Argument",
|
|
185
|
+
"name": {
|
|
186
|
+
"kind": "Name",
|
|
187
|
+
"value": "division"
|
|
188
|
+
},
|
|
189
|
+
"value": {
|
|
190
|
+
"kind": "Variable",
|
|
191
|
+
"name": {
|
|
192
|
+
"kind": "Name",
|
|
193
|
+
"value": "division"
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
}],
|
|
197
|
+
"selectionSet": {
|
|
198
|
+
"kind": "SelectionSet",
|
|
199
|
+
"selections": [{
|
|
200
|
+
"kind": "Field",
|
|
201
|
+
"name": {
|
|
202
|
+
"kind": "Name",
|
|
203
|
+
"value": "name"
|
|
204
|
+
}
|
|
205
|
+
}, {
|
|
206
|
+
"kind": "Field",
|
|
207
|
+
"name": {
|
|
208
|
+
"kind": "Name",
|
|
209
|
+
"value": "chart"
|
|
210
|
+
}
|
|
211
|
+
}]
|
|
212
|
+
}
|
|
213
|
+
}]
|
|
214
|
+
}
|
|
215
|
+
}]
|
|
216
|
+
};
|
|
217
|
+
export const ValidateInstrumentsDocument = {
|
|
218
|
+
"kind": "Document",
|
|
219
|
+
"definitions": [{
|
|
220
|
+
"kind": "OperationDefinition",
|
|
221
|
+
"operation": "query",
|
|
222
|
+
"name": {
|
|
223
|
+
"kind": "Name",
|
|
224
|
+
"value": "validateInstruments"
|
|
225
|
+
},
|
|
226
|
+
"variableDefinitions": [{
|
|
227
|
+
"kind": "VariableDefinition",
|
|
228
|
+
"variable": {
|
|
229
|
+
"kind": "Variable",
|
|
230
|
+
"name": {
|
|
231
|
+
"kind": "Name",
|
|
232
|
+
"value": "instruments"
|
|
233
|
+
}
|
|
234
|
+
},
|
|
235
|
+
"type": {
|
|
236
|
+
"kind": "NonNullType",
|
|
237
|
+
"type": {
|
|
238
|
+
"kind": "ListType",
|
|
239
|
+
"type": {
|
|
240
|
+
"kind": "NamedType",
|
|
241
|
+
"name": {
|
|
242
|
+
"kind": "Name",
|
|
243
|
+
"value": "String"
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
}, {
|
|
249
|
+
"kind": "VariableDefinition",
|
|
250
|
+
"variable": {
|
|
251
|
+
"kind": "Variable",
|
|
252
|
+
"name": {
|
|
253
|
+
"kind": "Name",
|
|
254
|
+
"value": "division"
|
|
255
|
+
}
|
|
256
|
+
},
|
|
257
|
+
"type": {
|
|
258
|
+
"kind": "NamedType",
|
|
259
|
+
"name": {
|
|
260
|
+
"kind": "Name",
|
|
261
|
+
"value": "Division"
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
}],
|
|
265
|
+
"selectionSet": {
|
|
266
|
+
"kind": "SelectionSet",
|
|
267
|
+
"selections": [{
|
|
268
|
+
"kind": "Field",
|
|
269
|
+
"name": {
|
|
270
|
+
"kind": "Name",
|
|
271
|
+
"value": "mapInstrumentNames"
|
|
272
|
+
},
|
|
273
|
+
"arguments": [{
|
|
274
|
+
"kind": "Argument",
|
|
275
|
+
"name": {
|
|
276
|
+
"kind": "Name",
|
|
277
|
+
"value": "instruments"
|
|
278
|
+
},
|
|
279
|
+
"value": {
|
|
280
|
+
"kind": "Variable",
|
|
281
|
+
"name": {
|
|
282
|
+
"kind": "Name",
|
|
283
|
+
"value": "instruments"
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
}, {
|
|
287
|
+
"kind": "Argument",
|
|
288
|
+
"name": {
|
|
289
|
+
"kind": "Name",
|
|
290
|
+
"value": "division"
|
|
291
|
+
},
|
|
292
|
+
"value": {
|
|
293
|
+
"kind": "Variable",
|
|
294
|
+
"name": {
|
|
295
|
+
"kind": "Name",
|
|
296
|
+
"value": "division"
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
}],
|
|
300
|
+
"selectionSet": {
|
|
301
|
+
"kind": "SelectionSet",
|
|
302
|
+
"selections": [{
|
|
303
|
+
"kind": "Field",
|
|
304
|
+
"name": {
|
|
305
|
+
"kind": "Name",
|
|
306
|
+
"value": "name"
|
|
307
|
+
}
|
|
308
|
+
}, {
|
|
309
|
+
"kind": "Field",
|
|
310
|
+
"name": {
|
|
311
|
+
"kind": "Name",
|
|
312
|
+
"value": "displayName"
|
|
313
|
+
}
|
|
314
|
+
}]
|
|
315
|
+
}
|
|
316
|
+
}]
|
|
317
|
+
}
|
|
318
|
+
}]
|
|
319
|
+
};
|
|
320
|
+
//# sourceMappingURL=graphql.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphql.js","names":["AssetClassName","BookType","CorrelationTimeUnit","CurrencyName","CurrencyPowerBalanceTimeUnit","DataSource","Division","Region","Sort","TopicalSort","ValueAtRiskBars","ValueAtRiskDuration","VolatilityChartTimeSpan","VolatilityChartTimeUnit","GetInstrumentsChartDocument","ValidateInstrumentsDocument"],"sources":["../../../../src/gql/types/graphql.ts"],"sourcesContent":["/* eslint-disable */\nimport { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/core';\nexport type Maybe<T> = T | null;\nexport type InputMaybe<T> = Maybe<T>;\nexport type Exact<T extends { [key: string]: unknown }> = { [K in keyof T]: T[K] };\nexport type MakeOptional<T, K extends keyof T> = Omit<T, K> & { [SubKey in K]?: Maybe<T[SubKey]> };\nexport type MakeMaybe<T, K extends keyof T> = Omit<T, K> & { [SubKey in K]: Maybe<T[SubKey]> };\nexport type MakeEmpty<T extends { [key: string]: unknown }, K extends keyof T> = { [_ in K]?: never };\nexport type Incremental<T> = T | { [P in keyof T]?: P extends ' $fragmentName' | '__typename' ? T[P] : never };\n/** All built-in and custom scalars, mapped to their actual values */\nexport type Scalars = {\n ID: { input: string; output: string; }\n String: { input: string; output: string; }\n Boolean: { input: boolean; output: boolean; }\n Int: { input: number; output: number; }\n Float: { input: number; output: number; }\n};\n\nexport type AssetClass = {\n __typename?: 'AssetClass';\n instruments: Array<Instrument>;\n name: Scalars['String']['output'];\n};\n\nexport enum AssetClassName {\n Commodities = 'COMMODITIES',\n Cryptocurrency = 'CRYPTOCURRENCY',\n Currency = 'CURRENCY',\n EquityShares = 'EQUITY_SHARES',\n Indices = 'INDICES',\n Rates = 'RATES'\n}\n\nexport enum BookType {\n Order = 'ORDER',\n Position = 'POSITION'\n}\n\nexport type CorrelationHeatmap = {\n __typename?: 'CorrelationHeatmap';\n baseInstrument: Instrument;\n heatmap: Array<Heatmap>;\n};\n\nexport type CorrelationMatrix = {\n __typename?: 'CorrelationMatrix';\n baseTimeUnit: CorrelationTimeUnit;\n matrix: Array<Matrix>;\n};\n\nexport enum CorrelationTimeUnit {\n H1 = 'H1',\n H4 = 'H4',\n H24 = 'H24',\n M1 = 'M1',\n M3 = 'M3',\n M6 = 'M6',\n W1 = 'W1',\n Y1 = 'Y1'\n}\n\nexport enum CurrencyName {\n Aud = 'AUD',\n Cad = 'CAD',\n Chf = 'CHF',\n Eur = 'EUR',\n Gbp = 'GBP',\n Jpy = 'JPY',\n Nzd = 'NZD',\n Usd = 'USD'\n}\n\nexport type CurrencyPower = {\n __typename?: 'CurrencyPower';\n /** UTC Timestamp */\n point: Scalars['String']['output'];\n price: Scalars['Float']['output'];\n};\n\nexport type CurrencyPowerBalance = {\n __typename?: 'CurrencyPowerBalance';\n currency: CurrencyName;\n power: Array<CurrencyPower>;\n updatedAt: Scalars['String']['output'];\n};\n\nexport enum CurrencyPowerBalanceTimeUnit {\n CurrentDay = 'CURRENT_DAY',\n H4 = 'H4',\n H8 = 'H8',\n H24 = 'H24',\n M1 = 'M1',\n M3 = 'M3',\n PreviousDay = 'PREVIOUS_DAY',\n W1 = 'W1'\n}\n\nexport type CurrencyStrength = {\n __typename?: 'CurrencyStrength';\n currency: CurrencyName;\n strengthRelation?: Maybe<Array<StrengthRelation>>;\n updatedAt: Scalars['String']['output'];\n};\n\nexport enum DataSource {\n Ny4 = 'NY4',\n Ty3 = 'TY3'\n}\n\nexport enum Division {\n Oap = 'OAP',\n Oau = 'OAU',\n Oc = 'OC',\n Ocan = 'OCAN',\n Oel = 'OEL',\n Ogm = 'OGM',\n Oj = 'OJ',\n Opt = 'OPT',\n Otms = 'OTMS'\n}\n\nexport type Heatmap = {\n __typename?: 'Heatmap';\n instrument: Instrument;\n timeCorrelation: Array<TimeCorrelation>;\n};\n\nexport type Instrument = {\n __typename?: 'Instrument';\n displayName: Scalars['String']['output'];\n name: Scalars['String']['output'];\n};\n\nexport type InstrumentCorrelation = {\n __typename?: 'InstrumentCorrelation';\n instrument: Instrument;\n value?: Maybe<Scalars['Float']['output']>;\n};\n\nexport type Matrix = {\n __typename?: 'Matrix';\n instrument: Instrument;\n instrumentCorrelation: Array<InstrumentCorrelation>;\n};\n\nexport type OrderPositionBucket = {\n __typename?: 'OrderPositionBucket';\n longCountPercent: Scalars['Float']['output'];\n price: Scalars['Float']['output'];\n shortCountPercent: Scalars['Float']['output'];\n};\n\nexport type OrderPositionData = {\n __typename?: 'OrderPositionData';\n bucketWidth: Scalars['Float']['output'];\n buckets: Array<Maybe<OrderPositionBucket>>;\n dataSource?: Maybe<Scalars['String']['output']>;\n instrument: Scalars['String']['output'];\n price?: Maybe<Scalars['Float']['output']>;\n region?: Maybe<Scalars['String']['output']>;\n time: Scalars['String']['output'];\n unixTime: Scalars['Int']['output'];\n};\n\nexport type Query = {\n __typename?: 'Query';\n assetClasses?: Maybe<Array<Maybe<AssetClass>>>;\n correlationHeatmap: CorrelationHeatmap;\n correlationMatrix: CorrelationMatrix;\n currencyPowerBalance?: Maybe<Array<CurrencyPowerBalance>>;\n currencyStrength?: Maybe<Array<CurrencyStrength>>;\n isAllowedPartner?: Maybe<Scalars['Boolean']['output']>;\n mapInstrumentNames?: Maybe<Array<Maybe<Instrument>>>;\n orderPositionBooks: Array<Maybe<OrderPositionData>>;\n sentiment?: Maybe<Array<SentimentInstrument>>;\n sentimentList?: Maybe<Array<SentimentInstrument>>;\n topicalInstruments?: Maybe<Array<TopicalInstrument>>;\n topicalInstrumentsCharts?: Maybe<Array<TopicalInstrumentChart>>;\n topicalInstrumentsTotalCount: Scalars['Int']['output'];\n valueAtRiskAssetClasses?: Maybe<Array<AssetClass>>;\n valueAtRiskChart?: Maybe<ValueAtRiskChart>;\n volatilityChart?: Maybe<Array<Maybe<VolatilityChart>>>;\n volatilityChartAssetClasses?: Maybe<Array<AssetClass>>;\n};\n\n\nexport type QueryAssetClassesArgs = {\n division: Division;\n};\n\n\nexport type QueryCorrelationHeatmapArgs = {\n division: Division;\n instruments?: InputMaybe<Array<InputMaybe<Scalars['String']['input']>>>;\n timeSpans?: InputMaybe<Array<InputMaybe<CorrelationTimeUnit>>>;\n};\n\n\nexport type QueryCorrelationMatrixArgs = {\n division: Division;\n instruments?: InputMaybe<Array<InputMaybe<Scalars['String']['input']>>>;\n};\n\n\nexport type QueryCurrencyPowerBalanceArgs = {\n timeUnit: CurrencyPowerBalanceTimeUnit;\n};\n\n\nexport type QueryIsAllowedPartnerArgs = {\n url: Scalars['String']['input'];\n};\n\n\nexport type QueryMapInstrumentNamesArgs = {\n division?: InputMaybe<Division>;\n instruments: Array<InputMaybe<Scalars['String']['input']>>;\n};\n\n\nexport type QueryOrderPositionBooksArgs = {\n bookType: BookType;\n dataSource?: InputMaybe<DataSource>;\n instrument: Scalars['String']['input'];\n recentHours?: InputMaybe<Scalars['Int']['input']>;\n region?: InputMaybe<Region>;\n};\n\n\nexport type QuerySentimentArgs = {\n division?: InputMaybe<Division>;\n name: Scalars['String']['input'];\n};\n\n\nexport type QuerySentimentListArgs = {\n division?: InputMaybe<Division>;\n sort?: InputMaybe<Sort>;\n};\n\n\nexport type QueryTopicalInstrumentsArgs = {\n assetClass?: InputMaybe<AssetClassName>;\n count?: InputMaybe<Scalars['Int']['input']>;\n division?: InputMaybe<Division>;\n offset?: InputMaybe<Scalars['Int']['input']>;\n sort: TopicalSort;\n};\n\n\nexport type QueryTopicalInstrumentsChartsArgs = {\n division?: InputMaybe<Division>;\n instruments?: InputMaybe<Array<Scalars['String']['input']>>;\n};\n\n\nexport type QueryTopicalInstrumentsTotalCountArgs = {\n assetClass?: InputMaybe<AssetClassName>;\n division?: InputMaybe<Division>;\n sort: TopicalSort;\n};\n\n\nexport type QueryValueAtRiskAssetClassesArgs = {\n division?: InputMaybe<Division>;\n};\n\n\nexport type QueryValueAtRiskChartArgs = {\n bars: ValueAtRiskBars;\n division?: InputMaybe<Division>;\n duration: ValueAtRiskDuration;\n instrument: Scalars['String']['input'];\n};\n\n\nexport type QueryVolatilityChartArgs = {\n division?: InputMaybe<Division>;\n instrument: Scalars['String']['input'];\n timeSpan: VolatilityChartTimeSpan;\n timeUnit: VolatilityChartTimeUnit;\n};\n\n\nexport type QueryVolatilityChartAssetClassesArgs = {\n division?: InputMaybe<Division>;\n};\n\nexport enum Region {\n Amer = 'AMER',\n Apac = 'APAC',\n Emea = 'EMEA'\n}\n\nexport type Sentiment = {\n __typename?: 'Sentiment';\n longPercent: Scalars['Float']['output'];\n shortPercent: Scalars['Float']['output'];\n};\n\nexport type SentimentInstrument = {\n __typename?: 'SentimentInstrument';\n displayName: Scalars['String']['output'];\n name: Scalars['String']['output'];\n sentiment: Sentiment;\n updatedAt: Scalars['String']['output'];\n};\n\nexport enum Sort {\n Bearish = 'BEARISH',\n Bullish = 'BULLISH'\n}\n\nexport type StrengthRelation = {\n __typename?: 'StrengthRelation';\n currency: CurrencyName;\n percentage: Scalars['Float']['output'];\n};\n\nexport type TimeCorrelation = {\n __typename?: 'TimeCorrelation';\n timeUnit: CorrelationTimeUnit;\n value?: Maybe<Scalars['Float']['output']>;\n};\n\nexport type TopicalInstrument = {\n __typename?: 'TopicalInstrument';\n assetClass?: Maybe<AssetClassName>;\n displayName: Scalars['String']['output'];\n name: Scalars['String']['output'];\n sentiment: Sentiment;\n updatedAt: Scalars['String']['output'];\n};\n\nexport type TopicalInstrumentChart = {\n __typename?: 'TopicalInstrumentChart';\n chart?: Maybe<Array<Scalars['Float']['output']>>;\n name: Scalars['String']['output'];\n};\n\nexport enum TopicalSort {\n Bearish = 'BEARISH',\n Bullish = 'BULLISH',\n Hot = 'HOT',\n Popular = 'POPULAR',\n Volatile = 'VOLATILE'\n}\n\nexport enum ValueAtRiskBars {\n C100 = 'C100',\n C200 = 'C200',\n C300 = 'C300'\n}\n\nexport type ValueAtRiskChart = {\n __typename?: 'ValueAtRiskChart';\n down: ValueAtRiskChartData;\n up: ValueAtRiskChartData;\n};\n\nexport type ValueAtRiskChartData = {\n __typename?: 'ValueAtRiskChartData';\n average: Scalars['Float']['output'];\n max: Scalars['Float']['output'];\n median: Scalars['Float']['output'];\n points?: Maybe<Array<ValueAtRiskChartPoint>>;\n threshold: Scalars['Float']['output'];\n};\n\nexport type ValueAtRiskChartPoint = {\n __typename?: 'ValueAtRiskChartPoint';\n percent: Scalars['Float']['output'];\n pips: Scalars['Float']['output'];\n};\n\nexport enum ValueAtRiskDuration {\n C1 = 'C1',\n C2 = 'C2',\n C3 = 'C3',\n C4 = 'C4',\n C5 = 'C5',\n C10 = 'C10'\n}\n\nexport type VolatilityChart = {\n __typename?: 'VolatilityChart';\n pips: Scalars['Float']['output'];\n /** Time point - hour in format hh:mm, Date in UTC, Week in format 'Mo' */\n point: Scalars['String']['output'];\n updatedAt: Scalars['String']['output'];\n};\n\nexport enum VolatilityChartTimeSpan {\n /** Valid for: H */\n D5 = 'D5',\n /** Valid for: H */\n D10 = 'D10',\n /** Valid for: D */\n M1 = 'M1',\n /** Valid for: D */\n M3 = 'M3',\n /** Valid for: W */\n W5 = 'W5',\n /** Valid for: W */\n W10 = 'W10'\n}\n\nexport enum VolatilityChartTimeUnit {\n D = 'D',\n H = 'H',\n W = 'W'\n}\n\nexport type GetInstrumentsChartQueryVariables = Exact<{\n instruments?: InputMaybe<Array<Scalars['String']['input']> | Scalars['String']['input']>;\n division?: InputMaybe<Division>;\n}>;\n\n\nexport type GetInstrumentsChartQuery = { __typename?: 'Query', topicalInstrumentsCharts?: Array<{ __typename?: 'TopicalInstrumentChart', name: string, chart?: Array<number> | null }> | null };\n\nexport type ValidateInstrumentsQueryVariables = Exact<{\n instruments: Array<InputMaybe<Scalars['String']['input']>> | InputMaybe<Scalars['String']['input']>;\n division?: InputMaybe<Division>;\n}>;\n\n\nexport type ValidateInstrumentsQuery = { __typename?: 'Query', mapInstrumentNames?: Array<{ __typename?: 'Instrument', name: string, displayName: string } | null> | null };\n\n\nexport const GetInstrumentsChartDocument = {\"kind\":\"Document\",\"definitions\":[{\"kind\":\"OperationDefinition\",\"operation\":\"query\",\"name\":{\"kind\":\"Name\",\"value\":\"GetInstrumentsChart\"},\"variableDefinitions\":[{\"kind\":\"VariableDefinition\",\"variable\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"instruments\"}},\"type\":{\"kind\":\"ListType\",\"type\":{\"kind\":\"NonNullType\",\"type\":{\"kind\":\"NamedType\",\"name\":{\"kind\":\"Name\",\"value\":\"String\"}}}}},{\"kind\":\"VariableDefinition\",\"variable\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"division\"}},\"type\":{\"kind\":\"NamedType\",\"name\":{\"kind\":\"Name\",\"value\":\"Division\"}}}],\"selectionSet\":{\"kind\":\"SelectionSet\",\"selections\":[{\"kind\":\"Field\",\"name\":{\"kind\":\"Name\",\"value\":\"topicalInstrumentsCharts\"},\"arguments\":[{\"kind\":\"Argument\",\"name\":{\"kind\":\"Name\",\"value\":\"instruments\"},\"value\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"instruments\"}}},{\"kind\":\"Argument\",\"name\":{\"kind\":\"Name\",\"value\":\"division\"},\"value\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"division\"}}}],\"selectionSet\":{\"kind\":\"SelectionSet\",\"selections\":[{\"kind\":\"Field\",\"name\":{\"kind\":\"Name\",\"value\":\"name\"}},{\"kind\":\"Field\",\"name\":{\"kind\":\"Name\",\"value\":\"chart\"}}]}}]}}]} as unknown as DocumentNode<GetInstrumentsChartQuery, GetInstrumentsChartQueryVariables>;\nexport const ValidateInstrumentsDocument = {\"kind\":\"Document\",\"definitions\":[{\"kind\":\"OperationDefinition\",\"operation\":\"query\",\"name\":{\"kind\":\"Name\",\"value\":\"validateInstruments\"},\"variableDefinitions\":[{\"kind\":\"VariableDefinition\",\"variable\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"instruments\"}},\"type\":{\"kind\":\"NonNullType\",\"type\":{\"kind\":\"ListType\",\"type\":{\"kind\":\"NamedType\",\"name\":{\"kind\":\"Name\",\"value\":\"String\"}}}}},{\"kind\":\"VariableDefinition\",\"variable\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"division\"}},\"type\":{\"kind\":\"NamedType\",\"name\":{\"kind\":\"Name\",\"value\":\"Division\"}}}],\"selectionSet\":{\"kind\":\"SelectionSet\",\"selections\":[{\"kind\":\"Field\",\"name\":{\"kind\":\"Name\",\"value\":\"mapInstrumentNames\"},\"arguments\":[{\"kind\":\"Argument\",\"name\":{\"kind\":\"Name\",\"value\":\"instruments\"},\"value\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"instruments\"}}},{\"kind\":\"Argument\",\"name\":{\"kind\":\"Name\",\"value\":\"division\"},\"value\":{\"kind\":\"Variable\",\"name\":{\"kind\":\"Name\",\"value\":\"division\"}}}],\"selectionSet\":{\"kind\":\"SelectionSet\",\"selections\":[{\"kind\":\"Field\",\"name\":{\"kind\":\"Name\",\"value\":\"name\"}},{\"kind\":\"Field\",\"name\":{\"kind\":\"Name\",\"value\":\"displayName\"}}]}}]}}]} as unknown as DocumentNode<ValidateInstrumentsQuery, ValidateInstrumentsQueryVariables>;"],"mappings":"AAwBA,WAAYA,cAAc,aAAdA,cAA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AAC;UAAC,OAAO,EAAC;YAAC,MAAM,EAAC,UAAU;YAAC,MAAM,EAAC;cAAC,MAAM,EAAC,MAAM;cAAC,OAAO,EAAC;YAAa;UAAC;QAAC,CAAC,EAAC;UAAC,MAAM,EAAC,UAAU;UAAC,MAAM,EAAC;YAAC,MAAM,EAAC,MAAM;YAAC,OAAO,EAAC;UAAU,CAAC;UAAC,OAAO,EAAC;YAAC,MAAM,EAAC,UAAU;YAAC,MAAM,EAAC;cAAC,MAAM,EAAC,MAAM;cAAC,OAAO,EAAC;YAAU;UAAC;QAAC,CAAC,CAAC;QAAC,cAAc,EAAC;UAAC,MAAM,EAAC,cAAc;UAAC,YAAY,EAAC,CAAC;YAAC,MAAM,EAAC,OAAO;YAAC,MAAM,EAAC;cAAC,MAAM,EAAC,MAAM;cAAC,OAAO,EAAC;YAAM;UAAC,CAAC,EAAC;YAAC,MAAM,EAAC,OAAO;YAAC,MAAM,EAAC;cAAC,MAAM,EAAC,MAAM;cAAC,OAAO,EAAC;YAAa;UAAC,CAAC;QAAC;MAAC,CAAC;IAAC;EAAC,CAAC;AAAC,CAAyF","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../../../src/gql/types/index.ts"],"sourcesContent":["export * from \"./fragment-masking\";\nexport * from \"./gql\";"],"mappings":"AAAA,cAAc,oBAAoB;AAClC,cAAc,OAAO","ignoreList":[]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { gql } from '@apollo/client';
|
|
2
|
+
export const validateInstruments = gql`
|
|
3
|
+
query validateInstruments($instruments: [String]!, $division: Division) {
|
|
4
|
+
mapInstrumentNames(instruments: $instruments, division: $division) {
|
|
5
|
+
name
|
|
6
|
+
displayName
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
`;
|
|
10
|
+
//# sourceMappingURL=validateInstruments.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validateInstruments.js","names":["gql","validateInstruments"],"sources":["../../../src/gql/validateInstruments.ts"],"sourcesContent":["import { gql } from '@apollo/client';\n\nexport const validateInstruments = gql`\n query validateInstruments($instruments: [String]!, $division: Division) {\n mapInstrumentNames(instruments: $instruments, division: $division) {\n name\n displayName\n }\n }\n`;\n"],"mappings":"AAAA,SAASA,GAAG,QAAQ,gBAAgB;AAEpC,OAAO,MAAMC,mBAAmB,GAAGD,GAAG;AACtC;AACA;AACA;AACA;AACA;AACA;AACA,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../src/index.ts"],"sourcesContent":["export * from './InstrumentLiveRateWidget/types';\nexport * from './InstrumentLiveRateWidget/InstrumentLiveRateWidget';\n"],"mappings":"AAAA,cAAc,kCAAkC;AAChD,cAAc,qDAAqD","ignoreList":[]}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Locale } from '@oanda/mono-i18n';
|
|
2
|
+
import en from './sources/en.json';
|
|
3
|
+
import zhTW from './sources/zh_TW.json';
|
|
4
|
+
import es from './sources/es.json';
|
|
5
|
+
import th from './sources/th.json';
|
|
6
|
+
export const translations = {
|
|
7
|
+
[Locale.en]: {
|
|
8
|
+
translation: en
|
|
9
|
+
},
|
|
10
|
+
[Locale.zhTW]: {
|
|
11
|
+
translation: zhTW
|
|
12
|
+
},
|
|
13
|
+
[Locale.es]: {
|
|
14
|
+
translation: es
|
|
15
|
+
},
|
|
16
|
+
[Locale.th]: {
|
|
17
|
+
translation: th
|
|
18
|
+
}
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["Locale","en","zhTW","es","th","translations","translation"],"sources":["../../../src/translations/index.ts"],"sourcesContent":["import { Locale, Translations } from '@oanda/mono-i18n';\n\nimport en from './sources/en.json';\nimport zhTW from './sources/zh_TW.json';\nimport es from './sources/es.json';\nimport th from './sources/th.json';\n\nimport { defaultTranslations } from './translations';\n\nexport type TranslationKey = keyof typeof defaultTranslations;\n\nexport const translations: Translations = {\n [Locale.en]: { translation: en },\n [Locale.zhTW]: { translation: zhTW },\n [Locale.es]: { translation: es },\n [Locale.th]: { translation: th },\n};\n"],"mappings":"AAAA,SAASA,MAAM,QAAsB,kBAAkB;AAEvD,OAAOC,EAAE,MAAM,mBAAmB;AAClC,OAAOC,IAAI,MAAM,sBAAsB;AACvC,OAAOC,EAAE,MAAM,mBAAmB;AAClC,OAAOC,EAAE,MAAM,mBAAmB;AAMlC,OAAO,MAAMC,YAA0B,GAAG;EACxC,CAACL,MAAM,CAACC,EAAE,GAAG;IAAEK,WAAW,EAAEL;EAAG,CAAC;EAChC,CAACD,MAAM,CAACE,IAAI,GAAG;IAAEI,WAAW,EAAEJ;EAAK,CAAC;EACpC,CAACF,MAAM,CAACG,EAAE,GAAG;IAAEG,WAAW,EAAEH;EAAG,CAAC;EAChC,CAACH,MAAM,CAACI,EAAE,GAAG;IAAEE,WAAW,EAAEF;EAAG;AACjC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"translations.js","names":["defaultTranslations","data_unavailable","pagination_entries_range"],"sources":["../../../src/translations/translations.ts"],"sourcesContent":["export const defaultTranslations = {\n data_unavailable: 'Data unavailable',\n pagination_entries_range: '{{firstItemOnPage}}-{{lastItemOnPage}} of {{itemCount}} entries',\n};\n"],"mappings":"AAAA,OAAO,MAAMA,mBAAmB,GAAG;EACjCC,gBAAgB,EAAE,kBAAkB;EACpCC,wBAAwB,EAAE;AAC5B,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { InstrumentLiveRateConfig } from './types';
|
|
3
|
+
declare const InstrumentLiveRateWidget: ({ graphqlUrl, liveRatesUrl, instrument, division, locale, theme, isParamError, removePadding, size, }: InstrumentLiveRateConfig) => React.JSX.Element;
|
|
4
|
+
export { InstrumentLiveRateWidget };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './LineChartWithData';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LineChartSize } from '@oanda/labs-widget-common';
|
|
2
|
+
import { DataRecord } from '../../types';
|
|
3
|
+
import { Division } from '../../../gql/types/graphql';
|
|
4
|
+
export interface LineChartWithDataProps {
|
|
5
|
+
padding?: number;
|
|
6
|
+
record: DataRecord;
|
|
7
|
+
size?: LineChartSize;
|
|
8
|
+
isLoading: boolean;
|
|
9
|
+
division: Division;
|
|
10
|
+
color: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './LineChartWithData';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { Locale } from '@oanda/mono-i18n';
|
|
2
|
+
import { Theme } from '@oanda/labs-widget-common';
|
|
3
|
+
import { Division } from '../gql/types/graphql';
|
|
4
|
+
export { Locale } from '@oanda/mono-i18n';
|
|
5
|
+
export { Division } from '../gql/types/graphql';
|
|
6
|
+
export interface InstrumentLiveRateConfig {
|
|
7
|
+
graphqlUrl: string;
|
|
8
|
+
division: Division;
|
|
9
|
+
liveRatesUrl: string;
|
|
10
|
+
instrument: string;
|
|
11
|
+
locale: Locale;
|
|
12
|
+
theme?: Theme;
|
|
13
|
+
isParamError?: boolean;
|
|
14
|
+
removePadding?: boolean;
|
|
15
|
+
size?: 'compact' | 'full' | 'fullWithChart';
|
|
16
|
+
}
|
|
17
|
+
export interface MainProps {
|
|
18
|
+
instrument: string;
|
|
19
|
+
division: Division;
|
|
20
|
+
size?: 'compact' | 'full' | 'fullWithChart';
|
|
21
|
+
}
|
|
22
|
+
export interface Sentiment {
|
|
23
|
+
shortPercent: number;
|
|
24
|
+
longPercent: number;
|
|
25
|
+
}
|
|
26
|
+
export type EmptyRecord = Record<any, never>;
|
|
27
|
+
export interface DataRecord {
|
|
28
|
+
[key: string]: string | number | undefined;
|
|
29
|
+
instrument: string;
|
|
30
|
+
displayName: string;
|
|
31
|
+
buy?: number;
|
|
32
|
+
buyPriceMovement?: number;
|
|
33
|
+
dailyPercentChange?: string;
|
|
34
|
+
dailyPipsChange?: number;
|
|
35
|
+
displayPrecision?: number;
|
|
36
|
+
}
|
|
37
|
+
export interface InstrumentRateWithDataProps {
|
|
38
|
+
loading: boolean;
|
|
39
|
+
record: DataRecord;
|
|
40
|
+
target: EventTarget | null;
|
|
41
|
+
division: Division;
|
|
42
|
+
size?: 'compact' | 'full' | 'fullWithChart';
|
|
43
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { LiveRatesErrorMessage } from '@oanda/labs-widget-common';
|
|
2
|
+
import { DataRecord, EmptyRecord } from './types';
|
|
3
|
+
import { ValidateInstrumentsQuery } from '../gql/types/graphql';
|
|
4
|
+
declare const getRecords: (data: ValidateInstrumentsQuery) => {
|
|
5
|
+
instrument: string;
|
|
6
|
+
displayName: string;
|
|
7
|
+
}[] | undefined;
|
|
8
|
+
declare const useRecords: (record: DataRecord | EmptyRecord, target: EventTarget | null) => {
|
|
9
|
+
updatedRecord: DataRecord;
|
|
10
|
+
error: LiveRatesErrorMessage | null;
|
|
11
|
+
};
|
|
12
|
+
export { getRecords, useRecords, };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const getInstrumentsChart: import("@apollo/client").DocumentNode;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ResultOf, DocumentTypeDecoration, TypedDocumentNode } from '@graphql-typed-document-node/core';
|
|
2
|
+
import { Incremental } from './graphql';
|
|
3
|
+
export type FragmentType<TDocumentType extends DocumentTypeDecoration<any, any>> = TDocumentType extends DocumentTypeDecoration<infer TType, any> ? [TType] extends [{
|
|
4
|
+
' $fragmentName'?: infer TKey;
|
|
5
|
+
}] ? TKey extends string ? {
|
|
6
|
+
' $fragmentRefs'?: {
|
|
7
|
+
[key in TKey]: TType;
|
|
8
|
+
};
|
|
9
|
+
} : never : never : never;
|
|
10
|
+
export declare function useFragment<TType>(_documentNode: DocumentTypeDecoration<TType, any>, fragmentType: FragmentType<DocumentTypeDecoration<TType, any>>): TType;
|
|
11
|
+
export declare function useFragment<TType>(_documentNode: DocumentTypeDecoration<TType, any>, fragmentType: FragmentType<DocumentTypeDecoration<TType, any>> | null | undefined): TType | null | undefined;
|
|
12
|
+
export declare function useFragment<TType>(_documentNode: DocumentTypeDecoration<TType, any>, fragmentType: ReadonlyArray<FragmentType<DocumentTypeDecoration<TType, any>>>): ReadonlyArray<TType>;
|
|
13
|
+
export declare function useFragment<TType>(_documentNode: DocumentTypeDecoration<TType, any>, fragmentType: ReadonlyArray<FragmentType<DocumentTypeDecoration<TType, any>>> | null | undefined): ReadonlyArray<TType> | null | undefined;
|
|
14
|
+
export declare function makeFragmentData<F extends DocumentTypeDecoration<any, any>, FT extends ResultOf<F>>(data: FT, _fragment: F): FragmentType<F>;
|
|
15
|
+
export declare function isFragmentReady<TQuery, TFrag>(queryNode: DocumentTypeDecoration<TQuery, any>, fragmentNode: TypedDocumentNode<TFrag>, data: FragmentType<TypedDocumentNode<Incremental<TFrag>, any>> | null | undefined): data is FragmentType<typeof fragmentNode>;
|