Skip to content
This repository has been archived by the owner on Jun 24, 2022. It is now read-only.

[Claim - ClaimTable - Pending] - Show loader and minor style change #2162

Merged
merged 3 commits into from
Jan 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 13 additions & 7 deletions src/custom/pages/Claim/ClaimsTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ import { ClaimStatus } from 'state/claim/actions'
import { formatSmart } from 'utils/format'
import { EnhancedUserClaimData } from './types'
import { useAllClaimingTransactionIndices } from 'state/enhancedTransactions/hooks'
import { CustomLightSpinner } from 'theme'
import Circle from 'assets/images/blue-loader.svg'

type ClaimsTableProps = {
handleSelectAll: (event: React.ChangeEvent<HTMLInputElement>) => void
Expand Down Expand Up @@ -54,13 +56,17 @@ const ClaimsTableRow = ({
<td>
{' '}
<label className="checkAll">
<input
onChange={(event) => handleSelect(event, index)}
type="checkbox"
name="check"
checked={isFree || selected.includes(index)}
disabled={isFree}
/>
{isPendingClaim ? (
<CustomLightSpinner src={Circle} title="Claiming in progress..." alt="loader" size="24px" />
) : (
<input
onChange={(event) => handleSelect(event, index)}
type="checkbox"
name="check"
checked={isFree || selected.includes(index)}
disabled={isFree}
/>
)}
</label>
</td>
<td>
Expand Down
3 changes: 2 additions & 1 deletion src/custom/pages/Claim/styled.ts
Original file line number Diff line number Diff line change
Expand Up @@ -474,7 +474,7 @@ export const ClaimTotal = styled.div`

> p {
margin: 0;
font-size: 24px;
font-size: 30px;
font-weight: bold;
}
`
Expand Down Expand Up @@ -547,6 +547,7 @@ export const EligibleBanner = styled.div`

export const InputField = styled.div`
padding: 18px;
padding-left: 36px;
border-radius: var(--border-radius);
border: ${({ theme }) => theme.currencyInput?.border};
color: ${({ theme }) => theme.text1};
Expand Down