diff --git a/compiled/facebook-www/REVISION b/compiled/facebook-www/REVISION index 7566c9c37fcd6..d5a03ab8ad720 100644 --- a/compiled/facebook-www/REVISION +++ b/compiled/facebook-www/REVISION @@ -1 +1 @@ -1c02b9d2bdc18091cc6afec810fc1b361f00abdd +113ab9af08c46e8a548a397154f5c9dfeb96ab6a diff --git a/compiled/facebook-www/React-prod.classic.js b/compiled/facebook-www/React-prod.classic.js index 3fec902975100..d08a393122d9d 100644 --- a/compiled/facebook-www/React-prod.classic.js +++ b/compiled/facebook-www/React-prod.classic.js @@ -633,4 +633,4 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactCurrentDispatcher.current.useTransition(); }; -exports.version = "18.3.0-www-classic-a1436691"; +exports.version = "18.3.0-www-classic-f938cefa"; diff --git a/compiled/facebook-www/React-prod.modern.js b/compiled/facebook-www/React-prod.modern.js index 83b80e32c1ea0..d201c145c98fc 100644 --- a/compiled/facebook-www/React-prod.modern.js +++ b/compiled/facebook-www/React-prod.modern.js @@ -625,4 +625,4 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactCurrentDispatcher.current.useTransition(); }; -exports.version = "18.3.0-www-modern-fac556b3"; +exports.version = "18.3.0-www-modern-a7ff7332"; diff --git a/compiled/facebook-www/React-profiling.classic.js b/compiled/facebook-www/React-profiling.classic.js index aa82cb7b8498b..cbf0275eab1ef 100644 --- a/compiled/facebook-www/React-profiling.classic.js +++ b/compiled/facebook-www/React-profiling.classic.js @@ -637,7 +637,7 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactCurrentDispatcher.current.useTransition(); }; -exports.version = "18.3.0-www-classic-cf792bcf"; +exports.version = "18.3.0-www-classic-c1c1744a"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled/facebook-www/React-profiling.modern.js b/compiled/facebook-www/React-profiling.modern.js index e84fe6881e84f..ced6357581184 100644 --- a/compiled/facebook-www/React-profiling.modern.js +++ b/compiled/facebook-www/React-profiling.modern.js @@ -629,7 +629,7 @@ exports.useSyncExternalStore = function ( exports.useTransition = function () { return ReactCurrentDispatcher.current.useTransition(); }; -exports.version = "18.3.0-www-modern-54bc703c"; +exports.version = "18.3.0-www-modern-120f741e"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled/facebook-www/ReactART-dev.modern.js b/compiled/facebook-www/ReactART-dev.modern.js index e4e8e1bcb7624..f0d61565bda0e 100644 --- a/compiled/facebook-www/ReactART-dev.modern.js +++ b/compiled/facebook-www/ReactART-dev.modern.js @@ -66,7 +66,7 @@ if (__DEV__) { return self; } - var ReactVersion = "18.3.0-www-modern-b6d2fca1"; + var ReactVersion = "18.3.0-www-modern-c0bbf979"; var LegacyRoot = 0; var ConcurrentRoot = 1; diff --git a/compiled/facebook-www/ReactDOM-dev.classic.js b/compiled/facebook-www/ReactDOM-dev.classic.js index cf0d141fccba3..37a7a5efb6847 100644 --- a/compiled/facebook-www/ReactDOM-dev.classic.js +++ b/compiled/facebook-www/ReactDOM-dev.classic.js @@ -10799,7 +10799,7 @@ if (__DEV__) { return status === "fulfilled" || status === "rejected"; } - function noop$2() {} + function noop$3() {} function trackUsedThenable(thenableState, thenable, index) { if (ReactCurrentActQueue$2.current !== null) { @@ -10845,7 +10845,7 @@ if (__DEV__) { } // Avoid an unhandled rejection errors for the Promises that we'll // intentionally ignore. - thenable.then(noop$2, noop$2); + thenable.then(noop$3, noop$3); thenable = previous; } } // We use an expando to track the status and result of a thenable so that we @@ -10874,7 +10874,7 @@ if (__DEV__) { // some custom userspace implementation. We treat it as "pending". // Attach a dummy listener, to ensure that any lazy initialization can // happen. Flight lazily parses JSON when the value is actually awaited. - thenable.then(noop$2, noop$2); + thenable.then(noop$3, noop$3); } else { // This is an uncached thenable that we haven't seen before. // Detect infinite ping loops caused by uncached promises. @@ -36046,7 +36046,7 @@ if (__DEV__) { return root; } - var ReactVersion = "18.3.0-www-classic-375d7b0a"; + var ReactVersion = "18.3.0-www-classic-e13660d6"; function createPortal$1( children, @@ -40821,7 +40821,7 @@ if (__DEV__) { } } - function noop$1() {} + function noop$2() {} function trapClickOnNonInteractiveElement(node) { // Mobile Safari does not fire properly bubble click events on @@ -40833,7 +40833,7 @@ if (__DEV__) { // bookkeeping for it. Not sure if we need to clear it when the listener is // removed. // TODO: Only do this for the relevant Safaris maybe? - node.onclick = noop$1; + node.onclick = noop$2; } var xlinkNamespace = "http://www.w3.org/1999/xlink"; var xmlNamespace = "http://www.w3.org/XML/1998/namespace"; @@ -43868,6 +43868,27 @@ if (__DEV__) { } } + function noop$1() {} + + var DefaultDispatcher = { + prefetchDNS: noop$1, + preconnect: noop$1, + preload: noop$1, + preloadModule: noop$1, + preinitScript: noop$1, + preinitStyle: noop$1, + preinitModuleScript: noop$1 + }; + var Internals = { + usingClientEntryPoint: false, + Events: null, + ReactDOMCurrentDispatcher: { + current: DefaultDispatcher + } + }; + + var ReactDOMCurrentDispatcher$1 = Internals.ReactDOMCurrentDispatcher; // Unused + var SUPPRESS_HYDRATION_WARNING = "suppressHydrationWarning"; var SUSPENSE_START_DATA = "$"; var SUSPENSE_END_DATA = "/$"; @@ -45429,11 +45450,10 @@ if (__DEV__) { function getDocumentFromRoot(root) { return root.ownerDocument || root; - } // We want this to be the default dispatcher on ReactDOMSharedInternals but we don't want to mutate - // internals in Module scope. Instead we export it and Internals will import it. There is already a cycle - // from Internals -> ReactDOM -> HostConfig -> Internals so this doesn't introduce a new one. + } - var ReactDOMClientDispatcher = { + var previousDispatcher = ReactDOMCurrentDispatcher$1.current; + ReactDOMCurrentDispatcher$1.current = { prefetchDNS: prefetchDNS$1, preconnect: preconnect$1, preload: preload$1, @@ -45448,14 +45468,16 @@ if (__DEV__) { // This is notable because nowhere else in ReactDOM do we actually reference the global document or window // because we may be rendering inside an iframe. - function getDocumentForImperativeFloatMethods() { - return document; + var globalDocument = typeof document === "undefined" ? null : document; + + function getGlobalDocument() { + return globalDocument; } function preconnectAs(rel, href, crossOrigin) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + var ownerDocument = getGlobalDocument(); - if (typeof href === "string" && href) { + if (ownerDocument && typeof href === "string" && href) { var limitedEscapedHref = escapeSelectorAttributeValueInsideDoubleQuotes(href); var key = 'link[rel="' + rel + '"][href="' + limitedEscapedHref + '"]'; @@ -45483,17 +45505,20 @@ if (__DEV__) { } function prefetchDNS$1(href) { + previousDispatcher.prefetchDNS(href); preconnectAs("dns-prefetch", href, null); } function preconnect$1(href, crossOrigin) { + previousDispatcher.preconnect(href, crossOrigin); preconnectAs("preconnect", href, crossOrigin); } function preload$1(href, as, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preload(href, as, options); + var ownerDocument = getGlobalDocument(); - if (href && as && ownerDocument) { + if (ownerDocument && href && as) { var preloadSelector = 'link[rel="preload"][as="' + escapeSelectorAttributeValueInsideDoubleQuotes(as) + @@ -45587,9 +45612,10 @@ if (__DEV__) { } function preloadModule$1(href, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preloadModule(href, options); + var ownerDocument = getGlobalDocument(); - if (href) { + if (ownerDocument && href) { var as = options && typeof options.as === "string" ? options.as : "script"; var preloadSelector = @@ -45652,9 +45678,10 @@ if (__DEV__) { } function preinitStyle(href, precedence, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preinitStyle(href, precedence, options); + var ownerDocument = getGlobalDocument(); - if (href) { + if (ownerDocument && href) { var styles = getResourcesFromRoot(ownerDocument).hoistableStyles; var key = getStyleKey(href); precedence = precedence || "default"; // Check if this resource already exists @@ -45724,9 +45751,10 @@ if (__DEV__) { } function preinitScript(src, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preinitScript(src, options); + var ownerDocument = getGlobalDocument(); - if (src) { + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts; var key = getScriptKey(src); // Check if this resource already exists @@ -45776,9 +45804,10 @@ if (__DEV__) { } function preinitModuleScript(src, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preinitModuleScript(src, options); + var ownerDocument = getGlobalDocument(); - if (src) { + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts; var key = getScriptKey(src); // Check if this resource already exists @@ -48086,20 +48115,6 @@ if (__DEV__) { } } - var Internals = { - usingClientEntryPoint: false, - Events: null, - Dispatcher: { - current: null - } - }; - - var Dispatcher$1 = Internals.Dispatcher; - - if (typeof document !== "undefined") { - // Set the default dispatcher to the client dispatcher - Dispatcher$1.current = ReactDOMClientDispatcher; - } /* global reportError */ var defaultOnRecoverableError = @@ -48247,7 +48262,6 @@ if (__DEV__) { transitionCallbacks ); markContainerAsRoot(root.current, container); - Dispatcher$1.current = ReactDOMClientDispatcher; var rootContainerElement = container.nodeType === COMMENT_NODE ? container.parentNode : container; listenToAllSupportedEvents(rootContainerElement); // $FlowFixMe[invalid-constructor] Flow no longer supports calling new on functions @@ -48333,8 +48347,7 @@ if (__DEV__) { transitionCallbacks, formState ); - markContainerAsRoot(root.current, container); - Dispatcher$1.current = ReactDOMClientDispatcher; // This can't be a comment node since hydration doesn't work on comment nodes anyway. + markContainerAsRoot(root.current, container); // This can't be a comment node since hydration doesn't work on comment nodes anyway. listenToAllSupportedEvents(container); // $FlowFixMe[invalid-constructor] Flow no longer supports calling new on functions @@ -48915,7 +48928,7 @@ if (__DEV__) { return undefined; } - var Dispatcher = Internals.Dispatcher; + var ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher; function prefetchDNS(href) { { if (typeof href !== "string" || !href) { @@ -48943,10 +48956,8 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { - dispatcher.prefetchDNS(href); + if (typeof href === "string") { + ReactDOMCurrentDispatcher.current.prefetchDNS(href); } // We don't error because preconnect needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical // so we favor silent bailout over warning or erroring. @@ -48971,13 +48982,11 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { + if (typeof href === "string") { var crossOrigin = options ? getCrossOriginString(options.crossOrigin) : null; - dispatcher.preconnect(href, crossOrigin); + ReactDOMCurrentDispatcher.current.preconnect(href, crossOrigin); } // We don't error because preconnect needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical // so we favor silent bailout over warning or erroring. @@ -49013,10 +49022,7 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - if ( - dispatcher && typeof href === "string" && // We check existence because we cannot enforce this function is actually called with the stated type typeof options === "object" && options !== null && @@ -49024,7 +49030,7 @@ if (__DEV__) { ) { var as = options.as; var crossOrigin = getCrossOriginStringAs(as, options.crossOrigin); - dispatcher.preload(href, as, { + ReactDOMCurrentDispatcher.current.preload(href, as, { crossOrigin: crossOrigin, integrity: typeof options.integrity === "string" @@ -49088,15 +49094,13 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { + if (typeof href === "string") { if (options) { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preloadModule(href, { + ReactDOMCurrentDispatcher.current.preloadModule(href, { as: typeof options.as === "string" && options.as !== "script" ? options.as @@ -49108,7 +49112,7 @@ if (__DEV__) { : undefined }); } else { - dispatcher.preloadModule(href); + ReactDOMCurrentDispatcher.current.preloadModule(href); } } // We don't error because preload needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical @@ -49134,10 +49138,7 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - if ( - dispatcher && typeof href === "string" && options && typeof options.as === "string" @@ -49152,7 +49153,7 @@ if (__DEV__) { : undefined; if (as === "style") { - dispatcher.preinitStyle( + ReactDOMCurrentDispatcher.current.preinitStyle( href, typeof options.precedence === "string" ? options.precedence @@ -49164,7 +49165,7 @@ if (__DEV__) { } ); } else if (as === "script") { - dispatcher.preinitScript(href, { + ReactDOMCurrentDispatcher.current.preinitScript(href, { crossOrigin: crossOrigin, integrity: integrity, fetchPriority: fetchPriority, @@ -49229,16 +49230,14 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { + if (typeof href === "string") { if (typeof options === "object" && options !== null) { if (options.as == null || options.as === "script") { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preinitModuleScript(href, { + ReactDOMCurrentDispatcher.current.preinitModuleScript(href, { crossOrigin: crossOrigin, integrity: typeof options.integrity === "string" @@ -49249,7 +49248,7 @@ if (__DEV__) { }); } } else if (options == null) { - dispatcher.preinitModuleScript(href); + ReactDOMCurrentDispatcher.current.preinitModuleScript(href); } } // We don't error because preinit needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical diff --git a/compiled/facebook-www/ReactDOM-dev.modern.js b/compiled/facebook-www/ReactDOM-dev.modern.js index 599ce0e908791..a89385b064312 100644 --- a/compiled/facebook-www/ReactDOM-dev.modern.js +++ b/compiled/facebook-www/ReactDOM-dev.modern.js @@ -27,11 +27,22 @@ if (__DEV__) { var React = require("react"); var Scheduler = require("scheduler"); + function noop$3() {} + + var DefaultDispatcher = { + prefetchDNS: noop$3, + preconnect: noop$3, + preload: noop$3, + preloadModule: noop$3, + preinitScript: noop$3, + preinitStyle: noop$3, + preinitModuleScript: noop$3 + }; var Internals = { usingClientEntryPoint: false, Events: null, - Dispatcher: { - current: null + ReactDOMCurrentDispatcher: { + current: DefaultDispatcher } }; @@ -35882,7 +35893,7 @@ if (__DEV__) { return root; } - var ReactVersion = "18.3.0-www-modern-0ae1c4c8"; + var ReactVersion = "18.3.0-www-modern-06a38f42"; function createPortal$1( children, @@ -44505,6 +44516,8 @@ if (__DEV__) { } } + var ReactDOMCurrentDispatcher$1 = Internals.ReactDOMCurrentDispatcher; // Unused + var SUPPRESS_HYDRATION_WARNING = "suppressHydrationWarning"; var SUSPENSE_START_DATA = "$"; var SUSPENSE_END_DATA = "/$"; @@ -46066,11 +46079,10 @@ if (__DEV__) { function getDocumentFromRoot(root) { return root.ownerDocument || root; - } // We want this to be the default dispatcher on ReactDOMSharedInternals but we don't want to mutate - // internals in Module scope. Instead we export it and Internals will import it. There is already a cycle - // from Internals -> ReactDOM -> HostConfig -> Internals so this doesn't introduce a new one. + } - var ReactDOMClientDispatcher = { + var previousDispatcher = ReactDOMCurrentDispatcher$1.current; + ReactDOMCurrentDispatcher$1.current = { prefetchDNS: prefetchDNS$1, preconnect: preconnect$1, preload: preload$1, @@ -46085,14 +46097,16 @@ if (__DEV__) { // This is notable because nowhere else in ReactDOM do we actually reference the global document or window // because we may be rendering inside an iframe. - function getDocumentForImperativeFloatMethods() { - return document; + var globalDocument = typeof document === "undefined" ? null : document; + + function getGlobalDocument() { + return globalDocument; } function preconnectAs(rel, href, crossOrigin) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + var ownerDocument = getGlobalDocument(); - if (typeof href === "string" && href) { + if (ownerDocument && typeof href === "string" && href) { var limitedEscapedHref = escapeSelectorAttributeValueInsideDoubleQuotes(href); var key = 'link[rel="' + rel + '"][href="' + limitedEscapedHref + '"]'; @@ -46120,17 +46134,20 @@ if (__DEV__) { } function prefetchDNS$1(href) { + previousDispatcher.prefetchDNS(href); preconnectAs("dns-prefetch", href, null); } function preconnect$1(href, crossOrigin) { + previousDispatcher.preconnect(href, crossOrigin); preconnectAs("preconnect", href, crossOrigin); } function preload$1(href, as, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preload(href, as, options); + var ownerDocument = getGlobalDocument(); - if (href && as && ownerDocument) { + if (ownerDocument && href && as) { var preloadSelector = 'link[rel="preload"][as="' + escapeSelectorAttributeValueInsideDoubleQuotes(as) + @@ -46224,9 +46241,10 @@ if (__DEV__) { } function preloadModule$1(href, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preloadModule(href, options); + var ownerDocument = getGlobalDocument(); - if (href) { + if (ownerDocument && href) { var as = options && typeof options.as === "string" ? options.as : "script"; var preloadSelector = @@ -46289,9 +46307,10 @@ if (__DEV__) { } function preinitStyle(href, precedence, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preinitStyle(href, precedence, options); + var ownerDocument = getGlobalDocument(); - if (href) { + if (ownerDocument && href) { var styles = getResourcesFromRoot(ownerDocument).hoistableStyles; var key = getStyleKey(href); precedence = precedence || "default"; // Check if this resource already exists @@ -46361,9 +46380,10 @@ if (__DEV__) { } function preinitScript(src, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preinitScript(src, options); + var ownerDocument = getGlobalDocument(); - if (src) { + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts; var key = getScriptKey(src); // Check if this resource already exists @@ -46413,9 +46433,10 @@ if (__DEV__) { } function preinitModuleScript(src, options) { - var ownerDocument = getDocumentForImperativeFloatMethods(); + previousDispatcher.preinitModuleScript(src, options); + var ownerDocument = getGlobalDocument(); - if (src) { + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts; var key = getScriptKey(src); // Check if this resource already exists @@ -47577,12 +47598,6 @@ if (__DEV__) { var NotPendingTransition = NotPending; - var Dispatcher$1 = Internals.Dispatcher; - - if (typeof document !== "undefined") { - // Set the default dispatcher to the client dispatcher - Dispatcher$1.current = ReactDOMClientDispatcher; - } /* global reportError */ var defaultOnRecoverableError = @@ -47730,7 +47745,6 @@ if (__DEV__) { transitionCallbacks ); markContainerAsRoot(root.current, container); - Dispatcher$1.current = ReactDOMClientDispatcher; var rootContainerElement = container.nodeType === COMMENT_NODE ? container.parentNode : container; listenToAllSupportedEvents(rootContainerElement); // $FlowFixMe[invalid-constructor] Flow no longer supports calling new on functions @@ -47816,8 +47830,7 @@ if (__DEV__) { transitionCallbacks, formState ); - markContainerAsRoot(root.current, container); - Dispatcher$1.current = ReactDOMClientDispatcher; // This can't be a comment node since hydration doesn't work on comment nodes anyway. + markContainerAsRoot(root.current, container); // This can't be a comment node since hydration doesn't work on comment nodes anyway. listenToAllSupportedEvents(container); // $FlowFixMe[invalid-constructor] Flow no longer supports calling new on functions @@ -47977,7 +47990,7 @@ if (__DEV__) { return undefined; } - var Dispatcher = Internals.Dispatcher; + var ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher; function prefetchDNS(href) { { if (typeof href !== "string" || !href) { @@ -48005,10 +48018,8 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { - dispatcher.prefetchDNS(href); + if (typeof href === "string") { + ReactDOMCurrentDispatcher.current.prefetchDNS(href); } // We don't error because preconnect needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical // so we favor silent bailout over warning or erroring. @@ -48033,13 +48044,11 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { + if (typeof href === "string") { var crossOrigin = options ? getCrossOriginString(options.crossOrigin) : null; - dispatcher.preconnect(href, crossOrigin); + ReactDOMCurrentDispatcher.current.preconnect(href, crossOrigin); } // We don't error because preconnect needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical // so we favor silent bailout over warning or erroring. @@ -48075,10 +48084,7 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - if ( - dispatcher && typeof href === "string" && // We check existence because we cannot enforce this function is actually called with the stated type typeof options === "object" && options !== null && @@ -48086,7 +48092,7 @@ if (__DEV__) { ) { var as = options.as; var crossOrigin = getCrossOriginStringAs(as, options.crossOrigin); - dispatcher.preload(href, as, { + ReactDOMCurrentDispatcher.current.preload(href, as, { crossOrigin: crossOrigin, integrity: typeof options.integrity === "string" @@ -48150,15 +48156,13 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { + if (typeof href === "string") { if (options) { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preloadModule(href, { + ReactDOMCurrentDispatcher.current.preloadModule(href, { as: typeof options.as === "string" && options.as !== "script" ? options.as @@ -48170,7 +48174,7 @@ if (__DEV__) { : undefined }); } else { - dispatcher.preloadModule(href); + ReactDOMCurrentDispatcher.current.preloadModule(href); } } // We don't error because preload needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical @@ -48196,10 +48200,7 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - if ( - dispatcher && typeof href === "string" && options && typeof options.as === "string" @@ -48214,7 +48215,7 @@ if (__DEV__) { : undefined; if (as === "style") { - dispatcher.preinitStyle( + ReactDOMCurrentDispatcher.current.preinitStyle( href, typeof options.precedence === "string" ? options.precedence @@ -48226,7 +48227,7 @@ if (__DEV__) { } ); } else if (as === "script") { - dispatcher.preinitScript(href, { + ReactDOMCurrentDispatcher.current.preinitScript(href, { crossOrigin: crossOrigin, integrity: integrity, fetchPriority: fetchPriority, @@ -48291,16 +48292,14 @@ if (__DEV__) { } } - var dispatcher = Dispatcher.current; - - if (dispatcher && typeof href === "string") { + if (typeof href === "string") { if (typeof options === "object" && options !== null) { if (options.as == null || options.as === "script") { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preinitModuleScript(href, { + ReactDOMCurrentDispatcher.current.preinitModuleScript(href, { crossOrigin: crossOrigin, integrity: typeof options.integrity === "string" @@ -48311,7 +48310,7 @@ if (__DEV__) { }); } } else if (options == null) { - dispatcher.preinitModuleScript(href); + ReactDOMCurrentDispatcher.current.preinitModuleScript(href); } } // We don't error because preinit needs to be resilient to being called in a variety of scopes // and the runtime may not be capable of responding. The function is optimistic and not critical diff --git a/compiled/facebook-www/ReactDOM-prod.classic.js b/compiled/facebook-www/ReactDOM-prod.classic.js index 7fe59f94b239b..da580ad70561d 100644 --- a/compiled/facebook-www/ReactDOM-prod.classic.js +++ b/compiled/facebook-www/ReactDOM-prod.classic.js @@ -2503,12 +2503,12 @@ function isThenableResolved(thenable) { thenable = thenable.status; return "fulfilled" === thenable || "rejected" === thenable; } -function noop$2() {} +function noop$3() {} function trackUsedThenable(thenableState, thenable, index) { index = thenableState[index]; void 0 === index ? thenableState.push(thenable) - : index !== thenable && (thenable.then(noop$2, noop$2), (thenable = index)); + : index !== thenable && (thenable.then(noop$3, noop$3), (thenable = index)); switch (thenable.status) { case "fulfilled": return thenable.value; @@ -2518,7 +2518,7 @@ function trackUsedThenable(thenableState, thenable, index) { throw Error(formatProdErrorMessage(483)); throw thenableState; default: - if ("string" === typeof thenable.status) thenable.then(noop$2, noop$2); + if ("string" === typeof thenable.status) thenable.then(noop$3, noop$3); else { thenableState = workInProgressRoot; if (null !== thenableState && 100 < thenableState.shellSuspendCounter) @@ -8550,7 +8550,7 @@ function insertOrAppendPlacementNodeIntoContainer(node, before, parent) { (parent = parent._reactRootContainer), (null !== parent && void 0 !== parent) || null !== before.onclick || - (before.onclick = noop$1)); + (before.onclick = noop$2)); else if (4 !== tag && 27 !== tag && ((node = node.child), null !== node)) for ( insertOrAppendPlacementNodeIntoContainer(node, before, parent), @@ -14380,7 +14380,7 @@ function checkForUnmatchedText(serverText, clientText, isConcurrentMode) { ) throw Error(formatProdErrorMessage(425)); } -function noop$1() {} +function noop$2() {} function setProp(domElement, tag, key, value, props, prevValue) { switch (key) { case "children": @@ -14478,7 +14478,7 @@ function setProp(domElement, tag, key, value, props, prevValue) { domElement.setAttribute(key, value); break; case "onClick": - null != value && (domElement.onclick = noop$1); + null != value && (domElement.onclick = noop$2); break; case "onScroll": null != value && listenToNonDelegatedEvent("scroll", domElement); @@ -14724,7 +14724,7 @@ function setPropOnCustomElement(domElement, tag, key, value, props, prevValue) { null != value && listenToNonDelegatedEvent("scrollend", domElement); break; case "onClick": - null != value && (domElement.onclick = noop$1); + null != value && (domElement.onclick = noop$2); break; case "suppressContentEditableWarning": case "suppressHydrationWarning": @@ -15300,7 +15300,24 @@ function updateProperties(domElement, tag, lastProps, nextProps) { (null == propKey$220 && null == propKey) || setProp(domElement, tag, lastProp, propKey$220, nextProps, propKey); } -var eventsEnabled = null, +function noop$1() {} +var Internals = { + usingClientEntryPoint: !1, + Events: null, + ReactDOMCurrentDispatcher: { + current: { + prefetchDNS: noop$1, + preconnect: noop$1, + preload: noop$1, + preloadModule: noop$1, + preinitScript: noop$1, + preinitStyle: noop$1, + preinitModuleScript: noop$1 + } + } + }, + ReactDOMCurrentDispatcher$1 = Internals.ReactDOMCurrentDispatcher, + eventsEnabled = null, selectionInformation = null; function getOwnerDocumentFromRootContainer(rootContainerElement) { return 9 === rootContainerElement.nodeType @@ -15634,7 +15651,7 @@ function hydrateInstance( (instance.textContent = internalInstanceHandle)); null != props.onScroll && listenToNonDelegatedEvent("scroll", instance); null != props.onScrollEnd && listenToNonDelegatedEvent("scrollend", instance); - null != props.onClick && (instance.onclick = noop$1); + null != props.onClick && (instance.onclick = noop$2); } function getParentSuspenseInstance(targetInstance) { targetInstance = targetInstance.previousSibling; @@ -15683,7 +15700,8 @@ function getHoistableRoot(container) { ? container.getRootNode() : container.ownerDocument; } -var ReactDOMClientDispatcher = { +var previousDispatcher = ReactDOMCurrentDispatcher$1.current; +ReactDOMCurrentDispatcher$1.current = { prefetchDNS: prefetchDNS$1, preconnect: preconnect$1, preload: preload$1, @@ -15692,9 +15710,10 @@ var ReactDOMClientDispatcher = { preinitScript: preinitScript, preinitModuleScript: preinitModuleScript }; +var globalDocument = "undefined" === typeof document ? null : document; function preconnectAs(rel, href, crossOrigin) { - var ownerDocument = document; - if ("string" === typeof href && href) { + var ownerDocument = globalDocument; + if (ownerDocument && "string" === typeof href && href) { var limitedEscapedHref = escapeSelectorAttributeValueInsideDoubleQuotes(href); limitedEscapedHref = @@ -15712,14 +15731,17 @@ function preconnectAs(rel, href, crossOrigin) { } } function prefetchDNS$1(href) { + previousDispatcher.prefetchDNS(href); preconnectAs("dns-prefetch", href, null); } function preconnect$1(href, crossOrigin) { + previousDispatcher.preconnect(href, crossOrigin); preconnectAs("preconnect", href, crossOrigin); } function preload$1(href, as, options) { - var ownerDocument = document; - if (href && as && ownerDocument) { + previousDispatcher.preload(href, as, options); + var ownerDocument = globalDocument; + if (ownerDocument && href && as) { var preloadSelector = 'link[rel="preload"][as="' + escapeSelectorAttributeValueInsideDoubleQuotes(as) + @@ -15778,8 +15800,9 @@ function preload$1(href, as, options) { } } function preloadModule$1(href, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preloadModule(href, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var as = options && "string" === typeof options.as ? options.as : "script", preloadSelector = 'link[rel="modulepreload"][as="' + @@ -15821,8 +15844,9 @@ function preloadModule$1(href, options) { } } function preinitStyle(href, precedence, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preinitStyle(href, precedence, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var styles = getResourcesFromRoot(ownerDocument).hoistableStyles, key = getStyleKey(href); precedence = precedence || "default"; @@ -15869,8 +15893,9 @@ function preinitStyle(href, precedence, options) { } } function preinitScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -15894,8 +15919,9 @@ function preinitScript(src, options) { } } function preinitModuleScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitModuleScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -17022,14 +17048,6 @@ function getEventPriority(domEventName) { return 32; } } -var Internals = { - usingClientEntryPoint: !1, - Events: null, - Dispatcher: { current: null } - }, - Dispatcher$1 = Internals.Dispatcher; -"undefined" !== typeof document && - (Dispatcher$1.current = ReactDOMClientDispatcher); var defaultOnRecoverableError = "function" === typeof reportError ? reportError @@ -17217,7 +17235,7 @@ function getCrossOriginStringAs(as, input) { if ("string" === typeof input) return "use-credentials" === input ? input : ""; } -var Dispatcher = Internals.Dispatcher; +var ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher; Internals.Events = [ getInstanceFromNode, getNodeFromInstance, @@ -17229,7 +17247,7 @@ Internals.Events = [ var devToolsConfig$jscomp$inline_1819 = { findFiberByHostInstance: getClosestInstanceFromNode, bundleType: 0, - version: "18.3.0-www-classic-4c78434b", + version: "18.3.0-www-classic-d9a421c8", rendererPackageName: "react-dom" }; var internals$jscomp$inline_2178 = { @@ -17259,7 +17277,7 @@ var internals$jscomp$inline_2178 = { scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "18.3.0-www-classic-4c78434b" + reconcilerVersion: "18.3.0-www-classic-d9a421c8" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { var hook$jscomp$inline_2179 = __REACT_DEVTOOLS_GLOBAL_HOOK__; @@ -17320,7 +17338,6 @@ exports.createRoot = function (container, options) { null ); container[internalContainerInstanceKey] = options.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents( 8 === container.nodeType ? container.parentNode : container ); @@ -17389,14 +17406,11 @@ exports.hydrateRoot = function (container, initialChildren, options) { formState ); container[internalContainerInstanceKey] = initialChildren.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents(container); return new ReactDOMHydrationRoot(initialChildren); }; exports.preconnect = function (href, options) { - var dispatcher = Dispatcher.current; - dispatcher && - "string" === typeof href && + "string" === typeof href && (options ? ((options = options.crossOrigin), (options = @@ -17406,20 +17420,14 @@ exports.preconnect = function (href, options) { : "" : void 0)) : (options = null), - dispatcher.preconnect(href, options)); + ReactDOMCurrentDispatcher.current.preconnect(href, options)); }; exports.prefetchDNS = function (href) { - var dispatcher = Dispatcher.current; - dispatcher && "string" === typeof href && dispatcher.prefetchDNS(href); + "string" === typeof href && + ReactDOMCurrentDispatcher.current.prefetchDNS(href); }; exports.preinit = function (href, options) { - var dispatcher = Dispatcher.current; - if ( - dispatcher && - "string" === typeof href && - options && - "string" === typeof options.as - ) { + if ("string" === typeof href && options && "string" === typeof options.as) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin), integrity = @@ -17429,7 +17437,7 @@ exports.preinit = function (href, options) { ? options.fetchPriority : void 0; "style" === as - ? dispatcher.preinitStyle( + ? ReactDOMCurrentDispatcher.current.preinitStyle( href, "string" === typeof options.precedence ? options.precedence : void 0, { @@ -17439,7 +17447,7 @@ exports.preinit = function (href, options) { } ) : "script" === as && - dispatcher.preinitScript(href, { + ReactDOMCurrentDispatcher.current.preinitScript(href, { crossOrigin: crossOrigin, integrity: integrity, fetchPriority: fetchPriority, @@ -17448,27 +17456,26 @@ exports.preinit = function (href, options) { } }; exports.preinitModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if ("object" === typeof options && null !== options) { if (null == options.as || "script" === options.as) { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preinitModuleScript(href, { + ReactDOMCurrentDispatcher.current.preinitModuleScript(href, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, nonce: "string" === typeof options.nonce ? options.nonce : void 0 }); } - } else null == options && dispatcher.preinitModuleScript(href); + } else + null == options && + ReactDOMCurrentDispatcher.current.preinitModuleScript(href); }; exports.preload = function (href, options) { - var dispatcher = Dispatcher.current; if ( - dispatcher && "string" === typeof href && "object" === typeof options && null !== options && @@ -17476,7 +17483,7 @@ exports.preload = function (href, options) { ) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin); - dispatcher.preload(href, as, { + ReactDOMCurrentDispatcher.current.preload(href, as, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, @@ -17498,11 +17505,10 @@ exports.preload = function (href, options) { } }; exports.preloadModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if (options) { var crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin); - dispatcher.preloadModule(href, { + ReactDOMCurrentDispatcher.current.preloadModule(href, { as: "string" === typeof options.as && "script" !== options.as ? options.as @@ -17511,7 +17517,7 @@ exports.preloadModule = function (href, options) { integrity: "string" === typeof options.integrity ? options.integrity : void 0 }); - } else dispatcher.preloadModule(href); + } else ReactDOMCurrentDispatcher.current.preloadModule(href); }; exports.render = function (element, container, callback) { if (!isValidContainerLegacy(container)) @@ -17602,4 +17608,4 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactCurrentDispatcher$2.current.useHostTransitionStatus(); }; -exports.version = "18.3.0-www-classic-4c78434b"; +exports.version = "18.3.0-www-classic-d9a421c8"; diff --git a/compiled/facebook-www/ReactDOM-prod.modern.js b/compiled/facebook-www/ReactDOM-prod.modern.js index b8d211f1a4b81..5bd3c5285e6e0 100644 --- a/compiled/facebook-www/ReactDOM-prod.modern.js +++ b/compiled/facebook-www/ReactDOM-prod.modern.js @@ -15,12 +15,23 @@ */ "use strict"; var React = require("react"), - Scheduler = require("scheduler"), - Internals = { - usingClientEntryPoint: !1, - Events: null, - Dispatcher: { current: null } - }; + Scheduler = require("scheduler"); +function noop$3() {} +var Internals = { + usingClientEntryPoint: !1, + Events: null, + ReactDOMCurrentDispatcher: { + current: { + prefetchDNS: noop$3, + preconnect: noop$3, + preload: noop$3, + preloadModule: noop$3, + preinitScript: noop$3, + preinitStyle: noop$3, + preinitModuleScript: noop$3 + } + } +}; function formatProdErrorMessage(code) { var url = "https://react.dev/errors/" + code; if (1 < arguments.length) { @@ -15592,7 +15603,8 @@ function updateProperties(domElement, tag, lastProps, nextProps) { (null == propKey$226 && null == propKey) || setProp(domElement, tag, lastProp, propKey$226, nextProps, propKey); } -var eventsEnabled = null, +var ReactDOMCurrentDispatcher$1 = Internals.ReactDOMCurrentDispatcher, + eventsEnabled = null, selectionInformation = null; function getOwnerDocumentFromRootContainer(rootContainerElement) { return 9 === rootContainerElement.nodeType @@ -15961,7 +15973,8 @@ function getHoistableRoot(container) { ? container.getRootNode() : container.ownerDocument; } -var ReactDOMClientDispatcher = { +var previousDispatcher = ReactDOMCurrentDispatcher$1.current; +ReactDOMCurrentDispatcher$1.current = { prefetchDNS: prefetchDNS$1, preconnect: preconnect$1, preload: preload$1, @@ -15970,9 +15983,10 @@ var ReactDOMClientDispatcher = { preinitScript: preinitScript, preinitModuleScript: preinitModuleScript }; +var globalDocument = "undefined" === typeof document ? null : document; function preconnectAs(rel, href, crossOrigin) { - var ownerDocument = document; - if ("string" === typeof href && href) { + var ownerDocument = globalDocument; + if (ownerDocument && "string" === typeof href && href) { var limitedEscapedHref = escapeSelectorAttributeValueInsideDoubleQuotes(href); limitedEscapedHref = @@ -15990,14 +16004,17 @@ function preconnectAs(rel, href, crossOrigin) { } } function prefetchDNS$1(href) { + previousDispatcher.prefetchDNS(href); preconnectAs("dns-prefetch", href, null); } function preconnect$1(href, crossOrigin) { + previousDispatcher.preconnect(href, crossOrigin); preconnectAs("preconnect", href, crossOrigin); } function preload$1(href, as, options) { - var ownerDocument = document; - if (href && as && ownerDocument) { + previousDispatcher.preload(href, as, options); + var ownerDocument = globalDocument; + if (ownerDocument && href && as) { var preloadSelector = 'link[rel="preload"][as="' + escapeSelectorAttributeValueInsideDoubleQuotes(as) + @@ -16056,8 +16073,9 @@ function preload$1(href, as, options) { } } function preloadModule$1(href, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preloadModule(href, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var as = options && "string" === typeof options.as ? options.as : "script", preloadSelector = 'link[rel="modulepreload"][as="' + @@ -16099,8 +16117,9 @@ function preloadModule$1(href, options) { } } function preinitStyle(href, precedence, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preinitStyle(href, precedence, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var styles = getResourcesFromRoot(ownerDocument).hoistableStyles, key = getStyleKey(href); precedence = precedence || "default"; @@ -16147,8 +16166,9 @@ function preinitStyle(href, precedence, options) { } } function preinitScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -16172,8 +16192,9 @@ function preinitScript(src, options) { } } function preinitModuleScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitModuleScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -16649,9 +16670,6 @@ function insertStylesheetIntoRoot(root, resource) { resource.state.loading |= 4; } } -var Dispatcher$1 = Internals.Dispatcher; -"undefined" !== typeof document && - (Dispatcher$1.current = ReactDOMClientDispatcher); var defaultOnRecoverableError = "function" === typeof reportError ? reportError @@ -16733,7 +16751,7 @@ function getCrossOriginStringAs(as, input) { if ("string" === typeof input) return "use-credentials" === input ? input : ""; } -var Dispatcher = Internals.Dispatcher; +var ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher; Internals.Events = [ getInstanceFromNode$1, getNodeFromInstance, @@ -16745,7 +16763,7 @@ Internals.Events = [ var devToolsConfig$jscomp$inline_1778 = { findFiberByHostInstance: getClosestInstanceFromNode, bundleType: 0, - version: "18.3.0-www-modern-36a10701", + version: "18.3.0-www-modern-7bb4d6b0", rendererPackageName: "react-dom" }; var internals$jscomp$inline_2142 = { @@ -16776,7 +16794,7 @@ var internals$jscomp$inline_2142 = { scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "18.3.0-www-modern-36a10701" + reconcilerVersion: "18.3.0-www-modern-7bb4d6b0" }; if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) { var hook$jscomp$inline_2143 = __REACT_DEVTOOLS_GLOBAL_HOOK__; @@ -16830,7 +16848,6 @@ exports.createRoot = function (container, options) { null ); container[internalContainerInstanceKey] = options.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents( 8 === container.nodeType ? container.parentNode : container ); @@ -16882,14 +16899,11 @@ exports.hydrateRoot = function (container, initialChildren, options) { markRootUpdated(initialChildren, isStrictMode); ensureRootIsScheduled(initialChildren); container[internalContainerInstanceKey] = initialChildren.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents(container); return new ReactDOMHydrationRoot(initialChildren); }; exports.preconnect = function (href, options) { - var dispatcher = Dispatcher.current; - dispatcher && - "string" === typeof href && + "string" === typeof href && (options ? ((options = options.crossOrigin), (options = @@ -16899,20 +16913,14 @@ exports.preconnect = function (href, options) { : "" : void 0)) : (options = null), - dispatcher.preconnect(href, options)); + ReactDOMCurrentDispatcher.current.preconnect(href, options)); }; exports.prefetchDNS = function (href) { - var dispatcher = Dispatcher.current; - dispatcher && "string" === typeof href && dispatcher.prefetchDNS(href); + "string" === typeof href && + ReactDOMCurrentDispatcher.current.prefetchDNS(href); }; exports.preinit = function (href, options) { - var dispatcher = Dispatcher.current; - if ( - dispatcher && - "string" === typeof href && - options && - "string" === typeof options.as - ) { + if ("string" === typeof href && options && "string" === typeof options.as) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin), integrity = @@ -16922,7 +16930,7 @@ exports.preinit = function (href, options) { ? options.fetchPriority : void 0; "style" === as - ? dispatcher.preinitStyle( + ? ReactDOMCurrentDispatcher.current.preinitStyle( href, "string" === typeof options.precedence ? options.precedence : void 0, { @@ -16932,7 +16940,7 @@ exports.preinit = function (href, options) { } ) : "script" === as && - dispatcher.preinitScript(href, { + ReactDOMCurrentDispatcher.current.preinitScript(href, { crossOrigin: crossOrigin, integrity: integrity, fetchPriority: fetchPriority, @@ -16941,27 +16949,26 @@ exports.preinit = function (href, options) { } }; exports.preinitModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if ("object" === typeof options && null !== options) { if (null == options.as || "script" === options.as) { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preinitModuleScript(href, { + ReactDOMCurrentDispatcher.current.preinitModuleScript(href, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, nonce: "string" === typeof options.nonce ? options.nonce : void 0 }); } - } else null == options && dispatcher.preinitModuleScript(href); + } else + null == options && + ReactDOMCurrentDispatcher.current.preinitModuleScript(href); }; exports.preload = function (href, options) { - var dispatcher = Dispatcher.current; if ( - dispatcher && "string" === typeof href && "object" === typeof options && null !== options && @@ -16969,7 +16976,7 @@ exports.preload = function (href, options) { ) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin); - dispatcher.preload(href, as, { + ReactDOMCurrentDispatcher.current.preload(href, as, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, @@ -16991,11 +16998,10 @@ exports.preload = function (href, options) { } }; exports.preloadModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if (options) { var crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin); - dispatcher.preloadModule(href, { + ReactDOMCurrentDispatcher.current.preloadModule(href, { as: "string" === typeof options.as && "script" !== options.as ? options.as @@ -17004,7 +17010,7 @@ exports.preloadModule = function (href, options) { integrity: "string" === typeof options.integrity ? options.integrity : void 0 }); - } else dispatcher.preloadModule(href); + } else ReactDOMCurrentDispatcher.current.preloadModule(href); }; exports.unstable_batchedUpdates = batchedUpdates$1; exports.unstable_createEventHandle = function (type, options) { @@ -17047,4 +17053,4 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactCurrentDispatcher$2.current.useHostTransitionStatus(); }; -exports.version = "18.3.0-www-modern-36a10701"; +exports.version = "18.3.0-www-modern-7bb4d6b0"; diff --git a/compiled/facebook-www/ReactDOM-profiling.classic.js b/compiled/facebook-www/ReactDOM-profiling.classic.js index c06b774aa2f8d..9d08c897684c9 100644 --- a/compiled/facebook-www/ReactDOM-profiling.classic.js +++ b/compiled/facebook-www/ReactDOM-profiling.classic.js @@ -2643,12 +2643,12 @@ function isThenableResolved(thenable) { thenable = thenable.status; return "fulfilled" === thenable || "rejected" === thenable; } -function noop$2() {} +function noop$3() {} function trackUsedThenable(thenableState, thenable, index) { index = thenableState[index]; void 0 === index ? thenableState.push(thenable) - : index !== thenable && (thenable.then(noop$2, noop$2), (thenable = index)); + : index !== thenable && (thenable.then(noop$3, noop$3), (thenable = index)); switch (thenable.status) { case "fulfilled": return thenable.value; @@ -2658,7 +2658,7 @@ function trackUsedThenable(thenableState, thenable, index) { throw Error(formatProdErrorMessage(483)); throw thenableState; default: - if ("string" === typeof thenable.status) thenable.then(noop$2, noop$2); + if ("string" === typeof thenable.status) thenable.then(noop$3, noop$3); else { thenableState = workInProgressRoot; if (null !== thenableState && 100 < thenableState.shellSuspendCounter) @@ -9055,7 +9055,7 @@ function insertOrAppendPlacementNodeIntoContainer(node, before, parent) { (parent = parent._reactRootContainer), (null !== parent && void 0 !== parent) || null !== before.onclick || - (before.onclick = noop$1)); + (before.onclick = noop$2)); else if (4 !== tag && 27 !== tag && ((node = node.child), null !== node)) for ( insertOrAppendPlacementNodeIntoContainer(node, before, parent), @@ -15149,7 +15149,7 @@ function checkForUnmatchedText(serverText, clientText, isConcurrentMode) { ) throw Error(formatProdErrorMessage(425)); } -function noop$1() {} +function noop$2() {} function setProp(domElement, tag, key, value, props, prevValue) { switch (key) { case "children": @@ -15247,7 +15247,7 @@ function setProp(domElement, tag, key, value, props, prevValue) { domElement.setAttribute(key, value); break; case "onClick": - null != value && (domElement.onclick = noop$1); + null != value && (domElement.onclick = noop$2); break; case "onScroll": null != value && listenToNonDelegatedEvent("scroll", domElement); @@ -15493,7 +15493,7 @@ function setPropOnCustomElement(domElement, tag, key, value, props, prevValue) { null != value && listenToNonDelegatedEvent("scrollend", domElement); break; case "onClick": - null != value && (domElement.onclick = noop$1); + null != value && (domElement.onclick = noop$2); break; case "suppressContentEditableWarning": case "suppressHydrationWarning": @@ -16069,7 +16069,24 @@ function updateProperties(domElement, tag, lastProps, nextProps) { (null == propKey$241 && null == propKey) || setProp(domElement, tag, lastProp, propKey$241, nextProps, propKey); } -var eventsEnabled = null, +function noop$1() {} +var Internals = { + usingClientEntryPoint: !1, + Events: null, + ReactDOMCurrentDispatcher: { + current: { + prefetchDNS: noop$1, + preconnect: noop$1, + preload: noop$1, + preloadModule: noop$1, + preinitScript: noop$1, + preinitStyle: noop$1, + preinitModuleScript: noop$1 + } + } + }, + ReactDOMCurrentDispatcher$1 = Internals.ReactDOMCurrentDispatcher, + eventsEnabled = null, selectionInformation = null; function getOwnerDocumentFromRootContainer(rootContainerElement) { return 9 === rootContainerElement.nodeType @@ -16403,7 +16420,7 @@ function hydrateInstance( (instance.textContent = internalInstanceHandle)); null != props.onScroll && listenToNonDelegatedEvent("scroll", instance); null != props.onScrollEnd && listenToNonDelegatedEvent("scrollend", instance); - null != props.onClick && (instance.onclick = noop$1); + null != props.onClick && (instance.onclick = noop$2); } function getParentSuspenseInstance(targetInstance) { targetInstance = targetInstance.previousSibling; @@ -16452,7 +16469,8 @@ function getHoistableRoot(container) { ? container.getRootNode() : container.ownerDocument; } -var ReactDOMClientDispatcher = { +var previousDispatcher = ReactDOMCurrentDispatcher$1.current; +ReactDOMCurrentDispatcher$1.current = { prefetchDNS: prefetchDNS$1, preconnect: preconnect$1, preload: preload$1, @@ -16461,9 +16479,10 @@ var ReactDOMClientDispatcher = { preinitScript: preinitScript, preinitModuleScript: preinitModuleScript }; +var globalDocument = "undefined" === typeof document ? null : document; function preconnectAs(rel, href, crossOrigin) { - var ownerDocument = document; - if ("string" === typeof href && href) { + var ownerDocument = globalDocument; + if (ownerDocument && "string" === typeof href && href) { var limitedEscapedHref = escapeSelectorAttributeValueInsideDoubleQuotes(href); limitedEscapedHref = @@ -16481,14 +16500,17 @@ function preconnectAs(rel, href, crossOrigin) { } } function prefetchDNS$1(href) { + previousDispatcher.prefetchDNS(href); preconnectAs("dns-prefetch", href, null); } function preconnect$1(href, crossOrigin) { + previousDispatcher.preconnect(href, crossOrigin); preconnectAs("preconnect", href, crossOrigin); } function preload$1(href, as, options) { - var ownerDocument = document; - if (href && as && ownerDocument) { + previousDispatcher.preload(href, as, options); + var ownerDocument = globalDocument; + if (ownerDocument && href && as) { var preloadSelector = 'link[rel="preload"][as="' + escapeSelectorAttributeValueInsideDoubleQuotes(as) + @@ -16547,8 +16569,9 @@ function preload$1(href, as, options) { } } function preloadModule$1(href, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preloadModule(href, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var as = options && "string" === typeof options.as ? options.as : "script", preloadSelector = 'link[rel="modulepreload"][as="' + @@ -16590,8 +16613,9 @@ function preloadModule$1(href, options) { } } function preinitStyle(href, precedence, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preinitStyle(href, precedence, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var styles = getResourcesFromRoot(ownerDocument).hoistableStyles, key = getStyleKey(href); precedence = precedence || "default"; @@ -16638,8 +16662,9 @@ function preinitStyle(href, precedence, options) { } } function preinitScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -16663,8 +16688,9 @@ function preinitScript(src, options) { } } function preinitModuleScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitModuleScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -17791,14 +17817,6 @@ function getEventPriority(domEventName) { return 32; } } -var Internals = { - usingClientEntryPoint: !1, - Events: null, - Dispatcher: { current: null } - }, - Dispatcher$1 = Internals.Dispatcher; -"undefined" !== typeof document && - (Dispatcher$1.current = ReactDOMClientDispatcher); var defaultOnRecoverableError = "function" === typeof reportError ? reportError @@ -17986,7 +18004,7 @@ function getCrossOriginStringAs(as, input) { if ("string" === typeof input) return "use-credentials" === input ? input : ""; } -var Dispatcher = Internals.Dispatcher; +var ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher; Internals.Events = [ getInstanceFromNode, getNodeFromInstance, @@ -17998,7 +18016,7 @@ Internals.Events = [ var devToolsConfig$jscomp$inline_1904 = { findFiberByHostInstance: getClosestInstanceFromNode, bundleType: 0, - version: "18.3.0-www-classic-8745c23b", + version: "18.3.0-www-classic-86500a4d", rendererPackageName: "react-dom" }; (function (internals) { @@ -18042,7 +18060,7 @@ var devToolsConfig$jscomp$inline_1904 = { scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "18.3.0-www-classic-8745c23b" + reconcilerVersion: "18.3.0-www-classic-86500a4d" }); assign(Internals, { ReactBrowserEventEmitter: { @@ -18090,7 +18108,6 @@ exports.createRoot = function (container, options) { null ); container[internalContainerInstanceKey] = options.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents( 8 === container.nodeType ? container.parentNode : container ); @@ -18159,14 +18176,11 @@ exports.hydrateRoot = function (container, initialChildren, options) { formState ); container[internalContainerInstanceKey] = initialChildren.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents(container); return new ReactDOMHydrationRoot(initialChildren); }; exports.preconnect = function (href, options) { - var dispatcher = Dispatcher.current; - dispatcher && - "string" === typeof href && + "string" === typeof href && (options ? ((options = options.crossOrigin), (options = @@ -18176,20 +18190,14 @@ exports.preconnect = function (href, options) { : "" : void 0)) : (options = null), - dispatcher.preconnect(href, options)); + ReactDOMCurrentDispatcher.current.preconnect(href, options)); }; exports.prefetchDNS = function (href) { - var dispatcher = Dispatcher.current; - dispatcher && "string" === typeof href && dispatcher.prefetchDNS(href); + "string" === typeof href && + ReactDOMCurrentDispatcher.current.prefetchDNS(href); }; exports.preinit = function (href, options) { - var dispatcher = Dispatcher.current; - if ( - dispatcher && - "string" === typeof href && - options && - "string" === typeof options.as - ) { + if ("string" === typeof href && options && "string" === typeof options.as) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin), integrity = @@ -18199,7 +18207,7 @@ exports.preinit = function (href, options) { ? options.fetchPriority : void 0; "style" === as - ? dispatcher.preinitStyle( + ? ReactDOMCurrentDispatcher.current.preinitStyle( href, "string" === typeof options.precedence ? options.precedence : void 0, { @@ -18209,7 +18217,7 @@ exports.preinit = function (href, options) { } ) : "script" === as && - dispatcher.preinitScript(href, { + ReactDOMCurrentDispatcher.current.preinitScript(href, { crossOrigin: crossOrigin, integrity: integrity, fetchPriority: fetchPriority, @@ -18218,27 +18226,26 @@ exports.preinit = function (href, options) { } }; exports.preinitModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if ("object" === typeof options && null !== options) { if (null == options.as || "script" === options.as) { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preinitModuleScript(href, { + ReactDOMCurrentDispatcher.current.preinitModuleScript(href, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, nonce: "string" === typeof options.nonce ? options.nonce : void 0 }); } - } else null == options && dispatcher.preinitModuleScript(href); + } else + null == options && + ReactDOMCurrentDispatcher.current.preinitModuleScript(href); }; exports.preload = function (href, options) { - var dispatcher = Dispatcher.current; if ( - dispatcher && "string" === typeof href && "object" === typeof options && null !== options && @@ -18246,7 +18253,7 @@ exports.preload = function (href, options) { ) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin); - dispatcher.preload(href, as, { + ReactDOMCurrentDispatcher.current.preload(href, as, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, @@ -18268,11 +18275,10 @@ exports.preload = function (href, options) { } }; exports.preloadModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if (options) { var crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin); - dispatcher.preloadModule(href, { + ReactDOMCurrentDispatcher.current.preloadModule(href, { as: "string" === typeof options.as && "script" !== options.as ? options.as @@ -18281,7 +18287,7 @@ exports.preloadModule = function (href, options) { integrity: "string" === typeof options.integrity ? options.integrity : void 0 }); - } else dispatcher.preloadModule(href); + } else ReactDOMCurrentDispatcher.current.preloadModule(href); }; exports.render = function (element, container, callback) { if (!isValidContainerLegacy(container)) @@ -18372,7 +18378,7 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactCurrentDispatcher$2.current.useHostTransitionStatus(); }; -exports.version = "18.3.0-www-classic-8745c23b"; +exports.version = "18.3.0-www-classic-86500a4d"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled/facebook-www/ReactDOM-profiling.modern.js b/compiled/facebook-www/ReactDOM-profiling.modern.js index 7454cd429ca0e..7f810317495c2 100644 --- a/compiled/facebook-www/ReactDOM-profiling.modern.js +++ b/compiled/facebook-www/ReactDOM-profiling.modern.js @@ -19,12 +19,23 @@ typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error()); var React = require("react"), - Scheduler = require("scheduler"), - Internals = { - usingClientEntryPoint: !1, - Events: null, - Dispatcher: { current: null } - }; + Scheduler = require("scheduler"); +function noop$3() {} +var Internals = { + usingClientEntryPoint: !1, + Events: null, + ReactDOMCurrentDispatcher: { + current: { + prefetchDNS: noop$3, + preconnect: noop$3, + preload: noop$3, + preloadModule: noop$3, + preinitScript: noop$3, + preinitStyle: noop$3, + preinitModuleScript: noop$3 + } + } +}; function formatProdErrorMessage(code) { var url = "https://react.dev/errors/" + code; if (1 < arguments.length) { @@ -16355,7 +16366,8 @@ function updateProperties(domElement, tag, lastProps, nextProps) { (null == propKey$247 && null == propKey) || setProp(domElement, tag, lastProp, propKey$247, nextProps, propKey); } -var eventsEnabled = null, +var ReactDOMCurrentDispatcher$1 = Internals.ReactDOMCurrentDispatcher, + eventsEnabled = null, selectionInformation = null; function getOwnerDocumentFromRootContainer(rootContainerElement) { return 9 === rootContainerElement.nodeType @@ -16724,7 +16736,8 @@ function getHoistableRoot(container) { ? container.getRootNode() : container.ownerDocument; } -var ReactDOMClientDispatcher = { +var previousDispatcher = ReactDOMCurrentDispatcher$1.current; +ReactDOMCurrentDispatcher$1.current = { prefetchDNS: prefetchDNS$1, preconnect: preconnect$1, preload: preload$1, @@ -16733,9 +16746,10 @@ var ReactDOMClientDispatcher = { preinitScript: preinitScript, preinitModuleScript: preinitModuleScript }; +var globalDocument = "undefined" === typeof document ? null : document; function preconnectAs(rel, href, crossOrigin) { - var ownerDocument = document; - if ("string" === typeof href && href) { + var ownerDocument = globalDocument; + if (ownerDocument && "string" === typeof href && href) { var limitedEscapedHref = escapeSelectorAttributeValueInsideDoubleQuotes(href); limitedEscapedHref = @@ -16753,14 +16767,17 @@ function preconnectAs(rel, href, crossOrigin) { } } function prefetchDNS$1(href) { + previousDispatcher.prefetchDNS(href); preconnectAs("dns-prefetch", href, null); } function preconnect$1(href, crossOrigin) { + previousDispatcher.preconnect(href, crossOrigin); preconnectAs("preconnect", href, crossOrigin); } function preload$1(href, as, options) { - var ownerDocument = document; - if (href && as && ownerDocument) { + previousDispatcher.preload(href, as, options); + var ownerDocument = globalDocument; + if (ownerDocument && href && as) { var preloadSelector = 'link[rel="preload"][as="' + escapeSelectorAttributeValueInsideDoubleQuotes(as) + @@ -16819,8 +16836,9 @@ function preload$1(href, as, options) { } } function preloadModule$1(href, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preloadModule(href, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var as = options && "string" === typeof options.as ? options.as : "script", preloadSelector = 'link[rel="modulepreload"][as="' + @@ -16862,8 +16880,9 @@ function preloadModule$1(href, options) { } } function preinitStyle(href, precedence, options) { - var ownerDocument = document; - if (href) { + previousDispatcher.preinitStyle(href, precedence, options); + var ownerDocument = globalDocument; + if (ownerDocument && href) { var styles = getResourcesFromRoot(ownerDocument).hoistableStyles, key = getStyleKey(href); precedence = precedence || "default"; @@ -16910,8 +16929,9 @@ function preinitStyle(href, precedence, options) { } } function preinitScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -16935,8 +16955,9 @@ function preinitScript(src, options) { } } function preinitModuleScript(src, options) { - var ownerDocument = document; - if (src) { + previousDispatcher.preinitModuleScript(src, options); + var ownerDocument = globalDocument; + if (ownerDocument && src) { var scripts = getResourcesFromRoot(ownerDocument).hoistableScripts, key = getScriptKey(src), resource = scripts.get(key); @@ -17412,9 +17433,6 @@ function insertStylesheetIntoRoot(root, resource) { resource.state.loading |= 4; } } -var Dispatcher$1 = Internals.Dispatcher; -"undefined" !== typeof document && - (Dispatcher$1.current = ReactDOMClientDispatcher); var defaultOnRecoverableError = "function" === typeof reportError ? reportError @@ -17496,7 +17514,7 @@ function getCrossOriginStringAs(as, input) { if ("string" === typeof input) return "use-credentials" === input ? input : ""; } -var Dispatcher = Internals.Dispatcher; +var ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher; Internals.Events = [ getInstanceFromNode$1, getNodeFromInstance, @@ -17508,7 +17526,7 @@ Internals.Events = [ var devToolsConfig$jscomp$inline_1863 = { findFiberByHostInstance: getClosestInstanceFromNode, bundleType: 0, - version: "18.3.0-www-modern-b6d2fca1", + version: "18.3.0-www-modern-c0bbf979", rendererPackageName: "react-dom" }; (function (internals) { @@ -17553,7 +17571,7 @@ var devToolsConfig$jscomp$inline_1863 = { scheduleRoot: null, setRefreshHandler: null, getCurrentFiber: null, - reconcilerVersion: "18.3.0-www-modern-b6d2fca1" + reconcilerVersion: "18.3.0-www-modern-c0bbf979" }); exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals; exports.createPortal = function (children, container) { @@ -17594,7 +17612,6 @@ exports.createRoot = function (container, options) { null ); container[internalContainerInstanceKey] = options.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents( 8 === container.nodeType ? container.parentNode : container ); @@ -17646,14 +17663,11 @@ exports.hydrateRoot = function (container, initialChildren, options) { markRootUpdated(initialChildren, isStrictMode); ensureRootIsScheduled(initialChildren); container[internalContainerInstanceKey] = initialChildren.current; - Dispatcher$1.current = ReactDOMClientDispatcher; listenToAllSupportedEvents(container); return new ReactDOMHydrationRoot(initialChildren); }; exports.preconnect = function (href, options) { - var dispatcher = Dispatcher.current; - dispatcher && - "string" === typeof href && + "string" === typeof href && (options ? ((options = options.crossOrigin), (options = @@ -17663,20 +17677,14 @@ exports.preconnect = function (href, options) { : "" : void 0)) : (options = null), - dispatcher.preconnect(href, options)); + ReactDOMCurrentDispatcher.current.preconnect(href, options)); }; exports.prefetchDNS = function (href) { - var dispatcher = Dispatcher.current; - dispatcher && "string" === typeof href && dispatcher.prefetchDNS(href); + "string" === typeof href && + ReactDOMCurrentDispatcher.current.prefetchDNS(href); }; exports.preinit = function (href, options) { - var dispatcher = Dispatcher.current; - if ( - dispatcher && - "string" === typeof href && - options && - "string" === typeof options.as - ) { + if ("string" === typeof href && options && "string" === typeof options.as) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin), integrity = @@ -17686,7 +17694,7 @@ exports.preinit = function (href, options) { ? options.fetchPriority : void 0; "style" === as - ? dispatcher.preinitStyle( + ? ReactDOMCurrentDispatcher.current.preinitStyle( href, "string" === typeof options.precedence ? options.precedence : void 0, { @@ -17696,7 +17704,7 @@ exports.preinit = function (href, options) { } ) : "script" === as && - dispatcher.preinitScript(href, { + ReactDOMCurrentDispatcher.current.preinitScript(href, { crossOrigin: crossOrigin, integrity: integrity, fetchPriority: fetchPriority, @@ -17705,27 +17713,26 @@ exports.preinit = function (href, options) { } }; exports.preinitModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if ("object" === typeof options && null !== options) { if (null == options.as || "script" === options.as) { var crossOrigin = getCrossOriginStringAs( options.as, options.crossOrigin ); - dispatcher.preinitModuleScript(href, { + ReactDOMCurrentDispatcher.current.preinitModuleScript(href, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, nonce: "string" === typeof options.nonce ? options.nonce : void 0 }); } - } else null == options && dispatcher.preinitModuleScript(href); + } else + null == options && + ReactDOMCurrentDispatcher.current.preinitModuleScript(href); }; exports.preload = function (href, options) { - var dispatcher = Dispatcher.current; if ( - dispatcher && "string" === typeof href && "object" === typeof options && null !== options && @@ -17733,7 +17740,7 @@ exports.preload = function (href, options) { ) { var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin); - dispatcher.preload(href, as, { + ReactDOMCurrentDispatcher.current.preload(href, as, { crossOrigin: crossOrigin, integrity: "string" === typeof options.integrity ? options.integrity : void 0, @@ -17755,11 +17762,10 @@ exports.preload = function (href, options) { } }; exports.preloadModule = function (href, options) { - var dispatcher = Dispatcher.current; - if (dispatcher && "string" === typeof href) + if ("string" === typeof href) if (options) { var crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin); - dispatcher.preloadModule(href, { + ReactDOMCurrentDispatcher.current.preloadModule(href, { as: "string" === typeof options.as && "script" !== options.as ? options.as @@ -17768,7 +17774,7 @@ exports.preloadModule = function (href, options) { integrity: "string" === typeof options.integrity ? options.integrity : void 0 }); - } else dispatcher.preloadModule(href); + } else ReactDOMCurrentDispatcher.current.preloadModule(href); }; exports.unstable_batchedUpdates = batchedUpdates$1; exports.unstable_createEventHandle = function (type, options) { @@ -17811,7 +17817,7 @@ exports.useFormState = function (action, initialState, permalink) { exports.useFormStatus = function () { return ReactCurrentDispatcher$2.current.useHostTransitionStatus(); }; -exports.version = "18.3.0-www-modern-b6d2fca1"; +exports.version = "18.3.0-www-modern-c0bbf979"; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && diff --git a/compiled/facebook-www/ReactDOMServer-dev.classic.js b/compiled/facebook-www/ReactDOMServer-dev.classic.js index 2b18d74b315ce..59c77fb93d30f 100644 --- a/compiled/facebook-www/ReactDOMServer-dev.classic.js +++ b/compiled/facebook-www/ReactDOMServer-dev.classic.js @@ -19,7 +19,7 @@ if (__DEV__) { var React = require("react"); var ReactDOM = require("react-dom"); - var ReactVersion = "18.3.0-www-classic-e23c55b6"; + var ReactVersion = "18.3.0-www-classic-1b1f613f"; // This refers to a WWW module. var warningWWW = require("warning"); @@ -2375,19 +2375,18 @@ if (__DEV__) { var ReactDOMSharedInternals = ReactDOM.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; - var ReactDOMCurrentDispatcher = ReactDOMSharedInternals.Dispatcher; - var ReactDOMServerDispatcher = { + var ReactDOMCurrentDispatcher = + ReactDOMSharedInternals.ReactDOMCurrentDispatcher; + var previousDispatcher = ReactDOMCurrentDispatcher.current; + ReactDOMCurrentDispatcher.current = { prefetchDNS: prefetchDNS, preconnect: preconnect, preload: preload, preloadModule: preloadModule, - preinitStyle: preinitStyle, preinitScript: preinitScript, + preinitStyle: preinitStyle, preinitModuleScript: preinitModuleScript - }; - function prepareHostDispatcher() { - ReactDOMCurrentDispatcher.current = ReactDOMServerDispatcher; - } // We make every property of the descriptor optional because it is not a contract that + }; // We make every property of the descriptor optional because it is not a contract that var ScriptStreamingFormat = 0; var DataStreamingFormat = 1; var NothingSent = @@ -7405,6 +7404,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.prefetchDNS(href); return; } @@ -7463,6 +7463,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preconnect(href, crossOrigin); return; } @@ -7527,6 +7528,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preload(href, as, options); return; } @@ -7761,6 +7763,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preloadModule(href, options); return; } @@ -7838,6 +7841,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preinitStyle(href, precedence, options); return; } @@ -7919,6 +7923,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preinitScript(src, options); return; } @@ -7984,6 +7989,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preinitModuleScript(src, options); return; } @@ -11150,7 +11156,6 @@ if (__DEV__) { onPostpone, formState ) { - prepareHostDispatcher(); var pingedTasks = []; var abortSet = new Set(); var request = { diff --git a/compiled/facebook-www/ReactDOMServer-dev.modern.js b/compiled/facebook-www/ReactDOMServer-dev.modern.js index 327b4bad2228e..2acd396b8b108 100644 --- a/compiled/facebook-www/ReactDOMServer-dev.modern.js +++ b/compiled/facebook-www/ReactDOMServer-dev.modern.js @@ -19,7 +19,7 @@ if (__DEV__) { var React = require("react"); var ReactDOM = require("react-dom"); - var ReactVersion = "18.3.0-www-modern-a8780f15"; + var ReactVersion = "18.3.0-www-modern-418a9c9b"; // This refers to a WWW module. var warningWWW = require("warning"); @@ -2375,19 +2375,18 @@ if (__DEV__) { var ReactDOMSharedInternals = ReactDOM.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; - var ReactDOMCurrentDispatcher = ReactDOMSharedInternals.Dispatcher; - var ReactDOMServerDispatcher = { + var ReactDOMCurrentDispatcher = + ReactDOMSharedInternals.ReactDOMCurrentDispatcher; + var previousDispatcher = ReactDOMCurrentDispatcher.current; + ReactDOMCurrentDispatcher.current = { prefetchDNS: prefetchDNS, preconnect: preconnect, preload: preload, preloadModule: preloadModule, - preinitStyle: preinitStyle, preinitScript: preinitScript, + preinitStyle: preinitStyle, preinitModuleScript: preinitModuleScript - }; - function prepareHostDispatcher() { - ReactDOMCurrentDispatcher.current = ReactDOMServerDispatcher; - } // We make every property of the descriptor optional because it is not a contract that + }; // We make every property of the descriptor optional because it is not a contract that var ScriptStreamingFormat = 0; var DataStreamingFormat = 1; var NothingSent = @@ -7405,6 +7404,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.prefetchDNS(href); return; } @@ -7463,6 +7463,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preconnect(href, crossOrigin); return; } @@ -7527,6 +7528,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preload(href, as, options); return; } @@ -7761,6 +7763,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preloadModule(href, options); return; } @@ -7838,6 +7841,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preinitStyle(href, precedence, options); return; } @@ -7919,6 +7923,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preinitScript(src, options); return; } @@ -7984,6 +7989,7 @@ if (__DEV__) { // the resources for this call in either case we opt to do nothing. We can consider making this a warning // but there may be times where calling a function outside of render is intentional (i.e. to warm up data // fetching) and we don't want to warn in those cases. + previousDispatcher.preinitModuleScript(src, options); return; } @@ -11071,7 +11077,6 @@ if (__DEV__) { onPostpone, formState ) { - prepareHostDispatcher(); var pingedTasks = []; var abortSet = new Set(); var request = { diff --git a/compiled/facebook-www/ReactDOMServer-prod.classic.js b/compiled/facebook-www/ReactDOMServer-prod.classic.js index 04604e92a7617..4b3c2f54b120b 100644 --- a/compiled/facebook-www/ReactDOMServer-prod.classic.js +++ b/compiled/facebook-www/ReactDOMServer-prod.classic.js @@ -289,17 +289,19 @@ var ReactSharedInternals = action: null }, ReactDOMCurrentDispatcher = - ReactDOM.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.Dispatcher, - ReactDOMServerDispatcher = { - prefetchDNS: prefetchDNS, - preconnect: preconnect, - preload: preload, - preloadModule: preloadModule, - preinitStyle: preinitStyle, - preinitScript: preinitScript, - preinitModuleScript: preinitModuleScript - }, - PRELOAD_NO_CREDS = [], + ReactDOM.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED + .ReactDOMCurrentDispatcher, + previousDispatcher = ReactDOMCurrentDispatcher.current; +ReactDOMCurrentDispatcher.current = { + prefetchDNS: prefetchDNS, + preconnect: preconnect, + preload: preload, + preloadModule: preloadModule, + preinitScript: preinitScript, + preinitStyle: preinitStyle, + preinitModuleScript: preinitModuleScript +}; +var PRELOAD_NO_CREDS = [], scriptRegex = /(<\/|<)(s)(cript)/gi; function scriptReplacer(match, prefix, s, suffix) { return "" + prefix + ("s" === s ? "\\u0073" : "\\u0053") + suffix; @@ -2211,7 +2213,7 @@ function prefetchDNS(href) { } enqueueFlush(request); } - } + } else previousDispatcher.prefetchDNS(href); } function preconnect(href, crossOrigin) { var request = currentRequest ? currentRequest : null; @@ -2265,7 +2267,7 @@ function preconnect(href, crossOrigin) { } enqueueFlush(request); } - } + } else previousDispatcher.preconnect(href, crossOrigin); } function preload(href, as, options) { var request = currentRequest ? currentRequest : null; @@ -2379,7 +2381,7 @@ function preload(href, as, options) { } enqueueFlush(request); } - } + } else previousDispatcher.preload(href, as, options); } function preloadModule(href, options) { var request = currentRequest ? currentRequest : null; @@ -2415,7 +2417,7 @@ function preloadModule(href, options) { renderState.bulkPreloads.add(as); enqueueFlush(request); } - } + } else previousDispatcher.preloadModule(href, options); } function preinitStyle(href, precedence, options) { var request = currentRequest ? currentRequest : null; @@ -2455,7 +2457,7 @@ function preinitStyle(href, precedence, options) { styleQueue.sheets.set(href, precedence), enqueueFlush(request)); } - } + } else previousDispatcher.preinitStyle(href, precedence, options); } function preinitScript(src, options) { var request = currentRequest ? currentRequest : null; @@ -2479,7 +2481,7 @@ function preinitScript(src, options) { pushScriptImpl(src, options), enqueueFlush(request)); } - } + } else previousDispatcher.preinitScript(src, options); } function preinitModuleScript(src, options) { var request = currentRequest ? currentRequest : null; @@ -2505,7 +2507,7 @@ function preinitModuleScript(src, options) { pushScriptImpl(src, options), enqueueFlush(request)); } - } + } else previousDispatcher.preinitModuleScript(src, options); } function adoptPreloadCredentials(target, preloadState) { null == target.crossOrigin && (target.crossOrigin = preloadState[0]); @@ -2593,16 +2595,16 @@ function createRenderState(resumableState, generateStaticMarkup) { "\x3c/script>" ); bootstrapScriptContent = idPrefix + "P:"; - var JSCompiler_object_inline_segmentPrefix_1596 = idPrefix + "S:"; + var JSCompiler_object_inline_segmentPrefix_1595 = idPrefix + "S:"; idPrefix += "B:"; - var JSCompiler_object_inline_preconnects_1610 = new Set(), - JSCompiler_object_inline_fontPreloads_1611 = new Set(), - JSCompiler_object_inline_highImagePreloads_1612 = new Set(), - JSCompiler_object_inline_styles_1613 = new Map(), - JSCompiler_object_inline_bootstrapScripts_1614 = new Set(), - JSCompiler_object_inline_scripts_1615 = new Set(), - JSCompiler_object_inline_bulkPreloads_1616 = new Set(), - JSCompiler_object_inline_preloads_1617 = { + var JSCompiler_object_inline_preconnects_1609 = new Set(), + JSCompiler_object_inline_fontPreloads_1610 = new Set(), + JSCompiler_object_inline_highImagePreloads_1611 = new Set(), + JSCompiler_object_inline_styles_1612 = new Map(), + JSCompiler_object_inline_bootstrapScripts_1613 = new Set(), + JSCompiler_object_inline_scripts_1614 = new Set(), + JSCompiler_object_inline_bulkPreloads_1615 = new Set(), + JSCompiler_object_inline_preloads_1616 = { images: new Map(), stylesheets: new Map(), scripts: new Map(), @@ -2639,7 +2641,7 @@ function createRenderState(resumableState, generateStaticMarkup) { scriptConfig.moduleScriptResources[href] = null; scriptConfig = []; pushLinkImpl(scriptConfig, props); - JSCompiler_object_inline_bootstrapScripts_1614.add(scriptConfig); + JSCompiler_object_inline_bootstrapScripts_1613.add(scriptConfig); bootstrapChunks.push('