custom_profile_fields: Support non editable profile fields.

This commit allows configuration of "editable_by_user" property from the
organization settings modal. It also adds support for non-editable
fields in profile settings modal.

Fixes #22883.

Co-Authored-By: Ujjawal Modi <umodi2003@gmail.com>
This commit is contained in:
tnmkr
2024-08-15 20:08:27 +05:30
committed by Tim Abbott
parent fc5cdd9e83
commit 23efb5cec7
11 changed files with 86 additions and 11 deletions

View File

@@ -762,6 +762,18 @@ export function initialize(): void {
},
});
tippy.delegate("body", {
target: ".settings-profile-user-field.not-editable-by-user-input-wrapper",
content: $t({
defaultMessage:
"You are not allowed to change this field. Contact an administrator to update it.",
}),
appendTo: () => document.body,
onHidden(instance) {
instance.destroy();
},
});
tippy.delegate("body", {
target: ".popover-contains-shift-hotkey",
trigger: "mouseenter",