Skip to content

close dialog from it's own controller #5310

@twoheaded

Description

@twoheaded

Bug, feature request, or proposal:

Feature request or proposal

What is the expected behavior?

How can I close md-dialog from it's own controller and send data without clicking a buttons in md-dialog-actions container?

What is the current behavior?

It is not possible to close dialog and share data from the dialog controller.

What are the steps to reproduce?

Create md-dialog component and try to close it with sending a data by click on the element in md-dialog-content.

What is the use-case or motivation for changing an existing behavior?

I have an items list in the md-dialog. Every item have a checkbox and title. I wont to add checked items to data and send them by click on the md-dialog-actions button. And I want to add one item to the data, send it to parent controller and close dialog by click on the item title. How can I do it without crutches?

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Angular 4+, Material beta.7

Is there anything else we should know?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions