Skip to content

Commit

Permalink
new file button
Browse files Browse the repository at this point in the history
  • Loading branch information
the-human-guy committed Dec 11, 2024
1 parent 3c3b6be commit 3b40127
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions js/pages/file-encrypt/page.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,18 @@ export function FileEncryptPage() {
>
Choose File
</button>
<button
type='button'
data-testid='create-new-file-btn'
onClick={async () => {
const newFile = new File([''], `new-file`, {
type: 'text/plain',
})
addFileToList(newFile)
}}
>
New File
</button>
{!!selectedFile && (
<>
<button
Expand Down

0 comments on commit 3b40127

Please sign in to comment.