- toast: Add back "open" button for Kukai and other wallets in toast.
- toast: Make sure the "Reset Connection" option is always shown in the "Request sent" toast.
- reconnect: If an error is encountered during the sending of a message, it will now always show an alert that lets the user reset the connection.
- licence: Add LICENCE file (MIT).
- network: Add support for Hangzhounet.
- web-wallet: Open new tab on button press so it will not be blocked by the browser popup blocker.
- kukai: Update icon.
- ui: Add space between wallet name and logo in "Preparing" toast.
- ui: Dynamically update pairing alert if new extension detected
- migration: Remove migration code for matrix.papers.tech server.
- ui: Avoid listener memory leak in pairing alert.
- types: The "disclaimerText" was not properly set as optional.
- ui: When clicking on "AirGap Wallet" in the pairing alert, the loader was shown instead of the QR code.
- wallet: Add Umami wallet to the wallet list
- pairing alert: The connection to the beacon network is now estabilished "lazily". This means that the connection is only established if the user selects a wallet that communicates over the beacon network. Users that select an extension wallet will no longer open an unused connection.
- pairing alert: The
DAppClientOptionsnew includes a
disclaimerTextfield, which will be displayed in the Pairing Alert.
- pairing: If the wallet rejects the initial permission request, the active peer will be reset and on the next action the user will be prompted to select his wallet again.
- wallet list: The wallets in the wallet list now include a
keyproperty, which will allow developers to uniquely identify the wallet.
- ui: A new "Prepare" UI state. This UI state can optionally be triggered by the developer in case there is a calculation or network request before the beacon request is sent. This will improve usability because there will be immediate feedback. If you are using taquito, the UI state will be triggered for you internally.
- ui: After clicking on a desktop or web wallet, the alert will show a "connecting" state to indicate that the dApp is waiting for the response of the wallet.
- ui: The wallet list is now ordered alphabetically.
- p2p: Rooms created on the beacon nodes are now
private. This will allow us to improve the reconnection flow in the future.
- internal: Improve example dApp and example wallet
- internal: Add E2E tests
- peers: The
activePeeris now no longer persisted in localStorage, which will improve the behavior if users refresh the page during a connection attempt.
- ui: Small improvements and bug fixes in the alert.
- p2p: Add
beacon-node-2.sky.papers.technode to the default nodes
- ui: Add "open wallet" button to "request" toast. This button will appear when paired with Kukai Wallet or a mobile wallet (while on mobile)
- p2p: Replace
- p2p: Use
room_version v5when creating rooms
- p2p: Add
WalletClientclass. The property is
trueby default (previous behavior), but it can be set to false in case an existing peer is re-added, but no new connection should be initiated.
- p2p: Using the "Reset Connection" button no longer requires a refresh
- p2p: Cached rooms are updated whenever a message is received or a new invite is received. This prevents peers from sending messages to "old" rooms where the other peer potentially no longer has access to
- p2p: Improved the behaviour of the "re-pairing" for previously connected dApps. To prevent old state from affecting the connection, a new room is now always created when a connection is initialised
- p2p: "Reset Connection" now works properly by making sure all old state is reset
- p2p: Deterministically select the relay server based on the public key so it's always the same on by default
- p2p: The SDK now resumes the connection after the server was unreachable for a while
- network: Add Granadanet
- p2p: Add second beacon-node to default nodes array
- p2p: Improve reconnect behaviour if the previously used node is not reachable
- ui: Limit toast width, which was causing styling issues on some devices
- ui: Ignore styling from parent page
- types: Make operation request properties optional instead of omitting them
- p2p: Remove unknown rooms and retry
- florencenet: Add Florencenet
- p2p: Support federated matrix servers
- p2p: Fix timing issues during connection setup to improve reliability
- UI: Make alert scrollable
- temple: Rename "Thanos" to "Temple"
- kukai: Add edonet URL
- error: Fix removing of dom element that would result in an error
- signing: The validation of the
MICHELINEpayloads is now correct
- alert: The page no longer scrolls down when the alert opens
- alert: Alert width fixed on mobile
- toast: Toasts are now sticky to the top of the window, not the top of the page
- toast: Toast height fixed on iOS
- toast: If an acknowledge message is received after the response, it will be ignored
- toast: The close button will now always be shown in the "awaiting" state
- toast: Remove unnecessary "href" from link in error toast
- toast: New toasts that are triggered while another one is being shown will now be handled correctly
UI Improvements: We changed the flow of the UI from the ground up. When a new message is sent from the dApp, the "request sent" toast now sticks to the top right of the page. It shows a loading animation and also includes the name (and logo) of the wallet where the request has been sent to. The toast will update whenever new information is received from the wallet (eg. request acknowledgement or response). Only the pairing information and details of errors will be displayed in a blocking alert. As always, all of these UI elements can be overwritten if dApp developers want to use their own UI.
UI Improvements: Default UI Elements in Beacon now use Shadow Dom. This will encapsulate the styling of the UI elements, so the styling of the page will no longer affect the styling of the beacon-sdk UI elements, and vice versa.
Dark Mode: The dApp developer can now choose between a "dark" and "light" color theme. This will change the look of both alerts and toasts.
beacon-sdknow allows for RPC-Errors to be passed in the
TRANSACTION_INVALID_ERRORresponse. Errors MUST be displayed in the wallet. This change does not change that. It simply allows dApps that expect certain errors to provide more insights into what went wrong. dApps are not required to display the details of an error, but they can choose to do so if it improves the user experience.
Debug: New debug methods have been introduced. To activate logs from the
beacon-sdkduring development, it is possible to call
setDebugEnabled(true). This will enable logs throughout the
beacon-sdk will now also listen to the
beaconSdkDebugEnabled variable on the global window object. This will allow browser extensions (eg. Spire) to set the debug flag to true on production websites, which will help debugging on production dApps.
- UI Elements: All default UI Elements / Event Handlers can be removed at once by setting the
disableDefaultEventsflag in the
DAppClientOptionsto true. Keep in mind that this will also disable the Pairing Alert. If you want to keep the Pairing Alert, you will have to add those default handlers again. An example would be:
- Alert: A click outside the alert will now dismiss the alert
- Logs: Add warning logs when the QR code gets too big and when muliple Clients are created
- SigningType: Add
MICHELINESigningTypes. The payload of the
OPERATIONtype has to start with
MICHELINEtype has to start with
- Beacon Extension: The "Beacon Extension" has been renamed to "Spire".
- dApp / Wallet metadata: The dApp and wallet metadata (name and icon) are now included in the pairing request / response
- Matrix Performace Improvements: Fixed a timing issue that lead to slower responses
setActiveAccountnow updates and persists the active peer
- Types: The type of
- Docs: Fixed a typo in link a docs link
edonet: Add Edonet
carthagenet: Remove Carthagenet
accessibility: Close alerts with "ESC" button
accessibility: Tab through selection on pairing alert and select item with enter
clearActiveAccount()method. This is just a wrapper for
setActiveAccount()but should make it more clear how to clear an account.
- errors: Error messages were thrown internally in some cases and could not be caught by the developer
- broadcast-error: The "Broadcast" error was mistakenly displayed as a "Network not supported" error
- init: If the
initmethod was called manually by the developer, the following requests would never resolve
- pageload: The transport is now set on pageload even if
initis not called
- pageload: If a peer was connected but no permissions were shared, a refresh will now reconnect to the previous peer
- deeplink: Deeplinks on iOS did not work in some browsers
- pairing: Center QR code
- types: "kind" of the
- pairing: Add Galleon Desktop Wallet
Beacon v2.0.0 is a big update from v1.x. The APIs on the DApp and Wallet side stayed mostly the same. There may be some minor changes in the object structure, but the majority of the changes are internal and should not affect the developers.
We highly encourage developers to upgrade to v2. The most notable new features are:
- Support for multiple Browser Extensions (eg. Thanos and Spire)
- Support for mobile, browser and desktop Wallets
- Mobile support via Deeplinking
- Secure and encrypted communication between DApp and Browser Extension
senderIdin all objects
senderId: The senderId property now has to be a hash of the publicKey of the sender
P2PTransport: The pairing-response from the Wallet is no longer only an encrypted public key, but rather an object including the public key (with additional metadata)
P2PPairInfo: Now includes a version and additional metadata
P2PPairInfo: JSON is now
base58checkencoded (eg. QR code)
PostMessageTransport: The communication is now encrypted
getAvailableExtensionsreturns an array of available browser extensions
DAppClient: Having an Extension installed on page load will no longer automatically select that extension as the active peer. The user always has to select his preferred wallet type.
Acknowledge Message: The Wallet will now send an acknowledge message immediately after a request is received.
Disconnect Message: There is now a disconnect even that can be sent from both sides and indicates that the connection will no longer be listened to
Error Message: A new error message type that makes it clear the message is an error
- delphinet: Add delphinet support
- build: Add esmodule files
- libsodium: Update to 0.7.8
- build: Add es5 build
- events: The
P2P_CHANNEL_CONNECT_SUCCESSevent will now return the
P2PPairInfoof the newly connected peer.
- active-account: calling
await dappClient.getActiveAccount()will now always wait for the storage to be read, so it will only be undefined if there was actually no active account set before.
- p2p: ignore dupliacte messages
- alert: fix timeout not working if multiple alerts are open
- error: the alert for beacon errors was not displayed
- operation-request: use network settings of ActiveAccount by default
- alert: multiple alerts can now all be closed independently
- storage: update stored information if newer one is available (eg. AccountInfo after a second PermissionRequest)
- peer: type of peer methods was
- all: changed
- events: added new event type "INTERNAL_ERROR" that will be triggered when an important handled error occurs, for example if
requestOperationis called but there is no
- account-info / permission-info: Change
- all: due to the changes in the interfaces, the storage of accounts and permissions will be invalid and has to be reset (eg. clearing application cache)
- DAppClient: when removing peers, remove related accounts as well
- DAppClient: when removing an account that happens to be the activeAccount, set activeAccount to null
- WalletClient: persist appMetadata and permissions
- WalletClient: when removing peers, remove related permissions as well
- storage: clone default values before returning to prevent them from being overwritten
- storage: remove FileStorage because it references the "fs" module and can cause issues when used in the brower
- QR: fixed a bug where the QR data object was stringified 2 times, resulting in an escaped string
- P2P: show QR Alert again if no peer has connected
- P2P: do not throw error when decryption fails, because this is expected to happen sometimes
- P2P: fixed error when persisting matrix room, resulting in an error when trying to read rooms from local storage
- BigNumber: use BigNumber instead of native BigInt to support Safari
- typescript: update to 3.9.2
- typescript: enable strict mode
- account-identifier: pass Buffer to bs58check encode method
- p2p-communication-client: make methods async
- alert: link to correct network
- alert: improve styling and wording
- alert: inline beacon logo
- matrix: replace
matrix-js-sdkwith internal implementation
- events: pass overrides in constructor
- alert: improve styling and wording
- events: send success events when receiving a beacon response
- get-address-from-pubkey: handle edpk public keys
- beacon: remove read_address permission
- account-identifier: remove account identifier from beacon message
- beaconId: generate keypair and use public key as
- errors: add human readable messages
- transport: fix detection of chrome extension
- exposed-promise: use class instead of function to preserve internal state
- active-account: read active account as early as possible
Initial stable beta release