Skip to content
pubscout

corner_radius_plugin

1.0.0, released 5 weeks ago by ketanchoyal.dev

Flutter plugin to read device screen corner radii on Android and iOS

WASM-ready
$ flutter pub add corner_radius_plugin
Source repository

What it does

Provides the per‑corner radius of the active screen, including live updates on multi‑screen devices. It uses native APIs on Android 12+ and iOS 26+, falling back to a bundled JSON dataset for older versions.

AI-written summary of version 1.0.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to match UI elements to the device’s rounded corners
  • You’re building a multi‑screen app that must adapt to changing screen geometry
  • You want to animate or style widgets based on the real corner radius

Skip it when

  • You only need a generic rounded corner value
  • You’re targeting only web or desktop where screen corners are irrelevant

Strengths

  • Accurate per‑corner data on modern Android and iOS
  • Live stream of radius changes for multi‑screen devices
  • No external dependencies beyond Flutter SDK

Weaknesses

  • Only Android and iOS supported
  • Requires native platform code, so not usable on web/desktop

Setup

Kind
Plugin (native code)
Effort
Medium
Code generation
No
Direct dependencies
1

Add dependency in pubspec, run flutter pub get. No special permissions or build_runner needed.

import 'package:corner_radius_plugin/corner_radius_plugin.dart';

final radius = await CornerRadiusPlugin.init();
print('Top‑left radius: ${radius?.topLeft}');

Alternatives

Packages that do the same job and could replace corner_radius_plugin.

Works with

Packages commonly used together with corner_radius_plugin: ones it builds on, ones built on it, and its own family.