geonetwork-ui 2.6.0-dev.186d57931 → 2.6.0-dev.25158f859

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 (306) hide show
  1. package/esm2022/libs/api/metadata-converter/src/index.mjs +2 -1
  2. package/esm2022/libs/api/metadata-converter/src/lib/common/distribution.mapper.mjs +3 -1
  3. package/esm2022/libs/api/metadata-converter/src/lib/common/resource-types.mjs +17 -15
  4. package/esm2022/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.mjs +2 -1
  5. package/esm2022/libs/api/repository/src/lib/gn4/elasticsearch/constant.mjs +2 -1
  6. package/esm2022/libs/api/repository/src/lib/gn4/gn4-repository.mjs +5 -2
  7. package/esm2022/libs/common/domain/src/lib/model/record/metadata.model.mjs +1 -1
  8. package/esm2022/libs/feature/dataviz/src/lib/chart-view/chart-view.component.mjs +45 -9
  9. package/esm2022/libs/feature/dataviz/src/lib/geo-table-view/geo-table-view.component.mjs +2 -2
  10. package/esm2022/libs/feature/dataviz/src/lib/service/data.service.mjs +32 -2
  11. package/esm2022/libs/feature/dataviz/src/lib/table-view/table-view.component.mjs +25 -6
  12. package/esm2022/libs/feature/editor/src/index.mjs +2 -1
  13. package/esm2022/libs/feature/editor/src/lib/components/multilingual-panel/multilingual-panel.component.mjs +18 -0
  14. package/esm2022/libs/feature/record/src/index.mjs +2 -3
  15. package/esm2022/libs/feature/record/src/lib/data-view/data-view.component.mjs +3 -3
  16. package/esm2022/libs/feature/record/src/lib/data-view-share/data-view-share.component.mjs +3 -3
  17. package/esm2022/libs/feature/record/src/lib/external-viewer-button/external-viewer-button.component.mjs +6 -3
  18. package/esm2022/libs/feature/record/src/lib/map-view/map-view.component.mjs +33 -7
  19. package/esm2022/libs/feature/record/src/lib/state/mdview.facade.mjs +11 -13
  20. package/esm2022/libs/feature/search/src/index.mjs +2 -2
  21. package/esm2022/libs/feature/search/src/lib/constants.mjs +2 -1
  22. package/esm2022/libs/feature/search/src/lib/feature-search.module.mjs +12 -5
  23. package/esm2022/libs/feature/search/src/lib/results-hits/results-hits.container.component.mjs +41 -0
  24. package/esm2022/libs/feature/search/src/lib/results-list/results-list.container.component.mjs +6 -2
  25. package/esm2022/libs/feature/search/src/lib/utils/service/fields.mjs +70 -1
  26. package/esm2022/libs/feature/search/src/lib/utils/service/fields.service.mjs +4 -3
  27. package/esm2022/libs/ui/dataviz/src/lib/chart/chart.component.mjs +5 -3
  28. package/esm2022/libs/ui/dataviz/src/lib/data-table/data-table.component.mjs +11 -6
  29. package/esm2022/libs/ui/elements/src/index.mjs +4 -1
  30. package/esm2022/libs/ui/elements/src/lib/api-card/api-card.component.mjs +3 -3
  31. package/esm2022/libs/ui/elements/src/lib/download-item/download-item.component.mjs +3 -3
  32. package/esm2022/libs/ui/elements/src/lib/downloads-list/downloads-list.component.mjs +18 -7
  33. package/esm2022/libs/ui/elements/src/lib/geo-data-badge/geo-data-badge.component.mjs +55 -0
  34. package/esm2022/libs/ui/elements/src/lib/image-overlay-preview/image-overlay-preview.component.mjs +3 -3
  35. package/esm2022/libs/ui/elements/src/lib/internal-link-card/internal-link-card.component.mjs +27 -53
  36. package/esm2022/libs/ui/elements/src/lib/kind-badge/kind-badge.component.mjs +68 -0
  37. package/esm2022/libs/ui/elements/src/lib/link-card/link-card.component.mjs +3 -3
  38. package/esm2022/libs/ui/elements/src/lib/metadata-catalog/metadata-catalog.component.mjs +3 -3
  39. package/esm2022/libs/ui/elements/src/lib/metadata-contact/metadata-contact.component.mjs +3 -3
  40. package/esm2022/libs/ui/elements/src/lib/metadata-info/metadata-info.component.mjs +3 -3
  41. package/esm2022/libs/ui/elements/src/lib/metadata-quality/metadata-quality.component.mjs +3 -3
  42. package/esm2022/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.mjs +51 -0
  43. package/esm2022/libs/ui/elements/src/lib/related-record-card/related-record-card.component.mjs +17 -7
  44. package/esm2022/libs/ui/elements/src/lib/service-capabilities/service-capabilities.component.mjs +12 -4
  45. package/esm2022/libs/ui/elements/src/lib/ui-elements.module.mjs +16 -4
  46. package/esm2022/libs/ui/inputs/src/index.mjs +3 -1
  47. package/esm2022/libs/ui/inputs/src/lib/button/button.component.mjs +2 -2
  48. package/esm2022/libs/ui/inputs/src/lib/dropdown-multiselect/dropdown-multiselect.component.mjs +3 -3
  49. package/esm2022/libs/ui/inputs/src/lib/dropdown-selector/dropdown-selector.component.mjs +3 -3
  50. package/esm2022/libs/ui/inputs/src/lib/inline-filter/inline-filter.component.mjs +42 -0
  51. package/esm2022/libs/ui/inputs/src/lib/inline-filter/inline-filter.model.mjs +2 -0
  52. package/esm2022/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.mjs +68 -0
  53. package/esm2022/libs/ui/inputs/src/lib/star-toggle/star-toggle.component.mjs +3 -3
  54. package/esm2022/libs/ui/inputs/src/lib/ui-inputs.module.mjs +8 -9
  55. package/esm2022/libs/ui/layout/src/index.mjs +2 -1
  56. package/esm2022/libs/ui/layout/src/lib/block-list/block-list.component.mjs +48 -11
  57. package/esm2022/libs/ui/layout/src/lib/carousel/carousel.component.mjs +3 -3
  58. package/esm2022/libs/ui/layout/src/lib/expandable-panel/expandable-panel.component.mjs +34 -13
  59. package/esm2022/libs/ui/layout/src/lib/max-lines/max-lines.component.mjs +3 -3
  60. package/esm2022/libs/ui/layout/src/lib/previous-next-buttons/previous-next-buttons.component.mjs +6 -6
  61. package/esm2022/libs/ui/layout/src/lib/truncated-text/truncated-text.component.mjs +107 -0
  62. package/esm2022/libs/ui/layout/src/lib/ui-layout.module.mjs +4 -12
  63. package/esm2022/libs/ui/map/src/lib/components/feature-detail/feature-detail.component.mjs +29 -4
  64. package/esm2022/libs/ui/map/src/lib/components/spatial-extent/spatial-extent.component.mjs +2 -1
  65. package/esm2022/libs/ui/search/src/index.mjs +2 -1
  66. package/esm2022/libs/ui/search/src/lib/record-preview-row/record-preview-row.component.mjs +4 -8
  67. package/esm2022/libs/ui/search/src/lib/results-hits-number/results-hits-number.component.mjs +3 -3
  68. package/esm2022/libs/ui/search/src/lib/results-hits-search-kind/results-hits-search-kind.component.mjs +53 -0
  69. package/esm2022/libs/ui/search/src/lib/results-list/results-layout.config.mjs +2 -2
  70. package/esm2022/libs/ui/search/src/lib/results-list/results-list.component.mjs +3 -3
  71. package/esm2022/libs/ui/search/src/lib/ui-search.module.mjs +11 -3
  72. package/esm2022/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.mjs +3 -3
  73. package/esm2022/libs/util/shared/src/lib/links/link-classifier.service.mjs +4 -1
  74. package/esm2022/libs/util/shared/src/lib/links/link-utils.mjs +4 -1
  75. package/esm2022/translations/de.json +14 -3
  76. package/esm2022/translations/en.json +15 -4
  77. package/esm2022/translations/es.json +14 -3
  78. package/esm2022/translations/fr.json +15 -4
  79. package/esm2022/translations/it.json +43 -32
  80. package/esm2022/translations/nl.json +14 -3
  81. package/esm2022/translations/pt.json +14 -3
  82. package/fesm2022/geonetwork-ui.mjs +1443 -648
  83. package/fesm2022/geonetwork-ui.mjs.map +1 -1
  84. package/libs/api/metadata-converter/src/index.d.ts +1 -0
  85. package/libs/api/metadata-converter/src/index.d.ts.map +1 -1
  86. package/libs/api/metadata-converter/src/lib/common/distribution.mapper.d.ts.map +1 -1
  87. package/libs/api/metadata-converter/src/lib/common/resource-types.d.ts +21 -0
  88. package/libs/api/metadata-converter/src/lib/common/resource-types.d.ts.map +1 -1
  89. package/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.d.ts.map +1 -1
  90. package/libs/api/repository/src/lib/gn4/elasticsearch/constant.d.ts.map +1 -1
  91. package/libs/api/repository/src/lib/gn4/gn4-repository.d.ts.map +1 -1
  92. package/libs/common/domain/src/lib/model/record/metadata.model.d.ts +4 -1
  93. package/libs/common/domain/src/lib/model/record/metadata.model.d.ts.map +1 -1
  94. package/libs/feature/dataviz/src/lib/chart-view/chart-view.component.d.ts +12 -8
  95. package/libs/feature/dataviz/src/lib/chart-view/chart-view.component.d.ts.map +1 -1
  96. package/libs/feature/dataviz/src/lib/service/data.service.d.ts +1 -0
  97. package/libs/feature/dataviz/src/lib/service/data.service.d.ts.map +1 -1
  98. package/libs/feature/dataviz/src/lib/table-view/table-view.component.d.ts +5 -2
  99. package/libs/feature/dataviz/src/lib/table-view/table-view.component.d.ts.map +1 -1
  100. package/libs/feature/editor/src/index.d.ts +1 -0
  101. package/libs/feature/editor/src/index.d.ts.map +1 -1
  102. package/libs/feature/editor/src/lib/components/multilingual-panel/multilingual-panel.component.d.ts +7 -0
  103. package/libs/feature/editor/src/lib/components/multilingual-panel/multilingual-panel.component.d.ts.map +1 -0
  104. package/libs/feature/record/src/index.d.ts +1 -2
  105. package/libs/feature/record/src/index.d.ts.map +1 -1
  106. package/libs/feature/record/src/lib/external-viewer-button/external-viewer-button.component.d.ts +2 -1
  107. package/libs/feature/record/src/lib/external-viewer-button/external-viewer-button.component.d.ts.map +1 -1
  108. package/libs/feature/record/src/lib/map-view/map-view.component.d.ts.map +1 -1
  109. package/libs/feature/record/src/lib/state/mdview.facade.d.ts +26 -21
  110. package/libs/feature/record/src/lib/state/mdview.facade.d.ts.map +1 -1
  111. package/libs/feature/search/src/index.d.ts +1 -1
  112. package/libs/feature/search/src/index.d.ts.map +1 -1
  113. package/libs/feature/search/src/lib/constants.d.ts.map +1 -1
  114. package/libs/feature/search/src/lib/feature-search.module.d.ts +4 -2
  115. package/libs/feature/search/src/lib/feature-search.module.d.ts.map +1 -1
  116. package/libs/feature/search/src/lib/results-hits/results-hits.container.component.d.ts +21 -0
  117. package/libs/feature/search/src/lib/results-hits/results-hits.container.component.d.ts.map +1 -0
  118. package/libs/feature/search/src/lib/results-list/results-list.container.component.d.ts +1 -1
  119. package/libs/feature/search/src/lib/results-list/results-list.container.component.d.ts.map +1 -1
  120. package/libs/feature/search/src/lib/utils/service/fields.d.ts +21 -0
  121. package/libs/feature/search/src/lib/utils/service/fields.d.ts.map +1 -1
  122. package/libs/feature/search/src/lib/utils/service/fields.service.d.ts.map +1 -1
  123. package/libs/ui/dataviz/src/lib/chart/chart.component.d.ts +2 -1
  124. package/libs/ui/dataviz/src/lib/chart/chart.component.d.ts.map +1 -1
  125. package/libs/ui/dataviz/src/lib/data-table/data-table.component.d.ts +6 -1
  126. package/libs/ui/dataviz/src/lib/data-table/data-table.component.d.ts.map +1 -1
  127. package/libs/ui/elements/src/index.d.ts +3 -0
  128. package/libs/ui/elements/src/index.d.ts.map +1 -1
  129. package/libs/ui/elements/src/lib/download-item/download-item.component.d.ts +1 -1
  130. package/libs/ui/elements/src/lib/download-item/download-item.component.d.ts.map +1 -1
  131. package/libs/ui/elements/src/lib/downloads-list/downloads-list.component.d.ts +7 -1
  132. package/libs/ui/elements/src/lib/downloads-list/downloads-list.component.d.ts.map +1 -1
  133. package/libs/ui/elements/src/lib/geo-data-badge/geo-data-badge.component.d.ts +15 -0
  134. package/libs/ui/elements/src/lib/geo-data-badge/geo-data-badge.component.d.ts.map +1 -0
  135. package/libs/ui/elements/src/lib/internal-link-card/internal-link-card.component.d.ts +3 -7
  136. package/libs/ui/elements/src/lib/internal-link-card/internal-link-card.component.d.ts.map +1 -1
  137. package/libs/ui/elements/src/lib/kind-badge/kind-badge.component.d.ts +13 -0
  138. package/libs/ui/elements/src/lib/kind-badge/kind-badge.component.d.ts.map +1 -0
  139. package/libs/ui/elements/src/lib/link-card/link-card.component.d.ts +1 -1
  140. package/libs/ui/elements/src/lib/link-card/link-card.component.d.ts.map +1 -1
  141. package/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.d.ts +16 -0
  142. package/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.d.ts.map +1 -0
  143. package/libs/ui/elements/src/lib/related-record-card/related-record-card.component.d.ts +8 -1
  144. package/libs/ui/elements/src/lib/related-record-card/related-record-card.component.d.ts.map +1 -1
  145. package/libs/ui/elements/src/lib/service-capabilities/service-capabilities.component.d.ts +1 -0
  146. package/libs/ui/elements/src/lib/service-capabilities/service-capabilities.component.d.ts.map +1 -1
  147. package/libs/ui/elements/src/lib/ui-elements.module.d.ts +3 -1
  148. package/libs/ui/elements/src/lib/ui-elements.module.d.ts.map +1 -1
  149. package/libs/ui/inputs/src/index.d.ts +2 -0
  150. package/libs/ui/inputs/src/index.d.ts.map +1 -1
  151. package/libs/ui/inputs/src/lib/button/button.component.d.ts +1 -1
  152. package/libs/ui/inputs/src/lib/button/button.component.d.ts.map +1 -1
  153. package/libs/ui/inputs/src/lib/inline-filter/inline-filter.component.d.ts +14 -0
  154. package/libs/ui/inputs/src/lib/inline-filter/inline-filter.component.d.ts.map +1 -0
  155. package/libs/ui/inputs/src/lib/inline-filter/inline-filter.model.d.ts +6 -0
  156. package/libs/ui/inputs/src/lib/inline-filter/inline-filter.model.d.ts.map +1 -0
  157. package/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.d.ts +17 -0
  158. package/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.d.ts.map +1 -0
  159. package/libs/ui/inputs/src/lib/ui-inputs.module.d.ts +25 -24
  160. package/libs/ui/inputs/src/lib/ui-inputs.module.d.ts.map +1 -1
  161. package/libs/ui/layout/src/index.d.ts +1 -0
  162. package/libs/ui/layout/src/index.d.ts.map +1 -1
  163. package/libs/ui/layout/src/lib/block-list/block-list.component.d.ts +9 -2
  164. package/libs/ui/layout/src/lib/block-list/block-list.component.d.ts.map +1 -1
  165. package/libs/ui/layout/src/lib/expandable-panel/expandable-panel.component.d.ts +15 -8
  166. package/libs/ui/layout/src/lib/expandable-panel/expandable-panel.component.d.ts.map +1 -1
  167. package/libs/ui/layout/src/lib/truncated-text/truncated-text.component.d.ts +27 -0
  168. package/libs/ui/layout/src/lib/truncated-text/truncated-text.component.d.ts.map +1 -0
  169. package/libs/ui/layout/src/lib/ui-layout.module.d.ts.map +1 -1
  170. package/libs/ui/map/src/lib/components/feature-detail/feature-detail.component.d.ts +6 -2
  171. package/libs/ui/map/src/lib/components/feature-detail/feature-detail.component.d.ts.map +1 -1
  172. package/libs/ui/map/src/lib/components/spatial-extent/spatial-extent.component.d.ts.map +1 -1
  173. package/libs/ui/search/src/index.d.ts +1 -0
  174. package/libs/ui/search/src/index.d.ts.map +1 -1
  175. package/libs/ui/search/src/lib/results-hits-search-kind/results-hits-search-kind.component.d.ts +17 -0
  176. package/libs/ui/search/src/lib/results-hits-search-kind/results-hits-search-kind.component.d.ts.map +1 -0
  177. package/libs/ui/search/src/lib/results-list/results-list.component.d.ts.map +1 -1
  178. package/libs/ui/search/src/lib/ui-search.module.d.ts +21 -19
  179. package/libs/ui/search/src/lib/ui-search.module.d.ts.map +1 -1
  180. package/libs/util/shared/src/lib/links/link-classifier.service.d.ts.map +1 -1
  181. package/libs/util/shared/src/lib/links/link-utils.d.ts.map +1 -1
  182. package/package.json +2 -2
  183. package/src/libs/api/metadata-converter/src/index.ts +1 -0
  184. package/src/libs/api/metadata-converter/src/lib/common/distribution.mapper.ts +1 -0
  185. package/src/libs/api/metadata-converter/src/lib/common/resource-types.ts +29 -15
  186. package/src/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.ts +1 -0
  187. package/src/libs/api/repository/src/lib/gn4/elasticsearch/constant.ts +1 -0
  188. package/src/libs/api/repository/src/lib/gn4/gn4-repository.ts +4 -1
  189. package/src/libs/common/domain/src/lib/model/record/metadata.model.ts +9 -2
  190. package/src/libs/common/fixtures/src/lib/elasticsearch/metadata-links.fixtures.ts +10 -0
  191. package/src/libs/common/fixtures/src/lib/link.fixtures.ts +14 -0
  192. package/src/libs/common/fixtures/src/lib/records.fixtures.ts +1 -1
  193. package/src/libs/feature/dataviz/src/lib/chart-view/chart-view.component.html +12 -9
  194. package/src/libs/feature/dataviz/src/lib/chart-view/chart-view.component.ts +54 -10
  195. package/src/libs/feature/dataviz/src/lib/service/data.service.ts +37 -0
  196. package/src/libs/feature/dataviz/src/lib/table-view/table-view.component.html +1 -0
  197. package/src/libs/feature/dataviz/src/lib/table-view/table-view.component.ts +27 -1
  198. package/src/libs/feature/editor/src/index.ts +1 -0
  199. package/src/libs/feature/editor/src/lib/components/multilingual-panel/multilingual-panel.component.css +0 -0
  200. package/src/libs/feature/editor/src/lib/components/multilingual-panel/multilingual-panel.component.html +14 -0
  201. package/src/libs/feature/editor/src/lib/components/multilingual-panel/multilingual-panel.component.ts +15 -0
  202. package/src/libs/feature/record/src/index.ts +1 -2
  203. package/src/libs/feature/record/src/lib/data-view/data-view.component.html +16 -10
  204. package/src/libs/feature/record/src/lib/data-view-share/data-view-share.component.html +1 -1
  205. package/src/libs/feature/record/src/lib/external-viewer-button/external-viewer-button.component.html +2 -2
  206. package/src/libs/feature/record/src/lib/external-viewer-button/external-viewer-button.component.ts +1 -0
  207. package/src/libs/feature/record/src/lib/map-view/map-view.component.html +25 -16
  208. package/src/libs/feature/record/src/lib/map-view/map-view.component.ts +35 -4
  209. package/src/libs/feature/record/src/lib/state/mdview.facade.ts +18 -15
  210. package/src/libs/feature/search/src/index.ts +1 -1
  211. package/src/libs/feature/search/src/lib/constants.ts +1 -0
  212. package/src/libs/feature/search/src/lib/feature-search.module.ts +9 -2
  213. package/src/libs/feature/search/src/lib/results-hits/results-hits.container.component.css +0 -0
  214. package/src/libs/feature/search/src/lib/results-hits/results-hits.container.component.html +16 -0
  215. package/src/libs/feature/search/src/lib/results-hits/results-hits.container.component.ts +59 -0
  216. package/src/libs/feature/search/src/lib/results-list/results-list.container.component.ts +2 -0
  217. package/src/libs/feature/search/src/lib/utils/service/fields.service.ts +4 -5
  218. package/src/libs/feature/search/src/lib/utils/service/fields.ts +99 -0
  219. package/src/libs/ui/dataviz/src/lib/chart/chart.component.ts +2 -1
  220. package/src/libs/ui/dataviz/src/lib/data-table/data-table.component.html +6 -3
  221. package/src/libs/ui/dataviz/src/lib/data-table/data-table.component.ts +5 -4
  222. package/src/libs/ui/elements/src/index.ts +3 -0
  223. package/src/libs/ui/elements/src/lib/api-card/api-card.component.html +4 -4
  224. package/src/libs/ui/elements/src/lib/download-item/download-item.component.html +8 -5
  225. package/src/libs/ui/elements/src/lib/download-item/download-item.component.ts +2 -2
  226. package/src/libs/ui/elements/src/lib/downloads-list/downloads-list.component.html +38 -7
  227. package/src/libs/ui/elements/src/lib/downloads-list/downloads-list.component.ts +29 -2
  228. package/src/libs/ui/elements/src/lib/geo-data-badge/geo-data-badge.component.css +4 -0
  229. package/src/libs/ui/elements/src/lib/geo-data-badge/geo-data-badge.component.html +13 -0
  230. package/src/libs/ui/elements/src/lib/geo-data-badge/geo-data-badge.component.ts +54 -0
  231. package/src/libs/ui/elements/src/lib/image-overlay-preview/image-overlay-preview.component.html +1 -1
  232. package/src/libs/ui/elements/src/lib/internal-link-card/internal-link-card.component.html +133 -138
  233. package/src/libs/ui/elements/src/lib/internal-link-card/internal-link-card.component.ts +19 -47
  234. package/src/libs/ui/elements/src/lib/kind-badge/kind-badge.component.css +6 -0
  235. package/src/libs/ui/elements/src/lib/kind-badge/kind-badge.component.html +11 -0
  236. package/src/libs/ui/elements/src/lib/kind-badge/kind-badge.component.ts +70 -0
  237. package/src/libs/ui/elements/src/lib/link-card/link-card.component.html +5 -2
  238. package/src/libs/ui/elements/src/lib/link-card/link-card.component.ts +3 -7
  239. package/src/libs/ui/elements/src/lib/metadata-catalog/metadata-catalog.component.html +3 -5
  240. package/src/libs/ui/elements/src/lib/metadata-contact/metadata-contact.component.html +12 -9
  241. package/src/libs/ui/elements/src/lib/metadata-info/metadata-info.component.css +1 -1
  242. package/src/libs/ui/elements/src/lib/metadata-info/metadata-info.component.html +11 -3
  243. package/src/libs/ui/elements/src/lib/metadata-quality/metadata-quality.component.html +2 -3
  244. package/src/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.html +48 -0
  245. package/src/libs/ui/elements/src/lib/record-feature-catalog/feature-catalog-list/feature-catalog-list.component.ts +52 -0
  246. package/src/libs/ui/elements/src/lib/related-record-card/related-record-card.component.html +8 -29
  247. package/src/libs/ui/elements/src/lib/related-record-card/related-record-card.component.ts +14 -1
  248. package/src/libs/ui/elements/src/lib/service-capabilities/service-capabilities.component.html +16 -2
  249. package/src/libs/ui/elements/src/lib/service-capabilities/service-capabilities.component.ts +9 -1
  250. package/src/libs/ui/elements/src/lib/ui-elements.module.ts +6 -1
  251. package/src/libs/ui/inputs/src/index.ts +2 -0
  252. package/src/libs/ui/inputs/src/lib/button/button.component.ts +2 -2
  253. package/src/libs/ui/inputs/src/lib/dropdown-multiselect/dropdown-multiselect.component.html +1 -1
  254. package/src/libs/ui/inputs/src/lib/dropdown-selector/dropdown-selector.component.html +1 -1
  255. package/src/libs/ui/inputs/src/lib/inline-filter/inline-filter.component.html +23 -0
  256. package/src/libs/ui/inputs/src/lib/inline-filter/inline-filter.component.ts +44 -0
  257. package/src/libs/ui/inputs/src/lib/inline-filter/inline-filter.model.ts +5 -0
  258. package/src/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.css +0 -0
  259. package/src/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.html +43 -0
  260. package/src/libs/ui/inputs/src/lib/search-feature-catalog/search-feature-catalog.component.ts +77 -0
  261. package/src/libs/ui/inputs/src/lib/star-toggle/star-toggle.component.html +3 -4
  262. package/src/libs/ui/inputs/src/lib/ui-inputs.module.ts +3 -3
  263. package/src/libs/ui/layout/src/index.ts +1 -0
  264. package/src/libs/ui/layout/src/lib/block-list/block-list.component.css +22 -0
  265. package/src/libs/ui/layout/src/lib/block-list/block-list.component.html +2 -2
  266. package/src/libs/ui/layout/src/lib/block-list/block-list.component.ts +43 -5
  267. package/src/libs/ui/layout/src/lib/carousel/carousel.component.css +0 -1
  268. package/src/libs/ui/layout/src/lib/carousel/carousel.component.html +1 -1
  269. package/src/libs/ui/layout/src/lib/expandable-panel/expandable-panel.component.html +24 -8
  270. package/src/libs/ui/layout/src/lib/expandable-panel/expandable-panel.component.ts +36 -10
  271. package/src/libs/ui/layout/src/lib/max-lines/max-lines.component.html +1 -1
  272. package/src/libs/ui/layout/src/lib/previous-next-buttons/previous-next-buttons.component.html +17 -5
  273. package/src/libs/ui/layout/src/lib/previous-next-buttons/previous-next-buttons.component.ts +3 -3
  274. package/src/libs/ui/layout/src/lib/truncated-text/truncated-text.component.html +44 -0
  275. package/src/libs/ui/layout/src/lib/truncated-text/truncated-text.component.ts +130 -0
  276. package/src/libs/ui/layout/src/lib/ui-layout.module.ts +1 -5
  277. package/src/libs/ui/map/src/lib/components/feature-detail/feature-detail.component.html +3 -3
  278. package/src/libs/ui/map/src/lib/components/feature-detail/feature-detail.component.ts +27 -3
  279. package/src/libs/ui/map/src/lib/components/spatial-extent/spatial-extent.component.ts +1 -0
  280. package/src/libs/ui/search/src/index.ts +1 -0
  281. package/src/libs/ui/search/src/lib/record-preview-row/record-preview-row.component.html +9 -81
  282. package/src/libs/ui/search/src/lib/results-hits-number/results-hits-number.component.html +1 -1
  283. package/src/libs/ui/search/src/lib/results-hits-search-kind/results-hits-search-kind.component.html +25 -0
  284. package/src/libs/ui/search/src/lib/results-hits-search-kind/results-hits-search-kind.component.ts +53 -0
  285. package/src/libs/ui/search/src/lib/results-list/results-layout.config.ts +2 -2
  286. package/src/libs/ui/search/src/lib/results-list/results-list.component.html +1 -0
  287. package/src/libs/ui/search/src/lib/results-list/results-list.component.ts +0 -1
  288. package/src/libs/ui/search/src/lib/ui-search.module.ts +5 -0
  289. package/src/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.html +1 -1
  290. package/src/libs/util/shared/src/lib/links/link-classifier.service.ts +3 -0
  291. package/src/libs/util/shared/src/lib/links/link-utils.ts +3 -0
  292. package/tailwind.base.config.js +3 -0
  293. package/tailwind.base.css +1 -13
  294. package/translations/de.json +14 -3
  295. package/translations/en.json +15 -4
  296. package/translations/es.json +14 -3
  297. package/translations/fr.json +15 -4
  298. package/translations/it.json +43 -32
  299. package/translations/nl.json +14 -3
  300. package/translations/pt.json +14 -3
  301. package/translations/sk.json +14 -3
  302. package/esm2022/libs/feature/search/src/lib/results-hits-number/results-hits.container.component.mjs +0 -18
  303. package/libs/feature/search/src/lib/results-hits-number/results-hits.container.component.d.ts +0 -9
  304. package/libs/feature/search/src/lib/results-hits-number/results-hits.container.component.d.ts.map +0 -1
  305. package/src/libs/feature/search/src/lib/results-hits-number/results-hits.container.component.html +0 -4
  306. package/src/libs/feature/search/src/lib/results-hits-number/results-hits.container.component.ts +0 -10
@@ -6,6 +6,7 @@ import {
6
6
  OgcApiRecord,
7
7
  WfsEndpoint,
8
8
  WfsVersion,
9
+ TmsEndpoint,
9
10
  } from '@camptocamp/ogc-client'
10
11
  import {
11
12
  BaseReader,
@@ -231,6 +232,42 @@ export class DataService {
231
232
  })
232
233
  }
233
234
 
235
+ async getGeodataLinksFromTms(
236
+ tmsLink: DatasetServiceDistribution,
237
+ keepOriginalLink = false
238
+ ): Promise<DatasetServiceDistribution[]> {
239
+ const endpoint = new TmsEndpoint(tmsLink.url.toString())
240
+ const tileMaps = await endpoint.allTileMaps
241
+ if (!tileMaps?.length) return null
242
+
243
+ // TODO: at some point use the identifierInService field if more that one layers in the TMS service
244
+ const tileMapInfo = await endpoint.getTileMapInfo(tileMaps[0].href)
245
+
246
+ // case 1: no styles; return a plain TMS link
247
+ if (!tileMapInfo?.metadata?.length) return [tmsLink]
248
+
249
+ // case 2: styles present; return each as a separate link
250
+ const styleLinks = tileMapInfo.metadata
251
+ .filter((meta) => meta.href)
252
+ .map((meta) => {
253
+ const fileName = meta.href.split('/').pop() || ''
254
+ const linkName =
255
+ tmsLink.description || ('name' in tmsLink ? tmsLink.name : '')
256
+ const styleName = fileName.split('.')[0]
257
+ const name = `${linkName} - ${styleName}`
258
+ return {
259
+ type: 'service',
260
+ url: new URL(meta.href),
261
+ name,
262
+ accessServiceProtocol: 'maplibre-style',
263
+ } as DatasetServiceDistribution
264
+ })
265
+ if (keepOriginalLink) {
266
+ styleLinks.unshift(tmsLink)
267
+ }
268
+ return styleLinks
269
+ }
270
+
234
271
  getDownloadLinksFromEsriRest(
235
272
  esriRestLink: DatasetServiceDistribution
236
273
  ): DatasetOnlineResource[] {
@@ -4,6 +4,7 @@
4
4
  *ngIf="tableData$ | async as dataset"
5
5
  class="overflow-auto grow"
6
6
  [dataset]="dataset"
7
+ [featureAttributes]="featureAttributes"
7
8
  (selected)="onTableSelect($event)"
8
9
  ></gn-ui-data-table>
9
10
  <gn-ui-loading-mask
@@ -6,11 +6,15 @@ import {
6
6
  shareReplay,
7
7
  startWith,
8
8
  switchMap,
9
+ tap,
9
10
  } from 'rxjs/operators'
10
11
  import { BaseReader, FetchError } from '../../../../../../libs/util/data-fetcher/src'
11
12
  import { DataService } from '../service/data.service'
12
13
  import { DataTableComponent } from '../../../../../../libs/ui/dataviz/src'
13
- import { DatasetOnlineResource } from '../../../../../../libs/common/domain/src/lib/model/record'
14
+ import {
15
+ DatasetFeatureCatalog,
16
+ DatasetOnlineResource,
17
+ } from '../../../../../../libs/common/domain/src/lib/model/record'
14
18
  import { TranslateModule, TranslateService } from '@ngx-translate/core'
15
19
  import {
16
20
  LoadingMaskComponent,
@@ -33,6 +37,8 @@ import { CommonModule } from '@angular/common'
33
37
  standalone: true,
34
38
  })
35
39
  export class TableViewComponent {
40
+ featureAttributes = []
41
+ @Input() featureCatalog: DatasetFeatureCatalog
36
42
  @Input() cacheActive = true
37
43
  @Input() set link(value: DatasetOnlineResource) {
38
44
  this.currentLink$.next(value)
@@ -52,6 +58,7 @@ export class TableViewComponent {
52
58
  }
53
59
  this.loading = true
54
60
  return this.getDatasetReader(link).pipe(
61
+ tap((dataset: BaseReader) => this.setProperties(dataset)),
55
62
  catchError((error) => {
56
63
  this.handleError(error)
57
64
  return of(undefined)
@@ -96,4 +103,23 @@ export class TableViewComponent {
96
103
  }
97
104
  this.loading = false
98
105
  }
106
+
107
+ setProperties(dataset: BaseReader) {
108
+ dataset.properties.then((properties) => {
109
+ const updatedProperties = properties.map((p) => {
110
+ let label = p.name
111
+ if (this.featureCatalog) {
112
+ const attributes = this.featureCatalog.featureTypes[0].attributes
113
+ const matchingAttribute = attributes.find(
114
+ (attr) => attr.name === p.name
115
+ )
116
+ if (matchingAttribute && matchingAttribute.code) {
117
+ label = matchingAttribute.code
118
+ }
119
+ }
120
+ return { value: p.name, label }
121
+ })
122
+ this.featureAttributes = updatedProperties
123
+ })
124
+ }
99
125
  }
@@ -11,3 +11,4 @@ export * from './lib/components/wizard/wizard.component'
11
11
  export * from './lib/components/wizard-field/wizard-field.component'
12
12
  export * from './lib/components/wizard-summarize/wizard-summarize.component'
13
13
  export * from './lib/components/record-form/form-field'
14
+ export * from './lib/components/multilingual-panel/multilingual-panel.component'
@@ -0,0 +1,14 @@
1
+ <div
2
+ class="flex flex-col h-full w-[302px] bg-neutral-100 border-l border-gray-300 py-9 px-3 gap-8"
3
+ >
4
+ <span class="text-3xl font-title text-black/80 px-2" translate
5
+ >editor.record.form.multilingual.title</span
6
+ >
7
+ <gn-ui-check-toggle
8
+ class="p-2"
9
+ [label]="'editor.record.form.multilingual.enable' | translate"
10
+ [color]="'primary'"
11
+ [value]="translationsEnabled"
12
+ (toggled)="translationsEnabled = $event"
13
+ ></gn-ui-check-toggle>
14
+ </div>
@@ -0,0 +1,15 @@
1
+ import { Component } from '@angular/core'
2
+ import { CommonModule } from '@angular/common'
3
+ import { CheckToggleComponent } from '../../../../../../../libs/ui/inputs/src'
4
+ import { TranslateModule } from '@ngx-translate/core'
5
+
6
+ @Component({
7
+ selector: 'gn-ui-multilingual-panel',
8
+ standalone: true,
9
+ imports: [CommonModule, CheckToggleComponent, TranslateModule],
10
+ templateUrl: './multilingual-panel.component.html',
11
+ styleUrl: './multilingual-panel.component.css',
12
+ })
13
+ export class MultilingualPanelComponent {
14
+ translationsEnabled = false
15
+ }
@@ -5,7 +5,6 @@ export * from './lib/data-view/data-view.component'
5
5
  export * from './lib/data-view-share/data-view-share.component'
6
6
  export * from './lib/data-view-web-component/data-view-web-component.component'
7
7
  export * from './lib/external-viewer-button/external-viewer-button.component'
8
- export * from './lib/map-view/map-view.component'
9
8
  export * from './lib/gpf-api-dl/gpf-api-dl.component'
9
+ export * from './lib/map-view/map-view.component'
10
10
  export * from './lib/record-meta/record-meta.component'
11
- export * from './lib/external-viewer-button/external-viewer-button.component'
@@ -1,13 +1,17 @@
1
- <div class="w-full h-full flex flex-col p-1">
2
- <gn-ui-dropdown-selector
3
- *ngIf="dropdownChoices$ | async as choices"
4
- [ngClass]="{ hidden: !displaySource }"
5
- [title]="'table.select.data' | translate"
6
- class="truncate p-1 -mx-1 self-end mb-1"
7
- extraBtnClass="!text-primary font-sans font-medium"
8
- [choices]="choices"
9
- (selectValue)="selectLink($event)"
10
- ></gn-ui-dropdown-selector>
1
+ <div class="w-full h-full flex flex-col gap-[13px]">
2
+ <div
3
+ class="w-full py-4 px-5 bg-white border border-color-border rounded-lg mt-6"
4
+ >
5
+ <gn-ui-dropdown-selector
6
+ *ngIf="dropdownChoices$ | async as choices"
7
+ [ngClass]="{ hidden: !displaySource }"
8
+ [title]="'table.select.data' | translate"
9
+ class="h-[44px] w-full"
10
+ extraBtnClass="font-sans font-bold"
11
+ [choices]="choices"
12
+ (selectValue)="selectLink($event)"
13
+ ></gn-ui-dropdown-selector>
14
+ </div>
11
15
  <ng-container *ngIf="hidePreview; else dataView">
12
16
  <gn-ui-popup-alert
13
17
  type="warning"
@@ -23,12 +27,14 @@
23
27
  *ngIf="mode === 'table'"
24
28
  [cacheActive]="cacheActive$ | async"
25
29
  [link]="selectedLink$ | async"
30
+ [featureCatalog]="mdViewFacade.featureCatalog$ | async"
26
31
  ></gn-ui-table-view>
27
32
  <gn-ui-chart-view
28
33
  *ngIf="mode === 'chart'"
29
34
  (chartConfig$)="setChartConfig($event)"
30
35
  [cacheActive]="cacheActive$ | async"
31
36
  [link]="selectedLink$ | async"
37
+ [featureCatalog]="mdViewFacade.featureCatalog$ | async"
32
38
  ></gn-ui-chart-view>
33
39
  </div>
34
40
  </ng-template>
@@ -1,4 +1,4 @@
1
- <div class="px-5 my-1">
1
+ <div>
2
2
  <mat-tab-group
3
3
  [selectedIndex]="0"
4
4
  animationDuration="0ms"
@@ -1,9 +1,9 @@
1
1
  <gn-ui-button
2
2
  *ngIf="externalViewer"
3
3
  (buttonClick)="openInExternalViewer()"
4
- type="secondary"
4
+ type="primary"
5
5
  [title]="'record.externalViewer.open' | translate"
6
- extraClass="ms-2 !rounded-lg"
6
+ [extraClass]="extraClass + 'bg-primary ms-2 !rounded-lg'"
7
7
  >
8
8
  <ng-icon name="matOpenInNew"></ng-icon>
9
9
  </gn-ui-button>
@@ -36,6 +36,7 @@ export const EXTERNAL_VIEWER_OPEN_NEW_TAB = new InjectionToken<boolean>(
36
36
  })
37
37
  export class ExternalViewerButtonComponent {
38
38
  @Input() link: DatasetOnlineResource
39
+ @Input() extraClass = ''
39
40
 
40
41
  get externalViewer() {
41
42
  return !!this.urlTemplate && !!this.supportedLinkLayerType
@@ -1,18 +1,24 @@
1
- <div class="w-full h-full flex flex-col p-1">
2
- <div class="w-full flex justify-end">
3
- <gn-ui-dropdown-selector
4
- [ngClass]="{ hidden: !displaySource }"
5
- class="truncate p-1 -mx-1 mb-1"
6
- extraBtnClass="!text-primary font-sans font-medium"
7
- [title]="'map.select.layer' | translate"
8
- [choices]="dropdownChoices$ | async"
9
- (selectValue)="selectLinkToDisplay($event)"
10
- ></gn-ui-dropdown-selector>
11
- <gn-ui-external-viewer-button
12
- class="shrink-0 py-1 place-self-end"
13
- [link]="selectedLink$ | async"
14
- >
15
- </gn-ui-external-viewer-button>
1
+ <div class="w-full h-full flex flex-col gap-[13px]">
2
+ <div
3
+ class="flex py-4 px-5 bg-white border border-color-border rounded-lg mt-6"
4
+ >
5
+ <div class="grow min-w-0">
6
+ <gn-ui-dropdown-selector
7
+ [ngClass]="{ hidden: !displaySource }"
8
+ class="w-full"
9
+ extraBtnClass="font-sans font-bold"
10
+ [title]="'map.select.layer' | translate"
11
+ [choices]="dropdownChoices$ | async"
12
+ (selectValue)="selectLinkToDisplay($event)"
13
+ ></gn-ui-dropdown-selector>
14
+ </div>
15
+ <div class="self-end">
16
+ <gn-ui-external-viewer-button
17
+ extraClass="w-[44px] h-[44px]"
18
+ [link]="selectedLink$ | async"
19
+ >
20
+ </gn-ui-external-viewer-button>
21
+ </div>
16
22
  </div>
17
23
  <ng-container *ngIf="hidePreview; else mapView">
18
24
  <gn-ui-popup-alert
@@ -49,7 +55,10 @@
49
55
  >
50
56
  <ng-icon name="matClose" class="align-middle text-sm"></ng-icon>
51
57
  </gn-ui-button>
52
- <gn-ui-feature-detail [feature]="selection"></gn-ui-feature-detail>
58
+ <gn-ui-feature-detail
59
+ [featureCatalog]="mdViewFacade.featureCatalog$ | async"
60
+ [feature]="selection"
61
+ ></gn-ui-feature-detail>
53
62
  </div>
54
63
 
55
64
  <div
@@ -39,8 +39,8 @@ import {
39
39
  import {
40
40
  FeatureDetailComponent,
41
41
  MapContainerComponent,
42
- prioritizePageScroll,
43
42
  MapLegendComponent,
43
+ prioritizePageScroll,
44
44
  } from '../../../../../../libs/ui/map/src'
45
45
  import { Feature } from 'geojson'
46
46
  import { NgIconComponent, provideIcons } from '@ng-icons/core'
@@ -109,9 +109,20 @@ export class MapViewComponent implements AfterViewInit {
109
109
  this.mdViewFacade.mapApiLinks$,
110
110
  this.mdViewFacade.geoDataLinksWithGeometry$,
111
111
  ]).pipe(
112
- map(([mapApiLinks, geoDataLinksWithGeometry]) => {
113
- return [...mapApiLinks, ...geoDataLinksWithGeometry]
114
- })
112
+ switchMap(async ([mapApiLinks, geoDataLinksWithGeometry]) => {
113
+ // looking for TMS links to process
114
+ let processedMapApiLinks = await Promise.all(
115
+ mapApiLinks.map((link) => {
116
+ if (link.type === 'service' && link.accessServiceProtocol === 'tms') {
117
+ return this.dataService.getGeodataLinksFromTms(link)
118
+ }
119
+ return link
120
+ })
121
+ )
122
+ processedMapApiLinks = processedMapApiLinks.flat()
123
+ return [...processedMapApiLinks, ...geoDataLinksWithGeometry]
124
+ }),
125
+ shareReplay(1)
115
126
  )
116
127
 
117
128
  dropdownChoices$ = this.compatibleMapLinks$.pipe(
@@ -239,6 +250,26 @@ export class MapViewComponent implements AfterViewInit {
239
250
  type: 'wms',
240
251
  name: link.name,
241
252
  })
253
+ } else if (
254
+ link.type === 'service' &&
255
+ link.accessServiceProtocol === 'tms'
256
+ ) {
257
+ // FIXME: here we're assuming that the TMS serves vector tiles only; should be checked with ogc-client first
258
+ return of({
259
+ url: link.url.toString().replace(/\/?$/, '/{z}/{x}/{y}.pbf'),
260
+ type: 'xyz',
261
+ tileFormat: 'application/vnd.mapbox-vector-tile',
262
+ name: link.name,
263
+ })
264
+ } else if (
265
+ link.type === 'service' &&
266
+ link.accessServiceProtocol === 'maplibre-style'
267
+ ) {
268
+ return of({
269
+ type: 'maplibre-style',
270
+ name: link.name,
271
+ styleUrl: link.url.toString(),
272
+ })
242
273
  } else if (
243
274
  link.type === 'service' &&
244
275
  link.accessServiceProtocol === 'wmts'
@@ -6,6 +6,7 @@ import {
6
6
  filter,
7
7
  map,
8
8
  mergeMap,
9
+ shareReplay,
9
10
  switchMap,
10
11
  toArray,
11
12
  } from 'rxjs/operators'
@@ -15,13 +16,11 @@ import { LinkClassifierService, LinkUsage } from '../../../../../../libs/util/sh
15
16
  import { DatavizConfigurationModel } from '../../../../../../libs/common/domain/src/lib/model/dataviz/dataviz-configuration.model'
16
17
  import {
17
18
  CatalogRecord,
18
- DatasetServiceDistribution,
19
- ServiceEndpoint,
20
19
  UserFeedback,
21
20
  } from '../../../../../../libs/common/domain/src/lib/model/record'
22
21
  import { AvatarServiceInterface } from '../../../../../../libs/api/repository/src'
23
22
  import { OgcApiRecord } from '@camptocamp/ogc-client'
24
- import { from, of } from 'rxjs'
23
+ import { from, of, Observable } from 'rxjs'
25
24
  import { DataService } from '../../../../../../libs/feature/dataviz/src'
26
25
 
27
26
  @Injectable()
@@ -80,21 +79,17 @@ export class MdViewFacade {
80
79
  chartConfig$ = this.store.pipe(select(MdViewSelectors.getChartConfig))
81
80
 
82
81
  allLinks$ = this.metadata$.pipe(
83
- map((record) => ('onlineResources' in record ? record.onlineResources : []))
82
+ map((record) =>
83
+ 'onlineResources' in record ? record.onlineResources : []
84
+ ),
85
+ shareReplay(1)
84
86
  )
85
87
 
86
88
  apiLinks$ = this.allLinks$.pipe(
87
89
  map((links) =>
88
- links
89
- .filter((link) => this.linkClassifier.hasUsage(link, LinkUsage.API))
90
- // Put links to IGN Géoplateforme first
91
- .sort((dd1, dd2) => {
92
- return (dd2 as DatasetServiceDistribution | ServiceEndpoint)
93
- .accessServiceProtocol === 'GPFDL'
94
- ? 1
95
- : undefined // do not change the sorting otherwise
96
- })
97
- )
90
+ links.filter((link) => this.linkClassifier.hasUsage(link, LinkUsage.API))
91
+ ),
92
+ shareReplay(1)
98
93
  )
99
94
 
100
95
  mapApiLinks$ = this.allLinks$.pipe(
@@ -102,7 +97,8 @@ export class MdViewFacade {
102
97
  links.filter((link) =>
103
98
  this.linkClassifier.hasUsage(link, LinkUsage.MAP_API)
104
99
  )
105
- )
100
+ ),
101
+ shareReplay(1)
106
102
  )
107
103
 
108
104
  downloadLinks$ = this.allLinks$.pipe(
@@ -216,4 +212,11 @@ export class MdViewFacade {
216
212
  loadUserFeedbacks(datasetUuid: string) {
217
213
  this.store.dispatch(MdViewActions.loadUserFeedbacks({ datasetUuid }))
218
214
  }
215
+
216
+ /**
217
+ * loadFeatureCatalog
218
+ */
219
+ loadFeatureCatalog(metadata: CatalogRecord) {
220
+ this.store.dispatch(MdViewActions.loadFeatureCatalog({ metadata }))
221
+ }
219
222
  }
@@ -17,7 +17,7 @@ export * from './lib/facets/facets.module'
17
17
  export * from './lib/facets/facets-container/facets-container.component'
18
18
  export * from './lib/records-metrics/records-metrics.component'
19
19
  export * from './lib/favorites/favorite-star/favorite-star.component'
20
- export * from './lib/results-hits-number/results-hits.container.component'
20
+ export * from './lib/results-hits/results-hits.container.component'
21
21
  export * from './lib/results-layout/results-layout.component'
22
22
  export * from './lib/sort-by/sort-by.component'
23
23
  export * from './lib/state/container/search-state.container.directive'
@@ -12,6 +12,7 @@ export const FIELDS_SUMMARY: FieldName[] = [
12
12
  'overview',
13
13
  'logo',
14
14
  'codelist_status_text',
15
+ 'link',
15
16
  'linkProtocol',
16
17
  'contactForResource*.organisation*',
17
18
  'contact*.organisation*',
@@ -4,6 +4,7 @@ import { UiSearchModule } from '../../../../../libs/ui/search/src'
4
4
  import { EffectsModule } from '@ngrx/effects'
5
5
  import { StoreModule } from '@ngrx/store'
6
6
  import { TranslateModule } from '@ngx-translate/core'
7
+ import { NgIconsModule } from '@ng-icons/core'
7
8
  import { FacetsModule } from './facets/facets.module'
8
9
  import { FuzzySearchComponent } from './fuzzy-search/fuzzy-search.component'
9
10
  import { RecordsMetricsComponent } from './records-metrics/records-metrics.component'
@@ -12,7 +13,7 @@ import { ResultsListContainerComponent } from './results-list/results-list.conta
12
13
  import { SortByComponent } from './sort-by/sort-by.component'
13
14
  import { SearchEffects } from './state/effects'
14
15
  import { initialState, reducer, SEARCH_FEATURE_KEY } from './state/reducer'
15
- import { ResultsHitsContainerComponent } from './results-hits-number/results-hits.container.component'
16
+ import { ResultsHitsContainerComponent } from './results-hits/results-hits.container.component'
16
17
  import { SearchStateContainerDirective } from './state/container/search-state.container.directive'
17
18
  import {
18
19
  AutocompleteComponent,
@@ -20,7 +21,11 @@ import {
20
21
  UiInputsModule,
21
22
  } from '../../../../../libs/ui/inputs/src'
22
23
  import { NgModule } from '@angular/core'
23
- import { ErrorComponent, UiElementsModule } from '../../../../../libs/ui/elements/src'
24
+ import {
25
+ ErrorComponent,
26
+ KindBadgeComponent,
27
+ UiElementsModule,
28
+ } from '../../../../../libs/ui/elements/src'
24
29
  import { FilterDropdownComponent } from './filter-dropdown/filter-dropdown.component'
25
30
  import {
26
31
  SpinningLoaderComponent,
@@ -58,6 +63,8 @@ import { FavoriteStarComponent } from './favorites/favorite-star/favorite-star.c
58
63
  ErrorComponent,
59
64
  FavoriteStarComponent,
60
65
  DateRangeDropdownComponent,
66
+ NgIconsModule,
67
+ KindBadgeComponent,
61
68
  ],
62
69
  exports: [
63
70
  SortByComponent,
@@ -0,0 +1,16 @@
1
+ <div
2
+ class="flex flex-col gap-3 sm:flex-row justify-between"
3
+ [ngClass]="{
4
+ 'sm:items-center': (searchFacade.resultsHits$ | async) !== 0,
5
+ }"
6
+ >
7
+ <gn-ui-results-hits-number
8
+ [loading]="searchFacade.isLoading$ | async"
9
+ [hits]="searchFacade.resultsHits$ | async"
10
+ ></gn-ui-results-hits-number>
11
+ <gn-ui-results-hits-search-kind
12
+ (selectionChanged)="onSelectionChanged($event)"
13
+ [choices]="filterChoices$ | async"
14
+ [selected]="selected$ | async"
15
+ ></gn-ui-results-hits-search-kind>
16
+ </div>
@@ -0,0 +1,59 @@
1
+ import {
2
+ catchError,
3
+ filter,
4
+ map,
5
+ Observable,
6
+ of,
7
+ startWith,
8
+ switchMap,
9
+ } from 'rxjs'
10
+ import { Component, OnInit } from '@angular/core'
11
+ import { marker } from '@biesbjerg/ngx-translate-extract-marker'
12
+ import { SearchFacade } from '../state/search.facade'
13
+ import { FieldAvailableValue, FieldValue } from '../utils/service/fields'
14
+ import { SearchService } from '../utils/service/search.service'
15
+ import { FieldsService } from '../utils/service/fields.service'
16
+
17
+ marker('search.filters.recordKind.all')
18
+ marker('search.filters.recordKind.dataset')
19
+ marker('search.filters.recordKind.service')
20
+ marker('search.filters.recordKind.reuse')
21
+
22
+ @Component({
23
+ selector: 'gn-ui-results-hits',
24
+ templateUrl: './results-hits.container.component.html',
25
+ styleUrls: ['./results-hits.container.component.css'],
26
+ })
27
+ export class ResultsHitsContainerComponent implements OnInit {
28
+ fieldName = 'recordKind'
29
+ filterChoices$: Observable<FieldAvailableValue[]>
30
+ selected$: Observable<FieldValue[]>
31
+
32
+ constructor(
33
+ protected searchFacade: SearchFacade,
34
+ private searchService: SearchService,
35
+ private fieldsService: FieldsService
36
+ ) {}
37
+
38
+ ngOnInit() {
39
+ this.selected$ = this.searchFacade.searchFilters$.pipe(
40
+ switchMap((filters) =>
41
+ this.fieldsService.readFieldValuesFromFilters(filters)
42
+ ),
43
+ map((fieldValues) => fieldValues[this.fieldName]),
44
+ filter((selected) => !!selected),
45
+ startWith([]),
46
+ catchError(() => of([]))
47
+ ) as Observable<FieldValue[]>
48
+
49
+ this.filterChoices$ = <Observable<FieldAvailableValue[]>>(
50
+ this.fieldsService.getAvailableValues(this.fieldName)
51
+ )
52
+ }
53
+
54
+ onSelectionChanged(values: string[]) {
55
+ this.fieldsService
56
+ .buildFiltersFromFieldValues({ [this.fieldName]: values })
57
+ .subscribe((filters) => this.searchService.updateFilters(filters))
58
+ }
59
+ }
@@ -55,8 +55,10 @@ export class ResultsListContainerComponent implements OnInit {
55
55
  @Optional()
56
56
  @Inject(RECORD_DATASET_URL_TOKEN)
57
57
  private recordDatasetUrlTemplate: string,
58
+ @Optional()
58
59
  @Inject(RECORD_SERVICE_URL_TOKEN)
59
60
  private recordServiceUrlTemplate: string,
61
+ @Optional()
60
62
  @Inject(RECORD_REUSE_URL_TOKEN)
61
63
  private recordReuseUrlTemplate: string
62
64
  ) {}
@@ -10,8 +10,10 @@ import {
10
10
  MultilingualSearchField,
11
11
  OrganizationSearchField,
12
12
  OwnerSearchField,
13
+ ResourceTypeLegacyField,
13
14
  SimpleSearchField,
14
15
  TranslatedSearchField,
16
+ RecordKindField,
15
17
  UserSearchField,
16
18
  } from './fields'
17
19
  import { forkJoin, Observable, of } from 'rxjs'
@@ -47,11 +49,8 @@ export class FieldsService {
47
49
  protected fields = {
48
50
  organization: new OrganizationSearchField(this.injector),
49
51
  format: new SimpleSearchField('format', this.injector, 'asc'),
50
- resourceType: new TranslatedSearchField(
51
- 'resourceType',
52
- this.injector,
53
- 'asc'
54
- ),
52
+ resourceType: new ResourceTypeLegacyField(this.injector), // Deprecated, use `recordKind` instead
53
+ recordKind: new RecordKindField(this.injector),
55
54
  representationType: new TranslatedSearchField(
56
55
  'cl_spatialRepresentationType.key',
57
56
  this.injector,