Chat component

<wy-chat> | WyChat

The chat component renders a complete and functional user interface for a contextual chat.

Importing

If you installed the UIKit with npm you can use the following snippet to import the component into your project. Otherwise, if you installed the UIKit as a <script> you can ignore this section.

import { WyChat } from "@weavy/uikit-web";

Examples

As seen in this example, specifying the app identifier (uid) is required, and automatically creates a corresponding app on your Weavy environment when the component is first initialized.

<wy-chat uid="test-chat" name="Test chat"></wy-chat>

It's often useful to base the uid on something that identifies the location where the component is rendered. Typically you would use something like a product id, page id, path or URL.

Properties

Most properties are optional and/or has sensible default values. Required properties are indicated with an asterisk (*).

Property Type Description
uid* string Unique identifier for the app.
name string Optional display name for the app (used in notifications etc.)
notifications "button-list", "none" Set the appearance of notifications. Defaults to "button-list".
notificationsBadge "count", "dot", "none" Set the appearance of the notification badge. Defaults to "count".
features string Explicit space separated list of enabled features. All default features are enabled when this property is not defined.
reactions string Space separated string of unicode emojis to use for reactions. Defaults to reactions from the Weavy instance or <wy-context>.

Learn more about attributes and properties.

Available features

Features that are available but disabled by default are indicated by parenthesis ().

Feature Description
attachments Possibility to upload local files.
cloud_files Cloud file picker (Google Drive, Dropbox etc.).
embeds Creating embeds from urls in editor text.
google_meet Google Meet video meetings.
meetings General availability for meetings. This can be ignored if using all individual meeting feature flags, i.e. google_meet, microsoft_teams and zoom_meetings.
mentions Possibility to mention other people from the current directory in the editor.
microsoft_teams Microsoft Teams video meetings.
polls Possibility to create polls in editor.
previews Previews of files and attachments.
reactions Possibility to add emoji reactions to a message, post or comment.
(receipts) Read receipts on messages.
(typing) Typing indicators in the chat when other people types.
zoom_meetings Zoom video meetings.

Events

Name Type Description
wy-link WyLinkEventType Emitted when a notification is clicked.
wy-preview-open WyPreviewOpenEventType Emitted when preview is about to be opened. The event may be prevented.
wy-preview-close WyPreviewCloseEventType Emitted when preview is closed

Learn more about events.

Support

To access live chat with our developer success team you need a Weavy account.

Sign in or create a Weavy account