在Chrome扩展中有面板行为 [英] Having panel behavior in chrome extension

查看:85
本文介绍了在Chrome扩展中有面板行为的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要在chrome中设置面板行为:始终位于顶部的东西,但不会影响导航(除掩蔽几个像素之外的任何其他方式)。

我们目前有两种选择:面板模式下的窗口:尚未发布(尽管现在可用于 a href =https://chrome.google.com/webstore/detail/nckgahadagoaajjgafhacjanaoiihapd> GTalk扩展)。

  • 模式:通过重新聚焦每个事件,我可以始终保持最佳状态,但是焦点会针对我的窗口(并损害导航)。




  • 我正在寻找:


    • GTalk的黑暗魔法


    • 一种使弹出窗口保持顶部(或顶部并将焦点放在第二个顶部窗口)的方法

    • ul>

      解决方案

      我发现GTalk是面板的唯一扩展。您可以在自己的扩展中使用面板,使用真正的黑魔法:



      在您的manifest.json中,添加键值对:



      'pre> 键: MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDsDApubb73tPfYlNIFxDu3K3 / EHgV6 / YOJXJkld1OZ20jW / cOht1j0NggnXhQYuu1mXFUufud4I2N7b5ydyg09gcM9Va3Zk17RhNV9smbPHOd4XlzJeXifX / 9MgHPu4FzCen3CiSXsOeAELJIXEuT28xICriuUko / rNPwGeIB9VwIDAQAB

      和BOOM,面板激活!

      这是Google激活隐藏功能的方式。 文档告诉我们关键的目的是提供独特的标识符,但我们并不需要它。如所证明的那样,它还激活隐藏的特征。

      另外,你不能有两个具有相同键值的扩展名(GTalk被卸载)。我认为你的扩展可能不会让它进入Chrome商店。



      如果你认识Google的某个人,请告诉他们,我们的凡人真的很想拥有面板。面板非常棒。它们是在网页顶部显示信息并同时与之互动的唯一方式。 Google应该分享这份爱,我们真的需要面板。

      I need to have panel behavior in chrome: something always on top but that does not impair the navigation (in any other way than masking a few pixels).

      We have two options at the moment:

      • window in panel mode: not available yet (although it is available now to the GTalk extension).

      • window in popup mode: I can make it be always on top by refocusing at every event, however the focus will get targeted at my window (and impair the navigation)

      I'm looking for either:

      • GTalk's dark magic

      • A way to make a popup window stay on top (or come on top and relinquish the focus to the second topmost window)

      解决方案

      I found how GTalk is the only extension with panels. You can have panels too in your own extension, using really dark magic:

      In your manifest.json, add the key-value pair:

      "key": "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDsDApubb73tPfYlNIFxDu3K3/EHgV6/YOJXJkld1OZ20jW/cOht1j0NggnXhQYuu1mXFUufud4I2N7b5ydyg09gcM9Va3Zk17RhNV9smbPHOd4XlzJeXifX/9MgHPu4FzCen3CiSXsOeAELJIXEuT28xICriuUko/rNPwGeIB9VwIDAQAB"
      

      And BOOM, panels activated!

      This is Google's way of activating a hidden feature. The documentation tells us "key"'s purpose is to provide a unique identifier but that we don't really need it. As demonstrated, it also activates hidden features.

      Also, you cannot have two extensions with the same "key" value (GTalk gets uninstalled). And I think your extension might not make it to the chrome store.

      If you know someone at Google, please tell them we mortals would really really love to have panels too. Panels are awesome. And they are the only way to display information on top of a web page while still interacting with it. Google should share the love, we really need panels.

      这篇关于在Chrome扩展中有面板行为的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

    查看全文
    登录 关闭
    扫码关注1秒登录
    发送“验证码”获取 | 15天全站免登陆