Add lockdown mode flag to config exports

This commit is contained in:
thePR0M3TH3AN committed 2025-10-20 15:13:01 -04:00
1 parent 39b2ede956
commit 004652c545
2 files changed
+15

No files matched your search

+10
View File
@@ -23,6 +23,16 @@
*/
export const IS_DEV_MODE = true;
/**
* Whether the current deployment should operate in lockdown mode.
*
* When `true`, bitvid restricts access to operator-approved functionality and
* enables defensive UI copy intended for incidents or maintenance windows.
* Leave this `false` for normal operation so downstream modules (via
* `js/config.js`) continue exposing the full experience.
*/
export const IS_LOCKDOWN_MODE = false;
/**
* The primary administrator for this bitvid instance.
*
+5
View File
@@ -3,6 +3,7 @@
import { userLogger } from "./utils/logger.js";
import {
IS_DEV_MODE,
IS_LOCKDOWN_MODE,
ADMIN_SUPER_NPUB,
ADMIN_DM_IMAGE_URL,
BITVID_WEBSITE_URL,
@@ -37,8 +38,12 @@ import {
export const isDevMode = Boolean(IS_DEV_MODE);
export { IS_DEV_MODE };
export const isLockdownMode = Boolean(IS_LOCKDOWN_MODE);
export { IS_LOCKDOWN_MODE };
if (typeof window !== "undefined") {
window.__BITVID_DEV_MODE__ = isDevMode;
window.__BITVID_LOCKDOWN_MODE__ = isLockdownMode;
}
// -----------------------------------------------------------------------------