Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions webview-ui/src/components/modes/ModesView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1166,6 +1166,15 @@ const ModesView = ({ onDone }: ModesViewProps) => {
}}
/>
),
"0": (
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding aria-label attributes to these VSCodeLink components for better accessibility. This helps screen reader users understand what these documentation links are for.

For example:
<VSCodeLink
href={buildDocLink(...)}
style={{ display: "inline" }}
aria-label="Learn about global custom instructions for modes"
/>

<VSCodeLink
href={buildDocLink(
"features/custom-instructions#global-custom-instructions",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it intentional that both the mode-specific and global custom instructions sections link to the same documentation anchor (features/custom-instructions#global-custom-instructions)?

The mode-specific section (line 1172) might benefit from a different anchor that explains the relationship between workspace and global rules specifically for modes, rather than pointing to the general global instructions section.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could use either of these links for both mode-specific and general rules as they cover how to set up both globally: https://docs.roocode.com/features/custom-instructions#global-rules-directory
https://docs.roocode.com/features/custom-instructions#setting-up-global-rules

"prompts_mode_custom_instructions_global",
)}
style={{ display: "inline" }}
/>
),
}}
/>
</div>
Expand Down Expand Up @@ -1352,6 +1361,15 @@ const ModesView = ({ onDone }: ModesViewProps) => {
}
/>
),
"0": (
<VSCodeLink
href={buildDocLink(
"features/custom-instructions#global-custom-instructions",
"prompts_global_custom_instructions_global",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The UTM campaign parameters are different between the two links:

  • Line 1172: prompts_mode_custom_instructions_global
  • Line 1368: prompts_global_custom_instructions_global

While this is good for tracking, consider if the naming could be clearer. For example:

  • prompts_mode_specific_global_rules
  • prompts_global_rules

This would make it more obvious what each link is tracking.

)}
style={{ display: "inline" }}
/>
),
}}
/>
</div>
Expand Down
4 changes: 2 additions & 2 deletions webview-ui/src/i18n/locales/en/prompts.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"title": "Mode-specific Custom Instructions (optional)",
"resetToDefault": "Reset to default",
"description": "Add behavioral guidelines specific to {{modeName}} mode.",
"loadFromFile": "Custom instructions specific to {{mode}} mode can also be loaded from the <span>.roo/rules-{{slug}}/</span> folder in your workspace (.roorules-{{slug}} and .clinerules-{{slug}} are deprecated and will stop working soon)."
"loadFromFile": "Custom instructions specific to {{mode}} mode can also be loaded from the <span>.roo/rules-{{slug}}/</span> folder in your workspace or from the global <0>.roo/rules-{{slug}}/</0> (.roorules-{{slug}} and .clinerules-{{slug}} are deprecated and will stop working soon)."
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Critical issue: This PR only updates the English translation file, but there are 17 other language files that need the same update. Without updating them, non-English users will see missing translation keys.

All translation files need the new "0" placeholder added to both customInstructions.loadFromFile (line 53) and globalCustomInstructions.loadFromFile (line 79).

Affected files:

  • locales/*/prompts.json (ca, de, es, fr, hi, id, it, ja, ko, nl, pl, pt-BR, ru, tr, vi, zh-CN, zh-TW)

},
"exportMode": {
"title": "Export Mode",
Expand All @@ -76,7 +76,7 @@
"globalCustomInstructions": {
"title": "Custom Instructions for All Modes",
"description": "These instructions apply to all modes. They provide a base set of behaviors that can be enhanced by mode-specific instructions below. <0>Learn more</0>",
"loadFromFile": "Instructions can also be loaded from the <span>.roo/rules/</span> folder in your workspace (.roorules and .clinerules are deprecated and will stop working soon)."
"loadFromFile": "Instructions can also be loaded from the <span>.roo/rules/</span> folder in your workspace or from the global <0>.roo/rules/</0> (.roorules and .clinerules are deprecated and will stop working soon)."
},
"systemPrompt": {
"preview": "Preview System Prompt",
Expand Down
Loading