Skip to content

Composite option to hide local screen share stream #5699

Merged
carocao-msft merged 4 commits intomainfrom
carocao/screenshare
Mar 12, 2025
Merged

Composite option to hide local screen share stream #5699
carocao-msft merged 4 commits intomainfrom
carocao/screenshare

Conversation

@carocao-msft
Copy link
Copy Markdown
Contributor

What

Composite option to hide local screen share stream

Why

How Tested

Process & policy checklist

  • I have updated the project documentation to reflect my changes if necessary.
  • I have read the CONTRIBUTING documentation.

Is this a breaking change?

  • This change causes current functionality to break.

@github-actions
Copy link
Copy Markdown
Contributor

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 12, 2025

@azure/communication-react jest test coverage for stable.

Lines Statements Functions Branches
Base 28021 / 44684
62.7%
28021 / 44684
62.7%
786 / 1436
54.73%
2346 / 3716
63.13%
Current 28142 / 44712
62.94%
28142 / 44712
62.94%
788 / 1438
54.79%
2350 / 3722
63.13%
Diff 121 / 28
0.24%
121 / 28
0.24%
2 / 2
0.06%
4 / 6
0%

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 12, 2025

@azure/communication-react jest test coverage for beta.

Lines Statements Functions Branches
Base 58337 / 94332
61.84%
58337 / 94332
61.84%
1178 / 2695
43.71%
3553 / 5836
60.88%
Current 58404 / 94388
61.87%
58404 / 94388
61.87%
1180 / 2697
43.75%
3499 / 5808
60.24%
Diff 67 / 56
0.03%
67 / 56
0.03%
2 / 2
0.04%
-54 / -28
-0.64%

joinCallOptions?: {
microphoneCheck?: 'requireMicrophoneAvailable' | 'skip';
};
hideLocalScreenShareStream?: boolean;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you move this inside the existing galleryOptions?

Copy link
Copy Markdown
Member

@JamesBurnside JamesBurnside Mar 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoid booleans, change to something like localScreenshareView: { 'stream' | 'placeholderMessage' } (open to better naming!)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the movement of this as well to gallery options

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Customers understand what the default behaviour is and understand they want to be a little special so they are willing to do this additional change if they want it. It's ok to not have this API on the top level. This is a good discussion as we should be thinking where should these APIs exist.

if (!localParticipant || !localParticipant.isScreenSharingOn) {
return null;
}
const localScreenSharingNotification = (
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We use notification to means that ufd alert UI, is the same UI or the old UI were the tile shows placeholder text and icon?
If its the same we should be using the notification component, if its the old UI change the naming here

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the old UI. I just brought back the code changes removed before when changing to show local video stream. What should the name be?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your choice, but notification is now a different component we ship so we should avoid that, one option would be localScreenSharingPlaceholder

Copy link
Copy Markdown
Member

@dmceachernmsft dmceachernmsft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should also write some e2e tests that meet this scenario as well.

joinCallOptions?: {
microphoneCheck?: 'requireMicrophoneAvailable' | 'skip';
};
hideLocalScreenShareStream?: boolean;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the movement of this as well to gallery options

onCreateLocalStreamView,
onDisposeLocalScreenShareStreamView
onDisposeLocalScreenShareStreamView,
hideLocalScreenShareStream
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if we are specifying there is a default in the JSdocs we should make sure we are setting that here in the code as well instead of relying on undefined.

@github-actions
Copy link
Copy Markdown
Contributor

@carocao-msft carocao-msft enabled auto-merge (squash) March 12, 2025 21:51
@github-actions
Copy link
Copy Markdown
Contributor

Calling bundle size is not changed.

  • Current size: 12401036
  • Base size: 12401036
  • Diff size: 0

@github-actions
Copy link
Copy Markdown
Contributor

CallWithChat bundle size is not changed.

  • Current size: 12401048
  • Base size: 12401048
  • Diff size: 0

@github-actions
Copy link
Copy Markdown
Contributor

Chat bundle size is not changed.

  • Current size: 1775142
  • Base size: 1775142
  • Diff size: 0

@github-actions
Copy link
Copy Markdown
Contributor

@carocao-msft carocao-msft merged commit 57a7c04 into main Mar 12, 2025
@carocao-msft carocao-msft deleted the carocao/screenshare branch March 12, 2025 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants