truconsent_consent_notice_flutter 0.1.2
truconsent_consent_notice_flutter: ^0.1.2 copied to clipboard
Flutter SDK for TruConsent consent banner. This package provides native Flutter widgets for displaying and managing consent banners in Flutter applications.
truconsent_consent_notice_flutter #
Flutter SDK for TruConsent consent banner. This package provides native Flutter widgets for displaying and managing consent banners in Flutter applications.
Installation #
Add this to your package's pubspec.yaml file:
dependencies:
truconsent_consent_notice_flutter: ^0.1.2
Then run:
flutter pub get
Usage #
import 'package:truconsent_consent_notice_flutter/truconsent_consent_banner_flutter.dart';
TruConsentModal(
apiKey: 'your-api-key',
organizationId: 'your-org-id',
bannerId: 'your-banner-id',
userId: 'user-id',
onClose: (action) {
print('Consent action: $action');
},
)
API #
TruConsentModal #
Main widget for displaying the consent banner modal.
Parameters
apiKey(String, required): API key for authenticationorganizationId(String, required): Organization IDbannerId(String, required): Banner/Collection Point IDuserId(String, required): User ID for consent trackingapiBaseUrl(String, optional): Base URL for APIlogoUrl(String, optional): Company logo URLcompanyName(String, optional): Company nameonClose(Function, optional): Callback when modal closes
Version History #
0.1.1 (Latest) #
- Fixed code warnings and linter issues
- Replaced deprecated
withOpacity()withwithValues(alpha:) - Replaced deprecated
activeColorwithactiveThumbColor - Added comprehensive dartdoc comments to public API (20%+ coverage)
- Fixed dangling library doc comments
- Improved code quality and static analysis scores
0.1.0 #
- Initial release of TruConsent Flutter SDK
- Native Flutter widgets for consent banner display
- TruConsentModal widget for modal-based consent collection
- NativeRightCenter widget for Rights Center functionality
- Support for multiple languages (English, Hindi, Tamil)
- Consent management and tracking
- Integration with TruConsent API
- Support for GDPR and privacy compliance features
License #
MIT