geonetwork-ui 2.11.0-dev.cf22e64cf → 2.11.0-dev.d02d7f3f8

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 (72) hide show
  1. package/fesm2022/geonetwork-ui.mjs +817 -302
  2. package/fesm2022/geonetwork-ui.mjs.map +1 -1
  3. package/index.d.ts +177 -46
  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/constant.ts +4 -0
  16. package/src/libs/api/repository/src/lib/gn4/elasticsearch/elasticsearch.service.ts +57 -24
  17. package/src/libs/api/repository/src/lib/gn4/gn4-repository.ts +82 -35
  18. package/src/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.ts +11 -0
  19. package/src/libs/common/domain/src/lib/model/record/flags.model.ts +1 -0
  20. package/src/libs/common/domain/src/lib/model/record/index.ts +1 -0
  21. package/src/libs/common/domain/src/lib/model/record/metadata.model.ts +14 -18
  22. package/src/libs/common/domain/src/lib/model/search/aggregation.model.ts +2 -0
  23. package/src/libs/common/domain/src/lib/platform.service.interface.ts +1 -0
  24. package/src/libs/common/domain/src/lib/repository/records-repository.interface.ts +20 -1
  25. package/src/libs/common/fixtures/src/lib/records.fixtures.ts +42 -62
  26. package/src/libs/feature/dataviz/src/lib/service/data.service.ts +32 -19
  27. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-constraints/form-field-constraints.component.ts +3 -5
  28. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts/form-field-contacts.component.ts +2 -2
  29. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-record-flags/form-field-record-flag-component.css +0 -0
  30. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-record-flags/form-field-record-flag-component.html +18 -0
  31. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-record-flags/form-field-record-flag-component.ts +86 -0
  32. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.html +100 -88
  33. package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field.component.ts +11 -4
  34. package/src/libs/feature/editor/src/lib/components/record-form/record-form.component.ts +18 -4
  35. package/src/libs/feature/editor/src/lib/expressions.ts +67 -0
  36. package/src/libs/feature/editor/src/lib/fields.config.ts +13 -0
  37. package/src/libs/feature/editor/src/lib/models/editor-config.model.ts +10 -4
  38. package/src/libs/feature/record/src/lib/state/mdview.effects.ts +3 -1
  39. package/src/libs/feature/record/src/lib/state/mdview.facade.ts +1 -1
  40. package/src/libs/feature/search/src/lib/filter-dropdown/filter-dropdown.component.html +7 -1
  41. package/src/libs/feature/search/src/lib/filter-dropdown/filter-dropdown.component.ts +18 -1
  42. package/src/libs/feature/search/src/lib/geocoding/geocoding.service.ts +41 -2
  43. package/src/libs/feature/search/src/lib/location-search/location-search.component.html +11 -1
  44. package/src/libs/feature/search/src/lib/location-search/location-search.component.ts +77 -3
  45. package/src/libs/feature/search/src/lib/utils/service/fields.service.ts +50 -4
  46. package/src/libs/feature/search/src/lib/utils/service/fields.ts +35 -10
  47. package/src/libs/ui/elements/src/lib/kind-badge/kind-badge.component.html +5 -1
  48. package/src/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.html +3 -3
  49. package/src/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.ts +2 -2
  50. package/src/libs/ui/elements/src/lib/thumbnail/thumbnail.component.html +1 -1
  51. package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.css +0 -4
  52. package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.html +2 -2
  53. package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.ts +3 -3
  54. package/src/libs/ui/inputs/src/lib/inline-filter/inline-filter.component.html +6 -11
  55. package/src/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.ts +2 -1
  56. package/src/libs/ui/inputs/src/lib/spatial-extent-dropdown/spatial-extent-dropdown.component.html +7 -1
  57. package/src/libs/ui/inputs/src/lib/spatial-extent-dropdown/spatial-extent-dropdown.component.ts +26 -3
  58. package/src/libs/ui/search/src/lib/results-hits-number/results-hits-number.component.html +1 -0
  59. package/src/libs/util/app-config/src/index.ts +1 -0
  60. package/src/libs/util/app-config/src/lib/app-config.ts +338 -270
  61. package/src/libs/util/app-config/src/lib/fixtures.ts +21 -0
  62. package/src/libs/util/app-config/src/lib/model.ts +30 -3
  63. package/src/libs/util/app-config/src/lib/parse-utils.ts +8 -4
  64. package/src/libs/util/shared/src/lib/utils/geojson.ts +21 -10
  65. package/translations/de.json +10 -2
  66. package/translations/en.json +10 -2
  67. package/translations/es.json +10 -2
  68. package/translations/fr.json +11 -3
  69. package/translations/it.json +10 -2
  70. package/translations/nl.json +10 -2
  71. package/translations/pt.json +10 -2
  72. package/translations/sk.json +10 -2
@@ -52,7 +52,7 @@ import { matClose, matContentCopy, matExpandMore, matExpandLess, matSearch, matS
52
52
  import * as i1$4 from '@angular/material/checkbox';
53
53
  import { MatCheckboxModule } from '@angular/material/checkbox';
54
54
  import * as i1$5 from '@angular/material/tooltip';
55
- import { MatTooltipModule } from '@angular/material/tooltip';
55
+ import { MatTooltipModule, MatTooltip } from '@angular/material/tooltip';
56
56
  import { MAT_DATE_LOCALE, MAT_DATE_FORMATS, DateAdapter } from '@angular/material/core';
57
57
  import { MAT_DATE_FNS_FORMATS, DateFnsAdapter } from '@angular/material-date-fns-adapter';
58
58
  import { enUS } from 'date-fns/locale/en-US';
@@ -71,6 +71,7 @@ import * as i2$2 from '@ngrx/effects';
71
71
  import { Actions, createEffect, ofType, EffectsModule } from '@ngrx/effects';
72
72
  import { valid as valid$1 } from 'geojson-validation';
73
73
  import { queryGeoplateforme, queryGeonames, queryGeoadmin } from '@geospatial-sdk/geocoding';
74
+ import pointer from 'jsonpointer';
74
75
  import { TemplatePortal } from '@angular/cdk/portal';
75
76
  import { parse as parse$3 } from 'marked';
76
77
  import * as i2$3 from '@angular/cdk/scrolling';
@@ -1137,7 +1138,7 @@ function kindToCodeListValue(record) {
1137
1138
  }
1138
1139
 
1139
1140
  function extractCharacterString() {
1140
- return pipe(fallback(findChildElement('gco:CharacterString', false), findChildElement('gmx:Anchor', false), findChildElement('gmx:MimeFileType', false)), readText());
1141
+ return pipe(fallback(findChildElement('gco:CharacterString', false), findChildElement('gmx:Anchor', false), findChildElement('gmx:MimeFileType', false), findChildElement('gco:LocalName', false)), readText());
1141
1142
  }
1142
1143
  /**
1143
1144
  * Translated values will also be collected in the translations object
@@ -2200,6 +2201,7 @@ class Iso19139Converter extends BaseConverter {
2200
2201
  lineage: readLineage$1,
2201
2202
  sourceRecords: readSourceRecords$1,
2202
2203
  associatedRecords: readAssociatedRecords$1,
2204
+ featureTypeDescriptions: () => undefined,
2203
2205
  onlineResources: readOnlineResources$2,
2204
2206
  temporalExtents: readTemporalExtents,
2205
2207
  spatialExtents: readSpatialExtents$1,
@@ -2239,6 +2241,7 @@ class Iso19139Converter extends BaseConverter {
2239
2241
  lineage: writeLineage$1,
2240
2242
  sourceRecords: writeSourceRecords$1,
2241
2243
  associatedRecords: writeAssociatedRecords$1,
2244
+ featureTypeDescriptions: () => undefined,
2242
2245
  onlineResources: writeOnlineResources$1,
2243
2246
  temporalExtents: writeTemporalExtents,
2244
2247
  spatialExtents: writeSpatialExtents,
@@ -2365,6 +2368,7 @@ class Iso19139Converter extends BaseConverter {
2365
2368
  const sourceRecords = this.readers['sourceRecords'](rootEl, tr);
2366
2369
  const associatedRecords = this.readers['associatedRecords'](rootEl, tr);
2367
2370
  const updateFrequency = this.readers['updateFrequency'](rootEl, tr);
2371
+ const featureTypeDescriptions = this.readers['featureTypeDescriptions'](rootEl, tr);
2368
2372
  return this.afterRecordRead({
2369
2373
  ...this.readBaseRecord(rootEl, tr),
2370
2374
  kind,
@@ -2375,6 +2379,7 @@ class Iso19139Converter extends BaseConverter {
2375
2379
  ...(spatialRepresentation && { spatialRepresentation }),
2376
2380
  temporalExtents,
2377
2381
  updateFrequency,
2382
+ ...(featureTypeDescriptions?.length && { featureTypeDescriptions }),
2378
2383
  translations: tr,
2379
2384
  });
2380
2385
  }
@@ -2464,6 +2469,8 @@ class Iso19139Converter extends BaseConverter {
2464
2469
  this.writers['resourceIdentifiers'](record, rootEl);
2465
2470
  if (record.kind === 'dataset') {
2466
2471
  fieldChanged('status') && this.writers['status'](record, rootEl);
2472
+ fieldChanged('featureTypeDescriptions') &&
2473
+ this.writers['featureTypeDescriptions'](record, rootEl);
2467
2474
  }
2468
2475
  if (record.kind === 'dataset' || record.kind === 'reuse') {
2469
2476
  fieldChanged('updateFrequency') &&
@@ -2631,6 +2638,34 @@ function readDefaultLanguage$1(rootEl) {
2631
2638
  function readOtherLanguages(rootEl) {
2632
2639
  return pipe(findChildrenElement('mdb:otherLocale', false), mapArray(readLocaleElement()), map((languages) => languages.filter((lang) => lang !== null)))(rootEl);
2633
2640
  }
2641
+ function extractCharacterStringOrText() {
2642
+ return fallback(extractCharacterString(), readText());
2643
+ }
2644
+ function extractListedValue() {
2645
+ return pipe(combine(pipe(findChildElement('gfc:code', false), extractCharacterString()), pipe(findChildElement('gfc:label', false), extractCharacterString()), pipe(findChildElement('gfc:definition', false), extractCharacterString())), map(([code, label, description]) => ({
2646
+ value: code ?? '',
2647
+ ...(label && { label }),
2648
+ ...(description && { description }),
2649
+ })));
2650
+ }
2651
+ function extractFeatureAttribute() {
2652
+ return pipe(combine(pipe(findChildElement('gfc:memberName', false), extractCharacterStringOrText()), pipe(findChildElement('gfc:designation', false), extractCharacterString()), pipe(findChildElement('gfc:definition', false), extractCharacterString()), pipe(findChildElement('gfc:code', false), extractCharacterString()), pipe(findNestedElement('gfc:valueType', 'gco:TypeName', 'gco:aName'), extractCharacterString()), pipe(findNestedElements('gfc:listedValue', 'gfc:FC_ListedValue'), mapArray(extractListedValue()), filterArray((value) => !!(value.value || value.label)))), map(([name, label, description, code, type, values]) => ({
2653
+ name: name ?? '',
2654
+ ...(label && { label }),
2655
+ ...(description && { description }),
2656
+ ...(code && { code }),
2657
+ ...(type && { type }),
2658
+ ...(values.length > 0 && { values }),
2659
+ })));
2660
+ }
2661
+ function readFeatureTypeDescriptions(rootEl) {
2662
+ return pipe(findNestedElements('mdb:contentInfo', 'mrc:MD_FeatureCatalogue', 'mrc:featureCatalogue', 'gfc:FC_FeatureCatalogue', 'gfc:featureType', 'gfc:FC_FeatureType'), mapArray(pipe(combine(pipe(findChildElement('gfc:typeName', false), extractCharacterStringOrText()), pipe(findChildElement('gfc:designation', false), extractCharacterString()), pipe(findChildElement('gfc:definition', false), extractCharacterString()), pipe(findNestedElements('gfc:carrierOfCharacteristics', 'gfc:FC_FeatureAttribute'), mapArray(extractFeatureAttribute()))), map(([name, label, description, attributes]) => ({
2663
+ name: name ?? '',
2664
+ ...(label && { label }),
2665
+ ...(description && { description }),
2666
+ attributes,
2667
+ })))))(rootEl);
2668
+ }
2634
2669
 
2635
2670
  function writeUniqueIdentifier$1(record, rootEl) {
2636
2671
  pipe(findNestedChildOrCreate('mdb:metadataIdentifier', 'mcc:MD_Identifier', 'mcc:code'), writeCharacterString(record.uniqueIdentifier))(rootEl);
@@ -2785,6 +2820,52 @@ function writeAssociatedRecords(record, rootEl) {
2785
2820
  .filter((assoc) => assoc.uniqueIdentifier && assoc.associationType)
2786
2821
  .map((assoc) => pipe(createNestedElement('mri:associatedResource', 'mri:MD_AssociatedResource'), appendChildren(pipe(createNestedElement('mri:associationType', 'mri:DS_AssociationTypeCode'), writeAttribute('codeList', 'http://standards.iso.org/iso/19115/resources/Codelists/cat/codelists.xml#DS_AssociationTypeCode'), writeAttribute('codeListValue', assoc.associationType)), pipe(createElement('mri:metadataReference'), writeAttribute('uuidref', assoc.uniqueIdentifier)))))))(rootEl);
2787
2822
  }
2823
+ function createNilElement(name, nilReason) {
2824
+ return pipe(createElement(name), writeAttribute('gco:nilReason', nilReason));
2825
+ }
2826
+ function createFeatureCatalogueShell() {
2827
+ return pipe(createNestedElement('mdb:contentInfo', 'mrc:MD_FeatureCatalogue', 'mrc:featureCatalogue', 'gfc:FC_FeatureCatalogue'),
2828
+ // create mandatory elements which are not part of the model yet
2829
+ appendChildren(createNilElement('cat:name', 'missing'), createNilElement('cat:scope', 'missing'), createNilElement('cat:versionNumber', 'missing'), createNilElement('cat:versionDate', 'missing'), createNilElement('gfc:producer', 'missing')));
2830
+ }
2831
+ function createListedValue(value) {
2832
+ return pipe(createNestedElement('gfc:listedValue', 'gfc:FC_ListedValue'), appendChildren(value.label
2833
+ ? pipe(createElement('gfc:label'), writeCharacterString(value.label))
2834
+ : createNilElement('gfc:label', 'missing'), value.value
2835
+ ? pipe(createElement('gfc:code'), writeCharacterString(value.value))
2836
+ : null, value.description
2837
+ ? pipe(createElement('gfc:definition'), writeCharacterString(value.description))
2838
+ : null));
2839
+ }
2840
+ function createFeatureAttribute(attribute) {
2841
+ return pipe(createNestedElement('gfc:carrierOfCharacteristics', 'gfc:FC_FeatureAttribute'), appendChildren(pipe(createElement('gfc:memberName'), setTextContent(attribute.name)), attribute.description
2842
+ ? pipe(createElement('gfc:definition'), writeCharacterString(attribute.description))
2843
+ : null, createNilElement('gfc:cardinality', 'missing'), attribute.label
2844
+ ? pipe(createElement('gfc:designation'), writeCharacterString(attribute.label))
2845
+ : null, attribute.code
2846
+ ? pipe(createElement('gfc:code'), writeCharacterString(attribute.code))
2847
+ : null, attribute.type
2848
+ ? pipe(createNestedElement('gfc:valueType', 'gco:TypeName', 'gco:aName'), writeCharacterString(attribute.type))
2849
+ : null, ...(attribute.values ?? [])
2850
+ .filter((value) => value.value || value.label)
2851
+ .map(createListedValue)));
2852
+ }
2853
+ function createFeatureType(featureType) {
2854
+ return pipe(createNestedElement('gfc:featureType', 'gfc:FC_FeatureType'), appendChildren(pipe(createElement('gfc:typeName'), setTextContent(featureType.name)), featureType.description
2855
+ ? pipe(createElement('gfc:definition'), writeCharacterString(featureType.description))
2856
+ : null, pipe(createNestedElement('gfc:isAbstract', 'gco:Boolean'), setTextContent('false')), featureType.label
2857
+ ? pipe(createElement('gfc:designation'), writeCharacterString(featureType.label))
2858
+ : null, ...featureType.attributes.map(createFeatureAttribute), createNilElement('gfc:featureCatalogue', 'missing')));
2859
+ }
2860
+ function writeFeatureTypeDescriptions(record, rootEl) {
2861
+ const featureTypes = record.featureTypeDescriptions ?? [];
2862
+ const catalogues = findNestedElements('mdb:contentInfo', 'mrc:MD_FeatureCatalogue', 'mrc:featureCatalogue', 'gfc:FC_FeatureCatalogue')(rootEl);
2863
+ catalogues.forEach((catalogue) => removeChildrenByName('gfc:featureType')(catalogue));
2864
+ if (!featureTypes.length)
2865
+ return;
2866
+ const catalogue = catalogues[0] ?? appendChildTree(createFeatureCatalogueShell())(rootEl);
2867
+ appendChildren(...featureTypes.map(createFeatureType))(catalogue);
2868
+ }
2788
2869
 
2789
2870
  class Iso191153Converter extends Iso19139Converter {
2790
2871
  constructor() {
@@ -2801,6 +2882,7 @@ class Iso191153Converter extends Iso19139Converter {
2801
2882
  this.readers['lineage'] = readLineage;
2802
2883
  this.readers['sourceRecords'] = readSourceRecords;
2803
2884
  this.readers['associatedRecords'] = readAssociatedRecords;
2885
+ this.readers['featureTypeDescriptions'] = readFeatureTypeDescriptions;
2804
2886
  this.readers['onlineResources'] = readOnlineResources$1;
2805
2887
  this.readers['defaultLanguage'] = readDefaultLanguage$1;
2806
2888
  this.readers['otherLanguages'] = readOtherLanguages;
@@ -2821,6 +2903,7 @@ class Iso191153Converter extends Iso19139Converter {
2821
2903
  this.writers['lineage'] = writeLineage;
2822
2904
  this.writers['sourceRecords'] = writeSourceRecords;
2823
2905
  this.writers['associatedRecords'] = writeAssociatedRecords;
2906
+ this.writers['featureTypeDescriptions'] = writeFeatureTypeDescriptions;
2824
2907
  this.writers['onlineResources'] = writeOnlineResources;
2825
2908
  this.writers['status'] = writeStatus;
2826
2909
  this.writers['spatialRepresentation'] = writeSpatialRepresentation;
@@ -2910,10 +2993,12 @@ class Iso191153Converter extends Iso19139Converter {
2910
2993
  });
2911
2994
  }
2912
2995
  async writeRecord(record, reference) {
2913
- let result = await super.writeRecord(record, reference);
2914
- // fix gco namespace definition (changes between iso19139 and iso19115-3
2915
- result = result.replace('"http://www.isotc211.org/2005/gco"', '"http://standards.iso.org/iso/19115/-3/gco/1.0"');
2916
- return result;
2996
+ const result = await super.writeRecord(record, reference);
2997
+ // fix the gco and gfc namespace definitions (they change between iso19139 and iso19115-3);
2998
+ // only on the root element, where they are declared, so that nested declarations stay untouched
2999
+ return result.replace(/<mdb:MD_Metadata[^>]*>/, (rootTag) => rootTag
3000
+ .replace('"http://www.isotc211.org/2005/gco"', '"http://standards.iso.org/iso/19115/-3/gco/1.0"')
3001
+ .replace('"http://www.isotc211.org/2005/gfc"', '"http://standards.iso.org/iso/19110/gfc/1.1"'));
2917
3002
  }
2918
3003
  }
2919
3004
 
@@ -3457,6 +3542,7 @@ class DcatApConverter extends BaseConverter {
3457
3542
  lineage: () => '',
3458
3543
  sourceRecords: () => [],
3459
3544
  associatedRecords: () => [],
3545
+ featureTypeDescriptions: () => undefined,
3460
3546
  temporalExtents: () => [],
3461
3547
  spatialRepresentation: () => undefined,
3462
3548
  extras: () => undefined,
@@ -3492,6 +3578,7 @@ class DcatApConverter extends BaseConverter {
3492
3578
  lineage: () => undefined,
3493
3579
  sourceRecords: () => [],
3494
3580
  associatedRecords: () => [],
3581
+ featureTypeDescriptions: () => undefined,
3495
3582
  onlineResources: () => undefined,
3496
3583
  temporalExtents: () => undefined,
3497
3584
  spatialExtents: () => undefined,
@@ -18902,9 +18989,15 @@ class Gn4FieldMapper {
18902
18989
  isOpenData: (output, source) => this.addExtra({
18903
18990
  isOpenData: selectField(source, 'isOpenData') !== 'false',
18904
18991
  }, output),
18905
- featureTypes: (output, source) => this.addExtra({
18906
- featureTypes: selectField(source, 'featureTypes'),
18907
- }, output),
18992
+ featureTypes: (output, source) => {
18993
+ const featureTypes = getAsArray(selectField(source, 'featureTypes'));
18994
+ if (!featureTypes.length)
18995
+ return output;
18996
+ return {
18997
+ ...output,
18998
+ featureTypeDescriptions: this.featureTypesField(featureTypes),
18999
+ };
19000
+ },
18908
19001
  related: (output, source) => {
18909
19002
  const related = selectField(source, 'related');
18910
19003
  const fcatSource = selectField(getFirstValue(selectField(related, 'fcats')) ?? {}, '_source');
@@ -19040,6 +19133,27 @@ class Gn4FieldMapper {
19040
19133
  },
19041
19134
  };
19042
19135
  this.genericField = (output) => output;
19136
+ this.featureTypesField = (featureTypes) => featureTypes.map((featureType) => ({
19137
+ name: featureType.typeName ?? '',
19138
+ ...(featureType.definition && {
19139
+ description: featureType.definition,
19140
+ }),
19141
+ attributes: getAsArray(featureType.attributeTable ?? []).map((attr) => {
19142
+ const values = (attr.values ?? [])
19143
+ .filter((value) => value.code || value.label)
19144
+ .map((value) => ({
19145
+ value: value.code || '',
19146
+ ...(value.label && { label: value.label }),
19147
+ }));
19148
+ return {
19149
+ name: attr.name ?? '',
19150
+ ...(attr.definition && { description: attr.definition }),
19151
+ ...(attr.code && { code: attr.code }),
19152
+ ...(attr.type && { type: attr.type }),
19153
+ ...(values.length > 0 && { values }),
19154
+ };
19155
+ }),
19156
+ }));
19043
19157
  this.constraintField = (type, output, constraintArray) => {
19044
19158
  let outputField;
19045
19159
  switch (type) {
@@ -19294,6 +19408,9 @@ const ES_QUERY_FIELDS_PRIORITY = {
19294
19408
  'any.${searchLang}': 1,
19295
19409
  uuid: 1,
19296
19410
  };
19411
+ // This prefix is part of the category names stored in GeoNetwork: changing it
19412
+ // would silently drop the flags already set on existing catalogs.
19413
+ const RECORD_FLAG_CATEGORY_PREFIX = 'geonetwork-ui-flag:';
19297
19414
 
19298
19415
  function isDateRange(filter) {
19299
19416
  if (!filter)
@@ -19662,10 +19779,25 @@ function getGeometryBoundingBox(geometry) {
19662
19779
  }
19663
19780
  }
19664
19781
  /**
19665
- * Builds the closed GeoJSON Polygon matching the given bounding box.
19782
+ * Builds the GeoJSON Geometry matching the given bounding box.
19666
19783
  */
19667
- function bboxToPolygon(bbox) {
19784
+ function bboxToGeometry(bbox) {
19668
19785
  const [minX, minY, maxX, maxY] = bbox;
19786
+ if (minX === maxX && minY === maxY) {
19787
+ return {
19788
+ type: 'Point',
19789
+ coordinates: [minX, minY],
19790
+ };
19791
+ }
19792
+ if (minX === maxX || minY === maxY) {
19793
+ return {
19794
+ type: 'LineString',
19795
+ coordinates: [
19796
+ [minX, minY],
19797
+ [maxX, maxY],
19798
+ ],
19799
+ };
19800
+ }
19669
19801
  return {
19670
19802
  type: 'Polygon',
19671
19803
  coordinates: [
@@ -19687,7 +19819,7 @@ function spatialExtentToGeometry(extent) {
19687
19819
  if (extent.geometry)
19688
19820
  return extent.geometry;
19689
19821
  if (extent.bbox)
19690
- return bboxToPolygon(extent.bbox);
19822
+ return bboxToGeometry(extent.bbox);
19691
19823
  return null;
19692
19824
  }
19693
19825
  /**
@@ -20450,7 +20582,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
20450
20582
  }] } });
20451
20583
 
20452
20584
  var name = "geonetwork-ui";
20453
- var version = "2.11.0-dev.cf22e64cf";
20585
+ var version = "2.11.0-dev.d02d7f3f8";
20454
20586
  var engines = {
20455
20587
  node: ">=24"
20456
20588
  };
@@ -20492,10 +20624,10 @@ var dependencies = {
20492
20624
  "@biesbjerg/ngx-translate-extract-marker": "~1.0.0",
20493
20625
  "@camptocamp/ogc-client": "1.3.1-dev.200c02a",
20494
20626
  "@duckdb/duckdb-wasm": "~1.32.0",
20495
- "@geospatial-sdk/core": "0.0.5-dev.78",
20496
- "@geospatial-sdk/geocoding": "0.0.5-dev.78",
20497
- "@geospatial-sdk/legend": "0.0.5-dev.78",
20498
- "@geospatial-sdk/openlayers": "0.0.5-dev.78",
20627
+ "@geospatial-sdk/core": "0.0.5-dev.86.sha-124eae3",
20628
+ "@geospatial-sdk/geocoding": "0.0.5-dev.86.sha-124eae3",
20629
+ "@geospatial-sdk/legend": "0.0.5-dev.86.sha-124eae3",
20630
+ "@geospatial-sdk/openlayers": "0.0.5-dev.86.sha-124eae3",
20499
20631
  "@ltd/j-toml": "~1.38.0",
20500
20632
  "@messageformat/core": "~3.4.0",
20501
20633
  "@ng-icons/core": "~32.5.0",
@@ -20512,6 +20644,7 @@ var dependencies = {
20512
20644
  "embla-carousel": "~8.6.0",
20513
20645
  "flag-icons": "~7.5.0",
20514
20646
  "geojson-validation": "~1.0.2",
20647
+ jsonpointer: "^5.0.1",
20515
20648
  marked: "~17.0.4",
20516
20649
  "ngx-dropzone": "~3.1.0",
20517
20650
  "ngx-translate-messageformat-compiler": "~7.2.0",
@@ -20681,6 +20814,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
20681
20814
  type: Input
20682
20815
  }] } });
20683
20816
 
20817
+ const REFERENCE_DATASET_BOOST = 5;
20684
20818
  class ElasticsearchService {
20685
20819
  constructor() {
20686
20820
  this.translateService = inject(TranslateService);
@@ -20688,6 +20822,7 @@ class ElasticsearchService {
20688
20822
  // runtime fields are computed using a Painless script
20689
20823
  // see: https://www.elastic.co/guide/en/elasticsearch/reference/current/runtime-mapping-fields.html
20690
20824
  this.runtimeFields = {};
20825
+ this.fieldAliases = {};
20691
20826
  }
20692
20827
  // we're using getters in case the defined languages change over time
20693
20828
  get metadataLang() {
@@ -20759,6 +20894,9 @@ class ElasticsearchService {
20759
20894
  registerRuntimeField(fieldName, expression, type = 'keyword') {
20760
20895
  this.runtimeFields[fieldName] = { script: expression, type };
20761
20896
  }
20897
+ registerFieldAlias(fieldIdentifier, esFieldName) {
20898
+ this.fieldAliases[fieldIdentifier] = esFieldName;
20899
+ }
20762
20900
  getMetadataByIdsPayload(uuids) {
20763
20901
  return {
20764
20902
  query: {
@@ -20953,7 +21091,7 @@ class ElasticsearchService {
20953
21091
  .filter((fieldname) => !Array.isArray(filters[fieldname]))
20954
21092
  .filter((fieldname) => filters[fieldname] &&
20955
21093
  JSON.stringify(filters[fieldname]) !== '{}')
20956
- .map((fieldname) => `${fieldname}:(${makeQuery(filters[fieldname])})`)
21094
+ .map((fieldname) => `${this.fieldAliases[fieldname] ?? fieldname}:(${makeQuery(filters[fieldname])})`)
20957
21095
  .join(' AND ');
20958
21096
  if (filters['gn-ui-crossFieldFilter']) {
20959
21097
  queryString = `${queryString} AND (${filters['gn-ui-crossFieldFilter']})`;
@@ -20996,7 +21134,18 @@ class ElasticsearchService {
20996
21134
  buildPayloadQuery({ any, ...fieldSearchFilters }, configFilters, uuids, geometry) {
20997
21135
  const must = [];
20998
21136
  const must_not = this.mustNotFilters();
20999
- const should = [];
21137
+ const should = [
21138
+ {
21139
+ constant_score: {
21140
+ filter: {
21141
+ term: {
21142
+ 'cat.keyword': `${RECORD_FLAG_CATEGORY_PREFIX}IS_REFERENCE_DATASET`,
21143
+ },
21144
+ },
21145
+ boost: REFERENCE_DATASET_BOOST,
21146
+ },
21147
+ },
21148
+ ];
21000
21149
  const filter = [this.queryFilterOnValues('isTemplate', 'n')];
21001
21150
  if (any) {
21002
21151
  must.push({
@@ -21021,7 +21170,7 @@ class ElasticsearchService {
21021
21170
  });
21022
21171
  }
21023
21172
  const boostGeometry = spatialFilterExtent
21024
- ? bboxToPolygon(spatialFilterExtent)
21173
+ ? bboxToGeometry(spatialFilterExtent)
21025
21174
  : geometry;
21026
21175
  if (boostGeometry) {
21027
21176
  // boosts applied using the filter geometry:
@@ -21029,15 +21178,19 @@ class ElasticsearchService {
21029
21178
  // * records intersecting the geometry receive a boost of 2
21030
21179
  // * records close to the geometry center receive a boost of 5 (based on the `location` field)
21031
21180
  // * records on the outskirt of the geometry receive a boost of 2.5
21032
- should.push({
21033
- geo_shape: {
21034
- geom: {
21035
- shape: boostGeometry,
21036
- relation: 'within',
21181
+ if (boostGeometry.type === 'Polygon' ||
21182
+ boostGeometry.type === 'MultiPolygon') {
21183
+ should.push({
21184
+ geo_shape: {
21185
+ geom: {
21186
+ shape: boostGeometry,
21187
+ relation: 'within',
21188
+ },
21189
+ boost: 5.0,
21037
21190
  },
21038
- boost: 5.0,
21039
- },
21040
- }, {
21191
+ });
21192
+ }
21193
+ should.push({
21041
21194
  geo_shape: {
21042
21195
  geom: {
21043
21196
  shape: boostGeometry,
@@ -21074,14 +21227,17 @@ class ElasticsearchService {
21074
21227
  getLength(westToCenter) +
21075
21228
  getLength(eastToCenter)) /
21076
21229
  4;
21077
- should.push({
21078
- distance_feature: {
21079
- field: 'location',
21080
- pivot: `${Math.round(cutoffDistance).toFixed(0)}m`,
21081
- origin: center,
21082
- boost: 5.0,
21083
- },
21084
- });
21230
+ const pivot = Math.round(cutoffDistance);
21231
+ if (pivot > 0) {
21232
+ should.push({
21233
+ distance_feature: {
21234
+ field: 'location',
21235
+ pivot: `${pivot.toFixed(0)}m`,
21236
+ origin: center,
21237
+ boost: 5.0,
21238
+ },
21239
+ });
21240
+ }
21085
21241
  }
21086
21242
  return {
21087
21243
  bool: {
@@ -21251,6 +21407,12 @@ class ElasticsearchService {
21251
21407
  order: {
21252
21408
  [`_${aggregation.sort[1]}`]: aggregation.sort[0],
21253
21409
  },
21410
+ ...(aggregation.includeValues && {
21411
+ include: aggregation.includeValues,
21412
+ }),
21413
+ ...(aggregation.excludeValues && {
21414
+ exclude: aggregation.excludeValues,
21415
+ }),
21254
21416
  },
21255
21417
  };
21256
21418
  case 'histogram':
@@ -21352,10 +21514,21 @@ class Gn4Repository {
21352
21514
  this.platformService = inject(PlatformServiceInterface);
21353
21515
  this.gn4LanguagesApi = inject(LanguagesApiService);
21354
21516
  this.settingsService = inject(Gn4SettingsService);
21517
+ this.gn4TagsApi = inject(TagsApiService);
21355
21518
  this.disableDraft = inject(DISABLE_DRAFT, { optional: true }) ?? false;
21356
21519
  this.defaultConverter = inject(DEFAULT_RECORD_CONVERTER);
21357
21520
  this._draftsChanged = new Subject();
21358
21521
  this.draftsChanged$ = this._draftsChanged.asObservable();
21522
+ /*
21523
+ * FLAGS
21524
+ * Note: in GN4 API, categories are named "tags"
21525
+ */
21526
+ this.categoriesIdentifierForFlags = this.gn4TagsApi.getTags().pipe(map$1((categories) => categories.reduce((acc, category) => {
21527
+ if (category.name.startsWith(RECORD_FLAG_CATEGORY_PREFIX)) {
21528
+ acc[category.name.slice(RECORD_FLAG_CATEGORY_PREFIX.length)] = category.id;
21529
+ }
21530
+ return acc;
21531
+ }, {})), shareReplay$1(1));
21359
21532
  }
21360
21533
  search({ filters, fields, offset, limit, sort, filterIds, filterGeometry, }) {
21361
21534
  return this.gn4SearchApi
@@ -21385,42 +21558,16 @@ class Gn4Repository {
21385
21558
  ? this.gn4Mapper.readRecords(records)
21386
21559
  : of(null)));
21387
21560
  }
21388
- mapEmbeddedFeatureCatalog(featureTypes) {
21389
- return {
21390
- featureTypes: featureTypes.map((featureType) => ({
21391
- name: featureType.typeName || '',
21392
- definition: featureType.definition || '',
21393
- attributes: Array.isArray(featureType.attributeTable)
21394
- ? featureType.attributeTable.map((attr) => {
21395
- const values = attr.values
21396
- ?.filter((v) => v.code || v.label)
21397
- .map((v) => ({
21398
- code: v.code,
21399
- label: v.label,
21400
- }));
21401
- return {
21402
- name: attr.name,
21403
- code: attr.code,
21404
- definition: attr.definition,
21405
- type: attr.type,
21406
- ...(values?.length > 0 ? { values } : {}),
21407
- };
21408
- })
21409
- : [],
21410
- })),
21411
- };
21412
- }
21413
- getFeatureCatalog(record, visited = new Set() // prevent looping
21561
+ queryLinkedFeatureCatalog(record, visited = new Set() // prevent looping
21414
21562
  ) {
21415
- if (record.extras?.['featureTypes'] &&
21416
- Array.isArray(record.extras['featureTypes']) &&
21417
- record.extras['featureTypes'].length > 0) {
21418
- return of(this.mapEmbeddedFeatureCatalog(record.extras['featureTypes']));
21563
+ if ('featureTypeDescriptions' in record &&
21564
+ record.featureTypeDescriptions?.length > 0) {
21565
+ return of({ featureTypes: record.featureTypeDescriptions });
21419
21566
  }
21420
21567
  const featureCatalogIdentifier = record.extras['featureCatalogIdentifier'];
21421
21568
  if (featureCatalogIdentifier && !visited.has(featureCatalogIdentifier)) {
21422
21569
  visited.add(featureCatalogIdentifier);
21423
- return this.getRecord(featureCatalogIdentifier).pipe(switchMap((record) => record ? this.getFeatureCatalog(record, visited) : of(null)));
21570
+ return this.getRecord(featureCatalogIdentifier).pipe(switchMap((record) => record ? this.queryLinkedFeatureCatalog(record, visited) : of(null)));
21424
21571
  }
21425
21572
  return of(null);
21426
21573
  }
@@ -21683,6 +21830,35 @@ class Gn4Repository {
21683
21830
  removeRecordFromLocalStorage(recordId) {
21684
21831
  window.localStorage.removeItem(this.getLocalStorageKeyForRecord(recordId));
21685
21832
  }
21833
+ getCategoryIdForFlag(flagName) {
21834
+ return this.categoriesIdentifierForFlags.pipe(map$1((categories) => {
21835
+ const categoryId = categories[flagName];
21836
+ if (categoryId === undefined) {
21837
+ console.warn(`The record flag ${flagName} is not created on GeoNetwork backend; please create a category with the name ${RECORD_FLAG_CATEGORY_PREFIX}${flagName} for this to work.`);
21838
+ return null;
21839
+ }
21840
+ return categoryId;
21841
+ }));
21842
+ }
21843
+ setRecordFlag(uniqueIdentifier, flagName, value) {
21844
+ return this.getCategoryIdForFlag(flagName).pipe(switchMap((categoryId) => {
21845
+ if (categoryId === null)
21846
+ return of();
21847
+ return value
21848
+ ? this.gn4RecordsApi.tagRecord(uniqueIdentifier, [categoryId], false)
21849
+ : this.gn4RecordsApi.deleteTags(uniqueIdentifier, [categoryId]);
21850
+ }));
21851
+ }
21852
+ getRecordFlag(uniqueIdentifier, flagName) {
21853
+ return combineLatest([
21854
+ this.getCategoryIdForFlag(flagName),
21855
+ this.gn4RecordsApi.getRecordTags(uniqueIdentifier),
21856
+ ]).pipe(map$1(([categoryId, tags]) => {
21857
+ if (categoryId === null)
21858
+ return false;
21859
+ return Array.from(tags).some((tag) => tag.id === categoryId);
21860
+ }));
21861
+ }
21686
21862
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: Gn4Repository, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
21687
21863
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: Gn4Repository }); }
21688
21864
  }
@@ -22298,6 +22474,9 @@ class Gn4PlatformService {
22298
22474
  this.me$ = this.disableAuth
22299
22475
  ? of(null)
22300
22476
  : of(true).pipe(switchMap(() => this.meApi.getMe()), switchMap((apiUser) => this.mapper.userFromMeApi(apiUser)), shareReplay$1({ bufferSize: 1, refCount: true }));
22477
+ this.isAdmin$ = this.disableAuth
22478
+ ? of(false)
22479
+ : of(true).pipe(switchMap(() => this.meApi.getMe()), map$1((apiUser) => !!apiUser?.admin), shareReplay$1({ bufferSize: 1, refCount: true }));
22301
22480
  /**
22302
22481
  * A map of already loaded thesauri (groups of keywords); the key is a URI
22303
22482
  * @private
@@ -22333,6 +22512,9 @@ class Gn4PlatformService {
22333
22512
  isAnonymous() {
22334
22513
  return this.isUserAnonymous$;
22335
22514
  }
22515
+ isAdministrator() {
22516
+ return this.isAdmin$;
22517
+ }
22336
22518
  getOrganizations() {
22337
22519
  return undefined;
22338
22520
  }
@@ -23609,15 +23791,15 @@ class AutocompleteComponent {
23609
23791
  getExtraClass() {
23610
23792
  if (this.allowSubmit) {
23611
23793
  if (this.enterButton) {
23612
- return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+var(--icon-padding))] inset-y-[--icon-padding]';
23794
+ return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+var(--icon-padding))] top-1/2 -translate-y-1/2';
23613
23795
  }
23614
23796
  else {
23615
- 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))]';
23797
+ 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';
23616
23798
  }
23617
23799
  }
23618
23800
  else {
23619
23801
  if (!this.enterButton) {
23620
- return 'border rounded-lg absolute w-8 h-8 right-2 inset-y-2';
23802
+ return 'border rounded-lg absolute w-8 h-8 right-2 top-1/2 -translate-y-1/2';
23621
23803
  }
23622
23804
  }
23623
23805
  return 'border rounded-lg absolute w-8 h-8';
@@ -23762,7 +23944,7 @@ class AutocompleteComponent {
23762
23944
  provideNgIconsConfig({
23763
23945
  size: '1.75rem',
23764
23946
  }),
23765
- ], viewQueries: [{ propertyName: "triggerRef", first: true, predicate: MatAutocompleteTrigger, descendants: true }, { propertyName: "autocomplete", first: true, predicate: MatAutocomplete, descendants: true }, { propertyName: "inputRef", first: true, predicate: ["searchInput"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<span class=\"w-full inline-block relative\">\n @if (!allowSubmit) {\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary search\"></ng-icon>\n </div>\n }\n <div class=\"flex flex-row\">\n <input\n #searchInput\n type=\"text\"\n class=\"gn-ui-text-input\"\n (input)=\"handleInput($event)\"\n [placeholder]=\"placeholder\"\n [formControl]=\"control\"\n [matAutocomplete]=\"auto\"\n (keyup.enter)=\"handleSearch()\"\n [ngClass]=\"{\n 'text-primary': searchActive && enterButton,\n 'text-gray-900': !searchActive,\n 'px-[--icon-width]': !allowSubmit,\n }\"\n />\n @if (searchInput.value && displayEnterBtn) {\n <gn-ui-button\n type=\"gray\"\n extraClass=\"w-32 h-8 !opacity-100\"\n [ngStyle]=\"{ left: enterBtnPosition + 'px' }\"\n class=\"absolute\"\n disabled=\"true\"\n >\n <ng-icon\n name=\"iconoirLongArrowDownLeft\"\n class=\"!w-4 text-gray-900 font-bold\"\n ></ng-icon>\n <span translate class=\"text-bold text-gray-900 font-bold\">\n Enter to search\n </span>\n </gn-ui-button>\n }\n </div>\n @if (searchInput.value) {\n <gn-ui-button\n type=\"primary\"\n [extraClass]=\"getExtraClass()\"\n data-test=\"clear-btn\"\n aria-label=\"Clear\"\n (buttonClick)=\"clear()\"\n >\n <ng-icon class=\"text-white\" name=\"matClose\"></ng-icon>\n </gn-ui-button>\n }\n @if (allowSubmit) {\n <gn-ui-button\n type=\"light\"\n extraClass=\"border-0 border-l-[1px] border-gray-300 hover:border-gray-500 text-primary hover:text-primary-darkest focus:text-primary-darkest absolute inset-y-[--icon-padding] right-[--icon-padding]\"\n aria-label=\"Trigger search\"\n data-test=\"autocomplete-submit-btn\"\n (buttonClick)=\"handleSearch()\"\n >\n <ng-icon name=\"iconoirSearch\"></ng-icon>\n </gn-ui-button>\n }\n\n @if (error) {\n <gn-ui-popup-alert\n class=\"absolute mt-2 w-full top-[100%] left-0\"\n icon=\"matErrorOutlineOutline\"\n position=\"top\"\n type=\"warning\"\n >\n <span translate>search.autocomplete.error</span>\n {{ error }}\n </gn-ui-popup-alert>\n }\n</span>\n\n<mat-autocomplete\n #auto=\"matAutocomplete\"\n (optionSelected)=\"handleSelection($event)\"\n [displayWith]=\"displayWithFnInternal\"\n>\n @for (suggestion of suggestions$ | async; track suggestion) {\n <mat-option [value]=\"suggestion\" class=\"p-2 suggestion text-start\">\n @if (displayWithTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n displayWithTemplate;\n context: { $implicit: suggestion }\n \"\n ></ng-container>\n } @else {\n {{ displayWithFnInternal(suggestion) }}\n }\n </mat-option>\n }\n</mat-autocomplete>\n", styles: ["span{--icon-padding: var(--gn-ui-text-input-border-size, 2px);--icon-width: calc(var(--gn-ui-text-input-padding, .6em) * 2 + 1.25em)}span>*:not(gn-ui-popup-alert){font-size:var(--gn-ui-text-input-font-size, 1em)}input:placeholder-shown{text-overflow:ellipsis}gn-ui-button{--gn-ui-button-rounded: 0;--gn-ui-button-width: var(--icon-width);--gn-ui-button-padding: 0;font-size:1em}ng-icon.search{margin-top:.6rem;margin-left:.6rem}gn-ui-button:last-of-type{--gn-ui-button-rounded: 0 var(--gn-ui-text-input-rounded, .25em) var(--gn-ui-text-input-rounded, .25em) 0}.mat-mdc-option.suggestion.mat-mdc-option-active{background-color:var(--color-primary-lightest)}\n"], dependencies: [{ kind: "component", type: PopupAlertComponent, selector: "gn-ui-popup-alert", inputs: ["icon", "type", "position"] }, { kind: "ngmodule", type: MatAutocompleteModule }, { kind: "component", type: i1$2.MatAutocomplete, selector: "mat-autocomplete", inputs: ["aria-label", "aria-labelledby", "displayWith", "autoActiveFirstOption", "autoSelectActiveOption", "requireSelection", "panelWidth", "disableRipple", "class", "hideSingleSelectionIndicator"], outputs: ["optionSelected", "opened", "closed", "optionActivated"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i1$2.MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "directive", type: i1$2.MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", inputs: ["matAutocomplete", "matAutocompletePosition", "matAutocompleteConnectedTo", "autocomplete", "matAutocompleteDisabled"], exportAs: ["matAutocompleteTrigger"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
23947
+ ], viewQueries: [{ propertyName: "triggerRef", first: true, predicate: MatAutocompleteTrigger, descendants: true }, { propertyName: "autocomplete", first: true, predicate: MatAutocomplete, descendants: true }, { propertyName: "inputRef", first: true, predicate: ["searchInput"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<span class=\"w-full inline-block relative\">\n @if (!allowSubmit) {\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none flex items-center justify-center\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary\"></ng-icon>\n </div>\n }\n <div class=\"flex flex-row\">\n <input\n #searchInput\n type=\"text\"\n class=\"gn-ui-text-input\"\n (input)=\"handleInput($event)\"\n [placeholder]=\"placeholder\"\n [formControl]=\"control\"\n [matAutocomplete]=\"auto\"\n (keyup.enter)=\"handleSearch()\"\n [ngClass]=\"{\n 'text-primary': searchActive && enterButton,\n 'text-gray-900': !searchActive,\n 'px-[--icon-width]': !allowSubmit,\n }\"\n />\n @if (searchInput.value && displayEnterBtn) {\n <gn-ui-button\n type=\"gray\"\n extraClass=\"w-32 h-8 !opacity-100\"\n [ngStyle]=\"{ left: enterBtnPosition + 'px' }\"\n class=\"absolute\"\n disabled=\"true\"\n >\n <ng-icon\n name=\"iconoirLongArrowDownLeft\"\n class=\"!w-4 text-gray-900 font-bold\"\n ></ng-icon>\n <span translate class=\"text-bold text-gray-900 font-bold\">\n Enter to search\n </span>\n </gn-ui-button>\n }\n </div>\n @if (searchInput.value) {\n <gn-ui-button\n type=\"primary\"\n [extraClass]=\"getExtraClass()\"\n data-test=\"clear-btn\"\n aria-label=\"Clear\"\n (buttonClick)=\"clear()\"\n >\n <ng-icon class=\"text-white\" name=\"matClose\"></ng-icon>\n </gn-ui-button>\n }\n @if (allowSubmit) {\n <gn-ui-button\n type=\"light\"\n extraClass=\"border-0 border-l-[1px] border-gray-300 hover:border-gray-500 text-primary hover:text-primary-darkest focus:text-primary-darkest absolute inset-y-[--icon-padding] right-[--icon-padding]\"\n aria-label=\"Trigger search\"\n data-test=\"autocomplete-submit-btn\"\n (buttonClick)=\"handleSearch()\"\n >\n <ng-icon name=\"iconoirSearch\"></ng-icon>\n </gn-ui-button>\n }\n\n @if (error) {\n <gn-ui-popup-alert\n class=\"absolute mt-2 w-full top-[100%] left-0\"\n icon=\"matErrorOutlineOutline\"\n position=\"top\"\n type=\"warning\"\n >\n <span translate>search.autocomplete.error</span>\n {{ error }}\n </gn-ui-popup-alert>\n }\n</span>\n\n<mat-autocomplete\n #auto=\"matAutocomplete\"\n (optionSelected)=\"handleSelection($event)\"\n [displayWith]=\"displayWithFnInternal\"\n>\n @for (suggestion of suggestions$ | async; track suggestion) {\n <mat-option [value]=\"suggestion\" class=\"p-2 suggestion text-start\">\n @if (displayWithTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n displayWithTemplate;\n context: { $implicit: suggestion }\n \"\n ></ng-container>\n } @else {\n {{ displayWithFnInternal(suggestion) }}\n }\n </mat-option>\n }\n</mat-autocomplete>\n", styles: ["span{--icon-padding: var(--gn-ui-text-input-border-size, 2px);--icon-width: calc(var(--gn-ui-text-input-padding, .6em) * 2 + 1.25em)}span>*:not(gn-ui-popup-alert){font-size:var(--gn-ui-text-input-font-size, 1em)}input:placeholder-shown{text-overflow:ellipsis}gn-ui-button{--gn-ui-button-rounded: 0;--gn-ui-button-width: var(--icon-width);--gn-ui-button-padding: 0;font-size:1em}gn-ui-button:last-of-type{--gn-ui-button-rounded: 0 var(--gn-ui-text-input-rounded, .25em) var(--gn-ui-text-input-rounded, .25em) 0}.mat-mdc-option.suggestion.mat-mdc-option-active{background-color:var(--color-primary-lightest)}\n"], dependencies: [{ kind: "component", type: PopupAlertComponent, selector: "gn-ui-popup-alert", inputs: ["icon", "type", "position"] }, { kind: "ngmodule", type: MatAutocompleteModule }, { kind: "component", type: i1$2.MatAutocomplete, selector: "mat-autocomplete", inputs: ["aria-label", "aria-labelledby", "displayWith", "autoActiveFirstOption", "autoSelectActiveOption", "requireSelection", "panelWidth", "disableRipple", "class", "hideSingleSelectionIndicator"], outputs: ["optionSelected", "opened", "closed", "optionActivated"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i1$2.MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "directive", type: i1$2.MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", inputs: ["matAutocomplete", "matAutocompletePosition", "matAutocompleteConnectedTo", "autocomplete", "matAutocompleteDisabled"], exportAs: ["matAutocompleteTrigger"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
23766
23948
  }
23767
23949
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: AutocompleteComponent, decorators: [{
23768
23950
  type: Component,
@@ -23783,7 +23965,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
23783
23965
  provideNgIconsConfig({
23784
23966
  size: '1.75rem',
23785
23967
  }),
23786
- ], template: "<span class=\"w-full inline-block relative\">\n @if (!allowSubmit) {\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary search\"></ng-icon>\n </div>\n }\n <div class=\"flex flex-row\">\n <input\n #searchInput\n type=\"text\"\n class=\"gn-ui-text-input\"\n (input)=\"handleInput($event)\"\n [placeholder]=\"placeholder\"\n [formControl]=\"control\"\n [matAutocomplete]=\"auto\"\n (keyup.enter)=\"handleSearch()\"\n [ngClass]=\"{\n 'text-primary': searchActive && enterButton,\n 'text-gray-900': !searchActive,\n 'px-[--icon-width]': !allowSubmit,\n }\"\n />\n @if (searchInput.value && displayEnterBtn) {\n <gn-ui-button\n type=\"gray\"\n extraClass=\"w-32 h-8 !opacity-100\"\n [ngStyle]=\"{ left: enterBtnPosition + 'px' }\"\n class=\"absolute\"\n disabled=\"true\"\n >\n <ng-icon\n name=\"iconoirLongArrowDownLeft\"\n class=\"!w-4 text-gray-900 font-bold\"\n ></ng-icon>\n <span translate class=\"text-bold text-gray-900 font-bold\">\n Enter to search\n </span>\n </gn-ui-button>\n }\n </div>\n @if (searchInput.value) {\n <gn-ui-button\n type=\"primary\"\n [extraClass]=\"getExtraClass()\"\n data-test=\"clear-btn\"\n aria-label=\"Clear\"\n (buttonClick)=\"clear()\"\n >\n <ng-icon class=\"text-white\" name=\"matClose\"></ng-icon>\n </gn-ui-button>\n }\n @if (allowSubmit) {\n <gn-ui-button\n type=\"light\"\n extraClass=\"border-0 border-l-[1px] border-gray-300 hover:border-gray-500 text-primary hover:text-primary-darkest focus:text-primary-darkest absolute inset-y-[--icon-padding] right-[--icon-padding]\"\n aria-label=\"Trigger search\"\n data-test=\"autocomplete-submit-btn\"\n (buttonClick)=\"handleSearch()\"\n >\n <ng-icon name=\"iconoirSearch\"></ng-icon>\n </gn-ui-button>\n }\n\n @if (error) {\n <gn-ui-popup-alert\n class=\"absolute mt-2 w-full top-[100%] left-0\"\n icon=\"matErrorOutlineOutline\"\n position=\"top\"\n type=\"warning\"\n >\n <span translate>search.autocomplete.error</span>\n {{ error }}\n </gn-ui-popup-alert>\n }\n</span>\n\n<mat-autocomplete\n #auto=\"matAutocomplete\"\n (optionSelected)=\"handleSelection($event)\"\n [displayWith]=\"displayWithFnInternal\"\n>\n @for (suggestion of suggestions$ | async; track suggestion) {\n <mat-option [value]=\"suggestion\" class=\"p-2 suggestion text-start\">\n @if (displayWithTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n displayWithTemplate;\n context: { $implicit: suggestion }\n \"\n ></ng-container>\n } @else {\n {{ displayWithFnInternal(suggestion) }}\n }\n </mat-option>\n }\n</mat-autocomplete>\n", styles: ["span{--icon-padding: var(--gn-ui-text-input-border-size, 2px);--icon-width: calc(var(--gn-ui-text-input-padding, .6em) * 2 + 1.25em)}span>*:not(gn-ui-popup-alert){font-size:var(--gn-ui-text-input-font-size, 1em)}input:placeholder-shown{text-overflow:ellipsis}gn-ui-button{--gn-ui-button-rounded: 0;--gn-ui-button-width: var(--icon-width);--gn-ui-button-padding: 0;font-size:1em}ng-icon.search{margin-top:.6rem;margin-left:.6rem}gn-ui-button:last-of-type{--gn-ui-button-rounded: 0 var(--gn-ui-text-input-rounded, .25em) var(--gn-ui-text-input-rounded, .25em) 0}.mat-mdc-option.suggestion.mat-mdc-option-active{background-color:var(--color-primary-lightest)}\n"] }]
23968
+ ], template: "<span class=\"w-full inline-block relative\">\n @if (!allowSubmit) {\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none flex items-center justify-center\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary\"></ng-icon>\n </div>\n }\n <div class=\"flex flex-row\">\n <input\n #searchInput\n type=\"text\"\n class=\"gn-ui-text-input\"\n (input)=\"handleInput($event)\"\n [placeholder]=\"placeholder\"\n [formControl]=\"control\"\n [matAutocomplete]=\"auto\"\n (keyup.enter)=\"handleSearch()\"\n [ngClass]=\"{\n 'text-primary': searchActive && enterButton,\n 'text-gray-900': !searchActive,\n 'px-[--icon-width]': !allowSubmit,\n }\"\n />\n @if (searchInput.value && displayEnterBtn) {\n <gn-ui-button\n type=\"gray\"\n extraClass=\"w-32 h-8 !opacity-100\"\n [ngStyle]=\"{ left: enterBtnPosition + 'px' }\"\n class=\"absolute\"\n disabled=\"true\"\n >\n <ng-icon\n name=\"iconoirLongArrowDownLeft\"\n class=\"!w-4 text-gray-900 font-bold\"\n ></ng-icon>\n <span translate class=\"text-bold text-gray-900 font-bold\">\n Enter to search\n </span>\n </gn-ui-button>\n }\n </div>\n @if (searchInput.value) {\n <gn-ui-button\n type=\"primary\"\n [extraClass]=\"getExtraClass()\"\n data-test=\"clear-btn\"\n aria-label=\"Clear\"\n (buttonClick)=\"clear()\"\n >\n <ng-icon class=\"text-white\" name=\"matClose\"></ng-icon>\n </gn-ui-button>\n }\n @if (allowSubmit) {\n <gn-ui-button\n type=\"light\"\n extraClass=\"border-0 border-l-[1px] border-gray-300 hover:border-gray-500 text-primary hover:text-primary-darkest focus:text-primary-darkest absolute inset-y-[--icon-padding] right-[--icon-padding]\"\n aria-label=\"Trigger search\"\n data-test=\"autocomplete-submit-btn\"\n (buttonClick)=\"handleSearch()\"\n >\n <ng-icon name=\"iconoirSearch\"></ng-icon>\n </gn-ui-button>\n }\n\n @if (error) {\n <gn-ui-popup-alert\n class=\"absolute mt-2 w-full top-[100%] left-0\"\n icon=\"matErrorOutlineOutline\"\n position=\"top\"\n type=\"warning\"\n >\n <span translate>search.autocomplete.error</span>\n {{ error }}\n </gn-ui-popup-alert>\n }\n</span>\n\n<mat-autocomplete\n #auto=\"matAutocomplete\"\n (optionSelected)=\"handleSelection($event)\"\n [displayWith]=\"displayWithFnInternal\"\n>\n @for (suggestion of suggestions$ | async; track suggestion) {\n <mat-option [value]=\"suggestion\" class=\"p-2 suggestion text-start\">\n @if (displayWithTemplate) {\n <ng-container\n *ngTemplateOutlet=\"\n displayWithTemplate;\n context: { $implicit: suggestion }\n \"\n ></ng-container>\n } @else {\n {{ displayWithFnInternal(suggestion) }}\n }\n </mat-option>\n }\n</mat-autocomplete>\n", styles: ["span{--icon-padding: var(--gn-ui-text-input-border-size, 2px);--icon-width: calc(var(--gn-ui-text-input-padding, .6em) * 2 + 1.25em)}span>*:not(gn-ui-popup-alert){font-size:var(--gn-ui-text-input-font-size, 1em)}input:placeholder-shown{text-overflow:ellipsis}gn-ui-button{--gn-ui-button-rounded: 0;--gn-ui-button-width: var(--icon-width);--gn-ui-button-padding: 0;font-size:1em}gn-ui-button:last-of-type{--gn-ui-button-rounded: 0 var(--gn-ui-text-input-rounded, .25em) var(--gn-ui-text-input-rounded, .25em) 0}.mat-mdc-option.suggestion.mat-mdc-option-active{background-color:var(--color-primary-lightest)}\n"] }]
23787
23969
  }], propDecorators: { placeholder: [{
23788
23970
  type: Input
23789
23971
  }], enterButton: [{
@@ -24961,11 +25143,11 @@ class InlineFilterComponent {
24961
25143
  this.selectValues.emit(this.selected);
24962
25144
  }
24963
25145
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: InlineFilterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
24964
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: InlineFilterComponent, isStandalone: true, selector: "gn-ui-inline-filter", inputs: { choices: "choices", selected: "selected" }, outputs: { selectValues: "selectValues" }, queries: [{ propertyName: "itemTemplate", first: true, predicate: TemplateRef, descendants: true }], ngImport: i0, template: "<ul class=\"flex flex-wrap list-none gap-2\">\n @for (choice of choices; track choice) {\n <li>\n <label\n class=\"\"\n [ngClass]=\"{\n selected: isSelected(choice),\n }\"\n >\n <input\n class=\"hidden\"\n type=\"checkbox\"\n #checkBox\n [checked]=\"isSelected(choice)\"\n (change)=\"select(choice, checkBox.checked)\"\n [attr.data-cy]=\"'inlineFilter-' + choice.value\"\n />\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: choice }\"\n >\n </ng-container>\n </label>\n </li>\n }\n</ul>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] }); }
25146
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: InlineFilterComponent, isStandalone: true, selector: "gn-ui-inline-filter", inputs: { choices: "choices", selected: "selected" }, outputs: { selectValues: "selectValues" }, queries: [{ propertyName: "itemTemplate", first: true, predicate: TemplateRef, descendants: true }], ngImport: i0, template: "<ul class=\"flex flex-wrap list-none gap-2\">\n @for (choice of choices; track choice) {\n <li>\n <button\n type=\"button\"\n [ngClass]=\"{\n selected: isSelected(choice),\n }\"\n [attr.aria-pressed]=\"isSelected(choice)\"\n [attr.data-cy]=\"'inlineFilter-' + choice.value\"\n (click)=\"select(choice, !isSelected(choice))\"\n >\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: choice }\"\n >\n </ng-container>\n </button>\n </li>\n }\n</ul>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] }); }
24965
25147
  }
24966
25148
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: InlineFilterComponent, decorators: [{
24967
25149
  type: Component,
24968
- args: [{ selector: 'gn-ui-inline-filter', standalone: true, imports: [CommonModule], template: "<ul class=\"flex flex-wrap list-none gap-2\">\n @for (choice of choices; track choice) {\n <li>\n <label\n class=\"\"\n [ngClass]=\"{\n selected: isSelected(choice),\n }\"\n >\n <input\n class=\"hidden\"\n type=\"checkbox\"\n #checkBox\n [checked]=\"isSelected(choice)\"\n (change)=\"select(choice, checkBox.checked)\"\n [attr.data-cy]=\"'inlineFilter-' + choice.value\"\n />\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: choice }\"\n >\n </ng-container>\n </label>\n </li>\n }\n</ul>\n" }]
25150
+ args: [{ selector: 'gn-ui-inline-filter', standalone: true, imports: [CommonModule], template: "<ul class=\"flex flex-wrap list-none gap-2\">\n @for (choice of choices; track choice) {\n <li>\n <button\n type=\"button\"\n [ngClass]=\"{\n selected: isSelected(choice),\n }\"\n [attr.aria-pressed]=\"isSelected(choice)\"\n [attr.data-cy]=\"'inlineFilter-' + choice.value\"\n (click)=\"select(choice, !isSelected(choice))\"\n >\n <ng-container\n *ngTemplateOutlet=\"itemTemplate; context: { $implicit: choice }\"\n >\n </ng-container>\n </button>\n </li>\n }\n</ul>\n" }]
24969
25151
  }], propDecorators: { choices: [{
24970
25152
  type: Input
24971
25153
  }], selected: [{
@@ -25259,7 +25441,8 @@ class SearchFeatureCatalogComponent {
25259
25441
  const filtered = (this.featureCatalog?.featureTypes || []).filter((featureType) => {
25260
25442
  const fuzzyFilter = createFuzzyFilter(searchTerm);
25261
25443
  return (fuzzyFilter(featureType.name) ||
25262
- (featureType.definition && fuzzyFilter(featureType.definition)));
25444
+ (featureType.description &&
25445
+ fuzzyFilter(featureType.description)));
25263
25446
  });
25264
25447
  this.filteredFeatureCatalog = {
25265
25448
  ...this.featureCatalog,
@@ -25347,6 +25530,8 @@ marker('search.filters.spatialExtent.error.title');
25347
25530
  marker('search.filters.spatialExtent.error.outOfBounds');
25348
25531
  const LABEL_FROM_FILE = marker('search.filters.spatialExtent.bboxFromFile');
25349
25532
  const LABEL_FROM_FILE_DELETE = marker('search.filters.spatialExtent.bboxFromFileDelete');
25533
+ const LABEL_FROM_LOCATION = marker('search.filters.spatialExtent.bboxFromLocation');
25534
+ const LABEL_FROM_LOCATION_DELETE = marker('search.filters.spatialExtent.bboxFromLocationDelete');
25350
25535
  const LABEL_INITIAL = marker('search.filters.spatialExtent.bboxInitial');
25351
25536
  const LABEL_INITIAL_DELETE = marker('search.filters.spatialExtent.bboxInitialDelete');
25352
25537
  class SpatialExtentDropdownComponent {
@@ -25358,6 +25543,7 @@ class SpatialExtentDropdownComponent {
25358
25543
  this.errorChange = new EventEmitter();
25359
25544
  this.bbox = null;
25360
25545
  this.fileName = '';
25546
+ this.locationName = '';
25361
25547
  this.overlayPositions = [
25362
25548
  {
25363
25549
  originX: 'start',
@@ -25388,13 +25574,21 @@ class SpatialExtentDropdownComponent {
25388
25574
  return !!this.bbox;
25389
25575
  }
25390
25576
  get selectionLabelKey() {
25391
- return this.fileName ? LABEL_FROM_FILE : LABEL_INITIAL;
25577
+ if (this.fileName)
25578
+ return LABEL_FROM_FILE;
25579
+ if (this.locationName)
25580
+ return LABEL_FROM_LOCATION;
25581
+ return LABEL_INITIAL;
25392
25582
  }
25393
25583
  get selectionDeleteLabelKey() {
25394
- return this.fileName ? LABEL_FROM_FILE_DELETE : LABEL_INITIAL_DELETE;
25584
+ if (this.fileName)
25585
+ return LABEL_FROM_FILE_DELETE;
25586
+ if (this.locationName)
25587
+ return LABEL_FROM_LOCATION_DELETE;
25588
+ return LABEL_INITIAL_DELETE;
25395
25589
  }
25396
25590
  get selectionLabelParams() {
25397
- return { fileName: this.fileName };
25591
+ return { fileName: this.fileName, locationName: this.locationName };
25398
25592
  }
25399
25593
  openOverlay() {
25400
25594
  this.overlayMinWidth =
@@ -25431,6 +25625,7 @@ class SpatialExtentDropdownComponent {
25431
25625
  }
25432
25626
  this.bbox = bbox;
25433
25627
  this.fileName = file.name;
25628
+ this.locationName = '';
25434
25629
  this.bboxChange.emit(bbox);
25435
25630
  this.cd.markForCheck();
25436
25631
  }
@@ -25439,6 +25634,15 @@ class SpatialExtentDropdownComponent {
25439
25634
  return;
25440
25635
  }
25441
25636
  }
25637
+ setLocationBbox(bbox, name) {
25638
+ this.errorKey = null;
25639
+ this.bbox = bbox;
25640
+ this.locationName = name;
25641
+ this.fileName = '';
25642
+ this.fileInput?.clear();
25643
+ this.bboxChange.emit(bbox);
25644
+ this.cd.markForCheck();
25645
+ }
25442
25646
  handleFileError(error) {
25443
25647
  if (error === 'file-too-large') {
25444
25648
  this.setError(marker('search.filters.spatialExtent.error.fileTooLarge'), {
@@ -25457,6 +25661,7 @@ class SpatialExtentDropdownComponent {
25457
25661
  removeSelection(event) {
25458
25662
  this.bbox = null;
25459
25663
  this.fileName = '';
25664
+ this.locationName = '';
25460
25665
  this.errorKey = null;
25461
25666
  this.fileInput?.clear();
25462
25667
  this.bboxChange.emit(null);
@@ -25473,7 +25678,7 @@ class SpatialExtentDropdownComponent {
25473
25678
  matExpandLess,
25474
25679
  matExpandMore,
25475
25680
  }),
25476
- ], viewQueries: [{ propertyName: "overlayOrigin", first: true, predicate: ["overlayOrigin"], descendants: true }, { propertyName: "overlay", first: true, predicate: CdkConnectedOverlay, descendants: true }, { propertyName: "fileInput", first: true, predicate: DragAndDropFileInputComponent, descendants: true }], ngImport: i0, template: "<gn-ui-button\n type=\"outline\"\n extraClass=\"bg-background w-full !p-[8px] !pl-[16px]\"\n [title]=\"title\"\n (buttonClick)=\"toggleOverlay()\"\n cdkOverlayOrigin\n #overlayOrigin=\"cdkOverlayOrigin\"\n>\n <div class=\"grow flex items-center mr-2 gap-2 overflow-hidden\">\n <div class=\"text-left font-medium truncate py-1\">\n {{ title }}\n </div>\n @if (hasSelection) {\n <div\n class=\"bg-primary-lighter text-white shrink-0 rounded-full font-bold text-[12px] w-[22px] h-[22px] flex items-center justify-center\"\n >\n 1\n </div>\n }\n </div>\n <button class=\"h-6 w-6 flex items-center\" data-cy=\"clearSelection\">\n @if (hasSelection && !overlayOpen) {\n <ng-icon\n class=\"shrink-0 opacity-40 mr-1.5 hover:opacity-80 transition-colors clear-btn\"\n (click)=\"removeSelection($event)\"\n name=\"matClose\"\n ></ng-icon>\n }\n </button>\n <ng-icon\n [name]=\"overlayOpen ? 'matExpandLess' : 'matExpandMore'\"\n class=\"shrink-0 opacity-40\"\n >\n </ng-icon>\n</gn-ui-button>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayHasBackdrop\n cdkConnectedOverlayBackdropClass=\"cdk-overlay-transparent-backdrop\"\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"overlayOpen\"\n [cdkConnectedOverlayPositions]=\"overlayPositions\"\n [cdkConnectedOverlayScrollStrategy]=\"scrollStrategy\"\n [cdkConnectedOverlayFlexibleDimensions]=\"true\"\n (overlayOutsideClick)=\"closeOverlay()\"\n (detach)=\"closeOverlay()\"\n>\n <div\n class=\"bg-white border border-gray-400 rounded shadow-lg pt-[12px] px-[16px] overlay-container w-[280px] flex flex-col gap-2\"\n [style.min-width]=\"overlayMinWidth\"\n >\n <div class=\"text-xs text-black\">\n {{ 'search.filters.spatialExtent.helpText' | translate }}\n </div>\n\n <div\n [class]=\"\n (hasSelection\n ? 'border-b-[1px] border-gray-400 pb-[20px]'\n : 'pb-[12px]') + ' text-black'\n \"\n >\n <gn-ui-drag-and-drop-file-input\n accept=\".json,.geojson\"\n [placeholder]=\"'search.filters.spatialExtent.import' | translate\"\n [maxFileSizeMb]=\"maxFileSizeMb\"\n [showFileName]=\"false\"\n textClass=\"text-black truncate\"\n dropzoneBackgroundColor=\"transparent\"\n icon=\"iconoirUpload\"\n extraClass=\"gn-ui-gray-outline-input w-full !h-[32px] px-[8px] py-[4px] justify-between\"\n (fileChange)=\"handleFileSelected($event)\"\n (errorChange)=\"handleFileError($event)\"\n data-cy=\"importGeojson\"\n ></gn-ui-drag-and-drop-file-input>\n </div>\n\n @if (hasSelection) {\n <gn-ui-button\n [type]=\"'primary-light'\"\n [title]=\"selectionDeleteLabelKey | translate: selectionLabelParams\"\n (buttonClick)=\"removeSelection($event)\"\n extraClass=\"group gap-x-2 w-full h-[28px] px-[8px] py-[4px] mb-[12px] bg-primary-lighter text-white\"\n data-test=\"spatial-extent-selected-item\"\n >\n <ng-icon\n name=\"iconoirSquareDashed\"\n class=\"shrink-0\"\n size=\"15px\"\n ></ng-icon>\n <span class=\"group-hover:hidden truncate text-sm m-auto\">\n {{ selectionLabelKey | translate: selectionLabelParams }}\n </span>\n <span class=\"hidden group-hover:block truncate text-sm m-auto\">\n {{ selectionDeleteLabelKey | translate: selectionLabelParams }}\n </span>\n <ng-icon\n name=\"iconoirCheckCircle\"\n class=\"group-hover:hidden shrink-0\"\n size=\"14px\"\n ></ng-icon>\n <ng-icon\n name=\"iconoirTrash\"\n class=\"!hidden group-hover:!block shrink-0\"\n size=\"15px\"\n ></ng-icon>\n </gn-ui-button>\n }\n </div>\n</ng-template>\n", styles: [""], dependencies: [{ kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "ngmodule", type: OverlayModule }, { kind: "directive", type: i1$7.CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: ["cdkConnectedOverlayOrigin", "cdkConnectedOverlayPositions", "cdkConnectedOverlayPositionStrategy", "cdkConnectedOverlayOffsetX", "cdkConnectedOverlayOffsetY", "cdkConnectedOverlayWidth", "cdkConnectedOverlayHeight", "cdkConnectedOverlayMinWidth", "cdkConnectedOverlayMinHeight", "cdkConnectedOverlayBackdropClass", "cdkConnectedOverlayPanelClass", "cdkConnectedOverlayViewportMargin", "cdkConnectedOverlayScrollStrategy", "cdkConnectedOverlayOpen", "cdkConnectedOverlayDisableClose", "cdkConnectedOverlayTransformOriginOn", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayLockPosition", "cdkConnectedOverlayFlexibleDimensions", "cdkConnectedOverlayGrowAfterOpen", "cdkConnectedOverlayPush", "cdkConnectedOverlayDisposeOnNavigation"], outputs: ["backdropClick", "positionChange", "attach", "detach", "overlayKeydown", "overlayOutsideClick"], exportAs: ["cdkConnectedOverlay"] }, { kind: "directive", type: i1$7.CdkOverlayOrigin, selector: "[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]", exportAs: ["cdkOverlayOrigin"] }, { kind: "component", type: DragAndDropFileInputComponent, selector: "gn-ui-drag-and-drop-file-input", inputs: ["placeholder", "accept", "maxFileSizeMb", "icon", "dropzoneBackgroundColor", "textClass", "extraClass", "showFileName"], outputs: ["fileChange", "errorChange"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
25681
+ ], viewQueries: [{ propertyName: "overlayOrigin", first: true, predicate: ["overlayOrigin"], descendants: true }, { propertyName: "overlay", first: true, predicate: CdkConnectedOverlay, descendants: true }, { propertyName: "fileInput", first: true, predicate: DragAndDropFileInputComponent, descendants: true }], ngImport: i0, template: "<gn-ui-button\n type=\"outline\"\n extraClass=\"bg-background w-full !p-[8px] !pl-[16px]\"\n [title]=\"title\"\n (buttonClick)=\"toggleOverlay()\"\n cdkOverlayOrigin\n #overlayOrigin=\"cdkOverlayOrigin\"\n>\n <div class=\"grow flex items-center mr-2 gap-2 overflow-hidden\">\n <div class=\"text-left font-medium truncate py-1\">\n {{ title }}\n </div>\n @if (hasSelection) {\n <div\n class=\"bg-primary-lighter text-white shrink-0 rounded-full font-bold text-[12px] w-[22px] h-[22px] flex items-center justify-center\"\n >\n 1\n </div>\n }\n </div>\n <button class=\"h-6 w-6 flex items-center\" data-cy=\"clearSelection\">\n @if (hasSelection && !overlayOpen) {\n <ng-icon\n class=\"shrink-0 opacity-40 mr-1.5 hover:opacity-80 transition-colors clear-btn\"\n (click)=\"removeSelection($event)\"\n name=\"matClose\"\n ></ng-icon>\n }\n </button>\n <ng-icon\n [name]=\"overlayOpen ? 'matExpandLess' : 'matExpandMore'\"\n class=\"shrink-0 opacity-40\"\n >\n </ng-icon>\n</gn-ui-button>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayHasBackdrop\n cdkConnectedOverlayBackdropClass=\"cdk-overlay-transparent-backdrop\"\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"overlayOpen\"\n [cdkConnectedOverlayPositions]=\"overlayPositions\"\n [cdkConnectedOverlayScrollStrategy]=\"scrollStrategy\"\n [cdkConnectedOverlayFlexibleDimensions]=\"true\"\n (overlayOutsideClick)=\"closeOverlay()\"\n (detach)=\"closeOverlay()\"\n>\n <div\n class=\"bg-white border border-gray-400 rounded shadow-lg pt-[12px] px-[16px] overlay-container w-[280px] flex flex-col gap-2\"\n [style.min-width]=\"overlayMinWidth\"\n >\n <div class=\"text-xs text-black\">\n {{ 'search.filters.spatialExtent.helpText' | translate }}\n </div>\n\n <div\n [class]=\"\n (hasSelection\n ? 'border-b-[1px] border-gray-400 pb-[20px]'\n : 'pb-[12px]') + ' text-black flex flex-col gap-[8px]'\n \"\n style=\"\n --gn-ui-text-input-rounded: 8px;\n --gn-ui-text-input-border-size: 1px;\n --gn-ui-text-input-padding: 6px;\n \"\n >\n <gn-ui-drag-and-drop-file-input\n accept=\".json,.geojson\"\n [placeholder]=\"'search.filters.spatialExtent.import' | translate\"\n [maxFileSizeMb]=\"maxFileSizeMb\"\n [showFileName]=\"false\"\n textClass=\"text-black truncate\"\n dropzoneBackgroundColor=\"transparent\"\n icon=\"iconoirUpload\"\n extraClass=\"gn-ui-gray-outline-input w-full !h-[32px] px-[8px] py-[4px] justify-between\"\n (fileChange)=\"handleFileSelected($event)\"\n (errorChange)=\"handleFileError($event)\"\n data-cy=\"importGeojson\"\n ></gn-ui-drag-and-drop-file-input>\n <ng-content></ng-content>\n </div>\n\n @if (hasSelection) {\n <gn-ui-button\n [type]=\"'primary-light'\"\n [title]=\"selectionDeleteLabelKey | translate: selectionLabelParams\"\n (buttonClick)=\"removeSelection($event)\"\n extraClass=\"group gap-x-2 w-full h-[28px] px-[8px] py-[4px] mb-[12px] bg-primary-lighter text-white\"\n data-test=\"spatial-extent-selected-item\"\n >\n <ng-icon\n name=\"iconoirSquareDashed\"\n class=\"shrink-0\"\n size=\"15px\"\n ></ng-icon>\n <span class=\"group-hover:hidden truncate text-sm m-auto\">\n {{ selectionLabelKey | translate: selectionLabelParams }}\n </span>\n <span class=\"hidden group-hover:block truncate text-sm m-auto\">\n {{ selectionDeleteLabelKey | translate: selectionLabelParams }}\n </span>\n <ng-icon\n name=\"iconoirCheckCircle\"\n class=\"group-hover:hidden shrink-0\"\n size=\"14px\"\n ></ng-icon>\n <ng-icon\n name=\"iconoirTrash\"\n class=\"!hidden group-hover:!block shrink-0\"\n size=\"15px\"\n ></ng-icon>\n </gn-ui-button>\n }\n </div>\n</ng-template>\n", styles: [""], dependencies: [{ kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "ngmodule", type: OverlayModule }, { kind: "directive", type: i1$7.CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: ["cdkConnectedOverlayOrigin", "cdkConnectedOverlayPositions", "cdkConnectedOverlayPositionStrategy", "cdkConnectedOverlayOffsetX", "cdkConnectedOverlayOffsetY", "cdkConnectedOverlayWidth", "cdkConnectedOverlayHeight", "cdkConnectedOverlayMinWidth", "cdkConnectedOverlayMinHeight", "cdkConnectedOverlayBackdropClass", "cdkConnectedOverlayPanelClass", "cdkConnectedOverlayViewportMargin", "cdkConnectedOverlayScrollStrategy", "cdkConnectedOverlayOpen", "cdkConnectedOverlayDisableClose", "cdkConnectedOverlayTransformOriginOn", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayLockPosition", "cdkConnectedOverlayFlexibleDimensions", "cdkConnectedOverlayGrowAfterOpen", "cdkConnectedOverlayPush", "cdkConnectedOverlayDisposeOnNavigation"], outputs: ["backdropClick", "positionChange", "attach", "detach", "overlayKeydown", "overlayOutsideClick"], exportAs: ["cdkConnectedOverlay"] }, { kind: "directive", type: i1$7.CdkOverlayOrigin, selector: "[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]", exportAs: ["cdkOverlayOrigin"] }, { kind: "component", type: DragAndDropFileInputComponent, selector: "gn-ui-drag-and-drop-file-input", inputs: ["placeholder", "accept", "maxFileSizeMb", "icon", "dropzoneBackgroundColor", "textClass", "extraClass", "showFileName"], outputs: ["fileChange", "errorChange"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
25477
25682
  }
25478
25683
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: SpatialExtentDropdownComponent, decorators: [{
25479
25684
  type: Component,
@@ -25493,7 +25698,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
25493
25698
  matExpandLess,
25494
25699
  matExpandMore,
25495
25700
  }),
25496
- ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<gn-ui-button\n type=\"outline\"\n extraClass=\"bg-background w-full !p-[8px] !pl-[16px]\"\n [title]=\"title\"\n (buttonClick)=\"toggleOverlay()\"\n cdkOverlayOrigin\n #overlayOrigin=\"cdkOverlayOrigin\"\n>\n <div class=\"grow flex items-center mr-2 gap-2 overflow-hidden\">\n <div class=\"text-left font-medium truncate py-1\">\n {{ title }}\n </div>\n @if (hasSelection) {\n <div\n class=\"bg-primary-lighter text-white shrink-0 rounded-full font-bold text-[12px] w-[22px] h-[22px] flex items-center justify-center\"\n >\n 1\n </div>\n }\n </div>\n <button class=\"h-6 w-6 flex items-center\" data-cy=\"clearSelection\">\n @if (hasSelection && !overlayOpen) {\n <ng-icon\n class=\"shrink-0 opacity-40 mr-1.5 hover:opacity-80 transition-colors clear-btn\"\n (click)=\"removeSelection($event)\"\n name=\"matClose\"\n ></ng-icon>\n }\n </button>\n <ng-icon\n [name]=\"overlayOpen ? 'matExpandLess' : 'matExpandMore'\"\n class=\"shrink-0 opacity-40\"\n >\n </ng-icon>\n</gn-ui-button>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayHasBackdrop\n cdkConnectedOverlayBackdropClass=\"cdk-overlay-transparent-backdrop\"\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"overlayOpen\"\n [cdkConnectedOverlayPositions]=\"overlayPositions\"\n [cdkConnectedOverlayScrollStrategy]=\"scrollStrategy\"\n [cdkConnectedOverlayFlexibleDimensions]=\"true\"\n (overlayOutsideClick)=\"closeOverlay()\"\n (detach)=\"closeOverlay()\"\n>\n <div\n class=\"bg-white border border-gray-400 rounded shadow-lg pt-[12px] px-[16px] overlay-container w-[280px] flex flex-col gap-2\"\n [style.min-width]=\"overlayMinWidth\"\n >\n <div class=\"text-xs text-black\">\n {{ 'search.filters.spatialExtent.helpText' | translate }}\n </div>\n\n <div\n [class]=\"\n (hasSelection\n ? 'border-b-[1px] border-gray-400 pb-[20px]'\n : 'pb-[12px]') + ' text-black'\n \"\n >\n <gn-ui-drag-and-drop-file-input\n accept=\".json,.geojson\"\n [placeholder]=\"'search.filters.spatialExtent.import' | translate\"\n [maxFileSizeMb]=\"maxFileSizeMb\"\n [showFileName]=\"false\"\n textClass=\"text-black truncate\"\n dropzoneBackgroundColor=\"transparent\"\n icon=\"iconoirUpload\"\n extraClass=\"gn-ui-gray-outline-input w-full !h-[32px] px-[8px] py-[4px] justify-between\"\n (fileChange)=\"handleFileSelected($event)\"\n (errorChange)=\"handleFileError($event)\"\n data-cy=\"importGeojson\"\n ></gn-ui-drag-and-drop-file-input>\n </div>\n\n @if (hasSelection) {\n <gn-ui-button\n [type]=\"'primary-light'\"\n [title]=\"selectionDeleteLabelKey | translate: selectionLabelParams\"\n (buttonClick)=\"removeSelection($event)\"\n extraClass=\"group gap-x-2 w-full h-[28px] px-[8px] py-[4px] mb-[12px] bg-primary-lighter text-white\"\n data-test=\"spatial-extent-selected-item\"\n >\n <ng-icon\n name=\"iconoirSquareDashed\"\n class=\"shrink-0\"\n size=\"15px\"\n ></ng-icon>\n <span class=\"group-hover:hidden truncate text-sm m-auto\">\n {{ selectionLabelKey | translate: selectionLabelParams }}\n </span>\n <span class=\"hidden group-hover:block truncate text-sm m-auto\">\n {{ selectionDeleteLabelKey | translate: selectionLabelParams }}\n </span>\n <ng-icon\n name=\"iconoirCheckCircle\"\n class=\"group-hover:hidden shrink-0\"\n size=\"14px\"\n ></ng-icon>\n <ng-icon\n name=\"iconoirTrash\"\n class=\"!hidden group-hover:!block shrink-0\"\n size=\"15px\"\n ></ng-icon>\n </gn-ui-button>\n }\n </div>\n</ng-template>\n" }]
25701
+ ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<gn-ui-button\n type=\"outline\"\n extraClass=\"bg-background w-full !p-[8px] !pl-[16px]\"\n [title]=\"title\"\n (buttonClick)=\"toggleOverlay()\"\n cdkOverlayOrigin\n #overlayOrigin=\"cdkOverlayOrigin\"\n>\n <div class=\"grow flex items-center mr-2 gap-2 overflow-hidden\">\n <div class=\"text-left font-medium truncate py-1\">\n {{ title }}\n </div>\n @if (hasSelection) {\n <div\n class=\"bg-primary-lighter text-white shrink-0 rounded-full font-bold text-[12px] w-[22px] h-[22px] flex items-center justify-center\"\n >\n 1\n </div>\n }\n </div>\n <button class=\"h-6 w-6 flex items-center\" data-cy=\"clearSelection\">\n @if (hasSelection && !overlayOpen) {\n <ng-icon\n class=\"shrink-0 opacity-40 mr-1.5 hover:opacity-80 transition-colors clear-btn\"\n (click)=\"removeSelection($event)\"\n name=\"matClose\"\n ></ng-icon>\n }\n </button>\n <ng-icon\n [name]=\"overlayOpen ? 'matExpandLess' : 'matExpandMore'\"\n class=\"shrink-0 opacity-40\"\n >\n </ng-icon>\n</gn-ui-button>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayHasBackdrop\n cdkConnectedOverlayBackdropClass=\"cdk-overlay-transparent-backdrop\"\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"overlayOpen\"\n [cdkConnectedOverlayPositions]=\"overlayPositions\"\n [cdkConnectedOverlayScrollStrategy]=\"scrollStrategy\"\n [cdkConnectedOverlayFlexibleDimensions]=\"true\"\n (overlayOutsideClick)=\"closeOverlay()\"\n (detach)=\"closeOverlay()\"\n>\n <div\n class=\"bg-white border border-gray-400 rounded shadow-lg pt-[12px] px-[16px] overlay-container w-[280px] flex flex-col gap-2\"\n [style.min-width]=\"overlayMinWidth\"\n >\n <div class=\"text-xs text-black\">\n {{ 'search.filters.spatialExtent.helpText' | translate }}\n </div>\n\n <div\n [class]=\"\n (hasSelection\n ? 'border-b-[1px] border-gray-400 pb-[20px]'\n : 'pb-[12px]') + ' text-black flex flex-col gap-[8px]'\n \"\n style=\"\n --gn-ui-text-input-rounded: 8px;\n --gn-ui-text-input-border-size: 1px;\n --gn-ui-text-input-padding: 6px;\n \"\n >\n <gn-ui-drag-and-drop-file-input\n accept=\".json,.geojson\"\n [placeholder]=\"'search.filters.spatialExtent.import' | translate\"\n [maxFileSizeMb]=\"maxFileSizeMb\"\n [showFileName]=\"false\"\n textClass=\"text-black truncate\"\n dropzoneBackgroundColor=\"transparent\"\n icon=\"iconoirUpload\"\n extraClass=\"gn-ui-gray-outline-input w-full !h-[32px] px-[8px] py-[4px] justify-between\"\n (fileChange)=\"handleFileSelected($event)\"\n (errorChange)=\"handleFileError($event)\"\n data-cy=\"importGeojson\"\n ></gn-ui-drag-and-drop-file-input>\n <ng-content></ng-content>\n </div>\n\n @if (hasSelection) {\n <gn-ui-button\n [type]=\"'primary-light'\"\n [title]=\"selectionDeleteLabelKey | translate: selectionLabelParams\"\n (buttonClick)=\"removeSelection($event)\"\n extraClass=\"group gap-x-2 w-full h-[28px] px-[8px] py-[4px] mb-[12px] bg-primary-lighter text-white\"\n data-test=\"spatial-extent-selected-item\"\n >\n <ng-icon\n name=\"iconoirSquareDashed\"\n class=\"shrink-0\"\n size=\"15px\"\n ></ng-icon>\n <span class=\"group-hover:hidden truncate text-sm m-auto\">\n {{ selectionLabelKey | translate: selectionLabelParams }}\n </span>\n <span class=\"hidden group-hover:block truncate text-sm m-auto\">\n {{ selectionDeleteLabelKey | translate: selectionLabelParams }}\n </span>\n <ng-icon\n name=\"iconoirCheckCircle\"\n class=\"group-hover:hidden shrink-0\"\n size=\"14px\"\n ></ng-icon>\n <ng-icon\n name=\"iconoirTrash\"\n class=\"!hidden group-hover:!block shrink-0\"\n size=\"15px\"\n ></ng-icon>\n </gn-ui-button>\n }\n </div>\n</ng-template>\n" }]
25497
25702
  }], propDecorators: { title: [{
25498
25703
  type: Input
25499
25704
  }], maxFileSizeMb: [{
@@ -27219,6 +27424,28 @@ const GEOCODING_PROVIDER = new InjectionToken('geocoding-provider', {
27219
27424
  providedIn: 'root',
27220
27425
  factory: () => DEFAULT_GEOCODING_PROVIDER,
27221
27426
  });
27427
+ // these options are arrays in the providers, but they can be configured
27428
+ // with a single value for simplicity
27429
+ const GEOCODING_PROVIDER_ARRAY_OPTIONS = {
27430
+ geoadmin: ['origins', 'features'],
27431
+ geoplateforme: [
27432
+ 'index',
27433
+ 'category',
27434
+ 'type',
27435
+ 'postCode',
27436
+ 'cityCode',
27437
+ 'depCode',
27438
+ ],
27439
+ };
27440
+ function wrapArrayOptions(options, keys) {
27441
+ const wrapped = { ...options };
27442
+ for (const key of keys) {
27443
+ if (typeof wrapped[key] === 'string') {
27444
+ wrapped[key] = [wrapped[key]];
27445
+ }
27446
+ }
27447
+ return wrapped;
27448
+ }
27222
27449
  class GeocodingService {
27223
27450
  constructor() {
27224
27451
  this.provider = inject(GEOCODING_PROVIDER);
@@ -27227,13 +27454,16 @@ class GeocodingService {
27227
27454
  let queryObservable;
27228
27455
  switch (this.provider[0]) {
27229
27456
  case 'geoadmin':
27230
- queryObservable = from(queryGeoadmin(text, this.provider[1]));
27457
+ queryObservable = from(queryGeoadmin(text, wrapArrayOptions(this.provider[1], GEOCODING_PROVIDER_ARRAY_OPTIONS.geoadmin)));
27231
27458
  break;
27232
27459
  case 'geonames':
27233
27460
  queryObservable = from(queryGeonames(text, this.provider[1]));
27234
27461
  break;
27235
27462
  case 'geoplateforme':
27236
- queryObservable = from(queryGeoplateforme(text, this.provider[1]));
27463
+ queryObservable = from(queryGeoplateforme(text, {
27464
+ ...wrapArrayOptions(this.provider[1], GEOCODING_PROVIDER_ARRAY_OPTIONS.geoplateforme),
27465
+ returnTrueGeometry: true,
27466
+ }));
27237
27467
  break;
27238
27468
  default:
27239
27469
  return throwError(() => new Error(`Unsupported geocoding provider: ${this.provider[0]}`));
@@ -27250,29 +27480,80 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
27250
27480
  }]
27251
27481
  }] });
27252
27482
 
27483
+ const GEOCODING_PROVIDER_LABELS = new InjectionToken('geocodingProviderLabels', {
27484
+ factory: () => ({}),
27485
+ });
27253
27486
  class LocationSearchComponent {
27254
27487
  constructor() {
27255
27488
  this.geocodingService = inject(GeocodingService);
27489
+ this.labels = inject(GEOCODING_PROVIDER_LABELS);
27256
27490
  this.placeholder = '';
27257
27491
  this.resultSelected = new EventEmitter();
27492
+ this.bboxSelected = new EventEmitter();
27258
27493
  this.displayWithFn = (item) => item.label;
27259
27494
  this.searchAction = (text) => this.geocodingService.query(text);
27260
27495
  }
27496
+ getSecondaryLabel(result) {
27497
+ return this.resolveLabel(result, this.labels.secondary);
27498
+ }
27499
+ getMainLabel(result) {
27500
+ return this.resolveLabel(result, this.labels.main) ?? result.label;
27501
+ }
27502
+ getTertiaryLabel(result) {
27503
+ return this.resolveLabel(result, this.labels.tertiary);
27504
+ }
27505
+ getDisplayLabel(result) {
27506
+ const tertiary = this.getTertiaryLabel(result);
27507
+ return this.getMainLabel(result) + (tertiary ? ', ' + tertiary : '');
27508
+ }
27509
+ resolveLabel(result, path) {
27510
+ if (!path)
27511
+ return undefined;
27512
+ let value;
27513
+ try {
27514
+ value = pointer.get(result, path);
27515
+ }
27516
+ catch {
27517
+ return undefined;
27518
+ }
27519
+ const values = Array.isArray(value) ? value : [value];
27520
+ const label = values
27521
+ .filter((v) => typeof v === 'string' || typeof v === 'number')
27522
+ .join(', ');
27523
+ return label || undefined;
27524
+ }
27525
+ // geoplateforme keeps a simplified geometry in geom and puts the real one,
27526
+ // as a JSON string, in properties.truegeometry when returnTrueGeometry is set
27527
+ getGeometry(result) {
27528
+ const trueGeometry = result.properties?.['truegeometry'];
27529
+ if (typeof trueGeometry === 'string') {
27530
+ return JSON.parse(trueGeometry);
27531
+ }
27532
+ return trueGeometry ?? result.geom;
27533
+ }
27261
27534
  handleItemSelected(item) {
27262
- this.resultSelected.emit(item);
27535
+ const result = item;
27536
+ this.resultSelected.emit(result);
27537
+ const geometry = this.getGeometry(result);
27538
+ if (geometry) {
27539
+ this.bboxSelected.emit({
27540
+ bbox: getGeometryBoundingBox(geometry),
27541
+ label: this.getDisplayLabel(result),
27542
+ });
27543
+ }
27263
27544
  }
27264
27545
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: LocationSearchComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
27265
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.19", type: LocationSearchComponent, isStandalone: true, selector: "gn-ui-location-search", inputs: { placeholder: "placeholder", displayWithTemplate: "displayWithTemplate" }, outputs: { resultSelected: "resultSelected" }, ngImport: i0, template: "<gn-ui-autocomplete\n [action]=\"searchAction\"\n [displayWithFn]=\"displayWithFn\"\n [placeholder]=\"placeholder\"\n [displayWithTemplate]=\"displayWithTemplate\"\n (itemSelected)=\"handleItemSelected($event)\"\n>\n</gn-ui-autocomplete>\n", dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "enterButton", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithTemplate", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared", "isSearchActive"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
27546
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: LocationSearchComponent, isStandalone: true, selector: "gn-ui-location-search", inputs: { placeholder: "placeholder" }, outputs: { resultSelected: "resultSelected", bboxSelected: "bboxSelected" }, ngImport: i0, template: "<gn-ui-autocomplete\n [action]=\"searchAction\"\n [displayWithFn]=\"displayWithFn\"\n [placeholder]=\"placeholder\"\n [displayWithTemplate]=\"defaultItemTpl\"\n [clearOnSelection]=\"true\"\n (itemSelected)=\"handleItemSelected($event)\"\n>\n</gn-ui-autocomplete>\n\n<ng-template #defaultItemTpl let-result>\n <div class=\"py-2\">\n @if (getSecondaryLabel(result)) {\n <div class=\"gn-ui-card-detail\">{{ getSecondaryLabel(result) }}</div>\n }\n <div class=\"gn-ui-card-title\">{{ getDisplayLabel(result) }}</div>\n </div>\n</ng-template>\n", dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "enterButton", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithTemplate", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared", "isSearchActive"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
27266
27547
  }
27267
27548
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: LocationSearchComponent, decorators: [{
27268
27549
  type: Component,
27269
- args: [{ selector: 'gn-ui-location-search', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [AutocompleteComponent], template: "<gn-ui-autocomplete\n [action]=\"searchAction\"\n [displayWithFn]=\"displayWithFn\"\n [placeholder]=\"placeholder\"\n [displayWithTemplate]=\"displayWithTemplate\"\n (itemSelected)=\"handleItemSelected($event)\"\n>\n</gn-ui-autocomplete>\n" }]
27550
+ args: [{ selector: 'gn-ui-location-search', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [AutocompleteComponent], template: "<gn-ui-autocomplete\n [action]=\"searchAction\"\n [displayWithFn]=\"displayWithFn\"\n [placeholder]=\"placeholder\"\n [displayWithTemplate]=\"defaultItemTpl\"\n [clearOnSelection]=\"true\"\n (itemSelected)=\"handleItemSelected($event)\"\n>\n</gn-ui-autocomplete>\n\n<ng-template #defaultItemTpl let-result>\n <div class=\"py-2\">\n @if (getSecondaryLabel(result)) {\n <div class=\"gn-ui-card-detail\">{{ getSecondaryLabel(result) }}</div>\n }\n <div class=\"gn-ui-card-title\">{{ getDisplayLabel(result) }}</div>\n </div>\n</ng-template>\n" }]
27270
27551
  }], propDecorators: { placeholder: [{
27271
27552
  type: Input
27272
- }], displayWithTemplate: [{
27273
- type: Input
27274
27553
  }], resultSelected: [{
27275
27554
  type: Output
27555
+ }], bboxSelected: [{
27556
+ type: Output
27276
27557
  }] } });
27277
27558
 
27278
27559
  // expects the replacement key ${uuid}
@@ -27433,6 +27714,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
27433
27714
  class AbstractSearchField {
27434
27715
  }
27435
27716
  class SimpleSearchField {
27717
+ get fieldIdentifier() {
27718
+ return this.customIdentifier ?? this.esFieldName;
27719
+ }
27436
27720
  constructor(esFieldName, injector, order = 'asc', orderType = 'key') {
27437
27721
  this.esFieldName = esFieldName;
27438
27722
  this.injector = injector;
@@ -27441,14 +27725,26 @@ class SimpleSearchField {
27441
27725
  this.repository = this.injector.get(RecordsRepositoryInterface);
27442
27726
  // FIXME: this is required to register runtime fields; abstract this as well
27443
27727
  this.esService = this.injector.get(ElasticsearchService);
27728
+ this.includeValues = [];
27729
+ this.excludeValues = [];
27730
+ }
27731
+ setFieldIdentifier(fieldIdentifier) {
27732
+ this.customIdentifier = fieldIdentifier;
27733
+ this.esService.registerFieldAlias(fieldIdentifier, this.esFieldName);
27444
27734
  }
27445
27735
  getAggregations() {
27446
27736
  return {
27447
- [this.esFieldName]: {
27737
+ [this.fieldIdentifier]: {
27448
27738
  type: 'terms',
27449
27739
  field: this.esFieldName,
27450
27740
  limit: 1000,
27451
27741
  sort: [this.order, this.orderType],
27742
+ ...(this.includeValues?.length && {
27743
+ includeValues: this.includeValues,
27744
+ }),
27745
+ ...(this.excludeValues?.length && {
27746
+ excludeValues: this.excludeValues,
27747
+ }),
27452
27748
  },
27453
27749
  };
27454
27750
  }
@@ -27456,7 +27752,7 @@ class SimpleSearchField {
27456
27752
  return bucket.term.toString();
27457
27753
  }
27458
27754
  getAvailableValues() {
27459
- return this.repository.aggregate(this.getAggregations()).pipe(map$1((response) => response[this.esFieldName].buckets || []), switchMap((buckets) => {
27755
+ return this.repository.aggregate(this.getAggregations()).pipe(map$1((response) => response[this.fieldIdentifier].buckets || []), switchMap((buckets) => {
27460
27756
  const bucketPromises = buckets.map(async (bucket) => ({
27461
27757
  label: `${await this.getBucketLabel(bucket)} (${bucket.count})`,
27462
27758
  value: bucket.term.toString(),
@@ -27469,7 +27765,7 @@ class SimpleSearchField {
27469
27765
  // FieldValue[]
27470
27766
  if (this.getType() === 'values') {
27471
27767
  return of({
27472
- [this.esFieldName]: values.reduce((acc, val) => {
27768
+ [this.fieldIdentifier]: values.reduce((acc, val) => {
27473
27769
  const value = val.toString();
27474
27770
  if (value !== '') {
27475
27771
  return { ...acc, [value]: true };
@@ -27480,11 +27776,11 @@ class SimpleSearchField {
27480
27776
  }
27481
27777
  // DateRange
27482
27778
  return of({
27483
- [this.esFieldName]: values[0] !== '' ? values[0] : {},
27779
+ [this.fieldIdentifier]: values[0] !== '' ? values[0] : {},
27484
27780
  });
27485
27781
  }
27486
27782
  getValuesForFilter(filters) {
27487
- const filter = filters[this.esFieldName];
27783
+ const filter = filters[this.fieldIdentifier];
27488
27784
  if (!filter)
27489
27785
  return of([]);
27490
27786
  // filter by expression
@@ -27502,6 +27798,9 @@ class SimpleSearchField {
27502
27798
  getType() {
27503
27799
  return 'values';
27504
27800
  }
27801
+ clone() {
27802
+ return Object.create(this);
27803
+ }
27505
27804
  }
27506
27805
  class TranslatedSearchField extends SimpleSearchField {
27507
27806
  constructor(esFieldName, injector, order = 'asc', orderType = 'key') {
@@ -27535,7 +27834,8 @@ class TranslatedSearchField extends SimpleSearchField {
27535
27834
  class MultilingualSearchField extends SimpleSearchField {
27536
27835
  // we're using a getter in case the token value changes over time
27537
27836
  get searchLanguage() {
27538
- return this.injector.get(METADATA_LANGUAGE, null);
27837
+ const language = this.injector.get(METADATA_LANGUAGE, null);
27838
+ return typeof language === 'function' ? language() : language;
27539
27839
  }
27540
27840
  constructor(esFieldName, injector, order = 'asc', orderType = 'key') {
27541
27841
  super(esFieldName, injector, order, orderType);
@@ -27771,11 +28071,11 @@ class BoundingBoxSearchField extends SimpleSearchField {
27771
28071
  }
27772
28072
  getFiltersForValues(values) {
27773
28073
  return of({
27774
- [this.esFieldName]: values.map(Number),
28074
+ [this.fieldIdentifier]: values.map(Number),
27775
28075
  });
27776
28076
  }
27777
28077
  getValuesForFilter(filters) {
27778
- const filter = filters[this.esFieldName];
28078
+ const filter = filters[this.fieldIdentifier];
27779
28079
  return of(isBoundingBox(filter) ? filter : []);
27780
28080
  }
27781
28081
  getType() {
@@ -27874,7 +28174,7 @@ class RecordKindField extends SimpleSearchField {
27874
28174
  }
27875
28175
  getFiltersForValues(values) {
27876
28176
  const filters = {
27877
- [this.esFieldName]: values.reduce((acc, value) => {
28177
+ [this.fieldIdentifier]: values.reduce((acc, value) => {
27878
28178
  if (value === '')
27879
28179
  return { ...acc, [value]: true };
27880
28180
  const keysToAdd = this.TYPE_MAPPING[value] || [value];
@@ -27897,7 +28197,7 @@ class RecordKindField extends SimpleSearchField {
27897
28197
  return of(filters);
27898
28198
  }
27899
28199
  getValuesForFilter(filters) {
27900
- const filter = filters[this.esFieldName];
28200
+ const filter = filters[this.fieldIdentifier];
27901
28201
  if (!filter)
27902
28202
  return of([]);
27903
28203
  const activeValues = Object.keys(filter).filter((v) => filter[v]);
@@ -27929,10 +28229,13 @@ marker('search.filters.changeDate');
27929
28229
  marker('search.filters.resourceCreationRevisionDate');
27930
28230
  marker('search.filters.temporalExtent');
27931
28231
  marker('search.filters.spatialExtent');
28232
+ marker('search.filters.documentStandard');
28233
+ const CUSTOM_FIELDS = new InjectionToken('custom-fields');
27932
28234
  class FieldsService {
27933
28235
  constructor() {
27934
28236
  this.injector = inject(Injector);
27935
- this.fields = {
28237
+ this.customFields = inject(CUSTOM_FIELDS, { optional: true }) ?? [];
28238
+ this.baseFields = {
27936
28239
  organization: new OrganizationSearchField(this.injector),
27937
28240
  format: new SimpleSearchField('format', this.injector, 'asc'),
27938
28241
  resourceType: new ResourceTypeLegacyField(this.injector), // Deprecated, use `recordKind` instead
@@ -27956,6 +28259,27 @@ class FieldsService {
27956
28259
  availableServices: new AvailableServicesField(this.injector),
27957
28260
  spatialExtent: new BoundingBoxSearchField('spatialExtent', this.injector),
27958
28261
  };
28262
+ this.fields = { ...this.baseFields };
28263
+ for (const customField of this.customFields) {
28264
+ const baseField = this.baseFields[customField.baseFilter];
28265
+ if (!(baseField instanceof SimpleSearchField)) {
28266
+ console.warn(`The custom field '${customField.name}' relies on a base field '${customField.baseFilter}' that is not supported. This field will be ignored.`);
28267
+ continue;
28268
+ }
28269
+ if (!customField.name.includes(':')) {
28270
+ console.warn(`The custom field '${customField.name}' is not scoped with a prefix. Custom fields must have their names prefixed, for instance "myOrg:myKeywords". This field will be ignored.`);
28271
+ continue;
28272
+ }
28273
+ const newField = baseField.clone();
28274
+ newField.setFieldIdentifier(customField.name);
28275
+ if (customField.includeValues) {
28276
+ newField.includeValues = customField.includeValues;
28277
+ }
28278
+ if (customField.excludeValues) {
28279
+ newField.excludeValues = customField.excludeValues;
28280
+ }
28281
+ this.fields[customField.name] = newField;
28282
+ }
27959
28283
  }
27960
28284
  get supportedFields() {
27961
28285
  return Object.keys(this.fields);
@@ -28003,7 +28327,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
28003
28327
  args: [{
28004
28328
  providedIn: 'root',
28005
28329
  }]
28006
- }] });
28330
+ }], ctorParameters: () => [] });
28007
28331
 
28008
28332
  class ApiCardComponent {
28009
28333
  constructor() {
@@ -28467,11 +28791,11 @@ class ThumbnailComponent {
28467
28791
  }
28468
28792
  }
28469
28793
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: ThumbnailComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
28470
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.19", type: ThumbnailComponent, isStandalone: true, selector: "gn-ui-thumbnail", inputs: { thumbnailUrl: "thumbnailUrl", fit: "fit" }, outputs: { placeholderShown: "placeholderShown" }, viewQueries: [{ propertyName: "imgElement", first: true, predicate: ["imageElement"], descendants: true }, { propertyName: "containerElement", first: true, predicate: ["containerElement"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n #containerElement\n class=\"h-full w-full relative shrink-0 overflow-hidden flex items-center justify-center\"\n [ngClass]=\"isPlaceholder ? 'bg-gray-100' : 'bg-white'\"\n [attr.data-cy-is-placeholder]=\"isPlaceholder.toString()\"\n>\n <img\n #imageElement\n class=\"relative w-full object-center\"\n [ngClass]=\"imgFit === 'contain' ? 'h-4/5 w-4/5' : 'h-full'\"\n [ngStyle]=\"{ objectFit: imgFit }\"\n alt=\"thumbnail\"\n loading=\"lazy\"\n (load)=\"setObjectFit()\"\n [src]=\"imgUrl\"\n (error)=\"useFallback()\"\n />\n</div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
28794
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.19", type: ThumbnailComponent, isStandalone: true, selector: "gn-ui-thumbnail", inputs: { thumbnailUrl: "thumbnailUrl", fit: "fit" }, outputs: { placeholderShown: "placeholderShown" }, viewQueries: [{ propertyName: "imgElement", first: true, predicate: ["imageElement"], descendants: true }, { propertyName: "containerElement", first: true, predicate: ["containerElement"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n #containerElement\n class=\"h-full w-full relative shrink-0 overflow-hidden flex items-center justify-center\"\n [ngClass]=\"isPlaceholder ? 'bg-gray-100' : 'bg-white'\"\n [attr.data-cy-is-placeholder]=\"isPlaceholder.toString()\"\n>\n <img\n #imageElement\n class=\"relative w-full object-center\"\n [ngClass]=\"imgFit === 'contain' ? 'h-4/5 w-4/5' : 'h-full'\"\n [ngStyle]=\"{ objectFit: imgFit }\"\n alt=\"\"\n loading=\"lazy\"\n (load)=\"setObjectFit()\"\n [src]=\"imgUrl\"\n (error)=\"useFallback()\"\n />\n</div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
28471
28795
  }
28472
28796
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: ThumbnailComponent, decorators: [{
28473
28797
  type: Component,
28474
- args: [{ selector: 'gn-ui-thumbnail', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [CommonModule], template: "<div\n #containerElement\n class=\"h-full w-full relative shrink-0 overflow-hidden flex items-center justify-center\"\n [ngClass]=\"isPlaceholder ? 'bg-gray-100' : 'bg-white'\"\n [attr.data-cy-is-placeholder]=\"isPlaceholder.toString()\"\n>\n <img\n #imageElement\n class=\"relative w-full object-center\"\n [ngClass]=\"imgFit === 'contain' ? 'h-4/5 w-4/5' : 'h-full'\"\n [ngStyle]=\"{ objectFit: imgFit }\"\n alt=\"thumbnail\"\n loading=\"lazy\"\n (load)=\"setObjectFit()\"\n [src]=\"imgUrl\"\n (error)=\"useFallback()\"\n />\n</div>\n" }]
28798
+ args: [{ selector: 'gn-ui-thumbnail', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [CommonModule], template: "<div\n #containerElement\n class=\"h-full w-full relative shrink-0 overflow-hidden flex items-center justify-center\"\n [ngClass]=\"isPlaceholder ? 'bg-gray-100' : 'bg-white'\"\n [attr.data-cy-is-placeholder]=\"isPlaceholder.toString()\"\n>\n <img\n #imageElement\n class=\"relative w-full object-center\"\n [ngClass]=\"imgFit === 'contain' ? 'h-4/5 w-4/5' : 'h-full'\"\n [ngStyle]=\"{ objectFit: imgFit }\"\n alt=\"\"\n loading=\"lazy\"\n (load)=\"setObjectFit()\"\n [src]=\"imgUrl\"\n (error)=\"useFallback()\"\n />\n</div>\n" }]
28475
28799
  }], propDecorators: { thumbnailUrl: [{
28476
28800
  type: Input
28477
28801
  }], fit: [{
@@ -28776,7 +29100,7 @@ class KindBadgeComponent {
28776
29100
  }
28777
29101
  }
28778
29102
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: KindBadgeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
28779
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: KindBadgeComponent, isStandalone: true, selector: "gn-ui-kind-badge", inputs: { styling: "styling", contentTemplate: "contentTemplate", kind: "kind", extraClass: "extraClass" }, ngImport: i0, template: "@if (kind) {\n <div [class]=\"badgeClasses\" [title]=\"'record.kind.' + kind | translate\">\n <ng-icon [name]=\"iconKind\" [ngClass]=\"extraClass\"></ng-icon>\n @if (contentTemplate) {\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n } @else {\n {{ 'record.kind.' + kind | translate }}\n }\n </div>\n}\n", styles: [":host gn-ui-badge ng-icon{font-size:1.2rem;width:1.2rem;height:1.2rem;transform:translateY(-2px)}\n"], dependencies: [{ kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], viewProviders: [
29103
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: KindBadgeComponent, isStandalone: true, selector: "gn-ui-kind-badge", inputs: { styling: "styling", contentTemplate: "contentTemplate", kind: "kind", extraClass: "extraClass" }, ngImport: i0, template: "@if (kind) {\n <div [class]=\"badgeClasses\" [title]=\"'record.kind.' + kind | translate\">\n <ng-icon\n [name]=\"iconKind\"\n [ngClass]=\"extraClass\"\n aria-hidden=\"true\"\n ></ng-icon>\n @if (contentTemplate) {\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n } @else {\n {{ 'record.kind.' + kind | translate }}\n }\n </div>\n}\n", styles: [":host gn-ui-badge ng-icon{font-size:1.2rem;width:1.2rem;height:1.2rem;transform:translateY(-2px)}\n"], dependencies: [{ kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], viewProviders: [
28780
29104
  provideIcons({
28781
29105
  iconoirAppleWallet,
28782
29106
  iconoirDatabase,
@@ -28800,7 +29124,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
28800
29124
  provideNgIconsConfig({
28801
29125
  size: '1.5em',
28802
29126
  }),
28803
- ], changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgIconComponent, CommonModule, TranslatePipe], template: "@if (kind) {\n <div [class]=\"badgeClasses\" [title]=\"'record.kind.' + kind | translate\">\n <ng-icon [name]=\"iconKind\" [ngClass]=\"extraClass\"></ng-icon>\n @if (contentTemplate) {\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n } @else {\n {{ 'record.kind.' + kind | translate }}\n }\n </div>\n}\n", styles: [":host gn-ui-badge ng-icon{font-size:1.2rem;width:1.2rem;height:1.2rem;transform:translateY(-2px)}\n"] }]
29127
+ ], changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgIconComponent, CommonModule, TranslatePipe], template: "@if (kind) {\n <div [class]=\"badgeClasses\" [title]=\"'record.kind.' + kind | translate\">\n <ng-icon\n [name]=\"iconKind\"\n [ngClass]=\"extraClass\"\n aria-hidden=\"true\"\n ></ng-icon>\n @if (contentTemplate) {\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n } @else {\n {{ 'record.kind.' + kind | translate }}\n }\n </div>\n}\n", styles: [":host gn-ui-badge ng-icon{font-size:1.2rem;width:1.2rem;height:1.2rem;transform:translateY(-2px)}\n"] }]
28804
29128
  }], propDecorators: { styling: [{
28805
29129
  type: Input
28806
29130
  }], contentTemplate: [{
@@ -30029,14 +30353,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
30029
30353
  marker('feature.catalog.attribute.type');
30030
30354
  marker('feature.catalog.attribute.name');
30031
30355
  marker('feature.catalog.attribute.code');
30032
- marker('feature.catalog.attribute.definition');
30356
+ marker('feature.catalog.attribute.description');
30033
30357
  marker('feature.catalog.attribute.values');
30034
30358
  class FeatureCatalogListComponent {
30035
30359
  constructor() {
30036
30360
  this.COLUMNS_DEFAULT = [
30037
30361
  { key: 'type', width: '25%' },
30038
30362
  { key: 'name', width: '40%' },
30039
- { key: 'definition', width: 'minmax(0px, 1fr)' },
30363
+ { key: 'description', width: 'minmax(0px, 1fr)' },
30040
30364
  ];
30041
30365
  this.COLUMN_VALUES = {
30042
30366
  key: 'values',
@@ -30057,7 +30381,7 @@ class FeatureCatalogListComponent {
30057
30381
  return col.key;
30058
30382
  }
30059
30383
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FeatureCatalogListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
30060
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: FeatureCatalogListComponent, isStandalone: true, selector: "gn-ui-feature-catalog-list", inputs: { filteredFeatureCatalog: "filteredFeatureCatalog" }, providers: [provideIcons({ iconoirList })], viewQueries: [{ propertyName: "scrollContainer", first: true, predicate: ["scrollContainer"], descendants: true }, { propertyName: "scrollable", first: true, predicate: CdkScrollable, descendants: true, static: true }, { propertyName: "panelComponent", first: true, predicate: ["expanel"], descendants: true, read: ExpandablePanelComponent, static: true }], ngImport: i0, template: "<div\n cdkScrollable\n class=\"h-[562px] relative overflow-y-auto overflow-hidden\"\n data-cy=\"feat-catalog-scrollable\"\n>\n <div #scrollContainer class=\"flex flex-col gap-2 py-5 px-5\">\n @for (\n featureType of filteredFeatureCatalog?.featureTypes;\n track featureType\n ) {\n <div class=\"rounded shadow bg-white\">\n <gn-ui-expandable-panel\n #expanel\n [collapsed]=\"filteredFeatureCatalog?.featureTypes?.length !== 1\"\n iconColor=\"black\"\n >\n <ng-template #titleTemplate>\n <div class=\"px-2\">\n <div class=\"text-lg font-bold\">{{ featureType.name }}</div>\n @if (featureType.definition) {\n <div class=\"text-sm\">\n {{ featureType.definition }}\n </div>\n }\n </div>\n </ng-template>\n @if (expanel && !expanel.collapsed) {\n <div\n class=\"grid gap-0\"\n [style.grid-template-columns]=\"\n getGridTemplateColumns(featureType.attributes)\n \"\n data-cy=\"feature-type-content\"\n >\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"py-1 px-2 text-sm font-bold text-left border-t break-all\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n [ngClass]=\"col.class || ''\"\n data-test=\"column-label\"\n >\n {{ 'feature.catalog.attribute.' + col.key | translate }}\n </div>\n }\n @if (expanel && !expanel.collapsed) {\n @for (row of featureType.attributes; track row) {\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"bg-white text-sm font-normal text-left border-t\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n data-test=\"cell-content\"\n >\n @if (col.key === 'values') {\n @if (row.values?.length > 0) {\n <gn-ui-cell-popin\n #popinRef\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n >\n <div\n cellContent\n data-cy=\"values-cell-popin-trigger\"\n >\n <gn-ui-button\n type=\"light\"\n extraClass=\"bg-transparent border-none\"\n (buttonClick)=\"popinRef.openOverlay()\"\n >\n <ng-icon name=\"iconoirList\" size=\"24\"></ng-icon>\n </gn-ui-button>\n </div>\n <div\n popinContent\n class=\"max-h-60 overflow-y-auto min-w-64 py-4 px-6\"\n style=\"scrollbar-width: thin\"\n >\n <ul class=\"list-disc list-inside mr-4\">\n @for (v of row.values; track v) {\n <li>\n {{ v.label || v.code }}\n </li>\n }\n </ul>\n </div>\n </gn-ui-cell-popin>\n }\n } @else {\n <gn-ui-truncated-text\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n [text]=\"row[col.key]\"\n ></gn-ui-truncated-text>\n }\n </div>\n }\n }\n }\n </div>\n }\n </gn-ui-expandable-panel>\n </div>\n }\n </div>\n</div>\n", dependencies: [{ kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: CellPopinComponent, selector: "gn-ui-cell-popin", inputs: ["extraClass", "cdkScrollContainer", "scrollContainer", "activePopin"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: ExpandablePanelComponent, selector: "gn-ui-expandable-panel", inputs: ["title", "iconColor", "collapsed"] }, { kind: "component", type: TruncatedTextComponent, selector: "gn-ui-truncated-text", inputs: ["text", "extraClass", "scrollContainer", "cdkScrollContainer"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "ngmodule", type: ScrollingModule }, { kind: "directive", type: i2$3.CdkScrollable, selector: "[cdk-scrollable], [cdkScrollable]" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
30384
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: FeatureCatalogListComponent, isStandalone: true, selector: "gn-ui-feature-catalog-list", inputs: { filteredFeatureCatalog: "filteredFeatureCatalog" }, providers: [provideIcons({ iconoirList })], viewQueries: [{ propertyName: "scrollContainer", first: true, predicate: ["scrollContainer"], descendants: true }, { propertyName: "scrollable", first: true, predicate: CdkScrollable, descendants: true, static: true }, { propertyName: "panelComponent", first: true, predicate: ["expanel"], descendants: true, read: ExpandablePanelComponent, static: true }], ngImport: i0, template: "<div\n cdkScrollable\n class=\"h-[562px] relative overflow-y-auto overflow-hidden\"\n data-cy=\"feat-catalog-scrollable\"\n>\n <div #scrollContainer class=\"flex flex-col gap-2 py-5 px-5\">\n @for (\n featureType of filteredFeatureCatalog?.featureTypes;\n track featureType\n ) {\n <div class=\"rounded shadow bg-white\">\n <gn-ui-expandable-panel\n #expanel\n [collapsed]=\"filteredFeatureCatalog?.featureTypes?.length !== 1\"\n iconColor=\"black\"\n >\n <ng-template #titleTemplate>\n <div class=\"px-2\">\n <div class=\"text-lg font-bold\">{{ featureType.name }}</div>\n @if (featureType.description) {\n <div class=\"text-sm\">\n {{ featureType.description }}\n </div>\n }\n </div>\n </ng-template>\n @if (expanel && !expanel.collapsed) {\n <div\n class=\"grid gap-0\"\n [style.grid-template-columns]=\"\n getGridTemplateColumns(featureType.attributes)\n \"\n data-cy=\"feature-type-content\"\n >\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"py-1 px-2 text-sm font-bold text-left border-t break-all\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n [ngClass]=\"col.class || ''\"\n data-test=\"column-label\"\n >\n {{ 'feature.catalog.attribute.' + col.key | translate }}\n </div>\n }\n @if (expanel && !expanel.collapsed) {\n @for (row of featureType.attributes; track row) {\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"bg-white text-sm font-normal text-left border-t\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n data-test=\"cell-content\"\n >\n @if (col.key === 'values') {\n @if (row.values?.length > 0) {\n <gn-ui-cell-popin\n #popinRef\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n >\n <div\n cellContent\n data-cy=\"values-cell-popin-trigger\"\n >\n <gn-ui-button\n type=\"light\"\n extraClass=\"bg-transparent border-none\"\n (buttonClick)=\"popinRef.openOverlay()\"\n >\n <ng-icon name=\"iconoirList\" size=\"24\"></ng-icon>\n </gn-ui-button>\n </div>\n <div\n popinContent\n class=\"max-h-60 overflow-y-auto min-w-64 py-4 px-6\"\n style=\"scrollbar-width: thin\"\n >\n <ul class=\"list-disc list-inside mr-4\">\n @for (v of row.values; track v) {\n <li>\n {{ v.label || v.value }}\n </li>\n }\n </ul>\n </div>\n </gn-ui-cell-popin>\n }\n } @else {\n <gn-ui-truncated-text\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n [text]=\"row[col.key]\"\n ></gn-ui-truncated-text>\n }\n </div>\n }\n }\n }\n </div>\n }\n </gn-ui-expandable-panel>\n </div>\n }\n </div>\n</div>\n", dependencies: [{ kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: CellPopinComponent, selector: "gn-ui-cell-popin", inputs: ["extraClass", "cdkScrollContainer", "scrollContainer", "activePopin"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: ExpandablePanelComponent, selector: "gn-ui-expandable-panel", inputs: ["title", "iconColor", "collapsed"] }, { kind: "component", type: TruncatedTextComponent, selector: "gn-ui-truncated-text", inputs: ["text", "extraClass", "scrollContainer", "cdkScrollContainer"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "ngmodule", type: ScrollingModule }, { kind: "directive", type: i2$3.CdkScrollable, selector: "[cdk-scrollable], [cdkScrollable]" }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
30061
30385
  }
30062
30386
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FeatureCatalogListComponent, decorators: [{
30063
30387
  type: Component,
@@ -30070,7 +30394,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
30070
30394
  TruncatedTextComponent,
30071
30395
  NgIconComponent,
30072
30396
  ScrollingModule,
30073
- ], providers: [provideIcons({ iconoirList })], template: "<div\n cdkScrollable\n class=\"h-[562px] relative overflow-y-auto overflow-hidden\"\n data-cy=\"feat-catalog-scrollable\"\n>\n <div #scrollContainer class=\"flex flex-col gap-2 py-5 px-5\">\n @for (\n featureType of filteredFeatureCatalog?.featureTypes;\n track featureType\n ) {\n <div class=\"rounded shadow bg-white\">\n <gn-ui-expandable-panel\n #expanel\n [collapsed]=\"filteredFeatureCatalog?.featureTypes?.length !== 1\"\n iconColor=\"black\"\n >\n <ng-template #titleTemplate>\n <div class=\"px-2\">\n <div class=\"text-lg font-bold\">{{ featureType.name }}</div>\n @if (featureType.definition) {\n <div class=\"text-sm\">\n {{ featureType.definition }}\n </div>\n }\n </div>\n </ng-template>\n @if (expanel && !expanel.collapsed) {\n <div\n class=\"grid gap-0\"\n [style.grid-template-columns]=\"\n getGridTemplateColumns(featureType.attributes)\n \"\n data-cy=\"feature-type-content\"\n >\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"py-1 px-2 text-sm font-bold text-left border-t break-all\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n [ngClass]=\"col.class || ''\"\n data-test=\"column-label\"\n >\n {{ 'feature.catalog.attribute.' + col.key | translate }}\n </div>\n }\n @if (expanel && !expanel.collapsed) {\n @for (row of featureType.attributes; track row) {\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"bg-white text-sm font-normal text-left border-t\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n data-test=\"cell-content\"\n >\n @if (col.key === 'values') {\n @if (row.values?.length > 0) {\n <gn-ui-cell-popin\n #popinRef\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n >\n <div\n cellContent\n data-cy=\"values-cell-popin-trigger\"\n >\n <gn-ui-button\n type=\"light\"\n extraClass=\"bg-transparent border-none\"\n (buttonClick)=\"popinRef.openOverlay()\"\n >\n <ng-icon name=\"iconoirList\" size=\"24\"></ng-icon>\n </gn-ui-button>\n </div>\n <div\n popinContent\n class=\"max-h-60 overflow-y-auto min-w-64 py-4 px-6\"\n style=\"scrollbar-width: thin\"\n >\n <ul class=\"list-disc list-inside mr-4\">\n @for (v of row.values; track v) {\n <li>\n {{ v.label || v.code }}\n </li>\n }\n </ul>\n </div>\n </gn-ui-cell-popin>\n }\n } @else {\n <gn-ui-truncated-text\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n [text]=\"row[col.key]\"\n ></gn-ui-truncated-text>\n }\n </div>\n }\n }\n }\n </div>\n }\n </gn-ui-expandable-panel>\n </div>\n }\n </div>\n</div>\n" }]
30397
+ ], providers: [provideIcons({ iconoirList })], template: "<div\n cdkScrollable\n class=\"h-[562px] relative overflow-y-auto overflow-hidden\"\n data-cy=\"feat-catalog-scrollable\"\n>\n <div #scrollContainer class=\"flex flex-col gap-2 py-5 px-5\">\n @for (\n featureType of filteredFeatureCatalog?.featureTypes;\n track featureType\n ) {\n <div class=\"rounded shadow bg-white\">\n <gn-ui-expandable-panel\n #expanel\n [collapsed]=\"filteredFeatureCatalog?.featureTypes?.length !== 1\"\n iconColor=\"black\"\n >\n <ng-template #titleTemplate>\n <div class=\"px-2\">\n <div class=\"text-lg font-bold\">{{ featureType.name }}</div>\n @if (featureType.description) {\n <div class=\"text-sm\">\n {{ featureType.description }}\n </div>\n }\n </div>\n </ng-template>\n @if (expanel && !expanel.collapsed) {\n <div\n class=\"grid gap-0\"\n [style.grid-template-columns]=\"\n getGridTemplateColumns(featureType.attributes)\n \"\n data-cy=\"feature-type-content\"\n >\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"py-1 px-2 text-sm font-bold text-left border-t break-all\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n [ngClass]=\"col.class || ''\"\n data-test=\"column-label\"\n >\n {{ 'feature.catalog.attribute.' + col.key | translate }}\n </div>\n }\n @if (expanel && !expanel.collapsed) {\n @for (row of featureType.attributes; track row) {\n @for (\n col of getColumnsDefinition(featureType.attributes);\n track trackByColumn(i, col);\n let i = $index\n ) {\n <div\n class=\"bg-white text-sm font-normal text-left border-t\"\n [class.border-l]=\"i > 0\"\n [class.border-gray-300]=\"i > 0\"\n data-test=\"cell-content\"\n >\n @if (col.key === 'values') {\n @if (row.values?.length > 0) {\n <gn-ui-cell-popin\n #popinRef\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n >\n <div\n cellContent\n data-cy=\"values-cell-popin-trigger\"\n >\n <gn-ui-button\n type=\"light\"\n extraClass=\"bg-transparent border-none\"\n (buttonClick)=\"popinRef.openOverlay()\"\n >\n <ng-icon name=\"iconoirList\" size=\"24\"></ng-icon>\n </gn-ui-button>\n </div>\n <div\n popinContent\n class=\"max-h-60 overflow-y-auto min-w-64 py-4 px-6\"\n style=\"scrollbar-width: thin\"\n >\n <ul class=\"list-disc list-inside mr-4\">\n @for (v of row.values; track v) {\n <li>\n {{ v.label || v.value }}\n </li>\n }\n </ul>\n </div>\n </gn-ui-cell-popin>\n }\n } @else {\n <gn-ui-truncated-text\n [scrollContainer]=\"scrollContainer\"\n [cdkScrollContainer]=\"scrollable\"\n [text]=\"row[col.key]\"\n ></gn-ui-truncated-text>\n }\n </div>\n }\n }\n }\n </div>\n }\n </gn-ui-expandable-panel>\n </div>\n }\n </div>\n</div>\n" }]
30074
30398
  }], propDecorators: { filteredFeatureCatalog: [{
30075
30399
  type: Input
30076
30400
  }], scrollContainer: [{
@@ -30670,11 +30994,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
30670
30994
 
30671
30995
  class ResultsHitsNumberComponent {
30672
30996
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: ResultsHitsNumberComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
30673
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: ResultsHitsNumberComponent, isStandalone: true, selector: "gn-ui-results-hits-number", inputs: { hits: "hits", loading: "loading" }, ngImport: i0, template: "@if (!loading) {\n <div class=\"w-full\">\n <span\n data-cy=\"resultsHitsFound\"\n translate\n [translateParams]=\"{ hits: hits }\"\n >results.records.hits.found</span\n >\n @if (hits === 0) {\n <p\n class=\"mt-4\"\n [innerHtml]=\"'results.records.hits.empty.help.html' | translate\"\n ></p>\n }\n </div>\n}\n", dependencies: [{ kind: "directive", type: TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
30997
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: ResultsHitsNumberComponent, isStandalone: true, selector: "gn-ui-results-hits-number", inputs: { hits: "hits", loading: "loading" }, ngImport: i0, template: "@if (!loading) {\n <div class=\"w-full\">\n <span\n role=\"status\"\n data-cy=\"resultsHitsFound\"\n translate\n [translateParams]=\"{ hits: hits }\"\n >results.records.hits.found</span\n >\n @if (hits === 0) {\n <p\n class=\"mt-4\"\n [innerHtml]=\"'results.records.hits.empty.help.html' | translate\"\n ></p>\n }\n </div>\n}\n", dependencies: [{ kind: "directive", type: TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }] }); }
30674
30998
  }
30675
30999
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: ResultsHitsNumberComponent, decorators: [{
30676
31000
  type: Component,
30677
- args: [{ selector: 'gn-ui-results-hits-number', standalone: true, imports: [TranslatePipe, TranslateDirective], template: "@if (!loading) {\n <div class=\"w-full\">\n <span\n data-cy=\"resultsHitsFound\"\n translate\n [translateParams]=\"{ hits: hits }\"\n >results.records.hits.found</span\n >\n @if (hits === 0) {\n <p\n class=\"mt-4\"\n [innerHtml]=\"'results.records.hits.empty.help.html' | translate\"\n ></p>\n }\n </div>\n}\n" }]
31001
+ args: [{ selector: 'gn-ui-results-hits-number', standalone: true, imports: [TranslatePipe, TranslateDirective], template: "@if (!loading) {\n <div class=\"w-full\">\n <span\n role=\"status\"\n data-cy=\"resultsHitsFound\"\n translate\n [translateParams]=\"{ hits: hits }\"\n >results.records.hits.found</span\n >\n @if (hits === 0) {\n <p\n class=\"mt-4\"\n [innerHtml]=\"'results.records.hits.empty.help.html' | translate\"\n ></p>\n }\n </div>\n}\n" }]
30678
31002
  }], propDecorators: { hits: [{
30679
31003
  type: Input
30680
31004
  }], loading: [{
@@ -31208,6 +31532,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
31208
31532
  ], template: "<div class=\"flex flex-col gap-6 p-6 items-start pointer-events-none\">\n @for (\n notification of notificationsService.notifications$ | async;\n track trackById($index, notification)\n ) {\n <gn-ui-notification\n class=\"max-w-full pointer-events-auto\"\n [text]=\"notification.text\"\n [type]=\"notification.type\"\n [title]=\"notification.title\"\n [closeMessage]=\"notification.closeMessage\"\n (notificationClose)=\"\n notificationsService.removeNotificationById(notification.id)\n \"\n [@enterExit]\n ></gn-ui-notification>\n }\n</div>\n" }]
31209
31533
  }] });
31210
31534
 
31535
+ marker('search.filters.spatialExtent.searchLocation');
31211
31536
  // in MB, null means no limit
31212
31537
  const SPATIAL_EXTENT_MAX_FILE_SIZE = new InjectionToken('spatialExtentMaxFileSize', { factory: () => null });
31213
31538
  class FilterDropdownComponent {
@@ -31238,6 +31563,9 @@ class FilterDropdownComponent {
31238
31563
  .subscribe((filters) => this.searchService.updateFilters(filters));
31239
31564
  this.clearSpatialExtentErrorNotification();
31240
31565
  }
31566
+ onLocationSelected({ bbox, label }) {
31567
+ this.spatialExtentDropdown.setLocationBbox(bbox, label);
31568
+ }
31241
31569
  onSpatialExtentError(error) {
31242
31570
  this.clearSpatialExtentErrorNotification();
31243
31571
  this.spatialExtentErrorNotificationId =
@@ -31268,7 +31596,7 @@ class FilterDropdownComponent {
31268
31596
  .subscribe((filters) => this.searchService.updateFilters(filters));
31269
31597
  }
31270
31598
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FilterDropdownComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
31271
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: FilterDropdownComponent, isStandalone: true, selector: "gn-ui-filter-dropdown", inputs: { fieldName: "fieldName", title: "title" }, ngImport: i0, template: "@if (fieldType === 'dateRange') {\n <gn-ui-date-range-dropdown\n [title]=\"title\"\n [dateRange]=\"(selectedDateRange$ | async) ?? {}\"\n (dateRangeChange)=\"onDateRangeChange($event)\"\n [attr.data-cy-field]=\"fieldName\"\n ></gn-ui-date-range-dropdown>\n} @else if (fieldType === 'spatialExtent') {\n <gn-ui-spatial-extent-dropdown\n [title]=\"title\"\n [initialBbox]=\"(selectedBoundingBox$ | async) ?? null\"\n [maxFileSizeMb]=\"spatialExtentMaxFileSize\"\n (bboxChange)=\"onBboxChange($event)\"\n (errorChange)=\"onSpatialExtentError($event)\"\n [attr.data-cy-field]=\"fieldName\"\n ></gn-ui-spatial-extent-dropdown>\n} @else {\n <gn-ui-dropdown-multiselect\n class=\"w-full\"\n [title]=\"title\"\n [maxRows]=\"6\"\n [choices]=\"(choices$ | async) || []\"\n [selected]=\"selected$ | async\"\n [allowSearch]=\"true\"\n (selectValues)=\"onSelectedValues($event)\"\n [attr.data-cy-field]=\"fieldName\"\n >\n </gn-ui-dropdown-multiselect>\n}\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: DateRangeDropdownComponent, selector: "gn-ui-date-range-dropdown", inputs: ["title", "dateRange"], outputs: ["dateRangeChange"] }, { kind: "component", type: DropdownMultiselectComponent, selector: "gn-ui-dropdown-multiselect", inputs: ["title", "choices", "selected", "allowSearch", "maxRows", "searchInputValue"], outputs: ["selectValues"] }, { kind: "component", type: SpatialExtentDropdownComponent, selector: "gn-ui-spatial-extent-dropdown", inputs: ["title", "maxFileSizeMb", "initialBbox"], outputs: ["bboxChange", "errorChange"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
31599
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: FilterDropdownComponent, isStandalone: true, selector: "gn-ui-filter-dropdown", inputs: { fieldName: "fieldName", title: "title" }, viewQueries: [{ propertyName: "spatialExtentDropdown", first: true, predicate: SpatialExtentDropdownComponent, descendants: true }], ngImport: i0, template: "@if (fieldType === 'dateRange') {\n <gn-ui-date-range-dropdown\n [title]=\"title\"\n [dateRange]=\"(selectedDateRange$ | async) ?? {}\"\n (dateRangeChange)=\"onDateRangeChange($event)\"\n [attr.data-cy-field]=\"fieldName\"\n ></gn-ui-date-range-dropdown>\n} @else if (fieldType === 'spatialExtent') {\n <gn-ui-spatial-extent-dropdown\n [title]=\"title\"\n [initialBbox]=\"(selectedBoundingBox$ | async) ?? null\"\n [maxFileSizeMb]=\"spatialExtentMaxFileSize\"\n (bboxChange)=\"onBboxChange($event)\"\n (errorChange)=\"onSpatialExtentError($event)\"\n [attr.data-cy-field]=\"fieldName\"\n >\n <gn-ui-location-search\n [placeholder]=\"'search.filters.spatialExtent.searchLocation' | translate\"\n (bboxSelected)=\"onLocationSelected($event)\"\n data-cy=\"locationSearch\"\n ></gn-ui-location-search>\n </gn-ui-spatial-extent-dropdown>\n} @else {\n <gn-ui-dropdown-multiselect\n class=\"w-full\"\n [title]=\"title\"\n [maxRows]=\"6\"\n [choices]=\"(choices$ | async) || []\"\n [selected]=\"selected$ | async\"\n [allowSearch]=\"true\"\n (selectValues)=\"onSelectedValues($event)\"\n [attr.data-cy-field]=\"fieldName\"\n >\n </gn-ui-dropdown-multiselect>\n}\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: DateRangeDropdownComponent, selector: "gn-ui-date-range-dropdown", inputs: ["title", "dateRange"], outputs: ["dateRangeChange"] }, { kind: "component", type: DropdownMultiselectComponent, selector: "gn-ui-dropdown-multiselect", inputs: ["title", "choices", "selected", "allowSearch", "maxRows", "searchInputValue"], outputs: ["selectValues"] }, { kind: "component", type: SpatialExtentDropdownComponent, selector: "gn-ui-spatial-extent-dropdown", inputs: ["title", "maxFileSizeMb", "initialBbox"], outputs: ["bboxChange", "errorChange"] }, { kind: "component", type: LocationSearchComponent, selector: "gn-ui-location-search", inputs: ["placeholder"], outputs: ["resultSelected", "bboxSelected"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
31272
31600
  }
31273
31601
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FilterDropdownComponent, decorators: [{
31274
31602
  type: Component,
@@ -31277,11 +31605,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
31277
31605
  DateRangeDropdownComponent,
31278
31606
  DropdownMultiselectComponent,
31279
31607
  SpatialExtentDropdownComponent,
31280
- ], template: "@if (fieldType === 'dateRange') {\n <gn-ui-date-range-dropdown\n [title]=\"title\"\n [dateRange]=\"(selectedDateRange$ | async) ?? {}\"\n (dateRangeChange)=\"onDateRangeChange($event)\"\n [attr.data-cy-field]=\"fieldName\"\n ></gn-ui-date-range-dropdown>\n} @else if (fieldType === 'spatialExtent') {\n <gn-ui-spatial-extent-dropdown\n [title]=\"title\"\n [initialBbox]=\"(selectedBoundingBox$ | async) ?? null\"\n [maxFileSizeMb]=\"spatialExtentMaxFileSize\"\n (bboxChange)=\"onBboxChange($event)\"\n (errorChange)=\"onSpatialExtentError($event)\"\n [attr.data-cy-field]=\"fieldName\"\n ></gn-ui-spatial-extent-dropdown>\n} @else {\n <gn-ui-dropdown-multiselect\n class=\"w-full\"\n [title]=\"title\"\n [maxRows]=\"6\"\n [choices]=\"(choices$ | async) || []\"\n [selected]=\"selected$ | async\"\n [allowSearch]=\"true\"\n (selectValues)=\"onSelectedValues($event)\"\n [attr.data-cy-field]=\"fieldName\"\n >\n </gn-ui-dropdown-multiselect>\n}\n" }]
31608
+ LocationSearchComponent,
31609
+ TranslatePipe,
31610
+ ], template: "@if (fieldType === 'dateRange') {\n <gn-ui-date-range-dropdown\n [title]=\"title\"\n [dateRange]=\"(selectedDateRange$ | async) ?? {}\"\n (dateRangeChange)=\"onDateRangeChange($event)\"\n [attr.data-cy-field]=\"fieldName\"\n ></gn-ui-date-range-dropdown>\n} @else if (fieldType === 'spatialExtent') {\n <gn-ui-spatial-extent-dropdown\n [title]=\"title\"\n [initialBbox]=\"(selectedBoundingBox$ | async) ?? null\"\n [maxFileSizeMb]=\"spatialExtentMaxFileSize\"\n (bboxChange)=\"onBboxChange($event)\"\n (errorChange)=\"onSpatialExtentError($event)\"\n [attr.data-cy-field]=\"fieldName\"\n >\n <gn-ui-location-search\n [placeholder]=\"'search.filters.spatialExtent.searchLocation' | translate\"\n (bboxSelected)=\"onLocationSelected($event)\"\n data-cy=\"locationSearch\"\n ></gn-ui-location-search>\n </gn-ui-spatial-extent-dropdown>\n} @else {\n <gn-ui-dropdown-multiselect\n class=\"w-full\"\n [title]=\"title\"\n [maxRows]=\"6\"\n [choices]=\"(choices$ | async) || []\"\n [selected]=\"selected$ | async\"\n [allowSearch]=\"true\"\n (selectValues)=\"onSelectedValues($event)\"\n [attr.data-cy-field]=\"fieldName\"\n >\n </gn-ui-dropdown-multiselect>\n}\n" }]
31281
31611
  }], propDecorators: { fieldName: [{
31282
31612
  type: Input
31283
31613
  }], title: [{
31284
31614
  type: Input
31615
+ }], spatialExtentDropdown: [{
31616
+ type: ViewChild,
31617
+ args: [SpatialExtentDropdownComponent]
31285
31618
  }] } });
31286
31619
 
31287
31620
  class FuzzySearchComponent {
@@ -33462,7 +33795,7 @@ class DataService {
33462
33795
  }));
33463
33796
  }
33464
33797
  async getDownloadLinksFromOgcApiFeatures(ogcApiLink) {
33465
- const collectionInfo = await this.getDownloadUrlsFromOgcApi(ogcApiLink.url.href);
33798
+ const collectionInfo = await this.getDownloadUrlsFromOgcApi(ogcApiLink.url.href, ogcApiLink.name);
33466
33799
  return Object.keys(collectionInfo.bulkDownloadLinks).map((mimeType) => {
33467
33800
  const urlWithoutLimit = new URL(collectionInfo.bulkDownloadLinks[mimeType]);
33468
33801
  urlWithoutLimit.searchParams.delete('limit');
@@ -33475,27 +33808,31 @@ class DataService {
33475
33808
  };
33476
33809
  });
33477
33810
  }
33478
- async getDownloadUrlsFromOgcApi(url) {
33811
+ async getTargetCollectionId(endpoint, collectionId) {
33812
+ const collections = await endpoint.featureCollections;
33813
+ return collections.length === 1 && !collectionId
33814
+ ? collections[0]
33815
+ : collectionId;
33816
+ }
33817
+ async getDownloadUrlsFromOgcApi(url, collectionId) {
33479
33818
  const endpoint = new OgcApiEndpoint(url);
33480
- return await endpoint.featureCollections
33481
- .then((collections) => {
33482
- return endpoint.getCollectionInfo(collections[0]);
33483
- })
33484
- .catch((error) => {
33485
- throw new Error(`ogc.unreachable.unknown`);
33486
- });
33819
+ try {
33820
+ const id = await this.getTargetCollectionId(endpoint, collectionId);
33821
+ return await endpoint.getCollectionInfo(id);
33822
+ }
33823
+ catch {
33824
+ throw new Error('ogc.unreachable.unknown');
33825
+ }
33487
33826
  }
33488
- async getItemsFromOgcApi(url, limit) {
33827
+ async getItemsFromOgcApi(url, collectionId, limit) {
33489
33828
  const endpoint = new OgcApiEndpoint(url);
33490
- return await endpoint.featureCollections
33491
- .then((collections) => {
33492
- return collections.length
33493
- ? endpoint.getCollectionItems(collections[0], limit)
33494
- : null;
33495
- })
33496
- .catch(() => {
33497
- throw new Error(`ogc.unreachable.unknown`);
33498
- });
33829
+ try {
33830
+ const id = await this.getTargetCollectionId(endpoint, collectionId);
33831
+ return await endpoint.getCollectionItems(id, limit);
33832
+ }
33833
+ catch {
33834
+ throw new Error('ogc.unreachable.unknown');
33835
+ }
33499
33836
  }
33500
33837
  async getItemsFromStacApi(url, options) {
33501
33838
  return await StacEndpoint.getItemsFromUrl(url, options)
@@ -33583,7 +33920,7 @@ class DataService {
33583
33920
  }
33584
33921
  else if (link.type === 'service' &&
33585
33922
  link.accessServiceProtocol === 'ogcFeatures') {
33586
- return from(this.getDownloadUrlsFromOgcApi(link.url.href)).pipe(switchMap$1((collectionInfo) => {
33923
+ return from(this.getDownloadUrlsFromOgcApi(link.url.href, link.name)).pipe(switchMap$1((collectionInfo) => {
33587
33924
  const isMimeTypeJson = (mimeType) => {
33588
33925
  return mimeType.toLowerCase().indexOf('json') > -1;
33589
33926
  };
@@ -34527,7 +34864,7 @@ class MdViewFacade {
34527
34864
  if (this.linkClassifier.hasUsage(link, LinkUsage.GEODATA)) {
34528
34865
  if (link.type === 'service' &&
34529
34866
  link.accessServiceProtocol === 'ogcFeatures') {
34530
- return from(this.dataService.getItemsFromOgcApi(link.url.href, 1)).pipe(map$1((collectionRecords) => {
34867
+ return from(this.dataService.getItemsFromOgcApi(link.url.href, link.name, 1)).pipe(map$1((collectionRecords) => {
34531
34868
  return collectionRecords &&
34532
34869
  collectionRecords[0] &&
34533
34870
  collectionRecords[0].geometry
@@ -34610,7 +34947,7 @@ class MdViewEffects {
34610
34947
  }
34611
34948
  return loadFullMetadataSuccess({ full: record });
34612
34949
  }), catchError((error) => of(loadFullMetadataFailure({ otherError: error.message })))));
34613
- this.loadFeatureCatalog$ = createEffect(() => this.actions$.pipe(ofType(loadFullMetadataSuccess), filter$1(({ full }) => full !== undefined), switchMap$1(({ full }) => this.recordsRepository.getFeatureCatalog(full)), map$1((featureCatalog) => loadFeatureCatalogSuccess({
34950
+ this.loadFeatureCatalog$ = createEffect(() => this.actions$.pipe(ofType(loadFullMetadataSuccess), filter$1(({ full }) => full !== undefined), switchMap$1(({ full }) => this.recordsRepository.queryLinkedFeatureCatalog(full)), map$1((featureCatalog) => loadFeatureCatalogSuccess({
34614
34951
  datasetCatalog: featureCatalog,
34615
34952
  })), catchError((error) => of(loadFeatureCatalogFailure({
34616
34953
  error: error.message,
@@ -36269,6 +36606,15 @@ const DEFAULT_CONFIGURATION = {
36269
36606
  labelKey: marker('editor.record.form.field.title'),
36270
36607
  },
36271
36608
  },
36609
+ {
36610
+ model: 'flags',
36611
+ modelSpecifier: 'flags:IS_REFERENCE_DATASET',
36612
+ formFieldConfig: {
36613
+ labelKey: marker('editor.record.form.field.flags.IS_REFERENCE_DATASET'),
36614
+ hintKey: marker('editor.record.form.field.hint.flags.IS_REFERENCE_DATASET'),
36615
+ },
36616
+ hidden: '${record.kind != "dataset" || !user.isAdmin}',
36617
+ },
36272
36618
  {
36273
36619
  model: 'abstract',
36274
36620
  formFieldConfig: {
@@ -39153,6 +39499,56 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
39153
39499
  type: Output
39154
39500
  }] } });
39155
39501
 
39502
+ class FormFieldRecordFlagComponent {
39503
+ constructor() {
39504
+ this.flagName = input(...(ngDevMode ? [undefined, { debugName: "flagName" }] : []));
39505
+ this.labelKey = input(...(ngDevMode ? [undefined, { debugName: "labelKey" }] : []));
39506
+ this.hintKey = input(...(ngDevMode ? [undefined, { debugName: "hintKey" }] : []));
39507
+ this.editorFacade = inject(EditorFacade);
39508
+ this.repository = inject(RecordsRepositoryInterface);
39509
+ this.notificationsService = inject(NotificationsService);
39510
+ this.translateService = inject(TranslateService);
39511
+ this.record = toSignal(this.editorFacade.record$);
39512
+ this.recordKind = toSignal(this.editorFacade.record$.pipe(map$1((record) => record.kind)));
39513
+ this.initialValue$ = this.editorFacade.record$.pipe(filter((record) => !!record), switchMap$1((record) => this.repository.getRecordFlag(record.uniqueIdentifier, this.flagName())));
39514
+ }
39515
+ onToggle(enabled) {
39516
+ if (this.record() === null) {
39517
+ return;
39518
+ }
39519
+ this.repository
39520
+ .setRecordFlag(this.record().uniqueIdentifier, this.flagName(), enabled)
39521
+ .subscribe({
39522
+ next: () => {
39523
+ // do nothing
39524
+ },
39525
+ error: (error) => {
39526
+ this.notificationsService.showNotification({
39527
+ type: 'error',
39528
+ title: this.translateService.instant('editor.record.flag.saveError.title'),
39529
+ text: `${this.translateService.instant('editor.record.flag.saveError.body', {
39530
+ recordKind: this.recordKind(),
39531
+ })} ${error.message}`,
39532
+ }, undefined, error);
39533
+ },
39534
+ });
39535
+ }
39536
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FormFieldRecordFlagComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
39537
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: FormFieldRecordFlagComponent, isStandalone: true, selector: "gn-ui-form-field-record-flag", inputs: { flagName: { classPropertyName: "flagName", publicName: "flagName", isSignal: true, isRequired: false, transformFunction: null }, labelKey: { classPropertyName: "labelKey", publicName: "labelKey", isSignal: true, isRequired: false, transformFunction: null }, hintKey: { classPropertyName: "hintKey", publicName: "hintKey", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"flex-1 flex justify-between items-center\">\n <gn-ui-check-toggle\n [label]=\"labelKey() | translate\"\n [value]=\"initialValue$ | async\"\n (toggled)=\"onToggle($event)\"\n [attr.data-cy]=\"'record-flag-toggle-' + flagName()\"\n ></gn-ui-check-toggle>\n\n @if (hintKey()) {\n <ng-icon\n name=\"matHelpOutline\"\n size=\"16\"\n class=\"m-2\"\n [matTooltip]=\"hintKey() | translate\"\n matTooltipPosition=\"above\"\n ></ng-icon>\n }\n</div>\n", styles: [""], dependencies: [{ kind: "component", type: CheckToggleComponent, selector: "gn-ui-check-toggle", inputs: ["title", "label", "value", "color"], outputs: ["toggled"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: TranslatePipe, name: "translate" }], viewProviders: [
39538
+ provideIcons({
39539
+ matHelpOutline,
39540
+ }),
39541
+ ], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
39542
+ }
39543
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FormFieldRecordFlagComponent, decorators: [{
39544
+ type: Component,
39545
+ args: [{ selector: 'gn-ui-form-field-record-flag', standalone: true, imports: [AsyncPipe, CheckToggleComponent, TranslatePipe, NgIcon, MatTooltip], viewProviders: [
39546
+ provideIcons({
39547
+ matHelpOutline,
39548
+ }),
39549
+ ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"flex-1 flex justify-between items-center\">\n <gn-ui-check-toggle\n [label]=\"labelKey() | translate\"\n [value]=\"initialValue$ | async\"\n (toggled)=\"onToggle($event)\"\n [attr.data-cy]=\"'record-flag-toggle-' + flagName()\"\n ></gn-ui-check-toggle>\n\n @if (hintKey()) {\n <ng-icon\n name=\"matHelpOutline\"\n size=\"16\"\n class=\"m-2\"\n [matTooltip]=\"hintKey() | translate\"\n matTooltipPosition=\"above\"\n ></ng-icon>\n }\n</div>\n" }]
39550
+ }], propDecorators: { flagName: [{ type: i0.Input, args: [{ isSignal: true, alias: "flagName", required: false }] }], labelKey: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelKey", required: false }] }], hintKey: [{ type: i0.Input, args: [{ isSignal: true, alias: "hintKey", required: false }] }] } });
39551
+
39156
39552
  class FormFieldComponent {
39157
39553
  constructor() {
39158
39554
  this.valueChange = new EventEmitter();
@@ -39171,6 +39567,7 @@ class FormFieldComponent {
39171
39567
  this.model === 'legalConstraints' ||
39172
39568
  this.model === 'securityConstraints' ||
39173
39569
  this.model === 'otherConstraints' ||
39570
+ this.model === 'flags' ||
39174
39571
  this.componentName === 'form-field-constraints-shortcuts');
39175
39572
  }
39176
39573
  get valueAsString() {
@@ -39210,6 +39607,9 @@ class FormFieldComponent {
39210
39607
  const identifiers = this.value;
39211
39608
  return identifiers?.[0]?.code || '';
39212
39609
  }
39610
+ get recordFlag() {
39611
+ return this.modelSpecifier?.replace(/^flags:/, '');
39612
+ }
39213
39613
  handleResourceIdentifierChange(code) {
39214
39614
  const identifiers = this.value;
39215
39615
  if (!code) {
@@ -39227,7 +39627,7 @@ class FormFieldComponent {
39227
39627
  }
39228
39628
  }
39229
39629
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FormFieldComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
39230
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.19", type: FormFieldComponent, isStandalone: true, selector: "gn-ui-form-field", inputs: { uniqueIdentifier: "uniqueIdentifier", recordKind: "recordKind", model: "model", modelSpecifier: "modelSpecifier", componentName: "componentName", config: "config", value: "value" }, outputs: { valueChange: "valueChange" }, providers: [provideIcons({ matEditOutline, matHelpOutline })], viewQueries: [{ propertyName: "titleInput", first: true, predicate: ["titleInput"], descendants: true }], hostDirectives: [{ directive: FieldFocusDirective }], ngImport: i0, template: "<!-- TEMPORARY - disabling the open data switch -->\n<!-- <ng-container *ngIf=\"model === 'licenses'\">\n <gn-ui-form-field-open-data\n [value]=\"valueAsConstraints\"\n (valueChange)=\"valueChange.emit($event)\"\n (openDataChange)=\"toggleIsOpenData($event)\"\n ></gn-ui-form-field-open-data>\n</ng-container> -->\n<div class=\"flex flex-col h-full\">\n <ng-container *ngIf=\"withoutWrapper; else withGenericWrapper\">\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n </ng-container>\n <ng-template #withGenericWrapper>\n <gn-ui-form-field-wrapper\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n >\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n </gn-ui-form-field-wrapper>\n </ng-template>\n</div>\n\n<ng-template #fieldContent>\n <ng-container [ngSwitch]=\"model\">\n <ng-container *ngSwitchCase=\"'title'\">\n <div class=\"flex flex-row flex-start items-center gap-3 mb-[12px]\">\n <textarea\n #titleInput\n cdkTextareaAutosize\n #autosize=\"cdkTextareaAutosize\"\n cdkAutosizeMinRows=\"1\"\n data-test=\"recordTitleInput\"\n class=\"grow font-title text-3xl font-normal overflow-hidden text-black/80\"\n [value]=\"valueAsString\"\n (change)=\"valueChange.emit($event.target.value)\"\n [placeholder]=\"\n 'editor.record.form.field.title.placeholder'\n | translate: { recordKind }\n \"\n ></textarea>\n <div class=\"flex flex-row justify-between self-start mt-0.5\">\n <ng-icon\n name=\"matEditOutline\"\n size=\"16\"\n class=\"m-2 cursor-pointer\"\n (click)=\"focusTitleInput()\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"config.hintKey\"\n name=\"matHelpOutline\"\n size=\"16\"\n class=\"m-2\"\n [matTooltip]=\"config.hintKey! | translate: { recordKind }\"\n matTooltipPosition=\"above\"\n ></ng-icon>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'abstract'\">\n <gn-ui-form-field-rich\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n [value]=\"valueAsString\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-rich>\n </ng-container>\n <ng-container *ngSwitchCase=\"'overviews'\">\n <gn-ui-form-field-overviews\n [metadataUuid]=\"uniqueIdentifier\"\n [recordKind]=\"recordKind\"\n [value]=\"valueAsOverviews\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-overviews>\n </ng-container>\n <ng-container *ngSwitchCase=\"'resourceIdentifiers'\">\n <gn-ui-form-field-simple\n [type]=\"'text'\"\n [value]=\"valueAsResourceIdentifierCode\"\n (valueChange)=\"handleResourceIdentifierChange($event)\"\n ></gn-ui-form-field-simple>\n </ng-container>\n <ng-container *ngSwitchCase=\"'resourceCreated'\">\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n </ng-container>\n <ng-container *ngSwitchCase=\"'resourceUpdated'\">\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n </ng-container>\n <ng-container *ngSwitchCase=\"'updateFrequency'\">\n <gn-ui-form-field-update-frequency\n [value]=\"valueAsUpdateFrequency\"\n (valueChange)=\"valueChange.emit($event)\"\n [recordKind]=\"recordKind\"\n ></gn-ui-form-field-update-frequency>\n </ng-container>\n <ng-container *ngSwitchCase=\"'associatedRecords'\">\n <gn-ui-form-field-associated-records\n [value]=\"valueAsAssociatedRecords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-associated-records>\n </ng-container>\n <ng-container *ngSwitchCase=\"'temporalExtents'\">\n <gn-ui-form-field-temporal-extents\n [value]=\"valueAsTemporalExtents\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-temporal-extents>\n </ng-container>\n <ng-container *ngSwitchCase=\"'spatialExtents'\">\n <gn-ui-form-field-spatial-extent></gn-ui-form-field-spatial-extent>\n </ng-container>\n <ng-container *ngSwitchCase=\"'keywords'\">\n <gn-ui-form-field-keywords\n [value]=\"valueAsKeywords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-keywords>\n </ng-container>\n <ng-container *ngSwitchCase=\"'topics'\">\n <gn-ui-form-field-topics\n [value]=\"valueAsTopics\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-topics>\n </ng-container>\n <ng-container *ngSwitchCase=\"'licenses'\">\n <gn-ui-form-field-license\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [recordLicences]=\"valueAsConstraints\"\n (recordLicencesChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-license>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'legalConstraints'\">\n <ng-container *ngTemplateOutlet=\"formFieldConstraints\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'securityConstraints'\">\n <ng-container *ngTemplateOutlet=\"formFieldConstraints\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'otherConstraints'\">\n <ng-container *ngTemplateOutlet=\"formFieldConstraints\"></ng-container\n ></ng-container>\n <ng-template #formFieldConstraints>\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints\n ></ng-template>\n\n <ng-container *ngSwitchCase=\"'contactsForResource'\">\n <gn-ui-form-field-contacts-for-resource\n [value]=\"valueAsIndividuals\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts-for-resource>\n </ng-container>\n <ng-container *ngSwitchCase=\"'contacts'\">\n <gn-ui-form-field-contacts\n [value]=\"valueAsIndividuals\"\n [modelSpecifier]=\"modelSpecifier\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts>\n </ng-container>\n <ng-container *ngSwitchCase=\"'onlineResources'\">\n <gn-ui-form-field-online-resources\n *ngIf=\"modelSpecifier === 'onlineResourceType:!link'\"\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-resources>\n </ng-container>\n <ng-container *ngSwitchCase=\"'onlineResources'\">\n <gn-ui-form-field-online-link-resources\n *ngIf=\"modelSpecifier === 'onlineResourceType:link'\"\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-link-resources>\n </ng-container>\n <ng-container *ngSwitchCase=\"'onlineResources'\">\n <gn-ui-form-field-online-single-link-resource\n *ngIf=\"modelSpecifier === 'onlineResourceType:singleLink'\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-single-link-resource>\n </ng-container>\n </ng-container>\n\n <ng-container *ngIf=\"!model\">\n <ng-container [ngSwitch]=\"componentName\">\n <ng-container *ngSwitchCase=\"'form-field-constraints-shortcuts'\">\n <gn-ui-form-field-constraints-shortcuts></gn-ui-form-field-constraints-shortcuts>\n </ng-container>\n <ng-container *ngSwitchCase=\"'form-field-spatial-toggle'\">\n <gn-ui-form-field-spatial-toggle></gn-ui-form-field-spatial-toggle>\n </ng-container>\n </ng-container>\n </ng-container>\n</ng-template>\n", styles: [":host{scroll-margin-top:90px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i1$5.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: FormFieldWrapperComponent, selector: "gn-ui-form-field-wrapper", inputs: ["label", "hint"] }, { kind: "component", type: FormFieldLicenseComponent, selector: "gn-ui-form-field-license", inputs: ["label", "recordLicences"], outputs: ["recordLicencesChange"] }, { kind: "component", type: FormFieldDateComponent, selector: "gn-ui-form-field-date", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldUpdateFrequencyComponent, selector: "gn-ui-form-field-update-frequency", inputs: ["value", "recordKind"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldAssociatedRecordsComponent, selector: "gn-ui-form-field-associated-records", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldTemporalExtentsComponent, selector: "gn-ui-form-field-temporal-extents", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldSimpleComponent, selector: "gn-ui-form-field-simple", inputs: ["type", "readonly", "invalid", "placeholder", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldRichComponent, selector: "gn-ui-form-field-rich", inputs: ["label", "hint", "placeholder", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldSpatialExtentComponent, selector: "gn-ui-form-field-spatial-extent" }, { kind: "component", type: FormFieldKeywordsComponent, selector: "gn-ui-form-field-keywords", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOverviewsComponent, selector: "gn-ui-form-field-overviews", inputs: ["metadataUuid", "recordKind", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldContactsForResourceComponent, selector: "gn-ui-form-field-contacts-for-resource", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOnlineResourcesComponent, selector: "gn-ui-form-field-online-resources", inputs: ["metadataUuid", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOnlineLinkResourcesComponent, selector: "gn-ui-form-field-online-link-resources", inputs: ["metadataUuid", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOnlineSingleLinkResourceComponent, selector: "gn-ui-form-field-online-single-link-resource", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldContactsComponent, selector: "gn-ui-form-field-contacts", inputs: ["value", "modelSpecifier"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldConstraintsComponent, selector: "gn-ui-form-field-constraints", inputs: ["label", "value", "constraintType"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldConstraintsShortcutsComponent, selector: "gn-ui-form-field-constraints-shortcuts" }, { kind: "component", type: FormFieldSpatialToggleComponent, selector: "gn-ui-form-field-spatial-toggle" }, { kind: "component", type: FormFieldTopicsComponent, selector: "gn-ui-form-field-topics", inputs: ["value"], outputs: ["valueChange"] }, { kind: "ngmodule", type: TextFieldModule }, { kind: "directive", type: i4$1.CdkTextareaAutosize, selector: "textarea[cdkTextareaAutosize]", inputs: ["cdkAutosizeMinRows", "cdkAutosizeMaxRows", "cdkTextareaAutosize", "placeholder"], exportAs: ["cdkTextareaAutosize"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
39630
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: FormFieldComponent, isStandalone: true, selector: "gn-ui-form-field", inputs: { uniqueIdentifier: "uniqueIdentifier", recordKind: "recordKind", model: "model", modelSpecifier: "modelSpecifier", componentName: "componentName", config: "config", value: "value" }, outputs: { valueChange: "valueChange" }, providers: [provideIcons({ matEditOutline, matHelpOutline })], viewQueries: [{ propertyName: "titleInput", first: true, predicate: ["titleInput"], descendants: true }], hostDirectives: [{ directive: FieldFocusDirective }], ngImport: i0, template: "<!-- TEMPORARY - disabling the open data switch -->\n<!-- <ng-container *ngIf=\"model === 'licenses'\">\n <gn-ui-form-field-open-data\n [value]=\"valueAsConstraints\"\n (valueChange)=\"valueChange.emit($event)\"\n (openDataChange)=\"toggleIsOpenData($event)\"\n ></gn-ui-form-field-open-data>\n</ng-container> -->\n<div class=\"flex flex-col h-full\">\n @if (withoutWrapper) {\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n } @else {\n <gn-ui-form-field-wrapper\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n >\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n </gn-ui-form-field-wrapper>\n }\n</div>\n\n<ng-template #fieldContent>\n @switch (model) {\n @case ('title') {\n <div class=\"flex flex-row flex-start items-center gap-3\">\n <textarea\n #titleInput\n cdkTextareaAutosize\n #autosize=\"cdkTextareaAutosize\"\n cdkAutosizeMinRows=\"1\"\n data-test=\"recordTitleInput\"\n class=\"grow font-title text-3xl font-normal overflow-hidden text-black/80\"\n [value]=\"valueAsString\"\n (change)=\"valueChange.emit($event.target.value)\"\n [placeholder]=\"\n 'editor.record.form.field.title.placeholder'\n | translate: { recordKind }\n \"\n ></textarea>\n <div class=\"flex flex-row justify-between self-start mt-0.5\">\n <ng-icon\n name=\"matEditOutline\"\n size=\"16\"\n class=\"m-2 cursor-pointer\"\n (click)=\"focusTitleInput()\"\n ></ng-icon>\n @if (config.hintKey) {\n <ng-icon\n name=\"matHelpOutline\"\n size=\"16\"\n class=\"m-2\"\n [matTooltip]=\"config.hintKey! | translate: { recordKind }\"\n matTooltipPosition=\"above\"\n ></ng-icon>\n }\n </div>\n </div>\n }\n @case ('abstract') {\n <gn-ui-form-field-rich\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n [value]=\"valueAsString\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-rich>\n }\n @case ('overviews') {\n <gn-ui-form-field-overviews\n [metadataUuid]=\"uniqueIdentifier\"\n [recordKind]=\"recordKind\"\n [value]=\"valueAsOverviews\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-overviews>\n }\n @case ('resourceIdentifiers') {\n <gn-ui-form-field-simple\n [type]=\"'text'\"\n [value]=\"valueAsResourceIdentifierCode\"\n (valueChange)=\"handleResourceIdentifierChange($event)\"\n ></gn-ui-form-field-simple>\n }\n @case ('resourceCreated') {\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n }\n @case ('resourceUpdated') {\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n }\n @case ('updateFrequency') {\n <gn-ui-form-field-update-frequency\n [value]=\"valueAsUpdateFrequency\"\n (valueChange)=\"valueChange.emit($event)\"\n [recordKind]=\"recordKind\"\n ></gn-ui-form-field-update-frequency>\n }\n @case ('associatedRecords') {\n <gn-ui-form-field-associated-records\n [value]=\"valueAsAssociatedRecords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-associated-records>\n }\n @case ('temporalExtents') {\n <gn-ui-form-field-temporal-extents\n [value]=\"valueAsTemporalExtents\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-temporal-extents>\n }\n @case ('spatialExtents') {\n <gn-ui-form-field-spatial-extent></gn-ui-form-field-spatial-extent>\n }\n @case ('keywords') {\n <gn-ui-form-field-keywords\n [value]=\"valueAsKeywords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-keywords>\n }\n @case ('topics') {\n <gn-ui-form-field-topics\n [value]=\"valueAsTopics\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-topics>\n }\n @case ('licenses') {\n <gn-ui-form-field-license\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [recordLicences]=\"valueAsConstraints\"\n (recordLicencesChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-license>\n }\n\n <!-- TODO: merge these cases together when migrated to angular 21 -->\n @case ('legalConstraints') {\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints>\n }\n @case ('securityConstraints') {\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints>\n }\n @case ('otherConstraints') {\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints>\n }\n\n @case ('contactsForResource') {\n <gn-ui-form-field-contacts-for-resource\n [value]=\"valueAsIndividuals\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts-for-resource>\n }\n @case ('contacts') {\n <gn-ui-form-field-contacts\n [value]=\"valueAsIndividuals\"\n [modelSpecifier]=\"modelSpecifier\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts>\n }\n @case ('onlineResources') {\n @if (modelSpecifier === 'onlineResourceType:!link') {\n <gn-ui-form-field-online-resources\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-resources>\n } @else if (modelSpecifier === 'onlineResourceType:link') {\n <gn-ui-form-field-online-link-resources\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-link-resources>\n } @else if (modelSpecifier === 'onlineResourceType:singleLink') {\n <gn-ui-form-field-online-single-link-resource\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-single-link-resource>\n }\n }\n @case ('flags') {\n <gn-ui-form-field-record-flag\n [flagName]=\"recordFlag\"\n [labelKey]=\"config.labelKey\"\n [hintKey]=\"config.hintKey\"\n ></gn-ui-form-field-record-flag>\n }\n }\n\n @if (!model) {\n @switch (componentName) {\n @case ('form-field-constraints-shortcuts') {\n <gn-ui-form-field-constraints-shortcuts></gn-ui-form-field-constraints-shortcuts>\n }\n @case ('form-field-spatial-toggle') {\n <gn-ui-form-field-spatial-toggle></gn-ui-form-field-spatial-toggle>\n }\n }\n }\n</ng-template>\n", styles: [":host{scroll-margin-top:90px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i1$5.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: FormFieldWrapperComponent, selector: "gn-ui-form-field-wrapper", inputs: ["label", "hint"] }, { kind: "component", type: FormFieldLicenseComponent, selector: "gn-ui-form-field-license", inputs: ["label", "recordLicences"], outputs: ["recordLicencesChange"] }, { kind: "component", type: FormFieldDateComponent, selector: "gn-ui-form-field-date", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldUpdateFrequencyComponent, selector: "gn-ui-form-field-update-frequency", inputs: ["value", "recordKind"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldAssociatedRecordsComponent, selector: "gn-ui-form-field-associated-records", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldTemporalExtentsComponent, selector: "gn-ui-form-field-temporal-extents", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldSimpleComponent, selector: "gn-ui-form-field-simple", inputs: ["type", "readonly", "invalid", "placeholder", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldRichComponent, selector: "gn-ui-form-field-rich", inputs: ["label", "hint", "placeholder", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldSpatialExtentComponent, selector: "gn-ui-form-field-spatial-extent" }, { kind: "component", type: FormFieldKeywordsComponent, selector: "gn-ui-form-field-keywords", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOverviewsComponent, selector: "gn-ui-form-field-overviews", inputs: ["metadataUuid", "recordKind", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldContactsForResourceComponent, selector: "gn-ui-form-field-contacts-for-resource", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOnlineResourcesComponent, selector: "gn-ui-form-field-online-resources", inputs: ["metadataUuid", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOnlineLinkResourcesComponent, selector: "gn-ui-form-field-online-link-resources", inputs: ["metadataUuid", "value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldOnlineSingleLinkResourceComponent, selector: "gn-ui-form-field-online-single-link-resource", inputs: ["value"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldContactsComponent, selector: "gn-ui-form-field-contacts", inputs: ["value", "modelSpecifier"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldConstraintsComponent, selector: "gn-ui-form-field-constraints", inputs: ["label", "value", "constraintType"], outputs: ["valueChange"] }, { kind: "component", type: FormFieldConstraintsShortcutsComponent, selector: "gn-ui-form-field-constraints-shortcuts" }, { kind: "component", type: FormFieldSpatialToggleComponent, selector: "gn-ui-form-field-spatial-toggle" }, { kind: "component", type: FormFieldTopicsComponent, selector: "gn-ui-form-field-topics", inputs: ["value"], outputs: ["valueChange"] }, { kind: "ngmodule", type: TextFieldModule }, { kind: "directive", type: i4$1.CdkTextareaAutosize, selector: "textarea[cdkTextareaAutosize]", inputs: ["cdkAutosizeMinRows", "cdkAutosizeMaxRows", "cdkTextareaAutosize", "placeholder"], exportAs: ["cdkTextareaAutosize"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "component", type: FormFieldRecordFlagComponent, selector: "gn-ui-form-field-record-flag", inputs: ["flagName", "labelKey", "hintKey"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
39231
39631
  }
39232
39632
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: FormFieldComponent, decorators: [{
39233
39633
  type: Component,
@@ -39257,7 +39657,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
39257
39657
  FormFieldTopicsComponent,
39258
39658
  TextFieldModule,
39259
39659
  NgIconComponent,
39260
- ], providers: [provideIcons({ matEditOutline, matHelpOutline })], hostDirectives: [FieldFocusDirective], template: "<!-- TEMPORARY - disabling the open data switch -->\n<!-- <ng-container *ngIf=\"model === 'licenses'\">\n <gn-ui-form-field-open-data\n [value]=\"valueAsConstraints\"\n (valueChange)=\"valueChange.emit($event)\"\n (openDataChange)=\"toggleIsOpenData($event)\"\n ></gn-ui-form-field-open-data>\n</ng-container> -->\n<div class=\"flex flex-col h-full\">\n <ng-container *ngIf=\"withoutWrapper; else withGenericWrapper\">\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n </ng-container>\n <ng-template #withGenericWrapper>\n <gn-ui-form-field-wrapper\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n >\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n </gn-ui-form-field-wrapper>\n </ng-template>\n</div>\n\n<ng-template #fieldContent>\n <ng-container [ngSwitch]=\"model\">\n <ng-container *ngSwitchCase=\"'title'\">\n <div class=\"flex flex-row flex-start items-center gap-3 mb-[12px]\">\n <textarea\n #titleInput\n cdkTextareaAutosize\n #autosize=\"cdkTextareaAutosize\"\n cdkAutosizeMinRows=\"1\"\n data-test=\"recordTitleInput\"\n class=\"grow font-title text-3xl font-normal overflow-hidden text-black/80\"\n [value]=\"valueAsString\"\n (change)=\"valueChange.emit($event.target.value)\"\n [placeholder]=\"\n 'editor.record.form.field.title.placeholder'\n | translate: { recordKind }\n \"\n ></textarea>\n <div class=\"flex flex-row justify-between self-start mt-0.5\">\n <ng-icon\n name=\"matEditOutline\"\n size=\"16\"\n class=\"m-2 cursor-pointer\"\n (click)=\"focusTitleInput()\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"config.hintKey\"\n name=\"matHelpOutline\"\n size=\"16\"\n class=\"m-2\"\n [matTooltip]=\"config.hintKey! | translate: { recordKind }\"\n matTooltipPosition=\"above\"\n ></ng-icon>\n </div>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'abstract'\">\n <gn-ui-form-field-rich\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n [value]=\"valueAsString\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-rich>\n </ng-container>\n <ng-container *ngSwitchCase=\"'overviews'\">\n <gn-ui-form-field-overviews\n [metadataUuid]=\"uniqueIdentifier\"\n [recordKind]=\"recordKind\"\n [value]=\"valueAsOverviews\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-overviews>\n </ng-container>\n <ng-container *ngSwitchCase=\"'resourceIdentifiers'\">\n <gn-ui-form-field-simple\n [type]=\"'text'\"\n [value]=\"valueAsResourceIdentifierCode\"\n (valueChange)=\"handleResourceIdentifierChange($event)\"\n ></gn-ui-form-field-simple>\n </ng-container>\n <ng-container *ngSwitchCase=\"'resourceCreated'\">\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n </ng-container>\n <ng-container *ngSwitchCase=\"'resourceUpdated'\">\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n </ng-container>\n <ng-container *ngSwitchCase=\"'updateFrequency'\">\n <gn-ui-form-field-update-frequency\n [value]=\"valueAsUpdateFrequency\"\n (valueChange)=\"valueChange.emit($event)\"\n [recordKind]=\"recordKind\"\n ></gn-ui-form-field-update-frequency>\n </ng-container>\n <ng-container *ngSwitchCase=\"'associatedRecords'\">\n <gn-ui-form-field-associated-records\n [value]=\"valueAsAssociatedRecords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-associated-records>\n </ng-container>\n <ng-container *ngSwitchCase=\"'temporalExtents'\">\n <gn-ui-form-field-temporal-extents\n [value]=\"valueAsTemporalExtents\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-temporal-extents>\n </ng-container>\n <ng-container *ngSwitchCase=\"'spatialExtents'\">\n <gn-ui-form-field-spatial-extent></gn-ui-form-field-spatial-extent>\n </ng-container>\n <ng-container *ngSwitchCase=\"'keywords'\">\n <gn-ui-form-field-keywords\n [value]=\"valueAsKeywords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-keywords>\n </ng-container>\n <ng-container *ngSwitchCase=\"'topics'\">\n <gn-ui-form-field-topics\n [value]=\"valueAsTopics\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-topics>\n </ng-container>\n <ng-container *ngSwitchCase=\"'licenses'\">\n <gn-ui-form-field-license\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [recordLicences]=\"valueAsConstraints\"\n (recordLicencesChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-license>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'legalConstraints'\">\n <ng-container *ngTemplateOutlet=\"formFieldConstraints\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'securityConstraints'\">\n <ng-container *ngTemplateOutlet=\"formFieldConstraints\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"'otherConstraints'\">\n <ng-container *ngTemplateOutlet=\"formFieldConstraints\"></ng-container\n ></ng-container>\n <ng-template #formFieldConstraints>\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints\n ></ng-template>\n\n <ng-container *ngSwitchCase=\"'contactsForResource'\">\n <gn-ui-form-field-contacts-for-resource\n [value]=\"valueAsIndividuals\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts-for-resource>\n </ng-container>\n <ng-container *ngSwitchCase=\"'contacts'\">\n <gn-ui-form-field-contacts\n [value]=\"valueAsIndividuals\"\n [modelSpecifier]=\"modelSpecifier\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts>\n </ng-container>\n <ng-container *ngSwitchCase=\"'onlineResources'\">\n <gn-ui-form-field-online-resources\n *ngIf=\"modelSpecifier === 'onlineResourceType:!link'\"\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-resources>\n </ng-container>\n <ng-container *ngSwitchCase=\"'onlineResources'\">\n <gn-ui-form-field-online-link-resources\n *ngIf=\"modelSpecifier === 'onlineResourceType:link'\"\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-link-resources>\n </ng-container>\n <ng-container *ngSwitchCase=\"'onlineResources'\">\n <gn-ui-form-field-online-single-link-resource\n *ngIf=\"modelSpecifier === 'onlineResourceType:singleLink'\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-single-link-resource>\n </ng-container>\n </ng-container>\n\n <ng-container *ngIf=\"!model\">\n <ng-container [ngSwitch]=\"componentName\">\n <ng-container *ngSwitchCase=\"'form-field-constraints-shortcuts'\">\n <gn-ui-form-field-constraints-shortcuts></gn-ui-form-field-constraints-shortcuts>\n </ng-container>\n <ng-container *ngSwitchCase=\"'form-field-spatial-toggle'\">\n <gn-ui-form-field-spatial-toggle></gn-ui-form-field-spatial-toggle>\n </ng-container>\n </ng-container>\n </ng-container>\n</ng-template>\n", styles: [":host{scroll-margin-top:90px}\n"] }]
39660
+ FormFieldRecordFlagComponent,
39661
+ ], providers: [provideIcons({ matEditOutline, matHelpOutline })], hostDirectives: [FieldFocusDirective], template: "<!-- TEMPORARY - disabling the open data switch -->\n<!-- <ng-container *ngIf=\"model === 'licenses'\">\n <gn-ui-form-field-open-data\n [value]=\"valueAsConstraints\"\n (valueChange)=\"valueChange.emit($event)\"\n (openDataChange)=\"toggleIsOpenData($event)\"\n ></gn-ui-form-field-open-data>\n</ng-container> -->\n<div class=\"flex flex-col h-full\">\n @if (withoutWrapper) {\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n } @else {\n <gn-ui-form-field-wrapper\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n >\n <ng-container *ngTemplateOutlet=\"fieldContent\"></ng-container>\n </gn-ui-form-field-wrapper>\n }\n</div>\n\n<ng-template #fieldContent>\n @switch (model) {\n @case ('title') {\n <div class=\"flex flex-row flex-start items-center gap-3\">\n <textarea\n #titleInput\n cdkTextareaAutosize\n #autosize=\"cdkTextareaAutosize\"\n cdkAutosizeMinRows=\"1\"\n data-test=\"recordTitleInput\"\n class=\"grow font-title text-3xl font-normal overflow-hidden text-black/80\"\n [value]=\"valueAsString\"\n (change)=\"valueChange.emit($event.target.value)\"\n [placeholder]=\"\n 'editor.record.form.field.title.placeholder'\n | translate: { recordKind }\n \"\n ></textarea>\n <div class=\"flex flex-row justify-between self-start mt-0.5\">\n <ng-icon\n name=\"matEditOutline\"\n size=\"16\"\n class=\"m-2 cursor-pointer\"\n (click)=\"focusTitleInput()\"\n ></ng-icon>\n @if (config.hintKey) {\n <ng-icon\n name=\"matHelpOutline\"\n size=\"16\"\n class=\"m-2\"\n [matTooltip]=\"config.hintKey! | translate: { recordKind }\"\n matTooltipPosition=\"above\"\n ></ng-icon>\n }\n </div>\n </div>\n }\n @case ('abstract') {\n <gn-ui-form-field-rich\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [hint]=\"config.hintKey! | translate: { recordKind }\"\n [value]=\"valueAsString\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-rich>\n }\n @case ('overviews') {\n <gn-ui-form-field-overviews\n [metadataUuid]=\"uniqueIdentifier\"\n [recordKind]=\"recordKind\"\n [value]=\"valueAsOverviews\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-overviews>\n }\n @case ('resourceIdentifiers') {\n <gn-ui-form-field-simple\n [type]=\"'text'\"\n [value]=\"valueAsResourceIdentifierCode\"\n (valueChange)=\"handleResourceIdentifierChange($event)\"\n ></gn-ui-form-field-simple>\n }\n @case ('resourceCreated') {\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n }\n @case ('resourceUpdated') {\n <gn-ui-form-field-date\n [value]=\"valueAsDate\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-date>\n }\n @case ('updateFrequency') {\n <gn-ui-form-field-update-frequency\n [value]=\"valueAsUpdateFrequency\"\n (valueChange)=\"valueChange.emit($event)\"\n [recordKind]=\"recordKind\"\n ></gn-ui-form-field-update-frequency>\n }\n @case ('associatedRecords') {\n <gn-ui-form-field-associated-records\n [value]=\"valueAsAssociatedRecords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-associated-records>\n }\n @case ('temporalExtents') {\n <gn-ui-form-field-temporal-extents\n [value]=\"valueAsTemporalExtents\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-temporal-extents>\n }\n @case ('spatialExtents') {\n <gn-ui-form-field-spatial-extent></gn-ui-form-field-spatial-extent>\n }\n @case ('keywords') {\n <gn-ui-form-field-keywords\n [value]=\"valueAsKeywords\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-keywords>\n }\n @case ('topics') {\n <gn-ui-form-field-topics\n [value]=\"valueAsTopics\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-topics>\n }\n @case ('licenses') {\n <gn-ui-form-field-license\n [label]=\"config.labelKey! | translate: { recordKind }\"\n [recordLicences]=\"valueAsConstraints\"\n (recordLicencesChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-license>\n }\n\n <!-- TODO: merge these cases together when migrated to angular 21 -->\n @case ('legalConstraints') {\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints>\n }\n @case ('securityConstraints') {\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints>\n }\n @case ('otherConstraints') {\n <gn-ui-form-field-constraints\n [label]=\"config.labelKey\"\n [value]=\"valueAsConstraints\"\n [constraintType]=\"model\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-constraints>\n }\n\n @case ('contactsForResource') {\n <gn-ui-form-field-contacts-for-resource\n [value]=\"valueAsIndividuals\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts-for-resource>\n }\n @case ('contacts') {\n <gn-ui-form-field-contacts\n [value]=\"valueAsIndividuals\"\n [modelSpecifier]=\"modelSpecifier\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-contacts>\n }\n @case ('onlineResources') {\n @if (modelSpecifier === 'onlineResourceType:!link') {\n <gn-ui-form-field-online-resources\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-resources>\n } @else if (modelSpecifier === 'onlineResourceType:link') {\n <gn-ui-form-field-online-link-resources\n [metadataUuid]=\"uniqueIdentifier\"\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-link-resources>\n } @else if (modelSpecifier === 'onlineResourceType:singleLink') {\n <gn-ui-form-field-online-single-link-resource\n [value]=\"valueAsOnlineResources\"\n (valueChange)=\"valueChange.emit($event)\"\n ></gn-ui-form-field-online-single-link-resource>\n }\n }\n @case ('flags') {\n <gn-ui-form-field-record-flag\n [flagName]=\"recordFlag\"\n [labelKey]=\"config.labelKey\"\n [hintKey]=\"config.hintKey\"\n ></gn-ui-form-field-record-flag>\n }\n }\n\n @if (!model) {\n @switch (componentName) {\n @case ('form-field-constraints-shortcuts') {\n <gn-ui-form-field-constraints-shortcuts></gn-ui-form-field-constraints-shortcuts>\n }\n @case ('form-field-spatial-toggle') {\n <gn-ui-form-field-spatial-toggle></gn-ui-form-field-spatial-toggle>\n }\n }\n }\n</ng-template>\n", styles: [":host{scroll-margin-top:90px}\n"] }]
39261
39662
  }], propDecorators: { uniqueIdentifier: [{
39262
39663
  type: Input
39263
39664
  }], recordKind: [{
@@ -39288,9 +39689,13 @@ const TOKEN_OPERATOR_LOGICAL = ['==', '!='];
39288
39689
  const TOKEN_STRING_LITERAL = ["'", '"'];
39289
39690
  const TOKEN_GROUP_START = '(';
39290
39691
  const TOKEN_GROUP_END = ')';
39692
+ const TOKEN_OPERATOR_BOOLEAN = ['&&', '||'];
39693
+ const TOKEN_OPERATOR_NOT = '!';
39291
39694
  // See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Operator_precedence
39292
39695
  const OPERATORS_BY_PRECEDENCE = [
39293
39696
  [TOKEN_OPERATOR_TERNARY_FIRST, TOKEN_OPERATOR_TERNARY_SECOND],
39697
+ TOKEN_OPERATOR_BOOLEAN,
39698
+ [TOKEN_OPERATOR_NOT],
39294
39699
  TOKEN_OPERATOR_LOGICAL,
39295
39700
  ];
39296
39701
  const ALL_OPERATORS = OPERATORS_BY_PRECEDENCE.flat();
@@ -39400,6 +39805,16 @@ function evaluateInternal(expression, currentContext) {
39400
39805
  pos++;
39401
39806
  continue;
39402
39807
  }
39808
+ // BOOLEAN LITERAL
39809
+ const isBooleanLiteral = readNext(expression, pos, 4) === 'true' ||
39810
+ readNext(expression, pos, 5) === 'false';
39811
+ if (isBooleanLiteral) {
39812
+ const literal = readNext(expression, pos, 4) === 'true' ? 'true' : 'false';
39813
+ pos += literal.length;
39814
+ const booleanLiteral = literal === 'true';
39815
+ currentEvaluator = () => booleanLiteral;
39816
+ continue;
39817
+ }
39403
39818
  // SYMBOL (NAME)
39404
39819
  const isSymbol = /[a-zA-Z]/.test(readNext(expression, pos));
39405
39820
  if (isSymbol) {
@@ -39490,6 +39905,35 @@ function evaluateInternal(expression, currentContext) {
39490
39905
  };
39491
39906
  continue;
39492
39907
  }
39908
+ // BOOLEAN OPERATORS
39909
+ const isBooleanOperator = TOKEN_OPERATOR_BOOLEAN.some((token) => readNext(expression, pos, token.length) === token);
39910
+ if (isBooleanOperator) {
39911
+ const matchingOperator = TOKEN_OPERATOR_BOOLEAN.find((token) => readNext(expression, pos, token.length) === token);
39912
+ const isAnd = matchingOperator === '&&';
39913
+ pos += matchingOperator.length;
39914
+ const leftEvaluator = currentEvaluator;
39915
+ const rightExpression = readUntilNextOperator(expression, pos, matchingOperator);
39916
+ pos += rightExpression.length;
39917
+ const rightEvaluator = evaluateInternal(rightExpression, currentContext).evaluator;
39918
+ currentEvaluator = (context) => {
39919
+ return isAnd
39920
+ ? Boolean(leftEvaluator(context) && rightEvaluator(context))
39921
+ : Boolean(leftEvaluator(context) || rightEvaluator(context));
39922
+ };
39923
+ continue;
39924
+ }
39925
+ // PREFIX OPERATORS
39926
+ const isNotOperator = readNext(expression, pos) === TOKEN_OPERATOR_NOT;
39927
+ if (isNotOperator) {
39928
+ pos++;
39929
+ const operandExpression = readUntilNextOperator(expression, pos, TOKEN_OPERATOR_NOT);
39930
+ pos += operandExpression.length;
39931
+ const operandEvaluator = evaluateInternal(operandExpression, currentContext).evaluator;
39932
+ currentEvaluator = (context) => {
39933
+ return !operandEvaluator(context);
39934
+ };
39935
+ continue;
39936
+ }
39493
39937
  // TERNARY OPERATOR
39494
39938
  const isTernary = readNext(expression, pos) === TOKEN_OPERATOR_TERNARY_FIRST;
39495
39939
  if (isTernary) {
@@ -39560,6 +40004,7 @@ class RecordFormComponent {
39560
40004
  constructor() {
39561
40005
  this.facade = inject(EditorFacade);
39562
40006
  this.notifications = inject(NotificationsService);
40007
+ this.platform = inject(PlatformServiceInterface);
39563
40008
  this.subscription = new Subscription();
39564
40009
  this.recordUniqueIdentifier$ = this.facade.record$.pipe(map$2((record) => record.uniqueIdentifier));
39565
40010
  this.recordKind$ = this.facade.record$.pipe(map$2((record) => record.kind));
@@ -39570,6 +40015,8 @@ class RecordFormComponent {
39570
40015
  this.formFields = viewChildren(FormFieldComponent, ...(ngDevMode ? [{ debugName: "formFields" }] : []));
39571
40016
  this.sectionFocusDirectives = viewChildren('sectionFocus', ...(ngDevMode ? [{ debugName: "sectionFocusDirectives" }] : []));
39572
40017
  this.recordSignal = toSignal(this.facade.record$, { requireSync: true });
40018
+ this.userSignal = toSignal(this.platform.getMe());
40019
+ this.isAdminSignal = toSignal(this.platform.isAdministrator());
39573
40020
  this.expressionCache = new Map();
39574
40021
  }
39575
40022
  focusField(model, sectionIndex) {
@@ -39594,7 +40041,7 @@ class RecordFormComponent {
39594
40041
  this.subscription.unsubscribe();
39595
40042
  }
39596
40043
  handleFieldValueChange(model, newValue) {
39597
- if (!model) {
40044
+ if (!model || model === 'flags') {
39598
40045
  return;
39599
40046
  }
39600
40047
  this.facade.updateRecordField(model, newValue);
@@ -39637,7 +40084,15 @@ ${errors.map((err) => `> ${err}`).join('\n')}`);
39637
40084
  text: 'An error happened while evaluating an expression inside the editor configuration; open the developer console for more information',
39638
40085
  });
39639
40086
  }
39640
- this.expressionCache.set(expression, computed(() => evaluator({ globals: { record: this.recordSignal() } })));
40087
+ this.expressionCache.set(expression, computed(() => evaluator({
40088
+ globals: {
40089
+ record: this.recordSignal(),
40090
+ user: {
40091
+ ...this.userSignal(),
40092
+ isAdmin: this.isAdminSignal(),
40093
+ },
40094
+ },
40095
+ })));
39641
40096
  return this.expressionCache.get(expression);
39642
40097
  }
39643
40098
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: RecordFormComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
@@ -40419,7 +40874,191 @@ function getCustomTranslations(langCode) {
40419
40874
  return langCode in customTranslations ? customTranslations[langCode] : {};
40420
40875
  }
40421
40876
  let appConfigLoaded = false;
40422
- function loadAppConfig(configUrl = 'assets/configuration/default.toml') {
40877
+ function parseGlobalSection(parsed, { warnings, errors }) {
40878
+ let parsedGlobalSection = parseConfigSection(parsed, 'global', ['geonetwork4_api_url'], [
40879
+ 'datahub_url',
40880
+ 'edit_url_template',
40881
+ 'proxy_path',
40882
+ 'metadata_language',
40883
+ 'login_url',
40884
+ 'logout_url',
40885
+ 'settings_url',
40886
+ 'web_component_embedder_url',
40887
+ 'languages',
40888
+ 'contact_email',
40889
+ 'reuse_form_url',
40890
+ ], warnings, errors);
40891
+ if (parsedGlobalSection?.metadata_language) {
40892
+ parsedGlobalSection = checkMetadataLanguage(parsedGlobalSection, warnings);
40893
+ }
40894
+ return parsedGlobalSection === null
40895
+ ? null
40896
+ : {
40897
+ GN4_API_URL: parsedGlobalSection.geonetwork4_api_url,
40898
+ DATAHUB_URL: parsedGlobalSection.datahub_url,
40899
+ EDIT_URL_TEMPLATE: parsedGlobalSection.edit_url_template,
40900
+ PROXY_PATH: parsedGlobalSection.proxy_path,
40901
+ METADATA_LANGUAGE: parsedGlobalSection.metadata_language
40902
+ ? parsedGlobalSection.metadata_language.toLowerCase()
40903
+ : undefined,
40904
+ LOGIN_URL: parsedGlobalSection.login_url,
40905
+ LOGOUT_URL: parsedGlobalSection.logout_url,
40906
+ SETTINGS_URL: parsedGlobalSection.settings_url,
40907
+ WEB_COMPONENT_EMBEDDER_URL: parsedGlobalSection.web_component_embedder_url,
40908
+ LANGUAGES: parsedGlobalSection.languages,
40909
+ CONTACT_EMAIL: parsedGlobalSection.contact_email,
40910
+ REUSE_FORM_URL: parsedGlobalSection.reuse_form_url,
40911
+ };
40912
+ }
40913
+ function parseMapSection(parsed, { warnings, errors }) {
40914
+ const parsedLayersSections = parseMultiConfigSection(parsed, 'map_layer', ['type'], ['name', 'url', 'data', 'styleUrl', 'accessToken'], warnings, errors);
40915
+ const parsedMapSection = parseConfigSection(parsed, 'map', [], [
40916
+ 'max_zoom',
40917
+ 'do_not_tile_wms',
40918
+ 'max_extent',
40919
+ 'max_feature_count',
40920
+ 'baselayer',
40921
+ 'do_not_use_default_basemap',
40922
+ 'external_viewer_url_template',
40923
+ 'external_viewer_open_new_tab',
40924
+ ], warnings, errors);
40925
+ return parsedMapSection === null || parsedLayersSections === null
40926
+ ? null
40927
+ : {
40928
+ MAX_ZOOM: parsedMapSection.max_zoom,
40929
+ DO_NOT_TILE_WMS: parsedMapSection.do_not_tile_wms,
40930
+ MAX_EXTENT: parsedMapSection.max_extent,
40931
+ MAX_FEATURE_COUNT: parsedMapSection.max_feature_count,
40932
+ EXTERNAL_VIEWER_URL_TEMPLATE: parsedMapSection.external_viewer_url_template,
40933
+ EXTERNAL_VIEWER_OPEN_NEW_TAB: parsedMapSection.external_viewer_open_new_tab,
40934
+ DO_NOT_USE_DEFAULT_BASEMAP: !!parsedMapSection.do_not_use_default_basemap,
40935
+ MAP_LAYERS: parsedLayersSections.map((map_layer) => ({
40936
+ TYPE: map_layer.type,
40937
+ URL: map_layer.url,
40938
+ NAME: map_layer.name,
40939
+ DATA: map_layer.data,
40940
+ STYLE_URL: map_layer.styleUrl,
40941
+ ACCESS_TOKEN: map_layer.accessToken,
40942
+ })),
40943
+ };
40944
+ }
40945
+ function parseThemeSection(parsed, { warnings, errors }) {
40946
+ const parsedThemeSection = parseConfigSection(parsed, 'theme', ['primary_color', 'secondary_color', 'main_color', 'background_color'], [
40947
+ 'header_foreground_color',
40948
+ 'main_font',
40949
+ 'title_font',
40950
+ 'fonts_stylesheet_url',
40951
+ 'thumbnail_placeholder',
40952
+ 'header_background',
40953
+ 'favicon',
40954
+ ], warnings, errors);
40955
+ return parsedThemeSection === null
40956
+ ? null
40957
+ : {
40958
+ PRIMARY_COLOR: parsedThemeSection.primary_color,
40959
+ SECONDARY_COLOR: parsedThemeSection.secondary_color,
40960
+ MAIN_COLOR: parsedThemeSection.main_color,
40961
+ BACKGROUND_COLOR: parsedThemeSection.background_color,
40962
+ HEADER_FOREGROUND_COLOR: parsedThemeSection.header_foreground_color,
40963
+ THUMBNAIL_PLACEHOLDER: parsedThemeSection.thumbnail_placeholder,
40964
+ HEADER_BACKGROUND: parsedThemeSection.header_background,
40965
+ TITLE_FONT: parsedThemeSection.title_font,
40966
+ MAIN_FONT: parsedThemeSection.main_font,
40967
+ FONTS_STYLESHEET_URL: parsedThemeSection.fonts_stylesheet_url,
40968
+ FAVICON: parsedThemeSection.favicon,
40969
+ };
40970
+ }
40971
+ function parseSearchSection(parsed, { warnings, errors }) {
40972
+ const parsedSearchSection = parseConfigSection(parsed, 'search', [], [
40973
+ 'record_kind_quick_filter',
40974
+ 'filter_geometry_data',
40975
+ 'filter_geometry_url',
40976
+ 'do_not_use_default_search_preset',
40977
+ 'search_preset',
40978
+ 'advanced_filters',
40979
+ 'limit',
40980
+ 'spatial_extent_max_file_size',
40981
+ 'geocoding_provider',
40982
+ 'geocoding_provider_options',
40983
+ 'geocoding_provider_labels',
40984
+ ], warnings, errors);
40985
+ const parsedSearchParams = parseMultiConfigSection(parsed, 'search_preset', ['name'], ['sort', 'filters'], warnings, errors);
40986
+ const parsedCustomFilters = parseMultiConfigSection(parsed, 'custom_filter', ['name', 'base_filter'], ['exclude_values', 'include_values', 'label_key'], warnings, errors);
40987
+ const parsedGeocodingProviderLabels = parsedSearchSection?.geocoding_provider_labels;
40988
+ return parsedSearchSection === null
40989
+ ? null
40990
+ : {
40991
+ RECORD_KIND_QUICK_FILTER: parsedSearchSection.record_kind_quick_filter,
40992
+ FILTER_GEOMETRY_DATA: parsedSearchSection.filter_geometry_data,
40993
+ FILTER_GEOMETRY_URL: parsedSearchSection.filter_geometry_url,
40994
+ DO_NOT_USE_DEFAULT_SEARCH_PRESET: !!parsedSearchSection.do_not_use_default_search_preset,
40995
+ SEARCH_PRESET: parsedSearchParams.map((param) => ({
40996
+ sort: param.sort,
40997
+ name: param.name,
40998
+ filters: param.filters,
40999
+ })),
41000
+ ADVANCED_FILTERS: parsedSearchSection.advanced_filters,
41001
+ CUSTOM_FILTERS: (parsedCustomFilters ?? []).map((customFilter) => ({
41002
+ name: customFilter.name,
41003
+ baseFilter: customFilter.base_filter,
41004
+ excludeValues: customFilter.exclude_values,
41005
+ includeValues: customFilter.include_values,
41006
+ labelKey: customFilter.label_key,
41007
+ })),
41008
+ LIMIT: parsedSearchSection.limit,
41009
+ SPATIAL_EXTENT_MAX_FILE_SIZE: parsedSearchSection.spatial_extent_max_file_size,
41010
+ GEOCODING_PROVIDER: parsedSearchSection.geocoding_provider,
41011
+ GEOCODING_PROVIDER_OPTIONS: parsedSearchSection.geocoding_provider_options,
41012
+ GEOCODING_PROVIDER_LABELS: parsedGeocodingProviderLabels
41013
+ ? {
41014
+ MAIN: parsedGeocodingProviderLabels.main,
41015
+ SECONDARY: parsedGeocodingProviderLabels.secondary,
41016
+ TERTIARY: parsedGeocodingProviderLabels.tertiary,
41017
+ }
41018
+ : undefined,
41019
+ };
41020
+ }
41021
+ function parseMetadataQualitySection(parsed, { warnings, errors }) {
41022
+ const parsedMetadataQualitySection = parseConfigSection(parsed, 'metadata-quality', [], ['enabled'], warnings, errors);
41023
+ return parsedMetadataQualitySection === null
41024
+ ? null
41025
+ : {
41026
+ ENABLED: parsedMetadataQualitySection.enabled,
41027
+ SORTABLE: parsedMetadataQualitySection.sortable,
41028
+ };
41029
+ }
41030
+ function parseEditingSection(parsed, { warnings, errors }) {
41031
+ let parsedEditingSection = parseConfigSection(parsed, 'editing', [], ['new_record_default_language', 'new_record_standard'], warnings, errors);
41032
+ if (parsedEditingSection !== null &&
41033
+ parsedEditingSection.new_record_default_language !== undefined) {
41034
+ parsedEditingSection = checkNewRecordDefaultLanguage(parsedEditingSection, warnings);
41035
+ }
41036
+ if (parsedEditingSection !== null &&
41037
+ parsedEditingSection.new_record_standard !== undefined) {
41038
+ parsedEditingSection = checkNewRecordStandard(parsedEditingSection, warnings);
41039
+ }
41040
+ return parsedEditingSection === null
41041
+ ? null
41042
+ : {
41043
+ NEW_RECORD_DEFAULT_LANGUAGE: parsedEditingSection.new_record_default_language,
41044
+ NEW_RECORD_STANDARD: parsedEditingSection.new_record_standard,
41045
+ };
41046
+ }
41047
+ const SECTION_PARSERS = {
41048
+ global: parseGlobalSection,
41049
+ map: parseMapSection,
41050
+ theme: parseThemeSection,
41051
+ search: parseSearchSection,
41052
+ metadataQuality: parseMetadataQualitySection,
41053
+ editor: parseEditingSection,
41054
+ translations: (parsed) => parseTranslationsConfigSection(parsed, 'translations'),
41055
+ };
41056
+ /**
41057
+ * Loads the configuration file and stores the given sections (all by default);
41058
+ * omitted sections are reset (their getters will throw or return null);
41059
+ * resolves with the parsed configuration file, e.g. to read sections with a custom parser
41060
+ */
41061
+ function loadAppConfig(configUrl = 'assets/configuration/default.toml', sections = Object.keys(SECTION_PARSERS)) {
40423
41062
  console.log(`[geonetwork-ui] Loading application configuration from ${configUrl}`);
40424
41063
  return fetch(configUrl)
40425
41064
  .then((resp) => {
@@ -40435,173 +41074,25 @@ function loadAppConfig(configUrl = 'assets/configuration/default.toml') {
40435
41074
  catch (e) {
40436
41075
  throw new Error(`An error occurred when parsing the configuration file: ${e.message}`);
40437
41076
  }
40438
- const errors = [];
40439
- const warnings = [];
40440
- let parsedGlobalSection = parseConfigSection(parsed, 'global', ['geonetwork4_api_url'], [
40441
- 'datahub_url',
40442
- 'edit_url_template',
40443
- 'proxy_path',
40444
- 'metadata_language',
40445
- 'login_url',
40446
- 'logout_url',
40447
- 'settings_url',
40448
- 'web_component_embedder_url',
40449
- 'languages',
40450
- 'contact_email',
40451
- 'reuse_form_url',
40452
- ], warnings, errors);
40453
- if (parsedGlobalSection?.metadata_language) {
40454
- parsedGlobalSection = checkMetadataLanguage(parsedGlobalSection, warnings);
40455
- }
40456
- globalConfig =
40457
- parsedGlobalSection === null
40458
- ? null
40459
- : {
40460
- GN4_API_URL: parsedGlobalSection.geonetwork4_api_url,
40461
- DATAHUB_URL: parsedGlobalSection.datahub_url,
40462
- EDIT_URL_TEMPLATE: parsedGlobalSection.edit_url_template,
40463
- PROXY_PATH: parsedGlobalSection.proxy_path,
40464
- METADATA_LANGUAGE: parsedGlobalSection.metadata_language
40465
- ? parsedGlobalSection.metadata_language.toLowerCase()
40466
- : undefined,
40467
- LOGIN_URL: parsedGlobalSection.login_url,
40468
- LOGOUT_URL: parsedGlobalSection.logout_url,
40469
- SETTINGS_URL: parsedGlobalSection.settings_url,
40470
- WEB_COMPONENT_EMBEDDER_URL: parsedGlobalSection.web_component_embedder_url,
40471
- LANGUAGES: parsedGlobalSection.languages,
40472
- CONTACT_EMAIL: parsedGlobalSection.contact_email,
40473
- REUSE_FORM_URL: parsedGlobalSection.reuse_form_url,
40474
- };
40475
- const parsedLayersSections = parseMultiConfigSection(parsed, 'map_layer', ['type'], ['name', 'url', 'data', 'styleUrl', 'accessToken'], warnings, errors);
40476
- const parsedMapSection = parseConfigSection(parsed, 'map', [], [
40477
- 'max_zoom',
40478
- 'do_not_tile_wms',
40479
- 'max_extent',
40480
- 'max_feature_count',
40481
- 'baselayer',
40482
- 'do_not_use_default_basemap',
40483
- 'external_viewer_url_template',
40484
- 'external_viewer_open_new_tab',
40485
- ], warnings, errors);
40486
- mapConfig =
40487
- parsedMapSection === null || parsedLayersSections === null
40488
- ? null
40489
- : {
40490
- MAX_ZOOM: parsedMapSection.max_zoom,
40491
- DO_NOT_TILE_WMS: parsedMapSection.do_not_tile_wms,
40492
- MAX_EXTENT: parsedMapSection.max_extent,
40493
- MAX_FEATURE_COUNT: parsedMapSection.max_feature_count,
40494
- EXTERNAL_VIEWER_URL_TEMPLATE: parsedMapSection.external_viewer_url_template,
40495
- EXTERNAL_VIEWER_OPEN_NEW_TAB: parsedMapSection.external_viewer_open_new_tab,
40496
- DO_NOT_USE_DEFAULT_BASEMAP: !!parsedMapSection.do_not_use_default_basemap,
40497
- MAP_LAYERS: parsedLayersSections.map((map_layer) => ({
40498
- TYPE: map_layer.type,
40499
- URL: map_layer.url,
40500
- NAME: map_layer.name,
40501
- DATA: map_layer.data,
40502
- STYLE_URL: map_layer.styleUrl,
40503
- ACCESS_TOKEN: map_layer.accessToken,
40504
- })),
40505
- };
40506
- const parsedThemeSection = parseConfigSection(parsed, 'theme', ['primary_color', 'secondary_color', 'main_color', 'background_color'], [
40507
- 'header_foreground_color',
40508
- 'main_font',
40509
- 'title_font',
40510
- 'fonts_stylesheet_url',
40511
- 'thumbnail_placeholder',
40512
- 'header_background',
40513
- 'favicon',
40514
- ], warnings, errors);
40515
- themeConfig =
40516
- parsedThemeSection === null
40517
- ? null
40518
- : {
40519
- PRIMARY_COLOR: parsedThemeSection.primary_color,
40520
- SECONDARY_COLOR: parsedThemeSection.secondary_color,
40521
- MAIN_COLOR: parsedThemeSection.main_color,
40522
- BACKGROUND_COLOR: parsedThemeSection.background_color,
40523
- HEADER_FOREGROUND_COLOR: parsedThemeSection.header_foreground_color,
40524
- THUMBNAIL_PLACEHOLDER: parsedThemeSection.thumbnail_placeholder,
40525
- HEADER_BACKGROUND: parsedThemeSection.header_background,
40526
- TITLE_FONT: parsedThemeSection.title_font,
40527
- MAIN_FONT: parsedThemeSection.main_font,
40528
- FONTS_STYLESHEET_URL: parsedThemeSection.fonts_stylesheet_url,
40529
- FAVICON: parsedThemeSection.favicon,
40530
- };
40531
- const parsedSearchSection = parseConfigSection(parsed, 'search', [], [
40532
- 'record_kind_quick_filter',
40533
- 'filter_geometry_data',
40534
- 'filter_geometry_url',
40535
- 'do_not_use_default_search_preset',
40536
- 'search_preset',
40537
- 'advanced_filters',
40538
- 'limit',
40539
- 'spatial_extent_max_file_size',
40540
- 'geocoding_provider',
40541
- 'geocoding_provider_options',
40542
- ], warnings, errors);
40543
- const parsedSearchParams = parseMultiConfigSection(parsed, 'search_preset', ['name'], ['sort', 'filters'], warnings, errors);
40544
- const parsedCustomFilters = parseMultiConfigSection(parsed, 'custom_filter', ['name', 'base_filter'], ['exclude_values', 'include_values', 'label_key'], warnings, errors);
40545
- searchConfig =
40546
- parsedSearchSection === null
40547
- ? null
40548
- : {
40549
- RECORD_KIND_QUICK_FILTER: parsedSearchSection.record_kind_quick_filter,
40550
- FILTER_GEOMETRY_DATA: parsedSearchSection.filter_geometry_data,
40551
- FILTER_GEOMETRY_URL: parsedSearchSection.filter_geometry_url,
40552
- DO_NOT_USE_DEFAULT_SEARCH_PRESET: !!parsedSearchSection.do_not_use_default_search_preset,
40553
- SEARCH_PRESET: parsedSearchParams.map((param) => ({
40554
- sort: param.sort,
40555
- name: param.name,
40556
- filters: param.filters,
40557
- })),
40558
- ADVANCED_FILTERS: parsedSearchSection.advanced_filters,
40559
- CUSTOM_FILTERS: parsedCustomFilters.map((customFilter) => ({
40560
- name: customFilter.name,
40561
- baseFilter: customFilter.base_filter,
40562
- excludeValues: customFilter.exclude_values,
40563
- includeValues: customFilter.include_values,
40564
- labelKey: customFilter.label_key,
40565
- })),
40566
- LIMIT: parsedSearchSection.limit,
40567
- SPATIAL_EXTENT_MAX_FILE_SIZE: parsedSearchSection.spatial_extent_max_file_size,
40568
- GEOCODING_PROVIDER: parsedSearchSection.geocoding_provider,
40569
- GEOCODING_PROVIDER_OPTIONS: parsedSearchSection.geocoding_provider_options,
40570
- };
40571
- const parsedMetadataQualitySection = parseConfigSection(parsed, 'metadata-quality', [], ['enabled'], warnings, errors);
40572
- metadataQualityConfig =
40573
- parsedMetadataQualitySection === null
40574
- ? null
40575
- : {
40576
- ENABLED: parsedMetadataQualitySection.enabled,
40577
- SORTABLE: parsedMetadataQualitySection.sortable,
40578
- };
40579
- let parsedEditingSection = parseConfigSection(parsed, 'editing', [], ['new_record_default_language', 'new_record_standard'], warnings, errors);
40580
- if (parsedEditingSection !== null &&
40581
- parsedEditingSection.new_record_default_language !== undefined) {
40582
- parsedEditingSection = checkNewRecordDefaultLanguage(parsedEditingSection, warnings);
40583
- }
40584
- if (parsedEditingSection !== null &&
40585
- parsedEditingSection.new_record_standard !== undefined) {
40586
- parsedEditingSection = checkNewRecordStandard(parsedEditingSection, warnings);
40587
- }
40588
- editorConfig =
40589
- parsedEditingSection === null
40590
- ? null
40591
- : {
40592
- NEW_RECORD_DEFAULT_LANGUAGE: parsedEditingSection.new_record_default_language,
40593
- NEW_RECORD_STANDARD: parsedEditingSection.new_record_standard,
40594
- };
40595
- customTranslations = parseTranslationsConfigSection(parsed, 'translations');
40596
- if (errors.length) {
41077
+ const issues = { warnings: [], errors: [] };
41078
+ const config = Object.fromEntries(sections.map((name) => [name, SECTION_PARSERS[name](parsed, issues)]));
41079
+ if (issues.errors.length) {
40597
41080
  throw new Error(`One or more mandatory settings were missing from the configuration file.
40598
- ${errors.join('\n')}`);
41081
+ ${issues.errors.join('\n')}`);
40599
41082
  }
40600
- else if (warnings.length) {
41083
+ else if (issues.warnings.length) {
40601
41084
  console.warn(`One or more unexpected settings were encountered in the configuration file.
40602
- ${warnings.join('\n')}`);
40603
- }
41085
+ ${issues.warnings.join('\n')}`);
41086
+ }
41087
+ globalConfig = config.global ?? null;
41088
+ themeConfig = config.theme ?? null;
41089
+ mapConfig = config.map ?? null;
41090
+ searchConfig = config.search ?? null;
41091
+ metadataQualityConfig = config.metadataQuality ?? null;
41092
+ editorConfig = config.editor ?? null;
41093
+ customTranslations = config.translations ?? {};
40604
41094
  appConfigLoaded = true;
41095
+ return parsed;
40605
41096
  });
40606
41097
  }
40607
41098
  function isConfigLoaded() {
@@ -40610,8 +41101,12 @@ function isConfigLoaded() {
40610
41101
  function _reset() {
40611
41102
  globalConfig = null;
40612
41103
  themeConfig = null;
41104
+ mapConfig = null;
41105
+ searchConfig = null;
41106
+ metadataQualityConfig = null;
40613
41107
  editorConfig = null;
40614
41108
  customTranslations = null;
41109
+ appConfigLoaded = false;
40615
41110
  }
40616
41111
  const TRANSLATE_WITH_OVERRIDES_CONFIG = {
40617
41112
  compiler: {
@@ -40676,8 +41171,12 @@ record_kind_quick_filter = false
40676
41171
  filter_geometry_url = 'https://my.domain.org/geom.json'
40677
41172
  do_not_use_default_search_preset = false
40678
41173
  geocoding_provider = "geoplateforme"
41174
+ geocoding_provider_options.index = "poi"
40679
41175
  geocoding_provider_options.category = "administratif"
40680
41176
  geocoding_provider_options.limit = 5
41177
+ geocoding_provider_labels.main = '/properties/name/0'
41178
+ geocoding_provider_labels.secondary = '/properties/citycode/0'
41179
+ geocoding_provider_labels.tertiary = '/properties/category/1'
40681
41180
  advanced_filters = ['publicationYear', 'documentStandard', 'inspireKeyword', 'topic', 'license', 'myOrg:firstCustomFilter', 'myOrg:secondCustomFilter']
40682
41181
 
40683
41182
  [[custom_filter]]
@@ -40727,6 +41226,22 @@ secondary_color = "#c2e9dc"
40727
41226
  main_color = "#212029" # All-purpose text color
40728
41227
  background_color = "#fdfbff"
40729
41228
  `;
41229
+ const customFilterMissingMandatoryConfigFixture = () => `
41230
+ [global]
41231
+ geonetwork4_api_url = "/geonetwork/srv/api"
41232
+
41233
+ [theme]
41234
+ primary_color = "#093564"
41235
+ secondary_color = "#c2e9dc"
41236
+ main_color = "#212029" # All-purpose text color
41237
+ background_color = "#fdfbff"
41238
+
41239
+ [search]
41240
+ advanced_filters = ['myOrg:firstCustomFilter']
41241
+
41242
+ [[custom_filter]]
41243
+ name = 'myOrg:firstCustomFilter'
41244
+ `;
40730
41245
  const mapConfigFixture = () => ({
40731
41246
  MAX_ZOOM: 10,
40732
41247
  MAX_EXTENT: [-418263.418776, 5251529.591305, 961272.067714, 6706890.609855],
@@ -40862,5 +41377,5 @@ const CHART_TYPE_VALUES = [
40862
41377
  * Generated bundle index. Do not edit.
40863
41378
  */
40864
41379
 
40865
- export { ADD_RESULTS, ADD_SEARCH, AVAILABLE_LICENSES, AbstractAction, AbstractSearchField, ActionMenuComponent, AddLayerFromCatalogComponent, AddLayerRecordPreviewComponent, AddResults, AddSearch, AnchorLinkDirective, ApiCardComponent, ApplicationBannerComponent, AuthService, AutocompleteComponent, AutofocusDirective, AvailableServicesField, AvatarComponent, AvatarServiceInterface, BASEMAP_LAYERS, BadgeComponent, BaseConverter, BaseFileReader, BaseReader, BlockListComponent, BoundingBoxSearchField, ButtonComponent, CHART_TYPE_VALUES, CLEAR_ERROR, CLEAR_RESULTS, CarouselComponent, CatalogTitleComponent, CellPopinComponent, ChartComponent, ChartViewComponent, CheckToggleComponent, CheckboxComponent, ClearError, ClearResults, ColorScaleComponent, ConfirmationDialogComponent, ContactDetailsComponent, ContactDetailsFormComponent, ContactPillComponent, ContentGhostComponent, CopyTextButtonComponent, DEFAULT_BASEMAP_LAYER, DEFAULT_CONFIGURATION, DEFAULT_GEOCODING_PROVIDER, DEFAULT_GN4_LOGIN_URL, DEFAULT_GN4_LOGOUT_URL, DEFAULT_GN4_SETTINGS_URL, DEFAULT_LANG, DEFAULT_PAGE_SIZE, DEFAULT_RECORD_CONVERTER, DEFAULT_RESULTS_LAYOUT_CONFIG, DEFAULT_SEARCH_KEY, DEFAULT_SPATIAL_EXTENT_STYLE, DISABLE_AUTH, DISABLE_DRAFT, DO_NOT_USE_DEFAULT_BASEMAP, DataService, DataTableComponent, DataViewComponent, DataViewPermalinkComponent, DataViewShareComponent, DataViewWebComponentComponent, DatePickerComponent, DateRangeDropdownComponent, DateRangeInputsComponent, DateRangePickerComponent, DateRangeSearchField, DateService, DcatApConverter, DefaultRouterModule, DownloadItemComponent, DownloadsListComponent, DragAndDropFileInputComponent, DropdownMultiselectComponent, DropdownSelectorComponent, EDITOR_FEATURE_KEY, ES_QUERY_FIELDS_PRIORITY, ES_RESOURCES_VALUES, ES_SOURCE_SUMMARY, EXTERNAL_VIEWER_OPEN_NEW_TAB, EXTERNAL_VIEWER_URL_TEMPLATE, EditableLabelDirective, EditorFacade, EditorService, ElasticsearchService, ErrorComponent, ErrorType, ExpandablePanelButtonComponent, ExpandablePanelComponent, ExternalLinkCardComponent, ExternalViewerButtonComponent, FIELDS_BRIEF, FIELDS_SUMMARY, FILTER_GEOMETRY, FILTER_SUMMARY_IGNORE_LIST, FORMATS, FacetBlockComponent, FacetItemComponent, FacetListComponent, FacetsContainerComponent, FavoriteStarComponent, FavoritesService, FeatureCatalogListComponent, FeatureDetailComponent, FeatureEditorModule, FeatureMapModule, FeatureRecordModule, FeatureSearchModule, FetchError, FieldFocusDirective, FieldsService, FigureComponent, FigureContainerComponent, FileInputComponent, FileTranslateLoader, FilesDropDirective, FilterDropdownComponent, FormFieldArrayComponent, FormFieldComponent, FormFieldDateComponent, FormFieldFileComponent, FormFieldKeywordsComponent, FormFieldLicenseComponent, FormFieldObjectComponent, FormFieldRichComponent, FormFieldSimpleComponent, FormFieldSpatialExtentComponent, FormFieldTemporalExtentsComponent, FormFieldTopicsComponent, FormFieldWrapperComponent, FullTextSearchField, FuzzySearchComponent, GEOCODING_PROVIDER, GEONETWORK_UI_TAG_NAME, GEONETWORK_UI_VERSION, GeoDataBadgeComponent, GeoTableViewComponent, GeocodingService, GeojsonReader, Gn4Converter, Gn4PlatformMapper, Gn4PlatformService, Gn4Repository, Gn4SettingsService, GnUiHumanizeDateDirective, GpfApiDlComponent, GravatarService, I18nInterceptor, ISO_TOPICS, ImageFallbackDirective, ImageInputComponent, ImageOverlayPreviewComponent, ImportRecordComponent, InlineFilterComponent, InteractiveTableColumnComponent, InteractiveTableComponent, InternalLinkCardComponent, IsSpatialSearchField, Iso191153Converter, Iso19139Converter, KeywordBadgeComponent, KindBadgeComponent, LANGUAGES_LIST, LANGUAGE_NAMES, LANGUAGE_STORAGE_KEY, LANG_2_TO_3_MAPPER, LOGIN_URL, LOGOUT_URL, LONLAT_CRS_CODES, LanguageSwitcherComponent, LayersPanelComponent, LicenseSearchField, LinkClassifierService, LinkUsage, LoadingMaskComponent, LocationSearchComponent, LogService, MAP_FEATURE_KEY, MAP_VIEW_CONSTRAINTS, MAX_UPLOAD_SIZE_MB, METADATA_LANGUAGE, MapContainerComponent, MapFacade, MapLegendComponent, MapStateContainerComponent, MapUtilsService, MapViewComponent, MarkdownEditorComponent, MarkdownParserComponent, MaxLinesComponent, mdview_actions as MdViewActions, MdViewFacade, MetadataCatalogComponent, MetadataContactComponent, MetadataDoiComponent, MetadataInfoComponent, MetadataLinkType, MetadataMapperContext, MetadataQualityComponent, MetadataQualityItemComponent, MetadataQualityPanelComponent, ModalDialogComponent, MultilingualPanelComponent, MultilingualSearchField, MyOrgService, NAMESPACES, NOT_APPLICABLE_CONSTRAINT, NOT_KNOWN_CONSTRAINT, NotificationComponent, NotificationsContainerComponent, NotificationsService, OPEN_DATA_LICENSE, ORGANIZATIONS_STRATEGY, ORGANIZATION_PAGE_URL_TOKEN, ORGANIZATION_URL_TOKEN, OnlineResourceCardComponent, OnlineServiceResourceInputComponent, OrganisationPreviewComponent, OrganisationsComponent, OrganisationsFilterComponent, OrganisationsResultComponent, OrganizationSearchField, OrganizationsFromGroupsService, OrganizationsFromMetadataService, OrganizationsServiceInterface, OwnerSearchField, PAGINATE, PARSE_DELIMITER, PATCH_RESULTS_AGGREGATIONS, PROXY_PATH, Paginate, PaginationButtonsComponent, PaginationComponent, PaginationDotsComponent, PatchResultsAggregations, PlatformServiceInterface, PopoverComponent, PopupAlertComponent, PossibleResourceTypes, PossibleResourceTypesDefinition, PreviousNextButtonsComponent, ProgressBarComponent, ProxyService, QUERY_FIELDS, RECORD_DATASET_URL_TOKEN, RECORD_REUSE_URL_TOKEN, RECORD_SERVICE_URL_TOKEN, REQUEST_MORE_ON_AGGREGATION, REQUEST_MORE_RESULTS, REQUEST_NEW_RESULTS, RESULTS_LAYOUT_CONFIG, REUSE_LIGHT_CONFIGURATION, ROUTER_CONFIG, ROUTER_ROUTE_DATASET, ROUTER_ROUTE_ORGANIZATION, ROUTER_ROUTE_REUSE, ROUTER_ROUTE_SEARCH, ROUTER_ROUTE_SERVICE, ROUTER_STATE_KEY, ROUTE_PARAMS, RecordApiFormComponent, RecordFormComponent, RecordKindField, RecordMetaComponent, RecordMetricComponent, RecordPreviewCardComponent, RecordPreviewComponent, RecordPreviewFeedComponent, RecordPreviewListComponent, RecordPreviewRowComponent, RecordPreviewTextComponent, RecordPreviewTitleComponent, RecordStatusValues, RecordsMetricsComponent, RecordsRepositoryInterface, RecordsService, RequestMoreOnAggregation, RequestMoreResults, RequestNewResults, ResourceCreationRevisionDateSearchField, ResourceTypeLegacyField, ResultsHitsContainerComponent, ResultsHitsNumberComponent, ResultsHitsSearchKindComponent, ResultsLayoutComponent, ResultsLayoutConfigItem, ResultsListComponent, ResultsListContainerComponent, ResultsListItemComponent, ResultsTableComponent, ResultsTableContainerComponent, ReusePresentationForms, RoleLabels, RoleValues, RouterEffects, RouterFacade, RouterService, SEARCH_FEATURE_KEY, SETTINGS_URL, SET_CONFIG_AGGREGATIONS, SET_CONFIG_FILTERS, SET_CONFIG_REQUEST_FIELDS, SET_ERROR, SET_FAVORITES_ONLY, SET_FILTERS, SET_INCLUDE_ON_AGGREGATION, SET_PAGE_SIZE, SET_RESULTS_AGGREGATIONS, SET_RESULTS_HITS, SET_RESULTS_LAYOUT, SET_SEARCH, SET_SORT_BY, SET_SPATIAL_FILTER_ENABLED, SPATIAL_EXTENT_MAX_FILE_SIZE, SPATIAL_SCOPES, SearchEffects, SearchFacade, SearchFeatureCatalogComponent, SearchFiltersSummaryComponent, SearchFiltersSummaryItemComponent, SearchInputComponent, SearchRouterContainerDirective, SearchService, SearchStateContainerDirective, SelectionService, ServiceCapabilitiesComponent, SetConfigAggregations, SetConfigFilters, SetConfigRequestFields, SetError, SetFavoritesOnly, SetFilters, SetIncludeOnAggregation, SetPageSize, SetResultsAggregations, SetResultsHits, SetResultsLayout, SetSearch, SetSortBy, SetSpatialFilterEnabled, SimpleSearchField, SiteTitleComponent, SortByComponent, SortByEnum, SortableListComponent, SourceLabelComponent, SourcesService, SpatialExtentComponent, SpatialExtentDropdownComponent, SpinningLoaderComponent, StacItemsResultGridComponent, StacViewComponent, StarToggleComponent, StickyHeaderComponent, SupportedTypes, SwitchToggleComponent, THUMBNAIL_PLACEHOLDER, TRANSLATE_DEBUG_CONFIG, TRANSLATE_DEFAULT_CONFIG, TRANSLATE_WITH_OVERRIDES_CONFIG, TableViewComponent, TextAreaComponent, TextInputComponent, ThemeService, ThumbnailComponent, TranslatedSearchField, TruncatedTextComponent, UPDATE_CONFIG_AGGREGATIONS, UPDATE_FILTERS, UPDATE_REQUEST_AGGREGATION_TERM, UpdateConfigAggregations, UpdateFilters, UrlInputComponent, UserFeedbackItemComponent, UserPreviewComponent, UserSearchField, VECTOR_STYLE_DEFAULT, ViewportIntersectorComponent, WEB_COMPONENT_EMBEDDER_URL, XmlParseError, _reset, allChildrenElement, appConfigWithTranslationFixture, appendChildTree, appendChildren, assertValidXml, associationTypeValues, bboxToPolygon, blockModelFixture, bytesToMegabytes, canEditRecord, checkFileFormat, clearSelectedFeatures, createChild, createDocument, createElement, createFuzzyFilter, createNestedChild, createNestedElement, createSpatialExtentLayer, currentPage, downgradeImage, downsizeImage, draftSaveSuccess, dragPanCondition, dropEmptyTranslations, editorReducer, emptyBlockModelFixture, findChildElement, findChildOrCreate, findChildrenElement, findConverterForDocument, findNestedChildOrCreate, findNestedElement, findNestedElements, findParent, firstChildElement, formatDate, formatUserInfo, getAddressLines, getAllKeysValidator, getArrayItem, getAsArray, getAsUrl, getBadgeColor, getCustomTranslations, getError, getFavoritesOnly, getFileFormat, getFileFormatFromServiceOutput, getFirstValue, getFormatPriority, getGeometryBoundingBox, getGeometryFromGeoJSON, getGlobalConfig, getIndividualDisplayName, getIsMobile, getJsonDataItemsProxy, getKeywordHierarchyPath, getLayers, getLinkId, getLinkLabel, getLinkPriority, getMapContext, getMapContextLayerFromConfig, getMapState, getMetadataQualityConfig, getMimeTypeForFormat, getNamespace, getOptionalEditorConfig, getOptionalMapConfig, getOptionalSearchConfig, getPageSize, getQualityValidators, getResourceType, getReusePresentationForm, getReuseType, getRootElement, getSearchConfigAggregations, getSearchFilters, getSearchResults, getSearchResultsAggregations, getSearchResultsHits, getSearchResultsLayout, getSearchResultsLoading, getSearchSortBy, getSearchState, getSearchStateSearch, getSelectedFeatures, getSpatialFilterEnabled, getTemporalRangeUnion, getThemeConfig, handleScrollOnNavigation, hasRecordChangedSinceDraft, hasRecordChangedSinceDraftSuccess, initSearch, initialEditorState, initialMapState, initialState, isBoundingBox, isBoundingBoxWithinWorldExtent, isConfigLoaded, isDateRange, isFileExtensionValid, isFormatInQueryParam, isPublished, itemModelFixture, kindToCodeListValue, loadAppConfig, malformedConfigFixture, mapConfigFixture, mapContact, mapKeywords, mapLogo, mapOrganization, mapReducer, markRecordAsChanged, matchesNoApplicableConstraint, matchesNoKnownConstraint, megabytesToBytes, mimeTypeToFormat, minimalAppConfigFixture, missingMandatoryConfigFixture, mouseWheelZoomCondition, noDuplicateFileName, okAppConfigFixture, openDataset, openRecord, organizationsServiceFactory, parse, parseXmlString, placeholder, prioritizePageScroll, propagateToDocumentOnly, provideGn4, provideI18n, provideLocalizedDateAdapter, provideRepositoryUrl, readAttribute, readDataset, readDatasetHeaders, readFileAsText, readText, reducer$2 as reducer, reducerSearch, removeAllChildren, removeChildren, removeChildrenByName, removeSearchParams, removeWhitespace, renameElements, saveRecord, saveRecordFailure, saveRecordSuccess, selectCanEditRecord, selectCurrentPage, selectEditorConfig, selectEditorState, selectFallback, selectFallbackFields, selectField, selectHasRecordChanged, selectIsPublished, selectRecord, selectRecordChangedSinceSave, selectRecordSaveError, selectRecordSaving, selectRecordSections, selectRecordSource, selectTranslatedField, selectTranslatedValue, setContext, setCurrentPage, setEditorConfiguration, setFieldVisibility, setFocusedField, setSelectedFeatures, setTextContent, sortByFromString, sortByToString, sortByToStrings, spatialExtentToGeometry, spatialExtentsToFeatureCollection, stripHtml, stripNamespace, toDate, toIndividual, toLang2, toLang3, totalPages, undoRecordDraft, unrecognizedKeysConfigFixture, updateFrequencyCodeValues, updateLanguages, updateRecordField, updateRecordLanguages, wmsLayerFlatten, writeAttribute, wrongLanguageCodeConfigFixture, xmlToString };
41380
+ export { ADD_RESULTS, ADD_SEARCH, AVAILABLE_LICENSES, AbstractAction, AbstractSearchField, ActionMenuComponent, AddLayerFromCatalogComponent, AddLayerRecordPreviewComponent, AddResults, AddSearch, AnchorLinkDirective, ApiCardComponent, ApplicationBannerComponent, AuthService, AutocompleteComponent, AutofocusDirective, AvailableServicesField, AvatarComponent, AvatarServiceInterface, BASEMAP_LAYERS, BadgeComponent, BaseConverter, BaseFileReader, BaseReader, BlockListComponent, BoundingBoxSearchField, ButtonComponent, CHART_TYPE_VALUES, CLEAR_ERROR, CLEAR_RESULTS, CUSTOM_FIELDS, CarouselComponent, CatalogTitleComponent, CellPopinComponent, ChartComponent, ChartViewComponent, CheckToggleComponent, CheckboxComponent, ClearError, ClearResults, ColorScaleComponent, ConfirmationDialogComponent, ContactDetailsComponent, ContactDetailsFormComponent, ContactPillComponent, ContentGhostComponent, CopyTextButtonComponent, DEFAULT_BASEMAP_LAYER, DEFAULT_CONFIGURATION, DEFAULT_GEOCODING_PROVIDER, DEFAULT_GN4_LOGIN_URL, DEFAULT_GN4_LOGOUT_URL, DEFAULT_GN4_SETTINGS_URL, DEFAULT_LANG, DEFAULT_PAGE_SIZE, DEFAULT_RECORD_CONVERTER, DEFAULT_RESULTS_LAYOUT_CONFIG, DEFAULT_SEARCH_KEY, DEFAULT_SPATIAL_EXTENT_STYLE, DISABLE_AUTH, DISABLE_DRAFT, DO_NOT_USE_DEFAULT_BASEMAP, DataService, DataTableComponent, DataViewComponent, DataViewPermalinkComponent, DataViewShareComponent, DataViewWebComponentComponent, DatePickerComponent, DateRangeDropdownComponent, DateRangeInputsComponent, DateRangePickerComponent, DateRangeSearchField, DateService, DcatApConverter, DefaultRouterModule, DownloadItemComponent, DownloadsListComponent, DragAndDropFileInputComponent, DropdownMultiselectComponent, DropdownSelectorComponent, EDITOR_FEATURE_KEY, ES_QUERY_FIELDS_PRIORITY, ES_RESOURCES_VALUES, ES_SOURCE_SUMMARY, EXTERNAL_VIEWER_OPEN_NEW_TAB, EXTERNAL_VIEWER_URL_TEMPLATE, EditableLabelDirective, EditorFacade, EditorService, ElasticsearchService, ErrorComponent, ErrorType, ExpandablePanelButtonComponent, ExpandablePanelComponent, ExternalLinkCardComponent, ExternalViewerButtonComponent, FIELDS_BRIEF, FIELDS_SUMMARY, FILTER_GEOMETRY, FILTER_SUMMARY_IGNORE_LIST, FORMATS, FacetBlockComponent, FacetItemComponent, FacetListComponent, FacetsContainerComponent, FavoriteStarComponent, FavoritesService, FeatureCatalogListComponent, FeatureDetailComponent, FeatureEditorModule, FeatureMapModule, FeatureRecordModule, FeatureSearchModule, FetchError, FieldFocusDirective, FieldsService, FigureComponent, FigureContainerComponent, FileInputComponent, FileTranslateLoader, FilesDropDirective, FilterDropdownComponent, FormFieldArrayComponent, FormFieldComponent, FormFieldDateComponent, FormFieldFileComponent, FormFieldKeywordsComponent, FormFieldLicenseComponent, FormFieldObjectComponent, FormFieldRichComponent, FormFieldSimpleComponent, FormFieldSpatialExtentComponent, FormFieldTemporalExtentsComponent, FormFieldTopicsComponent, FormFieldWrapperComponent, FullTextSearchField, FuzzySearchComponent, GEOCODING_PROVIDER, GEOCODING_PROVIDER_LABELS, GEONETWORK_UI_TAG_NAME, GEONETWORK_UI_VERSION, GeoDataBadgeComponent, GeoTableViewComponent, GeocodingService, GeojsonReader, Gn4Converter, Gn4PlatformMapper, Gn4PlatformService, Gn4Repository, Gn4SettingsService, GnUiHumanizeDateDirective, GpfApiDlComponent, GravatarService, I18nInterceptor, ISO_TOPICS, ImageFallbackDirective, ImageInputComponent, ImageOverlayPreviewComponent, ImportRecordComponent, InlineFilterComponent, InteractiveTableColumnComponent, InteractiveTableComponent, InternalLinkCardComponent, IsSpatialSearchField, Iso191153Converter, Iso19139Converter, KeywordBadgeComponent, KindBadgeComponent, LANGUAGES_LIST, LANGUAGE_NAMES, LANGUAGE_STORAGE_KEY, LANG_2_TO_3_MAPPER, LOGIN_URL, LOGOUT_URL, LONLAT_CRS_CODES, LanguageSwitcherComponent, LayersPanelComponent, LicenseSearchField, LinkClassifierService, LinkUsage, LoadingMaskComponent, LocationSearchComponent, LogService, MAP_FEATURE_KEY, MAP_VIEW_CONSTRAINTS, MAX_UPLOAD_SIZE_MB, METADATA_LANGUAGE, MapContainerComponent, MapFacade, MapLegendComponent, MapStateContainerComponent, MapUtilsService, MapViewComponent, MarkdownEditorComponent, MarkdownParserComponent, MaxLinesComponent, mdview_actions as MdViewActions, MdViewFacade, MetadataCatalogComponent, MetadataContactComponent, MetadataDoiComponent, MetadataInfoComponent, MetadataLinkType, MetadataMapperContext, MetadataQualityComponent, MetadataQualityItemComponent, MetadataQualityPanelComponent, ModalDialogComponent, MultilingualPanelComponent, MultilingualSearchField, MyOrgService, NAMESPACES, NOT_APPLICABLE_CONSTRAINT, NOT_KNOWN_CONSTRAINT, NotificationComponent, NotificationsContainerComponent, NotificationsService, OPEN_DATA_LICENSE, ORGANIZATIONS_STRATEGY, ORGANIZATION_PAGE_URL_TOKEN, ORGANIZATION_URL_TOKEN, OnlineResourceCardComponent, OnlineServiceResourceInputComponent, OrganisationPreviewComponent, OrganisationsComponent, OrganisationsFilterComponent, OrganisationsResultComponent, OrganizationSearchField, OrganizationsFromGroupsService, OrganizationsFromMetadataService, OrganizationsServiceInterface, OwnerSearchField, PAGINATE, PARSE_DELIMITER, PATCH_RESULTS_AGGREGATIONS, PROXY_PATH, Paginate, PaginationButtonsComponent, PaginationComponent, PaginationDotsComponent, PatchResultsAggregations, PlatformServiceInterface, PopoverComponent, PopupAlertComponent, PossibleResourceTypes, PossibleResourceTypesDefinition, PreviousNextButtonsComponent, ProgressBarComponent, ProxyService, QUERY_FIELDS, RECORD_DATASET_URL_TOKEN, RECORD_FLAG_CATEGORY_PREFIX, RECORD_REUSE_URL_TOKEN, RECORD_SERVICE_URL_TOKEN, REFERENCE_DATASET_BOOST, REQUEST_MORE_ON_AGGREGATION, REQUEST_MORE_RESULTS, REQUEST_NEW_RESULTS, RESULTS_LAYOUT_CONFIG, REUSE_LIGHT_CONFIGURATION, ROUTER_CONFIG, ROUTER_ROUTE_DATASET, ROUTER_ROUTE_ORGANIZATION, ROUTER_ROUTE_REUSE, ROUTER_ROUTE_SEARCH, ROUTER_ROUTE_SERVICE, ROUTER_STATE_KEY, ROUTE_PARAMS, RecordApiFormComponent, RecordFormComponent, RecordKindField, RecordMetaComponent, RecordMetricComponent, RecordPreviewCardComponent, RecordPreviewComponent, RecordPreviewFeedComponent, RecordPreviewListComponent, RecordPreviewRowComponent, RecordPreviewTextComponent, RecordPreviewTitleComponent, RecordStatusValues, RecordsMetricsComponent, RecordsRepositoryInterface, RecordsService, RequestMoreOnAggregation, RequestMoreResults, RequestNewResults, ResourceCreationRevisionDateSearchField, ResourceTypeLegacyField, ResultsHitsContainerComponent, ResultsHitsNumberComponent, ResultsHitsSearchKindComponent, ResultsLayoutComponent, ResultsLayoutConfigItem, ResultsListComponent, ResultsListContainerComponent, ResultsListItemComponent, ResultsTableComponent, ResultsTableContainerComponent, ReusePresentationForms, RoleLabels, RoleValues, RouterEffects, RouterFacade, RouterService, SEARCH_FEATURE_KEY, SETTINGS_URL, SET_CONFIG_AGGREGATIONS, SET_CONFIG_FILTERS, SET_CONFIG_REQUEST_FIELDS, SET_ERROR, SET_FAVORITES_ONLY, SET_FILTERS, SET_INCLUDE_ON_AGGREGATION, SET_PAGE_SIZE, SET_RESULTS_AGGREGATIONS, SET_RESULTS_HITS, SET_RESULTS_LAYOUT, SET_SEARCH, SET_SORT_BY, SET_SPATIAL_FILTER_ENABLED, SPATIAL_EXTENT_MAX_FILE_SIZE, SPATIAL_SCOPES, SearchEffects, SearchFacade, SearchFeatureCatalogComponent, SearchFiltersSummaryComponent, SearchFiltersSummaryItemComponent, SearchInputComponent, SearchRouterContainerDirective, SearchService, SearchStateContainerDirective, SelectionService, ServiceCapabilitiesComponent, SetConfigAggregations, SetConfigFilters, SetConfigRequestFields, SetError, SetFavoritesOnly, SetFilters, SetIncludeOnAggregation, SetPageSize, SetResultsAggregations, SetResultsHits, SetResultsLayout, SetSearch, SetSortBy, SetSpatialFilterEnabled, SimpleSearchField, SiteTitleComponent, SortByComponent, SortByEnum, SortableListComponent, SourceLabelComponent, SourcesService, SpatialExtentComponent, SpatialExtentDropdownComponent, SpinningLoaderComponent, StacItemsResultGridComponent, StacViewComponent, StarToggleComponent, StickyHeaderComponent, SupportedTypes, SwitchToggleComponent, THUMBNAIL_PLACEHOLDER, TRANSLATE_DEBUG_CONFIG, TRANSLATE_DEFAULT_CONFIG, TRANSLATE_WITH_OVERRIDES_CONFIG, TableViewComponent, TextAreaComponent, TextInputComponent, ThemeService, ThumbnailComponent, TranslatedSearchField, TruncatedTextComponent, UPDATE_CONFIG_AGGREGATIONS, UPDATE_FILTERS, UPDATE_REQUEST_AGGREGATION_TERM, UpdateConfigAggregations, UpdateFilters, UrlInputComponent, UserFeedbackItemComponent, UserPreviewComponent, UserSearchField, VECTOR_STYLE_DEFAULT, ViewportIntersectorComponent, WEB_COMPONENT_EMBEDDER_URL, XmlParseError, _reset, allChildrenElement, appConfigWithTranslationFixture, appendChildTree, appendChildren, assertValidXml, associationTypeValues, bboxToGeometry, blockModelFixture, bytesToMegabytes, canEditRecord, checkFileFormat, checkMetadataLanguage, checkNewRecordDefaultLanguage, checkNewRecordStandard, clearSelectedFeatures, createChild, createDocument, createElement, createFuzzyFilter, createNestedChild, createNestedElement, createSpatialExtentLayer, currentPage, customFilterMissingMandatoryConfigFixture, downgradeImage, downsizeImage, draftSaveSuccess, dragPanCondition, dropEmptyTranslations, editorReducer, emptyBlockModelFixture, findChildElement, findChildOrCreate, findChildrenElement, findConverterForDocument, findNestedChildOrCreate, findNestedElement, findNestedElements, findParent, firstChildElement, formatDate, formatUserInfo, getAddressLines, getAllKeysValidator, getArrayItem, getAsArray, getAsUrl, getBadgeColor, getCustomTranslations, getError, getFavoritesOnly, getFileFormat, getFileFormatFromServiceOutput, getFirstValue, getFormatPriority, getGeometryBoundingBox, getGeometryFromGeoJSON, getGlobalConfig, getIndividualDisplayName, getIsMobile, getJsonDataItemsProxy, getKeywordHierarchyPath, getLayers, getLinkId, getLinkLabel, getLinkPriority, getMapContext, getMapContextLayerFromConfig, getMapState, getMetadataQualityConfig, getMimeTypeForFormat, getNamespace, getOptionalEditorConfig, getOptionalMapConfig, getOptionalSearchConfig, getPageSize, getQualityValidators, getResourceType, getReusePresentationForm, getReuseType, getRootElement, getSearchConfigAggregations, getSearchFilters, getSearchResults, getSearchResultsAggregations, getSearchResultsHits, getSearchResultsLayout, getSearchResultsLoading, getSearchSortBy, getSearchState, getSearchStateSearch, getSelectedFeatures, getSpatialFilterEnabled, getTemporalRangeUnion, getThemeConfig, handleScrollOnNavigation, hasRecordChangedSinceDraft, hasRecordChangedSinceDraftSuccess, initSearch, initialEditorState, initialMapState, initialState, isBoundingBox, isBoundingBoxWithinWorldExtent, isConfigLoaded, isDateRange, isFileExtensionValid, isFormatInQueryParam, isPublished, itemModelFixture, kindToCodeListValue, loadAppConfig, malformedConfigFixture, mapConfigFixture, mapContact, mapKeywords, mapLogo, mapOrganization, mapReducer, markRecordAsChanged, matchesNoApplicableConstraint, matchesNoKnownConstraint, megabytesToBytes, mimeTypeToFormat, minimalAppConfigFixture, missingMandatoryConfigFixture, mouseWheelZoomCondition, noDuplicateFileName, okAppConfigFixture, openDataset, openRecord, organizationsServiceFactory, parse, parseConfigSection, parseMultiConfigSection, parseTranslationsConfigSection, parseXmlString, placeholder, prioritizePageScroll, propagateToDocumentOnly, provideGn4, provideI18n, provideLocalizedDateAdapter, provideRepositoryUrl, readAttribute, readDataset, readDatasetHeaders, readFileAsText, readText, reducer$2 as reducer, reducerSearch, removeAllChildren, removeChildren, removeChildrenByName, removeSearchParams, removeWhitespace, renameElements, saveRecord, saveRecordFailure, saveRecordSuccess, selectCanEditRecord, selectCurrentPage, selectEditorConfig, selectEditorState, selectFallback, selectFallbackFields, selectField, selectHasRecordChanged, selectIsPublished, selectRecord, selectRecordChangedSinceSave, selectRecordSaveError, selectRecordSaving, selectRecordSections, selectRecordSource, selectTranslatedField, selectTranslatedValue, setContext, setCurrentPage, setEditorConfiguration, setFieldVisibility, setFocusedField, setSelectedFeatures, setTextContent, sortByFromString, sortByToString, sortByToStrings, spatialExtentToGeometry, spatialExtentsToFeatureCollection, stripHtml, stripNamespace, toDate, toIndividual, toLang2, toLang3, totalPages, undoRecordDraft, unrecognizedKeysConfigFixture, updateFrequencyCodeValues, updateLanguages, updateRecordField, updateRecordLanguages, wmsLayerFlatten, writeAttribute, wrongLanguageCodeConfigFixture, xmlToString };
40866
41381
  //# sourceMappingURL=geonetwork-ui.mjs.map