Skip to content

Commit

Permalink
Merge pull request #2832 from Emurgo/Ahmed/multi-assets
Browse files Browse the repository at this point in the history
Enable multi-asset sending in the revamp
  • Loading branch information
vsubhuman committed Jun 29, 2022
2 parents d6ee5fd + dec10d9 commit 05ea645
Show file tree
Hide file tree
Showing 41 changed files with 2,104 additions and 1,018 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@ export default class TxBuilderActions {
updateReceiver: Action<void | string> = new Action();
updateAmount: Action<?BigNumber> = new Action();
updateMemo: Action<void | string> = new Action();
updateToken: Action<void | $ReadOnly<TokenRow>> = new Action();
addToken: Action<{|
token?: $ReadOnly<TokenRow>,
shouldReset?: boolean,
|}> = new Action();
deselectToken: Action<void> = new Action();
removeTokens: Action<Array<$ReadOnly<TokenRow>>> = new Action();
updateTentativeTx: Action<void> = new Action();
setFilter: Action<(ElementOf<IGetAllUtxosResponse> => boolean)> = new Action();
updateMetadata: Action<Array<TransactionMetadata> | void> = new Action();
Expand Down
3 changes: 2 additions & 1 deletion packages/yoroi-extension/app/api/common/errors.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const messages = defineMessages({
},
cannotSendBelowMinimumValueError: {
id: 'api.errors.CannotSendBelowMinimumValueError',
defaultMessage: '!!!Minimum required is 1 ADA',
defaultMessage: '!!!Cannot send blow minimum required value',
},
assetOverflowError: {
id: 'api.errors.assetOverflowError',
Expand Down Expand Up @@ -259,6 +259,7 @@ export class NotEnoughMoneyToSendError extends LocalizableError {
});
}
}

export class CannotSendBelowMinimumValueError extends LocalizableError {
constructor() {
super({
Expand Down
6 changes: 2 additions & 4 deletions packages/yoroi-extension/app/api/common/types.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@ export type CreateWalletFunc = (

export type SendTokenList = Array<$ReadOnly<{|
token: $ReadOnly<TokenRow>,
amount: string, // in lovelaces
|}> | $ReadOnly<{|
token: $ReadOnly<TokenRow>,
shouldSendAll: true,
amount?: string, // in lovelaces
shouldSendAll?: boolean,
|}>>;
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 05ea645

Please sign in to comment.