Skip to content

Fix wrong autocomplete-plain-input example (fixes #16327) #16329

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jun 21, 2019

Conversation

alvaromartmart
Copy link
Contributor

Fix for #16327

@alvaromartmart alvaromartmart requested a review from jelbourn as a code owner June 19, 2019 09:25
@googlebot
Copy link

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed (or fixed any issues), please reply here (e.g. I signed it!) and we'll verify it.


What to do if you already signed the CLA

Individual signers
Corporate signers

ℹ️ Googlers: Go here for more info.

@googlebot googlebot added the cla: no PR author must sign Google's Contributor License Agreement: https://opensource.google.com/docs/cla label Jun 19, 2019
@alvaromartmart
Copy link
Contributor Author

@googlebot I signed it!

@googlebot
Copy link

CLAs look good, thanks!

ℹ️ Googlers: Go here for more info.

@googlebot googlebot added cla: yes PR author has agreed to Google's Contributor License Agreement and removed cla: no PR author must sign Google's Contributor License Agreement: https://opensource.google.com/docs/cla labels Jun 19, 2019
Copy link
Member

@crisbeto crisbeto left a comment

Choose a reason for hiding this comment

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

This file is auto-generated so your changes will be lost next time we create it. What issue is it trying to solve?

@alvaromartmart
Copy link
Contributor Author

@crisbeto I see...

I was trying to fix #16327. The example for "Autocomplete on a custom input element" is broken in the documentation, I opened the console and saw the error "Could not find example: autocomplete-plain-input".

I think it's because the example is declared as "plain-input-autocomplete" in the EXAMPLE_COMPONENTS object, while it is referred to as "autocomplete-plain-input" in the documentation markdown file https://github.com/angular/components/blob/master/src/material/autocomplete/autocomplete.md#L99

<!-- example(autocomplete-plain-input) -->

I don't know which one is wrongly named, I can fix the reference instead and submit a new pull request.

@crisbeto
Copy link
Member

If the reference is wrong, it should be fixed in the Markdown file. Also you can push your change to the same PR.

@alvaromartmart
Copy link
Contributor Author

Done, thanks for the feedback

@crisbeto
Copy link
Member

Sorry, I just double-checked and it looks like we have to generate the example-module file manually due to a build limitation. The issue here is that the name of the example component doesn't match it's selector. The proper fix would be to revert the changes in the readme and rename the example component from PlainInputAutocompleteExample to AutocompletePlainInputExample both in the autocomplete-plain-input-example.ts and the example-module.

Copy link
Member

@crisbeto crisbeto left a comment

Choose a reason for hiding this comment

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

LGTM

@crisbeto crisbeto added pr: lgtm action: merge The PR is ready for merge by the caretaker target: patch This PR is targeted for the next patch release labels Jun 20, 2019
@angular angular deleted a comment from ngbot bot Jun 20, 2019
@jelbourn jelbourn merged commit 8a05678 into angular:master Jun 21, 2019
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 11, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker cla: yes PR author has agreed to Google's Contributor License Agreement target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants