Moduled Firegex, Merging pt2 (to finish and test)

This commit is contained in:
DomySh
2022-07-21 21:17:06 +02:00
parent 63ba0e94e7
commit 1399d0e22d
23 changed files with 177 additions and 391 deletions

View File

@@ -2,6 +2,7 @@ import { showNotification } from "@mantine/notifications";
import { ImCross } from "react-icons/im";
import { TiTick } from "react-icons/ti"
import { nfregex } from "../components/NFRegex/utils";
import { regexproxy } from "../components/RegexProxy/utils";
import { ChangePassword, IpInterface, LoginResponse, PasswordSend, ServerResponse, ServerResponseToken, ServerStatusResponse } from "./models";
var Buffer = require('buffer').Buffer
@@ -57,6 +58,16 @@ export function gatmainpath(){
return ""
}
export function getapiobject(){
switch(gatmainpath()){
case "nfregex":
return nfregex
case "regexproxy":
return regexproxy
}
throw 'No api for this tool!';
}
export function fireUpdateRequest(){
window.dispatchEvent(new Event(eventUpdateName))
}