jquery css 类Compass修正

标签 jquery frameworks css compass-sass

当您使用 css 方法时,jQuery 具有不透明度校正功能(jQuery 1.4.2 上的第 4592-4608 行):

    // IE uses filters for opacity
    if ( !jQuery.support.opacity && name === "opacity" ) {
        if ( set ) {
            // IE has trouble with opacity if it does not have layout
            // Force it by setting the zoom level
            style.zoom = 1;

            // Set the alpha filter to set the opacity
            var opacity = parseInt( value, 10 ) + "" === "NaN" ? "" : "alpha(opacity=" + value * 100 + ")";
            var filter = style.filter || jQuery.curCSS( elem, "filter" ) || "";
            style.filter = ralpha.test(filter) ? filter.replace(ralpha, opacity) : opacity;
        }

        return style.filter && style.filter.indexOf("opacity=") >= 0 ?
            (parseFloat( ropacity.exec(style.filter)[1] ) / 100) + "":
            "";
    }

我已经开始扩展此行为,使 css 3 选择器与多浏览器兼容(使用 Compass framework implements 的很多方法)。

是否有元素已经这样做了?

最佳答案

有各种元素涵盖 CSS3 的不同方面。据我所知,没有像样的统一元素。

我目前正在使用: http://plugins.jquery.com/project/2d-transform

用于 CSS3 转换。我现在不太愿意推荐其他元素。

还有: http://plugins.jquery.com/project/corners

关于jquery css 类Compass修正,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3580746/

相关文章:

javascript - 搜索词突出显示代码无法正常工作

java - 指向 Java 中的用户配置文件框架的指针

iPhone 模拟器 vs iPhone OS 测试 : file is not of required architecture

node.js - Strapi 适合服务 html 还是用作传统的 mvc Web 框架?

jQuery animate() 使用 keydown 进行平滑

jquery - 使用jquery获取两个日期之间的差异

javascript - ckeditor 未加载通过 ajax 调用生成的元素?

jquery - jQuery 选项卡中的相同高度 li

css - 将 div 限制在浏览器窗口的底部

html - 图像不在较大的卡片 div 中居中