feat: support textbox themes on say dialogue#950
Open
A-kirami wants to merge 2 commits into
Open
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request introduces a textboxTheme property to the stage state, enabling dynamic dialogue box themes based on the speaker or explicit overrides. Key changes include the addition of a resolveDialogDisplayState utility function with unit tests, and updates to the UI components to support the new theme attribute. A review comment suggested simplifying the logic in the new utility function using more idiomatic TypeScript operators.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
为
say对话增加文本框主题能力,使文本框样式默认跟随说话人,并支持通过-theme=...在单句对话上覆盖样式。改动内容
textboxThemeresolveDialogDisplayState,集中处理对话显示态解析say默认根据speaker推导文本框主题-theme=...覆盖当前句的文本框主题clear默认同时清空显示名和文本框主题data-textbox-theme,供模板样式使用TextPreview的 props 以适配新增的主题状态使用示例