Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/darshanbaral/khata.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'static/js/khata.js')
-rw-r--r--static/js/khata.js31
1 files changed, 1 insertions, 30 deletions
diff --git a/static/js/khata.js b/static/js/khata.js
index 6dcba90..8b13789 100644
--- a/static/js/khata.js
+++ b/static/js/khata.js
@@ -1,30 +1 @@
-let toggleHeight = function(elem) {
- if (getComputedStyle(elem)["height"] === "0px") {
- elem.style.maxHeight = elem.scrollHeight + 5 +"px";
- } else {
- elem.style.maxHeight = "0px";
- }
-};
-let toggleDisplay = function(elem) {
- elem.classList.toggle("d-none");
-};
-let zeroHeight = function(elem) {
- elem.style.maxHeight = "0px";
-};
-let checkClick = function() {
- if (!document.querySelector(".dropdown").contains(event.target)) {
- zeroHeight(document.querySelector(".dropdown-content"));
- }
- if (
- window.matchMedia("(max-width: 750px)").matches &&
- !document.querySelector("nav").contains(event.target)
- ) {
- document.querySelector(".all-menu").classList.add("d-none");
- }
-};
-window.onclick = function() {
- checkClick();
-};
-window.ontouchstart = function() {
- checkClick();
-};
+