Skip to content

Conversation

@julien4215
Copy link
Collaborator

@julien4215 julien4215 commented Jun 29, 2024

recording.webm

@julien4215 julien4215 marked this pull request as draft June 30, 2024 13:04
@julien4215 julien4215 force-pushed the broadcast branch 4 times, most recently from 81163ad to 97c0086 Compare June 30, 2024 15:01
@julien4215 julien4215 marked this pull request as ready for review June 30, 2024 15:05
@veloce
Copy link
Contributor

veloce commented Jul 1, 2024

I'll review asap, in the meantime can you re-run the script to solve the conflicts? thanks!

@julien4215 julien4215 force-pushed the broadcast branch 4 times, most recently from e607562 to 96233d3 Compare July 8, 2024 09:26
Copy link
Contributor

@veloce veloce left a comment

Choose a reason for hiding this comment

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

Nice job! only have a couple of comment for now;

Can you send a screen recording showing the new list and pagination? thanks.

BroadcastRound? get curentRound =>
rounds.where((r) => r.status == RoundStatus.live).firstOrNull ??
rounds.where((r) => r.status == RoundStatus.finished).lastOrNull;
factory Broadcast.loading() => Broadcast(
Copy link
Contributor

Choose a reason for hiding this comment

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

Instead of that Broadcast.loading() that has empty name and id, is it possible to have a nullable broadcast field where the broadcast is not yet present?
I believe it is only used in BroadcastPicture for now, so it should be possible.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Where should the broadcast field be nullable ? In the BroadcastPicture ?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes, in order to not use the Broadcast.loading()

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

But why not keep it ? It is easier to create the shimmer like this.

I can also do it with defining a nullable broadcast field in the BroadcastPicture but I am not sure that this will make the code cleaner.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ok let's use a dummy Broadcast in the BroadcastPicture if it's easier, but don't define the factory constructor here; we don't want it to be used elsewhere.
Just construct the dummy one directly in the view (and you can use a const).

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I can't use a const because DateTime doesn't have a const constructor

@julien4215
Copy link
Collaborator Author

I added a delay of 5 seconds to the request in order to have time to see the loading behavior when reaching next page

const BroadcastPicture({super.key, required this.broadcast});
const BroadcastPicture({required this.broadcast});

BroadcastPicture.loading() : broadcast = Broadcast.loading();
Copy link
Contributor

Choose a reason for hiding this comment

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

It could use a const I think.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I can't because the value I assign to broadcast is not a const value due to the presence of Datetime in Broadcast

BroadcastRound? get curentRound =>
rounds.where((r) => r.status == RoundStatus.live).firstOrNull ??
rounds.where((r) => r.status == RoundStatus.finished).lastOrNull;
factory Broadcast.loading() => Broadcast(
Copy link
Contributor

Choose a reason for hiding this comment

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

Ok let's use a dummy Broadcast in the BroadcastPicture if it's easier, but don't define the factory constructor here; we don't want it to be used elsewhere.
Just construct the dummy one directly in the view (and you can use a const).

@veloce
Copy link
Contributor

veloce commented Jul 10, 2024

I added a delay of 5 seconds to the request in order to have time to see the loading behavior when reaching next page

5 seconds seems a lot. Can you try with 2 seconds?

@julien4215
Copy link
Collaborator Author

I added a delay of 5 seconds to the request in order to have time to see the loading behavior when reaching next page

5 seconds seems a lot. Can you try with 2 seconds?

I added it only for the video so we can see better what happens with the shimmer. Do you want me to record again with 2 seconds instead of 5 ?

@veloce
Copy link
Contributor

veloce commented Jul 10, 2024

I added a delay of 5 seconds to the request in order to have time to see the loading behavior when reaching next page

5 seconds seems a lot. Can you try with 2 seconds?

I added it only for the video so we can see better what happens with the shimmer. Do you want me to record again with 2 seconds instead of 5 ?

Ah ok I didn't get it was for the recording. No I thought an artificial delay was needed (it sometimes is) to avoid "blinking" due to shimmer loading. If that is the case I'd say 1-2s max is enough.

@ijm8710
Copy link

ijm8710 commented Jul 10, 2024

Hey guys, web has a row or two of smaller detail text below each of the larger tournament titles.

Seems like they're still experimenting with what to show on the tournament posters but these have included:
- tournaments' location
- tournament time control
- tournament dates
- list of players
- current round #/time until round starts

There is also a red icon that shows # of viewers

image

Would it make sense to have a list vs grid switcher (using images of Trakt apps implementation below for reference) so that you can alternate between 2 vs 1 title per row. With just 1 expanded title per row, at least some of that underlying detail can be shown. At least some of that detail is important context whereby I think I'd personally keep it at 1 title per row if given the option.

image
image

And secondly, do you think the viewer count in red (see very first photo above) is worth showing in the app as well?

Copy link
Contributor

@veloce veloce left a comment

Choose a reason for hiding this comment

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

We cannot open any tournament anymore, I think it is missing a server scope config.

Capture d’écran 2024-07-15 à 11 56 44

@julien4215
Copy link
Collaborator Author

We cannot open any tournament anymore, I think it is missing a server scope config.

I don't have this problem on my side

@veloce
Copy link
Contributor

veloce commented Jul 15, 2024

We cannot open any tournament anymore, I think it is missing a server scope config.

I don't have this problem on my side

It works as anonymous, but if I log in, it stops to work. Does it also work for you when you're logged in?

@julien4215
Copy link
Collaborator Author

It works as anonymous, but if I log in, it stops to work. Does it also work for you when you're logged in?

How can I try the broadcast feature on a local lila to be able to log in ? I think there is nothing to populate the database with broadcast.

@veloce veloce merged commit 67a7c69 into lichess-org:main Jul 15, 2024
@julien4215 julien4215 deleted the broadcast branch July 15, 2024 18:07
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.

3 participants