GIP-ITC-UniversityTwente / stars-webviewer

Web interface of the Visualization tool for STARS
0 stars 0 forks source link

STARS-WebViewer

Web interface of the Visualization tool for STARS

Client-Side Technology

This aplication uses:

Angular 4.1.3 as the web framework.

Angular-CLI 1.1.0 Command Line Interface for project build & project scaffolding. Note, this requires Node 6.9.0 or higher and NPM 3 or higher.

Angular Material 2.0.0 for UI/UX goodness.

Angular Flexbox CSS 2.0.0 as the responsive engine.

Plotly.js 1.27.1 for Charts

Open Layers 4.2.0 for the Map interface.

geostats 1.6.0 for client-side histogram classification.

Auth0 is used for the identify store. The Auth0 hosted login page is also used for sign in, sign up, password recovery, and logging out. Below are notes on the server and client configuration.

Coding Style, Syntax & Semantics

The coding style used in the STARS WebViewer is inspired by the following:

Running the App

To run this app, clone the repo, install node packages, and use the Angular-CLI to serve it up. For example:

  npm install

  ng serve

Build & Deploy the App

First, go to authConfig.ts file. Change the callback url property to watch the URL of the server. Note that localhost is used for development.

interface AuthConfig {
  clientID: string;
  domain: string;
  callbackURL: string;
}

export const AUTH_CONFIG: AuthConfig = {
  clientID: '4Q4AvhUTyB0rePqjOKhRaMb5yIYHxXSQ', // see dashboard > clients >  app > settings
  domain: 'ccabanerospatialdev.auth0.com',      // see dashboard > clients >  app > settings
  callbackURL: 'http://localhost:4200/callback' // <--- CHANGE HERE!!!
};

To build the web app, use Terminal to cd to the root folder of the web app on your workstation. Then, use the Angular-CLI.

  ng build --prod

Then deploy the contents of the dist folder to the web server bucket.