-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into fix/oct-1505-proposals-cid-fix
- Loading branch information
Showing
32 changed files
with
410 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
BLOCK_NUMBER=5652838 | ||
BLOCK_NUMBER=5654008 | ||
GLM_CONTRACT_ADDRESS=0x71432DD1ae7DB41706ee6a22148446087BdD0906 | ||
AUTH_CONTRACT_ADDRESS=0x1a98D5fb178e63be8970F24d5f900bd9906C184A | ||
DEPOSITS_CONTRACT_ADDRESS=0x37c5364E7c95df8F355d68181Bd5d257765077d2 | ||
EPOCHS_CONTRACT_ADDRESS=0x2946547419F7Ae4F08a7447038158eE028886db7 | ||
PROPOSALS_CONTRACT_ADDRESS=0x0ffD9d36cC7CECFCB2Da929a416497669d0b2Bfd | ||
WITHDRAWALS_TARGET_CONTRACT_ADDRESS=0x71CeaAdB6e2ff28e59c5098525F25CC494650e5D | ||
VAULT_CONTRACT_ADDRESS=0x286baF6a4c8d047b821Ea25C8cfe977369d0087B | ||
AUTH_CONTRACT_ADDRESS=0xF5c7A09df8a0422B490cB215c6B3bC473A1C87A3 | ||
DEPOSITS_CONTRACT_ADDRESS=0x2043c7262A19493cD293d865c56482AF122f8882 | ||
EPOCHS_CONTRACT_ADDRESS=0xcdba82F0AfEe0B6b0aa78C5D6F9DA526834d6d5f | ||
PROPOSALS_CONTRACT_ADDRESS=0x026293cc6A739fe0E1E7a602fbB1bEea7CfE82E6 | ||
WITHDRAWALS_TARGET_CONTRACT_ADDRESS=0x2e7efFafDf380ac0e699478C89368BaF7d0ebF5d | ||
VAULT_CONTRACT_ADDRESS=0xcCFEF3B1eE18ee4e020F434D07b12f5E6272a253 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import env from 'env'; | ||
import apiService from 'services/apiService'; | ||
|
||
// eslint-disable-next-line no-shadow | ||
export enum SignatureOpType { | ||
ALLOCATION = 'allocation', | ||
TOS = 'tos', | ||
} | ||
|
||
export type PendingMultisigSignatures = { | ||
hash: string | undefined; | ||
message: string | undefined; | ||
}; | ||
|
||
export async function apiGetPendingMultisigSignatures( | ||
userAddress: string, | ||
signatureOpType: SignatureOpType, | ||
): Promise<PendingMultisigSignatures> { | ||
return apiService | ||
.get(`${env.serverEndpoint}multisig-signatures/pending/${userAddress}/type/${signatureOpType}`) | ||
.then(({ data }) => data); | ||
} | ||
|
||
export async function apiPostPendingMultisigSignatures( | ||
userAddress: string, | ||
message: | ||
| string | ||
| { | ||
isManuallyEdited: boolean; | ||
payload: { | ||
allocations: { amount: string; proposalAddress: string }[]; | ||
nonce: number; | ||
}; | ||
}, | ||
signatureOpType: SignatureOpType, | ||
): Promise<any> { | ||
return apiService | ||
.post( | ||
`${env.serverEndpoint}multisig-signatures/pending/${userAddress}/type/${signatureOpType}`, | ||
{ message }, | ||
) | ||
.then(({ data }) => data); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 5 additions & 0 deletions
5
.../EarnHistoryItemDetails/EarnHistoryItemDetailsRest/EarnHistoryItemDetailsRest.module.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,8 @@ | ||
.viewOnEtherscan { | ||
padding: 0; | ||
|
||
&.isMultisig { | ||
opacity: 0.5; | ||
pointer-events: none; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 18 additions & 7 deletions
25
...c/components/Earn/EarnHistory/EarnHistoryTransactionLabel/EarnHistoryTransactionLabel.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,30 @@ | ||
import cx from 'classnames'; | ||
import React, { FC } from 'react'; | ||
import React, { FC, useMemo } from 'react'; | ||
import { useTranslation } from 'react-i18next'; | ||
|
||
import styles from './EarnHistoryTransactionLabel.module.scss'; | ||
import EarnHistoryTransactionLabelProps from './types'; | ||
|
||
const EarnHistoryTransactionLabel: FC<EarnHistoryTransactionLabelProps> = ({ isFinalized }) => { | ||
const EarnHistoryTransactionLabel: FC<EarnHistoryTransactionLabelProps> = ({ | ||
isFinalized, | ||
isMultisig, | ||
}) => { | ||
const { t } = useTranslation('translation', { | ||
keyPrefix: 'components.dedicated.historyTransactionLabel', | ||
}); | ||
return ( | ||
<div className={cx(styles.root, isFinalized && styles.isFinalized)}> | ||
{isFinalized ? t('confirmed') : t('pending')} | ||
</div> | ||
); | ||
|
||
const label = useMemo(() => { | ||
if (isMultisig) { | ||
return t('pendingMultisig'); | ||
} | ||
if (isFinalized) { | ||
return t('confirmed'); | ||
} | ||
return t('pending'); | ||
// eslint-disable-next-line react-hooks/exhaustive-deps | ||
}, [isFinalized, isMultisig]); | ||
|
||
return <div className={cx(styles.root, isFinalized && styles.isFinalized)}>{label}</div>; | ||
}; | ||
|
||
export default EarnHistoryTransactionLabel; |
1 change: 1 addition & 0 deletions
1
client/src/components/Earn/EarnHistory/EarnHistoryTransactionLabel/types.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
export default interface EarnHistoryTransactionLabelProps { | ||
isFinalized: boolean; | ||
isMultisig?: boolean; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.