Skip to content

Commit

Permalink
Publish 2.0.0-alpha source
Browse files Browse the repository at this point in the history
  • Loading branch information
linusg committed Sep 27, 2019
1 parent ed21183 commit 4d971d5
Show file tree
Hide file tree
Showing 40 changed files with 11,190 additions and 764 deletions.
3 changes: 3 additions & 0 deletions .browserslistrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
> 1%
last 2 versions
not ie > 0
22 changes: 22 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
module.exports = {
root: true,
env: {
node: true
},
extends: ["plugin:vue/essential", "@vue/prettier"],
rules: {
"no-console": process.env.NODE_ENV === "production" ? "error" : "off",
"no-debugger": process.env.NODE_ENV === "production" ? "error" : "off",
"prettier/prettier": [
"error",
{
trailingComma: "es5",
printWidth: 80,
htmlWhitespaceSensitivity: "ignore",
},
],
},
parserOptions: {
parser: "babel-eslint"
}
};
23 changes: 23 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
.DS_Store
node_modules
/dist

# local env files
.env.local
.env.*.local

# Log files
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw*

public/config/config.js
# Logs
logs
*.log
Expand Down
47 changes: 23 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# OwnTracks UI

> A modern web interface for OwnTracks made with Vue.js
> Web interface for OwnTracks
[![Docker Pulls](https://img.shields.io/docker/pulls/owntracks/frontend)](https://hub.docker.com/r/owntracks/frontend)

Expand All @@ -10,17 +10,32 @@

## Introduction

This is a web interface for [OwnTracks](https://github.com/owntracks/recorder), intended to replace the various web pages shipping with the recorder. OwnTracks UI uses Vue.js under the hood.
This is a web interface for [OwnTracks](https://github.com/owntracks/recorder) built as
a Vue.js single page application. The recorder itself already ships with some basic web
pages, this is a more advanced interface with more functionality, all in one place.

## Installation

### Manual install
### Manually

Clone the repository and copy `index.html` and the `static/` directory to your server's webroot. The API is expected to be reachable under the same domain as the web interface.
For development:

- Run `yarn install` to install dependencies
- Run `yarn serve` to compile for development and start the hot-reload server
- Run `yarn lint` to lint and fix files

To deploy:

- Run `yarn install --production` to install dependencies
- Run `yarn build` to compile and minify for production
- Copy the content of the `dist/` directory to your webroot

The API is expected to be reachable under the same domain as the web interface.

### Docker

You can launch directly via Docker run like this:

```console
$ docker run -d -p 80:80 -e SERVER_HOST=otrecorder-host -e SERVER_PORT=otrecorder-port owntracks/frontend
```
Expand All @@ -44,30 +59,26 @@ services:
## Features

- Enable or disable multiple layers:

- Last known (i.e. live) locations:

- Accuracy visualization (circle)
- Device friendly name and icon
- Detailed information (if available): time, lat, lon, height, battery and speed

- Detailed information (if available): time, latitude, longitude, height, battery and speed
- Location history (data points, line or both)
- Location heatmap
- Button to quickly fit all shown objects on the map into view

- Display data in a specific date range
- Filter by user and device
- Customizable:

- Customisable:
- UI color
- Default start and end date
- Map:

- Tile server
- Max zoom
- Default position and zoom
- Heatmap colors, radius and blur

See [`docs/config.md`](docs/config.md) for more info.

## Screenshots

_Click to enlarge._
Expand All @@ -78,18 +89,6 @@ _Click to enlarge._
<a href="https://raw.githubusercontent.com/owntracks/frontend/master/docs/images/heatmap.png" target="_blank"><img src="https://raw.githubusercontent.com/owntracks/frontend/master/docs/images/heatmap.png" alt="Heatmap" height="200"></a>
<a href="https://raw.githubusercontent.com/owntracks/frontend/master/docs/images/customized.png" target="_blank"><img src="https://raw.githubusercontent.com/owntracks/frontend/master/docs/images/customized.png" alt="Customized" height="200"></a>

## ToDo

- Node.js based development workflow:

- Webpack
- Vue SFCs
- Sass
- Dependency management with yarn instead of a local copy or unpkg.com

- Add documentation, at least for the config file
- Download data for selected date range, user and device as JSON

## Contributing

Please feel free to open an issue and discuss your ideas and report bugs. If you think you can help out with something, open a PR!
3 changes: 3 additions & 0 deletions babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module.exports = {
presets: ["@vue/app"],
};
File renamed without changes.
File renamed without changes.
224 changes: 0 additions & 224 deletions index.html

This file was deleted.

0 comments on commit 4d971d5

Please sign in to comment.