solucx_widget 1.0.1 copy "solucx_widget: ^1.0.1" to clipboard
solucx_widget: ^1.0.1 copied to clipboard

retracted

SoluCXWidget is a Flutter widget that allows you to integrate SoluCX functionalities into your Flutter application.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:solucx_widget/models/solucx_widget_data.dart';
import 'package:solucx_widget/models/solucx_widget_options.dart';
import 'package:solucx_widget/models/solucx_widget_type.dart';
import 'package:solucx_widget/widgets/solucx_widget.dart';

void main() async {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: MyHomePage(
        title: Row(
          mainAxisAlignment: MainAxisAlignment.center,
          children: [
            Text("SoluCX Widget",
                style: TextStyle(fontSize: 20, color: Colors.white)),
          ],
        ),
      ),
    );
  }
}

class MyHomePage extends StatelessWidget {
  const MyHomePage({super.key, required this.title});

  final Widget title;

  @override
  Widget build(BuildContext context) {
    final size = MediaQuery.of(context).size;
    final screenHeight = size.height;
    final screenWidth = size.width;

    return DefaultTabController(
      length: 4,
      child: Scaffold(
        appBar: AppBar(
          backgroundColor: Color.fromARGB(255, 50, 115, 153),
          title: title,
          bottom: TabBar(
            indicatorColor: Colors.white,
            labelColor: Colors.white,
            unselectedLabelColor: Colors.grey,
            tabs: [
              Tab(icon: Icon(Icons.line_axis), text: 'Inline'),
              Tab(icon: Icon(Icons.border_bottom), text: 'Bottom'),
              Tab(icon: Icon(Icons.border_top), text: 'Top'),
              Tab(icon: Icon(Icons.window), text: 'Modal'),
            ],
          ),
        ),
        body: TabBarView(
          children: [
            SoluCXWidget(
              soluCXKey: 'my-key',
              data: SoluCXWidgetData(
                name: "John Doe",
                email: "teste@teste.com",
                cpf: "12345678900",
                journey: "my-journey",
                clientId: 'abc123',
              ),
              type: SoluCXWidgetType.inline,
              options: SoluCXWidgetOptions(
                displayHeight: screenHeight,
                displayWidth: screenWidth,
              ),
            ),
            SoluCXWidget(
              soluCXKey: 'my-key',
              data: SoluCXWidgetData(
                name: "John Doe",
                email: "teste@teste.com",
                cpf: "12345678900",
                journey: "my-journey",
                clientId: 'abc123',
              ),
              type: SoluCXWidgetType.bottom,
              options: SoluCXWidgetOptions(
                displayHeight: screenHeight,
                displayWidth: screenWidth,
              ),
            ),
            SoluCXWidget(
              soluCXKey: 'my-key',
              data: SoluCXWidgetData(
                name: "John Doe",
                email: "teste@teste.com",
                cpf: "12345678900",
                journey: "my-journey",
                clientId: 'abc123',
              ),
              type: SoluCXWidgetType.bottom,
              options: SoluCXWidgetOptions(
                displayHeight: screenHeight,
                displayWidth: screenWidth,
              ),
            ),
            SoluCXWidget(
              soluCXKey: 'my-key',
              data: SoluCXWidgetData(
                name: "John Doe",
                email: "teste@teste.com",
                cpf: "12345678900",
                journey: "my-journey",
                clientId: 'abc123',
              ),
              type: SoluCXWidgetType.modal,
              options: SoluCXWidgetOptions(
                displayHeight: screenHeight,
                displayWidth: screenWidth,
              ),
            ),
          ],
        ),
      ),
    );
  }
}
1
likes
0
points
65
downloads

Publisher

verified publishersolucx.com.br

Weekly Downloads

SoluCXWidget is a Flutter widget that allows you to integrate SoluCX functionalities into your Flutter application.

Homepage

License

unknown (license)

Dependencies

flutter, flutter_dotenv, shared_preferences, webview_flutter, webview_flutter_platform_interface

More

Packages that depend on solucx_widget