swissspidy / media-experiments

WordPress media experiments
GNU General Public License v2.0
84 stars 1 forks source link

Recording: remove `CanvasRenderingContext2D.filter` fallback #530

Closed swissspidy closed 3 months ago

swissspidy commented 3 months ago

CanvasRenderingContext2D.filter support recently landed in WebKit, see https://github.com/WebKit/WebKit/commit/222707e7516546a71f05f44449f58374a2bc727c

See https://github.com/riju/backgroundBlur/blob/main/explainer.md See https://bugs.webkit.org/show_bug.cgi?id=198416

One it lands in Safari, can remove the fallback here using this custom blur function:

https://github.com/swissspidy/media-experiments/blob/7ad67531386cee1dc98e31194a986f26082c9154/packages/edit-post/src/mediaRecording/store/resolvers.ts#L152-L188

Can probably already remove it now, and hide the blur button if there is no support.