* Provide metadata from external source * Listing via metadata interface * Updates * UI update * Storage & end-to-end
29 lines
906 B
TypeScript
29 lines
906 B
TypeScript
// Copyright 2019-2020 @polkadot/extension authors & contributors
|
|
// This software may be modified and distributed under the terms
|
|
// of the Apache-2.0 license. See the LICENSE file for details.
|
|
|
|
import PostMessageProvider from './PostMessageProvider';
|
|
import { Injected } from '@polkadot/extension-inject/types';
|
|
import { SendRequest } from './types';
|
|
|
|
import Accounts from './Accounts';
|
|
import Metadata from './Metadata';
|
|
import Signer from './Signer';
|
|
|
|
export default class implements Injected {
|
|
public readonly accounts: Accounts;
|
|
|
|
public readonly metadata: Metadata;
|
|
|
|
public readonly provider: PostMessageProvider;
|
|
|
|
public readonly signer: Signer;
|
|
|
|
constructor (sendRequest: SendRequest) {
|
|
this.accounts = new Accounts(sendRequest);
|
|
this.metadata = new Metadata(sendRequest);
|
|
this.provider = new PostMessageProvider(sendRequest);
|
|
this.signer = new Signer(sendRequest);
|
|
}
|
|
}
|