mirror of
https://github.com/LucasVbr/todo-list.git
synced 2026-05-13 17:22:04 +00:00
fix: Update Dependencies
This commit is contained in:
@@ -1,14 +0,0 @@
|
||||
module.exports = {
|
||||
env: { browser: true, es2020: true },
|
||||
extends: [
|
||||
'eslint:recommended',
|
||||
'plugin:@typescript-eslint/recommended',
|
||||
'plugin:react-hooks/recommended',
|
||||
],
|
||||
parser: '@typescript-eslint/parser',
|
||||
parserOptions: { ecmaVersion: 'latest', sourceType: 'module' },
|
||||
plugins: ['react-refresh'],
|
||||
rules: {
|
||||
'react-refresh/only-export-components': 'warn',
|
||||
},
|
||||
}
|
||||
+1
-1
@@ -15,7 +15,7 @@ dist-ssr
|
||||
# Editor directories and files
|
||||
.vscode/*
|
||||
!.vscode/extensions.json
|
||||
.idea
|
||||
.idea/
|
||||
.DS_Store
|
||||
*.suo
|
||||
*.ntvs*
|
||||
|
||||
|
Before Width: | Height: | Size: 322 KiB After Width: | Height: | Size: 322 KiB |
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
SOFTWARE.
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
### 🏠 [Homepage](https://todo-list-lucasvbr.vercel.app/)
|
||||
|
||||
<kbd>
|
||||
<img src="preview.png" alt="preview picture"/>
|
||||
<img src=".readme/preview.png" alt="preview picture"/>
|
||||
</kbd>
|
||||
|
||||
## Author
|
||||
@@ -34,4 +34,4 @@ Give a ⭐️ if this project helped you!
|
||||
Copyright © 2023 [LucasVbr](https://github.com/LucasVbr).<br />
|
||||
This project is [MIT](./LICENCE) licensed.
|
||||
|
||||
[//]: # (_This README was generated with ❤️ by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_)
|
||||
[//]: # (_This README was generated with ❤️ by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_)
|
||||
|
||||
+10
-10
@@ -1,13 +1,13 @@
|
||||
<!DOCTYPE html>
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<link rel="icon" type="image/svg+xml" href="/icons/plus.svg" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<head>
|
||||
<meta charset="UTF-8"/>
|
||||
<link rel="icon" type="image/svg+xml" href="/plus.svg"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<title>Todo List App</title>
|
||||
</head>
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
<script type="module" src="/src/main.tsx"></script>
|
||||
</body>
|
||||
</head>
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
<script type="module" src="/src/main.tsx"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Generated
+1106
-1653
File diff suppressed because it is too large
Load Diff
+18
-19
@@ -5,33 +5,32 @@
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
"dev-host": "vite --host",
|
||||
"build": "tsc && vite build",
|
||||
"lint": "eslint src --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
|
||||
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
|
||||
"preview": "vite preview"
|
||||
},
|
||||
"dependencies": {
|
||||
"@heroicons/react": "^2.0.18",
|
||||
"@reduxjs/toolkit": "^1.9.5",
|
||||
"@heroicons/react": "^2.1.3",
|
||||
"@reduxjs/toolkit": "^2.2.3",
|
||||
"react": "^18.2.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"react-redux": "^8.1.0"
|
||||
"react-redux": "^9.1.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/react": "^18.0.37",
|
||||
"@types/react-dom": "^18.0.11",
|
||||
"@typescript-eslint/eslint-plugin": "^5.59.0",
|
||||
"@typescript-eslint/parser": "^5.59.0",
|
||||
"@vitejs/plugin-react-swc": "^3.0.0",
|
||||
"autoprefixer": "^10.4.14",
|
||||
"clsx": "^1.2.1",
|
||||
"daisyui": "^3.1.0",
|
||||
"eslint": "^8.38.0",
|
||||
"@types/react": "^18.2.66",
|
||||
"@types/react-dom": "^18.2.22",
|
||||
"@typescript-eslint/eslint-plugin": "^7.2.0",
|
||||
"@typescript-eslint/parser": "^7.2.0",
|
||||
"@vitejs/plugin-react-swc": "^3.5.0",
|
||||
"autoprefixer": "^10.4.19",
|
||||
"clsx": "latest",
|
||||
"daisyui": "latest",
|
||||
"eslint": "^8.57.0",
|
||||
"eslint-plugin-react-hooks": "^4.6.0",
|
||||
"eslint-plugin-react-refresh": "^0.3.4",
|
||||
"postcss": "^8.4.24",
|
||||
"tailwindcss": "^3.3.2",
|
||||
"typescript": "^5.0.2",
|
||||
"vite": "^4.3.9"
|
||||
"eslint-plugin-react-refresh": "^0.4.6",
|
||||
"postcss": "^8.4.38",
|
||||
"tailwindcss": "^3.4.3",
|
||||
"typescript": "^5.2.2",
|
||||
"vite": "^5.2.0"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
module.exports = {
|
||||
plugins: [require('tailwindcss'), require('autoprefixer')],
|
||||
};
|
||||
@@ -0,0 +1,6 @@
|
||||
export default {
|
||||
plugins: {
|
||||
tailwindcss: {},
|
||||
autoprefixer: {},
|
||||
},
|
||||
}
|
||||
|
Before Width: | Height: | Size: 227 B After Width: | Height: | Size: 227 B |
+9
-9
@@ -1,18 +1,18 @@
|
||||
import Navbar from './components/Navbar.tsx';
|
||||
import Footer from './components/Footer.tsx';
|
||||
import TodoCard from './components/todo/TodoCard.tsx';
|
||||
import TodoCard from './components/todos/TodoCard.tsx';
|
||||
|
||||
export default function App() {
|
||||
|
||||
return (
|
||||
<div className={"w-screen min-h-screen bg-base-300"}>
|
||||
<Navbar/>
|
||||
<div className={"min-h-screen bg-base-300"}>
|
||||
<Navbar/>
|
||||
|
||||
<main className={"w-full min-h-screen flex justify-center items-center"}>
|
||||
<TodoCard/>
|
||||
</main>
|
||||
<main className={"w-full min-h-screen flex justify-center items-center"}>
|
||||
<TodoCard/>
|
||||
</main>
|
||||
|
||||
<Footer/>
|
||||
</div>
|
||||
<Footer/>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,14 @@
|
||||
export default function Footer() {
|
||||
return (
|
||||
<footer className={"Footer footer w-screen absolute bottom-0 p-4"}>
|
||||
<footer className={"Footer footer sticky bottom-0 py-4"}>
|
||||
<p className={"inline-block w-full text-center"}>
|
||||
MIT Licence © 2023 • <a className={"link link-hover"} href={"https://github.com/LucasVbr/todo-list"} target={"_blank"}>See code on GitHub</a>
|
||||
<span className={"badge badge-md"}>
|
||||
MIT Licence © 2023 •
|
||||
<a className={"link link-hover"} href={"https://github.com/LucasVbr/todo-list"} target={"_blank"}>
|
||||
See code on GitHub
|
||||
</a>
|
||||
</span>
|
||||
</p>
|
||||
</footer>
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,4 +10,4 @@ export default function Navbar() {
|
||||
</button>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,12 +17,12 @@ export default function TodoAddItemForm() {
|
||||
return (
|
||||
<form onSubmit={handleSubmit} className={'TodoAddItemForm'}>
|
||||
<div className={'form-control'}>
|
||||
<div className={'input-group'}>
|
||||
<div className={'join'}>
|
||||
<input type={'text'} value={name}
|
||||
placeholder={'Type here your task...'}
|
||||
className={'input border-primary w-full'}
|
||||
className={'input border-primary w-full join-item'}
|
||||
onChange={evt => setName(evt.target.value)}/>
|
||||
<button type={'submit'} className={'btn btn-square btn-primary'}>
|
||||
<button type={'submit'} className={'btn btn-square btn-primary join-item'}>
|
||||
<PlusIcon className={"h-6 w-6"}/>
|
||||
</button>
|
||||
</div>
|
||||
@@ -30,4 +30,4 @@ export default function TodoAddItemForm() {
|
||||
</form>
|
||||
);
|
||||
|
||||
}
|
||||
}
|
||||
@@ -10,7 +10,7 @@ export default function TodoCard() {
|
||||
|
||||
return (
|
||||
<div className={clsx('TodoCard',
|
||||
'card max-w-6xl p-5 shadow-xl gap-7 bg-base-100')}>
|
||||
'card max-w-6xl p-5 shadow-xl gap-7 bg-base-100 my-28')}>
|
||||
<TodoAddItemForm/>
|
||||
{todos.length > 0 && (
|
||||
<>
|
||||
@@ -21,4 +21,4 @@ export default function TodoCard() {
|
||||
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -21,4 +21,4 @@ export default function TodoCardFooter() {
|
||||
</button>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -22,4 +22,4 @@ export default function TodoItem({todo}: Props) {
|
||||
className={'checkbox checkbox-primary'}/>
|
||||
</label>
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -12,4 +12,4 @@ export default function TodoItemList({todos}: Props) {
|
||||
{todos.map((todo: TodoState, index) => <TodoItem todo={todo} key={index}/>)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -34,4 +34,4 @@ export const todoSlice = createSlice({
|
||||
});
|
||||
|
||||
export const {addTodo, checkTodo, deleteSelectedTodos} = todoSlice.actions;
|
||||
export default todoSlice.reducer;
|
||||
export default todoSlice.reducer;
|
||||
|
||||
+1
-1
@@ -1,3 +1,3 @@
|
||||
@tailwind base;
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
||||
@tailwind utilities;
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ import React from 'react';
|
||||
import ReactDOM from 'react-dom/client';
|
||||
import App from './App.tsx';
|
||||
import './index.css';
|
||||
import {Provider} from 'react-redux';
|
||||
import {Provider} from "react-redux";
|
||||
import {store} from './store.ts';
|
||||
|
||||
ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
|
||||
|
||||
@@ -4,4 +4,4 @@ type TodoState = {
|
||||
checked: boolean
|
||||
}
|
||||
|
||||
export default TodoState;
|
||||
export default TodoState;
|
||||
|
||||
+5
-6
@@ -1,12 +1,11 @@
|
||||
import { configureStore } from '@reduxjs/toolkit'
|
||||
import todoReducer from "./features/todo/todoSlice.ts"
|
||||
import {configureStore} from '@reduxjs/toolkit';
|
||||
import todoReducer from './features/todo/todoSlice.ts';
|
||||
|
||||
export const store = configureStore({
|
||||
reducer: {
|
||||
todo: todoReducer
|
||||
todo: todoReducer,
|
||||
},
|
||||
})
|
||||
|
||||
});
|
||||
|
||||
export type RootState = ReturnType<typeof store.getState>
|
||||
export type AppDispatch = typeof store.dispatch
|
||||
export type AppDispatch = typeof store.dispatch
|
||||
|
||||
+16
-4
@@ -1,4 +1,16 @@
|
||||
module.exports = {
|
||||
content: ['./src/**/*.{ts,tsx}'],
|
||||
plugins: [require('daisyui')],
|
||||
};
|
||||
import daisyui from 'daisyui';
|
||||
|
||||
/** @type {import('tailwindcss').Config} */
|
||||
export default {
|
||||
content: [
|
||||
"./index.html",
|
||||
"./src/**/*.{js,ts,jsx,tsx}",
|
||||
],
|
||||
theme: {
|
||||
extend: {},
|
||||
},
|
||||
plugins: [
|
||||
daisyui,
|
||||
],
|
||||
}
|
||||
|
||||
|
||||
+2
-1
@@ -4,7 +4,8 @@
|
||||
"skipLibCheck": true,
|
||||
"module": "ESNext",
|
||||
"moduleResolution": "bundler",
|
||||
"allowSyntheticDefaultImports": true
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"strict": true
|
||||
},
|
||||
"include": ["vite.config.ts"]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user