@oanda/labs-instruments-price-chart-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 +18 -0
- package/dist/main/InstrumentsPriceChartWidget/InstrumentsPriceChartWidget.js +40 -0
- package/dist/main/InstrumentsPriceChartWidget/InstrumentsPriceChartWidget.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/Main.js +52 -0
- package/dist/main/InstrumentsPriceChartWidget/Main.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/components/Chart.js +39 -0
- package/dist/main/InstrumentsPriceChartWidget/components/Chart.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/components/constants.js +12 -0
- package/dist/main/InstrumentsPriceChartWidget/components/constants.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/components/formatters.js +15 -0
- package/dist/main/InstrumentsPriceChartWidget/components/formatters.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/components/getOption.js +119 -0
- package/dist/main/InstrumentsPriceChartWidget/components/getOption.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/components/types.js +6 -0
- package/dist/main/InstrumentsPriceChartWidget/components/types.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/config.js +44 -0
- package/dist/main/InstrumentsPriceChartWidget/config.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/index.js +28 -0
- package/dist/main/InstrumentsPriceChartWidget/index.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/render.js +42 -0
- package/dist/main/InstrumentsPriceChartWidget/render.js.map +1 -0
- package/dist/main/InstrumentsPriceChartWidget/types.js +16 -0
- package/dist/main/InstrumentsPriceChartWidget/types.js.map +1 -0
- package/dist/main/gql/mock/getPriceCandles.js +30 -0
- package/dist/main/gql/mock/getPriceCandles.js.map +1 -0
- package/dist/main/gql/mock/handlers.js +62 -0
- package/dist/main/gql/mock/handlers.js.map +1 -0
- package/dist/main/gql/mock/schema.graphqls +59 -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 +438 -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 +17 -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 +2 -0
- package/dist/main/translations/sources/es.json +2 -0
- package/dist/main/translations/sources/th.json +2 -0
- package/dist/main/translations/sources/zh_TW.json +2 -0
- package/dist/main/translations/translations.js +8 -0
- package/dist/main/translations/translations.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/InstrumentsPriceChartWidget.js +33 -0
- package/dist/module/InstrumentsPriceChartWidget/InstrumentsPriceChartWidget.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/Main.js +44 -0
- package/dist/module/InstrumentsPriceChartWidget/Main.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/components/Chart.js +29 -0
- package/dist/module/InstrumentsPriceChartWidget/components/Chart.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/components/constants.js +6 -0
- package/dist/module/InstrumentsPriceChartWidget/components/constants.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/components/formatters.js +8 -0
- package/dist/module/InstrumentsPriceChartWidget/components/formatters.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/components/getOption.js +112 -0
- package/dist/module/InstrumentsPriceChartWidget/components/getOption.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/components/types.js +2 -0
- package/dist/module/InstrumentsPriceChartWidget/components/types.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/config.js +39 -0
- package/dist/module/InstrumentsPriceChartWidget/config.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/index.js +3 -0
- package/dist/module/InstrumentsPriceChartWidget/index.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/render.js +39 -0
- package/dist/module/InstrumentsPriceChartWidget/render.js.map +1 -0
- package/dist/module/InstrumentsPriceChartWidget/types.js +10 -0
- package/dist/module/InstrumentsPriceChartWidget/types.js.map +1 -0
- package/dist/module/gql/mock/getPriceCandles.js +25 -0
- package/dist/module/gql/mock/getPriceCandles.js.map +1 -0
- package/dist/module/gql/mock/handlers.js +56 -0
- package/dist/module/gql/mock/handlers.js.map +1 -0
- package/dist/module/gql/mock/schema.graphqls +59 -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 +432 -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 +2 -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 +2 -0
- package/dist/module/translations/sources/es.json +2 -0
- package/dist/module/translations/sources/th.json +2 -0
- package/dist/module/translations/sources/zh_TW.json +2 -0
- package/dist/module/translations/translations.js +2 -0
- package/dist/module/translations/translations.js.map +1 -0
- package/dist/types/InstrumentsPriceChartWidget/InstrumentsPriceChartWidget.d.ts +4 -0
- package/dist/types/InstrumentsPriceChartWidget/Main.d.ts +4 -0
- package/dist/types/InstrumentsPriceChartWidget/components/Chart.d.ts +3 -0
- package/dist/types/InstrumentsPriceChartWidget/components/constants.d.ts +5 -0
- package/dist/types/InstrumentsPriceChartWidget/components/formatters.d.ts +1 -0
- package/dist/types/InstrumentsPriceChartWidget/components/getOption.d.ts +2 -0
- package/dist/types/InstrumentsPriceChartWidget/components/types.d.ts +14 -0
- package/dist/types/InstrumentsPriceChartWidget/config.d.ts +10 -0
- package/dist/types/InstrumentsPriceChartWidget/index.d.ts +2 -0
- package/dist/types/InstrumentsPriceChartWidget/render.d.ts +1 -0
- package/dist/types/InstrumentsPriceChartWidget/types.d.ts +15 -0
- package/dist/types/gql/mock/getPriceCandles.d.ts +2 -0
- package/dist/types/gql/mock/handlers.d.ts +1 -0
- package/dist/types/gql/types/fragment-masking.d.ts +15 -0
- package/dist/types/gql/types/gql.d.ts +47 -0
- package/dist/types/gql/types/graphql.d.ts +468 -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 +1 -0
- package/dist/types/translations/index.d.ts +4 -0
- package/dist/types/translations/translations.d.ts +1 -0
- package/index.ts +1 -0
- package/lokalise.config.json +18 -0
- package/package.json +24 -0
- package/src/InstrumentsPriceChartWidget/InstrumentsPriceChartWidget.tsx +40 -0
- package/src/InstrumentsPriceChartWidget/Main.tsx +59 -0
- package/src/InstrumentsPriceChartWidget/components/Chart.tsx +47 -0
- package/src/InstrumentsPriceChartWidget/components/constants.ts +5 -0
- package/src/InstrumentsPriceChartWidget/components/formatters.ts +7 -0
- package/src/InstrumentsPriceChartWidget/components/getOption.ts +127 -0
- package/src/InstrumentsPriceChartWidget/components/types.ts +19 -0
- package/src/InstrumentsPriceChartWidget/config.ts +47 -0
- package/src/InstrumentsPriceChartWidget/index.ts +2 -0
- package/src/InstrumentsPriceChartWidget/render.tsx +52 -0
- package/src/InstrumentsPriceChartWidget/types.ts +20 -0
- package/src/gql/mock/getPriceCandles.ts +26 -0
- package/src/gql/mock/handlers.ts +66 -0
- package/src/gql/mock/schema.graphqls +59 -0
- package/src/gql/types/fragment-masking.ts +86 -0
- package/src/gql/types/gql.ts +54 -0
- package/src/gql/types/graphql.ts +723 -0
- package/src/gql/types/index.ts +2 -0
- package/src/gql/validateInstruments.ts +10 -0
- package/src/index.ts +1 -0
- package/src/translations/index.ts +17 -0
- package/src/translations/sources/en.json +2 -0
- package/src/translations/sources/es.json +2 -0
- package/src/translations/sources/th.json +2 -0
- package/src/translations/sources/zh_TW.json +2 -0
- package/src/translations/translations.ts +1 -0
- package/test/Main.test.tsx +26 -0
- package/test/mocks/chartMock.ts +52 -0
- package/test/mocks/index.ts +1 -0
- package/tsconfig.types.json +12 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graphql.js","names":["AssetClassName","BookType","CorrelationTimeUnit","CurrencyName","CurrencyPowerBalanceTimeUnit","DataSource","Division","Granularity","InstrumentDataSource","Region","Sort","TimeSpan","TopicalSort","ValueAtRiskBars","ValueAtRiskDuration","VolatilityChartTimeSpan","VolatilityChartTimeUnit","GetPriceCandlesDocument","kind","definitions","operation","name","value","variableDefinitions","variable","type","selectionSet","selections","arguments","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 }> = {\n [K in keyof T]: T[K];\n};\nexport type MakeOptional<T, K extends keyof T> = Omit<T, K> & {\n [SubKey in K]?: Maybe<T[SubKey]>;\n};\nexport type MakeMaybe<T, K extends keyof T> = Omit<T, K> & {\n [SubKey in K]: Maybe<T[SubKey]>;\n};\nexport type MakeEmpty<\n T extends { [key: string]: unknown },\n K extends keyof T,\n> = { [_ in K]?: never };\nexport type Incremental<T> =\n | T\n | {\n [P in keyof T]?: P extends ' $fragmentName' | '__typename' ? T[P] : never;\n };\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 Etfs = 'ETFS',\n Indices = 'INDICES',\n Rates = 'RATES',\n}\n\nexport enum BookType {\n Order = 'ORDER',\n Position = 'POSITION',\n}\n\nexport type Candle = {\n __typename?: 'Candle';\n high: Scalars['Float']['output'];\n};\n\nexport type CandlesData = {\n __typename?: 'CandlesData';\n candle: Candle;\n time: Scalars['String']['output'];\n timeSpan: TimeSpan;\n unixTime: Scalars['Int']['output'];\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 enum Granularity {\n Day_1 = 'DAY_1',\n Hour_1 = 'HOUR_1',\n Hour_4 = 'HOUR_4',\n Minute_5 = 'MINUTE_5',\n Minute_15 = 'MINUTE_15',\n Minute_30 = 'MINUTE_30',\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 enum InstrumentDataSource {\n Mt5 = 'MT5',\n V20 = 'V20',\n}\n\nexport type InstrumentTableResult = {\n __typename?: 'InstrumentTableResult';\n instruments: Array<Instrument>;\n totalCount: Scalars['Int']['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 getPriceCandles: Array<CandlesData>;\n isAllowedPartner?: Maybe<Scalars['Boolean']['output']>;\n mapInstrumentNames?: Maybe<Array<Maybe<Instrument>>>;\n orderPositionBooks: Array<Maybe<OrderPositionData>>;\n resolveInstrumentsByDivision?: Maybe<Array<Instrument>>;\n resolveInstrumentsWithFilters?: Maybe<InstrumentTableResult>;\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\nexport type QueryAssetClassesArgs = {\n division: Division;\n};\n\nexport type QueryCorrelationHeatmapArgs = {\n division: Division;\n instruments?: InputMaybe<Array<InputMaybe<Scalars['String']['input']>>>;\n timeSpans?: InputMaybe<Array<InputMaybe<CorrelationTimeUnit>>>;\n};\n\nexport type QueryCorrelationMatrixArgs = {\n division: Division;\n instruments?: InputMaybe<Array<InputMaybe<Scalars['String']['input']>>>;\n};\n\nexport type QueryCurrencyPowerBalanceArgs = {\n timeUnit: CurrencyPowerBalanceTimeUnit;\n};\n\nexport type QueryGetPriceCandlesArgs = {\n division?: InputMaybe<Division>;\n granularity: Granularity;\n instrument: Scalars['String']['input'];\n timeSpan: TimeSpan;\n};\n\nexport type QueryIsAllowedPartnerArgs = {\n url: Scalars['String']['input'];\n};\n\nexport type QueryMapInstrumentNamesArgs = {\n division?: InputMaybe<Division>;\n instruments: Array<InputMaybe<Scalars['String']['input']>>;\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\nexport type QueryResolveInstrumentsByDivisionArgs = {\n division: Division;\n instruments: Array<InputMaybe<Scalars['String']['input']>>;\n};\n\nexport type QueryResolveInstrumentsWithFiltersArgs = {\n assetClass?: InputMaybe<Array<InputMaybe<AssetClassName>>>;\n count?: InputMaybe<Scalars['Int']['input']>;\n dataSource?: InputMaybe<InstrumentDataSource>;\n division: Division;\n instruments?: InputMaybe<Array<InputMaybe<Scalars['String']['input']>>>;\n offset?: InputMaybe<Scalars['Int']['input']>;\n searchPattern?: InputMaybe<Scalars['String']['input']>;\n};\n\nexport type QuerySentimentArgs = {\n division?: InputMaybe<Division>;\n name: Scalars['String']['input'];\n};\n\nexport type QuerySentimentListArgs = {\n division?: InputMaybe<Division>;\n sort?: InputMaybe<Sort>;\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\nexport type QueryTopicalInstrumentsChartsArgs = {\n division?: InputMaybe<Division>;\n instruments?: InputMaybe<Array<Scalars['String']['input']>>;\n};\n\nexport type QueryTopicalInstrumentsTotalCountArgs = {\n assetClass?: InputMaybe<AssetClassName>;\n division?: InputMaybe<Division>;\n sort: TopicalSort;\n};\n\nexport type QueryValueAtRiskAssetClassesArgs = {\n division?: InputMaybe<Division>;\n};\n\nexport type QueryValueAtRiskChartArgs = {\n bars: ValueAtRiskBars;\n division?: InputMaybe<Division>;\n duration: ValueAtRiskDuration;\n instrument: Scalars['String']['input'];\n};\n\nexport type QueryVolatilityChartArgs = {\n division?: InputMaybe<Division>;\n instrument: Scalars['String']['input'];\n timeSpan: VolatilityChartTimeSpan;\n timeUnit: VolatilityChartTimeUnit;\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 enum TimeSpan {\n Day_1 = 'DAY_1',\n Day_2 = 'DAY_2',\n Hour_1 = 'HOUR_1',\n Hour_12 = 'HOUR_12',\n Month_1 = 'MONTH_1',\n Month_3 = 'MONTH_3',\n Month_6 = 'MONTH_6',\n Week_1 = 'WEEK_1',\n Week_2 = 'WEEK_2',\n Week_3 = 'WEEK_3',\n Year_1 = 'YEAR_1',\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 GetPriceCandlesQueryVariables = Exact<{\n division?: InputMaybe<Division>;\n instrument: Scalars['String']['input'];\n granularity: Granularity;\n timeSpan: TimeSpan;\n}>;\n\nexport type GetPriceCandlesQuery = {\n __typename?: 'Query';\n getPriceCandles: Array<{\n __typename?: 'CandlesData';\n time: string;\n unixTime: number;\n timeSpan: TimeSpan;\n candle: { __typename?: 'Candle'; high: number };\n }>;\n};\n\nexport type ValidateInstrumentsQueryVariables = Exact<{\n instruments:\n | Array<InputMaybe<Scalars['String']['input']>>\n | InputMaybe<Scalars['String']['input']>;\n division?: InputMaybe<Division>;\n}>;\n\nexport type ValidateInstrumentsQuery = {\n __typename?: 'Query';\n mapInstrumentNames?: Array<{\n __typename?: 'Instrument';\n name: string;\n displayName: string;\n } | null> | null;\n};\n\nexport const GetPriceCandlesDocument = {\n kind: 'Document',\n definitions: [\n {\n kind: 'OperationDefinition',\n operation: 'query',\n name: { kind: 'Name', value: 'GetPriceCandles' },\n variableDefinitions: [\n {\n kind: 'VariableDefinition',\n variable: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'division' },\n },\n type: {\n kind: 'NamedType',\n name: { kind: 'Name', value: 'Division' },\n },\n },\n {\n kind: 'VariableDefinition',\n variable: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'instrument' },\n },\n type: {\n kind: 'NonNullType',\n type: {\n kind: 'NamedType',\n name: { kind: 'Name', value: 'String' },\n },\n },\n },\n {\n kind: 'VariableDefinition',\n variable: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'granularity' },\n },\n type: {\n kind: 'NonNullType',\n type: {\n kind: 'NamedType',\n name: { kind: 'Name', value: 'Granularity' },\n },\n },\n },\n {\n kind: 'VariableDefinition',\n variable: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'timeSpan' },\n },\n type: {\n kind: 'NonNullType',\n type: {\n kind: 'NamedType',\n name: { kind: 'Name', value: 'TimeSpan' },\n },\n },\n },\n ],\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'getPriceCandles' },\n arguments: [\n {\n kind: 'Argument',\n name: { kind: 'Name', value: 'division' },\n value: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'division' },\n },\n },\n {\n kind: 'Argument',\n name: { kind: 'Name', value: 'instrument' },\n value: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'instrument' },\n },\n },\n {\n kind: 'Argument',\n name: { kind: 'Name', value: 'granularity' },\n value: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'granularity' },\n },\n },\n {\n kind: 'Argument',\n name: { kind: 'Name', value: 'timeSpan' },\n value: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'timeSpan' },\n },\n },\n ],\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'time' } },\n { kind: 'Field', name: { kind: 'Name', value: 'unixTime' } },\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'candle' },\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'high' } },\n ],\n },\n },\n { kind: 'Field', name: { kind: 'Name', value: 'timeSpan' } },\n ],\n },\n },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<\n GetPriceCandlesQuery,\n GetPriceCandlesQueryVariables\n>;\nexport const ValidateInstrumentsDocument = {\n kind: 'Document',\n definitions: [\n {\n kind: 'OperationDefinition',\n operation: 'query',\n name: { kind: 'Name', value: 'validateInstruments' },\n variableDefinitions: [\n {\n kind: 'VariableDefinition',\n variable: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'instruments' },\n },\n type: {\n kind: 'NonNullType',\n type: {\n kind: 'ListType',\n type: {\n kind: 'NamedType',\n name: { kind: 'Name', value: 'String' },\n },\n },\n },\n },\n {\n kind: 'VariableDefinition',\n variable: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'division' },\n },\n type: {\n kind: 'NamedType',\n name: { kind: 'Name', value: 'Division' },\n },\n },\n ],\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n {\n kind: 'Field',\n name: { kind: 'Name', value: 'mapInstrumentNames' },\n arguments: [\n {\n kind: 'Argument',\n name: { kind: 'Name', value: 'instruments' },\n value: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'instruments' },\n },\n },\n {\n kind: 'Argument',\n name: { kind: 'Name', value: 'division' },\n value: {\n kind: 'Variable',\n name: { kind: 'Name', value: 'division' },\n },\n },\n ],\n selectionSet: {\n kind: 'SelectionSet',\n selections: [\n { kind: 'Field', name: { kind: 'Name', value: 'name' } },\n { kind: 'Field', name: { kind: 'Name', value: 'displayName' } },\n ],\n },\n },\n ],\n },\n },\n ],\n} as unknown as DocumentNode<\n ValidateInstrumentsQuery,\n ValidateInstrumentsQueryVariables\n>;\n"],"mappings":"AAqCA,WAAYA,cAAc,aAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAA,OAAdA,cAAc;AAAA;AAU1B,WAAYC,QAAQ,aAARA,QAAQ;EAARA,QAAQ;EAARA,QAAQ;EAAA,OAARA,QAAQ;AAAA;AA8BpB,WAAYC,mBAAmB,aAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAnBA,mBAAmB;EAAA,OAAnBA,mBAAmB;AAAA;AAW/B,WAAYC,YAAY,aAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAA,OAAZA,YAAY;AAAA;AAyBxB,WAAYC,4BAA4B,aAA5BA,4BAA4B;EAA5BA,4BAA4B;EAA5BA,4BAA4B;EAA5BA,4BAA4B;EAA5BA,4BAA4B;EAA5BA,4BAA4B;EAA5BA,4BAA4B;EAA5BA,4BAA4B;EAA5BA,4BAA4B;EA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AAE,UAAU;UAChBG,IAAI,EAAE;YAAEH,IAAI,EAAE,MAAM;YAAEI,KAAK,EAAE;UAAc,CAAC;UAC5CA,KAAK,EAAE;YACLJ,IAAI,EAAE,UAAU;YAChBG,IAAI,EAAE;cAAEH,IAAI,EAAE,MAAM;cAAEI,KAAK,EAAE;YAAc;UAC7C;QACF,CAAC,EACD;UACEJ,IAAI,EAAE,UAAU;UAChBG,IAAI,EAAE;YAAEH,IAAI,EAAE,MAAM;YAAEI,KAAK,EAAE;UAAW,CAAC;UACzCA,KAAK,EAAE;YACLJ,IAAI,EAAE,UAAU;YAChBG,IAAI,EAAE;cAAEH,IAAI,EAAE,MAAM;cAAEI,KAAK,EAAE;YAAW;UAC1C;QACF,CAAC,CACF;QACDI,YAAY,EAAE;UACZR,IAAI,EAAE,cAAc;UACpBS,UAAU,EAAE,CACV;YAAET,IAAI,EAAE,OAAO;YAAEG,IAAI,EAAE;cAAEH,IAAI,EAAE,MAAM;cAAEI,KAAK,EAAE;YAAO;UAAE,CAAC,EACxD;YAAEJ,IAAI,EAAE,OAAO;YAAEG,IAAI,EAAE;cAAEH,IAAI,EAAE,MAAM;cAAEI,KAAK,EAAE;YAAc;UAAE,CAAC;QAEnE;MACF,CAAC;IAEL;EACF,CAAC;AAEL,CAGC","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';\n"],"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 './InstrumentsPriceChartWidget';\n"],"mappings":"AAAA,cAAc,+BAA+B","ignoreList":[]}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Locale } from '@oanda/mono-i18n';
|
|
2
|
+
import en from './sources/en.json';
|
|
3
|
+
import es from './sources/es.json';
|
|
4
|
+
import th from './sources/th.json';
|
|
5
|
+
import zhTW from './sources/zh_TW.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","es","th","zhTW","translations","translation"],"sources":["../../../src/translations/index.ts"],"sourcesContent":["import type { Translations } from '@oanda/mono-i18n';\nimport { Locale } from '@oanda/mono-i18n';\n\nimport en from './sources/en.json';\nimport es from './sources/es.json';\nimport th from './sources/th.json';\nimport zhTW from './sources/zh_TW.json';\nimport type { 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":"AACA,SAASA,MAAM,QAAQ,kBAAkB;AAEzC,OAAOC,EAAE,MAAM,mBAAmB;AAClC,OAAOC,EAAE,MAAM,mBAAmB;AAClC,OAAOC,EAAE,MAAM,mBAAmB;AAClC,OAAOC,IAAI,MAAM,sBAAsB;AAKvC,OAAO,MAAMC,YAA0B,GAAG;EACxC,CAACL,MAAM,CAACC,EAAE,GAAG;IAAEK,WAAW,EAAEL;EAAG,CAAC;EAChC,CAACD,MAAM,CAACI,IAAI,GAAG;IAAEE,WAAW,EAAEF;EAAK,CAAC;EACpC,CAACJ,MAAM,CAACE,EAAE,GAAG;IAAEI,WAAW,EAAEJ;EAAG,CAAC;EAChC,CAACF,MAAM,CAACG,EAAE,GAAG;IAAEG,WAAW,EAAEH;EAAG;AACjC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"translations.js","names":["defaultTranslations"],"sources":["../../../src/translations/translations.ts"],"sourcesContent":["export const defaultTranslations = {};\n"],"mappings":"AAAA,OAAO,MAAMA,mBAAmB,GAAG,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { InstrumentsPriceChartConfig } from './types';
|
|
3
|
+
declare const InstrumentsPriceChartWidget: ({ graphqlUrl, locale, theme, isParamError, logoLink, division, }: InstrumentsPriceChartConfig) => React.JSX.Element;
|
|
4
|
+
export { InstrumentsPriceChartWidget };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const dailyFormatter: (timestamp: string) => string;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { EChartsOption } from 'echarts';
|
|
2
|
+
import type { CandlesData } from '../../gql/types/graphql';
|
|
3
|
+
export interface ChartProps {
|
|
4
|
+
values: CandlesData[];
|
|
5
|
+
}
|
|
6
|
+
export interface GetOptionProps {
|
|
7
|
+
values: CandlesData[];
|
|
8
|
+
isDark: boolean;
|
|
9
|
+
}
|
|
10
|
+
export type GetOptionType = (props: GetOptionProps) => EChartsOption;
|
|
11
|
+
export interface ChartValue {
|
|
12
|
+
min: number;
|
|
13
|
+
max: number;
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { WidgetConfig } from '@oanda/labs-widget-common';
|
|
2
|
+
import type { Division } from '../gql/types/graphql';
|
|
3
|
+
export interface InstrumentsPriceChartConfig extends WidgetConfig {
|
|
4
|
+
division: Division;
|
|
5
|
+
}
|
|
6
|
+
export interface MainProps {
|
|
7
|
+
division: Division;
|
|
8
|
+
}
|
|
9
|
+
export declare enum TimeSpanSubset {
|
|
10
|
+
Day_1 = "DAY_1",
|
|
11
|
+
Week_1 = "WEEK_1",
|
|
12
|
+
Month_1 = "MONTH_1",
|
|
13
|
+
Month_6 = "MONTH_6",
|
|
14
|
+
Year_1 = "YEAR_1"
|
|
15
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const handlers: import("msw").GraphQLHandler[];
|
|
@@ -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>;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import * as types from './graphql';
|
|
2
|
+
import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/core';
|
|
3
|
+
/**
|
|
4
|
+
* Map of all GraphQL operations in the project.
|
|
5
|
+
*
|
|
6
|
+
* This map has several performance disadvantages:
|
|
7
|
+
* 1. It is not tree-shakeable, so it will include all operations in the project.
|
|
8
|
+
* 2. It is not minifiable, so the string of a GraphQL query will be multiple times inside the bundle.
|
|
9
|
+
* 3. It does not support dead code elimination, so it will add unused operations.
|
|
10
|
+
*
|
|
11
|
+
* Therefore it is highly recommended to use the babel or swc plugin for production.
|
|
12
|
+
*/
|
|
13
|
+
declare const documents: {
|
|
14
|
+
'\n query GetPriceCandles(\n $division: Division\n $instrument: String!\n $granularity: Granularity!\n $timeSpan: TimeSpan!\n ) {\n getPriceCandles(\n division: $division\n instrument: $instrument\n granularity: $granularity\n timeSpan: $timeSpan\n ) {\n time\n unixTime\n candle {\n high\n }\n timeSpan\n }\n }\n': DocumentNode<types.GetPriceCandlesQuery, types.Exact<{
|
|
15
|
+
division?: types.InputMaybe<types.Division>;
|
|
16
|
+
instrument: types.Scalars["String"]["input"];
|
|
17
|
+
granularity: types.Granularity;
|
|
18
|
+
timeSpan: types.TimeSpan;
|
|
19
|
+
}>>;
|
|
20
|
+
'\n query validateInstruments($instruments: [String]!, $division: Division) {\n mapInstrumentNames(instruments: $instruments, division: $division) {\n name\n displayName\n }\n }\n': DocumentNode<types.ValidateInstrumentsQuery, types.Exact<{
|
|
21
|
+
instruments: Array<types.InputMaybe<types.Scalars["String"]["input"]>> | types.InputMaybe<types.Scalars["String"]["input"]>;
|
|
22
|
+
division?: types.InputMaybe<types.Division>;
|
|
23
|
+
}>>;
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
27
|
+
*
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```ts
|
|
31
|
+
* const query = graphql(`query GetUser($id: ID!) { user(id: $id) { name } }`);
|
|
32
|
+
* ```
|
|
33
|
+
*
|
|
34
|
+
* The query argument is unknown!
|
|
35
|
+
* Please regenerate the types.
|
|
36
|
+
*/
|
|
37
|
+
export declare function graphql(source: string): unknown;
|
|
38
|
+
/**
|
|
39
|
+
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
40
|
+
*/
|
|
41
|
+
export declare function graphql(source: '\n query GetPriceCandles(\n $division: Division\n $instrument: String!\n $granularity: Granularity!\n $timeSpan: TimeSpan!\n ) {\n getPriceCandles(\n division: $division\n instrument: $instrument\n granularity: $granularity\n timeSpan: $timeSpan\n ) {\n time\n unixTime\n candle {\n high\n }\n timeSpan\n }\n }\n'): (typeof documents)['\n query GetPriceCandles(\n $division: Division\n $instrument: String!\n $granularity: Granularity!\n $timeSpan: TimeSpan!\n ) {\n getPriceCandles(\n division: $division\n instrument: $instrument\n granularity: $granularity\n timeSpan: $timeSpan\n ) {\n time\n unixTime\n candle {\n high\n }\n timeSpan\n }\n }\n'];
|
|
42
|
+
/**
|
|
43
|
+
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
44
|
+
*/
|
|
45
|
+
export declare function graphql(source: '\n query validateInstruments($instruments: [String]!, $division: Division) {\n mapInstrumentNames(instruments: $instruments, division: $division) {\n name\n displayName\n }\n }\n'): (typeof documents)['\n query validateInstruments($instruments: [String]!, $division: Division) {\n mapInstrumentNames(instruments: $instruments, division: $division) {\n name\n displayName\n }\n }\n'];
|
|
46
|
+
export type DocumentType<TDocumentNode extends DocumentNode<any, any>> = TDocumentNode extends DocumentNode<infer TType, any> ? TType : never;
|
|
47
|
+
export {};
|