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

2446 Commits

Author SHA1 Message Date
Dan J Miller
6409caa081
Use initial transaction for settings swap transaction title params (#9543)
* Use initial transaction for settings swap transaction title params, and remove addition of swap properties to cancel transcations

* Update unit test data

* Use token symbol properties from initial transaction for filitering in transaction list
2020-10-10 17:20:20 -02:30
Thomas Huang
ac8f673716
Overflow primaryCurrency in tx-list-item & use primaryCurrency for tx breakdown details. (#9539)
* Set result of calcTokenAmount to base 10 string in useTokenDisplayValue

* Use primaryCurrency for amount in transaction breakdownd details

* Hidden overflow and text overflow ellipsis on long primary currency in transaction-list-item

* Empty prefix for token approvals

* Conditional render primaryCurrency title in tx breakdown to `Spend limit amount` when tx is a token approve.

* Add title to primaryCurrency in tx list item to show full amount on hover

* Update ui/app/components/app/transaction-breakdown/transaction-breakdown.component.js

DRY title conditional rendering.

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2020-10-09 13:11:39 -07:00
Dan J Miller
436b01387c
Add useSwapsEthToken hook and utilize wherever we need the ETH 'token' for swaps (#9537)
* Add useSwapsEthToken hook and utilize wherever we need the ETH 'token' for swaps
* Remove rawEthTokens param from useTokensToSearch calls

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
Co-authored-by: Erik Marks <rekmarks@protonmail.com>
2020-10-09 12:17:56 -07:00
David Walsh
a301ce92d8
Prevent duplicate increment/decrement buttons in Firefox (#9523)
Fixes #9516
2020-10-08 14:53:14 -02:30
Mark Stacey
305e3ceb2e
Fix retry transaction button tooltip (#9524)
The tooltip for the Retry Transaction button would be erroneously set
to display a custom block explorer, if one was set for the current
network. It now displays the intended retry transaction text in all
cases.
2020-10-08 14:30:41 -02:30
Dan J Miller
e389ad98af
Hide activity list retry button for failed swaps transctions (#9513) 2020-10-08 11:41:05 -02:30
Mark Stacey
cdfa2e66fd
Hide retry button for on-chain failures (#9506)
On-chain failed transactions have a transaction status of `confirmed`,
and should not be retried. Our retry function doesn't handle on-chain
failures yet, so it would inevitably fail due to the transaction having
the same nonce as a confirmed on-chain transaction.

When determining whether to show the retry button in the UI, we had
mistakenly been using a `status` variable that determined whether we
should show "Failed" on that transaction in the activity log. That
display status includes both network and on-chain failures, unlike
the `txMeta.status` property.

The `showRetry` logic has been updated to ensure it's only shown when
`txMeta.status` is `failed`, meaning on-chain failures will no longer
show the retry button. Additionally, the display-specific `status`
variable has been renamed to `displayedStatusKey`, to indicate that it
is a string that corresponds to a localized message, and that it's the
status meant for display purposes.
2020-10-07 14:59:38 -07:00
Erik Marks
46bcba2d63
Fix IconButton prop type (#9489)
* Fix IconButton prop type
2020-10-06 14:09:12 -07:00
Dan J Miller
94810ce9c9
Compare the networkId against the correct enum in eth and token overview components (#9485) 2020-10-06 17:34:53 -02:30
Dan J Miller
30d13422b5
Add MetaMask Swaps (#9482) 2020-10-06 15:58:38 -02:30
Erik Marks
088d4c34f1
Merge pull request from GHSA-c2xw-px2x-pr65
* Remove network config store
* Remove inline networks variable in network controller
* Re-key network controller 'rpcTarget' to 'rpcUrl'
* Require chainId in lookupNetwork, implement eth_chainId
* Require chain ID in network form
* Add alert, migrations, and tests
* Add chainId validation to addToFrequentRpcList
* Update public config state selector to match new network controller
state
* Use network enums in networks-tab.constants
* Ensure chainId in provider config is current
* Update tests
2020-10-06 15:27:02 -02:30
Brad Decker
e75bfc4dbc
remove-unused-component (#9457) 2020-09-23 13:11:22 -05:00
Brad Decker
37cbeb56a3
make gas edit tooltips use Tooltip (#9434) 2020-09-17 17:05:31 -05:00
Thomas Huang
ee6e986f59
Fix dismiss button css on unconnected alert modal (#9430)
* Fix dismiss button on unconnected alert modal

Set button type to primary, rounded, and set `!important` on css class width

* Update ui/app/components/app/alerts/unconnected-account-alert/unconnected-account-alert.scss

* Add unconnected-account-alert to popover component classname to simplify css selector.

Co-authored-by: Brad Decker <git@braddecker.dev>
2020-09-17 13:23:37 -07:00
Erik Marks
550e49a64c
Gas modal styling fixes (#9433) 2020-09-17 13:02:00 -07:00
Brad Decker
c6a540419c
fix styles on tx detail popover buttons (#9432) 2020-09-17 12:12:42 -05:00
Brad Decker
f4a2a09713
increase specifity of button style overrides on notifications (#9427) 2020-09-17 09:08:02 -05:00
Thomas Huang
6f0a16a0e8
Fix button with on Deposit Ether / Buy Screen (#9424) 2020-09-16 12:42:11 -07:00
Brad Decker
86adca8486
Fix dropshadow permissions page (#9413) 2020-09-15 15:20:58 -05:00
Brad Decker
c97493cc13
rename Ethereum Main Network -> Etherum Mainnet (#9411) 2020-09-15 14:34:16 -05:00
Brad Decker
0c2404c6d7
fix button spacing on activity list (#9410) 2020-09-15 14:33:49 -05:00
Brad Decker
ed28591b62
fix link regression (#9408)
Co-authored-by: Erik Marks <25517051+rekmarks@users.noreply.github.com>
2020-09-15 13:03:05 -05:00
Dan J Miller
6b08ca428b
Fix left border of the first button in the gas price button group of the gas customization modal (#9406) 2020-09-15 12:52:39 -02:30
Mark Stacey
b80ab53396
Add radiogroup ButtonGroup variant (#9383)
Add a prop to the `ButtonGroup` component to make it act as a group of
radio buttons, rather than a group of regular buttons. These commits
were written by @danjm - I just pulled them into this branch.
2020-09-10 13:08:38 -03:00
Whymarrh Whitby
1e99a7b0c3
Migrate to scoped @metamask/jazzicon (#9341) 2020-09-02 12:37:56 -02:30
Whymarrh Whitby
9a711e695a
Fix lookAtDirection prop passed to Mascot (#9343) 2020-09-02 12:37:39 -02:30
Thomas Huang
a3f9e6d37b
Show token symbol when token amount string is long (#9333)
* Show token symbol when token amount string is long

Fixes #9318

This essentially separates the token cell list item title/token amount and the token symbol.
I do request advice/recomendations on how to better handle the new `subTtitle` which I set the token symbol to and the `subtitle` https://github.com/MetaMask/metamask-extension/blob/develop/ui/app/components/app/asset-list-item/asset-list-item.js#L99.

* Individually test token balance and token symbol and their associated css element

* Feedback commit

* Classname and css overflow for title with string.
2020-09-01 13:13:58 -07:00
Thomas Huang
79d477009e
Use verifyPassword instead of submitPassword when exporting priv key (#9288)
* Use verifyPassword instead of submitPassword when exporting priv key

Fixes #9287 which was when submitPassword is called will fully clear the keyring state

https://github.com/MetaMask/KeyringController/blob/master/index.js#L155
ad823d0ac1/index.js (L562)
ad823d0ac1/index.js (L726)

Also, pass hideWarning action prop so it will clear the appState.warning if a correct password is never provided on componentWillUnmount

* Hide Warning on componentWillUnmount

* Update exportAccount tests to verifyPassword

* Update ui/app/store/actions.js
Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2020-08-26 16:19:41 -07:00
Erik Marks
e08a55c8bc
Add messages for MetaMetrics opt-in (#9283)
* Add messages for MetaMetrics opt-in
2020-08-20 17:13:14 -07:00
Erik Marks
02d318d493
Add @metamask/logo (#9281)
* Remove metamask-logo
2020-08-20 10:48:43 -07:00
Dan J Miller
42f4c2e407
MetaMask mascot support for provided directions targets and toggling followMouse (#9166)
* MetaMask mascot support for provided directions targets and toggling followMouse

* Fixes for mascot.component.js

* Update metamask-logo version to 2.4.0

* Lint fix

* Fix mouse follow updating

Co-authored-by: Mark Stacey <markjstacey@gmail.com>

* Improve mascot story name

Co-authored-by: Mark Stacey <markjstacey@gmail.com>

* Update package.json

Co-authored-by: Mark Stacey <markjstacey@gmail.com>

* Lint fix

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2020-08-20 05:29:03 -02:30
Thomas Huang
5f11273550
Add react-testing-library/react (#9249)
* Add react-testing-library

Adds react-testing-library as a dependency, creates a wrapper function with Provider store/I18n context support, and implements it in unconnected-account-alert.

* Refactor renderWithProvider store to extra param, instead of component prop store
2020-08-19 21:13:59 -07:00
Brad Decker
a04ec49a57
remove unnecessary files and scss (#9253)
this moves very little code around, to enable deleting files that are
no longer used or necessary. There are a few more things to move and
delete that will be handled in a seperate PR after this one.
2020-08-19 16:02:42 -05:00
Brad Decker
cfff01164a
Reuse the loading-screen component and colocate it's styles (#9177) 2020-08-19 16:02:26 -05:00
Brad Decker
c04cb63c63
Standardize scss import practices (#9183) 2020-08-19 11:41:56 -05:00
Whymarrh Whitby
b6ccd22d6c
Update ESLint shared config to v3 (#9274)
Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2020-08-19 13:57:05 -02:30
Patryk Łucka
9a3c559b3d
Hide gas estimate on non-main network (#9189)
* hide advance gas on non mainnet

* hide edit gas button on non mainnet
2020-08-19 11:03:15 -03:00
Dan J Miller
a8199be553
Move the mascot component to its own directory (#9272) 2020-08-19 11:23:44 -02:30
Whymarrh Whitby
6ab12001e3
Fix prefer-destructuring issues (#9263)
See [`prefer-destructuring`](https://eslint.org/docs/rules/prefer-destructuring) for more information.

This change enables `prefer-destructuring` and fixes the issues raised by the rule.
2020-08-18 17:36:58 -02:30
Dan J Miller
09e7f24b2d
Adds pulse loader component (#9259)
* Adds pulse loader component

* Move pulse-loader component to the UI directory
2020-08-18 16:53:36 -02:30
Whymarrh Whitby
c1e3c229bc
Fix import/order issues (#9239)
See [`import/order`](https://eslint.org/docs/rules/import/order) for more information.

This change enables `import/order` and fixes the issues raised by the rule.
2020-08-18 16:48:25 -02:30
Whymarrh Whitby
b7259e5d6a
Fix radix issues (#9247)
See [`radix`](https://eslint.org/docs/rules/radix) for more information.

This change enables `radix` and fixes the issues raised by the rule.
2020-08-18 16:38:22 -02:30
Dan J Miller
eb653dfb6e
New info tooltip component (#9180)
* Add info-tooltip and associated storybook stories

* Allow tooltip-v2 to support react-tippy themes

* Update info-tooltip to use tooltip-v2
2020-08-18 15:45:22 -02:30
Whymarrh Whitby
4357cda7b8
Fix no-shadow issues (#9246)
See [`no-shadow`](https://eslint.org/docs/rules/no-shadow) for more information.

This change enables `no-shadow` and fixes the issues raised by the rule.
2020-08-18 14:06:45 -02:30
Brad Decker
d5a539e0e5
remove old tooltip component and styles (#9250)
The old tooltip component was only used in two places. Removing those usages
was simple and straight forward. So, instead of colocating the old tooltip
styles with the deprecated tooltip component, I removed all old styles and
made tooltip-v2 now simply 'tooltip' and removed the deprecated component.
2020-08-18 11:13:55 -05:00
Patryk Łucka
f7e4e209ef
move footer buttons to scrollable area (#9228)
Co-authored-by: Patryk Łucka <patryk.lucka@consensys.net>
2020-08-18 09:10:56 -05:00
Brad Decker
2e565d02b2
Removes the dropdown menu and colocates old styles with account-menu (#9185)
The only place that these .menu styles were being used was the account-menu by way of components/app/dropdowns/menu. Because account-menu is the only place that used these styles I moved them to exist with the account-menu
2020-08-18 09:09:56 -05:00
Whymarrh Whitby
e803807dd9
Fix no-param-reassign issues (#9235)
See [`no-param-reassign`](https://eslint.org/docs/rules/no-param-reassign) for more information.

This change enables `no-param-reassign` and fixes the issues raised by the rule.
2020-08-15 09:28:11 -02:30
Thomas Huang
87e5281a82
Clear Account Details in AppState (#9238)
* Clear Account Details in AppState

We store sensitive information in the AppState under accountDetail for when the modal is active and present. This adds a new action/reducer and componentWillUnmount to clean up the persisted data left after leaving the modal.

* Remove reduntant clearAccountDetails call when clicking done button
2020-08-14 16:08:26 -07:00
Whymarrh Whitby
04bfe3772c
Delete page-container.component.test.js (#9229) 2020-08-14 12:52:38 -02:30
Whymarrh Whitby
2aa4b6bbee
Tidy up getAccountLink (#9223) 2020-08-14 12:31:59 -02:30
Whymarrh Whitby
5d42a9b773
Fix require-unicode-regexp issues (#9212)
* Fix require-unicode-regexp issues

See [`require-unicode-regexp`](https://eslint.org/docs/rules/require-unicode-regexp) for more information.

This change enables `require-unicode-regexp` and fixes the issues raised by the rule.

* Remove case-insensitive flag from regexps
2020-08-14 09:18:42 -02:30
Whymarrh Whitby
884775cf71
Fix no-negated-condition issues (#9222)
See [`no-negated-condition`](https://eslint.org/docs/rules/no-negated-condition) for more information.

This change enables `no-negated-condition` and fixes the issues raised by the rule.
2020-08-14 09:17:43 -02:30
Whymarrh Whitby
c11888f287
Fix no-empty-function issues (#9216)
See [`no-empty-function`](https://eslint.org/docs/rules/no-empty-function) for more information.

This change enables `no-empty-function` and fixes the issues raised by the rule.
2020-08-14 09:17:02 -02:30
Whymarrh Whitby
9b78d3ab07
Fix import/extensions issues (#9217)
See [`import/extensions`](https://eslint.org/docs/rules/import/extensions) for more information.

This change enables `import/extensions` and fixes the issues raised by the rule.
2020-08-14 09:16:45 -02:30
Whymarrh Whitby
42e7d205b2
Fix no-dupe-else-if issues (#9208)
See [`no-dupe-else-if`](https://eslint.org/docs/rules/no-dupe-else-if) for more information.

This change enables `no-dupe-else-if` and fixes the issues raised by the rule.
2020-08-12 21:22:02 -02:30
Whymarrh Whitby
cd370be728
Fix no-invalid-this issues (#9207)
See [`no-invalid-this`](https://eslint.org/docs/rules/no-invalid-this) for more information.

This change enables `no-invalid-this` and fixes the issues raised by the rule.
2020-08-12 21:19:33 -02:30
Whymarrh Whitby
310b15ba4a
Fix no-plusplus issues (#9206)
See [`no-plusplus`](https://eslint.org/docs/rules/no-plusplus) for more information.

This change enables `no-plusplus` and fixes the issues raised by the rule.
2020-08-12 20:36:44 -02:30
Whymarrh Whitby
548b0bbbd5
Fix no-eq-null issues (#9205)
See [`no-eq-null`](https://eslint.org/docs/rules/no-eq-null) for more information.

This change enables `no-eq-null` and fixes the issues raised by the rule.
2020-08-12 20:32:44 -02:30
Whymarrh Whitby
ef88d79fac
Fix no-useless-concat issues (#9200)
See [`no-useless-concat`](https://eslint.org/docs/rules/no-useless-concat) for more information.

This change enables `no-useless-concat` and fixes the issues raised by the rule.
2020-08-12 17:07:44 -02:30
Whymarrh Whitby
a8863a3446
Fix consistent-return issues (#9192)
See [`consistent-return`](https://eslint.org/docs/rules/consistent-return) for more information.

This change enables `consistent-return` and fixes the issues raised by the rule.
2020-08-12 16:36:57 -02:30
Brad Decker
b2813f0b54
colocate the base modal styles with the modal component (#9151)
finalizes the colocation of styles with the consuming components.
2020-08-12 12:49:45 -03:00
Erik Marks
163f45beed
Fix account modal back button styling (#9184) 2020-08-11 09:49:07 -07:00
Brad Decker
42be0645da
colocate original request-signature component styles (#9182)
Moves the styles out of the itcss folder and colocates them with the component, as per the pattern set elsewhere.
2020-08-11 11:29:19 -05:00
Erik Marks
ef68a7963c fix account modal back styling 2020-08-11 09:17:50 -07:00
Brad Decker
01f69d7e7a
colocate account modal styles with their components (#9150)
This one gets a bit more complicated because the styles were interwoven and needed to be untangled to be moved. Essentially, though, the goal is to put the styles where they make the most sense and colocate them with their components.
2020-08-11 11:07:47 -05:00
Brad Decker
6ba9e65712
colocate tab-bar styles with the tab-bar component (#9176)
Moves styles out of the itcss components folder and places them alongside the component.
2020-08-11 08:58:10 -05:00
Brad Decker
2e33b57d17
colocate hide-token-confirmation modal styles (#9149) 2020-08-07 14:31:02 -05:00
Brad Decker
d59fc79e0f
colocate deposit-ether-modal styles (#9148)
Moves the still alive deposit-ether-modal styles to be colocated with it's component, as per the examples already in place in the components/modal folder
2020-08-07 13:57:33 -05:00
Brad Decker
f3ba18d79f
remove unused section scss (#9146) 2020-08-07 10:58:48 -05:00
Brad Decker
85e658993b
colocate notification-modal styles (#9147)
Follows former examples of colocating styles with the modals that use them.
2020-08-07 10:25:00 -05:00
Brad Decker
ecaa6c55dd
trim unused account-list-item code and co-locate styles (#9116) 2020-08-06 08:04:55 -05:00
Brad Decker
db1b72a95c
colocate editable label styles and code (#9120) 2020-08-05 08:44:17 -05:00
Brad Decker
b92475ac7c
Colocate alert styles (#9117) 2020-08-05 08:43:21 -05:00
Brad Decker
46ba1ef100
Update font family globally (#9073) 2020-07-29 15:04:02 -05:00
Brad Decker
1582855e28
Use mixins for typography instead of placeholder selectors (#9072)
Using extend would not work inside of some css, namely
inside of media queries. This made it a clear choice to
use mixins for these styles.
2020-07-29 10:35:53 -05:00
Brad Decker
df8eb494fe
Updates Typography Variables and styles. (#9017)
Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2020-07-24 11:26:45 -05:00
Bakhtiiar Muzakparov
1747f91bf1
Add tooltip to contacts (#8974)
Fixes #8790
2020-07-24 11:17:03 -03:00
Whymarrh Whitby
bf6578c6b8
Enable guard-for-in rule (#9000) 2020-07-21 18:40:45 -02:30
Brad Decker
35a6ad98b3
Add accent-color usage from design system. (#9009) 2020-07-21 11:17:02 -05:00
Brad Decker
e463a47588
do not show amounts for approvals (#9032) 2020-07-21 10:45:14 -05:00
Whymarrh Whitby
2389777244
Fix invalid CSS rules (#9039) 2020-07-20 15:26:44 -02:30
Whymarrh Whitby
2ae4720443
Fix words (#9038) 2020-07-20 14:32:49 -02:30
Mark Stacey
7cd609b86b
Fix crash upon removing contact (#9031)
The UI would crash upon deleting a contact from the contact list. This
happened for two reasons: the deletion could result in a re-render
before the `history.push` finished navigating back to the contact list
(it was a race condition), and the contact entry left behind an invalid
`identities` entry when it was removed.

The first problem was fixed by making the container components for view
and edit contact more tolerant of being passed an `address` that
doesn't correspond to a contact. If they are given an address without a
contact, `null` is passed to the component via the `address` prop. The
component will redirect back to the list when this happens instead
rendering. This is more awkward than I'd like, but it was the most
sensible way of handling this I could think of without making much more
drastic changes to how we're handling routing here.

The second problem was caused by the `setAccountLabel` call, which was
used to ensure the contact entry for any wallet accounts was kept
in-sync with the account label. This was being called even for non-
wallet accounts though, which is where this problem arose. This step is
now skipped for non-wallet accounts.

Fixes #9019
2020-07-20 11:55:47 -03:00
Whymarrh Whitby
983e32274c Fix array-callback-return issues
See [`array-callback-return`](https://eslint.org/docs/rules/array-callback-return) for more information.

This change enables `array-callback-return` and fixes the issues raised by the
rule.
2020-07-17 16:03:33 -02:30
Brad Decker
549eb320e8
Narrow usages of 037DD6 to 'primary-blue' (#9008) 2020-07-17 13:11:04 -05:00
Mark Stacey
fd2e02274a
Catch gas estimate errors (#9025)
There were two cases where bad gas estimate data was resulting in
crashes. These two places have been wrapped in a `try ... catch` to
handle the absence of gas estimate data.

The errors are still reported to Sentry so that we can track down the
root cause of this corrupted gas estimate data at some point in the
future. We plan on adding additional context to Sentry soon that should
help with this.

Fixes #8992
2020-07-16 20:29:22 -03:00
Mark Stacey
acaa648779
Fix ListItem styles (#9002)
The styles for the `ListItem` component were recently broken in #8989
because of a change made by `stylelint`. It incorrectly removed the
`fr` unit because of the `length-zero-no-unit` rule. This was a bug
that has since been fixed in `stylelint`; it should have left the `fr`
unit in this case.
2020-07-15 17:13:33 -03:00
Mark Stacey
f46dda0195
Uncomment and fix all auto-fixable stylelint rules (#8989)
All stylelint rules that can be automatically fixed have been uncommented. The rules are:

* `at-rule-empty-line-before`
* `block-closing-brace-empty-line-before`
* `block-closing-brace-newline-before`
* `block-opening-brace-space-before`
* `color-hex-case`
* `color-hex-length`
* `comment-empty-line-before`
* `declaration-block-semicolon-newline-after`
* `declaration-block-semicolon-space-after`
* `declaration-block-trailing-semicolon`
* `declaration-colon-space-after`
* `declaration-empty-line-before`
* `function-comma-space-after`
* `function-comma-space-before`
* `indentation`
* `length-zero-no-unit`
* `no-eol-whitespace`
* `no-missing-end-of-source-newline`
* `number-leading-zero`
* `number-no-trailing-zeros`
* `rule-empty-line-before`
* `selector-list-comma-newline-after`
* `selector-pseudo-element-colon-notation`
2020-07-15 10:13:40 -03:00
Whymarrh Whitby
4f0a205369
Use eslint@6.8.0 (#8978)
* Use eslint@6.8.0
* yarn lint:fix
2020-07-14 12:50:41 -02:30
Mark Stacey
670ae111f0
Remove unnecessary optional chaining operator (#8892)
`state.activeTab` is always guaranteed to be set to an object before
the UI is initialized. This happens in `app/ui.js`.
2020-07-10 12:46:54 -03:00
Mark Stacey
d53c4f824e
Add personal_sign e2e test (#8958)
This tests the `personal_sign` method using the test dapp. This test
reflects part of the `confirm-sig-requests` integration test, which
tests the confirmation of a `personal_sign` signature request.

A `data-testid` prop was added to the 'Sign' button on the signature
request confirmation page, to make it easier to select the 'Sign'
button reliably.
2020-07-10 11:35:52 -03:00
Brad Decker
3cbcc913e9
update material-ui/core (#8950) 2020-07-09 16:05:44 -05:00
Mark Stacey
b485a9afb3
Add data-testid to the EthOverview balances (#8951)
Both the primary and secondary balance components on `EthOverview` now
have `data-testid` props, so that they can be more easily referenced in
e2e tests.

This required the addition of a `data-testid` prop to the component
`UserPreferencedCurrencyDisplay`, which is passed through to the
underlying `CurrencyDisplay` component.
2020-07-09 17:33:37 -03:00
Erik Marks
652db3fd36
Use string network and chain IDs (#8628)
* convert network id enums to string

* stringify appropriate chain/network ids in tests

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
2020-07-08 14:05:09 -07:00
Brad Decker
cd4903f65e
remove ramda (#8932) 2020-07-08 15:17:53 -05:00
Thomas Huang
15d713f0ee
Standardize transaction activity conversion's currency to 'ETH' (#8934) 2020-07-07 15:15:42 -07:00
Mark Stacey
4a989c339a
Fix activity log inline buttons (#8908)
The inline speedup and speedup cancellation buttons in the activity log
were broken. An exception would be thrown upon either button being
clicked, and nothing would happen from the user's perspective.

Both handlers were being passed a transaction id, which was a holdover
from before the transaction list redesign. The handlers passed for
these two actions now have the transaction id embedded, so it doesn't
need to be passed in anymore. They expect the click event to be passed
through instead.

The handlers passed also didn't handle closing the transaction details
modal when clicked. After fixing the first problem, they still didn't
work because the speedup/cancel dialog was shown behind the transaction
details modal.

Both issues are now fixed. Both buttons now close the transaction
details modal, and trigger the appropriate action.
2020-07-03 13:03:13 -03:00
Mark Stacey
3832d694a4
Replace percentage opacity value (#8898)
The CSS `opacity` rule accepts percentages on newer browsers, but some
older browser versions we support (e.g. Firefox v60) doesn't support
them. A number is now used instead, which is supported by all browsers
we support.
2020-07-02 21:51:41 -03:00
Mark Stacey
d9a27fcf52
Prevent showing connected accounts without origin (#8891)
There was a case where the `activeTab.origin` was not set, yet the user
could still navigate to the "Connected accounts" modal, which assumes
that `activeTab.origin` is set. This would happen in Firefox when the
user opened the popup on a page internal to Firefox (e.g.
`about:blank`). The connected status indicator would still be shown,
but the UI would crash when it was clicked.

The connected status indicator is now hidden whenever
`activeTab.origin` is falsy. The 'Unconnected account' alert has also
been made impossible to trigger in that circumstance.
2020-07-02 18:26:30 -03:00