Repository navigation
Releases: afonsograca/react-native-qrcode-composer
Releases · afonsograca/react-native-qrcode-composer
Release list
Release 0.3.0
Added
- Typed QR code contents: the
valueprop now acceptsQRCodeContents, a union ofstringand typed content objects for plain text, URLs, email, phone, SMS, WiFi, geolocation, vCard, MeCard, and calendar events - The content interfaces (
PlainText,URLContent,Email,Phone,SMS,WiFi,GeolocationContent,VCard,MeCard,CalendarEvent) andQRCodeContentsare exported from the package - Support for the standard
refprop, forwarded to the underlyingreact-native-svgSvgelement - The package is declared side-effect-free (
sideEffects: false), letting bundlers tree-shake unused exports
Changed
- Breaking: the
valueprop is now required and typedQRCodeContents; the'QR code message'default has been removed - Breaking: on encoding/render failure the component now renders nothing (
null) instead of a rawTextelement with the error message;onErroris still invoked when provided - Breaking:
VCard.birthdayandVCard.anniversaryare nowDateinstead ofstring, consistent withMeCard QRCodeStyle.backgroundColoris now typedColorValue, widening it to also acceptOpaqueColorValue(e.g.PlatformColor); plain strings work as before- Breaking:
LogoStyle.borderRadiusis now applied in pixels to both the logo and its background (the background previously misread it as a fraction of its size, producing oversized radii for values above 2). For a circular logo, set it to half the logosize - Breaking: the internal
TestPropstype is no longer exported
Deprecated
- The
getRefprop — use the standardrefprop instead
Fixed
require()of the package no longer throws in Node consumers such as Jest and SSR: removed"type": "module"from package.json and added anexportsmap- MeCard nickname is now emitted with its
NICKNAME:key (it was previously appended without a key, corrupting the payload) - MeCard payload prefix corrected to
MECARD: - WiFi, MeCard, vCard, and iCalendar payloads now use spec-compliant backslash escaping instead of percent-encoding
- vCard and iCalendar payloads now use CRLF line endings
- Calendar events are now wrapped in
BEGIN:VCALENDAR/END:VCALENDAR - vCard now encodes all of its typed fields (previously around 20 fields, such as
telephone,organization, andtitle, were silently dropped) VCard.namegiven as a plain string is now escaped like every other text field (commas and semicolons no longer corrupt the payload)- The
testIDprefix is now applied to the logo's internal nodes (background, clip paths, container), so two QR codes with distincttestIDs no longer collide on them - Removed the broken
importcondition from the packageexportsmap: it pointed Node ESM consumers at ESM-syntax files in a CommonJS package, causing parse failures
Release 0.2.0
Added
- The ability to add a corner radius to the QR code's quiet zone
Release 0.1.4
First release of the react-native-qrcode-composer 🥳
Added
- Ability to display QR codes with customization