// src/product-framework/product-authoring-gate.ts
var runtimeProductAuthoring = null;
function getRuntimeProductAuthoring() {
  return runtimeProductAuthoring;
}
function setRuntimeProductAuthoring(enabled) {
  runtimeProductAuthoring = enabled;
}
function isPlatformCreatorWorkspace() {
  const vite = readVitePlatformCreatorFlag();
  if (vite !== void 0) return vite;
  const next = readNextPlatformCreatorFlag();
  if (next !== void 0) return next;
  return false;
}
function readVitePlatformCreatorFlag() {
  try {
    const raw = import.meta.env?.VITE_EXXAT_PLATFORM_CREATOR;
    if (raw === "true") return true;
    if (raw === "false") return false;
    return void 0;
  } catch {
    return void 0;
  }
}
function readNextPlatformCreatorFlag() {
  if (typeof process === "undefined") return void 0;
  const raw = process.env.NEXT_PUBLIC_EXXAT_PLATFORM_CREATOR;
  if (raw === "true") return true;
  if (raw === "false") return false;
  return void 0;
}
export {
  getRuntimeProductAuthoring,
  isPlatformCreatorWorkspace,
  setRuntimeProductAuthoring
};
//# sourceMappingURL=product-authoring-gate.js.map