Closed tristen closed 3 years ago
This is half a specific question about this and half a general one about assembly in general - why not call it hide-overflow
or something closer to what the actual CSS declaration is?
I had to use this a bit ago and knew I needed overflow: hidden;
but ctrl-f
ing on the assembly docs didn't help me at all, had to go into the actual assembly css file to find what I needed.
why not call it
hide-overflow
or something closer to what the actual CSS declaration is?
I think the reasoning was that scroll-{value}
had already been established. One class in that list is scroll-styled
which doesn't apply overflow rules. That naming sounds like a good alternative approach though! We could rename the following:
.scroll-always
👉 .overflow-scroll
.scroll-auto
👉 .overflow-auto
.scroll-hidden
👉 .overflow-hidden
And just leave scroll-styled
on its own under the miscellaneous group in the docs.
We could rename the following:
Ya, this seems like the right answer. Better than using clip
.
I think we should revert https://github.com/mapbox/assembly/issues/847. The argument was that it follows the
scroll-{value}
naming convention. In practice though,overflow:hidden
isn't always used to target scroll behavior. One technique is to clip images in rounded containers.clip
is a general enough name to capture both scenarios and is much easier to remember 😤