@product7/product7-js 0.5.4 → 0.5.6
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 +6 -5
- package/dist/README.md +6 -5
- package/dist/product7-js.js +821 -816
- package/dist/product7-js.js.map +1 -1
- package/dist/product7-js.min.js +1 -1
- package/dist/product7-js.min.js.map +1 -1
- package/package.json +1 -1
- package/src/api/services/{WebChatService.js → LiveChatService.js} +14 -14
- package/src/core/APIService.js +15 -15
- package/src/core/Product7.js +9 -4
- package/src/core/WebSocketService.js +1 -1
- package/src/docs/api.md +8 -8
- package/src/docs/example.md +9 -9
- package/src/docs/framework-integrations.md +3 -3
- package/src/index.js +37 -37
- package/src/styles/base.js +8 -8
- package/src/styles/{web-chat-components.js → live-chat-components.js} +114 -114
- package/src/styles/{web-chat-core.js → live-chat-core.js} +30 -30
- package/src/styles/{web-chat-features.js → live-chat-features.js} +20 -20
- package/src/styles/{web-chat-views.js → live-chat-views.js} +137 -137
- package/src/styles/live-chat.js +17 -0
- package/src/styles/{webChatCustomStyles.js → liveChatCustomStyles.js} +16 -16
- package/src/styles/styles.js +3 -3
- package/src/widgets/{WebChatWidget.js → LiveChatWidget.js} +166 -166
- package/src/widgets/WidgetFactory.js +2 -2
- package/src/widgets/{web-chat/WebChatState.js → live-chat/LiveChatState.js} +1 -1
- package/src/widgets/{web-chat/components/WebChatLauncher.js → live-chat/components/LiveChatLauncher.js} +15 -15
- package/src/widgets/{web-chat/components/WebChatPanel.js → live-chat/components/LiveChatPanel.js} +10 -10
- package/src/widgets/{web-chat → live-chat}/components/NavigationTabs.js +12 -12
- package/src/widgets/{web-chat → live-chat}/views/ChangelogView.js +16 -16
- package/src/widgets/{web-chat → live-chat}/views/ChatView.js +90 -90
- package/src/widgets/{web-chat → live-chat}/views/ConversationsView.js +23 -23
- package/src/widgets/{web-chat → live-chat}/views/HelpView.js +28 -28
- package/src/widgets/{web-chat → live-chat}/views/HomeView.js +52 -52
- package/src/widgets/{web-chat → live-chat}/views/PreChatFormView.js +16 -16
- package/types/index.d.ts +11 -9
- package/src/styles/web-chat.js +0 -17
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Product7 JS
|
|
1
|
+
# Product7 JS
|
|
2
2
|
|
|
3
3
|
[](https://badge.fury.io/js/%40product7%2Fproduct7-js)
|
|
4
4
|
[](https://bundlephobia.com/package/@product7/product7-js)
|
|
@@ -78,7 +78,7 @@ widget.mount();
|
|
|
78
78
|
| Widget | Type string | Description |
|
|
79
79
|
| --------- | ------------- | ----------------------------------------------------- |
|
|
80
80
|
| Feedback | `'feedback'` | Floating button that opens a feedback panel or modal |
|
|
81
|
-
|
|
|
81
|
+
| Live Chat | `'liveChat'` | Live chat, help articles, and changelog in one widget |
|
|
82
82
|
| Survey | `'survey'` | NPS, CSAT, CES, and custom multi-step surveys |
|
|
83
83
|
| Inline | `'inline'` | Embed feedback directly into a page element |
|
|
84
84
|
|
|
@@ -89,14 +89,14 @@ const feedback = sdk.createFeedbackWidget({
|
|
|
89
89
|
});
|
|
90
90
|
feedback.mount();
|
|
91
91
|
|
|
92
|
-
//
|
|
93
|
-
const
|
|
92
|
+
// Live Chat
|
|
93
|
+
const liveChat = sdk.createLiveChatWidget({
|
|
94
94
|
position: 'bottom-right',
|
|
95
95
|
teamName: 'Support Team',
|
|
96
96
|
enableHelp: true,
|
|
97
97
|
enableChangelog: true,
|
|
98
98
|
});
|
|
99
|
-
|
|
99
|
+
liveChat.mount();
|
|
100
100
|
|
|
101
101
|
// Survey: fetch active surveys and show on load
|
|
102
102
|
const surveys = await sdk.getActiveSurveys({ includeEligibility: true });
|
|
@@ -167,3 +167,4 @@ sdk.destroy(); // call on app unmount to prevent memory leaks
|
|
|
167
167
|
---
|
|
168
168
|
|
|
169
169
|
Made by the [Product7 Team](https://product7.io)
|
|
170
|
+
|
package/dist/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Product7 JS
|
|
1
|
+
# Product7 JS
|
|
2
2
|
|
|
3
3
|
[](https://badge.fury.io/js/%40product7%2Fproduct7-js)
|
|
4
4
|
[](https://bundlephobia.com/package/@product7/product7-js)
|
|
@@ -78,7 +78,7 @@ widget.mount();
|
|
|
78
78
|
| Widget | Type string | Description |
|
|
79
79
|
| --------- | ------------- | ----------------------------------------------------- |
|
|
80
80
|
| Feedback | `'feedback'` | Floating button that opens a feedback panel or modal |
|
|
81
|
-
|
|
|
81
|
+
| Live Chat | `'liveChat'` | Live chat, help articles, and changelog in one widget |
|
|
82
82
|
| Survey | `'survey'` | NPS, CSAT, CES, and custom multi-step surveys |
|
|
83
83
|
| Inline | `'inline'` | Embed feedback directly into a page element |
|
|
84
84
|
|
|
@@ -89,14 +89,14 @@ const feedback = sdk.createFeedbackWidget({
|
|
|
89
89
|
});
|
|
90
90
|
feedback.mount();
|
|
91
91
|
|
|
92
|
-
//
|
|
93
|
-
const
|
|
92
|
+
// Live Chat
|
|
93
|
+
const liveChat = sdk.createLiveChatWidget({
|
|
94
94
|
position: 'bottom-right',
|
|
95
95
|
teamName: 'Support Team',
|
|
96
96
|
enableHelp: true,
|
|
97
97
|
enableChangelog: true,
|
|
98
98
|
});
|
|
99
|
-
|
|
99
|
+
liveChat.mount();
|
|
100
100
|
|
|
101
101
|
// Survey: fetch active surveys and show on load
|
|
102
102
|
const surveys = await sdk.getActiveSurveys({ includeEligibility: true });
|
|
@@ -167,3 +167,4 @@ sdk.destroy(); // call on app unmount to prevent memory leaks
|
|
|
167
167
|
---
|
|
168
168
|
|
|
169
169
|
Made by the [Product7 Team](https://product7.io)
|
|
170
|
+
|