Skip to content

Commit 69b3a8a

Browse files
authored
Fix focus issue in KV properties (winery#720)
1 parent bbe59ae commit 69b3a8a

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

org.eclipse.winery.frontends/app/topologymodeler/src/app/properties/kv-properties/kv-properties.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2-
~ Copyright (c) 2020 Contributors to the Eclipse Foundation
2+
~ Copyright (c) 2020-2023 Contributors to the Eclipse Foundation
33
~
44
~ See the NOTICE file(s) distributed with this work for additional
55
~ information regarding copyright ownership.
@@ -24,7 +24,7 @@
2424
<th>
2525
Values
2626
</th>
27-
<tr *ngFor="let key of nodeProperties | keysPipe">
27+
<tr *ngFor="let key of nodeProperties | keysPipe; let i = index; trackBy: trackByFn">
2828
<td class="">{{key.key}}</td>
2929
<td class="">
3030
<textarea

org.eclipse.winery.frontends/app/topologymodeler/src/app/properties/kv-properties/kv-properties.component.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*******************************************************************************
2-
* Copyright (c) 2020 Contributors to the Eclipse Foundation
2+
* Copyright (c) 2020-2023 Contributors to the Eclipse Foundation
33
*
44
* See the NOTICE file(s) distributed with this work for additional
55
* information regarding copyright ownership.
@@ -164,6 +164,10 @@ export class KvPropertiesComponent implements OnInit, OnDestroy {
164164
}
165165
}
166166

167+
trackByFn(index, item) {
168+
return index;
169+
}
170+
167171
checkAndSetPattern(key: string, value: string): void {
168172
const pattern = this.kvPatternMap[key];
169173
if (!new RegExp(pattern).test(value)) {

0 commit comments

Comments
 (0)