Repository navigation
fix(settings): preserve multiline proxy bypass rules - #20957
Hidden character warning
AmethystLiang merged 1 commit into
Conversation
There was a problem hiding this comment.
✅ No new issues found.
Reviewed changes
- Multiline bypass-rules control —
AdvancedNetworkSettingsSection.tsxswaps the bypass-rulesInputfor theTextareaprimitive (rows={3}) and drops theonKeyDownEnter-to-blur handler, so pasted newline-separated hosts survive the browser's single-line flattening. The blur-timenormalizeProxyBypassRulespath (split on[;,\n], join with;) and the existing comma/semicolon/newline helper text are unchanged, so this is a UI-only fix. - Component interaction test — new
AdvancedNetworkSettingsSection.interaction.test.tsxpins the blur canonicalization (localhost\n127.0.0.1\n*.internal.corp→localhost;127.0.0.1;*.internal.corp) and that Enter keeps focus without committing. Both assertions fail against the oldInputimplementation, so they are real regression coverage rather than theatre. - SSR markup test —
AdvancedNetworkSettingsSection.test.tsasserts the control renders as<textarea id="settings-http-proxy-bypass-rules">and includes each host, which would also fail on the single-line input. - Electron E2E — new
tests/e2e/network-proxy-bypass-rules.spec.tsdoes a full fill/blur/persist round-trip throughwindow.api.settings, and restores the original persisted value in afinallyblock.
grep confirms this is the only proxy-bypass-rules edit site in the renderer, the canonicalization function was not touched, no i18n strings changed, and no other test/snapshot expects an Input here. I ran the focused vitest selection (16 tests passed) and pnpm run check:code-quality:changed (0 new findings across the 4 changed files).
DeepSeek Flash (free via Pullfrog for OSS) | 𝕏
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (4)
Included review availability: Your plan provides up to 10 included reviews per hour; 5 remain after this review. 📝 WalkthroughWalkthroughThe proxy bypass rules control changed from a single-line input to a three-row textarea. Enter now inserts a newline without blurring or committing settings. Blur still canonicalizes newline-separated rules to semicolon-separated values. Component, server-rendering, interaction, and end-to-end tests cover the new behavior. Priority: ⬇️ Low Merge Risk: ⚪ Minimal · up to The multiline proxy bypass setting retains canonicalized persistence on blur and has targeted component and end-to-end coverage. No current merge-blocking risk is identified. 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
Full details: Description checkExplanation The description explains the change and lists validation commands, but it omits most required template sections. It also lacks the required visual proof for a UI behavior change and uses "Refs STA-7336" instead of the required linked-issue format. Resolution Add the required ELI5, What Changed, Why, Linked Issue, Visual Proof, Testing, Review, Agent skill upstream boundary, Notes, and Checklist sections. Include before-and-after screenshots or a video, document manual testing and supported platforms, use the required linked issue format such as "Fixes #...", and complete the applicable checklist items.
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |

Summary
Validation
pnpm test src/renderer/src/components/settings/AdvancedNetworkSettingsSection.test.ts src/renderer/src/components/settings/AdvancedNetworkSettingsSection.interaction.test.tsx src/shared/network-proxy.test.tsORCA_BACKGROUND_LAUNCH=1 npx playwright test tests/e2e/network-proxy-bypass-rules.spec.ts --config tests/playwright.config.ts --project=electron-headless --workers=1pnpm run check:code-quality:changedRefs STA-7336