rename graphql dir to types
This commit is contained in:
parent
3f62c79f8d
commit
edce1c7869
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { AccountType } from "./../../../../../../../libs/graphql/src/__generated__/globalTypes";
|
||||
import { AccountType } from "./../../../../../../../libs/types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: AssetsQuery
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { ProposalState, ProposalRejectionReason, VoteValue } from "./../../../../../../../libs/graphql/src/__generated__/globalTypes";
|
||||
import { ProposalState, ProposalRejectionReason, VoteValue } from "./../../../../../../../libs/types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: ProposalsQuery
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketTradingMode, MarketState, AccountType, AuctionTrigger } from "./../../../../../../../libs/graphql/src/__generated__/globalTypes";
|
||||
import { MarketTradingMode, MarketState, AccountType, AuctionTrigger } from "./../../../../../../../libs/types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: MarketsQuery
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { AccountType } from "./../../../../../../../../libs/graphql/src/__generated__/globalTypes";
|
||||
import { AccountType } from "./../../../../../../../../libs/types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: PartyAssetsQuery
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { NodeStatus } from "./../../../../../../../libs/graphql/src/__generated__/globalTypes";
|
||||
import { NodeStatus } from "./../../../../../../../libs/types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: NodesQuery
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketState, MarketTradingMode } from "./../../../../../libs/graphql/src/__generated__/globalTypes";
|
||||
import { MarketState, MarketTradingMode } from "./../../../../../libs/types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: Market
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketState, MarketTradingMode } from "./../../../graphql/src/__generated__/globalTypes";
|
||||
import { MarketState, MarketTradingMode } from "./../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: DealTicketQuery
|
||||
|
2
libs/deal-ticket/src/__generated__/OrderEvent.ts
generated
2
libs/deal-ticket/src/__generated__/OrderEvent.ts
generated
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { BusEventType, OrderType, OrderStatus, OrderRejectionReason } from "./../../../graphql/src/__generated__/globalTypes";
|
||||
import { BusEventType, OrderType, OrderStatus, OrderRejectionReason } from "./../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL subscription operation: OrderEvent
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { useEffect, useState } from 'react';
|
||||
import { Dialog, Intent } from '@vegaprotocol/ui-toolkit';
|
||||
import { OrderStatus } from '@vegaprotocol/graphql';
|
||||
import { OrderStatus } from '@vegaprotocol/types';
|
||||
import { VegaTxStatus } from '@vegaprotocol/wallet';
|
||||
import { DealTicket } from './deal-ticket';
|
||||
import { useOrderSubmit } from './use-order-submit';
|
||||
|
@ -1,7 +0,0 @@
|
||||
# graphql
|
||||
|
||||
This library was generated with [Nx](https://nx.dev).
|
||||
|
||||
## Running unit tests
|
||||
|
||||
Run `nx test graphql` to execute the unit tests via [Jest](https://jestjs.io).
|
@ -1,4 +0,0 @@
|
||||
{
|
||||
"name": "@vegaprotocol/graphql",
|
||||
"version": "0.0.1"
|
||||
}
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketState, MarketTradingMode } from "./../../../../graphql/src/__generated__/globalTypes";
|
||||
import { MarketState, MarketTradingMode } from "./../../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL fragment: MarketDataFields
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketState, MarketTradingMode } from "./../../../../graphql/src/__generated__/globalTypes";
|
||||
import { MarketState, MarketTradingMode } from "./../../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL subscription operation: MarketDataSub
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketState, MarketTradingMode } from "./../../../../graphql/src/__generated__/globalTypes";
|
||||
import { MarketState, MarketTradingMode } from "./../../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: Markets
|
||||
|
2
libs/order-list/src/__generated__/OrderFields.ts
generated
2
libs/order-list/src/__generated__/OrderFields.ts
generated
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { OrderType, Side, OrderStatus, OrderRejectionReason, OrderTimeInForce } from "./../../../graphql/src/__generated__/globalTypes";
|
||||
import { OrderType, Side, OrderStatus, OrderRejectionReason, OrderTimeInForce } from "./../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL fragment: OrderFields
|
||||
|
2
libs/order-list/src/__generated__/OrderSub.ts
generated
2
libs/order-list/src/__generated__/OrderSub.ts
generated
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { OrderType, Side, OrderStatus, OrderRejectionReason, OrderTimeInForce } from "./../../../graphql/src/__generated__/globalTypes";
|
||||
import { OrderType, Side, OrderStatus, OrderRejectionReason, OrderTimeInForce } from "./../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL subscription operation: OrderSub
|
||||
|
2
libs/order-list/src/__generated__/Orders.ts
generated
2
libs/order-list/src/__generated__/Orders.ts
generated
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { OrderType, Side, OrderStatus, OrderRejectionReason, OrderTimeInForce } from "./../../../graphql/src/__generated__/globalTypes";
|
||||
import { OrderType, Side, OrderStatus, OrderRejectionReason, OrderTimeInForce } from "./../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: Orders
|
||||
|
@ -7,7 +7,7 @@ import {
|
||||
OrderType,
|
||||
Side,
|
||||
OrderRejectionReason,
|
||||
} from '@vegaprotocol/graphql';
|
||||
} from '@vegaprotocol/types';
|
||||
import { OrderList } from './order-list';
|
||||
|
||||
test('No orders message shown', async () => {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { OrderTimeInForce, OrderStatus, Side } from '@vegaprotocol/graphql';
|
||||
import { OrderTimeInForce, OrderStatus, Side } from '@vegaprotocol/types';
|
||||
import { Orders_party_orders } from './__generated__/Orders';
|
||||
import {
|
||||
formatNumber,
|
||||
|
@ -8,7 +8,7 @@ import {
|
||||
Side,
|
||||
OrderType,
|
||||
OrderTimeInForce,
|
||||
} from '@vegaprotocol/graphql';
|
||||
} from '@vegaprotocol/types';
|
||||
import {
|
||||
VegaKeyExtended,
|
||||
VegaWalletContext,
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketTradingMode } from "./../../../../graphql/src/__generated__/globalTypes";
|
||||
import { MarketTradingMode } from "./../../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL fragment: PositionDetails
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketTradingMode } from "./../../../../graphql/src/__generated__/globalTypes";
|
||||
import { MarketTradingMode } from "./../../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL subscription operation: PositionSubscribe
|
||||
|
@ -3,7 +3,7 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import { MarketTradingMode } from "./../../../../graphql/src/__generated__/globalTypes";
|
||||
import { MarketTradingMode } from "./../../../../types/src/__generated__/globalTypes";
|
||||
|
||||
// ====================================================
|
||||
// GraphQL query operation: Positions
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { act, render, screen } from '@testing-library/react';
|
||||
import PositionsTable from './positions-table';
|
||||
import { Positions_party_positions } from './__generated__/Positions';
|
||||
import { MarketTradingMode } from '@vegaprotocol/graphql';
|
||||
import { MarketTradingMode } from '@vegaprotocol/types';
|
||||
|
||||
const singleRow: Positions_party_positions = {
|
||||
realisedPNL: '5',
|
||||
|
@ -11,7 +11,7 @@ import { AgGridColumn } from 'ag-grid-react';
|
||||
import type { AgGridReact } from 'ag-grid-react';
|
||||
import compact from 'lodash/compact';
|
||||
import { Positions_party_positions } from './__generated__/Positions';
|
||||
import { MarketTradingMode } from '@vegaprotocol/graphql';
|
||||
import { MarketTradingMode } from '@vegaprotocol/types';
|
||||
|
||||
interface PositionsTableProps {
|
||||
data: Positions_party_positions[] | null;
|
||||
|
7
libs/types/README.md
Normal file
7
libs/types/README.md
Normal file
@ -0,0 +1,7 @@
|
||||
# types
|
||||
|
||||
This library was generated with [Nx](https://nx.dev).
|
||||
|
||||
## Running unit tests
|
||||
|
||||
Run `nx test types` to execute the unit tests via [Jest](https://jestjs.io).
|
@ -1,9 +1,9 @@
|
||||
module.exports = {
|
||||
displayName: 'graphql',
|
||||
displayName: 'types',
|
||||
preset: '../../jest.preset.js',
|
||||
transform: {
|
||||
'^.+\\.[tj]sx?$': 'babel-jest',
|
||||
},
|
||||
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
|
||||
coverageDirectory: '../../coverage/libs/graphql',
|
||||
coverageDirectory: '../../coverage/libs/types',
|
||||
};
|
4
libs/types/package.json
Normal file
4
libs/types/package.json
Normal file
@ -0,0 +1,4 @@
|
||||
{
|
||||
"name": "@vegaprotocol/types",
|
||||
"version": "0.0.1"
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"root": "libs/graphql",
|
||||
"sourceRoot": "libs/graphql/src",
|
||||
"root": "libs/types",
|
||||
"sourceRoot": "libs/types/src",
|
||||
"projectType": "library",
|
||||
"tags": [],
|
||||
"targets": {
|
||||
@ -8,16 +8,16 @@
|
||||
"executor": "@nrwl/web:rollup",
|
||||
"outputs": ["{options.outputPath}"],
|
||||
"options": {
|
||||
"outputPath": "dist/libs/graphql",
|
||||
"tsConfig": "libs/graphql/tsconfig.lib.json",
|
||||
"project": "libs/graphql/package.json",
|
||||
"entryFile": "libs/graphql/src/index.ts",
|
||||
"outputPath": "dist/libs/types",
|
||||
"tsConfig": "libs/types/tsconfig.lib.json",
|
||||
"project": "libs/types/package.json",
|
||||
"entryFile": "libs/types/src/index.ts",
|
||||
"external": ["react/jsx-runtime"],
|
||||
"rollupConfig": "@nrwl/react/plugins/bundle-rollup",
|
||||
"compiler": "babel",
|
||||
"assets": [
|
||||
{
|
||||
"glob": "libs/graphql/README.md",
|
||||
"glob": "libs/types/README.md",
|
||||
"input": ".",
|
||||
"output": "."
|
||||
}
|
||||
@ -28,14 +28,14 @@
|
||||
"executor": "@nrwl/linter:eslint",
|
||||
"outputs": ["{options.outputFile}"],
|
||||
"options": {
|
||||
"lintFilePatterns": ["libs/graphql/**/*.{ts,tsx,js,jsx}"]
|
||||
"lintFilePatterns": ["libs/types/**/*.{ts,tsx,js,jsx}"]
|
||||
}
|
||||
},
|
||||
"test": {
|
||||
"executor": "@nrwl/jest:jest",
|
||||
"outputs": ["coverage/libs/graphql"],
|
||||
"outputs": ["coverage/libs/types"],
|
||||
"options": {
|
||||
"jestConfig": "libs/graphql/jest.config.js",
|
||||
"jestConfig": "libs/types/jest.config.js",
|
||||
"passWithNoTests": true
|
||||
}
|
||||
},
|
||||
@ -44,7 +44,7 @@
|
||||
"options": {
|
||||
"commands": [
|
||||
{
|
||||
"command": "npx apollo client:codegen --config=libs/graphql/apollo.config.js --target=typescript --globalTypesFile=libs/graphql/src/__generated__/globalTypes.ts"
|
||||
"command": "npx apollo client:codegen --config=libs/types/apollo.config.js --target=typescript --globalTypesFile=libs/types/src/__generated__/globalTypes.ts"
|
||||
}
|
||||
]
|
||||
}
|
@ -16,7 +16,6 @@
|
||||
"baseUrl": ".",
|
||||
"paths": {
|
||||
"@vegaprotocol/deal-ticket": ["libs/deal-ticket/src/index.ts"],
|
||||
"@vegaprotocol/graphql": ["libs/graphql/src/index.ts"],
|
||||
"@vegaprotocol/market-list": ["libs/market-list/src/index.ts"],
|
||||
"@vegaprotocol/network-stats": ["libs/network-stats/src/index.ts"],
|
||||
"@vegaprotocol/order-list": ["libs/order-list/src/index.ts"],
|
||||
@ -25,6 +24,7 @@
|
||||
"@vegaprotocol/tailwindcss-config": [
|
||||
"libs/tailwindcss-config/src/index.js"
|
||||
],
|
||||
"@vegaprotocol/types": ["libs/types/src/index.ts"],
|
||||
"@vegaprotocol/ui-toolkit": ["libs/ui-toolkit/src/index.ts"],
|
||||
"@vegaprotocol/wallet": ["libs/wallet/src/index.ts"],
|
||||
"@vegaprotocol/web3": ["libs/web3/src/index.ts"]
|
||||
|
@ -4,7 +4,6 @@
|
||||
"deal-ticket": "libs/deal-ticket",
|
||||
"explorer": "apps/explorer",
|
||||
"explorer-e2e": "apps/explorer-e2e",
|
||||
"graphql": "libs/graphql",
|
||||
"market-list": "libs/market-list",
|
||||
"network-stats": "libs/network-stats",
|
||||
"order-list": "libs/order-list",
|
||||
@ -15,6 +14,7 @@
|
||||
"tailwindcss-config": "libs/tailwindcss-config",
|
||||
"trading": "apps/trading",
|
||||
"trading-e2e": "apps/trading-e2e",
|
||||
"types": "libs/types",
|
||||
"ui-toolkit": "libs/ui-toolkit",
|
||||
"wallet": "libs/wallet",
|
||||
"web3": "libs/web3"
|
||||
|
Loading…
Reference in New Issue
Block a user