diff --git a/webapp/packages/core-blocks/src/FormControls/Textarea.tsx b/webapp/packages/core-blocks/src/FormControls/Textarea.tsx index 98be7cace6..54ac67c211 100644 --- a/webapp/packages/core-blocks/src/FormControls/Textarea.tsx +++ b/webapp/packages/core-blocks/src/FormControls/Textarea.tsx @@ -73,6 +73,7 @@ export const Textarea: TextareaType = observer(function Textarea({ style, value: controlledValue, state, + required, children, className, fill, @@ -103,7 +104,7 @@ export const Textarea: TextareaType = observer(function Textarea({ return styled(useStyles(baseFormControlStyles, styles, style))( - {children} + {children}{required && ' *'} + + + + + + + )} {allowSaveCredentials && ( = observer(fu const enabled = state.enabled || false; const keyAuth = state.authType === NetworkHandlerAuthType.PublicKey; const passwordFilled = (initialConfig?.password === null && state.password !== '') || (state.password?.length || 0) > 0; + const testAvailable = keyAuth ? !!state.key?.length : passwordFilled; + const passwordLabel = keyAuth ? 'Passphrase' : translate('connections_network_handler_ssh_tunnel_password'); let passwordHint = ''; - if (initialConfig?.password === '') { + if (initialConfig?.password === '' && initialConfig.authType === state.authType) { passwordHint = '••••••'; } @@ -125,6 +127,7 @@ export const SSH: TabContainerPanelComponent = observer(fu disabled={disabled || !enabled} readOnly={readonly} mod='surface' + required small > {translate('connections_network_handler_ssh_tunnel_host')} @@ -136,6 +139,7 @@ export const SSH: TabContainerPanelComponent = observer(fu disabled={disabled || !enabled} readOnly={readonly} mod='surface' + required tiny > {translate('connections_network_handler_ssh_tunnel_port')} @@ -156,15 +160,16 @@ export const SSH: TabContainerPanelComponent = observer(fu - {keyAuth ? 'Passphrase' : translate('connections_network_handler_ssh_tunnel_password')} + {passwordLabel} {keyAuth && ( <> @@ -173,6 +178,7 @@ export const SSH: TabContainerPanelComponent = observer(fu state={state} disabled={disabled || !enabled} readOnly={readonly} + required medium > {translate('connections_network_handler_ssh_tunnel_private_key')} @@ -201,14 +207,15 @@ export const SSH: TabContainerPanelComponent = observer(fu name="savePassword" state={state} disabled={disabled || !enabled || readonly} - >{translate('connections_connection_edit_save_credentials')} + > + {translate('connections_connection_edit_save_credentials')} )}