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

Fixes #2237 Round corners in child tables inconsistent #2249

Merged
merged 2 commits into from Oct 19, 2015
Merged

Fixes #2237 Round corners in child tables inconsistent #2249

merged 2 commits into from Oct 19, 2015

Conversation

SvePu
Copy link
Contributor

@SvePu SvePu commented Oct 18, 2015

  • Defined the desired CSS rule only for first child of tborder class.
  • Changed the version number of css3.css to 1807

Defined the desired CSS rule only for first child of tborder class.
@Eldenroot
Copy link
Contributor

#2237

@Destroy666x
Copy link
Contributor

It works in this case, but it's unfortunately not a proper fix. I'm sure this CSS rule was added for a reason and changing it to affect only tables which are first children may break rounded borders in some other table(s).

EDIT: and your solution won't of course also work if the table is the first child of the <td> - in this case there's a lot of stuff before it.

The main issue here is something else - .tborder tbody tr:last-child td:first-child affects all descendant, including all first/last cells from table(s) in the last row, while it should affect only the closest children. The > selector should be used in between elements so that only the closest ones will be affected: .tborder > tbody > tr:last-child > td:first-child After applying: http://nooo.hol.es/mybb18/newreply.php?tid=5&replyto=20

Invisible bottom borders can/should be fixed that way too by applying the same code to

.tborder  tbody  tr:last-child  td {
    border-bottom: 0;
}

@Destroy666x Destroy666x added the b:1.8 Branch: 1.8.x label Oct 18, 2015
@SvePu
Copy link
Contributor Author

SvePu commented Oct 19, 2015

You're right @Destroy666x

Now I've tested it with different trow colors for a better view.

unbenannt

The new solution is:

.tborder tbody tr:last-child > td {
    border-bottom: 0;
}

.tborder tbody tr:last-child > td:first-child {
    -moz-border-radius-bottomleft: 6px;
    -webkit-border-bottom-left-radius: 6px;
    border-bottom-left-radius: 6px;
}

.tborder tbody tr:last-child > td:last-child {
    -moz-border-radius-bottomright: 6px;
    -webkit-border-bottom-right-radius: 6px;
    border-bottom-right-radius: 6px;
}

Could you test it please, if it's OK than I'll modify the PR

@Destroy666x
Copy link
Contributor

Should be ok to add > only there too, yes.

@SvePu
Copy link
Contributor Author

SvePu commented Oct 19, 2015

Modified PR in afa0aaf

@SvePu SvePu changed the title Fixes #2237 Fixes #2237 Round corners in child tables inconsistent Oct 19, 2015
@Destroy666x
Copy link
Contributor

Ok, thanks.

@Destroy666x Destroy666x self-assigned this Oct 19, 2015
Destroy666x added a commit that referenced this pull request Oct 19, 2015
Fixes #2237 Round corners in child tables inconsistent
@Destroy666x Destroy666x merged commit ef0bffb into mybb:feature Oct 19, 2015
@SvePu SvePu deleted the patch-1 branch October 19, 2015 22:09
@SvePu SvePu restored the patch-1 branch October 19, 2015 22:09
@SvePu SvePu deleted the patch-1 branch October 19, 2015 22:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
b:1.8 Branch: 1.8.x
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants