Niranjana Binoy
6c757ab5e0
Event tracking for Token Detection V2 ( #14441 )
3 years ago
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
3 years ago
filipsekulic
8cb1f4af2e
Renamed metametrics.new.js to metametrics.js ( #14327 )
3 years ago
Olusegun Akintayo
3c2e4e9c9e
Add asset_type to 'Tokens Added' event. ( #14252 )
...
Signed-off-by: Akintayo A. Olusegun <akintayo.segun@gmail.com>
3 years ago
Olusegun Akintayo
4ac0f82125
Add token standard to Token Added event. ( #14253 )
...
Signed-off-by: Akintayo A. Olusegun <akintayo.segun@gmail.com>
3 years ago
Guillaume Roux
8683282a6f
Dark Mode: Replace color occurences ( #14112 )
3 years ago
Ariella Vu
fa15b32fab
ConfirmAddSuggestToken: replace mapDispatchToProps & mapStateToProps; Add Tests ( #13526 )
...
* ConfirmAddSuggestedToken: component.js -> .js
* replace mapStateToProps w/ useSelector
ConfirmAddSuggestedToken
* replace mapDispatchToProps w/ useDispatch
ConfirmAddSuggestedToken
* ConfirmAddSuggestedToken: useHistory
* ConfirmAddSuggestedToken: revert scss
reuse ConfirmImportToken styles for now
* ConfirmAddSuggestToken: add tests
* ConfirmAddSuggestedToken: rm unused controls
* ConfirmAddSuggestedToken: rm snapshot
* use `metamark.svg` instead of `metamask.svg`
* ConfirmAddSuggestedToken: update useSelectors
* Revert "ConfirmAddSuggestedToken: revert scss"
This reverts commit 07aed4576caaf247cb38ad481d79a339ba3d3947.
* ConfirmAddSuggestedToken: === undefined
w/ strict mode
* ConfirmAddSuggestedToken: use useNewMetricEvent
* ConfirmAddSuggestedToken: run useEffect once
* ConfirmAddSuggestedToken: rm unused async
* ConfirmAddSuggestedToken: rm mock redux store
* ConfirmAddSuggestedToken: duplicate ConfirmImportToken styles
* ConfirmAddSuggestedToken: update metrics logic
* ConfirmAddSuggestedToken: metricEvent-> trackEvent
* ConfirmAddSuggestedToken:clean useEffect w/ new fn
- PR suggestion: https://github.com/MetaMask/metamask-extension/pull/13526#discussion_r818007393
* ConfirmAddSuggestedToken: rm unused .token-balance styles
3 years ago
Brad Decker
9cea401022
extract determineTransactionType from tx controller ( #13737 )
3 years ago
Ariella Vu
a5b114c4f9
Use ActionableMessage for ConfirmAddSuggestionToken warnings ( #13402 )
...
* ConfirmAddSuggestedToken: update duplicate logic
* ConfirmAddSuggestedToken: update duplicate fn names
* ConfirmAddSuggestedToken: add ActionableMessage
- fixes #13347
* base-styles.scss: deprecate .warning
* ConfirmAddSuggestedTokens: update @param desc
Co-authored-by: Alex Donesky <adonesky@gmail.com>
* ConfirmAddSuggestedTokens: update @param desc
Co-authored-by: Alex Donesky <adonesky@gmail.com>
* ConfirmAddSuggestedTokens: update @param desc
Co-authored-by: Alex Donesky <adonesky@gmail.com>
* ConfirmAddSuggestedTokens: update @param desc
Co-authored-by: Alex Donesky <adonesky@gmail.com>
* ConfirmAddSuggestedToken: clean JSDoc comments
- following GitHub suggestion commits
* ConfirmAddSuggestedToken: warning Learn More btn
* add zendesk-url constants
- use for ConfirmAddSuggestedToken & ImportToken pages
* storybook: add ConfirmAddSuggestedToken controls
* stories: add ConfirmAddSuggestedTokens states
* stories: rm unused args ConfirmAddSuggestedToken
* rn ZENDESK_URL -> ZENDESK_URLS
* AddSuggestedToken: check case-insensitive symbols
Co-authored-by: Alex Donesky <adonesky@gmail.com>
3 years ago
Ariella Vu
667350d15a
Convert ConfirmAddSuggestedToken to a functional component + cleanup ( #13377 )
...
* FC: ConfirmAddSuggestedToken
- change class to functional component
* clean: reorganize functions (no logic change)
* FC: ConfirmAddSuggestedToken pt. 2
- preserve trackEvent logic -> metricsEvent
* clean: rm _ prefix from fn name
- why? now, only 3 other functions remain prefixed w/ '_'
* clean: update useEffect hook
* clean: alphabetize props
* clean: functions in ConfirmAddSuggestedToken
* clean: use arrow fn for FC
3 years ago
Mark Stacey
3732c5f71e
Add JSDoc ESLint rules ( #12112 )
...
ESLint rules have been added to enforce our JSDoc conventions. These
rules were introduced by updating `@metamask/eslint-config` to v9.
Some of the rules have been disabled because the effort to fix all lint
errors was too high. It might be easiest to enable these rules one
directory at a time, or one rule at a time.
Most of the changes in this PR were a result of running
`yarn lint:fix`. There were a handful of manual changes that seemed
obvious and simple to make. Anything beyond that and the rule was left
disabled.
3 years ago
Mark Stacey
22f931e6b2
Prevent automatic rejection of confirmations ( #13194 )
...
* Prevent automatic rejection of confirmations
Confirmations are now only automatically rejected if a user explicitly
closes the notification window. If we close the window programmatically
because there are no notifications left to show, nothing gets rejected.
This partially avoids a race condition where a confirmation gets
rejected automatically without the user having seen the confirmation
first. This could happen if the confirmation was processed just as the
notification window was being closed.
It's still possible for a confirmation that the user has never seen to
get rejected as a result of the user closing the window. But at least
now it's no longer possible for a confirmation to get rejected in this
manner after the user resolves the last confirmation in the queue.
* Fix bug that prevented automatic closure detection
All windows were being detected as explicit window closures,
essentially just as they were previously, because this variable was
cleared too soon.
* Re-open popup when necessary
After the window is automatically closed, a confirmation may have been
queued up while the window was closing. If so, the popup is now re-
opened.
3 years ago
George Marshall
854fc71ae7
Organizing storybook to echo app folder structure ( #12796 )
...
* Organizing storybook to echo app folder structure
* Updating new stories to follow new convention from develop
3 years ago
Niranjana Binoy
68259ee3e2
UX Papercuts Epic: Create a consistent representation of the Buttons ( #12096 )
3 years ago
ryanml
c14f46eb92
Fixing confirm-add-suggested-token storybook entry ( #12261 )
3 years ago
kumavis
f472c2615a
CI - add metamaskbot comment "highlights" section for showing relevant storybook changes ( #12095 )
...
* ci/announce/highlight - add bot announcement section for "highlights" showing off important diffs + storybook highlights
* ci/announce/highlight - fix announcement message
* Update index.js
* xxx tmp xxx
* ci/announce/highlight - fix dirty file calculation
* ci/announce/highlight - try/catch wrap highlight generation for build stability
* ui - put fox emojis in the mascot component
* ci/announce/highlight - start storybook permalinks
* ci/announce/highlight - fix storybook permalink util
* ci/announce/highlight - fix storybook permalink util
* ci/announce/highlight - small styling fix
* storybook - use any easily predictable story id
* ci/announce/highlight - revert sample commit
* ci/announce/highlight - minimal documentation
3 years ago
Niranjana Binoy
05aadb38f2
Adding fake token warning and replacing `Add Token` labels with `Import Tokens` ( #11798 )
3 years ago
Alex Donesky
490d3b8d40
Integrate TokensController ( #11552 )
...
* Integrate controllers/tokensController
* address rebase issues
* small cleanup
* addressing feedback
* more feedback
3 years ago
Etienne Dusseault
09e79f273a
fix state problems with Storybook ( #11984 )
...
* fix state problems with Storybook
* lint
* lint
* Cleanup
Co-authored-by: ryanml <ryanlanese@gmail.com>
3 years ago
Etienne Dusseault
46c4cc1966
Add confirm-add-suggested-token & confirm-add-token components to Storybook ( #11175 )
...
* add suggessted token
* lintfix
* lintfix
* silence use effect warning
* download token icons and use paths to avoid web urls
* lintifx
* Add confirm-add-token component to Storyboard (#11195 )
* create story for add token
* change code
* add confirm add token story
* lintfix
* Update confirm-add-token.component.js
* Update confirm-add-token.component.js
* different token list for confirm add token
* lintfix
* Update confirm-add-suggested-token.component.js
* remove bnb png
* remove redundant images and fix storybook image path
3 years ago
Brad Decker
29742b9519
remove the ui/app and ui/lib folders ( #10911 )
4 years ago
Brad Decker
09d81ac5f2
remove the ui/app and ui/lib folders ( #10911 )
4 years ago