Is there any way to make the ModalDrawer pull out ...
# compose
u
Is there any way to make the ModalDrawer pull out from the right side of the screen?
k
In the documentation they do mention specifically that the
drawerContent
is for Drawer sheet that can be pulled from the left side (right for RTL)
so I think you’d have to look at the scaffold code and pick the part relevant to the drawer in order to implement your own, if you want to get one on the other side
u
implement your own, if you want to get one on the other side
Ah, you mean I have to implement my own version of Drawer because they don’t support pulling out from thee right side?
k
I think so yes
😢 1
🙏 1
j
As a dirty dirty hack you might be able to provide the
LocalLayoutDirection
as
LayoutDirection.rtl
for the
ModalDrawer
and then provide the proper
LayoutDirection
for the drawer content and children again
I think there might be an issue for support for this already, but if you don't find one you should open one
Alternatively, pull out the relevant part from the Drawer as @Kevin Aude said Something like https://gist.github.com/jossiwolf/fee47af3602d65bef58c754561c800a7
🙏 2
u
Thank you Jossi and Kevin for your awesome suggestions!
👍 2
Came up with this customized solution in case anyone wants to use it: https://gist.github.com/iamutkarshtiwari/e6ce774aa02499b021193ef6ee0d6db6