From 5b6e1d9f888b5509f4016fe2f304b408a7df0e83 Mon Sep 17 00:00:00 2001 From: Yogi_Wang Date: Thu, 21 Nov 2019 10:16:49 +0800 Subject: [PATCH] Fix ui issue about the third round test Signed-off-by: Yogi_Wang --- .../create-edit-endpoint.component.html | 2 +- .../create-edit-endpoint.component.scss | 3 +-- src/portal/lib/src/tag/tag.component.html | 2 +- src/portal/lib/src/tag/tag.component.scss | 12 +++++++++--- .../add-webhook-form/add-webhook-form.component.html | 4 ++-- .../add-webhook-form/add-webhook-form.component.ts | 9 +++++++-- 6 files changed, 21 insertions(+), 11 deletions(-) diff --git a/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.html b/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.html index b53499990..bdb9b4df9 100644 --- a/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.html +++ b/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.html @@ -43,7 +43,7 @@ && endpointList?.length" class="down" shape="caret" dir="down" (click)="showEndpointList=true"> + [(ngModel)]="target.url" size="28" name="endpointUrl" #targetEndpoint="ngModel" required placeholder="http(s)://192.168.1.1">
  • {{endpoint.key}}
  • diff --git a/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.scss b/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.scss index bea4112c3..abe6509c3 100644 --- a/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.scss +++ b/src/portal/lib/src/create-edit-endpoint/create-edit-endpoint.component.scss @@ -63,6 +63,5 @@ cursor: pointer; } .endpoint-input { - padding-right: 17px; - width: 256px; + padding-right: 21px; } diff --git a/src/portal/lib/src/tag/tag.component.html b/src/portal/lib/src/tag/tag.component.html index 9e7c60ec8..a32eefe7e 100644 --- a/src/portal/lib/src/tag/tag.component.html +++ b/src/portal/lib/src/tag/tag.component.html @@ -94,7 +94,7 @@
    {{t.name}} - {{'REPOSITORY.IMMUTABLE' | translate}} + {{'REPOSITORY.IMMUTABLE' | translate}}
    diff --git a/src/portal/lib/src/tag/tag.component.scss b/src/portal/lib/src/tag/tag.component.scss index 13ffa5616..2a31b08fa 100644 --- a/src/portal/lib/src/tag/tag.component.scss +++ b/src/portal/lib/src/tag/tag.component.scss @@ -254,11 +254,17 @@ clr-datagrid { height: 100%; } -.ml-5 { - margin-left: 8px !important; +.ml-8 { + margin-left: 8px; } .immutable { - padding-right: 80px; + padding-right: 94px; + position: relative; + span { + position: absolute; + right: 0; + margin-right: 0; + } } .white-normal { white-space: normal; diff --git a/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.html b/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.html index 1896d9740..f02b90885 100644 --- a/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.html +++ b/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.html @@ -8,7 +8,7 @@
    + size="30" name="edit_endpoint_url" #enpointURL="ngModel" required placeholder="http(s)://192.168.1.1">
    @@ -23,7 +23,7 @@
    + [(ngModel)]="webhookTarget.auth_header" size="30" name="auth_header">
    diff --git a/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.ts b/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.ts index d83b75c7c..e31467b8b 100644 --- a/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.ts +++ b/src/portal/src/app/project/webhook/add-webhook-form/add-webhook-form.component.ts @@ -16,6 +16,7 @@ import { WebhookService } from "../webhook.service"; import { WebhookEventTypes } from '../../../shared/shared.const'; import { InlineAlertComponent } from "../../../shared/inline-alert/inline-alert.component"; import { MessageHandlerService } from "../../../shared/message-handler/message-handler.service"; +import { TranslateService } from "@ngx-translate/core"; @Component({ selector: 'add-webhook-form', @@ -42,7 +43,8 @@ export class AddWebhookFormComponent implements OnInit, OnChanges { constructor( private webhookService: WebhookService, - private messageHandlerService: MessageHandlerService + private messageHandlerService: MessageHandlerService, + private translate: TranslateService ) { } ngOnInit() { @@ -70,8 +72,11 @@ export class AddWebhookFormComponent implements OnInit, OnChanges { message: "WEBHOOK.TEST_ENDPOINT_SUCCESS" }); } else { - this.checkBtnState = ClrLoadingState.SUCCESS; + this.translate.get("WEBHOOK.TEST_ENDPOINT_SUCCESS").subscribe((res: string) => { + this.messageHandlerService.info(res); + }); } + this.checkBtnState = ClrLoadingState.SUCCESS; }, error => { if (this.isModify) {