Hide the Object Picker in Unity Editor in ObjectField

I’m just asking if there is any possibility to hide the “Object Picker” (The little knob/menu next to an ObjectField in a custom Inspector. I am putting a bunch of these object fields right next to each other, and the object picker is getting in the way.

I’ve got another solution: Ignore the pick result of this object picker, while I still don’t know how to hide this button and the pickerwindow, here is the code:

    // Register another callback of this object field
    // In this callback, is a trick
    private void DefaultAssetFieldCallback(ChangeEvent<UnityEngine.Object> evt) {
        // unregister the callback first
        // trick: set back to the old value
        m_ConfigAssetField.value = evt.previousValue;
        // register the callback again

Necroing old thread. But I needed to do something similar and found a way to do this by stepping through the ObjectField in the UIToolkit Debugger. The type of the little object selector button is hidden, so we cant really work with the class itself.

This solution is using UIToolkit.

public override VisualElement CreatePropertyGUI(SerializedProperty property)
            //  Create ObjectField
            var field = new ObjectField(property.displayName);
            field.objectType = typeof(MyType);

            //  Find the little circle button,
            //  The button is of type ObjectFieldSelector 
            //  which i think is internal which is why we cant simply do 
            //  button.Q<ObjectFieldSelector>
            var objectSelector = FindChild(field, "unity-object-field__selector");

            //  Make the button invisible
            objectSelector.visible = false;
            return field;

//  Helper method to find the button using a depth first search
private VisualElement FindChild(VisualElement parent, string ussClass)
    foreach(var child in parent.Children())
        if (child.ClassListContains(ussClass))
            return child;

        var subChild = FindChild(child, ussClass);
        if (subChild != null)
            return subChild;
    return null;