Refactor MovieContent and MetadataScreen for improved metadata handling

This update removes the writer display from the MovieContent component to streamline the metadata presentation. Additionally, it modifies pointer event handling in the MetadataScreen to ensure proper interaction based on the availability of metadata, enhancing user experience during content loading and display.
This commit is contained in:
tapframe 2025-06-20 13:48:49 +05:30
parent d88962ae01
commit c9db098b0e
2 changed files with 3 additions and 9 deletions

View file

@ -23,13 +23,7 @@ export const MovieContent: React.FC<MovieContentProps> = ({ metadata }) => {
</View>
)}
{metadata.writer && metadata.writer.length > 0 && (
<View style={styles.metadataRow}>
<Text style={[styles.metadataLabel, { color: currentTheme.colors.textMuted }]}>Writer:</Text>
<Text style={[styles.metadataValue, { color: currentTheme.colors.text }]}>{Array.isArray(metadata.writer) ? metadata.writer.join(', ') : metadata.writer}</Text>
</View>
)}
{hasCast && (
<View style={styles.metadataRow}>
<Text style={[styles.metadataLabel, { color: currentTheme.colors.textMuted }]}>Cast:</Text>

View file

@ -305,7 +305,7 @@ const MetadataScreen: React.FC = () => {
{showSkeleton && (
<Animated.View
style={[StyleSheet.absoluteFill, skeletonStyle]}
pointerEvents={isContentReady ? 'none' : 'auto'}
pointerEvents={metadata ? 'none' : 'auto'}
>
<MetadataLoadingScreen type={metadata?.type === 'movie' ? 'movie' : 'series'} />
</Animated.View>
@ -315,7 +315,7 @@ const MetadataScreen: React.FC = () => {
{metadata && (
<Animated.View
style={[StyleSheet.absoluteFill, transitionStyle]}
pointerEvents={isContentReady ? 'auto' : 'none'}
pointerEvents={metadata ? 'auto' : 'none'}
>
<SafeAreaView
style={[containerStyle, styles.container, { backgroundColor: currentTheme.colors.darkBackground }]}