Trace:
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
sidebar [2022/12/23 00:56] – admin | sidebar [2023/01/27 17:41] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
< | < | ||
- | | + | |
- | <i class=" | + | <i class=" |
- | Start | + | Start |
- | </ | + | </ |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | somepi.ddns.net | + | somepi.ddns.net |
- | </ | + | </ |
- | <hr style=" | + | <hr style=" |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | Mobile | + | Mobile |
- | </ | + | </ |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | Linux | + | Linux |
- | </ | + | </ |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | Windows | + | Windows |
- | </ | + | </ |
- | <hr style=" | + | <hr style=" |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | Python | + | Python |
- | </ | + | </ |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | Java | + | Java |
- | </ | + | </ |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | C++ | + | C++ |
- | </ | + | </ |
- | <hr style=" | + | <hr style=" |
- | <div class=" | + | <div class=" |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | About | + | About |
- | </ | + | </ |
- | <a class=" | + | <a class=" |
- | <i class=" | + | <i class=" |
- | Help | + | Help |
- | </ | + | </ |
- | <script defer> | + | <script defer> |
- | let copytext | + | let add_clipboard |
- | let range, selection; | + | let duration = 2000; |
- | event.currentTarget !== event.target? | + | |
- | selection = window.getSelection(); | + | event.currentTarget !== event.target |
- | range = document.createRange(); | + | |
- | range.selectNodeContents(element); | + | |
- | selection.removeAllRanges(); | + | selection = window.getSelection(); |
- | selection.addRange(range); | + | range = document.createRange(); |
- | document.execCommand('copy'); | + | range.selectNodeContents(element.previousSibling); |
- | } | + | selection.removeAllRanges(); |
- | window.onload = () => { | + | selection.addRange(range); |
- | document.querySelectorAll(' | + | document.execCommand("copy"); |
- | element.addEventListener('click', copytext) | + | selection.removeAllRanges(); |
- | })} | + | element.style.animation = `${ |
- | </ | + | |
+ | | ||
+ | setTimeout(function () { | ||
+ | | ||
+ | }, duration); | ||
+ | }; | ||
+ | |||
+ | | ||
+ | document.querySelectorAll(" | ||
+ | | ||
+ | text_field = document.createElement(" | ||
+ | |||
+ | text_field.classList.add(" | ||
+ | text_field.appendChild(document.createTextNode(" | ||
+ | |||
+ | button.appendChild(text_field); | ||
+ | button.classList.add(" | ||
+ | |||
+ | wrapper = document.createElement(" | ||
+ | | ||
+ | wrapper.appendChild(element); | ||
+ | wrapper.classList.add(" | ||
+ | |||
+ | element.parentNode.insertBefore(button, | ||
+ | button.addEventListener("click", add_clipboard); | ||
+ | |||
+ | | ||
+ | e.preventDefault(); | ||
+ | if (e.target.nodeName == " | ||
+ | e.target.classList.toggle(" | ||
+ | | ||
+ | e.target.children[0].classList.toggle(" | ||
+ | | ||
+ | }); | ||
+ | }); | ||
+ | | ||
+ | | ||
</ | </ | ||
+ |