var
/
www
/
html
/
servotec-doerpen
/
wp-includes
/
js
| uid:33
wp-sanitize.js
[X]
/** * @output wp-includes/js/wp-sanitize.js */ /* eslint-env es6 */ ( function () { window.wp = window.wp || {}; /** * wp.sanitize * * Helper functions to sanitize strings. */ wp.sanitize = { /** * Strip HTML tags. * * @param {string} text - Text to strip the HTML tags from. * * @return {string} Stripped text. */ stripTags: function( text ) { if ( 'string' !== typeof text ) { return ''; } const domParser = new DOMParser(); const htmlDocument = domParser.parseFromString( text, 'text/html' ); /* * The following self-assignment appears to be a no-op, but it isn't. * It enforces the escaping. Reading the `innerText` property decodes * character references, returning a raw string. When written, however, * the text is re-escaped to ensure that the rendered text replicates * what it's given. * * See <https://github.com/WordPress/wordpress-develop/pull/10536#discussion_r2550615378>. */ htmlDocument.body.innerText = htmlDocument.body.innerText; // Return the text with stripped tags. return htmlDocument.body.innerHTML; }, /** * Strip HTML tags and convert HTML entities. * * @param {string} text - Text to strip tags and convert HTML entities. * * @return {string} Sanitized text. */ stripTagsAndEncodeText: function( text ) { let _text = wp.sanitize.stripTags( text ), textarea = document.createElement( 'textarea' ); try { textarea.textContent = _text; _text = wp.sanitize.stripTags( textarea.value ); } catch ( er ) {} return _text; } }; }() );
codemirror/
-
O
R
D
crop/
-
O
R
D
dist/
-
O
R
D
imgareaselect/
-
O
R
D
jcrop/
-
O
R
D
jquery/
-
O
R
D
mediaelement/
-
O
R
D
plupload/
-
O
R
D
swfupload/
-
O
R
D
thickbox/
-
O
R
D
tinymce/
-
O
R
D
autosave.min.js
5.7K
V
E
R
D
clipboard.js
26.2K
V
E
R
D
clipboard.min.js
8.8K
V
E
R
D
colorpicker.js
28.4K
V
E
R
D
colorpicker.min.js
16.1K
V
E
R
D
customize-preview-nav-menus.js
14.7K
V
E
R
D
customize-preview-nav-menus.min.js
4.9K
V
E
R
D
heartbeat.js
23.5K
V
E
R
D
heartbeat.min.js
5.8K
V
E
R
D
imagesloaded.min.js
5.4K
V
E
R
D
masonry.min.js
23.6K
V
E
R
D
mce-view.js
25.2K
V
E
R
D
media-audiovideo.js
24.1K
V
E
R
D
media-audiovideo.min.js
11.8K
V
E
R
D
media-grid.js
26.1K
V
E
R
D
media-grid.min.js
13K
V
E
R
D
media-models.min.js
13K
V
E
R
D
media-views.js
266.5K
V
E
R
D
media-views.min.js
108.1K
V
E
R
D
quicktags.js
22.1K
V
E
R
D
quicktags.min.js
10.9K
V
E
R
D
tw-sack.min.js
3.2K
V
E
R
D
twemoji.js
36.3K
V
E
R
D
twemoji.min.js
19.4K
V
E
R
D
underscore.min.js
18.6K
V
E
R
D
wp-ajax-response.js
3.8K
V
E
R
D
wp-ajax-response.min.js
2.5K
V
E
R
D
wp-emoji-loader.js
12.9K
V
E
R
D
wp-emoji-loader.min.js
2.8K
V
E
R
D
wp-emoji-release.min.js
22.2K
V
E
R
D
wp-emoji.js
8.6K
V
E
R
D
wp-emoji.min.js
2.8K
V
E
R
D
wp-list-revisions.js
970
V
E
R
D
wp-list-revisions.min.js
597
V
E
R
D
wp-lists.js
24.7K
V
E
R
D
wp-lists.min.js
7.3K
V
E
R
D
wp-sanitize.js
1.6K
V
E
R
D
wp-util.min.js
1.4K
V
E
R
D
wpdialog.js
569
V
E
R
D
wplink.min.js
11.1K
V
E
R
D
zxcvbn-async.js
821
V
E
R
D
zxcvbn-async.min.js
351
V
E
R
D
zxcvbn.min.js
803K
V
E
R
D