Skip to content

refactor(material/datepicker): expose month view change detector ref #21048

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

Conversation

MichaelJamesParsons
Copy link
Collaborator

Expose the datepicker month view's ChangeDetectorRef as part of its public (internal) API so it can be accessed by other components.

@google-cla google-cla bot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Nov 13, 2020
@MichaelJamesParsons MichaelJamesParsons added area: material/datepicker G This is is related to a Google internal issue P2 The issue is important to a large percentage of users, with a workaround labels Nov 13, 2020
@@ -180,7 +180,7 @@ export class MatMonthView<D> implements AfterContentInit, OnChanges, OnDestroy {
/** The names of the weekdays. */
_weekdays: {long: string, narrow: string}[];

constructor(private _changeDetectorRef: ChangeDetectorRef,
constructor(readonly _changeDetectorRef: ChangeDetectorRef,
Copy link
Member

Choose a reason for hiding this comment

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

The change is fine, but what's the context behind it? Which other components need to access it?

Copy link
Contributor

Choose a reason for hiding this comment

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

There's a Google internal datepicker spec based off this one. It's needed as part of implementing that.

@mmalerba mmalerba added the action: merge The PR is ready for merge by the caretaker label Nov 16, 2020
Copy link
Contributor

@mmalerba mmalerba left a comment

Choose a reason for hiding this comment

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

LGTM

@wagnermaciel wagnermaciel added the target: patch This PR is targeted for the next patch release label Nov 17, 2020
@wagnermaciel wagnermaciel merged commit a30b38f into angular:master Nov 17, 2020
wagnermaciel pushed a commit that referenced this pull request Nov 17, 2020
@MichaelJamesParsons MichaelJamesParsons deleted the datepicker-month-cdref branch November 17, 2020 19:43
@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 Dec 18, 2020
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 area: material/datepicker cla: yes PR author has agreed to Google's Contributor License Agreement G This is is related to a Google internal issue 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.

4 participants