mirror of
https://github.com/voltbonn/profile-picture-generator.git
synced 2024-12-22 07:45:04 +00:00
replaced downloadjs by just opening the data-url
This commit is contained in:
parent
634872d8b1
commit
844e1eea98
3 changed files with 3 additions and 8 deletions
|
@ -7,7 +7,6 @@
|
|||
"@testing-library/jest-dom": "^5.11.4",
|
||||
"@testing-library/react": "^11.1.0",
|
||||
"@testing-library/user-event": "^12.1.10",
|
||||
"downloadjs": "^1.4.7",
|
||||
"merge-images": "^2.0.0",
|
||||
"react": "^17.0.1",
|
||||
"react-dom": "^17.0.1",
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
import { useState, useEffect, useCallback } from 'react'
|
||||
import './App.css'
|
||||
import download from 'downloadjs'
|
||||
import { useDropzone } from 'react-dropzone'
|
||||
import FrameChooser from './FrameChooser.js'
|
||||
import HeaderImage from './HeaderImage.svg'
|
||||
|
@ -107,7 +106,9 @@ function App() {
|
|||
|
||||
<h2>Download your Photo:</h2>
|
||||
<img src={combinedImage} className="FinishedFrame" alt="Finished Frame" />
|
||||
<button onClick={() => download(combinedImage, "volt-profile-picture.png", "image/png")}>Download Profile Picture</button>
|
||||
<a download="volt-profile-picture.png" href={combinedImage} target="_blank" rel="noreferrer">
|
||||
<button>Download Profile Picture</button>
|
||||
</a>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
|
|
@ -4155,11 +4155,6 @@ dotenv@8.2.0:
|
|||
resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-8.2.0.tgz#97e619259ada750eea3e4ea3e26bceea5424b16a"
|
||||
integrity sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw==
|
||||
|
||||
downloadjs@^1.4.7:
|
||||
version "1.4.7"
|
||||
resolved "https://registry.yarnpkg.com/downloadjs/-/downloadjs-1.4.7.tgz#f69f96f940e0d0553dac291139865a3cd0101e3c"
|
||||
integrity sha1-9p+W+UDg0FU9rCkROYZaPNAQHjw=
|
||||
|
||||
duplexer@^0.1.1:
|
||||
version "0.1.2"
|
||||
resolved "https://registry.yarnpkg.com/duplexer/-/duplexer-0.1.2.tgz#3abe43aef3835f8ae077d136ddce0f276b0400e6"
|
||||
|
|
Loading…
Reference in a new issue