nodebb-plugin-admin-chats 2.0.0 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +1,3 @@
1
- {
2
- "kiroAgent.configureMCP": "Disabled"
1
+ {
2
+ "kiroAgent.configureMCP": "Disabled"
3
3
  }
package/README.md CHANGED
@@ -1,56 +1,56 @@
1
- # Super Admin Chat Control for NodeBB
2
-
3
- A professional administration plugin for NodeBB that allows administrators to monitor, manage, and interact with any chat room on the forum, regardless of membership.
4
-
5
- ## Main Features
6
-
7
- * **Global Chat Access**: Administrators can view any private or group conversation.
8
- * **Management Privileges**: Grants admins the ability to edit or delete any message in any room.
9
- * **Admin Room Locking**: Administrators can lock any chat room so only admins can continue replying.
10
- * **Profile Integration**: Adds a "View Chats" button to the user profile menu for administrators to quickly audit a user's interactions.
11
- * **Non-Intrusive Monitoring**: Admins can load and view room history without being added as permanent members, maintaining a clean member list.
12
- * **UI Enhancements**: Replaces generic "no chats" messages with helpful instructions for admins and supports both English and Hebrew interfaces.
13
-
14
- ## Technical Overview
15
-
16
- ### Plugin Information
17
- * **Name**: Super Admin Chat Control
18
- * **ID**: `nodebb-plugin-admin-chats`
19
- * **Compatibility**: NodeBB versions `^3.0.0` or `^4.0.0`
20
-
21
- ### Implemented Hooks
22
- The plugin utilizes several filters to elevate administrator permissions:
23
-
24
- | Hook | Method | Functionality |
25
- | :--- | :--- | :--- |
26
- | `filter:messaging.isRoomOwner` | `isRoomOwner` | Treats admins as owners for permission checks. |
27
- | `filter:messaging.canReply` | `canReply` | Allows admins to send messages in any room and blocks regular users in admin-locked rooms. |
28
- | `filter:messaging.canGetMessages` | `canGetMessages` | Allows admins to fetch chat history. |
29
- | `filter:messaging.loadRoom` | `onLoadRoom` | Manages room loading logic for non-member admins and injects lock state. |
30
- | `filter:user.accountMenu` | `addProfileLink` | Injects the admin link into the profile menu. |
31
-
32
- ### Function Overrides
33
- The plugin overrides core messaging functions to ensure full administrative control:
34
- * **Edit/Delete**: `Messaging.canEdit` and `Messaging.canDelete` are bypassed for administrators.
35
- * **Visibility**: `Messaging.canViewMessage` is modified to always return `true` for admins.
36
- * **Room Locking**: `Messaging.canReply` is wrapped so non-admins cannot post in rooms locked by an admin.
37
-
38
- ## Installation
39
-
40
- 1. Install the plugin via terminal:
41
- ```bash
42
- npm install nodebb-plugin-admin-chats
43
- ```
44
- 2. Activate the plugin in the NodeBB Admin Control Panel (ACP).
45
- 3. Restart NodeBB.
46
-
47
- ## Client-Side Support
48
- The plugin includes a `client.js` script that:
49
- * Detects the system language (English or Hebrew).
50
- * Dynamically injects action buttons into the account sub-links menu.
51
- * Adds an admin lock/unlock control to the chat UI.
52
- * Disables the composer for non-admin users when a room is locked.
53
- * Cleans up the chat UI empty states for a better admin experience.
54
-
55
- ---
56
- *Developed by [palmoni5](https://github.com/palmoni5/nodebb-plugin-admin-chats).*
1
+ # Super Admin Chat Control for NodeBB
2
+
3
+ A professional administration plugin for NodeBB that allows administrators to monitor, manage, and interact with any chat room on the forum, regardless of membership.
4
+
5
+ ## Main Features
6
+
7
+ * **Global Chat Access**: Administrators can view any private or group conversation.
8
+ * **Management Privileges**: Grants admins the ability to edit or delete any message in any room.
9
+ * **Admin Room Locking**: Administrators can lock any chat room so only admins can continue replying.
10
+ * **Profile Integration**: Adds a "View Chats" button to the user profile menu for administrators to quickly audit a user's interactions.
11
+ * **Non-Intrusive Monitoring**: Admins can load and view room history without being added as permanent members, maintaining a clean member list.
12
+ * **UI Enhancements**: Replaces generic "no chats" messages with helpful instructions for admins and supports both English and Hebrew interfaces.
13
+
14
+ ## Technical Overview
15
+
16
+ ### Plugin Information
17
+ * **Name**: Super Admin Chat Control
18
+ * **ID**: `nodebb-plugin-admin-chats`
19
+ * **Compatibility**: NodeBB versions `^3.0.0` or `^4.0.0`
20
+
21
+ ### Implemented Hooks
22
+ The plugin utilizes several filters to elevate administrator permissions:
23
+
24
+ | Hook | Method | Functionality |
25
+ | :--- | :--- | :--- |
26
+ | `filter:messaging.isRoomOwner` | `isRoomOwner` | Treats admins as owners for permission checks. |
27
+ | `filter:messaging.canReply` | `canReply` | Allows admins to send messages in any room and blocks regular users in admin-locked rooms. |
28
+ | `filter:messaging.canGetMessages` | `canGetMessages` | Allows admins to fetch chat history. |
29
+ | `filter:messaging.loadRoom` | `onLoadRoom` | Manages room loading logic for non-member admins and injects lock state. |
30
+ | `filter:user.accountMenu` | `addProfileLink` | Injects the admin link into the profile menu. |
31
+
32
+ ### Function Overrides
33
+ The plugin overrides core messaging functions to ensure full administrative control:
34
+ * **Edit/Delete**: `Messaging.canEdit` and `Messaging.canDelete` are bypassed for administrators.
35
+ * **Visibility**: `Messaging.canViewMessage` is modified to always return `true` for admins.
36
+ * **Room Locking**: `Messaging.canReply` is wrapped so non-admins cannot post in rooms locked by an admin.
37
+
38
+ ## Installation
39
+
40
+ 1. Install the plugin via terminal:
41
+ ```bash
42
+ npm install nodebb-plugin-admin-chats
43
+ ```
44
+ 2. Activate the plugin in the NodeBB Admin Control Panel (ACP).
45
+ 3. Restart NodeBB.
46
+
47
+ ## Client-Side Support
48
+ The plugin includes a `client.js` script that:
49
+ * Detects the system language (English or Hebrew).
50
+ * Dynamically injects action buttons into the account sub-links menu.
51
+ * Adds an admin lock/unlock control to the chat UI.
52
+ * Disables the composer for non-admin users when a room is locked.
53
+ * Cleans up the chat UI empty states for a better admin experience.
54
+
55
+ ---
56
+ *Developed by [palmoni5](https://github.com/palmoni5/nodebb-plugin-admin-chats).*