🌟 Shadex
Shadex is a lightweight Flutter widget that adds a customizable shadow effect to any widget — ideal for vector-based images like SVGs or other composable visuals. It gives your UI elements depth and polish without the performance hit of layering large assets.
✨ Features
- Adds a soft, blurred shadow behind any widget
- Highly customizable shadow color, blur, and offset
- Especially useful for SVG icons or vector illustrations
- Simple drop-in widget — no setup required
📦 Installation
Add the following to your pubspec.yaml
:
dependencies:
shadex:
git:
url: https://github.com/Munsif-Ali/shadex
or if you want to use the latest version from pub.dev, add:
dependencies:
shadex: ^1.0.2
Then run flutter pub get
to install the package.
🔧 Usage
import 'package:shadex/shadex.dart';
import 'package:flutter_svg/flutter_svg.dart';
Shadex(
child: SvgPicture.asset('assets/icons/star.svg'),
)
// Use with Icon widget
Shadex(
child: Icon(Icons.star, size: 50),
)
// Use with Text widget
Shadex(
child: Text('Hello, Shadex!', style: TextStyle(fontSize: 24)),
)
// Use with Image widget
Shadex(
child: Image.asset('assets/images/sample.png'),
)
🎨 Customization
Shadex(
child: SvgPicture.asset('assets/icons/star.svg'),
shadowColor: Colors.black45,
shadowBlurRadius: 6.0,
shadowOffset: Offset(4, 4),
)
📱 Screenshots
📜 License
This project is licensed under the MIT License. See the LICENSE file for details.