Contact emails
ericwi...@chromium.org, ray...@chromium.org
Explainer
https://github.com/WICG/web-share/blob/master/docs/explainer.md
Spec
https://wicg.github.io/web-share/level-2/
The API was most recently discussed during
TAG Review - Web Share Target API
Summary
We are adding the ability to share files, and a canShare() method for feature detection.
Is this feature supported on all six Blink platforms (Windows, Mac, Linux, Chrome OS, Android, and Android WebView)?
This is initially for Android only (same as Level 1). We use the platform native share dialog.
Demo link
https://jsfiddle.net/ericwilligers/8cpuskqd/ - obtains files from <input type="file">
https://jsfiddle.net/ericwilligers/7cory9mj/ - creates files using File API
Risks
Security
Malicious sites might attempt to share malware.
For the initial implementation, we only allow sharing of files with extensions that are not considered potentially dangerous by Safe Browsing: images, videos and text.
In particular, we don't allow sharing of Android executables (.apk / .dex).
Interoperability and Compatibility
This feature was well received at the Web Platform Working Group discussion at TPAC 2018 (minutes).
Edge: No signals
Firefox: under consideration (discussion, bug). The canShare() method was requested by Marcos.
Safari: Level 1 of the Web Share spec (text and URL sharing) is implemented in Safari Preview.
Web developers: The ability to share images and files has been a consistent request, for example from authors of image editors.
See also the blink-dev Intent to Implement discussion for Level 1. Usage of Level 1 has been growing.
There have public articles about Web Share Level 1 by numerous authors:-
Ergonomics
The Web Share Target API complements this API. Web applications can register to receive share requests. It is implemented (but not shipped) in Chrome for Android.
Activation
The API is straightforward and feature detectable, developers should be able to make use of it immediately, without degrading the experience of users running older browsers.
Is this feature fully tested by web-platform-tests?
canShare() has Web Platform Tests.
share() calls a platform-specific dialog. Required failure cases have web platform tests.
Entry on the feature dashboard
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAAyiQQO-MipRyoG5bii4ZQ2B3u8p6R4hUXN%2BeXxMQf%2B%3Dd1DKGw%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/op.zzrwcfv5rbppqq%40cicero2.linkoping.osa.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAOMQ%2Bw_zVVfZr_GUz%3DSW4oxWXGvKAssqoeSH%2Bar4Nxexzaoymw%40mail.gmail.com.