├── .gitignore
├── README.md
├── index.html
├── package-lock.json
├── package.json
├── public
└── icons8-calculator-64.png
├── src
├── App.tsx
├── components
│ ├── AddToBudget.tsx
│ ├── AddToExpenses.tsx
│ ├── DarkLightThemeButton.tsx
│ ├── DeleteCatToolTip.tsx
│ ├── DisplayCard.tsx
│ ├── DisplayCategories.tsx
│ ├── HistoryItem.tsx
│ ├── HistoryModal.tsx
│ ├── HistoryStack.tsx
│ ├── MainAppShell.tsx
│ ├── NavigationLink.tsx
│ ├── PieChart.tsx
│ ├── ResetValueModal.tsx
│ └── SetBudget.tsx
├── layout
│ └── PageContainer.tsx
├── main.tsx
├── pages
│ ├── AddBudgetPage.tsx
│ ├── AddExpensePage.tsx
│ ├── DisplayCategoriesPage.tsx
│ └── HomePage.tsx
├── store
│ ├── AvailableCategoriesContext.tsx
│ ├── CategoriesContext.tsx
│ └── HistoryContext.tsx
└── vite-env.d.ts
├── tsconfig.json
├── tsconfig.node.json
└── vite.config.ts
/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Expense Tracker App: Overview
2 |
3 | ## Deployment
4 | This app is being deployed using Netlify
5 | Link to app: https://expense-tracker-react-ts-app.netlify.app
6 |
7 | ## Motivation Behind Project
8 | As a university student it is very important to be able to keep track of where I am spending my money. Many of the expense tracking websites and apps
9 | either lack functionality or in design.
10 | I decided to create an expense tracking app that has both the functionality and the design.
11 | This project was also a great chance for me to learn the Mantine UI library.
12 |
13 | ## Resources and Technologies used
14 | Technologies: ReactJS, React Router, React Icons, TypeScript, Mantine UI, HTML canvas API, Local Storage, and ViteJS.
15 | React Docs Beta: https://beta.reactjs.org/
16 | React Router Docs: https://reactrouter.com/en/main
17 | React Icons Website: https://react-icons.github.io/react-icons
18 | Mantine UI Docs: https://mantine.dev/pages/getting-started/
19 | Canvas API Docs: https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API
20 |
21 | ## Quick Description of app
22 |
23 | This app includes the common expense tracking features such as a total budget and expenses counter as well as transaction history.
24 | The user is able to reset both budget and expenses amount as well as delete a transaction. After a transaction is deleted the effect it had on the budget / expenses is undone.
25 | Clicking on a transaction reveals more information about it as well as giving the user the ability to delete the transaction.
26 | The app also includes the ability to categorize expenses. The user can pick out of 3 pre-existing categories or create their own.
27 | The user is also able to view their Budget and Expenses in a pie chart to easily visualize their financial state.
28 | The user is also able to select either a dark or light theme for their app.
29 | All user's data is stored in their browser's local storage.
30 |
31 |
32 | ## What I Learned
33 |
34 | I advanced my knowledge of types and type safety in TypeScript and became more familair with the langauge.
35 | I learned more about React hooks, mainly the useContext hook and how it can be very useful when state is passed down multiple components.
36 | I learned how to use Mantine UI library and the components and hooks it provides.
37 | I learned about HMLT canvas API and how to use it to draw a simple pie chart.
38 | I learned how to use some external React libraries such as react router and react icons.
39 | I learned how to use ViteJS to create a React project that uses TypeScript as an alternative to using create-react-app and manually integrating TypeScript.
40 | I became more familar with inline CSS styling in React componenets.
41 | I became more familair with JavaScript and its built in methods for arrays such as forEach, map, filter and reduce.
42 |
43 |
44 | ## Steps going forward
45 |
46 | I plan to learn how to use Redux for state management.
47 | I plan to experience with other UI libraries such as Material UI and Chakara UI.
48 | I plan to make this app mobile responsive throught CSS media queries or using TailwindCSS
49 | I plan to learn how to add a backend to the expense tracker app and use a database (most likely MongoDB) to store the data instead of local storage.
50 |
51 |
--------------------------------------------------------------------------------
/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | Expense Tracker App
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/package-lock.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "expensetracker",
3 | "version": "0.0.0",
4 | "lockfileVersion": 3,
5 | "requires": true,
6 | "packages": {
7 | "": {
8 | "name": "expensetracker",
9 | "version": "0.0.0",
10 | "dependencies": {
11 | "@emotion/react": "^11.10.5",
12 | "@mantine/core": "^5.9.6",
13 | "@mantine/hooks": "^5.9.6",
14 | "react": "^18.2.0",
15 | "react-dom": "^18.2.0",
16 | "react-icons": "^4.7.1",
17 | "react-router-dom": "^6.6.1"
18 | },
19 | "devDependencies": {
20 | "@types/react": "^18.0.26",
21 | "@types/react-dom": "^18.0.9",
22 | "@vitejs/plugin-react": "^3.0.0",
23 | "typescript": "^4.9.3",
24 | "vite": "^4.0.0"
25 | }
26 | },
27 | "node_modules/@ampproject/remapping": {
28 | "version": "2.2.0",
29 | "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.0.tgz",
30 | "integrity": "sha512-qRmjj8nj9qmLTQXXmaR1cck3UXSRMPrbsLJAasZpF+t3riI71BXed5ebIOYwQntykeZuhjsdweEc9BxH5Jc26w==",
31 | "dependencies": {
32 | "@jridgewell/gen-mapping": "^0.1.0",
33 | "@jridgewell/trace-mapping": "^0.3.9"
34 | },
35 | "engines": {
36 | "node": ">=6.0.0"
37 | }
38 | },
39 | "node_modules/@babel/code-frame": {
40 | "version": "7.18.6",
41 | "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz",
42 | "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==",
43 | "dependencies": {
44 | "@babel/highlight": "^7.18.6"
45 | },
46 | "engines": {
47 | "node": ">=6.9.0"
48 | }
49 | },
50 | "node_modules/@babel/compat-data": {
51 | "version": "7.20.10",
52 | "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.20.10.tgz",
53 | "integrity": "sha512-sEnuDPpOJR/fcafHMjpcpGN5M2jbUGUHwmuWKM/YdPzeEDJg8bgmbcWQFUfE32MQjti1koACvoPVsDe8Uq+idg==",
54 | "engines": {
55 | "node": ">=6.9.0"
56 | }
57 | },
58 | "node_modules/@babel/core": {
59 | "version": "7.20.7",
60 | "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.20.7.tgz",
61 | "integrity": "sha512-t1ZjCluspe5DW24bn2Rr1CDb2v9rn/hROtg9a2tmd0+QYf4bsloYfLQzjG4qHPNMhWtKdGC33R5AxGR2Af2cBw==",
62 | "dependencies": {
63 | "@ampproject/remapping": "^2.1.0",
64 | "@babel/code-frame": "^7.18.6",
65 | "@babel/generator": "^7.20.7",
66 | "@babel/helper-compilation-targets": "^7.20.7",
67 | "@babel/helper-module-transforms": "^7.20.7",
68 | "@babel/helpers": "^7.20.7",
69 | "@babel/parser": "^7.20.7",
70 | "@babel/template": "^7.20.7",
71 | "@babel/traverse": "^7.20.7",
72 | "@babel/types": "^7.20.7",
73 | "convert-source-map": "^1.7.0",
74 | "debug": "^4.1.0",
75 | "gensync": "^1.0.0-beta.2",
76 | "json5": "^2.2.1",
77 | "semver": "^6.3.0"
78 | },
79 | "engines": {
80 | "node": ">=6.9.0"
81 | },
82 | "funding": {
83 | "type": "opencollective",
84 | "url": "https://opencollective.com/babel"
85 | }
86 | },
87 | "node_modules/@babel/generator": {
88 | "version": "7.20.7",
89 | "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.20.7.tgz",
90 | "integrity": "sha512-7wqMOJq8doJMZmP4ApXTzLxSr7+oO2jroJURrVEp6XShrQUObV8Tq/D0NCcoYg2uHqUrjzO0zwBjoYzelxK+sw==",
91 | "dependencies": {
92 | "@babel/types": "^7.20.7",
93 | "@jridgewell/gen-mapping": "^0.3.2",
94 | "jsesc": "^2.5.1"
95 | },
96 | "engines": {
97 | "node": ">=6.9.0"
98 | }
99 | },
100 | "node_modules/@babel/generator/node_modules/@jridgewell/gen-mapping": {
101 | "version": "0.3.2",
102 | "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz",
103 | "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==",
104 | "dependencies": {
105 | "@jridgewell/set-array": "^1.0.1",
106 | "@jridgewell/sourcemap-codec": "^1.4.10",
107 | "@jridgewell/trace-mapping": "^0.3.9"
108 | },
109 | "engines": {
110 | "node": ">=6.0.0"
111 | }
112 | },
113 | "node_modules/@babel/helper-compilation-targets": {
114 | "version": "7.20.7",
115 | "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.20.7.tgz",
116 | "integrity": "sha512-4tGORmfQcrc+bvrjb5y3dG9Mx1IOZjsHqQVUz7XCNHO+iTmqxWnVg3KRygjGmpRLJGdQSKuvFinbIb0CnZwHAQ==",
117 | "dependencies": {
118 | "@babel/compat-data": "^7.20.5",
119 | "@babel/helper-validator-option": "^7.18.6",
120 | "browserslist": "^4.21.3",
121 | "lru-cache": "^5.1.1",
122 | "semver": "^6.3.0"
123 | },
124 | "engines": {
125 | "node": ">=6.9.0"
126 | },
127 | "peerDependencies": {
128 | "@babel/core": "^7.0.0"
129 | }
130 | },
131 | "node_modules/@babel/helper-environment-visitor": {
132 | "version": "7.18.9",
133 | "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.9.tgz",
134 | "integrity": "sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg==",
135 | "engines": {
136 | "node": ">=6.9.0"
137 | }
138 | },
139 | "node_modules/@babel/helper-function-name": {
140 | "version": "7.19.0",
141 | "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.19.0.tgz",
142 | "integrity": "sha512-WAwHBINyrpqywkUH0nTnNgI5ina5TFn85HKS0pbPDfxFfhyR/aNQEn4hGi1P1JyT//I0t4OgXUlofzWILRvS5w==",
143 | "dependencies": {
144 | "@babel/template": "^7.18.10",
145 | "@babel/types": "^7.19.0"
146 | },
147 | "engines": {
148 | "node": ">=6.9.0"
149 | }
150 | },
151 | "node_modules/@babel/helper-hoist-variables": {
152 | "version": "7.18.6",
153 | "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.18.6.tgz",
154 | "integrity": "sha512-UlJQPkFqFULIcyW5sbzgbkxn2FKRgwWiRexcuaR8RNJRy8+LLveqPjwZV/bwrLZCN0eUHD/x8D0heK1ozuoo6Q==",
155 | "dependencies": {
156 | "@babel/types": "^7.18.6"
157 | },
158 | "engines": {
159 | "node": ">=6.9.0"
160 | }
161 | },
162 | "node_modules/@babel/helper-module-imports": {
163 | "version": "7.18.6",
164 | "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz",
165 | "integrity": "sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==",
166 | "dependencies": {
167 | "@babel/types": "^7.18.6"
168 | },
169 | "engines": {
170 | "node": ">=6.9.0"
171 | }
172 | },
173 | "node_modules/@babel/helper-module-transforms": {
174 | "version": "7.20.11",
175 | "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.20.11.tgz",
176 | "integrity": "sha512-uRy78kN4psmji1s2QtbtcCSaj/LILFDp0f/ymhpQH5QY3nljUZCaNWz9X1dEj/8MBdBEFECs7yRhKn8i7NjZgg==",
177 | "dependencies": {
178 | "@babel/helper-environment-visitor": "^7.18.9",
179 | "@babel/helper-module-imports": "^7.18.6",
180 | "@babel/helper-simple-access": "^7.20.2",
181 | "@babel/helper-split-export-declaration": "^7.18.6",
182 | "@babel/helper-validator-identifier": "^7.19.1",
183 | "@babel/template": "^7.20.7",
184 | "@babel/traverse": "^7.20.10",
185 | "@babel/types": "^7.20.7"
186 | },
187 | "engines": {
188 | "node": ">=6.9.0"
189 | }
190 | },
191 | "node_modules/@babel/helper-plugin-utils": {
192 | "version": "7.20.2",
193 | "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.20.2.tgz",
194 | "integrity": "sha512-8RvlJG2mj4huQ4pZ+rU9lqKi9ZKiRmuvGuM2HlWmkmgOhbs6zEAw6IEiJ5cQqGbDzGZOhwuOQNtZMi/ENLjZoQ==",
195 | "engines": {
196 | "node": ">=6.9.0"
197 | }
198 | },
199 | "node_modules/@babel/helper-simple-access": {
200 | "version": "7.20.2",
201 | "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.20.2.tgz",
202 | "integrity": "sha512-+0woI/WPq59IrqDYbVGfshjT5Dmk/nnbdpcF8SnMhhXObpTq2KNBdLFRFrkVdbDOyUmHBCxzm5FHV1rACIkIbA==",
203 | "dependencies": {
204 | "@babel/types": "^7.20.2"
205 | },
206 | "engines": {
207 | "node": ">=6.9.0"
208 | }
209 | },
210 | "node_modules/@babel/helper-split-export-declaration": {
211 | "version": "7.18.6",
212 | "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.18.6.tgz",
213 | "integrity": "sha512-bde1etTx6ZyTmobl9LLMMQsaizFVZrquTEHOqKeQESMKo4PlObf+8+JA25ZsIpZhT/WEd39+vOdLXAFG/nELpA==",
214 | "dependencies": {
215 | "@babel/types": "^7.18.6"
216 | },
217 | "engines": {
218 | "node": ">=6.9.0"
219 | }
220 | },
221 | "node_modules/@babel/helper-string-parser": {
222 | "version": "7.19.4",
223 | "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.19.4.tgz",
224 | "integrity": "sha512-nHtDoQcuqFmwYNYPz3Rah5ph2p8PFeFCsZk9A/48dPc/rGocJ5J3hAAZ7pb76VWX3fZKu+uEr/FhH5jLx7umrw==",
225 | "engines": {
226 | "node": ">=6.9.0"
227 | }
228 | },
229 | "node_modules/@babel/helper-validator-identifier": {
230 | "version": "7.19.1",
231 | "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz",
232 | "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==",
233 | "engines": {
234 | "node": ">=6.9.0"
235 | }
236 | },
237 | "node_modules/@babel/helper-validator-option": {
238 | "version": "7.18.6",
239 | "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.18.6.tgz",
240 | "integrity": "sha512-XO7gESt5ouv/LRJdrVjkShckw6STTaB7l9BrpBaAHDeF5YZT+01PCwmR0SJHnkW6i8OwW/EVWRShfi4j2x+KQw==",
241 | "engines": {
242 | "node": ">=6.9.0"
243 | }
244 | },
245 | "node_modules/@babel/helpers": {
246 | "version": "7.20.7",
247 | "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.20.7.tgz",
248 | "integrity": "sha512-PBPjs5BppzsGaxHQCDKnZ6Gd9s6xl8bBCluz3vEInLGRJmnZan4F6BYCeqtyXqkk4W5IlPmjK4JlOuZkpJ3xZA==",
249 | "dependencies": {
250 | "@babel/template": "^7.20.7",
251 | "@babel/traverse": "^7.20.7",
252 | "@babel/types": "^7.20.7"
253 | },
254 | "engines": {
255 | "node": ">=6.9.0"
256 | }
257 | },
258 | "node_modules/@babel/highlight": {
259 | "version": "7.18.6",
260 | "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz",
261 | "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==",
262 | "dependencies": {
263 | "@babel/helper-validator-identifier": "^7.18.6",
264 | "chalk": "^2.0.0",
265 | "js-tokens": "^4.0.0"
266 | },
267 | "engines": {
268 | "node": ">=6.9.0"
269 | }
270 | },
271 | "node_modules/@babel/parser": {
272 | "version": "7.20.7",
273 | "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.20.7.tgz",
274 | "integrity": "sha512-T3Z9oHybU+0vZlY9CiDSJQTD5ZapcW18ZctFMi0MOAl/4BjFF4ul7NVSARLdbGO5vDqy9eQiGTV0LtKfvCYvcg==",
275 | "bin": {
276 | "parser": "bin/babel-parser.js"
277 | },
278 | "engines": {
279 | "node": ">=6.0.0"
280 | }
281 | },
282 | "node_modules/@babel/plugin-syntax-jsx": {
283 | "version": "7.18.6",
284 | "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.18.6.tgz",
285 | "integrity": "sha512-6mmljtAedFGTWu2p/8WIORGwy+61PLgOMPOdazc7YoJ9ZCWUyFy3A6CpPkRKLKD1ToAesxX8KGEViAiLo9N+7Q==",
286 | "dependencies": {
287 | "@babel/helper-plugin-utils": "^7.18.6"
288 | },
289 | "engines": {
290 | "node": ">=6.9.0"
291 | },
292 | "peerDependencies": {
293 | "@babel/core": "^7.0.0-0"
294 | }
295 | },
296 | "node_modules/@babel/plugin-transform-react-jsx-self": {
297 | "version": "7.18.6",
298 | "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.18.6.tgz",
299 | "integrity": "sha512-A0LQGx4+4Jv7u/tWzoJF7alZwnBDQd6cGLh9P+Ttk4dpiL+J5p7NSNv/9tlEFFJDq3kjxOavWmbm6t0Gk+A3Ig==",
300 | "dev": true,
301 | "dependencies": {
302 | "@babel/helper-plugin-utils": "^7.18.6"
303 | },
304 | "engines": {
305 | "node": ">=6.9.0"
306 | },
307 | "peerDependencies": {
308 | "@babel/core": "^7.0.0-0"
309 | }
310 | },
311 | "node_modules/@babel/plugin-transform-react-jsx-source": {
312 | "version": "7.19.6",
313 | "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.19.6.tgz",
314 | "integrity": "sha512-RpAi004QyMNisst/pvSanoRdJ4q+jMCWyk9zdw/CyLB9j8RXEahodR6l2GyttDRyEVWZtbN+TpLiHJ3t34LbsQ==",
315 | "dev": true,
316 | "dependencies": {
317 | "@babel/helper-plugin-utils": "^7.19.0"
318 | },
319 | "engines": {
320 | "node": ">=6.9.0"
321 | },
322 | "peerDependencies": {
323 | "@babel/core": "^7.0.0-0"
324 | }
325 | },
326 | "node_modules/@babel/runtime": {
327 | "version": "7.20.7",
328 | "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.20.7.tgz",
329 | "integrity": "sha512-UF0tvkUtxwAgZ5W/KrkHf0Rn0fdnLDU9ScxBrEVNUprE/MzirjK4MJUX1/BVDv00Sv8cljtukVK1aky++X1SjQ==",
330 | "dependencies": {
331 | "regenerator-runtime": "^0.13.11"
332 | },
333 | "engines": {
334 | "node": ">=6.9.0"
335 | }
336 | },
337 | "node_modules/@babel/template": {
338 | "version": "7.20.7",
339 | "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.20.7.tgz",
340 | "integrity": "sha512-8SegXApWe6VoNw0r9JHpSteLKTpTiLZ4rMlGIm9JQ18KiCtyQiAMEazujAHrUS5flrcqYZa75ukev3P6QmUwUw==",
341 | "dependencies": {
342 | "@babel/code-frame": "^7.18.6",
343 | "@babel/parser": "^7.20.7",
344 | "@babel/types": "^7.20.7"
345 | },
346 | "engines": {
347 | "node": ">=6.9.0"
348 | }
349 | },
350 | "node_modules/@babel/traverse": {
351 | "version": "7.20.10",
352 | "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.20.10.tgz",
353 | "integrity": "sha512-oSf1juCgymrSez8NI4A2sr4+uB/mFd9MXplYGPEBnfAuWmmyeVcHa6xLPiaRBcXkcb/28bgxmQLTVwFKE1yfsg==",
354 | "dependencies": {
355 | "@babel/code-frame": "^7.18.6",
356 | "@babel/generator": "^7.20.7",
357 | "@babel/helper-environment-visitor": "^7.18.9",
358 | "@babel/helper-function-name": "^7.19.0",
359 | "@babel/helper-hoist-variables": "^7.18.6",
360 | "@babel/helper-split-export-declaration": "^7.18.6",
361 | "@babel/parser": "^7.20.7",
362 | "@babel/types": "^7.20.7",
363 | "debug": "^4.1.0",
364 | "globals": "^11.1.0"
365 | },
366 | "engines": {
367 | "node": ">=6.9.0"
368 | }
369 | },
370 | "node_modules/@babel/types": {
371 | "version": "7.20.7",
372 | "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.20.7.tgz",
373 | "integrity": "sha512-69OnhBxSSgK0OzTJai4kyPDiKTIe3j+ctaHdIGVbRahTLAT7L3R9oeXHC2aVSuGYt3cVnoAMDmOCgJ2yaiLMvg==",
374 | "dependencies": {
375 | "@babel/helper-string-parser": "^7.19.4",
376 | "@babel/helper-validator-identifier": "^7.19.1",
377 | "to-fast-properties": "^2.0.0"
378 | },
379 | "engines": {
380 | "node": ">=6.9.0"
381 | }
382 | },
383 | "node_modules/@emotion/babel-plugin": {
384 | "version": "11.10.5",
385 | "resolved": "https://registry.npmjs.org/@emotion/babel-plugin/-/babel-plugin-11.10.5.tgz",
386 | "integrity": "sha512-xE7/hyLHJac7D2Ve9dKroBBZqBT7WuPQmWcq7HSGb84sUuP4mlOWoB8dvVfD9yk5DHkU1m6RW7xSoDtnQHNQeA==",
387 | "dependencies": {
388 | "@babel/helper-module-imports": "^7.16.7",
389 | "@babel/plugin-syntax-jsx": "^7.17.12",
390 | "@babel/runtime": "^7.18.3",
391 | "@emotion/hash": "^0.9.0",
392 | "@emotion/memoize": "^0.8.0",
393 | "@emotion/serialize": "^1.1.1",
394 | "babel-plugin-macros": "^3.1.0",
395 | "convert-source-map": "^1.5.0",
396 | "escape-string-regexp": "^4.0.0",
397 | "find-root": "^1.1.0",
398 | "source-map": "^0.5.7",
399 | "stylis": "4.1.3"
400 | },
401 | "peerDependencies": {
402 | "@babel/core": "^7.0.0"
403 | }
404 | },
405 | "node_modules/@emotion/cache": {
406 | "version": "11.10.5",
407 | "resolved": "https://registry.npmjs.org/@emotion/cache/-/cache-11.10.5.tgz",
408 | "integrity": "sha512-dGYHWyzTdmK+f2+EnIGBpkz1lKc4Zbj2KHd4cX3Wi8/OWr5pKslNjc3yABKH4adRGCvSX4VDC0i04mrrq0aiRA==",
409 | "dependencies": {
410 | "@emotion/memoize": "^0.8.0",
411 | "@emotion/sheet": "^1.2.1",
412 | "@emotion/utils": "^1.2.0",
413 | "@emotion/weak-memoize": "^0.3.0",
414 | "stylis": "4.1.3"
415 | }
416 | },
417 | "node_modules/@emotion/hash": {
418 | "version": "0.9.0",
419 | "resolved": "https://registry.npmjs.org/@emotion/hash/-/hash-0.9.0.tgz",
420 | "integrity": "sha512-14FtKiHhy2QoPIzdTcvh//8OyBlknNs2nXRwIhG904opCby3l+9Xaf/wuPvICBF0rc1ZCNBd3nKe9cd2mecVkQ=="
421 | },
422 | "node_modules/@emotion/memoize": {
423 | "version": "0.8.0",
424 | "resolved": "https://registry.npmjs.org/@emotion/memoize/-/memoize-0.8.0.tgz",
425 | "integrity": "sha512-G/YwXTkv7Den9mXDO7AhLWkE3q+I92B+VqAE+dYG4NGPaHZGvt3G8Q0p9vmE+sq7rTGphUbAvmQ9YpbfMQGGlA=="
426 | },
427 | "node_modules/@emotion/react": {
428 | "version": "11.10.5",
429 | "resolved": "https://registry.npmjs.org/@emotion/react/-/react-11.10.5.tgz",
430 | "integrity": "sha512-TZs6235tCJ/7iF6/rvTaOH4oxQg2gMAcdHemjwLKIjKz4rRuYe1HJ2TQJKnAcRAfOUDdU8XoDadCe1rl72iv8A==",
431 | "dependencies": {
432 | "@babel/runtime": "^7.18.3",
433 | "@emotion/babel-plugin": "^11.10.5",
434 | "@emotion/cache": "^11.10.5",
435 | "@emotion/serialize": "^1.1.1",
436 | "@emotion/use-insertion-effect-with-fallbacks": "^1.0.0",
437 | "@emotion/utils": "^1.2.0",
438 | "@emotion/weak-memoize": "^0.3.0",
439 | "hoist-non-react-statics": "^3.3.1"
440 | },
441 | "peerDependencies": {
442 | "@babel/core": "^7.0.0",
443 | "react": ">=16.8.0"
444 | },
445 | "peerDependenciesMeta": {
446 | "@babel/core": {
447 | "optional": true
448 | },
449 | "@types/react": {
450 | "optional": true
451 | }
452 | }
453 | },
454 | "node_modules/@emotion/serialize": {
455 | "version": "1.1.1",
456 | "resolved": "https://registry.npmjs.org/@emotion/serialize/-/serialize-1.1.1.tgz",
457 | "integrity": "sha512-Zl/0LFggN7+L1liljxXdsVSVlg6E/Z/olVWpfxUTxOAmi8NU7YoeWeLfi1RmnB2TATHoaWwIBRoL+FvAJiTUQA==",
458 | "dependencies": {
459 | "@emotion/hash": "^0.9.0",
460 | "@emotion/memoize": "^0.8.0",
461 | "@emotion/unitless": "^0.8.0",
462 | "@emotion/utils": "^1.2.0",
463 | "csstype": "^3.0.2"
464 | }
465 | },
466 | "node_modules/@emotion/sheet": {
467 | "version": "1.2.1",
468 | "resolved": "https://registry.npmjs.org/@emotion/sheet/-/sheet-1.2.1.tgz",
469 | "integrity": "sha512-zxRBwl93sHMsOj4zs+OslQKg/uhF38MB+OMKoCrVuS0nyTkqnau+BM3WGEoOptg9Oz45T/aIGs1qbVAsEFo3nA=="
470 | },
471 | "node_modules/@emotion/unitless": {
472 | "version": "0.8.0",
473 | "resolved": "https://registry.npmjs.org/@emotion/unitless/-/unitless-0.8.0.tgz",
474 | "integrity": "sha512-VINS5vEYAscRl2ZUDiT3uMPlrFQupiKgHz5AA4bCH1miKBg4qtwkim1qPmJj/4WG6TreYMY111rEFsjupcOKHw=="
475 | },
476 | "node_modules/@emotion/use-insertion-effect-with-fallbacks": {
477 | "version": "1.0.0",
478 | "resolved": "https://registry.npmjs.org/@emotion/use-insertion-effect-with-fallbacks/-/use-insertion-effect-with-fallbacks-1.0.0.tgz",
479 | "integrity": "sha512-1eEgUGmkaljiBnRMTdksDV1W4kUnmwgp7X9G8B++9GYwl1lUdqSndSriIrTJ0N7LQaoauY9JJ2yhiOYK5+NI4A==",
480 | "peerDependencies": {
481 | "react": ">=16.8.0"
482 | }
483 | },
484 | "node_modules/@emotion/utils": {
485 | "version": "1.2.0",
486 | "resolved": "https://registry.npmjs.org/@emotion/utils/-/utils-1.2.0.tgz",
487 | "integrity": "sha512-sn3WH53Kzpw8oQ5mgMmIzzyAaH2ZqFEbozVVBSYp538E06OSE6ytOp7pRAjNQR+Q/orwqdQYJSe2m3hCOeznkw=="
488 | },
489 | "node_modules/@emotion/weak-memoize": {
490 | "version": "0.3.0",
491 | "resolved": "https://registry.npmjs.org/@emotion/weak-memoize/-/weak-memoize-0.3.0.tgz",
492 | "integrity": "sha512-AHPmaAx+RYfZz0eYu6Gviiagpmiyw98ySSlQvCUhVGDRtDFe4DBS0x1bSjdF3gqUDYOczB+yYvBTtEylYSdRhg=="
493 | },
494 | "node_modules/@esbuild/android-arm": {
495 | "version": "0.16.13",
496 | "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.16.13.tgz",
497 | "integrity": "sha512-JmtqThupn9Yf+FzANE+GG73ASUkssnPwOsndUElhp23685QzRK+MO1UompOlBaXV9D5FTuYcPnw7p4mCq2YbZQ==",
498 | "cpu": [
499 | "arm"
500 | ],
501 | "dev": true,
502 | "optional": true,
503 | "os": [
504 | "android"
505 | ],
506 | "engines": {
507 | "node": ">=12"
508 | }
509 | },
510 | "node_modules/@esbuild/android-arm64": {
511 | "version": "0.16.13",
512 | "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.16.13.tgz",
513 | "integrity": "sha512-r4xetsd1ez1NF9/9R2f9Q6AlxqiZLwUqo7ICOcvEVwopVkXUcspIjEbJk0EVTgT6Cp5+ymzGPT6YNV0ievx4yA==",
514 | "cpu": [
515 | "arm64"
516 | ],
517 | "dev": true,
518 | "optional": true,
519 | "os": [
520 | "android"
521 | ],
522 | "engines": {
523 | "node": ">=12"
524 | }
525 | },
526 | "node_modules/@esbuild/android-x64": {
527 | "version": "0.16.13",
528 | "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.16.13.tgz",
529 | "integrity": "sha512-hKt1bFht/Vtp0xJ0ZVzFMnPy1y1ycmM3KNnp3zsyZfQmw7nhs2WLO4vxdR5YG+6RsHKCb2zbZ3VwlC0Tij0qyA==",
530 | "cpu": [
531 | "x64"
532 | ],
533 | "dev": true,
534 | "optional": true,
535 | "os": [
536 | "android"
537 | ],
538 | "engines": {
539 | "node": ">=12"
540 | }
541 | },
542 | "node_modules/@esbuild/darwin-arm64": {
543 | "version": "0.16.13",
544 | "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.16.13.tgz",
545 | "integrity": "sha512-ogrVuNi2URocrr3Ps20f075EMm9V7IeenOi9FRj4qdbT6mQlwLuP4l90PW2iBrKERx0oRkcZprEUNsz/3xd7ww==",
546 | "cpu": [
547 | "arm64"
548 | ],
549 | "dev": true,
550 | "optional": true,
551 | "os": [
552 | "darwin"
553 | ],
554 | "engines": {
555 | "node": ">=12"
556 | }
557 | },
558 | "node_modules/@esbuild/darwin-x64": {
559 | "version": "0.16.13",
560 | "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.16.13.tgz",
561 | "integrity": "sha512-Agajik9SBGiKD7FPXE+ExW6x3MgA/dUdpZnXa9y1tyfE4lKQx+eQiknSdrBnWPeqa9wL0AOvkhghmYhpVkyqkA==",
562 | "cpu": [
563 | "x64"
564 | ],
565 | "dev": true,
566 | "optional": true,
567 | "os": [
568 | "darwin"
569 | ],
570 | "engines": {
571 | "node": ">=12"
572 | }
573 | },
574 | "node_modules/@esbuild/freebsd-arm64": {
575 | "version": "0.16.13",
576 | "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.16.13.tgz",
577 | "integrity": "sha512-KxMO3/XihBcHM+xQUM6nQZO1SgQuOsd1DCnKF1a4SIf/i5VD45vrqN3k8ePgFrEbMi7m5JeGmvNqwJXinF0a4Q==",
578 | "cpu": [
579 | "arm64"
580 | ],
581 | "dev": true,
582 | "optional": true,
583 | "os": [
584 | "freebsd"
585 | ],
586 | "engines": {
587 | "node": ">=12"
588 | }
589 | },
590 | "node_modules/@esbuild/freebsd-x64": {
591 | "version": "0.16.13",
592 | "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.16.13.tgz",
593 | "integrity": "sha512-Ez15oqV1vwvZ30cVLeBW14BsWq/fdWNQGMOxxqaSJVQVLqHhvgfQ7gxGDiN9tpJdeQhqJO+Q0r02/Tce5+USNg==",
594 | "cpu": [
595 | "x64"
596 | ],
597 | "dev": true,
598 | "optional": true,
599 | "os": [
600 | "freebsd"
601 | ],
602 | "engines": {
603 | "node": ">=12"
604 | }
605 | },
606 | "node_modules/@esbuild/linux-arm": {
607 | "version": "0.16.13",
608 | "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.16.13.tgz",
609 | "integrity": "sha512-18dLd2L3mda+iFj6sswyBMSh2UwniamD9M4DwPv8VM+9apRFlQ5IGKxBdumnTuOI4NvwwAernmUseWhYQ9k+rg==",
610 | "cpu": [
611 | "arm"
612 | ],
613 | "dev": true,
614 | "optional": true,
615 | "os": [
616 | "linux"
617 | ],
618 | "engines": {
619 | "node": ">=12"
620 | }
621 | },
622 | "node_modules/@esbuild/linux-arm64": {
623 | "version": "0.16.13",
624 | "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.16.13.tgz",
625 | "integrity": "sha512-qi5n7KwcGViyJeZeQnu8fB6dC3Mlm5PGaqSv2HhQDDx/MPvVfQGNMcv7zcBL4qk3FkuWhGVwXkjQ76x7R0PWlA==",
626 | "cpu": [
627 | "arm64"
628 | ],
629 | "dev": true,
630 | "optional": true,
631 | "os": [
632 | "linux"
633 | ],
634 | "engines": {
635 | "node": ">=12"
636 | }
637 | },
638 | "node_modules/@esbuild/linux-ia32": {
639 | "version": "0.16.13",
640 | "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.16.13.tgz",
641 | "integrity": "sha512-2489Xad9sr+6GD7nB913fUqpCsSwVwgskkQTq4Or2mZntSPYPebyJm8l1YruHo7oqYMTGV6RiwGE4gRo3H+EPQ==",
642 | "cpu": [
643 | "ia32"
644 | ],
645 | "dev": true,
646 | "optional": true,
647 | "os": [
648 | "linux"
649 | ],
650 | "engines": {
651 | "node": ">=12"
652 | }
653 | },
654 | "node_modules/@esbuild/linux-loong64": {
655 | "version": "0.16.13",
656 | "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.16.13.tgz",
657 | "integrity": "sha512-x8KplRu9Y43Px8I9YS+sPBwQ+fw44Mvp2BPVADopKDWz+h3fcj1BvRU58kxb89WObmwKX9sWdtYzepL4Fmx03A==",
658 | "cpu": [
659 | "loong64"
660 | ],
661 | "dev": true,
662 | "optional": true,
663 | "os": [
664 | "linux"
665 | ],
666 | "engines": {
667 | "node": ">=12"
668 | }
669 | },
670 | "node_modules/@esbuild/linux-mips64el": {
671 | "version": "0.16.13",
672 | "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.16.13.tgz",
673 | "integrity": "sha512-qhhdWph9FLwD9rVVC/nUf7k2U4NZIA6/mGx0B7+O6PFV0GjmPA2E3zDQ4NUjq9P26E0DeAZy9akH9dYcUBRU7A==",
674 | "cpu": [
675 | "mips64el"
676 | ],
677 | "dev": true,
678 | "optional": true,
679 | "os": [
680 | "linux"
681 | ],
682 | "engines": {
683 | "node": ">=12"
684 | }
685 | },
686 | "node_modules/@esbuild/linux-ppc64": {
687 | "version": "0.16.13",
688 | "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.16.13.tgz",
689 | "integrity": "sha512-cVWAPKsrRVxI1jCeJHnYSbE3BrEU+pZTZK2gfao9HRxuc+3m4+RLfs3EVEpGLmMKEcWfVCB9wZ3yNxnknutGKQ==",
690 | "cpu": [
691 | "ppc64"
692 | ],
693 | "dev": true,
694 | "optional": true,
695 | "os": [
696 | "linux"
697 | ],
698 | "engines": {
699 | "node": ">=12"
700 | }
701 | },
702 | "node_modules/@esbuild/linux-riscv64": {
703 | "version": "0.16.13",
704 | "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.16.13.tgz",
705 | "integrity": "sha512-Agb7dbRyZWnmPn5Vvf0eyqaEUqSsaIUwwyInu2EoFTaIDRp093QU2M5alUyOooMLkRbD1WvqQNwx08Z/g+SAcQ==",
706 | "cpu": [
707 | "riscv64"
708 | ],
709 | "dev": true,
710 | "optional": true,
711 | "os": [
712 | "linux"
713 | ],
714 | "engines": {
715 | "node": ">=12"
716 | }
717 | },
718 | "node_modules/@esbuild/linux-s390x": {
719 | "version": "0.16.13",
720 | "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.16.13.tgz",
721 | "integrity": "sha512-AqRBIrc/+kl08ahliNG+EyU+j41wIzQfwBTKpi80cCDiYvYFPuXjvzZsD9muiu58Isj0RVni9VgC4xK/AnSW4g==",
722 | "cpu": [
723 | "s390x"
724 | ],
725 | "dev": true,
726 | "optional": true,
727 | "os": [
728 | "linux"
729 | ],
730 | "engines": {
731 | "node": ">=12"
732 | }
733 | },
734 | "node_modules/@esbuild/linux-x64": {
735 | "version": "0.16.13",
736 | "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.16.13.tgz",
737 | "integrity": "sha512-S4wn2BimuhPcoArRtVrdHUKIymCCZcYAXQE47kUiX4yrUrEX2/ifn5eKNbZ5c1jJKUlh1gC2ESIN+iw3wQax3g==",
738 | "cpu": [
739 | "x64"
740 | ],
741 | "dev": true,
742 | "optional": true,
743 | "os": [
744 | "linux"
745 | ],
746 | "engines": {
747 | "node": ">=12"
748 | }
749 | },
750 | "node_modules/@esbuild/netbsd-x64": {
751 | "version": "0.16.13",
752 | "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.16.13.tgz",
753 | "integrity": "sha512-2c8JWgfUMlQHTdaR5X3xNMwqOyad8kgeCupuVkdm3QkUOzGREjlTETQsK6oHifocYzDCo9FeKcUwsK356SdR+g==",
754 | "cpu": [
755 | "x64"
756 | ],
757 | "dev": true,
758 | "optional": true,
759 | "os": [
760 | "netbsd"
761 | ],
762 | "engines": {
763 | "node": ">=12"
764 | }
765 | },
766 | "node_modules/@esbuild/openbsd-x64": {
767 | "version": "0.16.13",
768 | "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.16.13.tgz",
769 | "integrity": "sha512-Bwh+PmKD/LK+xBjqIpnYnKYj0fIyQJ0YpRxsn0F+WfzvQ2OA+GKDlf8AHosiCns26Q4Dje388jQVwfOBZ1GaFw==",
770 | "cpu": [
771 | "x64"
772 | ],
773 | "dev": true,
774 | "optional": true,
775 | "os": [
776 | "openbsd"
777 | ],
778 | "engines": {
779 | "node": ">=12"
780 | }
781 | },
782 | "node_modules/@esbuild/sunos-x64": {
783 | "version": "0.16.13",
784 | "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.16.13.tgz",
785 | "integrity": "sha512-8wwk6f9XGnhrF94/DBdFM4Xm1JeCyGTCj67r516VS9yvBVQf3Rar54L+XPVDs/oZOokwH+XsktrgkuTMAmjntg==",
786 | "cpu": [
787 | "x64"
788 | ],
789 | "dev": true,
790 | "optional": true,
791 | "os": [
792 | "sunos"
793 | ],
794 | "engines": {
795 | "node": ">=12"
796 | }
797 | },
798 | "node_modules/@esbuild/win32-arm64": {
799 | "version": "0.16.13",
800 | "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.16.13.tgz",
801 | "integrity": "sha512-Jmwbp/5ArLCiRAHC33ODfcrlIcbP/exXkOEUVkADNJC4e/so2jm+i8IQFvVX/lA2GWvK3GdgcN0VFfp9YITAbg==",
802 | "cpu": [
803 | "arm64"
804 | ],
805 | "dev": true,
806 | "optional": true,
807 | "os": [
808 | "win32"
809 | ],
810 | "engines": {
811 | "node": ">=12"
812 | }
813 | },
814 | "node_modules/@esbuild/win32-ia32": {
815 | "version": "0.16.13",
816 | "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.16.13.tgz",
817 | "integrity": "sha512-AX6WjntGjhJHzrPSVvjMD7grxt41koHfAOx6lxLorrpDwwIKKPaGDASPZgvFIZHTbwhOtILW6vAXxYPDsKpDJA==",
818 | "cpu": [
819 | "ia32"
820 | ],
821 | "dev": true,
822 | "optional": true,
823 | "os": [
824 | "win32"
825 | ],
826 | "engines": {
827 | "node": ">=12"
828 | }
829 | },
830 | "node_modules/@esbuild/win32-x64": {
831 | "version": "0.16.13",
832 | "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.16.13.tgz",
833 | "integrity": "sha512-A+U4gM6OOkPS03UgVU08GTpAAAxPsP/8Z4FmneGo4TaVSD99bK9gVJXlqUEPMO/htFXEAht2O6pX4ErtLY5tVg==",
834 | "cpu": [
835 | "x64"
836 | ],
837 | "dev": true,
838 | "optional": true,
839 | "os": [
840 | "win32"
841 | ],
842 | "engines": {
843 | "node": ">=12"
844 | }
845 | },
846 | "node_modules/@floating-ui/core": {
847 | "version": "1.1.0",
848 | "resolved": "https://registry.npmjs.org/@floating-ui/core/-/core-1.1.0.tgz",
849 | "integrity": "sha512-zbsLwtnHo84w1Kc8rScAo5GMk1GdecSlrflIbfnEBJwvTSj1SL6kkOYV+nHraMCPEy+RNZZUaZyL8JosDGCtGQ=="
850 | },
851 | "node_modules/@floating-ui/dom": {
852 | "version": "1.1.0",
853 | "resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.1.0.tgz",
854 | "integrity": "sha512-TSogMPVxbRe77QCj1dt8NmRiJasPvuc+eT5jnJ6YpLqgOD2zXc5UA3S1qwybN+GVCDNdKfpKy1oj8RpzLJvh6A==",
855 | "dependencies": {
856 | "@floating-ui/core": "^1.0.5"
857 | }
858 | },
859 | "node_modules/@floating-ui/react-dom": {
860 | "version": "1.1.0",
861 | "resolved": "https://registry.npmjs.org/@floating-ui/react-dom/-/react-dom-1.1.0.tgz",
862 | "integrity": "sha512-xyP9dMqZouuQ7h10DvbEbxZItuUleKHXe7XQFvbpttjXZrfyQMaZVTnWsE/t3hrHakZy18HxEBZRzGNXQHd0GA==",
863 | "dependencies": {
864 | "@floating-ui/dom": "^1.1.0"
865 | },
866 | "peerDependencies": {
867 | "react": ">=16.8.0",
868 | "react-dom": ">=16.8.0"
869 | }
870 | },
871 | "node_modules/@floating-ui/react-dom-interactions": {
872 | "version": "0.10.3",
873 | "resolved": "https://registry.npmjs.org/@floating-ui/react-dom-interactions/-/react-dom-interactions-0.10.3.tgz",
874 | "integrity": "sha512-UEHqdnzyoiWNU5az/tAljr9iXFzN18DcvpMqW+/cXz4FEhDEB1ogLtWldOWCujLerPBnSRocADALafelOReMpw==",
875 | "deprecated": "Package renamed to @floating-ui/react",
876 | "dependencies": {
877 | "@floating-ui/react-dom": "^1.0.0",
878 | "aria-hidden": "^1.1.3"
879 | },
880 | "peerDependencies": {
881 | "react": ">=16.8.0",
882 | "react-dom": ">=16.8.0"
883 | }
884 | },
885 | "node_modules/@jridgewell/gen-mapping": {
886 | "version": "0.1.1",
887 | "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.1.1.tgz",
888 | "integrity": "sha512-sQXCasFk+U8lWYEe66WxRDOE9PjVz4vSM51fTu3Hw+ClTpUSQb718772vH3pyS5pShp6lvQM7SxgIDXXXmOX7w==",
889 | "dependencies": {
890 | "@jridgewell/set-array": "^1.0.0",
891 | "@jridgewell/sourcemap-codec": "^1.4.10"
892 | },
893 | "engines": {
894 | "node": ">=6.0.0"
895 | }
896 | },
897 | "node_modules/@jridgewell/resolve-uri": {
898 | "version": "3.1.0",
899 | "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz",
900 | "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==",
901 | "engines": {
902 | "node": ">=6.0.0"
903 | }
904 | },
905 | "node_modules/@jridgewell/set-array": {
906 | "version": "1.1.2",
907 | "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz",
908 | "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==",
909 | "engines": {
910 | "node": ">=6.0.0"
911 | }
912 | },
913 | "node_modules/@jridgewell/sourcemap-codec": {
914 | "version": "1.4.14",
915 | "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz",
916 | "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw=="
917 | },
918 | "node_modules/@jridgewell/trace-mapping": {
919 | "version": "0.3.17",
920 | "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.17.tgz",
921 | "integrity": "sha512-MCNzAp77qzKca9+W/+I0+sEpaUnZoeasnghNeVc41VZCEKaCH73Vq3BZZ/SzWIgrqE4H4ceI+p+b6C0mHf9T4g==",
922 | "dependencies": {
923 | "@jridgewell/resolve-uri": "3.1.0",
924 | "@jridgewell/sourcemap-codec": "1.4.14"
925 | }
926 | },
927 | "node_modules/@mantine/core": {
928 | "version": "5.9.6",
929 | "resolved": "https://registry.npmjs.org/@mantine/core/-/core-5.9.6.tgz",
930 | "integrity": "sha512-N+Jow2vbaqb6IaOupzSEMJcuMZ5h3Sk6832j5GuNzacu377mpn8DR7lyFqKPTTowvhsUgI5fnFJRBsG4wuFgsw==",
931 | "dependencies": {
932 | "@floating-ui/react-dom-interactions": "^0.10.1",
933 | "@mantine/styles": "5.9.6",
934 | "@mantine/utils": "5.9.6",
935 | "@radix-ui/react-scroll-area": "1.0.2",
936 | "react-textarea-autosize": "8.3.4"
937 | },
938 | "peerDependencies": {
939 | "@mantine/hooks": "5.9.6",
940 | "react": ">=16.8.0",
941 | "react-dom": ">=16.8.0"
942 | }
943 | },
944 | "node_modules/@mantine/hooks": {
945 | "version": "5.9.6",
946 | "resolved": "https://registry.npmjs.org/@mantine/hooks/-/hooks-5.9.6.tgz",
947 | "integrity": "sha512-60gI0dXjfpx5XJZteIt6rKWtgE3RdpvKY2OmUH4yRe2ZVqFU4quWdt6r720x9dWSJs32xm0AYUxZxjJyCLhnFw==",
948 | "peerDependencies": {
949 | "react": ">=16.8.0"
950 | }
951 | },
952 | "node_modules/@mantine/styles": {
953 | "version": "5.9.6",
954 | "resolved": "https://registry.npmjs.org/@mantine/styles/-/styles-5.9.6.tgz",
955 | "integrity": "sha512-IZ4fdXzm1yUcSZgtUZGuWKL1mPkhVsG5veJKZ4o4M/8rO2fowzumay9WBrGJIs0i3KAM0KAGZ6lLyLGXkJYQQw==",
956 | "dependencies": {
957 | "clsx": "1.1.1",
958 | "csstype": "3.0.9"
959 | },
960 | "peerDependencies": {
961 | "@emotion/react": ">=11.9.0",
962 | "react": ">=16.8.0",
963 | "react-dom": ">=16.8.0"
964 | }
965 | },
966 | "node_modules/@mantine/styles/node_modules/csstype": {
967 | "version": "3.0.9",
968 | "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.0.9.tgz",
969 | "integrity": "sha512-rpw6JPxK6Rfg1zLOYCSwle2GFOOsnjmDYDaBwEcwoOg4qlsIVCN789VkBZDJAGi4T07gI4YSutR43t9Zz4Lzuw=="
970 | },
971 | "node_modules/@mantine/utils": {
972 | "version": "5.9.6",
973 | "resolved": "https://registry.npmjs.org/@mantine/utils/-/utils-5.9.6.tgz",
974 | "integrity": "sha512-MMKUsTLWzt9g7z1sfjPHIAaV2TzEdH6oRREZgFFtzfRR7V9jrpFdzCPruh+K/Cxh8xDWGPXKaSOkCfX6FSXw6A==",
975 | "peerDependencies": {
976 | "react": ">=16.8.0"
977 | }
978 | },
979 | "node_modules/@radix-ui/number": {
980 | "version": "1.0.0",
981 | "resolved": "https://registry.npmjs.org/@radix-ui/number/-/number-1.0.0.tgz",
982 | "integrity": "sha512-Ofwh/1HX69ZfJRiRBMTy7rgjAzHmwe4kW9C9Y99HTRUcYLUuVT0KESFj15rPjRgKJs20GPq8Bm5aEDJ8DuA3vA==",
983 | "dependencies": {
984 | "@babel/runtime": "^7.13.10"
985 | }
986 | },
987 | "node_modules/@radix-ui/primitive": {
988 | "version": "1.0.0",
989 | "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.0.0.tgz",
990 | "integrity": "sha512-3e7rn8FDMin4CgeL7Z/49smCA3rFYY3Ha2rUQ7HRWFadS5iCRw08ZgVT1LaNTCNqgvrUiyczLflrVrF0SRQtNA==",
991 | "dependencies": {
992 | "@babel/runtime": "^7.13.10"
993 | }
994 | },
995 | "node_modules/@radix-ui/react-compose-refs": {
996 | "version": "1.0.0",
997 | "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.0.0.tgz",
998 | "integrity": "sha512-0KaSv6sx787/hK3eF53iOkiSLwAGlFMx5lotrqD2pTjB18KbybKoEIgkNZTKC60YECDQTKGTRcDBILwZVqVKvA==",
999 | "dependencies": {
1000 | "@babel/runtime": "^7.13.10"
1001 | },
1002 | "peerDependencies": {
1003 | "react": "^16.8 || ^17.0 || ^18.0"
1004 | }
1005 | },
1006 | "node_modules/@radix-ui/react-context": {
1007 | "version": "1.0.0",
1008 | "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.0.0.tgz",
1009 | "integrity": "sha512-1pVM9RfOQ+n/N5PJK33kRSKsr1glNxomxONs5c49MliinBY6Yw2Q995qfBUUo0/Mbg05B/sGA0gkgPI7kmSHBg==",
1010 | "dependencies": {
1011 | "@babel/runtime": "^7.13.10"
1012 | },
1013 | "peerDependencies": {
1014 | "react": "^16.8 || ^17.0 || ^18.0"
1015 | }
1016 | },
1017 | "node_modules/@radix-ui/react-direction": {
1018 | "version": "1.0.0",
1019 | "resolved": "https://registry.npmjs.org/@radix-ui/react-direction/-/react-direction-1.0.0.tgz",
1020 | "integrity": "sha512-2HV05lGUgYcA6xgLQ4BKPDmtL+QbIZYH5fCOTAOOcJ5O0QbWS3i9lKaurLzliYUDhORI2Qr3pyjhJh44lKA3rQ==",
1021 | "dependencies": {
1022 | "@babel/runtime": "^7.13.10"
1023 | },
1024 | "peerDependencies": {
1025 | "react": "^16.8 || ^17.0 || ^18.0"
1026 | }
1027 | },
1028 | "node_modules/@radix-ui/react-presence": {
1029 | "version": "1.0.0",
1030 | "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.0.0.tgz",
1031 | "integrity": "sha512-A+6XEvN01NfVWiKu38ybawfHsBjWum42MRPnEuqPsBZ4eV7e/7K321B5VgYMPv3Xx5An6o1/l9ZuDBgmcmWK3w==",
1032 | "dependencies": {
1033 | "@babel/runtime": "^7.13.10",
1034 | "@radix-ui/react-compose-refs": "1.0.0",
1035 | "@radix-ui/react-use-layout-effect": "1.0.0"
1036 | },
1037 | "peerDependencies": {
1038 | "react": "^16.8 || ^17.0 || ^18.0",
1039 | "react-dom": "^16.8 || ^17.0 || ^18.0"
1040 | }
1041 | },
1042 | "node_modules/@radix-ui/react-primitive": {
1043 | "version": "1.0.1",
1044 | "resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-1.0.1.tgz",
1045 | "integrity": "sha512-fHbmislWVkZaIdeF6GZxF0A/NH/3BjrGIYj+Ae6eTmTCr7EB0RQAAVEiqsXK6p3/JcRqVSBQoceZroj30Jj3XA==",
1046 | "dependencies": {
1047 | "@babel/runtime": "^7.13.10",
1048 | "@radix-ui/react-slot": "1.0.1"
1049 | },
1050 | "peerDependencies": {
1051 | "react": "^16.8 || ^17.0 || ^18.0",
1052 | "react-dom": "^16.8 || ^17.0 || ^18.0"
1053 | }
1054 | },
1055 | "node_modules/@radix-ui/react-scroll-area": {
1056 | "version": "1.0.2",
1057 | "resolved": "https://registry.npmjs.org/@radix-ui/react-scroll-area/-/react-scroll-area-1.0.2.tgz",
1058 | "integrity": "sha512-k8VseTxI26kcKJaX0HPwkvlNBPTs56JRdYzcZ/vzrNUkDlvXBy8sMc7WvCpYzZkHgb+hd72VW9MqkqecGtuNgg==",
1059 | "dependencies": {
1060 | "@babel/runtime": "^7.13.10",
1061 | "@radix-ui/number": "1.0.0",
1062 | "@radix-ui/primitive": "1.0.0",
1063 | "@radix-ui/react-compose-refs": "1.0.0",
1064 | "@radix-ui/react-context": "1.0.0",
1065 | "@radix-ui/react-direction": "1.0.0",
1066 | "@radix-ui/react-presence": "1.0.0",
1067 | "@radix-ui/react-primitive": "1.0.1",
1068 | "@radix-ui/react-use-callback-ref": "1.0.0",
1069 | "@radix-ui/react-use-layout-effect": "1.0.0"
1070 | },
1071 | "peerDependencies": {
1072 | "react": "^16.8 || ^17.0 || ^18.0",
1073 | "react-dom": "^16.8 || ^17.0 || ^18.0"
1074 | }
1075 | },
1076 | "node_modules/@radix-ui/react-slot": {
1077 | "version": "1.0.1",
1078 | "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.0.1.tgz",
1079 | "integrity": "sha512-avutXAFL1ehGvAXtPquu0YK5oz6ctS474iM3vNGQIkswrVhdrS52e3uoMQBzZhNRAIE0jBnUyXWNmSjGHhCFcw==",
1080 | "dependencies": {
1081 | "@babel/runtime": "^7.13.10",
1082 | "@radix-ui/react-compose-refs": "1.0.0"
1083 | },
1084 | "peerDependencies": {
1085 | "react": "^16.8 || ^17.0 || ^18.0"
1086 | }
1087 | },
1088 | "node_modules/@radix-ui/react-use-callback-ref": {
1089 | "version": "1.0.0",
1090 | "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.0.tgz",
1091 | "integrity": "sha512-GZtyzoHz95Rhs6S63D2t/eqvdFCm7I+yHMLVQheKM7nBD8mbZIt+ct1jz4536MDnaOGKIxynJ8eHTkVGVVkoTg==",
1092 | "dependencies": {
1093 | "@babel/runtime": "^7.13.10"
1094 | },
1095 | "peerDependencies": {
1096 | "react": "^16.8 || ^17.0 || ^18.0"
1097 | }
1098 | },
1099 | "node_modules/@radix-ui/react-use-layout-effect": {
1100 | "version": "1.0.0",
1101 | "resolved": "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.0.0.tgz",
1102 | "integrity": "sha512-6Tpkq+R6LOlmQb1R5NNETLG0B4YP0wc+klfXafpUCj6JGyaUc8il7/kUZ7m59rGbXGczE9Bs+iz2qloqsZBduQ==",
1103 | "dependencies": {
1104 | "@babel/runtime": "^7.13.10"
1105 | },
1106 | "peerDependencies": {
1107 | "react": "^16.8 || ^17.0 || ^18.0"
1108 | }
1109 | },
1110 | "node_modules/@remix-run/router": {
1111 | "version": "1.2.1",
1112 | "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.2.1.tgz",
1113 | "integrity": "sha512-XiY0IsyHR+DXYS5vBxpoBe/8veTeoRpMHP+vDosLZxL5bnpetzI0igkxkLZS235ldLzyfkxF+2divEwWHP3vMQ==",
1114 | "engines": {
1115 | "node": ">=14"
1116 | }
1117 | },
1118 | "node_modules/@types/parse-json": {
1119 | "version": "4.0.0",
1120 | "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz",
1121 | "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA=="
1122 | },
1123 | "node_modules/@types/prop-types": {
1124 | "version": "15.7.5",
1125 | "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.5.tgz",
1126 | "integrity": "sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w==",
1127 | "devOptional": true
1128 | },
1129 | "node_modules/@types/react": {
1130 | "version": "18.0.26",
1131 | "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.26.tgz",
1132 | "integrity": "sha512-hCR3PJQsAIXyxhTNSiDFY//LhnMZWpNNr5etoCqx/iUfGc5gXWtQR2Phl908jVR6uPXacojQWTg4qRpkxTuGug==",
1133 | "devOptional": true,
1134 | "dependencies": {
1135 | "@types/prop-types": "*",
1136 | "@types/scheduler": "*",
1137 | "csstype": "^3.0.2"
1138 | }
1139 | },
1140 | "node_modules/@types/react-dom": {
1141 | "version": "18.0.10",
1142 | "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-18.0.10.tgz",
1143 | "integrity": "sha512-E42GW/JA4Qv15wQdqJq8DL4JhNpB3prJgjgapN3qJT9K2zO5IIAQh4VXvCEDupoqAwnz0cY4RlXeC/ajX5SFHg==",
1144 | "dev": true,
1145 | "dependencies": {
1146 | "@types/react": "*"
1147 | }
1148 | },
1149 | "node_modules/@types/scheduler": {
1150 | "version": "0.16.2",
1151 | "resolved": "https://registry.npmjs.org/@types/scheduler/-/scheduler-0.16.2.tgz",
1152 | "integrity": "sha512-hppQEBDmlwhFAXKJX2KnWLYu5yMfi91yazPb2l+lbJiwW+wdo1gNeRA+3RgNSO39WYX2euey41KEwnqesU2Jew==",
1153 | "devOptional": true
1154 | },
1155 | "node_modules/@vitejs/plugin-react": {
1156 | "version": "3.0.0",
1157 | "resolved": "https://registry.npmjs.org/@vitejs/plugin-react/-/plugin-react-3.0.0.tgz",
1158 | "integrity": "sha512-1mvyPc0xYW5G8CHQvJIJXLoMjl5Ct3q2g5Y2s6Ccfgwm45y48LBvsla7az+GkkAtYikWQ4Lxqcsq5RHLcZgtNQ==",
1159 | "dev": true,
1160 | "dependencies": {
1161 | "@babel/core": "^7.20.5",
1162 | "@babel/plugin-transform-react-jsx-self": "^7.18.6",
1163 | "@babel/plugin-transform-react-jsx-source": "^7.19.6",
1164 | "magic-string": "^0.27.0",
1165 | "react-refresh": "^0.14.0"
1166 | },
1167 | "engines": {
1168 | "node": "^14.18.0 || >=16.0.0"
1169 | },
1170 | "peerDependencies": {
1171 | "vite": "^4.0.0"
1172 | }
1173 | },
1174 | "node_modules/ansi-styles": {
1175 | "version": "3.2.1",
1176 | "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
1177 | "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
1178 | "dependencies": {
1179 | "color-convert": "^1.9.0"
1180 | },
1181 | "engines": {
1182 | "node": ">=4"
1183 | }
1184 | },
1185 | "node_modules/aria-hidden": {
1186 | "version": "1.2.2",
1187 | "resolved": "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.2.tgz",
1188 | "integrity": "sha512-6y/ogyDTk/7YAe91T3E2PR1ALVKyM2QbTio5HwM+N1Q6CMlCKhvClyIjkckBswa0f2xJhjsfzIGa1yVSe1UMVA==",
1189 | "dependencies": {
1190 | "tslib": "^2.0.0"
1191 | },
1192 | "engines": {
1193 | "node": ">=10"
1194 | },
1195 | "peerDependencies": {
1196 | "@types/react": "^16.9.0 || ^17.0.0 || ^18.0.0",
1197 | "react": "^16.9.0 || ^17.0.0 || ^18.0.0"
1198 | },
1199 | "peerDependenciesMeta": {
1200 | "@types/react": {
1201 | "optional": true
1202 | }
1203 | }
1204 | },
1205 | "node_modules/babel-plugin-macros": {
1206 | "version": "3.1.0",
1207 | "resolved": "https://registry.npmjs.org/babel-plugin-macros/-/babel-plugin-macros-3.1.0.tgz",
1208 | "integrity": "sha512-Cg7TFGpIr01vOQNODXOOaGz2NpCU5gl8x1qJFbb6hbZxR7XrcE2vtbAsTAbJ7/xwJtUuJEw8K8Zr/AE0LHlesg==",
1209 | "dependencies": {
1210 | "@babel/runtime": "^7.12.5",
1211 | "cosmiconfig": "^7.0.0",
1212 | "resolve": "^1.19.0"
1213 | },
1214 | "engines": {
1215 | "node": ">=10",
1216 | "npm": ">=6"
1217 | }
1218 | },
1219 | "node_modules/browserslist": {
1220 | "version": "4.21.4",
1221 | "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.21.4.tgz",
1222 | "integrity": "sha512-CBHJJdDmgjl3daYjN5Cp5kbTf1mUhZoS+beLklHIvkOWscs83YAhLlF3Wsh/lciQYAcbBJgTOD44VtG31ZM4Hw==",
1223 | "funding": [
1224 | {
1225 | "type": "opencollective",
1226 | "url": "https://opencollective.com/browserslist"
1227 | },
1228 | {
1229 | "type": "tidelift",
1230 | "url": "https://tidelift.com/funding/github/npm/browserslist"
1231 | }
1232 | ],
1233 | "dependencies": {
1234 | "caniuse-lite": "^1.0.30001400",
1235 | "electron-to-chromium": "^1.4.251",
1236 | "node-releases": "^2.0.6",
1237 | "update-browserslist-db": "^1.0.9"
1238 | },
1239 | "bin": {
1240 | "browserslist": "cli.js"
1241 | },
1242 | "engines": {
1243 | "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7"
1244 | }
1245 | },
1246 | "node_modules/callsites": {
1247 | "version": "3.1.0",
1248 | "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
1249 | "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==",
1250 | "engines": {
1251 | "node": ">=6"
1252 | }
1253 | },
1254 | "node_modules/caniuse-lite": {
1255 | "version": "1.0.30001441",
1256 | "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001441.tgz",
1257 | "integrity": "sha512-OyxRR4Vof59I3yGWXws6i908EtGbMzVUi3ganaZQHmydk1iwDhRnvaPG2WaR0KcqrDFKrxVZHULT396LEPhXfg==",
1258 | "funding": [
1259 | {
1260 | "type": "opencollective",
1261 | "url": "https://opencollective.com/browserslist"
1262 | },
1263 | {
1264 | "type": "tidelift",
1265 | "url": "https://tidelift.com/funding/github/npm/caniuse-lite"
1266 | }
1267 | ]
1268 | },
1269 | "node_modules/chalk": {
1270 | "version": "2.4.2",
1271 | "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz",
1272 | "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==",
1273 | "dependencies": {
1274 | "ansi-styles": "^3.2.1",
1275 | "escape-string-regexp": "^1.0.5",
1276 | "supports-color": "^5.3.0"
1277 | },
1278 | "engines": {
1279 | "node": ">=4"
1280 | }
1281 | },
1282 | "node_modules/chalk/node_modules/escape-string-regexp": {
1283 | "version": "1.0.5",
1284 | "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
1285 | "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==",
1286 | "engines": {
1287 | "node": ">=0.8.0"
1288 | }
1289 | },
1290 | "node_modules/clsx": {
1291 | "version": "1.1.1",
1292 | "resolved": "https://registry.npmjs.org/clsx/-/clsx-1.1.1.tgz",
1293 | "integrity": "sha512-6/bPho624p3S2pMyvP5kKBPXnI3ufHLObBFCfgx+LkeR5lg2XYy2hqZqUf45ypD8COn2bhgGJSUE+l5dhNBieA==",
1294 | "engines": {
1295 | "node": ">=6"
1296 | }
1297 | },
1298 | "node_modules/color-convert": {
1299 | "version": "1.9.3",
1300 | "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz",
1301 | "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==",
1302 | "dependencies": {
1303 | "color-name": "1.1.3"
1304 | }
1305 | },
1306 | "node_modules/color-name": {
1307 | "version": "1.1.3",
1308 | "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
1309 | "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw=="
1310 | },
1311 | "node_modules/convert-source-map": {
1312 | "version": "1.9.0",
1313 | "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.9.0.tgz",
1314 | "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A=="
1315 | },
1316 | "node_modules/cosmiconfig": {
1317 | "version": "7.1.0",
1318 | "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.1.0.tgz",
1319 | "integrity": "sha512-AdmX6xUzdNASswsFtmwSt7Vj8po9IuqXm0UXz7QKPuEUmPB4XyjGfaAr2PSuELMwkRMVH1EpIkX5bTZGRB3eCA==",
1320 | "dependencies": {
1321 | "@types/parse-json": "^4.0.0",
1322 | "import-fresh": "^3.2.1",
1323 | "parse-json": "^5.0.0",
1324 | "path-type": "^4.0.0",
1325 | "yaml": "^1.10.0"
1326 | },
1327 | "engines": {
1328 | "node": ">=10"
1329 | }
1330 | },
1331 | "node_modules/csstype": {
1332 | "version": "3.1.1",
1333 | "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.1.tgz",
1334 | "integrity": "sha512-DJR/VvkAvSZW9bTouZue2sSxDwdTN92uHjqeKVm+0dAqdfNykRzQ95tay8aXMBAAPpUiq4Qcug2L7neoRh2Egw=="
1335 | },
1336 | "node_modules/debug": {
1337 | "version": "4.3.4",
1338 | "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz",
1339 | "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==",
1340 | "dependencies": {
1341 | "ms": "2.1.2"
1342 | },
1343 | "engines": {
1344 | "node": ">=6.0"
1345 | },
1346 | "peerDependenciesMeta": {
1347 | "supports-color": {
1348 | "optional": true
1349 | }
1350 | }
1351 | },
1352 | "node_modules/electron-to-chromium": {
1353 | "version": "1.4.284",
1354 | "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.284.tgz",
1355 | "integrity": "sha512-M8WEXFuKXMYMVr45fo8mq0wUrrJHheiKZf6BArTKk9ZBYCKJEOU5H8cdWgDT+qCVZf7Na4lVUaZsA+h6uA9+PA=="
1356 | },
1357 | "node_modules/error-ex": {
1358 | "version": "1.3.2",
1359 | "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz",
1360 | "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==",
1361 | "dependencies": {
1362 | "is-arrayish": "^0.2.1"
1363 | }
1364 | },
1365 | "node_modules/esbuild": {
1366 | "version": "0.16.13",
1367 | "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.16.13.tgz",
1368 | "integrity": "sha512-oYwFdSEIoKM1oYzyem1osgKJAvg5447XF+05ava21fOtilyb2HeQQh26/74K4WeAk5dZmj/Mx10zUqUnI14jhA==",
1369 | "dev": true,
1370 | "hasInstallScript": true,
1371 | "bin": {
1372 | "esbuild": "bin/esbuild"
1373 | },
1374 | "engines": {
1375 | "node": ">=12"
1376 | },
1377 | "optionalDependencies": {
1378 | "@esbuild/android-arm": "0.16.13",
1379 | "@esbuild/android-arm64": "0.16.13",
1380 | "@esbuild/android-x64": "0.16.13",
1381 | "@esbuild/darwin-arm64": "0.16.13",
1382 | "@esbuild/darwin-x64": "0.16.13",
1383 | "@esbuild/freebsd-arm64": "0.16.13",
1384 | "@esbuild/freebsd-x64": "0.16.13",
1385 | "@esbuild/linux-arm": "0.16.13",
1386 | "@esbuild/linux-arm64": "0.16.13",
1387 | "@esbuild/linux-ia32": "0.16.13",
1388 | "@esbuild/linux-loong64": "0.16.13",
1389 | "@esbuild/linux-mips64el": "0.16.13",
1390 | "@esbuild/linux-ppc64": "0.16.13",
1391 | "@esbuild/linux-riscv64": "0.16.13",
1392 | "@esbuild/linux-s390x": "0.16.13",
1393 | "@esbuild/linux-x64": "0.16.13",
1394 | "@esbuild/netbsd-x64": "0.16.13",
1395 | "@esbuild/openbsd-x64": "0.16.13",
1396 | "@esbuild/sunos-x64": "0.16.13",
1397 | "@esbuild/win32-arm64": "0.16.13",
1398 | "@esbuild/win32-ia32": "0.16.13",
1399 | "@esbuild/win32-x64": "0.16.13"
1400 | }
1401 | },
1402 | "node_modules/escalade": {
1403 | "version": "3.1.1",
1404 | "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
1405 | "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==",
1406 | "engines": {
1407 | "node": ">=6"
1408 | }
1409 | },
1410 | "node_modules/escape-string-regexp": {
1411 | "version": "4.0.0",
1412 | "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz",
1413 | "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==",
1414 | "engines": {
1415 | "node": ">=10"
1416 | },
1417 | "funding": {
1418 | "url": "https://github.com/sponsors/sindresorhus"
1419 | }
1420 | },
1421 | "node_modules/find-root": {
1422 | "version": "1.1.0",
1423 | "resolved": "https://registry.npmjs.org/find-root/-/find-root-1.1.0.tgz",
1424 | "integrity": "sha512-NKfW6bec6GfKc0SGx1e07QZY9PE99u0Bft/0rzSD5k3sO/vwkVUpDUKVm5Gpp5Ue3YfShPFTX2070tDs5kB9Ng=="
1425 | },
1426 | "node_modules/fsevents": {
1427 | "version": "2.3.2",
1428 | "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz",
1429 | "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==",
1430 | "dev": true,
1431 | "hasInstallScript": true,
1432 | "optional": true,
1433 | "os": [
1434 | "darwin"
1435 | ],
1436 | "engines": {
1437 | "node": "^8.16.0 || ^10.6.0 || >=11.0.0"
1438 | }
1439 | },
1440 | "node_modules/function-bind": {
1441 | "version": "1.1.1",
1442 | "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
1443 | "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A=="
1444 | },
1445 | "node_modules/gensync": {
1446 | "version": "1.0.0-beta.2",
1447 | "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz",
1448 | "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==",
1449 | "engines": {
1450 | "node": ">=6.9.0"
1451 | }
1452 | },
1453 | "node_modules/globals": {
1454 | "version": "11.12.0",
1455 | "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz",
1456 | "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==",
1457 | "engines": {
1458 | "node": ">=4"
1459 | }
1460 | },
1461 | "node_modules/has": {
1462 | "version": "1.0.3",
1463 | "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
1464 | "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
1465 | "dependencies": {
1466 | "function-bind": "^1.1.1"
1467 | },
1468 | "engines": {
1469 | "node": ">= 0.4.0"
1470 | }
1471 | },
1472 | "node_modules/has-flag": {
1473 | "version": "3.0.0",
1474 | "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz",
1475 | "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==",
1476 | "engines": {
1477 | "node": ">=4"
1478 | }
1479 | },
1480 | "node_modules/hoist-non-react-statics": {
1481 | "version": "3.3.2",
1482 | "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz",
1483 | "integrity": "sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==",
1484 | "dependencies": {
1485 | "react-is": "^16.7.0"
1486 | }
1487 | },
1488 | "node_modules/import-fresh": {
1489 | "version": "3.3.0",
1490 | "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz",
1491 | "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==",
1492 | "dependencies": {
1493 | "parent-module": "^1.0.0",
1494 | "resolve-from": "^4.0.0"
1495 | },
1496 | "engines": {
1497 | "node": ">=6"
1498 | },
1499 | "funding": {
1500 | "url": "https://github.com/sponsors/sindresorhus"
1501 | }
1502 | },
1503 | "node_modules/is-arrayish": {
1504 | "version": "0.2.1",
1505 | "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz",
1506 | "integrity": "sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg=="
1507 | },
1508 | "node_modules/is-core-module": {
1509 | "version": "2.11.0",
1510 | "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.11.0.tgz",
1511 | "integrity": "sha512-RRjxlvLDkD1YJwDbroBHMb+cukurkDWNyHx7D3oNB5x9rb5ogcksMC5wHCadcXoo67gVr/+3GFySh3134zi6rw==",
1512 | "dependencies": {
1513 | "has": "^1.0.3"
1514 | },
1515 | "funding": {
1516 | "url": "https://github.com/sponsors/ljharb"
1517 | }
1518 | },
1519 | "node_modules/js-tokens": {
1520 | "version": "4.0.0",
1521 | "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz",
1522 | "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ=="
1523 | },
1524 | "node_modules/jsesc": {
1525 | "version": "2.5.2",
1526 | "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz",
1527 | "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==",
1528 | "bin": {
1529 | "jsesc": "bin/jsesc"
1530 | },
1531 | "engines": {
1532 | "node": ">=4"
1533 | }
1534 | },
1535 | "node_modules/json-parse-even-better-errors": {
1536 | "version": "2.3.1",
1537 | "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz",
1538 | "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w=="
1539 | },
1540 | "node_modules/json5": {
1541 | "version": "2.2.3",
1542 | "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz",
1543 | "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==",
1544 | "bin": {
1545 | "json5": "lib/cli.js"
1546 | },
1547 | "engines": {
1548 | "node": ">=6"
1549 | }
1550 | },
1551 | "node_modules/lines-and-columns": {
1552 | "version": "1.2.4",
1553 | "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz",
1554 | "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg=="
1555 | },
1556 | "node_modules/loose-envify": {
1557 | "version": "1.4.0",
1558 | "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz",
1559 | "integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==",
1560 | "dependencies": {
1561 | "js-tokens": "^3.0.0 || ^4.0.0"
1562 | },
1563 | "bin": {
1564 | "loose-envify": "cli.js"
1565 | }
1566 | },
1567 | "node_modules/lru-cache": {
1568 | "version": "5.1.1",
1569 | "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz",
1570 | "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==",
1571 | "dependencies": {
1572 | "yallist": "^3.0.2"
1573 | }
1574 | },
1575 | "node_modules/magic-string": {
1576 | "version": "0.27.0",
1577 | "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.27.0.tgz",
1578 | "integrity": "sha512-8UnnX2PeRAPZuN12svgR9j7M1uWMovg/CEnIwIG0LFkXSJJe4PdfUGiTGl8V9bsBHFUtfVINcSyYxd7q+kx9fA==",
1579 | "dev": true,
1580 | "dependencies": {
1581 | "@jridgewell/sourcemap-codec": "^1.4.13"
1582 | },
1583 | "engines": {
1584 | "node": ">=12"
1585 | }
1586 | },
1587 | "node_modules/ms": {
1588 | "version": "2.1.2",
1589 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
1590 | "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
1591 | },
1592 | "node_modules/nanoid": {
1593 | "version": "3.3.4",
1594 | "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.4.tgz",
1595 | "integrity": "sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw==",
1596 | "dev": true,
1597 | "bin": {
1598 | "nanoid": "bin/nanoid.cjs"
1599 | },
1600 | "engines": {
1601 | "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1"
1602 | }
1603 | },
1604 | "node_modules/node-releases": {
1605 | "version": "2.0.8",
1606 | "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.8.tgz",
1607 | "integrity": "sha512-dFSmB8fFHEH/s81Xi+Y/15DQY6VHW81nXRj86EMSL3lmuTmK1e+aT4wrFCkTbm+gSwkw4KpX+rT/pMM2c1mF+A=="
1608 | },
1609 | "node_modules/parent-module": {
1610 | "version": "1.0.1",
1611 | "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz",
1612 | "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==",
1613 | "dependencies": {
1614 | "callsites": "^3.0.0"
1615 | },
1616 | "engines": {
1617 | "node": ">=6"
1618 | }
1619 | },
1620 | "node_modules/parse-json": {
1621 | "version": "5.2.0",
1622 | "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz",
1623 | "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==",
1624 | "dependencies": {
1625 | "@babel/code-frame": "^7.0.0",
1626 | "error-ex": "^1.3.1",
1627 | "json-parse-even-better-errors": "^2.3.0",
1628 | "lines-and-columns": "^1.1.6"
1629 | },
1630 | "engines": {
1631 | "node": ">=8"
1632 | },
1633 | "funding": {
1634 | "url": "https://github.com/sponsors/sindresorhus"
1635 | }
1636 | },
1637 | "node_modules/path-parse": {
1638 | "version": "1.0.7",
1639 | "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
1640 | "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw=="
1641 | },
1642 | "node_modules/path-type": {
1643 | "version": "4.0.0",
1644 | "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz",
1645 | "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==",
1646 | "engines": {
1647 | "node": ">=8"
1648 | }
1649 | },
1650 | "node_modules/picocolors": {
1651 | "version": "1.0.0",
1652 | "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
1653 | "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ=="
1654 | },
1655 | "node_modules/postcss": {
1656 | "version": "8.4.20",
1657 | "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.20.tgz",
1658 | "integrity": "sha512-6Q04AXR1212bXr5fh03u8aAwbLxAQNGQ/Q1LNa0VfOI06ZAlhPHtQvE4OIdpj4kLThXilalPnmDSOD65DcHt+g==",
1659 | "dev": true,
1660 | "funding": [
1661 | {
1662 | "type": "opencollective",
1663 | "url": "https://opencollective.com/postcss/"
1664 | },
1665 | {
1666 | "type": "tidelift",
1667 | "url": "https://tidelift.com/funding/github/npm/postcss"
1668 | }
1669 | ],
1670 | "dependencies": {
1671 | "nanoid": "^3.3.4",
1672 | "picocolors": "^1.0.0",
1673 | "source-map-js": "^1.0.2"
1674 | },
1675 | "engines": {
1676 | "node": "^10 || ^12 || >=14"
1677 | }
1678 | },
1679 | "node_modules/react": {
1680 | "version": "18.2.0",
1681 | "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz",
1682 | "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==",
1683 | "dependencies": {
1684 | "loose-envify": "^1.1.0"
1685 | },
1686 | "engines": {
1687 | "node": ">=0.10.0"
1688 | }
1689 | },
1690 | "node_modules/react-dom": {
1691 | "version": "18.2.0",
1692 | "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.2.0.tgz",
1693 | "integrity": "sha512-6IMTriUmvsjHUjNtEDudZfuDQUoWXVxKHhlEGSk81n4YFS+r/Kl99wXiwlVXtPBtJenozv2P+hxDsw9eA7Xo6g==",
1694 | "dependencies": {
1695 | "loose-envify": "^1.1.0",
1696 | "scheduler": "^0.23.0"
1697 | },
1698 | "peerDependencies": {
1699 | "react": "^18.2.0"
1700 | }
1701 | },
1702 | "node_modules/react-icons": {
1703 | "version": "4.7.1",
1704 | "resolved": "https://registry.npmjs.org/react-icons/-/react-icons-4.7.1.tgz",
1705 | "integrity": "sha512-yHd3oKGMgm7zxo3EA7H2n7vxSoiGmHk5t6Ou4bXsfcgWyhfDKMpyKfhHR6Bjnn63c+YXBLBPUql9H4wPJM6sXw==",
1706 | "peerDependencies": {
1707 | "react": "*"
1708 | }
1709 | },
1710 | "node_modules/react-is": {
1711 | "version": "16.13.1",
1712 | "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz",
1713 | "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ=="
1714 | },
1715 | "node_modules/react-refresh": {
1716 | "version": "0.14.0",
1717 | "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.14.0.tgz",
1718 | "integrity": "sha512-wViHqhAd8OHeLS/IRMJjTSDHF3U9eWi62F/MledQGPdJGDhodXJ9PBLNGr6WWL7qlH12Mt3TyTpbS+hGXMjCzQ==",
1719 | "dev": true,
1720 | "engines": {
1721 | "node": ">=0.10.0"
1722 | }
1723 | },
1724 | "node_modules/react-router": {
1725 | "version": "6.6.1",
1726 | "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.6.1.tgz",
1727 | "integrity": "sha512-YkvlYRusnI/IN0kDtosUCgxqHeulN5je+ew8W+iA1VvFhf86kA+JEI/X/8NqYcr11hCDDp906S+SGMpBheNeYQ==",
1728 | "dependencies": {
1729 | "@remix-run/router": "1.2.1"
1730 | },
1731 | "engines": {
1732 | "node": ">=14"
1733 | },
1734 | "peerDependencies": {
1735 | "react": ">=16.8"
1736 | }
1737 | },
1738 | "node_modules/react-router-dom": {
1739 | "version": "6.6.1",
1740 | "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.6.1.tgz",
1741 | "integrity": "sha512-u+8BKUtelStKbZD5UcY0NY90WOzktrkJJhyhNg7L0APn9t1qJNLowzrM9CHdpB6+rcPt6qQrlkIXsTvhuXP68g==",
1742 | "dependencies": {
1743 | "@remix-run/router": "1.2.1",
1744 | "react-router": "6.6.1"
1745 | },
1746 | "engines": {
1747 | "node": ">=14"
1748 | },
1749 | "peerDependencies": {
1750 | "react": ">=16.8",
1751 | "react-dom": ">=16.8"
1752 | }
1753 | },
1754 | "node_modules/react-textarea-autosize": {
1755 | "version": "8.3.4",
1756 | "resolved": "https://registry.npmjs.org/react-textarea-autosize/-/react-textarea-autosize-8.3.4.tgz",
1757 | "integrity": "sha512-CdtmP8Dc19xL8/R6sWvtknD/eCXkQr30dtvC4VmGInhRsfF8X/ihXCq6+9l9qbxmKRiq407/7z5fxE7cVWQNgQ==",
1758 | "dependencies": {
1759 | "@babel/runtime": "^7.10.2",
1760 | "use-composed-ref": "^1.3.0",
1761 | "use-latest": "^1.2.1"
1762 | },
1763 | "engines": {
1764 | "node": ">=10"
1765 | },
1766 | "peerDependencies": {
1767 | "react": "^16.8.0 || ^17.0.0 || ^18.0.0"
1768 | }
1769 | },
1770 | "node_modules/regenerator-runtime": {
1771 | "version": "0.13.11",
1772 | "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz",
1773 | "integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg=="
1774 | },
1775 | "node_modules/resolve": {
1776 | "version": "1.22.1",
1777 | "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz",
1778 | "integrity": "sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw==",
1779 | "dependencies": {
1780 | "is-core-module": "^2.9.0",
1781 | "path-parse": "^1.0.7",
1782 | "supports-preserve-symlinks-flag": "^1.0.0"
1783 | },
1784 | "bin": {
1785 | "resolve": "bin/resolve"
1786 | },
1787 | "funding": {
1788 | "url": "https://github.com/sponsors/ljharb"
1789 | }
1790 | },
1791 | "node_modules/resolve-from": {
1792 | "version": "4.0.0",
1793 | "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz",
1794 | "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==",
1795 | "engines": {
1796 | "node": ">=4"
1797 | }
1798 | },
1799 | "node_modules/rollup": {
1800 | "version": "3.9.1",
1801 | "resolved": "https://registry.npmjs.org/rollup/-/rollup-3.9.1.tgz",
1802 | "integrity": "sha512-GswCYHXftN8ZKGVgQhTFUJB/NBXxrRGgO2NCy6E8s1rwEJ4Q9/VttNqcYfEvx4dTo4j58YqdC3OVztPzlKSX8w==",
1803 | "dev": true,
1804 | "bin": {
1805 | "rollup": "dist/bin/rollup"
1806 | },
1807 | "engines": {
1808 | "node": ">=14.18.0",
1809 | "npm": ">=8.0.0"
1810 | },
1811 | "optionalDependencies": {
1812 | "fsevents": "~2.3.2"
1813 | }
1814 | },
1815 | "node_modules/scheduler": {
1816 | "version": "0.23.0",
1817 | "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.23.0.tgz",
1818 | "integrity": "sha512-CtuThmgHNg7zIZWAXi3AsyIzA3n4xx7aNyjwC2VJldO2LMVDhFK+63xGqq6CsJH4rTAt6/M+N4GhZiDYPx9eUw==",
1819 | "dependencies": {
1820 | "loose-envify": "^1.1.0"
1821 | }
1822 | },
1823 | "node_modules/semver": {
1824 | "version": "6.3.0",
1825 | "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz",
1826 | "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==",
1827 | "bin": {
1828 | "semver": "bin/semver.js"
1829 | }
1830 | },
1831 | "node_modules/source-map": {
1832 | "version": "0.5.7",
1833 | "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz",
1834 | "integrity": "sha512-LbrmJOMUSdEVxIKvdcJzQC+nQhe8FUZQTXQy6+I75skNgn3OoQ0DZA8YnFa7gp8tqtL3KPf1kmo0R5DoApeSGQ==",
1835 | "engines": {
1836 | "node": ">=0.10.0"
1837 | }
1838 | },
1839 | "node_modules/source-map-js": {
1840 | "version": "1.0.2",
1841 | "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz",
1842 | "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==",
1843 | "dev": true,
1844 | "engines": {
1845 | "node": ">=0.10.0"
1846 | }
1847 | },
1848 | "node_modules/stylis": {
1849 | "version": "4.1.3",
1850 | "resolved": "https://registry.npmjs.org/stylis/-/stylis-4.1.3.tgz",
1851 | "integrity": "sha512-GP6WDNWf+o403jrEp9c5jibKavrtLW+/qYGhFxFrG8maXhwTBI7gLLhiBb0o7uFccWN+EOS9aMO6cGHWAO07OA=="
1852 | },
1853 | "node_modules/supports-color": {
1854 | "version": "5.5.0",
1855 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz",
1856 | "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==",
1857 | "dependencies": {
1858 | "has-flag": "^3.0.0"
1859 | },
1860 | "engines": {
1861 | "node": ">=4"
1862 | }
1863 | },
1864 | "node_modules/supports-preserve-symlinks-flag": {
1865 | "version": "1.0.0",
1866 | "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",
1867 | "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==",
1868 | "engines": {
1869 | "node": ">= 0.4"
1870 | },
1871 | "funding": {
1872 | "url": "https://github.com/sponsors/ljharb"
1873 | }
1874 | },
1875 | "node_modules/to-fast-properties": {
1876 | "version": "2.0.0",
1877 | "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz",
1878 | "integrity": "sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog==",
1879 | "engines": {
1880 | "node": ">=4"
1881 | }
1882 | },
1883 | "node_modules/tslib": {
1884 | "version": "2.4.1",
1885 | "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.1.tgz",
1886 | "integrity": "sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA=="
1887 | },
1888 | "node_modules/typescript": {
1889 | "version": "4.9.4",
1890 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.4.tgz",
1891 | "integrity": "sha512-Uz+dTXYzxXXbsFpM86Wh3dKCxrQqUcVMxwU54orwlJjOpO3ao8L7j5lH+dWfTwgCwIuM9GQ2kvVotzYJMXTBZg==",
1892 | "dev": true,
1893 | "bin": {
1894 | "tsc": "bin/tsc",
1895 | "tsserver": "bin/tsserver"
1896 | },
1897 | "engines": {
1898 | "node": ">=4.2.0"
1899 | }
1900 | },
1901 | "node_modules/update-browserslist-db": {
1902 | "version": "1.0.10",
1903 | "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.10.tgz",
1904 | "integrity": "sha512-OztqDenkfFkbSG+tRxBeAnCVPckDBcvibKd35yDONx6OU8N7sqgwc7rCbkJ/WcYtVRZ4ba68d6byhC21GFh7sQ==",
1905 | "funding": [
1906 | {
1907 | "type": "opencollective",
1908 | "url": "https://opencollective.com/browserslist"
1909 | },
1910 | {
1911 | "type": "tidelift",
1912 | "url": "https://tidelift.com/funding/github/npm/browserslist"
1913 | }
1914 | ],
1915 | "dependencies": {
1916 | "escalade": "^3.1.1",
1917 | "picocolors": "^1.0.0"
1918 | },
1919 | "bin": {
1920 | "browserslist-lint": "cli.js"
1921 | },
1922 | "peerDependencies": {
1923 | "browserslist": ">= 4.21.0"
1924 | }
1925 | },
1926 | "node_modules/use-composed-ref": {
1927 | "version": "1.3.0",
1928 | "resolved": "https://registry.npmjs.org/use-composed-ref/-/use-composed-ref-1.3.0.tgz",
1929 | "integrity": "sha512-GLMG0Jc/jiKov/3Ulid1wbv3r54K9HlMW29IWcDFPEqFkSO2nS0MuefWgMJpeHQ9YJeXDL3ZUF+P3jdXlZX/cQ==",
1930 | "peerDependencies": {
1931 | "react": "^16.8.0 || ^17.0.0 || ^18.0.0"
1932 | }
1933 | },
1934 | "node_modules/use-isomorphic-layout-effect": {
1935 | "version": "1.1.2",
1936 | "resolved": "https://registry.npmjs.org/use-isomorphic-layout-effect/-/use-isomorphic-layout-effect-1.1.2.tgz",
1937 | "integrity": "sha512-49L8yCO3iGT/ZF9QttjwLF/ZD9Iwto5LnH5LmEdk/6cFmXddqi2ulF0edxTwjj+7mqvpVVGQWvbXZdn32wRSHA==",
1938 | "peerDependencies": {
1939 | "react": "^16.8.0 || ^17.0.0 || ^18.0.0"
1940 | },
1941 | "peerDependenciesMeta": {
1942 | "@types/react": {
1943 | "optional": true
1944 | }
1945 | }
1946 | },
1947 | "node_modules/use-latest": {
1948 | "version": "1.2.1",
1949 | "resolved": "https://registry.npmjs.org/use-latest/-/use-latest-1.2.1.tgz",
1950 | "integrity": "sha512-xA+AVm/Wlg3e2P/JiItTziwS7FK92LWrDB0p+hgXloIMuVCeJJ8v6f0eeHyPZaJrM+usM1FkFfbNCrJGs8A/zw==",
1951 | "dependencies": {
1952 | "use-isomorphic-layout-effect": "^1.1.1"
1953 | },
1954 | "peerDependencies": {
1955 | "react": "^16.8.0 || ^17.0.0 || ^18.0.0"
1956 | },
1957 | "peerDependenciesMeta": {
1958 | "@types/react": {
1959 | "optional": true
1960 | }
1961 | }
1962 | },
1963 | "node_modules/vite": {
1964 | "version": "4.0.3",
1965 | "resolved": "https://registry.npmjs.org/vite/-/vite-4.0.3.tgz",
1966 | "integrity": "sha512-HvuNv1RdE7deIfQb8mPk51UKjqptO/4RXZ5yXSAvurd5xOckwS/gg8h9Tky3uSbnjYTgUm0hVCet1cyhKd73ZA==",
1967 | "dev": true,
1968 | "dependencies": {
1969 | "esbuild": "^0.16.3",
1970 | "postcss": "^8.4.20",
1971 | "resolve": "^1.22.1",
1972 | "rollup": "^3.7.0"
1973 | },
1974 | "bin": {
1975 | "vite": "bin/vite.js"
1976 | },
1977 | "engines": {
1978 | "node": "^14.18.0 || >=16.0.0"
1979 | },
1980 | "optionalDependencies": {
1981 | "fsevents": "~2.3.2"
1982 | },
1983 | "peerDependencies": {
1984 | "@types/node": ">= 14",
1985 | "less": "*",
1986 | "sass": "*",
1987 | "stylus": "*",
1988 | "sugarss": "*",
1989 | "terser": "^5.4.0"
1990 | },
1991 | "peerDependenciesMeta": {
1992 | "@types/node": {
1993 | "optional": true
1994 | },
1995 | "less": {
1996 | "optional": true
1997 | },
1998 | "sass": {
1999 | "optional": true
2000 | },
2001 | "stylus": {
2002 | "optional": true
2003 | },
2004 | "sugarss": {
2005 | "optional": true
2006 | },
2007 | "terser": {
2008 | "optional": true
2009 | }
2010 | }
2011 | },
2012 | "node_modules/yallist": {
2013 | "version": "3.1.1",
2014 | "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz",
2015 | "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g=="
2016 | },
2017 | "node_modules/yaml": {
2018 | "version": "1.10.2",
2019 | "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz",
2020 | "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==",
2021 | "engines": {
2022 | "node": ">= 6"
2023 | }
2024 | }
2025 | }
2026 | }
2027 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "expensetracker",
3 | "private": true,
4 | "version": "0.0.0",
5 | "type": "module",
6 | "scripts": {
7 | "dev": "vite",
8 | "build": "tsc && vite build",
9 | "preview": "vite preview"
10 | },
11 | "dependencies": {
12 | "@emotion/react": "^11.10.5",
13 | "@mantine/core": "^5.9.6",
14 | "@mantine/hooks": "^5.9.6",
15 | "react": "^18.2.0",
16 | "react-dom": "^18.2.0",
17 | "react-icons": "^4.7.1",
18 | "react-router-dom": "^6.6.1"
19 | },
20 | "devDependencies": {
21 | "@types/react": "^18.0.26",
22 | "@types/react-dom": "^18.0.9",
23 | "@vitejs/plugin-react": "^3.0.0",
24 | "typescript": "^4.9.3",
25 | "vite": "^4.0.0"
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/public/icons8-calculator-64.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/HamzaAbouJaib/React-Expense-Tracker-App/a3620adceb4735287402b7f8a36101321254489c/public/icons8-calculator-64.png
--------------------------------------------------------------------------------
/src/App.tsx:
--------------------------------------------------------------------------------
1 | import { Paper } from "@mantine/core";
2 | import { MantineProvider } from "@mantine/core";
3 | import MainAppShell from "./components/MainAppShell";
4 | import { AvailableCategoriesContextProvider } from "./store/AvailableCategoriesContext";
5 | import { CategoriesContextProvider } from "./store/CategoriesContext";
6 | import { HistoryContextProvider } from "./store/HistoryContext";
7 |
8 | export default function App() {
9 | return (
10 | // Global styles
11 |
18 |
19 | {/* Contexts */}
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 | );
30 | }
31 |
--------------------------------------------------------------------------------
/src/components/AddToBudget.tsx:
--------------------------------------------------------------------------------
1 | import { useState, useContext } from "react";
2 | import { useNavigate } from "react-router-dom";
3 | import { Button, TextInput } from "@mantine/core";
4 | import HistoryContext from "../store/HistoryContext";
5 | import CategoriesContext from "../store/CategoriesContext";
6 |
7 | const AddToBudget = () => {
8 | const { addCategory } = useContext(CategoriesContext);
9 | const { addHistoryElement } = useContext(HistoryContext);
10 |
11 | const [label, setLabel] = useState("");
12 | const [value, setValue] = useState(0);
13 | const navigate = useNavigate();
14 | return (
15 |
16 | setLabel(e.currentTarget.value)}
18 | mt={20}
19 | size="md"
20 | w="40%"
21 | placeholder="Ex: Christmas bonus"
22 | label="Label"
23 | withAsterisk
24 | />
25 | setValue(Number.parseFloat(e.currentTarget.value))}
27 | mt={20}
28 | size="md"
29 | w="40%"
30 | placeholder="Ex: 3000"
31 | label="Amount"
32 | withAsterisk
33 | />
34 | {
37 | // Checks if the user input is valid
38 | if (label === "" || value <= 0 || Number.isNaN(value)) {
39 | alert(
40 | "Invalid Entries. Make sure the label is not empty and the amount is greater than zero."
41 | );
42 | } else {
43 | addCategory({
44 | label: "Budget",
45 | id: crypto.randomUUID(),
46 | amount: value,
47 | });
48 | // navigate to home page
49 | navigate("/");
50 | addHistoryElement({
51 | label: label,
52 | amount: value,
53 | id: crypto.randomUUID(),
54 | type: "Budget",
55 | dateCreated: "",
56 | category: "Budget",
57 | });
58 | }
59 | }}
60 | >
61 | Add To Budget
62 |
63 |
64 | );
65 | };
66 |
67 | export default AddToBudget;
68 |
--------------------------------------------------------------------------------
/src/components/AddToExpenses.tsx:
--------------------------------------------------------------------------------
1 | import { Button, Divider, MultiSelect, Text, TextInput } from "@mantine/core";
2 | import { useState, useContext } from "react";
3 | import { useNavigate } from "react-router-dom";
4 | import AvailableCategoriesContext from "../store/AvailableCategoriesContext";
5 | import CategoriesContext from "../store/CategoriesContext";
6 | import HistoryContext from "../store/HistoryContext";
7 | import DeleteCatToolTip from "./DeleteCatToolTip";
8 |
9 | type AvailableCategories = {
10 | label: string;
11 | value: string;
12 | isused: string;
13 | };
14 |
15 | const AddToExpenses = () => {
16 | const { addHistoryElement } = useContext(HistoryContext);
17 | const { availableCategories, setAvailableCategories } = useContext(
18 | AvailableCategoriesContext
19 | );
20 | const { addCategory } = useContext(CategoriesContext);
21 | const [label, setLabel] = useState("");
22 | const [value, setValue] = useState(0);
23 |
24 | const [category, setCategory] = useState([""]);
25 | const navigate = useNavigate();
26 |
27 | return (
28 |
29 |
setLabel(e.currentTarget.value)}
31 | mt={20}
32 | size="md"
33 | w="40%"
34 | placeholder="Ex: Car payments"
35 | label="Label"
36 | withAsterisk
37 | />
38 | setValue(Number.parseFloat(e.currentTarget.value))}
40 | mt={20}
41 | size="md"
42 | w="40%"
43 | placeholder="Ex: 3000"
44 | label="Amount"
45 | withAsterisk
46 | />
47 |
48 | ({
52 | color:
53 | theme.colorScheme === "dark"
54 | ? theme.colors.dark[0]
55 | : theme.colors.gray[9],
56 | })}
57 | >
58 | Add a Category to Your Expense
59 |
60 |
72 | `+ Create ${query[0].toUpperCase() + query.substring(1)}`
73 | }
74 | onCreate={(query) => {
75 | const capQuery = query[0].toUpperCase() + query.substring(1);
76 | const item = {
77 | value: capQuery,
78 | label: capQuery,
79 | isused: "false",
80 | };
81 | console.log("hello");
82 |
83 | setAvailableCategories((current) => [item, ...current]);
84 | return item;
85 | }}
86 | />
87 |
88 | {
91 | if (label === "" || value <= 0 || Number.isNaN(value)) {
92 | alert(
93 | "Invalid Entries. Make sure the label is not empty and the amount is greater than zero."
94 | );
95 | } else {
96 | // if the user does not select a category while creating his expense, set category equal to 'Uncatigorized'
97 | category[0] === undefined ||
98 | category[0] === null ||
99 | category[0] === ""
100 | ? (category[0] = "Uncategorized")
101 | : null;
102 | addCategory({
103 | label: category[0],
104 | amount: value,
105 | id: crypto.randomUUID(),
106 | });
107 | setAvailableCategories((prev) => {
108 | // set the isused property of the available category selected to true
109 | return prev.map((c) => {
110 | if (c.label === category[0]) {
111 | c.isused = "true";
112 | }
113 | return c;
114 | });
115 | });
116 | // navigate back to the home page
117 | navigate("/");
118 | addHistoryElement({
119 | label: label,
120 | amount: value,
121 | id: crypto.randomUUID(),
122 | type: "Expense",
123 | dateCreated: "",
124 | category: category[0],
125 | });
126 | }
127 | }}
128 | >
129 | Add Expense
130 |
131 | {
134 | // Checks if the user has not selected a category
135 | if (category[0] === "") {
136 | alert("No category has been selected!");
137 | } else {
138 | // if they have selected a category
139 |
140 | // Uncategorized cannot be removed
141 | if (category[0] === "Uncategorized") {
142 | alert("Uncategorized cannot be removed!");
143 | return;
144 | }
145 | let removed = false; // used to check if the category has been removed
146 | setAvailableCategories((prev) => {
147 | // create a hard copy of the previous category state
148 | const arr: AvailableCategories[] = JSON.parse(
149 | JSON.stringify(prev)
150 | );
151 | // if the category selected exists in the available categories array and its match is not being used remove the category
152 | arr.forEach((c, index) => {
153 | if (c.label === category[0] && c.isused === "false") {
154 | arr.splice(index, 1);
155 | removed = true;
156 | }
157 | });
158 |
159 | return arr;
160 | });
161 | // if the category has not been removed then it is being used. Show an alert to notify the user
162 | removed
163 | ? null
164 | : alert("Category cannot be removed since it is being used.");
165 | }
166 | }}
167 | >
168 | Remove Category
169 |
170 |
171 |
172 |
173 | );
174 | };
175 |
176 | export default AddToExpenses;
177 |
--------------------------------------------------------------------------------
/src/components/DarkLightThemeButton.tsx:
--------------------------------------------------------------------------------
1 | import { ActionIcon, useMantineColorScheme } from "@mantine/core";
2 | import { FiSun } from "react-icons/fi";
3 | import { BsMoonStars } from "react-icons/bs";
4 |
5 |
6 | const DarkLightThemeButton = () => {
7 | const { colorScheme, toggleColorScheme } = useMantineColorScheme();
8 | const dark = colorScheme === "dark";
9 |
10 | return (
11 | toggleColorScheme()}
15 | title="Toggle color scheme"
16 | >
17 | {dark ? : }
18 |
19 | );
20 | };
21 |
22 | export default DarkLightThemeButton;
23 |
--------------------------------------------------------------------------------
/src/components/DeleteCatToolTip.tsx:
--------------------------------------------------------------------------------
1 | import { ActionIcon, Tooltip } from "@mantine/core";
2 | import { AiOutlineInfoCircle } from "react-icons/ai";
3 | const DeleteCatToolTip = () => {
4 | return (
5 |
12 |
13 |
14 |
15 |
16 | );
17 | };
18 |
19 | export default DeleteCatToolTip;
20 |
--------------------------------------------------------------------------------
/src/components/DisplayCard.tsx:
--------------------------------------------------------------------------------
1 | import { Card, Text } from "@mantine/core";
2 |
3 | type DisplayCardProps = {
4 | label: string;
5 | amount: number;
6 | color: string;
7 | };
8 |
9 | const DisplayCard = ({ label, amount, color }: DisplayCardProps) => {
10 | return (
11 |
17 |
18 | {label}
19 |
20 |
21 | ${amount.toLocaleString("en-US")}
22 |
23 |
24 | );
25 | };
26 |
27 | export default DisplayCard;
28 |
--------------------------------------------------------------------------------
/src/components/DisplayCategories.tsx:
--------------------------------------------------------------------------------
1 | import { useContext } from "react";
2 | import { SimpleGrid } from "@mantine/core";
3 | import DisplayCard from "./DisplayCard";
4 | import CategoriesContext from "../store/CategoriesContext";
5 |
6 | const DisplayCategories = () => {
7 | const { categories } = useContext(CategoriesContext);
8 |
9 | return (
10 |
11 | {categories.map((category) => (
12 |
18 | ))}
19 |
20 | );
21 | };
22 |
23 | export default DisplayCategories;
24 |
--------------------------------------------------------------------------------
/src/components/HistoryItem.tsx:
--------------------------------------------------------------------------------
1 | import { useState } from "react";
2 | import { Card, Text } from "@mantine/core";
3 | import HistoryModal from "./HistoryModal";
4 |
5 | type HistoryItemProps = {
6 | label: string;
7 | amount: number;
8 | type: string;
9 | id: string;
10 | dateCreated: string;
11 | category: string;
12 | };
13 |
14 | const HistoryItem = ({
15 | label,
16 | amount,
17 | type,
18 | id,
19 | dateCreated,
20 | category
21 | }: HistoryItemProps) => {
22 | const [opened, setOpened] = useState(false);
23 | // #69DB7C is green.4 and #FF8787 is red.4.
24 | const color =
25 | type === "Budget" || type === "Expenses Reset" ? "#69DB7C" : "#FF8787";
26 |
27 | return (
28 | <>
29 |
39 | {
49 | setOpened(true);
50 | }}
51 | >
52 |
53 | {/* Truncate the label if its length exceeds 44 characters */}
54 | {label.length > 44 ? label.slice(0, 44) + "..." : label}
55 |
56 |
57 | {/* Display the correct sign based on the type of transaction */}
58 | {type === "Budget" || type === "Expenses Reset" ? "+" : "-"}$
59 | {amount.toLocaleString("en-US")}
60 |
61 |
62 | >
63 | );
64 | };
65 |
66 | export default HistoryItem;
67 |
--------------------------------------------------------------------------------
/src/components/HistoryModal.tsx:
--------------------------------------------------------------------------------
1 | import { Button, Modal, Text } from "@mantine/core";
2 | import { useContext } from "react";
3 | import CategoriesContext from "../store/CategoriesContext";
4 | import HistoryContext from "../store/HistoryContext";
5 |
6 | type HistoryModalProps = {
7 | opened: boolean;
8 | setOpened: (state: boolean) => void;
9 | label: string;
10 | amount: number;
11 | dateCreated: string;
12 | id: string;
13 | type: string;
14 | category: string;
15 | };
16 |
17 | const HistoryModal = ({
18 | opened,
19 | setOpened,
20 | label,
21 | amount,
22 | dateCreated,
23 | type,
24 | id,
25 | category,
26 | }: HistoryModalProps) => {
27 | const { deleteHistoryElement } = useContext(HistoryContext);
28 | const { subtractCategoryAmount, addCategory } = useContext(
29 | CategoriesContext
30 | );
31 |
32 | return (
33 | setOpened(false)}
36 | title="Transaction Details"
37 | styles={{
38 | title: {
39 | fontSize: 20,
40 | },
41 | }}
42 | >
43 |
44 | Label: {label}
45 |
46 |
47 | Type: {type}
48 |
49 |
50 | Amount: $
51 | {amount.toLocaleString()}
52 |
53 |
54 | Category: {category}
55 |
56 |
57 | Date Created: {dateCreated}
58 |
59 |
60 | ID: {id}
61 |
62 |
70 | {
72 | setOpened(false);
73 | }}
74 | >
75 | Exit
76 |
77 | {
80 | // based on the type of transaction adjust the budget / expense amount accordingly
81 | deleteHistoryElement(id);
82 | if (type === "Expenses Reset") {
83 | // put the returned expenses in the Uncategorized category
84 | addCategory({
85 | label: "Uncategorized",
86 | amount: amount,
87 | id: crypto.randomUUID(),
88 | });
89 | } else if (type === "Budget Reset") {
90 | addCategory({
91 | label: "Budget",
92 | amount: amount,
93 | id: crypto.randomUUID(),
94 | });
95 | }
96 | // subtract the amount of the removed transaction from the category it belonged to
97 | subtractCategoryAmount(category, amount);
98 | setOpened(false);
99 | }}
100 | >
101 | Delete Item
102 |
103 |
104 |
105 | );
106 | };
107 |
108 | export default HistoryModal;
109 |
--------------------------------------------------------------------------------
/src/components/HistoryStack.tsx:
--------------------------------------------------------------------------------
1 | import { Divider, ScrollArea, Stack, Text } from "@mantine/core";
2 | import HistoryContext from "../store/HistoryContext";
3 | import HistoryItem from "./HistoryItem";
4 | import { useContext } from "react";
5 |
6 | const HistoryStack = () => {
7 | const { history } = useContext(HistoryContext);
8 |
9 | return (
10 |
11 |
({
14 | color:
15 | theme.colorScheme === "dark"
16 | ? theme.colors.dark[0]
17 | : theme.colors.gray[9],
18 | })}
19 | >
20 | Transaction History
21 |
22 |
23 |
({
26 | backgroundColor:
27 | theme.colorScheme === "dark"
28 | ? theme.colors.dark[8]
29 | : theme.colors.gray[0],
30 | height: 300,
31 | width: 500,
32 | paddingRight: 15,
33 | })}
34 | >
35 |
36 | {history.map((item) => {
37 | return (
38 |
47 | );
48 | })}
49 |
50 |
51 |
52 | );
53 | };
54 |
55 | export default HistoryStack;
56 |
--------------------------------------------------------------------------------
/src/components/MainAppShell.tsx:
--------------------------------------------------------------------------------
1 | import {
2 | AppShell,
3 | Burger,
4 | ColorScheme,
5 | ColorSchemeProvider,
6 | Header,
7 | MantineProvider,
8 | MediaQuery,
9 | Navbar,
10 | Text,
11 | useMantineTheme,
12 | } from "@mantine/core";
13 | import { useState } from "react";
14 | import { BrowserRouter, Routes, Route } from "react-router-dom";
15 | import { CgCalculator } from "react-icons/cg";
16 | import { AiOutlineHome } from "react-icons/ai";
17 | import { MdAttachMoney } from "react-icons/md";
18 | import { BsBarChartLine, BsPlusCircle } from "react-icons/bs";
19 | import NavigationLink from "./NavigationLink";
20 | import DarkLightThemeButton from "./DarkLightThemeButton";
21 | import HomePage from "../pages/HomePage";
22 | import AddBudgetPage from "../pages/AddBudgetPage";
23 | import AddExpensePage from "../pages/AddExpensePage";
24 | import { useLocalStorage } from "@mantine/hooks";
25 | import DisplayCategoriesPage from "../pages/DisplayCategoriesPage";
26 |
27 | type HistoryElement = {
28 | id: string;
29 | label: string;
30 | amount: number;
31 | type: string;
32 | };
33 |
34 | const MainAppShell = () => {
35 | const theme = useMantineTheme();
36 | const [opened, setOpened] = useState(false);
37 | const [colorScheme, setColorScheme] = useLocalStorage({
38 | key: "theme",
39 | defaultValue: "dark",
40 | });
41 | const toggleColorScheme = (value?: ColorScheme) =>
42 | setColorScheme(value || (colorScheme === "dark" ? "light" : "dark"));
43 |
44 | return (
45 | // Handles providing the correct color scheme to child elements
46 |
50 |
55 |
56 | ({
58 | main: {
59 | backgroundColor:
60 | theme.colorScheme === "dark"
61 | ? theme.colors.dark[8]
62 | : theme.colors.gray[0],
63 | },
64 | })}
65 | navbarOffsetBreakpoint="sm"
66 | asideOffsetBreakpoint="sm"
67 | navbar={
68 |
74 | }
77 | link="/"
78 | />
79 | }
82 | link="/newExpense"
83 | />
84 | }
87 | link="/newBudget"
88 | />
89 | }
92 | link="/categories"
93 | />
94 |
95 | }
96 | header={
97 |
138 | }
139 | >
140 | {/* Handle Routing */}
141 |
142 | } />
143 | } />
144 | } />
145 | } />
146 |
147 |
148 |
149 |
150 |
151 | );
152 | };
153 |
154 | export default MainAppShell;
155 |
--------------------------------------------------------------------------------
/src/components/NavigationLink.tsx:
--------------------------------------------------------------------------------
1 | import { Group, Text, ThemeIcon, UnstyledButton } from "@mantine/core";
2 | import React from "react";
3 | import { Link } from "react-router-dom";
4 |
5 | type NavigationLinkProps = {
6 | label: string;
7 | icon: React.ReactNode;
8 | link: string;
9 | };
10 |
11 | const NavigationLink = ({ icon, label, link }: NavigationLinkProps) => {
12 | return (
13 | ({
17 | display: "block",
18 | width: "100%",
19 | padding: theme.spacing.xs,
20 | borderRadius: theme.radius.sm,
21 | color:
22 | theme.colorScheme === "dark" ? theme.colors.dark[0] : theme.black,
23 |
24 | "&:hover": {
25 | backgroundColor:
26 | theme.colorScheme === "dark"
27 | ? theme.colors.dark[6]
28 | : theme.colors.gray[0],
29 | },
30 | })}
31 | >
32 |
33 |
34 | {icon}
35 |
36 | {label}
37 |
38 |
39 | );
40 | };
41 |
42 | export default NavigationLink;
43 |
--------------------------------------------------------------------------------
/src/components/PieChart.tsx:
--------------------------------------------------------------------------------
1 | import { useRef, useEffect, useContext } from "react";
2 | import CategoriesContext from "../store/CategoriesContext";
3 |
4 | type drawPieArgs = {
5 | context: CanvasRenderingContext2D;
6 | data: { type: string; amount: number; color: string }[];
7 | };
8 |
9 | function drawPie({ context, data }: drawPieArgs) {
10 | let totalAmount = data.reduce((sum, { amount }) => sum + amount, 0);
11 |
12 | //calculating the angle the slice (portion) will take in the chart
13 | let startAngle = 0;
14 | let radius = 150;
15 | let cx = 250;
16 | let cy = 200;
17 |
18 | context.clearRect(0, 0, 400, 400);
19 | data.forEach((entry) => {
20 | context.fillStyle = entry.color;
21 | context.lineWidth = 1;
22 | context.strokeStyle = "#333";
23 | context.beginPath();
24 | // draw the pie wedges
25 | let endAngle = (entry.amount / totalAmount) * Math.PI * 2 + startAngle;
26 | context.moveTo(cx, cy);
27 | context.arc(cx, cy, radius, startAngle, endAngle, false);
28 | context.lineTo(cx, cy);
29 | context.fill();
30 | context.stroke();
31 | context.closePath();
32 |
33 | // add the labels
34 | context.beginPath();
35 | context.font = "17px sans-serif";
36 | context.textAlign = "center";
37 | context.fillStyle = entry.color;
38 |
39 | let theta = (startAngle + endAngle) / 2;
40 | let deltaY = Math.sin(theta) * 1.25 * radius;
41 | let deltaX = Math.cos(theta) * 1.25 * radius;
42 | context.fillText(entry.type, deltaX + cx, deltaY + cy);
43 |
44 | context.closePath();
45 |
46 | startAngle = endAngle;
47 | });
48 | }
49 |
50 | const PieChart = () => {
51 | const { getTotalAmount } = useContext(CategoriesContext);
52 | const expenses = getTotalAmount("Expenses");
53 | const budget = getTotalAmount("Budget");
54 | const canvasRef = useRef(null);
55 |
56 | const data = [
57 | {
58 | type: "Budget",
59 | amount: budget,
60 | color: "#4BDB6B",
61 | },
62 | { type: "Expenses", amount: expenses, color: "#FF6C6C" },
63 | ];
64 |
65 | useEffect(() => {
66 | const canvas = canvasRef.current;
67 | if (!canvas) {
68 | return;
69 | }
70 |
71 | const context = canvas.getContext("2d");
72 | if (!context) {
73 | return;
74 | }
75 |
76 | drawPie({ context, data });
77 | }, [budget, expenses]);
78 |
79 | return (
80 | // use HTML canvas API to draw a pie chart
81 |
87 | );
88 | };
89 |
90 | export default PieChart;
91 |
--------------------------------------------------------------------------------
/src/components/ResetValueModal.tsx:
--------------------------------------------------------------------------------
1 | import { Button, Flex, Modal, Text } from "@mantine/core";
2 | import { useState, useContext } from "react";
3 | import { useNavigate } from "react-router-dom";
4 | import AvailableCategoriesContext from "../store/AvailableCategoriesContext";
5 | import CategoriesContext from "../store/CategoriesContext";
6 | import HistoryContext from "../store/HistoryContext";
7 |
8 | type ResetValueModalProps = {
9 | type: string;
10 | prevAmount: number;
11 | };
12 |
13 | type AvailableCategories = {
14 | label: string;
15 | value: string;
16 | isused: string;
17 | };
18 |
19 | const ResetValueModal = ({ type, prevAmount }: ResetValueModalProps) => {
20 | const [opened, setOpened] = useState(false);
21 | const { addHistoryElement } = useContext(HistoryContext);
22 | const { resetAmount } = useContext(CategoriesContext);
23 | const { setAvailableCategories } = useContext(AvailableCategoriesContext);
24 |
25 | const navigate = useNavigate();
26 |
27 | return (
28 | <>
29 | setOpened(false)}
32 | centered
33 | title={`Are you sure you want to reset your ${type.toLowerCase()} to 0?`}
34 | >
35 | ({
40 | color:
41 | theme.colorScheme === "dark"
42 | ? theme.colors.dark[1]
43 | : theme.colors.gray[9],
44 | lineHeight: 1.3,
45 | })}
46 | >
47 | This action can be later undone by deleting the transaction.{" "}
48 | {type === "Expenses" &&
49 | "However the expense categories will return and the amount will be put under Uncategorized"}
50 |
51 |
52 | {
55 | // sets the value of expenses/budget to 0
56 | resetAmount(type);
57 | setOpened(false);
58 | addHistoryElement({
59 | label: `${type} has been reset to 0`,
60 | amount: prevAmount,
61 | id: crypto.randomUUID(),
62 | type: `${type} Reset`,
63 | dateCreated: "", // dateCreated passes an empty string here as the actual date creation is handled in the addHisotyrElement function
64 | category: `${type} Reset`,
65 | });
66 | if (type === "Expenses") {
67 | // set the isused property on all items in the available categories array to false since all categories have 0 amounts now that the expenses have been reset
68 | setAvailableCategories((prev) => {
69 | const arr: AvailableCategories[] = JSON.parse(
70 | JSON.stringify(prev)
71 | );
72 | arr.forEach((c) => {
73 | c.isused = "false";
74 | });
75 | return arr;
76 | });
77 | }
78 | // navigates to home page
79 | navigate("/");
80 | }}
81 | >
82 | Reset {type}
83 |
84 | setOpened(false)}>Cancel
85 |
86 |
87 |
88 |
89 | ({
93 | color:
94 | theme.colorScheme === "dark"
95 | ? theme.colors.dark[0]
96 | : theme.colors.gray[9],
97 | })}
98 | >
99 | Reset Your {type}
100 |
101 | ({
104 | color:
105 | theme.colorScheme === "dark"
106 | ? theme.colors.dark[1]
107 | : theme.colors.gray[9],
108 | })}
109 | >
110 | Resets your {type.toLowerCase()} back to 0
111 |
112 | setOpened(true)}>
113 | Reset {type}
114 |
115 |
116 | >
117 | );
118 | };
119 |
120 | export default ResetValueModal;
121 |
--------------------------------------------------------------------------------
/src/components/SetBudget.tsx:
--------------------------------------------------------------------------------
1 | import { useState, useContext } from "react";
2 | import { useNavigate } from "react-router-dom";
3 | import { Button, TextInput } from "@mantine/core";
4 | import HistoryContext from "../store/HistoryContext";
5 | import CategoriesContext from "../store/CategoriesContext"
6 |
7 | const SetBudget = () => {
8 | const { addHistoryElement } = useContext(HistoryContext);
9 | const { addCategory, getTotalAmount } = useContext(CategoriesContext);
10 |
11 | const [value, setValue] = useState(0);
12 | const navigate = useNavigate();
13 | return (
14 |
15 | setValue(Number.parseFloat(e.currentTarget.value))}
17 | mt={20}
18 | size="md"
19 | w="40%"
20 | placeholder="Ex: 5000"
21 | label="Enter your budget"
22 | withAsterisk
23 | />
24 | {
27 | // checks that the user inputted valid values
28 | if (value <= 0 || Number.isNaN(value)) {
29 | alert("Invalid Entry. Make sure the amount is greater than zero.");
30 | } else {
31 | const budget = getTotalAmount("Budget");
32 | addCategory({
33 | label: "Budget",
34 | id: crypto.randomUUID(),
35 | amount: -1*budget,
36 | });
37 | addCategory({
38 | label: "Budget",
39 | id: crypto.randomUUID(),
40 | amount: value,
41 | });
42 | // navigates back to home page
43 | navigate("/");
44 | addHistoryElement({
45 | label: "Budget has been set to $" + value,
46 | id: crypto.randomUUID(),
47 | amount: value,
48 | type: "Budget",
49 | dateCreated: "", // dateCreated passes an empty string here as the actual date creation is handled in the addHisotyrElement function
50 | category: "Budget",
51 | });
52 | }
53 | }}
54 | >
55 | Set Budget
56 |
57 |
58 | );
59 | };
60 |
61 | export default SetBudget;
62 |
--------------------------------------------------------------------------------
/src/layout/PageContainer.tsx:
--------------------------------------------------------------------------------
1 | import { ReactNode } from "react";
2 |
3 | type PageContainerProps = {
4 | children: ReactNode;
5 | };
6 |
7 | const PageContainer = ({ children }: PageContainerProps) => {
8 | return {children}
;
9 | };
10 |
11 | export default PageContainer;
12 |
--------------------------------------------------------------------------------
/src/main.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import ReactDOM from 'react-dom/client'
3 | import App from './App'
4 |
5 | ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
6 |
7 |
8 | ,
9 | )
10 |
--------------------------------------------------------------------------------
/src/pages/AddBudgetPage.tsx:
--------------------------------------------------------------------------------
1 | import { Divider, Text } from "@mantine/core";
2 | import AddToBudget from "../components/AddToBudget";
3 | import SetBudget from "../components/SetBudget";
4 | import PageContainer from "../layout/PageContainer";
5 | import { useContext } from "react";
6 | import ResetValueModal from "../components/ResetValueModal";
7 | import CategoriesContext from "../store/CategoriesContext";
8 |
9 | const AddBudgetPage = () => {
10 | const { getTotalAmount } = useContext(CategoriesContext);
11 | const budget = getTotalAmount("Budget");
12 |
13 | return (
14 |
15 | ({
19 | color:
20 | theme.colorScheme === "dark"
21 | ? theme.colors.dark[0]
22 | : theme.colors.gray[9],
23 | })}
24 | >
25 | Set Your Income / Budget
26 |
27 | ({
30 | color:
31 | theme.colorScheme === "dark"
32 | ? theme.colors.dark[1]
33 | : theme.colors.gray[9],
34 | })}
35 | >
36 | Sets your income / budget to the entered value.
37 |
38 |
39 |
40 | ({
44 | color:
45 | theme.colorScheme === "dark"
46 | ? theme.colors.dark[0]
47 | : theme.colors.gray[9],
48 | })}
49 | >
50 | Add an Income Source
51 |
52 | ({
55 | color:
56 | theme.colorScheme === "dark"
57 | ? theme.colors.dark[1]
58 | : theme.colors.gray[9],
59 | })}
60 | >
61 | Adds on to your current income / budget amount.
62 |
63 |
64 |
65 |
66 |
67 | );
68 | };
69 |
70 | export default AddBudgetPage;
71 |
--------------------------------------------------------------------------------
/src/pages/AddExpensePage.tsx:
--------------------------------------------------------------------------------
1 | import { Divider, Text } from "@mantine/core";
2 | import AddToExpenses from "../components/AddToExpenses";
3 | import PageContainer from "../layout/PageContainer";
4 | import { useContext } from "react";
5 | import ResetValueModal from "../components/ResetValueModal";
6 | import CategoriesContext from "../store/CategoriesContext";
7 |
8 | const AddExpensePage = () => {
9 | const { getTotalAmount } = useContext(CategoriesContext);
10 | const expenses = getTotalAmount("Expenses");
11 |
12 | return (
13 |
14 | ({
18 | color:
19 | theme.colorScheme === "dark"
20 | ? theme.colors.dark[0]
21 | : theme.colors.gray[9],
22 | })}
23 | >
24 | Add an Expense
25 |
26 | ({
29 | color:
30 | theme.colorScheme === "dark"
31 | ? theme.colors.dark[1]
32 | : theme.colors.gray[9],
33 | })}
34 | >
35 | Adds on to your current expense amount.
36 |
37 |
38 |
39 |
40 |
41 | );
42 | };
43 |
44 | export default AddExpensePage;
45 |
--------------------------------------------------------------------------------
/src/pages/DisplayCategoriesPage.tsx:
--------------------------------------------------------------------------------
1 | import { Text } from "@mantine/core";
2 | import DisplayCategories from "../components/DisplayCategories";
3 | import PageContainer from "../layout/PageContainer";
4 |
5 | const DisplayCategoriesPage = () => {
6 | return (
7 |
8 | ({
13 | color:
14 | theme.colorScheme === "dark"
15 | ? theme.colors.dark[1]
16 | : theme.colors.gray[8],
17 | })}
18 | >
19 | Spending Categories
20 |
21 |
22 |
23 | );
24 | };
25 |
26 | export default DisplayCategoriesPage;
27 |
--------------------------------------------------------------------------------
/src/pages/HomePage.tsx:
--------------------------------------------------------------------------------
1 | import { useContext } from "react";
2 | import { SimpleGrid, Text } from "@mantine/core";
3 | import DisplayCard from "../components/DisplayCard";
4 | import HistoryStack from "../components/HistoryStack";
5 | import PageContainer from "../layout/PageContainer";
6 | import PieChart from "../components/PieChart";
7 | import CategoriesContext from "../store/CategoriesContext";
8 |
9 | const HomePage = () => {
10 | const { getTotalAmount } = useContext(CategoriesContext);
11 | const budget = getTotalAmount("Budget");
12 | const expenses = getTotalAmount("Expenses");
13 |
14 | return (
15 |
16 | {/* Displays the net balance of the user */}
17 | ({
22 | color:
23 | theme.colorScheme === "dark"
24 | ? theme.colors.dark[1]
25 | : theme.colors.gray[9],
26 | })}
27 | >
28 | YOUR BALANCE IS: ${budget - expenses}
29 |
30 |
31 |
32 |
33 |
34 | {/* Only show the pie chart when either expenses or budget is greater than 0 */}
35 | {(budget > 0 || expenses > 0) && }
36 |
37 |
38 | );
39 | };
40 |
41 | export default HomePage;
42 |
--------------------------------------------------------------------------------
/src/store/AvailableCategoriesContext.tsx:
--------------------------------------------------------------------------------
1 | import { useLocalStorage } from "@mantine/hooks";
2 | import { createContext, ReactNode } from "react";
3 |
4 | type AvailableCategoriesContextProps = {
5 | children: ReactNode;
6 | };
7 |
8 | type AvailableCategories = {
9 | label: string;
10 | value: string;
11 | isused: string;
12 | };
13 |
14 | type CallBack = (prev: AvailableCategories[]) => AvailableCategories[];
15 |
16 | type AvailableCategoriesContextType = {
17 | availableCategories: AvailableCategories[];
18 | setAvailableCategories: (callBack: CallBack) => void;
19 | };
20 |
21 | const AvailableCategoriesContext =
22 | createContext({
23 | availableCategories: [],
24 | setAvailableCategories: (callBack: CallBack) => {},
25 | });
26 |
27 | export function AvailableCategoriesContextProvider({
28 | children,
29 | }: AvailableCategoriesContextProps) {
30 | const [availableCategories, setAvailableCategories] = useLocalStorage<
31 | AvailableCategories[]
32 | >({
33 | key: "multiSelectCategories",
34 | defaultValue: [
35 | {
36 | label: "Entertainment",
37 | value: "Entertainment",
38 | isused: "false",
39 | },
40 | {
41 | label: "Groceries",
42 | value: "Groceries",
43 | isused: "false",
44 | },
45 | { label: "Uncategorized", value: "Uncategorized", isused: "false" },
46 | ],
47 | });
48 |
49 | function setAvailableCategoriesHandler(callBack: CallBack) {
50 | setAvailableCategories(callBack);
51 | }
52 |
53 | const context = {
54 | availableCategories: availableCategories,
55 | setAvailableCategories: setAvailableCategoriesHandler,
56 | };
57 |
58 | return (
59 |
60 | {children}
61 |
62 | );
63 | }
64 |
65 | export default AvailableCategoriesContext;
66 |
--------------------------------------------------------------------------------
/src/store/CategoriesContext.tsx:
--------------------------------------------------------------------------------
1 | import { useLocalStorage } from "@mantine/hooks";
2 | import { createContext, ReactNode, useContext } from "react";
3 | import AvailableCategoriesContext from "./AvailableCategoriesContext";
4 |
5 | type CategoriesContextProps = {
6 | children: ReactNode;
7 | };
8 |
9 | type Category = {
10 | label: string;
11 | id: string;
12 | amount: number;
13 | };
14 |
15 | type AvailableCategories = {
16 | label: string;
17 | value: string;
18 | isused: string;
19 | };
20 |
21 | type CategoriesContextType = {
22 | categories: Category[];
23 | getTotalAmount: (type: string) => number;
24 | resetAmount: (type: string) => void;
25 | setCategories: (categories: Category[]) => void;
26 | addCategory: (newCategory: Category) => void;
27 | deleteCategory: (label: string) => void;
28 | subtractCategoryAmount: (label: string, amount: number) => void;
29 | };
30 |
31 | const CategoriesContext = createContext({
32 | categories: [],
33 | getTotalAmount: (type: string) => {
34 | let total = 0;
35 | return total;
36 | },
37 | resetAmount: (type: string) => {},
38 | setCategories: (categories: Category[]) => {},
39 | addCategory: (newCategory: Category) => {},
40 | deleteCategory: (label: string) => {},
41 | subtractCategoryAmount: (label: string, amount: number) => {},
42 | });
43 |
44 | export function CategoriesContextProvider({
45 | children,
46 | }: CategoriesContextProps) {
47 | const [categories, setCategories] = useLocalStorage({
48 | key: "categories",
49 | defaultValue: [],
50 | });
51 | const { setAvailableCategories } = useContext(AvailableCategoriesContext);
52 |
53 | function setCategoriesHandler(categories: Category[]) {
54 | setCategories(categories);
55 | }
56 |
57 | function getTotalAmount(type: string) {
58 | let total = 0;
59 | if (type === "Expenses") {
60 | categories.forEach((category) => {
61 | if (category.label !== "Budget") total += category.amount;
62 | });
63 | } else {
64 | categories.forEach((category) => {
65 | if (category.label === "Budget") total += category.amount;
66 | });
67 | }
68 | return total;
69 | }
70 |
71 | function resetAmount(type: string) {
72 | setCategories((prev) => {
73 | const arr: Category[] = JSON.parse(JSON.stringify(prev));
74 | const arr2: Category[] = [];
75 | arr.forEach((c) => {
76 | if (type === "Budget") {
77 | if (c.label !== "Budget") {
78 | arr2.push(c);
79 | }
80 | } else {
81 | if (c.label === "Budget") {
82 | arr2.push(c);
83 | }
84 | }
85 | });
86 | return arr2;
87 | });
88 | }
89 |
90 | // Adds a category to the categories state.
91 | // If the category already exists the amount of the category will be adjusted accordingly
92 | function addCategoryHandler(newCategory: Category) {
93 | let arr: Category[] = [];
94 | let count = 0;
95 | setCategories((prev) => {
96 | // create a hard copy of previous categories array
97 | arr = JSON.parse(JSON.stringify(prev));
98 | // if this is the first category to be added then add the category
99 | if (arr.length === 0) {
100 | return [newCategory];
101 | }
102 | // if the category already exists only add the amount of the newCategory otherwise add the newCategory
103 | arr = arr.map((c) => {
104 | if (c.label === newCategory.label) {
105 | c.amount += newCategory.amount;
106 | count++; // used to track if the category already exists. if the category already exists count will get updated to 1
107 | }
108 | return c;
109 | });
110 |
111 | // if count is 0 then the category does not exist and we add it to the array of categories
112 | if (count === 0) {
113 | arr.push(newCategory);
114 | }
115 | return [...arr];
116 | });
117 | }
118 |
119 | // takes in a label and deletes the category with the given label
120 | function deleteCategory(label: string) {
121 | setCategories((prev) => {
122 | return prev.filter((cat) => cat.label !== label);
123 | });
124 | }
125 |
126 | function subtractCategoryAmount(label: string, amount: number) {
127 | setCategories((prev) => {
128 | // create a hard copy of the previous category state
129 | const arr: Category[] = JSON.parse(JSON.stringify(prev));
130 | // array to store cleaned version of categories
131 | const arr2: Category[] = [];
132 | arr.forEach((c) => {
133 | // if the label matches then subtract the amount
134 | if (c.label === label) {
135 | c.amount -= amount;
136 | }
137 | if (c.amount > 0) {
138 | arr2.push(c);
139 | } else {
140 | // if the amount is zero or less then that means the category is not being used therefore set isused for that category in available categories array to false
141 | setAvailableCategories((prev) => {
142 | // create a hard copy of the previous available categories state
143 | const arr3: AvailableCategories[] = JSON.parse(
144 | JSON.stringify(prev)
145 | );
146 | arr3.forEach((category) => {
147 | if (category.label === label) {
148 | category.isused = "false";
149 | }
150 | });
151 | return arr3;
152 | });
153 | }
154 | });
155 | return arr2;
156 | });
157 | }
158 |
159 | const context = {
160 | categories: categories,
161 | getTotalAmount: getTotalAmount,
162 | resetAmount: resetAmount,
163 | setCategories: setCategoriesHandler,
164 | addCategory: addCategoryHandler,
165 | deleteCategory: deleteCategory,
166 | subtractCategoryAmount: subtractCategoryAmount,
167 | };
168 |
169 | return (
170 |
171 | {children}
172 |
173 | );
174 | }
175 |
176 | export default CategoriesContext;
177 |
--------------------------------------------------------------------------------
/src/store/HistoryContext.tsx:
--------------------------------------------------------------------------------
1 | import { useLocalStorage } from "@mantine/hooks";
2 | import { createContext, ReactNode } from "react";
3 |
4 | type HistoryContextProps = {
5 | children: ReactNode;
6 | };
7 |
8 | type HistoryElement = {
9 | id: string;
10 | label: string;
11 | amount: number;
12 | type: string;
13 | dateCreated: string;
14 | category: string;
15 | };
16 |
17 | type HistoryContextType = {
18 | history: HistoryElement[];
19 | setHistory: (history: HistoryElement[]) => void;
20 | addHistoryElement: (element: HistoryElement) => void;
21 | deleteHistoryElement: (id: string) => void;
22 | };
23 |
24 | const HistoryContext = createContext({
25 | history: [],
26 | setHistory: (history: HistoryElement[]) => {},
27 | addHistoryElement: (element: HistoryElement) => {},
28 | deleteHistoryElement: (id: string) => {},
29 | });
30 |
31 | export function HistoryContextProvider({ children }: HistoryContextProps) {
32 | const [history, setHistory] = useLocalStorage({
33 | key: "History",
34 | defaultValue: [],
35 | });
36 |
37 | function setHistoryHandler(history: HistoryElement[]) {
38 | setHistory(history);
39 | }
40 |
41 | // takes in a historyElement item and adds it to the history
42 | function addHistoryElementHandler(element: HistoryElement) {
43 | // creates a new date
44 | var today = new Date();
45 | var date =
46 | today.getDate() +
47 | "/" +
48 | (today.getMonth() + 1) +
49 | "/" +
50 | today.getFullYear();
51 | setHistory((prev: HistoryElement[]) => {
52 | return [
53 | {
54 | label: element.label,
55 | amount: element.amount,
56 | type: element.type,
57 | id: element.id,
58 | dateCreated: date,
59 | category: element.category,
60 | },
61 | ...prev,
62 | ];
63 | });
64 | }
65 |
66 | // takes in an ID and deletes the history element with that ID
67 | function deleteHistoryElementHandler(id: string) {
68 | setHistory((prev) => {
69 | return prev.filter((h) => h.id !== id);
70 | });
71 | }
72 |
73 | const context = {
74 | history: history,
75 | setHistory: setHistoryHandler,
76 | addHistoryElement: addHistoryElementHandler,
77 | deleteHistoryElement: deleteHistoryElementHandler,
78 | };
79 |
80 | return (
81 |
82 | {children}
83 |
84 | );
85 | }
86 |
87 | export default HistoryContext;
88 |
--------------------------------------------------------------------------------
/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "ESNext",
4 | "useDefineForClassFields": true,
5 | "lib": ["DOM", "DOM.Iterable", "ESNext"],
6 | "allowJs": false,
7 | "skipLibCheck": true,
8 | "esModuleInterop": false,
9 | "allowSyntheticDefaultImports": true,
10 | "strict": true,
11 | "forceConsistentCasingInFileNames": true,
12 | "module": "ESNext",
13 | "moduleResolution": "Node",
14 | "resolveJsonModule": true,
15 | "isolatedModules": true,
16 | "noEmit": true,
17 | "jsx": "react-jsx"
18 | },
19 | "include": ["src"],
20 | "references": [{ "path": "./tsconfig.node.json" }]
21 | }
22 |
--------------------------------------------------------------------------------
/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "composite": true,
4 | "module": "ESNext",
5 | "moduleResolution": "Node",
6 | "allowSyntheticDefaultImports": true
7 | },
8 | "include": ["vite.config.ts"]
9 | }
10 |
--------------------------------------------------------------------------------
/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from 'vite'
2 | import react from '@vitejs/plugin-react'
3 |
4 | // https://vitejs.dev/config/
5 | export default defineConfig({
6 | plugins: [react()],
7 | })
8 |
--------------------------------------------------------------------------------