@comergehq/studio 0.1.2 → 0.1.4

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.
Files changed (174) hide show
  1. package/dist/index.d.mts +2 -10
  2. package/dist/index.d.ts +2 -10
  3. package/dist/index.js +293 -264
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.mjs +251 -222
  6. package/dist/index.mjs.map +1 -1
  7. package/package.json +8 -5
  8. package/src/components/chat/ChatComposer.tsx +277 -0
  9. package/src/components/chat/ChatHeader.tsx +31 -0
  10. package/src/components/chat/ChatMessageBubble.tsx +69 -0
  11. package/src/components/chat/ChatMessageList.tsx +137 -0
  12. package/src/components/chat/ChatPage.tsx +69 -0
  13. package/src/components/chat/ForkNoticeBanner.tsx +66 -0
  14. package/src/components/chat/MultilineTextInput.tsx +46 -0
  15. package/src/components/chat/ScrollToBottomButton.tsx +78 -0
  16. package/src/components/chat/TypingIndicator.tsx +54 -0
  17. package/src/components/chat/index.ts +28 -0
  18. package/src/components/comments/AppCommentsSheet.tsx +213 -0
  19. package/src/components/comments/CommentRow.tsx +63 -0
  20. package/src/components/comments/formatTimeAgo.ts +3 -0
  21. package/src/components/comments/index.ts +3 -0
  22. package/src/components/comments/useAppComments.ts +74 -0
  23. package/src/components/comments/useAppDetails.ts +35 -0
  24. package/src/components/comments/useIosKeyboardSnapFix.ts +24 -0
  25. package/src/components/dialogs/ConfirmMergeRequestDialog.tsx +156 -0
  26. package/src/components/dialogs/index.ts +4 -0
  27. package/src/components/draw/DrawColorPicker.tsx +77 -0
  28. package/src/components/draw/DrawModeOverlay.tsx +144 -0
  29. package/src/components/draw/DrawSurface.tsx +127 -0
  30. package/src/components/draw/DrawToolbar.tsx +253 -0
  31. package/src/components/draw/index.ts +15 -0
  32. package/src/components/draw/optionalHaptics.ts +15 -0
  33. package/src/components/draw/strokes.ts +21 -0
  34. package/src/components/draw/types.ts +9 -0
  35. package/src/components/floating-draggable-button/FloatingDraggableButton.tsx +323 -0
  36. package/src/components/floating-draggable-button/constants.ts +17 -0
  37. package/src/components/floating-draggable-button/index.ts +4 -0
  38. package/src/components/floating-draggable-button/types.ts +63 -0
  39. package/src/components/icons/MergeIcon.tsx +14 -0
  40. package/src/components/icons/StudioIcons.tsx +66 -0
  41. package/src/components/index.ts +17 -0
  42. package/src/components/merge-requests/MergeRequestStatusCard.tsx +179 -0
  43. package/src/components/merge-requests/ReviewMergeRequestActionButton.tsx +62 -0
  44. package/src/components/merge-requests/ReviewMergeRequestCard.tsx +192 -0
  45. package/src/components/merge-requests/ReviewMergeRequestCarousel.tsx +132 -0
  46. package/src/components/merge-requests/index.ts +7 -0
  47. package/src/components/merge-requests/mergeRequestStatusDisplay.ts +23 -0
  48. package/src/components/merge-requests/toIsoString.ts +9 -0
  49. package/src/components/merge-requests/useControlledExpansion.ts +16 -0
  50. package/src/components/models/index.ts +9 -0
  51. package/src/components/models/types.ts +43 -0
  52. package/src/components/overlays/EdgeGlowFrame.tsx +105 -0
  53. package/src/components/overlays/index.ts +4 -0
  54. package/src/components/preview/PreviewHeroCard.tsx +58 -0
  55. package/src/components/preview/PreviewImage.tsx +22 -0
  56. package/src/components/preview/PreviewMetaRow.tsx +70 -0
  57. package/src/components/preview/PreviewPage.tsx +36 -0
  58. package/src/components/preview/PreviewPlaceholder.tsx +72 -0
  59. package/src/components/preview/PreviewStatusBadge.tsx +63 -0
  60. package/src/components/preview/StatsBar.tsx +109 -0
  61. package/src/components/preview/index.ts +22 -0
  62. package/src/components/primitives/Avatar.tsx +68 -0
  63. package/src/components/primitives/Button.tsx +102 -0
  64. package/src/components/primitives/Card.tsx +30 -0
  65. package/src/components/primitives/Divider.tsx +17 -0
  66. package/src/components/primitives/Icon.tsx +40 -0
  67. package/src/components/primitives/MarkdownText.tsx +72 -0
  68. package/src/components/primitives/Modal.tsx +53 -0
  69. package/src/components/primitives/Surface.tsx +42 -0
  70. package/src/components/primitives/Text.tsx +83 -0
  71. package/src/components/primitives/index.ts +35 -0
  72. package/src/components/primitives/types.ts +30 -0
  73. package/src/components/studio-sheet/StudioBottomSheet.tsx +114 -0
  74. package/src/components/studio-sheet/StudioSheetBackground.tsx +63 -0
  75. package/src/components/studio-sheet/StudioSheetHeader.tsx +35 -0
  76. package/src/components/studio-sheet/StudioSheetHeaderIconButton.tsx +109 -0
  77. package/src/components/studio-sheet/StudioSheetPager.tsx +66 -0
  78. package/src/components/studio-sheet/index.ts +18 -0
  79. package/src/components/studio-sheet/types.ts +5 -0
  80. package/src/components/utils/color.ts +25 -0
  81. package/src/components/utils/formatTimeAgo.ts +19 -0
  82. package/src/core/logger.ts +42 -0
  83. package/src/core/services/http/baseUrl.ts +3 -0
  84. package/src/core/services/http/index.ts +128 -0
  85. package/src/core/services/http/public.ts +33 -0
  86. package/src/core/services/supabase/auth.ts +41 -0
  87. package/src/core/services/supabase/client.ts +43 -0
  88. package/src/core/services/supabase/index.ts +7 -0
  89. package/src/data/agent/remote.ts +30 -0
  90. package/src/data/agent/repository.ts +34 -0
  91. package/src/data/agent/types.ts +28 -0
  92. package/src/data/apps/bundles/remote.ts +47 -0
  93. package/src/data/apps/bundles/repository.ts +35 -0
  94. package/src/data/apps/bundles/types.ts +27 -0
  95. package/src/data/apps/images/remote.ts +61 -0
  96. package/src/data/apps/images/repository.ts +47 -0
  97. package/src/data/apps/remote.ts +97 -0
  98. package/src/data/apps/repository.ts +185 -0
  99. package/src/data/apps/types.ts +206 -0
  100. package/src/data/attachment/remote.ts +32 -0
  101. package/src/data/attachment/repository.ts +40 -0
  102. package/src/data/attachment/types.ts +42 -0
  103. package/src/data/base-remote.ts +3 -0
  104. package/src/data/base-repository.ts +11 -0
  105. package/src/data/comments/likes/remote.ts +87 -0
  106. package/src/data/comments/likes/repository.ts +61 -0
  107. package/src/data/comments/likes/types.ts +47 -0
  108. package/src/data/comments/remote.ts +71 -0
  109. package/src/data/comments/repository.ts +53 -0
  110. package/src/data/comments/types.ts +60 -0
  111. package/src/data/github/remote.ts +23 -0
  112. package/src/data/github/repository.ts +35 -0
  113. package/src/data/github/types.ts +23 -0
  114. package/src/data/home/remote.ts +24 -0
  115. package/src/data/home/repository.ts +28 -0
  116. package/src/data/home/types.ts +70 -0
  117. package/src/data/index.ts +3 -0
  118. package/src/data/likes/remote.ts +57 -0
  119. package/src/data/likes/repository.ts +47 -0
  120. package/src/data/likes/types.ts +46 -0
  121. package/src/data/me/remote.ts +28 -0
  122. package/src/data/me/repository.ts +30 -0
  123. package/src/data/me/types.ts +14 -0
  124. package/src/data/merge-requests/remote.ts +76 -0
  125. package/src/data/merge-requests/repository.ts +66 -0
  126. package/src/data/merge-requests/types.ts +33 -0
  127. package/src/data/messages/remote.ts +21 -0
  128. package/src/data/messages/repository.ts +104 -0
  129. package/src/data/messages/types.ts +20 -0
  130. package/src/data/public/studio-config/remote.ts +19 -0
  131. package/src/data/public/studio-config/repository.ts +23 -0
  132. package/src/data/public/studio-config/types.ts +6 -0
  133. package/src/data/ratings/remote.ts +76 -0
  134. package/src/data/ratings/repository.ts +63 -0
  135. package/src/data/ratings/types.ts +57 -0
  136. package/src/data/threads/remote.ts +40 -0
  137. package/src/data/threads/repository.ts +41 -0
  138. package/src/data/threads/types.ts +25 -0
  139. package/src/data/types.ts +8 -0
  140. package/src/data/users/remote.ts +31 -0
  141. package/src/data/users/repository.ts +45 -0
  142. package/src/data/users/types.ts +15 -0
  143. package/src/index.ts +6 -0
  144. package/src/studio/ComergeStudio.tsx +239 -0
  145. package/src/studio/bootstrap/StudioBootstrap.tsx +45 -0
  146. package/src/studio/bootstrap/useStudioBootstrap.ts +55 -0
  147. package/src/studio/hooks/useApp.ts +83 -0
  148. package/src/studio/hooks/useAppStats.ts +111 -0
  149. package/src/studio/hooks/useAttachmentUpload.ts +59 -0
  150. package/src/studio/hooks/useBundleManager.ts +389 -0
  151. package/src/studio/hooks/useMergeRequests.ts +173 -0
  152. package/src/studio/hooks/useStudioActions.ts +96 -0
  153. package/src/studio/hooks/useThreadMessages.ts +85 -0
  154. package/src/studio/lib/chat.ts +34 -0
  155. package/src/studio/ui/ChatPanel.tsx +154 -0
  156. package/src/studio/ui/ConfirmMergeFlow.tsx +55 -0
  157. package/src/studio/ui/PreviewPanel.tsx +131 -0
  158. package/src/studio/ui/RuntimeRenderer.tsx +40 -0
  159. package/src/studio/ui/StudioOverlay.tsx +257 -0
  160. package/src/studio/ui/preview-panel/PressableCardRow.tsx +49 -0
  161. package/src/studio/ui/preview-panel/PreviewCollaborateSection.tsx +174 -0
  162. package/src/studio/ui/preview-panel/PreviewCustomizeSection.tsx +160 -0
  163. package/src/studio/ui/preview-panel/PreviewHeroSection.tsx +56 -0
  164. package/src/studio/ui/preview-panel/PreviewMetaSection.tsx +67 -0
  165. package/src/studio/ui/preview-panel/PreviewPanelHeader.tsx +48 -0
  166. package/src/studio/ui/preview-panel/SectionTitle.tsx +31 -0
  167. package/src/studio/ui/preview-panel/usePreviewPanelData.ts +132 -0
  168. package/src/studio/ui/preview-panel/utils.ts +29 -0
  169. package/src/theme/index.ts +5 -0
  170. package/src/theme/tokens.ts +118 -0
  171. package/src/theme/types.ts +90 -0
  172. package/src/theme/useTheme.ts +11 -0
  173. package/dist/assets/images/merge.svg +0 -3
  174. package/dist/merge-72UG27QV.svg +0 -3
package/dist/index.js CHANGED
@@ -214,6 +214,39 @@ function Text({
214
214
  // src/studio/bootstrap/useStudioBootstrap.ts
215
215
  var React = __toESM(require("react"));
216
216
 
217
+ // src/core/services/http/public.ts
218
+ var import_axios = __toESM(require("axios"));
219
+
220
+ // src/core/services/http/baseUrl.ts
221
+ var BASE_URL = "http://192.168.8.175:8080";
222
+
223
+ // src/core/services/http/public.ts
224
+ var CLIENT_KEY_HEADER = "x-comerge-api-key";
225
+ var clientApiKey = null;
226
+ var publicApi = import_axios.default.create({
227
+ baseURL: BASE_URL,
228
+ timeout: 3e4,
229
+ headers: {
230
+ Accept: "application/json",
231
+ "Content-Type": "application/json"
232
+ }
233
+ });
234
+ function setClientApiKey(apiKey) {
235
+ var _a;
236
+ const trimmed = ((_a = apiKey == null ? void 0 : apiKey.trim) == null ? void 0 : _a.call(apiKey)) ?? "";
237
+ if (!trimmed) {
238
+ throw new Error("comerge-studio: apiKey is required");
239
+ }
240
+ clientApiKey = trimmed;
241
+ publicApi.defaults.headers.common[CLIENT_KEY_HEADER] = trimmed;
242
+ }
243
+ publicApi.interceptors.request.use((config) => {
244
+ if (!clientApiKey) return config;
245
+ config.headers = config.headers ?? {};
246
+ config.headers[CLIENT_KEY_HEADER] = clientApiKey;
247
+ return config;
248
+ });
249
+
217
250
  // src/core/services/supabase/client.ts
218
251
  var import_supabase_js = require("@supabase/supabase-js");
219
252
  var clientSingleton = null;
@@ -284,22 +317,6 @@ var BaseRepository = class {
284
317
  }
285
318
  };
286
319
 
287
- // src/core/services/http/public.ts
288
- var import_axios = __toESM(require("axios"));
289
-
290
- // src/core/services/http/baseUrl.ts
291
- var BASE_URL = "http://192.168.8.175:8080";
292
-
293
- // src/core/services/http/public.ts
294
- var publicApi = import_axios.default.create({
295
- baseURL: BASE_URL,
296
- timeout: 3e4,
297
- headers: {
298
- Accept: "application/json",
299
- "Content-Type": "application/json"
300
- }
301
- });
302
-
303
320
  // src/data/base-remote.ts
304
321
  var BaseRemote = class {
305
322
  };
@@ -337,6 +354,7 @@ function useStudioBootstrap(options) {
337
354
  let cancelled = false;
338
355
  (async () => {
339
356
  try {
357
+ setClientApiKey(options.apiKey);
340
358
  const requireAuth = isSupabaseClientInjected();
341
359
  if (!requireAuth) {
342
360
  const cfg = await studioConfigRepository.get();
@@ -354,14 +372,14 @@ function useStudioBootstrap(options) {
354
372
  return () => {
355
373
  cancelled = true;
356
374
  };
357
- }, []);
375
+ }, [options.apiKey]);
358
376
  return state;
359
377
  }
360
378
 
361
379
  // src/studio/bootstrap/StudioBootstrap.tsx
362
380
  var import_jsx_runtime2 = require("react/jsx-runtime");
363
- function StudioBootstrap({ children, fallback, renderError }) {
364
- const { ready, error, userId } = useStudioBootstrap({});
381
+ function StudioBootstrap({ children, fallback, renderError, apiKey }) {
382
+ const { ready, error, userId } = useStudioBootstrap({ apiKey });
365
383
  if (error) {
366
384
  return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react_native3.View, { style: { flex: 1, justifyContent: "center", alignItems: "center", padding: 24 }, children: renderError ? renderError(error) : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(Text, { variant: "bodyMuted", children: error.message }) });
367
385
  }
@@ -3834,11 +3852,21 @@ var import_react_native28 = require("react-native");
3834
3852
  var import_liquid_glass6 = require("@callstack/liquid-glass");
3835
3853
  var import_lucide_react_native5 = require("lucide-react-native");
3836
3854
 
3837
- // src/assets/images/merge.svg
3838
- var merge_default = "./merge-72UG27QV.svg";
3855
+ // src/components/icons/MergeIcon.tsx
3856
+ var import_react_native_svg2 = __toESM(require("react-native-svg"));
3857
+ var import_jsx_runtime28 = require("react/jsx-runtime");
3858
+ function MergeIcon({ color = "currentColor", width = 24, height = 24, ...props }) {
3859
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native_svg2.default, { viewBox: "0 0 486 486", width, height, ...props, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3860
+ import_react_native_svg2.Path,
3861
+ {
3862
+ d: "M237.025 0H243.664C254.876 95.0361 275.236 175.597 304.743 241.684C334.249 307.478 367.002 357.774 403 392.572L389.722 486C361.691 458.22 338.233 429.417 319.349 399.59C300.464 369.764 284.531 335.843 271.548 297.829C258.565 259.522 246.615 214.343 235.697 162.292L237.91 161.415C228.468 214.928 217.993 261.569 206.485 301.338C194.978 341.107 179.634 375.904 160.455 405.731C141.571 435.265 115.752 462.022 83 486L96.278 392.572C124.014 369.179 147.62 336.72 167.094 295.197C186.864 253.381 202.65 206.886 214.452 155.713C226.255 104.247 233.779 52.343 237.025 0Z",
3863
+ fill: color
3864
+ }
3865
+ ) });
3866
+ }
3839
3867
 
3840
3868
  // src/components/preview/StatsBar.tsx
3841
- var import_jsx_runtime28 = require("react/jsx-runtime");
3869
+ var import_jsx_runtime29 = require("react/jsx-runtime");
3842
3870
  function StatsBar({
3843
3871
  likeCount,
3844
3872
  commentCount,
@@ -3852,7 +3880,7 @@ function StatsBar({
3852
3880
  }) {
3853
3881
  const theme = useTheme();
3854
3882
  const statsBgColor = theme.scheme === "dark" ? "rgba(24, 24, 27, 0.5)" : "rgba(255, 255, 255, 0.5)";
3855
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3883
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3856
3884
  import_react_native28.View,
3857
3885
  {
3858
3886
  style: [
@@ -3860,7 +3888,7 @@ function StatsBar({
3860
3888
  centered && { alignItems: "center" },
3861
3889
  style
3862
3890
  ],
3863
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3891
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3864
3892
  import_liquid_glass6.LiquidGlassView,
3865
3893
  {
3866
3894
  style: [
@@ -3869,16 +3897,16 @@ function StatsBar({
3869
3897
  !import_liquid_glass6.isLiquidGlassSupported && { backgroundColor: statsBgColor }
3870
3898
  ],
3871
3899
  effect: "clear",
3872
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center", justifyContent: "space-between", paddingHorizontal: 16 }, children: [
3873
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3900
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center", justifyContent: "space-between", paddingHorizontal: 16 }, children: [
3901
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3874
3902
  import_react_native28.Pressable,
3875
3903
  {
3876
3904
  disabled: !onPressLike,
3877
3905
  onPress: onPressLike,
3878
3906
  hitSlop: 8,
3879
3907
  style: { paddingVertical: 8 },
3880
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
3881
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3908
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
3909
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3882
3910
  import_lucide_react_native5.Heart,
3883
3911
  {
3884
3912
  size: 16,
@@ -3887,8 +3915,8 @@ function StatsBar({
3887
3915
  fill: isLiked ? theme.colors.danger : "transparent"
3888
3916
  }
3889
3917
  ),
3890
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native28.View, { style: { width: 4 } }),
3891
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3918
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native28.View, { style: { width: 4 } }),
3919
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3892
3920
  Text,
3893
3921
  {
3894
3922
  variant: "caption",
@@ -3902,24 +3930,24 @@ function StatsBar({
3902
3930
  ] })
3903
3931
  }
3904
3932
  ),
3905
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
3933
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
3906
3934
  import_react_native28.Pressable,
3907
3935
  {
3908
3936
  disabled: !onPressComments,
3909
3937
  onPress: onPressComments,
3910
3938
  hitSlop: 8,
3911
3939
  style: { paddingVertical: 8 },
3912
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
3913
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_lucide_react_native5.MessageCircle, { size: 16, strokeWidth: 2.5, color: "#FFFFFF" }),
3914
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native28.View, { style: { width: 4 } }),
3915
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Text, { variant: "caption", style: { color: "#FFFFFF", fontWeight: theme.typography.fontWeight.bold }, children: commentCount })
3940
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
3941
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_lucide_react_native5.MessageCircle, { size: 16, strokeWidth: 2.5, color: "#FFFFFF" }),
3942
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native28.View, { style: { width: 4 } }),
3943
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Text, { variant: "caption", style: { color: "#FFFFFF", fontWeight: theme.typography.fontWeight.bold }, children: commentCount })
3916
3944
  ] })
3917
3945
  }
3918
3946
  ),
3919
- /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center", paddingVertical: 8 }, children: [
3920
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native28.View, { style: { transform: [{ scaleY: -1 }] }, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(merge_default, { width: 14, height: 14, color: "#FFFFFF" }) }),
3921
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react_native28.View, { style: { width: 4 } }),
3922
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Text, { variant: "caption", style: { color: "#FFFFFF", fontWeight: theme.typography.fontWeight.bold }, children: forkCount })
3947
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_react_native28.View, { style: { flexDirection: "row", alignItems: "center", paddingVertical: 8 }, children: [
3948
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native28.View, { style: { transform: [{ scaleY: -1 }] }, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(MergeIcon, { width: 14, height: 14, color: "#FFFFFF" }) }),
3949
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_react_native28.View, { style: { width: 4 } }),
3950
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Text, { variant: "caption", style: { color: "#FFFFFF", fontWeight: theme.typography.fontWeight.bold }, children: forkCount })
3923
3951
  ] })
3924
3952
  ] })
3925
3953
  }
@@ -3944,7 +3972,7 @@ var APP_STATUS_LABEL = {
3944
3972
  };
3945
3973
 
3946
3974
  // src/components/preview/PreviewStatusBadge.tsx
3947
- var import_jsx_runtime29 = require("react/jsx-runtime");
3975
+ var import_jsx_runtime30 = require("react/jsx-runtime");
3948
3976
  var STATUS_BG = {
3949
3977
  ready: "#10B981",
3950
3978
  // emerald-500
@@ -3973,7 +4001,7 @@ var STATUS_ICON = {
3973
4001
  function PreviewStatusBadge({ status }) {
3974
4002
  const IconComp = STATUS_ICON[status];
3975
4003
  const label = APP_STATUS_LABEL[status] ?? status;
3976
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
4004
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
3977
4005
  import_react_native29.View,
3978
4006
  {
3979
4007
  style: {
@@ -3985,15 +4013,15 @@ function PreviewStatusBadge({ status }) {
3985
4013
  backgroundColor: STATUS_BG[status]
3986
4014
  },
3987
4015
  children: [
3988
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(IconComp, { size: 12, color: "#FFFFFF", style: { marginRight: 4 } }),
3989
- /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Text, { style: { color: "#FFFFFF", fontSize: 11, lineHeight: 14 }, children: label })
4016
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(IconComp, { size: 12, color: "#FFFFFF", style: { marginRight: 4 } }),
4017
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(Text, { style: { color: "#FFFFFF", fontSize: 11, lineHeight: 14 }, children: label })
3990
4018
  ]
3991
4019
  }
3992
4020
  );
3993
4021
  }
3994
4022
 
3995
4023
  // src/studio/ui/preview-panel/PreviewHeroSection.tsx
3996
- var import_jsx_runtime30 = require("react/jsx-runtime");
4024
+ var import_jsx_runtime31 = require("react/jsx-runtime");
3997
4025
  function PreviewHeroSection({
3998
4026
  appStatus,
3999
4027
  showProcessing,
@@ -4002,13 +4030,13 @@ function PreviewHeroSection({
4002
4030
  onImageLoad,
4003
4031
  stats
4004
4032
  }) {
4005
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
4033
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
4006
4034
  PreviewHeroCard,
4007
4035
  {
4008
- overlayTopLeft: showProcessing ? /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(PreviewStatusBadge, { status: appStatus }) : null,
4009
- background: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(PreviewPlaceholder, { visible: !imageLoaded }),
4010
- image: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(PreviewImage, { uri: imageUrl, onLoad: onImageLoad }),
4011
- overlayBottom: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
4036
+ overlayTopLeft: showProcessing ? /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(PreviewStatusBadge, { status: appStatus }) : null,
4037
+ background: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(PreviewPlaceholder, { visible: !imageLoaded }),
4038
+ image: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(PreviewImage, { uri: imageUrl, onLoad: onImageLoad }),
4039
+ overlayBottom: /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
4012
4040
  StatsBar,
4013
4041
  {
4014
4042
  likeCount: stats.likeCount,
@@ -4031,7 +4059,7 @@ var import_react_native31 = require("react-native");
4031
4059
 
4032
4060
  // src/components/preview/PreviewMetaRow.tsx
4033
4061
  var import_react_native30 = require("react-native");
4034
- var import_jsx_runtime31 = require("react/jsx-runtime");
4062
+ var import_jsx_runtime32 = require("react/jsx-runtime");
4035
4063
  function PreviewMetaRow({
4036
4064
  avatarUri,
4037
4065
  creatorName,
@@ -4042,11 +4070,11 @@ function PreviewMetaRow({
4042
4070
  style
4043
4071
  }) {
4044
4072
  const theme = useTheme();
4045
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(import_react_native30.View, { style: [{ alignSelf: "stretch" }, style], children: [
4046
- /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(import_react_native30.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
4047
- /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(Avatar, { uri: avatarUri, name: creatorName, size: 24, style: { marginRight: theme.spacing.sm } }),
4048
- /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(import_react_native30.View, { style: { flexDirection: "row", alignItems: "center", flex: 1, minWidth: 0, marginRight: theme.spacing.sm }, children: [
4049
- /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
4073
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(import_react_native30.View, { style: [{ alignSelf: "stretch" }, style], children: [
4074
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(import_react_native30.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
4075
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(Avatar, { uri: avatarUri, name: creatorName, size: 24, style: { marginRight: theme.spacing.sm } }),
4076
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(import_react_native30.View, { style: { flexDirection: "row", alignItems: "center", flex: 1, minWidth: 0, marginRight: theme.spacing.sm }, children: [
4077
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
4050
4078
  Text,
4051
4079
  {
4052
4080
  numberOfLines: 1,
@@ -4060,11 +4088,11 @@ function PreviewMetaRow({
4060
4088
  children: title
4061
4089
  }
4062
4090
  ),
4063
- tag ? /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react_native30.View, { style: { marginLeft: theme.spacing.sm }, children: tag }) : null
4091
+ tag ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_react_native30.View, { style: { marginLeft: theme.spacing.sm }, children: tag }) : null
4064
4092
  ] }),
4065
- rightMetric ? /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_react_native30.View, { children: rightMetric }) : null
4093
+ rightMetric ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_react_native30.View, { children: rightMetric }) : null
4066
4094
  ] }),
4067
- subtitle ? /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
4095
+ subtitle ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
4068
4096
  Text,
4069
4097
  {
4070
4098
  numberOfLines: 2,
@@ -4107,19 +4135,19 @@ function statusDescription(status, statusError) {
4107
4135
  }
4108
4136
 
4109
4137
  // src/studio/ui/preview-panel/PreviewMetaSection.tsx
4110
- var import_jsx_runtime32 = require("react/jsx-runtime");
4138
+ var import_jsx_runtime33 = require("react/jsx-runtime");
4111
4139
  function PreviewMetaSection({ app, isOwner, creator, downloadsCount }) {
4112
4140
  var _a;
4113
4141
  const theme = useTheme();
4114
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
4142
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
4115
4143
  PreviewMetaRow,
4116
4144
  {
4117
4145
  title: app.name,
4118
4146
  subtitle: app.description,
4119
4147
  avatarUri: (creator == null ? void 0 : creator.avatar) ?? null,
4120
4148
  creatorName: (creator == null ? void 0 : creator.name) ?? null,
4121
- tag: isOwner || app.forkedFromAppId ? /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(import_react_native31.View, { style: { paddingHorizontal: 8, paddingVertical: 2, borderRadius: 999, backgroundColor: "#3700B3" }, children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(Text, { variant: "caption", style: { color: "#fff", fontWeight: theme.typography.fontWeight.semibold }, children: app.forkedFromAppId ? "Remix" : "Owner" }) }) : null,
4122
- rightMetric: /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
4149
+ tag: isOwner || app.forkedFromAppId ? /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react_native31.View, { style: { paddingHorizontal: 8, paddingVertical: 2, borderRadius: 999, backgroundColor: "#3700B3" }, children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(Text, { variant: "caption", style: { color: "#fff", fontWeight: theme.typography.fontWeight.semibold }, children: app.forkedFromAppId ? "Remix" : "Owner" }) }) : null,
4150
+ rightMetric: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
4123
4151
  import_react_native31.View,
4124
4152
  {
4125
4153
  style: {
@@ -4131,7 +4159,7 @@ function PreviewMetaSection({ app, isOwner, creator, downloadsCount }) {
4131
4159
  backgroundColor: withAlpha(theme.colors.neutral, 0.3)
4132
4160
  },
4133
4161
  children: [
4134
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
4162
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
4135
4163
  Text,
4136
4164
  {
4137
4165
  style: {
@@ -4144,7 +4172,7 @@ function PreviewMetaSection({ app, isOwner, creator, downloadsCount }) {
4144
4172
  children: formatCount(downloadsCount ?? ((_a = app.insights) == null ? void 0 : _a.totalDownloads) ?? 0)
4145
4173
  }
4146
4174
  ),
4147
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(IconPlay, { size: 14, colorToken: "textMuted", fill: theme.colors.textMuted })
4175
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(IconPlay, { size: 14, colorToken: "textMuted", fill: theme.colors.textMuted })
4148
4176
  ]
4149
4177
  }
4150
4178
  ),
@@ -4158,7 +4186,7 @@ var import_react_native33 = require("react-native");
4158
4186
 
4159
4187
  // src/studio/ui/preview-panel/PressableCardRow.tsx
4160
4188
  var import_react_native32 = require("react-native");
4161
- var import_jsx_runtime33 = require("react/jsx-runtime");
4189
+ var import_jsx_runtime34 = require("react/jsx-runtime");
4162
4190
  function PressableCardRow({
4163
4191
  accessibilityLabel,
4164
4192
  onPress,
@@ -4169,7 +4197,7 @@ function PressableCardRow({
4169
4197
  right,
4170
4198
  style
4171
4199
  }) {
4172
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
4200
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
4173
4201
  import_react_native32.Pressable,
4174
4202
  {
4175
4203
  accessibilityRole: "button",
@@ -4177,23 +4205,23 @@ function PressableCardRow({
4177
4205
  disabled,
4178
4206
  onPress,
4179
4207
  style: ({ pressed }) => ({ opacity: disabled ? 0.6 : pressed ? 0.85 : 1 }),
4180
- children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(Card, { padded: false, border: false, style, children: /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_react_native32.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
4208
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(Card, { padded: false, border: false, style, children: /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(import_react_native32.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
4181
4209
  left,
4182
- /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_react_native32.View, { style: { flex: 1, minWidth: 0 }, children: [
4210
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(import_react_native32.View, { style: { flex: 1, minWidth: 0 }, children: [
4183
4211
  title,
4184
4212
  subtitle ? subtitle : null
4185
4213
  ] }),
4186
- right ? /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(import_react_native32.View, { style: { marginLeft: 16 }, children: right }) : null
4214
+ right ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(import_react_native32.View, { style: { marginLeft: 16 }, children: right }) : null
4187
4215
  ] }) })
4188
4216
  }
4189
4217
  );
4190
4218
  }
4191
4219
 
4192
4220
  // src/studio/ui/preview-panel/SectionTitle.tsx
4193
- var import_jsx_runtime34 = require("react/jsx-runtime");
4221
+ var import_jsx_runtime35 = require("react/jsx-runtime");
4194
4222
  function SectionTitle({ children, marginTop }) {
4195
4223
  const theme = useTheme();
4196
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
4224
+ return /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
4197
4225
  Text,
4198
4226
  {
4199
4227
  style: {
@@ -4212,7 +4240,7 @@ function SectionTitle({ children, marginTop }) {
4212
4240
  }
4213
4241
 
4214
4242
  // src/studio/ui/preview-panel/PreviewCustomizeSection.tsx
4215
- var import_jsx_runtime35 = require("react/jsx-runtime");
4243
+ var import_jsx_runtime36 = require("react/jsx-runtime");
4216
4244
  function PreviewCustomizeSection({
4217
4245
  app,
4218
4246
  isOwner,
@@ -4222,9 +4250,9 @@ function PreviewCustomizeSection({
4222
4250
  onStartDraw
4223
4251
  }) {
4224
4252
  const theme = useTheme();
4225
- return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx_runtime35.Fragment, { children: [
4226
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(SectionTitle, { children: "Customize" }),
4227
- showProcessing ? /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
4253
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(import_jsx_runtime36.Fragment, { children: [
4254
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(SectionTitle, { children: "Customize" }),
4255
+ showProcessing ? /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
4228
4256
  import_react_native33.View,
4229
4257
  {
4230
4258
  style: {
@@ -4238,7 +4266,7 @@ function PreviewCustomizeSection({
4238
4266
  marginBottom: theme.spacing.sm
4239
4267
  },
4240
4268
  children: [
4241
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
4269
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4242
4270
  import_react_native33.View,
4243
4271
  {
4244
4272
  style: {
@@ -4250,17 +4278,17 @@ function PreviewCustomizeSection({
4250
4278
  backgroundColor: withAlpha(theme.colors.warning, 0.1),
4251
4279
  marginRight: theme.spacing.lg
4252
4280
  },
4253
- children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(import_react_native33.ActivityIndicator, { color: theme.colors.warning, size: "small" })
4281
+ children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(import_react_native33.ActivityIndicator, { color: theme.colors.warning, size: "small" })
4254
4282
  }
4255
4283
  ),
4256
- /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_react_native33.View, { style: { flex: 1, minWidth: 0 }, children: [
4257
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: app.status === "error" ? "Error" : "Processing" }),
4258
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: statusDescription(app.status, app.statusError) })
4284
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(import_react_native33.View, { style: { flex: 1, minWidth: 0 }, children: [
4285
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: app.status === "error" ? "Error" : "Processing" }),
4286
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: statusDescription(app.status, app.statusError) })
4259
4287
  ] })
4260
4288
  ]
4261
4289
  }
4262
4290
  ) : null,
4263
- /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
4291
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4264
4292
  PressableCardRow,
4265
4293
  {
4266
4294
  accessibilityLabel: isOwner ? "Edit app" : "Remix app",
@@ -4273,7 +4301,7 @@ function PreviewCustomizeSection({
4273
4301
  borderColor: withAlpha(theme.colors.primary, 0.1),
4274
4302
  marginBottom: theme.spacing.sm
4275
4303
  },
4276
- left: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
4304
+ left: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4277
4305
  import_react_native33.View,
4278
4306
  {
4279
4307
  style: {
@@ -4285,15 +4313,15 @@ function PreviewCustomizeSection({
4285
4313
  backgroundColor: withAlpha(theme.colors.primary, 0.1),
4286
4314
  marginRight: theme.spacing.lg
4287
4315
  },
4288
- children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(IconChat, { size: 20, colorToken: "primary" })
4316
+ children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(IconChat, { size: 20, colorToken: "primary" })
4289
4317
  }
4290
4318
  ),
4291
- title: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: isOwner ? app.forkedFromAppId ? "Edit your Remix" : "Edit Your App" : "Remix App" }),
4292
- subtitle: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: isOwner && app.forkedFromAppId ? "Make changes to your remix with chat" : shouldForkOnEdit ? "Chat to create your own copy and edit it" : "Chat to apply changes" }),
4293
- right: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(IconChevronRight, { size: 20, colorToken: "textMuted" })
4319
+ title: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: isOwner ? app.forkedFromAppId ? "Edit your Remix" : "Edit Your App" : "Remix App" }),
4320
+ subtitle: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: isOwner && app.forkedFromAppId ? "Make changes to your remix with chat" : shouldForkOnEdit ? "Chat to create your own copy and edit it" : "Chat to apply changes" }),
4321
+ right: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(IconChevronRight, { size: 20, colorToken: "textMuted" })
4294
4322
  }
4295
4323
  ),
4296
- isOwner && onStartDraw ? /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
4324
+ isOwner && onStartDraw ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4297
4325
  PressableCardRow,
4298
4326
  {
4299
4327
  accessibilityLabel: "Draw changes",
@@ -4306,7 +4334,7 @@ function PreviewCustomizeSection({
4306
4334
  borderColor: withAlpha(theme.colors.danger, 0.1),
4307
4335
  marginBottom: theme.spacing.sm
4308
4336
  },
4309
- left: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
4337
+ left: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4310
4338
  import_react_native33.View,
4311
4339
  {
4312
4340
  style: {
@@ -4318,12 +4346,12 @@ function PreviewCustomizeSection({
4318
4346
  backgroundColor: withAlpha(theme.colors.danger, 0.1),
4319
4347
  marginRight: theme.spacing.lg
4320
4348
  },
4321
- children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(IconDraw, { size: 20, colorToken: "danger" })
4349
+ children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(IconDraw, { size: 20, colorToken: "danger" })
4322
4350
  }
4323
4351
  ),
4324
- title: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: "Draw Changes" }),
4325
- subtitle: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: "Annotate the app with drawings" }),
4326
- right: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(IconChevronRight, { size: 20, colorToken: "textMuted" })
4352
+ title: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: "Draw Changes" }),
4353
+ subtitle: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: "Annotate the app with drawings" }),
4354
+ right: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(IconChevronRight, { size: 20, colorToken: "textMuted" })
4327
4355
  }
4328
4356
  ) : null
4329
4357
  ] });
@@ -4342,7 +4370,7 @@ var import_lucide_react_native7 = require("lucide-react-native");
4342
4370
  // src/components/primitives/MarkdownText.tsx
4343
4371
  var import_react_native34 = require("react-native");
4344
4372
  var import_react_native_markdown_display = __toESM(require("react-native-markdown-display"));
4345
- var import_jsx_runtime36 = require("react/jsx-runtime");
4373
+ var import_jsx_runtime37 = require("react/jsx-runtime");
4346
4374
  function MarkdownText({ markdown, variant = "chat", bodyColor, style }) {
4347
4375
  const theme = useTheme();
4348
4376
  const isDark = theme.scheme === "dark";
@@ -4353,7 +4381,7 @@ function MarkdownText({ markdown, variant = "chat", bodyColor, style }) {
4353
4381
  const codeTextColor = isDark ? "#FFFFFF" : theme.colors.text;
4354
4382
  const paragraphBottom = variant === "mergeRequest" ? 8 : 6;
4355
4383
  const baseLineHeight = variant === "mergeRequest" ? 22 : 20;
4356
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(import_react_native34.View, { style, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4384
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native34.View, { style, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4357
4385
  import_react_native_markdown_display.default,
4358
4386
  {
4359
4387
  style: {
@@ -4433,7 +4461,7 @@ function useControlledExpansion(props) {
4433
4461
  }
4434
4462
 
4435
4463
  // src/components/merge-requests/MergeRequestStatusCard.tsx
4436
- var import_jsx_runtime37 = require("react/jsx-runtime");
4464
+ var import_jsx_runtime38 = require("react/jsx-runtime");
4437
4465
  function MergeRequestStatusCard({
4438
4466
  mergeRequest,
4439
4467
  expanded: expandedProp,
@@ -4486,7 +4514,7 @@ function MergeRequestStatusCard({
4486
4514
  useNativeDriver: true
4487
4515
  }).start();
4488
4516
  }, [expanded, rotate]);
4489
- return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native35.Pressable, { onPress: () => setExpanded(!expanded), style: ({ pressed }) => [{ opacity: pressed ? 0.95 : 1 }], children: /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
4517
+ return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_react_native35.Pressable, { onPress: () => setExpanded(!expanded), style: ({ pressed }) => [{ opacity: pressed ? 0.95 : 1 }], children: /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
4490
4518
  Card,
4491
4519
  {
4492
4520
  padded: false,
@@ -4499,11 +4527,11 @@ function MergeRequestStatusCard({
4499
4527
  style
4500
4528
  ],
4501
4529
  children: [
4502
- /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_react_native35.View, { style: { flexDirection: "row", alignItems: "center", gap: theme.spacing.lg }, children: [
4503
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native35.View, { style: { width: 40, height: 40, borderRadius: 999, alignItems: "center", justifyContent: "center", backgroundColor: bgColor }, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(StatusIcon, { size: 20, color: iconColor }) }),
4504
- /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_react_native35.View, { style: { flex: 1, minWidth: 0 }, children: [
4505
- /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_react_native35.View, { style: { flexDirection: "row", alignItems: "center", justifyContent: "space-between" }, children: [
4506
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4530
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_react_native35.View, { style: { flexDirection: "row", alignItems: "center", gap: theme.spacing.lg }, children: [
4531
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_react_native35.View, { style: { width: 40, height: 40, borderRadius: 999, alignItems: "center", justifyContent: "center", backgroundColor: bgColor }, children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(StatusIcon, { size: 20, color: iconColor }) }),
4532
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_react_native35.View, { style: { flex: 1, minWidth: 0 }, children: [
4533
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_react_native35.View, { style: { flexDirection: "row", alignItems: "center", justifyContent: "space-between" }, children: [
4534
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
4507
4535
  Text,
4508
4536
  {
4509
4537
  style: {
@@ -4517,11 +4545,11 @@ function MergeRequestStatusCard({
4517
4545
  children: statusText
4518
4546
  }
4519
4547
  ),
4520
- headerTimeAgo ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Text, { style: { fontSize: 10, lineHeight: 14, marginLeft: theme.spacing.sm, color: withAlpha(theme.colors.textMuted, 0.6) }, children: headerTimeAgo }) : null
4548
+ headerTimeAgo ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Text, { style: { fontSize: 10, lineHeight: 14, marginLeft: theme.spacing.sm, color: withAlpha(theme.colors.textMuted, 0.6) }, children: headerTimeAgo }) : null
4521
4549
  ] }),
4522
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Text, { style: { fontSize: 12, lineHeight: 16, color: theme.colors.textMuted }, numberOfLines: 1, children: mergeRequest.title ?? "Untitled merge request" })
4550
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Text, { style: { fontSize: 12, lineHeight: 16, color: theme.colors.textMuted }, numberOfLines: 1, children: mergeRequest.title ?? "Untitled merge request" })
4523
4551
  ] }),
4524
- headerRight ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_react_native35.View, { children: headerRight }) : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4552
+ headerRight ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_react_native35.View, { children: headerRight }) : /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
4525
4553
  import_react_native35.Animated.View,
4526
4554
  {
4527
4555
  style: {
@@ -4531,12 +4559,12 @@ function MergeRequestStatusCard({
4531
4559
  }
4532
4560
  ]
4533
4561
  },
4534
- children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_lucide_react_native7.ChevronDown, { size: 20, color: withAlpha(theme.colors.textMuted, 0.4) })
4562
+ children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_lucide_react_native7.ChevronDown, { size: 20, color: withAlpha(theme.colors.textMuted, 0.4) })
4535
4563
  }
4536
4564
  )
4537
4565
  ] }),
4538
- expanded ? /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(import_react_native35.View, { style: { marginTop: 16, marginLeft: 56 }, children: [
4539
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4566
+ expanded ? /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_react_native35.View, { style: { marginTop: 16, marginLeft: 56 }, children: [
4567
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
4540
4568
  Text,
4541
4569
  {
4542
4570
  style: {
@@ -4550,7 +4578,7 @@ function MergeRequestStatusCard({
4550
4578
  children: status.text
4551
4579
  }
4552
4580
  ),
4553
- createdTimeAgo ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4581
+ createdTimeAgo ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
4554
4582
  Text,
4555
4583
  {
4556
4584
  style: {
@@ -4561,8 +4589,8 @@ function MergeRequestStatusCard({
4561
4589
  children: createdTimeAgo
4562
4590
  }
4563
4591
  ) : null,
4564
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Text, { style: { fontSize: 16, fontWeight: "600", color: textColor, marginBottom: 8 }, children: mergeRequest.title ?? "Untitled merge request" }),
4565
- mergeRequest.description ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(MarkdownText, { markdown: mergeRequest.description, variant: "mergeRequest" }) : null
4592
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(Text, { style: { fontSize: 16, fontWeight: "600", color: textColor, marginBottom: 8 }, children: mergeRequest.title ?? "Untitled merge request" }),
4593
+ mergeRequest.description ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(MarkdownText, { markdown: mergeRequest.description, variant: "mergeRequest" }) : null
4566
4594
  ] }) : null
4567
4595
  ]
4568
4596
  }
@@ -4581,7 +4609,7 @@ var import_lucide_react_native8 = require("lucide-react-native");
4581
4609
  // src/components/merge-requests/ReviewMergeRequestActionButton.tsx
4582
4610
  var React25 = __toESM(require("react"));
4583
4611
  var import_react_native36 = require("react-native");
4584
- var import_jsx_runtime38 = require("react/jsx-runtime");
4612
+ var import_jsx_runtime39 = require("react/jsx-runtime");
4585
4613
  function ReviewMergeRequestActionButton({
4586
4614
  accessibilityLabel,
4587
4615
  backgroundColor,
@@ -4596,7 +4624,7 @@ function ReviewMergeRequestActionButton({
4596
4624
  const paddingHorizontal = iconOnly ? 0 : 16;
4597
4625
  const paddingVertical = iconOnly ? 0 : 8;
4598
4626
  const opacity = disabled ? 0.5 : pressed ? 0.9 : 1;
4599
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
4627
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4600
4628
  import_react_native36.View,
4601
4629
  {
4602
4630
  style: {
@@ -4611,7 +4639,7 @@ function ReviewMergeRequestActionButton({
4611
4639
  paddingVertical,
4612
4640
  justifyContent: "center"
4613
4641
  },
4614
- children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
4642
+ children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4615
4643
  import_react_native36.Pressable,
4616
4644
  {
4617
4645
  accessibilityRole: "button",
@@ -4635,7 +4663,7 @@ function ReviewMergeRequestActionButton({
4635
4663
  }
4636
4664
 
4637
4665
  // src/components/merge-requests/ReviewMergeRequestCard.tsx
4638
- var import_jsx_runtime39 = require("react/jsx-runtime");
4666
+ var import_jsx_runtime40 = require("react/jsx-runtime");
4639
4667
  function ReviewMergeRequestCard({
4640
4668
  mr,
4641
4669
  index,
@@ -4659,7 +4687,7 @@ function ReviewMergeRequestCard({
4659
4687
  import_react_native37.Animated.timing(rotate, { toValue: isExpanded ? 1 : 0, duration: 200, useNativeDriver: true }).start();
4660
4688
  }, [isExpanded, rotate]);
4661
4689
  const position = total > 1 ? `${index + 1}/${total}` : "Merge request";
4662
- return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native37.Pressable, { onPress: onToggle, style: ({ pressed }) => ({ opacity: pressed ? 0.95 : 1 }), children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
4690
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native37.Pressable, { onPress: onToggle, style: ({ pressed }) => ({ opacity: pressed ? 0.95 : 1 }), children: /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(
4663
4691
  Card,
4664
4692
  {
4665
4693
  padded: false,
@@ -4672,10 +4700,10 @@ function ReviewMergeRequestCard({
4672
4700
  }
4673
4701
  ],
4674
4702
  children: [
4675
- /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: 12 }, children: [
4676
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Avatar, { size: 40, uri: (creator == null ? void 0 : creator.avatar) ?? null, name: (creator == null ? void 0 : creator.name) ?? void 0 }),
4677
- /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flex: 1, minWidth: 0 }, children: [
4678
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4703
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: 12 }, children: [
4704
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Avatar, { size: 40, uri: (creator == null ? void 0 : creator.avatar) ?? null, name: (creator == null ? void 0 : creator.name) ?? void 0 }),
4705
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flex: 1, minWidth: 0 }, children: [
4706
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4679
4707
  Text,
4680
4708
  {
4681
4709
  style: { fontWeight: theme.typography.fontWeight.semibold, color: theme.colors.text, fontSize: 16, lineHeight: 20 },
@@ -4683,24 +4711,24 @@ function ReviewMergeRequestCard({
4683
4711
  children: mr.title ?? "Untitled merge request"
4684
4712
  }
4685
4713
  ),
4686
- /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16 }, numberOfLines: 1, children: [
4714
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16 }, numberOfLines: 1, children: [
4687
4715
  (creator == null ? void 0 : creator.name) ?? "Loading...",
4688
4716
  " \xB7 ",
4689
4717
  position
4690
4718
  ] })
4691
4719
  ] }),
4692
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4720
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4693
4721
  import_react_native37.Animated.View,
4694
4722
  {
4695
4723
  style: {
4696
4724
  transform: [{ rotate: rotate.interpolate({ inputRange: [0, 1], outputRange: ["0deg", "180deg"] }) }]
4697
4725
  },
4698
- children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react_native8.ChevronDown, { size: 20, color: withAlpha(theme.colors.textMuted, 0.4) })
4726
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react_native8.ChevronDown, { size: 20, color: withAlpha(theme.colors.textMuted, 0.4) })
4699
4727
  }
4700
4728
  )
4701
4729
  ] }),
4702
- isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { marginTop: 16 }, children: [
4703
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4730
+ isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { marginTop: 16 }, children: [
4731
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4704
4732
  Text,
4705
4733
  {
4706
4734
  style: {
@@ -4714,13 +4742,13 @@ function ReviewMergeRequestCard({
4714
4742
  children: status.text
4715
4743
  }
4716
4744
  ),
4717
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginBottom: 12 }, children: creator ? `${creator.approvedOpenedMergeRequests} approved merge${creator.approvedOpenedMergeRequests !== 1 ? "s" : ""}` : "Loading stats..." }),
4718
- mr.description ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(MarkdownText, { markdown: mr.description, variant: "mergeRequest" }) : null
4745
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginBottom: 12 }, children: creator ? `${creator.approvedOpenedMergeRequests} approved merge${creator.approvedOpenedMergeRequests !== 1 ? "s" : ""}` : "Loading stats..." }),
4746
+ mr.description ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(MarkdownText, { markdown: mr.description, variant: "mergeRequest" }) : null
4719
4747
  ] }) : null,
4720
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native37.View, { style: { height: 1, backgroundColor: withAlpha(theme.colors.borderStrong, 0.5), marginTop: 12, marginBottom: 12 } }),
4721
- /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", justifyContent: "space-between" }, children: [
4722
- /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flexDirection: "row", gap: 8 }, children: [
4723
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4748
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native37.View, { style: { height: 1, backgroundColor: withAlpha(theme.colors.borderStrong, 0.5), marginTop: 12, marginBottom: 12 } }),
4749
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", justifyContent: "space-between" }, children: [
4750
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flexDirection: "row", gap: 8 }, children: [
4751
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4724
4752
  ReviewMergeRequestActionButton,
4725
4753
  {
4726
4754
  accessibilityLabel: "Reject",
@@ -4728,13 +4756,13 @@ function ReviewMergeRequestCard({
4728
4756
  disabled: !canAct || isAnyProcessing,
4729
4757
  onPress: onReject,
4730
4758
  iconOnly: !isExpanded,
4731
- children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4732
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react_native8.X, { size: 18, color: "#FFFFFF" }),
4733
- isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Text, { style: { fontSize: 13, color: "#FFFFFF", fontWeight: theme.typography.fontWeight.semibold }, children: "Reject" }) : null
4759
+ children: /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4760
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react_native8.X, { size: 18, color: "#FFFFFF" }),
4761
+ isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Text, { style: { fontSize: 13, color: "#FFFFFF", fontWeight: theme.typography.fontWeight.semibold }, children: "Reject" }) : null
4734
4762
  ] })
4735
4763
  }
4736
4764
  ),
4737
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4765
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4738
4766
  ReviewMergeRequestActionButton,
4739
4767
  {
4740
4768
  accessibilityLabel: !canAct ? "Not actionable" : isProcessing ? "Processing" : "Approve",
@@ -4742,17 +4770,17 @@ function ReviewMergeRequestCard({
4742
4770
  disabled: !canAct || isAnyProcessing,
4743
4771
  onPress: onApprove,
4744
4772
  iconOnly: !isExpanded,
4745
- children: isProcessing ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4746
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native37.ActivityIndicator, { size: "small", color: "#FFFFFF" }),
4747
- isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Text, { style: { fontSize: 13, color: "#FFFFFF", fontWeight: theme.typography.fontWeight.semibold }, children: "Processing" }) : null
4748
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4749
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react_native8.Check, { size: 18, color: "#FFFFFF" }),
4750
- isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Text, { style: { fontSize: 13, color: "#FFFFFF", fontWeight: theme.typography.fontWeight.semibold }, children: "Approve" }) : null
4773
+ children: isProcessing ? /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4774
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native37.ActivityIndicator, { size: "small", color: "#FFFFFF" }),
4775
+ isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Text, { style: { fontSize: 13, color: "#FFFFFF", fontWeight: theme.typography.fontWeight.semibold }, children: "Processing" }) : null
4776
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4777
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react_native8.Check, { size: 18, color: "#FFFFFF" }),
4778
+ isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Text, { style: { fontSize: 13, color: "#FFFFFF", fontWeight: theme.typography.fontWeight.semibold }, children: "Approve" }) : null
4751
4779
  ] })
4752
4780
  }
4753
4781
  )
4754
4782
  ] }),
4755
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
4783
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4756
4784
  ReviewMergeRequestActionButton,
4757
4785
  {
4758
4786
  accessibilityLabel: "Test",
@@ -4760,9 +4788,9 @@ function ReviewMergeRequestCard({
4760
4788
  disabled: isBuilding || isTestingThis,
4761
4789
  onPress: onTest,
4762
4790
  iconOnly: !isExpanded,
4763
- children: isTestingThis ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_react_native37.ActivityIndicator, { size: "small", color: "#888" }) : /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4764
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(import_lucide_react_native8.Play, { size: 14, color: theme.colors.text }),
4765
- isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(Text, { style: { fontSize: 13, color: theme.colors.text, fontWeight: theme.typography.fontWeight.semibold }, children: "Test" }) : null
4791
+ children: isTestingThis ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native37.ActivityIndicator, { size: "small", color: "#888" }) : /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native37.View, { style: { flexDirection: "row", alignItems: "center", gap: isExpanded ? 4 : 0 }, children: [
4792
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_lucide_react_native8.Play, { size: 14, color: theme.colors.text }),
4793
+ isExpanded ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(Text, { style: { fontSize: 13, color: theme.colors.text, fontWeight: theme.typography.fontWeight.semibold }, children: "Test" }) : null
4766
4794
  ] })
4767
4795
  }
4768
4796
  )
@@ -4773,7 +4801,7 @@ function ReviewMergeRequestCard({
4773
4801
  }
4774
4802
 
4775
4803
  // src/components/merge-requests/ReviewMergeRequestCarousel.tsx
4776
- var import_jsx_runtime40 = require("react/jsx-runtime");
4804
+ var import_jsx_runtime41 = require("react/jsx-runtime");
4777
4805
  function ReviewMergeRequestCarousel({
4778
4806
  mergeRequests,
4779
4807
  creatorStatsById,
@@ -4795,8 +4823,8 @@ function ReviewMergeRequestCarousel({
4795
4823
  const snapInterval = cardWidth + gap;
4796
4824
  const dotColor = theme.scheme === "dark" ? "#FFFFFF" : "#000000";
4797
4825
  if (mergeRequests.length === 0) return null;
4798
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_react_native38.View, { style: [{ marginHorizontal: -theme.spacing.lg }, style], children: [
4799
- /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4826
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(import_react_native38.View, { style: [{ marginHorizontal: -theme.spacing.lg }, style], children: [
4827
+ /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4800
4828
  import_react_native38.FlatList,
4801
4829
  {
4802
4830
  horizontal: true,
@@ -4804,13 +4832,13 @@ function ReviewMergeRequestCarousel({
4804
4832
  keyExtractor: (mr) => mr.id,
4805
4833
  showsHorizontalScrollIndicator: false,
4806
4834
  contentContainerStyle: { paddingHorizontal: theme.spacing.lg, paddingVertical: theme.spacing.sm },
4807
- ItemSeparatorComponent: () => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native38.View, { style: { width: gap } }),
4835
+ ItemSeparatorComponent: () => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_react_native38.View, { style: { width: gap } }),
4808
4836
  snapToAlignment: "start",
4809
4837
  decelerationRate: "fast",
4810
4838
  snapToInterval: snapInterval,
4811
4839
  disableIntervalMomentum: true,
4812
4840
  style: { paddingRight: peekAmount },
4813
- ListFooterComponent: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native38.View, { style: { width: peekAmount } }),
4841
+ ListFooterComponent: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_react_native38.View, { style: { width: peekAmount } }),
4814
4842
  onScroll: import_react_native38.Animated.event([{ nativeEvent: { contentOffset: { x: carouselScrollX } } }], {
4815
4843
  useNativeDriver: false
4816
4844
  }),
@@ -4822,7 +4850,7 @@ function ReviewMergeRequestCarousel({
4822
4850
  const isProcessing = Boolean(processingMrId && processingMrId === item.id);
4823
4851
  const isAnyProcessing = Boolean(processingMrId);
4824
4852
  const isTestingThis = Boolean(testingMrId && testingMrId === item.id);
4825
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native38.View, { style: { width: cardWidth }, children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4853
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_react_native38.View, { style: { width: cardWidth }, children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4826
4854
  ReviewMergeRequestCard,
4827
4855
  {
4828
4856
  mr: item,
@@ -4843,7 +4871,7 @@ function ReviewMergeRequestCarousel({
4843
4871
  }
4844
4872
  }
4845
4873
  ),
4846
- mergeRequests.length >= 1 ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_react_native38.View, { style: { flexDirection: "row", justifyContent: "center", columnGap: 8, marginTop: theme.spacing.md }, children: mergeRequests.map((mr, index) => {
4874
+ mergeRequests.length >= 1 ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_react_native38.View, { style: { flexDirection: "row", justifyContent: "center", columnGap: 8, marginTop: theme.spacing.md }, children: mergeRequests.map((mr, index) => {
4847
4875
  const inputRange = [(index - 1) * snapInterval, index * snapInterval, (index + 1) * snapInterval];
4848
4876
  const scale = carouselScrollX.interpolate({
4849
4877
  inputRange,
@@ -4855,7 +4883,7 @@ function ReviewMergeRequestCarousel({
4855
4883
  outputRange: [0.4, 1, 0.4],
4856
4884
  extrapolate: "clamp"
4857
4885
  });
4858
- return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
4886
+ return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4859
4887
  import_react_native38.Animated.View,
4860
4888
  {
4861
4889
  style: {
@@ -4874,7 +4902,7 @@ function ReviewMergeRequestCarousel({
4874
4902
  }
4875
4903
 
4876
4904
  // src/studio/ui/preview-panel/PreviewCollaborateSection.tsx
4877
- var import_jsx_runtime41 = require("react/jsx-runtime");
4905
+ var import_jsx_runtime42 = require("react/jsx-runtime");
4878
4906
  function PreviewCollaborateSection({
4879
4907
  canSubmitMergeRequest,
4880
4908
  incomingMergeRequests,
@@ -4894,9 +4922,9 @@ function PreviewCollaborateSection({
4894
4922
  const hasSection = canSubmitMergeRequest || incomingMergeRequests.length > 0 || outgoingMergeRequests.length > 0;
4895
4923
  if (!hasSection) return null;
4896
4924
  const showActionsSubtitle = canSubmitMergeRequest && onSubmitMergeRequest || onTestMr && incomingMergeRequests.length > 0;
4897
- return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(import_jsx_runtime41.Fragment, { children: [
4898
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(SectionTitle, { marginTop: theme.spacing.xl, children: "Collaborate" }),
4899
- showActionsSubtitle ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4925
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
4926
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(SectionTitle, { marginTop: theme.spacing.xl, children: "Collaborate" }),
4927
+ showActionsSubtitle ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
4900
4928
  Text,
4901
4929
  {
4902
4930
  style: {
@@ -4911,7 +4939,7 @@ function PreviewCollaborateSection({
4911
4939
  children: "Actions"
4912
4940
  }
4913
4941
  ) : null,
4914
- canSubmitMergeRequest && onSubmitMergeRequest ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4942
+ canSubmitMergeRequest && onSubmitMergeRequest ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
4915
4943
  PressableCardRow,
4916
4944
  {
4917
4945
  accessibilityLabel: "Submit merge request",
@@ -4942,7 +4970,7 @@ function PreviewCollaborateSection({
4942
4970
  borderColor: withAlpha("#03DAC6", 0.2),
4943
4971
  marginBottom: theme.spacing.sm
4944
4972
  },
4945
- left: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4973
+ left: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
4946
4974
  import_react_native39.View,
4947
4975
  {
4948
4976
  style: {
@@ -4954,15 +4982,15 @@ function PreviewCollaborateSection({
4954
4982
  backgroundColor: withAlpha("#03DAC6", 0.1),
4955
4983
  marginRight: theme.spacing.lg
4956
4984
  },
4957
- children: submittingMr ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_react_native39.ActivityIndicator, { color: "#03DAC6", size: "small" }) : /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(merge_default, { width: 20, height: 20, color: "#03DAC6" })
4985
+ children: submittingMr ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_native39.ActivityIndicator, { color: "#03DAC6", size: "small" }) : /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(MergeIcon, { width: 20, height: 20, color: "#03DAC6" })
4958
4986
  }
4959
4987
  ),
4960
- title: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: "Submit your new changes" }),
4961
- subtitle: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: "Ask to merge this remix to the original app" }),
4962
- right: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_lucide_react_native9.Send, { size: 16, color: "#03DAC6" })
4988
+ title: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(Text, { style: { color: theme.colors.text, fontSize: 16, lineHeight: 20, fontWeight: theme.typography.fontWeight.semibold }, children: "Submit your new changes" }),
4989
+ subtitle: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(Text, { style: { color: theme.colors.textMuted, fontSize: 12, lineHeight: 16, marginTop: 2 }, children: "Ask to merge this remix to the original app" }),
4990
+ right: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_lucide_react_native9.Send, { size: 16, color: "#03DAC6" })
4963
4991
  }
4964
4992
  ) : null,
4965
- onTestMr && incomingMergeRequests.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
4993
+ onTestMr && incomingMergeRequests.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
4966
4994
  ReviewMergeRequestCarousel,
4967
4995
  {
4968
4996
  mergeRequests: incomingMergeRequests,
@@ -4975,8 +5003,8 @@ function PreviewCollaborateSection({
4975
5003
  onTest: (mr) => onTestMr ? onTestMr(mr) : void 0
4976
5004
  }
4977
5005
  ) : null,
4978
- outgoingMergeRequests.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(import_jsx_runtime41.Fragment, { children: [
4979
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
5006
+ outgoingMergeRequests.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_jsx_runtime42.Fragment, { children: [
5007
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
4980
5008
  Text,
4981
5009
  {
4982
5010
  style: {
@@ -4992,7 +5020,7 @@ function PreviewCollaborateSection({
4992
5020
  children: "History"
4993
5021
  }
4994
5022
  ),
4995
- outgoingMergeRequests.map((mr) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_react_native39.View, { style: { marginBottom: theme.spacing.sm }, children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(MergeRequestStatusCard, { mergeRequest: toMergeRequestSummary(mr) }) }, mr.id))
5023
+ outgoingMergeRequests.map((mr) => /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_native39.View, { style: { marginBottom: theme.spacing.sm }, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(MergeRequestStatusCard, { mergeRequest: toMergeRequestSummary(mr) }) }, mr.id))
4996
5024
  ] }) : null
4997
5025
  ] });
4998
5026
  }
@@ -5283,7 +5311,7 @@ function usePreviewPanelData(params) {
5283
5311
  }
5284
5312
 
5285
5313
  // src/studio/ui/PreviewPanel.tsx
5286
- var import_jsx_runtime42 = require("react/jsx-runtime");
5314
+ var import_jsx_runtime43 = require("react/jsx-runtime");
5287
5315
  function PreviewPanel({
5288
5316
  app,
5289
5317
  loading,
@@ -5314,16 +5342,16 @@ function PreviewPanel({
5314
5342
  onOpenComments,
5315
5343
  commentCountOverride
5316
5344
  });
5317
- const header = /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(PreviewPanelHeader, { isOwner, onClose, onNavigateHome, onGoToChat });
5345
+ const header = /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(PreviewPanelHeader, { isOwner, onClose, onNavigateHome, onGoToChat });
5318
5346
  if (loading || !app) {
5319
- return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(PreviewPage, { header, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(import_react_native40.View, { style: { flex: 1, justifyContent: "center", alignItems: "center", padding: 24 }, children: [
5320
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_native40.ActivityIndicator, {}),
5321
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_react_native40.View, { style: { height: 12 } }),
5322
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(Text, { variant: "bodyMuted", children: "Loading app\u2026" })
5347
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(PreviewPage, { header, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_react_native40.View, { style: { flex: 1, justifyContent: "center", alignItems: "center", padding: 24 }, children: [
5348
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native40.ActivityIndicator, {}),
5349
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native40.View, { style: { height: 12 } }),
5350
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(Text, { variant: "bodyMuted", children: "Loading app\u2026" })
5323
5351
  ] }) });
5324
5352
  }
5325
- return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(PreviewPage, { header, children: [
5326
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5353
+ return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(PreviewPage, { header, children: [
5354
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
5327
5355
  PreviewHeroSection,
5328
5356
  {
5329
5357
  appStatus: app.status,
@@ -5341,8 +5369,8 @@ function PreviewPanel({
5341
5369
  }
5342
5370
  }
5343
5371
  ),
5344
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(PreviewMetaSection, { app, isOwner, creator, downloadsCount: insights.downloads }),
5345
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5372
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(PreviewMetaSection, { app, isOwner, creator, downloadsCount: insights.downloads }),
5373
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
5346
5374
  PreviewCustomizeSection,
5347
5375
  {
5348
5376
  app,
@@ -5353,7 +5381,7 @@ function PreviewPanel({
5353
5381
  onStartDraw
5354
5382
  }
5355
5383
  ),
5356
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5384
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
5357
5385
  PreviewCollaborateSection,
5358
5386
  {
5359
5387
  canSubmitMergeRequest,
@@ -5389,7 +5417,7 @@ var import_bottom_sheet5 = require("@gorhom/bottom-sheet");
5389
5417
  // src/components/chat/ChatMessageBubble.tsx
5390
5418
  var import_react_native41 = require("react-native");
5391
5419
  var import_lucide_react_native10 = require("lucide-react-native");
5392
- var import_jsx_runtime43 = require("react/jsx-runtime");
5420
+ var import_jsx_runtime44 = require("react/jsx-runtime");
5393
5421
  function ChatMessageBubble({ message, renderContent, style }) {
5394
5422
  var _a, _b;
5395
5423
  const theme = useTheme();
@@ -5403,7 +5431,7 @@ function ChatMessageBubble({ message, renderContent, style }) {
5403
5431
  const bubbleVariant = isHuman ? "surface" : "surfaceRaised";
5404
5432
  const cornerStyle = isHuman ? { borderTopRightRadius: 0 } : { borderTopLeftRadius: 0 };
5405
5433
  const bodyColor = metaStatus === "success" ? theme.colors.success : metaStatus === "error" ? theme.colors.danger : void 0;
5406
- return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native41.View, { style: [align, style], children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
5434
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_react_native41.View, { style: [align, style], children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
5407
5435
  Surface,
5408
5436
  {
5409
5437
  variant: bubbleVariant,
@@ -5418,10 +5446,10 @@ function ChatMessageBubble({ message, renderContent, style }) {
5418
5446
  },
5419
5447
  cornerStyle
5420
5448
  ],
5421
- children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_react_native41.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
5422
- isMergeCompleted ? /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_lucide_react_native10.CheckCheck, { size: 16, color: theme.colors.success, style: { marginRight: theme.spacing.sm } }) : null,
5423
- isMergeApproved ? /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_lucide_react_native10.GitMerge, { size: 16, color: theme.colors.text, style: { marginRight: theme.spacing.sm } }) : null,
5424
- /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react_native41.View, { style: { flexShrink: 1, minWidth: 0 }, children: renderContent ? renderContent(message) : /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(MarkdownText, { markdown: message.content, variant: "chat", bodyColor }) })
5449
+ children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_react_native41.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
5450
+ isMergeCompleted ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_lucide_react_native10.CheckCheck, { size: 16, color: theme.colors.success, style: { marginRight: theme.spacing.sm } }) : null,
5451
+ isMergeApproved ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_lucide_react_native10.GitMerge, { size: 16, color: theme.colors.text, style: { marginRight: theme.spacing.sm } }) : null,
5452
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_react_native41.View, { style: { flexShrink: 1, minWidth: 0 }, children: renderContent ? renderContent(message) : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(MarkdownText, { markdown: message.content, variant: "chat", bodyColor }) })
5425
5453
  ] })
5426
5454
  }
5427
5455
  ) });
@@ -5430,7 +5458,7 @@ function ChatMessageBubble({ message, renderContent, style }) {
5430
5458
  // src/components/chat/TypingIndicator.tsx
5431
5459
  var React31 = __toESM(require("react"));
5432
5460
  var import_react_native42 = require("react-native");
5433
- var import_jsx_runtime44 = require("react/jsx-runtime");
5461
+ var import_jsx_runtime45 = require("react/jsx-runtime");
5434
5462
  function TypingIndicator({ style }) {
5435
5463
  const theme = useTheme();
5436
5464
  const dotColor = theme.colors.textSubtle;
@@ -5453,7 +5481,7 @@ function TypingIndicator({ style }) {
5453
5481
  loops.forEach((l) => l.stop());
5454
5482
  };
5455
5483
  }, [anims]);
5456
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_react_native42.View, { style: [{ flexDirection: "row", alignItems: "center" }, style], children: anims.map((a, i) => /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
5484
+ return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_react_native42.View, { style: [{ flexDirection: "row", alignItems: "center" }, style], children: anims.map((a, i) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
5457
5485
  import_react_native42.Animated.View,
5458
5486
  {
5459
5487
  style: {
@@ -5471,7 +5499,7 @@ function TypingIndicator({ style }) {
5471
5499
  }
5472
5500
 
5473
5501
  // src/components/chat/ChatMessageList.tsx
5474
- var import_jsx_runtime45 = require("react/jsx-runtime");
5502
+ var import_jsx_runtime46 = require("react/jsx-runtime");
5475
5503
  var ChatMessageList = React32.forwardRef(
5476
5504
  ({
5477
5505
  messages,
@@ -5530,7 +5558,7 @@ var ChatMessageList = React32.forwardRef(
5530
5558
  }
5531
5559
  return void 0;
5532
5560
  }, [showTypingIndicator, scrollToBottom]);
5533
- return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
5561
+ return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
5534
5562
  import_bottom_sheet5.BottomSheetFlatList,
5535
5563
  {
5536
5564
  ref: listRef,
@@ -5547,8 +5575,8 @@ var ChatMessageList = React32.forwardRef(
5547
5575
  },
5548
5576
  contentStyle
5549
5577
  ],
5550
- renderItem: ({ item, index }) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_react_native43.View, { style: { marginTop: index === 0 ? 0 : theme.spacing.sm }, children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(ChatMessageBubble, { message: item, renderContent: renderMessageContent }) }),
5551
- ListFooterComponent: showTypingIndicator ? /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_react_native43.View, { style: { marginTop: theme.spacing.sm, alignSelf: "flex-start", paddingHorizontal: theme.spacing.lg }, children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(TypingIndicator, {}) }) : null,
5578
+ renderItem: ({ item, index }) => /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(import_react_native43.View, { style: { marginTop: index === 0 ? 0 : theme.spacing.sm }, children: /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(ChatMessageBubble, { message: item, renderContent: renderMessageContent }) }),
5579
+ ListFooterComponent: showTypingIndicator ? /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(import_react_native43.View, { style: { marginTop: theme.spacing.sm, alignSelf: "flex-start", paddingHorizontal: theme.spacing.lg }, children: /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(TypingIndicator, {}) }) : null,
5552
5580
  maintainVisibleContentPosition: { minIndexForVisible: 0, autoscrollToTopThreshold: nearBottomThreshold }
5553
5581
  }
5554
5582
  );
@@ -5557,7 +5585,7 @@ var ChatMessageList = React32.forwardRef(
5557
5585
  ChatMessageList.displayName = "ChatMessageList";
5558
5586
 
5559
5587
  // src/components/chat/ChatPage.tsx
5560
- var import_jsx_runtime46 = require("react/jsx-runtime");
5588
+ var import_jsx_runtime47 = require("react/jsx-runtime");
5561
5589
  function ChatPage({
5562
5590
  header,
5563
5591
  messages,
@@ -5572,11 +5600,11 @@ function ChatPage({
5572
5600
  }) {
5573
5601
  const theme = useTheme();
5574
5602
  const [composerHeight, setComposerHeight] = React33.useState(0);
5575
- return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)(import_react_native44.View, { style: [{ flex: 1 }, style], children: [
5576
- header ? /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(import_react_native44.View, { children: header }) : null,
5577
- topBanner ? /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(import_react_native44.View, { style: { paddingHorizontal: theme.spacing.lg, paddingTop: theme.spacing.sm }, children: topBanner }) : null,
5578
- /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)(import_react_native44.View, { style: { flex: 1 }, children: [
5579
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
5603
+ return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(import_react_native44.View, { style: [{ flex: 1 }, style], children: [
5604
+ header ? /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_react_native44.View, { children: header }) : null,
5605
+ topBanner ? /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_react_native44.View, { style: { paddingHorizontal: theme.spacing.lg, paddingTop: theme.spacing.sm }, children: topBanner }) : null,
5606
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(import_react_native44.View, { style: { flex: 1 }, children: [
5607
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
5580
5608
  ChatMessageList,
5581
5609
  {
5582
5610
  ref: listRef,
@@ -5589,7 +5617,7 @@ function ChatPage({
5589
5617
  ),
5590
5618
  overlay
5591
5619
  ] }),
5592
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
5620
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
5593
5621
  ChatComposer,
5594
5622
  {
5595
5623
  ...composer,
@@ -5604,7 +5632,7 @@ function ChatPage({
5604
5632
  var React34 = __toESM(require("react"));
5605
5633
  var import_react_native45 = require("react-native");
5606
5634
  var import_react_native_reanimated2 = __toESM(require("react-native-reanimated"));
5607
- var import_jsx_runtime47 = require("react/jsx-runtime");
5635
+ var import_jsx_runtime48 = require("react/jsx-runtime");
5608
5636
  function ScrollToBottomButton({ visible, onPress, children, style }) {
5609
5637
  const theme = useTheme();
5610
5638
  const progress = (0, import_react_native_reanimated2.useSharedValue)(visible ? 1 : 0);
@@ -5618,7 +5646,7 @@ function ScrollToBottomButton({ visible, onPress, children, style }) {
5618
5646
  }));
5619
5647
  const bg = theme.scheme === "dark" ? "rgba(39,39,42,0.9)" : "rgba(244,244,245,0.95)";
5620
5648
  const border = theme.scheme === "dark" ? withAlpha("#FFFFFF", 0.12) : withAlpha("#000000", 0.08);
5621
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
5649
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
5622
5650
  import_react_native_reanimated2.default.View,
5623
5651
  {
5624
5652
  pointerEvents: visible ? "auto" : "none",
@@ -5632,7 +5660,7 @@ function ScrollToBottomButton({ visible, onPress, children, style }) {
5632
5660
  style,
5633
5661
  animStyle
5634
5662
  ],
5635
- children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
5663
+ children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
5636
5664
  import_react_native45.View,
5637
5665
  {
5638
5666
  style: {
@@ -5651,7 +5679,7 @@ function ScrollToBottomButton({ visible, onPress, children, style }) {
5651
5679
  elevation: 5,
5652
5680
  opacity: pressed ? 0.85 : 1
5653
5681
  },
5654
- children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
5682
+ children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
5655
5683
  import_react_native45.Pressable,
5656
5684
  {
5657
5685
  onPress,
@@ -5670,7 +5698,7 @@ function ScrollToBottomButton({ visible, onPress, children, style }) {
5670
5698
 
5671
5699
  // src/components/chat/ChatHeader.tsx
5672
5700
  var import_react_native46 = require("react-native");
5673
- var import_jsx_runtime48 = require("react/jsx-runtime");
5701
+ var import_jsx_runtime49 = require("react/jsx-runtime");
5674
5702
  function ChatHeader({ left, right, center, style }) {
5675
5703
  const flattenedStyle = import_react_native46.StyleSheet.flatten([
5676
5704
  {
@@ -5678,7 +5706,7 @@ function ChatHeader({ left, right, center, style }) {
5678
5706
  },
5679
5707
  style
5680
5708
  ]);
5681
- return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
5709
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
5682
5710
  StudioSheetHeader,
5683
5711
  {
5684
5712
  left,
@@ -5691,12 +5719,12 @@ function ChatHeader({ left, right, center, style }) {
5691
5719
 
5692
5720
  // src/components/chat/ForkNoticeBanner.tsx
5693
5721
  var import_react_native47 = require("react-native");
5694
- var import_jsx_runtime49 = require("react/jsx-runtime");
5722
+ var import_jsx_runtime50 = require("react/jsx-runtime");
5695
5723
  function ForkNoticeBanner({ isOwner = true, title, description, style }) {
5696
5724
  const theme = useTheme();
5697
5725
  const resolvedTitle = title ?? (isOwner ? "Remixed app" : "Remix app");
5698
5726
  const resolvedDescription = description ?? (isOwner ? "Any changes you make will be a remix of the original app. You can view the edited version in the Remix tab in your apps page." : "Once you make edits, this remixed version will appear on your Remixed apps page.");
5699
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
5727
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
5700
5728
  Card,
5701
5729
  {
5702
5730
  variant: "surfaceRaised",
@@ -5711,8 +5739,8 @@ function ForkNoticeBanner({ isOwner = true, title, description, style }) {
5711
5739
  },
5712
5740
  style
5713
5741
  ],
5714
- children: /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(import_react_native47.View, { style: { minWidth: 0 }, children: [
5715
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
5742
+ children: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_react_native47.View, { style: { minWidth: 0 }, children: [
5743
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
5716
5744
  Text,
5717
5745
  {
5718
5746
  style: {
@@ -5726,7 +5754,7 @@ function ForkNoticeBanner({ isOwner = true, title, description, style }) {
5726
5754
  children: resolvedTitle
5727
5755
  }
5728
5756
  ),
5729
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
5757
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
5730
5758
  Text,
5731
5759
  {
5732
5760
  style: {
@@ -5744,7 +5772,7 @@ function ForkNoticeBanner({ isOwner = true, title, description, style }) {
5744
5772
  }
5745
5773
 
5746
5774
  // src/studio/ui/ChatPanel.tsx
5747
- var import_jsx_runtime50 = require("react/jsx-runtime");
5775
+ var import_jsx_runtime51 = require("react/jsx-runtime");
5748
5776
  function ChatPanel({
5749
5777
  title = "Chat",
5750
5778
  autoFocusComposer = false,
@@ -5782,21 +5810,21 @@ function ChatPanel({
5782
5810
  var _a;
5783
5811
  (_a = listRef.current) == null ? void 0 : _a.scrollToBottom({ animated: true });
5784
5812
  }, []);
5785
- const header = /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
5813
+ const header = /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
5786
5814
  ChatHeader,
5787
5815
  {
5788
- left: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_react_native48.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
5789
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(StudioSheetHeaderIconButton, { onPress: onBack, accessibilityLabel: "Back", style: { marginRight: 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(IconBack, { size: 20, colorToken: "floatingContent" }) }),
5790
- onNavigateHome ? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(StudioSheetHeaderIconButton, { onPress: onNavigateHome, accessibilityLabel: "Home", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(IconHome, { size: 20, colorToken: "floatingContent" }) }) : null
5816
+ left: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_react_native48.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
5817
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(StudioSheetHeaderIconButton, { onPress: onBack, accessibilityLabel: "Back", style: { marginRight: 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(IconBack, { size: 20, colorToken: "floatingContent" }) }),
5818
+ onNavigateHome ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(StudioSheetHeaderIconButton, { onPress: onNavigateHome, accessibilityLabel: "Home", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(IconHome, { size: 20, colorToken: "floatingContent" }) }) : null
5791
5819
  ] }),
5792
- right: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_react_native48.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
5793
- onStartDraw ? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(StudioSheetHeaderIconButton, { onPress: onStartDraw, accessibilityLabel: "Draw", intent: "danger", style: { marginRight: 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(IconDraw, { size: 20, colorToken: "onDanger" }) }) : null,
5794
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(StudioSheetHeaderIconButton, { onPress: onClose, accessibilityLabel: "Close", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(IconClose, { size: 20, colorToken: "floatingContent" }) })
5820
+ right: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_react_native48.View, { style: { flexDirection: "row", alignItems: "center" }, children: [
5821
+ onStartDraw ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(StudioSheetHeaderIconButton, { onPress: onStartDraw, accessibilityLabel: "Draw", intent: "danger", style: { marginRight: 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(IconDraw, { size: 20, colorToken: "onDanger" }) }) : null,
5822
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(StudioSheetHeaderIconButton, { onPress: onClose, accessibilityLabel: "Close", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(IconClose, { size: 20, colorToken: "floatingContent" }) })
5795
5823
  ] }),
5796
5824
  center: null
5797
5825
  }
5798
5826
  );
5799
- const topBanner = shouldForkOnEdit ? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
5827
+ const topBanner = shouldForkOnEdit ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
5800
5828
  ForkNoticeBanner,
5801
5829
  {
5802
5830
  isOwner: !shouldForkOnEdit,
@@ -5805,17 +5833,17 @@ function ChatPanel({
5805
5833
  ) : null;
5806
5834
  const showMessagesLoading = Boolean(loading) && messages.length === 0 || forking;
5807
5835
  if (showMessagesLoading) {
5808
- return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_react_native48.View, { style: { flex: 1 }, children: [
5809
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_react_native48.View, { children: header }),
5810
- topBanner ? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_react_native48.View, { style: { paddingHorizontal: 16, paddingTop: 8 }, children: topBanner }) : null,
5811
- /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_react_native48.View, { style: { flex: 1, alignItems: "center", justifyContent: "center", paddingHorizontal: 24, paddingVertical: 12 }, children: [
5812
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_react_native48.ActivityIndicator, {}),
5813
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(import_react_native48.View, { style: { height: 12 } }),
5814
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(Text, { variant: "bodyMuted", children: forking ? "Creating your copy\u2026" : "Loading messages\u2026" })
5836
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_react_native48.View, { style: { flex: 1 }, children: [
5837
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_react_native48.View, { children: header }),
5838
+ topBanner ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_react_native48.View, { style: { paddingHorizontal: 16, paddingTop: 8 }, children: topBanner }) : null,
5839
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_react_native48.View, { style: { flex: 1, alignItems: "center", justifyContent: "center", paddingHorizontal: 24, paddingVertical: 12 }, children: [
5840
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_react_native48.ActivityIndicator, {}),
5841
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_react_native48.View, { style: { height: 12 } }),
5842
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Text, { variant: "bodyMuted", children: forking ? "Creating your copy\u2026" : "Loading messages\u2026" })
5815
5843
  ] })
5816
5844
  ] });
5817
5845
  }
5818
- return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
5846
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
5819
5847
  ChatPage,
5820
5848
  {
5821
5849
  header,
@@ -5824,13 +5852,13 @@ function ChatPanel({
5824
5852
  topBanner,
5825
5853
  listRef,
5826
5854
  onNearBottomChange: setNearBottom,
5827
- overlay: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
5855
+ overlay: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
5828
5856
  ScrollToBottomButton,
5829
5857
  {
5830
5858
  visible: !nearBottom,
5831
5859
  onPress: handleScrollToBottom,
5832
5860
  style: { bottom: 80 },
5833
- children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(IconArrowDown, { size: 20, colorToken: "floatingContent" })
5861
+ children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(IconArrowDown, { size: 20, colorToken: "floatingContent" })
5834
5862
  }
5835
5863
  ),
5836
5864
  composer: {
@@ -5853,7 +5881,7 @@ var import_react_native50 = require("react-native");
5853
5881
 
5854
5882
  // src/components/primitives/Modal.tsx
5855
5883
  var import_react_native49 = require("react-native");
5856
- var import_jsx_runtime51 = require("react/jsx-runtime");
5884
+ var import_jsx_runtime52 = require("react/jsx-runtime");
5857
5885
  function Modal({
5858
5886
  visible,
5859
5887
  onRequestClose,
@@ -5862,15 +5890,15 @@ function Modal({
5862
5890
  contentStyle
5863
5891
  }) {
5864
5892
  const theme = useTheme();
5865
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
5893
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
5866
5894
  import_react_native49.Modal,
5867
5895
  {
5868
5896
  visible,
5869
5897
  transparent: true,
5870
5898
  animationType: "fade",
5871
5899
  onRequestClose,
5872
- children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_react_native49.View, { style: { flex: 1, backgroundColor: theme.colors.backdrop, justifyContent: "center", padding: theme.spacing.lg }, children: [
5873
- /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
5900
+ children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(import_react_native49.View, { style: { flex: 1, backgroundColor: theme.colors.backdrop, justifyContent: "center", padding: theme.spacing.lg }, children: [
5901
+ /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
5874
5902
  import_react_native49.Pressable,
5875
5903
  {
5876
5904
  accessibilityRole: "button",
@@ -5878,14 +5906,14 @@ function Modal({
5878
5906
  style: { position: "absolute", inset: 0 }
5879
5907
  }
5880
5908
  ),
5881
- /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Card, { variant: "surfaceRaised", padded: true, style: [{ borderRadius: theme.radii.xl }, contentStyle], children })
5909
+ /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(Card, { variant: "surfaceRaised", padded: true, style: [{ borderRadius: theme.radii.xl }, contentStyle], children })
5882
5910
  ] })
5883
5911
  }
5884
5912
  );
5885
5913
  }
5886
5914
 
5887
5915
  // src/components/dialogs/ConfirmMergeRequestDialog.tsx
5888
- var import_jsx_runtime52 = require("react/jsx-runtime");
5916
+ var import_jsx_runtime53 = require("react/jsx-runtime");
5889
5917
  function ConfirmMergeRequestDialog({
5890
5918
  visible,
5891
5919
  onOpenChange,
@@ -5915,7 +5943,7 @@ function ConfirmMergeRequestDialog({
5915
5943
  justifyContent: "center",
5916
5944
  alignSelf: "stretch"
5917
5945
  };
5918
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
5946
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
5919
5947
  Modal,
5920
5948
  {
5921
5949
  visible,
@@ -5926,7 +5954,7 @@ function ConfirmMergeRequestDialog({
5926
5954
  backgroundColor: theme.colors.background
5927
5955
  },
5928
5956
  children: [
5929
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_react_native50.View, { children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
5957
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_react_native50.View, { children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5930
5958
  Text,
5931
5959
  {
5932
5960
  style: {
@@ -5938,8 +5966,8 @@ function ConfirmMergeRequestDialog({
5938
5966
  children: "Are you sure you want to approve this merge request?"
5939
5967
  }
5940
5968
  ) }),
5941
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(import_react_native50.View, { style: { marginTop: 16 }, children: [
5942
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
5969
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_react_native50.View, { style: { marginTop: 16 }, children: [
5970
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5943
5971
  import_react_native50.View,
5944
5972
  {
5945
5973
  style: [
@@ -5949,7 +5977,7 @@ function ConfirmMergeRequestDialog({
5949
5977
  opacity: canConfirm ? 1 : 0.5
5950
5978
  }
5951
5979
  ],
5952
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
5980
+ children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5953
5981
  import_react_native50.Pressable,
5954
5982
  {
5955
5983
  accessibilityRole: "button",
@@ -5957,13 +5985,13 @@ function ConfirmMergeRequestDialog({
5957
5985
  disabled: !canConfirm,
5958
5986
  onPress: handleConfirm,
5959
5987
  style: [fullWidthButtonBase, { flex: 1 }],
5960
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(Text, { style: { textAlign: "center", color: theme.colors.onPrimary }, children: "Approve Merge" })
5988
+ children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(Text, { style: { textAlign: "center", color: theme.colors.onPrimary }, children: "Approve Merge" })
5961
5989
  }
5962
5990
  )
5963
5991
  }
5964
5992
  ),
5965
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_react_native50.View, { style: { height: 8 } }),
5966
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
5993
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_react_native50.View, { style: { height: 8 } }),
5994
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5967
5995
  import_react_native50.View,
5968
5996
  {
5969
5997
  style: [
@@ -5975,7 +6003,7 @@ function ConfirmMergeRequestDialog({
5975
6003
  opacity: isBuilding || !mergeRequest ? 0.5 : 1
5976
6004
  }
5977
6005
  ],
5978
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
6006
+ children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5979
6007
  import_react_native50.Pressable,
5980
6008
  {
5981
6009
  accessibilityRole: "button",
@@ -5983,13 +6011,13 @@ function ConfirmMergeRequestDialog({
5983
6011
  disabled: isBuilding || !mergeRequest,
5984
6012
  onPress: handleTestFirst,
5985
6013
  style: [fullWidthButtonBase, { flex: 1 }],
5986
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(Text, { style: { textAlign: "center", color: theme.colors.text }, children: isBuilding ? "Preparing\u2026" : "Test edits first" })
6014
+ children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(Text, { style: { textAlign: "center", color: theme.colors.text }, children: isBuilding ? "Preparing\u2026" : "Test edits first" })
5987
6015
  }
5988
6016
  )
5989
6017
  }
5990
6018
  ),
5991
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_react_native50.View, { style: { height: 8 } }),
5992
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
6019
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_react_native50.View, { style: { height: 8 } }),
6020
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5993
6021
  import_react_native50.View,
5994
6022
  {
5995
6023
  style: [
@@ -6000,14 +6028,14 @@ function ConfirmMergeRequestDialog({
6000
6028
  borderColor: theme.colors.border
6001
6029
  }
6002
6030
  ],
6003
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
6031
+ children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
6004
6032
  import_react_native50.Pressable,
6005
6033
  {
6006
6034
  accessibilityRole: "button",
6007
6035
  accessibilityLabel: "Cancel",
6008
6036
  onPress: close,
6009
6037
  style: [fullWidthButtonBase, { flex: 1 }],
6010
- children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(Text, { style: { textAlign: "center", color: theme.colors.text }, children: "Cancel" })
6038
+ children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(Text, { style: { textAlign: "center", color: theme.colors.text }, children: "Cancel" })
6011
6039
  }
6012
6040
  )
6013
6041
  }
@@ -6019,7 +6047,7 @@ function ConfirmMergeRequestDialog({
6019
6047
  }
6020
6048
 
6021
6049
  // src/studio/ui/ConfirmMergeFlow.tsx
6022
- var import_jsx_runtime53 = require("react/jsx-runtime");
6050
+ var import_jsx_runtime54 = require("react/jsx-runtime");
6023
6051
  function ConfirmMergeFlow({
6024
6052
  visible,
6025
6053
  onOpenChange,
@@ -6030,7 +6058,7 @@ function ConfirmMergeFlow({
6030
6058
  onConfirm,
6031
6059
  onTestFirst
6032
6060
  }) {
6033
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
6061
+ return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6034
6062
  ConfirmMergeRequestDialog,
6035
6063
  {
6036
6064
  visible,
@@ -6052,7 +6080,7 @@ function ConfirmMergeFlow({
6052
6080
  }
6053
6081
 
6054
6082
  // src/studio/ui/StudioOverlay.tsx
6055
- var import_jsx_runtime54 = require("react/jsx-runtime");
6083
+ var import_jsx_runtime55 = require("react/jsx-runtime");
6056
6084
  function StudioOverlay({
6057
6085
  captureTargetRef,
6058
6086
  app,
@@ -6140,14 +6168,14 @@ function StudioOverlay({
6140
6168
  },
6141
6169
  [closeSheet, onTestMr]
6142
6170
  );
6143
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [
6144
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(EdgeGlowFrame, { visible: isTesting, role: "accent", thickness: 40, intensity: 1 }),
6145
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(StudioBottomSheet, { open: sheetOpen, onOpenChange: setSheetOpen, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6171
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_jsx_runtime55.Fragment, { children: [
6172
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(EdgeGlowFrame, { visible: isTesting, role: "accent", thickness: 40, intensity: 1 }),
6173
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(StudioBottomSheet, { open: sheetOpen, onOpenChange: setSheetOpen, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6146
6174
  StudioSheetPager,
6147
6175
  {
6148
6176
  activePage,
6149
6177
  width,
6150
- preview: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6178
+ preview: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6151
6179
  PreviewPanel,
6152
6180
  {
6153
6181
  app,
@@ -6173,7 +6201,7 @@ function StudioOverlay({
6173
6201
  commentCountOverride: commentsCount ?? void 0
6174
6202
  }
6175
6203
  ),
6176
- chat: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6204
+ chat: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6177
6205
  ChatPanel,
6178
6206
  {
6179
6207
  messages: chatMessages,
@@ -6196,7 +6224,7 @@ function StudioOverlay({
6196
6224
  )
6197
6225
  }
6198
6226
  ) }),
6199
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6227
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6200
6228
  FloatingDraggableButton,
6201
6229
  {
6202
6230
  visible: !sheetOpen && !drawing,
@@ -6204,10 +6232,10 @@ function StudioOverlay({
6204
6232
  badgeCount: incomingMergeRequests.length,
6205
6233
  onPress: toggleSheet,
6206
6234
  isLoading: (app == null ? void 0 : app.status) === "editing",
6207
- children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react_native51.View, { style: { width: 28, height: 28, alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(merge_default, { width: 24, height: 24, color: theme.colors.floatingContent }) })
6235
+ children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_react_native51.View, { style: { width: 28, height: 28, alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(MergeIcon, { width: 24, height: 24, color: theme.colors.floatingContent }) })
6208
6236
  }
6209
6237
  ),
6210
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6238
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6211
6239
  DrawModeOverlay,
6212
6240
  {
6213
6241
  visible: drawing,
@@ -6216,7 +6244,7 @@ function StudioOverlay({
6216
6244
  onCapture: handleDrawCapture
6217
6245
  }
6218
6246
  ),
6219
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6247
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6220
6248
  ConfirmMergeFlow,
6221
6249
  {
6222
6250
  visible: Boolean(confirmMr),
@@ -6229,7 +6257,7 @@ function StudioOverlay({
6229
6257
  onTestFirst: handleTestMr
6230
6258
  }
6231
6259
  ),
6232
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
6260
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6233
6261
  AppCommentsSheet,
6234
6262
  {
6235
6263
  appId: commentsAppId,
@@ -6242,9 +6270,10 @@ function StudioOverlay({
6242
6270
  }
6243
6271
 
6244
6272
  // src/studio/ComergeStudio.tsx
6245
- var import_jsx_runtime55 = require("react/jsx-runtime");
6273
+ var import_jsx_runtime56 = require("react/jsx-runtime");
6246
6274
  function ComergeStudio({
6247
6275
  appId,
6276
+ apiKey,
6248
6277
  appKey = "MicroMain",
6249
6278
  onNavigateHome,
6250
6279
  style
@@ -6259,7 +6288,7 @@ function ComergeStudio({
6259
6288
  setPendingRuntimeTargetAppId(null);
6260
6289
  }, [appId]);
6261
6290
  const captureTargetRef = React38.useRef(null);
6262
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(StudioBootstrap, { children: ({ userId }) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_bottom_sheet6.BottomSheetModalProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6291
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(StudioBootstrap, { apiKey, children: ({ userId }) => /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_bottom_sheet6.BottomSheetModalProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
6263
6292
  ComergeStudioInner,
6264
6293
  {
6265
6294
  userId,
@@ -6352,9 +6381,9 @@ function ComergeStudioInner({
6352
6381
  const payloadType = typeof ((_a = last.payload) == null ? void 0 : _a.type) === "string" ? String(last.payload.type) : void 0;
6353
6382
  return payloadType !== "outcome";
6354
6383
  }, [thread.raw]);
6355
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_react_native52.View, { style: [{ flex: 1 }, style], children: /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_react_native52.View, { ref: captureTargetRef, style: { flex: 1 }, collapsable: false, children: [
6356
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(RuntimeRenderer, { appKey, bundlePath: bundle.bundlePath, renderToken: bundle.renderToken }),
6357
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
6384
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_react_native52.View, { style: [{ flex: 1 }, style], children: /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_react_native52.View, { ref: captureTargetRef, style: { flex: 1 }, collapsable: false, children: [
6385
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(RuntimeRenderer, { appKey, bundlePath: bundle.bundlePath, renderToken: bundle.renderToken }),
6386
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
6358
6387
  StudioOverlay,
6359
6388
  {
6360
6389
  captureTargetRef,