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

Tables: Set simpler selectors to decrease specificity #39608

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

louismaximepiton
Copy link
Member

@louismaximepiton louismaximepiton commented Jan 25, 2024

Description

Re introduce v4 selectors.
Adapt the selectors accordingly so we can support .table > tr > td.
Question that need to be answered:

  • Is that fine supporting this new way to use our selectors ?
    • .table > tbody.table-striped > tr:nth-of-type(odd) > *
    • .table > * > tr.table-sm > *

Motivation & Context

The actual specificity seems quite controversial and seems to be a bit too high.
Some tables implement simpler structures so with these selectors, it might be easier to handle these kind of tables.
Make the use of table selectors easier for everyone.
Keep the nested thing. It should be kept with the provided code.

Type of changes

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

Checklist

  • I have read the contributing guidelines
  • My code follows the code style of the project (using npm run lint)
  • My change introduces changes to the documentation
  • I have updated the documentation accordingly
  • I have added tests to cover my changes
  • All new and existing tests passed

Live previews

Related issues

Might close #34184.
Might supersede #34269.
Some commentary in much issues such as #38779 (comment)

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

Successfully merging this pull request may close these issues.

Buttons do not show up properly in a table without a tbody
1 participant