@product7/product7-js 0.5.5 → 0.5.7

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.
Files changed (40) hide show
  1. package/README.md +10 -10
  2. package/dist/README.md +10 -10
  3. package/dist/product7-js.js +7261 -7100
  4. package/dist/product7-js.js.map +1 -1
  5. package/dist/product7-js.min.js +1 -1
  6. package/dist/product7-js.min.js.map +1 -1
  7. package/package.json +1 -1
  8. package/src/api/services/{WebChatService.js → LiveChatService.js} +14 -14
  9. package/src/core/APIService.js +15 -15
  10. package/src/core/Product7.js +9 -4
  11. package/src/core/WebSocketService.js +1 -1
  12. package/src/docs/api.md +8 -8
  13. package/src/docs/example.md +9 -9
  14. package/src/docs/framework-integrations.md +3 -3
  15. package/src/index.js +38 -37
  16. package/src/styles/base.js +8 -8
  17. package/src/styles/{web-chat-components.js → liveChat-components.js} +114 -114
  18. package/src/styles/{web-chat-core.js → liveChat-core.js} +96 -31
  19. package/src/styles/{web-chat-features.js → liveChat-features.js} +20 -20
  20. package/src/styles/{web-chat-views.js → liveChat-views.js} +137 -137
  21. package/src/styles/liveChat.js +17 -0
  22. package/src/styles/{webChatCustomStyles.js → liveChatCustomStyles.js} +16 -16
  23. package/src/styles/styles.js +3 -3
  24. package/src/widgets/BaseWidget.js +2 -2
  25. package/src/widgets/ChangelogWidget.js +3 -3
  26. package/src/widgets/{WebChatWidget.js → LiveChatWidget.js} +169 -165
  27. package/src/widgets/SurveyWidget.js +7 -7
  28. package/src/widgets/WidgetFactory.js +2 -2
  29. package/src/widgets/{web-chat/WebChatState.js → liveChat/LiveChatState.js} +1 -1
  30. package/src/widgets/{web-chat/components/WebChatLauncher.js → liveChat/components/LiveChatLauncher.js} +16 -16
  31. package/src/widgets/{web-chat/components/WebChatPanel.js → liveChat/components/LiveChatPanel.js} +41 -10
  32. package/src/widgets/{web-chat → liveChat}/components/NavigationTabs.js +16 -16
  33. package/src/widgets/{web-chat → liveChat}/views/ChangelogView.js +17 -17
  34. package/src/widgets/{web-chat → liveChat}/views/ChatView.js +153 -95
  35. package/src/widgets/{web-chat → liveChat}/views/ConversationsView.js +24 -24
  36. package/src/widgets/{web-chat → liveChat}/views/HelpView.js +32 -32
  37. package/src/widgets/{web-chat → liveChat}/views/HomeView.js +52 -52
  38. package/src/widgets/{web-chat → liveChat}/views/PreChatFormView.js +15 -18
  39. package/types/index.d.ts +8 -9
  40. 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
  [![npm version](https://badge.fury.io/js/%40product7%2Fproduct7-js.svg)](https://badge.fury.io/js/%40product7%2Fproduct7-js)
4
4
  [![Bundle Size](https://img.shields.io/bundlephobia/minzip/@product7/product7-js)](https://bundlephobia.com/package/@product7/product7-js)
@@ -75,12 +75,12 @@ widget.mount();
75
75
 
76
76
  ## Widgets
77
77
 
78
- | Widget | Type string | Description |
79
- | --------- | ------------- | ----------------------------------------------------- |
80
- | Feedback | `'feedback'` | Floating button that opens a feedback panel or modal |
81
- | Web Chat | `'webChat'` | Live chat, help articles, and changelog in one widget |
82
- | Survey | `'survey'` | NPS, CSAT, CES, and custom multi-step surveys |
83
- | Inline | `'inline'` | Embed feedback directly into a page element |
78
+ | Widget | Type string | Description |
79
+ | --------- | ------------ | ----------------------------------------------------- |
80
+ | Feedback | `'feedback'` | Floating button that opens a feedback panel or modal |
81
+ | Live Chat | `'liveChat'` | Live chat, help articles, and changelog in one widget |
82
+ | Survey | `'survey'` | NPS, CSAT, CES, and custom multi-step surveys |
83
+ | Inline | `'inline'` | Embed feedback directly into a page element |
84
84
 
85
85
  ```javascript
86
86
  // Feedback
@@ -89,14 +89,14 @@ const feedback = sdk.createFeedbackWidget({
89
89
  });
90
90
  feedback.mount();
91
91
 
92
- // Web Chat
93
- const webChat = sdk.createWebChatWidget({
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
- webChat.mount();
99
+ liveChat.mount();
100
100
 
101
101
  // Survey: fetch active surveys and show on load
102
102
  const surveys = await sdk.getActiveSurveys({ includeEligibility: true });
package/dist/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Product7 JS
1
+ # Product7 JS
2
2
 
3
3
  [![npm version](https://badge.fury.io/js/%40product7%2Fproduct7-js.svg)](https://badge.fury.io/js/%40product7%2Fproduct7-js)
4
4
  [![Bundle Size](https://img.shields.io/bundlephobia/minzip/@product7/product7-js)](https://bundlephobia.com/package/@product7/product7-js)
@@ -75,12 +75,12 @@ widget.mount();
75
75
 
76
76
  ## Widgets
77
77
 
78
- | Widget | Type string | Description |
79
- | --------- | ------------- | ----------------------------------------------------- |
80
- | Feedback | `'feedback'` | Floating button that opens a feedback panel or modal |
81
- | Web Chat | `'webChat'` | Live chat, help articles, and changelog in one widget |
82
- | Survey | `'survey'` | NPS, CSAT, CES, and custom multi-step surveys |
83
- | Inline | `'inline'` | Embed feedback directly into a page element |
78
+ | Widget | Type string | Description |
79
+ | --------- | ------------ | ----------------------------------------------------- |
80
+ | Feedback | `'feedback'` | Floating button that opens a feedback panel or modal |
81
+ | Live Chat | `'liveChat'` | Live chat, help articles, and changelog in one widget |
82
+ | Survey | `'survey'` | NPS, CSAT, CES, and custom multi-step surveys |
83
+ | Inline | `'inline'` | Embed feedback directly into a page element |
84
84
 
85
85
  ```javascript
86
86
  // Feedback
@@ -89,14 +89,14 @@ const feedback = sdk.createFeedbackWidget({
89
89
  });
90
90
  feedback.mount();
91
91
 
92
- // Web Chat
93
- const webChat = sdk.createWebChatWidget({
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
- webChat.mount();
99
+ liveChat.mount();
100
100
 
101
101
  // Survey: fetch active surveys and show on load
102
102
  const surveys = await sdk.getActiveSurveys({ includeEligibility: true });