Skip to content

1871 app implement social buttons in singlecontentvue - #1892

Open
MrDirkelz wants to merge 11 commits into
mainfrom
1871-app-implement-social-buttons-in-singlecontentvue
Open

1871 app implement social buttons in singlecontentvue#1892
MrDirkelz wants to merge 11 commits into
mainfrom
1871-app-implement-social-buttons-in-singlecontentvue

Conversation

@MrDirkelz

@MrDirkelz MrDirkelz commented Aug 17, 2026

Copy link
Copy Markdown
Collaborator
image image

@MrDirkelz MrDirkelz linked an issue Aug 17, 2026 that may be closed by this pull request
@MrDirkelz MrDirkelz self-assigned this Aug 17, 2026
@MrDirkelz
MrDirkelz force-pushed the 1871-app-implement-social-buttons-in-singlecontentvue branch 2 times, most recently from 18835f0 to fca1658 Compare August 28, 2026 09:17

@johan-bell johan-bell left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

The share feature is well-structured (shared URL builders, dark-mode-aware icons, tested highlight-share path), but a few things need fixing first:

  • useSocialShare.ts:17web.whatsapp.com/send is desktop-only; on mobile it shows a "use WhatsApp on your computer" interstitial, so sharing breaks on the app's primary platform. Use api.whatsapp.com/send.
  • LHighlightable.vue:396 — the Instagram toast hardcodes English ("Link copied" / "Instagram doesn't support…") even though this PR adds the exact i18n keys and ShareMenu uses them.
  • ShareMenu.vue:29 — share links use window.location.href instead of publicUrl() from app/src/seo/publicSite.ts, so shares from the PWA build won't carry the public web origin.
  • ShareMenu.vue:81 — the fixed w-60 panel with placement="top-start" overflows ~375px viewports; screenshots are desktop-only, and ShareMenu/useSocialShare (the ticket's deliverable) have no spec.
  • ShareMenu.vue:65 — the unguarded navigator.clipboard.writeText leaves an unhandled rejection and no toast on failure; the nine window.open(url, "_blank") calls also omit "noopener".
  • Scope: the SingleContent hero title/summary-overlay redesign and the BasePage banner-margin removal are sizeable layout changes riding along on a share-buttons ticket — worth splitting or at least flagging in the PR body (currently empty).

@MrDirkelz
MrDirkelz force-pushed the 1871-app-implement-social-buttons-in-singlecontentvue branch 2 times, most recently from 98b346e to 7c8d21f Compare September 2, 2026 05:59
MrDirkelz and others added 9 commits September 2, 2026 15:41
- Add Telegram/WhatsApp share buttons on SingleContent, backed by new
  brand icon components and new locale strings
- Rework the title/summary layout to overlay on the hero image when
  one is present, unifying the previous separate desktop/mobile blocks
- Merge the metadata and bookmark rows into a single divided bar to
  make room for the new share actions
- Replace inline Telegram/WhatsApp share buttons with a unified ShareMenu
  component covering Telegram, WhatsApp, X, Reddit, and Instagram
  (clipboard-copy fallback), with new i18n strings for each platform.
- Trim notification banner and hero header spacing on SingleContent/BasePage
  now that the share UI redesign changes the surrounding layout.
- Flatten the redundant wrapper div around IgnorePagePadding in the
  hero media section, fixing indentation without changing behavior
- Adjust margin/gap spacing on the no-hero-image title block and
  notification banner for visual consistency
- Switch WhatsApp share to web.whatsapp.com since wa.me/api.whatsapp.com
  are OS-level Universal Links that hand off to the native app and drop
  the pre-filled share text
- Widen ShareMenu panel and truncate long labels so translations don't
  overflow
- Bump notification banner bottom margin for consistent spacing
Extract ShareMenu's Telegram/WhatsApp/X/Reddit URL builders and message
formatting into a shared `useSocialShare` composable, then reuse it in
LHighlightable so selecting article text surfaces the same share
targets (plus a copy-to-clipboard fallback for Instagram) instead of
only Highlight/Copy actions.
The selectionchange listener only registers after onMounted's async
restoreHighlights() resolves, so tests dispatching selectionchange
right after mount raced it. Also give the Instagram-share test suite
an active testing Pinia, since shareHighlightToInstagram() reads the
notification store.
Prefer the Web Share API on phones/tablets so the reader gets the apps
actually installed on their device, keeping the curated share targets as
the fallback for desktop and for browsers without Web Share.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@MrDirkelz
MrDirkelz force-pushed the 1871-app-implement-social-buttons-in-singlecontentvue branch from cb4d8dc to 4eea8e1 Compare September 2, 2026 13:43
@MrDirkelz

Copy link
Copy Markdown
Collaborator Author

Check if instagram sharing is possible via sharing the image?

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.

APP: Implement social buttons in SingleContent.vue

2 participants