Good afternoon, can you tell me if it is possible to hide the string “Shared by:” when creating a link?
Currently, there is no built-in configuration setting to toggle the “Shared by:” string on the share link page. However, you can achieve this using one of the following customization methods:
Method 1: Using Custom CSS (Easiest)
You can hide the element by adding a custom CSS rule.
- Create a CSS file (e.g.,
custom.css) in your Seafile custom media directory. - Add a rule to hide the “Shared by” section. Usually, this can be targeted with a rule like:
/* Example - you may need to inspect the page to find the exact class */ .shared-by-section { display: none !important; } - In your
seahub_settings.py, add or update theBRANDING_CSSsetting:BRANDING_CSS = 'custom/custom.css' - Restart Seahub.
For more details on custom CSS, see the Seahub Customization documentation.
Method 2: Template Overwriting
If you want to remove the code entirely from the page, you can overwrite the HTML template.
- Locate the relevant template in the Seahub source code (likely
shared_file_view.htmlorshared_dir.html). - Copy the file to
seahub-data/custom/templates/. - Edit the copied file and remove the HTML block containing the “Shared by” text.
- Restart Seahub.
Customizations placed in seahub-data/custom/templates/ are maintained after upgrades. You can find more information about template customization in the Admin Manual (the process is the same for web templates as it is for email templates).
I found “sharedBy” in the files:
shared_file_view_react.html
view_shared_dir_react.html
moved /custom/templates/ along the path
if I delete the line "sharedBy: '{{…
then the line on the tab still remains, only the username is deleted.
I left it in this version - sharedBy: ‘Organization’,
And it works.
