Skip to content

build: Migrate to wxt framework#53

Merged
CrawlerCode merged 8 commits intov2from
refactor/migrate-to-wxt
Dec 18, 2025
Merged

build: Migrate to wxt framework#53
CrawlerCode merged 8 commits intov2from
refactor/migrate-to-wxt

Conversation

@CrawlerCode
Copy link
Copy Markdown
Owner

@CrawlerCode CrawlerCode commented Dec 16, 2025

This pull request introduces changes to the build system, browser extension packaging, and some internal APIs, as well as various dependency upgrades and code cleanups. The key improvements are the migration to the wxt tool for building and packaging browser extensions, updates to the release workflows, and the removal of legacy or redundant code.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request migrates the browser extension from a custom Vite-based build setup to the WXT framework, a modern web extension development framework that provides better tooling, type safety, and cross-browser compatibility.

Key Changes:

  • Migration from custom Vite configuration to WXT framework with standardized entrypoints
  • Replacement of direct Chrome API calls with browser-agnostic polyfill from WXT
  • Restructured entrypoint files (background, content, popup, options) to follow WXT conventions

Reviewed changes

Copilot reviewed 37 out of 46 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
wxt.config.ts New WXT configuration file replacing vite.config.ts with manifest generation and build hooks
vite.config.ts Removed legacy Vite configuration in favor of WXT's built-in Vite integration
tsconfig.json Updated to extend WXT's TypeScript configuration and consolidated app/node configs
tsconfig.app.json Removed and merged into main tsconfig.json
tsconfig.node.json Removed and merged into main tsconfig.json
package.json Updated build scripts to use WXT CLI and bumped dependencies to newer versions
src/entrypoints/background.ts New background script using WXT's defineBackground with runtime content script registration
src/entrypoints/content.tsx New content script using WXT's shadow DOM utilities for React rendering
src/entrypoints/popup.html New popup entrypoint with WXT metadata
src/entrypoints/options.html New options page entrypoint with WXT metadata
src/entrypoints/index.html Updated standalone page with corrected icon path
src/background.ts Removed and migrated to src/entrypoints/background.ts
src/content.tsx Removed and migrated to src/entrypoints/content.tsx
src/inject-content-module.ts Removed as WXT handles module loading internally
src/manifest.json Removed as manifest is now generated from wxt.config.ts
src/vite-env.d.ts Removed as WXT provides its own type definitions
src/utils/popout.ts Updated to use browser polyfill instead of chrome API
src/utils/platform.ts Removed utility file (platform detection no longer needed)
src/utils/entrypoint.ts New utility to detect which HTML entrypoint is running
src/routes/index.tsx Updated root route to handle entrypoint-based navigation
src/routes/__root.tsx Added HeadContent component and browser API usage for dynamic title
src/routes/settings.tsx Migrated from chrome API to browser polyfill
src/main.tsx Updated to use new entrypoint detection instead of location type
src/provider/SettingsProvider.tsx Migrated runtime message sending to browser API
src/provider/QueryClientProvider.tsx Updated storage persister to use browser API with proper typing
src/hooks/useStorage.ts Migrated all chrome.storage calls to browser.storage with type safety
src/hooks/useActiveRedmineTab.ts Updated tab query and event listeners to use browser API
src/components/general/Layout.tsx Updated to use Entrypoint type instead of WindowLocationType
src/components/general/BrowserNotificationBadge.tsx Migrated badge API to browser polyfill
src/components/ui/*.tsx Updated shadow root container ID references from "redmine-time-tracking-host" to "redmine-time-tracking-shadow-host"
src/index.css Removed :host selector (no longer needed with WXT's shadow DOM approach)
public/icon/*.png Added icon files in new directory structure
public/tw-properties.css Removed Tailwind properties file as WXT handles CSS injection differently
.gitignore Added .output and .wxt directories for WXT build artifacts
.prettierignore Added generated route tree file
.github/workflows/publish-canary.yml New canary publishing workflow using WXT submit command

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/workflows/publish-canary.yml Outdated
Comment thread src/entrypoints/background.ts Outdated
Comment thread package.json
Comment thread package.json
@CrawlerCode CrawlerCode force-pushed the refactor/migrate-to-wxt branch from d36ece8 to d39374a Compare December 17, 2025 22:44
@CrawlerCode CrawlerCode changed the title refactor: Migrate to wxt framework build: Migrate to wxt framework Dec 18, 2025
@CrawlerCode CrawlerCode marked this pull request as ready for review December 18, 2025 17:36
@CrawlerCode CrawlerCode requested a review from Copilot December 18, 2025 17:36
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 38 out of 47 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread wxt.config.ts
@CrawlerCode CrawlerCode merged commit a83bf30 into v2 Dec 18, 2025
6 checks passed
@CrawlerCode CrawlerCode deleted the refactor/migrate-to-wxt branch December 18, 2025 17:40
@CrawlerCode CrawlerCode mentioned this pull request Jan 27, 2026
CrawlerCode pushed a commit that referenced this pull request Jan 27, 2026
## [2.0.0-beta.1](v1.21.2...v2.0.0-beta.1) (2026-01-27)

### ⚠ BREAKING CHANGES

* The next release should be a major version bump

### 🚀 Features

* Add project info tooltip ([f2a1c80](f2a1c80))
* Allow to specify the rounding mode ([#49](#49)) ([2c0322b](2c0322b))
* Display custom field values for info tooltips ([2d2bef8](2d2bef8))
* Enhance issue grouping ([#38](#38)) ([e2a5a98](e2a5a98))
* Enhance search ([#51](#51)) ([770fa4b](770fa4b)), closes [#46](#46)
* **filter:** Add issue status filter ([e7807e2](e7807e2))
* Multiple timers & timer tab ([bd55541](bd55541)), closes [#39](#39)
* **timers:** Group timers by project and sort them by newest first ([d66aa6a](d66aa6a))

### 🩹 Fixes

* Display translated error message until redmine url is configured and remove errors toasts ([4c2d534](4c2d534))
* Fix broken persistent comments behavior ([6121441](6121441))
* Fix default time entry activity selection ([946c4b6](946c4b6))
* Fix eslint errors ([a245275](a245275))
* Fix legacy settings migrations ([1336e31](1336e31))
* Handle issue priorities when no default is specified ([899c21a](899c21a))
* Implement legacy data migrations for issues and timers ([c2fd501](c2fd501))
* Save persistent comments per timer instead of issue ([bff5fcf](bff5fcf))
* Skip failed mutations for multi create time spend entires ([a019c16](a019c16))
* **timer:** Close alert dialog on reset confirm ([9e51a23](9e51a23))
* **ui:** Display deleted issues as strike-through text ([90933a9](90933a9))
* **ui:** Fix toaster styles inside shadow root ([0319a42](0319a42))
* Update min browser versions to match current requirements ([bd1e7d0](bd1e7d0))

### 🔥 Performance

* Add react compiler and reduce unnecessary re-renders ([acb8551](acb8551))
* Improving data loading and increasing page loading speed ([#52](#52)) ([6b22f6b](6b22f6b))

### 🏡 Chore

* Enforce next release version to v2.0.0 ([fade882](fade882))
* Update npm dependencies ([6c806b9](6c806b9))

### 🛠️ Refactors

* Improve create time entry modal ([49f6eb6](49f6eb6))
* Move to tanstack form + zod (removed formik + yup) ([60b9e43](60b9e43))
* Remove add notes settings option ([4c3733c](4c3733c))
* Run settings migration on extension update ([840f48d](840f48d))
* **settings:** Redesign settings page and add testing redmine connection button ([3a65610](3a65610))
* **timer:** Refactor timer components and permission improvements ([0b32d3e](0b32d3e))
* **ui:** Migrate to shadcn components ([#48](#48)) ([274e220](274e220))
* **ui:** Move to shadcn base-ui components ([#57](#57)) ([70994f0](70994f0))
* Upgrade tailwindcss to v4 ([aa42fbb](aa42fbb))
* Use null as form default values and update zod to v4 ([cd2f4d8](cd2f4d8))
* Use only project id for permission check function ([b31c12f](b31c12f))

### 📖 Documentation

* **license:** Update license text for consistency ([37a0ebf](37a0ebf))

### 🧪 Tests

* Fix all e2e tests ([c46486f](c46486f))

### 📦 Builds

* Migrate to wxt framework ([#53](#53)) ([a83bf30](a83bf30))

### ⚡CI

* Add build number for canary version ([df1d96c](df1d96c))
* Add semantic release ([2ca9621](2ca9621))
CrawlerCode pushed a commit that referenced this pull request Jan 27, 2026
## [2.0.0-beta.1](v1.21.2...v2.0.0-beta.1) (2026-01-27)

### ⚠ BREAKING CHANGES

* The next release should be a major version bump

### 🚀 Features

* Add project info tooltip ([f2a1c80](f2a1c80))
* Allow to specify the rounding mode ([#49](#49)) ([2c0322b](2c0322b))
* Display custom field values for info tooltips ([2d2bef8](2d2bef8))
* Enhance issue grouping ([#38](#38)) ([e2a5a98](e2a5a98))
* Enhance search ([#51](#51)) ([770fa4b](770fa4b)), closes [#46](#46)
* **filter:** Add issue status filter ([e7807e2](e7807e2))
* Multiple timers & timer tab ([bd55541](bd55541)), closes [#39](#39)
* **timers:** Group timers by project and sort them by newest first ([d66aa6a](d66aa6a))

### 🩹 Fixes

* Display translated error message until redmine url is configured and remove errors toasts ([4c2d534](4c2d534))
* Fix broken persistent comments behavior ([6121441](6121441))
* Fix default time entry activity selection ([946c4b6](946c4b6))
* Fix eslint errors ([a245275](a245275))
* Fix legacy settings migrations ([1336e31](1336e31))
* Handle issue priorities when no default is specified ([899c21a](899c21a))
* Implement legacy data migrations for issues and timers ([c2fd501](c2fd501))
* Save persistent comments per timer instead of issue ([bff5fcf](bff5fcf))
* Skip failed mutations for multi create time spend entires ([a019c16](a019c16))
* **timer:** Close alert dialog on reset confirm ([9e51a23](9e51a23))
* **ui:** Display deleted issues as strike-through text ([90933a9](90933a9))
* **ui:** Fix toaster styles inside shadow root ([0319a42](0319a42))
* Update min browser versions to match current requirements ([bd1e7d0](bd1e7d0))

### 🔥 Performance

* Add react compiler and reduce unnecessary re-renders ([acb8551](acb8551))
* Improving data loading and increasing page loading speed ([#52](#52)) ([6b22f6b](6b22f6b))

### 🏡 Chore

* Enforce next release version to v2.0.0 ([fade882](fade882))
* Update npm dependencies ([6c806b9](6c806b9))

### 🛠️ Refactors

* Improve create time entry modal ([49f6eb6](49f6eb6))
* Move to tanstack form + zod (removed formik + yup) ([60b9e43](60b9e43))
* Remove add notes settings option ([4c3733c](4c3733c))
* Run settings migration on extension update ([840f48d](840f48d))
* **settings:** Redesign settings page and add testing redmine connection button ([3a65610](3a65610))
* **timer:** Refactor timer components and permission improvements ([0b32d3e](0b32d3e))
* **ui:** Migrate to shadcn components ([#48](#48)) ([274e220](274e220))
* **ui:** Move to shadcn base-ui components ([#57](#57)) ([70994f0](70994f0))
* Upgrade tailwindcss to v4 ([aa42fbb](aa42fbb))
* Use null as form default values and update zod to v4 ([cd2f4d8](cd2f4d8))
* Use only project id for permission check function ([b31c12f](b31c12f))

### 📖 Documentation

* **license:** Update license text for consistency ([37a0ebf](37a0ebf))

### 🧪 Tests

* Fix all e2e tests ([c46486f](c46486f))

### 📦 Builds

* Migrate to wxt framework ([#53](#53)) ([a83bf30](a83bf30))

### ⚡CI

* Add build number for canary version ([df1d96c](df1d96c))
* Add semantic release ([2ca9621](2ca9621))
@CrawlerCode
Copy link
Copy Markdown
Owner Author

🎉 This PR is included in version 2.0.0-beta.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@CrawlerCode CrawlerCode added this to the v2.0.0 milestone Apr 17, 2026
CrawlerCode pushed a commit that referenced this pull request Apr 26, 2026
## [2.0.0](v1.21.2...v2.0.0) (2026-04-26)

### ⚠ BREAKING CHANGES

* The next release should be a major version bump

### 🚀 Features

* Add full-screen project sidebar (experimental) ([#64](#64)) ([2f4c065](2f4c065))
* Add issue status badge ([6c5e447](6c5e447))
* Add project info tooltip ([f2a1c80](f2a1c80))
* Add side panel entrypoint ([3731d5d](3731d5d))
* Allow to specify the rounding mode ([#49](#49)) ([2c0322b](2c0322b))
* Display custom field values for info tooltips ([2d2bef8](2d2bef8))
* Enhance issue grouping ([#38](#38)) ([e2a5a98](e2a5a98))
* Enhance search ([#51](#51)) ([770fa4b](770fa4b)), closes [#46](#46)
* **filter:** Add issue status filter ([e7807e2](e7807e2))
* Multiple timers & timer tab ([bd55541](bd55541)), closes [#39](#39)
* **settings:** Add option to show/hide issue done ratio ([bc9b6c3](bc9b6c3))
* **settings:** Add option to show/hide timer sessions ([6022751](6022751))
* **timers:** Add timer sessions ([#69](#69)) ([#71](#71)) ([ed42990](ed42990))
* **timers:** Group timers by project and sort them by newest first ([d66aa6a](d66aa6a))

### 🩹 Fixes

* Cleanup local issue data on reset to default data ([9a7adc1](9a7adc1))
* Display translated error message until redmine url is configured and remove errors toasts ([4c2d534](4c2d534))
* Enforce next release ([1d7d37c](1d7d37c))
* Fire toast after query reset ([f051446](f051446))
* Fix 0 value selection for select field ([35af5e4](35af5e4))
* Fix autoFetchPages for redmine paginated queries ([a925baa](a925baa))
* Fix broken persistent comments behavior ([6121441](6121441))
* Fix context menu dialog actions ([66cbc7a](66cbc7a))
* Fix default time entry activity ([0f316ae](0f316ae))
* Fix default time entry activity selection ([946c4b6](946c4b6))
* Fix eslint errors ([a245275](a245275))
* Fix install listener registration ([8b9b125](8b9b125))
* Fix legacy settings migrations ([1336e31](1336e31))
* Fix suspense settings provider ([#60](#60)) ([cfc47f3](cfc47f3))
* Handle issue priorities when no default is specified ([899c21a](899c21a))
* Implement legacy data migrations for issues and timers ([c2fd501](c2fd501))
* Prevent empty issues fetch request ([#65](#65)) ([6616c64](6616c64))
* Save persistent comments per timer instead of issue ([bff5fcf](bff5fcf))
* Skip failed mutations for multi create time spend entires ([a019c16](a019c16))
* **timer:** Close alert dialog on reset confirm ([9e51a23](9e51a23))
* **timer:** Fix timer name cursor focus ([dee98ec](dee98ec))
* **ui:** Display deleted issues as strike-through text ([90933a9](90933a9))
* **ui:** Enhance skeleton components ([d89a901](d89a901))
* **ui:** Fix dark mode for firefox options and sidepanel ([ba6b406](ba6b406))
* **ui:** Fix layout inconsistencies depending on style settings ([6cef7e3](6cef7e3))
* **ui:** Fix toaster styles inside shadow root ([0319a42](0319a42))
* **ui:** Improve combobox clear button position ([932d36d](932d36d))
* **ui:** Polished various ui elements ([c095c5c](c095c5c))
* **ui:** Truncate field labels ([e779018](e779018))
* Update min browser versions to match current requirements ([bd1e7d0](bd1e7d0))

### 🔥 Performance

* Add query client restoring gate instead of restoring twice ([30b9aeb](30b9aeb))
* Add react compiler and reduce unnecessary re-renders ([acb8551](acb8551))
* Improve performance by moving stuff to dedicated components ([f2f7fab](f2f7fab))
* Improving data loading and increasing page loading speed ([#52](#52)) ([6b22f6b](6b22f6b))
* Set NODE_ENV=production for release & pre-release builds ([4a922ff](4a922ff))
* Use react context for permissions management ([#63](#63)) ([23f25f0](23f25f0))

### 🏡 Chore

* Add docker compose for dev setup ([bb79a02](bb79a02))
* Add install buttons to github releases ([3c97a80](3c97a80))
* **deps:** Update dependencies ([2a3f1fb](2a3f1fb))
* **deps:** Update dependencies ([6f800bd](6f800bd))
* **deps:** Update npm dependencies ([0132802](0132802))
* **deps:** Update npm dependencies ([b0256f0](b0256f0))
* **deps:** Update npm dependencies ([e966f7e](e966f7e))
* Enforce next release version to v2.0.0 ([fade882](fade882))
* Fix eslint errors ([9ec1e07](9ec1e07))
* Introduced script to automate chrome store screenshot generation ([#67](#67)) ([c34baa2](c34baa2))
* **lint:** Fix htmlhint errors ([07604c3](07604c3))
* **security:** Set pnpm minimum release age to 1 days ([0d595c2](0d595c2))
* Update dependencies ([891fd66](891fd66))
* Update npm dependencies ([a9bb249](a9bb249))
* Update npm dependencies ([6c806b9](6c806b9))
* Update shadcn components ([4f9bb88](4f9bb88))
* Upgrade to typescript 6 and hardened  ts config ([5e34a03](5e34a03))
* Upgrade to vite v8 ([8210cb5](8210cb5))

### 🛠️ Refactors

* Fix some warnings and errors from react-doctor ([c4d9c84](c4d9c84))
* Improve create time entry modal ([49f6eb6](49f6eb6))
* Move to tanstack form + zod (removed formik + yup) ([60b9e43](60b9e43))
* Refactor redmine api hooks ([6642499](6642499))
* Remove add notes settings option ([4c3733c](4c3733c))
* Run settings migration on extension update ([840f48d](840f48d))
* **settings:** Redesign settings page and add testing redmine connection button ([3a65610](3a65610))
* **timer:** Refactor timer components and permission improvements ([0b32d3e](0b32d3e))
* **timer:** Remove the reset timer button ([26e0f2f](26e0f2f))
* **ui:** Migrate to shadcn components ([#48](#48)) ([274e220](274e220))
* **ui:** Move to shadcn base-ui components ([#57](#57)) ([70994f0](70994f0))
* **ui:** Refactor time entry week overview ([2710d3b](2710d3b))
* Upgrade tailwindcss to v4 ([aa42fbb](aa42fbb))
* Use null as form default values and update zod to v4 ([cd2f4d8](cd2f4d8))
* Use only project id for permission check function ([b31c12f](b31c12f))

### 📖 Documentation

* **github:** Enhance issue and feature request templates ([#68](#68)) ([e70f419](e70f419))
* **license:** Update license text for consistency ([37a0ebf](37a0ebf))
* Update README ([8011225](8011225))
* Update store screenshots ([702a2c4](702a2c4))
* Update store screenshots ([cd60ec7](cd60ec7))

### 🧪 Tests

* Fix all e2e tests ([c46486f](c46486f))
* Fix flaky tests ([1e0a7a2](1e0a7a2))
* Fix flaky time drift tests ([cadd015](cadd015))
* Introduce snapshot-based e2e tests ([#66](#66)) ([dfcb7fb](dfcb7fb))

### 📦 Builds

* **deps-dev:** bump vite from 8.0.3 to 8.0.5 ([#70](#70)) ([aed8cdc](aed8cdc))
* **deps:** bump axios from 1.14.0 to 1.15.0 ([#72](#72)) ([057ad2c](057ad2c))
* Migrate to wxt framework ([#53](#53)) ([a83bf30](a83bf30))

### ⚡CI

* Add build number for canary version ([df1d96c](df1d96c))
* Add semantic release ([2ca9621](2ca9621))
* Add super-linter for pull requests ([#59](#59)) ([9db6385](9db6385))
* Fix pre-release asset upload ([ac8f132](ac8f132))
* Fix wxt submit ([74fe75d](74fe75d))
* Publish production only for real releases not for pre-releases ([9855905](9855905))
* Use pat for release creation to trigger publish pipeline ([7b15071](7b15071))
@CrawlerCode
Copy link
Copy Markdown
Owner Author

🎉 This PR is included in version 2.0.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants