@capgo/capacitor-stream-call 8.0.41 → 8.0.42

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.
package/README.md CHANGED
@@ -25,6 +25,20 @@ The most complete doc is available here: https://capgo.app/docs/plugins/streamca
25
25
 
26
26
  ## Installation
27
27
 
28
+ You can use our AI-Assisted Setup to install the plugin. Add the Capgo skills to your AI tool using the following command:
29
+
30
+ ```bash
31
+ npx skills add https://github.com/cap-go/capacitor-skills --skill capacitor-plugins
32
+ ```
33
+
34
+ Then use the following prompt:
35
+
36
+ ```text
37
+ Use the `capacitor-plugins` skill from `cap-go/capacitor-skills` to install the `@capgo/capacitor-stream-call` plugin in my project.
38
+ ```
39
+
40
+ If you prefer Manual Setup, install the plugin by running the following commands and follow the platform-specific instructions below:
41
+
28
42
  ```bash
29
43
  npm install @capgo/capacitor-stream-call
30
44
  npx cap sync
@@ -26,6 +26,10 @@ import android.view.WindowManager
26
26
  import android.widget.FrameLayout
27
27
  import java.lang.ref.WeakReference
28
28
  import androidx.compose.foundation.layout.fillMaxSize
29
+ import androidx.compose.foundation.layout.windowInsetsPadding
30
+ import androidx.compose.foundation.layout.navigationBars
31
+ import androidx.compose.foundation.layout.WindowInsets
32
+ import androidx.compose.foundation.layout.Box
29
33
  import androidx.compose.runtime.collectAsState
30
34
  import androidx.compose.runtime.getValue
31
35
  import androidx.compose.ui.Modifier
@@ -616,50 +620,52 @@ class StreamCallPlugin : Plugin() {
616
620
 
617
621
  val currentLocal by activeCall.state.me.collectAsStateWithLifecycle()
618
622
 
619
- CallContent(
620
- call = activeCall,
621
- enableInPictureInPicture = false,
622
- onBackPressed = {},
623
- controlsContent = { /* Empty to disable native controls */ },
624
- appBarContent = { /* Empty to disable app bar with stop call button */ },
625
- layout = CallUIController.layoutType.value,
626
- videoRenderer = { videoModifier, videoCall, videoParticipant, videoStyle ->
627
- ParticipantVideo(
628
- modifier = videoModifier,
629
- call = videoCall,
630
- participant = videoParticipant,
631
- style = videoStyle,
632
- actionsContent = {_, _, _ -> {}},
633
- scalingType = if (CallUIController.layoutType.value == LayoutType.GRID) {
634
- VideoScalingType.SCALE_ASPECT_FIT
635
- } else {
636
- VideoScalingType.SCALE_ASPECT_FILL
637
- }
638
- )
639
- },
640
- floatingVideoRenderer = { call, parentSize ->
641
- currentLocal?.let {
642
- FloatingParticipantVideo(
643
- call = call,
644
- participant = currentLocal!!,
645
- style = RegularVideoRendererStyle().copy(isShowingConnectionQualityIndicator = false),
646
- parentBounds = parentSize,
647
- videoRenderer = { _ ->
648
- ParticipantVideo(
649
- modifier = Modifier
650
- .fillMaxSize()
651
- .clip(VideoTheme.shapes.dialog),
652
- call = call,
653
- participant = it,
654
- style = RegularVideoRendererStyle().copy(isShowingConnectionQualityIndicator = false),
655
- actionsContent = {_, _, _ -> {}},
656
- )
623
+ Box(modifier = Modifier.windowInsetsPadding(WindowInsets.navigationBars)) {
624
+ CallContent(
625
+ call = activeCall,
626
+ enableInPictureInPicture = false,
627
+ onBackPressed = {},
628
+ controlsContent = { /* Empty to disable native controls */ },
629
+ appBarContent = { /* Empty to disable app bar with stop call button */ },
630
+ layout = CallUIController.layoutType.value,
631
+ videoRenderer = { videoModifier, videoCall, videoParticipant, videoStyle ->
632
+ ParticipantVideo(
633
+ modifier = videoModifier,
634
+ call = videoCall,
635
+ participant = videoParticipant,
636
+ style = videoStyle,
637
+ actionsContent = {_, _, _ -> {}},
638
+ scalingType = if (CallUIController.layoutType.value == LayoutType.GRID) {
639
+ VideoScalingType.SCALE_ASPECT_FIT
640
+ } else {
641
+ VideoScalingType.SCALE_ASPECT_FILL
657
642
  }
658
643
  )
659
- }
644
+ },
645
+ floatingVideoRenderer = { call, parentSize ->
646
+ currentLocal?.let {
647
+ FloatingParticipantVideo(
648
+ call = call,
649
+ participant = currentLocal!!,
650
+ style = RegularVideoRendererStyle().copy(isShowingConnectionQualityIndicator = false),
651
+ parentBounds = parentSize,
652
+ videoRenderer = { _ ->
653
+ ParticipantVideo(
654
+ modifier = Modifier
655
+ .fillMaxSize()
656
+ .clip(VideoTheme.shapes.dialog),
657
+ call = call,
658
+ participant = it,
659
+ style = RegularVideoRendererStyle().copy(isShowingConnectionQualityIndicator = false),
660
+ actionsContent = {_, _, _ -> {}},
661
+ )
662
+ }
663
+ )
664
+ }
660
665
 
661
- }
662
- )
666
+ }
667
+ )
668
+ }
663
669
  }
664
670
  }
665
671
  }
@@ -12,7 +12,7 @@ import WebKit
12
12
  */
13
13
  @objc(StreamCallPlugin)
14
14
  public class StreamCallPlugin: CAPPlugin, CAPBridgedPlugin {
15
- private let pluginVersion: String = "8.0.41"
15
+ private let pluginVersion: String = "8.0.42"
16
16
  public let identifier = "StreamCallPlugin"
17
17
  public let jsName = "StreamCall"
18
18
  public let pluginMethods: [CAPPluginMethod] = [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@capgo/capacitor-stream-call",
3
- "version": "8.0.41",
3
+ "version": "8.0.42",
4
4
  "description": "Uses the https://getstream.io/ SDK to implement calling in Capacitor",
5
5
  "main": "dist/plugin.cjs.js",
6
6
  "module": "dist/esm/index.js",