some progress
This commit is contained in:
parent
e00e613d8e
commit
ced9f2d5d5
4 changed files with 51 additions and 0 deletions
14
Readme.md
14
Readme.md
|
|
@ -0,0 +1,14 @@
|
||||||
|
# sPlaner
|
||||||
|
Stuce's simple planer is a simple app that lets you plan your day
|
||||||
|
## Objectives
|
||||||
|
- Save on cloud on background, make spa with htmx
|
||||||
|
- add items via text input and give them title + duration
|
||||||
|
- show a nice timetable for the day
|
||||||
|
- allow adding items from sTodo, and interface to check them from there
|
||||||
|
- fetch items from sCalendar when it will be added
|
||||||
|
- deploy with nix easily
|
||||||
|
|
||||||
|
## Progress
|
||||||
|
- [ ] make base page by designing a add item field
|
||||||
|
- [ ] base representation of item fields
|
||||||
|
- [ ] fetch items from sTodo
|
||||||
BIN
htmx.min.js.gz
Normal file
BIN
htmx.min.js.gz
Normal file
Binary file not shown.
24
index.html
Normal file
24
index.html
Normal file
|
|
@ -0,0 +1,24 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
|
<!-- <script src="htmx.min.js.gz" defer></script> -->
|
||||||
|
<script src="script.js" defer></script>
|
||||||
|
<title>sPlanner</title>
|
||||||
|
<!-- <link href="css/style.css" rel="stylesheet"> -->
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<h1>sPlanner</h1>
|
||||||
|
<ul id="itemList"></ul>
|
||||||
|
|
||||||
|
<form id="itemForm" onsubmit="event.preventDefault(); appendItem(new Item(itemInput.value)); item-input.value = ''">
|
||||||
|
<input type="text" id="item-input" placeholder="Enter item" required>
|
||||||
|
<input type="time" id="time-input" name="time-input">
|
||||||
|
|
||||||
|
<button type="submit">Add Item</button>
|
||||||
|
</form>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
<footer>
|
||||||
|
</footer>
|
||||||
13
script.js
Normal file
13
script.js
Normal file
|
|
@ -0,0 +1,13 @@
|
||||||
|
const defaultDuration = 15*60
|
||||||
|
|
||||||
|
function Item(name/*, start, duration, end*/) {
|
||||||
|
this.name = name;
|
||||||
|
// this.start = start;
|
||||||
|
// this.ducation = duration;
|
||||||
|
// this.end = end;
|
||||||
|
}
|
||||||
|
|
||||||
|
function appendItem(item) {
|
||||||
|
let text = '<li><p>'+item.name+'</p></li>';
|
||||||
|
itemList.insertAdjacentHTML('beforeend', text);
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue