Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: update native avaxc recovery forms #360

Merged
merged 1 commit into from
Dec 11, 2023
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
10 changes: 0 additions & 10 deletions src/containers/BuildUnsignedSweepCoin/AvalancheCForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import * as Yup from 'yup';
import { Button, FormikTextfield } from '~/components';

const validationSchema = Yup.object({
apiKey: Yup.string().required(),
backupKey: Yup.string().required(),
backupKeyId: Yup.string(),
gasLimit: Yup.number()
Expand Down Expand Up @@ -36,7 +35,6 @@ export function AvalancheCForm({ onSubmit }: AvalancheCFormProps) {
const formik = useFormik<AvalancheCFormValues>({
onSubmit,
initialValues: {
apiKey: '',
backupKey: '',
backupKeyId: '',
gasLimit: 500000,
Expand Down Expand Up @@ -103,14 +101,6 @@ export function AvalancheCForm({ onSubmit }: AvalancheCFormProps) {
Width="fill"
/>
</div>
<div className="tw-mb-4">
<FormikTextfield
HelperText="An API-Key Token from snowtrace.com required for Avalanche C-Chain Mainnet recoveries."
Label="API Key"
name="apiKey"
Width="fill"
/>
</div>
<div className="tw-mb-4">
<FormikTextfield
HelperText="Gas limit for the AVAXC transaction. The value should be between 30,000 and 20,000,000. The default is 500,000 units of gas."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,7 @@ function Form() {
try {
await window.commands.setBitGoEnvironment(
bitGoEnvironment,
coin,
values.apiKey
coin
);
const chainData = await window.queries.getChain(coin);

Expand Down
10 changes: 0 additions & 10 deletions src/containers/NonBitGoRecoveryCoin/AvalancheCForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import {
} from '~/components';

const validationSchema = Yup.object({
apiKey: Yup.string().required(),
backupKey: Yup.string().required(),
gasLimit: Yup.number()
.typeError('Gas limit must be a number')
Expand Down Expand Up @@ -43,7 +42,6 @@ export function AvalancheCForm({ onSubmit }: AvalancheCFormProps) {
const formik = useFormik<AvalancheCFormValues>({
onSubmit,
initialValues: {
apiKey: '',
backupKey: '',
gasLimit: 500000,
gasPrice: 30,
Expand Down Expand Up @@ -123,14 +121,6 @@ export function AvalancheCForm({ onSubmit }: AvalancheCFormProps) {
Width="fill"
/>
</div>
<div className="tw-mb-4">
<FormikTextfield
HelperText="An API-Key Token from snowtrace.com required for Avalanche C-Chain Mainnet recoveries."
Label="API Key"
name="apiKey"
Width="fill"
/>
</div>
<div className="tw-mb-4">
<FormikTextfield
HelperText="Gas limit for the AVAXC transaction. The value should be between 30,000 and 20,000,000. The default is 500,000 units of gas."
Expand Down
3 changes: 1 addition & 2 deletions src/containers/NonBitGoRecoveryCoin/NonBitGoRecoveryCoin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -409,8 +409,7 @@ function Form() {
try {
await window.commands.setBitGoEnvironment(
bitGoEnvironment,
coin,
values.apiKey
coin
);
const chainData = await window.queries.getChain(coin);
const recoverData = await window.commands.recover(coin, {
Expand Down
Loading