public static void ConstantEditorGUI(SerializedObject o, GUIContent label, Stencil stencil,
                                             ConstantEditorMode mode = ConstantEditorMode.ValueOnly, Action onChange = null)
        {
            if (!(o.targetObject is AbstractNodeAsset asset))
            {
                return;
            }

            switch (asset.Model)
            {
            case ConstantNodeModel constantNodeModel when constantNodeModel.IsLocked:
                return;

            case EnumConstantNodeModel enumModel:
            {
                if (mode != ConstantEditorMode.ValueOnly)
                {
                    var filter = new SearcherFilter(SearcherContext.Type).WithEnums(stencil);
                    stencil.TypeEditor(enumModel.value.EnumType,
                                       (type, index) =>
                        {
                            enumModel.value.EnumType = type;
                            onChange?.Invoke();
                        }, filter);
                }
                enumModel.value.Value = Convert.ToInt32(EditorGUILayout.EnumPopup("Value", enumModel.EnumValue));
                break;
            }

            default:
                EditorGUILayout.PropertyField(o.FindProperty("m_NodeModel.value"), label, true);
                break;
            }
        }