Skip to content

Commit

Permalink
refactor: minor code clean-up
Browse files Browse the repository at this point in the history
Co-authored-by: Linus Gasser <[email protected]>
  • Loading branch information
PascalinDe and ineiti authored Jul 10, 2024
1 parent 0437042 commit 7cd2cf3
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions web/frontend/src/pages/form/components/FormRow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@ const SUBJECT_ELECTION = 'election';
const ACTION_CREATE = 'create';

const FormRow: FC<FormRowProps> = ({ form }) => {
const Blocklist = process.env.REACT_APP_BLOCKLIST
? process.env.REACT_APP_BLOCKLIST.split(',')
: [];
const Blocklist = process.env.REACT_APP_BLOCKLIST?.split(',') ?? [];
const [titles, setTitles] = useState<any>({});
const authCtx = useContext(AuthContext);
useEffect(() => {
Expand All @@ -41,8 +39,8 @@ const FormRow: FC<FormRowProps> = ({ form }) => {
? 'text-gray-700 hover:text-gray-700'
: 'text-gray-700 hover:text-[#ff0000]';
const styleBox = isBlocked
? 'bg-gray-200 border-b hover: bg-gray-200'
: 'bg-white border-b hover:bg-gray-50 ';
? 'bg-gray-200 border-b hover:bg-gray-200'
: 'bg-white border-b hover:bg-gray-50';

return (
<tr className={styleBox}>
Expand Down

0 comments on commit 7cd2cf3

Please sign in to comment.