docs: document per-tab badges and release:push updates.json automation

This commit is contained in:
Jordan Wages 2025-08-23 00:30:56 -05:00
commit ff5b02d07c
2 changed files with 13 additions and 5 deletions

View file

@ -16,6 +16,14 @@ This add-on helps you collect and filter links from archive.org `https://archive
- Popup → Content: try `collectLinks` first; if no receiver exists, Popup → Background → inject content → retry collect.
- Popup → Background: `aria2.send` wraps `aria2.addUri` calls (batch) and keeps secrets out of page context.
- Context menu: parent "Collect links…" with a dynamic submenu built per page ("Download/Copy All" and top file types).
- Popup → Background (badge): `popup.filteredCount` posts the current filtered count so the background can set a pertab badge.
### Badges (Pertab)
- Background maintains lightweight pertab state `{ url, isArchive, itemsCount, filteredCount }`.
- Default: on archive.org `/download/*` tabs, badge shows total item count; on other tabs, it is blank.
- When the popup filters change, it sends `popup.filteredCount`, and the badge shows that filtered count for the active tab.
- Badge updates on tab activation and URL changes; quick actions (copy/send) update only the current tabs badge.
### Storage Keys
@ -79,11 +87,10 @@ Suggested scripts (future): `npm test`, `npm run test:e2e` with Playwright.
## Release & Signing
- Addon ID and updates: `applications.gecko.id = "archive-org-link-grabber@jordanwages.com"` and `applications.gecko.update_url` points to the selfhosted updates JSON.
- Scripts: `release:prepare:*` (syncs `manifest.json`), `release:sign` (creates XPI under `releases/<version>/`).
- Scripts: `release:prepare:*` (syncs `manifest.json`), `release:sign` (creates XPI under `releases/<version>/`), `release:push` (uploads artifacts and autoupdates/uploads `releases/updates.json`).
- Secrets: set `AMO_JWT_ISSUER` and `AMO_JWT_SECRET` locally (see `.env.example`); never commit them.
## Commit & PR Guidelines
- Conventional Commits: `feat:`, `fix:`, `docs:`, `chore:`, `refactor:`.
- Keep PRs small and focused; include motivation, UX screenshots for UI changes, test plan, and linked issues.