Skip to content

fix: allow user-defined sidebar_action to override generated fields#2189

Open
djyde wants to merge 1 commit intowxt-dev:mainfrom
djyde:fix/sidebar-action-merge
Open

fix: allow user-defined sidebar_action to override generated fields#2189
djyde wants to merge 1 commit intowxt-dev:mainfrom
djyde:fix/sidebar-action-merge

Conversation

@djyde
Copy link

@djyde djyde commented Mar 11, 2026

Summary

  • Fixed an issue where the sidebar_action manifest field for Firefox was being completely overwritten by WXT, ignoring user-defined configuration from wxt.config.ts
  • User-defined sidebar_action fields now properly override auto-generated values
  • Added test case to verify the merge behavior

Changes

  • Modified packages/wxt/src/core/utils/manifest.ts to spread user-defined sidebar_action configuration after generated fields, allowing user values to take precedence
  • Added test case in packages/wxt/src/core/utils/__tests__/manifest.test.ts to verify user configuration is properly merged

Test Plan

  • All existing tests pass (76 tests)
  • New test case verifies that user-defined fields override generated values
  • Custom fields (like custom_field) are preserved
  • Auto-generated default_panel is still included

@djyde djyde requested a review from aklinker1 as a code owner March 11, 2026 18:04
@netlify
Copy link

netlify bot commented Mar 11, 2026

Deploy Preview for creative-fairy-df92c4 ready!

Name Link
🔨 Latest commit 7aaf025
🔍 Latest deploy log https://app.netlify.com/projects/creative-fairy-df92c4/deploys/69b1aeb4872e02000837307d
😎 Deploy Preview https://deploy-preview-2189--creative-fairy-df92c4.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions github-actions bot added the pkg/wxt Includes changes to the `packages/wxt` directory label Mar 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg/wxt Includes changes to the `packages/wxt` directory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant