Skip to content

Custom share-via menu (#34, #35), Edge favicon fix (#33), v2.1.0 - #36

Merged
BrandonML merged 7 commits into
mainfrom
feat/share-via-menu
Sep 14, 2026
Merged

BrandonML merged 7 commits into
mainfrom
feat/share-via-menu

Conversation

@BrandonML

Copy link
Copy Markdown
Owner

Summary

  • "Share" options limited on Windows, no method of selecting an option not shown #34 (share options limited on Windows, no way to pick a channel not shown): replaces the sole navigator.share() button with a custom "Share via" popover offering explicit channels — WhatsApp, Email, X/Twitter, Facebook, Reddit, Pinterest, Nextdoor, Copy link — plus a "More options…" entry that still uses native share (with photo attachment) when available.
  • Update "Share" output content for better UX and user engagement #35 (share output content/UX): text-based channels now share one message composed with the cat's profile link ahead of the Tabby plug, both on their own blank-separated line, instead of relying on how a native share target happens to join separate text/url fields together.
  • Tabby Favicon for browser tab does not show on Edge #33 (Edge doesn't show the favicon on a fresh new tab): added an explicit <link rel="icon"> on both pages plus a root favicon.ico wired into the release zip. Neither fully fixed the new-tab case in Edge — testing points to a genuine Edge platform limitation for chrome_url_overrides.newtab pages, not a page-markup issue. Left in place since it's correct/harmless regardless (and does work via direct navigation, e.g. options.html).
  • Version bump to 2.1.0 (manifest.json, package.json).

Real-world fixes from live testing

Several rounds of hands-on testing (Chrome, Edge, real rescue sites) surfaced and fixed:

  • Popover positioning wasn't viewport-aware — now flips above the button when there's insufficient room below.
  • window.open('mailto:...') silently failed in Chrome — switched to a real (appended, then removed) anchor click, opened in a new tab.
  • Pinterest's media param errored when it resolved to a non-public URL (e.g. local dev backend) — now guarded to only send it for a real https:// URL.
  • Reddit's link-post mode has no body-text field and its thumbnail depends on the target page's own Open Graph tags (same fragility as Facebook) — switched to a self/text post with the same composed message as WhatsApp/Nextdoor.
  • LinkedIn dropped in favor of Reddit/Pinterest/Nextdoor, whose share intents don't depend on the rescue site's own markup the way Facebook/LinkedIn/X do.

Known, unfixable-by-us limitations (documented inline in code)

  • Facebook and X only ever take a URL/text — any card image comes from that page's own Open Graph/Twitter Card tags (X has no media param at all), and most RescueGroups-hosted rescue pages don't have correct ones. Real fix is a Tabby-hosted cat-details share page with our own OG tags — scoped as separate follow-up work, not in this PR.
  • Instagram has no share-intent URL at all; left out rather than ship a dead button.

Test plan

  • npm test — 218/218 passing
  • Manual testing in real Chrome and Edge (by the repo owner) across multiple live rescue sites — all channels confirmed working to the extent of each platform's own limitations
  • Verified popover positioning/clipping and exact composed-message content in a real browser (JSDOM can't validate real layout)

Co-Authored-By: Claude Sonnet 5 noreply@anthropic.com
🤖 Generated with Claude Code

BrandonML and others added 7 commits September 14, 2026 13:52
navigator.share()'s OS share sheet on Windows is limited to whatever's
registered on that machine, with no way to pick a channel it doesn't
list (#34), and native share also leaves message ordering/spacing up
to whatever the receiving app does when it joins the separate text/url
fields back together (#35).

Replace the single native-share button with a popover offering
explicit channels -- WhatsApp, Email, X/Twitter, Facebook, LinkedIn,
Copy link -- built from share-intent URLs Tabby fully controls, plus a
"More options..." entry that still uses navigator.share (with photo
attachment) when available. Text-based channels now share one composed
message with the cat's profile link ahead of the Tabby plug, both on
their own blank-separated line, instead of relying on OS/app-dependent
concatenation.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…/Nextdoor

Real-world testing surfaced three issues with the share-via menu:

- The popover always opened downward, but the Share button sits near
  the bottom of the card -- which is often already near the bottom of
  the viewport -- so lower menu items were regularly unreachable
  without scrolling. It now flips above the button when there isn't
  enough room below.

- Email sharing silently did nothing: window.open('mailto:...') is
  unreliable in Chrome. Switched to a real anchor click, which is what
  browsers actually special-case for handing a non-http(s) scheme off
  to the OS/registered app.

- Facebook and LinkedIn only ever take a URL and build their preview
  card by scraping that page's Open Graph tags -- most RescueGroups-
  hosted rescue pages don't have (correct) ones, so those cards were
  regularly missing the cat's photo/name entirely. LinkedIn is dropped
  in favor of Reddit and Pinterest, whose share intents accept the
  title/image/description directly and don't depend on the rescue
  site's own markup, plus Nextdoor (a pre-filled text composer, same
  as WhatsApp/email). Facebook stays since it's still widely used --
  its OG-tag dependency is a platform restriction, not something a
  channel swap fixes; that needs the cat-details share page already
  planned separately.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Pinterest: its pin-creation API fetches the `media` URL itself,
server-side, so a non-public/non-https backend (the local dev
BACKEND_URL) can't be reached from there -- it surfaced as a raw
"not a valid URL format" error in Pinterest's own dialog instead of
degrading gracefully. Only send `media` when it's a real https URL
(always true in a release build -- see scripts/release.js); omit it
otherwise and still let the pin go through without a forced image.

Reddit: a link post (url= + title=) has no body-text field at all, and
its thumbnail comes from Reddit scraping the target page's Open Graph
tags -- same reliability problem as Facebook. Submit it as a self/text
post instead (title= + text=) with the same composed message as
WhatsApp/Nextdoor; the profile link is still right there in the text
and Reddit auto-links it.

Twitter/X's web intent has no media parameter at all -- confirmed via
their own developer docs, not something fixable client-side.

Email: append the synthetic anchor to the document before clicking it
(and remove it right after) instead of clicking it detached, matching
how other "trigger mailto/download via synthetic click" implementations
do it.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Neither page declared a favicon, so each browser fell back to its own
default resolution. Chrome (and Edge, but only when a page is reached
by direct navigation, e.g. options.html) derives one from the
extension's manifest icons; Edge specifically doesn't do that same
fallback for a chrome_url_overrides.newtab page in a freshly opened
tab, which is why the icon only showed up after visiting settings and
persisted only by leftover tab state, not on a new tab. An explicit
<link rel="icon"> removes the reliance on that fallback entirely.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The explicit <link rel="icon"> added earlier didn't fix Edge showing a
placeholder on a freshly opened new tab -- one theory for that gap is
Edge's new-tab-page icon resolution specifically probes for an
implicit /favicon.ico at the origin root rather than reading the
page's own <link> tags, unlike normal page navigation. Added one
(PNG-in-ICO container wrapping icon32.png, no external tooling needed)
at the package root, and wired it into the release zip -- the release
script only ever copied manifest.json + extension/ before, so this
would otherwise have shipped in git but not in a real release build.

Confidence on this one is genuinely lower than the last fix -- if it
doesn't resolve the new-tab case either, the plan is to revert this
and close #33 as a won't-fix Edge platform limitation.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@BrandonML
BrandonML merged commit 32d1511 into main Sep 14, 2026
1 check passed
@BrandonML
BrandonML deleted the feat/share-via-menu branch September 14, 2026 20:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update "Share" output content for better UX and user engagement "Share" options limited on Windows, no method of selecting an option not shown

1 participant