@prosopo/procaptcha-icon-order 0.2.9 → 0.2.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (124) hide show
  1. package/.turbo/turbo-build$colon$cjs.log +2 -2
  2. package/.turbo/{turbo-build.log → turbo-build$colon$esm.log} +8 -9
  3. package/.turbo/turbo-build$colon$tsc.log +17 -17
  4. package/.turbo/turbo-build$colon$types.log +1 -0
  5. package/CHANGELOG.md +46 -0
  6. package/dist/cjs/services/Manager.cjs +1 -2
  7. package/dist/{services → esm/services}/Manager.js +2 -3
  8. package/dist/tsc/components/iconOrderCanvas.d.ts.map +1 -0
  9. package/dist/tsc/components/iconOrderCanvas.js +336 -0
  10. package/dist/tsc/components/iconOrderCanvas.js.map +1 -0
  11. package/dist/tsc/components/procaptchaIconOrder.d.ts.map +1 -0
  12. package/dist/tsc/components/procaptchaIconOrder.js +4 -0
  13. package/dist/tsc/components/procaptchaIconOrder.js.map +1 -0
  14. package/dist/tsc/components/procaptchaWidget.d.ts.map +1 -0
  15. package/dist/tsc/components/procaptchaWidget.js +244 -0
  16. package/dist/tsc/components/procaptchaWidget.js.map +1 -0
  17. package/dist/tsc/errorSites.d.ts.map +1 -0
  18. package/dist/{errorSites.js.map → tsc/errorSites.js.map} +1 -1
  19. package/dist/tsc/index.d.ts.map +1 -0
  20. package/dist/tsc/index.js +4 -0
  21. package/dist/tsc/index.js.map +1 -0
  22. package/dist/tsc/services/Manager.d.ts.map +1 -0
  23. package/dist/tsc/services/Manager.js +262 -0
  24. package/dist/tsc/services/Manager.js.map +1 -0
  25. package/dist/tsc/tests/domHarness.d.ts.map +1 -0
  26. package/dist/tsc/tests/domHarness.js.map +1 -0
  27. package/dist/tsc/tests/iconOrderCanvas.unit.test.d.ts.map +1 -0
  28. package/dist/tsc/tests/iconOrderCanvas.unit.test.js.map +1 -0
  29. package/dist/tsc/tests/invisibleCanvasVisibility.unit.test.d.ts.map +1 -0
  30. package/dist/tsc/tests/invisibleCanvasVisibility.unit.test.js.map +1 -0
  31. package/dist/tsc/tests/manager.unit.test.d.ts.map +1 -0
  32. package/dist/{tests → tsc/tests}/manager.unit.test.js +10 -3
  33. package/dist/tsc/tests/manager.unit.test.js.map +1 -0
  34. package/dist/tsc/tests/managerHarness.d.ts.map +1 -0
  35. package/dist/tsc/tests/managerHarness.js.map +1 -0
  36. package/dist/tsc/tests/procaptchaIconOrder.test-d.d.ts.map +1 -0
  37. package/dist/tsc/tests/procaptchaIconOrder.test-d.js.map +1 -0
  38. package/dist/tsc/tests/procaptchaIconOrder.unit.test.d.ts.map +1 -0
  39. package/dist/tsc/tests/procaptchaIconOrder.unit.test.js.map +1 -0
  40. package/dist/tsc/tests/procaptchaWidget.unit.test.d.ts.map +1 -0
  41. package/dist/tsc/tests/procaptchaWidget.unit.test.js.map +1 -0
  42. package/dist/types/components/iconOrderCanvas.d.ts +20 -0
  43. package/dist/types/components/iconOrderCanvas.d.ts.map +1 -0
  44. package/dist/types/components/procaptchaIconOrder.d.ts +7 -0
  45. package/dist/types/components/procaptchaIconOrder.d.ts.map +1 -0
  46. package/dist/types/components/procaptchaWidget.d.ts +7 -0
  47. package/dist/types/components/procaptchaWidget.d.ts.map +1 -0
  48. package/dist/types/errorSites.d.ts +12 -0
  49. package/dist/types/errorSites.d.ts.map +1 -0
  50. package/dist/types/index.d.ts +4 -0
  51. package/dist/types/index.d.ts.map +1 -0
  52. package/dist/types/services/Manager.d.ts +10 -0
  53. package/dist/types/services/Manager.d.ts.map +1 -0
  54. package/dist/types/tests/domHarness.d.ts +20 -0
  55. package/dist/types/tests/domHarness.d.ts.map +1 -0
  56. package/dist/types/tests/iconOrderCanvas.unit.test.d.ts +2 -0
  57. package/dist/types/tests/iconOrderCanvas.unit.test.d.ts.map +1 -0
  58. package/dist/types/tests/invisibleCanvasVisibility.unit.test.d.ts +2 -0
  59. package/dist/types/tests/invisibleCanvasVisibility.unit.test.d.ts.map +1 -0
  60. package/dist/types/tests/manager.unit.test.d.ts +2 -0
  61. package/dist/types/tests/manager.unit.test.d.ts.map +1 -0
  62. package/dist/types/tests/managerHarness.d.ts +21 -0
  63. package/dist/types/tests/managerHarness.d.ts.map +1 -0
  64. package/dist/types/tests/procaptchaIconOrder.test-d.d.ts +2 -0
  65. package/dist/types/tests/procaptchaIconOrder.test-d.d.ts.map +1 -0
  66. package/dist/types/tests/procaptchaIconOrder.unit.test.d.ts +2 -0
  67. package/dist/types/tests/procaptchaIconOrder.unit.test.d.ts.map +1 -0
  68. package/dist/types/tests/procaptchaWidget.unit.test.d.ts +2 -0
  69. package/dist/types/tests/procaptchaWidget.unit.test.d.ts.map +1 -0
  70. package/package.json +17 -18
  71. package/dist/components/iconOrderCanvas.d.ts.map +0 -1
  72. package/dist/components/iconOrderCanvas.js.map +0 -1
  73. package/dist/components/procaptchaIconOrder.d.ts.map +0 -1
  74. package/dist/components/procaptchaIconOrder.js.map +0 -1
  75. package/dist/components/procaptchaWidget.d.ts.map +0 -1
  76. package/dist/components/procaptchaWidget.js.map +0 -1
  77. package/dist/errorSites.d.ts.map +0 -1
  78. package/dist/index.d.ts.map +0 -1
  79. package/dist/index.js.map +0 -1
  80. package/dist/services/Manager.d.ts.map +0 -1
  81. package/dist/services/Manager.js.map +0 -1
  82. package/dist/tests/domHarness.d.ts.map +0 -1
  83. package/dist/tests/domHarness.js.map +0 -1
  84. package/dist/tests/iconOrderCanvas.unit.test.d.ts.map +0 -1
  85. package/dist/tests/iconOrderCanvas.unit.test.js.map +0 -1
  86. package/dist/tests/invisibleCanvasVisibility.unit.test.d.ts.map +0 -1
  87. package/dist/tests/invisibleCanvasVisibility.unit.test.js.map +0 -1
  88. package/dist/tests/manager.unit.test.d.ts.map +0 -1
  89. package/dist/tests/manager.unit.test.js.map +0 -1
  90. package/dist/tests/managerHarness.d.ts.map +0 -1
  91. package/dist/tests/managerHarness.js.map +0 -1
  92. package/dist/tests/procaptchaIconOrder.test-d.d.ts.map +0 -1
  93. package/dist/tests/procaptchaIconOrder.test-d.js.map +0 -1
  94. package/dist/tests/procaptchaIconOrder.unit.test.d.ts.map +0 -1
  95. package/dist/tests/procaptchaIconOrder.unit.test.js.map +0 -1
  96. package/dist/tests/procaptchaWidget.unit.test.d.ts.map +0 -1
  97. package/dist/tests/procaptchaWidget.unit.test.js.map +0 -1
  98. /package/dist/{_virtual → esm/_virtual}/_rolldown/runtime.js +0 -0
  99. /package/dist/{components → esm/components}/iconOrderCanvas.js +0 -0
  100. /package/dist/{components → esm/components}/procaptchaIconOrder.js +0 -0
  101. /package/dist/{components → esm/components}/procaptchaWidget.js +0 -0
  102. /package/dist/{index.js → esm/index.js} +0 -0
  103. /package/dist/{components → tsc/components}/iconOrderCanvas.d.ts +0 -0
  104. /package/dist/{components → tsc/components}/procaptchaIconOrder.d.ts +0 -0
  105. /package/dist/{components → tsc/components}/procaptchaWidget.d.ts +0 -0
  106. /package/dist/{errorSites.d.ts → tsc/errorSites.d.ts} +0 -0
  107. /package/dist/{errorSites.js → tsc/errorSites.js} +0 -0
  108. /package/dist/{index.d.ts → tsc/index.d.ts} +0 -0
  109. /package/dist/{services → tsc/services}/Manager.d.ts +0 -0
  110. /package/dist/{tests → tsc/tests}/domHarness.d.ts +0 -0
  111. /package/dist/{tests → tsc/tests}/domHarness.js +0 -0
  112. /package/dist/{tests → tsc/tests}/iconOrderCanvas.unit.test.d.ts +0 -0
  113. /package/dist/{tests → tsc/tests}/iconOrderCanvas.unit.test.js +0 -0
  114. /package/dist/{tests → tsc/tests}/invisibleCanvasVisibility.unit.test.d.ts +0 -0
  115. /package/dist/{tests → tsc/tests}/invisibleCanvasVisibility.unit.test.js +0 -0
  116. /package/dist/{tests → tsc/tests}/manager.unit.test.d.ts +0 -0
  117. /package/dist/{tests → tsc/tests}/managerHarness.d.ts +0 -0
  118. /package/dist/{tests → tsc/tests}/managerHarness.js +0 -0
  119. /package/dist/{tests → tsc/tests}/procaptchaIconOrder.test-d.d.ts +0 -0
  120. /package/dist/{tests → tsc/tests}/procaptchaIconOrder.test-d.js +0 -0
  121. /package/dist/{tests → tsc/tests}/procaptchaIconOrder.unit.test.d.ts +0 -0
  122. /package/dist/{tests → tsc/tests}/procaptchaIconOrder.unit.test.js +0 -0
  123. /package/dist/{tests → tsc/tests}/procaptchaWidget.unit.test.d.ts +0 -0
  124. /package/dist/{tests → tsc/tests}/procaptchaWidget.unit.test.js +0 -0
@@ -44,7 +44,7 @@ computing gzip size...
44
44
  dist/cjs/components/procaptchaIconOrder.cjs 0.49 kB │ gzip: 0.23 kB
45
45
  dist/cjs/index.cjs 0.64 kB │ gzip: 0.22 kB
46
46
  dist/cjs/components/procaptchaWidget.cjs 7.11 kB │ gzip: 2.08 kB
47
- dist/cjs/services/Manager.cjs 8.92 kB │ gzip: 2.51 kB
47
+ dist/cjs/services/Manager.cjs 8.88 kB │ gzip: 2.49 kB
48
48
  dist/cjs/components/iconOrderCanvas.cjs 10.64 kB │ gzip: 3.16 kB
49
49
 
50
- ✓ built in 84ms
50
+ ✓ built in 44ms
@@ -1,5 +1,4 @@
1
- $ pnpm run build:cross-env --mode ${NODE_ENV:-development}
2
- $ vite build --config vite.esm.config.ts --mode production
1
+ $ vite build --config vite.esm.config.ts --mode ${NODE_ENV:-development}
3
2
  ViteEsmConfig: .
4
3
  {
5
4
  tsConfigPaths: [
@@ -42,11 +41,11 @@ Bundle build started
42
41
  ✓ 6 modules transformed.
43
42
  rendering chunks...
44
43
  computing gzip size...
45
- dist/_virtual/_rolldown/runtime.js 0.04 kB │ gzip: 0.06 kB
46
- dist/components/procaptchaIconOrder.js 0.36 kB │ gzip: 0.19 kB
47
- dist/index.js 0.41 kB │ gzip: 0.17 kB
48
- dist/components/procaptchaWidget.js 6.78 kB │ gzip: 2.08 kB
49
- dist/services/Manager.js 8.33 kB │ gzip: 2.46 kB
50
- dist/components/iconOrderCanvas.js 9.90 kB │ gzip: 3.14 kB
44
+ dist/esm/_virtual/_rolldown/runtime.js 0.04 kB │ gzip: 0.06 kB
45
+ dist/esm/components/procaptchaIconOrder.js 0.36 kB │ gzip: 0.19 kB
46
+ dist/esm/index.js 0.41 kB │ gzip: 0.17 kB
47
+ dist/esm/components/procaptchaWidget.js 6.78 kB │ gzip: 2.08 kB
48
+ dist/esm/services/Manager.js 8.29 kB │ gzip: 2.45 kB
49
+ dist/esm/components/iconOrderCanvas.js 9.90 kB │ gzip: 3.14 kB
51
50
 
52
- ✓ built in 73ms
51
+ ✓ built in 45ms
@@ -1,5 +1,5 @@
1
1
  $ tsc --build --verbose
2
- 3:59:59 PM - Projects in this build:
2
+ 12:57:34 PM - Projects in this build:
3
3
  * ../../dev/config/tsconfig.json
4
4
  * ../util/tsconfig.json
5
5
  * ../locale/tsconfig.json
@@ -16,35 +16,35 @@ $ tsc --build --verbose
16
16
  * ../procaptcha-common/tsconfig.json
17
17
  * tsconfig.json
18
18
 
19
- 3:59:59 PM - Project '../../dev/config/tsconfig.json' is up to date because newest input '../../dev/config/src/webpack/webpack.config.ts' is older than output '../../dev/config/tsconfig.tsbuildinfo'
19
+ 12:57:34 PM - Project '../../dev/config/tsconfig.json' is up to date because newest input '../../dev/config/src/vite/vite.esm.config.ts' is older than output '../../dev/config/dist/tsc/tsconfig.tsbuildinfo'
20
20
 
21
- 3:59:59 PM - Project '../util/tsconfig.json' is up to date because newest input '../util/src/url.ts' is older than output '../util/tsconfig.tsbuildinfo'
21
+ 12:57:34 PM - Project '../util/tsconfig.json' is up to date because newest input '../util/src/url.ts' is older than output '../util/dist/tsc/tsconfig.tsbuildinfo'
22
22
 
23
- 3:59:59 PM - Project '../locale/tsconfig.json' is up to date because newest input '../locale/src/process.ts' is older than output '../locale/tsconfig.tsbuildinfo'
23
+ 12:57:34 PM - Project '../locale/tsconfig.json' is up to date because newest input '../locale/src/translator.ts' is older than output '../locale/dist/tsc/tsconfig.tsbuildinfo'
24
24
 
25
- 3:59:59 PM - Project '../util-crypto/tsconfig.json' is up to date because newest input '../util-crypto/src/types.ts' is older than output '../util-crypto/tsconfig.tsbuildinfo'
25
+ 12:57:34 PM - Project '../util-crypto/tsconfig.json' is up to date because newest input '../util-crypto/src/types.ts' is older than output '../util-crypto/dist/tsc/tsconfig.tsbuildinfo'
26
26
 
27
- 3:59:59 PM - Project '../types/tsconfig.json' is up to date because newest input '../types/src/types.test-d.ts' is older than output '../types/tsconfig.tsbuildinfo'
27
+ 12:57:34 PM - Project '../types/tsconfig.json' is up to date because newest input '../types/src/types.test-d.ts' is older than output '../types/dist/tsc/tsconfig.tsbuildinfo'
28
28
 
29
- 3:59:59 PM - Project '../api/tsconfig.json' is up to date because newest input '../api/src/tests/apiHarness.ts' is older than output '../api/tsconfig.tsbuildinfo'
29
+ 12:57:35 PM - Project '../api/tsconfig.json' is up to date because newest input '../api/src/tests/apiHarness.ts' is older than output '../api/dist/tsc/tsconfig.tsbuildinfo'
30
30
 
31
- 3:59:59 PM - Project '../common/tsconfig.json' is up to date because newest input '../common/src/tests/errorSites.unit.test.ts' is older than output '../common/tsconfig.tsbuildinfo'
31
+ 12:57:35 PM - Project '../common/tsconfig.json' is up to date because newest input '../common/src/error.ts' is older than output '../common/dist/tsc/tsconfig.tsbuildinfo'
32
32
 
33
- 3:59:59 PM - Project '../load-balancer/tsconfig.json' is up to date because newest input '../load-balancer/src/tests/productionProviderList.unit.test.ts' is older than output '../load-balancer/tsconfig.tsbuildinfo'
33
+ 12:57:35 PM - Project '../load-balancer/tsconfig.json' is up to date because newest input '../load-balancer/src/balancer.ts' is older than output '../load-balancer/dist/tsc/tsconfig.tsbuildinfo'
34
34
 
35
- 3:59:59 PM - Project '../widget-skeleton/tsconfig.json' is up to date because newest input '../widget-skeleton/src/theme.ts' is older than output '../widget-skeleton/tsconfig.tsbuildinfo'
35
+ 12:57:35 PM - Project '../widget-skeleton/tsconfig.json' is up to date because newest input '../widget-skeleton/src/theme.ts' is older than output '../widget-skeleton/dist/tsc/tsconfig.tsbuildinfo'
36
36
 
37
- 3:59:59 PM - Project '../fingerprintjs/tsconfig.json' is up to date because newest input '../fingerprintjs/src/utils/browser.ts' is older than output '../fingerprintjs/tsconfig.tsbuildinfo'
37
+ 12:57:35 PM - Project '../fingerprintjs/tsconfig.json' is up to date because newest input '../fingerprintjs/src/sources/webgl.ts' is older than output '../fingerprintjs/dist/tsc/tsconfig.tsbuildinfo'
38
38
 
39
- 3:59:59 PM - Project '../fingerprint/tsconfig.json' is up to date because newest input '../fingerprint/src/index.test.ts' is older than output '../fingerprint/tsconfig.tsbuildinfo'
39
+ 12:57:35 PM - Project '../fingerprint/tsconfig.json' is up to date because newest input '../fingerprint/src/index.test.ts' is older than output '../fingerprint/dist/tsc/tsconfig.tsbuildinfo'
40
40
 
41
- 3:59:59 PM - Project '../keyring/tsconfig.json' is up to date because newest input '../keyring/src/keyring/keyring.test.ts' is older than output '../keyring/tsconfig.tsbuildinfo'
41
+ 12:57:35 PM - Project '../keyring/tsconfig.json' is up to date because newest input '../keyring/src/keyring/keyring.test.ts' is older than output '../keyring/dist/tsc/tsconfig.tsbuildinfo'
42
42
 
43
- 4:00:00 PM - Project '../account/tsconfig.json' is up to date because newest input '../account/src/errorSites.ts' is older than output '../account/tsconfig.tsbuildinfo'
43
+ 12:57:35 PM - Project '../account/tsconfig.json' is up to date because newest input '../account/src/custom.d.ts' is older than output '../account/dist/tsc/tsconfig.tsbuildinfo'
44
44
 
45
- 4:00:00 PM - Project '../procaptcha-common/tsconfig.json' is up to date because newest input '../procaptcha-common/src/extensionLoader.ts' is older than output '../procaptcha-common/tsconfig.tsbuildinfo'
45
+ 12:57:35 PM - Project '../procaptcha-common/tsconfig.json' is up to date because newest input '../procaptcha-common/src/tests/protectSession.test.ts' is older than output '../procaptcha-common/dist/tsc/tsconfig.tsbuildinfo'
46
46
 
47
- 4:00:00 PM - Project 'tsconfig.json' is out of date because output file 'tsconfig.tsbuildinfo' does not exist
47
+ 12:57:35 PM - Project 'tsconfig.json' is out of date because output file 'dist/tsc/tsconfig.tsbuildinfo' does not exist
48
48
 
49
- 4:00:00 PM - Building project '/home/runner/work/captcha/captcha/packages/procaptcha-icon-order/tsconfig.json'...
49
+ 12:57:35 PM - Building project '/home/runner/work/captcha/captcha/packages/procaptcha-icon-order/tsconfig.json'...
50
50
 
@@ -0,0 +1 @@
1
+ $ tsc --project tsconfig.types.json
package/CHANGELOG.md CHANGED
@@ -1,5 +1,51 @@
1
1
  # @prosopo/procaptcha-icon-order
2
2
 
3
+ ## 0.2.11
4
+ ### Patch Changes
5
+
6
+ - 76b6edd: The widget now tells the provider which bundle it is and where it was loaded from, on every request:
7
+
8
+ - `X-Prosopo-Bundle-Version`: the release the bundle was built from, or `dev` for a local build.
9
+ - `X-Prosopo-Bundle-Origin`: the origin the widget's code came from. `https://js.prosopo.io` is the hosted bundle. Anything else is a site serving its own copy, or building our npm packages into its app.
10
+
11
+ Providers store request headers on the session and in the request logs, so together with the site key these show which sites self-host and which version each one runs.
12
+
13
+ The provider now allows both headers in CORS. Every provider must run this version before the new bundle is published to the CDN: a widget sending these headers to an older provider fails the browser's preflight check and cannot load a captcha.
14
+ - Updated dependencies [1966fc1]
15
+ - Updated dependencies [c69b636]
16
+ - Updated dependencies [78107d9]
17
+ - Updated dependencies [d6cc6fe]
18
+ - Updated dependencies [f13677e]
19
+ - Updated dependencies [77bd891]
20
+ - Updated dependencies [76b6edd]
21
+ - @prosopo/common@3.3.2
22
+ - @prosopo/locale@3.13.2
23
+ - @prosopo/procaptcha-common@2.21.10
24
+ - @prosopo/types@5.20.0
25
+ - @prosopo/util@3.4.0
26
+ - @prosopo/util-crypto@13.6.3
27
+ - @prosopo/widget-skeleton@2.10.5
28
+ - @prosopo/api@4.8.0
29
+
30
+ ## 0.2.10
31
+ ### Patch Changes
32
+
33
+ - 2086040: Each kind of build now writes to its own folder under dist: dist/esm (vite ESM), dist/cjs (vite CommonJS), dist/types (declarations), dist/tsc (plain tsc), dist/bundle and dist/bundle-webpack (bundles) and dist/native (the Rust addons). Turbo caches each folder separately, so building one variant no longer overwrites or invalidates another. Package exports point at the new folders; anything importing a file from dist by path has to add the variant folder.
34
+
35
+ The Rust addons are no longer committed. They are built into dist/native, in debug for development and tests and fully optimised when NODE_ENV=production, so building them now needs a Rust toolchain.
36
+
37
+ Code that found the repo root or its certificates by climbing a fixed number of folders up from its own file now starts from its package's folder instead (new `packageDir` in @prosopo/util/node). The fixed count stopped working once the build output moved one folder deeper.
38
+ - Updated dependencies [2086040]
39
+ - Updated dependencies [915f30b]
40
+ - @prosopo/api@4.7.7
41
+ - @prosopo/common@3.3.1
42
+ - @prosopo/locale@3.13.1
43
+ - @prosopo/procaptcha-common@2.21.9
44
+ - @prosopo/types@5.19.0
45
+ - @prosopo/util-crypto@13.6.2
46
+ - @prosopo/util@3.3.17
47
+ - @prosopo/widget-skeleton@2.10.4
48
+
3
49
  ## 0.2.9
4
50
  ### Patch Changes
5
51
 
@@ -1,4 +1,3 @@
1
- let _prosopo_locale = require("@prosopo/locale");
2
1
  let _prosopo_procaptcha_common = require("@prosopo/procaptcha-common");
3
2
  let _prosopo_types = require("@prosopo/types");
4
3
  let _polkadot_util_string = require("@polkadot/util/string");
@@ -116,7 +115,7 @@ var Manager = (configInput, state, onStateUpdate, callbacks, frictionlessState,
116
115
  }
117
116
  const providerUrl = getRandomProviderResponse.provider.url;
118
117
  previousProviderUrl = providerUrl;
119
- const providerApi = new _prosopo_api.ProviderApi(providerUrl, getDappAccount(), void 0, (0, _prosopo_locale.widgetLanguageHeaders)(getConfig().language));
118
+ const providerApi = new _prosopo_api.ProviderApi(providerUrl, getDappAccount(), void 0, (0, _prosopo_procaptcha_common.widgetRequestHeaders)(getConfig().language));
120
119
  const challengeSessionId = frictionlessState?.sessionId;
121
120
  if (spentSession.isSpent(challengeSessionId)) {
122
121
  updateState({
@@ -1,5 +1,4 @@
1
- import { widgetLanguageHeaders } from "@prosopo/locale";
2
- import { ExtensionLoader, buildClientMetaData, buildUpdateState, createManagerLifecycle, createSpentSessionGuard, encryptBehavioralDataForSubmit, getDefaultEvents, getProcaptchaRandomActiveProvider, getSimdReadingsForSubmit, pickIpMode, providerRetry } from "@prosopo/procaptcha-common";
1
+ import { ExtensionLoader, buildClientMetaData, buildUpdateState, createManagerLifecycle, createSpentSessionGuard, encryptBehavioralDataForSubmit, getDefaultEvents, getProcaptchaRandomActiveProvider, getSimdReadingsForSubmit, pickIpMode, providerRetry, widgetRequestHeaders } from "@prosopo/procaptcha-common";
3
2
  import { ApiParams, CaptchaType, ProcaptchaConfigSchema, encodeProcaptchaOutput } from "@prosopo/types";
4
3
  import { stringToHex } from "@polkadot/util/string";
5
4
  import { ProviderApi } from "@prosopo/api";
@@ -116,7 +115,7 @@ var Manager = (configInput, state, onStateUpdate, callbacks, frictionlessState,
116
115
  }
117
116
  const providerUrl = getRandomProviderResponse.provider.url;
118
117
  previousProviderUrl = providerUrl;
119
- const providerApi = new ProviderApi(providerUrl, getDappAccount(), void 0, widgetLanguageHeaders(getConfig().language));
118
+ const providerApi = new ProviderApi(providerUrl, getDappAccount(), void 0, widgetRequestHeaders(getConfig().language));
120
119
  const challengeSessionId = frictionlessState?.sessionId;
121
120
  if (spentSession.isSpent(challengeSessionId)) {
122
121
  updateState({
@@ -0,0 +1 @@
1
+ {"version":3,"file":"iconOrderCanvas.d.ts","sourceRoot":"","sources":["../../../src/components/iconOrderCanvas.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,UAAU,EAAwB,MAAM,iBAAiB,CAAC;AACxE,OAAO,EAEN,KAAK,qBAAqB,EAG1B,KAAK,SAAS,EAOd,MAAM,4BAA4B,CAAC;AACpC,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAC/E,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAC;AAEtD,MAAM,WAAW,oBAAoB;IAEpC,UAAU,EAAE,MAAM,CAAC;IAEnB,MAAM,EAAE,MAAM,CAAC;IAEf,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,CAAC,MAAM,EAAE,SAAS,EAAE,EAAE,MAAM,EAAE,cAAc,EAAE,KAAK,IAAI,CAAC;IACpE,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,OAAO,CAAC;IACpB,KAAK,EAAE,KAAK,CAAC;IACb,UAAU,EAAE,UAAU,CAAC;IACvB,SAAS,CAAC,EAAE,aAAa,CAAC;IAC1B,MAAM,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IAEvB,gBAAgB,CAAC,EAAE,qBAAqB,CAAC;CACzC;AAsBD,eAAO,MAAM,oBAAoB,iBAClB,oBAAoB,KAChC,SAAS,CAAC,oBAAoB,CAsYhC,CAAC"}
@@ -0,0 +1,336 @@
1
+ import { Teardown, applyAttributes, applyStyles, createElement, mountAudioAlternativeFooter, mountChallengeSurface, } from "@prosopo/procaptcha-common";
2
+ const CONTAINER_WIDTH = 300;
3
+ const CONTAINER_HEIGHT = 200;
4
+ const MARKER_RADIUS = 13;
5
+ const SHAKE_MS = 500;
6
+ const MAIN_BUTTON = 0;
7
+ const SHAKE_KEYFRAMES = `
8
+ @keyframes prosopo-icon-order-shake {
9
+ 0%, 100% { transform: translateX(0); }
10
+ 10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
11
+ 20%, 40%, 60%, 80% { transform: translateX(4px); }
12
+ }
13
+ `;
14
+ export const mountIconOrderCanvas = (initialProps) => {
15
+ const teardown = new Teardown();
16
+ let props = initialProps;
17
+ let clicks = [];
18
+ let events = [];
19
+ let startedAt = Date.now();
20
+ let visible = false;
21
+ let shaking = false;
22
+ let shakeTimer;
23
+ const markers = [];
24
+ const t = (key, options) => props.translator.t(key, options);
25
+ const style = createElement("style", { text: SHAKE_KEYFRAMES });
26
+ const instruction = createElement("span");
27
+ const legend = createElement("img", {
28
+ style: { imageRendering: "auto", userSelect: "none" },
29
+ attributes: { draggable: "false" },
30
+ });
31
+ const header = createElement("div", {
32
+ style: {
33
+ borderRadius: "20px 20px 0 0",
34
+ padding: "10px 16px",
35
+ width: `${CONTAINER_WIDTH}px`,
36
+ boxSizing: "border-box",
37
+ display: "flex",
38
+ alignItems: "center",
39
+ justifyContent: "space-between",
40
+ gap: "10px",
41
+ fontSize: "14px",
42
+ fontWeight: 500,
43
+ transition: "color 0.3s ease, border-color 0.3s ease",
44
+ },
45
+ children: [instruction, legend],
46
+ });
47
+ const background = createElement("img", {
48
+ style: {
49
+ position: "absolute",
50
+ inset: 0,
51
+ width: `${CONTAINER_WIDTH}px`,
52
+ height: `${CONTAINER_HEIGHT}px`,
53
+ pointerEvents: "none",
54
+ userSelect: "none",
55
+ },
56
+ attributes: { alt: "", draggable: "false" },
57
+ });
58
+ const frame = createElement("div", {
59
+ style: {
60
+ position: "relative",
61
+ width: `${CONTAINER_WIDTH}px`,
62
+ height: `${CONTAINER_HEIGHT}px`,
63
+ overflow: "hidden",
64
+ userSelect: "none",
65
+ touchAction: "none",
66
+ transition: "opacity 0.2s ease",
67
+ },
68
+ children: [background],
69
+ });
70
+ const resetButton = createElement("button", {
71
+ attributes: { type: "button" },
72
+ style: {
73
+ flex: "0 0 auto",
74
+ padding: "8px 12px",
75
+ borderRadius: "10px",
76
+ background: "transparent",
77
+ fontSize: "13px",
78
+ },
79
+ });
80
+ const submitButton = createElement("button", {
81
+ attributes: { type: "button" },
82
+ style: {
83
+ flex: "1 1 auto",
84
+ padding: "8px 12px",
85
+ borderRadius: "10px",
86
+ border: "none",
87
+ fontSize: "14px",
88
+ fontWeight: 600,
89
+ },
90
+ });
91
+ if ("production" !== process.env.NODE_ENV) {
92
+ applyAttributes(frame, { "data-cy": "prosopo-icon-order-frame" });
93
+ applyAttributes(resetButton, { "data-cy": "prosopo-icon-order-reset" });
94
+ applyAttributes(submitButton, { "data-cy": "prosopo-icon-order-submit" });
95
+ }
96
+ const controls = createElement("div", {
97
+ style: {
98
+ borderRadius: "0 0 20px 20px",
99
+ padding: "10px 16px",
100
+ width: `${CONTAINER_WIDTH}px`,
101
+ boxSizing: "border-box",
102
+ display: "flex",
103
+ alignItems: "center",
104
+ gap: "10px",
105
+ },
106
+ children: [resetButton, submitButton],
107
+ });
108
+ const panel = createElement("div", {
109
+ style: {
110
+ display: "flex",
111
+ flexDirection: "column",
112
+ alignItems: "center",
113
+ transition: "opacity 0.3s ease, transform 0.3s ease",
114
+ },
115
+ children: [header, frame, controls],
116
+ });
117
+ const surfaceProps = () => ({
118
+ show: true,
119
+ placement: props.placement,
120
+ anchor: props.anchor,
121
+ onDismiss: props.onDismiss,
122
+ scrim: visible ? "dim" : "none",
123
+ dialogLabel: t("WIDGET.ICON_ORDER.DIALOG_LABEL", {
124
+ defaultValue: "Icon order challenge",
125
+ }),
126
+ });
127
+ const surface = mountChallengeSurface(surfaceProps());
128
+ surface.content.append(style, panel);
129
+ const audioAlternativeFooterProps = () => ({
130
+ offer: props.audioAlternative,
131
+ theme: props.theme,
132
+ width: CONTAINER_WIDTH,
133
+ });
134
+ const audioAlternativeFooter = mountAudioAlternativeFooter(panel, audioAlternativeFooterProps());
135
+ const createMarker = () => createElement("div", {
136
+ style: {
137
+ position: "absolute",
138
+ width: `${MARKER_RADIUS * 2}px`,
139
+ height: `${MARKER_RADIUS * 2}px`,
140
+ borderRadius: "50%",
141
+ border: "2px solid rgba(255, 255, 255, 0.9)",
142
+ boxShadow: "0 2px 6px rgba(0, 0, 0, 0.45)",
143
+ display: "flex",
144
+ alignItems: "center",
145
+ justifyContent: "center",
146
+ fontSize: "12px",
147
+ fontWeight: 700,
148
+ pointerEvents: "none",
149
+ userSelect: "none",
150
+ },
151
+ });
152
+ const renderMarkers = () => {
153
+ while (markers.length > clicks.length) {
154
+ markers.pop()?.remove();
155
+ }
156
+ while (markers.length < clicks.length) {
157
+ const marker = createMarker();
158
+ frame.appendChild(marker);
159
+ markers.push(marker);
160
+ }
161
+ const { theme } = props;
162
+ clicks.forEach((click, index) => {
163
+ const marker = markers[index];
164
+ if (!marker) {
165
+ return;
166
+ }
167
+ marker.textContent = String(index + 1);
168
+ applyStyles(marker, {
169
+ left: `${click.x - MARKER_RADIUS}px`,
170
+ top: `${click.y - MARKER_RADIUS}px`,
171
+ backgroundColor: theme.palette.primary.main,
172
+ color: theme.palette.background.default,
173
+ fontFamily: theme.font.fontFamily,
174
+ });
175
+ });
176
+ };
177
+ const render = () => {
178
+ const { theme, showRetry, submitting } = props;
179
+ const empty = 0 === clicks.length;
180
+ const inactive = submitting || empty;
181
+ applyStyles(panel, {
182
+ opacity: visible ? 1 : 0,
183
+ transform: visible ? "scale(1)" : "scale(0.9)",
184
+ animation: shaking
185
+ ? `prosopo-icon-order-shake ${SHAKE_MS}ms ease`
186
+ : "none",
187
+ });
188
+ instruction.textContent = showRetry
189
+ ? t("WIDGET.ICON_ORDER.RETRY", { defaultValue: "Not quite — try again" })
190
+ : t("WIDGET.ICON_ORDER.SELECT", {
191
+ defaultValue: "Select in this order",
192
+ });
193
+ applyStyles(header, {
194
+ backgroundColor: theme.palette.surface,
195
+ fontFamily: theme.font.fontFamily,
196
+ color: showRetry ? theme.palette.error.main : theme.palette.onSurface,
197
+ borderBottom: `2px solid ${showRetry ? theme.palette.error.main : "transparent"}`,
198
+ });
199
+ legend.src = props.legend;
200
+ legend.alt = t("WIDGET.ICON_ORDER.LEGEND_ALT", {
201
+ defaultValue: "Icons to select, in order",
202
+ });
203
+ applyStyles(legend, { height: `${props.legendIconSize}px` });
204
+ background.src = props.background;
205
+ applyStyles(frame, {
206
+ background: `linear-gradient(135deg, ${theme.palette.surface} 0%, ${theme.palette.primaryContainer.main} 50%, ${theme.palette.surface} 100%)`,
207
+ cursor: submitting ? "default" : "pointer",
208
+ opacity: submitting ? 0.6 : 1,
209
+ pointerEvents: submitting ? "none" : "auto",
210
+ });
211
+ renderMarkers();
212
+ applyStyles(controls, {
213
+ backgroundColor: theme.palette.surface,
214
+ borderRadius: props.audioAlternative ? "0" : "0 0 20px 20px",
215
+ });
216
+ audioAlternativeFooter.update(audioAlternativeFooterProps());
217
+ resetButton.textContent = t("WIDGET.ICON_ORDER.RESET", {
218
+ defaultValue: "Reset",
219
+ });
220
+ resetButton.disabled = inactive;
221
+ applyStyles(resetButton, {
222
+ border: `1px solid ${theme.palette.border}`,
223
+ color: theme.palette.onSurface,
224
+ fontFamily: theme.font.fontFamily,
225
+ cursor: inactive ? "default" : "pointer",
226
+ opacity: inactive ? 0.5 : 1,
227
+ });
228
+ submitButton.textContent = submitting
229
+ ? t("WIDGET.ICON_ORDER.CHECKING", { defaultValue: "Checking…" })
230
+ : t("WIDGET.ICON_ORDER.SUBMIT", { defaultValue: "OK" });
231
+ submitButton.disabled = inactive;
232
+ applyStyles(submitButton, {
233
+ backgroundColor: theme.palette.primary.main,
234
+ color: theme.palette.background.default,
235
+ fontFamily: theme.font.fontFamily,
236
+ cursor: inactive ? "default" : "pointer",
237
+ opacity: inactive ? 0.5 : 1,
238
+ });
239
+ surface.update(surfaceProps());
240
+ };
241
+ const clearAnswer = () => {
242
+ clicks = [];
243
+ events = [];
244
+ startedAt = Date.now();
245
+ };
246
+ const toFramePoint = (event) => {
247
+ if (props.submitting || !(event instanceof MouseEvent)) {
248
+ return null;
249
+ }
250
+ const rect = frame.getBoundingClientRect();
251
+ if (0 === rect.width || 0 === rect.height) {
252
+ return null;
253
+ }
254
+ return {
255
+ x: ((event.clientX - rect.left) / rect.width) * CONTAINER_WIDTH,
256
+ y: ((event.clientY - rect.top) / rect.height) * CONTAINER_HEIGHT,
257
+ };
258
+ };
259
+ const recordEvent = (point) => {
260
+ events.push({ x: point.x, y: point.y, t: Date.now() - startedAt });
261
+ };
262
+ teardown.addEventListener(frame, "pointermove", (event) => {
263
+ const point = toFramePoint(event);
264
+ if (point) {
265
+ recordEvent(point);
266
+ }
267
+ });
268
+ teardown.addEventListener(frame, "pointerup", (event) => {
269
+ if (event instanceof MouseEvent && MAIN_BUTTON !== event.button) {
270
+ return;
271
+ }
272
+ const point = toFramePoint(event);
273
+ if (!point) {
274
+ return;
275
+ }
276
+ recordEvent(point);
277
+ clicks = [...clicks, point];
278
+ render();
279
+ });
280
+ teardown.addEventListener(resetButton, "click", () => {
281
+ clearAnswer();
282
+ render();
283
+ });
284
+ teardown.addEventListener(submitButton, "click", () => {
285
+ if (props.submitting || 0 === clicks.length) {
286
+ return;
287
+ }
288
+ props.onComplete([...clicks], [...events]);
289
+ });
290
+ render();
291
+ const frameRequest = requestAnimationFrame(() => {
292
+ visible = true;
293
+ render();
294
+ });
295
+ teardown.add(() => cancelAnimationFrame(frameRequest));
296
+ const startShake = () => {
297
+ shaking = true;
298
+ render();
299
+ if (undefined !== shakeTimer) {
300
+ clearTimeout(shakeTimer);
301
+ }
302
+ shakeTimer = setTimeout(() => {
303
+ shaking = false;
304
+ render();
305
+ }, SHAKE_MS);
306
+ };
307
+ teardown.add(() => {
308
+ if (undefined !== shakeTimer) {
309
+ clearTimeout(shakeTimer);
310
+ }
311
+ });
312
+ if (props.showRetry) {
313
+ startShake();
314
+ }
315
+ return {
316
+ update: (nextProps) => {
317
+ const previous = props;
318
+ props = nextProps;
319
+ if (nextProps.background !== previous.background ||
320
+ nextProps.legend !== previous.legend) {
321
+ clearAnswer();
322
+ }
323
+ if (nextProps.showRetry && !previous.showRetry) {
324
+ startShake();
325
+ return;
326
+ }
327
+ render();
328
+ },
329
+ destroy: () => {
330
+ teardown.run();
331
+ audioAlternativeFooter.destroy();
332
+ surface.destroy();
333
+ },
334
+ };
335
+ };
336
+ //# sourceMappingURL=iconOrderCanvas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"iconOrderCanvas.js","sourceRoot":"","sources":["../../../src/components/iconOrderCanvas.ts"],"names":[],"mappings":"AAeA,OAAO,EAMN,QAAQ,EACR,eAAe,EACf,WAAW,EACX,aAAa,EACb,2BAA2B,EAC3B,qBAAqB,GACrB,MAAM,4BAA4B,CAAC;AA2BpC,MAAM,eAAe,GAAG,GAAG,CAAC;AAC5B,MAAM,gBAAgB,GAAG,GAAG,CA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BACF,WAAW,EAAE,CAAC;YACf,CAAC;YAED,IAAI,SAAS,CAAC,SAAS,IAAI,CAAC,QAAQ,CAAC,SAAS,EAAE,CAAC;gBAChD,UAAU,EAAE,CAAC;gBACb,OAAO;YACR,CAAC;YAED,MAAM,EAAE,CAAC;QACV,CAAC;QACD,OAAO,EAAE,GAAG,EAAE;YACb,QAAQ,CAAC,GAAG,EAAE,CAAC;YACf,sBAAsB,CAAC,OAAO,EAAE,CAAC;YACjC,OAAO,CAAC,OAAO,EAAE,CAAC;QACnB,CAAC;KACD,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"procaptchaIconOrder.d.ts","sourceRoot":"","sources":["../../../src/components/procaptchaIconOrder.ts"],"names":[],"mappings":"AAcA,OAAO,EAAE,KAAK,aAAa,EAAa,MAAM,4BAA4B,CAAC;AAC3E,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAEvE,YAAY,EAAE,yBAAyB,EAAE,CAAC;AAE1C,MAAM,MAAM,0BAA0B,GACrC,aAAa,CAAC,yBAAyB,CAAC,CAAC;AAE1C,eAAO,MAAM,uBAAuB,QACzB,OAAO,CAAC,0BAA0B,CAC2B,CAAC;AAEzE,eAAO,MAAM,wBAAwB,EAAE,0BAEtC,CAAC"}
@@ -0,0 +1,4 @@
1
+ import { lazyMount } from "@prosopo/procaptcha-common";
2
+ export const loadProcaptchaIconOrder = async () => (await import("./procaptchaWidget.js")).mountProcaptchaIconOrderWidget;
3
+ export const mountProcaptchaIconOrder = lazyMount(loadProcaptchaIconOrder);
4
+ //# sourceMappingURL=procaptchaIconOrder.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"procaptchaIconOrder.js","sourceRoot":"","sources":["../../../src/components/procaptchaIconOrder.ts"],"names":[],"mappings":"AAcA,OAAO,EAAsB,SAAS,EAAE,MAAM,4BAA4B,CAAC;AAQ3E,MAAM,CAAC,MAAM,uBAAuB,GACnC,KAAK,IAAyC,EAAE,CAC/C,CAAC,MAAM,MAAM,CAAC,uBAAuB,CAAC,CAAC,CAAC,8BAA8B,CAAC;AAEzE,MAAM,CAAC,MAAM,wBAAwB,GAA+B,SAAS,CAC5E,uBAAuB,CACvB,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"procaptchaWidget.d.ts","sourceRoot":"","sources":["../../../src/components/procaptchaWidget.ts"],"names":[],"mappings":"AAgCA,OAAO,EAKN,KAAK,eAAe,EAEpB,MAAM,gBAAgB,CAAC;AAUxB,MAAM,WAAW,yBAAyB;IACzC,OAAO,IAAI,IAAI,CAAC;CAChB;AAED,eAAO,MAAM,8BAA8B,cAC/B,WAAW,SACf,eAAe,KACpB,yBAwTF,CAAC;AAEF,eAAe,8BAA8B,CAAC"}