@livekit/components-js-docs 0.1.74 → 0.1.76

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.
@@ -14,7 +14,7 @@
14
14
  ```typescript
15
15
  export declare function participantByIdentifierObserver(
16
16
  room: Room,
17
- { kind, identity }: ParticipantIdentifier,
17
+ input: ParticipantIdentifier,
18
18
  options?: ConnectedParticipantObserverOptions
19
19
  ): Observable<RemoteParticipant | undefined>;
20
20
  ```
@@ -18,7 +18,7 @@ export declare function setupDataMessageHandler<T extends string>(
18
18
  onMessage?: (msg: ReceivedDataMessage<T>) => void
19
19
  ): {
20
20
  messageObservable: Observable<{
21
- payload: Uint8Array<ArrayBufferLike>;
21
+ payload: Uint8Array<ArrayBuffer>;
22
22
  topic: T;
23
23
  from: import("livekit-client").RemoteParticipant | undefined;
24
24
  }>;
@@ -23,7 +23,7 @@ Depends on the `LayoutContext` to work properly.
23
23
 
24
24
  ## Properties
25
25
 
26
- {% parameter name="{ props }.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
26
+ {% parameter name="input.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
27
27
  {% /parameter %}
28
28
 
29
29
  ## Returns
@@ -26,10 +26,10 @@ return <button {...mergedProps}>{inFocus ? "Unfocus" : "Focus"}</button>;
26
26
 
27
27
  ## Properties
28
28
 
29
- {% parameter name="{ trackRef, props }.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
29
+ {% parameter name="input.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
30
30
  {% /parameter %}
31
31
 
32
- {% parameter name="{ trackRef, props }.trackRef" type="TrackReferenceOrPlaceholder" optional=true %}
32
+ {% parameter name="input.trackRef" type="TrackReferenceOrPlaceholder" optional=true %}
33
33
  {% /parameter %}
34
34
 
35
35
  ## Returns
@@ -26,7 +26,7 @@ const audioDevices = useMediaDevices({ kind: "audioinput" });
26
26
 
27
27
  ## Properties
28
28
 
29
- {% parameter name="{ kind, onError, }" type="{
29
+ {% parameter name="input" type="{
30
30
  kind: MediaDeviceKind;
31
31
  onError?: (e: Error) => void;
32
32
  }" optional=false %}
@@ -27,23 +27,23 @@ const { devices, activeDeviceId, setActiveMediaDevice } = useMediaDeviceSelect({
27
27
 
28
28
  ## Properties
29
29
 
30
- {% parameter name="{ kind, room, track, requestPermissions, onError, }.kind" type="MediaDeviceKind" optional=false %}
30
+ {% parameter name="input.kind" type="MediaDeviceKind" optional=false %}
31
31
  {% /parameter %}
32
32
 
33
- {% parameter name="{ kind, room, track, requestPermissions, onError, }.onError" type="(e: Error) => void" optional=true %}
33
+ {% parameter name="input.onError" type="(e: Error) => void" optional=true %}
34
34
  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
35
35
 
36
36
  {% /parameter %}
37
37
 
38
- {% parameter name="{ kind, room, track, requestPermissions, onError, }.requestPermissions" type="boolean" optional=true %}
38
+ {% parameter name="input.requestPermissions" type="boolean" optional=true %}
39
39
  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.
40
40
 
41
41
  {% /parameter %}
42
42
 
43
- {% parameter name="{ kind, room, track, requestPermissions, onError, }.room" type="Room" optional=true %}
43
+ {% parameter name="input.room" type="Room" optional=true %}
44
44
  {% /parameter %}
45
45
 
46
- {% parameter name="{ kind, room, track, requestPermissions, onError, }.track" type="LocalAudioTrack | LocalVideoTrack" optional=true %}
46
+ {% parameter name="input.track" type="LocalAudioTrack | LocalVideoTrack" optional=true %}
47
47
  {% /parameter %}
48
48
 
49
49
  ## Returns
@@ -23,16 +23,16 @@ The returned props include many data attributes that are useful for CSS styling
23
23
 
24
24
  ## Properties
25
25
 
26
- {% parameter name="{ trackRef, onParticipantClick, disableSpeakingIndicator, htmlProps, }.htmlProps" type="React.HTMLAttributes<T>" optional=false %}
26
+ {% parameter name="input.htmlProps" type="React.HTMLAttributes<T>" optional=false %}
27
27
  {% /parameter %}
28
28
 
29
- {% parameter name="{ trackRef, onParticipantClick, disableSpeakingIndicator, htmlProps, }.disableSpeakingIndicator" type="boolean" optional=true %}
29
+ {% parameter name="input.disableSpeakingIndicator" type="boolean" optional=true %}
30
30
  {% /parameter %}
31
31
 
32
- {% parameter name="{ trackRef, onParticipantClick, disableSpeakingIndicator, htmlProps, }.onParticipantClick" type="(event: ParticipantClickEvent) => void" optional=true %}
32
+ {% parameter name="input.onParticipantClick" type="(event: ParticipantClickEvent) => void" optional=true %}
33
33
  {% /parameter %}
34
34
 
35
- {% parameter name="{ trackRef, onParticipantClick, disableSpeakingIndicator, htmlProps, }.trackRef" type="TrackReferenceOrPlaceholder" optional=true %}
35
+ {% parameter name="input.trackRef" type="TrackReferenceOrPlaceholder" optional=true %}
36
36
  The track reference to display.
37
37
 
38
38
  {% /parameter %}
@@ -25,10 +25,10 @@ import { useStartAudio } from "@livekit/components-react";
25
25
 
26
26
  ## Properties
27
27
 
28
- {% parameter name="{ room, props }.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
28
+ {% parameter name="input.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
29
29
  {% /parameter %}
30
30
 
31
- {% parameter name="{ room, props }.room" type="Room" optional=true %}
31
+ {% parameter name="input.room" type="Room" optional=true %}
32
32
  {% /parameter %}
33
33
 
34
34
  ## Returns
@@ -25,10 +25,10 @@ import { useStartVideo } from "@livekit/components-react";
25
25
 
26
26
  ## Properties
27
27
 
28
- {% parameter name="{ room, props }.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
28
+ {% parameter name="input.props" type="React.ButtonHTMLAttributes<HTMLButtonElement>" optional=false %}
29
29
  {% /parameter %}
30
30
 
31
- {% parameter name="{ room, props }.room" type="Room" optional=true %}
31
+ {% parameter name="input.room" type="Room" optional=true %}
32
32
  {% /parameter %}
33
33
 
34
34
  ## Returns
@@ -26,7 +26,7 @@ return <button {...buttonProps}>{enabled ? "disable" : "enable"}</button>;
26
26
 
27
27
  ## Properties
28
28
 
29
- {% parameter name="{ source, onChange, initialState, captureOptions, publishOptions, onDeviceError, room, ...rest }.room" type="Room" optional=true %}
29
+ {% parameter name="input.room" type="Room" optional=true %}
30
30
  {% /parameter %}
31
31
 
32
32
  ## Returns