Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
cd03f02
Update index.js lazy load vtt file
ahmad-bbbb Sep 15, 2025
3a6d7f0
lazy load vtt file
ahmad-bbbb Sep 23, 2025
c00c4fb
lazy load vtt file
ahmad-bbbb Sep 23, 2025
12846e2
fix chat remove html tag
ahmad-bbbb Apr 7, 2026
0ed0c9f
Merge pull request #7 from biggerbluebutton/backup_develop
ahmad-bbbb Apr 7, 2026
341255e
Fix premature loaded state and unhandled media probe failures
claude Oct 9, 2026
672bc76
Split the player bundle and load heavy dependencies on demand
claude Oct 9, 2026
c48537f
Improve keyboard access, shortcuts, dialogs and error page
claude Oct 9, 2026
8527ca2
Refresh the player visual design
claude Oct 9, 2026
9fda3a0
Patch vulnerable runtime dependencies and fix lint warnings
claude Oct 9, 2026
a157b50
Replace Dark Reader with a native light/dark theme
claude Oct 9, 2026
366c705
Redesign the player and add viewer features
claude Oct 9, 2026
e161f42
Translate the video controls and improve captions
claude Oct 9, 2026
a539695
Offer caption languages in the CC menu with on-demand translation
claude Oct 9, 2026
68cfaa5
Keep captions visible while switching to a translated language
claude Oct 9, 2026
947776a
Give the player a vibrant, more alive look
claude Oct 9, 2026
5077f5b
Use #E731B2 magenta as the brand color
claude Oct 9, 2026
231bed4
Use #FC25C6 as the brand color
claude Oct 9, 2026
5f5b4e8
Redesign the search dialog
claude Oct 10, 2026
fb314b3
Match the brand gradient to the requested magenta
claude Oct 10, 2026
3a8927b
Add bookmarks, transcript, timeline preview and more shortcuts
claude Oct 10, 2026
5e1e393
Add chapters, watch progress, downloads and touch gestures
claude Oct 10, 2026
a440db8
Add icons to the header details and a paused indicator
claude Oct 10, 2026
e779734
Make caption translation and language downloads faster
claude Oct 10, 2026
701f87e
Fix issues found in code review
claude Oct 10, 2026
e3e6b96
Meet WCAG 2.1 AA across the player (axe: 0 violations)
claude Oct 10, 2026
cedd07e
Handle recordings without slides or chat, and small phones
claude Oct 10, 2026
a2332bb
Add CI workflow, locale checks, and regional locale fallback
claude Oct 10, 2026
39d1d37
Translate the new player features into 17 languages
claude Oct 10, 2026
9c470c9
Show the CC button and captions in Safari
claude Oct 11, 2026
210097b
Translate captions in every browser, phone and tablet
claude Oct 12, 2026
bac5c92
Translate captions in every browser without a server
claude Oct 12, 2026
4bd534e
Make caption translation reliable in Safari
claude Oct 12, 2026
ff8570e
Remember the caption language, and test captions across browsers
claude Oct 13, 2026
7451eb0
Document captions and translation
claude Oct 13, 2026
a26cb11
Play recordings in Safari, and smoother translation notices
claude Oct 13, 2026
aff5a51
Restyle the caption settings dialog in the brand colors
claude Oct 13, 2026
98b947f
Install dependencies in deploy.sh before building
claude Oct 13, 2026
04fb9a6
Tap or click the slides to play and pause
claude Oct 13, 2026
831d3c8
Hide empty caption boxes
claude Oct 13, 2026
afaea0d
Restyle the about dialog in the brand colors
claude Oct 13, 2026
5a40409
Keep caption language switches free of the language left behind
claude Oct 13, 2026
52e8688
Drop empty lines inside captions
claude Oct 13, 2026
8435697
Treat invisible direction marks as empty caption lines
claude Oct 13, 2026
563cd76
Center the play button on the slides
claude Oct 14, 2026
711b74f
Make the quick keys work on any keyboard layout and focus
claude Oct 14, 2026
1224538
Name the side panel tabs under their icons
claude Oct 14, 2026
bd0d7b5
Narrow the gap in the tap pause icon
claude Oct 14, 2026
ab3ef57
Close caption settings with a click outside, without a scroll bar
claude Oct 14, 2026
db484f9
Name the top bar's bookmark action and move rarer actions to a menu
claude Oct 14, 2026
a8aab5d
Hold other caption languages while one gets ready, and never show the…
claude Oct 14, 2026
b572040
Let the side panels scroll, and show transcript words without timings
claude Oct 14, 2026
8337165
Center the loading spinner on the slides
claude Oct 14, 2026
4bd955d
Hold viewers to one translating language on the server too
claude Oct 20, 2026
f9a475a
Remove the LibreTranslate translation server
claude Oct 20, 2026
c413ddd
Make two browser tests hold in WebKit and Firefox
claude Oct 20, 2026
4666c9d
Remove the caption and layout browser tests
claude Oct 20, 2026
d6bae7c
Remove the browser tests and their test recording
claude Oct 20, 2026
fe768da
Remove a stray browser test result file
claude Oct 20, 2026
4c55469
Keep the original deploy.sh and GitHub workflows
claude Oct 21, 2026
e5072b7
Remove the in-browser translator's unit test
claude Oct 21, 2026
85815cc
Merge biggerbluebutton-playback into the player redesign
claude Oct 21, 2026
bd179ce
Remove the tests added on this branch
claude Oct 21, 2026
f8d09e0
Restyle the meeting summary notice in the player's colors
claude Oct 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,7 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Copied from node_modules/ogv by scripts/copy-ogv.js
/public/ogv

73 changes: 73 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,31 @@ You will be able to play your recordings using the following URL
https://<domain>/playback/presentation/2.3/<recordId>
```

## Video in Safari, iPhone and iPad

BigBlueButton records video as WebM, which Safari often cannot play. The
player falls back to decoding it in the page, so recordings play in every
browser. For smooth, battery-friendly playback in Safari, give recordings an
MP4 copy on the server that stores them:
```
sudo ./media/mp4.sh
```

Details: [media/README.md](media/README.md).

## Captions and translation

The CC button works the same in Chrome, Edge, Firefox and Safari, on
computers, phones and tablets. Besides the recording's own captions it
offers them translated into 18 languages, remembers the viewer's choice and
explains what it is doing while a translation starts.

Translation happens in the viewer's browser (Chrome's built-in translator,
or open models in every other browser), with nothing to install on the
server.

How it works, setup and troubleshooting: [docs/captions.md](docs/captions.md).

## Development proxy

The development proxy allows you to test the playback player locally against
Expand Down Expand Up @@ -76,6 +101,27 @@ When no URL is provided, the dev server starts normally without any proxy.

## Configuration

- captions:
- `translate`: offer the recording captions in more languages in the CC menu,
translated when the viewer selects one
- `enabled`: [`true`|`false`]
- `languages`: languages to offer, besides the viewer's own language
- `local`: translation in the viewer's browser with open models, used
when Chrome's built-in translator does not handle a language. Works in every browser with nothing to install; models
download once from `models` (about 110 MB per language) and stay in the
browser cache. Phones and tablets get the languages with small models
(ar, de, en, es, fr, hi, id, it, nl, pt, ru, uk, zh); computers get all
of them
- `enabled`: [`true`|`false`]
- `library`: transformers.js build to load
- `models`: where models download from (a mirror can be set here)
- `preload`: with the browser translator, start downloading the viewer's
language pack on their first click [`true`|`false`]

Translations are saved in the viewer's browser (Cache API), so switching
back to a language or coming back to the recording is instant. See
[docs/captions.md](docs/captions.md) for how the translators are chosen.

- chat:
- `scroll`: automatic scroll [`true`|`false`]
- `align`: scroll align [`top`|`middle`|`bottom`]
Expand All @@ -85,7 +131,9 @@ When no URL is provided, the dev server starts normally without any proxy.
- `fullscreen`
- `search`
- `section`
- `share`: copy a link that opens the recording at the current time
- `swap`
- `theme`: light/dark theme; follows the system preference until the viewer picks one
- `thumbnails`

- locale:
Expand All @@ -96,6 +144,10 @@ When no URL is provided, the dev server starts normally without any proxy.
- `rates`: speed rates

- shortcuts: alt + shift
- `plain`: also enable single key controls [`true`|`false`]
- `Space`/`K`: play/pause, `←`/`J`: seek backwards, `→`/`L`: seek forwards,
`F`: toggle fullscreen, `M`: mute, `<`/`>`: slower/faster, `B`: bookmark
the current moment, `?`: show shortcuts
- `fullscreen`: `K`
- `play/pause`: `Enter`
- `section`: `L`
Expand All @@ -117,6 +169,27 @@ When no URL is provided, the dev server starts normally without any proxy.
- `scroll`: automatic scroll [`true`|`false`]
- `align`: scroll align [`left`|`center`|`right`]

## Viewer features

- Bookmarks: viewers can bookmark moments with a note (`B` or the header
button). They are listed in the Bookmarks panel, marked on the timeline and
kept in the viewer's browser, per recording
- Transcript: when a recording has captions, the Transcript panel shows them as
a searchable list that follows playback; clicking a line plays from there
- Timeline preview: hovering the progress bar shows the slide at that moment
- Search: live results with the matching slide text; clicking one plays it
- Chapters: one per slide, titled from the slide text, with how much of each
one the viewer has watched
- Watch progress: the header shows the share of the recording watched across
visits (kept in the viewer's browser), with a message once it is complete
- Downloads: bookmarks and notes as Markdown with links to each moment, and
the transcript as text
- Tap or click the slides (or tap the video) to play or pause
- Touch: double-tap the left or right side of the slide or video to seek
- Captions: the CC menu offers the recording's captions and translations into
18 languages, and remembers the viewer's language (see
[docs/captions.md](docs/captions.md))

## Standalone recordings

bbb-playback can be used to create a self-contained recording - a single directory that contains all of the recording media files as well as the playback html and javascript code. To do this, use the following build command:
Expand Down
130 changes: 130 additions & 0 deletions docs/captions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
# Captions and translation

This guide covers the CC button of the presentation player: what viewers
get, how translation works, how to set it up on a BigBlueButton server, and
how to troubleshoot it.

## What viewers get

- **The same CC button in every browser**: Chrome, Edge, Firefox and Safari,
on computers, iPhone, iPad and Android. The player draws the captions
itself instead of leaving them to the browser, so they look and behave the
same everywhere, including right-to-left languages.
- **The recording's captions** in every language they were recorded in.
- **Translated captions**: the CC menu also lists other languages, marked
"auto-translated". Picking one shows each line as soon as its translation
arrives, starting from where the viewer is watching. Translation happens
in the viewer's browser: nothing to install on the server, and captions
never leave the viewer's device.
- **Clear notices** while a translation starts: "Translating captions into
Spanish…", the download progress when the browser needs a translation
model, "Getting Spanish captions ready…" while it prepares, and "Spanish
captions are ready" once the first translated line is on screen. Turning
translated captions off closes the notice.
- **A remembered choice**: the language picked last time, original or
translated, is turned on again on the next visit.
- **Instant return**: translations are saved in the viewer's browser, so
coming back to a language or a recording does not translate again.

On phones the captions sit on the video; on larger screens they sit over
the slides, clear of the side panel.

## How translation works

The player uses the first of these translators that handles the language,
and moves on to the next one if a translator stalls or fails, keeping the
lines already translated. Both run on the viewer's device:

| Translator | Browsers | Speed to the first line |
|---|---|---|
| Chrome's built-in translator | Desktop Chrome | About a second (a short language download the first time) |
| Open translation models | All | Chrome, Edge, Firefox: a few seconds, plus the model download the first time (about a minute on a typical connection); Safari: 2 to 4 minutes |

The open models are downloaded once (about 110 MB per language, 230 MB when
a pair goes through English) and kept in the browser cache. Safari is slower
with them because its engine needs a minute or two to prepare a model on
every visit; the player says so while it waits.

Languages offered (set in `captions.translate.languages`):

- On phones and tablets: Arabic, Chinese, Dutch, English, French, German,
Hindi, Indonesian, Italian, Portuguese, Russian, Spanish and Ukrainian.
- On computers: all 18 configured languages (Persian, Japanese, Korean,
Turkish and Urdu use a larger, 630 MB model).
- In desktop Chrome, also whatever its built-in translator offers.

### Switching languages

A picked language shows each line as soon as its translation is ready,
starting from where the viewer is, and "…" for lines still on their way. It
never shows the original language in their place.

While a language gets ready (until its first lines are translated), the
other translations wait, greyed out in the CC menu with a spinner on the
language being prepared. Switching meanwhile would start and stop work in
the background and slow everything down. Captions off and the recording's
own captions stay available, and turning captions off frees the menu at
once.

Once a language is ready, switching is free: the language left behind
pauses after the line it is on and keeps what it has translated, so
picking it again carries on from there. It never changes what is on
screen. If the language on screen cannot be translated, the captions go
back to the original with a notice saying so.

## Setting it up

Deploy the player on the BigBlueButton server, from the repository.
`deploy.sh` builds with the dependencies already installed, so install
them first (after every update that changes `package-lock.json`):

```sh
npm ci
./deploy.sh
```

It builds the player, copies it to `/var/bigbluebutton/playback/presentation/2.3`
and installs the nginx routes. Translation needs nothing else on the server.

Viewers' browsers download the in-browser models from `cdn.jsdelivr.net`
(the translation library) and `huggingface.co` (the models). If those are
blocked for your viewers, set `captions.translate.local` in `src/config.js`
to a mirror (see the README's Configuration section).

Servers where an earlier version of this player installed its translation
server (LibreTranslate) can remove it, freeing about 4 GB of memory and
3 GB of disk:

```sh
sudo ./scripts/remove-translation-server.sh
```

## Files

| Path | What it does |
|---|---|
| `src/components/webcams/index.js` | Creates the video player; turns off the browser's own caption rendering (`nativeTextTracks: false`), which hid the CC button in Safari |
| `src/components/webcams/captions/index.js` | Sets up the CC menu: translation, then the remembered language |
| `src/components/webcams/captions/translation.js` | Adds the translated languages and translates the picked one, line by line, with fallback between translators |
| `src/components/webcams/captions/preference.js` | Remembers and restores the caption language |
| `src/utils/captions/translators.js` | The translators (Chrome's, the in-browser models) and their order |
| `src/utils/captions/local.js` | The in-browser translator: which models for which languages and devices, and the background worker |
| `public/translation-worker.js` | The background worker that runs the open models |
| `src/utils/captions/cache.js` | Saved translations (Cache API) |
| `src/utils/captions/vtt.js` | Reads caption files and orders lines from where the viewer is |
| `src/components/webcams/index.scss` | Caption placement and style |
| `src/locales/messages/*.json` | Notices and labels in 19 languages (`player.captions.*`) |
| `scripts/remove-translation-server.sh` | Removes the translation server earlier versions installed |

## Troubleshooting

| What you see | Why | What to do |
|---|---|---|
| No CC button | The recording has no captions, or the server still runs an old player | Check the recording has `captions.json` and `caption_*.vtt`; deploy the player again |
| The CC menu lists only the recording's languages | Old player, or the browser blocks the model hosts | Deploy the player; check that viewers reach `cdn.jsdelivr.net` and `huggingface.co`, or set a mirror |
| Translation is slow to start in Safari | Safari prepares in-browser models for a minute or two on each visit | Expected; the notice says so. Chrome, Edge and Firefox start in seconds |
| "Couldn't translate captions into …" | Every translator failed (no network, blocked hosts, not enough memory) | With `?debug` in the recording URL, the browser console says which translator failed and why |
| Some languages are missing on phones | Phones only get languages with small models | Expected; computers get all of them |

Translations are saved per browser. To start one over, clear the site's data
in the browser, or open the recording in a private window.
41 changes: 41 additions & 0 deletions media/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Recording video in Safari, iPhone and iPad

BigBlueButton saves recording video as WebM. Chrome, Edge and Firefox play
it, but Safari often cannot: it showed "The media could not be loaded,
either because the server or network failed or because the format is not
supported."

The player now handles this in two ways:

1. **In the browser, nothing to install.** It plays the first video that
works: the recording's MP4, then its WebM, then the WebM decoded in the
page with [ogv.js](https://github.com/bvibber/ogv.js) (VP8/VP9 and
Opus/Vorbis, about 0.8 MB, downloaded only by browsers that need it).
If none works, it says so in the viewer's language. This uses more
processor and battery than native playback, and long, high-resolution
screen sharing can stutter on older phones.
2. **On the server, MP4 copies.** Safari plays MP4 natively: smooth, and
light on the battery. `mp4.sh` makes them:

```sh
sudo ./media/mp4.sh --check # what it would do
sudo ./media/mp4.sh # MP4 for new recordings, and convert the existing ones
sudo ./media/mp4.sh <id> # convert one recording
```

Run it on the server that stores the recordings
(`/var/bigbluebutton/published/presentation`). It:

- adds `mp4` to `video_formats` in
`/usr/local/bigbluebutton/core/scripts/presentation.yml`, so new
recordings get an MP4 (the previous file is kept as
`presentation.yml.before-mp4`);
- converts each recording's `video/webcams.webm` and
`deskshare/deskshare.webm` to H.264/AAC MP4 next to it, at low priority,
skipping files that already have one.

Converting takes roughly a tenth to a third of each recording's length,
and an MP4 takes about as much disk as its WebM. It can run again at any
time, for example from cron after recordings are published.

The player finds the MP4 files by itself; nothing else needs to change.
Loading