Compare commits
No commits in common. "main" and "v0.1.0" have entirely different histories.
6 changed files with 278 additions and 300 deletions
2
Makefile
2
Makefile
|
@ -20,7 +20,7 @@ build-ui:
|
||||||
cd ${UI_DIR} && pnpm run build
|
cd ${UI_DIR} && pnpm run build
|
||||||
|
|
||||||
build-server:
|
build-server:
|
||||||
go build -tags prod -ldflags "-s -w -X code.thetadev.de/TSGRain/WebUI/src/util.version=${VER}" -o build/tsgrainWebUI ./src/.
|
go build -tags prod -ldflags "-s -w -X code.thetadev.de/TSGRain/WebUI/src/util.version=${VER}" -o build/sebrauc ./src/.
|
||||||
|
|
||||||
build: build-ui build-server
|
build: build-ui build-server
|
||||||
|
|
||||||
|
|
|
@ -1,22 +0,0 @@
|
||||||
# Webserver options
|
|
||||||
[Server]
|
|
||||||
Address = ""
|
|
||||||
Port = 8001
|
|
||||||
|
|
||||||
# Websocket connection settings: Ping interval/Timeout in seconds
|
|
||||||
[Server.Websocket]
|
|
||||||
Ping = 10
|
|
||||||
Timeout = 2
|
|
||||||
|
|
||||||
# Compression settings. Refer to code.thetadev.de/TSGRain/ginzip for details.
|
|
||||||
[Server.Compression]
|
|
||||||
Gzip = "default"
|
|
||||||
Brotli = "default"
|
|
||||||
|
|
||||||
[Authentication]
|
|
||||||
Enable = false
|
|
||||||
PasswdFile = "htpasswd"
|
|
||||||
|
|
||||||
# IP-Address and port for communicating with the controller
|
|
||||||
[GRPC]
|
|
||||||
Address = "127.0.0.1:50051"
|
|
|
@ -22,7 +22,6 @@
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/core": "^7.17.0",
|
"@babel/core": "^7.17.0",
|
||||||
"@types/react": "^18.2.47",
|
|
||||||
"@types/react-dom": "^17.0.11",
|
"@types/react-dom": "^17.0.11",
|
||||||
"@vitejs/plugin-react-refresh": "latest",
|
"@vitejs/plugin-react-refresh": "latest",
|
||||||
"typescript": "^4.5.2",
|
"typescript": "^4.5.2",
|
||||||
|
|
550
ui/pnpm-lock.yaml
generated
550
ui/pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load diff
|
@ -135,7 +135,7 @@ class TaskProgress extends React.Component<TaskProgressProps, TaskProgressState>
|
||||||
// Cap progress in case the client is out of sync
|
// Cap progress in case the client is out of sync
|
||||||
progSeconds = Math.min(Math.max(progSeconds, 0), this.props.task.duration)
|
progSeconds = Math.min(Math.max(progSeconds, 0), this.props.task.duration)
|
||||||
|
|
||||||
progPercent = (progSeconds / this.props.task.duration) * 100
|
progPercent = (progSeconds / srvDuration) * 100
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
1
ui/ui.go
1
ui/ui.go
|
@ -40,7 +40,6 @@ func Register(r gin.IRouter, nZones int32) {
|
||||||
uiAssets := r.Group("/assets", middleware.Cache)
|
uiAssets := r.Group("/assets", middleware.Cache)
|
||||||
|
|
||||||
r.GET("/", indexHandler)
|
r.GET("/", indexHandler)
|
||||||
r.GET("/:path", indexHandler)
|
|
||||||
r.GET("/index.html", indexHandler)
|
r.GET("/index.html", indexHandler)
|
||||||
|
|
||||||
uiAssets.StaticFS("/", http.FS(subFS(distFS(), "assets")))
|
uiAssets.StaticFS("/", http.FS(subFS(distFS(), "assets")))
|
||||||
|
|
Loading…
Add table
Reference in a new issue