@prosopo/procaptcha-bundle 2.1.0 → 2.1.1
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/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/language.d.ts +1 -1
- package/.rollup.cache/home/chris/dev/prosopo/captcha-private/captcha/packages/procaptcha-bundle/dist/bundle/util/language.d.ts.map +1 -0
- package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/language.js +1 -1
- package/.rollup.cache/home/chris/dev/prosopo/captcha-private/captcha/packages/procaptcha-bundle/dist/bundle/util/language.js.map +1 -0
- package/dist/bundle/ProcaptchaWidget-BJTWbWXX.js +157 -0
- package/dist/bundle/{ProcaptchaWidget-BZq2OhjK.js → ProcaptchaWidget-CyCdGVAQ.js} +94 -85
- package/dist/bundle/{index-Ck7UqzKB.js → index-DkYajG2c.js} +13127 -13934
- package/dist/bundle/procaptcha.bundle.js +1 -1
- package/dist/bundle/util/language.d.ts +1 -1
- package/dist/bundle/util/language.d.ts.map +1 -1
- package/dist/bundle/{utils-9IQXYrRR.js → utils-CAk_TqSc.js} +5065 -3278
- package/dist/cjs/index.cjs +16 -4
- package/dist/cjs/util/language.cjs +3 -3
- package/dist/util/language.d.ts +1 -1
- package/dist/util/language.d.ts.map +1 -1
- package/dist/util/language.js +1 -1
- package/dist/util/language.js.map +1 -1
- package/package.json +9 -8
- package/stats.html +1 -1
- package/vite.config.ts.timestamp-1717674816132-b375b28e04de9.mjs +56 -0
- package/vite.config.ts.timestamp-1723148478701-50a086cc53355.mjs +56 -0
- package/.rollup.cache/home/runner/work/captcha/captcha/packages/procaptcha-bundle/dist/bundle/util/language.d.ts.map +0 -1
- package/.rollup.cache/home/runner/work/captcha/captcha/packages/procaptcha-bundle/dist/bundle/util/language.js.map +0 -1
- package/dist/bundle/ProcaptchaWidget-b_oUhvT9.js +0 -149
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/index.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/index.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/index.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/index.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/captchaType.test.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/captchaType.test.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/captchaType.test.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/captchaType.test.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/config.test.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/config.test.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/config.test.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/tests/config.test.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/captchaType.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/captchaType.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/captchaType.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/captchaType.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/config.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/config.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/config.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/config.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/defaultCallbacks.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/defaultCallbacks.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/defaultCallbacks.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/defaultCallbacks.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/form.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/form.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/form.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/form.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/theme.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/theme.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/theme.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/theme.js.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/timeout.d.ts +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/timeout.d.ts.map +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/timeout.js +0 -0
- /package/.rollup.cache/home/{runner/work/captcha → chris/dev/prosopo/captcha-private}/captcha/packages/procaptcha-bundle/dist/bundle/util/timeout.js.map +0 -0
package/dist/cjs/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const
|
|
3
|
+
const jsxDevRuntime = require("react/jsx-dev-runtime");
|
|
4
4
|
const procaptchaFrictionless = require("@prosopo/procaptcha-frictionless");
|
|
5
5
|
const procaptchaPow = require("@prosopo/procaptcha-pow");
|
|
6
6
|
const procaptchaReact = require("@prosopo/procaptcha-react");
|
|
@@ -37,17 +37,29 @@ const renderLogic = (elements, config2, renderOptions) => {
|
|
|
37
37
|
switch (renderOptions?.captchaType) {
|
|
38
38
|
case "pow":
|
|
39
39
|
client.createRoot(element).render(
|
|
40
|
-
/* @__PURE__ */
|
|
40
|
+
/* @__PURE__ */ jsxDevRuntime.jsxDEV(procaptchaPow.ProcaptchaPow, { config: config2, callbacks }, void 0, false, {
|
|
41
|
+
fileName: "/home/chris/dev/prosopo/captcha-private/captcha/packages/procaptcha-bundle/src/index.tsx",
|
|
42
|
+
lineNumber: 77,
|
|
43
|
+
columnNumber: 6
|
|
44
|
+
}, void 0)
|
|
41
45
|
);
|
|
42
46
|
break;
|
|
43
47
|
case "frictionless":
|
|
44
48
|
client.createRoot(element).render(
|
|
45
|
-
/* @__PURE__ */
|
|
49
|
+
/* @__PURE__ */ jsxDevRuntime.jsxDEV(procaptchaFrictionless.ProcaptchaFrictionless, { config: config2, callbacks }, void 0, false, {
|
|
50
|
+
fileName: "/home/chris/dev/prosopo/captcha-private/captcha/packages/procaptcha-bundle/src/index.tsx",
|
|
51
|
+
lineNumber: 82,
|
|
52
|
+
columnNumber: 6
|
|
53
|
+
}, void 0)
|
|
46
54
|
);
|
|
47
55
|
break;
|
|
48
56
|
default:
|
|
49
57
|
client.createRoot(element).render(
|
|
50
|
-
/* @__PURE__ */
|
|
58
|
+
/* @__PURE__ */ jsxDevRuntime.jsxDEV(procaptchaReact.Procaptcha, { config: config2, callbacks }, void 0, false, {
|
|
59
|
+
fileName: "/home/chris/dev/prosopo/captcha-private/captcha/packages/procaptcha-bundle/src/index.tsx",
|
|
60
|
+
lineNumber: 87,
|
|
61
|
+
columnNumber: 6
|
|
62
|
+
}, void 0)
|
|
51
63
|
);
|
|
52
64
|
break;
|
|
53
65
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
3
|
+
const locale = require("@prosopo/locale");
|
|
4
4
|
const setLanguage = (renderOptions, element, config) => {
|
|
5
5
|
const languageAttribute = renderOptions?.language || element.getAttribute("data-language");
|
|
6
6
|
if (languageAttribute) {
|
|
@@ -9,10 +9,10 @@ const setLanguage = (renderOptions, element, config) => {
|
|
|
9
9
|
};
|
|
10
10
|
const validateLanguage = (languageAttribute) => {
|
|
11
11
|
try {
|
|
12
|
-
return
|
|
12
|
+
return locale.LanguageSchema.parse(languageAttribute);
|
|
13
13
|
} catch (error) {
|
|
14
14
|
console.error(`Invalid language attribute: ${languageAttribute}`);
|
|
15
|
-
return
|
|
15
|
+
return locale.LanguageSchema.parse("en");
|
|
16
16
|
}
|
|
17
17
|
};
|
|
18
18
|
exports.setLanguage = setLanguage;
|
package/dist/util/language.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { ProcaptchaClientConfigInput, ProcaptchaRenderOptions } from "@prosopo/types";
|
|
2
2
|
export declare const setLanguage: (renderOptions: ProcaptchaRenderOptions | undefined, element: Element, config: ProcaptchaClientConfigInput) => void;
|
|
3
3
|
//# sourceMappingURL=language.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"language.d.ts","sourceRoot":"","sources":["../../src/util/language.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"language.d.ts","sourceRoot":"","sources":["../../src/util/language.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EACX,2BAA2B,EAC3B,uBAAuB,EACvB,MAAM,gBAAgB,CAAC;AAcxB,eAAO,MAAM,WAAW,kBACR,uBAAuB,GAAG,SAAS,WACzC,OAAO,UACR,2BAA2B,SAQnC,CAAC"}
|
package/dist/util/language.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { LanguageSchema
|
|
1
|
+
import { LanguageSchema } from "@prosopo/locale";
|
|
2
2
|
export const setLanguage = (renderOptions, element, config) => {
|
|
3
3
|
const languageAttribute = renderOptions?.language || element.getAttribute("data-language");
|
|
4
4
|
if (languageAttribute) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"language.js","sourceRoot":"","sources":["../../src/util/language.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"language.js","sourceRoot":"","sources":["../../src/util/language.ts"],"names":[],"mappings":"AAcA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAkBjD,MAAM,CAAC,MAAM,WAAW,GAAG,CAC1B,aAAkD,EAClD,OAAgB,EAChB,MAAmC,EAClC,EAAE;IACH,MAAM,iBAAiB,GACtB,aAAa,EAAE,QAAQ,IAAI,OAAO,CAAC,YAAY,CAAC,eAAe,CAAC,CAAC;IAElE,IAAI,iBAAiB,EAAE,CAAC;QACvB,MAAM,CAAC,QAAQ,GAAG,gBAAgB,CAAC,iBAAiB,CAAC,CAAC;IACvD,CAAC;AACF,CAAC,CAAC;AAEF,MAAM,gBAAgB,GAAG,CACxB,iBAAiD,EAChD,EAAE;IACH,IAAI,CAAC;QACJ,OAAO,cAAc,CAAC,KAAK,CAAC,iBAAiB,CAAC,CAAC;IAChD,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QAChB,OAAO,CAAC,KAAK,CAAC,+BAA+B,iBAAiB,EAAE,CAAC,CAAC;QAClE,OAAO,cAAc,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IACnC,CAAC;AACF,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prosopo/procaptcha-bundle",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.1",
|
|
4
4
|
"author": "PROSOPO LIMITED <info@prosopo.io>",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -29,12 +29,13 @@
|
|
|
29
29
|
},
|
|
30
30
|
"browserslist": ["> 0.5%, last 2 versions, not dead"],
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@prosopo/dotenv": "2.1.
|
|
33
|
-
"@prosopo/
|
|
34
|
-
"@prosopo/procaptcha-
|
|
35
|
-
"@prosopo/procaptcha-
|
|
36
|
-
"@prosopo/
|
|
37
|
-
"@prosopo/
|
|
32
|
+
"@prosopo/dotenv": "2.1.1",
|
|
33
|
+
"@prosopo/locale": "2.1.1",
|
|
34
|
+
"@prosopo/procaptcha-frictionless": "2.1.1",
|
|
35
|
+
"@prosopo/procaptcha-pow": "2.1.1",
|
|
36
|
+
"@prosopo/procaptcha-react": "2.1.1",
|
|
37
|
+
"@prosopo/types": "2.1.1",
|
|
38
|
+
"@prosopo/util": "2.1.1",
|
|
38
39
|
"react": "18.3.1",
|
|
39
40
|
"react-dom": "18.3.1"
|
|
40
41
|
},
|
|
@@ -51,7 +52,7 @@
|
|
|
51
52
|
"registry": "https://registry.npmjs.org"
|
|
52
53
|
},
|
|
53
54
|
"devDependencies": {
|
|
54
|
-
"@prosopo/config": "2.1.
|
|
55
|
+
"@prosopo/config": "2.1.1",
|
|
55
56
|
"@types/jsdom": "21.1.7",
|
|
56
57
|
"@vitest/coverage-v8": "2.1.1",
|
|
57
58
|
"concurrently": "9.0.1",
|