In the desktop UI, you can link to specific statement groups and statements, using the property ID or statement ID in the URL hash:
- https://www.wikidata.org/wiki/Q42#P735
- https://www.wikidata.org/wiki/Q42#Q42$1d7d0ea9-412f-8b5b-ba8d-405ab9ecf026
We should also support this in MEX / wbui2025.
Design:
Figma link
Acceptance criteria
- Loading a URL with a property ID in the hash scrolls to that statement group
- Loading a URL with a statement ID in the hash scrolls to that statement
- The selected statement or statement group is visually highlighted with a border-width-thick (codex name) in color.blue700
Notes
- We probably want to support this via HTML id= attributes (scroll) and CSS :target selectors (highlight), without any JavaScript
- We probably don’t need any special handling for “invalid” URLs (no such property or statement on this item), at least not as part of this task
- Generating these URLs is also not in scope for this task
- See also T414456: [MEX2] Support deep-linking to edit modals inside MEX, which is about linking to the edit state (this task is about the “view” state)
