@zezosoft/react-player 0.0.2 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,25 +1,74 @@
1
1
  import Hls from "hls.js";
2
+ import { Dispatch, SetStateAction } from "react";
2
3
  interface VideoState {
3
4
  videoRef: HTMLVideoElement | null;
4
5
  setVideoRef: (ref: HTMLVideoElement) => void;
6
+ playing: boolean | ((prevState: boolean) => boolean);
7
+ setPlaying: Dispatch<SetStateAction<boolean>>;
5
8
  videoWrapperRef: HTMLDivElement | null;
6
9
  setVideoWrapperRef: (ref: HTMLDivElement) => void;
10
+ isBuffering?: boolean;
11
+ setIsBuffering: (isBuffering: boolean) => void;
7
12
  isPlaying: boolean;
8
13
  setIsPlaying: (isPlaying: boolean) => void;
14
+ muted: boolean;
15
+ setMuted: (muted: boolean) => void;
16
+ volume: number;
17
+ setVolume: (volume: number) => void;
9
18
  controls: boolean;
10
19
  setControls: (controls: boolean) => void;
11
20
  currentTime: number;
12
21
  setCurrentTime: (currentTime: number) => void;
22
+ duration: number;
23
+ setDuration: (duration: number) => void;
24
+ isFullscreen: boolean;
25
+ setIsFullscreen: (isFullscreen: boolean) => void;
13
26
  hlsInstance?: Hls;
14
27
  setHlsInstance: (hlsInstance: Hls) => void;
15
28
  qualityLevels?: Hls["levels"];
16
29
  setQualityLevels: (qualityLevels: Hls["levels"]) => void;
17
30
  activeQuality?: string;
18
31
  setActiveQuality: (activeQuality: string) => void;
19
- isFullscreen?: boolean;
20
- setIsFullscreen: (isFullscreen: boolean) => void;
21
- duration?: number;
22
- setDuration: (duration: number) => void;
32
+ activeSubtitle?: {
33
+ lang: string;
34
+ label: string;
35
+ url: string;
36
+ } | null;
37
+ setActiveSubtitle: (subtitle: {
38
+ lang: string;
39
+ label: string;
40
+ url: string;
41
+ } | null) => void;
42
+ subtitles: {
43
+ lang: string;
44
+ label: string;
45
+ url: string;
46
+ }[];
47
+ setSubtitles: (subtitles: {
48
+ lang: string;
49
+ label: string;
50
+ url: string;
51
+ }[]) => void;
52
+ showIntroSkip: boolean;
53
+ setShowIntroSkip: (show: boolean) => void;
54
+ autoPlayNext: boolean;
55
+ setAutoPlayNext: (value: boolean) => void;
56
+ episodeList: {
57
+ id: number;
58
+ title: string;
59
+ url: string;
60
+ }[];
61
+ setEpisodeList: (list: {
62
+ id: number;
63
+ title: string;
64
+ url: string;
65
+ }[]) => void;
66
+ currentEpisodeIndex: number;
67
+ setCurrentEpisodeIndex: (index: number) => void;
68
+ showCountdown: boolean;
69
+ setShowCountdown: (show: boolean) => void;
70
+ countdownTime: number;
71
+ setCountdownTime: (time: number) => void;
23
72
  }
24
73
  export declare const useVideoStore: import("zustand").UseBoundStore<import("zustand").StoreApi<VideoState>>;
25
74
  export {};
package/package.json CHANGED
@@ -1,17 +1,16 @@
1
1
  {
2
2
  "name": "@zezosoft/react-player",
3
- "version": "0.0.2",
3
+ "version": "0.0.4",
4
4
  "main": "dist/index.js",
5
5
  "type": "module",
6
6
  "types": "dist/index.d.ts",
7
- "scripts": {
8
- "build": "npx rollup -c",
9
- "dev": "npx rollup -c -w",
10
- "prepare": "npm run build"
11
- },
12
7
  "files": [
13
8
  "dist"
14
9
  ],
10
+ "repository": {
11
+ "type": "git",
12
+ "url": "git+https://github.com/Zezo-Soft/react-player.git"
13
+ },
15
14
  "keywords": [
16
15
  "video",
17
16
  "player",
@@ -21,8 +20,10 @@
21
20
  "react-video",
22
21
  "react-video-player",
23
22
  "react-video-component",
24
- "react-video-component",
25
- "react-video-component"
23
+ "ZezoOTT",
24
+ "Zezo",
25
+ "Zezosoft",
26
+ "streaming"
26
27
  ],
27
28
  "author": "Pukhraj Dhamu",
28
29
  "license": "MIT",
@@ -31,6 +32,7 @@
31
32
  "@rollup/plugin-typescript": "^12.1.2",
32
33
  "@tailwindcss/postcss": "^4.0.14",
33
34
  "@types/react": "^19.0.10",
35
+ "@types/node": "^24.4.0",
34
36
  "hls.js": "^1.5.20",
35
37
  "lucide-react": "^0.481.0",
36
38
  "postcss": "^8.5.3",
@@ -48,5 +50,12 @@
48
50
  "react": "^19.0.0",
49
51
  "react-dom": "^19.0.0",
50
52
  "zustand": "^5.0.3"
53
+ },
54
+ "dependencies": {
55
+ "react-icons": "^5.5.0"
56
+ },
57
+ "scripts": {
58
+ "build": "npx rollup -c",
59
+ "dev": "npx rollup -c -w"
51
60
  }
52
- }
61
+ }