Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @noflow
* @nolint
* @preventMunge
* @preserve-invariant-messages
*/
/*
Modernizr 3.0.0pre (Custom Build) | MIT
*/
"use strict";
var React = require("react"),
Scheduler = require("scheduler");
function formatProdErrorMessage(code) {
for (
var url = "https://reactjs.org/docs/error-decoder.html?invariant=" + code,
i = 1;
i < arguments.length;
i++
) {
url += "&args[]=" + encodeURIComponent(arguments[i]);
}
return (
"Minified React error #" +
code +
"; visit " +
url +
" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."
);
}
if (!React) {
throw Error(formatProdErrorMessage(227));
}
var allNativeEvents = new Set(),
registrationNameDependencies = {};
function registerTwoPhaseEvent(registrationName, dependencies) {
registerDirectEvent(registrationName, dependencies);
registerDirectEvent(registrationName + "Capture", dependencies);
}
function registerDirectEvent(i$jscomp$1_registrationName, dependencies) {
registrationNameDependencies[i$jscomp$1_registrationName] = dependencies;
for (
i$jscomp$1_registrationName = 0;
i$jscomp$1_registrationName < dependencies.length;
i$jscomp$1_registrationName++
) {
allNativeEvents.add(dependencies[i$jscomp$1_registrationName]);
}
}
var canUseDOM = !(
"undefined" === typeof window ||
"undefined" === typeof window.document ||
"undefined" === typeof window.document.createElement
),
VALID_ATTRIBUTE_NAME_REGEX = /^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,
hasOwnProperty = Object.prototype.hasOwnProperty,
illegalAttributeNameCache = {},
validatedAttributeNameCache = {};
function isAttributeNameSafe(attributeName) {
if (hasOwnProperty.call(validatedAttributeNameCache, attributeName)) {
return !0;
}
if (hasOwnProperty.call(illegalAttributeNameCache, attributeName)) {
return !1;
}
if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) {
return (validatedAttributeNameCache[attributeName] = !0);
}
illegalAttributeNameCache[attributeName] = !0;
return !1;
}
function shouldRemoveAttributeWithWarning(
name,
value,
propertyInfo,
isCustomComponentTag
) {
if (null !== propertyInfo && 0 === propertyInfo.type) {
return !1;
}
switch (typeof value) {
case "function":
case "symbol":
return !0;
case "boolean":
if (isCustomComponentTag) {
return !1;
}
if (null !== propertyInfo) {
return !propertyInfo.acceptsBooleans;
}
name = name.toLowerCase().slice(0, 5);
return "data-" !== name && "aria-" !== name;
default:
return !1;
}
}
function shouldRemoveAttribute(
name,
value,
propertyInfo,
isCustomComponentTag
) {
if (
null === value ||
"undefined" === typeof value ||
shouldRemoveAttributeWithWarning(
name,
value,
propertyInfo,
isCustomComponentTag
)
) {
return !0;
}
if (isCustomComponentTag) {
return !1;
}
if (null !== propertyInfo) {
switch (propertyInfo.type) {
case 3:
return !value;
case 4:
return !1 === value;
case 5:
return isNaN(value);
case 6:
return isNaN(value) || 1 > value;
}
}
return !1;
}
function PropertyInfoRecord(
name,
type,
mustUseProperty,
attributeName,
attributeNamespace,
sanitizeURL,
removeEmptyString
) {
this.acceptsBooleans = 2 === type || 3 === type || 4 === type;
this.attributeName = attributeName;
this.attributeNamespace = attributeNamespace;
this.mustUseProperty = mustUseProperty;
this.propertyName = name;
this.type = type;
this.sanitizeURL = sanitizeURL;
this.removeEmptyString = removeEmptyString;
}
var properties = {};
"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style"
.split(" ")
.forEach(function(name) {
properties[name] = new PropertyInfoRecord(name, 0, !1, name, null, !1, !1);
});
[
["acceptCharset", "accept-charset"],
["className", "class"],
["htmlFor", "for"],
["httpEquiv", "http-equiv"]
].forEach(function(_ref) {
var name = _ref[0];
properties[name] = new PropertyInfoRecord(name, 1, !1, _ref[1], null, !1, !1);
});
["contentEditable", "draggable", "spellCheck", "value"].forEach(function(name) {
properties[name] = new PropertyInfoRecord(
name,
2,
!1,
name.toLowerCase(),
null,
!1,
!1
);
});
[
"autoReverse",
"externalResourcesRequired",
"focusable",
"preserveAlpha"
].forEach(function(name) {
properties[name] = new PropertyInfoRecord(name, 2, !1, name, null, !1, !1);
});
"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope"
.split(" ")
.forEach(function(name) {
properties[name] = new PropertyInfoRecord(
name,
3,
!1,
name.toLowerCase(),
null,
!1,
!1
);
});
["checked", "multiple", "muted", "selected"].forEach(function(name) {
properties[name] = new PropertyInfoRecord(name, 3, !0, name, null, !1, !1);
});
["capture", "download"].forEach(function(name) {
properties[name] = new PropertyInfoRecord(name, 4, !1, name, null, !1, !1);
});
["cols", "rows", "size", "span"].forEach(function(name) {
properties[name] = new PropertyInfoRecord(name, 6, !1, name, null, !1, !1);
});
["rowSpan", "start"].forEach(function(name) {
properties[name] = new PropertyInfoRecord(
name,
5,
!1,
name.toLowerCase(),
null,
!1,
!1
);
});
var CAMELIZE = /[\-:]([a-z])/g;
function capitalize(token) {
return token[1].toUpperCase();
}
"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height"
.split(" ")
.forEach(function(attributeName) {
var name = attributeName.replace(CAMELIZE, capitalize);
properties[name] = new PropertyInfoRecord(
name,
1,
!1,
attributeName,
null,
!1,
!1
);
});
"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type"
.split(" ")
.forEach(function(attributeName) {
var name = attributeName.replace(CAMELIZE, capitalize);
properties[name] = new PropertyInfoRecord(
name,
1,
!1,
attributeName,
"http://www.w3.org/1999/xlink",
!1,
!1
);
});
["xml:base", "xml:lang", "xml:space"].forEach(function(attributeName) {
var name = attributeName.replace(CAMELIZE, capitalize);
properties[name] = new PropertyInfoRecord(
name,
1,
!1,
attributeName,
"http://www.w3.org/XML/1998/namespace",
!1,
!1
);
});
["tabIndex", "crossOrigin"].forEach(function(attributeName) {
properties[attributeName] = new PropertyInfoRecord(
attributeName,
1,
!1,
attributeName.toLowerCase(),
null,
!1,
!1
);
});
properties.xlinkHref = new PropertyInfoRecord(
"xlinkHref",
1,
!1,
"xlink:href",
"http://www.w3.org/1999/xlink",
!0,
!1
);
["src", "href", "action", "formAction"].forEach(function(attributeName) {
properties[attributeName] = new PropertyInfoRecord(
attributeName,
1,
!1,
attributeName.toLowerCase(),
null,
!0,
!0
);
});
function setValueForProperty(
node,
attributeName$jscomp$8_name,
attributeValue_value,
attributeNamespace$jscomp$1_isCustomComponentTag
) {
var JSCompiler_inline_result = properties.hasOwnProperty(
attributeName$jscomp$8_name
)
? properties[attributeName$jscomp$8_name]
: null;
var JSCompiler_inline_result$jscomp$0 =
null !== JSCompiler_inline_result
? 0 === JSCompiler_inline_result.type
: attributeNamespace$jscomp$1_isCustomComponentTag
? !1
: !(2 < attributeName$jscomp$8_name.length) ||
("o" !== attributeName$jscomp$8_name[0] &&
"O" !== attributeName$jscomp$8_name[0]) ||
("n" !== attributeName$jscomp$8_name[1] &&
"N" !== attributeName$jscomp$8_name[1])
? !1
: !0;
JSCompiler_inline_result$jscomp$0 ||
(shouldRemoveAttribute(
attributeName$jscomp$8_name,
attributeValue_value,
JSCompiler_inline_result,
attributeNamespace$jscomp$1_isCustomComponentTag
) && (attributeValue_value = null),
attributeNamespace$jscomp$1_isCustomComponentTag ||
null === JSCompiler_inline_result
? isAttributeNameSafe(attributeName$jscomp$8_name) &&
(null === attributeValue_value
? node.removeAttribute(attributeName$jscomp$8_name)
: node.setAttribute(
attributeName$jscomp$8_name,
"" + attributeValue_value
))
: JSCompiler_inline_result.mustUseProperty
? (node[JSCompiler_inline_result.propertyName] =
null === attributeValue_value
? 3 === JSCompiler_inline_result.type
? !1
: ""
: attributeValue_value)
: ((attributeName$jscomp$8_name = JSCompiler_inline_result.attributeName),
(attributeNamespace$jscomp$1_isCustomComponentTag =
JSCompiler_inline_result.attributeNamespace),
null === attributeValue_value
? node.removeAttribute(attributeName$jscomp$8_name)
: ((JSCompiler_inline_result = JSCompiler_inline_result.type),
(attributeValue_value =
3 === JSCompiler_inline_result ||
(4 === JSCompiler_inline_result && !0 === attributeValue_value)
? ""
: "" + attributeValue_value),
attributeNamespace$jscomp$1_isCustomComponentTag
? node.setAttributeNS(
attributeNamespace$jscomp$1_isCustomComponentTag,
attributeName$jscomp$8_name,
attributeValue_value
)
: node.setAttribute(
attributeName$jscomp$8_name,
attributeValue_value
))));
}
var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,
REACT_ELEMENT_TYPE = 60103,
REACT_PORTAL_TYPE = 60106,
REACT_FRAGMENT_TYPE = 60107,
REACT_STRICT_MODE_TYPE = 60108,
REACT_PROFILER_TYPE = 60114,
REACT_PROVIDER_TYPE = 60109,
REACT_CONTEXT_TYPE = 60110,
REACT_FORWARD_REF_TYPE = 60112,
REACT_SUSPENSE_TYPE = 60113,
REACT_SUSPENSE_LIST_TYPE = 60120,
REACT_MEMO_TYPE = 60115,
REACT_LAZY_TYPE = 60116,
REACT_OPAQUE_ID_TYPE = 60128,
REACT_DEBUG_TRACING_MODE_TYPE = 60129,
REACT_OFFSCREEN_TYPE = 60130,
REACT_LEGACY_HIDDEN_TYPE = 60131,
REACT_CACHE_TYPE = 60132;
if ("function" === typeof Symbol && Symbol.for) {
var symbolFor = Symbol.for;
REACT_ELEMENT_TYPE = symbolFor("react.element");
REACT_PORTAL_TYPE = symbolFor("react.portal");
REACT_FRAGMENT_TYPE = symbolFor("react.fragment");
REACT_STRICT_MODE_TYPE = symbolFor("react.strict_mode");
REACT_PROFILER_TYPE = symbolFor("react.profiler");
REACT_PROVIDER_TYPE = symbolFor("react.provider");
REACT_CONTEXT_TYPE = symbolFor("react.context");
REACT_FORWARD_REF_TYPE = symbolFor("react.forward_ref");
REACT_SUSPENSE_TYPE = symbolFor("react.suspense");
REACT_SUSPENSE_LIST_TYPE = symbolFor("react.suspense_list");
REACT_MEMO_TYPE = symbolFor("react.memo");
REACT_LAZY_TYPE = symbolFor("react.lazy");
symbolFor("react.scope");
REACT_OPAQUE_ID_TYPE = symbolFor("react.opaque.id");
REACT_DEBUG_TRACING_MODE_TYPE = symbolFor("react.debug_trace_mode");
REACT_OFFSCREEN_TYPE = symbolFor("react.offscreen");
REACT_LEGACY_HIDDEN_TYPE = symbolFor("react.legacy_hidden");
REACT_CACHE_TYPE = symbolFor("react.cache");
}
var MAYBE_ITERATOR_SYMBOL = "function" === typeof Symbol && Symbol.iterator;
function getIteratorFn(maybeIterable_maybeIterator) {
if (
null === maybeIterable_maybeIterator ||
"object" !== typeof maybeIterable_maybeIterator
) {
return null;
}
maybeIterable_maybeIterator =
(MAYBE_ITERATOR_SYMBOL &&
maybeIterable_maybeIterator[MAYBE_ITERATOR_SYMBOL]) ||
maybeIterable_maybeIterator["@@iterator"];
return "function" === typeof maybeIterable_maybeIterator
? maybeIterable_maybeIterator
: null;
}
function describeComponentFrame(name, source, ownerName) {
source = "";
ownerName && (source = " (created by " + ownerName + ")");
return "\n in " + (name || "Unknown") + source;
}
function describeFunctionComponentFrame(fn, source) {
return fn
? describeComponentFrame(fn.displayName || fn.name || null, source, null)
: "";
}
function describeFiber(JSCompiler_inline_result) {
switch (JSCompiler_inline_result.tag) {
case 5:
return describeComponentFrame(JSCompiler_inline_result.type, null, null);
case 16:
return describeComponentFrame("Lazy", null, null);
case 13:
return describeComponentFrame("Suspense", null, null);
case 19:
return describeComponentFrame("SuspenseList", null, null);
case 0:
case 2:
case 15:
return describeFunctionComponentFrame(
JSCompiler_inline_result.type,
null
);
case 11:
return describeFunctionComponentFrame(
JSCompiler_inline_result.type.render,
null
);
case 1:
return (
(JSCompiler_inline_result = describeFunctionComponentFrame(
JSCompiler_inline_result.type,
null
)),
JSCompiler_inline_result
);
default:
return "";
}
}
function getComponentNameFromType(init_type) {
if (null == init_type) {
return null;
}
if ("function" === typeof init_type) {
return init_type.displayName || init_type.name || null;
}
if ("string" === typeof init_type) {
return init_type;
}
switch (init_type) {
case REACT_FRAGMENT_TYPE:
return "Fragment";
case REACT_PORTAL_TYPE:
return "Portal";
case REACT_PROFILER_TYPE:
return "Profiler";
case REACT_STRICT_MODE_TYPE:
return "StrictMode";
case REACT_SUSPENSE_TYPE:
return "Suspense";
case REACT_SUSPENSE_LIST_TYPE:
return "SuspenseList";
case REACT_CACHE_TYPE:
return "Cache";
}
if ("object" === typeof init_type) {
switch (init_type.$$typeof) {
case REACT_CONTEXT_TYPE:
return (init_type.displayName || "Context") + ".Consumer";
case REACT_PROVIDER_TYPE:
return (init_type._context.displayName || "Context") + ".Provider";
case REACT_FORWARD_REF_TYPE:
var functionName$jscomp$inline_205_innerType = init_type.render;
functionName$jscomp$inline_205_innerType =
functionName$jscomp$inline_205_innerType.displayName ||
functionName$jscomp$inline_205_innerType.name ||
"";
return (
init_type.displayName ||
("" !== functionName$jscomp$inline_205_innerType
? "ForwardRef(" + functionName$jscomp$inline_205_innerType + ")"
: "ForwardRef")
);
case REACT_MEMO_TYPE:
return getComponentNameFromType(init_type.type);
case REACT_LAZY_TYPE:
functionName$jscomp$inline_205_innerType = init_type._payload;
init_type = init_type._init;
try {
return getComponentNameFromType(
init_type(functionName$jscomp$inline_205_innerType)
);
} catch (x) {}
}
}
return null;
}
function getComponentNameFromFiber(
fiber$jscomp$1_functionName$jscomp$inline_210_innerType
) {
var type = fiber$jscomp$1_functionName$jscomp$inline_210_innerType.type;
switch (fiber$jscomp$1_functionName$jscomp$inline_210_innerType.tag) {
case 24:
return "Cache";
case 9:
return (type.displayName || "Context") + ".Consumer";
case 10:
return (type._context.displayName || "Context") + ".Provider";
case 18:
return "DehydratedFragment";
case 11:
return (
(fiber$jscomp$1_functionName$jscomp$inline_210_innerType = type.render),
(fiber$jscomp$1_functionName$jscomp$inline_210_innerType =
fiber$jscomp$1_functionName$jscomp$inline_210_innerType.displayName ||
fiber$jscomp$1_functionName$jscomp$inline_210_innerType.name ||
""),
type.displayName ||
("" !== fiber$jscomp$1_functionName$jscomp$inline_210_innerType
? "ForwardRef(" +
fiber$jscomp$1_functionName$jscomp$inline_210_innerType +
")"
: "ForwardRef")
);
case 7:
return "Fragment";
case 5:
return type;
case 4:
return "Portal";
case 3:
return "Root";
case 6:
return "Text";
case 16:
return getComponentNameFromType(type);
case 23:
return "LegacyHidden";
case 8:
return type === REACT_STRICT_MODE_TYPE ? "StrictMode" : "Mode";
case 22:
return "Offscreen";
case 12:
return "Profiler";
case 21:
return "Scope";
case 13:
return "Suspense";
case 19:
return "SuspenseList";
case 1:
case 0:
case 17:
case 2:
case 14:
case 15:
if ("function" === typeof type) {
return type.displayName || type.name || null;
}
if ("string" === typeof type) {
return type;
}
}
return null;
}
function getToStringValue(value) {
switch (typeof value) {
case "boolean":
case "number":
case "object":
case "string":
case "undefined":
return value;
default:
return "";
}
}
function isCheckable(elem_nodeName) {
var type = elem_nodeName.type;
return (
(elem_nodeName = elem_nodeName.nodeName) &&
"input" === elem_nodeName.toLowerCase() &&
("checkbox" === type || "radio" === type)
);
}
function trackValueOnNode(node) {
var valueField = isCheckable(node) ? "checked" : "value",
descriptor = Object.getOwnPropertyDescriptor(
node.constructor.prototype,
valueField
),
currentValue = "" + node[valueField];
if (
!node.hasOwnProperty(valueField) &&
"undefined" !== typeof descriptor &&
"function" === typeof descriptor.get &&
"function" === typeof descriptor.set
) {
var get = descriptor.get,
set = descriptor.set;
Object.defineProperty(node, valueField, {
configurable: !0,
get: function() {
return get.call(this);
},
set: function(value) {
currentValue = "" + value;
set.call(this, value);
}
});
Object.defineProperty(node, valueField, {
enumerable: descriptor.enumerable
});
return {
getValue: function() {
return currentValue;
},
setValue: function(value) {
currentValue = "" + value;
},
stopTracking: function() {
node._valueTracker = null;
delete node[valueField];
}
};
}
}
function track(node) {
node._valueTracker || (node._valueTracker = trackValueOnNode(node));
}
function updateValueIfChanged(JSCompiler_inline_result$jscomp$126_node) {
if (!JSCompiler_inline_result$jscomp$126_node) {
return !1;
}
var tracker = JSCompiler_inline_result$jscomp$126_node._valueTracker;
if (!tracker) {
return !0;
}
var lastValue = tracker.getValue();
var value = "";
JSCompiler_inline_result$jscomp$126_node &&
(value = isCheckable(JSCompiler_inline_result$jscomp$126_node)
? JSCompiler_inline_result$jscomp$126_node.checked
? "true"
: "false"
: JSCompiler_inline_result$jscomp$126_node.value);
JSCompiler_inline_result$jscomp$126_node = value;
return JSCompiler_inline_result$jscomp$126_node !== lastValue
? (tracker.setValue(JSCompiler_inline_result$jscomp$126_node), !0)
: !1;
}
function getActiveElement(doc) {
doc = doc || ("undefined" !== typeof document ? document : void 0);
if ("undefined" === typeof doc) {
return null;
}
try {
return doc.activeElement || doc.body;
} catch (e) {
return doc.body;
}
}
function getHostProps(element, props) {
var checked = props.checked;
return Object.assign({}, props, {
defaultChecked: void 0,
defaultValue: void 0,
value: void 0,
checked: null != checked ? checked : element._wrapperState.initialChecked
});
}
function initWrapperState(element, props) {
var JSCompiler_temp_const =
null == props.defaultValue ? "" : props.defaultValue,
JSCompiler_temp_const$jscomp$0 =
null != props.checked ? props.checked : props.defaultChecked;
JSCompiler_temp_const = getToStringValue(
null != props.value ? props.value : JSCompiler_temp_const
);
element._wrapperState = {
initialChecked: JSCompiler_temp_const$jscomp$0,
initialValue: JSCompiler_temp_const,
controlled:
"checkbox" === props.type || "radio" === props.type
? null != props.checked
: null != props.value
};
}
function updateChecked(element, checked$jscomp$1_props) {
checked$jscomp$1_props = checked$jscomp$1_props.checked;
null != checked$jscomp$1_props &&
setValueForProperty(element, "checked", checked$jscomp$1_props, !1);
}
function updateWrapper(element, props) {
updateChecked(element, props);
var value = getToStringValue(props.value),
type = props.type;
if (null != value) {
if ("number" === type) {
if ((0 === value && "" === element.value) || element.value != value) {
element.value = "" + value;
}
} else {
element.value !== "" + value && (element.value = "" + value);
}
} else {
if ("submit" === type || "reset" === type) {
element.removeAttribute("value");
return;
}
}
props.hasOwnProperty("value")
? setDefaultValue(element, props.type, value)
: props.hasOwnProperty("defaultValue") &&
setDefaultValue(
element,
props.type,
getToStringValue(props.defaultValue)
);
null == props.checked &&
null != props.defaultChecked &&
(element.defaultChecked = !!props.defaultChecked);
}
function postMountWrapper(
element,
initialValue_props,
isHydrating$jscomp$1_name
) {
if (
initialValue_props.hasOwnProperty("value") ||
initialValue_props.hasOwnProperty("defaultValue")
) {
var type = initialValue_props.type;
if (
!(
("submit" !== type && "reset" !== type) ||
(void 0 !== initialValue_props.value &&
null !== initialValue_props.value)
)
) {
return;
}
initialValue_props = "" + element._wrapperState.initialValue;
isHydrating$jscomp$1_name ||
initialValue_props === element.value ||
(element.value = initialValue_props);
element.defaultValue = initialValue_props;
}
isHydrating$jscomp$1_name = element.name;
"" !== isHydrating$jscomp$1_name && (element.name = "");
element.defaultChecked = !!element._wrapperState.initialChecked;
"" !== isHydrating$jscomp$1_name &&
(element.name = isHydrating$jscomp$1_name);
}
function setDefaultValue(node, type, value) {
if ("number" !== type || getActiveElement(node.ownerDocument) !== node) {
null == value
? (node.defaultValue = "" + node._wrapperState.initialValue)
: node.defaultValue !== "" + value && (node.defaultValue = "" + value);
}
}
function flattenChildren(children) {
var content = "";
React.Children.forEach(children, function(child) {
null != child && (content += child);
});
return content;
}
function getHostProps$1(element$jscomp$7_hostProps, content$jscomp$1_props) {
element$jscomp$7_hostProps = Object.assign(
{ children: void 0 },
content$jscomp$1_props
);
if (
(content$jscomp$1_props = flattenChildren(content$jscomp$1_props.children))
) {
element$jscomp$7_hostProps.children = content$jscomp$1_props;
}
return element$jscomp$7_hostProps;
}
function updateOptions(
node$jscomp$15_options,
defaultSelected_multiple_selectedValue,
i$2_propValue_selectedValue$3,
setDefaultSelected
) {
node$jscomp$15_options = node$jscomp$15_options.options;
if (defaultSelected_multiple_selectedValue) {
defaultSelected_multiple_selectedValue = {};
for (var i$4_i = 0; i$4_i < i$2_propValue_selectedValue$3.length; i$4_i++) {
defaultSelected_multiple_selectedValue[
"$" + i$2_propValue_selectedValue$3[i$4_i]
] = !0;
}
for (
i$2_propValue_selectedValue$3 = 0;
i$2_propValue_selectedValue$3 < node$jscomp$15_options.length;
i$2_propValue_selectedValue$3++
) {
(i$4_i = defaultSelected_multiple_selectedValue.hasOwnProperty(
"$" + node$jscomp$15_options[i$2_propValue_selectedValue$3].value
)),
node$jscomp$15_options[i$2_propValue_selectedValue$3].selected !==
i$4_i &&
(node$jscomp$15_options[
i$2_propValue_selectedValue$3
].selected = i$4_i),
i$4_i &&
setDefaultSelected &&
(node$jscomp$15_options[
i$2_propValue_selectedValue$3
].defaultSelected = !0);
}
} else {
i$2_propValue_selectedValue$3 =
"" + getToStringValue(i$2_propValue_selectedValue$3);
defaultSelected_multiple_selectedValue = null;
for (i$4_i = 0; i$4_i < node$jscomp$15_options.length; i$4_i++) {
if (
node$jscomp$15_options[i$4_i].value === i$2_propValue_selectedValue$3
) {
node$jscomp$15_options[i$4_i].selected = !0;
setDefaultSelected &&
(node$jscomp$15_options[i$4_i].defaultSelected = !0);
return;
}
null !== defaultSelected_multiple_selectedValue ||
node$jscomp$15_options[i$4_i].disabled ||
(defaultSelected_multiple_selectedValue =
node$jscomp$15_options[i$4_i]);
}
null !== defaultSelected_multiple_selectedValue &&
(defaultSelected_multiple_selectedValue.selected = !0);
}
}
function getHostProps$3(element, props) {
if (null != props.dangerouslySetInnerHTML) {
throw Error(formatProdErrorMessage(91));
}
return Object.assign({}, props, {
value: void 0,
defaultValue: void 0,
children: "" + element._wrapperState.initialValue
});
}
function initWrapperState$2(element, defaultValue$jscomp$1_props) {
var children$jscomp$1_initialValue = defaultValue$jscomp$1_props.value;
if (null == children$jscomp$1_initialValue) {
children$jscomp$1_initialValue = defaultValue$jscomp$1_props.children;
defaultValue$jscomp$1_props = defaultValue$jscomp$1_props.defaultValue;
if (null != children$jscomp$1_initialValue) {
if (null != defaultValue$jscomp$1_props) {
throw Error(formatProdErrorMessage(92));
}
if (Array.isArray(children$jscomp$1_initialValue)) {
if (!(1 >= children$jscomp$1_initialValue.length)) {
throw Error(formatProdErrorMessage(93));
}
children$jscomp$1_initialValue = children$jscomp$1_initialValue[0];
}
defaultValue$jscomp$1_props = children$jscomp$1_initialValue;
}
null == defaultValue$jscomp$1_props && (defaultValue$jscomp$1_props = "");
children$jscomp$1_initialValue = defaultValue$jscomp$1_props;
}
element._wrapperState = {
initialValue: getToStringValue(children$jscomp$1_initialValue)
};
}
function updateWrapper$1(element, props) {
var newValue_value = getToStringValue(props.value),
defaultValue = getToStringValue(props.defaultValue);
null != newValue_value &&
((newValue_value = "" + newValue_value),
newValue_value !== element.value && (element.value = newValue_value),
null == props.defaultValue &&
element.defaultValue !== newValue_value &&
(element.defaultValue = newValue_value));
null != defaultValue && (element.defaultValue = "" + defaultValue);
}
function postMountWrapper$3(element) {
var textContent = element.textContent;
textContent === element._wrapperState.initialValue &&
"" !== textContent &&
null !== textContent &&
(element.value = textContent);
}
function getIntrinsicNamespace(type) {
switch (type) {
case "svg":
return "http://www.w3.org/2000/svg";
case "math":
return "http://www.w3.org/1998/Math/MathML";
default:
return "http://www.w3.org/1999/xhtml";
}
}
function getChildNamespace(parentNamespace, type) {
return null == parentNamespace ||
"http://www.w3.org/1999/xhtml" === parentNamespace
? getIntrinsicNamespace(type)
: "http://www.w3.org/2000/svg" === parentNamespace &&
"foreignObject" === type
? "http://www.w3.org/1999/xhtml"
: parentNamespace;
}
var reusableSVGContainer,
setInnerHTML = (function(func) {
return "undefined" !== typeof MSApp && MSApp.execUnsafeLocalFunction
? function(arg0, arg1, arg2, arg3) {
MSApp.execUnsafeLocalFunction(function() {
return func(arg0, arg1, arg2, arg3);
});
}
: func;
})(function(node, html_svgNode) {
if (
"http://www.w3.org/2000/svg" !== node.namespaceURI ||
"innerHTML" in node
) {
node.innerHTML = html_svgNode;
} else {
reusableSVGContainer =
reusableSVGContainer || document.createElement("div");
reusableSVGContainer.innerHTML =
"<svg>" + html_svgNode.valueOf().toString() + "</svg>";
for (html_svgNode = reusableSVGContainer.firstChild; node.firstChild; ) {
node.removeChild(node.firstChild);
}
for (; html_svgNode.firstChild; ) {
node.appendChild(html_svgNode.firstChild);
}
}
});
function setTextContent(node, text) {
if (text) {
var firstChild = node.firstChild;
if (
firstChild &&
firstChild === node.lastChild &&
3 === firstChild.nodeType
) {
firstChild.nodeValue = text;
return;
}
}
node.textContent = text;
}
var isUnitlessNumber = {
animationIterationCount: !0,
borderImageOutset: !0,
borderImageSlice: !0,
borderImageWidth: !0,
boxFlex: !0,
boxFlexGroup: !0,
boxOrdinalGroup: !0,
columnCount: !0,
columns: !0,
flex: !0,
flexGrow: !0,
flexPositive: !0,
flexShrink: !0,
flexNegative: !0,
flexOrder: !0,
gridArea: !0,
gridRow: !0,
gridRowEnd: !0,
gridRowSpan: !0,
gridRowStart: !0,
gridColumn: !0,
gridColumnEnd: !0,
gridColumnSpan: !0,
gridColumnStart: !0,
fontWeight: !0,
lineClamp: !0,
lineHeight: !0,
opacity: !0,
order: !0,
orphans: !0,
tabSize: !0,
widows: !0,
zIndex: !0,
zoom: !0,
fillOpacity: !0,
floodOpacity: !0,
stopOpacity: !0,
strokeDasharray: !0,
strokeDashoffset: !0,
strokeMiterlimit: !0,
strokeOpacity: !0,
strokeWidth: !0
},
prefixes = ["Webkit", "ms", "Moz", "O"];
Object.keys(isUnitlessNumber).forEach(function(prop) {
prefixes.forEach(function(JSCompiler_inline_result$jscomp$130_prefix) {
JSCompiler_inline_result$jscomp$130_prefix =
JSCompiler_inline_result$jscomp$130_prefix +
prop.charAt(0).toUpperCase() +
prop.substring(1);
isUnitlessNumber[JSCompiler_inline_result$jscomp$130_prefix] =
isUnitlessNumber[prop];
});
});
function dangerousStyleValue(name, value, isCustomProperty) {
return null == value || "boolean" === typeof value || "" === value
? ""
: isCustomProperty ||
"number" !== typeof value ||
0 === value ||
(isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name])
? ("" + value).trim()
: value + "px";
}
function setValueForStyles(node$jscomp$26_style, styles) {
node$jscomp$26_style = node$jscomp$26_style.style;
for (var styleName in styles) {
if (styles.hasOwnProperty(styleName)) {
var isCustomProperty = 0 === styleName.indexOf("--"),
styleValue = dangerousStyleValue(
styleName,
styles[styleName],
isCustomProperty
);
"float" === styleName && (styleName = "cssFloat");
isCustomProperty
? node$jscomp$26_style.setProperty(styleName, styleValue)
: (node$jscomp$26_style[styleName] = styleValue);
}
}
}
var voidElementTags = Object.assign(
{ menuitem: !0 },
{
area: !0,
base: !0,
br: !0,
col: !0,
embed: !0,
hr: !0,
img: !0,
input: !0,
keygen: !0,
link: !0,
meta: !0,
param: !0,
source: !0,
track: !0,
wbr: !0
}
);
function assertValidProps(tag, props) {
if (props) {
if (
voidElementTags[tag] &&
(null != props.children || null != props.dangerouslySetInnerHTML)
) {
throw Error(formatProdErrorMessage(137, tag));
}
if (null != props.dangerouslySetInnerHTML) {
if (null != props.children) {
throw Error(formatProdErrorMessage(60));
}
if (
!(
"object" === typeof props.dangerouslySetInnerHTML &&
"__html" in props.dangerouslySetInnerHTML
)
) {
throw Error(formatProdErrorMessage(61));
}
}
if (null != props.style && "object" !== typeof props.style) {
throw Error(formatProdErrorMessage(62));
}
}
}
function isCustomComponent(tagName, props) {
if (-1 === tagName.indexOf("-")) {
return "string" === typeof props.is;
}
switch (tagName) {
case "annotation-xml":
case "color-profile":
case "font-face":
case "font-face-src":
case "font-face-uri":
case "font-face-format":
case "font-face-name":
case "missing-glyph":
return !1;
default:
return !0;
}
}
function getEventTarget(nativeEvent_target) {
nativeEvent_target =
nativeEvent_target.target || nativeEvent_target.srcElement || window;
nativeEvent_target.correspondingUseElement &&
(nativeEvent_target = nativeEvent_target.correspondingUseElement);
return 3 === nativeEvent_target.nodeType
? nativeEvent_target.parentNode
: nativeEvent_target;
}
var restoreImpl = null,
restoreTarget = null,
restoreQueue = null;
function restoreStateOfTarget(internalInstance_target) {
if (
(internalInstance_target = getInstanceFromNode(internalInstance_target))
) {
if ("function" !== typeof restoreImpl) {
throw Error(formatProdErrorMessage(280));
}
var stateNode = internalInstance_target.stateNode;
stateNode &&
restoreImpl(
internalInstance_target.stateNode,
internalInstance_target.type,
stateNode[internalPropsKey] || null
);
}
}
function batchedUpdatesImpl(fn, bookkeeping) {
return fn(bookkeeping);
}
function discreteUpdatesImpl(fn, a, b, c, d) {
return fn(a, b, c, d);
}
function flushDiscreteUpdatesImpl() {}
var batchedEventUpdatesImpl = batchedUpdatesImpl,
isInsideEventHandler = !1,
isBatchingEventUpdates = !1;
function finishEventHandler() {
if (null !== restoreTarget || null !== restoreQueue) {
if ((flushDiscreteUpdatesImpl(), restoreTarget)) {
var i$jscomp$inline_225_target = restoreTarget,
queuedTargets = restoreQueue;
restoreQueue = restoreTarget = null;
restoreStateOfTarget(i$jscomp$inline_225_target);
if (queuedTargets) {
for (
i$jscomp$inline_225_target = 0;
i$jscomp$inline_225_target < queuedTargets.length;
i$jscomp$inline_225_target++
) {
restoreStateOfTarget(queuedTargets[i$jscomp$inline_225_target]);
}
}
}
}
}
function batchedEventUpdates(fn, a, b) {
if (isBatchingEventUpdates) {
return fn(a, b);
}
isBatchingEventUpdates = !0;
try {
return batchedEventUpdatesImpl(fn, a, b);
} finally {
(isBatchingEventUpdates = !1), finishEventHandler();
}
}
function getListener(
JSCompiler_inline_result$jscomp$131_inst_tag,
registrationName
) {
var listener_stateNode =
JSCompiler_inline_result$jscomp$131_inst_tag.stateNode;
if (null === listener_stateNode) {
return null;
}
var JSCompiler_temp$jscomp$1248_props =
listener_stateNode[internalPropsKey] || null;
if (null === JSCompiler_temp$jscomp$1248_props) {
return null;
}
listener_stateNode = JSCompiler_temp$jscomp$1248_props[registrationName];
a: {
switch (registrationName) {
case "onClick":
case "onClickCapture":
case "onDoubleClick":
case "onDoubleClickCapture":
case "onMouseDown":
case "onMouseDownCapture":
case "onMouseMove":
case "onMouseMoveCapture":
case "onMouseUp":
case "onMouseUpCapture":
case "onMouseEnter":
(JSCompiler_temp$jscomp$1248_props = !JSCompiler_temp$jscomp$1248_props.disabled) ||
((JSCompiler_inline_result$jscomp$131_inst_tag =
JSCompiler_inline_result$jscomp$131_inst_tag.type),
(JSCompiler_temp$jscomp$1248_props = !(
"button" === JSCompiler_inline_result$jscomp$131_inst_tag ||
"input" === JSCompiler_inline_result$jscomp$131_inst_tag ||
"select" === JSCompiler_inline_result$jscomp$131_inst_tag ||
"textarea" === JSCompiler_inline_result$jscomp$131_inst_tag
)));
JSCompiler_inline_result$jscomp$131_inst_tag = !JSCompiler_temp$jscomp$1248_props;
break a;
default:
JSCompiler_inline_result$jscomp$131_inst_tag = !1;
}
}
if (JSCompiler_inline_result$jscomp$131_inst_tag) {
return null;
}
if (listener_stateNode && "function" !== typeof listener_stateNode) {
throw Error(
formatProdErrorMessage(231, registrationName, typeof listener_stateNode)
);
}
return listener_stateNode;
}
var passiveBrowserEventsSupported = !1;
if (canUseDOM) {
try {
var options = {};
Object.defineProperty(options, "passive", {
get: function() {
passiveBrowserEventsSupported = !0;
}
});
window.addEventListener("test", options, options);
window.removeEventListener("test", options, options);
} catch (e) {
passiveBrowserEventsSupported = !1;
}
}
var ReactFbErrorUtils = require("ReactFbErrorUtils");
if ("function" !== typeof ReactFbErrorUtils.invokeGuardedCallback) {
throw Error(formatProdErrorMessage(255));
}
function invokeGuardedCallbackImpl(name, func, context, a, b, c, d, e, f) {
ReactFbErrorUtils.invokeGuardedCallback.apply(this, arguments);
}
var hasError = !1,
caughtError = null,
hasRethrowError = !1,
rethrowError = null,
reporter = {
onError: function(error) {
hasError = !0;
caughtError = error;
}
};
function invokeGuardedCallback(name, func, context, a, b, c, d, e, f) {
hasError = !1;
caughtError = null;
invokeGuardedCallbackImpl.apply(reporter, arguments);
}
function invokeGuardedCallbackAndCatchFirstError(
name,
func,
context,
a,
b,
c,
d,
e,
f
) {
invokeGuardedCallback.apply(this, arguments);
if (hasError) {
if (hasError) {
var error$jscomp$2_error = caughtError;
hasError = !1;
caughtError = null;
} else {
throw Error(formatProdErrorMessage(198));
}
hasRethrowError ||
((hasRethrowError = !0), (rethrowError = error$jscomp$2_error));
}
}
function getNearestMountedFiber(fiber) {
var node = fiber,
nearestMounted = fiber;
if (fiber.alternate) {
for (; node.return; ) {
node = node.return;
}
} else {
fiber = node;
do {
(node = fiber),
0 !== (node.flags & 2050) && (nearestMounted = node.return),
(fiber = node.return);
} while (fiber);
}
return 3 === node.tag ? nearestMounted : null;
}
function getSuspenseInstanceFromFiber(current_fiber) {
if (13 === current_fiber.tag) {
var suspenseState = current_fiber.memoizedState;
null === suspenseState &&
((current_fiber = current_fiber.alternate),
null !== current_fiber && (suspenseState = current_fiber.memoizedState));
if (null !== suspenseState) {
return suspenseState.dehydrated;
}
}
return null;
}
function assertIsMounted(fiber) {
if (getNearestMountedFiber(fiber) !== fiber) {
throw Error(formatProdErrorMessage(188));
}
}
function findCurrentFiberUsingSlowPath(fiber) {
var alternate_nearestMounted = fiber.alternate;
if (!alternate_nearestMounted) {
alternate_nearestMounted = getNearestMountedFiber(fiber);
if (null === alternate_nearestMounted) {
throw Error(formatProdErrorMessage(188));
}
return alternate_nearestMounted !== fiber ? null : fiber;
}
for (var a = fiber, b = alternate_nearestMounted; ; ) {
var parentA = a.return;
if (null === parentA) {
break;
}
var child = parentA.alternate;
if (null === child) {
b = parentA.return;
if (null !== b) {
a = b;
continue;
}
break;
}
if (parentA.child === child.child) {
for (child = parentA.child; child; ) {
if (child === a) {
return assertIsMounted(parentA), fiber;
}
if (child === b) {
return assertIsMounted(parentA), alternate_nearestMounted;
}
child = child.sibling;
}
throw Error(formatProdErrorMessage(188));
}
if (a.return !== b.return) {
(a = parentA), (b = child);
} else {
for (var didFindChild = !1, child$5 = parentA.child; child$5; ) {
if (child$5 === a) {
didFindChild = !0;
a = parentA;
b = child;
break;
}
if (child$5 === b) {
didFindChild = !0;
b = parentA;
a = child;
break;
}
child$5 = child$5.sibling;
}
if (!didFindChild) {
for (child$5 = child.child; child$5; ) {
if (child$5 === a) {
didFindChild = !0;
a = child;
b = parentA;
break;
}
if (child$5 === b) {
didFindChild = !0;
b = child;
a = parentA;
break;
}
child$5 = child$5.sibling;
}
if (!didFindChild) {
throw Error(formatProdErrorMessage(189));
}
}
}
if (a.alternate !== b) {
throw Error(formatProdErrorMessage(190));
}
}
if (3 !== a.tag) {
throw Error(formatProdErrorMessage(188));
}
return a.stateNode.current === a ? fiber : alternate_nearestMounted;
}
function findCurrentHostFiberImpl(child$jscomp$2_node) {
if (5 === child$jscomp$2_node.tag || 6 === child$jscomp$2_node.tag) {
return child$jscomp$2_node;
}
for (
child$jscomp$2_node = child$jscomp$2_node.child;
null !== child$jscomp$2_node;
) {
var match = findCurrentHostFiberImpl(child$jscomp$2_node);
if (null !== match) {
return match;
}
child$jscomp$2_node = child$jscomp$2_node.sibling;
}
return null;
}
function doesFiberContain(parentFiber, childFiber_node) {
for (
var parentFiberAlternate = parentFiber.alternate;
null !== childFiber_node;
) {
if (
childFiber_node === parentFiber ||
childFiber_node === parentFiberAlternate
) {
return !0;
}
childFiber_node = childFiber_node.return;
}
return !1;
}
var attemptDiscreteHydration,
attemptContinuousHydration,
attemptHydrationAtCurrentPriority,
attemptHydrationAtPriority,
hasScheduledReplayAttempt = !1,
queuedDiscreteEvents = [],
queuedFocus = null,
queuedDrag = null,
queuedMouse = null,
queuedPointers = new Map(),
queuedPointerCaptures = new Map(),
queuedExplicitHydrationTargets = [],
discreteReplayableEvents = "mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(
" "
);
function createQueuedReplayableEvent(
blockedOn,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
) {
return {
blockedOn: blockedOn,
domEventName: domEventName,
eventSystemFlags: eventSystemFlags | 16,
nativeEvent: nativeEvent,
targetContainers: [targetContainer]
};
}
function clearIfContinuousEvent(domEventName, nativeEvent) {
switch (domEventName) {
case "focusin":
case "focusout":
queuedFocus = null;
break;
case "dragenter":
case "dragleave":
queuedDrag = null;
break;
case "mouseover":
case "mouseout":
queuedMouse = null;
break;
case "pointerover":
case "pointerout":
queuedPointers.delete(nativeEvent.pointerId);
break;
case "gotpointercapture":
case "lostpointercapture":
queuedPointerCaptures.delete(nativeEvent.pointerId);
}
}
function accumulateOrCreateContinuousQueuedReplayableEvent(
existingQueuedEvent_queuedEvent,
blockedOn$jscomp$2_fiber,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
) {
if (
null === existingQueuedEvent_queuedEvent ||
existingQueuedEvent_queuedEvent.nativeEvent !== nativeEvent
) {
return (
(existingQueuedEvent_queuedEvent = createQueuedReplayableEvent(
blockedOn$jscomp$2_fiber,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
)),
null !== blockedOn$jscomp$2_fiber &&
((blockedOn$jscomp$2_fiber = getInstanceFromNode(
blockedOn$jscomp$2_fiber
)),
null !== blockedOn$jscomp$2_fiber &&
attemptContinuousHydration(blockedOn$jscomp$2_fiber)),
existingQueuedEvent_queuedEvent
);
}
existingQueuedEvent_queuedEvent.eventSystemFlags |= eventSystemFlags;
blockedOn$jscomp$2_fiber = existingQueuedEvent_queuedEvent.targetContainers;
null !== targetContainer &&
-1 === blockedOn$jscomp$2_fiber.indexOf(targetContainer) &&
blockedOn$jscomp$2_fiber.push(targetContainer);
return existingQueuedEvent_queuedEvent;
}
function queueIfContinuousEvent(
blockedOn,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
) {
switch (domEventName) {
case "focusin":
return (
(queuedFocus = accumulateOrCreateContinuousQueuedReplayableEvent(
queuedFocus,
blockedOn,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
)),
!0
);
case "dragenter":
return (
(queuedDrag = accumulateOrCreateContinuousQueuedReplayableEvent(
queuedDrag,
blockedOn,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
)),
!0
);
case "mouseover":
return (
(queuedMouse = accumulateOrCreateContinuousQueuedReplayableEvent(
queuedMouse,
blockedOn,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
)),
!0
);
case "pointerover":
var pointerId$8_pointerId = nativeEvent.pointerId;
queuedPointers.set(
pointerId$8_pointerId,
accumulateOrCreateContinuousQueuedReplayableEvent(
queuedPointers.get(pointerId$8_pointerId) || null,
blockedOn,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
)
);
return !0;
case "gotpointercapture":
return (
(pointerId$8_pointerId = nativeEvent.pointerId),
queuedPointerCaptures.set(
pointerId$8_pointerId,
accumulateOrCreateContinuousQueuedReplayableEvent(
queuedPointerCaptures.get(pointerId$8_pointerId) || null,
blockedOn,
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
)
),
!0
);
}
return !1;
}
function attemptExplicitHydrationTarget(queuedTarget) {
var instance_tag = getClosestInstanceFromNode(queuedTarget.target);
if (null !== instance_tag) {
var nearestMounted = getNearestMountedFiber(instance_tag);
if (null !== nearestMounted) {
if (((instance_tag = nearestMounted.tag), 13 === instance_tag)) {
if (
((instance_tag = getSuspenseInstanceFromFiber(nearestMounted)),
null !== instance_tag)
) {
queuedTarget.blockedOn = instance_tag;
attemptHydrationAtPriority(queuedTarget.lanePriority, function() {
attemptHydrationAtCurrentPriority(nearestMounted);
});
return;
}
} else {
if (3 === instance_tag && nearestMounted.stateNode.hydrate) {
queuedTarget.blockedOn =
3 === nearestMounted.tag
? nearestMounted.stateNode.containerInfo
: null;
return;
}
}
}
}
queuedTarget.blockedOn = null;
}
function attemptReplayContinuousQueuedEvent(queuedEvent) {
if (null !== queuedEvent.blockedOn) {
return !1;
}
for (
var fiber$jscomp$10_targetContainers = queuedEvent.targetContainers;
0 < fiber$jscomp$10_targetContainers.length;
) {
var nextBlockedOn = attemptToDispatchEvent(
queuedEvent.domEventName,
queuedEvent.eventSystemFlags,
fiber$jscomp$10_targetContainers[0],
queuedEvent.nativeEvent
);
if (null !== nextBlockedOn) {
return (
(fiber$jscomp$10_targetContainers = getInstanceFromNode(nextBlockedOn)),
null !== fiber$jscomp$10_targetContainers &&
attemptContinuousHydration(fiber$jscomp$10_targetContainers),
(queuedEvent.blockedOn = nextBlockedOn),
!1
);
}
fiber$jscomp$10_targetContainers.shift();
}
return !0;
}
function attemptReplayContinuousQueuedEventInMap(queuedEvent, key, map) {
attemptReplayContinuousQueuedEvent(queuedEvent) && map.delete(key);
}
function replayUnblockedEvents() {
for (hasScheduledReplayAttempt = !1; 0 < queuedDiscreteEvents.length; ) {
var fiber = queuedDiscreteEvents[0];
if (null !== fiber.blockedOn) {
fiber = getInstanceFromNode(fiber.blockedOn);
null !== fiber && attemptDiscreteHydration(fiber);
break;
}
for (
var targetContainers = fiber.targetContainers;
0 < targetContainers.length;
) {
var nextBlockedOn = attemptToDispatchEvent(
fiber.domEventName,
fiber.eventSystemFlags,
targetContainers[0],
fiber.nativeEvent
);
if (null !== nextBlockedOn) {
fiber.blockedOn = nextBlockedOn;
break;
}
targetContainers.shift();
}
null === fiber.blockedOn && queuedDiscreteEvents.shift();
}
null !== queuedFocus &&
attemptReplayContinuousQueuedEvent(queuedFocus) &&
(queuedFocus = null);
null !== queuedDrag &&
attemptReplayContinuousQueuedEvent(queuedDrag) &&
(queuedDrag = null);
null !== queuedMouse &&
attemptReplayContinuousQueuedEvent(queuedMouse) &&
(queuedMouse = null);
queuedPointers.forEach(attemptReplayContinuousQueuedEventInMap);
queuedPointerCaptures.forEach(attemptReplayContinuousQueuedEventInMap);
}
function scheduleCallbackIfUnblocked(queuedEvent, unblocked) {
queuedEvent.blockedOn === unblocked &&
((queuedEvent.blockedOn = null),
hasScheduledReplayAttempt ||
((hasScheduledReplayAttempt = !0),
Scheduler.unstable_scheduleCallback(
Scheduler.unstable_NormalPriority,
replayUnblockedEvents
)));
}
function retryIfBlockedOn(unblocked) {
function unblock(queuedEvent) {
return scheduleCallbackIfUnblocked(queuedEvent, unblocked);
}
if (0 < queuedDiscreteEvents.length) {
scheduleCallbackIfUnblocked(queuedDiscreteEvents[0], unblocked);
for (var i$10_i = 1; i$10_i < queuedDiscreteEvents.length; i$10_i++) {
var queuedEvent$jscomp$5_queuedTarget = queuedDiscreteEvents[i$10_i];
queuedEvent$jscomp$5_queuedTarget.blockedOn === unblocked &&
(queuedEvent$jscomp$5_queuedTarget.blockedOn = null);
}
}
null !== queuedFocus && scheduleCallbackIfUnblocked(queuedFocus, unblocked);
null !== queuedDrag && scheduleCallbackIfUnblocked(queuedDrag, unblocked);
null !== queuedMouse && scheduleCallbackIfUnblocked(queuedMouse, unblocked);
queuedPointers.forEach(unblock);
queuedPointerCaptures.forEach(unblock);
for (i$10_i = 0; i$10_i < queuedExplicitHydrationTargets.length; i$10_i++) {
(queuedEvent$jscomp$5_queuedTarget =
queuedExplicitHydrationTargets[i$10_i]),
queuedEvent$jscomp$5_queuedTarget.blockedOn === unblocked &&
(queuedEvent$jscomp$5_queuedTarget.blockedOn = null);
}
for (
;
0 < queuedExplicitHydrationTargets.length &&
((i$10_i = queuedExplicitHydrationTargets[0]), null === i$10_i.blockedOn);
) {
attemptExplicitHydrationTarget(i$10_i),
null === i$10_i.blockedOn && queuedExplicitHydrationTargets.shift();
}
}
var Scheduler_scheduleCallback = Scheduler.unstable_scheduleCallback,
Scheduler_cancelCallback = Scheduler.unstable_cancelCallback,
Scheduler_shouldYield = Scheduler.unstable_shouldYield,
Scheduler_requestPaint = Scheduler.unstable_requestPaint,
Scheduler_now = Scheduler.unstable_now,
Scheduler_getCurrentPriorityLevel =
Scheduler.unstable_getCurrentPriorityLevel,
Scheduler_ImmediatePriority = Scheduler.unstable_ImmediatePriority,
Scheduler_UserBlockingPriority = Scheduler.unstable_UserBlockingPriority,
Scheduler_NormalPriority = Scheduler.unstable_NormalPriority,
Scheduler_LowPriority = Scheduler.unstable_LowPriority,
Scheduler_IdlePriority = Scheduler.unstable_IdlePriority,
requestPaint =
void 0 !== Scheduler_requestPaint ? Scheduler_requestPaint : function() {},
syncQueue = null,
isFlushingSyncQueue = !1,
initialTimeMs = Scheduler_now(),
now =
10000 > initialTimeMs
? Scheduler_now
: function() {
return Scheduler_now() - initialTimeMs;
};
function getCurrentPriorityLevel() {
switch (Scheduler_getCurrentPriorityLevel()) {
case Scheduler_ImmediatePriority:
return 99;
case Scheduler_UserBlockingPriority:
return 98;
case Scheduler_NormalPriority:
return 97;
case Scheduler_LowPriority:
return 96;
case Scheduler_IdlePriority:
return 95;
default:
throw Error(formatProdErrorMessage(332));
}
}
function reactPriorityToSchedulerPriority(reactPriorityLevel) {
switch (reactPriorityLevel) {
case 99:
return Scheduler_ImmediatePriority;
case 98:
return Scheduler_UserBlockingPriority;
case 97:
return Scheduler_NormalPriority;
case 96:
return Scheduler_LowPriority;
case 95:
return Scheduler_IdlePriority;
default:
throw Error(formatProdErrorMessage(332));
}
}
function scheduleCallback(priorityLevel_reactPriorityLevel, callback, options) {
priorityLevel_reactPriorityLevel = reactPriorityToSchedulerPriority(
priorityLevel_reactPriorityLevel
);
return Scheduler_scheduleCallback(
priorityLevel_reactPriorityLevel,
callback,
options
);
}
function flushSyncCallbackQueue() {
if (!isFlushingSyncQueue && null !== syncQueue) {
isFlushingSyncQueue = !0;
var i = 0,
previousLanePriority = currentUpdateLanePriority;
try {
var queue = syncQueue;
for (currentUpdateLanePriority = 12; i < queue.length; i++) {
var callback = queue[i];
do {
callback = callback(!0);
} while (null !== callback);
}
syncQueue = null;
} catch (error) {
throw (null !== syncQueue && (syncQueue = syncQueue.slice(i + 1)),
Scheduler_scheduleCallback(
Scheduler_ImmediatePriority,
flushSyncCallbackQueue
),
error);
} finally {
(currentUpdateLanePriority = previousLanePriority),
(isFlushingSyncQueue = !1);
}
}
return null;
}
var currentUpdateLanePriority = 0,
nextTransitionLane = 64,
nextRetryLane = 4194304,
return_highestLanePriority = 8;
function getHighestPriorityLanes(lanes) {
switch (lanes & -lanes) {
case 1:
return (return_highestLanePriority = 12), 1;
case 2:
return (return_highestLanePriority = 11), 2;
case 4:
return (return_highestLanePriority = 10), 4;
case 8:
return (return_highestLanePriority = 9), 8;
case 16:
return (return_highestLanePriority = 8), 16;
case 32:
return (return_highestLanePriority = 7), 32;
case 64:
case 128:
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
return (return_highestLanePriority = 6), lanes & 4194240;
case 4194304:
case 8388608:
case 16777216:
case 33554432:
case 67108864:
return (return_highestLanePriority = 5), lanes & 130023424;
case 134217728:
return (return_highestLanePriority = 4), 134217728;
case 268435456:
return (return_highestLanePriority = 3), 268435456;
case 536870912:
return (return_highestLanePriority = 2), 536870912;
case 1073741824:
return (return_highestLanePriority = 1), 1073741824;
default:
return (return_highestLanePriority = 8), lanes;
}
}
function lanePriorityToSchedulerPriority(lanePriority) {
switch (lanePriority) {
case 12:
return 99;
case 11:
case 10:
return 98;
case 9:
case 8:
case 7:
case 6:
case 4:
case 5:
return 97;
case 3:
case 2:
case 1:
return 95;
case 0:
return 90;
default:
throw Error(formatProdErrorMessage(358, lanePriority));
}
}
function getNextLanes(entanglements_root, entangledLanes_lanes) {
var nonIdleUnblockedLanes_pendingLanes_unblockedLanes =
entanglements_root.pendingLanes;
if (0 === nonIdleUnblockedLanes_pendingLanes_unblockedLanes) {
return (return_highestLanePriority = 0);
}
var nextLanes = 0,
index$11_nextLanePriority = 0,
expiredLanes_nonIdlePendingLanes = entanglements_root.expiredLanes,
lane_suspendedLanes_wipLanePriority = entanglements_root.suspendedLanes,
nonIdlePingedLanes_pingedLanes = entanglements_root.pingedLanes;
0 !== expiredLanes_nonIdlePendingLanes
? ((nextLanes = expiredLanes_nonIdlePendingLanes),
(index$11_nextLanePriority = return_highestLanePriority = 12))
: ((expiredLanes_nonIdlePendingLanes =
nonIdleUnblockedLanes_pendingLanes_unblockedLanes & 268435455),
0 !== expiredLanes_nonIdlePendingLanes
? ((nonIdleUnblockedLanes_pendingLanes_unblockedLanes =
expiredLanes_nonIdlePendingLanes &
~lane_suspendedLanes_wipLanePriority),
0 !== nonIdleUnblockedLanes_pendingLanes_unblockedLanes
? ((nextLanes = getHighestPriorityLanes(
nonIdleUnblockedLanes_pendingLanes_unblockedLanes
)),
(index$11_nextLanePriority = return_highestLanePriority))
: ((nonIdlePingedLanes_pingedLanes &= expiredLanes_nonIdlePendingLanes),
0 !== nonIdlePingedLanes_pingedLanes &&
((nextLanes = getHighestPriorityLanes(
nonIdlePingedLanes_pingedLanes
)),
(index$11_nextLanePriority = return_highestLanePriority))))
: ((nonIdleUnblockedLanes_pendingLanes_unblockedLanes &= ~lane_suspendedLanes_wipLanePriority),
0 !== nonIdleUnblockedLanes_pendingLanes_unblockedLanes
? ((nextLanes = getHighestPriorityLanes(
nonIdleUnblockedLanes_pendingLanes_unblockedLanes
)),
(index$11_nextLanePriority = return_highestLanePriority))
: 0 !== nonIdlePingedLanes_pingedLanes &&
((nextLanes = getHighestPriorityLanes(
nonIdlePingedLanes_pingedLanes
)),
(index$11_nextLanePriority = return_highestLanePriority))));
if (0 === nextLanes) {
return 0;
}
if (
0 !== entangledLanes_lanes &&
entangledLanes_lanes !== nextLanes &&
0 === (entangledLanes_lanes & lane_suspendedLanes_wipLanePriority)
) {
getHighestPriorityLanes(entangledLanes_lanes);
lane_suspendedLanes_wipLanePriority = return_highestLanePriority;
if (
index$11_nextLanePriority <= lane_suspendedLanes_wipLanePriority ||
(8 === index$11_nextLanePriority &&
6 === lane_suspendedLanes_wipLanePriority)
) {
return entangledLanes_lanes;
}
return_highestLanePriority = index$11_nextLanePriority;
}
entangledLanes_lanes = entanglements_root.entangledLanes;
if (0 !== entangledLanes_lanes) {
for (
entanglements_root = entanglements_root.entanglements,
entangledLanes_lanes &= nextLanes;
0 < entangledLanes_lanes;
) {
(index$11_nextLanePriority = 31 - clz32(entangledLanes_lanes)),
(lane_suspendedLanes_wipLanePriority = 1 << index$11_nextLanePriority),
(nextLanes |= entanglements_root[index$11_nextLanePriority]),
(entangledLanes_lanes &= ~lane_suspendedLanes_wipLanePriority);
}
}
return nextLanes;
}
function getLanesToRetrySynchronouslyOnError(everythingButOffscreen_root) {
everythingButOffscreen_root =
everythingButOffscreen_root.pendingLanes & -1073741825;
return 0 !== everythingButOffscreen_root
? everythingButOffscreen_root
: everythingButOffscreen_root & 1073741824
? 1073741824
: 0;
}
function findUpdateLane(lanePriority) {
switch (lanePriority) {
case 12:
return 1;
case 10:
return 4;
case 8:
return 16;
case 2:
return 536870912;
}
throw Error(formatProdErrorMessage(358, lanePriority));
}
function createLaneMap(initial) {
for (var laneMap = [], i = 0; 31 > i; i++) {
laneMap.push(initial);
}
return laneMap;
}
function markRootUpdated(eventTimes$jscomp$1_root, index, eventTime) {
eventTimes$jscomp$1_root.pendingLanes |= index;
536870912 !== index &&
((eventTimes$jscomp$1_root.suspendedLanes = 0),
(eventTimes$jscomp$1_root.pingedLanes = 0));
eventTimes$jscomp$1_root = eventTimes$jscomp$1_root.eventTimes;
index = 31 - clz32(index);
eventTimes$jscomp$1_root[index] = eventTime;
}
function markRootFinished(expirationTimes$jscomp$2_root, entanglements) {
var lanes = expirationTimes$jscomp$2_root.pendingLanes & ~entanglements;
expirationTimes$jscomp$2_root.pendingLanes = entanglements;
expirationTimes$jscomp$2_root.suspendedLanes = 0;
expirationTimes$jscomp$2_root.pingedLanes = 0;
expirationTimes$jscomp$2_root.expiredLanes &= entanglements;
expirationTimes$jscomp$2_root.mutableReadLanes &= entanglements;
expirationTimes$jscomp$2_root.entangledLanes &= entanglements;
entanglements = expirationTimes$jscomp$2_root.entanglements;
var eventTimes = expirationTimes$jscomp$2_root.eventTimes;
for (
expirationTimes$jscomp$2_root =
expirationTimes$jscomp$2_root.expirationTimes;
0 < lanes;
) {
var index$15 = 31 - clz32(lanes),
lane = 1 << index$15;
entanglements[index$15] = 0;
eventTimes[index$15] = -1;
expirationTimes$jscomp$2_root[index$15] = -1;
lanes &= ~lane;
}
}
function markRootEntangled(entanglements$jscomp$2_root, entangledLanes) {
var lanes = (entanglements$jscomp$2_root.entangledLanes |= entangledLanes);
for (
entanglements$jscomp$2_root = entanglements$jscomp$2_root.entanglements;
lanes;
) {
var index$16 = 31 - clz32(lanes),
lane = 1 << index$16;
(lane & entangledLanes) |
(entanglements$jscomp$2_root[index$16] & entangledLanes) &&
(entanglements$jscomp$2_root[index$16] |= entangledLanes);
lanes &= ~lane;
}
}
var clz32 = Math.clz32 ? Math.clz32 : clz32Fallback,
log = Math.log,
LN2 = Math.LN2;
function clz32Fallback(lanes) {
return 0 === lanes ? 32 : (31 - ((log(lanes) / LN2) | 0)) | 0;
}
var Scheduler_now$1 = Scheduler.unstable_now;
Scheduler_now$1();
var _enabled = !0;
function dispatchDiscreteEvent(
domEventName,
eventSystemFlags,
container,
nativeEvent
) {
isInsideEventHandler || flushDiscreteUpdatesImpl();
var fn = dispatchEvent,
prevIsInsideEventHandler = isInsideEventHandler;
isInsideEventHandler = !0;
try {
discreteUpdatesImpl(
fn,
domEventName,
eventSystemFlags,
container,
nativeEvent
);
} finally {
(isInsideEventHandler = prevIsInsideEventHandler) || finishEventHandler();
}
}
function dispatchContinuousEvent(
domEventName,
eventSystemFlags,
container,
nativeEvent
) {
var previousPriority = currentUpdateLanePriority;
try {
(currentUpdateLanePriority = 10),
dispatchEvent(domEventName, eventSystemFlags, container, nativeEvent);
} finally {
currentUpdateLanePriority = previousPriority;
}
}
function dispatchEvent(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
eventSystemFlags,
targetContainer,
nativeEvent
) {
if (_enabled) {
var allowReplay = 0 === (eventSystemFlags & 4);
if (
allowReplay &&
0 < queuedDiscreteEvents.length &&
-1 <
discreteReplayableEvents.indexOf(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent
)
) {
(domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent = createQueuedReplayableEvent(
null,
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
eventSystemFlags,
targetContainer,
nativeEvent
)),
queuedDiscreteEvents.push(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent
);
} else {
var blockedOn = attemptToDispatchEvent(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
eventSystemFlags,
targetContainer,
nativeEvent
);
if (null === blockedOn) {
allowReplay &&
clearIfContinuousEvent(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
nativeEvent
);
} else {
if (allowReplay) {
if (
-1 <
discreteReplayableEvents.indexOf(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent
)
) {
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent = createQueuedReplayableEvent(
blockedOn,
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
eventSystemFlags,
targetContainer,
nativeEvent
);
queuedDiscreteEvents.push(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent
);
return;
}
if (
queueIfContinuousEvent(
blockedOn,
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
eventSystemFlags,
targetContainer,
nativeEvent
)
) {
return;
}
clearIfContinuousEvent(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
nativeEvent
);
}
dispatchEventForPluginEventSystem(
domEventName$jscomp$8_queuedEvent$jscomp$inline_255_queuedEvent,
eventSystemFlags,
nativeEvent,
null,
targetContainer
);
}
}
}
}
function attemptToDispatchEvent(
domEventName,
eventSystemFlags,
targetContainer,
nativeEvent
) {
var instance$jscomp$1_nativeEventTarget_targetInst = getEventTarget(
nativeEvent
);
instance$jscomp$1_nativeEventTarget_targetInst = getClosestInstanceFromNode(
instance$jscomp$1_nativeEventTarget_targetInst
);
if (null !== instance$jscomp$1_nativeEventTarget_targetInst) {
var nearestMounted = getNearestMountedFiber(
instance$jscomp$1_nativeEventTarget_targetInst
);
if (null === nearestMounted) {
instance$jscomp$1_nativeEventTarget_targetInst = null;
} else {
var tag = nearestMounted.tag;
if (13 === tag) {
instance$jscomp$1_nativeEventTarget_targetInst = getSuspenseInstanceFromFiber(
nearestMounted
);
if (null !== instance$jscomp$1_nativeEventTarget_targetInst) {
return instance$jscomp$1_nativeEventTarget_targetInst;
}
instance$jscomp$1_nativeEventTarget_targetInst = null;
} else {
if (3 === tag) {
if (nearestMounted.stateNode.hydrate) {
return 3 === nearestMounted.tag
? nearestMounted.stateNode.containerInfo
: null;
}
instance$jscomp$1_nativeEventTarget_targetInst = null;
} else {
nearestMounted !== instance$jscomp$1_nativeEventTarget_targetInst &&
(instance$jscomp$1_nativeEventTarget_targetInst = null);
}
}
}
}
dispatchEventForPluginEventSystem(
domEventName,
eventSystemFlags,
nativeEvent,
instance$jscomp$1_nativeEventTarget_targetInst,
targetContainer
);
return null;
}
function getEventPriority(domEventName) {
switch (domEventName) {
case "cancel":
case "click":
case "close":
case "contextmenu":
case "copy":
case "cut":
case "auxclick":
case "dblclick":
case "dragend":
case "dragstart":
case "drop":
case "focusin":
case "focusout":
case "input":
case "invalid":
case "keydown":
case "keypress":
case "keyup":
case "mousedown":
case "mouseup":
case "paste":
case "pause":
case "play":
case "pointercancel":
case "pointerdown":
case "pointerup":
case "ratechange":
case "reset":
case "seeked":
case "submit":
case "touchcancel":
case "touchend":
case "touchstart":
case "volumechange":
case "change":
case "selectionchange":
case "textInput":
case "compositionstart":
case "compositionend":
case "compositionupdate":
case "beforeblur":
case "afterblur":
case "beforeinput":
case "blur":
case "fullscreenchange":
case "focus":
case "hashchange":
case "popstate":
case "select":
case "selectstart":
return 1;
case "drag":
case "dragenter":
case "dragexit":
case "dragleave":
case "dragover":
case "mousemove":
case "mouseout":
case "mouseover":
case "pointermove":
case "pointerout":
case "pointerover":
case "scroll":
case "toggle":
case "touchmove":
case "wheel":
case "mouseenter":
case "mouseleave":
case "pointerenter":
case "pointerleave":
return 4;
case "message":
switch (getCurrentPriorityLevel()) {
case 99:
return 1;
case 98:
return 4;
case 97:
case 96:
return 16;
case 95:
return 536870912;
default:
return 16;
}
default:
return 16;
}
}
var root = null,
startText = null,
fallbackText = null;
function getData() {
if (fallbackText) {
return fallbackText;
}
var start,
startValue = startText,
startLength = startValue.length,
end,
endValue = "value" in root ? root.value : root.textContent,
endLength = endValue.length;
for (
start = 0;
start < startLength && startValue[start] === endValue[start];
start++
) {}
var minEnd = startLength - start;
for (
end = 1;
end <= minEnd &&
startValue[startLength - end] === endValue[endLength - end];
end++
) {}
return (fallbackText = endValue.slice(start, 1 < end ? 1 - end : void 0));
}
function getEventCharCode(charCode_nativeEvent) {
var keyCode = charCode_nativeEvent.keyCode;
"charCode" in charCode_nativeEvent
? ((charCode_nativeEvent = charCode_nativeEvent.charCode),
0 === charCode_nativeEvent &&
13 === keyCode &&
(charCode_nativeEvent = 13))
: (charCode_nativeEvent = keyCode);
10 === charCode_nativeEvent && (charCode_nativeEvent = 13);
return 32 <= charCode_nativeEvent || 13 === charCode_nativeEvent
? charCode_nativeEvent
: 0;
}
function functionThatReturnsTrue() {
return !0;
}
function functionThatReturnsFalse() {
return !1;
}
function createSyntheticEvent(Interface) {
function SyntheticBaseEvent(
normalize_reactName,
reactEventType,
targetInst,
nativeEvent,
nativeEventTarget
) {
this._reactName = normalize_reactName;
this._targetInst = targetInst;
this.type = reactEventType;
this.nativeEvent = nativeEvent;
this.target = nativeEventTarget;
this.currentTarget = null;
for (var propName in Interface) {
Interface.hasOwnProperty(propName) &&
((normalize_reactName = Interface[propName]),
(this[propName] = normalize_reactName
? normalize_reactName(nativeEvent)
: nativeEvent[propName]));
}
this.isDefaultPrevented = (null != nativeEvent.defaultPrevented
? nativeEvent.defaultPrevented
: !1 === nativeEvent.returnValue)
? functionThatReturnsTrue
: functionThatReturnsFalse;
this.isPropagationStopped = functionThatReturnsFalse;
return this;
}
Object.assign(SyntheticBaseEvent.prototype, {
preventDefault: function() {
this.defaultPrevented = !0;
var event = this.nativeEvent;
event &&
(event.preventDefault
? event.preventDefault()
: "unknown" !== typeof event.returnValue && (event.returnValue = !1),
(this.isDefaultPrevented = functionThatReturnsTrue));
},
stopPropagation: function() {
var event = this.nativeEvent;
event &&
(event.stopPropagation
? event.stopPropagation()
: "unknown" !== typeof event.cancelBubble &&
(event.cancelBubble = !0),
(this.isPropagationStopped = functionThatReturnsTrue));
},
persist: function() {},
isPersistent: functionThatReturnsTrue
});
return SyntheticBaseEvent;
}
var EventInterface = {
eventPhase: 0,
bubbles: 0,
cancelable: 0,
timeStamp: function(event) {
return event.timeStamp || Date.now();
},
defaultPrevented: 0,
isTrusted: 0
},
SyntheticEvent = createSyntheticEvent(EventInterface),
UIEventInterface = Object.assign({}, EventInterface, { view: 0, detail: 0 }),
SyntheticUIEvent = createSyntheticEvent(UIEventInterface),
lastMovementX,
lastMovementY,
lastMouseEvent,
MouseEventInterface = Object.assign({}, UIEventInterface, {
screenX: 0,
screenY: 0,
clientX: 0,
clientY: 0,
pageX: 0,
pageY: 0,
ctrlKey: 0,
shiftKey: 0,
altKey: 0,
metaKey: 0,
getModifierState: getEventModifierState,
button: 0,
buttons: 0,
relatedTarget: function(event) {
return void 0 === event.relatedTarget
? event.fromElement === event.srcElement
? event.toElement
: event.fromElement
: event.relatedTarget;
},
movementX: function(event) {
if ("movementX" in event) {
return event.movementX;
}
event !== lastMouseEvent &&
(lastMouseEvent && "mousemove" === event.type
? ((lastMovementX = event.screenX - lastMouseEvent.screenX),
(lastMovementY = event.screenY - lastMouseEvent.screenY))
: (lastMovementY = lastMovementX = 0),
(lastMouseEvent = event));
return lastMovementX;
},
movementY: function(event) {
return "movementY" in event ? event.movementY : lastMovementY;
}
}),
SyntheticMouseEvent = createSyntheticEvent(MouseEventInterface),
DragEventInterface = Object.assign({}, MouseEventInterface, {
dataTransfer: 0
}),
SyntheticDragEvent = createSyntheticEvent(DragEventInterface),
FocusEventInterface = Object.assign({}, UIEventInterface, {
relatedTarget: 0
}),
SyntheticFocusEvent = createSyntheticEvent(FocusEventInterface),
AnimationEventInterface = Object.assign({}, EventInterface, {
animationName: 0,
elapsedTime: 0,
pseudoElement: 0
}),
SyntheticAnimationEvent = createSyntheticEvent(AnimationEventInterface),
ClipboardEventInterface = Object.assign({}, EventInterface, {
clipboardData: function(event) {
return "clipboardData" in event
? event.clipboardData
: window.clipboardData;
}
}),
SyntheticClipboardEvent = createSyntheticEvent(ClipboardEventInterface),
CompositionEventInterface = Object.assign({}, EventInterface, { data: 0 }),
SyntheticCompositionEvent = createSyntheticEvent(CompositionEventInterface),
normalizeKey = {
<