docthub-core-components 2.90.0 → 2.91.0

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.
package/dist/index.esm.js CHANGED
@@ -5289,7 +5289,7 @@ function Sl() {
5289
5289
  if (gi(o)) return "production";
5290
5290
  if (vi(o)) return "qa";
5291
5291
  }
5292
- return (s = n == null ? void 0 : n.env) != null && s.PROD || typeof process < "u" && ((r = process.env) == null ? void 0 : r.NODE_ENV) === "production" ? "production" : "qa";
5292
+ return typeof window > "u" && ((s = n == null ? void 0 : n.env) != null && s.PROD || typeof process < "u" && ((r = process.env) == null ? void 0 : r.NODE_ENV) === "production") ? "production" : "qa";
5293
5293
  }
5294
5294
  function Cc() {
5295
5295
  return Sl() === "production";
@@ -4,8 +4,10 @@
4
4
  *
5
5
  * Resolution order:
6
6
  * 1. VITE_NAV_ENV — explicit override (qa | production | prod | dev)
7
- * 2. window.location.hostname — localhost → QA; docthub.com → prod; dochub.in → QA
8
- * 3. import.meta.env.PROD Vite prod build prod
7
+ * 2. window.location.hostname — localhost → QA; *.com → prod; *.in → QA
8
+ * (Hostname takes precedence over build flags to ensure correct routing
9
+ * when a QA site like dochub.in is deployed as a production build.)
10
+ * 3. import.meta.env.PROD — Vite prod build → prod (SSR fallback only)
9
11
  * 4. process.env.NODE_ENV — Node/Next.js SSR fallback → "production" means prod
10
12
  * 5. Default → QA
11
13
  */
@@ -1,5 +1,5 @@
1
- /// <reference types="vite/client" />
2
-
3
- interface ImportMetaEnv {
4
- readonly VITE_NAV_ENV?: "qa" | "dev" | "production" | "prod";
5
- }
1
+ /// <reference types="vite/client" />
2
+
3
+ interface ImportMetaEnv {
4
+ readonly VITE_NAV_ENV?: "qa" | "dev" | "production" | "prod";
5
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "docthub-core-components",
3
- "version": "2.90.0",
3
+ "version": "2.91.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",