feat(歌词): 增加自适应歌词字体大小模式 添加歌词字体大小自适应模式,可根据窗口高度自动缩放歌词大小,避免全屏时过小或窗口时过大。新增设置选项允许用户在固定大小和自适应模式之间切换,并更新了歌词预览和播放器组件以支持新的字体大小计算逻辑。#852
Conversation
添加歌词字体大小自适应模式,可根据窗口高度自动缩放歌词大小,避免全屏时过小或窗口时过大。新增设置选项允许用户在固定大小和自适应模式之间切换,并更新了歌词预览和播放器组件以支持新的字体大小计算逻辑。
Summary of ChangesHello @kazukokawagawa, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! 此拉取请求为歌词显示功能引入了一项重要增强,即增加了自适应字体大小模式。此模式可根据应用程序窗口的高度动态调整歌词文本,确保在全屏和窗口模式等各种窗口尺寸下都能获得最佳可读性。此外,它还包含对QRC歌词解析器的一项重要修复,提高了其正确解释和显示来自可能格式不正确的XML结构的歌词内容的能力。 Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
| const getFontSize = (size: number) => { | ||
| if (settingStore.lyricFontSizeMode === "adaptive") { | ||
| return `calc(${size} / 1080 * 100vh)`; | ||
| } | ||
| return `${size}px`; | ||
| }; |
将多个组件中重复的字体大小计算逻辑提取到统一的工具函数 getFontSize 中 该函数根据字体大小模式(自适应或固定)返回相应的 CSS 值
No description provided.