【问题标题】:Does cluetip work on a link at the top right of a page?提示提示是否适用于页面右上角的链接?
【发布时间】:2012-03-22 19:17:51
【问题描述】:

我正在使用 jquery 线索提示,并且我在页面的右上角有一个链接,当我单击它时,我希望工具提示显示在我单击的底部,但它显示在屏幕中间或屏幕顶部。这是我的代码:

$('#personName').cluetip({
    width: '500px',
    showTitle: false,
    topOffset: 25,
    leftOffset: 5,
    positionBy: 'bottomTop',
    cluetipClass: 'jtip',
    activation: 'click',
    closeText: '<img src="/Content/Images/Icons/cross.png" alt="close" />Close',
    hoverIntent: {
        sensitivity: 7,
        interval: 100,
        timeout: 500
    },
    sticky: true,
    mouseOutClose: true,
    ajaxSettings: {
        dataType: 'json'
    },
    ajaxProcess: function (data) {

        var html = [];
        html.push(data.Person.Name);
        return html.join("");
    }
});

我尝试将 positionBy 更改为“auto”或“mouse”,但它仍然不起作用。 .提示提示根本不处理屏幕右侧的链接吗?

【问题讨论】:

    标签: jquery cluetip


    【解决方案1】:

    当尺寸不适合屏幕时,提示提示似乎无法处理右侧的链接。

    我尝试将positionBy: 'mouse'leftOffsettopOffset 一起使用,并让它稍微出现在链接的左侧底部。查看http://jsfiddle.net/neo108/9CV6t/ 中的第二个div

    希望对您有所帮助。

    也许您可以使用左侧和顶部偏移并根据需要定位它。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-11-10
      • 2018-11-18
      • 1970-01-01
      • 1970-01-01
      • 2015-09-25
      • 1970-01-01
      相关资源
      最近更新 更多