Skip to content

Commit

Permalink
Merge pull request #810 from near/dev
Browse files Browse the repository at this point in the history
v8.1.1 Release (dev -> main)
  • Loading branch information
DamirSQA authored May 18, 2023
2 parents cc9ba74 + 2de9780 commit 107ba92
Show file tree
Hide file tree
Showing 31 changed files with 56 additions and 33 deletions.
6 changes: 4 additions & 2 deletions examples/react/contexts/WalletSelectorExportContext.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,10 @@ export const ExportAccountSelectorContextProvider: React.FC<{
*/
const _modal = setupExportSelectorModal(_selector, {
accounts: [],
onComplete: (completedAccounts) => {
console.log("Transfer Completed: ", completedAccounts);
onComplete: (completeProps) => {
console.log(
`${completeProps.accounts} exported to ${completeProps.walletName}`
);
},
});
const state = _selector.store.getState();
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "near-wallet-selector",
"version": "8.1.0",
"version": "8.1.1",
"description": "NEAR Wallet Selector makes it easy for users to interact with your dApp by providing an abstraction over various wallets within the NEAR ecosystem",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/account-export/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/account-export",
"version": "8.1.0",
"version": "8.1.1",
"description": "This is the Export Selector UI package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
11 changes: 9 additions & 2 deletions packages/account-export/src/lib/components/ExportAccount.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ import { Complete } from "./Complete";

import { encryptAccountData } from "../helpers";

type CompleteProps = {
accounts: Array<string>;
walletName: string;
};
interface ExportAccountProps {
alertMessage: string | null;
module?: ModuleState;
Expand All @@ -33,7 +37,7 @@ interface ExportAccountProps {
accounts: Array<AccountImportData>;
selector: WalletSelector;
wallet: ModuleState<Wallet>;
onComplete?: (accounts: Array<string>) => void;
onComplete?: (object: CompleteProps) => void;
}

const EXPORT_ACCOUNT_STEPS = {
Expand Down Expand Up @@ -300,7 +304,10 @@ export const ExportAccount: React.FC<ExportAccountProps> = ({

const onTransferComplete = () => {
if (onComplete) {
onComplete(selectedAccounts);
onComplete({
accounts: selectedAccounts,
walletName: module?.metadata.name || "Unknown",
});
}
};

Expand Down
7 changes: 6 additions & 1 deletion packages/account-export/src/lib/index.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,16 @@ import type {

export type Theme = "dark" | "light" | "auto";

type ExportSelectorOnCompleteParams = {
accounts: Array<string>;
walletName: string;
};

export interface ExportSelectorOptions {
theme?: Theme;
description?: string;
accounts: Array<AccountImportData>;
onComplete?: (accounts: Array<string>) => void;
onComplete?: (completeProps: ExportSelectorOnCompleteParams) => void;
}

export interface WalletSelectorModal {
Expand Down
2 changes: 1 addition & 1 deletion packages/coin98-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/coin98-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "Coin 98 wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/core",
"version": "8.1.0",
"version": "8.1.1",
"description": "This is the core package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/default-wallets/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/default-wallets",
"version": "8.1.0",
"version": "8.1.1",
"description": "Default wallets package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/finer-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/finer-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "FiNER Wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/here-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/here-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "Here wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/ledger/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/ledger",
"version": "8.1.0",
"version": "8.1.1",
"description": "Ledger package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/math-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/math-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "Math wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/meteor-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/meteor-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "Meteor wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/modal-ui-js/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/modal-ui-js",
"version": "8.1.0",
"version": "8.1.1",
"description": "Modal UI package for NEAR wallet Selector",
"keywords": [
"near",
Expand Down
6 changes: 5 additions & 1 deletion packages/modal-ui-js/src/lib/components/GetAWallet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ export async function renderGetAWallet() {
`;

const filterByType = (item: { type: string }) => {
return item.type !== "bridge" && item.type !== "hardware";
return (
item.type !== "bridge" &&
item.type !== "hardware" &&
item.type !== "instant-link"
);
};

const filteredModules = modalState.modules.filter(filterByType);
Expand Down
2 changes: 1 addition & 1 deletion packages/modal-ui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/modal-ui",
"version": "8.1.0",
"version": "8.1.1",
"description": "Modal UI package for NEAR wallet Selector",
"keywords": [
"near",
Expand Down
7 changes: 6 additions & 1 deletion packages/modal-ui/src/lib/components/WalletHome.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,11 @@ export const WalletHome: React.FC<WalletHomeProps> = ({
useEffect(() => {
const subscription = selector.store.observable.subscribe((state) => {
const filterByType = (item: { type: string }) => {
return item.type !== "bridge" && item.type !== "hardware";
return (
item.type !== "bridge" &&
item.type !== "hardware" &&
item.type !== "instant-link"
);
};

const filteredModules = state.modules.filter(filterByType);
Expand Down Expand Up @@ -113,6 +117,7 @@ export const WalletHome: React.FC<WalletHomeProps> = ({
})}
</div>
)}

{route === "WalletInfo" && (
<>
<div className="wallet-info-wrapper what-wallet-hide">
Expand Down
2 changes: 1 addition & 1 deletion packages/my-near-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/my-near-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "My Near Wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/narwallets/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/narwallets",
"version": "8.1.0",
"version": "8.1.1",
"description": "This is the Narwallets package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/near-snap/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/near-snap",
"version": "8.1.0",
"version": "8.1.1",
"description": "Metamask snap to interact with Near dapps.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/near-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/near-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "Near Wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/nearfi/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/nearfi",
"version": "8.1.0",
"version": "8.1.1",
"description": "Nearfi package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/neth/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/neth",
"version": "8.1.0",
"version": "8.1.1",
"description": "Control NEAR accounts with ETH accounts",
"author": "mattlockyer",
"keywords": [
Expand Down
2 changes: 1 addition & 1 deletion packages/nightly-connect/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/nightly-connect",
"version": "8.1.0",
"version": "8.1.1",
"description": "Nightly connect package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/nightly/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/nightly",
"version": "8.1.0",
"version": "8.1.1",
"description": "Nightly wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/opto-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/opto-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "Opto wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/sender/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/sender",
"version": "8.1.0",
"version": "8.1.1",
"description": "Sender wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/wallet-connect/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/wallet-connect",
"version": "8.1.0",
"version": "8.1.1",
"description": "Wallet Connect package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/wallet-utils/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/wallet-utils",
"version": "8.1.0",
"version": "8.1.1",
"description": "Wallet utils package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/welldone-wallet/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/welldone-wallet",
"version": "8.1.0",
"version": "8.1.1",
"description": "Welldone wallet package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down
2 changes: 1 addition & 1 deletion packages/xdefi/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-wallet-selector/xdefi",
"version": "8.1.0",
"version": "8.1.1",
"description": "This is the XDEFI package for NEAR Wallet Selector.",
"keywords": [
"near",
Expand Down

0 comments on commit 107ba92

Please sign in to comment.