Skip to content

Commit

Permalink
Merge branch 'main' into feat/8795_remove_mixpanel
Browse files Browse the repository at this point in the history
  • Loading branch information
NicolasMassart authored Mar 6, 2024
2 parents 3a0b7b7 + 1097298 commit 14241b0
Show file tree
Hide file tree
Showing 13 changed files with 4,149 additions and 814 deletions.
4 changes: 2 additions & 2 deletions .js.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@ export MM_BLOCKAID_UI_ENABLED=""
export WATCHER_PORT=8081

# Environment: "production", "pre-release" or "local"
export METAMASK_ENVIRONMENT=""
export METAMASK_ENVIRONMENT="local"

# Build type: "main" or "flask"
export METAMASK_BUILD_TYPE=""
export METAMASK_BUILD_TYPE="main"

# Segment SDK proxy endpoint and write key
export SEGMENT_WRITE_KEY=""
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ To learn how to develop MetaMask-compatible applications, visit our [Developer D

### Environment setup

Before running the app, make sure your development environment has all the required tools.
Before running the app, make sure your development environment has all the required tools. Several of these tools (ie Node and Ruby) may require specific versions in order to successfully build the app.

[Setup your development environment](./docs/readme/environment.md)

Expand Down Expand Up @@ -65,4 +65,4 @@ yarn start:ios
**Run on an Android device**
```bash
yarn start:android
```
```
Original file line number Diff line number Diff line change
Expand Up @@ -378,6 +378,7 @@ describe('SendTransaction View', () => {
"fiat_out": 0,
"order_id": "test-id-1",
"payment_method_id": "/payments/instant-bank-transfer",
"provider_offramp": "Test (Staging)",
},
]
`);
Expand Down Expand Up @@ -432,6 +433,7 @@ describe('SendTransaction View', () => {
"fiat_out": 0,
"order_id": "test-id-1",
"payment_method_id": "/payments/instant-bank-transfer",
"provider_offramp": "Test (Staging)",
},
]
`);
Expand Down Expand Up @@ -479,6 +481,7 @@ describe('SendTransaction View', () => {
"fiat_out": 0,
"order_id": "test-id-1",
"payment_method_id": "/payments/instant-bank-transfer",
"provider_offramp": "Test (Staging)",
},
]
`);
Expand Down Expand Up @@ -529,6 +532,7 @@ describe('SendTransaction View', () => {
"fiat_out": 0,
"order_id": "test-id-1",
"payment_method_id": "/payments/instant-bank-transfer",
"provider_offramp": "Test (Staging)",
},
]
`);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,14 @@ function SendTransaction() {

const transactionAnalyticsPayload = useMemo(
() => ({
crypto_amount: orderData?.cryptoAmount,
crypto_amount: orderData?.cryptoAmount as string,
chain_id_source: orderData?.cryptoCurrency.network.chainId,
fiat_out: orderData?.fiatAmount,
payment_method_id: orderData?.paymentMethod.id,
currency_source: orderData?.cryptoCurrency.symbol,
currency_destination: orderData?.fiatCurrency.symbol,
order_id: order?.id,
provider_offramp: orderData?.provider.name,
}),
[order?.id, orderData],
);
Expand Down
1 change: 1 addition & 0 deletions app/components/UI/Ramp/types/analytics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,7 @@ interface RampTransaction {
currency_source: string;
currency_destination: string;
order_id?: string;
provider_offramp: string;
}

interface RampQuotesExpanded {
Expand Down
6 changes: 5 additions & 1 deletion app/components/Views/Settings/NetworksSettings/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,11 @@ class NetworksSettings extends PureComponent {
this.updateNavBar();
};

componentDidUpdate = () => {
componentDidUpdate = (prevProps) => {
if (this.props.networkConfigurations !== prevProps.networkConfigurations) {
this.handleSearchTextChange(this.state.searchString);
}

this.updateNavBar();
};

Expand Down
4 changes: 2 additions & 2 deletions app/store/migrations/025.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe('Migration #25', () => {
'0x61': true,
'0xa': true,
'0xa869': true,
'0x1a4': true,
'0xaa37dc': true,
'0x89': true,
'0x13881': true,
'0xa86a': true,
Expand Down Expand Up @@ -46,7 +46,7 @@ describe('Migration #25', () => {
'0x61': false,
'0xa': false,
'0xa869': false,
'0x1a4': false,
'0xaa37dc': false,
'0x89': false,
'0x13881': false,
'0xa86a': false,
Expand Down
2 changes: 1 addition & 1 deletion app/util/test/initial-background-state.json
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
"0x61": true,
"0xa": true,
"0xa869": true,
"0x1a4": true,
"0xaa37dc": true,
"0x89": true,
"0x13881": true,
"0xa86a": true,
Expand Down
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,7 @@
"@metamask/contract-metadata": "^2.1.0",
"@metamask/approval-controller": "3.4.0",
"@exodus/react-native-payments/validator": "^13.7.0",
"**/plist": "3.0.5",
"**/minimist": "1.2.6",
"@metamask/**/cross-fetch": "2.2.6",
"react-native-svg-asset-plugin/sharp": "^0.30.5",
"d3-color": "3.1.0",
"tough-cookie": "4.1.3",
Expand Down
10 changes: 6 additions & 4 deletions patches/@metamask+preferences-controller+4.4.3.patch
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
diff --git a/node_modules/@metamask/preferences-controller/dist/PreferencesController.d.ts b/node_modules/@metamask/preferences-controller/dist/PreferencesController.d.ts
index 323a8e8..8fa1856 100644
index 323a8e8..0c5ed1b 100644
--- a/node_modules/@metamask/preferences-controller/dist/PreferencesController.d.ts
+++ b/node_modules/@metamask/preferences-controller/dist/PreferencesController.d.ts
@@ -35,7 +35,8 @@ export interface PreferencesState extends BaseState {
Expand Down Expand Up @@ -54,8 +54,9 @@ index 323a8e8..8fa1856 100644
}
export default PreferencesController;
//# sourceMappingURL=PreferencesController.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@metamask/preferences-controller/dist/PreferencesController.js b/node_modules/@metamask/preferences-controller/dist/PreferencesController.js
index 1a98ab0..a31d967 100644
index 1a98ab0..4ce2400 100644
--- a/node_modules/@metamask/preferences-controller/dist/PreferencesController.js
+++ b/node_modules/@metamask/preferences-controller/dist/PreferencesController.js
@@ -3,6 +3,29 @@ Object.defineProperty(exports, "__esModule", { value: true });
Expand All @@ -69,7 +70,7 @@ index 1a98ab0..a31d967 100644
+ BSC: '0x38',
+ BSC_TESTNET: '0x61',
+ OPTIMISM: '0xa',
+ OPTIMISM_TESTNET: '0x1a4',
+ OPTIMISM_SEPOLIA: '0xaa37dc',
+ POLYGON: '0x89',
+ POLYGON_TESTNET: '0x13881',
+ AVALANCHE: '0xa86a',
Expand Down Expand Up @@ -108,7 +109,7 @@ index 1a98ab0..a31d967 100644
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.BSC]: true,
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.BSC_TESTNET]: true,
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.OPTIMISM]: true,
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.OPTIMISM_TESTNET]: true,
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.OPTIMISM_SEPOLIA]: true,
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.POLYGON]: true,
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.POLYGON_TESTNET]: true,
+ [ETHERSCAN_SUPPORTED_CHAIN_IDS.AVALANCHE]: true,
Expand Down Expand Up @@ -193,3 +194,4 @@ index 1a98ab0..a31d967 100644
exports.PreferencesController = PreferencesController;
exports.default = PreferencesController;
//# sourceMappingURL=PreferencesController.js.map
\ No newline at end of file
Loading

0 comments on commit 14241b0

Please sign in to comment.