@everymatrix/general-input 1.10.2 → 1.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (96) hide show
  1. package/dist/cjs/checkbox-group-input_10.cjs.entry.js +35539 -0
  2. package/dist/cjs/general-input.cjs.entry.js +34 -13
  3. package/dist/cjs/general-input.cjs.js +2 -2
  4. package/dist/cjs/{index-64a5cb7f.js → index-132a0774.js} +119 -6
  5. package/dist/cjs/loader.cjs.js +2 -2
  6. package/dist/cjs/locale.utils-7665b010.js +71 -0
  7. package/dist/cjs/toggle-checkbox-input.cjs.entry.js +85 -0
  8. package/dist/cjs/tooltipIcon-092a795f.js +5 -0
  9. package/dist/collection/collection-manifest.json +3 -1
  10. package/dist/collection/components/checkbox-group-input/checkbox-group-input.css +62 -0
  11. package/dist/collection/components/checkbox-group-input/checkbox-group-input.js +366 -0
  12. package/dist/collection/components/checkbox-input/checkbox-input.css +47 -1
  13. package/dist/collection/components/checkbox-input/checkbox-input.js +143 -16
  14. package/dist/collection/components/date-input/date-input.css +64 -30
  15. package/dist/collection/components/date-input/date-input.js +194 -13
  16. package/dist/collection/components/email-input/email-input.css +63 -28
  17. package/dist/collection/components/email-input/email-input.js +197 -21
  18. package/dist/collection/components/general-input/general-input.js +163 -21
  19. package/dist/collection/components/number-input/number-input.css +65 -30
  20. package/dist/collection/components/number-input/number-input.js +174 -19
  21. package/dist/collection/components/password-input/password-input.css +120 -29
  22. package/dist/collection/components/password-input/password-input.js +341 -25
  23. package/dist/collection/components/radio-input/radio-input.css +22 -1
  24. package/dist/collection/components/radio-input/radio-input.js +89 -10
  25. package/dist/collection/components/select-input/select-input.css +75 -22
  26. package/dist/collection/components/select-input/select-input.js +180 -37
  27. package/dist/collection/components/tel-input/tel-input.css +91 -33
  28. package/dist/collection/components/tel-input/tel-input.js +202 -24
  29. package/dist/collection/components/text-input/text-input.css +63 -28
  30. package/dist/collection/components/text-input/text-input.js +208 -39
  31. package/dist/collection/components/toggle-checkbox-input/toggle-checkbox-input.css +76 -0
  32. package/dist/collection/components/toggle-checkbox-input/toggle-checkbox-input.js +324 -0
  33. package/dist/collection/utils/locale.utils.js +52 -13
  34. package/dist/collection/utils/tooltipIcon.svg +5 -0
  35. package/dist/components/active-mixin.js +975 -0
  36. package/dist/components/checkbox-group-input.d.ts +11 -0
  37. package/dist/components/checkbox-group-input.js +6 -0
  38. package/dist/components/checkbox-group-input2.js +1125 -0
  39. package/dist/components/checkbox-input2.js +62 -12
  40. package/dist/components/date-input2.js +10247 -15
  41. package/dist/components/email-input2.js +98 -21
  42. package/dist/components/field-mixin.js +12712 -0
  43. package/dist/components/general-input.js +1 -118
  44. package/dist/components/general-input2.js +331 -0
  45. package/dist/components/input-field-shared-styles.js +1114 -0
  46. package/dist/components/number-input2.js +92 -16
  47. package/dist/components/password-input2.js +924 -24
  48. package/dist/components/pattern-mixin.js +85 -0
  49. package/dist/components/radio-input2.js +45 -11
  50. package/dist/components/select-input2.js +87 -27
  51. package/dist/components/tel-input2.js +122 -22
  52. package/dist/components/text-input2.js +120 -34
  53. package/dist/components/toggle-checkbox-input.d.ts +11 -0
  54. package/dist/components/toggle-checkbox-input.js +6 -0
  55. package/dist/components/tooltipIcon.js +70 -0
  56. package/dist/components/vaadin-button.js +461 -0
  57. package/dist/components/vaadin-combo-box.js +4329 -0
  58. package/dist/components/virtual-keyboard-controller.js +2658 -0
  59. package/dist/esm/checkbox-group-input_10.entry.js +35526 -0
  60. package/dist/esm/general-input.entry.js +34 -13
  61. package/dist/esm/general-input.js +2 -2
  62. package/dist/esm/{index-df80f936.js → index-db76d5b5.js} +118 -7
  63. package/dist/esm/loader.js +2 -2
  64. package/dist/esm/locale.utils-95ea2605.js +68 -0
  65. package/dist/esm/toggle-checkbox-input.entry.js +81 -0
  66. package/dist/esm/tooltipIcon-99c1c7b7.js +3 -0
  67. package/dist/general-input/general-input.esm.js +1 -1
  68. package/dist/general-input/p-0966f523.entry.js +3581 -0
  69. package/dist/general-input/p-916a1319.entry.js +1 -0
  70. package/dist/general-input/p-b408093e.js +1 -0
  71. package/dist/general-input/p-c2d4d6ac.entry.js +1 -0
  72. package/dist/general-input/p-f4f4ccda.js +1 -0
  73. package/dist/general-input/p-f6132f1d.js +1 -0
  74. package/dist/types/components/checkbox-group-input/checkbox-group-input.d.ts +74 -0
  75. package/dist/types/components/checkbox-input/checkbox-input.d.ts +28 -2
  76. package/dist/types/components/date-input/date-input.d.ts +43 -1
  77. package/dist/types/components/email-input/email-input.d.ts +37 -3
  78. package/dist/types/components/general-input/general-input.d.ts +30 -0
  79. package/dist/types/components/number-input/number-input.d.ts +34 -3
  80. package/dist/types/components/password-input/password-input.d.ts +56 -7
  81. package/dist/types/components/radio-input/radio-input.d.ts +17 -1
  82. package/dist/types/components/select-input/select-input.d.ts +36 -3
  83. package/dist/types/components/tel-input/tel-input.d.ts +40 -5
  84. package/dist/types/components/text-input/text-input.d.ts +84 -0
  85. package/dist/types/components/toggle-checkbox-input/toggle-checkbox-input.d.ts +67 -0
  86. package/dist/types/components.d.ts +568 -9
  87. package/dist/types/utils/locale.utils.d.ts +9 -0
  88. package/dist/types/utils/types.d.ts +41 -9
  89. package/package.json +8 -1
  90. package/dist/cjs/checkbox-input_9.cjs.entry.js +0 -623
  91. package/dist/components/locale.utils.js +0 -29
  92. package/dist/esm/checkbox-input_9.entry.js +0 -611
  93. package/dist/general-input/p-1703fce3.entry.js +0 -1
  94. package/dist/general-input/p-d9f7fa2e.js +0 -1
  95. package/dist/general-input/p-dea0a4ac.entry.js +0 -1
  96. /package/dist/types/Users/{user/workspace/everymatrix → adrian.pripon/Documents/Work}/widgets-stencil/packages/general-input/.stencil/packages/general-input/stencil.config.d.ts +0 -0
@@ -1,121 +1,4 @@
1
- import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
2
- import { d as defineCustomElement$a } from './checkbox-input2.js';
3
- import { d as defineCustomElement$9 } from './date-input2.js';
4
- import { d as defineCustomElement$8 } from './email-input2.js';
5
- import { d as defineCustomElement$7 } from './number-input2.js';
6
- import { d as defineCustomElement$6 } from './password-input2.js';
7
- import { d as defineCustomElement$5 } from './radio-input2.js';
8
- import { d as defineCustomElement$4 } from './select-input2.js';
9
- import { d as defineCustomElement$3 } from './tel-input2.js';
10
- import { d as defineCustomElement$2 } from './text-input2.js';
11
-
12
- const generalInputCss = ":host{display:block}";
13
-
14
- const GeneralInput$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
15
- constructor() {
16
- super();
17
- this.__registerHost();
18
- this.__attachShadow();
19
- /**
20
- * Type the general-input should take. Can take the default HTML input values.
21
- */
22
- this.type = 'text';
23
- }
24
- render() {
25
- switch (this.type.toLowerCase()) {
26
- case 'text':
27
- return h("text-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, emitValue: this.emitValue, language: this.language });
28
- case 'email':
29
- return h("email-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, emitValue: this.emitValue, language: this.language });
30
- case 'number':
31
- return h("number-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, emitValue: this.emitValue, language: this.language });
32
- case 'checkbox':
33
- return h("checkbox-input", { name: this.name, displayName: this.displayName, validation: this.validation, emitValue: this.emitValue, language: this.language });
34
- case 'datetime':
35
- return h("date-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, emitValue: this.emitValue, language: this.language });
36
- case 'password':
37
- return h("password-input", { name: this.name, displayName: this.displayName, validation: this.validation, emitValue: this.emitValue, language: this.language });
38
- case 'radio':
39
- return h("radio-input", { name: this.name, displayName: this.displayName, optionsGroup: this.options, validation: this.validation, emitValue: this.emitValue, language: this.language });
40
- case 'tel':
41
- return h("tel-input", { name: this.name, action: this.action, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, emitValue: this.emitValue, language: this.language });
42
- case 'dropdown':
43
- return h("select-input", { name: this.name, action: this.action, displayName: this.displayName, options: this.options, validation: this.validation, emitValue: this.emitValue, language: this.language });
44
- default:
45
- // Nothing here
46
- return h("p", null, "The ", this.type, " input type is not valid");
47
- }
48
- }
49
- static get style() { return generalInputCss; }
50
- }, [1, "general-input", {
51
- "type": [1],
52
- "name": [1],
53
- "displayName": [1, "display-name"],
54
- "action": [1],
55
- "validation": [16],
56
- "options": [8],
57
- "language": [1],
58
- "defaultValue": [8, "default-value"],
59
- "emitValue": [4, "emit-value"]
60
- }]);
61
- function defineCustomElement$1() {
62
- if (typeof customElements === "undefined") {
63
- return;
64
- }
65
- const components = ["general-input", "checkbox-input", "date-input", "email-input", "number-input", "password-input", "radio-input", "select-input", "tel-input", "text-input"];
66
- components.forEach(tagName => { switch (tagName) {
67
- case "general-input":
68
- if (!customElements.get(tagName)) {
69
- customElements.define(tagName, GeneralInput$1);
70
- }
71
- break;
72
- case "checkbox-input":
73
- if (!customElements.get(tagName)) {
74
- defineCustomElement$a();
75
- }
76
- break;
77
- case "date-input":
78
- if (!customElements.get(tagName)) {
79
- defineCustomElement$9();
80
- }
81
- break;
82
- case "email-input":
83
- if (!customElements.get(tagName)) {
84
- defineCustomElement$8();
85
- }
86
- break;
87
- case "number-input":
88
- if (!customElements.get(tagName)) {
89
- defineCustomElement$7();
90
- }
91
- break;
92
- case "password-input":
93
- if (!customElements.get(tagName)) {
94
- defineCustomElement$6();
95
- }
96
- break;
97
- case "radio-input":
98
- if (!customElements.get(tagName)) {
99
- defineCustomElement$5();
100
- }
101
- break;
102
- case "select-input":
103
- if (!customElements.get(tagName)) {
104
- defineCustomElement$4();
105
- }
106
- break;
107
- case "tel-input":
108
- if (!customElements.get(tagName)) {
109
- defineCustomElement$3();
110
- }
111
- break;
112
- case "text-input":
113
- if (!customElements.get(tagName)) {
114
- defineCustomElement$2();
115
- }
116
- break;
117
- } });
118
- }
1
+ import { G as GeneralInput$1, d as defineCustomElement$1 } from './general-input2.js';
119
2
 
120
3
  const GeneralInput = GeneralInput$1;
121
4
  const defineCustomElement = defineCustomElement$1;
@@ -0,0 +1,331 @@
1
+ import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
2
+ import { t as translate, a as tooltipIconSvg, g as getTranslations } from './tooltipIcon.js';
3
+ import { d as defineCustomElement$b } from './checkbox-group-input2.js';
4
+ import { d as defineCustomElement$a } from './checkbox-input2.js';
5
+ import { d as defineCustomElement$9 } from './date-input2.js';
6
+ import { d as defineCustomElement$8 } from './email-input2.js';
7
+ import { d as defineCustomElement$7 } from './number-input2.js';
8
+ import { d as defineCustomElement$6 } from './password-input2.js';
9
+ import { d as defineCustomElement$5 } from './radio-input2.js';
10
+ import { d as defineCustomElement$4 } from './select-input2.js';
11
+ import { d as defineCustomElement$3 } from './tel-input2.js';
12
+ import { d as defineCustomElement$2 } from './text-input2.js';
13
+
14
+ const toggleCheckboxInputCss = "*,*::before,*::after{padding:0;margin:0;box-sizing:border-box}.togglecheckbox{font-family:\"Roboto\";font-style:normal;font-size:15px}.togglecheckbox__wrapper{position:relative}.togglecheckbox__wrapper--flex{display:flex;gap:5px;align-content:flex-start}.togglecheckbox__wrapper--relative{position:relative;display:inline}.togglecheckbox__input{transform:scale(1.307, 1.307);margin-left:2px}.togglecheckbox__label{font-style:inherit;font-family:inherit;font-weight:400;font-size:16px;color:#2B2D3F;line-height:14px}.togglecheckbox__label-text{font-size:16px}.togglecheckbox__error-message{position:absolute;top:calc(100% + 5px);left:0;color:#cc0000b3}.togglecheckbox__tooltip-icon{width:16px;height:auto}.togglecheckbox__tooltip{position:absolute;top:0;right:0;background-color:#FFFFFF;border:1px solid #B0B0B0;color:#2B2D3F;padding:10px;border-radius:5px;opacity:0;transition:opacity 0.3s ease-in-out;z-index:10}.togglecheckbox__tooltip.visible{opacity:1}.togglecheckbox__fields-wrapper{margin-top:40px;display:flex;flex-direction:column;gap:40px}.hidden{display:none}";
15
+
16
+ const ToggleCheckboxInput = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
17
+ constructor() {
18
+ super();
19
+ this.__registerHost();
20
+ this.__attachShadow();
21
+ this.sendValidityState = createEvent(this, "sendValidityState", 7);
22
+ this.sendInputValue = createEvent(this, "sendInputValue", 7);
23
+ /**
24
+ * Default value for the input.
25
+ */
26
+ this.defaultValue = '';
27
+ /**
28
+ * Client custom styling via inline style
29
+ */
30
+ this.clientStyling = '';
31
+ this.limitStylingAppends = false;
32
+ this.showTooltip = false;
33
+ this.value = '';
34
+ this.setClientStyling = () => {
35
+ let sheet = document.createElement('style');
36
+ sheet.innerHTML = this.clientStyling;
37
+ this.stylingContainer.prepend(sheet);
38
+ };
39
+ }
40
+ validityStateHandler(inputStateEvent) {
41
+ this.sendValidityState.emit(inputStateEvent);
42
+ }
43
+ valueHandler(inputValueEvent) {
44
+ this.sendInputValue.emit(inputValueEvent);
45
+ }
46
+ handleClickOutside(event) {
47
+ if (event.composedPath()[0] === this.tooltipIconReference)
48
+ return;
49
+ if (event.composedPath()[0] !== this.tooltipReference)
50
+ this.showTooltip = false;
51
+ }
52
+ componentDidRender() {
53
+ // start custom styling area
54
+ if (!this.limitStylingAppends && this.stylingContainer) {
55
+ if (this.clientStyling)
56
+ this.setClientStyling();
57
+ this.limitStylingAppends = true;
58
+ }
59
+ // end custom styling area
60
+ }
61
+ handleClick() {
62
+ this.showFields = this.checkboxReference.checked;
63
+ this.errorMessage = this.setErrorMessage();
64
+ this.isValid = this.setValidity();
65
+ }
66
+ setValidity() {
67
+ return this.checkboxReference.validity.valid;
68
+ }
69
+ setErrorMessage() {
70
+ if (this.checkboxReference.validity.valueMissing) {
71
+ return translate('requiredError', this.language);
72
+ }
73
+ }
74
+ renderLabel() {
75
+ return (h("label", { class: 'togglecheckbox__label', htmlFor: `${this.name}__input` }, h("div", { class: 'togglecheckbox__label-text', innerHTML: `${this.displayName} ${this.validation.mandatory ? '*' : ''}` })));
76
+ }
77
+ renderTooltip() {
78
+ if (this.showTooltip) {
79
+ return (h("div", { class: `togglecheckbox__tooltip ${this.showTooltip ? 'visible' : ''}`, ref: (el) => this.tooltipReference = el, innerHTML: this.tooltip }));
80
+ }
81
+ return null;
82
+ }
83
+ render() {
84
+ return h("div", { class: `togglecheckbox__wrapper ${this.name}__input`, ref: el => this.stylingContainer = el }, h("div", { class: 'togglecheckbox__wrapper--flex' }, h("input", { class: 'togglecheckbox__input', type: "checkbox", id: `${this.name}__input`, ref: (el) => this.checkboxReference = el, name: this.name, checked: this.defaultValue === "true", readOnly: this.autofilled, required: this.validation.mandatory, value: this.value, onClick: () => this.handleClick() }), this.renderLabel()), h("small", { class: 'togglecheckbox__error-message' }, this.errorMessage), h("div", { class: 'togglecheckbox__wrapper--relative' }, this.tooltip &&
85
+ h("img", { class: 'togglecheckbox__tooltip-icon', src: tooltipIconSvg, alt: "", ref: (el) => this.tooltipIconReference = el, onClick: () => this.showTooltip = !this.showTooltip }), this.renderTooltip()), h("div", { class: `togglecheckbox__fields-wrapper ${this.showFields ? '' : 'hidden'}` }, this.options.map(subfield => {
86
+ return h("general-input", { type: subfield.inputType, name: subfield.name, displayName: subfield.displayName, validation: subfield.validate, action: subfield.action || null, defaultValue: subfield.defaultValue, autofilled: subfield.autofill, emitValue: this.emitValue, language: this.language, "client-styling": this.clientStyling, tooltip: subfield.tooltip, placeholder: subfield.placeholder == null ? '' : subfield.placeholder });
87
+ })));
88
+ }
89
+ static get style() { return toggleCheckboxInputCss; }
90
+ }, [1, "toggle-checkbox-input", {
91
+ "name": [513],
92
+ "displayName": [513, "display-name"],
93
+ "defaultValue": [513, "default-value"],
94
+ "options": [16],
95
+ "autofilled": [516],
96
+ "tooltip": [513],
97
+ "validation": [16],
98
+ "language": [513],
99
+ "emitValue": [516, "emit-value"],
100
+ "clientStyling": [513, "client-styling"],
101
+ "errorMessage": [32],
102
+ "isValid": [32],
103
+ "limitStylingAppends": [32],
104
+ "showTooltip": [32],
105
+ "showFields": [32]
106
+ }, [[4, "click", "handleClickOutside"]]]);
107
+ function defineCustomElement$1() {
108
+ if (typeof customElements === "undefined") {
109
+ return;
110
+ }
111
+ const components = ["toggle-checkbox-input", "checkbox-group-input", "checkbox-input", "date-input", "email-input", "general-input", "number-input", "password-input", "radio-input", "select-input", "tel-input", "text-input", "toggle-checkbox-input"];
112
+ components.forEach(tagName => { switch (tagName) {
113
+ case "toggle-checkbox-input":
114
+ if (!customElements.get(tagName)) {
115
+ customElements.define(tagName, ToggleCheckboxInput);
116
+ }
117
+ break;
118
+ case "checkbox-group-input":
119
+ if (!customElements.get(tagName)) {
120
+ defineCustomElement$b();
121
+ }
122
+ break;
123
+ case "checkbox-input":
124
+ if (!customElements.get(tagName)) {
125
+ defineCustomElement$a();
126
+ }
127
+ break;
128
+ case "date-input":
129
+ if (!customElements.get(tagName)) {
130
+ defineCustomElement$9();
131
+ }
132
+ break;
133
+ case "email-input":
134
+ if (!customElements.get(tagName)) {
135
+ defineCustomElement$8();
136
+ }
137
+ break;
138
+ case "general-input":
139
+ if (!customElements.get(tagName)) {
140
+ defineCustomElement();
141
+ }
142
+ break;
143
+ case "number-input":
144
+ if (!customElements.get(tagName)) {
145
+ defineCustomElement$7();
146
+ }
147
+ break;
148
+ case "password-input":
149
+ if (!customElements.get(tagName)) {
150
+ defineCustomElement$6();
151
+ }
152
+ break;
153
+ case "radio-input":
154
+ if (!customElements.get(tagName)) {
155
+ defineCustomElement$5();
156
+ }
157
+ break;
158
+ case "select-input":
159
+ if (!customElements.get(tagName)) {
160
+ defineCustomElement$4();
161
+ }
162
+ break;
163
+ case "tel-input":
164
+ if (!customElements.get(tagName)) {
165
+ defineCustomElement$3();
166
+ }
167
+ break;
168
+ case "text-input":
169
+ if (!customElements.get(tagName)) {
170
+ defineCustomElement$2();
171
+ }
172
+ break;
173
+ case "toggle-checkbox-input":
174
+ if (!customElements.get(tagName)) {
175
+ defineCustomElement$1();
176
+ }
177
+ break;
178
+ } });
179
+ }
180
+
181
+ const generalInputCss = ":host{display:block}";
182
+
183
+ const GeneralInput = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
184
+ constructor() {
185
+ super();
186
+ this.__registerHost();
187
+ this.__attachShadow();
188
+ /**
189
+ * Type the general-input should take. Can take the default HTML input values.
190
+ */
191
+ this.type = 'text';
192
+ /**
193
+ * Client custom styling via inline style
194
+ */
195
+ this.clientStyling = '';
196
+ /**
197
+ * Translations via URL
198
+ */
199
+ this.translationUrl = '';
200
+ }
201
+ connectedCallback() {
202
+ if (this.translationUrl) {
203
+ getTranslations(this.translationUrl);
204
+ }
205
+ }
206
+ renderInput() {
207
+ var _a;
208
+ switch ((_a = this.type) === null || _a === void 0 ? void 0 : _a.toLowerCase()) {
209
+ case 'text':
210
+ return h("text-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, autofilled: this.autofilled, emitValue: this.emitValue, language: this.language, isDuplicateInput: this.isDuplicateInput, "client-styling": this.clientStyling, tooltip: this.tooltip, placeholder: this.placeholder });
211
+ case 'email':
212
+ return h("email-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, autofilled: this.autofilled, emitValue: this.emitValue, language: this.language, isDuplicateInput: this.isDuplicateInput, "client-styling": this.clientStyling, tooltip: this.tooltip, placeholder: this.placeholder });
213
+ case 'number':
214
+ return h("number-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, autofilled: this.autofilled, emitValue: this.emitValue, language: this.language, "client-styling": this.clientStyling, tooltip: this.tooltip, placeholder: this.placeholder });
215
+ case 'checkbox':
216
+ return h("checkbox-input", { name: this.name, displayName: this.displayName, validation: this.validation, emitValue: this.emitValue, defaultValue: this.defaultValue, autofilled: this.autofilled, language: this.language, "client-styling": this.clientStyling, tooltip: this.tooltip });
217
+ case 'checkboxgroup':
218
+ return h("checkbox-group-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, autofilled: this.autofilled, emitValue: this.emitValue, language: this.language, "client-styling": this.clientStyling, tooltip: this.tooltip, options: this.options });
219
+ case 'togglecheckbox':
220
+ return h("toggle-checkbox-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, autofilled: this.autofilled, emitValue: this.emitValue, language: this.language, "client-styling": this.clientStyling, tooltip: this.tooltip, options: this.options });
221
+ case 'datetime':
222
+ return h("date-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, autofilled: this.autofilled, emitValue: this.emitValue, language: this.language, "client-styling": this.clientStyling, tooltip: this.tooltip, placeholder: this.placeholder, dateFormat: this.dateFormat });
223
+ case 'password':
224
+ return h("password-input", { name: this.name, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, autofilled: this.autofilled, emitValue: this.emitValue, language: this.language, isDuplicateInput: this.isDuplicateInput, "client-styling": this.clientStyling, tooltip: this.tooltip, placeholder: this.placeholder });
225
+ case 'radio':
226
+ return h("radio-input", { name: this.name, displayName: this.displayName, optionsGroup: this.options, validation: this.validation, emitValue: this.emitValue, language: this.language, "client-styling": this.clientStyling });
227
+ case 'tel':
228
+ return h("tel-input", { name: this.name, action: this.action, displayName: this.displayName, validation: this.validation, defaultValue: this.defaultValue, emitValue: this.emitValue, language: this.language, autofilled: this.autofilled, "client-styling": this.clientStyling, tooltip: this.tooltip, placeholder: this.placeholder });
229
+ case 'dropdown':
230
+ return h("select-input", { name: this.name, action: this.action, defaultValue: this.defaultValue, displayName: this.displayName, options: this.options, validation: this.validation, emitValue: this.emitValue, autofilled: this.autofilled, language: this.language, "client-styling": this.clientStyling, tooltip: this.tooltip, placeholder: this.placeholder });
231
+ default:
232
+ return h("p", null, "The ", this.type, " input type is not valid");
233
+ }
234
+ }
235
+ render() {
236
+ return (h(Host, { class: `general-input--${this.name}` }, this.renderInput()));
237
+ }
238
+ static get style() { return generalInputCss; }
239
+ }, [1, "general-input", {
240
+ "type": [513],
241
+ "name": [513],
242
+ "displayName": [513, "display-name"],
243
+ "placeholder": [513],
244
+ "action": [513],
245
+ "validation": [16],
246
+ "options": [520],
247
+ "language": [513],
248
+ "autofilled": [516],
249
+ "tooltip": [513],
250
+ "defaultValue": [520, "default-value"],
251
+ "emitValue": [516, "emit-value"],
252
+ "isDuplicateInput": [516, "is-duplicate-input"],
253
+ "clientStyling": [520, "client-styling"],
254
+ "dateFormat": [513, "date-format"],
255
+ "translationUrl": [513, "translation-url"]
256
+ }]);
257
+ function defineCustomElement() {
258
+ if (typeof customElements === "undefined") {
259
+ return;
260
+ }
261
+ const components = ["general-input", "checkbox-group-input", "checkbox-input", "date-input", "email-input", "general-input", "number-input", "password-input", "radio-input", "select-input", "tel-input", "text-input", "toggle-checkbox-input"];
262
+ components.forEach(tagName => { switch (tagName) {
263
+ case "general-input":
264
+ if (!customElements.get(tagName)) {
265
+ customElements.define(tagName, GeneralInput);
266
+ }
267
+ break;
268
+ case "checkbox-group-input":
269
+ if (!customElements.get(tagName)) {
270
+ defineCustomElement$b();
271
+ }
272
+ break;
273
+ case "checkbox-input":
274
+ if (!customElements.get(tagName)) {
275
+ defineCustomElement$a();
276
+ }
277
+ break;
278
+ case "date-input":
279
+ if (!customElements.get(tagName)) {
280
+ defineCustomElement$9();
281
+ }
282
+ break;
283
+ case "email-input":
284
+ if (!customElements.get(tagName)) {
285
+ defineCustomElement$8();
286
+ }
287
+ break;
288
+ case "general-input":
289
+ if (!customElements.get(tagName)) {
290
+ defineCustomElement();
291
+ }
292
+ break;
293
+ case "number-input":
294
+ if (!customElements.get(tagName)) {
295
+ defineCustomElement$7();
296
+ }
297
+ break;
298
+ case "password-input":
299
+ if (!customElements.get(tagName)) {
300
+ defineCustomElement$6();
301
+ }
302
+ break;
303
+ case "radio-input":
304
+ if (!customElements.get(tagName)) {
305
+ defineCustomElement$5();
306
+ }
307
+ break;
308
+ case "select-input":
309
+ if (!customElements.get(tagName)) {
310
+ defineCustomElement$4();
311
+ }
312
+ break;
313
+ case "tel-input":
314
+ if (!customElements.get(tagName)) {
315
+ defineCustomElement$3();
316
+ }
317
+ break;
318
+ case "text-input":
319
+ if (!customElements.get(tagName)) {
320
+ defineCustomElement$2();
321
+ }
322
+ break;
323
+ case "toggle-checkbox-input":
324
+ if (!customElements.get(tagName)) {
325
+ defineCustomElement$1();
326
+ }
327
+ break;
328
+ } });
329
+ }
330
+
331
+ export { GeneralInput as G, ToggleCheckboxInput as T, defineCustomElement$1 as a, defineCustomElement as d };