Adding results and export (#19)
* Initial Push
Inititial project state
* Static demo version
* static demo site - added variables
a
* first_implementation
* Updated UI, Improved Style to be more "Reactly", added Functionality
* add parsing functions
* change folder
* Import/Export Prototype
* Adding "reactjs-popup" to package,json
* Adding GLPK source
* Rough implementation of solver + example
* Show solution in output
* example 2 + popup lib
* removing import button
This feature won't be needed in this state of the project and might come back later. Right now it serves no functional purpose.
* Removing "Popout" button
This feature won't be needed in this state of the project and might come back later. Right now it serves no functional purpose.
* Updating Logs
Now the site displays all logs created with customLog(STRING). Logs can be cleared with customLogClear();
* Adding walltime
Can be called using:
Start:
function walltimeStart() {
returns Date.now();
Stop:
function walltimeStopAndPrint(startpoint: number) {
Add startpoint as argument.
It prints the elapsed time using customLog()
* Adding duals ouput
* Adding glpk.js package
required dependency
* adding LP format export and fixing a few errors
* fixing further errors
* adding automatic build
* Moving files to correct folders
* Update nextjs.yml
---------
Signed-off-by: SinusFox <61253950+SinusFox@users.noreply.github.com>
Co-authored-by: moebiusl <lucas.moebius@icloud.com>
Co-authored-by: Marcel Pöppe <marcel.poeppe@gmail.com>
This commit is contained in:
@@ -0,0 +1,50 @@
|
||||
import { MouseEventHandler } from "react";
|
||||
import React from 'react';
|
||||
import Popup from "reactjs-popup";
|
||||
|
||||
export function Box({title, placeholder, id}:
|
||||
{title:string; placeholder:string; id:string}) {
|
||||
return(
|
||||
<div className="main_div">
|
||||
<div className="body_title">
|
||||
{title}
|
||||
</div>
|
||||
<div className="text">
|
||||
<textarea
|
||||
className="body_box"
|
||||
id={id}
|
||||
wrap="soft"
|
||||
rows={6}
|
||||
placeholder={placeholder}
|
||||
></textarea>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export function Button({title, className, onClickFunc}:
|
||||
{title:string; className:string|undefined; onClickFunc: MouseEventHandler}) {
|
||||
|
||||
return(
|
||||
<button
|
||||
className={className}
|
||||
onClick={onClickFunc}
|
||||
>
|
||||
{title}
|
||||
</button>
|
||||
|
||||
);
|
||||
}
|
||||
|
||||
export function Output({ id, text }: { id: string; text: string }) {
|
||||
return (
|
||||
<div className="main_div">
|
||||
<div className="body_title">Output</div>
|
||||
<div className="text">
|
||||
<p className="output_box" id={id}>
|
||||
{text}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user