Commit Graph

135 Commits

Author SHA1 Message Date
macqbat
46a85b8e65
fix: insufficient balance error doesn't reset validation after balance has been fulfilled (#2336)
* fix: live validation in deal ticket - reset validation after market state or account balance changes

* fix: live validation in deal ticket - reset fix lint error

* fix: live validation in deal ticket - adjust failing int test
2022-12-07 08:45:30 +01:00
macqbat
ca5c3bc21d
fix: live validation in deal ticket (#2315)
* fix: live validation in deal ticket

* fix: live validation in deal ticket

* fix: live validation in deal ticket

* fix: live validation in deal ticket - fix test mock generate
2022-12-06 09:09:13 +01:00
Matthew Russell
9ddedd0b78
chore(#2004): add market status to trade header (#2269)
* feat: add status header stat, move header to own component

* chore: fix alignment of price change values when arrow is not rendered

* test: add check for market state display

* feat: add market state component and adjust queries to handle sub updates to market state

* test: update mocks to include data.marketState fields

* chore: add missing market state to console-lite mock

* chore: test adjustment

* fix: botched conflict resolution

* chore: update select market columns test

* chore: add missing fields to test helper functions

Co-authored-by: Rado <szpiechrados@gmail.com>
2022-12-01 16:33:30 -08:00
Sam Keen
7c8a54b35a
feat(1263): split validator page into separate tables (#2250)
* frontend-monorepo-1263 validator status of pending now named 'candidate' in the ui

* feat(1263): validator table updates, calculating penalties

* feat(1263): bit of cleanup

* feat(1263): tables built and values derived

* feat(1263): tweaks

* feat(1263): upping site max width to 1500px

* feat(1263): tweak to normalised voting power column width

* feat(1263): ensure validator rows when hovered have cursor:pointer

* feat(1263): consensus validators now have a ranking field by voting power shown in the table

* feat(1263): fixed linting errors

* feat(1263): a couple of extra tests and correct import of schema to use enums

* Update apps/token/src/routes/staking/home/validator-tables/standby-pending-validators-table.tsx

Co-authored-by: Dexter Edwards <dexter.edwards93@gmail.com>

* Update apps/token/src/routes/staking/home/validator-tables/validator-tables.tsx

Co-authored-by: Dexter Edwards <dexter.edwards93@gmail.com>

* Update apps/token/src/routes/staking/home/validator-tables/validator-tables.tsx

Co-authored-by: Dexter Edwards <dexter.edwards93@gmail.com>

* Update apps/token/src/routes/staking/home/validator-tables/validator-tables.tsx

Co-authored-by: Dexter Edwards <dexter.edwards93@gmail.com>

* feat(1263): tweaks from PR comments, initial push of util to remove 'node' from arrs

* feat(1263): updated new util to remove 'node' from 'edges'. Implemented across the monorepo

* feat(1263): cleaned up splitting validators into consensus, pending and ersatz to put into tables

* feat(1263): used decimals from app state in validator-tables.tsx

* feat(1263): removed redundant compact import

Co-authored-by: Dexter Edwards <dexter.edwards93@gmail.com>
2022-11-30 12:55:30 +00:00
Radosław Szpiech
c60e5841f7
chore: add regression tagged tests to PR runs (#2242)
* chore: fix trading-portfolio test

* chore: fix wallet connect

* chore: fix failing deal ticket validation test

* chore: add regression tagged tests to be run during pr checks

* chore: skip parties tests in explorer-e2e

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-11-28 15:13:57 +01:00
m.ray
787a8ea1b3
fix: deal ticket set market price (#2228) 2022-11-25 08:39:14 -05:00
m.ray
fe447167ca
fix(#2200): handle NotFound GraphQL errors in async renderer (#2204)
* fix(#2200): handle NotFound GraphQL errors in async renderer

* fix(#2200): data provider filter apollo graphQL not found error

* fix(#2200): update apollo-client to not report not found error link

* fix(#2200): fix log on not found error link

* fix(#2200): fix set error in data provider

* fix(#2200): extensions type access via index signature

* fix(#2200): log gql errors that are not NotFound and still throw error in data provider

* fix: remove unused import
2022-11-24 15:52:46 -08:00
Matthew Russell
0ccf564ee7
fix(#2137,#2197): correct price for estimate order query (#2159)
* fix: correct price for estimate order query

* chore: remove unnecessary optional chaining, accidental added test file

* chore: dont prevent orders for pending market state

* chore: estimate order query so that expiration is set as timestamp otherwise query fails

* chore: add test helper for market, fix tests and add type for order margin
2022-11-23 14:33:37 +00:00
m.ray
41646086e4
chore(#2179): update number formatters across frontend-monorepo (#2182)
* chore: update stagnet3 urls

* chore(#2179): remove normalized number formatter functions and update getNumberFormat

* fix(#2179): fix unit tests on all formatters

* fix(#2179): fix some cypress tests

* fix: fix  trading-accounts.cy.ts

* fix: update staking and wallet teardown tests

* chore: add e2e run-all command

* fix: wallet-eth test

* fix: fix tests in explorer and token

* fix: fix common.functions.js

* fix: fix common.functions.js in explorer

* fix(#2179): fix common.functions.js in explorer

* fix(#2179): fix common.functions.js in explorer

* fix(#2179): fix common.functions.js in explorer

Co-authored-by: Matthew Russell <mattrussell36@gmail.com>
2022-11-22 18:14:16 +00:00
macqbat
b749a05736
chore(2071): deal ticket data update fixing (#2169)
* chore: update of deal ticket data

* chore: update of deal ticket data

* chore: update of deal ticket data - fix re-render loop

* chore: update of deal ticket data - add marketDealTicketProvider

* chore: update of deal ticket data - add marketDealTicketProvider

* chore: update of deal ticket data - adjust console-lite to the changes

* chore: update of deal ticket data - fix failing unit tests

* chore: update of deal ticket data - fix failing unit tests

* chore: update of deal ticket data - fix linter failings

* chore: update of deal ticket data - adjust console-lite-e2e

* chore: update of deal ticket data - fix build-spec failings

* chore: update of deal ticket data - fix failing e2e tests

* chore: update of deal ticket data - fix failing e2e tests

* chore: update of deal ticket data - fix failing e2e tests

* chore: update of deal ticket data - remove unnecessary gqls

* chore: update of deal ticket data - remove unnecessary gqls

* chore: update of deal ticket data - remove unnecessary gqls

* chore: update of deal ticket data - fix failings build

* chore: update of deal ticket data - remove redundant data provider

* chore: update of deal ticket data - remove redundant data provider

* chore: update of deal ticket data - fix some types
2022-11-22 09:31:26 +01:00
Matthew Russell
5fe994521f
chore(#1909): remove deprecated apis (#2081)
* chore: update queries using deprecated fields

* chore: regen generated files

* fix: account for new data shape as a result of PartyBalance.graphql changes

* fix: accounts data resulting from  MarketInfo.graphql changes

* fix: accounts data resulting from  PartyMarketData.graphql changes

* fix: accounts data resulting from  MarketPositions.graphql changes

* fix: accounts data resulting from  Accounts.graphql changes

* chore: update generate functions to return the correct shape

* chore: fix deal ticket tests

* chore: add missing fields too generateMarketInfoQuery mock

* chore: remove tsignore now object is properly typed

* fix: add missing mock for trading page

* chore: fix import path for validation hook

* chore: fix no data display for console lite assets
2022-11-16 12:31:23 -08:00
Bartłomiej Głownia
d1b45a65a0
feat(#1812): do not require Ethereum connection to display collateral (#2028)
* feat(#1812): don not require ethereum connection to display collateral

* feat(#1812): amend trading-account e2e tests

* feat(#1812): move Web3ConnectDialog to dialogs container, fix Web3Container childrenOnly option

* feat(#1812): fix withdraw e2e tests

* feat(#1812): reverse DialogsContainer changes, add Web3ConnectUncontrolledDialog

* feat(#1812): wrap WithdrawalDialog with  Web3Container

* feat(#1812): fix deposit dialog handling in ZeroBalanceError

* feat(#1812): fix deposit and withdraw dialog e2e tests

* feat: market proposal selector - fix failing on develop e2e tests

* feat: market proposal selector - fix failing on develop e2e tests

* feat: market proposal selector - fix failing on develop e2e tests

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-11-16 15:10:17 +01:00
Matthew Russell
3077a634d1
fix(#1691,#2040): deal ticket validation (#2045)
* feat: update validation for size and price so they are reported simultaneously

* feat: adjust styles so error messages for price/size are rendered on one line

* fix: missing key in map error

* feat: split validation out on a field by field basis

* refactor: remove unnecessary price setting and just use props to calc market price

* refactor: rename setOrder func and add a comment

* chore: add type for form fields to allow for summary field

* fix: layout of market order size and price

* fix: casing of size/price in validation message

* refactor: fix type errors for summary react nodes and for tif and type validation

* feat: break out functions for testing market.state and market.tradingmode on submit

* fix: deal ticket test for last price value

* chore: remove unused files and move hooks and utils to correct dirs

* chore: tidy up constants

* fix: const before enum invalid syntax

* feat: dont block submission if not enough margin but do if zero balance

* chore: remove duplicated margin warning message

* feat: dont allow margin warning and error message to render at the same time

* feat: make trading mode check just a warning rather than error message

* test: make markets active so they are tradable, renaming describe blocks for clarity

* test: adjust test ids and disabled state and fix tests

* test: include AC codes in tests

* chore: remove click of in test as form is already dirty

* fix: lint errors, only show margin warning if you have balance

* chore: add ts ignore

* chore: re add use-order-validation hook for console-lite specifically

* chore: update use-order-validation test after consumed margin check hook changed

* fix: circular deps issue in console-lite

* chore: update use order validation hook to use Schema rather than direct import
2022-11-15 16:00:14 -08:00
Art
a3df65952d
feat: toast component (1677) (#1998) 2022-11-15 15:26:13 +01:00
Edd
e598cd1247
chore: update explorer to use v2 queries (#2049)
* fix: migrate queries to latest apis
* fix: remove oracles section for now
* fix: dive in to fields correctly
* fix: update queries
* fix: fragment for stats fields
* fix: rename triple underscore generated
* chore: refactor types that have moved
* chore(explorer): disable e2e test that asserts json structure
2022-11-15 12:31:25 +00:00
m.ray
b6df9a4219
chore(#1931): create single location for all external links (#1971)
* fix: #1826 fix vega docs links

* chore: #1931 create single location for docs links

* chore: #1931 token and wallet use react-helpers external links

* chore: #1931 rename links lib, delete unused links

* fix: #1931 environment links enforce url

* fix: #1931 fix staking-intro.spec.tsx

* fix: #1931 fix link on staking intro

* fix: don't use aliases for external links

* fix(#1931): restrict docsUrl type

* fix: fix withdrawals tests

* fix(#1931): fix staking and strading mode build

* chore: remove hardcoded docs urls and unnecessary type

* chore: remove stray DocsType link

* chore: add docs url to token e2e env

Co-authored-by: Matthew Russell <mattrussell36@gmail.com>
2022-11-14 15:41:56 -08:00
m.ray
ffa33634a9
fix(#2063): console liquidity tab keeps adding duplicate rows (#2069)
* fix: create custom ID for liquidity provision entries

* fix: #1931 rename is LP fragment

* fix(#2063): normalize numbers in lp table and rename isLpFragment
2022-11-14 21:17:26 +00:00
Bartłomiej Głownia
0c93023998
fix: remove useDataProviderHook updateOnInit (#2041)
* fix: fix useDataProviderHook updateOnInit

* chore: remove updateOnInit - always execute initial update in useDataProviderHook

* chore: remove useless variables param in useDataProvider update and insert callbacks

* chore: remove console.log
2022-11-14 16:08:12 +01:00
m.ray
f702df5ce5
fix: use estimate order query with simple order size, no open volume check (#2038)
* fix: use estimate order query with simple order size, no open volume check

* fix:  update console-lite-e2e to use stagnet3
2022-11-11 16:23:17 +00:00
m.ray
011ea97d23
fix: estimate order margin query asset decimal places fix (#2029)
* fix: estimate margin and fees update fix - use asset dp and normalize

* fix: update styling in fees breakdown component

* fix: fix cypress tests

* fix: format with asset dp only in react components

* fix: fix number formattingcd

* fix: remove comment

* fix: rename getMaximumDigitsNumberFormat

* fix: fix console-lite cypress tests
2022-11-11 14:44:53 +00:00
m.ray
e0b2fb9bf3
fix: deal ticket fees value formatting (#2014)
* fix: #2002 use asset dp for estimate order

* Update libs/deal-ticket/src/hooks/use-fee-deal-ticket-details.tsx

* fix: fix linting issue for format value with market dp
2022-11-10 12:09:32 -08:00
Art
0ec511a72f
feat: 1655 persist deal ticket, 1694 GTT in the past (#1865) 2022-11-10 19:06:10 +01:00
botond
df8a22a19e
chore: migrate withdrawals lib (#2009)
* chore: cleanup lib types

* chore: migrate withdrawals

* fix: withdrawals query and types

* fix: types

* fix: orders build

* fix: withdraws build

* fix: format

* fix: more build stuff in withdrawal lib

* fix: format

* fix: more withdrawal builds

* fix: format

* fix: orders build again

* fix: remaining build errors

* fix: format

* fix: withdrawal tests

* fix: trick git to pick up file rename?

* fix: rename back to orders

* fix: rename generated file
2022-11-10 14:13:58 +00:00
Matthew Russell
c576037b58
chore(#1873): trading hash router (#1921)
* chore: make liquidity page client side only

* chore: switch to hash based router

* chore: add index files for each page

* chore: tidy up _app

* chore: convert to use useRoutes

* fix: active state with react-router NavLink

* feat: add routes enum

* chore: restrict link and router imports from next

* chore: update testing navigation to use hash routes

* fix: typoe in eslint rule message

* chore: remove unnecessary getInitialProps function definition

* chore: wrap tests with memory router

* chore: delete unused index.page file

* chore: update suspense fallback state

* chore: add comment for link component span usage, update link to use toolkit styles

* chore: fix lint issues

* chore: delete client deposit page

* chore: revert title in _app so title gets set correctly without rerender

* revert: removal of deposit page so deposit e2e tests still pass

* chore: move client router to index page so valid status codes are still sent

* fix: wrong route path for markets page, cypress tests
2022-11-08 08:23:38 +01:00
m.ray
fe09ed9c0f
fix: #1826 fix vega docs links (#1967) 2022-11-07 18:12:40 +00:00
Art
7e52f25e27
chore: 1638 deposit flow (#1928) 2022-11-04 10:47:53 +00:00
macqbat
596c273657
Bug/1686 decimal issues with size and price (#1938)
* chore: fix order validation when market is in pending state

* chore: fix order validation when market is in pending state

* chore: fix order validation when market is in pending state

* chore: fix order validation when market is in pending state - add some urgent memo

* chore: fix order validation when market is in pending state - add unit test

* chore: fix order validation when market is in pending state - add memos in right places

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-11-03 15:17:44 +00:00
m.ray
769828a39d
Fix/1763 trade futures (#1948)
* feat: #1763 display the product type in select market lists

* fix: #1763 add on top of deal ticket button notice that you are buying product type contracts

* fix: #1763 remove message above deal-ticket button

* fix: #1763 left align product type title

* fix: #1763 header align left for product type
2022-11-03 12:57:06 +00:00
macqbat
0ee6773cb6
Feat/1657 show deal ticket errors contextually (#1900)
* feat: deal ticket contextual validation

* feat: deal ticket contextual validation

* feat: show deal ticket errors contextually

* feat: show deal ticket errors contextually

* feat: show deal ticket errors contextually

* feat: show deal ticket errors contextually - adjust int tests

* feat: show deal ticket errors contextually - adjust size and price sections

* feat: show deal ticket errors contextually - fix lin failings

* feat: show deal ticket errors contextually - use set timeout for create a transition effect

* feat: show deal ticket errors contextually - removing animations

* feat: show deal ticket errors contextually - reove unnecessary cast of section prop

* feat: show deal ticket errors contextually - reove unnecessary cast of section prop

* feat: show deal ticket errors contextually - add clickable order button, refactor error passing

* feat: show deal ticket errors contextually - fix market-info int tests

* feat: show deal ticket errors contextually - fix market-trade int tests

* feat: show deal ticket errors contextually - add back price after reset

* feat: show deal ticket errors contextually - remove reset after sent

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-11-02 16:45:23 +01:00
Matthew Russell
cd5f769c02
chore: adjust margin requirement spacing (#1922)
Co-authored-by: Madalina Raicu <madalina@raygroup.uk>
2022-11-01 18:45:30 +00:00
m.ray
3e970f7023
fix: 1875 & 1876 fix deal ticket fees display and remove insignificant trailing zeros (#1898) 2022-11-01 11:03:29 +00:00
m.ray
a90970399c
feat: 1651 market select snags (#1874)
* feat: #1651 market select snags

* fix: #1651 fix markets.cy.ts cypress test

* fix: #1651 prevent default and stop propagation on select markets asset click
2022-10-28 13:41:33 +01:00
macqbat
5ecf7d6a9f
Feat/1660 validate available margin (#1860)
* feat: deal ticket margin validation

* feat: deal ticket margin validation - working solution

* feat: deal ticket margin validation - add int test

* feat: deal ticket margin validation - improve int test

* feat: deal ticket margin validation - improve int test

* feat: deal ticket margin validation - fix unit test

* feat: deal ticket margin validation - improve case when no account

* feat: deal ticket margin validation - fix unit test

* feat: deal ticket margin validation - fix int test

* feat: deal ticket margin validation - fix int test

* feat: deal ticket margin validation - fix int test

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-10-27 20:12:03 +02:00
Art
633c2ae526
chore: updated order rejection reason mapping, types regen (1808) (#1845) 2022-10-25 11:07:54 +01:00
Bartłomiej Głownia
3bc9d3386b
chore: use queries from graphql file on orders lib (#1843) 2022-10-25 11:42:36 +02:00
Bartłomiej Głownia
17f93c2b7e
chore: add build-spec targets and execute on affected apps and libs on CI (#1745)
* chore: add build-spec targets and execute on affected apps and libs on CI

* chore: fix market-depth and react-helpers specs typings

* chore: fix ui-toolkit specs typings

* chore: fix trades specs typings

* chore: fix orders specs typings

* chore: fix deposits specs typings

* chore: fix deal-ticket specs typings

* feat: fix tsc on specs check

* feat: fix tsc on specs check

* feat: fix tsc on specs check

* feat: fix tsc on specs check

* feat: fix tsc on specs check - fix token app

* feat: fix tsc on specs check - fix positions lib

* feat: fix tsc on specs check - fix environment lib

* chore: fix failling build-spec in positions lib

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-10-25 09:41:16 +02:00
m.ray
4d20151abd
feat: 1537 LP view data provider subscriptions after 0.58 release (#1630)
* fix: #1537 add lp provider sub

* fix: change LP title & update party.id

* fix: #1537 fix obligation and supplied

* fix: #1537 add min width on accounts

* fix: #1537 consistent null check

* fix: #1537 update lp data providers

* fix:  add acounts data provider but requires party id

* feat: #1537 LP data provider -  marketID & query or subscribe for accounts - partyId

* fix: #1537 remove log and fix build

* fix: #1537 fix build console lite and lp dashboard

* fix: #1537 fix tsconfig lp dahsboard

* fix: #1537 use interval to poll LP data - sub not working yet
2022-10-24 20:42:53 +01:00
Bartłomiej Głownia
630ef4a22d
chore: add use throttled data provider hook (#1773)
* chore: add useThrottledDataProvider hook

* chore: add useThrottledDataProvider hook tests
2022-10-24 11:34:16 -07:00
Matthew Russell
d0976bbd46
Feat/522 close position (#1762)
* feat: use close position hook and dialog setup

* chore: update wallet tx interface for batch market instruction

* feat: add usage of data provider to show relevant order information

* feat: render correctly formatted values in close position dialog

* feat: make vega tx dialog more flexibly by allowing custom ui for every state of the tx

* feat: adjust text alignment and spacing between active orders and order to close

* feat: add unit tests

* chore: remove stray log

* chore: fix lint

* chore: ignore ts error for formatter function of vesting chart

* feat: split components up, memozie variables

* feat: add shared loading state to prevent content popping in

* feat: add time in force label

* feat: move transaction result hook to wallet lib

* feat: prevent being able to close vega tx dialog, must reject tx

* chore: add test for useTransactionResult hook

* chore: fix positiosn test after hook relocation

* Revert "feat: prevent being able to close vega tx dialog, must reject tx"

This reverts commit d1ecda69c3c55822bb042320f82b2e1c3833b99a.

* chore: add check for order edge to be defined

* chore: remove close callback

* feat: use tx result state to determine dialog state

* chore: update close position hook to check for transaction result

* fix: readd types tif selection persistance

* feat: convert order event func to be async, use it in close position for more result context

* fix: rename utils

* chore: adjust error language

Co-authored-by: Madalina Raicu <madalina@raygroup.uk>
2022-10-24 19:16:15 +01:00
m.ray
bf34f1c060
feat: 1486 add details of expected fees margin close out to deal ticket (#1771)
* fix: #1486 move deal ticket hooks from console-lite to be re-used in trading app for console v2

* fix: #1486 typo

* feat: #1486 deal ticket query update, console-lite fix

* feat: #1486 console-lite fix

* feat: #1486 initial hook to get fee details

* feat: #1486 add tooltips

* feat: #1486 add fees cell from market-info in tooltip

* fix: #1486 edit deal-ticket.spec.ts titles and index.ts of deal ticket hooks

* feat: #1486 move all hooks for slippage into deal ticket

* fix: #1486 fix linting deal-ticket issue

* fix: set price, fix NaN percentage, watch full order object

* fix: update only when market price is updated

* feat: #1486 add fees from est. order query, fees breakdown, fix BigNumber NaN issue

* feat: #1486 add fee factors in generate deal ticket query

* fix: #1486 show margin on short

* fix: #1486 format price and fix dal ticket use order margin import

* fix: #1486 fix price memo

* feat: #1486 update estimate ordr query with order price or mark price

* fix: #1486 revert apps/console-lite/.env

* fix: #1486 fix NaN value on close out

* fix: #1486 revert close out calculation

* fix: #1486 prevent NaN close out

* fix: #1486 revert close out

* feat: #1486 add fee factor percentages in tooltip and fix NaN

* fix: #1486 fix deal-ticket-steps est close out null handling

* fix: #1486 fix deal-ticket-steps est close out null handling

* fix: #1486 add tooltip for fees

* fix: #1486 fix console-lite formatting on notional size and close out

* fix: #1486 total fees formatting inside the hook

* feat: #1486 add qutote to fees tooltip

* fix: #1486 update hook, price, console-lite and styling

* chore: fix mock types

* fix: #1486 fix tests in console-lite

* fix: #1486 add declaration.d.ts to console-lite-e2e

* fix: #1486 fix deal ticket test

* fix: #1486 fix deal ticket test

Co-authored-by: Rado <szpiechrados@gmail.com>
2022-10-23 14:08:02 +01:00
macqbat
fbf21e9cb8
chore: fix for persist force value selection after change of order type (#1779)
* chore: fix for persist force value selection after change of order type

* chore: fix for persist force value selection after change of order type fix some int test

* chore: fix for persist force value selection after change of order fast fixes

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-10-20 09:01:01 +02:00
macqbat
c15765de79
chore: improve connect wallet button in deal ticket (#1793)
* chore: improve connect wallet button in deal ticket

* chore: improve connect wallet button in deal ticket

* chore: improve connect wallet button in deal ticket

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-10-20 08:41:02 +02:00
macqbat
1a539efdd6
feat: add connect vega wallet button to the deal ticket (#1768)
* feat: add connect vega wallet button to the deal ticket

* feat: add connect vega wallet button to the deal ticket - manage some int tests

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-10-18 17:59:17 +01:00
Radosław Szpiech
be9e1ee84b
Market page test refactor (#1741)
* fix: markets fixed test with new mock

* test: market summary tests refactored

* fix: fix undefined row.price issue

* chore: comments adressed

Co-authored-by: Madalina Raicu <madalina@raygroup.uk>
2022-10-14 10:15:34 +02:00
Radosław Szpiech
50df63c858
test: added tests to cover submit orders ac (#1708)
* test: added tests to cover submit orders ac

* fix: unit tests

* fix: mock subscription fixed

* fix: typo

* fix: lint

* fix(1593): remove ag-grid api presence check from providder update callbacks

* fix: unit tests

Co-authored-by: Bartłomiej Głownia <bglownia@gmail.com>
2022-10-12 09:55:23 +02:00
macqbat
0bb2e95091
chore: market header live update (#1672)
* chore: market header live update

* chore: market header live update

* chore: market header live update - adjust some mocks

* chore: market header live update - add single market query

* chore: market header live update - small fixes

* chore: market header live update - fix int tests

* chore: market header live update - fix int tests

* chore: market header live update - remove unnecessary props from query

* chore: market header live update - change concept - split for small comps

* chore: market header live update - small fix for mocks

* chore: market header live update - fix updates throttling

* chore: market header live update - improve update methods of data providers

* chore: market header live update - improve update methods of data providers

* chore: market header live update - improve update methods store for get rid of blinking

* chore: market header live update - fix title component

Co-authored-by: maciek <maciek@vegaprotocol.io>
2022-10-11 14:30:07 +02:00
m.ray
a71f40956b
fix: deal ticket estimated uncrossing (#1636)
* fix: invalid uncrossing price

* chore: align estimated uncrossing price with size label

* fix: 0 used balance on margin and bond accounts should not be displayed

* fix: small tweaks and bugfixes

* fix: filter empty acounts

* fix: fix unit test

* fix: fix unit test

Co-authored-by: Matthew Russell <mattrussell36@gmail.com>
2022-10-07 16:19:01 +01:00
Matthew Russell
1f8f54617b
chore: misc quick wins (#1596)
* fix: make sparkline appear after change cell

* fix: make price come after expiry in market header

* fix: refer to size rather than amount in validation

* fix: radio colors in light theme

* fix: remove orange border from vega tx pending state

* chore: combine deposit and withdraw buttons into single cell

* chore: update accounts table test, remove console warning from breakdown tests

* chore: update order validation test

* chore: place market table header in correct position

* chore: use actual change id to avoid clash

* fix: remove assertion in fills table that is flakey

* chore: render fills table with act

* fix: add a wait time for infura queries to resolve
2022-10-04 21:00:06 -07:00
Bartłomiej Głownia
a40f494a6f
chore: remove unused __generated__ files (#1599)
* chore: remove unused __generated__ files

* chore: change default env for type generation to testnet

* chore: fix import in assets data provider
2022-10-04 12:14:58 +02:00
Matthew Russell
4ed623c84c
feat#873): wallet service v2 (#1349)
* feat: update connect dialog to handle api v2

* feat: better error handling

* feat: update to only use strings for pubkey, add json rpc connector

* feat: make json connector follow same patterns as rest connector

* feat: add ability to change wallet location

* feat: add chain id fetch

* feat: improve types

* feat: adjust send tx types

* chore: remove dialog title and chain check temporarily

* feat: additional UI and error handling

* feat: rename keypair and keypairs to pubKey and pubKeys

* feat: make rest and json rpc connectors return consistent data

* feat: rename derived ids more clearly

* feat: update send_transaction response type

* chore: fix tests after context name change

* feat: add utils for wallet, add encode tx func

* feat: return null if tx is rejected

* feat: fix up styles for connect buttons

* feat: handle wallet version check

* feat: add chain id check

* chore: rename select pub key function to match, fix tests

* fix: tests for rest connector form

* feat: add tests for json rpc flow

* feat: connect dialog changes

* chore: change status to enum to avoid magic strings

* feat: add custom icons and handle provided key name

* chore: update global wallet connection e2d tests

* chore: change zod validation to only expected required values

* chore: ignore new generated code files

* chore: fix typos and add translations

* chore: set hosted wallet via env var and only show if not mainnet

* feat: add functionality for try again button

* test: fix failing tests

* chore: fix lint and test

* chore: remove double import

* chore: make console-lite-e2e strict so json connector compiles correctly

* chore: make token e2e tsconfig strict

* chore: make stats-e2e tsconfig strict

* feat: update json rpc request namespace

* feat: simplify connector setup, support try again

* chore: remove comment

* fix: build errors

* chore: make chainId check optional based on presence of appChainId, mock request for tests

* chore: mock chain id request for all apps on all pages

* fix: footer border on small screens

* fix: use beforeEach for chainId query mock

* chore: remove optional chain check, prevent rendering until fetch is complete

* chore: update NX_VEGA_WALLET_URLs as the application now appends the base path, adjust token tests

* fix: token e2e test that checks for pubkey name

* chore: remove duplicated test, update wallet title assertion

* fix: token tests

* fix: token e2e assertions

* fix: withdraw test

* feat: enable json RPC for token

* fix: sendTx command now accpets pubkey as separate arg

* fix: test to use gui option temporarily

Co-authored-by: Dexter <dexter.edwards93@gmail.com>
2022-10-03 11:12:34 -07:00