@bagelink/vue 0.0.675 → 0.0.677
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/dist/components/Accordion.d.ts +12 -0
- package/dist/components/Accordion.d.ts.map +1 -0
- package/dist/components/AccordionItem.d.ts +34 -0
- package/dist/components/AccordionItem.d.ts.map +1 -0
- package/dist/components/Alert.d.ts +34 -0
- package/dist/components/Alert.d.ts.map +1 -0
- package/dist/components/Avatar.d.ts +36 -0
- package/dist/components/Avatar.d.ts.map +1 -0
- package/dist/components/Badge.d.ts +22 -0
- package/dist/components/Badge.d.ts.map +1 -0
- package/dist/components/BglVideo.d.ts +20 -0
- package/dist/components/BglVideo.d.ts.map +1 -0
- package/dist/components/Btn.d.ts +99 -0
- package/dist/components/Btn.d.ts.map +1 -0
- package/dist/components/Card.d.ts +39 -0
- package/dist/components/Card.d.ts.map +1 -0
- package/dist/components/Carousel.d.ts +74 -0
- package/dist/components/Carousel.d.ts.map +1 -0
- package/dist/components/ComboBox.vue.d.ts +3 -3
- package/dist/components/Comments.vue.d.ts +2 -2
- package/dist/components/ContactSubmissions.vue.d.ts +2 -2
- package/dist/components/DataPreview.d.ts +42 -0
- package/dist/components/DataPreview.d.ts.map +1 -0
- package/dist/components/Drop.vue.d.ts +34 -0
- package/dist/components/Drop.vue.d.ts.map +1 -0
- package/dist/components/DropDown.vue.d.ts +3 -3
- package/dist/components/FileUploader.vue.d.ts +60 -0
- package/dist/components/FileUploader.vue.d.ts.map +1 -0
- package/dist/components/Flag.d.ts +20 -0
- package/dist/components/Flag.d.ts.map +1 -0
- package/dist/components/FormSchema.vue.d.ts +5 -4
- package/dist/components/LangText.vue.d.ts +2 -2
- package/dist/components/ListItem.d.ts +34 -0
- package/dist/components/ListItem.d.ts.map +1 -0
- package/dist/components/ListView.d.ts +13 -0
- package/dist/components/ListView.d.ts.map +1 -0
- package/dist/components/MapEmbed.d.ts +3 -0
- package/dist/components/MapEmbed.d.ts.map +1 -0
- package/dist/components/MaterialIcon.d.ts +26 -0
- package/dist/components/MaterialIcon.d.ts.map +1 -0
- package/dist/components/Modal.d.ts +46 -0
- package/dist/components/Modal.d.ts.map +1 -0
- package/dist/components/ModalBglForm.vue.d.ts +21 -20
- package/dist/components/ModalConfirm.d.ts +24 -0
- package/dist/components/ModalConfirm.d.ts.map +1 -0
- package/dist/components/ModalForm.d.ts +78 -0
- package/dist/components/ModalForm.d.ts.map +1 -0
- package/dist/components/NavBar.d.ts +64 -0
- package/dist/components/NavBar.d.ts.map +1 -0
- package/dist/components/PageTitle.d.ts +24 -0
- package/dist/components/PageTitle.d.ts.map +1 -0
- package/dist/components/PersonPreview.vue.d.ts +5 -4
- package/dist/components/PersonPreviewFormkit.vue.d.ts +4 -3
- package/dist/components/RTXEditor.vue.d.ts +3 -3
- package/dist/components/RouterWrapper.d.ts +3 -0
- package/dist/components/RouterWrapper.d.ts.map +1 -0
- package/dist/components/TabbedLayout.vue.d.ts +5 -4
- package/dist/components/TableSchema.d.ts +35 -0
- package/dist/components/TableSchema.d.ts.map +1 -0
- package/dist/components/Title.d.ts +42 -0
- package/dist/components/Title.d.ts.map +1 -0
- package/dist/components/TopBar.d.ts +12 -0
- package/dist/components/TopBar.d.ts.map +1 -0
- package/dist/components/charts/BarChart.vue.d.ts +2 -2
- package/dist/components/dashboard/Lineart.d.ts +20 -0
- package/dist/components/dashboard/Lineart.d.ts.map +1 -0
- package/dist/components/form/BglField.d.ts +25 -0
- package/dist/components/form/BglField.d.ts.map +1 -0
- package/dist/components/form/BglForm.d.ts +75 -0
- package/dist/components/form/BglForm.d.ts.map +1 -0
- package/dist/components/form/ItemRef.vue.d.ts +5 -3
- package/dist/components/form/ItemRef.vue.d.ts.map +1 -1
- package/dist/components/form/MaterialIcon.vue.d.ts +4 -3
- package/dist/components/form/PlainInputField.vue.d.ts +3 -3
- package/dist/components/form/inputs/CheckInput.d.ts +56 -0
- package/dist/components/form/inputs/CheckInput.d.ts.map +1 -0
- package/dist/components/form/inputs/Checkbox.d.ts +16 -0
- package/dist/components/form/inputs/Checkbox.d.ts.map +1 -0
- package/dist/components/form/inputs/ColorPicker.d.ts +48 -0
- package/dist/components/form/inputs/ColorPicker.d.ts.map +1 -0
- package/dist/components/form/inputs/CurrencyInput.vue.d.ts +3 -3
- package/dist/components/form/inputs/DateInput.d.ts +64 -0
- package/dist/components/form/inputs/DateInput.d.ts.map +1 -0
- package/dist/components/form/inputs/DatePicker.d.ts +33 -0
- package/dist/components/form/inputs/DatePicker.d.ts.map +1 -0
- package/dist/components/form/inputs/DatetimeInput.vue.d.ts +3 -3
- package/dist/components/form/inputs/DurationInput.vue.d.ts +3 -3
- package/dist/components/form/inputs/DynamicLinkField.vue.d.ts +3 -3
- package/dist/components/form/inputs/EmailInput.vue.d.ts +3 -3
- package/dist/components/form/inputs/FileUpload.d.ts +108 -0
- package/dist/components/form/inputs/FileUpload.d.ts.map +1 -0
- package/dist/components/form/inputs/FloatInput.vue.d.ts +3 -3
- package/dist/components/form/inputs/IntInput.vue.d.ts +3 -3
- package/dist/components/form/inputs/JSONInput.d.ts +53 -0
- package/dist/components/form/inputs/JSONInput.d.ts.map +1 -0
- package/dist/components/form/inputs/LinkField.vue.d.ts +3 -3
- package/dist/components/form/inputs/Password.vue.d.ts +3 -3
- package/dist/components/form/inputs/PasswordInput.vue.d.ts +3 -3
- package/dist/components/form/inputs/PlainText.vue.d.ts +3 -3
- package/dist/components/form/inputs/RadioGroup.d.ts +42 -0
- package/dist/components/form/inputs/RadioGroup.d.ts.map +1 -0
- package/dist/components/form/inputs/RadioPillsInput.d.ts +48 -0
- package/dist/components/form/inputs/RadioPillsInput.d.ts.map +1 -0
- package/dist/components/form/inputs/ReadOnlyInput.vue.d.ts +2 -2
- package/dist/components/form/inputs/RichText.d.ts +20 -0
- package/dist/components/form/inputs/RichText.d.ts.map +1 -0
- package/dist/components/form/inputs/RichText2/Toolbar.d.ts +22 -0
- package/dist/components/form/inputs/RichText2/Toolbar.d.ts.map +1 -0
- package/dist/components/form/inputs/RichText2/index.d.ts +24 -0
- package/dist/components/form/inputs/RichText2/index.d.ts.map +1 -0
- package/dist/components/form/inputs/RichTextEditor.vue.d.ts +3 -3
- package/dist/components/form/inputs/SelectField.vue.d.ts +6 -8
- package/dist/components/form/inputs/SelectField.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/SelectInput.d.ts +55 -0
- package/dist/components/form/inputs/SelectInput.d.ts.map +1 -0
- package/dist/components/form/inputs/SignaturePad.d.ts +72 -0
- package/dist/components/form/inputs/SignaturePad.d.ts.map +1 -0
- package/dist/components/form/inputs/TableField.d.ts +45 -0
- package/dist/components/form/inputs/TableField.d.ts.map +1 -0
- package/dist/components/form/inputs/TelInput.d.ts +241 -0
- package/dist/components/form/inputs/TelInput.d.ts.map +1 -0
- package/dist/components/form/inputs/TelInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/TextArea.vue.d.ts +3 -3
- package/dist/components/form/inputs/TextInput.d.ts +90 -0
- package/dist/components/form/inputs/TextInput.d.ts.map +1 -0
- package/dist/components/form/inputs/ToggleInput.d.ts +58 -0
- package/dist/components/form/inputs/ToggleInput.d.ts.map +1 -0
- package/dist/components/formkit/AddressArray.vue.d.ts +2 -2
- package/dist/components/formkit/BankDetailsArray.vue.d.ts +2 -2
- package/dist/components/formkit/ContactArrayFormKit.vue.d.ts +2 -2
- package/dist/components/formkit/FileUploader.vue.d.ts +2 -2
- package/dist/components/formkit/MiscFields.vue.d.ts +2 -2
- package/dist/components/formkit/Toggle.vue.d.ts +2 -2
- package/dist/components/layout/BottomMenu.d.ts +27 -0
- package/dist/components/layout/BottomMenu.d.ts.map +1 -0
- package/dist/components/layout/Layout.d.ts +58 -0
- package/dist/components/layout/Layout.d.ts.map +1 -0
- package/dist/components/layout/SidebarMenu.d.ts +38 -0
- package/dist/components/layout/SidebarMenu.d.ts.map +1 -0
- package/dist/components/layout/TabbedLayout.d.ts +42 -0
- package/dist/components/layout/TabbedLayout.d.ts.map +1 -0
- package/dist/components/layout/Tabs.d.ts +31 -0
- package/dist/components/layout/Tabs.d.ts.map +1 -0
- package/dist/components/layout/TabsBody.d.ts +23 -0
- package/dist/components/layout/TabsBody.d.ts.map +1 -0
- package/dist/components/layout/TabsNav.d.ts +35 -0
- package/dist/components/layout/TabsNav.d.ts.map +1 -0
- package/dist/components/whatsapp/form/MsgTemplate.vue.d.ts +4 -3
- package/dist/components/whatsapp/form/TextVariableExamples.vue.d.ts +2 -2
- package/dist/index.cjs +144 -80
- package/dist/index.mjs +144 -80
- package/dist/style.css +7 -7
- package/dist/utils/objects.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/form/inputs/TelInput.vue +12 -5
- package/dist/components/Popover.vue.d.ts +0 -10
- package/dist/components/Popover.vue.d.ts.map +0 -1
- package/dist/types/materialIcon.d.ts +0 -2
- package/dist/types/materialIcon.d.ts.map +0 -1
package/dist/index.mjs
CHANGED
|
@@ -2845,6 +2845,26 @@ const toJSONObject = (obj) => {
|
|
|
2845
2845
|
};
|
|
2846
2846
|
const isAsyncFn = kindOfTest("AsyncFunction");
|
|
2847
2847
|
const isThenable = (thing) => thing && (isObject$1(thing) || isFunction$1(thing)) && isFunction$1(thing.then) && isFunction$1(thing.catch);
|
|
2848
|
+
const _setImmediate = ((setImmediateSupported, postMessageSupported) => {
|
|
2849
|
+
if (setImmediateSupported) {
|
|
2850
|
+
return setImmediate;
|
|
2851
|
+
}
|
|
2852
|
+
return postMessageSupported ? ((token, callbacks) => {
|
|
2853
|
+
_global.addEventListener("message", ({ source, data: data2 }) => {
|
|
2854
|
+
if (source === _global && data2 === token) {
|
|
2855
|
+
callbacks.length && callbacks.shift()();
|
|
2856
|
+
}
|
|
2857
|
+
}, false);
|
|
2858
|
+
return (cb) => {
|
|
2859
|
+
callbacks.push(cb);
|
|
2860
|
+
_global.postMessage(token, "*");
|
|
2861
|
+
};
|
|
2862
|
+
})(`axios@${Math.random()}`, []) : (cb) => setTimeout(cb);
|
|
2863
|
+
})(
|
|
2864
|
+
typeof setImmediate === "function",
|
|
2865
|
+
isFunction$1(_global.postMessage)
|
|
2866
|
+
);
|
|
2867
|
+
const asap = typeof queueMicrotask !== "undefined" ? queueMicrotask.bind(_global) : typeof process !== "undefined" && process.nextTick || _setImmediate;
|
|
2848
2868
|
const utils$1 = {
|
|
2849
2869
|
isArray,
|
|
2850
2870
|
isArrayBuffer,
|
|
@@ -2901,7 +2921,9 @@ const utils$1 = {
|
|
|
2901
2921
|
isSpecCompliantForm,
|
|
2902
2922
|
toJSONObject,
|
|
2903
2923
|
isAsyncFn,
|
|
2904
|
-
isThenable
|
|
2924
|
+
isThenable,
|
|
2925
|
+
setImmediate: _setImmediate,
|
|
2926
|
+
asap
|
|
2905
2927
|
};
|
|
2906
2928
|
function AxiosError(message2, code2, config, request, response) {
|
|
2907
2929
|
Error.call(this);
|
|
@@ -3736,27 +3758,35 @@ function speedometer(samplesCount, min2) {
|
|
|
3736
3758
|
}
|
|
3737
3759
|
function throttle$2(fn3, freq) {
|
|
3738
3760
|
let timestamp = 0;
|
|
3739
|
-
|
|
3740
|
-
let
|
|
3741
|
-
|
|
3742
|
-
|
|
3761
|
+
let threshold = 1e3 / freq;
|
|
3762
|
+
let lastArgs;
|
|
3763
|
+
let timer;
|
|
3764
|
+
const invoke = (args, now = Date.now()) => {
|
|
3765
|
+
timestamp = now;
|
|
3766
|
+
lastArgs = null;
|
|
3767
|
+
if (timer) {
|
|
3768
|
+
clearTimeout(timer);
|
|
3769
|
+
timer = null;
|
|
3770
|
+
}
|
|
3771
|
+
fn3.apply(null, args);
|
|
3772
|
+
};
|
|
3773
|
+
const throttled = (...args) => {
|
|
3743
3774
|
const now = Date.now();
|
|
3744
|
-
|
|
3745
|
-
|
|
3746
|
-
|
|
3747
|
-
|
|
3775
|
+
const passed = now - timestamp;
|
|
3776
|
+
if (passed >= threshold) {
|
|
3777
|
+
invoke(args, now);
|
|
3778
|
+
} else {
|
|
3779
|
+
lastArgs = args;
|
|
3780
|
+
if (!timer) {
|
|
3781
|
+
timer = setTimeout(() => {
|
|
3782
|
+
timer = null;
|
|
3783
|
+
invoke(lastArgs);
|
|
3784
|
+
}, threshold - passed);
|
|
3748
3785
|
}
|
|
3749
|
-
timestamp = now;
|
|
3750
|
-
return fn3.apply(null, arguments);
|
|
3751
|
-
}
|
|
3752
|
-
if (!timer) {
|
|
3753
|
-
timer = setTimeout(() => {
|
|
3754
|
-
timer = null;
|
|
3755
|
-
timestamp = Date.now();
|
|
3756
|
-
return fn3.apply(null, arguments);
|
|
3757
|
-
}, threshold - (now - timestamp));
|
|
3758
3786
|
}
|
|
3759
3787
|
};
|
|
3788
|
+
const flush = () => lastArgs && invoke(lastArgs);
|
|
3789
|
+
return [throttled, flush];
|
|
3760
3790
|
}
|
|
3761
3791
|
const progressEventReducer = (listener, isDownloadStream, freq = 3) => {
|
|
3762
3792
|
let bytesNotified = 0;
|
|
@@ -3776,12 +3806,21 @@ const progressEventReducer = (listener, isDownloadStream, freq = 3) => {
|
|
|
3776
3806
|
rate: rate ? rate : void 0,
|
|
3777
3807
|
estimated: rate && total && inRange ? (total - loaded) / rate : void 0,
|
|
3778
3808
|
event: e,
|
|
3779
|
-
lengthComputable: total != null
|
|
3809
|
+
lengthComputable: total != null,
|
|
3810
|
+
[isDownloadStream ? "download" : "upload"]: true
|
|
3780
3811
|
};
|
|
3781
|
-
data2[isDownloadStream ? "download" : "upload"] = true;
|
|
3782
3812
|
listener(data2);
|
|
3783
3813
|
}, freq);
|
|
3784
3814
|
};
|
|
3815
|
+
const progressEventDecorator = (total, throttled) => {
|
|
3816
|
+
const lengthComputable = total != null;
|
|
3817
|
+
return [(loaded) => throttled[0]({
|
|
3818
|
+
lengthComputable,
|
|
3819
|
+
total,
|
|
3820
|
+
loaded
|
|
3821
|
+
}), throttled[1]];
|
|
3822
|
+
};
|
|
3823
|
+
const asyncDecorator = (fn3) => (...args) => utils$1.asap(() => fn3(...args));
|
|
3785
3824
|
const isURLSameOrigin = platform.hasStandardBrowserEnv ? (
|
|
3786
3825
|
// Standard browser envs have full support of the APIs needed to test
|
|
3787
3826
|
// whether the request URL is of the same origin as current location.
|
|
@@ -3979,15 +4018,15 @@ const xhrAdapter = isXHRAdapterSupported && function(config) {
|
|
|
3979
4018
|
const _config = resolveConfig(config);
|
|
3980
4019
|
let requestData = _config.data;
|
|
3981
4020
|
const requestHeaders = AxiosHeaders.from(_config.headers).normalize();
|
|
3982
|
-
let { responseType } = _config;
|
|
4021
|
+
let { responseType, onUploadProgress, onDownloadProgress } = _config;
|
|
3983
4022
|
let onCanceled;
|
|
4023
|
+
let uploadThrottled, downloadThrottled;
|
|
4024
|
+
let flushUpload, flushDownload;
|
|
3984
4025
|
function done() {
|
|
3985
|
-
|
|
3986
|
-
|
|
3987
|
-
|
|
3988
|
-
|
|
3989
|
-
_config.signal.removeEventListener("abort", onCanceled);
|
|
3990
|
-
}
|
|
4026
|
+
flushUpload && flushUpload();
|
|
4027
|
+
flushDownload && flushDownload();
|
|
4028
|
+
_config.cancelToken && _config.cancelToken.unsubscribe(onCanceled);
|
|
4029
|
+
_config.signal && _config.signal.removeEventListener("abort", onCanceled);
|
|
3991
4030
|
}
|
|
3992
4031
|
let request = new XMLHttpRequest();
|
|
3993
4032
|
request.open(_config.method.toUpperCase(), _config.url, true);
|
|
@@ -4034,11 +4073,11 @@ const xhrAdapter = isXHRAdapterSupported && function(config) {
|
|
|
4034
4073
|
if (!request) {
|
|
4035
4074
|
return;
|
|
4036
4075
|
}
|
|
4037
|
-
reject3(new AxiosError("Request aborted", AxiosError.ECONNABORTED,
|
|
4076
|
+
reject3(new AxiosError("Request aborted", AxiosError.ECONNABORTED, config, request));
|
|
4038
4077
|
request = null;
|
|
4039
4078
|
};
|
|
4040
4079
|
request.onerror = function handleError() {
|
|
4041
|
-
reject3(new AxiosError("Network Error", AxiosError.ERR_NETWORK,
|
|
4080
|
+
reject3(new AxiosError("Network Error", AxiosError.ERR_NETWORK, config, request));
|
|
4042
4081
|
request = null;
|
|
4043
4082
|
};
|
|
4044
4083
|
request.ontimeout = function handleTimeout() {
|
|
@@ -4050,7 +4089,7 @@ const xhrAdapter = isXHRAdapterSupported && function(config) {
|
|
|
4050
4089
|
reject3(new AxiosError(
|
|
4051
4090
|
timeoutErrorMessage,
|
|
4052
4091
|
transitional2.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED,
|
|
4053
|
-
|
|
4092
|
+
config,
|
|
4054
4093
|
request
|
|
4055
4094
|
));
|
|
4056
4095
|
request = null;
|
|
@@ -4067,11 +4106,14 @@ const xhrAdapter = isXHRAdapterSupported && function(config) {
|
|
|
4067
4106
|
if (responseType && responseType !== "json") {
|
|
4068
4107
|
request.responseType = _config.responseType;
|
|
4069
4108
|
}
|
|
4070
|
-
if (
|
|
4071
|
-
|
|
4109
|
+
if (onDownloadProgress) {
|
|
4110
|
+
[downloadThrottled, flushDownload] = progressEventReducer(onDownloadProgress, true);
|
|
4111
|
+
request.addEventListener("progress", downloadThrottled);
|
|
4072
4112
|
}
|
|
4073
|
-
if (
|
|
4074
|
-
|
|
4113
|
+
if (onUploadProgress && request.upload) {
|
|
4114
|
+
[uploadThrottled, flushUpload] = progressEventReducer(onUploadProgress);
|
|
4115
|
+
request.upload.addEventListener("progress", uploadThrottled);
|
|
4116
|
+
request.upload.addEventListener("loadend", flushUpload);
|
|
4075
4117
|
}
|
|
4076
4118
|
if (_config.cancelToken || _config.signal) {
|
|
4077
4119
|
onCanceled = (cancel) => {
|
|
@@ -4149,39 +4191,52 @@ const readBytes = async function* (iterable, chunkSize, encode2) {
|
|
|
4149
4191
|
const trackStream = (stream, chunkSize, onProgress, onFinish, encode2) => {
|
|
4150
4192
|
const iterator = readBytes(stream, chunkSize, encode2);
|
|
4151
4193
|
let bytes = 0;
|
|
4194
|
+
let done;
|
|
4195
|
+
let _onFinish = (e) => {
|
|
4196
|
+
if (!done) {
|
|
4197
|
+
done = true;
|
|
4198
|
+
onFinish && onFinish(e);
|
|
4199
|
+
}
|
|
4200
|
+
};
|
|
4152
4201
|
return new ReadableStream({
|
|
4153
|
-
type: "bytes",
|
|
4154
4202
|
async pull(controller) {
|
|
4155
|
-
|
|
4156
|
-
|
|
4157
|
-
|
|
4158
|
-
|
|
4159
|
-
|
|
4203
|
+
try {
|
|
4204
|
+
const { done: done2, value } = await iterator.next();
|
|
4205
|
+
if (done2) {
|
|
4206
|
+
_onFinish();
|
|
4207
|
+
controller.close();
|
|
4208
|
+
return;
|
|
4209
|
+
}
|
|
4210
|
+
let len = value.byteLength;
|
|
4211
|
+
if (onProgress) {
|
|
4212
|
+
let loadedBytes = bytes += len;
|
|
4213
|
+
onProgress(loadedBytes);
|
|
4214
|
+
}
|
|
4215
|
+
controller.enqueue(new Uint8Array(value));
|
|
4216
|
+
} catch (err) {
|
|
4217
|
+
_onFinish(err);
|
|
4218
|
+
throw err;
|
|
4160
4219
|
}
|
|
4161
|
-
let len = value.byteLength;
|
|
4162
|
-
onProgress && onProgress(bytes += len);
|
|
4163
|
-
controller.enqueue(new Uint8Array(value));
|
|
4164
4220
|
},
|
|
4165
4221
|
cancel(reason) {
|
|
4166
|
-
|
|
4222
|
+
_onFinish(reason);
|
|
4167
4223
|
return iterator.return();
|
|
4168
4224
|
}
|
|
4169
4225
|
}, {
|
|
4170
4226
|
highWaterMark: 2
|
|
4171
4227
|
});
|
|
4172
4228
|
};
|
|
4173
|
-
const fetchProgressDecorator = (total, fn3) => {
|
|
4174
|
-
const lengthComputable = total != null;
|
|
4175
|
-
return (loaded) => setTimeout(() => fn3({
|
|
4176
|
-
lengthComputable,
|
|
4177
|
-
total,
|
|
4178
|
-
loaded
|
|
4179
|
-
}));
|
|
4180
|
-
};
|
|
4181
4229
|
const isFetchSupported = typeof fetch === "function" && typeof Request === "function" && typeof Response === "function";
|
|
4182
4230
|
const isReadableStreamSupported = isFetchSupported && typeof ReadableStream === "function";
|
|
4183
4231
|
const encodeText = isFetchSupported && (typeof TextEncoder === "function" ? /* @__PURE__ */ ((encoder) => (str) => encoder.encode(str))(new TextEncoder()) : async (str) => new Uint8Array(await new Response(str).arrayBuffer()));
|
|
4184
|
-
const
|
|
4232
|
+
const test = (fn3, ...args) => {
|
|
4233
|
+
try {
|
|
4234
|
+
return !!fn3(...args);
|
|
4235
|
+
} catch (e) {
|
|
4236
|
+
return false;
|
|
4237
|
+
}
|
|
4238
|
+
};
|
|
4239
|
+
const supportsRequestStream = isReadableStreamSupported && test(() => {
|
|
4185
4240
|
let duplexAccessed = false;
|
|
4186
4241
|
const hasContentType = new Request(platform.origin, {
|
|
4187
4242
|
body: new ReadableStream(),
|
|
@@ -4192,14 +4247,9 @@ const supportsRequestStream = isReadableStreamSupported && (() => {
|
|
|
4192
4247
|
}
|
|
4193
4248
|
}).headers.has("Content-Type");
|
|
4194
4249
|
return duplexAccessed && !hasContentType;
|
|
4195
|
-
})
|
|
4250
|
+
});
|
|
4196
4251
|
const DEFAULT_CHUNK_SIZE = 64 * 1024;
|
|
4197
|
-
const supportsResponseStream = isReadableStreamSupported &&
|
|
4198
|
-
try {
|
|
4199
|
-
return utils$1.isReadableStream(new Response("").body);
|
|
4200
|
-
} catch (err) {
|
|
4201
|
-
}
|
|
4202
|
-
})();
|
|
4252
|
+
const supportsResponseStream = isReadableStreamSupported && test(() => utils$1.isReadableStream(new Response("").body));
|
|
4203
4253
|
const resolvers = {
|
|
4204
4254
|
stream: supportsResponseStream && ((res) => res.body)
|
|
4205
4255
|
};
|
|
@@ -4220,7 +4270,7 @@ const getBodyLength = async (body) => {
|
|
|
4220
4270
|
if (utils$1.isSpecCompliantForm(body)) {
|
|
4221
4271
|
return (await new Request(body).arrayBuffer()).byteLength;
|
|
4222
4272
|
}
|
|
4223
|
-
if (utils$1.isArrayBufferView(body)) {
|
|
4273
|
+
if (utils$1.isArrayBufferView(body) || utils$1.isArrayBuffer(body)) {
|
|
4224
4274
|
return body.byteLength;
|
|
4225
4275
|
}
|
|
4226
4276
|
if (utils$1.isURLSearchParams(body)) {
|
|
@@ -4271,14 +4321,15 @@ const fetchAdapter = isFetchSupported && (async (config) => {
|
|
|
4271
4321
|
headers.setContentType(contentTypeHeader);
|
|
4272
4322
|
}
|
|
4273
4323
|
if (_request.body) {
|
|
4274
|
-
|
|
4324
|
+
const [onProgress, flush] = progressEventDecorator(
|
|
4275
4325
|
requestContentLength,
|
|
4276
|
-
progressEventReducer(onUploadProgress)
|
|
4277
|
-
)
|
|
4326
|
+
progressEventReducer(asyncDecorator(onUploadProgress))
|
|
4327
|
+
);
|
|
4328
|
+
data2 = trackStream(_request.body, DEFAULT_CHUNK_SIZE, onProgress, flush, encodeText);
|
|
4278
4329
|
}
|
|
4279
4330
|
}
|
|
4280
4331
|
if (!utils$1.isString(withCredentials)) {
|
|
4281
|
-
withCredentials = withCredentials ? "
|
|
4332
|
+
withCredentials = withCredentials ? "include" : "omit";
|
|
4282
4333
|
}
|
|
4283
4334
|
request = new Request(url, {
|
|
4284
4335
|
...fetchOptions,
|
|
@@ -4287,7 +4338,7 @@ const fetchAdapter = isFetchSupported && (async (config) => {
|
|
|
4287
4338
|
headers: headers.normalize().toJSON(),
|
|
4288
4339
|
body: data2,
|
|
4289
4340
|
duplex: "half",
|
|
4290
|
-
withCredentials
|
|
4341
|
+
credentials: withCredentials
|
|
4291
4342
|
});
|
|
4292
4343
|
let response = await fetch(request);
|
|
4293
4344
|
const isStreamResponse = supportsResponseStream && (responseType === "stream" || responseType === "response");
|
|
@@ -4297,11 +4348,15 @@ const fetchAdapter = isFetchSupported && (async (config) => {
|
|
|
4297
4348
|
options[prop3] = response[prop3];
|
|
4298
4349
|
});
|
|
4299
4350
|
const responseContentLength = utils$1.toFiniteNumber(response.headers.get("content-length"));
|
|
4351
|
+
const [onProgress, flush] = onDownloadProgress && progressEventDecorator(
|
|
4352
|
+
responseContentLength,
|
|
4353
|
+
progressEventReducer(asyncDecorator(onDownloadProgress), true)
|
|
4354
|
+
) || [];
|
|
4300
4355
|
response = new Response(
|
|
4301
|
-
trackStream(response.body, DEFAULT_CHUNK_SIZE,
|
|
4302
|
-
|
|
4303
|
-
|
|
4304
|
-
|
|
4356
|
+
trackStream(response.body, DEFAULT_CHUNK_SIZE, onProgress, () => {
|
|
4357
|
+
flush && flush();
|
|
4358
|
+
isStreamResponse && onFinish();
|
|
4359
|
+
}, encodeText),
|
|
4305
4360
|
options
|
|
4306
4361
|
);
|
|
4307
4362
|
}
|
|
@@ -4427,7 +4482,7 @@ function dispatchRequest(config) {
|
|
|
4427
4482
|
return Promise.reject(reason);
|
|
4428
4483
|
});
|
|
4429
4484
|
}
|
|
4430
|
-
const VERSION = "1.7.
|
|
4485
|
+
const VERSION = "1.7.3";
|
|
4431
4486
|
const validators$1 = {};
|
|
4432
4487
|
["object", "boolean", "number", "function", "string", "symbol"].forEach((type3, i2) => {
|
|
4433
4488
|
validators$1[type3] = function validator2(thing) {
|
|
@@ -5079,6 +5134,7 @@ class Bagel {
|
|
|
5079
5134
|
const formData = new FormData();
|
|
5080
5135
|
formData.append("file", file);
|
|
5081
5136
|
let url = "/static_files/upload";
|
|
5137
|
+
console.log(options == null ? void 0 : options.topic);
|
|
5082
5138
|
if (options == null ? void 0 : options.topic)
|
|
5083
5139
|
url = `/static_files/upload?topic=${options.topic}`;
|
|
5084
5140
|
const { data: data2 } = await axios.post(url, formData, {
|
|
@@ -45858,18 +45914,26 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
45858
45914
|
}));
|
|
45859
45915
|
const phone = useModel(__props, "modelValue", {
|
|
45860
45916
|
set: (value) => {
|
|
45861
|
-
|
|
45862
|
-
if (
|
|
45863
|
-
|
|
45917
|
+
let maybeFormatted = value;
|
|
45918
|
+
if (value.length > 5) {
|
|
45919
|
+
maybeFormatted = formatPhone(`${value}`);
|
|
45920
|
+
if (!maybeFormatted) {
|
|
45921
|
+
emit2("update:modelValue", "");
|
|
45922
|
+
return "";
|
|
45923
|
+
}
|
|
45924
|
+
}
|
|
45925
|
+
emit2("update:modelValue", maybeFormatted);
|
|
45864
45926
|
debounce$2(() => {
|
|
45865
|
-
emit2("debounce",
|
|
45927
|
+
emit2("debounce", maybeFormatted);
|
|
45866
45928
|
}, props2.debounceDelay);
|
|
45867
|
-
return
|
|
45868
|
-
}
|
|
45929
|
+
return maybeFormatted;
|
|
45930
|
+
},
|
|
45931
|
+
get: (value) => value
|
|
45869
45932
|
});
|
|
45870
45933
|
function formatPhone(val) {
|
|
45871
45934
|
var _a2;
|
|
45872
45935
|
const phoneNumber = parsePhoneNumber(val, parseArgs.value);
|
|
45936
|
+
console.log("Phone Number:", phoneNumber);
|
|
45873
45937
|
if (!phoneNumber) {
|
|
45874
45938
|
const dialCode = ((_a2 = sortedCountries.value.find((c2) => c2.iso2 === activeCountryCode.value)) == null ? void 0 : _a2.dialCode) || "";
|
|
45875
45939
|
if (props2.mode === "INTERNATIONAL") return `+${dialCode}`;
|
|
@@ -46077,7 +46141,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
46077
46141
|
};
|
|
46078
46142
|
}
|
|
46079
46143
|
});
|
|
46080
|
-
const TelInput = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["__scopeId", "data-v-
|
|
46144
|
+
const TelInput = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["__scopeId", "data-v-4c2ef2c5"]]);
|
|
46081
46145
|
/*!
|
|
46082
46146
|
* Signature Pad v5.0.2 | https://github.com/szimek/signature_pad
|
|
46083
46147
|
* (c) 2024 Szymon Nowak | Released under the MIT license
|
|
@@ -48104,10 +48168,10 @@ var omit = /* @__PURE__ */ _curry2(function omit2(names, obj) {
|
|
|
48104
48168
|
return result2;
|
|
48105
48169
|
});
|
|
48106
48170
|
var omit$1 = omit;
|
|
48107
|
-
var pickBy = /* @__PURE__ */ _curry2(function pickBy2(
|
|
48171
|
+
var pickBy = /* @__PURE__ */ _curry2(function pickBy2(test2, obj) {
|
|
48108
48172
|
var result2 = {};
|
|
48109
48173
|
for (var prop3 in obj) {
|
|
48110
|
-
if (
|
|
48174
|
+
if (test2(obj[prop3], prop3, obj)) {
|
|
48111
48175
|
result2[prop3] = obj[prop3];
|
|
48112
48176
|
}
|
|
48113
48177
|
}
|
package/dist/style.css
CHANGED
|
@@ -2053,7 +2053,7 @@ p {
|
|
|
2053
2053
|
border-radius: var(--input-border-radius);
|
|
2054
2054
|
}
|
|
2055
2055
|
|
|
2056
|
-
.tel-input[data-v-
|
|
2056
|
+
.tel-input[data-v-4c2ef2c5] {
|
|
2057
2057
|
direction: ltr;
|
|
2058
2058
|
text-align: left;
|
|
2059
2059
|
background: var(--input-bg);
|
|
@@ -2064,21 +2064,21 @@ p {
|
|
|
2064
2064
|
min-width: calc(var(--input-height) * 3);
|
|
2065
2065
|
width: 100%;
|
|
2066
2066
|
}
|
|
2067
|
-
.tel-input[data-v-
|
|
2067
|
+
.tel-input[data-v-4c2ef2c5]:focus-within {
|
|
2068
2068
|
outline: none;
|
|
2069
2069
|
box-shadow: inset 0 0 10px #00000012;
|
|
2070
2070
|
}
|
|
2071
|
-
.tel-input input[data-v-
|
|
2071
|
+
.tel-input input[data-v-4c2ef2c5] {
|
|
2072
2072
|
background: transparent;
|
|
2073
2073
|
}
|
|
2074
|
-
.tel-input input[data-v-
|
|
2074
|
+
.tel-input input[data-v-4c2ef2c5]:focus-visible {
|
|
2075
2075
|
box-shadow: none;
|
|
2076
2076
|
}
|
|
2077
|
-
.input_country-code[data-v-
|
|
2077
|
+
.input_country-code[data-v-4c2ef2c5] {
|
|
2078
2078
|
font-size: var(--input-font-size);
|
|
2079
2079
|
color: var(--input-color);
|
|
2080
2080
|
}
|
|
2081
|
-
.tel-country[data-v-
|
|
2081
|
+
.tel-country[data-v-4c2ef2c5] {
|
|
2082
2082
|
font-size: var(--input-font-size);
|
|
2083
2083
|
max-width: 200px;
|
|
2084
2084
|
white-space: nowrap;
|
|
@@ -2087,7 +2087,7 @@ p {
|
|
|
2087
2087
|
margin-top: 0;
|
|
2088
2088
|
margin-bottom: 0;
|
|
2089
2089
|
}
|
|
2090
|
-
.tel-countryp-dropdown[data-v-
|
|
2090
|
+
.tel-countryp-dropdown[data-v-4c2ef2c5] {
|
|
2091
2091
|
direction: ltr;
|
|
2092
2092
|
text-align: left;
|
|
2093
2093
|
}
|
package/dist/utils/objects.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { BagelField } from '..';
|
|
2
|
+
|
|
2
3
|
export declare function getPropByPath(obj: Record<string, any>, propPath?: string, bagelField?: BagelField): {};
|
|
3
4
|
export declare function setPropByPath(obj: Record<string, any>, path?: string, value?: any): void;
|
|
4
5
|
//# sourceMappingURL=objects.d.ts.map
|
package/package.json
CHANGED
|
@@ -170,17 +170,24 @@ const parseArgs = $computed(() => ({
|
|
|
170
170
|
const phone = defineModel<string>('modelValue', {
|
|
171
171
|
default: '',
|
|
172
172
|
set: (value) => {
|
|
173
|
-
|
|
174
|
-
if (
|
|
173
|
+
let maybeFormatted = value
|
|
174
|
+
if (value.length > 5) {
|
|
175
|
+
maybeFormatted = formatPhone(`${value}`)
|
|
175
176
|
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
177
|
+
if (!maybeFormatted) { emit('update:modelValue', ''); return '' }
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
emit('update:modelValue', maybeFormatted)
|
|
181
|
+
debounce(() => { emit('debounce', maybeFormatted) }, props.debounceDelay)
|
|
182
|
+
return maybeFormatted
|
|
179
183
|
},
|
|
184
|
+
get: value => value,
|
|
180
185
|
})
|
|
181
186
|
|
|
182
187
|
function formatPhone(val: string): string {
|
|
183
188
|
const phoneNumber = parsePhoneNumberFromString(val, parseArgs)
|
|
189
|
+
console.log('Phone Number:', phoneNumber)
|
|
190
|
+
|
|
184
191
|
if (!phoneNumber) {
|
|
185
192
|
const dialCode
|
|
186
193
|
= sortedCountries.find(c => c.iso2 === activeCountryCode)?.dialCode || ''
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>, {
|
|
2
|
-
trigger?(_: {}): any;
|
|
3
|
-
}>;
|
|
4
|
-
export default _default;
|
|
5
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
6
|
-
new (): {
|
|
7
|
-
$slots: S;
|
|
8
|
-
};
|
|
9
|
-
};
|
|
10
|
-
//# sourceMappingURL=Popover.vue.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Popover.vue.d.ts","sourceRoot":"","sources":["../../src/components/Popover.vue"],"names":[],"mappings":"AAoBA;AAEA,OAAO,6BAA6B,CAAC;;;;AAmHrC,wBAAwG;AACxG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
|