Spaces:
Sleeping
Sleeping
Commit
·
be3ad36
1
Parent(s):
e698591
fix accident scroll on mobile when touch keyboard popup
Browse files- public/esltool.js +3 -3
- public/index.html +4 -42
- public/notebin.js +4 -2
public/esltool.js
CHANGED
|
@@ -144,10 +144,10 @@ defineBtn.addEventListener("pointerdown", () => {
|
|
| 144 |
});
|
| 145 |
|
| 146 |
removeButton.addEventListener('pointerdown', () => {
|
| 147 |
-
|
| 148 |
-
|
| 149 |
|
| 150 |
-
|
| 151 |
});
|
| 152 |
|
| 153 |
// Style the toolbar
|
|
|
|
| 144 |
});
|
| 145 |
|
| 146 |
removeButton.addEventListener('pointerdown', () => {
|
| 147 |
+
var urlDiv = document.getElementById("url_div");
|
| 148 |
+
urlDiv.style.display = urlDiv.style.display === "none" ? "block" : "none";
|
| 149 |
|
| 150 |
+
|
| 151 |
});
|
| 152 |
|
| 153 |
// Style the toolbar
|
public/index.html
CHANGED
|
@@ -4,65 +4,27 @@
|
|
| 4 |
<meta charset="UTF-8" />
|
| 5 |
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
| 6 |
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
|
|
|
|
|
| 7 |
<link rel="manifest" href="./manifest.json">
|
| 8 |
<link rel="stylesheet" href="./libs/toastui-editor.min.css" />
|
| 9 |
|
| 10 |
<title>groqnote</title>
|
| 11 |
<style>
|
| 12 |
body {
|
|
|
|
| 13 |
font-family: Arial, sans-serif;
|
| 14 |
background-color: #f4f4f4;
|
| 15 |
}
|
| 16 |
|
| 17 |
-
#testLinkContainer a {
|
| 18 |
-
width: fit-content;
|
| 19 |
-
display: inline-block;
|
| 20 |
-
margin-bottom: 10px;
|
| 21 |
-
color: #333;
|
| 22 |
-
text-decoration: none;
|
| 23 |
-
background-color: #ddd;
|
| 24 |
-
padding: 10px;
|
| 25 |
-
border-radius: 5px;
|
| 26 |
-
}
|
| 27 |
-
#testLinkContainer a:hover {
|
| 28 |
-
background-color: #eee;
|
| 29 |
-
}
|
| 30 |
-
textarea {
|
| 31 |
-
width: 90%;
|
| 32 |
-
height: 40vh;
|
| 33 |
-
margin-bottom: 20px;
|
| 34 |
-
padding: 10px;
|
| 35 |
-
border-radius: 5px;
|
| 36 |
-
border: 1px solid #ccc;
|
| 37 |
-
}
|
| 38 |
-
input {
|
| 39 |
-
display: block;
|
| 40 |
-
margin-bottom: 20px;
|
| 41 |
-
padding: 10px;
|
| 42 |
-
border-radius: 5px;
|
| 43 |
-
border: 1px solid #ccc;
|
| 44 |
-
}
|
| 45 |
-
#editableDiv {
|
| 46 |
-
padding: 20px;
|
| 47 |
-
border: 1px solid #ccc;
|
| 48 |
-
border-radius: 5px;
|
| 49 |
-
background-color: #fff;
|
| 50 |
-
}
|
| 51 |
-
#editableDiv div {
|
| 52 |
-
padding: 10px;
|
| 53 |
-
}
|
| 54 |
</style>
|
| 55 |
</head>
|
| 56 |
<body>
|
| 57 |
<div style="height: 30px;"></div>
|
| 58 |
-
|
| 59 |
-
<span id="url_div"></span>
|
| 60 |
<div id="notebin_editor"></div>
|
| 61 |
|
| 62 |
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
<script src="./index.js" type="module"></script>
|
| 67 |
<script src="./esltool.js" type="module"></script>
|
| 68 |
<script src="./libs/toastui-editor-all.min.js"></script>
|
|
|
|
| 4 |
<meta charset="UTF-8" />
|
| 5 |
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
| 6 |
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
| 7 |
+
|
| 8 |
+
|
| 9 |
<link rel="manifest" href="./manifest.json">
|
| 10 |
<link rel="stylesheet" href="./libs/toastui-editor.min.css" />
|
| 11 |
|
| 12 |
<title>groqnote</title>
|
| 13 |
<style>
|
| 14 |
body {
|
| 15 |
+
overflow-y: hidden;
|
| 16 |
font-family: Arial, sans-serif;
|
| 17 |
background-color: #f4f4f4;
|
| 18 |
}
|
| 19 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
</style>
|
| 21 |
</head>
|
| 22 |
<body>
|
| 23 |
<div style="height: 30px;"></div>
|
| 24 |
+
<span id="url_div" style="overflow-x: hidden;"></span>
|
|
|
|
| 25 |
<div id="notebin_editor"></div>
|
| 26 |
|
| 27 |
|
|
|
|
|
|
|
|
|
|
| 28 |
<script src="./index.js" type="module"></script>
|
| 29 |
<script src="./esltool.js" type="module"></script>
|
| 30 |
<script src="./libs/toastui-editor-all.min.js"></script>
|
public/notebin.js
CHANGED
|
@@ -144,8 +144,10 @@ setTimeout(() => {
|
|
| 144 |
|
| 145 |
let url_div = document.querySelector('#url_div');
|
| 146 |
url_div.innerText = window.location.href;
|
| 147 |
-
url_div.addEventListener('
|
| 148 |
-
|
|
|
|
|
|
|
| 149 |
})
|
| 150 |
|
| 151 |
|
|
|
|
| 144 |
|
| 145 |
let url_div = document.querySelector('#url_div');
|
| 146 |
url_div.innerText = window.location.href;
|
| 147 |
+
url_div.addEventListener('pointerdown', () => {
|
| 148 |
+
const text = url_div.textContent;
|
| 149 |
+
navigator.clipboard.writeText(text);
|
| 150 |
+
utils.showToast('copyed url to clipboard');
|
| 151 |
})
|
| 152 |
|
| 153 |
|