-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
104 lines (100 loc) · 3.93 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="./styles.css">
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
<title>
Finance Buddy
</title>
</head>
<body>
<h1>Finance <span id="financeSpan">Buddy</span></h1>
<div class="root">
<div class="budget">
<div>
<h2>Plan Your Budget</h2>
<div class="dashboard">
<div>
<canvas id="budgetChart"></canvas>
</div>
<div class="income">
<h3>My Total Income</h3>
<div id="total-income"></div>
<button id="update">Update Income</button>
<button id="setting">Settings</button>
</div>
</div>
</div>
<br>
</div>
<div class="expense-container">
<div id='expenseDiv1'>
<h3>Add expenses for the month</h3>
<form id="expenseForm">
<label for="name">Name: </label>
<input id="expenseText" placeholder="Eg: Groceries" type="text" required>
<label for="date">Date: </label>
<input id="expenseDate" type="date" value="" required>
<label for="amount">Amount: </label>
<input id="expenseAmount" type="text" oninput="formatInput('expenseAmount')" required>
<h5 id="warning"></h5>
<div id="addExpenseDiv">
<input id="addExpenseBtn" type="button" value="Add expense">
</div>
</form>
</div>
<div id="financeRes">
<table id="expenseTable">
<tbody>
<tr>
<th>Name</th>
<th>Date</th>
<th>Amount</th>
<th></th>
</tr>
</tbody>
</table>
<div id="messageDiv">Nothing is added yet!</div>
<div id="financeTotal"></div>
<div id="clear">
<button id="save-data">Save</button>
<button onclick="resetData()">Reset</button>
</div>
</div>
</div>
</div>
<div class="settings-modal">
<div id="settings">
<div id="close-setting" onclick="closeSettingModal()">X</div>
<h3>Settings</h3>
<label for="currency">Currency:</label>
<select name="currency" onchange="chooseCurrency()" id="currency">
<option value="₦">₦</option>
<option value="$">$</option>
<option value="£">£</option>
<option value="€">€</option>
<option value="₹">₹</option>
<option value="¥">¥</option>
<option value="₵">₵</option>
</select>
<p id="setting-messages"></p>
<div class="auto-fields">
<h4 style="margin-right: 5px;color:#d8d5d5">Auto Save: </h4>
<label class="switch">
<input id="auto-save-to-db" type="checkbox">
<span class="slider round"></span>
</label>
<div id="auto-save"></div>
</div>
<div class="user-details">
<button id="change-email">Edit Details</button>
<div class="details">
<input type="text" id="email">
</div>
</div>
</div>
</div>
<script type="module" src="./index.js"></script>
<script type="module" src="./save.js"></script>
</body>
</html>