@seamly/web-ui 20.7.0 → 20.8.0-beta.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.
Files changed (226) hide show
  1. package/build/dist/lib/hooks.js +1 -1
  2. package/build/dist/lib/hooks.min.js +1 -1
  3. package/build/dist/lib/index.debug.js +945 -790
  4. package/build/dist/lib/index.debug.min.js +1 -1
  5. package/build/dist/lib/index.debug.min.js.LICENSE.txt +187 -131
  6. package/build/dist/lib/index.js +24800 -19606
  7. package/build/dist/lib/index.min.js +1 -1
  8. package/build/dist/lib/index.min.js.LICENSE.txt +38 -4
  9. package/build/dist/lib/standalone.js +32920 -26742
  10. package/build/dist/lib/standalone.min.js +1 -1
  11. package/build/dist/lib/standalone.min.js.LICENSE.txt +39 -0
  12. package/build/dist/lib/storage.js +2 -2
  13. package/build/dist/lib/storage.min.js +1 -1
  14. package/build/dist/lib/style-guide.js +8780 -7907
  15. package/build/dist/lib/style-guide.min.js +2 -1
  16. package/build/dist/lib/style-guide.min.js.LICENSE.txt +38 -0
  17. package/build/dist/lib/styles.css +1 -1
  18. package/build/dist/lib/utils.js +1 -2
  19. package/build/dist/lib/utils.min.js +1 -1
  20. package/package.json +19 -9
  21. package/src/icons/avatar_agent-32.svg +7 -0
  22. package/src/icons/avatar_bot-32.svg +6 -1
  23. package/src/javascripts/api/index.js +1 -1
  24. package/src/javascripts/{config.js → config.ts} +3 -1
  25. package/src/javascripts/config.types.ts +96 -0
  26. package/src/javascripts/domains/app/actions.ts +83 -0
  27. package/src/javascripts/domains/app/app.types.ts +3 -0
  28. package/src/javascripts/domains/app/hooks.js +3 -5
  29. package/src/javascripts/domains/app/selectors.ts +6 -0
  30. package/src/javascripts/domains/app/slice.ts +30 -0
  31. package/src/javascripts/domains/config/actions.ts +45 -0
  32. package/src/javascripts/domains/config/hooks.ts +19 -0
  33. package/src/javascripts/domains/config/selectors.ts +24 -0
  34. package/src/javascripts/domains/config/slice.ts +113 -0
  35. package/src/javascripts/domains/errors/index.js +13 -9
  36. package/src/javascripts/domains/forms/context.ts +14 -0
  37. package/src/javascripts/domains/forms/forms.types.ts +24 -0
  38. package/src/javascripts/domains/forms/{hooks.js → hooks.ts} +23 -26
  39. package/src/javascripts/domains/forms/{provider.js → provider.tsx} +20 -14
  40. package/src/javascripts/domains/forms/{selectors.js → selectors.ts} +7 -8
  41. package/src/javascripts/domains/forms/slice.ts +84 -0
  42. package/src/javascripts/domains/forms/utils.ts +15 -0
  43. package/src/javascripts/domains/i18n/actions.ts +24 -0
  44. package/src/javascripts/domains/i18n/{hooks.js → hooks.ts} +2 -2
  45. package/src/javascripts/domains/i18n/i18n.types.ts +6 -0
  46. package/src/javascripts/domains/i18n/selectors.ts +16 -0
  47. package/src/javascripts/domains/i18n/{reducer.js → slice.ts} +40 -37
  48. package/src/javascripts/domains/interrupt/{hooks.js → hooks.ts} +2 -2
  49. package/src/javascripts/domains/interrupt/{middleware.js → middleware.ts} +11 -8
  50. package/src/javascripts/domains/interrupt/selectors.ts +6 -0
  51. package/src/javascripts/domains/interrupt/slice.ts +40 -0
  52. package/src/javascripts/domains/options/middleware.js +9 -6
  53. package/src/javascripts/domains/redux/redux.types.ts +11 -0
  54. package/src/javascripts/domains/store/index.ts +53 -0
  55. package/src/javascripts/domains/store/slice.ts +642 -0
  56. package/src/javascripts/domains/store/store.types.ts +146 -0
  57. package/src/javascripts/domains/translations/components/chat-status.js +2 -2
  58. package/src/javascripts/domains/translations/components/options-button.js +1 -1
  59. package/src/javascripts/domains/translations/components/options-dialog/form.js +5 -5
  60. package/src/javascripts/domains/translations/components/options-dialog/index.js +2 -2
  61. package/src/javascripts/domains/translations/hooks.ts +114 -0
  62. package/src/javascripts/domains/translations/middleware.js +29 -27
  63. package/src/javascripts/domains/translations/selectors.ts +12 -0
  64. package/src/javascripts/domains/translations/slice.ts +120 -0
  65. package/src/javascripts/domains/translations/translations.types.ts +19 -0
  66. package/src/javascripts/domains/visibility/{actions.js → actions.ts} +25 -19
  67. package/src/javascripts/domains/visibility/{hooks.js → hooks.ts} +13 -10
  68. package/src/javascripts/domains/visibility/{selectors.js → selectors.ts} +3 -6
  69. package/src/javascripts/domains/visibility/slice.ts +38 -0
  70. package/src/javascripts/domains/visibility/utils.js +0 -9
  71. package/src/javascripts/domains/visibility/visibility.types.ts +6 -0
  72. package/src/javascripts/index.ts +92 -0
  73. package/src/javascripts/lib/engine/index.js +15 -11
  74. package/src/javascripts/lib/external-api/initialize-api.js +1 -1
  75. package/src/javascripts/lib/id.js +5 -8
  76. package/src/javascripts/lib/mutex.js +3 -1
  77. package/src/javascripts/lib/store/providers/cookie-storage.js +1 -1
  78. package/src/javascripts/lib/store/providers/session-storage.js +1 -1
  79. package/src/javascripts/package/hooks.js +2 -2
  80. package/src/javascripts/package/utils.js +0 -1
  81. package/src/javascripts/schema.ts +1448 -0
  82. package/src/javascripts/style-guide/components/app.js +6 -6
  83. package/src/javascripts/style-guide/components/static-core.js +87 -65
  84. package/src/javascripts/style-guide/components/view.js +4 -4
  85. package/src/javascripts/style-guide/state-helpers/index.js +5 -5
  86. package/src/javascripts/style-guide/states.js +67 -7
  87. package/src/javascripts/style-guide.ts +5 -0
  88. package/src/javascripts/ui/components/app-options/index.js +2 -4
  89. package/src/javascripts/ui/components/conversation/component-filter.js +1 -1
  90. package/src/javascripts/ui/components/conversation/conversation.js +11 -7
  91. package/src/javascripts/ui/components/conversation/event/card-message.js +2 -2
  92. package/src/javascripts/ui/components/conversation/event/carousel-component/components/controls.js +1 -1
  93. package/src/javascripts/ui/components/conversation/event/carousel-message/components/slide.js +1 -1
  94. package/src/javascripts/ui/components/conversation/event/carousel-message/index.js +2 -2
  95. package/src/javascripts/ui/components/conversation/event/choice-prompt.js +3 -3
  96. package/src/javascripts/ui/components/conversation/event/conversation-suggestions.js +19 -15
  97. package/src/javascripts/ui/components/conversation/event/cta.js +2 -2
  98. package/src/javascripts/ui/components/conversation/event/divider/variants/default.js +1 -1
  99. package/src/javascripts/ui/components/conversation/event/divider/variants/new-translation.js +44 -5
  100. package/src/javascripts/ui/components/conversation/event/event-participant.js +2 -2
  101. package/src/javascripts/ui/components/conversation/event/hooks/use-formatted-date.js +2 -2
  102. package/src/javascripts/ui/components/conversation/event/image-lightbox.js +1 -1
  103. package/src/javascripts/ui/components/conversation/event/image.js +6 -8
  104. package/src/javascripts/ui/components/conversation/event/participant.js +2 -2
  105. package/src/javascripts/ui/components/conversation/event/splash.js +4 -4
  106. package/src/javascripts/ui/components/conversation/event/text.js +2 -2
  107. package/src/javascripts/ui/components/conversation/event/translation.js +3 -3
  108. package/src/javascripts/ui/components/conversation/event/upload.js +3 -3
  109. package/src/javascripts/ui/components/conversation/event/video.js +2 -2
  110. package/src/javascripts/ui/components/conversation/message-container.js +4 -26
  111. package/src/javascripts/ui/components/core/seamly-api-context.js +1 -1
  112. package/src/javascripts/ui/components/core/seamly-core.js +15 -14
  113. package/src/javascripts/ui/components/core/seamly-event-subscriber.js +98 -92
  114. package/src/javascripts/ui/components/core/seamly-file-upload.js +20 -24
  115. package/src/javascripts/ui/components/core/seamly-initializer.js +1 -1
  116. package/src/javascripts/ui/components/core/seamly-instance-functions-loader.js +5 -4
  117. package/src/javascripts/ui/components/core/seamly-new-notifications.js +2 -2
  118. package/src/javascripts/ui/components/core/seamly-read-state.js +10 -17
  119. package/src/javascripts/ui/components/entry/deprecated-toggle-button.js +3 -3
  120. package/src/javascripts/ui/components/entry/entry-container.js +4 -6
  121. package/src/javascripts/ui/components/entry/text-entry/hooks.js +3 -3
  122. package/src/javascripts/ui/components/entry/text-entry/index.js +3 -2
  123. package/src/javascripts/ui/components/entry/text-entry/text-entry-form.js +6 -10
  124. package/src/javascripts/ui/components/entry/upload/file-upload-form.js +2 -2
  125. package/src/javascripts/ui/components/entry/upload/index.js +10 -9
  126. package/src/javascripts/ui/components/entry/upload-toggle.js +2 -2
  127. package/src/javascripts/ui/components/faq/faq.js +9 -7
  128. package/src/javascripts/ui/components/form-controls/file-input.js +1 -1
  129. package/src/javascripts/ui/components/form-controls/form.js +1 -1
  130. package/src/javascripts/ui/components/form-controls/input.js +1 -1
  131. package/src/javascripts/ui/components/form-controls/select.js +1 -1
  132. package/src/javascripts/ui/components/layout/agent-info.js +4 -4
  133. package/src/javascripts/ui/components/layout/chat-frame.js +3 -3
  134. package/src/javascripts/ui/components/layout/chat.js +11 -12
  135. package/src/javascripts/ui/components/layout/deprecated-app-frame.js +10 -9
  136. package/src/javascripts/ui/components/layout/header.js +1 -1
  137. package/src/javascripts/ui/components/layout/interrupt.js +23 -24
  138. package/src/javascripts/ui/components/layout/pre-chat-messages.js +11 -11
  139. package/src/javascripts/ui/components/layout/privacy-disclaimer.js +2 -2
  140. package/src/javascripts/ui/components/options/options-button.js +14 -10
  141. package/src/javascripts/ui/components/options/transcript/index.js +2 -2
  142. package/src/javascripts/ui/components/options/transcript/transcript-form.js +1 -1
  143. package/src/javascripts/ui/components/suggestions/index.js +14 -10
  144. package/src/javascripts/ui/components/view/deprecated-view.js +19 -16
  145. package/src/javascripts/ui/components/view/index.js +12 -12
  146. package/src/javascripts/ui/components/view/inline-view.js +2 -2
  147. package/src/javascripts/ui/components/view/window-view/collapse-button.js +3 -3
  148. package/src/javascripts/ui/components/view/window-view/index.js +13 -13
  149. package/src/javascripts/ui/components/view/window-view/window-open-button.js +13 -13
  150. package/src/javascripts/ui/components/warnings/idle-detach-warning.js +1 -1
  151. package/src/javascripts/ui/components/warnings/resume-conversation-prompt.js +1 -1
  152. package/src/javascripts/ui/components/widgets/lightbox.js +2 -2
  153. package/src/javascripts/ui/components/widgets/upload-progress.js +1 -1
  154. package/src/javascripts/ui/hooks/component-helper-hooks.js +1 -1
  155. package/src/javascripts/ui/hooks/file-upload-hooks.js +4 -6
  156. package/src/javascripts/ui/hooks/focus-helper-hooks.js +14 -12
  157. package/src/javascripts/ui/hooks/live-region-hooks.js +2 -0
  158. package/src/javascripts/ui/hooks/seamly-api-hooks.js +8 -3
  159. package/src/javascripts/ui/hooks/seamly-entry-hooks.js +28 -25
  160. package/src/javascripts/ui/hooks/seamly-hooks.js +25 -25
  161. package/src/javascripts/ui/hooks/seamly-option-hooks.js +17 -19
  162. package/src/javascripts/ui/hooks/seamly-state-hooks.js +20 -13
  163. package/src/javascripts/ui/hooks/use-seamly-chat.js +15 -25
  164. package/src/javascripts/ui/hooks/use-seamly-commands.js +46 -46
  165. package/src/javascripts/ui/hooks/use-seamly-idle-detach-countdown.js +22 -24
  166. package/src/javascripts/ui/hooks/use-seamly-resume-conversation-prompt.js +8 -9
  167. package/src/javascripts/ui/hooks/use-single-file-upload.js +4 -6
  168. package/src/javascripts/ui/hooks/utility-hooks.js +4 -4
  169. package/src/javascripts/ui/utils/form-utils.js +0 -145
  170. package/src/javascripts/ui/utils/general-utils.js +3 -4
  171. package/src/javascripts/ui/utils/seamly-utils.ts +73 -0
  172. package/src/stylesheets/5-components/_message-carousel.scss +10 -8
  173. package/webpack/config.common.js +16 -0
  174. package/webpack/config.dev.js +1 -0
  175. package/webpack/config.package.js +26 -5
  176. package/webpack/defaults.js +7 -2
  177. package/webpack/parts/babel-loader-browser-plugins.js +1 -0
  178. package/webpack/parts/dev-server.js +4 -3
  179. package/CHANGELOG.md +0 -791
  180. package/src/javascripts/domains/app/actions.js +0 -112
  181. package/src/javascripts/domains/app/index.js +0 -7
  182. package/src/javascripts/domains/app/reducer.js +0 -16
  183. package/src/javascripts/domains/app/selectors.js +0 -8
  184. package/src/javascripts/domains/app/utils.js +0 -4
  185. package/src/javascripts/domains/config/actions.js +0 -7
  186. package/src/javascripts/domains/config/hooks.js +0 -23
  187. package/src/javascripts/domains/config/index.js +0 -7
  188. package/src/javascripts/domains/config/reducer.js +0 -79
  189. package/src/javascripts/domains/config/selectors.js +0 -23
  190. package/src/javascripts/domains/config/utils.js +0 -4
  191. package/src/javascripts/domains/forms/actions.js +0 -21
  192. package/src/javascripts/domains/forms/context.js +0 -6
  193. package/src/javascripts/domains/forms/index.js +0 -8
  194. package/src/javascripts/domains/forms/reducer.js +0 -84
  195. package/src/javascripts/domains/forms/utils.js +0 -20
  196. package/src/javascripts/domains/i18n/actions.js +0 -20
  197. package/src/javascripts/domains/i18n/index.js +0 -7
  198. package/src/javascripts/domains/i18n/selectors.js +0 -15
  199. package/src/javascripts/domains/i18n/utils.js +0 -4
  200. package/src/javascripts/domains/interrupt/actions.js +0 -4
  201. package/src/javascripts/domains/interrupt/index.js +0 -9
  202. package/src/javascripts/domains/interrupt/reducer.js +0 -22
  203. package/src/javascripts/domains/interrupt/selectors.js +0 -6
  204. package/src/javascripts/domains/interrupt/utils.js +0 -4
  205. package/src/javascripts/domains/options/index.js +0 -1
  206. package/src/javascripts/domains/redux/context.js +0 -6
  207. package/src/javascripts/domains/redux/create-redux-store.js +0 -21
  208. package/src/javascripts/domains/redux/hooks.js +0 -80
  209. package/src/javascripts/domains/redux/index.js +0 -19
  210. package/src/javascripts/domains/redux/provider.js +0 -5
  211. package/src/javascripts/domains/redux/utils.js +0 -12
  212. package/src/javascripts/domains/store/index.js +0 -46
  213. package/src/javascripts/domains/store/state-reducer.js +0 -56
  214. package/src/javascripts/domains/translations/actions.js +0 -11
  215. package/src/javascripts/domains/translations/hooks.js +0 -103
  216. package/src/javascripts/domains/translations/index.js +0 -10
  217. package/src/javascripts/domains/translations/reducer.js +0 -69
  218. package/src/javascripts/domains/translations/selectors.js +0 -16
  219. package/src/javascripts/domains/translations/utils.js +0 -4
  220. package/src/javascripts/domains/visibility/index.js +0 -8
  221. package/src/javascripts/domains/visibility/reducer.js +0 -24
  222. package/src/javascripts/index.js +0 -153
  223. package/src/javascripts/lib/redux-helpers/index.js +0 -99
  224. package/src/javascripts/style-guide.js +0 -5
  225. package/src/javascripts/ui/hooks/use-seamly-dispatch.js +0 -3
  226. package/src/javascripts/ui/utils/seamly-utils.js +0 -832
package/CHANGELOG.md DELETED
@@ -1,791 +0,0 @@
1
- # Seamly Web UI Changelog
2
-
3
- ## Unreleased
4
-
5
- ## 20.7.0 (14 September 2022)
6
-
7
- ### Bugfixes
8
- - Fix an issue where destructuring the `type` of an `entry` would result in an error when the `payload` was `undefined`.
9
-
10
- ### Breaking changes
11
- - The sendInfo() Seamly command has been removed.
12
-
13
- ### Changes
14
- - Added `.suggestions--aside` class to the suggestions in the inline interface to allow for easier styling.
15
-
16
- ## 20.6.0 (12 August 2022)
17
-
18
- ### Bugfixes
19
- - Fix an issue where the interface would not be translated when translation had started before the user had sent a message.
20
- - Fix an issue where optimistically rendered user messages would re-render after being mutated with the response from the server.
21
-
22
- ## 20.5.0 (29 July 2022)
23
-
24
- ### Changes
25
- - When syncing, give incoming events in the history precedence over events in the local state to allow the server to push changes to events.
26
- - Added links to user messages and the full conversation demo's in the styleguide.
27
- - The `connect()` and `start()` methods are decoupled to avoid unnecessary chat sessions. The `start()` method will only be called if the `visibility` state is 'open' or if using the inline view if it's 'open' or 'minimized'.
28
- - Markdown and Mustache rendering have been removed as this is now done server-side. Any implementation that uses `useTextRendering` should be rewritten to directly work on the rendered message body.
29
-
30
- ### Bugfixes
31
- - Fix an issue where reconnecting to the api would not happen when a page is loaded from back/forward cache.
32
- - Fix an issue where the order of appearance was incorrect when there where multiple start events and the suggestions block was used.
33
- - Fix an issue where `showDisclaimer` would be overwritten by the config in the styleguide.
34
- - Fix an issue where the FAQ would not immediately disappear after submitting an entry.
35
- - Fix an issue where the input entry was not showing the correct character limit after an entry with `limit` was received.
36
- - Fix an issue where the inline interface would not reopen after returning from hibernation or after clearing the session storage. This changes the way `visibilityCallback` is called.
37
- If the `visibility` state is not present in the storage after returning to a chat session, it will be set once the conversation data is fetched. This results in an extra execution of the `visibilityCallback`.
38
-
39
- ## 20.4.0 (13 July 2022)
40
-
41
- ### Changes
42
- - Added minimized inline interface with limited characters to styleguide.
43
-
44
- ### Bugfixes
45
- - Fix an issue where the translation locale would be `undefined` after reopening a session from hibernation.
46
- - Fix an issue where virtual keyboards would close after submitting a message in the chat.
47
- - Fix an issue where message count would accidentally show up briefly when collapsing the chat.
48
-
49
- ## 20.3.1 (11 July 2022)
50
-
51
- ### Bugfixes
52
- - Fix compatibility with existing custom view implementation by allowing passing of `children` to the `<View />` component.
53
-
54
- ## 20.3.0 (22 June 2022)
55
-
56
- ### Changes
57
- - The `preact` peerDependency has been upgraded to version `10.7.3`. This should also be used in client implementations.
58
- - Only load the inline chat interface when scrolled into view. This behaviour can be disabled by setting `connectWhenInView` in `config.js` to `false`.
59
- - Allow initial topic to be set through configuration or by calling the `setTopic` window API call before initialization.
60
- - When the `setVariables` window API call is called before initialization it will be merged with the variables set through configuration.
61
- - Added support for using locale native name in translation button label. This concerns the `translations.settings.openButtonText` label.
62
- For instance, change the `message` to:
63
- ```
64
- {hasLanguage, select, true {Language: {language}} other {Translation}}
65
- ```
66
-
67
- ### Bugfixes
68
- - Fix scrolling to the bottom of a chat window after an image has fully loaded.
69
- - Fix support for sending in both an `apiKey` and an `externalId` as query parameter on the demo pages.
70
- - Fix ensuring conversation suggestions remain hidden in the window variant after user interaction.
71
- - Fix classes to match BEM convention (modifier classes) in suggestions-item component.
72
- - Fix missing translation locale and variables during initialization.
73
-
74
- ## 20.2.0 (10 May 2022)
75
-
76
- ### Changes
77
- - Allow setting the automatic translation of the conversation upon initialization.
78
-
79
- ### Bugfixes
80
- - Fix inline interface to be open by default if the user has responded.
81
- - Fix agent name as subtitle of the header in the `DeprecatedView`.
82
- - Fix missing variables for the client name and client version.
83
- - Fix incorrect class name `icon` to `avatar` on agent and user avatar.
84
- - Fix default participant icon when switching to a service without an agent avatar.
85
-
86
- ## 20.1.0 (26 April 2022)
87
-
88
- ### Changes
89
- - The upload component has been rearranged to remove the redundant div container.
90
- - Expose `SeamlyStaticCore` component from styleguide in package.
91
- - All components that need disabled states now use aria-disabled for consistency across the board.
92
- - Added `message` to the Error object in the `errorCallback` when the error originates from the back-end.
93
- - Expose client name and client version to the server.
94
- - Expose layoutMode to the server.
95
-
96
- ### Bugfixes
97
- - Fix scrolling to top of inline interface in style guide.
98
-
99
- ## 20.0.0 (4 April 2022)
100
-
101
- ### The new interface
102
- Version 20.0.0 contains a major upgrade of the look and feel. The most noticeable improvements are:
103
-
104
- * The inline interface now starts in a collapsed state so it uses less screen real-estate on load and allows for a more call-to-action based interaction.
105
- * The chat button for the window variant shows pre-chat messages which makes it possible to have different call-to-action triggers based on the users need/location.
106
- * All UI variants have more screen real-estate for chat as the fixed header has been redesigned.
107
- * FAQ/suggestion handling is now part of the chat-flow in the window and app variants making it a more natural interaction.
108
-
109
- ::: box--important
110
- **Important**
111
- The old UI has been deprecated and will be removed in a future version. New implementations should not use the deprecated style.
112
- :::
113
-
114
- ### Changes
115
- - Add `.cvco-form` class to form component.
116
- - Add `.cvco-form--submitted`, `.cvco-form--valid`, `.cvco-form--invalid` modifier classes to form component.
117
- - Add `onError` handler to form component.
118
- - Add error classes when an error occurs in a form.
119
- - Legacy feature cobrowsing has been removed.
120
- - Emit warning on console if a translation label is missing.
121
- - Add Splash message component
122
- - Initializing a web-ui instance in the same parentElement will destroy the existing instance first
123
- - Add `app` layoutmode
124
- - Move initialisation of UI in IOS webviews to the app side. This fixes a bug in newer IOS versions where the storage data would arrive too late.
125
- - All demo pages on https://developers.seamly.ai/clients/web-ui now accept an `apiKey` parameter to connect to different accounts for demo purposes.
126
- - Add `context.channelName` to the Seamly initialization configuration options.
127
-
128
- ### Breaking changes
129
- - Remove `modal` window variant
130
- - Non-structural implementation specific styling is now in a separate stylesheet (`src/stylesheets/styles-default-implementation.scss` or pre-built: `styles-default-implementation.css`). If you depend on styling for hover/scrollbars on these you need to load this stylesheet as well.
131
- - The `inline` and `window` UI has been completely revamped. The old UI can still be used by using the deprecated views. If you wish to retain the old UI when updating you need to:
132
- - Add `<DeprecatedView />` as `<CustomView />` to the client.
133
-
134
- ```
135
- import { DeprecatedView } from '@seamly/web-ui'
136
-
137
- const config = {
138
- customComponents: {
139
- view: DeprecatedView,
140
- }
141
- }
142
- ```
143
-
144
- - Add deprecated stylesheet and remove the default stylesheet:
145
-
146
- ```
147
- @import '~@seamly/web-ui/src/stylesheets/deprecated-view';
148
- ```
149
-
150
- - To use the deprecated view in the styleguide, add `isDeprecated: true` to styleguide config:
151
-
152
- ```
153
- initStyleGuide({
154
- ...defaultConfig,
155
- isDeprecated: true,
156
- })
157
- ```
158
- - To mark the conversation's connection as ready we used to watch for a message of type `join_conversation_succeeded`, but this has been changed to type `attach_channel_succeeded`. If you depend on messages of type `join_conversation_succeeded` you should switch over to the new type.
159
- - Replace `defaults.startChatIcon`, `defaults.agentName`, `defaults.agentIcon` in config, with server-side equivalents.
160
- - Replace `defaults.userName` with a translation label, allowing per language labels.
161
-
162
- ## 19.1.6 (14 September 2022)
163
-
164
- ### Bugfixes
165
-
166
- - Fix an issue where destructuring the `type` of an `entry` would result in an error when the `payload` was `undefined`.
167
-
168
- ## 19.1.5 (17 August 2022)
169
-
170
- ### Bugfixes
171
- - Fix an issue where the interface would not be translated when translation had started before the user had sent a message.
172
-
173
- ## 19.1.4 (16 February 2022)
174
-
175
- ### Bug fixes
176
- - Fix deep merging of `defaults` key in config when supplied by both implementation and in `init`.
177
- - Fix carousel sliding in Safari
178
- - Fix the aria-label of a slide to use the correct index
179
- - Fix display of automatic translations in carousel messages.
180
- - Fix resetting of translation and other state after remote conversation crash.
181
-
182
- ## 19.1.3 (16 February 2022)
183
-
184
- ### Changes
185
- - Extended and improved data of `errorCallback`.
186
-
187
- ## 19.1.2 (26 January 2022)
188
-
189
- ### Bug fixes
190
- - Fix open/close state in styleguide for window layoutMode.
191
-
192
- ## 19.1.0 (11 January 2022)
193
- ### Changes
194
- - Added an option to monitor errors by passing `errorCallback` to the config.
195
-
196
- ### Bug fixes
197
- - Do not display user input as Markdown or Mustache to prevent potential XSS attacks.
198
- - Add translation dividers to styleguide
199
- - Add all error types to styleguide
200
- - Show time-indicators in styleguide
201
-
202
- ## 19.0.0 (19 December 2021)
203
- ### Breaking Changes
204
- - Translation files will be loaded from the back-end and can be managed there. Translations will no longer be provided in this package.
205
- - `setLocale` window API call has been removed. The locale can only be set at initialisation of a conversation.
206
- - `setTranslation` now also triggers a translation of the UI
207
- - The key for the store (sessionStorage, cookie, etc) will include the locale which is provided through the context. Any implementation using the storage directly will need to be adjusted accordingly. (Old format: `cvco.NAMESPACE.connection`, new format: `cvco.NAMESPACE.connection.LOCALE`).
208
- - The default locale for a conversation is provided by the server, but can be overridden through `config.context.locale` during `init`.
209
-
210
- ### Changes
211
- - Provide representative demo images for card and image messages to be used in styleguides.
212
- - Increase inline window size. This also changes some of the Sass variables.
213
- - Determination of `userResponded` has been moved to the server. This also means the key `userResponded` in the Storage is no longer available. If you need to know the state on startup you can use the appstate parameter on the `ui.start` or `ui.beforeStart` events.
214
- - Updated @seamly/eslint-config to latest
215
- - Updated @seamly/prettier-config to latest
216
- - Styleguide: "Cobrowser bar" has been renamed to "Chat status bar"
217
- - The locale for translations of the UI can now be changed to a different locale dynamically
218
-
219
- ## 18.3.1 (22 November 2021)
220
- ### Changes
221
- - Add class for styling to the `activity-monitor` div.
222
-
223
- ## 18.3.0 (20 October 2021)
224
- ### Changes
225
- - Improve entering send_transcript e-mail on mobile and desktop. Especially in combination with autocomplete on mobile.
226
-
227
- ### Bug fixes
228
- - Time indicators are properly shown before user messages.
229
- - Links in messages by users in the default UI are now legible.
230
- - Fix options dialog `max-height` issue to make implementations easier.
231
- - Fix keyboard navigation and focus of carousel.
232
- - Fix settings focus of input entry when windowed chat is opened.
233
- - Make card description element a `div` instead of `p` to prevent invalid HTML nesting.
234
-
235
- ## 18.2.0 (17 September 2021)
236
- ### Changes
237
- - Add default `secondary` category to be used with choice prompts
238
- - ChoicePrompt `<li>`'s now have an additional class based on the choice category to aid styling of choices in client implementations
239
- - Process card descriptions as markdown
240
- - Don't process cta descriptions as Mustache templates as we won't ever have any variables
241
-
242
- ### Bug fixes
243
- - Remove redundant img alt attribute in cards
244
-
245
- ## 18.1.1 (9 September 2021)
246
- ### Bug fixes
247
- - Fix translation menu automatically closing on focus-out by removing the close-on-focus-out from the Translations-Dialog.
248
-
249
- ## 18.1.0 (8 September 2021)
250
- ### Changes
251
- - Add Carousel message type
252
- - Add Card message type, the following three card types can be rendered:
253
- - `ask` which contains a cta that sends a question into the conversation.
254
- - `navigate` which contains a cta that navigates to a url.
255
- - `topic` which contains a cta that sets the topic of the conversation.
256
-
257
- ### Bug fixes
258
- - Make uploads show correctly as not-deleted if they are still available.
259
-
260
- ## 18.0.0 (30 August 2021)
261
- ### Changes
262
- - Added `Automatic Translation` feature to support live machine translations.
263
- - Added `setTranslation` added to the window API (only works if the feature is enabled in the account).
264
- - Added `@seamly/web-ui/index.debug` as a drop-in replacement for `@seamly/web-ui` to enable debug tools in client implementations
265
- - `useChoicePrompt`'s return value now also contains `{ body, subEvent }`
266
- - Exported `MessageContainer` for usage in client implementations
267
- - Exported `useTranslations`, `useTranslatedEventData` and `useTranslationsContainer` for usage in client implementations
268
-
269
- ### Breaking changes
270
- - `useChoicePrompt` now requires the full event as a parameter instead of `event.payload`
271
- - Drop support for IE11
272
- - `useTranslation` is renamed to `useI18n` and exports a name function (`t`).
273
- ```
274
- // v17.x
275
- import useTranslation from '@seamly/web-ui`
276
-
277
- const t = useTranslation()
278
-
279
- // v18.x
280
- import useI18n from '@seamly/web-ui'
281
-
282
- const { t } = useI18n()
283
- ```
284
- - Translation files now use a flattened structure and should be updated.
285
- ```
286
- // config.js v17.x
287
- import nlInformal from '@seamly/web-ui/translations/nl-informal'
288
-
289
- const translations = {
290
- ...nlInformal,
291
- toggleButton: {
292
- ...nlInformal.toggleButton,
293
- title: 'Chat',
294
- resumeTitle: 'Chat',
295
- subtitle: 'Start gesprek',
296
- },
297
- header: {
298
- ...nlInformal.header,
299
- title: 'Stel je vraag aan',
300
- }
301
- }
302
-
303
- // config.js v18.x
304
- import nlInformal from '@seamly/web-ui/translations/nl-informal'
305
-
306
- const translations = {
307
- ...nlInformal,
308
- 'toggleButton.resumeTitle': 'Chat',
309
- 'toggleButton.subtitle': 'Start gesprek',
310
- 'toggleButton.title': 'Chat',
311
- 'header.title': 'Stel je vraag aan'
312
- }
313
- ```
314
-
315
- ### Bug fixes
316
- * Fix timing issue between clearing entry and changing entry type based on incoming messages.
317
- * Fix issue in i18n where default object for overrides was provided, but tested against undefined instead of keys.length
318
-
319
- ## 17.2.0 (3 august 2021)
320
- ### Changes
321
- - Added app state information to `ui.beforeStart`, `ui.start` and `ui.visiblity` window.api events. App state contains `hasResponded`, `hasConversation`, `visiblity` and `unreadMessagecount`.
322
- - Always show time indicator at beginning of conversation when enabled.
323
- - Always show username/agent name when it is preceded by a time indicator.
324
-
325
- ## 17.1.1 (13 july 2021)
326
- ### Bug fixes
327
- - Expose `useSeamlyConfig` & `useSeamlyVisibility` hooks for customer implementations.
328
-
329
- ## 17.1.0 (29 june 2021)
330
- ### Changes
331
- - Replace default `api.*.seamly.ai` domains with `api.*.seamly-app.com`.
332
- - Minor dependency updates
333
-
334
- ### Bug fixes
335
- - Replace all `/` used for division in SCSS files with fractions. The `/` for division is being deprecated by Sass, as it is technically a seperator in CSS. In future, it will be either `calc()`, `math.div()` or we can use a fraction.
336
- - Info messages no longer disable choice prompts
337
- - Server-side triggered idle-timer elapse no longer doubly triggers detach-service action
338
-
339
- ## 17.0.0 (7 june 2021)
340
- ### Breaking changes
341
- - The `system.service_changed` event has been renamed to `system.systemChanged`.
342
- - For file uploads the following translation keys have been affected and should be changed if overrides or nonstandard translations are used:
343
- - `srMessageIconText` has been removed.
344
- - The text for `srFileUnavailableText` has been changed.
345
- - Keys `srFileUploadedText` and `srFileDownloadText` have been added.
346
-
347
- ### Changes
348
- - File download messages without a `url` value are now supported and rendered correctly.
349
- - Authenticate all conversation requests
350
- - Now hides all chat content from being shown in the Google Search result snippet by applying the `data-nosnippet` attribute.
351
- - A `system.userFirstResponse` event is now broadcast via the external api when a user responds for the first time in a conversation.
352
- - Added `@seamly/web-ui/standalone` and `@seamly/web-ui/standalone.min.js` as standalone pre-built package exports which do not require .
353
- - Update activeServiceSessionId on each incoming message
354
- - Add pre-built `@seamly/web-ui/styles.css` to the package exports.
355
-
356
- ### Bug fixes
357
- - Remove `cvco-false` class from the options toggle button.
358
- - The style guide will no longer display duplicate Preact key console errors.
359
- - Load scss imports from `node_modules` without deprecated `~`.
360
-
361
- ## 16.0.7 (18 may 2021)
362
- ### Bug fixes
363
- - Add missing styling for time indicators.
364
-
365
- ## 16.0.6 (12 may 2021)
366
- ### Bug fixes
367
- - Add optional chaining to prevent error in time indicator display when locale doesn't match.
368
-
369
- ## 16.0.5 (11 may 2021)
370
- ### Bug fixes
371
- - Export the following exports from the package as required by client implementations to enable upgrade to v16:
372
- - `useSeamlyCommands`
373
- - `useSeamlyIdleDetachCountdown`
374
- - `useDispatch`
375
- - `seamlyActions`
376
- - `eventTypes`
377
- - `AppFrame`
378
- - `ChatFrame`
379
- - `ToggleButton`
380
- - `AgentInfo`
381
- - `Header`
382
- - `Conversation`
383
- - `EntryContainer`
384
- - `Interrupt`
385
-
386
- ## 16.0.4 (10 may 2021)
387
- ### Bug fixes
388
- - Export `useSeamlyEvents` as `useEvents` for the package
389
-
390
- ## 16.0.3 (10 may 2021)
391
- ### Bug fixes
392
- - Fix FAQ overflow on mobile screens with low height (especially an issue when the keyboard is open on Android)
393
- - Fix image modal not expanding to full height in the inline layoutmode
394
-
395
- ## 16.0.2 (4 may 2021)
396
- ### Bug fixes
397
- - Also export `useSeamlyChat` hook from the package.
398
-
399
- ## 16.0.1 (22 april 2021)
400
- ### Bug fixes
401
- - Properly export all package files so you can use exports like `@seamly/web-ui/storage`
402
-
403
- ## 16.0.0 (20 april 2021)
404
- ### Changes
405
- - Remove loading of `@include-media` in `index.scss` as this is now loaded through the `Web UI`.
406
- - `FAQ` is now part of `Web UI` and can be deactivated with the `showFaq` setting in the configuration.
407
- - An `action.click_cta` is now broadcast via the external api when the to action is clicked in a CTA message.
408
- - Time Indicators can now be shown in a conversation when enabled in the configuration.
409
- - Render `info` events of type `divider` when received over the websocket.
410
- - Reorder events when an ACK is received
411
- - Add `setTopic` action to the window API.
412
- - A `system.system_changed` event is now broadcast via the external api when the current service changes.
413
- - Add guide to documentation on how to add analytics to your implementation.
414
- - All HTML buttons are now explicitly typed and safe for use inside wrapping forms (mainly classic ASP.NET applications).
415
-
416
- ### Breaking changes
417
- - Regardless of whether `FAQ` is activated in `Web UI` or not, the main application is now wrapped in class `cvco-app-wrapper` which reguires styling adjustment in all implementations.
418
- - All implementations already containing `FAQ` should migrate to the internal implementation. This is mostly the removal of the flex styling on certain breakpoints, and making sure `position: absolute` is possible on the `faqs`.
419
- - All direct references to `@seamly/web-ui/src/javascript/*` must be updated to reflect the new exports at `@seamly/web-ui`
420
- - `@seamly/web-ui` must be transpiled in the webpack-config of the implementation to enable cross-browser support
421
- - `preact` is now a peerDependency and must be included from the implementation
422
-
423
- ### Bug fixes
424
- - Don't render the skip link when minimized. This fixes the issue where you could focus the skip-link when only the button was visible.
425
-
426
- ## 15.0.1 (11 March 2021)
427
- ### Changes
428
- - `@babel/plugin-transform-react-jsx` now supports automatic transpilation of JSX without the need to import `preact`, `preact.h` or `preact.Fragment`.
429
-
430
- ### Breaking changes
431
- - Implementations must upgrade to Preact 10.5.12
432
- - Implementation must update the **Babel** configuration for `@babel/plugin-transform-react-jsx` to `{ runtime: 'automatic', importSource: 'preact' }` in order to support automatic transpilation.
433
-
434
- ## 15.0.0 (11 March 2021)
435
- ### Changes
436
- - Options, options dialogues, the upload button, as well as the Seamly modal version can now be animated with the same standard transition classes.
437
- - Add configurable z-index for implementations via config.
438
- - Add `overscroll-behaviour: contain` to windowed chat so scrolling a windowed chat will not automatically scroll the whole page when the user has reached the bottom of the chat.
439
- - Focus code has been consolidated to use hooks and helper functions. All focus code should use and expand on this implementation.
440
- - Remove cog icon when just one specific option is shown in the bottom bar. Also add classes so the entry can be styled.
441
-
442
- ### Breaking changes
443
- - Implementations with options need to update the hide/show of the options menu, and the upload button to use the new transition classes.
444
-
445
- ### Bug fixes
446
- - Fix double rendering of upload bubbles on socket reconnect.
447
-
448
- ## 14.0.2 (12 February 2021)
449
- ### Changes
450
- - Send transcript button now has it's own translation and explicitly says `Send`.
451
-
452
- ### Bug fixes
453
- - Fix typo in `de-informal` translations.
454
-
455
- ## 14.0.1 (10 February 2021)
456
- ### Bugfixes
457
- - Transcript email validation now also allows capital letters.
458
-
459
- ## 14.0.0 (27 January 2021)
460
- ### Changes
461
- - Build all translations as UJS modules and expose them in the NPM package in `@seamly/web-ui/dist/translations/*`.
462
- - Use `description` field for rich text in CTA messages.
463
- - Add `fileUpload.errors.virusFound` translation to indicate an uploaded file contains an unsafe file.
464
- - All non-user downloads will open in a new window.
465
- - Remove `inResponseTo` from the payload in a message as the back-end no longer uses it.
466
- - The user can now request a transcript of the chat to be sent via email.
467
- - Add German informal translations (`translations/de-informal.js`)
468
- - Any use of `:first-child` on `.cvco-conversation` may be removed from client implementations. This should've been removed when we moved the privacy disclaimer into the conversation stream.
469
- - The current agent name is passed to the resume conversation prompt translation.
470
-
471
- ### Breaking changes
472
- - Update the `marked` depdendency to 0.8.2, this fixes multiple security issue. Unfortunately this means implementations need to process `marked` by babel as it exports ES6
473
- - Upgrade webpack to v5. Implementations now have to upgrade to webpack 5 too. Things that need changing:
474
- - Update `webpack.config.js` to work with Webpack 5
475
- - Update `.eslintrc.js` resolver config. Replace `'import/resolver' : 'webpack'` with:
476
- ```
477
- 'import/resolver': {
478
- webpack: {},
479
- },
480
- ```
481
- - Update any calls to `yarn build -- --env.target=XX` to `yarn build --env target=XX`
482
- - Removed the `/webpack/implementation_config.js` file. Custom implementations should use @seamly/doc-site package with a custom config instead.
483
- - Options are now shown as pop-over screen driven by a menu button for multiple options, and an action button for single options. Styling needs to be adapted.
484
- - All options now show as single option pop-over screens. Styling needs to be adapted.
485
- - The screen sharing option is no longer implemented as a checkbox control but has become a toggle button. Styling needs to be adapted.
486
- - The file upload button will now only show when uploads are available. This may affect the display of the entry container in implementations. Styling needs to be adapted.
487
-
488
- ## 13.0.0 (9 December 2020)
489
- ### Changes
490
- - The entry component can now be set via the `entry` property on messages. Currently this is available for `upload` entry types but this can be extended via the same mechanism for all entry types where required.
491
- - Validations loaded on entry components can also now be adjusted via server message inside the `entry` property as per the previous point.
492
-
493
- ### Breaking changes
494
- - The import path for `EntryContainer` has changed to `@seamly/web-ui/src/javascripts/ui/components/entry/entry_container`. This should be adjusted in all custom views.
495
- - The structure of the entry block has been changed. All custom views should update the JSX declaration:
496
-
497
- ```
498
- // Replace
499
-
500
- <EntryContainer>
501
- <Entry />
502
- </EntryContainer>
503
-
504
- //With
505
-
506
- <EntryContainer />
507
- ```
508
- - As the entry block has been closed in JSX, custom implementations of the `Entry` component should now use the standard `customComponents` interface in the configuration as described in the documentation.
509
- - Any custom implementations of `Entry` will need to be recoded to follow the new structure in `Seamly Web UI`.
510
- - All implementations using the src from the `@seamly/web-ui` package should transpile the `phoenix` package to ES5 if IE11 support is required. If you use webpack, you should make sure `node_modules/phoenix` is not excluded from transpilation in webpack.config.js.
511
-
512
- ### Bugfixes
513
- - An edge case existed in the forms system where form element components could re-initialize if the upper application state changed thereby losing preloaded forms data. This has been fixed.
514
- - Fixed NL translation typo in the screen reader text of a configuration error.
515
- - The package now uses the source Phoenix file as the dist file contains JavaScript that violates the `unsafe-eval` CSP policy.
516
- - Send Content-Type header on POST requests to get config and to create a new conversation.
517
-
518
- ## 12.4.0 (27 November 2020)
519
- ### Changes
520
- - Send timezone information to server if it can be determined (only works in modern browsers)
521
- - Export new ViewWithFaq to use in implementations that use the bundled javascript.
522
- - Add support for file uploads without a deleteAt.
523
-
524
- ## 12.3.0 (19 November 2020)
525
- ### Changes
526
- - Add support for file upload messages from agents.
527
- - Add support for securely downloading uploaded files.
528
- - Clearly mark expired file upload links as such.
529
-
530
- ## 12.2.0 (17 November 2020)
531
- ### Changes
532
- - Add new `api.externalId` configuration option to persist conversations when messaging is enabled.
533
- - Add new `ResumeConversationPrompt` to ask users to continue or restart a conversation after returning to if after a while (when using messaging).
534
-
535
- ### Bug fixes
536
- - Always remove loader when initial events arrive from the server.
537
- - To avoid multiple instances sending events via the same event bus instance a unique event bus is now used for each chat instance.
538
- - Don't break on missing activeServiceSettings from a history call.
539
-
540
- ## 12.1.0 (9 November 2020)
541
- ### Changes
542
- - The character limit is visible 50 characters before the limit will be reached instead of the previous 25 characters.
543
- - History synchronisation with the server is now only performed when it results in new history.
544
- - The `Privacy Disclaimer` is now shown at the top of the chat window and scrolls away.
545
- - The Style Guide now accepts custom i18n files.
546
- - Add `appStorageProvider` with support for iOS, Android and React Native. This makes integration with those platform work out of the box (if implemented correctly on the app side).
547
-
548
- ### Bug fixes
549
- - In the Spanish language file, the `srStopCobrowsingText` language key has been repaired.
550
- - All event sorting is now based on the `occurredAt` timestamp on events. This ensures proper merging of history and current event streams in all cases.
551
- - Client side message again have the ID set properly from the server ACKs.
552
- - Incorrect height value for screen resolution in the browser environment context has been fixed.
553
- - Add missing documentation for storage providers.
554
-
555
- ### Breaking changes
556
- - Hook `useSeamlyDisclaimerDelayedClose` no longer exists. Implementations with a custom `Entry` component should remove this.
557
-
558
- ## 12.0.0 (25 September 2020)
559
- ### Breaking changes
560
- - Hook `useSeamlyContainerClassNames` has been renamed to `useSeamlyMessageContainerClassNames`.
561
- - Chat bubbles are no longer full width. Most client implementations do not use this full width, so needed escaping every time. For clients who do have full width bubbles this needs checking.
562
- - The `api.defaults` configuration option has been moved to `context` on the main configuration level. Within this configuration object any usages of `meta` or `settingsProfile` should be removed if still present in implementations as these are dead options.
563
- - The `customViewComponent` configuration option has been moved to `customComponents.view`
564
- - Allow setting of custom implementation specific view components in the config. The `ComponentProvider` component no longer exists. Custom components should now be passed via the `customComponents` key in the init configuration. To upgrad:
565
- - Remove the wrapping `<ComponentProvider>`
566
- - Pass the custom view components to config (see "Configuration" documentation and "Custom message components" documentation)
567
- - Various `layoutModes` with the same `namespace` no longer share a `visibility` setting in the storage, but have been separated. Therefore it can no longer be assumed that a windowed variant will open just because an inline variant had been active.
568
- - The `visible` config setting has been moved to the `defaults` object in the configuration. The function has remained unchanged. To upgrade, move this setting in the configuration.
569
- - File upload settings are now read from `entry.options.upload` configuration in service change events instead of `uploads`.
570
- - Split `useText` component hooks in to `useTextRendering` and `useEventLinkClickHandler`. Any custom text message components should now use these hooks instead of the `useText` hook.
571
-
572
- ### Changes
573
- - Add two `on` events to the window API for the idle detach warning: `'idleTimer.selectContinue` is sent when the user clicks on the `Continue coversation` button and `idleTimer.selectEnd` is sent when the user clicks on the `End conversation` button.
574
- - Do not show disabled option checkboxes.
575
- - Improve icon accessibility.
576
- - Add style guide to public site. The style guide contains a list of most common states for the UI. The style guide application can also be used in implementation to speed up styling.
577
- - Add support for custom message type. Custom messages allow you to pass arbitrary data from a back-end service to the UI. You can create custom rendering components to render these custom messages. Custom message components can be passed to the Seamly engine via the `customComponents.message.custom` configuration key.
578
- - The visibility mutations of the UI can now be overridden and managed with a custom `visibilityCallback` function set as value of the config property with the same name.
579
- - Add support for character limit on text input.
580
- - Add Call to Action (CTA) message type.
581
-
582
- ### Bug fixes
583
- - The participant displayed information is now cleared after an interrupt restart.
584
- - Fix duplicate rendering of accessiblity text in image messages.
585
- - Fix modification of the `body` data of messages when rendering them as rich text.
586
- - Fix issue with socket reconnects that would result in messages appearing at the start of the chat
587
-
588
- ## 11.1.0 (30 July 2020)
589
- ### Bug fixes
590
- - Fix history fetching when file uploads are disabled
591
-
592
- ### Changes
593
- - Clear waiting actions when destroying an instance
594
-
595
- ## 11.0.0 (29 July 2020)
596
- ### Bug fixes
597
- - Focus outline will now always show, also in browsers with `:focus-visible` activated.
598
- - Focus input when user clicked the restart button in the error interrupt.
599
- - Hide cobrowsing bar, options and options toggle button when the UI is minimized
600
-
601
- ### Breaking changes
602
- - Implementations with custom `Entry`, `ChatFrame` or `EntryContainer` components should re-align the implementations of these components to that inside Seamly UI in order to support `File uploads` and function with the adjusted `Multi Forms Data Engine` inside Seamly UI.
603
- - Classname for the icon in the lightbox/modal has been changed. From `cvco-model__icon` to `cvco-icon` to be consistent with all other icons.
604
- - All icons are now outlined, so any implementations that use `stroke` in the css (for instance to change color or width) should be fixed to use `fill` instead. Implementations that target specific parts of any `svg` will need tweaking, because all icons are now compound shapes (as few different paths as possible).
605
-
606
- ### Changes
607
- - The `Forms Data Engine` inside Seamly UI now supports multiple forms as well as the persistence of forms data.
608
- - The `Forms Engine` now supports validation.
609
- - `File uploads` are now supported in Seamly UI if the account configuration and service supports it.
610
- - An `aria-live` window API event has been added for testing the main `ARIA Live region` in Seamly UI. Any texts added to this live region will be broadcast via this event.
611
-
612
- ## 10.0.1 (7 July 2020)
613
- ### Bug fixes
614
- - Export `useEntry` again (as `useInput` used to be exported).
615
-
616
- ## 10.0.0 (3 July 2020)
617
- ### Changes
618
- - When the idle detach warning countdown starts the `idleTimer.start` window API event gets called and when the timer stops, the `idleTimer.stop` event.
619
- - Add `sendCustomAction` action to the window API.
620
- - Add generic Form engine for easier form handling and future extensibility for validation.
621
- - Introduce options window. It will only show when the connected account actually has options.
622
- - Introduce option for screensharing. This will also activate the screensharing warning when enabled.
623
-
624
- ### Breaking changes
625
- - The idle detach warning now displays the countdown as minutes and seconds. This will need styling changes in the implementation on upgrade.
626
- - `Input` component has been replaced with a more generic `Entry` component. This is a drop-in replacement.
627
- - Rename package to `@seamly/web-ui`. Updage your package.json files accordingly. Versioning will continue.
628
-
629
- ## 9.3.0 (23 June 2020)
630
- ### Changes
631
- - FAQ click also sets `userResponded` to true
632
-
633
- ## 9.2.0 (16 June 2020)
634
- ### Changes
635
- - Add the `appContainerClassName` configuration option to set custom class names on the container element.
636
- - Add new ui.inputFocus event callback that is triggered whenever the input field gets focus.
637
- - Emit faq question with `faqclick` custom action on click to aid implementations who need the faq question.
638
- - The external API now support fetching the current visibility state with the `getVisibility` action.
639
-
640
- ## 9.1.0 (5 June 2020)
641
- ### Changes
642
- - Removed custom focus styles on disclaimer close, modal enlarge, modal close, input etc. These get in the way when doing custom styling for clients. Remove any CSS that escapes this now removed styling.
643
- - Expired chats no longer show an interrupt screen but automatically restarts. The `sessionExpired` error key can be removed from all custom language files.
644
-
645
- ### Breaking changes
646
- - Chat now starts at the bottom of the window container. This severely improves visibility of initial chat messages in smaller views. This adds an extra container div. Test if scrolling/window visibility is still ok after updating.
647
-
648
- ## 9.0.0 (19 May 2020)
649
- ### Changes
650
- - Depending on server configuration, send user typed text to the Seamly server periodically.
651
- - Prefetch api configuration prior to chat start.
652
- - Prefetch initial chat state prior to chat start.
653
- - Initialise unit testing of Seamly.
654
- - Upgraded Preact to 10.4.1. Please align all custom implementations to this version.
655
- - Add the `hideOnNoUserResponse` configuration option to allow chats to only render if the user has previously replied via a chat interface using the same namespace.
656
- - Add `init` and `destroy` functionality to the external api to allow users to destroy or re-initialise the Seamly chat window.
657
- - Remove the deprecated object API, you can only use the `window.seamly` API from now on.
658
- - No longer automatically initialise an instance. You need to call the `init` action explicitly to render/start an instance.
659
- - Sanitize user input from any executable HTML.
660
-
661
- ### Breaking changes
662
- - Migrate the UI to version 2 of the Seamly API.
663
- - The exported Seamly function no longer returns an API
664
- - You need to explicitly `init` an instance to start it
665
- - The adjacent sibling combinator (`+`) has been removed in favour of the `cvco-conversation__item--new-participant` class on messages. Many implementations have either classes that override this default styling, or are using the adjacent sibling combinator themselves. This will need checking and potentially fixes on update.
666
-
667
- ## 8.1.0 (24 April 2020)
668
- ### Changes
669
- - FAQ events will now be persisted over application reloads and only be cleared when intended by the Seamly server.
670
-
671
- ## 8.0.1 (6 April 2020)
672
- ### Bug fixes
673
- - Repair text input labelling.
674
-
675
- ## 8.0.0 (6 April 2020)
676
- ### Changes
677
- - The default FAQ component has been adjusted to handle more implementation requirements. Refer to `faq.md` for the latest API.
678
- - An Idle Detach Warning will be shown if the user is connected to a live agent, inactive for a set amount of time and the server configuration allows for this.
679
-
680
- ### Breaking changes
681
- - The form element component used inside the view should now be wrapped inside a new `<EntryContainer>` component. All custom implementation should upgrade the custom view with this component:
682
-
683
- ```jsx harmony
684
- <EntryContainer>
685
- <Input />
686
- </EntryContainer>
687
- ```
688
-
689
- - Custom implementations using a custom `<ToggleButton>` component should align to the new version of the code.
690
- - Custom implementations using a custom `<Input>` component should also align to the new version of the code.
691
- - Any usages of the hook `useSkiplinkInputId` should be refactored to `useSkiplink`.
692
- - Any usages of the hook `useInputFocusing` should be refactored to `useSkiplinkTargetFocusing`.
693
-
694
- ## 7.1.0 (26 March 2020)
695
- ### Bug fixes
696
- - FAQ's selections will now show in history as the original event ID is now passed to the FAQ click action.
697
- - Image and video elements will now also show the event participant, when appropriate.
698
-
699
- ### Changes
700
- - The current active participant will show as event participant on the chat loader bubble, when appropriate.
701
-
702
- ## 7.0.0 (12 March 2020)
703
- ### Bug fixes
704
- - Avoid empty introductions from overwriting existing avatar intros.
705
- - Update avatar in button/header to show initial state / active agent avatar.
706
-
707
- ### Changes
708
- - Display `info` messages in the chat windo when they are sent via the websocket.
709
- - Upgrade Preact to v10.3.3. It is recommended to upgrade custom implementations to this version of Preact as well.
710
- - The configuration object has been expanded with a new `defaults` object:
711
-
712
- ```json
713
- defaults: {
714
- startChatIcon: imageUrl,
715
- agentName: 'Seamly Bot',
716
- agentIcon: imageUrl1,
717
- userName: 'You',
718
- },
719
- ```
720
-
721
- - The standard display name and avatar of the `user participant` will now be source from the `seamly-client-participant` participant message from the server.
722
- - A default chat start icon can be set using the `startChatIcon` setting found in the new `defaults` object in the configuration object.
723
- - A default agent icon can be set using the `agentIcon` setting found in the new `defaults` object in the configuration object.
724
-
725
- ### Breaking Changes
726
- - Any custom implementations using `component overrides` should migrate to the `ComponentProvider` component instead. Passing custom components to the `Conversation` component is no longer supported and will be ignored.
727
- - The container classes are no longer exposed as `containerClassNames` by the internal component hooks. Any view components relying on this should import the new `useSeamlyContainerClassNames` hook to resolve the same classes.
728
- - The `choose again` divider will no longer render in history if used with a version of the server API that does not support info messages.
729
- - Add privacy disclaimers will now auto close after 5000 milliseconds, unless the `disclaimerTimeout` is set in the config.
730
- - Remove `toggleButton.openChat` and add `toggleButton.resumeTitle` in all custom language files.
731
- - The `defaultName` settings for both `user` as well as `agent` no longer exists. Instead use the `userName` setting for the `user` and the `agentName` setting for the `agent`. Both are contained in a new main `defaults` object in the config.
732
- - Any implementations relying on an `agent defaultName` of `Bot` coming from the Seamly client itself, needs to implement this with the `userName` setting.
733
- - Any implementations relying on a `user defaultName` of `You` coming from the Seamly client itself, needs to implement this with the `userName` setting.
734
-
735
- ## 6.2.0 (3 March 2020)
736
- ### Changes
737
- - Upgrade Preact to v10.3.2. It is recommended to upgrade custom implementations to this version of Preact as well.
738
-
739
- ### Bug fixes
740
- - Avoid empty introductions from overwriting existing avatar intros.
741
- - Fixed race condition that sometimes caused a double connect of the chat client.
742
-
743
- ## 6.1.0 (17 February 2020)
744
- ### Changes
745
- - Allow links to open in new tabs via server configuration.
746
-
747
- ### Other
748
- - Fix image opening in lightbox after previous server change.
749
-
750
- ## 6.0.0 (17 February 2020)
751
- ### Bug fixes
752
- - Choice Prompts with prompts other than type="text" now displays properly.
753
-
754
- ### Changes
755
- - Custom `Text`, `Video` and `Image` components now implement a `descriptorId` prop as `id` to decorate description containers.
756
-
757
- ### Breaking Changes
758
- - Custom ChoicePrompt components should now allow for custom prompt component injection via the `children` prop.
759
- - Custom Text components should no longer use a `textBodyId` prop to decorate the text container via `id` but instead implement a `descriptorId` prop.
760
-
761
- ## 5.1.1 (12 February 2020)
762
-
763
- ### Bug fixes
764
- - Fix misalignment of balloon agent icon.
765
-
766
- ## 5.1.0 (7 February 2020)
767
-
768
- ### Changes
769
- - Expose new action events for `action.pick_choice`, `action.navigate` and `action.custom`.
770
-
771
- ## 5.0.2 (31 January 2020)
772
-
773
- ### Bug fixes
774
- - Properly build and release Dutch I18N text for Choose Again.
775
-
776
- ## 5.0.1 (31 January 2020)
777
-
778
- ### Changes
779
- - Adjust default Dutch I18N text for Choose Again.
780
-
781
- ## 5.0.0 (29 January 2020)
782
- ### New features
783
- - Enable choose again of choice prompt values.
784
-
785
- ### Bug fixes
786
- - Repair semantics of the Choice Prompt list.
787
-
788
- ### Breaking Changes
789
- - When services are setup to allow `Choose Again` of `Choice Prompts`, a choose again button will now be shown in the chat interface. New topic dividers will also be shown after choosing again. Styling should be adjusted to allow for this in implementations.
790
- - `Choice Prompts` will be rendered as a `<ul>` instead of `<div>`. Styling should be adjusted in implementations.
791
- - To align divider views the class postfix `divider__icon` in the `Participant` component has been adjusted to `divider__graphic`. Styling should be adjusted in implementations.