Edit component missing in Channel Manager

After placing a component in a container (node type hst:containercomponent), I was unable to find or access the “edit dialog” for the component despite it existing and rendering content to the page preview.

There was no errors logged in either CMS or site log files.

How do I troubleshoot this? And how do I resolve this?

Troubleshooting:
Did not find anything pertinent in https://documentation.bloomreach.com/library/concepts/channels/channel-manager-troubleshooting.html

Increasing log levels in localhost resulted in large logs with no relevant data when opening the page in the channel manager.

I accidentally found the solution by having a “Switch Template” and changing the component’s template via JCR console. One template would allow me to get the blue box with my component name & open the edit component dialog while the other mysteriously didn’t show any component outlines. Therefore, I isolated the problem to one of the FTL templates.

Comparing Templates:

  • one started with header <h2>My Header</h2> => blue outline surrounded only the header
  • the problem template had a <script>...</script> block before visible markup
  • the last template had a wrapper <div>...</div> around the entire component => blue outline surrounded the entire component in the Channel Manager
  • further experimentation proved <@hst.headContribution>...</@hst.headContribution> is safe for “invisible” HTML elements. (wrap style/script blocks with hst:headContribution tags)

Conclusion: if a component renders in channel manager but doesn’t have a clickable “edit component” area, examine the template for the first HTML element - it should be visible to give a hover area & edit click functionality.

Your problem may have been wrong use of the ‘NoMarkup’ container xtype. See https://documentation.bloomreach.com/library/concepts/template-composer/channel-editor-containers.html#using-the-nomarkup-type for a detailed explanation.

hth,

Mathijs