@ultrst-armada/floks 1.13.3 → 1.13.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,8 +1,8 @@
1
1
  {
2
2
  "schema": 1,
3
3
  "packageName": "@ultrst-armada/floks",
4
- "version": "1.13.3",
5
- "sourceCommit": "bb1bfd488fba5951ad53a56567dcb065344194dc",
4
+ "version": "1.13.5",
5
+ "sourceCommit": "83ac0162c7c3932deaffd0c87a824dd2b521f7a3",
6
6
  "releaseWorkflow": "npm Release",
7
- "workflowRunId": "41202294867"
7
+ "workflowRunId": "41637279439"
8
8
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ultrst-armada/floks",
3
- "version": "1.13.3",
3
+ "version": "1.13.5",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public",
@@ -93,7 +93,7 @@
93
93
  "@types/node": "^22.0.0",
94
94
  "@types/react": "^19.0.0",
95
95
  "@types/react-dom": "^19.0.0",
96
- "@ultrst-armada/kloks": "^1.22.2",
96
+ "@ultrst-armada/kloks": "^1.24.5",
97
97
  "@ultrst-armada/frnlts": "^0.5.3",
98
98
  "happy-dom": "^21.0.3",
99
99
  "lucide-react": "^1.55.0",
@@ -49,11 +49,6 @@ import {
49
49
  getAuthoringDepth,
50
50
  getAuthoringSubtreeIds
51
51
  } from "./chunk-TS7P3WWH.js";
52
- import {
53
- DockBar,
54
- DockItem,
55
- useDock
56
- } from "./chunk-6VB74RCH.js";
57
52
  import {
58
53
  MonacoEditor,
59
54
  skipoDarkTheme,
@@ -65,6 +60,11 @@ import {
65
60
  MiniMap,
66
61
  useCanvas
67
62
  } from "./chunk-34YRDZPJ.js";
63
+ import {
64
+ DockBar,
65
+ DockItem,
66
+ useDock
67
+ } from "./chunk-6VB74RCH.js";
68
68
  import {
69
69
  FodModule
70
70
  } from "./chunk-7CYX3B6O.js";
@@ -76,7 +76,7 @@
76
76
  "dependencies": {
77
77
  "@floks/ui": "workspace:*",
78
78
  "@ultrst-armada/frnlts": "^0.5.3",
79
- "@ultrst-armada/kloks": "^1.22.2"
79
+ "@ultrst-armada/kloks": "^1.24.5"
80
80
  },
81
81
  "peerDependencies": {
82
82
  "@dnd-kit/core": "^6.0.0",
@@ -521,4 +521,24 @@ interface FrnlThemeDefinition {
521
521
  /** Convert a validated Floks ThemePack to FrnlTS component/state visual parameters. */
522
522
  declare function themePackToFrnlTheme(themePack: ThemePack): FrnlThemeDefinition;
523
523
 
524
- export { type ComponentThemeContract, ComponentThemeContractSchema, type ContractDiffResult, FLOKS_CANONICAL_CONTRACT, FLOKS_COMPONENT_REGISTRY, FLOKS_PUBLIC_SYMBOLS, type FloksContractSnapshot, FloksContractSnapshotSchema, type FrnlThemeDefinition, type FrnlThemeState, type ThemePack, ThemePackSchema, type ThemePackSlotBinding, ThemePackSlotBindingSchema, type ThemePackStateMapping, ThemePackStateMappingSchema, type ThemeTarget, ThemeTargetSchema, type ThemeValidationResult, type VisualParameter, VisualParameterSchema, type VisualSlot, VisualSlotSchema, type VisualState, VisualStateSchema, createFloksSnapshot, diffContractSnapshots, getComponentContract, listComponentContracts, loadThemePack, themePackToFrnlTheme, validateThemePackAgainstContract };
524
+ type FloksPromotionKind = "component" | "theme" | "theme-pack";
525
+ interface FloksPromotionRequest {
526
+ assetId: string;
527
+ kind: FloksPromotionKind;
528
+ sourceRepository: string;
529
+ sourceCommit: string;
530
+ verificationId: string;
531
+ files: readonly string[];
532
+ }
533
+ interface FloksPromotionResult {
534
+ assetId: string;
535
+ status: "accepted" | "rejected";
536
+ canonicalReference?: string;
537
+ reason?: string;
538
+ }
539
+ declare const floksPromotionContract: {
540
+ readonly id: "floks.krusbl-promotion";
541
+ readonly requiredEvidence: readonly ["sourceRepository", "sourceCommit", "verificationId"];
542
+ };
543
+
544
+ export { type ComponentThemeContract, ComponentThemeContractSchema, type ContractDiffResult, FLOKS_CANONICAL_CONTRACT, FLOKS_COMPONENT_REGISTRY, FLOKS_PUBLIC_SYMBOLS, type FloksContractSnapshot, FloksContractSnapshotSchema, type FloksPromotionKind, type FloksPromotionRequest, type FloksPromotionResult, type FrnlThemeDefinition, type FrnlThemeState, type ThemePack, ThemePackSchema, type ThemePackSlotBinding, ThemePackSlotBindingSchema, type ThemePackStateMapping, ThemePackStateMappingSchema, type ThemeTarget, ThemeTargetSchema, type ThemeValidationResult, type VisualParameter, VisualParameterSchema, type VisualSlot, VisualSlotSchema, type VisualState, VisualStateSchema, createFloksSnapshot, diffContractSnapshots, floksPromotionContract, getComponentContract, listComponentContracts, loadThemePack, themePackToFrnlTheme, validateThemePackAgainstContract };
@@ -490,6 +490,12 @@ function themePackToFrnlTheme(themePack) {
490
490
  baseVisualParameters: { ...themePack.parameters }
491
491
  };
492
492
  }
493
+
494
+ // src/krusbl-promotion.ts
495
+ var floksPromotionContract = {
496
+ id: "floks.krusbl-promotion",
497
+ requiredEvidence: ["sourceRepository", "sourceCommit", "verificationId"]
498
+ };
493
499
  export {
494
500
  ComponentThemeContractSchema,
495
501
  FLOKS_CANONICAL_CONTRACT,
@@ -505,6 +511,7 @@ export {
505
511
  VisualStateSchema,
506
512
  createFloksSnapshot,
507
513
  diffContractSnapshots,
514
+ floksPromotionContract,
508
515
  getComponentContract,
509
516
  listComponentContracts,
510
517
  loadThemePack,
@@ -17,28 +17,62 @@ import React, { useId, useMemo, useState } from "react";
17
17
  import { LogIn, UserPlus, Eye, EyeOff, Shield, ArrowRight, AlertCircle } from "lucide-react";
18
18
 
19
19
  // src/components/auth/GoogleSignInButton.tsx
20
- import { jsx } from "react/jsx-runtime";
20
+ import { jsx, jsxs } from "react/jsx-runtime";
21
+ var GoogleIcon = ({ size = 14, className = "" }) => /* @__PURE__ */ jsxs("svg", { width: size, height: size, viewBox: "0 0 24 24", className, "aria-hidden": "true", style: { flexShrink: 0 }, children: [
22
+ /* @__PURE__ */ jsx(
23
+ "path",
24
+ {
25
+ fill: "#4285F4",
26
+ d: "M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92c-.26 1.37-1.04 2.53-2.21 3.31v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.09z"
27
+ }
28
+ ),
29
+ /* @__PURE__ */ jsx(
30
+ "path",
31
+ {
32
+ fill: "#34A853",
33
+ d: "M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z"
34
+ }
35
+ ),
36
+ /* @__PURE__ */ jsx(
37
+ "path",
38
+ {
39
+ fill: "#FBBC05",
40
+ d: "M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.06H2.18C1.43 8.55 1 10.22 1 12s.43 3.45 1.18 4.94l2.85-2.22.81-.63z"
41
+ }
42
+ ),
43
+ /* @__PURE__ */ jsx(
44
+ "path",
45
+ {
46
+ fill: "#EA4335",
47
+ d: "M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.06l3.66 2.84c.87-2.6 3.3-4.52 6.16-4.52z"
48
+ }
49
+ )
50
+ ] });
21
51
  var GoogleSignInButton = ({
22
52
  onSignIn,
23
53
  disabled = false,
24
54
  loading = false,
25
- label = "CONTINUE WITH GOOGLE"
26
- }) => /* @__PURE__ */ jsx(
55
+ label = "CONTINUE WITH GOOGLE",
56
+ className = ""
57
+ }) => /* @__PURE__ */ jsxs(
27
58
  "button",
28
59
  {
29
60
  type: "button",
30
61
  onClick: () => void onSignIn(),
31
62
  disabled: disabled || loading,
32
- className: "w-full py-2.5 text-[10px] font-black border-2 border-[var(--skipo-border-color)] bg-[var(--skipo-bg)] flex items-center justify-center gap-2 disabled:opacity-50",
63
+ className: `w-full py-2.5 text-[10px] font-black border-2 border-[var(--skipo-border-color)] bg-[var(--skipo-bg)] hover:bg-[var(--skipo-surface-hover,var(--skipo-surface))] text-[var(--skipo-text)] flex items-center justify-center gap-2.5 transition-colors cursor-pointer select-none disabled:opacity-50 ${className}`,
33
64
  "aria-label": label,
34
- children: loading ? "CONNECTING GOOGLE..." : label
65
+ children: [
66
+ loading ? /* @__PURE__ */ jsx("span", { className: "inline-block w-3.5 h-3.5 border-2 border-[var(--skipo-accent)] border-t-transparent rounded-full animate-spin" }) : /* @__PURE__ */ jsx(GoogleIcon, { size: 14 }),
67
+ /* @__PURE__ */ jsx("span", { children: loading ? "CONNECTING GOOGLE..." : label })
68
+ ]
35
69
  }
36
70
  );
37
71
 
38
72
  // src/components/auth/AuthPage.tsx
39
73
  import { defineFrnlComponent } from "@ultrst-armada/frnlts";
40
74
  import { useFrnlComponent } from "@ultrst-armada/frnlts/react";
41
- import { Fragment, jsx as jsx2, jsxs } from "react/jsx-runtime";
75
+ import { Fragment, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
42
76
  var AUTH_PAGE_REQUIRED_SERVICES = ["auth"];
43
77
  var authPageDefinition = defineFrnlComponent({
44
78
  name: "AuthPage",
@@ -57,6 +91,7 @@ var AuthPage = ({
57
91
  onRegister,
58
92
  onSuccess,
59
93
  onGoogleSignIn,
94
+ enableGoogleSignIn = true,
60
95
  onSwitchToAdmin
61
96
  }) => {
62
97
  const store = useFloksFrnlStore();
@@ -107,7 +142,7 @@ var AuthPage = ({
107
142
  setLoading(false);
108
143
  }
109
144
  };
110
- return /* @__PURE__ */ jsxs(
145
+ return /* @__PURE__ */ jsxs2(
111
146
  "div",
112
147
  {
113
148
  id: componentId,
@@ -116,8 +151,8 @@ var AuthPage = ({
116
151
  className: "min-h-screen h-screen w-screen bg-[var(--skipo-bg)] text-[var(--skipo-text)] font-mono flex flex-col justify-between overflow-hidden",
117
152
  style: { minHeight: "100vh", height: "100vh", width: "100vw" },
118
153
  children: [
119
- /* @__PURE__ */ jsxs("header", { className: "border-b-2 border-[var(--skipo-border-color)] bg-[var(--skipo-surface)] px-6 py-3.5 flex items-center justify-between shrink-0", children: [
120
- /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
154
+ /* @__PURE__ */ jsxs2("header", { className: "border-b-2 border-[var(--skipo-border-color)] bg-[var(--skipo-surface)] px-6 py-3.5 flex items-center justify-between shrink-0", children: [
155
+ /* @__PURE__ */ jsxs2("div", { className: "flex items-center gap-3", children: [
121
156
  appIcon && typeof appIcon !== "string" ? /* @__PURE__ */ jsx2("div", { className: "w-8 h-8 shrink-0 flex items-center justify-center", children: appIcon }) : !iconError ? /* @__PURE__ */ jsx2("div", { className: "w-8 h-8 shrink-0 flex items-center justify-center overflow-hidden rounded bg-[var(--skipo-surface)] border border-[var(--skipo-border-color)]", children: /* @__PURE__ */ jsx2(
122
157
  "img",
123
158
  {
@@ -127,27 +162,27 @@ var AuthPage = ({
127
162
  onError: () => setIconError(true)
128
163
  }
129
164
  ) }) : /* @__PURE__ */ jsx2("div", { className: "w-8 h-8 shrink-0 bg-[var(--skipo-accent)] text-black font-black flex items-center justify-center text-xs rounded select-none", children: "\u25B2" }),
130
- /* @__PURE__ */ jsxs("div", { children: [
165
+ /* @__PURE__ */ jsxs2("div", { children: [
131
166
  /* @__PURE__ */ jsx2("span", { className: "text-sm font-black uppercase tracking-wider", children: appName }),
132
167
  /* @__PURE__ */ jsx2("span", { className: "ml-2 text-[10px] text-[var(--skipo-text-muted)] tracking-tight", children: appSubtitle })
133
168
  ] })
134
169
  ] }),
135
- onSwitchToAdmin && /* @__PURE__ */ jsxs("button", { type: "button", onClick: onSwitchToAdmin, className: "px-3 py-1.5 text-[10px] font-black border-2 border-[var(--skipo-accent)] text-[var(--skipo-accent)] flex items-center gap-1.5", children: [
170
+ onSwitchToAdmin && /* @__PURE__ */ jsxs2("button", { type: "button", onClick: onSwitchToAdmin, className: "px-3 py-1.5 text-[10px] font-black border-2 border-[var(--skipo-accent)] text-[var(--skipo-accent)] flex items-center gap-1.5", children: [
136
171
  /* @__PURE__ */ jsx2(Shield, { size: 13 }),
137
172
  " ADMIN ",
138
173
  /* @__PURE__ */ jsx2(ArrowRight, { size: 13 })
139
174
  ] })
140
175
  ] }),
141
- /* @__PURE__ */ jsx2("main", { className: "flex-1 flex items-center justify-center p-4 overflow-auto", children: /* @__PURE__ */ jsxs("div", { className: "w-full max-w-md border-2 border-[var(--skipo-border-color)] bg-[var(--skipo-surface)] shadow-[6px_6px_0px_var(--skipo-border-color)] p-6 my-auto", children: [
142
- /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-2 gap-2 mb-5", children: [
143
- /* @__PURE__ */ jsxs("button", { type: "button", onClick: () => {
176
+ /* @__PURE__ */ jsx2("main", { className: "flex-1 flex items-center justify-center p-4 overflow-auto", children: /* @__PURE__ */ jsxs2("div", { className: "w-full max-w-md border-2 border-[var(--skipo-border-color)] bg-[var(--skipo-surface)] shadow-[6px_6px_0px_var(--skipo-border-color)] p-6 my-auto", children: [
177
+ /* @__PURE__ */ jsxs2("div", { className: "grid grid-cols-2 gap-2 mb-5", children: [
178
+ /* @__PURE__ */ jsxs2("button", { type: "button", onClick: () => {
144
179
  setMode("login");
145
180
  setError(null);
146
181
  }, className: `py-2 text-[10px] font-black border ${mode === "login" ? "bg-[var(--skipo-accent)] text-black" : "bg-[var(--skipo-bg)]"}`, children: [
147
182
  /* @__PURE__ */ jsx2(LogIn, { size: 13, className: "inline mr-1" }),
148
183
  " SIGN IN"
149
184
  ] }),
150
- /* @__PURE__ */ jsxs("button", { type: "button", onClick: () => {
185
+ /* @__PURE__ */ jsxs2("button", { type: "button", onClick: () => {
151
186
  setMode("register");
152
187
  setError(null);
153
188
  }, className: `py-2 text-[10px] font-black border ${mode === "register" ? "bg-[var(--skipo-accent)] text-black" : "bg-[var(--skipo-bg)]"}`, children: [
@@ -155,21 +190,21 @@ var AuthPage = ({
155
190
  " CREATE ACCOUNT"
156
191
  ] })
157
192
  ] }),
158
- error && /* @__PURE__ */ jsxs("div", { className: "mb-4 p-3 border-2 border-red-500/80 bg-red-950/30 text-red-300 text-xs flex items-center gap-2", children: [
193
+ error && /* @__PURE__ */ jsxs2("div", { className: "mb-4 p-3 border-2 border-red-500/80 bg-red-950/30 text-red-300 text-xs flex items-center gap-2", children: [
159
194
  /* @__PURE__ */ jsx2(AlertCircle, { size: 14 }),
160
195
  error
161
196
  ] }),
162
- /* @__PURE__ */ jsxs("form", { onSubmit: submit, className: "space-y-3", children: [
197
+ /* @__PURE__ */ jsxs2("form", { onSubmit: submit, className: "space-y-3", children: [
163
198
  mode === "register" && React.createElement(frnlTextInput, { id: componentId + ".name", label: "Full Name", value: name, onChange: (e) => setName(e.target.value) }),
164
- /* @__PURE__ */ jsxs("div", { children: [
199
+ /* @__PURE__ */ jsxs2("div", { children: [
165
200
  React.createElement(frnlTextInput, { id: componentId + ".email", label: "Email Address", value: email, onChange: (e) => setEmail(e.target.value), type: "email", autoComplete: "username" }),
166
201
  !emailValid && /* @__PURE__ */ jsx2("div", { className: "mt-1 text-[10px] text-red-400", children: "Enter a valid email address." })
167
202
  ] }),
168
203
  /* @__PURE__ */ jsx2("div", { children: React.createElement(frnlTextInput, { id: componentId + ".password", label: "Password", value: password, onChange: (e) => setPassword(e.target.value), type: showPassword ? "text" : "password", autoComplete: mode === "login" ? "current-password" : "new-password", trailingIcon: /* @__PURE__ */ jsx2("button", { type: "button", "aria-label": "Toggle password visibility", onClick: () => setShowPassword((v) => !v), children: showPassword ? /* @__PURE__ */ jsx2(EyeOff, { size: 13 }) : /* @__PURE__ */ jsx2(Eye, { size: 13 }) }) }) }),
169
204
  React.createElement(frnlButton, { type: "submit", disabled: loading, loading, variant: "accent", size: "lg", className: "w-full", icon: /* @__PURE__ */ jsx2(ArrowRight, { size: 13 }) }, mode === "login" ? "SIGN IN TO WORKSPACE" : "CREATE ACCOUNT")
170
205
  ] }),
171
- onGoogleSignIn && /* @__PURE__ */ jsxs(Fragment, { children: [
172
- /* @__PURE__ */ jsxs("div", { className: "my-4 flex items-center gap-2 text-[9px] text-[var(--skipo-text-muted)]", children: [
206
+ (onGoogleSignIn || enableGoogleSignIn) && /* @__PURE__ */ jsxs2(Fragment, { children: [
207
+ /* @__PURE__ */ jsxs2("div", { className: "my-4 flex items-center gap-2 text-[9px] text-[var(--skipo-text-muted)]", children: [
173
208
  /* @__PURE__ */ jsx2("span", { className: "h-px flex-1 bg-[var(--skipo-border-color)]" }),
174
209
  " OR ",
175
210
  /* @__PURE__ */ jsx2("span", { className: "h-px flex-1 bg-[var(--skipo-border-color)]" })
@@ -181,7 +216,25 @@ var AuthPage = ({
181
216
  setGoogleLoading(true);
182
217
  setError(null);
183
218
  try {
184
- const result = await onGoogleSignIn();
219
+ let result;
220
+ if (onGoogleSignIn) {
221
+ result = await onGoogleSignIn();
222
+ } else {
223
+ const callbackURL = typeof window !== "undefined" ? window.location.origin : "";
224
+ const res = await fetch("/api/auth/sign-in/social", {
225
+ method: "POST",
226
+ headers: { "Content-Type": "application/json" },
227
+ body: JSON.stringify({ provider: "google", callbackURL })
228
+ });
229
+ if (res.ok) {
230
+ const data = await res.json().catch(() => ({}));
231
+ if (data.url && typeof window !== "undefined") {
232
+ window.location.href = data.url;
233
+ return;
234
+ }
235
+ }
236
+ throw new Error("Google sign-in endpoint unavailable.");
237
+ }
185
238
  if (!result.success) throw new Error(result.error || "Google sign-in failed.");
186
239
  onSuccess?.(result);
187
240
  } catch (error2) {
@@ -205,17 +258,20 @@ var AuthPage = ({
205
258
  // src/components/auth/LoginModal.tsx
206
259
  import { useState as useState2 } from "react";
207
260
  import { ArrowRight as ArrowRight2, ShieldCheck, AlertCircle as AlertCircle2 } from "lucide-react";
208
- import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
261
+ import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
209
262
  var LoginModal = ({
210
263
  appName = "Ecosystem App",
211
264
  onSuccess,
212
- defaultEmail = ""
265
+ defaultEmail = "",
266
+ onGoogleSignIn,
267
+ enableGoogleSignIn = true
213
268
  }) => {
214
269
  const [email, setEmail] = useState2(defaultEmail);
215
270
  const [password, setPassword] = useState2("");
216
271
  const [isRegister, setIsRegister] = useState2(false);
217
272
  const [name, setName] = useState2("");
218
273
  const [loading, setLoading] = useState2(false);
274
+ const [googleLoading, setGoogleLoading] = useState2(false);
219
275
  const [error, setError] = useState2(null);
220
276
  const handleSubmit = async (e) => {
221
277
  e.preventDefault();
@@ -251,26 +307,26 @@ var LoginModal = ({
251
307
  className: "fixed inset-0 z-50 flex items-center justify-center bg-black/80 backdrop-blur-xs font-mono p-4",
252
308
  onWheel: (e) => e.stopPropagation(),
253
309
  onPointerDown: (e) => e.stopPropagation(),
254
- children: /* @__PURE__ */ jsxs2("div", { className: "w-full max-w-md p-6 border-2 border-[var(--skipo-border-color)] bg-[var(--skipo-surface)] text-[var(--skipo-text)] shadow-2xl rounded-lg space-y-4", children: [
255
- /* @__PURE__ */ jsxs2("div", { className: "flex items-center justify-between pb-3 border-b border-[var(--skipo-border-color)]", children: [
256
- /* @__PURE__ */ jsxs2("div", { className: "flex items-center gap-2", children: [
310
+ children: /* @__PURE__ */ jsxs3("div", { className: "w-full max-w-md p-6 border-2 border-[var(--skipo-border-color)] bg-[var(--skipo-surface)] text-[var(--skipo-text)] shadow-2xl rounded-lg space-y-4", children: [
311
+ /* @__PURE__ */ jsxs3("div", { className: "flex items-center justify-between pb-3 border-b border-[var(--skipo-border-color)]", children: [
312
+ /* @__PURE__ */ jsxs3("div", { className: "flex items-center gap-2", children: [
257
313
  /* @__PURE__ */ jsx3("div", { className: "w-7 h-7 bg-[var(--skipo-accent)] text-black font-black flex items-center justify-center text-xs rounded", children: "\u25B2" }),
258
- /* @__PURE__ */ jsxs2("span", { className: "font-black text-sm tracking-wider uppercase text-[var(--skipo-text)]", children: [
314
+ /* @__PURE__ */ jsxs3("span", { className: "font-black text-sm tracking-wider uppercase text-[var(--skipo-text)]", children: [
259
315
  appName,
260
316
  " Authentication"
261
317
  ] })
262
318
  ] }),
263
- /* @__PURE__ */ jsxs2("span", { className: "text-[9px] px-2 py-0.5 border border-emerald-500/50 bg-emerald-500/10 text-emerald-300 font-bold rounded flex items-center gap-1", children: [
319
+ /* @__PURE__ */ jsxs3("span", { className: "text-[9px] px-2 py-0.5 border border-emerald-500/50 bg-emerald-500/10 text-emerald-300 font-bold rounded flex items-center gap-1", children: [
264
320
  /* @__PURE__ */ jsx3(ShieldCheck, { size: 10 }),
265
321
  " SYSTEM DB"
266
322
  ] })
267
323
  ] }),
268
- error && /* @__PURE__ */ jsxs2("div", { className: "p-3 border border-red-500/60 bg-red-500/10 text-red-300 text-xs rounded flex items-start gap-2", children: [
324
+ error && /* @__PURE__ */ jsxs3("div", { className: "p-3 border border-red-500/60 bg-red-500/10 text-red-300 text-xs rounded flex items-start gap-2", children: [
269
325
  /* @__PURE__ */ jsx3(AlertCircle2, { size: 14, className: "shrink-0 mt-0.5" }),
270
326
  /* @__PURE__ */ jsx3("span", { children: error })
271
327
  ] }),
272
- /* @__PURE__ */ jsxs2("form", { onSubmit: handleSubmit, className: "space-y-3", children: [
273
- isRegister && /* @__PURE__ */ jsxs2("div", { children: [
328
+ /* @__PURE__ */ jsxs3("form", { onSubmit: handleSubmit, className: "space-y-3", children: [
329
+ isRegister && /* @__PURE__ */ jsxs3("div", { children: [
274
330
  /* @__PURE__ */ jsx3("label", { className: "block text-[10px] font-black uppercase mb-1", children: "Full Name *" }),
275
331
  /* @__PURE__ */ jsx3(
276
332
  BaseInput,
@@ -283,7 +339,7 @@ var LoginModal = ({
283
339
  }
284
340
  )
285
341
  ] }),
286
- /* @__PURE__ */ jsxs2("div", { children: [
342
+ /* @__PURE__ */ jsxs3("div", { children: [
287
343
  /* @__PURE__ */ jsx3("label", { className: "block text-[10px] font-black uppercase mb-1", children: "Email Address *" }),
288
344
  /* @__PURE__ */ jsx3(
289
345
  BaseInput,
@@ -296,7 +352,7 @@ var LoginModal = ({
296
352
  }
297
353
  )
298
354
  ] }),
299
- /* @__PURE__ */ jsxs2("div", { children: [
355
+ /* @__PURE__ */ jsxs3("div", { children: [
300
356
  /* @__PURE__ */ jsx3("label", { className: "block text-[10px] font-black uppercase mb-1", children: "Password *" }),
301
357
  /* @__PURE__ */ jsx3(
302
358
  BaseInput,
@@ -309,7 +365,7 @@ var LoginModal = ({
309
365
  }
310
366
  )
311
367
  ] }),
312
- /* @__PURE__ */ jsx3("div", { className: "pt-2", children: /* @__PURE__ */ jsxs2(
368
+ /* @__PURE__ */ jsx3("div", { className: "pt-2", children: /* @__PURE__ */ jsxs3(
313
369
  BaseButton,
314
370
  {
315
371
  variant: "accent",
@@ -324,7 +380,48 @@ var LoginModal = ({
324
380
  }
325
381
  ) })
326
382
  ] }),
327
- /* @__PURE__ */ jsxs2("div", { className: "pt-2 border-t border-[var(--skipo-border-color)]/60 flex items-center justify-between text-[11px]", children: [
383
+ enableGoogleSignIn !== false && /* @__PURE__ */ jsxs3("div", { className: "space-y-2", children: [
384
+ /* @__PURE__ */ jsxs3("div", { className: "flex items-center gap-2 text-[9px] text-[var(--skipo-text-muted)]", children: [
385
+ /* @__PURE__ */ jsx3("span", { className: "h-px flex-1 bg-[var(--skipo-border-color)]" }),
386
+ " OR ",
387
+ /* @__PURE__ */ jsx3("span", { className: "h-px flex-1 bg-[var(--skipo-border-color)]" })
388
+ ] }),
389
+ /* @__PURE__ */ jsx3(
390
+ GoogleSignInButton,
391
+ {
392
+ disabled: loading || googleLoading,
393
+ loading: googleLoading,
394
+ onSignIn: async () => {
395
+ setGoogleLoading(true);
396
+ setError(null);
397
+ try {
398
+ if (onGoogleSignIn) {
399
+ await onGoogleSignIn();
400
+ } else {
401
+ const res = await fetch("/api/auth/sign-in/social", {
402
+ method: "POST",
403
+ headers: { "Content-Type": "application/json" },
404
+ body: JSON.stringify({ provider: "google", callbackURL: window.location.origin })
405
+ });
406
+ if (res.ok) {
407
+ const data = await res.json().catch(() => ({}));
408
+ if (data.url) {
409
+ window.location.href = data.url;
410
+ return;
411
+ }
412
+ }
413
+ throw new Error("Google sign-in endpoint unavailable.");
414
+ }
415
+ } catch (err) {
416
+ setError(err.message || "Google sign-in failed.");
417
+ } finally {
418
+ setGoogleLoading(false);
419
+ }
420
+ }
421
+ }
422
+ )
423
+ ] }),
424
+ /* @__PURE__ */ jsxs3("div", { className: "pt-2 border-t border-[var(--skipo-border-color)]/60 flex items-center justify-between text-[11px]", children: [
328
425
  /* @__PURE__ */ jsx3(
329
426
  "button",
330
427
  {
@@ -345,6 +442,7 @@ var LoginModal = ({
345
442
  };
346
443
 
347
444
  export {
445
+ GoogleIcon,
348
446
  GoogleSignInButton,
349
447
  AUTH_PAGE_REQUIRED_SERVICES,
350
448
  authPageDefinition,
@@ -1063,13 +1063,14 @@ var DirectChatMessageList = ({
1063
1063
 
1064
1064
  // src/components/ai/chat/DirectChatInput.tsx
1065
1065
  import { useState as useState10 } from "react";
1066
- import { Send } from "lucide-react";
1066
+ import { Bug, Send } from "lucide-react";
1067
1067
  import { jsx as jsx21, jsxs as jsxs21 } from "react/jsx-runtime";
1068
1068
  var DirectChatInput = ({
1069
1069
  onSendMessage,
1070
1070
  disabled = false,
1071
1071
  placeholder = "Type a prompt... (Shift+Enter for new line)",
1072
- toolsSlot
1072
+ toolsSlot,
1073
+ onReportBug
1073
1074
  }) => {
1074
1075
  const [content, setContent] = useState10("");
1075
1076
  const handleKeyDown = (e) => {
@@ -1084,7 +1085,13 @@ var DirectChatInput = ({
1084
1085
  setContent("");
1085
1086
  };
1086
1087
  return /* @__PURE__ */ jsxs21("div", { className: "p-3 border-t border-slate-300 dark:border-slate-800 bg-white dark:bg-slate-900 font-mono text-xs", children: [
1087
- /* @__PURE__ */ jsx21("div", { className: "flex items-center justify-between pb-2", children: /* @__PURE__ */ jsx21("div", { className: "flex items-center gap-2", children: toolsSlot }) }),
1088
+ /* @__PURE__ */ jsx21("div", { className: "flex items-center justify-between pb-2", children: /* @__PURE__ */ jsxs21("div", { className: "flex items-center gap-2", children: [
1089
+ toolsSlot,
1090
+ onReportBug && /* @__PURE__ */ jsxs21(BaseButton, { size: "sm", variant: "ghost", onClick: () => content.trim() && onReportBug(content.trim()), disabled: disabled || !content.trim(), title: "Report bug", children: [
1091
+ /* @__PURE__ */ jsx21(Bug, { size: 13 }),
1092
+ " Report bug"
1093
+ ] })
1094
+ ] }) }),
1088
1095
  /* @__PURE__ */ jsxs21("div", { className: "flex items-end gap-2", children: [
1089
1096
  /* @__PURE__ */ jsx21("div", { className: "flex-1", children: /* @__PURE__ */ jsx21(
1090
1097
  BaseTextarea,
@@ -359,6 +359,7 @@ interface DirectChatInputProps {
359
359
  disabled?: boolean;
360
360
  placeholder?: string;
361
361
  toolsSlot?: React__default.ReactNode;
362
+ onReportBug?: (description: string) => void;
362
363
  }
363
364
  declare const DirectChatInput: React__default.FC<DirectChatInputProps>;
364
365
 
@@ -22,7 +22,7 @@ import {
22
22
  SingleKeyForm,
23
23
  TimelineScrubber,
24
24
  getProviderIcon
25
- } from "../../chunk-UJK3JKRK.js";
25
+ } from "../../chunk-XMRSW4TL.js";
26
26
  import "../../chunk-KIFQA7L6.js";
27
27
  import "../../chunk-GKP6KHTI.js";
28
28
  import "../../chunk-UOR4P6PO.js";
@@ -21,6 +21,7 @@ interface AuthPageProps {
21
21
  }) => Promise<AuthResult>;
22
22
  onSuccess?: (result: AuthResult) => void;
23
23
  onGoogleSignIn?: () => Promise<AuthResult>;
24
+ enableGoogleSignIn?: boolean;
24
25
  onSwitchToAdmin?: () => void;
25
26
  }
26
27
  declare const authPageDefinition: {
@@ -83,6 +84,8 @@ interface LoginModalProps {
83
84
  appName?: string;
84
85
  onSuccess: (user: any, token: string) => void;
85
86
  defaultEmail?: string;
87
+ onGoogleSignIn?: () => Promise<void> | void;
88
+ enableGoogleSignIn?: boolean;
86
89
  }
87
90
  declare const LoginModal: React__default.FC<LoginModalProps>;
88
91
 
@@ -91,7 +94,12 @@ interface GoogleSignInButtonProps {
91
94
  disabled?: boolean;
92
95
  loading?: boolean;
93
96
  label?: string;
97
+ className?: string;
94
98
  }
99
+ declare const GoogleIcon: React__default.FC<{
100
+ size?: number;
101
+ className?: string;
102
+ }>;
95
103
  declare const GoogleSignInButton: React__default.FC<GoogleSignInButtonProps>;
96
104
 
97
- export { AUTH_PAGE_REQUIRED_SERVICES, AuthPage, type AuthPageProps, type AuthResult, GoogleSignInButton, type GoogleSignInButtonProps, LoginModal, type LoginModalProps, authPageDefinition };
105
+ export { AUTH_PAGE_REQUIRED_SERVICES, AuthPage, type AuthPageProps, type AuthResult, GoogleIcon, GoogleSignInButton, type GoogleSignInButtonProps, LoginModal, type LoginModalProps, authPageDefinition };
@@ -1,10 +1,11 @@
1
1
  import {
2
2
  AUTH_PAGE_REQUIRED_SERVICES,
3
3
  AuthPage,
4
+ GoogleIcon,
4
5
  GoogleSignInButton,
5
6
  LoginModal,
6
7
  authPageDefinition
7
- } from "../../chunk-RBYTWUD4.js";
8
+ } from "../../chunk-5HQ6DSFX.js";
8
9
  import "../../chunk-5QDNIDDN.js";
9
10
  import "../../chunk-5ZMXFCD4.js";
10
11
  import "../../chunk-C3L53YN4.js";
@@ -15,6 +16,7 @@ import "../../chunk-A2CDQISJ.js";
15
16
  export {
16
17
  AUTH_PAGE_REQUIRED_SERVICES,
17
18
  AuthPage,
19
+ GoogleIcon,
18
20
  GoogleSignInButton,
19
21
  LoginModal,
20
22
  authPageDefinition
@@ -7,7 +7,7 @@ export { AppShell, AppShellProps, BreadcrumbNav, BreadcrumbNavProps, HeaderBar,
7
7
  export { ApiCallIndicator, ApiCallIndicatorProps, AutoSaveStatus, AutoSaveToggle, AutoSaveToggleProps, BottomStripContextValue, BottomStripProvider, BottomStripProviderProps, StatusLight, StatusLightProps, SystemMessage, SystemMessageDisplay, SystemMessageDisplayProps, SystemMessageType, useBottomStrip } from './components/bottom-strip/index.js';
8
8
  export { B as BottomStrip, a as BottomStripProps } from './BottomStrip-DYhAUQR4.js';
9
9
  export { AccountsSettingsSection, AccountsSettingsSectionProps, SettingsTab, SettingsTabProps, ThemeSettingsSection } from './components/settings/index.js';
10
- export { AUTH_PAGE_REQUIRED_SERVICES, AuthPage, AuthPageProps, AuthResult, GoogleSignInButton, GoogleSignInButtonProps, LoginModal, LoginModalProps, authPageDefinition } from './components/auth/index.js';
10
+ export { AUTH_PAGE_REQUIRED_SERVICES, AuthPage, AuthPageProps, AuthResult, GoogleIcon, GoogleSignInButton, GoogleSignInButtonProps, LoginModal, LoginModalProps, authPageDefinition } from './components/auth/index.js';
11
11
  export { FrnlTileRecord, TilesMenu, TilesMenuProps, tilesMenuDefinition } from './components/tiles/index.js';
12
12
  export { GRAPHS_MENU_REQUIRED_SERVICES, GraphRecord, GraphsMenu, GraphsMenuProps } from './components/graph/index.js';
13
13
  export { BackblazeAccount, BackblazeBucket, KloksServiceInvoker, SrklBackblazeAccount, SrklBackblazeTile, StorageOptionTiles, StoragePresetTile, StorageSelection, WORKSPACE_CREATE_DIALOG_REQUIRED_SERVICES, WORKSPACE_TILES_MENU_REQUIRED_SERVICES, WorkspaceCreateDialog, WorkspaceCreateDialogProps, WorkspaceCreateInput, WorkspaceGate, WorkspaceGateProps, WorkspaceRecord, WorkspaceSecondaryClone, WorkspaceSecondaryClonesPanel, WorkspaceStorageReadonlyPanel, WorkspaceStorageService, WorkspaceTilesMenu, WorkspaceTilesMenuProps, createKloksWorkspaceStorageService, defaultWorkspaceStorageService, workspaceTilesMenuDefinition } from './components/workspace/index.js';
@@ -64,6 +64,18 @@ import {
64
64
  TilesMenu,
65
65
  tilesMenuDefinition
66
66
  } from "./chunk-DZTJJOLR.js";
67
+ import {
68
+ frnlBadge,
69
+ frnlBottomBar,
70
+ frnlPage,
71
+ frnlSelect,
72
+ frnlSelectDefinition,
73
+ frnlSlider,
74
+ frnlTabWindow,
75
+ frnlToggle,
76
+ frnlToggleDefinition,
77
+ frnlTopBar
78
+ } from "./chunk-G5CYPT3P.js";
67
79
  import {
68
80
  ActionButton,
69
81
  Badge,
@@ -91,18 +103,6 @@ import {
91
103
  ToolbarPanel,
92
104
  UIParent
93
105
  } from "./chunk-Q324BMDJ.js";
94
- import {
95
- frnlBadge,
96
- frnlBottomBar,
97
- frnlPage,
98
- frnlSelect,
99
- frnlSelectDefinition,
100
- frnlSlider,
101
- frnlTabWindow,
102
- frnlToggle,
103
- frnlToggleDefinition,
104
- frnlTopBar
105
- } from "./chunk-G5CYPT3P.js";
106
106
  import "./chunk-SLJBDDSN.js";
107
107
  import {
108
108
  DEFAULT_PALETTE_ID,
@@ -189,7 +189,7 @@ import {
189
189
  SingleKeyForm,
190
190
  TimelineScrubber,
191
191
  getProviderIcon
192
- } from "./chunk-UJK3JKRK.js";
192
+ } from "./chunk-XMRSW4TL.js";
193
193
  import {
194
194
  BaseSelect,
195
195
  BaseTextarea,
@@ -207,10 +207,11 @@ import {
207
207
  import {
208
208
  AUTH_PAGE_REQUIRED_SERVICES,
209
209
  AuthPage,
210
+ GoogleIcon,
210
211
  GoogleSignInButton,
211
212
  LoginModal,
212
213
  authPageDefinition
213
- } from "./chunk-RBYTWUD4.js";
214
+ } from "./chunk-5HQ6DSFX.js";
214
215
  import {
215
216
  frnlButton,
216
217
  frnlButtonDefinition,
@@ -303,6 +304,7 @@ export {
303
304
  FrnlStoreProvider,
304
305
  GRAPHS_MENU_REQUIRED_SERVICES,
305
306
  GhostButton,
307
+ GoogleIcon,
306
308
  GoogleSignInButton,
307
309
  GraphsMenu,
308
310
  HeaderBar,