mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-08 11:50:03 +01:00
0e21d32900
This upgrades a number of devDependencies. Some of these include changes to how the tasks are configured. Uglify: There are deprecated options from 2.x to 4.x, see: https://github.com/gruntjs/grunt-contrib-uglify#options Autoprefixer: Browserslist now warns when passing in the browser list, so that is put into package.json As with most changes to uglify, this changes every minified JS file. Fixes #48203. Built from https://develop.svn.wordpress.org/trunk@46408 git-svn-id: http://core.svn.wordpress.org/trunk@46206 1a063a9b-81f0-0310-95a4-ce76da25c4cd
1 line
1.5 KiB
JavaScript
1 line
1.5 KiB
JavaScript
!function(r){r.PluginManager.add("wpemoji",function(n){var t,e,o=window.wp,i=window._wpemojiSettings,a=r.Env,w=window.navigator.userAgent,d=-1<w.indexOf("Windows"),c=!!((e=w.match(/Windows NT 6\.(\d)/))&&1<e[1]);function m(e){o.emoji.parse(e,{imgAttr:{"data-mce-resize":"false","data-mce-placeholder":"1","data-wp-emoji":"1"}})}function s(e){var t,o;e&&window.twemoji&&window.twemoji.test(e.textContent||e.innerText)&&(a.webkit&&(o=(t=n.selection).getBookmark()),m(e),a.webkit&&t.moveToBookmark(o))}o&&o.emoji&&!i.supports.everything&&(c?n.on("keyup",function(e){231===e.keyCode&&s(n.selection.getNode())}):d||(n.on("keydown keyup",function(e){t="keydown"===e.type}),n.on("input",function(){t||s(n.selection.getNode())})),n.on("setcontent",function(e){var t=n.selection,o=t.getNode();window.twemoji&&window.twemoji.test(o.textContent||o.innerText)&&(m(o),a.ie&&a.ie<9&&e.load&&o&&"BODY"===o.nodeName&&t.collapse(!0))}),n.on("PastePostProcess",function(e){window.twemoji&&r.each(n.dom.$("img.emoji",e.node),function(e){e.alt&&window.twemoji.test(e.alt)&&function(e){e.className="emoji",e.setAttribute("data-mce-resize","false"),e.setAttribute("data-mce-placeholder","1"),e.setAttribute("data-wp-emoji","1")}(e)})}),n.on("postprocess",function(e){e.content&&(e.content=e.content.replace(/<img[^>]+data-wp-emoji="[^>]+>/g,function(e){var t=e.match(/alt="([^"]+)"/);return t&&t[1]?t[1]:e}))}),n.on("resolvename",function(e){"IMG"===e.target.nodeName&&n.dom.getAttrib(e.target,"data-wp-emoji")&&e.preventDefault()}))})}(window.tinymce); |