This repository has been archived by the owner on May 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
266 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,12 @@ | ||
# Changelog | ||
|
||
## v0.1.0 | ||
## v0.1.2 | ||
|
||
Fix crash on unknown asset | ||
Added Edit asset details | ||
Added Delete asset | ||
Added Copy receive address button | ||
|
||
## v0.1.1 | ||
|
||
* Initial Release |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
/** | ||
* Helper methods for clipbaord. | ||
*/ | ||
export class ClipboardHelper { | ||
/** | ||
* Copy the text to the clipboard. | ||
* @param text The text to copy. | ||
* @returns True id the text was copied. | ||
*/ | ||
public static copy(text: string | undefined): boolean { | ||
if (text !== undefined && text !== null) { | ||
try { | ||
const textArea = document.createElement("textarea"); | ||
|
||
// Prevent zooming on iOS | ||
textArea.style.fontSize = "12pt"; | ||
// Reset box model | ||
textArea.style.border = "0"; | ||
textArea.style.padding = "0"; | ||
textArea.style.margin = "0"; | ||
// Move element out of screen horizontally | ||
textArea.style.position = "absolute"; | ||
textArea.style.left = "-9999px"; | ||
// Move element to the same position vertically | ||
const yPosition = window.pageYOffset || document.documentElement.scrollTop; | ||
textArea.style.top = `${yPosition}px`; | ||
|
||
textArea.setAttribute("readonly", ""); | ||
textArea.value = text; | ||
|
||
document.body.append(textArea); | ||
|
||
textArea.select(); | ||
document.execCommand("Copy"); | ||
textArea.remove(); | ||
|
||
return true; | ||
} catch { | ||
// Not much we can do | ||
return false; | ||
} | ||
} else { | ||
return false; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.