You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,6 +11,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
11
11
12
12
### Added
13
13
14
+
- Added support for multiple content shares in meetings through the `ContentShareProvider`. The provider now accepts a `maxContentShares` prop (default: 1, range 1-2) to specify the maximum number of concurrent content shares allowed.
15
+
- Added new collections in `ContentShareState` to track multiple content shares: `tiles`, `tileIdToAttendeeId`, and `attendeeIdToTileId`.
16
+
- Added optional `tileId` prop to the `ContentShare` component to specify which content share to render.
17
+
- Added `canStartContentShare` state to control when content sharing is allowed based on the current number of shares and configured maximum.
18
+
- Maintained backward compatibility by keeping `tileId` and `sharingAttendeeId` properties, which now point to the most recently started content share when multiple shares are present.
Copy file name to clipboardExpand all lines: src/components/sdk/ContentShare/ContentShare.mdx
+66-3Lines changed: 66 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,12 +5,16 @@ import { ContentShare } from './';
5
5
6
6
# ContentShare
7
7
8
-
The `ContentShare` component renders a `ContentTile` for the active content share video, remote or local.
8
+
The `ContentShare` component renders a `ContentTile` for a content share video, remote or local.
9
9
10
10
If used within the `VideoGrid` component, it will automatically place the active tile in the featured grid slot. It takes precedence over the featured video tile.
11
11
12
12
Once a meeting session has been started, a user can start and stop content sharing by using the `useContentShareControls` hook.
13
13
14
+
## Multiple Content Shares
15
+
16
+
With the support for multiple content shares, you can now specify which content share tile to render by providing the `tileId` prop. If no `tileId` is provided, the component will render the default content share tile from (`const { tileId } = useContentShareState()`).
17
+
14
18
## Importing
15
19
16
20
```javascript
@@ -19,26 +23,85 @@ import { ContentShare } from 'amazon-chime-sdk-component-library-react';
If you opt out of using `MeetingProvider`, you can drop in a `ContentShareProvider` and use its state. Make sure that its dependencies are rendered higher in the tree.
0 commit comments