geonetwork / core-geonetwork

GeoNetwork is a catalog application to manage spatially referenced resources. It provides powerful metadata editing and search functions as well as an interactive web map viewer. It is currently used in numerous Spatial Data Infrastructure initiatives across the world.
http://geonetwork-opensource.org/
GNU General Public License v2.0
426 stars 489 forks source link

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

Open josegar74 opened 1 year ago

josegar74 commented 1 year ago

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 commented 1 year ago

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?

fxprunayre commented 1 year ago

Maybe we should have 2 settings:

josegar74 commented 1 year ago

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