diff --git a/lib/models/video_detail_res.dart b/lib/models/video_detail_res.dart index 8d67d56b..37c84bb8 100644 --- a/lib/models/video_detail_res.dart +++ b/lib/models/video_detail_res.dart @@ -291,6 +291,7 @@ class Staff { String? name; String? face; Vip? vip; + Map? official; Staff({ this.mid, @@ -306,6 +307,7 @@ class Staff { name = json["name"]; face = json["face"]; vip = json["vip"] == null ? null : Vip.fromJson(json["vip"]); + official = json['official']; } } diff --git a/lib/pages/video/detail/introduction/view.dart b/lib/pages/video/detail/introduction/view.dart index f9b40e03..de604d09 100644 --- a/lib/pages/video/detail/introduction/view.dart +++ b/lib/pages/video/detail/introduction/view.dart @@ -223,6 +223,7 @@ class _VideoInfoState extends State with TickerProviderStateMixin { @override void initState() { super.initState(); + videoDetailCtr = Get.find(tag: widget.heroTag); if (videoIntroController.expandableCtr == null) { @@ -461,13 +462,47 @@ class _VideoInfoState extends State with TickerProviderStateMixin { }, child: Row( children: [ - NetworkImgLayer( - type: 'avatar', - src: videoItem['staff'][index].face, - width: 35, - height: 35, - fadeInDuration: Duration.zero, - fadeOutDuration: Duration.zero, + Stack( + clipBehavior: Clip.none, + children: [ + NetworkImgLayer( + type: 'avatar', + src: videoItem['staff'][index] + .face, + width: 35, + height: 35, + fadeInDuration: Duration.zero, + fadeOutDuration: Duration.zero, + ), + if ((videoItem['staff'][index] + .official?['type'] ?? + -1) != + -1) + Positioned( + right: -2, + bottom: -2, + child: Container( + decoration: BoxDecoration( + shape: BoxShape.circle, + color: Theme.of(context) + .colorScheme + .surface, + ), + child: Icon( + Icons.offline_bolt, + color: videoItem['staff'] + [index] + .official?[ + 'type'] == + 0 + ? Colors.yellow + : Colors + .lightBlueAccent, + size: 14, + ), + ), + ), + ], ), const SizedBox(width: 8), Column(