Skip to content

fix(button-toggle): error when checked value is set via static attribute in Ivy #16587

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
Jul 25, 2019

Conversation

crisbeto
Copy link
Member

Fixes the button toggle throwing an error under Ivy, if its checked value is set via a static attribute (e.g. <mat-button-toggle checked>). The issue comes from the fact that in Ivy static inputs are set during creation, which means that the selection model isn't initialized yet.

Fixes #16471.

@crisbeto crisbeto added P2 The issue is important to a large percentage of users, with a workaround target: patch This PR is targeted for the next patch release labels Jul 22, 2019
@crisbeto crisbeto requested a review from jelbourn as a code owner July 22, 2019 19:42
@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Jul 22, 2019
…e in Ivy

Fixes the button toggle throwing an error under Ivy, if its `checked` value is set via a static attribute (e.g. `<mat-button-toggle checked>`). The issue comes from the fact that in Ivy static inputs are set during creation, which means that the selection model isn't initialized yet.

Fixes angular#16471.
@crisbeto crisbeto force-pushed the 16471/button-toggle-ivy-error branch from 5ade807 to 7398bb3 Compare July 22, 2019 20:01
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

@jelbourn jelbourn added pr: lgtm action: merge The PR is ready for merge by the caretaker labels Jul 23, 2019
@crisbeto crisbeto changed the title fix(button-toggle): error when check value is set via static attribute in Ivy fix(button-toggle): error when checked value is set via static attribute in Ivy Jul 23, 2019
@jelbourn jelbourn merged commit bd24369 into angular:master Jul 25, 2019
andrewseguin pushed a commit that referenced this pull request Jul 29, 2019
…e in Ivy (#16587)

Fixes the button toggle throwing an error under Ivy, if its `checked` value is set via a static attribute (e.g. `<mat-button-toggle checked>`). The issue comes from the fact that in Ivy static inputs are set during creation, which means that the selection model isn't initialized yet.

Fixes #16471.
@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 P2 The issue is important to a large percentage of users, with a workaround target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

MatButtonToggle errors with Ivy enabled
3 participants