Skip to content

feat: add React 19 support to peer dependency ranges#1089

Merged
georgewrmarshall merged 2 commits into
mainfrom
design-system-react-support-react-v19
Apr 17, 2026
Merged

feat: add React 19 support to peer dependency ranges#1089
georgewrmarshall merged 2 commits into
mainfrom
design-system-react-support-react-v19

Conversation

@georgewrmarshall

@georgewrmarshall georgewrmarshall commented Apr 16, 2026

Copy link
Copy Markdown
Contributor

Description

Widens peerDependencies for @metamask/design-system-react and @metamask/design-system-shared to accept React 19 (^19.0.0) alongside existing React 17 and 18 support.

https://react.dev/blog/2024/04/25/react-19-upgrade-guide

Audit Summary

A full audit of React 19 breaking changes was performed against the codebase. No breaking APIs are used:

Breaking Change Impact
forwardRef deprecated (not removed) None — still works at runtime, deprecation warnings only
defaultProps removed for function components None — not used, already using ES6 defaults
propTypes removed None — not used
String refs / Legacy Context / createFactory removed None — not used
ReactDOM.render / hydrate / findDOMNode removed None — not used
react-dom/test-utils removed None — not imported
useRef requires argument None — all usages already pass null
Context.Provider deprecated None — only in react-native packages (not in scope)

Verification

  • Temporarily upgraded storybook-react to React 19.2.5 and confirmed all components render correctly
  • Build, tests (100% coverage), constraints, and lint all pass

Future Phases

  • Phase 2: Bump @types/react to v19, fix any TypeScript strictness issues
  • Phase 3: Migrate forwardRef to ref as prop pattern (large refactor, not required for compat)

Related issues

N/A

Manual testing steps

  1. Install packages in a React 19 project
  2. Verify no peer dependency warnings
  3. Verify components render correctly

Screenshots/Recordings

Storybook running on React 19.2.5

Components render correctly with React 19:

storybook.reactv19.support.after720.mov

Screenrecording captured with storybook-react temporarily using react@^19.0.0 / react-dom@^19.0.0. Confirmed via yarn why reactreact@npm:19.2.5 for storybook-react workspace.

Pre-merge author checklist

  • I've followed MetaMask Contributor Docs
  • I've completed the PR template to the best of my ability
  • I've included tests if applicable
  • I've documented my code using JSDoc format if applicable
  • I've applied the right labels on the PR (see labeling guidelines). Not required for external contributors.

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Note

Low Risk
Dependency/metadata-only changes (peer range widening and lockfile updates) with no runtime code changes; primary risk is consumers encountering React 19-specific issues that aren’t covered by existing tests.

Overview
Adds React 19 compatibility by widening peerDependencies in @metamask/design-system-react (also react-dom) and @metamask/design-system-shared to allow ^19.0.0 alongside React 17/18.

Updates yarn.lock accordingly, including a bump of @testing-library/react to 16.3.2 and related transitive lockfile entries.

Reviewed by Cursor Bugbot for commit a1a72f9. Bugbot is set up for automated code reviews on this repo. Configure here.

@georgewrmarshall georgewrmarshall requested a review from a team as a code owner April 16, 2026 16:26
@github-actions

Copy link
Copy Markdown
Contributor

📖 Storybook Preview

@socket-security

socket-security Bot commented Apr 16, 2026

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated@​testing-library/​react@​16.1.0 ⏵ 16.3.29910010087100

View full report

Widen peerDependencies for design-system-react and design-system-shared
to accept React 19 alongside existing React 17 and 18 support.
@georgewrmarshall georgewrmarshall force-pushed the design-system-react-support-react-v19 branch from bd12cab to 50e0d31 Compare April 16, 2026 16:29
@georgewrmarshall georgewrmarshall self-assigned this Apr 16, 2026
@github-actions

Copy link
Copy Markdown
Contributor

📖 Storybook Preview

@github-actions

Copy link
Copy Markdown
Contributor

📖 Storybook Preview

@georgewrmarshall georgewrmarshall merged commit c3de7dd into main Apr 17, 2026
44 checks passed
@georgewrmarshall georgewrmarshall deleted the design-system-react-support-react-v19 branch April 17, 2026 03:53
@georgewrmarshall georgewrmarshall mentioned this pull request Apr 20, 2026
19 tasks
georgewrmarshall added a commit that referenced this pull request Apr 21, 2026
## Release 34.0.0

This release adds new shared `TitleHub` and `Checkbox` type contracts,
expands React 19 support for web and shared packages, and publishes a
React Native release that aligns its supported runtime with the React
Native 0.76 / Storybook 10 stack.

### 📦 Package Versions

- `@metamask/design-system-shared`: **0.12.0**
- `@metamask/design-system-react`: **0.17.1**
- `@metamask/design-system-react-native`: **0.19.0**
- `@metamask/design-system-twrnc-preset`: **0.4.2**

### 🔄 Shared Type Updates (0.12.0)

#### Shared contract additions and API cleanup
([#1052](#1052),
[#1040](#1040),
[#1076](#1076),
[#1089](#1089))

**What Changed:**

- Added `TitleHubPropsShared` and `CheckboxPropsShared` to
`@metamask/design-system-shared`
- Removed `isReactNodeRenderable` from the public shared API
- Expanded the shared package `react` peer dependency range to support
React 19

**Impact:**

- Enables consistent `TitleHub` and `Checkbox` implementations across
React and React Native
- Consumers importing `isReactNodeRenderable` must replace that import
with plain truthy checks
- Shared consumers on React 19 can now satisfy peer dependency
requirements without overrides

### 🌐 React Web Updates (0.17.1)

#### Changed

- Expanded the `react` and `react-dom` peer dependency ranges to support
React 19 consumers without changing the public component API
([#1089](#1089))

### 📱 React Native Updates (0.19.0)

#### Added

- Added `TitleHub` for stacked title, amount, and bottom-label layouts
with optional accessory slots
([#1052](#1052))

#### Changed

- **BREAKING:** Raised the minimum supported peer dependency versions to
React Native `>=0.76.0`, `react-native-gesture-handler >=2.25.0`,
`react-native-reanimated >=3.17.0`, and `react-native-safe-area-context
>=5.0.0`
([#844](#844))
- **BREAKING:** `HeaderRoot` now renders `titleAccessory` only when
`title` is present; use `children` for fully custom accessory-only title
rows
([#1076](#1076))
- **BREAKING:** `IconProps` now align with the underlying SVG component
props instead of `ViewProps`; move `View`-specific props to a wrapper
view if TypeScript flags them after upgrading
([#1090](#1090))

### 🎨 TWRNC Preset Updates (0.4.2)

#### Changed

- Expanded the `react` peer dependency range to `>=18.2.0`, allowing the
preset to install alongside newer React Native 0.76 and React 19 app
stacks
([#844](#844))

### ⚠️ Breaking Changes

#### `isReactNodeRenderable` removal (Shared)

**What Changed:**

- Removed `isReactNodeRenderable` from `@metamask/design-system-shared`
- Shared consumers should replace this helper with standard truthy
checks

**Migration:**

```tsx
// Before (0.11.0)
import { isReactNodeRenderable } from '@metamask/design-system-shared';

if (isReactNodeRenderable(title)) {
  return <Header title={title} />;
}

// After (0.12.0)
if (title) {
  return <Header title={title} />;
}
```

**Impact:**

- Any import of `isReactNodeRenderable` will fail after upgrading to
`0.12.0`
- See [Shared Migration
Guide](./packages/design-system-shared/MIGRATION.md#from-version-0110-to-0120)

#### React Native 0.76 peer minimums (React Native)

**What Changed:**

- Raised the minimum supported peer dependency versions to the React
Native 0.76 family used by the Storybook 10 migration

**Migration:**

```tsx
// Before (0.18.0)
// Compatible with older app stacks such as:
// react-native: 0.72.x
// react-native-gesture-handler: 2.12.x
// react-native-reanimated: 3.3.x
// react-native-safe-area-context: 4.x

// After (0.19.0)
// Consumers must be on at least:
// react-native: 0.76.x
// react-native-gesture-handler: 2.25.x
// react-native-reanimated: 3.17.x
// react-native-safe-area-context: 5.x
```

**Impact:**

- Apps on older React Native stacks will no longer satisfy peer
dependency requirements
- See [React Native Migration
Guide](./packages/design-system-react-native/MIGRATION.md#from-version-0180-to-0190)

#### `HeaderRoot` accessory rendering and `IconProps` typing (React
Native)

**What Changed:**

- `HeaderRoot` no longer renders `titleAccessory` unless `title` is
present
- `IconProps` now align with SVG props instead of `ViewProps`

**Migration:**

```tsx
// Before (0.18.0)
<HeaderRoot titleAccessory={<Icon name={IconName.Info} />} />
<Icon name={IconName.Lock} onLayout={handleLayout} />

// After (0.19.0)
<HeaderRoot title="Settings" titleAccessory={<Icon name={IconName.Info} />} />
<View onLayout={handleLayout}>
  <Icon name={IconName.Lock} />
</View>
```

**Impact:**

- Accessory-only `HeaderRoot` title rows must switch to `children` or
provide `title`
- `View`-specific props on `Icon` must move to a wrapper `View`
- See [React Native Migration
Guide](./packages/design-system-react-native/MIGRATION.md#from-version-0180-to-0190)

### ✅ Checklist

- [x] Changelogs updated with human-readable descriptions
- [x] Changelog validation passed (`yarn changelog:validate`)
- [x] Version bumps follow semantic versioning
- [x] design-system-shared: minor (`0.11.0` → `0.12.0`) - pre-1.0
breaking shared API cleanup plus new shared type exports
- [x] design-system-react: patch (`0.17.0` → `0.17.1`) - non-breaking
compatibility update that widens React peer support to include v19
- [x] design-system-react-native: minor (`0.18.0` → `0.19.0`) - pre-1.0
breaking peer minimum and API behavior/type changes
- [x] design-system-twrnc-preset: patch (`0.4.1` → `0.4.2`) -
non-breaking peer range expansion
- [x] Breaking changes documented with migration guidance
- [x] Migration guides updated with before/after examples (if breaking
changes)
- [x] PR references included in changelog entries

## **Pre-merge author checklist**

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs)
- [x] I've reviewed the [Release
Workflow](./.cursor/rules/release-workflow.md) cursor rule
- [x] All tests pass (`yarn build && yarn test && yarn lint`)
- [x] Changelog validation passes (`yarn changelog:validate`)

## **Pre-merge reviewer checklist**

- [ ] I've reviewed the [Reviewing Release
PRs](./docs/reviewing-release-prs.md) guide
- [ ] Package versions follow semantic versioning
- [ ] Changelog entries are consumer-facing (not commit message
regurgitation)
- [ ] Breaking changes are documented in MIGRATION.md with examples
- [ ] All unreleased changes are accounted for in changelogs
georgewrmarshall added a commit that referenced this pull request Apr 27, 2026
## **Description**

Widens `peerDependencies` for `@metamask/design-system-react` and
`@metamask/design-system-shared` to accept React 19 (`^19.0.0`)
alongside existing React 17 and 18 support.

https://react.dev/blog/2024/04/25/react-19-upgrade-guide

### Audit Summary

A full audit of React 19 breaking changes was performed against the
codebase. No breaking APIs are used:

| Breaking Change | Impact |
|---|---|
| `forwardRef` deprecated (not removed) | **None** — still works at
runtime, deprecation warnings only |
| `defaultProps` removed for function components | **None** — not used,
already using ES6 defaults |
| `propTypes` removed | **None** — not used |
| String refs / Legacy Context / `createFactory` removed | **None** —
not used |
| `ReactDOM.render` / `hydrate` / `findDOMNode` removed | **None** — not
used |
| `react-dom/test-utils` removed | **None** — not imported |
| `useRef` requires argument | **None** — all usages already pass `null`
|
| `Context.Provider` deprecated | **None** — only in react-native
packages (not in scope) |

### Verification

- Temporarily upgraded `storybook-react` to React 19.2.5 and confirmed
all components render correctly
- Build, tests (100% coverage), constraints, and lint all pass

### Future Phases

- **Phase 2**: Bump `@types/react` to v19, fix any TypeScript strictness
issues
- **Phase 3**: Migrate `forwardRef` to `ref` as prop pattern (large
refactor, not required for compat)

## **Related issues**

N/A

## **Manual testing steps**

1. Install packages in a React 19 project
2. Verify no peer dependency warnings
3. Verify components render correctly

## **Screenshots/Recordings**

### **Storybook running on React 19.2.5**

Components render correctly with React 19:


https://github.com/user-attachments/assets/6f8529e9-cea3-4732-98cc-5ed991d63adb


> Screenrecording captured with `storybook-react` temporarily using
`react@^19.0.0` / `react-dom@^19.0.0`. Confirmed via `yarn why react` →
`react@npm:19.2.5` for storybook-react workspace.

## **Pre-merge author checklist**

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs)
- [x] I've completed the PR template to the best of my ability
- [x] I've included tests if applicable
- [x] I've documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [ ] I've applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.



<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Dependency/metadata-only changes (peer range widening and lockfile
updates) with no runtime code changes; primary risk is consumers
encountering React 19-specific issues that aren’t covered by existing
tests.
> 
> **Overview**
> Adds React 19 compatibility by widening `peerDependencies` in
`@metamask/design-system-react` (also `react-dom`) and
`@metamask/design-system-shared` to allow `^19.0.0` alongside React
17/18.
> 
> Updates `yarn.lock` accordingly, including a bump of
`@testing-library/react` to `16.3.2` and related transitive lockfile
entries.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
a1a72f9. Bugbot is set up for automated
code reviews on this repo. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
georgewrmarshall added a commit that referenced this pull request Apr 27, 2026
## Release 34.0.0

This release adds new shared `TitleHub` and `Checkbox` type contracts,
expands React 19 support for web and shared packages, and publishes a
React Native release that aligns its supported runtime with the React
Native 0.76 / Storybook 10 stack.

### 📦 Package Versions

- `@metamask/design-system-shared`: **0.12.0**
- `@metamask/design-system-react`: **0.17.1**
- `@metamask/design-system-react-native`: **0.19.0**
- `@metamask/design-system-twrnc-preset`: **0.4.2**

### 🔄 Shared Type Updates (0.12.0)

#### Shared contract additions and API cleanup
([#1052](#1052),
[#1040](#1040),
[#1076](#1076),
[#1089](#1089))

**What Changed:**

- Added `TitleHubPropsShared` and `CheckboxPropsShared` to
`@metamask/design-system-shared`
- Removed `isReactNodeRenderable` from the public shared API
- Expanded the shared package `react` peer dependency range to support
React 19

**Impact:**

- Enables consistent `TitleHub` and `Checkbox` implementations across
React and React Native
- Consumers importing `isReactNodeRenderable` must replace that import
with plain truthy checks
- Shared consumers on React 19 can now satisfy peer dependency
requirements without overrides

### 🌐 React Web Updates (0.17.1)

#### Changed

- Expanded the `react` and `react-dom` peer dependency ranges to support
React 19 consumers without changing the public component API
([#1089](#1089))

### 📱 React Native Updates (0.19.0)

#### Added

- Added `TitleHub` for stacked title, amount, and bottom-label layouts
with optional accessory slots
([#1052](#1052))

#### Changed

- **BREAKING:** Raised the minimum supported peer dependency versions to
React Native `>=0.76.0`, `react-native-gesture-handler >=2.25.0`,
`react-native-reanimated >=3.17.0`, and `react-native-safe-area-context
>=5.0.0`
([#844](#844))
- **BREAKING:** `HeaderRoot` now renders `titleAccessory` only when
`title` is present; use `children` for fully custom accessory-only title
rows
([#1076](#1076))
- **BREAKING:** `IconProps` now align with the underlying SVG component
props instead of `ViewProps`; move `View`-specific props to a wrapper
view if TypeScript flags them after upgrading
([#1090](#1090))

### 🎨 TWRNC Preset Updates (0.4.2)

#### Changed

- Expanded the `react` peer dependency range to `>=18.2.0`, allowing the
preset to install alongside newer React Native 0.76 and React 19 app
stacks
([#844](#844))

### ⚠️ Breaking Changes

#### `isReactNodeRenderable` removal (Shared)

**What Changed:**

- Removed `isReactNodeRenderable` from `@metamask/design-system-shared`
- Shared consumers should replace this helper with standard truthy
checks

**Migration:**

```tsx
// Before (0.11.0)
import { isReactNodeRenderable } from '@metamask/design-system-shared';

if (isReactNodeRenderable(title)) {
  return <Header title={title} />;
}

// After (0.12.0)
if (title) {
  return <Header title={title} />;
}
```

**Impact:**

- Any import of `isReactNodeRenderable` will fail after upgrading to
`0.12.0`
- See [Shared Migration
Guide](./packages/design-system-shared/MIGRATION.md#from-version-0110-to-0120)

#### React Native 0.76 peer minimums (React Native)

**What Changed:**

- Raised the minimum supported peer dependency versions to the React
Native 0.76 family used by the Storybook 10 migration

**Migration:**

```tsx
// Before (0.18.0)
// Compatible with older app stacks such as:
// react-native: 0.72.x
// react-native-gesture-handler: 2.12.x
// react-native-reanimated: 3.3.x
// react-native-safe-area-context: 4.x

// After (0.19.0)
// Consumers must be on at least:
// react-native: 0.76.x
// react-native-gesture-handler: 2.25.x
// react-native-reanimated: 3.17.x
// react-native-safe-area-context: 5.x
```

**Impact:**

- Apps on older React Native stacks will no longer satisfy peer
dependency requirements
- See [React Native Migration
Guide](./packages/design-system-react-native/MIGRATION.md#from-version-0180-to-0190)

#### `HeaderRoot` accessory rendering and `IconProps` typing (React
Native)

**What Changed:**

- `HeaderRoot` no longer renders `titleAccessory` unless `title` is
present
- `IconProps` now align with SVG props instead of `ViewProps`

**Migration:**

```tsx
// Before (0.18.0)
<HeaderRoot titleAccessory={<Icon name={IconName.Info} />} />
<Icon name={IconName.Lock} onLayout={handleLayout} />

// After (0.19.0)
<HeaderRoot title="Settings" titleAccessory={<Icon name={IconName.Info} />} />
<View onLayout={handleLayout}>
  <Icon name={IconName.Lock} />
</View>
```

**Impact:**

- Accessory-only `HeaderRoot` title rows must switch to `children` or
provide `title`
- `View`-specific props on `Icon` must move to a wrapper `View`
- See [React Native Migration
Guide](./packages/design-system-react-native/MIGRATION.md#from-version-0180-to-0190)

### ✅ Checklist

- [x] Changelogs updated with human-readable descriptions
- [x] Changelog validation passed (`yarn changelog:validate`)
- [x] Version bumps follow semantic versioning
- [x] design-system-shared: minor (`0.11.0` → `0.12.0`) - pre-1.0
breaking shared API cleanup plus new shared type exports
- [x] design-system-react: patch (`0.17.0` → `0.17.1`) - non-breaking
compatibility update that widens React peer support to include v19
- [x] design-system-react-native: minor (`0.18.0` → `0.19.0`) - pre-1.0
breaking peer minimum and API behavior/type changes
- [x] design-system-twrnc-preset: patch (`0.4.1` → `0.4.2`) -
non-breaking peer range expansion
- [x] Breaking changes documented with migration guidance
- [x] Migration guides updated with before/after examples (if breaking
changes)
- [x] PR references included in changelog entries

## **Pre-merge author checklist**

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs)
- [x] I've reviewed the [Release
Workflow](./.cursor/rules/release-workflow.md) cursor rule
- [x] All tests pass (`yarn build && yarn test && yarn lint`)
- [x] Changelog validation passes (`yarn changelog:validate`)

## **Pre-merge reviewer checklist**

- [ ] I've reviewed the [Reviewing Release
PRs](./docs/reviewing-release-prs.md) guide
- [ ] Package versions follow semantic versioning
- [ ] Changelog entries are consumer-facing (not commit message
regurgitation)
- [ ] Breaking changes are documented in MIGRATION.md with examples
- [ ] All unreleased changes are accounted for in changelogs
cursor Bot pushed a commit that referenced this pull request Apr 28, 2026
## **Description**

Widens `peerDependencies` for `@metamask/design-system-react` and
`@metamask/design-system-shared` to accept React 19 (`^19.0.0`)
alongside existing React 17 and 18 support.

https://react.dev/blog/2024/04/25/react-19-upgrade-guide

### Audit Summary

A full audit of React 19 breaking changes was performed against the
codebase. No breaking APIs are used:

| Breaking Change | Impact |
|---|---|
| `forwardRef` deprecated (not removed) | **None** — still works at
runtime, deprecation warnings only |
| `defaultProps` removed for function components | **None** — not used,
already using ES6 defaults |
| `propTypes` removed | **None** — not used |
| String refs / Legacy Context / `createFactory` removed | **None** —
not used |
| `ReactDOM.render` / `hydrate` / `findDOMNode` removed | **None** — not
used |
| `react-dom/test-utils` removed | **None** — not imported |
| `useRef` requires argument | **None** — all usages already pass `null`
|
| `Context.Provider` deprecated | **None** — only in react-native
packages (not in scope) |

### Verification

- Temporarily upgraded `storybook-react` to React 19.2.5 and confirmed
all components render correctly
- Build, tests (100% coverage), constraints, and lint all pass

### Future Phases

- **Phase 2**: Bump `@types/react` to v19, fix any TypeScript strictness
issues
- **Phase 3**: Migrate `forwardRef` to `ref` as prop pattern (large
refactor, not required for compat)

## **Related issues**

N/A

## **Manual testing steps**

1. Install packages in a React 19 project
2. Verify no peer dependency warnings
3. Verify components render correctly

## **Screenshots/Recordings**

### **Storybook running on React 19.2.5**

Components render correctly with React 19:


https://github.com/user-attachments/assets/6f8529e9-cea3-4732-98cc-5ed991d63adb


> Screenrecording captured with `storybook-react` temporarily using
`react@^19.0.0` / `react-dom@^19.0.0`. Confirmed via `yarn why react` →
`react@npm:19.2.5` for storybook-react workspace.

## **Pre-merge author checklist**

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs)
- [x] I've completed the PR template to the best of my ability
- [x] I've included tests if applicable
- [x] I've documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [ ] I've applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.



<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Dependency/metadata-only changes (peer range widening and lockfile
updates) with no runtime code changes; primary risk is consumers
encountering React 19-specific issues that aren’t covered by existing
tests.
> 
> **Overview**
> Adds React 19 compatibility by widening `peerDependencies` in
`@metamask/design-system-react` (also `react-dom`) and
`@metamask/design-system-shared` to allow `^19.0.0` alongside React
17/18.
> 
> Updates `yarn.lock` accordingly, including a bump of
`@testing-library/react` to `16.3.2` and related transitive lockfile
entries.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
a1a72f9. Bugbot is set up for automated
code reviews on this repo. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
cursor Bot pushed a commit that referenced this pull request Apr 28, 2026
## Release 34.0.0

This release adds new shared `TitleHub` and `Checkbox` type contracts,
expands React 19 support for web and shared packages, and publishes a
React Native release that aligns its supported runtime with the React
Native 0.76 / Storybook 10 stack.

### 📦 Package Versions

- `@metamask/design-system-shared`: **0.12.0**
- `@metamask/design-system-react`: **0.17.1**
- `@metamask/design-system-react-native`: **0.19.0**
- `@metamask/design-system-twrnc-preset`: **0.4.2**

### 🔄 Shared Type Updates (0.12.0)

#### Shared contract additions and API cleanup
([#1052](#1052),
[#1040](#1040),
[#1076](#1076),
[#1089](#1089))

**What Changed:**

- Added `TitleHubPropsShared` and `CheckboxPropsShared` to
`@metamask/design-system-shared`
- Removed `isReactNodeRenderable` from the public shared API
- Expanded the shared package `react` peer dependency range to support
React 19

**Impact:**

- Enables consistent `TitleHub` and `Checkbox` implementations across
React and React Native
- Consumers importing `isReactNodeRenderable` must replace that import
with plain truthy checks
- Shared consumers on React 19 can now satisfy peer dependency
requirements without overrides

### 🌐 React Web Updates (0.17.1)

#### Changed

- Expanded the `react` and `react-dom` peer dependency ranges to support
React 19 consumers without changing the public component API
([#1089](#1089))

### 📱 React Native Updates (0.19.0)

#### Added

- Added `TitleHub` for stacked title, amount, and bottom-label layouts
with optional accessory slots
([#1052](#1052))

#### Changed

- **BREAKING:** Raised the minimum supported peer dependency versions to
React Native `>=0.76.0`, `react-native-gesture-handler >=2.25.0`,
`react-native-reanimated >=3.17.0`, and `react-native-safe-area-context
>=5.0.0`
([#844](#844))
- **BREAKING:** `HeaderRoot` now renders `titleAccessory` only when
`title` is present; use `children` for fully custom accessory-only title
rows
([#1076](#1076))
- **BREAKING:** `IconProps` now align with the underlying SVG component
props instead of `ViewProps`; move `View`-specific props to a wrapper
view if TypeScript flags them after upgrading
([#1090](#1090))

### 🎨 TWRNC Preset Updates (0.4.2)

#### Changed

- Expanded the `react` peer dependency range to `>=18.2.0`, allowing the
preset to install alongside newer React Native 0.76 and React 19 app
stacks
([#844](#844))

### ⚠️ Breaking Changes

#### `isReactNodeRenderable` removal (Shared)

**What Changed:**

- Removed `isReactNodeRenderable` from `@metamask/design-system-shared`
- Shared consumers should replace this helper with standard truthy
checks

**Migration:**

```tsx
// Before (0.11.0)
import { isReactNodeRenderable } from '@metamask/design-system-shared';

if (isReactNodeRenderable(title)) {
  return <Header title={title} />;
}

// After (0.12.0)
if (title) {
  return <Header title={title} />;
}
```

**Impact:**

- Any import of `isReactNodeRenderable` will fail after upgrading to
`0.12.0`
- See [Shared Migration
Guide](./packages/design-system-shared/MIGRATION.md#from-version-0110-to-0120)

#### React Native 0.76 peer minimums (React Native)

**What Changed:**

- Raised the minimum supported peer dependency versions to the React
Native 0.76 family used by the Storybook 10 migration

**Migration:**

```tsx
// Before (0.18.0)
// Compatible with older app stacks such as:
// react-native: 0.72.x
// react-native-gesture-handler: 2.12.x
// react-native-reanimated: 3.3.x
// react-native-safe-area-context: 4.x

// After (0.19.0)
// Consumers must be on at least:
// react-native: 0.76.x
// react-native-gesture-handler: 2.25.x
// react-native-reanimated: 3.17.x
// react-native-safe-area-context: 5.x
```

**Impact:**

- Apps on older React Native stacks will no longer satisfy peer
dependency requirements
- See [React Native Migration
Guide](./packages/design-system-react-native/MIGRATION.md#from-version-0180-to-0190)

#### `HeaderRoot` accessory rendering and `IconProps` typing (React
Native)

**What Changed:**

- `HeaderRoot` no longer renders `titleAccessory` unless `title` is
present
- `IconProps` now align with SVG props instead of `ViewProps`

**Migration:**

```tsx
// Before (0.18.0)
<HeaderRoot titleAccessory={<Icon name={IconName.Info} />} />
<Icon name={IconName.Lock} onLayout={handleLayout} />

// After (0.19.0)
<HeaderRoot title="Settings" titleAccessory={<Icon name={IconName.Info} />} />
<View onLayout={handleLayout}>
  <Icon name={IconName.Lock} />
</View>
```

**Impact:**

- Accessory-only `HeaderRoot` title rows must switch to `children` or
provide `title`
- `View`-specific props on `Icon` must move to a wrapper `View`
- See [React Native Migration
Guide](./packages/design-system-react-native/MIGRATION.md#from-version-0180-to-0190)

### ✅ Checklist

- [x] Changelogs updated with human-readable descriptions
- [x] Changelog validation passed (`yarn changelog:validate`)
- [x] Version bumps follow semantic versioning
- [x] design-system-shared: minor (`0.11.0` → `0.12.0`) - pre-1.0
breaking shared API cleanup plus new shared type exports
- [x] design-system-react: patch (`0.17.0` → `0.17.1`) - non-breaking
compatibility update that widens React peer support to include v19
- [x] design-system-react-native: minor (`0.18.0` → `0.19.0`) - pre-1.0
breaking peer minimum and API behavior/type changes
- [x] design-system-twrnc-preset: patch (`0.4.1` → `0.4.2`) -
non-breaking peer range expansion
- [x] Breaking changes documented with migration guidance
- [x] Migration guides updated with before/after examples (if breaking
changes)
- [x] PR references included in changelog entries

## **Pre-merge author checklist**

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs)
- [x] I've reviewed the [Release
Workflow](./.cursor/rules/release-workflow.md) cursor rule
- [x] All tests pass (`yarn build && yarn test && yarn lint`)
- [x] Changelog validation passes (`yarn changelog:validate`)

## **Pre-merge reviewer checklist**

- [ ] I've reviewed the [Reviewing Release
PRs](./docs/reviewing-release-prs.md) guide
- [ ] Package versions follow semantic versioning
- [ ] Changelog entries are consumer-facing (not commit message
regurgitation)
- [ ] Breaking changes are documented in MIGRATION.md with examples
- [ ] All unreleased changes are accounted for in changelogs
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.

2 participants