// Force strict mode and setup for ESM
"use strict";
import {
  init_esbuild_shims
} from "./chunk-5O2XNYP6.js";
import {
  __name
} from "./chunk-J2S4EL5Y.js";

// packages/acp-bridge/src/replayWindowLimits.ts
init_esbuild_shims();
var DEFAULT_COMPACTED_REPLAY_MAX_BYTES = 4 * 1024 * 1024;
var MAX_COMPACTED_REPLAY_MAX_BYTES = 256 * 1024 * 1024;
function normalizeCompactedReplayMaxBytes(value) {
  if (value === void 0) return DEFAULT_COMPACTED_REPLAY_MAX_BYTES;
  if (!Number.isSafeInteger(value) || value < 1 || value > MAX_COMPACTED_REPLAY_MAX_BYTES) {
    throw new TypeError(
      `Invalid compactedReplayMaxBytes: ${value}. Must be a positive safe integer in [1, ${MAX_COMPACTED_REPLAY_MAX_BYTES}].`
    );
  }
  return value;
}
__name(normalizeCompactedReplayMaxBytes, "normalizeCompactedReplayMaxBytes");

export {
  DEFAULT_COMPACTED_REPLAY_MAX_BYTES,
  MAX_COMPACTED_REPLAY_MAX_BYTES,
  normalizeCompactedReplayMaxBytes
};
/**
 * @license
 * Copyright 2026 Qwen Team
 * SPDX-License-Identifier: Apache-2.0
 */
