Closed fweth closed 2 years ago
Hello,
I don't know what exactly you want to achieve. Could you please provide some more context?
When I test the CodeSandbox above on Safari, I can't type text in the input field. This only happens
-webkit-user-select: none
activated (e.g. on the body) andTNCSSR with user-select: none
does not envoke this behaviour in the Chrome browser. So I can't really explain it, but it's definitely a change of behaviour I wouldn't expect from importing the TNCSSR style sheet.
The problem seems to be introduced by input { -webkit-user-select: unset }
which is implicitly called by the first statement in the reset. Apparently in Safari, the user agent style sheet has -webkit-user-select: text
for the input element and text input is not working when this value is set to none
. But without the reset, setting -webkit-user-select: none
on the body also isn't inherited by the input field, as it has its own value already. In Chrome, the user agent style sheet sets no value for user-select
on the input field, and setting it to none
seems to not change its behaviour. So feel free to interpret this as bug or not, for me it was at least unexpected.
Hi @fweth,
Sorry for checking it out so late. Added patch to prevent it for hapaning in the new version 1.7.0.
/* Safari - solving issue when using user-select:none on the <body> text input doesn't working */
input ,textarea {
-webkit-user-select: auto;
}
Safaru bug fixed - Issue Closed
When setting
-webkit-user-select: none
on the body, I can't type into text input fields in Safari, see here (code). Not sure what is happening exactly here (in Chrome everything works fine), but it seems related to TNCSSR. Feel free to delete if this is offtopic.