perf: 更新程序界面代码

更新英语翻译
This commit is contained in:
JoeanAmier
2024-12-28 22:58:11 +08:00
parent 13707c425a
commit 102e7adbd4
7 changed files with 66 additions and 25 deletions

View File

@@ -39,11 +39,16 @@ class About(Screen):
def compose(self) -> ComposeResult:
yield Header()
yield Label(Text(_("如果 XHS-Downloader 对您有帮助,请考虑为它点个 Star感谢您的支持"), style=INFO),
classes="prompt", )
yield Label(
Text(
_("如果 XHS-Downloader 对您有帮助,请考虑为它点个 Star感谢您的支持"),
style=INFO,
),
classes="prompt",
)
yield Label(Text(_("Discord 社区"), style=PROMPT), classes="prompt", )
yield Link(
f"{_("邀请链接:")}https://discord.com/invite/ZYtmgKud9Y",
_("邀请链接:") + "https://discord.com/invite/ZYtmgKud9Y",
url="https://discord.com/invite/ZYtmgKud9Y",
tooltip=_("点击访问"),
)

View File

@@ -74,7 +74,7 @@ class XHSDownloader(App):
await self.push_screen("setting", save_settings)
async def refresh_screen(self):
self.pop_screen()
await self.pop_screen()
await self.close_database()
await self.APP.close()
self.__initialization()

View File

@@ -53,12 +53,12 @@ class Index(Screen):
yield ScrollableContainer(
Label(
Text(
f"{_("开源协议")}: {LICENCE}",
_("开源协议: ") + LICENCE,
style=MASTER)
),
Link(
Text(
f"{_("项目地址")}{REPOSITORY}",
_("项目地址: ") + REPOSITORY,
style=MASTER,
),
url=REPOSITORY,
@@ -130,7 +130,7 @@ class Index(Screen):
Text(">" * 50, style=GENERAL),
animate=True,
)
self.app.pop_screen()
await self.app.pop_screen()
async def action_quit(self) -> None:
await self.app.action_quit()