--- a/wp/wp-includes/js/dist/wordcount.js Tue Oct 22 16:11:46 2019 +0200
+++ b/wp/wp-includes/js/dist/wordcount.js Tue Dec 15 13:49:49 2020 +0100
@@ -82,7 +82,7 @@
/******/
/******/
/******/ // Load entry module and return exports
-/******/ return __webpack_require__(__webpack_require__.s = 365);
+/******/ return __webpack_require__(__webpack_require__.s = 450);
/******/ })
/************************************************************************/
/******/ ({
@@ -94,14 +94,18 @@
/***/ }),
-/***/ 365:
+/***/ 450:
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
+// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);
-// EXTERNAL MODULE: external "lodash"
-var external_lodash_ = __webpack_require__(2);
+// EXPORTS
+__webpack_require__.d(__webpack_exports__, "count", function() { return /* binding */ count; });
+
+// EXTERNAL MODULE: external {"this":"lodash"}
+var external_this_lodash_ = __webpack_require__(2);
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/defaultSettings.js
var defaultSettings = {
@@ -175,11 +179,11 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var stripTags = (function (settings, text) {
+function stripTags(settings, text) {
if (settings.HTMLRegExp) {
return text.replace(settings.HTMLRegExp, '\n');
}
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/transposeAstralsToCountableChar.js
/**
@@ -190,13 +194,13 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var transposeAstralsToCountableChar = (function (settings, text) {
+function transposeAstralsToCountableChar(settings, text) {
if (settings.astralRegExp) {
return text.replace(settings.astralRegExp, 'a');
}
return text;
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/stripHTMLEntities.js
/**
@@ -207,13 +211,13 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var stripHTMLEntities = (function (settings, text) {
+function stripHTMLEntities(settings, text) {
if (settings.HTMLEntityRegExp) {
return text.replace(settings.HTMLEntityRegExp, '');
}
return text;
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/stripConnectors.js
/**
@@ -224,13 +228,13 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var stripConnectors = (function (settings, text) {
+function stripConnectors(settings, text) {
if (settings.connectorRegExp) {
return text.replace(settings.connectorRegExp, ' ');
}
return text;
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/stripRemovables.js
/**
@@ -241,13 +245,13 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var stripRemovables = (function (settings, text) {
+function stripRemovables(settings, text) {
if (settings.removeRegExp) {
return text.replace(settings.removeRegExp, '');
}
return text;
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/stripHTMLComments.js
/**
@@ -258,13 +262,13 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var stripHTMLComments = (function (settings, text) {
+function stripHTMLComments(settings, text) {
if (settings.HTMLcommentRegExp) {
return text.replace(settings.HTMLcommentRegExp, '');
}
return text;
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/stripShortcodes.js
/**
@@ -275,13 +279,13 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var stripShortcodes = (function (settings, text) {
+function stripShortcodes(settings, text) {
if (settings.shortcodesRegExp) {
return text.replace(settings.shortcodesRegExp, '\n');
}
return text;
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/stripSpaces.js
/**
@@ -292,11 +296,11 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var stripSpaces = (function (settings, text) {
+function stripSpaces(settings, text) {
if (settings.spaceRegExp) {
return text.replace(settings.spaceRegExp, ' ');
}
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/transposeHTMLEntitiesToCountableChars.js
/**
@@ -307,16 +311,15 @@
*
* @return {string} The manipulated text.
*/
-/* harmony default export */ var transposeHTMLEntitiesToCountableChars = (function (settings, text) {
+function transposeHTMLEntitiesToCountableChars(settings, text) {
if (settings.HTMLEntityRegExp) {
return text.replace(settings.HTMLEntityRegExp, 'a');
}
return text;
-});
+}
// CONCATENATED MODULE: ./node_modules/@wordpress/wordcount/build-module/index.js
-/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "count", function() { return count; });
/**
* External dependencies
*/
@@ -345,7 +348,7 @@
*/
function loadSettings(type, userSettings) {
- var settings = Object(external_lodash_["extend"])(defaultSettings, userSettings);
+ var settings = Object(external_this_lodash_["extend"])(defaultSettings, userSettings);
settings.shortcodes = settings.l10n.shortcodes || {};
if (settings.shortcodes && settings.shortcodes.length) {
@@ -372,7 +375,7 @@
function matchWords(text, regex, settings) {
- text = Object(external_lodash_["flow"])(stripTags.bind(this, settings), stripHTMLComments.bind(this, settings), stripShortcodes.bind(this, settings), stripSpaces.bind(this, settings), stripHTMLEntities.bind(this, settings), stripConnectors.bind(this, settings), stripRemovables.bind(this, settings))(text);
+ text = Object(external_this_lodash_["flow"])(stripTags.bind(this, settings), stripHTMLComments.bind(this, settings), stripShortcodes.bind(this, settings), stripSpaces.bind(this, settings), stripHTMLEntities.bind(this, settings), stripConnectors.bind(this, settings), stripRemovables.bind(this, settings))(text);
text = text + '\n';
return text.match(regex);
}
@@ -388,15 +391,15 @@
function matchCharacters(text, regex, settings) {
- text = Object(external_lodash_["flow"])(stripTags.bind(this, settings), stripHTMLComments.bind(this, settings), stripShortcodes.bind(this, settings), stripSpaces.bind(this, settings), transposeAstralsToCountableChar.bind(this, settings), transposeHTMLEntitiesToCountableChars.bind(this, settings))(text);
+ text = Object(external_this_lodash_["flow"])(stripTags.bind(this, settings), stripHTMLComments.bind(this, settings), stripShortcodes.bind(this, settings), stripSpaces.bind(this, settings), transposeAstralsToCountableChar.bind(this, settings), transposeHTMLEntitiesToCountableChars.bind(this, settings))(text);
text = text + '\n';
return text.match(regex);
}
/**
* Count some words.
*
- * @param {String} text The text being processed
- * @param {String} type The type of count. Accepts ;words', 'characters_excluding_spaces', or 'characters_including_spaces'.
+ * @param {string} text The text being processed
+ * @param {string} type The type of count. Accepts ;words', 'characters_excluding_spaces', or 'characters_including_spaces'.
* @param {Object} userSettings Custom settings object.
*
* @example
@@ -405,7 +408,7 @@
* const numberOfWords = count( 'Words to count', 'words', {} )
* ```
*
- * @return {Number} The word or character count.
+ * @return {number} The word or character count.
*/