HomePhabricator

[Cashtab] fix antd error in console when user clicks Create eToken

Description

[Cashtab] fix antd error in console when user clicks Create eToken

Summary: Related to T2593. Removed transformFile prop and related function from Dragger component in CreateTokenForm. According to the error, the component should simply use the beforeUpload prop directly. This related PR (https://github.com/ant-design/ant-design/pull/28365), describes the following: "The original beforeUpload already supports the transformFile capability and removes related documents. This also fixes an issue where the preview function would not use transformFile transformed files."

Test Plan:
cd web/cashtab && npm start
navigate to create eToken screen
observe that the error does not fire
drag an image file into the Dragger component
The image should upload.
Drag an unsupported filetype over the Dragger component
A modal should appear instructing user to upload only jpg & png files.

Reviewers: bytesofman, #bitcoin_abc

Reviewed By: bytesofman, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D12065

Details

Provenance
kieran709Authored on Sep 26 2022, 18:38
kieran709Pushed on Sep 27 2022, 17:55
Reviewer
Restricted Project
Differential Revision
D12065: [Cashtab] fix antd error in console when user clicks Create eToken
Parents
rABC79a6ad1bf2da: [Cashtab] fix antd syntax issue
Branches
Unknown
Tags
Unknown