Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
59c891a937 | ||
|
310679ce3c |
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
build/*
|
8
Makefile
Normal file
8
Makefile
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
APP_NAME=minimalprofile
|
||||||
|
VERSION=$(shell grep '<version>' appinfo/info.xml | sed -E 's/.*<version>(.*)<\/version>.*/\1/')
|
||||||
|
|
||||||
|
.PHONY: appstore
|
||||||
|
|
||||||
|
appstore:
|
||||||
|
mkdir -p build
|
||||||
|
tar --exclude-vcs --exclude='build' --exclude='*.tar.gz' -czf build/$(APP_NAME)-$(VERSION).tar.gz -C .. $(notdir $(CURDIR))
|
23
README.md
23
README.md
@ -1,2 +1,23 @@
|
|||||||
# nextcloud_minimalprofile
|
# Minimal Profile Display for Nextcloud
|
||||||
|
|
||||||
|
**Minimal Profile Display** is a lightweight Nextcloud app that allows users and administrators to simplify user profile pages by hiding certain optional fields, such as pronouns.
|
||||||
|
|
||||||
|
This app is perfect for those who prefer a cleaner, distraction-free interface without altering the underlying user data.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ✨ Features
|
||||||
|
|
||||||
|
- Hide the Pronouns field from user profiles
|
||||||
|
- Lightweight: No database changes or backend processing
|
||||||
|
- Fully reversible: Simply disable the app to restore default profiles
|
||||||
|
- Compatible with Nextcloud 26 to 31
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 📥 Installation
|
||||||
|
|
||||||
|
1. Download the latest release from the [Releases page](https://code.taurix.net/TaurixIT/nextcloud_minimalprofile/releases).
|
||||||
|
2. Extract the archive into your Nextcloud `custom_apps/` directory:
|
||||||
|
```bash
|
||||||
|
tar -xvzf minimalprofile-*.tar.gz -C /var/www/nextcloud/custom_apps/
|
||||||
|
@ -3,5 +3,5 @@ namespace OCA\MinimalProfile\AppInfo;
|
|||||||
|
|
||||||
use OCP\Util;
|
use OCP\Util;
|
||||||
|
|
||||||
Util::addStyle('minimalprofile', 'style');
|
Util::addStyle("minimalprofile", "style");
|
||||||
Util::addScript('minimalprofile', 'script');
|
Util::addScript("minimalprofile", "hidePronouns");
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
</description>
|
</description>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
<licence>agpl</licence>
|
<licence>agpl</licence>
|
||||||
<author>Your Name</author>
|
<author>Guy Van Sanden</author>
|
||||||
<namespace>MinimalProfile</namespace>
|
<namespace>MinimalProfile</namespace>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<nextcloud min-version="26" max-version="31" />
|
<nextcloud min-version="26" max-version="31" />
|
||||||
|
19
js/hidePronouns.js
Normal file
19
js/hidePronouns.js
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
document.addEventListener("DOMContentLoaded", function () {
|
||||||
|
function tryToHidePronouns() {
|
||||||
|
const sections = document.querySelectorAll("section");
|
||||||
|
|
||||||
|
for (const section of sections) {
|
||||||
|
const label = section.querySelector("label");
|
||||||
|
if (label && label.textContent.trim().toLowerCase() === "pronouns") {
|
||||||
|
console.log("Found Pronouns field, hiding section...");
|
||||||
|
section.style.display = "none";
|
||||||
|
clearInterval(checkInterval); // stop checking
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
const checkInterval = setInterval(tryToHidePronouns, 500); // retry every half second
|
||||||
|
|
||||||
|
console.log("Started polling to find Pronouns field...");
|
||||||
|
});
|
@ -1,7 +0,0 @@
|
|||||||
|
|
||||||
document.addEventListener('DOMContentLoaded', function () {
|
|
||||||
const pronounField = document.querySelector('[data-profile-field="pronouns"]');
|
|
||||||
if (pronounField) {
|
|
||||||
pronounField.style.display = 'none';
|
|
||||||
}
|
|
||||||
});
|
|
Loading…
x
Reference in New Issue
Block a user