Added "learning table" above main table to allow user to make machine start learning again
This commit is contained in:
parent
f94e14fc89
commit
18890fcbc0
100
react/src/App.js
100
react/src/App.js
@ -7,6 +7,7 @@ function App() {
|
|||||||
const [tableQuarry, setTableQuarry] = useState('');
|
const [tableQuarry, setTableQuarry] = useState('');
|
||||||
const [columns, setColumns] = useState('');
|
const [columns, setColumns] = useState('');
|
||||||
const [results, setResults] = useState('');
|
const [results, setResults] = useState('');
|
||||||
|
const [isVisible, setIsVisible] = useState(true);
|
||||||
|
|
||||||
const fetchDataFromAPI = async (dataset, table, column) => {
|
const fetchDataFromAPI = async (dataset, table, column) => {
|
||||||
try {
|
try {
|
||||||
@ -24,41 +25,80 @@ function App() {
|
|||||||
fetchDataFromAPI(datasetQuarry, tableQuarry, columns);
|
fetchDataFromAPI(datasetQuarry, tableQuarry, columns);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const toggleVisibility = () => {
|
||||||
|
setIsVisible(!isVisible);
|
||||||
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="container">
|
<body>
|
||||||
<input
|
{isVisible && <div className="container2">
|
||||||
className='dataset'
|
<div className='headerlearn'>
|
||||||
type="text"
|
<header>Learning tables</header>
|
||||||
placeholder="Dataset quarry"
|
</div>
|
||||||
value={datasetQuarry}
|
|
||||||
onChange={(e) => setDatasetQuarry(e.target.value)}
|
|
||||||
/>
|
|
||||||
<input
|
|
||||||
className='table'
|
|
||||||
type="text"
|
|
||||||
placeholder="Table quarry"
|
|
||||||
value={tableQuarry}
|
|
||||||
onChange={(e) => setTableQuarry(e.target.value)}
|
|
||||||
/>
|
|
||||||
<div className="colums" id="columns-heigh">
|
|
||||||
<input
|
<input
|
||||||
|
className='datasetL'
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="Columns"
|
placeholder="Dataset quarry"
|
||||||
value={columns}
|
value={datasetQuarry}
|
||||||
onChange={(e) => setColumns(e.target.value)}
|
onChange={(e) => setDatasetQuarry(e.target.value)}
|
||||||
/>
|
/>
|
||||||
|
<input
|
||||||
|
className='tableL'
|
||||||
|
type="text"
|
||||||
|
placeholder="Table quarry"
|
||||||
|
value={tableQuarry}
|
||||||
|
onChange={(e) => setTableQuarry(e.target.value)}
|
||||||
|
/>
|
||||||
|
<div className="columsL" id="columns-heigh">
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
placeholder="Columns"
|
||||||
|
value={columns}
|
||||||
|
onChange={(e) => setColumns(e.target.value)}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>}
|
||||||
|
<div className="container">
|
||||||
|
<div className='headertest'>
|
||||||
|
<header>Test tables</header>
|
||||||
|
</div>
|
||||||
|
<input
|
||||||
|
className='dataset'
|
||||||
|
type="text"
|
||||||
|
placeholder="Dataset quarry"
|
||||||
|
value={datasetQuarry}
|
||||||
|
onChange={(e) => setDatasetQuarry(e.target.value)}
|
||||||
|
/>
|
||||||
|
<input
|
||||||
|
className='table'
|
||||||
|
type="text"
|
||||||
|
placeholder="Table quarry"
|
||||||
|
value={tableQuarry}
|
||||||
|
onChange={(e) => setTableQuarry(e.target.value)}
|
||||||
|
/>
|
||||||
|
<div className="colums" id="columns-heigh">
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
placeholder="Columns"
|
||||||
|
value={columns}
|
||||||
|
onChange={(e) => setColumns(e.target.value)}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
<button className='toggle' onClick={toggleVisibility}>
|
||||||
|
Toggle more
|
||||||
|
</button>
|
||||||
|
<button className="test" type="button" onClick={handleButtonClick}>
|
||||||
|
Test
|
||||||
|
</button>
|
||||||
|
<textarea
|
||||||
|
className='Resoult'
|
||||||
|
placeholder="Results"
|
||||||
|
value={results}
|
||||||
|
onChange={(e) => setResults(e.target.value)}
|
||||||
|
></textarea>
|
||||||
</div>
|
</div>
|
||||||
<button className="test" type="button" onClick={handleButtonClick}>
|
</body>
|
||||||
Test
|
|
||||||
</button>
|
|
||||||
<textarea
|
|
||||||
className='Resoult'
|
|
||||||
placeholder="Results"
|
|
||||||
value={results}
|
|
||||||
onChange={(e) => setResults(e.target.value)}
|
|
||||||
></textarea>
|
|
||||||
</div>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
export default App;
|
export default App;
|
Loading…
Reference in New Issue
Block a user