Skip to content

Commit bb17e6d

Browse files
committed
Merge branch 'main' into chore/update-angular-to-v20
2 parents 5dcb8ea + fdf6fd9 commit bb17e6d

13 files changed

Lines changed: 1255 additions & 31 deletions

package-lock.json

Lines changed: 601 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@
3333
"ngx-float-ui": "^20.0.0",
3434
"rxjs": "~7.8.2",
3535
"tslib": "^2.8.1",
36-
"zone.js": "~0.15.1"
36+
"uuid": "^13.0.0",
37+
"zone.js": "~0.15.0"
3738
},
3839
"devDependencies": {
3940
"@angular-devkit/core": "^20.3.9",

projects/dashboard-core/package-lock.json

Lines changed: 30 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

projects/dashboard-core/package.json

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,15 @@
22
"name": "@eclipse-edc/dashboard-core",
33
"version": "0.3.0",
44
"peerDependencies": {
5-
"@angular/common": "^20.3.9",
6-
"@angular/core": "^20.3.9",
7-
"@tailwindcss/postcss": "^4.1.16",
8-
"@think-it-labs/edc-connector-client": "0.9.0",
9-
"daisyui": "^5.3.10",
10-
"tailwindcss": "^4.1.16",
11-
"postcss": "^8.5.6",
12-
"material-symbols": "^0.39.0"
5+
"@angular/common": "^19.2.5",
6+
"@angular/core": "^19.2.5",
7+
"@tailwindcss/postcss": "^4.1.1",
8+
"@think-it-labs/edc-connector-client": "0.8.0",
9+
"daisyui": "^5.0.12",
10+
"tailwindcss": "^4.1.1",
11+
"postcss": "^8.5.3",
12+
"material-symbols": "^0.29.2",
13+
"uuid": "^13.0.0"
1314
},
1415
"dependencies": {
1516
"tslib": "^2.8.1"
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
/*
2+
* Copyright (c) 2025 Fraunhofer-Gesellschaft zur Förderung der angewandten Forschung e.V.
3+
*
4+
* This program and the accompanying materials are made available under the
5+
* terms of the Apache License, Version 2.0 which is available at
6+
* https://www.apache.org/licenses/LICENSE-2.0
7+
*
8+
* SPDX-License-Identifier: Apache-2.0
9+
*
10+
* Contributors:
11+
* Fraunhofer-Gesellschaft zur Förderung der angewandten Forschung e.V. - initial API and implementation
12+
*
13+
*/
14+
15+
import { createOutputSpy, mount } from 'cypress/angular';
16+
import { AwsS3DataTypeComponent } from '@eclipse-edc/dashboard-core';
17+
18+
it('should have region, bucket and object path invalid on load', () => {
19+
mount(AwsS3DataTypeComponent);
20+
cy.get('input[name="region"]').parent().should('have.class', 'input-error');
21+
cy.get('input[name="bucketName"]').parent().should('have.class', 'input-error');
22+
cy.get('input[name="objectName"]').parent().should('have.class', 'input-error');
23+
});
24+
25+
it('should emit the changed region', () => {
26+
mount(AwsS3DataTypeComponent, {
27+
componentProperties: {
28+
changed: createOutputSpy('changed'),
29+
},
30+
});
31+
cy.get('input[name="region"]').type('eu-central-1');
32+
cy.get('@changed').should('have.been.called');
33+
});
34+
35+
it('should enable multi object fields', () => {
36+
mount(AwsS3DataTypeComponent);
37+
cy.get('input[name="folderName"]').should('not.exist');
38+
cy.get('input[name="objectPrefix"]').should('not.exist');
39+
cy.get('input[name="objectName"]').parent().should('have.class', 'input-error');
40+
41+
cy.get('input[name="multi-object-switch"]').check();
42+
43+
cy.get('input[name="folderName"]').should('exist');
44+
cy.get('input[name="objectPrefix"]').should('exist');
45+
cy.get('input[name="objectName"]').parent().should('not.have.class', 'input-error');
46+
});
47+
48+
it('should enable plain credential fields', () => {
49+
mount(AwsS3DataTypeComponent);
50+
cy.get('input[name="accessKeyId"]').should('not.exist');
51+
cy.get('input[name="secretAccessKey"]').should('not.exist');
52+
53+
cy.get('input[name="plain-credentials-switch"]').check();
54+
55+
cy.get('input[name="accessKeyId"]').should('exist');
56+
cy.get('input[name="secretAccessKey"]').should('exist');
57+
});
Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
<!--
2+
Copyright (c) 2025 Fraunhofer-Gesellschaft zur Förderung der angewandten Forschung e.V.
3+
4+
This program and the accompanying materials are made available under the
5+
terms of the Apache License, Version 2.0 which is available at
6+
https://www.apache.org/licenses/LICENSE-2.0
7+
8+
SPDX-License-Identifier: Apache-2.0
9+
10+
Contributors:
11+
Fraunhofer-Gesellschaft zur Förderung der angewandten Forschung e.V. - initial API and implementation
12+
-->
13+
14+
<fieldset class="fieldset" [formGroup]="formGroup">
15+
@for (property of viewData; track property[0]) {
16+
<legend class="fieldset-label">{{ property[1].displayName }}</legend>
17+
<label
18+
class="input w-full"
19+
[ngClass]="
20+
formGroup.get(property[0])?.invalid
21+
? property[1].tooltip
22+
? 'input-error tooltip tooltip-top tooltip-info'
23+
: 'input-error'
24+
: property[1].tooltip
25+
? 'tooltip tooltip-top tooltip-info'
26+
: ''
27+
"
28+
[attr.data-tip]="property[1].tooltip"
29+
>
30+
@if (property[1].icon) {
31+
<span class="material-symbols-rounded opacity-50">{{ property[1].icon }}</span>
32+
}
33+
<input
34+
[type]="property[1].inputType ?? 'text'"
35+
[placeholder]="property[1].displayName"
36+
[name]="property[0]"
37+
[formControlName]="property[0]"
38+
/>
39+
</label>
40+
}
41+
42+
<legend class="fieldset-label">
43+
<span>Multiple Objects</span>
44+
</legend>
45+
<div class="flex items-center">
46+
<input
47+
type="checkbox"
48+
name="multi-object-switch"
49+
[checked]="multiObject"
50+
class="toggle toggle-primary"
51+
(change)="onMultiDataSwitch()"
52+
/>
53+
<div
54+
class="tooltip tooltip-info tooltip-right ml-2 h-[1.3rem]"
55+
data-tip="When folderName and objectPrefix are not present, transfer only the object with a key matching the objectPath property. When folderName, objectPrefix and objectPath are empty and/or null an entire s3 bucket transfer is triggered. Precedence: folderName and/or objectPrefix take precedence over objectPath when determining which objects to transfer. It allows for both multiple object transfers and fetching a single object when necessary."
56+
>
57+
<span class="material-symbols-rounded !text-[1.3rem] text-info">info</span>
58+
</div>
59+
</div>
60+
@if (multiObject) {
61+
@for (property of multiObjectViewData; track property[0]) {
62+
<legend class="fieldset-label">{{ property[1].displayName }}</legend>
63+
<label
64+
class="input w-full"
65+
[ngClass]="
66+
formGroup.get(property[0])?.invalid
67+
? property[1].tooltip
68+
? 'input-error tooltip tooltip-top tooltip-info'
69+
: 'input-error'
70+
: property[1].tooltip
71+
? 'tooltip tooltip-top tooltip-info'
72+
: ''
73+
"
74+
[attr.data-tip]="property[1].tooltip"
75+
>
76+
@if (property[1].icon) {
77+
<span class="material-symbols-rounded opacity-50">{{ property[1].icon }}</span>
78+
}
79+
<input
80+
[type]="property[1].inputType ?? 'text'"
81+
[placeholder]="property[1].displayName"
82+
[name]="property[0]"
83+
[formControlName]="property[0]"
84+
/>
85+
</label>
86+
}
87+
}
88+
89+
<legend class="fieldset-label">
90+
<span>Plain Text Credentials</span>
91+
</legend>
92+
<div class="flex items-center">
93+
<input
94+
type="checkbox"
95+
name="plain-credentials-switch"
96+
[checked]="plainCredentials"
97+
class="toggle toggle-primary"
98+
(change)="plainCredentials = !plainCredentials"
99+
/>
100+
<div
101+
class="tooltip tooltip-info tooltip-right ml-2 h-[1.3rem]"
102+
data-tip="This feature has been introduced to provide flexibility by not mandating the use of a vault. However, it is important to note that this functionality is not recommended for production environments. Do not set the key name because it has higher priority."
103+
>
104+
<span class="material-symbols-rounded !text-[1.3rem] text-info">info</span>
105+
</div>
106+
</div>
107+
@if (plainCredentials) {
108+
@for (property of plainCredentialsViewData; track property[0]) {
109+
<legend class="fieldset-label">{{ property[1].displayName }}</legend>
110+
<label class="input w-full">
111+
@if (property[1].icon) {
112+
<span class="material-symbols-rounded opacity-50">{{ property[1].icon }}</span>
113+
}
114+
<input
115+
[type]="property[1].inputType ?? 'text'"
116+
[placeholder]="property[1].displayName"
117+
[name]="property[0]"
118+
[formControlName]="property[0]"
119+
/>
120+
</label>
121+
}
122+
}
123+
</fieldset>

0 commit comments

Comments
 (0)