diff --git a/CHANGELOG.md b/CHANGELOG.md index 8549c49..5186d6e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,41 @@ All notable changes to this project will be documented in this file. +## 2.0.0-beta.18 + +### Breaking + +- The viewer tells whoever opened it with events instead of callbacks. + `open()`, `openFolder()` and `compare()` resolve with a `ViewerSession`, an + `EventTarget` dispatching `update:file`, `update:editing`, `close` and + `before-download`. They replace the `onPrev`, `onNext`, `onEditingChange` + and `onClose` options. `getViewer()` dispatches the same events, whoever + opened the viewer (#130) +- `compare(file, base, { view, handlerId })` replaces + `compare(node1, node2, handlerId)`. Both handler elements get + `files: [base, file]` and a `comparison` prop, and the older file shows on + the left (#133) +- A handler's `canCompare` is a function of the files, like `enabled` (#133) +- The package is ESM only, the CommonJS build is gone. Its styles are no + longer injected from JavaScript: each chunk imports its own stylesheet, so + the app's bundler has to handle CSS imports (#124, #132) + +### Added + +- A handler setting `canShowDifferences` can show what changed between two + files in one view. The viewer then offers a toggle in its header, also on D, + and `compare()` can open straight on it with `view: 'differences'` (#133) +- Two versions of a picture show over each other, cut where you drag a + slider (#134) +- `before-download` also reaches the handler's element, and + `detail.waitUntil()` holds the download back, so an editor can save first + (#130) + +### Changed + +- Video and audio play with Video.js 10 and its packaged skins instead of + Plyr, which is deprecated. Picture-in-picture is back (#128, #138) + ## 2.0.0-beta.17 ### Added diff --git a/package-lock.json b/package-lock.json index 5ca702f..3dd7ec2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@nextcloud/viewer", - "version": "2.0.0-beta.17", + "version": "2.0.0-beta.18", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@nextcloud/viewer", - "version": "2.0.0-beta.17", + "version": "2.0.0-beta.18", "license": "AGPL-3.0-or-later", "dependencies": { "@mdi/svg": "^7.4.47", diff --git a/package.json b/package.json index 8c6b26a..0566aaa 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@nextcloud/viewer", - "version": "2.0.0-beta.17", + "version": "2.0.0-beta.18", "description": "The Nextcloud file viewer, and the API for apps to add their own file views", "keywords": [ "nextcloud",