feat: 原网页查看专栏

This commit is contained in:
guozhigq
2024-10-03 16:30:47 +08:00
parent dd363e3cda
commit 2a436cfcfc
6 changed files with 37 additions and 18 deletions

View File

@ -22,6 +22,7 @@ class ReadPageController extends GetxController {
title.value = Get.parameters['title'] ?? '';
id = Get.parameters['id']!;
articleType = Get.parameters['articleType']!;
url = 'https://www.bilibili.com/read/cv$id';
scrollController.addListener(_scrollListener);
fetchViewInfo();
}
@ -85,6 +86,15 @@ class ReadPageController extends GetxController {
ReadHttp.getViewInfo(id: id);
}
// 跳转webview
void onJumpWebview() {
Get.toNamed('/webview', parameters: {
'url': url,
'type': 'webview',
'pageTitle': title.value,
});
}
@override
void onClose() {
scrollController.removeListener(_scrollListener);