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

[modal] inputs/components should be able to span full width #4790

Closed
aagonzales opened this issue Nov 27, 2019 · 6 comments · Fixed by #5046
Closed

[modal] inputs/components should be able to span full width #4790

aagonzales opened this issue Nov 27, 2019 · 6 comments · Fixed by #5046

Comments

@aagonzales
Copy link
Member

aagonzales commented Nov 27, 2019

Currently the modal has a padding-right of 25%. However, this padding-right should only apply to text in a modal and not restrict other components like form inputs and tables. Those should be able to span the full width of the modal container.

As-is:
image

To-be:
image

@asudoh
Copy link
Contributor

asudoh commented Nov 28, 2019

Hi @aagonzales does “trap focus” story address this issue? react.carbondesignsystem.com may be stale, but I think local clone shows the full width input when we shrink the browser's width. Thanks!

@aagonzales
Copy link
Member Author

@asudoh I'm not sure, I can't tell from just the code, I'd have to see it.

@asudoh
Copy link
Contributor

asudoh commented Dec 2, 2019

@aagonzales Does https://deploy-preview-4657--carbon-components-react.netlify.com/?path=/story/modal--trap-focus work? You'll see full width text box when you shrink the browser window. Please let me know if you have any questions - Thanks!

@jz2cao
Copy link

jz2cao commented Jan 10, 2020

@asudoh
I think @aagonzales was requesting if it is possible for carbon to allow user to utilize the full width of the modal for customized design elements (e.g. it makes sense to have the padding if we simply showing the header and content in the modal, we would also want to flexibility to use the full width if we want to put something like a form into the modal)

thanks

@aagonzales
Copy link
Member Author

(oops sorry for the very delayed response)
If bx--modal-content is just text should have the 20% padding right but the bx--modal-content bx--modal-content--with-form should have padding-right: 16px, so span the full width of the modal.

In the react storybook it was actually just the "default" size that wasn't doing this. The large one was also spanning the full width of the modal.

image

image

@asudoh
Copy link
Contributor

asudoh commented Jan 15, 2020

Thank you for clarifying @aagonzales @jz2cao! Created #5046.

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

Successfully merging a pull request may close this issue.

4 participants