-
Notifications
You must be signed in to change notification settings - Fork 6.8k
chore(overlay): add attach
method to PositionStrategy interface
#6505
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
Conversation
After fixing the bad |
I've updated this to now omit the overlay element from |
/** Updates the position of the overlay element. */ | ||
apply(element: Element): void; | ||
apply(): void; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe attach
and apply
should return this
so they can be chained?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd rather leave them as is since normal use wouldn't chain them, just the tests
src/lib/menu/menu.spec.ts
Outdated
@@ -974,7 +974,7 @@ describe('MdMenu', () => { | |||
.not.toContain('mat-elevation-z3', 'Expected no stacked elevation.'); | |||
}); | |||
|
|||
it('should close all of the menus when the root is closed programmatically', () => { | |||
it('should close all of the menus when the root is closed programmatically', fakeAsync(() => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should get these changes if you rebase.
element: HTMLElement; | ||
|
||
apply(): void { | ||
this.element.classList.add('fake-positioned'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a test that this gets executed at the proper time?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't follow what you mean; the existing test for this still applies- is there something that isn't covered?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah sorry, didn't know that we had something in place already.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, one typo
this._pane = overlayRef.overlayElement; | ||
} | ||
|
||
/** To be used to for any cleanup after the element gets destroyed. */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: to for any cleanup
-> for any cleanup
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Caretaker note: This is technically a breaking API change, but I don't think anyone inside Google will be affected by it |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
No description provided.