Remove Enable AI header toggle - #985
Conversation
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Unlinked AccountsThe following contributors have not linked their GitHub and WordPress.org accounts: @manueldiaz2006t-blip. Contributors, please read how to link your accounts to ensure your work is properly credited in WordPress releases. If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #985 +/- ##
==========================================
Coverage 75.55% 75.55%
Complexity 3381 3381
==========================================
Files 138 138
Lines 13081 13081
==========================================
Hits 9883 9883
Misses 3198 3198
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
What?
Closes #600
Removes the
Enable AIheader toggle from the AI settings page (routes/ai-home/stage.tsx), cleans up remainingglobalEnabledUI disabling logic, and allows individual feature and experiment group toggles to directly control plugin functionality.Why?
The
Enable AIheader toggle displayed a binary ON/OFF state that did not accurately reflect individual feature configurations. Per maintainer consensus in #600, this PR removes the global header toggle entirely, allowing individual feature toggles and category group toggles (or deactivating the plugin / using core filters) to manage functionality.How?
Enable AIheader<ToggleControl>andInfoTipfromroutes/ai-home/stage.tsx.globalToggleDescription,GLOBAL_FIELD_ID,noop, andDisabledTogglecomponent fromstage.tsx.globalEnabledprop and conditions fromSectionActionsandVisualCardToggleinstage.tsx, ensuring individual toggles and bulk action buttons remain interactive..ai-showcase-card--disabledCSS rule fromroutes/ai-home/style.scss.is_globally_enabled()inincludes/Abstracts/Abstract_Feature.phpto default totruewhen option is not explicitly set.tests/e2e/utils/helpers.ts) indisableExperimentsandenableExperimentsto wait for section action buttons to render before counting, correctly capture settings save responses, and toggle showcase cards.tests/e2e/specs/admin/settings.spec.jsto assert section button states and removed the obsolete test for disabled global bulk actions.Use of AI Tools
AI assistance: Yes
Tool(s): Antigravity
Model(s): Gemini 2.5 Pro
Used for: Diagnosing E2E test failures, updating settings UI components and E2E test assertions, and structuring the PR according to repository guidelines.
Testing Instructions
options-general.php?page=ai-wp-admin).Enable AIheader toggle.npm run typecheck,npm run lint:js, andnpm run buildpass without errors.Screenshots or screencast
Changelog Entry