Skip to content

Commit 8faf2bc

Browse files
authored
Make thumbnails for uploading pictures (#2206)
* Add downscale on upload * Clean up * Add entry * Separate worker into another file * Check for downscale support * Add comment * Add style options for thumbnail * Typo * Add test * Rename styleOptions for upload thumbnail * Fix ESLint * Add upload text file * Cleanup * Update entry * Update entry * Fix broken propTypes * More robust capability check * Fix tests * Fix tests * Add snapshot * Apply suggestions from code review Co-Authored-By: Corina <[email protected]> * Incorporate PR comments * Thumbnail support for Edge, Firefox, and IE11 * Fix ESLint * Fix promise chaining * Fix test
1 parent 9320172 commit 8faf2bc

33 files changed

Lines changed: 592 additions & 15 deletions

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,12 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
6161

6262
- Added bubble nub and style options, by [@compulim](https://github.com/compulim), in PR [#2137](https://github.com/Microsoft/BotFramework-WebChat/pull/2137)
6363
- Fix [#1808](https://github.com/microsoft/BotFramework-WebChat/issues/1808). Added documentation on activity types, by [@corinagum](https://github.com/corinagum) in PR [#2228](https://github.com/microsoft/BotFramework-WebChat/pull/2228)
64+
- Make thumbnails when uploading GIF/JPEG/PNG and store it in `channelData.attachmentThumbnails`, by [@compulim](https://github.com/compulim), in PR [#2206](https://github.com/microsoft/BotFramework-WebChat/pull/2206), requires modern browsers with following features:
65+
- [Web Workers API](https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API)
66+
- [`createImageBitmap`](https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/createImageBitmap)
67+
- [`MessageChannel`](https://developer.mozilla.org/en-US/docs/Web/API/MessageChannel)/[`MessagePort`](https://developer.mozilla.org/en-US/docs/Web/API/MessagePort)
68+
- [`OffscreenCanvas`](https://developer.mozilla.org/en-US/docs/Web/API/OffscreenCanvas)
69+
- Specifically [`OffscreenCanvas.getContext('2d')`](https://developer.mozilla.org/en-US/docs/Web/API/OffscreenCanvas/getContext)
6470

6571
### Samples
6672

Dockerfile-selenium

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# https://github.com/SeleniumHQ/docker-selenium
2+
# https://hub.docker.com/r/selenium/standalone-chrome/tags/
3+
4+
FROM selenium/standalone-chrome:3.141.59-radium
5+
6+
ADD __tests__/setup/local ~/Downloads
159 KB
Loading
14.4 KB
Loading
117 KB
Loading
124 KB
Loading
155 KB
Loading
Loading
107 KB
Loading
15.5 KB
Loading

0 commit comments

Comments
 (0)