The callback is confusingly named `propertyNamesCallback()` and has a `names` argument.
The payload is actually a list of objects with CSS property names, values, aliases, longhands, etc.
The constructor of `WI.CSSCompletions` expects and handles this payload.
Seems like `WI.CSSCompletions` began life handling just CSS property names, but overtime got overloaded to support additional use cases.
For example, `WI.CSSCompletions` ends up having an instance of itself assigned as a property o_O:
WI.CSSCompletions.cssNameCompletions = new WI.CSSCompletions(properties, false);
There's a bit of confusing ping-pong between `WI.CSSCompletions` and `WI.CSSKeywordCompletions`.
But that's a fix for another patch.
Created attachment 437875 [details]
Comment on attachment 437875 [details]
View in context: https://bugs.webkit.org/attachment.cgi?id=437875&action=review
> + function propertiesCallback(error, properties)
NIT: this should really be named `cssProperties` to match what's used in the protocol
Created attachment 438046 [details]
Carry over R+
Committed r282360 (241623@main): <https://commits.webkit.org/241623@main>
All reviewed patches have been landed. Closing bug and clearing flags on attachment 438046 [details].