Skip to content

Custom Functions (@function) #1031

@andruud

Description

@andruud

こんにちは TAG-さん!

I'm requesting a TAG review of Custom Functions (@function)

"A custom function can be thought of as an advanced custom property, which instead of being substituted by a single fixed value provides its substitution value based on function parameters and local variables." (From the spec.)

  • Explainer¹: https://css.oddbird.net/sasslike/mixins-functions/ (Also explains mixins, which is not in scope for this review.)
  • Specification: https://drafts.csswg.org/css-mixins-1/#defining-custom-functions
  • WPT Tests: N/A
  • User research: https://css.oddbird.net/sasslike/mixins-functions/#author-interest
  • Security and Privacy self-review²:
    tl;dr: nothing to report, expand for details.
    • 2.1 What information might this feature expose to Web sites or other parties, and for what purposes is that exposure necessary?
      A: It doesn't expose anything. It's both defined and used within CSS.
    • 2.2 Do features in your specification expose the minimum amount of information necessary to enable their intended uses?
      A: Yes. (Nothing.)
    • 2.3 How do the features in your specification deal with personal information, personally-identifiable information (PII), or information derived from them?
      A: N/A
    • 2.4 How do the features in your specification deal with sensitive information?
      A: N/A
    • 2.5 Do the features in your specification introduce new state for an origin that persists across browsing sessions?
      A: No.
    • 2.6 Do the features in your specification expose information about the underlying platform to origins?
      A: No.
    • 2.7 Does this specification allow an origin to send data to the underlying platform?
      A: No.
    • 2.8 Do features in this specification enable access to device sensors?
      A: No.
    • 2.9 Do features in this specification enable new script execution/loading mechanisms?
      A: No.
    • 2.10 Do features in this specification allow an origin to access other devices?
      A: No.
    • 2.11 Do features in this specification allow an origin some measure of control over a user agent's native UI?
      A: No.
    • 2.12 What temporary identifiers do the features in this specification create or expose to the web?
      A: None.
    • 2.13 How does this specification distinguish between behavior in first-party and third-party contexts?
      A: N/A.
    • 2.14 How do the features in this specification work in the context of a browser's Private Browsing or Incognito mode?
      A: As normal / not applicable.
    • 2.15 Does this specification have both "Security Considerations" and "Privacy Considerations" sections?
      A: Not yet.
    • 2.16 Do features in your specification enable origins to downgrade default security protections?
      A: N/A.
    • 2.17 How does your feature handle non-"fully active" documents?
      A: N/A.
    • 2.18 What should this questionnaire have asked?
      A: N/A.
  • GitHub repo: https://github.com/w3c/csswg-drafts/tree/main/css-mixins-1
  • Primary contacts:
    • @mirisuzanne, CSSWG Invited Expert, original proposal author and spec editor.
    • @tabatkins, Google, spec editor.
    • @andruud, Google, working on the feature in Chromium.
  • Organization/project driving the specification: Chromium
  • Multi-stakeholder support³:
  • Status/issue trackers for implementations⁴: https://issues.chromium.org/issues/325504770

Further details:

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions