Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alternative design for "waiting for media..." state #2858

Draft
wants to merge 100 commits into
base: livekit
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
100 commits
Select commit Hold shift + click to select a range
5f8809c
make tiles based on rtc member
toger5 Oct 30, 2024
3f233a6
display missing lk participant + fix tile multiplier
toger5 Oct 30, 2024
34e9e8a
add show_non_member_participants config option
toger5 Oct 30, 2024
e1e202d
per member tiles
toger5 Nov 4, 2024
2a5dc60
merge fixes
toger5 Nov 4, 2024
1ab4d50
linter
toger5 Nov 4, 2024
14919ca
linter and tests
toger5 Nov 4, 2024
b5208ff
tests
toger5 Nov 5, 2024
e64204d
adapt tests (wip)
toger5 Nov 5, 2024
bb0febf
Remove unused keys
hughns Nov 5, 2024
e7dbddb
Fix optionality of nonMemberItemCount
hughns Nov 6, 2024
0d1b54e
video is optional
hughns Nov 6, 2024
fecd789
Mock RTC members
hughns Nov 6, 2024
733b685
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 6, 2024
c829f2f
Lint
hughns Nov 6, 2024
73107e4
Merge fixes
hughns Nov 6, 2024
bcbdb59
Fix user id
hughns Nov 6, 2024
b0e0e0e
Add explicit types for public fields
hughns Nov 6, 2024
a1083f3
isRTCParticipantAvailable => isLiveKitParticipantAvailable
hughns Nov 6, 2024
5213636
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 6, 2024
2c3d733
isLiveKitParticipantAvailable
hughns Nov 6, 2024
d8d4e89
Readonly
hughns Nov 6, 2024
efee27a
More keys removal
hughns Nov 6, 2024
eec4470
Make local field based on view model class not observable
hughns Nov 6, 2024
b1798e7
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 6, 2024
462f034
Wording
hughns Nov 6, 2024
efe9c9b
Fix RTC members in tes
hughns Nov 6, 2024
4f6b1b0
Tests again
hughns Nov 6, 2024
59e49d5
Lint
hughns Nov 6, 2024
f9f8f37
Disable showing non-member tiles by default
hughns Nov 6, 2024
dfd7273
Duplicate screen sharing tiles like we used to
hughns Nov 7, 2024
e515359
Lint
hughns Nov 7, 2024
9bfd2e3
Revert function reordering
hughns Nov 7, 2024
0760796
Remove throttleTime from bad merge
hughns Nov 7, 2024
95effe0
Cleanup
hughns Nov 7, 2024
6bda895
Tidy config of show non-member settings
hughns Nov 7, 2024
5e8a947
tidy up handling of local rtc member in tests
hughns Nov 7, 2024
bb56f42
tidy up test init
hughns Nov 7, 2024
5da642b
Fix mocks
hughns Nov 7, 2024
bf41cfc
Cleanup
hughns Nov 7, 2024
0c4cddb
Apply local override where participant not yet known
hughns Nov 7, 2024
be250e2
Handle no visible media id
hughns Nov 7, 2024
5009f1f
Assertions for one-on-one view
hughns Nov 7, 2024
238797a
Remove isLiveKitParticipantAvailable and show via encryption status
hughns Nov 7, 2024
c37c2e5
Handle no local media (yet)
hughns Nov 7, 2024
190ac9b
Remove unused effect for setting
hughns Nov 7, 2024
cf3893b
Tidy settings
hughns Nov 7, 2024
886dc2c
Avoid case of one-to-one layout with missing local or remote
hughns Nov 8, 2024
02b96fa
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 11, 2024
dbbf774
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 13, 2024
8351421
Iterate
hughns Nov 13, 2024
44935ee
Remove option to show non-member tiles to simplify code review
hughns Nov 13, 2024
b3e725f
Remove unused code
hughns Nov 13, 2024
87c3793
Remove more remnants of show-non-member-tiles
hughns Nov 14, 2024
fa3c9fd
iterate
hughns Nov 14, 2024
eafd8fd
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 14, 2024
f6a641b
back
hughns Nov 14, 2024
5cae849
Fix unit test
hughns Nov 18, 2024
09de976
Refactor
hughns Nov 18, 2024
23579b2
Expose TestScheduler as global
hughns Nov 18, 2024
8f59f08
Fix incorrect type assertion
hughns Nov 20, 2024
256a65a
Simplify speaking observer
hughns Nov 20, 2024
67a9d58
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 20, 2024
edb53ae
Fix
hughns Nov 20, 2024
3cb5ecc
Whitespace
hughns Nov 20, 2024
138a6c7
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 20, 2024
7677514
Make it clear that we are mocking MatrixRTC memberships
hughns Nov 20, 2024
b7ecd39
Test case for only showing tiles for MatrixRTC session members
hughns Nov 20, 2024
18e7ca5
Simplify diff
hughns Nov 20, 2024
a63d44a
Simplify diff
hughns Nov 20, 2024
1c04d22
.
hughns Nov 20, 2024
3f11f51
Whitespaces
hughns Nov 20, 2024
bc90deb
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 20, 2024
8f62cb6
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 21, 2024
ee8038f
Use asObservable when exposing subject
hughns Nov 21, 2024
e0651c5
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 23, 2024
b819a72
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Nov 25, 2024
4f2591f
Show "waiting for media..." when no participant
hughns Nov 25, 2024
16666b8
Additional test case
hughns Nov 25, 2024
8f9bee7
Don't show "waiting for media..." in case of local participant
hughns Nov 25, 2024
765f7b4
Make the loading state more subtle
toger5 Nov 26, 2024
52cb393
Use correct key for matrix rtc foci in code comment. (#2838)
toger5 Nov 27, 2024
cc1f0d5
Update src/tile/SpotlightTile.tsx
hughns Nov 27, 2024
133dc26
Update src/state/CallViewModel.ts
hughns Nov 27, 2024
743638d
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Dec 2, 2024
3d0bfae
Make the purpose of BaseMediaViewModel.local explicit
hughns Dec 2, 2024
968de5e
Use named object instead of unnamed array for spotlightAndPip
hughns Dec 2, 2024
33f398d
Refactor spotlightAndPip into spotlight and pip
hughns Dec 2, 2024
7fdcbb3
Use if statement instead of ternary for readability in spotlight and …
hughns Dec 2, 2024
370d8bd
Review feedback
hughns Dec 2, 2024
a37e8fd
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Dec 2, 2024
70deaf0
Fix tests for CallEventAudioRenderer
hughns Dec 2, 2024
79ea8d9
Merge branch 'livekit' into toger5/tiles_based_on_rtc_member
hughns Dec 2, 2024
e4087b2
Lint
hughns Dec 2, 2024
40526cb
Developer setting to show non-member tiles
hughns Nov 13, 2024
d1e9093
Lint
hughns Dec 2, 2024
820ac7f
Make the loading state more subtle
toger5 Nov 26, 2024
d1c8ac1
Merge branch 'livekit' into toger5/loading_border
hughns Dec 6, 2024
5a1a1a7
Remove changes that should be in https://github.com/element-hq/elemen…
hughns Dec 6, 2024
93710ff
Remove unused code
hughns Dec 6, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 33 additions & 1 deletion src/tile/GridTile.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ borders don't support gradients */
position: absolute;
z-index: -1; /* Put it below the outline */
opacity: 0; /* Hidden unless speaking */
transition: opacity ease 0.15s;
/* this only animates in one direction. In the other direction,
the background will disappear and the opacity has no effect.*/
transition: opacity ease 0.5s;
inset: calc(-1 * var(--cpd-border-width-4));
border-radius: var(--cpd-space-5x);
background-blend-mode: overlay, normal;
Expand Down Expand Up @@ -48,6 +50,11 @@ borders don't support gradients */
outline: var(--cpd-border-width-2) solid var(--cpd-color-bg-canvas-default) !important;
}

.tile.loading {
/* !important because loading border should take priority over hover */
outline: var(--cpd-border-width-2) solid var(--cpd-color-bg-canvas-default) !important;
}

.tile.handRaised::before {
background: linear-gradient(
119deg,
Expand All @@ -62,6 +69,31 @@ borders don't support gradients */
opacity: 1;
}

.tile.loading::before {
background: linear-gradient(
var(--angle),
var(--cpd-color-green-900) 0%,
var(--cpd-color-blue-200) 100%
);
opacity: 1;
animation: rotate-gradient linear 2s infinite;
}

@property --angle {
syntax: "<angle>";
inherits: false;
initial-value: 0deg;
}

@keyframes rotate-gradient {
from {
--angle: 0deg;
}
to {
--angle: 360deg;
}
}

@media (hover: hover) {
.tile:hover {
outline: var(--cpd-border-width-2) solid
Expand Down
3 changes: 3 additions & 0 deletions src/tile/GridTile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ import {
useDisplayName,
LocalUserMediaViewModel,
RemoteUserMediaViewModel,
EncryptionStatus,
} from "../state/MediaViewModel";
import { Slider } from "../Slider";
import { MediaView } from "./MediaView";
Expand Down Expand Up @@ -145,6 +146,8 @@ const UserMediaTile = forwardRef<HTMLDivElement, UserMediaTileProps>(
className={classNames(className, styles.tile, {
[styles.speaking]: showSpeaking,
[styles.handRaised]: !showSpeaking && !!handRaised,
[styles.loading]:
encryptionStatus === EncryptionStatus.Connecting && !vm.local,
})}
nameTagLeadingIcon={
<AudioIcon
Expand Down
Loading