diff --git a/public/js/index.js b/public/js/index.js index 3d2efc0..e49985e 100644 --- a/public/js/index.js +++ b/public/js/index.js @@ -1373,7 +1373,7 @@ socket.on('cursor focus', function (data) { if (data.id != socket.id) buildCursor(data); //force show - var cursor = $('#' + data.id); + var cursor = $('div[data-clientid="' + data.id + '"]'); if (cursor.length > 0) { cursor.stop(true).fadeIn(); } @@ -1400,7 +1400,7 @@ socket.on('cursor blur', function (data) { if (data.id != socket.id) buildCursor(data); //force hide - var cursor = $('#' + data.id); + var cursor = $('div[data-clientid="' + data.id + '"]'); if (cursor.length > 0) { cursor.stop(true).fadeOut(); } @@ -1648,8 +1648,8 @@ function buildCursor(user) { if ($('.other-cursors').length <= 0) { $("