Skip to content

feat(autocomplete): add the ability to set a different panel connection element #11284

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 1 commit into from
May 15, 2018

Conversation

crisbeto
Copy link
Member

Currently the autocomplete panel gets attached to the trigger element, however this can be inflexible in the cases where people have a custom input wrapper. These changes add the ability to have an autocomplete be attached to an element that is different from the trigger.

Fixes #11269.

@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label May 11, 2018
Copy link
Member

@jelbourn jelbourn left a comment

Choose a reason for hiding this comment

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

LGTM, that was way faster than I expected


<mat-autocomplete #auto="matAutocomplete">
<mat-option *ngFor="let option of options" [value]="option">
{{ option }}
Copy link
Member

Choose a reason for hiding this comment

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

Omit spaces in braces

@jelbourn jelbourn added pr: lgtm action: merge The PR is ready for merge by the caretaker target: minor This PR is targeted for the next minor release and removed pr: needs review labels May 11, 2018
…on element

Currently the autocomplete panel gets attached to the trigger element, however this can be inflexible in the cases where people have a custom input wrapper. These changes add the ability to have an autocomplete be attached to an element that is different from the trigger.

Fixes angular#11269.
@crisbeto crisbeto force-pushed the 11269/autocomplete-origin branch from 625ad6e to 144e0a5 Compare May 12, 2018 07:44
@tinayuangao tinayuangao merged commit efe37f5 into angular:master May 15, 2018
crisbeto added a commit to crisbeto/material2 that referenced this pull request May 15, 2018
…on element (angular#11284)

Currently the autocomplete panel gets attached to the trigger element, however this can be inflexible in the cases where people have a custom input wrapper. These changes add the ability to have an autocomplete be attached to an element that is different from the trigger.

Fixes angular#11269.
@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 8, 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: minor This PR is targeted for the next minor release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

MatAutoComplete is not allowed to be attached to the form
4 participants