@startinblox/core 0.17.31 → 0.18.0-beta.2

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 (255) hide show
  1. package/dist/_snowpack/pkg/autolinker.js +3515 -3367
  2. package/dist/_snowpack/pkg/autolinker.js.map +1 -1
  3. package/dist/_snowpack/pkg/common/{_baseUnary-217dffb2.js → _baseUnary-c1edb653.js} +16 -40
  4. package/dist/_snowpack/pkg/common/{_baseUnary-217dffb2.js.map → _baseUnary-c1edb653.js.map} +1 -1
  5. package/dist/_snowpack/pkg/common/{_commonjsHelpers-8c19dec8.js → _commonjsHelpers-37fa8da4.js} +6 -2
  6. package/dist/_snowpack/pkg/common/_commonjsHelpers-37fa8da4.js.map +1 -0
  7. package/dist/_snowpack/pkg/common/{decode-a4c334cf.js → decode-26fbf385.js} +38 -69
  8. package/dist/_snowpack/pkg/common/decode-26fbf385.js.map +1 -0
  9. package/dist/_snowpack/pkg/common/lit-html-3647afce.js +1104 -0
  10. package/dist/_snowpack/pkg/common/lit-html-3647afce.js.map +1 -0
  11. package/dist/_snowpack/pkg/delta-markdown-for-quill.js +4767 -4246
  12. package/dist/_snowpack/pkg/delta-markdown-for-quill.js.map +1 -1
  13. package/dist/_snowpack/pkg/dialog-polyfill.js +107 -139
  14. package/dist/_snowpack/pkg/dialog-polyfill.js.map +1 -1
  15. package/dist/_snowpack/pkg/fusejs.js +411 -601
  16. package/dist/_snowpack/pkg/fusejs.js.map +1 -1
  17. package/dist/_snowpack/pkg/jsonld-context-parser.js +718 -686
  18. package/dist/_snowpack/pkg/jsonld-context-parser.js.map +1 -1
  19. package/dist/_snowpack/pkg/leaflet.markercluster/dist/MarkerCluster.Default.css +59 -59
  20. package/dist/_snowpack/pkg/leaflet.markercluster/dist/MarkerCluster.Default.css.proxy.js +1 -1
  21. package/dist/_snowpack/pkg/leaflet.markercluster/dist/MarkerCluster.css +14 -14
  22. package/dist/_snowpack/pkg/leaflet.markercluster/dist/MarkerCluster.css.proxy.js +1 -1
  23. package/dist/_snowpack/pkg/lit-html/directives/if-defined.js +13 -14
  24. package/dist/_snowpack/pkg/lit-html/directives/if-defined.js.map +1 -1
  25. package/dist/_snowpack/pkg/lit-html/directives/unsafe-html.js +17 -15
  26. package/dist/_snowpack/pkg/lit-html/directives/unsafe-html.js.map +1 -1
  27. package/dist/_snowpack/pkg/lit-html/directives/until.js +45 -46
  28. package/dist/_snowpack/pkg/lit-html/directives/until.js.map +1 -1
  29. package/dist/_snowpack/pkg/lit-html.js +37 -35
  30. package/dist/_snowpack/pkg/lit-html.js.map +1 -1
  31. package/dist/_snowpack/pkg/markdown-it-link-attributes.js +1 -20
  32. package/dist/_snowpack/pkg/markdown-it-link-attributes.js.map +1 -1
  33. package/dist/_snowpack/pkg/markdown-it.js +1731 -2284
  34. package/dist/_snowpack/pkg/markdown-it.js.map +1 -1
  35. package/dist/_snowpack/pkg/quill-delta-to-markdown.js +236 -294
  36. package/dist/_snowpack/pkg/quill-delta-to-markdown.js.map +1 -1
  37. package/dist/_snowpack/pkg/quill.js +12077 -11017
  38. package/dist/_snowpack/pkg/quill.js.map +1 -1
  39. package/dist/_snowpack/pkg/slim-select.js +711 -1
  40. package/dist/_snowpack/pkg/slim-select.js.map +1 -1
  41. package/dist/_snowpack/pkg/tui-calendar/dist/tui-calendar.css +1 -16
  42. package/dist/_snowpack/pkg/tui-calendar/dist/tui-calendar.css.proxy.js +1 -1
  43. package/dist/_snowpack/pkg/tui-calendar.js +44297 -40075
  44. package/dist/_snowpack/pkg/tui-calendar.js.map +1 -1
  45. package/dist/components/solid-ac-checker.js +4 -17
  46. package/dist/components/solid-calendar.js +5 -26
  47. package/dist/components/solid-delete.js +9 -24
  48. package/dist/components/solid-display.js +15 -59
  49. package/dist/components/solid-form-search.js +27 -79
  50. package/dist/components/solid-form.js +48 -143
  51. package/dist/components/solid-lang.js +8 -19
  52. package/dist/components/solid-map.js +26 -64
  53. package/dist/components/solid-table.js +51 -133
  54. package/dist/components/solid-widget.js +2 -24
  55. package/dist/index.js +17 -11
  56. package/dist/libs/Component.js +4 -10
  57. package/dist/libs/ComponentFactory.js +6 -34
  58. package/dist/libs/Compositor.js +8 -15
  59. package/dist/libs/Sib.js +7 -21
  60. package/dist/libs/filter.js +184 -0
  61. package/dist/libs/helpers.js +19 -47
  62. package/dist/libs/interfaces.js +1 -1
  63. package/dist/libs/lit-helpers.js +7 -34
  64. package/dist/libs/polyfills.js +7 -10
  65. package/dist/libs/store/server-pagination.js +22 -0
  66. package/dist/libs/store/server-search.js +35 -0
  67. package/dist/libs/store/store.js +243 -234
  68. package/dist/mixins/attributeBinderMixin.js +17 -25
  69. package/dist/mixins/contextMixin.js +5 -7
  70. package/dist/mixins/counterMixin.js +2 -23
  71. package/dist/mixins/federationMixin.js +2 -14
  72. package/dist/mixins/filterMixin.js +60 -100
  73. package/dist/mixins/grouperMixin.js +11 -18
  74. package/dist/mixins/highlighterMixin.js +2 -8
  75. package/dist/mixins/interfaces.js +3 -5
  76. package/dist/mixins/listMixin.js +12 -43
  77. package/dist/mixins/nextMixin.js +1 -4
  78. package/dist/mixins/paginateMixin.js +17 -30
  79. package/dist/mixins/requiredMixin.js +1 -9
  80. package/dist/mixins/serverPaginationMixin.js +122 -0
  81. package/dist/mixins/sorterMixin.js +26 -44
  82. package/dist/mixins/storeMixin.js +28 -21
  83. package/dist/mixins/translationMixin.js +2 -12
  84. package/dist/mixins/validationMixin.js +28 -46
  85. package/dist/mixins/widgetMixin.js +58 -154
  86. package/dist/new-widgets/attributeMixins/actionMixin.js +1 -2
  87. package/dist/new-widgets/attributeMixins/blankMixin.js +1 -4
  88. package/dist/new-widgets/attributeMixins/booleanMixin.js +1 -4
  89. package/dist/new-widgets/attributeMixins/index.js +1 -2
  90. package/dist/new-widgets/attributeMixins/mailtoMixin.js +1 -4
  91. package/dist/new-widgets/attributeMixins/multipleMixin.js +1 -2
  92. package/dist/new-widgets/attributeMixins/numberMixin.js +1 -4
  93. package/dist/new-widgets/attributeMixins/placeholderMixin.js +1 -4
  94. package/dist/new-widgets/attributeMixins/telMixin.js +1 -4
  95. package/dist/new-widgets/baseWidgetMixin.js +5 -18
  96. package/dist/new-widgets/callbackMixins/autocompletionMixin.js +3 -11
  97. package/dist/new-widgets/callbackMixins/index.js +1 -2
  98. package/dist/new-widgets/callbackMixins/richtextMixin.js +1 -6
  99. package/dist/new-widgets/interfaces.js +1 -0
  100. package/dist/new-widgets/new-widget-factory.js +14 -19
  101. package/dist/new-widgets/templateAdditionMixins/addableMixin.js +6 -21
  102. package/dist/new-widgets/templateAdditionMixins/index.js +2 -3
  103. package/dist/new-widgets/templateAdditionMixins/labelLastMixin.js +5 -18
  104. package/dist/new-widgets/templateAdditionMixins/labelMixin.js +5 -18
  105. package/dist/new-widgets/templates/defaultTemplatesDirectory.js +21 -27
  106. package/dist/new-widgets/templates/displayTemplatesDirectory.js +35 -70
  107. package/dist/new-widgets/templates/formTemplatesDirectory.js +350 -315
  108. package/dist/new-widgets/templates/groupTemplatesDirectory.js +5 -15
  109. package/dist/new-widgets/templates/index.js +1 -2
  110. package/dist/new-widgets/templates/setTemplatesDirectory.js +4 -37
  111. package/dist/new-widgets/templatesDependencies/altMixin.js +1 -2
  112. package/dist/new-widgets/templatesDependencies/editableMixin.js +9 -26
  113. package/dist/new-widgets/templatesDependencies/filterRangeFormMixin.js +3 -7
  114. package/dist/new-widgets/templatesDependencies/formCheckboxMixin.js +1 -5
  115. package/dist/new-widgets/templatesDependencies/formCheckboxesMixin.js +1 -11
  116. package/dist/new-widgets/templatesDependencies/formDropdownMixin.js +3 -13
  117. package/dist/new-widgets/templatesDependencies/formFileMixin.js +1 -13
  118. package/dist/new-widgets/templatesDependencies/formLengthMixin.js +1 -2
  119. package/dist/new-widgets/templatesDependencies/formMinMaxMixin.js +1 -2
  120. package/dist/new-widgets/templatesDependencies/formMixin.js +4 -14
  121. package/dist/new-widgets/templatesDependencies/formNumberMixin.js +1 -5
  122. package/dist/new-widgets/templatesDependencies/formRadioMixin.js +1 -5
  123. package/dist/new-widgets/templatesDependencies/formStepMixin.js +1 -2
  124. package/dist/new-widgets/templatesDependencies/linkTextMixin.js +13 -0
  125. package/dist/new-widgets/templatesDependencies/multipleFormMixin.js +23 -18
  126. package/dist/new-widgets/templatesDependencies/multipleselectFormMixin.js +1 -10
  127. package/dist/new-widgets/templatesDependencies/patternMixin.js +1 -2
  128. package/dist/new-widgets/templatesDependencies/rangeMixin.js +5 -15
  129. package/dist/new-widgets/templatesDependencies/setMixin.js +1 -4
  130. package/dist/new-widgets/templatesDependencies/valueRichtextMixin.js +1 -4
  131. package/dist/new-widgets/valueTransformationMixins/autolinkMixin.js +1 -5
  132. package/dist/new-widgets/valueTransformationMixins/dateMixin.js +5 -11
  133. package/dist/new-widgets/valueTransformationMixins/dateTimeMixin.js +1 -5
  134. package/dist/new-widgets/valueTransformationMixins/index.js +1 -2
  135. package/dist/new-widgets/valueTransformationMixins/markdownMixin.js +1 -7
  136. package/dist/new-widgets/valueTransformationMixins/multilineMixin.js +1 -5
  137. package/dist/new-widgets/valueTransformationMixins/oembedMixin.js +1 -7
  138. package/dist/solid-template-element.js +24 -44
  139. package/dist/widgets/baseWidget.js +21 -85
  140. package/dist/widgets/widget-factory.js +4 -6
  141. package/package.json +8 -6
  142. package/dist/_snowpack/env.js +0 -3
  143. package/dist/_snowpack/pkg/autolinker.js.map.proxy.js +0 -1
  144. package/dist/_snowpack/pkg/common/_baseUnary-217dffb2.js.map.proxy.js +0 -1
  145. package/dist/_snowpack/pkg/common/_commonjsHelpers-8c19dec8.js.map +0 -1
  146. package/dist/_snowpack/pkg/common/_commonjsHelpers-8c19dec8.js.map.proxy.js +0 -1
  147. package/dist/_snowpack/pkg/common/decode-a4c334cf.js.map +0 -1
  148. package/dist/_snowpack/pkg/common/decode-a4c334cf.js.map.proxy.js +0 -1
  149. package/dist/_snowpack/pkg/common/lit-html-babd44cd.js +0 -1119
  150. package/dist/_snowpack/pkg/common/lit-html-babd44cd.js.map +0 -1
  151. package/dist/_snowpack/pkg/common/lit-html-babd44cd.js.map.proxy.js +0 -1
  152. package/dist/_snowpack/pkg/delta-markdown-for-quill.js.map.proxy.js +0 -1
  153. package/dist/_snowpack/pkg/dialog-polyfill.js.map.proxy.js +0 -1
  154. package/dist/_snowpack/pkg/fusejs.js.map.proxy.js +0 -1
  155. package/dist/_snowpack/pkg/jsonld-context-parser.js.map.proxy.js +0 -1
  156. package/dist/_snowpack/pkg/lit-html/directives/if-defined.js.map.proxy.js +0 -1
  157. package/dist/_snowpack/pkg/lit-html/directives/unsafe-html.js.map.proxy.js +0 -1
  158. package/dist/_snowpack/pkg/lit-html/directives/until.js.map.proxy.js +0 -1
  159. package/dist/_snowpack/pkg/lit-html.js.map.proxy.js +0 -1
  160. package/dist/_snowpack/pkg/markdown-it-link-attributes.js.map.proxy.js +0 -1
  161. package/dist/_snowpack/pkg/markdown-it.js.map.proxy.js +0 -1
  162. package/dist/_snowpack/pkg/quill-delta-to-markdown.js.map.proxy.js +0 -1
  163. package/dist/_snowpack/pkg/quill.js.map.proxy.js +0 -1
  164. package/dist/_snowpack/pkg/slim-select.js.map.proxy.js +0 -1
  165. package/dist/_snowpack/pkg/tui-calendar.js.map.proxy.js +0 -1
  166. package/dist/components/solid-ac-checker.js.map +0 -1
  167. package/dist/components/solid-calendar.js.map +0 -1
  168. package/dist/components/solid-delete.js.map +0 -1
  169. package/dist/components/solid-display.js.map +0 -1
  170. package/dist/components/solid-form-search.js.map +0 -1
  171. package/dist/components/solid-form.js.map +0 -1
  172. package/dist/components/solid-lang.js.map +0 -1
  173. package/dist/components/solid-map.js.map +0 -1
  174. package/dist/components/solid-table.js.map +0 -1
  175. package/dist/components/solid-widget.js.map +0 -1
  176. package/dist/index.js.map +0 -1
  177. package/dist/libs/Component.js.map +0 -1
  178. package/dist/libs/ComponentFactory.js.map +0 -1
  179. package/dist/libs/Compositor.js.map +0 -1
  180. package/dist/libs/Sib.js.map +0 -1
  181. package/dist/libs/helpers.js.map +0 -1
  182. package/dist/libs/interfaces.js.map +0 -1
  183. package/dist/libs/lit-helpers.js.map +0 -1
  184. package/dist/libs/polyfills.js.map +0 -1
  185. package/dist/libs/store/store.js.map +0 -1
  186. package/dist/mixins/attributeBinderMixin.js.map +0 -1
  187. package/dist/mixins/contextMixin.js.map +0 -1
  188. package/dist/mixins/counterMixin.js.map +0 -1
  189. package/dist/mixins/federationMixin.js.map +0 -1
  190. package/dist/mixins/filterMixin.js.map +0 -1
  191. package/dist/mixins/grouperMixin.js.map +0 -1
  192. package/dist/mixins/highlighterMixin.js.map +0 -1
  193. package/dist/mixins/interfaces.js.map +0 -1
  194. package/dist/mixins/listMixin.js.map +0 -1
  195. package/dist/mixins/nextMixin.js.map +0 -1
  196. package/dist/mixins/paginateMixin.js.map +0 -1
  197. package/dist/mixins/requiredMixin.js.map +0 -1
  198. package/dist/mixins/sorterMixin.js.map +0 -1
  199. package/dist/mixins/storeMixin.js.map +0 -1
  200. package/dist/mixins/translationMixin.js.map +0 -1
  201. package/dist/mixins/validationMixin.js.map +0 -1
  202. package/dist/mixins/widgetMixin.js.map +0 -1
  203. package/dist/new-widgets/attributeMixins/actionMixin.js.map +0 -1
  204. package/dist/new-widgets/attributeMixins/blankMixin.js.map +0 -1
  205. package/dist/new-widgets/attributeMixins/booleanMixin.js.map +0 -1
  206. package/dist/new-widgets/attributeMixins/index.js.map +0 -1
  207. package/dist/new-widgets/attributeMixins/mailtoMixin.js.map +0 -1
  208. package/dist/new-widgets/attributeMixins/multipleMixin.js.map +0 -1
  209. package/dist/new-widgets/attributeMixins/numberMixin.js.map +0 -1
  210. package/dist/new-widgets/attributeMixins/placeholderMixin.js.map +0 -1
  211. package/dist/new-widgets/attributeMixins/telMixin.js.map +0 -1
  212. package/dist/new-widgets/baseWidgetMixin.js.map +0 -1
  213. package/dist/new-widgets/callbackMixins/autocompletionMixin.js.map +0 -1
  214. package/dist/new-widgets/callbackMixins/index.js.map +0 -1
  215. package/dist/new-widgets/callbackMixins/richtextMixin.js.map +0 -1
  216. package/dist/new-widgets/new-widget-factory.js.map +0 -1
  217. package/dist/new-widgets/templateAdditionMixins/addableMixin.js.map +0 -1
  218. package/dist/new-widgets/templateAdditionMixins/index.js.map +0 -1
  219. package/dist/new-widgets/templateAdditionMixins/labelLastMixin.js.map +0 -1
  220. package/dist/new-widgets/templateAdditionMixins/labelMixin.js.map +0 -1
  221. package/dist/new-widgets/templates/defaultTemplatesDirectory.js.map +0 -1
  222. package/dist/new-widgets/templates/displayTemplatesDirectory.js.map +0 -1
  223. package/dist/new-widgets/templates/formTemplatesDirectory.js.map +0 -1
  224. package/dist/new-widgets/templates/groupTemplatesDirectory.js.map +0 -1
  225. package/dist/new-widgets/templates/index.js.map +0 -1
  226. package/dist/new-widgets/templates/setTemplatesDirectory.js.map +0 -1
  227. package/dist/new-widgets/templatesDependencies/altMixin.js.map +0 -1
  228. package/dist/new-widgets/templatesDependencies/editableMixin.js.map +0 -1
  229. package/dist/new-widgets/templatesDependencies/filterRangeFormMixin.js.map +0 -1
  230. package/dist/new-widgets/templatesDependencies/formCheckboxMixin.js.map +0 -1
  231. package/dist/new-widgets/templatesDependencies/formCheckboxesMixin.js.map +0 -1
  232. package/dist/new-widgets/templatesDependencies/formDropdownMixin.js.map +0 -1
  233. package/dist/new-widgets/templatesDependencies/formFileMixin.js.map +0 -1
  234. package/dist/new-widgets/templatesDependencies/formLengthMixin.js.map +0 -1
  235. package/dist/new-widgets/templatesDependencies/formMinMaxMixin.js.map +0 -1
  236. package/dist/new-widgets/templatesDependencies/formMixin.js.map +0 -1
  237. package/dist/new-widgets/templatesDependencies/formNumberMixin.js.map +0 -1
  238. package/dist/new-widgets/templatesDependencies/formRadioMixin.js.map +0 -1
  239. package/dist/new-widgets/templatesDependencies/formStepMixin.js.map +0 -1
  240. package/dist/new-widgets/templatesDependencies/multipleFormMixin.js.map +0 -1
  241. package/dist/new-widgets/templatesDependencies/multipleselectFormMixin.js.map +0 -1
  242. package/dist/new-widgets/templatesDependencies/patternMixin.js.map +0 -1
  243. package/dist/new-widgets/templatesDependencies/rangeMixin.js.map +0 -1
  244. package/dist/new-widgets/templatesDependencies/setMixin.js.map +0 -1
  245. package/dist/new-widgets/templatesDependencies/valueRichtextMixin.js.map +0 -1
  246. package/dist/new-widgets/valueTransformationMixins/autolinkMixin.js.map +0 -1
  247. package/dist/new-widgets/valueTransformationMixins/dateMixin.js.map +0 -1
  248. package/dist/new-widgets/valueTransformationMixins/dateTimeMixin.js.map +0 -1
  249. package/dist/new-widgets/valueTransformationMixins/index.js.map +0 -1
  250. package/dist/new-widgets/valueTransformationMixins/markdownMixin.js.map +0 -1
  251. package/dist/new-widgets/valueTransformationMixins/multilineMixin.js.map +0 -1
  252. package/dist/new-widgets/valueTransformationMixins/oembedMixin.js.map +0 -1
  253. package/dist/solid-template-element.js.map +0 -1
  254. package/dist/widgets/baseWidget.js.map +0 -1
  255. package/dist/widgets/widget-factory.js.map +0 -1
@@ -1,21 +1,11 @@
1
- function _templateObject() {
2
- const data = _taggedTemplateLiteral(["\n <span>", "</span>\n <div data-content></div>\n "]);
3
-
4
- _templateObject = function () {
5
- return data;
6
- };
7
-
8
- return data;
9
- }
10
-
11
- function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
12
-
13
1
  import { html } from '../../_snowpack/pkg/lit-html.js';
14
2
  import { SetMixin } from '../templatesDependencies/setMixin.js';
15
3
  export const groupTemplates = {
16
4
  default: {
17
- template: value => html(_templateObject(), value),
5
+ template: value => html`
6
+ <span>${value}</span>
7
+ <div data-content></div>
8
+ `,
18
9
  dependencies: [SetMixin]
19
10
  }
20
- };
21
- //# sourceMappingURL=groupTemplatesDirectory.js.map
11
+ };
@@ -3,5 +3,4 @@ import { displayTemplates } from './displayTemplatesDirectory.js';
3
3
  import { formTemplates } from './formTemplatesDirectory.js';
4
4
  import { setTemplates } from './setTemplatesDirectory.js';
5
5
  import { groupTemplates } from './groupTemplatesDirectory.js';
6
- export { defaultTemplates, displayTemplates, formTemplates, setTemplates, groupTemplates };
7
- //# sourceMappingURL=index.js.map
6
+ export { defaultTemplates, displayTemplates, formTemplates, setTemplates, groupTemplates };
@@ -1,49 +1,16 @@
1
- function _templateObject3() {
2
- const data = _taggedTemplateLiteral(["<ul data-content></ul>"]);
3
-
4
- _templateObject3 = function () {
5
- return data;
6
- };
7
-
8
- return data;
9
- }
10
-
11
- function _templateObject2() {
12
- const data = _taggedTemplateLiteral(["<div data-content></div>"]);
13
-
14
- _templateObject2 = function () {
15
- return data;
16
- };
17
-
18
- return data;
19
- }
20
-
21
- function _templateObject() {
22
- const data = _taggedTemplateLiteral([""]);
23
-
24
- _templateObject = function () {
25
- return data;
26
- };
27
-
28
- return data;
29
- }
30
-
31
- function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
32
-
33
1
  import { html } from '../../_snowpack/pkg/lit-html.js';
34
2
  import { SetMixin } from '../templatesDependencies/setMixin.js';
35
3
  export const setTemplates = {
36
4
  default: {
37
- template: () => html(_templateObject()),
5
+ template: () => html``,
38
6
  dependencies: [SetMixin]
39
7
  },
40
8
  div: {
41
- template: () => html(_templateObject2()),
9
+ template: () => html`<div data-content></div>`,
42
10
  dependencies: [SetMixin]
43
11
  },
44
12
  ul: {
45
- template: () => html(_templateObject3()),
13
+ template: () => html`<ul data-content></ul>`,
46
14
  dependencies: [SetMixin]
47
15
  }
48
- };
49
- //# sourceMappingURL=setTemplatesDirectory.js.map
16
+ };
@@ -9,5 +9,4 @@ const AltMixin = {
9
9
  }
10
10
  }
11
11
  };
12
- export { AltMixin };
13
- //# sourceMappingURL=altMixin.js.map
12
+ export { AltMixin };
@@ -1,15 +1,3 @@
1
- function _templateObject() {
2
- const data = _taggedTemplateLiteral(["\n ", "\n <button @click=", ">Modifier</button>\n "]);
3
-
4
- _templateObject = function () {
5
- return data;
6
- };
7
-
8
- return data;
9
- }
10
-
11
- function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
12
-
13
1
  import { StoreMixin } from '../../mixins/storeMixin.js';
14
2
  import { store } from '../../libs/store/store.js';
15
3
  import { html } from '../../_snowpack/pkg/lit-html.js';
@@ -30,48 +18,43 @@ const EditableMixin = {
30
18
  default: ''
31
19
  }
32
20
  },
33
-
34
21
  created() {
35
22
  this.listTemplateAdditions.push(this.addEditButton.bind(this));
36
23
  },
37
-
38
24
  addEditButton(template, listTemplateAdditions) {
39
25
  let newTemplate = null;
40
-
41
26
  if (this.editable !== null) {
42
- newTemplate = html(_templateObject(), template, this.activateEditableField.bind(this));
27
+ newTemplate = html`
28
+ ${template}
29
+ <button @click=${this.activateEditableField.bind(this)}>Modifier</button>
30
+ `;
43
31
  }
44
-
45
32
  const nextProcessor = listTemplateAdditions.shift();
46
33
  if (nextProcessor) nextProcessor(newTemplate || template, listTemplateAdditions);
47
34
  },
48
-
49
35
  activateEditableField(e) {
50
36
  const editableField = this.element.querySelector('[data-editable]');
51
- const editButton = e.target; // Set attributes
37
+ const editButton = e.target;
52
38
 
39
+ // Set attributes
53
40
  editableField.toggleAttribute('contenteditable', true);
54
41
  editableField.focus();
55
- editButton.toggleAttribute('disabled', true); // Save on focusout
42
+ editButton.toggleAttribute('disabled', true);
56
43
 
44
+ // Save on focusout
57
45
  editableField.addEventListener('focusout', () => this.save(editableField, editButton));
58
46
  },
59
-
60
47
  save(editableField, editButton) {
61
48
  editableField.toggleAttribute('contenteditable', false);
62
49
  editButton.removeAttribute('disabled');
63
-
64
50
  if (!this.name || !this.valueId) {
65
51
  console.warn('Some attributes are missing to perform the update');
66
52
  return;
67
53
  }
68
-
69
54
  const resource = {};
70
55
  resource[this.name] = editableField.innerText;
71
56
  resource['@context'] = this.context;
72
57
  store.patch(resource, this.valueId);
73
58
  }
74
-
75
59
  };
76
- export { EditableMixin };
77
- //# sourceMappingURL=editableMixin.js.map
60
+ export { EditableMixin };
@@ -16,23 +16,19 @@ const FilterRangeFormMixin = {
16
16
  }
17
17
  }
18
18
  },
19
-
20
19
  getDefaultValue(value) {
21
20
  if (value == "today") return new Date().toISOString().split("T")[0];
22
21
  return value;
23
22
  },
24
-
25
23
  getValue() {
26
24
  if (!this.dataHolder) return [];
27
25
  if (this.dataHolder.length !== 2) this.showDataHolderError(2, this.dataHolder.length);
28
- return [// we expect 2 values, one min and one max
26
+ return [
27
+ // we expect 2 values, one min and one max
29
28
  this.getValueFromElement(this.dataHolder[0]), this.getValueFromElement(this.dataHolder[1])];
30
29
  },
31
-
32
30
  get type() {
33
31
  return 'range';
34
32
  }
35
-
36
33
  };
37
- export { FilterRangeFormMixin };
38
- //# sourceMappingURL=filterRangeFormMixin.js.map
34
+ export { FilterRangeFormMixin };
@@ -1,14 +1,10 @@
1
1
  const FormCheckboxMixin = {
2
2
  name: 'form-checkbox-mixin',
3
-
4
3
  getValueFromElement(element) {
5
4
  return element.checked;
6
5
  },
7
-
8
6
  get type() {
9
7
  return 'boolean';
10
8
  }
11
-
12
9
  };
13
- export { FormCheckboxMixin };
14
- //# sourceMappingURL=formCheckboxMixin.js.map
10
+ export { FormCheckboxMixin };
@@ -6,46 +6,36 @@ const FormCheckboxesMixin = {
6
6
  default: '',
7
7
  callback: function (value) {
8
8
  if (!value) return;
9
-
10
9
  try {
11
10
  this.listAttributes['values'] = JSON.parse(value);
12
11
  } catch (e) {
13
12
  console.error(e);
14
13
  this.listAttributes['values'] = [];
15
14
  }
16
-
17
15
  this.render();
18
16
  this.element.dispatchEvent(new Event('change'));
19
17
  }
20
18
  }
21
19
  },
22
-
23
20
  created() {
24
21
  this.listAttributes['values'] = [];
25
22
  },
26
-
27
23
  getValue() {
28
24
  const options = Array.from(this.element.querySelectorAll('input'));
29
25
  return options.filter(el => el.checked).map(el => {
30
26
  if (!el.value) return null;
31
27
  let value = el.value;
32
-
33
28
  try {
34
29
  value = JSON.parse(el.value);
35
30
  } catch (e) {}
36
-
37
31
  return value;
38
32
  });
39
33
  },
40
-
41
34
  get type() {
42
35
  return this.enum === '' ? 'resource' : 'string';
43
36
  },
44
-
45
37
  get multiple() {
46
38
  return true;
47
39
  }
48
-
49
40
  };
50
- export { FormCheckboxesMixin };
51
- //# sourceMappingURL=formCheckboxesMixin.js.map
41
+ export { FormCheckboxesMixin };
@@ -13,9 +13,7 @@ const FormDropdownMixin = {
13
13
  console.error(e);
14
14
  this.listAttributes['values'] = [];
15
15
  }
16
-
17
16
  this.render(); // use render to make sure the dispatch always happen after
18
-
19
17
  this.dispatchChange();
20
18
  }
21
19
  }
@@ -28,39 +26,31 @@ const FormDropdownMixin = {
28
26
  }
29
27
  }
30
28
  },
31
-
32
29
  created() {
33
30
  this.listAttributes['values'] = [];
34
31
  if (this.multiple) this.listAttributes['multiple'] = true;
35
32
  },
36
-
37
33
  dispatchChange() {
38
34
  if (!this.element.querySelector('select')) return;
39
35
  this.element.querySelector('select').dispatchEvent(new Event('change'));
40
36
  },
41
-
42
37
  getValue() {
43
38
  if (!this.dataHolder) return ''; // no value
44
-
45
39
  if (!this.multiple) {
46
40
  // simple select
47
41
  if (this.dataHolder.length > 1) this.showDataHolderError(1, this.dataHolder.length);
48
42
  return this.getValueFromElement(this.dataHolder[0]);
49
- } // multiple select
50
-
43
+ }
51
44
 
45
+ // multiple select
52
46
  const options = Array.from(this.element.querySelectorAll('option'));
53
47
  return options.filter(el => el.selected).map(el => el.value ? JSON.parse(el.value) : null);
54
48
  },
55
-
56
49
  get type() {
57
50
  return this.enum === '' ? 'resource' : 'string';
58
51
  },
59
-
60
52
  get multiple() {
61
53
  return this.element.hasAttribute('multiple');
62
54
  }
63
-
64
55
  };
65
- export { FormDropdownMixin };
66
- //# sourceMappingURL=formDropdownMixin.js.map
56
+ export { FormDropdownMixin };
@@ -10,14 +10,12 @@ const FormFileMixin = {
10
10
  initialState: {
11
11
  initialValue: ''
12
12
  },
13
-
14
13
  created() {
15
14
  this.listAttributes['output'] = '';
16
15
  this.listAttributes['resetButtonHidden'] = true;
17
16
  this.listAttributes['selectFile'] = this.selectFile.bind(this);
18
17
  this.listAttributes['resetFile'] = this.resetFile.bind(this);
19
18
  },
20
-
21
19
  attached() {
22
20
  document.addEventListener('reset', e => {
23
21
  if (e.target && e.target.contains(this.element)) {
@@ -30,14 +28,11 @@ const FormFileMixin = {
30
28
  }
31
29
  });
32
30
  },
33
-
34
31
  selectFile() {
35
32
  if (this.uploadUrl === null) return;
36
-
37
33
  if (this.initialValue === '') {
38
34
  this.initialValue = this.value;
39
35
  }
40
-
41
36
  const filePicker = this.element.querySelector('input[type="file"]');
42
37
  if (filePicker.files.length < 1) return;
43
38
  const dataHolder = this.element.querySelector('input[data-holder]');
@@ -56,10 +51,8 @@ const FormFileMixin = {
56
51
  console.error(error);
57
52
  });
58
53
  },
59
-
60
54
  updateFile(dataHolder, response) {
61
55
  const location = response.headers.get('location');
62
-
63
56
  if (location == null) {
64
57
  this.listAttributes['output'] = 'header location not found!';
65
58
  } else {
@@ -71,24 +64,19 @@ const FormFileMixin = {
71
64
  this.planRender();
72
65
  }
73
66
  },
74
-
75
67
  resetFile(event) {
76
68
  event.preventDefault();
77
69
  this.value = '';
78
70
  const filePicker = this.element.querySelector('input[type="file"]');
79
71
  const dataHolder = this.element.querySelector('input[data-holder]');
80
-
81
72
  if (filePicker && dataHolder) {
82
73
  filePicker.value = dataHolder.value = '';
83
74
  }
84
-
85
75
  this.listAttributes['fileValue'] = '';
86
76
  this.listAttributes['output'] = '';
87
77
  this.listAttributes['resetButtonHidden'] = true;
88
78
  dataHolder.dispatchEvent(new Event('change'));
89
79
  this.planRender();
90
80
  }
91
-
92
81
  };
93
- export { FormFileMixin };
94
- //# sourceMappingURL=formFileMixin.js.map
82
+ export { FormFileMixin };
@@ -15,5 +15,4 @@ const FormLengthMixin = {
15
15
  }
16
16
  }
17
17
  };
18
- export { FormLengthMixin };
19
- //# sourceMappingURL=formLengthMixin.js.map
18
+ export { FormLengthMixin };
@@ -15,5 +15,4 @@ const FormMinMaxMixin = {
15
15
  }
16
16
  }
17
17
  };
18
- export { FormMinMaxMixin };
19
- //# sourceMappingURL=formMinMaxMixin.js.map
18
+ export { FormMinMaxMixin };
@@ -16,11 +16,9 @@ const FormMixin = {
16
16
  }
17
17
  }
18
18
  },
19
-
20
19
  attached() {
21
20
  this.listAttributes['onChange'] = this.onChange.bind(this);
22
21
  },
23
-
24
22
  onChange(e) {
25
23
  e.preventDefault();
26
24
  e.stopPropagation();
@@ -28,39 +26,31 @@ const FormMixin = {
28
26
  bubbles: true
29
27
  }));
30
28
  },
31
-
32
29
  getValue() {
33
30
  if (!this.dataHolder || this.dataHolder.length === 0) return this.value;
34
31
  if (this.dataHolder.length > 1) this.showDataHolderError(1, this.dataHolder.length);
35
32
  return this.getValueFromElement(this.dataHolder[0]);
36
33
  },
37
-
38
34
  get type() {
39
35
  return 'string';
40
36
  },
41
-
42
37
  get multiple() {
43
38
  return false;
44
39
  },
45
-
46
40
  get dataHolder() {
47
41
  const dataHolders = Array.from(this.element.querySelectorAll('[data-holder]'));
48
42
  const widgetDataHolders = dataHolders.filter(element => {
49
- const dataHolderAncestor = element.parentElement ? element.parentElement.closest('[data-holder]') : null; // get the dataHolder of the widget only if no dataHolder ancestor in the current widget
50
-
43
+ const dataHolderAncestor = element.parentElement ? element.parentElement.closest('[data-holder]') : null;
44
+ // get the dataHolder of the widget only if no dataHolder ancestor in the current widget
51
45
  return dataHolderAncestor === this.element || !dataHolderAncestor || !this.element.contains(dataHolderAncestor);
52
46
  });
53
47
  return widgetDataHolders.length ? widgetDataHolders : null;
54
48
  },
55
-
56
49
  getValueFromElement(element) {
57
50
  return element.component ? element.component.getValue() : element.value;
58
51
  },
59
-
60
52
  showDataHolderError(expected, found) {
61
- console.warn("Expected ".concat(expected, " data-holder element in ").concat(this.element.tagName, ". Found ").concat(found));
53
+ console.warn(`Expected ${expected} data-holder element in ${this.element.tagName}. Found ${found}`);
62
54
  }
63
-
64
55
  };
65
- export { FormMixin };
66
- //# sourceMappingURL=formMixin.js.map
56
+ export { FormMixin };
@@ -1,14 +1,10 @@
1
1
  const FormNumberMixin = {
2
2
  name: 'form-number-mixin',
3
-
4
3
  getValueFromElement(element) {
5
4
  return element.value ? Number(element.value) : '';
6
5
  },
7
-
8
6
  get type() {
9
7
  return 'number';
10
8
  }
11
-
12
9
  };
13
- export { FormNumberMixin };
14
- //# sourceMappingURL=formNumberMixin.js.map
10
+ export { FormNumberMixin };
@@ -1,16 +1,12 @@
1
1
  import { uniqID } from '../../libs/helpers.js';
2
2
  const FormRadioMixin = {
3
3
  name: 'form-radio-mixin',
4
-
5
4
  created() {
6
5
  this.listAttributes['id'] = uniqID();
7
6
  },
8
-
9
7
  getValue() {
10
8
  const checkedElement = this.element.querySelector('input[type=radio]:checked');
11
9
  return checkedElement ? checkedElement.value : '';
12
10
  }
13
-
14
11
  };
15
- export { FormRadioMixin };
16
- //# sourceMappingURL=formRadioMixin.js.map
12
+ export { FormRadioMixin };
@@ -9,5 +9,4 @@ const FormStepMixin = {
9
9
  }
10
10
  }
11
11
  };
12
- export { FormStepMixin };
13
- //# sourceMappingURL=formStepMixin.js.map
12
+ export { FormStepMixin };
@@ -0,0 +1,13 @@
1
+ const LinkTextMixin = {
2
+ name: 'link-text-mixin',
3
+ attributes: {
4
+ linkText: {
5
+ type: String,
6
+ default: '',
7
+ callback: function (newValue) {
8
+ this.addToAttributes(newValue, 'linkText');
9
+ }
10
+ }
11
+ }
12
+ };
13
+ export { LinkTextMixin };
@@ -26,39 +26,52 @@ const MultipleFormMixin = {
26
26
  range: {
27
27
  type: String,
28
28
  default: ''
29
+ },
30
+ addClass: {
31
+ type: String,
32
+ default: undefined,
33
+ callback: function (value) {
34
+ if (value !== this.listAttributes['addClass']) this.listAttributes['addClass'] = value;
35
+ this.planRender();
36
+ }
37
+ },
38
+ removeClass: {
39
+ type: String,
40
+ default: undefined,
41
+ callback: function (value) {
42
+ if (value !== this.listAttributes['removeClass']) this.listAttributes['removeClass'] = value;
43
+ this.planRender();
44
+ }
29
45
  }
30
46
  },
31
-
32
47
  created() {
33
48
  this.listValueTransformations.push(this.setDataSrc.bind(this));
34
49
  this.listAttributes['children'] = [];
35
50
  this.listAttributes['addLabel'] = this.addLabel;
36
51
  this.listAttributes['removeLabel'] = this.removeLabel;
37
-
52
+ this.listAttributes['addClass'] = this.addClass;
53
+ this.listAttributes['removeClass'] = this.removeClass;
38
54
  this.listAttributes['addItem'] = () => {
39
55
  this.insertWidget();
40
56
  this.planRender();
41
57
  };
42
-
43
58
  this.listAttributes['removeItem'] = index => {
44
- this.element.querySelector("[data-index=\"".concat(this.name + index, "\"]")).remove();
59
+ this.element.querySelector(`[data-index="${this.name + index}"]`).remove();
45
60
  this.element.dispatchEvent(new Event('change', {
46
61
  bubbles: true
47
62
  }));
48
63
  };
49
64
  },
50
-
51
65
  setDataSrc(value, listValueTransformations) {
52
66
  if (value && value !== this.dataSrc) this.dataSrc = value;
53
67
  const nextProcessor = listValueTransformations.shift();
54
68
  if (nextProcessor) nextProcessor(value, listValueTransformations);
55
69
  },
56
-
57
70
  populate() {
58
71
  if (!this.resource || !this.resource['ldp:contains']) return;
59
72
  this.listAttributes['children'] = []; // reset list
60
- // set value in form
61
73
 
74
+ // set value in form
62
75
  for (let resource of this.resource['ldp:contains']) {
63
76
  // for each resource
64
77
  this.insertWidget(resource['@id']); // create a widget
@@ -66,8 +79,8 @@ const MultipleFormMixin = {
66
79
 
67
80
  this.planRender();
68
81
  },
69
-
70
- insertWidget(value = '') {
82
+ insertWidget() {
83
+ let value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
71
84
  if (!this.widget) return;
72
85
  const widget = document.createElement(this.widget);
73
86
  const attributes = {
@@ -76,32 +89,24 @@ const MultipleFormMixin = {
76
89
  'value': value,
77
90
  'range': this.range
78
91
  };
79
-
80
92
  for (let name of Object.keys(attributes)) {
81
93
  if (typeof attributes[name] === "boolean") widget.toggleAttribute(name, attributes[name]);else widget.setAttribute(name, attributes[name]);
82
94
  }
83
-
84
95
  this.listAttributes['children'].push(widget);
85
96
  },
86
-
87
97
  empty() {
88
98
  this.listAttributes['children'] = [];
89
99
  this.planRender();
90
100
  },
91
-
92
101
  getValue() {
93
102
  if (!this.dataHolder) return [];
94
103
  return Array.from(this.dataHolder).map(element => this.getValueFromElement(element));
95
104
  },
96
-
97
105
  get type() {
98
106
  return 'resource';
99
107
  },
100
-
101
108
  get multiple() {
102
109
  return true;
103
110
  }
104
-
105
111
  };
106
- export { MultipleFormMixin };
107
- //# sourceMappingURL=multipleFormMixin.js.map
112
+ export { MultipleFormMixin };
@@ -34,41 +34,32 @@ const MultipleselectFormMixin = {
34
34
  }
35
35
  }
36
36
  },
37
-
38
37
  created() {
39
38
  this.listValueTransformations.push(this.setDataSrc.bind(this));
40
39
  },
41
-
42
40
  setDataSrc(value, listValueTransformations) {
43
41
  if (value && value !== this.dataSrc) this.dataSrc = value;
44
42
  const nextProcessor = listValueTransformations.shift();
45
43
  if (nextProcessor) nextProcessor(value, listValueTransformations);
46
44
  },
47
-
48
45
  populate() {
49
46
  if (!this.resource || !this.resource['ldp:contains']) return;
50
47
  this.setValue(this.resource['ldp:contains']);
51
48
  this.planRender();
52
49
  },
53
-
54
50
  setValue(values) {
55
51
  // set the values to the dropdown
56
52
  this.listAttributes['values'] = JSON.stringify(values.map(r => r['@id']));
57
53
  },
58
-
59
54
  empty() {
60
55
  this.listAttributes['values'] = [];
61
56
  this.planRender();
62
57
  },
63
-
64
58
  get type() {
65
59
  return this.enum === '' ? 'resource' : 'string';
66
60
  },
67
-
68
61
  get multiple() {
69
62
  return true;
70
63
  }
71
-
72
64
  };
73
- export { MultipleselectFormMixin };
74
- //# sourceMappingURL=multipleselectFormMixin.js.map
65
+ export { MultipleselectFormMixin };
@@ -15,5 +15,4 @@ const PatternMixin = {
15
15
  }
16
16
  }
17
17
  };
18
- export { PatternMixin };
19
- //# sourceMappingURL=patternMixin.js.map
18
+ export { PatternMixin };