Skip to content
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

Getting height of BottomSheet while transition #288

Open
motto76 opened this issue Sep 8, 2023 · 1 comment
Open

Getting height of BottomSheet while transition #288

motto76 opened this issue Sep 8, 2023 · 1 comment

Comments

@motto76
Copy link

motto76 commented Sep 8, 2023

Hello,

is it possible to get the current height of the BottomSheet during resizing?

Background is:
I want to display a button always above the BottomSheet during a resize.
So far I get the current height only at the end of the transition.

The example in the documentation (at "height") also shows a height only at the end of the transition.

@motto76
Copy link
Author

motto76 commented Nov 8, 2023

Hello, we have solved the problem as follows:

  1. css configuration of the button component with reference to '--rsbs-overlay-h' and '--rsbs-overlay-translate-y'
    bottom: (calc(var(--rsbs-overlay-h) - var(--rsbs-overlay-translate-y))
  2. defined the button as a sibling on the BottomSheet

Result:
When the bottom sheet is moved, the button moves as desired.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant