Override plugin ADMIN views from theme or plugin?

I’m trying to add some additional formatting options to the TinyMCE editor on Exhibit Builder’s page edit forms. I’ve been able to do so by adding formats to the Omeka.wysiwyg call in

I’d rather not hack on the core plugin, however, and am trying to override. I know you can override public views from the theme, but this is an admin view.

I do already have a custom plugin overriding a shared view to add an exhibit builder layout, and I’ve tried to add a copy of admin/exhibits/page-form.php to this but it is not being picked up automatically as it would with a public theme override.

Do I need to add a hook in the plugin to pick this up? Or do I just need to hack the Exhibit Builder itself to make this happen?

Thanks for your help!

I think you could do this via a plugin that uses the admin_head hook. That’ll let you insert javascript that should change the configuration options used by TinyMCE (I haven’t tested that myself, though). Without a little more extra work, that would apply to all admin pages, but it’s not too much more to check whether it’s an EB page before making the change.

Thanks for the pointer Patrick. I’ll check it out and report back what I find.

You were right, Patrick. I was able to get this to work with an admin_head hook, and I seem to be able to target specific pages checking the view object just fine.

While it works as intended on exhibit edit views, where I really want it to work is on exhibit_page edit forms and here it has a quirk. New blocks added through the dialogue receive the additional formats as desired, but the edit form on blocks that are already in the page do not… Could this be due to the order of scripts (and therefore calls to Omeka.wysiwyg) in the head?

Here’s the code in my included js file. Thanks!

jQuery(window).load(function() {

      theme_advanced_buttons2: "styleselect",
      style_formats: [{
          title: 'Highlight1 - gray w/bar',
          inline: 'span',
          classes: 'medium-block-1'