Closed Keith94 closed 6 years ago
Firefox seems does it with very complicated technique, and it seems impossible to be done by simple CSS rules by 1 or 2 lines. I need PR to implement this.
@piroor Maybe this implementation (CSS) would work also for TST? https://github.com/eoger/tabcenter-redux/commit/c17a99dc67193ddd2b3564ba46cb8e7eafe651da
Hmm, Tab Center Redux's way seems different from Firefox's one.
Firefox:
Tab Center Redux:
Anyway both ways require more effort. To be honest I think both they are not attractive for me - the cost-performance seems not high. Until more easier way like text-overflow: fade-out
is introduced, I won't implement this by myself. (Instead I'm still waiting PRs ;) )
Thanks for the info! Hopefully there will be an easier way at some point.
text-overflow: fade-out
should really be implemented within CSS. Two years since the proposal, and no browser really bothers to implement it.
https://developer.mozilla.org/en-US/docs/Web/CSS/text-overflow
@piroor I found some simple code that achieves the fade out effect quite nicely. Can you try it?
.tab .label {
mask-image: linear-gradient(to left, transparent 0, black 2em);
}
@Keith94 Wow, this works on the released version of Firefox also!
I've added the rule as a built-in style of TST itself.
Looks good to me. :)
Adding faded tab labels would look more consistent with the rest of Firefox UI. See https://bugzilla.mozilla.org/show_bug.cgi?id=658467