@vcmap/ui 6.0.0-rc.3 → 6.0.0-rc.6

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 (235) hide show
  1. package/build/buildHelpers.js +60 -11
  2. package/build/buildTypes.js +9 -5
  3. package/build/bundle.js +1 -1
  4. package/build/info/publish.js +25 -31
  5. package/build/lintTypes.js +5 -0
  6. package/config/base.config.json +2 -7
  7. package/config/dev.config.json +11 -1
  8. package/config/projects.config.json +2 -1
  9. package/config/theming.config.json +68 -0
  10. package/config/www.config.json +27 -23
  11. package/dist/assets/@mdi/font/css/{materialdesignicons.min-7a4f6be0.css → materialdesignicons.min-680621ca.css} +1 -1
  12. package/dist/assets/{cesium-cb4dbfba.js → cesium-ccb4cc30.js} +272 -385
  13. package/dist/assets/cesium.js +1 -1
  14. package/dist/assets/{core-72f21835.js → core-e06aa7a6.js} +2313 -2321
  15. package/dist/assets/core.js +1 -1
  16. package/dist/assets/{ol-2d33bc8b.js → ol-e7981d5c.js} +233 -329
  17. package/dist/assets/ol.js +1 -1
  18. package/dist/assets/ui-5dda32d2.css +1 -0
  19. package/dist/assets/{ui-2ab43a16.js → ui-5dda32d2.js} +11344 -11078
  20. package/dist/assets/ui.js +1 -1
  21. package/dist/assets/vue-87bc6efe.js +6083 -0
  22. package/dist/assets/vue.js +1 -1
  23. package/dist/assets/{vuetify-760ced3b.css → vuetify-4c4e4217.css} +2 -2
  24. package/dist/assets/{vuetify-760ced3b.js → vuetify-4c4e4217.js} +8063 -8262
  25. package/dist/assets/vuetify.js +1 -1
  26. package/index.d.ts +27 -17
  27. package/index.js +16 -8
  28. package/package.json +17 -17
  29. package/plugins/@vcmap-show-case/custom-icons-example/README.md +3 -0
  30. package/plugins/@vcmap-show-case/custom-icons-example/assets/imageExample.png +0 -0
  31. package/plugins/@vcmap-show-case/custom-icons-example/assets/svgExample.svg +1 -0
  32. package/plugins/@vcmap-show-case/custom-icons-example/package.json +5 -0
  33. package/plugins/@vcmap-show-case/custom-icons-example/src/CustomIconsExample.vue +90 -0
  34. package/plugins/@vcmap-show-case/custom-icons-example/src/index.js +45 -0
  35. package/plugins/@vcmap-show-case/form-inputs-example/src/FormInputsExample.vue +2 -3
  36. package/plugins/@vcmap-show-case/plugin-editors/src/PluginEditors.vue +11 -7
  37. package/plugins/@vcmap-show-case/project-selector/src/ModulesListComponent.vue +18 -11
  38. package/plugins/@vcmap-show-case/search-example/src/index.js +1 -0
  39. package/plugins/@vcmap-show-case/search-example/src/searchImpl.js +35 -5
  40. package/plugins/@vcmap-show-case/theming-example/README.md +3 -0
  41. package/plugins/@vcmap-show-case/theming-example/package.json +5 -0
  42. package/plugins/@vcmap-show-case/theming-example/src/ThemingExample.vue +116 -0
  43. package/plugins/@vcmap-show-case/theming-example/src/index.js +53 -0
  44. package/plugins/@vcmap-show-case/toolbox-example/src/index.js +2 -1
  45. package/plugins/package.json +7 -23
  46. package/public/assets/@mdi/font/css/materialdesignicons.min.css +1 -1
  47. package/src/actions/StyleSelector.vue +1 -1
  48. package/src/actions/actionHelper.d.ts +4 -11
  49. package/src/actions/actionHelper.js +15 -7
  50. package/src/actions/listActions.d.ts +5 -5
  51. package/src/actions/listActions.js +2 -2
  52. package/src/application/VcsApp.vue +113 -50
  53. package/src/application/VcsApp.vue.d.ts +301 -4
  54. package/src/application/VcsAttributionsFooter.vue.d.ts +1 -1
  55. package/src/application/VcsContainer.vue +27 -10
  56. package/src/application/VcsContainer.vue.d.ts +241 -0
  57. package/src/application/VcsMainMap.vue +7 -7
  58. package/src/application/VcsMainMap.vue.d.ts +2 -2
  59. package/src/application/VcsNavbar.vue +14 -2
  60. package/src/application/VcsNavbar.vue.d.ts +1 -0
  61. package/src/application/VcsSplashScreen.vue +33 -26
  62. package/src/application/VcsTextPageFooter.vue +2 -1
  63. package/src/application/attributionsHelper.d.ts +20 -22
  64. package/src/application/attributionsHelper.js +4 -4
  65. package/src/callback/vcsCallback.d.ts +2 -2
  66. package/src/callback/vcsCallback.js +1 -1
  67. package/src/components/buttons/VcsActionButtonList.vue +61 -6
  68. package/src/components/buttons/VcsActionButtonList.vue.d.ts +28 -0
  69. package/src/components/buttons/VcsButton.vue +2 -4
  70. package/src/components/buttons/VcsButton.vue.d.ts +1 -1
  71. package/src/components/buttons/VcsFormButton.vue +4 -4
  72. package/src/components/buttons/VcsToolButton.vue +4 -2
  73. package/src/components/buttons/VcsToolButton.vue.d.ts +2 -2
  74. package/src/components/composables.d.ts +5 -0
  75. package/src/components/composables.js +79 -9
  76. package/src/components/extent/VcsExtent.vue +10 -6
  77. package/src/components/extent/VcsExtent.vue.d.ts +1 -0
  78. package/src/components/flight/VcsFlightComponent.vue +13 -13
  79. package/src/components/flight/VcsFlightComponent.vue.d.ts +1 -0
  80. package/src/components/form-inputs-controls/VcsCheckbox.vue +8 -3
  81. package/src/components/form-inputs-controls/VcsChipArrayInput.vue +13 -16
  82. package/src/components/form-inputs-controls/VcsChipArrayInput.vue.d.ts +2 -4
  83. package/src/components/form-inputs-controls/VcsCoordinate.vue +4 -4
  84. package/src/components/form-inputs-controls/VcsFileInput.vue +1 -1
  85. package/src/components/form-inputs-controls/VcsLabel.vue +1 -1
  86. package/src/components/form-inputs-controls/VcsRadio.vue +8 -6
  87. package/src/components/form-inputs-controls/VcsRadio.vue.d.ts +1 -0
  88. package/src/components/form-inputs-controls/VcsSelect.vue +2 -5
  89. package/src/components/form-inputs-controls/VcsSlider.vue +5 -6
  90. package/src/components/form-inputs-controls/VcsSlider.vue.d.ts +2 -4
  91. package/src/components/form-inputs-controls/VcsTextArea.vue +2 -5
  92. package/src/components/form-inputs-controls/VcsTextField.vue +24 -1
  93. package/src/components/form-inputs-controls/VcsTextField.vue.d.ts +11 -1
  94. package/src/components/form-inputs-controls/VcsWizard.vue +3 -3
  95. package/src/components/form-inputs-controls/VcsWizardStep.vue +6 -5
  96. package/src/components/form-inputs-controls/vcsTextField.scss +8 -5
  97. package/src/components/form-output/VcsFormattedNumber.vue +7 -5
  98. package/src/components/form-output/VcsMarkdown.vue +15 -12
  99. package/src/components/form-output/VcsMarkdown.vue.d.ts +1 -0
  100. package/src/components/form-output/markdownHelper.d.ts +30 -0
  101. package/src/components/form-output/markdownHelper.js +398 -0
  102. package/src/components/import/VcsFileDrop.vue +8 -5
  103. package/src/components/import/VcsImportComponent.vue +8 -4
  104. package/src/components/import/VcsImportComponent.vue.d.ts +1 -2
  105. package/src/components/lists/VcsActionList.vue +6 -6
  106. package/src/components/lists/VcsList.vue +22 -37
  107. package/src/components/lists/VcsList.vue.d.ts +14 -55
  108. package/src/components/lists/{VcsListItem.vue → VcsListItemComponent.vue} +37 -11
  109. package/src/components/lists/VcsListItemComponent.vue.d.ts +79 -0
  110. package/src/components/lists/VcsTreeview.vue +95 -26
  111. package/src/components/lists/VcsTreeview.vue.d.ts +16 -3
  112. package/src/components/lists/VcsTreeviewSearchbar.vue +16 -5
  113. package/src/components/lists/VcsTreeviewSearchbar.vue.d.ts +3 -1
  114. package/src/components/lists/VcsTreeviewTitle.vue +36 -0
  115. package/src/components/modelHelper.d.ts +10 -8
  116. package/src/components/modelHelper.js +8 -6
  117. package/src/components/notification/VcsHelp.vue +6 -7
  118. package/src/components/notification/VcsHelp.vue.d.ts +0 -8
  119. package/src/components/plugins/AbstractConfigEditor.vue +1 -22
  120. package/src/components/plugins/AbstractConfigEditor.vue.d.ts +6 -29
  121. package/src/components/section/VcsExpansionPanel.vue +9 -3
  122. package/src/components/section/VcsExpansionPanel.vue.d.ts +2 -2
  123. package/src/components/section/VcsFormSection.vue +13 -7
  124. package/src/components/section/VcsFormSection.vue.d.ts +2 -3
  125. package/src/components/style/VcsImageSelector.vue +14 -6
  126. package/src/components/style/VcsImageSelector.vue.d.ts +1 -0
  127. package/src/components/style/VcsStrokeSelector.vue +5 -2
  128. package/src/components/style/VcsStrokeSelector.vue.d.ts +1 -0
  129. package/src/components/style/VcsTextMenu.vue +3 -3
  130. package/src/components/style/VcsVectorStyleComponent.vue +1 -1
  131. package/src/components/tables/VcsDataTable.vue +42 -32
  132. package/src/components/tables/VcsDataTable.vue.d.ts +1 -0
  133. package/src/components/tables/VcsTable.vue +45 -62
  134. package/src/components/tables/VcsTable.vue.d.ts +30 -17
  135. package/src/components/tables/VcsTableCell.vue +72 -0
  136. package/src/components/tables/VcsTableCell.vue.d.ts +13 -0
  137. package/src/components/vector-properties/VcsFeatureEditingWindow.vue +6 -5
  138. package/src/components/vector-properties/VcsFeatureTransforms.vue +5 -0
  139. package/src/components/vector-properties/VcsVectorPropertiesComponent.vue +42 -31
  140. package/src/components/vector-properties/VcsVectorPropertiesComponent.vue.d.ts +1 -0
  141. package/src/components/viewpoint/VcsViewpointComponent.vue +14 -11
  142. package/src/components/viewpoint/VcsViewpointComponent.vue.d.ts +1 -0
  143. package/src/components/viewpoint/VcsViewpointEditor.vue +2 -2
  144. package/src/contentTree/LayerTree.vue +9 -27
  145. package/src/contentTree/LayerTree.vue.d.ts +1 -1
  146. package/src/contentTree/contentTreeCollection.d.ts +1 -0
  147. package/src/contentTree/contentTreeCollection.js +45 -11
  148. package/src/contentTree/contentTreeItem.d.ts +2 -2
  149. package/src/contentTree/contentTreeItem.js +1 -1
  150. package/src/featureInfo/BalloonComponent.vue +32 -25
  151. package/src/featureInfo/BalloonComponent.vue.d.ts +1 -0
  152. package/src/featureInfo/MarkdownBalloonComponent.vue +4 -2
  153. package/src/featureInfo/MarkdownBalloonComponent.vue.d.ts +2 -2
  154. package/src/featureInfo/abstractFeatureInfoView.d.ts +10 -4
  155. package/src/featureInfo/abstractFeatureInfoView.js +19 -11
  156. package/src/featureInfo/featureInfo.d.ts +7 -7
  157. package/src/featureInfo/featureInfo.js +51 -31
  158. package/src/featureInfo/iframeFeatureInfoView.d.ts +8 -2
  159. package/src/featureInfo/iframeFeatureInfoView.js +15 -5
  160. package/src/featureInfo/markdownBalloonFeatureInfoView.d.ts +1 -1
  161. package/src/featureInfo/markdownBalloonFeatureInfoView.js +5 -5
  162. package/src/featureInfo/markdownFeatureInfoView.d.ts +1 -1
  163. package/src/featureInfo/markdownFeatureInfoView.js +9 -11
  164. package/src/featureInfo/tableFeatureInfoView.js +13 -4
  165. package/src/i18n/i18nCollection.d.ts +9 -15
  166. package/src/i18n/i18nCollection.js +3 -3
  167. package/src/legend/VcsLegend.vue +6 -2
  168. package/src/legend/VcsLegend.vue.d.ts +1 -0
  169. package/src/manager/collectionManager/CollectionComponentList.vue +2 -2
  170. package/src/manager/collectionManager/CollectionComponentList.vue.d.ts +2 -2
  171. package/src/manager/collectionManager/categoryManager.d.ts +1 -1
  172. package/src/manager/collectionManager/collectionComponentClass.d.ts +3 -3
  173. package/src/manager/collectionManager/collectionComponentClass.js +6 -6
  174. package/src/manager/collectionManager/collectionManager.d.ts +1 -1
  175. package/src/manager/collectionManager/editorCollectionComponentClass.js +2 -1
  176. package/src/manager/panel/PanelComponent.vue +2 -9
  177. package/src/manager/panel/PanelManagerComponent.vue +7 -3
  178. package/src/manager/panel/panelHelper.js +3 -3
  179. package/src/manager/panel/panelManager.d.ts +9 -1
  180. package/src/manager/panel/panelManager.js +15 -3
  181. package/src/manager/toolbox/GroupToolboxComponent.vue +11 -5
  182. package/src/manager/toolbox/GroupToolboxComponent.vue.d.ts +1 -0
  183. package/src/manager/toolbox/SelectToolboxComponent.vue +11 -6
  184. package/src/manager/toolbox/SelectToolboxComponent.vue.d.ts +1 -0
  185. package/src/manager/toolbox/{ToolboxManager.vue → ToolboxManagerComponent.vue} +13 -7
  186. package/src/manager/toolbox/{ToolboxManager.vue.d.ts → ToolboxManagerComponent.vue.d.ts} +1 -0
  187. package/src/manager/window/WindowComponent.vue +12 -8
  188. package/src/manager/window/WindowComponentHeader.vue +33 -9
  189. package/src/manager/window/WindowComponentHeader.vue.d.ts +3 -0
  190. package/src/manager/window/WindowManager.vue +2 -2
  191. package/src/manager/window/windowManager.d.ts +6 -6
  192. package/src/manager/window/windowManager.js +3 -3
  193. package/src/navigation/MapNavigation.vue +20 -0
  194. package/src/navigation/OrientationToolsButton.vue +2 -4
  195. package/src/navigation/TiltSlider.vue +3 -5
  196. package/src/navigation/locatorHelper.js +1 -1
  197. package/src/navigation/overviewMap.js +1 -1
  198. package/src/notifier/NotifierComponent.vue +18 -15
  199. package/src/search/ResultItem.vue +18 -6
  200. package/src/search/ResultsComponent.vue +31 -20
  201. package/src/search/ResultsComponent.vue.d.ts +2 -1
  202. package/src/search/SearchComponent.vue +11 -15
  203. package/src/search/SearchComponent.vue.d.ts +1 -0
  204. package/src/siteConfig.js +8 -8
  205. package/src/styles/_typography.scss +0 -2
  206. package/src/styles/main.scss +0 -4
  207. package/src/styles/vcsList.scss +1 -1
  208. package/src/uiConfig.d.ts +311 -7
  209. package/src/uiConfig.js +30 -17
  210. package/src/vcsUiApp.d.ts +48 -63
  211. package/src/vcsUiApp.js +44 -37
  212. package/src/vuePlugins/vuetify.d.ts +88 -62
  213. package/src/vuePlugins/vuetify.js +119 -20
  214. package/dist/assets/ui-2ab43a16.css +0 -1
  215. package/dist/assets/vue-03b265aa.js +0 -6096
  216. package/plugins/@vcmap-show-case/theme-changer/README.md +0 -23
  217. package/plugins/@vcmap-show-case/theme-changer/config.json +0 -69
  218. package/plugins/@vcmap-show-case/theme-changer/package.json +0 -11
  219. package/plugins/@vcmap-show-case/theme-changer/src/ThemeChangerComponent.vue +0 -120
  220. package/plugins/@vcmap-show-case/theme-changer/src/index.js +0 -108
  221. package/src/application/markdownHelper.d.ts +0 -12
  222. package/src/application/markdownHelper.js +0 -70
  223. package/src/components/lists/VcsListItem.vue.d.ts +0 -27
  224. package/src/components/lists/VcsTreeviewLeaf.vue +0 -83
  225. package/src/components/notification/VcsTooltip.vue +0 -156
  226. package/src/components/notification/VcsTooltip.vue.d.ts +0 -27
  227. package/src/featureInfo/MarkdownComponent.vue +0 -16
  228. package/src/featureInfo/MarkdownComponent.vue.d.ts +0 -7
  229. package/src/styles/_theming.scss +0 -73
  230. package/src/styles/settings.scss +0 -6
  231. package/src/styles/shades.scss +0 -4
  232. package/src/styles/variables.scss +0 -140
  233. package/src/styles/vcsFont.scss +0 -2
  234. package/src/styles/vcsGrid.scss +0 -3
  235. /package/src/components/lists/{VcsTreeviewLeaf.vue.d.ts → VcsTreeviewTitle.vue.d.ts} +0 -0
@@ -10,8 +10,10 @@
10
10
  class="vcs-text-field primary--placeholder"
11
11
  :class="{
12
12
  'py-1': !paddingProvided,
13
+ 'no-prepended-content': !prependedContent,
13
14
  }"
14
15
  v-bind="$attrs"
16
+ :prefix="forcePrefix ? undefined : $attrs.prefix"
15
17
  v-model="visibleValue"
16
18
  v-model:focused="focused"
17
19
  >
@@ -41,6 +43,14 @@
41
43
  ></v-tooltip>
42
44
  <slot name="default" v-bind="scope ?? {}"></slot>
43
45
  </template>
46
+ <!-- use slot to show prefix always, independent of modelValue (unlike prefix prop) -->
47
+ <template #prepend-inner="prependInnerScope">
48
+ <slot name="prepend-inner" v-bind="prependInnerScope">
49
+ <template v-if="forcePrefix && $attrs.prefix">
50
+ {{ $attrs.prefix }}
51
+ </template>
52
+ </slot>
53
+ </template>
44
54
  </v-text-field>
45
55
  </template>
46
56
 
@@ -74,6 +84,7 @@
74
84
  * @vue-prop {string|undefined} tooltip - Optional tooltip which will be shown on hover when no error message is shown
75
85
  * @vue-prop {string} unit - Unit for number input fields. Is displayed behind the number.
76
86
  * @vue-prop {number|undefined} [decimals] - An optional number of decimal places the visible value will be rounded to. Does not affect the input value!
87
+ * @vue-prop {boolean} [forcePrefix=false] - If set, forces the prefix to be always rendered independent of modelValue by using prepend-inner slot
77
88
  */
78
89
  export default {
79
90
  name: 'VcsTextField',
@@ -112,6 +123,10 @@
112
123
  type: Number,
113
124
  default: undefined,
114
125
  },
126
+ forcePrefix: {
127
+ type: Boolean,
128
+ default: false,
129
+ },
115
130
  },
116
131
  setup(props, { attrs, slots }) {
117
132
  const textFieldRef = ref();
@@ -137,8 +152,12 @@
137
152
  return localValue.value ?? '';
138
153
  },
139
154
  set(value) {
140
- localValue.value = value;
141
155
  // emit is not needed since the vuetify component already emits an @input event. (forwarded listeners)
156
+ if (props.type === 'number') {
157
+ localValue.value = parseFloat(value);
158
+ } else {
159
+ localValue.value = value;
160
+ }
142
161
  },
143
162
  });
144
163
 
@@ -155,7 +174,11 @@
155
174
  const paddingProvided = usePadding(attrs);
156
175
  const forwardSlots = useForwardSlots(slots, ['default', 'message']);
157
176
 
177
+ const prependedContent = computed(() => {
178
+ return (props.forcePrefix && attrs.prefix) || !!slots['prepend-inner'];
179
+ });
158
180
  return {
181
+ prependedContent,
159
182
  forwardSlots,
160
183
  paddingProvided,
161
184
  visibleValue,
@@ -23,10 +23,15 @@ declare const _default: import("vue").DefineComponent<{
23
23
  type: NumberConstructor;
24
24
  default: undefined;
25
25
  };
26
+ forcePrefix: {
27
+ type: BooleanConstructor;
28
+ default: boolean;
29
+ };
26
30
  }, {
31
+ prependedContent: import("vue").ComputedRef<{}>;
27
32
  forwardSlots: import("vue").ComputedRef<string[]>;
28
33
  paddingProvided: import("vue").ComputedRef<boolean>;
29
- visibleValue: import("vue").WritableComputedRef<any>;
34
+ visibleValue: import("vue").WritableComputedRef<string | number | boolean>;
30
35
  rules: import("vue").ComputedRef<unknown>;
31
36
  textFieldRef: import("vue").Ref<any>;
32
37
  errorTooltipRef: import("vue").Ref<any>;
@@ -56,6 +61,10 @@ declare const _default: import("vue").DefineComponent<{
56
61
  type: NumberConstructor;
57
62
  default: undefined;
58
63
  };
64
+ forcePrefix: {
65
+ type: BooleanConstructor;
66
+ default: boolean;
67
+ };
59
68
  }>>, {
60
69
  type: string;
61
70
  modelValue: string | number;
@@ -63,5 +72,6 @@ declare const _default: import("vue").DefineComponent<{
63
72
  tooltipPosition: string;
64
73
  unit: string;
65
74
  decimals: number;
75
+ forcePrefix: boolean;
66
76
  }, {}>;
67
77
  export default _default;
@@ -35,8 +35,8 @@
35
35
  </script>
36
36
  <style scoped lang="scss">
37
37
  :deep(.v-expansion-panel-title) {
38
- height: var(--v-vcs-item-height);
39
- min-height: var(--v-vcs-item-height);
38
+ height: calc(var(--v-vcs-font-size) * 2 + 6px);
39
+ min-height: calc(var(--v-vcs-font-size) * 2 + 6px);
40
40
  padding: 0 8px;
41
41
  }
42
42
  :deep(.v-expansion-panel-title.v-expansion-panel-title--active) {
@@ -58,7 +58,7 @@
58
58
  }
59
59
  :deep(.v-stepper-vertical-item:not(:last-child):before) {
60
60
  height: 100%;
61
- top: calc(var(--v-vcs-item-height) * 0.5);
61
+ top: calc(var(--v-vcs-font-size) * 2 - 16px);
62
62
  left: calc(14px + var(--v-vcs-font-size) * 0.42);
63
63
  width: calc(var(--v-vcs-font-size) * 0.1);
64
64
  }
@@ -23,9 +23,6 @@
23
23
  v-if="isActiveStep"
24
24
  :actions="actions"
25
25
  :overflow-count="actionButtonListOverflowCount"
26
- @mousedown.stop
27
- @touchstart.stop
28
- @keydown.stop
29
26
  class="justify-end"
30
27
  />
31
28
  </div>
@@ -33,7 +30,11 @@
33
30
  </template>
34
31
  <template #default>
35
32
  <div>
36
- <VcsHelp :text="helpText" :show="showHelp">
33
+ <VcsHelp
34
+ :text="helpText"
35
+ v-if="showHelp && ($slots.help || helpText)"
36
+ class="mb-1"
37
+ >
37
38
  <slot name="help" />
38
39
  </VcsHelp>
39
40
  <slot />
@@ -136,7 +137,7 @@
136
137
  const helpAction = reactive({
137
138
  name: 'help',
138
139
  title: 'components.vcsFormSection.help',
139
- active: false,
140
+ active: true,
140
141
  icon: 'mdi-help-circle',
141
142
  callback() {
142
143
  this.active = !this.active;
@@ -3,7 +3,7 @@
3
3
  --v-field-padding-end: 4px;
4
4
  }
5
5
  .v-input--density-compact :deep(.v-field) {
6
- --v-input-control-height: calc(var(--v-vcs-item-height) - 8px);
6
+ --v-input-control-height: calc(var(--v-vcs-font-size) * 2 - 2px);
7
7
  --v-field-padding-bottom: 0px;
8
8
  --v-field-input-padding-top: 0px;
9
9
  --v-input-padding-top: 0px;
@@ -50,6 +50,12 @@
50
50
  :deep(.v-field--appended) {
51
51
  padding-inline-end: 4px;
52
52
  }
53
+ :deep(.v-field--prepended) {
54
+ padding-inline-start: 4px;
55
+ }
56
+ .no-prepended-content :deep(.v-field--prepended) {
57
+ padding-inline-start: 0px;
58
+ }
53
59
 
54
60
  // remove margin from prepended Icon
55
61
  .v-input--horizontal :deep(.v-input__prepend) {
@@ -58,13 +64,10 @@
58
64
  .primary--placeholder {
59
65
  :deep(input::placeholder) {
60
66
  color: rgb(var(--v-theme-primary));
61
- font-style: italic;
67
+ font-style: italic !important;
62
68
  opacity: 1;
63
69
  padding: 0 3px 0 0;
64
70
  }
65
- :deep(input::-moz-placeholder) {
66
- font-style: initial;
67
- }
68
71
  }
69
72
 
70
73
  // remove details
@@ -11,10 +11,12 @@
11
11
  </slot>
12
12
  {{ formatted }}
13
13
  <slot name="append">
14
- <span v-if="unit === SpecialUnits.SQM"> m<sup>2</sup> </span>
15
- <span v-else-if="unit === SpecialUnits.CBM"> m<sup>3</sup> </span>
16
- <span v-else-if="unit === SpecialUnits.DEG"> ° </span>
17
- <span v-else>
14
+ <span class="pl-1" v-if="unit === SpecialUnits.SQM"> m<sup>2</sup> </span>
15
+ <span class="pl-1" v-else-if="unit === SpecialUnits.CBM">
16
+ m<sup>3</sup>
17
+ </span>
18
+ <span class="pl-1" v-else-if="unit === SpecialUnits.DEG"> ° </span>
19
+ <span class="pl-1" v-else>
18
20
  {{ unit }}
19
21
  </span>
20
22
  </slot>
@@ -31,7 +33,7 @@
31
33
  box-sizing: content-box;
32
34
  display: flex;
33
35
  align-items: center;
34
- height: calc(var(--v-vcs-item-height) - 8px);
36
+ height: calc(var(--v-vcs-font-size) * 2 - 2px);
35
37
  }
36
38
  .vcs-disabled {
37
39
  opacity: var(--v-disabled-opacity);
@@ -1,5 +1,11 @@
1
1
  <template>
2
- <div class="marked" v-html="markedHtml"></div>
2
+ <div
3
+ class="marked"
4
+ :class="{
5
+ 'pa-2': !paddingProvided,
6
+ }"
7
+ v-html="markedHtml"
8
+ ></div>
3
9
  </template>
4
10
  <style lang="scss" scoped>
5
11
  div {
@@ -10,19 +16,13 @@
10
16
  margin-bottom: calc(var(--v-vcs-font-size) * 1);
11
17
  }
12
18
  :deep(h2) {
13
- margin-bottom: calc(
14
- var(--v-vcs-font-size) * 1
15
- ); /* or any other value you prefer */
19
+ margin-bottom: calc(var(--v-vcs-font-size) * 1);
16
20
  }
17
21
  :deep(ul) {
18
- margin-bottom: calc(
19
- var(--v-vcs-font-size) * 1
20
- ); /* or any other value you prefer */
22
+ margin-bottom: calc(var(--v-vcs-font-size) * 1);
21
23
  }
22
24
  :deep(ol) {
23
- margin-bottom: calc(
24
- var(--v-vcs-font-size) * 1
25
- ); /* or any other value you prefer */
25
+ margin-bottom: calc(var(--v-vcs-font-size) * 1);
26
26
  }
27
27
  :deep(li) {
28
28
  margin-left: 1.5em;
@@ -31,7 +31,8 @@
31
31
  </style>
32
32
  <script>
33
33
  import { computed } from 'vue';
34
- import { parseAndSanitizeMarkdown } from '../../application/markdownHelper.js';
34
+ import { parseAndSanitizeMarkdown } from './markdownHelper.js';
35
+ import { usePadding } from '../composables.js';
35
36
 
36
37
  export default {
37
38
  name: 'VcsMarkdown',
@@ -41,12 +42,14 @@
41
42
  default: undefined,
42
43
  },
43
44
  },
44
- setup(props) {
45
+ setup(props, { attrs }) {
45
46
  const markedHtml = computed(() =>
46
47
  parseAndSanitizeMarkdown(props.content),
47
48
  );
49
+ const paddingProvided = usePadding(attrs);
48
50
  return {
49
51
  markedHtml,
52
+ paddingProvided,
50
53
  };
51
54
  },
52
55
  };
@@ -5,6 +5,7 @@ declare const _default: import("vue").DefineComponent<{
5
5
  };
6
6
  }, {
7
7
  markedHtml: import("vue").ComputedRef<string>;
8
+ paddingProvided: import("vue").ComputedRef<boolean>;
8
9
  }, any, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
9
10
  content: {
10
11
  type: StringConstructor;
@@ -0,0 +1,30 @@
1
+ /**
2
+ * @typedef {Object} Block
3
+ * @property {RegExpExecArray} opening
4
+ * @property {RegExpExecArray} closing
5
+ */
6
+ /**
7
+ * @typedef {Block} ConditionalBlock
8
+ * @property {RegExpExecArray|undefined} elseStatement
9
+ * @property {RegExpExecArray[]} elseIfs
10
+ */
11
+ /**
12
+ * @param {string} content
13
+ * @returns {string}
14
+ */
15
+ export function parseAndSanitizeMarkdown(content: string): string;
16
+ /**
17
+ * Renders a template in these steps
18
+ * 1. expand conditional blocks. this will remove any blocks that do not match their expressions and choose from if / elseif / else block which of them to render
19
+ * 2. expand iterations. this will create new templates for each iteration and re-run the rendering for those blocks
20
+ * 3. render attributes. this will add the attributes to all the blocks not within each blocks
21
+ * @param {string|string[]} template
22
+ * @param {Record<string, unknown>} data
23
+ * @returns {string}
24
+ */
25
+ export function renderTemplate(template: string | string[], data: Record<string, unknown>): string;
26
+ export type Block = {
27
+ opening: RegExpExecArray;
28
+ closing: RegExpExecArray;
29
+ };
30
+ export type ConditionalBlock = Block;