@@ -65,15 +65,15 @@ const HTMLPanel = (props): JSX.Element => {
65
65
const triggerError = ( type : String ) => {
66
66
setErrorStatus ( true ) ;
67
67
if ( type === 'empty' ) {
68
- setErrorMsg ( 'Tag/ Tag name cannot be blank.' ) ;
68
+ setErrorMsg ( '* Input cannot be blank. * ' ) ;
69
69
} else if ( type === 'dupe' ) {
70
- setErrorMsg ( 'Tag/ Tag name already exists.' ) ;
70
+ setErrorMsg ( '* Input already exists. * ' ) ;
71
71
} else if ( type === 'letters' ) {
72
- setErrorMsg ( 'Tag/ Tag name must start with a letter.' ) ;
72
+ setErrorMsg ( '* Input must start with a letter. * ' ) ;
73
73
} else if ( type === 'symbolsDetected' ) {
74
- setErrorMsg ( 'Tag/ Tag name must not contain symbols.' ) ;
74
+ setErrorMsg ( '* Input must not contain symbols. * ' ) ;
75
75
} else if ( type === 'length' ) {
76
- setErrorMsg ( 'Element name cannot exceed 10 characters.' ) ;
76
+ setErrorMsg ( '* Input cannot exceed 10 characters. * ' ) ;
77
77
}
78
78
} ;
79
79
@@ -183,11 +183,14 @@ const HTMLPanel = (props): JSX.Element => {
183
183
type = "text"
184
184
name = "Tag"
185
185
value = { tag }
186
+ autocomplete = "off"
186
187
onChange = { handleTagChange }
187
- className = { classes . input }
188
+ className = { isThemeLight ? ` ${ classes . input } ${ classes . lightThemeFontColor } ` : ` ${ classes . input } ${ classes . darkThemeFontColor } ` }
188
189
style = { { marginBottom : '10px' } }
190
+
189
191
/>
190
- { errorStatus && < span > { errorMsg } </ span > }
192
+ { errorStatus && < span style = { { fontSize :"11px" , marginTop : "10px" , color : "red" } } > < em > { errorMsg } </ em > </ span > }
193
+
191
194
< br > </ br >
192
195
< label className = { isThemeLight ? `${ classes . inputLabel } ${ classes . lightThemeFontColor } ` : `${ classes . inputLabel } ${ classes . darkThemeFontColor } ` } >
193
196
Element Name:
@@ -198,10 +201,12 @@ const HTMLPanel = (props): JSX.Element => {
198
201
name = "Tag Name"
199
202
value = { name }
200
203
onChange = { handleNameChange }
201
- className = { classes . input }
204
+ autocomplete = "off"
205
+ className = { isThemeLight ? `${ classes . input } ${ classes . lightThemeFontColor } ` : `${ classes . input } ${ classes . darkThemeFontColor } ` }
202
206
/>
203
- { errorStatus && < span > { errorMsg } </ span > }
207
+ { errorStatus && < span style = { { fontSize : "11px" , marginTop : "10px" , color : "red" } } > < em > { errorMsg } </ em > </ span > }
204
208
< input
209
+
205
210
className = { isThemeLight ? `${ classes . addElementButton } ${ classes . lightThemeFontColor } ` : `${ classes . addElementButton } ${ classes . darkThemeFontColor } ` }
206
211
id = "submitButton"
207
212
type = "submit"
@@ -237,7 +242,7 @@ const useStyles = makeStyles({
237
242
backgroundColor : 'rgba(255,255,255,0.15)' ,
238
243
margin : '0px 0px 0px 10px' ,
239
244
width : '140px' ,
240
- height : '30px'
245
+ height : '30px' ,
241
246
} ,
242
247
inputLabel : {
243
248
fontSize : '85%' ,
0 commit comments