-
Notifications
You must be signed in to change notification settings - Fork 1
IS-9422: updates templates to support same-device and cross-device flows #136
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
Changes from all commits
1db54ce
2efab13
c6176de
a91d7fe
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -35,6 +35,11 @@ | |
| #else | ||
| #set($qr_time_left = $_maxWaitTime / 60) | ||
| #end | ||
| #if($_flowMode == 'cross-device' || $_flowMode == 'same-device') | ||
| #set($extendUrl="${_authUrl}?flowMode=$_flowMode") | ||
| #else | ||
| #set($extendUrl=$_authUrl) | ||
| #end | ||
| #set($qr_time_elapsed = 0) | ||
| <iframe id="autoStart" height="0" width="0" frameborder="0"></iframe> | ||
| <h1 class="center">#message("${_templatePrefix}.page.title")</h1> | ||
|
|
@@ -52,7 +57,7 @@ | |
| <span id="qr-time-label-seconds" #if($_maxWaitTime >= 60) class="hide"#end>#message("${_templatePrefix}.view.qr.seconds-left")</span> | ||
| </p> | ||
| <div class="mt2"> | ||
| <a class="button button-tiny button-primary-outline" id="qr-time-extend" href="$_authUrl"> | ||
| <a class="button button-tiny button-primary-outline" id="qr-time-extend" href="$extendUrl"> | ||
| #message("${_templatePrefix}.view.button.qr-time-extend") | ||
| </a> | ||
| </div> | ||
|
|
@@ -92,30 +97,32 @@ | |
| <p class="left-align">#message("${_templatePrefix}.view.qr.screen-reader.outro")</p> | ||
| </details> | ||
| </div> | ||
| #end | ||
| #if($_autostartTokenDataUri && $_autostartToken) | ||
| <p class="login-symbol">#message("${_templatePrefix}.view.or")</p> | ||
| #end | ||
| #if($_autostartToken) | ||
| <form class="manuallink pb0"> | ||
| <a class="button button-fullwidth button-primary center" id="manualStart"> | ||
| #message("${_templatePrefix}.view.button.this-device")</a> | ||
| </form> | ||
| <form name="cancel" action="cancel" class="manuallink" method="get"> | ||
| <button type="submit" class="button button-fullwidth button-primary-outline">#message($_messages, | ||
| "${_templatePrefix}.view.button.cancel")</button> | ||
| #end | ||
| #if($_flowMode == 'cross-device') | ||
| <form class="manuallink pb0"> | ||
| <a class="button button-fullwidth button-primary center" href="$_switchModeUrl"> | ||
| #message("${_templatePrefix}.view.button.open-on-this-device")</a> | ||
| </form> | ||
| #else | ||
| <div class="area center"> | ||
| <p class="h4 mb4 semibold" id="poll_message">#message("${_templatePrefix}.view.title")</p> | ||
| #parse("fragments/spinner") | ||
| </div> | ||
| <form class="manuallink pb0 display-none"> | ||
| <p class="h4 center">#message("${_templatePrefix}.view.manualstart")</p> | ||
| <a class="button button-fullwidth button-primary center" id="manualStart"> | ||
| #message("${_templatePrefix}.view.button.manualstart")</a> | ||
| #end | ||
| #if($_flowMode == 'same-device') | ||
| <form class="manuallink pb0"> | ||
| <a class="button button-fullwidth button-primary center" href="$_switchModeUrl"> | ||
| #message("${_templatePrefix}.view.button.show-qr-code")</a> | ||
| </form> | ||
| <form name="cancel" action="cancel" class="manuallink display-none" method="get"> | ||
| #end | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Previously, with the auto-start mode, the cancel button was hidden and then displayed after 5 seconds. Now it will be displayed from the beginning for both modes. Did you remove this behaviour voluntarily?
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Before my changes, my understanding is that the cancel button was always there when we have a QR code, which always happened for BankID v6. |
||
| <form name="cancel" action="cancel" class="manuallink" method="get"> | ||
| <button type="submit" class="button button-fullwidth button-primary-outline">#message($_messages, | ||
| "${_templatePrefix}.view.button.cancel")</button> | ||
| </form> | ||
| #end | ||
| <form action="$_action" method="post" id="pollingDone" class="display-none"> | ||
| <input type="hidden" name="_pollingDone" value="true"/> | ||
| </form> | ||
|
|
||
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.
I don't get why we also need messages without the "button" qualifier in the path:
launch.view.show-qr-codelaunch.view.open-on-this-devicedoes not look to be used.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.
They were being used by HAAPI, however I removed them and changed the HAAPI representation so that it uses the exact same messages as the VM templates.