* fix(governance): special case bravo parsing
* fix(governance): explicitly parse U+2018, U+2026
* chore: upgrade ethers to ^5.4.6
Updates parseLog to delay parsing nested properties, so that they will only fail when accessed.
* fix(vote): recover from invalid UTF-8 in proposal descriptions
* fix(vote): special case bravo proposal newlines
* chore: rm dead reference
reconfigure service workers to only cache used assets (excluding .po language files and non-.var.woff2 font files)
* fix: turn service workers back on
* chore: configure service worker caches
* chore: add newline
* Fix code style issues with ESLint
* chore: limit service-worker caching
Co-authored-by: Zach Pomerantz <zzmp@uniswap.org>
Co-authored-by: Lint Action <lint-action@samuelmeuli.com>
* set up snapshot testing
* improvements
* add tests for TextInput as an example
* Fix code style issues with ESLint
* add comment to custom-test-env file
* only set up needed providers
* include style rules in snapshots
* disable redux storage warning
* added setupTests to avoid boilerplate
Co-authored-by: Lint Action <lint-action@samuelmeuli.com>
* feat: support connecting to a gnosis safe
* add the manifest.json attributes required by gnosis safe
* remove background fill
* copy
* only try injected provider if not active after trying safe
* initial routing api integration
* add routing api slice
* display route in dialog
* addressed pr feedback
* switch to `get`
* renamed useRouterTradeExactIn to useRouter
* moving few files to later iteration
* removed unnecessary `as`
* switch to polling
* add todo for blocknumber freshness
* remove account-slippage-deadline
* preliminary support
* fix multicall abi
add explorer support
* Fix code style issues with ESLint
* fix gas estimation
* fix todo tests
* fix gas estimation comments
* anonymize links to kovan etherscan and poll more frequently on optimistic kovan
* separate pool creation
* remove supported chain id
* remove the blocktag
* do not use the blocktag on optimism only
* give more gas to tokenURI for optimism
* update sdk
* temp fix to the block tag thing (do not update the block number from the fetch block number)
* remove unused import
* gasRequired -> multi-network
* bump quoter gas limit to 6m on optimism
* move the gas required parameter by chain id one level up
* missed a hook
* retry fetching receipts for optimism as many times as arbitrum
* fix duplicate enum, add optimism as well to retry options config
* fix: state not getting updated after a transaction confirmation
* bump sdk version
* update for mainnet optimism (#1998)
* fix for calculateGasMargin on optimism
Co-authored-by: Lint Action <lint-action@samuelmeuli.com>
Co-authored-by: Moody Salem <moody.salem@gmail.com>
* add hooks to fecth ticks data and active liquidity
* cleanup
* add polling interval
* moved ms.macro types to dev deps
* generate graphql schema on build
* added @types/ms.macro
* use clone deep
* build dynamic subgraph url based on chain id
* reset api state (query cache) on chain id change
* removed dependency on rtk-query/graphql
* add error message
* wrap sock around function component to get re-renders
* removed sourcelocale since we are using custom ids
* load locale data dynamically
* undo dev change
* ran yarn i18n:extract
* store locale in redux
* added support for redux
* restored header
* refactor
* addressed pr feedback
* specify type
* added navigator locale fallback to generic dialect
* make locale array const and typed
* addressed pr feedback
* fixed various
* addressed pr feedback
* make supported locales constant uppercase
* add back toUpperCase removed during refactoring
* removed lingui/detect-locale
* run yarn
* replaced i18next with lingui
* integrate lingui in i18n and update dev setup
* updated components to @lingui
* fix compile error after rebase
* detect locale
* add all previous languages to linguirc
* address pr feedback
* remove it for now
* ignore generate *js files, various fixes
* added more translations
* fixed yarn build command
* wrapped more hardcoded english around <Trans>
* finished second round of translations
* added support for pseudo-en locale
* improvements
* moved copy.tsx to different branch
* moved extra files to different branch
* regenerated po
* clean up
* more fixes
* regenerate po
* remove messages.js
* clean up
* addressed pr feedback
* regenerated po
* do not construct tokens for wrapped token info
* some cleanup of the wrapped token info
* back to extends, bump sdk core version via v2/v3 sdk updates
* Revert "back to extends, bump sdk core version via v2/v3 sdk updates"
This reverts commit 92cc5073
* update the sdk version
* fix some more uses of instanceof
* finish the refactor
* mess with the currency list performance
* start replacing with the latest v3/v2 sdks
* raw -> quotient
* more cleanup
* finish the refactor
* clean up currency list refactor
* fix list rendering
* perf(token lists): improve app performance when there are large inactive token lists (#1510)
* improve inactive token lists performance
* cleanup before larger changes to combine inactive lists
* only do the search if the query does not match any active lists, limit the number of results
* more performance improvements
* search inactive lists more aggressively
* Add App-level error boundary, referring users to GitHub issue creation on page crashes. (#1452)
* Class component is used as boundary since catching errors is apparently not yet possible with hooks.
* EventListener in window was removed and replaced by error boundary's error catch, which now fires a GA exception. The fields it passes are slightly different because React uses slightly different error types.
* Pre-filling issues with dynamic data is possible with POST requests to GitHub's API, but the GH web client seems to only support pre-fill based on templates. Therefore users still need to copy error info themselves.
* Prefill GitHub issues with crash data.
* Added package 'react-device-detect' to include device data such as OS, browser etc. in crash report.
* Included error stack in issue body.
* Used <code> html tag for displaying stack to user.
* Slightly reduce vertical padding on code block.
* Add ua-parser-js for parsing user agent.
* Revert react-device-detect to ^1.6.2 (which is used for mobile detection etc. in components)
* very rough positions/pools data fetching and position list rendering
* fix formatting
* fix loading
* position page routing, bug on add page
Co-authored-by: ianlapham <ianlapham@gmail.com>
* Update index.ts
* feature(service worker): add offline support (#1319)
* Revert "feature(service worker): add offline support (#1319)" (#1320)
This reverts commit 34dfb41a1e0a647596c5d37d5e3f7baa6c4005a3.
* Revert "Revert "feature(service worker): add offline support (#1319)" (#1320)" (#1321)
This reverts commit db3328c8d9d7ea7b7cf7e75dc658714798d007a4.
* unregisters all installed service workers (#1322)
* fix: modals stealing focus across frames (#1326)
* improvement(lists): add BA SEC tokens to unsupported list (#1327)
* show hidden search results by default
* update break styles
* optimize filter, use debounce on input
* increase debounce time
* add ba association list
* handle dismiss (#1328)
* split up sdk use between core and v2
* Fix code style issues with ESLint
* remove service worker
Co-authored-by: Moody Salem <moodysalem@users.noreply.github.com>
Co-authored-by: Jordan Frankfurt <jordanwfrankfurt@gmail.com>
Co-authored-by: Hyperion <72735936+moontools-hyperion@users.noreply.github.com>
Co-authored-by: Lint Action <lint-action@samuelmeuli.com>
* more list stuff
Use the selected list instead of the default list, but also use the default list
start list selection code
* move token warning to a modal, fix the install issue
* add/remove/enter key
* handle enter on currency select for ETHER
* change slippage tolerance to be a slider
* make ui closer to the mocks
* commit slider changes
* back to tabs
* copy changes
* bump list version
* some styling for the list select
* bump uniswap default list version
* use contract calls to get ens names and addresses
* show list logo
* fix failing integration test
* .eth.link
* list introduction screen
* remove showSendWithSwap
* fix integration and unit tests
* resolve ENS names
* logos from ens
* fix the lint errors
* some refactoring to better support using a the library provider from the user for resolving ENS names
* load list info from the list url for the introduction page
* make it slightly harder to remove a list
* minor clean up, some help text and links
* remove icon from list update popup
* show added/removed tokens
* add GA everywhere, don't debounce contenthash lookups
* show tags
* fix tag key
* tag display, list rendering, needs optimization
* fix list fetching in firefox, style issue in safari
* sort the lists, clean up styling
* use client provider when possible
* show token warning for url loaded tokens
* improve the warning modal
* some refactoring to fix the list fetching on networks other than mainnet
* fix tests
* some minor improvements
* increase timeout to maybe fix integration tests which pass locally
* build for tests using the dev network url
* reset the lists if we deleted the other two copies
* improve how we handle updating the default list of lists
* fix integration test
* Update token list selection styles
* fix external links, reuse the on click outside code, show add errors
* show the list origin instead of the full url
* fix update list link
* show host instead of hostname
do not automatically dismiss major version upgrades for lists
* fix link to tokenlists.org
* add uma
* clean up styling in list rows
* bump token list version
* bump token list version again
* hover symbol to see currency name
* bump version
* add cmc lists, dharma list
Co-authored-by: Callil Capuozzo <callil.capuozzo@gmail.com>
* move the gas estimation stuff into its own hook and report errors from the gas estimation
* fix linter errors
* show the swap callback error separately
* rename some variables
* use a manually specified key for gas estimates
* flip price... thought i did this already
* only show swap callback error if approval state is approved
* some clean up to the swap components
* stop proactively looking for gas estimates
* improve some retry stuff, show errors inline
* add another retry test
* latest ethers
* fix integration tests
* simplify modal and fix jitter on open in mobile
* refactor confirmation modal into pieces before creating the error content
* finish refactoring of transaction confirmation modal
* show error state in the transaction confirmation modal
* fix lint errors
* error not always relevant
* fix lint errors, remove action item
* move a lot of code into ConfirmSwapModal.tsx
* show accept changes flow, not styled
* Adjust styles for slippage error states
* Add styles for updated price prompt
* Add input/output highlighting
* lint errors
* fix link to wallets in modal
* use total supply instead of reserves for `noLiquidity` (fixes#701)
* bump the walletconnect version to the fixed alpha
Co-authored-by: Callil Capuozzo <callil.capuozzo@gmail.com>
* load tokens from url `useTokenList`
* improve performance of the loading
* move the loading to redux and save loaded lists
* lint error
* move the list fetching code to a separate component
* change how token lists are fetched to use the updater and add unit tests
* fix a crash with currencyEquals
* bump sdk version
* token lists should automatically update for minor/patch changes
* nit
* show popups for list updates
* support pointing at localhost
* spuport ipfs/ipns logos
* use the updater to bump list versions
* save the old/new list in the popup for viewing diffs
* improve the list popup
* fix linter error, make sure visibility checking is working
* show list update notifications
* address a couple metamask warnings, linter error
* fix the custom added/default tokens
* refactor some popup stuff to reuse the fader
* linter error
* Revert: refactor some popup stuff to reuse the fader (a7b0f752)
* style improvements, linter
* add to the readme, drop the token-request template
* back to the beta that works with wallet connect
* get the dependencies to a state that works with wallet connect and passes integration tests
* first pass of sdk 3.0
* second pass using weth
* kill unused pool popup
* get it compiling again
* first pass of sdk 3.0
* switch to currencies
* get it compiling after the big move merge
* restore margin
* clean up add liquidity more
* fix a bunch of bugs
* todo trade on v1
* show eth in currency list
* allow selecting eth in the swap page
* fix unit tests for swap page
* test lint errors
* fix failing integration tests
* fix another couple of failing unit tests
* handle selecting currency b when no currency a
* improve the import pool page
* clean up add liquidity for invalid pairs
* bold
* first pass at swap arguments for v1, some unit tests
* fix some bugs in add liquidity, burn hook
* fix last of ts errors in remove liquidity
* support wrapping/unwrapping weth
* kill a bunch of code including the dummy pairs
* required pair prop in the position card
* tests for the v1 swap arguments
* do not say estimated on the wrap ui
* show ETH instead of WETH in the pool summaries
* small size socks
* fix lint error
* in burn, use currencies from the URL
* fix some integration tests
* both contain weth
* receive eth/weth link
* fix empty row
* show wrapped only if one currency is weth
* currency selects in the remove liquidity page
* deleting some code first
* strict, some refactoring
* denser common bases
* more add liquidity refactoring
* add liquidity paths working
* show common bases in the token selects
* fix the ability to select duplicate tokens
* useless rename
* try to handle alllll the duplicate token edge cases
* think i got them all lol
* remove common bases header
* Revert "remove common bases header"
This reverts commit 6ac4565d
* fix and add integration tests
* make gap between rows smaller
* get integration tests actually running again
* try another format of the command, upgrade serve
* frozen lockfile on install
* try the cypress github action
* install cypress in ci
* remove redundant ignore-scripts command
* use a specific github commit for the pinata action
* fix a bug in the multicall reducer, improve token list rendering performance
* improve the enter key on the token search modal
* stop using history.push
* fix linting errors
* position card cleanup before updating to match mock
* initial refactoring
* rebase lint error
* start implementing reducer
* multicall reducer
* working multicall!
* clean up performance, re-fix annoying error
* use multicall everywhere
* use multicall for balances
* fix lint warning
* Use checksummed address
* Fix strict warning
* get it to a working state with the more generic form
* convert useETHBalances
* Remove the eth-scan contract completely
* Remove the eth-scan contract completely more
* Default export
* Put the encoding/decoding in the methods that can do it most efficiently
* Avoid duplicate fetches via debounce
* Reduce delay to something less noticeable
* Return null if pair reserves are undefined to indicate it does not exist
* Search modal performance improvements
* Move more code out of the search modal
* Add the question helper to the search
* Fix a couple lint errors
* Fix the tests, duplicate import text
* Hide the token info on small screens, flex the list
* Fix token sorting, have a link that focuses and shows a tooltip for the search input
* Remove reach tooltip css
* Fix pair balances in the search modal
* Get the arrow working
* Only clear the input when they re-open
* Better way to exclude props
* More small performance tweaks
* Part 1, separate swap and send, move duplicate code into separate files
* Move some more constants out of the swap/send
* Support defaults from URL parameters
* Implement query string parsing via a redux action
* Finish merging the changes
* Fix the slippage warnings
* Clean up some other files
* More refactoring
* Move the price bar out of the component
* Move advanced details and some computations into utilities
* Make same improvements to send
* Approval hook
* Swap page functional with swap callback hook
* Swap/send page functional with swap callback hook
* Fix lint
* Move styleds.ts
* Fix integration test
* Fix error state in swap and move some things around
* Move send callback out of send page
* Make send behave more like current behavior
* Differentiate swap w/o send on send page from swap w/o send on swap page
* Remove userAdvanced which was always false
* Remove the price bar which is not used in the new UI
* Delete the file
* Fix null in the send dialog and move another component out of send
* Move the swap modal header out to another file
* Include change after merge
* Add recipient to swap message
* Keep input token selected if user has no balance and clicks send with swap
* Move the modal footer out of send component
* Remove the hard coded estimated time
* Fix the label/action for swap/sends
* Share the swap modal footer between swap and send
* Fix integration test
* remove margin from popper to suppress warnings
fix missing ENS name recipient link
default deadline to 15 minutes
* ensure useApproveCallback returns accurate data
* clean up callbacks
* extra space
* Re-apply ignored changes from v2 branch ExchangePage file
Co-authored-by: Noah Zinsmeister <noahwz@gmail.com>
* Create the wallet store
* Get the updater completed
* Code complete
* Fix token balance bug
* Fix another bug in the hooks
* Final bug fix, blockNumber can be undefined
* Formalize the fact that block number can be undefined
* Woops add package
* Add more info to errors
* Replace balances in the v1 methods with the new ones
* Only return a balance value if it's present
* Address comments
* Trigger updateVersion before anything else
* Rewrite the local storage context into a redux store for user data
* Separate out the mega methods
* Fix infinite loop
* Missing dependency
* Missing dependency, rename version field
* Introduce redux for one of the state stores
* Remove unused state
* Clean up hooks
* Add types for react-redux and fix error from any type on useSelector
* Strongly type the web3 provider
* Make the popup content into a POJO
* Lint errors
* Clean up method call
* Fix lint error
* Fix lint error
* Lint
* remove duplicated prettier from dependencies
* use swr for allowances
* slight improvements to error cascading
* fetch totalsupply with SWR
fetch pairs with SWR (except persistent pairs, will be refactored later)
* fix lint error
* stop using pair context, instead store per-user pairs in local storage
* add more pairs to the default list
remove unnecessary isWETH
fix lint error
* add more bases to trade consideration
* fix lint warnings
* get SWR data on same schedule
* don't pass value if it's 0
fix WETH equality checks
* clean up fixed/significant formatting
* fix slippage calculation bug in swap
add slippage to remove
* fix token logos
* show fewer sig figs
* lint error
* remove unused signer
* add calculateSlippageAmount safety check and tests
* fix useAllBalances type
stop spuriously sorting token amounts of different tokens
use slightly better comparisons for slippage calculations
* improve priceSlippage comparison logic
* useReserves -> usePair
* use checksum for DAI logo address
* Add some basic integration tests and CI in GitHub
* Add push trigger
* Add badge for tests to readme
* Unit tests
* Just use the development infura URL in the tests
* Remove unused webpack config
* Make integration test run on the same port as yarn start
* make test a little bit better
* rename describe