This commit is contained in:
guozhigq
2024-12-11 23:08:04 +08:00
parent 470e70be2b
commit 9a20f246d3
8 changed files with 14 additions and 17 deletions

View File

@ -59,7 +59,7 @@ class HtmlRender extends StatelessWidget {
imgUrl = imgUrl.replaceAll('http://', 'https://'); imgUrl = imgUrl.replaceAll('http://', 'https://');
} }
imgUrl = imgUrl.contains('@') ? imgUrl.split('@').first : imgUrl; imgUrl = imgUrl.contains('@') ? imgUrl.split('@').first : imgUrl;
final bool isEmote = imgUrl.contains('/emote/'); // final bool isEmote = imgUrl.contains('/emote/');
final bool isMall = imgUrl.contains('/mall/'); final bool isMall = imgUrl.contains('/mall/');
if (isMall) { if (isMall) {
return const SizedBox(); return const SizedBox();

View File

@ -22,10 +22,10 @@ import 'controller.dart';
import 'widgets/intro_detail.dart'; import 'widgets/intro_detail.dart';
class BangumiIntroPanel extends StatefulWidget { class BangumiIntroPanel extends StatefulWidget {
final int? cid; final int cid;
const BangumiIntroPanel({ const BangumiIntroPanel({
Key? key, Key? key,
this.cid, required this.cid,
}) : super(key: key); }) : super(key: key);
@override @override
@ -49,7 +49,7 @@ class _BangumiIntroPanelState extends State<BangumiIntroPanel>
void initState() { void initState() {
super.initState(); super.initState();
heroTag = Get.arguments['heroTag']; heroTag = Get.arguments['heroTag'];
cid = widget.cid!; cid = widget.cid;
bangumiIntroController = Get.put(BangumiIntroController(), tag: heroTag); bangumiIntroController = Get.put(BangumiIntroController(), tag: heroTag);
videoDetailCtr = Get.find<VideoDetailController>(tag: heroTag); videoDetailCtr = Get.find<VideoDetailController>(tag: heroTag);
_futureBuilderFuture = bangumiIntroController.queryBangumiIntro(); _futureBuilderFuture = bangumiIntroController.queryBangumiIntro();
@ -103,11 +103,11 @@ class BangumiInfo extends StatefulWidget {
const BangumiInfo({ const BangumiInfo({
super.key, super.key,
this.bangumiDetail, this.bangumiDetail,
this.cid, required this.cid,
}); });
final BangumiInfoModel? bangumiDetail; final BangumiInfoModel? bangumiDetail;
final int? cid; final int cid;
@override @override
State<BangumiInfo> createState() => _BangumiInfoState(); State<BangumiInfo> createState() => _BangumiInfoState();
@ -119,7 +119,7 @@ class _BangumiInfoState extends State<BangumiInfo> {
late final VideoDetailController videoDetailCtr; late final VideoDetailController videoDetailCtr;
Box localCache = GStorage.localCache; Box localCache = GStorage.localCache;
late double sheetHeight; late double sheetHeight;
int? cid; late int cid;
bool isProcessing = false; bool isProcessing = false;
void Function()? handleState(Future Function() action) { void Function()? handleState(Future Function() action) {
return isProcessing return isProcessing
@ -137,7 +137,7 @@ class _BangumiInfoState extends State<BangumiInfo> {
bangumiIntroController = Get.put(BangumiIntroController(), tag: heroTag); bangumiIntroController = Get.put(BangumiIntroController(), tag: heroTag);
videoDetailCtr = Get.find<VideoDetailController>(tag: heroTag); videoDetailCtr = Get.find<VideoDetailController>(tag: heroTag);
sheetHeight = localCache.get('sheetHeight'); sheetHeight = localCache.get('sheetHeight');
cid = widget.cid!; cid = widget.cid;
videoDetailCtr.cid.listen((p0) { videoDetailCtr.cid.listen((p0) {
cid = p0; cid = p0;
if (!mounted) { if (!mounted) {
@ -313,7 +313,7 @@ class _BangumiInfoState extends State<BangumiInfo> {
if (widget.bangumiDetail!.episodes!.isNotEmpty) ...[ if (widget.bangumiDetail!.episodes!.isNotEmpty) ...[
BangumiPanel( BangumiPanel(
pages: widget.bangumiDetail!.episodes!, pages: widget.bangumiDetail!.episodes!,
cid: cid! ?? widget.bangumiDetail!.episodes!.first.cid!, cid: cid,
sheetHeight: sheetHeight, sheetHeight: sheetHeight,
changeFuc: (bvid, cid, aid, cover) => bangumiIntroController changeFuc: (bvid, cid, aid, cover) => bangumiIntroController
.changeSeasonOrbangu(bvid, cid, aid, cover), .changeSeasonOrbangu(bvid, cid, aid, cover),

View File

@ -47,7 +47,7 @@ class FollowItem extends StatelessWidget {
height: 34, height: 34,
child: TextButton( child: TextButton(
onPressed: () async { onPressed: () async {
int followStatus = await FollowUtils( await FollowUtils(
context: context, context: context,
followStatus: 2, followStatus: 2,
mid: item.mid!, mid: item.mid!,

View File

@ -1,6 +1,7 @@
import 'package:easy_debounce/easy_throttle.dart'; import 'package:easy_debounce/easy_throttle.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:get/get.dart'; import 'package:get/get.dart';
import 'package:pilipala/common/widgets/no_data.dart';
import 'package:pilipala/pages/member_dynamics/index.dart'; import 'package:pilipala/pages/member_dynamics/index.dart';
import 'package:pilipala/utils/utils.dart'; import 'package:pilipala/utils/utils.dart';
@ -82,7 +83,7 @@ class _MemberDynamicsPageState extends State<MemberDynamicsPage> {
childCount: list.length, childCount: list.length,
), ),
) )
: const SliverToBoxAdapter(), : const NoData(),
); );
} else { } else {
return HttpError( return HttpError(

View File

@ -18,7 +18,6 @@ import 'package:pilipala/models/video_detail_res.dart';
import 'package:pilipala/pages/video/detail/introduction/controller.dart'; import 'package:pilipala/pages/video/detail/introduction/controller.dart';
import 'package:pilipala/pages/video/detail/widgets/ai_detail.dart'; import 'package:pilipala/pages/video/detail/widgets/ai_detail.dart';
import 'package:pilipala/utils/feed_back.dart'; import 'package:pilipala/utils/feed_back.dart';
import 'package:pilipala/utils/follow.dart';
import 'package:pilipala/utils/global_data_cache.dart'; import 'package:pilipala/utils/global_data_cache.dart';
import 'package:pilipala/utils/storage.dart'; import 'package:pilipala/utils/storage.dart';
import 'package:pilipala/utils/utils.dart'; import 'package:pilipala/utils/utils.dart';

View File

@ -32,7 +32,6 @@ import 'package:status_bar_control/status_bar_control.dart';
import '../../../plugin/pl_player/models/bottom_control_type.dart'; import '../../../plugin/pl_player/models/bottom_control_type.dart';
import '../../../services/shutdown_timer_service.dart'; import '../../../services/shutdown_timer_service.dart';
import 'widgets/app_bar.dart'; import 'widgets/app_bar.dart';
import 'widgets/header_control.dart';
class VideoDetailPage extends StatefulWidget { class VideoDetailPage extends StatefulWidget {
const VideoDetailPage({Key? key}) : super(key: key); const VideoDetailPage({Key? key}) : super(key: key);

View File

@ -59,11 +59,11 @@ class ChatItem extends StatelessWidget {
bool isOwner = item.senderUid == GStorage.userInfo.get('userInfoCache').mid; bool isOwner = item.senderUid == GStorage.userInfo.get('userInfoCache').mid;
bool isPic = item.msgType == MsgType.pic.value; // 图片 bool isPic = item.msgType == MsgType.pic.value; // 图片
bool isText = item.msgType == MsgType.text.value; // 文本 // bool isText = item.msgType == MsgType.text.value; // 文本
// bool isArchive = item.msgType == 11; // 投稿 // bool isArchive = item.msgType == 11; // 投稿
// bool isArticle = item.msgType == 12; // 专栏 // bool isArticle = item.msgType == 12; // 专栏
bool isRevoke = item.msgType == MsgType.revoke.value; // 撤回消息 bool isRevoke = item.msgType == MsgType.revoke.value; // 撤回消息
bool isShareV2 = item.msgType == MsgType.share_v2.value; // bool isShareV2 = item.msgType == MsgType.share_v2.value;
bool isSystem = item.msgType == MsgType.notify_text.value || bool isSystem = item.msgType == MsgType.notify_text.value ||
item.msgType == MsgType.notify_msg.value || item.msgType == MsgType.notify_msg.value ||
item.msgType == MsgType.pic_card.value || item.msgType == MsgType.pic_card.value ||

View File

@ -1,5 +1,3 @@
import 'dart:math';
import 'storage.dart'; import 'storage.dart';
class RecommendFilter { class RecommendFilter {