@xiping/react-components 1.0.45 → 1.0.49
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.
- package/dist/cjs/_virtual/_commonjsHelpers.js +1 -0
- package/dist/cjs/_virtual/delegate.js +1 -0
- package/dist/cjs/_virtual/download.js +1 -0
- package/dist/cjs/_virtual/download2.js +1 -0
- package/dist/cjs/_virtual/index.js +1 -0
- package/dist/cjs/_virtual/index2.js +1 -0
- package/dist/cjs/components/subtitle-player/SubtitlePlayer.d.ts +21 -0
- package/dist/cjs/components/subtitle-player/SubtitlePlayer.js +3 -3
- package/dist/cjs/components/video-subtitle-player/VideoSubtitlePlayer.d.ts +23 -0
- package/dist/cjs/components/video-subtitle-player/VideoSubtitlePlayer.js +1 -0
- package/dist/cjs/components/video-subtitle-player/index.d.ts +3 -0
- package/dist/cjs/components/video-subtitle-player/useVideoSubtitleStore.d.ts +61 -0
- package/dist/cjs/components/video-subtitle-player/useVideoSubtitleStore.js +1 -0
- package/dist/cjs/index.d.ts +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/node_modules/.pnpm/delegate@3.2.0/node_modules/delegate/src/closest.js +1 -0
- package/dist/cjs/node_modules/.pnpm/delegate@3.2.0/node_modules/delegate/src/delegate.js +1 -0
- package/dist/cjs/node_modules/.pnpm/downloadjs@1.4.7/node_modules/downloadjs/download.js +3 -0
- package/dist/cjs/node_modules/.pnpm/eventemitter3@4.0.7/node_modules/eventemitter3/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/_virtual/_rollupPluginBabelHelpers.js +2 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/constant.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/defaultConfig.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/error.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/events.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/index.umd.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/instManager.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/lang/en.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/lang/i18n.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/lang/zh-cn.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/mediaProxy.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/player.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/basePlugin.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/hooksDescriptor.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/plugin.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/pluginsManager.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/preset.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/resizeObserver.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/back.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/download.js +15 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/exitCssFull.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/exitFull.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/loading.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/pause.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/pipIcon.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/pipIconExit.js +8 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/play.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/playNext.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/replay.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/requestCssFull.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/requestFull.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/rotate.js +12 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/seekicon.js +7 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/volumeLarge.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/volumeMuted.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/volumeSmall.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/iconPlugin.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/iconTools.js +3 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/optionList.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/optionsIcon.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/thumbnail.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/controls/index.js +9 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/cssFullScreen/index.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/definition/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/download/index.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/dynamicBg/index.js +2 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/enter/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/error/index.js +6 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/fpsDetect/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/fullscreen/backicon.js +2 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/fullscreen/index.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/gapJump/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/keyboard/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/loading/index.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/logger/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/miniScreen/index.js +13 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/miniScreen/miniScreenIcon.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/mobile/index.js +19 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/mobile/touch.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/pc/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/pip/index.js +8 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/play/index.js +5 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/playNext/index.js +7 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/playbackRate/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/poster/index.js +2 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progress/index.js +7 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progress/innerList.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progress/miniProgress.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progressPreview/dotsApi.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progressPreview/index.js +11 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/prompt/index.js +3 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/replay/index.js +3 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/rotate/index.js +6 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/screenShot/index.js +6 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/start/index.js +4 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/stats/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/testspeed/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/time/index.js +6 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/time/timesegments.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/volume/index.js +11 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/waitingTimeoutJump/index.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/presets/default.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/state.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/stateClassMap.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/database.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/debug.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/draggabilly.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/sniffer.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/util.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/xgplayerTimeRange.js +1 -0
- package/dist/cjs/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/version.js +1 -0
- package/dist/cjs/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/react.js +1 -0
- package/dist/cjs/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/vanilla.js +1 -0
- package/dist/cjs/packages/subtitle/lib/src/json-converter.js +1 -0
- package/dist/cjs/react-components.css +1 -1
- package/dist/es/_virtual/_commonjsHelpers.js +6 -0
- package/dist/es/_virtual/delegate.js +7 -0
- package/dist/es/_virtual/download.js +7 -0
- package/dist/es/_virtual/download2.js +4 -0
- package/dist/es/_virtual/index.js +8 -0
- package/dist/es/_virtual/index2.js +4 -0
- package/dist/es/components/subtitle-player/SubtitlePlayer.d.ts +21 -0
- package/dist/es/components/subtitle-player/SubtitlePlayer.js +274 -76
- package/dist/es/components/txt-editor/TxtEditor.js +4 -1
- package/dist/es/components/video-subtitle-player/VideoSubtitlePlayer.d.ts +23 -0
- package/dist/es/components/video-subtitle-player/VideoSubtitlePlayer.js +125 -0
- package/dist/es/components/video-subtitle-player/index.d.ts +3 -0
- package/dist/es/components/video-subtitle-player/useVideoSubtitleStore.d.ts +61 -0
- package/dist/es/components/video-subtitle-player/useVideoSubtitleStore.js +57 -0
- package/dist/es/index.d.ts +1 -1
- package/dist/es/index.js +60 -58
- package/dist/es/node_modules/.pnpm/delegate@3.2.0/node_modules/delegate/src/closest.js +21 -0
- package/dist/es/node_modules/.pnpm/delegate@3.2.0/node_modules/delegate/src/delegate.js +29 -0
- package/dist/es/node_modules/.pnpm/downloadjs@1.4.7/node_modules/downloadjs/download.js +77 -0
- package/dist/es/node_modules/.pnpm/eventemitter3@4.0.7/node_modules/eventemitter3/index.js +111 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/_virtual/_rollupPluginBabelHelpers.js +197 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/constant.js +7 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/defaultConfig.js +87 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/error.js +64 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/events.js +67 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/index.umd.js +45 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/instManager.js +101 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/lang/en.js +79 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/lang/i18n.js +75 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/lang/zh-cn.js +79 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/mediaProxy.js +466 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/player.js +1240 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/basePlugin.js +207 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/hooksDescriptor.js +130 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/plugin.js +366 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/pluginsManager.js +204 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/preset.js +14 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugin/resizeObserver.js +81 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/back.js +10 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/download.js +20 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/exitCssFull.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/exitFull.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/loading.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/pause.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/pipIcon.js +10 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/pipIconExit.js +13 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/play.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/playNext.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/replay.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/requestCssFull.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/requestFull.js +9 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/rotate.js +17 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/seekicon.js +12 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/volumeLarge.js +10 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/volumeMuted.js +10 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/assets/volumeSmall.js +10 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/iconPlugin.js +35 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/iconTools.js +12 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/optionList.js +79 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/optionsIcon.js +193 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/common/thumbnail.js +141 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/controls/index.js +171 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/cssFullScreen/index.js +105 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/definition/index.js +110 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/download/index.js +83 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/dynamicBg/index.js +232 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/enter/index.js +42 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/error/index.js +68 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/fpsDetect/index.js +116 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/fullscreen/backicon.js +68 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/fullscreen/index.js +150 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/gapJump/index.js +96 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/keyboard/index.js +299 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/loading/index.js +46 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/logger/index.js +171 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/miniScreen/index.js +169 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/miniScreen/miniScreenIcon.js +55 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/mobile/index.js +448 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/mobile/touch.js +138 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/pc/index.js +122 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/pip/index.js +216 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/play/index.js +102 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/playNext/index.js +78 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/playbackRate/index.js +100 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/poster/index.js +119 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progress/index.js +431 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progress/innerList.js +215 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progress/miniProgress.js +93 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progressPreview/dotsApi.js +175 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/progressPreview/index.js +292 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/prompt/index.js +86 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/replay/index.js +92 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/rotate/index.js +106 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/screenShot/index.js +134 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/start/index.js +222 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/stats/index.js +152 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/testspeed/index.js +134 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/time/index.js +164 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/time/timesegments.js +146 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/volume/index.js +206 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/plugins/waitingTimeoutJump/index.js +53 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/presets/default.js +61 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/state.js +13 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/stateClassMap.js +34 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/database.js +83 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/debug.js +34 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/draggabilly.js +271 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/sniffer.js +111 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/util.js +517 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/utils/xgplayerTimeRange.js +25 -0
- package/dist/es/node_modules/.pnpm/xgplayer@3.0.23_core-js@3.47.0/node_modules/xgplayer/es/version.js +4 -0
- package/dist/es/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/react.js +19 -0
- package/dist/es/node_modules/.pnpm/zustand@5.0.9_@types_react@19.2.7_react@19.2.3_use-sync-external-store@1.6.0_react@19.2.3_/node_modules/zustand/esm/vanilla.js +14 -0
- package/dist/es/packages/subtitle/lib/src/json-converter.js +27 -0
- package/dist/es/react-components.css +1 -1
- package/package.json +19 -21
- package/dist/cjs/components/qr-code/index.d.ts +0 -103
- package/dist/cjs/components/qr-code/index.js +0 -1
- package/dist/es/components/qr-code/index.d.ts +0 -103
- package/dist/es/components/qr-code/index.js +0 -49
- /package/dist/cjs/{subtitle → packages/subtitle}/lib/src/parser.js +0 -0
- /package/dist/es/{subtitle → packages/subtitle}/lib/src/parser.js +0 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { inherits as a, createSuper as c, classCallCheck as u, createClass as l } from "../../_virtual/_rollupPluginBabelHelpers.js";
|
|
2
|
+
import o from "../../utils/util.js";
|
|
3
|
+
import h, { POSITIONS as f } from "../../plugin/plugin.js";
|
|
4
|
+
import k from "../assets/back.js";
|
|
5
|
+
var v = /* @__PURE__ */ (function(r) {
|
|
6
|
+
a(t, r);
|
|
7
|
+
var s = c(t);
|
|
8
|
+
function t() {
|
|
9
|
+
return u(this, t), s.apply(this, arguments);
|
|
10
|
+
}
|
|
11
|
+
return l(t, [{
|
|
12
|
+
key: "afterCreate",
|
|
13
|
+
value: function() {
|
|
14
|
+
var n = this;
|
|
15
|
+
this.initIcons(), this.onClick = function(i) {
|
|
16
|
+
i.preventDefault(), i.stopPropagation(), n.config.onClick(i);
|
|
17
|
+
}, this.bind(["click", "touchend"], this.onClick);
|
|
18
|
+
}
|
|
19
|
+
}, {
|
|
20
|
+
key: "registerIcons",
|
|
21
|
+
value: function() {
|
|
22
|
+
return {
|
|
23
|
+
screenBack: {
|
|
24
|
+
icon: k,
|
|
25
|
+
class: "xg-fullscreen-back"
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
}, {
|
|
30
|
+
key: "initIcons",
|
|
31
|
+
value: function() {
|
|
32
|
+
var n = this.icons;
|
|
33
|
+
this.appendChild(this.root, n.screenBack);
|
|
34
|
+
}
|
|
35
|
+
}, {
|
|
36
|
+
key: "show",
|
|
37
|
+
value: function() {
|
|
38
|
+
o.addClass(this.root, "show");
|
|
39
|
+
}
|
|
40
|
+
}, {
|
|
41
|
+
key: "hide",
|
|
42
|
+
value: function() {
|
|
43
|
+
o.removeClass(this.root, "show");
|
|
44
|
+
}
|
|
45
|
+
}, {
|
|
46
|
+
key: "render",
|
|
47
|
+
value: function() {
|
|
48
|
+
return `<xg-icon class="xgplayer-back">
|
|
49
|
+
</xg-icon>`;
|
|
50
|
+
}
|
|
51
|
+
}], [{
|
|
52
|
+
key: "pluginName",
|
|
53
|
+
get: function() {
|
|
54
|
+
return "topbackicon";
|
|
55
|
+
}
|
|
56
|
+
}, {
|
|
57
|
+
key: "defaultConfig",
|
|
58
|
+
get: function() {
|
|
59
|
+
return {
|
|
60
|
+
position: f.ROOT_TOP,
|
|
61
|
+
index: 0
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
}]), t;
|
|
65
|
+
})(h);
|
|
66
|
+
export {
|
|
67
|
+
v as default
|
|
68
|
+
};
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
import { inherits as p, createSuper as d, classCallCheck as y, defineProperty as C, assertThisInitialized as k, createClass as m, get as f, getPrototypeOf as h } from "../../_virtual/_rollupPluginBabelHelpers.js";
|
|
2
|
+
import v from "../../utils/util.js";
|
|
3
|
+
import a from "../../utils/sniffer.js";
|
|
4
|
+
import { FULLSCREEN_CHANGE as F } from "../../events.js";
|
|
5
|
+
import { POSITIONS as S } from "../../plugin/plugin.js";
|
|
6
|
+
import { xgIconTips as I } from "../common/iconTools.js";
|
|
7
|
+
import x from "../common/iconPlugin.js";
|
|
8
|
+
import T from "./backicon.js";
|
|
9
|
+
import w from "../assets/requestFull.js";
|
|
10
|
+
import E from "../assets/exitFull.js";
|
|
11
|
+
var D = /* @__PURE__ */ (function(g) {
|
|
12
|
+
p(l, g);
|
|
13
|
+
var o = d(l);
|
|
14
|
+
function l() {
|
|
15
|
+
var n;
|
|
16
|
+
y(this, l);
|
|
17
|
+
for (var e = arguments.length, t = new Array(e), i = 0; i < e; i++)
|
|
18
|
+
t[i] = arguments[i];
|
|
19
|
+
return n = o.call.apply(o, [this].concat(t)), C(k(n), "_onOrientationChange", function(c) {
|
|
20
|
+
n.player.fullscreen && n.config.rotateFullscreen && (window.orientation === 90 || window.orientation === -90 ? n.player.setRotateDeg(0) : n.player.setRotateDeg(90));
|
|
21
|
+
}), n;
|
|
22
|
+
}
|
|
23
|
+
return m(l, [{
|
|
24
|
+
key: "afterCreate",
|
|
25
|
+
value: function() {
|
|
26
|
+
var e = this;
|
|
27
|
+
f(h(l.prototype), "afterCreate", this).call(this);
|
|
28
|
+
var t = this.config, i = this.playerConfig;
|
|
29
|
+
if (!t.disable) {
|
|
30
|
+
t.target && (this.playerConfig.fullscreenTarget = this.config.target);
|
|
31
|
+
var c = v.getFullScreenEl();
|
|
32
|
+
i.fullscreenTarget === c && this.player.getFullscreen().catch(function(r) {
|
|
33
|
+
}), this.initIcons(), this.handleFullscreen = this.hook("fullscreenChange", this.toggleFullScreen, {
|
|
34
|
+
pre: function(s) {
|
|
35
|
+
var u = e.player.fullscreen;
|
|
36
|
+
e.emitUserAction(s, "switch_fullscreen", {
|
|
37
|
+
prop: "fullscreen",
|
|
38
|
+
from: u,
|
|
39
|
+
to: !u
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
}), this.bind(".xgplayer-fullscreen", ["touchend", "click"], this.handleFullscreen), this.on(F, function(r) {
|
|
43
|
+
var s = e.find(".xg-tips");
|
|
44
|
+
s && e.changeLangTextKey(s, r ? e.i18nKeys.EXITFULLSCREEN_TIPS : e.i18nKeys.FULLSCREEN_TIPS), e.animate(r);
|
|
45
|
+
}), this.config.needBackIcon && (this.topBackIcon = this.player.registerPlugin({
|
|
46
|
+
plugin: T,
|
|
47
|
+
options: {
|
|
48
|
+
config: {
|
|
49
|
+
onClick: function(s) {
|
|
50
|
+
e.handleFullscreen(s);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
})), a.device === "mobile" && window.addEventListener("orientationchange", this._onOrientationChange);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}, {
|
|
58
|
+
key: "registerIcons",
|
|
59
|
+
value: function() {
|
|
60
|
+
return {
|
|
61
|
+
fullscreen: {
|
|
62
|
+
icon: w,
|
|
63
|
+
class: "xg-get-fullscreen"
|
|
64
|
+
},
|
|
65
|
+
exitFullscreen: {
|
|
66
|
+
icon: E,
|
|
67
|
+
class: "xg-exit-fullscreen"
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
}, {
|
|
72
|
+
key: "destroy",
|
|
73
|
+
value: function() {
|
|
74
|
+
f(h(l.prototype), "destroy", this).call(this), this.unbind(".xgplayer-icon", a.device === "mobile" ? "touchend" : "click", this.handleFullscreen), a.device === "mobile" && window.removeEventListener("orientationchange", this._onOrientationChange);
|
|
75
|
+
}
|
|
76
|
+
}, {
|
|
77
|
+
key: "initIcons",
|
|
78
|
+
value: function() {
|
|
79
|
+
var e = this.icons;
|
|
80
|
+
this.appendChild(".xgplayer-icon", e.fullscreen), this.appendChild(".xgplayer-icon", e.exitFullscreen);
|
|
81
|
+
}
|
|
82
|
+
}, {
|
|
83
|
+
key: "toggleFullScreen",
|
|
84
|
+
value: function(e) {
|
|
85
|
+
e instanceof Event && (e.preventDefault(), e.stopPropagation());
|
|
86
|
+
var t = this.player, i = this.config, c = i.useCssFullscreen === !0 || typeof i.useCssFullscreen == "function" && i.useCssFullscreen();
|
|
87
|
+
c ? (t.fullscreen ? t.exitCssFullscreen() : t.getCssFullscreen(), this.animate(t.fullscreen)) : i.rotateFullscreen ? (t.fullscreen ? t.exitRotateFullscreen() : t.getRotateFullscreen(), this.animate(t.fullscreen)) : i.switchCallback && typeof i.switchCallback == "function" ? i.switchCallback(t.fullscreen) : t.fullscreen ? (t.exitFullscreen(), i.useScreenOrientation && this.unlockScreen()) : (t.getFullscreen().catch(function(r) {
|
|
88
|
+
}), i.useScreenOrientation && t.aspectRatio > 1 && this.lockScreen(i.lockOrientationType));
|
|
89
|
+
}
|
|
90
|
+
}, {
|
|
91
|
+
key: "animate",
|
|
92
|
+
value: function(e) {
|
|
93
|
+
e ? this.setAttr("data-state", "full") : this.setAttr("data-state", "normal"), this.topBackIcon && (e ? (this.topBackIcon.show(), this.hide()) : (this.topBackIcon.hide(), this.show()));
|
|
94
|
+
}
|
|
95
|
+
}, {
|
|
96
|
+
key: "render",
|
|
97
|
+
value: function() {
|
|
98
|
+
if (!this.config.disable) {
|
|
99
|
+
var e = "FULLSCREEN_TIPS";
|
|
100
|
+
return `<xg-icon class="xgplayer-fullscreen">
|
|
101
|
+
<div class="xgplayer-icon">
|
|
102
|
+
</div>
|
|
103
|
+
`.concat(I(this, e, this.playerConfig.isHideTips), `
|
|
104
|
+
</xg-icon>`);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}, {
|
|
108
|
+
key: "lockScreen",
|
|
109
|
+
value: function(e) {
|
|
110
|
+
try {
|
|
111
|
+
screen.orientation.lock(e).catch(function(t) {
|
|
112
|
+
});
|
|
113
|
+
} catch {
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}, {
|
|
117
|
+
key: "unlockScreen",
|
|
118
|
+
value: function() {
|
|
119
|
+
try {
|
|
120
|
+
screen.orientation.unlock().catch(function(e) {
|
|
121
|
+
});
|
|
122
|
+
} catch {
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}], [{
|
|
126
|
+
key: "pluginName",
|
|
127
|
+
get: function() {
|
|
128
|
+
return "fullscreen";
|
|
129
|
+
}
|
|
130
|
+
}, {
|
|
131
|
+
key: "defaultConfig",
|
|
132
|
+
get: function() {
|
|
133
|
+
return {
|
|
134
|
+
position: S.CONTROLS_RIGHT,
|
|
135
|
+
index: 0,
|
|
136
|
+
useCssFullscreen: !1,
|
|
137
|
+
rotateFullscreen: !1,
|
|
138
|
+
useScreenOrientation: !1,
|
|
139
|
+
lockOrientationType: "landscape",
|
|
140
|
+
switchCallback: null,
|
|
141
|
+
target: null,
|
|
142
|
+
disable: !1,
|
|
143
|
+
needBackIcon: !1
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
}]), l;
|
|
147
|
+
})(x);
|
|
148
|
+
export {
|
|
149
|
+
D as default
|
|
150
|
+
};
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { inherits as _, createSuper as y, classCallCheck as E, defineProperty as S, assertThisInitialized as c, createClass as k } from "../../_virtual/_rollupPluginBabelHelpers.js";
|
|
2
|
+
import { WAITING as C, PLAY as I, SEEKING as P } from "../../events.js";
|
|
3
|
+
import J from "../../plugin/plugin.js";
|
|
4
|
+
var R = /* @__PURE__ */ (function(v) {
|
|
5
|
+
_(s, v);
|
|
6
|
+
var m = y(s);
|
|
7
|
+
function s() {
|
|
8
|
+
var a;
|
|
9
|
+
E(this, s);
|
|
10
|
+
for (var e = arguments.length, i = new Array(e), r = 0; r < e; r++)
|
|
11
|
+
i[r] = arguments[r];
|
|
12
|
+
return a = m.call.apply(m, [this].concat(i)), S(c(a), "onGapJump", function() {
|
|
13
|
+
var u = c(a), t = u.player, n = u.config;
|
|
14
|
+
if (t.media.readyState !== HTMLMediaElement.HAVE_NOTHING) {
|
|
15
|
+
if (t.media.seeking) {
|
|
16
|
+
if (!a.seekingEventReceived)
|
|
17
|
+
return;
|
|
18
|
+
} else
|
|
19
|
+
a.seekingEventReceived = !1;
|
|
20
|
+
if (!(t.media.paused && t.media.currentTime !== 0 && a.hasPlayed)) {
|
|
21
|
+
var l = t.media.buffered, h = n.smallGapLimit || 0.5, G = n.gapDetectionThreshold || 0.3, p = t.media.currentTime, o = a._getIndex(l, p, G);
|
|
22
|
+
if (!(o === null || o === 0)) {
|
|
23
|
+
console.log("GapJump bufferRange ", l.start(o), l.end(o));
|
|
24
|
+
var f = l.start(o) + 0.1, T = t.media.duration;
|
|
25
|
+
if (!(f > T)) {
|
|
26
|
+
var d = f - p, g = d <= h;
|
|
27
|
+
d < s.BROWSER_GAP_TOLERANCE || g && (n.useGapJump !== !1 && (t.media.currentTime = a.isSafari ? f + 0.1 : f), a.player && a.player.emit("detectGap"), console.log("gapJump gapIndex", o, " isGapSamll:", g, " currentTime:", t.media.currentTime, " jumpSize:", p - t.media.currentTime), f !== 0.08 && t && t.emit("log", {
|
|
28
|
+
type: "oneevent",
|
|
29
|
+
end_type: "gap",
|
|
30
|
+
vid: t.config.vid,
|
|
31
|
+
ext: {
|
|
32
|
+
video_postion: Math.floor(f * 1e3)
|
|
33
|
+
}
|
|
34
|
+
}));
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}), a;
|
|
40
|
+
}
|
|
41
|
+
return k(s, [{
|
|
42
|
+
key: "afterCreate",
|
|
43
|
+
value: function() {
|
|
44
|
+
var e = this, i = this.config.useGapJump;
|
|
45
|
+
i !== !1 && (this.hasPlayed = !1, this.seekingEventReceived = !1, this.isSafari = /(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent) && !/Chrome/.test(navigator.userAgent) && !/BlackBerry/.test(navigator.platform), this.on(C, this.onGapJump), this.on(I, function() {
|
|
46
|
+
e.hasPlayed = !0;
|
|
47
|
+
}), this.on(P, function() {
|
|
48
|
+
e.seekingEventReceived = !0;
|
|
49
|
+
}));
|
|
50
|
+
}
|
|
51
|
+
}, {
|
|
52
|
+
key: "_getIndex",
|
|
53
|
+
value: function(e, i, r) {
|
|
54
|
+
if (!e || !e.length || e.length === 1 && e.end(0) - e.start(0) < 1e-6)
|
|
55
|
+
return null;
|
|
56
|
+
for (var u = this._getBuffered(e), t = null, n = 0; n < u.length; n++) {
|
|
57
|
+
var l = u[n];
|
|
58
|
+
if (l.start > i && (n === 0 || u[n - 1].end - i <= r)) {
|
|
59
|
+
t = n;
|
|
60
|
+
break;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
return t;
|
|
64
|
+
}
|
|
65
|
+
}, {
|
|
66
|
+
key: "_getBuffered",
|
|
67
|
+
value: function(e) {
|
|
68
|
+
if (!e)
|
|
69
|
+
return [];
|
|
70
|
+
for (var i = [], r = 0; r < e.length; r++)
|
|
71
|
+
i.push({
|
|
72
|
+
start: e.start(r),
|
|
73
|
+
end: e.end(r)
|
|
74
|
+
});
|
|
75
|
+
return i;
|
|
76
|
+
}
|
|
77
|
+
}], [{
|
|
78
|
+
key: "pluginName",
|
|
79
|
+
get: function() {
|
|
80
|
+
return "gapJump";
|
|
81
|
+
}
|
|
82
|
+
}, {
|
|
83
|
+
key: "defaultConfig",
|
|
84
|
+
get: function() {
|
|
85
|
+
return {
|
|
86
|
+
useGapJump: !1,
|
|
87
|
+
smallGapLimit: 0.5,
|
|
88
|
+
gapDetectionThreshold: 0.3
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
}]), s;
|
|
92
|
+
})(J);
|
|
93
|
+
R.BROWSER_GAP_TOLERANCE = 1e-3;
|
|
94
|
+
export {
|
|
95
|
+
R as default
|
|
96
|
+
};
|
|
@@ -0,0 +1,299 @@
|
|
|
1
|
+
import { inherits as C, createSuper as K, classCallCheck as w, defineProperty as v, assertThisInitialized as d, createClass as T, objectSpread2 as S } from "../../_virtual/_rollupPluginBabelHelpers.js";
|
|
2
|
+
import m from "../../utils/util.js";
|
|
3
|
+
import { SHORTCUT as _ } from "../../events.js";
|
|
4
|
+
import B from "../../plugin/basePlugin.js";
|
|
5
|
+
import "../../../../../../../../_virtual/delegate.js";
|
|
6
|
+
function D(c) {
|
|
7
|
+
c.preventDefault(), c.returnValue = !1;
|
|
8
|
+
}
|
|
9
|
+
function g(c) {
|
|
10
|
+
var h = c.tagName;
|
|
11
|
+
return !!(h === "INPUT" || h === "TEXTAREA" || c.isContentEditable);
|
|
12
|
+
}
|
|
13
|
+
var M = /* @__PURE__ */ (function(c) {
|
|
14
|
+
C(k, c);
|
|
15
|
+
var h = K(k);
|
|
16
|
+
function k() {
|
|
17
|
+
var t;
|
|
18
|
+
w(this, k);
|
|
19
|
+
for (var i = arguments.length, e = new Array(i), a = 0; a < i; a++)
|
|
20
|
+
e[a] = arguments[a];
|
|
21
|
+
return t = h.call.apply(h, [this].concat(e)), v(d(t), "onBodyKeyDown", function(r) {
|
|
22
|
+
if (t.player) {
|
|
23
|
+
var s = r || window.event, n = s.keyCode, l = d(t), o = l._keyState, y = l.player, u = t.config, p = u.disable, f = u.disableBodyTrigger, b = u.isIgnoreUserActive;
|
|
24
|
+
if (p || f || !(y.isUserActive || b) || g(s.target) || !t.checkIsVisible() || s.metaKey || s.altKey || s.ctrlKey) {
|
|
25
|
+
o.isBodyKeyDown = !1;
|
|
26
|
+
return;
|
|
27
|
+
}
|
|
28
|
+
!r.repeat && !o.isKeyDown && ((s.target === document.body || t.config.isGlobalTrigger && !g(s.target)) && t.checkCode(n, !0) && (o.isBodyKeyDown = !0), document.addEventListener("keyup", t.onBodyKeyUp)), o.isBodyKeyDown && t.handleKeyDown(s);
|
|
29
|
+
}
|
|
30
|
+
}), v(d(t), "onBodyKeyUp", function(r) {
|
|
31
|
+
t.player && (document.removeEventListener("keyup", t.onBodyKeyUp), t.handleKeyUp(r));
|
|
32
|
+
}), v(d(t), "onKeydown", function(r) {
|
|
33
|
+
if (t.player) {
|
|
34
|
+
var s = r || window.event, n = d(t), l = n._keyState;
|
|
35
|
+
if (!s.repeat) {
|
|
36
|
+
if (t.config.disable || t.config.disableRootTrigger || s.metaKey || s.altKey || s.ctrlKey)
|
|
37
|
+
return;
|
|
38
|
+
s && (s.keyCode === 37 || t.checkCode(s.keyCode)) && (s.target === t.player.root || s.target === t.player.video || s.target === t.player.controls.el) && (l.isKeyDown = !0), t.player.root.addEventListener("keyup", t.onKeyup);
|
|
39
|
+
}
|
|
40
|
+
l.isKeyDown && t.handleKeyDown(s);
|
|
41
|
+
}
|
|
42
|
+
}), v(d(t), "onKeyup", function(r) {
|
|
43
|
+
t.player && (t.player.root.removeEventListener("keyup", t.onKeyup), t.handleKeyUp(r));
|
|
44
|
+
}), t;
|
|
45
|
+
}
|
|
46
|
+
return T(k, [{
|
|
47
|
+
key: "mergekeyCodeMap",
|
|
48
|
+
value: function() {
|
|
49
|
+
var i = this, e = this.config.keyCodeMap;
|
|
50
|
+
e && Object.keys(e).map(function(a) {
|
|
51
|
+
i.keyCodeMap[a] ? ["keyCode", "action", "disable", "pressAction", "disablePress", "isBodyTarget"].map(function(r) {
|
|
52
|
+
e[a][r] && (i.keyCodeMap[a][r] = e[a][r]);
|
|
53
|
+
}) : i.keyCodeMap[a] = e[a];
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
}, {
|
|
57
|
+
key: "afterCreate",
|
|
58
|
+
value: function() {
|
|
59
|
+
this.config.disable = !this.playerConfig.keyShortcut;
|
|
60
|
+
var i = typeof this.config.seekStep == "function" ? this.config.seekStep(this.player) : this.config.seekStep;
|
|
61
|
+
!i || typeof i != "number" || (this.seekStep = i), this.keyCodeMap = {
|
|
62
|
+
space: {
|
|
63
|
+
keyCode: 32,
|
|
64
|
+
action: "playPause",
|
|
65
|
+
disable: !1,
|
|
66
|
+
disablePress: !1,
|
|
67
|
+
noBodyTarget: !1
|
|
68
|
+
},
|
|
69
|
+
up: {
|
|
70
|
+
keyCode: 38,
|
|
71
|
+
action: "upVolume",
|
|
72
|
+
disable: !1,
|
|
73
|
+
disablePress: !1,
|
|
74
|
+
noBodyTarget: !0
|
|
75
|
+
},
|
|
76
|
+
down: {
|
|
77
|
+
keyCode: 40,
|
|
78
|
+
action: "downVolume",
|
|
79
|
+
disable: !1,
|
|
80
|
+
disablePress: !1,
|
|
81
|
+
noBodyTarget: !0
|
|
82
|
+
},
|
|
83
|
+
left: {
|
|
84
|
+
keyCode: 37,
|
|
85
|
+
action: "seekBack",
|
|
86
|
+
disablePress: !1,
|
|
87
|
+
disable: !1
|
|
88
|
+
},
|
|
89
|
+
right: {
|
|
90
|
+
keyCode: 39,
|
|
91
|
+
action: "seek",
|
|
92
|
+
pressAction: "changePlaybackRate",
|
|
93
|
+
disablePress: !1,
|
|
94
|
+
disable: !1
|
|
95
|
+
},
|
|
96
|
+
esc: {
|
|
97
|
+
keyCode: 27,
|
|
98
|
+
action: "exitFullscreen",
|
|
99
|
+
disablePress: !0,
|
|
100
|
+
disable: !1
|
|
101
|
+
}
|
|
102
|
+
}, this.mergekeyCodeMap(), this._keyState = {
|
|
103
|
+
isKeyDown: !1,
|
|
104
|
+
isBodyKeyDown: !1,
|
|
105
|
+
isPress: !1,
|
|
106
|
+
tt: 0,
|
|
107
|
+
playbackRate: 0
|
|
108
|
+
}, this.player.root.addEventListener("keydown", this.onKeydown), document.addEventListener("keydown", this.onBodyKeyDown);
|
|
109
|
+
}
|
|
110
|
+
}, {
|
|
111
|
+
key: "setConfig",
|
|
112
|
+
value: function(i) {
|
|
113
|
+
var e = this;
|
|
114
|
+
Object.keys(i).forEach(function(a) {
|
|
115
|
+
e.config[a] = i[a];
|
|
116
|
+
});
|
|
117
|
+
}
|
|
118
|
+
}, {
|
|
119
|
+
key: "checkIsVisible",
|
|
120
|
+
value: function() {
|
|
121
|
+
if (!this.config.checkVisible)
|
|
122
|
+
return !0;
|
|
123
|
+
var i = this.player.root.getBoundingClientRect(), e = i.height, a = i.top, r = i.bottom, s = window.innerHeight;
|
|
124
|
+
return !(a < 0 && a < 0 - e * 0.9 || r > 0 && r - s > e * 0.9);
|
|
125
|
+
}
|
|
126
|
+
}, {
|
|
127
|
+
key: "checkCode",
|
|
128
|
+
value: function(i, e) {
|
|
129
|
+
var a = this, r = !1;
|
|
130
|
+
return Object.keys(this.keyCodeMap).map(function(s) {
|
|
131
|
+
a.keyCodeMap[s] && i === a.keyCodeMap[s].keyCode && !a.keyCodeMap[s].disable && (r = !e || e && !a.keyCodeMap[s].noBodyTarget);
|
|
132
|
+
}), r;
|
|
133
|
+
}
|
|
134
|
+
}, {
|
|
135
|
+
key: "downVolume",
|
|
136
|
+
value: function(i) {
|
|
137
|
+
var e = this.player;
|
|
138
|
+
if (!(e.volume <= 0)) {
|
|
139
|
+
var a = parseFloat((e.volume - 0.1).toFixed(1)), r = {
|
|
140
|
+
volume: {
|
|
141
|
+
from: e.volume,
|
|
142
|
+
to: a
|
|
143
|
+
}
|
|
144
|
+
};
|
|
145
|
+
this.emitUserAction(i, "change_volume", {
|
|
146
|
+
props: r
|
|
147
|
+
}), a >= 0 ? e.volume = a : e.volume = 0;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
}, {
|
|
151
|
+
key: "upVolume",
|
|
152
|
+
value: function(i) {
|
|
153
|
+
var e = this.player;
|
|
154
|
+
if (!(e.volume >= 1)) {
|
|
155
|
+
var a = parseFloat((e.volume + 0.1).toFixed(1)), r = {
|
|
156
|
+
volume: {
|
|
157
|
+
from: e.volume,
|
|
158
|
+
to: a
|
|
159
|
+
}
|
|
160
|
+
};
|
|
161
|
+
this.emitUserAction(i, "change_volume", {
|
|
162
|
+
props: r
|
|
163
|
+
}), a <= 1 ? e.volume = a : e.volume = 1;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}, {
|
|
167
|
+
key: "seek",
|
|
168
|
+
value: function(i) {
|
|
169
|
+
var e = this.player, a = e.currentTime, r = e.offsetCurrentTime, s = e.duration, n = e.offsetDuration, l = e.timeSegments, o = r > -1 ? r : a, y = n || s, u = i.repeat && this.seekStep >= 4 ? parseInt(this.seekStep / 2, 10) : this.seekStep;
|
|
170
|
+
o + u <= y ? o = o + u : o = y;
|
|
171
|
+
var p = m.getCurrentTimeByOffset(o, l), f = {
|
|
172
|
+
currentTime: {
|
|
173
|
+
from: a,
|
|
174
|
+
to: p
|
|
175
|
+
}
|
|
176
|
+
};
|
|
177
|
+
this.emitUserAction(i, "seek", {
|
|
178
|
+
props: f
|
|
179
|
+
}), this.player.currentTime = p;
|
|
180
|
+
}
|
|
181
|
+
}, {
|
|
182
|
+
key: "seekBack",
|
|
183
|
+
value: function(i) {
|
|
184
|
+
var e = this.player, a = e.currentTime, r = e.offsetCurrentTime, s = e.timeSegments, n = i.repeat ? parseInt(this.seekStep / 2, 10) : this.seekStep, l = r > -1 ? r : a, o = l - n;
|
|
185
|
+
o < 0 && (o = 0), o = m.getCurrentTimeByOffset(o, s);
|
|
186
|
+
var y = {
|
|
187
|
+
currentTime: {
|
|
188
|
+
from: a,
|
|
189
|
+
to: o
|
|
190
|
+
}
|
|
191
|
+
};
|
|
192
|
+
this.emitUserAction(i, "seek", {
|
|
193
|
+
props: y
|
|
194
|
+
}), this.player.currentTime = o;
|
|
195
|
+
}
|
|
196
|
+
}, {
|
|
197
|
+
key: "changePlaybackRate",
|
|
198
|
+
value: function(i) {
|
|
199
|
+
var e = this._keyState, a = this.config, r = this.player;
|
|
200
|
+
e.playbackRate === 0 && (e.playbackRate = r.playbackRate, r.playbackRate = a.playbackRate);
|
|
201
|
+
}
|
|
202
|
+
}, {
|
|
203
|
+
key: "playPause",
|
|
204
|
+
value: function(i) {
|
|
205
|
+
var e = this.player;
|
|
206
|
+
e && (this.emitUserAction(i, "switch_play_pause"), e.paused ? e.play() : e.pause());
|
|
207
|
+
}
|
|
208
|
+
}, {
|
|
209
|
+
key: "exitFullscreen",
|
|
210
|
+
value: function(i) {
|
|
211
|
+
var e = this.player, a = e.fullscreen, r = e.cssfullscreen;
|
|
212
|
+
a && (this.emitUserAction("keyup", "switch_fullscreen", {
|
|
213
|
+
prop: "fullscreen",
|
|
214
|
+
from: a,
|
|
215
|
+
to: !a
|
|
216
|
+
}), e.exitFullscreen()), r && (this.emitUserAction("keyup", "switch_css_fullscreen", {
|
|
217
|
+
prop: "cssfullscreen",
|
|
218
|
+
from: r,
|
|
219
|
+
to: !r
|
|
220
|
+
}), e.exitCssFullscreen());
|
|
221
|
+
}
|
|
222
|
+
}, {
|
|
223
|
+
key: "handleKeyDown",
|
|
224
|
+
value: function(i) {
|
|
225
|
+
var e = this._keyState;
|
|
226
|
+
if (i.repeat) {
|
|
227
|
+
e.isPress = !0;
|
|
228
|
+
var a = Date.now();
|
|
229
|
+
if (a - e.tt < 200)
|
|
230
|
+
return;
|
|
231
|
+
e.tt = a;
|
|
232
|
+
}
|
|
233
|
+
this.handleKeyCode(i.keyCode, i, e.isPress);
|
|
234
|
+
}
|
|
235
|
+
}, {
|
|
236
|
+
key: "handleKeyUp",
|
|
237
|
+
value: function(i) {
|
|
238
|
+
var e = this._keyState;
|
|
239
|
+
e.playbackRate > 0 && (this.player.playbackRate = e.playbackRate, e.playbackRate = 0), e.isKeyDown = !1, e.isPress = !1, e.tt = 0;
|
|
240
|
+
}
|
|
241
|
+
}, {
|
|
242
|
+
key: "handleKeyCode",
|
|
243
|
+
value: function(i, e, a) {
|
|
244
|
+
for (var r = Object.keys(this.keyCodeMap), s = 0; s < r.length; s++) {
|
|
245
|
+
var n = this.keyCodeMap[r[s]], l = n.action, o = n.keyCode, y = n.disable, u = n.pressAction, p = n.disablePress;
|
|
246
|
+
if (o === i) {
|
|
247
|
+
if (!y && !(a && p)) {
|
|
248
|
+
var f = a && u || l;
|
|
249
|
+
typeof f == "function" ? l(e, this.player, a) : typeof f == "string" && typeof this[f] == "function" && this[f](e, this.player, a), this.emit(_, S({
|
|
250
|
+
key: r[s],
|
|
251
|
+
target: e.target,
|
|
252
|
+
isPress: a
|
|
253
|
+
}, this.keyCodeMap[r[s]]));
|
|
254
|
+
}
|
|
255
|
+
D(e), e.stopPropagation();
|
|
256
|
+
break;
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
}, {
|
|
261
|
+
key: "destroy",
|
|
262
|
+
value: function() {
|
|
263
|
+
this.player.root.removeEventListener("keydown", this.onKeydown), document.removeEventListener("keydown", this.onBodyKeyDown), this.player.root.removeEventListener("keyup", this.onKeyup), document.removeEventListener("keyup", this.onBodyKeyUp);
|
|
264
|
+
}
|
|
265
|
+
}, {
|
|
266
|
+
key: "disable",
|
|
267
|
+
value: function() {
|
|
268
|
+
this.config.disable = !0;
|
|
269
|
+
}
|
|
270
|
+
}, {
|
|
271
|
+
key: "enable",
|
|
272
|
+
value: function() {
|
|
273
|
+
this.config.disable = !1;
|
|
274
|
+
}
|
|
275
|
+
}], [{
|
|
276
|
+
key: "pluginName",
|
|
277
|
+
get: function() {
|
|
278
|
+
return "keyboard";
|
|
279
|
+
}
|
|
280
|
+
}, {
|
|
281
|
+
key: "defaultConfig",
|
|
282
|
+
get: function() {
|
|
283
|
+
return {
|
|
284
|
+
seekStep: 10,
|
|
285
|
+
checkVisible: !1,
|
|
286
|
+
disableBodyTrigger: !1,
|
|
287
|
+
disableRootTrigger: !1,
|
|
288
|
+
isGlobalTrigger: !0,
|
|
289
|
+
keyCodeMap: {},
|
|
290
|
+
disable: !1,
|
|
291
|
+
playbackRate: 2,
|
|
292
|
+
isIgnoreUserActive: !0
|
|
293
|
+
};
|
|
294
|
+
}
|
|
295
|
+
}]), k;
|
|
296
|
+
})(B);
|
|
297
|
+
export {
|
|
298
|
+
M as default
|
|
299
|
+
};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { inherits as i, createSuper as t, classCallCheck as o, createClass as s } from "../../_virtual/_rollupPluginBabelHelpers.js";
|
|
2
|
+
import l, { POSITIONS as g } from "../../plugin/plugin.js";
|
|
3
|
+
import u from "../assets/loading.js";
|
|
4
|
+
var p = /* @__PURE__ */ (function(r) {
|
|
5
|
+
i(e, r);
|
|
6
|
+
var a = t(e);
|
|
7
|
+
function e() {
|
|
8
|
+
return o(this, e), a.apply(this, arguments);
|
|
9
|
+
}
|
|
10
|
+
return s(e, [{
|
|
11
|
+
key: "registerIcons",
|
|
12
|
+
value: function() {
|
|
13
|
+
return {
|
|
14
|
+
loadingIcon: u
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
}, {
|
|
18
|
+
key: "afterCreate",
|
|
19
|
+
value: function() {
|
|
20
|
+
this.appendChild("xg-loading-inner", this.icons.loadingIcon);
|
|
21
|
+
}
|
|
22
|
+
}, {
|
|
23
|
+
key: "render",
|
|
24
|
+
value: function() {
|
|
25
|
+
return `
|
|
26
|
+
<xg-loading class="xgplayer-loading">
|
|
27
|
+
<xg-loading-inner></xg-loading-inner>
|
|
28
|
+
</xg-loading>`;
|
|
29
|
+
}
|
|
30
|
+
}], [{
|
|
31
|
+
key: "pluginName",
|
|
32
|
+
get: function() {
|
|
33
|
+
return "loading";
|
|
34
|
+
}
|
|
35
|
+
}, {
|
|
36
|
+
key: "defaultConfig",
|
|
37
|
+
get: function() {
|
|
38
|
+
return {
|
|
39
|
+
position: g.ROOT
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
}]), e;
|
|
43
|
+
})(l);
|
|
44
|
+
export {
|
|
45
|
+
p as default
|
|
46
|
+
};
|