Problem/Motivation
If you are adding a node that is setup with mercury editor through an inline entity form it would be good if there was a link that took you directly to the mercury editor edit page for that entity.
If the primary method for adding content to an entity setup with mercury editor is through mercury editor itself, than it is presumably not feasible to edit that content inline, instead provide a link directly to the mercury editor page for that piece of content.
This hook is triggered when there is a table of entities in your inline entity form, it won't be triggered or added where there is only a single entity per inline entity form.
A future enhancement for this work would be to provide a configurable option to add this button to the inline entity form table, rather than have it be added automatically.
Proposed resolution
Apply the patch attached to this issue.
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | Screenshot 2025-08-19 at 4.32.52 PM.png | 13.33 KB | joelsteidl |
| #2 | issue-3503726.patch | 3.36 KB | devanbicher |
Issue fork mercury_editor_task-3503726
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
devanbicher commentedPatch to add this requested functionality.
Comment #3
jrockowitz commentedI think we need to create a MercuryEditorTasksInlineEntityForm service for just the preprocess hook.
Comment #6
immaculatexavier commentedComment #7
devanbicher commentedHere are the steps to setup a site to expose this functionality
Comment #9
joelsteidl commented@devanbicher thanks for the detailed setup tasks. That was super helpful for writing a test.
@immaculatexavier thanks for getting the service started. I made an interface and broke up the main function into some additional methods to keep things a bit simpler.
Thoughts/Questions
Comment #10
devanbicher commented@joelsteidl
Comment #11
jrockowitz commentedThe label should be the same across all implementations. I don't think it needs to be configurable for IEF
Comment #12
joelsteidl commented@jrockowitz - I appreciate all the feedback.
I think everything is addressed in Gitlab. Let me know if you see any other issues.
Comment #14
jrockowitz commented