Conversation
There was a problem hiding this comment.
Pull request overview
Refactors the launcher content-script structure and build configuration for the Chrome extension.
Changes:
- Renames/splits launcher entrypoints in
webpack.config.cjs(homepage vs shortcut launcher scripts). - Moves launcher CSS into
src/content/modules/launcher/launcher_styles.cssand updates build copy patterns. - Adjusts relative imports in launcher content scripts after file moves.
Reviewed changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
webpack.config.cjs |
Updates webpack entries/copy patterns; adds performance hints suppression. |
src/content/modules/launcher/launcher_styles.css |
Adds module-scoped launcher styling (including Ctrl+K overlay styles). |
src/content/modules/launcher/launch_shortcut.ts |
Updates imports for new module location. |
src/content/modules/launcher/launch_homepage.ts |
Updates imports for new module location. |
Comments suppressed due to low confidence (2)
webpack.config.cjs:24
- The
contententry was removed/renamed, but the background injector still executescontent.js(seesrc/background/events/injects/launcher.ts:13). With the current entries, the build will no longer emitdist/content.js, so the launcher inject on the homepage will fail at runtime. Reintroduce acontententry (aliasing the new homepage launcher script) or update the injector to loadlauncher_homepage.js.
entry: {
popup: "./src/popup/popup.ts",
background: "./src/background/background.ts",
launcher_homepage: "./src/content/modules/launcher/launch_homepage.ts",
launcher_shortcut: "./src/content/modules/launcher/launch_shortcut.ts",
get_textbooks: "./src/content/modules/launcher/getters/get_textbooks.ts",
inject_css_tools: "./src/content/inject_css_tools.ts",
news_search_main: "./src/content/modules/news_search/news_search.ts",
display_history: "./src/content/modules/post_history_tracking/content.ts",
src/content/modules/launcher/launch_shortcut.ts:3
launcheris imported but never used. Keeping this import also risks bundling background-only code (that useschrome.scripting) into the content-script bundle unnecessarily. Remove the unused import.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
🎉 This PR is included in version 1.1.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
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.
Do things yes
💤