core-geonetwork icon indicating copy to clipboard operation
core-geonetwork copied to clipboard

Metadata editor - Editor page indent type doesn't seem to work

Open josegar74 opened this issue 1 year ago • 3 comments

Describe the bug The setting Editor page indent type doesn't seem to work, the metadata editor is always displayed with the colored indent value:

metadata-editor-indent-setting

To Reproduce

Steps to reproduce the behavior:

  1. Go to Admin console > UI settings and set the value of Editor page indent type to Default, minimal indents
  2. Go to the Editor board and create a new iso19139 metadata.
  3. The editor is displayed with the colored indent value:

metadata-editor-indent

Expected behavior The editor is displayed using the style Default, minimal indents.

Additional context

This code doesn't seem to have effect:

https://github.com/geonetwork/core-geonetwork/blob/4bfd6cb6aae9887804a2629ef32bbb3d38f32402/web-ui/src/main/resources/catalog/js/edit/EditorController.js#L402-L412

@fxprunayre any idea about this? I would expect Default, minimal indents displays the metadata as used to be displayed in GeoNetwork 3.12.x.

josegar74 avatar Mar 02 '23 07:03 josegar74

The function works, but it doesn't enter in the if due to this:

https://github.com/geonetwork/core-geonetwork/blob/4bfd6cb6aae9887804a2629ef32bbb3d38f32402/schemas/iso19139/src/main/plugin/iso19139/layout/config-editor.xml#L3174

Removing that, it works. But apparently, apart of the 2 values defined in the setting, the config-editor.xml defines a new one gn-indent-bluescale, that is slightly different to the Colored indents style.

If this can be configured by metadata standard, maybe the setting should be removed? Or at least add some help in the setting to indicate that takes precedence what is defined in config-editor.xml?

josegar74 avatar Mar 02 '23 07:03 josegar74

Maybe we should have 2 settings:

  • Label above: true/false/config-editor.xml
  • Colored indent: blue/colored/config-editor.xml ?

fxprunayre avatar Mar 02 '23 07:03 fxprunayre

Not really sure how to manage it, as potentially can be created other styles.

josegar74 avatar Mar 02 '23 10:03 josegar74