I know that the Collections component does this, but I am trying to figure out how to move the content area to its own tab on non-Collections pages.
This post was helpful in how to create a new tab
https://forums.modx.com/thread/?thread=82682 but I can't seem to figure out how to move the modx-content component to the newly created tab.
Revo 2.6.5
Here is the code I have so far in the plugin:
switch ($modx->event->name) {
// Add a custom tab to the MODX create/edit resource pages
case 'OnDocFormPrerender':
$modx->regClientStartupHTMLBlock('<script type="text/javascript">
MODx.on("ready",function() {
Ext.getCmp("modx-resource-tabs").insert(0, {
title: "Custom Tab",
id: "custom-resource-tab",
width: "95%",
});
});
</script>');
}
It feels like I need to put Ext.getCmp("modx-content") in there somewhere, but not sure how.