summaryrefslogtreecommitdiffstats
path: root/catalog-ui/src/app/ng2/pages/composition/panel/panel-header/edit-name-modal/edit-name-modal.component.ts
blob: 9c4aab206e3f3a14af513ed87dfaa426ca85f5d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import { Component, Input } from "@angular/core";

@Component({
    selector: 'edit-name-modal',
    templateUrl: './edit-name-modal.component.html',
    styleUrls: ['./edit-name-modal.component.less']
})
export class EditNameModalComponent {

    @Input() name:String;
    @Input() validityChangedCallback: Function;

    private pattern:string = "^[\\s\\w\&_.:-]{1,1024}$"
    constructor(){
    }

    private validityChanged = (value):void => {
        if(this.validityChangedCallback) {
            this.validityChangedCallback(value);
        }
    }



}