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

Remove bottom margin from tables #419

Conversation

Tomasito665
Copy link

@Tomasito665 Tomasito665 commented Mar 4, 2024

Description

  • Set 'margin-bottom' to 0

Related Issue

N/A

Motivation and Context

We noticed how Table components show a horizontal show bar always regardless of whether the table overflows its parent container. We fixed this in adobe/parliament-ui-components#200 by setting overflow-x to 'auto'. Besides the horizontal scroll bar, we noticed that table components have a bottom margin. We think we should not add this margin to all tables because of the following reasons.

  • The margin makes the layout inconsistent - while tables have a bottom margin, they don't have a top margin.
  • Doc authors cannot remove whitespace but can add it by adding breaklines - so, better too little margin than to much.

How Has This Been Tested?

Ran Parliament locally with this change - table bottom margin gone.

Before

image

After

image

Note how there still is some whitespace between the table and the second paragraph. That's not the table's bottom margin but the paragraph's top margin. See the video attached to the pull request description of adobe/parliament-ui-components#200 for a more detailed demonstration.

Screenshots (if appropriate):

See previous section.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have signed the Adobe Open Source CLA.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@solimant solimant changed the base branch from dev to main March 4, 2024 16:58
@solimant solimant changed the base branch from main to remove_table_bottom_margin March 4, 2024 17:01
@solimant solimant merged commit 4aaadee into adobe:remove_table_bottom_margin Mar 4, 2024
2 of 3 checks passed
@solimant solimant mentioned this pull request Mar 4, 2024
10 tasks
solimant added a commit that referenced this pull request Mar 4, 2024
Co-authored-by: Jordi Ortolá Ankum <Tomasito665@users.noreply.github.com>
@Tomasito665 Tomasito665 deleted the remove_table_bottom_margin branch March 12, 2024 14:10
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

Successfully merging this pull request may close these issues.

None yet

2 participants