Skip to content

Commit 8b6e4d1

Browse files
Merge remote-tracking branch 'origin/main'
2 parents ec60c63 + 0b716fe commit 8b6e4d1

File tree

8 files changed

+51
-40
lines changed

8 files changed

+51
-40
lines changed

ui-ngx/src/app/modules/home/components/authentication/configuration/jwt-provider-form/jwt-provider-form.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@
176176
<input matInput formControlName="secret"
177177
autocomplete="new-password" name="new-password"
178178
type="password">
179-
<tb-toggle-password [disabled]="disabled" matSuffix></tb-toggle-password>
179+
<tb-toggle-password matSuffix></tb-toggle-password>
180180
<tb-copy-button matSuffix
181181
[class.!hidden]="!jwtConfigForm.get('jwtVerifierConfiguration.jwtSignAlgorithmConfiguration.secret')?.value?.length"
182182
[copyText]="jwtConfigForm.get('jwtVerifierConfiguration.jwtSignAlgorithmConfiguration.secret')?.value">

ui-ngx/src/app/modules/home/pages/blocked-clients/blocked-client.component.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,7 @@ export class BlockedClientComponent extends EntityComponent<BlockedClient> {
192192
this.entityForm.get('expirationTime').setValue(this.defaultExpirationDate(), {emitEvent: false});
193193
this.entityForm.get('expirationTime').setValidators([this.expirationTimeValidator]);
194194
}
195+
this.entityForm.get('expirationTime').updateValueAndValidity();
195196
}
196197

197198
private updateValidators() {

ui-ngx/src/app/modules/home/pages/ws-client/messages/messanger.component.html

Lines changed: 22 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -45,32 +45,31 @@
4545
<div [formGroup]="messangerFormGroup" class="mat-padding flex flex-col" style="background: #fff; border-radius: 4px;">
4646
<section class="flex flex-row flex-nowrap items-center gap-4 lt-xl:flex-wrap"
4747
[class.wrap]="isLtLg | async">
48-
<section class="flex flex-1 items-baseline justify-center gap-4">
49-
<mat-form-field [class.topic-mat-form-field]="isLtLg | async"
50-
style="min-width: 200px !important; width: 100%" hideRequiredMarker>
51-
<mat-label translate>mqtt-client-session.topic</mat-label>
52-
<input matInput formControlName="topic" [matAutocomplete]="auto">
53-
<mat-autocomplete #auto="matAutocomplete">
54-
@for (option of filteredTopics | async; track option) {
55-
<mat-option [value]="option">{{option}}</mat-option>
56-
}
57-
</mat-autocomplete>
58-
@if (messangerFormGroup.get('topic').hasError('required')) {
59-
<mat-error>
60-
{{ 'mqtt-client-session.topic-name-required' | translate }}
61-
</mat-error>
48+
<mat-form-field class="flex flex-1" [class.topic-mat-form-field]="isLtLg | async"
49+
style="min-width: 200px !important; width: 100%" hideRequiredMarker>
50+
<mat-label translate>mqtt-client-session.topic</mat-label>
51+
<input matInput formControlName="topic" [matAutocomplete]="auto">
52+
<mat-autocomplete #auto="matAutocomplete">
53+
@for (option of filteredTopics | async; track option) {
54+
<mat-option [value]="option">{{option}}</mat-option>
6255
}
63-
@if (messangerFormGroup.get('topic').hasError('invalidTopic')) {
64-
<mat-error>
65-
{{ 'mqtt-client-session.topic-name-invalid' | translate }}
66-
</mat-error>
67-
}
68-
</mat-form-field>
69-
<tb-color-input formControlName="color" asBoxInput></tb-color-input>
70-
</section>
56+
</mat-autocomplete>
57+
@if (messangerFormGroup.get('topic').hasError('required')) {
58+
<mat-error>
59+
{{ 'mqtt-client-session.topic-name-required' | translate }}
60+
</mat-error>
61+
}
62+
@if (messangerFormGroup.get('topic').hasError('invalidTopic')) {
63+
<mat-error>
64+
{{ 'mqtt-client-session.topic-name-invalid' | translate }}
65+
</mat-error>
66+
}
67+
<tb-color-input class="full-opacity mr-2" asBoxInput matSuffix formControlName="color">
68+
</tb-color-input>
69+
</mat-form-field>
7170
<tb-qos-select formControlName="qos" class="flex max-w-20% lt-xl:max-w-20%">
7271
</tb-qos-select>
73-
<mat-form-field class="flex max-w-20% lt-xl:max-w-[100px]">
72+
<mat-form-field class="flex max-w-20% lt-xl:max-w-[110px]">
7473
<mat-label translate>value.format</mat-label>
7574
<mat-select formControlName="payloadFormat">
7675
@for (valueType of payloadFormats; track valueType) {

ui-ngx/src/app/modules/home/pages/ws-client/messages/messanger.component.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,5 +85,9 @@
8585
border: 1px solid rgba(0, 0, 0, 0.12);
8686
border-radius: 4px;
8787
}
88+
89+
.mat-mdc-form-field-icon-suffix {
90+
opacity: 1 !important;
91+
}
8892
}
8993
}

ui-ngx/src/app/shared/components/button/toggle-password.component.html

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,7 @@
1616
1717
-->
1818
@if (!hideToggle) {
19-
<button mat-icon-button type="button"
20-
[disabled]="disabled()"
21-
(click)="togglePassword($event)"
22-
[attr.aria-pressed]="showPassword">
23-
<mat-icon>{{ showPassword ? 'visibility' : 'visibility_off' }}</mat-icon>
24-
</button>
19+
<mat-icon (click)="togglePassword($event)">
20+
{{ showPassword ? 'visibility' : 'visibility_off' }}
21+
</mat-icon>
2522
}

ui-ngx/src/app/shared/components/button/toggle-password.component.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,19 +14,22 @@
1414
/// limitations under the License.
1515
///
1616

17-
import { AfterViewInit, Component, ElementRef, input } from '@angular/core';
18-
19-
import { MatIconButton } from '@angular/material/button';
17+
import { AfterViewInit, Component, ElementRef } from '@angular/core';
2018
import { MatIcon } from '@angular/material/icon';
2119

2220
@Component({
2321
selector: 'tb-toggle-password',
2422
templateUrl: 'toggle-password.component.html',
25-
imports: [MatIconButton, MatIcon]
23+
styles: [`
24+
:host {
25+
cursor: pointer;
26+
padding: 12px;
27+
}`
28+
],
29+
imports: [MatIcon]
2630
})
2731
export class TogglePasswordComponent implements AfterViewInit {
2832

29-
disabled = input<boolean>(false);
3033
showPassword = false;
3134
hideToggle = false;
3235

ui-ngx/src/assets/locale/locale.constant-en_US.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -591,7 +591,13 @@
591591
"outdated-hint": "Updated over a week ago",
592592
"delete-resource": "Delete outdated service",
593593
"delete-resource-title": "Are you sure you want to delete the service '{{id}}'?",
594-
"delete-resource-text": "Be careful, after the confirmation the service will be removed and all related data will become unrecoverable."
594+
"delete-resource-text": "Be careful, after the confirmation the service will be removed and all related data will become unrecoverable.",
595+
"cpu-warning-text": "Running high on CPU usage. To avoid system failure, optimize system performance.",
596+
"cpu-critical-text": "Critically high CPU usage. To avoid system failure, optimize system performance.",
597+
"ram-warning-text": "Running low on reserve of RAM. To avoid system failure, optimize system performance or increase the size of RAM.",
598+
"ram-critical-text": "Critically low reserve of RAM. To avoid system failure, optimize system performance or increase the size of RAM.",
599+
"disk-warning-text": "Running low on disk space. To avoid data loss, free up or expand the disk space.",
600+
"disk-critical-text": "Critically low disk space. To avoid data loss, free up or expand the disk space."
595601
}
596602
},
597603
"mqtt-client": {

ui-ngx/src/styles.scss

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1313,10 +1313,11 @@ pre.tb-highlight {
13131313
}
13141314

13151315
.mat-mdc-form-field-icon-suffix {
1316-
opacity: 0.54;
1317-
1318-
&:hover {
1319-
opacity: 1;
1316+
> *:not(.full-opacity) {
1317+
opacity: 0.54;
1318+
&:hover {
1319+
opacity: 1;
1320+
}
13201321
}
13211322
}
13221323

0 commit comments

Comments
 (0)