Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
902seanryan committed Jun 22, 2022
1 parent b29b1ea commit 27a63d8
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,23 @@ container.openPath('game.html');

`PausePlugin` sets a className of 'paused' or 'unpaused' on individual pause buttons.

The `PausePlugin` also has an optional flag
`manageOwnVisibility`. This defaults to `true` and is intended to disable the visibility management of the plugin for environements
that handle visibility/focus themselves. For most web based contexts this flag will not be needed.

```javascript
import { PausePlugin, Container } from 'springroll-container';

const container = new Container("#game", {
plugins: [
// manageOwnVisibility is set to false which means the plugin will not send pause or unpause events if the app is no longer
// focused or other similar states (switched tabs, etc)
new PausePlugin('button#pause-button', false),
]
});
container.openPath('game.html');
```

### Captions

There are two plugins that interact with captions: `CaptionsTogglePlugin`, and `CaptionsStylePlugin`.
Expand Down

0 comments on commit 27a63d8

Please sign in to comment.