w3c / manifest

Manifest for web apps
https://www.w3.org/TR/appmanifest/
Other
658 stars 160 forks source link

Clarify case-insensitive parsing for enum values #1142

Open christianliebel opened 3 weeks ago

christianliebel commented 3 weeks ago

The parsing algorithms of the current specification don't mention case-insensitive parsing of the enum-based members (dir, display, orientation), but some browser engines seem to have implemented this:

User Agent dir display orientation
Chromium not implemented yet 🤷🏼‍♂️ case-insensitive 🤷🏼‍♂️ case-insensitive
Gecko 🚨 case-sensitive 🤷🏼‍♂️ case-insensitive 🤷🏼‍♂️ case-insensitive
WebKit 🤷🏼‍♂️ case-insensitive 🤷🏼‍♂️ case-insensitive 🤷🏼‍♂️ case-insensitive
marcoscaceres commented 3 weeks ago

Bit of history... the original version of the spec did... then we did the IDL conversion (case-sensitive/exact match)... then we got rid of the IDL conversion... but then we forgot to revert back to normalizing the case.

At the same time, we were originally being a bit too liberal with the what we accepted. We shouldn't have done case normalization for enum values, but given that's what's implemented by everyone, we might as well updated the spec to match.