added a linux checker

This commit is contained in:
2023-11-28 21:02:17 -08:00
parent 327a4a42ae
commit 8707411dda
+10 -7
View File
@@ -24,10 +24,7 @@ function AddJob({ popUpHandler, categories }) {
let dispatch = useDispatch();
const getWalletDetails = getWalletDetail(
userDetails.country,
walletDetails
);
const getWalletDetails = getWalletDetail(userDetails.country, walletDetails);
const walletAmount = getWalletDetails; // GETTING USER BALANCE BASED ON COUNTRY SELECTED
const initialValues = { ...IV, country: walletAmount?.description };
const [requestStatus, setRequestStatus] = useState(initialReqState); // Holds state when submit button is pressed
@@ -83,6 +80,9 @@ function AddJob({ popUpHandler, categories }) {
// Check if the user is using iOS
const isIOS = /MacIntel|MacPPC/.test(navigator.platform) && !window.MSStream;
// Check if the user is using Linux
const isLinux = /Linux/.test(navigator.platform);
// Check if the user is using Windows
const isWindows = /Windows/.test(navigator.userAgent);
@@ -187,7 +187,7 @@ function AddJob({ popUpHandler, categories }) {
<div className="sm:w-[60%] w-full">
<label
htmlFor="Job Delivery Details"
className='input-label text-[#181c32] dark:text-white text-[13.975px] leading-[20.9625px] font-semibold flex items-center gap-1'
className="input-label text-[#181c32] dark:text-white text-[13.975px] leading-[20.9625px] font-semibold flex items-center gap-1"
>
Job Delivery Details
{props.errors.job_detail &&
@@ -214,13 +214,16 @@ function AddJob({ popUpHandler, categories }) {
htmlFor="Job Categories"
className="input-label text-[#181c32] dark:text-white text-[13.975px] leading-[20.9625px] font-semibold flex item-center gap-1"
>
Categories ({`multiple categories - ${isIOS ? "⌘" : isWindows ? "Ctrl+" : ""}`})
Categories (
{`multiple categories - ${
isIOS ? "⌘" : isWindows | isLinux ? "Ctrl+" : ""
}`}
)
{props.errors.category && props.touched.category && (
<span className="text-[12px] text-red-500">
{props.errors.category}
</span>
)}
</label>
<select
id="category"