@bigbinary/neeto-editor 1.28.11 → 1.28.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs.js +5 -3
- package/index.cjs.js.map +1 -1
- package/index.js +5 -3
- package/index.js.map +1 -1
- package/package.json +8 -8
package/index.cjs.js
CHANGED
|
@@ -15,6 +15,7 @@ var reactUtils = require('@bigbinary/neeto-commons-frontend/react-utils');
|
|
|
15
15
|
var CopyToClipboardButton = require('@bigbinary/neeto-molecules/CopyToClipboardButton');
|
|
16
16
|
var DynamicVariables = require('@bigbinary/neeto-molecules/DynamicVariables');
|
|
17
17
|
var formik = require('formik');
|
|
18
|
+
var client = require('react-dom/client');
|
|
18
19
|
|
|
19
20
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
20
21
|
|
|
@@ -6547,7 +6548,7 @@ var DIRECT_UPLOAD_ENDPOINT = "/api/direct_uploads";
|
|
|
6547
6548
|
var URL_REGEXP = /[(http(s)?)://(www.)?a-zA-Z0-9@:%._+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_+.~#?&//=]*)/;
|
|
6548
6549
|
var YOUTUBE_URL_REGEXP = /^((?:https?:)?\/\/)?((?:www|m)\.)?((?:youtube\.com|youtu.be))(\/(?:[\w-]+\?v=|embed\/|v\/)?)([\w-]+)(\S+)?$/;
|
|
6549
6550
|
var VIMEO_URL_REGEXP = /((?:http|https):\/\/)?(www\.|player\.)?vimeo\.com\/(?:channels\/(?:\w+\/)?|groups\/([^/]*)\/videos\/|(?:manage\/)?videos?\/|)(\d+)(?:(?:\/|\?h=)(\w+))?(?:|\/\?)/;
|
|
6550
|
-
var LOOM_URL_REGEXP = /((?:http|https):\/\/)?(www\.)?loom\.com\/(share|embed)\/((
|
|
6551
|
+
var LOOM_URL_REGEXP = /((?:http|https):\/\/)?(www\.)?loom\.com\/(share|embed)\/([a-f0-9]{32})(?:\?sid=([a-f0-9-]{36}))?(?:\?t=(\d+))?/;
|
|
6551
6552
|
var COMBINED_REGEX = new RegExp(ramda.pluck("source", [YOUTUBE_URL_REGEXP, VIMEO_URL_REGEXP, LOOM_URL_REGEXP]).join("|"), "g");
|
|
6552
6553
|
|
|
6553
6554
|
var DEFAULT_EDITOR_OPTIONS = [EDITOR_OPTIONS.BOLD, EDITOR_OPTIONS.ITALIC, EDITOR_OPTIONS.UNDERLINE, EDITOR_OPTIONS.STRIKETHROUGH, EDITOR_OPTIONS.LINK, EDITOR_OPTIONS.PARAGRAPH, EDITOR_OPTIONS.H1, EDITOR_OPTIONS.H2, EDITOR_OPTIONS.LIST_BULLETS, EDITOR_OPTIONS.LIST_ORDERED, EDITOR_OPTIONS.CODE];
|
|
@@ -98707,11 +98708,12 @@ var EditorContent = function EditorContent(_ref) {
|
|
|
98707
98708
|
preTags.forEach(function (preTag) {
|
|
98708
98709
|
var button = document.createElement("div");
|
|
98709
98710
|
button.className = "neeto-editor-codeblock-options";
|
|
98710
|
-
|
|
98711
|
+
var root = client.createRoot(button);
|
|
98712
|
+
root.render( /*#__PURE__*/React__default["default"].createElement(CopyToClipboardButton__default["default"], {
|
|
98711
98713
|
size: "small",
|
|
98712
98714
|
style: "text",
|
|
98713
98715
|
value: preTag.textContent
|
|
98714
|
-
})
|
|
98716
|
+
}));
|
|
98715
98717
|
preTag.appendChild(button);
|
|
98716
98718
|
});
|
|
98717
98719
|
};
|