Desaturating a color image couldn’t be simpler with CSS3. We’ll apply the filter as a class, as you’d typically desire several images to be affected by the code at the same time:
img.desaturate { filter: grayscale(100%); }
Naturally, all current browsers implement CSS3 filters via vendor prefixes, so our first job is to insert that code, writing in CSS that does not yet exist in order to future-proof our work:
img.desaturate { filter: grayscale(100%);
-webkit-filter: grayscale(100%);
-moz-filter: grayscale(100%);
filter: grayscale(100%);
}
Applying the class to the image is easy:
经由过程数据深化理解IT工具各类及时与汗青运转情况,实时发……
2018年6月30日,中国IT效劳立异大会在京召开,北塔软件气力产物……
继推出聪慧医疗运维处理计划后不久,为更好地助力医疗行业用……
中国电子港口是国度收支口同一信息平台,怎样追求其在IT运维……
克日,各媒体纷繁报导北塔软件喜获科技型中小企业手艺立异基……
北塔软件快讯:12月15日,SEI(卡内基-梅龙软件工程研讨所)经……