@thunderid/vue 0.13.1 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.cjs +445 -27
- package/dist/components/actions/SignInButton.d.ts +15 -0
- package/dist/components/actions/SignInButton.d.ts.map +1 -1
- package/dist/components/actions/SignUpButton.d.ts +15 -0
- package/dist/components/actions/SignUpButton.d.ts.map +1 -1
- package/dist/components/adapters/GoogleButton.d.ts.map +1 -1
- package/dist/components/factories/FieldFactory.d.ts +2 -0
- package/dist/components/factories/FieldFactory.d.ts.map +1 -1
- package/dist/components/primitives/OtpField/OtpField.d.ts.map +1 -1
- package/dist/index.js +445 -27
- package/package.json +2 -2
package/dist/cjs/index.cjs
CHANGED
|
@@ -4400,6 +4400,8 @@ var DatePicker_default = DatePicker;
|
|
|
4400
4400
|
|
|
4401
4401
|
//#endregion
|
|
4402
4402
|
//#region src/components/primitives/OtpField/OtpField.ts
|
|
4403
|
+
const NON_NUMERIC_OTP_CHARS = /[^0-9]/g;
|
|
4404
|
+
const NON_ALPHANUMERIC_OTP_CHARS = /[^0-9A-Z]/g;
|
|
4403
4405
|
const OtpField = (0, vue.defineComponent)({
|
|
4404
4406
|
name: "OtpField",
|
|
4405
4407
|
props: {
|
|
@@ -4427,6 +4429,10 @@ const OtpField = (0, vue.defineComponent)({
|
|
|
4427
4429
|
default: void 0,
|
|
4428
4430
|
type: String
|
|
4429
4431
|
},
|
|
4432
|
+
numericOnly: {
|
|
4433
|
+
default: true,
|
|
4434
|
+
type: Boolean
|
|
4435
|
+
},
|
|
4430
4436
|
required: {
|
|
4431
4437
|
default: false,
|
|
4432
4438
|
type: Boolean
|
|
@@ -4440,7 +4446,7 @@ const OtpField = (0, vue.defineComponent)({
|
|
|
4440
4446
|
};
|
|
4441
4447
|
const handleInput = (index, e) => {
|
|
4442
4448
|
const target = e.target;
|
|
4443
|
-
const val = target.value.replace(
|
|
4449
|
+
const val = props.numericOnly ? target.value.replace(NON_NUMERIC_OTP_CHARS, "").slice(0, 1) : target.value.toUpperCase().replace(NON_ALPHANUMERIC_OTP_CHARS, "").slice(0, 1);
|
|
4444
4450
|
target.value = val;
|
|
4445
4451
|
const current = (props.modelValue || "").split("");
|
|
4446
4452
|
while (current.length < props.length) current.push("");
|
|
@@ -4463,7 +4469,7 @@ const OtpField = (0, vue.defineComponent)({
|
|
|
4463
4469
|
"aria-label": `Digit ${i + 1}`,
|
|
4464
4470
|
class: (0, __thunderid_browser.withVendorCSSClassPrefix)("otp-field__digit"),
|
|
4465
4471
|
disabled: props.disabled,
|
|
4466
|
-
inputmode: "numeric",
|
|
4472
|
+
inputmode: props.numericOnly ? "numeric" : "text",
|
|
4467
4473
|
key: i,
|
|
4468
4474
|
maxlength: 1,
|
|
4469
4475
|
onInput: (e) => handleInput(i, e),
|
|
@@ -4715,13 +4721,34 @@ var BaseSignInButton_default = BaseSignInButton;
|
|
|
4715
4721
|
*
|
|
4716
4722
|
* If a custom `signInUrl` is configured, navigates to it instead.
|
|
4717
4723
|
* Falls back to i18n translation for the button text.
|
|
4724
|
+
*
|
|
4725
|
+
* By default, slot content is rendered *inside* the styled button (matching
|
|
4726
|
+
* {@link BaseSignInButton}'s convention) — the click handler and styling are
|
|
4727
|
+
* wired up for you.
|
|
4728
|
+
*
|
|
4729
|
+
* @example
|
|
4730
|
+
* <!-- Default: content is wrapped in the styled, click-wired button -->
|
|
4731
|
+
* <SignInButton>Sign In</SignInButton>
|
|
4732
|
+
* <SignInButton v-slot="{ isLoading }">{{ isLoading ? 'Signing in…' : 'Sign in' }}</SignInButton>
|
|
4733
|
+
*
|
|
4734
|
+
* @example
|
|
4735
|
+
* <!-- asChild: full control — you render the element and wire the click yourself -->
|
|
4736
|
+
* <SignInButton as-child v-slot="{ signIn, isLoading }">
|
|
4737
|
+
* <button @click="signIn" :disabled="isLoading">Sign In</button>
|
|
4738
|
+
* </SignInButton>
|
|
4718
4739
|
*/
|
|
4719
4740
|
const SignInButton = (0, vue.defineComponent)({
|
|
4720
4741
|
name: "SignInButton",
|
|
4721
|
-
props: {
|
|
4722
|
-
|
|
4723
|
-
|
|
4724
|
-
|
|
4742
|
+
props: {
|
|
4743
|
+
asChild: {
|
|
4744
|
+
default: false,
|
|
4745
|
+
type: Boolean
|
|
4746
|
+
},
|
|
4747
|
+
signInOptions: {
|
|
4748
|
+
default: void 0,
|
|
4749
|
+
type: Object
|
|
4750
|
+
}
|
|
4751
|
+
},
|
|
4725
4752
|
emits: ["click", "error"],
|
|
4726
4753
|
setup(props, { slots, emit, attrs }) {
|
|
4727
4754
|
const { signIn, signInUrl, signInOptions: contextSignInOptions } = useThunderID_default();
|
|
@@ -4740,19 +4767,23 @@ const SignInButton = (0, vue.defineComponent)({
|
|
|
4740
4767
|
}
|
|
4741
4768
|
};
|
|
4742
4769
|
return () => {
|
|
4743
|
-
if (slots["default"]) {
|
|
4770
|
+
if (props.asChild && slots["default"]) {
|
|
4744
4771
|
const nodes = slots["default"]({
|
|
4745
4772
|
isLoading: isLoading.value,
|
|
4746
4773
|
signIn: handleSignIn
|
|
4747
4774
|
});
|
|
4748
4775
|
return nodes.length === 1 ? nodes[0] : (0, vue.h)(vue.Fragment, null, nodes);
|
|
4749
4776
|
}
|
|
4777
|
+
const slotContent = slots["default"] ? () => slots["default"]({
|
|
4778
|
+
isLoading: isLoading.value,
|
|
4779
|
+
signIn: handleSignIn
|
|
4780
|
+
}) : void 0;
|
|
4750
4781
|
return (0, vue.h)(BaseSignInButton_default, {
|
|
4751
4782
|
class: attrs.class,
|
|
4752
4783
|
isLoading: isLoading.value,
|
|
4753
4784
|
onClick: handleSignIn,
|
|
4754
4785
|
style: attrs.style
|
|
4755
|
-
});
|
|
4786
|
+
}, slotContent);
|
|
4756
4787
|
};
|
|
4757
4788
|
}
|
|
4758
4789
|
});
|
|
@@ -4919,11 +4950,30 @@ var BaseSignUpButton_default = BaseSignUpButton;
|
|
|
4919
4950
|
*
|
|
4920
4951
|
* If a custom `signUpUrl` is configured, navigates to it instead.
|
|
4921
4952
|
* Falls back to i18n translation for the button text.
|
|
4953
|
+
*
|
|
4954
|
+
* By default, slot content is rendered *inside* the styled button (matching
|
|
4955
|
+
* {@link BaseSignUpButton}'s convention) — the click handler and styling are
|
|
4956
|
+
* wired up for you.
|
|
4957
|
+
*
|
|
4958
|
+
* @example
|
|
4959
|
+
* <!-- Default: content is wrapped in the styled, click-wired button -->
|
|
4960
|
+
* <SignUpButton>Sign Up</SignUpButton>
|
|
4961
|
+
* <SignUpButton v-slot="{ isLoading }">{{ isLoading ? 'Signing up…' : 'Sign up' }}</SignUpButton>
|
|
4962
|
+
*
|
|
4963
|
+
* @example
|
|
4964
|
+
* <!-- asChild: full control — you render the element and wire the click yourself -->
|
|
4965
|
+
* <SignUpButton as-child v-slot="{ signUp, isLoading }">
|
|
4966
|
+
* <button @click="signUp" :disabled="isLoading">Sign Up</button>
|
|
4967
|
+
* </SignUpButton>
|
|
4922
4968
|
*/
|
|
4923
4969
|
const SignUpButton = (0, vue.defineComponent)({
|
|
4924
4970
|
name: "SignUpButton",
|
|
4971
|
+
props: { asChild: {
|
|
4972
|
+
default: false,
|
|
4973
|
+
type: Boolean
|
|
4974
|
+
} },
|
|
4925
4975
|
emits: ["click", "error"],
|
|
4926
|
-
setup(
|
|
4976
|
+
setup(props, { slots, emit, attrs }) {
|
|
4927
4977
|
const { signUp, signUpUrl } = useThunderID_default();
|
|
4928
4978
|
const isLoading = (0, vue.ref)(false);
|
|
4929
4979
|
const handleSignUp = async (e) => {
|
|
@@ -4940,19 +4990,23 @@ const SignUpButton = (0, vue.defineComponent)({
|
|
|
4940
4990
|
}
|
|
4941
4991
|
};
|
|
4942
4992
|
return () => {
|
|
4943
|
-
if (slots["default"]) {
|
|
4993
|
+
if (props.asChild && slots["default"]) {
|
|
4944
4994
|
const nodes = slots["default"]({
|
|
4945
4995
|
isLoading: isLoading.value,
|
|
4946
4996
|
signUp: handleSignUp
|
|
4947
4997
|
});
|
|
4948
4998
|
return nodes.length === 1 ? nodes[0] : (0, vue.h)(vue.Fragment, null, nodes);
|
|
4949
4999
|
}
|
|
5000
|
+
const slotContent = slots["default"] ? () => slots["default"]({
|
|
5001
|
+
isLoading: isLoading.value,
|
|
5002
|
+
signUp: handleSignUp
|
|
5003
|
+
}) : void 0;
|
|
4950
5004
|
return (0, vue.h)(BaseSignUpButton_default, {
|
|
4951
5005
|
class: attrs.class,
|
|
4952
5006
|
isLoading: isLoading.value,
|
|
4953
5007
|
onClick: handleSignUp,
|
|
4954
5008
|
style: attrs.style
|
|
4955
|
-
});
|
|
5009
|
+
}, slotContent);
|
|
4956
5010
|
};
|
|
4957
5011
|
}
|
|
4958
5012
|
});
|
|
@@ -5158,31 +5212,393 @@ const GoogleButton = (0, vue.defineComponent)({
|
|
|
5158
5212
|
const { t } = useI18n_default();
|
|
5159
5213
|
const googleIcon = () => (0, vue.h)("svg", {
|
|
5160
5214
|
height: "18",
|
|
5161
|
-
viewBox: "0 0
|
|
5215
|
+
viewBox: "0 0 268.1522 273.8827",
|
|
5162
5216
|
width: "18",
|
|
5163
5217
|
xmlns: "http://www.w3.org/2000/svg"
|
|
5164
|
-
}, [(0, vue.h)("
|
|
5218
|
+
}, [(0, vue.h)("defs", {}, [
|
|
5219
|
+
(0, vue.h)("linearGradient", { id: "google-btn-a" }, [(0, vue.h)("stop", {
|
|
5220
|
+
offset: "0",
|
|
5221
|
+
"stop-color": "#0fbc5c"
|
|
5222
|
+
}), (0, vue.h)("stop", {
|
|
5223
|
+
offset: "1",
|
|
5224
|
+
"stop-color": "#0cba65"
|
|
5225
|
+
})]),
|
|
5226
|
+
(0, vue.h)("linearGradient", { id: "google-btn-g" }, [
|
|
5227
|
+
(0, vue.h)("stop", {
|
|
5228
|
+
offset: ".2312727",
|
|
5229
|
+
"stop-color": "#0fbc5f"
|
|
5230
|
+
}),
|
|
5231
|
+
(0, vue.h)("stop", {
|
|
5232
|
+
offset: ".3115468",
|
|
5233
|
+
"stop-color": "#0fbc5f"
|
|
5234
|
+
}),
|
|
5235
|
+
(0, vue.h)("stop", {
|
|
5236
|
+
offset: ".3660131",
|
|
5237
|
+
"stop-color": "#0fbc5e"
|
|
5238
|
+
}),
|
|
5239
|
+
(0, vue.h)("stop", {
|
|
5240
|
+
offset: ".4575163",
|
|
5241
|
+
"stop-color": "#0fbc5d"
|
|
5242
|
+
}),
|
|
5243
|
+
(0, vue.h)("stop", {
|
|
5244
|
+
offset: ".540305",
|
|
5245
|
+
"stop-color": "#12bc58"
|
|
5246
|
+
}),
|
|
5247
|
+
(0, vue.h)("stop", {
|
|
5248
|
+
offset: ".6993464",
|
|
5249
|
+
"stop-color": "#28bf3c"
|
|
5250
|
+
}),
|
|
5251
|
+
(0, vue.h)("stop", {
|
|
5252
|
+
offset: ".7712418",
|
|
5253
|
+
"stop-color": "#38c02b"
|
|
5254
|
+
}),
|
|
5255
|
+
(0, vue.h)("stop", {
|
|
5256
|
+
offset: ".8605665",
|
|
5257
|
+
"stop-color": "#52c218"
|
|
5258
|
+
}),
|
|
5259
|
+
(0, vue.h)("stop", {
|
|
5260
|
+
offset: ".9150327",
|
|
5261
|
+
"stop-color": "#67c30f"
|
|
5262
|
+
}),
|
|
5263
|
+
(0, vue.h)("stop", {
|
|
5264
|
+
offset: "1",
|
|
5265
|
+
"stop-color": "#86c504"
|
|
5266
|
+
})
|
|
5267
|
+
]),
|
|
5268
|
+
(0, vue.h)("linearGradient", { id: "google-btn-h" }, [
|
|
5269
|
+
(0, vue.h)("stop", {
|
|
5270
|
+
offset: ".1416122",
|
|
5271
|
+
"stop-color": "#1abd4d"
|
|
5272
|
+
}),
|
|
5273
|
+
(0, vue.h)("stop", {
|
|
5274
|
+
offset: ".2475151",
|
|
5275
|
+
"stop-color": "#6ec30d"
|
|
5276
|
+
}),
|
|
5277
|
+
(0, vue.h)("stop", {
|
|
5278
|
+
offset: ".3115468",
|
|
5279
|
+
"stop-color": "#8ac502"
|
|
5280
|
+
}),
|
|
5281
|
+
(0, vue.h)("stop", {
|
|
5282
|
+
offset: ".3660131",
|
|
5283
|
+
"stop-color": "#a2c600"
|
|
5284
|
+
}),
|
|
5285
|
+
(0, vue.h)("stop", {
|
|
5286
|
+
offset: ".4456735",
|
|
5287
|
+
"stop-color": "#c8c903"
|
|
5288
|
+
}),
|
|
5289
|
+
(0, vue.h)("stop", {
|
|
5290
|
+
offset: ".540305",
|
|
5291
|
+
"stop-color": "#ebcb03"
|
|
5292
|
+
}),
|
|
5293
|
+
(0, vue.h)("stop", {
|
|
5294
|
+
offset: ".6156363",
|
|
5295
|
+
"stop-color": "#f7cd07"
|
|
5296
|
+
}),
|
|
5297
|
+
(0, vue.h)("stop", {
|
|
5298
|
+
offset: ".6993454",
|
|
5299
|
+
"stop-color": "#fdcd04"
|
|
5300
|
+
}),
|
|
5301
|
+
(0, vue.h)("stop", {
|
|
5302
|
+
offset: ".7712418",
|
|
5303
|
+
"stop-color": "#fdce05"
|
|
5304
|
+
}),
|
|
5305
|
+
(0, vue.h)("stop", {
|
|
5306
|
+
offset: ".8605661",
|
|
5307
|
+
"stop-color": "#ffce0a"
|
|
5308
|
+
})
|
|
5309
|
+
]),
|
|
5310
|
+
(0, vue.h)("linearGradient", { id: "google-btn-f" }, [
|
|
5311
|
+
(0, vue.h)("stop", {
|
|
5312
|
+
offset: ".3159041",
|
|
5313
|
+
"stop-color": "#ff4c3c"
|
|
5314
|
+
}),
|
|
5315
|
+
(0, vue.h)("stop", {
|
|
5316
|
+
offset: ".6038179",
|
|
5317
|
+
"stop-color": "#ff692c"
|
|
5318
|
+
}),
|
|
5319
|
+
(0, vue.h)("stop", {
|
|
5320
|
+
offset: ".7268366",
|
|
5321
|
+
"stop-color": "#ff7825"
|
|
5322
|
+
}),
|
|
5323
|
+
(0, vue.h)("stop", {
|
|
5324
|
+
offset: ".884534",
|
|
5325
|
+
"stop-color": "#ff8d1b"
|
|
5326
|
+
}),
|
|
5327
|
+
(0, vue.h)("stop", {
|
|
5328
|
+
offset: "1",
|
|
5329
|
+
"stop-color": "#ff9f13"
|
|
5330
|
+
})
|
|
5331
|
+
]),
|
|
5332
|
+
(0, vue.h)("linearGradient", { id: "google-btn-b" }, [
|
|
5333
|
+
(0, vue.h)("stop", {
|
|
5334
|
+
offset: ".2312727",
|
|
5335
|
+
"stop-color": "#ff4541"
|
|
5336
|
+
}),
|
|
5337
|
+
(0, vue.h)("stop", {
|
|
5338
|
+
offset: ".3115468",
|
|
5339
|
+
"stop-color": "#ff4540"
|
|
5340
|
+
}),
|
|
5341
|
+
(0, vue.h)("stop", {
|
|
5342
|
+
offset: ".4575163",
|
|
5343
|
+
"stop-color": "#ff4640"
|
|
5344
|
+
}),
|
|
5345
|
+
(0, vue.h)("stop", {
|
|
5346
|
+
offset: ".540305",
|
|
5347
|
+
"stop-color": "#ff473f"
|
|
5348
|
+
}),
|
|
5349
|
+
(0, vue.h)("stop", {
|
|
5350
|
+
offset: ".6993464",
|
|
5351
|
+
"stop-color": "#ff5138"
|
|
5352
|
+
}),
|
|
5353
|
+
(0, vue.h)("stop", {
|
|
5354
|
+
offset: ".7712418",
|
|
5355
|
+
"stop-color": "#ff5b33"
|
|
5356
|
+
}),
|
|
5357
|
+
(0, vue.h)("stop", {
|
|
5358
|
+
offset: ".8605665",
|
|
5359
|
+
"stop-color": "#ff6c29"
|
|
5360
|
+
}),
|
|
5361
|
+
(0, vue.h)("stop", {
|
|
5362
|
+
offset: "1",
|
|
5363
|
+
"stop-color": "#ff8c18"
|
|
5364
|
+
})
|
|
5365
|
+
]),
|
|
5366
|
+
(0, vue.h)("linearGradient", { id: "google-btn-d" }, [(0, vue.h)("stop", {
|
|
5367
|
+
offset: ".4084578",
|
|
5368
|
+
"stop-color": "#fb4e5a"
|
|
5369
|
+
}), (0, vue.h)("stop", {
|
|
5370
|
+
offset: "1",
|
|
5371
|
+
"stop-color": "#ff4540"
|
|
5372
|
+
})]),
|
|
5373
|
+
(0, vue.h)("linearGradient", { id: "google-btn-c" }, [
|
|
5374
|
+
(0, vue.h)("stop", {
|
|
5375
|
+
offset: ".1315461",
|
|
5376
|
+
"stop-color": "#0cba65"
|
|
5377
|
+
}),
|
|
5378
|
+
(0, vue.h)("stop", {
|
|
5379
|
+
offset: ".2097843",
|
|
5380
|
+
"stop-color": "#0bb86d"
|
|
5381
|
+
}),
|
|
5382
|
+
(0, vue.h)("stop", {
|
|
5383
|
+
offset: ".2972969",
|
|
5384
|
+
"stop-color": "#09b479"
|
|
5385
|
+
}),
|
|
5386
|
+
(0, vue.h)("stop", {
|
|
5387
|
+
offset: ".3962575",
|
|
5388
|
+
"stop-color": "#08ad93"
|
|
5389
|
+
}),
|
|
5390
|
+
(0, vue.h)("stop", {
|
|
5391
|
+
offset: ".4771242",
|
|
5392
|
+
"stop-color": "#0aa6a9"
|
|
5393
|
+
}),
|
|
5394
|
+
(0, vue.h)("stop", {
|
|
5395
|
+
offset: ".5684245",
|
|
5396
|
+
"stop-color": "#0d9cc6"
|
|
5397
|
+
}),
|
|
5398
|
+
(0, vue.h)("stop", {
|
|
5399
|
+
offset: ".667385",
|
|
5400
|
+
"stop-color": "#1893dd"
|
|
5401
|
+
}),
|
|
5402
|
+
(0, vue.h)("stop", {
|
|
5403
|
+
offset: ".7687273",
|
|
5404
|
+
"stop-color": "#258bf1"
|
|
5405
|
+
}),
|
|
5406
|
+
(0, vue.h)("stop", {
|
|
5407
|
+
offset: ".8585063",
|
|
5408
|
+
"stop-color": "#3086ff"
|
|
5409
|
+
})
|
|
5410
|
+
]),
|
|
5411
|
+
(0, vue.h)("linearGradient", { id: "google-btn-e" }, [
|
|
5412
|
+
(0, vue.h)("stop", {
|
|
5413
|
+
offset: ".3660131",
|
|
5414
|
+
"stop-color": "#ff4e3a"
|
|
5415
|
+
}),
|
|
5416
|
+
(0, vue.h)("stop", {
|
|
5417
|
+
offset: ".4575163",
|
|
5418
|
+
"stop-color": "#ff8a1b"
|
|
5419
|
+
}),
|
|
5420
|
+
(0, vue.h)("stop", {
|
|
5421
|
+
offset: ".540305",
|
|
5422
|
+
"stop-color": "#ffa312"
|
|
5423
|
+
}),
|
|
5424
|
+
(0, vue.h)("stop", {
|
|
5425
|
+
offset: ".6156363",
|
|
5426
|
+
"stop-color": "#ffb60c"
|
|
5427
|
+
}),
|
|
5428
|
+
(0, vue.h)("stop", {
|
|
5429
|
+
offset: ".7712418",
|
|
5430
|
+
"stop-color": "#ffcd0a"
|
|
5431
|
+
}),
|
|
5432
|
+
(0, vue.h)("stop", {
|
|
5433
|
+
offset: ".8605665",
|
|
5434
|
+
"stop-color": "#fecf0a"
|
|
5435
|
+
}),
|
|
5436
|
+
(0, vue.h)("stop", {
|
|
5437
|
+
offset: ".9150327",
|
|
5438
|
+
"stop-color": "#fecf08"
|
|
5439
|
+
}),
|
|
5440
|
+
(0, vue.h)("stop", {
|
|
5441
|
+
offset: "1",
|
|
5442
|
+
"stop-color": "#fdcd01"
|
|
5443
|
+
})
|
|
5444
|
+
]),
|
|
5445
|
+
(0, vue.h)("linearGradient", {
|
|
5446
|
+
href: "#google-btn-a",
|
|
5447
|
+
id: "google-btn-s",
|
|
5448
|
+
x1: "219.6997",
|
|
5449
|
+
y1: "329.5351",
|
|
5450
|
+
x2: "254.4673",
|
|
5451
|
+
y2: "329.5351",
|
|
5452
|
+
gradientUnits: "userSpaceOnUse"
|
|
5453
|
+
}),
|
|
5454
|
+
(0, vue.h)("radialGradient", {
|
|
5455
|
+
href: "#google-btn-b",
|
|
5456
|
+
id: "google-btn-m",
|
|
5457
|
+
gradientUnits: "userSpaceOnUse",
|
|
5458
|
+
gradientTransform: "matrix(-1.936885,1.043001,1.455731,2.555422,290.5254,-400.6338)",
|
|
5459
|
+
cx: "109.6267",
|
|
5460
|
+
cy: "135.8619",
|
|
5461
|
+
fx: "109.6267",
|
|
5462
|
+
fy: "135.8619",
|
|
5463
|
+
r: "71.46001"
|
|
5464
|
+
}),
|
|
5465
|
+
(0, vue.h)("radialGradient", {
|
|
5466
|
+
href: "#google-btn-c",
|
|
5467
|
+
id: "google-btn-n",
|
|
5468
|
+
gradientUnits: "userSpaceOnUse",
|
|
5469
|
+
gradientTransform: "matrix(-3.512595,-4.45809,-1.692547,1.260616,870.8006,191.554)",
|
|
5470
|
+
cx: "45.25866",
|
|
5471
|
+
cy: "279.2738",
|
|
5472
|
+
fx: "45.25866",
|
|
5473
|
+
fy: "279.2738",
|
|
5474
|
+
r: "71.46001"
|
|
5475
|
+
}),
|
|
5476
|
+
(0, vue.h)("radialGradient", {
|
|
5477
|
+
href: "#google-btn-d",
|
|
5478
|
+
id: "google-btn-l",
|
|
5479
|
+
cx: "304.0166",
|
|
5480
|
+
cy: "118.0089",
|
|
5481
|
+
fx: "304.0166",
|
|
5482
|
+
fy: "118.0089",
|
|
5483
|
+
r: "47.85445",
|
|
5484
|
+
gradientTransform: "matrix(2.064353,-4.926832e-6,-2.901531e-6,2.592041,-297.6788,-151.7469)",
|
|
5485
|
+
gradientUnits: "userSpaceOnUse"
|
|
5486
|
+
}),
|
|
5487
|
+
(0, vue.h)("radialGradient", {
|
|
5488
|
+
href: "#google-btn-e",
|
|
5489
|
+
id: "google-btn-o",
|
|
5490
|
+
gradientUnits: "userSpaceOnUse",
|
|
5491
|
+
gradientTransform: "matrix(-0.2485783,2.083138,2.962486,0.3341668,-255.1463,-331.1636)",
|
|
5492
|
+
cx: "181.001",
|
|
5493
|
+
cy: "177.2013",
|
|
5494
|
+
fx: "181.001",
|
|
5495
|
+
fy: "177.2013",
|
|
5496
|
+
r: "71.46001"
|
|
5497
|
+
}),
|
|
5498
|
+
(0, vue.h)("radialGradient", {
|
|
5499
|
+
href: "#google-btn-f",
|
|
5500
|
+
id: "google-btn-p",
|
|
5501
|
+
cx: "207.6733",
|
|
5502
|
+
cy: "108.0972",
|
|
5503
|
+
fx: "207.6733",
|
|
5504
|
+
fy: "108.0972",
|
|
5505
|
+
r: "41.1025",
|
|
5506
|
+
gradientTransform: "matrix(-1.249206,1.343263,-3.896837,-3.425693,880.5011,194.9051)",
|
|
5507
|
+
gradientUnits: "userSpaceOnUse"
|
|
5508
|
+
}),
|
|
5509
|
+
(0, vue.h)("radialGradient", {
|
|
5510
|
+
href: "#google-btn-g",
|
|
5511
|
+
id: "google-btn-r",
|
|
5512
|
+
gradientUnits: "userSpaceOnUse",
|
|
5513
|
+
gradientTransform: "matrix(-1.936885,-1.043001,1.455731,-2.555422,290.5254,838.6834)",
|
|
5514
|
+
cx: "109.6267",
|
|
5515
|
+
cy: "135.8619",
|
|
5516
|
+
fx: "109.6267",
|
|
5517
|
+
fy: "135.8619",
|
|
5518
|
+
r: "71.46001"
|
|
5519
|
+
}),
|
|
5520
|
+
(0, vue.h)("radialGradient", {
|
|
5521
|
+
href: "#google-btn-h",
|
|
5522
|
+
id: "google-btn-j",
|
|
5523
|
+
gradientUnits: "userSpaceOnUse",
|
|
5524
|
+
gradientTransform: "matrix(-0.081402,-1.93722,2.926737,-0.1162508,-215.1345,632.8606)",
|
|
5525
|
+
cx: "154.8697",
|
|
5526
|
+
cy: "145.9691",
|
|
5527
|
+
fx: "154.8697",
|
|
5528
|
+
fy: "145.9691",
|
|
5529
|
+
r: "71.46001"
|
|
5530
|
+
}),
|
|
5531
|
+
(0, vue.h)("filter", {
|
|
5532
|
+
id: "google-btn-q",
|
|
5533
|
+
x: "-.04842873",
|
|
5534
|
+
y: "-.0582241",
|
|
5535
|
+
width: "1.096857",
|
|
5536
|
+
height: "1.116448",
|
|
5537
|
+
"color-interpolation-filters": "sRGB"
|
|
5538
|
+
}, [(0, vue.h)("feGaussianBlur", { stdDeviation: "1.700914" })]),
|
|
5539
|
+
(0, vue.h)("filter", {
|
|
5540
|
+
id: "google-btn-k",
|
|
5541
|
+
x: "-.01670084",
|
|
5542
|
+
y: "-.01009856",
|
|
5543
|
+
width: "1.033402",
|
|
5544
|
+
height: "1.020197",
|
|
5545
|
+
"color-interpolation-filters": "sRGB"
|
|
5546
|
+
}, [(0, vue.h)("feGaussianBlur", { stdDeviation: ".2419367" })]),
|
|
5547
|
+
(0, vue.h)("clipPath", {
|
|
5548
|
+
clipPathUnits: "userSpaceOnUse",
|
|
5549
|
+
id: "google-btn-i"
|
|
5550
|
+
}, [(0, vue.h)("path", {
|
|
5551
|
+
d: "M371.3784 193.2406H237.0825v53.4375h77.167c-1.2405 7.5627-4.0259 15.0024-8.1049 21.7862-4.6734 7.7723-10.4511 13.6895-16.373 18.1957-17.7389 13.4983-38.42 16.2584-52.7828 16.2584-36.2824 0-67.2833-23.2865-79.2844-54.9287-.4843-1.1482-.8059-2.3344-1.1975-3.5068-2.652-8.0533-4.101-16.5825-4.101-25.4474 0-9.226 1.5691-18.0575 4.4301-26.3985 11.2851-32.8967 42.9849-57.4674 80.1789-57.4674 7.4811 0 14.6854.8843 21.5173 2.6481 15.6135 4.0309 26.6578 11.9698 33.4252 18.2494l40.834-39.7111c-24.839-22.616-57.2194-36.3201-95.8444-36.3201-30.8782-.00066-59.3863 9.55308-82.7477 25.6992-18.9454 13.0941-34.4833 30.6254-44.9695 50.9861-9.75366 18.8785-15.09441 39.7994-15.09441 62.2934 0 22.495 5.34891 43.6334 15.10261 62.3374v.126c10.3023 19.8567 25.3678 36.9537 43.6783 49.9878 15.9962 11.3866 44.6789 26.5516 84.0307 26.5516 22.6301 0 42.6867-4.0517 60.3748-11.6447 12.76-5.4775 24.0655-12.6217 34.3012-21.8036 13.5247-12.1323 24.1168-27.1388 31.3465-44.4041 7.2297-17.2654 11.097-36.7895 11.097-57.957 0-9.858-.9971-19.8694-2.6881-28.9684Z",
|
|
5552
|
+
fill: "#000"
|
|
5553
|
+
})])
|
|
5554
|
+
]), (0, vue.h)("g", { transform: "matrix(0.957922,0,0,0.985255,-90.17436,-78.85577)" }, [(0, vue.h)("g", { "clip-path": "url(#google-btn-i)" }, [
|
|
5555
|
+
(0, vue.h)("path", {
|
|
5556
|
+
d: "M92.07563 219.9585c.14844 22.14 6.5014 44.983 16.11767 63.4234v.1269c6.9482 13.3919 16.4444 23.9704 27.2604 34.4518l65.326-23.67c-12.3593-6.2344-14.2452-10.0546-23.1048-17.0253-9.0537-9.0658-15.8015-19.4735-20.0038-31.677h-.1693l.1693-.1269c-2.7646-8.0587-3.0373-16.6129-3.1393-25.5029Z",
|
|
5557
|
+
fill: "url(#google-btn-j)",
|
|
5558
|
+
filter: "url(#google-btn-k)"
|
|
5559
|
+
}),
|
|
5560
|
+
(0, vue.h)("path", {
|
|
5561
|
+
d: "M237.0835 79.02491c-6.4568 22.52569-3.988 44.42139 0 57.16129 7.4561.0055 14.6388.8881 21.4494 2.6464 15.6135 4.0309 26.6566 11.97 33.424 18.2496l41.8794-40.7256c-24.8094-22.58904-54.6663-37.2961-96.7528-37.33169Z",
|
|
5562
|
+
fill: "url(#google-btn-l)",
|
|
5563
|
+
filter: "url(#google-btn-k)"
|
|
5564
|
+
}),
|
|
5565
|
+
(0, vue.h)("path", {
|
|
5566
|
+
d: "M236.9434 78.84678c-31.6709-.00068-60.9107 9.79833-84.8718 26.35902-8.8968 6.149-17.0612 13.2521-24.3311 21.1509-1.9045 17.7429 14.2569 39.5507 46.2615 39.3702 15.5284-17.9373 38.4946-29.5427 64.0561-29.5427.0233 0 .046.0019.0693.002l-1.0439-57.33536c-.0472-.00003-.0929-.00406-.1401-.00406Z",
|
|
5567
|
+
fill: "url(#google-btn-m)",
|
|
5568
|
+
filter: "url(#google-btn-k)"
|
|
5569
|
+
}),
|
|
5570
|
+
(0, vue.h)("path", {
|
|
5571
|
+
d: "m341.4751 226.3788-28.2685 19.2848c-1.2405 7.5627-4.0278 15.0023-8.1068 21.7861-4.6734 7.7723-10.4506 13.6898-16.3725 18.196-17.7022 13.4704-38.3286 16.2439-52.6877 16.2553-14.8415 25.1018-17.4435 37.6749 1.0439 57.9342 22.8762-.0167 43.157-4.1174 61.0458-11.7965 12.9312-5.551 24.3879-12.7913 34.7609-22.0964 13.7061-12.295 24.4421-27.5034 31.7688-45.0003 7.3267-17.497 11.2446-37.2822 11.2446-58.7336Z",
|
|
5572
|
+
fill: "url(#google-btn-n)",
|
|
5573
|
+
filter: "url(#google-btn-k)"
|
|
5574
|
+
}),
|
|
5575
|
+
(0, vue.h)("path", {
|
|
5576
|
+
d: "M234.9956 191.2104v57.4981h136.0062c1.1962-7.8745 5.1523-18.0644 5.1523-26.5001 0-9.858-.9963-21.899-2.6873-30.998Z",
|
|
5577
|
+
fill: "#3086ff",
|
|
5578
|
+
filter: "url(#google-btn-k)"
|
|
5579
|
+
}),
|
|
5165
5580
|
(0, vue.h)("path", {
|
|
5166
|
-
d: "
|
|
5167
|
-
fill: "#
|
|
5168
|
-
|
|
5581
|
+
d: "M128.3894 124.3268c-8.393 9.1191-15.5632 19.326-21.2483 30.3646-9.75351 18.8785-15.09402 41.8295-15.09402 64.3235 0 .317.02642.6271.02855.9436 4.31953 8.2244 59.66647 6.6495 62.45617 0-.0035-.3103-.0387-.6128-.0387-.9238 0-9.226 1.5696-16.0262 4.4306-24.3672 3.5294-10.2885 9.0557-19.7628 16.1223-27.9257 1.6019-2.0309 5.8748-6.3969 7.1214-9.0157.4749-.9975-.8621-1.5574-.9369-1.9085-.0836-.3927-1.8762-.0769-2.2778-.3694-1.2751-.9288-3.8001-1.4138-5.3334-1.8449-3.2772-.9215-8.7085-2.9536-11.7252-5.0601-9.5357-6.6586-24.417-14.6122-33.5047-24.2164Z",
|
|
5582
|
+
fill: "url(#google-btn-o)",
|
|
5583
|
+
filter: "url(#google-btn-k)"
|
|
5169
5584
|
}),
|
|
5170
5585
|
(0, vue.h)("path", {
|
|
5171
|
-
d: "
|
|
5172
|
-
fill: "#
|
|
5173
|
-
|
|
5586
|
+
d: "M162.0989 155.8569c22.1123 13.3013 28.4714-6.7139 43.173-12.9771L179.698 90.21568c-9.4075 3.92642-18.2957 8.80465-26.5426 14.50442-12.316 8.5122-23.192 18.8995-32.1763 30.7204Z",
|
|
5587
|
+
fill: "url(#google-btn-p)",
|
|
5588
|
+
filter: "url(#google-btn-q)"
|
|
5174
5589
|
}),
|
|
5175
5590
|
(0, vue.h)("path", {
|
|
5176
|
-
d: "
|
|
5177
|
-
fill: "#
|
|
5178
|
-
|
|
5591
|
+
d: "M171.0987 290.222c-29.6829 10.6413-34.3299 11.023-37.0622 29.2903 5.2213 5.0597 10.8312 9.74 16.7926 13.9835 15.9962 11.3867 46.766 26.5517 86.1178 26.5517.0462 0 .0904-.004.1366-.004v-59.1574c-.0298.0001-.064.002-.0938.002-14.7359 0-26.5113-3.8435-38.5848-10.5273-2.9768-1.6479-8.3775 2.7772-11.1229.799-3.7865-2.7284-12.8991 2.3508-16.1833-.9378Z",
|
|
5592
|
+
fill: "url(#google-btn-r)",
|
|
5593
|
+
filter: "url(#google-btn-k)"
|
|
5179
5594
|
}),
|
|
5180
5595
|
(0, vue.h)("path", {
|
|
5181
|
-
d: "
|
|
5182
|
-
|
|
5183
|
-
|
|
5596
|
+
d: "M219.6997 299.0227v59.9959c5.506.6402 11.2361 1.0289 17.2472 1.0289 6.0259 0 11.8556-.3073 17.5204-.8723v-59.7481c-6.3482 1.0777-12.3272 1.461-17.4776 1.461-5.9318 0-11.7005-.6858-17.29-1.8654Z",
|
|
5597
|
+
opacity: ".5",
|
|
5598
|
+
fill: "url(#google-btn-s)",
|
|
5599
|
+
filter: "url(#google-btn-k)"
|
|
5184
5600
|
})
|
|
5185
|
-
])]);
|
|
5601
|
+
])])]);
|
|
5186
5602
|
return () => (0, vue.h)(Button_default, {
|
|
5187
5603
|
...attrs,
|
|
5188
5604
|
color: "secondary",
|
|
@@ -5275,7 +5691,7 @@ const validateFieldValue = (value, type, required = false, touched = false) => {
|
|
|
5275
5691
|
* Factory function to create form field VNodes based on FieldType.
|
|
5276
5692
|
*/
|
|
5277
5693
|
const createField = (config) => {
|
|
5278
|
-
const { name, type, label, required, value, onChange, onBlur, disabled = false, error, className, options = [], touched = false, placeholder } = config;
|
|
5694
|
+
const { name, type, label, required, value, onChange, onBlur, disabled = false, error, className, options = [], touched = false, placeholder, length, numericOnly = true } = config;
|
|
5279
5695
|
const validationError = error || validateFieldValue(value, type, required, touched);
|
|
5280
5696
|
const commonProps = {
|
|
5281
5697
|
class: className,
|
|
@@ -5320,6 +5736,8 @@ const createField = (config) => {
|
|
|
5320
5736
|
}
|
|
5321
5737
|
case __thunderid_browser.FieldType.Otp: return (0, vue.h)(OtpField_default, {
|
|
5322
5738
|
...commonProps,
|
|
5739
|
+
...length ? { length } : {},
|
|
5740
|
+
numericOnly,
|
|
5323
5741
|
"onUpdate:modelValue": onChange
|
|
5324
5742
|
});
|
|
5325
5743
|
case __thunderid_browser.FieldType.Number: return (0, vue.h)(TextField_default, {
|
|
@@ -4,6 +4,21 @@ import { type Component } from 'vue';
|
|
|
4
4
|
*
|
|
5
5
|
* If a custom `signInUrl` is configured, navigates to it instead.
|
|
6
6
|
* Falls back to i18n translation for the button text.
|
|
7
|
+
*
|
|
8
|
+
* By default, slot content is rendered *inside* the styled button (matching
|
|
9
|
+
* {@link BaseSignInButton}'s convention) — the click handler and styling are
|
|
10
|
+
* wired up for you.
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* <!-- Default: content is wrapped in the styled, click-wired button -->
|
|
14
|
+
* <SignInButton>Sign In</SignInButton>
|
|
15
|
+
* <SignInButton v-slot="{ isLoading }">{{ isLoading ? 'Signing in…' : 'Sign in' }}</SignInButton>
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* <!-- asChild: full control — you render the element and wire the click yourself -->
|
|
19
|
+
* <SignInButton as-child v-slot="{ signIn, isLoading }">
|
|
20
|
+
* <button @click="signIn" :disabled="isLoading">Sign In</button>
|
|
21
|
+
* </SignInButton>
|
|
7
22
|
*/
|
|
8
23
|
declare const SignInButton: Component;
|
|
9
24
|
export default SignInButton;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SignInButton.d.ts","sourceRoot":"","sources":["../../../src/components/actions/SignInButton.ts"],"names":[],"mappings":"AAIA,OAAO,EAKL,KAAK,SAAS,EAKf,MAAM,KAAK,CAAC;AAIb
|
|
1
|
+
{"version":3,"file":"SignInButton.d.ts","sourceRoot":"","sources":["../../../src/components/actions/SignInButton.ts"],"names":[],"mappings":"AAIA,OAAO,EAKL,KAAK,SAAS,EAKf,MAAM,KAAK,CAAC;AAIb;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,QAAA,MAAM,YAAY,EAAE,SA6DlB,CAAC;AAEH,eAAe,YAAY,CAAC"}
|
|
@@ -4,6 +4,21 @@ import { type Component } from 'vue';
|
|
|
4
4
|
*
|
|
5
5
|
* If a custom `signUpUrl` is configured, navigates to it instead.
|
|
6
6
|
* Falls back to i18n translation for the button text.
|
|
7
|
+
*
|
|
8
|
+
* By default, slot content is rendered *inside* the styled button (matching
|
|
9
|
+
* {@link BaseSignUpButton}'s convention) — the click handler and styling are
|
|
10
|
+
* wired up for you.
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* <!-- Default: content is wrapped in the styled, click-wired button -->
|
|
14
|
+
* <SignUpButton>Sign Up</SignUpButton>
|
|
15
|
+
* <SignUpButton v-slot="{ isLoading }">{{ isLoading ? 'Signing up…' : 'Sign up' }}</SignUpButton>
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* <!-- asChild: full control — you render the element and wire the click yourself -->
|
|
19
|
+
* <SignUpButton as-child v-slot="{ signUp, isLoading }">
|
|
20
|
+
* <button @click="signUp" :disabled="isLoading">Sign Up</button>
|
|
21
|
+
* </SignUpButton>
|
|
7
22
|
*/
|
|
8
23
|
declare const SignUpButton: Component;
|
|
9
24
|
export default SignUpButton;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SignUpButton.d.ts","sourceRoot":"","sources":["../../../src/components/actions/SignUpButton.ts"],"names":[],"mappings":"AAIA,OAAO,EAAoC,KAAK,SAAS,EAA0C,MAAM,KAAK,CAAC;AAI/G
|
|
1
|
+
{"version":3,"file":"SignUpButton.d.ts","sourceRoot":"","sources":["../../../src/components/actions/SignUpButton.ts"],"names":[],"mappings":"AAIA,OAAO,EAAoC,KAAK,SAAS,EAA0C,MAAM,KAAK,CAAC;AAI/G;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,QAAA,MAAM,YAAY,EAAE,SAyDlB,CAAC;AAEH,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GoogleButton.d.ts","sourceRoot":"","sources":["../../../src/components/adapters/GoogleButton.ts"],"names":[],"mappings":"AAGA,OAAO,EAAqB,KAAK,SAAS,EAAgC,MAAM,KAAK,CAAC;AAItF;;;GAGG;AACH,QAAA,MAAM,YAAY,EAAE,
|
|
1
|
+
{"version":3,"file":"GoogleButton.d.ts","sourceRoot":"","sources":["../../../src/components/adapters/GoogleButton.ts"],"names":[],"mappings":"AAGA,OAAO,EAAqB,KAAK,SAAS,EAAgC,MAAM,KAAK,CAAC;AAItF;;;GAGG;AACH,QAAA,MAAM,YAAY,EAAE,SA6QlB,CAAC;AAEH,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldFactory.d.ts","sourceRoot":"","sources":["../../../src/components/factories/FieldFactory.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,SAAS,EAAC,MAAM,oBAAoB,CAAC;AAC7C,OAAO,EAAC,KAAK,SAAS,EAAiB,KAAK,KAAK,EAAqB,MAAM,KAAK,CAAC;AAKlF,OAAe,EAAC,KAAK,YAAY,EAAC,MAAM,6BAA6B,CAAC;AAGtE;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,OAAO,CAAC,EAAE,YAAY,EAAE,CAAC;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,IAAI,EAAE,SAAS,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;CACf;AAgBD;;GAEG;AACH,eAAO,MAAM,kBAAkB,GAC7B,OAAO,MAAM,EACb,MAAM,SAAS,EACf,kBAAgB,EAChB,iBAAe,KACd,MAAM,GAAG,IAsBX,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,WAAW,GAAI,QAAQ,WAAW,KAAG,
|
|
1
|
+
{"version":3,"file":"FieldFactory.d.ts","sourceRoot":"","sources":["../../../src/components/factories/FieldFactory.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,SAAS,EAAC,MAAM,oBAAoB,CAAC;AAC7C,OAAO,EAAC,KAAK,SAAS,EAAiB,KAAK,KAAK,EAAqB,MAAM,KAAK,CAAC;AAKlF,OAAe,EAAC,KAAK,YAAY,EAAC,MAAM,6BAA6B,CAAC;AAGtE;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,OAAO,CAAC,EAAE,YAAY,EAAE,CAAC;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,IAAI,EAAE,SAAS,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;CACf;AAgBD;;GAEG;AACH,eAAO,MAAM,kBAAkB,GAC7B,OAAO,MAAM,EACb,MAAM,SAAS,EACf,kBAAgB,EAChB,iBAAe,KACd,MAAM,GAAG,IAsBX,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,WAAW,GAAI,QAAQ,WAAW,KAAG,KAsHjD,CAAC;AAEF;;GAEG;AACH,QAAA,MAAM,YAAY,EAAE,SAkClB,CAAC;AAEH,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OtpField.d.ts","sourceRoot":"","sources":["../../../../src/components/primitives/OtpField/OtpField.ts"],"names":[],"mappings":"AAIA,OAAO,EAAC,KAAK,SAAS,EAA6E,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"OtpField.d.ts","sourceRoot":"","sources":["../../../../src/components/primitives/OtpField/OtpField.ts"],"names":[],"mappings":"AAIA,OAAO,EAAC,KAAK,SAAS,EAA6E,MAAM,KAAK,CAAC;AAkB/G,QAAA,MAAM,QAAQ,EAAE,SAqFd,CAAC;AAEH,eAAe,QAAQ,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -4374,6 +4374,8 @@ var DatePicker_default = DatePicker;
|
|
|
4374
4374
|
|
|
4375
4375
|
//#endregion
|
|
4376
4376
|
//#region src/components/primitives/OtpField/OtpField.ts
|
|
4377
|
+
const NON_NUMERIC_OTP_CHARS = /[^0-9]/g;
|
|
4378
|
+
const NON_ALPHANUMERIC_OTP_CHARS = /[^0-9A-Z]/g;
|
|
4377
4379
|
const OtpField = defineComponent({
|
|
4378
4380
|
name: "OtpField",
|
|
4379
4381
|
props: {
|
|
@@ -4401,6 +4403,10 @@ const OtpField = defineComponent({
|
|
|
4401
4403
|
default: void 0,
|
|
4402
4404
|
type: String
|
|
4403
4405
|
},
|
|
4406
|
+
numericOnly: {
|
|
4407
|
+
default: true,
|
|
4408
|
+
type: Boolean
|
|
4409
|
+
},
|
|
4404
4410
|
required: {
|
|
4405
4411
|
default: false,
|
|
4406
4412
|
type: Boolean
|
|
@@ -4414,7 +4420,7 @@ const OtpField = defineComponent({
|
|
|
4414
4420
|
};
|
|
4415
4421
|
const handleInput = (index, e) => {
|
|
4416
4422
|
const target = e.target;
|
|
4417
|
-
const val = target.value.replace(
|
|
4423
|
+
const val = props.numericOnly ? target.value.replace(NON_NUMERIC_OTP_CHARS, "").slice(0, 1) : target.value.toUpperCase().replace(NON_ALPHANUMERIC_OTP_CHARS, "").slice(0, 1);
|
|
4418
4424
|
target.value = val;
|
|
4419
4425
|
const current = (props.modelValue || "").split("");
|
|
4420
4426
|
while (current.length < props.length) current.push("");
|
|
@@ -4437,7 +4443,7 @@ const OtpField = defineComponent({
|
|
|
4437
4443
|
"aria-label": `Digit ${i + 1}`,
|
|
4438
4444
|
class: withVendorCSSClassPrefix("otp-field__digit"),
|
|
4439
4445
|
disabled: props.disabled,
|
|
4440
|
-
inputmode: "numeric",
|
|
4446
|
+
inputmode: props.numericOnly ? "numeric" : "text",
|
|
4441
4447
|
key: i,
|
|
4442
4448
|
maxlength: 1,
|
|
4443
4449
|
onInput: (e) => handleInput(i, e),
|
|
@@ -4689,13 +4695,34 @@ var BaseSignInButton_default = BaseSignInButton;
|
|
|
4689
4695
|
*
|
|
4690
4696
|
* If a custom `signInUrl` is configured, navigates to it instead.
|
|
4691
4697
|
* Falls back to i18n translation for the button text.
|
|
4698
|
+
*
|
|
4699
|
+
* By default, slot content is rendered *inside* the styled button (matching
|
|
4700
|
+
* {@link BaseSignInButton}'s convention) — the click handler and styling are
|
|
4701
|
+
* wired up for you.
|
|
4702
|
+
*
|
|
4703
|
+
* @example
|
|
4704
|
+
* <!-- Default: content is wrapped in the styled, click-wired button -->
|
|
4705
|
+
* <SignInButton>Sign In</SignInButton>
|
|
4706
|
+
* <SignInButton v-slot="{ isLoading }">{{ isLoading ? 'Signing in…' : 'Sign in' }}</SignInButton>
|
|
4707
|
+
*
|
|
4708
|
+
* @example
|
|
4709
|
+
* <!-- asChild: full control — you render the element and wire the click yourself -->
|
|
4710
|
+
* <SignInButton as-child v-slot="{ signIn, isLoading }">
|
|
4711
|
+
* <button @click="signIn" :disabled="isLoading">Sign In</button>
|
|
4712
|
+
* </SignInButton>
|
|
4692
4713
|
*/
|
|
4693
4714
|
const SignInButton = defineComponent({
|
|
4694
4715
|
name: "SignInButton",
|
|
4695
|
-
props: {
|
|
4696
|
-
|
|
4697
|
-
|
|
4698
|
-
|
|
4716
|
+
props: {
|
|
4717
|
+
asChild: {
|
|
4718
|
+
default: false,
|
|
4719
|
+
type: Boolean
|
|
4720
|
+
},
|
|
4721
|
+
signInOptions: {
|
|
4722
|
+
default: void 0,
|
|
4723
|
+
type: Object
|
|
4724
|
+
}
|
|
4725
|
+
},
|
|
4699
4726
|
emits: ["click", "error"],
|
|
4700
4727
|
setup(props, { slots, emit, attrs }) {
|
|
4701
4728
|
const { signIn, signInUrl, signInOptions: contextSignInOptions } = useThunderID_default();
|
|
@@ -4714,19 +4741,23 @@ const SignInButton = defineComponent({
|
|
|
4714
4741
|
}
|
|
4715
4742
|
};
|
|
4716
4743
|
return () => {
|
|
4717
|
-
if (slots["default"]) {
|
|
4744
|
+
if (props.asChild && slots["default"]) {
|
|
4718
4745
|
const nodes = slots["default"]({
|
|
4719
4746
|
isLoading: isLoading.value,
|
|
4720
4747
|
signIn: handleSignIn
|
|
4721
4748
|
});
|
|
4722
4749
|
return nodes.length === 1 ? nodes[0] : h(Fragment, null, nodes);
|
|
4723
4750
|
}
|
|
4751
|
+
const slotContent = slots["default"] ? () => slots["default"]({
|
|
4752
|
+
isLoading: isLoading.value,
|
|
4753
|
+
signIn: handleSignIn
|
|
4754
|
+
}) : void 0;
|
|
4724
4755
|
return h(BaseSignInButton_default, {
|
|
4725
4756
|
class: attrs.class,
|
|
4726
4757
|
isLoading: isLoading.value,
|
|
4727
4758
|
onClick: handleSignIn,
|
|
4728
4759
|
style: attrs.style
|
|
4729
|
-
});
|
|
4760
|
+
}, slotContent);
|
|
4730
4761
|
};
|
|
4731
4762
|
}
|
|
4732
4763
|
});
|
|
@@ -4893,11 +4924,30 @@ var BaseSignUpButton_default = BaseSignUpButton;
|
|
|
4893
4924
|
*
|
|
4894
4925
|
* If a custom `signUpUrl` is configured, navigates to it instead.
|
|
4895
4926
|
* Falls back to i18n translation for the button text.
|
|
4927
|
+
*
|
|
4928
|
+
* By default, slot content is rendered *inside* the styled button (matching
|
|
4929
|
+
* {@link BaseSignUpButton}'s convention) — the click handler and styling are
|
|
4930
|
+
* wired up for you.
|
|
4931
|
+
*
|
|
4932
|
+
* @example
|
|
4933
|
+
* <!-- Default: content is wrapped in the styled, click-wired button -->
|
|
4934
|
+
* <SignUpButton>Sign Up</SignUpButton>
|
|
4935
|
+
* <SignUpButton v-slot="{ isLoading }">{{ isLoading ? 'Signing up…' : 'Sign up' }}</SignUpButton>
|
|
4936
|
+
*
|
|
4937
|
+
* @example
|
|
4938
|
+
* <!-- asChild: full control — you render the element and wire the click yourself -->
|
|
4939
|
+
* <SignUpButton as-child v-slot="{ signUp, isLoading }">
|
|
4940
|
+
* <button @click="signUp" :disabled="isLoading">Sign Up</button>
|
|
4941
|
+
* </SignUpButton>
|
|
4896
4942
|
*/
|
|
4897
4943
|
const SignUpButton = defineComponent({
|
|
4898
4944
|
name: "SignUpButton",
|
|
4945
|
+
props: { asChild: {
|
|
4946
|
+
default: false,
|
|
4947
|
+
type: Boolean
|
|
4948
|
+
} },
|
|
4899
4949
|
emits: ["click", "error"],
|
|
4900
|
-
setup(
|
|
4950
|
+
setup(props, { slots, emit, attrs }) {
|
|
4901
4951
|
const { signUp, signUpUrl } = useThunderID_default();
|
|
4902
4952
|
const isLoading = ref(false);
|
|
4903
4953
|
const handleSignUp = async (e) => {
|
|
@@ -4914,19 +4964,23 @@ const SignUpButton = defineComponent({
|
|
|
4914
4964
|
}
|
|
4915
4965
|
};
|
|
4916
4966
|
return () => {
|
|
4917
|
-
if (slots["default"]) {
|
|
4967
|
+
if (props.asChild && slots["default"]) {
|
|
4918
4968
|
const nodes = slots["default"]({
|
|
4919
4969
|
isLoading: isLoading.value,
|
|
4920
4970
|
signUp: handleSignUp
|
|
4921
4971
|
});
|
|
4922
4972
|
return nodes.length === 1 ? nodes[0] : h(Fragment, null, nodes);
|
|
4923
4973
|
}
|
|
4974
|
+
const slotContent = slots["default"] ? () => slots["default"]({
|
|
4975
|
+
isLoading: isLoading.value,
|
|
4976
|
+
signUp: handleSignUp
|
|
4977
|
+
}) : void 0;
|
|
4924
4978
|
return h(BaseSignUpButton_default, {
|
|
4925
4979
|
class: attrs.class,
|
|
4926
4980
|
isLoading: isLoading.value,
|
|
4927
4981
|
onClick: handleSignUp,
|
|
4928
4982
|
style: attrs.style
|
|
4929
|
-
});
|
|
4983
|
+
}, slotContent);
|
|
4930
4984
|
};
|
|
4931
4985
|
}
|
|
4932
4986
|
});
|
|
@@ -5132,31 +5186,393 @@ const GoogleButton = defineComponent({
|
|
|
5132
5186
|
const { t } = useI18n_default();
|
|
5133
5187
|
const googleIcon = () => h("svg", {
|
|
5134
5188
|
height: "18",
|
|
5135
|
-
viewBox: "0 0
|
|
5189
|
+
viewBox: "0 0 268.1522 273.8827",
|
|
5136
5190
|
width: "18",
|
|
5137
5191
|
xmlns: "http://www.w3.org/2000/svg"
|
|
5138
|
-
}, [h("
|
|
5192
|
+
}, [h("defs", {}, [
|
|
5193
|
+
h("linearGradient", { id: "google-btn-a" }, [h("stop", {
|
|
5194
|
+
offset: "0",
|
|
5195
|
+
"stop-color": "#0fbc5c"
|
|
5196
|
+
}), h("stop", {
|
|
5197
|
+
offset: "1",
|
|
5198
|
+
"stop-color": "#0cba65"
|
|
5199
|
+
})]),
|
|
5200
|
+
h("linearGradient", { id: "google-btn-g" }, [
|
|
5201
|
+
h("stop", {
|
|
5202
|
+
offset: ".2312727",
|
|
5203
|
+
"stop-color": "#0fbc5f"
|
|
5204
|
+
}),
|
|
5205
|
+
h("stop", {
|
|
5206
|
+
offset: ".3115468",
|
|
5207
|
+
"stop-color": "#0fbc5f"
|
|
5208
|
+
}),
|
|
5209
|
+
h("stop", {
|
|
5210
|
+
offset: ".3660131",
|
|
5211
|
+
"stop-color": "#0fbc5e"
|
|
5212
|
+
}),
|
|
5213
|
+
h("stop", {
|
|
5214
|
+
offset: ".4575163",
|
|
5215
|
+
"stop-color": "#0fbc5d"
|
|
5216
|
+
}),
|
|
5217
|
+
h("stop", {
|
|
5218
|
+
offset: ".540305",
|
|
5219
|
+
"stop-color": "#12bc58"
|
|
5220
|
+
}),
|
|
5221
|
+
h("stop", {
|
|
5222
|
+
offset: ".6993464",
|
|
5223
|
+
"stop-color": "#28bf3c"
|
|
5224
|
+
}),
|
|
5225
|
+
h("stop", {
|
|
5226
|
+
offset: ".7712418",
|
|
5227
|
+
"stop-color": "#38c02b"
|
|
5228
|
+
}),
|
|
5229
|
+
h("stop", {
|
|
5230
|
+
offset: ".8605665",
|
|
5231
|
+
"stop-color": "#52c218"
|
|
5232
|
+
}),
|
|
5233
|
+
h("stop", {
|
|
5234
|
+
offset: ".9150327",
|
|
5235
|
+
"stop-color": "#67c30f"
|
|
5236
|
+
}),
|
|
5237
|
+
h("stop", {
|
|
5238
|
+
offset: "1",
|
|
5239
|
+
"stop-color": "#86c504"
|
|
5240
|
+
})
|
|
5241
|
+
]),
|
|
5242
|
+
h("linearGradient", { id: "google-btn-h" }, [
|
|
5243
|
+
h("stop", {
|
|
5244
|
+
offset: ".1416122",
|
|
5245
|
+
"stop-color": "#1abd4d"
|
|
5246
|
+
}),
|
|
5247
|
+
h("stop", {
|
|
5248
|
+
offset: ".2475151",
|
|
5249
|
+
"stop-color": "#6ec30d"
|
|
5250
|
+
}),
|
|
5251
|
+
h("stop", {
|
|
5252
|
+
offset: ".3115468",
|
|
5253
|
+
"stop-color": "#8ac502"
|
|
5254
|
+
}),
|
|
5255
|
+
h("stop", {
|
|
5256
|
+
offset: ".3660131",
|
|
5257
|
+
"stop-color": "#a2c600"
|
|
5258
|
+
}),
|
|
5259
|
+
h("stop", {
|
|
5260
|
+
offset: ".4456735",
|
|
5261
|
+
"stop-color": "#c8c903"
|
|
5262
|
+
}),
|
|
5263
|
+
h("stop", {
|
|
5264
|
+
offset: ".540305",
|
|
5265
|
+
"stop-color": "#ebcb03"
|
|
5266
|
+
}),
|
|
5267
|
+
h("stop", {
|
|
5268
|
+
offset: ".6156363",
|
|
5269
|
+
"stop-color": "#f7cd07"
|
|
5270
|
+
}),
|
|
5271
|
+
h("stop", {
|
|
5272
|
+
offset: ".6993454",
|
|
5273
|
+
"stop-color": "#fdcd04"
|
|
5274
|
+
}),
|
|
5275
|
+
h("stop", {
|
|
5276
|
+
offset: ".7712418",
|
|
5277
|
+
"stop-color": "#fdce05"
|
|
5278
|
+
}),
|
|
5279
|
+
h("stop", {
|
|
5280
|
+
offset: ".8605661",
|
|
5281
|
+
"stop-color": "#ffce0a"
|
|
5282
|
+
})
|
|
5283
|
+
]),
|
|
5284
|
+
h("linearGradient", { id: "google-btn-f" }, [
|
|
5285
|
+
h("stop", {
|
|
5286
|
+
offset: ".3159041",
|
|
5287
|
+
"stop-color": "#ff4c3c"
|
|
5288
|
+
}),
|
|
5289
|
+
h("stop", {
|
|
5290
|
+
offset: ".6038179",
|
|
5291
|
+
"stop-color": "#ff692c"
|
|
5292
|
+
}),
|
|
5293
|
+
h("stop", {
|
|
5294
|
+
offset: ".7268366",
|
|
5295
|
+
"stop-color": "#ff7825"
|
|
5296
|
+
}),
|
|
5297
|
+
h("stop", {
|
|
5298
|
+
offset: ".884534",
|
|
5299
|
+
"stop-color": "#ff8d1b"
|
|
5300
|
+
}),
|
|
5301
|
+
h("stop", {
|
|
5302
|
+
offset: "1",
|
|
5303
|
+
"stop-color": "#ff9f13"
|
|
5304
|
+
})
|
|
5305
|
+
]),
|
|
5306
|
+
h("linearGradient", { id: "google-btn-b" }, [
|
|
5307
|
+
h("stop", {
|
|
5308
|
+
offset: ".2312727",
|
|
5309
|
+
"stop-color": "#ff4541"
|
|
5310
|
+
}),
|
|
5311
|
+
h("stop", {
|
|
5312
|
+
offset: ".3115468",
|
|
5313
|
+
"stop-color": "#ff4540"
|
|
5314
|
+
}),
|
|
5315
|
+
h("stop", {
|
|
5316
|
+
offset: ".4575163",
|
|
5317
|
+
"stop-color": "#ff4640"
|
|
5318
|
+
}),
|
|
5319
|
+
h("stop", {
|
|
5320
|
+
offset: ".540305",
|
|
5321
|
+
"stop-color": "#ff473f"
|
|
5322
|
+
}),
|
|
5323
|
+
h("stop", {
|
|
5324
|
+
offset: ".6993464",
|
|
5325
|
+
"stop-color": "#ff5138"
|
|
5326
|
+
}),
|
|
5327
|
+
h("stop", {
|
|
5328
|
+
offset: ".7712418",
|
|
5329
|
+
"stop-color": "#ff5b33"
|
|
5330
|
+
}),
|
|
5331
|
+
h("stop", {
|
|
5332
|
+
offset: ".8605665",
|
|
5333
|
+
"stop-color": "#ff6c29"
|
|
5334
|
+
}),
|
|
5335
|
+
h("stop", {
|
|
5336
|
+
offset: "1",
|
|
5337
|
+
"stop-color": "#ff8c18"
|
|
5338
|
+
})
|
|
5339
|
+
]),
|
|
5340
|
+
h("linearGradient", { id: "google-btn-d" }, [h("stop", {
|
|
5341
|
+
offset: ".4084578",
|
|
5342
|
+
"stop-color": "#fb4e5a"
|
|
5343
|
+
}), h("stop", {
|
|
5344
|
+
offset: "1",
|
|
5345
|
+
"stop-color": "#ff4540"
|
|
5346
|
+
})]),
|
|
5347
|
+
h("linearGradient", { id: "google-btn-c" }, [
|
|
5348
|
+
h("stop", {
|
|
5349
|
+
offset: ".1315461",
|
|
5350
|
+
"stop-color": "#0cba65"
|
|
5351
|
+
}),
|
|
5352
|
+
h("stop", {
|
|
5353
|
+
offset: ".2097843",
|
|
5354
|
+
"stop-color": "#0bb86d"
|
|
5355
|
+
}),
|
|
5356
|
+
h("stop", {
|
|
5357
|
+
offset: ".2972969",
|
|
5358
|
+
"stop-color": "#09b479"
|
|
5359
|
+
}),
|
|
5360
|
+
h("stop", {
|
|
5361
|
+
offset: ".3962575",
|
|
5362
|
+
"stop-color": "#08ad93"
|
|
5363
|
+
}),
|
|
5364
|
+
h("stop", {
|
|
5365
|
+
offset: ".4771242",
|
|
5366
|
+
"stop-color": "#0aa6a9"
|
|
5367
|
+
}),
|
|
5368
|
+
h("stop", {
|
|
5369
|
+
offset: ".5684245",
|
|
5370
|
+
"stop-color": "#0d9cc6"
|
|
5371
|
+
}),
|
|
5372
|
+
h("stop", {
|
|
5373
|
+
offset: ".667385",
|
|
5374
|
+
"stop-color": "#1893dd"
|
|
5375
|
+
}),
|
|
5376
|
+
h("stop", {
|
|
5377
|
+
offset: ".7687273",
|
|
5378
|
+
"stop-color": "#258bf1"
|
|
5379
|
+
}),
|
|
5380
|
+
h("stop", {
|
|
5381
|
+
offset: ".8585063",
|
|
5382
|
+
"stop-color": "#3086ff"
|
|
5383
|
+
})
|
|
5384
|
+
]),
|
|
5385
|
+
h("linearGradient", { id: "google-btn-e" }, [
|
|
5386
|
+
h("stop", {
|
|
5387
|
+
offset: ".3660131",
|
|
5388
|
+
"stop-color": "#ff4e3a"
|
|
5389
|
+
}),
|
|
5390
|
+
h("stop", {
|
|
5391
|
+
offset: ".4575163",
|
|
5392
|
+
"stop-color": "#ff8a1b"
|
|
5393
|
+
}),
|
|
5394
|
+
h("stop", {
|
|
5395
|
+
offset: ".540305",
|
|
5396
|
+
"stop-color": "#ffa312"
|
|
5397
|
+
}),
|
|
5398
|
+
h("stop", {
|
|
5399
|
+
offset: ".6156363",
|
|
5400
|
+
"stop-color": "#ffb60c"
|
|
5401
|
+
}),
|
|
5402
|
+
h("stop", {
|
|
5403
|
+
offset: ".7712418",
|
|
5404
|
+
"stop-color": "#ffcd0a"
|
|
5405
|
+
}),
|
|
5406
|
+
h("stop", {
|
|
5407
|
+
offset: ".8605665",
|
|
5408
|
+
"stop-color": "#fecf0a"
|
|
5409
|
+
}),
|
|
5410
|
+
h("stop", {
|
|
5411
|
+
offset: ".9150327",
|
|
5412
|
+
"stop-color": "#fecf08"
|
|
5413
|
+
}),
|
|
5414
|
+
h("stop", {
|
|
5415
|
+
offset: "1",
|
|
5416
|
+
"stop-color": "#fdcd01"
|
|
5417
|
+
})
|
|
5418
|
+
]),
|
|
5419
|
+
h("linearGradient", {
|
|
5420
|
+
href: "#google-btn-a",
|
|
5421
|
+
id: "google-btn-s",
|
|
5422
|
+
x1: "219.6997",
|
|
5423
|
+
y1: "329.5351",
|
|
5424
|
+
x2: "254.4673",
|
|
5425
|
+
y2: "329.5351",
|
|
5426
|
+
gradientUnits: "userSpaceOnUse"
|
|
5427
|
+
}),
|
|
5428
|
+
h("radialGradient", {
|
|
5429
|
+
href: "#google-btn-b",
|
|
5430
|
+
id: "google-btn-m",
|
|
5431
|
+
gradientUnits: "userSpaceOnUse",
|
|
5432
|
+
gradientTransform: "matrix(-1.936885,1.043001,1.455731,2.555422,290.5254,-400.6338)",
|
|
5433
|
+
cx: "109.6267",
|
|
5434
|
+
cy: "135.8619",
|
|
5435
|
+
fx: "109.6267",
|
|
5436
|
+
fy: "135.8619",
|
|
5437
|
+
r: "71.46001"
|
|
5438
|
+
}),
|
|
5439
|
+
h("radialGradient", {
|
|
5440
|
+
href: "#google-btn-c",
|
|
5441
|
+
id: "google-btn-n",
|
|
5442
|
+
gradientUnits: "userSpaceOnUse",
|
|
5443
|
+
gradientTransform: "matrix(-3.512595,-4.45809,-1.692547,1.260616,870.8006,191.554)",
|
|
5444
|
+
cx: "45.25866",
|
|
5445
|
+
cy: "279.2738",
|
|
5446
|
+
fx: "45.25866",
|
|
5447
|
+
fy: "279.2738",
|
|
5448
|
+
r: "71.46001"
|
|
5449
|
+
}),
|
|
5450
|
+
h("radialGradient", {
|
|
5451
|
+
href: "#google-btn-d",
|
|
5452
|
+
id: "google-btn-l",
|
|
5453
|
+
cx: "304.0166",
|
|
5454
|
+
cy: "118.0089",
|
|
5455
|
+
fx: "304.0166",
|
|
5456
|
+
fy: "118.0089",
|
|
5457
|
+
r: "47.85445",
|
|
5458
|
+
gradientTransform: "matrix(2.064353,-4.926832e-6,-2.901531e-6,2.592041,-297.6788,-151.7469)",
|
|
5459
|
+
gradientUnits: "userSpaceOnUse"
|
|
5460
|
+
}),
|
|
5461
|
+
h("radialGradient", {
|
|
5462
|
+
href: "#google-btn-e",
|
|
5463
|
+
id: "google-btn-o",
|
|
5464
|
+
gradientUnits: "userSpaceOnUse",
|
|
5465
|
+
gradientTransform: "matrix(-0.2485783,2.083138,2.962486,0.3341668,-255.1463,-331.1636)",
|
|
5466
|
+
cx: "181.001",
|
|
5467
|
+
cy: "177.2013",
|
|
5468
|
+
fx: "181.001",
|
|
5469
|
+
fy: "177.2013",
|
|
5470
|
+
r: "71.46001"
|
|
5471
|
+
}),
|
|
5472
|
+
h("radialGradient", {
|
|
5473
|
+
href: "#google-btn-f",
|
|
5474
|
+
id: "google-btn-p",
|
|
5475
|
+
cx: "207.6733",
|
|
5476
|
+
cy: "108.0972",
|
|
5477
|
+
fx: "207.6733",
|
|
5478
|
+
fy: "108.0972",
|
|
5479
|
+
r: "41.1025",
|
|
5480
|
+
gradientTransform: "matrix(-1.249206,1.343263,-3.896837,-3.425693,880.5011,194.9051)",
|
|
5481
|
+
gradientUnits: "userSpaceOnUse"
|
|
5482
|
+
}),
|
|
5483
|
+
h("radialGradient", {
|
|
5484
|
+
href: "#google-btn-g",
|
|
5485
|
+
id: "google-btn-r",
|
|
5486
|
+
gradientUnits: "userSpaceOnUse",
|
|
5487
|
+
gradientTransform: "matrix(-1.936885,-1.043001,1.455731,-2.555422,290.5254,838.6834)",
|
|
5488
|
+
cx: "109.6267",
|
|
5489
|
+
cy: "135.8619",
|
|
5490
|
+
fx: "109.6267",
|
|
5491
|
+
fy: "135.8619",
|
|
5492
|
+
r: "71.46001"
|
|
5493
|
+
}),
|
|
5494
|
+
h("radialGradient", {
|
|
5495
|
+
href: "#google-btn-h",
|
|
5496
|
+
id: "google-btn-j",
|
|
5497
|
+
gradientUnits: "userSpaceOnUse",
|
|
5498
|
+
gradientTransform: "matrix(-0.081402,-1.93722,2.926737,-0.1162508,-215.1345,632.8606)",
|
|
5499
|
+
cx: "154.8697",
|
|
5500
|
+
cy: "145.9691",
|
|
5501
|
+
fx: "154.8697",
|
|
5502
|
+
fy: "145.9691",
|
|
5503
|
+
r: "71.46001"
|
|
5504
|
+
}),
|
|
5505
|
+
h("filter", {
|
|
5506
|
+
id: "google-btn-q",
|
|
5507
|
+
x: "-.04842873",
|
|
5508
|
+
y: "-.0582241",
|
|
5509
|
+
width: "1.096857",
|
|
5510
|
+
height: "1.116448",
|
|
5511
|
+
"color-interpolation-filters": "sRGB"
|
|
5512
|
+
}, [h("feGaussianBlur", { stdDeviation: "1.700914" })]),
|
|
5513
|
+
h("filter", {
|
|
5514
|
+
id: "google-btn-k",
|
|
5515
|
+
x: "-.01670084",
|
|
5516
|
+
y: "-.01009856",
|
|
5517
|
+
width: "1.033402",
|
|
5518
|
+
height: "1.020197",
|
|
5519
|
+
"color-interpolation-filters": "sRGB"
|
|
5520
|
+
}, [h("feGaussianBlur", { stdDeviation: ".2419367" })]),
|
|
5521
|
+
h("clipPath", {
|
|
5522
|
+
clipPathUnits: "userSpaceOnUse",
|
|
5523
|
+
id: "google-btn-i"
|
|
5524
|
+
}, [h("path", {
|
|
5525
|
+
d: "M371.3784 193.2406H237.0825v53.4375h77.167c-1.2405 7.5627-4.0259 15.0024-8.1049 21.7862-4.6734 7.7723-10.4511 13.6895-16.373 18.1957-17.7389 13.4983-38.42 16.2584-52.7828 16.2584-36.2824 0-67.2833-23.2865-79.2844-54.9287-.4843-1.1482-.8059-2.3344-1.1975-3.5068-2.652-8.0533-4.101-16.5825-4.101-25.4474 0-9.226 1.5691-18.0575 4.4301-26.3985 11.2851-32.8967 42.9849-57.4674 80.1789-57.4674 7.4811 0 14.6854.8843 21.5173 2.6481 15.6135 4.0309 26.6578 11.9698 33.4252 18.2494l40.834-39.7111c-24.839-22.616-57.2194-36.3201-95.8444-36.3201-30.8782-.00066-59.3863 9.55308-82.7477 25.6992-18.9454 13.0941-34.4833 30.6254-44.9695 50.9861-9.75366 18.8785-15.09441 39.7994-15.09441 62.2934 0 22.495 5.34891 43.6334 15.10261 62.3374v.126c10.3023 19.8567 25.3678 36.9537 43.6783 49.9878 15.9962 11.3866 44.6789 26.5516 84.0307 26.5516 22.6301 0 42.6867-4.0517 60.3748-11.6447 12.76-5.4775 24.0655-12.6217 34.3012-21.8036 13.5247-12.1323 24.1168-27.1388 31.3465-44.4041 7.2297-17.2654 11.097-36.7895 11.097-57.957 0-9.858-.9971-19.8694-2.6881-28.9684Z",
|
|
5526
|
+
fill: "#000"
|
|
5527
|
+
})])
|
|
5528
|
+
]), h("g", { transform: "matrix(0.957922,0,0,0.985255,-90.17436,-78.85577)" }, [h("g", { "clip-path": "url(#google-btn-i)" }, [
|
|
5529
|
+
h("path", {
|
|
5530
|
+
d: "M92.07563 219.9585c.14844 22.14 6.5014 44.983 16.11767 63.4234v.1269c6.9482 13.3919 16.4444 23.9704 27.2604 34.4518l65.326-23.67c-12.3593-6.2344-14.2452-10.0546-23.1048-17.0253-9.0537-9.0658-15.8015-19.4735-20.0038-31.677h-.1693l.1693-.1269c-2.7646-8.0587-3.0373-16.6129-3.1393-25.5029Z",
|
|
5531
|
+
fill: "url(#google-btn-j)",
|
|
5532
|
+
filter: "url(#google-btn-k)"
|
|
5533
|
+
}),
|
|
5534
|
+
h("path", {
|
|
5535
|
+
d: "M237.0835 79.02491c-6.4568 22.52569-3.988 44.42139 0 57.16129 7.4561.0055 14.6388.8881 21.4494 2.6464 15.6135 4.0309 26.6566 11.97 33.424 18.2496l41.8794-40.7256c-24.8094-22.58904-54.6663-37.2961-96.7528-37.33169Z",
|
|
5536
|
+
fill: "url(#google-btn-l)",
|
|
5537
|
+
filter: "url(#google-btn-k)"
|
|
5538
|
+
}),
|
|
5539
|
+
h("path", {
|
|
5540
|
+
d: "M236.9434 78.84678c-31.6709-.00068-60.9107 9.79833-84.8718 26.35902-8.8968 6.149-17.0612 13.2521-24.3311 21.1509-1.9045 17.7429 14.2569 39.5507 46.2615 39.3702 15.5284-17.9373 38.4946-29.5427 64.0561-29.5427.0233 0 .046.0019.0693.002l-1.0439-57.33536c-.0472-.00003-.0929-.00406-.1401-.00406Z",
|
|
5541
|
+
fill: "url(#google-btn-m)",
|
|
5542
|
+
filter: "url(#google-btn-k)"
|
|
5543
|
+
}),
|
|
5544
|
+
h("path", {
|
|
5545
|
+
d: "m341.4751 226.3788-28.2685 19.2848c-1.2405 7.5627-4.0278 15.0023-8.1068 21.7861-4.6734 7.7723-10.4506 13.6898-16.3725 18.196-17.7022 13.4704-38.3286 16.2439-52.6877 16.2553-14.8415 25.1018-17.4435 37.6749 1.0439 57.9342 22.8762-.0167 43.157-4.1174 61.0458-11.7965 12.9312-5.551 24.3879-12.7913 34.7609-22.0964 13.7061-12.295 24.4421-27.5034 31.7688-45.0003 7.3267-17.497 11.2446-37.2822 11.2446-58.7336Z",
|
|
5546
|
+
fill: "url(#google-btn-n)",
|
|
5547
|
+
filter: "url(#google-btn-k)"
|
|
5548
|
+
}),
|
|
5549
|
+
h("path", {
|
|
5550
|
+
d: "M234.9956 191.2104v57.4981h136.0062c1.1962-7.8745 5.1523-18.0644 5.1523-26.5001 0-9.858-.9963-21.899-2.6873-30.998Z",
|
|
5551
|
+
fill: "#3086ff",
|
|
5552
|
+
filter: "url(#google-btn-k)"
|
|
5553
|
+
}),
|
|
5139
5554
|
h("path", {
|
|
5140
|
-
d: "
|
|
5141
|
-
fill: "#
|
|
5142
|
-
|
|
5555
|
+
d: "M128.3894 124.3268c-8.393 9.1191-15.5632 19.326-21.2483 30.3646-9.75351 18.8785-15.09402 41.8295-15.09402 64.3235 0 .317.02642.6271.02855.9436 4.31953 8.2244 59.66647 6.6495 62.45617 0-.0035-.3103-.0387-.6128-.0387-.9238 0-9.226 1.5696-16.0262 4.4306-24.3672 3.5294-10.2885 9.0557-19.7628 16.1223-27.9257 1.6019-2.0309 5.8748-6.3969 7.1214-9.0157.4749-.9975-.8621-1.5574-.9369-1.9085-.0836-.3927-1.8762-.0769-2.2778-.3694-1.2751-.9288-3.8001-1.4138-5.3334-1.8449-3.2772-.9215-8.7085-2.9536-11.7252-5.0601-9.5357-6.6586-24.417-14.6122-33.5047-24.2164Z",
|
|
5556
|
+
fill: "url(#google-btn-o)",
|
|
5557
|
+
filter: "url(#google-btn-k)"
|
|
5143
5558
|
}),
|
|
5144
5559
|
h("path", {
|
|
5145
|
-
d: "
|
|
5146
|
-
fill: "#
|
|
5147
|
-
|
|
5560
|
+
d: "M162.0989 155.8569c22.1123 13.3013 28.4714-6.7139 43.173-12.9771L179.698 90.21568c-9.4075 3.92642-18.2957 8.80465-26.5426 14.50442-12.316 8.5122-23.192 18.8995-32.1763 30.7204Z",
|
|
5561
|
+
fill: "url(#google-btn-p)",
|
|
5562
|
+
filter: "url(#google-btn-q)"
|
|
5148
5563
|
}),
|
|
5149
5564
|
h("path", {
|
|
5150
|
-
d: "
|
|
5151
|
-
fill: "#
|
|
5152
|
-
|
|
5565
|
+
d: "M171.0987 290.222c-29.6829 10.6413-34.3299 11.023-37.0622 29.2903 5.2213 5.0597 10.8312 9.74 16.7926 13.9835 15.9962 11.3867 46.766 26.5517 86.1178 26.5517.0462 0 .0904-.004.1366-.004v-59.1574c-.0298.0001-.064.002-.0938.002-14.7359 0-26.5113-3.8435-38.5848-10.5273-2.9768-1.6479-8.3775 2.7772-11.1229.799-3.7865-2.7284-12.8991 2.3508-16.1833-.9378Z",
|
|
5566
|
+
fill: "url(#google-btn-r)",
|
|
5567
|
+
filter: "url(#google-btn-k)"
|
|
5153
5568
|
}),
|
|
5154
5569
|
h("path", {
|
|
5155
|
-
d: "
|
|
5156
|
-
|
|
5157
|
-
|
|
5570
|
+
d: "M219.6997 299.0227v59.9959c5.506.6402 11.2361 1.0289 17.2472 1.0289 6.0259 0 11.8556-.3073 17.5204-.8723v-59.7481c-6.3482 1.0777-12.3272 1.461-17.4776 1.461-5.9318 0-11.7005-.6858-17.29-1.8654Z",
|
|
5571
|
+
opacity: ".5",
|
|
5572
|
+
fill: "url(#google-btn-s)",
|
|
5573
|
+
filter: "url(#google-btn-k)"
|
|
5158
5574
|
})
|
|
5159
|
-
])]);
|
|
5575
|
+
])])]);
|
|
5160
5576
|
return () => h(Button_default, {
|
|
5161
5577
|
...attrs,
|
|
5162
5578
|
color: "secondary",
|
|
@@ -5249,7 +5665,7 @@ const validateFieldValue = (value, type, required = false, touched = false) => {
|
|
|
5249
5665
|
* Factory function to create form field VNodes based on FieldType.
|
|
5250
5666
|
*/
|
|
5251
5667
|
const createField = (config) => {
|
|
5252
|
-
const { name, type, label, required, value, onChange, onBlur, disabled = false, error, className, options = [], touched = false, placeholder } = config;
|
|
5668
|
+
const { name, type, label, required, value, onChange, onBlur, disabled = false, error, className, options = [], touched = false, placeholder, length, numericOnly = true } = config;
|
|
5253
5669
|
const validationError = error || validateFieldValue(value, type, required, touched);
|
|
5254
5670
|
const commonProps = {
|
|
5255
5671
|
class: className,
|
|
@@ -5294,6 +5710,8 @@ const createField = (config) => {
|
|
|
5294
5710
|
}
|
|
5295
5711
|
case FieldType$1.Otp: return h(OtpField_default, {
|
|
5296
5712
|
...commonProps,
|
|
5713
|
+
...length ? { length } : {},
|
|
5714
|
+
numericOnly,
|
|
5297
5715
|
"onUpdate:modelValue": onChange
|
|
5298
5716
|
});
|
|
5299
5717
|
case FieldType$1.Number: return h(TextField_default, {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thunderid/vue",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"description": "Vue SDK for ThunderID",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"thunderid",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"dependencies": {
|
|
60
60
|
"dompurify": "3.4.11",
|
|
61
61
|
"tslib": "2.8.1",
|
|
62
|
-
"@thunderid/browser": "^0.
|
|
62
|
+
"@thunderid/browser": "^1.0.0"
|
|
63
63
|
},
|
|
64
64
|
"publishConfig": {
|
|
65
65
|
"access": "public"
|