From 98b656c04a3516dbf5d238656ee9d5e8a7034090 Mon Sep 17 00:00:00 2001 From: albinAppsmith <87797149+albinAppsmith@users.noreply.github.com> Date: Thu, 16 May 2024 11:33:13 +0530 Subject: [PATCH] fix: Peek overlay position flickering issue (#33499) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Description https://theappsmith.slack.com/archives/C0134BAVDB4/p1715768117676669 ![image](https://github.com/appsmithorg/appsmith/assets/7846888/a5deedfc-94d8-4904-9045-3122efebb71a) Fixes #33498 ## Automation /ok-to-test tags="@tag.All" ### :mag: Cypress test results > [!TIP] > 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉 > Workflow run: > Commit: 001db2594c4b70a19249699b5839a615785ae59c > Cypress dashboard url: Click here! ## Communication Should the DevRel and Marketing teams inform users about this change? - [ ] Yes - [x] No --- app/client/src/components/editorComponents/CodeEditor/index.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/client/src/components/editorComponents/CodeEditor/index.tsx b/app/client/src/components/editorComponents/CodeEditor/index.tsx index b4463eb600..2423bca9bb 100644 --- a/app/client/src/components/editorComponents/CodeEditor/index.tsx +++ b/app/client/src/components/editorComponents/CodeEditor/index.tsx @@ -818,7 +818,9 @@ class CodeEditor extends Component { handleMouseOver = (event: MouseEvent) => { const tokenElement = event.target; + const rect = (tokenElement as Element).getBoundingClientRect(); if ( + !(rect.height === 0 && rect.width === 0) && tokenElement instanceof Element && this.isPeekableElement(tokenElement) ) {