Skip to content

Commit

Permalink
EO: fix thirdparty flow (#3858)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
1 parent 570e90a commit f650a40
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 23 deletions.
14 changes: 7 additions & 7 deletions libs/eo/core/shell/src/lib/eo-core-shell.routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,17 +57,17 @@ const routes: Routes = [
path: 'callback',
redirectTo: 'onboarding/signin-callback',
},
{
path: eoOnboardingRoutePath,
loadChildren: () =>
import('@energinet-datahub/eo/onboarding/shell').then(
(esModule) => esModule.eoOnbordingRoutes
),
},
{
path: '',
component: EoShellComponent,
children: [
{
path: eoOnboardingRoutePath,
loadChildren: () =>
import('@energinet-datahub/eo/onboarding/shell').then(
(esModule) => esModule.eoOnbordingRoutes
),
},
...eoLegalRoutes,
{
path: eoCertificatesRoutePath,
Expand Down
6 changes: 3 additions & 3 deletions libs/eo/landing-page/shell/src/lib/header.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,9 +132,9 @@ import { EoLoginButtonComponent } from './login-button.component';
`,
})
export class EoLandingPageHeaderComponent {
private elementRef = inject(ElementRef);
private viewportScroller = inject(ViewportScroller);
private destroyRef = inject(DestroyRef);
private readonly elementRef = inject(ElementRef);
private readonly viewportScroller = inject(ViewportScroller);
private readonly destroyRef = inject(DestroyRef);

protected translations = translations;
protected pauseScrollEvents = false;
Expand Down
38 changes: 25 additions & 13 deletions libs/eo/onboarding/shell/signin-callback.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ import { WattEmptyStateComponent } from '@energinet-datahub/watt/empty-state';

import { EoAuthService } from '@energinet-datahub/eo/auth/data-access';
import { translations } from '@energinet-datahub/eo/translations';
import { EoHeaderComponent } from '@energinet-datahub/eo/shared/components/ui-header';
import { EoFooterComponent } from '@energinet-datahub/eo/shared/components/ui-footer';

interface State {
thirdPartyClientId: string;
Expand All @@ -34,10 +36,16 @@ interface State {
@Component({
standalone: true,
selector: 'eo-signin-callback',
imports: [WattSpinnerComponent, WattEmptyStateComponent, TranslocoPipe],
imports: [
WattSpinnerComponent,
WattEmptyStateComponent,
TranslocoPipe,
EoHeaderComponent,
EoFooterComponent,
],
styles: `
:host {
height: 100vh;
.content {
height: 90vh;
width: 100%;
display: flex;
flex-direction: column;
Expand All @@ -47,16 +55,20 @@ interface State {
}
`,
template: `
@if (isMitIDErhverv()) {
<watt-spinner />
} @else {
<watt-empty-state
icon="custom-power"
[useHTML]="true"
[title]="translations.shared.notMitIDErhvervError.title | transloco"
[message]="translations.shared.notMitIDErhvervError.message | transloco"
/>
}
<eo-header />
<div class="content">
@if (isMitIDErhverv()) {
<watt-spinner />
} @else {
<watt-empty-state
icon="custom-power"
[useHTML]="true"
[title]="translations.shared.notMitIDErhvervError.title | transloco"
[message]="translations.shared.notMitIDErhvervError.message | transloco"
/>
}
</div>
<eo-footer />
`,
})
export class EoSigninCallbackComponent implements OnInit {
Expand Down

0 comments on commit f650a40

Please sign in to comment.