solucx_widget 1.0.0
solucx_widget: ^1.0.0 copied to clipboard
SoluCXWidget is a Flutter widget that allows you to integrate SoluCX functionalities into your Flutter application.
SoluCXWidget #
The SoluCXWidget
is a Flutter widget that allows integration with the SoluCX survey system. It offers different types of widgets that can be displayed in various positions on the screen, such as top, bottom, modal, or inline.
Features #
- Support for different widget types:
bottom
,top
,modal
,inline
. - Control widget visibility.
- Dynamic widget resizing.
- Control of attempts and data collection intervals.
- Integration with WebView for displaying web content.
Getting Started #
Prerequisites #
- Flutter SDK
- Project dependencies listed in
pubspec.yaml
- Internet permission for Android and iOS
Installation #
Add SoluCXWidget
to your Flutter project:
dependencies:
flutter:
sdk: flutter
solucx_widget: ^1.0.0
Configuration #
Android
Add the following permission to your AndroidManifest.xml
file:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.yourapp">
<uses-permission android:name="android.permission.INTERNET"/>
<!-- ...existing code... -->
</manifest>
iOS
Add the following to your Info.plist
file:
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
Usage #
Here is a basic example of how to use SoluCXWidget
:
import 'package:flutter/material.dart';
import 'package:solucx_widget/solucx_widget.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: Text('SoluCX Widget Example'),
),
body: Center(
child: SoluCXWidget(
soluCXKey: 'your-solucx-key',
type: SoluCXWidgetType.bottom,
data: SoluCXWidgetData(
clientId: 'client-id',
email: 'client@example.com',
),
options: SoluCXWidgetOptions(
displayWidth: 300,
displayHeight: 600,
widgetWidth: 1.0,
retryAttempts: 5,
retryInterval: 1,
collectInterval: 60,
collectPartialInterval: 0,
),
),
),
),
);
}
}
Additional Information #
For more information on how to contribute to the project, report issues, and what to expect from the package authors, please refer to the official documentation.