components icon indicating copy to clipboard operation
components copied to clipboard

fix(cdk/overlay): fix overlay margin in isBoundedByLeftViewportEdge

Open kryshac opened this issue 7 months ago • 3 comments

When the overlay is opening 'left-ward' (the content flows to the left) the margin is not calculated correctly because the margin is subtracted twice from the width (line: 1092), but here it is added only once

kryshac avatar Dec 05 '23 00:12 kryshac

I'm not sure if this is the desired behavior? It's been a long time since I wrote this, but I think that we'd want to keep it such that the rightmost edge of the bounding box is the actual viewport edge minus one margin, no?

jelbourn avatar Dec 05 '23 23:12 jelbourn

because I have a margin in the viewport, the overlay goes to the right, exactly as much as the margin is set image

kryshac avatar Dec 05 '23 23:12 kryshac

and also the same behavior is implemented when calculating the bottom line 772

kryshac avatar Dec 05 '23 23:12 kryshac

@jelbourn @mmalerba hello, what is happening with this pull request?

kryshac avatar Feb 11 '24 20:02 kryshac

..

GiorgiZanqaidze avatar Feb 24 '24 19:02 GiorgiZanqaidze

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.