Peertube: Visitors should not see the “Upload” button when signup is disabled

Created on 16 Mar 2018  Â·  6Comments  Â·  Source: Chocobozzz/PeerTube

  • PeerTube version or commit: 1.0.0-alpha.8

  • What is the expected behaviour?

When an instance only accept uploads from known users, the “Upload” button in the top bar is useless to anonymous visitors. Administrators should have an option to hide it. Or maybe this should just be linked to the “Signup enabled” setting.

  • What do you see instead?

The “Upload” button in the top bar is visible to visitors.

Type Type

Most helpful comment

Our instance is a run for a closed community. We have a process for accepting new members. Random visitors will never be allowed to upload videos on our instance. The button is pure noise for them.

All 6 comments

I disagree. This upload button is useful even if the user is not logged in because:

  • It helps people to understand you can upload videos on this platform
  • Sometimes you forgot you're not logged in, and once https://github.com/Chocobozzz/PeerTube/issues/294 is implemented people would not loose the habit to click on the top-right button to upload a video

Our instance is a run for a closed community. We have a process for accepting new members. Random visitors will never be allowed to upload videos on our instance. The button is pure noise for them.

Hello, as a cheap hack, i would propose to add a css class on the body or the app that indicates the state of login (.not-logged or .logged).
An instance willing to hide the upload button for non logged users could add a custom css like:
.not-logged .upload-button { display:none; }

Here you go: https://github.com/Chocobozzz/PeerTube/commit/d414207f07f47307947d86d5bc5c5fc0ae73be18

Just add this as custom CSS:

.user-not-logged-in .upload-button {
  display: none;
}

I also think that the button can be misleading.

It helps people to understand you can upload videos on this platform

Couldn't it be shown only if registration is enabled on the instance ?

Some administrators ask people to send them an email for registration. If this button is not there, unregistered users would not understand that they could ask for an account to upload videos.

Then we could redirect people on another instance in the login form.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

filmaidykai picture filmaidykai  Â·  3Comments

kabo picture kabo  Â·  3Comments

filmaidykai picture filmaidykai  Â·  3Comments

Nutomic picture Nutomic  Â·  3Comments

zilti picture zilti  Â·  3Comments