Reformat all project files to use the prettier config file.

This commit is contained in:
Patrick Fic
2024-03-27 15:35:07 -07:00
parent b161530381
commit e1df64d592
873 changed files with 111387 additions and 125473 deletions

View File

@@ -1,33 +1,33 @@
import {useQuery} from "@apollo/client";
import {Select} from "antd";
import React, {forwardRef} from "react";
import {QUERY_TEAMS} from "../../graphql/employee_teams.queries";
import { useQuery } from "@apollo/client";
import { Select } from "antd";
import React, { forwardRef } from "react";
import { QUERY_TEAMS } from "../../graphql/employee_teams.queries";
import AlertComponent from "../alert/alert.component";
//To be used as a form element only.
const EmployeeTeamSearchSelect = ({...props}, ref) => {
const {loading, error, data} = useQuery(QUERY_TEAMS);
const EmployeeTeamSearchSelect = ({ ...props }, ref) => {
const { loading, error, data } = useQuery(QUERY_TEAMS);
if (error) return <AlertComponent message={JSON.stringify(error)}/>;
return (
<Select
showSearch
allowClear
loading={loading}
style={{
width: 400,
}}
options={
data
? data.employee_teams.map((e) => ({
value: JSON.stringify(e),
label: e.name,
}))
: []
}
{...props}
/>
);
if (error) return <AlertComponent message={JSON.stringify(error)} />;
return (
<Select
showSearch
allowClear
loading={loading}
style={{
width: 400
}}
options={
data
? data.employee_teams.map((e) => ({
value: JSON.stringify(e),
label: e.name
}))
: []
}
{...props}
/>
);
};
export default forwardRef(EmployeeTeamSearchSelect);