wai-website-theme 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/LICENSE.txt +21 -0
- data/README.md +52 -0
- data/_data/lang.json +730 -0
- data/_data/techniques.yml +180 -0
- data/_data/wcag.yml +125 -0
- data/_includes/.DS_Store +0 -0
- data/_includes/body-class.html +1 -0
- data/_includes/box.html +10 -0
- data/_includes/excol.html +13 -0
- data/_includes/footer.html +40 -0
- data/_includes/head.html +23 -0
- data/_includes/header.html +59 -0
- data/_includes/icon.html +6 -0
- data/_includes/img.html +17 -0
- data/_includes/multilang-list-policy-links.html +29 -0
- data/_includes/multilang-list.html +35 -0
- data/_includes/multilang-policy-title.html +5 -0
- data/_includes/multilang-title-full.html +1 -0
- data/_includes/multilang-title.html +1 -0
- data/_includes/navlist.html +22 -0
- data/_includes/notes.html +2 -0
- data/_includes/prevnext.html +34 -0
- data/_includes/resources.html +19 -0
- data/_includes/sidenav.html +65 -0
- data/_includes/sidenote.html +14 -0
- data/_includes/toc.html +10 -0
- data/_includes/video-player.html +99 -0
- data/_layouts/default.html +26 -0
- data/_layouts/home.html +14 -0
- data/_layouts/news.html +21 -0
- data/_layouts/none.html +1 -0
- data/_layouts/policy.html +72 -0
- data/_layouts/sidenav.html +27 -0
- data/_layouts/sidenavsidebar.html +22 -0
- data/assets/ableplayer/.gitattributes +14 -0
- data/assets/ableplayer/.gitignore +7 -0
- data/assets/ableplayer/Gruntfile.js +105 -0
- data/assets/ableplayer/LICENSE +26 -0
- data/assets/ableplayer/README.md +656 -0
- data/assets/ableplayer/build/ableplayer.dist.js +12157 -0
- data/assets/ableplayer/build/ableplayer.js +12157 -0
- data/assets/ableplayer/build/ableplayer.min.css +2 -0
- data/assets/ableplayer/build/ableplayer.min.js +8 -0
- data/assets/ableplayer/button-icons/able-icons.svg +116 -0
- data/assets/ableplayer/button-icons/black/captions.png +0 -0
- data/assets/ableplayer/button-icons/black/chapters.png +0 -0
- data/assets/ableplayer/button-icons/black/close.png +0 -0
- data/assets/ableplayer/button-icons/black/descriptions.png +0 -0
- data/assets/ableplayer/button-icons/black/ellipsis.png +0 -0
- data/assets/ableplayer/button-icons/black/faster.png +0 -0
- data/assets/ableplayer/button-icons/black/forward.png +0 -0
- data/assets/ableplayer/button-icons/black/fullscreen-collapse.png +0 -0
- data/assets/ableplayer/button-icons/black/fullscreen-expand.png +0 -0
- data/assets/ableplayer/button-icons/black/help.png +0 -0
- data/assets/ableplayer/button-icons/black/next.png +0 -0
- data/assets/ableplayer/button-icons/black/pause.png +0 -0
- data/assets/ableplayer/button-icons/black/pipe.png +0 -0
- data/assets/ableplayer/button-icons/black/play.png +0 -0
- data/assets/ableplayer/button-icons/black/preferences.png +0 -0
- data/assets/ableplayer/button-icons/black/previous.png +0 -0
- data/assets/ableplayer/button-icons/black/rabbit.png +0 -0
- data/assets/ableplayer/button-icons/black/restart.png +0 -0
- data/assets/ableplayer/button-icons/black/rewind.png +0 -0
- data/assets/ableplayer/button-icons/black/sign.png +0 -0
- data/assets/ableplayer/button-icons/black/slower.png +0 -0
- data/assets/ableplayer/button-icons/black/stop.png +0 -0
- data/assets/ableplayer/button-icons/black/transcript.png +0 -0
- data/assets/ableplayer/button-icons/black/turtle.png +0 -0
- data/assets/ableplayer/button-icons/black/volume-loud.png +0 -0
- data/assets/ableplayer/button-icons/black/volume-medium.png +0 -0
- data/assets/ableplayer/button-icons/black/volume-mute.png +0 -0
- data/assets/ableplayer/button-icons/black/volume-soft.png +0 -0
- data/assets/ableplayer/button-icons/fonts/able.eot +0 -0
- data/assets/ableplayer/button-icons/fonts/able.svg +40 -0
- data/assets/ableplayer/button-icons/fonts/able.ttf +0 -0
- data/assets/ableplayer/button-icons/fonts/able.woff +0 -0
- data/assets/ableplayer/button-icons/white/captions.png +0 -0
- data/assets/ableplayer/button-icons/white/chapters.png +0 -0
- data/assets/ableplayer/button-icons/white/close.png +0 -0
- data/assets/ableplayer/button-icons/white/descriptions.png +0 -0
- data/assets/ableplayer/button-icons/white/ellipsis.png +0 -0
- data/assets/ableplayer/button-icons/white/faster.png +0 -0
- data/assets/ableplayer/button-icons/white/forward.png +0 -0
- data/assets/ableplayer/button-icons/white/fullscreen-collapse.png +0 -0
- data/assets/ableplayer/button-icons/white/fullscreen-expand.png +0 -0
- data/assets/ableplayer/button-icons/white/help.png +0 -0
- data/assets/ableplayer/button-icons/white/next.png +0 -0
- data/assets/ableplayer/button-icons/white/pause.png +0 -0
- data/assets/ableplayer/button-icons/white/pipe.png +0 -0
- data/assets/ableplayer/button-icons/white/play.png +0 -0
- data/assets/ableplayer/button-icons/white/preferences.png +0 -0
- data/assets/ableplayer/button-icons/white/previous.png +0 -0
- data/assets/ableplayer/button-icons/white/rabbit.png +0 -0
- data/assets/ableplayer/button-icons/white/restart.png +0 -0
- data/assets/ableplayer/button-icons/white/rewind.png +0 -0
- data/assets/ableplayer/button-icons/white/sign.png +0 -0
- data/assets/ableplayer/button-icons/white/slower.png +0 -0
- data/assets/ableplayer/button-icons/white/stop.png +0 -0
- data/assets/ableplayer/button-icons/white/transcript.png +0 -0
- data/assets/ableplayer/button-icons/white/turtle.png +0 -0
- data/assets/ableplayer/button-icons/white/volume-loud.png +0 -0
- data/assets/ableplayer/button-icons/white/volume-medium.png +0 -0
- data/assets/ableplayer/button-icons/white/volume-mute.png +0 -0
- data/assets/ableplayer/button-icons/white/volume-soft.png +0 -0
- data/assets/ableplayer/images/wingrip.png +0 -0
- data/assets/ableplayer/package.json +22 -0
- data/assets/ableplayer/scripts/JQuery.doWhen.js +113 -0
- data/assets/ableplayer/scripts/ableplayer-base.js +440 -0
- data/assets/ableplayer/scripts/browser.js +162 -0
- data/assets/ableplayer/scripts/buildplayer.js +1609 -0
- data/assets/ableplayer/scripts/caption.js +385 -0
- data/assets/ableplayer/scripts/chapters.js +242 -0
- data/assets/ableplayer/scripts/control.js +1514 -0
- data/assets/ableplayer/scripts/description.js +283 -0
- data/assets/ableplayer/scripts/dialog.js +147 -0
- data/assets/ableplayer/scripts/dragdrop.js +766 -0
- data/assets/ableplayer/scripts/event.js +595 -0
- data/assets/ableplayer/scripts/initialize.js +725 -0
- data/assets/ableplayer/scripts/langs.js +750 -0
- data/assets/ableplayer/scripts/metadata.js +134 -0
- data/assets/ableplayer/scripts/misc.js +72 -0
- data/assets/ableplayer/scripts/preference.js +909 -0
- data/assets/ableplayer/scripts/search.js +171 -0
- data/assets/ableplayer/scripts/sign.js +92 -0
- data/assets/ableplayer/scripts/slider.js +454 -0
- data/assets/ableplayer/scripts/track.js +296 -0
- data/assets/ableplayer/scripts/transcript.js +590 -0
- data/assets/ableplayer/scripts/translation.js +66 -0
- data/assets/ableplayer/scripts/volume.js +383 -0
- data/assets/ableplayer/scripts/webvtt.js +765 -0
- data/assets/ableplayer/scripts/youtube.js +471 -0
- data/assets/ableplayer/styles/ableplayer.css +1241 -0
- data/assets/ableplayer/thirdparty/js.cookie.js +145 -0
- data/assets/ableplayer/thirdparty/modernizr.custom.js +4 -0
- data/assets/ableplayer/translations/ca.js +1 -0
- data/assets/ableplayer/translations/de.js +1 -0
- data/assets/ableplayer/translations/en.js +305 -0
- data/assets/ableplayer/translations/es.js +305 -0
- data/assets/ableplayer/translations/fr.js +305 -0
- data/assets/ableplayer/translations/it.js +303 -0
- data/assets/ableplayer/translations/ja.js +305 -0
- data/assets/ableplayer/translations/nl.js +305 -0
- data/assets/css/style.css +4360 -0
- data/assets/css/style.css.map +1 -0
- data/assets/fonts/anonymouspro-bold.woff +0 -0
- data/assets/fonts/anonymouspro-bold.woff2 +0 -0
- data/assets/fonts/anonymouspro-bolditalic.woff +0 -0
- data/assets/fonts/anonymouspro-bolditalic.woff2 +0 -0
- data/assets/fonts/anonymouspro-italic.woff +0 -0
- data/assets/fonts/anonymouspro-italic.woff2 +0 -0
- data/assets/fonts/anonymouspro-regular.woff +0 -0
- data/assets/fonts/anonymouspro-regular.woff2 +0 -0
- data/assets/fonts/notosans-bold.woff +0 -0
- data/assets/fonts/notosans-bold.woff2 +0 -0
- data/assets/fonts/notosans-bolditalic.woff +0 -0
- data/assets/fonts/notosans-bolditalic.woff2 +0 -0
- data/assets/fonts/notosans-italic.woff +0 -0
- data/assets/fonts/notosans-italic.woff2 +0 -0
- data/assets/fonts/notosans-regular.woff +0 -0
- data/assets/fonts/notosans-regular.woff2 +0 -0
- data/assets/images/.DS_Store +0 -0
- data/assets/images/Shape.svg +10 -0
- data/assets/images/icon-related-content.svg +14 -0
- data/assets/images/icons.svg +126 -0
- data/assets/images/teaser-image@1x.jpg +0 -0
- data/assets/images/teaser-image@2x.jpg +0 -0
- data/assets/images/w3c.sketch +0 -0
- data/assets/images/w3c.svg +10 -0
- data/assets/scripts/jquery.min.js +4 -0
- data/assets/scripts/main.js +208 -0
- data/assets/scripts/svg4everybody.js +1 -0
- metadata +257 -0
|
@@ -0,0 +1,656 @@
|
|
|
1
|
+
Able Player
|
|
2
|
+
==========
|
|
3
|
+
|
|
4
|
+
*Able Player* is a fully accessible cross-browser media player. It uses
|
|
5
|
+
the HTML5 `<audio>` or `<video>` element for browsers that support them,
|
|
6
|
+
and (optionally) the JW Player as a fallback for those that don’t.
|
|
7
|
+
|
|
8
|
+
To see the player in action check our [Able Player Examples][examples] page.
|
|
9
|
+
|
|
10
|
+
Features
|
|
11
|
+
--------
|
|
12
|
+
|
|
13
|
+
- Supports both audio and video.
|
|
14
|
+
- Supports either a single audio track or an entire playlist.
|
|
15
|
+
- A full set of player controls that are keyboard-accessible, properly labeled for screen reader users, and controllable by speech recognition users.
|
|
16
|
+
- Customizable keyboard shortcuts that enable the player to be operated from anywhere on the web page (unless there are multiple instances of the player on a given page; then the player must have focus for keyboard shortcuts to work).
|
|
17
|
+
- High contrast, scalable controls that remain visible in Windows High Contrast mode, plus an easy-to-see focus indicator so keyboard users can easily tell which control currently has focus.
|
|
18
|
+
- Support for closed captions and subtitles in Web Video Timed Text (WebVTT) format, the standard format recommended by the HTML5 specification.
|
|
19
|
+
- Support for chapters, also using WebVTT. Chapters are specific landing points in the video, allowing video content to have structure and be more easily navigated.
|
|
20
|
+
- Support for text-based audio description, also using WebVTT. At designated times, the description text is read aloud by screen readers. Users can optionally set their player to pause when audio description starts in order to avoid conflicts between the description and program audio.
|
|
21
|
+
- Support for audio description as a separate video. When two videos are available (one with description and one without), both can be delivered together using the same player and users can toggle between the versions.
|
|
22
|
+
- Support for adjustable playback rate. Users who need to slow down the video in order to better process and understand its content can do so; and users who need to speed up the video in order to maintain better focus can do so.
|
|
23
|
+
- An interactive transcript feature, built from the WebVTT chapter, caption and description files as the page is loaded. Users can click anywhere in the transcript to start playing the video (or audio) at that point. Keyboard users can also choose to keyboard-enable the transcript, so they can tab through its content one caption at a time and press enter to play the media at the desired point.
|
|
24
|
+
- Automatic text highlighting within the transcript as the media plays. This feature is enabled by default but can be turned off if users find it distracting.
|
|
25
|
+
- Support for playing YouTube videos within the Able Player chrome.
|
|
26
|
+
- Customizable caption display. Users can control the font style, size, and color of caption text; plus background color and transparency; all from the Preferences dialog. They can also choose to position captions *below* the video instead of the default position (an semi-transparent overlay).
|
|
27
|
+
- Optional seamless integrated support for JW Player as a fallback player for users whose browsers don't support HTML5 media. The fallback player uses the same custom interface and provides a nearly identical experience.
|
|
28
|
+
- Extensive customization. Many of the features described above are controlled by user preferences. This is based on the belief that every user has different needs and there are no one-size-fits-all solutions. This is the heart of universal design.
|
|
29
|
+
|
|
30
|
+
Contributing
|
|
31
|
+
-------------
|
|
32
|
+
|
|
33
|
+
There are many ways to contribute to Able Player, and we welcome and appreciate your help! Here are some options:
|
|
34
|
+
|
|
35
|
+
- If you spot bugs are have feature requests, please submit them to the [Issues][issues] queue.
|
|
36
|
+
- If you have code to contribute, please note that all development occurs on the [develop branch][develop]. This is often many commits ahead of the master branch, so please do all development from *develop*, and submit pull requests there. We particularly appreciate help with any issues in the Issues queue that have been flagged with "help wanted".
|
|
37
|
+
- If you are multilingual, please consider translating Able Player into another language! All labels, prompts, messages, and help text for each language are contained within a single file, contained within the */translations* directory.
|
|
38
|
+
|
|
39
|
+
Compatibility
|
|
40
|
+
-------------
|
|
41
|
+
|
|
42
|
+
*Able Player* has been tested with the following browsers and assistive
|
|
43
|
+
technologies.
|
|
44
|
+
|
|
45
|
+
- Firefox 3.x and higher
|
|
46
|
+
- Internet Explorer 10 and higher without fallback
|
|
47
|
+
- Internet Explorer 8 and 9, dependent on JW Player as fallback.
|
|
48
|
+
- Google Chrome 7.0 and higher
|
|
49
|
+
- Opera 10.63 and higher
|
|
50
|
+
- Safari 5.0 on Mac OS X
|
|
51
|
+
- Safari on IOS 3.2.2 and higher (audio only, video plays in default IOS player)
|
|
52
|
+
- Chrome on Android 4.2 and higher
|
|
53
|
+
|
|
54
|
+
Note that mobile browsers have limitations (e.g., volume control and autostart are not supported)
|
|
55
|
+
|
|
56
|
+
Dependencies
|
|
57
|
+
------------
|
|
58
|
+
|
|
59
|
+
*Able Player* has a few dependencies, but most are either provided with
|
|
60
|
+
*Able Player* or available through Google’s hosted libraries. The one
|
|
61
|
+
exception is the fallback player—see the *Fallback* section below for
|
|
62
|
+
details.
|
|
63
|
+
|
|
64
|
+
- *Able Player* uses [jQuery][]. The example code
|
|
65
|
+
below uses Google’s hosted libraries; no download required.
|
|
66
|
+
- *Able Player* uses [Modernizr][] to enable styling of HTML5 elements
|
|
67
|
+
in Internet Explorer 6 through 8. A Modernizr 2.6.2 Custom Build is
|
|
68
|
+
distributed with *Able Player*, and is all that *Able Player* needs.
|
|
69
|
+
- *Able Player* uses [js-cookie][] to store and retrieve user
|
|
70
|
+
preferences in cookies. This script is distributed with *Able
|
|
71
|
+
Player*. Prior to version 2.3, Able Player used [jquery.cookie][]
|
|
72
|
+
for this same purpose.
|
|
73
|
+
|
|
74
|
+
Fallback
|
|
75
|
+
--------
|
|
76
|
+
|
|
77
|
+
For older browsers that don’t support HTML5 media elements, you need a
|
|
78
|
+
fallback solution. *Able Player* was developed to work seamlessly with
|
|
79
|
+
[JW Player][], specifically **JW Player 6** (successfully tested with
|
|
80
|
+
versions 6.0 and 6.11). JW Player is free for non-commercial use but
|
|
81
|
+
is licensed separately and is not distributed with *Able Player*.
|
|
82
|
+
After licensing and downloading JW PLayer, copy *jwplayer.js*, *jwplayer.html5.js*,
|
|
83
|
+
and *jwplayer.flash.swf* into the
|
|
84
|
+
*Able Player* */thirdparty* directory.
|
|
85
|
+
|
|
86
|
+
If you choose to use JW Player as your fallback player,
|
|
87
|
+
users with some older browsers will have a similar experience with
|
|
88
|
+
*Able Player* as users with newer browsers.
|
|
89
|
+
|
|
90
|
+
Note that *most* browsers in use today support HTML5 media elements.
|
|
91
|
+
Here’s a breakdown:
|
|
92
|
+
- Chrome since 3.0
|
|
93
|
+
- Firefox since 3.5
|
|
94
|
+
- Safari since 3.1
|
|
95
|
+
- Opera since 10.5
|
|
96
|
+
- Internet Explorer since 9.0 (video was buggy in 9; better in 10)
|
|
97
|
+
|
|
98
|
+
Note the following limitations in Internet Explorer (IE):
|
|
99
|
+
- IE10 and higher work fine without a fallback player
|
|
100
|
+
- IE9 was the first version of IE to support HTML5 media elements. However, its support for video was buggy so Able Player uses the fallback if it's available
|
|
101
|
+
- IE8 works fine with JW Player as fallback
|
|
102
|
+
- IE6 and 7 are not supported
|
|
103
|
+
|
|
104
|
+
At some point we may decide that it’s reasonable to stop supporting a
|
|
105
|
+
fallback player. However, according to [WebAIM’s 2014 Screen Reader User
|
|
106
|
+
Survey][] 19.8% of screen reader users are still using Internet Explorer 8, 7, or 6. Until these users catch up, we think we have to provide a
|
|
107
|
+
working fallback.
|
|
108
|
+
|
|
109
|
+
As an alternative fallback, you could link to the media file so users
|
|
110
|
+
can download it and play it on their player of choice, and/or provide a
|
|
111
|
+
transcript.
|
|
112
|
+
|
|
113
|
+
Setup Step 1: Use HTML5 Doctype
|
|
114
|
+
-------------------------------
|
|
115
|
+
|
|
116
|
+
*Able Player* is built on the HTML5 media elements, so at the top of
|
|
117
|
+
your web page be sure you have the HTML5 doctype:
|
|
118
|
+
|
|
119
|
+
```HTML
|
|
120
|
+
<!DOCTYPE html>
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
Setup Step 2: Add JavaScript and CSS
|
|
124
|
+
------------------------------------
|
|
125
|
+
|
|
126
|
+
Copy and paste the following code into your web page. This code applies
|
|
127
|
+
to all use cases, both audio and video.
|
|
128
|
+
|
|
129
|
+
```HTML
|
|
130
|
+
<!-- Dependencies -->
|
|
131
|
+
<script src="thirdparty/modernizr.custom.js"></script>
|
|
132
|
+
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.2.4/jquery.min.js"></script>
|
|
133
|
+
<script src="thirdparty/js.cookie.js"></script>
|
|
134
|
+
|
|
135
|
+
<!-- CSS -->
|
|
136
|
+
<link rel="stylesheet" href="build/ableplayer.min.css" type="text/css"/>
|
|
137
|
+
|
|
138
|
+
<!-- JavaScript -->
|
|
139
|
+
<script src="build/ableplayer.min.js"></script>
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
Setup Step 3: Add HTML
|
|
143
|
+
----------------------
|
|
144
|
+
|
|
145
|
+
Add an HTML5 `<audio>` or `<video>` element to your web page, as
|
|
146
|
+
follows.
|
|
147
|
+
|
|
148
|
+
### Audio
|
|
149
|
+
|
|
150
|
+
Copy and paste the following code into your web page, replacing the
|
|
151
|
+
source files with the path to your own media files. Use both OGG and MP3
|
|
152
|
+
to ensure cross-browser compatibility, since some browsers don’t support
|
|
153
|
+
MP3.
|
|
154
|
+
|
|
155
|
+
```HTML
|
|
156
|
+
<audio id="audio1" data-able-player preload="auto">
|
|
157
|
+
<source type="audio/ogg" src="path_to_audio_file.ogg"/>
|
|
158
|
+
<source type="audio/mpeg" src="path_to_audio_file.mp3"/>
|
|
159
|
+
</audio>
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
### Video
|
|
163
|
+
|
|
164
|
+
Copy and paste the following code into your web page, replacing the
|
|
165
|
+
source files with the path to your own media files. Use both WebM and MP4
|
|
166
|
+
to ensure cross-browser compatibility, since some browsers don’t support
|
|
167
|
+
MP4.
|
|
168
|
+
|
|
169
|
+
```HTML
|
|
170
|
+
<video id="video1" data-able-player preload="auto" width="480" height="360" poster="path_to_image.jpg">
|
|
171
|
+
<source type="video/webm" src="path_to_video.webm" data-desc-src="path_to_described_video.webm"/>
|
|
172
|
+
<source type="video/mp4" src="path_to_video.mp4" data-desc-src="path_to_described_video.mp4"/>
|
|
173
|
+
<track kind="captions" src="path_to_captions.vtt"/>
|
|
174
|
+
<track kind="descriptions" src="path_to_descriptions.vtt"/>
|
|
175
|
+
</video>
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
### Supported Attributes
|
|
180
|
+
|
|
181
|
+
The following attributes are supported on both the `<audio>` and `<video>` elements:
|
|
182
|
+
|
|
183
|
+
#### Required Attributes
|
|
184
|
+
|
|
185
|
+
- **id** - required; any unique ID
|
|
186
|
+
- **data-able-player** - required
|
|
187
|
+
|
|
188
|
+
#### Optional; General-Purpose
|
|
189
|
+
|
|
190
|
+
- **data-debug** - optional; if present will write messages to the developer console
|
|
191
|
+
- **autoplay** - optional; play media automatically when page loads. For accessibility reasons, this is *not* recommended unless user is sure to *expect* media to automatically start. For example, autoplay could reasonably be used in conjunction with data-start-time in a media search application.
|
|
192
|
+
- **preload** - optional; tells the browser how much media to download
|
|
193
|
+
when the page loads. If the media is the central focus of the web
|
|
194
|
+
page, use **preload="auto"**, which instructs the browser to
|
|
195
|
+
download as much of the media as possible. If the media is not a
|
|
196
|
+
central focus, downloading the entire media resource can consume
|
|
197
|
+
valuable bandwidth, so preload="metadata" would be a better option.
|
|
198
|
+
- **width** - width of the media player in pixels. For video, this value should reflect the target width of the media itself. If not provided will default to 480.
|
|
199
|
+
- **data-root-path** - define path to root directory of Able Player; generally not required but may be needed in rare instances where Able Player is unable to identify its current path on the web server
|
|
200
|
+
- **data-icon-type** - optional; "font" or "image"; "font" is the default with automatic fallback to image if browsers don't support icon fonts. Should generally leave as is unless testing the fallback.
|
|
201
|
+
- **data-speed-icons** - optional; "arrows" (default) or "animals". The latter will substitute a turtle icon for *slower* and a rabbit icon for *faster*.
|
|
202
|
+
- **data-start-time** - optional; time at which you want the audio to start playing (in seconds)
|
|
203
|
+
- **data-volume** - optional; set the default volume (0 to 10; default is 7 to avoid overpowering screen reader audio)
|
|
204
|
+
- **data-seek-interval** - optional; interval (in seconds) of forward and rewind buttons. By default, seek interval is intelligently calculated based on duration of the media.
|
|
205
|
+
- **data-show-now-playing** - optional; "true" or "false" to include "Selected track" section within player; only applies when a playlist is present
|
|
206
|
+
|
|
207
|
+
#### Language
|
|
208
|
+
|
|
209
|
+
- **data-lang** - optional; specify language of the player using 2-character language code (default is "en" for English)
|
|
210
|
+
- **data-force-lang** - optional; include this option to force the player to use the value of *data-lang* as the player language. Otherwise, the player language will be set as follows, in order of precedence: 1) the language of the web page or user's web browser if either is known and if there is a matching translation file; 2) the value of *data-lang* if provided; 3) English.
|
|
211
|
+
|
|
212
|
+
#### Captions
|
|
213
|
+
|
|
214
|
+
- **data-captions-position** - optional; specify default position of captions relative to the video (either "below" or "overlay"; "below" is the default if not specified). Users can override this setting in Captions Preferences.
|
|
215
|
+
|
|
216
|
+
#### Transcript
|
|
217
|
+
|
|
218
|
+
Able Player can automatically generate an accessible interactive transcript from the chapters, captions, and descriptions tracks. There are three types of interactive transcripts supported:
|
|
219
|
+
- "external" - Automatically generated, written to an external div (requires **data-transcript-div**)
|
|
220
|
+
- "popup" - Automatically generated, written to a draggable, resizable popup window that can be toggled on/off with a button on the controller
|
|
221
|
+
- "manual" - A manually coded external transcript (requires **data-transcript-src**)
|
|
222
|
+
|
|
223
|
+
The following attributes control which of the above types, if any, are generated:
|
|
224
|
+
- **data-transcript-div** - optional; id of an external div in which to display an interactive transcript.
|
|
225
|
+
- **data-transcript-src** - optional; id of an external div that contains a pre-existing manually coded transcript. Able Player will parse this transcript and interact with it during playback.
|
|
226
|
+
- **data-include-transcript** - optional; set to "false" to exclude transcript button from controller.
|
|
227
|
+
|
|
228
|
+
If none of the above attributes are present, the transcript will be displayed in a draggable, resizable popup that can be toggled on/off using a button on the controller. Note that a toggle button is added to the controller *only* if the transcript is a "popup" type; there is no toggle button for either the "external" or "manual" transcript types.
|
|
229
|
+
|
|
230
|
+
Additional transcript-related attributes include:
|
|
231
|
+
- **data-transcript-title** - optional; override default transcript title (default is "Transcript", or "Lyrics" if the data-lyrics-mode attribute is present)
|
|
232
|
+
- **data-lyrics-mode** - optional; forces a line break between and within captions in the transcript
|
|
233
|
+
|
|
234
|
+
To manually code the transcript, one simple strategy is to first allow Able Player to *automatically* generate a transcript. Then copy and paste its content as a starting point. To manually code a transcript from scratch, use the following markup (see [Video Demo #7] for an example):
|
|
235
|
+
|
|
236
|
+
- Wrap the entire transcript in a container with class="able-transcript", and wrap that in another container with class="able-transcript-area".
|
|
237
|
+
- Add an empty <div> just inside the outer container with class="able-window-toolbar".
|
|
238
|
+
- Wrap all audio description in a <div> element with class="able-transcript-desc".
|
|
239
|
+
- Add a <span> element to the start of each audio description block, with class="able-hidden" and text "Description:". This helps screen reader users to distinguish between caption and description text.
|
|
240
|
+
- Wrap each block of caption text in a <div> element with class="able-transcript-block".
|
|
241
|
+
- Wrap each clickable segment of content in a <span> element, with class="able-transcript-seekpoint", plus **data-start** and **data-end** attributes. The values of these two data attributes are the video start and end times expressed in seconds (decimals points are allowed).
|
|
242
|
+
- If the clickable span is caption text, also add the "able-transcript-caption" class.
|
|
243
|
+
- Wrap unspoken content such as names of speakers or descriptions of sound in a <span> element with class="able-unspoken".
|
|
244
|
+
- Use any other markup desired to add structure and style to your transcript. Able Player will ignore it.
|
|
245
|
+
|
|
246
|
+
#### Chapters
|
|
247
|
+
|
|
248
|
+
- **data-chapters-div** - optional; id of an external div in which to display a list of chapters.
|
|
249
|
+
The list of chapters is generated automatically if a chapters track is available in a WebVTT file.
|
|
250
|
+
If this attribute is not provided and chapter are available, chapters will be displayed in a popup menu triggered by the Chapters button.
|
|
251
|
+
- **data-use-chapters-button** - optional; set to "false" to exclude chapters button from controller. If using the data-chapters-div attribute to write the chapters to an external container, you might not want users to be able to toggle the chapters off.
|
|
252
|
+
- **data-chapters-title** - optional; override default chapters title (default is "Chapters"). A null value (data-chapters-title="") eliminates the title altogether.
|
|
253
|
+
- **data-chapters-default** - optional; identify ID of default chapter (must correspond with the text or value immediately above the timestamp in your chapter's WebVTT file). If this attribute is present, the media will be advanced to this start time. Otherwise it will start at the beginning. (See also **data-start-time**).
|
|
254
|
+
- **data-seekbar-scope** - optional; default is "video" (seekbar represents full duration of video); if set to "chapter" seekbar represents the duration of the current chapter only
|
|
255
|
+
|
|
256
|
+
#### Metadata
|
|
257
|
+
|
|
258
|
+
Metadata is added using the `<track>` element with kind="metadata".
|
|
259
|
+
It must be in Web Video Text Tracks format ([WebVTT][]).
|
|
260
|
+
Able Player supports two types of metadata:
|
|
261
|
+
|
|
262
|
+
1. "text" - The WebVTT file contains text, intended to be written to an external container at the designated times. You must provide the external container; Able Player does not generate that automatically.
|
|
263
|
+
|
|
264
|
+
2. "selector" - The WebVTT file contains jQuery selectors which target hidden content that is already present on the web page. At the designated times, the hidden content referenced by the jQuery selectors is made visible. In addition to selectors, the WebVTT file can contain either of the following keywords, each on a line by itself:
|
|
265
|
+
|
|
266
|
+
- **PAUSE** instructs Able Player to pause the video at that point.
|
|
267
|
+
- **FOCUS:** followed by a jQuery selector, places keyboard focus on the designated element, which should have a *tabindex* attribute with a value of either "0" (element is part of the regular tab order) or "-1" (element is not part of the regular tab order, but can receive focus in this context via JavasScript).
|
|
268
|
+
|
|
269
|
+
This combination of exposing new content, pausing the video, and placing keyboard focus on a newly exposed element, can be used to provide supplemental content including clickable "hot spots" overlaid on the video.
|
|
270
|
+
|
|
271
|
+
The following attributes make all this possible:
|
|
272
|
+
|
|
273
|
+
- **data-meta-type** - required for metadata; indicates the type of metadata contained within a metadata track. Supported values as described above are "text" and "selector".
|
|
274
|
+
- **data-meta-div** - required for "text" metadata; id of an external div in which to display the text.
|
|
275
|
+
- **data-duration** - optional attribute on the element displayed via a metadata track; value is the number of milliseconds to display the element before it fades out. Elements displayed via metadata tracks automatically fade out at the end time designated within the WebVTT file. However, if the **data-duration** attribute is present, this enables an element to fade out *before* the designated time. This is useful if multiple elements appear simultaneously, but some need to fade out earlier than others.
|
|
276
|
+
|
|
277
|
+
**NOTE:** If you're using metadata to expose content in sync with videos hosted on YouTube, please review [YouTube's Terms of Service] related to Overlays and Frames. As of August 11, 2016: "You must not display overlays, frames, or other visual elements in front of any part of a YouTube embedded player, including player controls. Similarly, you must not use overlays, frames or other visual elements to obscure any part of an embedded player, including player controls."
|
|
278
|
+
|
|
279
|
+
#### Search
|
|
280
|
+
|
|
281
|
+
- **data-search** - optional; search terms to search for within the caption tracks, separated by a space
|
|
282
|
+
- **data-search-div** - optional; id of external container in which to display search results
|
|
283
|
+
|
|
284
|
+
|
|
285
|
+
#### Fallback Player
|
|
286
|
+
|
|
287
|
+
- **data-fallback** - optional; specify a fallback player. Currently the only supported option is "jw" (JW Player)
|
|
288
|
+
- **data-test-fallback** - optional; force browser to user fallback player (recommended for testing only)
|
|
289
|
+
- **data-fallback-path** - optional; override default path to directory in which the fallback player files are stored
|
|
290
|
+
|
|
291
|
+
|
|
292
|
+
The following attributes are supported on the `<video>` element only:
|
|
293
|
+
|
|
294
|
+
- **data-allow-fullscreen** - optional; if set to "false" the player will not include a fullscreen button
|
|
295
|
+
- **data-youtube-id** - optional; 11-character YouTube ID, to play the YouTube video using *Able Player*.
|
|
296
|
+
- **data-youtube-desc-id** - optional; 11-character YouTube ID of the described version of a video. See the section below on *YouTube Support* for additional information.
|
|
297
|
+
- **height** - height of the video in pixels. If not provided will
|
|
298
|
+
default to 360.
|
|
299
|
+
- **poster** - path to an image file. Will be displayed in the player
|
|
300
|
+
until the video is played.
|
|
301
|
+
|
|
302
|
+
The following additional features are supported by *Able Player*:
|
|
303
|
+
|
|
304
|
+
#### Multiple source files
|
|
305
|
+
|
|
306
|
+
As with audio, we recommend including two versions of each video, one in
|
|
307
|
+
H.264 (MP4) and another in WebM or OGG for browsers that don’t support
|
|
308
|
+
MP4. Browsers will play the first media source that they support.
|
|
309
|
+
|
|
310
|
+
#### Closed Captions
|
|
311
|
+
|
|
312
|
+
Captions are added using the `<track>` element with kind="captions".
|
|
313
|
+
Captions must be in Web Video Text Tracks format ([WebVTT][]).
|
|
314
|
+
WebVTT tags within captions are currently ignored.
|
|
315
|
+
|
|
316
|
+
**NOTE:** Able Player only supports valid WebVTT files. Be sure to
|
|
317
|
+
validate your WebVTT using a [WebVTT Validator][].
|
|
318
|
+
|
|
319
|
+
If captions are provided, a CC button will be added to the
|
|
320
|
+
*Able Player* controller.
|
|
321
|
+
|
|
322
|
+
#### Audio Description
|
|
323
|
+
|
|
324
|
+
Supplemental description of key visual content for blind users can be
|
|
325
|
+
added using one of two methods.
|
|
326
|
+
|
|
327
|
+
The first method is the same as closed captions, a `<track>` element, with
|
|
328
|
+
kind="descriptions". This points to a WebVTT file, which is essentially
|
|
329
|
+
the same as a closed caption file, but its contents are description text
|
|
330
|
+
rather than captions. With this method, description text is written to a
|
|
331
|
+
container that has ARIA role="alert". Supporting screen readers
|
|
332
|
+
automatically announce the new text as soon as it is written to the
|
|
333
|
+
page.
|
|
334
|
+
|
|
335
|
+
The second method is to produce a separate video with description mixed
|
|
336
|
+
in. If multiple video sources are already provided (e.g., an MP4 and
|
|
337
|
+
WebM file), then the described version must be available in both of
|
|
338
|
+
these formats. For each video source that has a described version
|
|
339
|
+
available, add a **data-desc-src** attribute to the `<source>` element for
|
|
340
|
+
that video. The value of this attribute is a path pointing to the
|
|
341
|
+
described version of the video. With this method, the described version
|
|
342
|
+
of the video can be played instead of the non-described version, and the
|
|
343
|
+
two versions can be swapped with clicking the "D" button on the
|
|
344
|
+
controller.
|
|
345
|
+
|
|
346
|
+
If descriptions are available using either of the above methods, a
|
|
347
|
+
Description toggle button appears on the controller (represented by the
|
|
348
|
+
universal Description symbol, the letter "D"). How descriptions are
|
|
349
|
+
ultimately delivered depends on which of the above methods is used, and
|
|
350
|
+
on user preference. If a user prefers text-based description announced
|
|
351
|
+
by their screen reader, that’s what they’ll get. If they prefer an
|
|
352
|
+
alternate video with description mixed in, that’s what they’ll get. See
|
|
353
|
+
the section below on *User Preferences* for additional information about
|
|
354
|
+
preferences.
|
|
355
|
+
|
|
356
|
+
In some applications, text-based descriptions might be a required
|
|
357
|
+
part of the interface (e.g., if video pauses so users can interact with
|
|
358
|
+
HTML overlays; text-based description could be used in this context to provide
|
|
359
|
+
additional instructions for screen reader users). In such cases the Descriptions
|
|
360
|
+
button can be eliminated from the controller with **data-use-descriptions-button="false"**.
|
|
361
|
+
|
|
362
|
+
#### Sign language
|
|
363
|
+
|
|
364
|
+
Sign language translation is supported in a separate video player,
|
|
365
|
+
synchronized with the main player. Tips for filming a sign language
|
|
366
|
+
interpreter are available from [Signing Books for the Deaf][]:
|
|
367
|
+
|
|
368
|
+
* [Filming the Signer][]
|
|
369
|
+
* [Editing the Signer][]
|
|
370
|
+
|
|
371
|
+
If multiple video sources are already provided (e.g., an MP4 and
|
|
372
|
+
WebM file), then the sign language video must be available in both of
|
|
373
|
+
these formats. For each video source that has a sign language version
|
|
374
|
+
available, add a **data-sign-src** attribute to the `<source>` element for
|
|
375
|
+
that video. The value of this attribute is a path pointing to the
|
|
376
|
+
sign language version of the video. If a sign language version is available,
|
|
377
|
+
a sign language button will be added to the media controller.
|
|
378
|
+
This button will toggle the display of a secondary window in which
|
|
379
|
+
the sign language video will appear.
|
|
380
|
+
|
|
381
|
+
This is an experimental feature and a work in progress. Ultimately
|
|
382
|
+
the intent is for the user to have full control of the size and position
|
|
383
|
+
of the sign language video.
|
|
384
|
+
|
|
385
|
+
Setup Step 4: Review User-Defined Variables in *ableplayer.js*
|
|
386
|
+
--------------------------------------------------------------
|
|
387
|
+
|
|
388
|
+
The JavaScript file *initialize.js* includes a block of user-defined
|
|
389
|
+
variables that can be modified from their default settings, such as
|
|
390
|
+
volume, color of controller buttons, seek interval for rewind and
|
|
391
|
+
forward buttons, and others. Explanations of each variable are provided
|
|
392
|
+
in the comments.
|
|
393
|
+
|
|
394
|
+
If you make changes to this or any other JavaScript script files,
|
|
395
|
+
the player will need to be recompiled before your changes will take effect.
|
|
396
|
+
To do so, run the shell script *compile.sh*.
|
|
397
|
+
|
|
398
|
+
Playlists
|
|
399
|
+
---------
|
|
400
|
+
|
|
401
|
+
An *Able Player* playlist is an HTML list of tracks. The list can be
|
|
402
|
+
either ordered (`<ol>`) or unordered (`<ul>`). The following attributes
|
|
403
|
+
are supported on the list element:
|
|
404
|
+
|
|
405
|
+
- **class** - required; must be **able-playlist**
|
|
406
|
+
- **data-player** - required; must reference the ID of the media
|
|
407
|
+
player in which the playlist should be played.
|
|
408
|
+
- **data-embedded** - optional; add this attribute if you want your
|
|
409
|
+
playlist to be embedded into the media player. If this attribute is
|
|
410
|
+
omitted, the playlist will be external to the player and will appear
|
|
411
|
+
wherever you place it on the web page.
|
|
412
|
+
|
|
413
|
+
Within the playlist, each list item must include data-\* attributes
|
|
414
|
+
where \* is the media type and the value of the attribute is the URL
|
|
415
|
+
pointing to the media file of that type. For example, the following
|
|
416
|
+
audio playlist includes three songs, each of which is available in MP3
|
|
417
|
+
and OGG:
|
|
418
|
+
|
|
419
|
+
```HTML
|
|
420
|
+
<ul class="able-playlist" data-player="audio1" data-embedded>
|
|
421
|
+
<li data-mp3="song1.mp3" data-ogg="song1.ogg">My First Song</li>
|
|
422
|
+
<li data-mp3="song2.mp3" data-ogg="song2.ogg">My Second Song</li>
|
|
423
|
+
<li data-mp3="song3.mp3" data-ogg="song3.ogg">My Third Song</li>
|
|
424
|
+
</ul>
|
|
425
|
+
```
|
|
426
|
+
|
|
427
|
+
**Supported data-\* audio types:**
|
|
428
|
+
|
|
429
|
+
- mp3
|
|
430
|
+
- ogg or oga
|
|
431
|
+
- wav
|
|
432
|
+
|
|
433
|
+
**Supported data-\* video types:**
|
|
434
|
+
|
|
435
|
+
- mp4
|
|
436
|
+
- webm or webmv
|
|
437
|
+
- ogg or ogv
|
|
438
|
+
|
|
439
|
+
When a playlist is included on a page, the `<source>` elements within
|
|
440
|
+
the `<audio>` or `<video>` tags are optional. If they are provided, they
|
|
441
|
+
should match the first item in the playlist.
|
|
442
|
+
|
|
443
|
+
Interactive Transcript
|
|
444
|
+
----------------------
|
|
445
|
+
|
|
446
|
+
*Able Player* interactive transcripts are generated automatically from
|
|
447
|
+
WebVTT caption and description files. If a transcript is available, a Transcript
|
|
448
|
+
button will be added to the *Able Player* controller.
|
|
449
|
+
|
|
450
|
+
Features of the interactive transcript include the following:
|
|
451
|
+
|
|
452
|
+
- Clicking anywhere in the transcript starts playing the media at that
|
|
453
|
+
point.
|
|
454
|
+
- This same functionality is accessible to keyboard users, who can tab
|
|
455
|
+
through the transcript and press Enter at any point to start playing
|
|
456
|
+
the media at that point. Since this creates a lot of extra tab stops
|
|
457
|
+
on the page, this might be undesirable functionality for some
|
|
458
|
+
keyboard users so it’s disabled by default. It can be toggled on/off
|
|
459
|
+
in the Preferences dialog.
|
|
460
|
+
- Text in the transcript is highlighted as the media plays. This can
|
|
461
|
+
be toggled on/off in the Preferences dialog.
|
|
462
|
+
- If subtitles are available, the transcript can be displayed in any supported language.
|
|
463
|
+
Available languages can be selected from a dropdown select field.
|
|
464
|
+
|
|
465
|
+
YouTube Support
|
|
466
|
+
---------------
|
|
467
|
+
|
|
468
|
+
To play a YouTube video in *Able Player*, simply include a **data-youtube-id** attribute
|
|
469
|
+
on the `<video>` element. The value of this attribute must be the video's 11-character YouTube ID.
|
|
470
|
+
|
|
471
|
+
If a described version of the video is available on YouTube, include a **data-youtube-desc-id** attribute
|
|
472
|
+
on the `<video>` element. The value of this attribute must be the 11-character YouTube ID
|
|
473
|
+
of the described version. If users turn on the Description button on their player controller,
|
|
474
|
+
the described version of the video will be loaded instead of the non-described version.
|
|
475
|
+
|
|
476
|
+
Starting with 2.3.1, a YouTube Data API key is required for playing YouTube videos in Able Player.
|
|
477
|
+
Get a YouTube Data API key by registering your application at the [Google Developer Console][].
|
|
478
|
+
For complete instructions, see [Google's Getting Started page]. Note: All that's needed for
|
|
479
|
+
playing YouTube videos in Able Player is a simple API key, **not** OAuth 2.0.
|
|
480
|
+
|
|
481
|
+
After obtaining your YouTube Data API Key, insert the following code into your HTML page:
|
|
482
|
+
|
|
483
|
+
```HTML
|
|
484
|
+
<script>
|
|
485
|
+
var youTubeDataAPIKey = "paste your API key here";
|
|
486
|
+
var googleApiReady = false;
|
|
487
|
+
function initGoogleClientApi() {
|
|
488
|
+
googleApiReady = true;
|
|
489
|
+
}
|
|
490
|
+
</script>
|
|
491
|
+
<script src="http://apis.google.com/js/client.js?onload=initGoogleClientApi"></script>
|
|
492
|
+
```
|
|
493
|
+
|
|
494
|
+
If captions or subtitles are available on the YouTube video, these will be displayed for all users,
|
|
495
|
+
and can be controlled using Able Player's CC button. Alternatively, if you include your own
|
|
496
|
+
`<track kind="captions">` elements, these will be used *instead of* the captions on YouTube.
|
|
497
|
+
|
|
498
|
+
The advantage of managing captions entirely on YouTube is that you only have to manage them in
|
|
499
|
+
one place, and they're available everywhere your YouTube video is played.
|
|
500
|
+
|
|
501
|
+
The advantages of including captions locally in `<track>` elements include:
|
|
502
|
+
|
|
503
|
+
- Able Player can repurpose the captions into an interactive transcript
|
|
504
|
+
- The captions are searchable using the **data-search** attribute
|
|
505
|
+
- Users can control how the captions are displayed (e.g., color, background color, opacity)
|
|
506
|
+
|
|
507
|
+
Adjustable playback rate is available for some videos.
|
|
508
|
+
|
|
509
|
+
MIME Types
|
|
510
|
+
----------
|
|
511
|
+
|
|
512
|
+
If your media doesn’t play, one possibility is that your web server is
|
|
513
|
+
attempting to serve up the media with the incorrect MIME type. On
|
|
514
|
+
Apache, this can be correct by adding the following commands to the
|
|
515
|
+
.htaccess file:
|
|
516
|
+
|
|
517
|
+
```
|
|
518
|
+
# Audio MIME Types
|
|
519
|
+
AddType audio/mpeg mp3
|
|
520
|
+
AddType audio/mp4 mp4
|
|
521
|
+
AddType audio/mp4 mpa
|
|
522
|
+
AddType audio/ogg ogg
|
|
523
|
+
AddType audio/ogg oga
|
|
524
|
+
AddType audio/wav wav
|
|
525
|
+
|
|
526
|
+
# Video MIME Types
|
|
527
|
+
AddType video/mp4 mp4
|
|
528
|
+
AddType video/ogg ogv
|
|
529
|
+
AddType video/webm webm
|
|
530
|
+
```
|
|
531
|
+
|
|
532
|
+
If you don’t have access to your server’s .htaccess file, you should be
|
|
533
|
+
able to view and add MIME types somewhere within your server’s control
|
|
534
|
+
panel.
|
|
535
|
+
|
|
536
|
+
If your site is running on a Windows server, consult the documentation
|
|
537
|
+
from Microsoft. For example:
|
|
538
|
+
|
|
539
|
+
- [Configuring MIME Types in IIS 7][]
|
|
540
|
+
- [How to add MIME Types with IIS7 Web.config][]
|
|
541
|
+
|
|
542
|
+
Keyboard Shortcuts
|
|
543
|
+
------------------
|
|
544
|
+
|
|
545
|
+
*Able Player* includes several keyboard shortcuts that enable users to control the
|
|
546
|
+
player from anywhere on the web page, as follows:
|
|
547
|
+
|
|
548
|
+
- **p or spacebar** = Play/Pause
|
|
549
|
+
- **s** = Stop
|
|
550
|
+
- **r** = Rewind
|
|
551
|
+
- **f** = Forward
|
|
552
|
+
- **c** = Captions
|
|
553
|
+
- **d** = Description
|
|
554
|
+
- **m** = Mute on/off
|
|
555
|
+
- **v or 1-9** = Volume
|
|
556
|
+
- **e** = Preferences
|
|
557
|
+
|
|
558
|
+
Note that modifier keys (Alt, Control, and Shift) can be assigned by clicking
|
|
559
|
+
the Preferences button on the player. If users find that shortcut keys
|
|
560
|
+
aren’t working as advertised, they might have better success by
|
|
561
|
+
selecting different combinations of modifier keys to accompany the
|
|
562
|
+
default shortcut keys.
|
|
563
|
+
|
|
564
|
+
By default, keyboard shortcuts must be accompanied by Alt + Control.
|
|
565
|
+
|
|
566
|
+
User Preferences
|
|
567
|
+
----------------
|
|
568
|
+
|
|
569
|
+
One of *Able Player’s* accessibility features is that the player is
|
|
570
|
+
highly customizable by users. The controller includes a Preferences
|
|
571
|
+
button that allows users to change default preferences and settings.
|
|
572
|
+
Their changes are stored in a browser cookie and in most cases should
|
|
573
|
+
therefore be preserved the next time they visit the site. Specifically,
|
|
574
|
+
users can control the following:
|
|
575
|
+
|
|
576
|
+
- Modifier keys: Add *Alt*, *Ctrl*, or *Shift* to the Able Player keyboard
|
|
577
|
+
shortcuts to avoid conflicts with other applications.
|
|
578
|
+
- Closed captions on by default
|
|
579
|
+
- Description on by default
|
|
580
|
+
- Use text-based description if available.
|
|
581
|
+
- Automatically pause video when text-based description starts
|
|
582
|
+
- If using text-based description, make it visible
|
|
583
|
+
- Transcript on by default
|
|
584
|
+
- Highlight transcript as video plays
|
|
585
|
+
- Keyboard-enable transcript
|
|
586
|
+
|
|
587
|
+
Building the Able Player source
|
|
588
|
+
-------------------------------
|
|
589
|
+
|
|
590
|
+
The source JavaScript files for Able Player are in the */scripts* directory,
|
|
591
|
+
and the source CSS files are in the */styles* directory. These source files
|
|
592
|
+
are ultimately combined into several different files (in the */build* directory) using
|
|
593
|
+
[npm][] and [Grunt][]:
|
|
594
|
+
|
|
595
|
+
```sh
|
|
596
|
+
npm install
|
|
597
|
+
grunt
|
|
598
|
+
```
|
|
599
|
+
|
|
600
|
+
The npm and Grunt build process is defined by the *Gruntfile.js* and *package.json*
|
|
601
|
+
files. (Note that the **version number** is specified in *package.json*, and must be
|
|
602
|
+
updated when a new version is released).
|
|
603
|
+
|
|
604
|
+
Files created by the build process are put into the */build* directory:
|
|
605
|
+
|
|
606
|
+
- **build/ableplayer.js** -
|
|
607
|
+
the default build of *ableplayer.js*
|
|
608
|
+
- **build/ableplayer.dist.js** -
|
|
609
|
+
a build of *ableplayer.js* without console logging
|
|
610
|
+
- **build/ableplayer.min.js** -
|
|
611
|
+
a minified version of the *dist* file
|
|
612
|
+
- **build/ableplayer.min.css** -
|
|
613
|
+
a minified combined version of all Able Player CSS files
|
|
614
|
+
|
|
615
|
+
Acknowledgments
|
|
616
|
+
---------------
|
|
617
|
+
|
|
618
|
+
- Able Player development is supported in part by the [AccessComputing][] project
|
|
619
|
+
at the University of Washington, with financial support from the National Science Foundation
|
|
620
|
+
(grants #CNS-0540615, CNS-0837508, and CNS-1042260).
|
|
621
|
+
- Additional support has been provided by the
|
|
622
|
+
[Committee on Institutional Cooperation][] (CIC).
|
|
623
|
+
- Turtle and rabbit icons (available as optional alternatives for the speed buttons) are provided courtesy of [Icons8][].
|
|
624
|
+
- Sample video tracks are provided courtesy of [The DO-IT Center][] at the University of Washington. Additional videos are available on the [DO-IT Video][] website, which uses Able Player.
|
|
625
|
+
- Sample audio tracks are provided courtesy of Terrill Thompson from his album [Flavors, by Flow Theory][].
|
|
626
|
+
|
|
627
|
+
|
|
628
|
+
[AccessComputing]: http://washington.edu/accesscomputing
|
|
629
|
+
[Committee on Institutional Cooperation]: https://www.cic.net/home
|
|
630
|
+
[Configuring MIME Types in IIS 7]: http://technet.microsoft.com/en-us/library/17bda1f4-8a0d-440f-986a-5aaa9d40b74c.aspx
|
|
631
|
+
[Editing the Signer]: http://www.sign-lang.uni-hamburg.de/signingbooks/sbrc/grid/d71/guide13.htm
|
|
632
|
+
[develop]: https://github.com/ableplayer/ableplayer/tree/develop
|
|
633
|
+
[examples]: http://ableplayer.github.io/ableplayer/demos/
|
|
634
|
+
[Filming the Signer]: http://www.sign-lang.uni-hamburg.de/signingbooks/sbrc/grid/d71/guide12.htm
|
|
635
|
+
[Flavors, by Flow Theory]: http://www.terrillthompson.com/music/2012/01/flow-theory-flavors/
|
|
636
|
+
[DO-IT Video]: http://washington.edu/doit/video
|
|
637
|
+
[Google Developer Console]: https://console.developers.google.com/
|
|
638
|
+
[Google's Getting Started page]: https://developers.google.com/api-client-library/javascript/start/start-js#Getkeysforyourapplication
|
|
639
|
+
[Grunt]: http://gruntjs.com/
|
|
640
|
+
[How to add MIME Types with IIS7 Web.config]: http://blogs.iis.net/bills/archive/2008/03/25/how-to-add-mime-types-with-iis7-web-config.aspx
|
|
641
|
+
[Icons8]: https://icons8.com
|
|
642
|
+
[issues]: https://github.com/ableplayer/ableplayer/issues
|
|
643
|
+
[jQuery]: http://jquery.com/
|
|
644
|
+
[jquery.cookie]: https://github.com/carhartl/jquery-cookie
|
|
645
|
+
[js-cookie]: https://github.com/js-cookie/js-cookie
|
|
646
|
+
[JW Player]: http://www.jwplayer.com/
|
|
647
|
+
[Modernizr]: http://modernizr.com/
|
|
648
|
+
[npm]: https://www.npmjs.com/
|
|
649
|
+
[Signing Books for the Deaf]: http://www.sign-lang.uni-hamburg.de/signingbooks/
|
|
650
|
+
[The DO-IT Center]: http://washington.edu/doit
|
|
651
|
+
[Video Demo #7]: demos/video7.html
|
|
652
|
+
[WebVTT validator]: https://quuz.org/webvtt/
|
|
653
|
+
[WebAIM’s 2014 Screen Reader User Survey]: http://webaim.org/projects/screenreadersurvey5/#browsers
|
|
654
|
+
[WebVTT]: https://w3c.github.io/webvtt/
|
|
655
|
+
[YouTube's Terms of Service]: https://developers.google.com/youtube/terms/required-minimum-functionality#overlays-and-frames
|
|
656
|
+
|