Found while implementing objectui#8434 (a user reference that resolved to nothing rendered as a person). Filed rather than fixed there: that card's fix is confined to packages/fields, and correcting this would pull @object-ui/core into its published-source set for a comment-only edit.
The false claim
packages/core/src/utils/expand-fields.ts, in the docblock over EXPANDABLE_FIELD_TYPES:
* `user` is a lookup specialised to `sys_user`: it carries the same `reference`
* + id storage and the server resolves it through the same expand path as
* `lookup` / `master_detail`, so a `user` column that is NOT requested for
* expansion comes back as a raw user id and renders as "—" (objectui#2032).
The last clause is wrong and has been for as long as UserCellRenderer has existed. Measured on da5e4f69e by rendering getCellRenderer('user') against three unexpanded primitives:
| value |
what UserCellRenderer actually rendered |
'u_1' |
span class="block max-w-full truncate" title="u_1" containing u_1 |
'01HQZX9K2M4N6P8R' |
the same span, containing the raw ULID |
'Ada Lovelace' |
the same span, containing the raw string |
No em-dash, no muted treatment, nothing. UserCellRenderer has no resolver at all — no useLookupName, no isLikelyOpaqueId. The "—" behaviour the comment describes belongs to LookupCellRenderer, which does have both, and which returns a muted em-dash only for values that pass isLikelyOpaqueId.
Why it matters
This docblock is the argument for user being a member of EXPANDABLE_FIELD_TYPES, and the set is read by at least eight consumers (the docblock enumerates them). A reader reasoning about "what happens if a user column is not expanded" is told the UI degrades visibly. It did not — it printed the id as if it were a name, which is exactly the defect objectui#8434 was opened for. The false sentence is plausibly part of why nobody looked.
After objectui#8434
That card changes the answer again: an unexpanded user id now renders the unresolved-reference affordance (raw value kept, plus a stated sentence). So the clause is wrong both before and after, in different ways, and needs rewriting either way. lookup / master_detail / tree are unchanged and still behave as the "—" clause describes, for opaque-id-shaped values only.
Suggested scope
Correct the one clause to say what each family does, or drop the rendering claim entirely and keep the storage claim, which is the part the set actually depends on. Comment-only; no behaviour.
Generated by Claude Code
Found while implementing objectui#8434 (a
userreference that resolved to nothing rendered as a person). Filed rather than fixed there: that card's fix is confined topackages/fields, and correcting this would pull@object-ui/coreinto its published-source set for a comment-only edit.The false claim
packages/core/src/utils/expand-fields.ts, in the docblock overEXPANDABLE_FIELD_TYPES:The last clause is wrong and has been for as long as
UserCellRendererhas existed. Measured onda5e4f69eby renderinggetCellRenderer('user')against three unexpanded primitives:UserCellRendereractually rendered'u_1'span class="block max-w-full truncate" title="u_1"containingu_1'01HQZX9K2M4N6P8R''Ada Lovelace'No em-dash, no muted treatment, nothing.
UserCellRendererhas no resolver at all — nouseLookupName, noisLikelyOpaqueId. The"—"behaviour the comment describes belongs toLookupCellRenderer, which does have both, and which returns a muted em-dash only for values that passisLikelyOpaqueId.Why it matters
This docblock is the argument for
userbeing a member ofEXPANDABLE_FIELD_TYPES, and the set is read by at least eight consumers (the docblock enumerates them). A reader reasoning about "what happens if ausercolumn is not expanded" is told the UI degrades visibly. It did not — it printed the id as if it were a name, which is exactly the defect objectui#8434 was opened for. The false sentence is plausibly part of why nobody looked.After objectui#8434
That card changes the answer again: an unexpanded
userid now renders the unresolved-reference affordance (raw value kept, plus a stated sentence). So the clause is wrong both before and after, in different ways, and needs rewriting either way.lookup/master_detail/treeare unchanged and still behave as the"—"clause describes, for opaque-id-shaped values only.Suggested scope
Correct the one clause to say what each family does, or drop the rendering claim entirely and keep the storage claim, which is the part the set actually depends on. Comment-only; no behaviour.
Generated by Claude Code