Repository navigation
refactor: remove voice input from default build (v0.11 PR 2/4) - #192
Merged
Merged
Conversation
Drops the Whisper Web Worker from the webpack entry list, removing the 819 KB whisper-worker.js bundle that shipped to every user. Removes the VoiceButton + push-to-talk integration from ChatInput so the bundle drop is real (no orphaned imports). Source preserved per the roadmap: - src/extensions/components/VoiceButton.jsx (400 lines) - src/extensions/services/whisper-worker.js (162 lines) Voice returns in v1.4 as an opt-in Labs feature. Re-enable by: 1. Restoring the whisper-worker entry in webpack.config.js 2. Restoring the VoiceButton import + state in ChatInput.jsx Build verification: build-extensions/whisper-worker.js no longer exists after npm run build. Main bundle size unchanged (the worker shipped as its own entry, not bundled into index.js). Tests: 117 passing, 0 changed. No new tests needed (voice removal is structural; existing ChatInput tests cover the simplified flow). Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
This was referenced May 11, 2026
pluginslab
added a commit
that referenced
this pull request
May 12, 2026
Removes the first batch of parked features per the v1 Roadmap doc: features deemed low-comeback-probability that don't merit code preservation. Deleted: - backup-check (low accuracy — guesses backup plugins by slug) - opcode-cache-status (niche, most admins don't care) - disk-usage (nice-to-have, not essential) - core-editor-blocks (orphaned, only useful if content-generate exists) Total: 7 files removed (3 PHP + 4 JS), ~860 lines of source code. Manifest updates: - Removed entries from PHP and JS labs manifests - Updated manifest.test.js expected labs slug set - Removed bundle references in ability-bundles.js (3 bundles cleaned) - Removed test cases in core-abilities.test.js (3 abilities) - Replaced disk-usage in issue-158.test.js with theme-list - Removed Disk usage e2e conversation test Git history preserves the deleted code (recoverable via `git show v0.10.0:includes/abilities/backup-check.php` etc.) for any future need to consult the implementation. Tests: 117 passing, 0 changed. Build succeeds. Lint: clean (PHP + JS + Prettier). Roadmap context: - PR #191: manifest pattern (merged) - PR #192: voice out of default build (merged) - PR 3a (this): delete 4 simple abilities - PR 3b (next): delete webmcp-bridge - PR 3c (after): delete feedback system - PR 4 (last): flip default to core+local-only; labs requires WP_AGENTIC_ADMIN_ENABLE_LABS Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
pluginslab
added a commit
that referenced
this pull request
May 12, 2026
Last piece of the v0.11 strip-down. Labs (parked) abilities now require
opt-in to be registered, completing the WordPress.org submission path.
PHP — includes/abilities-manifest.php:
resolve_enabled_abilities() now gates the labs array on the
WP_AGENTIC_ADMIN_ENABLE_LABS constant. The wp_agentic_admin_enabled_abilities
filter remains the per-ability override path:
define( 'WP_AGENTIC_ADMIN_ENABLE_LABS', true ); // all labs
add_filter( 'wp_agentic_admin_enabled_abilities', ... ); // selective
New helper: wp_agentic_admin_labs_enabled() — single source of truth
for the boolean.
PHP — includes/class-admin-page.php:
Localizes two new fields on window.wpAgenticAdmin:
- enabledAbilities: PHP-resolved slug list (the result of the
filter above)
- enableLabs: bool, mirrors wp_agentic_admin_labs_enabled()
PHP becomes authoritative for which PHP-backed abilities the JS
manifest registers.
JS — src/extensions/abilities/manifest.js:
New JS_ONLY_ABILITIES set captures the slugs that have no PHP
register function (current-user-role, core-site-info, core-environment-info,
codebase-index, code-search, wp-config-list, content-generate).
PHP's enabledAbilities list can't include these, so JS adds them
back. Members that are also LABS are gated by enableLabs.
JS — src/extensions/abilities/index.js:
registerAllAbilities() now delegates slug resolution to a new
exported resolveEnabledSlugs() function:
- With PHP-localized enabledAbilities: register that list ∪
(JS_ONLY_ABILITIES minus labs-when-off)
- Without (tests / dev): register all REGISTRARS minus LABS
unless enableLabs is set
Falls back gracefully when window.wpAgenticAdmin is unset, so
Jest tests don't have to mock the global.
Tests:
- manifest.test.js: 2 new cases covering JS_ONLY_ABILITIES contract
- index.test.js (new file, 6 cases): PHP-authoritative path with
labs on/off, empty PHP list edge case, fallback path with and
without enableLabs
PHP smoke verification (manual):
Without constant: 33 abilities resolved (CORE + LOCAL_ONLY)
With constant: 39 abilities resolved (+6 labs)
Tests: 124 passing (was 117, +7 new).
Build: clean.
Lint: clean (PHP + JS + Prettier).
Roadmap context — END OF v0.11 STRIP-DOWN:
- PR #191: manifest pattern ✅ merged
- PR #192: voice out of default build ✅ merged
- PR #193: delete 4 simple abilities (open)
- PR #194: delete webmcp-bridge (open)
- PR #195: delete feedback system (open)
- PR 4 (this): flip default to core+local-only
After all six merge: ~3,800 LoC removed, 819 KB shipped bundle
dropped, 35 PHP abilities registered by default (down from 39),
plugin ready for WP.org submission (modulo the remaining 6 security
+ 6 compliance issues from the roadmap).
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Second of four PRs implementing the v0.11 strip-down strategy from the v1 Roadmap doc. Drops the 819 KB Whisper Web Worker bundle from the default build by removing the webpack entry, and removes the VoiceButton + push-to-talk integration from `ChatInput` so the bundle drop is real (no orphaned imports).
Independent of PR #191 — can be reviewed/merged in either order.
What's removed
What's preserved (per the doc's "park, don't delete" intent)
Voice returns in v1.4 as an opt-in Labs feature:
To re-enable: restore the `whisper-worker` webpack entry + restore the VoiceButton import / state in `ChatInput.jsx`. A breadcrumb comment in `webpack.config.js` points future devs at the relevant paths.
Verification
Roadmap context
Test plan
🤖 Generated with Claude Code