geonetwork-ui 2.11.0-dev.57f4be358 → 2.11.0-dev.5a8170627

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/fesm2022/geonetwork-ui.mjs +717 -281
  2. package/fesm2022/geonetwork-ui.mjs.map +1 -1
  3. package/index.d.ts +152 -44
  4. package/index.d.ts.map +1 -1
  5. package/package.json +6 -5
  6. package/src/libs/api/metadata-converter/src/lib/dcat-ap/dcat-ap.converter.ts +2 -0
  7. package/src/libs/api/metadata-converter/src/lib/fixtures/mel.records.dataset+featurecatalog.ts +395 -0
  8. package/src/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.ts +35 -8
  9. package/src/libs/api/metadata-converter/src/lib/gn4/types/metadata.model.ts +19 -0
  10. package/src/libs/api/metadata-converter/src/lib/iso19115-3/iso19115-3.converter.ts +17 -6
  11. package/src/libs/api/metadata-converter/src/lib/iso19115-3/read-parts.ts +110 -0
  12. package/src/libs/api/metadata-converter/src/lib/iso19115-3/write-parts.ts +131 -0
  13. package/src/libs/api/metadata-converter/src/lib/iso19139/iso19139.converter.ts +9 -0
  14. package/src/libs/api/metadata-converter/src/lib/iso19139/read-parts.ts +2 -1
  15. package/src/libs/api/repository/src/lib/gn4/elasticsearch/elasticsearch.service.ts +29 -23
  16. package/src/libs/api/repository/src/lib/gn4/gn4-repository.ts +79 -35
  17. package/src/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.ts +11 -0
  18. package/src/libs/common/domain/src/lib/model/record/flags.model.ts +1 -0
  19. package/src/libs/common/domain/src/lib/model/record/index.ts +1 -0
  20. package/src/libs/common/domain/src/lib/model/record/metadata.model.ts +14 -18
  21. package/src/libs/common/domain/src/lib/platform.service.interface.ts +1 -0
  22. package/src/libs/common/domain/src/lib/repository/records-repository.interface.ts +20 -1
  23. package/src/libs/common/fixtures/src/lib/records.fixtures.ts +42 -62
  24. package/src/libs/feature/dataviz/src/lib/service/data.service.ts +32 -19
  25. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-constraints/form-field-constraints.component.ts +3 -5
  26. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts/form-field-contacts.component.ts +2 -2
  27. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-record-flags/form-field-record-flag-component.css +0 -0
  28. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-record-flags/form-field-record-flag-component.html +18 -0
  29. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-record-flags/form-field-record-flag-component.ts +86 -0
  30. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.html +100 -88
  31. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.ts +11 -4
  32. package/src/libs/feature/editor/src/lib/components/record-form/record-form.component.ts +18 -4
  33. package/src/libs/feature/editor/src/lib/expressions.ts +67 -0
  34. package/src/libs/feature/editor/src/lib/fields.config.ts +13 -0
  35. package/src/libs/feature/editor/src/lib/models/editor-config.model.ts +10 -4
  36. package/src/libs/feature/record/src/lib/state/mdview.effects.ts +3 -1
  37. package/src/libs/feature/record/src/lib/state/mdview.facade.ts +1 -1
  38. package/src/libs/feature/search/src/lib/filter-dropdown/filter-dropdown.component.html +7 -1
  39. package/src/libs/feature/search/src/lib/filter-dropdown/filter-dropdown.component.ts +18 -1
  40. package/src/libs/feature/search/src/lib/geocoding/geocoding.service.ts +41 -2
  41. package/src/libs/feature/search/src/lib/location-search/location-search.component.html +11 -1
  42. package/src/libs/feature/search/src/lib/location-search/location-search.component.ts +77 -3
  43. package/src/libs/feature/search/src/lib/utils/service/fields.service.ts +6 -0
  44. package/src/libs/feature/search/src/lib/utils/service/fields.ts +2 -1
  45. package/src/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.html +3 -3
  46. package/src/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.ts +2 -2
  47. package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.css +0 -4
  48. package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.html +2 -2
  49. package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.ts +3 -3
  50. package/src/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.ts +2 -1
  51. package/src/libs/ui/inputs/src/lib/spatial-extent-dropdown/spatial-extent-dropdown.component.html +7 -1
  52. package/src/libs/ui/inputs/src/lib/spatial-extent-dropdown/spatial-extent-dropdown.component.ts +26 -3
  53. package/src/libs/util/app-config/src/index.ts +1 -0
  54. package/src/libs/util/app-config/src/lib/app-config.ts +338 -272
  55. package/src/libs/util/app-config/src/lib/fixtures.ts +4 -0
  56. package/src/libs/util/app-config/src/lib/model.ts +28 -1
  57. package/src/libs/util/app-config/src/lib/parse-utils.ts +8 -4
  58. package/src/libs/util/shared/src/lib/utils/geojson.ts +21 -10
  59. package/translations/de.json +8 -1
  60. package/translations/en.json +8 -1
  61. package/translations/es.json +8 -1
  62. package/translations/fr.json +9 -2
  63. package/translations/it.json +8 -1
  64. package/translations/nl.json +8 -1
  65. package/translations/pt.json +8 -1
  66. package/translations/sk.json +8 -1
@@ -134,13 +134,13 @@ export class AutocompleteComponent
134
134
  getExtraClass(): string {
135
135
  if (this.allowSubmit) {
136
136
  if (this.enterButton) {
137
- return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+var(--icon-padding))] inset-y-[--icon-padding]'
137
+ return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+var(--icon-padding))] top-1/2 -translate-y-1/2'
138
138
  } else {
139
- return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+0.25*var(--icon-width))] inset-y-[calc(0.25*var(--icon-width))]'
139
+ return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+0.25*var(--icon-width))] top-1/2 -translate-y-1/2'
140
140
  }
141
141
  } else {
142
142
  if (!this.enterButton) {
143
- return 'border rounded-lg absolute w-8 h-8 right-2 inset-y-2'
143
+ return 'border rounded-lg absolute w-8 h-8 right-2 top-1/2 -translate-y-1/2'
144
144
  }
145
145
  }
146
146
  return 'border rounded-lg absolute w-8 h-8'
@@ -56,7 +56,8 @@ export class SearchFeatureCatalogComponent {
56
56
  const fuzzyFilter = createFuzzyFilter(searchTerm)
57
57
  return (
58
58
  fuzzyFilter(featureType.name) ||
59
- (featureType.definition && fuzzyFilter(featureType.definition))
59
+ (featureType.description &&
60
+ fuzzyFilter(featureType.description))
60
61
  )
61
62
  }
62
63
  )
@@ -58,7 +58,12 @@
58
58
  [class]="
59
59
  (hasSelection
60
60
  ? 'border-b-[1px] border-gray-400 pb-[20px]'
61
- : 'pb-[12px]') + ' text-black'
61
+ : 'pb-[12px]') + ' text-black flex flex-col gap-[8px]'
62
+ "
63
+ style="
64
+ --gn-ui-text-input-rounded: 8px;
65
+ --gn-ui-text-input-border-size: 1px;
66
+ --gn-ui-text-input-padding: 6px;
62
67
  "
63
68
  >
64
69
  <gn-ui-drag-and-drop-file-input
@@ -74,6 +79,7 @@
74
79
  (errorChange)="handleFileError($event)"
75
80
  data-cy="importGeojson"
76
81
  ></gn-ui-drag-and-drop-file-input>
82
+ <ng-content></ng-content>
77
83
  </div>
78
84
 
79
85
  @if (hasSelection) {
@@ -53,6 +53,12 @@ const LABEL_FROM_FILE = marker('search.filters.spatialExtent.bboxFromFile')
53
53
  const LABEL_FROM_FILE_DELETE = marker(
54
54
  'search.filters.spatialExtent.bboxFromFileDelete'
55
55
  )
56
+ const LABEL_FROM_LOCATION = marker(
57
+ 'search.filters.spatialExtent.bboxFromLocation'
58
+ )
59
+ const LABEL_FROM_LOCATION_DELETE = marker(
60
+ 'search.filters.spatialExtent.bboxFromLocationDelete'
61
+ )
56
62
  const LABEL_INITIAL = marker('search.filters.spatialExtent.bboxInitial')
57
63
  const LABEL_INITIAL_DELETE = marker(
58
64
  'search.filters.spatialExtent.bboxInitialDelete'
@@ -105,6 +111,7 @@ export class SpatialExtentDropdownComponent {
105
111
 
106
112
  bbox: BoundingBox | null = null
107
113
  fileName = ''
114
+ locationName = ''
108
115
 
109
116
  @ViewChild('overlayOrigin') overlayOrigin: CdkOverlayOrigin
110
117
  @ViewChild(CdkConnectedOverlay) overlay: CdkConnectedOverlay
@@ -138,15 +145,19 @@ export class SpatialExtentDropdownComponent {
138
145
  }
139
146
 
140
147
  get selectionLabelKey() {
141
- return this.fileName ? LABEL_FROM_FILE : LABEL_INITIAL
148
+ if (this.fileName) return LABEL_FROM_FILE
149
+ if (this.locationName) return LABEL_FROM_LOCATION
150
+ return LABEL_INITIAL
142
151
  }
143
152
 
144
153
  get selectionDeleteLabelKey() {
145
- return this.fileName ? LABEL_FROM_FILE_DELETE : LABEL_INITIAL_DELETE
154
+ if (this.fileName) return LABEL_FROM_FILE_DELETE
155
+ if (this.locationName) return LABEL_FROM_LOCATION_DELETE
156
+ return LABEL_INITIAL_DELETE
146
157
  }
147
158
 
148
159
  get selectionLabelParams() {
149
- return { fileName: this.fileName }
160
+ return { fileName: this.fileName, locationName: this.locationName }
150
161
  }
151
162
 
152
163
  openOverlay() {
@@ -186,6 +197,7 @@ export class SpatialExtentDropdownComponent {
186
197
  }
187
198
  this.bbox = bbox
188
199
  this.fileName = file.name
200
+ this.locationName = ''
189
201
  this.bboxChange.emit(bbox)
190
202
  this.cd.markForCheck()
191
203
  } catch {
@@ -194,6 +206,16 @@ export class SpatialExtentDropdownComponent {
194
206
  }
195
207
  }
196
208
 
209
+ setLocationBbox(bbox: BoundingBox, name: string) {
210
+ this.errorKey = null
211
+ this.bbox = bbox
212
+ this.locationName = name
213
+ this.fileName = ''
214
+ this.fileInput?.clear()
215
+ this.bboxChange.emit(bbox)
216
+ this.cd.markForCheck()
217
+ }
218
+
197
219
  handleFileError(error: DragAndDropFileInputError) {
198
220
  if (error === 'file-too-large') {
199
221
  this.setError(marker('search.filters.spatialExtent.error.fileTooLarge'), {
@@ -213,6 +235,7 @@ export class SpatialExtentDropdownComponent {
213
235
  removeSelection(event: Event) {
214
236
  this.bbox = null
215
237
  this.fileName = ''
238
+ this.locationName = ''
216
239
  this.errorKey = null
217
240
  this.fileInput?.clear()
218
241
  this.bboxChange.emit(null)
@@ -2,3 +2,4 @@ export * from './lib/app-config'
2
2
  export * from './lib/fixtures'
3
3
  export * from './lib/model'
4
4
  export * from './lib/map-layers'
5
+ export * from './lib/parse-utils'