WordPress/wp-includes/js/wp-sanitize.min.js
desrosj ec8147c8dd Build/Test Tools: Backport GitHub Action and build improvements to the 5.1 branch.
This backports several build and test tool improvements to the 5.1 branch. Most notably, this includes:

- The changes required to allow each workflow to be triggered by the `workflow_dispatch` event so that tests can be run on a schedule [50590].
- Splitting single site and multisite tests into parallel jobs [50379].
- Split slow tests into separate, parallel jobs for PHP <= 5.6 [50444].
- Better branch and path scoping for GitHub Action workflows when running on `pull_request` [50432,50479].
- Several `devDependency` updates.

Merges [45317,50267,50379,50387,50413,50416,50432,50435-50436,50444,50446,50473-50474,50476,50479,50485-50487,50545,50579,50590,50598] to the 5.1 branch.
See #50401, #51801, #51802, #52548, #52608, #52612, #52624, #52625, #52645, #52653, #52658, #52660, #52667.
Built from https://develop.svn.wordpress.org/branches/5.1@50622


git-svn-id: http://core.svn.wordpress.org/branches/5.1@50235 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-03-31 19:21:47 +00:00

1 line
381 B
JavaScript

window.wp=window.wp||{},wp.sanitize={stripTags:function(e){return(e=e||"").replace(/<!--[\s\S]*?(-->|$)/g,"").replace(/<(script|style)[^>]*>[\s\S]*?(<\/\1>|$)/gi,"").replace(/<\/?[a-z][\s\S]*?(>|$)/gi,"")},stripTagsAndEncodeText:function(e){var t=wp.sanitize.stripTags(e),e=document.createElement("textarea");try{e.innerHTML=t,t=wp.sanitize.stripTags(e.value)}catch(e){}return t}};