overflow:auto is not working properly in Firefox to spell check for typed text in text area. When I right click on incorrect text and select correct text from suggested texts, it does not show correct selected text.

CSS code used:

div.mystyle:hover {
overflow: auto; 
}

See Code here

It works fine in chrome.

Is there any workaround for it? Note: I need this class should be overflow auto for some other reason.

有帮助吗?

解决方案

You may set that style dynamically to div. We set that style using jquery,

Script,

 $(".mystyle").hover(function () {
     $(this).attr("style", "overflow:auto");
 });

Here is the working DEMO

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top