Skip to content

Commit

Permalink
Skip screens consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
oharsta committed Feb 15, 2024
1 parent 57ec7bf commit f88f2cc
Show file tree
Hide file tree
Showing 8 changed files with 31 additions and 11 deletions.
2 changes: 1 addition & 1 deletion account-gui/src/components/SubContent.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
export let route = null;
export let href = null;
export let isMfa = false;
let isMfaParameter = false;
let isMfaParameter = false;
let showModal = false;
onMount(() => {
Expand Down
1 change: 1 addition & 0 deletions account-gui/src/locale/en.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ I18n.translations.en = {
forgotPassword: "Forgot your password?",
useAnother: "Use another",
optionsLink: "sign-in option.",
sendingEmail: "Sending email..."
},
options: {
header: "How do you want to login?",
Expand Down
1 change: 1 addition & 0 deletions account-gui/src/locale/nl.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ I18n.translations.nl = {
forgotPassword: "Wachtwoord vergeten?",
useAnother: "Gebruik een andere",
optionsLink: "inlogmethode.",
sendingEmail: "Email aan het sturen..."
},
options: {
header: "Hoe wil je inloggen?",
Expand Down
15 changes: 15 additions & 0 deletions account-gui/src/routes/UseLink.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,23 @@
};
</script>
<style lang="scss">
div.spinner-container {
display: flex;
flex-direction: column;
p {
margin: 75px auto 0 auto;
}
}
</style>
{#if showSpinner}
<div class="spinner-container">
<Spinner/>
{#if mrccValue}
<p>{I18n.t("login.sendingEmail")}</p>
{/if}
</div>
{/if}
{#if !showSpinner && !mrccValue}
<h2 class="header">{I18n.t("useLink.header")}</h2>
Expand Down
14 changes: 7 additions & 7 deletions account-gui/src/routes/UseWebAuth.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,15 @@
export let id;
let showSpinner = true;
let serviceName = "";
let mrccValue = null;
let isMrcc = null;
onMount(() => {
const urlParams = new URLSearchParams(window.location.search);
mrccValue = urlParams.get(mrcc);
if (mrccValue) {
showSpinner = false;
isMrcc = urlParams.has(mrcc);
if (isMrcc) {
webAuthnStart();
} else {
$links.displayBackArrow = true;
fetchServiceName(id).then(res => {
serviceName = res.name;
showSpinner = false;
Expand All @@ -37,6 +35,8 @@
const webAuthnStart = (test = false) => {
webAuthnStartAuthentication($user.email, id, test)
.then(request => {
showSpinner = false;
isMrcc = false;
get({publicKey: request.publicKeyCredentialRequestOptions})
.then(credentials => {
//rawId is not supported server-side
Expand Down Expand Up @@ -70,7 +70,7 @@
{#if showSpinner}
<Spinner/>
{/if}

{#if !isMrcc}
<h2 class="header">{I18n.t("webAuthn.header")}</h2>
{#if serviceName}
<h2 class="top">{I18n.t("login.headerSubTitle")}<span>{serviceName}</span></h2>
Expand All @@ -82,4 +82,4 @@
className="full"
onClick={webAuthnStart}/>


{/if}
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
package myconext;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.actuate.autoconfigure.metrics.MetricsAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration;
import org.springframework.scheduling.annotation.EnableScheduling;

@SpringBootApplication(exclude = {SecurityAutoConfiguration.class, MetricsAutoConfiguration.class})
@SpringBootApplication(exclude = {SecurityAutoConfiguration.class})
@EnableScheduling
public class MyConextServerApplication {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ public class UserResponse implements Serializable {
private final String chosenName;
private final String givenName;
private final String familyName;
private final String displayName;
private final boolean usePassword;
private final boolean usePublicKey;
private final boolean forgottenPassword;
Expand All @@ -46,6 +47,7 @@ public UserResponse(User user,
this.chosenName = user.getChosenName();
this.givenName = user.getGivenName();
this.familyName = user.getFamilyName();
this.displayName = this.givenName + " " + this.familyName;
this.schacHomeOrganization = user.getSchacHomeOrganization();
this.uid = user.getUid();
this.usePassword = StringUtils.hasText(user.getPassword());
Expand Down
4 changes: 3 additions & 1 deletion myconext-server/src/main/resources/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,13 +185,15 @@ management:
endpoints:
web:
exposure:
include: "health,info,mappings"
include: "health,info,mappings,metrics"
base-path: "/internal"
endpoint:
info:
enabled: true
mappings:
enabled: true
metrics:
enabled: true
info:
git:
mode: full

0 comments on commit f88f2cc

Please sign in to comment.