Double configuration properties for datatype

I have upgraded a site from v13.3.0 to v17.1.0 and most seems to work.

However I noticed a few things:

Including a custom button picker property editor UI used in a v16 project (although started from clean install).

I wonder if anyone else have had similar issues?

It seems it happens because the property editor has the settings properties, but also reference a property editor schema.

It seems it resolved the duplicate settings, when removing the properties under propertyEditorUi manifest and the schema manifest defines the properties.

Not sure why it worked in v16 though, maybe it was fixed for v17.

@nielslyngsoe @jacob I guess something changes from v16 to v17 regarding this: :slight_smile:

I my use case instead of the following (but similar issue for OEmbed property editor by @dawoe ):

mport { MCB_BUTTON_PICKER_PROPERTY_EDITOR_UI_ALIAS } from './constants.js';
import { manifest as schemaManifest } from './property-editor-schema.js';

export const manifests: Array<UmbExtensionManifest> = [
	{
		type: 'propertyEditorUi',
		alias: MCB_BUTTON_PICKER_PROPERTY_EDITOR_UI_ALIAS,
		name: 'Button Picker Property Editor UI',
		element: () => import('./property-editor-ui-button-picker.element.js'),
		meta: {
			label: 'Button Picker',
            propertyEditorSchemaAlias: 'MCB.ButtonPicker',
            icon: 'icon-mouse-cursor',
			group: 'pickers',
			supportsReadOnly: true,
            "settings": {
                "properties": [
                    {
                        "alias": "multiple",
                        "label": "Multiple",
                        "description": "Allow multiple selection.",
                        "propertyEditorUiAlias": "Umb.PropertyEditorUi.Toggle"
                    },
                    {
                        "alias": "defaultValue",
                        "label": "Default value",
                        "description": "If no default value selected, first value is used.",
                        "propertyEditorUiAlias": "Umb.PropertyEditorUi.TextBox"
                    },
                    {
                        "alias": "buttons",
                        "label": "Buttons",
                        "description": "The defined buttons.",
                        "propertyEditorUiAlias": "Mcb.PropertyEditorUi.MultiValuesEditor"
                    },
                    {
                        "alias": "size",
                        "label": "Size",
                        "description": "Size of the buttons.",
                        "propertyEditorUiAlias": "Umb.PropertyEditorUi.Dropdown",
                        "config": [
                            {
                                "alias": "items",
                                "value": [
                                    {
                                        "name": "Small",
                                        "value": "small"
                                    },
                                    {
                                        "name": "Medium",
                                        "value": "medium"
                                    },
                                    {
                                        "name": "Large",
                                        "value": "large"
                                    }
                                ]
                            }
                        ]
                    },
                    {
                        "alias": "showIcons",
                        "label": "Show icons",
                        "description": "Show selected icons in buttons.",
                        "propertyEditorUiAlias": "Umb.PropertyEditorUi.Toggle"
                    }
                ],
                defaultData: [
                    {
                        alias: "size",
                        value: "medium"
                    }
                ]
            }
		},
	},
	schemaManifest,
];

I have this:

import { MCB_BUTTON_PICKER_PROPERTY_EDITOR_UI_ALIAS } from './constants.js';
import { manifest as schemaManifest } from './property-editor-schema.js';

export const manifests: Array<UmbExtensionManifest> = [
	{
		type: 'propertyEditorUi',
		alias: MCB_BUTTON_PICKER_PROPERTY_EDITOR_UI_ALIAS,
		name: 'Button Picker Property Editor UI',
		element: () => import('./property-editor-ui-button-picker.element.js'),
		meta: {
			label: 'Button Picker',
            propertyEditorSchemaAlias: 'MCB.ButtonPicker',
            icon: 'icon-mouse-cursor',
			group: 'pickers',
			supportsReadOnly: true,
		},
	},
	schemaManifest,
];

And the property editor schema manifest looks like this:

import type { ManifestPropertyEditorSchema } from '@umbraco-cms/backoffice/property-editor';

export const manifest: ManifestPropertyEditorSchema = {
	type: 'propertyEditorSchema',
	name: 'Button Picker',
	alias: 'MCB.ButtonPicker',
	meta: {
		defaultPropertyEditorUiAlias: 'Mcb.PropertyEditorUi.ButtonsPicker',
		settings: {
            properties: [
                {
                    alias: "multiple",
                    label: "Multiple",
                    description: "Allow multiple selection.",
                    propertyEditorUiAlias: "Umb.PropertyEditorUi.Toggle"
                },
                {
                    alias: "defaultValue",
                    label: "Default value",
                    description: "If no default value selected, first value is used.",
                    propertyEditorUiAlias: "Umb.PropertyEditorUi.TextBox"
                },
                {
                    alias: "buttons",
                    label: "Buttons",
                    description: "The defined buttons.",
                    propertyEditorUiAlias: "Mcb.PropertyEditorUi.MultiValuesEditor"
                },
                {
                    alias: "size",
                    label: "Size",
                    description: "Size of the buttons.",
                    propertyEditorUiAlias: "Umb.PropertyEditorUi.Dropdown"
                },
                {
                    alias: "showIcons",
                    label: "Show icons",
                    description: "Show selected icons in buttons.",
                    propertyEditorUiAlias: "Umb.PropertyEditorUi.Toggle"
                }
            ]
		},
	},
};

I have also moved defaultData to propertyEditorSchema.

defaultData: [
    {
        alias: "size",
        value: "medium"
    }
]

But not sure why it shows empty options in Umb.PropertyEditorUi.Dropdown: