"use strict";
/*
 * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
 * This devtool is neither made for production nor for readable output files.
 * It uses "eval()" calls to create a separate source file in the browser devtools.
 * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
 * or disable the default devtool with "devtool: false".
 * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
 */
(self["webpackChunkwoocommerce_rtm_custom_emails"] = self["webpackChunkwoocommerce_rtm_custom_emails"] || []).push([["defaultVendors-1011~1013-91d5ce2f87409aae21f5036b7dbafdab-index.js"],{

/***/ 71167:
/*!***********************************************!*\
  !*** ./node_modules/react-quill/lib/index.js ***!
  \***********************************************/
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {

eval("\n/*\nReact-Quill\nhttps://github.com/zenoamaro/react-quill\n*/\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nvar __spreadArrays = (this && this.__spreadArrays) || function () {\n    for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\n    for (var r = Array(s), k = 0, i = 0; i < il; i++)\n        for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\n            r[k] = a[j];\n    return r;\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n    return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nvar react_1 = __importDefault(__webpack_require__(/*! react */ 99196));\nvar react_dom_1 = __importDefault(__webpack_require__(/*! react-dom */ 91850));\nvar isEqual_1 = __importDefault(__webpack_require__(/*! lodash/isEqual */ 18446));\nvar quill_1 = __importDefault(__webpack_require__(/*! quill */ 76095));\nvar ReactQuill = /** @class */ (function (_super) {\n    __extends(ReactQuill, _super);\n    function ReactQuill(props) {\n        var _this = _super.call(this, props) || this;\n        /*\n        Changing one of these props should cause a full re-render and a\n        re-instantiation of the Quill editor.\n        */\n        _this.dirtyProps = [\n            'modules',\n            'formats',\n            'bounds',\n            'theme',\n            'children',\n        ];\n        /*\n        Changing one of these props should cause a regular update. These are mostly\n        props that act on the container, rather than the quillized editing area.\n        */\n        _this.cleanProps = [\n            'id',\n            'className',\n            'style',\n            'placeholder',\n            'tabIndex',\n            'onChange',\n            'onChangeSelection',\n            'onFocus',\n            'onBlur',\n            'onKeyPress',\n            'onKeyDown',\n            'onKeyUp',\n        ];\n        _this.state = {\n            generation: 0,\n        };\n        /*\n        Tracks the internal selection of the Quill editor\n        */\n        _this.selection = null;\n        _this.onEditorChange = function (eventName, rangeOrDelta, oldRangeOrDelta, source) {\n            var _a, _b, _c, _d;\n            if (eventName === 'text-change') {\n                (_b = (_a = _this).onEditorChangeText) === null || _b === void 0 ? void 0 : _b.call(_a, _this.editor.root.innerHTML, rangeOrDelta, source, _this.unprivilegedEditor);\n            }\n            else if (eventName === 'selection-change') {\n                (_d = (_c = _this).onEditorChangeSelection) === null || _d === void 0 ? void 0 : _d.call(_c, rangeOrDelta, source, _this.unprivilegedEditor);\n            }\n        };\n        var value = _this.isControlled() ? props.value : props.defaultValue;\n        _this.value = (value !== null && value !== void 0 ? value : '');\n        return _this;\n    }\n    ReactQuill.prototype.validateProps = function (props) {\n        var _a;\n        if (react_1.default.Children.count(props.children) > 1)\n            throw new Error('The Quill editing area can only be composed of a single React element.');\n        if (react_1.default.Children.count(props.children)) {\n            var child = react_1.default.Children.only(props.children);\n            if (((_a = child) === null || _a === void 0 ? void 0 : _a.type) === 'textarea')\n                throw new Error('Quill does not support editing on a <textarea>. Use a <div> instead.');\n        }\n        if (this.lastDeltaChangeSet &&\n            props.value === this.lastDeltaChangeSet)\n            throw new Error('You are passing the `delta` object from the `onChange` event back ' +\n                'as `value`. You most probably want `editor.getContents()` instead. ' +\n                'See: https://github.com/zenoamaro/react-quill#using-deltas');\n    };\n    ReactQuill.prototype.shouldComponentUpdate = function (nextProps, nextState) {\n        var _this = this;\n        var _a;\n        this.validateProps(nextProps);\n        // If the editor hasn't been instantiated yet, or the component has been\n        // regenerated, we already know we should update.\n        if (!this.editor || this.state.generation !== nextState.generation) {\n            return true;\n        }\n        // Handle value changes in-place\n        if ('value' in nextProps) {\n            var prevContents = this.getEditorContents();\n            var nextContents = (_a = nextProps.value, (_a !== null && _a !== void 0 ? _a : ''));\n            // NOTE: Seeing that Quill is missing a way to prevent edits, we have to\n            //       settle for a hybrid between controlled and uncontrolled mode. We\n            //       can't prevent the change, but we'll still override content\n            //       whenever `value` differs from current state.\n            // NOTE: Comparing an HTML string and a Quill Delta will always trigger a\n            //       change, regardless of whether they represent the same document.\n            if (!this.isEqualValue(nextContents, prevContents)) {\n                this.setEditorContents(this.editor, nextContents);\n            }\n        }\n        // Handle read-only changes in-place\n        if (nextProps.readOnly !== this.props.readOnly) {\n            this.setEditorReadOnly(this.editor, nextProps.readOnly);\n        }\n        // Clean and Dirty props require a render\n        return __spreadArrays(this.cleanProps, this.dirtyProps).some(function (prop) {\n            return !isEqual_1.default(nextProps[prop], _this.props[prop]);\n        });\n    };\n    ReactQuill.prototype.shouldComponentRegenerate = function (nextProps) {\n        var _this = this;\n        // Whenever a `dirtyProp` changes, the editor needs reinstantiation.\n        return this.dirtyProps.some(function (prop) {\n            return !isEqual_1.default(nextProps[prop], _this.props[prop]);\n        });\n    };\n    ReactQuill.prototype.componentDidMount = function () {\n        this.instantiateEditor();\n        this.setEditorContents(this.editor, this.getEditorContents());\n    };\n    ReactQuill.prototype.componentWillUnmount = function () {\n        this.destroyEditor();\n    };\n    ReactQuill.prototype.componentDidUpdate = function (prevProps, prevState) {\n        var _this = this;\n        // If we're changing one of the `dirtyProps`, the entire Quill Editor needs\n        // to be re-instantiated. Regenerating the editor will cause the whole tree,\n        // including the container, to be cleaned up and re-rendered from scratch.\n        // Store the contents so they can be restored later.\n        if (this.editor && this.shouldComponentRegenerate(prevProps)) {\n            var delta = this.editor.getContents();\n            var selection = this.editor.getSelection();\n            this.regenerationSnapshot = { delta: delta, selection: selection };\n            this.setState({ generation: this.state.generation + 1 });\n            this.destroyEditor();\n        }\n        // The component has been regenerated, so it must be re-instantiated, and\n        // its content must be restored to the previous values from the snapshot.\n        if (this.state.generation !== prevState.generation) {\n            var _a = this.regenerationSnapshot, delta = _a.delta, selection_1 = _a.selection;\n            delete this.regenerationSnapshot;\n            this.instantiateEditor();\n            var editor_1 = this.editor;\n            editor_1.setContents(delta);\n            postpone(function () { return _this.setEditorSelection(editor_1, selection_1); });\n        }\n    };\n    ReactQuill.prototype.instantiateEditor = function () {\n        if (this.editor) {\n            this.hookEditor(this.editor);\n        }\n        else {\n            this.editor = this.createEditor(this.getEditingArea(), this.getEditorConfig());\n        }\n    };\n    ReactQuill.prototype.destroyEditor = function () {\n        if (!this.editor)\n            return;\n        this.unhookEditor(this.editor);\n    };\n    /*\n    We consider the component to be controlled if `value` is being sent in props.\n    */\n    ReactQuill.prototype.isControlled = function () {\n        return 'value' in this.props;\n    };\n    ReactQuill.prototype.getEditorConfig = function () {\n        return {\n            bounds: this.props.bounds,\n            formats: this.props.formats,\n            modules: this.props.modules,\n            placeholder: this.props.placeholder,\n            readOnly: this.props.readOnly,\n            scrollingContainer: this.props.scrollingContainer,\n            tabIndex: this.props.tabIndex,\n            theme: this.props.theme,\n        };\n    };\n    ReactQuill.prototype.getEditor = function () {\n        if (!this.editor)\n            throw new Error('Accessing non-instantiated editor');\n        return this.editor;\n    };\n    /**\n    Creates an editor on the given element. The editor will be passed the\n    configuration, have its events bound,\n    */\n    ReactQuill.prototype.createEditor = function (element, config) {\n        var editor = new quill_1.default(element, config);\n        if (config.tabIndex != null) {\n            this.setEditorTabIndex(editor, config.tabIndex);\n        }\n        this.hookEditor(editor);\n        return editor;\n    };\n    ReactQuill.prototype.hookEditor = function (editor) {\n        // Expose the editor on change events via a weaker, unprivileged proxy\n        // object that does not allow accidentally modifying editor state.\n        this.unprivilegedEditor = this.makeUnprivilegedEditor(editor);\n        // Using `editor-change` allows picking up silent updates, like selection\n        // changes on typing.\n        editor.on('editor-change', this.onEditorChange);\n    };\n    ReactQuill.prototype.unhookEditor = function (editor) {\n        editor.off('editor-change', this.onEditorChange);\n    };\n    ReactQuill.prototype.getEditorContents = function () {\n        return this.value;\n    };\n    ReactQuill.prototype.getEditorSelection = function () {\n        return this.selection;\n    };\n    /*\n    True if the value is a Delta instance or a Delta look-alike.\n    */\n    ReactQuill.prototype.isDelta = function (value) {\n        return value && value.ops;\n    };\n    /*\n    Special comparison function that knows how to compare Deltas.\n    */\n    ReactQuill.prototype.isEqualValue = function (value, nextValue) {\n        if (this.isDelta(value) && this.isDelta(nextValue)) {\n            return isEqual_1.default(value.ops, nextValue.ops);\n        }\n        else {\n            return isEqual_1.default(value, nextValue);\n        }\n    };\n    /*\n    Replace the contents of the editor, but keep the previous selection hanging\n    around so that the cursor won't move.\n    */\n    ReactQuill.prototype.setEditorContents = function (editor, value) {\n        var _this = this;\n        this.value = value;\n        var sel = this.getEditorSelection();\n        if (typeof value === 'string') {\n            editor.setContents(editor.clipboard.convert(value));\n        }\n        else {\n            editor.setContents(value);\n        }\n        postpone(function () { return _this.setEditorSelection(editor, sel); });\n    };\n    ReactQuill.prototype.setEditorSelection = function (editor, range) {\n        this.selection = range;\n        if (range) {\n            // Validate bounds before applying.\n            var length_1 = editor.getLength();\n            range.index = Math.max(0, Math.min(range.index, length_1 - 1));\n            range.length = Math.max(0, Math.min(range.length, (length_1 - 1) - range.index));\n            editor.setSelection(range);\n        }\n    };\n    ReactQuill.prototype.setEditorTabIndex = function (editor, tabIndex) {\n        var _a, _b;\n        if ((_b = (_a = editor) === null || _a === void 0 ? void 0 : _a.scroll) === null || _b === void 0 ? void 0 : _b.domNode) {\n            editor.scroll.domNode.tabIndex = tabIndex;\n        }\n    };\n    ReactQuill.prototype.setEditorReadOnly = function (editor, value) {\n        if (value) {\n            editor.disable();\n        }\n        else {\n            editor.enable();\n        }\n    };\n    /*\n    Returns a weaker, unprivileged proxy object that only exposes read-only\n    accessors found on the editor instance, without any state-modifying methods.\n    */\n    ReactQuill.prototype.makeUnprivilegedEditor = function (editor) {\n        var e = editor;\n        return {\n            getHTML: function () { return e.root.innerHTML; },\n            getLength: e.getLength.bind(e),\n            getText: e.getText.bind(e),\n            getContents: e.getContents.bind(e),\n            getSelection: e.getSelection.bind(e),\n            getBounds: e.getBounds.bind(e),\n        };\n    };\n    ReactQuill.prototype.getEditingArea = function () {\n        if (!this.editingArea) {\n            throw new Error('Instantiating on missing editing area');\n        }\n        var element = react_dom_1.default.findDOMNode(this.editingArea);\n        if (!element) {\n            throw new Error('Cannot find element for editing area');\n        }\n        if (element.nodeType === 3) {\n            throw new Error('Editing area cannot be a text node');\n        }\n        return element;\n    };\n    /*\n    Renders an editor area, unless it has been provided one to clone.\n    */\n    ReactQuill.prototype.renderEditingArea = function () {\n        var _this = this;\n        var _a = this.props, children = _a.children, preserveWhitespace = _a.preserveWhitespace;\n        var generation = this.state.generation;\n        var properties = {\n            key: generation,\n            ref: function (instance) {\n                _this.editingArea = instance;\n            },\n        };\n        if (react_1.default.Children.count(children)) {\n            return react_1.default.cloneElement(react_1.default.Children.only(children), properties);\n        }\n        return preserveWhitespace ?\n            react_1.default.createElement(\"pre\", __assign({}, properties)) :\n            react_1.default.createElement(\"div\", __assign({}, properties));\n    };\n    ReactQuill.prototype.render = function () {\n        var _a;\n        return (react_1.default.createElement(\"div\", { id: this.props.id, style: this.props.style, key: this.state.generation, className: \"quill \" + (_a = this.props.className, (_a !== null && _a !== void 0 ? _a : '')), onKeyPress: this.props.onKeyPress, onKeyDown: this.props.onKeyDown, onKeyUp: this.props.onKeyUp }, this.renderEditingArea()));\n    };\n    ReactQuill.prototype.onEditorChangeText = function (value, delta, source, editor) {\n        var _a, _b;\n        if (!this.editor)\n            return;\n        // We keep storing the same type of value as what the user gives us,\n        // so that value comparisons will be more stable and predictable.\n        var nextContents = this.isDelta(this.value)\n            ? editor.getContents()\n            : editor.getHTML();\n        if (nextContents !== this.getEditorContents()) {\n            // Taint this `delta` object, so we can recognize whether the user\n            // is trying to send it back as `value`, preventing a likely loop.\n            this.lastDeltaChangeSet = delta;\n            this.value = nextContents;\n            (_b = (_a = this.props).onChange) === null || _b === void 0 ? void 0 : _b.call(_a, value, delta, source, editor);\n        }\n    };\n    ReactQuill.prototype.onEditorChangeSelection = function (nextSelection, source, editor) {\n        var _a, _b, _c, _d, _e, _f;\n        if (!this.editor)\n            return;\n        var currentSelection = this.getEditorSelection();\n        var hasGainedFocus = !currentSelection && nextSelection;\n        var hasLostFocus = currentSelection && !nextSelection;\n        if (isEqual_1.default(nextSelection, currentSelection))\n            return;\n        this.selection = nextSelection;\n        (_b = (_a = this.props).onChangeSelection) === null || _b === void 0 ? void 0 : _b.call(_a, nextSelection, source, editor);\n        if (hasGainedFocus) {\n            (_d = (_c = this.props).onFocus) === null || _d === void 0 ? void 0 : _d.call(_c, nextSelection, source, editor);\n        }\n        else if (hasLostFocus) {\n            (_f = (_e = this.props).onBlur) === null || _f === void 0 ? void 0 : _f.call(_e, currentSelection, source, editor);\n        }\n    };\n    ReactQuill.prototype.focus = function () {\n        if (!this.editor)\n            return;\n        this.editor.focus();\n    };\n    ReactQuill.prototype.blur = function () {\n        if (!this.editor)\n            return;\n        this.selection = null;\n        this.editor.blur();\n    };\n    ReactQuill.displayName = 'React Quill';\n    /*\n    Export Quill to be able to call `register`\n    */\n    ReactQuill.Quill = quill_1.default;\n    ReactQuill.defaultProps = {\n        theme: 'snow',\n        modules: {},\n        readOnly: false,\n    };\n    return ReactQuill;\n}(react_1.default.Component));\n/*\nSmall helper to execute a function in the next micro-tick.\n*/\nfunction postpone(fn) {\n    Promise.resolve().then(fn);\n}\nmodule.exports = ReactQuill;\n//# sourceMappingURL=index.js.map\n\n//# sourceURL=webpack://woocommerce-rtm-custom-emails/./node_modules/react-quill/lib/index.js?");

/***/ })

}]);