=== AC
[X] Add wikidata link to overflow menu (above the "Cite page" link)
[X] Selecting the wikidata item link will navigate to the wikidata item page
[X] If no wikidata item is available, the link should not appear
=== Dev notes
- Link should look something like: https://www.wikidata.org/wiki/Q5296
- Use the Sidebar toolbox link injected via `BaseTemplateToolbox` hook
- There's no need for additional feature flagging. We're not planning on enabling AMC on wikidatawiki any time soon so there's no need to worry about Wikidata entities linking to themselves right now
- See T222630#5167983 for a note on setting up a development environment
=== Sign off notes
[] The code shouldn't rely on Wikibase classes/hooks in any way. It can use only links injected into the Template object.
=== Design
{F29353103}
=== QA Instructions
==== Test when Wikidata link in not in menu
- Login and enable AMC mode on https://en.m.wikipedia.beta.wmflabs.org
- Go to https://en.m.wikipedia.beta.wmflabs.org/wiki/Abraham_Lincoln
- Click on the three dot overflow menu
- This page does not have a corresponding wikidata item so ensure there is NOT a "Wikidata item" link anywhere in the overflow menu.
==== Test when Wikidata link is in menu
- Login and enable AMC mode on https://en.m.wikipedia.beta.wmflabs.org
- Go to https://en.m.wikipedia.beta.wmflabs.org/wiki/Barack_Obama
- Click on the three dot overflow menu
- Ensure there is a "Wikidata item" link, and it is placed above the "Cite page" link
- Click on the link and ensure it goes to the "Barack Obama" wikidata page