diff --git a/bot.z_web/package.json b/bot.z_web/package.json
index b86f1ae..2726865 100644
--- a/bot.z_web/package.json
+++ b/bot.z_web/package.json
@@ -1,6 +1,6 @@
{
"name": "bot.z_web",
- "version": "0.1.0",
+ "version": "1.0.0",
"private": true,
"dependencies": {
"bootstrap": "^4.3.1",
diff --git a/bot.z_web/public/favicon.ico b/bot.z_web/public/favicon.ico
index a11777c..4765a3c 100644
Binary files a/bot.z_web/public/favicon.ico and b/bot.z_web/public/favicon.ico differ
diff --git a/bot.z_web/public/index.html b/bot.z_web/public/index.html
index 5b4b39f..1ff1dd8 100644
--- a/bot.z_web/public/index.html
+++ b/bot.z_web/public/index.html
@@ -19,7 +19,7 @@
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
-
React App
+ BotZ
diff --git a/bot.z_web/public/manifest.json b/bot.z_web/public/manifest.json
index 1f2f141..7e68641 100644
--- a/bot.z_web/public/manifest.json
+++ b/bot.z_web/public/manifest.json
@@ -1,6 +1,6 @@
{
- "short_name": "React App",
- "name": "Create React App Sample",
+ "short_name": "BotZ",
+ "name": "BotZ web interface",
"icons": [
{
"src": "favicon.ico",
diff --git a/bot.z_web/src/App.js b/bot.z_web/src/App.js
index da4db79..b72e3f6 100644
--- a/bot.z_web/src/App.js
+++ b/bot.z_web/src/App.js
@@ -2,17 +2,15 @@ import React from 'react';
import IndexPage from './IndexPage.js';
-const targetUrl = "http://localhost:3003"
-
class App extends React.Component {
constructor(props) {
super(props)
- this.state = {targetUrl: targetUrl, loggedIn: false}
+ this.state = {targetUrl: props.targetUrl, loggedIn: false}
}
componentDidMount() {
- fetch(this.targetUrl, {credentials: 'include'})
+ fetch(this.targetUrl + '/status', {credentials: 'include'})
.then(response => response.json())
.then(data => this.setState({loggedIn: data.logged_in}));
}
diff --git a/bot.z_web/src/index.js b/bot.z_web/src/index.js
index 0f412d7..dcca205 100644
--- a/bot.z_web/src/index.js
+++ b/bot.z_web/src/index.js
@@ -5,7 +5,12 @@ import './index.css';
import App from './App';
import * as serviceWorker from './serviceWorker';
-ReactDOM.render(, document.getElementById('root'));
+
+const targetUrl = "/api";
+// // Dev address //
+// const targetUrl = "http://localhost:3003/api";
+
+ReactDOM.render(, document.getElementById('root'));
// If you want your app to work offline and load faster, you can change
// unregister() to register() below. Note this comes with some pitfalls.