This commit is contained in:
maaa 2024-06-23 21:00:06 +02:00
parent 03a4af3419
commit 3fdaf7279d
3 changed files with 10 additions and 5 deletions

View File

@ -33,10 +33,9 @@
<button id="newNote" class="newNote" style="margin-left: 5px;"> <button id="newNote" class="newNote" style="margin-left: 5px;">
<div class="vcenter"><img id="newNoteImage" draggable="false" alt="" src="/static/svg/add.svg"></div> <div class="vcenter"><img id="newNoteImage" draggable="false" alt="" src="/static/svg/add.svg"></div>
</button> </button>
<button class="newNote" style="margin-left: 37.5px; background-color: var(--bar) !important;"> <!--<button class="newNote" style="margin-left: 37.5px; background-color: var(--bar) !important;">-->
</button> </button>
<button id="removeBox" class="newNote"> <button id="removeBox" class="newNote remove">
<div class="vcenter"><img id="newNoteImage" draggable="false" alt="" src="/static/svg/delete.svg"></div> <div class="vcenter"><img id="newNoteImage" draggable="false" alt="" src="/static/svg/delete.svg"></div>
</button> </button>
<div id="notesDiv" class="notesDiv"> <div id="notesDiv" class="notesDiv">

View File

@ -372,6 +372,11 @@ body {
transition: 0.125s; transition: 0.125s;
} }
.notesBar .remove {
position: absolute;
right: 5px;
}
.notesBar .newNote:hover { .notesBar .newNote:hover {
background-color: var(--icon-button-hover); background-color: var(--icon-button-hover);
} }

View File

@ -76,11 +76,12 @@ if (/Android|iPhone|iPod/i.test(navigator.userAgent)) {
mobile = true mobile = true
noteBoxDiv.classList.add("mobile"); noteBoxDiv.classList.add("mobile");
noteBoxDiv.style.width = "0px"; noteBoxDiv.style.width = "0px";
notesBar.style.width = "calc(100% + 7.5px)" notesBar.style.width = "85%"
noteBoxDiv.readOnly = true noteBoxDiv.readOnly = true
noteBox.style.fontSize = "18px" noteBox.style.fontSize = "18px"
noteBoxDiv.classList.add("hidden") noteBoxDiv.classList.add("hidden")
let touchstartX, touchstartY, touchendX, touchendY let touchstartX, touchstartY, touchendX, touchendY
notesBar.addEventListener("touchstart", function (event) { notesBar.addEventListener("touchstart", function (event) {
@ -130,7 +131,7 @@ if (/Android|iPhone|iPod/i.test(navigator.userAgent)) {
function handleGesture() { function handleGesture() {
if (indiv) { if (indiv) {
indiv = false indiv = false
notesBar.style.width = "calc(100% + 7.5px)"; notesBar.style.width = "85%"
noteBoxDiv.style.width = "0px" noteBoxDiv.style.width = "0px"
if (selectedNote !== 0) { if (selectedNote !== 0) {
noteBoxDiv.readOnly = true noteBoxDiv.readOnly = true