Info Label
Overview
Info Label is a Flutter library that provides customizable components for displaying information labels in Flutter applications. These labels can be used to convey various types of information, such as success messages, errors, warnings, or additional details, with flexible styling options.
Features
- InfoLabelWidget: A widget for creating customizable information labels with text, icons, and various styling options.
- TypeDistributionColor: An enum defining different color distribution configurations for labels to optimize readability and visual appeal.
- TypeInfoLabel: An enum representing different types of labels with associated meanings and colors for quick and easy labeling of information.
Getting Started
- Add the
info_label
package to yourpubspec.yaml
file:
dependencies:
info_label: ^1.2.3
Then, import the library in your Dart code:
import 'package:info_label/info_label.dart';
Usage
Here's a simple example demonstrating how to use the InfoLabelWidget
:
import 'package:flutter/material.dart';
import 'package:info_label/info_label.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: Text('Info Label Example'),
),
body: Center(
child: InfoLabel(
text: 'Hello, World!',
typeColor: TypeDistributionColor.solid,
),
),
),
);
}
}
Current Golden test.
On App.
Documentation
Contributing
Contributions to this project are welcome! If you have any ideas, suggestions, or find any issues, feel free to open an issue or submit a pull request on GitHub.
Libraries
- info_label
- Library for customizable information labels in Flutter applications.