lulichat 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,68 @@
1
+ # Lulichat Support Chat
2
+
3
+ Lulichat Support Chat is a React library that provides a chat interface for web applications. It includes a chat icon that opens a contact form for users to submit their contact information, and it establishes a socket connection for real-time chat functionality.
4
+
5
+ ## Features
6
+
7
+ - Chat icon positioned at the bottom right corner of the screen.
8
+ - Contact information collection form with validation.
9
+ - Real-time chat interface using WebSocket.
10
+ - Easy integration into any React application.
11
+
12
+ ## Installation
13
+
14
+ To install the Lulichat Support Chat library, run the following command:
15
+
16
+ ```bash
17
+ npm install lulichat
18
+ ```
19
+
20
+ ## Usage
21
+
22
+ To use the Lulichat Support Chat in your application, import the components as follows:
23
+
24
+ ```tsx
25
+ import Lulichat from "lulichat";
26
+ ```
27
+
28
+ ### Example
29
+
30
+ ```tsx
31
+ import React from "react";
32
+ import Lulichat from "lulichat";
33
+
34
+ const App = () => {
35
+ return (
36
+ <div>
37
+ <h1>Welcome to My Application</h1>
38
+ <LuliChat
39
+ apiKey="LU...."
40
+ companyName="LuliChat Demo"
41
+ welcomeMessage="How can we help you today?"
42
+ primaryColor="#4f46e5"
43
+ allowAnonymous={true}
44
+ requireContactInfo={true}
45
+ position="bottom-right"
46
+ />
47
+ </div>
48
+ );
49
+ };
50
+
51
+ export default App;
52
+ ```
53
+
54
+ ## API
55
+
56
+ ### Components
57
+
58
+ - **ChatIcon**: Renders a chat icon that opens the contact form.
59
+ - **ContactForm**: Displays a form for users to input their contact details.
60
+ - **SupportChat**: Manages the chat interface and socket connection.
61
+
62
+ ## Contributing
63
+
64
+ Contributions are welcome! Please open an issue or submit a pull request for any improvements or bug fixes.
65
+
66
+ ## License
67
+
68
+ This project is licensed under the MIT License. See the LICENSE file for more details.