spuxx1701 / potber-client

An SPA client for the german board forum.mods.de built with Ember.js
GNU General Public License v3.0
11 stars 4 forks source link

potber logo

A mobile-first web client for the german internet forum forum.mods.de built with ember.js. If you're looking for potber-api, you can find it here.

Production Builds Staging Builds Latest Release License

Table of contents

How to use

Visit https://www.potber.de (or https://test.potber.de for the staging environment) to use the app.

Core features

Browser support

Potber supports the following browsers. Other browser might work, but are not supported. The app might still behave and display differently on different devices.

Standalone mode (PWA)

The app supports standalone mode (PWA). In stadalone mode, the website behaves almost exactly like an App. Whether your browser supports standalone mode and how to enable it highly depends on your browser. Android Chrome offers an option to "Install app" in your website settings, while iOS Safari has an option to "Add website to home screen". If you're having trouble, maybe this article can be of help.

BBCode parser

The application includes a functioning and fully custom BBCode parser written in TypeScript. It is able to parse most of the board's BBCode without errors and is being continously worked on. You can find it here.

Gestures

The app includes basic support for gestures. Gestures support can be enabled in the settings. When doing so, the app will disable some of your browser's native gestures (like pull to refresh). You might still run into issues in case your device adds native gestures on top of that. For example, some Android devices use horizontal swipes for navigating the OS.

The following gestures have been implemented so far:

Themes

You can customize the application's appearance via the available themes. Additionally, feel free to create your own theme and suggest adding it to the app. The individual steps might depend on your browser, but this is rougly how you do it:

  1. Open the application on a desktop device. Make sure you have the 'default' theme selected as it'll make the process easier.
  2. Rightclick anywhere into the application and hit Inspect (or Untersuchen in german). What you see now is the inspector panel. In the panel, look for the styles container. It looks rougly like this:
element {
  ...
}

:root {
  ...
}
...
  1. Scroll down in that container until you see a section called html, html *
  2. You can now change any of the default theme's variables.
  3. Send me a copy of the entire section and tell me how the theme should be called. 🙂

If you feel skilled enough, you can also create a PR of course. Themes are located here. All themes will be merged with the default theme, so you only need to provide variables you want to override.

How to develop or build the app

Prerequisites

You will need the following things properly installed on your computer.

Installation

Running / Development

You can either run the application via a Dev Container or without. The advantage of using the dev container is that you do not need to setup or clone the potber-auth and potber-api repository. Similar as running the application via npm run start:remote except that potber-auth and potber-api are running locally via Docker.

Dev Container

You need to have Docker installed on your system and have the Dev Containers extension setup in VSCode. Clone potber-api and open it in VSCode. Click on Reopen in container. After finishing the setup, you can start the development server with npm start inside of the VSCode terminal. Visit the app at http://localhost:4200.

Without Dev Container

Linting

Testing

Building

Deploying

The application can be deployed via Docker. The application provides two different Dockerfiles for the staging and production environments:

After building the Docker image, you can run it locally or on a remote host. In case you're curious about how potber.de is hosted: Both the test and production environments run on a Flux-controlled MicroK8s cluster. The infrastructure is documented here.

Further Reading / Useful Links

Credit