server icon indicating copy to clipboard operation
server copied to clipboard

feat: add width, height, crop and mode to BeforePreviewFetchedEvent

Open kesselb opened this issue 2 years ago • 3 comments

Summary

user_usage_report keeps a counter for files read.^1

The app uses

  • OC_Filesystem::read hook
  • Event listener (the legacy one) for IPreview::EVENT

Request for previews do not trigger the hook, hence the additional event listener. The thumbnails for a list or grid view should not count, so we need the width and height.

TODO

  • [x] CI

Checklist

kesselb avatar Jun 06 '23 21:06 kesselb

Would you mind adding more details while we're at it? What I added in https://github.com/nextcloud/server/pull/37193 for admin_audit (crop, mode and mimetype).

tcitworld avatar Jun 09 '23 16:06 tcitworld

@tcitworld added crop and mode.

kesselb avatar Jun 12 '23 09:06 kesselb

Added defaults for width, height, crop and mode to keep the public api stable.

kesselb avatar Jun 20 '23 08:06 kesselb

Documentation: https://github.com/nextcloud/documentation/pull/10674

kesselb avatar Jun 26 '23 11:06 kesselb