@burdenoff/fe-libs 2026.719.5 → 2026.719.6

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":"ProductSwitcher.d.ts","sourceRoot":"","sources":["../../src/chrome/ProductSwitcher.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAUhC,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,6EAA6E;IAC7E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,gEAAgE;IAChE,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,CAAC,EAAE;IAC3C,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,GAAG,CAAC,EAAE,MAAM,CAAC;CACd,GAAG,MAAM,GAAG,SAAS,CAKrB;AA0CD;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,CAAC,SAAS;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,WAAW,CAAC,EAAE,MAAM,CAAA;CAAE,EACzF,QAAQ,EAAE,CAAC,EAAE,EACb,KAAK,EAAE,MAAM,GACZ,CAAC,EAAE,CASL;AAED;;;;;;;;;GASG;AACH,wBAAgB,qBAAqB,CACnC,QAAQ,EAAE,OAAO,EAAE,EACnB,gBAAgB,CAAC,EAAE,MAAM,GACxB,OAAO,GAAG,SAAS,CAOrB;AAED,MAAM,WAAW,oBAAoB;IACnC,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,eAAe,CAAC,EAAE,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,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,eAAe,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IAC7C,4CAA4C;IAC5C,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CA6MpD,CAAC"}
@@ -84,7 +84,7 @@ var f = ({ products: e, currentProductId: c, onProductChange: f, compact: p = !1
84
84
  })
85
85
  ]
86
86
  }), m && /* @__PURE__ */ o("div", {
87
- className: "absolute right-0 mt-2 w-[calc(100vw-1.5rem)] sm:w-64 max-w-64 bg-bg-elevated border border-border-subtle rounded-card shadow-[var(--shadow-elevation-4)] z-50 py-2 overflow-hidden animate-in fade-in-0 zoom-in-95 slide-in-from-top-2 duration-200",
87
+ className: "absolute right-0 mt-2 w-[calc(100vw-1.5rem)] sm:w-72 max-w-72 bg-bg-elevated border border-border-subtle rounded-card shadow-[var(--shadow-elevation-4)] z-50 py-2 overflow-hidden animate-in fade-in-0 zoom-in-95 slide-in-from-top-2 duration-200",
88
88
  children: [
89
89
  /* @__PURE__ */ a("div", {
90
90
  className: "px-4 py-2 border-b border-border-subtle",
@@ -153,7 +153,7 @@ var f = ({ products: e, currentProductId: c, onProductChange: f, compact: p = !1
153
153
  onClick: () => C(e),
154
154
  disabled: e.comingSoon,
155
155
  "aria-disabled": e.comingSoon,
156
- title: e.comingSoon ? "Coming soon" : void 0,
156
+ title: e.comingSoon ? "Soon" : e.name,
157
157
  className: `w-full flex items-center gap-3 px-4 py-2.5 text-body-sm transition-colors ${e.comingSoon ? "text-text-muted cursor-not-allowed opacity-60" : e.id === c ? "bg-[var(--color-accent-soft)] text-text-primary font-medium" : "text-text-primary hover:bg-bg-sunken"}`,
158
158
  children: [
159
159
  /* @__PURE__ */ a(l, {
@@ -162,12 +162,12 @@ var f = ({ products: e, currentProductId: c, onProductChange: f, compact: p = !1
162
162
  textClass: "text-sm"
163
163
  }),
164
164
  /* @__PURE__ */ a("span", {
165
- className: "flex-1 truncate text-left",
165
+ className: "flex-1 text-left leading-tight",
166
166
  children: e.name
167
167
  }),
168
168
  e.comingSoon ? /* @__PURE__ */ a("span", {
169
169
  className: "shrink-0 whitespace-nowrap rounded-full border border-border-subtle bg-bg-sunken px-1.5 py-0.5 text-[10px] font-medium uppercase tracking-wide text-text-secondary",
170
- children: "Coming soon"
170
+ children: "Soon"
171
171
  }) : e.id === c && /* @__PURE__ */ a("svg", {
172
172
  className: "size-5 text-action-primary-bg",
173
173
  fill: "currentColor",
@@ -68,6 +68,16 @@ export declare const PRODUCT_URLS: {
68
68
  };
69
69
  export declare const PRODUCTS: ProductConfig[];
70
70
  export declare function getProductUrl(productId: string): string;
71
+ /**
72
+ * Absolute logo URL for a product — ALWAYS the production app's
73
+ * `/icons/icon.svg`, regardless of the current environment.
74
+ *
75
+ * The cross-product switcher renders logos for OTHER products, whose assets
76
+ * only exist at their production domains. It must not use the env-aware
77
+ * `getProductUrl` (which returns `localhost:*` in dev, or `#` for ids missing
78
+ * from the dev map) — that produced broken/absent logos for several products.
79
+ */
80
+ export declare function getProductLogoUrl(productId: string): string | undefined;
71
81
  /**
72
82
  * Get all products with environment-aware URLs.
73
83
  */
@@ -1 +1 @@
1
- {"version":3,"file":"products.d.ts","sourceRoot":"","sources":["../../../src/shared/config/products.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,WAAW,aAAa;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgDf,CAAC;AAEX,eAAO,MAAM,QAAQ,EAAE,aAAa,EAkTnC,CAAC;AAOF,wBAAgB,aAAa,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,CAIvD;AAED;;GAEG;AACH,wBAAgB,mBAAmB;;QAlY7B,MAAM;UACJ,MAAM;UACN,MAAM;WACL,MAAM;kBACC,MAAM;IACpB;;;;;OAKG;iBACU,OAAO;IAyXrB"}
1
+ {"version":3,"file":"products.d.ts","sourceRoot":"","sources":["../../../src/shared/config/products.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,WAAW,aAAa;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgDf,CAAC;AAEX,eAAO,MAAM,QAAQ,EAAE,aAAa,EAkTnC,CAAC;AAOF,wBAAgB,aAAa,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,CAIvD;AAED;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAGvE;AAED;;GAEG;AACH,wBAAgB,mBAAmB;;QAhZ7B,MAAM;UACJ,MAAM;UACN,MAAM;WACL,MAAM;kBACC,MAAM;IACpB;;;;;OAKG;iBACU,OAAO;IAuYrB"}
@@ -357,11 +357,15 @@ function n() {
357
357
  function r(t) {
358
358
  return e[n()][t] || "#";
359
359
  }
360
- function i() {
360
+ function i(t) {
361
+ let n = e.production[t];
362
+ return n ? `${n}icons/icon.svg` : void 0;
363
+ }
364
+ function a() {
361
365
  return t.map((e) => ({
362
366
  ...e,
363
367
  url: r(e.id)
364
368
  }));
365
369
  }
366
370
  //#endregion
367
- export { t as PRODUCTS, e as PRODUCT_URLS, r as getProductUrl, i as getProductsWithUrls };
371
+ export { t as PRODUCTS, e as PRODUCT_URLS, i as getProductLogoUrl, r as getProductUrl, a as getProductsWithUrls };
@@ -1 +1 @@
1
- {"version":3,"file":"useProducts.d.ts","sourceRoot":"","sources":["../../../../src/shared/hooks/shell/useProducts.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AA8DH,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,6EAA6E;IAC7E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,iFAAiF;IACjF,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AA6DD,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,SAAS,EAAE,OAAO,CAAC;IACnB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,MAAM,WAAW,kBAAkB;IACjC,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;GAGG;AACH,wBAAgB,WAAW,CAAC,OAAO,CAAC,EAAE,kBAAkB,GAAG,iBAAiB,CAyD3E"}
1
+ {"version":3,"file":"useProducts.d.ts","sourceRoot":"","sources":["../../../../src/shared/hooks/shell/useProducts.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AA8DH,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,6EAA6E;IAC7E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,iFAAiF;IACjF,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAeD,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,SAAS,EAAE,OAAO,CAAC;IACnB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,MAAM,WAAW,kBAAkB;IACjC,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;GAGG;AACH,wBAAgB,WAAW,CAAC,OAAO,CAAC,EAAE,kBAAkB,GAAG,iBAAiB,CAsE3E"}
@@ -1,14 +1,14 @@
1
- import { PRODUCTS as e, getProductUrl as t } from "../../config/products.js";
2
- import { useGatewayClient as n } from "../../graphql/GatewayContext.js";
1
+ import { PRODUCTS as e, getProductLogoUrl as t, getProductUrl as n } from "../../config/products.js";
2
+ import { useGatewayClient as r } from "../../graphql/GatewayContext.js";
3
3
  import "../../../shared-graphql.js";
4
- import { useCallback as r, useEffect as i, useState as a } from "react";
5
- import { gql as o } from "@apollo/client/core";
4
+ import { useCallback as i, useEffect as a, useState as o } from "react";
5
+ import { gql as s } from "@apollo/client/core";
6
6
  //#region src/shared/hooks/shell/useProducts.ts
7
- var s = new Set(e.map((e) => e.id)), c = new Map(e.map((e) => [e.id, e.comingSoon === !0]));
8
- function l(e, t, n) {
9
- return c.get(e) ? !0 : t !== "ACTIVE" || !n;
7
+ var c = new Set(e.map((e) => e.id)), l = new Map(e.map((e) => [e.id, e.comingSoon === !0]));
8
+ function u(e, t, n) {
9
+ return l.get(e) ? !0 : t !== "ACTIVE" || !n;
10
10
  }
11
- var u = o`
11
+ var d = s`
12
12
  query GetAccessibleProducts($limit: Int, $offset: Int) {
13
13
  myAccessibleProducts(limit: $limit, offset: $offset) {
14
14
  items {
@@ -25,84 +25,62 @@ var u = o`
25
25
  }
26
26
  }
27
27
  `;
28
- function d(e) {
29
- return s.has(e);
28
+ function f(e) {
29
+ return c.has(e);
30
30
  }
31
- var f = {
32
- fluidgrids: "#3b82f6",
33
- bigconsole: "#8b5cf6",
34
- workspaces: "#06b6d4",
35
- vibecontrols: "#10b981",
36
- botlit: "#f59e0b"
37
- }, p = "#6b7280";
38
- function m(e, t) {
39
- let n = {
40
- fluidgrids: "FG",
41
- bigconsole: "BC",
42
- workspaces: "WS",
43
- vibecontrols: "VC",
44
- botlit: "BL"
45
- };
46
- if (n[t]) return n[t];
47
- let r = e.split(/\s+/);
48
- return r.length >= 2 ? (r[0][0] + r[1][0]).toUpperCase() : e.substring(0, 2).toUpperCase();
49
- }
50
- function h(e, t) {
51
- return t?.color && typeof t.color == "string" ? t.color : f[e] || p;
52
- }
53
- function g(e) {
54
- if (e) return `${e.replace(/\/+$/, "")}/icons/icon.svg`;
55
- }
56
- function _() {
31
+ function p() {
57
32
  return e.map((e) => ({
58
33
  id: e.id,
59
34
  name: e.name,
60
- url: t(e.id),
35
+ url: n(e.id),
61
36
  icon: e.icon,
62
37
  color: e.color,
63
- logoUrl: g(t(e.id)),
64
- comingSoon: e.comingSoon
38
+ logoUrl: t(e.id),
39
+ comingSoon: e.comingSoon === !0
65
40
  }));
66
41
  }
67
- function v(e) {
68
- let o = n("global"), [s, c] = a(_()), [f, p] = a(e?.autoFetch !== !1), [v, y] = a(null), b = r(async () => {
69
- p(!0), y(null);
42
+ function m(s) {
43
+ let c = r("global"), [l, m] = o(p()), [h, g] = o(s?.autoFetch !== !1), [_, v] = o(null), y = i(async () => {
44
+ g(!0), v(null);
70
45
  try {
71
- let e = ((await o.query({
72
- query: u,
46
+ let r = (await c.query({
47
+ query: d,
73
48
  variables: {
74
49
  limit: 50,
75
50
  offset: 0
76
51
  },
77
52
  fetchPolicy: "cache-first"
78
- })).data?.myAccessibleProducts?.items || []).filter((e) => d(e.slug)).map((e) => ({
79
- id: e.slug,
80
- name: e.name,
81
- url: e.appUrl || t(e.slug),
82
- icon: m(e.name, e.slug),
83
- color: h(e.slug, e.metadata),
84
- logoUrl: e.logoUrl || g(e.appUrl || t(e.slug)),
85
- comingSoon: l(e.slug, e.status, e.appUrl)
86
- }));
87
- e.sort((e, t) => e.name.localeCompare(t.name)), c(e.length > 0 ? e : _());
53
+ })).data?.myAccessibleProducts?.items || [], i = new Map(r.filter((e) => f(e.slug)).map((e) => [e.slug, e])), a = e.map((e) => {
54
+ let r = i.get(e.id);
55
+ return {
56
+ id: e.id,
57
+ name: e.name,
58
+ url: r?.appUrl || n(e.id),
59
+ icon: e.icon,
60
+ color: r?.metadata && typeof r.metadata.color == "string" ? r.metadata.color : e.color,
61
+ logoUrl: t(e.id),
62
+ comingSoon: r ? u(e.id, r.status, r.appUrl) : e.comingSoon === !0
63
+ };
64
+ });
65
+ a.sort((e, t) => e.name.localeCompare(t.name)), m(a);
88
66
  } catch (e) {
89
- y(e instanceof Error ? e.message : "Failed to fetch products"), c(_());
67
+ v(e instanceof Error ? e.message : "Failed to fetch products"), m(p());
90
68
  } finally {
91
- p(!1);
69
+ g(!1);
92
70
  }
93
- }, [o]);
94
- return i(() => {
95
- if (e?.autoFetch === !1) {
96
- p(!1);
71
+ }, [c]);
72
+ return a(() => {
73
+ if (s?.autoFetch === !1) {
74
+ g(!1);
97
75
  return;
98
76
  }
99
- b();
77
+ y();
100
78
  }, []), {
101
- products: s,
102
- isLoading: f,
103
- error: v,
104
- refetch: b
79
+ products: l,
80
+ isLoading: h,
81
+ error: _,
82
+ refetch: y
105
83
  };
106
84
  }
107
85
  //#endregion
108
- export { v as useProducts };
86
+ export { m as useProducts };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@burdenoff/fe-libs",
3
- "version": "2026.719.5",
3
+ "version": "2026.719.6",
4
4
  "description": "Burdenoff frontend primitives and domain libraries",
5
5
  "type": "module",
6
6
  "imports": {