Skip to content

Commit

Permalink
refactor: card form disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
topliceanurazvan committed Feb 26, 2024
1 parent 6961fdf commit 80fdfb6
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ const Authentication: React.FC = () => {
spacing={24}
form={form}
initialValues={defaults}
disabled={!mayEdit}
disabled={!mayEdit || disableSecretCreation}
wasTouched={Boolean((tokenSecret && isClearedToken) || (usernameSecret && isClearedUsername))}
onConfirm={onFinish}
onCancel={onCancel}
Expand All @@ -89,14 +89,12 @@ const Authentication: React.FC = () => {
label="Git Username"
isClearedValue={isClearedUsername}
setIsClearedValue={setIsClearedUsername}
disabled={disableSecretCreation}
/>
<SecretFormItem
name="token"
label="Git Token"
isClearedValue={isClearedToken}
setIsClearedValue={setIsClearedToken}
disabled={disableSecretCreation}
/>
</CardForm>
);
Expand Down

0 comments on commit 80fdfb6

Please sign in to comment.