@vvedantb/native-ui 0.37.2 → 0.39.0
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.
- package/README.md +8 -7
- package/dist/Avatar.jsx +22 -19
- package/dist/BottomSheetContainer.jsx +0 -6
- package/dist/BulkActionBar.jsx +0 -24
- package/dist/Button.jsx +92 -116
- package/dist/Card.jsx +56 -50
- package/dist/ColorSwatches.jsx +0 -6
- package/dist/Dialog.jsx +0 -12
- package/dist/DropdownMenu.jsx +0 -10
- package/dist/EmptyState.jsx +0 -3
- package/dist/ExpoWebRoot.jsx +0 -6
- package/dist/Field.jsx +0 -17
- package/dist/FloatingSurface.jsx +95 -80
- package/dist/FloatingTabBar.jsx +0 -23
- package/dist/IconButton.jsx +0 -1
- package/dist/LoadingState.jsx +0 -6
- package/dist/PasswordInput.jsx +0 -15
- package/dist/PillTabs.jsx +39 -36
- package/dist/SearchInput.jsx +0 -13
- package/dist/SectionLabel.jsx +0 -1
- package/dist/SharedTransition.jsx +0 -3
- package/dist/Skeleton.jsx +0 -2
- package/dist/Spinner.jsx +0 -2
- package/dist/StatusDot.jsx +0 -5
- package/dist/Switch.jsx +32 -22
- package/dist/Tabs.jsx +27 -26
- package/dist/Textarea.jsx +0 -1
- package/dist/ThemeToggle.jsx +0 -1
- package/dist/Toast.jsx +80 -91
- package/dist/UpdateChecker.jsx +0 -1
- package/dist/ai/activity-question.jsx +0 -6
- package/dist/ai/activity-step-label.js +0 -6
- package/dist/ai/activity-step-types.js +0 -4
- package/dist/ai/activity-tasks-utils.js +0 -17
- package/dist/ai/activity-timeline.js +0 -8
- package/dist/ai/attachments.jsx +0 -2
- package/dist/ai/chain-of-thought.jsx +0 -3
- package/dist/ai/chat-text.js +0 -1
- package/dist/ai/chat-thread.jsx +0 -1
- package/dist/ai/choice-question.jsx +0 -10
- package/dist/ai/code-block.jsx +0 -31
- package/dist/ai/collapsible.jsx +0 -14
- package/dist/ai/conversation-context.js +0 -3
- package/dist/ai/conversation.jsx +2 -48
- package/dist/ai/file-chip.jsx +0 -2
- package/dist/ai/icon-button.jsx +0 -8
- package/dist/ai/index.js +0 -5
- package/dist/ai/message-context-menu.jsx +0 -7
- package/dist/ai/message.jsx +0 -21
- package/dist/ai/prompt-input-menu.jsx +0 -3
- package/dist/ai/prompt-input.jsx +0 -27
- package/dist/ai/response-text.jsx +0 -6
- package/dist/ai/sources.jsx +0 -1
- package/dist/ai/suggestion.jsx +0 -1
- package/dist/ai/trace.jsx +0 -11
- package/dist/ai/unified-diff.jsx +0 -4
- package/dist/app-root/AuthGroupGate.jsx +65 -0
- package/dist/app-root/SsoCallbackScreen.jsx +97 -0
- package/dist/app-root/fonts.js +88 -0
- package/dist/app-root/index.js +3 -0
- package/dist/auth/AuthScreen.jsx +250 -77
- package/dist/auth/GoogleSignInButton.jsx +0 -3
- package/dist/auth/SecondFactorScreen.jsx +18 -14
- package/dist/auth/SignInScreen.jsx +40 -34
- package/dist/auth/authErrors.js +0 -4
- package/dist/auth/clerkCore3.js +0 -7
- package/dist/auth/index.js +0 -4
- package/dist/auth/totp.js +0 -2
- package/dist/brand/GoogleMark.jsx +0 -1
- package/dist/brand/ProviderIcon.jsx +0 -2
- package/dist/brand/index.js +0 -3
- package/dist/brand/svg.js +0 -6
- package/dist/configureTheme.js +0 -9
- package/dist/controlStyles.js +0 -14
- package/dist/crash/LastCrashDialog.jsx +56 -0
- package/dist/crash/lastCrash.js +192 -0
- package/dist/entries/ai.js +0 -3
- package/dist/entries/ambient.js +0 -2
- package/dist/entries/app-root.js +1 -0
- package/dist/entries/auth.js +0 -4
- package/dist/entries/bottom-sheet.js +0 -2
- package/dist/entries/brand.js +0 -1
- package/dist/entries/button.js +0 -1
- package/dist/entries/crash.js +2 -0
- package/dist/entries/date-time.js +0 -2
- package/dist/entries/expo-router.js +0 -3
- package/dist/entries/expo-web-root.js +0 -2
- package/dist/entries/floating.js +0 -2
- package/dist/entries/generative-ui.js +0 -4
- package/dist/entries/gesture-handler.js +0 -3
- package/dist/entries/keyboard-controller.js +0 -3
- package/dist/entries/layout.js +0 -2
- package/dist/entries/markdown.js +0 -3
- package/dist/entries/marketing.js +0 -1
- package/dist/entries/page-title.js +0 -5
- package/dist/entries/password-input.js +0 -2
- package/dist/entries/paste-input.js +0 -3
- package/dist/entries/primitives.js +0 -6
- package/dist/entries/search-input.js +0 -2
- package/dist/entries/tab-bar.js +0 -2
- package/dist/entries/theme.js +4 -2
- package/dist/entries/toast.js +0 -3
- package/dist/entries/video.js +0 -2
- package/dist/entries/webview.js +0 -2
- package/dist/examples/AiChatGallery.jsx +0 -11
- package/dist/examples/ParityGallery.jsx +0 -12
- package/dist/floating.js +0 -8
- package/dist/generative-ui/GenerativeUiPanel.jsx +0 -2
- package/dist/generative-ui/components.jsx +0 -8
- package/dist/glass.js +55 -0
- package/dist/glassBlur.jsx +0 -12
- package/dist/highlight.js +0 -26
- package/dist/index.js +4 -2
- package/dist/loadingGrid.js +0 -13
- package/dist/markdown/Markdown.jsx +0 -59
- package/dist/markdown/MarkdownTable.jsx +0 -18
- package/dist/markdown/tableText.js +0 -5
- package/dist/marketing/UpgradeToProCard.jsx +0 -5
- package/dist/marketing/pricing.js +0 -3
- package/dist/media/ImageGallery.jsx +0 -16
- package/dist/media/imageZoom.js +0 -4
- package/dist/media/zoom-image-gesture.jsx +0 -8
- package/dist/media/zoomImage.js +0 -3
- package/dist/motion.js +0 -3
- package/dist/neutralTheme.js +158 -0
- package/dist/pagerSwipe.js +0 -16
- package/dist/palette.js +0 -10
- package/dist/primitives/button.jsx +0 -5
- package/dist/primitives/icon.jsx +0 -4
- package/dist/primitives/keyboard-controller.jsx +0 -27
- package/dist/primitives/native-only-animated-view.jsx +0 -5
- package/dist/primitives/overlay.jsx +0 -2
- package/dist/primitives/pager-gesture.jsx +3 -29
- package/dist/primitives/paste-input.jsx +0 -5
- package/dist/primitives/select.jsx +0 -10
- package/dist/primitives/sheet-drag.jsx +0 -3
- package/dist/primitives/sheet-gesture.jsx +0 -8
- package/dist/primitives/swipe-row-gesture.jsx +3 -45
- package/dist/primitives/text.jsx +0 -5
- package/dist/primitives/toast-drag-gesture.jsx +4 -24
- package/dist/primitives/web-click-guard.js +0 -3
- package/dist/primitives/window-layer.jsx +0 -14
- package/dist/push.js +0 -6
- package/dist/relativeTime.js +0 -13
- package/dist/settings/MoreFromProjectV.jsx +0 -5
- package/dist/settings/ThemeModePicker.jsx +2 -9
- package/dist/settings/projectVMobileApps.js +1 -6
- package/dist/sheetDrag.js +0 -10
- package/dist/swipeRow.js +0 -15
- package/dist/tabBarRoutes.js +0 -4
- package/dist/tabIndicator.js +0 -4
- package/dist/tailwind-preset.cjs +0 -54
- package/dist/tailwind-preset.d.cts +0 -8
- package/dist/theme.jsx +29 -21
- package/dist/themeModeStore.js +62 -0
- package/dist/themeModes.js +9 -0
- package/dist/toastChrome.js +0 -6
- package/dist/toastDrag.js +0 -14
- package/dist/toastStore.js +0 -4
- package/dist/updateCheck.js +0 -7
- package/dist/video/InlineVideo.jsx +0 -2
- package/dist/webview/htmlView.js +0 -5
- package/package.json +47 -19
- package/src/ArtifactList.tsx +0 -2
- package/src/Avatar.tsx +3 -3
- package/src/Badge.tsx +0 -1
- package/src/BottomSheetContainer.tsx +0 -11
- package/src/BulkActionBar.tsx +0 -66
- package/src/Button.tsx +4 -40
- package/src/CaptureButton.tsx +0 -1
- package/src/Card.tsx +3 -15
- package/src/Checkbox.tsx +0 -2
- package/src/ColorSwatches.tsx +0 -9
- package/src/ConfirmDialog.tsx +0 -7
- package/src/DateTimeField.tsx +0 -5
- package/src/Dialog.tsx +0 -27
- package/src/DividedList.tsx +0 -1
- package/src/DropdownMenu.tsx +0 -51
- package/src/EmptyState.tsx +0 -5
- package/src/ExpoWebRoot.tsx +0 -10
- package/src/Field.tsx +0 -14
- package/src/FloatingFAB.tsx +0 -3
- package/src/FloatingSurface.tsx +11 -8
- package/src/FloatingTabBar.tsx +0 -25
- package/src/IconButton.tsx +0 -5
- package/src/Input.tsx +0 -1
- package/src/Label.tsx +0 -1
- package/src/LabeledSwitchRow.tsx +0 -2
- package/src/ListRow.tsx +0 -12
- package/src/LoadingState.tsx +0 -12
- package/src/MenuSheet.tsx +0 -2
- package/src/PageIndicator.tsx +0 -2
- package/src/PageTitle.tsx +0 -15
- package/src/Pager.tsx +0 -9
- package/src/PasswordInput.tsx +0 -24
- package/src/PillTabs.tsx +3 -11
- package/src/PinnedBotTile.tsx +0 -6
- package/src/Progress.tsx +0 -3
- package/src/ReactionRow.tsx +0 -8
- package/src/ScreenContainer.tsx +0 -4
- package/src/SearchInput.tsx +0 -25
- package/src/SectionLabel.tsx +0 -2
- package/src/Select.tsx +0 -6
- package/src/Separator.tsx +0 -2
- package/src/SharedTransition.tsx +0 -7
- package/src/Sheet.tsx +0 -3
- package/src/SheetRow.tsx +0 -12
- package/src/Skeleton.tsx +0 -10
- package/src/Spinner.tsx +0 -6
- package/src/StackPageHeader.tsx +0 -16
- package/src/StatGrid.tsx +0 -1
- package/src/StatusDot.tsx +0 -6
- package/src/SurfaceRow.tsx +0 -12
- package/src/SwipeableRow.tsx +0 -4
- package/src/Switch.tsx +3 -4
- package/src/Tabs.tsx +3 -27
- package/src/Textarea.tsx +0 -2
- package/src/ThemeToggle.tsx +0 -1
- package/src/Toast.tsx +3 -19
- package/src/UpdateChecker.tsx +0 -46
- package/src/ai/activity-question.tsx +0 -8
- package/src/ai/activity-step-detail.tsx +0 -5
- package/src/ai/activity-step-label.ts +0 -5
- package/src/ai/activity-step-types.ts +0 -24
- package/src/ai/activity-step.tsx +0 -4
- package/src/ai/activity-tasks-utils.ts +0 -13
- package/src/ai/activity-timeline.ts +0 -6
- package/src/ai/attachments.tsx +0 -13
- package/src/ai/chain-of-thought.tsx +0 -5
- package/src/ai/chat-jump-rail.tsx +0 -2
- package/src/ai/chat-text.ts +0 -1
- package/src/ai/chat-thread.tsx +0 -9
- package/src/ai/choice-question.tsx +0 -36
- package/src/ai/code-block.tsx +0 -52
- package/src/ai/collapsible.tsx +0 -12
- package/src/ai/conversation-context.ts +0 -14
- package/src/ai/conversation.tsx +0 -58
- package/src/ai/file-chip.tsx +0 -1
- package/src/ai/icon-button.tsx +0 -17
- package/src/ai/index.ts +0 -5
- package/src/ai/message-action-sheet.tsx +0 -8
- package/src/ai/message-context-menu.tsx +0 -22
- package/src/ai/message-quote.tsx +0 -4
- package/src/ai/message.tsx +0 -66
- package/src/ai/prompt-input-menu.tsx +0 -19
- package/src/ai/prompt-input.tsx +0 -97
- package/src/ai/reasoning.tsx +0 -6
- package/src/ai/reply-quote-chip.tsx +0 -5
- package/src/ai/response-text.tsx +0 -8
- package/src/ai/shimmer.tsx +0 -2
- package/src/ai/sources.tsx +0 -3
- package/src/ai/subagent-cards.tsx +0 -13
- package/src/ai/suggestion.tsx +0 -4
- package/src/ai/tool-approval-card.tsx +0 -14
- package/src/ai/trace.tsx +0 -23
- package/src/ai/unified-diff.tsx +0 -16
- package/src/ai/use-streaming-disclosure.ts +0 -4
- package/src/app-root/AuthGroupGate.tsx +38 -0
- package/src/app-root/SsoCallbackScreen.tsx +52 -0
- package/src/app-root/fonts.ts +53 -0
- package/src/app-root/index.ts +6 -0
- package/src/auth/AccountScreens.tsx +0 -16
- package/src/auth/AuthProviders.tsx +0 -13
- package/src/auth/AuthScreen.tsx +95 -6
- package/src/auth/GoogleSignInButton.tsx +0 -12
- package/src/auth/SecondFactorScreen.tsx +17 -15
- package/src/auth/SignInScreen.tsx +103 -105
- package/src/auth/authErrors.ts +0 -6
- package/src/auth/clerkCore3.ts +0 -6
- package/src/auth/index.ts +0 -4
- package/src/auth/totp.ts +0 -13
- package/src/brand/AppIcons.tsx +0 -6
- package/src/brand/AppMark.tsx +0 -5
- package/src/brand/AppWordmark.tsx +0 -7
- package/src/brand/GoogleMark.tsx +0 -4
- package/src/brand/ProviderIcon.tsx +0 -6
- package/src/brand/familyApps.ts +0 -2
- package/src/brand/index.ts +0 -3
- package/src/brand/svg.ts +0 -9
- package/src/configureTheme.ts +0 -10
- package/src/controlStyles.ts +0 -12
- package/src/crash/LastCrashDialog.tsx +36 -0
- package/src/crash/lastCrash.ts +218 -0
- package/src/entries/ai.ts +0 -3
- package/src/entries/ambient.ts +0 -2
- package/src/entries/app-root.ts +1 -0
- package/src/entries/auth.ts +0 -4
- package/src/entries/bottom-sheet.ts +0 -2
- package/src/entries/brand.ts +0 -1
- package/src/entries/button.ts +0 -1
- package/src/entries/crash.ts +13 -0
- package/src/entries/date-time.ts +0 -2
- package/src/entries/expo-router.ts +0 -3
- package/src/entries/expo-web-root.ts +0 -2
- package/src/entries/floating.ts +0 -2
- package/src/entries/generative-ui.ts +0 -4
- package/src/entries/gesture-handler.ts +0 -3
- package/src/entries/keyboard-controller.ts +0 -3
- package/src/entries/layout.ts +0 -2
- package/src/entries/markdown.ts +0 -3
- package/src/entries/marketing.ts +0 -1
- package/src/entries/page-title.ts +0 -5
- package/src/entries/password-input.ts +0 -2
- package/src/entries/paste-input.ts +0 -3
- package/src/entries/primitives.ts +0 -6
- package/src/entries/search-input.ts +0 -2
- package/src/entries/tab-bar.ts +0 -2
- package/src/entries/theme.ts +8 -2
- package/src/entries/toast.ts +0 -3
- package/src/entries/video.ts +0 -2
- package/src/entries/webview.ts +0 -2
- package/src/examples/AiChatGallery.tsx +0 -11
- package/src/examples/ParityGallery.tsx +0 -25
- package/src/floating.ts +0 -6
- package/src/generative-ui/GenerativeUiPanel.tsx +0 -15
- package/src/generative-ui/components.tsx +0 -9
- package/src/generative-ui/context.ts +0 -2
- package/src/glass.ts +31 -0
- package/src/glassBlur.tsx +0 -15
- package/src/highlight.ts +1 -21
- package/src/index.ts +7 -2
- package/src/loadingGrid.ts +0 -12
- package/src/markdown/Markdown.tsx +0 -71
- package/src/markdown/MarkdownTable.tsx +0 -23
- package/src/markdown/tableText.ts +0 -3
- package/src/marketing/PricingModal.tsx +0 -13
- package/src/marketing/UpgradeToProCard.tsx +0 -14
- package/src/marketing/pricing.ts +0 -12
- package/src/media/ImageGallery.tsx +0 -18
- package/src/media/MediaCard.tsx +0 -8
- package/src/media/imageZoom.ts +0 -4
- package/src/media/zoom-image-gesture.tsx +0 -9
- package/src/media/zoomImage.ts +0 -5
- package/src/motion.ts +0 -3
- package/src/neutralTheme.ts +127 -0
- package/src/pagerSwipe.ts +0 -13
- package/src/palette.ts +0 -10
- package/src/pressScale.ts +0 -7
- package/src/primitives/button.tsx +0 -4
- package/src/primitives/card.tsx +0 -1
- package/src/primitives/icon.tsx +0 -2
- package/src/primitives/input.tsx +0 -4
- package/src/primitives/keyboard-controller.tsx +0 -25
- package/src/primitives/keyboard-parts.tsx +0 -27
- package/src/primitives/native-only-animated-view.tsx +0 -5
- package/src/primitives/overlay.tsx +0 -25
- package/src/primitives/pager-gesture.tsx +0 -20
- package/src/primitives/paste-input.tsx +0 -4
- package/src/primitives/paste-parts.tsx +0 -1
- package/src/primitives/select.tsx +0 -18
- package/src/primitives/sheet-drag.tsx +0 -19
- package/src/primitives/sheet-gesture.tsx +0 -22
- package/src/primitives/swipe-row-gesture.tsx +0 -33
- package/src/primitives/switch.tsx +0 -4
- package/src/primitives/text.tsx +0 -4
- package/src/primitives/toast-drag-gesture.tsx +0 -13
- package/src/primitives/web-click-guard.ts +0 -2
- package/src/primitives/window-layer.tsx +0 -18
- package/src/push.ts +0 -15
- package/src/relativeTime.ts +0 -21
- package/src/router/RouterStackPageHeader.tsx +0 -1
- package/src/settings/MoreFromProjectV.tsx +0 -8
- package/src/settings/SettingsEmptyState.tsx +0 -2
- package/src/settings/SettingsSection.tsx +0 -3
- package/src/settings/SettingsToggleRow.tsx +0 -4
- package/src/settings/ThemeModePicker.tsx +2 -16
- package/src/settings/projectVMobileApps.ts +0 -8
- package/src/sheetDrag.ts +0 -9
- package/src/swipeRow.ts +0 -23
- package/src/tabBarRoutes.ts +0 -13
- package/src/tabIndicator.ts +0 -5
- package/src/tailwind-preset.cjs +0 -54
- package/src/tailwind-preset.d.cts +0 -8
- package/src/theme.tsx +11 -2
- package/src/themeModeStore.ts +85 -0
- package/src/themeModes.ts +10 -0
- package/src/toastChrome.ts +0 -6
- package/src/toastDrag.ts +0 -13
- package/src/toastStore.ts +0 -7
- package/src/updateCheck.ts +0 -15
- package/src/video/InlineVideo.tsx +0 -5
- package/src/webview/HtmlView.tsx +0 -23
- package/src/webview/HtmlView.web.tsx +0 -1
- package/src/webview/htmlView.ts +0 -5
- package/types/prism-react-renderer.d.ts +22 -0
package/dist/Toast.jsx
CHANGED
|
@@ -12,19 +12,14 @@ import { sizeStyle, textStyle, typeStyle } from "./controlStyles";
|
|
|
12
12
|
import { FLOATING_INSET } from "./floating";
|
|
13
13
|
import { TOAST_ICON_SIZE, TOAST_ICONS, toastIconColor, toastShadowStyle, toastSurfaceStyle } from "./toastChrome";
|
|
14
14
|
import { tokens } from "./tokens";
|
|
15
|
+
import { useGlass } from "./glass";
|
|
15
16
|
import { useLargerText } from "./theme";
|
|
16
17
|
import { useScheme } from "./useScheme";
|
|
17
18
|
import { NativeOnlyAnimatedView } from "./primitives/native-only-animated-view";
|
|
18
19
|
import { ToastDragContext } from "./toastDrag";
|
|
19
20
|
import { getToasts, subscribeToasts, toast } from "./toastStore";
|
|
20
|
-
|
|
21
|
-
// On iOS the overlay draws above RN `Modal`s, so toasts show over dialogs (as
|
|
22
|
-
// sonner does on the web). On Android a `Modal` still covers them.
|
|
23
21
|
const FullWindowOverlay = Platform.OS === "ios" ? RNFullWindowOverlay : Fragment;
|
|
24
22
|
const toastShadow = toastShadowStyle(Platform.OS);
|
|
25
|
-
|
|
26
|
-
// Down from the top edge and back up the way it came, the exit 20% quicker:
|
|
27
|
-
// the reader is done with it.
|
|
28
23
|
const TOAST_ENTER = FadeInUp.duration(200).easing(EASE_OUT);
|
|
29
24
|
const TOAST_EXIT = FadeOutUp.duration(160).easing(EASE_OUT);
|
|
30
25
|
|
|
@@ -81,8 +76,6 @@ export function Toaster(t0) {
|
|
|
81
76
|
}
|
|
82
77
|
return t7;
|
|
83
78
|
}
|
|
84
|
-
|
|
85
|
-
/** The web filled 24 icons (`toastChrome`), or a spinner while loading. */
|
|
86
79
|
function _temp(item) {
|
|
87
80
|
return <ToastCard key={item.id} item={item} />;
|
|
88
81
|
}
|
|
@@ -143,12 +136,6 @@ function ToastIcon(t0) {
|
|
|
143
136
|
}
|
|
144
137
|
return t3;
|
|
145
138
|
}
|
|
146
|
-
|
|
147
|
-
/**
|
|
148
|
-
* Closes `item` after its `duration`, counting only while it is not `held`:
|
|
149
|
-
* a finger on the toast pauses the time left, and lifting it resumes. A
|
|
150
|
-
* toast replaced in place (same id, new item) starts its own time afresh.
|
|
151
|
-
*/
|
|
152
139
|
function useToastTimer(item, held) {
|
|
153
140
|
const $ = _c(6);
|
|
154
141
|
let t0;
|
|
@@ -195,12 +182,13 @@ function useToastTimer(item, held) {
|
|
|
195
182
|
useEffect(t1, t2);
|
|
196
183
|
}
|
|
197
184
|
function ToastCard(t0) {
|
|
198
|
-
const $ = _c(
|
|
185
|
+
const $ = _c(57);
|
|
199
186
|
const {
|
|
200
187
|
item
|
|
201
188
|
} = t0;
|
|
202
189
|
const largerText = useLargerText();
|
|
203
190
|
const scheme = useScheme();
|
|
191
|
+
const glass = useGlass("surface");
|
|
204
192
|
const Drag = useContext(ToastDragContext);
|
|
205
193
|
const [held, setHeld] = useState(false);
|
|
206
194
|
useToastTimer(item, held);
|
|
@@ -251,146 +239,147 @@ function ToastCard(t0) {
|
|
|
251
239
|
t5 = $[10];
|
|
252
240
|
}
|
|
253
241
|
let t6;
|
|
254
|
-
if ($[11] !== t5) {
|
|
255
|
-
t6 = [t5, toastShadow];
|
|
256
|
-
$[11] =
|
|
257
|
-
$[12] =
|
|
242
|
+
if ($[11] !== glass || $[12] !== t5) {
|
|
243
|
+
t6 = [t5, toastShadow, glass];
|
|
244
|
+
$[11] = glass;
|
|
245
|
+
$[12] = t5;
|
|
246
|
+
$[13] = t6;
|
|
258
247
|
} else {
|
|
259
|
-
t6 = $[
|
|
248
|
+
t6 = $[13];
|
|
260
249
|
}
|
|
261
250
|
const t7 = `toast-${item.id}`;
|
|
262
251
|
const t8 = !item.action;
|
|
263
252
|
let t9;
|
|
264
|
-
if ($[
|
|
253
|
+
if ($[14] !== item.id) {
|
|
265
254
|
t9 = () => toast.dismiss(item.id);
|
|
266
|
-
$[
|
|
267
|
-
$[
|
|
255
|
+
$[14] = item.id;
|
|
256
|
+
$[15] = t9;
|
|
268
257
|
} else {
|
|
269
|
-
t9 = $[
|
|
258
|
+
t9 = $[15];
|
|
270
259
|
}
|
|
271
260
|
let t10;
|
|
272
|
-
if ($[
|
|
261
|
+
if ($[16] !== item) {
|
|
273
262
|
t10 = <ToastIcon item={item} />;
|
|
274
|
-
$[
|
|
275
|
-
$[
|
|
263
|
+
$[16] = item;
|
|
264
|
+
$[17] = t10;
|
|
276
265
|
} else {
|
|
277
|
-
t10 = $[
|
|
266
|
+
t10 = $[17];
|
|
278
267
|
}
|
|
279
268
|
const t11 = largerText ? "text-lg" : "text-sm";
|
|
280
269
|
let t12;
|
|
281
|
-
if ($[
|
|
270
|
+
if ($[18] !== t11) {
|
|
282
271
|
t12 = cn("font-instrument-sans-medium", t11);
|
|
283
|
-
$[
|
|
284
|
-
$[
|
|
272
|
+
$[18] = t11;
|
|
273
|
+
$[19] = t12;
|
|
285
274
|
} else {
|
|
286
|
-
t12 = $[
|
|
275
|
+
t12 = $[19];
|
|
287
276
|
}
|
|
288
277
|
let t13;
|
|
289
|
-
if ($[
|
|
278
|
+
if ($[20] !== scheme) {
|
|
290
279
|
t13 = textStyle("foreground", scheme);
|
|
291
|
-
$[
|
|
292
|
-
$[
|
|
280
|
+
$[20] = scheme;
|
|
281
|
+
$[21] = t13;
|
|
293
282
|
} else {
|
|
294
|
-
t13 = $[
|
|
283
|
+
t13 = $[21];
|
|
295
284
|
}
|
|
296
285
|
let t14;
|
|
297
|
-
if ($[
|
|
286
|
+
if ($[22] === Symbol.for("react.memo_cache_sentinel")) {
|
|
298
287
|
t14 = typeStyle("medium");
|
|
299
|
-
$[
|
|
288
|
+
$[22] = t14;
|
|
300
289
|
} else {
|
|
301
|
-
t14 = $[
|
|
290
|
+
t14 = $[22];
|
|
302
291
|
}
|
|
303
292
|
let t15;
|
|
304
|
-
if ($[
|
|
293
|
+
if ($[23] !== largerText) {
|
|
305
294
|
t15 = largerText ? sizeStyle("text-lg") : sizeStyle("text-sm", "snug");
|
|
306
|
-
$[
|
|
307
|
-
$[
|
|
295
|
+
$[23] = largerText;
|
|
296
|
+
$[24] = t15;
|
|
308
297
|
} else {
|
|
309
|
-
t15 = $[
|
|
298
|
+
t15 = $[24];
|
|
310
299
|
}
|
|
311
300
|
let t16;
|
|
312
|
-
if ($[
|
|
301
|
+
if ($[25] !== t13 || $[26] !== t15) {
|
|
313
302
|
t16 = [t13, t14, t15];
|
|
314
|
-
$[
|
|
315
|
-
$[
|
|
316
|
-
$[
|
|
303
|
+
$[25] = t13;
|
|
304
|
+
$[26] = t15;
|
|
305
|
+
$[27] = t16;
|
|
317
306
|
} else {
|
|
318
|
-
t16 = $[
|
|
307
|
+
t16 = $[27];
|
|
319
308
|
}
|
|
320
309
|
let t17;
|
|
321
|
-
if ($[
|
|
310
|
+
if ($[28] !== item.title || $[29] !== t12 || $[30] !== t16) {
|
|
322
311
|
t17 = <Text className={t12} style={t16}>{item.title}</Text>;
|
|
323
|
-
$[
|
|
324
|
-
$[
|
|
325
|
-
$[
|
|
326
|
-
$[
|
|
312
|
+
$[28] = item.title;
|
|
313
|
+
$[29] = t12;
|
|
314
|
+
$[30] = t16;
|
|
315
|
+
$[31] = t17;
|
|
327
316
|
} else {
|
|
328
|
-
t17 = $[
|
|
317
|
+
t17 = $[31];
|
|
329
318
|
}
|
|
330
319
|
let t18;
|
|
331
|
-
if ($[
|
|
320
|
+
if ($[32] !== item.description || $[33] !== largerText || $[34] !== scheme) {
|
|
332
321
|
t18 = item.description ? <Text className={cn("font-instrument-sans", largerText ? "text-base" : "text-sm")} style={textStyle("muted", scheme)}>{item.description}</Text> : null;
|
|
333
|
-
$[
|
|
334
|
-
$[
|
|
335
|
-
$[
|
|
336
|
-
$[
|
|
322
|
+
$[32] = item.description;
|
|
323
|
+
$[33] = largerText;
|
|
324
|
+
$[34] = scheme;
|
|
325
|
+
$[35] = t18;
|
|
337
326
|
} else {
|
|
338
|
-
t18 = $[
|
|
327
|
+
t18 = $[35];
|
|
339
328
|
}
|
|
340
329
|
let t19;
|
|
341
|
-
if ($[
|
|
330
|
+
if ($[36] !== t17 || $[37] !== t18) {
|
|
342
331
|
t19 = <View className="min-w-0 flex-1">{t17}{t18}</View>;
|
|
343
|
-
$[
|
|
344
|
-
$[
|
|
345
|
-
$[
|
|
332
|
+
$[36] = t17;
|
|
333
|
+
$[37] = t18;
|
|
334
|
+
$[38] = t19;
|
|
346
335
|
} else {
|
|
347
|
-
t19 = $[
|
|
336
|
+
t19 = $[38];
|
|
348
337
|
}
|
|
349
338
|
let t20;
|
|
350
|
-
if ($[
|
|
339
|
+
if ($[39] !== item.action || $[40] !== item.id || $[41] !== scheme) {
|
|
351
340
|
t20 = item.action ? <Pressable accessibilityRole="button" hitSlop={8} onPress={() => {
|
|
352
341
|
item.action?.onPress();
|
|
353
342
|
toast.dismiss(item.id);
|
|
354
343
|
}} className="rounded-full bg-secondary px-3 py-1.5 active:opacity-70"><Text className="font-instrument-sans-medium text-sm" style={[textStyle("foreground", scheme), typeStyle("medium")]}>{item.action.label}</Text></Pressable> : null;
|
|
355
|
-
$[
|
|
356
|
-
$[
|
|
357
|
-
$[
|
|
358
|
-
$[
|
|
344
|
+
$[39] = item.action;
|
|
345
|
+
$[40] = item.id;
|
|
346
|
+
$[41] = scheme;
|
|
347
|
+
$[42] = t20;
|
|
359
348
|
} else {
|
|
360
|
-
t20 = $[
|
|
349
|
+
t20 = $[42];
|
|
361
350
|
}
|
|
362
351
|
let t21;
|
|
363
|
-
if ($[
|
|
352
|
+
if ($[43] !== t10 || $[44] !== t19 || $[45] !== t20 || $[46] !== t7 || $[47] !== t8 || $[48] !== t9) {
|
|
364
353
|
t21 = <Pressable testID={t7} accessible={t8} accessibilityRole="button" accessibilityHint="Closes the message" onPress={t9} className="flex-row items-center gap-3 px-4 py-3">{t10}{t19}{t20}</Pressable>;
|
|
365
|
-
$[
|
|
366
|
-
$[
|
|
367
|
-
$[
|
|
368
|
-
$[
|
|
369
|
-
$[
|
|
370
|
-
$[
|
|
371
|
-
$[
|
|
354
|
+
$[43] = t10;
|
|
355
|
+
$[44] = t19;
|
|
356
|
+
$[45] = t20;
|
|
357
|
+
$[46] = t7;
|
|
358
|
+
$[47] = t8;
|
|
359
|
+
$[48] = t9;
|
|
360
|
+
$[49] = t21;
|
|
372
361
|
} else {
|
|
373
|
-
t21 = $[
|
|
362
|
+
t21 = $[49];
|
|
374
363
|
}
|
|
375
364
|
let t22;
|
|
376
|
-
if ($[
|
|
365
|
+
if ($[50] !== t21 || $[51] !== t6) {
|
|
377
366
|
t22 = <View style={t6}>{t21}</View>;
|
|
378
|
-
$[
|
|
379
|
-
$[
|
|
380
|
-
$[
|
|
367
|
+
$[50] = t21;
|
|
368
|
+
$[51] = t6;
|
|
369
|
+
$[52] = t22;
|
|
381
370
|
} else {
|
|
382
|
-
t22 = $[
|
|
371
|
+
t22 = $[52];
|
|
383
372
|
}
|
|
384
373
|
const surface = t22;
|
|
385
374
|
let t23;
|
|
386
|
-
if ($[
|
|
375
|
+
if ($[53] !== Drag || $[54] !== item.id || $[55] !== surface) {
|
|
387
376
|
t23 = <NativeOnlyAnimatedView entering={TOAST_ENTER} exiting={TOAST_EXIT} layout={LinearTransition}>{Drag ? <Drag onDismiss={() => toast.dismiss(item.id)} onHoldChange={setHeld}>{surface}</Drag> : surface}</NativeOnlyAnimatedView>;
|
|
388
|
-
$[
|
|
389
|
-
$[
|
|
390
|
-
$[
|
|
391
|
-
$[
|
|
377
|
+
$[53] = Drag;
|
|
378
|
+
$[54] = item.id;
|
|
379
|
+
$[55] = surface;
|
|
380
|
+
$[56] = t23;
|
|
392
381
|
} else {
|
|
393
|
-
t23 = $[
|
|
382
|
+
t23 = $[56];
|
|
394
383
|
}
|
|
395
384
|
return t23;
|
|
396
385
|
}
|
package/dist/UpdateChecker.jsx
CHANGED
|
@@ -209,7 +209,6 @@ export function UpdatePrompt(t0) {
|
|
|
209
209
|
|
|
210
210
|
/** Where "Later" is remembered, for example `expo-secure-store` or AsyncStorage. */
|
|
211
211
|
function _temp() {}
|
|
212
|
-
/** The version Later hid. An unreadable store means nothing was dismissed. */
|
|
213
212
|
async function readDismissed(storage, key) {
|
|
214
213
|
try {
|
|
215
214
|
return await storage.getItem(key);
|
|
@@ -109,12 +109,6 @@ export function ActivityQuestionCard(t0) {
|
|
|
109
109
|
}
|
|
110
110
|
return t1;
|
|
111
111
|
}
|
|
112
|
-
|
|
113
|
-
/**
|
|
114
|
-
* One option as recorded (web `OptionRow`): a 20 rounded mark (the letter, a
|
|
115
|
-
* check when picked, a pencil for "Other"), the label and its description.
|
|
116
|
-
* Picked: the row on the tertiary fill, the mark on primary, the label medium.
|
|
117
|
-
*/
|
|
118
112
|
function RecordRow(t0) {
|
|
119
113
|
const $ = _c(56);
|
|
120
114
|
const {
|
|
@@ -636,11 +636,6 @@ function joinCommandText(verb, target) {
|
|
|
636
636
|
}
|
|
637
637
|
return `${verb} ${target}`;
|
|
638
638
|
}
|
|
639
|
-
|
|
640
|
-
/**
|
|
641
|
-
* Past-tense phrase used when a step type is folded into a group summary line.
|
|
642
|
-
* Deliberately plural/vague — the exact call is one click away in the fold.
|
|
643
|
-
*/
|
|
644
639
|
const GROUP_PHRASES = {
|
|
645
640
|
read: "read files",
|
|
646
641
|
edit: "edited files",
|
|
@@ -667,7 +662,6 @@ function groupPhraseForStep(step) {
|
|
|
667
662
|
if (step.type !== "tool") {
|
|
668
663
|
return GROUP_PHRASES[step.type];
|
|
669
664
|
}
|
|
670
|
-
// Codex reports edits as a `file_change` tool call, not an edit step.
|
|
671
665
|
if (isFileChangeTool(step)) {
|
|
672
666
|
return GROUP_PHRASES.edit;
|
|
673
667
|
}
|
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
// Pure step types for the activity timeline: no React, so `@vvedantb/native-ui`
|
|
2
|
-
// keeps a byte-identical copy (`src/ai/activity-step-types.ts`), with the step
|
|
3
|
-
// labels and grouping that read them.
|
|
4
|
-
|
|
5
1
|
/** One item in a todo checklist step (type "todos"). */
|
|
6
2
|
|
|
7
3
|
/** One choice offered by an AskUserQuestion prompt. */
|
|
@@ -3,17 +3,8 @@
|
|
|
3
3
|
* inside that agent (keyed by parentToolUseId → toolUseId).
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
/**
|
|
7
|
-
* Status-filler thinking labels emitted by older callback versions (and by
|
|
8
|
-
* prod until the current callback deploys). The response/reasoning text is
|
|
9
|
-
* shown directly, so these narration rows are pure noise — hide them.
|
|
10
|
-
*/
|
|
11
6
|
const LEGACY_NOISE_LABELS = new Set(["Generating response...", "Generated response", "Streaming response...", "Streamed response", "Finalizing response..."]);
|
|
12
|
-
|
|
13
|
-
/** Thinking labels that mark model reasoning rather than status narration. */
|
|
14
7
|
const REASONING_LABELS = new Set(["Thinking...", "Thought"]);
|
|
15
|
-
|
|
16
|
-
/** Placeholder details older callbacks attached to reasoning-label steps. */
|
|
17
8
|
const FILLER_DETAILS = new Set(["Claude is reasoning...", "Codex is reasoning...", "Opencode is reasoning...", "Cursor is reasoning...", "Receiving reply..."]);
|
|
18
9
|
|
|
19
10
|
/**
|
|
@@ -35,8 +26,6 @@ export function normalizeStep(step) {
|
|
|
35
26
|
}
|
|
36
27
|
return step;
|
|
37
28
|
}
|
|
38
|
-
|
|
39
|
-
/** Builds one row per normalized step (no consecutive-type merging). */
|
|
40
29
|
function stepsToRows(steps) {
|
|
41
30
|
const rows = [];
|
|
42
31
|
for (const raw of steps) {
|
|
@@ -48,11 +37,6 @@ function stepsToRows(steps) {
|
|
|
48
37
|
}
|
|
49
38
|
return rows;
|
|
50
39
|
}
|
|
51
|
-
|
|
52
|
-
/**
|
|
53
|
-
* Row types that read as narration rather than work: they already summarise
|
|
54
|
-
* themselves, so folding them into an action group would hide their only text.
|
|
55
|
-
*/
|
|
56
40
|
const STANDALONE_TYPES = new Set(["todos", "notice", "status", "question", "steer"]);
|
|
57
41
|
|
|
58
42
|
/** One block in the activity timeline: prose, a lone row, or a folded run. */
|
|
@@ -73,7 +57,6 @@ export function groupActivityRows(rows) {
|
|
|
73
57
|
});
|
|
74
58
|
continue;
|
|
75
59
|
}
|
|
76
|
-
// Mid-turn reply text: it ends the tool run before it, like reasoning.
|
|
77
60
|
if (row.step.type === "response") {
|
|
78
61
|
segments.push({
|
|
79
62
|
kind: "response",
|
|
@@ -1,17 +1,9 @@
|
|
|
1
|
-
// The folded (Codex-style) rules of the web `ActivityTasks`
|
|
2
|
-
// (`@vvedantb/ui` `activity-tasks.tsx`), as pure logic for an app that draws
|
|
3
|
-
// the rows with the `AgentTrace` parts. The row text, the grouping and the
|
|
4
|
-
// step types are byte-identical copies of the web files
|
|
5
|
-
// (`activity-step-label.ts`, `activity-tasks-utils.ts`, `activity-step-types.ts`).
|
|
6
|
-
|
|
7
1
|
import { buildActivityRows, groupActivityRows } from "./activity-tasks-utils";
|
|
8
2
|
/** Blocks a settled timeline shows before "Show N more" (web `MAX_VISIBLE_ROWS`). */
|
|
9
3
|
export const ACTIVITY_MAX_VISIBLE_BLOCKS = 8;
|
|
10
4
|
|
|
11
5
|
/** Child rows a subagent step shows before "+N more" (web `MAX_VISIBLE_CHILDREN`). */
|
|
12
6
|
export const ACTIVITY_MAX_VISIBLE_CHILDREN = 8;
|
|
13
|
-
|
|
14
|
-
/** Step types the folded layout hides: the reply text and the status thinking lines. */
|
|
15
7
|
const HIDDEN_TYPES = new Set(["thinking", "response"]);
|
|
16
8
|
|
|
17
9
|
/**
|
package/dist/ai/attachments.jsx
CHANGED
|
@@ -97,8 +97,6 @@ export function Attachments(t0) {
|
|
|
97
97
|
}
|
|
98
98
|
/** The hit target of a pressable chip, in points, on each axis. */
|
|
99
99
|
export const ATTACHMENT_PRESS_TARGET = 48;
|
|
100
|
-
|
|
101
|
-
/** A remove cross of 20 in a 32 row: the slop brings it to 44. */
|
|
102
100
|
const REMOVE_SIZE = 20;
|
|
103
101
|
|
|
104
102
|
/**
|
|
@@ -11,9 +11,6 @@ import { chatTextSize } from "./chat-text";
|
|
|
11
11
|
import { Collapsible, CollapsibleChevron, CollapsibleContent, CollapsibleTrigger, useCollapsible } from "./collapsible";
|
|
12
12
|
import { ResponseText } from "./response-text";
|
|
13
13
|
|
|
14
|
-
// The web `ChainOfThought`, simplified: a fold of steps with search-result
|
|
15
|
-
// chips. `ChainOfThoughtImage` and the step enter animation are not ported.
|
|
16
|
-
|
|
17
14
|
/** Holds its open state (default closed), or takes `open` and `onOpenChange`. */
|
|
18
15
|
export function ChainOfThought(t0) {
|
|
19
16
|
const $ = _c(8);
|
package/dist/ai/chat-text.js
CHANGED
package/dist/ai/chat-thread.jsx
CHANGED
|
@@ -9,7 +9,6 @@ import { Conversation, ConversationContent, ConversationScrollButton } from "./c
|
|
|
9
9
|
* `UIMessage` fits it, so the package takes no `ai` dependency.
|
|
10
10
|
*/
|
|
11
11
|
|
|
12
|
-
/** Index of the last message with `role`, or -1. A loop, not `findLastIndex` (Hermes). */
|
|
13
12
|
function lastIndexOfRole(messages, role) {
|
|
14
13
|
for (let index = messages.length - 1; index >= 0; index -= 1) {
|
|
15
14
|
if (messages[index].role === role) return index;
|
|
@@ -586,16 +586,12 @@ export function TopicBadge(t0) {
|
|
|
586
586
|
}
|
|
587
587
|
return t9;
|
|
588
588
|
}
|
|
589
|
-
|
|
590
|
-
/** The option card's `py-2 px-2.5`, which is also the slop of its press target. */
|
|
591
589
|
const CARD_PADDING = {
|
|
592
590
|
top: 8,
|
|
593
591
|
bottom: 8,
|
|
594
592
|
left: 10,
|
|
595
593
|
right: 10
|
|
596
594
|
};
|
|
597
|
-
|
|
598
|
-
/** A whole card is at least a 44 target: the press target inside is this much less its slop. */
|
|
599
595
|
const CARD_MIN_HEIGHT = 44;
|
|
600
596
|
|
|
601
597
|
/** The card while pressed: the kit 3% press scale, or a dim with Reduce Motion. */
|
|
@@ -609,12 +605,6 @@ export function choicePressStyle(pressed, reduceMotion) {
|
|
|
609
605
|
}]
|
|
610
606
|
};
|
|
611
607
|
}
|
|
612
|
-
|
|
613
|
-
/**
|
|
614
|
-
* One option row (web `Card` with `bg-secondary`, `py-2 px-2.5`, radius 16): a round 24 mark
|
|
615
|
-
* (30 with larger text; letter, or a pencil for "Other"; a check on the primary fill when picked),
|
|
616
|
-
* the label and the description. Picked: a 1-wide primary ring outside, on the accent.
|
|
617
|
-
*/
|
|
618
608
|
function ChoiceRow(t0) {
|
|
619
609
|
const $ = _c(99);
|
|
620
610
|
const {
|
package/dist/ai/code-block.jsx
CHANGED
|
@@ -107,21 +107,6 @@ export function CodeBlockCopyButton(t0) {
|
|
|
107
107
|
}
|
|
108
108
|
return t9;
|
|
109
109
|
}
|
|
110
|
-
/**
|
|
111
|
-
* Code on the flat panel at radius 16, selectable, long lines scrolling
|
|
112
|
-
* sideways. With `prism-react-renderer` installed and a `language`, tokens
|
|
113
|
-
* take the GitHub colours of the scheme.
|
|
114
|
-
*
|
|
115
|
-
* `default` is the web `CodeBlock` (`ai-elements/code-block.tsx`): `text-sm`
|
|
116
|
-
* code in `p-4`, and a `px-3` header with the language and a copy button when
|
|
117
|
-
* either is given. `markdown` is the web `MarkdownCodeBlock`, which `Markdown`
|
|
118
|
-
* draws for fenced code: 13 / 20.15 code, a 32 header with `icon-xs` actions,
|
|
119
|
-
* a wrap toggle ("Wrap long lines", foreground while on) and then copy.
|
|
120
|
-
*/
|
|
121
|
-
/**
|
|
122
|
-
* Android fades the code at a side with more to scroll (there is no scroll
|
|
123
|
-
* bar), so a cut line reads as "scroll sideways". iOS ignores it.
|
|
124
|
-
*/
|
|
125
110
|
const CODE_FADING_EDGE = 24;
|
|
126
111
|
export function CodeBlock(t0) {
|
|
127
112
|
const $ = _c(21);
|
|
@@ -194,8 +179,6 @@ export function CodeBlock(t0) {
|
|
|
194
179
|
}
|
|
195
180
|
return t7;
|
|
196
181
|
}
|
|
197
|
-
|
|
198
|
-
/** The web `MarkdownCodeBlock`: `CodeBlock` with `variant="markdown"`. A component of its own for the wrap state. */
|
|
199
182
|
function MarkdownCodeBlock(t0) {
|
|
200
183
|
const $ = _c(21);
|
|
201
184
|
const {
|
|
@@ -281,8 +264,6 @@ function MarkdownCodeBlock(t0) {
|
|
|
281
264
|
}
|
|
282
265
|
return t5;
|
|
283
266
|
}
|
|
284
|
-
|
|
285
|
-
/** The panel style, the language label and the code text both code blocks draw. */
|
|
286
267
|
function useCodeParts(code, language, highlight, markdown) {
|
|
287
268
|
const $ = _c(42);
|
|
288
269
|
const scheme = useScheme();
|
|
@@ -429,11 +410,6 @@ function useCodeParts(code, language, highlight, markdown) {
|
|
|
429
410
|
}
|
|
430
411
|
return t10;
|
|
431
412
|
}
|
|
432
|
-
|
|
433
|
-
/**
|
|
434
|
-
* Coloured runs as nested `Text` spans, lines joined by newlines. They
|
|
435
|
-
* inherit the size and font of the code `Text` around them.
|
|
436
|
-
*/
|
|
437
413
|
function CodeRuns(t0) {
|
|
438
414
|
const $ = _c(7);
|
|
439
415
|
const {
|
|
@@ -469,13 +445,6 @@ function CodeRuns(t0) {
|
|
|
469
445
|
}
|
|
470
446
|
return t2;
|
|
471
447
|
}
|
|
472
|
-
|
|
473
|
-
/**
|
|
474
|
-
* The code in the web's Shiki colours: shell blocks through `shellTokens`
|
|
475
|
-
* (no peer needed), other languages through Prism, the JavaScript family
|
|
476
|
-
* recoloured where Prism and Shiki disagree (`scriptTokens`). Without
|
|
477
|
-
* `prism-react-renderer` a non-shell block is the plain code.
|
|
478
|
-
*/
|
|
479
448
|
function HighlightedCode(t0) {
|
|
480
449
|
const $ = _c(19);
|
|
481
450
|
const {
|
package/dist/ai/collapsible.jsx
CHANGED
|
@@ -7,18 +7,6 @@ import { cn } from "../cn";
|
|
|
7
7
|
import { MIN_TOUCH_TARGET, touchSlop } from "../controlStyles";
|
|
8
8
|
import { useControllableState } from "../primitives/use-controllable-state";
|
|
9
9
|
import { useReduceMotion } from "../useReduceMotion";
|
|
10
|
-
|
|
11
|
-
// A small fold for the AI parts: native-ui has no `Collapsible`. A `Pressable`
|
|
12
|
-
// trigger and content that mounts only while open. The content appears at
|
|
13
|
-
// once: a fade would also run each time a list mounts an open fold (a chat
|
|
14
|
-
// opening, a virtualised row scrolled back). The chevron turns in 150 ms; with
|
|
15
|
-
// Reduce Motion it changes in place.
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* The web chevron: `transition-transform duration-150`. The curve is the
|
|
19
|
-
* predefined `ease-out`: a `cubicBezier(...)` value in an `Animated.View`
|
|
20
|
-
* style does not typecheck against `react-native-reanimated` 4.3.
|
|
21
|
-
*/
|
|
22
10
|
const CHEVRON_TURN = {
|
|
23
11
|
transitionProperty: "transform",
|
|
24
12
|
transitionDuration: 150,
|
|
@@ -106,8 +94,6 @@ export function Collapsible(t0) {
|
|
|
106
94
|
}
|
|
107
95
|
return t5;
|
|
108
96
|
}
|
|
109
|
-
|
|
110
|
-
/** A `text-sm` line with the web `py-1`: 28 high. The slop brings it to 44. */
|
|
111
97
|
const TRIGGER_ROW_HEIGHT = 28;
|
|
112
98
|
/** Toggles the fold. A button with `expanded` state for VoiceOver and TalkBack. */
|
|
113
99
|
export function CollapsibleTrigger(t0) {
|
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
import { createContext, useContext } from "react";
|
|
2
2
|
|
|
3
|
-
// The `Conversation` context on its own, so a message can reach it without the
|
|
4
|
-
// thread's components (`message.tsx` sets `overlay`).
|
|
5
|
-
|
|
6
3
|
/**
|
|
7
4
|
* What the thread scrolls with: the `ScrollView` of `ConversationContent` or
|
|
8
5
|
* the `FlatList` of `ConversationList`. `scrollToEnd` goes to the newest
|