TGMPA / TGM-Plugin-Activation

TGM Plugin Activation is a PHP library that allows you to easily require or recommend plugins for your WordPress themes (and plugins). It allows your users to install, update and even automatically activate plugins in singular or bulk fashion using native WordPress classes, functions and interfaces. You can reference bundled plugins, plugins from the WordPress Plugin Repository or even plugins hosted elsewhere on the internet.
http://tgmpluginactivation.com/
GNU General Public License v2.0
1.75k stars 431 forks source link

Allow add_submenu_page for WordPress.org themes via Generator #794

Open acosmin opened 3 years ago

acosmin commented 3 years ago

@jrfnl We've started allowing add_menu_page & add_submenu_page in themes on wp.org and we've noticed that parent_slug uses only add_theme_page via TGMPA Generator. This piece of code https://github.com/TGMPA/TGM-Plugin-Activation/blob/2d34264f4fdcfcc60261d490ff2e689f0c33730c/class-tgm-plugin-activation.php#L740-L742 should be allowed now. I guess the Generator needs to be changed.

Thank you!

jrfnl commented 3 years ago

@acosmin Ripping that out via the generator was done at the explicit request of the wp.org Theme team, so yes, if you now want to start allowing it, the generator will need to be updated. PRs welcome.

acosmin commented 3 years ago

Sure :) could you please point me to the Generator repo?

acosmin commented 3 years ago

I think I found it :) https://github.com/TGMPA/TGM-Plugin-Activation/blob/gh-pages/js/tgmpa.js I'll take it for a spin