feat: stream cards

closes #21
This commit is contained in:
2025-05-14 13:46:14 +01:00
parent eefbbc2f73
commit 465c6f222e
6 changed files with 130 additions and 7 deletions

View File

@ -10,6 +10,7 @@ import 'package:zap_stream_flutter/utils.dart';
import 'package:zap_stream_flutter/widgets/avatar.dart';
import 'package:zap_stream_flutter/widgets/button.dart';
import 'package:zap_stream_flutter/widgets/header.dart';
import 'package:zap_stream_flutter/widgets/nostr_text.dart';
import 'package:zap_stream_flutter/widgets/profile.dart';
import 'package:zap_stream_flutter/widgets/stream_grid.dart';
@ -53,9 +54,15 @@ class ProfilePage extends StatelessWidget {
fontWeight: FontWeight.w600,
),
),
Text(
profile.about ?? "",
style: TextStyle(color: LAYER_5),
Text.rich(
TextSpan(
style: TextStyle(color: LAYER_5),
children: textToSpans(
profile.about ?? "",
[],
profile.pubKey,
),
),
),
],
),

View File

@ -101,7 +101,10 @@ class _StreamPage extends State<StreamPage> {
aspectRatio: 16 / 9,
child:
_chewieController != null
? Chewie(controller: _chewieController!)
? Chewie(
key: Key("stream:player:${stream.aTag}"),
controller: _chewieController!,
)
: Container(
color: LAYER_1,
child:
@ -163,9 +166,8 @@ class _StreamPage extends State<StreamPage> {
),
GestureDetector(
onTap: () {
showModalBottomSheet(
showBottomSheet(
context: context,
constraints: BoxConstraints.expand(),
builder: (context) => StreamInfoWidget(stream: stream),
);
},