This repository was archived by the owner on Feb 19, 2025. It is now read-only.
File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ function Input({
65
65
...props
66
66
} : Props ) {
67
67
const [ copyLabel , setCopyLabel ] = useState ( 'Copy' )
68
- const [ hidden , setHidden ] = useState ( reveal )
68
+ const [ hidden , setHidden ] = useState ( true )
69
69
70
70
const __styles = styleHandler ( 'input' )
71
71
@@ -160,15 +160,15 @@ function Input({
160
160
placeholder = { placeholder }
161
161
ref = { inputRef }
162
162
type = { type }
163
- value = { hidden ? HIDDEN_PLACEHOLDER : value }
163
+ value = { reveal && hidden ? HIDDEN_PLACEHOLDER : value }
164
164
className = { inputClasses . join ( ' ' ) }
165
165
{ ...props }
166
166
/>
167
167
{ icon && < InputIconContainer icon = { icon } /> }
168
168
{ copy || error || actions ? (
169
169
< div className = { __styles . actions_container } >
170
170
{ error && < InputErrorIcon size = { size } /> }
171
- { copy && ! hidden ? (
171
+ { copy && ! ( reveal && hidden ) ? (
172
172
< Button
173
173
size = "tiny"
174
174
type = "default"
@@ -178,7 +178,7 @@ function Input({
178
178
{ copyLabel }
179
179
</ Button >
180
180
) : null }
181
- { hidden && reveal ? (
181
+ { reveal && hidden ? (
182
182
< Button size = "tiny" type = "default" onClick = { onReveal } >
183
183
Reveal
184
184
</ Button >
You can’t perform that action at this time.
0 commit comments