-
Notifications
You must be signed in to change notification settings - Fork 75
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
Set Pending state on Deep Link action #519
Conversation
Signed-off-by: Lucas ONeil <lucasoneil@gmail.com>
deepLinkOpen() { | ||
state.disableDeeplink = true; | ||
this.setUiStates("pending"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Set Deep Link pending status
setUiStates(status) { | ||
state.current = status; | ||
state.showSpinner = status === "pending"; | ||
state.showScanned = ["pending", "verified"].includes(status); | ||
state.showRefresh = ["abandoned", "expired", "failed"].includes( | ||
status | ||
); | ||
state.disableDeeplink = [ | ||
"abandoned", | ||
"expired", | ||
"pending", | ||
"success", | ||
].includes(status); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Refactor to be called from multiple spots
}); | ||
this.socket.on("status", (data) => { | ||
console.log("Toggling state", data.status); | ||
this.setUiStates(data.status); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Refactor to be called from multiple spots
Signed-off-by: Lucas ONeil <lucasoneil@gmail.com> tweak Signed-off-by: Lucas ONeil <lucasoneil@gmail.com>
a956ba7
to
64c3fbf
Compare
The Deep Link when clicked was opening the pres req on the BC Wallet but leaving the button enabled. This can cause the issue discussed here
bcgov/bc-wallet-mobile#1956 (comment)
Change it to set the deep link button to disabled (Pending status triggered manually, since it's not updating on the server when deep link is used, no callback)
See comments for relevant changes in html file, diff is big because there was a extraneous div ending that was breaking prettier so I fixed that and formatted.