@livekit/components-js-docs 0.1.2 → 0.1.4

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 (71) hide show
  1. package/generated-docs/core/chatmessage.md +2 -0
  2. package/generated-docs/core/chatoptions.md +24 -0
  3. package/generated-docs/core/createmediadeviceobserver.md +2 -1
  4. package/generated-docs/core/index.md +4 -3
  5. package/generated-docs/core/pinstate.md +2 -0
  6. package/generated-docs/core/receivedchatmessage.md +2 -0
  7. package/generated-docs/core/roomvideoplaybackallowedobservable.md +18 -0
  8. package/generated-docs/core/setupchat.md +1 -5
  9. package/generated-docs/core/setupstartvideo.md +20 -0
  10. package/generated-docs/core/trackreference.md +2 -0
  11. package/generated-docs/core/trackreferenceorplaceholder.md +2 -0
  12. package/generated-docs/core/trackreferenceplaceholder.md +2 -0
  13. package/generated-docs/core/widgetstate.md +2 -0
  14. package/generated-docs/react/audiotrackprops.md +10 -10
  15. package/generated-docs/react/audiovisualizerprops.md +4 -4
  16. package/generated-docs/react/carousellayoutprops.md +5 -5
  17. package/generated-docs/react/chatentryprops.md +6 -6
  18. package/generated-docs/react/chatmessage.md +25 -0
  19. package/generated-docs/{core/participantclickevent.track.md → react/chatmessage.message.md} +3 -3
  20. package/generated-docs/react/{chatprops.messageencoder.md → chatmessage.timestamp.md} +3 -3
  21. package/generated-docs/react/chatprops.md +2 -4
  22. package/generated-docs/react/component/chat.md +0 -10
  23. package/generated-docs/react/component/livekitroom.md +5 -0
  24. package/generated-docs/react/component/mediadeviceselect.md +5 -0
  25. package/generated-docs/react/focuslayoutcontainerprops.md +4 -4
  26. package/generated-docs/react/focuslayoutprops.md +5 -5
  27. package/generated-docs/react/focustoggleprops.md +5 -5
  28. package/generated-docs/react/gridlayoutprops.md +4 -4
  29. package/generated-docs/react/hook/usechat.md +1 -4
  30. package/generated-docs/react/hook/useisencrypted.md +29 -0
  31. package/generated-docs/react/hook/uselivekitroom.md +3 -0
  32. package/generated-docs/react/hook/usemediadeviceselect.md +5 -0
  33. package/generated-docs/react/hook/usestartvideo.md +43 -0
  34. package/generated-docs/react/index.md +181 -168
  35. package/generated-docs/react/layoutcontextproviderprops.md +5 -5
  36. package/generated-docs/react/livekitroomprops.md +1 -0
  37. package/generated-docs/react/livekitroomprops.onencryptionerror.md +13 -0
  38. package/generated-docs/react/localuserchoices.md +28 -0
  39. package/generated-docs/react/mediadeviceselectprops.md +3 -2
  40. package/generated-docs/react/mediadeviceselectprops.onerror.md +13 -0
  41. package/generated-docs/react/messagedecoder.md +20 -0
  42. package/generated-docs/react/messageencoder.md +20 -0
  43. package/generated-docs/react/meta-data.json +1 -1
  44. package/generated-docs/react/participanttileprops.md +8 -8
  45. package/generated-docs/react/pinstate.md +20 -0
  46. package/generated-docs/react/prejoinprops.md +13 -13
  47. package/generated-docs/react/{chatprops.messagedecoder.md → receivedchatmessage.from.md} +3 -3
  48. package/generated-docs/react/receivedchatmessage.md +26 -0
  49. package/generated-docs/react/setloglevel.md +20 -0
  50. package/generated-docs/react/trackloopprops.md +4 -4
  51. package/generated-docs/react/trackmutedindicatorprops.md +6 -6
  52. package/generated-docs/react/trackreference.md +22 -0
  53. package/generated-docs/react/trackreferenceorplaceholder.md +20 -0
  54. package/generated-docs/react/tracktoggleprops.md +7 -7
  55. package/generated-docs/react/usefocustoggleprops.md +6 -6
  56. package/generated-docs/react/usemediadeviceselectprops.md +1 -0
  57. package/generated-docs/react/usemediadeviceselectprops.onerror.md +17 -0
  58. package/generated-docs/react/useparticipanttileprops.md +9 -9
  59. package/generated-docs/react/usepersistentuserchoicesoptions.md +5 -5
  60. package/generated-docs/react/usestartvideoprops.md +25 -0
  61. package/generated-docs/react/usestartvideoprops.props.md +13 -0
  62. package/generated-docs/react/usestartvideoprops.room.md +13 -0
  63. package/generated-docs/react/usetrackshookreturntype.md +1 -1
  64. package/generated-docs/react/usevisualstableupdateoptions.md +3 -3
  65. package/generated-docs/react/videoconferenceprops.md +2 -2
  66. package/generated-docs/react/videotrackprops.md +10 -10
  67. package/generated-docs/react/widgetstate.md +21 -0
  68. package/package.json +2 -2
  69. package/generated-docs/core/istrackreference.md +0 -16
  70. package/generated-docs/core/participantclickevent.md +0 -23
  71. package/generated-docs/core/participantclickevent.participant.md +0 -13
@@ -15,6 +15,8 @@
15
15
  export interface ChatMessage
16
16
  ```
17
17
 
18
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
19
+
18
20
  ## Properties
19
21
 
20
22
  | Property | Type | Description |
@@ -0,0 +1,24 @@
1
+ ---
2
+ {
3
+ "title": "ChatOptions type",
4
+ "linkToSource": "https://github.com/livekit/components-js/blob/main/packages/core/src/components/chat.ts"
5
+ }
6
+ ---
7
+
8
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
9
+
10
+ # ChatOptions type
11
+
12
+ **Signature:**
13
+
14
+ ```typescript
15
+ export type ChatOptions = {
16
+ messageEncoder?: (message: ChatMessage) => Uint8Array;
17
+ messageDecoder?: (message: Uint8Array) => ReceivedChatMessage;
18
+ channelTopic?: string;
19
+ };
20
+ ```
21
+
22
+ **References:** [ChatMessage](./core/chatmessage.md)<!-- -->, [ReceivedChatMessage](./core/receivedchatmessage.md)
23
+
24
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
@@ -14,6 +14,7 @@
14
14
  ```typescript
15
15
  export declare function createMediaDeviceObserver(
16
16
  kind?: MediaDeviceKind,
17
+ onError?: (e: Error) => void,
17
18
  requestPermissions?: boolean
18
- ): Observable<MediaDeviceInfo[]>;
19
+ ): Observable<void | MediaDeviceInfo[] | undefined>;
19
20
  ```
@@ -20,6 +20,7 @@
20
20
  | [BaseDataMessage](./core/basedatamessage.md) | |
21
21
  | [CaptureOptionsBySource](./core/captureoptionsbysource.md) | |
22
22
  | [ChatMessage](./core/chatmessage.md) | |
23
+ | [ChatOptions](./core/chatoptions.md) | |
23
24
  | [computeMenuPosition(button, menu)](./core/computemenuposition.md) | |
24
25
  | [connectedParticipantObserver(room, identity, options)](./core/connectedparticipantobserver.md) | |
25
26
  | [ConnectedParticipantObserverOptions](./core/connectedparticipantobserveroptions.md) | |
@@ -30,7 +31,7 @@
30
31
  | [createDataObserver(room)](./core/createdataobserver.md) | |
31
32
  | [createDefaultGrammar](./core/createdefaultgrammar.md) | |
32
33
  | [createIsSpeakingObserver(participant)](./core/createisspeakingobserver.md) | |
33
- | [createMediaDeviceObserver(kind, requestPermissions)](./core/createmediadeviceobserver.md) | |
34
+ | [createMediaDeviceObserver(kind, onError, requestPermissions)](./core/createmediadeviceobserver.md) | |
34
35
  | [createTrackObserver(participant, options)](./core/createtrackobserver.md) | |
35
36
  | [createUrlRegExp(options)](./core/createurlregexp.md) | |
36
37
  | [cssPrefix](./core/cssprefix.md) | |
@@ -50,7 +51,6 @@
50
51
  | [isRemote(p)](./core/isremote.md) | |
51
52
  | [isSourcesWithOptions(sources)](./core/issourceswithoptions.md) | |
52
53
  | [isSourceWitOptions(source)](./core/issourcewitoptions.md) | |
53
- | [isTrackReference(trackReference)](./core/istrackreference.md) | |
54
54
  | [isTrackReferencePinned(trackReference, pinState)](./core/istrackreferencepinned.md) | Check if the <code>TrackReference</code> is pinned. |
55
55
  | [isTrackReferencePlaceholder(trackReference)](./core/istrackreferenceplaceholder.md) | |
56
56
  | [loadUserChoices(defaults, preventLoad)](./core/loaduserchoices.md) | Reads the user choices from local storage, or returns the default settings if none are found. |
@@ -64,7 +64,6 @@
64
64
  | [observeParticipantMedia(participant)](./core/observeparticipantmedia.md) | |
65
65
  | [observeRoomEvents(room, events)](./core/observeroomevents.md) | |
66
66
  | [observeTrackEvents(track, events)](./core/observetrackevents.md) | |
67
- | [ParticipantClickEvent](./core/participantclickevent.md) | |
68
67
  | [participantEventSelector(participant, event)](./core/participanteventselector.md) | |
69
68
  | [ParticipantFilter](./core/participantfilter.md) | |
70
69
  | [participantInfoObserver(participant)](./core/participantinfoobserver.md) | |
@@ -79,6 +78,7 @@
79
78
  | [roomEventSelector(room, event)](./core/roomeventselector.md) | |
80
79
  | [roomInfoObserver(room)](./core/roominfoobserver.md) | |
81
80
  | [roomObserver(room)](./core/roomobserver.md) | |
81
+ | [roomVideoPlaybackAllowedObservable(room)](./core/roomvideoplaybackallowedobservable.md) | |
82
82
  | [saveUserChoices(userChoices, preventSave)](./core/saveuserchoices.md) | Saves user choices to local storage. |
83
83
  | [screenShareObserver(room)](./core/screenshareobserver.md) | |
84
84
  | [ScreenShareTrackMap](./core/screensharetrackmap.md) | |
@@ -102,6 +102,7 @@
102
102
  | [setupParticipantName(participant)](./core/setupparticipantname.md) | |
103
103
  | [setupParticipantTile()](./core/setupparticipanttile.md) | |
104
104
  | [setupStartAudio()](./core/setupstartaudio.md) | |
105
+ | [setupStartVideo()](./core/setupstartvideo.md) | |
105
106
  | [setupTrackMutedIndicator(trackRef)](./core/setuptrackmutedindicator.md) | |
106
107
  | [sortParticipants(participants)](./core/sortparticipants.md) | Default sort for participants, it'll order participants by: 1. local participant 2. dominant speaker (speaker with the loudest audio level) 3. other speakers that are recently active 4. participants with video on 5. by joinedAt |
107
108
  | [sortTrackReferences(tracks)](./core/sorttrackreferences.md) | Default sort for <code>TrackReferenceOrPlaceholder</code>, it'll order participants by: 1. local camera track (publication.isLocal) 2. remote screen_share track 3. local screen_share track 4. remote dominant speaker camera track (sorted by speaker with the loudest audio level) 5. other remote speakers that are recently active 6. remote unmuted camera tracks 7. remote tracks sorted by joinedAt |
@@ -16,3 +16,5 @@ export type PinState = TrackReferenceOrPlaceholder[];
16
16
  ```
17
17
 
18
18
  **References:** [TrackReferenceOrPlaceholder](./core/trackreferenceorplaceholder.md)
19
+
20
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
@@ -17,6 +17,8 @@ export interface ReceivedChatMessage extends ChatMessage
17
17
 
18
18
  **Extends:** [ChatMessage](./core/chatmessage.md)
19
19
 
20
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
21
+
20
22
  ## Properties
21
23
 
22
24
  | Property | Type | Description |
@@ -0,0 +1,18 @@
1
+ ---
2
+ {
3
+ "title": "roomVideoPlaybackAllowedObservable",
4
+ "linkToSource": "https://github.com/livekit/components-js/blob/main/packages/core/src/observables/room.ts"
5
+ }
6
+ ---
7
+
8
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
9
+
10
+ # roomVideoPlaybackAllowedObservable
11
+
12
+ **Signature:**
13
+
14
+ ```typescript
15
+ export declare function roomVideoPlaybackAllowedObservable(room: Room): Observable<{
16
+ canPlayVideo: boolean;
17
+ }>;
18
+ ```
@@ -14,14 +14,10 @@
14
14
  ```typescript
15
15
  export declare function setupChat(
16
16
  room: Room,
17
- options?: {
18
- messageEncoder?: (message: ChatMessage) => Uint8Array;
19
- messageDecoder?: (message: Uint8Array) => ReceivedChatMessage;
20
- }
17
+ options?: ChatOptions
21
18
  ): {
22
19
  messageObservable: import("rxjs").Observable<ReceivedChatMessage[]>;
23
20
  isSendingObservable: BehaviorSubject<boolean>;
24
21
  send: (message: string) => Promise<void>;
25
- destroy: () => void;
26
22
  };
27
23
  ```
@@ -0,0 +1,20 @@
1
+ ---
2
+ {
3
+ "title": "setupStartVideo",
4
+ "linkToSource": "https://github.com/livekit/components-js/blob/main/packages/core/src/components/startVideo.ts"
5
+ }
6
+ ---
7
+
8
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
9
+
10
+ # setupStartVideo
11
+
12
+ **Signature:**
13
+
14
+ ```typescript
15
+ export declare function setupStartVideo(): {
16
+ className: string;
17
+ roomVideoPlaybackAllowedObservable: typeof roomVideoPlaybackAllowedObservable;
18
+ handleStartVideoPlayback: (room: Room) => Promise<void>;
19
+ };
20
+ ```
@@ -18,3 +18,5 @@ export type TrackReference = {
18
18
  source: Track.Source;
19
19
  };
20
20
  ```
21
+
22
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
@@ -16,3 +16,5 @@ export type TrackReferenceOrPlaceholder = TrackReference | TrackReferencePlaceho
16
16
  ```
17
17
 
18
18
  **References:** [TrackReference](./core/trackreference.md)<!-- -->, [TrackReferencePlaceholder](./core/trackreferenceplaceholder.md)
19
+
20
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
@@ -18,3 +18,5 @@ export type TrackReferencePlaceholder = {
18
18
  source: Track.Source;
19
19
  };
20
20
  ```
21
+
22
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
@@ -17,3 +17,5 @@ export type WidgetState = {
17
17
  unreadMessages: number;
18
18
  };
19
19
  ```
20
+
21
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
@@ -21,13 +21,13 @@ export interface AudioTrackProps extends React.AudioHTMLAttributes<HTMLAudioElem
21
21
 
22
22
  ## Properties
23
23
 
24
- | Property | Type | Description |
25
- | -------------------------------------------------------------------------------------- | ------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ |
26
- | [muted?](./react/audiotrackprops.muted.md) | boolean | _(Optional)_ Mutes the audio track if set to <code>true</code>. |
27
- | [name?](./react/audiotrackprops.name.md) | string | _(Optional)_ |
28
- | [onSubscriptionStatusChanged?](./react/audiotrackprops.onsubscriptionstatuschanged.md) | (subscribed: boolean) =&gt; void | _(Optional)_ |
29
- | [participant?](./react/audiotrackprops.participant.md) | Participant | _(Optional)_ |
30
- | [publication?](./react/audiotrackprops.publication.md) | TrackPublication | _(Optional)_ |
31
- | [source?](./react/audiotrackprops.source.md) | Track.Source | _(Optional)_ |
32
- | [trackRef?](./react/audiotrackprops.trackref.md) | [TrackReference](./core/trackreference.md) | _(Optional)_ The track reference of the track from which the audio is to be rendered. |
33
- | [volume?](./react/audiotrackprops.volume.md) | number | _(Optional)_ Sets the volume of the audio track. By default, the range is between <code>0.0</code> and <code>1.0</code>. |
24
+ | Property | Type | Description |
25
+ | -------------------------------------------------------------------------------------- | ------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
26
+ | [muted?](./react/audiotrackprops.muted.md) | boolean | _(Optional)_ Mutes the audio track if set to <code>true</code>. |
27
+ | [name?](./react/audiotrackprops.name.md) | string | _(Optional)_ |
28
+ | [onSubscriptionStatusChanged?](./react/audiotrackprops.onsubscriptionstatuschanged.md) | (subscribed: boolean) =&gt; void | _(Optional)_ |
29
+ | [participant?](./react/audiotrackprops.participant.md) | Participant | _(Optional)_ |
30
+ | [publication?](./react/audiotrackprops.publication.md) | TrackPublication | _(Optional)_ |
31
+ | [source?](./react/audiotrackprops.source.md) | Track.Source | _(Optional)_ |
32
+ | [trackRef?](./react/audiotrackprops.trackref.md) | [TrackReference](./react/trackreference.md) | _(Optional)_ The track reference of the track from which the audio is to be rendered. |
33
+ | [volume?](./react/audiotrackprops.volume.md) | number | _(Optional)_ Sets the volume of the audio track. By default, the range is between <code>0.0</code> and <code>1.0</code>. |
@@ -21,7 +21,7 @@ export interface AudioVisualizerProps extends React.HTMLAttributes<SVGElement>
21
21
 
22
22
  ## Properties
23
23
 
24
- | Property | Type | Description |
25
- | ----------------------------------------------------------- | -------------------------------------------------------------------- | ------------ |
26
- | [participant?](./react/audiovisualizerprops.participant.md) | Participant | _(Optional)_ |
27
- | [trackRef?](./react/audiovisualizerprops.trackref.md) | [TrackReferenceOrPlaceholder](./core/trackreferenceorplaceholder.md) | _(Optional)_ |
24
+ | Property | Type | Description |
25
+ | ----------------------------------------------------------- | --------------------------------------------------------------------- | ------------ |
26
+ | [participant?](./react/audiovisualizerprops.participant.md) | Participant | _(Optional)_ |
27
+ | [trackRef?](./react/audiovisualizerprops.trackref.md) | [TrackReferenceOrPlaceholder](./react/trackreferenceorplaceholder.md) | _(Optional)_ |
@@ -21,8 +21,8 @@ export interface CarouselLayoutProps extends React.HTMLAttributes<HTMLMediaEleme
21
21
 
22
22
  ## Properties
23
23
 
24
- | Property | Type | Description |
25
- | ---------------------------------------------------------- | -------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
26
- | [children](./react/carousellayoutprops.children.md) | React.ReactNode | |
27
- | [orientation?](./react/carousellayoutprops.orientation.md) | 'vertical' \| 'horizontal' | _(Optional)_ Place the tiles vertically or horizontally next to each other. If undefined orientation is guessed by the dimensions of the container. |
28
- | [tracks](./react/carousellayoutprops.tracks.md) | [TrackReferenceOrPlaceholder](./core/trackreferenceorplaceholder.md)<!-- -->\[\] | |
24
+ | Property | Type | Description |
25
+ | ---------------------------------------------------------- | --------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
26
+ | [children](./react/carousellayoutprops.children.md) | React.ReactNode | |
27
+ | [orientation?](./react/carousellayoutprops.orientation.md) | 'vertical' \| 'horizontal' | _(Optional)_ Place the tiles vertically or horizontally next to each other. If undefined orientation is guessed by the dimensions of the container. |
28
+ | [tracks](./react/carousellayoutprops.tracks.md) | [TrackReferenceOrPlaceholder](./react/trackreferenceorplaceholder.md)<!-- -->\[\] | |
@@ -23,9 +23,9 @@ export interface ChatEntryProps extends React.HTMLAttributes<HTMLLIElement>
23
23
 
24
24
  ## Properties
25
25
 
26
- | Property | Type | Description |
27
- | --------------------------------------------------------------- | ---------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |
28
- | [entry](./react/chatentryprops.entry.md) | [ReceivedChatMessage](./core/receivedchatmessage.md) | The chat massage object to display. |
29
- | [hideName?](./react/chatentryprops.hidename.md) | boolean | _(Optional)_ Hide sender name. Useful when displaying multiple consecutive chat messages from the same person. |
30
- | [hideTimestamp?](./react/chatentryprops.hidetimestamp.md) | boolean | _(Optional)_ Hide message timestamp. |
31
- | [messageFormatter?](./react/chatentryprops.messageformatter.md) | [MessageFormatter](./react/messageformatter.md) | _(Optional)_ An optional formatter for the message body. |
26
+ | Property | Type | Description |
27
+ | --------------------------------------------------------------- | ----------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |
28
+ | [entry](./react/chatentryprops.entry.md) | [ReceivedChatMessage](./react/receivedchatmessage.md) | The chat massage object to display. |
29
+ | [hideName?](./react/chatentryprops.hidename.md) | boolean | _(Optional)_ Hide sender name. Useful when displaying multiple consecutive chat messages from the same person. |
30
+ | [hideTimestamp?](./react/chatentryprops.hidetimestamp.md) | boolean | _(Optional)_ Hide message timestamp. |
31
+ | [messageFormatter?](./react/chatentryprops.messageformatter.md) | [MessageFormatter](./react/messageformatter.md) | _(Optional)_ An optional formatter for the message body. |
@@ -0,0 +1,25 @@
1
+ ---
2
+ {
3
+ "title": "ChatMessage interface",
4
+ "linkToSource": "https://github.com/livekit/components-js/blob/main/packages/react/../core/src/components/chat.ts"
5
+ }
6
+ ---
7
+
8
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
9
+
10
+ # ChatMessage interface
11
+
12
+ **Signature:**
13
+
14
+ ```typescript
15
+ export interface ChatMessage
16
+ ```
17
+
18
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
19
+
20
+ ## Properties
21
+
22
+ | Property | Type | Description |
23
+ | --------------------------------------------- | ------ | ----------- |
24
+ | [message](./react/chatmessage.message.md) | string | |
25
+ | [timestamp](./react/chatmessage.timestamp.md) | number | |
@@ -1,13 +1,13 @@
1
1
  ---
2
- { "title": "ParticipantClickEvent.track property" }
2
+ { "title": "ChatMessage.message property" }
3
3
  ---
4
4
 
5
5
  <!-- Do not edit this file. It is automatically generated by API Documenter. -->
6
6
 
7
- # ParticipantClickEvent.track property
7
+ # ChatMessage.message property
8
8
 
9
9
  **Signature:**
10
10
 
11
11
  ```typescript
12
- track?: TrackPublication;
12
+ message: string;
13
13
  ```
@@ -1,13 +1,13 @@
1
1
  ---
2
- { "title": "ChatProps.messageEncoder property" }
2
+ { "title": "ChatMessage.timestamp property" }
3
3
  ---
4
4
 
5
5
  <!-- Do not edit this file. It is automatically generated by API Documenter. -->
6
6
 
7
- # ChatProps.messageEncoder property
7
+ # ChatMessage.timestamp property
8
8
 
9
9
  **Signature:**
10
10
 
11
11
  ```typescript
12
- messageEncoder?: MessageEncoder;
12
+ timestamp: number;
13
13
  ```
@@ -12,10 +12,10 @@
12
12
  **Signature:**
13
13
 
14
14
  ```typescript
15
- export interface ChatProps extends React.HTMLAttributes<HTMLDivElement>
15
+ export interface ChatProps extends React.HTMLAttributes<HTMLDivElement>, ChatOptions
16
16
  ```
17
17
 
18
- **Extends:** React.HTMLAttributes&lt;HTMLDivElement&gt;
18
+ **Extends:** React.HTMLAttributes&lt;HTMLDivElement&gt;, ChatOptions
19
19
 
20
20
  {% partial file="p_usage.md" variables={exampleCount: 0} /%}
21
21
 
@@ -23,6 +23,4 @@ export interface ChatProps extends React.HTMLAttributes<HTMLDivElement>
23
23
 
24
24
  | Property | Type | Description |
25
25
  | ---------------------------------------------------------- | ----------------------------------------------- | ------------ |
26
- | [messageDecoder?](./react/chatprops.messagedecoder.md) | [MessageDecoder](./core/messagedecoder.md) | _(Optional)_ |
27
- | [messageEncoder?](./react/chatprops.messageencoder.md) | [MessageEncoder](./core/messageencoder.md) | _(Optional)_ |
28
26
  | [messageFormatter?](./react/chatprops.messageformatter.md) | [MessageFormatter](./react/messageformatter.md) | _(Optional)_ |
@@ -29,16 +29,6 @@ import { Chat } from "@livekit/components-react";
29
29
 
30
30
  ## Properties
31
31
 
32
- {% parameter name="messageDecoder" type="MessageDecoder" optional=true %}
33
- _(Optional)_
34
-
35
- {% /parameter %}
36
-
37
- {% parameter name="messageEncoder" type="MessageEncoder" optional=true %}
38
- _(Optional)_
39
-
40
- {% /parameter %}
41
-
42
32
  {% parameter name="messageFormatter" type="MessageFormatter" optional=true %}
43
33
  _(Optional)_
44
34
 
@@ -64,6 +64,11 @@ _(Optional)_
64
64
 
65
65
  {% /parameter %}
66
66
 
67
+ {% parameter name="onEncryptionError" type="(error: Error) => void" optional=true %}
68
+ _(Optional)_
69
+
70
+ {% /parameter %}
71
+
67
72
  {% parameter name="onError" type="(error: Error) => void" optional=true %}
68
73
  _(Optional)_
69
74
 
@@ -57,6 +57,11 @@ _(Optional)_
57
57
 
58
58
  {% /parameter %}
59
59
 
60
+ {% parameter name="onError" type="(e: Error) => void" optional=true %}
61
+ _(Optional)_
62
+
63
+ {% /parameter %}
64
+
60
65
  {% parameter name="requestPermissions" type="boolean" optional=true %}
61
66
  _(Optional)_ this will call getUserMedia if the permissions are not yet given to enumerate the devices with device labels. in some browsers multiple calls to getUserMedia result in multiple permission prompts. It's generally advised only flip this to true, once a (preview) track has been acquired successfully with the appropriate permissions.
62
67
 
@@ -21,7 +21,7 @@ export interface FocusLayoutContainerProps extends React.HTMLAttributes<HTMLDivE
21
21
 
22
22
  ## Properties
23
23
 
24
- | Property | Type | Description |
25
- | ------------------------------------------------------------------ | ------------------------------------------ | ------------ |
26
- | [focusTrack?](./react/focuslayoutcontainerprops.focustrack.md) | [TrackReference](./core/trackreference.md) | _(Optional)_ |
27
- | [participants?](./react/focuslayoutcontainerprops.participants.md) | Array&lt;Participant&gt; | _(Optional)_ |
24
+ | Property | Type | Description |
25
+ | ------------------------------------------------------------------ | ------------------------------------------- | ------------ |
26
+ | [focusTrack?](./react/focuslayoutcontainerprops.focustrack.md) | [TrackReference](./react/trackreference.md) | _(Optional)_ |
27
+ | [participants?](./react/focuslayoutcontainerprops.participants.md) | Array&lt;Participant&gt; | _(Optional)_ |
@@ -21,8 +21,8 @@ export interface FocusLayoutProps extends React.HTMLAttributes<HTMLElement>
21
21
 
22
22
  ## Properties
23
23
 
24
- | Property | Type | Description |
25
- | --------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ------------------------------------------------------ |
26
- | [onParticipantClick?](./react/focuslayoutprops.onparticipantclick.md) | (evt: [ParticipantClickEvent](./core/participantclickevent.md)<!-- -->) =&gt; void | _(Optional)_ |
27
- | [track?](./react/focuslayoutprops.track.md) | [TrackReferenceOrPlaceholder](./core/trackreferenceorplaceholder.md) | _(Optional)_ |
28
- | [trackRef?](./react/focuslayoutprops.trackref.md) | [TrackReferenceOrPlaceholder](./core/trackreferenceorplaceholder.md) | _(Optional)_ The track to display in the focus layout. |
24
+ | Property | Type | Description |
25
+ | --------------------------------------------------------------------- | --------------------------------------------------------------------- | ------------------------------------------------------ |
26
+ | [onParticipantClick?](./react/focuslayoutprops.onparticipantclick.md) | (evt: ParticipantClickEvent) =&gt; void | _(Optional)_ |
27
+ | [track?](./react/focuslayoutprops.track.md) | [TrackReferenceOrPlaceholder](./react/trackreferenceorplaceholder.md) | _(Optional)_ |
28
+ | [trackRef?](./react/focuslayoutprops.trackref.md) | [TrackReferenceOrPlaceholder](./react/trackreferenceorplaceholder.md) | _(Optional)_ The track to display in the focus layout. |
@@ -21,8 +21,8 @@ export interface FocusToggleProps extends React.ButtonHTMLAttributes<HTMLButtonE
21
21
 
22
22
  ## Properties
23
23
 
24
- | Property | Type | Description |
25
- | ------------------------------------------------------- | -------------------------------------------------------------------- | ------------ |
26
- | [participant?](./react/focustoggleprops.participant.md) | Participant | _(Optional)_ |
27
- | [trackRef?](./react/focustoggleprops.trackref.md) | [TrackReferenceOrPlaceholder](./core/trackreferenceorplaceholder.md) | _(Optional)_ |
28
- | [trackSource?](./react/focustoggleprops.tracksource.md) | Track.Source | _(Optional)_ |
24
+ | Property | Type | Description |
25
+ | ------------------------------------------------------- | --------------------------------------------------------------------- | ------------ |
26
+ | [participant?](./react/focustoggleprops.participant.md) | Participant | _(Optional)_ |
27
+ | [trackRef?](./react/focustoggleprops.trackref.md) | [TrackReferenceOrPlaceholder](./react/trackreferenceorplaceholder.md) | _(Optional)_ |
28
+ | [trackSource?](./react/focustoggleprops.tracksource.md) | Track.Source | _(Optional)_ |
@@ -21,7 +21,7 @@ export interface GridLayoutProps extends React.HTMLAttributes<HTMLDivElement>, P
21
21
 
22
22
  ## Properties
23
23
 
24
- | Property | Type | Description |
25
- | ----------------------------------------------- | -------------------------------------------------------------------------------- | ----------- |
26
- | [children](./react/gridlayoutprops.children.md) | React.ReactNode | |
27
- | [tracks](./react/gridlayoutprops.tracks.md) | [TrackReferenceOrPlaceholder](./core/trackreferenceorplaceholder.md)<!-- -->\[\] | |
24
+ | Property | Type | Description |
25
+ | ----------------------------------------------- | --------------------------------------------------------------------------------- | ----------- |
26
+ | [children](./react/gridlayoutprops.children.md) | React.ReactNode | |
27
+ | [tracks](./react/gridlayoutprops.tracks.md) | [TrackReferenceOrPlaceholder](./react/trackreferenceorplaceholder.md)<!-- -->\[\] | |
@@ -25,10 +25,7 @@ It is possible to pass configurations for custom message encoding and decoding.
25
25
 
26
26
  ## Properties
27
27
 
28
- {% parameter name="options" type="{
29
- messageEncoder?: MessageEncoder;
30
- messageDecoder?: MessageDecoder;
31
- }" optional=true %}
28
+ {% parameter name="options" type="ChatOptions" optional=true %}
32
29
  {% /parameter %}
33
30
 
34
31
  ## Returns
@@ -0,0 +1,29 @@
1
+ ---
2
+ {
3
+ "title": "useIsEncrypted",
4
+ "linkToSource": "https://github.com/livekit/components-js/blob/main/packages/react/src/hooks/useIsEncrypted.ts"
5
+ }
6
+ ---
7
+
8
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
9
+
10
+ # useIsEncrypted
11
+
12
+ ## Import
13
+
14
+ ```typescript
15
+ import { useIsEncrypted } from "@livekit/components-react";
16
+ ```
17
+
18
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
19
+
20
+ ## Properties
21
+
22
+ {% parameter name="participant" type="Participant" optional=true %}
23
+ {% /parameter %}
24
+
25
+ ## Returns
26
+
27
+ ```typescript
28
+ boolean;
29
+ ```
@@ -59,6 +59,9 @@ Define options how to connect to the LiveKit server.
59
59
  {% parameter name="onDisconnected" type="() => void" optional=true %}
60
60
  {% /parameter %}
61
61
 
62
+ {% parameter name="onEncryptionError" type="(error: Error) => void" optional=true %}
63
+ {% /parameter %}
64
+
62
65
  {% parameter name="onError" type="(error: Error) => void" optional=true %}
63
66
  {% /parameter %}
64
67
 
@@ -32,6 +32,11 @@ const { devices, activeDeviceId, setActiveMediaDevice } = useMediaDeviceSelect({
32
32
  {% parameter name="kind" type="MediaDeviceKind" optional=false %}
33
33
  {% /parameter %}
34
34
 
35
+ {% parameter name="onError" type="(e: Error) => void" optional=true %}
36
+ this callback gets called if an error is thrown when failing to select a device and also if a user denied permissions, eventhough the `requestPermissions` option is set to `true`<!-- -->. Most commonly this will emit a MediaDeviceError
37
+
38
+ {% /parameter %}
39
+
35
40
  {% parameter name="requestPermissions" type="boolean" optional=true %}
36
41
  this will call getUserMedia if the permissions are not yet given to enumerate the devices with device labels. in some browsers multiple calls to getUserMedia result in multiple permission prompts. It's generally advised only flip this to true, once a (preview) track has been acquired successfully with the appropriate permissions.
37
42
 
@@ -0,0 +1,43 @@
1
+ ---
2
+ {
3
+ "title": "useStartVideo",
4
+ "linkToSource": "https://github.com/livekit/components-js/blob/main/packages/react/src/hooks/useStartVideo.ts"
5
+ }
6
+ ---
7
+
8
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
9
+
10
+ # useStartVideo
11
+
12
+ In some browsers to start video playback in low power mode, the user must perform a user-initiated event such as clicking a button. The `useStartVideo` hook returns an object with a boolean `canPlayVideo` flag that indicates whether video playback is allowed in the current context, as well as a `startVideo` function that can be called in a button `onClick` callback to start video playback in the current context.
13
+
14
+ ## Import
15
+
16
+ ```typescript
17
+ import { useStartVideo } from "@livekit/components-react";
18
+ ```
19
+
20
+ {% partial file="p_usage.md" variables={exampleCount: 0} /%}
21
+
22
+ ## Properties
23
+
24
+ {% parameter name="props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
25
+ {% /parameter %}
26
+
27
+ {% parameter name="room" type="Room" optional=true %}
28
+ {% /parameter %}
29
+
30
+ ## Returns
31
+
32
+ ```typescript
33
+ {
34
+ mergedProps: React.ButtonHTMLAttributes<HTMLButtonElement> & {
35
+ className: string;
36
+ onClick: () => void;
37
+ style: {
38
+ display: string;
39
+ };
40
+ };
41
+ canPlayVideo: boolean;
42
+ }
43
+ ```