Skip to content

Commit a570c3a

Browse files
authored
Merge pull request #1904 from blocknative/release/2.24.10
Release 2.24.10
2 parents df7480f + d14ddef commit a570c3a

File tree

26 files changed

+201
-63
lines changed

26 files changed

+201
-63
lines changed

docs/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
"@web3-onboard/blocto": "^2.0.0",
5656
"@web3-onboard/cede-store": "^2.1.0",
5757
"@web3-onboard/coinbase": "^2.2.5",
58-
"@web3-onboard/core": "^2.21.0",
58+
"@web3-onboard/core": "^2.21.1",
5959
"@web3-onboard/dcent": "^2.2.7",
6060
"@web3-onboard/enkrypt": "^2.0.4",
6161
"@web3-onboard/fortmatic": "^2.0.19",
@@ -64,7 +64,7 @@
6464
"@web3-onboard/gas": "^2.1.8",
6565
"@web3-onboard/gnosis": "^2.1.10",
6666
"@web3-onboard/infinity-wallet": "^2.0.4",
67-
"@web3-onboard/injected-wallets": "^2.10.2",
67+
"@web3-onboard/injected-wallets": "^2.10.6",
6868
"@web3-onboard/keepkey": "^2.3.7",
6969
"@web3-onboard/keystone": "^2.3.7",
7070
"@web3-onboard/ledger": "^2.5.1",

docs/src/routes/docs/[...3]modules/[...1]core/+page.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,14 +156,15 @@ type Chain = {
156156
namespace?: 'evm' // string indicating chain namespace. Defaults to 'evm' but will allow other chain namespaces in the future
157157
// PLEASE NOTE: Some wallets require an rpcUrl, label, and token for actions such as adding a new chain.
158158
// It is recommended to include rpcUrl, label, and token for full functionality.
159-
rpcUrl?: string // Recommended to include. Used for network requests.
159+
rpcUrl?: string // Recommended to include. Used for network requests (eg Alchemy or Infura end point).
160160
label?: string // Recommended to include. Used for display, eg Ethereum Mainnet.
161161
token?: TokenSymbol // Recommended to include. The native token symbol, eg ETH, BNB, MATIC.
162162
color?: string // the color used to represent the chain and will be used as a background for the icon
163163
icon?: string // the icon to represent the chain
164164
publicRpcUrl?: string // an optional public RPC used when adding a new chain config to the wallet
165165
blockExplorerUrl?: string // also used when adding a new config to the wallet
166166
secondaryTokens?: SecondaryTokens[] // An optional array of tokens (max of 5) to be available to the dapp in the app state object per wallet within the wallet account and displayed in Account Center (if enabled)
167+
protectedRpcUrl?: string //An optional protected RPC URL - Defaults to Blocknative's private RPC aggregator to allow users to update the chain RPC within their wallet, specifically for private RPCs that protect user transactions. More information can be found at `https://docs.blocknative.com/blocknative-mev-protection/transaction-boost`
167168
}
168169

169170
interface SecondaryTokens {
@@ -415,6 +416,13 @@ type AccountCenter = {
415416
* Can be set as a global for Account Center or per interface (desktop/mobile)
416417
*/
417418
hideTransactionProtectionBtn?: boolean
419+
/**
420+
* defaults to
421+
* `docs.blocknative.com/blocknative-mev-protection/transaction-boost-alpha`
422+
* Use this property to override the default link to give users
423+
* more information about transaction protection and the RPC be set
424+
*/
425+
transactionProtectionInfoLink?: string
418426
/**
419427
* @deprecated Use top level containerElements property
420428
* with the accountCenter prop set to the desired container El. See documentation below

docs/src/routes/docs/[...4]wallets/[...11]injected/+page.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ const injected = injectedModule({
299299
- Trust - _Desktop & Mobile_
300300
- SafePal - _Desktop & Mobile_
301301
- Zerion - _Desktop & Mobile_
302-
- OKX Wallet - _Desktop_
302+
- OKX Wallet - _Desktop & Mobile_
303303
- Taho (Previously named Tally Ho wallet) - _Desktop_
304304
- Opera - _Desktop & Mobile_
305305
- Status - _Mobile_
@@ -345,6 +345,7 @@ const injected = injectedModule({
345345
- Ronin Wallet - _Desktop & Mobile_
346346
- Coin98 Wallet - _Desktop & Mobile_
347347
- SubWallet - _Desktop & Mobile_
348+
- Kayros - _Desktop_
348349

349350
## Build Environments
350351

docs/src/routes/examples/[...1]connect-wallet/+page.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ const appMetadata = {
171171

172172
const web3Onboard = init({
173173
wallets,
174-
chains
174+
chains,
175175
appMetadata
176176
})
177177

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "web3-onboard-monorepo",
3-
"version": "2.24.9",
3+
"version": "2.24.10",
44
"private": true,
55
"workspaces": {
66
"packages": [

packages/core/README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,7 @@ type Chain = {
148148
publicRpcUrl?: string // an optional public RPC used when adding a new chain config to the wallet
149149
blockExplorerUrl?: string // also used when adding a new config to the wallet
150150
secondaryTokens?: SecondaryTokens[] // An optional array of tokens (max of 5) to be available to the dapp in the app state object per wallet within the wallet account and displayed in Account Center (if enabled)
151+
protectedRpcUrl?: string //An optional protected RPC URL - Defaults to Blocknative's private RPC aggregator to allow users to update the chain RPC within their wallet, specifically for private RPCs that protect user transactions. More information can be found at `https://docs.blocknative.com/blocknative-mev-protection/transaction-boost`
151152
}
152153
interface SecondaryTokens {
153154
/**
@@ -363,6 +364,16 @@ type AccountCenter = {
363364
position?: AccountCenterPosition // default: 'bottomRight'
364365
expanded?: boolean // default: true
365366
minimal?: boolean // enabled by default for mobile
367+
/**
368+
* Controls the visibility of the 'Enable Transaction Protection' button within the expanded Account Center.
369+
* - When set to false (default), the button is visible.
370+
* - When set to true, the button is hidden.
371+
* This setting can be configured globally for the Account Center, or separately for different interfaces like desktop/mobile.
372+
* defaults to `docs.blocknative.com/blocknative-mev-protection/transaction-boost-alpha`
373+
* Use this property to override the default link to give users
374+
* more information about transaction protection and the RPC be set
375+
*/
376+
transactionProtectionInfoLink?: string
366377

367378
/**
368379
* @deprecated Use top level containerElements property
@@ -381,6 +392,16 @@ type AccountCenterOptions = {
381392
* Can be set as a global for Account Center or per interface (desktop/mobile)
382393
*/
383394
hideTransactionProtectionBtn?: boolean
395+
/**
396+
* Controls the visibility of the 'Enable Transaction Protection' button within the expanded Account Center.
397+
* - When set to false (default), the button is visible.
398+
* - When set to true, the button is hidden.
399+
* This setting can be configured globally for the Account Center, or separately for different interfaces like desktop/mobile.
400+
* defaults to `docs.blocknative.com/blocknative-mev-protection/transaction-boost-alpha`
401+
* Use this property to override the default link to give users
402+
* more information about transaction protection and the RPC be set
403+
*/
404+
transactionProtectionInfoLink?: string
384405
}
385406

386407
type AccountCenterPosition =

packages/core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@web3-onboard/core",
3-
"version": "2.21.0",
3+
"version": "2.21.1",
44
"description": "Web3-Onboard makes it simple to connect Ethereum hardware and software wallets to your dapp. Features standardized spec compliant web3 providers for all supported wallets, framework agnostic modern javascript UI with code splitting, CSS customization, multi-chain and multi-account support, reactive wallet state subscriptions and real-time transaction state change notifications.",
55
"keywords": [
66
"Ethereum",

packages/core/src/constants.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,5 @@ export const STORAGE_KEYS = {
3737

3838
export const MOBILE_WINDOW_WIDTH = 768
3939

40-
export const BN_PROTECT_RPC_URL = 'https://rpc.blocknative.com/protect'
40+
export const BN_BOOST_RPC_URL = 'https://rpc.blocknative.com/boost'
41+
export const BN_BOOST_INFO_URL = 'https://docs.blocknative.com/blocknative-mev-protection/transaction-boost'

packages/core/src/i18n/en.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,8 @@
6262
},
6363
"confirmTransactionProtection": {
6464
"heading": "Enable Transaction Protection",
65-
"description": "Protect RPC Endpoints hide your transactions from front-running and sandwich bots to reduce unfavorable transaction settlement from slippage.",
65+
"description": "Protect RPC endpoints hide your transaction from front-running and sandwich bots.",
66+
"link": "Learn more",
6667
"enable": "Enable",
6768
"dismiss": "Dismiss"
6869
}

packages/core/src/index.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,18 +127,21 @@ function init(options: InitOptions): OnboardAPI {
127127
// update accountCenter
128128
if (typeof accountCenter !== 'undefined') {
129129
let accountCenterUpdate
130-
const { hideTransactionProtectionBtn } = accountCenter
130+
const { hideTransactionProtectionBtn, transactionProtectionInfoLink } =
131+
accountCenter
131132

132133
if (device.type === 'mobile') {
133134
accountCenterUpdate = {
134135
...APP_INITIAL_STATE.accountCenter,
135136
hideTransactionProtectionBtn,
137+
transactionProtectionInfoLink,
136138
...(accountCenter.mobile ? accountCenter.mobile : {})
137139
}
138140
} else if (accountCenter.desktop) {
139141
accountCenterUpdate = {
140142
...APP_INITIAL_STATE.accountCenter,
141143
hideTransactionProtectionBtn,
144+
transactionProtectionInfoLink,
142145
...accountCenter.desktop
143146
}
144147
}

0 commit comments

Comments
 (0)