diff --git a/README.md b/README.md index 6d9633a5..d56e3be5 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ - https://oplayer.vercel.app - https://ohplayer.netlify.app -- [Standalone Demo](https://oplayer.vercel.app/ohls.html?playlist=%5B%7B"title"%3A"Disney%27s+Oceans+-+MP4"%2C"src"%3A"%2F%2Fvjs.zencdn.net%2Fv%2Foceans.mp4"%2C"poster"%3A"%2F%2Fvjs.zencdn.net%2Fv%2Foceans.png"%2C"duration"%3A"00%3A46"%7D%2C%7B"title"%3A"Big+Buck+Bunny+-+HLS"%2C"src"%3A"https%3A%2F%2Ftest-streams.mux.dev%2Fx36xhzz%2Fx36xhzz.m3u8"%2C"poster"%3A"https%3A%2F%2Fd2zihajmogu5jn.cloudfront.net%2Fbig-buck-bunny%2Fbbb.png"%2C"duration"%3A"10%3A34"%7D%2C%7B"title"%3A"Big+Buck+Bunny+-+DASH"%2C"src"%3A"https%3A%2F%2Fdash.akamaized.net%2Fakamai%2Fbbb_30fps%2Fbbb_30fps.mpd"%2C"poster"%3A"https%3A%2F%2Fd2zihajmogu5jn.cloudfront.net%2Fbig-buck-bunny%2Fbbb.png"%2C"duration"%3A"10%3A34"%7D%5D) +- [Standalone Demo](https://oplayer.vercel.app/ohls.html?playlist=%5B%7B"title"%3A"Disney%27s+Oceans+-+MP4"%2C"src"%3A"https%3A%2F%2Fvjs.zencdn.net%2Fv%2Foceans.mp4"%2C"poster"%3A"https%3A%2F%2Fvjs.zencdn.net%2Fv%2Foceans.png"%2C"duration"%3A"00%3A46"%7D%2C%7B"title"%3A"Big+Buck+Bunny+-+HLS"%2C"src"%3A"https%3A%2F%2Ftest-streams.mux.dev%2Fx36xhzz%2Fx36xhzz.m3u8"%2C"poster"%3A"https%3A%2F%2Fd2zihajmogu5jn.cloudfront.net%2Fbig-buck-bunny%2Fbbb.png"%2C"duration"%3A"10%3A34"%7D%2C%7B"title"%3A"Big+Buck+Bunny+-+DASH"%2C"src"%3A"https%3A%2F%2Fdash.akamaized.net%2Fakamai%2Fbbb_30fps%2Fbbb_30fps.mpd"%2C"poster"%3A"https%3A%2F%2Fd2zihajmogu5jn.cloudfront.net%2Fbig-buck-bunny%2Fbbb.png"%2C"duration"%3A"10%3A34"%7D%5D) ## Who use OPlayer? diff --git a/examples/standalone/main.ts b/examples/standalone/main.ts index 22b46d83..3f93e55a 100644 --- a/examples/standalone/main.ts +++ b/examples/standalone/main.ts @@ -146,8 +146,8 @@ const player = Player.make('#player', { }, { title: "Disney's Oceans - MP4", - src: '//vjs.zencdn.net/v/oceans.mp4', - poster: '//vjs.zencdn.net/v/oceans.png', + src: 'https://vjs.zencdn.net/v/oceans.mp4', + poster: 'https://vjs.zencdn.net/v/oceans.png', duration: '00:46' }, { diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 24ef447a..2e00aefa 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -2,6 +2,11 @@ ## UnRelease +## [1.2.33-beta.3] + +- pause before source changeing. +- single apply plugin. + ## [1.2.33-beta.1] - add events `sourcechangeerror`, `qualitychangeerror`. diff --git a/packages/core/package.json b/packages/core/package.json index 2a2b7822..b306cd5d 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@oplayer/core", - "version": "1.2.33-beta.2", + "version": "1.2.33-beta.3", "description": "Oh! Another HTML5 video player.", "type": "module", "main": "./dist/index.es.js", diff --git a/packages/core/src/player.ts b/packages/core/src/player.ts index ddee9c36..68640105 100644 --- a/packages/core/src/player.ts +++ b/packages/core/src/player.ts @@ -218,8 +218,8 @@ export class Player = Record> { } applyPlugin(plugin: PlayerPlugin) { + this.plugins.push(plugin) const returned = plugin.apply(this) - const { name, key } = plugin if (returned) { //@ts-ignore diff --git a/packages/docs/public/ohls.html b/packages/docs/public/ohls.html index 95f2a58c..42d6697b 100644 --- a/packages/docs/public/ohls.html +++ b/packages/docs/public/ohls.html @@ -1,4 +1,4 @@ - + @@ -12,73 +12,32 @@ margin: 0; background-color: #000; } + #oplayer, .placeholder { width: 100vw; height: 100vh; } - - .placeholder { - display: flex; - align-items: center; - justify-content: center; - } - - .placeholder span { - animation: jello-horizontal 1.2s both infinite; - letter-spacing: 4px; - color: #fff; - font-size: 24px; - } - - @keyframes jello-horizontal { - 0% { - transform: scale3d(1, 1, 1); - } - 30% { - transform: scale3d(1.25, 0.75, 1); - } - 40% { - transform: scale3d(0.75, 1.25, 1); - } - 50% { - transform: scale3d(1.15, 0.85, 1); - } - 65% { - transform: scale3d(0.95, 1.05, 1); - } - 75% { - transform: scale3d(1.05, 0.95, 1); - } - 100% { - transform: scale3d(1, 1, 1); - } - } + -
-
- WAIT ยทยทยท -
-
+
- - + +