Compare commits

...

1396 Commits

Author SHA1 Message Date
17dcb63c26 Merge branch 'develop'
# Conflicts:
#	dist/plyr.js.map
#	dist/plyr.min.js
#	dist/plyr.min.js.map
#	dist/plyr.polyfilled.js.map
#	dist/plyr.polyfilled.min.js
#	dist/plyr.polyfilled.min.js.map
2018-06-21 09:11:05 +10:00
e04b90c9c0 Ads only on HTML5 and .is cleanup 2018-06-21 09:06:28 +10:00
f62e1da01a Merge pull request #1057 from meyt/patch-1
Fix i18n defaults path on README
2018-06-20 22:46:50 +10:00
2fe949629f Fix i18n defaults path 2018-06-20 16:00:51 +04:30
20f2ddc11d Merge pull request #1056 from friday/volume
Minor increaseVolume and decreaseVolume changes
2018-06-20 16:53:43 +10:00
004528a65c Avoid conditions in volume scroll event listener 2018-06-19 17:22:12 +02:00
39c7bd40c2 Make decreaseVolume wrap increaseVolume for code reuse 2018-06-19 16:29:52 +02:00
43879e08f4 Make (increase/decrease)Volume methods ignore invalid input instead of raising / lowering to the min / max 2018-06-19 16:27:06 +02:00
5ed7aa6620 v3.3.17 2018-06-19 16:58:38 +10:00
47750b6aad v3.3.17
-   Fix YouTube muting after seeking with the progress slider
-   Respect preload="none" when setting quality if the media hasn't been loaded some other way
2018-06-19 16:57:32 +10:00
de7832eb8b Merge branch 'develop' 2018-06-19 16:40:54 +10:00
52ea5bd0ab Merge pull request #1052 from friday/youtube-audio-fix
Fix YouTube muting after seeking with the progress slider.
2018-06-19 04:15:07 +02:00
457d112df7 Fix #1045: YouTube mutes when seeking after play 2018-06-19 04:03:59 +02:00
22cdec9d38 Merge pull request #1051 from friday/quality-2
Respect preload="none" when setting quality if the media hasn't been loaded some other way
2018-06-19 11:48:44 +10:00
d72e502107 Fixes #1044: Don't load the new source if preload is disabled and the current source hasn't been loaded 2018-06-19 03:39:18 +02:00
94055f0772 Replace filter()[0] with find() 2018-06-19 03:35:57 +02:00
ede9323524 v3.3.16 2018-06-19 09:16:14 +10:00
c45f428f61 Built files 2018-06-19 09:14:10 +10:00
b61ba02f3d Fix issue with play button not changing state (fixes #1048) 2018-06-19 09:12:21 +10:00
ea4d91d2a0 v3.3.15 2018-06-18 23:21:03 +10:00
22d524ac9d Removed 1440p so I can afford to eat 2018-06-18 22:16:12 +10:00
8584f6a1db v3.3.14 2018-06-18 22:01:56 +10:00
08df96a149 v3.3.13
You guessed it, a load of awesome changes from contributors:

Thanks @friday for the following:

-   Captions fixes
-   Fix poster race conditions
-   Minor code improvements for quality switching
-   Minor event changes
-   Fix condition in events.toggleListener to allow non-elements
-   Suggestion: Remove array newline rule
-   Contributions improvements

-   fix: html5.cancelRequest not remove source tag correctly (thanks @a60814billy)
-   remove event listeners in destroy() (thanks @cky917)
-   Fix markdown in README (thanks @azu)
-   Some parts of the accessibility improvements outlined in #905 (more on the way...)
-   Fix for bug where volume slider didn't always show
2018-06-18 21:49:06 +10:00
cc3c0b5448 Merge branch 'develop' 2018-06-18 21:41:25 +10:00
3c9c1b4cdc Merge pull request #1041 from sampotts/a11y-improvements
A11y improvements
2018-06-17 01:34:11 +10:00
599883e684 Formatting fix 2018-06-17 01:30:24 +10:00
f1b4db4f36 Merge branch 'develop' into a11y-improvements
# Conflicts:
#	dist/plyr.js
#	dist/plyr.js.map
#	dist/plyr.min.js
#	dist/plyr.min.js.map
#	dist/plyr.polyfilled.js
#	dist/plyr.polyfilled.js.map
#	dist/plyr.polyfilled.min.js
#	dist/plyr.polyfilled.min.js.map
#	src/js/controls.js
#	src/js/fullscreen.js
#	src/js/plyr.js
#	src/js/ui.js
#	src/js/utils.js
2018-06-17 01:26:24 +10:00
d4abb4b143 120 line width, package upgrade 2018-06-17 01:04:55 +10:00
828ce66942 Merge pull request #1038 from friday/captions-input-lowercase
Small captions fixes
2018-06-17 00:40:56 +10:00
ccc2608cf6 Merge pull request #1039 from friday/poster-race-conditions
Fix poster race conditions
2018-06-17 00:40:28 +10:00
de45de0e0b Merge pull request #1040 from friday/switches-get-stitches
Switches code optimizations
2018-06-17 00:39:35 +10:00
99c10aa1fc Replace switch in controls.createProgress with object literal 2018-06-16 07:27:04 +02:00
2a186e425b Replace switch in support.mime with object literal and conditions, and make it return boolean 2018-06-16 07:27:04 +02:00
64bb206d85 Replace switch in support.check with simpler conditions 2018-06-16 07:27:04 +02:00
2d6732d580 Replace switch in controls.createLabel with object literal 2018-06-16 07:25:34 +02:00
8f359adf9c Fix captions.toggle order 2018-06-16 01:34:55 +02:00
1f09493ba2 Captions: Handle uppercase input (like before) 2018-06-16 01:07:16 +02:00
115f352ade Respect call order and prioritize public API calls for setting poster, in order to avoid race conditions 2018-06-15 23:56:47 +02:00
2af60c5c0d Add 'ready' promise 2018-06-15 23:01:33 +02:00
aab2817ddc Copy poster when creating new media element for YouTube and Vimeo (needed for #1018) 2018-06-15 22:57:16 +02:00
f1c4752036 Filter out null / undefined in elements.setAttributes 2018-06-15 22:52:19 +02:00
88735e3146 Replace switch in controls.updateSetting with condition 2018-06-15 15:57:10 +02:00
c373ed72d7 Replace switch in YouTube error handler with object literal 2018-06-15 15:57:10 +02:00
213cfe8c84 Replace switch in media.js with simpler conditions 2018-06-15 15:57:10 +02:00
87ea5e14b4 Replace provider switch plyr.js with conditions 2018-06-15 15:57:10 +02:00
2aa967aba9 Replace switch in source.js with destructuring 2018-06-15 12:33:30 +02:00
d522e40594 Merge pull request #1034 from friday/remove-array-newline-rule
Suggestion: Remove array newline rule
2018-06-15 15:34:29 +10:00
3cd2b9a6c3 Merge pull request #1036 from friday/captions-passive-toggle
Captions fixes (again)
2018-06-15 15:33:39 +10:00
19e412a73a Add 'passive' flag to internal captions methods to avoid overriding user preferences, support multiple browser languages (get first match) and improve comments 2018-06-15 06:07:04 +02:00
cf5f77c709 Fix menu transitionend event listener 2018-06-15 05:51:23 +02:00
4811e3333f Merge pull request #1035 from sampotts/friday-contrib-2
Contributions improvements
2018-06-15 11:04:33 +10:00
8257857075 Wrap caption toggle event listener callback to avoid sending event 2018-06-15 02:44:00 +02:00
e3e4e60fdb Contributions improvements
General improvements and new sections
2018-06-14 19:50:59 +02:00
6ce9a94932 Move internal event listeners for captions with direct handling in the captions object 2018-06-14 16:41:16 +02:00
fa5d0ad316 Move toggleCaption internals to captions object 2018-06-14 15:58:35 +02:00
6bff6b317d Remove line breaks in arrays 2018-06-13 23:27:35 +02:00
99ac8d4c52 Remove array-newline rule 2018-06-13 22:07:32 +02:00
019e1f80ca Merge pull request #1032 from friday/event-2
Fix condition in events.toggleListener to allow non-elements
2018-06-13 23:16:46 +10:00
2fe98f3721 Fix condition in events.toggleListener to allow non-elements 2018-06-13 14:29:55 +02:00
5c08363400 Merge pull request #1030 from friday/event-improvements
Minor event changes
2018-06-13 10:52:17 +10:00
927326f715 Also remove 'once' event listeners when destroying (they may still be waiting) 2018-06-12 20:00:41 +02:00
53933dff7e Use toggleListener in trapFocus 2018-06-12 19:39:26 +02:00
f15c1344b0 Removed support for multiple elements in toggleListener 2018-06-12 19:10:00 +02:00
fb48b330cc typo 2018-06-12 17:41:17 +02:00
5dddf8b0ec Logic cleanup 2018-06-13 00:56:31 +10:00
0ecf7e3854 Force string on format 2018-06-13 00:48:42 +10:00
aae1092bac Merge branch 'develop' of github.com:sampotts/plyr into develop
# Conflicts:
#	src/js/captions.js
#	src/js/controls.js
#	src/js/fullscreen.js
#	src/js/html5.js
#	src/js/listeners.js
#	src/js/plugins/youtube.js
#	src/js/plyr.js
#	src/js/utils.js
2018-06-13 00:41:30 +10:00
7158e507ad Merge pull request #1029 from cky917/develop
remove event listeners in destroy()
2018-06-13 00:05:31 +10:00
70f3390ffe Merge pull request #1028 from a60814billy/fix/cancel-request-not-remove-source-tag-correctly
fix: html5.cancelRequest not remove source tag correctly
2018-06-13 00:03:24 +10:00
392dfd024c Utils broken down into seperate files and exports 2018-06-13 00:02:55 +10:00
cky
87170ab460 remove event listeners in destroy, add once method 2018-06-12 21:18:05 +08:00
ee4c044d27 fix: html5.cancelRequest not remove source tag correctly 2018-06-12 11:35:31 +08:00
0b09b8ee6f Merge pull request #1027 from friday/quality
Minor code improvements for quality switching
2018-06-12 11:13:34 +10:00
db95b3234f Move uniqueness filter from getQualityOptions to setQualityMenu 2018-06-12 02:31:18 +02:00
6d2dad5810 Trigger qualityrequested event unconditionally when trying to set it (needed for streaming libraries to be able to listen) 2018-06-12 02:31:18 +02:00
81ee3f759c Remove todo comment about Vimeo support for setting quality (they don't support it) 2018-06-12 02:31:18 +02:00
ed606c28ab Filter out unsupported mimetypes in getSources() instead of the quality setter 2018-06-12 02:31:18 +02:00
f15e07f7f5 Simplify logic in youtube.mapQualityUnit (not that it matters much now) 2018-06-12 02:31:04 +02:00
cd14c3086d Merge pull request #1025 from azu/patch-1
Fix markdown in README
2018-06-11 20:16:18 +10:00
azu
41184b82ee Fix markdown in README 2018-06-11 19:12:35 +09:00
6a6f3914c0 Merge branch 'develop' into a11y-improvements
# Conflicts:
#	dist/plyr.js.map
#	dist/plyr.min.js
#	dist/plyr.min.js.map
#	dist/plyr.polyfilled.js.map
#	dist/plyr.polyfilled.min.js
#	dist/plyr.polyfilled.min.js.map
2018-06-11 17:13:09 +10:00
840e31a693 v3.3.12 2018-06-11 17:10:37 +10:00
1bc452c349 Merge 2018-06-11 16:54:35 +10:00
3fad6ed42c Merge branch 'develop' into a11y-improvements
# Conflicts:
#	demo/dist/demo.css
#	dist/plyr.css
#	dist/plyr.js.map
#	dist/plyr.min.js
#	dist/plyr.min.js.map
#	dist/plyr.polyfilled.js.map
#	dist/plyr.polyfilled.min.js
#	dist/plyr.polyfilled.min.js.map
#	src/js/captions.js
2018-06-11 16:54:20 +10:00
38f954ef17 Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.js.map
#	dist/plyr.min.js
#	dist/plyr.min.js.map
#	dist/plyr.polyfilled.js.map
#	dist/plyr.polyfilled.min.js
#	dist/plyr.polyfilled.min.js.map
2018-06-11 16:48:54 +10:00
abd1182303 Merge 2018-06-11 16:45:40 +10:00
efe70ab48e v3.3.11 2018-06-11 16:39:35 +10:00
62c263bda3 Replace quality setter conditions with Array.find() 2018-06-11 08:23:08 +02:00
4c1337b4c5 Assure type safety in getSources() and getQualityOptions() (always return arrays), and remove external conditions and type conversion no longer needed 2018-06-11 08:23:08 +02:00
38f10d4cc6 WIP 2018-06-11 16:19:11 +10:00
1ad76800b0 Merge pull request #1024 from friday/event-bubble-detail
Event "detail" is lost in the synthetic event bubble/proxy
2018-06-11 16:13:02 +10:00
cc97d7be6a Fix synthetic event bubble/proxy loses detail 2018-06-11 08:00:46 +02:00
f951cb372c Merge pull request #1023 from friday/make-utils-static
Make utils static
2018-06-11 14:41:06 +10:00
37a3ab202a Remove wrapper function around utils.is.element in Plyr.setup() (no lnger needed) 2018-06-11 05:44:57 +02:00
b148adc0af Avoid using this to refer to utils or utils.is, since that means methods can't be used statically 2018-06-11 05:44:57 +02:00
16828e975a Move utils.is.getConstructor() to utils.getConstructor() 2018-06-11 05:44:57 +02:00
7d26f41d64 Merge pull request #1015 from friday/captions-fixes-again
Captions rewrite (use index internally to support missing or duplicate languages)
2018-06-11 13:21:05 +10:00
f37f465ce4 Merge pull request #1020 from friday/1016
Vimeo: Update playback state and assure events are triggered on load
2018-06-11 11:48:03 +10:00
b199215525 Merge pull request #1021 from friday/vimeo-seek-while-playing
Fix for YouTube and Vimeo pausing after seek
2018-06-11 11:47:34 +10:00
94699f3255 Fix problem with YouTube and Vimeo seeking while playing 2018-06-11 02:21:00 +02:00
d3e98eb27e Vimeo: Assure state is updated with autoplay (fixes #1016) 2018-06-11 00:00:16 +02:00
41012a9843 Typo 2018-06-10 22:00:15 +02:00
c83487a293 Fix #1017, fix #980, fix #1014: Captions rewrite (use index internally) 2018-06-10 19:00:07 +02:00
1fab4919c0 controls.createMenuItem: Change input to object (too many params made it hard to read) 2018-06-10 18:57:19 +02:00
9dc0f28800 Avoid condition in getTracks 2018-06-10 18:57:19 +02:00
b57784d1a5 Change debug warn 'Unsupported language option' to log 'Language option doesn't yet exist' since it doesn't have to be an error 2018-06-10 18:56:13 +02:00
a80b31bf98 Fix #1003: Formatted captions issue 2018-06-10 18:56:13 +02:00
7c6d4666e9 Merge branch 'develop' into a11y-improvements
# Conflicts:
#	demo/dist/demo.css
#	dist/plyr.css
#	dist/plyr.js.map
#	dist/plyr.min.js
#	dist/plyr.min.js.map
#	dist/plyr.polyfilled.js
#	dist/plyr.polyfilled.js.map
#	dist/plyr.polyfilled.min.js
#	dist/plyr.polyfilled.min.js.map
#	src/js/captions.js
#	src/js/plyr.js
2018-06-09 17:03:16 +10:00
76bb299c68 Restore default 2018-06-09 12:05:37 +10:00
0c03accd41 Fix Sprite issue 2018-06-09 12:04:53 +10:00
b12eeb0eb7 Merge captions setText and setCue into updateCues (fixes #998 and vimeo cuechange event) 2018-06-08 11:44:15 +02:00
8e634862ff Merge pull request #1007 from cky917/master
fix:  After clicking on the progress bar, keyboard operations will not work.
2018-06-08 10:54:16 +10:00
1e1874d86b Merge pull request #1009 from friday/contributing
Contributing document and codepen demo updates
2018-06-08 10:52:37 +10:00
16624b90d3 Clarifications due to recent non-constructive comments in #1001 2018-06-07 14:30:05 +02:00
ed14b656a8 Add contributing document 2018-06-07 11:47:51 +02:00
1d0cf16254 Readme: Replace streaming section with codepen templates for all supported formats and libraries (and updated code) 2018-06-07 11:47:34 +02:00
cky
84424f7f67 fix: when the seek input is focused and the video is playing, the space key can't make the video pause, because after 'keyup', it always make the video play 2018-06-06 19:27:07 +08:00
cky
c95d9923f7 fix: https://github.com/sampotts/plyr/issues/1006 2018-06-06 16:59:42 +08:00
05b85da3f4 Update controls.md (fixes #996) 2018-06-02 19:48:48 +10:00
a4caba120c Merge branch 'master' of github.com:sampotts/plyr
# Conflicts:
#	demo/dist/demo.css
#	dist/plyr.css
#	dist/plyr.js.map
#	dist/plyr.min.js
#	dist/plyr.min.js.map
#	dist/plyr.polyfilled.js.map
#	dist/plyr.polyfilled.min.js
#	dist/plyr.polyfilled.min.js.map
2018-05-31 23:43:40 +10:00
969a877a34 v3.3.10 2018-05-31 23:41:48 +10:00
fb22a90d33 Merge pull request #993 from sampotts/develop
v3.3.10
2018-05-31 23:39:51 +10:00
108bd3dfa0 Fixed incorrect BEM formatting, fixed buffer alignment 2018-05-31 23:33:59 +10:00
5a445ae647 Merge pull request #988 from kim-company/translate-qualities
Translate quality badges and quality names
2018-05-31 22:43:31 +10:00
56668f58b6 Rename qualityName to label 2018-05-31 14:40:56 +02:00
eec96e5879 Merge pull request #990 from friday/travis
Travis integration
2018-05-31 18:33:00 +10:00
c6c9d877e4 Merge pull request #992 from philipgiuliani/quality-resume-time
Wait for the metadata to be loaded before setting the currentTime
2018-05-31 18:32:10 +10:00
61f4b998e1 Wait for the metadata to be loaded before setting the currentTime 2018-05-31 10:17:41 +02:00
25a319d884 Merge pull request #989 from friday/pr-template
Proposed changes to PR template
2018-05-31 08:34:02 +10:00
4bf678fe6c Proposed changes to PR template (develop as base branch, exclude build and typo fix) 2018-05-30 19:52:15 +02:00
359acd6bb9 Lint and build in travis 2018-05-30 19:40:17 +02:00
2fce385691 Add npm scripts for linting and building 2018-05-30 19:40:17 +02:00
a82c61c539 Gulp: Add option to build only 2018-05-30 19:39:57 +02:00
a8fa125a96 Refactor getDeep method 2018-05-30 17:30:10 +02:00
6435ced707 Return undefined when the key is not present. 2018-05-30 17:10:38 +02:00
94dc0d176c Rebuild 2018-05-30 17:03:41 +02:00
23c21252e8 Rebuild 2018-05-30 17:02:07 +02:00
41c7dff0e8 Add getDeep method to utils 2018-05-30 17:02:07 +02:00
e3bae562fc Rebuild 2018-05-30 17:02:07 +02:00
1c1668bfc3 Implement translation support for qualityName and qualityBadge 2018-05-30 17:02:07 +02:00
e0c09c51f2 Allow nested translations 2018-05-30 17:02:07 +02:00
8de06fb862 Accept quality 0 2018-05-30 17:02:07 +02:00
64412868d8 ESLint tweak 2018-05-30 17:02:07 +02:00
450958c290 Merge pull request #981 from friday/hls-captions
Improve captions handling for streaming
2018-05-30 21:44:42 +10:00
963fe11ad6 Update readme.md 2018-05-30 00:22:01 +10:00
ce199e4b6b Merge pull request #986 from friday/701
Call duration update method manually if user config has duration
2018-05-30 00:20:15 +10:00
9d798893b5 Call duration update method manually if user config has duration 2018-05-29 16:06:07 +02:00
64399e0717 Defer initial captions update to next tick, to avoid event being triggered to early 2018-05-28 17:54:25 +02:00
f58e23b325 Change to using addtrack and removetrack listeners since 'change' didn't trigger in firefox for embedded captions (may also be a hls.js issue) 2018-05-28 16:19:44 +02:00
812e07b734 Replace browser language detection in defaults.js with explicit 'auto' option 2018-05-28 07:43:37 +02:00
c9298fde76 Fix typo 2018-05-28 07:08:38 +02:00
0109454a34 Ensure language is set in case the track is added after initialization, and trigger languagechange event when language is initially set 2018-05-28 06:08:03 +02:00
813f703211 Add option to watch caption track changes and update language options 2018-05-28 06:08:03 +02:00
7aad747c25 Optimize captions code reused and ensure captionsenabled/captionsdisabled
will be sent on initial setup
2018-05-28 05:44:54 +02:00
d70a787af1 Merge branch 'develop' 2018-05-28 10:42:11 +10:00
69bb0917ad v3.3.9 2018-05-28 10:41:51 +10:00
90c5735904 WIP 2018-05-28 10:19:07 +10:00
6f256d09b2 ESLint tweak 2018-05-28 10:18:04 +10:00
e9684c2021 Merge pull request #979 from friday/respect-storage
Respect storage being disabled for storage getter
2018-05-28 10:09:02 +10:00
bf91a0e73f Merge pull request #977 from friday/utils.is.icue-ie11
Restore utils.is.cue()
2018-05-28 10:08:42 +10:00
14b6309aef Merge pull request #978 from friday/ie-issues
Fix InvalidStateError and IE11 issues
2018-05-28 10:08:24 +10:00
6391ced99f If storage is disabled, disable get as well, not just set 2018-05-28 01:58:06 +02:00
fac8a185ba Simplify currentTime setter and bail when media hasn't loaded 2018-05-28 00:57:07 +02:00
c69aa8a42b Avoid duration getter returning NaN before element has loaded 2018-05-28 00:57:01 +02:00
f34bf22125 Restore utils.is.cue() 2018-05-27 20:28:48 +02:00
f0be913dc3 Merge pull request #975 from sampotts/develop
v3.3.8
2018-05-26 13:55:22 +10:00
cd51788b98 v3.3.8 2018-05-26 13:53:15 +10:00
edd67b0da3 Typo 2018-05-20 23:44:40 +10:00
d733454d7f Pause while seeking 2018-05-20 23:40:28 +10:00
41f9a87e0e Add URL polyfill 2018-05-20 23:40:00 +10:00
f4858f0c62 Merge pull request #959 from friday/876
Youtube and vimeo fixes
2018-05-19 16:49:31 +10:00
121093ae71 Prevent durationchange events from showing time when invertTime is false 2018-05-19 04:27:45 +02:00
aa8fc313a9 Fix #966: Add 'seeked' event listener to update progress (seeking doesn't have the correct time) 2018-05-19 04:23:22 +02:00
723298a07b Fix #921: Trigger seeked event in youtube plugin if either playing or paused 2018-05-19 04:18:27 +02:00
f8c89e3e95 Fix #876: YouTube and Vimeo autoplays on seek 2018-05-19 04:18:27 +02:00
333435a9c2 Fix playback state (paused) and events (play/pause) 2018-05-19 04:18:27 +02:00
3ab2295fe7 Merge branch 'master' into develop 2018-05-19 11:29:47 +10:00
c41bb657ac Merge pull request #958 from friday/954
Fix the seek tooltip time difference from seek time
2018-05-19 11:28:38 +10:00
55bbf64f2b Merge pull request #963 from friday/verify-poster
Make sure poster element isn't shown if the image isn't loaded
2018-05-19 11:27:52 +10:00
3bba65f2c2 Merge pull request #967 from friday/883
toggleControls rewrite
2018-05-19 11:27:19 +10:00
1bab0d07b5 Merge branch 'master' into develop 2018-05-19 11:26:05 +10:00
602353f4d9 Merge branch 'master' of github.com:sampotts/plyr 2018-05-19 11:25:02 +10:00
51814249af Reduce circular dependencies 2018-05-19 11:24:56 +10:00
37c5fbfe16 toggleControls() rewrite 2018-05-18 16:19:38 +02:00
d7356726a1 Remove ui.checkFailed() and error class 2018-05-16 23:21:06 +02:00
4db6bf7a2e Make utils.toggleClass() compatible with Element.classList.toggle (rename toggle argument to 'force' and make it optional) 2018-05-16 23:21:06 +02:00
28826f6402 Add 'video only' caveat to toggleControls() doc (current behavior) 2018-05-16 23:21:06 +02:00
c845558d96 Youtube poster: Set css backgroundSize to 'cover' for padded youtube thumbnails 2018-05-15 16:41:51 +02:00
16c3a7d9e5 Rewrite ui.setPoster to check that images arent broken or youtube fallback images. Only show poster element when valid 2018-05-15 16:21:36 +02:00
90d5b48845 Add async method to utils for loading/checking images 2018-05-15 13:27:55 +02:00
d1acc4abb3 Add event before seeking via mouse interaction to set alternative 'value' for the input matching the tooltip time 2018-05-14 19:50:08 +02:00
797b70998f Merge pull request #960 from friday/935
Support importing Plyr in Node.js without errors
2018-05-14 23:38:48 +10:00
4a01027da0 Merge pull request #961 from friday/expose-defaults
Enable overriding defaults
2018-05-14 23:38:25 +10:00
7ca2169790 Expose defaults (enable overriding) 2018-05-14 06:49:04 +02:00
054f522aa9 Enable importing Plyr in node.js without errors (resulting in an empty object) 2018-05-14 05:35:13 +02:00
f2fc3f5ea5 Fix the seek tooltip time difference from seek time 2018-05-12 00:10:39 +02:00
765c01e83d Remove references to window.Plyr 2018-05-10 09:34:15 +10:00
33a11fb53a v3.3.7 2018-05-09 09:50:22 +10:00
d1d41ca49a Merge branch 'master' of github.com:sampotts/plyr 2018-05-09 09:48:52 +10:00
c06e0ee5e9 Grid tweak 2018-05-09 09:48:46 +10:00
83f80ccc40 Merge pull request #950 from friday/poster-fixes
Poster fixes
2018-05-09 09:44:36 +10:00
069065ea3a Fix #946 - poster getting click events 2018-05-08 16:50:40 +02:00
1672e78041 Fix poster being stretched 2018-05-08 16:49:32 +02:00
34401de3d0 Merge branch 'master' into develop 2018-05-08 22:22:43 +10:00
f687b81b70 v3.3.6 2018-05-08 13:18:30 +10:00
bbb11e611e Vimeo options, docs for multiple players 2018-05-08 13:12:39 +10:00
90919411e9 Use div for poster, Vimeo fixes, Tooltip fixes 2018-05-08 12:57:24 +10:00
1491b017a0 Setup multiple players 2018-05-06 16:18:10 +10:00
1655150092 v3.3.5 2018-05-06 01:32:51 +10:00
ceb6c9a100 v3.3.3 2018-05-06 01:16:41 +10:00
00bbce08fb Reverted menu change 2018-05-06 01:14:41 +10:00
91a4b86860 Small bug fixes 2018-05-06 01:03:38 +10:00
5aece6fa06 Merge 2018-05-06 00:50:02 +10:00
a70b94afe2 Merge branch 'master' of github.com:sampotts/plyr 2018-05-06 00:49:22 +10:00
9ebc2719d3 v3.3.0 2018-05-06 00:49:12 +10:00
b46aae1833 Merge pull request #939 from Billybobbonnet/patch-1
Added 480p to SD labels
2018-05-03 20:28:03 +10:00
30e6a40865 Added 480p to SD labels 2018-05-03 11:42:09 +02:00
403df36af6 Merge branch 'master' into develop 2018-04-27 21:42:29 +10:00
5ca769807e Merge pull request #923 from friday/922
Only add hideControls class if config.hideControls is truthy
2018-04-27 20:07:18 +10:00
72a71a605b Fix for default timestamp 2018-04-27 20:06:14 +10:00
24d833a5d1 Merge branch 'master' into develop 2018-04-27 18:35:06 +10:00
44b30380f7 Merge branch 'beta' of github.com:Selz/plyr 2018-04-27 18:34:06 +10:00
261cd086c7 Update readme.md 2018-04-27 12:44:58 +10:00
9e19b526b9 Only add hideControls class if config.hideControls is truthy 2018-04-26 17:51:14 +02:00
6c617a0ef1 Readme fix 2018-04-27 01:12:04 +10:00
a812650fea v3.2.4 2018-04-27 00:47:51 +10:00
fec7a77d6f v3.2.3 2018-04-25 20:02:36 +10:00
971e261067 Fix for iOS 9 throwing error for name property in fullscreen API (fixes #908) 2018-04-25 19:59:22 +10:00
27407ba021 v3.2.2 2018-04-25 19:46:39 +10:00
ef8e58ede4 Fix for hidden buffer and incorrect use of aria-hidden 2018-04-25 19:40:23 +10:00
f13260c10a Merge pull request #919 from sampotts/master
Merge back
2018-04-25 07:38:17 +10:00
e1183d6049 Merge pull request #918 from sampotts/master
Merge back
2018-04-25 07:37:18 +10:00
f1b275aedc v3.2.1 2018-04-23 00:53:54 +10:00
b647af256c More a11y stuff and context menu fix 2018-04-23 00:01:19 +10:00
d2e9ed3467 Merge 2018-04-18 18:34:59 +10:00
5b39986835 Merge branch 'master' of github.com:sampotts/plyr 2018-04-18 18:29:50 +10:00
a97b08e8ea ARIA and Vimeo fixes 2018-04-18 18:29:43 +10:00
56d1be9447 Merge pull request #903 from friday/901
Show captions even if toggle button is omitted from controls
2018-04-18 08:49:05 +10:00
a241cb5215 Merge pull request #904 from friday/881
Fullscreen aria-pressed event listened fix for Chrome
2018-04-18 08:48:08 +10:00
042b1a8294 Fullscreen aria-pressed event listened fix for Chrome 2018-04-17 20:28:47 +02:00
6d79b8cd4c Don't require captions toggle button to be enabled in order to show captions 2018-04-17 18:59:19 +02:00
88d766aeae v3.2.0 2018-04-17 23:54:38 +10:00
119b471b84 More bug fixes 2018-04-17 23:51:23 +10:00
7f079e0ec3 Fix for playing false positive (fixes #898) 2018-04-17 22:52:46 +10:00
46fe3eecff Fixed bug for captions with no srclang and labels and improved logic (fixes #875) 2018-04-17 22:49:28 +10:00
3061a701d5 PR merge 2018-04-14 14:58:09 +10:00
e45109e1d7 Merge branch 'master' of github.com:sampotts/plyr 2018-04-14 14:48:20 +10:00
e138e6d51e Merge pull request #895 from nicolasthy/patch-1
Fix IE10 split error
2018-04-14 14:47:57 +10:00
aef1363b04 Fix IE10 with default captions.language 2018-04-13 14:44:05 +02:00
766dd03d81 Fix IE10 split error
On IE10, Plyr throws the error `Unable to get property 'split' of undefined or null reference`. This fixes the case when `window.navigator.language` is null and can't use the `split()` function.
2018-04-12 22:12:12 +02:00
ab393651ec Merge branch 'master' of github.com:sampotts/plyr 2018-04-11 23:44:44 +10:00
ffd265d0ae Merge pull request #888 from Antonio-Laguna/master
Safer check for active caption
2018-04-11 23:42:40 +10:00
72155472dd Safer check for active caption 2018-04-11 15:39:12 +02:00
9b7170834e Merge pull request #887 from danielsarin/use-i18n-for-normal-speed
Add i18n support for "Normal" value in speed options
2018-04-11 22:43:47 +10:00
3e57a87bf7 Add i18n support for "Normal" value in speed options 2018-04-11 15:39:23 +03:00
a15d1c9f1c Merge pull request #886 from danielsarin/increate-menu-z-index
Increase menu container z-index to be higher than controls
2018-04-11 22:23:46 +10:00
a095a64f90 Increase menu container z-index to be higher than controls 2018-04-11 15:13:34 +03:00
2374d6b1c4 Merge branch 'master' of github.com:sampotts/plyr 2018-04-11 21:52:36 +10:00
5ed3ff9084 Restore paused state after seek 2018-04-11 21:52:31 +10:00
385be55510 Merge pull request #874 from friday/873
Fixes issue leaving fullscreen in Chrome using button
2018-04-10 17:21:15 +10:00
3082d0d128 Fixes #873 Can't leave fullscreen in Chrome (using button) 2018-04-05 20:29:01 +02:00
f7e242f054 Merge pull request #871 from friday/867
Fix #867: Add custom property fallback
2018-04-05 09:19:46 +10:00
2874505004 Merge pull request #868 from friday/null-no-controls
Fix string "null" being appended after the video if controls argument is empty.
2018-04-05 09:19:05 +10:00
ed9e0c13d7 Fix #867: Add custom property fallback 2018-04-05 00:33:09 +02:00
10be94fa99 Fix 'null' being appended after the video if controls is empty array 2018-04-04 21:33:14 +02:00
ee79c46145 Merge branch 'master' of github.com:sampotts/plyr 2018-04-04 16:50:06 +10:00
384010a2c0 Style fixes 2018-04-04 16:50:00 +10:00
1e47019122 Merge pull request #863 from friday/data-plyr-config-no-options
Fix loading data-plyr-config when initiating Plyr without any options
2018-04-04 11:33:30 +10:00
536c65e82c Fix loading data-plyr-config when initiating Plyr without any options 2018-04-04 03:16:25 +02:00
cdf14932ec Changelog 2018-04-03 23:03:16 +10:00
3b20dbd9fd v3.1.0 2018-04-03 22:57:34 +10:00
e4d975af00 Styling fixes 2018-04-03 22:56:19 +10:00
2782a00e7c v3.1.0-beta.2 2018-04-03 22:31:55 +10:00
91d192dd7c YouTube speed menu fix 2018-04-03 22:30:29 +10:00
b1e3abc795 v3.1.0-beta.1 2018-04-02 22:52:02 +10:00
3395e8df90 HTML5 quality selection 2018-04-02 22:40:03 +10:00
cce143a7da v3.0.11 2018-03-30 23:14:07 +11:00
d593005b32 Muted and autoplay fixes, small bug fixes 2018-03-30 23:09:17 +11:00
7be9d5d4d3 v3.0.10 2018-03-30 00:16:42 +11:00
d7141d5ed7 Controls docs, package upgrades 2018-03-30 00:11:48 +11:00
0d0ece94d3 Fix regression 2018-03-29 20:20:37 +11:00
1c06f6d06d Vimeo hotfix 2018-03-29 19:35:02 +11:00
dda8e30b92 Merge branch 'master' of github.com:sampotts/plyr 2018-03-28 22:45:18 +11:00
c4e2e24643 Bug fixes 2018-03-28 22:45:11 +11:00
e020a105a3 Update readme.md 2018-03-28 00:55:55 +11:00
2b7fe9a4f9 v3.0.6 2018-03-28 00:17:15 +11:00
951df64b7f v3.0.5 2018-03-27 23:52:26 +11:00
0976afe282 v3.0.4 2018-03-27 23:47:58 +11:00
7b1e4abda7 Controls fixes 2018-03-27 23:43:38 +11:00
0cf75eed3f Revert API method change 2018-03-27 21:15:11 +11:00
d96957d086 Allow fullscreen in iframe 2018-03-27 21:13:22 +11:00
1a032ea498 Fix for seeking issue 2018-03-27 21:10:06 +11:00
5d079da1b8 Use object.entries 2018-03-27 10:41:06 +11:00
9c1bc6ab08 Fixes for fast forward and issues with event.preventDefault() 2018-03-27 10:36:08 +11:00
3d2ba8c009 Update readme.md 2018-03-22 09:11:42 +11:00
e872ce3f77 Update readme.md 2018-03-22 09:10:50 +11:00
b77756da04 Typo 2018-03-22 01:15:10 +11:00
9b23e13ce8 v3.0.3 2018-03-22 01:13:37 +11:00
5eafe9baff Vimeo offset tweak (fixes #826) 2018-03-22 01:08:08 +11:00
c251c94131 Fix for .stop() method (fixes #819) 2018-03-22 01:02:38 +11:00
17041efc71 Check for array for speed options (fixes #252) 2018-03-22 00:33:14 +11:00
05b8e8a6e0 Restore as float (fixes #828) 2018-03-22 00:28:42 +11:00
f998b996fa Fix for Firefox fullscreen oddness (Fixes #821) 2018-03-22 00:26:01 +11:00
958b47c435 Merge branch 'master' of github.com:sampotts/plyr 2018-03-22 00:06:26 +11:00
a27248d3b6 Merge pull request #820 from saadshahd/patch-1
Fix fast-forward control
2018-03-22 00:05:24 +11:00
1b1f7be7ff Merge branch 'master' of github.com:sampotts/plyr 2018-03-22 00:04:34 +11:00
59d4a27240 Improve Sprite checking (fixes #827) 2018-03-22 00:04:28 +11:00
75e9f3c2e3 Fix fast-forward control
fast-forward control doesn't work.
2018-03-21 12:15:57 +02:00
7132eccf50 Merge pull request #822 from DanielRuf/patch/fix-options-link
fix the options link in the readme
2018-03-21 09:12:06 +11:00
e953c6398c fix the options link in the readme 2018-03-20 15:05:51 +01:00
bb7eea27e5 v3.0.2 2018-03-18 22:46:36 +11:00
595c5e95bc Fix for Safari with adblockers 2018-03-18 22:37:06 +11:00
43e6dcd41d Fix for local storage issue 2018-03-18 01:37:24 +11:00
b06c8ae43f Changelog updated 2018-03-18 01:14:18 +11:00
c7ea13c0c7 Sentry in live only 2018-03-18 01:08:05 +11:00
0f8c6e147b Added Sentry 2018-03-18 00:21:23 +11:00
e566365288 Typo 2018-03-17 23:44:40 +11:00
a06e0f5890 Updated screenshot 2018-03-17 23:40:28 +11:00
3bccc0da01 v3.0.0 2018-03-17 23:33:25 +11:00
a0173d991e Removed beta message 2018-03-17 23:31:34 +11:00
600f0eb8a3 Merge branch 'beta'
# Conflicts:
#	readme.md
2018-03-17 23:30:16 +11:00
5db73b1327 Added buffered getter 2018-03-17 23:27:40 +11:00
5cb1628cd8 Vimeo fix 2018-03-15 10:29:05 +11:00
c74b75e8e1 3.0.0-beta.20 2018-03-13 23:35:17 +11:00
0538476d6f 3.0.0-beta.19 2018-03-13 22:15:28 +11:00
5ebe18d081 Typography fix 2018-03-13 22:00:40 +11:00
207adde36d 3.0.0-beta.18 2018-03-13 21:44:18 +11:00
1b13ddaa54 Update ads 2018-03-13 21:42:01 +11:00
9981c349be Fix for null manager race condition 2018-03-11 18:23:47 +11:00
b3365a7373 Normalised event names and removed unused 2018-03-11 12:54:51 +11:00
9a0c1c830d Merge pull request #804 from friday/ads-trigger-arguments
[v3] Add optional arguments to Ads.trigger
2018-03-11 10:55:29 +11:00
ef27ba16f4 Add optional argument to Ads.trigger (currently only used for adblocker error) 2018-03-10 16:20:33 +01:00
e206edc1f6 Event listener fixes, loadScript promise, ads tweaks 2018-03-11 02:03:35 +11:00
c734bc4957 Merge branch 'beta' of github.com:sampotts/plyr into beta 2018-03-10 23:32:55 +11:00
572b8a7aca Manually merged PRs 2018-03-10 23:32:48 +11:00
eebae4a227 Merge pull request #802 from gehaktmolen/ad-hotfixes
Advertisement couldnt be loaded when creative dimensions do not align after resizing
2018-03-10 23:32:15 +11:00
e0562752ea Merge pull request #795 from frogg/patch-1
Added link that explains Webkit's autoplay blocker
2018-03-10 23:29:22 +11:00
6a2ca534d2 Removed redundant wrappers within the adsmanager promises. 2018-03-09 14:29:37 +01:00
7adc2bc6c8 Unneeded else has been removed within the play() method. 2018-03-09 13:21:19 +01:00
ba8d7831a7 Made sure play() returns a promise. 2018-03-09 12:50:57 +01:00
69ffcbad27 Ad block detection would not work when calling play() right after creating the player instance, so the adsManager now also rejects on such a case. Also made sure that calling play() will wait for the adsManager promise to resolve or otherwise return the media.play() method. 2018-03-09 11:17:24 +01:00
819f7d1080 Resizing the ad container while having it on display none will return offset width and height of 0, which will cause ads not to play when ad sizes are set within the clients DSP. Also making sure that the inner containers of the ad container are full size. The container is now hidden/ displayed using z-index. 2018-03-07 15:43:48 +01:00
409b588458 Made sure that cue points for midrolls are not displayed when the ad rule for a midroll doesn't exceed the total play time of a video. 2018-03-07 15:17:30 +01:00
e90a603d57 Removed a double this.enabled variable and updated a comment in ads.js. Also made sure the adsmanager promise also can fail, so we can use it to wait for getting the advertisement ready when someone clicks the play button. Otherwise there it can look glitchy when the actual video starts playing and the video ad plays a few seconds later because the vast tag was slow to retrieve. Also fixed a typo. 2018-03-06 17:27:59 +01:00
6f061621ad v3.0.0-beta.17 2018-03-03 23:16:15 +11:00
0300610108 Typo 2018-03-03 23:14:57 +11:00
2fba5f152c 3.0.0-beta.16 2018-03-03 23:06:54 +11:00
317b08c703 Ready event fix, YouTube play event fix, docs update 2018-03-03 23:06:12 +11:00
e6db374a72 Added link that explains Webkit's autoplay blocker 2018-02-24 16:19:55 +01:00
bfb550b8d0 Package updates 2018-02-22 23:46:52 +11:00
174234c166 v3.0.0-beta.15 2018-02-19 09:55:16 +11:00
24b4220de5 Fix IE CORS captions 2018-02-19 09:52:46 +11:00
f1895a4cce Pause button fix, polyfilled build, unminified builds 2018-02-17 19:34:15 +11:00
c2a6306d46 Merge pull request #781 from friday/gulp-unminified-js-output
Build both minified and non-minified js-bundles
2018-02-17 09:22:34 +11:00
7ac732f45b Merge branch 'beta' into gulp-unminified-js-output 2018-02-17 09:22:19 +11:00
c90f1bdf08 v3.0.0-beta.13 2018-02-13 00:02:13 +11:00
6a9be8d16b Fix for custom controls 2018-02-13 00:01:19 +11:00
58c2c52c95 Merge branch 'beta' of github.com:sampotts/plyr into beta 2018-02-11 15:09:40 +11:00
73a39769d4 Fullscreen API changes, color settings tweaks 2018-02-11 15:09:34 +11:00
7221e26eca Merge pull request #780 from friday/captions-ie11-indexsizeerror
Fix harmless but annoying IE error 'IndexSizeError'
2018-02-06 12:51:45 +11:00
98adb8e784 Fix harmless but annoying IE error 'IndexSizeError' 2018-02-06 02:39:01 +01:00
a59dcb2f53 Gulp js build: create both minified and non-minified outputs 2018-02-06 01:57:27 +01:00
d21b58e1c9 Copy 2018-02-06 11:26:13 +11:00
d6e84cbabb Nicer checks 2018-02-06 11:12:03 +11:00
fcccf1d479 Copy 2018-02-06 11:08:26 +11:00
211db12a3d Readme merge 2018-02-06 11:06:46 +11:00
ab7f277a1b Merge pull request #769 from redxtech/add-vue-plyr-to-readme
Add vue-plyr to readme
2018-02-06 10:51:42 +11:00
ce1d5a60d6 Remove eslint-rule 'no-shadow' (common variable names should be able to exist in different scopes) 2018-02-05 23:22:20 +01:00
f67315e20c 3.0.0-beta.12 2018-02-06 00:25:50 +11:00
2150c44036 Added backwards compatibility for <div> embeds 2018-02-06 00:24:48 +11:00
70c9fbdde3 Removed fetch dependency 2018-02-05 21:43:32 +11:00
f3ea31c515 Merge branch 'beta' of github.com:sampotts/plyr into beta
# Conflicts:
#	dist/plyr.js
#	dist/plyr.js.map
2018-02-05 21:28:16 +11:00
1ee88cba16 Testing fetch 2018-02-05 21:26:18 +11:00
af3ae75229 Update readme.md 2018-02-03 23:16:52 +11:00
d76ef3ff91 Small UI tweaks and fix for instanceof issue 2018-01-31 19:33:00 +11:00
2691c7c9d6 Version bump + icon fix 2018-01-30 13:01:05 +11:00
26b1d8ce8f Fix UMD stuff 2018-01-30 12:57:19 +11:00
6fae148fc1 Deploy 2018-01-30 09:26:09 +11:00
bb51647fe2 Merge pull request #772 from sampotts/fix/ads-blocked
Fix: ads blocked and media playing before ad plays
2018-01-30 09:22:54 +11:00
71efbe7a92 Merge branch 'beta' into fix/ads-blocked
# Conflicts:
#	dist/plyr.js
#	dist/plyr.js.map
#	src/js/plugins/ads.js
#	src/js/plyr.js
2018-01-30 09:22:14 +11:00
afd695cb39 Fix typo's 2018-01-29 22:45:46 +01:00
c4eb4c97ac fix(ads): Fixes media from playing when ads are blocked 2018-01-29 22:40:08 +01:00
d5a1a7ca1c Add vue-plyr to readme 2018-01-28 23:03:05 -07:00
8f7a8940f3 Version bump 2018-01-25 22:42:52 +11:00
5e68f8c8dd Attempt to fix YouTube message error, added ads references, changes to bool 2018-01-25 22:41:30 +11:00
b4e22e2e7b Restored “Ad” in label 2018-01-24 09:06:20 +11:00
d4234da9aa Docs tweak 2018-01-23 19:13:35 +11:00
1f53b27d4e Version bump 2018-01-23 18:00:08 +11:00
cc128e6088 Renamed property, UI tweak 2018-01-23 10:31:21 +11:00
3c8acb4e9e Fix bug where ad would play on every play action 2018-01-22 21:07:08 +01:00
ebf53d14b1 Small tweaks 2018-01-22 23:39:09 +11:00
b298587c0b Bug fix 2018-01-22 23:20:03 +11:00
26e9aaceb8 Version bump 2018-01-22 23:17:40 +11:00
384f3d6eda Gulp 2018-01-22 23:16:50 +11:00
3aa5747c90 Merge pull request #760 from sampotts/beta-with-ads
Beta with ads
2018-01-22 23:15:52 +11:00
5671235fd9 Formatting, events and ad countdown added 2018-01-22 23:15:10 +11:00
1dd5c9efd9 Converted demo to iife 2018-01-20 15:23:36 +11:00
5fad152cbf Formatting and “ad” badge 2018-01-19 20:24:15 +11:00
f33ca846f2 Build 2018-01-19 14:30:28 +11:00
986c802acd Merge branch 'beta-with-ads' of github.com:sampotts/plyr into beta-with-ads
# Conflicts:
#	src/js/plugins/ads.js
2018-01-19 14:30:11 +11:00
98dd818bf6 Merge branch 'beta' into beta-with-ads
# Conflicts:
#	demo/dist/demo.js
#	demo/dist/demo.js.map
#	dist/plyr.js
#	dist/plyr.js.map
2018-01-19 14:28:39 +11:00
021f6c8460 Comments and formatting 2018-01-19 14:26:25 +11:00
392f837398 Merge pull request #763 from gehaktmolen/beta-with-ads-adjustments
Beta with ads - Reloading ads on new video
2018-01-19 14:26:08 +11:00
6831c30534 Transition event fix 2018-01-19 14:22:26 +11:00
ed6048034b Noticed that Plyr stopped working when ads are blocked. 2018-01-18 14:04:47 +01:00
8af312fe3c Updated pause and resume content methods within Ads class. 2018-01-18 12:31:10 +01:00
d87ada4f58 Reformatted ads codebase and added/ changed comments. Also removed un-used events. 2018-01-18 12:26:53 +01:00
31c8166562 Fixed string literal and position issue of the midroll cue inside the time line. Added a check for the progress element existence. 2018-01-17 15:57:10 +01:00
0cb2f95888 Removed an un-used variable. 2018-01-17 15:43:08 +01:00
896ea7c689 Added cue markings within the time line for when midrolls will be displayed. Removed unusued callback parameter. 2018-01-17 15:38:26 +01:00
1d1eb02bd7 Added the logging of our main promises to their resolving callback. Otherwise they come up as null. 2018-01-17 14:44:44 +01:00
3583165b30 Removed logic related to starting the ad by clicking/ tapping the advertisement container. Ad is started by plyr play method. 2018-01-17 14:09:11 +01:00
d822f0c6bf Adsmanager is now re/pre-loaded with new ads when the video is done or an ad error appears. Will make it possible to request ads when a new video is loaded. Added comments and missing events within the adsmanagerloader method. 2018-01-17 13:58:39 +01:00
9e52296dc6 Moved the ads container to be outside of the video wrapper. This way we can easily move the ad in front or behind the video controls based on content resume or pause IMA events. 2018-01-17 12:19:32 +01:00
12a7a4142c Moved the logic for pausing and playing the video to content pause/ resume IMA events to avoid flickering. Also used events for resolving the adsmanager and adsloader promises. 2018-01-17 11:32:13 +01:00
8348f79742 Fix loading/playing of the ads when there is no valid ads.tagUrl 2018-01-17 08:31:36 +01:00
ec73d34bd3 Some tweaks 2018-01-16 23:06:40 +01:00
1cef48d4f8 fix blocking play() if ads are set 2018-01-15 23:30:54 +01:00
c24c05226d Merge pull request #761 from gehaktmolen/beta-with-ads-promises
Beta with ads - Added promises, missing events, new ad tag and additional logging.
2018-01-15 20:13:51 +01:00
4b0005c28e Added promises, missing events, new ad tag and additional logging. 2018-01-15 14:47:34 +01:00
8064405dbc Tweaks 2018-01-14 23:33:18 +11:00
22e8892993 Code tweaks 2018-01-14 23:15:33 +11:00
cfc86bcb7c Merge branch 'beta' into beta-with-ads
# Conflicts:
#	demo/dist/demo.js
#	demo/dist/demo.js.map
#	dist/plyr.js
#	dist/plyr.js.map
2018-01-14 22:55:44 +11:00
5f96ec6ac2 Minor logic tweak 2018-01-14 22:54:03 +11:00
bbdf225d7b Fix loading google ima sdk 2018-01-14 08:21:35 +01:00
025fc1090b Implementing ads plugin 2018-01-13 23:02:59 +01:00
d9ec1d1b8e Progressively enhance <iframe> embeds 2018-01-12 19:35:46 +11:00
2e5d06ad85 Publish script tweaks 2018-01-09 20:43:58 +11:00
bacd049eb0 Package 2018-01-09 20:26:56 +11:00
6fd7b26bb2 Beta version up on https://plyr.io/beta and CDN 2018-01-09 20:25:46 +11:00
1df79cf7f8 Publishing to /beta 2018-01-09 19:35:17 +11:00
e6badacf0d Recommended extensions for VS Code 2018-01-09 18:52:36 +11:00
a0d9d5eca8 Styling tweaks 2018-01-09 09:14:59 +11:00
8786377a75 Use CSS custom property for webkit range fill 2018-01-08 20:53:18 +11:00
f0322e8d94 Merge branch 'develop' of github.com:sampotts/plyr into develop 2018-01-08 19:42:29 +11:00
3f2ac3fca0 Package tweaks 2018-01-08 19:42:21 +11:00
9872207e87 Merge pull request #752 from friday/gulp-fix
Enable gulp builds when aws.json isn't present.
2018-01-08 12:12:11 +11:00
58d942e737 Fix gulp build for user who doesn't have aws.json 2018-01-08 02:01:39 +01:00
dd190155c4 Empty storage fix 2018-01-07 23:16:55 +11:00
ebb3b83b27 Merge branch 'master' into develop
# Conflicts:
#	src/js/plyr.js
2018-01-07 22:46:28 +11:00
79a43120ae Merge pull request #740 from gurinderhans/master
double click player to toggle fullscreen
2018-01-07 22:40:20 +11:00
2b36ab7ef5 Merge branch 'master' into develop
# Conflicts:
#	.vscode/settings.json
#	demo/dist/demo.css
#	demo/dist/demo.js
#	demo/error.html
#	demo/index.html
#	demo/src/js/main.js
#	demo/src/less/lib/fontface.less
#	dist/plyr.css
#	dist/plyr.js
#	gulpfile.js
#	package-lock.json
#	package.json
#	readme.md
#	src/js/plyr.js
#	src/less/plyr.less
#	src/scss/plyr.scss
2018-01-07 22:39:28 +11:00
eb38e0394d Slider styling 2018-01-07 22:35:52 +11:00
b79ffacd9c Merge pull request #726 from xDae/master
Added react port
2018-01-05 21:23:45 +11:00
e14e2cfaff Merge branch 'develop' of https://github.com/Selz/plyr into develop 2018-01-05 10:37:38 +11:00
04119b27e6 Tweaks 2018-01-05 10:37:34 +11:00
Sam
92cb9e22e2 Started on error handling 2018-01-04 13:43:56 +11:00
888c6773d0 Merge pull request #743 from jwpage/patch-1
Fix `enabled` smartphone example in README
2018-01-03 11:45:33 +11:00
cfd653f02a Fix enabled smartphone example in README 2018-01-03 09:55:14 +11:00
Sam
6b9106ddb1 Fix for promise issue on Chrome, loading fix 2017-12-27 21:40:35 +00:00
838bd49a1d add comment about no fullscreen if player type is audio 2017-12-23 21:47:01 -08:00
800e0dedfb add double click to make full screen support 2017-12-23 21:41:08 -08:00
965fc0b2f5 Docs, restored loadSprite and supported static methods 2017-12-23 18:42:52 +00:00
98ac98b4c2 Vimeo fix 2017-12-21 00:20:56 +00:00
178b0d8020 Badge tweak 2017-12-21 00:06:59 +00:00
3bd1c1ff56 Fix for scrubber 2017-12-20 22:06:26 +00:00
7d4bf91a35 Small fixes 2017-12-20 21:45:06 +00:00
ac3d1d1242 Docs 2017-12-20 21:10:43 +00:00
742018a716 Fix SASS bundle 2017-12-20 21:08:44 +00:00
a2ef691b4b Comment update 2017-12-20 20:49:41 +00:00
9e0c406a4a Remove chaning ability and return promise for play() 2017-12-20 20:47:02 +00:00
f3df7aba15 Split up settings file 2017-12-20 18:00:05 +00:00
6bc3592381 Fix for rounding 2017-12-20 15:32:16 +00:00
6864149989 Converted to SASS/SCSS 2017-12-20 15:14:05 +00:00
aab53fa91f Minor tweaks 2017-12-18 16:57:23 +00:00
423f67b4f4 Copy 2017-12-08 15:55:12 +00:00
82f81f4f73 More Edge fixes and small UI bugs 2017-12-08 15:54:08 +00:00
c8990bd379 IE & Edge fixes, Storage & Console classes 2017-12-08 10:05:38 +00:00
e6cc4ba1f5 Added react port 2017-12-04 17:05:14 +02:00
de54929bb7 Safari CSS fixes and variables setup 2017-11-25 22:54:04 +11:00
fd77831303 Fix display for current language on change 2017-11-25 01:19:16 +11:00
cda574e627 Map 2017-11-24 08:47:17 +11:00
fda1977119 Fix for keyboard increase/decrease volume 2017-11-24 08:47:11 +11:00
f7bf0961cf Fix overflow issue on small players with menu open 2017-11-23 22:32:07 +11:00
61325bbad1 Vimeo captions fix 2017-11-23 20:50:07 +11:00
921cefd212 Moved to provider + type to make it cleaner in future, fix for multiple players 2017-11-23 17:35:35 +11:00
de6f0f1b77 Updated data attributes to data-plyr namespace. Speed menu fixes 2017-11-23 12:57:43 +11:00
7382553a78 Work on touch controls 2017-11-22 00:04:11 +11:00
4b82e89845 Fix for playing getter as currentTime check is flaky 2017-11-21 21:14:44 +11:00
d3b31e595a Handle no audio, more docs in code, fix for playing getter 2017-11-21 20:14:57 +11:00
f33bc5a5c6 Minor tweaks 2017-11-21 14:05:55 +11:00
f518ec108b Vimeo autopause option 2017-11-21 13:33:51 +11:00
edfc6cd475 Play button as toggle button, tooltip changes, docs updated, fullscreen fix 2017-11-21 13:12:36 +11:00
92cd67effb Docs to build custom CSS for plyr 2017-11-20 23:53:54 +11:00
da1e987444 WIP on docs example 2017-11-20 21:23:49 +11:00
2d4a166218 Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	dist/plyr.js.map
2017-11-20 10:48:53 +11:00
feae00224e Added ended and playing getters 2017-11-20 10:48:28 +11:00
000afdd300 Merge branch 'develop' of github.com:Selz/plyr into develop 2017-11-19 23:35:23 +11:00
0dc9681ae8 YouTube title 2017-11-19 23:35:07 +11:00
dc391c98c6 UI tweaks 2017-11-19 21:15:24 +11:00
4b62a5c74d Captions fix 2017-11-19 17:54:38 +11:00
3f744ef63a Formatting 2017-11-18 19:36:36 +11:00
5a244b7fed Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	dist/plyr.js.map
#	src/js/controls.js
2017-11-18 19:33:01 +11:00
4dca4bf93c Minor fixes 2017-11-18 19:31:45 +11:00
6984d6fb16 Controls cleanup, work on captions bug, click to invert time 2017-11-18 19:30:26 +11:00
d7a1c44281 Using fetch instead of xhr, grabbing title for YouTube 2017-11-16 11:38:06 +01:00
c64b8f6940 Started on error handling, Safari icon fix 2017-11-14 17:27:40 +01:00
9c4b53d761 Fix for YouTube .getVideoData() issue (fixes #709) 2017-11-14 13:28:52 +01:00
022b436c3f YouTube fix 2017-11-14 13:22:23 +01:00
6058bb0245 Docs 2017-11-12 08:16:47 +00:00
3ade86537d Docs, keyboard shortcut fixes 2017-11-12 08:14:14 +00:00
d80be3b903 More docs, event renamed 2017-11-12 07:45:52 +00:00
1a26681d87 Added Sparkk TV to the list of users 2017-11-10 00:19:44 +11:00
9171297764 More docs 2017-11-10 00:06:46 +11:00
ebd1a52e5d Config docs 2017-11-09 21:18:09 +11:00
743c84188e Fix for destroy 2017-11-09 20:54:14 +11:00
4879bea4a0 Moved console methods out of the root of the object 2017-11-09 20:01:13 +11:00
66917fd39b Use callback for loading Vimeo API 2017-11-09 19:44:07 +11:00
fd97607e55 Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	dist/plyr.js.map
2017-11-09 19:41:12 +11:00
f878581c8f UI bugs 2017-11-09 19:40:45 +11:00
f9602acf61 Callback for loadScript 2017-11-09 16:06:49 +11:00
86a5724bdb Missing code highlight 2017-11-09 00:22:40 +11:00
63c963d726 More docs 2017-11-09 00:21:44 +11:00
88bfa35b99 Test 2017-11-09 00:06:34 +11:00
bb66be98da Volume fixes and other tidy up work 2017-11-08 23:46:20 +11:00
c948e95ade Looping, increase/decrease volume fix 2017-11-08 00:37:14 +11:00
1a5f4b1b9e Merge branch 'develop' of github.com:Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	dist/plyr.js.map
#	src/js/defaults.js
2017-11-07 23:23:17 +11:00
3f41a0cf54 Merge branch 'develop' of github.com:Selz/plyr into develop
# Conflicts:
#	readme.md
2017-11-07 23:21:35 +11:00
966ca1acc3 Trap focus fix 2017-11-07 18:01:24 +11:00
e2c7491ccd Using the “href” attribute on SVG if supported, using hasAttribute 2017-11-07 09:58:37 +11:00
0ec0addbda Update readme.md 2017-11-07 09:16:41 +11:00
fae4ca12e0 Started on docs 2017-11-06 23:06:14 +11:00
84505da84b Automatic Vimeo aspect ratio 2017-11-06 22:00:00 +11:00
2497e25b3c Global listeners to prevent repeat binding 2017-11-06 21:19:00 +11:00
9c4b7e7094 Keyboard logic 2017-11-06 20:34:11 +11:00
3a9beaed59 Vimeo captions fix 2017-11-06 20:27:19 +11:00
1578525ee3 Finished aspect ratio setting 2017-11-06 20:24:07 +11:00
62c1b368cf Cleanup 2017-11-06 19:53:27 +11:00
f8ecea8fb7 Added Vimeo playback speed 2017-11-06 19:47:14 +11:00
0068710740 Started on documentation and aspect ratio option 2017-11-06 19:38:31 +11:00
d206b8ab34 Merge pull request #696 from yuriykuzin/enable-speed-controls-on-vimeo
Enable speed controls using Vimeo API
2017-11-06 19:37:47 +11:00
51c011b733 Merge branch 'master' into enable-speed-controls-on-vimeo 2017-11-06 19:37:02 +11:00
5fe477340b Tab focus classname change 2017-11-05 23:20:26 +11:00
45df319823 Keyboard shortcut tweaks 2017-11-05 23:09:33 +11:00
6bebbe4153 Key listeners fix 2017-11-05 20:49:37 +11:00
374de800a4 Captions fix 2017-11-05 18:57:22 +11:00
60084a17f8 YouTube volume fix 2017-11-05 18:40:41 +11:00
4d417d0396 Vimeo fix 2017-11-05 12:04:31 +11:00
e2d8bd2b73 Captions language fix 2017-11-05 11:59:15 +11:00
1c693df00b src getter fix, local storage fix 2017-11-05 11:45:02 +11:00
8aaa932050 Cleanup 2017-11-05 01:13:00 +11:00
3cd6c2acf6 Merge branch 'develop' of https://github.com/Selz/plyr into develop 2017-11-05 01:02:17 +11:00
3930ebb339 Menu design tweaks, moved logic into plugins 2017-11-05 01:02:10 +11:00
b102714067 Merge pull request #705 from friday/editorconfig
Add .editorconfig file
2017-11-05 00:49:45 +11:00
13d3037a53 Meta data and icons updated 2017-11-05 00:29:21 +11:00
1e7a60ee5c Add .editorconfig file 2017-11-04 14:16:00 +01:00
8d80f6b05d Removed log 2017-11-04 23:53:03 +11:00
3c99357f06 Vimeo fixes + small bug fixes 2017-11-04 23:18:47 +11:00
597b3fe0db Retrofit PRs 2017-11-04 22:41:18 +11:00
a757acad15 Merge pull request #577 from brandon-pereira/master
fix for svg4everybody conflicting with plyr
2017-11-04 22:25:27 +11:00
7913cf837f Merge branch 'master' into master 2017-11-04 22:25:17 +11:00
e98d356ede Merge branch 'master' into master 2017-11-04 22:22:49 +11:00
c9c20345c0 Merge pull request #613 from vers-one/master
Fix for handling explicitly set duration of audio
2017-11-04 22:19:47 +11:00
aca06be7ac Merge branch 'master' into master 2017-11-04 22:19:39 +11:00
550cc6a19b Merge branch 'master' into master 2017-11-04 22:19:17 +11:00
e44e93c117 Merge pull request #617 from oemueller/patch-1
[bugfix] target is null exception
2017-11-04 22:17:00 +11:00
a06a8150ef Merge pull request #649 from waltercruz/master
Adding title to the player html template
2017-11-04 22:16:28 +11:00
e787934ee6 Merge branch 'master' into master 2017-11-04 22:16:16 +11:00
be4b5ef4db Merge branch 'master' into master 2017-11-04 22:14:55 +11:00
55c5b8b07e Typo 2017-11-04 21:32:19 +11:00
a924d40620 Merge pull request #654 from jjui/patch-1
Enable start/stop toggle on whole element
2017-11-04 21:29:25 +11:00
0074e77a7c Update plyr.scss 2017-11-04 21:28:38 +11:00
f3141690ee Update plyr.less 2017-11-04 21:28:17 +11:00
7ac5b0e18b Merge pull request #678 from StudyTube/use-url-as-input-for-vimeo-player
Add URL as a possible input option to Vimeo player
2017-11-04 21:24:55 +11:00
d920de2a25 Small tweaks 2017-11-04 21:19:02 +11:00
5abf7e9535 Merge pull request #703 from gurupras/early-listener-fix
Allow Plyr.setup event listeners to be set up as separate event listeners
2017-11-04 18:15:03 +11:00
650ee2c18f Merge pull request #700 from ashkanhosseini/master
fix #684 memory leaks issues after destroy.
2017-11-04 18:11:35 +11:00
069c8093ae Small bug fixes 2017-11-04 14:45:06 +11:00
1cc2930dc0 ES6-ified 2017-11-04 14:25:28 +11:00
95734cf7cc Allow setup event listeners to be set up as separate event listeners
rather than in-conjunction with defaultListener

This allows the setup listeners to do things like
preventDefault()/stopImmediatePropagation() and have them work
2017-11-01 04:15:03 -04:00
3d50936b47 Split LESS into more granular files, Vimeo fixes 2017-10-28 20:14:33 +11:00
7234e2f5a3 fix #684 memory leaks issues after destroy. 2017-10-28 00:09:40 +03:00
dd9d5c8898 Linting and minor changes 2017-10-27 15:06:16 +11:00
e06b689f5c Enable speed controls using Vimeo API 2017-10-26 17:11:19 +03:00
71db66d802 Error pages 2017-10-26 20:59:40 +11:00
959b5a20e3 Inlined SVGs, fixed build 2017-10-26 00:10:56 +11:00
9de5c0cf39 Built JS 2017-10-26 00:00:15 +11:00
1a3868a6c6 Merge branch 'develop' of https://github.com/Selz/plyr into develop 2017-10-25 23:59:59 +11:00
378aa159b8 Docs/demo refresh 2017-10-25 23:59:53 +11:00
6876a9163d Merge pull request #694 from friday/fix/volume-steps
Restore volume stepping via key up/down
2017-10-25 23:59:15 +11:00
34d28a69ad Merge pull request #693 from friday/fix/instanceof-undefined
v3: Add instanceof wrapper to avoid TypeErrors
2017-10-25 23:54:10 +11:00
0715d3ae67 Restore up/down arrow behavior from v2 (10 steps between min and max instead of one) 2017-10-25 14:25:10 +02:00
542095f5eb Add instanceof wrapper that avoids TypeError when second argument is undefined 2017-10-25 14:10:38 +02:00
57517a9dcc Fullscreen improvements 2017-10-18 23:55:53 +11:00
751708ff23 Fix 2017-10-18 19:47:03 +11:00
fcf944788a Cleanup 2017-10-18 12:47:54 +11:00
36a84c5c2d Removed extra <progress> for populating lower fill on range inputs 2017-10-18 12:43:10 +11:00
4392abfc49 Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
2017-10-08 19:12:55 +11:00
3238b6a36a Fullscreen fix 2017-10-08 19:12:25 +11:00
18a5edef0e Linting 2017-10-08 19:10:04 +11:00
1b3a6b340d Add URL as a possible input option to Vimeo player
This is reasonable to processing correctly private Vimeo links, like https://vimeo.com/25345658/fe46e209ac - that contain not only vimeo id, but also private key
2017-10-06 14:41:57 +03:00
b3759e966d Version bump 2017-10-05 22:47:27 +11:00
34172b9aee Fullscreen bug fix (fixes #664) 2017-10-05 22:46:48 +11:00
02cb093f7b Small tweaks to focus 2017-10-03 00:00:45 +11:00
d6977473b1 Formatting 2017-10-02 21:03:51 +11:00
15cffad89e CDN URLs 2017-10-02 14:54:35 +11:00
a21ffe983c Demo fixes 2017-10-02 14:52:31 +11:00
0d96601d1a CDN URLs 2017-10-02 14:48:15 +11:00
9fb79f29fd Readme fix 2017-10-02 14:25:14 +11:00
032d73408f CDN URL updates 2017-10-02 14:18:44 +11:00
7959297a98 Merge branch 'develop' of https://github.com/Selz/plyr into develop 2017-10-02 13:55:08 +11:00
6dd010ea34 Comments, small tweaks 2017-10-02 13:55:03 +11:00
f89ddb2f1b Merge pull request #669 from friday/fix/prevent-buttons-from-submitting-form
Prevent buttons from submitting form (v3)
2017-09-27 23:33:28 +10:00
2e5cc272e3 Merge pull request #670 from friday/fix/errors-without-settings-pane
Avoid errors when initiating plyr without settings (v3)
2017-09-27 23:32:25 +10:00
ebd13c63e8 Avoid multiple errors when initiating plyr without 'settings' in controls 2017-09-27 05:09:56 +02:00
ec091266aa Prevent buttons from submitting form 2017-09-27 02:34:23 +02:00
ad105877ed Merge pull request #667 from friday/fix/caption-feature-detection
Fix 'TypeError: Cannot read property 'kind' of null' in captions feat…
2017-09-27 10:03:25 +10:00
c84f666b55 Fix 'TypeError: Cannot read property 'kind' of null' in captions feature detection if video lacks captions 2017-09-27 00:24:54 +02:00
J
72412d26a5 Update plyr.less 2017-09-09 13:31:39 +02:00
J
bf02c69daa Enable start/stop toggle on whole element
Related to issue https://github.com/sampotts/plyr/issues/587
2017-09-09 13:25:22 +02:00
2bba1f30e2 Fixing Vimeo captions, WIP on settings menu, prettier and VS code settings 2017-09-03 14:36:55 +10:00
01f50f03f1 dding title to the player html template (build) 2017-08-28 10:32:56 -03:00
f50f0eb63d Adding title to the player html template 2017-08-28 10:19:29 -03:00
2196665495 Cleanup 2017-08-16 13:30:27 +10:00
0148c76c30 ESLint, comments, quality and speed menus 2017-08-16 00:36:23 +10:00
3fe0c7c84b Update readme.md 2017-08-13 21:07:22 +10:00
18b2cbb2e9 Small tweak 2017-08-13 13:54:16 +10:00
f6a7555a1d Work on quality control 2017-08-06 21:00:31 +10:00
f7144dc0cb Fix bug when switching sources 2017-08-06 13:42:37 +10:00
a9957211f4 Work on playback rate changes 2017-07-31 09:58:30 +10:00
7b60e473fa Small tweaks 2017-07-23 21:13:11 +10:00
b114a6f42e [bugfix] target is null exception
when using 'play-large' without a 'play' button, the statement target = target[0]; caused an error. So it is necessary to check the value of target before accessing [0]
2017-07-12 22:17:25 +02:00
dfc516baf6 Merge branch 'develop' of https://github.com/Selz/plyr into develop 2017-07-09 17:17:26 +10:00
b0d3bcd15a Notes 2017-07-09 17:17:21 +10:00
03c3960e93 Tweaks 2017-07-09 17:14:42 +10:00
d0ceefe827 Gulp build 2017-07-06 23:41:34 -04:00
e756664750 Fix for https://github.com/sampotts/plyr/issues/601 2017-07-06 23:28:31 -04:00
21f444ed61 Tweaks 2017-06-12 09:26:01 +07:00
40b4f8e840 Tweaks 2017-06-04 22:39:21 +10:00
bc61dac4c5 Tidy up, fixing destroy 2017-06-04 18:30:37 +10:00
3605989226 Warning 2017-06-04 15:51:37 +10:00
a49d77afab Source change fix 2017-06-04 15:50:47 +10:00
7daa08c32f Change to proper constructor + prototypes 2017-06-04 15:27:37 +10:00
aaab9ad082 Seperated reduce motion check 2017-05-22 09:07:14 +10:00
86c9004183 More work on the menu 2017-05-22 08:55:45 +10:00
857dfe838c Menu toggle 2017-05-21 17:50:07 +10:00
6828bc00f8 Delete notes.md 2017-05-16 10:31:07 +10:00
e1a19faf26 URL updates 2017-05-16 10:20:58 +10:00
e95c81cc5b Update bower.json 2017-05-16 10:17:57 +10:00
f3bda17fa0 Merge branch 'master' into develop
# Conflicts:
#	demo/dist/demo.js
#	demo/src/js/main.js
#	dist/plyr.js
#	notes.md
#	src/js/plyr.js
2017-05-16 10:17:04 +10:00
c0eee58732 Plugin versions 2017-05-16 10:14:01 +10:00
bcf88cd024 Vimeo demo bug fix + repo move 2017-05-16 10:08:59 +10:00
966c3d875d Single instance only 2017-05-16 09:58:53 +10:00
fe9383bed5 Cleanup 2017-05-09 21:30:09 +10:00
2c31770030 Update notes 2017-05-09 00:20:22 +10:00
8d3e160166 Adding support for playsinline 2017-05-09 00:18:19 +10:00
408cfe5b97 Added support for passive event listeners 2017-05-08 23:07:19 +10:00
279fee3595 Bug fixes 2017-05-07 20:17:36 +10:00
28dddfcff2 Vimeo captions working 2017-05-07 20:07:08 +10:00
9e2580ec6a Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
2017-05-07 19:04:05 +10:00
aba5a9dc0e Utils object, work on Vimeo captions 2017-05-07 19:03:48 +10:00
d27a0b3855 updated to check for global namespace 2017-05-01 16:53:54 -06:00
a575aa25ac fix for svg4everybody conflicting with plyr 2017-05-01 15:50:54 -06:00
9999828505 Merge pull request #574 from mapmelabs/youtube-loop
Implement loop in YouTube
2017-04-28 13:12:31 +10:00
b04301c211 Implement loop in YouTube 2017-04-27 11:53:53 -03:00
97157efcfa More work on Vimeo captions 2017-04-26 00:24:42 +10:00
3756476809 Merge branch 'develop' of github.com:Selz/plyr into develop 2017-04-25 22:39:21 +10:00
b3d798eeee Gulp tweak 2017-04-25 22:39:14 +10:00
b499622eb8 Started on Vimeo captions 2017-04-25 20:45:25 +10:00
04b8d0bac8 Tweaks 2017-04-25 19:31:34 +10:00
8ea4cbd942 Tidy up 2017-04-25 18:43:09 +10:00
7889ae1126 Built JS 2017-04-25 18:37:56 +10:00
897d49ad87 Merge branch 'develop' of https://github.com/Selz/plyr into develop 2017-04-25 18:37:36 +10:00
1960d35d8b More work on menus and tidy up 2017-04-25 18:37:31 +10:00
0b7d0dedf6 Merge pull request #545 from silverwind/blank-mp4
Add blank.mp4 to dist files
2017-04-25 12:40:20 +10:00
948e2cc66c Merge branch 'develop' into blank-mp4 2017-04-25 12:40:13 +10:00
396b816a1f Merge pull request #563 from stormrockwell/master
removed vimeo id parsing because it is not necessary
2017-04-25 12:37:43 +10:00
0a58cbfd59 Merge branch 'develop' into master 2017-04-25 12:37:35 +10:00
bbe4b7e565 Notes 2017-04-22 14:55:03 +10:00
2ecca2cbe3 removed vimeo id parsing because it is not necessary 2017-04-19 15:16:03 -04:00
f5d80fa888 Notes 2017-04-19 22:40:32 +10:00
f2bbe4eb12 Looping menu (WIP) 2017-04-19 22:34:52 +10:00
60e51b7077 Added notes 2017-04-19 21:33:23 +10:00
01d1ac9ab9 Toggle menu 2017-04-17 21:05:35 +10:00
9b2396f5ff Airplay and PiP 2017-04-17 01:28:52 +10:00
da15980b8a ID fix and styling fix 2017-04-17 00:32:41 +10:00
452678867f More work on menus 2017-04-16 20:38:45 +10:00
ff2d27f8e5 Cleanup events and references 2017-04-16 13:00:57 +10:00
546cdaad92 Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
2017-04-15 23:22:35 +10:00
5d38497f07 Formatting 2017-04-15 23:22:14 +10:00
808a3af3cf Formatting 2017-04-15 23:21:18 +10:00
889712761a Merge branch 'develop' of github.com:Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	src/js/plyr.js
2017-03-29 09:05:25 +11:00
46fab972a0 Namespacing 2017-03-29 09:03:33 +11:00
535c046b62 Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	src/js/plyr.js
2017-03-28 09:30:37 +11:00
55dfab8394 Tweaks 2017-03-28 09:19:58 +11:00
18bf4d84b9 Menu creation (WIP) 2017-03-28 00:12:33 +11:00
ef1d73df15 Controls rewrite 2017-03-27 00:25:41 +11:00
684107da5c WIP on new controls creation 2017-03-26 21:32:41 +11:00
2a97a9a9c5 Add blank.mp4 to dist files
For a complete "offline" experience, it's necessary to self-host the
file, so include it in the dist files for that purpose.
2017-03-25 10:58:36 +01:00
ca12343b16 Merge branch 'develop' of https://github.com/Selz/plyr into develop 2017-03-25 18:44:17 +11:00
a974fbf31c Notes 2017-03-25 18:44:10 +11:00
6eaf33ec6c Merge pull request #520 from platformpurple/feature/subtitles
Feature/subtitles
2017-03-25 18:43:45 +11:00
33fef7faee Merge branch 'develop' into feature/subtitles 2017-03-25 18:43:36 +11:00
b083bf4297 Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.css
#	dist/plyr.js
#	src/js/plyr.js
#	src/less/plyr.less
#	src/scss/plyr.scss
2017-03-25 11:24:38 +11:00
4957e4d80c Version bump to 2.0.12 2017-03-25 10:58:41 +11:00
605f8a8249 Changelog update 2017-03-25 10:57:52 +11:00
7490a7e7f3 Merge pull request #468 from jronallo/captions-listener
allow for setting additional listener for captions
2017-03-25 10:51:54 +11:00
f32527feb4 Merge pull request #504 from ShimShamSam/master
Add blankUrl option to set the URL for blank.mp4
2017-03-25 10:50:55 +11:00
ebc7ed538a Manual merge of #509 2017-03-25 10:49:04 +11:00
a60868bfe8 Clean up 2017-03-25 10:47:37 +11:00
4a2866d05f Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
2017-03-25 10:37:21 +11:00
1a05f352c7 Code formatting 2017-03-25 10:37:00 +11:00
ba27de0669 Merge pull request #510 from platformpurple/feature/loop-events
Added key bindings for loop
2017-03-25 10:35:15 +11:00
e21e7054ce Merge branch 'develop' into feature/loop-events 2017-03-25 10:35:08 +11:00
bc323e905c Manual merge of #543 PR 2017-03-25 10:27:03 +11:00
afa1fe9d5f Merge pull request #514 from platformpurple/improvement/loop-color-area
Improvement/loop color area
2017-03-25 10:22:10 +11:00
2444efc834 Merge branch 'develop' into improvement/loop-color-area 2017-03-25 10:22:02 +11:00
7b6257ff20 Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
2017-03-25 10:09:14 +11:00
13973125fb Loop variable naming 2017-03-25 10:08:39 +11:00
ddf9104349 Merge pull request #511 from platformpurple/develop
Fix on typo
2017-03-25 10:07:07 +11:00
47b53fffb4 remove commented out code 2017-03-24 17:29:48 +02:00
9ba3753f80 toggle quality options 2017-03-24 17:25:09 +02:00
a353194fe1 make config.captions.selectedIndex number 2017-03-22 15:50:56 +02:00
c205c47509 set captionExists to true if selectedIndex is bigger than capt source 2017-03-22 13:38:08 +02:00
9c867edfbc fix data typo in language button 2017-03-18 01:59:20 +02:00
9919d80782 check if captions exists 2017-03-15 17:18:34 +02:00
a971850d26 Update readme.md 2017-03-09 15:35:29 +11:00
8464ffe6ad Conflicts and tracks array on config 2017-02-24 16:38:00 +02:00
6537225c61 Subtitles tracks 2017-02-24 16:32:17 +02:00
dcbf59bd89 Colored strip indicating looped area 2017-02-15 17:41:04 +02:00
21d478d396 Add looping key bindings to allowed array 2017-02-14 17:15:27 +02:00
054c243416 Fix on typo and gulp 2017-02-14 16:44:29 +02:00
d57e453541 Fix on typo 2017-02-14 16:42:40 +02:00
3f45ef4908 Removed console 2017-02-14 16:29:05 +02:00
1fd742464d Added key bindings for loop 2017-02-14 16:04:58 +02:00
382397407f Generated dist files 2017-02-12 00:15:21 -05:00
82809235b9 Documented the blankUrl option 2017-02-11 23:59:14 -05:00
7d5c507f16 Allow configuration of the blank.mp4 URL
This is useful for people behind firewalls who need to host a blank mp4 themselves.
2017-02-11 23:50:49 -05:00
bc139f16a7 Update readme.md 2017-02-10 11:21:20 +11:00
f6f3284dc5 Update readme.md 2017-02-10 11:19:37 +11:00
f4d2f1856f Update readme.md 2017-02-09 23:38:52 +11:00
871e19ed92 Update readme.md 2017-02-09 23:37:29 +11:00
9c599884a8 Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	src/js/plyr.js
2017-02-05 11:36:53 +11:00
cbef45841c Menu work 2017-02-05 11:34:33 +11:00
96d9f302c2 Merge pull request #490 from platformpurple/develop
Playback speed and looping controls
2017-02-05 11:31:58 +11:00
afcdf17a72 Removed not needed functions + reverted demo.js to previous 2017-02-03 14:52:38 +02:00
1bcdbe4c00 Refactored loop event buttons + on 'No Loop' cleared displayed timing 2017-02-02 11:38:08 +02:00
45c0ded88c Loop functionality 2017-02-01 19:16:39 +02:00
ea30ad9494 Playback speed control settings 2017-01-31 17:21:33 +02:00
7608615702 Merge branch 'develop' of https://github.com/Selz/plyr into develop 2017-01-11 20:14:48 +11:00
cc5f37392f ToDo notes, code tidy up 2017-01-11 20:14:41 +11:00
413fcbcb8c Merge branch 'develop' of github.com:Selz/plyr into develop
# Conflicts:
#	dist/plyr.js
#	src/js/plyr.js
2017-01-10 21:47:49 +11:00
c49d0a99e4 JsBeautifier 2017-01-10 21:43:28 +11:00
5a0cb9289c JsBeautifier in use, syntax tweaks 2017-01-10 20:22:18 +11:00
72998c4c41 Merge pull request #437 from tv2/playground
Fixed typo
2017-01-10 20:21:01 +11:00
da48be495b Merge pull request #477 from iamrobert/patch-1
Update index.html
2017-01-10 14:51:40 +11:00
c843ed3460 Update index.html
Just missing the closing </li>
2017-01-10 11:50:26 +08:00
4232aa9ea4 Update issue_template.md 2017-01-10 09:47:46 +11:00
f6612fa78c Update issue_template.md 2017-01-10 09:45:41 +11:00
bce1d983cb Merge pull request #457 from amowu/patch-3
fix: Firefox can not display captions
2017-01-04 08:45:40 +11:00
047fc43f8f Merge pull request #458 from amowu/patch-4
fix: parse webVTT time NaN
2017-01-04 08:45:06 +11:00
96ae866baa allow for setting additional listener for captions 2016-12-26 17:06:59 -05:00
0cbfc9252c fix: parse webVTT time NaN 2016-12-16 14:32:04 +08:00
d02e57bdb3 fix: Firefox can not display captions 2016-12-15 16:38:46 +08:00
a1d5bccac2 Fixed typo 2016-11-30 08:54:24 +01:00
a9bb8afca4 v2.0.11 2016-11-27 20:18:30 +11:00
28cd92b708 Merge branch 'master' of https://github.com/Selz/plyr 2016-11-27 20:15:19 +11:00
a44c7ecc3a Fix for iPad and YouTube issues 2016-11-27 20:15:15 +11:00
663c1fb627 Merge pull request #427 from amowu/patch-2
Fix cannot scroll after destroyed
2016-11-27 20:09:49 +11:00
a7969b8e9e Fix cannot scroll after destroyed
In single page application, switch router when plyr is fullscreen mode, page cannot scroll, because `document.body.style.overflow` is `hidden`
2016-11-24 11:21:43 +08:00
4ca3f030cc Merge pull request #419 from amowu/patch-1
refactor: miss prefix
2016-11-18 09:48:40 +11:00
5214c5d55d Merge pull request #425 from sebastiancarlsson/cleanup-called-twice-bug
fixes bug where cleanUp would be called twice
2016-11-18 09:40:34 +11:00
3e6ed7b69b fixes bug where cleanUp would be called twice 2016-11-17 15:43:26 +01:00
7d2a8d343a Update 2016-11-16 09:41:06 +11:00
03aacf483f Update readme.md 2016-11-16 09:40:09 +11:00
02bc8c8445 refactor: miss prefix
fix _fullscreen.prefix can't work
2016-11-10 16:27:10 +08:00
7965b82cca Quality WIP 2016-11-06 21:47:44 +11:00
bae04a492a Merge branch 'master' into develop
# Conflicts:
#	demo/index.html
#	dist/plyr.js
2016-11-06 15:55:55 +11:00
73a1391f2f Update readme.md 2016-11-02 18:45:37 +11:00
660ff0434d Cache bust 2016-11-02 18:29:38 +11:00
94208dce76 v2.0.10
- Added seek event fixes for Vimeo and YouTube (fixes #409)
- Added support for embed URLs rather than ID only (fixes #345)
2016-11-02 18:14:06 +11:00
efe54fbba4 Added seek event fixes (fixes #409), Added support for URLs (fixes #345) 2016-11-02 18:09:40 +11:00
10561d6c83 Merge pull request #408 from gurupras/urlparser
Added logic to parse youtube video id
2016-11-02 16:59:28 +11:00
72404e77e5 PiP 2016-11-01 12:00:16 +11:00
0ef87f93a6 Added logic to parse youtube video id
This commit is targetted at solving issue#345 and adds
    functionality to parse youtube video IDs from various
    types of youtube video URLs.

    Other embed types like vimeo/soundcloud can be extended by
    following a similar structure as implemented in this commit.
2016-10-30 00:49:17 -04:00
Sam
c7310c21fb Fullscreen fix, styling 2016-10-24 00:11:47 +11:00
Sam
ed9e27b64f Merge branch 'develop' of https://github.com/Selz/plyr into develop 2016-10-23 21:42:18 +11:00
801ed63be5 Work on PiP 2016-10-23 21:21:42 +11:00
Sam
2aa9b267ab Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	src/js/plyr.js
2016-10-23 21:16:49 +11:00
Sam
90338d9600 Tweaks 2016-10-23 21:15:19 +11:00
5cecf16d4f Merge branch 'master' into develop
# Conflicts:
#	demo/dist/demo.js
#	dist/plyr.css
#	dist/plyr.js
2016-10-23 15:27:28 +11:00
a3ed309342 v2.0.9
- Temporary patch for the YouTube API issues with `getDuration()` (relates to #374)
2016-10-23 15:18:53 +11:00
08b4c09b89 Temporary patch for the YouTube API issues with getDuration() (relates to #374) 2016-10-23 15:18:08 +11:00
a509a5e1bc v2.0.8
- Added `isPaused()` API method (thanks to @darrena092)
- Allowed `.on()` API method to be chainable (thanks to @gurupras) (fixes #357)
- Improved the "awful" rendering of captions on small screens in fullscreen mode (fixes #390)
- Fix for Firefox VTT compatibility (thanks to @magourex)
- Fix for Firefox Developer Edition blank video due to `-webkit-mask-image` issue (fixes #392)
- Added Issue and PR templates with the aim of reducing duplicate or duff issues
2016-10-23 13:48:05 +11:00
bec10e7836 Fix for caption size (fixes #390), Fix for Firefox Dev (fixes #392) 2016-10-23 13:35:49 +11:00
f9a184800b Add Issue and PR templates 2016-10-23 13:34:44 +11:00
f428c3ff8b Manually merged #395 2016-10-23 12:19:39 +11:00
97eb40a8e3 Merge pull request #389 from darrena092/master
Added .isPaused().
2016-10-23 11:51:10 +11:00
8211631950 Gulp build done. 2016-10-06 15:43:41 +01:00
a17cbb0e8b Added .isPaused to API 2016-10-06 15:33:49 +01:00
21a30f1b6f Fixed for array passed to _on and _off 2016-10-03 17:16:05 +11:00
Sam
613c45ede9 Merge branch 'master' into develop 2016-10-01 22:18:40 +10:00
Sam
8743c6a08d Code style 2016-10-01 22:18:01 +10:00
8098be6f93 Merge pull request #379 from magourex/master
Support WebVTT with CRLF or LF Line separator with firefox #378
2016-10-01 22:10:35 +10:00
Sam
eba0831538 Manually merged #385 2016-10-01 22:07:01 +10:00
1c73c9fbfe Update plyr.js 2016-09-27 10:57:35 +02:00
Sam
1ad103c29f Menu animation 2016-09-26 23:21:57 +10:00
Sam
ca37b4c9ac Menu 2016-09-25 23:54:49 +10:00
d3bbf09d12 More menu work 2016-09-25 20:01:58 +10:00
f608317eec Merge branch 'develop' of https://github.com/Selz/plyr into develop
# Conflicts:
#	dist/plyr.css
#	dist/plyr.js
2016-09-14 15:22:41 +10:00
c8b9c9bcaa Expanded 2016-09-13 23:52:25 +10:00
Sam
d638cdcdd3 Started on PIP support 2016-09-13 00:16:27 +10:00
46f82a4af3 Added quality in menu 2016-09-07 22:18:05 +10:00
978606edb4 CSS path 2016-09-06 23:54:04 +10:00
Sam
42a2642d40 Icon fix 2016-09-06 23:50:59 +10:00
Sam
37840c3844 Working on settings menu 2016-09-06 23:48:09 +10:00
28335ef3d8 Merge pull request #356 from amowu/feature/add-playback-speed
Add playback speed
2016-09-06 20:46:00 +10:00
78ec5b3322 refactor: sorting speed 2016-09-05 22:56:19 +08:00
ac7e1ab299 test: add speed-up button 2016-09-05 18:00:11 +08:00
ea60fd0f45 docs: update readme 2016-08-31 17:18:44 +08:00
c291e8c5d9 refactor: check config.speeds format 2016-08-31 15:42:01 +08:00
f0ac542a7f refactor: add localStorage supporting 2016-08-31 15:34:44 +08:00
a412085785 feat: add playback speed button 2016-08-31 15:11:29 +08:00
Sam
435b5c74bf Fixed API method, added new methods (fixes #346, #351)
- Fixed `getCurrentTime()` method (fixes #351)
- Added `getVolume()` , `isMuted()` and `getDuration()` API methods (fixes #346)
2016-08-29 23:36:43 +10:00
Sam
15fd7041ab Fixed AMD definition 2016-08-26 21:43:51 +10:00
1ced6b4d67 Vimeo IE9/10 (Fixes #348), HTML5 ready event (Fixes #349) 2016-08-26 18:15:24 +10:00
Sam
6694c1e6cf Fix for Firefox full screen (fixes #343) 2016-08-23 00:34:43 +10:00
19ca906e50 Update changelog.md 2016-08-22 20:41:49 +10:00
12e94775d6 Global keyboard shortcut changes 2016-08-22 14:44:18 +10:00
df7f52d885 Added ‘global’ keyboard shortcut option 2016-08-22 14:15:49 +10:00
d5b5faafbb Version bump for NPM 2016-08-22 13:08:19 +10:00
a318e8588b Merge branch 'master' of https://github.com/Selz/plyr 2016-08-22 13:07:07 +10:00
51fb252cd8 Update changelog.md 2016-08-22 13:06:26 +10:00
86b2f61b56 Bump to v2.0.0 2016-08-22 13:00:47 +10:00
232a9fe868 Update changelog.md 2016-08-22 12:53:38 +10:00
e8bfe73b1d Update readme.md 2016-08-22 08:40:02 +10:00
ab0d762675 Update readme.md 2016-08-21 22:46:11 +10:00
a6a314e011 Update readme.md 2016-08-21 21:53:16 +10:00
514bdff92e Update readme.md 2016-08-21 21:53:02 +10:00
745e56a3a3 Update readme.md 2016-08-21 21:40:24 +10:00
130fb78b4c Version bump 2016-08-21 19:47:13 +10:00
3718ec69ba Use minified 2016-08-21 19:45:45 +10:00
4610f4a8c9 Firefox and Edge fixes 2016-08-21 19:44:46 +10:00
a8062354ec Loading tweaks, Microsoft Edge tweaks 2016-08-21 19:25:21 +10:00
Sam
aac0a5a3a9 Work on docs 2016-08-21 10:30:11 +10:00
Sam
92b9e3400b Keyboard shortcuts 2016-08-20 23:39:18 +10:00
Sam
bea513f5dd Jshint tweaks, changelog 2016-08-20 20:11:21 +10:00
9d109bf02d Refactoring and bug fixing 2016-08-20 18:02:02 +10:00
fc45ab48c9 Merge branch 'master' into develop
# Conflicts:
#	src/js/plyr.js
2016-08-20 17:46:05 +10:00
58e9b02405 Merge 2016-08-06 11:09:55 +10:00
b578fb4840 Merge branch 'master' of https://github.com/Selz/plyr 2016-08-06 11:08:33 +10:00
f18d9589eb Font stack SASS fix (Fixes #328) 2016-08-06 11:08:28 +10:00
35c6ec9461 Manually merged #313 PR 2016-08-06 11:08:04 +10:00
56d9730d0a Merge pull request #326 from mkaziz/master
Updated define to work with AMD imports
2016-08-06 10:15:53 +10:00
6e18bc8b31 Updated define to work with AMD imports 2016-08-04 02:05:12 -05:00
81756a1af9 Merge pull request #322 from mortonfox/patch-1
Fix the Initialising and Options anchor links
2016-07-30 14:10:34 +10:00
05e1ab1165 Fix the Initialising and Options anchor links 2016-07-30 00:09:39 -04:00
a0ddc5e6eb Merge pull request #321 from electerious/patch-1
Added Array as selector in .setup() to readme
2016-07-25 08:53:29 +10:00
dc40b1f93a Added Array as selector in .setup() to readme
Documentation for #319
2016-07-24 20:52:20 +02:00
d7cc29f2fb Vimeo keyboard focus fix (Fixes #317), Fix for Vimeo on basic support devices 2016-07-23 11:11:17 +10:00
0505e49038 Vimeo API upgrade, YouTube Bugfix, Array support
- Vimeo API upgrade
- Fix for YouTube bug introduced in v1.8.9 (Fixes #320)
- Added support for passing array to .setup() (Fixes #319)
2016-07-23 10:42:06 +10:00
6ff1e47341 Merge branch 'master' of https://github.com/Selz/plyr 2016-07-21 21:59:26 +10:00
e72a91de6e Fix for seek issues introduced in v1.8.9 2016-07-21 21:59:16 +10:00
52ec4c012d Update readme.md 2016-07-21 21:32:56 +10:00
ae89c92ab6 Update readme.md 2016-07-21 21:31:09 +10:00
57ad124ce8 v1.8.9 2016-07-21 21:25:27 +10:00
a85d45d2e5 Fix for fullscreen not being defined (Fixes #295) 2016-07-21 21:21:10 +10:00
a6f57fc034 Fix for multiline captions (Fixes #314) 2016-07-21 21:15:44 +10:00
04c9653b86 Merge branch 'master' of https://github.com/Selz/plyr 2016-07-21 21:14:29 +10:00
b8cdc71001 Clean up of type checks and fix for _restart() (Fixes #315) 2016-07-21 21:14:22 +10:00
277ebf0fd1 Merge pull request #312 from dpschen/patch-1
Add kirby-plyrtag
2016-07-14 22:03:50 +10:00
7682d998e7 Add kirby-plyrtag
Added a Kirby cms kirbytag https://getkirby.com/
2016-07-14 12:52:28 +02:00
05b9b9a831 Fix for MEDIA_ERR_SRC_NOT_SUPPORTED when calling .source() API method 2016-07-14 17:13:37 +10:00
eee699cec6 Version bump 2016-07-10 20:59:42 +10:00
3c9e9862d8 Added getCurrentTime API method (fixes #292) 2016-07-10 20:58:19 +10:00
39dc651a9d Fix for !hideControls on touch devices (fixes #303) 2016-07-10 20:50:55 +10:00
4effda125a Merge branch 'master' of https://github.com/Selz/plyr 2016-07-10 20:45:58 +10:00
bf9de231d8 Styling minor tweaks 2016-07-10 20:45:54 +10:00
ef12332505 Update readme.md 2016-06-29 16:23:38 +10:00
1b735f1727 Update readme.md 2016-06-26 22:21:19 +10:00
7f7ecf852e Line height fix 2016-06-26 09:07:42 +10:00
931672895f Reverted font size change 2016-06-26 09:04:38 +10:00
0952bc8239 Built JS 2016-06-26 08:45:06 +10:00
7e7508ca82 Fixed overflow issues (fixes #286) 2016-06-26 08:34:36 +10:00
095d100ba4 Version bump 2016-06-25 23:47:30 +10:00
c61fad51c1 Fix for z-index on large play button 2016-06-25 23:46:37 +10:00
7b11c6803d Merge pull request #283 from arrowthemes/patch-1
Make the player button clickable on small videos
2016-06-25 17:44:07 +04:00
9b75436380 v1.8.3
- Disabled iPad support for YouTube and Vimeo due to iOS limitations with iFrame playback
- Fixed IE11 icon loading (fixes #269)
- Updated screenshot (fixes #281)
- Added WordPress plugin (fixes #239)
- Added Neos plugin
- Added HLS, Shaka and dash.js examples (see #235 for more)
- Improvements for controls hiding and showing on touch devices
2016-06-25 23:39:00 +10:00
be19b72719 Merge branch 'master' of https://github.com/Selz/plyr
# Conflicts:
#	dist/plyr.css
#	src/less/plyr.less
#	src/scss/plyr.scss
2016-06-25 22:35:04 +10:00
2fdcc18356 Hide Shadow DOM elements 2016-06-25 22:33:23 +10:00
6425a33ccd Merge pull request #284 from Integer64/develop
fix name svg
2016-06-22 19:10:48 +01:00
12c5dbd290 fix name svg 2016-06-23 01:56:14 +08:00
cb591dac0c Make the player button clickable on small videos
If you set the plyr video to width of 300px, the plyr__controls overlays the play centered play button such that you can't click on the play button. Adding a z-index on the plyr .plyr__play-large fixes that.
2016-06-21 21:59:00 +03:00
4c1cdea56e Merge pull request #275 from wilsonmsalberto/master
Prevent error when verifying if play buttons exist
2016-06-13 18:49:20 +01:00
80cfabbaf9 Prevent error when verifying if play buttons exist 2016-06-13 17:01:46 +01:00
Sam
c7d28b09c0 Fixed event bubbling 2016-06-09 11:05:07 +01:00
Sam
161dd48312 Fixed log message 2016-06-09 09:57:16 +01:00
Sam
383515c1b7 Merge branch 'master' of https://github.com/Selz/plyr 2016-06-09 09:49:09 +01:00
Sam
98792168e4 Changes to setup return value, SVG bug fix (fixes #269) 2016-06-09 09:49:01 +01:00
01437a4a38 Merge pull request #271 from thegrammarnazi/patch-3
correct grammar
2016-06-09 09:46:49 +01:00
03ed86f5c2 correct grammar 2016-06-09 01:39:52 -05:00
Sam
1a745e1eaa Merge branch 'master' of https://github.com/Selz/plyr 2016-06-07 12:34:40 +01:00
Sam
70646ca907 See changelog (fixes #265, #253, #257) 2016-06-07 12:34:36 +01:00
af774b6f02 Merge pull request #260 from cytec/fix-control-icon-size
use $plyr-control-icon-size in sass file
2016-06-02 10:41:36 +01:00
7a9eac093a use $plyr-control-icon-size in sass file 2016-06-02 11:40:09 +02:00
Sam
4afd311ef6 Version bump 2016-06-02 10:19:35 +01:00
Sam
7eec6c6739 Fix for multiple sprites being requested (fixes #259) 2016-06-02 10:18:33 +01:00
Sam
521431e093 Fix for scroll direction on volume (fixes #258) 2016-06-01 09:38:29 +01:00
24bc415faf Merge pull request #256 from MrSnowflake/develop
In specific cases Plyr fails to initiate YT: YT.Player is not a constructor
2016-05-31 08:26:53 +01:00
Sam
552f448ccd Seek rounding from 1 to 4 decimal places (fixes #242) 2016-05-30 07:41:17 +01:00
152e94f229 Improved YT initialized check.
Added an extra check to see wether YT API has been initialized. The current check is inadequate as YT can be an object while the API still isn't completely initialized.
2016-05-30 00:35:07 +02:00
cb318dd6ad Update readme.md 2016-05-27 08:42:11 +01:00
Sam
9ee0d00a35 Merge branch 'master' of https://github.com/Selz/plyr 2016-05-26 22:32:23 +01:00
Sam
c0909095e3 Added disableContextMenu option to hide the right click context menu (fixes #248 and #225) 2016-05-26 22:32:18 +01:00
1e732694eb Merge pull request #246 from zvizvi/master
FIx Plyr to work with RTL systems
2016-05-26 08:03:40 +01:00
30922246e9 FIx Plyr to work with RTL systems 2016-05-26 03:35:08 +03:00
edf5a14171 FIx Plyr to work with RTL systems
(less)
2016-05-26 03:33:05 +03:00
1c9f7901bc FIx Plyr to work with RTL systems
(scss)
2016-05-26 03:32:22 +03:00
1bd6ffc84d Merge pull request #237 from itaditya/master
Update readme.md
2016-05-25 19:13:13 +01:00
845ed000fc Merge pull request #244 from thijstriemstra/patch-1
reference unminified js script
2016-05-25 19:12:05 +01:00
c7b2347ccd reference unminified js script
Reading the minified js script is impossible so reference the source version instead.
2016-05-25 19:41:12 +02:00
a2f18c4e31 Merge pull request #241 from rabbitears/patch-1
Fix typo
2016-05-24 21:52:26 +01:00
37c8948d2c Fix typo 2016-05-24 14:08:15 -04:00
Sam
351e1540c5 Version bump 2016-05-23 22:33:16 +01:00
Sam
b3299b4641 Fix for Tooltips overflowing (fixes #230) 2016-05-23 22:29:20 +01:00
Sam
be2e7d4c99 Always hide standard controls (Fixes #225) 2016-05-23 21:19:53 +01:00
Sam
7238eab737 Merge branch 'master' of https://github.com/Selz/plyr 2016-05-23 21:11:54 +01:00
Sam
3c2921b994 Restore scroll position when exiting fullscreen (fixes #236) 2016-05-23 21:11:43 +01:00
179c6fca0b Update readme.md 2016-05-23 19:21:43 +01:00
Sam
69194915d4 Sprite loading improvements, touch controls
- SVG sprite loading automatically for an easier setup
- Touch devices now show controls on touch rather than pausing playback
2016-05-23 19:16:48 +01:00
341fd59cf6 Update readme.md 2016-05-23 21:34:57 +05:30
a6c8b7e506 Update readme.md
thang was a less common word , keeping it simple by using 'thing' is I think good , also there were SASS support so why not add that too.
2016-05-22 16:36:30 +05:30
98e4c5acea Decreased sensitivity and inverted scroll on volume slider (scroll up to increase, down to decrease) 2016-05-19 12:06:51 +10:00
1496b21c83 Version bump 2016-05-19 11:59:52 +10:00
ac0061b83e Bug fix for no buffer 2016-05-19 11:56:24 +10:00
0b7dc51bd1 Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.css
#	dist/plyr.js
2016-05-19 11:32:14 +10:00
126f80ed78 Reverted LESS structure for now 2016-05-19 11:31:27 +10:00
e0ef7482c6 Merge pull request #227 from igoradamenko/scroll-on-volume-slider
Add scroll listener on volume slider
2016-05-19 10:43:22 +10:00
6ffb971226 Add scroll listener on volume slider 2016-05-19 02:11:41 +03:00
72187a89dd Update readme.md 2016-05-19 08:47:42 +10:00
a461500ab9 Update readme.md 2016-05-17 12:38:52 +10:00
c830af492c Merge pull request #216 from IonicaBizauKitchen/fix
Removed "Node Package Manager" in readme.md
2016-05-17 08:30:25 +10:00
1f6f841fcb Removed "Node Package Manager" in readme.md
`npm` does not stand for "Node Package Manager" because `npm` is not an acronym. It is a bacronymic abbreviation for "npm is not an acronym".

https://www.quora.com/I-keep-hearing-NPM-doesnt-stand-for-Node-Package-Manager-what-does-it-stand-for
2016-05-16 17:59:37 +03:00
99960c0dc5 Fix for Vimeo fullscreen (fixes #214) 2016-05-16 12:28:28 +10:00
e8a8b08215 Merge branch 'master' of https://github.com/Selz/plyr 2016-05-16 12:15:15 +10:00
a989e87a2d Changed icon prefix default to avoid clashes 2016-05-16 12:15:09 +10:00
Sam
0bceeb4674 Merge branch 'master' of https://github.com/Selz/plyr
# Conflicts:
#	dist/plyr.css
#	src/less/variables.less
2016-05-15 19:54:03 +10:00
Sam
5a433f2fc8 Remove unused styles 2016-05-15 19:52:55 +10:00
c86b824a04 Comment 2016-05-15 18:59:13 +10:00
21c2276359 Build changes, sprite.svg => plyr.svg 2016-05-15 18:57:21 +10:00
602944ea4f Fix for bug in v1.6.7 2016-05-14 09:18:04 +10:00
f4a9ffcec7 Merge branch 'master' of https://github.com/Selz/plyr 2016-05-14 08:57:07 +10:00
d2e9c61fd7 iOS bug fixes (fixes #213) 2016-05-14 08:56:59 +10:00
c8cd051a00 Update readme.md 2016-05-14 01:09:20 +10:00
448c070898 Merge branch 'master' of https://github.com/Selz/plyr
# Conflicts:
#	dist/plyr.css
2016-05-14 00:48:56 +10:00
7f624ebbb7 Icon tweaks, IE button fix 2016-05-14 00:48:21 +10:00
Sam
4a69ef3874 Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.css
#	src/less/plyr.less
2016-05-11 22:47:27 +10:00
31c933af38 Merge pull request #209 from robinpoort/master
Add CSS settings
2016-05-11 22:39:54 +10:00
00137fe46b Compile css file 2016-05-11 13:46:47 +02:00
b23a16826e Adding SCSS settings
- Added setting to be able to disable the border-box if you already defined that in your own css
- Added setting to be able to disable touch-action if you already defined that in your own css
- Added setting to choose not to use !important for sr-only class
2016-05-11 13:46:40 +02:00
2a822d7b45 Adding LESS settings
- Added setting to be able to disable the border-box if you already defined that in your own css
- Added setting to be able to disable touch-action if you already defined that in your own css
- Added setting to choose not to use !important for sr-only class
2016-05-11 13:46:19 +02:00
cc5b363d66 Version bump 2016-05-11 10:18:34 +10:00
7e53f01d44 Fix for #206 2016-05-11 10:17:28 +10:00
d351f9f172 Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.css
#	src/less/plyr.less
2016-05-10 10:01:29 +10:00
4d67d68c6b Built CSS 2016-05-10 09:35:45 +10:00
3f20462943 Restore simplicity to LESS file structure 2016-05-10 09:35:19 +10:00
ab26525f09 Merge pull request #204 from robinpoort/master
Broken progress bar styling IE10
2016-05-10 09:17:09 +10:00
e431d7594b Fix broken progress bar styling IE10 2016-05-09 17:47:10 +02:00
8b75bec3d2 Fix broken progress bar styling IE10 2016-05-09 17:40:14 +02:00
1a5e56ed46 Fix broken progress bar styling IE10 2016-05-09 17:39:36 +02:00
3470d5f5e6 Merge branch 'master' into develop
# Conflicts:
#	src/less/plyr.less
2016-05-09 19:11:57 +10:00
9ff933e532 Merge pull request #202 from robinpoort/master
Removing duplicate selectors
2016-05-09 19:09:23 +10:00
299dfe4afe Removing duplicate selectors 2016-05-06 12:37:18 +02:00
6921070688 Removing duplicate selectors 2016-05-06 12:36:14 +02:00
bb976ccf4b Merge pull request #200 from shakeelmohamed/feature/youtube-onstatuschange-event
Add event for YouTube onStateChange
2016-05-02 07:31:29 +10:00
f02cb5635f Add event for YouTube onStateChange 2016-05-01 10:24:25 -07:00
fad3f41ca7 Prep work for theming 2016-05-01 19:27:53 +10:00
39a0a38d07 Bug fix for undefined progress bar 2016-05-01 15:04:09 +10:00
a316514ca1 Minor bug fixes 2016-05-01 13:39:53 +10:00
3b69f47590 v1.6.2 2016-05-01 12:52:07 +10:00
8172e2339d Caption change position on controls hidden 2016-05-01 12:49:04 +10:00
44bb6c077c Fixed merge 2016-05-01 12:00:37 +10:00
e11a58a841 Bug fixes 2016-05-01 11:30:51 +10:00
Sam
c4e3b5a242 Bug fixes 2016-05-01 00:35:30 +10:00
f1b44e6da0 Error handling 2016-04-30 19:52:10 +10:00
aa093b6c42 Merge branch 'pr/196' into develop
# Conflicts:
#	dist/plyr.js
2016-04-30 11:08:42 +10:00
Sam
97870a7cdc Merge branch 'master' of https://github.com/Selz/plyr 2016-04-28 23:35:26 +10:00
Sam
9a6433488f Tooltip bug fixes 2016-04-28 23:35:18 +10:00
993617f75f Remove badges (broken since GitHub caching changes) 2016-04-28 22:55:47 +10:00
Sam
e3baa43b22 Docs 2016-04-28 22:24:54 +10:00
Sam
7a332f29ea Typo 2016-04-28 22:22:32 +10:00
Sam
14c21422e7 URL fix 2016-04-28 22:21:03 +10:00
Sam
fe411b1ede Screenshot 2016-04-28 22:17:45 +10:00
Sam
4f02e2d6e7 Docs updates, small tweaks 2016-04-28 22:07:35 +10:00
4719766843 Merge branch 'develop' of github.com:selz/plyr into develop
# Conflicts:
#	dist/plyr.css
2016-04-28 18:35:21 +10:00
85600ef685 Max width on range progress indicators 2016-04-28 18:33:58 +10:00
f7edd84125 Bug fixes 2016-04-28 13:57:01 +10:00
27e3583fbc Merge branch 'develop' of github.com:selz/plyr into develop 2016-04-28 08:36:30 +10:00
12d1a03bc4 Margins 2016-04-28 08:36:23 +10:00
Sam
d3028b9a03 iconUrl option 2016-04-28 00:14:20 +10:00
2385291886 Volume fixes, iOS bug fixes 2016-04-27 22:47:03 +10:00
cb0b22574a Input progress for volume, fixes for playback progress 2016-04-27 22:22:17 +10:00
4a1adf92e2 Color 2016-04-27 08:46:36 +10:00
b077bb9f5f Docs tweaks 2016-04-27 00:34:44 +10:00
Sam
68c4b52dfa Mute volume toggle fixes 2016-04-27 00:15:29 +10:00
81ad9cf6f7 Audio styles, docs tweaks, package updates 2016-04-26 23:06:30 +10:00
Sam
024706f2ff Tab shows controls 2016-04-26 22:24:20 +10:00
Sam
57b3b9e3f6 Audio styles 2016-04-26 21:15:36 +10:00
6c8d118f83 WIP 2016-04-26 19:14:42 +10:00
48399f6364 Merge remote-tracking branch 'org/develop' into develop 2016-04-25 22:43:44 -07:00
Sam
e26694c322 Work on Audio UI 2016-04-25 22:48:40 +10:00
d41249bd90 WIP 2016-04-25 21:24:07 +10:00
Sam
833d3ac36f Tweaks 2016-04-25 20:05:01 +10:00
fdaeecbb06 Merge branch 'master' into develop 2016-04-25 19:11:00 +10:00
70297321c3 Merge branch 'develop' of github.com:selz/plyr into develop
# Conflicts:
#	.gitignore
#	dist/plyr.css
#	dist/plyr.js
#	dist/sprite.svg
#	docs/dist/docs.css
#	docs/dist/docs.js
#	docs/src/less/components/examples.less
#	src/js/plyr.js
#	src/less/plyr.less
#	src/sprite/icon-fast-forward.svg
#	src/sprite/icon-pause.svg
#	src/sprite/icon-play.svg
#	src/sprite/icon-rewind.svg
2016-04-25 19:10:10 +10:00
a02609c3e3 ignore 2016-04-25 19:07:17 +10:00
ffebc7b077 UI tweaks 2016-04-25 19:06:55 +10:00
47e0800f02 Add support for soundcloud 2016-04-17 20:57:55 -07:00
c7c7902769 Merge pull request #179 from prince-0203/update-readme-outdated-contents
Update outdated contents in readme.md
2016-04-18 10:25:23 +10:00
5bb4d70cf7 Merge branch 'master' of github.com:selz/plyr 2016-03-27 18:30:20 +11:00
67b2f2510b Bug fix for embeds: play not being defined (fixes #185 and #186) 2016-03-27 18:29:58 +11:00
ba9434b6f2 Merge pull request #184 from iamvlado/patch-1
fix type error
2016-03-20 15:26:25 +11:00
26469452e1 fix type error 2016-03-19 17:29:15 +02:00
6ae2655923 Version bump 2016-03-14 22:53:11 +11:00
815100cff8 Autoplay bug fixes 2016-03-14 22:50:34 +11:00
33771ef8c0 Merge branch 'master' of github.com:selz/plyr 2016-03-14 22:34:44 +11:00
b51a1684dc Fix for embed property not being set 2016-03-14 22:34:28 +11:00
ba9abdc1d3 Update readme.md 2016-03-13 22:45:47 +11:00
6a8803ec9f Update readme.md 2016-03-13 22:45:27 +11:00
bcb5b981f9 Update readme.md 2016-03-13 22:44:14 +11:00
5ea9e59d71 SASS fixes, docs changes (fixes #180), 'ready' event 2016-03-13 21:45:57 +11:00
01b45e7d97 Merge branch 'master' of github.com:selz/plyr 2016-03-13 21:23:00 +11:00
c41e5320c8 SASS fixes, Default font stack added 2016-03-13 21:22:51 +11:00
426c0f5559 Merge pull request #181 from shakeelmohamed/bugfix/youtube-autoplay
Dynamically set YouTube autoplay from config
2016-03-13 18:29:49 +11:00
c636f0e69e Dynamically set YouTube autoplay from config
The YouTube autoplay doesn't work without this
change.
2016-03-12 14:05:33 -08:00
58342cfae8 Update outdated contents in readme.md 2016-03-12 14:07:37 +09:00
193103cb2d Update readme.md 2016-03-07 23:18:56 +11:00
f9c593d2f9 Update readme.md 2016-03-07 23:16:46 +11:00
87d174ac2c Bug fixes and native APIs exposed for embeds 2016-03-07 22:28:30 +11:00
cd83a2670b Cancel requests on source change (Fixes #174) 2016-02-28 12:50:34 +11:00
1bbc47c64f CustomEvent polyfill (Fixes #172) 2016-02-28 11:22:11 +11:00
7a1a5830aa Remove version from source 2016-02-25 19:36:14 +11:00
1ecbec4044 Volume storage fix (Fixes #171) 2016-02-25 19:35:03 +11:00
ab329b99df Merge branch 'master' of github.com:selz/plyr 2016-02-23 15:11:48 +11:00
54af43dd75 Docs code 2016-02-23 15:11:35 +11:00
188a2e72eb Update readme.md 2016-02-21 14:34:49 +11:00
b7a14be2ac Removed npm log 2016-02-21 14:33:34 +11:00
c99f20d5d8 Fix for manual captions 2016-02-21 14:28:01 +11:00
5b968c97f4 v1.5.12 2016-02-21 14:07:17 +11:00
d538cdcdf6 1.5.12 2016-02-21 14:04:49 +11:00
cad142fe85 Merge branch 'master' of github.com:selz/plyr
# Conflicts:
#	src/js/plyr.js
2016-02-21 14:04:13 +11:00
b18ed03384 WIP on captions bug, manual duration option, reset media object 2016-02-21 13:17:30 +11:00
6a0b3dc823 Merge pull request #168 from gurupras/fix-captions
Fixes for captions
2016-02-21 11:28:15 +11:00
402c45ee2b Updated manual caption split pattern
Previously, Plyr was using a fixed pattern of '\n\n' to split
contents into captions. This does not always work as some VTT files
contain '\r\n'. This commit checks for both.
2016-02-16 20:17:10 -05:00
67f19166ac Some WebVTT fixes to allow manual captions
WebVTT allows additional parameters along with the line that
contains the start and end times. These were not being filtered
out while attempting to manually display captions.
2016-02-16 19:52:08 -05:00
32b7b6b886 Merge pull request #167 from ivanvermeyen/patch-1
Allow player control colors to be overridden #158
2016-02-15 11:50:38 +11:00
96df8fbc85 Update readme.md 2016-02-14 14:04:30 +11:00
e742527e65 Version bump 2016-02-13 22:23:11 +11:00
f426af6e9e 1.5.11 2016-02-13 22:19:48 +11:00
aea86b6124 Merge branch 'master' of github.com:selz/plyr
# Conflicts:
#	dist/plyr.js
2016-02-13 22:19:31 +11:00
ce51344269 iOS fix (Fixes #166), Edge Progress Tip (Fixes #160), SASS fix (Fixes #158) 2016-02-13 22:18:42 +11:00
7d0311fd64 Allow player control colors to be overridden #158 2016-02-12 17:11:07 +01:00
89e000f669 Update readme.md 2016-02-09 14:53:57 +11:00
f341f1264d Update readme.md 2016-02-09 14:53:20 +11:00
c687b867e7 Update readme.md 2016-02-09 14:52:37 +11:00
4ee31ba661 Update readme.md 2016-02-09 14:40:26 +11:00
a9126a4c82 Update readme.md 2016-02-05 00:02:24 +11:00
6b70c4b49a Update readme.md 2016-02-04 14:59:59 +11:00
d8fb876c81 Update readme.md 2016-02-04 14:58:00 +11:00
73e6ad610f Merge pull request #156 from mortonfox/patch-1
Fix the svgfixer.js link
2016-02-02 09:35:31 +11:00
eee7553d09 Fix the svgfixer.js link 2016-02-01 16:14:22 -05:00
130b5ebedf Update readme.md 2016-01-29 10:25:39 +11:00
dae5fb9785 Merge pull request #154 from marvinhagemeister/fix_window_usage
Get the proper reference to window on initialization.
2016-01-28 09:19:25 +11:00
31a0eb8d14 Get the proper window reference on initialization.
The previous code assumed that `this` points to the browsers
window object, which is not the case when using a module bundler.

So we check for the variable `window` first, before falling back
to `this`.

(taken from jQuery's codebase)
2016-01-27 21:27:58 +01:00
b8b611fbb6 Merge pull request #152 from marvinhagemeister/fix_commonjs
Swap CommonJS and AMD module check so that CommonJS is checked first
2016-01-27 08:45:10 +11:00
a285fcc4ec Check for module.exports as well for CommonJS Modules 2016-01-26 17:05:57 +01:00
4fda65c862 Swap CommonJS and AMD module check so that CommonJS is checked first. Fixes Webpack module bundling 2016-01-26 16:53:15 +01:00
a8cea7b5c9 1.5.10 2016-01-26 22:44:09 +11:00
01bdcc2b01 Merge pull request #151 from marvinhagemeister/fix_npm
Fix broken npm require/import
2016-01-26 20:44:44 +11:00
812d2d33f2 NPM package main must always be the main source file. Fixes broken require/import 2016-01-26 10:21:03 +01:00
a59073c5ca Update readme.md 2016-01-26 10:16:02 +11:00
7edc3ccd53 NPM updates and published (fixes #146) 2016-01-26 10:08:19 +11:00
b217e23880 Npm changes 2016-01-26 09:59:17 +11:00
053b6c2e3f Merge pull request #150 from marvinhagemeister/remove_global
Remove global preinstall script
2016-01-26 09:33:49 +11:00
0d426ca479 Remove global preinstall script. Gulp does not have to be globally installed to build plyr 2016-01-25 16:35:54 +01:00
a327056789 Seek fixes for touch 2016-01-25 11:25:32 +11:00
b006b73c69 Fix for control tooltips always showing 2016-01-25 11:02:35 +11:00
3127cea1b2 SASS fix (fixes #149) 2016-01-25 08:36:53 +11:00
a965d8a893 Seek tooltip, bug fixes for SASS, fullscreen and icons 2016-01-24 11:25:31 +11:00
173e651e3f Comment 2016-01-23 12:24:58 +11:00
fa5cb828c0 Update controls.md 2016-01-21 09:49:00 +11:00
5978810b7f Update controls.md 2016-01-21 09:48:46 +11:00
6c251794c8 Merge branch 'master' of github.com:selz/plyr 2016-01-21 09:43:40 +11:00
76917751e3 Small bug fixes 2016-01-21 09:43:27 +11:00
e75a9b89b0 Merge pull request #147 from christianpv/patch-3
Update bundles.json - Fix path to sass dir.
2016-01-21 09:06:08 +11:00
a0fe61011f Update bundles.json - Fix path to sass dir. 2016-01-20 12:40:04 -05:00
84a1b03d7d Docs update 2016-01-19 17:15:50 +11:00
b9177e7892 Minor bug fix for clicking video to play/pause after source change 2016-01-19 11:36:30 +11:00
fd12247a62 Fix for video click 2016-01-19 11:34:04 +11:00
20a71300a5 Controls 2016-01-19 09:54:23 +11:00
70c5b24678 Added reference 2016-01-19 09:35:10 +11:00
a87e87f93c Version bump 2016-01-19 09:32:04 +11:00
1b54ff0ad3 Listen for durationchange 2016-01-19 09:30:37 +11:00
3075e1eda2 Docs 2016-01-19 09:22:39 +11:00
8d1e014a40 Docs 2016-01-19 00:46:00 +11:00
0c52fe0c7c Added events line 2016-01-19 00:43:22 +11:00
bb25f8d02a Removed broken links 2016-01-19 00:41:30 +11:00
42c955c5eb Removed onSetup from docs code 2016-01-19 00:33:22 +11:00
268223ac52 Version bump 2016-01-19 00:31:28 +11:00
b81b8c1d31 Event listeners 2016-01-19 00:30:25 +11:00
5b2a016241 Merge branch 'master' of github.com:selz/plyr 2016-01-18 19:48:20 +11:00
a665121b52 Types enum 2016-01-18 19:48:14 +11:00
02d312f2d2 Style tweaks 2016-01-18 18:27:01 +11:00
c23c150fe9 Merge branch 'master' of https://github.com/Selz/plyr 2016-01-18 17:35:32 +11:00
2e5bdb338e Tidying up, Vimeo fix 2016-01-18 17:35:18 +11:00
c51ef05067 Update readme.md 2016-01-18 11:24:31 +11:00
Sam
dbe152a4c1 LESS/SASS variable name spacing and clean up 2016-01-17 19:22:43 +11:00
3f42e53d95 Don't add video hash 2016-01-17 10:48:26 +11:00
54b0dc5273 Docs tweak 2016-01-17 10:41:13 +11:00
d6b67c3388 Docs pushstate for tabs 2016-01-17 10:39:05 +11:00
Sam
a277224ef4 Reverted docs.js changes 2016-01-17 01:29:34 +11:00
Sam
f87a10ae0b Fix for event listeners being duplicated on source change 2016-01-17 01:25:11 +11:00
f18fb3f26d Update readme.md 2016-01-16 13:51:18 +11:00
71359a3ff2 Merge branch 'master' of github.com:selz/plyr
# Conflicts:
#	readme.md
2016-01-16 13:48:26 +11:00
6edc6ac680 Image 2016-01-16 13:48:11 +11:00
bf2b6c3c96 Update readme.md 2016-01-16 13:46:09 +11:00
b904e640f7 Docs update 2016-01-16 13:45:41 +11:00
1ddb4eb60c HTTPS, docs update 2016-01-16 13:20:50 +11:00
891abd1d4a Final tweaks for v1.5 and IE9 2016-01-16 13:02:04 +11:00
aed7db34ea Comments 2016-01-15 15:19:20 +11:00
90608e9e1a Vimeo iOS fix 2016-01-15 15:11:02 +11:00
70b4b14984 iOS fixes 2016-01-15 15:07:31 +11:00
9fbbb474db Clean up 2016-01-14 23:50:00 +11:00
bc7a6ebdde Keyboard nav fixes (seek & focus trap in fullscreen), SASS updates 2016-01-14 21:20:46 +11:00
353d920e25 Minor tweaks to custom handler stuff 2016-01-14 19:34:09 +11:00
6110098e97 Merge pull request #141 from gurupras/gurupras-develop
Added new configuration option 'handlers'
2016-01-14 19:21:31 +11:00
b5092c338c Added new configuration option 'handlers'
This option allows developers to attach their custom handlers
before internal plyr's handlers. This should enable developers
to have full control over all the buttons including the ability
to stop event propagation if desired.
2016-01-14 03:01:51 -05:00
cce7e9932e Merge for new source api changes 2016-01-14 09:53:58 +11:00
e6c30ec137 Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.js
#	readme.md
#	src/js/plyr.js
2016-01-14 09:42:36 +11:00
9bcd0434db Built JS 2016-01-14 09:39:10 +11:00
debdf112cc Merge pull request #140 from gurupras/gurupras-develop
Updated API function 'plyr.source()' to get media source
2016-01-14 09:35:01 +11:00
533bd173b2 Updated API function 'plyr.source()' to get media source
Currently, there is no simple way of acquiring media source.
This commit updates the 'source' API function to allow developers
to acquire the video source regardless of whether the video
is a youtube-embed or HTML5 video.

Future embeds just need their respective URL fetching code added
to this common function.
2016-01-13 17:19:19 -05:00
e05538e480 Tab focus 2016-01-14 01:19:48 +11:00
38f554b480 Tidying up 2016-01-14 01:14:22 +11:00
7d487553b2 Tab focus tweaks 2016-01-14 00:59:18 +11:00
ca8fd08e81 Use only one index.html for testing locally, fixes for limited controls, larger seek handle 2016-01-14 00:23:57 +11:00
bc67d969cb Froogaloop fixes (custom version), docs sprite, source api changes 2016-01-13 23:12:16 +11:00
c449fc0867 Controls bug fix 2016-01-12 22:31:37 +11:00
18b2d81985 Media paused state for embeds 2016-01-11 08:52:04 +11:00
533af96c4f Merge pull request #134 from gurupras/gurupras-develop
Fixed embedded Plyr not updating plyr.media.paused
2016-01-11 08:49:53 +11:00
be8b4d2735 Fixed embedded Plyr not updating plyr.media.paused 2016-01-10 12:46:56 -05:00
7d077d543b Fullscreen fixes 2016-01-11 00:07:13 +11:00
9b09c9c7a0 Work on v1.5
See changelog.md
2016-01-10 21:40:22 +11:00
Sam
592bcc8d7e Prep for v1.5 2016-01-10 15:08:58 +11:00
Sam
30529ee4e4 New vimeo vid 2015-12-13 22:57:06 +11:00
Sam
ee2cdb2c9b Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.css
#	dist/plyr.js
#	docs/dist/docs.css
#	docs/dist/docs.js
#	docs/index.html
#	docs/src/js/docs.js
#	docs/src/less/components/icons.less
#	docs/src/less/components/type.less
#	docs/src/less/docs.less
#	gulpfile.js
#	package.json
#	src/js/plyr.js
2015-12-13 22:49:02 +11:00
1371c1341f Removed Hogan from Docs (Fixes #128) 2015-12-11 10:41:29 +11:00
05bf08a438 Merge branch 'master' of github.com:selz/plyr 2015-12-11 10:01:12 +11:00
Sam
1e03aa1360 Docs update - removed button counts temporarily 2015-11-26 18:26:26 +11:00
7463e31f95 Merge pull request #123 from ciceropablo/master
Fix typo
2015-11-17 09:40:23 +11:00
83caa3f55a Fix typo 2015-11-16 20:30:29 -02:00
787465d626 Merge pull request #122 from DarthUjj/patch-1
Cleanup README a bit
2015-11-09 09:08:12 +11:00
33357a5992 Cleanup README a bit 2015-11-09 00:06:35 +05:30
cd2532867c Vimeo mute 2015-10-25 12:13:12 +11:00
8f80e4fa65 Fragaloop and docs 2015-10-25 12:02:42 +11:00
125a95e9e1 Audio fullscreen, Tooltip tweaks, Docs 2015-10-25 11:57:52 +11:00
58f8cdd8c8 Sass updated 2015-10-05 16:38:02 +11:00
b164a2f3fb Setup improvements, player -> plyr, docs (WIP) 2015-10-05 16:33:26 +11:00
262c9f9e13 Removed Hogan stuff 2015-10-05 02:01:43 +11:00
2c4c8c58d5 Docs tweaks 2015-10-05 01:39:55 +11:00
daec1baebc Source API changes, Vimeo fixes, still WIP 2015-10-04 19:27:30 +11:00
0674e13bab Icon tweaks, other small tweaks 2015-10-03 10:43:27 +10:00
aee076dc3b Added autoplay option 2015-10-03 08:49:07 +10:00
66969f1a65 Fix for multiple YouTube instances (Fixes #114) 2015-09-13 09:56:59 +10:00
e964c1a298 Docs 2015-09-06 15:34:13 +10:00
941b4c1c20 Merge 2015-08-27 07:36:59 +10:00
95e39e7bd7 Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.css
#	dist/plyr.js
#	docs/dist/docs.css
#	docs/src/less/components/examples.less
#	src/js/plyr.js
2015-08-27 07:36:17 +10:00
0785ca6024 Vimeo 2015-08-27 07:30:14 +10:00
6543fc1e5b Fixed bug with API use on basic supported browsers 2015-08-21 21:36:15 +10:00
9133247cdf Code cleanup 2015-08-13 21:34:17 +10:00
bf7f6f40bd Merge pull request #111 from calvintam236/master
Code cleanup
2015-08-13 21:32:10 +10:00
43a904917f Fixed equal signs 2015-08-13 01:39:13 -07:00
9fe6e5ffcb Converted double quote to single quote 2015-08-13 01:36:20 -07:00
a46e421bf6 Fixed syntax; Fixed some JSHint errors (Not escaped character, etc.) 2015-08-13 01:15:57 -07:00
20090aee03 Fixed missing semicolons mentioned by JSHint 2015-08-13 00:43:11 -07:00
c4ca7fe0d2 Updated tag closing 2015-08-13 00:38:30 -07:00
6b41752415 Use defined function instead of hard coding 2015-08-13 00:13:57 -07:00
2bc53d12ea Use double quote for html strings 2015-08-12 23:38:39 -07:00
2f6dc5279b Removed unnecessary "break"s 2015-08-12 23:13:58 -07:00
c8b2867b1f Removed useless spaces 2015-08-12 23:13:13 -07:00
e56132ae3b Standardized syntax 2015-08-12 22:58:33 -07:00
45d4091c20 Merge branch 'master' of github.com:selz/plyr 2015-08-11 22:38:45 +10:00
60c53a5894 Removed captions being read by screen readers 2015-08-11 22:38:06 +10:00
032c823d3a Merge pull request #108 from ChristianPV/patch-2
Update plyr.scss - Fix new scss!
2015-08-10 23:31:31 +10:00
66f724a3be Update plyr.scss - Fix new scss!
This is a fix the newly added scss.
2015-08-10 10:03:21 -03:00
bf0c81b484 Docs 2015-08-09 09:29:33 +10:00
aa72a17f44 Version bump 2015-08-08 21:02:55 +10:00
8825e82634 Merge branch 'master' of github.com:selz/plyr 2015-08-08 21:01:39 +10:00
f700d50dc8 Fix for voiceover 2015-08-08 21:01:06 +10:00
a585270d21 Update readme.md 2015-08-08 20:38:21 +10:00
7a23dda294 Typo 2015-08-08 18:13:14 +10:00
f3c324038f ARIA improvements for caption reading 2015-08-08 15:16:42 +10:00
34c9bdc84c Readme 2015-08-08 14:37:28 +10:00
38a206892b YouTube, Captions and Control improvements
- Controls improvements (Fixes #103)
- YouTube bug fixes (Fixes #105)
- Internationalization support (Fixes #101)
- Captions legibility improvements
2015-08-08 14:37:12 +10:00
12a737a49e Merge branch 'master' of github.com:selz/plyr 2015-08-08 11:14:19 +10:00
e7946189c6 Icon updates 2015-08-08 11:14:11 +10:00
850720d8f2 Merge pull request #106 from calvintam236/master
Fixed certain YouTube player issues
2015-08-08 11:13:03 +10:00
b130a13c8a Merge pull request #107 from ChristianPV/patch-1
Update plyr.scss - Make it work V3!
2015-08-07 11:50:01 +10:00
75c090e8b9 Update plyr.scss - Make it work V3! 2015-08-06 14:21:36 -03:00
f983f0771b Revert "Eliminated running try catch when player.type="youtube""
This reverts commit 5fcfd5fa4f.
2015-08-05 20:36:48 -07:00
9f1e5a55f4 Disabled YouTube embed player keyboard control to match with plyr's control 2015-08-05 20:33:04 -07:00
5fcfd5fa4f Eliminated running try catch when player.type="youtube" 2015-08-05 20:09:05 -07:00
e135309670 Fixed youtube video cannot seek before video started with controls 2015-08-05 19:57:24 -07:00
e97b616811 Fixed events are not fired in YouTube embed player 2015-08-05 19:55:30 -07:00
c504ecffe6 Merge pull request #104 from ChristianPV/patch-1
Update plyr.scss - Make it work V2!
2015-08-01 00:35:21 +10:00
9534db823d Update plyr.scss - Make it work V2!
Hi, thanks for accepting my previous pull request. I made this request because the variables control-color and control-color-hover weren't being set inside the mixin so i took them out and it's working now again. I hope you can merge this as it isnt completly working yet and sorry for the delay. Thanks again! :)
2015-07-31 10:59:03 -03:00
1ba1bec066 Merge branch 'master' of github.com:selz/plyr
# Conflicts:
#	src/sass/plyr.scss
2015-07-31 21:34:07 +10:00
aad4a720dc Tooltip fix for NVDA 2015-07-31 21:32:12 +10:00
a978348123 Version bump 2015-07-28 11:31:32 +10:00
00cf797c20 Restored !default and fullscreen logic in SASS 2015-07-28 11:29:49 +10:00
6b0f58dab2 Merge pull request #102 from ChristianPV/patch-1
Update plyr.scss - Make it work
2015-07-28 10:13:47 +10:00
04cf5dfda1 Update plyr.scss - Make it work
There were some things that needed to be changed for the sass preprocessor to work. There were some variables declared as @ that need to be declared with the right syntax: $. Also sass evaluation is eager, while less evaluation is _lazy_ that means in sass, mixins should be declared before they are use. I hope you can accept this change as it's currently not working. Thanks!
2015-07-27 13:04:02 -03:00
fe1989dea1 gulp 2015-07-25 22:06:13 +10:00
5d19b43888 Tooltip tweak 2015-07-25 21:35:12 +10:00
06ed345f29 YouTube quality tweak 2015-07-25 21:11:17 +10:00
e0cd34c996 Fix for omitted kind attribute on <track> (fixes #88) 2015-07-25 20:45:11 +10:00
06641d5709 Docs 2015-07-25 20:29:54 +10:00
a0d2d5cd24 Minor tweaks 2015-07-25 20:29:19 +10:00
e9cdbfb8da Safari fix (fixes #96), YouTube tweaks, docs 2015-07-25 19:51:32 +10:00
df64fdac9e Tab focus and caption position fixes (fixes #61, fixes #92) 2015-07-25 18:30:47 +10:00
4dbbbd04cc Merge pull request #99 from ChristianPV/patch-1
Update bower.json - fix sass file name
2015-07-25 10:59:56 +10:00
c9c3ee9014 Update bower.json - fix sass file name
I installed this package with bower and encountered an error while checking for existence of main bower files. I changed the filename to the correct one. Please take a look. Thanks!
2015-07-24 11:51:16 -03:00
67191c2a75 Merge branch 'master' of github.com:selz/plyr 2015-07-22 11:36:35 +10:00
8ba4522b3e Docs 2015-07-22 11:36:24 +10:00
52eaf62b58 Update readme.md 2015-07-21 12:30:41 +10:00
8d43f412ac Docs CSS 2015-07-21 10:48:31 +10:00
e9ea90f527 Update readme.md 2015-07-21 10:38:48 +10:00
5dc0d84300 Version bump 2015-07-21 08:51:44 +10:00
ec8923ef08 Merge branch 'master' of github.com:selz/plyr 2015-07-21 08:51:25 +10:00
5a414572f9 Tooltip fix (Fixes #97) 2015-07-21 08:51:14 +10:00
7f40307b0a Update readme.md 2015-07-20 23:11:11 +10:00
a12485d10f Update readme.md 2015-07-20 23:09:57 +10:00
4695bbf483 Merge branch 'master' of github.com:selz/plyr 2015-07-20 23:04:13 +10:00
20ee77a55e Docs tweak 2015-07-20 23:03:24 +10:00
78a0ac8674 Update readme.md 2015-07-20 22:51:33 +10:00
e49c417e54 Version bump 2015-07-20 22:32:29 +10:00
b39961ec49 Tidying 2015-07-20 22:28:27 +10:00
8894b4c7b9 Merge branch 'master' into develop
# Conflicts:
#	changelog.md
#	dist/plyr.js
2015-07-20 22:25:31 +10:00
cdf3deb458 YouTube playback, docs update 2015-07-20 22:24:06 +10:00
b5fc21239b Version bump 2015-07-20 14:45:32 +10:00
93cc9edd9a Added icon prefix option for when using default controls 2015-07-20 14:44:51 +10:00
dcd9ca3a93 Started on source swap 2015-07-12 23:57:36 +10:00
c202cc1ffb More work on YouTube 2015-07-12 23:41:56 +10:00
093af22942 More work on YouTube playback 2015-07-12 21:17:56 +10:00
9d966e41b1 Built 2015-06-27 16:21:54 +10:00
240aa7aa5f Merge branch 'master' into develop
# Conflicts:
#	dist/plyr.css
#	dist/plyr.js
2015-06-27 16:21:38 +10:00
654e9cd623 Docs tweaks 2015-06-08 22:12:08 +10:00
73c3888309 Removed log 2015-06-08 21:50:04 +10:00
4f0633fdc1 SASS for previous change 2015-06-08 21:46:47 +10:00
f41854ebe7 Minor tweak to hiding controls in fullscreen 2015-06-08 21:43:49 +10:00
f398266206 Chrome Canary Fix 2015-06-07 23:20:33 +10:00
4c17f98520 TogglePlay API method (Fixes #86), Volume border (Fixes #87), Chrome Subs (Fixes #90) 2015-06-07 23:00:26 +10:00
398815857f Merge branch 'develop' of github.com:selz/plyr into develop
# Conflicts:
#	.gitignore
2015-05-23 19:58:53 +10:00
4c5020a396 Ignore test video 2015-05-23 19:58:06 +10:00
df84ce6e90 Docs 2015-05-18 15:11:16 +10:00
7161378da1 Bug fix 2015-05-18 15:10:40 +10:00
224b612ae7 Bug fix 2015-05-18 14:46:21 +10:00
19d7522722 Fixes bug with 1.1.8 volume 2015-05-18 14:43:45 +10:00
ceace2a678 setVolume() API method improvements (Fixes #83) 2015-05-18 13:50:44 +10:00
d627454b2a Restore classname on destroy 2015-05-17 17:33:46 +10:00
7ccbfad6ad New API methods (fixes #77), Fix for non strict mode (fixes #78) 2015-05-17 17:23:09 +10:00
91f8a158d2 Update index.html 2015-04-19 23:47:46 +10:00
8925dcde01 Update readme.md 2015-04-19 23:45:25 +10:00
3d1a586314 Working on YouTube playback 2015-04-15 23:50:03 +10:00
d04b278802 Merge branch 'master' into develop
# Conflicts:
#	src/js/plyr.js
2015-04-15 21:51:59 +10:00
7345f656c1 Started on plugin setup 2015-04-15 21:47:50 +10:00
530abac3a7 Update readme.md 2015-04-15 01:15:05 +10:00
e702d9a881 Update readme.md 2015-04-15 01:14:36 +10:00
b0aeccb793 Update readme.md 2015-04-11 11:19:19 +10:00
43d8d748ce Merge pull request #76 from robinpoort/feature/sass-variables
Make SCSS variables optional
2015-04-11 09:29:04 +10:00
b43ea5c7d3 adding !default to variables so they are easily overwritable 2015-04-10 15:13:02 +02:00
f56759222d Update readme.md 2015-04-10 13:38:49 +10:00
c8b7bb570c Update readme.md 2015-04-10 13:37:55 +10:00
d536b29550 Update readme.md 2015-04-10 13:36:51 +10:00
ecbda018c5 Merge branch 'master' of github.com:selz/plyr
# Conflicts:
#	src/js/plyr.js
2015-04-10 07:17:23 +10:00
5187311ff0 Bug fix for isFullscreen() in Mozilla (Fixes #38) 2015-04-10 07:16:53 +10:00
d9a94ac7b0 Version bump 2015-04-08 13:42:34 +10:00
3526e322ef Minor bug fixes 2015-04-06 19:42:26 +10:00
99cabd545d Fix for generated IDs for controls, UI tweak for audio 2015-04-06 13:25:36 +10:00
1f7f7b10de Docs tweak 2015-04-06 12:06:34 +10:00
b2421b592a Merge branch 'master' of github.com:selz/plyr 2015-04-06 11:47:43 +10:00
5322f4c62f Fullscreen API methods (Fixes #74), onSetup callback 2015-04-06 11:47:23 +10:00
7ab8647fc8 Merge pull request #75 from franks921/fs-fix-localstorage-volume-settings
fix: use custom localStorage key for volume setting
2015-04-05 21:39:08 +10:00
50c76f3d7e fix: use custom localStorage key for volume setting 2015-04-05 13:26:17 +02:00
2f4c56176d Updated screenshot 2015-04-04 12:58:09 +11:00
7c5f38311b Bug fixes for controls changes 2015-04-04 12:51:24 +11:00
e568bc9c8d Controls improvements
- Added an option to toggle which controls display
- Better handle missing controls
2015-04-04 12:32:37 +11:00
c2c4172634 Clarified the option 2015-03-30 21:04:38 +11:00
73de5b5773 Added displayDuration option, small bug fix
- Using the native VTT cues, sometimes cues would not disappear
2015-03-30 21:03:48 +11:00
aa1fed0b16 Fixed bug with media longer than 60 minutes (Fixes #69) 2015-03-30 19:17:27 +11:00
22331ae9f1 Added mention 2015-03-22 23:24:15 +11:00
8b436276bf Fixed bug with caption toggle, hide controls in fullscreen 2015-03-22 21:26:29 +11:00
c61db87fd6 API improvements 2015-03-22 11:05:28 +11:00
388cb4df39 Keyboard accessibility improvements (Fixes #66)
- Enter now works on checkboxes within the controls
2015-03-21 17:00:05 +11:00
9feffb2972 Version bump 2015-03-15 10:18:56 +11:00
acea5cdb24 Built js 2015-03-15 10:14:00 +11:00
55ed577b6a Indentation
Converted to 4 space width tabbing
2015-03-15 10:12:36 +11:00
20b206a161 Merge pull request #62 from brunowego/patch-1
Updated SASS support
2015-03-15 10:00:00 +11:00
9c028a0ecc Updated SASS support 2015-03-14 15:50:32 -03:00
b677c3d7ad Merge branch 'master' of https://github.com/selz/plyr
Conflicts:
	dist/plyr.js
	src/js/plyr.js
2015-03-10 23:57:36 +11:00
aa6bc2df2f Fixes for volume control on iOS 2015-03-10 23:54:52 +11:00
a16579fd21 Fix for repo url 2015-03-09 11:53:26 +11:00
ae5a816df1 Fix for potential issue with .tagName 2015-03-09 11:51:01 +11:00
1532f2ab23 Added tooltip option (Fixes #50) 2015-03-09 00:47:38 +11:00
5370fc5c83 Loading state handling
Fixes #36
2015-03-08 01:24:23 +11:00
8482a1a320 Updated captions 2015-03-07 19:39:01 +11:00
f3603ac3fa Size updated 2015-03-07 19:27:11 +11:00
44fe647a49 Typo 2015-03-07 19:25:25 +11:00
928a89e599 More formatting 2015-03-07 19:24:41 +11:00
80d6d806c4 Formatting 2015-03-07 19:21:54 +11:00
aeecf40191 Slight tweaks 2015-03-07 19:17:57 +11:00
f368ed572d source(), poster() and supports() API methods 2015-03-07 19:12:56 +11:00
5291bf616e More work on source change 2015-03-07 12:24:07 +11:00
a00407a475 Removed extra log 2015-03-06 17:47:08 +11:00
4f47ec49b1 Work on source update and caption fixes 2015-03-06 17:46:06 +11:00
c48afb7880 Merge remote-tracking branch 'origin/master' into develop 2015-03-06 12:21:51 +11:00
5d3fb359b8 Note about demo code 2015-03-06 12:20:47 +11:00
0227dfa7d8 Working on source() api method 2015-03-06 01:51:12 +11:00
b9915b4b94 Removed notes 2015-03-06 01:50:37 +11:00
f4c1313c19 Updated screenshot 2015-03-05 23:36:45 +11:00
7681d63876 Removed progress transition as it feels laggy 2015-03-05 23:27:53 +11:00
3bed21bd95 Version bump 2015-03-05 22:47:49 +11:00
99cdfd60a1 Merge pull request #55 from Selz/develop
Seek improvements
2015-03-05 22:42:46 +11:00
c6e5937deb Seeking improvements 2015-03-05 22:38:25 +11:00
4404e999eb Merge branch 'develop' of github.com:selz/plyr into develop 2015-03-05 20:08:53 +11:00
3684024a58 Merge branch 'develop' of github.com:selz/plyr into develop
Conflicts:
	.gitignore
2015-03-05 20:08:26 +11:00
1903b1bcdf Seeking (still work in progress) 2015-03-05 18:36:18 +11:00
9644833d26 Ignore 2015-03-05 00:45:19 +11:00
93e3f7cdd9 WIP on better seeking 2015-03-05 00:41:42 +11:00
617ae146c1 SASS updated for icon changes 2015-03-04 21:44:41 +11:00
3459387f04 Updated icons to make them more obvious 2015-03-04 21:28:25 +11:00
4d483bf66c Bug fixes and improvements 2015-03-04 08:08:38 +11:00
9e65b67bc1 Merge pull request #41 from pborreli/typos
Fixed typos
2015-03-04 07:35:48 +11:00
722b153fcd Fixed typos 2015-03-03 14:04:27 +00:00
27a0ec9424 Open docs site on publish 2015-03-03 19:57:46 +11:00
6520a466f3 Typo fix 2015-03-03 17:26:48 +11:00
698d7289af Copy amends 2015-03-03 17:26:03 +11:00
11063a8924 Fixing the linked image 2015-03-03 17:19:10 +11:00
1071ef5bf9 Added screenshot 2015-03-03 17:16:59 +11:00
28caa00c3f Docs tweaks 2015-03-03 00:50:50 +11:00
894ac8088d Updated gulp to version assets correctly 2015-03-03 00:14:31 +11:00
148481eccc Included SSL CDN hosting 2015-03-03 00:11:01 +11:00
26bd4d0833 Fix for fullscreen issues on Firefox
Fixes #38
2015-03-02 20:16:44 +11:00
b6d5ba43ec Merge branch 'master' of github.com:selz/plyr
Conflicts:
	.gitignore
2015-03-02 19:50:56 +11:00
6cbcfd75d1 Ignore 2015-03-02 19:48:27 +11:00
ce39369d84 Fixed domain check 2015-03-02 01:32:30 +11:00
e73eb87c7e Fixed domain check 2015-03-02 01:31:31 +11:00
daf2cf4b07 Merge branch 'develop' 2015-03-02 01:09:35 +11:00
beba315ec5 Ignore aws 2015-03-02 01:09:26 +11:00
880152d0a0 Added CDN references 2015-03-02 01:08:12 +11:00
4314853640 Publishing to AWS 2015-03-01 23:23:08 +11:00
dc10139f80 v1.0.17
Fixes #4
2015-03-01 20:34:46 +11:00
05a97500aa Seperated docs, included SASS 2015-03-01 20:27:35 +11:00
eb630ab551 Merge pull request #7 from brunowego/patch-1
Add sass support
2015-03-01 19:09:43 +11:00
30d6a0cd5f Aria tidy up 2015-02-28 17:00:40 +11:00
b2ffd7d3ca Fixed icon references 2015-02-28 13:32:19 +11:00
245a5ef3d7 Fixed syntax highlighting 2015-02-28 12:48:33 +11:00
5d858344f4 Typos 2015-02-28 12:47:27 +11:00
fea7ed96b3 Controls HTML docs 2015-02-28 12:44:21 +11:00
fdc0197433 Fixed broken link 2015-02-28 12:40:21 +11:00
044bcb359e Only output GA on plyr.io domain 2015-02-28 12:29:53 +11:00
18dfc17439 Version bump 2015-02-28 12:09:01 +11:00
35ac236a00 Updates to docs, fix for seek time in controls 2015-02-28 12:07:21 +11:00
dd17100a53 Small improvements, docs updated 2015-02-28 11:18:24 +11:00
f8b4622093 Fix for Bootstrap compatibility
Fixes #6
2015-02-28 10:43:42 +11:00
1216968c60 Minor tweaks 2015-02-28 01:17:56 +11:00
1d2bd227f1 Small tweak to play(), pause() 2015-02-28 00:45:56 +11:00
6cec6b2e16 Docs for 1.0.12 2015-02-28 00:40:36 +11:00
98bc9b0c4b Handle native events
Fixes #34
2015-02-28 00:36:28 +11:00
a637949e84 Added link to Selz 2015-02-27 14:52:57 +11:00
d784669699 Updated docs/examples to use new CDN 2015-02-27 12:19:41 +11:00
ba340172ee Readme updates, code formatted using spaces 2015-02-26 14:32:18 +11:00
bb193ff152 Add sass support 2015-02-25 21:24:39 -03:00
55b085c4d0 Bug fixes for fullscreen mode 2015-02-24 15:44:56 +11:00
dd72a973d6 Docs fix 2015-02-24 12:39:22 +11:00
1b8b5d6ee4 Tidying up, bower changes
- Folder tidy up
- Bower updated to include source files
- Upgraded to svgstore 5.0.0
2015-02-24 12:37:23 +11:00
c105063ad9 Update license.md 2015-02-22 22:08:03 +11:00
ff43701e97 Readme update 2015-02-22 10:34:20 +11:00
f477fdf9e2 Minor changes 2015-02-22 10:19:47 +11:00
49038e3ca9 Progress for buffer, Safari 8 fix, validating 'html' option 2015-02-22 10:17:39 +11:00
5f96172dbd Bumping version 2015-02-19 23:18:39 +11:00
2bd6a8390c Fix for empty local storage 2015-02-19 23:16:51 +11:00
3e68cec6ea Bumping version 2015-02-19 22:38:15 +11:00
b24d763d40 Storing volume in local storage 2015-02-19 22:37:41 +11:00
d690560fc2 Fullscreen fallback for older browsers 2015-02-19 21:46:45 +11:00
d46d40fa17 Font size fix for examples, tidied up variables 2015-02-19 12:21:37 +11:00
18001e7799 Fix for control alignment 2015-02-18 17:10:41 +11:00
aa39aa8a58 Prevent multiple instances on one element 2015-02-18 16:17:27 +11:00
c7c48bbe3c Improved caption legibility on white backgrounds 2015-02-18 00:56:07 +11:00
484617e2d7 Tidy up 2015-02-18 00:18:35 +11:00
841cc957c9 Improve docs layout on small screens 2015-02-18 00:01:35 +11:00
e89e87de62 Prevent poster being downloaded twice 2015-02-17 23:40:57 +11:00
b7ea8c3875 Merge 2015-02-17 23:18:03 +11:00
a67e495910 Merge branch 'master' of github.com:selz/plyr
Conflicts:
	dist/js/plyr.js
2015-02-17 23:17:39 +11:00
97d6216409 Removed XHR for IE8 2015-02-17 23:17:15 +11:00
c55faa3505 Added OGG to <audio> example, Fixed IE11 Fullscreen 2015-02-17 22:57:00 +11:00
218 changed files with 46364 additions and 3903 deletions

10
.editorconfig Normal file
View File

@ -0,0 +1,10 @@
# See editorconfig.org
root = true
[*]
charset = utf-8
end_of_line = lf
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

40
.eslintrc.json Normal file
View File

@ -0,0 +1,40 @@
{
"parser": "babel-eslint",
"extends": ["airbnb-base", "prettier"],
"env": {
"browser": true,
"es6": true
},
"globals": { "Plyr": false, "jQuery": false },
"rules": {
"no-const-assign": 1,
"no-shadow": 0,
"no-this-before-super": 1,
"no-undef": 1,
"no-unreachable": 1,
"no-unused-vars": 1,
"constructor-super": 1,
"valid-typeof": 1,
"indent": [2, 4, { "SwitchCase": 1 }],
"quotes": [2, "single", "avoid-escape"],
"semi": [2, "always"],
"eqeqeq": [2, "always"],
"one-var": [2, "never"],
"comma-dangle": [2, "always-multiline"],
"no-restricted-globals": [
"error",
{
"name": "event",
"message": "Use local parameter instead."
},
{
"name": "error",
"message": "Use local parameter instead."
}
],
"no-param-reassign": [2, { "props": false }]
},
"parserOptions": {
"sourceType": "module"
}
}

17
.github/issue_template.md vendored Normal file
View File

@ -0,0 +1,17 @@
<!---
Please use this issue template as it makes replicating and fixing the issue easier!
--->
### Expected behaviour
### Actual behaviour
### Environment
- Browser:
- Version:
- Operating System:
- Version:
### Steps to reproduce
-

8
.github/pull_request_template.md vendored Normal file
View File

@ -0,0 +1,8 @@
### Link to related issue (if applicable)
### Summary of proposed changes
### Checklist
- [ ] Use `develop` as the base branch
- [ ] Exclude the gulp build from the PR
- [ ] Test on [supported browsers](https://github.com/sampotts/plyr#browser-support)

11
.gitignore vendored
View File

@ -1,4 +1,11 @@
node_modules
*.sublime-project
*.sublime-workspace
.DS_Store
aws.json
*.mp4
!dist/blank.mp4
index-*.html
npm-debug.log
*.webm
/package-lock.json
.idea/

View File

View File

@ -1,56 +0,0 @@
{
// Settings
"passfail" : false, // Stop on first error.
"maxerr" : 100, // Maximum error before stopping.
// Predefined globals whom JSHint will ignore.
"browser" : true, // Standard browser globals e.g. `window`, `document`.
"node" : false,
"rhino" : false,
"couch" : false,
"wsh" : true, // Windows Scripting Host.
"jquery" : true,
"predef" : [ "jQuery", "$" ],
// Development.
"debug" : false, // Allow debugger statements e.g. browser breakpoints.
"devel" : true, // Allow developments statements e.g. `console.log();`.
// ECMAScript 5.
"strict" : false, // Require `use strict` pragma in every file.
"globalstrict" : false, // Allow global "use strict" (also enables 'strict').
// The Good Parts.
"asi" : true, // Tolerate Automatic Semicolon Insertion (no semicolons).
"laxbreak" : true, // Tolerate unsafe line breaks e.g. `return [\n] x` without semicolons.
"bitwise" : false, // Prohibit bitwise operators (&, |, ^, etc.).
"boss" : false, // Tolerate assignments inside if, for & while. Usually conditions & loops are for comparison, not assignments.
"curly" : true, // Require {} for every new block or scope.
"eqeqeq" : false, // Require triple equals i.e. `===`.
"eqnull" : false, // Tolerate use of `== null`.
"evil" : false, // Tolerate use of `eval`.
"expr" : false, // Tolerate `ExpressionStatement` as Programs.
"forin" : false, // Tolerate `for in` loops without `hasOwnPrototype`.
"immed" : true, // Require immediate invocations to be wrapped in parens e.g. `( function(){}() );`
"latedef" : false, // Prohipit variable use before definition.
"loopfunc" : true, // Allow functions to be defined within loops.
"noarg" : true, // Prohibit use of `arguments.caller` and `arguments.callee`.
"regexp" : true, // Prohibit `.` and `[^...]` in regular expressions.
"regexdash" : false, // Tolerate unescaped last dash i.e. `[-...]`.
"scripturl" : true, // Tolerate script-targeted URLs.
"shadow" : false, // Allows re-define variables later in code e.g. `var x=1; x=2;`.
"supernew" : false, // Tolerate `new function () { ... };` and `new Object;`.
"undef" : true, // Require all non-global variables be declared before they are used.
// Personal styling preferences.
"newcap" : true, // Require capitalization of all constructor functions e.g. `new F()`.
"noempty" : true, // Prohibit use of empty blocks.
"nonew" : true, // Prohibit use of constructors for side-effects.
"nomen" : true, // Prohibit use of initial or trailing underbars in names.
"onevar" : false, // Allow only one `var` statement per function.
"plusplus" : false, // Prohibit use of `++` & `--`.
"sub" : false, // Tolerate all forms of subscript notation besides dot notation e.g. `dict['key']` instead of `dict.key`.
"trailing" : true, // Prohibit trailing whitespaces.
"white" : false, // Check against strict whitespace and indentation rules.
"indent" : 2 // Specify indentation spacing
}

4
.npmignore Normal file
View File

@ -0,0 +1,4 @@
demo
.github
.vscode
*.code-workspace

7
.prettierrc Normal file
View File

@ -0,0 +1,7 @@
{
"useTabs": false,
"tabWidth": 4,
"printWidth": 120,
"singleQuote": true,
"trailingComma": "all"
}

25
.stylelintrc.json Normal file
View File

@ -0,0 +1,25 @@
{
"plugins": ["stylelint-selector-bem-pattern", "stylelint-scss"],
"extends": ["stylelint-config-recommended", "stylelint-config-sass-guidelines", "stylelint-config-prettier"],
"rules": {
"selector-class-pattern": null,
"selector-no-qualifying-type": [
true,
{
"ignore": ["attribute", "class"]
}
],
"string-no-newline": null,
"indentation": 4,
"string-quotes": "single",
"max-nesting-depth": 2,
"plugin/selector-bem-pattern": {
"preset": "bem",
"componentName": "(([a-z0-9]+(?!-$)-?)+)",
"componentSelectors": {
"initial": "\\.{componentName}(((__|--)(([a-z0-9\\[\\]'=]+(?!-$)-?)+))+)?$"
},
"ignoreSelectors": [".*\\.has-.*", ".*\\.is-.*"]
}
}
}

7
.travis.yml Normal file
View File

@ -0,0 +1,7 @@
language: node_js
node_js:
- 'lts/*'
script:
- npm run lint
- npm run build

12
.vscode/extensions.json vendored Normal file
View File

@ -0,0 +1,12 @@
{
// See http://go.microsoft.com/fwlink/?LinkId=827846
// for the documentation about the extensions.json format
"recommendations": [
// Extension identifier format: ${publisher}.${name}. Example: vscode.csharp
"dbaeumer.vscode-eslint",
"wix.vscode-import-cost",
"esbenp.prettier-vscode",
"shinnn.stylelint",
"wayou.vscode-todo-highlight"
]
}

15
.vscode/launch.json vendored Normal file
View File

@ -0,0 +1,15 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "launch",
"name": "Launch Chrome against localhost",
"url": "http://localhost/dev/plyr/demo",
"webRoot": "${workspaceFolder}"
}
]
}

1
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1 @@
{}

61
CONTRIBUTING.md Normal file
View File

@ -0,0 +1,61 @@
# Contributing
We welcome bug reports, feature requests and pull requests. If you want to help us out, please follow these guidelines, in order to avoid redundant work.
## Commenting
When commenting, keep a civil tone and stay on topic. Don't ask for support (use [Stack Overflow](https://stackoverflow.com/) or [our Slack](https://bit.ly/plyr-chat) for that), or post "+1" or "I agree" type of comments. Use the emojis instead.
Asking for the status on issues is discouraged. Unless someone has explicitly said in an issue that it's work in progress, most likely that means no one is working on it. We have a lot to do, and it may not be a top priority for us.
We *may* moderate discussions. We do this to avoid threads being "hijacked", to avoid confusion in case the content is misleading or outdated, and to avoid bothering people with github notifications.
## Reporting issues
Our GitHub issue tracker is for bug reports and feature requests. Don't ask for support here. Use [Stack Overflow](https://stackoverflow.com/) or [our Slack](https://bit.ly/plyr-chat) for that.
Please verify that your issue hasn't already been answered by our [FAQ](https://github.com/sampotts/plyr/wiki/FAQ), and that there isn't already an open issue for it.
When applicable, check that your problem doesn't happen without Plyr (see [FAQ#1](https://github.com/sampotts/plyr/wiki/FAQ#1-does-plyr-work-with--)).
Verify that you are following the documentation, are using the latest version of Plyr, and aren't getting any errors in your own code, causing the issues.
Create one issue per problem or request (i.e. don't combine multiple problems to one git issue). Describe the issue as detailed as possible (see [Replication](#replication))
## Replication
In order to solve a problem, we first need to understand it. Please answer these questions when reporting issues or asking for help in [our Slack](https://bit.ly/plyr-chat).
* Does it happen only with specific options and/or specific browsers?
* Does is happen only with HTML5 video, audio, YouTube, Vimeo or a specific library?
* Does the issue happen on [our demo](https://plyr.io/)? If not, please recreate it with a **minimal** example online. You can use our Codepen templates to get started:
* [HTML5 video](https://codepen.io/pen?template=bKeqpr)
* [HTML5 audio](https://codepen.io/pen?template=rKLywR)
* [YouTube](https://codepen.io/pen?template=GGqbbJ)
* [Vimeo](https://codepen.io/pen?template=bKeXNq)
* [Dash.js integration](https://codepen.io/pen?template=zaBgBy)
* [Hls.js integration](https://codepen.io/pen?template=oyLKQb)
* [Shaka Player integration](https://codepen.io/pen?template=ZRpzZO)
It's important that you keep the issue description and replication demo **minimal**. If your replication includes frameworks, libraries or customizations, this makes it harder to debug and understand the issue. While it may be relevant to bring this up (ex: "I need Plyr to trigger the event sooner or it breaks Framework X"), please keep these out of your replication demo if they aren't strictly needed to reproduce the issue. If the issue is caused by something a library does that Plyr doesn't handle, it's more helpful for us if you find out what it is, and replicate the same problem without the library. Otherwise any developer who is willing to help out with the issue has to understand the frameworks, libraries and customizations of *your* choice, or no one will try to fix your issue because it's too much work.
## Requesting features and improvements
If you are missing something in Plyr, you can create a GitHub issue for this as well. Since we prioritize fixing bugs first, and may have a lot of other suggestions and architectural changes to work on as well, these may not be at the top of our list.
If your suggestion is important or urgent to you, you may want to first ensure it's something we want to have in Plyr, and then contribute it as a pull request. [Our Slack](https://bit.ly/plyr-chat) is the best place for questions like this.
## Contributing features and documentation
* Fork Plyr, and create a new branch in your fork, based on the **develop** branch
* To test locally, you can use the demo. First make sure you have installed the dependencies with `npm install` or `yarn`. Run `gulp` to build while you are working, and run a local server from the repository root directory. If you have Python installed, this command should work: `python -m SimpleHTTPServer 8080`. Then go to `http://localhost:8080/demo/`
* Develop and test your modifications.
* Preferably commit your changes as independent logical chunks, with meaningful messages. Make sure you do not commit unnecessary files or changes, such as the build output, or logging and breakpoints you added for testing.
* If your modifications changes the documented behavior or add new features, document these changes in readme.md.
* When finished, push the changes to your GitHub repository and send a pull request to **develop**. Describe what your PR does.
* If the Travis build fails, or if you get a code review with change requests, you can fix these by pushing new or rebased commits to the branch.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M9.016 3c2.748 0 4.984 2.243 4.984 5s-2.236 5-4.97 5l-0.060-0.004c-0.055-0.004-0.11-0.007-0.165-0.010l-0.336-0.014-3.665 1.098 0.629-2.483-0.517-0.747c-0.58-0.839-0.886-1.822-0.886-2.842 0-2.757 2.236-5 4.984-5zM9.016 1c-3.857 0-6.984 3.134-6.984 7 0 1.479 0.46 2.848 1.241 3.978l-1.272 5.022 6.722-2.015c0.098 0.004 0.194 0.015 0.293 0.015 3.857 0 6.984-3.134 6.984-7s-3.127-7-6.984-7v0z"></path>
</svg>

Before

Width:  |  Height:  |  Size: 726 B

View File

@ -1,13 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg width="18px" height="18px" viewBox="0 0 18 18" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
<title>collapse</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Page-1" stroke="none" stroke-width="1">
<g id="collapse" sketch:type="MSLayerGroup" transform="translate(-1.000000, -1.000000)">
<path d="M15.00325,9.01 L15.00325,5.377 L16.29625,6.694 C16.68825,7.082 17.32125,7.082 17.71325,6.694 C18.10525,6.306 18.10425,5.678 17.71325,5.291 L14.74625,2.291 C14.55825,2.105 14.30425,2 14.03725,2 C14.02625,2 14.01425,2 14.00325,2.001 C13.99225,2.002 13.98025,2 13.96925,2 C13.70325,2 13.44825,2.105 13.26025,2.291 L10.29325,5.291 C9.90225,5.679 9.90225,6.307 10.29325,6.694 C10.68425,7.081 11.31825,7.082 11.71025,6.694 L13.00425,5.377 L13.00425,9.01 C13.00425,9.557 13.44725,10 13.99425,10 L14.01225,10 C14.55925,10 15.00225,9.557 15.00225,9.01 L15.00325,9.01 Z" id="Shape" sketch:type="MSShapeGroup" transform="translate(14.003438, 6.000000) rotate(-135.000000) translate(-14.003438, -6.000000) "></path>
<path d="M7.00668756,13.377 L8.29968756,14.694 C8.69168756,15.082 9.32468756,15.082 9.71668756,14.694 C10.1086876,14.306 10.1076876,13.678 9.71668756,13.291 L6.74968756,10.291 C6.56168756,10.105 6.30768756,10 6.04068756,10 C6.02968756,10 6.01768756,10 6.00668756,10.001 C5.99568756,10.002 5.98368756,10 5.97268756,10 C5.70668756,10 5.45168756,10.105 5.26368756,10.291 L2.29668756,13.291 C1.90568756,13.679 1.90568756,14.307 2.29668756,14.694 C2.68768756,15.081 3.32168756,15.082 3.71368756,14.694 L5.00768756,13.377 L5.00768756,17.01 C5.00768756,17.557 5.45068756,18 5.99768756,18 C6.56268756,18 7.00568756,17.557 7.00568756,17.01 L7.00668756,13.377 Z" id="Shape-2" sketch:type="MSShapeGroup" transform="translate(6.006875, 14.000000) rotate(45.000000) translate(-6.006875, -14.000000) "></path>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.1 KiB

View File

@ -1,13 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg width="18px" height="18px" viewBox="0 0 18 18" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
<title>expand</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Page-1" stroke="none" stroke-width="1" sketch:type="MSPage">
<g id="expand" sketch:type="MSLayerGroup" transform="translate(-1.000000, -1.000000)">
<path d="M7.00325,17.01 L7.00325,13.377 L8.29625,14.694 C8.68825,15.082 9.32125,15.082 9.71325,14.694 C10.10525,14.306 10.10425,13.678 9.71325,13.291 L6.74625,10.291 C6.55825,10.105 6.30425,10 6.03725,10 C6.02625,10 6.01425,10 6.00325,10.001 C5.99225,10.002 5.98025,10 5.96925,10 C5.70325,10 5.44825,10.105 5.26025,10.291 L2.29325,13.291 C1.90225,13.679 1.90225,14.307 2.29325,14.694 C2.68425,15.081 3.31825,15.082 3.71025,14.694 L5.00425,13.377 L5.00425,17.01 C5.00425,17.557 5.44725,18 5.99425,18 L6.01225,18 C6.55925,18 7.00225,17.557 7.00225,17.01 L7.00325,17.01 Z" id="Shape" sketch:type="MSShapeGroup" transform="translate(6.003438, 14.000000) rotate(-135.000000) translate(-6.003438, -14.000000) "></path>
<path d="M15.0066876,5.377 L16.2996876,6.694 C16.6916876,7.082 17.3246876,7.082 17.7166876,6.694 C18.1086876,6.306 18.1076876,5.678 17.7166876,5.291 L14.7496876,2.291 C14.5616876,2.105 14.3076876,2 14.0406876,2 C14.0296876,2 14.0176876,2 14.0066876,2.001 C13.9956876,2.002 13.9836876,2 13.9726876,2 C13.7066876,2 13.4516876,2.105 13.2636876,2.291 L10.2966876,5.291 C9.90568756,5.679 9.90568756,6.307 10.2966876,6.694 C10.6876876,7.081 11.3216876,7.082 11.7136876,6.694 L13.0076876,5.377 L13.0076876,9.01 C13.0076876,9.557 13.4506876,10 13.9976876,10 C14.5626876,10 15.0056876,9.557 15.0056876,9.01 L15.0066876,5.377 Z" id="Shape-2" sketch:type="MSShapeGroup" transform="translate(14.006875, 6.000000) rotate(45.000000) translate(-14.006875, -6.000000) "></path>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.1 KiB

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M17.569 8.246l-10.569-6.246c-0.552 0-1 0.448-1 1v1.954l-5-2.954c-0.552 0-1 0.448-1 1v12c0 0.552 0.448 1 1 1l5-2.955v1.955c0 0.552 0.448 1 1 1l10.569-6.246c0.267-0.158 0.431-0.444 0.431-0.754s-0.164-0.597-0.431-0.754zM6 10.722l-4 2.364v-8.172l4 2.364v3.444zM8 13.086v-8.172l6.915 4.086-6.915 4.086z"></path>
</svg>

Before

Width:  |  Height:  |  Size: 635 B

View File

@ -1,14 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg width="18px" height="18px" viewBox="0 0 18 18" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
<title>muted</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Page-1" stroke="none" stroke-width="1" sketch:type="MSPage">
<g id="sound" sketch:type="MSLayerGroup" transform="translate(0.000000, 2.000000)">
<path d="M9.214,0 C9.103,0 8.989,0.032 8.88,0.101 L4.832,2.911 C4.749,2.969 4.65,3 4.549,3 L0.996,3 C0.446,3 1.33226763e-15,3.448 1.33226763e-15,4 L1.33226763e-15,10 C1.33226763e-15,10.552 0.446,11 0.996,11 L4.549,11 C4.651,11 4.749,11.031 4.832,11.089 L8.88,13.899 C8.989,13.968 9.103,14 9.214,14 C9.606,14 9.961,13.6 9.961,13.051 L9.961,0.95 C9.961,0.4 9.606,0.001 9.214,0.001 L9.214,0 Z M7.969,10.834 L5.582,9.177 C5.416,9.062 5.218,8.999 5.016,8.999 L2.491,8.999 C2.216,8.999 1.993,8.775 1.993,8.499 L1.993,5.499 C1.993,5.223 2.216,4.999 2.491,4.999 L5.016,4.999 C5.218,4.999 5.416,4.937 5.582,4.821 L7.969,3.164 L7.969,10.833 L7.969,10.834 Z" id="Shape" sketch:type="MSShapeGroup"></path>
<path d="M14.934,6.799 C14.848,5.051 13.42,3.808 12.427,3.15 C11.957,2.838 11.333,3.028 11.102,3.558 L11.064,3.644 C10.876,4.075 11.019,4.583 11.4,4.838 C12.106,5.311 12.986,6.085 13.024,6.903 C13.056,7.579 12.471,8.371 11.361,9.173 C10.963,9.461 10.832,10.012 11.076,10.448 L11.118,10.523 C11.384,10.998 11.984,11.147 12.418,10.835 C14.158,9.584 15.004,8.229 14.934,6.798 L14.934,6.799 Z" id="Shape" sketch:type="MSShapeGroup"></path>
<path d="M17.934,6.799 C17.848,5.051 16.42,3.808 15.427,3.15 C14.957,2.838 14.333,3.028 14.102,3.558 L14.064,3.644 C13.876,4.075 14.019,4.583 14.4,4.838 C15.106,5.311 15.986,6.085 16.024,6.903 C16.056,7.579 15.471,8.371 14.361,9.173 C13.963,9.461 13.832,10.012 14.076,10.448 L14.118,10.523 C14.384,10.998 14.984,11.147 15.418,10.835 C17.158,9.584 18.004,8.229 17.934,6.798 L17.934,6.799 Z" id="Shape-2" sketch:type="MSShapeGroup" transform="translate(15.945467, 6.999165) rotate(-180.000000) translate(-15.945467, -6.999165) "></path>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.3 KiB

View File

@ -1,13 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg width="18px" height="18px" viewBox="0 0 18 18" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
<title>pause</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Page-1" stroke="none" stroke-width="1" sketch:type="MSPage">
<g id="pause" sketch:type="MSLayerGroup" transform="translate(2.000000, 2.000000)">
<path d="M0,2 L0,12 C5.24848613e-17,14 2,14 2,14 L4,14 C4,14 6,14 6,12 C6,11.786438 6,11.572876 6,11 L6,2 C6,3.17446247e-09 4,0 4,0 L2,0 C2,0 0,0 0,2 Z M2,2 L4,2 L4,12 L2,12 L2,2 Z" id="Path-1" sketch:type="MSShapeGroup"></path>
<path d="M8,2 L8,12 C8,14 10,14 10,14 L12,14 C12,14 14,14 14,12 C14,11.786438 14,11.572876 14,11 L14,2 C14,3.17446247e-09 12,0 12,0 L10,0 C10,0 8,0 8,2 Z M10,2 L12,2 L12,12 L10,12 L10,2 Z" id="Path-2" sketch:type="MSShapeGroup"></path>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1.1 KiB

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M5 4.914l6.915 4.086-6.915 4.086v-8.172zM4 2c-0.552 0-1 0.448-1 1v12c0 0.552 0.448 1 1 1l10.569-6.246c0.267-0.158 0.431-0.444 0.431-0.754s-0.164-0.597-0.431-0.754l-10.569-6.246z"></path>
</svg>

Before

Width:  |  Height:  |  Size: 515 B

View File

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M8.013 14.006h-0.822c-2.372-0.388-4.187-2.453-4.187-4.934 0-0.831 0.213-1.609 0.574-2.299l0.613 0.85c0.446 0.618 1.409 0.446 1.614-0.289l1.162-4.179c0.162-0.58-0.275-1.155-0.877-1.154l-4.174 0.006c-0.741 0.001-1.17 0.841-0.736 1.443l1.128 1.564c-0.817 1.145-1.302 2.544-1.302 4.059 0 3.499 2.566 6.399 5.918 6.917 0.091 0.014 0.18 0.010 0.267-0.001v0.012h0.822c0.545 0 0.987-0.442 0.987-0.987v-0.020c0-0.545-0.442-0.987-0.987-0.987z"></path>
<path d="M16.82 14.551l-1.129-1.564c0.818-1.145 1.302-2.544 1.302-4.059 0-3.499-2.566-6.399-5.918-6.918-0.091-0.014-0.18-0.010-0.267 0.001v-0.013h-0.822c-0.545 0-0.986 0.442-0.986 0.987v0.020c0 0.546 0.442 0.988 0.986 0.988h0.822c2.372 0.388 4.187 2.453 4.187 4.934 0 0.831-0.213 1.609-0.573 2.299l-0.614-0.85c-0.446-0.618-1.409-0.446-1.613 0.289l-1.163 4.179c-0.161 0.581 0.275 1.155 0.878 1.154l4.174-0.006c0.742-0.001 1.17-0.842 0.736-1.443z"></path>
</svg>

Before

Width:  |  Height:  |  Size: 1.2 KiB

View File

@ -1,10 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg width="18px" height="21px" viewBox="0 0 18 21" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
<title>rewind</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<g id="Page-1" stroke="none" stroke-width="1" sketch:type="MSPage">
<path d="M17.569,9.246 L7,3 C6.448,3 6,3.448 6,4 L6,5.954 L1,3 C0.448,3 0,3.448 0,4 L0,16 C0,16.552 0.448,17 1,17 L6,14.045 L6,16 C6,16.552 6.448,17 7,17 L17.569,10.754 C17.836,10.596 18,10.31 18,10 C18,9.69 17.836,9.403 17.569,9.246 L17.569,9.246 Z M6,11.722 L2,14.086 L2,5.914 L6,8.278 L6,11.722 L6,11.722 Z M8,14.086 L8,5.914 L14.915,10 L8,14.086 L8,14.086 Z" id="Shape" sketch:type="MSShapeGroup" transform="translate(9.000000, 10.000000) rotate(-180.000000) translate(-9.000000, -10.000000) "></path>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1021 B

View File

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M10.214 2c-0.111 0-0.225 0.032-0.334 0.101l-4.048 2.81c-0.083 0.058-0.182 0.089-0.283 0.089h-3.553c-0.55 0-0.996 0.448-0.996 1v6c0 0.552 0.446 1 0.996 1h3.553c0.102 0 0.2 0.031 0.283 0.089l4.048 2.81c0.109 0.069 0.223 0.101 0.334 0.101 0.392 0 0.747-0.4 0.747-0.949v-12.101c0-0.55-0.355-0.949-0.747-0.949zM8.969 12.834l-2.387-1.657c-0.166-0.115-0.364-0.178-0.566-0.178h-2.525c-0.275 0-0.498-0.224-0.498-0.5v-3c0-0.276 0.223-0.5 0.498-0.5h2.525c0.202 0 0.4-0.062 0.566-0.178l2.387-1.657v7.669z"></path>
<path d="M16.934 8.799c-0.086-1.748-1.514-2.991-2.507-3.649-0.47-0.312-1.094-0.122-1.325 0.408l-0.038 0.086c-0.188 0.431-0.045 0.939 0.336 1.194 0.706 0.473 1.586 1.247 1.624 2.065 0.032 0.676-0.553 1.468-1.663 2.27-0.398 0.288-0.529 0.839-0.285 1.275l0.042 0.075c0.266 0.475 0.866 0.624 1.3 0.312 1.74-1.251 2.586-2.606 2.516-4.037z"></path>
</svg>

Before

Width:  |  Height:  |  Size: 1.1 KiB

View File

@ -1,15 +0,0 @@
// ==========================================================================
// Docs example
// ==========================================================================
/*global plyr, templates */
// Setup the player
plyr.setup({
debug: true,
title: "Video demo",
html: templates.controls.render({}),
captions: {
defaultActive: true
}
});

View File

@ -1,802 +0,0 @@
/*!
* Copyright 2011 Twitter, Inc.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// A wrapper for compatibility with Mustache.js, quirks and all
var Hogan = {};
(function (Hogan) {
Hogan.Template = function (codeObj, text, compiler, options) {
codeObj = codeObj || {};
this.r = codeObj.code || this.r;
this.c = compiler;
this.options = options || {};
this.text = text || '';
this.partials = codeObj.partials || {};
this.subs = codeObj.subs || {};
this.buf = '';
}
Hogan.Template.prototype = {
// render: replaced by generated code.
r: function (context, partials, indent) { return ''; },
// variable escaping
v: hoganEscape,
// triple stache
t: coerceToString,
render: function render(context, partials, indent) {
return this.ri([context], partials || {}, indent);
},
// render internal -- a hook for overrides that catches partials too
ri: function (context, partials, indent) {
return this.r(context, partials, indent);
},
// ensurePartial
ep: function(symbol, partials) {
var partial = this.partials[symbol];
// check to see that if we've instantiated this partial before
var template = partials[partial.name];
if (partial.instance && partial.base == template) {
return partial.instance;
}
if (typeof template == 'string') {
if (!this.c) {
throw new Error("No compiler available.");
}
template = this.c.compile(template, this.options);
}
if (!template) {
return null;
}
// We use this to check whether the partials dictionary has changed
this.partials[symbol].base = template;
if (partial.subs) {
// Make sure we consider parent template now
if (!partials.stackText) partials.stackText = {};
for (key in partial.subs) {
if (!partials.stackText[key]) {
partials.stackText[key] = (this.activeSub !== undefined && partials.stackText[this.activeSub]) ? partials.stackText[this.activeSub] : this.text;
}
}
template = createSpecializedPartial(template, partial.subs, partial.partials,
this.stackSubs, this.stackPartials, partials.stackText);
}
this.partials[symbol].instance = template;
return template;
},
// tries to find a partial in the current scope and render it
rp: function(symbol, context, partials, indent) {
var partial = this.ep(symbol, partials);
if (!partial) {
return '';
}
return partial.ri(context, partials, indent);
},
// render a section
rs: function(context, partials, section) {
var tail = context[context.length - 1];
if (!isArray(tail)) {
section(context, partials, this);
return;
}
for (var i = 0; i < tail.length; i++) {
context.push(tail[i]);
section(context, partials, this);
context.pop();
}
},
// maybe start a section
s: function(val, ctx, partials, inverted, start, end, tags) {
var pass;
if (isArray(val) && val.length === 0) {
return false;
}
if (typeof val == 'function') {
val = this.ms(val, ctx, partials, inverted, start, end, tags);
}
pass = !!val;
if (!inverted && pass && ctx) {
ctx.push((typeof val == 'object') ? val : ctx[ctx.length - 1]);
}
return pass;
},
// find values with dotted names
d: function(key, ctx, partials, returnFound) {
var found,
names = key.split('.'),
val = this.f(names[0], ctx, partials, returnFound),
doModelGet = this.options.modelGet,
cx = null;
if (key === '.' && isArray(ctx[ctx.length - 2])) {
val = ctx[ctx.length - 1];
} else {
for (var i = 1; i < names.length; i++) {
found = findInScope(names[i], val, doModelGet);
if (found !== undefined) {
cx = val;
val = found;
} else {
val = '';
}
}
}
if (returnFound && !val) {
return false;
}
if (!returnFound && typeof val == 'function') {
ctx.push(cx);
val = this.mv(val, ctx, partials);
ctx.pop();
}
return val;
},
// find values with normal names
f: function(key, ctx, partials, returnFound) {
var val = false,
v = null,
found = false,
doModelGet = this.options.modelGet;
for (var i = ctx.length - 1; i >= 0; i--) {
v = ctx[i];
val = findInScope(key, v, doModelGet);
if (val !== undefined) {
found = true;
break;
}
}
if (!found) {
return (returnFound) ? false : "";
}
if (!returnFound && typeof val == 'function') {
val = this.mv(val, ctx, partials);
}
return val;
},
// higher order templates
ls: function(func, cx, partials, text, tags) {
var oldTags = this.options.delimiters;
this.options.delimiters = tags;
this.b(this.ct(coerceToString(func.call(cx, text)), cx, partials));
this.options.delimiters = oldTags;
return false;
},
// compile text
ct: function(text, cx, partials) {
if (this.options.disableLambda) {
throw new Error('Lambda features disabled.');
}
return this.c.compile(text, this.options).render(cx, partials);
},
// template result buffering
b: function(s) { this.buf += s; },
fl: function() { var r = this.buf; this.buf = ''; return r; },
// method replace section
ms: function(func, ctx, partials, inverted, start, end, tags) {
var textSource,
cx = ctx[ctx.length - 1],
result = func.call(cx);
if (typeof result == 'function') {
if (inverted) {
return true;
} else {
textSource = (this.activeSub && this.subsText && this.subsText[this.activeSub]) ? this.subsText[this.activeSub] : this.text;
return this.ls(result, cx, partials, textSource.substring(start, end), tags);
}
}
return result;
},
// method replace variable
mv: function(func, ctx, partials) {
var cx = ctx[ctx.length - 1];
var result = func.call(cx);
if (typeof result == 'function') {
return this.ct(coerceToString(result.call(cx)), cx, partials);
}
return result;
},
sub: function(name, context, partials, indent) {
var f = this.subs[name];
if (f) {
this.activeSub = name;
f(context, partials, this, indent);
this.activeSub = false;
}
}
};
//Find a key in an object
function findInScope(key, scope, doModelGet) {
var val;
if (scope && typeof scope == 'object') {
if (scope[key] !== undefined) {
val = scope[key];
// try lookup with get for backbone or similar model data
} else if (doModelGet && scope.get && typeof scope.get == 'function') {
val = scope.get(key);
}
}
return val;
}
function createSpecializedPartial(instance, subs, partials, stackSubs, stackPartials, stackText) {
function PartialTemplate() {};
PartialTemplate.prototype = instance;
function Substitutions() {};
Substitutions.prototype = instance.subs;
var key;
var partial = new PartialTemplate();
partial.subs = new Substitutions();
partial.subsText = {}; //hehe. substext.
partial.buf = '';
stackSubs = stackSubs || {};
partial.stackSubs = stackSubs;
partial.subsText = stackText;
for (key in subs) {
if (!stackSubs[key]) stackSubs[key] = subs[key];
}
for (key in stackSubs) {
partial.subs[key] = stackSubs[key];
}
stackPartials = stackPartials || {};
partial.stackPartials = stackPartials;
for (key in partials) {
if (!stackPartials[key]) stackPartials[key] = partials[key];
}
for (key in stackPartials) {
partial.partials[key] = stackPartials[key];
}
return partial;
}
var rAmp = /&/g,
rLt = /</g,
rGt = />/g,
rApos = /\'/g,
rQuot = /\"/g,
hChars = /[&<>\"\']/;
function coerceToString(val) {
return String((val === null || val === undefined) ? '' : val);
}
function hoganEscape(str) {
str = coerceToString(str);
return hChars.test(str) ?
str
.replace(rAmp, '&amp;')
.replace(rLt, '&lt;')
.replace(rGt, '&gt;')
.replace(rApos, '&#39;')
.replace(rQuot, '&quot;') :
str;
}
var isArray = Array.isArray || function(a) {
return Object.prototype.toString.call(a) === '[object Array]';
};
})(typeof exports !== 'undefined' ? exports : Hogan);
(function (Hogan) {
// Setup regex assignments
// remove whitespace according to Mustache spec
var rIsWhitespace = /\S/,
rQuot = /\"/g,
rNewline = /\n/g,
rCr = /\r/g,
rSlash = /\\/g,
rLineSep = /\u2028/,
rParagraphSep = /\u2029/;
Hogan.tags = {
'#': 1, '^': 2, '<': 3, '$': 4,
'/': 5, '!': 6, '>': 7, '=': 8, '_v': 9,
'{': 10, '&': 11, '_t': 12
};
Hogan.scan = function scan(text, delimiters) {
var len = text.length,
IN_TEXT = 0,
IN_TAG_TYPE = 1,
IN_TAG = 2,
state = IN_TEXT,
tagType = null,
tag = null,
buf = '',
tokens = [],
seenTag = false,
i = 0,
lineStart = 0,
otag = '{{',
ctag = '}}';
function addBuf() {
if (buf.length > 0) {
tokens.push({tag: '_t', text: new String(buf)});
buf = '';
}
}
function lineIsWhitespace() {
var isAllWhitespace = true;
for (var j = lineStart; j < tokens.length; j++) {
isAllWhitespace =
(Hogan.tags[tokens[j].tag] < Hogan.tags['_v']) ||
(tokens[j].tag == '_t' && tokens[j].text.match(rIsWhitespace) === null);
if (!isAllWhitespace) {
return false;
}
}
return isAllWhitespace;
}
function filterLine(haveSeenTag, noNewLine) {
addBuf();
if (haveSeenTag && lineIsWhitespace()) {
for (var j = lineStart, next; j < tokens.length; j++) {
if (tokens[j].text) {
if ((next = tokens[j+1]) && next.tag == '>') {
// set indent to token value
next.indent = tokens[j].text.toString()
}
tokens.splice(j, 1);
}
}
} else if (!noNewLine) {
tokens.push({tag:'\n'});
}
seenTag = false;
lineStart = tokens.length;
}
function changeDelimiters(text, index) {
var close = '=' + ctag,
closeIndex = text.indexOf(close, index),
delimiters = trim(
text.substring(text.indexOf('=', index) + 1, closeIndex)
).split(' ');
otag = delimiters[0];
ctag = delimiters[delimiters.length - 1];
return closeIndex + close.length - 1;
}
if (delimiters) {
delimiters = delimiters.split(' ');
otag = delimiters[0];
ctag = delimiters[1];
}
for (i = 0; i < len; i++) {
if (state == IN_TEXT) {
if (tagChange(otag, text, i)) {
--i;
addBuf();
state = IN_TAG_TYPE;
} else {
if (text.charAt(i) == '\n') {
filterLine(seenTag);
} else {
buf += text.charAt(i);
}
}
} else if (state == IN_TAG_TYPE) {
i += otag.length - 1;
tag = Hogan.tags[text.charAt(i + 1)];
tagType = tag ? text.charAt(i + 1) : '_v';
if (tagType == '=') {
i = changeDelimiters(text, i);
state = IN_TEXT;
} else {
if (tag) {
i++;
}
state = IN_TAG;
}
seenTag = i;
} else {
if (tagChange(ctag, text, i)) {
tokens.push({tag: tagType, n: trim(buf), otag: otag, ctag: ctag,
i: (tagType == '/') ? seenTag - otag.length : i + ctag.length});
buf = '';
i += ctag.length - 1;
state = IN_TEXT;
if (tagType == '{') {
if (ctag == '}}') {
i++;
} else {
cleanTripleStache(tokens[tokens.length - 1]);
}
}
} else {
buf += text.charAt(i);
}
}
}
filterLine(seenTag, true);
return tokens;
}
function cleanTripleStache(token) {
if (token.n.substr(token.n.length - 1) === '}') {
token.n = token.n.substring(0, token.n.length - 1);
}
}
function trim(s) {
if (s.trim) {
return s.trim();
}
return s.replace(/^\s*|\s*$/g, '');
}
function tagChange(tag, text, index) {
if (text.charAt(index) != tag.charAt(0)) {
return false;
}
for (var i = 1, l = tag.length; i < l; i++) {
if (text.charAt(index + i) != tag.charAt(i)) {
return false;
}
}
return true;
}
// the tags allowed inside super templates
var allowedInSuper = {'_t': true, '\n': true, '$': true, '/': true};
function buildTree(tokens, kind, stack, customTags) {
var instructions = [],
opener = null,
tail = null,
token = null;
tail = stack[stack.length - 1];
while (tokens.length > 0) {
token = tokens.shift();
if (tail && tail.tag == '<' && !(token.tag in allowedInSuper)) {
throw new Error('Illegal content in < super tag.');
}
if (Hogan.tags[token.tag] <= Hogan.tags['$'] || isOpener(token, customTags)) {
stack.push(token);
token.nodes = buildTree(tokens, token.tag, stack, customTags);
} else if (token.tag == '/') {
if (stack.length === 0) {
throw new Error('Closing tag without opener: /' + token.n);
}
opener = stack.pop();
if (token.n != opener.n && !isCloser(token.n, opener.n, customTags)) {
throw new Error('Nesting error: ' + opener.n + ' vs. ' + token.n);
}
opener.end = token.i;
return instructions;
} else if (token.tag == '\n') {
token.last = (tokens.length == 0) || (tokens[0].tag == '\n');
}
instructions.push(token);
}
if (stack.length > 0) {
throw new Error('missing closing tag: ' + stack.pop().n);
}
return instructions;
}
function isOpener(token, tags) {
for (var i = 0, l = tags.length; i < l; i++) {
if (tags[i].o == token.n) {
token.tag = '#';
return true;
}
}
}
function isCloser(close, open, tags) {
for (var i = 0, l = tags.length; i < l; i++) {
if (tags[i].c == close && tags[i].o == open) {
return true;
}
}
}
function stringifySubstitutions(obj) {
var items = [];
for (var key in obj) {
items.push('"' + esc(key) + '": function(c,p,t,i) {' + obj[key] + '}');
}
return "{ " + items.join(",") + " }";
}
function stringifyPartials(codeObj) {
var partials = [];
for (var key in codeObj.partials) {
partials.push('"' + esc(key) + '":{name:"' + esc(codeObj.partials[key].name) + '", ' + stringifyPartials(codeObj.partials[key]) + "}");
}
return "partials: {" + partials.join(",") + "}, subs: " + stringifySubstitutions(codeObj.subs);
}
Hogan.stringify = function(codeObj, text, options) {
return "{code: function (c,p,i) { " + Hogan.wrapMain(codeObj.code) + " }," + stringifyPartials(codeObj) + "}";
}
var serialNo = 0;
Hogan.generate = function(tree, text, options) {
serialNo = 0;
var context = { code: '', subs: {}, partials: {} };
Hogan.walk(tree, context);
if (options.asString) {
return this.stringify(context, text, options);
}
return this.makeTemplate(context, text, options);
}
Hogan.wrapMain = function(code) {
return 'var t=this;t.b(i=i||"");' + code + 'return t.fl();';
}
Hogan.template = Hogan.Template;
Hogan.makeTemplate = function(codeObj, text, options) {
var template = this.makePartials(codeObj);
template.code = new Function('c', 'p', 'i', this.wrapMain(codeObj.code));
return new this.template(template, text, this, options);
}
Hogan.makePartials = function(codeObj) {
var key, template = {subs: {}, partials: codeObj.partials, name: codeObj.name};
for (key in template.partials) {
template.partials[key] = this.makePartials(template.partials[key]);
}
for (key in codeObj.subs) {
template.subs[key] = new Function('c', 'p', 't', 'i', codeObj.subs[key]);
}
return template;
}
function esc(s) {
return s.replace(rSlash, '\\\\')
.replace(rQuot, '\\\"')
.replace(rNewline, '\\n')
.replace(rCr, '\\r')
.replace(rLineSep, '\\u2028')
.replace(rParagraphSep, '\\u2029');
}
function chooseMethod(s) {
return (~s.indexOf('.')) ? 'd' : 'f';
}
function createPartial(node, context) {
var prefix = "<" + (context.prefix || "");
var sym = prefix + node.n + serialNo++;
context.partials[sym] = {name: node.n, partials: {}};
context.code += 't.b(t.rp("' + esc(sym) + '",c,p,"' + (node.indent || '') + '"));';
return sym;
}
Hogan.codegen = {
'#': function(node, context) {
context.code += 'if(t.s(t.' + chooseMethod(node.n) + '("' + esc(node.n) + '",c,p,1),' +
'c,p,0,' + node.i + ',' + node.end + ',"' + node.otag + " " + node.ctag + '")){' +
't.rs(c,p,' + 'function(c,p,t){';
Hogan.walk(node.nodes, context);
context.code += '});c.pop();}';
},
'^': function(node, context) {
context.code += 'if(!t.s(t.' + chooseMethod(node.n) + '("' + esc(node.n) + '",c,p,1),c,p,1,0,0,"")){';
Hogan.walk(node.nodes, context);
context.code += '};';
},
'>': createPartial,
'<': function(node, context) {
var ctx = {partials: {}, code: '', subs: {}, inPartial: true};
Hogan.walk(node.nodes, ctx);
var template = context.partials[createPartial(node, context)];
template.subs = ctx.subs;
template.partials = ctx.partials;
},
'$': function(node, context) {
var ctx = {subs: {}, code: '', partials: context.partials, prefix: node.n};
Hogan.walk(node.nodes, ctx);
context.subs[node.n] = ctx.code;
if (!context.inPartial) {
context.code += 't.sub("' + esc(node.n) + '",c,p,i);';
}
},
'\n': function(node, context) {
context.code += write('"\\n"' + (node.last ? '' : ' + i'));
},
'_v': function(node, context) {
context.code += 't.b(t.v(t.' + chooseMethod(node.n) + '("' + esc(node.n) + '",c,p,0)));';
},
'_t': function(node, context) {
context.code += write('"' + esc(node.text) + '"');
},
'{': tripleStache,
'&': tripleStache
}
function tripleStache(node, context) {
context.code += 't.b(t.t(t.' + chooseMethod(node.n) + '("' + esc(node.n) + '",c,p,0)));';
}
function write(s) {
return 't.b(' + s + ');';
}
Hogan.walk = function(nodelist, context) {
var func;
for (var i = 0, l = nodelist.length; i < l; i++) {
func = Hogan.codegen[nodelist[i].tag];
func && func(nodelist[i], context);
}
return context;
}
Hogan.parse = function(tokens, text, options) {
options = options || {};
return buildTree(tokens, '', [], options.sectionTags || []);
}
Hogan.cache = {};
Hogan.cacheKey = function(text, options) {
return [text, !!options.asString, !!options.disableLambda, options.delimiters, !!options.modelGet].join('||');
}
Hogan.compile = function(text, options) {
options = options || {};
var key = Hogan.cacheKey(text, options);
var template = this.cache[key];
if (template) {
var partials = template.partials;
for (var name in partials) {
delete partials[name].instance;
}
return template;
}
template = this.generate(this.parse(this.scan(text, options.delimiters), text, options), text, options);
return this.cache[key] = template;
}
})(typeof exports !== 'undefined' ? exports : Hogan);
var Mustache = (function (Hogan) {
// Mustache.js has non-spec partial context behavior
function mustachePartial(name, context, partials, indent) {
var partialScope = this.f(name, context, partials, 0);
var cx = context;
if (partialScope) {
cx = cx.concat(partialScope);
}
return Hogan.Template.prototype.rp.call(this, name, cx, partials, indent);
}
var HoganTemplateWrapper = function(renderFunc, text, compiler){
this.rp = mustachePartial;
Hogan.Template.call(this, renderFunc, text, compiler);
};
HoganTemplateWrapper.prototype = Hogan.Template.prototype;
// Add a wrapper for Hogan's generate method. Mustache and Hogan keep
// separate caches, and Mustache returns wrapped templates.
var wrapper;
var HoganWrapper = function(){
this.cache = {};
this.generate = function(code, text, options) {
return new HoganTemplateWrapper(new Function('c', 'p', 'i', code), text, wrapper);
}
};
HoganWrapper.prototype = Hogan;
wrapper = new HoganWrapper();
return {
to_html: function(text, data, partials, sendFun) {
var template = wrapper.compile(text);
var result = template.render(data, partials);
if (!sendFun) {
return result;
}
sendFun(result);
}
}
})(Hogan);

View File

@ -1,979 +0,0 @@
// ==========================================================================
// Plyr
// plyr.js v1.0.0
// https://github.com/sampotts/plyr
// ==========================================================================
// Credits: http://paypal.github.io/accessible-html5-video-player/
// ==========================================================================
/*global ActiveXObject*/
(function (api) {
"use strict";
// Globals
var fullscreen, config;
// Default config
var defaults = {
enabled: true,
debug: false,
seekInterval: 10,
volume: 5,
click: true,
selectors: {
container: ".player",
controls: ".player-controls",
buttons: {
play: "[data-player='play']",
pause: "[data-player='pause']",
restart: "[data-player='restart']",
rewind: "[data-player='rewind']",
forward: "[data-player='fast-forward']",
mute: "[data-player='mute']",
volume: "[data-player='volume']",
captions: "[data-player='captions']",
fullscreen: "[data-player='fullscreen']"
},
progress: ".player-progress",
captions: ".player-captions",
duration: ".player-duration",
seekTime: ".player-seek-time"
},
classes: {
video: "player-video",
videoWrapper: "player-video-wrapper",
audio: "player-audio",
stopped: "stopped",
playing: "playing",
muted: "muted",
captions: {
active: "captions-active",
enabled: "captions-enabled"
},
fullscreen: {
enabled: "fullscreen-enabled"
}
},
captions: {
defaultActive: false
},
fullscreen: {
enabled: true
}
};
// Credits: http://paypal.github.io/accessible-html5-video-player/
// Unfortunately, due to scattered support, browser sniffing is required
function _browserSniff() {
var nAgt = navigator.userAgent,
browserName = navigator.appName,
fullVersion = ""+parseFloat(navigator.appVersion),
majorVersion = parseInt(navigator.appVersion,10),
nameOffset,
verOffset,
ix;
// MSIE 11
if ((navigator.appVersion.indexOf("Windows NT") !== -1) && (navigator.appVersion.indexOf("rv:11") !== -1)) {
browserName = "IE";
fullVersion = "11;";
}
// MSIE
else if ((verOffset=nAgt.indexOf("MSIE")) !== -1) {
browserName = "IE";
fullVersion = nAgt.substring(verOffset+5);
}
// Chrome
else if ((verOffset=nAgt.indexOf("Chrome")) !== -1) {
browserName = "Chrome";
fullVersion = nAgt.substring(verOffset+7);
}
// Safari
else if ((verOffset=nAgt.indexOf("Safari")) !== -1) {
browserName = "Safari";
fullVersion = nAgt.substring(verOffset+7);
if ((verOffset=nAgt.indexOf("Version")) !== -1) {
fullVersion = nAgt.substring(verOffset+8);
}
}
// Firefox
else if ((verOffset=nAgt.indexOf("Firefox")) !== -1) {
browserName = "Firefox";
fullVersion = nAgt.substring(verOffset+8);
}
// In most other browsers, "name/version" is at the end of userAgent
else if ( (nameOffset=nAgt.lastIndexOf(" ")+1) < (verOffset=nAgt.lastIndexOf("/")) ) {
browserName = nAgt.substring(nameOffset,verOffset);
fullVersion = nAgt.substring(verOffset+1);
if (browserName.toLowerCase()==browserName.toUpperCase()) {
browserName = navigator.appName;
}
}
// Trim the fullVersion string at semicolon/space if present
if ((ix=fullVersion.indexOf(";")) !== -1) {
fullVersion=fullVersion.substring(0,ix);
}
if ((ix=fullVersion.indexOf(" ")) !== -1) {
fullVersion=fullVersion.substring(0,ix);
}
// Get major version
majorVersion = parseInt(""+fullVersion,10);
if (isNaN(majorVersion)) {
fullVersion = ""+parseFloat(navigator.appVersion);
majorVersion = parseInt(navigator.appVersion,10);
}
// Return data
return [browserName, majorVersion];
}
// Replace all
function _replaceAll(string, find, replace) {
return string.replace(new RegExp(find.replace(/([.*+?^=!:${}()|\[\]\/\\])/g, "\\$1"), "g"), replace);
}
// Wrap an element
function _wrap(elements, wrapper) {
// Convert `elms` to an array, if necessary.
if (!elements.length) {
elements = [elements];
}
// Loops backwards to prevent having to clone the wrapper on the
// first element (see `child` below).
for (var i = elements.length - 1; i >= 0; i--) {
var child = (i > 0) ? wrapper.cloneNode(true) : wrapper;
var el = elements[i];
// Cache the current parent and sibling.
var parent = el.parentNode;
var sibling = el.nextSibling;
// Wrap the element (is automatically removed from its current
// parent).
child.appendChild(el);
// If the element had a sibling, insert the wrapper before
// the sibling to maintain the HTML structure; otherwise, just
// append it to the parent.
if (sibling) {
parent.insertBefore(child, sibling);
} else {
parent.appendChild(child);
}
}
}
// Toggle class on an element
function _toggleClass(element, name, state) {
if(element){
if(element.classList) {
element.classList[state ? "add" : "remove"](name);
}
else {
var className = (" " + element.className + " ").replace(/\s+/g, " ").replace(" " + name + " ", "");
element.className = className + (state ? " " + name : "");
}
}
}
// Bind event
function _on(element, event, callback) {
element.addEventListener(event, callback, false);
}
// Get click position relative to parent
// http://www.kirupa.com/html5/getting_mouse_click_position.htm
function _getClickPosition(event) {
var parentPosition = _fullscreen().isFullScreen() ? { x: 0, y: 0 } : _getPosition(event.currentTarget);
return {
x: event.clientX - parentPosition.x,
y: event.clientY - parentPosition.y
};
}
// Get element position
function _getPosition(element) {
var xPosition = 0;
var yPosition = 0;
while (element) {
xPosition += (element.offsetLeft - element.scrollLeft + element.clientLeft);
yPosition += (element.offsetTop - element.scrollTop + element.clientTop);
element = element.offsetParent;
}
return {
x: xPosition,
y: yPosition
};
}
// Deep extend/merge two Objects
// http://andrewdupont.net/2009/08/28/deep-extending-objects-in-javascript/
// Removed call to arguments.callee (used explicit function name instead)
function _extend(destination, source) {
for (var property in source) {
if (source[property] && source[property].constructor && source[property].constructor === Object) {
destination[property] = destination[property] || {};
_extend(destination[property], source[property]);
}
else {
destination[property] = source[property];
}
}
return destination;
}
// Fullscreen API
function _fullscreen() {
var fullscreen = {
supportsFullScreen: false,
isFullScreen: function() { return false; },
requestFullScreen: function() {},
cancelFullScreen: function() {},
fullScreenEventName: "",
element: null,
prefix: ""
},
browserPrefixes = "webkit moz o ms khtml".split(" ");
// check for native support
if (typeof document.cancelFullScreen != "undefined") {
fullscreen.supportsFullScreen = true;
}
else {
// check for fullscreen support by vendor prefix
for (var i = 0, il = browserPrefixes.length; i < il; i++ ) {
fullscreen.prefix = browserPrefixes[i];
if (typeof document[fullscreen.prefix + "CancelFullScreen" ] != "undefined" ) {
fullscreen.supportsFullScreen = true;
break;
}
}
}
// Safari doesn't support the ALLOW_KEYBOARD_INPUT flag so set it to not supported
// https://bugs.webkit.org/show_bug.cgi?id=121496
if(fullscreen.prefix === "webkit" && !!navigator.userAgent.match(/Version\/[\d\.]+.*Safari/)) {
fullscreen.supportsFullScreen = false;
}
// Update methods to do something useful
if (fullscreen.supportsFullScreen) {
fullscreen.fullScreenEventName = fullscreen.prefix + "fullscreenchange";
fullscreen.isFullScreen = function() {
switch (this.prefix) {
case "":
return document.fullScreen;
case "webkit":
return document.webkitIsFullScreen;
default:
return document[this.prefix + "FullScreen"];
}
};
fullscreen.requestFullScreen = function(element) {
return (this.prefix === "") ? element.requestFullScreen() : element[this.prefix + "RequestFullScreen"](this.prefix === "webkit" ? element.ALLOW_KEYBOARD_INPUT : null);
};
fullscreen.cancelFullScreen = function() {
return (this.prefix === "") ? document.cancelFullScreen() : document[this.prefix + "CancelFullScreen"]();
};
fullscreen.element = function() {
return (this.prefix === "") ? document.fullscreenElement : document[this.prefix + "FullscreenElement"];
};
}
return fullscreen;
}
// Player instance
function Plyr(container) {
var player = this;
player.container = container;
// Captions functions
// Credits: http://paypal.github.io/accessible-html5-video-player/
// For "manual" captions, adjust caption position when play time changed (via rewind, clicking progress bar, etc.)
function _adjustManualCaptions() {
player.subcount = 0;
while (_timecodeMax(player.captions[player.subcount][0]) < player.media.currentTime.toFixed(1)) {
player.subcount++;
if (player.subcount > player.captions.length-1) {
player.subcount = player.captions.length-1;
break;
}
}
}
// Display captions container and button (for initialization)
function _showCaptions() {
_toggleClass(player.container, config.classes.captions.enabled, true);
if (config.captions.defaultActive) {
_toggleClass(player.container, config.classes.captions.active, true);
player.buttons.captions.setAttribute("checked", "checked");
}
}
// Utilities for caption time codes
function _timecodeMin(tc) {
var tcpair = [];
tcpair = tc.split(" --> ");
return _subTcSecs(tcpair[0]);
}
function _timecodeMax(tc) {
var tcpair = [];
tcpair = tc.split(" --> ");
return _subTcSecs(tcpair[1]);
}
function _subTcSecs(tc) {
if (tc === null || tc === undefined) {
return 0;
}
else {
var tc1 = [],
tc2 = [],
seconds;
tc1 = tc.split(",");
tc2 = tc1[0].split(":");
seconds = Math.floor(tc2[0]*60*60) + Math.floor(tc2[1]*60) + Math.floor(tc2[2]);
return seconds;
}
}
// Find all elements
function _getElements(selector) {
return player.container.querySelectorAll(selector);
}
// Find a single element
function _getElement(selector) {
return _getElements(selector)[0];
}
// Insert controls
function _injectControls() {
// Insert custom video controls
if (config.debug) {
console.log("Injecting custom controls");
}
// Use specified html
// Need to do a default?
var html = config.html;
// Replace aria label instances
html = _replaceAll(html, "{aria-label}", config.playAriaLabel);
// Replace all id references
html = _replaceAll(html, "{id}", player.random);
// Inject into the container
player.container.insertAdjacentHTML("beforeend", html);
}
// Find the UI controls and store references
function _findElements() {
player.controls = _getElement(config.selectors.controls);
// Buttons
player.buttons = {};
player.buttons.play = _getElement(config.selectors.buttons.play);
player.buttons.pause = _getElement(config.selectors.buttons.pause);
player.buttons.restart = _getElement(config.selectors.buttons.restart);
player.buttons.rewind = _getElement(config.selectors.buttons.rewind);
player.buttons.forward = _getElement(config.selectors.buttons.forward);
player.buttons.mute = _getElement(config.selectors.buttons.mute);
player.buttons.captions = _getElement(config.selectors.buttons.captions);
player.buttons.fullscreen = _getElement(config.selectors.buttons.fullscreen);
// Progress
player.progress = {};
player.progress.bar = _getElement(config.selectors.progress);
player.progress.text = player.progress.bar.getElementsByTagName("span")[0];
// Volume
player.volume = _getElement(config.selectors.buttons.volume);
// Timing
player.duration = _getElement(config.selectors.duration);
player.seekTime = _getElements(config.selectors.seekTime);
}
// Setup media
function _setupMedia() {
player.media = player.container.querySelectorAll("audio, video")[0];
// If there's no media, bail
if(!player.media) {
console.error("No audio or video element found!");
return false;
}
// Remove native video controls
player.media.removeAttribute("controls");
// Set media type
player.type = (player.media.tagName.toLowerCase() == "video" ? "video" : "audio");
// Add type class
_toggleClass(player.container, config.classes[player.type], true);
// If there's no autoplay attribute, assume the video is stopped and add state class
_toggleClass(player.container, config.classes.stopped, (player.media.getAttribute("autoplay") === null));
// Inject the player wrapper
if(player.type === "video") {
// Create the wrapper div
var wrapper = document.createElement("div");
wrapper.setAttribute("class", config.classes.videoWrapper);
// Wrap the video in a container
_wrap(player.media, wrapper);
// Cache the container
player.videoContainer = wrapper;
}
}
// Setup captions
function _setupCaptions() {
if(player.type === "video") {
// Inject the container
player.videoContainer.insertAdjacentHTML("afterbegin", "<div class='" + config.selectors.captions.replace(".", "") + "'></div>");
// Cache selector
player.captionsContainer = _getElement(config.selectors.captions);
// Determine if HTML5 textTracks is supported
player.isTextTracks = false;
if (player.media.textTracks) {
player.isTextTracks = true;
}
// Get URL of caption file if exists
var captionSrc = "",
kind,
children = player.media.childNodes;
for (var i = 0; i < children.length; i++) {
if (children[i].nodeName.toLowerCase() === "track") {
kind = children[i].getAttribute("kind");
if (kind === "captions") {
captionSrc = children[i].getAttribute("src");
}
}
}
// Record if caption file exists or not
player.captionExists = true;
if (captionSrc === "") {
player.captionExists = false;
if (config.debug) {
console.log("No caption track found.");
}
}
else {
if (config.debug) {
console.log("Caption track found; URI: " + captionSrc);
}
}
// If no caption file exists, hide container for caption text
if (!player.captionExists) {
_toggleClass(player.container, config.classes.captions.enabled);
}
// If caption file exists, process captions
else {
var track = {}, tracks, j;
// If IE 10/11 or Firefox 31+ or Safari 7+, don"t use native captioning (still doesn"t work although they claim it"s now supported)
if ((player.browserName === "IE" && player.browserMajorVersion === 10) ||
(player.browserName === "IE" && player.browserMajorVersion === 11) ||
(player.browserName === "Firefox" && player.browserMajorVersion >= 31) ||
(player.browserName === "Safari" && player.browserMajorVersion >= 7)) {
if (config.debug) {
console.log("Detected IE 10/11 or Firefox 31+ or Safari 7+");
}
// set to false so skips to "manual" captioning
player.isTextTracks = false;
// turn off native caption rendering to avoid double captions [doesn"t work in Safari 7; see patch below]
track = {};
tracks = player.media.textTracks;
for (j=0; j < tracks.length; j++) {
track = player.media.textTracks[j];
track.mode = "hidden";
}
}
// Rendering caption tracks - native support required - http://caniuse.com/webvtt
if (player.isTextTracks) {
if (config.debug) {
console.log("textTracks supported");
}
_showCaptions(player);
track = {};
tracks = player.media.textTracks;
for (j=0; j < tracks.length; j++) {
track = player.media.textTracks[j];
track.mode = "hidden";
if (track.kind === "captions") {
_on(track, "cuechange",function() {
if (this.activeCues[0]) {
if (this.activeCues[0].hasOwnProperty("text")) {
player.captionsContainer.innerHTML = this.activeCues[0].text;
}
}
});
}
}
}
// Caption tracks not natively supported
else {
if (config.debug) {
console.log("textTracks not supported so rendering captions manually");
}
_showCaptions(player);
// Render captions from array at appropriate time
player.currentCaption = "";
player.subcount = 0;
player.captions = [];
_on(player.media, "timeupdate", function() {
// Check if the next caption is in the current time range
if (player.media.currentTime.toFixed(1) > _timecodeMin(player.captions[player.subcount][0]) &&
player.media.currentTime.toFixed(1) < _timecodeMax(player.captions[player.subcount][0])) {
player.currentCaption = player.captions[player.subcount][1];
}
// Is there a next timecode?
if (player.media.currentTime.toFixed(1) > _timecodeMax(player.captions[player.subcount][0]) &&
player.subcount < (player.captions.length-1)) {
player.subcount++;
}
// Render the caption
player.captionsContainer.innerHTML = player.currentCaption;
});
if (captionSrc !== "") {
// Create XMLHttpRequest Object
var xhr;
if (window.XMLHttpRequest) {
xhr = new XMLHttpRequest();
}
else if (window.ActiveXObject) { // IE8
xhr = new ActiveXObject("Microsoft.XMLHTTP");
}
xhr.onreadystatechange = function() {
if (xhr.readyState === 4) {
if (xhr.status === 200) {
if (config.debug) {
console.log("xhr = 200");
}
player.captions = [];
var records = [],
record,
req = xhr.responseText;
records = req.split("\n\n");
for (var r=0; r < records.length; r++) {
record = records[r];
player.captions[r] = [];
player.captions[r] = record.split("\n");
}
// Remove first element ("VTT")
player.captions.shift();
if (config.debug) {
console.log("Successfully loaded the caption file via ajax.");
}
}
else {
if (config.debug) {
console.log("There was a problem loading the caption file via ajax.");
}
}
}
}
xhr.open("get", captionSrc, true);
xhr.send();
}
}
// If Safari 7, removing track from DOM [see "turn off native caption rendering" above]
if (player.browserName === "Safari" && player.browserMajorVersion === 7) {
if (config.debug) {
console.log("Safari 7 detected; removing track from DOM");
}
tracks = player.media.getElementsByTagName("track");
player.media.removeChild(tracks[0]);
}
}
}
}
// Setup seeking
function _setupSeeking() {
// Update number of seconds in rewind and fast forward buttons
player.seekTime[0].innerHTML = config.seekInterval;
player.seekTime[1].innerHTML = config.seekInterval;
}
// Setup fullscreen
function _setupFullscreen() {
if(player.type === "video" && config.fullscreen.enabled) {
if(fullscreen.supportsFullScreen) {
if(config.debug) {
console.log("Fullscreen enabled");
}
_toggleClass(player.container, config.classes.fullscreen.enabled, true);
}
else if(config.debug) {
console.warn("Fullscreen not supported");
}
}
}
// Play media
function _play() {
player.media.play();
_toggleClass(player.container, config.classes.stopped);
_toggleClass(player.container, config.classes.playing, true);
}
// Pause media
function _pause() {
player.media.pause();
_toggleClass(player.container, config.classes.playing);
_toggleClass(player.container, config.classes.stopped, true);
}
// Restart playback
function _restart() {
// Move to beginning
player.media.currentTime = 0;
// Special handling for "manual" captions
if (!player.isTextTracks) {
player.subcount = 0;
}
// Play and ensure the play button is in correct state
_play();
}
// Rewind
function _rewind(seekInterval) {
// Use default if needed
if(typeof seekInterval === "undefined") {
seekInterval = config.seekInterval;
}
var targetTime = player.media.currentTime - seekInterval;
if (targetTime < 0) {
player.media.currentTime = 0;
}
else {
player.media.currentTime = targetTime;
}
// Special handling for "manual" captions
if (!player.isTextTracks && player.type === "video") {
_adjustManualCaptions(player);
}
}
// Fast forward
function _forward(seekInterval) {
// Use default if needed
if(typeof seekInterval === "undefined") {
seekInterval = config.seekInterval;
}
var targetTime = player.media.currentTime + seekInterval;
if (targetTime > player.media.duration) {
player.media.currentTime = player.media.duration;
}
else {
player.media.currentTime = targetTime;
}
// Special handling for "manual" captions
if (!player.isTextTracks && player.type === "video") {
_adjustManualCaptions(player);
}
}
// Toggle fullscreen
function _toggleFullscreen() {
if(!fullscreen.isFullScreen()) {
fullscreen.requestFullScreen(player.container);
}
else {
fullscreen.cancelFullScreen();
}
}
// Set volume
function _setVolume(volume) {
// Use default if needed
if(typeof volume === "undefined") {
volume = config.volume;
}
// Maximum is 10
if(volume > 10) {
volume = 10;
}
player.volume.value = volume;
player.media.volume = parseFloat(volume / 10);
_checkMute();
}
// Mute
function _toggleMute(muted) {
// If the method is called without parameter, toggle based on current value
if(typeof active === "undefined") {
muted = !player.media.muted;
player.buttons.mute.checked = muted;
}
player.media.muted = muted;
_checkMute();
}
// Toggle captions
function _toggleCaptions(active) {
// If the method is called without parameter, toggle based on current value
if(typeof active === "undefined") {
active = (player.container.className.indexOf(config.classes.captions.active) === -1);
player.buttons.captions.checked = active;
}
if (active) {
_toggleClass(player.container, config.classes.captions.active, true);
}
else {
_toggleClass(player.container, config.classes.captions.active);
}
}
// Check mute state
function _checkMute() {
_toggleClass(player.container, config.classes.muted, (player.media.volume === 0 || player.media.muted));
}
// Listen for events
function _listeners() {
// Fullscreen
_on(player.buttons.fullscreen, "click", _toggleFullscreen);
// Click video
if(player.type === "video" && config.click) {
_on(player.videoContainer, "click", function() {
if(player.media.paused) {
_play();
}
else if(player.media.ended) {
_restart();
}
else {
_pause();
}
});
}
// Play
_on(player.buttons.play, "click", function() {
_play();
player.buttons.pause.focus();
});
// Pause
_on(player.buttons.pause, "click", function() {
_pause();
player.buttons.play.focus();
});
// Restart
_on(player.buttons.restart, "click", _restart);
// Rewind
_on(player.buttons.rewind, "click", function() {
_rewind(config.seekInterval);
});
// Fast forward
_on(player.buttons.forward, "click", function() {
_forward(config.seekInterval);
});
// Get the HTML5 range input element and append audio volume adjustment on change
_on(player.volume, "change", function() {
_setVolume(this.value);
});
// Mute
_on(player.buttons.mute, "change", function() {
_toggleMute(this.checked);
});
// Duration
_on(player.media, "timeupdate", function() {
player.secs = parseInt(player.media.currentTime % 60);
player.mins = parseInt((player.media.currentTime / 60) % 60);
// Ensure it"s two digits. For example, 03 rather than 3.
player.secs = ("0" + player.secs).slice(-2);
player.mins = ("0" + player.mins).slice(-2);
// Render
player.duration.innerHTML = player.mins + ":" + player.secs;
});
// Progress bar
_on(player.media, "timeupdate", function() {
player.percent = (100 / player.media.duration) * player.media.currentTime;
if (player.percent > 0) {
player.progress.bar.value = player.percent;
player.progress.text.innerHTML = player.percent;
}
});
// Skip when clicking progress bar
_on(player.progress.bar, "click", function(event) {
player.pos = _getClickPosition(event).x / this.offsetWidth;
player.media.currentTime = player.pos * player.media.duration;
// Special handling for "manual" captions
if (!player.isTextTracks && player.type === "video") {
_adjustManualCaptions(player);
}
});
// Captions
_on(player.buttons.captions, "click", function() {
_toggleCaptions(this.checked);
});
// Clear captions at end of video
_on(player.media, "ended", function() {
if(player.type === "video") {
player.captionsContainer.innerHTML = "";
}
_toggleClass(player.container, config.classes.stopped, true);
_toggleClass(player.container, config.classes.playing);
});
}
function _init() {
// Setup the fullscreen api
fullscreen = _fullscreen();
// Sniff
player.browserInfo = _browserSniff();
player.browserName = player.browserInfo[0];
player.browserMajorVersion = player.browserInfo[1];
// Debug info
if(config.debug) {
console.log(player.browserName + " " + player.browserMajorVersion);
}
// If IE8, stop customization (use fallback)
// If IE9, stop customization (use native controls)
if (player.browserName === "IE" && (player.browserMajorVersion === 8 || player.browserMajorVersion === 9) ) {
if(config.debug) {
console.error("Browser not suppported.");
}
return false;
}
// Set up aria-label for Play button with the title option
if (typeof(config.title) === "undefined" || !config.title.length) {
config.playAriaLabel = "Play";
}
else {
config.playAriaLabel = "Play " + config.title;
}
// Setup media
_setupMedia();
// Generate random number for id/for attribute values for controls
player.random = Math.floor(Math.random() * (10000));
// Inject custom controls
_injectControls();
// Find the elements
_findElements();
// Set volume
_setVolume(config.volume);
// Setup fullscreen
_setupFullscreen();
// Captions
_setupCaptions();
// Seeking
_setupSeeking();
// Listeners
_listeners();
}
_init();
return {
media: player.media,
play: _play,
pause: _pause,
restart: _restart,
rewind: _rewind,
forward: _forward,
setVolume: _setVolume,
toggleMute: _toggleMute,
toggleCaptions: _toggleCaptions
}
}
// Expose setup function
api.setup = function(options){
// Extend the default options with user specified
config = _extend(defaults, options);
// If enabled carry on
// You may want to disable certain UAs etc
if(!config.enabled) {
return false;
}
// Get the players
var elements = document.querySelectorAll(config.selectors.container), players = [];
// Create a player instance for each element
for (var i = elements.length - 1; i >= 0; i--) {
// Get the current element
var element = elements[i];
// Setup a player instance and add to the element
element.plyr = new Plyr(element);
// Add to return array
players.push(element.plyr);
}
return players;
}
}(this.plyr = this.plyr || {}));

View File

@ -1,117 +0,0 @@
// ==========================================================================
// HTML5 Video Player Demo Page
// ==========================================================================
// Reset
@import "docs/normalize.less";
// Mixins
@import "docs/mixins.less";
// Fonts
@import "docs/fontface.less";
// Variables
// ---------------------------------------
// Colors
@blue: #3498DB;
@gray-dark: #343f4a;
@gray: #565d64;
@gray-light: #cbd0d3;
// Elements
@link-color: @blue;
// BORDER-BOX ALL THE THINGS!
// http://paulirish.com/2012/box-sizing-border-box-ftw/
*, *::after, *::before {
box-sizing: border-box;
}
html {
font-size: 62.5%;
}
body {
font-family: "Avenir", "Helvetica Neue", Helvetica, Arial, sans-serif;
background: #fff;
.font-size(16);
line-height: 1.5;
text-align: center;
color: #6D797F;
}
h1,
h2 {
letter-spacing: -.025em;
color: #2E3C44;
margin: 0 0 10px;
line-height: 1.2;
.font-smoothing();
}
h1 {
.font-size(64);
color: #3498DB;
}
p,
small {
margin: 0 0 20px;
}
small {
display: block;
.font-size(14);
}
header {
padding: 60px 0;
margin-bottom: 20px;
p {
.font-size(18);
}
}
a {
text-decoration: none;
color: @link-color;
border-bottom: 1px solid currentColor;
transition: all .3s ease;
&:hover,
&:focus {
color: #000;
}
&:focus {
.tab-focus();
}
}
.btn {
display: inline-block;
padding: 10px 25px;
background: @link-color;
border: 0;
color: #fff;
.font-smoothing(on);
font-weight: 600;
border-radius: 3px;
&:hover,
&:focus {
color: #fff;
background: darken(@link-color, 5%);
}
}
section {
padding-bottom: 80px;
}
// Players
.example-audio .player {
max-width: 480px;
}
.example-video .player {
max-width: 1200px;
}
.example-audio .player,
.example-video .player {
margin: 0 auto 20px;
&:fullscreen,
&-fullscreen {
max-width: none;
}
}

View File

@ -1,16 +0,0 @@
@font-face {
font-family: "Avenir";
src: url("../../assets/fonts/AvenirLTStd-Medium.woff2") format("woff2"),
url("../../assets/fonts/AvenirLTStd-Medium.woff") format("woff"),
url("../../assets/fonts/AvenirLTStd-Medium.ttf") format("truetype");
font-style: normal;
font-weight: 400;
}
@font-face {
font-family: "Avenir";
src: url("../../assets/fonts/AvenirLTStd-Heavy.woff2") format("woff2"),
url("../../assets/fonts/AvenirLTStd-Heavy.woff") format("woff"),
url("../../assets/fonts/AvenirLTStd-Heavy.ttf") format("truetype");
font-style: normal;
font-weight: 600;
}

View File

@ -1,41 +0,0 @@
// ==========================================================================
// Mixins
// ==========================================================================
// Contain floats: nicolasgallagher.com/micro-clearfix-hack/
// ---------------------------------------
.clearfix() {
zoom: 1;
&:before,
&:after { content: ""; display: table; }
&:after { clear: both; }
}
// Webkit-style focus
// ---------------------------------------
.tab-focus() {
// Default
outline: thin dotted @gray-dark;
// Webkit
//outline: 5px auto -webkit-focus-ring-color;
outline-offset: 1px;
}
// Use rems for font sizing
// ---------------------------------------
.font-size(@font-size: 16){
@rem: (@font-size / 10);
font-size: @font-size * 1px;
font-size: ~"@{rem}rem";
}
// Font smoothing
// ---------------------------------------
.font-smoothing(@mode: on) when (@mode = on) {
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
}
.font-smoothing(@mode: on) when (@mode = off) {
-moz-osx-font-smoothing: auto;
-webkit-font-smoothing: subpixel-antialiased;
}

View File

@ -1,406 +0,0 @@
/*! normalize.css v2.1.3 | MIT License | git.io/normalize */
/* ==========================================================================
HTML5 display definitions
========================================================================== */
/**
* Correct `block` display not defined in IE 8/9.
*/
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
main,
nav,
section,
summary {
display: block;
}
/**
* Correct `inline-block` display not defined in IE 8/9.
*/
audio,
canvas,
video {
display: inline-block;
}
/**
* Prevent modern browsers from displaying `audio` without controls.
* Remove excess height in iOS 5 devices.
*/
audio:not([controls]) {
display: none;
height: 0;
}
/**
* Address `[hidden]` styling not present in IE 8/9.
* Hide the `template` element in IE, Safari, and Firefox < 22.
*/
[hidden],
template {
display: none;
}
/* ==========================================================================
Base
========================================================================== */
/**
* 1. Set default font family to sans-serif.
* 2. Prevent iOS text size adjust after orientation change, without disabling
* user zoom.
*/
html {
font-family: sans-serif; /* 1 */
-ms-text-size-adjust: 100%; /* 2 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/**
* Remove default margin.
*/
body {
margin: 0;
}
/* ==========================================================================
Links
========================================================================== */
/**
* Remove the gray background color from active links in IE 10.
*/
a {
background: transparent;
}
/**
* Address `outline` inconsistency between Chrome and other browsers.
*/
a:focus {
outline: thin dotted;
}
/**
* Improve readability when focused and also mouse hovered in all browsers.
*/
a:active,
a:hover {
outline: 0;
}
/* ==========================================================================
Typography
========================================================================== */
/**
* Address variable `h1` font-size and margin within `section` and `article`
* contexts in Firefox 4+, Safari 5, and Chrome.
*/
h1 {
font-size: 2em;
margin: 0.67em 0;
}
/**
* Address styling not present in IE 8/9, Safari 5, and Chrome.
*/
abbr[title] {
border-bottom: 1px dotted;
}
/**
* Address style set to `bolder` in Firefox 4+, Safari 5, and Chrome.
*/
b,
strong {
font-weight: bold;
}
/**
* Address styling not present in Safari 5 and Chrome.
*/
dfn {
font-style: italic;
}
/**
* Address differences between Firefox and other browsers.
*/
hr {
-moz-box-sizing: content-box;
box-sizing: content-box;
height: 0;
}
/**
* Address styling not present in IE 8/9.
*/
mark {
background: #ff0;
color: #000;
}
/**
* Correct font family set oddly in Safari 5 and Chrome.
*/
code,
kbd,
pre,
samp {
font-family: monospace, serif;
font-size: 1em;
}
/**
* Improve readability of pre-formatted text in all browsers.
*/
pre {
white-space: pre-wrap;
}
/**
* Set consistent quote types.
*/
q {
quotes: "\201C" "\201D" "\2018" "\2019";
}
/**
* Address inconsistent and variable font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` affecting `line-height` in all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sup {
top: -0.5em;
}
sub {
bottom: -0.25em;
}
/* ==========================================================================
Embedded content
========================================================================== */
/**
* Remove border when inside `a` element in IE 8/9.
*/
img {
border: 0;
}
/**
* Correct overflow displayed oddly in IE 9.
*/
svg:not(:root) {
overflow: hidden;
}
/* ==========================================================================
Figures
========================================================================== */
/**
* Address margin not present in IE 8/9 and Safari 5.
*/
figure {
margin: 0;
}
/* ==========================================================================
Forms
========================================================================== */
/**
* Define consistent border, margin, and padding.
*/
fieldset {
border: 1px solid #c0c0c0;
margin: 0 2px;
padding: 0.35em 0.625em 0.75em;
}
/**
* 1. Correct `color` not being inherited in IE 8/9.
* 2. Remove padding so people aren't caught out if they zero out fieldsets.
*/
legend {
border: 0; /* 1 */
padding: 0; /* 2 */
}
/**
* 1. Correct font family not being inherited in all browsers.
* 2. Correct font size not being inherited in all browsers.
* 3. Address margins set differently in Firefox 4+, Safari 5, and Chrome.
*/
button,
input,
select,
textarea {
font-family: inherit; /* 1 */
font-size: 100%; /* 2 */
margin: 0; /* 3 */
}
/**
* Address Firefox 4+ setting `line-height` on `input` using `!important` in
* the UA stylesheet.
*/
button,
input {
line-height: normal;
}
/**
* Address inconsistent `text-transform` inheritance for `button` and `select`.
* All other form control elements do not inherit `text-transform` values.
* Correct `button` style inheritance in Chrome, Safari 5+, and IE 8+.
* Correct `select` style inheritance in Firefox 4+ and Opera.
*/
button,
select {
text-transform: none;
}
/**
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
* and `video` controls.
* 2. Correct inability to style clickable `input` types in iOS.
* 3. Improve usability and consistency of cursor style between image-type
* `input` and others.
*/
button,
html input[type="button"], /* 1 */
input[type="reset"],
input[type="submit"] {
-webkit-appearance: button; /* 2 */
cursor: pointer; /* 3 */
}
/**
* Re-set default cursor for disabled elements.
*/
button[disabled],
html input[disabled] {
cursor: default;
}
/**
* 1. Address box sizing set to `content-box` in IE 8/9/10.
* 2. Remove excess padding in IE 8/9/10.
*/
input[type="checkbox"],
input[type="radio"] {
box-sizing: border-box; /* 1 */
padding: 0; /* 2 */
}
/**
* 1. Address `appearance` set to `searchfield` in Safari 5 and Chrome.
* 2. Address `box-sizing` set to `border-box` in Safari 5 and Chrome
* (include `-moz` to future-proof).
*/
input[type="search"] {
-webkit-appearance: textfield; /* 1 */
-moz-box-sizing: content-box;
-webkit-box-sizing: content-box; /* 2 */
box-sizing: content-box;
}
/**
* Remove inner padding and search cancel button in Safari 5 and Chrome
* on OS X.
*/
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* Remove inner padding and border in Firefox 4+.
*/
button::-moz-focus-inner,
input::-moz-focus-inner {
border: 0;
padding: 0;
}
/**
* 1. Remove default vertical scrollbar in IE 8/9.
* 2. Improve readability and alignment in all browsers.
*/
textarea {
overflow: auto; /* 1 */
vertical-align: top; /* 2 */
}
/* ==========================================================================
Tables
========================================================================== */
/**
* Remove most spacing between table cells.
*/
table {
border-collapse: collapse;
border-spacing: 0;
}

View File

@ -1,407 +0,0 @@
// ==========================================================================
// HTML5 Media Player
// ==========================================================================
// Variables
// -------------------------------
// Colors
@blue: #3498DB;
@gray-dark: #343f4a;
@gray: #565d64;
@gray-light: #cbd0d3;
// Controls
@controls-bg: @gray-dark;
@control-color: @gray-light;
@control-color-active: @blue;
@control-color-inactive: @gray;
@control-spacing: 10px;
// Progress
@progress-bg: @gray;
@progress-value-bg: @blue;
// Range
@range-track-height: 6px;
@range-thumb-height: (@range-track-height * 2);
@range-thumb-width: (@range-track-height * 2);
@range-thumb-bg: @control-color;
@range-thumb-bg-focus: @control-color-active;
// Utility classes & mixins
// -------------------------------
// Screen reader only
.sr-only {
position: absolute !important;
clip: rect(1px, 1px, 1px, 1px);
padding: 0 !important;
border: 0 !important;
height: 1px !important;
width: 1px !important;
overflow: hidden;
}
// Contain floats: nicolasgallagher.com/micro-clearfix-hack/
.clearfix() {
zoom: 1;
&:before,
&:after { content: ""; display: table; }
&:after { clear: both; }
}
// Tab focus styles
.tab-focus() {
outline: thin dotted #000;
outline-offset: 1px;
}
// Range styling
// ---------------------------------------
.range-thumb() {
height: @range-thumb-height;
width: @range-thumb-width;
background: @range-thumb-bg;
border: 0;
border-radius: (@range-thumb-height / 2);
transition: background .3s ease;
cursor: ew-resize;
}
.range-track() {
height: @range-track-height;
background: @gray;
border: 0;
border-radius: (@range-track-height / 2);
}
// Font smoothing
// ---------------------------------------
.font-smoothing(@mode: on) when (@mode = on) {
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
}
.font-smoothing(@mode: on) when (@mode = off) {
-moz-osx-font-smoothing: auto;
-webkit-font-smoothing: subpixel-antialiased;
}
// Styles
// -------------------------------
// Base
.player {
position: relative;
max-width: 100%;
min-width: 290px;
overflow: hidden; // For the controls
background: #000;
// BORDER-BOX ALL THE THINGS!
// http://paulirish.com/2012/box-sizing-border-box-ftw/
&,
*,
*::after,
*::before {
box-sizing: border-box;
}
// For video
&-video-wrapper {
position: relative;
}
video {
width: 100%;
height: auto;
vertical-align: middle;
}
// Captions
&-captions {
display: none;
position: absolute;
bottom: 0;
left: 0;
width: 100%;
padding: 20px;
min-height: 2.5em;
color: #fff;
font-size: 16px;
text-shadow: 0 1px 1px rgba(0,0,0, .75);
text-align: center;
.font-smoothing();
@media (min-width: 560px) {
font-size: 24px;
}
}
&.captions-active &-captions {
display: block;
}
// Player controls
&-controls {
.clearfix();
.font-smoothing();
position: relative;
padding: (@control-spacing * 2) @control-spacing @control-spacing;
background: @controls-bg;
line-height: 1;
// Layout
&-sound {
display: block;
margin: @control-spacing auto 0;
}
@media (min-width: 560px) {
&-playback {
float: left;
}
&-sound {
float: right;
margin-top: 0;
}
}
input + label,
button {
display: inline-block;
vertical-align: middle;
margin: 0 2px;
padding: (@control-spacing / 2) @control-spacing;
transition: background .3s ease;
border-radius: 3px;
cursor: pointer;
svg {
width: 18px;
height: 18px;
display: block;
fill: currentColor;
transition: fill .3s ease;
}
}
input + label,
input.inverted:checked + label {
color: @control-color-inactive;
}
button,
input.inverted + label,
input:checked + label {
color: @control-color;
}
button {
border: 0;
background: transparent;
overflow: hidden;
}
button:hover,
label:hover {
background: @control-color-active;
svg {
fill: #fff;
}
}
input:focus + label,
button:focus {
.tab-focus();
svg {
fill: #fff;
}
}
.icon-exit-fullscreen,
.icon-muted {
display: none;
}
.player-time {
display: inline-block;
vertical-align: middle;
margin-left: @control-spacing;
color: #fff;
font-weight: 600;
font-size: 14px;
.font-smoothing();
}
}
// Player progress
// <progress> element
&-progress {
position: absolute;
top: 0;
left: 0;
right: 0;
width: 100%;
height: @control-spacing;
margin: 0;
vertical-align: top;
&[value] {
-webkit-appearance: none;
border: none;
background: @progress-bg;
cursor: pointer;
color: @progress-value-bg;
&::-webkit-progress-bar {
background: @progress-bg;
}
// Inherit from currentColor;
&::-webkit-progress-value {
background: currentColor;
}
&::-moz-progress-bar {
background: currentColor;
}
}
}
// States
&-controls [data-player='pause'],
&.playing .player-controls [data-player='play'] {
display: none;
}
&.playing .player-controls [data-player='pause'] {
display: inline-block;
}
// Muted
&.muted .player-controls .icon-muted {
display: block;
& + svg {
display: none;
}
}
// Volume control
// <input[type='range']> element
&-volume {
vertical-align: middle;
-webkit-appearance: none;
-moz-appearance: none;
//height: 6px;
width: 100px;
margin: 0 @control-spacing 0 0;
padding: 0;
cursor: pointer;
background: none;
// Webkit
&::-webkit-slider-runnable-track {
.range-track();
}
&::-webkit-slider-thumb {
-webkit-appearance: none;
margin-top: -((@range-thumb-height - @range-track-height) / 2);
.range-thumb();
}
// Mozilla
&::-moz-range-track {
.range-track();
}
&::-moz-range-thumb {
.range-thumb();
}
// Microsoft
&::-ms-track {
height: @range-track-height;
background: transparent;
border-color: transparent;
border-width: ((@range-thumb-height - @range-track-height) / 2) 0;
color: transparent;
}
&::-ms-fill-lower,
&::-ms-fill-upper {
.range-track();
}
&::-ms-thumb {
.range-thumb();
}
&:focus {
outline: 0;
&::-webkit-slider-thumb {
background: @range-thumb-bg-focus;
}
&::-moz-range-thumb {
background: @range-thumb-bg-focus;
}
&::-ms-thumb {
background: @range-thumb-bg-focus;
}
}
}
// Full screen mode
&-fullscreen,
&:fullscreen {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
height: 100%;
width: 100%;
z-index: 999999;
.player-video-wrapper {
height: 100%;
width: 100%;
video {
height: 100%;
}
.player-captions {
top: auto;
bottom: 90px;
@media (min-width: 560px) and (max-width: 767px) {
bottom: 60px;
}
@media (min-width: 768px) {
bottom: 80px;
}
}
}
.player-controls {
position: absolute;
bottom: 0;
left: 0;
right: 0;
.icon-exit-fullscreen {
display: block;
& + svg {
display: none;
}
}
}
}
// Some options are hidden by default
[data-player='captions'],
[data-player='captions'] + label,
[data-player='fullscreen'],
[data-player='fullscreen'] + label {
display: none;
}
&.captions-enabled [data-player='captions'],
&.captions-enabled [data-player='captions'] + label,
&.fullscreen-enabled [data-player='fullscreen'],
&.fullscreen-enabled [data-player='fullscreen'] + label {
display: inline-block;
}
// Full browser view hides toggle
&-fullscreen [data-player='fullscreen'],
&-fullscreen [data-player='fullscreen'] + label {
display: none !important;
}
}

View File

@ -1,54 +0,0 @@
<div class="player-controls">
<progress class="player-progress" max="100" value="0">
<span>0</span>% played
</progress>
<span class="player-controls-playback">
<button type="button" data-player="restart">
<svg><use xlink:href="#icon-refresh"></use></svg>
<span class="sr-only">Restart</span>
</button>
<button type="button" data-player="rewind">
<svg><use xlink:href="#icon-rewind"></use></svg>
<span class="sr-only">Rewind <span class="player-seek-time">10</span> seconds</span>
</button>
<button type="button" aria-label="{aria-label}" data-player="play">
<svg><use xlink:href="#icon-play"></use></svg>
<span class="sr-only">Play</span>
</button>
<button type="button" data-player="pause">
<svg><use xlink:href="#icon-pause"></use></svg>
<span class="sr-only">Pause</span>
</button>
<button type="button" data-player="fast-forward">
<svg><use xlink:href="#icon-fast-forward"></use></svg>
<span class="sr-only">Fast forward <span class="player-seek-time">10</span> seconds</span>
</button>
<span class="player-time">
<span class="sr-only">Time</span>
<span class="player-duration">00:00</span>
</span>
</span>
<span class="player-controls-sound">
<input class="inverted sr-only" id="mute{id}" type="checkbox" data-player="mute">
<label id="mute{id}" for="mute{id}">
<svg class="icon-muted"><use xlink:href="#icon-muted"></use></svg>
<svg><use xlink:href="#icon-sound"></use></svg>
<span class="sr-only">Mute</span>
</label>
<label for="volume{id}" class="sr-only">Volume:</label>
<input id="volume{id}" class="player-volume" type="range" min="0" max="10" value="5" data-player="volume">
<input class="sr-only" id="captions{id}" type="checkbox" data-player="captions">
<label for="captions{id}">
<svg><use xlink:href="#icon-bubble"></use></svg>
<span class="sr-only">Captions</span>
</label>
<button type="button" data-player="fullscreen">
<svg class="icon-exit-fullscreen"><use xlink:href="#icon-collapse"></use></svg>
<svg><use xlink:href="#icon-expand"></use></svg>
<span class="sr-only">Toggle fullscreen</span>
</button>
</span>
</div>

View File

@ -1,29 +1,33 @@
{
"name": "plyr",
"description": "A simple HTML5 media player using custom controls",
"homepage": "http://plyr.io",
"keywords": [
"Audio",
"Video",
"HTML5 Audio",
"HTml5 Video"
],
"authors": [
"Sam Potts <me@sampotts.me>"
],
"dependencies": {},
"main": [
"dist/css/plyr.css",
"dist/js/plyr.js"
],
"ignore": [
"node_modules",
"bower_components",
".gitignore"
],
"repository": {
"type": "git",
"url": "git://github.com/selz/plyr.git"
},
"license": "BSD"
"name": "plyr",
"description": "A simple HTML5 media player using custom controls",
"homepage": "http://plyr.io",
"keywords": [
"Audio",
"Video",
"HTML5 Audio",
"HTML5 Video"
],
"authors": [
"Sam Potts <sam@potts.es>"
],
"dependencies": {},
"main": [
"dist/plyr.css",
"dist/plyr.js",
"dist/plyr.svg",
"src/less/plyr.less",
"src/scss/plyr.scss",
"src/js/plyr.js"
],
"ignore": [
"node_modules",
"bower_components",
".gitignore"
],
"repository": {
"type": "git",
"url": "git://github.com/sampotts/plyr.git"
},
"license": "MIT"
}

View File

@ -1,14 +1,20 @@
{
"less": {
"plyr.css": ["assets/less/plyr.less"],
"docs.css": ["assets/less/docs.less"]
},
"js": {
"plyr.js": ["assets/js/plyr.js"],
"docs.js": [
"assets/js/lib/hogan-3.0.2.mustache.js",
"dist/js/templates.js",
"assets/js/docs.js"
]
}
}
"plyr": {
"sass": {
"plyr.css": "src/sass/plyr.scss"
},
"js": {
"plyr.js": "src/js/plyr.js",
"plyr.polyfilled.js": "src/js/plyr.polyfilled.js"
}
},
"demo": {
"sass": {
"demo.css": "demo/src/sass/bundles/demo.scss",
"error.css": "demo/src/sass/bundles/error.scss"
},
"js": {
"demo.js": "demo/src/js/demo.js"
}
}
}

977
changelog.md Normal file
View File

@ -0,0 +1,977 @@
# 3.3.18
- Ads are now only supported on HTML5 videos as it violates terms of service for YouTube and Vimeo 😢
- Fix i18n defaults path on README (thanks @meyt!)
- Minor increaseVolume and decreaseVolume changes (thanks @friday!)
# v3.3.17
- Fix YouTube muting after seeking with the progress slider (thanks @friday!)
- Respect preload="none" when setting quality if the media hasn't been loaded some other way (thanks @friday!)
# v3.3.16
- Fixed regression relating the play button status (fixes #1048)
# v3.3.15
- Fix for error relating to play buttons when switching source
# v3.3.14
- Fix sprite loading regression
# v3.3.13
You guessed it, a load of awesome changes from contributors:
Thanks @friday for the following:
- Captions fixes
- Fix poster race conditions
- Minor code improvements for quality switching
- Minor event changes
- Fix condition in events.toggleListener to allow non-elements
- Suggestion: Remove array newline rule
- Contributions improvements
- fix: html5.cancelRequest not remove source tag correctly (thanks @a60814billy)
- remove event listeners in destroy() (thanks @cky917)
- Fix markdown in README (thanks @azu)
- Some parts of the accessibility improvements outlined in #905 (more on the way...)
- Fix for bug where volume slider didn't always show
# v3.3.12
- Fix synthetic event bubble/proxy loses detail (thanks @friday!)
- Make utils static (thanks @friday!)
- Fix for YouTube and Vimeo pausing after seek (thanks @friday!)
- Vimeo: Update playback state and assure events are triggered on load (thanks @friday!)
- Captions rewrite (use index internally to support missing or duplicate languages) (thanks @friday and @philipgiuliani!)
- Contributing document and codepen demo updates (thanks @friday!)
- Fix for after clicking on the progress bar, keyboard operations will not work (thanks @cky917!)
# v3.3.10
- Fix for buffer display alignment and incorrect BEM classname
- Fix for playback not resuming position after quality swap (fixes #991, thanks @philipgiuliani!)
- Travis integration (thanks @friday!)
- Translate quality badges and quality names (thanks @philipgiuliani!)
- Improve captions handling for streaming (thanks @friday!)
- Call duration update method manually if user config has duration (thanks @friday!)
# v3.3.9
Again, more changes from @friday!
- Restore window reference in `is.cue()`
- Fix InvalidStateError and IE11 issues
- Respect storage being disabled for storage getter
# v3.3.8
Many changes here thanks to @friday:
- Added missing URL polyfill
- Pause while seeking to mimic default HTML5 behaviour
- Add `seeked` event listener to update progress (fixes #966)
- Trigger seeked event in youtube plugin if either playing or paused (fixes #921)
- Fix for YouTube and Vimeo autoplays on seek (fixes #876)
- Toggle controls improvements
- Cleanup unused code
- Poster image loading improvements
- Fix for seek tooltip vs click accuracy
# v3.3.7
- Poster fixes (thanks @friday)
- Grid tweak
# v3.3.6
- Vimeo fixes for mute state
- Vimeo ID fix (fixes #945)
- Use `<div>` for poster container
- Tooltip fixes for unicode languages (fixes #943)
# v3.3.5
- Removed `.load()` call as it breaks HLS (see #870)
# v3.3.4
- Fix for controls sometimes not showing while video is playing
- Fixed logic for show home tab on option select
# v3.3.3
- Reverted change to show home tab on option select due to usability regression
# v3.3.2
- Fix for ads running in audio
- Fix for setting poster on source change
## v3.3.0
- Now using a custom poster image element to hide the YouTube play button and give more control over when the poster image shows
- Renamed `showPosterOnEnd` to `resetOnEnd` as it makes more sense and now works for all players and does not reload media
- Fix for same domain SVG URLs (raised by Jochem in Slack)
- [`URL`](https://developer.mozilla.org/en-US/docs/Web/API/Window/URL) is polyfill now required
- Added pause className (fixes #941)
- Button height set in CSS (auto) (fixes #928)
- Don't autoplay cloned original media (fixes #936)
- Return to the home menu pane after selecting an option
## v3.2.4
- Fix issue wher player never reports as ready if controls is empty array
- Fix issue where screen reader labels were removed from time displays
- Fix issue where custom controls placeholders were not populated
- Custom controls HTML example updated
- Fix for aria-label being set to the initial state on toggle buttons, overriding the inner labels
- Fix for hidden mute button on iOS (not functional for Vimeo due to API limitations) (fixes #656)
## v3.2.3
- Fix for iOS 9 throwing error for `name` property in fullscreen API (fixes #908)
## v3.2.2
- Fix for regression in 3.2.1 resulting in hidden buffer display (fixes #920)
- Cleaned up incorrect use of `aria-hidden` attribute
## v3.2.1
- Accessibility improvements for the controls (part of #905 fixes)
- Fix for context menu showing on YouTube (thanks Anthony Recenello in Slack)
- Vimeo fix for their API not returning the right duration until playback begins (fixes #891)
## v3.2.0
- Fullscreen fixes (thanks @friday)
- Menu fix for if speed not in config
- Menu z-index fix (thanks @danielsarin)
- i18n fix for missing "Normal" string (thanks @danielsarin)
- Safer check for active caption (thanks @Antonio-Laguna)
- Add custom property fallback (thanks @friday)
- Fixed bug for captions with no srclang and labels and improved logic (fixes #875)
- Fix for `playing` false positive (fixes #898)
- Fix for IE issue with navigator.language (thanks @nicolasthy) (fixes #893)
- Fix for Vimeo controls missing on iOS (thanks @verde-io) (fixes #807)
- Fix for double vimeo caption rendering (fixes #877)
## v3.1.0
- Styling fixes
## v3.1.0-beta.2
- YouTube playback speed fixes
## v3.1.0-beta.1
- HTML5 quality selection
- Improvements to the YouTube quality selection
## v3.0.11
- Muted and autoplay fixes
- Small bug fixes from Sentry logs
## v3.0.10
- Docs fix
- Package upgrades
## v3.0.9
- Demo fix
- Fix Vimeo regression
## v3.0.8
- Vimeo hotfix for private videos
## v3.0.7
- Fix for keyboard shortcut error with fast forward
- Fix for Vimeo trying to set playback rate when not allowed
## v3.0.6
- Improved the logic for the custom handlers preventing default handlers
## v3.0.5
- Removed console messages
## v3.0.4
- Fixes for fullscreen not working inside iframes
- Fixes for custom handlers being able to prevent default
- Fixes for controls not hiding/showing correctly on Mobile Safari
## v3.0.3
- Vimeo offset tweak (fixes #826)
- Fix for .stop() method (fixes #819)
- Check for array for speed options (fixes #817)
- Restore as float (fixes #828)
- Fix for Firefox fullscreen oddness (Fixes #821)
- Improve Sprite checking (fixes #827)
- Fix fast-forward control (thanks @saadshahd)
- Fix the options link in the readme (thanks @DanielRuf)
## v3.0.2
- Fix for Safari not firing error events when trying to load blocked scripts
## v3.0.1
- Fix for trying to accessing local storage when it's blocked
# v3.0.0
This is a massive release. A _mostly_ complete rewrite in ES6. What started out as a few changes quickly snowballed. There's many breaking changes so be careful upgrading.
### Big changes
- New settings menu complete with funky animations
- Ability to adjust speed of playback
- Ability to toggle caption language (HTML5 and Vimeo only)
- Ability to set YouTube quality (HTML5 will follow)
- Added support for Vimeo captions
- Added Picture-in-Picture support (Safari only)
- Added AirPlay support (again, Safari only)
- Added `playsinline` support for iOS 10+
- Soundcloud removed until I can work on a plugin framework
- Embedded players are now progressively enhanced - no more empty `<div>`s!
### Other stuff
- Now using SASS exclusively. Sorry, LESS folk it just made sense to maintain one method as SASS is what the cool kids use. It may come back if we work out an automated way to convert the SASS
- Moved to ES6. All the rage these days. You'll need to look at polyfills. The demo uses [polyfill.io](https://polyfill.io)
- Added basic looping support
- Added an aspect ratio option for those that can't leave the 90s and want 4:3
- `controlshidden` and `controlsshown` events added for when the controls show or hide
- `qualityrequested` and `qualitychange` events for YouTube quality control (HTML5 will follow)
- Volume is now `0` to `1` as per HTML5 spec
- No longer bodging a `<progress>` behind the `<input type="range">` to make up for WebKit's lack of lower fill styling
- Captions now render with line breaks as intended
- Captions now render without AJAX using the native events etc
- Added a fallback for getting YouTube video data incase `.getVideoData()` disappears when one of their developers randomly deletes it again
- Setup and building of the UI should be way "snappier"
- Click to toggle inverted time (e.g. 0:01 or -2:59 for a 3 minute video at 1 seconds) - new `toggleInvert` and `invertTime` options
- Added `autopause` option for Vimeo
- Added `muted` option for you guessed it, muted playback
- Restored the `.off()` API method
- `.play()` will now return a promise to prevent that pesky uncaught promise issue in Chrome etc
- Pressing and hold the seek bar no longer freezes all other updates of the UI
...plus loads of bug fixes.
### Breaking changes
You gotta break eggs to make an omelette. Sadly, there's quite a few breaking changes:
- Setup now uses proper constructor, accepts a single selector/element/node and returns a single instance - much simpler than before
- Much of the API is now using getters and setters rather than methods (where it makes sense) to match the HTML5 API - see the docs for more info
- The data attributes for the embeds are now `data-plyr-provider` and `data-plyr-embed-id` to prevent compatibility issues. These can be changed under `config.attributes.embed` if required
- `blankUrl` -> `blankVideo`
- `volume` is now `0` to `1` as per HTML5 spec
- `keyboardShorcuts` (typo) is now just `keyboard`
- `loop` is now `loop.active` in preparation for loop enhancements later
- `html` option for custom controls removed in favour of the `controls` option which now accepts an array (to use built in controls) or a string of HTML for custom controls.
- `classes` -> `classNames`
- `classes.videoWrapper` -> `classNames.video`
- `classes.embedWrapper` -> `classNames.embed`
- `classes.ready` removed
- `classes.setup` removed
- `classes.muted` removed
- `classes.fullscreen.active` removed in favour of the `:fullscreen` selector
- `selectors.html5` removed
- `selectors.embed` removed
- `selectors.buttons.seek` -> `selectors.inputs.seek`
- `selectors.volume.input` -> `selectors.inputs.volume`
- `selectors.volume.display` -> `selectors.display.volume`
- `selectors.currentTime` -> `selectors.display.currentTime`
- `selectors.duration` -> `selectors.display.duration`
### Polyfilling
Because we're using the fancy new ES6 syntax, you will need to polyfill for vintage browsers if you want to use Plyr and still support them. Luckily there's a decent service for this that makes it painless, [polyfill.io](https://polyfill.io). Alternatively, you can use the prebuilt polyfilled build but bear in mind this is 20kb larger. I'd suggest working our your own polyfill strategy.
## v2.0.18
- Fix for YouTube .getVideoData() issue (fixes #709)
## v2.0.17
- Vimeo controls fix (fixes #697)
- SVG4everybody compatibility fix
- Allow Plyr.setup event listeners to be set up as separate event listeners (https://github.com/sampotts/plyr/pull/703)
- Added title to the layer html template (for custom controls) (https://github.com/sampotts/plyr/pull/649)
- Target is null bug fix (https://github.com/sampotts/plyr/pull/617)
- fix #684 memory leaks issues after destroy (https://github.com/sampotts/plyr/pull/700)
## v2.0.16
- Fullscreen bug fix (fixes #664)
## v2.0.15
- Demo fix
## v2.0.14
- CDN URL updates. Sorry, still working on V3 as hard as I can...
## v2.0.13
- Repo moved and Vimeo demo fix
## v2.0.12
- Ability to set custom `blankUrl` for source changes (https://github.com/sampotts/plyr/pull/504)
- Ability to set caption button listener (https://github.com/sampotts/plyr/pull/468)
## v2.0.11
- Fix for `cleanUp` being called twice (thanks to @sebastiancarlsson)
- Fix for YouTube controls on iPad (fixes #391)
## v2.0.10
- Added seek event fixes for Vimeo and YouTube (fixes #409)
- Added support for embed URLs rather than ID only (fixes #345)
## v2.0.9
- Temporary patch for the YouTube API issues with `getDuration()` (relates to #374)
## v2.0.8
- Added `isPaused()` API method (thanks to @darrena092)
- Allowed `.on()` API method to be chainable (thanks to @gurupras) (fixes #357)
- Improved the "awful" rendering of captions on small screens in fullscreen mode (fixes #390)
- Fix for Firefox VTT compatibility (thanks to @magourex)
- Fix for Firefox Developer Edition blank video due to `-webkit-mask-image` issue (fixes #392)
- Added Issue and PR templates with the aim of reducing duplicate or duff issues
## v2.0.7
- Fixed `getCurrentTime()` method (fixes #351)
- Added `getVolume()` , `isMuted()` and `getDuration()` API methods (fixes #346)
## v2.0.6
- Fixed merge issue with `Updated define to work with AMD imports #326` PR
- Code formatting
## v2.0.5
- Fix for Vimeo in IE9 & IE10
- Fix for HTML5 elements not firing `ready` event
## v2.0.4
- Fix for Firefox full screen (fixes #343)
## v2.0.3
- Set 'global' keyboard shortcut option to false as default, added `<textarea>` to editable elements to be ignored
## v2.0.2
- Added 'global' keyboard shortcut option
## v2.0.1
- Version bump for NPM (sorry for folks who upgraded to the now deleted v1.9.0 through NPM)
# v2.0.0
This version contains several potential **_breaking changes_**:
- `setup()` has been reverted to pre v1.8.0 behaviour; meaning it will return the _instance_ rather than the _element_. This is because the reference to the instance is no longer added to the original element (see below).
- The reference to the `plyr` instance is now added to the media element rather than original container. This is because if a container with multiple children was passed to `setup()` the references to all instances would have been added to the container, creating issues. I would recommend using the return value from `setup()` or the new `get()` method to access the instance.
- Players will always be wrapped in their own div now - this makes `setup()` and `destroy()` cleaner. This _may_ break any custom styling based on DOM position.
- Players no longer seek to 0 on 'ended' - this is to fix a bug with Microsoft Edge as it triggers 'ended' on media change for whatever reason. They'll never change ;-)
And some other changes and bug fixes:
- New `get()` method on the global plyr object to get all instances inside a container
- New API methods: - `getOriginal()` to get the original, _unmodified_ element plyr was setup on (`<video>`, `<audio>` or empty `<div>` for YouTube and Vimeo) - `getContainer()` to get the players outer wrapper element - `getMedia()` to get the players media element (`<video>`, `<audio>` or empty `<div>` for YouTube and Vimeo) - `getEmbed()` to access the YouTube or Vimeo API directly - `getType()` to get the type of the player - `isReady()` to determine if an instance has completed setup and necessary APIs are loaded (for YouTube / Vimeo) - `on()` to provide an easy way to listen to events - `stop()` to, you guessed it, stop the player
- `destroy()` now works correctly for YouTube and Vimeo (fixes #272)
- New `destroyed` event when `destroy()` has completed (original element is passed as event.target)
- Default volume is now 10 (max) rather than 5
- Sprite is only loaded once (fixes #259)
- Fixes for Vimeo post message bugs on source change or destroy (fixes #318)
- Save caption state in storage (fixes #311)
- Added keyboard shortcuts to the current focused player (with `keyboardShortcuts` boolean option to disable) (fixes #309)
- Fix for captions bug (fixes #332)
- Change to AMD (fixes #298)
## v1.8.12
- Vimeo keyboard focus fix (Fixes #317)
- Fix for Vimeo on basic support devices
## v1.8.11
- Fix for keyboard navigation on Vimeo (Fixes #317)
- Fix for bug introduced in v1.8.9 related to additional controls
- Vimeo API upgrade
- Fix for YouTube bug introduced in v1.8.9
- Added support for passing array to .setup() (Fixes #319)
## v1.8.10
- Fix for seek issues introduced in v1.8.9
## v1.8.9
- Fix for fullscreen not being defined (Fixes #295)
- Fix for multiline captions (Fixes #314)
- Clean up of type checks and fix for `restart()` (Fixes #315)
- Fix for `MEDIA_ERR_SRC_NOT_SUPPORTED` when calling `.source()` API method
## v1.8.8
- Added getCurrentTime API method (fixes #292)
- Fix for !hideControls on touch devices (fixes #303)
## v1.8.7
- Line height fix
## v1.8.6
- Reverted font size change
## v1.8.5
- Fixed overflow issues (fixes #286)
## v1.8.4
- Fix for large play button on small videos
## v1.8.3
- Disabled iPad support for YouTube and Vimeo due to iOS limitations with iFrame playback
- Fixed IE11 icon loading (fixes #269)
- Updated screenshot (fixes #281)
- Added WordPress plugin (fixes #239)
- Added Neos plugin
- Added HLS, Shaka and dash.js examples (see #235 for more)
- Improvements for controls hiding and showing on touch devices
## v1.8.2
- Fixed event bubbling
## v1.8.1
- Fixed inaccurate log message
# v1.8.0
- **_(Important)_** `setup()` now returns the element Plyr was setup on rather than the `plyr` object. This means `var player = plyr.setup()[0];` would now be `var player = plyr.setup()[0].plyr;`. This improves support for React and other virtual dom frameworks as mentioned in #254
- Fixed using a relative URL for `iconUrl` in IE (fixes #269)
# v1.7.0
- SASS cleanup (fixes #265)
- Docs tidy up to help quick start (fixes #253)
- Fix for issues with data attribute options passing (fixes #257)
- **_(Important)_** Removed the requirement for a wrapper div to setup Plyr and removed the dependency on the `plyr` classname as a JS hook. By default it will now look for `<video>`, `<audio>` and `[data-type]` elements. If you are just calling `setup()` with a `<div class="plyr">` you may want to give it a good test after upgrading. You can probably remove the wrapper div. The reason behind this is to make setup easier for newcomers and prevent the styling being used on unsupported players (because the plyr classname was used as a CSS and JS hook - which isn't ideal)
- Renamed the 'docs' folder to `demo` to avoid confusion - the readme is the docs after all
## v1.6.20
- Fix for multiple sprites being requested (fixes #259)
## v1.6.19
- Fix for scroll direction issues on volume control (fixes #258)
## v1.6.18
- Reduced rounding of seek value from 1 decimal point to 4 (fixes #242)
## v1.6.17
- Added `disableContextMenu` option to hide the right click context menu (fixes #248 and #225)
## v1.6.16
- Always hide standard controls (fixes #225)
- Fix for Tooltips overflowing (fixes #230)
## v1.6.15
- Restore scroll position when exiting full screen (fixes #236)
## v1.6.14
- SVG sprite loading automatically for an easier setup
- Touch devices now show controls on touch rather than pausing playback
## v1.6.13
- Decreased sensitivity and inverted scroll on volume slider (scroll up to increase, down to decrease)
## v1.6.12
- Fix for undefined buffer error
- Add scroll listener on volume slider (PR #227 bty @igoradamenko)
## v1.6.11
- Fix for Vimeo fullscreen (fixes #214)
## v1.6.10
- Changed default icon prefix from 'icon' to 'plyr' to avoid clashes
## v1.6.9
- Added 'latest' CDN option
- Renamed `sprite.svg` to `plyr.svg` to be inline with the other package files
## v1.6.8
- Fix for bug introduced in v1.6.7
## v1.6.7
- Fixes for using `source` API method on iOS
## v1.6.6
- Icons cleaned up
- IE11 button fix for tooltips (fixes #210)
## v1.6.5
- IE UI bug fixes
## v1.6.4
- Bug fix for undefined progress bar
## v1.6.3
- Seek back to 0 for all media on ended
- Check for HTML5 video on ended reload
- Update to docs for `showPosterOnEnd` option
## v1.6.2
- Fix for tooltip displaying when duration is not set (fixes #177)
- `showPosterOnEnd` option to show poster when HTML5 video ended (fixes #59)
- Error handler for YouTube (fixes #189)
- Initial SoundCloud support (fixes #194)
- Other minor bug fixes
## v1.6.1
- Tooltip changes for accessibility
## v1.6.0
- New, cleaner, UI: - Controls are now overlaid, maintaining the video's ratio and making sizing easier - A large play button can now be overlaid over videos - Default number of control buttons reduced - New play, pause, rewind and fast forward icons - Flexbox all the things!
- Tidied up the LESS (and SCSS) as part of the above, variables and mixins in seprate files amking customization and upgrades easier
- Toggle mute bug fix; if a player was muted previously and the user refreshed, unmuting would have meant volume was still zero (effectively muted), now the config default value is used. Not ideal but good for now
- New `iconUrl` option allowing specifying a same origin SVG sprite location. Loading this way means you don't need the AJAX sprite loading JavaScript
- `click` option renamed to `clickToPlay` to make it a bit more self explanatory. Unfortunately cross origin SVG sprites is not supported in any browser yet :-(
- `hideControls` is now a global option, rather than being exclusive to fullscreen. Controls are now hidden after 2 seconds of no mouse movement. Controls are always shown when media is paused or stopped. This is defaulted to true.
- `sass` folder in `src` renamed from to `scss`
## v1.5.21
- Bug fix for embeds: `play` not being defined (fixes #185 and #186)
## v1.5.20
- Bug fix for autoplay option
## v1.5.19
- Fix for accessing `embed` property after `ready` event fired
## v1.5.18
- Added 'ready' event for initial setup complete or source change occurs
- Fixed SASS stylesheet references to transparentize
- Added default font stack to controls
- Docs fixes inc controls HTML (fixes #180)
## v1.5.17
- Expose YouTube and Vimeo API (docs update required) (fixes #176)
- Auto set title based on YouTube getVideoData() title property
- Bug fix for Vimeo API change (Uncaught TypeError: Cannot read property 'value' of undefined) due to a change their end
## v1.5.16
- Cancel requests on source change (fixes #174)
## v1.5.15
- Fix for CustomEvent polyfill and related bug (see #172)
## v1.5.14
- Volume storage fix (fixes #171)
## v1.5.13
- Fix for manual caption rendering
## v1.5.12
- Added a duration option to pass the duration of the file
- Added the ability to set options per element by setting a data-plyr attribute on the target elements (this might be useful for the duration option for example)
- Fixes for Chrome and Safari caption rendering, they now use the default texttrack and cuechange events
- Firefox bug fix for event not defined
## v1.5.11
- iOS embed bug fixes (fixes #166)
- Hide IE/Edge <input type='range'> tooltip (since we have a styled one) (fixes #160)
- SASS bug fix for default values (fixes #158)
## v1.5.9 + v1.5.10
- NPM bug fixes
## v1.5.8
- Fix for touch device seek tooltip
- Seek improvements
## v1.5.7
- Fix for control tooltips always showing
## v1.5.6
- Seek tooltip (option for tooltips changed, please check docs)
- SASS compile error fixes (fixes #148)
- Fullscreen fixes for controls not always hiding/showing (fixes #149)
- Screen reader icon fixes (title was being read twice due to the tooltip/hidden label)
## v1.5.5
- Fixed controls.md example
- Bug fix for docs error page
- Bug fix for controls tooltips
## v1.5.4
- Minor bug fix for clicking video to play/pause after source change
## v1.5.3
- Minor bug fix for occasional display of 0:00 as the media duration
## v1.5.2
- `handlers` option renamed to `listeners`
- Added event listeners for all types to the plyr container (playback, fullscreen, captions etc - see docs)
- Removed onSetup config option (use the 'setup' event instead, plyr element is event.plyr)
- Style bug fixes
- Vimeo seek bug fix (requires whole seconds when seeking)
- Fix for fullscreen player (using class hook, not browser fullscreen)
## v1.5.1
- Fix for event listeners being duplicated on source change
# v1.5.0
- Vimeo support (fixes #8)
- New options for initialization (you can now pass a selector, HTMLElement or NodeList) (fixes #118)
- Switched to BEM methodology (you will need to change CSS and probably HTML)
- Decoupled CSS and JS hooks (fixes #129)
- Custom controls container (fixes #98)
- Fix for private/incognito mode local storage bug (fixes #131)
- UMD module setup (fixes #121)
- Specify iframe title for Vimeo and YouTube (fixes #124)
- Better handling of mission controls (fixes #132)
- Retain classname on source change (fixes #120)
- Increased thumb size on seek (partially fixes #130)
- Passing no argument to `source` api method, now returns current source (by @gurupras)
- Ability to add custom handlers to controls prior to Plyr bindings (by @gurupras)
- Keyboard navigation improvements (focus on seek, focus trap in fullscreen) (fixes #135)
## v1.3.5
- Fixed bug with API use on basic supported browsers
## v1.3.4
- Code cleanup by @calvintam236
## v1.3.3
- Removed captions being read by screen readers
## v1.3.2
- Voiceover fix for captions
## v1.3.1
- ARIA improvements for captions being read
## v1.3.0
- Internationalization support (i18n) using default controls (required markup changes to controls)
- ARIA enhancements for controls (required markup changes to controls)
- Captions legibility improvements
- YouTube bug fixes
## v1.2.6
- SASS updates and fixes (cheers @ChristianPV)
## v1.2.5
- Fix for YouTube quality (let them decide quality)
## v1.2.4
- Fix for omitted kind attribute on <track> (fixes #88)
## v1.2.3
- Fix for YouTube on iPhone or unsupported browsers (fallback to YouTube native)
- Docs tidy up
- Fullscreen for Safari fix (fixes #96)
## v1.2.2
- Fix for :focus keyboard vs mouse (fixes #61)
- Fix for caption positioning in full screen (fixes #92)
## v1.2.1
- Tooltip bug fix
# v1.2.0
- Added YouTube support
## v1.1.13
- Added icon prefix option for when using default controls
## v1.1.13
- Logic tweaks for hiding controls in fullscreen
## v1.1.12
- Bug fix for Chrome Canary
## v1.1.11
- Bug fix
## v1.1.10
- Bug fix
## v1.1.9
- Bug fix for 1.1.8
## v1.1.8
- setVolume API method improvements (fixes #83)
## v1.1.7
- Restore classname on destroy()
## v1.1.6
- New API methods (fixes #77), Fix for non strict mode (fixes #78)
## v1.1.5
- Fix for incorrect `isFullscreen()` return value in Mozilla (fixes #38)
## v1.1.4
- Minor bug fixes
## v1.1.3
- Fixes for random id used in controls with multiple instances and one call to setup
- Audio player UI improvements
## v1.1.2
- Added an onSetup callback option
- Added fullscreen API methods `toggleFullscreen()` (must be user iniated), and `isFullscreen()`
## v1.1.1
- Fix for unsupported browser handling
- Fix for config.controls having no effect
## v1.1.0
- Added config option to set which controls are shown (if using the default controls html) and better handling of missing controls
## v1.0.31
- Display duration on `metadataloaded`
## v1.0.30
- Fixed bug with media longer than 60 minutes (fixes #69)
## v1.0.29
- Added option to hide controls on fullscreen (default `true`) while palying, after 1s. Pause, mouse hover on progress, or focus on a child control re-shows the controls. On touch a tap of the video (which plays/pauses the video by default) is required. (fixes #47)
- Fixed a bug with caption toggle in 1.0.28
## v1.0.28
- Added API support for browsers that don't have full plyr support (pretty much <=IE9 and `<video>` on iPhone/iPod)
## v1.0.27
- Keyboard accessibility improvements (fixes #66)
## v1.0.26
- Fixes for SASS (cheers @brunowego)
- Indentation reset to 4 spaces
## v1.0.25
- Fixes for iOS volume controls (hidden)
- Classnames for left/right controls changed
## v1.0.24
- Added tooltip option to display labels as tooltips (fixes #50)
## v1.0.23
- Handling loading states in the UI (fixes #36)
## v1.0.22
- Added support() API method for checking mimetype support
- Added source() API method for setting media source(s) (fixes #44)
- Added poster() API method for setting poster source
- Refactored captions logic for manual captions
## v1.0.21
- Added an <input type="range"> for seeking to improve experience (and support dragging) (fixes #40, #42)
- Icons for restart and captions improved (and some IDs changed) (fixes #49)
## v1.0.20
- Default controls included (Fixes #45)
- Volume changes on `input` as well as `change` (fixes #43)
- Fix for undefined Play text
- License changed to MIT
## v1.0.19
- Fixed firefox fullscreen issue (fixes #38)
## v1.0.18
- Added CDN references
## v1.0.17
- SASS support added (thanks to @brunowego)
- Docs completely separated to avoid any confusion
- New gulp tasks (will add more documentation for this)
## v1.0.16
- Aria label is now dynamic
## v1.0.15
- Fix for seek time display in controls
- More documentation for controls html
## v1.0.14
- Minor change for bootstrap compatibility
## v1.0.13
- Minor tweaks
## v1.0.12
- Handle native events (issue #34)
## v1.0.11
- Bug fixes for fullscreen mode
## v1.0.10
- Bower includes src files now
- Folder re-arrangement
## v1.0.9
- Added buffer progress bar
- Fixed Safari 8 caption track (it needs to be removed from the DOM like in Safari 7)
- Added validation (it works or it doesn't basically) of the `html` option passed
## v1.0.8
- Bug fix
## v1.0.7
- Storing user selected volume in local storage
## v1.0.6
- Fullscreen fallback for older browsers to use "full window"
## v1.0.5
- More minor bug fixes and improvements
## v1.0.4
- Fixed caption legibility issues
## v1.0.3
- Minor bug fixes
## v1.0.2
- Added OGG to <audio> example for Firefox
- Fixed IE11 fullscreen issues
## v1.0.1
- Bug fixes for IE (as per usual)
- Added CSS hooks for media type
- Return instances of Plyr to the element
## v1.0.0
- Initial release

151
controls.md Normal file
View File

@ -0,0 +1,151 @@
# Controls
This is the markup that is rendered for the Plyr controls. You can use the default controls or provide a customized version of markup based on your needs. You can pass the following to the `controls` option:
- `Array` of options (this builds the default controls based on your choices)
- `String` containing the desired HTML
- `Function` that will be executed and should return one of the above
## Using default controls
If you want to use the standard controls as they are, you don't need to pass any options. If you want to turn on off controls, here's the full list:
```javascript
controls: [
'play-large', // The large play button in the center
'restart', // Restart playback
'rewind', // Rewind by the seek time (default 10 seconds)
'play', // Play/pause playback
'fast-forward', // Fast forward by the seek time (default 10 seconds)
'progress', // The progress bar and scrubber for playback and buffering
'current-time', // The current time of playback
'duration', // The full duration of the media
'mute', // Toggle mute
'volume', // Volume control
'captions', // Toggle captions
'settings', // Settings menu
'pip', // Picture-in-picture (currently Safari only)
'airplay', // Airplay (currently Safari only)
'fullscreen', // Toggle fullscreen
];
```
### Internationalization using default controls
You can provide an `i18n` object as one of your options when initialising the plugin which we be used when rendering the controls.
#### Example
```javascript
i18n: {
restart: 'Restart',
rewind: 'Rewind {seektime} secs',
play: 'Play',
pause: 'Pause',
fastForward: 'Forward {seektime} secs',
seek: 'Seek',
played: 'Played',
buffered: 'Buffered',
currentTime: 'Current time',
duration: 'Duration',
volume: 'Volume',
mute: 'Mute',
unmute: 'Unmute',
enableCaptions: 'Enable captions',
disableCaptions: 'Disable captions',
enterFullscreen: 'Enter fullscreen',
exitFullscreen: 'Exit fullscreen',
frameTitle: 'Player for {title}',
captions: 'Captions',
settings: 'Settings',
speed: 'Speed',
normal: 'Normal',
quality: 'Quality',
loop: 'Loop',
start: 'Start',
end: 'End',
all: 'All',
reset: 'Reset',
disabled: 'Disabled',
advertisement: 'Ad',
}
```
Note: `{seektime}` will be replaced with your configured seek time or the default. For example "Forward {seektime} secs" would render as "Forward 10 secs".
## Using custom HTML
You can specify the HTML as a `String` or your `Function` return for the controls using the `controls` option.
The classes and data attributes used in your template should match the `selectors` option if you change any.
You need to add several placeholders to your HTML template that are replaced when rendering:
- `{id}` - the dynamically generated ID for the player (for form controls)
- `{seektime}` - the seek time specified in options for fast forward and rewind
- `{title}` - the title of your media, if specified
### Limitations
- Currently the settings menus are not supported with custom controls HTML
- AirPlay and PiP buttons can be added but you will have to manage feature detection
### Example
Here's an example of custom controls markup (this is just all default controls shown).
```javascript
const controls = `
<div class="plyr__controls">
<button type="button" class="plyr__control" data-plyr="restart">
<svg role="presentation"><use xlink:href="#plyr-restart"></use></svg>
<span class="plyr__tooltip" role="tooltip">Restart</span>
</button>
<button type="button" class="plyr__control" data-plyr="rewind">
<svg role="presentation"><use xlink:href="#plyr-rewind"></use></svg>
<span class="plyr__tooltip" role="tooltip">Rewind {seektime} secs</span>
</button>
<button type="button" class="plyr__control" aria-label="Play, {title}" data-plyr="play">
<svg class="icon--pressed" role="presentation"><use xlink:href="#plyr-pause"></use></svg>
<svg class="icon--not-pressed" role="presentation"><use xlink:href="#plyr-play"></use></svg>
<span class="label--pressed plyr__tooltip" role="tooltip">Pause</span>
<span class="label--not-pressed plyr__tooltip" role="tooltip">Play</span>
</button>
<button type="button" class="plyr__control" data-plyr="fast-forward">
<svg role="presentation"><use xlink:href="#plyr-fast-forward"></use></svg>
<span class="plyr__tooltip" role="tooltip">Forward {seektime} secs</span>
</button>
<div class="plyr__progress">
<input data-plyr="seek" type="range" min="0" max="100" step="0.01" value="0" aria-label="Seek">
<progress class="plyr__progress__buffer" min="0" max="100" value="0">% buffered</progress>
<span role="tooltip" class="plyr__tooltip">00:00</span>
</div>
<div class="plyr__time plyr__time--current" aria-label="Current time">00:00</div>
<div class="plyr__time plyr__time--duration" aria-label="Duration">00:00</div>
<button type="button" class="plyr__control" aria-label="Mute" data-plyr="mute">
<svg class="icon--pressed" role="presentation"><use xlink:href="#plyr-muted"></use></svg>
<svg class="icon--not-pressed" role="presentation"><use xlink:href="#plyr-volume"></use></svg>
<span class="label--pressed plyr__tooltip" role="tooltip">Unmute</span>
<span class="label--not-pressed plyr__tooltip" role="tooltip">Mute</span>
</button>
<div class="plyr__volume">
<input data-plyr="volume" type="range" min="0" max="1" step="0.05" value="1" autocomplete="off" aria-label="Volume">
</div>
<button type="button" class="plyr__control" data-plyr="captions">
<svg class="icon--pressed" role="presentation"><use xlink:href="#plyr-captions-on"></use></svg>
<svg class="icon--not-pressed" role="presentation"><use xlink:href="#plyr-captions-off"></use></svg>
<span class="label--pressed plyr__tooltip" role="tooltip">Disable captions</span>
<span class="label--not-pressed plyr__tooltip" role="tooltip">Enable captions</span>
</button>
<button type="button" class="plyr__control" data-plyr="fullscreen">
<svg class="icon--pressed" role="presentation"><use xlink:href="#plyr-exit-fullscreen"></use></svg>
<svg class="icon--not-pressed" role="presentation"><use xlink:href="#plyr-enter-fullscreen"></use></svg>
<span class="label--pressed plyr__tooltip" role="tooltip">Exit fullscreen</span>
<span class="label--not-pressed plyr__tooltip" role="tooltip">Enter fullscreen</span>
</button>
</div>
`;
// Setup the player
const player = new Plyr('#player', { controls });
```

1
demo/dist/demo.css vendored Normal file

File diff suppressed because one or more lines are too long

4396
demo/dist/demo.js vendored Normal file

File diff suppressed because it is too large Load Diff

1
demo/dist/demo.js.map vendored Normal file

File diff suppressed because one or more lines are too long

2
demo/dist/demo.min.js vendored Normal file

File diff suppressed because one or more lines are too long

1
demo/dist/demo.min.js.map vendored Normal file

File diff suppressed because one or more lines are too long

1
demo/dist/error.css vendored Normal file

File diff suppressed because one or more lines are too long

31
demo/error.html Normal file
View File

@ -0,0 +1,31 @@
<!doctype html>
<html lang="en" class="error">
<head>
<meta charset="utf-8" />
<title>Doh. Looks like something went wrong.</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Icons -->
<link rel="icon" href="https://cdn.plyr.io/static/icons/favicon.ico">
<link rel="icon" type="image/png" href="https://cdn.plyr.io/static/icons/32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="https://cdn.plyr.io/static/icons/16x16.png" sizes="16x16">
<link rel="apple-touch-icon" sizes="180x180" href="https://cdn.plyr.io/static/icons/180x180.png">
<!-- Docs styles -->
<link rel="stylesheet" href="dist/error.css?v=2">
<!-- Preload -->
<link rel="preload" as="font" crossorigin type="font/woff2" href="https://cdn.plyr.io/static/fonts/gordita-medium.woff2">
<link rel="preload" as="font" crossorigin type="font/woff2" href="https://cdn.plyr.io/static/fonts/gordita-bold.woff2">
</head>
<body>
<main>
<h1>Doh.</h1>
<p>Looks like something went wrong.</p>
<a href="javascript:history.back()" class="button">Go back</a>
</main>
</body>
</html>

190
demo/index.html Normal file
View File

@ -0,0 +1,190 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>Plyr - A simple, customizable HTML5 Video, Audio, YouTube and Vimeo player</title>
<meta name="description" property="og:description" content="A simple HTML5 media player with custom controls and WebVTT captions.">
<meta name="author" content="Sam Potts">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Icons -->
<link rel="icon" href="https://cdn.plyr.io/static/icons/favicon.ico">
<link rel="icon" type="image/png" href="https://cdn.plyr.io/static/icons/32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="https://cdn.plyr.io/static/icons/16x16.png" sizes="16x16">
<link rel="apple-touch-icon" sizes="180x180" href="https://cdn.plyr.io/static/icons/180x180.png">
<!-- Opengraph -->
<meta property="og:title" content="Plyr - A simple, customizable HTML5 Video, Audio, YouTube and Vimeo player">
<meta property="og:site_name" content="Plyr">
<meta property="og:url" content="https://plyr.io">
<meta property="og:image" content="https://cdn.plyr.io/static/icons/1200x630.png">
<!-- Twitter -->
<meta name="twitter:card" content="summary">
<meta name="twitter:site" content="@sam_potts">
<meta name="twitter:creator" content="@sam_potts">
<meta name="twitter:card" content="summary_large_image">
<!-- Docs styles -->
<link rel="stylesheet" href="dist/demo.css?v=2">
<!-- Preload -->
<link rel="preload" as="font" crossorigin type="font/woff2" href="https://cdn.plyr.io/static/fonts/gordita-medium.woff2">
<link rel="preload" as="font" crossorigin type="font/woff2" href="https://cdn.plyr.io/static/fonts/gordita-bold.woff2">
</head>
<body>
<div class="grid">
<header>
<h1>Plyr</h1>
<p>A simple, accessible and customisable media player for
<button type="button" class="faux-link" data-source="video">
<svg class="icon">
<title>HTML5</title>
<path d="M14.738.326C14.548.118 14.28 0 14 0H2c-.28 0-.55.118-.738.326S.98.81 1.004 1.09l1 11c.03.317.208.603.48.767l5 3c.16.095.338.143.516.143s.356-.048.515-.143l5-3c.273-.164.452-.45.48-.767l1-11c.026-.28-.067-.557-.257-.764zM12 4H6v2h6v5.72l-4 1.334-4-1.333V9h2v1.28l2 .666 2-.667V8H4V2h8v2z"></path>
</svg>Video</button>,
<button type="button" class="faux-link" data-source="audio">
<svg class="icon">
<title>HTML5</title>
<path d="M14.738.326C14.548.118 14.28 0 14 0H2c-.28 0-.55.118-.738.326S.98.81 1.004 1.09l1 11c.03.317.208.603.48.767l5 3c.16.095.338.143.516.143s.356-.048.515-.143l5-3c.273-.164.452-.45.48-.767l1-11c.026-.28-.067-.557-.257-.764zM12 4H6v2h6v5.72l-4 1.334-4-1.333V9h2v1.28l2 .666 2-.667V8H4V2h8v2z"></path>
</svg>Audio</button>,
<button type="button" class="faux-link" data-source="youtube">
<svg class="icon" role="presentation">
<title>YouTube</title>
<path d="M15.8,4.8c-0.2-1.3-0.8-2.2-2.2-2.4C11.4,2,8,2,8,2S4.6,2,2.4,2.4C1,2.6,0.3,3.5,0.2,4.8C0,6.1,0,8,0,8
s0,1.9,0.2,3.2c0.2,1.3,0.8,2.2,2.2,2.4C4.6,14,8,14,8,14s3.4,0,5.6-0.4c1.4-0.3,2-1.1,2.2-2.4C16,9.9,16,8,16,8S16,6.1,15.8,4.8z
M6,11V5l5,3L6,11z"></path>
</svg>YouTube</button> and
<button type="button" class="faux-link" data-source="vimeo">
<svg class="icon" role="presentation">
<title>Vimeo</title>
<path d="M16,4.3c-0.1,1.6-1.2,3.7-3.3,6.4c-2.2,2.8-4,4.2-5.5,4.2c-0.9,0-1.7-0.9-2.4-2.6C4,9.9,3.4,5,2,5
C1.9,5,1.5,5.3,0.8,5.8L0,4.8c0.8-0.7,3.5-3.4,4.7-3.5C5.9,1.2,6.7,2,7,3.8c0.3,2,0.8,6.1,1.8,6.1c0.9,0,2.5-3.4,2.6-4
c0.1-0.9-0.3-1.9-2.3-1.1c0.8-2.6,2.3-3.8,4.5-3.8C15.3,1.1,16.1,2.2,16,4.3z"></path>
</svg>Vimeo</button>
</p>
<p>Premium video monitization from
<a href="https://vi.ai/publisher-video-monetization/?aid=plyrio" target="_blank" class="no-border">
<img src="https://cdn.plyr.io/static/vi-logo-24x24.svg" alt="ai.vi">
<span class="sr-only">ai.vi</span>
</a>
</p>
<div class="call-to-action">
<span class="button--with-count">
<a href="https://github.com/sampotts/plyr" target="_blank" class="button" data-shr-network="github">
<svg class="icon" role="presentation">
<title>GitHub</title>
<path d="M8,0.2c-4.4,0-8,3.6-8,8c0,3.5,2.3,6.5,5.5,7.6
C5.9,15.9,6,15.6,6,15.4c0-0.2,0-0.7,0-1.4C3.8,14.5,3.3,13,3.3,13c-0.4-0.9-0.9-1.2-0.9-1.2c-0.7-0.5,0.1-0.5,0.1-0.5
c0.8,0.1,1.2,0.8,1.2,0.8C4.4,13.4,5.6,13,6,12.8c0.1-0.5,0.3-0.9,0.5-1.1c-1.8-0.2-3.6-0.9-3.6-4c0-0.9,0.3-1.6,0.8-2.1
c-0.1-0.2-0.4-1,0.1-2.1c0,0,0.7-0.2,2.2,0.8c0.6-0.2,1.3-0.3,2-0.3c0.7,0,1.4,0.1,2,0.3c1.5-1,2.2-0.8,2.2-0.8
c0.4,1.1,0.2,1.9,0.1,2.1c0.5,0.6,0.8,1.3,0.8,2.1c0,3.1-1.9,3.7-3.7,3.9C9.7,12,10,12.5,10,13.2c0,1.1,0,1.9,0,2.2
c0,0.2,0.1,0.5,0.6,0.4c3.2-1.1,5.5-4.1,5.5-7.6C16,3.8,12.4,0.2,8,0.2z"></path>
</svg>
Download on GitHub
</a>
</span>
</div>
</header>
<main>
<video controls crossorigin playsinline poster="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-HD.jpg" id="player">
<!-- Video files -->
<source src="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-576p.mp4" type="video/mp4" size="576">
<source src="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-720p.mp4" type="video/mp4" size="720">
<source src="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-1080p.mp4" type="video/mp4" size="1080">
<!-- <source src="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-1440p.mp4" type="video/mp4" size="1440"> -->
<!-- Caption files -->
<track kind="captions" label="English" srclang="en" src="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-HD.en.vtt"
default>
<track kind="captions" label="Français" srclang="fr" src="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-HD.fr.vtt">
<!-- Fallback for browsers that don't support the <video> element -->
<a href="https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-576p.mp4" download>Download</a>
</video>
<ul>
<li class="plyr__cite plyr__cite--video" hidden>
<small>
<svg class="icon">
<title>HTML5</title>
<path d="M14.738.326C14.548.118 14.28 0 14 0H2c-.28 0-.55.118-.738.326S.98.81 1.004 1.09l1 11c.03.317.208.603.48.767l5 3c.16.095.338.143.516.143s.356-.048.515-.143l5-3c.273-.164.452-.45.48-.767l1-11c.026-.28-.067-.557-.257-.764zM12 4H6v2h6v5.72l-4 1.334-4-1.333V9h2v1.28l2 .666 2-.667V8H4V2h8v2z"></path>
</svg>
<a href="https://itunes.apple.com/au/movie/view-from-a-blue-moon/id1041586323" target="_blank">View From A Blue Moon</a> &copy; Brainfarm
</small>
</li>
<li class="plyr__cite plyr__cite--audio" hidden>
<small>
<svg class="icon" title="HTML5">
<title>HTML5</title>
<path d="M14.738.326C14.548.118 14.28 0 14 0H2c-.28 0-.55.118-.738.326S.98.81 1.004 1.09l1 11c.03.317.208.603.48.767l5 3c.16.095.338.143.516.143s.356-.048.515-.143l5-3c.273-.164.452-.45.48-.767l1-11c.026-.28-.067-.557-.257-.764zM12 4H6v2h6v5.72l-4 1.334-4-1.333V9h2v1.28l2 .666 2-.667V8H4V2h8v2z"></path>
</svg>
<a href="http://www.kishibashi.com/" target="_blank">Kishi Bashi &ndash; &ldquo;It All Began With A Burst&rdquo;</a> &copy; Kishi Bashi
</small>
</li>
<li class="plyr__cite plyr__cite--youtube" hidden>
<small>
<a href="https://www.youtube.com/watch?v=bTqVqk7FSmY" target="_blank">View From A Blue Moon</a> on&nbsp;
<span class="color--youtube">
<svg class="icon" role="presentation">
<title>YouTube</title>
<path d="M15.8,4.8c-0.2-1.3-0.8-2.2-2.2-2.4C11.4,2,8,2,8,2S4.6,2,2.4,2.4C1,2.6,0.3,3.5,0.2,4.8C0,6.1,0,8,0,8
s0,1.9,0.2,3.2c0.2,1.3,0.8,2.2,2.2,2.4C4.6,14,8,14,8,14s3.4,0,5.6-0.4c1.4-0.3,2-1.1,2.2-2.4C16,9.9,16,8,16,8S16,6.1,15.8,4.8z
M6,11V5l5,3L6,11z"></path>
</svg>YouTube
</span>
</small>
</li>
<li class="plyr__cite plyr__cite--vimeo" hidden>
<small>
<a href="https://vimeo.com/76979871" target="_blank">The New Vimeo Player</a> on&nbsp;
<span class="color--vimeo">
<svg class="icon" role="presentation">
<title>Vimeo</title>
<path d="M16,4.3c-0.1,1.6-1.2,3.7-3.3,6.4c-2.2,2.8-4,4.2-5.5,4.2c-0.9,0-1.7-0.9-2.4-2.6C4,9.9,3.4,5,2,5
C1.9,5,1.5,5.3,0.8,5.8L0,4.8c0.8-0.7,3.5-3.4,4.7-3.5C5.9,1.2,6.7,2,7,3.8c0.3,2,0.8,6.1,1.8,6.1c0.9,0,2.5-3.4,2.6-4
c0.1-0.9-0.3-1.9-2.3-1.1c0.8-2.6,2.3-3.8,4.5-3.8C15.3,1.1,16.1,2.2,16,4.3z"></path>
</svg>Vimeo
</span>
</small>
</li>
</ul>
</main>
</div>
<aside>
<svg class="icon">
<title>Twitter</title>
<path d="M16,3c-0.6,0.3-1.2,0.4-1.9,0.5c0.7-0.4,1.2-1,1.4-1.8c-0.6,0.4-1.3,0.6-2.1,0.8c-0.6-0.6-1.5-1-2.4-1
C9.3,1.5,7.8,3,7.8,4.8c0,0.3,0,0.5,0.1,0.7C5.2,5.4,2.7,4.1,1.1,2.1c-0.3,0.5-0.4,1-0.4,1.7c0,1.1,0.6,2.1,1.5,2.7
c-0.5,0-1-0.2-1.5-0.4c0,0,0,0,0,0c0,1.6,1.1,2.9,2.6,3.2C3,9.4,2.7,9.4,2.4,9.4c-0.2,0-0.4,0-0.6-0.1c0.4,1.3,1.6,2.3,3.1,2.3
c-1.1,0.9-2.5,1.4-4.1,1.4c-0.3,0-0.5,0-0.8,0c1.5,0.9,3.2,1.5,5,1.5c6,0,9.3-5,9.3-9.3c0-0.1,0-0.3,0-0.4C15,4.3,15.6,3.7,16,3z"></path>
</svg>
<p>If you think Plyr's good,
<a href="https://twitter.com/intent/tweet?text=A+simple+HTML5+media+player+with+custom+controls+and+WebVTT+captions.&amp;url=http%3A%2F%2Fplyr.io&amp;via=Sam_Potts"
target="_blank" data-shr-network="twitter">tweet it</a>
</p>
</aside>
<!-- Polyfills -->
<script src="https://cdn.polyfill.io/v2/polyfill.min.js?features=es6,Array.prototype.includes,CustomEvent,Object.entries,Object.values,URL"
crossorigin="anonymous"></script>
<!-- Plyr core script -->
<script src="../dist/plyr.js" crossorigin="anonymous"></script>
<!-- Sharing libary (https://shr.one) -->
<script src="https://cdn.shr.one/1.0.1/shr.js" crossorigin="anonymous"></script>
<!-- Rangetouch to fix <input type="range"> on touch devices (see https://rangetouch.com) -->
<script src="https://cdn.rangetouch.com/1.0.1/rangetouch.js" async crossorigin="anonymous"></script>
<!-- Docs script -->
<script src="dist/demo.js" crossorigin="anonymous"></script>
</body>
</html>

View File

@ -0,0 +1,29 @@
WEBVTT FILE
1
00:00:09.500 --> 00:00:12.000
The ocean floor rises 5 miles to the shores
2
00:00:12.001 --> 00:00:16.500
of what people call, the seven mile miracle
3
00:00:25.500 --> 00:00:28.000
What would it be like to be born on this island?
4
00:00:32.500 --> 00:00:34.500
To grow up on these shores
5
00:00:37.500 --> 00:00:40.000
To witness this water, every day
6
00:00:43.500 --> 00:00:46.000
You're about to meet someone, who did
7
00:02:45.500 --> 00:02:49.000
This is a film about John John Florence

View File

@ -0,0 +1,29 @@
WEBVTT FILE
1
00:00:09.500 --> 00:00:12.000
Le fond de l'océan monte 5 miles des rives
2
00:00:12.001 --> 00:00:16.500
de ce que les gens appellent le miracle de sept mile
3
00:00:25.500 --> 00:00:28.000
Que serait-il d'être né sur cette île?
4
00:00:32.500 --> 00:00:34.500
Pour grandir sur ces rivages
5
00:00:37.500 --> 00:00:40.000
Pour assister à cette eau, tous les jours
6
00:00:43.500 --> 00:00:46.000
Vous êtes sur le point de rencontrer quelqu'un, qui ne
7
00:02:45.500 --> 00:02:49.000
Ceci est un film sur John John Florence

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 KiB

335
demo/src/js/demo.js Normal file
View File

@ -0,0 +1,335 @@
// ==========================================================================
// Plyr.io demo
// This code is purely for the https://plyr.io website
// Please see readme.md in the root or github.com/sampotts/plyr
// ==========================================================================
import Raven from 'raven-js';
(() => {
const isLive = window.location.host === 'plyr.io';
// Raven / Sentry
// For demo site (https://plyr.io) only
if (isLive) {
Raven.config('https://d4ad9866ad834437a4754e23937071e4@sentry.io/305555').install();
}
document.addEventListener('DOMContentLoaded', () => {
Raven.context(() => {
if (window.shr) {
window.shr.setup({
count: {
classname: 'button__count',
},
});
}
// Setup tab focus
const tabClassName = 'tab-focus';
// Remove class on blur
document.addEventListener('focusout', event => {
event.target.classList.remove(tabClassName);
});
// Add classname to tabbed elements
document.addEventListener('keydown', event => {
if (event.keyCode !== 9) {
return;
}
// Delay the adding of classname until the focus has changed
// This event fires before the focusin event
setTimeout(() => {
document.activeElement.classList.add(tabClassName);
}, 0);
});
// Setup the player
const player = new Plyr('#player', {
debug: true,
title: 'View From A Blue Moon',
iconUrl: '../dist/plyr.svg',
keyboard: {
global: true,
},
tooltips: {
controls: true,
},
/* controls: [
'play-large',
'restart',
'rewind',
'play',
'fast-forward',
'progress',
'current-time',
'duration',
'mute',
'volume',
'captions',
'settings',
'pip',
'airplay',
'fullscreen',
], */
/* i18n: {
restart: '重新開始',
rewind: '快退{seektime}秒',
play: '播放',
pause: '暫停',
fastForward: '快進{seektime}秒',
seek: '尋求',
played: '發揮',
buffered: '緩衝的',
currentTime: '當前時間戳',
duration: '長短',
volume: '音量',
mute: '靜音',
unmute: '取消靜音',
enableCaptions: '開啟字幕',
disableCaptions: '關閉字幕',
enterFullscreen: '進入全螢幕',
exitFullscreen: '退出全螢幕',
frameTitle: '球員為{title}',
captions: '字幕',
settings: '設定',
speed: '速度',
normal: '正常',
quality: '質量',
loop: '循環',
start: 'Start',
end: 'End',
all: 'All',
reset: '重啟',
disabled: '殘',
enabled: '啟用',
advertisement: '廣告',
}, */
captions: {
active: true,
},
keys: {
google: 'AIzaSyDrNwtN3nLH_8rjCmu5Wq3ZCm4MNAVdc0c',
},
ads: {
enabled: true,
publisherId: '918848828995742',
},
});
// Expose for tinkering in the console
window.player = player;
// Setup type toggle
const buttons = document.querySelectorAll('[data-source]');
const types = {
video: 'video',
audio: 'audio',
youtube: 'youtube',
vimeo: 'vimeo',
};
let currentType = window.location.hash.replace('#', '');
const historySupport = window.history && window.history.pushState;
// Toggle class on an element
function toggleClass(element, className, state) {
if (element) {
element.classList[state ? 'add' : 'remove'](className);
}
}
// Set a new source
function newSource(type, init) {
// Bail if new type isn't known, it's the current type, or current type is empty (video is default) and new type is video
if (
!(type in types) ||
(!init && type === currentType) ||
(!currentType.length && type === types.video)
) {
return;
}
switch (type) {
case types.video:
player.source = {
type: 'video',
title: 'View From A Blue Moon',
sources: [
{
src: 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-576p.mp4',
type: 'video/mp4',
size: 576,
},
{
src: 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-720p.mp4',
type: 'video/mp4',
size: 720,
},
{
src: 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-1080p.mp4',
type: 'video/mp4',
size: 1080,
},
{
src: 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-1440p.mp4',
type: 'video/mp4',
size: 1440,
},
],
poster: 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-HD.jpg',
tracks: [
{
kind: 'captions',
label: 'English',
srclang: 'en',
src: 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-HD.en.vtt',
default: true,
},
{
kind: 'captions',
label: 'French',
srclang: 'fr',
src: 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-HD.fr.vtt',
},
],
};
break;
case types.audio:
player.source = {
type: 'audio',
title: 'Kishi Bashi &ndash; &ldquo;It All Began With A Burst&rdquo;',
sources: [
{
src: 'https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.mp3',
type: 'audio/mp3',
},
{
src: 'https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.ogg',
type: 'audio/ogg',
},
],
};
break;
case types.youtube:
player.source = {
type: 'video',
sources: [
{
src: 'https://youtube.com/watch?v=bTqVqk7FSmY',
provider: 'youtube',
},
],
};
break;
case types.vimeo:
player.source = {
type: 'video',
sources: [
{
src: 'https://vimeo.com/76979871',
provider: 'vimeo',
},
],
};
break;
default:
break;
}
// Set the current type for next time
currentType = type;
// Remove active classes
Array.from(buttons).forEach(button => toggleClass(button.parentElement, 'active', false));
// Set active on parent
toggleClass(document.querySelector(`[data-source="${type}"]`), 'active', true);
// Show cite
Array.from(document.querySelectorAll('.plyr__cite')).forEach(cite => {
cite.setAttribute('hidden', '');
});
document.querySelector(`.plyr__cite--${type}`).removeAttribute('hidden');
}
// Bind to each button
Array.from(buttons).forEach(button => {
button.addEventListener('click', () => {
const type = button.getAttribute('data-source');
newSource(type);
if (historySupport) {
window.history.pushState({ type }, '', `#${type}`);
}
});
});
// List for backwards/forwards
window.addEventListener('popstate', event => {
if (event.state && 'type' in event.state) {
newSource(event.state.type);
}
});
// On load
if (historySupport) {
const video = !currentType.length;
// If there's no current type set, assume video
if (video) {
currentType = types.video;
}
// Replace current history state
if (currentType in types) {
window.history.replaceState(
{
type: currentType,
},
'',
video ? '' : `#${currentType}`,
);
}
// If it's not video, load the source
if (currentType !== types.video) {
newSource(currentType, true);
}
}
});
});
// Google analytics
// For demo site (https://plyr.io) only
/* eslint-disable */
if (isLive) {
(function(i, s, o, g, r, a, m) {
i.GoogleAnalyticsObject = r;
i[r] =
i[r] ||
function() {
(i[r].q = i[r].q || []).push(arguments);
};
i[r].l = 1 * new Date();
a = s.createElement(o);
m = s.getElementsByTagName(o)[0];
a.async = 1;
a.src = g;
m.parentNode.insertBefore(a, m);
})(window, document, 'script', 'https://www.google-analytics.com/analytics.js', 'ga');
window.ga('create', 'UA-40881672-11', 'auto');
window.ga('send', 'pageview');
}
/* eslint-enable */
})();

View File

@ -0,0 +1,46 @@
// ==========================================================================
// Plyr.io Demo Page
// ==========================================================================
@charset 'UTF-8';
// Settings
@import '../settings/breakpoints';
@import '../settings/colors';
@import '../settings/cosmetic';
@import '../settings/icons';
@import '../settings/layout';
@import '../settings/plyr';
@import '../settings/spacing';
@import '../settings/type';
// Libs
@import '../lib/fontface';
@import '../lib/animation';
@import '../lib/mixins';
@import '../lib/normalize';
@import '../lib/reset';
// Layout
@import '../layout/core';
@import '../layout/grid';
// Type
@import '../type/base';
@import '../type/headings';
// Components
@import '../components/buttons';
@import '../components/header';
@import '../components/icons';
@import '../components/links';
@import '../components/lists';
@import '../components/media';
@import '../components/navigation';
@import '../components/players';
// Plyr
@import '../../../../src/sass/plyr';
// Utils
@import '../utilities/cosmetic';
@import '../utilities/hidden';

View File

@ -0,0 +1,29 @@
// ==========================================================================
// Plyr.io Error Page
// ==========================================================================
@charset 'UTF-8';
// Settings
@import '../settings/colors';
@import '../settings/cosmetic';
@import '../settings/icons';
@import '../settings/layout';
@import '../settings/spacing';
@import '../settings/type';
// Libs
@import '../lib/fontface';
@import '../lib/mixins';
@import '../lib/normalize';
@import '../lib/reset';
// Layout
@import '../layout/error';
// Type
@import '../type/base';
@import '../type/headings';
// Components
@import '../components/buttons';
@import '../components/links';

View File

@ -0,0 +1,83 @@
// ==========================================================================
// Buttons
// ==========================================================================
// Shared
.button,
.button__count {
align-items: center;
background: $color-button-background;
border: 0;
border-radius: $border-radius-base;
box-shadow: 0 1px 1px rgba(#000, 0.1);
color: $color-button-text;
display: inline-flex;
padding: ($spacing-base * 0.75);
position: relative;
text-shadow: none;
user-select: none;
vertical-align: middle;
}
// Buttons
.button {
font-weight: $font-weight-bold;
padding-left: $spacing-base;
padding-right: $spacing-base;
transition: all 0.2s ease;
&:hover,
&:focus {
color: $gray-dark;
// Remove the underline/border
&::after {
display: none;
}
}
&:hover {
box-shadow: 0 2px 2px rgba(#000, 0.1);
transform: translateY(-1px);
}
&:focus {
outline: 0;
}
&.tab-focus {
@include tab-focus();
}
&:active {
transform: translateY(1px);
}
}
// Button group
.button--with-count {
display: inline-flex;
.button .icon {
flex-shrink: 0;
}
}
// Count bubble
.button__count {
animation: fadein 0.2s ease;
margin-left: ($spacing-base / 2);
&::before {
border: $arrow-size solid transparent;
border-left-width: 0;
border-right-color: $color-button-background;
content: '';
height: 0;
position: absolute;
right: 100%;
top: 50%;
transform: translateY(-50%);
width: 0;
}
}

View File

@ -0,0 +1,19 @@
// ==========================================================================
// Header
// ==========================================================================
header {
padding-bottom: $spacing-base;
text-align: center;
.call-to-action {
margin-top: ($spacing-base * 1.5);
}
@media only screen and (min-width: $screen-md) {
margin-right: ($spacing-base * 3);
max-width: 360px;
padding-bottom: ($spacing-base * 2);
text-align: left;
}
}

View File

@ -0,0 +1,23 @@
// ==========================================================================
// Icons
// ==========================================================================
// Base size icon styles
.icon {
fill: currentColor;
height: $icon-size;
vertical-align: -3px;
width: $icon-size;
}
// Within elements
a svg,
button svg,
label svg {
pointer-events: none;
}
a .icon,
.btn .icon {
margin-right: floor($spacing-base / 3);
}

View File

@ -0,0 +1,49 @@
// ==========================================================================
// Links
// ==========================================================================
// Make a <button> look like an <a>
button.faux-link {
@extend a; // stylelint-disable-line
@include cancel-button-styles();
}
// Links
a {
border-bottom: 1px dotted currentColor;
color: $color-link;
font-weight: $font-weight-bold;
position: relative;
text-decoration: none;
transition: all 0.2s ease;
&::after {
background: currentColor;
content: '';
height: 1px;
left: 50%;
position: absolute;
top: 100%;
transform: translateX(-50%);
transition: width 0.2s ease;
width: 0;
}
&:hover,
&:focus {
border-bottom-color: transparent;
outline: 0;
&::after {
width: 100%;
}
}
&.tab-focus {
@include tab-focus();
}
&.no-border::after {
display: none;
}
}

View File

@ -0,0 +1,11 @@
// ==========================================================================
// Lists
// ==========================================================================
// Lists
ul,
li {
list-style: none;
margin: 0;
padding: 0;
}

View File

@ -0,0 +1,10 @@
// ==========================================================================
// Basic media
// ==========================================================================
img,
video,
audio {
max-width: 100%;
vertical-align: middle;
}

View File

@ -0,0 +1,9 @@
// ==========================================================================
// Navigation
// ==========================================================================
nav {
display: flex;
justify-content: center;
margin-bottom: $spacing-base;
}

View File

@ -0,0 +1,50 @@
// ==========================================================================
// Examples
// ==========================================================================
// For non supported browsers
video {
max-width: 100%;
vertical-align: middle;
}
// Example players
.plyr {
border-radius: $border-radius-base;
box-shadow: 0 2px 5px rgba(#000, 0.2);
margin: $spacing-base auto;
&.plyr--audio {
max-width: 480px;
}
}
.plyr__video-wrapper::after {
border: 1px solid rgba(#000, 0.15);
border-radius: inherit;
bottom: 0;
content: '';
left: 0;
pointer-events: none;
position: absolute;
right: 0;
top: 0;
z-index: 3;
}
// Style full supported player
.plyr__cite {
display: none;
margin-top: $spacing-base;
.icon {
margin-right: ceil($spacing-base / 6);
}
}
.plyr--video:not(.plyr--youtube):not(.plyr--vimeo) ~ ul .plyr__cite--video,
.plyr--audio ~ ul .plyr__cite--audio,
.plyr--youtube ~ ul .plyr__cite--youtube,
.plyr--vimeo ~ ul .plyr__cite--vimeo {
display: block;
}

View File

@ -0,0 +1,64 @@
// ==========================================================================
// Core
// ==========================================================================
html,
body {
display: flex;
width: 100%;
}
html {
background: $page-background;
background-attachment: fixed;
height: 100%;
}
body {
align-items: center;
display: flex;
flex-direction: column;
min-height: 100%;
}
.grid {
flex: 1;
overflow: auto;
}
main {
margin: auto;
padding-bottom: 1px; // Collapsing margins
text-align: center;
}
aside {
align-items: center;
background: #fff;
color: $gray;
display: flex;
flex-shrink: 0;
justify-content: center;
padding: ($spacing-base * 0.75);
position: relative;
text-align: center;
text-shadow: none;
width: 100%;
.icon {
fill: $color-twitter;
margin-right: ($spacing-base / 2);
}
p {
margin: 0;
}
a {
color: $color-twitter;
&.tab-focus {
@include tab-focus($color-twitter);
}
}
}

View File

@ -0,0 +1,30 @@
// ==========================================================================
// Errors (AWS pages)
// ==========================================================================
// Error page
html.error,
.error body {
height: 100%;
}
html.error {
background: $page-background;
background-attachment: fixed;
}
.error body {
align-items: center;
display: flex;
width: 100%;
}
.error main {
padding: $spacing-base;
text-align: center;
width: 100%;
p {
@include font-size($font-size-large);
}
}

View File

@ -0,0 +1,19 @@
// ==========================================================================
// Super basic grid
// ==========================================================================
.grid {
margin: 0 auto;
padding: $spacing-base;
@media only screen and (min-width: $screen-md) {
align-items: center;
display: flex;
max-width: $container-max-width;
width: 100%;
> * {
flex: 1;
}
}
}

View File

@ -0,0 +1,13 @@
// ==========================================================================
// Animations
// ==========================================================================
// Fade
@keyframes fadein {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}

View File

@ -0,0 +1,45 @@
// ==========================================================================
// Fonts
// ==========================================================================
@font-face {
font-display: swap;
font-family: 'Gordita';
font-style: normal;
font-weight: $font-weight-light;
src: url('https://cdn.plyr.io/static/fonts/gordita-light.woff2') format('woff2'), url('https://cdn.plyr.io/static/fonts/gordita-light.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Gordita';
font-style: normal;
font-weight: $font-weight-regular;
src: url('https://cdn.plyr.io/static/fonts/gordita-regular.woff2') format('woff2'),
url('https://cdn.plyr.io/static/fonts/gordita-regular.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Gordita';
font-style: normal;
font-weight: $font-weight-medium;
src: url('https://cdn.plyr.io/static/fonts/gordita-medium.woff2') format('woff2'),
url('https://cdn.plyr.io/static/fonts/gordita-medium.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Gordita';
font-style: normal;
font-weight: $font-weight-bold;
src: url('https://cdn.plyr.io/static/fonts/gordita-bold.woff2') format('woff2'), url('https://cdn.plyr.io/static/fonts/gordita-bold.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Gordita';
font-style: normal;
font-weight: $font-weight-black;
src: url('https://cdn.plyr.io/static/fonts/gordita-black.woff2') format('woff2'), url('https://cdn.plyr.io/static/fonts/gordita-black.woff') format('woff');
}

View File

@ -0,0 +1,54 @@
// ==========================================================================
// Mixins
// ==========================================================================
// Convert a <button> into an <a>
// ---------------------------------------
@mixin cancel-button-styles() {
background: transparent;
border: 0;
border-radius: 0;
cursor: pointer;
font: inherit;
line-height: $line-height-base;
margin: 0;
padding: 0;
position: relative;
text-align: inherit;
text-shadow: inherit;
-moz-user-select: text; // stylelint-disable-line
vertical-align: baseline;
width: auto;
}
// Nicer focus styles
// ---------------------------------------
@mixin tab-focus($color: $tab-focus-default-color) {
box-shadow: 0 0 0 3px rgba($color, 0.35);
outline: 0;
}
// Use rems for font sizing
// Leave <body> at 100%/16px
// ---------------------------------------
@function calculate-rem($size) {
$rem: $size / 16;
@return #{$rem}rem;
}
@mixin font-size($size: 16) {
font-size: $size * 1px; // Fallback in px
font-size: calculate-rem($size);
}
// Font smoothing
// ---------------------------------------
@mixin font-smoothing($enabled: true) {
@if $enabled {
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
} @else {
-moz-osx-font-smoothing: auto;
-webkit-font-smoothing: subpixel-antialiased;
}
}

450
demo/src/sass/lib/normalize.scss vendored Normal file
View File

@ -0,0 +1,450 @@
/*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */
/* Document
========================================================================== */
/**
* 1. Correct the line height in all browsers.
* 2. Prevent adjustments of font size after orientation changes in
* IE on Windows Phone and in iOS.
*/
html {
line-height: 1.15; /* 1 */
-ms-text-size-adjust: 100%; /* 2 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/* Sections
========================================================================== */
/**
* Remove the margin in all browsers (opinionated).
*/
body {
margin: 0;
}
/**
* Add the correct display in IE 9-.
*/
article,
aside,
footer,
header,
nav,
section {
display: block;
}
/**
* Correct the font size and margin on `h1` elements within `section` and
* `article` contexts in Chrome, Firefox, and Safari.
*/
h1 {
font-size: 2em;
margin: 0.67em 0;
}
/* Grouping content
========================================================================== */
/**
* Add the correct display in IE 9-.
* 1. Add the correct display in IE.
*/
figcaption,
figure,
main {
/* 1 */
display: block;
}
/**
* Add the correct margin in IE 8.
*/
figure {
margin: 1em 40px;
}
/**
* 1. Add the correct box sizing in Firefox.
* 2. Show the overflow in Edge and IE.
*/
hr {
box-sizing: content-box; /* 1 */
height: 0; /* 1 */
overflow: visible; /* 2 */
}
/**
* 1. Correct the inheritance and scaling of font size in all browsers.
* 2. Correct the odd `em` font sizing in all browsers.
*/
pre {
font-family: monospace, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/* Text-level semantics
========================================================================== */
/**
* 1. Remove the gray background on active links in IE 10.
* 2. Remove gaps in links underline in iOS 8+ and Safari 8+.
*/
a {
background-color: transparent; /* 1 */
-webkit-text-decoration-skip: objects; /* 2 */
}
/**
* 1. Remove the bottom border in Chrome 57- and Firefox 39-.
* 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
*/
abbr[title] {
border-bottom: none; /* 1 */
text-decoration: underline; /* 2 */
text-decoration: underline dotted; /* 2 */
}
/**
* Prevent the duplicate application of `bolder` by the next rule in Safari 6.
*/
b,
strong {
font-weight: inherit;
}
/**
* Add the correct font weight in Chrome, Edge, and Safari.
*/
b,
strong {
font-weight: bolder;
}
/**
* 1. Correct the inheritance and scaling of font size in all browsers.
* 2. Correct the odd `em` font sizing in all browsers.
*/
code,
kbd,
samp {
font-family: monospace, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/**
* Add the correct font style in Android 4.3-.
*/
dfn {
font-style: italic;
}
/**
* Add the correct background and color in IE 9-.
*/
mark {
background-color: #ff0;
color: #000;
}
/**
* Add the correct font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` elements from affecting the line height in
* all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
/* Embedded content
========================================================================== */
/**
* Add the correct display in IE 9-.
*/
audio,
video {
display: inline-block;
}
/**
* Add the correct display in iOS 4-7.
*/
audio:not([controls]) {
display: none;
height: 0;
}
/**
* Remove the border on images inside links in IE 10-.
*/
img {
border-style: none;
}
/**
* Hide the overflow in IE.
*/
svg:not(:root) {
overflow: hidden;
}
/* Forms
========================================================================== */
/**
* 1. Change the font styles in all browsers (opinionated).
* 2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
font-family: sans-serif; /* 1 */
font-size: 100%; /* 1 */
line-height: 1.15; /* 1 */
margin: 0; /* 2 */
}
/**
* Show the overflow in IE.
* 1. Show the overflow in Edge.
*/
button,
input {
/* 1 */
overflow: visible;
}
/**
* Remove the inheritance of text transform in Edge, Firefox, and IE.
* 1. Remove the inheritance of text transform in Firefox.
*/
button,
select {
/* 1 */
text-transform: none;
}
/**
* 1. Prevent a WebKit bug where (2) destroys native `audio` and `video`
* controls in Android 4.
* 2. Correct the inability to style clickable types in iOS and Safari.
*/
button,
html [type='button'],
[type='reset'],
[type='submit'] {
-webkit-appearance: button; /* 2 */
}
/**
* Remove the inner border and padding in Firefox.
*/
button::-moz-focus-inner,
[type='button']::-moz-focus-inner,
[type='reset']::-moz-focus-inner,
[type='submit']::-moz-focus-inner {
border-style: none;
padding: 0;
}
/**
* Restore the focus styles unset by the previous rule.
*/
button:-moz-focusring,
[type='button']:-moz-focusring,
[type='reset']:-moz-focusring,
[type='submit']:-moz-focusring {
outline: 1px dotted ButtonText;
}
/**
* Correct the padding in Firefox.
*/
fieldset {
padding: 0.35em 0.75em 0.625em;
}
/**
* 1. Correct the text wrapping in Edge and IE.
* 2. Correct the color inheritance from `fieldset` elements in IE.
* 3. Remove the padding so developers are not caught out when they zero out
* `fieldset` elements in all browsers.
*/
legend {
box-sizing: border-box; /* 1 */
color: inherit; /* 2 */
display: table; /* 1 */
max-width: 100%; /* 1 */
padding: 0; /* 3 */
white-space: normal; /* 1 */
}
/**
* 1. Add the correct display in IE 9-.
* 2. Add the correct vertical alignment in Chrome, Firefox, and Opera.
*/
progress {
display: inline-block; /* 1 */
vertical-align: baseline; /* 2 */
}
/**
* Remove the default vertical scrollbar in IE.
*/
textarea {
overflow: auto;
}
/**
* 1. Add the correct box sizing in IE 10-.
* 2. Remove the padding in IE 10-.
*/
[type='checkbox'],
[type='radio'] {
box-sizing: border-box; /* 1 */
padding: 0; /* 2 */
}
/**
* Correct the cursor style of increment and decrement buttons in Chrome.
*/
[type='number']::-webkit-inner-spin-button,
[type='number']::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Correct the odd appearance in Chrome and Safari.
* 2. Correct the outline style in Safari.
*/
[type='search'] {
-webkit-appearance: textfield; /* 1 */
outline-offset: -2px; /* 2 */
}
/**
* Remove the inner padding and cancel buttons in Chrome and Safari on macOS.
*/
[type='search']::-webkit-search-cancel-button,
[type='search']::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* 1. Correct the inability to style clickable types in iOS and Safari.
* 2. Change font properties to `inherit` in Safari.
*/
::-webkit-file-upload-button {
-webkit-appearance: button; /* 1 */
font: inherit; /* 2 */
}
/* Interactive
========================================================================== */
/*
* Add the correct display in IE 9-.
* 1. Add the correct display in Edge, IE, and Firefox.
*/
details,
menu {
display: block;
}
/*
* Add the correct display in all browsers.
*/
summary {
display: list-item;
}
/* Scripting
========================================================================== */
/**
* Add the correct display in IE 9-.
*/
canvas {
display: inline-block;
}
/**
* Add the correct display in IE.
*/
template {
display: none;
}
/* Hidden
========================================================================== */
/**
* Add the correct display in IE 10-.
*/
[hidden] {
display: none;
}

View File

@ -0,0 +1,11 @@
// ==========================================================================
// Resets
// ==========================================================================
// BORDER-BOX ALL THE THINGS!
// http://paulirish.com/2012/box-sizing-border-box-ftw/
*,
*::after,
*::before {
box-sizing: border-box;
}

View File

@ -0,0 +1,6 @@
// ==========================================================================
// Breakpoints
// ==========================================================================
$screen-sm: 480px;
$screen-md: 768px;

View File

@ -0,0 +1,32 @@
// ==========================================================================
// Colors
// ==========================================================================
// Greyscale
$gray-dark: #343f4a;
$gray: #55646b;
$gray-light: #cbd0d3;
$gray-lighter: #dbe3e8;
$off-white: #f2f5f7;
// Text
$color-text: #fff;
// Plyr
$color-brand-primary: #1aafff;
// Brands
$color-twitter: #4baaf4;
$color-youtube: #cc181e;
$color-vimeo: #19b7ed;
// Elements
$color-link: #fff;
$color-background: $color-brand-primary;
// Buttons
$color-button-background: #fff;
$color-button-text: $gray;
// Focus
$tab-focus-default-color: #fff;

View File

@ -0,0 +1,12 @@
// ==========================================================================
// Misc cosmetic
// ==========================================================================
// Button count arrow size
$arrow-size: 5px;
// Radii
$border-radius-base: 4px;
// Background
$page-background: linear-gradient(to left top, lighten($color-background, 10%), darken($color-background, 20%));

View File

@ -0,0 +1,5 @@
// ==========================================================================
// Icons
// ==========================================================================
$icon-size: 16px;

View File

@ -0,0 +1,5 @@
// ==========================================================================
// Layout
// ==========================================================================
$container-max-width: 1260px;

View File

@ -0,0 +1,19 @@
// ==========================================================================
// Plyr Settings
// ==========================================================================
// Font
$plyr-font-family: inherit;
// Sizes
$plyr-font-size-base: 13px;
$plyr-font-size-small: 12px;
$plyr-font-size-time: 11px;
$plyr-font-size-badges: 9px;
// Captions
$plyr-font-size-captions-base: $plyr-font-size-base;
$plyr-font-size-captions-small: $plyr-font-size-small;
$plyr-font-size-captions-medium: 18px;
$plyr-font-size-captions-large: 21px;
$plyr-font-size-menu: $plyr-font-size-base;

View File

@ -0,0 +1,5 @@
// ==========================================================================
// Colors
// ==========================================================================
$spacing-base: 20px;

View File

@ -0,0 +1,20 @@
// ==========================================================================
// Typography
// ==========================================================================
$font-sans-serif: 'Gordita', 'Avenir', 'Helvetica Neue', sans-serif;
$font-size-base: 15;
$font-size-small: 13;
$font-size-large: 18;
$font-size-h1: 64;
$font-weight-light: 300;
$font-weight-regular: 400;
$font-weight-medium: 500;
$font-weight-bold: 600;
$font-weight-black: 900;
$line-height-base: 1.75;
$letter-spacing-headings: -0.025em;

View File

@ -0,0 +1,35 @@
// ==========================================================================
// Base
// ==========================================================================
// Set to 100% for rem sizing
html {
font-size: 100%;
}
body {
@include font-smoothing();
@include font-size($font-size-base);
color: $color-text;
font-family: $font-sans-serif;
font-weight: $font-weight-medium;
line-height: $line-height-base;
text-shadow: 0 1px 1px rgba(#000, 0.15);
}
button,
input,
select,
textarea {
font: inherit;
}
p,
small {
margin: 0 0 $spacing-base;
}
small {
@include font-size($font-size-small);
display: block;
}

View File

@ -0,0 +1,11 @@
// ==========================================================================
// Headings
// ==========================================================================
h1 {
@include font-size($font-size-h1);
font-weight: $font-weight-bold;
letter-spacing: $letter-spacing-headings;
line-height: 1.2;
margin: 0 0 $spacing-base;
}

View File

@ -0,0 +1,7 @@
// ==========================================================================
// Misc cosmetic
// ==========================================================================
.no-border {
border: 0;
}

View File

@ -0,0 +1,20 @@
// ==========================================================================
// Hidden
// ==========================================================================
[hidden] {
display: none;
}
// Hide only visually, but have it available for screen readers: h5bp.com/v
.sr-only {
border: 0;
clip: rect(0 0 0 0);
height: 1px;
margin: -1px;
opacity: 0.001;
overflow: hidden;
padding: 0;
position: absolute;
width: 1px;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 420 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 360 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 157 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 199 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 329 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 441 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 328 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 419 B

View File

@ -1,7 +0,0 @@
The *SVG* folder contains the icons you selected as separate SVG files.
The *demo.html* lists the icons that you selected. To learn how to insert your icons as inline SVGs (with the <use> element), refer to the source of this HTML file. If you prefer to reference an external SVG instead of embedding it in the HTML, you will need to use javascript to fetch the SVG in order to make sure your SVGs will work fine in IE. IcoMoon's Quick Usage mode can take care of that and host your SVGs too.
You can ignore the *svgdefs.svg* file. It contains the same SVG <symbol> definitions as the ones you can find in the demo.html file.
If you prefer using PNGs or CSS sprites, refer to the Preferences panel of the IcoMoon app before downloading your zip pack.

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M9.016 3c2.748 0 4.984 2.243 4.984 5s-2.236 5-4.97 5l-0.060-0.004c-0.055-0.004-0.11-0.007-0.165-0.010l-0.336-0.014-3.665 1.098 0.629-2.483-0.517-0.747c-0.58-0.839-0.886-1.822-0.886-2.842 0-2.757 2.236-5 4.984-5zM9.016 1c-3.857 0-6.984 3.134-6.984 7 0 1.479 0.46 2.848 1.241 3.978l-1.272 5.022 6.722-2.015c0.098 0.004 0.194 0.015 0.293 0.015 3.857 0 6.984-3.134 6.984-7s-3.127-7-6.984-7v0z" fill="#444444"></path>
</svg>

Before

Width:  |  Height:  |  Size: 741 B

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M17.569 8.246l-10.569-6.246c-0.552 0-1 0.448-1 1v1.954l-5-2.954c-0.552 0-1 0.448-1 1v12c0 0.552 0.448 1 1 1l5-2.955v1.955c0 0.552 0.448 1 1 1l10.569-6.246c0.267-0.158 0.431-0.444 0.431-0.754s-0.164-0.597-0.431-0.754zM6 10.722l-4 2.364v-8.172l4 2.364v3.444zM8 13.086v-8.172l6.915 4.086-6.915 4.086z" fill="#444444"></path>
</svg>

Before

Width:  |  Height:  |  Size: 650 B

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M17 2h-16c-0.552 0-1 0.448-1 1v12c0 0.552 0.448 1 1 1h16c0.552 0 1-0.448 1-1v-12c0-0.552-0.448-1-1-1zM2 4h2v2h-2v-2zM2 8h2v2h-2v-2zM2 14v-2h2v2h-2zM6 14v-10h6v10h-6zM16 14h-2v-2h2v2zM16 10h-2v-2h2v2zM16 6h-2v-2h2v2z" fill="#444444"></path>
</svg>

Before

Width:  |  Height:  |  Size: 568 B

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M16 1h-14c-0.552 0-1 0.448-1 1v12c0 0.552 0.448 1 1 1h5.5c-0.829 0-1.5 0.671-1.5 1.5v0.5h6v-0.5c0-0.829-0.671-1.5-1.5-1.5h5.5c0.552 0 1-0.448 1-1v-12c0-0.552-0.448-1-1-1zM15 12.5c0 0.276-0.224 0.5-0.5 0.5h-11c-0.276 0-0.5-0.224-0.5-0.5v-9c0-0.276 0.224-0.5 0.5-0.5h11c0.276 0 0.5 0.224 0.5 0.5v9z" fill="#444444"></path>
</svg>

Before

Width:  |  Height:  |  Size: 649 B

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generated by IcoMoon.io -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="18" height="18" viewBox="0 0 18 18">
<path d="M5 4.914l6.915 4.086-6.915 4.086v-8.172zM4 2c-0.552 0-1 0.448-1 1v12c0 0.552 0.448 1 1 1l10.569-6.246c0.267-0.158 0.431-0.444 0.431-0.754s-0.164-0.597-0.431-0.754l-10.569-6.246z" fill="#444444"></path>
</svg>

Before

Width:  |  Height:  |  Size: 530 B

Some files were not shown because too many files have changed in this diff Show More