I'm trying to customize the SiteEdit menu bar and component toolbar, enabling only inline editing and publishing. I can enable/disable just about any of the buttons successfully, except the one called 'Add component', the one that has a submenu item. Here is my current config section:
...
<Page Visible="true">
<Edit Visible="false" />
<AddNew Visible="false" />
<Publish Visible="true" />
<Unpublish Visible="true" />
<Localize Visible="false" />
<Unlocalize Visible="false" />
</Page>
<Component Visible="true">
<Edit Visible="false" />
<EditParent Visible="false" />
<AddNew Visible="false" />
<AddExisting Visible="false" />
<ChangeTemplate Visible="false" />
<Remove Visible="true" />
<Publish Visible="true" />
<Unpublish Visible="true" />
<Localize Visible="false" />
<Unlocalize Visible="false" />
<StartActivity Visible="false" />
<FinishActivity Visible="false" />
</Component>
...
If I change the 'AddNew' and 'AddExisting' inside the Component section back into 'true', all is fine...
This is the javascript error I'm getting, in Menu.js on line 50:
TypeError: parentMenuItem is undefined
var menuItems = parentMenuItem.Items;
Any ideas as to what could cause this?