Socket
Book a DemoInstallSign in
Socket

@zezosoft/zezo-ott-react-native-video-player

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zezosoft/zezo-ott-react-native-video-player

React Native OTT Video Player for Android & iOS. Supports playlists, seasons, auto-next playback, subtitles, theming, analytics, fullscreen mode, and custom controls. πŸš€ Powered by ZezoSoft.

1.0.0
latest
Source
npmnpm
Version published
Weekly downloads
7
-89.86%
Maintainers
1
Weekly downloads
Β 
Created
Source

🎬 ZezoOTT Video Player

The ZezoOTT Video Player is a powerful React Native component crafted for OTT platforms.
It delivers a seamless full-screen video playback experience, powered by a centralized VideoPlayer Store for state management.

✨ Features

  • πŸ“Ί Episode navigation & Seasons support
  • πŸ“Š Watch progress tracking & analytics
  • 🎨 Custom theming
  • πŸ”„ Auto-next playback
  • 🎬 Playlist & seasons integration
  • πŸ—„οΈ Centralized store for playback state, tracks & UI
  • πŸ“± Optimized for React Native OTT apps
  • πŸ›  Minimal configuration, production-ready

πŸ“¦ Installation

yarn add @zezosoft/zezo-ott-react-native-video-player

or

npm install @zezosoft/zezo-ott-react-native-video-player

βš™οΈ VideoPlayer Props

PropTypeDescription
onClose() => voidTriggered when the player is closed.
isFocusedbooleanControls playback focus. Automatically pauses when the screen is not active.
seekTimenumber | nullStarts playback from a given time (in seconds).
mode'fullscreen' | 'normal'Sets the display mode of the player.
onSeek(time: number) => voidFired when the user manually seeks to a new playback position.
autoNextbooleanAutomatically plays the next episode/video after completion.
event{ onPressEpisode?: ({ episode }: { episode: MediaEpisode }) => Promise<boolean> }Event hooks (e.g. custom handling for episode selection).
themePartial<VideoPlayerTheme>Customize the look & feel of the player (colors, metrics, etc.).
onWatchProgress(progress: ExtendedWatchProgress) => voidReports playback analytics such as watch time, current time, and completion.

πŸš€ Usage Examples

▢️ Basic Example

import React from 'react';
import { VideoPlayer } from '@zezosoft/zezo-ott-react-native-video-player';

export default function App() {
  return (
    <VideoPlayer
      isFocused={true}
      onClose={() => console.log('Player closed')}
      autoNext={true}
      onWatchProgress={(progress) => {
        console.log('Watch Progress:', progress);
      }}
    />
  );
}

πŸ”„ Auto-Next Episodes

<VideoPlayer
  autoNext={true}
  event={{
    onPressEpisode: async ({ episode }) => {
      console.log('Next episode:', episode.title);
      return true; // return false to block playback
    },
  }}
/>

🎨 Theming Example

<VideoPlayer
  theme={{
    colors: {
      primary: '#E50914',
      background: '#000000',
      onBackground: '#FFFFFF',
    },
    metrics: {
      controlButtonSize: 42,
    },
  }}
/>

πŸ“Ί Playlist & Seasons Setup

// ContentDetailsScreen.tsx
import { useVideoPlayerStore } from '@zezosoft/zezo-ott-react-native-video-player';
import { useNavigation } from '@react-navigation/native';

export default function ContentDetailsScreen({ contentData }) {
  const {
    resetStore,
    setPlayList,
    setContentSeasons,
    setActiveSeason,
    setCurrentTrackIndex,
    setActiveTrack,
  } = useVideoPlayerStore();
  const navigation = useNavigation();

  const handlePlay = () => {
    resetStore();
    setContentSeasons(contentData.seasons);
    setActiveSeason(contentData.seasons[0]);

    const playlist = contentData.seasons[0].episodes.map((ep) => ({
      id: ep.id,
      title: ep.name,
      contentId: contentData.id,
      sourceLink: ep.sourceLink,
      type: contentData.type,
    }));

    setPlayList(playlist);
    setCurrentTrackIndex(0);
    setActiveTrack(playlist[0]);

    navigation.navigate('VideoPlayerScreen');
  };

  return <Button title="Play" onPress={handlePlay} />;
}
// VideoPlayerScreen.tsx
import { VideoPlayer } from '@zezosoft/zezo-ott-react-native-video-player';

export default function VideoPlayerScreen() {
  return <VideoPlayer isFocused={true} autoNext={true} />;
}

πŸ—„οΈ Video Player Store

The VideoPlayerStore is a centralized state store that powers the ZezoOTT Video Player.
It manages playback state, tracks, UI controls, analytics, and content navigation.

πŸš€ Store Features

  • Manage playback state: current time, duration, buffering, playback rate
  • Handle tracks: audio, subtitles, video quality
  • Control UI state: controls visibility, settings modal, skip/next episode
  • Track content structure: playlists, seasons, active season/episode
  • Support analytics: watch time, view count, error handling

⚑ Store Usage Example

import { useVideoPlayerStore } from '@zezosoft/zezo-ott-react-native-video-player';
import React from 'react';

export default function VideoPlayerExample() {
  const {
    setPlayList,
    setActiveSeason,
    setActiveTrack,
    setContentSeasons,
    setCurrentTrackIndex,
    resetStore,
    playList,
    activeTrack,
    activeSeason,
  } = useVideoPlayerStore();

  const contentData = {
    id: 'movie123',
    type: 'series',
    name: 'My Series',
    seasons: [
      {
        id: 'season1',
        name: 'Season 1',
        seasonNumber: 1,
        episodes: [
          {
            id: 'ep1',
            name: 'Episode 1',
            sourceLink: 'https://example.com/ep1.mp4',
          },
          {
            id: 'ep2',
            name: 'Episode 2',
            sourceLink: 'https://example.com/ep2.mp4',
          },
        ],
      },
    ],
  };

  const setupPlayer = () => {
    resetStore();
    setContentSeasons(contentData.seasons);
    setActiveSeason(contentData.seasons[0]);

    const playlist = contentData.seasons[0].episodes.map((ep) => ({
      id: ep.id,
      title: ep.name,
      contentId: contentData.id,
      sourceLink: ep.sourceLink,
      type: contentData.type,
    }));

    setPlayList(playlist);
    setCurrentTrackIndex(0);
    setActiveTrack(playlist[0]);
  };

  return (
    <div>
      <button onClick={setupPlayer}>Load Series</button>
      <h3>Active Season: {activeSeason?.name}</h3>
      <ul>
        {playList.map((track) => (
          <li key={track.id}>
            {track.title} {activeTrack?.id === track.id ? '(Playing)' : ''}
          </li>
        ))}
      </ul>
    </div>
  );
}

πŸ“ Notes & Best Practices

  • πŸ”„ Always call resetStore() before loading new content.
  • 🎚️ Playback rate requires both rate and label in sync.
  • πŸ•ΉοΈ Controls auto-hide is managed by controlsTimer.
  • 🌐 Track selections depend on available OnLoadData β€” always null-check.
  • πŸ“Š Analytics props integrate with your analytics pipeline.
  • ⚠️ Error handling: Use setError for surfacing playback issues.
  • 🎬 Seasons & episodes: Update both contentSeasons and activeSeason before setting playlist.

πŸ“Œ Fullscreen Notes

If fullscreen doesn’t work, ensure you install react-native-orientation-locker:

yarn add react-native-orientation-locker
# or
npm install react-native-orientation-locker

πŸ”— Known issues: react-native-orientation-locker issues

πŸ”— Demo App

πŸ‘‰ Zezo OTT Demo App

πŸ‘¨β€πŸ’» Developer

Made with passion by:

Naresh Dhamu
Naresh Dhamu

πŸ“„ License

Licensed under the MIT License.

⚑ Powered by ZezoSoft

Keywords

react-native

FAQs

Package last updated on 20 Aug 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚑️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.