1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-10-22 19:26:13 +02:00
Commit Graph

160 Commits

Author SHA1 Message Date
Niranjana Binoy
6e5c2f03bf
Token detection V2 Flag Removal and Re-introducing the use of legacy token list when token detection is OFF (#15138)
* addding the legacy tokenlist, tuning token detection OFF by default, adding new message while importing tokens

updating the controller version and calling detectNewToken on network change

fixing rebase error

Run yarn lavamoat:auto for updating policies

updating lavamoat

Deleted node modules and run again lavamoat auto

fixing rebase issues

updating lavamoat policies

updating lavamoat after rebasing

policies

updating custom token warning and blocking detectedtoken link when tpken detection is off for supported networks

to update the token in fetchTosync

updating the contract map object

Revert build-system lavamoat policy changes

Move token list selection logic from components to getTokenList selector

updating the tokenList

Update lavamoat

Fix error

updating lavamoat

lint fix

fix unit test fail

fix unit test fail

lint fix

fixing rebase locale error

rebase fix

Revert build-system policy changes

temp

addressing review comments

* rebase fix
2022-08-09 22:56:25 -02:30
Tommaso Maioli
d21a8a1cfb
docs: addition of controls and readme in SelectQuotePopover story (#15187)
* docs: addition of controls and readme in SelectQuotePopover story

* Content update

Co-authored-by: georgewrmarshall <george.marshall@consensys.net>
2022-08-09 16:48:48 -05:00
Daniel
d255fcdefb
Only check if a user has enough token balance before calling STX (#15218) 2022-08-09 12:56:52 -05:00
George Marshall
0692f7bf25
Updating content to sentence case and updating tests (#15285) 2022-08-08 12:01:38 -07:00
George Marshall
cdc0fed828
Update media query instances (#15068) 2022-08-04 09:03:02 -05:00
Brad Decker
c72199a1a6
update prettier (#15360) 2022-07-31 13:26:40 -05:00
Daniel
f31bac9fbf
Performance improvements for Swaps (#15359) 2022-07-28 15:56:15 +02:00
Nidhi Kumari
7424e98416
Updated all instances of "Component API" to "Props" in storybook documentation (#15324)
* replaced Component API with Props

* replaced Component API with Props in DOCUMENTATION.stories.mdx

* removed base avatar component
2022-07-27 00:22:40 +05:30
Brad Decker
1db0ee87ec
Update Eslint and deps (#15293) 2022-07-26 13:10:51 -05:00
Nidhi Kumari
2e6f579ee5
Converted BuildQuote story to use controls and action argType (#15234)
* added build quote component

* fixed updated test-data to use Rinkeby instead of ropsten
2022-07-22 12:14:35 +05:30
George Marshall
5592687df1
Updating design tokens package and shadow values with new tokens (#15264)
* Updating design tokens v1.8 and shadows

* Adding missing stories

* Some fixes and updates to css and stories

* removing unneeded story

* Fixing story order
2022-07-21 15:43:31 -07:00
George Marshall
05a20bb721
Add responsive props to Box component (#15106)
* Adding responsive props to Box component

* Updating margin array prop instances

* Updating padding array prop instances

* Updates to docs, tests and margin, padding instances

* Optimizing class name object

* Simplifying single value logic

* replacing for loop with switch statement

* Memoizing generateClassNames function
2022-07-20 13:47:51 -07:00
Alex Donesky
09164dcabb
Bump controllers v30.0.2 (#14906)
* bump @metamask/controllers to v30.0.2 and adapt
2022-07-18 09:43:30 -05:00
Daniel
2744eaf760
Update the "results" state if "initialResultsState" array length is different (#15270) 2022-07-18 16:30:36 +02:00
Daniel
75ac87e487
Show a block explorer URL hostname, hide token import if block explorer URL is not available (#15198) 2022-07-13 18:42:50 +02:00
Daniel
8cbfa2ea9e
Show a tx link and the "create a new swap" link for STX (#14995) 2022-07-11 17:53:07 +02:00
Daniel
5fa88bebce
Show how much a cancellation of a smart transaction will cost (#15011) 2022-06-22 18:58:51 +02:00
George Marshall
051254dffd
Fixing tooltip theming by enforcing default theme (#14992)
* Fixing tooltip theming by enforcing background color

* Removing wide prop
2022-06-21 09:50:44 -07:00
daniba
085126d275
Move search icon and add to storybook (#14940)
* move search icon || update imports || add to story

* Optimized svg path, updated icon api and updating colors

* update other icons

* update snapshot

Co-authored-by: georgewrmarshall <george.marshall@consensys.net>
2022-06-21 10:18:35 -05:00
Daniel
ebf967562b
Remove experimental gas editing for Swaps (#14942) 2022-06-15 21:08:13 +02:00
Jordon
f5c6d0054f
Convert knobs and actions to controls/args for MainQuoteSummary (#14758)
Co-authored-by: George Marshall <georgewrmarshall@gmail.com>
Co-authored-by: Brad Decker <bhdecker84@gmail.com>
2022-06-15 10:43:26 -05:00
Daniel
b0557daa05
Handle an RPC provider delay in Swaps (#14821)
* Return an estimated amount for a completed swap if an RPC provider has a delay

* Create a recursive function for updating post tx balance

* Add a few tests for the "getSwapsTokensReceivedFromTxMeta" fn

* Trigger Build
2022-06-08 16:32:04 +02:00
Daniel
9705531671
Reduce the default slippage from 3% to 2% (#14863) 2022-06-07 18:28:59 +02:00
Daniel
bd5d47993d
Make content changes for the STX status page, remove old content (#14805) 2022-06-07 15:42:25 +02:00
Daniel
6dbb2c4ded
Migrate the "estimateGas" API call to "getFees" for STX (#14767) 2022-05-26 19:56:28 +02:00
George Marshall
8fcbebc546
Update design tokens library from 1.5 to 1.6 WIP (#14732)
* Updating account menu icon color

* Updating design-tokens and making appropriate updates to extension styles

* Adding more deprecated tags to colors

* Adding spinner and removing todo comment

* Remove comment

* Updates

* Updating snapshots

* More color and ui updates

* reverting transition change
2022-05-25 08:35:36 -07:00
Daniel
f6576801d4
Fix an edge case with missing top assets in Swaps (#14688)
* If there is no array of top assets in a response, use an empty array

* Set a default empty array for 2 functions, remove an unnecessary condition

* Redirect a user from Swaps to the homepage if they switch to a chain that is not supported in Swaps

* Fix errors in the UI Console when it's not a swaps chain
2022-05-24 18:30:46 +02:00
Thomas Huang
11831c6ae5
Add hideEstimatedGasFee prop to sort-list and select-quote-popover tests (#14725) 2022-05-19 10:43:31 -07:00
Daniel
d305dcba9d
Change styles for the high price impact notification in Swaps (#14697) 2022-05-12 19:57:05 +02:00
Daniel
9a153d2388
Remove gas editing in Swaps (#14673)
* Remove gas editing in Swaps

* Remove "extraApprovalGas"
2022-05-11 20:30:03 +02:00
Daniel
2bd7127433
Swaps / STX improvements (#14622) 2022-05-09 18:48:14 +02:00
Daniel
9daab6aa59
Disable STX if a regular tx is in progress (#14554)
* Disable STX if a regular tx is in progress

* disableStxIfRegularTxInProgress : early return

* Fix UTs

* Trigger Build
2022-05-03 17:55:41 +02:00
Ariella Vu
78f4684b2a
MetaMetrics: Add EVENT.CATEGORIES const (#14474)
* MetaMetrics: add EVENT.CATEGORIES const

* MetaMetrics: add EVENT.CATEGORIES.INPAGE_PROVIDER

* MetaMetrics: add EVENT.CATEGORIES.AUTH

* MetaMetrics: add EVENT.CATEGORIES.ACCOUNTS pt. 1

* MetaMetrics: add EVENT.CATEGORIES.ACCOUNTS pt. 2
confirm we want to use 'Accounts' instead of 'Account'

* MetaMetrics: add EVENT.CATEGORIES.MESSAGES

* MetaMetrics: add EVENT.CATEGORIES.RETENTION const

* MetaMetrics: add EVENT.CATEGORIES.SETTINGS

* MetaMask: add missing EVENT.CATEGORIES.SNAPS

* MetaMetrics: add EVENT.CATEGORIES.WALLET const

* MetaMetrics: add EVENT.CATEGORIES.ONBOARDING const

* MetaMetrics: add EVENT.CATEGORIES.ONBOARDING
& EVENT.CATEGORIES.TRANSACTIONS consts

* MetaMetrics: use EVENT.CATEGORIES

* ducks/swaps: revert slice name

* MetaMetrics: add missing EVENT.CATEGORIES.NETWORK
2022-04-22 13:09:10 -03:00
Daniel
eed6ae2b8c
Swaps: Sort "token_from" dropdown tokens by their fiat value first and "token_to" by top tokens (#14436) 2022-04-15 14:57:58 +02:00
George Marshall
9ce966ba1d
Storybook housekeeping 🧹 (#14331)
* Removing argTypes that are related to static props and don't have anything to do with the component. Also some general house keeping

* updates
2022-04-07 08:14:22 -07:00
Daniel
fc17fbe1ad
Swaps timer improvements, optional refresh rates and fix for a notification UI (#14300)
* Set up correct timer value for fetching new quotes

* Show red timer in Swaps if quotes fetching will happen in less than 10s (previously it was 30s)

* Fix a UI issue with the notification close button

* Make stx refresh rates optional, since not every network supports them
2022-04-04 15:14:50 +02:00
George Marshall
dfd3e233e8
color fix for hover on swaps quote (#14334) 2022-04-02 06:40:33 -07:00
filipsekulic
8cb1f4af2e
Renamed metametrics.new.js to metametrics.js (#14327) 2022-04-01 14:11:12 -05:00
Pieter Tolsma
cb1890d928
Convert knobs and actions to controls/args for CountdownTimer (#14222)
Co-authored-by: Pieter Tolsma <pietertolsma@Pieters-MacBook-Air.local>
2022-03-31 13:31:31 -05:00
George Marshall
4bb2582200
Swaps select quote highlight fix (#14270) 2022-03-31 08:58:09 -05:00
David Walsh
00025afe4c
Dark Mode: Remove unwanted background for price quote (#14278) 2022-03-30 15:42:18 -07:00
David Walsh
9d7f4d2005
Ensure proper color for swaps edit link (#14273) 2022-03-30 14:54:25 -07:00
ryanml
085c9753de
Ensure Metafox follows cursor on Fetching quotes screen (#14261) 2022-03-30 10:54:01 -07:00
BoxedFruits
950de390b3
GasModalPageContainer story: convert knobs and actions to controls / args (#13516) 2022-03-30 08:46:37 -05:00
Daniel
69d7c51c56
Show STX switch for wrapping / unwrapping (#14225) 2022-03-30 10:02:55 +02:00
Jurriaan Den Toonder
1521e63913
Change over FeeCard stories to use controls instead of knobs, update props in stories (#13766)
This PR changes over the deprecated knobs and actions in `fee-card.stories.js` to controls.
I attempted to create a `README.mdx`, but unfortunately the `<ArgsTable of={FeeCard} />` refused to render out any of the documentation comments I added to the `FeeCard.propTypes`, thus that has not been included (and no documentation has been added to the propTypes of FeeCard).

_Please note:_ currently nested arg types are not possible in StoryBook, but discussions are open: https://github.com/storybookjs/storybook/issues/11486. This means that the StoryBook shows `primaryFee`, `primaryMaxFee`, `secondaryFee` and `secondaryMaxFee`, but these are mapped to the 2 `primaryFee` and `secondaryFee` props of the component. This is visible if the developer clicks on the `Show code` button at the docs page in StoryBook.

Signed-off-by: Jurriaan Den Toonder <1493561+Fastjur@users.noreply.github.com>
2022-03-29 16:13:00 -06:00
Daniel
7cb22bd883
metaMetricsEvent -> trackEvent (#14249) 2022-03-29 19:19:40 +02:00
Guillaume Roux
a3ab204d11
Dark Mode: Fix some colors (#14228)
* fix some colors

* fix test and address requested changes

* address requested changes
2022-03-28 10:23:27 -07:00
Guillaume Roux
a7ac83f9d3
Dark Mode: Swap hex colors in ui/pages (#14214)
* swap hex colors in ui/pages

* update snapshots
2022-03-25 15:15:31 -07:00
Guillaume Roux
57818fabbe
Dark Mode: Remove ui colors (#14184) 2022-03-25 10:07:47 -05:00