[webkit-changes] [WebKit/WebKit] 204b4f: Add documentation and validation for CSSPseudoSele...

Tim Nguyen noreply at github.com
Thu Jan 4 08:59:17 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 204b4f9d9d47a0120e702686d8f4777c6e66aef2
      https://github.com/WebKit/WebKit/commit/204b4f9d9d47a0120e702686d8f4777c6e66aef2
  Author: Tim Nguyen <ntim at apple.com>
  Date:   2024-01-04 (Thu, 04 Jan 2024)

  Changed paths:
    M Source/WebCore/css/CSSPseudoSelectors.json
    M Source/WebCore/css/process-css-pseudo-selectors.py

  Log Message:
  -----------
  Add documentation and validation for CSSPseudoSelectors.json
https://bugs.webkit.org/show_bug.cgi?id=267031
rdar://120407844

Reviewed by Simon Fraser.

Add validation for:
- field types
- unknown fields
- "argument" field values
- ensuring no-one uses "argument" along with "user-agent-part"

Also add some documentation inline in CSSPseudoSelectors.json.
Documentation for each field is also enforced through the script.

* Source/WebCore/css/CSSPseudoSelectors.json:
* Source/WebCore/css/process-css-pseudo-selectors.py:
(InputValidator):
(InputValidator.__init__):
(InputValidator.validate_fields):

Canonical link: https://commits.webkit.org/272651@main




More information about the webkit-changes mailing list