v2.2.0: includes/Core/AdminMenu.php

This commit is contained in:
2026-05-29 12:44:12 +00:00
parent 4003325420
commit 0704ac02a6
+44
View File
@@ -696,6 +696,50 @@ class AdminMenu {
'elementor_templates'=>['label'=>'Elementor — Templates','tools'=>['elementor_save_as_template'=>['label'=>'Save as Template','description'=>'Saves the current page content as a reusable Elementor template.','badges'=>['write','elementor']],'elementor_apply_template'=>['label'=>'Apply Template','description'=>'Applies a saved template to a target page.','badges'=>['write','elementor']],'elementor_list_templates'=>['label'=>'List Templates','description'=>'Lists all saved Elementor templates.','badges'=>['read','elementor']]]], 'elementor_templates'=>['label'=>'Elementor — Templates','tools'=>['elementor_save_as_template'=>['label'=>'Save as Template','description'=>'Saves the current page content as a reusable Elementor template.','badges'=>['write','elementor']],'elementor_apply_template'=>['label'=>'Apply Template','description'=>'Applies a saved template to a target page.','badges'=>['write','elementor']],'elementor_list_templates'=>['label'=>'List Templates','description'=>'Lists all saved Elementor templates.','badges'=>['read','elementor']]]],
'elementor_global'=>['label'=>'Elementor — Global Settings','tools'=>['elementor_get_global_colors'=>['label'=>'Get Global Colors','description'=>'Returns the site-wide Elementor color palette.','badges'=>['read','elementor']],'elementor_set_global_color'=>['label'=>'Set Global Color','description'=>'Updates a specific global color in the Elementor palette.','badges'=>['write','elementor']],'elementor_get_global_fonts'=>['label'=>'Get Global Fonts','description'=>'Returns the global typography presets.','badges'=>['read','elementor']],'elementor_get_kit_settings'=>['label'=>'Get Kit Settings','description'=>'Returns the full Elementor kit/site settings.','badges'=>['read','elementor']],'elementor_update_kit_settings'=>['label'=>'Update Kit Settings','description'=>'Updates Elementor kit/site settings.','badges'=>['write','elementor']]]], 'elementor_global'=>['label'=>'Elementor — Global Settings','tools'=>['elementor_get_global_colors'=>['label'=>'Get Global Colors','description'=>'Returns the site-wide Elementor color palette.','badges'=>['read','elementor']],'elementor_set_global_color'=>['label'=>'Set Global Color','description'=>'Updates a specific global color in the Elementor palette.','badges'=>['write','elementor']],'elementor_get_global_fonts'=>['label'=>'Get Global Fonts','description'=>'Returns the global typography presets.','badges'=>['read','elementor']],'elementor_get_kit_settings'=>['label'=>'Get Kit Settings','description'=>'Returns the full Elementor kit/site settings.','badges'=>['read','elementor']],'elementor_update_kit_settings'=>['label'=>'Update Kit Settings','description'=>'Updates Elementor kit/site settings.','badges'=>['write','elementor']]]],
'elementor_query'=>['label'=>'Elementor — Query & Discovery','tools'=>['elementor_list_widgets'=>['label'=>'List Widgets','description'=>'Lists all widget types and names on a page.','badges'=>['read','elementor']],'elementor_get_element'=>['label'=>'Get Element','description'=>'Returns settings of a specific element by ID.','badges'=>['read','elementor']],'elementor_clone_page'=>['label'=>'Clone Page','description'=>'Clones an Elementor page to a new post.','badges'=>['write','elementor']],'elementor_replace_text'=>['label'=>'Replace Text','description'=>'Bulk-replaces text content across all widgets on a page.','badges'=>['write','elementor']],'elementor_get_page_outline'=>['label'=>'Get Page Outline','description'=>'Returns a simplified structural outline of an Elementor page.','badges'=>['read','elementor']]]], 'elementor_query'=>['label'=>'Elementor — Query & Discovery','tools'=>['elementor_list_widgets'=>['label'=>'List Widgets','description'=>'Lists all widget types and names on a page.','badges'=>['read','elementor']],'elementor_get_element'=>['label'=>'Get Element','description'=>'Returns settings of a specific element by ID.','badges'=>['read','elementor']],'elementor_clone_page'=>['label'=>'Clone Page','description'=>'Clones an Elementor page to a new post.','badges'=>['write','elementor']],'elementor_replace_text'=>['label'=>'Replace Text','description'=>'Bulk-replaces text content across all widgets on a page.','badges'=>['write','elementor']],'elementor_get_page_outline'=>['label'=>'Get Page Outline','description'=>'Returns a simplified structural outline of an Elementor page.','badges'=>['read','elementor']]]],
'file_manager' => ['label' => 'File Manager', 'tools' => [
'fs_list_dir' => ['label'=>'List Directory', 'description'=>'List files and folders in the uploads directory. Sandboxed to /wp-content/uploads/.', 'badges'=>['read']],
'fs_read_file' => ['label'=>'Read File', 'description'=>'Read a file from uploads. Returns text or base64 for binary files.', 'badges'=>['read']],
'fs_delete_file' => ['label'=>'Delete File', 'description'=>'Delete a file from the uploads directory.', 'badges'=>['write','destructive']],
'fs_delete_dir' => ['label'=>'Delete Directory', 'description'=>'Delete a directory and all its contents from uploads.', 'badges'=>['admin','destructive']],
'fs_uploads_info' => ['label'=>'Uploads Info', 'description'=>'Get uploads base path, URL, and total disk usage.', 'badges'=>['read']],
]],
'email' => ['label' => 'Email', 'tools' => [
'email_send_test' => ['label'=>'Send Test Email', 'description'=>'Send a test email to verify WordPress mail is working.', 'badges'=>['admin']],
'email_get_config' => ['label'=>'Get Email Config', 'description'=>'Get the current WordPress email configuration: admin email, SMTP, active mail plugins.', 'badges'=>['read']],
'email_list_log' => ['label'=>'List Email Log', 'description'=>'List recent emails from WP Mail SMTP log if plugin is active.', 'badges'=>['read']],
]],
'transients' => ['label' => 'Transients', 'tools' => [
'transient_get' => ['label'=>'Get Transient', 'description'=>'Get a WordPress transient value by key.', 'badges'=>['read']],
'transient_set' => ['label'=>'Set Transient', 'description'=>'Set a WordPress transient with optional expiration in seconds.', 'badges'=>['admin']],
'transient_delete' => ['label'=>'Delete Transient', 'description'=>'Delete a WordPress transient by key.', 'badges'=>['admin']],
'transient_list' => ['label'=>'List Transients', 'description'=>'List WordPress transients, optionally filtered by search term.', 'badges'=>['read']],
'transient_flush_expired' => ['label'=>'Flush Expired Transients','description'=>'Delete all expired transients from the database.', 'badges'=>['admin']],
]],
'widgets' => ['label' => 'Widget Areas', 'tools' => [
'widget_list_areas' => ['label'=>'List Widget Areas', 'description'=>'List all registered WordPress widget areas (sidebars).', 'badges'=>['read']],
'widget_get_area' => ['label'=>'Get Widget Area', 'description'=>'Get all widgets in a specific widget area with their settings.', 'badges'=>['read']],
'widget_list_registered' => ['label'=>'List Registered Widgets', 'description'=>'List all registered WordPress widget types.', 'badges'=>['read']],
'widget_update_area' => ['label'=>'Update Widget Area', 'description'=>'Reorder or set the widget list for a widget area.', 'badges'=>['admin']],
'widget_remove' => ['label'=>'Remove Widget', 'description'=>'Remove a specific widget from a widget area.', 'badges'=>['admin']],
]],
'cli' => ['label' => 'WP-CLI', 'tools' => [
'cli_run' => ['label'=>'Run CLI Command', 'description'=>'Run a WP-CLI command (admin). Allowed: cache, cron, media, option, plugin, post, rewrite, theme, transient, user, widget, elementor, wc, yoast.', 'badges'=>['admin']],
'cli_available' => ['label'=>'CLI Available', 'description'=>'Check if WP-CLI is available on the server.', 'badges'=>['read']],
]],
'raw_sql' => ['label' => 'Raw SQL', 'tools' => [
'sql_query' => ['label'=>'SQL Query', 'description'=>'Run a SELECT query against the WordPress database. Must be enabled in Settings.', 'badges'=>['admin']],
'sql_list_tables' => ['label'=>'List Tables', 'description'=>'List WordPress database tables with row count and size.', 'badges'=>['admin']],
'sql_describe_table' => ['label'=>'Describe Table', 'description'=>'Describe the columns of a WordPress database table.', 'badges'=>['admin']],
]],
'theme_discovery' => ['label' => 'Theme Discovery', 'tools' => [
'theme_elementor_support' => ['label'=>'Elementor Theme Support', 'description'=>'Check what Elementor features the active theme supports: full-width, canvas, templates, Pro theme builder.', 'badges'=>['read']],
'theme_widget_areas' => ['label'=>'Theme Widget Areas', 'description'=>'List all widget areas registered by the active theme.', 'badges'=>['read']],
'theme_custom_post_types' => ['label'=>'Custom Post Types', 'description'=>'List all custom post types registered by the theme and plugins, with supports and taxonomies.', 'badges'=>['read']],
'theme_taxonomies' => ['label'=>'Taxonomies', 'description'=>'List all public taxonomies registered by the theme and plugins.', 'badges'=>['read']],
'theme_elementor_tokens' => ['label'=>'Elementor Kit Tokens', 'description'=>'Get Elementor global design tokens: colors with CSS vars, typography presets.', 'badges'=>['read']],
'theme_woodmart_elements' => ['label'=>'WoodMart Elements', 'description'=>'Discover WoodMart custom Elementor widgets, shortcodes, and widget areas. Active only if WoodMart theme is running.', 'badges'=>['read']],
'theme_page_templates' => ['label'=>'Page Templates', 'description'=>'List all page templates from the active theme including Elementor canvas and full-width.', 'badges'=>['read']],
]],
]; ];
} }