-
Notifications
You must be signed in to change notification settings - Fork 7.6k
Editor unresponsive when clicked on commented CSS while live preview is active #9002
Comments
@RaymondLim Cannot reproduce unresponsiveness on 64bit Ubuntu 14.04. (on master ece9bbf). I do see a 'Unable to load live preview page' dialog; but this happens after the index.html of the
|
@Mark-Simulacrum That's a rather common error message, which is probably not part of the issue. |
@Mark-Simulacrum I found a more reproducible recipe that works for me on Win. Could you try it?
<html>
<head>
<link rel="stylesheet" href="i.css" type="text/css">
</head>
<body>
Some text.
</body>
</html> /* body {
background-color: black;
color: white;
} */
Result: The editor becomes unresponsive |
|
@marcelgerber Yes, your test case does allow me to reproduce the hang. Will test the PR branch soon. |
@Mark-Simulacrum @marcelgerber Since you both repro'ed this earlier, would one of you mind confirming the fix before we close it? (I tested it a bit during PR review, but this was a nasty enough bug that it never hurts to get some extra eyes on it). Thanks! |
@peterflynn @RaymondLim I'm sorry to say, but using the files from above recipe, the bug got even worse.
<html>
<head>
<link rel="stylesheet" href="i.css" type="text/css">
</head>
<body>
Some text.
</body>
</html> /* body {
background-color: black;
color: white;
} */
Result: The editor becomes unresponsive |
Ugh, sorry -- my fault. My last suggestion for simplifying the loop was not quite right. The stopping condition needs to exactly match how TokenUtils decides whether to stop & return false or not. @RaymondLim thee potential ways to fix that:
|
@RaymondLim I can post a fix using approach 2 above -- just proofed it out. |
Looks good now. |
Closing as fixed. @liaujianjie let us know if you still see problems. |
In release 43 (OSX Mavericks), the editor becomes unresponsive when you click on a multi-line comment (that comments out a valid class/id) in CSS while having the live preview running. I tried replicating the bug without plugins and it still occurs.
The text was updated successfully, but these errors were encountered: