$(function() {
  $.ajax({
    url: "https://nugoo.me/people/names/",
    success: function(data) {
      var names = data.data;

      // highlight all the names in names
      for (var i = 0; i < names.length; ++i) {
        var selector = "body :contains('" + names[i] + "')";

        $(selector).each(function(_, element) {
          $(element).html(function(_, oldHtml) {
            var regexp = new RegExp("(>[^<]*)" + names[i], "gmu"),
                span = '<span class="nugoo nugoo-' + i + '">' + names[i] + '</span>';
            return oldHtml.replace(regexp, "$1" + span);
          });
        });

        $(".nugoo-" + i).tooltip({
          items: ".nugoo-" + i,
          content: '<iframe src="https://nugoo.me/p/' + names[i] + '/" width="400" height="224" style="border: none;"></iframe>',
          classes: {"ui-tooltip": "nugoo-tooltip"}
        });
      }
    }
  });
});

@@ -120,16 +120,36 @@
 ta.data;
+%0A      var flag = 0;
 %0A%0A      
@@ -625,16 +625,151 @@
      %7D);
+%0A        %0A        console.log(%22Start flag :%22 + flag);%0A        %0A        var nugooclass = %22.nugoo-%22+i;%0A        var $elem = $(nugooclass);
 %0A%0A      
@@ -1010,16 +1010,16 @@
 oltip%22%7D%0A
-
         
@@ -1018,24 +1018,871 @@
         %7D);%0A
+        %0A        $elem.on(%22mouseenter%22, function (e) %7B%0A            console.log(%22Before : %22 + flag);%0A            if (flag == 0) %7B%0A                e.stopImmediatePropagation();%0A                $(this).tooltip(%22open%22);%0A                flag = 1%0A                console.log(%22After : %22 + flag);%0A            %7D else %7B%0A                $(this).tooltip(%22disable%22);%0A            %7D%0A        %7D);%0A        %0A        $elem.on(%22mouseleave%22, function (e) %7B%0A            e.stopImmediatePropagation();%0A        %7D);%0A        %0A        $(document).mouseup(function (e) %7B%0A            var container = $(%22.ui-tooltip%22);%0A            if (! container.is(e.target) && %0A                container.has(e.target).length === 0)%0A            %7B%0A                $elem.tooltip(%22close%22);%0A                flag = 0;%0A                console.log(%22Now : %22 + flag);%0A            %7D%0A        %7D);%0A        %0A
       %7D%0A    

Modify script