feat: add placeholder for kling AccessKey and SecretKey - #1279
Conversation
WalkthroughA new case for the value Changes
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (2)
web/src/pages/Channel/EditChannel.js (2)
67-68: Inconsistent colon style in prompt string
Other cases use a fullwidth Chinese colon (:) without a space. For consistency, update to:-case 50: - return '按照如下格式输入: AccessKey|SecretKey'; +case 50: + return '按照如下格式输入:AccessKey|SecretKey';
54-72: Consider using translation keys instead of hardcoded phrases
Refactortype2secretPromptto return i18n keys (e.g.'channel.prompt.kling_keys') and move the actual Chinese strings into your locale JSON. This will improve maintainability and enable easy localization.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
web/src/pages/Channel/EditChannel.js(1 hunks)
🔇 Additional comments (2)
web/src/pages/Channel/EditChannel.js (2)
67-68: New placeholder case implemented correctly
The addedcase 50returns the intendedAccessKey|SecretKeyprompt, fulfilling the PR objective.
579-581: Ensure translation entry for dynamic prompt
Since you wrap the output oftype2secretPromptint(), add the new string'按照如下格式输入:AccessKey|SecretKey'to your i18n locale files. Otherwise,t()will simply return the key itself.
a0da83b to
e4def06
Compare
…aceholder feat: add placeholder for kling AccessKey and SecretKey
增加可灵密钥输入框placeholder
Summary by CodeRabbit
AccessKey|SecretKeyin the channel editing interface.|) separator for improved consistency and clarity.