Skip to content

Commit

Permalink
Merge branch 'dev' of github.com:Lodestone-Team/lodestone into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
CheatCod committed Jul 27, 2023
2 parents 1befb6f + bc82947 commit a609804
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions dashboard/src/components/Atoms/Config/InputBox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,8 @@ export default function InputBox({

let icons = [];

if (typeModified !== 'password' && touched) {
// enable editing regardless of input type
if (touched) {
icons.push(
<FontAwesomeIcon
icon={faFloppyDisk}
Expand Down Expand Up @@ -200,7 +201,8 @@ export default function InputBox({
typeModified === 'password'
? setTypeModified('text')
: setTypeModified('password');
formRef.current?.reset();
// allow in-progress password to persist between hide/show
// formRef.current?.reset();
}}
key="reveal password"
/>
Expand Down Expand Up @@ -255,7 +257,7 @@ export default function InputBox({
</div>
</div>
<input
value={typeModified === 'password' ? 'xxxxxxxx' : value}
value={value}
placeholder={placeholder}
onChange={onChange}
maxLength={maxLength}
Expand All @@ -267,7 +269,7 @@ export default function InputBox({
onBlur={() => {
setValue(value.trim());
}}
disabled={typeModified === 'password' ? true : disabled}
disabled={disabled}
type={typeModified}
autoComplete={DISABLE_AUTOFILL}
/>
Expand Down

0 comments on commit a609804

Please sign in to comment.