Questions tagged [angular-cdk-overlay]
10 questions
1
vote
0 answers
How to drag and drop from mat-menu to another element on the page (using cdkdrag Angular Material)
Is there any way to drag from mat-menu and drop to another element on the page (using cdkdrag)?
The approach taken by greatweatherforducks in this answer is very interesting, but it doest use cdkdrag, just the DragEvent interface.
I have tried to…

Gustavo López Frutos
- 61
- 1
- 6
1
vote
2 answers
Two Mat-Menus on one page, control position for both separately
I have these two menus below. I want to control the cdk-overlay-connected-position-bounding-box css property of both mat menus (their overlays) and align one menu align-items: flex-start; and the other align-items: flex-end;
I have tried setting the…

Generaldeep
- 437
- 2
- 12
- 30
1
vote
0 answers
Angular - access position for overlay of a Material component
I'm facing an issue while working on a custom flyout component which utilizes Overlay CDK. I followed this article and it works fine (after upgrading some deprecated code), just one thing seems a bit off to me.
I have a flyout service, which opens…

mat.hudak
- 2,803
- 2
- 24
- 39
1
vote
1 answer
Angular CDK Overlay Animation on overlay works only on first time
I'm trying to implement a generic auto completion.
My code is structured in following way
dsAutocomplete directive is top level directive
dsAutocompleteInputTrigger is directive attached to element
dsAutoCompleteOrigin is attached to…

AbdulKareem
- 1,199
- 8
- 24
0
votes
0 answers
Angular Material Dialog / Overlay needs click to dom after close sometimes
I have got the following problem:
I have a list with a "headerbar", where I can change some settings of the list view. This happens in a dialog the user can open.
But sometimes (and I can't figure out when), when the Dialog is closed, the scrolling…

Peter Bucher
- 48
- 1
- 5
0
votes
0 answers
Can't Get Button Click on Angular Material CDK Overlay
I am using the Angular Material CDK Overlay to show some options once an HTML element is clicked and I cannot figure out how to get the buttons to trigger a click event. Is there a way to do this?
I need to know which button was clicked and I cannot…

bschmitty
- 1,118
- 3
- 16
- 46
0
votes
1 answer
google.maps.places.Autocomplete position offset inside angular material Dialog
I'm using a google autocomplete input inside angular material Dialog.
When the user scrolls a bit down, material Dialog uses a trick and (according to source):
/** Blocks page-level scroll while the attached overlay is open .
This in turn adds a…

Eli
- 1,670
- 1
- 20
- 23
0
votes
1 answer
Angular - set overlay margin depending on its position strategy
I'm working on a custom overlay component and I need to set a margin on it. It should be 0.5rem depending on the position of the overlay (e.g. originY === 'bottom' => margin-top: 0.5rem, and so on). I was hoping to use PositionStrategy object for…

mat.hudak
- 2,803
- 2
- 24
- 39
0
votes
2 answers
Angular CDK Overlay - Mocking overlay component in unit test
I've created an offcanvas component for angular, but I can't get my unit tests to work.
Here's the failing unit test (offcanvas-host.component):
describe('BsOffcanvasHostComponent', () => {
let component: BsOffcanvasTestComponent;
let fixture:…

Pieterjan
- 2,738
- 4
- 28
- 55
0
votes
1 answer
angular - Preserve state of overlay
I've been building a component library for angular which contains an accordion and offcanvas component. I've created a minimal StackBlitz with a demo.
Now I want to be able to preserve the expanded states of the accordion in the sidebar. Currently,…

Pieterjan
- 2,738
- 4
- 28
- 55