add linter
This commit is contained in:
@@ -1,11 +1,9 @@
|
||||
import React, {FC, useEffect, useState} from "react";
|
||||
import useAxiosTools from "../../hooks/AxiosTools";
|
||||
import {toDo} from "../../utilities/types";
|
||||
import {Link} from "react-router-dom";
|
||||
import useTracker from "../../hooks/TraskerHook";
|
||||
import {Simulate} from "react-dom/test-utils";
|
||||
import load = Simulate.load;
|
||||
import {DraggableSVG, PauseSVG, PlaySVG} from "../SVG";
|
||||
import React, {FC, useEffect, useState} from "react"
|
||||
import useAxiosTools from "../../hooks/AxiosTools"
|
||||
import {toDo} from "../../utilities/types"
|
||||
import {Link} from "react-router-dom"
|
||||
import useTracker from "../../hooks/TraskerHook"
|
||||
import {DraggableSVG, PauseSVG, PlaySVG} from "../SVG"
|
||||
|
||||
const ToDoIndex: FC<ToDoIndexProps> = ({reload, setReload}) => {
|
||||
|
||||
@@ -21,7 +19,7 @@ const ToDoIndex: FC<ToDoIndexProps> = ({reload, setReload}) => {
|
||||
if (reload && !loading) {
|
||||
fetchToDos()
|
||||
}
|
||||
}, [reload]);
|
||||
}, [reload])
|
||||
|
||||
const fetchToDos = async () => {
|
||||
try {
|
||||
@@ -57,18 +55,18 @@ const ToDoIndex: FC<ToDoIndexProps> = ({reload, setReload}) => {
|
||||
onChange={() =>toggleCheck(toDo)}
|
||||
className=""/>
|
||||
<Link to={"/todos/" + toDo.id}
|
||||
className={`${toDo.checked ? 'line-through' : ''} flex-1 flex justify-between`}>
|
||||
className={`${toDo.checked ? 'line-through' : ''} flex flex-1 justify-between`}>
|
||||
<span>{toDo.name}</span>
|
||||
<span className="text-gray-400 text-md mr-2">{toDo.duration.durationify()}</span>
|
||||
<span className="mr-2 text-sm text-gray-400">{toDo.duration.durationify()}</span>
|
||||
</Link>
|
||||
{toDo.id === currentTimeTracker?.to_do?.id
|
||||
? <button className="cursor-pointer w-7 justify-center flex items-center"
|
||||
? <button className="flex w-7 cursor-pointer items-center justify-center"
|
||||
type="button"
|
||||
title="Commencer"
|
||||
onClick={stopCurrentTimeTrack}>
|
||||
<PauseSVG className="w-7"/>
|
||||
</button>
|
||||
: <button className="cursor-pointer w-7 justify-center flex items-center"
|
||||
: <button className="flex w-7 cursor-pointer items-center justify-center"
|
||||
type="button"
|
||||
title="Commencer"
|
||||
onClick={() => startTrackToDo(toDo)}>
|
||||
|
||||
Reference in New Issue
Block a user