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

Image replacement not clear to me #13883

Closed
Willem-Siebe opened this issue Jun 20, 2014 · 3 comments
Closed

Image replacement not clear to me #13883

Willem-Siebe opened this issue Jun 20, 2014 · 3 comments
Labels

Comments

@Willem-Siebe
Copy link

Hi,

In the proces of updating V2 to V3 I spend houres to see if the image replacement technique in V2 is still to one to be used.

First I noticed this: https://github.com/twbs/bootstrap/blob/82e2f87363d960b647bc1e97bf53bbb229b0e703/less/mixins/hide-text.less.

If .hide-text will be removed in V4, then .text-hide, that is including .hide-text, will not be working anymore either, right?

Also you are linking to HTML5 Boilerplate in that file, but on that page somebody commented:

The latest version of boilerplate appears to use the clip method, and have no .ir class anymore. In which case that's great. And I'm not sure why I am commenting on this page. :)

Also, in the changelog of HTML5 boilerplate, the removed .ir helper class, see https://github.com/h5bp/html5-boilerplate/blob/8c4b71e6c601550680d45f7d719cd9c1f6b0fe4d/CHANGELOG.md.

So, what should I use for image replacement? Finally, the goal is to present normal graphical browser users an image, and the screenreader the text! I also found the .sr-only in V3 of Bootstrap, where I also see 'clip' being used, is that the new image replacement? I do understand this is also helpfull for labels in forms etc., but I'm messed up with what to use for image replacement now.

Kind regards,

Willem

@mdo mdo added the css label Jun 23, 2014
@mdo
Copy link
Member

mdo commented Jun 23, 2014

.hide-text will be dropped, but .text-hide will remain in v4 with the proper styles. It's just a class deprecation for consistency in naming.

@mdo mdo closed this as completed Jun 23, 2014
@Willem-Siebe
Copy link
Author

@mdo For me, it's just nog clear why it makes a difference to name something .hide-text or .text-hide. I would love to understand that, but the only thing I can find is this:

#10100: Deprecate .hide-text mixin for .text-hide. This matches our class-mixin strategy elsewhere (e.g., .clearfix) and ensures the class and mixin use the same name to avoid confusion.

I would like to understand this class-mixin strategy, where can I read more about that?

@mdo
Copy link
Member

mdo commented Jul 11, 2014

@Willem-Siebe No where right now—it's just our way of writing things. Come v4 I hope to add something to the docs to explain it.

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

No branches or pull requests

3 participants
@mdo @Willem-Siebe and others