谷歌浏览器扩展 kwift.CHROME.min.js

Mar*_*oss 9 javascript console google-chrome google-chrome-extension

有人可以知道文件调用的 chrome-extension 是什么吗kwift.CHROME.min.js

它正在使用这种链接:

chrome-extension://random_string_here/content/contentScripts/kwift.CHROME.min.js
Run Code Online (Sandbox Code Playgroud)

在我的 Chrome 控制台中,我可以看到数百/数千条以描述开头的日志isElementCoveringWebui

控制台日志示例:

isElementCoveringWebui
div.pcaflag
Run Code Online (Sandbox Code Playgroud)

以及负责显示上述日志的代码:

  t.isWebUIFrameVisible = function (e, t) {
  const a = t.iframe;
  return a && (e => {
    const t = "EDGE" === n.getBrowser() ? ["BODY"] : ["BODY", "HTML"];
    return e.parentElement && t.some(t => t === e.parentElement.tagName)
  }
  )(a) && function () {
    let t;
    try {
      t = e.getCurrentWindow().getComputedStyle(a)
    } catch (e) {
      return !0
    }
    return o(t)
  }() && e.isReallyVisible({
    node: a,
    checkWholeArea: !0
  }) && !function (e, t) {
    const a = e.getCurrentDocument();
    let n = !1;
    const o = a.createTreeWalker(t.parentNode, NodeFilter.SHOW_ELEMENT);
    o.currentNode = t;
    const r = a => {
      console.log("isElementCoveringWebui"),
      console.log(a);
      const n = e.getCurrentWindow().getComputedStyle(a);
      return (() => "none" === n.pointerEvents)() && (() => "2147483647" === n.zIndex)() && (() => {
        const e = a.getBoundingClientRect()
          , n = t.getBoundingClientRect();
        return i.elementsHaveCommonArea(e, n)
      }
      )()
    }
      ;
    for (; o.nextNode() && !n;)
      n = r(o.currentNode);
    return n
  }(e, a)
}
Run Code Online (Sandbox Code Playgroud)

Lou*_*set 8

答案很简单:kwift脚本是 Dashlane.com 浏览器扩展的一部分。