added Legacy keyword in front of theme names

GitOrigin-RevId: 67153578ba1cdfcc2df45caf4dee185644ec1021
This commit is contained in:
Davinder Singh 2023-08-25 14:43:06 +01:00 committed by Copybot
parent 0ae6adb4d6
commit acad014cc9
2 changed files with 4 additions and 2 deletions

View file

@ -30,7 +30,7 @@ export default function SettingsEditorTheme() {
const legacyEditorThemeOptions: Array<Option> =
legacyEditorThemes?.map(theme => ({
value: theme,
label: theme.replace(/_/g, ' '),
label: theme.replace(/_/g, ' ') + ' (Legacy)',
})) ?? []
return [...editorThemeOptions, dividerOption, ...legacyEditorThemeOptions]

View file

@ -30,7 +30,9 @@ describe('<SettingsEditorTheme />', function () {
}
for (const theme of legacyEditorThemes) {
const option = within(select).getByText(theme.replace(/_/g, ' '))
const option = within(select).getByText(
theme.replace(/_/g, ' ') + ' (Legacy)'
)
expect(option.getAttribute('value')).to.equal(theme)
}
})