Skip to content

erisdisqordia/pleroma-fe

Repository files navigation

Disqordia.space fork of pleroma-fe

This fork includes several new options and tweaks, some of which have been merged upstream. View all fork changes here

Note: This frontend is only tested on disqordia.space. It should still work on any pleroma instance, but is not guaranteed.

Install instructions | Build instructions | Alternate frontends | Changelog

Screenshot_20210613_014229

To-do list

  • Create list of all changes
  • Create and maintain branch without disqordia specific changes, to be used by other instance admins
  • Update changelog properly

Features

  • Add sidebar position option (merged upstream)
  • Add disable instance shoutbox option
    • send merge request
  • Add separate notifications column option
  • Add "Persistent floating post button" option
    • send merge request upstream
  • Add "Toggle media-only post viewing" in nav bar (similar to dashboard-fe or 4chan X)
  • Add link to edit profile if viewing your own profile
  • Add an option for silent notifications (notifications without unread indicators that you have to click away)
  • Option to move shoutbox to top nav icon to save space

Fixes

  • Fixed Pleroma looking as if it's continuously loading on private instances, replaces loading circle with "Log in to view more"
    • send merge request

Tweaks

  • Add "Apply" buttons at the top of Theme settings
    • send merge request
  • Redo mobile nav

Long-term goals

  • Add an admin dashboard within pleroma-fe (similar to soapbox-fe)
  • Implementation of lists
  • Menu link to mute a user's domain
  • Allow a user to set if their individual profile is private (similar to how "locked" works on Twitter)
  • Add option for site layout similar to 4chan userscript OneeChan or AppChan X
  • Add draggable resizable post form
  • Add customizable sidebar links (like soapbox-fe)
  • Popover chat menu
  • Add a second column option for split timelines

Installing this fork on your instance

Installing and removing this fork is easy, and you can revert back to regular pleroma-fe at any time. Pleroma lets us override the defaults risk-free using your static folder in /var/lib/pleroma/static/

To install:

  • Download the current zip file here
  • Back up your static folder
    • cp -r /var/lib/pleroma/static ~/pleroma-backup
  • Extract the contents to your static folder
    • This means index.html should be in /var/lib/pleroma/static/index.html and the js and css folders should be in /var/lib/pleroma/static/static/(js/css)

That's it! When you refresh the page it should load this fork.

Removing this fork for the built in pleroma-fe

Removing is easy as the fork shouldn't touch the default pleroma-fe, so just remove what we installed:

cd /var/lib/pleroma/static/static
rm -rf js css 
cd /var/lib/pleroma/static
rm index.html

Building yourself to make your own changes

# clone the repo 
git clone https://github.com/erisdisqordia/pleroma-fe.git
cd pleroma-fe
git checkout master

# install dependencies
npm install -g yarn
yarn

# make your changes
# languages options are in src/i18n/en.json
# most features have their own folder in src/components/

# once you're happy, test that it works at localhost:8080 (see "For Contributors" section below to load your instance backend with it
npm run dev

# Back up your static folder, usually /var/lib/pleroma/static/
cp -r /var/lib/pleroma/static ~/pleroma-backup

# build for production with minifications with output into the /dist/ folder 
npm run build

# install files
cp -r dist/static/js /var/lib/pleroma/static/static/js
cp -r dist/static/css /var/lib/pleroma/static/static/css
cp dist/index.html /var/lib/pleroma/static/index.html

# Refresh your instance and you should see your changes!

For Contributors:

You can create file /config/local.json (see example) to enable some convenience dev options:

  • target: makes local dev server redirect to some existing instance's BE instead of local BE, useful for testing things in near-production environment and searching for real-life use-cases.
  • staticConfigPreference: makes FE's /static/config.json take preference of BE-served /api/statusnet/config.json. Only works in dev mode.

FE Build process also leaves current commit hash in global variable ___pleromafe_commit_hash so that you can easily see which pleroma-fe commit instance is running, also helps pinpointing which commit was used when FE was bundled into BE.