Skip to content

fix(dia): open options page via extension tab#1373

Merged
mengxi-ream merged 2 commits intomainfrom
codex/fix-dia-options-opening
Apr 24, 2026
Merged

fix(dia): open options page via extension tab#1373
mengxi-ream merged 2 commits intomainfrom
codex/fix-dia-options-opening

Conversation

@mengxi-ream
Copy link
Copy Markdown
Owner

Type of Changes

  • 🐛 Bug fix (fix)
  • 🔧 Build or dependencies update (build)

Description

This PR fixes opening the extension options page in Dia by avoiding browser.runtime.openOptionsPage() and opening the extension options entry directly with browser.tabs.create({ url: browser.runtime.getURL("/options.html") }).

It also makes postinstall skip required production env validation while running wxt prepare, so local installs do not require production-only WXT_* values.

Related Issue

N/A

How Has This Been Tested?

  • Added unit tests
  • Verified through manual testing

Commands run:

  • pnpm run postinstall
  • SKIP_FREE_API=true pnpm exec vitest run src/utils/__tests__/navigation.test.ts
  • pnpm exec eslint package.json src/utils/navigation.ts src/utils/__tests__/navigation.test.ts src/entrypoints/background/index.ts src/entrypoints/popup/app.tsx
  • WXT_SKIP_ENV_VALIDATION=true pnpm build
  • pnpm exec tsc --noEmit
  • Pre-push hook: nx run @read-frog/extension:lint, nx run @read-frog/extension:type-check, nx run @read-frog/extension:test

Screenshots

N/A

Checklist

  • I have tested these changes locally
  • I have updated the documentation accordingly if necessary
  • My code follows the code style of this project
  • My changes do not break existing functionality
  • If my code was generated by AI, I have proofread and improved it as necessary.

Additional Information

The local web-ext.config.ts for Dia remains ignored by git as intended.

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 24, 2026

🦋 Changeset detected

Latest commit: aa061a8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@read-frog/extension Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions Bot added fix contrib-trust:highly-trusted PR author trust score is 80-100. labels Apr 24, 2026
@github-actions
Copy link
Copy Markdown
Contributor

Contributor trust score

94/100 — Highly trusted

This score estimates contributor familiarity with mengxi-ream/read-frog using public GitHub signals. It is advisory only and does not block merges automatically.

Outcome

Score breakdown

Dimension Score Signals
Repo familiarity 35/35 commits in repo, merged PRs, reviews
Community standing 20/25 account age, followers, repo role
OSS influence 20/20 stars on owned non-fork repositories
PR track record 19/20 merge rate across resolved PRs in this repo

Signals used

  • Repo commits: 210 (author commits reachable from the repository default branch)
  • Repo PR history: merged 210, open 1, closed-unmerged 12
  • Repo reviews: 208
  • PR changed lines: 46 (+41 / -5)
  • Repo permission: admin
  • Followers: 160
  • Account age: 95 months
  • Owned non-fork repos considered: max 5382, total 5524 (mengxi-ream/read-frog (5382), mengxi-ream/visactor-next-template (93), mengxi-ream/mr-resume (36), mengxi-ream/excel-comparison (3), mengxi-ream/mengxi-ream (2), mengxi-ream/ai-sdk-registry (1), mengxi-ream/fumadocs-tanstack-start-cloudflare (1), mengxi-ream/nextjs-flask-framework (1), mengxi-ream/trpc-v11-t3-bug (1), mengxi-ream/kuiliang-blog (1), mengxi-ream/CS193p-2021 (1), mengxi-ream/ids-algorithms (1), mengxi-ream/elezoo-iceapp (1), mengxi-ream/base-ui-combobox-repro (0), mengxi-ream/tanstack-cloudflare-fumadocs (0), mengxi-ream/streamdown-wxt-bug (0), mengxi-ream/static (0), mengxi-ream/lucky (0), mengxi-ream/storage-onchange-bug-orion (0), mengxi-ream/wxt-i18n-zh-CN-bug (0))

Policy

  • Low-score review threshold: < 30
  • Auto-close: score < 20 and changed lines > 1000
  • Policy version: v1.1

Updated automatically when the PR changes or when a maintainer reruns the workflow.

@mengxi-ream mengxi-ream merged commit d2c75ac into main Apr 24, 2026
5 checks passed
@mengxi-ream mengxi-ream deleted the codex/fix-dia-options-opening branch April 24, 2026 02:51
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: aa061a8342

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread package.json
"lint": "eslint",
"lint:fix": "eslint --fix",
"postinstall": "wxt prepare",
"postinstall": "WXT_SKIP_ENV_VALIDATION=true wxt prepare",
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Make postinstall env override cross-platform

The new postinstall command uses POSIX inline env assignment (WXT_SKIP_ENV_VALIDATION=true wxt prepare), which fails under the default Windows npm/pnpm script shell (cmd.exe), so pnpm install now breaks for Windows contributors/CI before dependencies finish installing. This regression was introduced by this commit; use a cross-platform approach (e.g., cross-env) to preserve install behavior across OSes.

Useful? React with 👍 / 👎.

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

Labels

contrib-trust:highly-trusted PR author trust score is 80-100. fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant