Import apps/android/src/screens/chat/styles.ts
This commit is contained in:
parent
7e3dc7aacb
commit
dda43dd055
|
|
@ -0,0 +1,636 @@
|
|||
import { StyleSheet } from 'react-native'
|
||||
import { floatingShadow, radius, spacing, typeForDensity, type TypographyDensity } from '../../ui/theme'
|
||||
import type { ThemeColors } from '../../ui/theme-context'
|
||||
|
||||
export function createStyles(colors: ThemeColors, density: TypographyDensity = 'compact') {
|
||||
const isCompact = density === 'compact'
|
||||
const t = typeForDensity(density)
|
||||
return StyleSheet.create({
|
||||
flex: { flex: 1, backgroundColor: colors.background },
|
||||
splitRoot: { flex: 1 },
|
||||
splitRootWide: { flexDirection: 'row' },
|
||||
splitSidebar: { width: 300, maxWidth: '38%', backgroundColor: colors.surface },
|
||||
splitMain: { flex: 1, minWidth: 0 },
|
||||
modelChip: { minWidth: 0, flexShrink: 1, flexDirection: 'row', alignItems: 'center', gap: 4, paddingLeft: spacing.sm + 2, paddingRight: spacing.sm, height: 38, borderRadius: radius.pill, backgroundColor: colors.surfaceStrong },
|
||||
permissionChip: { minWidth: 0, flexShrink: 1, flexDirection: 'row', alignItems: 'center', gap: isCompact ? 4 : spacing.xs, paddingHorizontal: isCompact ? 8 : spacing.sm, height: isCompact ? 32 : 36, borderRadius: radius.pill, backgroundColor: colors.primarySoft, borderWidth: StyleSheet.hairlineWidth, borderColor: colors.separator },
|
||||
permissionChipDisabled: { opacity: 0.52 },
|
||||
modelChipText: { ...t.small, fontSize: 14, color: colors.ink, flexShrink: 1 },
|
||||
olderButton: { alignSelf: 'center', paddingVertical: isCompact ? 4 : spacing.xs, paddingHorizontal: spacing.md, marginBottom: isCompact ? 4 : spacing.sm },
|
||||
olderText: { ...t.smallStrong, color: colors.primary },
|
||||
// Floats over the newest row so jumping back never moves the composer.
|
||||
// The layer is transparent to touches; only the button itself is a target.
|
||||
latestTurnLayer: { position: 'absolute', left: 0, right: 0, bottom: spacing.sm, alignItems: 'center', paddingHorizontal: spacing.lg },
|
||||
// Touch slop never exceeds the parent bounds, so the padding keeps the
|
||||
// 44 dp circle reachable as the 48 dp target the design system asks for.
|
||||
latestTurnColumn: { alignItems: 'flex-end', paddingVertical: 2 },
|
||||
latestTurnButton: {
|
||||
width: 44,
|
||||
height: 44,
|
||||
borderRadius: radius.pill,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
backgroundColor: colors.surface,
|
||||
borderWidth: StyleSheet.hairlineWidth,
|
||||
borderColor: colors.separator,
|
||||
shadowColor: '#000',
|
||||
shadowOffset: { width: 0, height: 2 },
|
||||
shadowOpacity: 0.16,
|
||||
shadowRadius: 6,
|
||||
elevation: 4,
|
||||
},
|
||||
latestTurnButtonPressed: { opacity: 0.7 },
|
||||
modalBackdrop: { flex: 1, backgroundColor: colors.modalBackdrop, justifyContent: 'flex-end' },
|
||||
// Keep the sheet above the full-screen dismiss target on Android. Without an
|
||||
// explicit stacking order, the transparent backdrop can win hit testing on
|
||||
// some RN/Android combinations even though it is rendered first.
|
||||
// maxHeight is applied by ModalSurface from the live window size (landscape phones get ~92%).
|
||||
modalSheet: { zIndex: 1, elevation: 1, backgroundColor: colors.background, borderTopLeftRadius: radius.xxl, borderTopRightRadius: radius.xxl, padding: spacing.lg, paddingBottom: spacing.xxl },
|
||||
modalHeader: { flexDirection: 'row', alignItems: 'center', justifyContent: 'space-between', gap: spacing.sm, marginBottom: spacing.md },
|
||||
modalHeaderCopy: { minWidth: 0, flex: 1, flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
modalTitle: { ...t.heading, color: colors.ink, flexShrink: 1 },
|
||||
modalListContent: { paddingBottom: spacing.xs },
|
||||
pickerHint: { ...t.caption, color: colors.muted, marginBottom: spacing.sm },
|
||||
pickerEmpty: { paddingVertical: spacing.md, gap: spacing.sm, alignItems: 'flex-start' },
|
||||
modelGroupBlock: { marginBottom: spacing.md },
|
||||
modelGroupTitle: { ...t.caption, color: colors.muted, textTransform: 'uppercase', marginBottom: spacing.xs },
|
||||
modelOption: { flexDirection: 'row', alignItems: 'center', gap: spacing.sm, minHeight: 52, paddingHorizontal: spacing.md, paddingVertical: spacing.sm, borderRadius: radius.lg, borderWidth: 1, borderColor: 'transparent', backgroundColor: colors.grouped, marginBottom: spacing.xs },
|
||||
modelOptionCurrent: { borderColor: colors.primary, backgroundColor: colors.primarySoft },
|
||||
modelOptionCopy: { minWidth: 0, flex: 1 },
|
||||
modelOptionName: { ...t.small, color: colors.ink },
|
||||
permissionOption: { flexDirection: 'row', alignItems: 'center', gap: spacing.sm, minHeight: 52, paddingHorizontal: spacing.md, paddingVertical: spacing.sm, borderRadius: radius.lg, backgroundColor: colors.grouped, marginBottom: spacing.xs },
|
||||
permissionOptionCopy: { flex: 1 },
|
||||
permissionOptionName: { ...t.small, color: colors.ink },
|
||||
permissionOptionDescription: { ...t.caption, color: colors.muted, marginTop: 2 },
|
||||
modelFailures: { ...t.caption, color: colors.danger, marginTop: spacing.sm },
|
||||
connectionBanner: { minHeight: 40, marginHorizontal: spacing.md, marginTop: spacing.xxs, paddingHorizontal: spacing.md, paddingVertical: spacing.xs, borderRadius: radius.pill, backgroundColor: colors.warningSoft, flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
connectionDot: { width: 8, height: 8, borderRadius: radius.pill, backgroundColor: colors.warning },
|
||||
connectionBannerText: { ...t.small, color: colors.ink, flex: 1 },
|
||||
list: { flex: 1 },
|
||||
listContent: { paddingHorizontal: isCompact ? 14 : spacing.lg, paddingTop: isCompact ? spacing.md : spacing.xl, paddingBottom: spacing.xxl, gap: isCompact ? 2 : spacing.xxs },
|
||||
shortConversation: { flexGrow: 1, justifyContent: 'flex-end', paddingBottom: spacing.sm },
|
||||
emptyList: { flexGrow: 1, justifyContent: 'center' },
|
||||
messageRow: { flexDirection: 'row', alignItems: 'flex-start', gap: isCompact ? 6 : spacing.sm, marginVertical: isCompact ? 3 : spacing.xs },
|
||||
messageRowUser: { flexDirection: 'row-reverse' },
|
||||
assistantBlock: { alignSelf: 'stretch', gap: isCompact ? 2 : spacing.xxs, marginVertical: isCompact ? 2 : spacing.xs },
|
||||
assistantText: { paddingHorizontal: 0 },
|
||||
userBlock: { alignSelf: 'flex-end', maxWidth: '88%', marginVertical: isCompact ? 4 : spacing.sm },
|
||||
userContent: { paddingHorizontal: isCompact ? 12 : spacing.md, paddingVertical: isCompact ? 6 : spacing.xs },
|
||||
userBubble: { backgroundColor: colors.inverse, borderRadius: radius.lg, maxWidth: '100%' },
|
||||
userMessageInlineWrap: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
flexWrap: 'wrap',
|
||||
gap: 4,
|
||||
},
|
||||
userMessageInlineText: {
|
||||
...t.body,
|
||||
fontSize: 15,
|
||||
color: colors.ink,
|
||||
lineHeight: 22,
|
||||
},
|
||||
avatar: { width: isCompact ? 28 : 32, height: isCompact ? 28 : 32, borderRadius: radius.md, alignItems: 'center', justifyContent: 'center' },
|
||||
avatarUser: { backgroundColor: colors.primary },
|
||||
avatarAssistant: { backgroundColor: colors.primarySoft },
|
||||
remoteAvatarLogo: { width: isCompact ? 28 : 32, height: isCompact ? 28 : 32 },
|
||||
messageBody: { flex: 1, maxWidth: '88%' },
|
||||
messageBodyUser: { alignItems: 'flex-end' },
|
||||
messageLabel: { ...t.caption, color: colors.muted, marginBottom: isCompact ? 2 : 4 },
|
||||
messageImages: { flexDirection: 'row', flexWrap: 'wrap', gap: spacing.xs, marginBottom: spacing.xs },
|
||||
messageImagesUser: { justifyContent: 'flex-end' },
|
||||
toolImages: { marginLeft: 32, marginRight: spacing.xs, marginBottom: spacing.sm },
|
||||
messageImage: { width: 132, height: 104, borderRadius: radius.md, backgroundColor: colors.surfaceStrong },
|
||||
messageImagePlaceholder: { width: 132, minHeight: 76, borderRadius: radius.md, backgroundColor: colors.primarySoft, alignItems: 'center', justifyContent: 'center', padding: spacing.sm, gap: spacing.xs },
|
||||
messageImageName: { ...t.caption, color: colors.primary, maxWidth: '100%' },
|
||||
reasoningCard: { alignSelf: 'stretch', borderRadius: radius.md, overflow: 'hidden' },
|
||||
reasoningHeader: { minHeight: 48, paddingHorizontal: spacing.xs, flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
reasoningHeaderPressed: { backgroundColor: colors.surfaceStrong },
|
||||
reasoningLabel: { ...t.smallStrong, color: colors.muted },
|
||||
reasoningLabelActive: { color: colors.accent },
|
||||
reasoningPreview: { ...t.small, color: colors.muted, flex: 1 },
|
||||
activitySeparator: { ...t.small, color: colors.subtle },
|
||||
reasoningBody: { backgroundColor: colors.surface, padding: isCompact ? 8 : spacing.sm, marginHorizontal: isCompact ? 4 : spacing.xs, marginBottom: isCompact ? 4 : spacing.xs, borderRadius: radius.sm },
|
||||
processGroup: { alignSelf: 'stretch', marginHorizontal: spacing.xs },
|
||||
activityGroup: { alignSelf: 'stretch' },
|
||||
processHeader: { minHeight: 48, flexDirection: 'row', alignItems: 'center', gap: spacing.xs, paddingHorizontal: 0, borderRadius: radius.md },
|
||||
processIcon: { width: 28, height: 28, alignItems: 'center', justifyContent: 'center' },
|
||||
processCurrent: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs, paddingHorizontal: spacing.xs, paddingBottom: spacing.xs },
|
||||
processCurrentText: { ...t.small, color: colors.muted, flex: 1 },
|
||||
processLabel: { ...t.small, color: colors.muted, flex: 1 },
|
||||
turnProcessHeader: { minHeight: 48, flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
turnProcessLabel: { ...t.small, color: colors.muted },
|
||||
activityReasoning: { paddingVertical: isCompact ? 4 : spacing.xs },
|
||||
processBody: { gap: 0, paddingVertical: 2 },
|
||||
streamingCursor: { width: 7, height: isCompact ? 14 : 16, backgroundColor: colors.accent, borderRadius: 2, marginTop: 3 },
|
||||
toolCard: { borderRadius: radius.md, overflow: 'hidden' },
|
||||
toolCardExpanded: { backgroundColor: colors.card },
|
||||
toolRow: { minHeight: isCompact ? 36 : 48, paddingHorizontal: spacing.xs, paddingVertical: isCompact ? 0 : spacing.xxs, flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
toolRowPressed: { backgroundColor: colors.surfaceStrong },
|
||||
toolIcon: { width: isCompact ? 20 : 24, height: isCompact ? 20 : 24, alignItems: 'center', justifyContent: 'center' },
|
||||
toolCopy: { flex: 1, minWidth: 0, flexDirection: 'row', alignItems: 'center', gap: 6 },
|
||||
toolName: { ...(isCompact ? t.caption : t.small), color: colors.muted, flexShrink: 1 },
|
||||
toolSummary: { ...(isCompact ? t.caption : t.small), color: colors.muted, flex: 1 },
|
||||
toolStateGroup: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
toolState: { ...t.caption, color: colors.success },
|
||||
toolFailed: { color: colors.danger },
|
||||
toolDetails: { borderTopWidth: StyleSheet.hairlineWidth, borderTopColor: colors.separator, padding: isCompact ? 8 : spacing.sm, gap: isCompact ? 8 : spacing.md },
|
||||
toolDetailBlock: { gap: isCompact ? 4 : spacing.xs },
|
||||
toolDetailLabel: { ...t.caption, color: colors.muted },
|
||||
toolDetailCode: { fontFamily: 'monospace', fontSize: isCompact ? 12 : 13, lineHeight: isCompact ? 17 : 20, color: colors.ink, backgroundColor: colors.surfaceStrong, borderRadius: radius.sm, padding: isCompact ? 6 : spacing.sm },
|
||||
toolDetailTruncated: { ...t.caption, color: colors.warning },
|
||||
permissionCard: { borderRadius: radius.lg, backgroundColor: colors.warningSoft, padding: spacing.md, gap: spacing.md, marginVertical: spacing.xs },
|
||||
questionCard: { borderRadius: radius.lg, backgroundColor: colors.accentSoft, padding: spacing.md, gap: spacing.md, marginVertical: spacing.xs },
|
||||
permissionHeader: { flexDirection: 'row', alignItems: 'center', gap: spacing.sm },
|
||||
permissionIcon: { width: 40, height: 40, borderRadius: radius.md, backgroundColor: colors.background, alignItems: 'center', justifyContent: 'center' },
|
||||
permissionHeaderCopy: { flex: 1 },
|
||||
permissionTitle: { ...t.bodyStrong, color: colors.ink },
|
||||
permissionKind: { ...t.small, color: colors.muted },
|
||||
permissionDetail: { backgroundColor: colors.background, borderRadius: radius.md, padding: spacing.sm },
|
||||
permissionCode: { fontFamily: 'monospace', fontSize: 14, lineHeight: 21, color: colors.ink },
|
||||
permissionText: { ...t.body, color: colors.ink },
|
||||
permissionScope: { ...t.caption, color: colors.muted },
|
||||
permissionActions: { gap: spacing.xs },
|
||||
permissionResolved: { borderRadius: radius.md, backgroundColor: colors.card, padding: spacing.sm, flexDirection: 'row', gap: spacing.xs, alignItems: 'center', marginVertical: spacing.xs },
|
||||
permissionResolvedText: { ...t.smallStrong, color: colors.ink },
|
||||
questionBlock: { gap: spacing.xs },
|
||||
questionText: { ...t.bodyStrong, color: colors.ink },
|
||||
queueDock: { borderWidth: StyleSheet.hairlineWidth, borderColor: colors.border, borderRadius: radius.md, backgroundColor: colors.card, padding: spacing.sm, marginBottom: spacing.sm, gap: spacing.xxs },
|
||||
queueDockHeader: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
queueDockTitle: { ...t.smallStrong, color: colors.ink },
|
||||
queueDockRow: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
queueDockText: { ...t.small, color: colors.muted, flex: 1 },
|
||||
resendRow: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs, minHeight: 44, paddingHorizontal: spacing.xs },
|
||||
resendRowPressed: { opacity: 0.6 },
|
||||
resendText: { ...t.small, color: colors.primary },
|
||||
canceledText: { ...t.small, color: colors.muted, paddingHorizontal: spacing.xs, minHeight: 44, textAlignVertical: 'center' },
|
||||
// maxHeight comes from usePickerListMaxHeight so landscape sheets fit.
|
||||
subagentList: { flexShrink: 1 },
|
||||
teamRowCopy: { flex: 1, gap: spacing.xxs },
|
||||
teamRowTitleLine: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs },
|
||||
teamRowRole: { ...t.smallStrong, color: colors.ink, flexShrink: 1 },
|
||||
teamRowTask: { ...t.small, color: colors.muted },
|
||||
subagentRow: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs, minHeight: 52, paddingVertical: spacing.xs, paddingHorizontal: spacing.xs, borderBottomWidth: StyleSheet.hairlineWidth, borderBottomColor: colors.border },
|
||||
subagentRunning: { ...t.smallStrong, color: colors.success },
|
||||
subagentRunningFailed: { ...t.smallStrong, color: colors.danger },
|
||||
subagentProvisioning: { ...t.smallStrong, color: colors.warning },
|
||||
subagentIdle: { ...t.small, color: colors.muted },
|
||||
stopButtonSmall: { width: 38, height: 38, borderRadius: 19, backgroundColor: colors.inverse, alignItems: 'center', justifyContent: 'center', marginRight: spacing.xs },
|
||||
resendRowDisabled: { opacity: 0.5 },
|
||||
resendTextMuted: { color: colors.muted },
|
||||
resendTextFailed: { color: colors.danger },
|
||||
questionCustom: { borderWidth: StyleSheet.hairlineWidth, borderColor: colors.border, borderRadius: radius.sm, paddingHorizontal: spacing.sm, paddingVertical: spacing.xs, color: colors.ink, marginBottom: spacing.xs, minHeight: 40 },
|
||||
questionDetail: { ...t.small, color: colors.muted },
|
||||
optionRow: { flexDirection: 'row', alignItems: 'center', gap: spacing.sm, padding: spacing.sm, borderRadius: radius.md, borderWidth: 1, borderColor: colors.border, backgroundColor: colors.background },
|
||||
optionChosen: { borderColor: colors.accent, backgroundColor: colors.accentSoft },
|
||||
optionDot: { width: 20, height: 20, borderRadius: radius.pill, borderWidth: 1.5, borderColor: colors.border, alignItems: 'center', justifyContent: 'center' },
|
||||
optionDotChosen: { borderColor: colors.accent, backgroundColor: colors.accent },
|
||||
optionLabel: { ...t.small, color: colors.ink, flex: 1 },
|
||||
optionDescription: { ...t.caption, color: colors.muted, marginTop: 2 },
|
||||
welcome: { alignItems: 'center', paddingHorizontal: spacing.lg },
|
||||
welcomeRow: { flexDirection: 'row', alignItems: 'center', gap: spacing.sm, marginTop: spacing.lg },
|
||||
welcomeSlogan: { ...t.title, fontSize: 24, lineHeight: 30, fontWeight: '600', letterSpacing: -0.4, color: colors.ink },
|
||||
welcomeBadge: { borderRadius: radius.pill, backgroundColor: colors.primarySoft, paddingHorizontal: spacing.sm, paddingVertical: 3, marginTop: 2 },
|
||||
welcomeBadgeText: { ...t.caption, fontWeight: '600', color: colors.primary },
|
||||
mentionBackdrop: { ...StyleSheet.absoluteFill, backgroundColor: colors.menuDismiss },
|
||||
composerWrap: { backgroundColor: colors.background, paddingHorizontal: spacing.md, paddingTop: spacing.xs, paddingBottom: spacing.xs },
|
||||
composerInner: { width: '100%' },
|
||||
|
||||
runningFooterWrap: { paddingHorizontal: spacing.lg, paddingTop: spacing.xs, paddingBottom: spacing.md },
|
||||
replyStatus: { minHeight: 32, flexDirection: 'row', alignItems: 'center', justifyContent: 'flex-start', gap: spacing.xs, paddingVertical: spacing.sm, borderTopWidth: StyleSheet.hairlineWidth, borderTopColor: colors.separator },
|
||||
replyStatusText: { ...t.small, color: colors.accent },
|
||||
replyDots: { flexDirection: 'row', alignItems: 'center', marginLeft: -spacing.xs },
|
||||
replyDot: { ...t.caption, fontSize: 18, lineHeight: 18, fontWeight: '700' },
|
||||
imageTray: { gap: spacing.xs, paddingBottom: spacing.xs },
|
||||
imagePreviewWrap: { width: 72, height: 72 },
|
||||
imagePreview: { width: 72, height: 72, borderRadius: radius.sm, backgroundColor: colors.surfaceStrong },
|
||||
removeImageButton: { position: 'absolute', right: -3, top: -3, width: 24, height: 24, borderRadius: radius.pill, backgroundColor: colors.ink, alignItems: 'center', justifyContent: 'center' },
|
||||
fileTray: { gap: spacing.xs, paddingBottom: spacing.xs },
|
||||
fileCard: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
gap: spacing.xs,
|
||||
paddingVertical: 6,
|
||||
paddingHorizontal: spacing.sm,
|
||||
borderRadius: radius.md,
|
||||
backgroundColor: colors.surfaceStrong,
|
||||
borderWidth: 1,
|
||||
borderColor: colors.border,
|
||||
maxWidth: 220,
|
||||
},
|
||||
fileCardMeta: { flexShrink: 1 },
|
||||
fileCardName: { ...t.caption, fontWeight: '600', color: colors.ink },
|
||||
fileCardSize: { ...t.caption, color: colors.muted },
|
||||
removeFileButton: {
|
||||
width: 20,
|
||||
height: 20,
|
||||
borderRadius: radius.pill,
|
||||
backgroundColor: colors.surface,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
marginLeft: 2,
|
||||
},
|
||||
composerCard: {
|
||||
borderWidth: StyleSheet.hairlineWidth,
|
||||
borderColor: colors.separator,
|
||||
borderRadius: radius.xxl,
|
||||
backgroundColor: colors.surface,
|
||||
paddingHorizontal: spacing.xs,
|
||||
paddingTop: spacing.xs,
|
||||
paddingBottom: spacing.xs,
|
||||
gap: spacing.xs,
|
||||
...floatingShadow(colors, 'high'),
|
||||
},
|
||||
composerExpandButton: {
|
||||
position: 'absolute',
|
||||
top: 6,
|
||||
right: 6,
|
||||
width: 32,
|
||||
height: 32,
|
||||
borderRadius: radius.pill,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
zIndex: 5,
|
||||
},
|
||||
expandedComposerOverlay: {
|
||||
...StyleSheet.absoluteFill,
|
||||
zIndex: 50,
|
||||
elevation: 50,
|
||||
},
|
||||
expandedComposerBackdrop: {
|
||||
height: 52,
|
||||
backgroundColor: colors.menuDismiss,
|
||||
},
|
||||
expandedComposerCard: {
|
||||
flex: 1,
|
||||
backgroundColor: colors.surface,
|
||||
borderTopLeftRadius: 28,
|
||||
borderTopRightRadius: 28,
|
||||
paddingHorizontal: spacing.md,
|
||||
paddingTop: spacing.xs,
|
||||
paddingBottom: spacing.sm,
|
||||
...floatingShadow(colors, 'high'),
|
||||
},
|
||||
expandedComposerHeader: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'flex-end',
|
||||
minHeight: 40,
|
||||
paddingHorizontal: spacing.xs,
|
||||
},
|
||||
expandedCollapseButton: {
|
||||
width: 36,
|
||||
height: 36,
|
||||
borderRadius: radius.pill,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
expandedQuotesWrap: {
|
||||
flexDirection: 'row',
|
||||
flexWrap: 'wrap',
|
||||
gap: 6,
|
||||
paddingHorizontal: spacing.xs,
|
||||
paddingBottom: spacing.xs,
|
||||
},
|
||||
expandedInputContainer: {
|
||||
flex: 1,
|
||||
paddingHorizontal: spacing.xs,
|
||||
paddingVertical: spacing.xs,
|
||||
},
|
||||
expandedTextInput: {
|
||||
...t.body,
|
||||
flex: 1,
|
||||
fontSize: 16,
|
||||
lineHeight: 24,
|
||||
color: colors.ink,
|
||||
textAlignVertical: 'top',
|
||||
padding: 0,
|
||||
},
|
||||
expandedFooter: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'flex-end',
|
||||
paddingHorizontal: spacing.xs,
|
||||
paddingVertical: spacing.xs,
|
||||
minHeight: 48,
|
||||
},
|
||||
runningComposer: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs, padding: spacing.xs },
|
||||
runningComposerPrompt: { flex: 1, minHeight: 44, justifyContent: 'center', minWidth: 0 },
|
||||
runningComposerText: { ...t.small, color: colors.muted },
|
||||
composerControls: { flexDirection: 'row', alignItems: 'center', gap: spacing.xs, paddingHorizontal: 4, paddingBottom: 2 },
|
||||
composerSpacer: { flex: 1 },
|
||||
// Keep the actual target at the Android 48dp minimum. hitSlop is not
|
||||
// reliable when a control sits inside a clipped/native text-input surface.
|
||||
plusButton: {
|
||||
width: 38,
|
||||
height: 38,
|
||||
borderRadius: radius.pill,
|
||||
backgroundColor: colors.surfaceStrong,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
quickPromptsButton: {
|
||||
height: 38,
|
||||
flexShrink: 0,
|
||||
paddingHorizontal: spacing.sm + 2,
|
||||
borderRadius: radius.pill,
|
||||
backgroundColor: colors.surfaceStrong,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
quickPromptsText: { ...t.small, fontSize: 14, color: colors.ink },
|
||||
plusPressed: { opacity: 0.7 },
|
||||
plusDisabled: { opacity: 0.52 },
|
||||
plusMenuOption: { flexDirection: 'row', alignItems: 'center', gap: spacing.sm, padding: spacing.md, borderRadius: radius.lg, backgroundColor: colors.card, borderWidth: StyleSheet.hairlineWidth, borderColor: colors.separator, marginBottom: spacing.xs },
|
||||
plusMenuOptionPressed: { backgroundColor: colors.surfaceStrong },
|
||||
plusMenuOptionDisabled: { opacity: 0.5 },
|
||||
plusMenuOptionText: { ...t.body, color: colors.ink, flex: 1 },
|
||||
plusCardRow: { flexDirection: 'row', gap: spacing.sm, marginBottom: spacing.xs },
|
||||
plusCard: { flex: 1, minHeight: 80, alignItems: 'center', justifyContent: 'center', gap: spacing.xs, paddingVertical: spacing.sm, paddingHorizontal: spacing.xxs, borderRadius: radius.xl, backgroundColor: colors.card, borderWidth: StyleSheet.hairlineWidth, borderColor: colors.separator },
|
||||
plusCardText: { ...t.smallStrong, color: colors.ink },
|
||||
plusMenuOptionValue: { minWidth: 0, flexShrink: 1, flexDirection: 'row', alignItems: 'center', gap: spacing.xxs },
|
||||
plusMenuOptionValueText: { ...t.small, color: colors.muted, flexShrink: 1 },
|
||||
modeLoading: { paddingVertical: spacing.lg, alignItems: 'center' },
|
||||
effortRow: { flexDirection: 'row', alignItems: 'center', justifyContent: 'space-between', gap: spacing.sm, paddingHorizontal: spacing.md, paddingVertical: spacing.sm, minHeight: 52, borderRadius: radius.lg, backgroundColor: colors.card, borderWidth: StyleSheet.hairlineWidth, borderColor: colors.separator, marginTop: spacing.xs },
|
||||
effortRowLabel: { ...t.smallStrong, color: colors.ink },
|
||||
effortRowValue: { ...t.small, color: colors.muted, flexShrink: 1 },
|
||||
composerInputWrap: {
|
||||
position: 'relative',
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
flexWrap: 'wrap',
|
||||
minHeight: 44,
|
||||
paddingHorizontal: spacing.sm,
|
||||
},
|
||||
composerInlineQuoteBadge: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
gap: 4,
|
||||
marginRight: 6,
|
||||
paddingVertical: 2,
|
||||
},
|
||||
composerInlineQuoteText: {
|
||||
fontSize: 16,
|
||||
fontWeight: '500',
|
||||
},
|
||||
messageQuotePreview: {
|
||||
marginBottom: spacing.xs,
|
||||
},
|
||||
assistantProseWrap: {
|
||||
position: 'relative',
|
||||
},
|
||||
floatingCalloutAnchor: {
|
||||
position: 'absolute',
|
||||
top: -46,
|
||||
left: 0,
|
||||
right: 0,
|
||||
zIndex: 999,
|
||||
alignItems: 'center',
|
||||
},
|
||||
assistantSelectableText: {
|
||||
...t.body,
|
||||
fontSize: 15,
|
||||
lineHeight: 23,
|
||||
padding: 0,
|
||||
margin: 0,
|
||||
},
|
||||
calloutBackdrop: {
|
||||
flex: 1,
|
||||
backgroundColor: 'rgba(0, 0, 0, 0.25)',
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
padding: spacing.md,
|
||||
},
|
||||
calloutMenu: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
backgroundColor: colors.surface,
|
||||
borderRadius: radius.md,
|
||||
borderWidth: StyleSheet.hairlineWidth,
|
||||
borderColor: colors.border,
|
||||
shadowColor: '#000',
|
||||
shadowOffset: { width: 0, height: 2 },
|
||||
shadowOpacity: 0.18,
|
||||
shadowRadius: 8,
|
||||
elevation: 8,
|
||||
paddingHorizontal: spacing.xs,
|
||||
height: 42,
|
||||
maxWidth: 320,
|
||||
},
|
||||
calloutBtn: {
|
||||
paddingHorizontal: spacing.sm,
|
||||
paddingVertical: 6,
|
||||
borderRadius: radius.sm,
|
||||
},
|
||||
calloutBtnPressed: {
|
||||
backgroundColor: colors.surfaceStrong,
|
||||
},
|
||||
calloutBtnText: {
|
||||
...t.small,
|
||||
color: colors.ink,
|
||||
fontWeight: '600',
|
||||
},
|
||||
calloutDivider: {
|
||||
width: StyleSheet.hairlineWidth,
|
||||
height: 16,
|
||||
backgroundColor: colors.separator,
|
||||
},
|
||||
|
||||
snippetModalBackdrop: {
|
||||
flex: 1,
|
||||
backgroundColor: 'rgba(0, 0, 0, 0.4)',
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
padding: spacing.md,
|
||||
},
|
||||
snippetModalCard: {
|
||||
width: '100%',
|
||||
maxWidth: 380,
|
||||
backgroundColor: colors.surface,
|
||||
borderRadius: radius.lg,
|
||||
borderWidth: StyleSheet.hairlineWidth,
|
||||
borderColor: colors.border,
|
||||
padding: spacing.md,
|
||||
shadowColor: '#000',
|
||||
shadowOffset: { width: 0, height: 4 },
|
||||
shadowOpacity: 0.15,
|
||||
shadowRadius: 16,
|
||||
elevation: 10,
|
||||
},
|
||||
snippetModalHeader: {
|
||||
flexDirection: 'row',
|
||||
justifyContent: 'space-between',
|
||||
alignItems: 'center',
|
||||
marginBottom: spacing.sm,
|
||||
},
|
||||
snippetHeaderLeft: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
gap: 6,
|
||||
},
|
||||
snippetModalTitle: {
|
||||
...t.bodyStrong,
|
||||
color: colors.ink,
|
||||
fontSize: 14,
|
||||
},
|
||||
snippetCloseBtn: {
|
||||
padding: 4,
|
||||
},
|
||||
snippetPreviewBox: {
|
||||
backgroundColor: colors.surfaceStrong,
|
||||
borderRadius: radius.md,
|
||||
padding: spacing.sm,
|
||||
marginBottom: spacing.sm,
|
||||
},
|
||||
snippetPreviewQuote: {
|
||||
...t.small,
|
||||
color: colors.primary,
|
||||
fontWeight: '500',
|
||||
lineHeight: 18,
|
||||
},
|
||||
snippetCharCount: {
|
||||
fontSize: 11,
|
||||
lineHeight: 14,
|
||||
color: colors.muted,
|
||||
marginTop: 4,
|
||||
textAlign: 'right',
|
||||
},
|
||||
snippetChipRow: {
|
||||
marginBottom: spacing.sm,
|
||||
},
|
||||
snippetChipScroll: {
|
||||
gap: 6,
|
||||
},
|
||||
snippetChip: {
|
||||
paddingHorizontal: spacing.sm,
|
||||
paddingVertical: 5,
|
||||
borderRadius: radius.pill,
|
||||
backgroundColor: colors.surfaceStrong,
|
||||
borderWidth: StyleSheet.hairlineWidth,
|
||||
borderColor: colors.border,
|
||||
},
|
||||
snippetChipActive: {
|
||||
backgroundColor: colors.primarySoft,
|
||||
borderColor: colors.primary,
|
||||
},
|
||||
snippetChipText: {
|
||||
fontSize: 11,
|
||||
lineHeight: 14,
|
||||
color: colors.muted,
|
||||
fontWeight: '500',
|
||||
},
|
||||
snippetChipTextActive: {
|
||||
color: colors.primary,
|
||||
fontWeight: '600',
|
||||
},
|
||||
snippetEditorWrap: {
|
||||
maxHeight: 140,
|
||||
backgroundColor: colors.surfaceStrong,
|
||||
borderRadius: radius.md,
|
||||
padding: spacing.sm,
|
||||
marginBottom: spacing.md,
|
||||
},
|
||||
snippetTextInput: {
|
||||
...t.small,
|
||||
color: colors.ink,
|
||||
lineHeight: 20,
|
||||
minHeight: 70,
|
||||
},
|
||||
snippetActionRow: {
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
gap: spacing.sm,
|
||||
},
|
||||
snippetCopyBtn: {
|
||||
flex: 1,
|
||||
height: 40,
|
||||
borderRadius: radius.md,
|
||||
borderWidth: StyleSheet.hairlineWidth,
|
||||
borderColor: colors.border,
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
gap: 6,
|
||||
backgroundColor: colors.surface,
|
||||
},
|
||||
snippetCopyBtnActive: {
|
||||
borderColor: colors.primary,
|
||||
backgroundColor: colors.primarySoft,
|
||||
},
|
||||
snippetCopyText: {
|
||||
...t.small,
|
||||
color: colors.ink,
|
||||
fontWeight: '500',
|
||||
},
|
||||
snippetAskBtn: {
|
||||
flex: 1.4,
|
||||
height: 40,
|
||||
borderRadius: radius.md,
|
||||
backgroundColor: colors.primary,
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
gap: 6,
|
||||
},
|
||||
snippetAskBtnDisabled: {
|
||||
opacity: 0.5,
|
||||
},
|
||||
snippetAskText: {
|
||||
...t.small,
|
||||
color: colors.white,
|
||||
fontWeight: '600',
|
||||
},
|
||||
|
||||
composerInput: { ...t.body, flex: 1, minWidth: 80, fontSize: 16, color: colors.ink, minHeight: 44, maxHeight: 126, paddingVertical: 10, paddingHorizontal: 0, textAlignVertical: 'top' },
|
||||
|
||||
sendButton: {
|
||||
width: 40,
|
||||
height: 40,
|
||||
borderRadius: radius.pill,
|
||||
backgroundColor: colors.primary,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
sendPressed: { backgroundColor: colors.primaryPressed },
|
||||
stopButton: {
|
||||
width: 40,
|
||||
height: 40,
|
||||
borderRadius: radius.pill,
|
||||
backgroundColor: colors.inverse,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
stopPressed: { opacity: 0.78 },
|
||||
sendDisabled: { backgroundColor: colors.surfaceStrong },
|
||||
composerHint: {
|
||||
...t.caption,
|
||||
fontSize: 11,
|
||||
lineHeight: 15,
|
||||
color: colors.muted,
|
||||
textAlign: 'center',
|
||||
marginTop: 5,
|
||||
},
|
||||
promptInputLabel: { ...t.caption, color: colors.muted, marginBottom: 4, marginTop: 4 },
|
||||
promptInput: { borderRadius: radius.md, borderWidth: 1, borderColor: colors.border, backgroundColor: colors.surface, color: colors.ink, paddingHorizontal: spacing.sm, paddingVertical: 8, ...t.body, minHeight: 40 },
|
||||
promptTextArea: { minHeight: 88, textAlignVertical: 'top' },
|
||||
lightboxBackdrop: {
|
||||
flex: 1,
|
||||
backgroundColor: 'rgba(0, 0, 0, 0.92)',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
lightboxImage: {
|
||||
width: '100%',
|
||||
height: '100%',
|
||||
},
|
||||
lightboxClose: {
|
||||
position: 'absolute',
|
||||
top: 50,
|
||||
right: 20,
|
||||
width: 44,
|
||||
height: 44,
|
||||
borderRadius: 22,
|
||||
backgroundColor: 'rgba(0, 0, 0, 0.65)',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
},
|
||||
})
|
||||
}
|
||||
Loading…
Reference in New Issue