Skip to content

Commit

Permalink
added compiled files
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilya committed Nov 20, 2024
1 parent cb41fb9 commit 62feeb0
Show file tree
Hide file tree
Showing 13 changed files with 93 additions and 17 deletions.
8 changes: 4 additions & 4 deletions dist/esbuild/main.js.map

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export interface IKeySharesData {
get operatorIds(): number[];
get operatorPublicKeys(): string[];
}
export interface IKeySharesPartitialData {
export interface IKeySharesPartialData {
ownerNonce?: number | null;
ownerAddress?: string | null;
publicKey?: string | null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export interface IKeySharesPayload {
validate(): void;
build(data: any): any;
}
export interface IKeySharesPartitialPayload {
export interface IKeySharesPartialPayload {
sharesData: string;
publicKey: string;
operatorIds: number[];
Expand Down
4 changes: 2 additions & 2 deletions dist/tsc/src/lib/KeyShares/KeySharesData/KeySharesData.d.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { OperatorData } from './OperatorData';
import { IKeySharesData, IKeySharesPartitialData } from './IKeySharesData';
import { IKeySharesData, IKeySharesPartialData } from './IKeySharesData';
export declare class KeySharesData implements IKeySharesData {
ownerNonce?: number | null;
ownerAddress?: string | null;
publicKey?: string | null;
operators?: OperatorData[] | null;
update(data: IKeySharesPartitialData): void;
update(data: IKeySharesPartialData): void;
/**
* Do all possible validations.
*/
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { IKeySharesPartitialPayload, IKeySharesPayload } from './IKeySharesPayload';
import { IKeySharesPartialPayload, IKeySharesPayload } from './IKeySharesPayload';
/**
* Key Shares Payload
*/
Expand All @@ -17,7 +17,7 @@ export declare class KeySharesPayload implements IKeySharesPayload {
* Updates the payload with new data and validates it.
* @param data Partial key shares payload to update.
*/
update(data: IKeySharesPartitialPayload): void;
update(data: IKeySharesPartialPayload): void;
/**
* Validates the current state of the instance.
* @returns {void | ValidationError[]} Validation errors if any, otherwise undefined.
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions dist/tsc/src/lib/KeyShares/KeySharesItem.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { KeySharesData } from './KeySharesData/KeySharesData';
import { KeySharesPayload } from './KeySharesData/KeySharesPayload';
import { EncryptShare } from '../Encryption/Encryption';
import { IKeySharesPartitialData } from './KeySharesData/IKeySharesData';
import { IKeySharesPartialData } from './KeySharesData/IKeySharesData';
import { IOperator } from './KeySharesData/IOperator';
import { SSVKeysException } from '../exceptions/base';
export interface IKeySharesPayloadData {
Expand Down Expand Up @@ -41,7 +41,7 @@ export declare class KeySharesItem {
/**
* Updates the current instance with partial data and payload, and validates.
*/
update(data: IKeySharesPartitialData): void;
update(data: IKeySharesPartialData): void;
/**
* Validate everything
*/
Expand Down
1 change: 0 additions & 1 deletion dist/tsc/src/lib/KeyShares/KeySharesItem.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/tsc/src/lib/KeyShares/KeySharesItem.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 22 additions & 0 deletions dist/tsc/src/lib/SSVKeys.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,15 @@ export interface ExtractedKeys {
privateKey: string;
publicKey: string;
}
interface ISharesValidation {
shares: string;
operatorsCount: number;
validatorPublicKey: string;
isAccountExists: boolean;
ownerAddress: string;
ownerNonce: number;
blockNumber: number;
}
/**
* SSVKeys class provides high-level methods to easily work with entire flow:
* - getting private key from keystore file using password
Expand Down Expand Up @@ -44,4 +53,17 @@ export declare class SSVKeys {
* Getting threshold if it has been created before.
*/
getThreshold(): ISharesKeyPairs | undefined;
validateSharesPostRegistration({ shares, operatorsCount, validatorPublicKey, isAccountExists, ownerAddress, ownerNonce, blockNumber }: ISharesValidation): Promise<{
isValid: boolean;
isSharesValid: boolean;
sharesPublicKeys: any;
encryptedKeys: any;
memo: {
message: string;
error: string;
data: string;
blockNumber: number;
}[];
}>;
}
export {};
Loading

0 comments on commit 62feeb0

Please sign in to comment.