4

这是我在 jsfiddle 中的示例,将鼠标悬停在 Minnesota 上以查看 qtip 弹出窗口。我正在使用 qTip jquery 插件,我一直坚持让 qtip 停留足够长的时间,以便有人单击工具提示上的链接。我已经尝试了各种场景以使其保持开放。阅读文档似乎很容易,但我尝试了这些但没有运气。我试过这些

hide: { when: 'mouseout', fixed: true }

hide: { fixed: true, delay: 1000 }

和许多其他人,没有什么可以保持工具提示,以便用户可以点击链接。令人恼火的是参考页面上的内容。如果您单击任何示例链接,他们正在做我想做的事,我去了源头,如果他们似乎正在使用

  hide: 'unfocus',

     hide: {
        fixed: true,
        delay: 240
     },

但我都试过了,工具提示不会保持打开状态。我错过了什么吗?

4

2 回答 2

7

由于您的提示位置似乎偏右,请尝试以下操作:

  $(this).qtip(
  {
      hide:{ //moved hide to here,
        delay:500, //give a small delay to allow the user to mouse over it.
        fixed:true
      },
     content: $("." + test).html(),
     style: {
        name: 'dark',
         style: {
            border: 1,
            cursor: 'pointer',
            padding: '5px 8px',
            name: 'blue'
         },
        border: {}, 
        tip: true // Apply a tip at the default tooltip corner
     }
  });

更新了小提琴

于 2011-03-28T13:49:57.723 回答
1

您的代码中有 2 种样式,而且各式各样。这是你的代码,工作。

http://jsfiddle.net/JDVTM/

于 2011-03-28T13:52:30.143 回答