]> source.dussan.org Git - sonarqube.git/commitdiff
NO JIRA Fixing the spotlight when element is insert in the DOM after it render the...
authorMathieu Suen <mathieu.suen@sonarsource.com>
Tue, 18 Jun 2024 09:19:13 +0000 (11:19 +0200)
committersonartech <sonartech@sonarsource.com>
Tue, 18 Jun 2024 20:02:41 +0000 (20:02 +0000)
server/sonar-web/design-system/src/components/SpotlightTour.tsx

index c5be29f5a4871330971b232a6944d420f28cb4f3..a5481d261f092aca451bd3fa0fa6d98469978a0e 100644 (file)
@@ -152,7 +152,15 @@ function TooltipComponent({
         </SpotlightArrowWrapper>
       )}
 
-      <div className="sw-flex sw-justify-between" ref={setRef}>
+      <div
+        className="sw-flex sw-justify-between"
+        ref={(r) => {
+          setRef(r);
+          setTimeout(() => {
+            setTimeStamp(1);
+          }, 100);
+        }}
+      >
         <strong className="sw-body-md-highlight sw-mb-2">{step.title}</strong>
         <WrapperButton
           className="sw-w-[30px] sw-h-[30px] sw--mt-2 sw--mr-2 sw-flex sw-justify-center"