Utility-First Class Classifier Note
Audit exact caller framework/version utility registry, no utility-first identity inferred from class spelling or generated CSS availability. Explicit supplied computed/layout context only; not a browser cascade/layout engine or cross-browser guarantee.
Description
Utility classification requires a defined registry of independently recognized class tokens.
Utility classification requires a defined registry of independently recognized class tokens.1
Registry membership does not prove that a class has a particular CSS effect. Use Utility-First Class Classifier Note to evaluate the supplied inputs under the specific model below.
When to use Utility-First Class Classifier Note
Use Utility-First Class Classifier Note to evaluate the supplied inputs under the specific model below. Define the supplied layout, token or rendering scenario and establish the relevant units and browser context independently.
How to use Utility-First Class Classifier Note and understand its results
- Define the supplied layout, token or rendering scenario and establish the relevant units and browser context independently.
- Enter Class tokens, Caller independently verified utility tokens using the field table and validation rules below, then run the tool.
- Read Caller utility flags, Unclassified tokens and interpret units, signs, ordering and placeholders as explained below.
- If the tool reports an input error, correct that field and rerun. A successful false result, empty match list or unknown-evidence placeholder has the specific meaning described here; check the limitations before applying the result.
| Input field | Meaning | Value type | Requirement |
|---|---|---|---|
| classTokens | Class tokens | array of string | Required; constraints below |
| callerIndependentlyVerifiedUtilityTokens | Caller independently verified utility tokens | array of string | Required; constraints below |
Enter a nonempty registry of unique nonblank utility tokens and the class-token array to examine. Return a binary membership flag for each examined token and an unclassified list preserving its original order and repetitions. Tokens are compared exactly; there is no stylesheet inspection, inferred naming scheme or automatic utility definition.
flag[i] = registeredUtilities includes classToken[i]; unclassified = tokens with flag 0 Field order, units and branch conditions follow the implementation explanation above.
| Output field | Meaning | Value type |
|---|---|---|
| callerUtilityFlags | Caller utility flags | array of number |
| unclassifiedTokens | Unclassified tokens | array of string |
{
"input": {
"classTokens": [
"p-4",
"button",
"text-sm"
],
"callerIndependentlyVerifiedUtilityTokens": [
"p-4",
"text-sm"
]
},
"output": {
"callerUtilityFlags": [
1,
0,
1
],
"unclassifiedTokens": [
"button"
]
}
} Limitations and assumptions
Registry membership does not prove that a class has a particular CSS effect. Apply the exact scope and assumptions described above.
All listed fields require explicit values. Unexpected fields, incorrect types, nonfinite numbers and sparse arrays fail validation. Domain-specific bounds, alignments and supported tokens are stated above; extremely large inputs or outputs can also be rejected. These errors differ from successful results such as false, no matches or unknown evidence.
Alternative or Complementary methods
Use Pseudo-Class State Targets Table for a related task: Pseudo-classes select elements under defined states or conditions.
Use Attribute Selector case Flag [i] Lookup for a related task: Attribute equality can use explicit case-sensitive or ASCII-insensitive comparison.
References
-
Utility-First Class Classifier Note — tool.io
Similar or alternative tools
- Pseudo-Class State Targets Table
Pseudo-classes select elements under defined states or conditions.
- Attribute Selector case Flag [i] Lookup
Attribute equality can use explicit case-sensitive or ASCII-insensitive comparison.