alphardex
V2EX  ›  问与答

chrome 插件开发:如何让插件弹窗 popup 持续悬浮在某个特定的网站上

  •  
  •   alphardex · Aug 6, 2020 · 2884 views
    This topic created in 2119 days ago, the information mentioned may be changed or developed.

    查阅过很多答案,都是新建一个 popup 的 tab 。那有没有办法把它悬浮在页面的某个位置呢,就像 iframe 一样?

    3 replies    2020-08-06 12:44:56 +08:00
    ooh
        1
    ooh  
       Aug 6, 2020
    翻译插件就是想浮动在哪就哪吗
    div + css 想飘哪不行?
    alphardex
        2
    alphardex  
    OP
       Aug 6, 2020
    @ooh 这个用 content-scripts 确实可以做到,但这样就无法使用浏览器相关的 API 了
    ooh
        3
    ooh  
       Aug 6, 2020
    @alphardex 比如?你这个特定网站浮窗是可以的
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1413 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 17:02 · PVG 01:02 · LAX 10:02 · JFK 13:02
    ♥ Do have faith in what you're doing.