Spotlight Effect Flutter Package

Overview

The Spotlight package provides a simple way to create spotlight effects in your Flutter applications. This package allows you to highlight specific areas of your UI, drawing attention to important elements.

Features

Easy integration with existing Flutter applications. Customizable spotlight effects. Supports various child widgets.

Installation

To use the Spotlight package, add it to your pubspec.yaml file:

dependencies:
  spotlight: ^1.0.0

Then, run the following command to install the package:

flutter pub get

Here’s a simple example of how to use the Spotlight package in your Flutter application:

import 'package:flutter/material.dart';
import 'package:spotlight/spotlight.dart';

void main() {
  runApp(const MyApp());
}
class MyApp extends StatelessWidget {
  const MyApp({super.key});
  
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Spot Light Effect',
      home: Scaffold(
        body: SpotlightScreen(
          child: Image.network(
              "https://th.bing.com/th/id/OIG4.7h3EEAkofdcgjDEjeOyg",
              fit: BoxFit.cover),
        ),
      ),
    );
  }
}

Explanation

SpotlightScreen: This widget wraps around the child widget you want to highlight. Image.network: In this example, we are using a network image as the child widget. Customization

You can customize the spotlight effect by modifying the properties of the SpotlightScreen widget. Refer to the package documentation for more details on available options.

Libraries

spotlight_effect