File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed
web/src/pages/NewTransaction/NavigationButtons Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -25,9 +25,19 @@ import { wrapWithToast } from "utils/wrapWithToast";
25
25
import { ethAddressPattern } from "utils/validateAddress" ;
26
26
import { useQueryRefetch } from "hooks/useQueryRefetch" ;
27
27
import { useNavigateAndScrollTop } from "hooks/useNavigateAndScrollTop" ;
28
+ import ClosedCircleIcon from "components/StyledIcons/ClosedCircleIcon" ;
28
29
29
30
const StyledButton = styled ( Button ) `` ;
30
31
32
+ const ErrorMessage = styled . div `
33
+ display: flex;
34
+ align-items: center;
35
+ gap: 12px;
36
+ justify-content: center;
37
+ margin: 4px;
38
+ color: ${ ( { theme } ) => theme . error } ;
39
+ ` ;
40
+
31
41
const DepositPaymentButton : React . FC = ( ) => {
32
42
const {
33
43
escrowTitle,
@@ -174,15 +184,16 @@ const DepositPaymentButton: React.FC = () => {
174
184
} ;
175
185
176
186
return (
177
- < >
187
+ < div >
178
188
< StyledButton
179
189
isLoading = { isSending }
180
190
disabled = { isSending || ! ! error }
191
+ tooltip = { error }
181
192
text = { isNativeTransaction || isApproved ? "Deposit the Payment" : "Approve Token" }
182
193
onClick = { isNativeTransaction || isApproved ? handleCreateTransaction : handleApproveToken }
183
194
/>
184
- < p > { error } </ p >
185
- </ >
195
+ { error ? < ErrorMessage > < ClosedCircleIcon /> { error } </ ErrorMessage > : null }
196
+ </ div >
186
197
) ;
187
198
} ;
188
199
You can’t perform that action at this time.
0 commit comments