fix(chat): add voice unlock payment choices

This commit is contained in:
2026-06-25 14:41:21 +08:00
parent 5879b7acf3
commit ffc3db9a91
7 changed files with 201 additions and 2 deletions
@@ -28,6 +28,7 @@ export interface MessageBubbleProps {
isUnlockingPrivate?: boolean;
onUnlockPrivateMessage?: (messageId: string) => void;
onUnlockImagePaywall?: () => void;
onUnlockVoiceMessage?: () => void;
}
export function MessageBubble({
@@ -44,6 +45,7 @@ export function MessageBubble({
isUnlockingPrivate,
onUnlockPrivateMessage,
onUnlockImagePaywall,
onUnlockVoiceMessage,
}: MessageBubbleProps) {
const { avatarUrl } = useUserState();
@@ -66,6 +68,7 @@ export function MessageBubble({
isUnlockingPrivate={isUnlockingPrivate}
onUnlockPrivateMessage={onUnlockPrivateMessage}
onUnlockImagePaywall={onUnlockImagePaywall}
onUnlockVoiceMessage={onUnlockVoiceMessage}
/>
<div style={{ width: 43 }} /> {/* 占位:保持与头像宽度一致 */}
</div>
@@ -89,6 +92,7 @@ export function MessageBubble({
isUnlockingPrivate={isUnlockingPrivate}
onUnlockPrivateMessage={onUnlockPrivateMessage}
onUnlockImagePaywall={onUnlockImagePaywall}
onUnlockVoiceMessage={onUnlockVoiceMessage}
/>
<div style={{ width: 8 }} />
<MessageAvatar isFromAI={false} userAvatarUrl={avatarUrl} />