This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function logHookFunction(obj, key, hookTime = 5000) { | |
if (typeof obj[key] !== "function") { | |
console.log("[-] Hook failed! Not a function!") | |
return | |
} | |
obj[`o${key}`] = obj[`o${key}`] || obj[key] | |
obj[key] = function(...args) { | |
console.log(`[HOOKR] ${key}(${args.join(',')})`) | |
return this[`o${key}`](...args) | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hash from 'hash-it'; | |
import { useEffect, useState } from 'react'; | |
const MIN_DELAY = 50; | |
const MAX_DELAY = 1000; | |
const STEP_DELAY = 50; | |
export function useReactive(target) { | |
const [val, setVal] = useState(target); | |
const [_toggle, setToggle] = useState(false); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(() => { | |
if (!window.speechSynthesis || !window.SpeechSynthesisUtterance) { | |
return alert('Nicht unterstützt!') | |
} | |
const say = text => { | |
if (!text) return | |
window.speechSynthesis.cancel() | |
const msg = new SpeechSynthesisUtterance(text) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.WebSocket = class WebSocket extends window.WebSocket { | |
static event_listener = {} | |
static on(eventName, fn) { | |
WebSocket.event_listener[eventName] = WebSocket.event_listener[eventName] || [] | |
WebSocket.event_listener[eventName].push(fn) | |
} | |
static on(eventName, fn) { | |
WebSocket.event_listener[eventName] = WebSocket.event_listener[eventName] || [] | |
WebSocket.event_listener[eventName].push(fn) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<style> | |
.single-div-modal { | |
position: fixed; | |
box-sizing: border-box; | |
z-index: 1337; | |
top: 0; | |
right: 0; | |
bottom: 0; | |
left: 0; |
NewerOlder