crisp 0.1.4 copy "crisp: ^0.1.4" to clipboard
crisp: ^0.1.4 copied to clipboard

outdated

Connect with Crisp Chat, register a user to chat (or not) and render a chat widget.

example/lib/main.dart

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

void main() => runApp(MyApp());

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  CrispMain crispMain;

  @override
  void initState() {
    super.initState();

    crispMain = CrispMain(
      websiteId: '11385bfa-3cf8-4a0f-beba-44629aec6779',
      locale: 'pt-br',
    );

    crispMain.register(
      user: CrispUser(
        email: "leo@provider.com",
        avatar: 'https://avatars2.githubusercontent.com/u/16270189?s=200&v=4',
        nickname: "João Cardoso",
        phone: "5511987654321",
      ),
    );

    crispMain.setMessage("Hello world");
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: CrispView(
        appBar: AppBar(
          title: const Text('Widget WebView'),
        ),
        loadingWidget: Center(
          child: CircularProgressIndicator(),
        ),
        crispMain: crispMain,
      ),
    );
  }
}
28
likes
0
pub points
89%
popularity

Publisher

verified publisheroiluna.com

Connect with Crisp Chat, register a user to chat (or not) and render a chat widget.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, flutter_inappwebview, url_launcher

More

Packages that depend on crisp