Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
875 changes: 113 additions & 762 deletions package-lock.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
},
"devDependencies": {
"@angular-architects/module-federation": "^20.0.0",
"@rollup/plugin-node-resolve": "^16.0.3",
"@types/angular-ui-router": "^1.1.44",
"@types/jasmine": "^5.1.15",
"@types/node": "^20.19.30",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ describe('Arc Layer Delete Dialog', () => {

beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [HttpClientModule, MatDialogModule],
declarations: [ArcLayerDeleteDialogComponent],
imports: [HttpClientModule, MatDialogModule, ArcLayerDeleteDialogComponent],
providers: [
{
provide: MatDialogRef,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { HttpClientModule } from '@angular/common/http';
import { MatDialogModule } from '@angular/material/dialog';
import { HttpClientModule } from '@angular/common/http';
import { MatDialogModule } from '@angular/material/dialog';
import { ArcLayerDialogComponent } from './arc-layer-dialog.component';
import { ArcService } from '../arc.service';
import { ArcService } from '../arc.service';

describe('Arc Layer Dialog', () => {
let component: ArcLayerDialogComponent;
let fixture: ComponentFixture<ArcLayerDialogComponent>;

beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [HttpClientModule, MatDialogModule],
declarations: [ArcLayerDialogComponent],
imports: [HttpClientModule, MatDialogModule, ArcLayerDialogComponent],
providers: [
{
provide: MatDialogRef,
Expand All @@ -22,9 +21,9 @@ describe('Arc Layer Dialog', () => {
},
{
provide: MAT_DIALOG_DATA,
useValue: {}
useValue: {}
},
ArcService
ArcService
]
}).compileComponents();
});
Expand All @@ -38,4 +37,4 @@ describe('Arc Layer Dialog', () => {
it('should create', () => {
expect(component).toBeTruthy();
});
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ describe('AppComponent', () => {

beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [AppComponent],
imports: [AppComponent],
}).compileComponents();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ describe('ConfigurationComponent', () => {

beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [HttpClientTestingModule],
declarations: [ConfigurationComponent]
imports: [HttpClientTestingModule, ConfigurationComponent],
}).compileComponents();
}));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,7 @@ import { AppComponent } from './app.component';
describe('AppComponent', () => {
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [
RouterTestingModule
],
declarations: [
AppComponent
],
imports: [RouterTestingModule, AppComponent],
}).compileComponents();
}));

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Component, Inject, OnDestroy, OnInit } from '@angular/core';
import { CommonModule } from '@angular/common';
import { Component, OnDestroy, OnInit } from '@angular/core';
import { TypeChoice } from './admin-create.model';
import { AdminBreadcrumb } from '../../admin-breadcrumb/admin-breadcrumb.model';
import { AuthenticationConfigurationService } from '../../services/admin-authentication-configuration.service';
Expand All @@ -12,12 +13,44 @@ import {
FormBuilder,
FormControl,
FormGroup,
ReactiveFormsModule,
ValidationErrors,
Validators
} from '@angular/forms';

import { MatStepperModule } from '@angular/material/stepper';
import { MatFormFieldModule } from '@angular/material/form-field';
import { MatInputModule } from '@angular/material/input';
import { MatSelectModule } from '@angular/material/select';
import { MatIconModule } from '@angular/material/icon';
import { MatButtonModule } from '@angular/material/button';

import { AdminBreadcrumbComponent } from '../../admin-breadcrumb/admin-breadcrumb.component';
import { AdminAuthenticationOidcComponent } from '../admin-authentication-oidc/admin-authentication-oidc.component';
import { AdminAuthenticationOAuth2Component } from '../admin-authentication-oauth2/admin-authentication-oauth2.component';
import { AdminAuthenticationLDAPComponent } from '../admin-authentication-ldap/admin-authentication-ldap.component';
import { AdminAuthenticationSAMLComponent } from '../admin-authentication-saml/admin-authentication-saml.component';
import { ButtonPreviewComponent } from './button-preview/button-preview.component';

@Component({
selector: 'admin-authentication-create',
standalone: true,
imports: [
CommonModule,
ReactiveFormsModule,
MatStepperModule,
MatFormFieldModule,
MatInputModule,
MatSelectModule,
MatIconModule,
MatButtonModule,
AdminBreadcrumbComponent,
AdminAuthenticationOidcComponent,
AdminAuthenticationOAuth2Component,
AdminAuthenticationLDAPComponent,
AdminAuthenticationSAMLComponent,
ButtonPreviewComponent
],
templateUrl: './admin-authentication-create.component.html',
styleUrls: ['./admin-authentication-create.component.scss'],
providers: []
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,25 @@
import { Component, Input } from '@angular/core'
import { ColorEvent } from 'ngx-color';
import { Strategy } from '../../admin-settings.model';
import { CommonModule } from '@angular/common';
import { MatFormFieldModule } from '@angular/material/form-field';
import { MatIconModule } from '@angular/material/icon';
import { ColorPickerComponent } from 'admin/src/app/color-picker/color-picker.component';
import { IconUploadComponent } from '../icon-upload/icon-upload.component';

@Component({
selector: 'button-preview',
standalone: true,
imports: [
CommonModule,
MatFormFieldModule,
MatIconModule,
ColorPickerComponent,
IconUploadComponent
],
templateUrl: './button-preview.component.html',
styleUrls: ['./button-preview.component.scss']
})
})
export class ButtonPreviewComponent {
@Input() strategy: Strategy;
@Input() editable = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

button {
margin-left: 8px;
color: mat.get-color-from-palette($app-primary);
color: mat.m2-get-color-from-palette($app-primary);
}

mat-dialog-actions {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
import { AfterViewInit, Component, Inject } from '@angular/core'
import { MatDialogRef as MatDialogRef, MAT_DIALOG_DATA as MAT_DIALOG_DATA } from '@angular/material/dialog'
import { MatDialogRef as MatDialogRef, MAT_DIALOG_DATA as MAT_DIALOG_DATA, MatDialogModule } from '@angular/material/dialog'
import { Strategy } from '../../admin-authentication/admin-settings.model'
import { AuthenticationConfigurationService } from '../../services/admin-authentication-configuration.service'
import { CommonModule } from '@angular/common'
import { MatButtonModule } from '@angular/material/button'

@Component({
selector: 'admin-authentication-delete',
standalone: true,
imports: [
CommonModule,
MatDialogModule,
MatButtonModule
],
templateUrl: './admin-authentication-delete.component.html',
styleUrls: ['./admin-authentication-delete.component.scss']
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ describe('AdminAuthenticationLDAPComponent', () => {

beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [ AdminAuthenticationLDAPComponent ],
imports: [ AdminAuthenticationLDAPComponent ],
schemas: [ CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA ]
})
.compileComponents();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { Strategy } from '../../admin-authentication/admin-settings.model';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { MatFormFieldModule } from '@angular/material/form-field';
import { MatInputModule } from '@angular/material/input';
import { MatSelectModule } from '@angular/material/select';
import { MatExpansionModule } from '@angular/material/expansion';

interface Scope {
value: string;
Expand All @@ -8,23 +14,30 @@ interface Scope {

@Component({
selector: 'admin-authentication-ldap',
standalone: true,
imports: [
CommonModule,
FormsModule,
MatFormFieldModule,
MatInputModule,
MatSelectModule,
MatExpansionModule
],
templateUrl: './admin-authentication-ldap.component.html',
styleUrls: ['./admin-authentication-ldap.component.scss']
})
//https://datatracker.ietf.org/doc/html/rfc4510
//https://datatracker.ietf.org/doc/html/rfc4510
export class AdminAuthenticationLDAPComponent implements OnInit {

@Input() strategy: Strategy
@Input() editable = true
@Input() strategy: Strategy;
@Input() editable = true;
@Output() strategyDirty = new EventEmitter<boolean>();

scopes: Scope[] = [
{value: 'sub', viewValue: 'sub'},
{value: 'base', viewValue: 'base'},
{value: 'one', viewValue: 'one'}
{ value: 'sub', viewValue: 'sub' },
{ value: 'base', viewValue: 'base' },
{ value: 'one', viewValue: 'one' }
];


ngOnInit(): void {
if (!this.strategy.settings.headers) {
this.strategy.settings.headers = {};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,51 +1,76 @@
import { Component, OnInit, Input, EventEmitter, Output } from '@angular/core';
import { Strategy, AdminChoice } from '../../../admin-authentication/admin-settings.model';
import {
Strategy,
AdminChoice
} from '../../../admin-authentication/admin-settings.model';
import { MaxLock } from './account-lock.model';

import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { MatFormFieldModule } from '@angular/material/form-field';
import { MatInputModule } from '@angular/material/input';
import { MatSelectModule } from '@angular/material/select';

@Component({
selector: 'account-lock',
templateUrl: 'account-lock.component.html',
styleUrls: ['./account-lock.component.scss']
selector: 'account-lock',
standalone: true,
imports: [
CommonModule,
FormsModule,
MatFormFieldModule,
MatSelectModule,
MatInputModule
],
templateUrl: 'account-lock.component.html',
styleUrls: ['./account-lock.component.scss']
})
export class AccountLockComponent implements OnInit {
@Input() strategy: Strategy;
@Output() strategyDirty = new EventEmitter<boolean>();
@Input() strategy: Strategy;
@Output() strategyDirty = new EventEmitter<boolean>();

readonly accountLockChoices: AdminChoice[] = [{
title: 'Off',
description: 'Do not lock MAGE user accounts.',
value: false
}, {
title: 'On',
description: 'Lock MAGE user accounts for defined time \n after defined number of invalid login attempts.',
value: true
}];
maxLock: MaxLock = {
enabled: false
};
readonly maxLockChoices: AdminChoice[] = [{
title: 'Off',
description: 'Do not disable MAGE user accounts.',
value: false
}, {
title: 'On',
description: 'Disable MAGE user accounts after account has been locked defined number of times.',
value: true
}];
readonly accountLockChoices: AdminChoice[] = [
{
title: 'Off',
description: 'Do not lock MAGE user accounts.',
value: false
},
{
title: 'On',
description:
'Lock MAGE user accounts for defined time \n after defined number of invalid login attempts.',
value: true
}
];
maxLock: MaxLock = {
enabled: false
};
readonly maxLockChoices: AdminChoice[] = [
{
title: 'Off',
description: 'Do not disable MAGE user accounts.',
value: false
},
{
title: 'On',
description:
'Disable MAGE user accounts after account has been locked defined number of times.',
value: true
}
];

ngOnInit(): void {
if (this.strategy.type === 'local') {
this.maxLock.enabled = this.strategy.settings.accountLock && this.strategy.settings.accountLock.max !== undefined;
ngOnInit(): void {
if (this.strategy.type === 'local') {
this.maxLock.enabled =
this.strategy.settings.accountLock &&
this.strategy.settings.accountLock.max !== undefined;

if (!this.maxLock.enabled) {
delete this.strategy.settings.accountLock.max;
}
}
if (!this.maxLock.enabled) {
delete this.strategy.settings.accountLock.max;
}
}
}

setDirty(isDirty: boolean): void {
this.strategy.isDirty = isDirty;
this.strategyDirty.emit(isDirty);
}
}
setDirty(isDirty: boolean): void {
this.strategy.isDirty = isDirty;
this.strategyDirty.emit(isDirty);
}
}
Loading
Loading