-
Notifications
You must be signed in to change notification settings - Fork 16
fix: many fixes and tests. #592
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
Merged
Merged
Changes from all commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
38a0471
chore: single button page to simplified tests
chedieck 28ed757
fix: paymentId on open
chedieck 13a1776
fix: regenerating for undefined
chedieck 8c052f2
test: add test for 13a1776f
chedieck a1c1612
test: test for not regenerating paymentId across reopenings
chedieck 866a62a
fix: <div> inside <p>
chedieck 77ec5ab
test: add tests for paybutton
chedieck 3abdbdb
fix: open ui immediatly (WIP)
chedieck 030a899
fix: onOpen with correct values, leaving amount updated
chedieck 30f3bea
fix: optional props, wait for loading before being able to click button
chedieck 2143dd5
fix: don't allow copying qrcode before paymentId loads
chedieck 5d7bc59
test: improve widget tests
chedieck 3dab97e
fix: dependecy on effect
chedieck 15e37b2
test: working review of paybutton tests
chedieck 1543843
fix: createPayment import
chedieck 3070474
test: passing paybutton tests
chedieck 689127c
test: fix warning on widget tests
chedieck 0adb6b9
test: add tests for QR code and amount shown
chedieck c8d8f30
fix: type error
chedieck c88bbc3
fix: widget is actually widget container
chedieck 165f92f
fix: widget not fetching paymentId for undefined amount
chedieck d94939a
test: complete widget test for now
chedieck a780c8b
Merge branch 'master' into fix/paymentId-onopen
chedieck 285e0bc
fix: double editable
chedieck 2505d69
chore: add canvas
chedieck 39dcd22
test: fix mock get price
chedieck 3836eb6
test: faster test time
chedieck File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,40 @@ | ||
| <!DOCTYPE html> | ||
| <html> | ||
|
|
||
| <head> | ||
| <meta charset="utf-8" /> | ||
| <title>Paybutton Bundle Test</title> | ||
| <style> | ||
| body { | ||
| padding: auto; | ||
| font-family: Arial, sans-serif; | ||
| } | ||
| </style> | ||
| <link rel="stylesheet" type="text/css" href="style.css"> | ||
| </head> | ||
|
|
||
| <body> | ||
| <script src="./paybutton.js"></script> | ||
|
|
||
| <div class="paybutton" to="ecash:qr64gaal5zx97judme7nmqxpru6gnx8p3uwgvx585h" text="Purchase" amount="1001" | ||
| editable="true" | ||
| currency="XEC" goal-amount="2.5" success-text="WOW!" on-close="myClose" on-open="myOpen" | ||
| on-success="mySuccessFunction" on-transaction="myTransactionFunction" size="lg"></div> | ||
| <script> | ||
| function mySuccessFunction(tx) { | ||
| console.log('Ran mySuccess', { tx }) | ||
| } | ||
|
|
||
| function myTransactionFunction(tx) { | ||
| console.log('Ran myTransaction', { tx }) | ||
| } | ||
|
|
||
| function myClose(success, paymentId) { | ||
| console.log('Ran myClose', { success, paymentId}) | ||
| } | ||
|
|
||
| function myOpen(amount, to, paymentId) { | ||
| console.log('Ran myOpen', { amount, to, paymentId }) | ||
| } | ||
| </script> | ||
| </body> | ||
This file contains hidden or 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 hidden or 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 hidden or 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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.