Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

feat($mdDialog): add prompt #6769

Closed
wants to merge 1 commit into from
Closed

feat($mdDialog): add prompt #6769

wants to merge 1 commit into from

Conversation

zbjornson
Copy link

Add preconfigured dialog for prompt. Fixes #4995.

I didn't see the bit about "not actively reviewing unsolicited PRs" until after I did this :(. This is relatively minor, only 20 lines of code; remaining 160 are docs and tests.

Add preconfigured dialog for prompt. Fixes #4995
};
this.abort = function() {
$mdDialog.cancel();
};
this.keypress = function($event) {
if ($event.keyCode === $mdConstant.KEY_CODE.ENTER) {
$mdDialog.hide(this.result)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you not want to call this.hide() instead in order to account for type == 'prompt'?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ng-keypress is only set if dialog.$type == 'prompt' on line 520, so it won't make a difference, if I understand your question.

@ThomasBurleson
Copy link
Contributor

@zbjornson - see my one (1) question/concern.

Nice work and enhancement. Like the tests also.

@ThomasBurleson ThomasBurleson added this to the 1.0.4 milestone Jan 26, 2016
@ThomasBurleson ThomasBurleson added pr: merge ready This PR is ready for a caretaker to review needs: feedback The issue creator or community need to respond to questions in this issue labels Jan 26, 2016
@zbjornson
Copy link
Author

Thanks for the review!

@ThomasBurleson ThomasBurleson modified the milestones: 1.0.4, 1.0.5 Jan 30, 2016
@ThomasBurleson ThomasBurleson removed the needs: feedback The issue creator or community need to respond to questions in this issue label Jan 30, 2016
@ThomasBurleson ThomasBurleson self-assigned this Jan 30, 2016
ErinCoughlan pushed a commit to ErinCoughlan/material that referenced this pull request Feb 9, 2016
Add preconfigured dialog for prompt.

Fixes angular#4995. Closes angular#6769.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
pr: merge ready This PR is ready for a caretaker to review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants