Admin UI: Remove model/provider fields from AI step config modal - #889
Merged
Merged
Conversation
Contributor
Homeboy Results —
|
…erything else is context-managed Resolves #888. The AI step configuration modal is now fully redundant: - Model/provider: managed by context_models setting (#886/#887) - Tools: managed by ToolPolicyResolver context system - System prompt: already editable inline on the step card via PromptField Changes: - ConfigureStepModal: gutted to no-op (auto-closes if triggered) - PipelineStepCard: removed tools display, removed Configure button, removed onConfigure prop. Only inline system prompt remains. - PipelineCard: removed handleStepConfigured callback - PipelineSteps: removed onConfigure prop passthrough - api.js: removed disabledTools from updateSystemPrompt - pipelines.js: removed disabledTools from mutation 6 files changed, -284 net lines.
chubes4
force-pushed
the
fix/admin-ui-remove-model-provider-fields
branch
from
March 20, 2026 15:49
39f5e03 to
d10e506
Compare
chubes4
added a commit
that referenced
this pull request
Apr 24, 2026
Removes unambiguously dead code across the Pipelines / Logs React surface. No behavioural change. Two categories: ## Dead imports Modules imported but never referenced by any expression in the same file. `wp-scripts lint-js` surfaces these as `no-unused-vars`; each was manually verified by grepping the file for the symbol. - HandlerSettingsModal.jsx — `Notice`, `Spinner`, `FilesHandlerSettings` (the latter is dead because the modal dispatches via `handlerModel.renderSettingsEditor()` and routes the Files custom editor through the model's own import, not the modal's). - FlowFooter.jsx — `Button` - ImportExportModal.jsx — `useState` - AIToolsSelector.jsx — `useState` (orphan file, deleted below) - ModalManager.jsx — `useQueryClient` - ModalSwitch.jsx — `Modal`, `Button`, `__` - HandlerProvider.jsx — `useHandlerDetails` - LogsAgentTabs.jsx — `AGENTS_KEY` - queries/flows.js — `updateUserMessage` (re-import of utils/api) - queries/pipelines.js — `updatePipelineTitle`, `reorderPipelineSteps`, `updateSystemPrompt` (same pattern — consumers import these directly from utils/api, the queries/ re-imports were never used) Also removed the dead local `handlerDetailsError = null` in HandlerSettingsModal which flowed from a TanStack Query refactor that dropped the error state. ## Dead feature: ConfigureStepModal + configure-step/ PR #889 gutted the AI step config modal — system prompt is now edited inline via PromptField, everything else is context-managed. The modal was left as a no-op auto-closer and its child components were left as orphan files. Nothing ever triggers the `MODAL_TYPES.CONFIGURE_STEP` route: - ConfigureStepModal.jsx — deleted (21-line no-op auto-closer) - configure-step/AIToolsSelector.jsx — deleted - configure-step/ConfigurationWarning.jsx — deleted - configure-step/ToolCheckbox.jsx — deleted - modals/index.js — dropped `ConfigureStepModal` re-export - shared/ModalSwitch.jsx — dropped import + case - utils/constants.js — dropped `MODAL_TYPES.CONFIGURE_STEP` - PipelinesFilters.php — dropped the two now-stale JS comments pointing at `ConfigureStepModal` / `AIToolsSelector` from the preloaded script-data payload doc The three PHP step classes (AIStep, WebhookGateStep, SystemTaskStep) still declare `stepSettings.modal_type => 'configure-step'` in their step descriptors. That metadata is never read by the React side — it's vestigial documentation on the PHP side — so it's left for a separate step-registration cleanup to avoid mixing PHP contract changes into a JS dead-code PR. ## Not touched Unused function parameters (e.g. `pipelineConfig` in FlowStepCard, `onStepConfigured` in PipelineSteps, `flowId` in HandlerSettingsModal) are intentionally left alone. Some have explicit 'retained' comments, others are part of callback signatures whose prop-drilling parents would need touching too. Candidates for a follow-up pass. Net: 16 files changed, 275 lines deleted, 3 inserted.
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
ProviderModelSelectorfrom the AI step configuration modalprovider/modelfrom form state, validation, API calls, and inline displayBefore
The AI step modal had 4 sections: provider dropdown, model dropdown, tools selector, system prompt. The provider/model were sent in PUT requests but the backend now ignores them.
After
The modal has 2 sections: tools selector and system prompt. No provider/model fields, no dead API params.
The
ProviderModelSelectorshared component is not deleted — it lives in@shared/components/ai/and may be used by other admin pages. It's just no longer imported by the pipeline step modal.Files
ConfigureStepModal.jsxPipelineStepCard.jsxapi.jsupdateSystemPrompt()paramspipelines.jsDepends on #887 being merged first (backend).