feat(contacts): admin-defined custom property types via app config - #5659
feat(contacts): admin-defined custom property types via app config#5659fberke wants to merge 2 commits into
Conversation
Assisted-by: Claude:claude-fable-5 Signed-off-by: Frank Berke <fb@wtmr.de>
|
Hi @fberke Thank you for the PR. I had a quick look at the code, and noticed one thing, we require that any newly created front end files be created in typescript. |
…nfig Assisted-by: Claude:claude-fable-5 Signed-off-by: Frank Berke <fb@wtmr.de>
|
Thanks for the quick look! Fair point — I converted |
|
Hello there, We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process. Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6 Thank you for contributing to Nextcloud and we hope to hear from you soon! (If you believe you should not receive this message, you can add yourself to the blocklist.) |
Summary
Allows admins to define custom property types (custom fields) for the contact editor via app config — no UI, a single
occcommand:The fields show up in the "Add more info" menu and in the contact details, read-only and merge views like built-in fields, and are stored as regular
X-…vCard properties, so they survive sync with other CardDAV clients.Implements the config-based flavor of #3273 / #303.
How it works
CustomPropertiesServicereads and validates thecustomPropertiesapp config (JSON). Onlyx-…property names are accepted; invalid entries are dropped and logged, so a broken config can never break the app. The config schema is documented in the class docblock.PageControllerprovides the sanitized list as initial state.rfcPropsregistry at boot (src/models/customProperties.js), so all existing views pick them up without further changes.Supported keys per entry:
label,force(text, default, orselect),options(TYPE parameter choices for text fields, value choices for select fields),multiple,primary,icon.Notes / limitations
textandselectfor now.Testing
PageControllerTestupdated for the new constructor dependency.X-…properties.🤖 Generated with Claude Code