W3C home > Mailing lists > Public > public-css-archive@w3.org > November 2019

Re: [csswg-drafts] [all] Feature detection for CSS property support on certain elements (#4498)

From: Xidorn Quan via GitHub <sysbot+gh@w3.org>
Date: Fri, 08 Nov 2019 11:31:55 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-551628780-1573212713-sysbot+gh@w3.org>
To make it crystal clear, what made me raise this issue is `clip-path`, which is a property initially only supported on SVG elements, but later also applied to HTML elements. Nowadays, most modern browsers support this property on both SVG and HTML element, except the legacy Edge, which supports it only on SVG. This makes it practically impossible to do feature detection for this, and we would have to do UA-sniffing, which is unfortunate.


<summary>The reason that we need to diverge on this is ...</summary> because there are various browser bugs involving, especially WebKit has a relatively poor support for SVG elements on some aspects which my colleague and I have filed several bugs for. So we want to avoid touching SVG elements in some cases but instead using `clip-path` on HTML whenever possible. But this doesn't work for the legacy Edge.


This case makes me think that this is a problem CSS should solve, given [the guideline](https://w3ctag.github.io/design-principles/#feature-detect) from TAG. But I totally understand that it could be rather hard, and I don't really have a perfect solution for this.

I file this issue basically just want to raise the concern of this problem, and kick off discussion about this.

GitHub Notification of comment by upsuper
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4498#issuecomment-551628780 using your GitHub account
Received on Friday, 8 November 2019 11:31:57 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:56 UTC