# Half-sized custom user objects

**URL:** <https://community.zammad.org/t/half-sized-custom-user-objects/11127>\
**Category:** Lobby\
**Created:** [March 17, 2023, 9:45am UTC](https://community.zammad.org/t/half-sized-custom-user-objects/11127 "2023-03-17T09:45:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![richie\_77](https://community.zammad.org/user_avatar/community.zammad.org/richie_77/32/5964_2.png) [@richie\_77](https://community.zammad.org/u/richie_77)\
**Post date:** [March 17, 2023, 9:45am UTC](https://community.zammad.org/t/half-sized-custom-user-objects/11127/1 "2023-03-17T09:45:15Z")

</div>

Hello,

since this thread is closed:

> [@Half-sized custom user objects in the edit mask](https://community.zammad.org/t/half-sized-custom-user-objects-in-the-edit-mask/9230):
>
> Because i dont know, where to put this question, i’m writing this in Lobby: Is it possible to create custom fields for the user edit mask, that are half-sized? Just like some of the default fields? The fields “email”, “phone” or “mobile” are half-sized by default. (There is a separate css class) I have created a new telephone field, which i want to have in the same size like the other contact fields.

i cannot post my solution there. I have found a way to modify custom text/tel objects to a half-sized text box.

You have to use the api to manipulate the custom field. There is an endpoint called “object\_manager\_attribute”. With a PUT-Request you can add the specific option “item\_class”, where you can set the value to “formGroup–halfSize”.

**Use it at your own risk, because you are manipulating objects on your system in a non-typical way!**

> **Summary**
>
> First get the ID of your custom object by calling the Endpoint with a GET-Request. If you know the id, you can edit the object by sending a PUT-Request to /api/v1/object\_manager\_attribute/{id} with the following minimalistic payload:
> 
> ```auto
> {
> "name": "phone2",
> "object":"User",
> "data_type": "input",
> "data_option": {
> "type": "tel",
> "maxlength": 120,
> "item_class": "formGroup--halfSize"
> }
> }
> 
> ```
> 
> Then the text field is in half size like first name or last name.

---

<div class="post-metadata">

**Author:** ![system](https://community.zammad.org/uploads/default/original/1X/5c5afaea2d23f811dbec33cd4edb02fa29d3262f.png) [@system](https://community.zammad.org/u/system)\
**Post date:** [March 11, 2024, 9:45am UTC](https://community.zammad.org/t/half-sized-custom-user-objects/11127/2 "2024-03-11T09:45:40Z")

</div>

This topic was automatically closed 360 days after the last reply. New replies are no longer allowed.
