@wallet-standard/features
Advanced tools
Comparing version 1.0.2 to 1.0.3
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Connect = void 0; | ||
exports.Connect = exports.StandardConnect = void 0; | ||
/** Name of the feature. */ | ||
exports.Connect = 'standard:connect'; | ||
exports.StandardConnect = 'standard:connect'; | ||
/** | ||
* @deprecated Use {@link StandardConnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
exports.Connect = exports.StandardConnect; | ||
//# sourceMappingURL=connect.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Disconnect = void 0; | ||
exports.Disconnect = exports.StandardDisconnect = void 0; | ||
/** Name of the feature. */ | ||
exports.Disconnect = 'standard:disconnect'; | ||
exports.StandardDisconnect = 'standard:disconnect'; | ||
/** | ||
* @deprecated Use {@link StandardDisconnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
exports.Disconnect = exports.StandardDisconnect; | ||
//# sourceMappingURL=disconnect.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Events = void 0; | ||
exports.Events = exports.StandardEvents = void 0; | ||
/** Name of the feature. */ | ||
exports.Events = 'standard:events'; | ||
exports.StandardEvents = 'standard:events'; | ||
/** | ||
* @deprecated Use {@link StandardEvents} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
exports.Events = exports.StandardEvents; | ||
//# sourceMappingURL=events.js.map |
/** Name of the feature. */ | ||
export const Connect = 'standard:connect'; | ||
export const StandardConnect = 'standard:connect'; | ||
/** | ||
* @deprecated Use {@link StandardConnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export const Connect = StandardConnect; | ||
//# sourceMappingURL=connect.js.map |
/** Name of the feature. */ | ||
export const Disconnect = 'standard:disconnect'; | ||
export const StandardDisconnect = 'standard:disconnect'; | ||
/** | ||
* @deprecated Use {@link StandardDisconnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export const Disconnect = StandardDisconnect; | ||
//# sourceMappingURL=disconnect.js.map |
/** Name of the feature. */ | ||
export const Events = 'standard:events'; | ||
export const StandardEvents = 'standard:events'; | ||
/** | ||
* @deprecated Use {@link StandardEvents} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export const Events = StandardEvents; | ||
//# sourceMappingURL=events.js.map |
import type { WalletAccount } from '@wallet-standard/base'; | ||
/** Name of the feature. */ | ||
export declare const StandardConnect = "standard:connect"; | ||
/** | ||
* @deprecated Use {@link StandardConnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare const Connect = "standard:connect"; | ||
@@ -11,31 +17,49 @@ /** | ||
*/ | ||
export declare type ConnectFeature = { | ||
export declare type StandardConnectFeature = { | ||
/** Name of the feature. */ | ||
readonly [Connect]: { | ||
readonly [StandardConnect]: { | ||
/** Version of the feature implemented by the Wallet. */ | ||
readonly version: ConnectVersion; | ||
readonly version: StandardConnectVersion; | ||
/** Method to call to use the feature. */ | ||
readonly connect: ConnectMethod; | ||
readonly connect: StandardConnectMethod; | ||
}; | ||
}; | ||
/** | ||
* Version of the {@link ConnectFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* @deprecated Use {@link StandardConnectFeature} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type ConnectFeature = StandardConnectFeature; | ||
/** | ||
* Version of the {@link StandardConnectFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* | ||
* @group Connect | ||
*/ | ||
export declare type ConnectVersion = '1.0.0'; | ||
export declare type StandardConnectVersion = '1.0.0'; | ||
/** | ||
* Method to call to use the {@link ConnectFeature}. | ||
* @deprecated Use {@link StandardConnectVersion} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type ConnectVersion = StandardConnectVersion; | ||
/** | ||
* Method to call to use the {@link StandardConnectFeature}. | ||
* | ||
* @group Connect | ||
*/ | ||
export declare type ConnectMethod = (input?: ConnectInput) => Promise<ConnectOutput>; | ||
export declare type StandardConnectMethod = (input?: StandardConnectInput) => Promise<StandardConnectOutput>; | ||
/** | ||
* Input for the {@link ConnectMethod}. | ||
* @deprecated Use {@link StandardConnectMethod} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type ConnectMethod = StandardConnectMethod; | ||
/** | ||
* Input for the {@link StandardConnectMethod}. | ||
* | ||
* @group Connect | ||
*/ | ||
export interface ConnectInput { | ||
export interface StandardConnectInput { | ||
/** | ||
* By default, using the {@link ConnectFeature} should prompt the user to request authorization to accounts. | ||
* By default, using the {@link StandardConnectFeature} should prompt the user to request authorization to accounts. | ||
* Set the `silent` flag to `true` to request accounts that have already been authorized without prompting. | ||
@@ -50,10 +74,22 @@ * | ||
/** | ||
* Output of the {@link ConnectMethod}. | ||
* @deprecated Use {@link StandardConnectInput} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type ConnectInput = StandardConnectInput; | ||
/** | ||
* Output of the {@link StandardConnectMethod}. | ||
* | ||
* @group Connect | ||
*/ | ||
export interface ConnectOutput { | ||
export interface StandardConnectOutput { | ||
/** List of accounts in the {@link "@wallet-standard/base".Wallet} that the app has been authorized to use. */ | ||
readonly accounts: readonly WalletAccount[]; | ||
} | ||
/** | ||
* @deprecated Use {@link StandardConnectOutput} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type ConnectOutput = StandardConnectOutput; | ||
//# sourceMappingURL=connect.d.ts.map |
/** Name of the feature. */ | ||
export declare const StandardDisconnect = "standard:disconnect"; | ||
/** | ||
* @deprecated Use {@link StandardDisconnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare const Disconnect = "standard:disconnect"; | ||
@@ -13,23 +19,41 @@ /** | ||
*/ | ||
export declare type DisconnectFeature = { | ||
export declare type StandardDisconnectFeature = { | ||
/** Name of the feature. */ | ||
readonly [Disconnect]: { | ||
readonly [StandardDisconnect]: { | ||
/** Version of the feature implemented by the Wallet. */ | ||
readonly version: DisconnectVersion; | ||
readonly version: StandardDisconnectVersion; | ||
/** Method to call to use the feature. */ | ||
readonly disconnect: DisconnectMethod; | ||
readonly disconnect: StandardDisconnectMethod; | ||
}; | ||
}; | ||
/** | ||
* Version of the {@link DisconnectFeature} implemented by a Wallet. | ||
* @deprecated Use {@link StandardDisconnectFeature} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type DisconnectFeature = StandardDisconnectFeature; | ||
/** | ||
* Version of the {@link StandardDisconnectFeature} implemented by a Wallet. | ||
* | ||
* @group Disconnect | ||
*/ | ||
export declare type DisconnectVersion = '1.0.0'; | ||
export declare type StandardDisconnectVersion = '1.0.0'; | ||
/** | ||
* Method to call to use the {@link DisconnectFeature}. | ||
* @deprecated Use {@link StandardDisconnectVersion} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type DisconnectVersion = StandardDisconnectVersion; | ||
/** | ||
* Method to call to use the {@link StandardDisconnectFeature}. | ||
* | ||
* @group Disconnect | ||
*/ | ||
export declare type DisconnectMethod = () => Promise<void>; | ||
export declare type StandardDisconnectMethod = () => Promise<void>; | ||
/** | ||
* @deprecated Use {@link StandardDisconnectMethod} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type DisconnectMethod = StandardDisconnectMethod; | ||
//# sourceMappingURL=disconnect.d.ts.map |
import type { Wallet } from '@wallet-standard/base'; | ||
/** Name of the feature. */ | ||
export declare const StandardEvents = "standard:events"; | ||
/** | ||
* @deprecated Use {@link StandardEvents} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare const Events = "standard:events"; | ||
@@ -7,25 +13,37 @@ /** | ||
* {@link "@wallet-standard/base".Wallet} to allow the app to add an event listener and subscribe to events emitted by | ||
* the Wallet when properties of the Wallet {@link EventsListeners.change}. | ||
* the Wallet when properties of the Wallet {@link StandardEventsListeners.change}. | ||
* | ||
* @group Events | ||
*/ | ||
export declare type EventsFeature = { | ||
export declare type StandardEventsFeature = { | ||
/** Name of the feature. */ | ||
readonly [Events]: { | ||
readonly [StandardEvents]: { | ||
/** Version of the feature implemented by the {@link "@wallet-standard/base".Wallet}. */ | ||
readonly version: EventsVersion; | ||
readonly version: StandardEventsVersion; | ||
/** Method to call to use the feature. */ | ||
readonly on: EventsOnMethod; | ||
readonly on: StandardEventsOnMethod; | ||
}; | ||
}; | ||
/** | ||
* Version of the {@link EventsFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* @deprecated Use {@link StandardEventsFeature} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type EventsFeature = StandardEventsFeature; | ||
/** | ||
* Version of the {@link StandardEventsFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* | ||
* @group Events | ||
*/ | ||
export declare type EventsVersion = '1.0.0'; | ||
export declare type StandardEventsVersion = '1.0.0'; | ||
/** | ||
* Method to call to use the {@link EventsFeature}. | ||
* @deprecated Use {@link StandardEventsVersion} instead. | ||
* | ||
* @param event Event type to listen for. {@link EventsListeners.change | `change`} is the only event type. | ||
* @group Deprecated | ||
*/ | ||
export declare type EventsVersion = StandardEventsVersion; | ||
/** | ||
* Method to call to use the {@link StandardEventsFeature}. | ||
* | ||
* @param event Event type to listen for. {@link StandardEventsListeners.change | `change`} is the only event type. | ||
* @param listener Function that will be called when an event of the type is emitted. | ||
@@ -40,11 +58,17 @@ * | ||
*/ | ||
export declare type EventsOnMethod = <E extends EventsNames>(event: E, listener: EventsListeners[E]) => () => void; | ||
export declare type StandardEventsOnMethod = <E extends StandardEventsNames>(event: E, listener: StandardEventsListeners[E]) => () => void; | ||
/** | ||
* Types of event listeners of the {@link EventsFeature}. | ||
* @deprecated Use {@link StandardEventsOnMethod} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type EventsOnMethod = StandardEventsOnMethod; | ||
/** | ||
* Types of event listeners of the {@link StandardEventsFeature}. | ||
* | ||
* @group Events | ||
*/ | ||
export interface EventsListeners { | ||
export interface StandardEventsListeners { | ||
/** | ||
* Listener that will be called when {@link EventsChangeProperties | properties} of the | ||
* Listener that will be called when {@link StandardEventsChangeProperties | properties} of the | ||
* {@link "@wallet-standard/base".Wallet} have changed. | ||
@@ -54,12 +78,24 @@ * | ||
*/ | ||
change(properties: EventsChangeProperties): void; | ||
change(properties: StandardEventsChangeProperties): void; | ||
} | ||
/** | ||
* Names of {@link EventsListeners} that can be listened for. | ||
* @deprecated Use {@link StandardEventsListeners} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type EventsListeners = StandardEventsListeners; | ||
/** | ||
* Names of {@link StandardEventsListeners} that can be listened for. | ||
* | ||
* @group Events | ||
*/ | ||
export declare type EventsNames = keyof EventsListeners; | ||
export declare type StandardEventsNames = keyof StandardEventsListeners; | ||
/** | ||
* Properties of a {@link "@wallet-standard/base".Wallet} that {@link EventsListeners.change | changed} with their | ||
* @deprecated Use {@link StandardEventsNames} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type EventsNames = StandardEventsNames; | ||
/** | ||
* Properties of a {@link "@wallet-standard/base".Wallet} that {@link StandardEventsListeners.change | changed} with their | ||
* **new** values. | ||
@@ -69,3 +105,3 @@ * | ||
*/ | ||
export interface EventsChangeProperties { | ||
export interface StandardEventsChangeProperties { | ||
/** | ||
@@ -96,2 +132,8 @@ * {@link "@wallet-standard/base".Wallet.chains | Chains} supported by the Wallet. | ||
} | ||
/** | ||
* @deprecated Use {@link StandardEventsChangeProperties} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export declare type EventsChangeProperties = StandardEventsChangeProperties; | ||
//# sourceMappingURL=events.d.ts.map |
import type { WalletWithFeatures } from '@wallet-standard/base'; | ||
import type { ConnectFeature } from './connect.js'; | ||
import type { DisconnectFeature } from './disconnect.js'; | ||
import type { EventsFeature } from './events.js'; | ||
import type { StandardConnectFeature } from './connect.js'; | ||
import type { StandardDisconnectFeature } from './disconnect.js'; | ||
import type { StandardEventsFeature } from './events.js'; | ||
/** | ||
@@ -11,3 +11,3 @@ * Type alias for some or all {@link "@wallet-standard/base".Wallet.features} implemented within the reserved `standard` | ||
*/ | ||
export declare type StandardFeatures = ConnectFeature | DisconnectFeature | EventsFeature; | ||
export declare type StandardFeatures = StandardConnectFeature | StandardDisconnectFeature | StandardEventsFeature; | ||
/** | ||
@@ -14,0 +14,0 @@ * Type alias for a {@link "@wallet-standard/base".Wallet} that implements some or all {@link StandardFeatures}. |
{ | ||
"name": "@wallet-standard/features", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"author": "Solana Maintainers <maintainers@solana.foundation>", | ||
@@ -5,0 +5,0 @@ "repository": "https://github.com/wallet-standard/wallet-standard", |
import type { WalletAccount } from '@wallet-standard/base'; | ||
/** Name of the feature. */ | ||
export const Connect = 'standard:connect'; | ||
export const StandardConnect = 'standard:connect'; | ||
/** | ||
* @deprecated Use {@link StandardConnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export const Connect = StandardConnect; | ||
@@ -13,34 +19,52 @@ /** | ||
*/ | ||
export type ConnectFeature = { | ||
export type StandardConnectFeature = { | ||
/** Name of the feature. */ | ||
readonly [Connect]: { | ||
readonly [StandardConnect]: { | ||
/** Version of the feature implemented by the Wallet. */ | ||
readonly version: ConnectVersion; | ||
readonly version: StandardConnectVersion; | ||
/** Method to call to use the feature. */ | ||
readonly connect: ConnectMethod; | ||
readonly connect: StandardConnectMethod; | ||
}; | ||
}; | ||
/** | ||
* @deprecated Use {@link StandardConnectFeature} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type ConnectFeature = StandardConnectFeature; | ||
/** | ||
* Version of the {@link ConnectFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* Version of the {@link StandardConnectFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* | ||
* @group Connect | ||
*/ | ||
export type ConnectVersion = '1.0.0'; | ||
export type StandardConnectVersion = '1.0.0'; | ||
/** | ||
* @deprecated Use {@link StandardConnectVersion} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type ConnectVersion = StandardConnectVersion; | ||
/** | ||
* Method to call to use the {@link ConnectFeature}. | ||
* Method to call to use the {@link StandardConnectFeature}. | ||
* | ||
* @group Connect | ||
*/ | ||
export type ConnectMethod = (input?: ConnectInput) => Promise<ConnectOutput>; | ||
export type StandardConnectMethod = (input?: StandardConnectInput) => Promise<StandardConnectOutput>; | ||
/** | ||
* @deprecated Use {@link StandardConnectMethod} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type ConnectMethod = StandardConnectMethod; | ||
/** | ||
* Input for the {@link ConnectMethod}. | ||
* Input for the {@link StandardConnectMethod}. | ||
* | ||
* @group Connect | ||
*/ | ||
export interface ConnectInput { | ||
export interface StandardConnectInput { | ||
/** | ||
* By default, using the {@link ConnectFeature} should prompt the user to request authorization to accounts. | ||
* By default, using the {@link StandardConnectFeature} should prompt the user to request authorization to accounts. | ||
* Set the `silent` flag to `true` to request accounts that have already been authorized without prompting. | ||
@@ -54,11 +78,23 @@ * | ||
} | ||
/** | ||
* @deprecated Use {@link StandardConnectInput} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type ConnectInput = StandardConnectInput; | ||
/** | ||
* Output of the {@link ConnectMethod}. | ||
* Output of the {@link StandardConnectMethod}. | ||
* | ||
* @group Connect | ||
*/ | ||
export interface ConnectOutput { | ||
export interface StandardConnectOutput { | ||
/** List of accounts in the {@link "@wallet-standard/base".Wallet} that the app has been authorized to use. */ | ||
readonly accounts: readonly WalletAccount[]; | ||
} | ||
/** | ||
* @deprecated Use {@link StandardConnectOutput} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type ConnectOutput = StandardConnectOutput; |
/** Name of the feature. */ | ||
export const Disconnect = 'standard:disconnect'; | ||
export const StandardDisconnect = 'standard:disconnect'; | ||
/** | ||
* @deprecated Use {@link StandardDisconnect} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export const Disconnect = StandardDisconnect; | ||
@@ -14,24 +20,42 @@ /** | ||
*/ | ||
export type DisconnectFeature = { | ||
export type StandardDisconnectFeature = { | ||
/** Name of the feature. */ | ||
readonly [Disconnect]: { | ||
readonly [StandardDisconnect]: { | ||
/** Version of the feature implemented by the Wallet. */ | ||
readonly version: DisconnectVersion; | ||
readonly version: StandardDisconnectVersion; | ||
/** Method to call to use the feature. */ | ||
readonly disconnect: DisconnectMethod; | ||
readonly disconnect: StandardDisconnectMethod; | ||
}; | ||
}; | ||
/** | ||
* @deprecated Use {@link StandardDisconnectFeature} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type DisconnectFeature = StandardDisconnectFeature; | ||
/** | ||
* Version of the {@link DisconnectFeature} implemented by a Wallet. | ||
* Version of the {@link StandardDisconnectFeature} implemented by a Wallet. | ||
* | ||
* @group Disconnect | ||
*/ | ||
export type DisconnectVersion = '1.0.0'; | ||
export type StandardDisconnectVersion = '1.0.0'; | ||
/** | ||
* @deprecated Use {@link StandardDisconnectVersion} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type DisconnectVersion = StandardDisconnectVersion; | ||
/** | ||
* Method to call to use the {@link DisconnectFeature}. | ||
* Method to call to use the {@link StandardDisconnectFeature}. | ||
* | ||
* @group Disconnect | ||
*/ | ||
export type DisconnectMethod = () => Promise<void>; | ||
export type StandardDisconnectMethod = () => Promise<void>; | ||
/** | ||
* @deprecated Use {@link StandardDisconnectMethod} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type DisconnectMethod = StandardDisconnectMethod; |
import type { Wallet } from '@wallet-standard/base'; | ||
/** Name of the feature. */ | ||
export const Events = 'standard:events'; | ||
export const StandardEvents = 'standard:events'; | ||
/** | ||
* @deprecated Use {@link StandardEvents} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export const Events = StandardEvents; | ||
@@ -9,27 +15,39 @@ /** | ||
* {@link "@wallet-standard/base".Wallet} to allow the app to add an event listener and subscribe to events emitted by | ||
* the Wallet when properties of the Wallet {@link EventsListeners.change}. | ||
* the Wallet when properties of the Wallet {@link StandardEventsListeners.change}. | ||
* | ||
* @group Events | ||
*/ | ||
export type EventsFeature = { | ||
export type StandardEventsFeature = { | ||
/** Name of the feature. */ | ||
readonly [Events]: { | ||
readonly [StandardEvents]: { | ||
/** Version of the feature implemented by the {@link "@wallet-standard/base".Wallet}. */ | ||
readonly version: EventsVersion; | ||
readonly version: StandardEventsVersion; | ||
/** Method to call to use the feature. */ | ||
readonly on: EventsOnMethod; | ||
readonly on: StandardEventsOnMethod; | ||
}; | ||
}; | ||
/** | ||
* @deprecated Use {@link StandardEventsFeature} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type EventsFeature = StandardEventsFeature; | ||
/** | ||
* Version of the {@link EventsFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* Version of the {@link StandardEventsFeature} implemented by a {@link "@wallet-standard/base".Wallet}. | ||
* | ||
* @group Events | ||
*/ | ||
export type EventsVersion = '1.0.0'; | ||
export type StandardEventsVersion = '1.0.0'; | ||
/** | ||
* @deprecated Use {@link StandardEventsVersion} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type EventsVersion = StandardEventsVersion; | ||
/** | ||
* Method to call to use the {@link EventsFeature}. | ||
* Method to call to use the {@link StandardEventsFeature}. | ||
* | ||
* @param event Event type to listen for. {@link EventsListeners.change | `change`} is the only event type. | ||
* @param event Event type to listen for. {@link StandardEventsListeners.change | `change`} is the only event type. | ||
* @param listener Function that will be called when an event of the type is emitted. | ||
@@ -44,12 +62,21 @@ * | ||
*/ | ||
export type EventsOnMethod = <E extends EventsNames>(event: E, listener: EventsListeners[E]) => () => void; | ||
export type StandardEventsOnMethod = <E extends StandardEventsNames>( | ||
event: E, | ||
listener: StandardEventsListeners[E] | ||
) => () => void; | ||
/** | ||
* @deprecated Use {@link StandardEventsOnMethod} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type EventsOnMethod = StandardEventsOnMethod; | ||
/** | ||
* Types of event listeners of the {@link EventsFeature}. | ||
* Types of event listeners of the {@link StandardEventsFeature}. | ||
* | ||
* @group Events | ||
*/ | ||
export interface EventsListeners { | ||
export interface StandardEventsListeners { | ||
/** | ||
* Listener that will be called when {@link EventsChangeProperties | properties} of the | ||
* Listener that will be called when {@link StandardEventsChangeProperties | properties} of the | ||
* {@link "@wallet-standard/base".Wallet} have changed. | ||
@@ -59,14 +86,26 @@ * | ||
*/ | ||
change(properties: EventsChangeProperties): void; | ||
change(properties: StandardEventsChangeProperties): void; | ||
} | ||
/** | ||
* @deprecated Use {@link StandardEventsListeners} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type EventsListeners = StandardEventsListeners; | ||
/** | ||
* Names of {@link EventsListeners} that can be listened for. | ||
* Names of {@link StandardEventsListeners} that can be listened for. | ||
* | ||
* @group Events | ||
*/ | ||
export type EventsNames = keyof EventsListeners; | ||
export type StandardEventsNames = keyof StandardEventsListeners; | ||
/** | ||
* @deprecated Use {@link StandardEventsNames} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type EventsNames = StandardEventsNames; | ||
/** | ||
* Properties of a {@link "@wallet-standard/base".Wallet} that {@link EventsListeners.change | changed} with their | ||
* Properties of a {@link "@wallet-standard/base".Wallet} that {@link StandardEventsListeners.change | changed} with their | ||
* **new** values. | ||
@@ -76,3 +115,3 @@ * | ||
*/ | ||
export interface EventsChangeProperties { | ||
export interface StandardEventsChangeProperties { | ||
/** | ||
@@ -103,1 +142,7 @@ * {@link "@wallet-standard/base".Wallet.chains | Chains} supported by the Wallet. | ||
} | ||
/** | ||
* @deprecated Use {@link StandardEventsChangeProperties} instead. | ||
* | ||
* @group Deprecated | ||
*/ | ||
export type EventsChangeProperties = StandardEventsChangeProperties; |
import type { WalletWithFeatures } from '@wallet-standard/base'; | ||
import type { ConnectFeature } from './connect.js'; | ||
import type { DisconnectFeature } from './disconnect.js'; | ||
import type { EventsFeature } from './events.js'; | ||
import type { StandardConnectFeature } from './connect.js'; | ||
import type { StandardDisconnectFeature } from './disconnect.js'; | ||
import type { StandardEventsFeature } from './events.js'; | ||
@@ -12,3 +12,3 @@ /** | ||
*/ | ||
export type StandardFeatures = ConnectFeature | DisconnectFeature | EventsFeature; | ||
export type StandardFeatures = StandardConnectFeature | StandardDisconnectFeature | StandardEventsFeature; | ||
@@ -15,0 +15,0 @@ /** |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
41254
686