startpage

Simple text centric startpage
Log | Files | Refs | README

commit 0008203ee952114eb4c00eec94e3207a2609e062
parent 594d403aeb7b7013675ef6464ea4273827d6d5d5
Author: Peter <peter@minskio.co.uk>
Date:   Wed, 25 May 2022 09:31:56 +0100

Remove up/last_command javascript

Diffstat:
Mindex.html | 3+--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/index.html b/index.html @@ -132,10 +132,9 @@ var current_block;function new_block() {(current_block=document.createElement("div"))} function block_log(e,n=!1){new_block()} - function handleKeyUp(){13===event.keyCode&&submit_command(),38===event.keyCode&&last_command()} + function handleKeyUp(){13===event.keyCode&&submit_command()} function submit_command(){var e=document.getElementById("input_source").value document.getElementById("input_source").value="",new_block(),"function"==typeof window[e.split(" ")[0]]?(block_log(config.shellPrompt+e,shell=!0),window[e.split(" ")[0]](e)):""!=e&&block_log("command not found : "+e)} - function last_command(){const e=document.getElementsByClassName("shell");document.getElementById("input_source").value=e[e.length-1].innerText.substr(2)} config={shellPrompt:"$ "} document.getElementById("input_title").innerText=config.shellPrompt document.getElementById("input_source").addEventListener("keyup",handleKeyUp);