import { Component } from '@angular/core';
import { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';
import * as i0 from "@angular/core";
import * as i1 from "@angular/material/legacy-dialog";
import * as i2 from "@angular/forms";
import * as i3 from "@angular/material/legacy-button";
import * as i4 from "@angular/material/legacy-form-field";
import * as i5 from "@angular/material/legacy-input";
/**
 * NonReleventFeedbackDialogComponent - Stub component
 * Displays a dialog for collecting feedback when content is marked as not relevant
 */
export class NonReleventFeedbackDialogComponent {
    constructor(dialogRef) {
        this.dialogRef = dialogRef;
        this.feedbackForm = new UntypedFormGroup({
            feedback: new UntypedFormControl('', [Validators.required]),
        });
    }
    ngOnInit() { }
    onSubmit() {
        if (this.feedbackForm.valid) {
            this.dialogRef.close(this.feedbackForm.value.feedback);
        }
    }
    onCancel() {
        this.dialogRef.close();
    }
    static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: NonReleventFeedbackDialogComponent, deps: [{ token: i1.MatLegacyDialogRef }], target: i0.ɵɵFactoryTarget.Component }); }
    static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: NonReleventFeedbackDialogComponent, selector: "ws-non-relevent-feedback-dialog", ngImport: i0, template: "<div class=\"feedback-dialog\">\n  <h2 mat-dialog-title>Feedback</h2>\n  <mat-dialog-content>\n    <form [formGroup]=\"feedbackForm\">\n      <mat-form-field class=\"full-width\" appearance=\"outline\">\n        <mat-label>Please tell us why this content is not relevant</mat-label>\n        <textarea matInput formControlName=\"feedback\" rows=\"4\"></textarea>\n      </mat-form-field>\n    </form>\n  </mat-dialog-content>\n  <mat-dialog-actions align=\"end\">\n    <button mat-button (click)=\"onCancel()\">Cancel</button>\n    <button mat-raised-button color=\"primary\" (click)=\"onSubmit()\" [disabled]=\"!feedbackForm.valid\">Submit</button>\n  </mat-dialog-actions>\n</div>\n", styles: [".feedback-dialog{padding:16px}.feedback-dialog .full-width{width:100%}\n"], dependencies: [{ kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i3.MatLegacyButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button],             button[mat-fab], button[mat-mini-fab], button[mat-stroked-button],             button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i4.MatLegacyFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i4.MatLegacyLabel, selector: "mat-label" }, { kind: "directive", type: i5.MatLegacyInput, selector: "input[matInput], textarea[matInput], select[matNativeControl],      input[matNativeControl], textarea[matNativeControl]", exportAs: ["matInput"] }, { kind: "directive", type: i1.MatLegacyDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "directive", type: i1.MatLegacyDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "directive", type: i1.MatLegacyDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }] }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: NonReleventFeedbackDialogComponent, decorators: [{
            type: Component,
            args: [{ selector: 'ws-non-relevent-feedback-dialog', template: "<div class=\"feedback-dialog\">\n  <h2 mat-dialog-title>Feedback</h2>\n  <mat-dialog-content>\n    <form [formGroup]=\"feedbackForm\">\n      <mat-form-field class=\"full-width\" appearance=\"outline\">\n        <mat-label>Please tell us why this content is not relevant</mat-label>\n        <textarea matInput formControlName=\"feedback\" rows=\"4\"></textarea>\n      </mat-form-field>\n    </form>\n  </mat-dialog-content>\n  <mat-dialog-actions align=\"end\">\n    <button mat-button (click)=\"onCancel()\">Cancel</button>\n    <button mat-raised-button color=\"primary\" (click)=\"onSubmit()\" [disabled]=\"!feedbackForm.valid\">Submit</button>\n  </mat-dialog-actions>\n</div>\n", styles: [".feedback-dialog{padding:16px}.feedback-dialog .full-width{width:100%}\n"] }]
        }], ctorParameters: function () { return [{ type: i1.MatLegacyDialogRef }]; } });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibm9uLXJlbGV2ZW50LWZlZWRiYWNrLWRpYWxvZy5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9saWJyYXJ5L3N1bmJpcmQtY2IvdG9jL3NyYy9saWIvY29tcG9uZW50cy9ub24tcmVsZXZlbnQtZmVlZGJhY2stZGlhbG9nL25vbi1yZWxldmVudC1mZWVkYmFjay1kaWFsb2cuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vLi4vbGlicmFyeS9zdW5iaXJkLWNiL3RvYy9zcmMvbGliL2NvbXBvbmVudHMvbm9uLXJlbGV2ZW50LWZlZWRiYWNrLWRpYWxvZy9ub24tcmVsZXZlbnQtZmVlZGJhY2stZGlhbG9nLmNvbXBvbmVudC5odG1sIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxTQUFTLEVB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