@josercl/form-maker 1.0.0-alpha19 → 1.1.0-beta01
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.
- package/index.js +11 -11
- package/lib/components/FormMaker.vue +1 -1
- package/lib/components/inputs/SelectInput.vue +3 -3
- package/package.json +16 -23
- package/umd/index.umd.js +1 -1097
- package/commonjs/index.common.js +0 -1087
- package/umd/index.umd.min.js +0 -1
package/umd/index.umd.js
CHANGED
|
@@ -1,1097 +1 @@
|
|
|
1
|
-
(function webpackUniversalModuleDefinition(root, factory) {
|
|
2
|
-
if(typeof exports === 'object' && typeof module === 'object')
|
|
3
|
-
module.exports = factory(require("vue"));
|
|
4
|
-
else if(typeof define === 'function' && define.amd)
|
|
5
|
-
define([], factory);
|
|
6
|
-
else if(typeof exports === 'object')
|
|
7
|
-
exports["FormMaker"] = factory(require("vue"));
|
|
8
|
-
else
|
|
9
|
-
root["FormMaker"] = factory(root["Vue"]);
|
|
10
|
-
})((typeof self !== 'undefined' ? self : this), function(__WEBPACK_EXTERNAL_MODULE__8bbf__) {
|
|
11
|
-
return /******/ (function(modules) { // webpackBootstrap
|
|
12
|
-
/******/ // The module cache
|
|
13
|
-
/******/ var installedModules = {};
|
|
14
|
-
/******/
|
|
15
|
-
/******/ // The require function
|
|
16
|
-
/******/ function __webpack_require__(moduleId) {
|
|
17
|
-
/******/
|
|
18
|
-
/******/ // Check if module is in cache
|
|
19
|
-
/******/ if(installedModules[moduleId]) {
|
|
20
|
-
/******/ return installedModules[moduleId].exports;
|
|
21
|
-
/******/ }
|
|
22
|
-
/******/ // Create a new module (and put it into the cache)
|
|
23
|
-
/******/ var module = installedModules[moduleId] = {
|
|
24
|
-
/******/ i: moduleId,
|
|
25
|
-
/******/ l: false,
|
|
26
|
-
/******/ exports: {}
|
|
27
|
-
/******/ };
|
|
28
|
-
/******/
|
|
29
|
-
/******/ // Execute the module function
|
|
30
|
-
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
|
31
|
-
/******/
|
|
32
|
-
/******/ // Flag the module as loaded
|
|
33
|
-
/******/ module.l = true;
|
|
34
|
-
/******/
|
|
35
|
-
/******/ // Return the exports of the module
|
|
36
|
-
/******/ return module.exports;
|
|
37
|
-
/******/ }
|
|
38
|
-
/******/
|
|
39
|
-
/******/
|
|
40
|
-
/******/ // expose the modules object (__webpack_modules__)
|
|
41
|
-
/******/ __webpack_require__.m = modules;
|
|
42
|
-
/******/
|
|
43
|
-
/******/ // expose the module cache
|
|
44
|
-
/******/ __webpack_require__.c = installedModules;
|
|
45
|
-
/******/
|
|
46
|
-
/******/ // define getter function for harmony exports
|
|
47
|
-
/******/ __webpack_require__.d = function(exports, name, getter) {
|
|
48
|
-
/******/ if(!__webpack_require__.o(exports, name)) {
|
|
49
|
-
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
|
|
50
|
-
/******/ }
|
|
51
|
-
/******/ };
|
|
52
|
-
/******/
|
|
53
|
-
/******/ // define __esModule on exports
|
|
54
|
-
/******/ __webpack_require__.r = function(exports) {
|
|
55
|
-
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
|
56
|
-
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
57
|
-
/******/ }
|
|
58
|
-
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
|
59
|
-
/******/ };
|
|
60
|
-
/******/
|
|
61
|
-
/******/ // create a fake namespace object
|
|
62
|
-
/******/ // mode & 1: value is a module id, require it
|
|
63
|
-
/******/ // mode & 2: merge all properties of value into the ns
|
|
64
|
-
/******/ // mode & 4: return value when already ns object
|
|
65
|
-
/******/ // mode & 8|1: behave like require
|
|
66
|
-
/******/ __webpack_require__.t = function(value, mode) {
|
|
67
|
-
/******/ if(mode & 1) value = __webpack_require__(value);
|
|
68
|
-
/******/ if(mode & 8) return value;
|
|
69
|
-
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
|
|
70
|
-
/******/ var ns = Object.create(null);
|
|
71
|
-
/******/ __webpack_require__.r(ns);
|
|
72
|
-
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
|
|
73
|
-
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
|
|
74
|
-
/******/ return ns;
|
|
75
|
-
/******/ };
|
|
76
|
-
/******/
|
|
77
|
-
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
|
78
|
-
/******/ __webpack_require__.n = function(module) {
|
|
79
|
-
/******/ var getter = module && module.__esModule ?
|
|
80
|
-
/******/ function getDefault() { return module['default']; } :
|
|
81
|
-
/******/ function getModuleExports() { return module; };
|
|
82
|
-
/******/ __webpack_require__.d(getter, 'a', getter);
|
|
83
|
-
/******/ return getter;
|
|
84
|
-
/******/ };
|
|
85
|
-
/******/
|
|
86
|
-
/******/ // Object.prototype.hasOwnProperty.call
|
|
87
|
-
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
|
88
|
-
/******/
|
|
89
|
-
/******/ // __webpack_public_path__
|
|
90
|
-
/******/ __webpack_require__.p = "";
|
|
91
|
-
/******/
|
|
92
|
-
/******/
|
|
93
|
-
/******/ // Load entry module and return exports
|
|
94
|
-
/******/ return __webpack_require__(__webpack_require__.s = "fb15");
|
|
95
|
-
/******/ })
|
|
96
|
-
/************************************************************************/
|
|
97
|
-
/******/ ({
|
|
98
|
-
|
|
99
|
-
/***/ "8875":
|
|
100
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
101
|
-
|
|
102
|
-
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// addapted from the document.currentScript polyfill by Adam Miller
|
|
103
|
-
// MIT license
|
|
104
|
-
// source: https://github.com/amiller-gh/currentScript-polyfill
|
|
105
|
-
|
|
106
|
-
// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505
|
|
107
|
-
|
|
108
|
-
(function (root, factory) {
|
|
109
|
-
if (true) {
|
|
110
|
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
|
|
111
|
-
__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
|
|
112
|
-
(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
|
|
113
|
-
__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
|
114
|
-
} else {}
|
|
115
|
-
}(typeof self !== 'undefined' ? self : this, function () {
|
|
116
|
-
function getCurrentScript () {
|
|
117
|
-
var descriptor = Object.getOwnPropertyDescriptor(document, 'currentScript')
|
|
118
|
-
// for chrome
|
|
119
|
-
if (!descriptor && 'currentScript' in document && document.currentScript) {
|
|
120
|
-
return document.currentScript
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
// for other browsers with native support for currentScript
|
|
124
|
-
if (descriptor && descriptor.get !== getCurrentScript && document.currentScript) {
|
|
125
|
-
return document.currentScript
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
// IE 8-10 support script readyState
|
|
129
|
-
// IE 11+ & Firefox support stack trace
|
|
130
|
-
try {
|
|
131
|
-
throw new Error();
|
|
132
|
-
}
|
|
133
|
-
catch (err) {
|
|
134
|
-
// Find the second match for the "at" string to get file src url from stack.
|
|
135
|
-
var ieStackRegExp = /.*at [^(]*\((.*):(.+):(.+)\)$/ig,
|
|
136
|
-
ffStackRegExp = /@([^@]*):(\d+):(\d+)\s*$/ig,
|
|
137
|
-
stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),
|
|
138
|
-
scriptLocation = (stackDetails && stackDetails[1]) || false,
|
|
139
|
-
line = (stackDetails && stackDetails[2]) || false,
|
|
140
|
-
currentLocation = document.location.href.replace(document.location.hash, ''),
|
|
141
|
-
pageSource,
|
|
142
|
-
inlineScriptSourceRegExp,
|
|
143
|
-
inlineScriptSource,
|
|
144
|
-
scripts = document.getElementsByTagName('script'); // Live NodeList collection
|
|
145
|
-
|
|
146
|
-
if (scriptLocation === currentLocation) {
|
|
147
|
-
pageSource = document.documentElement.outerHTML;
|
|
148
|
-
inlineScriptSourceRegExp = new RegExp('(?:[^\\n]+?\\n){0,' + (line - 2) + '}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*', 'i');
|
|
149
|
-
inlineScriptSource = pageSource.replace(inlineScriptSourceRegExp, '$1').trim();
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
for (var i = 0; i < scripts.length; i++) {
|
|
153
|
-
// If ready state is interactive, return the script tag
|
|
154
|
-
if (scripts[i].readyState === 'interactive') {
|
|
155
|
-
return scripts[i];
|
|
156
|
-
}
|
|
157
|
-
|
|
158
|
-
// If src matches, return the script tag
|
|
159
|
-
if (scripts[i].src === scriptLocation) {
|
|
160
|
-
return scripts[i];
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
// If inline source matches, return the script tag
|
|
164
|
-
if (
|
|
165
|
-
scriptLocation === currentLocation &&
|
|
166
|
-
scripts[i].innerHTML &&
|
|
167
|
-
scripts[i].innerHTML.trim() === inlineScriptSource
|
|
168
|
-
) {
|
|
169
|
-
return scripts[i];
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
// If no match, return null
|
|
174
|
-
return null;
|
|
175
|
-
}
|
|
176
|
-
};
|
|
177
|
-
|
|
178
|
-
return getCurrentScript
|
|
179
|
-
}));
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
/***/ }),
|
|
183
|
-
|
|
184
|
-
/***/ "8bbf":
|
|
185
|
-
/***/ (function(module, exports) {
|
|
186
|
-
|
|
187
|
-
module.exports = __WEBPACK_EXTERNAL_MODULE__8bbf__;
|
|
188
|
-
|
|
189
|
-
/***/ }),
|
|
190
|
-
|
|
191
|
-
/***/ "fb15":
|
|
192
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
193
|
-
|
|
194
|
-
"use strict";
|
|
195
|
-
// ESM COMPAT FLAG
|
|
196
|
-
__webpack_require__.r(__webpack_exports__);
|
|
197
|
-
|
|
198
|
-
// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
|
|
199
|
-
// This file is imported into lib/wc client bundles.
|
|
200
|
-
|
|
201
|
-
if (typeof window !== 'undefined') {
|
|
202
|
-
var currentScript = window.document.currentScript
|
|
203
|
-
if (true) {
|
|
204
|
-
var getCurrentScript = __webpack_require__("8875")
|
|
205
|
-
currentScript = getCurrentScript()
|
|
206
|
-
|
|
207
|
-
// for backward compatibility, because previously we directly included the polyfill
|
|
208
|
-
if (!('currentScript' in document)) {
|
|
209
|
-
Object.defineProperty(document, 'currentScript', { get: getCurrentScript })
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
var src = currentScript && currentScript.src.match(/(.+\/)[^/]+\.js(\?.*)?$/)
|
|
214
|
-
if (src) {
|
|
215
|
-
__webpack_require__.p = src[1] // eslint-disable-line
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
// Indicate to webpack that this file can be concatenated
|
|
220
|
-
/* harmony default export */ var setPublicPath = (null);
|
|
221
|
-
|
|
222
|
-
// EXTERNAL MODULE: external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
|
|
223
|
-
var external_commonjs_vue_commonjs2_vue_root_Vue_ = __webpack_require__("8bbf");
|
|
224
|
-
|
|
225
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/FormMaker.vue?vue&type=template&id=6dccc3ca&bindings={"loading":"props","hasActions":"props","modelValue":"props","fields":"props","hideDivider":"props","rowClass":"props","columnClass":"props","labelClass":"props","inputGroupClass":"props","inputWrapperClass":"props","inputErrorClass":"props","inputClass":"props","errorClass":"props","helpTextClass":"props","submitButtonClass":"props","submitButtonText":"props","value":"setup","formFields":"setup","realColumnClass":"setup","realRowClass":"setup","realSubmitButtonClass":"setup","handleSubmit":"setup"}
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
const _hoisted_1 = /*#__PURE__*/Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createTextVNode"])(" Loading... ");
|
|
229
|
-
|
|
230
|
-
const _hoisted_2 = {
|
|
231
|
-
key: 0
|
|
232
|
-
};
|
|
233
|
-
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
234
|
-
const _component_form_maker_input = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["resolveComponent"])("form-maker-input");
|
|
235
|
-
|
|
236
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("form", {
|
|
237
|
-
class: "form-maker",
|
|
238
|
-
onSubmit: _cache[1] || (_cache[1] = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["withModifiers"])((...args) => $setup.handleSubmit(...args), ["prevent"]))
|
|
239
|
-
}, [$props.loading ? Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "loading", {
|
|
240
|
-
key: 0
|
|
241
|
-
}, () => [_hoisted_1]) : Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createCommentVNode"])("", true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "default", {}, () => [(Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(external_commonjs_vue_commonjs2_vue_root_Vue_["Fragment"], null, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderList"])($setup.formFields, (fieldRow, i) => {
|
|
242
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("div", {
|
|
243
|
-
class: $setup.realRowClass,
|
|
244
|
-
key: `fieldRow_${i}`
|
|
245
|
-
}, [(Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(external_commonjs_vue_commonjs2_vue_root_Vue_["Fragment"], null, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderList"])(fieldRow, (field, j) => {
|
|
246
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("div", {
|
|
247
|
-
class: [$setup.realColumnClass, field.columnClass],
|
|
248
|
-
key: `field_${i}_${j}`
|
|
249
|
-
}, [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, `${field.name}`, {
|
|
250
|
-
field: field
|
|
251
|
-
}, () => [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createVNode"])(_component_form_maker_input, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["mergeProps"])({
|
|
252
|
-
modelValue: $setup.value[field.name],
|
|
253
|
-
"onUpdate:modelValue": $event => $setup.value[field.name] = $event
|
|
254
|
-
}, field), null, 16, ["modelValue", "onUpdate:modelValue"])])], 2);
|
|
255
|
-
}), 128
|
|
256
|
-
/* KEYED_FRAGMENT */
|
|
257
|
-
))], 2);
|
|
258
|
-
}), 128
|
|
259
|
-
/* KEYED_FRAGMENT */
|
|
260
|
-
))]), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "extra"), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "divider", {}, () => [$props.hasActions && !$props.hideDivider ? (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("hr", _hoisted_2)) : Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createCommentVNode"])("", true)]), $props.hasActions ? Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "actions", {
|
|
261
|
-
key: 1
|
|
262
|
-
}, () => [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "submit-button", {}, () => [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createVNode"])("button", {
|
|
263
|
-
class: $setup.realSubmitButtonClass,
|
|
264
|
-
disabled: $props.loading,
|
|
265
|
-
type: "submit"
|
|
266
|
-
}, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])($props.submitButtonText), 11, ["disabled"])]), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "extra-buttons")]) : Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createCommentVNode"])("", true)], 32);
|
|
267
|
-
}
|
|
268
|
-
// CONCATENATED MODULE: ./lib/components/FormMaker.vue?vue&type=template&id=6dccc3ca&bindings={"loading":"props","hasActions":"props","modelValue":"props","fields":"props","hideDivider":"props","rowClass":"props","columnClass":"props","labelClass":"props","inputGroupClass":"props","inputWrapperClass":"props","inputErrorClass":"props","inputClass":"props","errorClass":"props","helpTextClass":"props","submitButtonClass":"props","submitButtonText":"props","value":"setup","formFields":"setup","realColumnClass":"setup","realRowClass":"setup","realSubmitButtonClass":"setup","handleSubmit":"setup"}
|
|
269
|
-
|
|
270
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/FormMaker.vue?vue&type=script&lang=js
|
|
271
|
-
// import setupVModel from '../utils';
|
|
272
|
-
|
|
273
|
-
/* harmony default export */ var FormMakervue_type_script_lang_js = ({
|
|
274
|
-
name: 'FormMaker',
|
|
275
|
-
emits: ['submit', 'update:modelValue'],
|
|
276
|
-
props: {
|
|
277
|
-
loading: {
|
|
278
|
-
type: Boolean,
|
|
279
|
-
default: false
|
|
280
|
-
},
|
|
281
|
-
hasActions: {
|
|
282
|
-
type: Boolean,
|
|
283
|
-
default: true
|
|
284
|
-
},
|
|
285
|
-
modelValue: {
|
|
286
|
-
type: Object,
|
|
287
|
-
default: () => ({})
|
|
288
|
-
},
|
|
289
|
-
fields: {
|
|
290
|
-
type: Array,
|
|
291
|
-
default: () => []
|
|
292
|
-
},
|
|
293
|
-
hideDivider: {
|
|
294
|
-
type: Boolean,
|
|
295
|
-
default: false
|
|
296
|
-
},
|
|
297
|
-
rowClass: {
|
|
298
|
-
type: String,
|
|
299
|
-
default: null
|
|
300
|
-
},
|
|
301
|
-
columnClass: {
|
|
302
|
-
type: String,
|
|
303
|
-
default: null
|
|
304
|
-
},
|
|
305
|
-
labelClass: {
|
|
306
|
-
type: String,
|
|
307
|
-
default: null
|
|
308
|
-
},
|
|
309
|
-
inputGroupClass: {
|
|
310
|
-
type: String,
|
|
311
|
-
default: null
|
|
312
|
-
},
|
|
313
|
-
inputWrapperClass: {
|
|
314
|
-
type: String,
|
|
315
|
-
default: null
|
|
316
|
-
},
|
|
317
|
-
inputErrorClass: {
|
|
318
|
-
type: String,
|
|
319
|
-
default: null
|
|
320
|
-
},
|
|
321
|
-
inputClass: {
|
|
322
|
-
type: String,
|
|
323
|
-
default: null
|
|
324
|
-
},
|
|
325
|
-
errorClass: {
|
|
326
|
-
type: String,
|
|
327
|
-
default: null
|
|
328
|
-
},
|
|
329
|
-
helpTextClass: {
|
|
330
|
-
type: String,
|
|
331
|
-
default: null
|
|
332
|
-
},
|
|
333
|
-
submitButtonClass: {
|
|
334
|
-
type: String,
|
|
335
|
-
default: null
|
|
336
|
-
},
|
|
337
|
-
submitButtonText: {
|
|
338
|
-
type: String,
|
|
339
|
-
default: 'Submit'
|
|
340
|
-
}
|
|
341
|
-
},
|
|
342
|
-
|
|
343
|
-
setup(props, {
|
|
344
|
-
emit
|
|
345
|
-
}) {
|
|
346
|
-
const handleSubmit = () => emit('submit');
|
|
347
|
-
|
|
348
|
-
const formFields = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => {
|
|
349
|
-
if (props.fields.length > 0) {
|
|
350
|
-
return props.fields.map(row => {
|
|
351
|
-
let newRow = row;
|
|
352
|
-
|
|
353
|
-
if (!Array.isArray(row)) {
|
|
354
|
-
newRow = [row];
|
|
355
|
-
}
|
|
356
|
-
|
|
357
|
-
return newRow.map(fieldSpec => {
|
|
358
|
-
if (!fieldSpec.id) {
|
|
359
|
-
return { ...fieldSpec,
|
|
360
|
-
id: `formMaker_${new Date().getTime()}_${fieldSpec.name}`
|
|
361
|
-
};
|
|
362
|
-
}
|
|
363
|
-
|
|
364
|
-
return fieldSpec;
|
|
365
|
-
});
|
|
366
|
-
});
|
|
367
|
-
}
|
|
368
|
-
|
|
369
|
-
return Object.keys(props.modelValue).map(key => [{
|
|
370
|
-
name: key,
|
|
371
|
-
label: key,
|
|
372
|
-
id: `formMaker_${key}`
|
|
373
|
-
}]);
|
|
374
|
-
});
|
|
375
|
-
const {
|
|
376
|
-
rowClass,
|
|
377
|
-
columnClass,
|
|
378
|
-
labelClass,
|
|
379
|
-
inputGroupClass,
|
|
380
|
-
inputWrapperClass,
|
|
381
|
-
inputErrorClass,
|
|
382
|
-
inputClass,
|
|
383
|
-
errorClass,
|
|
384
|
-
helpTextClass,
|
|
385
|
-
submitButtonClass,
|
|
386
|
-
modelValue
|
|
387
|
-
} = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toRefs"])(props);
|
|
388
|
-
Object(external_commonjs_vue_commonjs2_vue_root_Vue_["provide"])('labelClass', labelClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('form-label'));
|
|
389
|
-
Object(external_commonjs_vue_commonjs2_vue_root_Vue_["provide"])('inputGroupClass', inputGroupClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('input-group'));
|
|
390
|
-
Object(external_commonjs_vue_commonjs2_vue_root_Vue_["provide"])('inputWrapperClass', inputWrapperClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('input-wrapper'));
|
|
391
|
-
Object(external_commonjs_vue_commonjs2_vue_root_Vue_["provide"])('inputErrorClass', inputErrorClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('input-error'));
|
|
392
|
-
Object(external_commonjs_vue_commonjs2_vue_root_Vue_["provide"])('inputClass', inputClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('input'));
|
|
393
|
-
Object(external_commonjs_vue_commonjs2_vue_root_Vue_["provide"])('errorClass', errorClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('error'));
|
|
394
|
-
Object(external_commonjs_vue_commonjs2_vue_root_Vue_["provide"])('helpTextClass', helpTextClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('help-text'));
|
|
395
|
-
const realRowClass = rowClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('form-row');
|
|
396
|
-
const realColumnClass = columnClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('form-column');
|
|
397
|
-
const realSubmitButtonClass = submitButtonClass.value || Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('submit-button');
|
|
398
|
-
return {
|
|
399
|
-
value: modelValue,
|
|
400
|
-
formFields,
|
|
401
|
-
realColumnClass,
|
|
402
|
-
realRowClass,
|
|
403
|
-
realSubmitButtonClass,
|
|
404
|
-
handleSubmit
|
|
405
|
-
};
|
|
406
|
-
}
|
|
407
|
-
|
|
408
|
-
});
|
|
409
|
-
// CONCATENATED MODULE: ./lib/components/FormMaker.vue?vue&type=script&lang=js
|
|
410
|
-
|
|
411
|
-
// CONCATENATED MODULE: ./lib/components/FormMaker.vue
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
FormMakervue_type_script_lang_js.render = render
|
|
416
|
-
|
|
417
|
-
/* harmony default export */ var FormMaker = (FormMakervue_type_script_lang_js);
|
|
418
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/FormMakerInput.vue?vue&type=template&id=c9668268&bindings={"value":"setup","labelClass":"setup","inputClass":"setup","inputErrorClass":"setup","inputGroupClass":"setup","inputWrapperClass":"setup","errorClass":"setup","helpTextClass":"setup","hasErrors":"setup","hasLabel":"setup","hasHelpText":"setup"}
|
|
419
|
-
|
|
420
|
-
function FormMakerInputvue_type_template_id_c9668268_bindings_value_setup_labelClass_setup_inputClass_setup_inputErrorClass_setup_inputGroupClass_setup_inputWrapperClass_setup_errorClass_setup_helpTextClass_setup_hasErrors_setup_hasLabel_setup_hasHelpText_setup_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
421
|
-
const _component_form_maker_label = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["resolveComponent"])("form-maker-label");
|
|
422
|
-
|
|
423
|
-
const _component_form_maker_help = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["resolveComponent"])("form-maker-help");
|
|
424
|
-
|
|
425
|
-
const _component_form_maker_error = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["resolveComponent"])("form-maker-error");
|
|
426
|
-
|
|
427
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("div", {
|
|
428
|
-
class: [$setup.hasErrors && $setup.inputErrorClass]
|
|
429
|
-
}, [_ctx.type !== 'checkbox' ? Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "label", {
|
|
430
|
-
key: 0
|
|
431
|
-
}, () => [$setup.hasLabel ? (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(_component_form_maker_label, {
|
|
432
|
-
key: 0,
|
|
433
|
-
id: _ctx.id,
|
|
434
|
-
class: $setup.labelClass,
|
|
435
|
-
text: _ctx.label
|
|
436
|
-
}, null, 8, ["id", "class", "text"])) : Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createCommentVNode"])("", true)]) : Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createCommentVNode"])("", true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "default", {}, () => [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createVNode"])("div", {
|
|
437
|
-
class: [$setup.inputGroupClass, $setup.hasErrors && $setup.inputErrorClass]
|
|
438
|
-
}, [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "before"), (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(Object(external_commonjs_vue_commonjs2_vue_root_Vue_["resolveDynamicComponent"])(`form-maker-input-${_ctx.type}`), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["mergeProps"])({
|
|
439
|
-
modelValue: $setup.value,
|
|
440
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => $setup.value = $event)
|
|
441
|
-
}, { ..._ctx.$props,
|
|
442
|
-
..._ctx.$attrs
|
|
443
|
-
}, {
|
|
444
|
-
class: [_ctx.type !== 'checkbox' && $setup.inputClass, $setup.hasErrors && $setup.inputErrorClass],
|
|
445
|
-
label: _ctx.label
|
|
446
|
-
}), null, 16, ["modelValue", "class", "label"])), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "after")], 2)]), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "help", {}, () => [$setup.hasHelpText ? (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(_component_form_maker_help, {
|
|
447
|
-
key: 0,
|
|
448
|
-
class: $setup.helpTextClass,
|
|
449
|
-
text: _ctx.helpText
|
|
450
|
-
}, null, 8, ["class", "text"])) : Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createCommentVNode"])("", true)]), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderSlot"])(_ctx.$slots, "errors", {}, () => [$setup.hasErrors ? (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(_component_form_maker_error, {
|
|
451
|
-
key: 0,
|
|
452
|
-
class: $setup.errorClass,
|
|
453
|
-
text: _ctx.error
|
|
454
|
-
}, null, 8, ["class", "text"])) : Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createCommentVNode"])("", true)])], 2);
|
|
455
|
-
}
|
|
456
|
-
// CONCATENATED MODULE: ./lib/components/FormMakerInput.vue?vue&type=template&id=c9668268&bindings={"value":"setup","labelClass":"setup","inputClass":"setup","inputErrorClass":"setup","inputGroupClass":"setup","inputWrapperClass":"setup","errorClass":"setup","helpTextClass":"setup","hasErrors":"setup","hasLabel":"setup","hasHelpText":"setup"}
|
|
457
|
-
|
|
458
|
-
// CONCATENATED MODULE: ./lib/utils.js
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
const setupVModel = (props, emit, propName = 'modelValue') => Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])({
|
|
462
|
-
get: () => props[propName],
|
|
463
|
-
set: value => emit(`update:${propName}`, value)
|
|
464
|
-
});
|
|
465
|
-
|
|
466
|
-
/* harmony default export */ var utils = (setupVModel);
|
|
467
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormInputMixin.js
|
|
468
|
-
|
|
469
|
-
const injectFormClasses = () => {
|
|
470
|
-
const labelClass = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('labelClass', null);
|
|
471
|
-
const inputClass = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('inputClass', null);
|
|
472
|
-
const inputWrapperClass = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('inputWrapperClass', null);
|
|
473
|
-
const inputGroupClass = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('inputGroupClass', null);
|
|
474
|
-
const inputErrorClass = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('inputErrorClass', null);
|
|
475
|
-
const errorClass = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('errorClass', null);
|
|
476
|
-
const helpTextClass = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["inject"])('helpTextClass', null);
|
|
477
|
-
return {
|
|
478
|
-
labelClass,
|
|
479
|
-
inputClass,
|
|
480
|
-
inputWrapperClass,
|
|
481
|
-
inputGroupClass,
|
|
482
|
-
inputErrorClass,
|
|
483
|
-
errorClass,
|
|
484
|
-
helpTextClass
|
|
485
|
-
};
|
|
486
|
-
};
|
|
487
|
-
const getFormInputComputeds = props => {
|
|
488
|
-
const {
|
|
489
|
-
label,
|
|
490
|
-
error,
|
|
491
|
-
helpText
|
|
492
|
-
} = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toRefs"])(props);
|
|
493
|
-
const hasErrors = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => !!error.value);
|
|
494
|
-
const hasLabel = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => !!label.value);
|
|
495
|
-
const hasHelpText = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => !!helpText.value);
|
|
496
|
-
return {
|
|
497
|
-
hasErrors,
|
|
498
|
-
hasLabel,
|
|
499
|
-
hasHelpText
|
|
500
|
-
};
|
|
501
|
-
};
|
|
502
|
-
const FormInputMixin = {
|
|
503
|
-
emits: ['update:modelValue'],
|
|
504
|
-
props: {
|
|
505
|
-
loading: {
|
|
506
|
-
type: Boolean,
|
|
507
|
-
default: false
|
|
508
|
-
},
|
|
509
|
-
disabled: {
|
|
510
|
-
type: Boolean,
|
|
511
|
-
default: false
|
|
512
|
-
},
|
|
513
|
-
modelValue: {
|
|
514
|
-
default: null
|
|
515
|
-
},
|
|
516
|
-
error: {
|
|
517
|
-
type: String,
|
|
518
|
-
default: null
|
|
519
|
-
},
|
|
520
|
-
helpText: {
|
|
521
|
-
type: String,
|
|
522
|
-
default: null
|
|
523
|
-
},
|
|
524
|
-
id: {
|
|
525
|
-
type: String,
|
|
526
|
-
default: null
|
|
527
|
-
},
|
|
528
|
-
label: {
|
|
529
|
-
type: String,
|
|
530
|
-
default: null
|
|
531
|
-
},
|
|
532
|
-
name: {
|
|
533
|
-
type: String,
|
|
534
|
-
default: null
|
|
535
|
-
},
|
|
536
|
-
placeholder: {
|
|
537
|
-
type: String,
|
|
538
|
-
default: null
|
|
539
|
-
},
|
|
540
|
-
type: {
|
|
541
|
-
type: String,
|
|
542
|
-
default: 'text'
|
|
543
|
-
},
|
|
544
|
-
options: {
|
|
545
|
-
type: Array,
|
|
546
|
-
default: () => []
|
|
547
|
-
},
|
|
548
|
-
optionGroups: {
|
|
549
|
-
type: Object,
|
|
550
|
-
default: () => ({})
|
|
551
|
-
}
|
|
552
|
-
}
|
|
553
|
-
};
|
|
554
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/FormMakerInput.vue?vue&type=script&lang=js
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
/* harmony default export */ var FormMakerInputvue_type_script_lang_js = ({
|
|
558
|
-
name: 'FormMakerInput',
|
|
559
|
-
mixins: [FormInputMixin],
|
|
560
|
-
inheritAttrs: false,
|
|
561
|
-
|
|
562
|
-
setup(props, {
|
|
563
|
-
emit
|
|
564
|
-
}) {
|
|
565
|
-
const value = utils(props, emit);
|
|
566
|
-
const {
|
|
567
|
-
labelClass,
|
|
568
|
-
inputClass,
|
|
569
|
-
inputWrapperClass,
|
|
570
|
-
inputGroupClass,
|
|
571
|
-
inputErrorClass,
|
|
572
|
-
errorClass,
|
|
573
|
-
helpTextClass
|
|
574
|
-
} = injectFormClasses();
|
|
575
|
-
const {
|
|
576
|
-
hasErrors,
|
|
577
|
-
hasLabel,
|
|
578
|
-
hasHelpText
|
|
579
|
-
} = getFormInputComputeds(props);
|
|
580
|
-
return {
|
|
581
|
-
value,
|
|
582
|
-
labelClass,
|
|
583
|
-
inputClass,
|
|
584
|
-
inputErrorClass,
|
|
585
|
-
inputGroupClass,
|
|
586
|
-
inputWrapperClass,
|
|
587
|
-
errorClass,
|
|
588
|
-
helpTextClass,
|
|
589
|
-
hasErrors,
|
|
590
|
-
hasLabel,
|
|
591
|
-
hasHelpText
|
|
592
|
-
};
|
|
593
|
-
}
|
|
594
|
-
|
|
595
|
-
});
|
|
596
|
-
// CONCATENATED MODULE: ./lib/components/FormMakerInput.vue?vue&type=script&lang=js
|
|
597
|
-
|
|
598
|
-
// CONCATENATED MODULE: ./lib/components/FormMakerInput.vue
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
FormMakerInputvue_type_script_lang_js.render = FormMakerInputvue_type_template_id_c9668268_bindings_value_setup_labelClass_setup_inputClass_setup_inputErrorClass_setup_inputGroupClass_setup_inputWrapperClass_setup_errorClass_setup_helpTextClass_setup_hasErrors_setup_hasLabel_setup_hasHelpText_setup_render
|
|
603
|
-
|
|
604
|
-
/* harmony default export */ var FormMakerInput = (FormMakerInputvue_type_script_lang_js);
|
|
605
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/CheckboxInput.vue?vue&type=template&id=0f1f8bfc&bindings={"label":"props","fieldOptions":"setup","isBinary":"setup","selectedOptions":"setup","handleClick":"setup"}
|
|
606
|
-
|
|
607
|
-
function CheckboxInputvue_type_template_id_0f1f8bfc_bindings_label_props_fieldOptions_setup_isBinary_setup_selectedOptions_setup_handleClick_setup_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
608
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(external_commonjs_vue_commonjs2_vue_root_Vue_["Fragment"], null, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderList"])($setup.fieldOptions, (option, i) => {
|
|
609
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("div", {
|
|
610
|
-
key: `option_${i}`
|
|
611
|
-
}, [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createVNode"])("label", null, [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createVNode"])("input", Object(external_commonjs_vue_commonjs2_vue_root_Vue_["mergeProps"])(_ctx.$props, {
|
|
612
|
-
checked: $setup.selectedOptions.indexOf(option.value) !== -1,
|
|
613
|
-
value: option.value,
|
|
614
|
-
type: "checkbox",
|
|
615
|
-
onClick: () => $setup.handleClick(option.value)
|
|
616
|
-
}), null, 16, ["checked", "value", "onClick"]), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createTextVNode"])(" " + Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])(option.label), 1
|
|
617
|
-
/* TEXT */
|
|
618
|
-
)])]);
|
|
619
|
-
}), 128
|
|
620
|
-
/* KEYED_FRAGMENT */
|
|
621
|
-
);
|
|
622
|
-
}
|
|
623
|
-
// CONCATENATED MODULE: ./lib/components/inputs/CheckboxInput.vue?vue&type=template&id=0f1f8bfc&bindings={"label":"props","fieldOptions":"setup","isBinary":"setup","selectedOptions":"setup","handleClick":"setup"}
|
|
624
|
-
|
|
625
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/CheckboxInput.vue?vue&type=script&lang=js
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
/* harmony default export */ var CheckboxInputvue_type_script_lang_js = ({
|
|
629
|
-
name: 'CheckInput',
|
|
630
|
-
mixins: [FormInputMixin],
|
|
631
|
-
emits: ['update:modelValue'],
|
|
632
|
-
props: {
|
|
633
|
-
label: {
|
|
634
|
-
type: String,
|
|
635
|
-
default: null
|
|
636
|
-
}
|
|
637
|
-
},
|
|
638
|
-
|
|
639
|
-
setup(props, {
|
|
640
|
-
emit
|
|
641
|
-
}) {
|
|
642
|
-
const {
|
|
643
|
-
options,
|
|
644
|
-
label
|
|
645
|
-
} = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toRefs"])(props);
|
|
646
|
-
const isBinary = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => options.value.length === 0);
|
|
647
|
-
const val = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => props.modelValue);
|
|
648
|
-
const selectedOptions = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => {
|
|
649
|
-
const arr = Array.isArray(val.value) ? val.value : [val.value];
|
|
650
|
-
return arr.filter(x => !!x);
|
|
651
|
-
});
|
|
652
|
-
const fieldOptions = Object(external_commonjs_vue_commonjs2_vue_root_Vue_["computed"])(() => {
|
|
653
|
-
if (!isBinary.value) {
|
|
654
|
-
return options.value;
|
|
655
|
-
}
|
|
656
|
-
|
|
657
|
-
return [{
|
|
658
|
-
label: label.value,
|
|
659
|
-
value: true
|
|
660
|
-
}];
|
|
661
|
-
});
|
|
662
|
-
|
|
663
|
-
const handleClick = clickVal => {
|
|
664
|
-
let selOptions = [...selectedOptions.value];
|
|
665
|
-
|
|
666
|
-
if (selOptions.indexOf(clickVal) === -1) {
|
|
667
|
-
selOptions.push(clickVal);
|
|
668
|
-
} else {
|
|
669
|
-
selOptions = selOptions.filter(x => x !== clickVal);
|
|
670
|
-
}
|
|
671
|
-
|
|
672
|
-
if (isBinary.value) {
|
|
673
|
-
emit('update:modelValue', selOptions.length > 0);
|
|
674
|
-
} else {
|
|
675
|
-
emit('update:modelValue', selOptions);
|
|
676
|
-
}
|
|
677
|
-
};
|
|
678
|
-
|
|
679
|
-
return {
|
|
680
|
-
fieldOptions,
|
|
681
|
-
isBinary,
|
|
682
|
-
selectedOptions,
|
|
683
|
-
handleClick
|
|
684
|
-
};
|
|
685
|
-
}
|
|
686
|
-
|
|
687
|
-
});
|
|
688
|
-
// CONCATENATED MODULE: ./lib/components/inputs/CheckboxInput.vue?vue&type=script&lang=js
|
|
689
|
-
|
|
690
|
-
// CONCATENATED MODULE: ./lib/components/inputs/CheckboxInput.vue
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
CheckboxInputvue_type_script_lang_js.render = CheckboxInputvue_type_template_id_0f1f8bfc_bindings_label_props_fieldOptions_setup_isBinary_setup_selectedOptions_setup_handleClick_setup_render
|
|
695
|
-
|
|
696
|
-
/* harmony default export */ var CheckboxInput = (CheckboxInputvue_type_script_lang_js);
|
|
697
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FileInput.vue?vue&type=template&id=36054fae&bindings={"handleFileSelect":"setup"}
|
|
698
|
-
|
|
699
|
-
function FileInputvue_type_template_id_36054fae_bindings_handleFileSelect_setup_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
700
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("input", Object(external_commonjs_vue_commonjs2_vue_root_Vue_["mergeProps"])(_ctx.$props, {
|
|
701
|
-
type: "file",
|
|
702
|
-
onChange: _cache[1] || (_cache[1] = (...args) => $setup.handleFileSelect(...args))
|
|
703
|
-
}), null, 16);
|
|
704
|
-
}
|
|
705
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FileInput.vue?vue&type=template&id=36054fae&bindings={"handleFileSelect":"setup"}
|
|
706
|
-
|
|
707
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FileInput.vue?vue&type=script&lang=js
|
|
708
|
-
|
|
709
|
-
/* harmony default export */ var FileInputvue_type_script_lang_js = ({
|
|
710
|
-
name: 'FileInput',
|
|
711
|
-
mixins: [FormInputMixin],
|
|
712
|
-
emits: ['update:modelValue'],
|
|
713
|
-
|
|
714
|
-
setup(props, {
|
|
715
|
-
emit
|
|
716
|
-
}) {
|
|
717
|
-
const handleFileSelect = event => {
|
|
718
|
-
if (event.target.files.length) {
|
|
719
|
-
const file = event.target.files[0];
|
|
720
|
-
emit('update:modelValue', file);
|
|
721
|
-
}
|
|
722
|
-
};
|
|
723
|
-
|
|
724
|
-
return {
|
|
725
|
-
handleFileSelect
|
|
726
|
-
};
|
|
727
|
-
}
|
|
728
|
-
|
|
729
|
-
});
|
|
730
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FileInput.vue?vue&type=script&lang=js
|
|
731
|
-
|
|
732
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FileInput.vue
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
FileInputvue_type_script_lang_js.render = FileInputvue_type_template_id_36054fae_bindings_handleFileSelect_setup_render
|
|
737
|
-
|
|
738
|
-
/* harmony default export */ var FileInput = (FileInputvue_type_script_lang_js);
|
|
739
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FormMakerInputError.vue?vue&type=template&id=3b7039ac&bindings={"text":"props"}
|
|
740
|
-
|
|
741
|
-
function FormMakerInputErrorvue_type_template_id_3b7039ac_bindings_text_props_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
742
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("div", null, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])($props.text), 1);
|
|
743
|
-
}
|
|
744
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputError.vue?vue&type=template&id=3b7039ac&bindings={"text":"props"}
|
|
745
|
-
|
|
746
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FormMakerInputError.vue?vue&type=script&lang=js
|
|
747
|
-
/* harmony default export */ var FormMakerInputErrorvue_type_script_lang_js = ({
|
|
748
|
-
name: 'FormMakerInputError',
|
|
749
|
-
props: {
|
|
750
|
-
text: {
|
|
751
|
-
type: String,
|
|
752
|
-
default: null
|
|
753
|
-
}
|
|
754
|
-
}
|
|
755
|
-
});
|
|
756
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputError.vue?vue&type=script&lang=js
|
|
757
|
-
|
|
758
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputError.vue
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
FormMakerInputErrorvue_type_script_lang_js.render = FormMakerInputErrorvue_type_template_id_3b7039ac_bindings_text_props_render
|
|
763
|
-
|
|
764
|
-
/* harmony default export */ var FormMakerInputError = (FormMakerInputErrorvue_type_script_lang_js);
|
|
765
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FormMakerInputHelp.vue?vue&type=template&id=7439ecba&bindings={"text":"props"}
|
|
766
|
-
|
|
767
|
-
function FormMakerInputHelpvue_type_template_id_7439ecba_bindings_text_props_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
768
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("div", null, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])($props.text), 1);
|
|
769
|
-
}
|
|
770
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputHelp.vue?vue&type=template&id=7439ecba&bindings={"text":"props"}
|
|
771
|
-
|
|
772
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FormMakerInputHelp.vue?vue&type=script&lang=js
|
|
773
|
-
/* harmony default export */ var FormMakerInputHelpvue_type_script_lang_js = ({
|
|
774
|
-
name: 'FormMakerInputHelp',
|
|
775
|
-
props: {
|
|
776
|
-
text: {
|
|
777
|
-
type: String,
|
|
778
|
-
default: null
|
|
779
|
-
}
|
|
780
|
-
}
|
|
781
|
-
});
|
|
782
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputHelp.vue?vue&type=script&lang=js
|
|
783
|
-
|
|
784
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputHelp.vue
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
FormMakerInputHelpvue_type_script_lang_js.render = FormMakerInputHelpvue_type_template_id_7439ecba_bindings_text_props_render
|
|
789
|
-
|
|
790
|
-
/* harmony default export */ var FormMakerInputHelp = (FormMakerInputHelpvue_type_script_lang_js);
|
|
791
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FormMakerInputLabel.vue?vue&type=template&id=10c7c87e&bindings={"text":"props","id":"props"}
|
|
792
|
-
|
|
793
|
-
function FormMakerInputLabelvue_type_template_id_10c7c87e_bindings_text_props_id_props_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
794
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("label", {
|
|
795
|
-
for: $props.id
|
|
796
|
-
}, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])($props.text), 9, ["for"]);
|
|
797
|
-
}
|
|
798
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputLabel.vue?vue&type=template&id=10c7c87e&bindings={"text":"props","id":"props"}
|
|
799
|
-
|
|
800
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/FormMakerInputLabel.vue?vue&type=script&lang=js
|
|
801
|
-
/* harmony default export */ var FormMakerInputLabelvue_type_script_lang_js = ({
|
|
802
|
-
name: 'FormMakerInputLabel',
|
|
803
|
-
props: {
|
|
804
|
-
text: {
|
|
805
|
-
type: String,
|
|
806
|
-
default: null
|
|
807
|
-
},
|
|
808
|
-
id: {
|
|
809
|
-
type: String,
|
|
810
|
-
default: null
|
|
811
|
-
}
|
|
812
|
-
}
|
|
813
|
-
});
|
|
814
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputLabel.vue?vue&type=script&lang=js
|
|
815
|
-
|
|
816
|
-
// CONCATENATED MODULE: ./lib/components/inputs/FormMakerInputLabel.vue
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
FormMakerInputLabelvue_type_script_lang_js.render = FormMakerInputLabelvue_type_template_id_10c7c87e_bindings_text_props_id_props_render
|
|
821
|
-
|
|
822
|
-
/* harmony default export */ var FormMakerInputLabel = (FormMakerInputLabelvue_type_script_lang_js);
|
|
823
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/RadioInput.vue?vue&type=template&id=2d04d097&bindings={"label":"props","handleClick":"setup"}
|
|
824
|
-
|
|
825
|
-
function RadioInputvue_type_template_id_2d04d097_bindings_label_props_handleClick_setup_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
826
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(external_commonjs_vue_commonjs2_vue_root_Vue_["Fragment"], null, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderList"])(_ctx.options, (option, i) => {
|
|
827
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("div", {
|
|
828
|
-
key: `option_${i}`
|
|
829
|
-
}, [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createVNode"])("label", null, [Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createVNode"])("input", Object(external_commonjs_vue_commonjs2_vue_root_Vue_["mergeProps"])(_ctx.$props, {
|
|
830
|
-
checked: option.value === _ctx.modelValue,
|
|
831
|
-
value: option.value,
|
|
832
|
-
type: "radio",
|
|
833
|
-
onChange: _cache[1] || (_cache[1] = (...args) => $setup.handleClick(...args))
|
|
834
|
-
}), null, 16, ["checked", "value"]), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createTextVNode"])(" " + Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])(option.label), 1
|
|
835
|
-
/* TEXT */
|
|
836
|
-
)])]);
|
|
837
|
-
}), 128
|
|
838
|
-
/* KEYED_FRAGMENT */
|
|
839
|
-
);
|
|
840
|
-
}
|
|
841
|
-
// CONCATENATED MODULE: ./lib/components/inputs/RadioInput.vue?vue&type=template&id=2d04d097&bindings={"label":"props","handleClick":"setup"}
|
|
842
|
-
|
|
843
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/RadioInput.vue?vue&type=script&lang=js
|
|
844
|
-
|
|
845
|
-
/* harmony default export */ var RadioInputvue_type_script_lang_js = ({
|
|
846
|
-
name: 'RadioInput',
|
|
847
|
-
emits: ['update:modelValue'],
|
|
848
|
-
mixins: [FormInputMixin],
|
|
849
|
-
props: {
|
|
850
|
-
label: {
|
|
851
|
-
type: String,
|
|
852
|
-
default: null
|
|
853
|
-
}
|
|
854
|
-
},
|
|
855
|
-
|
|
856
|
-
setup(props, {
|
|
857
|
-
emit
|
|
858
|
-
}) {
|
|
859
|
-
const handleClick = e => emit('update:modelValue', e.target.value);
|
|
860
|
-
|
|
861
|
-
return {
|
|
862
|
-
handleClick
|
|
863
|
-
};
|
|
864
|
-
}
|
|
865
|
-
|
|
866
|
-
});
|
|
867
|
-
// CONCATENATED MODULE: ./lib/components/inputs/RadioInput.vue?vue&type=script&lang=js
|
|
868
|
-
|
|
869
|
-
// CONCATENATED MODULE: ./lib/components/inputs/RadioInput.vue
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
RadioInputvue_type_script_lang_js.render = RadioInputvue_type_template_id_2d04d097_bindings_label_props_handleClick_setup_render
|
|
874
|
-
|
|
875
|
-
/* harmony default export */ var RadioInput = (RadioInputvue_type_script_lang_js);
|
|
876
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/SelectInput.vue?vue&type=template&id=797a9e6e&bindings={"value":"setup","hasGroups":"setup"}
|
|
877
|
-
|
|
878
|
-
function SelectInputvue_type_template_id_797a9e6e_bindings_value_setup_hasGroups_setup_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
879
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["withDirectives"])((Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("select", {
|
|
880
|
-
id: _ctx.id,
|
|
881
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => $setup.value = $event),
|
|
882
|
-
disabled: _ctx.disabled,
|
|
883
|
-
name: _ctx.name,
|
|
884
|
-
placeholder: _ctx.placeholder
|
|
885
|
-
}, [$setup.hasGroups ? (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(external_commonjs_vue_commonjs2_vue_root_Vue_["Fragment"], {
|
|
886
|
-
key: 0
|
|
887
|
-
}, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderList"])(_ctx.optionGroups, (opts, key) => {
|
|
888
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("optgroup", {
|
|
889
|
-
key: `optGroup_${key}`,
|
|
890
|
-
label: key
|
|
891
|
-
}, [(Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(external_commonjs_vue_commonjs2_vue_root_Vue_["Fragment"], null, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderList"])(opts, (optLabel, value) => {
|
|
892
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("option", {
|
|
893
|
-
key: `option_${value}`,
|
|
894
|
-
value: value
|
|
895
|
-
}, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])(optLabel), 9, ["value"]);
|
|
896
|
-
}), 128
|
|
897
|
-
/* KEYED_FRAGMENT */
|
|
898
|
-
))], 8, ["label"]);
|
|
899
|
-
}), 128
|
|
900
|
-
/* KEYED_FRAGMENT */
|
|
901
|
-
)) : (Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(true), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])(external_commonjs_vue_commonjs2_vue_root_Vue_["Fragment"], {
|
|
902
|
-
key: 1
|
|
903
|
-
}, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["renderList"])(_ctx.options, (option, i) => {
|
|
904
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("option", {
|
|
905
|
-
key: `option_${i}`,
|
|
906
|
-
value: option.value
|
|
907
|
-
}, Object(external_commonjs_vue_commonjs2_vue_root_Vue_["toDisplayString"])(option.label), 9, ["value"]);
|
|
908
|
-
}), 128
|
|
909
|
-
/* KEYED_FRAGMENT */
|
|
910
|
-
))], 8, ["id", "disabled", "name", "placeholder"])), [[external_commonjs_vue_commonjs2_vue_root_Vue_["vModelSelect"], $setup.value]]);
|
|
911
|
-
}
|
|
912
|
-
// CONCATENATED MODULE: ./lib/components/inputs/SelectInput.vue?vue&type=template&id=797a9e6e&bindings={"value":"setup","hasGroups":"setup"}
|
|
913
|
-
|
|
914
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/SelectInput.vue?vue&type=script&lang=js
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
/* harmony default export */ var SelectInputvue_type_script_lang_js = ({
|
|
918
|
-
name: 'SelectInput',
|
|
919
|
-
mixins: [FormInputMixin],
|
|
920
|
-
|
|
921
|
-
setup(props, {
|
|
922
|
-
emit
|
|
923
|
-
}) {
|
|
924
|
-
const value = utils(props, emit);
|
|
925
|
-
const hasGroups = Object.keys(props.optionGroups).length > 0;
|
|
926
|
-
return {
|
|
927
|
-
value,
|
|
928
|
-
hasGroups
|
|
929
|
-
};
|
|
930
|
-
}
|
|
931
|
-
|
|
932
|
-
});
|
|
933
|
-
// CONCATENATED MODULE: ./lib/components/inputs/SelectInput.vue?vue&type=script&lang=js
|
|
934
|
-
|
|
935
|
-
// CONCATENATED MODULE: ./lib/components/inputs/SelectInput.vue
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
SelectInputvue_type_script_lang_js.render = SelectInputvue_type_template_id_797a9e6e_bindings_value_setup_hasGroups_setup_render
|
|
940
|
-
|
|
941
|
-
/* harmony default export */ var SelectInput = (SelectInputvue_type_script_lang_js);
|
|
942
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/TextAreaInput.vue?vue&type=template&id=cc1fd11e&bindings={"value":"setup"}
|
|
943
|
-
|
|
944
|
-
function TextAreaInputvue_type_template_id_cc1fd11e_bindings_value_setup_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
945
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["withDirectives"])((Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("textarea", {
|
|
946
|
-
id: _ctx.id,
|
|
947
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => $setup.value = $event),
|
|
948
|
-
disabled: _ctx.disabled,
|
|
949
|
-
name: _ctx.name,
|
|
950
|
-
placeholder: _ctx.placeholder
|
|
951
|
-
}, null, 8, ["id", "disabled", "name", "placeholder"])), [[external_commonjs_vue_commonjs2_vue_root_Vue_["vModelText"], $setup.value]]);
|
|
952
|
-
}
|
|
953
|
-
// CONCATENATED MODULE: ./lib/components/inputs/TextAreaInput.vue?vue&type=template&id=cc1fd11e&bindings={"value":"setup"}
|
|
954
|
-
|
|
955
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/TextAreaInput.vue?vue&type=script&lang=js
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
/* harmony default export */ var TextAreaInputvue_type_script_lang_js = ({
|
|
959
|
-
name: 'TextAreaInput',
|
|
960
|
-
mixins: [FormInputMixin],
|
|
961
|
-
|
|
962
|
-
setup(props, {
|
|
963
|
-
emit
|
|
964
|
-
}) {
|
|
965
|
-
const value = utils(props, emit);
|
|
966
|
-
return {
|
|
967
|
-
value
|
|
968
|
-
};
|
|
969
|
-
}
|
|
970
|
-
|
|
971
|
-
});
|
|
972
|
-
// CONCATENATED MODULE: ./lib/components/inputs/TextAreaInput.vue?vue&type=script&lang=js
|
|
973
|
-
|
|
974
|
-
// CONCATENATED MODULE: ./lib/components/inputs/TextAreaInput.vue
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
TextAreaInputvue_type_script_lang_js.render = TextAreaInputvue_type_template_id_cc1fd11e_bindings_value_setup_render
|
|
979
|
-
|
|
980
|
-
/* harmony default export */ var TextAreaInput = (TextAreaInputvue_type_script_lang_js);
|
|
981
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/vue-loader-v16/dist/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/TextInput.vue?vue&type=template&id=604ff240&bindings={"value":"setup"}
|
|
982
|
-
|
|
983
|
-
function TextInputvue_type_template_id_604ff240_bindings_value_setup_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
984
|
-
return Object(external_commonjs_vue_commonjs2_vue_root_Vue_["withDirectives"])((Object(external_commonjs_vue_commonjs2_vue_root_Vue_["openBlock"])(), Object(external_commonjs_vue_commonjs2_vue_root_Vue_["createBlock"])("input", Object(external_commonjs_vue_commonjs2_vue_root_Vue_["mergeProps"])({
|
|
985
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => $setup.value = $event),
|
|
986
|
-
type: _ctx.type
|
|
987
|
-
}, _ctx.$props), null, 16, ["type"])), [[external_commonjs_vue_commonjs2_vue_root_Vue_["vModelDynamic"], $setup.value]]);
|
|
988
|
-
}
|
|
989
|
-
// CONCATENATED MODULE: ./lib/components/inputs/TextInput.vue?vue&type=template&id=604ff240&bindings={"value":"setup"}
|
|
990
|
-
|
|
991
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader-v16/dist??ref--0-1!./lib/components/inputs/TextInput.vue?vue&type=script&lang=js
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
/* harmony default export */ var TextInputvue_type_script_lang_js = ({
|
|
995
|
-
name: 'TextInput',
|
|
996
|
-
mixins: [FormInputMixin],
|
|
997
|
-
|
|
998
|
-
setup(props, {
|
|
999
|
-
emit
|
|
1000
|
-
}) {
|
|
1001
|
-
const value = utils(props, emit);
|
|
1002
|
-
return {
|
|
1003
|
-
value
|
|
1004
|
-
};
|
|
1005
|
-
}
|
|
1006
|
-
|
|
1007
|
-
});
|
|
1008
|
-
// CONCATENATED MODULE: ./lib/components/inputs/TextInput.vue?vue&type=script&lang=js
|
|
1009
|
-
|
|
1010
|
-
// CONCATENATED MODULE: ./lib/components/inputs/TextInput.vue
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
TextInputvue_type_script_lang_js.render = TextInputvue_type_template_id_604ff240_bindings_value_setup_render
|
|
1015
|
-
|
|
1016
|
-
/* harmony default export */ var TextInput = (TextInputvue_type_script_lang_js);
|
|
1017
|
-
// CONCATENATED MODULE: ./index.js
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
const defaultOptions = {
|
|
1030
|
-
classes: {
|
|
1031
|
-
'form-row': 'form-maker-row',
|
|
1032
|
-
'form-column': 'form-maker-column',
|
|
1033
|
-
'form-label': 'form-maker-label',
|
|
1034
|
-
'input-group': 'form-maker-input-group',
|
|
1035
|
-
'input-wrapper': 'form-maker-input-wrapper',
|
|
1036
|
-
'input-error': 'form-maker-input-error',
|
|
1037
|
-
'input': 'form-maker-input',
|
|
1038
|
-
'error': 'form-maker-error',
|
|
1039
|
-
'help-text': 'form-maker-help-text',
|
|
1040
|
-
'submit-button': 'form-maker-submit'
|
|
1041
|
-
},
|
|
1042
|
-
components: {
|
|
1043
|
-
'form-maker-input-color': TextInput,
|
|
1044
|
-
'form-maker-input-date': TextInput,
|
|
1045
|
-
'form-maker-input-email': TextInput,
|
|
1046
|
-
'form-maker-input-month': TextInput,
|
|
1047
|
-
'form-maker-input-number': TextInput,
|
|
1048
|
-
'form-maker-input-password': TextInput,
|
|
1049
|
-
'form-maker-input-search': TextInput,
|
|
1050
|
-
'form-maker-input-tel': TextInput,
|
|
1051
|
-
'form-maker-input-time': TextInput,
|
|
1052
|
-
'form-maker-input-text': TextInput,
|
|
1053
|
-
'form-maker-input-url': TextInput,
|
|
1054
|
-
'form-maker-input-week': TextInput,
|
|
1055
|
-
'form-maker-input-range': TextInput,
|
|
1056
|
-
'form-maker-input-file': FileInput,
|
|
1057
|
-
'form-maker-input-textarea': TextAreaInput,
|
|
1058
|
-
'form-maker-input-select': SelectInput,
|
|
1059
|
-
'form-maker-input-checkbox': CheckboxInput,
|
|
1060
|
-
'form-maker-input-radio': RadioInput,
|
|
1061
|
-
'form-maker-label': FormMakerInputLabel,
|
|
1062
|
-
'form-maker-help': FormMakerInputHelp,
|
|
1063
|
-
'form-maker-error': FormMakerInputError
|
|
1064
|
-
}
|
|
1065
|
-
};
|
|
1066
|
-
const index_FormMaker = {
|
|
1067
|
-
install: (app, extraOptions = {}) => {
|
|
1068
|
-
const options = {
|
|
1069
|
-
classes: { ...defaultOptions.classes,
|
|
1070
|
-
...extraOptions.classes
|
|
1071
|
-
},
|
|
1072
|
-
components: { ...defaultOptions.components,
|
|
1073
|
-
...extraOptions.components
|
|
1074
|
-
}
|
|
1075
|
-
};
|
|
1076
|
-
app.component('FormMaker', FormMaker);
|
|
1077
|
-
app.component('FormMakerInput', FormMakerInput);
|
|
1078
|
-
Object.keys(options.classes).forEach(key => {
|
|
1079
|
-
app.provide(key, options.classes[key]);
|
|
1080
|
-
});
|
|
1081
|
-
Object.keys(options.components).forEach(key => {
|
|
1082
|
-
app.component(key, options.components[key]);
|
|
1083
|
-
});
|
|
1084
|
-
}
|
|
1085
|
-
};
|
|
1086
|
-
/* harmony default export */ var index = (index_FormMaker);
|
|
1087
|
-
// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
/* harmony default export */ var entry_lib = __webpack_exports__["default"] = (index);
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
/***/ })
|
|
1095
|
-
|
|
1096
|
-
/******/ });
|
|
1097
|
-
});
|
|
1
|
+
var $e=Object.defineProperty,Se=Object.defineProperties;var Ee=Object.getOwnPropertyDescriptors;var S=Object.getOwnPropertySymbols;var Ve=Object.prototype.hasOwnProperty,Fe=Object.prototype.propertyIsEnumerable;var E=(e,a,f)=>a in e?$e(e,a,{enumerable:!0,configurable:!0,writable:!0,value:f}):e[a]=f,k=(e,a)=>{for(var f in a||(a={}))Ve.call(a,f)&&E(e,f,a[f]);if(S)for(var f of S(a))Fe.call(a,f)&&E(e,f,a[f]);return e},V=(e,a)=>Se(e,Ee(a));(function(e,a){typeof exports=="object"&&typeof module!="undefined"?module.exports=a(require("vue")):typeof define=="function"&&define.amd?define(["vue"],a):(e=typeof globalThis!="undefined"?globalThis:e||self,e.FormMaker=a(e.Vue))})(this,function(e){"use strict";var a=(t,r)=>{const n=t.__vccOpts||t;for(const[l,s]of r)n[l]=s;return n};const f={name:"FormMaker",emits:["submit","update:modelValue"],props:{loading:{type:Boolean,default:!1},hasActions:{type:Boolean,default:!0},modelValue:{type:Object,default:()=>({})},fields:{type:Array,default:()=>[]},hideDivider:{type:Boolean,default:!1},rowClass:{type:String,default:null},columnClass:{type:String,default:null},labelClass:{type:String,default:null},inputGroupClass:{type:String,default:null},inputWrapperClass:{type:String,default:null},inputErrorClass:{type:String,default:null},inputClass:{type:String,default:null},errorClass:{type:String,default:null},helpTextClass:{type:String,default:null},submitButtonClass:{type:String,default:null},submitButtonText:{type:String,default:"Submit"}},setup(t,{emit:r}){const n=()=>r("submit"),l=e.computed(()=>t.fields.length>0?t.fields.map(b=>{let $=b;return Array.isArray(b)||($=[b]),$.map(g=>g.id?g:V(k({},g),{id:`formMaker_${new Date().getTime()}_${g.name}`}))}):Object.keys(t.modelValue).map(b=>[{name:b,label:b,id:`formMaker_${b}`}])),{rowClass:s,columnClass:i,labelClass:o,inputGroupClass:m,inputWrapperClass:u,inputErrorClass:p,inputClass:c,errorClass:h,helpTextClass:B,submitButtonClass:be,modelValue:ye}=e.toRefs(t);e.provide("labelClass",o.value||e.inject("form-label")),e.provide("inputGroupClass",m.value||e.inject("input-group")),e.provide("inputWrapperClass",u.value||e.inject("input-wrapper")),e.provide("inputErrorClass",p.value||e.inject("input-error")),e.provide("inputClass",c.value||e.inject("input")),e.provide("errorClass",h.value||e.inject("error")),e.provide("helpTextClass",B.value||e.inject("help-text"));const ge=s.value||e.inject("form-row"),Be=i.value||e.inject("form-column"),_e=be.value||e.inject("submit-button");return{value:ye,formFields:l,realColumnClass:Be,realRowClass:ge,realSubmitButtonClass:_e,handleSubmit:n}}},F=e.createTextVNode(" Loading... "),x={key:0},T=["disabled"];function j(t,r,n,l,s,i){const o=e.resolveComponent("form-maker-input");return e.openBlock(),e.createElementBlock("form",{class:"form-maker",onSubmit:r[0]||(r[0]=e.withModifiers((...m)=>l.handleSubmit&&l.handleSubmit(...m),["prevent"]))},[n.loading?e.renderSlot(t.$slots,"loading",{key:0},()=>[F]):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default",{},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.formFields,(m,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(l.realRowClass),key:`fieldRow_${u}`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m,(p,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([l.realColumnClass,p.columnClass]),key:`field_${u}_${c}`},[e.renderSlot(t.$slots,`${p.name}`,{field:p},()=>[e.createVNode(o,e.mergeProps({modelValue:l.value[p.name],"onUpdate:modelValue":h=>l.value[p.name]=h},p),null,16,["modelValue","onUpdate:modelValue"])])],2))),128))],2))),128))]),e.renderSlot(t.$slots,"extra"),e.renderSlot(t.$slots,"divider",{},()=>[n.hasActions&&!n.hideDivider?(e.openBlock(),e.createElementBlock("hr",x)):e.createCommentVNode("",!0)]),n.hasActions?e.renderSlot(t.$slots,"actions",{key:1},()=>[e.renderSlot(t.$slots,"submit-button",{},()=>[e.createElementVNode("button",{class:e.normalizeClass(l.realSubmitButtonClass),disabled:n.loading,type:"submit"},e.toDisplayString(n.submitButtonText),11,T)]),e.renderSlot(t.$slots,"extra-buttons")]):e.createCommentVNode("",!0)],32)}var I=a(f,[["render",j]]);const y=(t,r,n="modelValue")=>e.computed({get:()=>t[n],set:l=>r(`update:${n}`,l)}),M=()=>{const t=e.inject("labelClass",null),r=e.inject("inputClass",null),n=e.inject("inputWrapperClass",null),l=e.inject("inputGroupClass",null),s=e.inject("inputErrorClass",null),i=e.inject("errorClass",null),o=e.inject("helpTextClass",null);return{labelClass:t,inputClass:r,inputWrapperClass:n,inputGroupClass:l,inputErrorClass:s,errorClass:i,helpTextClass:o}},w=t=>{const{label:r,error:n,helpText:l}=e.toRefs(t),s=e.computed(()=>!!n.value),i=e.computed(()=>!!r.value),o=e.computed(()=>!!l.value);return{hasErrors:s,hasLabel:i,hasHelpText:o}},C={emits:["update:modelValue"],props:{loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},modelValue:{default:null},error:{type:String,default:null},helpText:{type:String,default:null},id:{type:String,default:null},label:{type:String,default:null},name:{type:String,default:null},placeholder:{type:String,default:null},type:{type:String,default:"text"},options:{type:Array,default:()=>[]},optionGroups:{type:Object,default:()=>({})}}},D={name:"FormMakerInput",mixins:[C],inheritAttrs:!1,setup(t,{emit:r}){const n=y(t,r),{labelClass:l,inputClass:s,inputWrapperClass:i,inputGroupClass:o,inputErrorClass:m,errorClass:u,helpTextClass:p}=M(),{hasErrors:c,hasLabel:h,hasHelpText:B}=w(t);return{value:n,labelClass:l,inputClass:s,inputErrorClass:m,inputGroupClass:o,inputWrapperClass:i,errorClass:u,helpTextClass:p,hasErrors:c,hasLabel:h,hasHelpText:B}}};function N(t,r,n,l,s,i){const o=e.resolveComponent("form-maker-label"),m=e.resolveComponent("form-maker-help"),u=e.resolveComponent("form-maker-error");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([l.hasErrors&&l.inputErrorClass])},[t.type!=="checkbox"?e.renderSlot(t.$slots,"label",{key:0},()=>[l.hasLabel?(e.openBlock(),e.createBlock(o,{key:0,id:t.id,class:e.normalizeClass(l.labelClass),text:t.label},null,8,["id","class","text"])):e.createCommentVNode("",!0)]):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default",{},()=>[e.createElementVNode("div",{class:e.normalizeClass([l.inputGroupClass,l.hasErrors&&l.inputErrorClass])},[e.renderSlot(t.$slots,"before"),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(`form-maker-input-${t.type}`),e.mergeProps({modelValue:l.value,"onUpdate:modelValue":r[0]||(r[0]=p=>l.value=p)},k(k({},t.$props),t.$attrs),{class:[t.type!=="checkbox"&&l.inputClass,l.hasErrors&&l.inputErrorClass],label:t.label}),null,16,["modelValue","class","label"])),e.renderSlot(t.$slots,"after")],2)]),e.renderSlot(t.$slots,"help",{},()=>[l.hasHelpText?(e.openBlock(),e.createBlock(m,{key:0,class:e.normalizeClass(l.helpTextClass),text:t.helpText},null,8,["class","text"])):e.createCommentVNode("",!0)]),e.renderSlot(t.$slots,"errors",{},()=>[l.hasErrors?(e.openBlock(),e.createBlock(u,{key:0,class:e.normalizeClass(l.errorClass),text:t.error},null,8,["class","text"])):e.createCommentVNode("",!0)])],2)}var O=a(D,[["render",N]]);const G={name:"CheckInput",mixins:[C],emits:["update:modelValue"],props:{label:{type:String,default:null}},setup(t,{emit:r}){const{options:n,label:l}=e.toRefs(t),s=e.computed(()=>n.value.length===0),i=e.computed(()=>t.modelValue),o=e.computed(()=>(Array.isArray(i.value)?i.value:[i.value]).filter(c=>!!c));return{fieldOptions:e.computed(()=>s.value?[{label:l.value,value:!0}]:n.value),isBinary:s,selectedOptions:o,handleClick:p=>{let c=[...o.value];c.indexOf(p)===-1?c.push(p):c=c.filter(h=>h!==p),s.value?r("update:modelValue",c.length>0):r("update:modelValue",c)}}}},L=["checked","value","onClick"];function A(t,r,n,l,s,i){return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.fieldOptions,(o,m)=>(e.openBlock(),e.createElementBlock("div",{key:`option_${m}`},[e.createElementVNode("label",null,[e.createElementVNode("input",e.mergeProps(t.$props,{checked:l.selectedOptions.indexOf(o.value)!==-1,value:o.value,type:"checkbox",onClick:()=>l.handleClick(o.value)}),null,16,L),e.createTextVNode(" "+e.toDisplayString(o.label),1)])]))),128)}var R=a(G,[["render",A]]);const z={name:"FileInput",mixins:[C],emits:["update:modelValue"],setup(t,{emit:r}){return{handleFileSelect:l=>{if(l.target.files.length){const s=l.target.files[0];r("update:modelValue",s)}}}}};function P(t,r,n,l,s,i){return e.openBlock(),e.createElementBlock("input",e.mergeProps(t.$props,{type:"file",onChange:r[0]||(r[0]=(...o)=>l.handleFileSelect&&l.handleFileSelect(...o))}),null,16)}var U=a(z,[["render",P]]);const W={name:"FormMakerInputError",props:{text:{type:String,default:null}}};function H(t,r,n,l,s,i){return e.openBlock(),e.createElementBlock("div",null,e.toDisplayString(n.text),1)}var q=a(W,[["render",H]]);const J={name:"FormMakerInputHelp",props:{text:{type:String,default:null}}};function K(t,r,n,l,s,i){return e.openBlock(),e.createElementBlock("div",null,e.toDisplayString(n.text),1)}var Q=a(J,[["render",K]]);const X={name:"FormMakerInputLabel",props:{text:{type:String,default:null},id:{type:String,default:null}}},Y=["for"];function Z(t,r,n,l,s,i){return e.openBlock(),e.createElementBlock("label",{for:n.id},e.toDisplayString(n.text),9,Y)}var v=a(X,[["render",Z]]);const ee={name:"RadioInput",emits:["update:modelValue"],mixins:[C],props:{label:{type:String,default:null}},setup(t,{emit:r}){return{handleClick:l=>r("update:modelValue",l.target.value)}}},te=["checked","value"];function le(t,r,n,l,s,i){return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(o,m)=>(e.openBlock(),e.createElementBlock("div",{key:`option_${m}`},[e.createElementVNode("label",null,[e.createElementVNode("input",e.mergeProps(t.$props,{checked:o.value===t.modelValue,value:o.value,type:"radio",onChange:r[0]||(r[0]=(...u)=>l.handleClick&&l.handleClick(...u))}),null,16,te),e.createTextVNode(" "+e.toDisplayString(o.label),1)])]))),128)}var re=a(ee,[["render",le]]);const ne={name:"SelectInput",mixins:[C],setup(t,{emit:r}){const n=y(t,r),l=Object.keys(t.optionGroups).length>0;return{value:n,hasGroups:l}}},oe=["id","disabled","name","placeholder"],ae=["label"],se=["value"],ie=["value"];function pe(t,r,n,l,s,i){return e.withDirectives((e.openBlock(),e.createElementBlock("select",{id:t.id,"onUpdate:modelValue":r[0]||(r[0]=o=>l.value=o),disabled:t.disabled,name:t.name,placeholder:t.placeholder},[l.hasGroups?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.optionGroups,(o,m)=>(e.openBlock(),e.createElementBlock("optgroup",{key:`optGroup_${m}`,label:m},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o,(u,p)=>(e.openBlock(),e.createElementBlock("option",{key:`option_${p}`,value:p},e.toDisplayString(u),9,se))),128))],8,ae))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.options,(o,m)=>(e.openBlock(),e.createElementBlock("option",{key:`option_${m}`,value:o.value},e.toDisplayString(o.label),9,ie))),128))],8,oe)),[[e.vModelSelect,l.value]])}var me=a(ne,[["render",pe]]);const ce={name:"TextAreaInput",mixins:[C],setup(t,{emit:r}){return{value:y(t,r)}}},de=["id","disabled","name","placeholder"];function ue(t,r,n,l,s,i){return e.withDirectives((e.openBlock(),e.createElementBlock("textarea",{id:t.id,"onUpdate:modelValue":r[0]||(r[0]=o=>l.value=o),disabled:t.disabled,name:t.name,placeholder:t.placeholder},null,8,de)),[[e.vModelText,l.value]])}var fe=a(ce,[["render",ue]]);const ke={name:"TextInput",mixins:[C],setup(t,{emit:r}){return{value:y(t,r)}}},Ce=["type"];function he(t,r,n,l,s,i){return e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps({"onUpdate:modelValue":r[0]||(r[0]=o=>l.value=o),type:t.type},t.$props),null,16,Ce)),[[e.vModelDynamic,l.value]])}var d=a(ke,[["render",he]]);const _={classes:{"form-row":"form-maker-row","form-column":"form-maker-column","form-label":"form-maker-label","input-group":"form-maker-input-group","input-wrapper":"form-maker-input-wrapper","input-error":"form-maker-input-error",input:"form-maker-input",error:"form-maker-error","help-text":"form-maker-help-text","submit-button":"form-maker-submit"},components:{"form-maker-input-color":d,"form-maker-input-date":d,"form-maker-input-email":d,"form-maker-input-month":d,"form-maker-input-number":d,"form-maker-input-password":d,"form-maker-input-search":d,"form-maker-input-tel":d,"form-maker-input-time":d,"form-maker-input-text":d,"form-maker-input-url":d,"form-maker-input-week":d,"form-maker-input-range":d,"form-maker-input-file":U,"form-maker-input-textarea":fe,"form-maker-input-select":me,"form-maker-input-checkbox":R,"form-maker-input-radio":re,"form-maker-label":v,"form-maker-help":Q,"form-maker-error":q}};return{install:(t,r={})=>{const n={classes:k(k({},_.classes),r.classes),components:k(k({},_.components),r.components)};t.component("FormMaker",I),t.component("FormMakerInput",O),Object.keys(n.classes).forEach(l=>{t.provide(l,n.classes[l])}),Object.keys(n.components).forEach(l=>{t.component(l,n.components[l])})}}});
|