fix: error

This commit is contained in:
imeepos
2025-10-29 19:38:04 +08:00
parent 3a99ff96d5
commit 30ea4fb13c
34 changed files with 2185 additions and 870 deletions

View File

@@ -1,7 +1,8 @@
import { VideoPlayer } from '@/components/video/video-player';
import { FullscreenMediaModal } from '@/components/media/fullscreen-media-modal';
import { VideoPlayer } from '@/components/video/video-player';
import { useThemeColor } from '@/hooks/use-theme-color';
import { Template } from '@/lib/types/template';
import { isVideoTemplate } from '@/utils/media-utils';
import { ResizeMode } from 'expo-av';
import { Image } from 'expo-image';
import { useRouter } from 'expo-router';
@@ -9,7 +10,6 @@ import { useMemo, useState } from 'react';
import { Platform, StyleSheet, TouchableOpacity, View } from 'react-native';
import { ThemedText } from '../themed-text';
import { ThemedView } from '../themed-view';
import { isVideoTemplate, canLoadMedia } from '@/utils/media-utils';
interface TemplateCardProps {
template: Template;
@@ -109,7 +109,7 @@ export function TemplateCard({
)}
{template.category && (
<View style={styles.watermark}>
<View style={styles.watermark} className='template-category'>
<View style={styles.categoryBadge}>
<ThemedText style={styles.categoryText}>
{template.category.name}
@@ -119,7 +119,7 @@ export function TemplateCard({
)}
{template.tags.length > 0 && (
<View style={styles.tagOverlay}>
<View style={styles.tagOverlay} className='template-tags'>
{template.tags.slice(0, 2).map((tag) => (
<View key={tag.id} style={styles.tagBadge}>
<ThemedText style={styles.tagText}>
@@ -131,7 +131,6 @@ export function TemplateCard({
)}
</ThemedView>
</View>
{/* 操作按钮区域 */}
<View style={styles.actionArea}>
<ThemedText style={styles.templateTitle} numberOfLines={1}>

View File

@@ -1,9 +1,9 @@
import { StyleSheet, FlatList, ActivityIndicator, RefreshControl, View } from 'react-native';
import { useThemeColor } from '@/hooks/use-theme-color';
import { Template } from '@/lib/types/template';
import { ActivityIndicator, FlatList, RefreshControl, StyleSheet, View } from 'react-native';
import { ThemedText } from '../themed-text';
import { ThemedView } from '../themed-view';
import { Template } from '@/lib/types/template';
import { TemplateCard } from './template-card';
import { useThemeColor } from '@/hooks/use-theme-color';
interface TemplateListProps {
templates: Template[];