-
Notifications
You must be signed in to change notification settings - Fork 125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat/116 user dashboard password settings page #217
Conversation
… functionality-final)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
eslint
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
const hasMinLength = value.length >= 8; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
setValidation({ |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
hasUppercase, |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
hasNumber, |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············hasMinLength
with ······hasMinLength,
hasMinLength |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
const handleChange = (event: React.ChangeEvent<HTMLInputElement>) => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····event.preventDefault()
with event.preventDefault();
event.preventDefault() |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
const { name, value } = event.target; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········const·val:·keyof·PasswordValues·=·name·as·keyof·PasswordValues
with ····const·val:·keyof·PasswordValues·=·name·as·keyof·PasswordValues;
const val: keyof PasswordValues = name as keyof PasswordValues |
🚫 [eslint] <unicorn/prevent-abbreviations> reported by reviewdog 🐶
The variable val
should be named value_
. A more descriptive name will do too.
const val: keyof PasswordValues = name as keyof PasswordValues |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
setActualValue((prevActualValue) => ({ |
🚫 [eslint] <unicorn/prevent-abbreviations> reported by reviewdog 🐶
The variable prevActualValue
should be named previousActualValue
. A more descriptive name will do too.
setActualValue((prevActualValue) => ({ |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
...prevActualValue, |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······[name]:·(actualValue[val]·+·value.charAt(value.length·-·1)).length·>·value.length·?·actualValue[val].slice(0,·-1)·:·actualValue[val]·+·value.charAt(value.length·-·1)
with [name]:⏎········(actualValue[val]·+·value.charAt(value.length·-·1)).length·>⏎········value.length⏎··········?·actualValue[val].slice(0,·-1)⏎··········:·actualValue[val]·+·value.charAt(value.length·-·1),
[name]: (actualValue[val] + value.charAt(value.length - 1)).length > value.length ? actualValue[val].slice(0, -1) : actualValue[val] + value.charAt(value.length - 1) |
🚫 [eslint] <unicorn/prefer-at> reported by reviewdog 🐶
Prefer String#at(…)
over String#charAt(….length - index)
.
[name]: (actualValue[val] + value.charAt(value.length - 1)).length > value.length ? actualValue[val].slice(0, -1) : actualValue[val] + value.charAt(value.length - 1) |
🚫 [eslint] <unicorn/prefer-at> reported by reviewdog 🐶
Prefer String#at(…)
over String#charAt(….length - index)
.
[name]: (actualValue[val] + value.charAt(value.length - 1)).length > value.length ? actualValue[val].slice(0, -1) : actualValue[val] + value.charAt(value.length - 1) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
setDisplayValue((prevDisplayValue) => ({ |
🚫 [eslint] <unicorn/prevent-abbreviations> reported by reviewdog 🐶
The variable prevDisplayValue
should be named previousDisplayValue
. A more descriptive name will do too.
setDisplayValue((prevDisplayValue) => ({ |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
...prevDisplayValue, |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············[name]:·'*'.repeat(value.length)
with ······[name]:·"*".repeat(value.length),
[name]: '*'.repeat(value.length) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········if·(name·===·'newPassword'
with ····if·(name·===·"newPassword"
if (name === 'newPassword') { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
handlePasswordValidation(actualValue[val]); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ·····⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 62 to 63 in be36ee3
}; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
useEffect(() => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········const·inputs·=·document.querySelectorAll<HTMLInputElement>('.psw-input'
with ····const·inputs·=·document.querySelectorAll<HTMLInputElement>(".psw-input"
const inputs = document.querySelectorAll<HTMLInputElement>('.psw-input'); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
inputs.forEach((element) => { |
🚫 [eslint] <unicorn/no-array-for-each> reported by reviewdog 🐶
Use for…of
instead of .forEach(…)
.
inputs.forEach((element) => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
element.addEventListener( |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····'select'
with "select"
'select', |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
function () { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
this.select = () => {}; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
this.selectionStart = this.selectionEnd; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············false
with ········false,
false |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
}, []); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<h1·className="text-[rgba(20,20,20,1)]·font-bold·text-2xl·mb-1·mt-10">Password·Settings
with ······<h1·className="mb-1·mt-10·text-2xl·font-bold·text-[rgba(20,20,20,1)]">⏎········Password·Settings⏎······
<h1 className="text-[rgba(20,20,20,1)] font-bold text-2xl mb-1 mt-10">Password Settings</h1> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<p·className="text-[rgba(67,67,67,1)]·mb-5·text-base">Update·password·for·enhanced·account·security
with ······<p·className="mb-5·text-base·text-[rgba(67,67,67,1)]">⏎········Update·password·for·enhanced·account·security⏎······
<p className="text-[rgba(67,67,67,1)] mb-5 text-base">Update password for enhanced account security</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Form·className="w-2/3·max-md:w-5/6·flex·flex-col·gap-4
with ······<Form·className="flex·w-2/3·flex-col·gap-4·max-md:w-5/6
<Form className="w-2/3 max-md:w-5/6 flex flex-col gap-4"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<p className="text-base text-[rgba(67,67,67,1)]">Current Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className={
border-[1px]·${actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·'border-[rgba(220,38,38,1)]'·:·'border-[rgba(147,147,147,1)]'}·rounded-lg·select-none·flex·justify-between·items-center·p-1·pr-5}>
with <div⏎············className={
border-[1px]·${actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·"border-[rgba(220,38,38,1)]"·:·"border-[rgba(147,147,147,1)]"}·flex·select-none·items-center·justify-between·rounded-lg·p-1·pr-5}
<div className={`border-[1px] ${actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <unicorn/explicit-length-check> reported by reviewdog 🐶
Use .length > 0
when checking length is not zero.
<div className={`border-[1px] ${actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<input·
with >⏎············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="currentPassword"·
with ··············name="currentPassword"
name="currentPassword" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········value={showPassword·?·actualValue.currentPassword·:·displayValue.currentPassword}·⏎························onChange={handleChange}·
with value={⏎················showPassword⏎··················?·actualValue.currentPassword⏎··················:·displayValue.currentPassword⏎··············}⏎··············onChange={handleChange}
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 88 to 89 in be36ee3
value={showPassword ? actualValue.currentPassword : displayValue.currentPassword} | |
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
placeholder="Enter current password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················{·!showPassword·?·
with ············{!showPassword·?·(
{ !showPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowPassword(!showPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowPassword(!showPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowPassword(!showPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········:·
with />⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowPassword(!showPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowPassword(!showPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowPassword(!showPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············)}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················{⏎····················actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·
with ··········{actualValue.currentPassword.length·<·5·&&⏎··········actualValue.currentPassword.length·!=·0·?·(
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 101 to 102 in be36ee3
{ | |
actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? |
🚫 [eslint] <unicorn/explicit-length-check> reported by reviewdog 🐶
Use .length > 0
when checking length is not zero.
actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ·····················<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">Invalid·password</p>·
with ············<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">⏎··············Invalid·password
<p className="text-sm font-[500] text-[rgba(220,38,38,1)]">Invalid password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········:·
with </p>
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················null⏎················}·
with ··········)·:·null}
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 105 to 106 in be36ee3
null | |
} |
🚫 [eslint] <unicorn/no-null> reported by reviewdog 🐶
Use undefined
instead of null
.
null |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········⏎············
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 107 to 108 in be36ee3
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
<p className="text-base text-[rgba(67,67,67,1)]">New Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className="border-[1px]·border-[rgba(147,147,147,1)]·rounded-lg·select-none·flex·justify-between·items-center·
with <div·className="flex·select-none·items-center·justify-between·rounded-lg·border-[1px]·border-[rgba(147,147,147,1)]·
<div className="border-[1px] border-[rgba(147,147,147,1)] rounded-lg select-none flex justify-between items-center p-1 pr-5"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················<input·
with ············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="newPassword"·⏎························value={showNewPassword·?·actualValue.newPassword·:·displayValue.newPassword}·
with ··············name="newPassword"⏎··············value={⏎················showNewPassword⏎··················?·actualValue.newPassword⏎··················:·displayValue.newPassword
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 115 to 116 in be36ee3
name="newPassword" | |
value={showNewPassword ? actualValue.newPassword : displayValue.newPassword} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············onChange={handleChange}·
with ··}⏎··············onChange={handleChange}
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········
placeholder="Enter new password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························onFocus={·
with ··············onFocus={
onFocus={ () => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
// setIsFocused(true); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··························
with ··············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with ··············className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················{·!showNewPassword·?·
with ············{!showNewPassword·?·(
{ !showNewPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showNewPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowNewPassword(!showNewPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowNewPassword(!showNewPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowNewPassword(!showNewPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········:·
with />⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowNewPassword(!showNewPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowNewPassword(!showNewPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowNewPassword(!showNewPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with )}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
{displayValue.newPassword.length > 0 && ( |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
<div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
<div className="flex gap-3"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasUppercase·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}
with ··<span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasUppercase·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}⏎················
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasUppercase ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasNumber·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}
with <span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasNumber·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}⏎················
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasNumber ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasMinLength·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}></span>
with ··<span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasMinLength·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasMinLength ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ></span>⏎··············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········
<div className="mt-3 grid gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<p·className="text-sm·mb-1
with <p·className="mb-1·text-sm
<p className="text-sm mb-1">Weak password. Must contain;</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ································{validation.hasUppercase·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with ··················{validation.hasUppercase·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasUppercase ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ····)}⏎
<p className="text-sm">At least 1 uppercase</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············{validation.hasNumber·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with {validation.hasNumber·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasNumber ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert )}⏎····
<p className="text-sm">At least 1 number</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ································{validation.hasMinLength·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with ··················{validation.hasMinLength·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasMinLength ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ····)}⏎
<p className="text-sm">At least 8 characters</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········⏎············
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 156 to 157 in be36ee3
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<p className="text-base text-[rgba(67,67,67,1)]">Confirm Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className={
border-[1px]·${actualValue.confirmPassword.length·>·0·?·(actualValue.newPassword·!=·actualValue.confirmPassword·?·'border-[rgba(220,38,38,1)]'·:·'border-[rgba(147,147,147,1)]')·:·'border-[rgba(147,147,147,1)]'}·rounded-lg·select-none·flex·justify-between·items-center·p-1·pr-5}>
with <div⏎············className={
border-[1px]·${actualValue.confirmPassword.length·>·0·?·(actualValue.newPassword·!=·actualValue.confirmPassword·?·"border-[rgba(220,38,38,1)]"·:·"border-[rgba(147,147,147,1)]")·:·"border-[rgba(147,147,147,1)]"}·flex·select-none·items-center·justify-between·rounded-lg·p-1·pr-5}
<div className={`border-[1px] ${actualValue.confirmPassword.length > 0 ? (actualValue.newPassword != actualValue.confirmPassword ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]') : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
<div className={`border-[1px] ${actualValue.confirmPassword.length > 0 ? (actualValue.newPassword != actualValue.confirmPassword ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]') : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<input·
with >⏎············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="confirmPassword"·
with ··············name="confirmPassword"
name="confirmPassword" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········value={showConfirmPassword·?·actualValue.confirmPassword·:·displayValue.confirmPassword}·
with value={⏎················showConfirmPassword⏎··················?·actualValue.confirmPassword⏎··················:·displayValue.confirmPassword
value={showConfirmPassword ? actualValue.confirmPassword : displayValue.confirmPassword} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ··}⏎··············
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········
placeholder="Enter confirm password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with ··············className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········{·!showConfirmPassword·?·
with {!showConfirmPassword·?·(
{ !showConfirmPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showConfirmPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowConfirmPassword(!showConfirmPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············:·
with ··/>⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowConfirmPassword(!showConfirmPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with )}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················{⏎····················actualValue.confirmPassword.length·>·0·?·
with ··········{actualValue.confirmPassword.length·>·0
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 178 to 179 in be36ee3
{ | |
actualValue.confirmPassword.length > 0 ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········(actualValue.newPassword·!=·actualValue.confirmPassword·&&·<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">Password·does·not·match</p>)·
with ?·actualValue.newPassword·!=·actualValue.confirmPassword·&&·(⏎················<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">⏎··················Password·does·not·match
(actualValue.newPassword != actualValue.confirmPassword && <p className="text-sm font-[500] text-[rgba(220,38,38,1)]">Password does not match</p>) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················:·
with ················</p>
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················null
with ··············)
null |
🚫 [eslint] <unicorn/no-null> reported by reviewdog 🐶
Use undefined
instead of null
.
null |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····}·
with :·null}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 184 to 185 in be36ee3
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 187 to 188 in be36ee3
<AlertDialog> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······⏎················<div·className="flex·gap-5·mt-6·
with <div·className="mt-6·flex·gap-5
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 189 to 190 in be36ee3
<div className="flex gap-5 mt-6 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Button·type="submit"·variant="outline"·size="default"·className="w-24·h-12·text-base·bg-transparent·font-bold·text-black·rounded-lg">Cancel
with <Button⏎··············type="submit"⏎··············variant="outline"⏎··············size="default"⏎··············className="h-12·w-24·rounded-lg·bg-transparent·text-base·font-bold·text-black"⏎············>⏎··············Cancel⏎············
<Button type="submit" variant="outline" size="default" className="w-24 h-12 text-base bg-transparent font-bold text-black rounded-lg">Cancel</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
<AlertDialogTrigger asChild> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Button·
with <Button
<Button |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························type="submit"·
with ················type="submit"
type="submit" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························onClick={()·=>·{·
with ················onClick={()·=>·{
onClick={() => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············setActualValue({currentPassword:·'',·newPassword:·'',·confirmPassword:·''})·
with setActualValue({⏎····················currentPassword:·"",⏎····················newPassword:·"",⏎····················confirmPassword:·"",
setActualValue({currentPassword: '', newPassword: '', confirmPassword: ''}) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············setDisplayValue({currentPassword:·'',·newPassword:·'',·confirmPassword:·''})
with });⏎··················setDisplayValue({⏎····················currentPassword:·"",⏎····················newPassword:·"",⏎····················confirmPassword:·"",
setDisplayValue({currentPassword: '', newPassword: '', confirmPassword: ''}) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········}}·
with });⏎················}}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························variant="default"·
with ················variant="default"
variant="default" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························size="default"·
with ················size="default"
size="default" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························className="w-44·h-12·text-base·bg-[rgba(249,115,22,1)]·font-bold·text-white·rounded-lg
with ················className="h-12·w-44·rounded-lg·bg-[rgba(249,115,22,1)]·text-base·font-bold·text-white
className="w-44 h-12 text-base bg-[rgba(249,115,22,1)] font-bold text-white rounded-lg" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
Update Password |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
</AlertDialogTrigger> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········⏎················
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 206 to 207 in be36ee3
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<AlertDialogContent className="sm:max-w-md"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
<AlertDialogHeader> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<AlertDialogTitle>Password·Successfully·Updated!
with <AlertDialogTitle>⏎················Password·Successfully·Updated!⏎··············
<AlertDialogTitle>Password Successfully Updated!</AlertDialogTitle> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ··············
<AlertDialogDescription> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························Your·password·has·been·successfully·updated!·You·can·now·log·in
with ················Your·password·has·been·successfully·updated!·You·can·now·log·in⏎···············
Your password has been successfully updated! You can now log in with your new password. |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ··············
</AlertDialogDescription> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
</AlertDialogHeader> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
<AlertDialogFooter className="sm:justify-end"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················<AlertDialogCancel·asChild·className='flex·flex-row-reverse'
with ··············<AlertDialogCancel·asChild·className="flex·flex-row-reverse"
<AlertDialogCancel asChild className='flex flex-row-reverse'> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Button·type="button"·variant="default"·className="px-6·font-semibold·bg-[rgba(249,115,22,1)]">
with <Button⏎··················type="button"⏎··················variant="default"⏎··················className="bg-[rgba(249,115,22,1)]·px-6·font-semibold"
<Button type="button" variant="default" className="px-6 font-semibold bg-[rgba(249,115,22,1)]"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········
with ················>⏎
Continue |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ················
</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</AlertDialogCancel> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
</AlertDialogFooter> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
</AlertDialogContent> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
</AlertDialog> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············⏎··
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 225 to 226 in be36ee3
</Form> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace '~/components/dashboard/PasswordUpdate'
with "~/components/dashboard/PasswordUpdate";
import PasswordUpdate from '~/components/dashboard/PasswordUpdate' |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··<div·className="h-16··grid·
with <div·className="grid·h-16·
<div className="h-16 grid place-items-center font-extrabold">Nav</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
<div className="flex"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<div·className="w-[20%]·h-svh·bg-[rgba(203,213,225,.3)]·grid·place-items-center·font-extrabold·max-lg:hidden">Sidebar
with ········<div·className="grid·h-svh·w-[20%]·place-items-center·bg-[rgba(203,213,225,.3)]·font-extrabold·max-lg:hidden">⏎··········Sidebar⏎········
<div className="w-[20%] h-svh bg-[rgba(203,213,225,.3)] grid place-items-center font-extrabold max-lg:hidden">Sidebar</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ········
<PasswordUpdate /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;⏎
export default DaashboardPasswordSettings |
import { useEffect, useState } from "react"; | ||
import { Form } from "@remix-run/react"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete import·{·useEffect,·useState·}·from·"react";⏎
import { useEffect, useState } from "react"; | |
import { Form } from "@remix-run/react"; | |
import { Form } from "@remix-run/react"; |
import { EyeOff, Eye, CircleCheck } from 'lucide-react'; | ||
import { Button } from "../ui/button"; | ||
import { AlertDialog, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle, AlertDialogTrigger } from "../ui/alert-dialog"; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert import·{·Button·}·from·"../ui/button";⏎
import { Button } from "../ui/button"; | |
const [showNewPassword, setShowNewPassword] = useState<boolean>(false); | ||
const [showConfirmPassword, setShowConfirmPassword] = useState<boolean>(false); | ||
const [validation, setValidation] = useState({ | ||
hasUppercase: false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
hasUppercase: false, | |
hasUppercase: false, |
hasNumber: false, | ||
hasMinLength: false, | ||
}); | ||
const [displayValue, setDisplayValue] = useState<PasswordValues>({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
const [displayValue, setDisplayValue] = useState<PasswordValues>({ | |
const [displayValue, setDisplayValue] = useState<PasswordValues>({ |
hasMinLength: false, | ||
}); | ||
const [displayValue, setDisplayValue] = useState<PasswordValues>({ | ||
currentPassword: '', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····currentPassword:·''
with currentPassword:·""
currentPassword: '', | |
currentPassword: "", |
currentPassword: '', | ||
newPassword: '', | ||
confirmPassword: '' | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
}); | |
}); |
|
||
const [actualValue, setActualValue] = useState<PasswordValues>({ | ||
currentPassword: '', | ||
newPassword: '', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········newPassword:·''
with ····newPassword:·""
newPassword: '', | |
newPassword: "", |
currentPassword: '', | ||
newPassword: '', | ||
confirmPassword: '' | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
}); | |
}); |
confirmPassword: '' | ||
}); | ||
|
||
const handlePasswordValidation = (value: string) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
const handlePasswordValidation = (value: string) => { | |
const handlePasswordValidation = (value: string) => { |
|
||
const handlePasswordValidation = (value: string) => { | ||
const hasUppercase = /[A-Z]/.test(value); | ||
const hasNumber = /[0-9]/.test(value); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <unicorn/better-regex> reported by reviewdog 🐶
/[0-9]/ can be optimized to /\d/.
const hasNumber = /[0-9]/.test(value); | |
const hasNumber = /\d/.test(value); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
eslint
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
inputs.forEach((element) => { |
🚫 [eslint] <unicorn/no-array-for-each> reported by reviewdog 🐶
Use for…of
instead of .forEach(…)
.
inputs.forEach((element) => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
element.addEventListener( |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····'select'
with "select"
'select', |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
function () { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
this.select = () => {}; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
this.selectionStart = this.selectionEnd; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············false
with ········false,
false |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
}, []); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<h1·className="text-[rgba(20,20,20,1)]·font-bold·text-2xl·mb-1·mt-10">Password·Settings
with ······<h1·className="mb-1·mt-10·text-2xl·font-bold·text-[rgba(20,20,20,1)]">⏎········Password·Settings⏎······
<h1 className="text-[rgba(20,20,20,1)] font-bold text-2xl mb-1 mt-10">Password Settings</h1> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<p·className="text-[rgba(67,67,67,1)]·mb-5·text-base">Update·password·for·enhanced·account·security
with ······<p·className="mb-5·text-base·text-[rgba(67,67,67,1)]">⏎········Update·password·for·enhanced·account·security⏎······
<p className="text-[rgba(67,67,67,1)] mb-5 text-base">Update password for enhanced account security</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Form·className="w-2/3·max-md:w-5/6·flex·flex-col·gap-4
with ······<Form·className="flex·w-2/3·flex-col·gap-4·max-md:w-5/6
<Form className="w-2/3 max-md:w-5/6 flex flex-col gap-4"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<p className="text-base text-[rgba(67,67,67,1)]">Current Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className={
border-[1px]·${actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·'border-[rgba(220,38,38,1)]'·:·'border-[rgba(147,147,147,1)]'}·rounded-lg·select-none·flex·justify-between·items-center·p-1·pr-5}>
with <div⏎············className={
border-[1px]·${actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·"border-[rgba(220,38,38,1)]"·:·"border-[rgba(147,147,147,1)]"}·flex·select-none·items-center·justify-between·rounded-lg·p-1·pr-5}
<div className={`border-[1px] ${actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <unicorn/explicit-length-check> reported by reviewdog 🐶
Use .length > 0
when checking length is not zero.
<div className={`border-[1px] ${actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<input·
with >⏎············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="currentPassword"·
with ··············name="currentPassword"
name="currentPassword" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········value={showPassword·?·actualValue.currentPassword·:·displayValue.currentPassword}·⏎························onChange={handleChange}·
with value={⏎················showPassword⏎··················?·actualValue.currentPassword⏎··················:·displayValue.currentPassword⏎··············}⏎··············onChange={handleChange}
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 88 to 89 in 54e57b0
value={showPassword ? actualValue.currentPassword : displayValue.currentPassword} | |
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
placeholder="Enter current password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················{·!showPassword·?·
with ············{!showPassword·?·(
{ !showPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowPassword(!showPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowPassword(!showPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowPassword(!showPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········:·
with />⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowPassword(!showPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowPassword(!showPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowPassword(!showPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············)}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················{⏎····················actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·
with ··········{actualValue.currentPassword.length·<·5·&&⏎··········actualValue.currentPassword.length·!=·0·?·(
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 101 to 102 in 54e57b0
{ | |
actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? |
🚫 [eslint] <unicorn/explicit-length-check> reported by reviewdog 🐶
Use .length > 0
when checking length is not zero.
actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ·····················<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">Invalid·password</p>·
with ············<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">⏎··············Invalid·password
<p className="text-sm font-[500] text-[rgba(220,38,38,1)]">Invalid password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········:·
with </p>
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················null⏎················}·
with ··········)·:·null}
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 105 to 106 in 54e57b0
null | |
} |
🚫 [eslint] <unicorn/no-null> reported by reviewdog 🐶
Use undefined
instead of null
.
null |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········⏎············
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 107 to 108 in 54e57b0
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
<p className="text-base text-[rgba(67,67,67,1)]">New Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className="border-[1px]·border-[rgba(147,147,147,1)]·rounded-lg·select-none·flex·justify-between·items-center·
with <div·className="flex·select-none·items-center·justify-between·rounded-lg·border-[1px]·border-[rgba(147,147,147,1)]·
<div className="border-[1px] border-[rgba(147,147,147,1)] rounded-lg select-none flex justify-between items-center p-1 pr-5"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················<input·
with ············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="newPassword"·⏎························value={showNewPassword·?·actualValue.newPassword·:·displayValue.newPassword}·
with ··············name="newPassword"⏎··············value={⏎················showNewPassword⏎··················?·actualValue.newPassword⏎··················:·displayValue.newPassword
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 115 to 116 in 54e57b0
name="newPassword" | |
value={showNewPassword ? actualValue.newPassword : displayValue.newPassword} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············onChange={handleChange}·
with ··}⏎··············onChange={handleChange}
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········
placeholder="Enter new password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························onFocus={·
with ··············onFocus={
onFocus={ () => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
// setIsFocused(true); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··························
with ··············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with ··············className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················{·!showNewPassword·?·
with ············{!showNewPassword·?·(
{ !showNewPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showNewPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowNewPassword(!showNewPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowNewPassword(!showNewPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowNewPassword(!showNewPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········:·
with />⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowNewPassword(!showNewPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowNewPassword(!showNewPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowNewPassword(!showNewPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with )}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
{displayValue.newPassword.length > 0 && ( |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
<div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
<div className="flex gap-3"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasUppercase·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}
with ··<span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasUppercase·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}⏎················
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasUppercase ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasNumber·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}
with <span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasNumber·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}⏎················
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasNumber ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasMinLength·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}></span>
with ··<span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasMinLength·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasMinLength ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ></span>⏎··············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········
<div className="mt-3 grid gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<p·className="text-sm·mb-1
with <p·className="mb-1·text-sm
<p className="text-sm mb-1">Weak password. Must contain;</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ································{validation.hasUppercase·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with ··················{validation.hasUppercase·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasUppercase ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ····)}⏎
<p className="text-sm">At least 1 uppercase</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············{validation.hasNumber·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with {validation.hasNumber·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasNumber ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert )}⏎····
<p className="text-sm">At least 1 number</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ································{validation.hasMinLength·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with ··················{validation.hasMinLength·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasMinLength ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ····)}⏎
<p className="text-sm">At least 8 characters</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········⏎············
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 156 to 157 in 54e57b0
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<p className="text-base text-[rgba(67,67,67,1)]">Confirm Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className={
border-[1px]·${actualValue.confirmPassword.length·>·0·?·(actualValue.newPassword·!=·actualValue.confirmPassword·?·'border-[rgba(220,38,38,1)]'·:·'border-[rgba(147,147,147,1)]')·:·'border-[rgba(147,147,147,1)]'}·rounded-lg·select-none·flex·justify-between·items-center·p-1·pr-5}>
with <div⏎············className={
border-[1px]·${actualValue.confirmPassword.length·>·0·?·(actualValue.newPassword·!=·actualValue.confirmPassword·?·"border-[rgba(220,38,38,1)]"·:·"border-[rgba(147,147,147,1)]")·:·"border-[rgba(147,147,147,1)]"}·flex·select-none·items-center·justify-between·rounded-lg·p-1·pr-5}
<div className={`border-[1px] ${actualValue.confirmPassword.length > 0 ? (actualValue.newPassword != actualValue.confirmPassword ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]') : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
<div className={`border-[1px] ${actualValue.confirmPassword.length > 0 ? (actualValue.newPassword != actualValue.confirmPassword ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]') : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<input·
with >⏎············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="confirmPassword"·
with ··············name="confirmPassword"
name="confirmPassword" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········value={showConfirmPassword·?·actualValue.confirmPassword·:·displayValue.confirmPassword}·
with value={⏎················showConfirmPassword⏎··················?·actualValue.confirmPassword⏎··················:·displayValue.confirmPassword
value={showConfirmPassword ? actualValue.confirmPassword : displayValue.confirmPassword} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ··}⏎··············
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········
placeholder="Enter confirm password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with ··············className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········{·!showConfirmPassword·?·
with {!showConfirmPassword·?·(
{ !showConfirmPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showConfirmPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowConfirmPassword(!showConfirmPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············:·
with ··/>⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowConfirmPassword(!showConfirmPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with )}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················{⏎····················actualValue.confirmPassword.length·>·0·?·
with ··········{actualValue.confirmPassword.length·>·0
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 178 to 179 in 54e57b0
{ | |
actualValue.confirmPassword.length > 0 ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········(actualValue.newPassword·!=·actualValue.confirmPassword·&&·<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">Password·does·not·match</p>)·
with ?·actualValue.newPassword·!=·actualValue.confirmPassword·&&·(⏎················<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">⏎··················Password·does·not·match
(actualValue.newPassword != actualValue.confirmPassword && <p className="text-sm font-[500] text-[rgba(220,38,38,1)]">Password does not match</p>) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················:·
with ················</p>
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················null
with ··············)
null |
🚫 [eslint] <unicorn/no-null> reported by reviewdog 🐶
Use undefined
instead of null
.
null |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····}·
with :·null}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 184 to 185 in 54e57b0
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 187 to 188 in 54e57b0
<AlertDialog> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······⏎················<div·className="flex·gap-5·mt-6·
with <div·className="mt-6·flex·gap-5
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 189 to 190 in 54e57b0
<div className="flex gap-5 mt-6 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Button·type="submit"·variant="outline"·size="default"·className="w-24·h-12·text-base·bg-transparent·font-bold·text-black·rounded-lg">Cancel
with <Button⏎··············type="submit"⏎··············variant="outline"⏎··············size="default"⏎··············className="h-12·w-24·rounded-lg·bg-transparent·text-base·font-bold·text-black"⏎············>⏎··············Cancel⏎············
<Button type="submit" variant="outline" size="default" className="w-24 h-12 text-base bg-transparent font-bold text-black rounded-lg">Cancel</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
<AlertDialogTrigger asChild> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Button·
with <Button
<Button |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························type="submit"·
with ················type="submit"
type="submit" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························onClick={()·=>·{·
with ················onClick={()·=>·{
onClick={() => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············setActualValue({currentPassword:·'',·newPassword:·'',·confirmPassword:·''})·
with setActualValue({⏎····················currentPassword:·"",⏎····················newPassword:·"",⏎····················confirmPassword:·"",
setActualValue({currentPassword: '', newPassword: '', confirmPassword: ''}) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············setDisplayValue({currentPassword:·'',·newPassword:·'',·confirmPassword:·''})
with });⏎··················setDisplayValue({⏎····················currentPassword:·"",⏎····················newPassword:·"",⏎····················confirmPassword:·"",
setDisplayValue({currentPassword: '', newPassword: '', confirmPassword: ''}) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········}}·
with });⏎················}}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························variant="default"·
with ················variant="default"
variant="default" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························size="default"·
with ················size="default"
size="default" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························className="w-44·h-12·text-base·bg-[rgba(249,115,22,1)]·font-bold·text-white·rounded-lg
with ················className="h-12·w-44·rounded-lg·bg-[rgba(249,115,22,1)]·text-base·font-bold·text-white
className="w-44 h-12 text-base bg-[rgba(249,115,22,1)] font-bold text-white rounded-lg" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
Update Password |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
</AlertDialogTrigger> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········⏎················
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 206 to 207 in 54e57b0
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<AlertDialogContent className="sm:max-w-md"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
<AlertDialogHeader> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<AlertDialogTitle>Password·Successfully·Updated!
with <AlertDialogTitle>⏎················Password·Successfully·Updated!⏎··············
<AlertDialogTitle>Password Successfully Updated!</AlertDialogTitle> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ··············
<AlertDialogDescription> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························Your·password·has·been·successfully·updated!·You·can·now·log·in
with ················Your·password·has·been·successfully·updated!·You·can·now·log·in⏎···············
Your password has been successfully updated! You can now log in with your new password. |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ··············
</AlertDialogDescription> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
</AlertDialogHeader> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
<AlertDialogFooter className="sm:justify-end"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················<AlertDialogCancel·asChild·className='flex·flex-row-reverse'
with ··············<AlertDialogCancel·asChild·className="flex·flex-row-reverse"
<AlertDialogCancel asChild className='flex flex-row-reverse'> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Button·type="button"·variant="default"·className="px-6·font-semibold·bg-[rgba(249,115,22,1)]">
with <Button⏎··················type="button"⏎··················variant="default"⏎··················className="bg-[rgba(249,115,22,1)]·px-6·font-semibold"
<Button type="button" variant="default" className="px-6 font-semibold bg-[rgba(249,115,22,1)]"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········
with ················>⏎
Continue |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ················
</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</AlertDialogCancel> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
</AlertDialogFooter> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
</AlertDialogContent> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
</AlertDialog> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············⏎··
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 225 to 226 in 54e57b0
</Form> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace '~/components/dashboard/PasswordUpdate'
with "~/components/dashboard/PasswordUpdate";
import PasswordUpdate from '~/components/dashboard/PasswordUpdate' |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··<div·className="h-16··grid·
with <div·className="grid·h-16·
<div className="h-16 grid place-items-center font-extrabold">Nav</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
<div className="flex"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<div·className="w-[20%]·h-svh·bg-[rgba(203,213,225,.3)]·grid·place-items-center·font-extrabold·max-lg:hidden">Sidebar
with ········<div·className="grid·h-svh·w-[20%]·place-items-center·bg-[rgba(203,213,225,.3)]·font-extrabold·max-lg:hidden">⏎··········Sidebar⏎········
<div className="w-[20%] h-svh bg-[rgba(203,213,225,.3)] grid place-items-center font-extrabold max-lg:hidden">Sidebar</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ········
<PasswordUpdate /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;⏎
export default DaashboardPasswordSettings |
const hasMinLength = value.length >= 8; | ||
setValidation({ | ||
hasUppercase, | ||
hasNumber, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
hasNumber, | |
hasNumber, |
setValidation({ | ||
hasUppercase, | ||
hasNumber, | ||
hasMinLength |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············hasMinLength
with ······hasMinLength,
hasMinLength | |
hasMinLength, |
}); | ||
}; | ||
|
||
const handleChange = (event: React.ChangeEvent<HTMLInputElement>) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
const handleChange = (event: React.ChangeEvent<HTMLInputElement>) => { | |
const handleChange = (event: React.ChangeEvent<HTMLInputElement>) => { |
const handleChange = (event: React.ChangeEvent<HTMLInputElement>) => { | ||
event.preventDefault() | ||
const { name, value } = event.target; | ||
const val: keyof PasswordValues = name as keyof PasswordValues |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········const·val:·keyof·PasswordValues·=·name·as·keyof·PasswordValues
with ····const·val:·keyof·PasswordValues·=·name·as·keyof·PasswordValues;
const val: keyof PasswordValues = name as keyof PasswordValues | |
const val: keyof PasswordValues = name as keyof PasswordValues; |
const val: keyof PasswordValues = name as keyof PasswordValues | ||
|
||
setActualValue((prevActualValue) => ({ | ||
...prevActualValue, | ||
[name]: (actualValue[val] + value.charAt(value.length - 1)).length > value.length ? actualValue[val].slice(0, -1) : actualValue[val] + value.charAt(value.length - 1) | ||
})); | ||
|
||
setDisplayValue((prevDisplayValue) => ({ | ||
...prevDisplayValue, | ||
[name]: '*'.repeat(value.length) | ||
})); | ||
if (name === 'newPassword') { | ||
handlePasswordValidation(actualValue[val]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <unicorn/prevent-abbreviations> reported by reviewdog 🐶
The variable val
should be named value_
. A more descriptive name will do too.
const val: keyof PasswordValues = name as keyof PasswordValues | |
setActualValue((prevActualValue) => ({ | |
...prevActualValue, | |
[name]: (actualValue[val] + value.charAt(value.length - 1)).length > value.length ? actualValue[val].slice(0, -1) : actualValue[val] + value.charAt(value.length - 1) | |
})); | |
setDisplayValue((prevDisplayValue) => ({ | |
...prevDisplayValue, | |
[name]: '*'.repeat(value.length) | |
})); | |
if (name === 'newPassword') { | |
handlePasswordValidation(actualValue[val]); | |
const value_: keyof PasswordValues = name as keyof PasswordValues | |
setActualValue((prevActualValue) => ({ | |
...prevActualValue, | |
[name]: (actualValue[value_] + value.charAt(value.length - 1)).length > value.length ? actualValue[value_].slice(0, -1) : actualValue[value_] + value.charAt(value.length - 1) | |
})); | |
setDisplayValue((prevDisplayValue) => ({ | |
...prevDisplayValue, | |
[name]: '*'.repeat(value.length) | |
})); | |
if (name === 'newPassword') { | |
handlePasswordValidation(actualValue[value_]); |
|
||
setDisplayValue((prevDisplayValue) => ({ | ||
...prevDisplayValue, | ||
[name]: '*'.repeat(value.length) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············[name]:·'*'.repeat(value.length)
with ······[name]:·"*".repeat(value.length),
[name]: '*'.repeat(value.length) | |
[name]: "*".repeat(value.length), |
...prevDisplayValue, | ||
[name]: '*'.repeat(value.length) | ||
})); | ||
if (name === 'newPassword') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········if·(name·===·'newPassword'
with ····if·(name·===·"newPassword"
if (name === 'newPassword') { | |
if (name === "newPassword") { |
[name]: '*'.repeat(value.length) | ||
})); | ||
if (name === 'newPassword') { | ||
handlePasswordValidation(actualValue[val]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
handlePasswordValidation(actualValue[val]); | |
handlePasswordValidation(actualValue[val]); |
|
||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ·····⏎····
}; | |
}; |
|
||
}; | ||
useEffect(() => { | ||
const inputs = document.querySelectorAll<HTMLInputElement>('.psw-input'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········const·inputs·=·document.querySelectorAll<HTMLInputElement>('.psw-input'
with ····const·inputs·=·document.querySelectorAll<HTMLInputElement>(".psw-input"
const inputs = document.querySelectorAll<HTMLInputElement>('.psw-input'); | |
const inputs = document.querySelectorAll<HTMLInputElement>(".psw-input"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
eslint
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····
with ··
useEffect(() => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
inputs.forEach((element) => { |
🚫 [eslint] <unicorn/no-array-for-each> reported by reviewdog 🐶
Use for…of
instead of .forEach(…)
.
inputs.forEach((element) => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
element.addEventListener( |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····'select'
with "select"
'select', |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ········
function () { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
this.select = () => {}; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
this.selectionStart = this.selectionEnd; |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············false
with ········false,
false |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
}, []); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··<h1·className="text-[rgba(20,20,20,1)]·font-bold·text-2xl·mb-1·mt-10">Password·Settings
with <h1·className="mb-1·mt-10·text-2xl·font-bold·text-[rgba(20,20,20,1)]">⏎········Password·Settings⏎······
<h1 className="text-[rgba(20,20,20,1)] font-bold text-2xl mb-1 mt-10">Password Settings</h1> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<p·className="text-[rgba(67,67,67,1)]·mb-5·text-base">Update·password·for·enhanced·account·security
with ······<p·className="mb-5·text-base·text-[rgba(67,67,67,1)]">⏎········Update·password·for·enhanced·account·security⏎······
<p className="text-[rgba(67,67,67,1)] mb-5 text-base">Update password for enhanced account security</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Form·className="w-2/3·max-md:w-5/6·flex·flex-col·gap-4
with ······<Form·className="flex·w-2/3·flex-col·gap-4·max-md:w-5/6
<Form className="w-2/3 max-md:w-5/6 flex flex-col gap-4"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<p className="text-base text-[rgba(67,67,67,1)]">Current Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<div·className={
border-[1px]·${actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·'border-[rgba(220,38,38,1)]'·:·'border-[rgba(147,147,147,1)]'}·rounded-lg·select-none·flex·justify-between·items-center·p-1·pr-5}>
with ····<div⏎············className={
border-[1px]·${actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·"border-[rgba(220,38,38,1)]"·:·"border-[rgba(147,147,147,1)]"}·flex·select-none·items-center·justify-between·rounded-lg·p-1·pr-5}
<div className={`border-[1px] ${actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <unicorn/explicit-length-check> reported by reviewdog 🐶
Use .length > 0
when checking length is not zero.
<div className={`border-[1px] ${actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ···········<input·
with ·>⏎············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="currentPassword"·
with ··············name="currentPassword"
name="currentPassword" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········value={showPassword·?·actualValue.currentPassword·:·displayValue.currentPassword}·⏎························onChange={handleChange}·
with value={⏎················showPassword⏎··················?·actualValue.currentPassword⏎··················:·displayValue.currentPassword⏎··············}⏎··············onChange={handleChange}
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 88 to 89 in 4275707
value={showPassword ? actualValue.currentPassword : displayValue.currentPassword} | |
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
placeholder="Enter current password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················{·!showPassword·?·
with ············{!showPassword·?·(
{ !showPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowPassword(!showPassword)}/>·⏎························:·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowPassword(!showPassword)}⏎··············/>⏎············)·:·(
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 95 to 96 in 4275707
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowPassword(!showPassword)}/> | |
: |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowPassword(!showPassword)}·/>·
with ··<Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowPassword(!showPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowPassword(!showPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············)}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······{⏎····················actualValue.currentPassword.length·<·5·&&·actualValue.currentPassword.length·!=·0·?·
with {actualValue.currentPassword.length·<·5·&&⏎··········actualValue.currentPassword.length·!=·0·?·(
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 101 to 102 in 4275707
{ | |
actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? |
🚫 [eslint] <unicorn/explicit-length-check> reported by reviewdog 🐶
Use .length > 0
when checking length is not zero.
actualValue.currentPassword.length < 5 && actualValue.currentPassword.length != 0 ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ·········<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">Invalid·password</p>·
with <p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">⏎··············Invalid·password
<p className="text-sm font-[500] text-[rgba(220,38,38,1)]">Invalid password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········:·
with </p>
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················null⏎················}·
with ··········)·:·null}
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 105 to 106 in 4275707
null | |
} |
🚫 [eslint] <unicorn/no-null> reported by reviewdog 🐶
Use undefined
instead of null
.
null |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ················⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 107 to 108 in 4275707
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····<label·className="flex·flex-col·gap-2·
with <label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<p className="text-base text-[rgba(67,67,67,1)]">New Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className="border-[1px]·border-[rgba(147,147,147,1)]·rounded-lg·select-none·flex·justify-between·items-center·
with <div·className="flex·select-none·items-center·justify-between·rounded-lg·border-[1px]·border-[rgba(147,147,147,1)]·
<div className="border-[1px] border-[rgba(147,147,147,1)] rounded-lg select-none flex justify-between items-center p-1 pr-5"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················<input·
with ············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="newPassword"·
with ··············name="newPassword"
name="newPassword" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········value={showNewPassword·?·actualValue.newPassword·:·displayValue.newPassword}·
with value={⏎················showNewPassword⏎··················?·actualValue.newPassword⏎··················:·displayValue.newPassword
value={showNewPassword ? actualValue.newPassword : displayValue.newPassword} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········onChange={handleChange}·
with }⏎··············onChange={handleChange}
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
placeholder="Enter new password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························onFocus={·
with ··············onFocus={
onFocus={ () => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
// setIsFocused(true); |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with ··············className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················{·!showNewPassword·?·
with ············{!showNewPassword·?·(
{ !showNewPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showNewPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowNewPassword(!showNewPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowNewPassword(!showNewPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowNewPassword(!showNewPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········:·
with />⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowNewPassword(!showNewPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowNewPassword(!showNewPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowNewPassword(!showNewPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············)}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
{displayValue.newPassword.length > 0 && ( |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
<div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
<div className="flex gap-3"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasUppercase·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}
with <span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasUppercase·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}⏎················
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasUppercase ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasNumber·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}
with <span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasNumber·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}⏎················
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasNumber ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<span·className={
w-24·rounded·h-1·${actualValue.newPassword.length·>·0·?·(validation.hasMinLength·?·'bg-[rgba(109,195,71,1)]'·:·'bg-[rgba(220,38,38,1)]')·:·'bg-[rgba(182,182,182,1)]'·}·flex}></span>
with <span⏎··················className={
h-1·w-24·rounded·${actualValue.newPassword.length·>·0·?·(validation.hasMinLength·?·"bg-[rgba(109,195,71,1)]"·:·"bg-[rgba(220,38,38,1)]")·:·"bg-[rgba(182,182,182,1)]"}·flex}
<span className={`w-24 rounded h-1 ${actualValue.newPassword.length > 0 ? (validation.hasMinLength ? 'bg-[rgba(109,195,71,1)]' : 'bg-[rgba(220,38,38,1)]') : 'bg-[rgba(182,182,182,1)]' } flex`}></span> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ></span>⏎··············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
<div className="mt-3 grid gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<p·className="text-sm·mb-1
with <p·className="mb-1·text-sm
<p className="text-sm mb-1">Weak password. Must contain;</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··············{validation.hasUppercase·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with {validation.hasUppercase·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasUppercase ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert )}⏎····
<p className="text-sm">At least 1 uppercase</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ································{validation.hasNumber·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with ··················{validation.hasNumber·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasNumber ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··)}⏎··················
<p className="text-sm">At least 1 number</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························
with ················
<div className="flex gap-2"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ································{validation.hasMinLength·?·<CircleCheck·color="rgba(109,195,71,1)"·/>·:·<CircleCheck·color="rgba(220,38,38,1)"·/>}
with ··················{validation.hasMinLength·?·(⏎····················<CircleCheck·color="rgba(109,195,71,1)"·/>⏎··················)·:·(⏎····················<CircleCheck·color="rgba(220,38,38,1)"·/>
{validation.hasMinLength ? <CircleCheck color="rgba(109,195,71,1)" /> : <CircleCheck color="rgba(220,38,38,1)" />} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert )}⏎····
<p className="text-sm">At least 8 characters</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········⏎············
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 156 to 157 in 4275707
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<label·className="flex·flex-col·gap-2·
with ········<label·className="flex·flex-col·gap-2
<label className="flex flex-col gap-2 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<p className="text-base text-[rgba(67,67,67,1)]">Confirm Password</p> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<div·className={
border-[1px]·${actualValue.confirmPassword.length·>·0·?·(actualValue.newPassword·!=·actualValue.confirmPassword·?·'border-[rgba(220,38,38,1)]'·:·'border-[rgba(147,147,147,1)]')·:·'border-[rgba(147,147,147,1)]'}·rounded-lg·select-none·flex·justify-between·items-center·p-1·pr-5}>
with <div⏎············className={
border-[1px]·${actualValue.confirmPassword.length·>·0·?·(actualValue.newPassword·!=·actualValue.confirmPassword·?·"border-[rgba(220,38,38,1)]"·:·"border-[rgba(147,147,147,1)]")·:·"border-[rgba(147,147,147,1)]"}·flex·select-none·items-center·justify-between·rounded-lg·p-1·pr-5}
<div className={`border-[1px] ${actualValue.confirmPassword.length > 0 ? (actualValue.newPassword != actualValue.confirmPassword ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]') : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
<div className={`border-[1px] ${actualValue.confirmPassword.length > 0 ? (actualValue.newPassword != actualValue.confirmPassword ? 'border-[rgba(220,38,38,1)]' : 'border-[rgba(147,147,147,1)]') : 'border-[rgba(147,147,147,1)]'} rounded-lg select-none flex justify-between items-center p-1 pr-5`}> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<input·
with >⏎············<input
<input |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························type="text"·
with ··············type="text"
type="text" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························name="confirmPassword"·
with ··············name="confirmPassword"
name="confirmPassword" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········value={showConfirmPassword·?·actualValue.confirmPassword·:·displayValue.confirmPassword}·
with value={⏎················showConfirmPassword⏎··················?·actualValue.confirmPassword⏎··················:·displayValue.confirmPassword
value={showConfirmPassword ? actualValue.confirmPassword : displayValue.confirmPassword} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ····}⏎
onChange={handleChange} |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
placeholder="Enter confirm password" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········className="psw-input·text-[rgba(147,147,147,1)]·bg-transparent·hi·rounded-lg·w-11/12·bg-slate-600·h-12·!select-none·border-none·outline-none·px-5
with className="psw-input·hi·h-12·w-11/12·!select-none·rounded-lg·border-none·bg-slate-600·bg-transparent·px-5·text-[rgba(147,147,147,1)]·outline-none
className="psw-input text-[rgba(147,147,147,1)] bg-transparent hi rounded-lg w-11/12 bg-slate-600 h-12 !select-none border-none outline-none px-5" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····················
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················{·!showConfirmPassword·?·
with ············{!showConfirmPassword·?·(
{ !showConfirmPassword ? |
🚫 [eslint] <unicorn/no-negated-condition> reported by reviewdog 🐶
Unexpected negated condition.
{ !showConfirmPassword ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<EyeOff·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}/>·
with <EyeOff⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}
<EyeOff size={24} color="rgba(147,147,147,1)" onClick={() => setShowConfirmPassword(!showConfirmPassword)}/> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ···········:·
with ·/>⏎············)·:·(
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Eye·size={24}·color="rgba(147,147,147,1)"·onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}·/>·
with <Eye⏎················size={24}⏎················color="rgba(147,147,147,1)"⏎················onClick={()·=>·setShowConfirmPassword(!showConfirmPassword)}
<Eye size={24} color="rgba(147,147,147,1)" onClick={() => setShowConfirmPassword(!showConfirmPassword)} /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······}
with />
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with )}
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······{⏎····················actualValue.confirmPassword.length·>·0·?·
with {actualValue.confirmPassword.length·>·0
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 178 to 179 in 4275707
{ | |
actualValue.confirmPassword.length > 0 ? |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········(actualValue.newPassword·!=·actualValue.confirmPassword·&&·<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">Password·does·not·match</p>)·
with ?·actualValue.newPassword·!=·actualValue.confirmPassword·&&·(⏎················<p·className="text-sm·font-[500]·text-[rgba(220,38,38,1)]">⏎··················Password·does·not·match
(actualValue.newPassword != actualValue.confirmPassword && <p className="text-sm font-[500] text-[rgba(220,38,38,1)]">Password does not match</p>) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····:·
with </p>
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ···········null⏎················}·
with ·····)⏎············:·null}
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 182 to 183 in 4275707
null | |
} |
🚫 [eslint] <unicorn/no-null> reported by reviewdog 🐶
Use undefined
instead of null
.
null |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 184 to 185 in 4275707
</label> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ⏎····
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 187 to 188 in 4275707
<AlertDialog> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················⏎················<div·className="flex·gap-5·mt-6·
with ··········<div·className="mt-6·flex·gap-5
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 189 to 190 in 4275707
<div className="flex gap-5 mt-6 "> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Button·type="submit"·variant="outline"·size="default"·className="w-24·h-12·text-base·bg-transparent·font-bold·text-black·rounded-lg">Cancel
with <Button⏎··············type="submit"⏎··············variant="outline"⏎··············size="default"⏎··············className="h-12·w-24·rounded-lg·bg-transparent·text-base·font-bold·text-black"⏎············>⏎··············Cancel⏎············
<Button type="submit" variant="outline" size="default" className="w-24 h-12 text-base bg-transparent font-bold text-black rounded-lg">Cancel</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
<AlertDialogTrigger asChild> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········<Button·
with <Button
<Button |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············type="submit"·
with type="submit"
type="submit" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························onClick={()·=>·{·
with ················onClick={()·=>·{
onClick={() => { |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ································setActualValue({currentPassword:·'',·newPassword:·'',·confirmPassword:·''})·⏎································setDisplayValue({currentPassword:·'',·newPassword:·'',·confirmPassword:·''})
with ··················setActualValue({⏎····················currentPassword:·"",⏎····················newPassword:·"",⏎····················confirmPassword:·"",⏎··················});⏎··················setDisplayValue({⏎····················currentPassword:·"",⏎····················newPassword:·"",⏎····················confirmPassword:·"",
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 196 to 197 in 4275707
setActualValue({currentPassword: '', newPassword: '', confirmPassword: ''}) | |
setDisplayValue({currentPassword: '', newPassword: '', confirmPassword: ''}) |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········}}·⏎····························variant="default"·
with });⏎················}}⏎················variant="default"
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 198 to 199 in 4275707
}} | |
variant="default" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························size="default"·
with ················size="default"
size="default" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····························className="w-44·h-12·text-base·bg-[rgba(249,115,22,1)]·font-bold·text-white·rounded-lg
with ················className="h-12·w-44·rounded-lg·bg-[rgba(249,115,22,1)]·text-base·font-bold·text-white
className="w-44 h-12 text-base bg-[rgba(249,115,22,1)] font-bold text-white rounded-lg" |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············
Update Password |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ··············
</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
</AlertDialogTrigger> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··········⏎················
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 206 to 207 in 4275707
</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
<AlertDialogContent className="sm:max-w-md"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
<AlertDialogHeader> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ······<AlertDialogTitle>Password·Successfully·Updated!
with <AlertDialogTitle>⏎················Password·Successfully·Updated!⏎··············
<AlertDialogTitle>Password Successfully Updated!</AlertDialogTitle> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ··············
<AlertDialogDescription> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························Your·password·has·been·successfully·updated!·You·can·now·log·in
with ················Your·password·has·been·successfully·updated!·You·can·now·log·in⏎···············
Your password has been successfully updated! You can now log in with your new password. |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ··············
</AlertDialogDescription> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ········
</AlertDialogHeader> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
<AlertDialogFooter className="sm:justify-end"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················<AlertDialogCancel·asChild·className='flex·flex-row-reverse'
with ··············<AlertDialogCancel·asChild·className="flex·flex-row-reverse"
<AlertDialogCancel asChild className='flex flex-row-reverse'> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········<Button·type="button"·variant="default"·className="px-6·font-semibold·bg-[rgba(249,115,22,1)]">
with <Button⏎··················type="button"⏎··················variant="default"⏎··················className="bg-[rgba(249,115,22,1)]·px-6·font-semibold"
<Button type="button" variant="default" className="px-6 font-semibold bg-[rgba(249,115,22,1)]"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··········
with ················>⏎
Continue |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ························
with ················
</Button> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
</AlertDialogCancel> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····················
with ············
</AlertDialogFooter> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ················
with ··········
</AlertDialogContent> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
</AlertDialog> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ············⏎··
hng_boilerplate_remix/app/components/dashboard/PasswordUpdate.tsx
Lines 225 to 226 in 4275707
</Form> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace '~/components/dashboard/PasswordUpdate'
with "~/components/dashboard/PasswordUpdate";
import PasswordUpdate from '~/components/dashboard/PasswordUpdate' |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ··<div·className="h-16··grid·
with <div·className="grid·h-16·
<div className="h-16 grid place-items-center font-extrabold">Nav</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
<div className="flex"> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············<div·className="w-[20%]·h-svh·bg-[rgba(203,213,225,.3)]·grid·place-items-center·font-extrabold·max-lg:hidden">Sidebar
with ········<div·className="grid·h-svh·w-[20%]·place-items-center·bg-[rgba(203,213,225,.3)]·font-extrabold·max-lg:hidden">⏎··········Sidebar⏎········
<div className="w-[20%] h-svh bg-[rgba(203,213,225,.3)] grid place-items-center font-extrabold max-lg:hidden">Sidebar</div> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ········
<PasswordUpdate /> |
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert ;⏎
export default DaashboardPasswordSettings |
import { useEffect, useState } from "react"; | ||
import { Form } from "@remix-run/react"; | ||
import { CircleCheck, Eye, EyeOff } from "lucide-react"; | ||
import { Button } from "../ui/button"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace Button·}·from·"../ui/button";
with useEffect,·useState·}·from·"react";⏎
import { Button } from "../ui/button"; | |
import { useEffect, useState } from "react"; | |
import { Form } from "@remix-run/react"; | ||
import { CircleCheck, Eye, EyeOff } from "lucide-react"; | ||
import { Button } from "../ui/button"; | ||
import { AlertDialog, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle, AlertDialogTrigger } from "../ui/alert-dialog"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ·AlertDialog,·AlertDialogCancel,·AlertDialogContent,·AlertDialogDescription,·AlertDialogFooter,·AlertDialogHeader,·AlertDialogTitle,·AlertDialogTrigger·
with ⏎··AlertDialog,⏎··AlertDialogCancel,⏎··AlertDialogContent,⏎··AlertDialogDescription,⏎··AlertDialogFooter,⏎··AlertDialogHeader,⏎··AlertDialogTitle,⏎··AlertDialogTrigger,⏎
import { AlertDialog, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle, AlertDialogTrigger } from "../ui/alert-dialog"; | |
import { | |
AlertDialog, | |
AlertDialogCancel, | |
AlertDialogContent, | |
AlertDialogDescription, | |
AlertDialogFooter, | |
AlertDialogHeader, | |
AlertDialogTitle, | |
AlertDialogTrigger, | |
} from "../ui/alert-dialog"; |
import { AlertDialog, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle, AlertDialogTrigger } from "../ui/alert-dialog"; | ||
|
||
interface PasswordValues { | ||
currentPassword: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····
with ··
currentPassword: string; | |
currentPassword: string; |
|
||
interface PasswordValues { | ||
currentPassword: string; | ||
newPassword: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··
newPassword: string; | |
newPassword: string; |
interface PasswordValues { | ||
currentPassword: string; | ||
newPassword: string; | ||
confirmPassword: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ····
with ··
confirmPassword: string; | |
confirmPassword: string; |
const { name, value } = event.target; | ||
const val: keyof PasswordValues = name as keyof PasswordValues | ||
|
||
setActualValue((prevActualValue) => ({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
setActualValue((prevActualValue) => ({ | |
setActualValue((prevActualValue) => ({ |
const val: keyof PasswordValues = name as keyof PasswordValues | ||
|
||
setActualValue((prevActualValue) => ({ | ||
...prevActualValue, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ······
...prevActualValue, | |
...prevActualValue, |
setActualValue((prevActualValue) => ({ | ||
...prevActualValue, | ||
[name]: (actualValue[val] + value.charAt(value.length - 1)).length > value.length ? actualValue[val].slice(0, -1) : actualValue[val] + value.charAt(value.length - 1) | ||
})); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ····
})); | |
})); |
[name]: (actualValue[val] + value.charAt(value.length - 1)).length > value.length ? actualValue[val].slice(0, -1) : actualValue[val] + value.charAt(value.length - 1) | ||
})); | ||
|
||
setDisplayValue((prevDisplayValue) => ({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ········
with ····
setDisplayValue((prevDisplayValue) => ({ | |
setDisplayValue((prevDisplayValue) => ({ |
})); | ||
|
||
setDisplayValue((prevDisplayValue) => ({ | ||
...prevDisplayValue, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ············
with ······
...prevDisplayValue, | |
...prevDisplayValue, |
… functionality-finalv0.5)
… functionality-finalv0.5:fixed-lint-issues)
4275707
to
ae70e8d
Compare
Descripition
This is prior to issue-116 which is the dashboard password settings page.
pnpm lint
resultImplementation preview