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

Block property on button does not consistently work properly #3088

Open
1 of 6 tasks
gremlin529 opened this issue Sep 11, 2023 · 4 comments
Open
1 of 6 tasks

Block property on button does not consistently work properly #3088

gremlin529 opened this issue Sep 11, 2023 · 4 comments

Comments

@gremlin529
Copy link
Contributor

Willing to submit a PR to fix?

  • I am willing to submit a PR to fix

Requested priority

High

Products/applications affected

I'm trying to use "Block:{true}" on buttonv1 to get a full width button, as opposed to just using a style and it seems to extend off the screen in some cases, in this case we've got a bottom sheet container that the button is in:

image

anyone have thoughts on what's happening here?

Package version(s)

0.35.1

OS version(s)

No response

Platform

  • iOS
  • macOS
  • win32
  • windows
  • android

Xcode version

No response

Please provide a reproduction of the bug

Just use foo is what I did above.

Actual behavior

Button goes off screen

Expected behavior

more like align-self:"stretch" which seems to work when I add it to the style

@thesharifi
Copy link

@Saadnajmi, please assign this to me.

@Saadnajmi
Copy link
Collaborator

Saadnajmi commented Oct 3, 2023

@Saadnajmi, please assign this to me.

We don't really use the assign feature of GitHub issues much, but please feel free to go for it! :)

@gremlin529
Copy link
Contributor Author

@Saadnajmi, please assign this to me.

Thank you thesharifi, I'd also like to understand if it's possible for this to work under android as currently it does not. If that isn't possible then I wonder if should just be worked around some other way globally.

@gremlin529
Copy link
Contributor Author

@Saadnajmi, please assign this to me.

We don't really use the assign feature of GitHub issues much, but please feel free to go for it! :)

So I've done a bit more digging and I've found an interesting issue. If you want a FURN Button component to be the full width of the container on iOS and Android there's some more issues. Android doesn't support Block so you can set the button width to 100% and that works, and it works on iOS as well, but if you want the button to have say a left and right margin to the edges so you set margin:10, then you'll see on Android it works but on iOS it will compute the width of the button first, then move it over the 10 from the left, resulting in this behaviour of the button being off screen on the right.

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

3 participants