palantir / blueprint

A React-based UI toolkit for the web
https://blueprintjs.com/
Apache License 2.0
20.51k stars 2.15k forks source link

use gap instead of margin for tab #6834

Closed JosephChotard closed 1 month ago

JosephChotard commented 1 month ago

By doing this, tabs can natively support RTL without breaking any LTR

Changes proposed in this pull request:

Instead of using margin for tab spacing use flex gap

Reviewers should focus on:

Screenshot

Looks identical

svc-palantir-github commented 1 month ago

use gap instead of margin

Build artifact links for this commit: documentation | landing | table | demo

This is an automated comment from the deploy-preview CircleCI job.

svc-palantir-github commented 1 month ago

made a mistake in 1 line PR

Build artifact links for this commit: documentation | landing | table | demo

This is an automated comment from the deploy-preview CircleCI job.

svc-palantir-github commented 1 month ago

ugh alphabetical

Build artifact links for this commit: documentation | landing | table | demo

This is an automated comment from the deploy-preview CircleCI job.

JosephChotard commented 1 month ago

Existing view in RTL mode (notice margins break)

Screenshot 2024-05-28 at 16 39 39

New view:

Screenshot 2024-05-28 at 16 40 58

LTR looks identical For these screenshots I added direction: rtl to a wrapper around the tab. We use RTL for Arabic / Hebrew text

JosephChotard commented 1 month ago

Example in arabic.

Now:

Screenshot 2024-05-28 at 16 48 05

Before:

Screenshot 2024-05-28 at 16 49 18
stewartfeasby commented 1 hour ago

Hi

This completely breaks vertical tabbing now, which previously had no gap but now has massive gaps.

Thanks