@kaizentech/wizard-sdk 1.0.39-beta.1 → 1.0.39-beta.10
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 +110 -0
- package/dist/klp-wizard.min.js +3 -3
- package/package.json +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
# 🧙 KLP Wizard SDK
|
|
2
|
+
|
|
3
|
+
A lightweight and modern frontend SDK that can be embedded via CDN. Provides an interactive wizard modal with features such as campaigns, rewards, FAQ, and recent activities.
|
|
4
|
+
|
|
5
|
+
## 📋 Table of Contents
|
|
6
|
+
|
|
7
|
+
- [Features](#-features)
|
|
8
|
+
- [Installation](#-installation)
|
|
9
|
+
- [Quick Start](#-quick-start)
|
|
10
|
+
|
|
11
|
+
## ✨ Features
|
|
12
|
+
|
|
13
|
+
- 🎯 **CDN Integration**: Easy integration with a single script tag
|
|
14
|
+
- 🎨 **Modern UI**: Sleek and modern interface with Inter font
|
|
15
|
+
- 📱 **Responsive**: Perfect appearance on all devices
|
|
16
|
+
- 🔄 **SPA Support**: Automatic remount in Single Page Applications
|
|
17
|
+
- 🎭 **Multiple Pages**: Welcome, Demo, Campaigns, Rewards, FAQ, and Last Activities pages
|
|
18
|
+
- 🔐 **Authentication**: Flexible auth configuration
|
|
19
|
+
- 🎨 **Customizable**: Font and appearance settings
|
|
20
|
+
- 📊 **Event Tracking**: Automatic event push support
|
|
21
|
+
|
|
22
|
+
## 📦 Installation
|
|
23
|
+
|
|
24
|
+
### Install via NPM
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
# Latest (stable) version
|
|
28
|
+
npm install @kaizentech/wizard-sdk
|
|
29
|
+
|
|
30
|
+
# Beta version
|
|
31
|
+
npm install @kaizentech/wizard-sdk@beta
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### Using CDN
|
|
35
|
+
|
|
36
|
+
```html
|
|
37
|
+
<script
|
|
38
|
+
defer
|
|
39
|
+
src="https://unpkg.com/@kaizentech/wizard-sdk/dist/klp-wizard.min.js"
|
|
40
|
+
api-key="YOUR_API_KEY"
|
|
41
|
+
></script>
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## 🚀 Quick Start
|
|
45
|
+
|
|
46
|
+
1. **Add Script Tag**
|
|
47
|
+
|
|
48
|
+
```html
|
|
49
|
+
<!DOCTYPE html>
|
|
50
|
+
<html lang="en">
|
|
51
|
+
<head>
|
|
52
|
+
<meta charset="UTF-8">
|
|
53
|
+
<title>My Website</title>
|
|
54
|
+
</head>
|
|
55
|
+
<body>
|
|
56
|
+
<!-- KLP Wizard SDK -->
|
|
57
|
+
<script
|
|
58
|
+
defer
|
|
59
|
+
src="https://unpkg.com/@kaizentech/wizard-sdk/dist/klp-wizard.min.js"
|
|
60
|
+
api-key="YOUR_API_KEY"
|
|
61
|
+
></script>
|
|
62
|
+
</body>
|
|
63
|
+
</html>
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
2. **Get Your API Key**
|
|
67
|
+
|
|
68
|
+
You can get your API key from the [Revx management panel](https://www.kaizentech.net/book-a-demo).
|
|
69
|
+
|
|
70
|
+
3. **Ready!**
|
|
71
|
+
|
|
72
|
+
After the script loads, a floating action button will automatically appear in the bottom right corner of your page.
|
|
73
|
+
|
|
74
|
+
## 🔧 Technologies
|
|
75
|
+
|
|
76
|
+
- **ESBuild**: Fast JavaScript bundler
|
|
77
|
+
- **Axios**: For HTTP requests
|
|
78
|
+
- **JavaScript Obfuscator**: Code obfuscation in production builds
|
|
79
|
+
|
|
80
|
+
## 📝 Notes
|
|
81
|
+
|
|
82
|
+
### SPA (Single Page Application) Support
|
|
83
|
+
|
|
84
|
+
The SDK works automatically in SPAs. It monitors History API changes (`pushState`, `replaceState`, `popstate`) and automatically remounts the modal and floating button.
|
|
85
|
+
|
|
86
|
+
### Font Management
|
|
87
|
+
|
|
88
|
+
The SDK uses Inter font by default. Different fonts can be selected through configuration:
|
|
89
|
+
- Inter (default)
|
|
90
|
+
- Roboto
|
|
91
|
+
- Open Sans
|
|
92
|
+
- Lato
|
|
93
|
+
- Montserrat
|
|
94
|
+
- Poppins
|
|
95
|
+
- Oswald
|
|
96
|
+
- Merriweather
|
|
97
|
+
- Raleway
|
|
98
|
+
- Playfair Display
|
|
99
|
+
|
|
100
|
+
### Event Tracking
|
|
101
|
+
|
|
102
|
+
The SDK automatically performs event tracking. Events are pushed to the backend and can be viewed in the console when debug mode is enabled.
|
|
103
|
+
|
|
104
|
+
## 👤 Author
|
|
105
|
+
|
|
106
|
+
**[KaizenTech](https://www.kaizentech.net/loyalty-platform)**
|
|
107
|
+
|
|
108
|
+
---
|
|
109
|
+
|
|
110
|
+
⭐ If you liked this project, don't forget to give it a star!
|