Repository navigation
Conversation
Raise the supported React peer range to ^18 || ^19 for v6 and update the compatibility docs accordingly. This is the planned v6 breaking change for React support, following the v5 line where React 17 remained supported through 5.3.
Remove the deprecated TwitterShareButton and TwitterIcon aliases from the public package surface, leaving XShareButton and XIcon as the canonical X exports in v6. This follows the v5 deprecation where the X exports were introduced and the Twitter aliases were kept only for backwards compatibility.
Remove all share count components, the shared createShareCount implementation, and the jsonp dependency from the published package surface in v6. This follows the v5 deprecation where share counts were kept only as best-effort compatibility and documented for removal in the next major release.
Remove the deprecated hashtags, related, and via props from ThreadsShareButton in v6. These props were ignored in v5 and documented only as compatibility shims ahead of their planned removal in the next major release.
Replace the ambiguous share button title prop with explicit v6 payload names: text, message, shareTitle, and postTitle depending on the target network. Keep htmlTitle as the native button tooltip/title attribute and update the demo, README, and button tests to reflect the renamed public API.
Export per-network build*ShareUrl helpers from the package root and expose openShareWindow(url, options) as the shared popup helper used internally by ShareButton. This keeps the button components as thin wrappers over the same helper implementations and adds direct source and built-package coverage for the new advanced-usage API.
Add an ESLint no-default-export rule for src, demo, and test files, and convert local modules to named exports so the rule is enforced by construction. The root barrel now re-exports one symbol per file line instead of aliasing defaults, while the published package surface remains the same through named root exports.
Address recurring mobile handoff reports from #577, #551, #529, and the earlier Messenger deep-link proposal in #357 without changing the default web-link behavior. The new mobileBehavior prop keeps the existing web flow as the default and adds best-effort app-link behavior for WhatsApp, Telegram, Viber, and Messenger when consumers explicitly opt in.
Introduce a first-class native share surface for mobile and PWA flows instead of forcing those use cases through popup-based network URLs. This addresses the file-sharing and platform-handoff needs behind #576 and complements the iOS/PWA limitations reported in #551 with canNativeShare(), shareNative(), and NativeShareButton.
Add a dedicated v5-to-v6 migration guide and a native/mobile sharing behavior guide under docs/, and link both from the main README for discoverability.
Rename the existing badge-style icons to *LegacyIcon and reuse the original *Icon names for raw SVG marks in v6. Vendored Simple Icons data is used where there is a strong canonical match, while unsupported networks and the generic native-share glyph keep repo-local raw icons. The old badge visuals remain available through the legacy exports. The docs, migration guide, and package/tests are updated so the raw icons are the default surface and the legacy family is the migration path for preserving v5 visuals.
Upgrade Vite to 8.0.0 and move the React plugin to 6.0.0 so the bundler stack stays on the supported peer range. Vitest and @vitest/coverage-v8 are updated to 4.1.0 at the same time to keep the test runner aligned with Vite 8 and avoid split peer ranges. No library runtime API changes are included in this commit.
Upgrade ESLint and @eslint/js to the v10 line and keep the existing flat-config rule set working with ESLint's v10 rule API changes. Wrap legacy React, hooks, and jsx-a11y plugins with @eslint/compat, replace the crashing import/no-default-export rule with an equivalent core selector rule, and add a local npm legacy peer deps setting while upstream plugin peer ranges catch up. Also add @testing-library/dom explicitly so clean installs keep tests runnable, ignore demo/dist in lint, and refresh formatting in files touched by the stricter lint pass.
The flat ESLint config no longer references the Babel plugin since the TypeScript and Vite migration, so it was only adding install weight and peer-dependency noise. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
XShareButton still identified itself as "twitter" internally, a leftover from the TwitterShareButton era. With the Twitter aliases gone in v6, key the default aria-label on "x" instead. No public API change; a test now covers the default aria-label for icon-only X buttons. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Pocket shut down in July 2025 and Workplace from Meta shut down in June 2026. Their share endpoints no longer accept shares, so keeping the buttons only shipped broken UI. v6 is the breaking release, so remove the share buttons, raw and legacy icons, and URL builders for both networks. Tests now assert the removed symbols stay out of the source and built package surfaces, and the migration guide lists the removals. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
X, Threads, and Telegram moved their canonical hosts to x.com, threads.com, and t.me. The old twitter.com, threads.net, and telegram.me URLs still work only through redirects, which add a hop and can drop the share intent if they are retired. Point the builders straight at the current endpoints. Requested in #536. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
When beforeOnClick returned a promise, the share popup was opened only after awaiting it. By then the click's user activation had expired, so Safari and other strict popup blockers silently blocked the share window (#525, #506, #529). Open a blank popup synchronously during the click and load the share URL into it once beforeOnClick resolves. A rejected promise now cancels the share and closes the popup instead of surfacing as an unhandled rejection. The synchronous path is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Apps had no way to tell whether the share popup actually opened, so a popup blocker made the share button silently do nothing (#525). Popup- based buttons now call onShareWindowOpen with the opened window, or null when the popup was blocked, so apps can offer a fallback. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Bluesky, Email, Viber, and WhatsApp builders relied on their button components to supply the default " " separator. Calling the newly exported build*ShareUrl helpers directly without a separator produced URLs such as "Helloundefinedhttps://...". Default the separator in the builders themselves. The builders are unreleased v6 API, so the existing helpers changeset covers this. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
EmailShareButton joined body and URL with a space, so the link ran into the body text in the composed email (#582). Default the separator to a newline in both the button and buildEmailShareUrl. This changes the generated mailto: body, so it ships in the v6 major; pass separator=" " to keep the old formatting. The blank lines above the body shown in #582 come from the mail client's composer, not from the mailto: URL. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Share buttons attach click handlers, so importing them from a Server Component (for example a Next.js App Router page) failed unless the app added its own "use client" wrapper (#491). Emit a "use client" banner on both the ESM and CJS bundles so frameworks treat the package as a client module, and assert it in the dist tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The v5 to v6 guide predated onShareWindowOpen, the "use client" banner, and the share endpoint updates, and its checklist did not mention the new beforeOnClick rejection and email separator behavior. Add an "Other improvements" section and the missing checklist steps. Fix two facts carried over from intermediate v6 states: v5's LinkedinShareButton took `title` (not `shareTitle`), and NativeShareIcon is new in v6, so it is not a v5 rename. Split the checklist into required, behavior, and optional steps, merge the two icon steps into one either/or step, and warn that plain JavaScript silently ignores the old `title` prop. Also point v5 users at the guide right under the install instructions, since the Guides section is easy to miss further down the README. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
LinkedinIcon and GabIcon still reused the 64x64 glyphs from the badge icons without their backgrounds, so they only filled 40-55% of the icon box. Next to the full-bleed Simple Icons marks they looked tiny and inconsistent. LinkedIn now uses its full rounded-square "in" mark in the current #0A66C2 brand blue. Gab knocks the wordmark out of a rounded green square, matching the VK and Hatena marks. Both are drawn on a 24x24 viewBox like the other raw icons. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The raw EmailIcon and NativeShareIcon reused small badge glyphs on a 64x64 viewBox and looked undersized next to the other raw icons. Swap them for the Lucide "mail" and "share" icons, which fill the 24x24 box like the brand marks do. Lucide icons are stroke-based, so RawIconBase gains an internal `outlined` mode that renders fill="none" with a round 2px stroke. The `color` (or `fill`) prop drives the stroke in that mode, so every raw icon can be recolored the same way. The README now documents `color` and credits Lucide. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
🦋 Changeset detectedLatest commit: 552fde3 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
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 |
Raw X, Weibo, Bluesky, Email, native share, Instapaper, and Tumblr icons were bare glyphs. Next to the circular brand marks (Facebook, Telegram, Reddit, Pinterest) they looked heavier or lighter and lost the consistent look the v5 badges had. RawIconBase gains an internal `badge` option that scales the glyph down around the center and draws it in white on a filled circle, so the glyph stays legible on dark backgrounds too. The outlined Lucide glyphs of Email and native share keep their round stroke, painted white. NativeShareIcon used the current text color, which on dark pages turns the circle white and hides the white glyph. It now uses a fixed blue (#0A84FF), the color of NativeShareLegacyIcon. The README, migration guide, and the raw/legacy icon changeset no longer describe raw icons as background-free. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Threads introduced a new app icon in 2026: a white glyph on a black rounded square. The raw ThreadsIcon still drew the old bare glyph, which also looked lighter than the other raw icons. Draw the new icon from the official SVG, scaled to the 24x24 viewBox. The glyph is a fixed white path, so it stays legible on dark backgrounds and `color` only recolors the square. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
OK's current logo, served as the ok.ru favicon, is a white figure on an orange (#FF7700) rounded square. The raw OKIcon still drew the old bare glyph in an older orange. Draw the new logo from the official SVG, scaled to the 24x24 viewBox. The figure is fixed white, so it stays legible on dark backgrounds and `color` only recolors the square. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Many raw icons cut their details out of the brand shape: the Facebook "f", the LinkedIn "in", the LINE lettering, the inside of the WhatsApp and Viber bubbles. On a dark page those holes showed the page background, so the logos turned into dark blobs. RawIconBase gains an internal `backdrop`: a white shape painted behind the mark. For the solid marks it is inset just inside the outline so it does not leave a light fringe on the anti-aliased edge; Facebook and Pinterest extend it only where their "f" and "P" stems open onto the edge. WhatsApp and Viber reuse the inner contour of their bubble outline, so the white fills the bubble exactly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Simple Icons LiveJournal mark is one color: the pencil body and lead are cut out of the blue circle. On a dark page they took on the page background, and on a light page the pencil showed as white, neither of which matches the official logo. Layer the mark from the same geometry instead: blue circle and eraser cap, navy (#15374C) pencil body and lead, and a white wooden tip, so the pencil looks the same on any background. `color` still recolors the blue parts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Several raw icons still used older or Simple Icons approximations of their brand colors. Switch them to the networks' current brand colors: - Bluesky: #1185FE -> #0560FF - LINE: #00C300 -> #06C755 - Pinterest: #BD081C -> #E60023 - Tumblr: #36465D -> #001935 - Gab: #00D178 -> #30CE7D The legacy badge icons keep their v5 colors. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
example.png was a hand-made screenshot that had drifted: it still showed the v5 badges and the removed Pocket and Workplace buttons. Replace it with example.svg, built by a test that renders the demo and lays out its icons in demo order. toMatchFileSnapshot keeps the file in sync: `npm run update-example` rewrites it, and CI fails while the committed preview is stale. As SVG the preview stays sharp, diffs readably, and keeps a transparent background on GitHub's dark theme. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The README had grown section by section through the v6 work and was hard to follow: there was no quick start, the network list was buried in Features, and broken list markup ran required, all-button and popup-only props together. Accessibility, mobile handoff and versioning notes were scattered across several sections. Reorganize it around install, a runnable quick start and a supported networks table. Common props become real tables, each network section gets a props table with its example in a collapsible block, and the accessibility, mobile handoff and compatibility notes each live in one place. Add a table of contents and a development section. Drop the icon sources section, which no longer describes where the icons come from. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
v6 is a cleanup release: it removes deprecated and dead APIs, gives share payload props explicit names, refreshes the icons, and adds native/mobile sharing. Upgrade steps are in docs/migrate-v5-to-v6.md.
Breaking
Twitter*aliases (useX*), all share counts, and Pocket and Workplace buttons (both services have shut down).titleis replaced per network bytext,message,shareTitle, orpostTitle.hashtags/related/viaprops.*Iconnow renders current brand logos at a consistent size (glyph-only marks on circle badges, current brand colors, the new OK and Threads logos); the v5 badges live on as*LegacyIcon.beforeOnClick: the popup opens right away so popup blockers allow it, and a rejected promise cancels the share (Any method is there which can return popup is blocked? #525, EmailShareButton not working on safari web browser #506, Not Working on Mobile browser #529).EmailShareButtonputs the URL on its own line by default (Why two empty lines on top of email sharing? #582).New
NativeShareButton,canNativeShare, andshareNative(Web Share API).mobileBehaviorapp handoff for WhatsApp, Telegram, Viber, and Messenger.build*ShareUrlhelpers andopenShareWindow.onShareWindowOpencallback to detect blocked popups (Any method is there which can return popup is blocked? #525)."use client"banner, so buttons work in React Server Components (Cannot be use with React Server Component #491).Fixes