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

Disable text selection #76

Closed
Bert-Proesmans opened this issue Mar 31, 2014 · 5 comments
Closed

Disable text selection #76

Bert-Proesmans opened this issue Mar 31, 2014 · 5 comments

Comments

@Bert-Proesmans
Copy link

Hello

I was playing Adarkroom earlier today and i just found out it's on GitHub.
I would like to suggest a fix to the game so the players won't experience this nasty blue color when clicking too much on the same button.
IThere was a ::selection property set to invisible, but i suppose it's for something else than text selection since it doesn't change the color of the selected text.

My HTML/CSS/Javascript knowledge isn't that great so i just throw in CSS declarations which should work according to StackOverflow questions:
user-select: none;
-> works on roughly 80% of the browsers being used
(source: http://caniuse.com/#feat=user-select-none )

alternative style codes:
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;

I'm also not sure if these properties are applicable on the body/wrapper element so the childs could inherent it. Maybe someone of you guys can code my suggestion to life?

@Continuities
Copy link
Contributor

I thought I already had user-select:none in there... If not, it's a good idea. I'll take a look at the CSS tonight.

@Bert-Proesmans
Copy link
Author

Thanks!

Although I should have checked the full source before posting this to save you from the work, apologies.

@Continuities
Copy link
Contributor

As I suspected, I already have user-select:none on the button class. Doesn't seem to work %100, though... What a pain in the butt.

@groteworld
Copy link
Member

I've had to deal with this issue before, the PR is what I've used to fix this issue.

@Bert-Proesmans
Copy link
Author

i'm glad this issue gets fixed.
Thanks grotr & Continuities!

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

No branches or pull requests

3 participants