mirror of
https://github.com/status-im/MyCrypto.git
synced 2025-01-14 13:06:10 +00:00
db6b737cad
* Save transactions to local storage. * Checksum more things + reset hash on network change. * Fix IHexTransaction type, grab from from tx object directly. * Refactor storage of recent transactions to use redux storage and loading. * Refactor types to a transactions types file. * Initial crack at recent transactions tab on account * Punctuation. * Transaction Status responsive behavior. * Refactor transaction helper function out to remove circular dependency. * Fix typings * Collapse subtabs to select list when too small. * s/wallet/address * Type select onChange * Get fields from current state if web3 tx
36 lines
1.1 KiB
TypeScript
36 lines
1.1 KiB
TypeScript
import * as interfaces from './actionTypes';
|
|
import { TypeKeys } from './constants';
|
|
|
|
export type TFetchTransactionData = typeof fetchTransactionData;
|
|
export function fetchTransactionData(txhash: string): interfaces.FetchTransactionDataAction {
|
|
return {
|
|
type: TypeKeys.TRANSACTIONS_FETCH_TRANSACTION_DATA,
|
|
payload: txhash
|
|
};
|
|
}
|
|
|
|
export type TSetTransactionData = typeof setTransactionData;
|
|
export function setTransactionData(
|
|
payload: interfaces.SetTransactionDataAction['payload']
|
|
): interfaces.SetTransactionDataAction {
|
|
return {
|
|
type: TypeKeys.TRANSACTIONS_SET_TRANSACTION_DATA,
|
|
payload
|
|
};
|
|
}
|
|
|
|
export type TResetTransactionData = typeof resetTransactionData;
|
|
export function resetTransactionData(): interfaces.ResetTransactionDataAction {
|
|
return { type: TypeKeys.TRANSACTIONS_RESET_TRANSACTION_DATA };
|
|
}
|
|
|
|
export type TAddRecentTransaction = typeof addRecentTransaction;
|
|
export function addRecentTransaction(
|
|
payload: interfaces.AddRecentTransactionAction['payload']
|
|
): interfaces.AddRecentTransactionAction {
|
|
return {
|
|
type: TypeKeys.TRANSACTIONS_ADD_RECENT_TRANSACTION,
|
|
payload
|
|
};
|
|
}
|