@vcmap/ui 6.0.0-rc.9 → 6.0.0

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 (160) hide show
  1. package/README.md +2 -0
  2. package/build/commonViteConfig.js +7 -0
  3. package/config/aerowest.config.json +12 -2
  4. package/config/analysis.config.json +17 -0
  5. package/config/base.config.json +16 -4
  6. package/config/components-show-case.config.json +53 -0
  7. package/config/concepts-show-case.config.json +39 -0
  8. package/config/dev.config.json +165 -104
  9. package/config/dynamic-layer.config.json +32 -0
  10. package/config/hello-world.config.json +11 -0
  11. package/config/projects.config.json +9 -1
  12. package/config/solar.config.json +65 -0
  13. package/config/vectorTile.config.json +70 -0
  14. package/config/www.config.json +33 -10
  15. package/dist/assets/cesium.js +1 -1
  16. package/dist/assets/{core-ccecb5f4.js → core-a599e8b6.js} +7302 -6838
  17. package/dist/assets/core.js +1 -1
  18. package/dist/assets/{ol-3c6b9b5b.js → ol-21bbc740.js} +5057 -5178
  19. package/dist/assets/ol.js +1 -1
  20. package/dist/assets/ui-adeddc7d.css +1 -0
  21. package/dist/assets/{ui-8a8aef2a.js → ui-adeddc7d.js} +9687 -8940
  22. package/dist/assets/ui.js +1 -1
  23. package/dist/assets/vue.js +1 -1
  24. package/dist/assets/{vuetify-ac50bfc8.js → vuetify-c0e02f11.js} +2507 -2504
  25. package/dist/assets/vuetify.js +1 -1
  26. package/index.d.ts +2 -0
  27. package/index.js +1 -0
  28. package/package.json +12 -12
  29. package/plugins/@vcmap-show-case/README.md +15 -6
  30. package/plugins/@vcmap-show-case/category-tester/package.json +1 -1
  31. package/plugins/@vcmap-show-case/category-tester/src/CollectionComponentOptions.vue +23 -23
  32. package/plugins/@vcmap-show-case/category-tester/src/FoobarEditor.vue +2 -8
  33. package/plugins/@vcmap-show-case/collection-manager-example/package.json +1 -1
  34. package/plugins/@vcmap-show-case/collection-manager-example/src/CollectionManagerExample.vue +10 -8
  35. package/plugins/@vcmap-show-case/context-menu-tester/package.json +1 -1
  36. package/plugins/@vcmap-show-case/extent-example/package.json +1 -1
  37. package/plugins/@vcmap-show-case/flight-component-example/package.json +1 -1
  38. package/plugins/@vcmap-show-case/form-inputs-example/package.json +1 -1
  39. package/plugins/@vcmap-show-case/hello-world/package.json +1 -1
  40. package/plugins/@vcmap-show-case/icons-example/package.json +1 -1
  41. package/plugins/@vcmap-show-case/notifier-tester/package.json +1 -1
  42. package/plugins/@vcmap-show-case/panel-tester/package.json +1 -1
  43. package/plugins/@vcmap-show-case/plugin-editors/package.json +1 -1
  44. package/plugins/@vcmap-show-case/plugin-editors/src/index.js +17 -6
  45. package/plugins/@vcmap-show-case/project-selector/package.json +1 -9
  46. package/plugins/@vcmap-show-case/project-selector/src/ModulesListComponent.vue +22 -31
  47. package/plugins/@vcmap-show-case/project-selector/src/ProjectSelectorComponent.vue +15 -23
  48. package/plugins/@vcmap-show-case/projection-example/README.md +3 -0
  49. package/plugins/@vcmap-show-case/projection-example/package.json +5 -0
  50. package/plugins/@vcmap-show-case/projection-example/src/ProjectionExample.vue +73 -0
  51. package/plugins/@vcmap-show-case/{table-example → projection-example}/src/index.js +22 -11
  52. package/plugins/@vcmap-show-case/search-example/package.json +1 -1
  53. package/plugins/@vcmap-show-case/simple-graph/package.json +1 -4
  54. package/plugins/@vcmap-show-case/style-input-example/package.json +1 -1
  55. package/plugins/@vcmap-show-case/switch-map-callback-example/README.md +2 -2
  56. package/plugins/@vcmap-show-case/switch-map-callback-example/package.json +2 -1
  57. package/plugins/@vcmap-show-case/switch-map-callback-example/src/index.js +4 -1
  58. package/plugins/@vcmap-show-case/theming-example/package.json +1 -1
  59. package/plugins/@vcmap-show-case/toolbox-example/package.json +1 -1
  60. package/plugins/@vcmap-show-case/vector-properties-example/package.json +1 -1
  61. package/plugins/@vcmap-show-case/viewpoint-component-example/package.json +1 -1
  62. package/plugins/@vcmap-show-case/window-tester/package.json +1 -1
  63. package/plugins/@vcmap-show-case/window-tester/src/WindowExample.vue +1 -1
  64. package/plugins/@vcmap-show-case/window-tester/src/WindowExampleToggleChild.vue +5 -1
  65. package/plugins/@vcmap-show-case/wizard-example/package.json +1 -1
  66. package/plugins/package.json +7 -3
  67. package/src/actions/flightActions.js +40 -20
  68. package/src/actions/listActions.d.ts +1 -1
  69. package/src/actions/listActions.js +1 -1
  70. package/src/application/VcsApp.vue +3 -0
  71. package/src/application/VcsApp.vue.d.ts +12 -0
  72. package/src/application/VcsAttributions.vue +1 -1
  73. package/src/application/VcsAttributionsFooter.vue +1 -1
  74. package/src/application/VcsContainer.vue +0 -1
  75. package/src/application/VcsContainer.vue.d.ts +12 -0
  76. package/src/application/VcsObliqueFooter.vue +110 -0
  77. package/src/application/VcsObliqueFooter.vue.d.ts +4 -0
  78. package/src/application/VcsTextPageFooter.vue +1 -0
  79. package/src/application/attributionsHelper.js +10 -6
  80. package/src/components/flight/VcsFlightPlayer.vue +26 -20
  81. package/src/components/form-inputs-controls/VcsDatePicker.vue +23 -3
  82. package/src/components/form-inputs-controls/VcsDatePicker.vue.d.ts +1 -1
  83. package/src/components/form-inputs-controls/VcsFileInput.vue +1 -1
  84. package/src/components/form-inputs-controls/VcsLabel.vue +10 -1
  85. package/src/components/form-inputs-controls/VcsLabel.vue.d.ts +9 -0
  86. package/src/components/form-inputs-controls/VcsRadio.vue +4 -0
  87. package/src/components/form-inputs-controls/VcsSelect.vue.d.ts +2 -2
  88. package/src/components/form-inputs-controls/VcsTextField.vue +1 -1
  89. package/src/components/form-inputs-controls/VcsWizardStep.vue.d.ts +2 -2
  90. package/src/components/import/VcsImportComponent.vue +3 -3
  91. package/src/components/lists/VcsActionList.vue +1 -1
  92. package/src/components/lists/VcsList.vue +42 -29
  93. package/src/components/lists/VcsListItemComponent.vue +1 -1
  94. package/src/components/lists/VcsListItemComponent.vue.d.ts +5 -32
  95. package/src/components/lists/VcsTreeview.vue +2 -0
  96. package/src/components/notification/VcsHelp.vue +0 -1
  97. package/src/components/notification/VcsHelpTooltip.vue +48 -0
  98. package/src/components/notification/VcsHelpTooltip.vue.d.ts +25 -0
  99. package/src/components/projection/VcsProjection.vue +329 -0
  100. package/src/components/projection/VcsProjection.vue.d.ts +7 -0
  101. package/src/components/section/VcsFormSection.vue +0 -1
  102. package/src/components/section/VcsFormSection.vue.d.ts +1 -1
  103. package/src/components/tables/VcsDataTable.vue +13 -2
  104. package/src/components/tables/VcsDataTable.vue.d.ts +12 -1
  105. package/src/components/vector-properties/VcsFeatureEditingWindow.vue +17 -1
  106. package/src/components/vector-properties/VcsFeatureEditingWindow.vue.d.ts +10 -1
  107. package/src/components/vector-properties/VcsFeatureTransforms.vue +39 -5
  108. package/src/components/vector-properties/VcsFeatureTransforms.vue.d.ts +2 -1
  109. package/src/components/vector-properties/VcsVectorPropertiesComponent.vue +44 -24
  110. package/src/components/vector-properties/VcsVectorPropertiesComponent.vue.d.ts +27 -2
  111. package/src/components/viewpoint/VcsViewpointComponent.vue +6 -6
  112. package/src/contentTree/contentTreeCollection.js +12 -1
  113. package/src/featureInfo/abstractFeatureInfoView.d.ts +9 -0
  114. package/src/featureInfo/abstractFeatureInfoView.js +17 -1
  115. package/src/i18n/de.d.ts +90 -41
  116. package/src/i18n/de.js +63 -22
  117. package/src/i18n/en.d.ts +90 -41
  118. package/src/i18n/en.js +59 -18
  119. package/src/legend/StyleLegendItem.vue +1 -5
  120. package/src/legend/VcsLegend.vue +9 -10
  121. package/src/legend/VcsLegend.vue.d.ts +1 -1
  122. package/src/legend/legendHelper.js +6 -1
  123. package/src/manager/collectionManager/collectionComponentClass.js +4 -4
  124. package/src/manager/collectionManager/editorCollectionComponentClass.js +5 -3
  125. package/src/manager/toolbox/GroupToolboxComponent.vue +6 -1
  126. package/src/manager/toolbox/SelectToolboxComponent.vue +6 -2
  127. package/src/manager/toolbox/ToolboxManagerComponent.vue +7 -2
  128. package/src/manager/window/WindowComponentHeader.vue +1 -1
  129. package/src/navigation/MapNavCompass.vue +166 -140
  130. package/src/navigation/MapNavCompass.vue.d.ts +3 -1
  131. package/src/navigation/MapNavigation.vue +22 -5
  132. package/src/navigation/VcsCompass.vue +2 -1
  133. package/src/navigation/overviewMap.js +4 -1
  134. package/src/styles/main.scss +2 -2
  135. package/src/uiConfig.d.ts +27 -0
  136. package/src/uiConfig.js +3 -0
  137. package/src/vuePlugins/vuetify.js +2 -0
  138. package/dist/assets/ui-8a8aef2a.css +0 -1
  139. package/plugins/@vcmap-show-case/buttons-example/README.md +0 -4
  140. package/plugins/@vcmap-show-case/buttons-example/package.json +0 -5
  141. package/plugins/@vcmap-show-case/buttons-example/src/ButtonsExample.vue +0 -281
  142. package/plugins/@vcmap-show-case/buttons-example/src/index.js +0 -51
  143. package/plugins/@vcmap-show-case/config-editor/README.md +0 -3
  144. package/plugins/@vcmap-show-case/config-editor/package.json +0 -5
  145. package/plugins/@vcmap-show-case/config-editor/src/ConfigEditor.vue +0 -62
  146. package/plugins/@vcmap-show-case/config-editor/src/index.js +0 -49
  147. package/plugins/@vcmap-show-case/list-example/README.md +0 -3
  148. package/plugins/@vcmap-show-case/list-example/package.json +0 -5
  149. package/plugins/@vcmap-show-case/list-example/src/ListExample.vue +0 -406
  150. package/plugins/@vcmap-show-case/list-example/src/index.js +0 -46
  151. package/plugins/@vcmap-show-case/table-example/README.md +0 -3
  152. package/plugins/@vcmap-show-case/table-example/package.json +0 -5
  153. package/plugins/@vcmap-show-case/table-example/src/DataTableExample.vue +0 -203
  154. package/plugins/@vcmap-show-case/textfields-example/README.md +0 -3
  155. package/plugins/@vcmap-show-case/textfields-example/package.json +0 -5
  156. package/plugins/@vcmap-show-case/textfields-example/src/TextfieldsExample.vue +0 -115
  157. package/plugins/@vcmap-show-case/textfields-example/src/index.js +0 -64
  158. /package/dist/assets/{cesium-a21a380a.js → cesium-00deba88.js} +0 -0
  159. /package/dist/assets/{vue-bcc58dd1.js → vue-8269279d.js} +0 -0
  160. /package/dist/assets/{vuetify-ac50bfc8.css → vuetify-c0e02f11.css} +0 -0
@@ -1,11 +1,11 @@
1
1
  import { ButtonLocation, createToggleAction, WindowSlot } from '@vcmap/ui';
2
2
  import packageJSON from '../package.json';
3
- import DataTableExample from './DataTableExample.vue';
3
+ import ProjectionExample from './ProjectionExample.vue';
4
4
 
5
5
  /**
6
6
  * @returns {VcsPlugin}
7
7
  */
8
- export default async function iconsExample() {
8
+ export default async function projectionExample() {
9
9
  return {
10
10
  get name() {
11
11
  return packageJSON.name;
@@ -16,21 +16,20 @@ export default async function iconsExample() {
16
16
  get mapVersion() {
17
17
  return packageJSON.mapVersion;
18
18
  },
19
- onVcsAppMounted(app) {
19
+ initialize(app) {
20
20
  const { action, destroy } = createToggleAction(
21
21
  {
22
- name: 'Table Example',
23
- title: 'Table Example Plugin',
22
+ name: 'Projection Example',
23
+ title: 'Projection Example Plugin',
24
+ icon: '$vcsBoundingBox',
24
25
  },
25
26
  {
26
- id: 'table-example',
27
- component: DataTableExample,
27
+ id: 'projection-example',
28
+ component: ProjectionExample,
28
29
  slot: WindowSlot.DYNAMIC_LEFT,
29
30
  state: {
30
- headerTitle: 'Table Example',
31
- },
32
- position: {
33
- width: 500,
31
+ headerTitle: 'Projection Example',
32
+ headerIcon: '$vcsBoundingBox',
34
33
  },
35
34
  },
36
35
  app.windowManager,
@@ -39,6 +38,18 @@ export default async function iconsExample() {
39
38
  app.navbarManager.add({ action }, packageJSON.name, ButtonLocation.TOOL);
40
39
  this._destroyAction = destroy;
41
40
  },
41
+ i18n: {
42
+ de: {
43
+ projectionExample: {
44
+ openDialog: 'Dialog öffnen',
45
+ log: 'Log',
46
+ },
47
+ },
48
+ en: {
49
+ openDialog: 'Open Dialog',
50
+ log: 'Log',
51
+ },
52
+ },
42
53
  destroy() {
43
54
  if (this._destroyAction) {
44
55
  this._destroyAction();
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/search-example",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^6.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -1,11 +1,8 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/simple-graph",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^5.0.0",
4
+ "mapVersion": "^6.0",
5
5
  "dependencies": {
6
6
  "@vcsuite/parsers": "^1.0.1"
7
- },
8
- "peerDependencies": {
9
- "@vcmap/ui": "5.0.0-rc.2"
10
7
  }
11
8
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/style-input-example",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^5.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -1,9 +1,9 @@
1
1
  # @vcmap-show-case/switch-map-callback-example
2
2
 
3
- This plugin adds a MapSwitcherCallback to the uiApp.
3
+ This plugin demonstrates the concept of `VcsCallback` by adding a MapSwitcherCallback to the uiApp.
4
4
 
5
5
  This can be used to switch the map i the ContentTree,
6
- on Click of an Item.
6
+ on Click of a ContentTreeItem.
7
7
 
8
8
  ```json
9
9
 
@@ -1,5 +1,6 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/switch-map-callback-example",
3
3
  "version": "1.0.0",
4
- "description": "An Example plugin to add a Map Switcher Callback"
4
+ "description": "An Example plugin to add a Map Switcher Callback",
5
+ "mapVersion": "^6.0"
5
6
  }
@@ -1,4 +1,4 @@
1
- import { version, name } from '../package.json';
1
+ import { version, mapVersion, name } from '../package.json';
2
2
  import SwitchMapCallback from './switchMapCallback.js';
3
3
 
4
4
  /**
@@ -13,6 +13,9 @@ export default function switchMapCallbackExample() {
13
13
  get version() {
14
14
  return version;
15
15
  },
16
+ get mapVersion() {
17
+ return mapVersion;
18
+ },
16
19
  /**
17
20
  * @param {import("@vcmap/ui").VcsUiApp} vcsUiApp
18
21
  */
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/theming-example",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^6.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/toolbox-example",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^5.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/vector-properties-example",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^5.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/viewpoint-component-example",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^5.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/window-tester",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^5.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -4,7 +4,7 @@
4
4
  v-for="(example, index) in examples"
5
5
  :key="`b-${index}`"
6
6
  @click="(e) => toggle(e, example)"
7
- class="pa-1"
7
+ class="ma-1"
8
8
  >
9
9
  toggle {{ example }}
10
10
  </VcsFormButton>
@@ -1,6 +1,10 @@
1
1
  <template>
2
2
  <v-container>
3
- <VcsFormButton v-for="num in [1, 2]" :key="num" @click.stop="toggle(num)"
3
+ <VcsFormButton
4
+ v-for="num in [1, 2]"
5
+ :key="num"
6
+ @click.stop="toggle(num)"
7
+ class="ma-1"
4
8
  >toggle child {{ num }}</VcsFormButton
5
9
  >
6
10
  </v-container>
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@vcmap-show-case/wizard-example",
3
3
  "version": "1.0.0",
4
- "mapVersion": "^5.0.0"
4
+ "mapVersion": "^6.0"
5
5
  }
@@ -9,7 +9,7 @@
9
9
  "@vcmap/swipe-tool": "https://github.com/virtualcitySYSTEMS/map-swipe-tool.git#main",
10
10
  "@vcmap/export": "https://github.com/virtualcitySYSTEMS/map-export.git#main",
11
11
  "@vcmap/viewshed": "https://github.com/virtualcitySYSTEMS/map-viewshed.git#main",
12
- "@vcmap/measurement": "https://github.com/virtualcitySYSTEMS/map-measurement.git#main",
12
+ "@vcmap/measurement": "^2.0.0-rc.2",
13
13
  "@vcmap/multi-view": "https://github.com/virtualcitySYSTEMS/map-multi-view.git#main",
14
14
  "@vcmap/draw": "https://github.com/virtualcitySYSTEMS/map-draw.git#main",
15
15
  "@vcmap/shadow": "https://github.com/virtualcitySYSTEMS/map-shadow.git#main",
@@ -19,9 +19,13 @@
19
19
  "@vcmap/link-button": "https://github.com/virtualcitySYSTEMS/map-link-button.git#main",
20
20
  "@vcmap/cesium-filters": "https://github.com/virtualcitySYSTEMS/map-cesium-filters.git#main",
21
21
  "@vcmap/search-nominatim": "https://github.com/virtualcitySYSTEMS/map-search-nominatim.git#main",
22
- "@vcmap/create-link": "https://github.com/virtualcitySYSTEMS/map-create-link.git#main"
22
+ "@vcmap/create-link": "https://github.com/virtualcitySYSTEMS/map-create-link.git#main",
23
+ "@vcmap/module-selector": "^2.0.0",
24
+ "@vcmap/dynamic-layer": "git+ssh://git@gitlab.virtualcitysystems.de/vcsuite/npm/vcmap/dynamic-layer.git#feature-idra-catalogue",
25
+ "@vcmap/line-of-sight": "git+ssh://git@gitlab.virtualcitysystems.de/vcsuite/npm/vcmap/line-of-sight.git#feature-v1"
23
26
  },
24
27
  "optionalDependencies": {
25
- "@vcmap/planning": "^6.0.0-rc.1"
28
+ "@vcmap/planning": "^6.0.0-rc.2",
29
+ "@vcmap/solar-revenue": "^2.0.0-rc.1"
26
30
  }
27
31
  }
@@ -36,33 +36,54 @@ export function createPlayAction(app, instance) {
36
36
  } else {
37
37
  player = await app.flights.setPlayerForFlight(instance);
38
38
  if (player) {
39
- stateListener = player.stateChanged.addEventListener((state) => {
40
- if (state === 'stopped') {
41
- action.icon = '$vcsPlayCircle';
42
- action.title = 'flight.playTooltip';
43
- } else if (state === 'paused') {
44
- action.icon = '$vcsPlayCircle';
45
- action.title = 'flight.playTooltip';
46
- } else {
47
- action.icon = 'mdi-pause';
48
- action.title = 'flight.pauseTooltip';
49
- }
50
- });
51
- destroyListener = player.destroyed.addEventListener(() => {
52
- player = null;
53
- action.icon = '$vcsPlayCircle';
54
- stateListener();
55
- destroyListener();
56
- });
57
39
  player.play();
58
40
  }
59
41
  }
60
42
  },
61
43
  });
62
44
 
45
+ function updateAction(state) {
46
+ if (state === 'stopped' || state === 'paused') {
47
+ action.icon = '$vcsPlayCircle';
48
+ action.title = 'flight.playTooltip';
49
+ } else {
50
+ action.icon = 'mdi-pause';
51
+ action.title = 'flight.pauseTooltip';
52
+ }
53
+ }
54
+
55
+ function destroyPlayer() {
56
+ player = undefined;
57
+ updateAction('stopped');
58
+ stateListener?.();
59
+ destroyListener?.();
60
+ }
61
+
62
+ function checkPlayer(_player) {
63
+ if (_player?.flightInstanceName === instance.name) {
64
+ player = _player;
65
+ updateAction(player.state);
66
+ stateListener = player.stateChanged.addEventListener((state) => {
67
+ updateAction(state);
68
+ });
69
+ destroyListener = player.destroyed.addEventListener(() => {
70
+ destroyPlayer();
71
+ });
72
+ } else {
73
+ destroyPlayer();
74
+ }
75
+ }
76
+ const playerListener = app.flights.playerChanged.addEventListener(
77
+ (_player) => {
78
+ checkPlayer(_player);
79
+ },
80
+ );
81
+ checkPlayer(app.flights.player);
82
+
63
83
  return {
64
84
  action,
65
85
  destroy: () => {
86
+ playerListener();
66
87
  if (player) {
67
88
  player.stop();
68
89
  player.destroy();
@@ -348,7 +369,7 @@ export async function createFlightVisualizationAction(
348
369
  const action = reactive({
349
370
  name: 'components.flight.hidePath',
350
371
  title: 'components.flight.hidePath',
351
- icon: 'mdi-eye-outline',
372
+ icon: '$vcsEye',
352
373
  active,
353
374
  async callback() {
354
375
  if (!flightVis) {
@@ -360,7 +381,6 @@ export async function createFlightVisualizationAction(
360
381
  await flightVis.activate();
361
382
  }
362
383
  this.active = !this.active;
363
- this.icon = this.active ? 'mdi-eye-outline' : 'mdi-eye-off-outline';
364
384
  },
365
385
  });
366
386
 
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Creates an action for renaming an item in a VcsList.
2
+ * Creates an action for deleting an item in a VcsList.
3
3
  * @param {import("@vcmap/core").Collection<T>} collection
4
4
  * @param {T} item
5
5
  * @param {Partial<import("./actionHelper.js").ActionOptions>} [actionOptions={}]
@@ -9,7 +9,7 @@ import { vcsAppSymbol } from '../pluginHelper.js';
9
9
  import { NotificationType } from '../notifier/notifier.js';
10
10
 
11
11
  /**
12
- * Creates an action for renaming an item in a VcsList.
12
+ * Creates an action for deleting an item in a VcsList.
13
13
  * @param {import("@vcmap/core").Collection<T>} collection
14
14
  * @param {T} item
15
15
  * @param {Partial<import("./actionHelper.js").ActionOptions>} [actionOptions={}]
@@ -15,6 +15,7 @@
15
15
  class="d-flex gc-1 pa-0"
16
16
  >
17
17
  <VcsPositionDisplay />
18
+ <VcsObliqueFooter />
18
19
  <VcsTextPageFooter
19
20
  v-if="imprint"
20
21
  :text-page="imprint"
@@ -66,6 +67,7 @@
66
67
  import VcsLegend from '../legend/VcsLegend.vue';
67
68
  import { getLegendEntries } from '../legend/legendHelper.js';
68
69
  import VcsAttributionsFooter from './VcsAttributionsFooter.vue';
70
+ import VcsObliqueFooter from './VcsObliqueFooter.vue';
69
71
  import VcsTextPageFooter from './VcsTextPageFooter.vue';
70
72
  import VcsSplashScreen from './VcsSplashScreen.vue';
71
73
  import VcsTextPage from './VcsTextPage.vue';
@@ -723,6 +725,7 @@
723
725
  VcsPositionDisplay,
724
726
  VcsAttributionsFooter,
725
727
  VcsTextPageFooter,
728
+ VcsObliqueFooter,
726
729
  VcsSplashScreen,
727
730
  VcsNavbar,
728
731
  VContainer,
@@ -110,6 +110,10 @@ declare const _default: import("vue").DefineComponent<{
110
110
  * - mouse event, when position display is updated. Either 'click' (default) or 'move'.
111
111
  */
112
112
  readonly positionDisplayEventType?: string | undefined;
113
+ /**
114
+ * - A template for rendering information of the current image in oblique mode, e.g. '{{ name }}' printing the image's name
115
+ */
116
+ readonly obliqueFooterTemplate?: string | undefined;
113
117
  /**
114
118
  * - an optional URL to a help landing page
115
119
  */
@@ -282,10 +286,18 @@ declare const _default: import("vue").DefineComponent<{
282
286
  * - can be used to hide the settings Window
283
287
  */
284
288
  readonly hideSettings?: boolean | undefined;
289
+ /**
290
+ * - can be used to hide the oblique name in the footer
291
+ */
292
+ readonly hideObliqueFooter?: boolean | undefined;
285
293
  /**
286
294
  * - can be used to activate the overviewMap on startup
287
295
  */
288
296
  readonly overviewMapActiveOnStartup?: boolean | undefined;
297
+ /**
298
+ * - can be used to activate a contentTree on startup
299
+ */
300
+ readonly contentTreeActiveOnStartup?: boolean | undefined;
289
301
  /**
290
302
  * - the display quality settings
291
303
  */
@@ -12,7 +12,7 @@
12
12
  :key="attribution.provider"
13
13
  :title="`${$st(attribution.provider)} ${attribution.year}`"
14
14
  >
15
- <a :href="attribution.url" target="_blank">
15
+ <a :href="attribution.url ? attribution.url : null" target="_blank">
16
16
  {{ $st(attribution.provider) }} {{ attribution.year }}
17
17
  </a>
18
18
  </v-list-item-subtitle>
@@ -8,7 +8,7 @@
8
8
  class="attribution"
9
9
  :key="attribution.provider"
10
10
  >
11
- <a :href="attribution.url" target="_blank">
11
+ <a :href="attribution.url ? attribution.url : null" target="_blank">
12
12
  {{ $st(attribution.provider) }} <span>{{ attribution.years }}</span>
13
13
  </a>
14
14
  </span>
@@ -9,7 +9,6 @@
9
9
  }"
10
10
  fluid
11
11
  absolute
12
- style="background: #1b5e20"
13
12
  >
14
13
  <template v-if="xs">
15
14
  <img
@@ -30,6 +30,10 @@ declare const _default: import("vue").DefineComponent<{
30
30
  * - mouse event, when position display is updated. Either 'click' (default) or 'move'.
31
31
  */
32
32
  readonly positionDisplayEventType?: string | undefined;
33
+ /**
34
+ * - A template for rendering information of the current image in oblique mode, e.g. '{{ name }}' printing the image's name
35
+ */
36
+ readonly obliqueFooterTemplate?: string | undefined;
33
37
  /**
34
38
  * - an optional URL to a help landing page
35
39
  */
@@ -202,10 +206,18 @@ declare const _default: import("vue").DefineComponent<{
202
206
  * - can be used to hide the settings Window
203
207
  */
204
208
  readonly hideSettings?: boolean | undefined;
209
+ /**
210
+ * - can be used to hide the oblique name in the footer
211
+ */
212
+ readonly hideObliqueFooter?: boolean | undefined;
205
213
  /**
206
214
  * - can be used to activate the overviewMap on startup
207
215
  */
208
216
  readonly overviewMapActiveOnStartup?: boolean | undefined;
217
+ /**
218
+ * - can be used to activate a contentTree on startup
219
+ */
220
+ readonly contentTreeActiveOnStartup?: boolean | undefined;
209
221
  /**
210
222
  * - the display quality settings
211
223
  */
@@ -0,0 +1,110 @@
1
+ <template>
2
+ <span
3
+ v-if="content"
4
+ class="d-flex align-center overflow-hidden vcs-oblique-footer"
5
+ v-html="content"
6
+ />
7
+ </template>
8
+
9
+ <style lang="scss" scoped>
10
+ .vcs-oblique-footer {
11
+ :deep(p) {
12
+ font-size: smaller;
13
+ margin: 0;
14
+ }
15
+ }
16
+ </style>
17
+
18
+ <script>
19
+ import { computed, inject, onUnmounted, shallowRef } from 'vue';
20
+ import { ObliqueMap, ObliqueViewDirection } from '@vcmap/core';
21
+ import { renderTemplate } from '../components/form-output/markdownHelper.js';
22
+
23
+ const i18nViewDirection = {
24
+ [ObliqueViewDirection.NORTH]: 'footer.oblique.north',
25
+ [ObliqueViewDirection.EAST]: 'footer.oblique.east',
26
+ [ObliqueViewDirection.SOUTH]: 'footer.oblique.south',
27
+ [ObliqueViewDirection.WEST]: 'footer.oblique.west',
28
+ [ObliqueViewDirection.NADIR]: 'footer.oblique.nadir',
29
+ };
30
+
31
+ /**
32
+ * @description Renders image information according to configured markdown template
33
+ * @vue-computed {string} content - the derived rendered image information
34
+ */
35
+ export default {
36
+ name: 'VcsObliqueFooter',
37
+ setup() {
38
+ const app = inject('vcsApp');
39
+
40
+ /**
41
+ * @returns {import("@vcmap/core").ObliqueImage|null}
42
+ */
43
+ function getImage() {
44
+ const map = app.maps.activeMap;
45
+ if (map instanceof ObliqueMap) {
46
+ return map.currentImage;
47
+ }
48
+ return null;
49
+ }
50
+
51
+ /**
52
+ * @param {import("@vcmap/core").ObliqueImage?} image
53
+ * @returns {import("@vcmap/core").ObliqueImage & {viewDirection: string}|null}
54
+ */
55
+ function getTranslatedImageInfo(image) {
56
+ if (image) {
57
+ return {
58
+ ...image,
59
+ viewDirection: app.vueI18n.t(
60
+ i18nViewDirection[image.viewDirection],
61
+ ),
62
+ };
63
+ }
64
+ return null;
65
+ }
66
+
67
+ const currentImage = shallowRef(getImage());
68
+
69
+ let imageChangedListener = () => {};
70
+ const mapChangedListener = app.maps.mapActivated.addEventListener(
71
+ (map) => {
72
+ imageChangedListener();
73
+ if (map instanceof ObliqueMap) {
74
+ currentImage.value = map.currentImage;
75
+ imageChangedListener = map.imageChanged.addEventListener(
76
+ (image) => {
77
+ currentImage.value = image;
78
+ },
79
+ );
80
+ } else if (currentImage.value) {
81
+ currentImage.value = null;
82
+ imageChangedListener = () => {};
83
+ }
84
+ },
85
+ );
86
+
87
+ onUnmounted(() => {
88
+ imageChangedListener();
89
+ mapChangedListener();
90
+ });
91
+
92
+ const content = computed(() => {
93
+ if (!app.uiConfig.config.hideObliqueFooter && currentImage.value) {
94
+ const template =
95
+ app.uiConfig.config.obliqueFooterTemplate ??
96
+ 'footer.oblique.template';
97
+ return renderTemplate(
98
+ app.vueI18n.te(template) ? app.vueI18n.tm(template) : template,
99
+ getTranslatedImageInfo(currentImage.value),
100
+ );
101
+ }
102
+ return null;
103
+ });
104
+
105
+ return {
106
+ content,
107
+ };
108
+ },
109
+ };
110
+ </script>
@@ -0,0 +1,4 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {
2
+ content: import("vue").ComputedRef<string | null>;
3
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
4
+ export default _default;
@@ -15,6 +15,7 @@
15
15
  >{{ $st(textPage.title) }}</span
16
16
  >
17
17
  <v-tooltip
18
+ v-if="$st(textPage.tooltip)"
18
19
  :text="$st(textPage.tooltip)"
19
20
  activator="parent"
20
21
  location="top"
@@ -107,14 +107,14 @@ export function getAttributions(app) {
107
107
  }
108
108
 
109
109
  /**
110
- * adds or removes a AttributionEntry on layer state changes
111
- * @param {import("@vcmap/core").VcsMap|import("@vcmap/core").Layer|import("@vcmap/core").ObliqueCollection} object
110
+ * adds or removes a AttributionEntry for layers or maps
111
+ * @param {import("@vcmap/core").VcsMap|import("@vcmap/core").Layer} object
112
112
  */
113
113
  function syncAttributions(object) {
114
114
  if (object?.properties?.attributions === undefined) {
115
115
  return;
116
116
  }
117
- if (object.active || object.loaded) {
117
+ if (object.active) {
118
118
  addAttributions(object);
119
119
  } else {
120
120
  removeAttributions(object);
@@ -138,9 +138,13 @@ export function getAttributions(app) {
138
138
  }
139
139
  });
140
140
  if (map instanceof ObliqueMap) {
141
- syncAttributions(map.collection);
142
- obliqueListener =
143
- map.collectionChanged.addEventListener(syncAttributions);
141
+ addAttributions(map.collection);
142
+ obliqueListener = map.collectionChanged.addEventListener(
143
+ (obliqueCollection) => {
144
+ [...app.obliqueCollections].forEach(removeAttributions);
145
+ addAttributions(obliqueCollection);
146
+ },
147
+ );
144
148
  }
145
149
  }
146
150