Improve styling of Add button

This commit is contained in:
James Brunton 2025-09-09 10:14:06 +01:00
parent e7cfb7045b
commit e6526bdb44
2 changed files with 5 additions and 5 deletions

View File

@ -1605,7 +1605,7 @@
"wordsToRedact": { "wordsToRedact": {
"title": "Words to Redact", "title": "Words to Redact",
"placeholder": "Enter a word", "placeholder": "Enter a word",
"addAnother": "Add Another", "add": "Add",
"examples": "Examples: Confidential, Top-Secret" "examples": "Examples: Confidential, Top-Secret"
}, },
"useRegexLabel": "Use Regex", "useRegexLabel": "Use Regex",

View File

@ -58,7 +58,7 @@ export default function WordsToRedactInput({ wordsToRedact, onWordsChange, disab
))} ))}
{/* Add new word input */} {/* Add new word input */}
<Stack gap="sm"> <Group gap="sm" align="end">
<TextInput <TextInput
placeholder={t('redact.auto.wordsToRedact.placeholder', 'Enter a word')} placeholder={t('redact.auto.wordsToRedact.placeholder', 'Enter a word')}
value={currentWord} value={currentWord}
@ -66,17 +66,17 @@ export default function WordsToRedactInput({ wordsToRedact, onWordsChange, disab
onKeyDown={handleKeyPress} onKeyDown={handleKeyPress}
disabled={disabled} disabled={disabled}
size="sm" size="sm"
style={{ flex: 1 }}
/> />
<Button <Button
size="sm" size="sm"
variant="light" variant="light"
onClick={addWord} onClick={addWord}
disabled={disabled || !currentWord.trim()} disabled={disabled || !currentWord.trim()}
style={{ alignSelf: 'flex-start' }}
> >
+ {t('redact.auto.wordsToRedact.addAnother', 'Add Another')} + {t('redact.auto.wordsToRedact.add', 'Add')}
</Button> </Button>
</Stack> </Group>
{/* Examples */} {/* Examples */}
{wordsToRedact.length === 0 && ( {wordsToRedact.length === 0 && (