@rovela-ai/sdk 0.3.11 → 0.3.13

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":"AdminBarBanner.d.ts","sourceRoot":"","sources":["../../../src/admin/components/AdminBarBanner.tsx"],"names":[],"mappings":"AAwDA,wBAAgB,cAAc,uCA+F7B"}
1
+ {"version":3,"file":"AdminBarBanner.d.ts","sourceRoot":"","sources":["../../../src/admin/components/AdminBarBanner.tsx"],"names":[],"mappings":"AAoDA,wBAAgB,cAAc,uCAoI7B"}
@@ -1,51 +1,47 @@
1
1
  'use client';
2
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  /**
4
4
  * @rovela/sdk/admin/components/AdminBarBanner
5
5
  *
6
- * Linear/Vercel-style admin session bar that sits above the storefront
7
- * whenever a signed-in admin browses the public store. Customers and
8
- * anonymous visitors never see it.
6
+ * Linear/Vercel-style admin session bar shown above the storefront whenever
7
+ * a signed-in admin browses the public store. Customers and anonymous
8
+ * visitors never see it.
9
9
  *
10
- * Design rules:
10
+ * Design rules (unchanged from v1):
11
11
  *
12
- * 1. Self-gating. The component takes no props and renders `null` when
13
- * the session is loading, when there is no admin role, or when the
14
- * user is on an `/admin/*` route. Safe to mount unconditionally at
15
- * the root of a customer layout.
12
+ * 1. Self-gating. No props. Renders `null` while loading, for sessions
13
+ * without a role, and on /admin/*.
16
14
  *
17
- * 2. Portal-rendered to <html> (outside <body>). This anchors the bar
18
- * to the viewport regardless of any body-level transform below it.
15
+ * 2. Portal-rendered to <html>. Combined with a `translateZ(0)` on
16
+ * <body> and a 40px body margin, fixed/sticky store chrome is pushed
17
+ * below the bar instead of overlapping it.
19
18
  *
20
- * 3. Offset the storefront without editing it. On mount we apply
21
- * `margin-top: 40px` + `transform: translateZ(0)` to <body>. The
22
- * transform reparents the containing block of every `position: fixed`
23
- * descendant from the viewport to <body>, so sticky/fixed store
24
- * headers sit *below* our bar instead of overlapping it. The banner
25
- * itself lives outside <body> (in the portal root appended to
26
- * <html>), so the same transform does not affect it — it stays
27
- * pinned to the real viewport at `top: 0`.
19
+ * 3. Theme-proof. Inline styles + one scoped <style> element.
28
20
  *
29
- * 4. Theme-proof styling. Inline styles + one scoped `<style>` element
30
- * for pseudo-states and media queries. Storefront Tailwind/CSS edits
31
- * cannot regress this.
21
+ * 4. Navigation-only. Server-side guards still authorize.
32
22
  *
33
- * 5. Navigation-only. The bar never authorizes — clicking "Dashboard"
34
- * sends a normal navigation to `/admin`, which is gated server-side
35
- * by `requireAdmin()`. A deactivated admin whose JWT is still valid
36
- * will land on `/admin/login`; this bar is never the gate.
23
+ * v2 changes:
24
+ * - Two actions instead of one: "Edit store" (rovela.ai/generate/{id})
25
+ * and "Manage store" (/admin). Both open in a new tab.
26
+ * - "Edit store" only renders when NEXT_PUBLIC_ROVELA_PROJECT_ID is set.
27
+ * This gives a graceful degradation path for stores whose env var
28
+ * hasn't propagated yet.
29
+ * - Rovela logo (same CDN asset as AdminNav sidebar footer) as the
30
+ * Edit-store glyph; Lucide LayoutDashboard as the Manage-store glyph.
37
31
  */
38
32
  import { useEffect, useState } from 'react';
39
33
  import { createPortal } from 'react-dom';
40
34
  import { usePathname } from 'next/navigation';
35
+ import { LayoutDashboard } from 'lucide-react';
41
36
  import { useAdminAuth } from '../hooks/useAdminAuth';
42
- import { roleLabel } from '../permissions';
43
37
  // =============================================================================
44
38
  // Constants
45
39
  // =============================================================================
46
40
  const BAR_HEIGHT_PX = 40;
47
41
  const PORTAL_ROOT_ID = 'rovela-admin-bar-root';
48
42
  const STYLE_TAG_ID = 'rovela-admin-bar-style';
43
+ const DEFAULT_ROVELA_URL = 'https://rovela.ai';
44
+ const ROVELA_LOGO_SRC = 'https://rovela.ai/logo.png';
49
45
  // =============================================================================
50
46
  // Component
51
47
  // =============================================================================
@@ -53,8 +49,6 @@ export function AdminBarBanner() {
53
49
  const pathname = usePathname();
54
50
  const { admin, isAuthenticated, isLoading } = useAdminAuth();
55
51
  const [portalRoot, setPortalRoot] = useState(null);
56
- // Visibility gate. Any change here triggers mount/unmount side-effects
57
- // via the `useEffect` below.
58
52
  const visible = !isLoading &&
59
53
  isAuthenticated &&
60
54
  Boolean(admin?.role) &&
@@ -64,7 +58,7 @@ export function AdminBarBanner() {
64
58
  return;
65
59
  if (!visible)
66
60
  return;
67
- // --- 1. Portal root (child of <html>, sibling of <body>) ---
61
+ // --- Portal root (<html> child, sibling of <body>) ---
68
62
  let root = document.getElementById(PORTAL_ROOT_ID);
69
63
  let ownsRoot = false;
70
64
  if (!root) {
@@ -74,7 +68,7 @@ export function AdminBarBanner() {
74
68
  ownsRoot = true;
75
69
  }
76
70
  setPortalRoot(root);
77
- // --- 2. Global stylesheet for pseudo-states + responsive behavior ---
71
+ // --- Scoped global stylesheet (pseudo-states + responsive hides) ---
78
72
  let styleEl = document.getElementById(STYLE_TAG_ID);
79
73
  let ownsStyle = false;
80
74
  if (!styleEl) {
@@ -84,14 +78,10 @@ export function AdminBarBanner() {
84
78
  document.head.appendChild(styleEl);
85
79
  ownsStyle = true;
86
80
  }
87
- // --- 3. Push the storefront down + reparent fixed descendants ---
88
- // Remember previous inline values so we restore precisely on unmount.
81
+ // --- Push the storefront down + reparent fixed descendants ---
89
82
  const prevBodyMarginTop = document.body.style.marginTop;
90
83
  const prevBodyTransform = document.body.style.transform;
91
84
  document.body.style.marginTop = `${BAR_HEIGHT_PX}px`;
92
- // `translateZ(0)` creates a new containing block for any descendant
93
- // with `position: fixed`. Combined with the body margin above, this
94
- // shifts sticky/fixed store chrome out from under our bar.
95
85
  document.body.style.transform = 'translateZ(0)';
96
86
  return () => {
97
87
  document.body.style.marginTop = prevBodyMarginTop;
@@ -107,8 +97,36 @@ export function AdminBarBanner() {
107
97
  }, [visible]);
108
98
  if (!visible || !portalRoot || !admin)
109
99
  return null;
110
- const role = roleLabel(admin.role).toLowerCase();
111
- return createPortal(_jsx("div", { "data-rovela-admin-bar": "", style: wrapStyle, children: _jsxs("div", { style: innerStyle, children: [_jsxs("div", { style: leftGroupStyle, children: [_jsx("span", { "aria-hidden": "true", style: dotStyle }), _jsx("span", { style: labelStyle, children: "Admin session" }), _jsx("span", { "aria-hidden": "true", "data-rovela-desktop-only": "", style: dividerStyle, children: "\u00B7" }), _jsx("span", { "data-rovela-desktop-only": "", style: roleStyle, children: role })] }), _jsxs("a", { href: "/admin", "data-rovela-action": "", "aria-label": "Open admin dashboard", style: buttonStyle, children: [_jsx("span", { "data-rovela-desktop-only": "", children: "Dashboard" }), _jsx("span", { "aria-hidden": "true", style: arrowStyle, children: "\u2197" })] })] }) }), portalRoot);
100
+ // Deep-link to Rovela platform. Only shown when the project ID env var is
101
+ // present which is the case for every store that has redeployed since
102
+ // the env var was added to buildStoreEnvVars(). Older stores see only the
103
+ // "Manage store" button until their next rebuild.
104
+ const projectId = getEnv('NEXT_PUBLIC_ROVELA_PROJECT_ID');
105
+ const rovelaBase = getEnv('NEXT_PUBLIC_ROVELA_URL') || DEFAULT_ROVELA_URL;
106
+ const editUrl = projectId ? `${rovelaBase.replace(/\/$/, '')}/generate/${projectId}` : null;
107
+ // Store name surfaces in the left group so a merchant managing multiple
108
+ // stores instantly knows which storefront they're viewing. Falls back to
109
+ // hiding the name (just "Live store") when the env var isn't set.
110
+ const storeName = (getEnv('STORE_NAME') || '').trim() || null;
111
+ return createPortal(_jsx("div", { "data-rovela-admin-bar": "", style: wrapStyle, children: _jsxs("div", { style: innerStyle, children: [_jsxs("div", { style: leftGroupStyle, children: [_jsx("span", { "aria-hidden": "true", style: dotStyle }), _jsx("span", { "data-rovela-desktop-only": "", style: labelStyle, children: "Live store" }), storeName && (_jsxs(_Fragment, { children: [_jsx("span", { "aria-hidden": "true", "data-rovela-desktop-only": "", style: dividerStyle, children: "\u00B7" }), _jsx("span", { "data-rovela-tablet-only": "", style: storeNameStyle, children: storeName })] }))] }), _jsxs("div", { style: actionsStyle, children: [editUrl && (_jsxs("a", { href: editUrl, target: "_blank", rel: "noopener noreferrer", "data-rovela-action": "", "aria-label": "Edit store in Rovela", style: buttonStyle, children: [_jsx("img", { src: ROVELA_LOGO_SRC, alt: "", "aria-hidden": "true", style: rovelaIconStyle }), _jsx("span", { "data-rovela-desktop-only": "", children: "Edit store" })] })), _jsxs("a", { href: "/admin", target: "_blank", rel: "noopener noreferrer", "data-rovela-action": "", "aria-label": "Open the admin dashboard", style: buttonStyle, children: [_jsx(LayoutDashboard, { "aria-hidden": "true", style: lucideIconStyle, strokeWidth: 1.8 }), _jsx("span", { "data-rovela-desktop-only": "", children: "Manage store" })] })] })] }) }), portalRoot);
112
+ }
113
+ // =============================================================================
114
+ // Helpers
115
+ // =============================================================================
116
+ /**
117
+ * `NEXT_PUBLIC_*` vars get statically inlined by Next.js when a component
118
+ * is bundled, so reading via `process.env[name]` with a dynamic key does
119
+ * not work in the SDK (no direct access to the compile-time substitution).
120
+ * We read the literal strings so the bundler can substitute them.
121
+ */
122
+ function getEnv(key) {
123
+ if (key === 'NEXT_PUBLIC_ROVELA_PROJECT_ID')
124
+ return process.env.NEXT_PUBLIC_ROVELA_PROJECT_ID;
125
+ if (key === 'NEXT_PUBLIC_ROVELA_URL')
126
+ return process.env.NEXT_PUBLIC_ROVELA_URL;
127
+ if (key === 'STORE_NAME')
128
+ return process.env.STORE_NAME;
129
+ return undefined;
112
130
  }
113
131
  // =============================================================================
114
132
  // Styles
@@ -119,8 +137,6 @@ const wrapStyle = {
119
137
  left: 0,
120
138
  right: 0,
121
139
  height: `${BAR_HEIGHT_PX}px`,
122
- // Max 32-bit signed int — safely above any storefront z-index stacking
123
- // context (Intercom widgets cap at ~2147483000; we still sit above).
124
140
  zIndex: 2147483647,
125
141
  background: 'rgba(10, 10, 12, 0.85)',
126
142
  backdropFilter: 'blur(12px) saturate(140%)',
@@ -168,16 +184,26 @@ const labelStyle = {
168
184
  const dividerStyle = {
169
185
  color: 'rgba(255, 255, 255, 0.3)',
170
186
  };
171
- const roleStyle = {
172
- color: 'rgba(255, 255, 255, 0.55)',
187
+ const storeNameStyle = {
188
+ color: 'rgba(255, 255, 255, 0.75)',
189
+ fontWeight: 500,
173
190
  whiteSpace: 'nowrap',
191
+ overflow: 'hidden',
192
+ textOverflow: 'ellipsis',
193
+ minWidth: 0,
194
+ };
195
+ const actionsStyle = {
196
+ display: 'inline-flex',
197
+ alignItems: 'center',
198
+ gap: '6px',
199
+ flexShrink: 0,
174
200
  };
175
201
  const buttonStyle = {
176
202
  display: 'inline-flex',
177
203
  alignItems: 'center',
178
204
  gap: '6px',
179
205
  height: '28px',
180
- padding: '0 12px',
206
+ padding: '0 10px',
181
207
  borderRadius: '6px',
182
208
  fontSize: '12.5px',
183
209
  fontWeight: 500,
@@ -190,14 +216,25 @@ const buttonStyle = {
190
216
  flexShrink: 0,
191
217
  transition: 'background 120ms ease, border-color 120ms ease',
192
218
  };
193
- const arrowStyle = {
194
- display: 'inline-block',
195
- transform: 'translateY(-0.5px)',
196
- fontSize: '13px',
197
- opacity: 0.9,
219
+ const rovelaIconStyle = {
220
+ width: '14px',
221
+ height: '14px',
222
+ objectFit: 'contain',
223
+ // Force the logo to render pure white so it reads correctly on the dark bar
224
+ filter: 'brightness(0) invert(1)',
225
+ flexShrink: 0,
226
+ };
227
+ const lucideIconStyle = {
228
+ width: '14px',
229
+ height: '14px',
230
+ flexShrink: 0,
198
231
  };
199
- // Scoped to `[data-rovela-admin-bar]` so we can never leak into storefront
200
- // styles. Injected once per mount, removed on unmount.
232
+ // Scoped under [data-rovela-admin-bar] so no rules can escape into the
233
+ // storefront. Injected on mount, removed on unmount.
234
+ //
235
+ // Responsive hide rules:
236
+ // - [data-rovela-desktop-only] hidden below 640px (role tag, button labels)
237
+ // - [data-rovela-tablet-only] hidden below 480px ("Admin session" label)
201
238
  const GLOBAL_CSS = `
202
239
  @keyframes rab-pulse {
203
240
  0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.55); }
@@ -212,9 +249,13 @@ const GLOBAL_CSS = `
212
249
  outline: 2px solid rgba(255, 255, 255, 0.6);
213
250
  outline-offset: 2px;
214
251
  }
215
- @media (max-width: 480px) {
252
+ @media (max-width: 639px) {
216
253
  [data-rovela-admin-bar] [data-rovela-desktop-only] { display: none !important; }
217
254
  }
255
+ @media (max-width: 479px) {
256
+ [data-rovela-admin-bar] [data-rovela-tablet-only] { display: none !important; }
257
+ [data-rovela-admin-bar] a[data-rovela-action] { padding: 0 8px; }
258
+ }
218
259
  @media (prefers-reduced-motion: reduce) {
219
260
  [data-rovela-admin-bar] [aria-hidden="true"] { animation: none !important; }
220
261
  }
@@ -1 +1 @@
1
- {"version":3,"file":"AdminBarBanner.js","sourceRoot":"","sources":["../../../src/admin/components/AdminBarBanner.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;;AAEZ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AAEH,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAE1C,gFAAgF;AAChF,YAAY;AACZ,gFAAgF;AAEhF,MAAM,aAAa,GAAG,EAAE,CAAA;AACxB,MAAM,cAAc,GAAG,uBAAuB,CAAA;AAC9C,MAAM,YAAY,GAAG,wBAAwB,CAAA;AAE7C,gFAAgF;AAChF,YAAY;AACZ,gFAAgF;AAEhF,MAAM,UAAU,cAAc;IAC5B,MAAM,QAAQ,GAAG,WAAW,EAAE,CAAA;IAC9B,MAAM,EAAE,KAAK,EAAE,eAAe,EAAE,SAAS,EAAE,GAAG,YAAY,EAAE,CAAA;IAC5D,MAAM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AAA;AAED,MAAM,YAAY,GAAwB;IACxC,OAAO,EAAE,aAAa;IACtB,UAAU,EAAE,QAAQ;IACpB,GAAG,EAAE,KAAK;IACV,UAAU,EAAE,CAAC;CACd,CAAA;AAED,MAAM,WAAW,GAAwB;IACvC,OAAO,EAAE,aAAa;IACtB,UAAU,EAAE,QAAQ;IACpB,GAAG,EAAE,KAAK;IACV,MAAM,EAAE,MAAM;IACd,OAAO,EAAE,QAAQ;IACjB,YAAY,EAAE,KAAK;IACnB,QAAQ,EAAE,QAAQ;IAClB,UAAU,EAAE,GAAG;IACf,KAAK,EAAE,SAAS;IAChB,UAAU,EAAE,0BAA0B;IACtC,MAAM,EAAE,qCAAqC;IAC7C,cAAc,EAAE,MAAM;IACtB,MAAM,EAAE,SAAS;IACjB,UAAU,EAAE,QAAQ;IACpB,UAAU,EAAE,CAAC;IACb,UAAU,EAAE,gDAAgD;CAC7D,CAAA;AAED,MAAM,eAAe,GAAwB;IAC3C,KAAK,EAAE,MAAM;IACb,MAAM,EAAE,MAAM;IACd,SAAS,EAAE,SAAS;IACpB,4EAA4E;IAC5E,MAAM,EAAE,yBAAyB;IACjC,UAAU,EAAE,CAAC;CACd,CAAA;AAED,MAAM,eAAe,GAAwB;IAC3C,KAAK,EAAE,MAAM;IACb,MAAM,EAAE,MAAM;IACd,UAAU,EAAE,CAAC;CACd,CAAA;AAED,uEAAuE;AACvE,qDAAqD;AACrD,EAAE;AACF,yBAAyB;AACzB,gFAAgF;AAChF,8EAA8E;AAC9E,MAAM,UAAU,GAAG;;;;;;;;;;;;;;;;;;;;;;;;CAwBlB,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rovela-ai/sdk",
3
- "version": "0.3.11",
3
+ "version": "0.3.13",
4
4
  "description": "Rovela SDK - Pre-built e-commerce components for AI-powered store generation",
5
5
  "type": "module",
6
6
  "license": "MIT",