title: how to access properties of a component inside a angular material pop up/dialog component?
body: <p>I am opening one dialog from my component.</p>
  
  <pre><code> const dialogRef = this.dialog.open(DialogOverviewExampleDialog, {
               width: '500px',
              data: DialogData
              });
  
      dialogRef.afterClosed().subscribe(result =&gt; {
          this.dialogData = new DialogData('label...',this.frequency,'action','screen_ocr','parameter_type','parameter_value',0,'next_node',1,'index',false);
        console.log('The dialog was closed');
  
      });
  </code></pre>
  
  <p>I wan to access few properties from this component to initialize DialogOverviewExampleDialog </p>
  
  <pre><code>@Component({
    selector: 'dialog-overview-example-dialog',
    templateUrl: 'dialog-overview-example-dialog.html',
  })
  export class DialogOverviewExampleDialog {
  
      //here I want to use properties of my component
  
    constructor(private dialogService: DialogDataService,
      public dialogRef: MatDialogRef&lt;DialogOverviewExampleDialog&gt;,
      @Inject(MAT_DIALOG_DATA) public data: DialogData) {}
  </code></pre>
  
  <p>The only way , I could figure out this is using behaviorsubject of rxjs to access properties, However this DialogOverviewExampleDialog is declared inside my component itself. Is there a way to directly access properties of my component inside DialogOverviewExampleDialog ? and vice versa as well.</p>
  
  <p>Thanks,</p>