import { MAT_DIALOG_DATA } from '@angular/material/dialog';
import { Component, Inject, OnInit } from '@angular/core';
import { FormControl } from '@angular/forms';

interface Param{
  id: number;
  name: string;
}
@Component({
  selector: 'app-script-dialog',
  templateUrl: './script-dialog.component.html',
  styleUrls: ['./script-dialog.component.css']
})
export class ScriptDialogComponent implements OnInit {
  scriptControl = new FormControl({value: '', disabled: true})

  constructor(
    @Inject(MAT_DIALOG_DATA) public data: any
  ) {}

  ngOnInit(): void {
    this.scriptControl.setValue(this.data.desc);
  }
}
