Skip to content

Commit bf0bb34

Browse files
authored
Add Lint fixes (#21)
1 parent 304543d commit bf0bb34

File tree

3 files changed

+46
-23
lines changed

3 files changed

+46
-23
lines changed

src/app/components/Authentication/Login.tsx

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,18 @@ export class Login extends React.Component<LoginInterfaces.Props, LoginInterface
132132
</div>
133133
</div>
134134
<div className="form-row">
135-
<div className={ errorMessage ? classnames("col text-center mt -0 mb-2 errorMessage" ,styles['register-error-active']):""} >{errorMessage}</div>
135+
<div
136+
className={
137+
errorMessage
138+
? classnames(
139+
'col text-center mt -0 mb-2 errorMessage',
140+
styles['register-error-active'],
141+
)
142+
: ''
143+
}
144+
>
145+
{errorMessage}
146+
</div>
136147
</div>
137148
<div className="form-row">
138149
<div className="col text-center">

src/app/components/Authentication/Register.tsx

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,11 @@ export class Register extends React.Component<RegisterInterfaces.Props, Register
268268
})
269269
}
270270
/>
271-
<label htmlFor="switch" className="flaglabel" style={{ backgroundColor: '#4630eb' }}>
271+
<label
272+
htmlFor="switch"
273+
className="flaglabel"
274+
style={{ backgroundColor: '#4630eb' }}
275+
>
272276
Toggle
273277
</label>
274278
</span>
@@ -298,14 +302,13 @@ export class Register extends React.Component<RegisterInterfaces.Props, Register
298302
</div>
299303
)}
300304
<div className="input-group">
301-
302-
<ReactFlagsSelect
303-
searchable={true}
304-
placeholder="Search for a country"
305-
className={classnames(styles["customFlag" ])}
306-
defaultCountry="IN"
307-
onSelect={this.onSelectFlag}
308-
/>
305+
<ReactFlagsSelect
306+
searchable={true}
307+
placeholder="Search for a country"
308+
className={classnames(styles.customFlag)}
309+
defaultCountry="IN"
310+
onSelect={this.onSelectFlag}
311+
/>
309312

310313
<div className={classnames('invalid-feedback', styles['register-error'])}>
311314
Please Select a country
@@ -347,7 +350,10 @@ export class Register extends React.Component<RegisterInterfaces.Props, Register
347350
ref={this.recaptchaRef}
348351
/>
349352
<div
350-
className={classnames(styles['register-error-active'],"invalid-feedback text-center")}
353+
className={classnames(
354+
styles['register-error-active'],
355+
'invalid-feedback text-center',
356+
)}
351357
style={{
352358
display: !isCaptchaValidated && isFormSubmitted ? 'block' : 'none',
353359
}}
@@ -357,7 +363,7 @@ export class Register extends React.Component<RegisterInterfaces.Props, Register
357363
</div>
358364
<div
359365
className={
360-
errorMessage===""
366+
errorMessage === ''
361367
? classnames(
362368
'col text-center mt -0 mb-2 errorMessage',
363369
styles['register-error-inactive'],
@@ -386,7 +392,11 @@ export class Register extends React.Component<RegisterInterfaces.Props, Register
386392
<Row>
387393
<div
388394
className={classnames(styles['left-arrow'])}
389-
onClick={() => { if(currentStep!==RegisterInterfaces.Steps.USER_DETAILS) this.handleStepChange(currentStep, currentStep - 1) }}
395+
onClick={() => {
396+
if (currentStep !== RegisterInterfaces.Steps.USER_DETAILS) {
397+
this.handleStepChange(currentStep, currentStep - 1);
398+
}
399+
}}
390400
>
391401
<FontAwesomeIcon icon={faChevronCircleLeft} />
392402
</div>
@@ -429,7 +439,11 @@ export class Register extends React.Component<RegisterInterfaces.Props, Register
429439
</ul>
430440
<div
431441
className={classnames(styles['right-arrow'])}
432-
onClick={() => { if(currentStep!==RegisterInterfaces.Steps.OTHERS) this.handleStepChange(currentStep, currentStep + 1) } }
442+
onClick={() => {
443+
if (currentStep !== RegisterInterfaces.Steps.OTHERS) {
444+
this.handleStepChange(currentStep, currentStep + 1);
445+
}
446+
}}
433447
>
434448
<FontAwesomeIcon icon={faChevronCircleRight} />
435449
</div>

src/app/styles/Authentication.module.css

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,8 @@
107107
overflow-y: hidden !important;
108108
}
109109

110-
.stage-form{
111-
width:390px;
112-
110+
.stage-form {
111+
width: 390px;
113112
}
114113

115114
.avatar-img {
@@ -147,7 +146,6 @@
147146
margin-top: 3% !important;
148147
}
149148

150-
151149
.login-error {
152150
background-color: #fee5d4;
153151
padding: 9px;
@@ -246,11 +244,13 @@
246244
cursor: pointer;
247245
}
248246

249-
.left-arrow:active ,.left-arrow:focus {
247+
.left-arrow:active,
248+
.left-arrow:focus {
250249
transform: scale(0.9);
251250
}
252251

253-
.right-arrow:active , .right-arrow:focus{
252+
.right-arrow:active,
253+
.right-arrow:focus {
254254
transform: scale(0.9);
255255
}
256256

@@ -352,8 +352,6 @@
352352
border-radius: 5px;
353353
}
354354

355-
356-
357355
.multi-steps > li.is-active:before,
358356
.multi-steps > li.is-active ~ li:before {
359357
content: counter(stepNum);
@@ -409,7 +407,7 @@
409407
.multi-steps li.is-active {
410408
color: #4630eb;
411409
}
412-
.multi-steps li:active:before{
410+
.multi-steps li:active:before {
413411
transform: scale(0.9);
414412
}
415413

0 commit comments

Comments
 (0)