@powerhousedao/knowledge-note 1.0.4 → 1.0.5

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.
@@ -1 +1 @@
1
- {"version":3,"file":"use-graph-search.d.ts","sourceRoot":"","sources":["../../../../editors/knowledge-vault/hooks/use-graph-search.ts"],"names":[],"mappings":"AAOA,MAAM,MAAM,YAAY,GAAG;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,SAAS,CAAC;AAsHhD,wBAAgB,cAAc;;kBAgBtB,MAAM;;;;;;uBAQN,UAAU;EAoGjB"}
1
+ {"version":3,"file":"use-graph-search.d.ts","sourceRoot":"","sources":["../../../../editors/knowledge-vault/hooks/use-graph-search.ts"],"names":[],"mappings":"AAOA,MAAM,MAAM,YAAY,GAAG;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,SAAS,CAAC;AAkIhD,wBAAgB,cAAc;;kBAgBtB,MAAM;;;;;;uBAQN,UAAU;EAoGjB"}
@@ -18,12 +18,21 @@ const SUBGRAPH_PATH = "/graphql/knowledgeGraph";
18
18
  * set VITE_SUBGRAPH_URL=https://switchboard-dev.powerhouse.xyz/graphql/knowledgeGraph
19
19
  * in your .env file.
20
20
  */
21
+ // Known Connect → Switchboard domain mappings for deployed environments
22
+ const DOMAIN_MAP = {
23
+ "connect-dev.powerhouse.xyz": "https://switchboard-dev.powerhouse.xyz/graphql/knowledgeGraph",
24
+ };
21
25
  function resolveEndpoint() {
22
26
  // Explicit override via env var
23
27
  const envUrl = typeof import.meta !== "undefined" &&
24
28
  import.meta.env?.VITE_SUBGRAPH_URL;
25
29
  if (envUrl)
26
30
  return envUrl;
31
+ // Check known Connect → Switchboard domain mappings
32
+ const hostname = globalThis.window?.location?.hostname;
33
+ if (hostname && DOMAIN_MAP[hostname]) {
34
+ return DOMAIN_MAP[hostname];
35
+ }
27
36
  // Vite dev server proxying to local reactor
28
37
  const port = globalThis.window?.location?.port;
29
38
  if (port === "3000" || port === "3001") {
package/dist/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@powerhousedao/knowledge-note",
3
3
  "description": "Knowledge Note document model package for Powerhouse",
4
- "version": "1.0.4",
4
+ "version": "1.0.5",
5
5
  "license": "AGPL-3.0-only",
6
6
  "type": "module",
7
7
  "files": [
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@powerhousedao/knowledge-note",
3
3
  "description": "Knowledge Note document model package for Powerhouse",
4
- "version": "1.0.4",
4
+ "version": "1.0.5",
5
5
  "license": "AGPL-3.0-only",
6
6
  "type": "module",
7
7
  "files": [