octane 0.3.1 → 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/cjs/constants.cjs +18 -25
  2. package/dist/cjs/css.cjs +6 -0
  3. package/dist/cjs/dom-binding-protocol.cjs +37 -14
  4. package/dist/cjs/hydration/control-capture.cjs +12 -4
  5. package/dist/cjs/hydration/event-capture.cjs +6 -7
  6. package/dist/cjs/hydration-markers.cjs +40 -2
  7. package/dist/cjs/runtime-tags.cjs +55 -0
  8. package/dist/cjs/runtime.cjs +483 -132
  9. package/dist/cjs/runtime.server.cjs +34 -41
  10. package/dist/cjs/server/streamed-signals.cjs +7 -4
  11. package/dist/cjs/signals/control-binding.cjs +2 -1
  12. package/dist/cjs/stream-protocol.cjs +9 -8
  13. package/dist/cjs/version.cjs +1 -1
  14. package/dist/compiler/compile.js +120 -19
  15. package/dist/compiler/dom-bindings.js +5 -0
  16. package/dist/constants.d.ts +7 -18
  17. package/dist/constants.js +11 -9
  18. package/dist/css.d.ts +7 -0
  19. package/dist/css.js +4 -0
  20. package/dist/dom-binding-program.js +12 -5
  21. package/dist/dom-binding-protocol.d.ts +14 -1
  22. package/dist/dom-binding-protocol.js +40 -14
  23. package/dist/hydration/control-capture.d.ts +2 -0
  24. package/dist/hydration/control-capture.js +18 -5
  25. package/dist/hydration/event-capture.js +1 -2
  26. package/dist/hydration/independent-island.js +5 -5
  27. package/dist/hydration-markers.d.ts +30 -0
  28. package/dist/hydration-markers.js +27 -1
  29. package/dist/react/index.js +1 -1
  30. package/dist/react/react-compat-shared.js +5 -3
  31. package/dist/react/shared.d.ts +1 -3
  32. package/dist/react/shared.js +1 -1
  33. package/dist/runtime-tags.d.ts +34 -0
  34. package/dist/runtime-tags.js +22 -0
  35. package/dist/runtime.d.ts +37 -15
  36. package/dist/runtime.js +463 -90
  37. package/dist/runtime.server.d.ts +2 -3
  38. package/dist/runtime.server.js +25 -17
  39. package/dist/server/streamed-signals.js +7 -4
  40. package/dist/signals/control-binding.js +4 -2
  41. package/dist/stream-protocol.js +20 -9
  42. package/dist/universal-core.js +8 -4
  43. package/dist/universal-native.js +1 -1
  44. package/dist/version.js +1 -1
  45. package/package.json +3 -3
@@ -149,6 +149,7 @@ __export(runtime_exports, {
149
149
  hostComponent: () => hostComponent,
150
150
  htext: () => htext,
151
151
  htextSwap: () => htextSwap,
152
+ hydrateClaimedBindingCaches: () => hydrateClaimedBindingCaches,
152
153
  hydrateRoot: () => hydrateRoot,
153
154
  ifBlock: () => ifBlock,
154
155
  injectStyle: () => injectStyle,
@@ -336,12 +337,15 @@ var import_profiling = require("./profiling.cjs");
336
337
  var import_devtools_hook = require("./devtools-hook.cjs");
337
338
  var import_interaction_config = require("./hydration/interaction-config.cjs");
338
339
  var import_event_capture = require("./hydration/event-capture.cjs");
340
+ var import_control_capture = require("./hydration/control-capture.cjs");
339
341
  var import_sanitize_url = require("./sanitize-url.cjs");
340
342
  var import_html_tree_validation = require("./html-tree-validation.cjs");
341
343
  var import_component_flags = require("./component-flags.cjs");
342
344
  var import_error_codes_client_generated = require("./error-codes.client.generated.cjs");
343
345
  var import_form_diagnostics = require("./form-diagnostics.cjs");
344
346
  var import_dom_binding_protocol = require("./dom-binding-protocol.cjs");
347
+ var import_hydration_markers = require("./hydration-markers.cjs");
348
+ var import_runtime_tags = require("./runtime-tags.cjs");
345
349
  var import_dom_focused_move = require("./dom-focused-move.cjs");
346
350
  var import_stream_protocol = require("./stream-protocol.cjs");
347
351
  var import_renderer_bridge = require("./renderer-bridge.cjs");
@@ -381,7 +385,7 @@ function profileTrackComponent(subject, fallback) {
381
385
  function profilePortalComponent(rawBody) {
382
386
  if (typeof rawBody === "function" && (0, import_profiling.__profileHasComponentMetadata)(rawBody)) return rawBody;
383
387
  const descriptor = rawBody;
384
- return descriptor != null && descriptor.$$kind === ELEMENT_TAG && typeof descriptor.type === "function" ? descriptor.type : null;
388
+ return descriptor != null && descriptor.$$kind === import_runtime_tags.ELEMENT_TAG && typeof descriptor.type === "function" ? descriptor.type : null;
385
389
  }
386
390
  function ensureHooks(scope) {
387
391
  return scope.hooks ?? (scope.hooks = /* @__PURE__ */ new Map());
@@ -688,7 +692,8 @@ function scopeSignalOwner(scope) {
688
692
  }
689
693
  function runWithBlockSignalOwner(scope, callback) {
690
694
  const owner = scopeSignalOwner(scope);
691
- if (owner !== void 0) (0, import_document_owner.streamedSignalOwnerActivator)?.(owner);
695
+ if (owner !== void 0 && (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null))
696
+ (0, import_document_owner.streamedSignalOwnerActivator)?.(owner);
692
697
  return owner === void 0 || (0, import_owner_context.currentSignalOwner)() === owner ? callback() : (0, import_owner_context.runWithSignalOwner)(owner, callback);
693
698
  }
694
699
  function disposeNativeStyleBinding(binding) {
@@ -782,6 +787,8 @@ function nativeProjectionBinding(owner, slotIndex, el, compute, fields) {
782
787
  nativePresentationBinding(owner, slotIndex, el, nativeProjectionBody, { el, compute, fields });
783
788
  }
784
789
  function nativePresentationBinding(owner, slotIndex, el, body, props) {
790
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null && el.ownerDocument !== hydrateAttributeProbe.document)
791
+ throw new PresentationAdoptionMiss(void 0, false);
785
792
  let binding = owner.slots[slotIndex];
786
793
  if (binding === void 0) {
787
794
  const block = createBlock("control-flow", owner.block, el, null, null, body, props);
@@ -813,6 +820,8 @@ function enableNativeReadCollection(abi = 1) {
813
820
  ensureNativeReadDriver();
814
821
  }
815
822
  function beginNativeReadScope(scope, abi = 1) {
823
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null)
824
+ throw new PresentationAdoptionMiss(void 0, false);
816
825
  if (abi !== 1) throw new Error((0, import_error_codes_client_generated.formatClientError)(58));
817
826
  const block = CURRENT_BLOCK;
818
827
  const owner = scope ?? CURRENT_SCOPE;
@@ -820,6 +829,7 @@ function beginNativeReadScope(scope, abi = 1) {
820
829
  return ensureNativeReadDriver().beginScope(owner, block);
821
830
  }
822
831
  function beginActiveNativeReadScope(scope) {
832
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return -1;
823
833
  const block = CURRENT_BLOCK;
824
834
  return block === null ? -1 : NATIVE_READ_DRIVER.beginScope(scope, block);
825
835
  }
@@ -1054,13 +1064,13 @@ function hydrationMismatchMode(el) {
1054
1064
  }
1055
1065
  function warnHydrationValueMismatch(loc, what, serverVal, clientVal) {
1056
1066
  if (process.env.NODE_ENV === "production") return;
1057
- if (!loc) return;
1067
+ if (!loc || hydrateAttributeProbe !== null) return;
1058
1068
  console.error(
1059
1069
  `Octane hydration mismatch at ${loc}: server rendered ${what} ${JSON.stringify(serverVal)} but the client rendered ${JSON.stringify(clientVal)}. The client value was used. If this difference is intentional (e.g. a timestamp or random id), add suppressHydrationWarning to the element.`
1060
1070
  );
1061
1071
  }
1062
1072
  function warnHydrationKeptServerValue(loc, what, serverVal, clientVal) {
1063
- if (process.env.NODE_ENV === "production" || !loc) return;
1073
+ if (process.env.NODE_ENV === "production" || !loc || hydrateAttributeProbe !== null) return;
1064
1074
  console.error(
1065
1075
  `Octane hydration mismatch at ${loc}: server rendered ${what} ${JSON.stringify(serverVal)} but the client rendered ${JSON.stringify(clientVal)}. The server value was kept. If this difference is intentional, add suppressHydrationWarning to the element.`
1066
1076
  );
@@ -1079,7 +1089,7 @@ function describeHydrationNode(node) {
1079
1089
  }
1080
1090
  function warnHydrationStructuralMismatch(loc, expected, actual) {
1081
1091
  if (process.env.NODE_ENV === "production") return;
1082
- if (!loc) return;
1092
+ if (!loc || hydrateAttributeProbe !== null) return;
1083
1093
  console.error(
1084
1094
  `Octane hydration mismatch at ${loc}: the client expected ${expected} but the server rendered ${actual}. The mismatched subtree was rebuilt on the client.`
1085
1095
  );
@@ -1139,7 +1149,6 @@ let NEXT_EFFECT_RENDER_VERSION = 1;
1139
1149
  const ACTIVE_WARM_PLANS = [];
1140
1150
  let NEXT_WARM_EPISODE = 1;
1141
1151
  let CURRENT_WARM_EPISODE = 0;
1142
- const RENDERER_REGION_OWNER = /* @__PURE__ */ Symbol.for("octane.renderer-region.owner");
1143
1152
  const RENDERER_REGION_DOM_OWNERS = /* @__PURE__ */ new WeakMap();
1144
1153
  let RENDERER_REGION_OWNER_COUNT = 0;
1145
1154
  const RENDERER_REGION_DOM_BINDINGS = /* @__PURE__ */ new WeakMap();
@@ -3016,19 +3025,17 @@ function vtCaptureElements(block, owner) {
3016
3025
  }
3017
3026
  const VT_SCOPE_OWNERS = /* @__PURE__ */ new WeakMap();
3018
3027
  const VT_INVALID_SCOPE_WARNED = /* @__PURE__ */ new WeakSet();
3019
- const VT_SCOPE_STYLE_ID = "octane-view-transition-scope";
3020
- const VT_SCOPE_CSS = '[vt-scope="element"]{view-transition-scope:all!important}';
3021
3028
  const VT_SCOPE_STYLED_DOCUMENTS = /* @__PURE__ */ new WeakSet();
3022
3029
  function vtInjectScopeStyle(host) {
3023
3030
  if (DEFERRED_LAYOUT_DRIVER?.stageAction(() => vtInjectScopeStyle(host), true) === true) return;
3024
3031
  const owner = host.ownerDocument;
3025
3032
  if (VT_SCOPE_STYLED_DOCUMENTS.has(owner)) return;
3026
3033
  if ((STAGED_DOM?.view(owner) ?? owner).querySelector(
3027
- `style[data-octane="${VT_SCOPE_STYLE_ID}"],style[data-href~="octane-${VT_SCOPE_STYLE_ID}"]`
3034
+ `style[data-octane="${import_css.VIEW_TRANSITION_SCOPE_STYLE_ID}"],style[data-href~="octane-${import_css.VIEW_TRANSITION_SCOPE_STYLE_ID}"]`
3028
3035
  ) === null) {
3029
3036
  const style = (STAGED_DOM?.view(owner) ?? owner).createElement("style");
3030
- (STAGED_DOM?.view(style) ?? style).setAttribute("data-octane", VT_SCOPE_STYLE_ID);
3031
- (STAGED_DOM?.view(style) ?? style).textContent = VT_SCOPE_CSS;
3037
+ (STAGED_DOM?.view(style) ?? style).setAttribute("data-octane", import_css.VIEW_TRANSITION_SCOPE_STYLE_ID);
3038
+ (STAGED_DOM?.view(style) ?? style).textContent = import_css.VIEW_TRANSITION_SCOPE_CSS;
3032
3039
  domNode(owner.head).appendChild(style);
3033
3040
  }
3034
3041
  VT_SCOPE_STYLED_DOCUMENTS.add(owner);
@@ -6572,7 +6579,8 @@ function captureRenderPhaseUpdate(cell, key) {
6572
6579
  function renderBlock(block) {
6573
6580
  if (import_document_owner.signalDocumentEnabled || block.idState.renderOwner?.signalOwner !== void 0) {
6574
6581
  const owner = scopeSignalOwner(block);
6575
- if (owner !== void 0) (0, import_document_owner.streamedSignalOwnerActivator)?.(owner);
6582
+ if (owner !== void 0 && (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null))
6583
+ (0, import_document_owner.streamedSignalOwnerActivator)?.(owner);
6576
6584
  if (owner !== void 0 && (0, import_owner_context.currentSignalOwner)() !== owner) {
6577
6585
  (0, import_owner_context.runWithSignalOwner)(owner, () => renderBlock(block));
6578
6586
  return;
@@ -6832,7 +6840,7 @@ function returnSlotTail(block, state) {
6832
6840
  return null;
6833
6841
  }
6834
6842
  function renderReturnedValue(block, out) {
6835
- const isComponentDescriptor = out !== null && out.$$kind === ELEMENT_TAG && out.key == null && typeof out.type === "function";
6843
+ const isComponentDescriptor = out !== null && out.$$kind === import_runtime_tags.ELEMENT_TAG && out.key == null && typeof out.type === "function";
6836
6844
  const existingRet = block.slots[0];
6837
6845
  let replacedStart = null;
6838
6846
  let replacedEnd = null;
@@ -7385,6 +7393,8 @@ function resolveSlot(slot) {
7385
7393
  return typeof __OCTANE_PROFILE_ENABLED__ !== "undefined" && __OCTANE_PROFILE_ENABLED__ ? (0, import_profiling.__profileResolveHook)(resolved, typeof slot === "symbol" ? slot : void 0) : resolved;
7386
7394
  }
7387
7395
  function nativeLocalHook(name, initialize, dispose, slot) {
7396
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null)
7397
+ throw new PresentationAdoptionMiss(void 0, false);
7388
7398
  slot = resolveSlot(slot);
7389
7399
  if (slot === void 0 || CURRENT_SCOPE === null) missingSlot(name);
7390
7400
  const scope = CURRENT_SCOPE;
@@ -8403,7 +8413,6 @@ function useEffectEvent(fn, slot) {
8403
8413
  return cell.impl.apply(void 0, args);
8404
8414
  });
8405
8415
  }
8406
- const CONTEXT_TAG = /* @__PURE__ */ Symbol.for("octane.context");
8407
8416
  // @__NO_SIDE_EFFECTS__
8408
8417
  function createContext(defaultValue) {
8409
8418
  const ctx = function ProviderBody(props, scope) {
@@ -8437,7 +8446,7 @@ function __createCompiledContext(defaultValue) {
8437
8446
  return initializeContext(ctx, defaultValue);
8438
8447
  }
8439
8448
  function initializeContext(ctx, defaultValue) {
8440
- ctx.$$kind = CONTEXT_TAG;
8449
+ ctx.$$kind = import_runtime_tags.CONTEXT_TAG;
8441
8450
  ctx.defaultValue = defaultValue;
8442
8451
  ctx.$$version = 0;
8443
8452
  (0, import_context_identity.registerContext)(ctx);
@@ -8521,22 +8530,28 @@ function provideContext(scope, context, value) {
8521
8530
  if (had) values.set(context, previous);
8522
8531
  else values.delete(context);
8523
8532
  });
8524
- if (had) {
8533
+ if (had && (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null)) {
8525
8534
  context.$$version++;
8526
8535
  (0, import_context_epoch.bumpContextEpoch)();
8527
8536
  }
8528
8537
  values.set(context, value);
8529
8538
  }
8530
- const CHILDREN_BLOCK = /* @__PURE__ */ Symbol.for("octane.childrenBlock");
8531
8539
  const CHILDREN_BODY = /* @__PURE__ */ Symbol.for("octane.childrenBody");
8540
+ const CHILDREN_DIAGNOSTIC_CAPTURES = /* @__PURE__ */ Symbol.for(
8541
+ "octane.childrenDiagnosticCaptures"
8542
+ );
8532
8543
  function markSingleRoot(component) {
8533
8544
  component.$$singleRoot = true;
8534
8545
  return component;
8535
8546
  }
8536
8547
  function markChildrenBlock(fn, body) {
8537
8548
  if (typeof fn === "function") {
8538
- fn[CHILDREN_BLOCK] = true;
8549
+ fn[import_runtime_tags.CHILDREN_BLOCK_TAG] = true;
8539
8550
  if (body !== void 0) fn[CHILDREN_BODY] = body;
8551
+ if (process.env.NODE_ENV !== "production") {
8552
+ const captures = arguments[2];
8553
+ if (captures !== void 0) fn[CHILDREN_DIAGNOSTIC_CAPTURES] = captures;
8554
+ }
8540
8555
  }
8541
8556
  return fn;
8542
8557
  }
@@ -8544,7 +8559,7 @@ function descriptorChildren(component) {
8544
8559
  return component;
8545
8560
  }
8546
8561
  function isChildrenBlock(value) {
8547
- return typeof value === "function" && value[CHILDREN_BLOCK] === true;
8562
+ return typeof value === "function" && value[import_runtime_tags.CHILDREN_BLOCK_TAG] === true;
8548
8563
  }
8549
8564
  function childrenAsBody(children) {
8550
8565
  if (typeof children === "function") return children;
@@ -8680,13 +8695,239 @@ const HYDRATE_STRATEGY_TYPES = /* @__PURE__ */ new Set([
8680
8695
  "never",
8681
8696
  "dynamic"
8682
8697
  ]);
8683
- const HYDRATE_MARKER_SELECTOR = "[data-octane-hydrate-id]";
8684
8698
  const HYDRATE_STREAM_ERROR_ATTR = "data-oct-err";
8685
8699
  const HYDRATE_STREAM_BOUNDARY_SELECTOR = `template[${import_constants.STREAM_BOUNDARY_ATTR}]`;
8686
8700
  const HYDRATE_STREAM_SCAN_MASK = 1 | 128;
8687
8701
  let hydrateStreamWaitCleanups = null;
8688
8702
  let preservedHydrateActivations = null;
8689
8703
  let preservedHydrateActivationCount = 0;
8704
+ let initialHydrateAttributes = null;
8705
+ let hydrateAttributeProbe = null;
8706
+ function copyHydrateDiagnosticIds(ids) {
8707
+ const first = { prefix: ids.prefix, next: ids.next };
8708
+ let copy = first;
8709
+ while (true) {
8710
+ if (ids.limit !== void 0) copy.limit = ids.limit;
8711
+ if (ids.signalState !== void 0) copy.signalState = { ...ids.signalState };
8712
+ if (ids.overflow === void 0) return first;
8713
+ ids = ids.overflow;
8714
+ copy = copy.overflow = { prefix: ids.prefix, next: ids.next };
8715
+ }
8716
+ }
8717
+ function copyHydrateDiagnosticContexts(scope) {
8718
+ let contexts = null;
8719
+ const add = (values) => {
8720
+ if (values === null) return;
8721
+ for (const [context, value] of values) {
8722
+ contexts ??= /* @__PURE__ */ new Map();
8723
+ if (!contexts.has(context)) contexts.set(context, value);
8724
+ }
8725
+ };
8726
+ for (let current = scope; current !== null; current = current.parent)
8727
+ add(current.$$ctxValues);
8728
+ for (let block = scope.block.parentBlock; block !== null; block = block.parentBlock)
8729
+ add(block.$$ctxValues);
8730
+ return contexts;
8731
+ }
8732
+ function changedHydrateDiagnosticContexts(initial, next) {
8733
+ if ((initial?.size ?? 0) !== (next?.size ?? 0)) return true;
8734
+ if (initial !== null) {
8735
+ for (const [context, value] of initial) {
8736
+ if (next === null || !next.has(context) || !Object.is(value, next.get(context))) return true;
8737
+ }
8738
+ }
8739
+ return false;
8740
+ }
8741
+ function changedHydrateDiagnosticCaptures(initial, next) {
8742
+ if (initial.__data === void 0 || next.__data === void 0)
8743
+ return changedHydrateDiagnosticChildren(initial.children, next.children);
8744
+ if (initial.__data.length !== next.__data.length) return true;
8745
+ for (let i = 0; i < initial.__data.length; i++) {
8746
+ if (!Object.is(initial.__data[i], next.__data[i])) return true;
8747
+ }
8748
+ return false;
8749
+ }
8750
+ function changedHydrateDiagnosticChildren(initial, next) {
8751
+ if (initial === next) return false;
8752
+ if (typeof initial !== "function" || typeof next !== "function") return true;
8753
+ try {
8754
+ const body = initial[CHILDREN_BODY];
8755
+ const initialCaptures = initial[CHILDREN_DIAGNOSTIC_CAPTURES];
8756
+ const nextCaptures = next[CHILDREN_DIAGNOSTIC_CAPTURES];
8757
+ if (initialCaptures === void 0 && nextCaptures === void 0 && isChildrenBlock(initial) && isChildrenBlock(next))
8758
+ return false;
8759
+ if (body === void 0 || body !== next[CHILDREN_BODY] || initialCaptures == null || nextCaptures == null)
8760
+ return true;
8761
+ const before = initialCaptures();
8762
+ const after = nextCaptures();
8763
+ if (before.length !== after.length) return true;
8764
+ for (let i = 0; i < before.length; i++) {
8765
+ if (!Object.is(before[i], after[i])) return true;
8766
+ }
8767
+ return false;
8768
+ } catch {
8769
+ return true;
8770
+ }
8771
+ }
8772
+ function recordInitialHydrateAttribute(el, name, server, next) {
8773
+ const probe = hydrateAttributeProbe;
8774
+ const original = probe?.originals.get(el);
8775
+ if (original === void 0) return;
8776
+ let values = probe.attributes.get(original);
8777
+ if (values === void 0) probe.attributes.set(original, values = /* @__PURE__ */ new Map());
8778
+ const previous = values.get(name);
8779
+ values.set(name, {
8780
+ server: previous === void 0 ? server : previous.server,
8781
+ next,
8782
+ suppressed: isHydrationSuppressed(el),
8783
+ checked: false
8784
+ });
8785
+ }
8786
+ function checkInitialHydrateAttribute(hydration, el, name, server) {
8787
+ const initial = hydration.attributeBaselines?.attributes.get(el)?.get(name);
8788
+ if (initial === void 0) return false;
8789
+ if (initial.checked) return true;
8790
+ initial.checked = true;
8791
+ if (!initial.suppressed && initial.server !== initial.next && !(name !== "class" && name !== "style" && initial.next !== null && isAttributeParserNormalizedMatch(initial.server, initial.next)) && import_dom_binding_claims.domBindingClaims.get(el)?.get(name) !== server) {
8792
+ warnHydrationValueMismatch(
8793
+ el.__oct_loc,
8794
+ name === "style" ? "style" : `attribute \`${name}\``,
8795
+ name === "style" ? initial.server ?? "" : initial.server,
8796
+ name === "style" ? initial.next ?? "" : initial.next
8797
+ );
8798
+ }
8799
+ return true;
8800
+ }
8801
+ function probeInitialHydrateAttributes(state) {
8802
+ const snapshot = initialHydrateAttributes?.get(state);
8803
+ if (snapshot === void 0 || !changedHydrateDiagnosticCaptures(snapshot.props, state.props) && !changedHydrateDiagnosticContexts(
8804
+ snapshot.contexts,
8805
+ copyHydrateDiagnosticContexts(
8806
+ CURRENT_SCOPE?.block === state.parentBlock ? CURRENT_SCOPE : state.parentBlock
8807
+ )
8808
+ ))
8809
+ return;
8810
+ try {
8811
+ return collectInitialHydrateAttributes(state, snapshot);
8812
+ } catch {
8813
+ return;
8814
+ }
8815
+ }
8816
+ function collectInitialHydrateAttributes(state, snapshot) {
8817
+ const ownerDocument = document.implementation.createHTMLDocument("");
8818
+ const originalWrapper = state.wrapper;
8819
+ const source = STAGED_DOM?.view(originalWrapper) ?? originalWrapper;
8820
+ const template2 = ownerDocument.createElement("template");
8821
+ template2.innerHTML = source.outerHTML;
8822
+ const wrapper = ownerDocument.adoptNode(template2.content.firstElementChild);
8823
+ const probe = {
8824
+ document: ownerDocument,
8825
+ originals: /* @__PURE__ */ new WeakMap(),
8826
+ attributes: /* @__PURE__ */ new WeakMap(),
8827
+ boundaries: /* @__PURE__ */ new WeakMap()
8828
+ };
8829
+ probe.originals.set(wrapper, originalWrapper);
8830
+ const originals = source.querySelectorAll("*");
8831
+ const copies = wrapper.querySelectorAll("*");
8832
+ if (originals.length !== copies.length) return;
8833
+ for (let i = 0; i < originals.length; i++) {
8834
+ const original = originals[i];
8835
+ const copy = copies[i];
8836
+ if (copy.localName !== original.localName || copy.namespaceURI !== original.namespaceURI || probe.originals.get(copy.parentElement) !== (STAGED_DOM?.view(original) ?? original).parentElement)
8837
+ return;
8838
+ probe.originals.set(copy, original);
8839
+ }
8840
+ const start = wrapper.firstChild;
8841
+ if (start === null || !isBlockOpen(start)) return;
8842
+ const end = findMatchingClose(start, /* @__PURE__ */ new WeakMap());
8843
+ const initialChild = (_props, scope, extra) => {
8844
+ if (state.loadedBody !== null) state.loadedBody(snapshot.props.__data, scope, extra);
8845
+ else childrenAsBody(snapshot.props.children)(void 0, scope, extra);
8846
+ };
8847
+ const body = (_props, scope) => {
8848
+ tryBlock(scope, 0, wrapper, initialChild, null, null, end);
8849
+ };
8850
+ const block = createBlock("control-flow", null, wrapper, start, end, body, void 0);
8851
+ block.idState = copyHydrateDiagnosticIds(snapshot.ids);
8852
+ block.$$ctxValues = snapshot.contexts === null ? null : new Map(snapshot.contexts);
8853
+ const hydration = new HydrationCapability(block, start.nextSibling, null);
8854
+ if (state.seedRaw !== null) hydration.seeds = hydration.parseSeeds(state.seedRaw);
8855
+ hydration.protectRootAnchor(end);
8856
+ const capture = createOffscreenCapture();
8857
+ const previousHydration = currentHydration;
8858
+ const previousCapture = WIP_CAPTURE;
8859
+ const previousProbe = hydrateAttributeProbe;
8860
+ const previousTransaction = ROOT_RENDER_TRANSACTION;
8861
+ const previousJournal = TRANSITION_JOURNAL;
8862
+ const previousAttempt = ACTIVE_TRANSITION_ATTEMPT;
8863
+ const previousScopedReadTracking = SCOPED_READ_TRACKING;
8864
+ const previousScopedReads = SCOPED_READS;
8865
+ const previousWarm = CURRENT_WARM;
8866
+ const previousWarmClaims = CURRENT_WARM_CLAIMS;
8867
+ const previousWarmEpisode = CURRENT_WARM_EPISODE;
8868
+ const previousWarmPlans = ACTIVE_WARM_PLANS.splice(0);
8869
+ const previousStagedDom = STAGED_DOM;
8870
+ const previousStagedCapture = STAGED_COMMIT_CAPTURE;
8871
+ const previousPresentation = PRESENTATION_HYDRATION;
8872
+ const previousSelectSyncs = SELECT_SYNCS;
8873
+ const previousSelectDefaultSyncs = SELECT_DEFAULT_SYNCS;
8874
+ const previousFormChecks = DEV_FORM_CHECKS;
8875
+ const previousAutofocus = AUTOFOCUS_QUEUE;
8876
+ const previousNative = (0, import_read_protocol.setNativeAdoptionResolver)(null);
8877
+ const refDetachCheckpoint = refDetachQueue.length;
8878
+ currentHydration = hydration;
8879
+ WIP_CAPTURE = capture;
8880
+ hydrateAttributeProbe = probe;
8881
+ ROOT_RENDER_TRANSACTION = null;
8882
+ TRANSITION_JOURNAL = null;
8883
+ ACTIVE_TRANSITION_ATTEMPT = null;
8884
+ SCOPED_READ_TRACKING = false;
8885
+ SCOPED_READS = null;
8886
+ CURRENT_WARM = null;
8887
+ CURRENT_WARM_CLAIMS = null;
8888
+ CURRENT_WARM_EPISODE = 0;
8889
+ STAGED_DOM = null;
8890
+ STAGED_COMMIT_CAPTURE = null;
8891
+ PRESENTATION_HYDRATION = null;
8892
+ SELECT_SYNCS = [];
8893
+ SELECT_DEFAULT_SYNCS = [];
8894
+ DEV_FORM_CHECKS = [];
8895
+ AUTOFOCUS_QUEUE = [];
8896
+ try {
8897
+ renderBlock(block);
8898
+ drainHydrationRenderPhaseUpdates(block);
8899
+ hydration.flushClassWrites();
8900
+ } catch {
8901
+ } finally {
8902
+ try {
8903
+ disposeWip({ block, start, end, capture, domParent: wrapper, refDetachCheckpoint });
8904
+ drainHydrationRenderPhaseUpdates(block);
8905
+ } finally {
8906
+ (0, import_read_protocol.setNativeAdoptionResolver)(previousNative);
8907
+ currentHydration = previousHydration;
8908
+ WIP_CAPTURE = previousCapture;
8909
+ hydrateAttributeProbe = previousProbe;
8910
+ ROOT_RENDER_TRANSACTION = previousTransaction;
8911
+ TRANSITION_JOURNAL = previousJournal;
8912
+ ACTIVE_TRANSITION_ATTEMPT = previousAttempt;
8913
+ SCOPED_READ_TRACKING = previousScopedReadTracking;
8914
+ SCOPED_READS = previousScopedReads;
8915
+ CURRENT_WARM = previousWarm;
8916
+ CURRENT_WARM_CLAIMS = previousWarmClaims;
8917
+ CURRENT_WARM_EPISODE = previousWarmEpisode;
8918
+ ACTIVE_WARM_PLANS.length = 0;
8919
+ ACTIVE_WARM_PLANS.push(...previousWarmPlans);
8920
+ STAGED_DOM = previousStagedDom;
8921
+ STAGED_COMMIT_CAPTURE = previousStagedCapture;
8922
+ PRESENTATION_HYDRATION = previousPresentation;
8923
+ SELECT_SYNCS = previousSelectSyncs;
8924
+ SELECT_DEFAULT_SYNCS = previousSelectDefaultSyncs;
8925
+ DEV_FORM_CHECKS = previousFormChecks;
8926
+ AUTOFOCUS_QUEUE = previousAutofocus;
8927
+ }
8928
+ }
8929
+ return probe;
8930
+ }
8690
8931
  function releasePreservedHydrateActivation(state) {
8691
8932
  if (preservedHydrateActivations?.delete(state)) preservedHydrateActivationCount--;
8692
8933
  }
@@ -8869,6 +9110,7 @@ function createHydrateBoundaryBody(state, renderChild, pendingBody) {
8869
9110
  }
8870
9111
  function failHydrateBoundary(state, error) {
8871
9112
  if (state.hasError || state.block.disposed) return;
9113
+ if (process.env.NODE_ENV !== "production") initialHydrateAttributes?.delete(state);
8872
9114
  cleanupHydrateStreamWait(state);
8873
9115
  state.hasError = true;
8874
9116
  state.error = error;
@@ -8986,6 +9228,7 @@ function teardownHydrateBoundary(state) {
8986
9228
  }
8987
9229
  if (DEFERRED_LAYOUT_DRIVER?.stageAction(() => teardownHydrateBoundary(state), true) === true)
8988
9230
  return;
9231
+ if (process.env.NODE_ENV !== "production") initialHydrateAttributes?.delete(state);
8989
9232
  cleanupHydrateInstallers(state);
8990
9233
  cleanupHydrateStreamWait(state);
8991
9234
  if (preserved !== void 0) {
@@ -9044,7 +9287,7 @@ function installHydrateInteraction(state, strategy) {
9044
9287
  // whose strategy could not yet be evaluated. Resolved boundaries get none.
9045
9288
  (state.delegatedDynamicIntent ? import_event_capture.HYDRATE_SUPPORTED_INTERACTION_EVENTS : []);
9046
9289
  const events = new Set(ownEvents);
9047
- const descendants = domNode(state.wrapper).querySelectorAll(HYDRATE_MARKER_SELECTOR);
9290
+ const descendants = domNode(state.wrapper).querySelectorAll(import_hydration_markers.HYDRATE_MARKER_SELECTOR);
9048
9291
  for (let i = 0; i < descendants.length; i++) {
9049
9292
  const nestedEvents = hydrateMarkerInteractionEvents(descendants[i]);
9050
9293
  if (nestedEvents !== null) {
@@ -9057,7 +9300,7 @@ function installHydrateInteraction(state, strategy) {
9057
9300
  if (state.hydrated) return;
9058
9301
  const rawTarget = event.target;
9059
9302
  let target = rawTarget instanceof Element ? rawTarget : rawTarget instanceof Node ? (STAGED_DOM?.view(rawTarget) ?? rawTarget).parentElement : null;
9060
- let marker = (STAGED_DOM?.view(target) ?? target)?.closest(HYDRATE_MARKER_SELECTOR) ?? state.wrapper;
9303
+ let marker = (STAGED_DOM?.view(target) ?? target)?.closest(import_hydration_markers.HYDRATE_MARKER_SELECTOR) ?? state.wrapper;
9061
9304
  let matches = ownEvents.includes(event.type);
9062
9305
  const delegatedDynamicMarkers = [];
9063
9306
  while (marker !== null && domNode(state.wrapper).contains(marker)) {
@@ -9072,7 +9315,7 @@ function installHydrateInteraction(state, strategy) {
9072
9315
  }
9073
9316
  if (marker === state.wrapper) break;
9074
9317
  marker = domNode((STAGED_DOM?.view(marker) ?? marker).parentElement)?.closest(
9075
- HYDRATE_MARKER_SELECTOR
9318
+ import_hydration_markers.HYDRATE_MARKER_SELECTOR
9076
9319
  ) ?? null;
9077
9320
  }
9078
9321
  if (!matches) return;
@@ -9365,10 +9608,22 @@ function createHydrateSlot(props, scope, boundaryId, boundaryBody) {
9365
9608
  independent: props.__independent !== void 0
9366
9609
  };
9367
9610
  if (nativeSeedRaw !== null) state.nativeSeedRaw = nativeSeedRaw;
9611
+ if (process.env.NODE_ENV !== "production" && serverPreserved && !state.independent) {
9612
+ const original = hydrateAttributeProbe?.originals.get(wrapper);
9613
+ const inherited = hydration?.attributeBaselines?.boundaries.get(wrapper);
9614
+ const snapshot = inherited ?? {
9615
+ props,
9616
+ ids: copyHydrateDiagnosticIds(idState),
9617
+ contexts: copyHydrateDiagnosticContexts(scope)
9618
+ };
9619
+ (initialHydrateAttributes ??= /* @__PURE__ */ new WeakMap()).set(state, snapshot);
9620
+ if (original !== void 0) hydrateAttributeProbe.boundaries.set(original, snapshot);
9621
+ }
9368
9622
  scope.slots[0] = state;
9369
9623
  registerSlot(scope, state);
9370
9624
  if (!state.independent) (0, import_event_capture.registerHydrationIntentBoundary)(wrapper, intentBoundary);
9371
9625
  block.body = boundaryBody(state);
9626
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return state;
9372
9627
  const initialStrategy = resolveHydrateStrategy(state);
9373
9628
  const pendingIntents = state.independent ? void 0 : (0, import_event_capture.takePendingHydrationIntents)(wrapper);
9374
9629
  if (state.independent) {
@@ -9396,6 +9651,8 @@ function activateHydrateBoundary(state) {
9396
9651
  }
9397
9652
  const hydration = preserved?.hydration ?? new HydrationCapability(block, getNextSibling(state.start), null);
9398
9653
  if (preserved === void 0) {
9654
+ if (process.env.NODE_ENV !== "production")
9655
+ hydration.attributeBaselines = probeInitialHydrateAttributes(state);
9399
9656
  if (state.seedRaw !== null) hydration.seeds = hydration.parseSeeds(state.seedRaw);
9400
9657
  hydration.protectRootAnchor(state.end);
9401
9658
  }
@@ -9470,6 +9727,7 @@ function activateHydrateBoundary(state) {
9470
9727
  if (nativeRecovery !== void 0) {
9471
9728
  noteRecoverableHydrationError(() => nativeRecovery, block);
9472
9729
  state.serverPreserved = false;
9730
+ if (process.env.NODE_ENV !== "production") initialHydrateAttributes?.delete(state);
9473
9731
  state.serverActivationStarted = false;
9474
9732
  state.seedRaw = null;
9475
9733
  state.nativeSeedRaw = void 0;
@@ -9500,6 +9758,7 @@ function activateHydrateBoundary(state) {
9500
9758
  return;
9501
9759
  }
9502
9760
  if (completed) {
9761
+ if (process.env.NODE_ENV !== "production") initialHydrateAttributes?.delete(state);
9503
9762
  releasePreservedHydrateActivation(state);
9504
9763
  spliceOffscreenCapture(capture);
9505
9764
  }
@@ -9609,6 +9868,7 @@ function notifyHydrateBoundary(state, scope) {
9609
9868
  return;
9610
9869
  }
9611
9870
  state.didNotify = true;
9871
+ if (process.env.NODE_ENV !== "production") initialHydrateAttributes?.delete(state);
9612
9872
  cleanupHydrateInstallers(state);
9613
9873
  state.props.onHydrated?.();
9614
9874
  domNode(state.wrapper).removeAttribute(import_constants.HYDRATE_WHEN_ATTR);
@@ -9702,7 +9962,7 @@ const Suspense = /* @__PURE__ */ (0, import_component_flags.markComponentFlags)(
9702
9962
  },
9703
9963
  import_component_flags.COMPONENT_FLAG_BOUNDARY,
9704
9964
  "Suspense",
9705
- /* @__PURE__ */ Symbol.for("octane.suspense")
9965
+ import_runtime_tags.SUSPENSE_TAG
9706
9966
  );
9707
9967
  function initializeViewTransitionComponent() {
9708
9968
  return (0, import_component_flags.markComponentFlags)(
@@ -9768,7 +10028,7 @@ function use(usable) {
9768
10028
  "Do not call use() inside a useMemo() factory. Cached factories can skip context or promise reads; call use() before useMemo() and memoize the returned value instead."
9769
10029
  );
9770
10030
  }
9771
- if (usable && usable.$$kind === CONTEXT_TAG) {
10031
+ if (usable && usable.$$kind === import_runtime_tags.CONTEXT_TAG) {
9772
10032
  return useContextInternal(usable);
9773
10033
  }
9774
10034
  if (usable == null || typeof usable.then !== "function") {
@@ -9776,13 +10036,12 @@ function use(usable) {
9776
10036
  }
9777
10037
  return useThenable(usable);
9778
10038
  }
9779
- const REACT_FOREIGN_CONTEXT_TAG = /* @__PURE__ */ Symbol.for("react.context");
9780
10039
  function useForeignContext(usable, api) {
9781
10040
  if (usable !== null && typeof usable === "object") {
9782
10041
  const bridge = rendererRegionOwnerForBlock(CURRENT_BLOCK);
9783
10042
  const mirror = bridge?.resolveForeignContext?.(usable);
9784
10043
  if (mirror != null) return useContextInternal(mirror);
9785
- if (usable.$$typeof === REACT_FOREIGN_CONTEXT_TAG) {
10044
+ if (usable.$$typeof === import_runtime_tags.REACT_CONTEXT_TAG) {
9786
10045
  throw new Error((0, import_error_codes_client_generated.formatClientError)(18, api));
9787
10046
  }
9788
10047
  }
@@ -9792,7 +10051,7 @@ function useRendererThenable(thenable) {
9792
10051
  return useThenable(thenable, true);
9793
10052
  }
9794
10053
  function useContext(context) {
9795
- if (context && context.$$kind === CONTEXT_TAG) {
10054
+ if (context && context.$$kind === import_runtime_tags.CONTEXT_TAG) {
9796
10055
  return useContextInternal(context);
9797
10056
  }
9798
10057
  return useForeignContext(context, "useContext");
@@ -9821,7 +10080,7 @@ function rendererRegionSuspenseHandler(block) {
9821
10080
  };
9822
10081
  }
9823
10082
  function bindRendererRegionOwner(props) {
9824
- const bridge = props?.[RENDERER_REGION_OWNER];
10083
+ const bridge = props?.[import_runtime_tags.RENDERER_REGION_OWNER_TAG];
9825
10084
  if (bridge === void 0) {
9826
10085
  throw new Error((0, import_error_codes_client_generated.formatClientError)(19));
9827
10086
  }
@@ -10786,7 +11045,6 @@ function memoPublish(slot, value, ...deps) {
10786
11045
  function memoPublishAlways(slot, value) {
10787
11046
  return publishMemoEntry(CURRENT_SCOPE, slot, void 0, value);
10788
11047
  }
10789
- const LAZY_COMPONENT = /* @__PURE__ */ Symbol.for("octane.lazy");
10790
11048
  const LAZY_BODY_CHECK = /* @__PURE__ */ Symbol.for("octane.lazyBodyCheck");
10791
11049
  function markLazyBodyCheck(body, check) {
10792
11050
  Object.defineProperty(body, LAZY_BODY_CHECK, {
@@ -10801,11 +11059,11 @@ function resolveLazyModule(mod) {
10801
11059
  const defaultExport = mod.default;
10802
11060
  if (defaultExport !== void 0) comp = defaultExport;
10803
11061
  }
10804
- if (typeof comp !== "function" || comp[LAZY_COMPONENT] === true) {
11062
+ if (typeof comp !== "function" || comp[import_runtime_tags.LAZY_COMPONENT_TAG] === true) {
10805
11063
  throw new Error(
10806
11064
  (0, import_error_codes_client_generated.formatClientError)(
10807
11065
  10,
10808
- comp?.[LAZY_COMPONENT] === true ? "lazy component" : typeof comp
11066
+ comp?.[import_runtime_tags.LAZY_COMPONENT_TAG] === true ? "lazy component" : typeof comp
10809
11067
  )
10810
11068
  );
10811
11069
  }
@@ -10929,7 +11187,7 @@ function lazy(load) {
10929
11187
  const nestedCheck = current[LAZY_BODY_CHECK];
10930
11188
  return nestedCheck === void 0 || nestedCheck(scope);
10931
11189
  });
10932
- Object.defineProperty(lazyWrapper, LAZY_COMPONENT, {
11190
+ Object.defineProperty(lazyWrapper, import_runtime_tags.LAZY_COMPONENT_TAG, {
10933
11191
  get() {
10934
11192
  return this === lazyWrapper;
10935
11193
  }
@@ -10954,7 +11212,7 @@ function useId(slot) {
10954
11212
  while (owner.limit !== void 0 && owner.next >= owner.limit && owner.overflow !== void 0) {
10955
11213
  owner = owner.overflow;
10956
11214
  }
10957
- s = { id: ":" + owner.prefix + "in-" + (owner.next++).toString(36) + ":" };
11215
+ s = { id: (0, import_hydration_markers.formatUseId)(owner.prefix, owner.next++) };
10958
11216
  ensureHooks(scope).set(slot, s);
10959
11217
  }
10960
11218
  return s.id;
@@ -11539,13 +11797,20 @@ class HydrationCapability {
11539
11797
  ns,
11540
11798
  name.indexOf(":") >= 0 ? name.slice(name.indexOf(":") + 1) : name
11541
11799
  ) : (STAGED_DOM?.view(el) ?? el).getAttribute(name);
11800
+ if (process.env.NODE_ENV !== "production") {
11801
+ if (hydrateAttributeProbe !== null) {
11802
+ recordInitialHydrateAttribute(el, name, server, next);
11803
+ } else {
11804
+ checkInitialHydrateAttribute(this, el, name, server);
11805
+ }
11806
+ }
11542
11807
  if (server === next) return false;
11543
11808
  if (import_dom_binding_claims.domBindingClaims.get(el)?.get(name) === server) return false;
11544
11809
  if (next !== null && isAttributeParserNormalizedMatch(server, next)) return false;
11545
11810
  const mode = hydrationMismatchMode(el);
11546
11811
  if (mode === 0) return true;
11547
11812
  if (mode === 1) return false;
11548
- if (process.env.NODE_ENV !== "production")
11813
+ if (process.env.NODE_ENV !== "production" && !checkInitialHydrateAttribute(this, el, name, server))
11549
11814
  warnHydrationValueMismatch(el.__oct_loc, `attribute \`${name}\``, server, next);
11550
11815
  return true;
11551
11816
  }
@@ -11553,11 +11818,15 @@ class HydrationCapability {
11553
11818
  const mode = hydrationMismatchMode(el);
11554
11819
  const rawServer = (STAGED_DOM?.view(el) ?? el).getAttribute("class");
11555
11820
  const server = absentIsEmpty && rawServer === null ? "" : rawServer;
11821
+ if (process.env.NODE_ENV !== "production") {
11822
+ if (hydrateAttributeProbe !== null) recordInitialHydrateAttribute(el, "class", server, next);
11823
+ else checkInitialHydrateAttribute(this, el, "class", rawServer);
11824
+ }
11556
11825
  if (server === next) return true;
11557
11826
  if (import_dom_binding_claims.domBindingClaims.get(el)?.get("class") === rawServer) return false;
11558
11827
  if (mode === 0) return true;
11559
11828
  if (mode === 1) return false;
11560
- if (process.env.NODE_ENV !== "production")
11829
+ if (process.env.NODE_ENV !== "production" && !checkInitialHydrateAttribute(this, el, "class", rawServer))
11561
11830
  warnHydrationValueMismatch(el.__oct_loc, "attribute `class`", server, next);
11562
11831
  return true;
11563
11832
  }
@@ -11568,7 +11837,11 @@ class HydrationCapability {
11568
11837
  try {
11569
11838
  for (const [el, write] of this.classWrites) {
11570
11839
  const rawTarget = write.remove ? null : write.next;
11571
- if ((STAGED_DOM?.view(el) ?? el).getAttribute("class") === rawTarget) continue;
11840
+ if ((STAGED_DOM?.view(el) ?? el).getAttribute("class") === rawTarget) {
11841
+ if (process.env.NODE_ENV !== "production")
11842
+ this.allowClass(el, write.next, write.absentIsEmpty);
11843
+ continue;
11844
+ }
11572
11845
  if (!this.allowClass(el, write.next, write.absentIsEmpty)) continue;
11573
11846
  if (write.remove) (STAGED_DOM?.view(el) ?? el).removeAttribute("class");
11574
11847
  else if (write.useAttribute)
@@ -11581,7 +11854,21 @@ class HydrationCapability {
11581
11854
  }
11582
11855
  applyStyle(el, value, _prev, staticCss, entries) {
11583
11856
  const mode = hydrationMismatchMode(el);
11584
- if (mode === 1) return true;
11857
+ if (mode === 1) {
11858
+ if (process.env.NODE_ENV !== "production") {
11859
+ if (hydrateAttributeProbe !== null) recordInitialHydrateAttribute(el, "style", null, null);
11860
+ else {
11861
+ const current = STAGED_DOM?.view(el) ?? el;
11862
+ checkInitialHydrateAttribute(
11863
+ this,
11864
+ el,
11865
+ "style",
11866
+ current.hasAttribute("style") ? current.style.cssText : null
11867
+ );
11868
+ }
11869
+ }
11870
+ return true;
11871
+ }
11585
11872
  const style = (STAGED_DOM?.view(el) ?? el).style;
11586
11873
  const hadStyleAttribute = (STAGED_DOM?.view(el) ?? el).hasAttribute("style");
11587
11874
  const before = style.cssText;
@@ -11597,7 +11884,11 @@ class HydrationCapability {
11597
11884
  applyStyleProperty(el, expectedStyle, entries[i], entry);
11598
11885
  }
11599
11886
  }
11600
- const claims = import_dom_binding_claims.domBindingClaims.get(el);
11887
+ let claims = import_dom_binding_claims.domBindingClaims.get(el);
11888
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) {
11889
+ const original = hydrateAttributeProbe.originals.get(el);
11890
+ if (original !== void 0) claims = import_dom_binding_claims.domBindingClaims.get(original);
11891
+ }
11601
11892
  if (claims !== void 0) {
11602
11893
  for (const [channel, published] of claims) {
11603
11894
  if (!channel.startsWith("style:")) continue;
@@ -11611,10 +11902,20 @@ class HydrationCapability {
11611
11902
  }
11612
11903
  const expected = expectedStyle.cssText;
11613
11904
  const expectsStyleAttribute = expected !== "";
11905
+ if (process.env.NODE_ENV !== "production") {
11906
+ if (hydrateAttributeProbe !== null)
11907
+ recordInitialHydrateAttribute(
11908
+ el,
11909
+ "style",
11910
+ hadStyleAttribute ? before : null,
11911
+ expectsStyleAttribute ? expected : null
11912
+ );
11913
+ else checkInitialHydrateAttribute(this, el, "style", hadStyleAttribute ? before : null);
11914
+ }
11614
11915
  if (before === expected && hadStyleAttribute === expectsStyleAttribute) return true;
11615
11916
  if (expectsStyleAttribute) style.cssText = expected;
11616
11917
  else (STAGED_DOM?.view(el) ?? el).removeAttribute("style");
11617
- if (mode === 2 && process.env.NODE_ENV !== "production") {
11918
+ if (mode === 2 && process.env.NODE_ENV !== "production" && !checkInitialHydrateAttribute(this, el, "style", hadStyleAttribute ? before : null)) {
11618
11919
  warnHydrationValueMismatch(el.__oct_loc, "style", before, expected);
11619
11920
  }
11620
11921
  return true;
@@ -12250,6 +12551,8 @@ function preparePresentationSignalValue(args, frame) {
12250
12551
  runWithBlockSignalOwner(scope, () => {
12251
12552
  if (!valid()) throw new Error((0, import_error_codes_client_generated.formatClientError)(77));
12252
12553
  const before = (0, import_event_capture.snapshotHydrationControl)(element);
12554
+ const priorValue = readSignalBinding(handle);
12555
+ const restored = lease === void 0 ? (0, import_control_capture.isRestoredHydrationTextarea)(element, priorValue) : !before.composing && !lease.composing() && typeof priorValue === "string" && before.value !== priorValue.replace(/\r\n?/g, "\n");
12253
12556
  const ctrl = armControlled(element);
12254
12557
  ctrl.composing = before.composing || lease?.composing() === true;
12255
12558
  if (ctrl.composing) element.addEventListener("blur", onCtrlCompositionEnd);
@@ -12271,11 +12574,15 @@ function preparePresentationSignalValue(args, frame) {
12271
12574
  if (lease !== void 0) owner.controlLeases.delete(element);
12272
12575
  if (!binding.disposed && !scope.block.disposed) {
12273
12576
  const snapshot = (0, import_event_capture.snapshotHydrationControl)(element);
12274
- binding.value = element.value;
12275
- binding.pendingControl = snapshot.editRevision > (lease === void 0 ? 0 : before.editRevision);
12577
+ binding.value = priorValue;
12578
+ binding.pendingControl = snapshot.editRevision > (lease === void 0 ? 0 : before.editRevision) || restored;
12276
12579
  installDirectSignalControl(binding);
12277
12580
  if (!binding.pendingControl) (0, import_event_capture.consumeHydrationControl)(element, snapshot.revision);
12278
- if (binding.pendingControl) queueDirectSignalControlAdoption(binding);
12581
+ if (binding.pendingControl)
12582
+ queueDirectSignalControlAdoption(
12583
+ binding,
12584
+ lease === void 0 ? 0 : before.editRevision
12585
+ );
12279
12586
  else {
12280
12587
  const current = readSignalBinding(handle);
12281
12588
  ctrl.sawV = true;
@@ -12419,7 +12726,7 @@ function presentationWrite(writer, kind, ...args) {
12419
12726
  return result;
12420
12727
  }
12421
12728
  function bindPresentationView(view, id) {
12422
- view[BINDING_VIEW_ROOT] = "[b;" + id + ";root";
12729
+ view[BINDING_VIEW_ROOT] = (0, import_dom_binding_protocol.bindingRootMarker)(id);
12423
12730
  return (0, import_component_flags.markComponentFlags)(view, import_component_flags.COMPONENT_FLAG_BOUNDARY, view.name);
12424
12731
  }
12425
12732
  const BINDING_CHILDREN_SITE = /* @__PURE__ */ Symbol.for("octane.binding.children-site");
@@ -12449,7 +12756,8 @@ function presentationStructure(writer, kind, marker, ...args) {
12449
12756
  }
12450
12757
  const range = presentationRange(frame, start, marker, kind);
12451
12758
  const expected = args[3][BINDING_VIEW_ROOT];
12452
- if (expected !== "[b;" + range.view + ";root") presentationMiss(false);
12759
+ if (range.view === void 0 || expected !== (0, import_dom_binding_protocol.bindingRootMarker)(range.view))
12760
+ presentationMiss(false);
12453
12761
  writer(...args);
12454
12762
  }
12455
12763
  function setBindingClass(element, receipt, values) {
@@ -12469,7 +12777,7 @@ function hydrationMarkerMultiplicity(data, open) {
12469
12777
  const marker = open ? import_constants.HYDRATION_START : import_constants.HYDRATION_END;
12470
12778
  if (data === marker) return 1;
12471
12779
  if (open && (data === import_constants.HYDRATION_FOR_EMPTY || data === import_constants.HYDRATION_FOR_ITEMS)) return 1;
12472
- if (open && (data.startsWith("[b;") || data.startsWith("[f")) && (0, import_dom_binding_protocol.isBindingOpenComment)(data))
12780
+ if (open && (data.startsWith(import_dom_binding_protocol.BINDING_OPEN_PREFIX) || data.startsWith(import_hydration_markers.HYDRATION_FOR_PREFIX)) && (0, import_dom_binding_protocol.isBindingOpenComment)(data))
12473
12781
  return 1;
12474
12782
  if (data.length < 2 || data.charCodeAt(0) !== marker.charCodeAt(0)) return 0;
12475
12783
  const first = data.charCodeAt(1);
@@ -12531,7 +12839,7 @@ function ssrForMarkerState(node) {
12531
12839
  const data = (STAGED_DOM?.view(node) ?? node).data;
12532
12840
  if (data === import_constants.HYDRATION_FOR_EMPTY) return 0;
12533
12841
  if (data === import_constants.HYDRATION_FOR_ITEMS) return 1;
12534
- return (0, import_dom_binding_protocol.isBindingOpenComment)(data) && data.startsWith("[f") ? data.charCodeAt(2) === 48 ? 0 : 1 : -1;
12842
+ return (0, import_dom_binding_protocol.isForBindingOpenComment)(data) ? data.charCodeAt(import_hydration_markers.HYDRATION_FOR_ARM_INDEX) === 48 ? 0 : 1 : -1;
12535
12843
  }
12536
12844
  function child(node) {
12537
12845
  if (currentHydration !== null) return (STAGED_DOM?.view(node) ?? node).firstChild;
@@ -12565,6 +12873,46 @@ function setText(node, value) {
12565
12873
  (STAGED_DOM?.view(node) ?? node).nodeValue = text;
12566
12874
  }
12567
12875
  const DIRECT_SIGNAL_BINDING = /* @__PURE__ */ Symbol("octane.direct-signal-binding");
12876
+ const CLAIMED_BINDING_VALUE = /* @__PURE__ */ Symbol("octane.claimed-binding-value");
12877
+ function hydrateClaimedBindingCaches(scope, fields) {
12878
+ if (activeHydration() === null) return;
12879
+ const bag = scope.slots[0];
12880
+ for (let i = 0; i < fields.length; i += 3) {
12881
+ const field = fields[i];
12882
+ const node = bag[fields[i + 1]];
12883
+ const element = node.nodeType === 3 ? (STAGED_DOM?.view(node) ?? node).parentNode : node;
12884
+ const claims = import_dom_binding_claims.domBindingClaims.get(element);
12885
+ if (claims === void 0) continue;
12886
+ const channel = fields[i + 2];
12887
+ const tokenOnly = channel === "#text-token";
12888
+ let claimed = claims.has(
12889
+ tokenOnly ? "#text" : channel.startsWith("style:") ? "style:" + (0, import_css.styleName)(channel.slice(6)) : channel
12890
+ );
12891
+ if (channel === "style") {
12892
+ for (const name of claims.keys())
12893
+ if (name.startsWith("style:")) {
12894
+ claimed = true;
12895
+ break;
12896
+ }
12897
+ }
12898
+ if (!claimed) continue;
12899
+ const value = channel === "style" ? (STAGED_DOM?.view(element) ?? element).style.cssText : CLAIMED_BINDING_VALUE;
12900
+ if (typeof field === "number") {
12901
+ const slots = scope.slots[field].block.slots;
12902
+ journalRootProperty(slots, 0, slots[0]);
12903
+ slots[0] = value;
12904
+ } else {
12905
+ const cached = bag[field];
12906
+ if (cached?.[DIRECT_SIGNAL_BINDING] === true) {
12907
+ if (TRANSITION_JOURNAL !== null) journalObjectOnce(cached);
12908
+ cached.value = value;
12909
+ } else if (!tokenOnly) {
12910
+ if (TRANSITION_JOURNAL !== null) journalBag();
12911
+ bag[field] = value;
12912
+ }
12913
+ }
12914
+ }
12915
+ }
12568
12916
  function isSignalHandle(value) {
12569
12917
  return (typeof value === "object" || typeof value === "function") && value !== null && value[import_types.SIGNAL_HANDLE] === true;
12570
12918
  }
@@ -12637,7 +12985,7 @@ function writeDirectSignalBoundValue(binding, value) {
12637
12985
  const element = binding.target;
12638
12986
  const tag = element.localName;
12639
12987
  if (tag === "select") setSelectValue(element, value);
12640
- else setValue(element, value, tag === "textarea" && isWritableSignal(binding.handle));
12988
+ else setValue(element, value);
12641
12989
  }
12642
12990
  function writeDirectSignalBoundChecked(binding, value) {
12643
12991
  setChecked(binding.target, value);
@@ -12766,19 +13114,19 @@ function installDirectSignalControl(binding) {
12766
13114
  )
12767
13115
  );
12768
13116
  }
12769
- function queueDirectSignalControlAdoption(binding) {
13117
+ function queueDirectSignalControlAdoption(binding, priorEditRevision = 0) {
12770
13118
  enqueueEffectEventCommitAction(() => {
12771
13119
  if (binding.disposed || binding.scope.block.disposed || !binding.pendingControl) return;
12772
13120
  (0, import_transition_state.withoutSignalCandidate)(
12773
13121
  () => runWithBlockSignalOwner(binding.scope, () => {
12774
13122
  const element = binding.target;
12775
13123
  const snapshot = (0, import_event_capture.snapshotHydrationControl)(element);
12776
- if (snapshot.editRevision > 0 && isWritableSignal(binding.handle)) {
13124
+ if (isWritableSignal(binding.handle) && (snapshot.editRevision > priorEditRevision || element.localName === "textarea" && Object.is(readSignalBinding(binding.handle), binding.value))) {
12777
13125
  binding.handle.set(directSignalControlValue(binding, snapshot));
12778
13126
  }
12779
13127
  if (binding.disposed || binding.scope.block.disposed) return;
12780
13128
  if (!(0, import_event_capture.consumeHydrationControl)(element, snapshot.revision)) {
12781
- queueDirectSignalControlAdoption(binding);
13129
+ queueDirectSignalControlAdoption(binding, priorEditRevision);
12782
13130
  return;
12783
13131
  }
12784
13132
  binding.pendingControl = false;
@@ -12812,8 +13160,9 @@ function createDirectSignalBinding(scope, target, value, site, policy, name, att
12812
13160
  };
12813
13161
  if (text !== void 0) binding.text = text;
12814
13162
  const controlSnapshot = policy.control?.snapshot(target, site) ?? null;
12815
- binding.pendingControl = activeHydration() !== null && isWritableSignal(handle) && controlSnapshot !== null && controlSnapshot.editRevision > 0;
12816
13163
  const initial = handle === null ? value : readSignalBinding(handle);
13164
+ binding.pendingControl = activeHydration() !== null && isWritableSignal(handle) && controlSnapshot !== null && (controlSnapshot.editRevision > 0 || (0, import_control_capture.isRestoredHydrationTextarea)(target, initial));
13165
+ if (binding.pendingControl) binding.value = initial;
12817
13166
  if (!binding.pendingControl) writeDirectSignalBinding(binding, initial);
12818
13167
  if (STAGED_COMMIT_CAPTURE !== null) {
12819
13168
  DEFERRED_LAYOUT_DRIVER.stageAction(() => {
@@ -12832,6 +13181,8 @@ function bindDirectSignal(scope, previous, target, value, site, policy, name, at
12832
13181
  const kind = policy.kind;
12833
13182
  const prior = typeof previous === "object" && previous !== null && previous[DIRECT_SIGNAL_BINDING] === true ? previous : null;
12834
13183
  const handle = isSignalHandle(value) ? value : null;
13184
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null && handle !== null)
13185
+ throw new PresentationAdoptionMiss(void 0, false);
12835
13186
  if (handle !== null && (!import_document_owner.signalDocumentEnabled || (0, import_owner_context.currentSignalOwner)() !== SCOPE_SIGNAL_OWNERS.get(scope))) {
12836
13187
  if (!import_document_owner.signalDocumentEnabled) enableSignalBindings();
12837
13188
  return runWithBlockSignalOwner(
@@ -13217,10 +13568,10 @@ function applyRefValue(ref, el, prevTarget) {
13217
13568
  }
13218
13569
  ref.current = el;
13219
13570
  }
13220
- const Fragment = /* @__PURE__ */ Symbol.for("octane.Fragment");
13571
+ const Fragment = import_runtime_tags.FRAGMENT_TAG;
13221
13572
  let activityDescriptorDispatch = null;
13222
13573
  function initializeActivitySentinel() {
13223
- const type = /* @__PURE__ */ Symbol.for("octane.Activity");
13574
+ const type = import_runtime_tags.ACTIVITY_TAG;
13224
13575
  activityDescriptorDispatch = { type, body: renderActivityDescriptor };
13225
13576
  return type;
13226
13577
  }
@@ -14440,7 +14791,7 @@ function resolveHostPropSources(el, sources, props, readStyle) {
14440
14791
  if (readStyle !== void 0 && "style" in resolved) resolved.style = readStyle(resolved.style);
14441
14792
  return resolved;
14442
14793
  }
14443
- function setHostPropSources(el, sources, prev, scope, hasNestedChildren = false, readStyle, deferControl = false, writableTextareaValue = false) {
14794
+ function setHostPropSources(el, sources, prev, scope, hasNestedChildren = false, readStyle, deferControl = false) {
14444
14795
  const props = /* @__PURE__ */ new Map();
14445
14796
  const resolved = resolveHostPropSources(el, sources, props, readStyle);
14446
14797
  const tag = el.localName;
@@ -14455,8 +14806,7 @@ function setHostPropSources(el, sources, prev, scope, hasNestedChildren = false,
14455
14806
  props.get("defaultValue")?.value,
14456
14807
  props.get("checked")?.value,
14457
14808
  props.get("defaultChecked")?.value,
14458
- props.get("multiple")?.value,
14459
- writableTextareaValue
14809
+ props.get("multiple")?.value
14460
14810
  );
14461
14811
  return resolved;
14462
14812
  }
@@ -14477,14 +14827,12 @@ function resolveSignalStyle(value, handles, read) {
14477
14827
  }
14478
14828
  return copy ?? value;
14479
14829
  }
14480
- function resolveSignalHostPropSources(sources, readStyle, read = readSignalBinding, textarea = false) {
14830
+ function resolveSignalHostPropSources(sources, readStyle, read = readSignalBinding) {
14481
14831
  const handles = /* @__PURE__ */ new Set();
14482
14832
  let rows;
14483
- let writableTextareaValue = false;
14484
14833
  for (let i = 0; i < sources.length; i++) {
14485
14834
  const source = sources[i];
14486
14835
  if (!source[0]) {
14487
- if (textarea && source[1] === "value") writableTextareaValue = isWritableSignal(source[2]);
14488
14836
  const value = source[1] === "children" || source[1] === "style" && readStyle !== void 0 ? source[2] : source[1] === "style" ? resolveSignalStyle(source[2], handles, read) : isSignalHandle(source[2]) ? (handles.add(source[2]), read(source[2])) : source[2];
14489
14837
  if (value !== source[2]) {
14490
14838
  rows ??= sources.slice();
@@ -14497,7 +14845,6 @@ function resolveSignalHostPropSources(sources, readStyle, read = readSignalBindi
14497
14845
  let copy;
14498
14846
  for (const name of Object.keys(spread)) {
14499
14847
  const current = spread[name];
14500
- if (textarea && name === "value") writableTextareaValue = isWritableSignal(current);
14501
14848
  const value = name === "children" || name === "style" && readStyle !== void 0 ? current : name === "style" ? resolveSignalStyle(current, handles, read) : isSignalHandle(current) ? (handles.add(current), read(current)) : current;
14502
14849
  if (value !== current) {
14503
14850
  copy ??= { ...spread };
@@ -14509,7 +14856,7 @@ function resolveSignalHostPropSources(sources, readStyle, read = readSignalBindi
14509
14856
  rows[i] = [true, copy];
14510
14857
  }
14511
14858
  }
14512
- return textarea ? { sources: rows ?? sources, handles, writableTextareaValue } : { sources: rows ?? sources, handles };
14859
+ return { sources: rows ?? sources, handles };
14513
14860
  }
14514
14861
  function winningSignalHostControl(sources, name) {
14515
14862
  let winner;
@@ -14529,21 +14876,14 @@ function updateSignalHostPropSources(binding) {
14529
14876
  if (binding.disposed || binding.pendingControl || binding.scope.block.disposed) return;
14530
14877
  try {
14531
14878
  runWithBlockSignalOwner(binding.scope, () => {
14532
- const next = resolveSignalHostPropSources(
14533
- binding.sources,
14534
- binding.readStyle,
14535
- void 0,
14536
- binding.element.localName === "textarea"
14537
- );
14879
+ const next = resolveSignalHostPropSources(binding.sources, binding.readStyle);
14538
14880
  binding.resolved = setHostPropSources(
14539
14881
  binding.element,
14540
14882
  next.sources,
14541
14883
  binding.resolved,
14542
14884
  binding.scope,
14543
14885
  binding.hasNestedChildren,
14544
- binding.readStyle,
14545
- false,
14546
- next.writableTextareaValue
14886
+ binding.readStyle
14547
14887
  );
14548
14888
  if (process.env.NODE_ENV !== "production" && STAGED_DOM === null)
14549
14889
  drainDevFormDiagnostics(binding.element);
@@ -14680,22 +15020,22 @@ function disposeSignalHostPropSources(binding) {
14680
15020
  domNode(binding.element).removeEventListener("input", binding.input);
14681
15021
  queueOwnRefDetach(binding.resolved, binding.element);
14682
15022
  }
14683
- function queueSignalHostControlAdoption(binding) {
15023
+ function queueSignalHostControlAdoption(binding, priorValue) {
14684
15024
  enqueueEffectEventCommitAction(() => {
14685
15025
  if (binding.disposed || binding.scope.block.disposed || !binding.pendingControl) return;
14686
15026
  (0, import_transition_state.withoutSignalCandidate)(
14687
15027
  () => runWithBlockSignalOwner(binding.scope, () => {
14688
15028
  const snapshot = (0, import_event_capture.snapshotHydrationControl)(binding.element);
14689
- if (snapshot.editRevision > 0) {
15029
+ const value = winningSignalHostControl(binding.sources, "value");
15030
+ if (snapshot.editRevision > 0 || binding.element.localName === "textarea" && isWritableSignal(value) && Object.is(readSignalBinding(value), priorValue)) {
14690
15031
  const checked = winningSignalHostControl(binding.sources, "checked");
14691
- const value = winningSignalHostControl(binding.sources, "value");
14692
15032
  if (isWritableSignal(checked) && snapshot.checked !== void 0)
14693
15033
  checked.set(snapshot.checked);
14694
15034
  if (isWritableSignal(value)) value.set(snapshot.selectedValues ?? snapshot.value);
14695
15035
  }
14696
15036
  if (binding.disposed || binding.scope.block.disposed) return;
14697
15037
  if (!(0, import_event_capture.consumeHydrationControl)(binding.element, snapshot.revision)) {
14698
- queueSignalHostControlAdoption(binding);
15038
+ queueSignalHostControlAdoption(binding, priorValue);
14699
15039
  return;
14700
15040
  }
14701
15041
  binding.pendingControl = false;
@@ -14808,14 +15148,9 @@ function bindSignalHostPropSources(scope, previous, element, sources, site, hasN
14808
15148
  const controlSnapshot = isWritableSignal(valueControl) || isWritableSignal(checkedControl) ? (0, import_event_capture.snapshotHydrationControl)(element) : null;
14809
15149
  if (controlSnapshot !== null) {
14810
15150
  validateDirectSignalControl(element, site);
14811
- binding.pendingControl ||= activeHydration() !== null && controlSnapshot.editRevision > 0;
15151
+ binding.pendingControl ||= activeHydration() !== null && (controlSnapshot.editRevision > 0 || isWritableSignal(valueControl) && (0, import_control_capture.isRestoredHydrationTextarea)(element, readSignalBinding(valueControl)));
14812
15152
  }
14813
- const next = resolveSignalHostPropSources(
14814
- sources,
14815
- readStyle,
14816
- void 0,
14817
- element.localName === "textarea"
14818
- );
15153
+ const next = resolveSignalHostPropSources(sources, readStyle);
14819
15154
  binding.resolved = setHostPropSources(
14820
15155
  element,
14821
15156
  next.sources,
@@ -14823,8 +15158,7 @@ function bindSignalHostPropSources(scope, previous, element, sources, site, hasN
14823
15158
  scope,
14824
15159
  hasNestedChildren,
14825
15160
  readStyle,
14826
- binding.pendingControl,
14827
- next.writableTextareaValue
15161
+ binding.pendingControl
14828
15162
  );
14829
15163
  if (STAGED_COMMIT_CAPTURE !== null) {
14830
15164
  DEFERRED_LAYOUT_DRIVER.stageAction(() => {
@@ -14846,7 +15180,7 @@ function bindSignalHostPropSources(scope, previous, element, sources, site, hasN
14846
15180
  if (!binding.pendingControl && controlSnapshot !== null)
14847
15181
  (0, import_event_capture.consumeHydrationControl)(element, controlSnapshot.revision);
14848
15182
  }
14849
- if (binding.pendingControl) queueSignalHostControlAdoption(committed);
15183
+ if (binding.pendingControl) queueSignalHostControlAdoption(committed, binding.resolved?.value);
14850
15184
  return committed;
14851
15185
  }
14852
15186
  function isAggregatedFormControlProp(el, name) {
@@ -15163,6 +15497,7 @@ function namespaceHeadElement(headKey, tag, attrs, text, authoredKey) {
15163
15497
  return createElement(namespaceHead, config);
15164
15498
  }
15165
15499
  function injectStyle(id, css, nonce) {
15500
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
15166
15501
  if (typeof document === "undefined") {
15167
15502
  _injectedStyles.add(id);
15168
15503
  return;
@@ -16492,7 +16827,7 @@ function setNativeChangeDiagnosticMetadata(el, value) {
16492
16827
  if (state !== void 0) state.staticNativeChange = false;
16493
16828
  if (value === "runtime") queueDevFormDiagnostic(el, CURRENT_SCOPE ?? void 0, true);
16494
16829
  }
16495
- function setValue(el, value, writableTextareaEcho = false) {
16830
+ function setValue(el, value) {
16496
16831
  if (CURRENT_SCOPE?.block.idState.renderOwner?.controlLeases?.has(el)) presentationMiss(false);
16497
16832
  const input = el;
16498
16833
  const ctrl = armControlled(el);
@@ -16524,17 +16859,14 @@ function setValue(el, value, writableTextareaEcho = false) {
16524
16859
  const prev = ctrl.v;
16525
16860
  ctrl.v = value;
16526
16861
  if (process.env.NODE_ENV !== "production") queueDevFormDiagnostic(el, CURRENT_SCOPE ?? void 0);
16527
- if (writableTextareaEcho) {
16528
- if ((STAGED_DOM?.view(input) ?? input).value === s) return;
16529
- if (!(ctrl.composing && Object.is(prev, value))) (STAGED_DOM?.view(input) ?? input).value = s;
16530
- if ((STAGED_DOM?.view(input) ?? input).defaultValue !== s)
16531
- (STAGED_DOM?.view(input) ?? input).defaultValue = s;
16532
- return;
16533
- }
16534
16862
  if (!(ctrl.composing && Object.is(prev, value)) && valueNeedsWrite(input, value))
16535
16863
  (STAGED_DOM?.view(input) ?? input).value = s;
16536
- if ((STAGED_DOM?.view(input) ?? input).defaultValue !== s)
16537
- (STAGED_DOM?.view(input) ?? input).defaultValue = s;
16864
+ if ((STAGED_DOM?.view(input) ?? input).defaultValue !== s) {
16865
+ const text = STAGED_DOM === null && el.localName === "textarea" ? getFirstChild(el) : null;
16866
+ if (text !== null && text.nodeType === 3 && getNextSibling(text) === null)
16867
+ domNode(text).data = s;
16868
+ else (STAGED_DOM?.view(input) ?? input).defaultValue = s;
16869
+ }
16538
16870
  }
16539
16871
  function setCheckedState(input, value, ctrl) {
16540
16872
  const first = !ctrl.sawC;
@@ -16835,7 +17167,7 @@ function setFormControlSources(el, sources) {
16835
17167
  }
16836
17168
  applyFormControlValues(el, tag, value, defaultValue, checked, defaultChecked, multiple);
16837
17169
  }
16838
- function applyFormControlValues(el, tag, value, defaultValue, checked, defaultChecked, multiple, writableTextareaValue = false) {
17170
+ function applyFormControlValues(el, tag, value, defaultValue, checked, defaultChecked, multiple) {
16839
17171
  const ctrl = armControlled(el);
16840
17172
  const first = !ctrl.formSeen;
16841
17173
  const previousMultiple = ctrl.formMultiple;
@@ -16865,7 +17197,7 @@ function applyFormControlValues(el, tag, value, defaultValue, checked, defaultCh
16865
17197
  }
16866
17198
  if (tag === "textarea") {
16867
17199
  const textarea = el;
16868
- setValue(textarea, value, writableTextareaValue);
17200
+ setValue(textarea, value);
16869
17201
  if (value == null) {
16870
17202
  if (defaultValue != null) setDefaultValue(textarea, defaultValue, first);
16871
17203
  else if (!first && (STAGED_DOM?.view(textarea) ?? textarea).defaultValue !== "")
@@ -17379,6 +17711,8 @@ function registerValuePortalFragmentOwners(portal2, parentBlock, anchor) {
17379
17711
  }
17380
17712
  }
17381
17713
  function renderPortalState(prev, parentBlock, target, rawBody, rawProps, host, env, key = null) {
17714
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null && target.ownerDocument !== hydrateAttributeProbe.document)
17715
+ target = hydrateAttributeProbe.document.createDocumentFragment();
17382
17716
  const hydration = activeHydration();
17383
17717
  if (hydration !== null) {
17384
17718
  return hydration.suspend(
@@ -17477,7 +17811,7 @@ function normalizePortalBody(rawBody, rawProps) {
17477
17811
  if (typeof rawBody === "function") {
17478
17812
  return { body: rawBody, props: rawProps };
17479
17813
  }
17480
- if (rawBody != null && rawBody.$$kind === ELEMENT_TAG && typeof rawBody.type === "function") {
17814
+ if (rawBody != null && rawBody.$$kind === import_runtime_tags.ELEMENT_TAG && typeof rawBody.type === "function") {
17481
17815
  return {
17482
17816
  body: rawBody.type,
17483
17817
  props: rawBody.props
@@ -17491,16 +17825,14 @@ function normalizePortalBody(rawBody, rawProps) {
17491
17825
  function genericPortalBody(value, scope) {
17492
17826
  childSlot(scope, 0, scope.parentNode, value, scope.endMarker);
17493
17827
  }
17494
- const PORTAL_TAG = /* @__PURE__ */ Symbol.for("octane.portal");
17495
17828
  function portalKey(value) {
17496
17829
  return typeof value === "string" || typeof value === "number" ? String(value) : null;
17497
17830
  }
17498
17831
  // @__NO_SIDE_EFFECTS__
17499
17832
  function createPortal(body, target, props = void 0) {
17500
17833
  const key = portalKey(props);
17501
- return { $$kind: PORTAL_TAG, body, target, key, props: key === null ? props : void 0 };
17834
+ return { $$kind: import_runtime_tags.PORTAL_TAG, body, target, key, props: key === null ? props : void 0 };
17502
17835
  }
17503
- const ELEMENT_TAG = /* @__PURE__ */ Symbol.for("octane.element");
17504
17836
  const KEYED_ELEMENT_DESCRIPTORS = /* @__PURE__ */ new WeakSet();
17505
17837
  function elementKeyWasProvided(descriptor) {
17506
17838
  return descriptor.key !== null || KEYED_ELEMENT_DESCRIPTORS.has(descriptor);
@@ -17603,7 +17935,7 @@ function copyScopedElementConfig(type, config, resolve) {
17603
17935
  return props;
17604
17936
  }
17605
17937
  function scopedElementRecord(type, props, key, ref, resolve, invocationSite) {
17606
- const descriptor = { $$kind: ELEMENT_TAG, type, props, key, ref };
17938
+ const descriptor = { $$kind: import_runtime_tags.ELEMENT_TAG, type, props, key, ref };
17607
17939
  if (invocationSite !== void 0) descriptor.__octaneInvocationSite = invocationSite;
17608
17940
  Object.defineProperty(descriptor, SCOPED_CHILDREN_RESOLVER, { value: resolve });
17609
17941
  Object.defineProperty(descriptor, "children", SCOPED_CHILDREN_PROPERTY);
@@ -17659,7 +17991,7 @@ function nativeCreateScopedValue(readElement) {
17659
17991
  return scopedValueDescriptor(createNativeScopedResolver(readElement));
17660
17992
  }
17661
17993
  function scopedValueDescriptor(resolve) {
17662
- const descriptor = { $$kind: ELEMENT_TAG };
17994
+ const descriptor = { $$kind: import_runtime_tags.ELEMENT_TAG };
17663
17995
  Object.defineProperty(descriptor, SCOPED_VALUE_RECORD, { value: resolve });
17664
17996
  Object.defineProperty(descriptor, "type", SCOPED_VALUE_PROPERTIES.type);
17665
17997
  Object.defineProperty(descriptor, "props", SCOPED_VALUE_PROPERTIES.props);
@@ -17727,7 +18059,7 @@ function createElementFromConfig(invocationSite, type, props, children = EMPTY_A
17727
18059
  (0, import_shared_value_helpers.applyElementDefaultProps)(type, p);
17728
18060
  kids = p.children;
17729
18061
  const descriptor = {
17730
- $$kind: ELEMENT_TAG,
18062
+ $$kind: import_runtime_tags.ELEMENT_TAG,
17731
18063
  type,
17732
18064
  props: p,
17733
18065
  key,
@@ -17741,10 +18073,10 @@ function createElementFromConfig(invocationSite, type, props, children = EMPTY_A
17741
18073
  return finalizeElementDescriptor(descriptor);
17742
18074
  }
17743
18075
  function isElementDescriptor(v) {
17744
- return v != null && v.$$kind === ELEMENT_TAG;
18076
+ return v != null && v.$$kind === import_runtime_tags.ELEMENT_TAG;
17745
18077
  }
17746
18078
  function isHostDescriptor(v) {
17747
- return v != null && v.$$kind === ELEMENT_TAG && typeof v.type === "string";
18079
+ return v != null && v.$$kind === import_runtime_tags.ELEMENT_TAG && typeof v.type === "string";
17748
18080
  }
17749
18081
  function isValidElement(v) {
17750
18082
  return isElementDescriptor(v);
@@ -17824,7 +18156,7 @@ function cloneElement(element, config, ...children) {
17824
18156
  );
17825
18157
  } else {
17826
18158
  descriptor = {
17827
- $$kind: ELEMENT_TAG,
18159
+ $$kind: import_runtime_tags.ELEMENT_TAG,
17828
18160
  type: element.type,
17829
18161
  props,
17830
18162
  key,
@@ -17866,7 +18198,7 @@ function cloneAndReplaceElementKey(element, key) {
17866
18198
  } else {
17867
18199
  const copiedGetter = get === SCOPED_VALUE_PROPERTIES.children.get ? () => get.call(element) : get;
17868
18200
  descriptor = {
17869
- $$kind: ELEMENT_TAG,
18201
+ $$kind: import_runtime_tags.ELEMENT_TAG,
17870
18202
  type: element.type,
17871
18203
  props: element.props,
17872
18204
  key,
@@ -17883,7 +18215,7 @@ function cloneAndReplaceElementKey(element, key) {
17883
18215
  }
17884
18216
  } else {
17885
18217
  descriptor = {
17886
- $$kind: ELEMENT_TAG,
18218
+ $$kind: import_runtime_tags.ELEMENT_TAG,
17887
18219
  type: element.type,
17888
18220
  props: element.props,
17889
18221
  key,
@@ -17926,7 +18258,7 @@ function mapIntoChildren(children, out, escapedPrefix, nameSoFar, callback, vali
17926
18258
  children = null;
17927
18259
  type = "object";
17928
18260
  }
17929
- const isLeaf = children === null || type === "string" || type === "number" || type === "bigint" || isElementDescriptor(children) || children != null && children.$$kind === PORTAL_TAG;
18261
+ const isLeaf = children === null || type === "string" || type === "number" || type === "bigint" || isElementDescriptor(children) || children != null && children.$$kind === import_runtime_tags.PORTAL_TAG;
17930
18262
  if (isLeaf) {
17931
18263
  const child2 = children;
17932
18264
  let mapped = callback(child2);
@@ -18052,7 +18384,7 @@ function componentSlot(parentScope, slotKey, domParent, comp, props, anchor, key
18052
18384
  }
18053
18385
  }
18054
18386
  const renderProps = typeof comp === "string" ? {
18055
- $$kind: ELEMENT_TAG,
18387
+ $$kind: import_runtime_tags.ELEMENT_TAG,
18056
18388
  type: comp,
18057
18389
  props,
18058
18390
  key: null,
@@ -18733,8 +19065,8 @@ function warnMissingListKey(owner) {
18733
19065
  }
18734
19066
  }
18735
19067
  function deoptKey(item, index) {
18736
- const element = item != null && item.$$kind === ELEMENT_TAG;
18737
- if (item?.$$kind === PORTAL_TAG && item.key != null) return item.key;
19068
+ const element = item != null && item.$$kind === import_runtime_tags.ELEMENT_TAG;
19069
+ if (item?.$$kind === import_runtime_tags.PORTAL_TAG && item.key != null) return item.key;
18738
19070
  if (element && item.key != null && !ELEMENTS_MISSING_LIST_KEY.has(item)) return item.key;
18739
19071
  if (element && process.env.NODE_ENV !== "production" && activeHydration() === null) {
18740
19072
  warnMissingListKey(CURRENT_BLOCK);
@@ -18743,7 +19075,7 @@ function deoptKey(item, index) {
18743
19075
  }
18744
19076
  const POSITIONAL_CHILDREN = /* @__PURE__ */ new WeakSet();
18745
19077
  function deoptKeyPositional(item, index) {
18746
- return item != null && (item.$$kind === ELEMENT_TAG || item.$$kind === PORTAL_TAG) && item.key != null ? item.key : index;
19078
+ return item != null && (item.$$kind === import_runtime_tags.ELEMENT_TAG || item.$$kind === import_runtime_tags.PORTAL_TAG) && item.key != null ? item.key : index;
18747
19079
  }
18748
19080
  function positionalChildren(children) {
18749
19081
  POSITIONAL_CHILDREN.add(children);
@@ -18995,7 +19327,7 @@ function setDeoptDesc(el, d) {
18995
19327
  const children = record.children;
18996
19328
  const previous = getDeoptDesc(el);
18997
19329
  record = sameDeoptDesc(previous, record, children) ? previous : {
18998
- $$kind: ELEMENT_TAG,
19330
+ $$kind: import_runtime_tags.ELEMENT_TAG,
18999
19331
  type: record.type,
19000
19332
  props: record.props,
19001
19333
  key: record.key,
@@ -19018,7 +19350,7 @@ function fragmentDescriptorChildren(value) {
19018
19350
  }
19019
19351
  function fragmentRefDescriptor(value) {
19020
19352
  return {
19021
- $$kind: ELEMENT_TAG,
19353
+ $$kind: import_runtime_tags.ELEMENT_TAG,
19022
19354
  type: renderFragmentRefDescriptor,
19023
19355
  props: value,
19024
19356
  key: value.key,
@@ -19083,7 +19415,7 @@ function nestedDeoptKeyPrefix(path) {
19083
19415
  return "[" + JSON.stringify(path) + ",";
19084
19416
  }
19085
19417
  function appendScopedDeoptKey(outKeys, path, item, index, key, keyPrefix) {
19086
- const explicit = (isElementDescriptor(item) || item?.$$kind === PORTAL_TAG) && item.key != null;
19418
+ const explicit = (isElementDescriptor(item) || item?.$$kind === import_runtime_tags.PORTAL_TAG) && item.key != null;
19087
19419
  if (path.length === 0) {
19088
19420
  outKeys.push(explicit ? "k" + String(key) : index);
19089
19421
  return keyPrefix;
@@ -19136,7 +19468,7 @@ function flattenReactChildContainer(outItems, outKeys, children, kind, path) {
19136
19468
  }
19137
19469
  }
19138
19470
  function singleDeoptKey(item, key) {
19139
- return (isElementDescriptor(item) || item?.$$kind === PORTAL_TAG) && item.key != null ? "k" + String(key) : 0;
19471
+ return (isElementDescriptor(item) || item?.$$kind === import_runtime_tags.PORTAL_TAG) && item.key != null ? "k" + String(key) : 0;
19140
19472
  }
19141
19473
  function prepareDeoptList(value, forceSingle = false, includeKeyedSingle = true) {
19142
19474
  if (isFragmentDescriptor(value)) {
@@ -19200,7 +19532,7 @@ function flattenDeoptChildrenKeyed(outVals, outKeys, v, prefix) {
19200
19532
  if (prefix === "") {
19201
19533
  outKeys.push(typeof k2 === "string" && k2[0] === ":" ? ":" + k2 : k2);
19202
19534
  } else {
19203
- const explicit = item?.$$kind === ELEMENT_TAG && item.key != null;
19535
+ const explicit = item?.$$kind === import_runtime_tags.ELEMENT_TAG && item.key != null;
19204
19536
  outKeys.push(prefix + ":" + (explicit ? "k" : "i") + String(k2));
19205
19537
  }
19206
19538
  }
@@ -19208,7 +19540,7 @@ function flattenDeoptChildrenKeyed(outVals, outKeys, v, prefix) {
19208
19540
  return;
19209
19541
  }
19210
19542
  outVals.push(v);
19211
- const k = v?.$$kind === ELEMENT_TAG && v.key != null ? v.key : 0;
19543
+ const k = v?.$$kind === import_runtime_tags.ELEMENT_TAG && v.key != null ? v.key : 0;
19212
19544
  outKeys.push(
19213
19545
  prefix === "" ? typeof k === "string" && k[0] === ":" ? ":" + k : k : prefix + ":i0"
19214
19546
  );
@@ -19599,12 +19931,12 @@ function descNeedsBlocks(value) {
19599
19931
  return false;
19600
19932
  }
19601
19933
  if (!isElementDescriptor(value) && (0, import_shared_value_helpers.childrenIterator)(value) !== null) return true;
19602
- if (value.$$kind === ELEMENT_TAG) {
19934
+ if (value.$$kind === import_runtime_tags.ELEMENT_TAG) {
19603
19935
  if (value.type === Fragment || activityDescriptorDispatch !== null && value.type === activityDescriptorDispatch.type)
19604
19936
  return true;
19605
19937
  return typeof value.type === "function" || descNeedsBlocks(value.children);
19606
19938
  }
19607
- if (value.$$kind === PORTAL_TAG) return true;
19939
+ if (value.$$kind === import_runtime_tags.PORTAL_TAG) return true;
19608
19940
  return false;
19609
19941
  }
19610
19942
  function hostElementBody(d, block) {
@@ -19858,7 +20190,7 @@ function compilerCacheArray(value, previous) {
19858
20190
  continue;
19859
20191
  }
19860
20192
  if (item !== null && typeof item === "object") {
19861
- if (item.$$kind !== ELEMENT_TAG) {
20193
+ if (item.$$kind !== import_runtime_tags.ELEMENT_TAG) {
19862
20194
  renderable = false;
19863
20195
  continue;
19864
20196
  }
@@ -20400,7 +20732,7 @@ function childSlot(parentScope, slotKey, domParent, value, anchor, ownEnd, ownsH
20400
20732
  return;
20401
20733
  }
20402
20734
  while (value !== null && (typeof value === "object" || typeof value === "function")) {
20403
- if (value.$$kind === CONTEXT_TAG) {
20735
+ if (value.$$kind === import_runtime_tags.CONTEXT_TAG) {
20404
20736
  value = useContextInternal(value);
20405
20737
  continue;
20406
20738
  }
@@ -20556,7 +20888,7 @@ function childSlot(parentScope, slotKey, domParent, value, anchor, ownEnd, ownsH
20556
20888
  state.start = start;
20557
20889
  state.end = end;
20558
20890
  }
20559
- const portalDesc = value != null && value.$$kind === PORTAL_TAG ? value : null;
20891
+ const portalDesc = value != null && value.$$kind === import_runtime_tags.PORTAL_TAG ? value : null;
20560
20892
  if (portalDesc === null && state.portal != null) {
20561
20893
  teardownPortalState(state.portal);
20562
20894
  state.portal = null;
@@ -21357,7 +21689,8 @@ function hmr(fn) {
21357
21689
  }
21358
21690
  };
21359
21691
  function wrapper(props, scope, extra) {
21360
- if (scope !== void 0) meta.liveBlocks.add(scope.block);
21692
+ if (scope !== void 0 && (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null))
21693
+ meta.liveBlocks.add(scope.block);
21361
21694
  return meta.fn(props, scope, extra);
21362
21695
  }
21363
21696
  Object.defineProperty(wrapper, HMR, {
@@ -21756,7 +22089,8 @@ function mountPassthroughPending(state, thenable) {
21756
22089
  setTryBranch(state, -1);
21757
22090
  scheduleRender(state.parentBlock);
21758
22091
  };
21759
- thenable.then(retry, retry);
22092
+ if (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null)
22093
+ thenable.then(retry, retry);
21760
22094
  }
21761
22095
  function renderPassthroughTry(state) {
21762
22096
  if (state.branch === 0 && state.block !== null) {
@@ -22259,10 +22593,10 @@ function takeInitialSuspenseHydration(state, hydration) {
22259
22593
  if (payload === void 0) {
22260
22594
  payload = {
22261
22595
  seedRaw: typeof stash?.[boundaryId] === "string" ? stash[boundaryId] : null,
22262
- nativeRaw: typeof stash?.[boundaryId + "$signals"] === "string" ? stash[boundaryId + "$signals"] : null
22596
+ nativeRaw: (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null) && typeof stash?.[boundaryId + "$signals"] === "string" ? stash[boundaryId + "$signals"] : null
22263
22597
  };
22264
22598
  (initialStreamedPayloads ??= /* @__PURE__ */ new WeakMap()).set(owner, payload);
22265
- if (stash !== void 0) {
22599
+ if (stash !== void 0 && (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null)) {
22266
22600
  delete stash[boundaryId];
22267
22601
  delete stash[boundaryId + "$signals"];
22268
22602
  }
@@ -22299,7 +22633,8 @@ function takeInitialSuspenseHydration(state, hydration) {
22299
22633
  continue;
22300
22634
  if (attr === import_constants.SUSPENSE_RESOLVED_SEED_ATTR)
22301
22635
  seedRaw = (STAGED_DOM?.view(script) ?? script).textContent;
22302
- else nativeRaw = (STAGED_DOM?.view(script) ?? script).textContent;
22636
+ else if (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null)
22637
+ nativeRaw = (STAGED_DOM?.view(script) ?? script).textContent;
22303
22638
  sidecars.push(script);
22304
22639
  cursor = getNextSibling(script);
22305
22640
  }
@@ -22340,6 +22675,8 @@ function renderInitialSuspenseHydration(state, initial) {
22340
22675
  hydration.claimRootRemainder(initial.end);
22341
22676
  hydration.protectRootAnchor(initial.end);
22342
22677
  const previousHydration = currentHydration;
22678
+ if (process.env.NODE_ENV !== "production")
22679
+ hydration.attributeBaselines = previousHydration?.attributeBaselines;
22343
22680
  if (previousHydration?.retryPresentation !== void 0)
22344
22681
  hydration.retryPresentation = previousHydration.retryPresentation;
22345
22682
  const previousCapture = WIP_CAPTURE;
@@ -22408,7 +22745,8 @@ function renderInitialSuspenseHydration(state, initial) {
22408
22745
  return;
22409
22746
  scheduleRender(state.parentBlock);
22410
22747
  };
22411
- suspended.then(resume, resume);
22748
+ if (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null)
22749
+ suspended.then(resume, resume);
22412
22750
  return;
22413
22751
  }
22414
22752
  initialSuspenseHydrations?.delete(state);
@@ -22475,7 +22813,8 @@ function mountTry(state) {
22475
22813
  const raw = stash !== void 0 ? stash[streamedBoundaryId] : void 0;
22476
22814
  if (typeof raw === "string") scopedSeeds = hydration.parseSeeds(raw);
22477
22815
  const nativeRaw = stash?.[streamedBoundaryId + "$signals"];
22478
- if (typeof nativeRaw === "string") scopedNativeRaw = nativeRaw;
22816
+ if (typeof nativeRaw === "string" && (process.env.NODE_ENV === "production" || hydrateAttributeProbe === null))
22817
+ scopedNativeRaw = nativeRaw;
22479
22818
  adoptCursor = getNextSibling(adoptCursor);
22480
22819
  } else if (
22481
22820
  // A shell hydrated before its streamed segment swaps still has the
@@ -23427,6 +23766,7 @@ function flushStagedReveals() {
23427
23766
  }
23428
23767
  }
23429
23768
  function attachResume(state, thenable) {
23769
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
23430
23770
  if (state.pendingThenable === thenable) return;
23431
23771
  state.pendingThenable = thenable;
23432
23772
  const retry = () => {
@@ -24731,6 +25071,7 @@ function queueCurrentActivityRefs(activity) {
24731
25071
  }
24732
25072
  }
24733
25073
  function suspendHiddenActivity(state, thenable) {
25074
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
24734
25075
  if (state.pendingThenable === thenable) return;
24735
25076
  state.pendingThenable = thenable;
24736
25077
  const block = state.block;
@@ -27718,6 +28059,7 @@ function applyHintAttrs(el, opts) {
27718
28059
  }
27719
28060
  }
27720
28061
  function preload(href, options) {
28062
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27721
28063
  if (process.env.NODE_ENV !== "production") {
27722
28064
  const warning = (0, import_resource_hint_diagnostics.resourceHintWarning)("preload", href, options);
27723
28065
  if (warning !== null) console.error(warning);
@@ -27755,6 +28097,7 @@ function preload(href, options) {
27755
28097
  });
27756
28098
  }
27757
28099
  function preinit(href, options) {
28100
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27758
28101
  if (process.env.NODE_ENV !== "production") {
27759
28102
  const warning = (0, import_resource_hint_diagnostics.resourceHintWarning)("preinit", href, options);
27760
28103
  if (warning !== null) console.error(warning);
@@ -27779,6 +28122,7 @@ function preinit(href, options) {
27779
28122
  }
27780
28123
  }
27781
28124
  function preconnect(href, options) {
28125
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27782
28126
  if (process.env.NODE_ENV !== "production") {
27783
28127
  const warning = (0, import_resource_hint_diagnostics.resourceHintWarning)("preconnect", href, options);
27784
28128
  if (warning !== null) console.error(warning);
@@ -27800,6 +28144,7 @@ function preconnect(href, options) {
27800
28144
  });
27801
28145
  }
27802
28146
  function prefetchDNS(href) {
28147
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27803
28148
  if (process.env.NODE_ENV !== "production") {
27804
28149
  const warning = (0, import_resource_hint_diagnostics.resourceHintWarning)("prefetchDNS", href, arguments[1], arguments.length > 1);
27805
28150
  if (warning !== null) console.error(warning);
@@ -27815,6 +28160,7 @@ function prefetchDNS(href) {
27815
28160
  });
27816
28161
  }
27817
28162
  function preloadModule(href, options) {
28163
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27818
28164
  if (process.env.NODE_ENV !== "production") {
27819
28165
  const warning = (0, import_resource_hint_diagnostics.resourceHintWarning)("preloadModule", href, options);
27820
28166
  if (warning !== null) console.error(warning);
@@ -27836,6 +28182,7 @@ function preloadModule(href, options) {
27836
28182
  });
27837
28183
  }
27838
28184
  function preinitModule(href, options) {
28185
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27839
28186
  if (process.env.NODE_ENV !== "production") {
27840
28187
  const warning = (0, import_resource_hint_diagnostics.resourceHintWarning)("preinitModule", href, options);
27841
28188
  if (warning !== null) console.error(warning);
@@ -27944,6 +28291,7 @@ function warnInvalidStylesheetResource(reason) {
27944
28291
  );
27945
28292
  }
27946
28293
  function stylesheetResource(attrs, invalidReason) {
28294
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27947
28295
  if (process.env.NODE_ENV !== "production" && invalidReason !== void 0) {
27948
28296
  warnInvalidStylesheetResource(invalidReason);
27949
28297
  return;
@@ -27963,6 +28311,7 @@ function stylesheetResource(attrs, invalidReason) {
27963
28311
  state.sheets.add(href);
27964
28312
  }
27965
28313
  function styleResource(attrs, css, development) {
28314
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27966
28315
  if (typeof document === "undefined" || attrs == null) return;
27967
28316
  const href = attrs.href;
27968
28317
  if (typeof href !== "string" || href === "") return;
@@ -27993,6 +28342,7 @@ function resetFloatResourceState() {
27993
28342
  if (typeof window !== "undefined") delete window.$OCTFR;
27994
28343
  }
27995
28344
  function scriptResource(attrs) {
28345
+ if (process.env.NODE_ENV !== "production" && hydrateAttributeProbe !== null) return;
27996
28346
  if (typeof document === "undefined" || attrs == null) return;
27997
28347
  const src = attrs.src;
27998
28348
  if (typeof src !== "string" || src === "") return;
@@ -28139,6 +28489,7 @@ function scriptResource(attrs) {
28139
28489
  hostComponent,
28140
28490
  htext,
28141
28491
  htextSwap,
28492
+ hydrateClaimedBindingCaches,
28142
28493
  hydrateRoot,
28143
28494
  ifBlock,
28144
28495
  injectStyle,