@knime/jsonforms 1.14.3 → 1.15.1

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 (200) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/dist/AnyOfTwinlist-BmHETHvW.js +28 -0
  3. package/dist/{Button-BxuGKyL5.js → Button-B9RSLVI2.js} +9 -8
  4. package/dist/CheckboxControl-q88fZSZD.js +58 -0
  5. package/dist/Checkboxes-Bofcg7tl.js +120 -0
  6. package/dist/CheckboxesControl-DY0R1PDD.js +47 -0
  7. package/dist/{ComboBoxControl-Dk02x7sN.js → ComboBoxControl-2r1FWcy-.js} +238 -172
  8. package/dist/DateControl-vnkppn62.js +38 -0
  9. package/dist/DateTimeControl-MkF9G3Xz.js +53 -0
  10. package/dist/DateTimeFormatInput-Ds2VLXw1.js +426 -0
  11. package/dist/DateTimeFormatPickerControl-D3OjZCj7.js +47 -0
  12. package/dist/DateTimeFormatPickerWithTypeControl-DDto-oJk.js +85 -0
  13. package/dist/DateTimeInput-DcwhvMD2.js +11321 -0
  14. package/dist/Dropdown-D49sEHBa.js +663 -0
  15. package/dist/DropdownControl-aeEqC-Yg.js +46 -0
  16. package/dist/HorizontalLayout-D0toQmVl.js +39 -0
  17. package/dist/{InputField-BYxW_-G3.js → InputField-C_aZPs-f.js} +48 -36
  18. package/dist/IntegerControl-DAwniqjW.js +33 -0
  19. package/dist/IntervalControl-Bkuhg0Ga.js +647 -0
  20. package/dist/LoadingDropdown-B9jHjdWV.js +50 -0
  21. package/dist/LoadingIcon-RPBUjTO3.js +23 -0
  22. package/dist/ManualTwinlistControl-DGW-7a2Q.js +90 -0
  23. package/dist/MultiSelectListBoxControl-BYHuC9jL.js +48 -0
  24. package/dist/MultimodeTwinlistControl-oIvgI_FP.js +486 -0
  25. package/dist/{MultimodeTwinlistControl.vue_vue_type_style_index_0_scoped_37fe7036_lang-DGKMWtLi.js → MultimodeTwinlistControl.vue_vue_type_style_index_0_scoped_bd2eaa56_lang-pnMOUiIt.js} +1 -1
  26. package/dist/{MultiselectListBox-CHvGxAhY.js → MultiselectListBox-CfdPbcn1.js} +105 -86
  27. package/dist/NameFilter-BV68t_P5.js +37 -0
  28. package/dist/NumberControl-Dm01CJW9.js +33 -0
  29. package/dist/NumberControlBase-CN5eTKEm.js +58 -0
  30. package/dist/{NumberInput-DJ38AGiR.js → NumberInput-DWTImcA_.js} +72 -54
  31. package/dist/OneOfDropdown-DuXXP0Qn.js +50 -0
  32. package/dist/RadioControl-X6HLs9F1.js +36 -0
  33. package/dist/RadioControlBase-BGUHTIUl.js +111 -0
  34. package/dist/{RichTextControl-CXY1ULxR.js → RichTextControl-B1mJMs1e.js} +5462 -4668
  35. package/dist/SectionHeading-B6JkPyMh.js +31 -0
  36. package/dist/SectionHeading.vue_vue_type_style_index_0_scoped_f06e9b7d_lang-B5ALSUVO.js +15603 -0
  37. package/dist/SectionLayout-7pXn4OHo.js +61 -0
  38. package/dist/SettingsSubPanel-DToMRoLu.js +48 -0
  39. package/dist/SettingsSubPanelLayout-DnZnghFr.js +83 -0
  40. package/dist/SimpleButtonControl-DOSd92Kq.js +84 -0
  41. package/dist/SimpleTwinlistControl-RBfQTk47.js +31 -0
  42. package/dist/SingleSelectControl-C-GLQD-a.js +73 -0
  43. package/dist/SingleSelectListBoxControl-CDg_1QUT.js +260 -0
  44. package/dist/SortListControl-CWuxKIEb.js +445 -0
  45. package/dist/StyledListItem-NqAG7jSw.js +81 -0
  46. package/dist/TextAreaControl-Dt5ZGrae.js +122 -0
  47. package/dist/TextControl-w9vrCC1T.js +54 -0
  48. package/dist/TimeControl-DiNQSV4K.js +46 -0
  49. package/dist/TwinlistControlBase-CMFEecdr.js +47 -0
  50. package/dist/TwinlistLoadingInfo-Cy6HY-97.js +1080 -0
  51. package/dist/TypedStringFilter-FUF8sqOm.js +32 -0
  52. package/dist/ValueSwitch-Ozmr1YfK.js +162 -0
  53. package/dist/ValueSwitchControl-CdFlHo-2.js +33 -0
  54. package/dist/VerticalLayout-DY8gbasK.js +39 -0
  55. package/dist/VerticalLayoutBase-CpN-KONq.js +32 -0
  56. package/dist/ZonedDateTimeControl-Cg3dAfq5.js +79 -0
  57. package/dist/{_baseEach-cjHvi5iT.js → _baseEach-CWap1NWh.js} +4 -4
  58. package/dist/{_baseIteratee-CIxt0KWU.js → _baseIteratee-D0MXvnuf.js} +27 -27
  59. package/dist/{_getTag-sLUyzSDj.js → _getTag-BvpAzjaz.js} +10 -10
  60. package/dist/{arrow-dropdown-DdgjzLAO.js → arrow-dropdown-eS-nVNCv.js} +9 -3
  61. package/dist/{arrow-next-CIOU5o42.js → arrow-next-BmOStWql.js} +9 -3
  62. package/dist/{close-BuY4mhXV.js → close-0dYG2oDA.js} +9 -3
  63. package/dist/floating-ui.vue-CDo9Kas1.js +1055 -0
  64. package/dist/{hotkeys-kwHHtFKz.js → hotkeys-rxnt4egK.js} +1 -1
  65. package/dist/index-CpKfM262.js +376 -0
  66. package/dist/knime-jsonforms.css +1 -1
  67. package/dist/knime-jsonforms.js +133 -110
  68. package/dist/{localTimeUtils-Dv-1R88J.js → localTimeUtils-CfchSrLG.js} +179 -181
  69. package/dist/magic-string.es-BQ9KnLz-.js +659 -0
  70. package/dist/navigator-e30QQMkl.js +4 -0
  71. package/dist/popper-LGjf7Wza.js +905 -0
  72. package/dist/reload-57Xc2t-6.js +23 -0
  73. package/dist/src/higherOrderComponents/control/LabeledControl.vue.d.ts +26 -22
  74. package/dist/src/higherOrderComponents/control/errorMessage/ErrorLine.vue.d.ts +3 -4
  75. package/dist/src/higherOrderComponents/control/errorMessage/ErrorMessages.vue.d.ts +16 -10
  76. package/dist/src/higherOrderComponents/control/errorMessage/withErrorMessage.d.ts +1 -1
  77. package/dist/src/higherOrderComponents/control/util.d.ts +7 -33
  78. package/dist/src/higherOrderComponents/layout/util.d.ts +1 -17
  79. package/dist/src/layoutComponents/Form.vue.d.ts +12 -4
  80. package/dist/src/layoutComponents/HorizontalLayout.vue.d.ts +1 -1
  81. package/dist/src/layoutComponents/SectionLayout.vue.d.ts +13 -5
  82. package/dist/src/layoutComponents/VerticalLayout.vue.d.ts +1 -1
  83. package/dist/src/layoutComponents/VerticalLayoutBase.vue.d.ts +16 -9
  84. package/dist/src/layoutComponents/section/SectionHeading.vue.d.ts +13 -6
  85. package/dist/src/layoutComponents/settingsSubPanel/SettingsSubPanel.vue.d.ts +2 -2
  86. package/dist/src/layoutComponents/settingsSubPanel/SettingsSubPanelBackArrow.vue.d.ts +1 -1
  87. package/dist/src/renderers/dateTimeFormatPickerRenderer.d.ts +2 -2
  88. package/dist/src/renderers/defaultRenderers.d.ts +966 -151
  89. package/dist/src/renderers/dropdownRenderer.d.ts +1 -1
  90. package/dist/src/renderers/fallbackRenderers.d.ts +8 -8
  91. package/dist/src/renderers/horizontalLayoutRenderer.d.ts +1 -1
  92. package/dist/src/renderers/sectionLayoutRenderer.d.ts +4 -4
  93. package/dist/src/renderers/simpleButtonRenderer.d.ts +7 -89
  94. package/dist/src/renderers/sortListRenderer.d.ts +853 -20
  95. package/dist/src/renderers/textMessageRenderer.d.ts +65 -1
  96. package/dist/src/renderers/textRenderer.d.ts +1 -1
  97. package/dist/src/renderers/verticalLayoutRenderer.d.ts +2 -2
  98. package/dist/src/renderers/zonedDateTimeRenderer.d.ts +1 -1
  99. package/dist/src/uiComponents/CheckboxControl.vue.d.ts +15 -6
  100. package/dist/src/uiComponents/CheckboxesControl.vue.d.ts +2 -1
  101. package/dist/src/uiComponents/ComboBoxControl.vue.d.ts +2 -1
  102. package/dist/src/uiComponents/DateControl.vue.d.ts +2 -1
  103. package/dist/src/uiComponents/DateTimeControl.vue.d.ts +2 -1
  104. package/dist/src/uiComponents/DateTimeFormatPickerControl.vue.d.ts +2 -1
  105. package/dist/src/uiComponents/DateTimeFormatPickerWithTypeControl.vue.d.ts +2 -1
  106. package/dist/src/uiComponents/DropdownControl.vue.d.ts +2 -1
  107. package/dist/src/uiComponents/IntegerControl.vue.d.ts +2 -1
  108. package/dist/src/uiComponents/IntervalControl.vue.d.ts +2 -1
  109. package/dist/src/uiComponents/MultiSelectListBoxControl.vue.d.ts +2 -1
  110. package/dist/src/uiComponents/NumberControl.vue.d.ts +2 -1
  111. package/dist/src/uiComponents/NumberControlBase.vue.d.ts +5 -9
  112. package/dist/src/uiComponents/OneOfDropdown.vue.d.ts +2 -1
  113. package/dist/src/uiComponents/RadioControl.vue.d.ts +2 -1
  114. package/dist/src/uiComponents/RadioControlBase.vue.d.ts +4 -8
  115. package/dist/src/uiComponents/SimpleButtonControl.vue.d.ts +5 -129
  116. package/dist/src/uiComponents/SingleSelectControl.vue.d.ts +2 -1
  117. package/dist/src/uiComponents/SingleSelectListBoxControl.vue.d.ts +2 -1
  118. package/dist/src/uiComponents/SortListControl.vue.d.ts +845 -12
  119. package/dist/src/uiComponents/TextAreaControl.vue.d.ts +2 -1
  120. package/dist/src/uiComponents/TextControl.vue.d.ts +203 -3
  121. package/dist/src/uiComponents/TextMessageControl.vue.d.ts +2 -1
  122. package/dist/src/uiComponents/TimeControl.vue.d.ts +2 -1
  123. package/dist/src/uiComponents/ValueSwitchControl.vue.d.ts +2 -1
  124. package/dist/src/uiComponents/ZonedDateTimeControl.vue.d.ts +2 -1
  125. package/dist/src/uiComponents/composables/useProvidedState.d.ts +1 -1
  126. package/dist/src/uiComponents/loading/TwinlistLoadingInfo.vue.d.ts +1 -1
  127. package/dist/src/uiComponents/richTextControl/DialogLinkModal.vue.d.ts +3 -1
  128. package/dist/src/uiComponents/richTextControl/RichTextControl.vue.d.ts +230 -1
  129. package/dist/src/uiComponents/twinlist/AnyOfTwinlist.vue.d.ts +2 -1
  130. package/dist/src/uiComponents/twinlist/ManualTwinlistControl.vue.d.ts +2 -1
  131. package/dist/src/uiComponents/twinlist/MultimodeTwinlistControl.vue.d.ts +8 -15
  132. package/dist/src/uiComponents/twinlist/NameFilter.vue.d.ts +2 -1
  133. package/dist/src/uiComponents/twinlist/SimpleTwinlistControl.vue.d.ts +2 -1
  134. package/dist/src/uiComponents/twinlist/TwinlistControlBase.vue.d.ts +5 -10
  135. package/dist/src/uiComponents/twinlist/TypedStringFilter.vue.d.ts +2 -1
  136. package/dist/testUtils/component.d.ts +18 -18
  137. package/dist/testing.js +8688 -8655
  138. package/dist/{toString-C_MqBj3_.js → toString-C-X8cE7K.js} +1 -1
  139. package/dist/{useBuiltinValidations-DP7OS71z.js → useBuiltinValidations-D0WuEacN.js} +1 -1
  140. package/dist/useDropdownNavigation-BfCXUheD.js +817 -0
  141. package/dist/usePossibleValues-DTVXBGRC.js +16 -0
  142. package/package.json +14 -14
  143. package/dist/AnyOfTwinlist-Cwxtyt0Q.js +0 -22
  144. package/dist/CheckboxControl-Oe97HhY3.js +0 -40
  145. package/dist/Checkboxes-DIPjJhPO.js +0 -103
  146. package/dist/CheckboxesControl-5QlPmjwv.js +0 -41
  147. package/dist/DateControl-CddCObVg.js +0 -29
  148. package/dist/DateTimeControl-DyXUJBHE.js +0 -54
  149. package/dist/DateTimeFormatInput-bO1zHUyp.js +0 -381
  150. package/dist/DateTimeFormatPickerControl-Dq25_JV2.js +0 -43
  151. package/dist/DateTimeFormatPickerWithTypeControl-DZib_x-B.js +0 -79
  152. package/dist/DateTimeInput-CEYEV8dt.js +0 -11204
  153. package/dist/Dropdown-CJj0CUA8.js +0 -604
  154. package/dist/DropdownControl-BNQKWzTT.js +0 -31
  155. package/dist/HorizontalLayout-6GwurgkR.js +0 -25
  156. package/dist/IntegerControl-DZIY-wb_.js +0 -20
  157. package/dist/IntervalControl-Yts36_MI.js +0 -546
  158. package/dist/LoadingDropdown-Dw-0WQ8x.js +0 -40
  159. package/dist/ManualTwinlistControl-C3NnAug1.js +0 -85
  160. package/dist/MultiSelectListBoxControl-3Q41S4aA.js +0 -34
  161. package/dist/MultimodeTwinlistControl-B2Jven29.js +0 -470
  162. package/dist/NameFilter-D0hKO5Fr.js +0 -24
  163. package/dist/NumberControl-DkeQT1iR.js +0 -20
  164. package/dist/NumberControlBase.vue_vue_type_script_setup_true_lang-B9K5qEs3.js +0 -53
  165. package/dist/OneOfDropdown-NAgE-mPP.js +0 -34
  166. package/dist/RadioControl-DjrysNQ_.js +0 -24
  167. package/dist/RadioControlBase.vue_vue_type_script_setup_true_lang-WaVJMdQq.js +0 -114
  168. package/dist/SectionHeading-BU1W5lDr.js +0 -19
  169. package/dist/SectionHeading.vue_vue_type_style_index_0_scoped_625edfbe_lang-CsYyUtDa.js +0 -14015
  170. package/dist/SectionLayout-CJP4sYyB.js +0 -46
  171. package/dist/SettingsSubPanel-KxEyzlB6.js +0 -5
  172. package/dist/SettingsSubPanelLayout-YBNVPQOD.js +0 -61
  173. package/dist/SimpleButtonControl-ejyUwJdL.js +0 -61
  174. package/dist/SimpleTwinlistControl-qXQxRI7h.js +0 -28
  175. package/dist/SingleSelectControl-B0JgDv7j.js +0 -58
  176. package/dist/SingleSelectListBoxControl-ClQOxnxW.js +0 -235
  177. package/dist/SortListControl-mvJofiWn.js +0 -375
  178. package/dist/StyledListItem-BXz08pEQ.js +0 -72
  179. package/dist/TextAreaControl-S4aoqAv1.js +0 -111
  180. package/dist/TextControl-rJrjrBw8.js +0 -4
  181. package/dist/TextControl.vue_vue_type_script_setup_true_lang-Bf6GB1zX.js +0 -50
  182. package/dist/TimeControl-DfhE8yu9.js +0 -42
  183. package/dist/TwinlistControlBase-D1l9t7Up.js +0 -40
  184. package/dist/TwinlistLoadingInfo-CQRx9cEu.js +0 -963
  185. package/dist/TypedStringFilter-C6JhWCCC.js +0 -29
  186. package/dist/ValueSwitch-CUYV7v67.js +0 -131
  187. package/dist/ValueSwitchControl-IP9SxrUs.js +0 -20
  188. package/dist/VerticalLayout-D2eQSYgv.js +0 -30
  189. package/dist/VerticalLayoutBase-DRfHwc4t.js +0 -20
  190. package/dist/ZonedDateTimeControl-Bi8cV34A.js +0 -75
  191. package/dist/floating-ui.vue-B-MrqKCT.js +0 -1019
  192. package/dist/index-CoRworrE.js +0 -322
  193. package/dist/magic-string.es-D-aKzDFf.js +0 -858
  194. package/dist/navigator-D_R-txCf.js +0 -7
  195. package/dist/popper-CRR--9mA.js +0 -907
  196. package/dist/reload-BVbCGubF.js +0 -17
  197. package/dist/src/JsonFormsDialog.vue.d.ts +0 -46
  198. package/dist/svgWithTitle-Cr3Pu3wr.js +0 -18
  199. package/dist/useDropdownNavigation-7o7SRJSo.js +0 -781
  200. package/dist/usePossibleValues-lz0Rcu_N.js +0 -20
@@ -0,0 +1,426 @@
1
+ import { createElementBlock as T, openBlock as p, createElementVNode as u, defineComponent as L, computed as x, ref as y, watch as k, reactive as J, onMounted as Q, nextTick as B, onUnmounted as X, createBlock as H, withCtx as Y, createCommentVNode as P, createVNode as I, normalizeStyle as K, Fragment as $, renderList as ee, normalizeClass as V, toDisplayString as U, mergeModels as te, useModel as oe, withDirectives as ae, vModelText as le } from "vue";
2
+ import { o as re } from "./index-CpKfM262.js";
3
+ import { u as ne, a as ie, o as se, s as ce, f as de } from "./floating-ui.vue-CDo9Kas1.js";
4
+ import { u as me, F as pe } from "./useDropdownNavigation-BfCXUheD.js";
5
+ import { L as ue } from "./LoadingIcon-RPBUjTO3.js";
6
+ import { V as fe } from "./ValueSwitch-Ozmr1YfK.js";
7
+ import { _ as j } from "./SectionHeading.vue_vue_type_style_index_0_scoped_f06e9b7d_lang-B5ALSUVO.js";
8
+ const ve = {
9
+ xmlns: "http://www.w3.org/2000/svg",
10
+ fill: "none",
11
+ "stroke-linejoin": "round",
12
+ viewBox: "0 0 32 32"
13
+ };
14
+ function ye(g, a) {
15
+ return p(), T("svg", ve, a[0] || (a[0] = [
16
+ u(
17
+ "path",
18
+ {
19
+ fill: "#000",
20
+ d: "M2 3.842v-.5a.5.5 0 0 0-.5.5zm22.611 0h.5a.5.5 0 0 0-.5-.5zm-.5 7.48a.5.5 0 1 0 1 0zM2 21.43h-.5a.5.5 0 0 0 .5.5zm10.298.5a.5.5 0 1 0 0-1zm5.283 8.222h-.5a.5.5 0 0 0 .765.424zm3.278-2.046.265.424a.5.5 0 0 0 .235-.424zm0-5.87-.366-.34a.5.5 0 0 0-.134.34zM27.613 15l.366.341a.5.5 0 0 0-.366-.841zm-10.032 7.235h.5a.5.5 0 0 0-.128-.334zM11.063 15v-.5a.5.5 0 0 0-.372.835zm-.69-9.483V2h-1v3.517zM16.155 2v3.517h1V2zM2 4.342h22.611v-1H2zm22.111-.5v7.48h1v-7.48zM2.5 21.43V3.842h-1V21.43zM2 8.362h22.611v-1H2zM12.298 20.93h-6.81v1h6.81zm-6.81 0H2v1h3.488zm12.358 9.646 3.278-2.046-.53-.849-3.278 2.047zm3.513-2.47v-5.87h-1v5.87zm-.135-5.528 6.755-7.236-.731-.682-6.755 7.235zm-4.143-.342v7.916h1v-7.916zm.872-.334-6.519-7.236-.743.67 6.519 7.235zm-6.89-6.401h16.55v-1h-16.55z"
21
+ },
22
+ null,
23
+ -1
24
+ /* CACHED */
25
+ )
26
+ ]));
27
+ }
28
+ const he = { render: ye }, q = 1, Te = /* @__PURE__ */ L({
29
+ __name: "DateTimeFormatPickerPopover",
30
+ props: {
31
+ allFormats: { type: [Array, null], required: !0 },
32
+ selectedType: { type: String, required: !0 },
33
+ initialSelectedPattern: { type: [String, null], required: !0 },
34
+ showTypeSwitch: { type: Boolean, required: !0 }
35
+ },
36
+ emits: ["commit", "cancel"],
37
+ setup(g, { expose: a, emit: c }) {
38
+ a();
39
+ const e = c, d = g, w = x(() => [
40
+ {
41
+ id: "RECENT",
42
+ text: "Recent"
43
+ },
44
+ {
45
+ id: "STANDARD",
46
+ text: "ISO"
47
+ },
48
+ {
49
+ id: "EUROPEAN",
50
+ text: "European"
51
+ },
52
+ {
53
+ id: "AMERICAN",
54
+ text: "United States"
55
+ }
56
+ ]), l = x(() => [
57
+ {
58
+ id: "DATE",
59
+ text: "Date"
60
+ },
61
+ {
62
+ id: "DATE_TIME",
63
+ text: "Date & time"
64
+ },
65
+ {
66
+ id: "TIME",
67
+ text: "Time"
68
+ },
69
+ {
70
+ id: "ZONED_DATE_TIME",
71
+ text: "Zoned date & time"
72
+ }
73
+ ]), s = y(null), h = y(null), m = y("RECENT"), f = y(d.selectedType);
74
+ k(
75
+ () => d.selectedType,
76
+ (t) => {
77
+ h.value = t;
78
+ }
79
+ );
80
+ const n = x(
81
+ () => d.allFormats?.filter(
82
+ (t) => t.category === m.value && t.temporalType === f.value
83
+ ) ?? null
84
+ ), E = y(null), F = J({}), C = (t) => `${t.format}-${t.category}-${t.temporalType}`, W = (t) => (o) => {
85
+ F[C(t)] = o;
86
+ }, _ = (t) => ({
87
+ format: t.format,
88
+ temporalType: t.temporalType
89
+ }), {
90
+ currentIndex: A,
91
+ onKeydown: Z,
92
+ resetNavigation: z,
93
+ setElement: R
94
+ } = me({
95
+ keepOpenedOnTab: !0,
96
+ getFirstElement: () => ({
97
+ index: 0,
98
+ onClick: () => e(
99
+ "commit",
100
+ _(n.value[0])
101
+ )
102
+ }),
103
+ getLastElement: () => {
104
+ const t = n.value.length - 1;
105
+ return {
106
+ index: t,
107
+ onClick: () => e(
108
+ "commit",
109
+ _(n.value[t])
110
+ )
111
+ };
112
+ },
113
+ getNextElement: (t, o) => {
114
+ if (t = t === null || t === -1 ? null : t, o === 1) {
115
+ const i = ((t ?? -1) + 1) % n.value.length;
116
+ return {
117
+ index: i,
118
+ onClick: () => e(
119
+ "commit",
120
+ _(n.value[i])
121
+ )
122
+ };
123
+ } else {
124
+ const i = ((t ?? 0) - 1 + n.value.length) % n.value.length;
125
+ return {
126
+ index: i,
127
+ onClick: () => e(
128
+ "commit",
129
+ _(n.value[i])
130
+ )
131
+ };
132
+ }
133
+ },
134
+ close: () => {
135
+ e("cancel");
136
+ }
137
+ }), O = (t) => {
138
+ const o = t.parentElement;
139
+ if (o && o.scrollHeight > o.clientHeight) {
140
+ const r = o.offsetTop + q, i = o.clientHeight + o.scrollTop, v = t.offsetTop + t.offsetHeight - r;
141
+ v > i ? o.scrollTop = v - o.clientHeight : t.offsetTop - o.scrollTop < r && (o.scrollTop = t.offsetTop - r);
142
+ }
143
+ }, b = (t) => {
144
+ const o = F[`${t}-${m.value}-${f.value}`];
145
+ o && O(o);
146
+ }, D = async (t, o, r) => {
147
+ f.value = o ?? f.value, m.value = r ?? m.value, await B(), h.value = t, b(t);
148
+ const i = n.value.findIndex(
149
+ (v) => v.format === t
150
+ );
151
+ R({
152
+ index: i,
153
+ onClick: () => e(
154
+ "commit",
155
+ _(n.value[i])
156
+ )
157
+ });
158
+ };
159
+ k(A, (t) => {
160
+ if (t === null)
161
+ return;
162
+ const o = n.value?.[t]?.format;
163
+ o && b(o);
164
+ }), k([f, m], () => {
165
+ f.value === s.value?.temporalType && m.value === s.value?.category ? D(
166
+ s.value.format,
167
+ s.value.temporalType,
168
+ s.value.category
169
+ ) : (h.value = null, z());
170
+ });
171
+ const M = y(!1);
172
+ Q(async () => {
173
+ if (!d.allFormats)
174
+ return;
175
+ const t = [
176
+ "RECENT",
177
+ "STANDARD",
178
+ "EUROPEAN",
179
+ "AMERICAN"
180
+ ], o = d.allFormats.filter((r) => d.initialSelectedPattern === r.format).filter(
181
+ (r) => (
182
+ // if the type switch is hidden, filter to only formats with the same type
183
+ d.selectedType === r.temporalType || d.showTypeSwitch
184
+ )
185
+ ).sort((r, i) => {
186
+ const v = t.indexOf(r.category), S = t.indexOf(i.category);
187
+ return v - S;
188
+ });
189
+ if (o.length > 0) {
190
+ const r = o[0].format, i = o[0].temporalType, v = o[0].category;
191
+ await D(r, i, v);
192
+ const S = n.value.findIndex(
193
+ (G) => G.format === r
194
+ );
195
+ s.value = {
196
+ format: r,
197
+ index: S,
198
+ category: v,
199
+ temporalType: i
200
+ };
201
+ }
202
+ B(() => M.value = !0);
203
+ }), X(() => M.value = !1);
204
+ const N = { emit: e, props: d, categoriesToDisplayInValueSwitch: w, typesToDisplayInValueSwitch: l, currentlyAppliedFormat: s, currentlyHighlightedFormat: h, selectedFormatStandard: m, selectedFormatType: f, applicableFormats: n, formatContainerRef: E, allFormatListItemRefs: F, createFormatListItemKey: C, createFormatListItemRef: W, formatWithExampleToModel: _, currentlyHighlightedFormatIndex: A, onKeydown: Z, resetNavigation: z, setHighlightedElement: R, BORDER_WIDTH: q, scrollIntoView: O, scrollToFormat: b, highlightAndScrollToFormat: D, isMounted: M, get FocusTrap() {
205
+ return pe;
206
+ }, LoadingIcon: ue, ValueSwitch: fe };
207
+ return Object.defineProperty(N, "__isScriptSetup", { enumerable: !1, value: !0 }), N;
208
+ }
209
+ }), ge = { class: "popover" }, Fe = { class: "formats-container-border-host" }, _e = {
210
+ key: 0,
211
+ class: "no-formats-available"
212
+ }, we = {
213
+ key: 1,
214
+ class: "no-formats-available"
215
+ }, xe = ["onClick"], Ee = { class: "format-pattern" }, Ie = { class: "format-preview" };
216
+ function be(g, a, c, e, d, w) {
217
+ return p(), H(e.FocusTrap, {
218
+ active: e.isMounted,
219
+ "onUpdate:active": a[3] || (a[3] = (l) => e.isMounted = l),
220
+ "initial-focus": () => e.formatContainerRef ?? !1
221
+ }, {
222
+ default: Y(() => [
223
+ u("div", ge, [
224
+ c.showTypeSwitch ? (p(), H(e.ValueSwitch, {
225
+ key: 0,
226
+ id: "selectedFormatType",
227
+ ref: "typeSwitchRef",
228
+ modelValue: e.selectedFormatType,
229
+ "onUpdate:modelValue": a[0] || (a[0] = (l) => e.selectedFormatType = l),
230
+ compact: "",
231
+ "possible-values": e.typesToDisplayInValueSwitch,
232
+ class: "filter-switch"
233
+ }, null, 8, ["modelValue", "possible-values"])) : P("v-if", !0),
234
+ I(e.ValueSwitch, {
235
+ id: "selectedFormatStandard",
236
+ ref: "standardSwitchRef",
237
+ modelValue: e.selectedFormatStandard,
238
+ "onUpdate:modelValue": a[1] || (a[1] = (l) => e.selectedFormatStandard = l),
239
+ compact: "",
240
+ "possible-values": e.categoriesToDisplayInValueSwitch,
241
+ class: "filter-switch"
242
+ }, null, 8, ["modelValue", "possible-values"]),
243
+ u("div", Fe, [
244
+ u(
245
+ "div",
246
+ {
247
+ id: "dateFormats",
248
+ ref: "formatContainerRef",
249
+ class: "formats-container",
250
+ style: K({ "--formats-container-border-width": e.BORDER_WIDTH + "px" }),
251
+ tabindex: "0",
252
+ role: "menu",
253
+ onKeydown: a[2] || (a[2] = (...l) => e.onKeydown && e.onKeydown(...l))
254
+ },
255
+ [
256
+ e.applicableFormats === null ? (p(), T("div", _e, [
257
+ I(e.LoadingIcon, { class: "loading-spinner" })
258
+ ])) : e.applicableFormats.length === 0 ? (p(), T("div", we, " No formats available ")) : (p(!0), T(
259
+ $,
260
+ { key: 2 },
261
+ ee(e.applicableFormats, (l, s) => (p(), T("div", {
262
+ key: e.createFormatListItemKey(l),
263
+ ref_for: !0,
264
+ ref: e.createFormatListItemRef(l),
265
+ class: V([{
266
+ highlighted: s === e.currentlyHighlightedFormatIndex,
267
+ applied: s === e.currentlyAppliedFormat?.index && l.category === e.currentlyAppliedFormat.category && l.temporalType === e.currentlyAppliedFormat.temporalType
268
+ }, "single-format"]),
269
+ role: "menuitem",
270
+ onClick: () => e.emit("commit", e.formatWithExampleToModel(l))
271
+ }, [
272
+ u(
273
+ "span",
274
+ Ee,
275
+ U(l.format),
276
+ 1
277
+ /* TEXT */
278
+ ),
279
+ u(
280
+ "span",
281
+ Ie,
282
+ U(l.example),
283
+ 1
284
+ /* TEXT */
285
+ )
286
+ ], 10, xe))),
287
+ 128
288
+ /* KEYED_FRAGMENT */
289
+ ))
290
+ ],
291
+ 36
292
+ /* STYLE, NEED_HYDRATION */
293
+ )
294
+ ])
295
+ ])
296
+ ]),
297
+ _: 1
298
+ /* STABLE */
299
+ }, 8, ["active", "initial-focus"]);
300
+ }
301
+ const De = /* @__PURE__ */ j(Te, [["render", be], ["__scopeId", "data-v-4744db25"], ["__file", "/Users/albrecht/Documents/KNIME/git/webapps-common/packages/components/src/components/forms/DateTimeFormatInput/components/DateTimeFormatPickerPopover.vue"]]), Me = {}, Se = /* @__PURE__ */ L({
302
+ ...Me,
303
+ __name: "DateTimeFormatInput",
304
+ props: /* @__PURE__ */ te({
305
+ disabled: { type: Boolean, required: !1, default: !1 },
306
+ compact: { type: Boolean, required: !1, default: !1 },
307
+ isValid: { type: Boolean, required: !1, default: !0 },
308
+ allDefaultFormats: { type: [Array, null], required: !0 },
309
+ allowedTypes: { type: Array, required: !1, default: () => [
310
+ "DATE",
311
+ "TIME",
312
+ "DATE_TIME",
313
+ "ZONED_DATE_TIME"
314
+ ] },
315
+ showTypeSwitchInPopover: { type: Boolean, required: !1, default: !0 }
316
+ }, {
317
+ modelValue: { type: Object, default: {
318
+ format: "yyyy-MM-dd",
319
+ temporalType: "DATE"
320
+ } },
321
+ modelModifiers: {}
322
+ }),
323
+ emits: ["update:modelValue"],
324
+ setup(g, { expose: a }) {
325
+ a();
326
+ const c = g, e = oe(g, "modelValue"), d = x({
327
+ get: () => e.value.format,
328
+ set: (F) => {
329
+ e.value = {
330
+ ...e.value,
331
+ format: F
332
+ };
333
+ }
334
+ }), w = "Format like 'yyyy-MM-dd'", l = x(() => c.isValid), s = y(null), h = y(null), m = y(!1), f = (F) => {
335
+ e.value = F, m.value = !1;
336
+ };
337
+ re(h, () => m.value = !1, {
338
+ ignore: [s]
339
+ });
340
+ const { floatingStyles: n } = ne(
341
+ s,
342
+ h,
343
+ {
344
+ middleware: [
345
+ se({
346
+ mainAxis: 2,
347
+ crossAxis: 0
348
+ }),
349
+ ce(),
350
+ de({
351
+ mainAxis: !0,
352
+ crossAxis: !1
353
+ })
354
+ ],
355
+ placement: "top-end",
356
+ whileElementsMounted: ie
357
+ }
358
+ ), E = { props: c, pickedFormatModel: e, formatSubModel: d, textFieldPlaceholder: w, isValueValid: l, togglePopoverButtonRef: s, floatingPopoverRef: h, showPopOver: m, onCommitPopupChanges: f, popoverFloatingStyles: n, get CalendarFilterIcon() {
359
+ return he;
360
+ }, DateTimeFormatPickerPopover: De };
361
+ return Object.defineProperty(E, "__isScriptSetup", { enumerable: !1, value: !0 }), E;
362
+ }
363
+ }), ke = { class: "input-fields" }, Pe = ["disabled"], Ve = {
364
+ key: 0,
365
+ class: "invalid-marker"
366
+ }, Ce = ["disabled"];
367
+ function Ae(g, a, c, e, d, w) {
368
+ return p(), T("div", null, [
369
+ u(
370
+ "div",
371
+ {
372
+ class: V(["wrapper", { disabled: c.disabled, compact: c.compact }])
373
+ },
374
+ [
375
+ u("span", ke, [
376
+ ae(u("input", {
377
+ "onUpdate:modelValue": a[0] || (a[0] = (l) => e.formatSubModel = l),
378
+ type: "text",
379
+ disabled: c.disabled,
380
+ placeholder: e.textFieldPlaceholder,
381
+ spellcheck: "false",
382
+ onFocus: a[1] || (a[1] = (l) => e.showPopOver = !1)
383
+ }, null, 40, Pe), [
384
+ [le, e.formatSubModel]
385
+ ]),
386
+ e.isValueValid ? P("v-if", !0) : (p(), T("span", Ve)),
387
+ u("button", {
388
+ ref: "togglePopoverButtonRef",
389
+ class: V(["trigger-popover-button", { active: e.showPopOver }]),
390
+ disabled: c.disabled,
391
+ onClick: a[2] || (a[2] = (l) => e.showPopOver = !e.showPopOver)
392
+ }, [
393
+ I(e.CalendarFilterIcon)
394
+ ], 10, Ce)
395
+ ])
396
+ ],
397
+ 2
398
+ /* CLASS */
399
+ ),
400
+ e.showPopOver ? (p(), T(
401
+ "div",
402
+ {
403
+ key: 0,
404
+ ref: "floatingPopoverRef",
405
+ class: "popover",
406
+ style: K(e.popoverFloatingStyles)
407
+ },
408
+ [
409
+ I(e.DateTimeFormatPickerPopover, {
410
+ "all-formats": c.allDefaultFormats,
411
+ "initial-selected-pattern": e.pickedFormatModel.format,
412
+ "selected-type": e.pickedFormatModel.temporalType,
413
+ "show-type-switch": c.showTypeSwitchInPopover,
414
+ onCommit: e.onCommitPopupChanges,
415
+ onCancel: a[3] || (a[3] = (l) => e.showPopOver = !1)
416
+ }, null, 8, ["all-formats", "initial-selected-pattern", "selected-type", "show-type-switch"])
417
+ ],
418
+ 4
419
+ /* STYLE */
420
+ )) : P("v-if", !0)
421
+ ]);
422
+ }
423
+ const qe = /* @__PURE__ */ j(Se, [["render", Ae], ["__scopeId", "data-v-3efc38c3"], ["__file", "/Users/albrecht/Documents/KNIME/git/webapps-common/packages/components/src/components/forms/DateTimeFormatInput/DateTimeFormatInput.vue"]]);
424
+ export {
425
+ qe as D
426
+ };
@@ -0,0 +1,47 @@
1
+ import { defineComponent as d, computed as a, createBlock as c, openBlock as p } from "vue";
2
+ import { u as f, _ as F } from "./SectionHeading.vue_vue_type_style_index_0_scoped_f06e9b7d_lang-B5ALSUVO.js";
3
+ import { D as _ } from "./DateTimeFormatInput-Ds2VLXw1.js";
4
+ const b = /* @__PURE__ */ d({
5
+ __name: "DateTimeFormatPickerControl",
6
+ props: {
7
+ control: { type: Object, required: !0 },
8
+ handleChange: { type: Function, required: !0 },
9
+ changeValue: { type: Function, required: !0 },
10
+ disabled: { type: Boolean, required: !0 },
11
+ isValid: { type: Boolean, required: !0 },
12
+ onRegisterValidation: { type: Function, required: !0 },
13
+ labelForId: { type: String, required: !0 }
14
+ },
15
+ setup(n, { expose: o }) {
16
+ o();
17
+ const t = n, e = a(
18
+ () => t.control.uischema
19
+ ), r = a(() => e.value.options), i = a(() => r.value?.allowedFormats), l = f(e, "dateTimeFormats"), m = a({
20
+ get: () => ({
21
+ format: t.control.data,
22
+ temporalType: "DATE"
23
+ }),
24
+ set: (u) => t.changeValue(u.format)
25
+ }), s = { props: t, uischema: e, options: r, allowedFormats: i, allBaseFormats: l, modelValue: m, get DateTimeFormatInput() {
26
+ return _;
27
+ } };
28
+ return Object.defineProperty(s, "__isScriptSetup", { enumerable: !1, value: !0 }), s;
29
+ }
30
+ });
31
+ function y(n, o, t, e, r, i) {
32
+ return p(), c(e.DateTimeFormatInput, {
33
+ id: t.labelForId,
34
+ modelValue: e.modelValue,
35
+ "onUpdate:modelValue": o[0] || (o[0] = (l) => e.modelValue = l),
36
+ compact: "",
37
+ disabled: t.disabled,
38
+ "show-type-switch-in-popover": !0,
39
+ "allowed-formats": e.allowedFormats,
40
+ "all-default-formats": e.allBaseFormats,
41
+ "is-valid": !0
42
+ }, null, 8, ["id", "modelValue", "disabled", "allowed-formats", "all-default-formats"]);
43
+ }
44
+ const T = /* @__PURE__ */ F(b, [["render", y], ["__file", "/Users/albrecht/Documents/KNIME/git/webapps-common/packages/jsonforms/src/uiComponents/DateTimeFormatPickerControl.vue"]]);
45
+ export {
46
+ T as default
47
+ };
@@ -0,0 +1,85 @@
1
+ import { defineComponent as f, computed as l, createElementBlock as T, openBlock as _, createVNode as u } from "vue";
2
+ import { u as V, _ as b } from "./SectionHeading.vue_vue_type_style_index_0_scoped_f06e9b7d_lang-B5ALSUVO.js";
3
+ import { V as h } from "./ValueSwitch-Ozmr1YfK.js";
4
+ import { D as y } from "./DateTimeFormatInput-Ds2VLXw1.js";
5
+ const F = /* @__PURE__ */ f({
6
+ __name: "DateTimeFormatPickerWithTypeControl",
7
+ props: {
8
+ control: { type: Object, required: !0 },
9
+ handleChange: { type: Function, required: !0 },
10
+ changeValue: { type: Function, required: !0 },
11
+ disabled: { type: Boolean, required: !0 },
12
+ isValid: { type: Boolean, required: !0 },
13
+ onRegisterValidation: { type: Function, required: !0 },
14
+ labelForId: { type: String, required: !0 }
15
+ },
16
+ setup(n, { expose: o }) {
17
+ o();
18
+ const t = n, e = l(
19
+ () => t.control.uischema
20
+ ), i = l(() => e.value.options), s = l(() => i.value?.allowedFormats), a = V(e, "dateTimeFormats"), c = [
21
+ {
22
+ id: "DATE",
23
+ text: "Date"
24
+ },
25
+ {
26
+ id: "DATE_TIME",
27
+ text: "Date & time"
28
+ },
29
+ {
30
+ id: "TIME",
31
+ text: "Time"
32
+ },
33
+ {
34
+ id: "ZONED_DATE_TIME",
35
+ text: "Zoned date & time"
36
+ }
37
+ ], r = l({
38
+ get: () => t.control.data,
39
+ set: (d) => {
40
+ t.changeValue(d);
41
+ }
42
+ }), p = l({
43
+ get: () => r.value.temporalType,
44
+ set: (d) => {
45
+ r.value = {
46
+ ...r.value,
47
+ temporalType: d
48
+ };
49
+ }
50
+ }), m = { props: t, uischema: e, options: i, allowedFormats: s, allBaseFormats: a, possibleValueSwitchChoices: c, modelValue: r, temporalTypeModel: p, get DateTimeFormatInput() {
51
+ return y;
52
+ }, get ValueSwitch() {
53
+ return h;
54
+ } };
55
+ return Object.defineProperty(m, "__isScriptSetup", { enumerable: !1, value: !0 }), m;
56
+ }
57
+ }), D = ["id"];
58
+ function v(n, o, t, e, i, s) {
59
+ return _(), T("div", {
60
+ id: t.labelForId,
61
+ class: "control-container"
62
+ }, [
63
+ u(e.ValueSwitch, {
64
+ modelValue: e.temporalTypeModel,
65
+ "onUpdate:modelValue": o[0] || (o[0] = (a) => e.temporalTypeModel = a),
66
+ compact: "",
67
+ "possible-values": e.possibleValueSwitchChoices,
68
+ disabled: t.disabled
69
+ }, null, 8, ["modelValue", "disabled"]),
70
+ u(e.DateTimeFormatInput, {
71
+ modelValue: e.modelValue,
72
+ "onUpdate:modelValue": o[1] || (o[1] = (a) => e.modelValue = a),
73
+ compact: "",
74
+ disabled: t.disabled,
75
+ "show-type-switch-in-popover": !1,
76
+ "allowed-formats": e.allowedFormats,
77
+ "all-default-formats": e.allBaseFormats,
78
+ "is-valid": !0
79
+ }, null, 8, ["modelValue", "disabled", "allowed-formats", "all-default-formats"])
80
+ ], 8, D);
81
+ }
82
+ const S = /* @__PURE__ */ b(F, [["render", v], ["__scopeId", "data-v-427f35bb"], ["__file", "/Users/albrecht/Documents/KNIME/git/webapps-common/packages/jsonforms/src/uiComponents/DateTimeFormatPickerWithTypeControl.vue"]]);
83
+ export {
84
+ S as default
85
+ };